@wangeditor-next/upload-image-module 1.1.3 → 1.1.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.esm.js +1 -1
- package/dist/index.esm.js.map +1 -1
- package/dist/index.js +1 -1
- package/dist/index.js.map +1 -1
- package/package.json +4 -5
- package/CHANGELOG.md +0 -98
- package/LICENSE +0 -21
package/dist/index.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
!function(t,e){"object"==typeof exports&&"undefined"!=typeof module?module.exports=e(require("@wangeditor-next/core"),require("@wangeditor-next/basic-modules"),require("dom7")):"function"==typeof define&&define.amd?define(["@wangeditor-next/core","@wangeditor-next/basic-modules","dom7"],e):(t="undefined"!=typeof globalThis?globalThis:t||self).WangEditorUploadImageModule=e(t.core,t.basicModules,t.$)}(this,(function(t,e,n){"use strict";function r(t){return t&&"object"==typeof t&&"default"in t?t:{default:t}}var o=r(n);t.i18nAddResources("en",{uploadImgModule:{uploadImage:"Upload Image",uploadError:"{{fileName}} upload error"}}),t.i18nAddResources("zh-CN",{uploadImgModule:{uploadImage:"上传图片",uploadError:"{{fileName}} 上传出错"}});var i="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{};function u(t){var e={exports:{}};return t(e,e.exports),e.exports}var a,c,f=function(t){return t&&t.Math==Math&&t},s=f("object"==typeof globalThis&&globalThis)||f("object"==typeof window&&window)||f("object"==typeof self&&self)||f("object"==typeof i&&i)||function(){return this}()||Function("return this")(),l=function(t){try{return!!t()}catch(t){return!0}},p=!l((function(){return 7!=Object.defineProperty({},1,{get:function(){return 7}})[1]})),d=Function.prototype.call,v=d.bind?d.bind(d):function(){return d.apply(d,arguments)},h={}.propertyIsEnumerable,y=Object.getOwnPropertyDescriptor,g={f:y&&!h.call({1:2},1)?function(t){var e=y(this,t);return!!e&&e.enumerable}:h},m=function(t,e){return{enumerable:!(1&t),configurable:!(2&t),writable:!(4&t),value:e}},b=Function.prototype,w=b.bind,S=b.call,x=w&&w.bind(S),O=w?function(t){return t&&x(S,t)}:function(t){return t&&function(){return S.apply(t,arguments)}},j=O({}.toString),E=O("".slice),I=function(t){return E(j(t),8,-1)},T=s.Object,A=O("".split),P=l((function(){return!T("z").propertyIsEnumerable(0)}))?function(t){return"String"==I(t)?A(t,""):T(t)}:T,R=s.TypeError,M=function(t){if(null==t)throw R("Can't call method on "+t);return t},k=function(t){return P(M(t))},L=function(t){return"function"==typeof t},F=function(t){return"object"==typeof t?null!==t:L(t)},C=function(t,e){return arguments.length<2?(n=s[t],L(n)?n:void 0):s[t]&&s[t][e];var n},z=O({}.isPrototypeOf),N=C("navigator","userAgent")||"",_=s.process,D=s.Deno,G=_&&_.versions||D&&D.version,U=G&&G.v8;U&&(c=(a=U.split("."))[0]>0&&a[0]<4?1:+(a[0]+a[1])),!c&&N&&(!(a=N.match(/Edge\/(\d+)/))||a[1]>=74)&&(a=N.match(/Chrome\/(\d+)/))&&(c=+a[1]);var B=c,W=!!Object.getOwnPropertySymbols&&!l((function(){var t=Symbol();return!String(t)||!(Object(t)instanceof Symbol)||!Symbol.sham&&B&&B<41})),V=W&&!Symbol.sham&&"symbol"==typeof Symbol.iterator,H=s.Object,q=V?function(t){return"symbol"==typeof t}:function(t){var e=C("Symbol");return L(e)&&z(e.prototype,H(t))},K=s.String,X=function(t){try{return K(t)}catch(t){return"Object"}},Y=s.TypeError,$=function(t){if(L(t))return t;throw Y(X(t)+" is not a function")},J=function(t,e){var n=t[e];return null==n?void 0:$(n)},Q=s.TypeError,Z=Object.defineProperty,tt=function(t,e){try{Z(s,t,{value:e,configurable:!0,writable:!0})}catch(n){s[t]=e}return e},et="__core-js_shared__",nt=s[et]||tt(et,{}),rt=u((function(t){(t.exports=function(t,e){return nt[t]||(nt[t]=void 0!==e?e:{})})("versions",[]).push({version:"3.19.3",mode:"global",copyright:"© 2021 Denis Pushkarev (zloirock.ru)"})})),ot=s.Object,it=function(t){return ot(M(t))},ut=O({}.hasOwnProperty),at=Object.hasOwn||function(t,e){return ut(it(t),e)},ct=0,ft=Math.random(),st=O(1..toString),lt=function(t){return"Symbol("+(void 0===t?"":t)+")_"+st(++ct+ft,36)},pt=rt("wks"),dt=s.Symbol,vt=dt&&dt.for,ht=V?dt:dt&&dt.withoutSetter||lt,yt=function(t){if(!at(pt,t)||!W&&"string"!=typeof pt[t]){var e="Symbol."+t;W&&at(dt,t)?pt[t]=dt[t]:pt[t]=V&&vt?vt(e):ht(e)}return pt[t]},gt=s.TypeError,mt=yt("toPrimitive"),bt=function(t,e){if(!F(t)||q(t))return t;var n,r=J(t,mt);if(r){if(void 0===e&&(e="default"),n=v(r,t,e),!F(n)||q(n))return n;throw gt("Can't convert object to primitive value")}return void 0===e&&(e="number"),function(t,e){var n,r;if("string"===e&&L(n=t.toString)&&!F(r=v(n,t)))return r;if(L(n=t.valueOf)&&!F(r=v(n,t)))return r;if("string"!==e&&L(n=t.toString)&&!F(r=v(n,t)))return r;throw Q("Can't convert object to primitive value")}(t,e)},wt=function(t){var e=bt(t,"string");return q(e)?e:e+""},St=s.document,xt=F(St)&&F(St.createElement),Ot=function(t){return xt?St.createElement(t):{}},jt=!p&&!l((function(){return 7!=Object.defineProperty(Ot("div"),"a",{get:function(){return 7}}).a})),Et=Object.getOwnPropertyDescriptor,It={f:p?Et:function(t,e){if(t=k(t),e=wt(e),jt)try{return Et(t,e)}catch(t){}if(at(t,e))return m(!v(g.f,t,e),t[e])}},Tt=s.String,At=s.TypeError,Pt=function(t){if(F(t))return t;throw At(Tt(t)+" is not an object")},Rt=s.TypeError,Mt=Object.defineProperty,kt={f:p?Mt:function(t,e,n){if(Pt(t),e=wt(e),Pt(n),jt)try{return Mt(t,e,n)}catch(t){}if("get"in n||"set"in n)throw Rt("Accessors not supported");return"value"in n&&(t[e]=n.value),t}},Lt=p?function(t,e,n){return kt.f(t,e,m(1,n))}:function(t,e,n){return t[e]=n,t},Ft=O(Function.toString);L(nt.inspectSource)||(nt.inspectSource=function(t){return Ft(t)});var Ct,zt,Nt,_t=nt.inspectSource,Dt=s.WeakMap,Gt=L(Dt)&&/native code/.test(_t(Dt)),Ut=rt("keys"),Bt=function(t){return Ut[t]||(Ut[t]=lt(t))},Wt={},Vt="Object already initialized",Ht=s.TypeError,qt=s.WeakMap;if(Gt||nt.state){var Kt=nt.state||(nt.state=new qt),Xt=O(Kt.get),Yt=O(Kt.has),$t=O(Kt.set);Ct=function(t,e){if(Yt(Kt,t))throw new Ht(Vt);return e.facade=t,$t(Kt,t,e),e},zt=function(t){return Xt(Kt,t)||{}},Nt=function(t){return Yt(Kt,t)}}else{var Jt=Bt("state");Wt[Jt]=!0,Ct=function(t,e){if(at(t,Jt))throw new Ht(Vt);return e.facade=t,Lt(t,Jt,e),e},zt=function(t){return at(t,Jt)?t[Jt]:{}},Nt=function(t){return at(t,Jt)}}var Qt={set:Ct,get:zt,has:Nt,enforce:function(t){return Nt(t)?zt(t):Ct(t,{})},getterFor:function(t){return function(e){var n;if(!F(e)||(n=zt(e)).type!==t)throw Ht("Incompatible receiver, "+t+" required");return n}}},Zt=Function.prototype,te=p&&Object.getOwnPropertyDescriptor,ee=at(Zt,"name"),ne={EXISTS:ee,PROPER:ee&&"something"===function(){}.name,CONFIGURABLE:ee&&(!p||p&&te(Zt,"name").configurable)},re=u((function(t){var e=ne.CONFIGURABLE,n=Qt.get,r=Qt.enforce,o=String(String).split("String");(t.exports=function(t,n,i,u){var a,c=!!u&&!!u.unsafe,f=!!u&&!!u.enumerable,l=!!u&&!!u.noTargetGet,p=u&&void 0!==u.name?u.name:n;L(i)&&("Symbol("===String(p).slice(0,7)&&(p="["+String(p).replace(/^Symbol\(([^)]*)\)/,"$1")+"]"),(!at(i,"name")||e&&i.name!==p)&&Lt(i,"name",p),(a=r(i)).source||(a.source=o.join("string"==typeof p?p:""))),t!==s?(c?!l&&t[n]&&(f=!0):delete t[n],f?t[n]=i:Lt(t,n,i)):f?t[n]=i:tt(n,i)})(Function.prototype,"toString",(function(){return L(this)&&n(this).source||_t(this)}))})),oe=Math.ceil,ie=Math.floor,ue=function(t){var e=+t;return e!=e||0===e?0:(e>0?ie:oe)(e)},ae=Math.max,ce=Math.min,fe=function(t,e){var n=ue(t);return n<0?ae(n+e,0):ce(n,e)},se=Math.min,le=function(t){return(e=t.length)>0?se(ue(e),9007199254740991):0;var e},pe=function(t){return function(e,n,r){var o,i=k(e),u=le(i),a=fe(r,u);if(t&&n!=n){for(;u>a;)if((o=i[a++])!=o)return!0}else for(;u>a;a++)if((t||a in i)&&i[a]===n)return t||a||0;return!t&&-1}},de={includes:pe(!0),indexOf:pe(!1)}.indexOf,ve=O([].push),he=function(t,e){var n,r=k(t),o=0,i=[];for(n in r)!at(Wt,n)&&at(r,n)&&ve(i,n);for(;e.length>o;)at(r,n=e[o++])&&(~de(i,n)||ve(i,n));return i},ye=["constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleString","toString","valueOf"],ge=ye.concat("length","prototype"),me={f:Object.getOwnPropertyNames||function(t){return he(t,ge)}},be={f:Object.getOwnPropertySymbols},we=O([].concat),Se=C("Reflect","ownKeys")||function(t){var e=me.f(Pt(t)),n=be.f;return n?we(e,n(t)):e},xe=function(t,e){for(var n=Se(e),r=kt.f,o=It.f,i=0;i<n.length;i++){var u=n[i];at(t,u)||r(t,u,o(e,u))}},Oe=/#|\.prototype\./,je=function(t,e){var n=Ie[Ee(t)];return n==Ae||n!=Te&&(L(e)?l(e):!!e)},Ee=je.normalize=function(t){return String(t).replace(Oe,".").toLowerCase()},Ie=je.data={},Te=je.NATIVE="N",Ae=je.POLYFILL="P",Pe=je,Re=It.f,Me=function(t,e){var n,r,o,i,u,a=t.target,c=t.global,f=t.stat;if(n=c?s:f?s[a]||tt(a,{}):(s[a]||{}).prototype)for(r in e){if(i=e[r],o=t.noTargetGet?(u=Re(n,r))&&u.value:n[r],!Pe(c?r:a+(f?".":"#")+r,t.forced)&&void 0!==o){if(typeof i==typeof o)continue;xe(i,o)}(t.sham||o&&o.sham)&&Lt(i,"sham",!0),re(n,r,i,t)}},ke=Array.isArray||function(t){return"Array"==I(t)},Le={};Le[yt("toStringTag")]="z";var Fe,Ce="[object z]"===String(Le),ze=yt("toStringTag"),Ne=s.Object,_e="Arguments"==I(function(){return arguments}()),De=Ce?I:function(t){var e,n,r;return void 0===t?"Undefined":null===t?"Null":"string"==typeof(n=function(t,e){try{return t[e]}catch(t){}}(e=Ne(t),ze))?n:_e?I(e):"Object"==(r=I(e))&&L(e.callee)?"Arguments":r},Ge=function(){},Ue=[],Be=C("Reflect","construct"),We=/^\s*(?:class|function)\b/,Ve=O(We.exec),He=!We.exec(Ge),qe=function(t){if(!L(t))return!1;try{return Be(Ge,Ue,t),!0}catch(t){return!1}},Ke=!Be||l((function(){var t;return qe(qe.call)||!qe(Object)||!qe((function(){t=!0}))||t}))?function(t){if(!L(t))return!1;switch(De(t)){case"AsyncFunction":case"GeneratorFunction":case"AsyncGeneratorFunction":return!1}return He||!!Ve(We,_t(t))}:qe,Xe=function(t,e,n){var r=wt(e);r in t?kt.f(t,r,m(0,n)):t[r]=n},Ye=yt("species"),$e=O([].slice),Je=(Fe="slice",B>=51||!l((function(){var t=[];return(t.constructor={})[Ye]=function(){return{foo:1}},1!==t[Fe](Boolean).foo}))),Qe=yt("species"),Ze=s.Array,tn=Math.max;Me({target:"Array",proto:!0,forced:!Je},{slice:function(t,e){var n,r,o,i=k(this),u=le(i),a=fe(t,u),c=fe(void 0===e?u:e,u);if(ke(i)&&(n=i.constructor,(Ke(n)&&(n===Ze||ke(n.prototype))||F(n)&&null===(n=n[Qe]))&&(n=void 0),n===Ze||void 0===n))return $e(i,a,c);for(r=new(void 0===n?Ze:n)(tn(c-a,0)),o=0;a<c;a++,o++)a in i&&Xe(r,o,i[a]);return r.length=o,r}});var en=Ce?{}.toString:function(){return"[object "+De(this)+"]"};Ce||re(Object.prototype,"toString",en,{unsafe:!0});var nn=function(){return nn=Object.assign||function(t){for(var e,n=1,r=arguments.length;n<r;n++)for(var o in e=arguments[n])Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o]);return t},nn.apply(this,arguments)};function rn(t,e,n,r){return new(n||(n=Promise))((function(o,i){function u(t){try{c(r.next(t))}catch(t){i(t)}}function a(t){try{c(r.throw(t))}catch(t){i(t)}}function c(t){var e;t.done?o(t.value):(e=t.value,e instanceof n?e:new n((function(t){t(e)}))).then(u,a)}c((r=r.apply(t,e||[])).next())}))}function on(t,e){var n,r,o,i,u={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]};return i={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(i[Symbol.iterator]=function(){return this}),i;function a(a){return function(c){return function(a){if(n)throw new TypeError("Generator is already executing.");for(;i&&(i=0,a[0]&&(u=0)),u;)try{if(n=1,r&&(o=2&a[0]?r.return:a[0]?r.throw||((o=r.return)&&o.call(r),0):r.next)&&!(o=o.call(r,a[1])).done)return o;switch(r=0,o&&(a=[2&a[0],o.value]),a[0]){case 0:case 1:o=a;break;case 4:return u.label++,{value:a[1],done:!1};case 5:u.label++,r=a[1],a=[0];continue;case 7:a=u.ops.pop(),u.trys.pop();continue;default:if(!(o=u.trys,(o=o.length>0&&o[o.length-1])||6!==a[0]&&2!==a[0])){u=0;continue}if(3===a[0]&&(!o||a[1]>o[0]&&a[1]<o[3])){u.label=a[1];break}if(6===a[0]&&u.label<o[1]){u.label=o[1],o=a;break}if(o&&u.label<o[2]){u.label=o[2],u.ops.push(a);break}o[2]&&u.ops.pop(),u.trys.pop();continue}a=e.call(t,u)}catch(t){a=[6,t],r=0}finally{n=o=0}if(5&a[0])throw a[1];return{value:a[0]?a[1]:void 0,done:!0}}([a,c])}}}function un(t){var e="function"==typeof Symbol&&Symbol.iterator,n=e&&t[e],r=0;if(n)return n.call(t);if(t&&"number"==typeof t.length)return{next:function(){return t&&r>=t.length&&(t=void 0),{value:t&&t[r++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")}function an(t){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var e,n=t[Symbol.asyncIterator];return n?n.call(t):(t=un(t),e={},r("next"),r("throw"),r("return"),e[Symbol.asyncIterator]=function(){return this},e);function r(n){e[n]=t[n]&&function(e){return new Promise((function(r,o){(function(t,e,n,r){Promise.resolve(r).then((function(e){t({value:e,done:n})}),e)})(r,o,(e=t[n](e)).done,e.value)}))}}}"function"==typeof SuppressedError&&SuppressedError;var cn,fn=Object.keys||function(t){return he(t,ye)},sn=p?Object.defineProperties:function(t,e){Pt(t);for(var n,r=k(e),o=fn(e),i=o.length,u=0;i>u;)kt.f(t,n=o[u++],r[n]);return t},ln=C("document","documentElement"),pn="prototype",dn="script",vn=Bt("IE_PROTO"),hn=function(){},yn=function(t){return"<"+dn+">"+t+"</"+dn+">"},gn=function(t){t.write(yn("")),t.close();var e=t.parentWindow.Object;return t=null,e},mn=function(){try{cn=new ActiveXObject("htmlfile")}catch(t){}var t,e,n;mn="undefined"!=typeof document?document.domain&&cn?gn(cn):(e=Ot("iframe"),n="java"+dn+":",e.style.display="none",ln.appendChild(e),e.src=String(n),(t=e.contentWindow.document).open(),t.write(yn("document.F=Object")),t.close(),t.F):gn(cn);for(var r=ye.length;r--;)delete mn[pn][ye[r]];return mn()};Wt[vn]=!0;var bn=Object.create||function(t,e){var n;return null!==t?(hn[pn]=Pt(t),n=new hn,hn[pn]=null,n[vn]=t):n=mn(),void 0===e?n:sn(n,e)},wn=yt("unscopables"),Sn=Array.prototype;null==Sn[wn]&&kt.f(Sn,wn,{configurable:!0,value:bn(null)});var xn,On,jn,En=function(t){Sn[wn][t]=!0},In={},Tn=!l((function(){function t(){}return t.prototype.constructor=null,Object.getPrototypeOf(new t)!==t.prototype})),An=Bt("IE_PROTO"),Pn=s.Object,Rn=Pn.prototype,Mn=Tn?Pn.getPrototypeOf:function(t){var e=it(t);if(at(e,An))return e[An];var n=e.constructor;return L(n)&&e instanceof n?n.prototype:e instanceof Pn?Rn:null},kn=yt("iterator"),Ln=!1;[].keys&&("next"in(jn=[].keys())?(On=Mn(Mn(jn)))!==Object.prototype&&(xn=On):Ln=!0);var Fn=null==xn||l((function(){var t={};return xn[kn].call(t)!==t}));Fn&&(xn={}),L(xn[kn])||re(xn,kn,(function(){return this}));var Cn={IteratorPrototype:xn,BUGGY_SAFARI_ITERATORS:Ln},zn=kt.f,Nn=yt("toStringTag"),_n=function(t,e,n){t&&!at(t=n?t:t.prototype,Nn)&&zn(t,Nn,{configurable:!0,value:e})},Dn=Cn.IteratorPrototype,Gn=function(){return this},Un=s.String,Bn=s.TypeError,Wn=Object.setPrototypeOf||("__proto__"in{}?function(){var t,e=!1,n={};try{(t=O(Object.getOwnPropertyDescriptor(Object.prototype,"__proto__").set))(n,[]),e=n instanceof Array}catch(t){}return function(n,r){return Pt(n),function(t){if("object"==typeof t||L(t))return t;throw Bn("Can't set "+Un(t)+" as a prototype")}(r),e?t(n,r):n.__proto__=r,n}}():void 0),Vn=ne.PROPER,Hn=ne.CONFIGURABLE,qn=Cn.IteratorPrototype,Kn=Cn.BUGGY_SAFARI_ITERATORS,Xn=yt("iterator"),Yn="keys",$n="values",Jn="entries",Qn=function(){return this},Zn=function(t,e,n,r,o,i,u){!function(t,e,n,r){var o=e+" Iterator";t.prototype=bn(Dn,{next:m(+!r,n)}),_n(t,o,!1),In[o]=Gn}(n,e,r);var a,c,f,s=function(t){if(t===o&&y)return y;if(!Kn&&t in d)return d[t];switch(t){case Yn:case $n:case Jn:return function(){return new n(this,t)}}return function(){return new n(this)}},l=e+" Iterator",p=!1,d=t.prototype,h=d[Xn]||d["@@iterator"]||o&&d[o],y=!Kn&&h||s(o),g="Array"==e&&d.entries||h;if(g&&(a=Mn(g.call(new t)))!==Object.prototype&&a.next&&(Mn(a)!==qn&&(Wn?Wn(a,qn):L(a[Xn])||re(a,Xn,Qn)),_n(a,l,!0)),Vn&&o==$n&&h&&h.name!==$n&&(Hn?Lt(d,"name",$n):(p=!0,y=function(){return v(h,this)})),o)if(c={values:s($n),keys:i?y:s(Yn),entries:s(Jn)},u)for(f in c)(Kn||p||!(f in d))&&re(d,f,c[f]);else Me({target:e,proto:!0,forced:Kn||p},c);return d[Xn]!==y&&re(d,Xn,y,{name:o}),In[e]=y,c},tr="Array Iterator",er=Qt.set,nr=Qt.getterFor(tr),rr=Zn(Array,"Array",(function(t,e){er(this,{type:tr,target:k(t),index:0,kind:e})}),(function(){var t=nr(this),e=t.target,n=t.kind,r=t.index++;return!e||r>=e.length?(t.target=void 0,{value:void 0,done:!0}):"keys"==n?{value:r,done:!1}:"values"==n?{value:e[r],done:!1}:{value:[r,e[r]],done:!1}}),"values");In.Arguments=In.Array,En("keys"),En("values"),En("entries");var or=ne.EXISTS,ir=kt.f,ur=Function.prototype,ar=O(ur.toString),cr=/function\b(?:\s|\/\*[\S\s]*?\*\/|\/\/[^\n\r]*[\n\r]+)*([^\s(/]*)/,fr=O(cr.exec);p&&!or&&ir(ur,"name",{configurable:!0,get:function(){try{return fr(cr,ar(this))[1]}catch(t){return""}}});var sr=s.Promise,lr=function(t,e,n){for(var r in e)re(t,r,e[r],n);return t},pr=yt("species"),dr=s.TypeError,vr=function(t,e){if(z(e,t))return t;throw dr("Incorrect invocation")},hr=O(O.bind),yr=function(t,e){return $(t),void 0===e?t:hr?hr(t,e):function(){return t.apply(e,arguments)}},gr=yt("iterator"),mr=Array.prototype,br=yt("iterator"),wr=function(t){if(null!=t)return J(t,br)||J(t,"@@iterator")||In[De(t)]},Sr=s.TypeError,xr=function(t,e,n){var r,o;Pt(t);try{if(!(r=J(t,"return"))){if("throw"===e)throw n;return n}r=v(r,t)}catch(t){o=!0,r=t}if("throw"===e)throw n;if(o)throw r;return Pt(r),n},Or=s.TypeError,jr=function(t,e){this.stopped=t,this.result=e},Er=jr.prototype,Ir=function(t,e,n){var r,o,i,u,a,c,f,s,l=n&&n.that,p=!(!n||!n.AS_ENTRIES),d=!(!n||!n.IS_ITERATOR),h=!(!n||!n.INTERRUPTED),y=yr(e,l),g=function(t){return r&&xr(r,"normal",t),new jr(!0,t)},m=function(t){return p?(Pt(t),h?y(t[0],t[1],g):y(t[0],t[1])):h?y(t,g):y(t)};if(d)r=t;else{if(!(o=wr(t)))throw Or(X(t)+" is not iterable");if(void 0!==(s=o)&&(In.Array===s||mr[gr]===s)){for(i=0,u=le(t);u>i;i++)if((a=m(t[i]))&&z(Er,a))return a;return new jr(!1)}r=function(t,e){var n=arguments.length<2?wr(t):e;if($(n))return Pt(v(n,t));throw Sr(X(t)+" is not iterable")}(t,o)}for(c=r.next;!(f=v(c,r)).done;){try{a=m(f.value)}catch(t){xr(r,"throw",t)}if("object"==typeof a&&a&&z(Er,a))return a}return new jr(!1)},Tr=yt("iterator"),Ar=!1;try{var Pr=0,Rr={next:function(){return{done:!!Pr++}},return:function(){Ar=!0}};Rr[Tr]=function(){return this},Array.from(Rr,(function(){throw 2}))}catch(t){}var Mr,kr,Lr,Fr,Cr=function(t,e){if(!e&&!Ar)return!1;var n=!1;try{var r={};r[Tr]=function(){return{next:function(){return{done:n=!0}}}},t(r)}catch(t){}return n},zr=s.TypeError,Nr=yt("species"),_r=function(t,e){var n,r=Pt(t).constructor;return void 0===r||null==(n=Pt(r)[Nr])?e:function(t){if(Ke(t))return t;throw zr(X(t)+" is not a constructor")}(n)},Dr=Function.prototype,Gr=Dr.apply,Ur=Dr.bind,Br=Dr.call,Wr="object"==typeof Reflect&&Reflect.apply||(Ur?Br.bind(Gr):function(){return Br.apply(Gr,arguments)}),Vr=/(?:ipad|iphone|ipod).*applewebkit/i.test(N),Hr="process"==I(s.process),qr=s.setImmediate,Kr=s.clearImmediate,Xr=s.process,Yr=s.Dispatch,$r=s.Function,Jr=s.MessageChannel,Qr=s.String,Zr=0,to={},eo="onreadystatechange";try{Mr=s.location}catch(t){}var no=function(t){if(at(to,t)){var e=to[t];delete to[t],e()}},ro=function(t){return function(){no(t)}},oo=function(t){no(t.data)},io=function(t){s.postMessage(Qr(t),Mr.protocol+"//"+Mr.host)};qr&&Kr||(qr=function(t){var e=$e(arguments,1);return to[++Zr]=function(){Wr(L(t)?t:$r(t),void 0,e)},kr(Zr),Zr},Kr=function(t){delete to[t]},Hr?kr=function(t){Xr.nextTick(ro(t))}:Yr&&Yr.now?kr=function(t){Yr.now(ro(t))}:Jr&&!Vr?(Fr=(Lr=new Jr).port2,Lr.port1.onmessage=oo,kr=yr(Fr.postMessage,Fr)):s.addEventListener&&L(s.postMessage)&&!s.importScripts&&Mr&&"file:"!==Mr.protocol&&!l(io)?(kr=io,s.addEventListener("message",oo,!1)):kr=eo in Ot("script")?function(t){ln.appendChild(Ot("script"))[eo]=function(){ln.removeChild(this),no(t)}}:function(t){setTimeout(ro(t),0)});var uo,ao,co,fo,so,lo,po,vo,ho={set:qr,clear:Kr},yo=/ipad|iphone|ipod/i.test(N)&&void 0!==s.Pebble,go=/web0s(?!.*chrome)/i.test(N),mo=It.f,bo=ho.set,wo=s.MutationObserver||s.WebKitMutationObserver,So=s.document,xo=s.process,Oo=s.Promise,jo=mo(s,"queueMicrotask"),Eo=jo&&jo.value;Eo||(uo=function(){var t,e;for(Hr&&(t=xo.domain)&&t.exit();ao;){e=ao.fn,ao=ao.next;try{e()}catch(t){throw ao?fo():co=void 0,t}}co=void 0,t&&t.enter()},Vr||Hr||go||!wo||!So?!yo&&Oo&&Oo.resolve?((po=Oo.resolve(void 0)).constructor=Oo,vo=yr(po.then,po),fo=function(){vo(uo)}):Hr?fo=function(){xo.nextTick(uo)}:(bo=yr(bo,s),fo=function(){bo(uo)}):(so=!0,lo=So.createTextNode(""),new wo(uo).observe(lo,{characterData:!0}),fo=function(){lo.data=so=!so}));var Io,To,Ao,Po,Ro=Eo||function(t){var e={fn:t,next:void 0};co&&(co.next=e),ao||(ao=e,fo()),co=e},Mo=function(t){var e,n;this.promise=new t((function(t,r){if(void 0!==e||void 0!==n)throw TypeError("Bad Promise constructor");e=t,n=r})),this.resolve=$(e),this.reject=$(n)},ko={f:function(t){return new Mo(t)}},Lo=function(t){try{return{error:!1,value:t()}}catch(t){return{error:!0,value:t}}},Fo="object"==typeof window,Co=ho.set,zo=yt("species"),No="Promise",_o=Qt.getterFor(No),Do=Qt.set,Go=Qt.getterFor(No),Uo=sr&&sr.prototype,Bo=sr,Wo=Uo,Vo=s.TypeError,Ho=s.document,qo=s.process,Ko=ko.f,Xo=Ko,Yo=!!(Ho&&Ho.createEvent&&s.dispatchEvent),$o=L(s.PromiseRejectionEvent),Jo="unhandledrejection",Qo=!1,Zo=Pe(No,(function(){var t=_t(Bo),e=t!==String(Bo);if(!e&&66===B)return!0;if(B>=51&&/native code/.test(t))return!1;var n=new Bo((function(t){t(1)})),r=function(t){t((function(){}),(function(){}))};return(n.constructor={})[zo]=r,!(Qo=n.then((function(){}))instanceof r)||!e&&Fo&&!$o})),ti=Zo||!Cr((function(t){Bo.all(t).catch((function(){}))})),ei=function(t){var e;return!(!F(t)||!L(e=t.then))&&e},ni=function(t,e){if(!t.notified){t.notified=!0;var n=t.reactions;Ro((function(){for(var r=t.value,o=1==t.state,i=0;n.length>i;){var u,a,c,f=n[i++],s=o?f.ok:f.fail,l=f.resolve,p=f.reject,d=f.domain;try{s?(o||(2===t.rejection&&ui(t),t.rejection=1),!0===s?u=r:(d&&d.enter(),u=s(r),d&&(d.exit(),c=!0)),u===f.promise?p(Vo("Promise-chain cycle")):(a=ei(u))?v(a,u,l,p):l(u)):p(r)}catch(t){d&&!c&&d.exit(),p(t)}}t.reactions=[],t.notified=!1,e&&!t.rejection&&oi(t)}))}},ri=function(t,e,n){var r,o;Yo?((r=Ho.createEvent("Event")).promise=e,r.reason=n,r.initEvent(t,!1,!0),s.dispatchEvent(r)):r={promise:e,reason:n},!$o&&(o=s["on"+t])?o(r):t===Jo&&function(t,e){var n=s.console;n&&n.error&&(1==arguments.length?n.error(t):n.error(t,e))}("Unhandled promise rejection",n)},oi=function(t){v(Co,s,(function(){var e,n=t.facade,r=t.value;if(ii(t)&&(e=Lo((function(){Hr?qo.emit("unhandledRejection",r,n):ri(Jo,n,r)})),t.rejection=Hr||ii(t)?2:1,e.error))throw e.value}))},ii=function(t){return 1!==t.rejection&&!t.parent},ui=function(t){v(Co,s,(function(){var e=t.facade;Hr?qo.emit("rejectionHandled",e):ri("rejectionhandled",e,t.value)}))},ai=function(t,e,n){return function(r){t(e,r,n)}},ci=function(t,e,n){t.done||(t.done=!0,n&&(t=n),t.value=e,t.state=2,ni(t,!0))},fi=function(t,e,n){if(!t.done){t.done=!0,n&&(t=n);try{if(t.facade===e)throw Vo("Promise can't be resolved itself");var r=ei(e);r?Ro((function(){var n={done:!1};try{v(r,e,ai(fi,n,t),ai(ci,n,t))}catch(e){ci(n,e,t)}})):(t.value=e,t.state=1,ni(t,!1))}catch(e){ci({done:!1},e,t)}}};if(Zo&&(Wo=(Bo=function(t){vr(this,Wo),$(t),v(Io,this);var e=_o(this);try{t(ai(fi,e),ai(ci,e))}catch(t){ci(e,t)}}).prototype,(Io=function(t){Do(this,{type:No,done:!1,notified:!1,parent:!1,reactions:[],rejection:!1,state:0,value:void 0})}).prototype=lr(Wo,{then:function(t,e){var n=Go(this),r=n.reactions,o=Ko(_r(this,Bo));return o.ok=!L(t)||t,o.fail=L(e)&&e,o.domain=Hr?qo.domain:void 0,n.parent=!0,r[r.length]=o,0!=n.state&&ni(n,!1),o.promise},catch:function(t){return this.then(void 0,t)}}),To=function(){var t=new Io,e=_o(t);this.promise=t,this.resolve=ai(fi,e),this.reject=ai(ci,e)},ko.f=Ko=function(t){return t===Bo||t===Ao?new To(t):Xo(t)},L(sr)&&Uo!==Object.prototype)){Po=Uo.then,Qo||(re(Uo,"then",(function(t,e){var n=this;return new Bo((function(t,e){v(Po,n,t,e)})).then(t,e)}),{unsafe:!0}),re(Uo,"catch",Wo.catch,{unsafe:!0}));try{delete Uo.constructor}catch(t){}Wn&&Wn(Uo,Wo)}Me({global:!0,wrap:!0,forced:Zo},{Promise:Bo}),_n(Bo,No,!1),function(t){var e=C(t),n=kt.f;p&&e&&!e[pr]&&n(e,pr,{configurable:!0,get:function(){return this}})}(No),Ao=C(No),Me({target:No,stat:!0,forced:Zo},{reject:function(t){var e=Ko(this);return v(e.reject,void 0,t),e.promise}}),Me({target:No,stat:!0,forced:Zo},{resolve:function(t){return function(t,e){if(Pt(t),F(e)&&e.constructor===t)return e;var n=ko.f(t);return(0,n.resolve)(e),n.promise}(this,t)}}),Me({target:No,stat:!0,forced:ti},{all:function(t){var e=this,n=Ko(e),r=n.resolve,o=n.reject,i=Lo((function(){var n=$(e.resolve),i=[],u=0,a=1;Ir(t,(function(t){var c=u++,f=!1;a++,v(n,e,t).then((function(t){f||(f=!0,i[c]=t,--a||r(i))}),o)})),--a||r(i)}));return i.error&&o(i.value),n.promise},race:function(t){var e=this,n=Ko(e),r=n.reject,o=Lo((function(){var o=$(e.resolve);Ir(t,(function(t){v(o,e,t).then(n.resolve,r)}))}));return o.error&&r(o.value),n.promise}});var si=s.String,li=function(t){if("Symbol"===De(t))throw TypeError("Cannot convert a Symbol value to a string");return si(t)},pi=function(){var t=Pt(this),e="";return t.global&&(e+="g"),t.ignoreCase&&(e+="i"),t.multiline&&(e+="m"),t.dotAll&&(e+="s"),t.unicode&&(e+="u"),t.sticky&&(e+="y"),e},di=ne.PROPER,vi="toString",hi=RegExp.prototype,yi=hi[vi],gi=O(pi),mi=l((function(){return"/a/b"!=yi.call({source:"a",flags:"b"})})),bi=di&&yi.name!=vi;(mi||bi)&&re(RegExp.prototype,vi,(function(){var t=Pt(this),e=li(t.source),n=t.flags;return"/"+e+"/"+li(void 0===n&&z(hi,t)&&!("flags"in hi)?gi(t):n)}),{unsafe:!0});var wi=O("".charAt),Si=O("".charCodeAt),xi=O("".slice),Oi=function(t){return function(e,n){var r,o,i=li(M(e)),u=ue(n),a=i.length;return u<0||u>=a?t?"":void 0:(r=Si(i,u))<55296||r>56319||u+1===a||(o=Si(i,u+1))<56320||o>57343?t?wi(i,u):r:t?xi(i,u,u+2):o-56320+(r-55296<<10)+65536}},ji={codeAt:Oi(!1),charAt:Oi(!0)}.charAt,Ei="String Iterator",Ii=Qt.set,Ti=Qt.getterFor(Ei);Zn(String,"String",(function(t){Ii(this,{type:Ei,string:li(t),index:0})}),(function(){var t,e=Ti(this),n=e.string,r=e.index;return r>=n.length?{value:void 0,done:!0}:(t=ji(n,r),e.index+=t.length,{value:t,done:!1})}));var Ai=s.Array,Pi=Math.max,Ri=me.f,Mi="object"==typeof window&&window&&Object.getOwnPropertyNames?Object.getOwnPropertyNames(window):[],ki=function(t){try{return Ri(t)}catch(t){return function(t,e,n){for(var r=le(t),o=fe(e,r),i=fe(void 0===n?r:n,r),u=Ai(Pi(i-o,0)),a=0;o<i;o++,a++)Xe(u,a,t[o]);return u.length=a,u}(Mi)}},Li={f:function(t){return Mi&&"Window"==I(t)?ki(t):Ri(k(t))}},Fi=l((function(){if("function"==typeof ArrayBuffer){var t=new ArrayBuffer(8);Object.isExtensible(t)&&Object.defineProperty(t,"a",{value:8})}})),Ci=Object.isExtensible,zi=l((function(){Ci(1)}))||Fi?function(t){return!!F(t)&&((!Fi||"ArrayBuffer"!=I(t))&&(!Ci||Ci(t)))}:Ci,Ni=!l((function(){return Object.isExtensible(Object.preventExtensions({}))})),_i=u((function(t){var e=kt.f,n=!1,r=lt("meta"),o=0,i=function(t){e(t,r,{value:{objectID:"O"+o++,weakData:{}}})},u=t.exports={enable:function(){u.enable=function(){},n=!0;var t=me.f,e=O([].splice),o={};o[r]=1,t(o).length&&(me.f=function(n){for(var o=t(n),i=0,u=o.length;i<u;i++)if(o[i]===r){e(o,i,1);break}return o},Me({target:"Object",stat:!0,forced:!0},{getOwnPropertyNames:Li.f}))},fastKey:function(t,e){if(!F(t))return"symbol"==typeof t?t:("string"==typeof t?"S":"P")+t;if(!at(t,r)){if(!zi(t))return"F";if(!e)return"E";i(t)}return t[r].objectID},getWeakData:function(t,e){if(!at(t,r)){if(!zi(t))return!0;if(!e)return!1;i(t)}return t[r].weakData},onFreeze:function(t){return Ni&&n&&zi(t)&&!at(t,r)&&i(t),t}};Wt[r]=!0})),Di=yt("species"),Gi=s.Array,Ui=function(t,e){return new(function(t){var e;return ke(t)&&(e=t.constructor,(Ke(e)&&(e===Gi||ke(e.prototype))||F(e)&&null===(e=e[Di]))&&(e=void 0)),void 0===e?Gi:e}(t))(0===e?0:e)},Bi=O([].push),Wi=function(t){var e=1==t,n=2==t,r=3==t,o=4==t,i=6==t,u=7==t,a=5==t||i;return function(c,f,s,l){for(var p,d,v=it(c),h=P(v),y=yr(f,s),g=le(h),m=0,b=l||Ui,w=e?b(c,g):n||u?b(c,0):void 0;g>m;m++)if((a||m in h)&&(d=y(p=h[m],m,v),t))if(e)w[m]=d;else if(d)switch(t){case 3:return!0;case 5:return p;case 6:return m;case 2:Bi(w,p)}else switch(t){case 4:return!1;case 7:Bi(w,p)}return i?-1:r||o?o:w}},Vi={forEach:Wi(0),map:Wi(1),filter:Wi(2),some:Wi(3),every:Wi(4),find:Wi(5),findIndex:Wi(6),filterReject:Wi(7)},Hi=_i.getWeakData,qi=Qt.set,Ki=Qt.getterFor,Xi=Vi.find,Yi=Vi.findIndex,$i=O([].splice),Ji=0,Qi=function(t){return t.frozen||(t.frozen=new Zi)},Zi=function(){this.entries=[]},tu=function(t,e){return Xi(t.entries,(function(t){return t[0]===e}))};Zi.prototype={get:function(t){var e=tu(this,t);if(e)return e[1]},has:function(t){return!!tu(this,t)},set:function(t,e){var n=tu(this,t);n?n[1]=e:this.entries.push([t,e])},delete:function(t){var e=Yi(this.entries,(function(e){return e[0]===t}));return~e&&$i(this.entries,e,1),!!~e}};var eu,nu={getConstructor:function(t,e,n,r){var o=t((function(t,o){vr(t,i),qi(t,{type:e,id:Ji++,frozen:void 0}),null!=o&&Ir(o,t[r],{that:t,AS_ENTRIES:n})})),i=o.prototype,u=Ki(e),a=function(t,e,n){var r=u(t),o=Hi(Pt(e),!0);return!0===o?Qi(r).set(e,n):o[r.id]=n,t};return lr(i,{delete:function(t){var e=u(this);if(!F(t))return!1;var n=Hi(t);return!0===n?Qi(e).delete(t):n&&at(n,e.id)&&delete n[e.id]},has:function(t){var e=u(this);if(!F(t))return!1;var n=Hi(t);return!0===n?Qi(e).has(t):n&&at(n,e.id)}}),lr(i,n?{get:function(t){var e=u(this);if(F(t)){var n=Hi(t);return!0===n?Qi(e).get(t):n?n[e.id]:void 0}},set:function(t,e){return a(this,t,e)}}:{add:function(t){return a(this,t,!0)}}),o}},ru=Qt.enforce,ou=!s.ActiveXObject&&"ActiveXObject"in s,iu=function(t){return function(){return t(this,arguments.length?arguments[0]:void 0)}},uu=function(t,e,n){var r=-1!==t.indexOf("Map"),o=-1!==t.indexOf("Weak"),i=r?"set":"add",u=s[t],a=u&&u.prototype,c=u,f={},p=function(t){var e=O(a[t]);re(a,t,"add"==t?function(t){return e(this,0===t?0:t),this}:"delete"==t?function(t){return!(o&&!F(t))&&e(this,0===t?0:t)}:"get"==t?function(t){return o&&!F(t)?void 0:e(this,0===t?0:t)}:"has"==t?function(t){return!(o&&!F(t))&&e(this,0===t?0:t)}:function(t,n){return e(this,0===t?0:t,n),this})};if(Pe(t,!L(u)||!(o||a.forEach&&!l((function(){(new u).entries().next()})))))c=n.getConstructor(e,t,r,i),_i.enable();else if(Pe(t,!0)){var d=new c,v=d[i](o?{}:-0,1)!=d,h=l((function(){d.has(1)})),y=Cr((function(t){new u(t)})),g=!o&&l((function(){for(var t=new u,e=5;e--;)t[i](e,e);return!t.has(-0)}));y||((c=e((function(t,e){vr(t,a);var n=function(t,e,n){var r,o;return Wn&&L(r=e.constructor)&&r!==n&&F(o=r.prototype)&&o!==n.prototype&&Wn(t,o),t}(new u,t,c);return null!=e&&Ir(e,n[i],{that:n,AS_ENTRIES:r}),n}))).prototype=a,a.constructor=c),(h||g)&&(p("delete"),p("has"),r&&p("get")),(g||v)&&p(i),o&&a.clear&&delete a.clear}return f[t]=c,Me({global:!0,forced:c!=u},f),_n(c,t),o||n.setStrong(c,t,r),c}("WeakMap",iu,nu);if(Gt&&ou){eu=nu.getConstructor(iu,"WeakMap",!0),_i.enable();var au=uu.prototype,cu=O(au.delete),fu=O(au.has),su=O(au.get),lu=O(au.set);lr(au,{delete:function(t){if(F(t)&&!zi(t)){var e=ru(this);return e.frozen||(e.frozen=new eu),cu(this,t)||e.frozen.delete(t)}return cu(this,t)},has:function(t){if(F(t)&&!zi(t)){var e=ru(this);return e.frozen||(e.frozen=new eu),fu(this,t)||e.frozen.has(t)}return fu(this,t)},get:function(t){if(F(t)&&!zi(t)){var e=ru(this);return e.frozen||(e.frozen=new eu),fu(this,t)?su(this,t):e.frozen.get(t)}return su(this,t)},set:function(t,e){if(F(t)&&!zi(t)){var n=ru(this);n.frozen||(n.frozen=new eu),fu(this,t)?lu(this,t,e):n.frozen.set(t,e)}else lu(this,t,e);return this}})}var pu={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},du=Ot("span").classList,vu=du&&du.constructor&&du.constructor.prototype,hu=vu===Object.prototype?void 0:vu,yu=function(t,e){var n=[][t];return!!n&&l((function(){n.call(null,e||function(){throw 1},1)}))},gu=Vi.forEach,mu=yu("forEach")?[].forEach:function(t){return gu(this,t,arguments.length>1?arguments[1]:void 0)},bu=function(t){if(t&&t.forEach!==mu)try{Lt(t,"forEach",mu)}catch(e){t.forEach=mu}};for(var wu in pu)pu[wu]&&bu(s[wu]&&s[wu].prototype);bu(hu);var Su=yt("iterator"),xu=yt("toStringTag"),Ou=rr.values,ju=function(t,e){if(t){if(t[Su]!==Ou)try{Lt(t,Su,Ou)}catch(e){t[Su]=Ou}if(t[xu]||Lt(t,xu,e),pu[e])for(var n in rr)if(t[n]!==rr[n])try{Lt(t,n,rr[n])}catch(e){t[n]=rr[n]}}};for(var Eu in pu)ju(s[Eu]&&s[Eu].prototype,Eu);ju(hu,"DOMTokenList");var Iu=new WeakMap;function Tu(t){return t.getMenuConfig("uploadImage")}function Au(t,n){return rn(this,void 0,void 0,(function(){return on(this,(function(r){return[2,new Promise((function(r){var o=new FileReader;o.readAsDataURL(n),o.onload=function(){var i=o.result;if(i){var u=i.toString(),a=0===u.indexOf("data:image")?"":u;e.insertImageNode(t,u,n.name,a),r("ok")}}}))]}))}))}function Pu(n,r){return rn(this,void 0,void 0,(function(){var o,i,u,a;return on(this,(function(c){switch(c.label){case 0:return o=function(n){var r=Iu.get(n);if(null!=r)return r;var o=Tu(n),i=o.onSuccess,u=o.onProgress,a=o.onFailed,c=o.customInsert,f=o.onError;return r=t.createUploader(nn(nn({},o),{onProgress:function(t){n.showProgressBar(t),u&&u(t)},onSuccess:function(t,r){if(c)return c(r,(function(t,r,o){return e.insertImageNode(n,t,r,o)})),void i(t,r);var o=r.errno,u=void 0===o?1:o,f=r.data,s=void 0===f?{}:f;if(0===u){if(Array.isArray(s))s.forEach((function(t){var r=t.url,o=void 0===r?"":r,i=t.alt,u=void 0===i?"":i,a=t.href,c=void 0===a?"":a;e.insertImageNode(n,o,u,c)}));else{var l=s.url,p=void 0===l?"":l,d=s.alt,v=void 0===d?"":d,h=s.href,y=void 0===h?"":h;e.insertImageNode(n,p,v,y)}i(t,r)}else a(t,r)},onError:function(t,e,n){f(t,e,n)}})),Iu.set(n,r),r}(n),i=r.name,u=r.type,a=r.size,o.addFile({name:i,type:u,size:a,data:r}),[4,o.upload()];case 1:return c.sent(),[2]}}))}))}function Ru(t,n){var r,o;return rn(this,void 0,void 0,(function(){var i,u,a,c,f,s,l,p,d;return on(this,(function(v){switch(v.label){case 0:if(null==n)return[2];i=Array.prototype.slice.call(n),u=Tu(t),a=u.customUpload,c=u.base64LimitSize,v.label=1;case 1:v.trys.push([1,11,12,17]),f=an(i),v.label=2;case 2:return[4,f.next()];case 3:return(s=v.sent()).done?[3,10]:(l=s.value,p=l.size,c&&p<=c?[4,Au(t,l)]:[3,5]);case 4:return v.sent(),[3,9];case 5:return a?[4,a(l,(function(n,r,o){return e.insertImageNode(t,n,r,o)}))]:[3,7];case 6:return v.sent(),[3,9];case 7:return[4,Pu(t,l)];case 8:v.sent(),v.label=9;case 9:return[3,2];case 10:return[3,17];case 11:return d=v.sent(),r={error:d},[3,17];case 12:return v.trys.push([12,,15,16]),s&&!s.done&&(o=f.return)?[4,o.call(f)]:[3,14];case 13:v.sent(),v.label=14;case 14:return[3,16];case 15:if(r)throw r.error;return[7];case 16:return[7];case 17:return[2]}}))}))}var Mu=O([].join),ku=P!=Object,Lu=yu("join",",");Me({target:"Array",proto:!0,forced:ku||!Lu},{join:function(t){return Mu(k(this),void 0===t?",":t)}});var Fu,Cu,zu=s.RegExp,Nu=l((function(){var t=zu("a","y");return t.lastIndex=2,null!=t.exec("abcd")})),_u=Nu||l((function(){return!zu("a","y").sticky})),Du={BROKEN_CARET:Nu||l((function(){var t=zu("^r","gy");return t.lastIndex=2,null!=t.exec("str")})),MISSED_STICKY:_u,UNSUPPORTED_Y:Nu},Gu=s.RegExp,Uu=l((function(){var t=Gu(".","s");return!(t.dotAll&&t.exec("\n")&&"s"===t.flags)})),Bu=s.RegExp,Wu=l((function(){var t=Bu("(?<a>b)","g");return"b"!==t.exec("b").groups.a||"bc"!=="b".replace(t,"$<a>c")})),Vu=Qt.get,Hu=rt("native-string-replace",String.prototype.replace),qu=RegExp.prototype.exec,Ku=qu,Xu=O("".charAt),Yu=O("".indexOf),$u=O("".replace),Ju=O("".slice),Qu=(Cu=/b*/g,v(qu,Fu=/a/,"a"),v(qu,Cu,"a"),0!==Fu.lastIndex||0!==Cu.lastIndex),Zu=Du.BROKEN_CARET,ta=void 0!==/()??/.exec("")[1];(Qu||ta||Zu||Uu||Wu)&&(Ku=function(t){var e,n,r,o,i,u,a,c=this,f=Vu(c),s=li(t),l=f.raw;if(l)return l.lastIndex=c.lastIndex,e=v(Ku,l,s),c.lastIndex=l.lastIndex,e;var p=f.groups,d=Zu&&c.sticky,h=v(pi,c),y=c.source,g=0,m=s;if(d&&(h=$u(h,"y",""),-1===Yu(h,"g")&&(h+="g"),m=Ju(s,c.lastIndex),c.lastIndex>0&&(!c.multiline||c.multiline&&"\n"!==Xu(s,c.lastIndex-1))&&(y="(?: "+y+")",m=" "+m,g++),n=new RegExp("^(?:"+y+")",h)),ta&&(n=new RegExp("^"+y+"$(?!\\s)",h)),Qu&&(r=c.lastIndex),o=v(qu,d?n:c,m),d?o?(o.input=Ju(o.input,g),o[0]=Ju(o[0],g),o.index=c.lastIndex,c.lastIndex+=o[0].length):c.lastIndex=0:Qu&&o&&(c.lastIndex=c.global?o.index+o[0].length:r),ta&&o&&o.length>1&&v(Hu,o[0],n,(function(){for(i=1;i<arguments.length-2;i++)void 0===arguments[i]&&(o[i]=void 0)})),o&&p)for(o.groups=u=bn(null),i=0;i<p.length;i++)u[(a=p[i])[0]]=o[a[1]];return o});Me({target:"RegExp",proto:!0,forced:/./.exec!==Ku},{exec:Ku});n.append&&(o.default.fn.append=n.append),n.on&&(o.default.fn.on=n.on),n.remove&&(o.default.fn.remove=n.remove),n.val&&(o.default.fn.val=n.val),n.click&&(o.default.fn.click=n.click),n.hide&&(o.default.fn.hide=n.hide);var ea=function(){function n(){this.title=t.t("uploadImgModule.uploadImage"),this.iconSvg='<svg viewBox="0 0 1024 1024"><path d="M828.708571 585.045333a48.761905 48.761905 0 0 0-48.737523 48.761905v18.529524l-72.143238-72.167619a135.972571 135.972571 0 0 0-191.585524 0l-34.133334 34.133333-120.880762-120.953905a138.898286 138.898286 0 0 0-191.585523 0l-72.167619 72.167619V292.400762a48.786286 48.786286 0 0 1 48.761904-48.761905h341.23581a48.737524 48.737524 0 0 0 34.474667-83.285333 48.737524 48.737524 0 0 0-34.474667-14.287238H146.236952A146.212571 146.212571 0 0 0 0 292.400762v585.289143A146.358857 146.358857 0 0 0 146.236952 1024h584.996572a146.212571 146.212571 0 0 0 146.236952-146.310095V633.807238a48.786286 48.786286 0 0 0-48.761905-48.761905zM146.261333 926.45181a48.737524 48.737524 0 0 1-48.761904-48.761905v-174.128762l141.409523-141.458286a38.497524 38.497524 0 0 1 53.126096 0l154.526476 154.624 209.627428 209.724953H146.236952z m633.734096-48.761905c-0.073143 9.337905-3.145143 18.383238-8.777143 25.843809l-219.843048-220.94019 34.133333-34.133334a37.546667 37.546667 0 0 1 53.613715 0l140.873143 141.897143V877.714286zM1009.615238 160.231619L863.329524 13.897143a48.737524 48.737524 0 0 0-16.091429-10.24c-11.849143-4.87619-25.161143-4.87619-37.059047 0a48.761905 48.761905 0 0 0-16.067048 10.24l-146.236952 146.334476a49.005714 49.005714 0 0 0 69.217523 69.241905l62.902858-63.390476v272.627809a48.761905 48.761905 0 1 0 97.475047 0V166.083048l62.902857 63.390476a48.737524 48.737524 0 0 0 69.217524 0 48.761905 48.761905 0 0 0 0-69.241905z"></path></svg>',this.tag="button"}return n.prototype.getValue=function(t){return""},n.prototype.isActive=function(t){return!1},n.prototype.isDisabled=function(t){return e.isInsertImageMenuDisabled(t)},n.prototype.getMenuConfig=function(t){return t.getMenuConfig("uploadImage")},n.prototype.exec=function(t,n){var r=this.getMenuConfig(t),i=r.allowedFileTypes,u=void 0===i?[]:i,a=r.customBrowseAndUpload;if(a)a((function(n,r,o){return e.insertImageNode(t,n,r,o)}));else{var c="";u.length>0&&(c='accept="'+u.join(", ")+'"');var f=o.default("body"),s=o.default('<input type="file" '+c+" multiple/>");s.hide(),f.append(s),s.click(),s.on("change",(function(){var e=s[0].files;Ru(t,e)}))}},n}();var na={menus:[{key:"uploadImage",factory:function(){return new ea},config:{server:"",fieldName:"wangeditor-uploaded-image",maxFileSize:2097152,maxNumberOfFiles:100,allowedFileTypes:["image/*"],meta:{},metaWithUrl:!1,withCredentials:!1,timeout:1e4,onBeforeUpload:function(t){return t},onProgress:function(t){},onSuccess:function(t,e){},onFailed:function(t,e){console.error("'"+t.name+"' upload failed",e)},onError:function(t,e,n){console.error("'"+t.name+"' upload error",n)},base64LimitSize:0}}],editorPlugin:function(t){var n=t.insertData,r=t;return r.insertData=function(o){if(e.isInsertImageMenuDisabled(r))n(o);else if(o.getData("text/plain"))n(o);else{var i=o.files;if(i.length<=0)n(o);else Array.prototype.slice.call(i).some((function(t){return"image"===function(t,e){var n="function"==typeof Symbol&&t[Symbol.iterator];if(!n)return t;var r,o,i=n.call(t),u=[];try{for(;(void 0===e||e-- >0)&&!(r=i.next()).done;)u.push(r.value)}catch(t){o={error:t}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return u}(t.type.split("/"),1)[0]}))?Ru(t,i):n(o)}},r}};return na}));
|
|
1
|
+
!function(t,e){"object"==typeof exports&&"undefined"!=typeof module?module.exports=e(require("@wangeditor-next/core"),require("@wangeditor-next/basic-modules"),require("dom7")):"function"==typeof define&&define.amd?define(["@wangeditor-next/core","@wangeditor-next/basic-modules","dom7"],e):(t="undefined"!=typeof globalThis?globalThis:t||self).WangEditorUploadImageModule=e(t.core,t.basicModules,t.$)}(this,(function(t,e,n){"use strict";function r(t){return t&&"object"==typeof t&&"default"in t?t:{default:t}}var o=r(n);t.i18nAddResources("en",{uploadImgModule:{uploadImage:"Upload Image",uploadError:"{{fileName}} upload error"}}),t.i18nAddResources("zh-CN",{uploadImgModule:{uploadImage:"上传图片",uploadError:"{{fileName}} 上传出错"}});var i="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{};function u(t){var e={exports:{}};return t(e,e.exports),e.exports}var a,c,f=function(t){return t&&t.Math===Math&&t},s=f("object"==typeof globalThis&&globalThis)||f("object"==typeof window&&window)||f("object"==typeof self&&self)||f("object"==typeof i&&i)||f("object"==typeof i&&i)||function(){return this}()||Function("return this")(),l=function(t){try{return!!t()}catch(t){return!0}},p=!l((function(){return 7!==Object.defineProperty({},1,{get:function(){return 7}})[1]})),d=!l((function(){var t=function(){}.bind();return"function"!=typeof t||t.hasOwnProperty("prototype")})),v=Function.prototype.call,h=d?v.bind(v):function(){return v.apply(v,arguments)},y={}.propertyIsEnumerable,g=Object.getOwnPropertyDescriptor,m={f:g&&!y.call({1:2},1)?function(t){var e=g(this,t);return!!e&&e.enumerable}:y},b=function(t,e){return{enumerable:!(1&t),configurable:!(2&t),writable:!(4&t),value:e}},w=Function.prototype,S=w.call,O=d&&w.bind.bind(S,S),E=d?O:function(t){return function(){return S.apply(t,arguments)}},j=E({}.toString),x=E("".slice),I=function(t){return x(j(t),8,-1)},T=Object,P=E("".split),R=l((function(){return!T("z").propertyIsEnumerable(0)}))?function(t){return"String"===I(t)?P(t,""):T(t)}:T,A=function(t){return null==t},C=TypeError,N=function(t){if(A(t))throw new C("Can't call method on "+t);return t},k=function(t){return R(N(t))},M="object"==typeof document&&document.all,L=void 0===M&&void 0!==M?function(t){return"function"==typeof t||t===M}:function(t){return"function"==typeof t},D=function(t){return"object"==typeof t?null!==t:L(t)},F=function(t,e){return arguments.length<2?(n=s[t],L(n)?n:void 0):s[t]&&s[t][e];var n},z=E({}.isPrototypeOf),_=s.navigator,U=_&&_.userAgent,B=U?String(U):"",G=s.process,W=s.Deno,V=G&&G.versions||W&&W.version,H=V&&V.v8;H&&(c=(a=H.split("."))[0]>0&&a[0]<4?1:+(a[0]+a[1])),!c&&B&&(!(a=B.match(/Edge\/(\d+)/))||a[1]>=74)&&(a=B.match(/Chrome\/(\d+)/))&&(c=+a[1]);var q=c,K=s.String,X=!!Object.getOwnPropertySymbols&&!l((function(){var t=Symbol("symbol detection");return!K(t)||!(Object(t)instanceof Symbol)||!Symbol.sham&&q&&q<41})),Y=X&&!Symbol.sham&&"symbol"==typeof Symbol.iterator,$=Object,J=Y?function(t){return"symbol"==typeof t}:function(t){var e=F("Symbol");return L(e)&&z(e.prototype,$(t))},Q=String,Z=function(t){try{return Q(t)}catch(t){return"Object"}},tt=TypeError,et=function(t){if(L(t))return t;throw new tt(Z(t)+" is not a function")},nt=function(t,e){var n=t[e];return A(n)?void 0:et(n)},rt=TypeError,ot=Object.defineProperty,it=function(t,e){try{ot(s,t,{value:e,configurable:!0,writable:!0})}catch(n){s[t]=e}return e},ut=u((function(t){var e="__core-js_shared__",n=t.exports=s[e]||it(e,{});(n.versions||(n.versions=[])).push({version:"3.38.1",mode:"global",copyright:"© 2014-2024 Denis Pushkarev (zloirock.ru)",license:"https://github.com/zloirock/core-js/blob/v3.38.1/LICENSE",source:"https://github.com/zloirock/core-js"})})),at=function(t,e){return ut[t]||(ut[t]=e||{})},ct=Object,ft=function(t){return ct(N(t))},st=E({}.hasOwnProperty),lt=Object.hasOwn||function(t,e){return st(ft(t),e)},pt=0,dt=Math.random(),vt=E(1..toString),ht=function(t){return"Symbol("+(void 0===t?"":t)+")_"+vt(++pt+dt,36)},yt=s.Symbol,gt=at("wks"),mt=Y?yt.for||yt:yt&&yt.withoutSetter||ht,bt=function(t){return lt(gt,t)||(gt[t]=X&<(yt,t)?yt[t]:mt("Symbol."+t)),gt[t]},wt=TypeError,St=bt("toPrimitive"),Ot=function(t,e){if(!D(t)||J(t))return t;var n,r=nt(t,St);if(r){if(void 0===e&&(e="default"),n=h(r,t,e),!D(n)||J(n))return n;throw new wt("Can't convert object to primitive value")}return void 0===e&&(e="number"),function(t,e){var n,r;if("string"===e&&L(n=t.toString)&&!D(r=h(n,t)))return r;if(L(n=t.valueOf)&&!D(r=h(n,t)))return r;if("string"!==e&&L(n=t.toString)&&!D(r=h(n,t)))return r;throw new rt("Can't convert object to primitive value")}(t,e)},Et=function(t){var e=Ot(t,"string");return J(e)?e:e+""},jt=s.document,xt=D(jt)&&D(jt.createElement),It=function(t){return xt?jt.createElement(t):{}},Tt=!p&&!l((function(){return 7!==Object.defineProperty(It("div"),"a",{get:function(){return 7}}).a})),Pt=Object.getOwnPropertyDescriptor,Rt={f:p?Pt:function(t,e){if(t=k(t),e=Et(e),Tt)try{return Pt(t,e)}catch(t){}if(lt(t,e))return b(!h(m.f,t,e),t[e])}},At=p&&l((function(){return 42!==Object.defineProperty((function(){}),"prototype",{value:42,writable:!1}).prototype})),Ct=String,Nt=TypeError,kt=function(t){if(D(t))return t;throw new Nt(Ct(t)+" is not an object")},Mt=TypeError,Lt=Object.defineProperty,Dt=Object.getOwnPropertyDescriptor,Ft="enumerable",zt="configurable",_t="writable",Ut={f:p?At?function(t,e,n){if(kt(t),e=Et(e),kt(n),"function"==typeof t&&"prototype"===e&&"value"in n&&_t in n&&!n[_t]){var r=Dt(t,e);r&&r[_t]&&(t[e]=n.value,n={configurable:zt in n?n[zt]:r[zt],enumerable:Ft in n?n[Ft]:r[Ft],writable:!1})}return Lt(t,e,n)}:Lt:function(t,e,n){if(kt(t),e=Et(e),kt(n),Tt)try{return Lt(t,e,n)}catch(t){}if("get"in n||"set"in n)throw new Mt("Accessors not supported");return"value"in n&&(t[e]=n.value),t}},Bt=p?function(t,e,n){return Ut.f(t,e,b(1,n))}:function(t,e,n){return t[e]=n,t},Gt=Function.prototype,Wt=p&&Object.getOwnPropertyDescriptor,Vt=lt(Gt,"name"),Ht={EXISTS:Vt,PROPER:Vt&&"something"===function(){}.name,CONFIGURABLE:Vt&&(!p||p&&Wt(Gt,"name").configurable)},qt=E(Function.toString);L(ut.inspectSource)||(ut.inspectSource=function(t){return qt(t)});var Kt,Xt,Yt,$t=ut.inspectSource,Jt=s.WeakMap,Qt=L(Jt)&&/native code/.test(String(Jt)),Zt=at("keys"),te=function(t){return Zt[t]||(Zt[t]=ht(t))},ee={},ne="Object already initialized",re=s.TypeError,oe=s.WeakMap;if(Qt||ut.state){var ie=ut.state||(ut.state=new oe);ie.get=ie.get,ie.has=ie.has,ie.set=ie.set,Kt=function(t,e){if(ie.has(t))throw new re(ne);return e.facade=t,ie.set(t,e),e},Xt=function(t){return ie.get(t)||{}},Yt=function(t){return ie.has(t)}}else{var ue=te("state");ee[ue]=!0,Kt=function(t,e){if(lt(t,ue))throw new re(ne);return e.facade=t,Bt(t,ue,e),e},Xt=function(t){return lt(t,ue)?t[ue]:{}},Yt=function(t){return lt(t,ue)}}var ae={set:Kt,get:Xt,has:Yt,enforce:function(t){return Yt(t)?Xt(t):Kt(t,{})},getterFor:function(t){return function(e){var n;if(!D(e)||(n=Xt(e)).type!==t)throw new re("Incompatible receiver, "+t+" required");return n}}},ce=u((function(t){var e=Ht.CONFIGURABLE,n=ae.enforce,r=ae.get,o=String,i=Object.defineProperty,u=E("".slice),a=E("".replace),c=E([].join),f=p&&!l((function(){return 8!==i((function(){}),"length",{value:8}).length})),s=String(String).split("String"),d=t.exports=function(t,r,l){"Symbol("===u(o(r),0,7)&&(r="["+a(o(r),/^Symbol\(([^)]*)\).*$/,"$1")+"]"),l&&l.getter&&(r="get "+r),l&&l.setter&&(r="set "+r),(!lt(t,"name")||e&&t.name!==r)&&(p?i(t,"name",{value:r,configurable:!0}):t.name=r),f&&l&<(l,"arity")&&t.length!==l.arity&&i(t,"length",{value:l.arity});try{l&<(l,"constructor")&&l.constructor?p&&i(t,"prototype",{writable:!1}):t.prototype&&(t.prototype=void 0)}catch(t){}var d=n(t);return lt(d,"source")||(d.source=c(s,"string"==typeof r?r:"")),t};Function.prototype.toString=d((function(){return L(this)&&r(this).source||$t(this)}),"toString")})),fe=function(t,e,n,r){r||(r={});var o=r.enumerable,i=void 0!==r.name?r.name:e;if(L(n)&&ce(n,i,r),r.global)o?t[e]=n:it(e,n);else{try{r.unsafe?t[e]&&(o=!0):delete t[e]}catch(t){}o?t[e]=n:Ut.f(t,e,{value:n,enumerable:!1,configurable:!r.nonConfigurable,writable:!r.nonWritable})}return t},se=Math.ceil,le=Math.floor,pe=Math.trunc||function(t){var e=+t;return(e>0?le:se)(e)},de=function(t){var e=+t;return e!=e||0===e?0:pe(e)},ve=Math.max,he=Math.min,ye=function(t,e){var n=de(t);return n<0?ve(n+e,0):he(n,e)},ge=Math.min,me=function(t){return e=t.length,(n=de(e))>0?ge(n,9007199254740991):0;var e,n},be=function(t){return function(e,n,r){var o=k(e),i=me(o);if(0===i)return!t&&-1;var u,a=ye(r,i);if(t&&n!=n){for(;i>a;)if((u=o[a++])!=u)return!0}else for(;i>a;a++)if((t||a in o)&&o[a]===n)return t||a||0;return!t&&-1}},we={includes:be(!0),indexOf:be(!1)}.indexOf,Se=E([].push),Oe=function(t,e){var n,r=k(t),o=0,i=[];for(n in r)!lt(ee,n)&<(r,n)&&Se(i,n);for(;e.length>o;)lt(r,n=e[o++])&&(~we(i,n)||Se(i,n));return i},Ee=["constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleString","toString","valueOf"],je=Ee.concat("length","prototype"),xe={f:Object.getOwnPropertyNames||function(t){return Oe(t,je)}},Ie={f:Object.getOwnPropertySymbols},Te=E([].concat),Pe=F("Reflect","ownKeys")||function(t){var e=xe.f(kt(t)),n=Ie.f;return n?Te(e,n(t)):e},Re=function(t,e,n){for(var r=Pe(e),o=Ut.f,i=Rt.f,u=0;u<r.length;u++){var a=r[u];lt(t,a)||n&<(n,a)||o(t,a,i(e,a))}},Ae=/#|\.prototype\./,Ce=function(t,e){var n=ke[Ne(t)];return n===Le||n!==Me&&(L(e)?l(e):!!e)},Ne=Ce.normalize=function(t){return String(t).replace(Ae,".").toLowerCase()},ke=Ce.data={},Me=Ce.NATIVE="N",Le=Ce.POLYFILL="P",De=Ce,Fe=Rt.f,ze=function(t,e){var n,r,o,i,u,a=t.target,c=t.global,f=t.stat;if(n=c?s:f?s[a]||it(a,{}):s[a]&&s[a].prototype)for(r in e){if(i=e[r],o=t.dontCallGetSet?(u=Fe(n,r))&&u.value:n[r],!De(c?r:a+(f?".":"#")+r,t.forced)&&void 0!==o){if(typeof i==typeof o)continue;Re(i,o)}(t.sham||o&&o.sham)&&Bt(i,"sham",!0),fe(n,r,i,t)}},_e=Array.isArray||function(t){return"Array"===I(t)},Ue={};Ue[bt("toStringTag")]="z";var Be="[object z]"===String(Ue),Ge=bt("toStringTag"),We=Object,Ve="Arguments"===I(function(){return arguments}()),He=Be?I:function(t){var e,n,r;return void 0===t?"Undefined":null===t?"Null":"string"==typeof(n=function(t,e){try{return t[e]}catch(t){}}(e=We(t),Ge))?n:Ve?I(e):"Object"===(r=I(e))&&L(e.callee)?"Arguments":r},qe=function(){},Ke=F("Reflect","construct"),Xe=/^\s*(?:class|function)\b/,Ye=E(Xe.exec),$e=!Xe.test(qe),Je=function(t){if(!L(t))return!1;try{return Ke(qe,[],t),!0}catch(t){return!1}},Qe=function(t){if(!L(t))return!1;switch(He(t)){case"AsyncFunction":case"GeneratorFunction":case"AsyncGeneratorFunction":return!1}try{return $e||!!Ye(Xe,$t(t))}catch(t){return!0}};Qe.sham=!0;var Ze,tn=!Ke||l((function(){var t;return Je(Je.call)||!Je(Object)||!Je((function(){t=!0}))||t}))?Qe:Je,en=bt("species"),nn=E([].slice),rn=(Ze="slice",q>=51||!l((function(){var t=[];return(t.constructor={})[en]=function(){return{foo:1}},1!==t[Ze](Boolean).foo}))),on=bt("species"),un=Array,an=Math.max;ze({target:"Array",proto:!0,forced:!rn},{slice:function(t,e){var n,r,o,i,u,a,c=k(this),f=me(c),s=ye(t,f),l=ye(void 0===e?f:e,f);if(_e(c)&&(n=c.constructor,(tn(n)&&(n===un||_e(n.prototype))||D(n)&&null===(n=n[on]))&&(n=void 0),n===un||void 0===n))return nn(c,s,l);for(r=new(void 0===n?un:n)(an(l-s,0)),o=0;s<l;s++,o++)s in c&&(i=r,u=o,a=c[s],p?Ut.f(i,u,b(0,a)):i[u]=a);return r.length=o,r}});var cn=Be?{}.toString:function(){return"[object "+He(this)+"]"};Be||fe(Object.prototype,"toString",cn,{unsafe:!0});var fn=function(){return fn=Object.assign||function(t){for(var e,n=1,r=arguments.length;n<r;n++)for(var o in e=arguments[n])Object.prototype.hasOwnProperty.call(e,o)&&(t[o]=e[o]);return t},fn.apply(this,arguments)};function sn(t,e,n,r){return new(n||(n=Promise))((function(o,i){function u(t){try{c(r.next(t))}catch(t){i(t)}}function a(t){try{c(r.throw(t))}catch(t){i(t)}}function c(t){var e;t.done?o(t.value):(e=t.value,e instanceof n?e:new n((function(t){t(e)}))).then(u,a)}c((r=r.apply(t,e||[])).next())}))}function ln(t,e){var n,r,o,i,u={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]};return i={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(i[Symbol.iterator]=function(){return this}),i;function a(a){return function(c){return function(a){if(n)throw new TypeError("Generator is already executing.");for(;i&&(i=0,a[0]&&(u=0)),u;)try{if(n=1,r&&(o=2&a[0]?r.return:a[0]?r.throw||((o=r.return)&&o.call(r),0):r.next)&&!(o=o.call(r,a[1])).done)return o;switch(r=0,o&&(a=[2&a[0],o.value]),a[0]){case 0:case 1:o=a;break;case 4:return u.label++,{value:a[1],done:!1};case 5:u.label++,r=a[1],a=[0];continue;case 7:a=u.ops.pop(),u.trys.pop();continue;default:if(!(o=u.trys,(o=o.length>0&&o[o.length-1])||6!==a[0]&&2!==a[0])){u=0;continue}if(3===a[0]&&(!o||a[1]>o[0]&&a[1]<o[3])){u.label=a[1];break}if(6===a[0]&&u.label<o[1]){u.label=o[1],o=a;break}if(o&&u.label<o[2]){u.label=o[2],u.ops.push(a);break}o[2]&&u.ops.pop(),u.trys.pop();continue}a=e.call(t,u)}catch(t){a=[6,t],r=0}finally{n=o=0}if(5&a[0])throw a[1];return{value:a[0]?a[1]:void 0,done:!0}}([a,c])}}}function pn(t){var e="function"==typeof Symbol&&Symbol.iterator,n=e&&t[e],r=0;if(n)return n.call(t);if(t&&"number"==typeof t.length)return{next:function(){return t&&r>=t.length&&(t=void 0),{value:t&&t[r++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")}function dn(t){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var e,n=t[Symbol.asyncIterator];return n?n.call(t):(t=pn(t),e={},r("next"),r("throw"),r("return"),e[Symbol.asyncIterator]=function(){return this},e);function r(n){e[n]=t[n]&&function(e){return new Promise((function(r,o){(function(t,e,n,r){Promise.resolve(r).then((function(e){t({value:e,done:n})}),e)})(r,o,(e=t[n](e)).done,e.value)}))}}}"function"==typeof SuppressedError&&SuppressedError;var vn,hn=Object.keys||function(t){return Oe(t,Ee)},yn=p&&!At?Object.defineProperties:function(t,e){kt(t);for(var n,r=k(e),o=hn(e),i=o.length,u=0;i>u;)Ut.f(t,n=o[u++],r[n]);return t},gn={f:yn},mn=F("document","documentElement"),bn="prototype",wn="script",Sn=te("IE_PROTO"),On=function(){},En=function(t){return"<"+wn+">"+t+"</"+wn+">"},jn=function(t){t.write(En("")),t.close();var e=t.parentWindow.Object;return t=null,e},xn=function(){try{vn=new ActiveXObject("htmlfile")}catch(t){}var t,e,n;xn="undefined"!=typeof document?document.domain&&vn?jn(vn):(e=It("iframe"),n="java"+wn+":",e.style.display="none",mn.appendChild(e),e.src=String(n),(t=e.contentWindow.document).open(),t.write(En("document.F=Object")),t.close(),t.F):jn(vn);for(var r=Ee.length;r--;)delete xn[bn][Ee[r]];return xn()};ee[Sn]=!0;var In=Object.create||function(t,e){var n;return null!==t?(On[bn]=kt(t),n=new On,On[bn]=null,n[Sn]=t):n=xn(),void 0===e?n:gn.f(n,e)},Tn=Ut.f,Pn=bt("unscopables"),Rn=Array.prototype;void 0===Rn[Pn]&&Tn(Rn,Pn,{configurable:!0,value:In(null)});var An,Cn,Nn,kn=function(t){Rn[Pn][t]=!0},Mn={},Ln=!l((function(){function t(){}return t.prototype.constructor=null,Object.getPrototypeOf(new t)!==t.prototype})),Dn=te("IE_PROTO"),Fn=Object,zn=Fn.prototype,_n=Ln?Fn.getPrototypeOf:function(t){var e=ft(t);if(lt(e,Dn))return e[Dn];var n=e.constructor;return L(n)&&e instanceof n?n.prototype:e instanceof Fn?zn:null},Un=bt("iterator"),Bn=!1;[].keys&&("next"in(Nn=[].keys())?(Cn=_n(_n(Nn)))!==Object.prototype&&(An=Cn):Bn=!0);var Gn=!D(An)||l((function(){var t={};return An[Un].call(t)!==t}));Gn&&(An={}),L(An[Un])||fe(An,Un,(function(){return this}));var Wn={IteratorPrototype:An,BUGGY_SAFARI_ITERATORS:Bn},Vn=Ut.f,Hn=bt("toStringTag"),qn=function(t,e,n){t&&!n&&(t=t.prototype),t&&!lt(t,Hn)&&Vn(t,Hn,{configurable:!0,value:e})},Kn=Wn.IteratorPrototype,Xn=function(){return this},Yn=String,$n=TypeError,Jn=function(t){if(function(t){return D(t)||null===t}(t))return t;throw new $n("Can't set "+Yn(t)+" as a prototype")},Qn=Object.setPrototypeOf||("__proto__"in{}?function(){var t,e=!1,n={};try{t=function(t,e,n){try{return E(et(Object.getOwnPropertyDescriptor(t,e)[n]))}catch(t){}}(Object.prototype,"__proto__","set"),t(n,[]),e=n instanceof Array}catch(t){}return function(n,r){return N(n),Jn(r),D(n)?(e?t(n,r):n.__proto__=r,n):n}}():void 0),Zn=Ht.PROPER,tr=Ht.CONFIGURABLE,er=Wn.IteratorPrototype,nr=Wn.BUGGY_SAFARI_ITERATORS,rr=bt("iterator"),or="keys",ir="values",ur="entries",ar=function(){return this},cr=function(t,e,n,r,o,i,u){!function(t,e,n,r){var o=e+" Iterator";t.prototype=In(Kn,{next:b(+!r,n)}),qn(t,o,!1),Mn[o]=Xn}(n,e,r);var a,c,f,s=function(t){if(t===o&&y)return y;if(!nr&&t&&t in d)return d[t];switch(t){case or:case ir:case ur:return function(){return new n(this,t)}}return function(){return new n(this)}},l=e+" Iterator",p=!1,d=t.prototype,v=d[rr]||d["@@iterator"]||o&&d[o],y=!nr&&v||s(o),g="Array"===e&&d.entries||v;if(g&&(a=_n(g.call(new t)))!==Object.prototype&&a.next&&(_n(a)!==er&&(Qn?Qn(a,er):L(a[rr])||fe(a,rr,ar)),qn(a,l,!0)),Zn&&o===ir&&v&&v.name!==ir&&(tr?Bt(d,"name",ir):(p=!0,y=function(){return h(v,this)})),o)if(c={values:s(ir),keys:i?y:s(or),entries:s(ur)},u)for(f in c)(nr||p||!(f in d))&&fe(d,f,c[f]);else ze({target:e,proto:!0,forced:nr||p},c);return d[rr]!==y&&fe(d,rr,y,{name:o}),Mn[e]=y,c},fr=function(t,e){return{value:t,done:e}},sr=Ut.f,lr="Array Iterator",pr=ae.set,dr=ae.getterFor(lr),vr=cr(Array,"Array",(function(t,e){pr(this,{type:lr,target:k(t),index:0,kind:e})}),(function(){var t=dr(this),e=t.target,n=t.index++;if(!e||n>=e.length)return t.target=null,fr(void 0,!0);switch(t.kind){case"keys":return fr(n,!1);case"values":return fr(e[n],!1)}return fr([n,e[n]],!1)}),"values"),hr=Mn.Arguments=Mn.Array;if(kn("keys"),kn("values"),kn("entries"),p&&"values"!==hr.name)try{sr(hr,"name",{value:"values"})}catch(t){}var yr=function(t,e,n){return n.get&&ce(n.get,e,{getter:!0}),n.set&&ce(n.set,e,{setter:!0}),Ut.f(t,e,n)},gr=Ht.EXISTS,mr=Function.prototype,br=E(mr.toString),wr=/function\b(?:\s|\/\*[\S\s]*?\*\/|\/\/[^\n\r]*[\n\r]+)*([^\s(/]*)/,Sr=E(wr.exec);p&&!gr&&yr(mr,"name",{configurable:!0,get:function(){try{return Sr(wr,br(this))[1]}catch(t){return""}}});var Or,Er,jr,xr,Ir=function(t){return B.slice(0,t.length)===t},Tr=Ir("Bun/")?"BUN":Ir("Cloudflare-Workers")?"CLOUDFLARE":Ir("Deno/")?"DENO":Ir("Node.js/")?"NODE":s.Bun&&"string"==typeof Bun.version?"BUN":s.Deno&&"object"==typeof Deno.version?"DENO":"process"===I(s.process)?"NODE":s.window&&s.document?"BROWSER":"REST",Pr="NODE"===Tr,Rr=bt("species"),Ar=TypeError,Cr=function(t,e){if(z(e,t))return t;throw new Ar("Incorrect invocation")},Nr=TypeError,kr=bt("species"),Mr=function(t,e){var n,r=kt(t).constructor;return void 0===r||A(n=kt(r)[kr])?e:function(t){if(tn(t))return t;throw new Nr(Z(t)+" is not a constructor")}(n)},Lr=Function.prototype,Dr=Lr.apply,Fr=Lr.call,zr="object"==typeof Reflect&&Reflect.apply||(d?Fr.bind(Dr):function(){return Fr.apply(Dr,arguments)}),_r=function(t){if("Function"===I(t))return E(t)},Ur=_r(_r.bind),Br=function(t,e){return et(t),void 0===e?t:d?Ur(t,e):function(){return t.apply(e,arguments)}},Gr=TypeError,Wr=/(?:ipad|iphone|ipod).*applewebkit/i.test(B),Vr=s.setImmediate,Hr=s.clearImmediate,qr=s.process,Kr=s.Dispatch,Xr=s.Function,Yr=s.MessageChannel,$r=s.String,Jr=0,Qr={},Zr="onreadystatechange";l((function(){Or=s.location}));var to=function(t){if(lt(Qr,t)){var e=Qr[t];delete Qr[t],e()}},eo=function(t){return function(){to(t)}},no=function(t){to(t.data)},ro=function(t){s.postMessage($r(t),Or.protocol+"//"+Or.host)};Vr&&Hr||(Vr=function(t){!function(t,e){if(t<e)throw new Gr("Not enough arguments")}(arguments.length,1);var e=L(t)?t:Xr(t),n=nn(arguments,1);return Qr[++Jr]=function(){zr(e,void 0,n)},Er(Jr),Jr},Hr=function(t){delete Qr[t]},Pr?Er=function(t){qr.nextTick(eo(t))}:Kr&&Kr.now?Er=function(t){Kr.now(eo(t))}:Yr&&!Wr?(xr=(jr=new Yr).port2,jr.port1.onmessage=no,Er=Br(xr.postMessage,xr)):s.addEventListener&&L(s.postMessage)&&!s.importScripts&&Or&&"file:"!==Or.protocol&&!l(ro)?(Er=ro,s.addEventListener("message",no,!1)):Er=Zr in It("script")?function(t){mn.appendChild(It("script"))[Zr]=function(){mn.removeChild(this),to(t)}}:function(t){setTimeout(eo(t),0)});var oo={set:Vr,clear:Hr},io=Object.getOwnPropertyDescriptor,uo=function(){this.head=null,this.tail=null};uo.prototype={add:function(t){var e={item:t,next:null},n=this.tail;n?n.next=e:this.head=e,this.tail=e},get:function(){var t=this.head;if(t)return null===(this.head=t.next)&&(this.tail=null),t.item}};var ao,co,fo,so,lo,po=uo,vo=/ipad|iphone|ipod/i.test(B)&&"undefined"!=typeof Pebble,ho=/web0s(?!.*chrome)/i.test(B),yo=oo.set,go=s.MutationObserver||s.WebKitMutationObserver,mo=s.document,bo=s.process,wo=s.Promise,So=function(t){if(!p)return s[t];var e=io(s,t);return e&&e.value}("queueMicrotask");if(!So){var Oo=new po,Eo=function(){var t,e;for(Pr&&(t=bo.domain)&&t.exit();e=Oo.get();)try{e()}catch(t){throw Oo.head&&ao(),t}t&&t.enter()};Wr||Pr||ho||!go||!mo?!vo&&wo&&wo.resolve?((so=wo.resolve(void 0)).constructor=wo,lo=Br(so.then,so),ao=function(){lo(Eo)}):Pr?ao=function(){bo.nextTick(Eo)}:(yo=Br(yo,s),ao=function(){yo(Eo)}):(co=!0,fo=mo.createTextNode(""),new go(Eo).observe(fo,{characterData:!0}),ao=function(){fo.data=co=!co}),So=function(t){Oo.head||ao(),Oo.add(t)}}var jo=So,xo=function(t){try{return{error:!1,value:t()}}catch(t){return{error:!0,value:t}}},Io=s.Promise;Io&&Io.prototype;var To,Po,Ro,Ao,Co=bt("species"),No=!1,ko=L(s.PromiseRejectionEvent),Mo=De("Promise",(function(){var t=$t(Io),e=t!==String(Io);if(!e&&66===q)return!0;if(!q||q<51||!/native code/.test(t)){var n=new Io((function(t){t(1)})),r=function(t){t((function(){}),(function(){}))};if((n.constructor={})[Co]=r,!(No=n.then((function(){}))instanceof r))return!0}return!(e||"BROWSER"!==Tr&&"DENO"!==Tr||ko)})),Lo={CONSTRUCTOR:Mo,REJECTION_EVENT:ko,SUBCLASSING:No},Do=TypeError,Fo=function(t){var e,n;this.promise=new t((function(t,r){if(void 0!==e||void 0!==n)throw new Do("Bad Promise constructor");e=t,n=r})),this.resolve=et(e),this.reject=et(n)},zo={f:function(t){return new Fo(t)}},_o=oo.set,Uo="Promise",Bo=Lo.CONSTRUCTOR,Go=Lo.REJECTION_EVENT,Wo=Lo.SUBCLASSING,Vo=ae.getterFor(Uo),Ho=ae.set,qo=Io&&Io.prototype,Ko=Io,Xo=qo,Yo=s.TypeError,$o=s.document,Jo=s.process,Qo=zo.f,Zo=Qo,ti=!!($o&&$o.createEvent&&s.dispatchEvent),ei="unhandledrejection",ni=function(t){var e;return!(!D(t)||!L(e=t.then))&&e},ri=function(t,e){var n,r,o,i=e.value,u=1===e.state,a=u?t.ok:t.fail,c=t.resolve,f=t.reject,s=t.domain;try{a?(u||(2===e.rejection&&ci(e),e.rejection=1),!0===a?n=i:(s&&s.enter(),n=a(i),s&&(s.exit(),o=!0)),n===t.promise?f(new Yo("Promise-chain cycle")):(r=ni(n))?h(r,n,c,f):c(n)):f(i)}catch(t){s&&!o&&s.exit(),f(t)}},oi=function(t,e){t.notified||(t.notified=!0,jo((function(){for(var n,r=t.reactions;n=r.get();)ri(n,t);t.notified=!1,e&&!t.rejection&&ui(t)})))},ii=function(t,e,n){var r,o;ti?((r=$o.createEvent("Event")).promise=e,r.reason=n,r.initEvent(t,!1,!0),s.dispatchEvent(r)):r={promise:e,reason:n},!Go&&(o=s["on"+t])?o(r):t===ei&&function(t,e){try{1===arguments.length?console.error(t):console.error(t,e)}catch(t){}}("Unhandled promise rejection",n)},ui=function(t){h(_o,s,(function(){var e,n=t.facade,r=t.value;if(ai(t)&&(e=xo((function(){Pr?Jo.emit("unhandledRejection",r,n):ii(ei,n,r)})),t.rejection=Pr||ai(t)?2:1,e.error))throw e.value}))},ai=function(t){return 1!==t.rejection&&!t.parent},ci=function(t){h(_o,s,(function(){var e=t.facade;Pr?Jo.emit("rejectionHandled",e):ii("rejectionhandled",e,t.value)}))},fi=function(t,e,n){return function(r){t(e,r,n)}},si=function(t,e,n){t.done||(t.done=!0,n&&(t=n),t.value=e,t.state=2,oi(t,!0))},li=function(t,e,n){if(!t.done){t.done=!0,n&&(t=n);try{if(t.facade===e)throw new Yo("Promise can't be resolved itself");var r=ni(e);r?jo((function(){var n={done:!1};try{h(r,e,fi(li,n,t),fi(si,n,t))}catch(e){si(n,e,t)}})):(t.value=e,t.state=1,oi(t,!1))}catch(e){si({done:!1},e,t)}}};if(Bo&&(Xo=(Ko=function(t){Cr(this,Xo),et(t),h(To,this);var e=Vo(this);try{t(fi(li,e),fi(si,e))}catch(t){si(e,t)}}).prototype,(To=function(t){Ho(this,{type:Uo,done:!1,notified:!1,parent:!1,reactions:new po,rejection:!1,state:0,value:null})}).prototype=fe(Xo,"then",(function(t,e){var n=Vo(this),r=Qo(Mr(this,Ko));return n.parent=!0,r.ok=!L(t)||t,r.fail=L(e)&&e,r.domain=Pr?Jo.domain:void 0,0===n.state?n.reactions.add(r):jo((function(){ri(r,n)})),r.promise})),Po=function(){var t=new To,e=Vo(t);this.promise=t,this.resolve=fi(li,e),this.reject=fi(si,e)},zo.f=Qo=function(t){return t===Ko||undefined===t?new Po(t):Zo(t)},L(Io)&&qo!==Object.prototype)){Ro=qo.then,Wo||fe(qo,"then",(function(t,e){var n=this;return new Ko((function(t,e){h(Ro,n,t,e)})).then(t,e)}),{unsafe:!0});try{delete qo.constructor}catch(t){}Qn&&Qn(qo,Xo)}ze({global:!0,constructor:!0,wrap:!0,forced:Bo},{Promise:Ko}),qn(Ko,Uo,!1),Ao=F(Uo),p&&Ao&&!Ao[Rr]&&yr(Ao,Rr,{configurable:!0,get:function(){return this}});var pi=bt("iterator"),di=Array.prototype,vi=bt("iterator"),hi=function(t){if(!A(t))return nt(t,vi)||nt(t,"@@iterator")||Mn[He(t)]},yi=TypeError,gi=function(t,e,n){var r,o;kt(t);try{if(!(r=nt(t,"return"))){if("throw"===e)throw n;return n}r=h(r,t)}catch(t){o=!0,r=t}if("throw"===e)throw n;if(o)throw r;return kt(r),n},mi=TypeError,bi=function(t,e){this.stopped=t,this.result=e},wi=bi.prototype,Si=function(t,e,n){var r,o,i,u,a,c,f,s,l=n&&n.that,p=!(!n||!n.AS_ENTRIES),d=!(!n||!n.IS_RECORD),v=!(!n||!n.IS_ITERATOR),y=!(!n||!n.INTERRUPTED),g=Br(e,l),m=function(t){return r&&gi(r,"normal",t),new bi(!0,t)},b=function(t){return p?(kt(t),y?g(t[0],t[1],m):g(t[0],t[1])):y?g(t,m):g(t)};if(d)r=t.iterator;else if(v)r=t;else{if(!(o=hi(t)))throw new mi(Z(t)+" is not iterable");if(void 0!==(s=o)&&(Mn.Array===s||di[pi]===s)){for(i=0,u=me(t);u>i;i++)if((a=b(t[i]))&&z(wi,a))return a;return new bi(!1)}r=function(t,e){var n=arguments.length<2?hi(t):e;if(et(n))return kt(h(n,t));throw new yi(Z(t)+" is not iterable")}(t,o)}for(c=d?t.next:r.next;!(f=h(c,r)).done;){try{a=b(f.value)}catch(t){gi(r,"throw",t)}if("object"==typeof a&&a&&z(wi,a))return a}return new bi(!1)},Oi=bt("iterator"),Ei=!1;try{var ji=0,xi={next:function(){return{done:!!ji++}},return:function(){Ei=!0}};xi[Oi]=function(){return this},Array.from(xi,(function(){throw 2}))}catch(t){}var Ii=function(t,e){try{if(!e&&!Ei)return!1}catch(t){return!1}var n=!1;try{var r={};r[Oi]=function(){return{next:function(){return{done:n=!0}}}},t(r)}catch(t){}return n},Ti=Lo.CONSTRUCTOR||!Ii((function(t){Io.all(t).then(void 0,(function(){}))}));ze({target:"Promise",stat:!0,forced:Ti},{all:function(t){var e=this,n=zo.f(e),r=n.resolve,o=n.reject,i=xo((function(){var n=et(e.resolve),i=[],u=0,a=1;Si(t,(function(t){var c=u++,f=!1;a++,h(n,e,t).then((function(t){f||(f=!0,i[c]=t,--a||r(i))}),o)})),--a||r(i)}));return i.error&&o(i.value),n.promise}});var Pi=Lo.CONSTRUCTOR,Ri=Io&&Io.prototype;if(ze({target:"Promise",proto:!0,forced:Pi,real:!0},{catch:function(t){return this.then(void 0,t)}}),L(Io)){var Ai=F("Promise").prototype.catch;Ri.catch!==Ai&&fe(Ri,"catch",Ai,{unsafe:!0})}ze({target:"Promise",stat:!0,forced:Ti},{race:function(t){var e=this,n=zo.f(e),r=n.reject,o=xo((function(){var o=et(e.resolve);Si(t,(function(t){h(o,e,t).then(n.resolve,r)}))}));return o.error&&r(o.value),n.promise}}),ze({target:"Promise",stat:!0,forced:Lo.CONSTRUCTOR},{reject:function(t){var e=zo.f(this);return(0,e.reject)(t),e.promise}});var Ci=Lo.CONSTRUCTOR;F("Promise"),ze({target:"Promise",stat:!0,forced:Ci},{resolve:function(t){return function(t,e){if(kt(t),D(e)&&e.constructor===t)return e;var n=zo.f(t);return(0,n.resolve)(e),n.promise}(this,t)}});var Ni=String,ki=function(t){if("Symbol"===He(t))throw new TypeError("Cannot convert a Symbol value to a string");return Ni(t)},Mi=function(){var t=kt(this),e="";return t.hasIndices&&(e+="d"),t.global&&(e+="g"),t.ignoreCase&&(e+="i"),t.multiline&&(e+="m"),t.dotAll&&(e+="s"),t.unicode&&(e+="u"),t.unicodeSets&&(e+="v"),t.sticky&&(e+="y"),e},Li=RegExp.prototype,Di=Ht.PROPER,Fi="toString",zi=RegExp.prototype,_i=zi[Fi],Ui=l((function(){return"/a/b"!==_i.call({source:"a",flags:"b"})})),Bi=Di&&_i.name!==Fi;(Ui||Bi)&&fe(zi,Fi,(function(){var t=kt(this),e=ki(t.source),n=ki(function(t){var e=t.flags;return void 0!==e||"flags"in Li||lt(t,"flags")||!z(Li,t)?e:h(Mi,t)}(t));return"/"+e+"/"+n}),{unsafe:!0});var Gi=E("".charAt),Wi=E("".charCodeAt),Vi=E("".slice),Hi=function(t){return function(e,n){var r,o,i=ki(N(e)),u=de(n),a=i.length;return u<0||u>=a?t?"":void 0:(r=Wi(i,u))<55296||r>56319||u+1===a||(o=Wi(i,u+1))<56320||o>57343?t?Gi(i,u):r:t?Vi(i,u,u+2):o-56320+(r-55296<<10)+65536}},qi={codeAt:Hi(!1),charAt:Hi(!0)}.charAt,Ki="String Iterator",Xi=ae.set,Yi=ae.getterFor(Ki);cr(String,"String",(function(t){Xi(this,{type:Ki,string:ki(t),index:0})}),(function(){var t,e=Yi(this),n=e.string,r=e.index;return r>=n.length?fr(void 0,!0):(t=qi(n,r),e.index+=t.length,fr(t,!1))}));var $i=!l((function(){return Object.isExtensible(Object.preventExtensions({}))})),Ji=function(t,e,n){for(var r in e)fe(t,r,e[r],n);return t},Qi=xe.f,Zi="object"==typeof window&&window&&Object.getOwnPropertyNames?Object.getOwnPropertyNames(window):[],tu={f:function(t){return Zi&&"Window"===I(t)?function(t){try{return Qi(t)}catch(t){return nn(Zi)}}(t):Qi(k(t))}},eu=l((function(){if("function"==typeof ArrayBuffer){var t=new ArrayBuffer(8);Object.isExtensible(t)&&Object.defineProperty(t,"a",{value:8})}})),nu=Object.isExtensible,ru=l((function(){nu(1)}))||eu?function(t){return!!D(t)&&((!eu||"ArrayBuffer"!==I(t))&&(!nu||nu(t)))}:nu,ou=u((function(t){var e=Ut.f,n=!1,r=ht("meta"),o=0,i=function(t){e(t,r,{value:{objectID:"O"+o++,weakData:{}}})},u=t.exports={enable:function(){u.enable=function(){},n=!0;var t=xe.f,e=E([].splice),o={};o[r]=1,t(o).length&&(xe.f=function(n){for(var o=t(n),i=0,u=o.length;i<u;i++)if(o[i]===r){e(o,i,1);break}return o},ze({target:"Object",stat:!0,forced:!0},{getOwnPropertyNames:tu.f}))},fastKey:function(t,e){if(!D(t))return"symbol"==typeof t?t:("string"==typeof t?"S":"P")+t;if(!lt(t,r)){if(!ru(t))return"F";if(!e)return"E";i(t)}return t[r].objectID},getWeakData:function(t,e){if(!lt(t,r)){if(!ru(t))return!0;if(!e)return!1;i(t)}return t[r].weakData},onFreeze:function(t){return $i&&n&&ru(t)&&!lt(t,r)&&i(t),t}};ee[r]=!0})),iu=bt("species"),uu=Array,au=function(t,e){return new(function(t){var e;return _e(t)&&(e=t.constructor,(tn(e)&&(e===uu||_e(e.prototype))||D(e)&&null===(e=e[iu]))&&(e=void 0)),void 0===e?uu:e}(t))(0===e?0:e)},cu=E([].push),fu=function(t){var e=1===t,n=2===t,r=3===t,o=4===t,i=6===t,u=7===t,a=5===t||i;return function(c,f,s,l){for(var p,d,v=ft(c),h=R(v),y=me(h),g=Br(f,s),m=0,b=l||au,w=e?b(c,y):n||u?b(c,0):void 0;y>m;m++)if((a||m in h)&&(d=g(p=h[m],m,v),t))if(e)w[m]=d;else if(d)switch(t){case 3:return!0;case 5:return p;case 6:return m;case 2:cu(w,p)}else switch(t){case 4:return!1;case 7:cu(w,p)}return i?-1:r||o?o:w}},su={forEach:fu(0),map:fu(1),filter:fu(2),some:fu(3),every:fu(4),find:fu(5),findIndex:fu(6),filterReject:fu(7)},lu=ou.getWeakData,pu=ae.set,du=ae.getterFor,vu=su.find,hu=su.findIndex,yu=E([].splice),gu=0,mu=function(t){return t.frozen||(t.frozen=new bu)},bu=function(){this.entries=[]},wu=function(t,e){return vu(t.entries,(function(t){return t[0]===e}))};bu.prototype={get:function(t){var e=wu(this,t);if(e)return e[1]},has:function(t){return!!wu(this,t)},set:function(t,e){var n=wu(this,t);n?n[1]=e:this.entries.push([t,e])},delete:function(t){var e=hu(this.entries,(function(e){return e[0]===t}));return~e&&yu(this.entries,e,1),!!~e}};var Su,Ou={getConstructor:function(t,e,n,r){var o=t((function(t,o){Cr(t,i),pu(t,{type:e,id:gu++,frozen:null}),A(o)||Si(o,t[r],{that:t,AS_ENTRIES:n})})),i=o.prototype,u=du(e),a=function(t,e,n){var r=u(t),o=lu(kt(e),!0);return!0===o?mu(r).set(e,n):o[r.id]=n,t};return Ji(i,{delete:function(t){var e=u(this);if(!D(t))return!1;var n=lu(t);return!0===n?mu(e).delete(t):n&<(n,e.id)&&delete n[e.id]},has:function(t){var e=u(this);if(!D(t))return!1;var n=lu(t);return!0===n?mu(e).has(t):n&<(n,e.id)}}),Ji(i,n?{get:function(t){var e=u(this);if(D(t)){var n=lu(t);if(!0===n)return mu(e).get(t);if(n)return n[e.id]}},set:function(t,e){return a(this,t,e)}}:{add:function(t){return a(this,t,!0)}}),o}},Eu=ae.enforce,ju=Object,xu=Array.isArray,Iu=ju.isExtensible,Tu=ju.isFrozen,Pu=ju.isSealed,Ru=ju.freeze,Au=ju.seal,Cu=!s.ActiveXObject&&"ActiveXObject"in s,Nu=function(t){return function(){return t(this,arguments.length?arguments[0]:void 0)}},ku=function(t,e,n){var r=-1!==t.indexOf("Map"),o=-1!==t.indexOf("Weak"),i=r?"set":"add",u=s[t],a=u&&u.prototype,c=u,f={},p=function(t){var e=E(a[t]);fe(a,t,"add"===t?function(t){return e(this,0===t?0:t),this}:"delete"===t?function(t){return!(o&&!D(t))&&e(this,0===t?0:t)}:"get"===t?function(t){return o&&!D(t)?void 0:e(this,0===t?0:t)}:"has"===t?function(t){return!(o&&!D(t))&&e(this,0===t?0:t)}:function(t,n){return e(this,0===t?0:t,n),this})};if(De(t,!L(u)||!(o||a.forEach&&!l((function(){(new u).entries().next()})))))c=n.getConstructor(e,t,r,i),ou.enable();else if(De(t,!0)){var d=new c,v=d[i](o?{}:-0,1)!==d,h=l((function(){d.has(1)})),y=Ii((function(t){new u(t)})),g=!o&&l((function(){for(var t=new u,e=5;e--;)t[i](e,e);return!t.has(-0)}));y||((c=e((function(t,e){Cr(t,a);var n=function(t,e,n){var r,o;return Qn&&L(r=e.constructor)&&r!==n&&D(o=r.prototype)&&o!==n.prototype&&Qn(t,o),t}(new u,t,c);return A(e)||Si(e,n[i],{that:n,AS_ENTRIES:r}),n}))).prototype=a,a.constructor=c),(h||g)&&(p("delete"),p("has"),r&&p("get")),(g||v)&&p(i),o&&a.clear&&delete a.clear}return f[t]=c,ze({global:!0,constructor:!0,forced:c!==u},f),qn(c,t),o||n.setStrong(c,t,r),c}("WeakMap",Nu,Ou),Mu=ku.prototype,Lu=E(Mu.set);if(Qt)if(Cu){Su=Ou.getConstructor(Nu,"WeakMap",!0),ou.enable();var Du=E(Mu.delete),Fu=E(Mu.has),zu=E(Mu.get);Ji(Mu,{delete:function(t){if(D(t)&&!Iu(t)){var e=Eu(this);return e.frozen||(e.frozen=new Su),Du(this,t)||e.frozen.delete(t)}return Du(this,t)},has:function(t){if(D(t)&&!Iu(t)){var e=Eu(this);return e.frozen||(e.frozen=new Su),Fu(this,t)||e.frozen.has(t)}return Fu(this,t)},get:function(t){if(D(t)&&!Iu(t)){var e=Eu(this);return e.frozen||(e.frozen=new Su),Fu(this,t)?zu(this,t):e.frozen.get(t)}return zu(this,t)},set:function(t,e){if(D(t)&&!Iu(t)){var n=Eu(this);n.frozen||(n.frozen=new Su),Fu(this,t)?Lu(this,t,e):n.frozen.set(t,e)}else Lu(this,t,e);return this}})}else $i&&l((function(){var t=Ru([]);return Lu(new ku,t,1),!Tu(t)}))&&Ji(Mu,{set:function(t,e){var n;return xu(t)&&(Tu(t)?n=Ru:Pu(t)&&(n=Au)),Lu(this,t,e),n&&n(t),this}});var _u={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},Uu=It("span").classList,Bu=Uu&&Uu.constructor&&Uu.constructor.prototype,Gu=Bu===Object.prototype?void 0:Bu,Wu=function(t,e){var n=[][t];return!!n&&l((function(){n.call(null,e||function(){return 1},1)}))},Vu=su.forEach,Hu=Wu("forEach")?[].forEach:function(t){return Vu(this,t,arguments.length>1?arguments[1]:void 0)},qu=function(t){if(t&&t.forEach!==Hu)try{Bt(t,"forEach",Hu)}catch(e){t.forEach=Hu}};for(var Ku in _u)_u[Ku]&&qu(s[Ku]&&s[Ku].prototype);qu(Gu);var Xu=bt("iterator"),Yu=vr.values,$u=function(t,e){if(t){if(t[Xu]!==Yu)try{Bt(t,Xu,Yu)}catch(e){t[Xu]=Yu}if(qn(t,e,!0),_u[e])for(var n in vr)if(t[n]!==vr[n])try{Bt(t,n,vr[n])}catch(e){t[n]=vr[n]}}};for(var Ju in _u)$u(s[Ju]&&s[Ju].prototype,Ju);$u(Gu,"DOMTokenList");var Qu=new WeakMap;function Zu(t){return t.getMenuConfig("uploadImage")}function ta(t,n){return sn(this,void 0,void 0,(function(){return ln(this,(function(r){return[2,new Promise((function(r){var o=new FileReader;o.readAsDataURL(n),o.onload=function(){var i=o.result;if(i){var u=i.toString(),a=0===u.indexOf("data:image")?"":u;e.insertImageNode(t,u,n.name,a),r("ok")}}}))]}))}))}function ea(n,r){return sn(this,void 0,void 0,(function(){var o,i,u,a;return ln(this,(function(c){switch(c.label){case 0:return o=function(n){var r=Qu.get(n);if(null!=r)return r;var o=Zu(n),i=o.onSuccess,u=o.onProgress,a=o.onFailed,c=o.customInsert,f=o.onError;return r=t.createUploader(fn(fn({},o),{onProgress:function(t){n.showProgressBar(t),u&&u(t)},onSuccess:function(t,r){if(c)return c(r,(function(t,r,o){return e.insertImageNode(n,t,r,o)})),void i(t,r);var o=r.errno,u=void 0===o?1:o,f=r.data,s=void 0===f?{}:f;if(0===u){if(Array.isArray(s))s.forEach((function(t){var r=t.url,o=void 0===r?"":r,i=t.alt,u=void 0===i?"":i,a=t.href,c=void 0===a?"":a;e.insertImageNode(n,o,u,c)}));else{var l=s.url,p=void 0===l?"":l,d=s.alt,v=void 0===d?"":d,h=s.href,y=void 0===h?"":h;e.insertImageNode(n,p,v,y)}i(t,r)}else a(t,r)},onError:function(t,e,n){f(t,e,n)}})),Qu.set(n,r),r}(n),i=r.name,u=r.type,a=r.size,o.addFile({name:i,type:u,size:a,data:r}),[4,o.upload()];case 1:return c.sent(),[2]}}))}))}function na(t,n){var r,o;return sn(this,void 0,void 0,(function(){var i,u,a,c,f,s,l,p,d;return ln(this,(function(v){switch(v.label){case 0:if(null==n)return[2];i=Array.prototype.slice.call(n),u=Zu(t),a=u.customUpload,c=u.base64LimitSize,v.label=1;case 1:v.trys.push([1,11,12,17]),f=dn(i),v.label=2;case 2:return[4,f.next()];case 3:return(s=v.sent()).done?[3,10]:(l=s.value,p=l.size,c&&p<=c?[4,ta(t,l)]:[3,5]);case 4:return v.sent(),[3,9];case 5:return a?[4,a(l,(function(n,r,o){return e.insertImageNode(t,n,r,o)}))]:[3,7];case 6:return v.sent(),[3,9];case 7:return[4,ea(t,l)];case 8:v.sent(),v.label=9;case 9:return[3,2];case 10:return[3,17];case 11:return d=v.sent(),r={error:d},[3,17];case 12:return v.trys.push([12,,15,16]),s&&!s.done&&(o=f.return)?[4,o.call(f)]:[3,14];case 13:v.sent(),v.label=14;case 14:return[3,16];case 15:if(r)throw r.error;return[7];case 16:return[7];case 17:return[2]}}))}))}var ra=E([].join),oa=R!==Object||!Wu("join",",");ze({target:"Array",proto:!0,forced:oa},{join:function(t){return ra(k(this),void 0===t?",":t)}});var ia,ua,aa=s.RegExp,ca=l((function(){var t=aa("a","y");return t.lastIndex=2,null!==t.exec("abcd")})),fa=ca||l((function(){return!aa("a","y").sticky})),sa={BROKEN_CARET:ca||l((function(){var t=aa("^r","gy");return t.lastIndex=2,null!==t.exec("str")})),MISSED_STICKY:fa,UNSUPPORTED_Y:ca},la=s.RegExp,pa=l((function(){var t=la(".","s");return!(t.dotAll&&t.test("\n")&&"s"===t.flags)})),da=s.RegExp,va=l((function(){var t=da("(?<a>b)","g");return"b"!==t.exec("b").groups.a||"bc"!=="b".replace(t,"$<a>c")})),ha=ae.get,ya=at("native-string-replace",String.prototype.replace),ga=RegExp.prototype.exec,ma=ga,ba=E("".charAt),wa=E("".indexOf),Sa=E("".replace),Oa=E("".slice),Ea=(ua=/b*/g,h(ga,ia=/a/,"a"),h(ga,ua,"a"),0!==ia.lastIndex||0!==ua.lastIndex),ja=sa.BROKEN_CARET,xa=void 0!==/()??/.exec("")[1];(Ea||xa||ja||pa||va)&&(ma=function(t){var e,n,r,o,i,u,a,c=this,f=ha(c),s=ki(t),l=f.raw;if(l)return l.lastIndex=c.lastIndex,e=h(ma,l,s),c.lastIndex=l.lastIndex,e;var p=f.groups,d=ja&&c.sticky,v=h(Mi,c),y=c.source,g=0,m=s;if(d&&(v=Sa(v,"y",""),-1===wa(v,"g")&&(v+="g"),m=Oa(s,c.lastIndex),c.lastIndex>0&&(!c.multiline||c.multiline&&"\n"!==ba(s,c.lastIndex-1))&&(y="(?: "+y+")",m=" "+m,g++),n=new RegExp("^(?:"+y+")",v)),xa&&(n=new RegExp("^"+y+"$(?!\\s)",v)),Ea&&(r=c.lastIndex),o=h(ga,d?n:c,m),d?o?(o.input=Oa(o.input,g),o[0]=Oa(o[0],g),o.index=c.lastIndex,c.lastIndex+=o[0].length):c.lastIndex=0:Ea&&o&&(c.lastIndex=c.global?o.index+o[0].length:r),xa&&o&&o.length>1&&h(ya,o[0],n,(function(){for(i=1;i<arguments.length-2;i++)void 0===arguments[i]&&(o[i]=void 0)})),o&&p)for(o.groups=u=In(null),i=0;i<p.length;i++)u[(a=p[i])[0]]=o[a[1]];return o});ze({target:"RegExp",proto:!0,forced:/./.exec!==ma},{exec:ma});n.append&&(o.default.fn.append=n.append),n.on&&(o.default.fn.on=n.on),n.remove&&(o.default.fn.remove=n.remove),n.val&&(o.default.fn.val=n.val),n.click&&(o.default.fn.click=n.click),n.hide&&(o.default.fn.hide=n.hide);var Ia=function(){function n(){this.title=t.t("uploadImgModule.uploadImage"),this.iconSvg='<svg viewBox="0 0 1024 1024"><path d="M828.708571 585.045333a48.761905 48.761905 0 0 0-48.737523 48.761905v18.529524l-72.143238-72.167619a135.972571 135.972571 0 0 0-191.585524 0l-34.133334 34.133333-120.880762-120.953905a138.898286 138.898286 0 0 0-191.585523 0l-72.167619 72.167619V292.400762a48.786286 48.786286 0 0 1 48.761904-48.761905h341.23581a48.737524 48.737524 0 0 0 34.474667-83.285333 48.737524 48.737524 0 0 0-34.474667-14.287238H146.236952A146.212571 146.212571 0 0 0 0 292.400762v585.289143A146.358857 146.358857 0 0 0 146.236952 1024h584.996572a146.212571 146.212571 0 0 0 146.236952-146.310095V633.807238a48.786286 48.786286 0 0 0-48.761905-48.761905zM146.261333 926.45181a48.737524 48.737524 0 0 1-48.761904-48.761905v-174.128762l141.409523-141.458286a38.497524 38.497524 0 0 1 53.126096 0l154.526476 154.624 209.627428 209.724953H146.236952z m633.734096-48.761905c-0.073143 9.337905-3.145143 18.383238-8.777143 25.843809l-219.843048-220.94019 34.133333-34.133334a37.546667 37.546667 0 0 1 53.613715 0l140.873143 141.897143V877.714286zM1009.615238 160.231619L863.329524 13.897143a48.737524 48.737524 0 0 0-16.091429-10.24c-11.849143-4.87619-25.161143-4.87619-37.059047 0a48.761905 48.761905 0 0 0-16.067048 10.24l-146.236952 146.334476a49.005714 49.005714 0 0 0 69.217523 69.241905l62.902858-63.390476v272.627809a48.761905 48.761905 0 1 0 97.475047 0V166.083048l62.902857 63.390476a48.737524 48.737524 0 0 0 69.217524 0 48.761905 48.761905 0 0 0 0-69.241905z"></path></svg>',this.tag="button"}return n.prototype.getValue=function(t){return""},n.prototype.isActive=function(t){return!1},n.prototype.isDisabled=function(t){return e.isInsertImageMenuDisabled(t)},n.prototype.getMenuConfig=function(t){return t.getMenuConfig("uploadImage")},n.prototype.exec=function(t,n){var r=this.getMenuConfig(t),i=r.allowedFileTypes,u=void 0===i?[]:i,a=r.customBrowseAndUpload;if(a)a((function(n,r,o){return e.insertImageNode(t,n,r,o)}));else{var c="";u.length>0&&(c='accept="'+u.join(", ")+'"');var f=o.default("body"),s=o.default('<input type="file" '+c+" multiple/>");s.hide(),f.append(s),s.click(),s.on("change",(function(){var e=s[0].files;na(t,e)}))}},n}();var Ta={menus:[{key:"uploadImage",factory:function(){return new Ia},config:{server:"",fieldName:"wangeditor-uploaded-image",maxFileSize:2097152,maxNumberOfFiles:100,allowedFileTypes:["image/*"],meta:{},metaWithUrl:!1,withCredentials:!1,timeout:1e4,onBeforeUpload:function(t){return t},onProgress:function(t){},onSuccess:function(t,e){},onFailed:function(t,e){console.error("'"+t.name+"' upload failed",e)},onError:function(t,e,n){console.error("'"+t.name+"' upload error",n)},base64LimitSize:0}}],editorPlugin:function(t){var n=t.insertData,r=t;return r.insertData=function(o){if(e.isInsertImageMenuDisabled(r))n(o);else if(o.getData("text/plain"))n(o);else{var i=o.files;if(i.length<=0)n(o);else Array.prototype.slice.call(i).some((function(t){return"image"===function(t,e){var n="function"==typeof Symbol&&t[Symbol.iterator];if(!n)return t;var r,o,i=n.call(t),u=[];try{for(;(void 0===e||e-- >0)&&!(r=i.next()).done;)u.push(r.value)}catch(t){o={error:t}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return u}(t.type.split("/"),1)[0]}))?na(t,i):n(o)}},r}};return Ta}));
|
|
2
2
|
//# sourceMappingURL=index.js.map
|