text: (window.webpackJsonp=window.webpackJsonp||[]).push([[54],{"5l+g":function(e,n,t){(n=t("JPst")(!1)).push([e.i,"\n.dropzone[data-v-eac0d386] {\n  border: 2px solid #e5e5e5;\n  font-family: 'Roboto', sans-serif;\n  color: #777;\n  -webkit-transition: background-color 0.2s linear;\n  transition: background-color 0.2s linear;\n  padding: 5px;\n}\n.dropzone[data-v-eac0d386]:hover {\n  background-color: #f6f6f6;\n}\ni[data-v-eac0d386] {\n  color: #ccc;\n}\n.dropzone .dz-image img[data-v-eac0d386] {\n  width: 100%;\n  height: 100%;\n}\n.dropzone input[name='file'][data-v-eac0d386] {\n  display: none;\n}\n.dropzone .dz-preview .dz-image[data-v-eac0d386] {\n  border-radius: 0px;\n}\n.dropzone .dz-preview:hover .dz-image img[data-v-eac0d386] {\n  -webkit-transform: none;\n          transform: none;\n  -webkit-filter: none;\n  width: 100%;\n  height: 100%;\n}\n.dropzone .dz-preview .dz-details[data-v-eac0d386] {\n  bottom: 0px;\n  top: 0px;\n  color: white;\n  background-color: rgba(33, 150, 243, 0.8);\n  -webkit-transition: opacity 0.2s linear;\n  transition: opacity 0.2s linear;\n  text-align: left;\n}\n.dropzone .dz-preview .dz-details .dz-filename span[data-v-eac0d386],\n.dropzone .dz-preview .dz-details .dz-size span[data-v-eac0d386] {\n  background-color: transparent;\n}\n.dropzone .dz-preview .dz-details .dz-filename:not(:hover) span[data-v-eac0d386] {\n  border: none;\n}\n.dropzone .dz-preview .dz-details .dz-filename:hover span[data-v-eac0d386] {\n  background-color: transparent;\n  border: none;\n}\n.dropzone .dz-preview .dz-remove[data-v-eac0d386] {\n  position: absolute;\n  z-index: 30;\n  color: white;\n  margin-left: 15px;\n  padding: 10px;\n  top: inherit;\n  bottom: 15px;\n  border: 2px white solid;\n  text-decoration: none;\n  text-transform: uppercase;\n  font-size: 0.8rem;\n  font-weight: 800;\n  letter-spacing: 1.1px;\n  opacity: 0;\n}\n.dropzone .dz-preview:hover .dz-remove[data-v-eac0d386] {\n  opacity: 1;\n}\n.dropzone .dz-preview .dz-success-mark[data-v-eac0d386],\n.dropzone .dz-preview .dz-error-mark[data-v-eac0d386] {\n  margin-left: -40px;\n  margin-top: -50px;\n}\n.dropzone .dz-preview .dz-success-mark i[data-v-eac0d386],\n.dropzone .dz-preview .dz-error-mark i[data-v-eac0d386] {\n  color: white;\n  font-size: 5rem;\n}\n",""]),e.exports=n},YTvP:function(e,n,t){"use strict";t.r(n);var i=t("eeMe"),o=t.n(i);t("e8E5");o.a.autoDiscover=!1;var a={props:{id:{type:String,required:!0},url:{type:String,required:!0},clickable:{type:Boolean,default:!0},defaultMsg:{type:String,default:"Upload image"},acceptedFiles:{type:String,default:""},thumbnailHeight:{type:Number,default:200},thumbnailWidth:{type:Number,default:200},showRemoveLink:{type:Boolean,default:!0},maxFilesize:{type:Number,default:2},maxFiles:{type:Number,default:3},autoProcessQueue:{type:Boolean,default:!0},useCustomDropzoneOptions:{type:Boolean,default:!1},defaultImg:{default:"",type:[String,Array]},couldPaste:{type:Boolean,default:!1}},data:function(){return{dropzone:"",initOnce:!0}},watch:{defaultImg:function(e){0!==e.length?this.initOnce&&(this.initImages(e),this.initOnce=!1):this.initOnce=!1}},mounted:function(){var e=document.getElementById(this.id),n=this;this.dropzone=new o.a(e,{clickable:this.clickable,thumbnailWidth:this.thumbnailWidth,thumbnailHeight:this.thumbnailHeight,maxFiles:this.maxFiles,maxFilesize:this.maxFilesize,dictRemoveFile:"Remove",addRemoveLinks:this.showRemoveLink,acceptedFiles:this.acceptedFiles,autoProcessQueue:this.autoProcessQueue,dictDefaultMessage:'<i style="margin-top: 3em;display: inline-block" class="material-icons">'+this.defaultMsg+"</i><br>Drop files here to upload",dictMaxFilesExceeded:"Only one picture",previewTemplate:'<div class="dz-preview dz-file-preview"><div class="dz-image" style="width:'+this.thumbnailWidth+"px;height:"+this.thumbnailHeight+'px" ><img style="width:'+this.thumbnailWidth+"px;height:"+this.thumbnailHeight+'px" data-dz-thumbnail /></div><div class="dz-details"><div class="dz-size"><span data-dz-size></span></div><div class="dz-progress"><span class="dz-upload" data-dz-uploadprogress></span></div><div class="dz-error-message"><span data-dz-errormessage></span></div><div class="dz-success-mark"><i class="material-icons">done</i></div><div class="dz-error-mark"><i class="material-icons">error</i></div></div></div>',init:function(){var e=this,t=n.defaultImg;if(t)if(Array.isArray(t)){if(0===t.length)return;t.map((function(t,i){var o={name:"name"+i,size:12345,url:t};return e.options.addedfile.call(e,o),e.options.thumbnail.call(e,o,t),o.previewElement.classList.add("dz-success"),o.previewElement.classList.add("dz-complete"),n.initOnce=!1,!0}))}else{var i={name:"name",size:12345,url:t};this.options.addedfile.call(this,i),this.options.thumbnail.call(this,i,t),i.previewElement.classList.add("dz-success"),i.previewElement.classList.add("dz-complete"),n.initOnce=!1}},accept:function(e,n){n()},sending:function(e,t,i){n.initOnce=!1}}),this.couldPaste&&document.addEventListener("paste",this.pasteImg),this.dropzone.on("success",(function(e){n.$emit("dropzone-success",e,n.dropzone.element)})),this.dropzone.on("addedfile",(function(e){n.$emit("dropzone-fileAdded",e)})),this.dropzone.on("removedfile",(function(e){n.$emit("dropzone-removedFile",e)})),this.dropzone.on("error",(function(e,t,i){n.$emit("dropzone-error",e,t,i)})),this.dropzone.on("successmultiple",(function(e,t,i){n.$emit("dropzone-successmultiple",e,t,i)}))},destroyed:function(){document.removeEventListener("paste",this.pasteImg),this.dropzone.destroy()},methods:{removeAllFiles:function(){this.dropzone.removeAllFiles(!0)},processQueue:function(){this.dropzone.processQueue()},pasteImg:function(e){var n=(e.clipboardData||e.originalEvent.clipboardData).items;"file"===n[0].kind&&this.dropzone.addFile(n[0].getAsFile())},initImages:function(e){var n=this;if(e)if(Array.isArray(e))e.map((function(e,t){var i={name:"name"+t,size:12345,url:e};return n.dropzone.options.addedfile.call(n.dropzone,i),n.dropzone.options.thumbnail.call(n.dropzone,i,e),i.previewElement.classList.add("dz-success"),i.previewElement.classList.add("dz-complete"),!0}));else{var t={name:"name",size:12345,url:e};this.dropzone.options.addedfile.call(this.dropzone,t),this.dropzone.options.thumbnail.call(this.dropzone,t,e),t.previewElement.classList.add("dz-success"),t.previewElement.classList.add("dz-complete")}}}},s=(t("wA+b"),t("KHd+")),d={name:"DropzoneDemo",components:{Dropzone:Object(s.a)(a,(function(){var e=this.$createElement,n=this._self._c||e;return n("div",{ref:this.id,staticClass:"dropzone",attrs:{id:this.id,action:this.url}},[n("input",{attrs:{type:"file",name:"file"}})])}),[],!1,null,"eac0d386",null).exports},methods:{dropzoneS:function(e){this.$message({message:"Upload success",type:"success"})},dropzoneR:function(e){this.$message({message:"Delete success",type:"success"})}}},r=Object(s.a)(d,(function(){var e=this,n=e.$createElement,t=e._self._c||n;return t("div",{staticClass:"components-container"},[t("code",[e._v("\n    Based on "),t("a",{staticClass:"link-type",attrs:{href:"https://github.com/rowanwins/vue-dropzone"}},[e._v(" dropzone ")]),e._v(".\n    "+e._s(e.$t("components.dropzoneTips"))+"\n  ")]),e._v(" "),t("div",{staticClass:"editor-container"},[t("dropzone",{attrs:{id:"myVueDropzone",url:"https://httpbin.org/post"},on:{"dropzone-removedFile":e.dropzoneR,"dropzone-success":e.dropzoneS}})],1)])}),[],!1,null,null,null);n.default=r.exports},"t+1M":function(e,n,t){var i=t("5l+g");"string"==typeof i&&(i=[[e.i,i,""]]);var o={hmr:!0,transform:void 0,insertInto:void 0};t("aET+")(i,o);i.locals&&(e.exports=i.locals)},"wA+b":function(e,n,t){"use strict";var i=t("t+1M");t.n(i).a}}]);