(window.webpackJsonp=window.webpackJsonp||[]).push([["vendor"],{"./node_modules/dropzone/dist/dropzone.js": /*!************************************************!*\ !*** ./node_modules/dropzone/dist/dropzone.js ***! \************************************************/ /*! no static exports found */function(e,t,n){"use strict";(function(e){var t=function(){function e(e,t){for(var n=0;n1?n-1:0),r=1;r=a.length)break;a[o++].apply(this,i)}}return this}},{key:"off",value:function(e,t){if(!this._callbacks||0===arguments.length)return this._callbacks={},this;var n=this._callbacks[e];if(!n)return this;if(1===arguments.length)return delete this._callbacks[e],this;for(var i=0;i=n.length)break;var i=n[t++];if(/(^| )dz-message($| )/.test(i.className)){e=i,i.className="dz-message";break}}e||(e=o.createElement('
'),this.element.appendChild(e));var r=e.getElementsByTagName("span")[0];return r&&(null!=r.textContent?r.textContent=this.options.dictFallbackMessage:null!=r.innerText&&(r.innerText=this.options.dictFallbackMessage)),this.element.appendChild(this.getFallbackForm())},resize:function(e,t,n,i){var r={srcX:0,srcY:0,srcWidth:e.width,srcHeight:e.height},o=e.width/e.height;null==t&&null==n?(t=r.srcWidth,n=r.srcHeight):null==t?t=n*o:null==n&&(n=t/o);var a=(t=Math.min(t,r.srcWidth))/(n=Math.min(n,r.srcHeight));if(r.srcWidth>t||r.srcHeight>n)if("crop"===i)o>a?(r.srcHeight=e.height,r.srcWidth=r.srcHeight*a):(r.srcWidth=e.width,r.srcHeight=r.srcWidth/a);else{if("contain"!==i)throw new Error("Unknown resizeMethod '"+i+"'");o>a?n=t/o:t=n*o}return r.srcX=(e.width-r.srcWidth)/2,r.srcY=(e.height-r.srcHeight)/2,r.trgWidth=t,r.trgHeight=n,r},transformFile:function(e,t){return(this.options.resizeWidth||this.options.resizeHeight)&&e.type.match(/image.*/)?this.resizeImage(e,this.options.resizeWidth,this.options.resizeHeight,this.options.resizeMethod,t):t(e)},previewTemplate:'
\n
\n
\n
\n
\n
\n
\n
\n
\n \n Check\n \n \n \n \n \n
\n
\n \n Error\n \n \n \n \n \n \n \n
\n
',drop:function(e){return this.element.classList.remove("dz-drag-hover")},dragstart:function(e){},dragend:function(e){return this.element.classList.remove("dz-drag-hover")},dragenter:function(e){return this.element.classList.add("dz-drag-hover")},dragover:function(e){return this.element.classList.add("dz-drag-hover")},dragleave:function(e){return this.element.classList.remove("dz-drag-hover")},paste:function(e){},reset:function(){return this.element.classList.remove("dz-started")},addedfile:function(e){var t=this;if(this.element===this.previewsContainer&&this.element.classList.add("dz-started"),this.previewsContainer){e.previewElement=o.createElement(this.options.previewTemplate.trim()),e.previewTemplate=e.previewElement,this.previewsContainer.appendChild(e.previewElement);for(var n=0,i=i=e.previewElement.querySelectorAll("[data-dz-name]");;){if(n>=i.length)break;var r=i[n++];r.textContent=e.name}for(var a=0,s=s=e.previewElement.querySelectorAll("[data-dz-size]");!(a>=s.length);)(r=s[a++]).innerHTML=this.filesize(e.size);this.options.addRemoveLinks&&(e._removeLink=o.createElement(''+this.options.dictRemoveFile+""),e.previewElement.appendChild(e._removeLink));for(var l=function(n){return n.preventDefault(),n.stopPropagation(),e.status===o.UPLOADING?o.confirm(t.options.dictCancelUploadConfirmation,function(){return t.removeFile(e)}):t.options.dictRemoveFileConfirmation?o.confirm(t.options.dictRemoveFileConfirmation,function(){return t.removeFile(e)}):t.removeFile(e)},u=0,d=d=e.previewElement.querySelectorAll("[data-dz-remove]");;){if(u>=d.length)break;d[u++].addEventListener("click",l)}}},removedfile:function(e){return null!=e.previewElement&&null!=e.previewElement.parentNode&&e.previewElement.parentNode.removeChild(e.previewElement),this._updateMaxFilesReachedClass()},thumbnail:function(e,t){if(e.previewElement){e.previewElement.classList.remove("dz-file-preview");for(var n=0,i=i=e.previewElement.querySelectorAll("[data-dz-thumbnail]");;){if(n>=i.length)break;var r=i[n++];r.alt=e.name,r.src=t}return setTimeout(function(){return e.previewElement.classList.add("dz-image-preview")},1)}},error:function(e,t){if(e.previewElement){e.previewElement.classList.add("dz-error"),"String"!=typeof t&&t.error&&(t=t.error);for(var n=0,i=i=e.previewElement.querySelectorAll("[data-dz-errormessage]");;){if(n>=i.length)break;i[n++].textContent=t}}},errormultiple:function(){},processing:function(e){if(e.previewElement&&(e.previewElement.classList.add("dz-processing"),e._removeLink))return e._removeLink.innerHTML=this.options.dictCancelUpload},processingmultiple:function(){},uploadprogress:function(e,t,n){if(e.previewElement)for(var i=0,r=r=e.previewElement.querySelectorAll("[data-dz-uploadprogress]");;){if(i>=r.length)break;var o=r[i++];"PROGRESS"===o.nodeName?o.value=t:o.style.width=t+"%"}},totaluploadprogress:function(){},sending:function(){},sendingmultiple:function(){},success:function(e){if(e.previewElement)return e.previewElement.classList.add("dz-success")},successmultiple:function(){},canceled:function(e){return this.emit("error",e,this.options.dictUploadCanceled)},canceledmultiple:function(){},complete:function(e){if(e._removeLink&&(e._removeLink.innerHTML=this.options.dictRemoveFile),e.previewElement)return e.previewElement.classList.add("dz-complete")},completemultiple:function(){},maxfilesexceeded:function(){},maxfilesreached:function(){},queuecomplete:function(){},addedfiles:function(){}},this.prototype._thumbnailQueue=[],this.prototype._processingThumbnail=!1}},{key:"extend",value:function(e){for(var t=arguments.length,n=Array(t>1?t-1:0),i=1;i=o.length)break;var a=o[r++];for(var s in a){var l=a[s];e[s]=l}}return e}}]),t(o,[{key:"getAcceptedFiles",value:function(){return this.files.filter(function(e){return e.accepted}).map(function(e){return e})}},{key:"getRejectedFiles",value:function(){return this.files.filter(function(e){return!e.accepted}).map(function(e){return e})}},{key:"getFilesWithStatus",value:function(e){return this.files.filter(function(t){return t.status===e}).map(function(e){return e})}},{key:"getQueuedFiles",value:function(){return this.getFilesWithStatus(o.QUEUED)}},{key:"getUploadingFiles",value:function(){return this.getFilesWithStatus(o.UPLOADING)}},{key:"getAddedFiles",value:function(){return this.getFilesWithStatus(o.ADDED)}},{key:"getActiveFiles",value:function(){return this.files.filter(function(e){return e.status===o.UPLOADING||e.status===o.QUEUED}).map(function(e){return e})}},{key:"init",value:function(){var e=this;if("form"===this.element.tagName&&this.element.setAttribute("enctype","multipart/form-data"),this.element.classList.contains("dropzone")&&!this.element.querySelector(".dz-message")&&this.element.appendChild(o.createElement('
'+this.options.dictDefaultMessage+"
")),this.clickableElements.length){!function t(){return e.hiddenFileInput&&e.hiddenFileInput.parentNode.removeChild(e.hiddenFileInput),e.hiddenFileInput=document.createElement("input"),e.hiddenFileInput.setAttribute("type","file"),(null===e.options.maxFiles||e.options.maxFiles>1)&&e.hiddenFileInput.setAttribute("multiple","multiple"),e.hiddenFileInput.className="dz-hidden-input",null!==e.options.acceptedFiles&&e.hiddenFileInput.setAttribute("accept",e.options.acceptedFiles),null!==e.options.capture&&e.hiddenFileInput.setAttribute("capture",e.options.capture),e.hiddenFileInput.style.visibility="hidden",e.hiddenFileInput.style.position="absolute",e.hiddenFileInput.style.top="0",e.hiddenFileInput.style.left="0",e.hiddenFileInput.style.height="0",e.hiddenFileInput.style.width="0",o.getElement(e.options.hiddenInputContainer,"hiddenInputContainer").appendChild(e.hiddenFileInput),e.hiddenFileInput.addEventListener("change",function(){var n=e.hiddenFileInput.files;if(n.length)for(var i=0,r=r=n;!(i>=r.length);){var o=r[i++];e.addFile(o)}return e.emit("addedfiles",n),t()})}()}this.URL=null!==window.URL?window.URL:window.webkitURL;for(var t=0,n=n=this.events;;){if(t>=n.length)break;var i=n[t++];this.on(i,this.options[i])}this.on("uploadprogress",function(){return e.updateTotalUploadProgress()}),this.on("removedfile",function(){return e.updateTotalUploadProgress()}),this.on("canceled",function(t){return e.emit("complete",t)}),this.on("complete",function(t){if(0===e.getAddedFiles().length&&0===e.getUploadingFiles().length&&0===e.getQueuedFiles().length)return setTimeout(function(){return e.emit("queuecomplete")},0)});var r=function(e){return e.stopPropagation(),e.preventDefault?e.preventDefault():e.returnValue=!1};return this.listeners=[{element:this.element,events:{dragstart:function(t){return e.emit("dragstart",t)},dragenter:function(t){return r(t),e.emit("dragenter",t)},dragover:function(t){var n=void 0;try{n=t.dataTransfer.effectAllowed}catch(e){}return t.dataTransfer.dropEffect="move"===n||"linkMove"===n?"move":"copy",r(t),e.emit("dragover",t)},dragleave:function(t){return e.emit("dragleave",t)},drop:function(t){return r(t),e.drop(t)},dragend:function(t){return e.emit("dragend",t)}}}],this.clickableElements.forEach(function(t){return e.listeners.push({element:t,events:{click:function(n){return(t!==e.element||n.target===e.element||o.elementInside(n.target,e.element.querySelector(".dz-message")))&&e.hiddenFileInput.click(),!0}}})}),this.enable(),this.options.init.call(this)}},{key:"destroy",value:function(){return this.disable(),this.removeAllFiles(!0),(null!=this.hiddenFileInput?this.hiddenFileInput.parentNode:void 0)&&(this.hiddenFileInput.parentNode.removeChild(this.hiddenFileInput),this.hiddenFileInput=null),delete this.element.dropzone,o.instances.splice(o.instances.indexOf(this),1)}},{key:"updateTotalUploadProgress",value:function(){var e=void 0,t=0,n=0;if(this.getActiveFiles().length){for(var i=0,r=r=this.getActiveFiles();;){if(i>=r.length)break;var o=r[i++];t+=o.upload.bytesSent,n+=o.upload.total}e=100*t/n}else e=100;return this.emit("totaluploadprogress",e,n,t)}},{key:"_getParamName",value:function(e){return"function"==typeof this.options.paramName?this.options.paramName(e):this.options.paramName+(this.options.uploadMultiple?"["+e+"]":"")}},{key:"_renameFile",value:function(e){return"function"!=typeof this.options.renameFile?e.name:this.options.renameFile(e)}},{key:"getFallbackForm",value:function(){var e,t=void 0;if(e=this.getExistingFallback())return e;var n='
';this.options.dictFallbackText&&(n+="

"+this.options.dictFallbackText+"

"),n+='
';var i=o.createElement(n);return"FORM"!==this.element.tagName?(t=o.createElement('
')).appendChild(i):(this.element.setAttribute("enctype","multipart/form-data"),this.element.setAttribute("method",this.options.method)),null!=t?t:i}},{key:"getExistingFallback",value:function(){for(var e=function(e){for(var t=0,n=n=e;;){if(t>=n.length)break;var i=n[t++];if(/(^| )fallback($| )/.test(i.className))return i}},t=["div","form"],n=0;n0){for(var i=["tb","gb","mb","kb","b"],r=0;r=Math.pow(this.options.filesizeBase,4-r)/10){t=e/Math.pow(this.options.filesizeBase,4-r),n=o;break}}t=Math.round(10*t)/10}return""+t+" "+this.options.dictFileSizeUnits[n]}},{key:"_updateMaxFilesReachedClass",value:function(){return null!=this.options.maxFiles&&this.getAcceptedFiles().length>=this.options.maxFiles?(this.getAcceptedFiles().length===this.options.maxFiles&&this.emit("maxfilesreached",this.files),this.element.classList.add("dz-max-files-reached")):this.element.classList.remove("dz-max-files-reached")}},{key:"drop",value:function(e){if(e.dataTransfer){this.emit("drop",e);for(var t=[],n=0;n=n.length)break;var i=n[t++];this.addFile(i)}}},{key:"_addFilesFromItems",value:function(e){var t=this;return function(){for(var n=[],i=0,r=r=e;;){if(i>=r.length)break;var o,a=r[i++];null!=a.webkitGetAsEntry&&(o=a.webkitGetAsEntry())?o.isFile?n.push(t.addFile(a.getAsFile())):o.isDirectory?n.push(t._addFilesFromDirectory(o,o.name)):n.push(void 0):null!=a.getAsFile&&(null==a.kind||"file"===a.kind)?n.push(t.addFile(a.getAsFile())):n.push(void 0)}return n}()}},{key:"_addFilesFromDirectory",value:function(e,t){var n=this,i=e.createReader(),r=function(e){return t=console,n="log",i=function(t){return t.log(e)},void 0!==t&&null!==t&&"function"==typeof t[n]?i(t,n):void 0;var t,n,i};return function e(){return i.readEntries(function(i){if(i.length>0){for(var r=0,o=o=i;!(r>=o.length);){var a=o[r++];a.isFile?a.file(function(e){if(!n.options.ignoreHiddenFiles||"."!==e.name.substring(0,1))return e.fullPath=t+"/"+e.name,n.addFile(e)}):a.isDirectory&&n._addFilesFromDirectory(a,t+"/"+a.name)}e()}return null},r)}()}},{key:"accept",value:function(e,t){return this.options.maxFilesize&&e.size>1024*this.options.maxFilesize*1024?t(this.options.dictFileTooBig.replace("{{filesize}}",Math.round(e.size/1024/10.24)/100).replace("{{maxFilesize}}",this.options.maxFilesize)):o.isValidFile(e,this.options.acceptedFiles)?null!=this.options.maxFiles&&this.getAcceptedFiles().length>=this.options.maxFiles?(t(this.options.dictMaxFilesExceeded.replace("{{maxFiles}}",this.options.maxFiles)),this.emit("maxfilesexceeded",e)):this.options.accept.call(this,e,t):t(this.options.dictInvalidFileType)}},{key:"addFile",value:function(e){var t=this;return e.upload={uuid:o.uuidv4(),progress:0,total:e.size,bytesSent:0,filename:this._renameFile(e),chunked:this.options.chunking&&(this.options.forceChunking||e.size>this.options.chunkSize),totalChunkCount:Math.ceil(e.size/this.options.chunkSize)},this.files.push(e),e.status=o.ADDED,this.emit("addedfile",e),this._enqueueThumbnail(e),this.accept(e,function(n){return n?(e.accepted=!1,t._errorProcessing([e],n)):(e.accepted=!0,t.options.autoQueue&&t.enqueueFile(e)),t._updateMaxFilesReachedClass()})}},{key:"enqueueFiles",value:function(e){for(var t=0,n=n=e;;){if(t>=n.length)break;var i=n[t++];this.enqueueFile(i)}return null}},{key:"enqueueFile",value:function(e){var t=this;if(e.status!==o.ADDED||!0!==e.accepted)throw new Error("This file can't be queued because it has already been processed or was rejected.");if(e.status=o.QUEUED,this.options.autoProcessQueue)return setTimeout(function(){return t.processQueue()},0)}},{key:"_enqueueThumbnail",value:function(e){var t=this;if(this.options.createImageThumbnails&&e.type.match(/image.*/)&&e.size<=1024*this.options.maxThumbnailFilesize*1024)return this._thumbnailQueue.push(e),setTimeout(function(){return t._processThumbnailQueue()},0)}},{key:"_processThumbnailQueue",value:function(){var e=this;if(!this._processingThumbnail&&0!==this._thumbnailQueue.length){this._processingThumbnail=!0;var t=this._thumbnailQueue.shift();return this.createThumbnail(t,this.options.thumbnailWidth,this.options.thumbnailHeight,this.options.thumbnailMethod,!0,function(n){return e.emit("thumbnail",t,n),e._processingThumbnail=!1,e._processThumbnailQueue()})}}},{key:"removeFile",value:function(e){if(e.status===o.UPLOADING&&this.cancelUpload(e),this.files=a(this.files,e),this.emit("removedfile",e),0===this.files.length)return this.emit("reset")}},{key:"removeAllFiles",value:function(e){null==e&&(e=!1);for(var t=0,n=n=this.files.slice();;){if(t>=n.length)break;var i=n[t++];(i.status!==o.UPLOADING||e)&&this.removeFile(i)}return null}},{key:"resizeImage",value:function(e,t,n,i,r){var a=this;return this.createThumbnail(e,t,n,i,!0,function(t,n){if(null==n)return r(e);var i=a.options.resizeMimeType;null==i&&(i=e.type);var s=n.toDataURL(i,a.options.resizeQuality);return"image/jpeg"!==i&&"image/jpg"!==i||(s=u.restore(e.dataURL,s)),r(o.dataURItoBlob(s))})}},{key:"createThumbnail",value:function(e,t,n,i,r,o){var a=this,s=new FileReader;return s.onload=function(){if(e.dataURL=s.result,"image/svg+xml"!==e.type)return a.createThumbnailFromUrl(e,t,n,i,r,o);null!=o&&o(s.result)},s.readAsDataURL(e)}},{key:"createThumbnailFromUrl",value:function(e,t,n,i,r,o,a){var s=this,u=document.createElement("img");return a&&(u.crossOrigin=a),u.onload=function(){var a=function(e){return e(1)};return"undefined"!=typeof EXIF&&null!==EXIF&&r&&(a=function(e){return EXIF.getData(u,function(){return e(EXIF.getTag(this,"Orientation"))})}),a(function(r){e.width=u.width,e.height=u.height;var a=s.options.resize.call(s,e,t,n,i),d=document.createElement("canvas"),c=d.getContext("2d");switch(d.width=a.trgWidth,d.height=a.trgHeight,r>4&&(d.width=a.trgHeight,d.height=a.trgWidth),r){case 2:c.translate(d.width,0),c.scale(-1,1);break;case 3:c.translate(d.width,d.height),c.rotate(Math.PI);break;case 4:c.translate(0,d.height),c.scale(1,-1);break;case 5:c.rotate(.5*Math.PI),c.scale(1,-1);break;case 6:c.rotate(.5*Math.PI),c.translate(0,-d.width);break;case 7:c.rotate(.5*Math.PI),c.translate(d.height,-d.width),c.scale(-1,1);break;case 8:c.rotate(-.5*Math.PI),c.translate(-d.height,0)}l(c,u,null!=a.srcX?a.srcX:0,null!=a.srcY?a.srcY:0,a.srcWidth,a.srcHeight,null!=a.trgX?a.trgX:0,null!=a.trgY?a.trgY:0,a.trgWidth,a.trgHeight);var h=d.toDataURL("image/png");if(null!=o)return o(h,d)})},null!=o&&(u.onerror=o),u.src=e.dataURL}},{key:"processQueue",value:function(){var e=this.options.parallelUploads,t=this.getUploadingFiles().length,n=t;if(!(t>=e)){var i=this.getQueuedFiles();if(i.length>0){if(this.options.uploadMultiple)return this.processFiles(i.slice(0,e-t));for(;n=n.length)break;var i=n[t++];i.processing=!0,i.status=o.UPLOADING,this.emit("processing",i)}return this.options.uploadMultiple&&this.emit("processingmultiple",e),this.uploadFiles(e)}},{key:"_getFilesWithXhr",value:function(e){return this.files.filter(function(t){return t.xhr===e}).map(function(e){return e})}},{key:"cancelUpload",value:function(e){if(e.status===o.UPLOADING){for(var t=this._getFilesWithXhr(e.xhr),n=0,i=i=t;;){if(n>=i.length)break;i[n++].status=o.CANCELED}void 0!==e.xhr&&e.xhr.abort();for(var r=0,a=a=t;;){if(r>=a.length)break;var s=a[r++];this.emit("canceled",s)}this.options.uploadMultiple&&this.emit("canceledmultiple",t)}else e.status!==o.ADDED&&e.status!==o.QUEUED||(e.status=o.CANCELED,this.emit("canceled",e),this.options.uploadMultiple&&this.emit("canceledmultiple",[e]));if(this.options.autoProcessQueue)return this.processQueue()}},{key:"resolveOption",value:function(e){if("function"==typeof e){for(var t=arguments.length,n=Array(t>1?t-1:0),i=1;i=i.upload.totalChunkCount)){0;var a=n*t.options.chunkSize,s=Math.min(a+t.options.chunkSize,i.size),l={name:t._getParamName(0),data:r.webkitSlice?r.webkitSlice(a,s):r.slice(a,s),filename:i.upload.filename,chunkIndex:n};i.upload.chunks[n]={file:i,index:n,dataBlock:l,status:o.UPLOADING,progress:0,retries:0},t._uploadData(e,[l])}};if(i.upload.finishedChunkUpload=function(n){var r=!0;n.status=o.SUCCESS,n.dataBlock=null,n.xhr=null;for(var s=0;s=a.length)break;a[r++].xhr=i}e[0].upload.chunked&&(e[0].upload.chunks[t[0].chunkIndex].xhr=i);var s=this.resolveOption(this.options.method,e),l=this.resolveOption(this.options.url,e);i.open(s,l,!0),i.timeout=this.resolveOption(this.options.timeout,e),i.withCredentials=!!this.options.withCredentials,i.onload=function(t){n._finishedUploading(e,i,t)},i.onerror=function(){n._handleUploadError(e,i)},(null!=i.upload?i.upload:i).onprogress=function(t){return n._updateFilesUploadProgress(e,i,t)};var u={Accept:"application/json","Cache-Control":"no-cache","X-Requested-With":"XMLHttpRequest"};for(var d in this.options.headers&&o.extend(u,this.options.headers),u){var c=u[d];c&&i.setRequestHeader(d,c)}var h=new FormData;if(this.options.params){var p=this.options.params;for(var f in"function"==typeof p&&(p=p.call(this,e,i,e[0].upload.chunked?this._getChunk(e[0],i):null)),p){var m=p[f];h.append(f,m)}}for(var g=0,v=v=e;;){if(g>=v.length)break;var b=v[g++];this.emit("sending",b,i,h)}this.options.uploadMultiple&&this.emit("sendingmultiple",e,i,h),this._addFormElementData(h);for(var y=0;y=n.length)break;var i=n[t++],r=i.getAttribute("name"),o=i.getAttribute("type");if(o&&(o=o.toLowerCase()),void 0!==r&&null!==r)if("SELECT"===i.tagName&&i.hasAttribute("multiple"))for(var a=0,s=s=i.options;;){if(a>=s.length)break;var l=s[a++];l.selected&&e.append(r,l.value)}else(!o||"checkbox"!==o&&"radio"!==o||i.checked)&&e.append(r,i.value)}}},{key:"_updateFilesUploadProgress",value:function(e,t,n){var i=void 0;if(void 0!==n){if(i=100*n.loaded/n.total,e[0].upload.chunked){var r=e[0],o=this._getChunk(r,t);o.progress=i,o.total=n.total,o.bytesSent=n.loaded;r.upload.progress=0,r.upload.total=0,r.upload.bytesSent=0;for(var a=0;a=l.length)break;var u=l[s++];u.upload.progress=i,u.upload.total=n.total,u.upload.bytesSent=n.loaded}for(var d=0,c=c=e;;){if(d>=c.length)break;var h=c[d++];this.emit("uploadprogress",h,h.upload.progress,h.upload.bytesSent)}}else{var p=!0;i=100;for(var f=0,m=m=e;;){if(f>=m.length)break;var g=m[f++];100===g.upload.progress&&g.upload.bytesSent===g.upload.total||(p=!1),g.upload.progress=i,g.upload.bytesSent=g.upload.total}if(p)return;for(var v=0,b=b=e;;){if(v>=b.length)break;var y=b[v++];this.emit("uploadprogress",y,i,y.upload.bytesSent)}}}},{key:"_finishedUploading",value:function(e,t,n){var i=void 0;if(e[0].status!==o.CANCELED&&4===t.readyState){if("arraybuffer"!==t.responseType&&"blob"!==t.responseType&&(i=t.responseText,t.getResponseHeader("content-type")&&~t.getResponseHeader("content-type").indexOf("application/json")))try{i=JSON.parse(i)}catch(e){n=e,i="Invalid JSON response from server."}this._updateFilesUploadProgress(e),200<=t.status&&t.status<300?e[0].upload.chunked?e[0].upload.finishedChunkUpload(this._getChunk(e[0],t)):this._finished(e,i,n):this._handleUploadError(e,t,i)}}},{key:"_handleUploadError",value:function(e,t,n){if(e[0].status!==o.CANCELED){if(e[0].upload.chunked&&this.options.retryChunks){var i=this._getChunk(e[0],t);if(i.retries++=a.length)break;a[r++];this._errorProcessing(e,n||this.options.dictResponseError.replace("{{statusCode}}",t.status),t)}}}},{key:"submitRequest",value:function(e,t,n){e.send(t)}},{key:"_finished",value:function(e,t,n){for(var i=0,r=r=e;;){if(i>=r.length)break;var a=r[i++];a.status=o.SUCCESS,this.emit("success",a,t,n),this.emit("complete",a)}if(this.options.uploadMultiple&&(this.emit("successmultiple",e,t,n),this.emit("completemultiple",e)),this.options.autoProcessQueue)return this.processQueue()}},{key:"_errorProcessing",value:function(e,t,n){for(var i=0,r=r=e;;){if(i>=r.length)break;var a=r[i++];a.status=o.ERROR,this.emit("error",a,t,n),this.emit("complete",a)}if(this.options.uploadMultiple&&(this.emit("errormultiple",e,t,n),this.emit("completemultiple",e)),this.options.autoProcessQueue)return this.processQueue()}}],[{key:"uuidv4",value:function(){return"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,function(e){var t=16*Math.random()|0;return("x"===e?t:3&t|8).toString(16)})}}]),o}();o.initClass(),o.version="5.5.1",o.options={},o.optionsForElement=function(e){return e.getAttribute("id")?o.options[s(e.getAttribute("id"))]:void 0},o.instances=[],o.forElement=function(e){if("string"==typeof e&&(e=document.querySelector(e)),null==(null!=e?e.dropzone:void 0))throw new Error("No Dropzone found for given element. This is probably because you're trying to access it before Dropzone had the time to initialize. Use the `init` option to setup any additional observers on your Dropzone.");return e.dropzone},o.autoDiscover=!0,o.discover=function(){var e=void 0;if(document.querySelectorAll)e=document.querySelectorAll(".dropzone");else{e=[];var t=function(t){return function(){for(var n=[],i=0,r=r=t;;){if(i>=r.length)break;var o=r[i++];/(^| )dropzone($| )/.test(o.className)?n.push(e.push(o)):n.push(void 0)}return n}()};t(document.getElementsByTagName("div")),t(document.getElementsByTagName("form"))}return function(){for(var t=[],n=0,i=i=e;;){if(n>=i.length)break;var r=i[n++];!1!==o.optionsForElement(r)?t.push(new o(r)):t.push(void 0)}return t}()},o.blacklistedBrowsers=[/opera.*(Macintosh|Windows Phone).*version\/12/i],o.isBrowserSupported=function(){var e=!0;if(window.File&&window.FileReader&&window.FileList&&window.Blob&&window.FormData&&document.querySelector)if("classList"in document.createElement("a"))for(var t=0,n=n=o.blacklistedBrowsers;;){if(t>=n.length)break;n[t++].test(navigator.userAgent)&&(e=!1)}else e=!1;else e=!1;return e},o.dataURItoBlob=function(e){for(var t=atob(e.split(",")[1]),n=e.split(",")[0].split(":")[1].split(";")[0],i=new ArrayBuffer(t.length),r=new Uint8Array(i),o=0,a=t.length,s=0<=a;s?o<=a:o>=a;s?o++:o--)r[o]=t.charCodeAt(o);return new Blob([i],{type:n})};var a=function(e,t){return e.filter(function(e){return e!==t}).map(function(e){return e})},s=function(e){return e.replace(/[\-_](\w)/g,function(e){return e.charAt(1).toUpperCase()})};o.createElement=function(e){var t=document.createElement("div");return t.innerHTML=e,t.childNodes[0]},o.elementInside=function(e,t){if(e===t)return!0;for(;e=e.parentNode;)if(e===t)return!0;return!1},o.getElement=function(e,t){var n=void 0;if("string"==typeof e?n=document.querySelector(e):null!=e.nodeType&&(n=e),null==n)throw new Error("Invalid `"+t+"` option provided. Please provide a CSS selector or a plain HTML element.");return n},o.getElements=function(e,t){var n=void 0,i=void 0;if(e instanceof Array){i=[];try{for(var r=0,o=o=e;!(r>=o.length);)n=o[r++],i.push(this.getElement(n,t))}catch(e){i=null}}else if("string"==typeof e){i=[];for(var a=0,s=s=document.querySelectorAll(e);!(a>=s.length);)n=s[a++],i.push(n)}else null!=e.nodeType&&(i=[e]);if(null==i||!i.length)throw new Error("Invalid `"+t+"` option provided. Please provide a CSS selector, a plain HTML element or a list of those.");return i},o.confirm=function(e,t,n){return window.confirm(e)?t():null!=n?n():void 0},o.isValidFile=function(e,t){if(!t)return!0;t=t.split(",");for(var n=e.type,i=n.replace(/\/.*$/,""),r=0,o=o=t;;){if(r>=o.length)break;var a=o[r++];if("."===(a=a.trim()).charAt(0)){if(-1!==e.name.toLowerCase().indexOf(a.toLowerCase(),e.name.length-a.length))return!0}else if(/\/\*$/.test(a)){if(i===a.replace(/\/.*$/,""))return!0}else if(n===a)return!0}return!1},"undefined"!=typeof jQuery&&null!==jQuery&&(jQuery.fn.dropzone=function(e){return this.each(function(){return new o(this,e)})}),void 0!==e&&null!==e?e.exports=o:window.Dropzone=o,o.ADDED="added",o.QUEUED="queued",o.ACCEPTED=o.QUEUED,o.UPLOADING="uploading",o.PROCESSING=o.UPLOADING,o.CANCELED="canceled",o.ERROR="error",o.SUCCESS="success";var l=function(e,t,n,i,r,o,a,s,l,u){var d=function(e){e.naturalWidth;var t=e.naturalHeight,n=document.createElement("canvas");n.width=1,n.height=t;var i=n.getContext("2d");i.drawImage(e,0,0);for(var r=i.getImageData(1,0,1,t).data,o=0,a=t,s=t;s>o;)0===r[4*(s-1)+3]?a=s:o=s,s=a+o>>1;var l=s/t;return 0===l?1:l}(t);return e.drawImage(t,n,i,r,o,a,s,l,u/d)},u=function(){function e(){i(this,e)}return t(e,null,[{key:"initClass",value:function(){this.KEY_STR="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/="}},{key:"encode64",value:function(e){for(var t="",n=void 0,i=void 0,r="",o=void 0,a=void 0,s=void 0,l="",u=0;o=(n=e[u++])>>2,a=(3&n)<<4|(i=e[u++])>>4,s=(15&i)<<2|(r=e[u++])>>6,l=63&r,isNaN(i)?s=l=64:isNaN(r)&&(l=64),t=t+this.KEY_STR.charAt(o)+this.KEY_STR.charAt(a)+this.KEY_STR.charAt(s)+this.KEY_STR.charAt(l),n=i=r="",o=a=s=l="",ue.length)break}return n}},{key:"decode64",value:function(e){var t=void 0,n=void 0,i="",r=void 0,o=void 0,a="",s=0,l=[];for(/[^A-Za-z0-9\+\/\=]/g.exec(e),e=e.replace(/[^A-Za-z0-9\+\/\=]/g,"");t=this.KEY_STR.indexOf(e.charAt(s++))<<2|(r=this.KEY_STR.indexOf(e.charAt(s++)))>>4,n=(15&r)<<4|(o=this.KEY_STR.indexOf(e.charAt(s++)))>>2,i=(3&o)<<6|(a=this.KEY_STR.indexOf(e.charAt(s++))),l.push(t),64!==o&&l.push(n),64!==a&&l.push(i),t=n=i="",r=o=a="",s")+8,u=(s=s.substring(s.indexOf("4?p:t+8,a=[],l=0;l4?p:t+8,h-1);case 3:if(1==h)return e.getUint16(t+8,!r);for(o=h>2?p:t+8,a=[],l=0;le.byteLength)return{};var o=m(e,t,t+r,l,i);if(o.Compression)switch(o.Compression){case 6:if(o.JpegIFOffset&&o.JpegIFByteCount){var a=t+o.JpegIFOffset,s=o.JpegIFByteCount;o.blob=new Blob([new Uint8Array(e.buffer,a,s)],{type:"image/jpeg"})}}else o.PhotometricInterpretation;return o}(e,h,p,n),i}function y(e){var t={};if(1==e.nodeType){if(e.attributes.length>0){t["@attributes"]={};for(var n=0;n0)for(var n=0;n * @license MIT */ /**! * Sortable * @author RubaXa * @license MIT */ !function(o){"use strict";void 0===(r="function"==typeof(i=o)?i.call(t,n,t,e):i)||(e.exports=r)}(function(){"use strict";if("undefined"==typeof window||!window.document)return function(){throw new Error("Sortable.js requires a window with a document")};var e,t,n,i,r,o,a,s,l,u,d,c,h,p,f,m,g,v,b,y,k,w={},F=/\s+/g,C=/left|right|inline/,S="Sortable"+(new Date).getTime(),x=window,E=x.document,D=x.parseInt,_=x.setTimeout,T=x.jQuery||x.Zepto,P=x.Polymer,I=!1,U="draggable"in E.createElement("div"),z=!navigator.userAgent.match(/(?:Trident.*rv[ :]?11\.|msie)/i)&&((k=E.createElement("x")).style.cssText="pointer-events:auto","auto"===k.style.pointerEvents),L=!1,A=Math.abs,M=Math.min,R=[],N=[],O=ie(function(e,t,n){if(n&&t.scroll){var i,r,o,a,d,c,h=n[S],p=t.scrollSensitivity,f=t.scrollSpeed,m=e.clientX,g=e.clientY,v=window.innerWidth,b=window.innerHeight;if(l!==n&&(s=t.scroll,l=n,u=t.scrollFn,!0===s)){s=n;do{if(s.offsetWidth-1:r==e)}}var n={},i=e.group;i&&"object"==typeof i||(i={name:i}),n.name=i.name,n.checkPull=t(i.pull,!0),n.checkPut=t(i.put),n.revertClone=i.revertClone,e.group=n};try{window.addEventListener("test",null,Object.defineProperty({},"passive",{get:function(){I={capture:!1,passive:!1}}}))}catch(e){}function G(e,t){if(!e||!e.nodeType||1!==e.nodeType)throw"Sortable: `el` must be HTMLElement, and not "+{}.toString.call(e);this.el=e,this.options=t=re({},t),e[S]=this;var n={group:Math.random(),sort:!0,disabled:!1,store:null,handle:null,scroll:!0,scrollSensitivity:30,scrollSpeed:10,draggable:/[uo]l/i.test(e.nodeName)?"li":">*",ghostClass:"sortable-ghost",chosenClass:"sortable-chosen",dragClass:"sortable-drag",ignore:"a, img",filter:null,preventOnFilter:!0,animation:0,setData:function(e,t){e.setData("Text",t.textContent)},dropBubble:!1,dragoverBubble:!1,dataIdAttr:"data-id",delay:0,forceFallback:!1,fallbackClass:"sortable-fallback",fallbackOnBody:!1,fallbackTolerance:0,fallbackOffset:{x:0,y:0},supportPointer:!1!==G.supportPointer};for(var i in n)!(i in t)&&(t[i]=n[i]);for(var r in B(t),this)"_"===r.charAt(0)&&"function"==typeof this[r]&&(this[r]=this[r].bind(this));this.nativeDraggable=!t.forceFallback&&U,W(e,"mousedown",this._onTapStart),W(e,"touchstart",this._onTapStart),t.supportPointer&&W(e,"pointerdown",this._onTapStart),this.nativeDraggable&&(W(e,"dragover",this),W(e,"dragenter",this)),N.push(this._onDragOver),t.store&&this.sort(t.store.get(this))}function Y(t,n){"clone"!==t.lastPullMode&&(n=!0),i&&i.state!==n&&(Q(i,"display",n?"none":""),n||i.state&&(t.options.group.revertClone?(r.insertBefore(i,o),t._animate(e,i)):r.insertBefore(i,e)),i.state=n)}function H(e,t,n){if(e){n=n||E;do{if(">*"===t&&e.parentNode===n||ne(e,t))return e}while(e=X(e))}return null}function X(e){var t=e.host;return t&&t.nodeType?t:e.parentNode}function W(e,t,n){e.addEventListener(t,n,I)}function j(e,t,n){e.removeEventListener(t,n,I)}function q(e,t,n){if(e)if(e.classList)e.classList[n?"add":"remove"](t);else{var i=(" "+e.className+" ").replace(F," ").replace(" "+t+" "," ");e.className=(i+(n?" "+t:"")).replace(F," ")}}function Q(e,t,n){var i=e&&e.style;if(i){if(void 0===n)return E.defaultView&&E.defaultView.getComputedStyle?n=E.defaultView.getComputedStyle(e,""):e.currentStyle&&(n=e.currentStyle),void 0===t?n:n[t];t in i||(t="-webkit-"+t),i[t]=n+("string"==typeof n?"":"px")}}function V(e,t,n){if(e){var i=e.getElementsByTagName(t),r=0,o=i.length;if(n)for(;r*"!==t&&!ne(e,t)||n++;return n}function ne(e,t){if(e){var n=(t=t.split(".")).shift().toUpperCase(),i=new RegExp("\\s("+t.join("|")+")(?=\\s)","g");return!(""!==n&&e.nodeName.toUpperCase()!=n||t.length&&((" "+e.className+" ").match(i)||[]).length!=t.length)}return!1}function ie(e,t){var n,i;return function(){void 0===n&&(n=arguments,i=this,_(function(){1===n.length?e.call(i,n[0]):e.apply(i,n),n=void 0},t))}}function re(e,t){if(e&&t)for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n]);return e}function oe(e){return P&&P.dom?P.dom(e).cloneNode(!0):T?T(e).clone(!0)[0]:e.cloneNode(!0)}function ae(e){return _(e,0)}function se(e){return clearTimeout(e)}return G.prototype={constructor:G,_onTapStart:function(t){var n,i=this,r=this.el,o=this.options,s=o.preventOnFilter,l=t.type,u=t.touches&&t.touches[0],d=(u||t).target,c=t.target.shadowRoot&&t.path&&t.path[0]||d,h=o.filter;if(function(e){var t=e.getElementsByTagName("input"),n=t.length;for(;n--;){var i=t[n];i.checked&&R.push(i)}}(r),!e&&!(/mousedown|pointerdown/.test(l)&&0!==t.button||o.disabled)&&!c.isContentEditable&&(d=H(d,o.draggable,r))&&a!==d){if(n=te(d,o.draggable),"function"==typeof h){if(h.call(this,t,d,this))return K(i,c,"filter",d,r,r,n),void(s&&t.preventDefault())}else if(h&&(h=h.split(",").some(function(e){if(e=H(c,e.trim(),r))return K(i,e,"filter",d,r,r,n),!0})))return void(s&&t.preventDefault());o.handle&&!H(c,o.handle,r)||this._prepareDragStart(t,u,d,n)}},_prepareDragStart:function(n,i,s,l){var u,d=this,c=d.el,h=d.options,f=c.ownerDocument;s&&!e&&s.parentNode===c&&(v=n,r=c,t=(e=s).parentNode,o=e.nextSibling,a=s,m=h.group,p=l,this._lastX=(i||n).clientX,this._lastY=(i||n).clientY,e.style["will-change"]="all",u=function(){d._disableDelayedDrag(),e.draggable=d.nativeDraggable,q(e,h.chosenClass,!0),d._triggerDragStart(n,i),K(d,r,"choose",e,r,r,p)},h.ignore.split(",").forEach(function(t){V(e,t.trim(),Z)}),W(f,"mouseup",d._onDrop),W(f,"touchend",d._onDrop),W(f,"touchcancel",d._onDrop),W(f,"selectstart",d),h.supportPointer&&W(f,"pointercancel",d._onDrop),h.delay?(W(f,"mouseup",d._disableDelayedDrag),W(f,"touchend",d._disableDelayedDrag),W(f,"touchcancel",d._disableDelayedDrag),W(f,"mousemove",d._disableDelayedDrag),W(f,"touchmove",d._disableDelayedDrag),h.supportPointer&&W(f,"pointermove",d._disableDelayedDrag),d._dragStartTimer=_(u,h.delay)):u())},_disableDelayedDrag:function(){var e=this.el.ownerDocument;clearTimeout(this._dragStartTimer),j(e,"mouseup",this._disableDelayedDrag),j(e,"touchend",this._disableDelayedDrag),j(e,"touchcancel",this._disableDelayedDrag),j(e,"mousemove",this._disableDelayedDrag),j(e,"touchmove",this._disableDelayedDrag),j(e,"pointermove",this._disableDelayedDrag)},_triggerDragStart:function(t,n){(n=n||("touch"==t.pointerType?t:null))?(v={target:e,clientX:n.clientX,clientY:n.clientY},this._onDragStart(v,"touch")):this.nativeDraggable?(W(e,"dragend",this),W(r,"dragstart",this._onDragStart)):this._onDragStart(v,!0);try{E.selection?ae(function(){E.selection.empty()}):window.getSelection().removeAllRanges()}catch(e){}},_dragStarted:function(){if(r&&e){var t=this.options;q(e,t.ghostClass,!0),q(e,t.dragClass,!1),G.active=this,K(this,r,"start",e,r,r,p)}else this._nulling()},_emulateDragOver:function(){if(b){if(this._lastX===b.clientX&&this._lastY===b.clientY)return;this._lastX=b.clientX,this._lastY=b.clientY,z||Q(n,"display","none");var e=E.elementFromPoint(b.clientX,b.clientY),t=e,i=N.length;if(e&&e.shadowRoot&&(t=e=e.shadowRoot.elementFromPoint(b.clientX,b.clientY)),t)do{if(t[S]){for(;i--;)N[i]({clientX:b.clientX,clientY:b.clientY,target:e,rootEl:t});break}e=t}while(t=t.parentNode);z||Q(n,"display","")}},_onTouchMove:function(e){if(v){var t=this.options,i=t.fallbackTolerance,r=t.fallbackOffset,o=e.touches?e.touches[0]:e,a=o.clientX-v.clientX+r.x,s=o.clientY-v.clientY+r.y,l=e.touches?"translate3d("+a+"px,"+s+"px,0)":"translate("+a+"px,"+s+"px)";if(!G.active){if(i&&M(A(o.clientX-this._lastX),A(o.clientY-this._lastY))5||t.clientX-(n.left+n.width)>5}(f,a)){if(0!==f.children.length&&f.children[0]!==n&&f===a.target&&(s=f.lastElementChild),s){if(s.animated)return;u=s.getBoundingClientRect()}Y(k,w),!1!==J(r,f,e,l,s,u,a)&&(e.contains(f)||(f.appendChild(e),t=f),this._animate(l,e),s&&this._animate(u,s))}else if(s&&!s.animated&&s!==e&&void 0!==s.parentNode[S]){d!==s&&(d=s,c=Q(s),h=Q(s.parentNode));var E=(u=s.getBoundingClientRect()).right-u.left,D=u.bottom-u.top,T=C.test(c.cssFloat+c.display)||"flex"==h.display&&0===h["flex-direction"].indexOf("row"),P=s.offsetWidth>e.offsetWidth,I=s.offsetHeight>e.offsetHeight,U=(T?(a.clientX-u.left)/E:(a.clientY-u.top)/D)>.5,z=s.nextElementSibling,A=!1;if(T){var M=e.offsetTop,R=s.offsetTop;A=M===R?s.previousElementSibling===e&&!P||U&&P:s.previousElementSibling===e||e.previousElementSibling===s?(a.clientY-u.top)/D>.5:R>M}else F||(A=z!==e&&!I||U&&I);var N=J(r,f,e,l,s,u,a,A);!1!==N&&(1!==N&&-1!==N||(A=1===N),L=!0,_($,30),Y(k,w),e.contains(f)||(A&&!z?f.appendChild(e):s.parentNode.insertBefore(e,A?z:s)),t=e.parentNode,this._animate(l,e),this._animate(u,s))}}},_animate:function(e,t){var n=this.options.animation;if(n){var i=t.getBoundingClientRect();1===e.nodeType&&(e=e.getBoundingClientRect()),Q(t,"transition","none"),Q(t,"transform","translate3d("+(e.left-i.left)+"px,"+(e.top-i.top)+"px,0)"),t.offsetWidth,Q(t,"transition","all "+n+"ms"),Q(t,"transform","translate3d(0,0,0)"),clearTimeout(t.animated),t.animated=_(function(){Q(t,"transition",""),Q(t,"transform",""),t.animated=!1},n)}},_offUpEvents:function(){var e=this.el.ownerDocument;j(E,"touchmove",this._onTouchMove),j(E,"pointermove",this._onTouchMove),j(e,"mouseup",this._onDrop),j(e,"touchend",this._onDrop),j(e,"pointerup",this._onDrop),j(e,"touchcancel",this._onDrop),j(e,"pointercancel",this._onDrop),j(e,"selectstart",this)},_onDrop:function(a){var s=this.el,l=this.options;clearInterval(this._loopId),clearInterval(w.pid),clearTimeout(this._dragStartTimer),se(this._cloneId),se(this._dragStartId),j(E,"mouseover",this),j(E,"mousemove",this._onTouchMove),this.nativeDraggable&&(j(E,"drop",this),j(s,"dragstart",this._onDragStart)),this._offUpEvents(),a&&(y&&(a.preventDefault(),!l.dropBubble&&a.stopPropagation()),n&&n.parentNode&&n.parentNode.removeChild(n),r!==t&&"clone"===G.active.lastPullMode||i&&i.parentNode&&i.parentNode.removeChild(i),e&&(this.nativeDraggable&&j(e,"dragend",this),Z(e),e.style["will-change"]="",q(e,this.options.ghostClass,!1),q(e,this.options.chosenClass,!1),K(this,r,"unchoose",e,t,r,p),r!==t?(f=te(e,l.draggable))>=0&&(K(null,t,"add",e,t,r,p,f),K(this,r,"remove",e,t,r,p,f),K(null,t,"sort",e,t,r,p,f),K(this,r,"sort",e,t,r,p,f)):e.nextSibling!==o&&(f=te(e,l.draggable))>=0&&(K(this,r,"update",e,t,r,p,f),K(this,r,"sort",e,t,r,p,f)),G.active&&(null!=f&&-1!==f||(f=p),K(this,r,"end",e,t,r,p,f),this.save()))),this._nulling()},_nulling:function(){r=e=t=n=o=i=a=s=l=v=b=y=f=d=c=g=m=G.active=null,R.forEach(function(e){e.checked=!0}),R.length=0},handleEvent:function(t){switch(t.type){case"drop":case"dragend":this._onDrop(t);break;case"dragover":case"dragenter":e&&(this._onDragOver(t),function(e){e.dataTransfer&&(e.dataTransfer.dropEffect="move");e.preventDefault()}(t));break;case"mouseover":this._onDrop(t);break;case"selectstart":t.preventDefault()}},toArray:function(){for(var e,t=[],n=this.el.children,i=0,r=n.length,o=this.options;i