(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["chunk-e3c7a600"],{"0358":function(t,e,r){(function(e){t.exports=e()})((function(t){"use strict";var e=["0","1","2","3","4","5","6","7","8","9","a","b","c","d","e","f"];function r(t,e){var r=t[0],n=t[1],o=t[2],i=t[3];r+=(n&o|~n&i)+e[0]-680876936|0,r=(r<<7|r>>>25)+n|0,i+=(r&n|~r&o)+e[1]-389564586|0,i=(i<<12|i>>>20)+r|0,o+=(i&r|~i&n)+e[2]+606105819|0,o=(o<<17|o>>>15)+i|0,n+=(o&i|~o&r)+e[3]-1044525330|0,n=(n<<22|n>>>10)+o|0,r+=(n&o|~n&i)+e[4]-176418897|0,r=(r<<7|r>>>25)+n|0,i+=(r&n|~r&o)+e[5]+1200080426|0,i=(i<<12|i>>>20)+r|0,o+=(i&r|~i&n)+e[6]-1473231341|0,o=(o<<17|o>>>15)+i|0,n+=(o&i|~o&r)+e[7]-45705983|0,n=(n<<22|n>>>10)+o|0,r+=(n&o|~n&i)+e[8]+1770035416|0,r=(r<<7|r>>>25)+n|0,i+=(r&n|~r&o)+e[9]-1958414417|0,i=(i<<12|i>>>20)+r|0,o+=(i&r|~i&n)+e[10]-42063|0,o=(o<<17|o>>>15)+i|0,n+=(o&i|~o&r)+e[11]-1990404162|0,n=(n<<22|n>>>10)+o|0,r+=(n&o|~n&i)+e[12]+1804603682|0,r=(r<<7|r>>>25)+n|0,i+=(r&n|~r&o)+e[13]-40341101|0,i=(i<<12|i>>>20)+r|0,o+=(i&r|~i&n)+e[14]-1502002290|0,o=(o<<17|o>>>15)+i|0,n+=(o&i|~o&r)+e[15]+1236535329|0,n=(n<<22|n>>>10)+o|0,r+=(n&i|o&~i)+e[1]-165796510|0,r=(r<<5|r>>>27)+n|0,i+=(r&o|n&~o)+e[6]-1069501632|0,i=(i<<9|i>>>23)+r|0,o+=(i&n|r&~n)+e[11]+643717713|0,o=(o<<14|o>>>18)+i|0,n+=(o&r|i&~r)+e[0]-373897302|0,n=(n<<20|n>>>12)+o|0,r+=(n&i|o&~i)+e[5]-701558691|0,r=(r<<5|r>>>27)+n|0,i+=(r&o|n&~o)+e[10]+38016083|0,i=(i<<9|i>>>23)+r|0,o+=(i&n|r&~n)+e[15]-660478335|0,o=(o<<14|o>>>18)+i|0,n+=(o&r|i&~r)+e[4]-405537848|0,n=(n<<20|n>>>12)+o|0,r+=(n&i|o&~i)+e[9]+568446438|0,r=(r<<5|r>>>27)+n|0,i+=(r&o|n&~o)+e[14]-1019803690|0,i=(i<<9|i>>>23)+r|0,o+=(i&n|r&~n)+e[3]-187363961|0,o=(o<<14|o>>>18)+i|0,n+=(o&r|i&~r)+e[8]+1163531501|0,n=(n<<20|n>>>12)+o|0,r+=(n&i|o&~i)+e[13]-1444681467|0,r=(r<<5|r>>>27)+n|0,i+=(r&o|n&~o)+e[2]-51403784|0,i=(i<<9|i>>>23)+r|0,o+=(i&n|r&~n)+e[7]+1735328473|0,o=(o<<14|o>>>18)+i|0,n+=(o&r|i&~r)+e[12]-1926607734|0,n=(n<<20|n>>>12)+o|0,r+=(n^o^i)+e[5]-378558|0,r=(r<<4|r>>>28)+n|0,i+=(r^n^o)+e[8]-2022574463|0,i=(i<<11|i>>>21)+r|0,o+=(i^r^n)+e[11]+1839030562|0,o=(o<<16|o>>>16)+i|0,n+=(o^i^r)+e[14]-35309556|0,n=(n<<23|n>>>9)+o|0,r+=(n^o^i)+e[1]-1530992060|0,r=(r<<4|r>>>28)+n|0,i+=(r^n^o)+e[4]+1272893353|0,i=(i<<11|i>>>21)+r|0,o+=(i^r^n)+e[7]-155497632|0,o=(o<<16|o>>>16)+i|0,n+=(o^i^r)+e[10]-1094730640|0,n=(n<<23|n>>>9)+o|0,r+=(n^o^i)+e[13]+681279174|0,r=(r<<4|r>>>28)+n|0,i+=(r^n^o)+e[0]-358537222|0,i=(i<<11|i>>>21)+r|0,o+=(i^r^n)+e[3]-722521979|0,o=(o<<16|o>>>16)+i|0,n+=(o^i^r)+e[6]+76029189|0,n=(n<<23|n>>>9)+o|0,r+=(n^o^i)+e[9]-640364487|0,r=(r<<4|r>>>28)+n|0,i+=(r^n^o)+e[12]-421815835|0,i=(i<<11|i>>>21)+r|0,o+=(i^r^n)+e[15]+530742520|0,o=(o<<16|o>>>16)+i|0,n+=(o^i^r)+e[2]-995338651|0,n=(n<<23|n>>>9)+o|0,r+=(o^(n|~i))+e[0]-198630844|0,r=(r<<6|r>>>26)+n|0,i+=(n^(r|~o))+e[7]+1126891415|0,i=(i<<10|i>>>22)+r|0,o+=(r^(i|~n))+e[14]-1416354905|0,o=(o<<15|o>>>17)+i|0,n+=(i^(o|~r))+e[5]-57434055|0,n=(n<<21|n>>>11)+o|0,r+=(o^(n|~i))+e[12]+1700485571|0,r=(r<<6|r>>>26)+n|0,i+=(n^(r|~o))+e[3]-1894986606|0,i=(i<<10|i>>>22)+r|0,o+=(r^(i|~n))+e[10]-1051523|0,o=(o<<15|o>>>17)+i|0,n+=(i^(o|~r))+e[1]-2054922799|0,n=(n<<21|n>>>11)+o|0,r+=(o^(n|~i))+e[8]+1873313359|0,r=(r<<6|r>>>26)+n|0,i+=(n^(r|~o))+e[15]-30611744|0,i=(i<<10|i>>>22)+r|0,o+=(r^(i|~n))+e[6]-1560198380|0,o=(o<<15|o>>>17)+i|0,n+=(i^(o|~r))+e[13]+1309151649|0,n=(n<<21|n>>>11)+o|0,r+=(o^(n|~i))+e[4]-145523070|0,r=(r<<6|r>>>26)+n|0,i+=(n^(r|~o))+e[11]-1120210379|0,i=(i<<10|i>>>22)+r|0,o+=(r^(i|~n))+e[2]+718787259|0,o=(o<<15|o>>>17)+i|0,n+=(i^(o|~r))+e[9]-343485551|0,n=(n<<21|n>>>11)+o|0,t[0]=r+t[0]|0,t[1]=n+t[1]|0,t[2]=o+t[2]|0,t[3]=i+t[3]|0}function n(t){var e,r=[];for(e=0;e<64;e+=4)r[e>>2]=t.charCodeAt(e)+(t.charCodeAt(e+1)<<8)+(t.charCodeAt(e+2)<<16)+(t.charCodeAt(e+3)<<24);return r}function o(t){var e,r=[];for(e=0;e<64;e+=4)r[e>>2]=t[e]+(t[e+1]<<8)+(t[e+2]<<16)+(t[e+3]<<24);return r}function i(t){var e,o,i,a,s,c,u=t.length,h=[1732584193,-271733879,-1732584194,271733878];for(e=64;e<=u;e+=64)r(h,n(t.substring(e-64,e)));for(t=t.substring(e-64),o=t.length,i=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],e=0;e>2]|=t.charCodeAt(e)<<(e%4<<3);if(i[e>>2]|=128<<(e%4<<3),e>55)for(r(h,i),e=0;e<16;e+=1)i[e]=0;return a=8*u,a=a.toString(16).match(/(.*?)(.{0,8})$/),s=parseInt(a[2],16),c=parseInt(a[1],16)||0,i[14]=s,i[15]=c,r(h,i),h}function a(t){var e,n,i,a,s,c,u=t.length,h=[1732584193,-271733879,-1732584194,271733878];for(e=64;e<=u;e+=64)r(h,o(t.subarray(e-64,e)));for(t=e-64>2]|=t[e]<<(e%4<<3);if(i[e>>2]|=128<<(e%4<<3),e>55)for(r(h,i),e=0;e<16;e+=1)i[e]=0;return a=8*u,a=a.toString(16).match(/(.*?)(.{0,8})$/),s=parseInt(a[2],16),c=parseInt(a[1],16)||0,i[14]=s,i[15]=c,r(h,i),h}function s(t){var r,n="";for(r=0;r<4;r+=1)n+=e[t>>8*r+4&15]+e[t>>8*r&15];return n}function c(t){var e;for(e=0;e>16)+(e>>16)+(r>>16);return n<<16|65535&r},"undefined"===typeof ArrayBuffer||ArrayBuffer.prototype.slice||function(){function e(t,e){return t=0|t||0,t<0?Math.max(t+e,0):Math.min(t,e)}ArrayBuffer.prototype.slice=function(r,n){var o,i,a,s,c=this.byteLength,u=e(r,c),h=c;return n!==t&&(h=e(n,c)),u>h?new ArrayBuffer(0):(o=h-u,i=new ArrayBuffer(o),a=new Uint8Array(i),s=new Uint8Array(this,u,o),a.set(s),i)}}(),d.prototype.append=function(t){return this.appendBinary(u(t)),this},d.prototype.appendBinary=function(t){this._buff+=t,this._length+=t.length;var e,o=this._buff.length;for(e=64;e<=o;e+=64)r(this._hash,n(this._buff.substring(e-64,e)));return this._buff=this._buff.substring(e-64),this},d.prototype.end=function(t){var e,r,n=this._buff,o=n.length,i=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0];for(e=0;e>2]|=n.charCodeAt(e)<<(e%4<<3);return this._finish(i,o),r=c(this._hash),t&&(r=p(r)),this.reset(),r},d.prototype.reset=function(){return this._buff="",this._length=0,this._hash=[1732584193,-271733879,-1732584194,271733878],this},d.prototype.getState=function(){return{buff:this._buff,length:this._length,hash:this._hash.slice()}},d.prototype.setState=function(t){return this._buff=t.buff,this._length=t.length,this._hash=t.hash,this},d.prototype.destroy=function(){delete this._hash,delete this._buff,delete this._length},d.prototype._finish=function(t,e){var n,o,i,a=e;if(t[a>>2]|=128<<(a%4<<3),a>55)for(r(this._hash,t),a=0;a<16;a+=1)t[a]=0;n=8*this._length,n=n.toString(16).match(/(.*?)(.{0,8})$/),o=parseInt(n[2],16),i=parseInt(n[1],16)||0,t[14]=o,t[15]=i,r(this._hash,t)},d.hash=function(t,e){return d.hashBinary(u(t),e)},d.hashBinary=function(t,e){var r=i(t),n=c(r);return e?p(n):n},d.ArrayBuffer=function(){this.reset()},d.ArrayBuffer.prototype.append=function(t){var e,n=f(this._buff.buffer,t,!0),i=n.length;for(this._length+=t.byteLength,e=64;e<=i;e+=64)r(this._hash,o(n.subarray(e-64,e)));return this._buff=e-64>2]|=n[e]<<(e%4<<3);return this._finish(i,o),r=c(this._hash),t&&(r=p(r)),this.reset(),r},d.ArrayBuffer.prototype.reset=function(){return this._buff=new Uint8Array(0),this._length=0,this._hash=[1732584193,-271733879,-1732584194,271733878],this},d.ArrayBuffer.prototype.getState=function(){var t=d.prototype.getState.call(this);return t.buff=l(t.buff),t},d.ArrayBuffer.prototype.setState=function(t){return t.buff=h(t.buff,!0),d.prototype.setState.call(this,t)},d.ArrayBuffer.prototype.destroy=d.prototype.destroy,d.ArrayBuffer.prototype._finish=d.prototype._finish,d.ArrayBuffer.hash=function(t,e){var r=a(new Uint8Array(t)),n=c(r);return e?p(n):n},d}))},"053b":function(t,e,r){var n=r("1e2c"),o=r("d910").f,i=Function.prototype,a=i.toString,s=/^\s*function ([^ (]*)/,c="name";n&&!(c in i)&&o(i,c,{configurable:!0,get:function(){try{return a.call(this).match(s)[1]}catch(t){return""}}})},"064b":function(t,e){t.exports={CSSRuleList:0,CSSStyleDeclaration:0,CSSValueList:0,ClientRectList:0,DOMRectList:0,DOMStringList:0,DOMTokenList:1,DataTransferItemList:0,FileList:0,HTMLAllCollection:0,HTMLCollection:0,HTMLFormElement:0,HTMLSelectElement:0,MediaList:0,MimeTypeArray:0,NamedNodeMap:0,NodeList:1,PaintRequestList:0,Plugin:0,PluginArray:0,SVGLengthList:0,SVGNumberList:0,SVGPathSegList:0,SVGPointList:0,SVGStringList:0,SVGTransformList:0,SourceBufferList:0,StyleSheetList:0,TextTrackCueList:0,TextTrackList:0,TouchList:0}},"0689":function(t,e,r){},"07a2":function(t,e,r){var n=r("8a1c");t.exports=function(t){if(n(t))throw TypeError("The method doesn't accept regular expressions");return t}},"08ba":function(t,e,r){var n=r("d890"),o=r("064b"),i=r("3c10"),a=r("0fc1");for(var s in o){var c=n[s],u=c&&c.prototype;if(u&&u.forEach!==i)try{a(u,"forEach",i)}catch(h){u.forEach=i}}},"0a0a":function(t,e,r){"use strict";var n=r("edba"),o=r.n(n);o.a},"0a51":function(t,e,r){"use strict";var n=r("1c8b"),o=r("1e2c"),i=r("d890"),a=r("faa8"),s=r("a719"),c=r("d910").f,u=r("c69d"),h=i.Symbol;if(o&&"function"==typeof h&&(!("description"in h.prototype)||void 0!==h().description)){var l={},f=function(){var t=arguments.length<1||void 0===arguments[0]?void 0:String(arguments[0]),e=this instanceof f?new h(t):void 0===t?h():h(t);return""===t&&(l[e]=!0),e};u(f,h);var p=f.prototype=h.prototype;p.constructor=f;var d=p.toString,g="Symbol(test)"==String(h("test")),m=/^Symbol\((.*)\)[^)]+$/;c(p,"description",{configurable:!0,get:function(){var t=s(this)?this.valueOf():this,e=d.call(t);if(a(l,t))return"";var r=g?e.slice(7,-1):e.replace(m,"$1");return""===r?void 0:r}}),n({global:!0,forced:!0},{Symbol:f})}},"0d7a":function(t,e,r){"use strict";var n=r("b2a2"),o=r("8a1c"),i=r("857c"),a=r("2732"),s=r("ef4c"),c=r("38eb"),u=r("d88d"),h=r("59da"),l=r("5139"),f=r("efe2"),p=[].push,d=Math.min,g=4294967295,m=!f((function(){return!RegExp(g,"y")}));n("split",2,(function(t,e,r){var n;return n="c"=="abbc".split(/(b)*/)[1]||4!="test".split(/(?:)/,-1).length||2!="ab".split(/(?:ab)*/).length||4!=".".split(/(.?)(.?)/).length||".".split(/()()/).length>1||"".split(/.?/).length?function(t,r){var n=String(a(this)),i=void 0===r?g:r>>>0;if(0===i)return[];if(void 0===t)return[n];if(!o(t))return e.call(n,t,i);var s,c,u,h=[],f=(t.ignoreCase?"i":"")+(t.multiline?"m":"")+(t.unicode?"u":"")+(t.sticky?"y":""),d=0,m=new RegExp(t.source,f+"g");while(s=l.call(m,n)){if(c=m.lastIndex,c>d&&(h.push(n.slice(d,s.index)),s.length>1&&s.index=i))break;m.lastIndex===s.index&&m.lastIndex++}return d===n.length?!u&&m.test("")||h.push(""):h.push(n.slice(d)),h.length>i?h.slice(0,i):h}:"0".split(void 0,0).length?function(t,r){return void 0===t&&0===r?[]:e.call(this,t,r)}:e,[function(e,r){var o=a(this),i=void 0==e?void 0:e[t];return void 0!==i?i.call(e,o,r):n.call(String(o),e,r)},function(t,o){var a=r(n,t,this,o,n!==e);if(a.done)return a.value;var l=i(t),f=String(this),p=s(l,RegExp),v=l.unicode,y=(l.ignoreCase?"i":"")+(l.multiline?"m":"")+(l.unicode?"u":"")+(m?"y":"g"),w=new p(m?l:"^(?:"+l.source+")",y),b=void 0===o?g:o>>>0;if(0===b)return[];if(0===f.length)return null===h(w,f)?[f]:[];var x=0,C=0,I=[];while(C2?arguments[2]:void 0,l=a((void 0===h?s:o(h,s))-u,s-c),f=1;u0)u in r?r[c]=r[u]:delete r[c],c+=f,u+=f;return r}},"1bb1":function(t,e,r){"use strict";var n=r("d890"),o=r("5a9e"),i=r("efe2"),a=n.Int8Array,s=o.aTypedArray,c=o.exportTypedArrayMethod,u=[].toLocaleString,h=[].slice,l=!!a&&i((function(){u.call(new a(1))})),f=i((function(){return[1,2].toLocaleString()!=new a([1,2]).toLocaleString()}))||!i((function(){a.prototype.toLocaleString.call([1,2])}));c("toLocaleString",(function(){return u.apply(l?h.call(s(this)):s(this),arguments)}),f)},"1bbd":function(t,e,r){"use strict";var n=r("9f67"),o=r("d910"),i=r("38b9");t.exports=function(t,e,r){var a=n(e);a in t?o.f(t,a,i(0,r)):t[a]=r}},"1c2e9":function(t,e,r){"use strict";var n=r("d890"),o=r("1e2c"),i=r("d77f"),a=r("0fc1"),s=r("99ab"),c=r("efe2"),u=r("c4e4"),h=r("3da3"),l=r("d88d"),f=r("3ccd"),p=r("e026"),d=r("908e"),g=r("50fb"),m=r("b338").f,v=r("d910").f,y=r("fa41"),w=r("27b5"),b=r("b702"),x=b.get,C=b.set,I="ArrayBuffer",S="DataView",B="prototype",O="Wrong length",A="Wrong index",T=n[I],k=T,E=n[S],M=E&&E[B],L=Object.prototype,P=n.RangeError,_=p.pack,U=p.unpack,R=function(t){return[255&t]},F=function(t){return[255&t,t>>8&255]},N=function(t){return[255&t,t>>8&255,t>>16&255,t>>24&255]},D=function(t){return t[3]<<24|t[2]<<16|t[1]<<8|t[0]},j=function(t){return _(t,23,4)},H=function(t){return _(t,52,8)},W=function(t,e){v(t[B],e,{get:function(){return x(this)[e]}})},X=function(t,e,r,n){var o=f(r),i=x(t);if(o+e>i.byteLength)throw P(A);var a=x(i.buffer).bytes,s=o+i.byteOffset,c=a.slice(s,s+e);return n?c:c.reverse()},Y=function(t,e,r,n,o,i){var a=f(r),s=x(t);if(a+e>s.byteLength)throw P(A);for(var c=x(s.buffer).bytes,u=a+s.byteOffset,h=n(+o),l=0;l$;)(z=q[$++])in k||a(k,z,T[z]);G.constructor=k}g&&d(M)!==L&&g(M,L);var V=new E(new k(2)),J=M.setInt8;V.setInt8(0,2147483648),V.setInt8(1,2147483649),!V.getInt8(0)&&V.getInt8(1)||s(M,{setInt8:function(t,e){J.call(this,t,e<<24>>24)},setUint8:function(t,e){J.call(this,t,e<<24>>24)}},{unsafe:!0})}else k=function(t){u(this,k,I);var e=f(t);C(this,{bytes:y.call(new Array(e),0),byteLength:e}),o||(this.byteLength=e)},E=function(t,e,r){u(this,E,S),u(t,k,S);var n=x(t).byteLength,i=h(e);if(i<0||i>n)throw P("Wrong offset");if(r=void 0===r?n-i:l(r),i+r>n)throw P(O);C(this,{buffer:t,byteLength:r,byteOffset:i}),o||(this.buffer=t,this.byteLength=r,this.byteOffset=i)},o&&(W(k,"byteLength"),W(E,"buffer"),W(E,"byteLength"),W(E,"byteOffset")),s(E[B],{getInt8:function(t){return X(this,1,t)[0]<<24>>24},getUint8:function(t){return X(this,1,t)[0]},getInt16:function(t){var e=X(this,2,t,arguments.length>1?arguments[1]:void 0);return(e[1]<<8|e[0])<<16>>16},getUint16:function(t){var e=X(this,2,t,arguments.length>1?arguments[1]:void 0);return e[1]<<8|e[0]},getInt32:function(t){return D(X(this,4,t,arguments.length>1?arguments[1]:void 0))},getUint32:function(t){return D(X(this,4,t,arguments.length>1?arguments[1]:void 0))>>>0},getFloat32:function(t){return U(X(this,4,t,arguments.length>1?arguments[1]:void 0),23)},getFloat64:function(t){return U(X(this,8,t,arguments.length>1?arguments[1]:void 0),52)},setInt8:function(t,e){Y(this,1,t,R,e)},setUint8:function(t,e){Y(this,1,t,R,e)},setInt16:function(t,e){Y(this,2,t,F,e,arguments.length>2?arguments[2]:void 0)},setUint16:function(t,e){Y(this,2,t,F,e,arguments.length>2?arguments[2]:void 0)},setInt32:function(t,e){Y(this,4,t,N,e,arguments.length>2?arguments[2]:void 0)},setUint32:function(t,e){Y(this,4,t,N,e,arguments.length>2?arguments[2]:void 0)},setFloat32:function(t,e){Y(this,4,t,j,e,arguments.length>2?arguments[2]:void 0)},setFloat64:function(t,e){Y(this,8,t,H,e,arguments.length>2?arguments[2]:void 0)}});w(k,I),w(E,S),t.exports={ArrayBuffer:k,DataView:E}},"1cc1":function(t,e,r){"use strict";var n=r("5a9e"),o=r("5dfd").find,i=n.aTypedArray,a=n.exportTypedArrayMethod;a("find",(function(t){return o(i(this),t,arguments.length>1?arguments[1]:void 0)}))},"26a2":function(t,e,r){"use strict";var n=r("1c8b"),o=r("d890"),i=r("1e2c"),a=r("a4c7"),s=r("5a9e"),c=r("1c2e9"),u=r("c4e4"),h=r("38b9"),l=r("0fc1"),f=r("d88d"),p=r("3ccd"),d=r("7aeb"),g=r("9f67"),m=r("faa8"),v=r("2a91"),y=r("a719"),w=r("6d60"),b=r("50fb"),x=r("b338").f,C=r("6f82"),I=r("5dfd").forEach,S=r("403f"),B=r("d910"),O=r("aa6b"),A=r("b702"),T=r("7063"),k=A.get,E=A.set,M=B.f,L=O.f,P=Math.round,_=o.RangeError,U=c.ArrayBuffer,R=c.DataView,F=s.NATIVE_ARRAY_BUFFER_VIEWS,N=s.TYPED_ARRAY_TAG,D=s.TypedArray,j=s.TypedArrayPrototype,H=s.aTypedArrayConstructor,W=s.isTypedArray,X="BYTES_PER_ELEMENT",Y="Wrong length",z=function(t,e){var r=0,n=e.length,o=new(H(t))(n);while(n>r)o[r]=e[r++];return o},G=function(t,e){M(t,e,{get:function(){return k(this)[e]}})},q=function(t){var e;return t instanceof U||"ArrayBuffer"==(e=v(t))||"SharedArrayBuffer"==e},$=function(t,e){return W(t)&&"symbol"!=typeof e&&e in t&&String(+e)==String(e)},V=function(t,e){return $(t,e=g(e,!0))?h(2,t[e]):L(t,e)},J=function(t,e,r){return!($(t,e=g(e,!0))&&y(r)&&m(r,"value"))||m(r,"get")||m(r,"set")||r.configurable||m(r,"writable")&&!r.writable||m(r,"enumerable")&&!r.enumerable?M(t,e,r):(t[e]=r.value,t)};i?(F||(O.f=V,B.f=J,G(j,"buffer"),G(j,"byteOffset"),G(j,"byteLength"),G(j,"length")),n({target:"Object",stat:!0,forced:!F},{getOwnPropertyDescriptor:V,defineProperty:J}),t.exports=function(t,e,r){var i=t.match(/\d+$/)[0]/8,s=t+(r?"Clamped":"")+"Array",c="get"+t,h="set"+t,g=o[s],m=g,v=m&&m.prototype,B={},O=function(t,e){var r=k(t);return r.view[c](e*i+r.byteOffset,!0)},A=function(t,e,n){var o=k(t);r&&(n=(n=P(n))<0?0:n>255?255:255&n),o.view[h](e*i+o.byteOffset,n,!0)},L=function(t,e){M(t,e,{get:function(){return O(this,e)},set:function(t){return A(this,e,t)},enumerable:!0})};F?a&&(m=e((function(t,e,r,n){return u(t,m,s),T(function(){return y(e)?q(e)?void 0!==n?new g(e,d(r,i),n):void 0!==r?new g(e,d(r,i)):new g(e):W(e)?z(m,e):C.call(m,e):new g(p(e))}(),t,m)})),b&&b(m,D),I(x(g),(function(t){t in m||l(m,t,g[t])})),m.prototype=v):(m=e((function(t,e,r,n){u(t,m,s);var o,a,c,h=0,l=0;if(y(e)){if(!q(e))return W(e)?z(m,e):C.call(m,e);o=e,l=d(r,i);var g=e.byteLength;if(void 0===n){if(g%i)throw _(Y);if(a=g-l,a<0)throw _(Y)}else if(a=f(n)*i,a+l>g)throw _(Y);c=a/i}else c=p(e),a=c*i,o=new U(a);E(t,{buffer:o,byteOffset:l,byteLength:a,length:c,view:new R(o)});while(h1?arguments[1]:void 0)}))},3598:function(t,e,r){"use strict";var n=r("5a9e"),o=r("8d7b"),i=n.aTypedArray,a=n.exportTypedArrayMethod;a("lastIndexOf",(function(t){return o.apply(i(this),arguments)}))},"3c10":function(t,e,r){"use strict";var n=r("5dfd").forEach,o=r("d7e1"),i=r("ff9c"),a=o("forEach"),s=i("forEach");t.exports=a&&s?[].forEach:function(t){return n(this,t,arguments.length>1?arguments[1]:void 0)}},"3c51":function(t,e,r){"use strict";var n=r("5a9e"),o=r("fa41"),i=n.aTypedArray,a=n.exportTypedArrayMethod;a("fill",(function(t){return o.apply(i(this),arguments)}))},"3ccd":function(t,e,r){var n=r("3da3"),o=r("d88d");t.exports=function(t){if(void 0===t)return 0;var e=n(t),r=o(e);if(e!==r)throw RangeError("Wrong length or index");return r}},4140:function(t,e,r){"use strict";var n=r("5a9e"),o=r("ef4c"),i=r("efe2"),a=n.aTypedArray,s=n.aTypedArrayConstructor,c=n.exportTypedArrayMethod,u=[].slice,h=i((function(){new Int8Array(1).slice()}));c("slice",(function(t,e){var r=u.call(a(this),t,e),n=o(this,this.constructor),i=0,c=r.length,h=new(s(n))(c);while(c>i)h[i]=r[i++];return h}),h)},4350:function(t,e,r){var n=r("90fb");e.f=n},"513c":function(t,e,r){"use strict";var n=r("1e2c"),o=r("d890"),i=r("e8d6"),a=r("1944"),s=r("faa8"),c=r("2118"),u=r("7063"),h=r("9f67"),l=r("efe2"),f=r("6d60"),p=r("b338").f,d=r("aa6b").f,g=r("d910").f,m=r("c10f").trim,v="Number",y=o[v],w=y.prototype,b=c(f(w))==v,x=function(t){var e,r,n,o,i,a,s,c,u=h(t,!1);if("string"==typeof u&&u.length>2)if(u=m(u),e=u.charCodeAt(0),43===e||45===e){if(r=u.charCodeAt(2),88===r||120===r)return NaN}else if(48===e){switch(u.charCodeAt(1)){case 66:case 98:n=2,o=49;break;case 79:case 111:n=8,o=55;break;default:return+u}for(i=u.slice(2),a=i.length,s=0;so)return NaN;return parseInt(i,n)}return+u};if(i(v,!y(" 0o1")||!y("0b1")||y("+0x1"))){for(var C,I=function(t){var e=arguments.length<1?0:t,r=this;return r instanceof I&&(b?l((function(){w.valueOf.call(r)})):c(r)!=v)?u(new y(x(e)),r,I):x(e)},S=n?p(y):"MAX_VALUE,MIN_VALUE,NaN,NEGATIVE_INFINITY,POSITIVE_INFINITY,EPSILON,isFinite,isInteger,isNaN,isSafeInteger,MAX_SAFE_INTEGER,MIN_SAFE_INTEGER,parseFloat,parseInt,isInteger".split(","),B=0;S.length>B;B++)s(y,C=S[B])&&!s(I,C)&&g(I,C,d(y,C));I.prototype=w,w.constructor=I,a(o,v,I)}},5501:function(t,e,r){var o,i;(function(){var r=!1,a=function(t){return t instanceof a?t:this instanceof a?void(this.EXIFwrapped=t):new a(t)};t.exports&&(e=t.exports=a),e.EXIF=a;var s=a.Tags={36864:"ExifVersion",40960:"FlashpixVersion",40961:"ColorSpace",40962:"PixelXDimension",40963:"PixelYDimension",37121:"ComponentsConfiguration",37122:"CompressedBitsPerPixel",37500:"MakerNote",37510:"UserComment",40964:"RelatedSoundFile",36867:"DateTimeOriginal",36868:"DateTimeDigitized",37520:"SubsecTime",37521:"SubsecTimeOriginal",37522:"SubsecTimeDigitized",33434:"ExposureTime",33437:"FNumber",34850:"ExposureProgram",34852:"SpectralSensitivity",34855:"ISOSpeedRatings",34856:"OECF",37377:"ShutterSpeedValue",37378:"ApertureValue",37379:"BrightnessValue",37380:"ExposureBias",37381:"MaxApertureValue",37382:"SubjectDistance",37383:"MeteringMode",37384:"LightSource",37385:"Flash",37396:"SubjectArea",37386:"FocalLength",41483:"FlashEnergy",41484:"SpatialFrequencyResponse",41486:"FocalPlaneXResolution",41487:"FocalPlaneYResolution",41488:"FocalPlaneResolutionUnit",41492:"SubjectLocation",41493:"ExposureIndex",41495:"SensingMethod",41728:"FileSource",41729:"SceneType",41730:"CFAPattern",41985:"CustomRendered",41986:"ExposureMode",41987:"WhiteBalance",41988:"DigitalZoomRation",41989:"FocalLengthIn35mmFilm",41990:"SceneCaptureType",41991:"GainControl",41992:"Contrast",41993:"Saturation",41994:"Sharpness",41995:"DeviceSettingDescription",41996:"SubjectDistanceRange",40965:"InteroperabilityIFDPointer",42016:"ImageUniqueID"},c=a.TiffTags={256:"ImageWidth",257:"ImageHeight",34665:"ExifIFDPointer",34853:"GPSInfoIFDPointer",40965:"InteroperabilityIFDPointer",258:"BitsPerSample",259:"Compression",262:"PhotometricInterpretation",274:"Orientation",277:"SamplesPerPixel",284:"PlanarConfiguration",530:"YCbCrSubSampling",531:"YCbCrPositioning",282:"XResolution",283:"YResolution",296:"ResolutionUnit",273:"StripOffsets",278:"RowsPerStrip",279:"StripByteCounts",513:"JPEGInterchangeFormat",514:"JPEGInterchangeFormatLength",301:"TransferFunction",318:"WhitePoint",319:"PrimaryChromaticities",529:"YCbCrCoefficients",532:"ReferenceBlackWhite",306:"DateTime",270:"ImageDescription",271:"Make",272:"Model",305:"Software",315:"Artist",33432:"Copyright"},u=a.GPSTags={0:"GPSVersionID",1:"GPSLatitudeRef",2:"GPSLatitude",3:"GPSLongitudeRef",4:"GPSLongitude",5:"GPSAltitudeRef",6:"GPSAltitude",7:"GPSTimeStamp",8:"GPSSatellites",9:"GPSStatus",10:"GPSMeasureMode",11:"GPSDOP",12:"GPSSpeedRef",13:"GPSSpeed",14:"GPSTrackRef",15:"GPSTrack",16:"GPSImgDirectionRef",17:"GPSImgDirection",18:"GPSMapDatum",19:"GPSDestLatitudeRef",20:"GPSDestLatitude",21:"GPSDestLongitudeRef",22:"GPSDestLongitude",23:"GPSDestBearingRef",24:"GPSDestBearing",25:"GPSDestDistanceRef",26:"GPSDestDistance",27:"GPSProcessingMethod",28:"GPSAreaInformation",29:"GPSDateStamp",30:"GPSDifferential"},h=a.IFD1Tags={256:"ImageWidth",257:"ImageHeight",258:"BitsPerSample",259:"Compression",262:"PhotometricInterpretation",273:"StripOffsets",274:"Orientation",277:"SamplesPerPixel",278:"RowsPerStrip",279:"StripByteCounts",282:"XResolution",283:"YResolution",284:"PlanarConfiguration",296:"ResolutionUnit",513:"JpegIFOffset",514:"JpegIFByteCount",529:"YCbCrCoefficients",530:"YCbCrSubSampling",531:"YCbCrPositioning",532:"ReferenceBlackWhite"},l=a.StringValues={ExposureProgram:{0:"Not defined",1:"Manual",2:"Normal program",3:"Aperture priority",4:"Shutter priority",5:"Creative program",6:"Action program",7:"Portrait mode",8:"Landscape mode"},MeteringMode:{0:"Unknown",1:"Average",2:"CenterWeightedAverage",3:"Spot",4:"MultiSpot",5:"Pattern",6:"Partial",255:"Other"},LightSource:{0:"Unknown",1:"Daylight",2:"Fluorescent",3:"Tungsten (incandescent light)",4:"Flash",9:"Fine weather",10:"Cloudy weather",11:"Shade",12:"Daylight fluorescent (D 5700 - 7100K)",13:"Day white fluorescent (N 4600 - 5400K)",14:"Cool white fluorescent (W 3900 - 4500K)",15:"White fluorescent (WW 3200 - 3700K)",17:"Standard light A",18:"Standard light B",19:"Standard light C",20:"D55",21:"D65",22:"D75",23:"D50",24:"ISO studio tungsten",255:"Other"},Flash:{0:"Flash did not fire",1:"Flash fired",5:"Strobe return light not detected",7:"Strobe return light detected",9:"Flash fired, compulsory flash mode",13:"Flash fired, compulsory flash mode, return light not detected",15:"Flash fired, compulsory flash mode, return light detected",16:"Flash did not fire, compulsory flash mode",24:"Flash did not fire, auto mode",25:"Flash fired, auto mode",29:"Flash fired, auto mode, return light not detected",31:"Flash fired, auto mode, return light detected",32:"No flash function",65:"Flash fired, red-eye reduction mode",69:"Flash fired, red-eye reduction mode, return light not detected",71:"Flash fired, red-eye reduction mode, return light detected",73:"Flash fired, compulsory flash mode, red-eye reduction mode",77:"Flash fired, compulsory flash mode, red-eye reduction mode, return light not detected",79:"Flash fired, compulsory flash mode, red-eye reduction mode, return light detected",89:"Flash fired, auto mode, red-eye reduction mode",93:"Flash fired, auto mode, return light not detected, red-eye reduction mode",95:"Flash fired, auto mode, return light detected, red-eye reduction mode"},SensingMethod:{1:"Not defined",2:"One-chip color area sensor",3:"Two-chip color area sensor",4:"Three-chip color area sensor",5:"Color sequential area sensor",7:"Trilinear sensor",8:"Color sequential linear sensor"},SceneCaptureType:{0:"Standard",1:"Landscape",2:"Portrait",3:"Night scene"},SceneType:{1:"Directly photographed"},CustomRendered:{0:"Normal process",1:"Custom process"},WhiteBalance:{0:"Auto white balance",1:"Manual white balance"},GainControl:{0:"None",1:"Low gain up",2:"High gain up",3:"Low gain down",4:"High gain down"},Contrast:{0:"Normal",1:"Soft",2:"Hard"},Saturation:{0:"Normal",1:"Low saturation",2:"High saturation"},Sharpness:{0:"Normal",1:"Soft",2:"Hard"},SubjectDistanceRange:{0:"Unknown",1:"Macro",2:"Close view",3:"Distant view"},FileSource:{3:"DSC"},Components:{0:"",1:"Y",2:"Cb",3:"Cr",4:"R",5:"G",6:"B"}};function f(t){return!!t.exifdata}function p(t,e){e=e||t.match(/^data\:([^\;]+)\;base64,/im)[1]||"",t=t.replace(/^data\:([^\;]+)\;base64,/gim,"");for(var r=atob(t),n=r.length,o=new ArrayBuffer(n),i=new Uint8Array(o),a=0;a4?p:e+8,a=[],c=0;c4?p:e+8,S(t,i,f-1);case 3:if(1==f)return t.getUint16(e+8,!o);for(i=f>2?p:e+8,a=[],c=0;ct.byteLength)return{};var i=b(t,e,e+o,h,n);if(i["Compression"])switch(i["Compression"]){case 6:if(i.JpegIFOffset&&i.JpegIFByteCount){var a=e+i.JpegIFOffset,s=i.JpegIFByteCount;i["blob"]=new Blob([new Uint8Array(t.buffer,a,s)],{type:"image/jpeg"})}break;case 1:console.log("Thumbnail image format is TIFF, which is not implemented.");break;default:console.log("Unknown thumbnail image format '%s'",i["Compression"])}else 2==i["PhotometricInterpretation"]&&console.log("Thumbnail image format is RGB, which is not implemented.");return i}function S(t,e,r){var o="";for(n=e;n")+8;c=c.substring(c.indexOf("0){e["@attributes"]={};for(var r=0;r0)for(var r=0;r=0:l>f;f+=p)f in h&&(c=r(c,h[f],f,u));return c}};t.exports={left:s(!1),right:s(!0)}},"5a9e":function(t,e,r){"use strict";var n,o=r("d77f"),i=r("1e2c"),a=r("d890"),s=r("a719"),c=r("faa8"),u=r("2a91"),h=r("0fc1"),l=r("1944"),f=r("d910").f,p=r("908e"),d=r("50fb"),g=r("90fb"),m=r("7e8b"),v=a.Int8Array,y=v&&v.prototype,w=a.Uint8ClampedArray,b=w&&w.prototype,x=v&&p(v),C=y&&p(y),I=Object.prototype,S=I.isPrototypeOf,B=g("toStringTag"),O=m("TYPED_ARRAY_TAG"),A=o&&!!d&&"Opera"!==u(a.opera),T=!1,k={Int8Array:1,Uint8Array:1,Uint8ClampedArray:1,Int16Array:2,Uint16Array:2,Int32Array:4,Uint32Array:4,Float32Array:4,Float64Array:8},E=function(t){var e=u(t);return"DataView"===e||c(k,e)},M=function(t){return s(t)&&c(k,u(t))},L=function(t){if(M(t))return t;throw TypeError("Target is not a typed array")},P=function(t){if(d){if(S.call(x,t))return t}else for(var e in k)if(c(k,n)){var r=a[e];if(r&&(t===r||S.call(r,t)))return t}throw TypeError("Target is not a typed array constructor")},_=function(t,e,r){if(i){if(r)for(var n in k){var o=a[n];o&&c(o.prototype,t)&&delete o.prototype[t]}C[t]&&!r||l(C,t,r?e:A&&y[t]||e)}},U=function(t,e,r){var n,o;if(i){if(d){if(r)for(n in k)o=a[n],o&&c(o,t)&&delete o[t];if(x[t]&&!r)return;try{return l(x,t,r?e:A&&v[t]||e)}catch(s){}}for(n in k)o=a[n],!o||o[t]&&!r||l(o,t,e)}};for(n in k)a[n]||(A=!1);if((!A||"function"!=typeof x||x===Function.prototype)&&(x=function(){throw TypeError("Incorrect invocation")},A))for(n in k)a[n]&&d(a[n],x);if((!A||!C||C===I)&&(C=x.prototype,A))for(n in k)a[n]&&d(a[n].prototype,C);if(A&&p(b)!==C&&d(b,C),i&&!c(C,B))for(n in T=!0,f(C,B,{get:function(){return s(this)?this[O]:void 0}}),k)a[n]&&h(a[n],O,n);t.exports={NATIVE_ARRAY_BUFFER_VIEWS:A,TYPED_ARRAY_TAG:T&&O,aTypedArray:L,aTypedArrayConstructor:P,exportTypedArrayMethod:_,exportTypedArrayStaticMethod:U,isView:E,isTypedArray:M,TypedArray:x,TypedArrayPrototype:C}},"5ee6":function(t,e,r){"use strict";var n=function(){var t=this,e=t.$createElement,r=t._self._c||e;return r("div",[!0===t.showChooseBtn&&!0===t.isModal?r("div",{on:{click:t.handleOpen}},[t._t("openImgCutter"),t._t("open")],2):t._e(),t.$slots.openImgCutter||t.$slots.open||!0!==t.isModal?t._e():r("button",{staticClass:"btn btn-primary",attrs:{type:"button"},on:{click:t.handleOpen}},[t._v(t._s(t.label))]),r("transition",{attrs:{name:"fade"}},[t.visible?r("div",{ref:"mask",class:!0===t.isModal?"mask vue-img-cutter":""},[t.visible?r("div",{class:!0===t.isModal?"dialogBoxModal":"dialogBox"},[r("transition",{attrs:{name:"fade","enter-class":"fade-in-enter","enter-active-class":"fade-in-active","leave-class":"fade-out-enter","leave-active-class":"fade-out-active"}},[r("div",{ref:"dialogMainModalRef",class:!0===t.isModal?"dialogMainModal":"dialogMain",style:"width:"+(!0===t.isModal?t.boxWidth+32:t.boxWidth)+"px"},[r("div",{staticClass:"toolMain"},[!0===t.isModal?r("div",{staticClass:"tool-title"},[t._v(" 图片裁剪 "),r("span",{staticClass:"closeIcon",on:{click:t.handleClose}},[t._v("×")])]):t._e(),r("div",{ref:"toolBox",staticClass:"toolBox",style:"height:"+t.boxHeight+"px;width:"+t.boxWidth+"px",on:{mousemove:t.controlBtnMouseMove,mouseup:t.controlBtnMouseUp,mouseleave:t.controlBtnMouseUp}},[r("div",{directives:[{name:"show",rawName:"v-show",value:!t.drawImg.img&&!0===t.showChooseBtn,expression:"!drawImg.img && showChooseBtn===true"}],staticClass:"tips"},[r("div",{staticClass:"btn btn-warning btn-xs",on:{click:t.chooseImg}},[t._v(t._s(t.label))])]),1==t.tool?r("div",{directives:[{name:"show",rawName:"v-show",value:this.drawImg.img&&!0!==t.dropImg.active&&1==t.controlBox.disable&&1==t.toolBox.disable,expression:"this.drawImg.img && dropImg.active!==true && controlBox.disable==true && toolBox.disable==true"}],staticClass:"dockMain",style:"background:"+this.toolBgc,on:{mouseenter:t.dropImgOff}},[t.rate?r("div",{staticClass:"dockBtn"},[t._t("ratio",[t._v(" Ratio: ")]),t._v(" "+t._s(t.rate)+" ")],2):t._e(),r("div",{staticClass:"dockBtn",on:{click:t.scaleReset}},[t._t("scaleReset",[t._v(" Scale: ")]),t._v(" "+t._s(t.drawImg.swidth>0?(t.drawImg.width/t.drawImg.swidth).toFixed(2):"-")+" ")],2),!1===t.originalGraph?r("div",{staticClass:"dockBtn",on:{click:function(e){return t.turnImg(-90)}}},[t._t("turnLeft",[t._v(" ↳ ")])],2):t._e(),!1===t.originalGraph?r("div",{staticClass:"dockBtn",on:{click:function(e){return t.turnImg(90)}}},[t._t("turnRight",[t._v(" ↲ ")])],2):t._e(),!1===t.originalGraph?r("div",{staticClass:"dockBtn",on:{click:function(e){return t.turnReset()}}},[t._t("reset",[t._v(" ↻ ")])],2):t._e(),!1===t.originalGraph?r("div",{staticClass:"dockBtnScrollBar"},[r("div",{ref:"dockBtnScrollControl",staticClass:"scrollBarControl",style:"left:"+t.rotateControl.position+"px",on:{mousemove:t.scrollBarControlMove,mousedown:t.scrollBarControlOn,mouseleave:t.scrollBarControlOff,mouseup:t.scrollBarControlOff}}),1==t.rotateControl.active?r("div",{staticClass:"scrollBarText",style:"left:"+t.rotateControl.position+"px"},[t._v(" "+t._s(t.rotateImg.angle.toFixed(0)+"°")+" ")]):t._e()]):t._e(),!1===t.originalGraph?r("div",{staticClass:"dockBtn",on:{click:t.flipHorizontal}},[t._t("flipHorizontal",[t._v(" ⇆ ")])],2):t._e(),!1===t.originalGraph?r("div",{staticClass:"dockBtn",on:{click:t.flipVertically}},[t._t("turnRight",[t._v(" ⇅ ")])],2):t._e()]):t._e(),r("div",{directives:[{name:"show",rawName:"v-show",value:null!=t.drawImg.img,expression:"drawImg.img!=null"}],ref:"toolBoxControl",staticClass:"toolBoxControl",on:{mousedown:t.toolBoxMouseDown,mouseup:t.toolBoxMouseUp,mousemove:t.toolBoxMouseMove,mouseleave:t.toolBoxMouseLeave}},[r("div",{staticClass:"toolBoxControlBox"},[r("div",{staticClass:"controlBox"},[r("div",{staticClass:"controlBoxInnerLine controlBoxInnerLineTop"}),r("div",{staticClass:"controlBoxInnerLine controlBoxInnerLineBottom"}),r("div",{staticClass:"controlBoxInnerLine controlBoxInnerLineLeft"}),r("div",{staticClass:"controlBoxInnerLine controlBoxInnerLineRight"}),!1===t.originalGraph?r("div",{staticClass:"selectArea"},[t._v(" 宽:"+t._s(t.toolBox.width)+" 高:"+t._s(t.toolBox.height)+" (x:"+t._s(t.toolBoxPosition.x)+",y:"+t._s(t.toolBoxPosition.y)+") ")]):t._e(),!0===t.originalGraph?r("div",{staticClass:"selectArea"},[t._v(" 宽:"+t._s((t.toolBox.width/(t.drawImg.width/t.drawImg.swidth)).toFixed(0))+" 高:"+t._s((t.toolBox.height/(t.drawImg.width/t.drawImg.swidth)).toFixed(0))+" (x:"+t._s(t.toolBoxPosition.x)+",y:"+t._s(t.toolBoxPosition.y)+") ")]):t._e(),!0===t.sizeChange?r("div",{staticClass:"leftUp controlBtn",attrs:{"data-name":"leftUp"},on:{mousedown:function(e){return t.controlBtnMouseDown(e,"leftUp")}}}):t._e(),!0===t.sizeChange?r("div",{staticClass:"leftDown controlBtn",attrs:{"data-name":"leftDown"},on:{mousedown:function(e){return t.controlBtnMouseDown(e,"leftDown")}}}):t._e(),!0===t.sizeChange?r("div",{staticClass:"rightUp controlBtn",attrs:{"data-name":"rightUp"},on:{mousedown:function(e){return t.controlBtnMouseDown(e,"rightUp")}}}):t._e(),!0===t.sizeChange?r("div",{staticClass:"rightDown controlBtn",attrs:{"data-name":"rightDown"},on:{mousedown:function(e){return t.controlBtnMouseDown(e,"rightDown")}}}):t._e(),!0===t.sizeChange&&!t.rate&&this.toolBox.width>20?r("div",{staticClass:"topCenter controlBtn",attrs:{"data-name":"topCenter"},on:{mousedown:function(e){return t.controlBtnMouseDown(e,"topCenter")}}}):t._e(),!0===t.sizeChange&&!t.rate&&this.toolBox.width>20?r("div",{staticClass:"downCenter controlBtn",attrs:{"data-name":"downCenter"},on:{mousedown:function(e){return t.controlBtnMouseDown(e,"downCenter")}}}):t._e(),!0===t.sizeChange&&!t.rate&&this.toolBox.height>20?r("div",{staticClass:"leftCenter controlBtn",attrs:{"data-name":"leftCenter"},on:{mousedown:function(e){return t.controlBtnMouseDown(e,"leftCenter")}}}):t._e(),!0===t.sizeChange&&!t.rate&&this.toolBox.height>20?r("div",{staticClass:"rightCenter controlBtn",attrs:{"data-name":"rightCenter"},on:{mousedown:function(e){return t.controlBtnMouseDown(e,"rightCenter")}}}):t._e()]),r("div",{staticClass:"toolBoxControlLine toolBoxControlLineItem-1"}),r("div",{staticClass:"toolBoxControlLine toolBoxControlLineItem-2"}),r("div",{staticClass:"toolBoxControlLine toolBoxControlLineItem-3"}),r("div",{staticClass:"toolBoxControlLine toolBoxControlLineItem-4"})])]),r("div",{staticClass:"copyright"},[t.DoNotDisplayCopyright?t._e():r("a",{attrs:{target:"_blank",href:"https://github.com/acccccccb/vue-img-cutter",rel:"nofollow"}},[t._v("vue-img-cutter "+t._s(t.version))])]),r("canvas",{ref:"canvasSelectBox",staticClass:"canvasSelectBox",attrs:{width:t.boxWidth,height:t.boxHeight},on:{mousedown:t.dropImgOn,mouseup:t.dropImgOff,mousemove:t.dropImgMove}}),r("canvas",{ref:"canvas",staticClass:"canvas",attrs:{width:t.boxWidth,height:t.boxHeight}})])]),r("div",{staticClass:"i-dialog-footer"},[r("input",{ref:"inputFile",staticStyle:{width:"1px",height:"1px",border:"none",opacity:"0"},attrs:{type:"file",accept:"image/gif, image/jpeg ,image/png"},on:{change:t.putImgToCanv}}),r("span",{on:{click:t.chooseImg}},[t._t("choose",[!0===t.showChooseBtn?r("div",{staticClass:"btn btn-primary btn-primary-plain"},[t._v(t._s(t.label))]):t._e()])],2),r("div",{staticClass:"btn-group fr"},[r("span",{on:{click:t.handleClose}},[t._t("cancel",[r("button",{staticClass:"btn btn-default",attrs:{type:"button"}},[t._v("取消")])])],2),r("span",{on:{click:function(e){return t.cropPicture(!1)}}},[t._t("confirm",[r("button",{staticClass:"btn btn-primary",staticStyle:{"margin-left":"15px"},attrs:{type:"button",disabled:!t.drawImg.img}},[t._v("确定")])])],2)])])])]),r("div",{staticStyle:{clear:"both"}})],1):t._e()]):t._e()])],1)},o=[],i=(r("ecb4"),r("053b"),r("513c"),r("e18c"),r("e35a"),r("f4e3"),r("0d7a"),r("8256"),r("ab6e"),r("927c"),r("3c51"),r("db0a"),r("1cc1"),r("ab0f"),r("fc6e"),r("f30b"),r("cfd1"),r("d104"),r("f74a"),r("3598"),r("b497"),r("2909"),r("a7ef"),r("b523"),r("e671"),r("4140"),r("83db"),r("829d"),r("939f"),r("1bb1"),r("c3ba"),r("f3dd"),r("dbb3"),r("fe59"),r("b73f"),r("bf84"),r("fe8a"),r("08ba"),r("ce3c"));function a(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),r.push.apply(r,n)}return r}function s(t){for(var e=1;eo?"scroll":"hidden"}t&&"function"===typeof t&&t()};if(t&&"object"==c(t)&&t.src){if(!t.name)throw new Error("传入参数必须包含:src,name");var o=new Image;!0===this.crossOrigin&&(o.crossOrigin=this.crossOriginHeader),o.name=t.name,o.style.position="fixed",o.style.top=-5e3,o.style.opacity=0,o.onerror=function(t){console.error("图片加载失败"),r.$emit("error",{event:t,msg:"图片加载失败"}),r.clearCutImageObj()},o.onload=function(){if(!0!==o.complete)throw new Error("图片加载失败");r.visible=!0,r.$nextTick((function(){n((function(){r.importImgToCanv(o)}))}))},o.src=t.src,this.cutImageObj=o,document.body.appendChild(o),this.$emit("onChooseImg",t)}else r.visible=!0,r.$nextTick((function(){n()}))},handleClose:function(){var t=this;this.clearAll(),!0===this.isModal&&(!0===this.lockScroll&&(document.body.style.overflowY="scroll"),this.$nextTick((function(){t.visible=!1})))},chooseImg:function(){this.$refs["inputFile"].click()},importImgToCanv:function(t){var e=this;e.fileName=t.name;var r,n=t.height,o=t.width,i=e.boxWidth,a=e.boxHeight,c=s({},e.drawImg);c.img=t,e.scaleImg.rate=o/n,nthis.boxWidth?this.boxWidth:this.cutWidth,this.toolBox.height=this.cutHeight>this.boxHeight?this.boxHeight:this.cutHeight),(0===this.toolBox.x&&0===this.toolBox.y||!1===this.saveCutPosition)&&(this.toolBox.x=this.boxWidth/2-this.toolBox.width/2,this.toolBox.y=this.boxHeight/2-this.toolBox.height/2),this.drawControlBox(this.toolBox.width,this.toolBox.height,this.toolBox.x,this.toolBox.y)},isSupportFileApi:function(){return!!(window.File&&window.FileList&&window.FileReader&&window.Blob&&-1===navigator.userAgent.indexOf("Edge")&&-1===navigator.userAgent.indexOf("MSIE")&&-1===navigator.userAgent.indexOf("Trident"))},dataURLtoFile:function(t,e){var r=t.split(","),n=r[0].match(/:(.*?);/)[1],o=atob(r[1]),i=o.length,a=new Uint8Array(i);while(i--)a[i]=o.charCodeAt(i);if(this.isSupportFileApi()){var s=new File([a],e,{type:n});return s}return"不支持File对象"},clearAll:function(){var t=this,e=t.$refs["canvas"],r=e.getContext("2d");r.clearRect(0,0,e.width,e.height);var n=t.$refs["canvasSelectBox"],o=n.getContext("2d");o.clearRect(0,0,n.width,n.height);var i=t.drawImg.sx,a=t.drawImg.sy;this.drawImg={img:null,sx:i,sy:a,swidth:0,sheight:0,x:0,y:0,width:0,height:0},this.isFlipHorizontal=!1,this.isFlipVertically=!1,this.$refs["inputFile"].value="",this.rotateImg.angle=0,this.drawImg.img=null,this.turnReset(),this.clearCutImageObj(),this.$emit("onClearAll")},clearCutImageObj:function(){null!==this.cutImageObj&&void 0!==this.cutImageObj&&("function"===typeof this.cutImageObj.remove?this.cutImageObj.remove():this.cutImageObj.removeNode()),this.cutImageObj=null},drawControlBox:function(t,e,r,n){var o=this;t>this.boxWidth&&(t=this.boxWidth),e>this.boxHeight&&(e=this.boxHeight),r<0&&(r=0),n<0&&(n=0);var i,a,s=this.$refs["toolBoxControl"],c=this.$refs["canvasSelectBox"],u=c.getContext("2d");if(u.fillStyle=this.selectBoxColor,u.clearRect(0,0,c.width,c.height),u.fillRect(0,0,c.width,c.height),this.rate&&""!==this.rate){var h=this.rate.split(":")[0]/this.rate.split(":")[1];h>=1?(i=t,a=t/h):(i=e*h,a=e)}else i=t,a=e;this.toolBox.width=i,this.toolBox.height=a,s.style.width=Math.abs(i)+"px",s.style.height=Math.abs(a)+"px",this.toolBox.boxMove.moveTo.x=r,this.toolBox.boxMove.moveTo.y=n,i<0&&(r+=i),a<0&&(n+=a),r+this.toolBox.width>this.boxWidth&&(r=this.boxWidth-this.toolBox.width),r<0&&(r=0),n+this.toolBox.height>this.boxHeight&&(n=this.boxHeight-this.toolBox.height),n<0&&(n=0),this.toolBoxPosition.x=r,this.toolBoxPosition.y=n,s.style.left=r+"px",s.style.top=n+"px",u.clearRect(r,n,Math.abs(i),Math.abs(a)),this.onPrintImgTimmer&&clearTimeout(this.onPrintImgTimmer),this.onPrintImgTimmer=setTimeout((function(){o.cropPicture(!0)}),100)},resetToolBox:function(){this.toolBox.width<0&&(this.toolBox.boxMove.moveTo.x=this.toolBox.x-this.toolBox.width),this.toolBox.height<0&&(this.toolBox.boxMove.moveTo.y=this.toolBox.y-this.toolBox.height),this.toolBox.width=Math.abs(this.toolBox.width),this.toolBox.height=Math.abs(this.toolBox.height)},toolBoxMouseDown:function(t){var e=this.$refs["toolBoxControl"];this.toolBox.x=parseInt(e.style.left.split("px")[0]),this.toolBox.y=parseInt(e.style.top.split("px")[0]),this.toolBox.disable=!1,this.dropImg.active=!1,this.toolBox.boxMove.start={x:t.pageX,y:t.pageY}},toolBoxMouseMove:function(t){if(this.dropImg.active&&this.dropImgMove(t),!1===this.toolBox.disable&&!0===this.moveAble){var e=t.pageX-this.toolBox.boxMove.start.x,r=t.pageY-this.toolBox.boxMove.start.y,n=this.toolBox.x+e,o=this.toolBox.y+r;this.drawControlBox(this.toolBox.width,this.toolBox.height,n,o)}},toolBoxMouseLeave:function(){var t=this;this.toolBox.disable=!0,this.onPrintImgTimmer&&clearTimeout(this.onPrintImgTimmer),this.onPrintImgTimmer=setTimeout((function(){t.cropPicture(!0)}),100),this.resetToolBox()},toolBoxMouseUp:function(t){this.toolBox.x=parseInt(this.toolBoxPosition.x),this.toolBox.y=parseInt(this.toolBoxPosition.y),this.toolBox.disable=!0,this.dropImg.active=!1,this.resetToolBox()},printImg:function(){var t=this;if(this.drawImg.img){var e=this.$refs["canvas"],r=e.getContext("2d");r.font="18px bold 黑体",r.fillStyle="#ff0",r.textAlign="center",r.textBaseline="middle",r.save(),r.clearRect(0,0,e.width,e.height),r.translate(this.drawImg.x+this.drawImg.width/2,this.drawImg.y+this.drawImg.height/2),r.rotate(this.rotateImg.angle*Math.PI/180),r.translate(-(this.drawImg.x+this.drawImg.width/2),-(this.drawImg.y+this.drawImg.height/2)),r.translate(this.drawImg.x,this.drawImg.y),r.scale(this.isFlipHorizontal?-1:1,this.isFlipVertically?-1:1),r.drawImage(this.drawImg.img,this.drawImg.sx,this.drawImg.sy,this.drawImg.swidth,this.drawImg.sheight,this.isFlipHorizontal?-this.drawImg.width:0,this.isFlipVertically?-this.drawImg.height:0,this.drawImg.width,this.drawImg.height),r.translate(-this.drawImg.x,this.drawImg.y),r.restore(),this.onPrintImgTimmer&&clearTimeout(this.onPrintImgTimmer),this.onPrintImgTimmer=setTimeout((function(){t.cropPicture(!0)}),100)}},dropImgOn:function(t){this.dropImg.active=!0,this.dropImg.params=s({},this.drawImg),this.dropImg.pageX=t.pageX,this.dropImg.pageY=t.pageY},dropImgOff:function(){var t=this;this.dropImg.active=!1,this.onPrintImgTimmer&&clearTimeout(this.onPrintImgTimmer),this.onPrintImgTimmer=setTimeout((function(){t.cropPicture(!0)}),100)},dropImgMove:function(t){var e=this;if(this.dropImg.active&&this.drawImg.img){var r=s({},e.drawImg);r.x=e.dropImg.params.x-(e.dropImg.pageX-t.pageX),r.y=e.dropImg.params.y-(e.dropImg.pageY-t.pageY),e.$set(e,"drawImg",r),e.printImg(),t.stopPropagation()}},scaleReset:function(){this.drawImg.width=this.drawImg.swidth,this.drawImg.height=this.drawImg.sheight,this.printImg()},scaleImgWheel:function(t){var e=this,r=this;if(r.drawImg.img&&!0===this.scaleAble){var n,o=t||window.event;o.wheelDelta?n=-o.wheelDelta/40:o.detail&&(n=o.detail);var i=50;r.drawImg.x=r.drawImg.width-9*n>i?r.drawImg.x+3*n:r.drawImg.x,r.drawImg.y=r.drawImg.width-9*n>i?r.drawImg.y+3*n:r.drawImg.y,r.drawImg.width=r.drawImg.width-9*n>i?r.drawImg.width-9*n:i,r.drawImg.height=r.drawImg.width/r.scaleImg.rate,r.printImg(),this.onPrintImgTimmer&&clearTimeout(this.onPrintImgTimmer),this.onPrintImgTimmer=setTimeout((function(){e.cropPicture(!0)}),100)}return t.preventDefault(),t.returnValue=!1,!1},flipHorizontal:function(){this.drawImg.img&&(0==this.isFlipHorizontal?this.isFlipHorizontal=!0:this.isFlipHorizontal=!1,this.printImg())},flipVertically:function(){this.drawImg.img&&(0==this.isFlipVertically?this.isFlipVertically=!0:this.isFlipVertically=!1,this.printImg())},turnImg:function(t){var e=this.rotateImg.angle,r=e+t;r>=-180&&r<=180&&(this.rotateImg.angle=r,this.rotateControl.position=r/180*100+100,this.printImg("rotate"))},turnReset:function(){this.rotateImg.angle=0,this.rotateControl.position=100,this.printImg("rotate")},controlBtnMouseDown:function(t,e){this.controlBox.disable=!1,this.controlBox.btnName=e,this.controlBox.start.x=t.clientX,this.controlBox.start.y=t.clientY,this.controlBox.start.width=this.toolBox.width,this.controlBox.start.height=this.toolBox.height,t.stopPropagation()},controlBtnMouseUp:function(t){this.controlBox.disable=!0,this.dropImgOff(),this.resetToolBox(),this.toolBoxMouseUp(),t.stopPropagation()},controlBtnMouseMove:function(t){if(!1===this.controlBox.disable){var e,r,n=t.clientX-this.controlBox.start.x,o=t.clientY-this.controlBox.start.y;"leftUp"==this.controlBox.btnName&&(e=this.toolBox.x+n,r=this.toolBox.y+o,this.toolBox.width=this.controlBox.start.width-n,this.toolBox.height=this.controlBox.start.height-o),"rightUp"==this.controlBox.btnName&&(e=this.toolBox.x,r=this.toolBox.y+o,this.toolBox.width=this.controlBox.start.width+n,this.toolBox.height=this.controlBox.start.height-o),"rightDown"==this.controlBox.btnName&&(e=this.toolBox.x,r=this.toolBox.y,this.toolBox.width=this.controlBox.start.width+n,this.toolBox.height=this.controlBox.start.height+o),"leftDown"==this.controlBox.btnName&&(e=this.toolBox.x+n,r=this.toolBox.y,this.toolBox.width=this.controlBox.start.width-n,this.toolBox.height=this.controlBox.start.height+o),"topCenter"==this.controlBox.btnName&&(e=this.toolBox.x,r=this.toolBox.y+o,this.toolBox.width=this.controlBox.start.width,this.toolBox.height=this.controlBox.start.height-o),"downCenter"==this.controlBox.btnName&&(e=this.toolBox.x,r=this.toolBox.y,this.toolBox.width=this.controlBox.start.width,this.toolBox.height=this.controlBox.start.height+o),"leftCenter"==this.controlBox.btnName&&(e=this.toolBox.x+n,r=this.toolBox.y,this.toolBox.width=this.controlBox.start.width-n,this.toolBox.height=this.controlBox.start.height),"rightCenter"==this.controlBox.btnName&&(e=this.toolBox.x,r=this.toolBox.y,this.toolBox.width=this.controlBox.start.width+n,this.toolBox.height=this.controlBox.start.height),this.drawControlBox(this.toolBox.width,this.toolBox.height,e,r)}t.stopPropagation()},cropPicture:function(t){var e=this;if(this.drawImg.img){var r=this.$refs["canvas"];if(this.WatermarkText&&!t){var n=r.getContext("2d");n.font=this.WatermarkTextFont,n.fillStyle=this.WatermarkTextColor,n.textAlign="right",n.textBaseline="bottom",n.fillText(this.WatermarkText,this.toolBox.x+this.toolBox.width*this.WatermarkTextX,this.toolBox.y+this.toolBox.height*this.WatermarkTextY)}var o=new Image;!0===this.crossOrigin&&(o.crossOrigin=this.crossOriginHeader),o.src=r.toDataURL(),HTMLCanvasElement.prototype.toBlob||Object.defineProperty(HTMLCanvasElement.prototype,"toBlob",{value:function(t,e,n){window.atob?setTimeout((function(){for(var o=atob(r.toDataURL(e,n).split(",")[1]),i=o.length,a=new Uint8Array(i),s=0;s=v?a.drawImage(o,d.x,d.y,d.width,d.width*g,0,0,d.width,d.width*g):a.drawImage(o,d.x,d.y,d.width,d.width/g,0,0,d.width,d.width/g)}else a.drawImage(o,d.x,d.y,d.width,d.height,0,0,d.width,d.height)}i.toBlob((function(r){t?e.$emit("onPrintImg",{fileName:e.fileName,blob:r,file:e.dataURLtoFile(i.toDataURL(),e.fileName),dataURL:i.toDataURL()}):(e.handleClose(),e.$emit("cutDown",{fileName:e.fileName,blob:r,file:e.dataURLtoFile(i.toDataURL(),e.fileName),dataURL:i.toDataURL()}))}),"image/jpeg",.95)}}),200)}}else{var i=document.createElement("canvas");i.width=e.toolBox.width,i.height=e.toolBox.height;var a=i.getContext("2d"),s=e.toolBox;if(e.rate){var c=e.rate.split(":")[0]/e.rate.split(":")[1];a.drawImage(o,s.x,s.y,s.width,s.width*c,0,0,s.width,s.width*c)}else a.drawImage(o,s.x,s.y,s.width,s.height,0,0,s.width,s.height);t?e.$emit("onPrintImg",{fileName:e.fileName,dataURL:i.toDataURL()}):(e.handleClose(),e.$emit("cutDown",{fileName:e.fileName,dataURL:i.toDataURL()}))}}))}else t||(console.warn("No picture selected"),e.$emit("error",{err:1,msg:"No picture selected"}))},scrollBarControlMove:function(t){if(this.rotateControl.active){var e=t.pageX-this.rotateControl.start.x,r=this.rotateControl.start.position+e;r<=0&&(r=0),r>=200&&(r=200),this.rotateControl.position=r,this.rotateImg.angle=(r-100)/100*180,this.printImg()}},scrollBarControlOn:function(t){this.rotateControl.active=!0,this.rotateControl.start.x=t.pageX,this.rotateControl.start.y=t.pageY,this.rotateControl.start.position=this.rotateControl.position},scrollBarControlOff:function(){this.rotateControl.active=!1}}},l=h,f=(r("0a0a"),r("9ca4")),p=Object(f["a"])(l,n,o,!1,null,"b09dcefa",null),d=p.exports;e["a"]=d},6176:function(t,e,r){var n=r("3da3");t.exports=function(t){var e=n(t);if(e<0)throw RangeError("The argument can't be less than 0");return e}},"6a61":function(t,e,r){var n=function(t){"use strict";var e,r=Object.prototype,n=r.hasOwnProperty,o="function"===typeof Symbol?Symbol:{},i=o.iterator||"@@iterator",a=o.asyncIterator||"@@asyncIterator",s=o.toStringTag||"@@toStringTag";function c(t,e,r){return Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}),t[e]}try{c({},"")}catch(L){c=function(t,e,r){return t[e]=r}}function u(t,e,r,n){var o=e&&e.prototype instanceof m?e:m,i=Object.create(o.prototype),a=new k(n||[]);return i._invoke=B(t,r,a),i}function h(t,e,r){try{return{type:"normal",arg:t.call(e,r)}}catch(L){return{type:"throw",arg:L}}}t.wrap=u;var l="suspendedStart",f="suspendedYield",p="executing",d="completed",g={};function m(){}function v(){}function y(){}var w={};w[i]=function(){return this};var b=Object.getPrototypeOf,x=b&&b(b(E([])));x&&x!==r&&n.call(x,i)&&(w=x);var C=y.prototype=m.prototype=Object.create(w);function I(t){["next","throw","return"].forEach((function(e){c(t,e,(function(t){return this._invoke(e,t)}))}))}function S(t,e){function r(o,i,a,s){var c=h(t[o],t,i);if("throw"!==c.type){var u=c.arg,l=u.value;return l&&"object"===typeof l&&n.call(l,"__await")?e.resolve(l.__await).then((function(t){r("next",t,a,s)}),(function(t){r("throw",t,a,s)})):e.resolve(l).then((function(t){u.value=t,a(u)}),(function(t){return r("throw",t,a,s)}))}s(c.arg)}var o;function i(t,n){function i(){return new e((function(e,o){r(t,n,e,o)}))}return o=o?o.then(i,i):i()}this._invoke=i}function B(t,e,r){var n=l;return function(o,i){if(n===p)throw new Error("Generator is already running");if(n===d){if("throw"===o)throw i;return M()}r.method=o,r.arg=i;while(1){var a=r.delegate;if(a){var s=O(a,r);if(s){if(s===g)continue;return s}}if("next"===r.method)r.sent=r._sent=r.arg;else if("throw"===r.method){if(n===l)throw n=d,r.arg;r.dispatchException(r.arg)}else"return"===r.method&&r.abrupt("return",r.arg);n=p;var c=h(t,e,r);if("normal"===c.type){if(n=r.done?d:f,c.arg===g)continue;return{value:c.arg,done:r.done}}"throw"===c.type&&(n=d,r.method="throw",r.arg=c.arg)}}}function O(t,r){var n=t.iterator[r.method];if(n===e){if(r.delegate=null,"throw"===r.method){if(t.iterator["return"]&&(r.method="return",r.arg=e,O(t,r),"throw"===r.method))return g;r.method="throw",r.arg=new TypeError("The iterator does not provide a 'throw' method")}return g}var o=h(n,t.iterator,r.arg);if("throw"===o.type)return r.method="throw",r.arg=o.arg,r.delegate=null,g;var i=o.arg;return i?i.done?(r[t.resultName]=i.value,r.next=t.nextLoc,"return"!==r.method&&(r.method="next",r.arg=e),r.delegate=null,g):i:(r.method="throw",r.arg=new TypeError("iterator result is not an object"),r.delegate=null,g)}function A(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function T(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function k(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(A,this),this.reset(!0)}function E(t){if(t){var r=t[i];if(r)return r.call(t);if("function"===typeof t.next)return t;if(!isNaN(t.length)){var o=-1,a=function r(){while(++o=0;--i){var a=this.tryEntries[i],s=a.completion;if("root"===a.tryLoc)return o("end");if(a.tryLoc<=this.prev){var c=n.call(a,"catchLoc"),u=n.call(a,"finallyLoc");if(c&&u){if(this.prev=0;--r){var o=this.tryEntries[r];if(o.tryLoc<=this.prev&&n.call(o,"finallyLoc")&&this.prev=0;--e){var r=this.tryEntries[e];if(r.finallyLoc===t)return this.complete(r.completion,r.afterLoc),T(r),g}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.tryLoc===t){var n=r.completion;if("throw"===n.type){var o=n.arg;T(r)}return o}}throw new Error("illegal catch attempt")},delegateYield:function(t,r,n){return this.delegate={iterator:E(t),resultName:r,nextLoc:n},"next"===this.method&&(this.arg=e),g}},t}(t.exports);try{regeneratorRuntime=n}catch(o){Function("r","regeneratorRuntime = r")(n)}},"6d51":function(t,e,r){var n=r("1b99"),o=r("faa8"),i=r("4350"),a=r("d910").f;t.exports=function(t){var e=n.Symbol||(n.Symbol={});o(e,t)||a(e,t,{value:i.f(t)})}},"6f82":function(t,e,r){var n=r("3553"),o=r("d88d"),i=r("b60f"),a=r("98a9"),s=r("e349"),c=r("5a9e").aTypedArrayConstructor;t.exports=function(t){var e,r,u,h,l,f,p=n(t),d=arguments.length,g=d>1?arguments[1]:void 0,m=void 0!==g,v=i(p);if(void 0!=v&&!a(v)){l=v.call(p),f=l.next,p=[];while(!(h=f.call(l)).done)p.push(h.value)}for(m&&d>2&&(g=s(g,arguments[2],2)),r=o(p.length),u=new(c(this))(r),e=0;r>e;e++)u[e]=m?g(p[e],e):p[e];return u}},7063:function(t,e,r){var n=r("a719"),o=r("50fb");t.exports=function(t,e,r){var i,a;return o&&"function"==typeof(i=e.constructor)&&i!==r&&n(a=i.prototype)&&a!==r.prototype&&o(t,a),t}},"77ad":function(t,e,r){"use strict";var n=r("1c8b"),o=r("a719"),i=r("74e7"),a=r("e1d6"),s=r("d88d"),c=r("da10"),u=r("1bbd"),h=r("90fb"),l=r("1ea7"),f=r("ff9c"),p=l("slice"),d=f("slice",{ACCESSORS:!0,0:0,1:2}),g=h("species"),m=[].slice,v=Math.max;n({target:"Array",proto:!0,forced:!p||!d},{slice:function(t,e){var r,n,h,l=c(this),f=s(l.length),p=a(t,f),d=a(void 0===e?f:e,f);if(i(l)&&(r=l.constructor,"function"!=typeof r||r!==Array&&!i(r.prototype)?o(r)&&(r=r[g],null===r&&(r=void 0)):r=void 0,r===Array||void 0===r))return m.call(l,p,d);for(n=new(void 0===r?Array:r)(v(d-p,0)),h=0;p1?arguments[1]:void 0)}))},"8a1c":function(t,e,r){var n=r("a719"),o=r("2118"),i=r("90fb"),a=i("match");t.exports=function(t){var e;return n(t)&&(void 0!==(e=t[a])?!!e:"RegExp"==o(t))}},"8d6e":function(t,e,r){"use strict";var n=function(){var t=this,e=t.$createElement,r=t._self._c||e;return r("div",{staticClass:"custom-upload"},[r("el-dialog",{staticClass:"cropper-dialog",attrs:{title:"图片裁剪",visible:t.showCropper,width:"50%",height:"600",center:"","append-to-body":""},on:{"update:visible":function(e){t.showCropper=e}}},[t.showCropper?r("vue-cropper",t._b({ref:"cropper",class:{"corpper-warp":t.showCropper},attrs:{id:"corpper"}},"vue-cropper",t.cropper,!1)):t._e(),t.showCropper?r("div",{staticClass:"cropper-button"},[r("el-button",{staticClass:"cancel-btn",attrs:{size:"small"},nativeOn:{click:function(e){t.showCropper=!1}}},[t._v("取消")]),r("el-button",{attrs:{size:"small",type:"primary",loading:t.loading},on:{click:t.uploadCover}},[t._v("完成")])],1):t._e()],1),r("input",{staticStyle:{display:"none"},attrs:{id:t.id,type:"file",name:"single",accept:"image/*"},on:{change:function(e){return t.onChange(e)}}}),r("el-button",{attrs:{size:"small",type:"primary",loading:t.loading},on:{click:function(e){return t.handleOpenFile()}}},[r("i",{staticClass:"fa fa-upload"}),t._v(" "+t._s(t.buttonName)+" ")]),t.tips?r("div",{staticClass:"tips clear-margin-top"},[t._v(t._s(t.tips))]):t._e()],1)},o=[];r("513c"),r("6a61"),r("e18c");function i(t,e,r,n,o,i,a){try{var s=t[i](a),c=s.value}catch(u){return void r(u)}s.done?e(c):Promise.resolve(c).then(n,o)}function a(t){return function(){var e=this,r=arguments;return new Promise((function(n,o){var a=t.apply(e,r);function s(t){i(a,n,o,s,c,"next",t)}function c(t){i(a,n,o,s,c,"throw",t)}s(void 0)}))}}var s=r("ce3c"),c=(r("e925"),r("b678"));r("b130"),r("90aa");r("f3dd"),r("0a51"),r("9b11"),r("96db"),r("af86");r("98e0"),r("77ad"),r("053b"),r("1c2e");var u=r("b705"),h=function(t,e){var r=e||["image/png","image/gif","image/jpeg","image/jpg","image/bmp","image/x-icon"],n=r.includes(t.type);return!!n||(u["Message"].error("上传文件非图片格式!"),!1)},l=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:2,r=t.size/1024/10241&&(a=c(a,o(arguments[1]))),a<0&&(a=r+a);a>=0;a--)if(a in e&&e[a]===t)return a||0;return-1}:u},"90aa":function(t,e,r){"use strict";var n=r("1c8b"),o=r("07a2"),i=r("2732"),a=r("783d");n({target:"String",proto:!0,forced:!a("includes")},{includes:function(t){return!!~String(i(this)).indexOf(o(t),arguments.length>1?arguments[1]:void 0)}})},"927c":function(t,e,r){"use strict";var n=r("5a9e"),o=r("5dfd").every,i=n.aTypedArray,a=n.exportTypedArrayMethod;a("every",(function(t){return o(i(this),t,arguments.length>1?arguments[1]:void 0)}))},"939f":function(t,e,r){"use strict";var n=r("5a9e"),o=r("d88d"),i=r("e1d6"),a=r("ef4c"),s=n.aTypedArray,c=n.exportTypedArrayMethod;c("subarray",(function(t,e){var r=s(this),n=r.length,c=i(t,n);return new(a(r,r.constructor))(r.buffer,r.byteOffset+c*r.BYTES_PER_ELEMENT,o((void 0===e?n:i(e,n))-c))}))},"96db":function(t,e,r){"use strict";var n=r("f62c").charAt,o=r("b702"),i=r("99ee"),a="String Iterator",s=o.set,c=o.getterFor(a);i(String,"String",(function(t){s(this,{type:a,string:String(t),index:0})}),(function(){var t,e=c(this),r=e.string,o=e.index;return o>=r.length?{value:void 0,done:!0}:(t=n(r,o),e.index+=t.length,{value:t,done:!1})}))},"98e0":function(t,e,r){var n=r("1c8b"),o=r("e62b"),i=r("f471"),a=!i((function(t){Array.from(t)}));n({target:"Array",stat:!0,forced:a},{from:o})},"9b11":function(t,e,r){var n=r("6d51");n("iterator")},a4c7:function(t,e,r){var n=r("d890"),o=r("efe2"),i=r("f471"),a=r("5a9e").NATIVE_ARRAY_BUFFER_VIEWS,s=n.ArrayBuffer,c=n.Int8Array;t.exports=!a||!o((function(){c(1)}))||!o((function(){new c(-1)}))||!i((function(t){new c,new c(null),new c(1.5),new c(t)}),!0)||o((function(){return 1!==new c(new s(2),1,void 0).length}))},a7ef:function(t,e,r){"use strict";var n=r("5a9e"),o=r("58d8").right,i=n.aTypedArray,a=n.exportTypedArrayMethod;a("reduceRight",(function(t){return o(i(this),t,arguments.length,arguments.length>1?arguments[1]:void 0)}))},ab0f:function(t,e,r){"use strict";var n=r("5a9e"),o=r("5dfd").findIndex,i=n.aTypedArray,a=n.exportTypedArrayMethod;a("findIndex",(function(t){return o(i(this),t,arguments.length>1?arguments[1]:void 0)}))},ab6e:function(t,e,r){"use strict";var n=r("5a9e"),o=r("19fc"),i=n.aTypedArray,a=n.exportTypedArrayMethod;a("copyWithin",(function(t,e){return o.call(i(this),t,e,arguments.length>2?arguments[2]:void 0)}))},af86:function(t,e,r){var n=r("d890"),o=r("064b"),i=r("a133"),a=r("0fc1"),s=r("90fb"),c=s("iterator"),u=s("toStringTag"),h=i.values;for(var l in o){var f=n[l],p=f&&f.prototype;if(p){if(p[c]!==h)try{a(p,c,h)}catch(g){p[c]=h}if(p[u]||a(p,u,l),o[l])for(var d in i)if(p[d]!==i[d])try{a(p,d,i[d])}catch(g){p[d]=i[d]}}}},b130:function(t,e,r){"use strict";var n=r("1c8b"),o=r("45af").includes,i=r("258f"),a=r("ff9c"),s=a("indexOf",{ACCESSORS:!0,1:0});n({target:"Array",proto:!0,forced:!s},{includes:function(t){return o(this,t,arguments.length>1?arguments[1]:void 0)}}),i("includes")},b497:function(t,e,r){"use strict";var n=r("5a9e"),o=r("5dfd").map,i=r("ef4c"),a=n.aTypedArray,s=n.aTypedArrayConstructor,c=n.exportTypedArrayMethod;c("map",(function(t){return o(a(this),t,arguments.length>1?arguments[1]:void 0,(function(t,e){return new(s(i(t,t.constructor)))(e)}))}))},b523:function(t,e,r){"use strict";var n=r("5a9e"),o=n.aTypedArray,i=n.exportTypedArrayMethod,a=Math.floor;i("reverse",(function(){var t,e=this,r=o(e).length,n=a(r/2),i=0;while(i=0&&c.splice(e,1)}function d(t){var e=document.createElement("style");if(void 0===t.attrs.type&&(t.attrs.type="text/css"),void 0===t.attrs.nonce){var n=function(){return r.nc}();n&&(t.attrs.nonce=n)}return g(e,t.attrs),f(t,e),e}function g(t,e){Object.keys(e).forEach((function(r){t.setAttribute(r,e[r])}))}function m(t,e){var r,n,o,i;if(e.transform&&t.css){if(!(i="function"==typeof e.transform?e.transform(t.css):e.transform.default(t.css)))return function(){};t.css=i}if(e.singleton){var c=s++;r=a||(a=d(e)),n=y.bind(null,r,c,!1),o=y.bind(null,r,c,!0)}else t.sourceMap&&"function"==typeof URL&&"function"==typeof URL.createObjectURL&&"function"==typeof URL.revokeObjectURL&&"function"==typeof Blob&&"function"==typeof btoa?(r=function(t){var e=document.createElement("link");return void 0===t.attrs.type&&(t.attrs.type="text/css"),t.attrs.rel="stylesheet",g(e,t.attrs),f(t,e),e}(e),n=function(t,e,r){var n=r.css,o=r.sourceMap,i=void 0===e.convertToAbsoluteUrls&&o;(e.convertToAbsoluteUrls||i)&&(n=u(n)),o&&(n+="\n/*# sourceMappingURL=data:application/json;base64,"+btoa(unescape(encodeURIComponent(JSON.stringify(o))))+" */");var a=new Blob([n],{type:"text/css"}),s=t.href;t.href=URL.createObjectURL(a),s&&URL.revokeObjectURL(s)}.bind(null,r,e),o=function(){p(r),r.href&&URL.revokeObjectURL(r.href)}):(r=d(e),n=function(t,e){var r=e.css,n=e.media;if(n&&t.setAttribute("media",n),t.styleSheet)t.styleSheet.cssText=r;else{for(;t.firstChild;)t.removeChild(t.firstChild);t.appendChild(document.createTextNode(r))}}.bind(null,r),o=function(){p(r)});return n(t),function(e){if(e){if(e.css===t.css&&e.media===t.media&&e.sourceMap===t.sourceMap)return;n(t=e)}else o()}}t.exports=function(t,e){if("undefined"!=typeof DEBUG&&DEBUG&&"object"!=typeof document)throw new Error("The style-loader cannot be used in a non-browser environment");(e=e||{}).attrs="object"==typeof e.attrs?e.attrs:{},e.singleton||"boolean"==typeof e.singleton||(e.singleton=o()),e.insertInto||(e.insertInto="head"),e.insertAt||(e.insertAt="bottom");var r=l(t,e);return h(r,e),function(t){for(var o=[],i=0;i=8&&(s=r+n))),s)for(l=h.getUint16(s,o),u=0;u21?"-21px":"0px",t.width=this.cropW>0?this.cropW:0,t.height=this.cropH>0?this.cropH:0,this.infoTrue){var e=1;this.high&&!this.full&&(e=window.devicePixelRatio),1!==this.enlarge&!this.full&&(e=Math.abs(Number(this.enlarge))),t.width=t.width*e,t.height=t.height*e,this.full&&(t.width=t.width/this.scale,t.height=t.height/this.scale)}return t.width=t.width.toFixed(0),t.height=t.height.toFixed(0),t},isIE:function(){navigator.userAgent;var t=!!window.ActiveXObject||"ActiveXObject"in window;return t},passive:function(){return this.isIE?null:{passive:!1}}},watch:{img:function(){this.checkedImg()},imgs:function(t){""!==t&&this.reload()},cropW:function(){this.showPreview()},cropH:function(){this.showPreview()},cropOffsertX:function(){this.showPreview()},cropOffsertY:function(){this.showPreview()},scale:function(t,e){this.showPreview()},x:function(){this.showPreview()},y:function(){this.showPreview()},autoCrop:function(t){t&&this.goAutoCrop()},autoCropWidth:function(){this.autoCrop&&this.goAutoCrop()},autoCropHeight:function(){this.autoCrop&&this.goAutoCrop()},mode:function(){this.checkedImg()},rotate:function(){this.showPreview(),(this.autoCrop||this.cropW>0||this.cropH>0)&&this.goAutoCrop(this.cropW,this.cropH)}},methods:{getVersion:function(t){for(var e=navigator.userAgent.split(" "),r="",n=new RegExp(t,"i"),o=0;o=81)e=-1;else if(this.getVersion("safari")[0]>=605){var i=this.getVersion("version");i[0]>13&&i[1]>1&&(e=-1)}else{var a=navigator.userAgent.toLowerCase().match(/cpu iphone os (.*?) like mac os/);if(a){var s=a[1];((s=s.split("_"))[0]>13||s[0]>=13&&s[1]>=4)&&(e=-1)}}var c=document.createElement("canvas"),u=c.getContext("2d");switch(u.save(),e){case 2:c.width=r,c.height=n,u.translate(r,0),u.scale(-1,1);break;case 3:c.width=r,c.height=n,u.translate(r/2,n/2),u.rotate(180*Math.PI/180),u.translate(-r/2,-n/2);break;case 4:c.width=r,c.height=n,u.translate(0,n),u.scale(1,-1);break;case 5:c.height=r,c.width=n,u.rotate(.5*Math.PI),u.scale(1,-1);break;case 6:c.width=n,c.height=r,u.translate(n/2,r/2),u.rotate(90*Math.PI/180),u.translate(-r/2,-n/2);break;case 7:c.height=r,c.width=n,u.rotate(.5*Math.PI),u.translate(r,-n),u.scale(-1,1);break;case 8:c.height=r,c.width=n,u.translate(n/2,r/2),u.rotate(-90*Math.PI/180),u.translate(-r/2,-n/2);break;default:c.width=r,c.height=n}u.drawImage(t,0,0,r,n),u.restore(),c.toBlob((function(t){var e=URL.createObjectURL(t);URL.revokeObjectURL(o.imgs),o.imgs=e}),"image/"+this.outputType,1)},checkedImg:function(){var t=this;if(null===this.img||""===this.img)return this.imgs="",void this.clearCrop();this.loading=!0,this.scale=1,this.rotate=0,this.clearCrop();var e=new Image;if(e.onload=function(){if(""===t.img)return t.$emit("imgLoad","error"),t.$emit("img-load","error"),!1;var r=e.width,n=e.height;i.getData(e).then((function(o){t.orientation=o.orientation||1;var i=Number(t.maxImgSize);!t.orientation&&ri&&(n=n/r*i,r=i),n>i&&(r=r/n*i,n=i),t.checkOrientationImage(e,t.orientation,r,n))}))},e.onerror=function(){t.$emit("imgLoad","error"),t.$emit("img-load","error")},"data"!==this.img.substr(0,4)&&(e.crossOrigin=""),this.isIE){var r=new XMLHttpRequest;r.onload=function(){var t=URL.createObjectURL(this.response);e.src=t},r.open("GET",this.img,!0),r.responseType="blob",r.send()}else e.src=this.img},startMove:function(t){if(t.preventDefault(),this.move&&!this.crop){if(!this.canMove)return!1;this.moveX=("clientX"in t?t.clientX:t.touches[0].clientX)-this.x,this.moveY=("clientY"in t?t.clientY:t.touches[0].clientY)-this.y,t.touches?(window.addEventListener("touchmove",this.moveImg),window.addEventListener("touchend",this.leaveImg),2==t.touches.length&&(this.touches=t.touches,window.addEventListener("touchmove",this.touchScale),window.addEventListener("touchend",this.cancelTouchScale))):(window.addEventListener("mousemove",this.moveImg),window.addEventListener("mouseup",this.leaveImg)),this.$emit("imgMoving",{moving:!0,axis:this.getImgAxis()}),this.$emit("img-moving",{moving:!0,axis:this.getImgAxis()})}else this.cropping=!0,window.addEventListener("mousemove",this.createCrop),window.addEventListener("mouseup",this.endCrop),window.addEventListener("touchmove",this.createCrop),window.addEventListener("touchend",this.endCrop),this.cropOffsertX=t.offsetX?t.offsetX:t.touches[0].pageX-this.$refs.cropper.offsetLeft,this.cropOffsertY=t.offsetY?t.offsetY:t.touches[0].pageY-this.$refs.cropper.offsetTop,this.cropX="clientX"in t?t.clientX:t.touches[0].clientX,this.cropY="clientY"in t?t.clientY:t.touches[0].clientY,this.cropChangeX=this.cropOffsertX,this.cropChangeY=this.cropOffsertY,this.cropW=0,this.cropH=0},touchScale:function(t){var e=this;t.preventDefault();var r=this.scale,n=this.touches[0].clientX,o=this.touches[0].clientY,i=t.touches[0].clientX,a=t.touches[0].clientY,s=this.touches[1].clientX,c=this.touches[1].clientY,u=t.touches[1].clientX,h=t.touches[1].clientY,l=Math.sqrt(Math.pow(n-s,2)+Math.pow(o-c,2)),f=Math.sqrt(Math.pow(i-u,2)+Math.pow(a-h,2))-l,p=1,d=(p=(p=p/this.trueWidth>p/this.trueHeight?p/this.trueHeight:p/this.trueWidth)>.1?.1:p)*f;if(!this.touchNow){if(this.touchNow=!0,f>0?r+=Math.abs(d):f<0&&r>Math.abs(d)&&(r-=Math.abs(d)),this.touches=t.touches,setTimeout((function(){e.touchNow=!1}),8),!this.checkoutImgAxis(this.x,this.y,r))return!1;this.scale=r}},cancelTouchScale:function(t){window.removeEventListener("touchmove",this.touchScale)},moveImg:function(t){var e=this;if(t.preventDefault(),t.touches&&2===t.touches.length)return this.touches=t.touches,window.addEventListener("touchmove",this.touchScale),window.addEventListener("touchend",this.cancelTouchScale),window.removeEventListener("touchmove",this.moveImg),!1;var r,n,o="clientX"in t?t.clientX:t.touches[0].clientX,i="clientY"in t?t.clientY:t.touches[0].clientY;r=o-this.moveX,n=i-this.moveY,this.$nextTick((function(){if(e.centerBox){var t,o,i,a,s=e.getImgAxis(r,n,e.scale),c=e.getCropAxis(),u=e.trueHeight*e.scale,h=e.trueWidth*e.scale;switch(e.rotate){case 1:case-1:case 3:case-3:t=e.cropOffsertX-e.trueWidth*(1-e.scale)/2+(u-h)/2,o=e.cropOffsertY-e.trueHeight*(1-e.scale)/2+(h-u)/2,i=t-u+e.cropW,a=o-h+e.cropH;break;default:t=e.cropOffsertX-e.trueWidth*(1-e.scale)/2,o=e.cropOffsertY-e.trueHeight*(1-e.scale)/2,i=t-h+e.cropW,a=o-u+e.cropH}s.x1>=c.x1&&(r=t),s.y1>=c.y1&&(n=o),s.x2<=c.x2&&(r=i),s.y2<=c.y2&&(n=a)}e.x=r,e.y=n,e.$emit("imgMoving",{moving:!0,axis:e.getImgAxis()}),e.$emit("img-moving",{moving:!0,axis:e.getImgAxis()})}))},leaveImg:function(t){window.removeEventListener("mousemove",this.moveImg),window.removeEventListener("touchmove",this.moveImg),window.removeEventListener("mouseup",this.leaveImg),window.removeEventListener("touchend",this.leaveImg),this.$emit("imgMoving",{moving:!1,axis:this.getImgAxis()}),this.$emit("img-moving",{moving:!1,axis:this.getImgAxis()})},scaleImg:function(){this.canScale&&window.addEventListener(this.support,this.changeSize,this.passive)},cancelScale:function(){this.canScale&&window.removeEventListener(this.support,this.changeSize)},changeSize:function(t){var e=this;t.preventDefault();var r=this.scale,n=t.deltaY||t.wheelDelta;n=navigator.userAgent.indexOf("Firefox")>0?30*n:n,this.isIE&&(n=-n);var o=this.coe,i=(o=o/this.trueWidth>o/this.trueHeight?o/this.trueHeight:o/this.trueWidth)*n;i<0?r+=Math.abs(i):r>Math.abs(i)&&(r-=Math.abs(i));var a=i<0?"add":"reduce";if(a!==this.coeStatus&&(this.coeStatus=a,this.coe=.2),this.scaling||(this.scalingSet=setTimeout((function(){e.scaling=!1,e.coe=e.coe+=.01}),50)),this.scaling=!0,!this.checkoutImgAxis(this.x,this.y,r))return!1;this.scale=r},changeScale:function(t){var e=this.scale;t=t||1;var r=20;if((t*=r=r/this.trueWidth>r/this.trueHeight?r/this.trueHeight:r/this.trueWidth)>0?e+=Math.abs(t):e>Math.abs(t)&&(e-=Math.abs(t)),!this.checkoutImgAxis(this.x,this.y,e))return!1;this.scale=e},createCrop:function(t){var e=this;t.preventDefault();var r="clientX"in t?t.clientX:t.touches?t.touches[0].clientX:0,n="clientY"in t?t.clientY:t.touches?t.touches[0].clientY:0;this.$nextTick((function(){var t=r-e.cropX,o=n-e.cropY;if(t>0?(e.cropW=t+e.cropChangeX>e.w?e.w-e.cropChangeX:t,e.cropOffsertX=e.cropChangeX):(e.cropW=e.w-e.cropChangeX+Math.abs(t)>e.w?e.cropChangeX:Math.abs(t),e.cropOffsertX=e.cropChangeX+t>0?e.cropChangeX+t:0),e.fixed){var i=e.cropW/e.fixedNumber[0]*e.fixedNumber[1];i+e.cropOffsertY>e.h?(e.cropH=e.h-e.cropOffsertY,e.cropW=e.cropH/e.fixedNumber[1]*e.fixedNumber[0],e.cropOffsertX=t>0?e.cropChangeX:e.cropChangeX-e.cropW):e.cropH=i,e.cropOffsertY=e.cropOffsertY}else o>0?(e.cropH=o+e.cropChangeY>e.h?e.h-e.cropChangeY:o,e.cropOffsertY=e.cropChangeY):(e.cropH=e.h-e.cropChangeY+Math.abs(o)>e.h?e.cropChangeY:Math.abs(o),e.cropOffsertY=e.cropChangeY+o>0?e.cropChangeY+o:0)}))},changeCropSize:function(t,e,r,n,o){t.preventDefault(),window.addEventListener("mousemove",this.changeCropNow),window.addEventListener("mouseup",this.changeCropEnd),window.addEventListener("touchmove",this.changeCropNow),window.addEventListener("touchend",this.changeCropEnd),this.canChangeX=e,this.canChangeY=r,this.changeCropTypeX=n,this.changeCropTypeY=o,this.cropX="clientX"in t?t.clientX:t.touches[0].clientX,this.cropY="clientY"in t?t.clientY:t.touches[0].clientY,this.cropOldW=this.cropW,this.cropOldH=this.cropH,this.cropChangeX=this.cropOffsertX,this.cropChangeY=this.cropOffsertY,this.fixed&&this.canChangeX&&this.canChangeY&&(this.canChangeY=0),this.$emit("change-crop-size",{width:this.cropW,height:this.cropH})},changeCropNow:function(t){var e=this;t.preventDefault();var r="clientX"in t?t.clientX:t.touches?t.touches[0].clientX:0,n="clientY"in t?t.clientY:t.touches?t.touches[0].clientY:0,o=this.w,i=this.h,a=0,s=0;if(this.centerBox){var c=this.getImgAxis(),u=c.x2,h=c.y2;a=c.x1>0?c.x1:0,s=c.y1>0?c.y1:0,o>u&&(o=u),i>h&&(i=h)}this.$nextTick((function(){var t=r-e.cropX,c=n-e.cropY;if(e.canChangeX&&(1===e.changeCropTypeX?e.cropOldW-t>0?(e.cropW=o-e.cropChangeX-t<=o-a?e.cropOldW-t:e.cropOldW+e.cropChangeX-a,e.cropOffsertX=o-e.cropChangeX-t<=o-a?e.cropChangeX+t:a):(e.cropW=Math.abs(t)+e.cropChangeX<=o?Math.abs(t)-e.cropOldW:o-e.cropOldW-e.cropChangeX,e.cropOffsertX=e.cropChangeX+e.cropOldW):2===e.changeCropTypeX&&(e.cropOldW+t>0?(e.cropW=e.cropOldW+t+e.cropOffsertX<=o?e.cropOldW+t:o-e.cropOffsertX,e.cropOffsertX=e.cropChangeX):(e.cropW=o-e.cropChangeX+Math.abs(t+e.cropOldW)<=o-a?Math.abs(t+e.cropOldW):e.cropChangeX-a,e.cropOffsertX=o-e.cropChangeX+Math.abs(t+e.cropOldW)<=o-a?e.cropChangeX-Math.abs(t+e.cropOldW):a))),e.canChangeY&&(1===e.changeCropTypeY?e.cropOldH-c>0?(e.cropH=i-e.cropChangeY-c<=i-s?e.cropOldH-c:e.cropOldH+e.cropChangeY-s,e.cropOffsertY=i-e.cropChangeY-c<=i-s?e.cropChangeY+c:s):(e.cropH=Math.abs(c)+e.cropChangeY<=i?Math.abs(c)-e.cropOldH:i-e.cropOldH-e.cropChangeY,e.cropOffsertY=e.cropChangeY+e.cropOldH):2===e.changeCropTypeY&&(e.cropOldH+c>0?(e.cropH=e.cropOldH+c+e.cropOffsertY<=i?e.cropOldH+c:i-e.cropOffsertY,e.cropOffsertY=e.cropChangeY):(e.cropH=i-e.cropChangeY+Math.abs(c+e.cropOldH)<=i-s?Math.abs(c+e.cropOldH):e.cropChangeY-s,e.cropOffsertY=i-e.cropChangeY+Math.abs(c+e.cropOldH)<=i-s?e.cropChangeY-Math.abs(c+e.cropOldH):s))),e.canChangeX&&e.fixed){var u=e.cropW/e.fixedNumber[0]*e.fixedNumber[1];u+e.cropOffsertY>i?(e.cropH=i-e.cropOffsertY,e.cropW=e.cropH/e.fixedNumber[1]*e.fixedNumber[0]):e.cropH=u}if(e.canChangeY&&e.fixed){var h=e.cropH/e.fixedNumber[1]*e.fixedNumber[0];h+e.cropOffsertX>o?(e.cropW=o-e.cropOffsertX,e.cropH=e.cropW/e.fixedNumber[0]*e.fixedNumber[1]):e.cropW=h}}))},checkCropLimitSize:function(){this.cropW,this.cropH;var t=this.limitMinSize,e=new Array;return e=Array.isArray[t]?t:[t,t],[parseFloat(e[0]),parseFloat(e[1])]},changeCropEnd:function(t){window.removeEventListener("mousemove",this.changeCropNow),window.removeEventListener("mouseup",this.changeCropEnd),window.removeEventListener("touchmove",this.changeCropNow),window.removeEventListener("touchend",this.changeCropEnd)},endCrop:function(){0===this.cropW&&0===this.cropH&&(this.cropping=!1),window.removeEventListener("mousemove",this.createCrop),window.removeEventListener("mouseup",this.endCrop),window.removeEventListener("touchmove",this.createCrop),window.removeEventListener("touchend",this.endCrop)},startCrop:function(){this.crop=!0},stopCrop:function(){this.crop=!1},clearCrop:function(){this.cropping=!1,this.cropW=0,this.cropH=0},cropMove:function(t){if(t.preventDefault(),!this.canMoveBox)return this.crop=!1,this.startMove(t),!1;if(t.touches&&2===t.touches.length)return this.crop=!1,this.startMove(t),this.leaveCrop(),!1;window.addEventListener("mousemove",this.moveCrop),window.addEventListener("mouseup",this.leaveCrop),window.addEventListener("touchmove",this.moveCrop),window.addEventListener("touchend",this.leaveCrop);var e,r,n="clientX"in t?t.clientX:t.touches[0].clientX,o="clientY"in t?t.clientY:t.touches[0].clientY;e=n-this.cropOffsertX,r=o-this.cropOffsertY,this.cropX=e,this.cropY=r,this.$emit("cropMoving",{moving:!0,axis:this.getCropAxis()}),this.$emit("crop-moving",{moving:!0,axis:this.getCropAxis()})},moveCrop:function(t,e){var r=this,n=0,o=0;t&&(t.preventDefault(),n="clientX"in t?t.clientX:t.touches[0].clientX,o="clientY"in t?t.clientY:t.touches[0].clientY),this.$nextTick((function(){var t,i,a=n-r.cropX,s=o-r.cropY;if(e&&(a=r.cropOffsertX,s=r.cropOffsertY),t=a<=0?0:a+r.cropW>r.w?r.w-r.cropW:a,i=s<=0?0:s+r.cropH>r.h?r.h-r.cropH:s,r.centerBox){var c=r.getImgAxis();t<=c.x1&&(t=c.x1),t+r.cropW>c.x2&&(t=c.x2-r.cropW),i<=c.y1&&(i=c.y1),i+r.cropH>c.y2&&(i=c.y2-r.cropH)}r.cropOffsertX=t,r.cropOffsertY=i,r.$emit("cropMoving",{moving:!0,axis:r.getCropAxis()}),r.$emit("crop-moving",{moving:!0,axis:r.getCropAxis()})}))},getImgAxis:function(t,e,r){t=t||this.x,e=e||this.y,r=r||this.scale;var n={x1:0,x2:0,y1:0,y2:0},o=this.trueWidth*r,i=this.trueHeight*r;switch(this.rotate){case 0:n.x1=t+this.trueWidth*(1-r)/2,n.x2=n.x1+this.trueWidth*r,n.y1=e+this.trueHeight*(1-r)/2,n.y2=n.y1+this.trueHeight*r;break;case 1:case-1:case 3:case-3:n.x1=t+this.trueWidth*(1-r)/2+(o-i)/2,n.x2=n.x1+this.trueHeight*r,n.y1=e+this.trueHeight*(1-r)/2+(i-o)/2,n.y2=n.y1+this.trueWidth*r;break;default:n.x1=t+this.trueWidth*(1-r)/2,n.x2=n.x1+this.trueWidth*r,n.y1=e+this.trueHeight*(1-r)/2,n.y2=n.y1+this.trueHeight*r}return n},getCropAxis:function(){var t={x1:0,x2:0,y1:0,y2:0};return t.x1=this.cropOffsertX,t.x2=t.x1+this.cropW,t.y1=this.cropOffsertY,t.y2=t.y1+this.cropH,t},leaveCrop:function(t){window.removeEventListener("mousemove",this.moveCrop),window.removeEventListener("mouseup",this.leaveCrop),window.removeEventListener("touchmove",this.moveCrop),window.removeEventListener("touchend",this.leaveCrop),this.$emit("cropMoving",{moving:!1,axis:this.getCropAxis()}),this.$emit("crop-moving",{moving:!1,axis:this.getCropAxis()})},getCropChecked:function(t){var e=this,r=document.createElement("canvas"),n=new Image,o=this.rotate,i=this.trueWidth,a=this.trueHeight,s=this.cropOffsertX,c=this.cropOffsertY;function u(t,e){r.width=Math.round(t),r.height=Math.round(e)}n.onload=function(){if(0!==e.cropW){var h=r.getContext("2d"),l=1;e.high&!e.full&&(l=window.devicePixelRatio),1!==e.enlarge&!e.full&&(l=Math.abs(Number(e.enlarge)));var f=e.cropW*l,p=e.cropH*l,d=i*e.scale*l,g=a*e.scale*l,m=(e.x-s+e.trueWidth*(1-e.scale)/2)*l,v=(e.y-c+e.trueHeight*(1-e.scale)/2)*l;switch(u(f,p),h.save(),o){case 0:e.full?(u(f/e.scale,p/e.scale),h.drawImage(n,m/e.scale,v/e.scale,d/e.scale,g/e.scale)):h.drawImage(n,m,v,d,g);break;case 1:case-3:e.full?(u(f/e.scale,p/e.scale),m=m/e.scale+(d/e.scale-g/e.scale)/2,v=v/e.scale+(g/e.scale-d/e.scale)/2,h.rotate(90*o*Math.PI/180),h.drawImage(n,v,-m-g/e.scale,d/e.scale,g/e.scale)):(m+=(d-g)/2,v+=(g-d)/2,h.rotate(90*o*Math.PI/180),h.drawImage(n,v,-m-g,d,g));break;case 2:case-2:e.full?(u(f/e.scale,p/e.scale),h.rotate(90*o*Math.PI/180),m/=e.scale,v/=e.scale,h.drawImage(n,-m-d/e.scale,-v-g/e.scale,d/e.scale,g/e.scale)):(h.rotate(90*o*Math.PI/180),h.drawImage(n,-m-d,-v-g,d,g));break;case 3:case-1:e.full?(u(f/e.scale,p/e.scale),m=m/e.scale+(d/e.scale-g/e.scale)/2,v=v/e.scale+(g/e.scale-d/e.scale)/2,h.rotate(90*o*Math.PI/180),h.drawImage(n,-v-d/e.scale,m,d/e.scale,g/e.scale)):(m+=(d-g)/2,v+=(g-d)/2,h.rotate(90*o*Math.PI/180),h.drawImage(n,-v-d,m,d,g));break;default:e.full?(u(f/e.scale,p/e.scale),h.drawImage(n,m/e.scale,v/e.scale,d/e.scale,g/e.scale)):h.drawImage(n,m,v,d,g)}h.restore()}else{var y=i*e.scale,w=a*e.scale,b=r.getContext("2d");switch(b.save(),o){case 0:u(y,w),b.drawImage(n,0,0,y,w);break;case 1:case-3:u(w,y),b.rotate(90*o*Math.PI/180),b.drawImage(n,0,-w,y,w);break;case 2:case-2:u(y,w),b.rotate(90*o*Math.PI/180),b.drawImage(n,-y,-w,y,w);break;case 3:case-1:u(w,y),b.rotate(90*o*Math.PI/180),b.drawImage(n,-y,0,y,w);break;default:u(y,w),b.drawImage(n,0,0,y,w)}b.restore()}t(r)},"data"!==this.img.substr(0,4)&&(n.crossOrigin="Anonymous"),n.src=this.imgs},getCropData:function(t){var e=this;this.getCropChecked((function(r){t(r.toDataURL("image/"+e.outputType,e.outputSize))}))},getCropBlob:function(t){var e=this;this.getCropChecked((function(r){r.toBlob((function(e){return t(e)}),"image/"+e.outputType,e.outputSize)}))},showPreview:function(){var t=this;if(!this.isCanShow)return!1;this.isCanShow=!1,setTimeout((function(){t.isCanShow=!0}),16);var e=this.cropW,r=this.cropH,n=this.scale,o={};o.div={width:"".concat(e,"px"),height:"".concat(r,"px")};var i=(this.x-this.cropOffsertX)/n,a=(this.y-this.cropOffsertY)/n;o.w=e,o.h=r,o.url=this.imgs,o.img={width:"".concat(this.trueWidth,"px"),height:"".concat(this.trueHeight,"px"),transform:"scale(".concat(n,")translate3d(").concat(i,"px, ").concat(a,"px, ").concat(0,"px)rotateZ(").concat(90*this.rotate,"deg)")},o.html='\n
\n
\n \n
\n
'),this.$emit("realTime",o),this.$emit("real-time",o)},reload:function(){var t=this,e=new Image;e.onload=function(){t.w=parseFloat(window.getComputedStyle(t.$refs.cropper).width),t.h=parseFloat(window.getComputedStyle(t.$refs.cropper).height),t.trueWidth=e.width,t.trueHeight=e.height,t.original?t.scale=1:t.scale=t.checkedMode(),t.$nextTick((function(){t.x=-(t.trueWidth-t.trueWidth*t.scale)/2+(t.w-t.trueWidth*t.scale)/2,t.y=-(t.trueHeight-t.trueHeight*t.scale)/2+(t.h-t.trueHeight*t.scale)/2,t.loading=!1,t.autoCrop&&t.goAutoCrop(),t.$emit("img-load","success"),t.$emit("imgLoad","success"),setTimeout((function(){t.showPreview()}),20)}))},e.onerror=function(){t.$emit("imgLoad","error"),t.$emit("img-load","error")},e.src=this.imgs},checkedMode:function(){var t=1,e=(this.trueWidth,this.trueHeight),r=this.mode.split(" ");switch(r[0]){case"contain":this.trueWidth>this.w&&(t=this.w/this.trueWidth),this.trueHeight*t>this.h&&(t=this.h/this.trueHeight);break;case"cover":(e*=t=this.w/this.trueWidth)0,i=(o?this.trueHeight:this.trueWidth)*this.scale,a=(o?this.trueWidth:this.trueHeight)*this.scale;r=ir?r:s,c=c>n?n:c,this.fixed&&(c=s/this.fixedNumber[0]*this.fixedNumber[1]),c>this.h&&(s=(c=this.h)/this.fixedNumber[1]*this.fixedNumber[0]),this.changeCrop(s,c)}},changeCrop:function(t,e){var r=this;if(this.centerBox){var n=this.getImgAxis();t>n.x2-n.x1&&(e=(t=n.x2-n.x1)/this.fixedNumber[0]*this.fixedNumber[1]),e>n.y2-n.y1&&(t=(e=n.y2-n.y1)/this.fixedNumber[1]*this.fixedNumber[0])}this.cropW=t,this.cropH=e,this.checkCropLimitSize(),this.$nextTick((function(){r.cropOffsertX=(r.w-r.cropW)/2,r.cropOffsertY=(r.h-r.cropH)/2,r.centerBox&&r.moveCrop(null,!0)}))},refresh:function(){var t=this;this.img,this.imgs="",this.scale=1,this.crop=!1,this.rotate=0,this.w=0,this.h=0,this.trueWidth=0,this.trueHeight=0,this.clearCrop(),this.$nextTick((function(){t.checkedImg()}))},rotateLeft:function(){this.rotate=this.rotate<=-3?0:this.rotate-1},rotateRight:function(){this.rotate=this.rotate>=3?0:this.rotate+1},rotateClear:function(){this.rotate=0},checkoutImgAxis:function(t,e,r){t=t||this.x,e=e||this.y,r=r||this.scale;var n=!0;if(this.centerBox){var o=this.getImgAxis(t,e,r),i=this.getCropAxis();o.x1>=i.x1&&(n=!1),o.x2<=i.x2&&(n=!1),o.y1>=i.y1&&(n=!1),o.y2<=i.y2&&(n=!1)}return n}},mounted:function(){this.support="onwheel"in document.createElement("div")?"wheel":void 0!==document.onmousewheel?"mousewheel":"DOMMouseScroll";var t=this,e=navigator.userAgent;this.isIOS=!!e.match(/\(i[^;]+;( U;)? CPU.+Mac OS X/),HTMLCanvasElement.prototype.toBlob||Object.defineProperty(HTMLCanvasElement.prototype,"toBlob",{value:function(e,r,n){for(var o=atob(this.toDataURL(r,n).split(",")[1]),i=o.length,a=new Uint8Array(i),s=0;sl)r=o(n,e=u[l++]),void 0!==r&&c(h,e,r);return h}})},c051:function(t,e,r){var n=r("da10"),o=r("b338").f,i={}.toString,a="object"==typeof window&&window&&Object.getOwnPropertyNames?Object.getOwnPropertyNames(window):[],s=function(t){try{return o(t)}catch(e){return a.slice()}};t.exports.f=function(t){return a&&"[object Window]"==i.call(t)?s(t):o(n(t))}},c10f:function(t,e,r){var n=r("2732"),o=r("fc8c"),i="["+o+"]",a=RegExp("^"+i+i+"*"),s=RegExp(i+i+"*$"),c=function(t){return function(e){var r=String(n(e));return 1&t&&(r=r.replace(a,"")),2&t&&(r=r.replace(s,"")),r}};t.exports={start:c(1),end:c(2),trim:c(3)}},c3ba:function(t,e,r){"use strict";var n=r("5a9e").exportTypedArrayMethod,o=r("efe2"),i=r("d890"),a=i.Uint8Array,s=a&&a.prototype||{},c=[].toString,u=[].join;o((function(){c.call({})}))&&(c=function(){return u.call(this)});var h=s.toString!=c;n("toString",c,h)},ce3c:function(t,e,r){"use strict";function n(t,e,r){return e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}r.d(e,"a",(function(){return n}))},cfd1:function(t,e,r){"use strict";var n=r("5a9e"),o=r("45af").indexOf,i=n.aTypedArray,a=n.exportTypedArrayMethod;a("indexOf",(function(t){return o(i(this),t,arguments.length>1?arguments[1]:void 0)}))},d104:function(t,e,r){"use strict";var n=r("d890"),o=r("5a9e"),i=r("a133"),a=r("90fb"),s=a("iterator"),c=n.Uint8Array,u=i.values,h=i.keys,l=i.entries,f=o.aTypedArray,p=o.exportTypedArrayMethod,d=c&&c.prototype[s],g=!!d&&("values"==d.name||void 0==d.name),m=function(){return u.call(f(this))};p("entries",(function(){return l.call(f(this))})),p("keys",(function(){return h.call(f(this))})),p("values",m,!g),p(s,m,!g)},d77f:function(t,e){t.exports="undefined"!==typeof ArrayBuffer&&"undefined"!==typeof DataView},d7e1:function(t,e,r){"use strict";var n=r("efe2");t.exports=function(t,e){var r=[][t];return!!r&&n((function(){r.call(null,e||function(){throw 1},1)}))}},db0a:function(t,e,r){"use strict";var n=r("5a9e"),o=r("5dfd").filter,i=r("ef4c"),a=n.aTypedArray,s=n.aTypedArrayConstructor,c=n.exportTypedArrayMethod;c("filter",(function(t){var e=o(a(this),t,arguments.length>1?arguments[1]:void 0),r=i(this,this.constructor),n=0,c=e.length,u=new(s(r))(c);while(c>n)u[n]=e[n++];return u}))},dbb3:function(t,e,r){"use strict";var n=r("1c8b"),o=r("5dfd").filter,i=r("1ea7"),a=r("ff9c"),s=i("filter"),c=a("filter");n({target:"Array",proto:!0,forced:!s||!c},{filter:function(t){return o(this,t,arguments.length>1?arguments[1]:void 0)}})},e026:function(t,e){var r=1/0,n=Math.abs,o=Math.pow,i=Math.floor,a=Math.log,s=Math.LN2,c=function(t,e,c){var u,h,l,f=new Array(c),p=8*c-e-1,d=(1<>1,m=23===e?o(2,-24)-o(2,-77):0,v=t<0||0===t&&1/t<0?1:0,y=0;for(t=n(t),t!=t||t===r?(h=t!=t?1:0,u=d):(u=i(a(t)/s),t*(l=o(2,-u))<1&&(u--,l*=2),t+=u+g>=1?m/l:m*o(2,1-g),t*l>=2&&(u++,l/=2),u+g>=d?(h=0,u=d):u+g>=1?(h=(t*l-1)*o(2,e),u+=g):(h=t*o(2,g-1)*o(2,e),u=0));e>=8;f[y++]=255&h,h/=256,e-=8);for(u=u<0;f[y++]=255&u,u/=256,p-=8);return f[--y]|=128*v,f},u=function(t,e){var n,i=t.length,a=8*i-e-1,s=(1<>1,u=a-7,h=i-1,l=t[h--],f=127&l;for(l>>=7;u>0;f=256*f+t[h],h--,u-=8);for(n=f&(1<<-u)-1,f>>=-u,u+=e;u>0;n=256*n+t[h],h--,u-=8);if(0===f)f=1-c;else{if(f===s)return n?NaN:l?-r:r;n+=o(2,e),f-=c}return(l?-1:1)*n*o(2,f-e)};t.exports={pack:c,unpack:u}},e62b:function(t,e,r){"use strict";var n=r("e349"),o=r("3553"),i=r("69c5"),a=r("98a9"),s=r("d88d"),c=r("1bbd"),u=r("b60f");t.exports=function(t){var e,r,h,l,f,p,d=o(t),g="function"==typeof this?this:Array,m=arguments.length,v=m>1?arguments[1]:void 0,y=void 0!==v,w=u(d),b=0;if(y&&(v=n(v,m>2?arguments[2]:void 0,2)),void 0==w||g==Array&&a(w))for(e=s(d.length),r=new g(e);e>b;b++)p=y?v(d[b],b):d[b],c(r,b,p);else for(l=w.call(d),f=l.next,r=new g;!(h=f.call(l)).done;b++)p=y?i(l,v,[h.value,b],!0):h.value,c(r,b,p);return r.length=b,r}},e671:function(t,e,r){"use strict";var n=r("5a9e"),o=r("d88d"),i=r("7aeb"),a=r("3553"),s=r("efe2"),c=n.aTypedArray,u=n.exportTypedArrayMethod,h=s((function(){new Int8Array(1).set({})}));u("set",(function(t){c(this);var e=i(arguments.length>1?arguments[1]:void 0,1),r=this.length,n=a(t),s=o(n.length),u=0;if(s+e>r)throw RangeError("Wrong length");while(u","private":false,"scripts":{"dev":"webpack-dev-server --inline --progress --config build/webpack.dev.conf.js","start":"npm run dev","build":"node build/build.js"},"dependencies":{"vue":"^2.5.2"},"devDependencies":{"autoprefixer":"^7.1.2","babel-core":"^6.22.1","babel-helper-vue-jsx-merge-props":"^2.0.3","babel-loader":"^7.1.1","babel-plugin-syntax-jsx":"^6.18.0","babel-plugin-transform-runtime":"^6.22.0","babel-plugin-transform-vue-jsx":"^3.5.0","babel-preset-env":"^1.3.2","babel-preset-stage-2":"^6.22.0","chalk":"^2.0.1","copy-webpack-plugin":"^4.0.1","css-loader":"^0.28.0","extract-text-webpack-plugin":"^3.0.0","file-loader":"^1.1.4","friendly-errors-webpack-plugin":"^1.6.1","html-webpack-plugin":"^2.30.1","js-yaml":"^3.13.1","lodash":"^4.17.15","mem":"^6.0.0","mixin-deep":"^2.0.1","node-notifier":"^5.1.2","optimize-css-assets-webpack-plugin":"^3.2.0","ora":"^1.2.0","portfinder":"^1.0.13","postcss-import":"^11.0.0","postcss-loader":"^2.0.8","postcss-url":"^7.2.1","rimraf":"^2.6.0","semver":"^5.3.0","set-value":"^3.0.1","shelljs":"^0.7.6","uglifyjs-webpack-plugin":"^1.1.1","url-loader":"^0.5.8","vue-loader":"^13.3.0","vue-style-loader":"^3.0.1","vue-template-compiler":"^2.5.2","webpack":"^3.6.0","webpack-bundle-analyzer":"^2.13.1","webpack-dev-server":"^2.11.5","webpack-merge":"^4.1.0"},"engines":{"node":">= 6.0.0","npm":">= 3.0.0"},"browserslist":["> 1%","last 2 versions","not ie <= 8"],"main":"./src/index.js","repository":{"type":"git","url":"git+https://github.com/acccccccb/vue-img-cutter.git"},"keywords":["image","crop","cutter","vue","裁剪"],"license":"Apache2.0","bugs":{"url":"https://github.com/acccccccb/vue-img-cutter/issues"},"homepage":"https://ihtmlcss.com/demo/dist/#/croptool","_from":"vue-img-cutter@2.1.10","_resolved":"https://registry.npm.taobao.org/vue-img-cutter/download/vue-img-cutter-2.1.10.tgz"}')},e925:function(t,e,r){"use strict";var n=r("0358"),o=r.n(n);function i(t){if(null===t||"undefined"===typeof t)return"";var e,r,n=t+"",o="",i=0;e=r=0,i=n.length;for(var a=0;a127&&s<2048)c=String.fromCharCode(s>>6|192,63&s|128);else if((63488&s^55296)>0)c=String.fromCharCode(s>>12|224,s>>6&63|128,63&s|128);else{if((64512&s^55296)>0)throw new RangeError("Unmatched trail surrogate at "+a);var u=n.charCodeAt(++a);if((64512&u^56320)>0)throw new RangeError("Unmatched lead surrogate at "+(a-1));s=((1023&s)<<10)+(1023&u)+65536,c=String.fromCharCode(s>>18|240,s>>12&63|128,s>>6&63|128,63&s|128)}null!==c&&(r>e&&(o+=n.slice(e,r)),o+=c,e=r=a+1)}return r>e&&(o+=n.slice(e,i)),o}function a(t){var e,r,n,o,a,s,c,u,h="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",l=0,f=0,p="",d=[];if(!t)return t;t=i(t+"");do{e=t.charCodeAt(l++),r=t.charCodeAt(l++),n=t.charCodeAt(l++),u=e<<16|r<<8|n,o=u>>18&63,a=u>>12&63,s=u>>6&63,c=63&u,d[f++]=h.charAt(o)+h.charAt(a)+h.charAt(s)+h.charAt(c)}while(l>16&255,r=c>>8&255,n=255&c,p[l++]=64===a?String.fromCharCode(e):64===s?String.fromCharCode(e,r):String.fromCharCode(e,r,n)}while(h0&&o[o.length-1])&&(6===i[0]||2===i[0])){a=0;continue}if(3===i[0]&&(!o||i[1]>o[0]&&i[1]t.size)r=t.size;else while(t.size>1e4*r)r*=2;for(var n=[],o=Math.ceil(t.size/r),i=0;i3?e[1]:e[0],n=JSON.parse(u(e[e.length-1]));return{ak:r,bucket:n.scope.split(":")[0]}}function L(t){var e=window.URL||window.webkitURL||window.mozURL;return e.createObjectURL(t)}function P(t,e){var r=t.width,n=t.height;switch(e){case 1:return{width:r,height:n,matrix:[1,0,0,1,0,0]};case 2:return{width:r,height:n,matrix:[-1,0,0,1,r,0]};case 3:return{width:r,height:n,matrix:[-1,0,0,-1,r,n]};case 4:return{width:r,height:n,matrix:[1,0,0,-1,0,n]};case 5:return{width:n,height:r,matrix:[0,1,1,0,0,0]};case 6:return{width:n,height:r,matrix:[0,1,-1,0,n,0]};case 7:return{width:n,height:r,matrix:[0,-1,-1,0,n,r]};case 8:return{width:n,height:r,matrix:[0,-1,1,0,0,r]};default:throw new Error("orientation "+e+" is unavailable")}}var _,U=function(){function t(){}return t.prototype.log=function(t,e){var r=Object.values(t).join(",");this.send(r,e,0)},t.prototype.send=function(t,e,r){var n=this,o=B();o.open("POST","https://uplog.qbox.me/log/3"),o.setRequestHeader("Content-type","application/x-www-form-urlencoded"),o.setRequestHeader("Authorization","UpToken "+e),o.onreadystatechange=function(){4===o.readyState&&200!==o.status&&++r<=3&&n.send(t,e,r)},o.send(t)},t}(),R=U,F=function(){function t(t,e){this.runTask=t,this.limit=e,this.queue=[],this.processing=[]}return t.prototype.enqueue=function(t){var e=this;return new Promise((function(r,n){e.queue.push({task:t,resolve:r,reject:n}),e.check()}))},t.prototype.run=function(t){var e=this;this.queue=this.queue.filter((function(e){return e!==t})),this.processing.push(t),this.runTask(t.task).then((function(){e.processing=e.processing.filter((function(e){return e!==t})),t.resolve(),e.check()}),(function(e){return t.reject(e)}))},t.prototype.check=function(){var t=this,e=this.processing.length,r=this.limit-e;this.queue.slice(0,r).forEach((function(e){t.run(e)}))},t}(),N={z0:"z0",z1:"z1",z2:"z2",na0:"na0",as0:"as0"},D=(_={},_[N.z0]={srcUphost:"up.qiniup.com",cdnUphost:"upload.qiniup.com"},_[N.z1]={srcUphost:"up-z1.qiniup.com",cdnUphost:"upload-z1.qiniup.com"},_[N.z2]={srcUphost:"up-z2.qiniup.com",cdnUphost:"upload-z2.qiniup.com"},_[N.na0]={srcUphost:"up-na0.qiniup.com",cdnUphost:"upload-na0.qiniup.com"},_[N.as0]={srcUphost:"up-as0.qiniup.com",cdnUphost:"upload-as0.qiniup.com"},_),j=function(){return j=Object.assign||function(t){for(var e,r=1,n=arguments.length;r0&&o[o.length-1])&&(6===i[0]||2===i[0])){a=0;continue}if(3===i[0]&&(!o||i[1]>o[0]&&i[1]0&&o[o.length-1])&&(6===i[0]||2===i[0])){a=0;continue}if(3===i[0]&&(!o||i[1]>o[0]&&i[1]1e4*Z)throw t=new Error("file size exceed maximum value 10000G"),this.onError(t),t;if(this.putExtra.customVars&&!m(this.putExtra.customVars))throw t=new Error("customVars key should start width x:"),this.onError(t),t;if(this.putExtra.metadata&&!g(this.putExtra.metadata))throw t=new Error("metadata key should start with x-qn-meta-"),this.onError(t),t;c.label=1;case 1:return c.trys.push([1,4,,5]),e=this,[4,Y(this.config,this.token)];case 2:return e.uploadUrl=c.sent(),this.uploadAt=(new Date).getTime(),[4,this.run()];case 3:return r=c.sent(),this.onComplete(r.data),this.config.disableStatisticsReport||this.sendLog(r.reqId,200),[2,r];case 4:if(n=c.sent(),this.clear(),n.isRequestError&&!this.config.disableStatisticsReport&&(o=this.aborted?"":n.reqId,i=this.aborted?-2:n.code,this.sendLog(o,i)),a=n.isRequestError&&0===n.code&&!this.aborted,s=++this.retryCount<=this.config.retryCount,a&&s||612===n.code)return[2,this.putFile()];throw this.onError(n),n;case 5:return[2]}}))}))},t.prototype.clear=function(){this.xhrList.forEach((function(t){return t.abort()})),this.xhrList=[]},t.prototype.stop=function(){this.clear(),this.aborted=!0},t.prototype.addXhr=function(t){this.xhrList.push(t)},t.prototype.sendLog=function(t,e){this.statisticsLogger.log({code:e,reqId:t,host:E(this.uploadUrl),remoteIp:"",port:k(this.uploadUrl),duration:((new Date).getTime()-this.uploadAt)/1e3,time:Math.floor(this.uploadAt/1e3),bytesSent:this.progress?this.progress.total.loaded:0,upType:"jssdk-h5",size:this.file.size},this.token)},t.prototype.getProgressInfoItem=function(t,e){return{loaded:t,size:e,percent:t/e*100}},t}(),et=tt,rt=function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var r in e)e.hasOwnProperty(r)&&(t[r]=e[r])},t(e,r)};return function(e,r){function n(){this.constructor=e}t(e,r),e.prototype=null===r?Object.create(r):(n.prototype=r.prototype,new n)}}(),nt=function(){return nt=Object.assign||function(t){for(var e,r=1,n=arguments.length;r0&&o[o.length-1])&&(6===i[0]||2===i[0])){a=0;continue}if(3===i[0]&&(!o||i[1]>o[0]&&i[1]1024)throw new Error("chunkSize maximum value is 1024");return[4,this.initBeforeUploadChunks()];case 1:return o.sent(),t=new F((function(t){return n.uploadChunk(t)}),this.config.concurrentRequestLimit),e=this.chunks.map((function(e,r){return t.enqueue({chunk:e,index:r})})),r=Promise.all(e).then((function(){return n.mkFileReq()})),r.then((function(){b(n.getLocalKey())}),(function(t){612!==t.code&&400!==t.code||b(n.getLocalKey())})),[2,r]}}))}))},e.prototype.uploadChunk=function(t){return ot(this,void 0,void 0,(function(){var e,r,n,o,i,a,s,c,u,h=this;return it(this,(function(l){switch(l.label){case 0:return e=t.index,r=t.chunk,n=this.uploadedList[e],o=this.config.checkByMD5,i=function(){h.updateChunkProgress(r.size,e)},n&&!o?(i(),[2]):[4,O(r)];case 1:return a=l.sent(),n&&a===n.md5?(i(),[2]):(s=function(t){h.updateChunkProgress(t.loaded,e)},c={body:r,onProgress:s,onCreate:function(t){return h.addXhr(t)}},[4,q(this.token,this.key,t.index+1,this.getUploadInfo(),c)]);case 2:return u=l.sent(),s({loaded:r.size,total:r.size}),this.uploadedList[e]={etag:u.data.etag,md5:u.data.md5,size:r.size},y(this.getLocalKey(),{id:this.uploadId,data:this.uploadedList}),[2]}}))}))},e.prototype.mkFileReq=function(){return ot(this,void 0,void 0,(function(){var t,e,r=this;return it(this,(function(n){switch(n.label){case 0:return t=nt(nt(nt({parts:this.uploadedList.map((function(t,e){return{etag:t.etag,partNumber:e+1}})),fname:this.putExtra.fname},this.putExtra.mimeType&&{mimeType:this.putExtra.mimeType}),this.putExtra.customVars&&{customVars:this.putExtra.customVars}),this.putExtra.metadata&&{metadata:this.putExtra.metadata}),[4,$(this.token,this.key,this.getUploadInfo(),{onCreate:function(t){return r.addXhr(t)},body:JSON.stringify(t)})];case 1:return e=n.sent(),this.updateMkFileProgress(1),[2,e]}}))}))},e.prototype.initBeforeUploadChunks=function(){return ot(this,void 0,void 0,(function(){var t,e;return it(this,(function(r){switch(r.label){case 0:return t=x(this.getLocalKey()),t?[3,2]:(b(this.getLocalKey()),[4,G(this.token,this.bucket,this.key,this.uploadUrl)]);case 1:return e=r.sent(),this.uploadId=e.data.uploadId,this.uploadedList=[],[3,3];case 2:this.uploadId=t.id,this.uploadedList=t.data,r.label=3;case 3:return this.chunks=d(this.file,this.config.chunkSize),this.loaded={mkFileProgress:0,chunks:this.chunks.map((function(t){return 0}))},this.notifyResumeProgress(),[2]}}))}))},e.prototype.getUploadInfo=function(){return{id:this.uploadId,url:this.uploadUrl}},e.prototype.getLocalKey=function(){return w(this.file.name,this.key,this.file.size)},e.prototype.updateChunkProgress=function(t,e){this.loaded.chunks[e]=t,this.notifyResumeProgress()},e.prototype.updateMkFileProgress=function(t){this.loaded.mkFileProgress=t,this.notifyResumeProgress()},e.prototype.notifyResumeProgress=function(){var t=this;this.progress={total:this.getProgressInfoItem(v(this.loaded.chunks)+this.loaded.mkFileProgress,this.file.size+1),chunks:this.chunks.map((function(e,r){return t.getProgressInfoItem(t.loaded.chunks[r],e.size)})),uploadInfo:{id:this.uploadId,url:this.uploadUrl}},this.onData(this.progress)}})(et);var st=function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var r in e)e.hasOwnProperty(r)&&(t[r]=e[r])},t(e,r)};return function(e,r){function n(){this.constructor=e}t(e,r),e.prototype=null===r?Object.create(r):(n.prototype=r.prototype,new n)}}(),ct=function(t,e,r,n){function o(t){return t instanceof r?t:new r((function(e){e(t)}))}return new(r||(r=Promise))((function(r,i){function a(t){try{c(n.next(t))}catch(e){i(e)}}function s(t){try{c(n["throw"](t))}catch(e){i(e)}}function c(t){t.done?r(t.value):o(t.value).then(a,s)}c((n=n.apply(t,e||[])).next())}))},ut=function(t,e){var r,n,o,i,a={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]};return i={next:s(0),throw:s(1),return:s(2)},"function"===typeof Symbol&&(i[Symbol.iterator]=function(){return this}),i;function s(t){return function(e){return c([t,e])}}function c(i){if(r)throw new TypeError("Generator is already executing.");while(a)try{if(r=1,n&&(o=2&i[0]?n["return"]:i[0]?n["throw"]||((o=n["return"])&&o.call(n),0):n.next)&&!(o=o.call(n,i[1])).done)return o;switch(n=0,o&&(i=[2&i[0],o.value]),i[0]){case 0:case 1:o=i;break;case 4:return a.label++,{value:i[1],done:!1};case 5:a.label++,n=i[1],i=[0];continue;case 7:i=a.ops.pop(),a.trys.pop();continue;default:if(o=a.trys,!(o=o.length>0&&o[o.length-1])&&(6===i[0]||2===i[0])){a=0;continue}if(3===i[0]&&(!o||i[1]>o[0]&&i[1]0&&o[o.length-1])&&(6===i[0]||2===i[0])){a=0;continue}if(3===i[0]&&(!o||i[1]>o[0]&&i[1]0)&&!(n=i.next()).done)a.push(n.value)}catch(s){o={error:s}}finally{try{n&&!n.done&&(r=i["return"])&&r.call(i)}finally{if(o)throw o.error}}return a},wt=function(){for(var t=[],e=0;ethis.file.size&&this.config.noCompressIfLarger?[2,{dist:this.file,width:t.width,height:t.height}]:[2,{dist:i,width:o.width,height:o.height}]}}))}))},t.prototype.clear=function(t,e,r){this.outputType===St?(t.fillStyle="#fff",t.fillRect(0,0,e,r)):t.clearRect(0,0,e,r)},t.prototype.getOriginImage=function(){var t=this;return new Promise((function(e,r){var n=L(t.file),o=new Image;o.onload=function(){e(o)},o.onerror=function(){r("image load error")},o.src=n}))},t.prototype.getCanvas=function(t){var e=this;return new Promise((function(r,n){dt["EXIF"].getData(t,(function(){var o=dt["EXIF"].getTag(t,"Orientation")||1,i=P(t,o),a=i.width,s=i.height,c=i.matrix,u=document.createElement("canvas"),h=u.getContext("2d");u.width=a,u.height=s,h?(e.clear(h,a,s),h.transform.apply(h,wt(c)),h.drawImage(t,0,0),r(u)):n(new Error("context is null"))}))}))},t.prototype.doScale=function(t,e){return mt(this,void 0,void 0,(function(){var r,n,o,i,a,s,c,u,h,l,f,p,d,g,m,v;return vt(this,(function(y){if(1===e)return[2,t];if(r=t.getContext("2d"),n=Math.min(xt,Math.ceil(1/e/Ct)),o=Math.pow(e,1/n),i=document.createElement("canvas"),a=i.getContext("2d"),s=t.width,c=t.height,u=s,h=c,i.width=s,i.height=c,!a||!r)throw new Error("mctx or sctx can't be null");for(p=0;p1?arguments[1]:void 0)}})},edba:function(t,e,r){},f30b:function(t,e,r){"use strict";var n=r("5a9e"),o=r("45af").includes,i=n.aTypedArray,a=n.exportTypedArrayMethod;a("includes",(function(t){return o(i(this),t,arguments.length>1?arguments[1]:void 0)}))},f3dd:function(t,e,r){"use strict";var n=r("1c8b"),o=r("d890"),i=r("6d7a"),a=r("9b9d"),s=r("1e2c"),c=r("c54b"),u=r("74cb"),h=r("efe2"),l=r("faa8"),f=r("74e7"),p=r("a719"),d=r("857c"),g=r("3553"),m=r("da10"),v=r("9f67"),y=r("38b9"),w=r("6d60"),b=r("cbab"),x=r("b338"),C=r("c051"),I=r("0a60"),S=r("aa6b"),B=r("d910"),O=r("ef71"),A=r("0fc1"),T=r("1944"),k=r("6d28"),E=r("7db2"),M=r("d5a8"),L=r("7e8b"),P=r("90fb"),_=r("4350"),U=r("6d51"),R=r("27b5"),F=r("b702"),N=r("5dfd").forEach,D=E("hidden"),j="Symbol",H="prototype",W=P("toPrimitive"),X=F.set,Y=F.getterFor(j),z=Object[H],G=o.Symbol,q=i("JSON","stringify"),$=S.f,V=B.f,J=C.f,K=O.f,Q=k("symbols"),Z=k("op-symbols"),tt=k("string-to-symbol-registry"),et=k("symbol-to-string-registry"),rt=k("wks"),nt=o.QObject,ot=!nt||!nt[H]||!nt[H].findChild,it=s&&h((function(){return 7!=w(V({},"a",{get:function(){return V(this,"a",{value:7}).a}})).a}))?function(t,e,r){var n=$(z,e);n&&delete z[e],V(t,e,r),n&&t!==z&&V(z,e,n)}:V,at=function(t,e){var r=Q[t]=w(G[H]);return X(r,{type:j,tag:t,description:e}),s||(r.description=e),r},st=u?function(t){return"symbol"==typeof t}:function(t){return Object(t)instanceof G},ct=function(t,e,r){t===z&&ct(Z,e,r),d(t);var n=v(e,!0);return d(r),l(Q,n)?(r.enumerable?(l(t,D)&&t[D][n]&&(t[D][n]=!1),r=w(r,{enumerable:y(0,!1)})):(l(t,D)||V(t,D,y(1,{})),t[D][n]=!0),it(t,n,r)):V(t,n,r)},ut=function(t,e){d(t);var r=m(e),n=b(r).concat(dt(r));return N(n,(function(e){s&&!lt.call(r,e)||ct(t,e,r[e])})),t},ht=function(t,e){return void 0===e?w(t):ut(w(t),e)},lt=function(t){var e=v(t,!0),r=K.call(this,e);return!(this===z&&l(Q,e)&&!l(Z,e))&&(!(r||!l(this,e)||!l(Q,e)||l(this,D)&&this[D][e])||r)},ft=function(t,e){var r=m(t),n=v(e,!0);if(r!==z||!l(Q,n)||l(Z,n)){var o=$(r,n);return!o||!l(Q,n)||l(r,D)&&r[D][n]||(o.enumerable=!0),o}},pt=function(t){var e=J(m(t)),r=[];return N(e,(function(t){l(Q,t)||l(M,t)||r.push(t)})),r},dt=function(t){var e=t===z,r=J(e?Z:m(t)),n=[];return N(r,(function(t){!l(Q,t)||e&&!l(z,t)||n.push(Q[t])})),n};if(c||(G=function(){if(this instanceof G)throw TypeError("Symbol is not a constructor");var t=arguments.length&&void 0!==arguments[0]?String(arguments[0]):void 0,e=L(t),r=function(t){this===z&&r.call(Z,t),l(this,D)&&l(this[D],e)&&(this[D][e]=!1),it(this,e,y(1,t))};return s&&ot&&it(z,e,{configurable:!0,set:r}),at(e,t)},T(G[H],"toString",(function(){return Y(this).tag})),T(G,"withoutSetter",(function(t){return at(L(t),t)})),O.f=lt,B.f=ct,S.f=ft,x.f=C.f=pt,I.f=dt,_.f=function(t){return at(P(t),t)},s&&(V(G[H],"description",{configurable:!0,get:function(){return Y(this).description}}),a||T(z,"propertyIsEnumerable",lt,{unsafe:!0}))),n({global:!0,wrap:!0,forced:!c,sham:!c},{Symbol:G}),N(b(rt),(function(t){U(t)})),n({target:j,stat:!0,forced:!c},{for:function(t){var e=String(t);if(l(tt,e))return tt[e];var r=G(e);return tt[e]=r,et[r]=e,r},keyFor:function(t){if(!st(t))throw TypeError(t+" is not a symbol");if(l(et,t))return et[t]},useSetter:function(){ot=!0},useSimple:function(){ot=!1}}),n({target:"Object",stat:!0,forced:!c,sham:!s},{create:ht,defineProperty:ct,defineProperties:ut,getOwnPropertyDescriptor:ft}),n({target:"Object",stat:!0,forced:!c},{getOwnPropertyNames:pt,getOwnPropertySymbols:dt}),n({target:"Object",stat:!0,forced:h((function(){I.f(1)}))},{getOwnPropertySymbols:function(t){return I.f(g(t))}}),q){var gt=!c||h((function(){var t=G();return"[null]"!=q([t])||"{}"!=q({a:t})||"{}"!=q(Object(t))}));n({target:"JSON",stat:!0,forced:gt},{stringify:function(t,e,r){var n,o=[t],i=1;while(arguments.length>i)o.push(arguments[i++]);if(n=e,(p(e)||void 0!==t)&&!st(t))return f(e)||(e=function(t,e){if("function"==typeof n&&(e=n.call(this,t,e)),!st(e))return e}),o[1]=e,q.apply(null,o)}})}G[H][W]||A(G[H],W,G[H].valueOf),R(G,j),M[D]=!0},f4e3:function(t,e,r){"use strict";var n=r("b2a2"),o=r("857c"),i=r("d88d"),a=r("2732"),s=r("38eb"),c=r("59da");n("match",1,(function(t,e,r){return[function(e){var r=a(this),n=void 0==e?void 0:e[t];return void 0!==n?n.call(e,r):new RegExp(e)[t](String(r))},function(t){var n=r(e,t,this);if(n.done)return n.value;var a=o(t),u=String(this);if(!a.global)return c(a,u);var h=a.unicode;a.lastIndex=0;var l,f=[],p=0;while(null!==(l=c(a,u))){var d=String(l[0]);f[p]=d,""===d&&(a.lastIndex=s(u,i(a.lastIndex),h)),p++}return 0===p?null:f}]}))},f74a:function(t,e,r){"use strict";var n=r("5a9e"),o=n.aTypedArray,i=n.exportTypedArrayMethod,a=[].join;i("join",(function(t){return a.apply(o(this),arguments)}))},f925:function(t,e,r){"use strict";var n=r("0689"),o=r.n(n);o.a},fa41:function(t,e,r){"use strict";var n=r("3553"),o=r("e1d6"),i=r("d88d");t.exports=function(t){var e=n(this),r=i(e.length),a=arguments.length,s=o(a>1?arguments[1]:void 0,r),c=a>2?arguments[2]:void 0,u=void 0===c?r:o(c,r);while(u>s)e[s++]=t;return e}},fc6e:function(t,e,r){"use strict";var n=r("5a9e"),o=r("5dfd").forEach,i=n.aTypedArray,a=n.exportTypedArrayMethod;a("forEach",(function(t){o(i(this),t,arguments.length>1?arguments[1]:void 0)}))},fc8c:function(t,e){t.exports="\t\n\v\f\r                 \u2028\u2029\ufeff"},fe59:function(t,e,r){"use strict";var n=r("1c8b"),o=r("3c10");n({target:"Array",proto:!0,forced:[].forEach!=o},{forEach:o})},fe8a:function(t,e,r){var n=r("1c8b"),o=r("3553"),i=r("cbab"),a=r("efe2"),s=a((function(){i(1)}));n({target:"Object",stat:!0,forced:s},{keys:function(t){return i(o(t))}})}}]); //# sourceMappingURL=chunk-e3c7a600.undefined.1613816010683.js.map