|
|
|
|
import{d as uP,r as wg,s as sP,o as lP,l as i$,g as J3,c as Q3,n as a$,p as u$,_ as s$,q as l$,v as c$,b as gx,e as f$,f as vx}from"./index-93dfb385.js";var se=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function d$(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}function as(t){var e={exports:{}};return t(e,e.exports),e.exports}var mi,z0,Bh=function(t){return t&&t.Math==Math&&t},kt=Bh(typeof globalThis=="object"&&globalThis)||Bh(typeof window=="object"&&window)||Bh(typeof self=="object"&&self)||Bh(typeof se=="object"&&se)||function(){return this}()||Function("return this")(),t5=Function.prototype,mx=t5.apply,p$=t5.bind,yx=t5.call,cP=typeof Reflect=="object"&&Reflect.apply||(p$?yx.bind(mx):function(){return yx.apply(mx,arguments)}),fP=Function.prototype,g4=fP.bind,v4=fP.call,h$=g4&&g4.bind(v4),ge=g4?function(t){return t&&h$(v4,t)}:function(t){return t&&function(){return v4.apply(t,arguments)}},sn=function(t){return typeof t=="function"},Gn=function(t){try{return!!t()}catch{return!0}},Hn=!Gn(function(){return Object.defineProperty({},1,{get:function(){return 7}})[1]!=7}),Oc=Function.prototype.call,zn=Oc.bind?Oc.bind(Oc):function(){return Oc.apply(Oc,arguments)},bx={}.propertyIsEnumerable,wx=Object.getOwnPropertyDescriptor,g$=wx&&!bx.call({1:2},1)?function(t){var e=wx(this,t);return!!e&&e.enumerable}:bx,e5={f:g$},Yr=function(t,e){return{enumerable:!(1&t),configurable:!(2&t),writable:!(4&t),value:e}},v$=ge({}.toString),m$=ge("".slice),Eu=function(t){return m$(v$(t),8,-1)},Hm=kt.Object,y$=ge("".split),dP=Gn(function(){return!Hm("z").propertyIsEnumerable(0)})?function(t){return Eu(t)=="String"?y$(t,""):Hm(t)}:Hm,b$=kt.TypeError,n5=function(t){if(t==null)throw b$("Can't call method on "+t);return t},Po=function(t){return dP(n5(t))},tr=function(t){return typeof t=="object"?t!==null:sn(t)},Qn={},Ex=function(t){return sn(t)?t:void 0},rc=function(t,e){return arguments.length<2?Ex(Qn[t])||Ex(kt[t]):Qn[t]&&Qn[t][e]||kt[t]&&kt[t][e]},Td=ge({}.isPrototypeOf),Vm=rc("navigator","userAgent")||"",Dx=kt.process,Cx=kt.Deno,xx=Dx&&Dx.versions||Cx&&Cx.version,Sx=xx&&xx.v8;Sx&&(z0=(mi=Sx.split("."))[0]>0&&mi[0]<4?1:+(mi[0]+mi[1])),!z0&&Vm&&(!(mi=Vm.match(/Edge\/(\d+)/))||mi[1]>=74)&&(mi=Vm.match(/Chrome\/(\d+)/))&&(z0=+mi[1]);var Fh,Eg=z0,po=!!Object.getOwnPropertySymbols&&!Gn(function(){var t=Symbol();return!String(t)||!(Object(t)instanceof Symbol)||!Symbol.sham&&Eg&&Eg<41}),r5=po&&!Symbol.sham&&typeof Symbol.iterator=="symbol",w$=kt.Object,pl=r5?function(t){return typeof t=="symbol"}:function(t){var e=rc("Symbol");return sn(e)&&Td(e.prototype,w$(t))},E$=kt.String,m4=function(t){try{return E$(t)}catch{return"Object"}},D$=kt.TypeError,o5=function(t){if(sn(t))return t;throw D$(m4(t)+" is not a function")},Dg=function(t,e){var n=t[e];return n==null?void 0:o5(n)},C$=kt.TypeError,x$=Object.defineProperty,ta=kt["__core-js_shared__"]||function(t,e){try{x$(kt,t,{value:e,configurable:!0,writable:!0})}catch{kt[t]=e}return e}("__core-js_shared__",{}),us=as(function(t){(t.exports=function(e,n){return ta[e]||(ta[e]=n!==void 0?n:{})})("versions",[]).push({version:"3.19.3",mode:"pure",copyright:"© 2021 Denis Pushkarev (zloirock.ru)"})}),S$=kt.Object,Bp=function(t){return S$(n5(t))},A$=ge({}.hasOwnProperty),Vt=Object.hasOwn||function(t,e){return A$(Bp(t),e)},O$=0,k$=Math.random(),B$=ge(1 .toString),Cg=function(t){return"Symbol("+(t===void 0?"":t)+")_"+B$(++O$+k$,36)},kc=us("wks"),Du=kt.Symbol,Ax=Du&&Du.for,F$=r5?Du:Du&&Du.withoutSetter||Cg,Bn=function(t){if(!Vt(kc,t)||!po&&typeof kc[t]!="string"){var e="Symbol."+t;po&&Vt(Du,t)?kc[t]=Du[t]:kc[t]=r5&&Ax?Ax(e):F$(e)}return kc[t]},T$=kt.TypeError,_$=Bn("toPrimitive"),P$=function(t,e){if(!tr(t)||pl(t))return t;var n,r=Dg(t,_$);if(r){if(e===void 0&&(e="default"),n=zn(r,t,e),!tr(n)||pl(n))return n;throw T$("Can't convert object to primitive value")}return e===void 0&&(e="number"),function(o,i){var a,u;if(i==="string"&&sn(a=o.toString)&&!tr(u=zn(a,o))||sn(a=o.valueOf)&&!tr(u=zn(a,o))||i!=="string"&&sn(a=o.toStrin
|
|
|
|
|
`),e),`
|
|
|
|
|
`);return t},bH=function(t,e){tr(e)&&"cause"in e&&_n(t,"cause",e.cause)},ti={},wH=Bn("iterator"),EH=Array.prototype,wP={};wP[Bn("toStringTag")]="z";var l5=String(wP)==="[object z]",DH=Bn("toStringTag"),CH=kt.Object,xH=Eu(function(){return arguments}())=="Arguments",Pp=l5?Eu:function(t){var e,n,r;return t===void 0?"Undefined":t===null?"Null":typeof(n=function(o,i){try{return o[i]}catch{}}(e=CH(t),DH))=="string"?n:xH?Eu(e):(r=Eu(e))=="Object"&&sn(e.callee)?"Arguments":r},SH=Bn("iterator"),Nx=function(t){if(t!=null)return Dg(t,SH)||Dg(t,"@@iterator")||ti[Pp(t)]},AH=kt.TypeError,Ix=function(t,e,n){var r,o;ar(t);try{if(!(r=Dg(t,"return"))){if(e==="throw")throw n;return n}r=zn(r,t)}catch(i){o=!0,r=i}if(e==="throw")throw n;if(o)throw r;return ar(r),n},OH=kt.TypeError,V0=function(t,e){this.stopped=t,this.result=e},Lx=V0.prototype,kH=function(t,e,n){var r,o,i,a,u,s,l,c=n&&n.that,f=!(!n||!n.AS_ENTRIES),p=!(!n||!n.IS_ITERATOR),d=!(!n||!n.INTERRUPTED),v=i5(e,c),g=function(y){return r&&Ix(r,"normal",y),new V0(!0,y)},m=function(y){return f?(ar(y),d?v(y[0],y[1],g):v(y[0],y[1])):d?v(y,g):v(y)};if(p)r=t;else{if(!(o=Nx(t)))throw OH(m4(t)+" is not iterable");if(function(y){return y!==void 0&&(ti.Array===y||EH[wH]===y)}(o)){for(i=0,a=Tp(t);a>i;i++)if((u=m(t[i]))&&Td(Lx,u))return u;return new V0(!1)}r=function(y,h){var b=arguments.length<2?Nx(y):h;if(o5(b))return ar(zn(b,y));throw AH(m4(y)+" is not iterable")}(t,o)}for(s=r.next;!(l=zn(s,r)).done;){try{u=m(l.value)}catch(y){Ix(r,"throw",y)}if(typeof u=="object"&&u&&Td(Lx,u))return u}return new V0(!1)},BH=kt.String,_d=function(t){if(Pp(t)==="Symbol")throw TypeError("Cannot convert a Symbol value to a string");return BH(t)},FH=function(t,e){return t===void 0?arguments.length<2?"":e:_d(t)},TH=!Gn(function(){var t=Error("a");return!("stack"in t)||(Object.defineProperty(t,"stack",Yr(1,7)),t.stack!==7)}),_H=Bn("toStringTag"),Og=kt.Error,PH=[].push,Pd=function(t,e){var n,r=arguments.length>2?arguments[2]:void 0,o=Td(Wm,this);Sg?n=Sg(new Og(void 0),o?xg(this):Wm):(n=o?this:oi(Wm),_n(n,_H,"Error")),_n(n,"message",FH(e,"")),TH&&_n(n,"stack",yH(n.stack,1)),bH(n,r);var i=[];return kH(t,PH,{that:i}),_n(n,"errors",i),n};Sg?Sg(Pd,Og):function(t,e){for(var n=sH(e),r=ja.f,o=P1.f,i=0;i<n.length;i++){var a=n[i];Vt(t,a)||r(t,a,o(e,a))}}(Pd,Og);var Wm=Pd.prototype=oi(Og.prototype,{constructor:Yr(1,Pd),message:Yr(1,""),name:Yr(1,"AggregateError")});qo({global:!0},{AggregateError:Pd});var jH=ge(Function.toString);sn(ta.inspectSource)||(ta.inspectSource=function(t){return jH(t)});var kg,od,Bg,EP=ta.inspectSource,Rx=kt.WeakMap,NH=sn(Rx)&&/native code/.test(EP(Rx)),C4=kt.TypeError,IH=kt.WeakMap;if(NH||ta.state){var Ga=ta.state||(ta.state=new IH),LH=ge(Ga.get),Mx=ge(Ga.has),RH=ge(Ga.set);kg=function(t,e){if(Mx(Ga,t))throw new C4("Object already initialized");return e.facade=t,RH(Ga,t,e),e},od=function(t){return LH(Ga,t)||{}},Bg=function(t){return Mx(Ga,t)}}else{var Cs=j1("state");_p[Cs]=!0,kg=function(t,e){if(Vt(t,Cs))throw new C4("Object already initialized");return e.facade=t,_n(t,Cs,e),e},od=function(t){return Vt(t,Cs)?t[Cs]:{}},Bg=function(t){return Vt(t,Cs)}}var Ki,zx,$x,ic={set:kg,get:od,has:Bg,enforce:function(t){return Bg(t)?od(t):kg(t,{})},getterFor:function(t){return function(e){var n;if(!tr(e)||(n=od(e)).type!==t)throw C4("Incompatible receiver, "+t+" required");return n}}},DP=Function.prototype,MH=Hn&&Object.getOwnPropertyDescriptor,Gm=Vt(DP,"name"),zH={EXISTS:Gm,PROPER:Gm&&(function(){}).name==="something",CONFIGURABLE:Gm&&(!Hn||Hn&&MH(DP,"name").configurable)},Al=function(t,e,n,r){r&&r.enumerable?t[e]=n:_n(t,e,n)},x4=Bn("iterator"),CP=!1;[].keys&&("next"in($x=[].keys())?(zx=xg(xg($x)))!==Object.prototype&&(Ki=zx):CP=!0);var $H=Ki==null||Gn(function(){var t={};return Ki[x4].call(t)!==t});Ki=$H?{}:oi(Ki),sn(Ki[x4])||Al(Ki,x4,function(){return this});var xP={IteratorPrototype:Ki,BUGGY_SAFARI_ITERATORS:CP},HH=l5?{}.toString:function(){return"[object "+Pp(this)+"]"},VH=ja.f,Hx=Bn("toStringTag"),Fg=function(t,e,n,r){if(t){var o=n?t:t.prototype;Vt(o,Hx)||VH(o,Hx,{configurable:!0,value:e}),r&&!l5&&_n(o,"toString
|
|
|
|
|
`)&&t.flags==="s")}),gU=Et.RegExp,vU=cn(function(){var t=gU("(?<a>b)","g");return t.exec("b").groups.a!=="b"||"b".replace(t,"$<a>c")!=="bc"}),mU=Wu.get,yU=p5("native-string-replace",String.prototype.replace),Ng=RegExp.prototype.exec,P4=Ng,bU=ie("".charAt),wU=ie("".indexOf),EU=ie("".replace),ey=ie("".slice),ny=(ty=/b*/g,un(Ng,lS=/a/,"a"),un(Ng,ty,"a"),lS.lastIndex!==0||ty.lastIndex!==0),cS=lU.BROKEN_CARET,ry=/()??/.exec("")[1]!==void 0;(ny||ry||cS||hU||vU)&&(P4=function(t){var e,n,r,o,i,a,u,s=this,l=mU(s),c=Su(t),f=l.raw;if(f)return f.lastIndex=s.lastIndex,e=un(P4,f,c),s.lastIndex=f.lastIndex,e;var p=l.groups,d=cS&&s.sticky,v=un(aU,s),g=s.source,m=0,y=c;if(d&&(v=EU(v,"y",""),wU(v,"g")===-1&&(v+="g"),y=ey(c,s.lastIndex),s.lastIndex>0&&(!s.multiline||s.multiline&&bU(c,s.lastIndex-1)!==`
|
|
|
|
|
`)&&(g="(?: "+g+")",y=" "+y,m++),n=new RegExp("^(?:"+g+")",v)),ry&&(n=new RegExp("^"+g+"$(?!\\s)",v)),ny&&(r=s.lastIndex),o=un(Ng,d?n:s,y),d?o?(o.input=ey(o.input,m),o[0]=ey(o[0],m),o.index=s.lastIndex,s.lastIndex+=o[0].length):s.lastIndex=0:ny&&o&&(s.lastIndex=s.global?o.index+o[0].length:r),ry&&o&&o.length>1&&un(yU,o[0],n,function(){for(i=1;i<arguments.length-2;i++)arguments[i]===void 0&&(o[i]=void 0)}),o&&p)for(o.groups=a=Lp(null),i=0;i<p.length;i++)a[(u=p[i])[0]]=o[u[1]];return o});var Ig=P4;Ip({target:"RegExp",proto:!0,forced:/./.exec!==Ig},{exec:Ig});var DU=Nn("species"),oy=RegExp.prototype,CU=ie("".charAt),fS=ie("".charCodeAt),xU=ie("".slice),dS=function(t){return function(e,n){var r,o,i=Su(N1(e)),a=D5(n),u=i.length;return a<0||a>=u?t?"":void 0:(r=fS(i,a))<55296||r>56319||a+1===u||(o=fS(i,a+1))<56320||o>57343?t?CU(i,a):r:t?xU(i,a,a+2):o-56320+(r-55296<<10)+65536}},LP={codeAt:dS(!1),charAt:dS(!0)},SU=LP.charAt,AU=function(t,e,n){return e+(n?SU(t,e).length:1)},OU=Et.TypeError,pS=function(t,e){var n=t.exec;if(Ge(n)){var r=un(n,t,e);return r!==null&&ur(r),r}if(Cu(t)==="RegExp")return un(Ig,t,e);throw OU("RegExp#exec called on incompatible receiver")};(function(t,e,n,r){var o=Nn(t),i=!cn(function(){var l={};return l[o]=function(){return 7},""[t](l)!=7}),a=i&&!cn(function(){var l=!1,c=/a/;return t==="split"&&((c={}).constructor={},c.constructor[DU]=function(){return c},c.flags="",c[o]=/./[o]),c.exec=function(){return l=!0,null},c[o](""),!l});if(!i||!a||n){var u=ie(/./[o]),s=e(o,""[t],function(l,c,f,p,d){var v=ie(l),g=c.exec;return g===Ig||g===oy.exec?i&&!d?{done:!0,value:u(c,f,p)}:{done:!0,value:v(f,c,p)}:{done:!1}});ra(String.prototype,t,s[0]),ra(oy,o,s[1])}r&&jn(oy[o],"sham",!0)})("match",function(t,e,n){return[function(r){var o=N1(this),i=r==null?void 0:jd(r,t);return i?un(i,r,o):new RegExp(r)[t](Su(o))},function(r){var o=ur(this),i=Su(r),a=n(e,o,i);if(a.done)return a.value;if(!o.global)return pS(o,i);var u=o.unicode;o.lastIndex=0;for(var s,l=[],c=0;(s=pS(o,i))!==null;){var f=Su(s[0]);l[c]=f,f===""&&(o.lastIndex=AU(i,TP(o.lastIndex),u)),c++}return c===0?null:l}]}),Ip({global:!0},{globalThis:Et});var kU=!cn(function(){function t(){}return t.prototype.constructor=null,Object.getPrototypeOf(new t)!==t.prototype}),hS=b5("IE_PROTO"),j4=Et.Object,BU=j4.prototype,Nd=kU?j4.getPrototypeOf:function(t){var e=h5(t);if(Vn(e,hS))return e[hS];var n=e.constructor;return Ge(n)&&e instanceof n?n.prototype:e instanceof j4?BU:null},FU=Et.String,TU=Et.TypeError,Ol=Object.setPrototypeOf||("__proto__"in{}?function(){var t,e=!1,n={};try{(t=ie(Object.getOwnPropertyDescriptor(Object.prototype,"__proto__").set))(n,[]),e=n instanceof Array}catch{}return function(r,o){return ur(r),function(i){if(typeof i=="object"||Ge(i))return i;throw TU("Can't set "+FU(i)+" as a prototype")}(o),e?t(r,o):r.__proto__=o,r}}():void 0),_U=Et.Array,PU=Math.max,jU=ie("".replace),NU=ie("".split),IU=ie([].join),N4=String(Error("zxcasd").stack),RP=/\n\s*at [^:]*:[^\n]*/,LU=RP.test(N4),RU=/@[^\n]*\n/.test(N4)&&!/zxcasd/.test(N4),MU=function(t,e){if(typeof t!="string")return t;if(LU)for(;e--;)t=jU(t,RP,"");else if(RU)return IU(function(n,r,o){for(var i,a,u,s,l=I1(n),c=_4(r,l),f=_4(o===void 0?l:o,l),p=_U(PU(f-c,0)),d=0;c<f;c++,d++)i=p,a=d,u=n[c],s=void 0,(s=g5(a))in i?uc.f(i,s,ea(0,u)):i[s]=u;return p.length=d,p}(NU(t,`
|
|
|
|
|
`),e),`
|
|
|
|
|
`);return t},zU=function(t,e){Vr(e)&&"cause"in e&&jn(t,"cause",e.cause)},gS=ie(ie.bind),MP=function(t,e){return f5(t),e===void 0?t:gS?gS(t,e):function(){return t.apply(e,arguments)}},kl={},$U=Nn("iterator"),HU=Array.prototype,VU=Nn("iterator"),vS=function(t){if(t!=null)return jd(t,VU)||jd(t,"@@iterator")||kl[L1(t)]},UU=Et.TypeError,mS=function(t,e,n){var r,o;ur(t);try{if(!(r=jd(t,"return"))){if(e==="throw")throw n;return n}r=un(r,t)}catch(i){o=!0,r=i}if(e==="throw")throw n;if(o)throw r;return ur(r),n},WU=Et.TypeError,G0=function(t,e){this.stopped=t,this.result=e},yS=G0.prototype,GU=function(t,e,n){var r,o,i,a,u,s,l,c=n&&n.that,f=!(!n||!n.AS_ENTRIES),p=!(!n||!n.IS_ITERATOR),d=!(!n||!n.INTERRUPTED),v=MP(e,c),g=function(y){return r&&mS(r,"normal",y),new G0(!0,y)},m=function(y){return f?(ur(y),d?v(y[0],y[1],g):v(y[0],y[1])):d?v(y,g):v(y)};if(p)r=t;else{if(!(o=vS(t)))throw WU(B4(t)+" is not iterable");if(function(y){return y!==void 0&&(kl.Array===y||HU[$U]===y)}(o)){for(i=0,a=I1(t);a>i;i++)if((u=m(t[i]))&&Tg(yS,u))return u;return new G0(!1)}r=function(y,h){var b=arguments.length<2?vS(y):h;if(f5(b))return ur(un(b,y));throw UU(B4(y)+" is not iterable")}(t,o)}for(s=r.next;!(l=un(s,r)).done;){try{u=m(l.value)}catch(y){mS(r,"throw",y)}if(typeof u=="object"&&u&&Tg(yS,u))return u}return new G0(!1)},qU=function(t,e){return t===void 0?arguments.length<2?"":e:Su(t)},KU=!cn(function(){var t=Error("a");return!("stack"in t)||(Object.defineProperty(t,"stack",ea(1,7)),t.stack!==7)}),YU=Nn("toStringTag"),Lg=Et.Error,XU=[].push,Id=function(t,e){var n,r=arguments.length>2?arguments[2]:void 0,o=Tg(iy,this);Ol?n=Ol(new Lg(void 0),o?Nd(this):iy):(n=o?this:Lp(iy),jn(n,YU,"Error")),jn(n,"message",qU(e,"")),KU&&jn(n,"stack",MU(n.stack,1)),zU(n,r);var i=[];return GU(t,XU,{that:i}),jn(n,"errors",i),n};Ol?Ol(Id,Lg):PP(Id,Lg);var iy=Id.prototype=Lp(Lg.prototype,{constructor:ea(1,Id),message:ea(1,""),name:ea(1,"AggregateError")});Ip({global:!0},{AggregateError:Id});var I4=Nn("unscopables"),L4=Array.prototype;L4[I4]==null&&uc.f(L4,I4,{configurable:!0,value:Lp(null)});var Au,bS,wS,ay=function(t){L4[I4][t]=!0},R4=Nn("iterator"),zP=!1;[].keys&&("next"in(wS=[].keys())?(bS=Nd(Nd(wS)))!==Object.prototype&&(Au=bS):zP=!0);var ZU=Au==null||cn(function(){var t={};return Au[R4].call(t)!==t});ZU&&(Au={}),Ge(Au[R4])||ra(Au,R4,function(){return this});var A5={IteratorPrototype:Au,BUGGY_SAFARI_ITERATORS:zP},JU=uc.f,ES=Nn("toStringTag"),DS=function(t,e,n){t&&!Vn(t=n?t:t.prototype,ES)&&JU(t,ES,{configurable:!0,value:e})},QU=A5.IteratorPrototype,tW=function(){return this},eW=E5.PROPER,nW=E5.CONFIGURABLE,CS=A5.IteratorPrototype,jh=A5.BUGGY_SAFARI_ITERATORS,Tc=Nn("iterator"),rW=function(){return this},$P=function(t,e,n,r,o,i,a){(function(y,h,b,w){var D=h+" Iterator";y.prototype=Lp(QU,{next:ea(+!w,b)}),DS(y,D,!1),kl[D]=tW})(n,e,r);var u,s,l,c=function(y){if(y===o&&g)return g;if(!jh&&y in d)return d[y];switch(y){case"keys":case"values":case"entries":return function(){return new n(this,y)}}return function(){return new n(this)}},f=e+" Iterator",p=!1,d=t.prototype,v=d[Tc]||d["@@iterator"]||o&&d[o],g=!jh&&v||c(o),m=e=="Array"&&d.entries||v;if(m&&(u=Nd(m.call(new t)))!==Object.prototype&&u.next&&(Nd(u)!==CS&&(Ol?Ol(u,CS):Ge(u[Tc])||ra(u,Tc,rW)),DS(u,f,!0)),eW&&o=="values"&&v&&v.name!=="values"&&(nW?jn(d,"name","values"):(p=!0,g=function(){return un(v,this)})),o)if(s={values:c("values"),keys:i?g:c("keys"),entries:c("entries")},a)for(l in s)(jh||p||!(l in d))&&ra(d,l,s[l]);else Ip({target:e,proto:!0,forced:jh||p},s);return d[Tc]!==g&&ra(d,Tc,g,{name:o}),kl[e]=g,s},oW=Wu.set,iW=Wu.getterFor("Array Iterator"),Kf=$P(Array,"Array",function(t,e){oW(this,{type:"Array Iterator",target:ac(t),index:0,kind:e})},function(){var t=iW(this),e=t.target,n=t.kind,r=t.index++;return!e||r>=e.length?(t.target=void 0,{value:void 0,done:!0}):n=="keys"?{value:r,done:!1}:n=="values"?{value:e[r],done:!1}:{value:[r,e[r]],done:!1}},"values");kl.Arguments=kl.Array,ay("keys"),ay("values"),ay("entries");var aW=LP.charAt,uW=Wu.set,sW=Wu.getterFor("String Iterator");$P(String,"String",function(t){uW(this,{type:"St
|
|
|
|
|
Sorry, wangEditor V5+ versions do not support IE browser.`),AS(),OS()):global&&(!((uy=global.navigator)===null||uy===void 0)&&uy.userAgent.match("QQBrowser"))&&(AS(),OS());function AS(){typeof globalThis>"u"&&(window.globalThis=window)}function OS(){nV===void 0&&(window.AggregateError=function(t,e){var n=new Error(e);return n.errors=t,n})}var kS,Mg=Array.isArray||function(t){return Eu(t)=="Array"},UP=function(){},lW=[],WP=rc("Reflect","construct"),O5=/^\s*(?:class|function)\b/,cW=ge(O5.exec),fW=!O5.exec(UP),_c=function(t){if(!sn(t))return!1;try{return WP(UP,lW,t),!0}catch{return!1}},dW=!WP||Gn(function(){var t;return _c(_c.call)||!_c(Object)||!_c(function(){t=!0})||t})?function(t){if(!sn(t))return!1;switch(Pp(t)){case"AsyncFunction":case"GeneratorFunction":case"AsyncGeneratorFunction":return!1}return fW||!!cW(O5,EP(t))}:_c,pW=Bn("species"),BS=kt.Array,GP=function(t,e){return new(function(n){var r;return Mg(n)&&(r=n.constructor,(dW(r)&&(r===BS||Mg(r.prototype))||tr(r)&&(r=r[pW])===null)&&(r=void 0)),r===void 0?BS:r}(t))(e===0?0:e)},hW=Bn("species"),qP=Bn("isConcatSpreadable"),FS=kt.TypeError,gW=Eg>=51||!Gn(function(){var t=[];return t[qP]=!1,t.concat()[0]!==t}),vW=(kS="concat",Eg>=51||!Gn(function(){var t=[];return(t.constructor={})[hW]=function(){return{foo:1}},t[kS](Boolean).foo!==1})),mW=function(t){if(!tr(t))return!1;var e=t[qP];return e!==void 0?!!e:Mg(t)};qo({target:"Array",proto:!0,forced:!gW||!vW},{concat:function(t){var e,n,r,o,i,a=Bp(this),u=GP(a,0),s=0;for(e=-1,r=arguments.length;e<r;e++)if(mW(i=e===-1?a:arguments[e])){if(s+(o=Tp(i))>9007199254740991)throw FS("Maximum allowed index exceeded");for(n=0;n<o;n++,s++)n in i&&E4(u,s,i[n])}else{if(s>=9007199254740991)throw FS("Maximum allowed index exceeded");E4(u,s++,i)}return u.length=s,u}});var TS=u5.f,_S=typeof window=="object"&&window&&Object.getOwnPropertyNames?Object.getOwnPropertyNames(window):[],KP={f:function(t){return _S&&Eu(t)=="Window"?function(e){try{return TS(e)}catch{return yP(_S)}}(t):TS(Po(t))}},yW=ge([].slice),k5={f:Bn},bW=ja.f,je=function(t){var e=Qn.Symbol||(Qn.Symbol={});Vt(e,t)||bW(e,t,{value:k5.f(t)})},PS=ge([].push),bi=function(t){var e=t==1,n=t==2,r=t==3,o=t==4,i=t==6,a=t==7,u=t==5||i;return function(s,l,c,f){for(var p,d,v=Bp(s),g=dP(v),m=i5(l,c),y=Tp(g),h=0,b=f||GP,w=e?b(s,y):n||a?b(s,0):void 0;y>h;h++)if((u||h in g)&&(d=m(p=g[h],h,v),t))if(e)w[h]=d;else if(d)switch(t){case 3:return!0;case 5:return p;case 6:return h;case 2:PS(w,p)}else switch(t){case 4:return!1;case 7:PS(w,p)}return i?-1:r||o?o:w}},R1={forEach:bi(0),map:bi(1),filter:bi(2),some:bi(3),every:bi(4),find:bi(5),findIndex:bi(6),filterReject:bi(7)}.forEach,Rn=j1("hidden"),jS=Bn("toPrimitive"),wW=ic.set,NS=ic.getterFor("Symbol"),Gr=Object.prototype,Ui=kt.Symbol,Yi=Ui&&Ui.prototype,IS=kt.TypeError,dy=kt.QObject,Pc=rc("JSON","stringify"),YP=P1.f,Wi=ja.f,XP=KP.f,EW=e5.f,ZP=ge([].push),ii=us("symbols"),Rp=us("op-symbols"),py=us("string-to-symbol-registry"),hy=us("symbol-to-string-registry"),DW=us("wks"),gy=!dy||!dy.prototype||!dy.prototype.findChild,M4=Hn&&Gn(function(){return oi(Wi({},"a",{get:function(){return Wi(this,"a",{value:7}).a}})).a!=7})?function(t,e,n){var r=YP(Gr,e);r&&delete Gr[e],Wi(t,e,n),r&&t!==Gr&&Wi(Gr,e,r)}:Wi,vy=function(t,e){var n=ii[t]=oi(Yi);return wW(n,{type:"Symbol",tag:t,description:e}),Hn||(n.description=e),n},zg=function(t,e,n){t===Gr&&zg(Rp,e,n),ar(t);var r=oc(e);return ar(n),Vt(ii,r)?(n.enumerable?(Vt(t,Rn)&&t[Rn][r]&&(t[Rn][r]=!1),n=oi(n,{enumerable:Yr(0,!1)})):(Vt(t,Rn)||Wi(t,Rn,Yr(1,{})),t[Rn][r]=!0),M4(t,r,n)):Wi(t,r,n)},LS=function(t,e){ar(t);var n=Po(e),r=s5(n).concat(z4(n));return R1(r,function(o){Hn&&!zn(JP,n,o)||zg(t,o,n[o])}),t},JP=function(t){var e=oc(t),n=zn(EW,this,e);return!(this===Gr&&Vt(ii,e)&&!Vt(Rp,e))&&(!(n||!Vt(this,e)||!Vt(ii,e)||Vt(this,Rn)&&this[Rn][e])||n)},RS=function(t,e){var n=Po(t),r=oc(e);if(n!==Gr||!Vt(ii,r)||Vt(Rp,r)){var o=YP(n,r);return!o||!Vt(ii,r)||Vt(n,Rn)&&n[Rn][r]||(o.enumerable=!0),o}},MS=function(t){var e=XP(Po(t)),n=[];return R1(e,function(r){Vt(ii,r)||Vt(_p,r)||ZP(n,r)}),n},z4=function(t){var e=t===Gr,n=XP(e?Rp:Po(
|
|
|
|
|
* is-plain-object <https://github.com/jonschlinkert/is-plain-object>
|
|
|
|
|
*
|
|
|
|
|
* Copyright (c) 2014-2017, Jon Schlinkert.
|
|
|
|
|
* Released under the MIT License.
|
|
|
|
|
*/function zS(t){return Object.prototype.toString.call(t)==="[object Object]"}function Sn(t){var e,n;return zS(t)!==!1&&((e=t.constructor)===void 0||zS(n=e.prototype)!==!1&&n.hasOwnProperty("isPrototypeOf")!==!1)}function Ur(t){for(var e=arguments.length,n=Array(e>1?e-1:0),r=1;r<e;r++)n[r-1]=arguments[r];throw Error("[Immer] minified error nr: "+t+(n.length?" "+n.map(function(o){return"'"+o+"'"}).join(","):"")+". Find the full error at: https://bit.ly/3cXEKWf")}function Gu(t){return!!t&&!!t[sr]}function qu(t){return!!t&&(function(e){if(!e||typeof e!="object")return!1;var n=Object.getPrototypeOf(e);if(n===null)return!0;var r=Object.hasOwnProperty.call(n,"constructor")&&n.constructor;return r===Object||typeof r=="function"&&Function.toString.call(r)===IW}(t)||Array.isArray(t)||!!t[KS]||!!t.constructor[KS]||B5(t)||F5(t))}function Ld(t,e,n){n===void 0&&(n=!1),Bl(t)===0?(n?Object.keys:N5)(t).forEach(function(r){n&&typeof r=="symbol"||e(r,t[r],t)}):t.forEach(function(r,o){return e(o,r,t)})}function Bl(t){var e=t[sr];return e?e.i>3?e.i-4:e.i:Array.isArray(t)?1:B5(t)?2:F5(t)?3:0}function $4(t,e){return Bl(t)===2?t.has(e):Object.prototype.hasOwnProperty.call(t,e)}function tj(t,e,n){var r=Bl(t);r===2?t.set(e,n):r===3?(t.delete(e),t.add(n)):t[e]=n}function B5(t){return jW&&t instanceof Map}function F5(t){return NW&&t instanceof Set}function iu(t){return t.o||t.t}function T5(t){if(Array.isArray(t))return Array.prototype.slice.call(t);var e=LW(t);delete e[sr];for(var n=N5(e),r=0;r<n.length;r++){var o=n[r],i=e[o];i.writable===!1&&(i.writable=!0,i.configurable=!0),(i.get||i.set)&&(e[o]={configurable:!0,writable:!0,enumerable:i.enumerable,value:t[o]})}return Object.create(Object.getPrototypeOf(t),e)}function _5(t,e){return e===void 0&&(e=!1),P5(t)||Gu(t)||!qu(t)||(Bl(t)>1&&(t.set=t.add=t.clear=t.delete=TW),Object.freeze(t),e&&Ld(t,function(n,r){return _5(r,!0)},!0)),t}function TW(){Ur(2)}function P5(t){return t==null||typeof t!="object"||Object.isFrozen(t)}function ei(t){var e=RW[t];return e||Ur(18,t),e}function $S(){return Rd}function my(t,e){e&&(ei("Patches"),t.u=[],t.s=[],t.v=e)}function $g(t){H4(t),t.p.forEach(_W),t.p=null}function H4(t){t===Rd&&(Rd=t.l)}function HS(t){return Rd={p:[],l:Rd,h:t,m:!0,_:0}}function _W(t){var e=t[sr];e.i===0||e.i===1?e.j():e.O=!0}function yy(t,e){e._=e.p.length;var n=e.p[0],r=t!==void 0&&t!==n;return e.h.g||ei("ES5").S(e,t,r),r?(n[sr].P&&($g(e),Ur(4)),qu(t)&&(t=Hg(e,t),e.l||Vg(e,t)),e.u&&ei("Patches").M(n[sr],t,e.u,e.s)):t=Hg(e,n,[]),$g(e),e.u&&e.v(e.u,e.s),t!==ej?t:void 0}function Hg(t,e,n){if(P5(e))return e;var r=e[sr];if(!r)return Ld(e,function(i,a){return VS(t,r,e,i,a,n)},!0),e;if(r.A!==t)return e;if(!r.P)return Vg(t,r.t,!0),r.t;if(!r.I){r.I=!0,r.A._--;var o=r.i===4||r.i===5?r.o=T5(r.k):r.o;Ld(r.i===3?new Set(o):o,function(i,a){return VS(t,r,o,i,a,n)}),Vg(t,o,!1),n&&t.u&&ei("Patches").R(r,n,t.u,t.s)}return r.o}function VS(t,e,n,r,o,i){if(Gu(o)){var a=Hg(t,o,i&&e&&e.i!==3&&!$4(e.D,r)?i.concat(r):void 0);if(tj(n,r,a),!Gu(a))return;t.m=!1}if(qu(o)&&!P5(o)){if(!t.h.F&&t._<1)return;Hg(t,o),e&&e.A.l||Vg(t,o)}}function Vg(t,e,n){n===void 0&&(n=!1),t.h.F&&t.m&&_5(e,n)}function by(t,e){var n=t[sr];return(n?iu(n):t)[e]}function US(t,e){if(e in t)for(var n=Object.getPrototypeOf(t);n;){var r=Object.getOwnPropertyDescriptor(n,e);if(r)return r;n=Object.getPrototypeOf(n)}}function V4(t){t.P||(t.P=!0,t.l&&V4(t.l))}function wy(t){t.o||(t.o=T5(t.t))}function U4(t,e,n){var r=B5(e)?ei("MapSet").N(e,n):F5(e)?ei("MapSet").T(e,n):t.g?function(o,i){var a=Array.isArray(o),u={i:a?1:0,A:i?i.A:$S(),P:!1,I:!1,D:{},l:i,t:o,k:null,o:null,j:null,C:!1},s=u,l=q0;a&&(s=[u],l=K0);var c=Proxy.revocable(s,l),f=c.revoke,p=c.proxy;return u.k=p,u.j=f,p}(e,n):ei("ES5").J(e,n);return(n?n.A:$S()).p.push(r),r}function PW(t){return Gu(t)||Ur(22,t),function e(n){if(!qu(n))return n;var r,o=n[sr],i=Bl(n);if(o){if(!o.P&&(o.i<4||!ei("ES5").K(o)))return o.t;o.I=!0,r=WS(n,i),o.I=!1}else r=WS(n,i);return Ld(r,function(a,u){o&&function(s,l){return Bl(s)===2?s.get(l):s[l]}(o.t,a)===u||tj(r,a,e(u))}),i===3?new Set(r):r}(t)}function WS(t,e){switch(e){cas
|
|
|
|
|
Could not completely normalize the editor after `.concat(l,` iterations! This is usually due to incorrect normalization logic that leaves a node in an invalid state.
|
|
|
|
|
`));var f=r(t).pop();if(Q.has(t,f)){var p=E.node(t,f);t.normalizeNode(p)}c++}})}},parent(t,e){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},r=E.path(t,e,n),o=j.parent(r);return E.node(t,o)},path(t,e){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},{depth:r,edge:o}=n;if(j.isPath(e)){if(o==="start"){var[,i]=Q.first(t,e);e=i}else if(o==="end"){var[,a]=Q.last(t,e);e=a}}return L.isRange(e)&&(e=o==="start"?L.start(e):o==="end"?L.end(e):j.common(e.anchor.path,e.focus.path)),Bt.isPoint(e)&&(e=e.path),r!=null&&(e=e.slice(0,r)),e},hasPath:(t,e)=>Q.has(t,e),pathRef(t,e){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},{affinity:r="forward"}=n,o={current:e,affinity:r,unref(){var{current:i}=o;return E.pathRefs(t).delete(o),o.current=null,i}};return E.pathRefs(t).add(o),o},pathRefs(t){var e=JS.get(t);return e||(e=new Set,JS.set(t,e)),e},point(t,e){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},{edge:r="start"}=n;if(j.isPath(e)){var o;if(r==="end"){var[,i]=Q.last(t,e);o=i}else{var[,a]=Q.first(t,e);o=a}var u=Q.get(t,o);if(!ot.isText(u))throw new Error("Cannot get the ".concat(r," point in the node at path [").concat(e,"] because it has no ").concat(r," text node."));return{path:o,offset:r==="end"?u.text.length:0}}if(L.isRange(e)){var[s,l]=L.edges(e);return r==="start"?s:l}return e},pointRef(t,e){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},{affinity:r="forward"}=n,o={current:e,affinity:r,unref(){var{current:i}=o;return E.pointRefs(t).delete(o),o.current=null,i}};return E.pointRefs(t).add(o),o},pointRefs(t){var e=QS.get(t);return e||(e=new Set,QS.set(t,e)),e},*positions(t){var e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},{at:n=t.selection,unit:r="offset",reverse:o=!1,voids:i=!1}=e;if(n){var a=E.range(t,n),[u,s]=L.edges(a),l=o?s:u,c=!1,f="",p=0,d=0,v=0;for(var[g,m]of E.nodes(t,{at:n,reverse:o,voids:i})){if(ct.isElement(g)){if(!i&&t.isVoid(g)){yield E.start(t,m);continue}if(t.isInline(g))continue;if(E.hasInlines(t,g)){var y=j.isAncestor(m,s.path)?s:E.end(t,m),h=j.isAncestor(m,u.path)?u:E.start(t,m);f=E.string(t,{anchor:h,focus:y},{voids:i}),c=!0}}if(ot.isText(g)){var b=j.equals(m,l.path);for(b?(d=o?l.offset:g.text.length-l.offset,v=l.offset):(d=g.text.length,v=o?d:0),(b||c||r==="offset")&&(yield{path:m,offset:v},c=!1);;){if(p===0){if(f==="")break;p=w(f,r,o),f=G4(f,p,o)[1]}if(v=o?v-p:v+p,(d-=p)<0){p=-d;break}p=0,yield{path:m,offset:v}}}}}function w(D,x,C){return x==="character"?W4(D,C):x==="word"?function(O){for(var T=arguments.length>1&&arguments[1]!==void 0&&arguments[1],R=0,H=!1;O.length>0;){var M=W4(O,T),[K,U]=G4(O,M,T);if(WW(K,U,T))H=!0,R+=M;else{if(H)break;R+=M}O=U}return R}(D,C):x==="line"||x==="block"?D.length:1}},previous(t){var e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},{mode:n="lowest",voids:r=!1}=e,{match:o,at:i=t.selection}=e;if(i){var a=E.before(t,i,{voids:r});if(a){var[,u]=E.first(t,[]),s=[a.path,u];if(j.isPath(i)&&i.length===0)throw new Error("Cannot get the previous node from the root node!");if(o==null)if(j.isPath(i)){var[l]=E.parent(t,i);o=f=>l.children.includes(f)}else o=()=>!0;var[c]=E.nodes(t,{reverse:!0,at:s,match:o,mode:n,voids:r});return c}}},range:(t,e,n)=>L.isRange(e)&&!n?e:{anchor:E.start(t,e),focus:E.end(t,n||e)},rangeRef(t,e){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},{affinity:r="forward"}=n,o={current:e,affinity:r,unref(){var{current:i}=o;return E.rangeRefs(t).delete(o),o.current=null,i}};return E.rangeRefs(t).add(o),o},rangeRefs(t){var e=tA.get(t);return e||(e=new Set,tA.set(t,e)),e},removeMark(t,e){t.removeMark(e)},setNormalizing(t,e){ZS.set(t,e)},start:(t,e)=>E.point(t,e,{edge:"start"}),string(t,e){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},{voids:r=!1}=n,o=E.range(t,e),[i,a]=L.edges(o),u="";for(var[s,l]of E.nodes(t,{at:o,match:ot.isText,voids:r})){var c=s.text;j.equals(l,a.path)&&(c=c.slice(0,a.offset)),j.equals(l,i.path)&&(c=c.slice(i.offset)),u+=c}return u},unhangRange(t,e){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{}
|
|
|
|
|
* Takes a string with placeholder variables like `%{smart_count} file selected`
|
|
|
|
|
* and replaces it with values from options `{smart_count: 5}`
|
|
|
|
|
*
|
|
|
|
|
* @license https://github.com/airbnb/polyglot.js/blob/master/LICENSE
|
|
|
|
|
* taken from https://github.com/airbnb/polyglot.js/blob/master/lib/polyglot.js#L299
|
|
|
|
|
*
|
|
|
|
|
* @param {string} phrase that needs interpolation, with placeholders
|
|
|
|
|
* @param {object} options with values that will be used to replace placeholders
|
|
|
|
|
* @returns {any[]} interpolated
|
|
|
|
|
*/function XA(t,e){const n=/\$/g;let r=[t];if(e==null)return r;for(const o of Object.keys(e))if(o!=="_"){let i=e[o];typeof i=="string"&&(i=n[Symbol.replace](i,"$$$$")),r=OK(r,new RegExp(`%\\{${o}\\}`,"g"),i)}return r}var Pj=(Os=AK("apply"),class{constructor(t){Object.defineProperty(this,Os,{value:kK}),this.locale={strings:{},pluralize:e=>e===1?0:1},Array.isArray(t)?t.forEach(YA(this,Os)[Os],this):YA(this,Os)[Os](t)}translate(t,e){return this.translateArray(t,e).join("")}translateArray(t,e){if(!function(r,o){return Object.prototype.hasOwnProperty.call(r,o)}(this.locale.strings,t))throw new Error(`missing string: ${t}`);const n=this.locale.strings[t];if(typeof n=="object"){if(e&&e.smart_count!==void 0)return XA(n[this.locale.pluralize(e.smart_count)],e);throw new Error("Attempted to use a string with plural forms, but no value was given for %{smart_count}")}return XA(n,e)}});function kK(t){if(t==null||!t.strings)return;const e=this.locale;this.locale={...e,strings:{...e.strings,...t.strings}},this.locale.pluralize=t.pluralize||e.pluralize}var jj=function(){var t={},e=t._fns={};return t.emit=function(n,r,o,i,a,u,s){var l=function(c){for(var f=e[c]?e[c]:[],p=c.indexOf(":"),d=p===-1?[c]:[c.substring(0,p),c.substring(p+1)],v=Object.keys(e),g=0,m=v.length;g<m;g++){var y=v[g];if(y==="*"&&(f=f.concat(e[y])),d.length===2&&d[0]===y){f=f.concat(e[y]);break}}return f}(n);l.length&&function(c,f,p){for(var d=0,v=f.length;d<v&&f[d];d++)f[d].event=c,f[d].apply(f[d],p)}(n,l,[r,o,i,a,u,s])},t.on=function(n,r){e[n]||(e[n]=[]),e[n].push(r)},t.once=function(n,r){this.on(n,function o(){r.apply(this,arguments),t.off(n,o)})},t.off=function(n,r){var o=[];if(n&&r)for(var i=this._fns[n],a=0,u=i?i.length:0;a<u;a++)i[a]!==r&&o.push(i[a]);o.length?this._fns[n]=o:delete this._fns[n]},t},BK={urlAlphabet:"useandom-26T198340PX75pxJACKVERYMINDBUSHWOLF_GQZbfghjklqvwyzrict"};let{urlAlphabet:FK}=BK,ZA=t=>crypto.getRandomValues(new Uint8Array(t)),JA=(t,e,n)=>{let r=(2<<Math.log(t.length-1)/Math.LN2)-1,o=-~(1.6*r*e/t.length);return()=>{let i="";for(;;){let a=n(o),u=o;for(;u--;)if(i+=t[a[u]&r]||"",i.length===e)return i}}};var TK={nanoid:(t=21)=>{let e="",n=crypto.getRandomValues(new Uint8Array(t));for(;t--;){let r=63&n[t];e+=r<36?r.toString(36):r<62?(r-26).toString(36).toUpperCase():r<63?"_":"-"}return e},customAlphabet:(t,e)=>JA(t,e,ZA),customRandom:JA,urlAlphabet:FK,random:ZA},Ty=function(t){if(typeof t!="number"||isNaN(t))throw new TypeError("Expected a number, got "+typeof t);var e=t<0,n=["B","KB","MB","GB","TB","PB","EB","ZB","YB"];if(e&&(t=-t),t<1)return(e?"-":"")+t+" B";var r=Math.min(Math.floor(Math.log(t)/Math.log(1024)),n.length-1);t=Number(t/Math.pow(1024,r));var o=n[r];return t>=10||t%1==0?(e?"-":"")+t.toFixed(0)+" "+o:(e?"-":"")+t.toFixed(1)+" "+o};function Nj(t,e){this.text=t=t||"",this.hasWild=~t.indexOf("*"),this.separator=e,this.parts=t.split(e)}Nj.prototype.match=function(t){var e,n,r=!0,o=this.parts,i=o.length;if(typeof t=="string"||t instanceof String)if(this.hasWild||this.text==t){for(n=(t||"").split(this.separator),e=0;r&&e<i;e++)o[e]!=="*"&&(r=e<n.length&&o[e]===n[e]);r=r&&n}else r=!1;else if(typeof t.splice=="function")for(r=[],e=t.length;e--;)this.match(t[e])&&(r[r.length]=t[e]);else if(typeof t=="object")for(var a in r={},t)this.match(a)&&(r[a]=t[a]);return r};var _K=/[\/\+\.]/,PK=function(t,e){function n(r){var o=function(i,a,u){var s=new Nj(i,u||/[\/\.]/);return a!==void 0?s.match(a):s}(r,t,_K);return o&&o.length>=2}return e?n(e.split(";")[0]):n},jK=0;function NK(t){return"__private_"+jK+++"_"+t}var _y=NK("publish");class Ij{constructor(){Object.defineProperty(this,_y,{value:IK}),this.state={},this.callbacks=[]}getState(){return this.state}setState(e){const n={...this.state},r={...this.state,...e};this.state=r,function(o,i){if(!Object.prototype.hasOwnProperty.call(o,i))throw new TypeError("attempted to use private field on non-instance");return o}(this,_y)[_y](n,r,e)}subscribe(e){return this.callbacks.push(e),()=>{this.callbacks.splice(this.callbacks.indexOf(e),1)}}}function IK(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++
|
|
|
|
|
id: ${r[i].id}
|
|
|
|
|
type: ${r[i].type}`)}),r.length>0&&ft(this,zc)[zc](),o.length>0){let i=`Multiple errors occurred while adding files:
|
|
|
|
|
`;if(o.forEach(a=>{i+=`
|
|
|
|
|
* ${a.message}`}),this.info({message:this.i18n("addBulkFilesFailed",{smart_count:o.length}),details:i},"error",this.opts.infoTimeout),typeof AggregateError=="function")throw new AggregateError(o,i);{const a=new Error(i);throw a.errors=o,a}}}removeFiles(e,n){const{files:r,currentUploads:o}=this.getState(),i={...r},a={...o},u=Object.create(null);function s(f){return u[f]===void 0}e.forEach(f=>{r[f]&&(u[f]=r[f],delete i[f])}),Object.keys(a).forEach(f=>{const p=o[f].fileIDs.filter(s);p.length!==0?a[f]={...o[f],fileIDs:p}:delete a[f]});const l={currentUploads:a,files:i};Object.keys(i).length===0&&(l.allowNewUpload=!0,l.error=null,l.recoveredState=null),this.setState(l),this.calculateTotalProgress();const c=Object.keys(u);c.forEach(f=>{this.emit("file-removed",u[f],n)}),c.length>5?this.log(`Removed ${c.length} files`):this.log(`Removed files: ${c.join(", ")}`)}removeFile(e,n){n===void 0&&(n=null),this.removeFiles([e],n)}pauseResume(e){if(!this.getState().capabilities.resumableUploads||this.getFile(e).uploadComplete)return;const n=!this.getFile(e).isPaused;return this.setFileState(e,{isPaused:n}),this.emit("upload-pause",e,n),n}pauseAll(){const e={...this.getState().files};Object.keys(e).filter(n=>!e[n].progress.uploadComplete&&e[n].progress.uploadStarted).forEach(n=>{const r={...e[n],isPaused:!0};e[n]=r}),this.setState({files:e}),this.emit("pause-all")}resumeAll(){const e={...this.getState().files};Object.keys(e).filter(n=>!e[n].progress.uploadComplete&&e[n].progress.uploadStarted).forEach(n=>{const r={...e[n],isPaused:!1,error:null};e[n]=r}),this.setState({files:e}),this.emit("resume-all")}retryAll(){const e={...this.getState().files},n=Object.keys(e).filter(o=>e[o].error);if(n.forEach(o=>{const i={...e[o],isPaused:!1,error:null};e[o]=i}),this.setState({files:e,error:null}),this.emit("retry-all",n),n.length===0)return Promise.resolve({successful:[],failed:[]});const r=ft(this,Uo)[Uo](n,{forceAllowNewUpload:!0});return ft(this,Wo)[Wo](r)}cancelAll(){this.emit("cancel-all");const{files:e}=this.getState(),n=Object.keys(e);n.length&&this.removeFiles(n,"cancel-all"),this.setState({totalProgress:0,error:null,recoveredState:null})}retryUpload(e){this.setFileState(e,{error:null,isPaused:!1}),this.emit("upload-retry",e);const n=ft(this,Uo)[Uo]([e],{forceAllowNewUpload:!0});return ft(this,Wo)[Wo](n)}reset(){this.cancelAll()}logout(){this.iteratePlugins(e=>{e.provider&&e.provider.logout&&e.provider.logout()})}calculateProgress(e,n){if(!this.getFile(e.id))return void this.log(`Not setting progress for a file that has been removed: ${e.id}`);const r=Number.isFinite(n.bytesTotal)&&n.bytesTotal>0;this.setFileState(e.id,{progress:{...this.getFile(e.id).progress,bytesUploaded:n.bytesUploaded,bytesTotal:n.bytesTotal,percentage:r?Math.round(n.bytesUploaded/n.bytesTotal*100):0}}),this.calculateTotalProgress()}calculateTotalProgress(){const e=this.getFiles().filter(s=>s.progress.uploadStarted||s.progress.preprocess||s.progress.postprocess);if(e.length===0)return this.emit("progress",0),void this.setState({totalProgress:0});const n=e.filter(s=>s.progress.bytesTotal!=null),r=e.filter(s=>s.progress.bytesTotal==null);if(n.length===0){const s=100*e.length,l=r.reduce((f,p)=>f+p.progress.percentage,0),c=Math.round(l/s*100);return void this.setState({totalProgress:c})}let o=n.reduce((s,l)=>s+l.progress.bytesTotal,0);const i=o/n.length;o+=i*r.length;let a=0;n.forEach(s=>{a+=s.progress.bytesUploaded}),r.forEach(s=>{a+=i*(s.progress.percentage||0)/100});let u=o===0?0:Math.round(a/o*100);u>100&&(u=100),this.setState({totalProgress:u}),this.emit("progress",u)}updateOnlineStatus(){window.navigator.onLine===void 0||window.navigator.onLine?(this.emit("is-online"),this.wasOffline&&(this.emit("back-online"),this.info(this.i18n("connectedToInternet"),"success",3e3),this.wasOffline=!1)):(this.emit("is-offline"),this.info(this.i18n("noInternetConnection"),"error",0),this.wasOffline=!0)}getID(){return this.opts.id}use(e,n){if(typeof e!="function")throw new TypeError(`Expected a plugin class, but got ${e===null?"null":typeof e}. Please verify that the plugin was impo
|
|
|
|
|
Uppy plugins must have unique \`id\` options. See https://uppy.io/docs/plugins/#id.`;throw new Error(a)}return e.VERSION&&this.log(`Using ${o} v${e.VERSION}`),r.type in ft(this,pn)[pn]?ft(this,pn)[pn][r.type].push(r):ft(this,pn)[pn][r.type]=[r],r.install(),this}getPlugin(e){for(const n of Object.values(ft(this,pn)[pn])){const r=n.find(o=>o.id===e);if(r!=null)return r}}[Mj](e){return ft(this,pn)[pn][e]}iteratePlugins(e){Object.values(ft(this,pn)[pn]).flat(1).forEach(e)}removePlugin(e){this.log(`Removing plugin ${e.id}`),this.emit("plugin-remove",e),e.uninstall&&e.uninstall();const n=ft(this,pn)[pn][e.type],r=n.findIndex(i=>i.id===e.id);r!==-1&&n.splice(r,1);const o={plugins:{...this.getState().plugins,[e.id]:void 0}};this.setState(o)}close(){this.log(`Closing Uppy instance ${this.opts.id}: removing all files and uninstalling plugins`),this.reset(),ft(this,Lc)[Lc](),this.iteratePlugins(e=>{this.removePlugin(e)}),typeof window<"u"&&window.removeEventListener&&(window.removeEventListener("online",ft(this,Hr)[Hr]),window.removeEventListener("offline",ft(this,Hr)[Hr]))}hideInfo(){const{info:e}=this.getState();this.setState({info:e.slice(1)}),this.emit("info-hidden")}info(e,n,r){n===void 0&&(n="info"),r===void 0&&(r=3e3);const o=typeof e=="object";this.setState({info:[...this.getState().info,{type:n,message:o?e.message:e,details:o?e.details:null}]}),setTimeout(()=>this.hideInfo(),r),this.emit("info-visible")}log(e,n){const{logger:r}=this.opts;switch(n){case"error":r.error(e);break;case"warning":r.warn(e);break;default:r.debug(e)}}restore(e){return this.log(`Core: attempting to restore upload "${e}"`),this.getState().currentUploads[e]?ft(this,Wo)[Wo](e):(ft(this,vu)[vu](e),Promise.reject(new Error("Nonexistent upload")))}[zj](){return ft(this,Uo)[Uo](...arguments)}addResultData(e,n){if(!ft(this,Ly)[Ly](e))return void this.log(`Not setting result for an upload that has been removed: ${e}`);const{currentUploads:r}=this.getState(),o={...r[e],result:{...r[e].result,...n}};this.setState({currentUploads:{...r,[e]:o}})}upload(){var e;(e=ft(this,pn)[pn].uploader)!=null&&e.length||this.log("No uploader type plugins are used","warning");let{files:n}=this.getState();const r=this.opts.onBeforeUpload(n);return r===!1?Promise.reject(new Error("Not starting the upload because onBeforeUpload returned false")):(r&&typeof r=="object"&&(n=r,this.setState({files:n})),Promise.resolve().then(()=>{ft(this,jy)[jy](n),ft(this,Ny)[Ny](n)}).catch(o=>{ft(this,Je)[Je](o)}).then(()=>{const{currentUploads:o}=this.getState(),i=Object.values(o).flatMap(s=>s.fileIDs),a=[];Object.keys(n).forEach(s=>{const l=this.getFile(s);l.progress.uploadStarted||i.indexOf(s)!==-1||a.push(l.id)});const u=ft(this,Uo)[Uo](a);return ft(this,Wo)[Wo](u)}).catch(o=>{ft(this,Je)[Je](o,{showInformer:!1})}))}}function UK(t,e){e===void 0&&(e=this.getFiles());const{maxFileSize:n,minFileSize:r,maxTotalFileSize:o,maxNumberOfFiles:i,allowedFileTypes:a}=this.opts.restrictions;if(i&&e.length+1>i)throw new mo(`${this.i18n("youCanOnlyUploadX",{smart_count:i})}`);if(a&&!a.some(u=>u.indexOf("/")>-1?!!t.type&&PK(t.type.replace(/;.*?$/,""),u):!(u[0]!=="."||!t.extension)&&t.extension.toLowerCase()===u.substr(1).toLowerCase())){const u=a.join(", ");throw new mo(this.i18n("youCanOnlyUploadFileTypes",{types:u}))}if(o&&t.size!=null){let u=0;if(u+=t.size,e.forEach(s=>{u+=s.size}),u>o)throw new mo(this.i18n("exceedsSize",{size:Ty(o),file:t.name}))}if(n&&t.size!=null&&t.size>n)throw new mo(this.i18n("exceedsSize",{size:Ty(n),file:t.name}));if(r&&t.size!=null&&t.size<r)throw new mo(this.i18n("inferiorSize",{size:Ty(r)}))}function WK(t){const{minNumberOfFiles:e}=this.opts.restrictions;if(Object.keys(t).length<e)throw new mo(`${this.i18n("youHaveToAtLeastSelectX",{smart_count:e})}`)}function GK(t){const{requiredMetaFields:e}=this.opts.restrictions,{hasOwnProperty:n}=Object.prototype,r=[],o=[];for(let i=0;i<e.length;i++)if(!n.call(t.meta,e[i])||t.meta[e[i]]===""){const a=new mo(`${this.i18n("missingRequiredMetaFieldOnFile",{fileName:t.name})}`);r.push(a),o.push(e[i]),ft(this,Je)[Je](a,{file:t,showInformer:!1,t
|
|
|
|
|
* is-plain-object <https://github.com/jonschlinkert/is-plain-object>
|
|
|
|
|
*
|
|
|
|
|
* Copyright (c) 2014-2017, Jon Schlinkert.
|
|
|
|
|
* Released under the MIT License.
|
|
|
|
|
*/function P7(t){return Object.prototype.toString.call(t)==="[object Object]"}De({target:"Object",stat:!0,forced:$X},{keys:function(t){return gl(Na(t))}});var HX={isHistory(t){return P7(e=t)!==!1&&((n=e.constructor)===void 0||P7(r=n.prototype)!==!1&&r.hasOwnProperty("isPrototypeOf")!==!1)&&Array.isArray(t.redos)&&Array.isArray(t.undos)&&(t.redos.length===0||Xi.isOperationList(t.redos[0]))&&(t.undos.length===0||Xi.isOperationList(t.undos[0]));var e,n,r}},Xy=new WeakMap,Zy=new WeakMap,sl={isHistoryEditor:t=>HX.isHistory(t.history)&&E.isEditor(t),isMerging:t=>Zy.get(t),isSaving:t=>Xy.get(t),redo(t){t.redo()},undo(t){t.undo()},withoutMerging(t,e){var n=sl.isMerging(t);Zy.set(t,!1),e(),Zy.set(t,n)},withoutSaving(t,e){var n=sl.isSaving(t);Xy.set(t,!1),e(),Xy.set(t,n)}},VX=X.String,ue=function(t){if(K1(t)==="Symbol")throw TypeError("Cannot convert a Symbol value to a string");return VX(t)},tD=function(){var t=Le(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},UX=sc.PROPER,vE=RegExp.prototype,aN=vE.toString,WX=pt(tD),GX=Zt(function(){return aN.call({source:"a",flags:"b"})!="/a/b"}),qX=UX&&aN.name!="toString";(GX||qX)&&Un(RegExp.prototype,"toString",function(){var t=Le(this),e=ue(t.source),n=t.flags;return"/"+e+"/"+ue(n===void 0&&Yu(vE,t)&&!("flags"in vE)?WX(t):n)},{unsafe:!0});var Vh,KX=an?Object.defineProperties:function(t,e){Le(t);for(var n,r=Ia(e),o=gl(e),i=o.length,a=0;i>a;)ro.f(t,n=o[a++],r[n]);return t},mE=ds("document","documentElement"),uN=J5("IE_PROTO"),Jy=function(){},sN=function(t){return"<script>"+t+"<\/script>"},j7=function(t){t.write(sN("")),t.close();var e=t.parentWindow.Object;return t=null,e},J0=function(){try{Vh=new ActiveXObject("htmlfile")}catch{}var t,e;J0=typeof document<"u"?document.domain&&Vh?j7(Vh):((e=Hd("iframe")).style.display="none",mE.appendChild(e),e.src="javascript:",(t=e.contentWindow.document).open(),t.write(sN("document.F=Object")),t.close(),t.F):j7(Vh);for(var n=uv.length;n--;)delete J0.prototype[uv[n]];return J0()};q1[uN]=!0;var Z1=Object.create||function(t,e){var n;return t!==null?(Jy.prototype=Le(t),n=new Jy,Jy.prototype=null,n[uN]=t):n=J0(),e===void 0?n:KX(n,e)},yE=xe("unscopables"),bE=Array.prototype;bE[yE]==null&&ro.f(bE,yE,{configurable:!0,value:Z1(null)});var ld=function(t){bE[yE][t]=!0},YX=rN.includes;De({target:"Array",proto:!0},{includes:function(t){return YX(this,t,arguments.length>1?arguments[1]:void 0)}}),ld("includes");var XX=xe("match"),eD=function(t){var e;return ce(t)&&((e=t[XX])!==void 0?!!e:Zr(t)=="RegExp")},ZX=X.TypeError,nD=function(t){if(eD(t))throw ZX("The method doesn't accept regular expressions");return t},JX=xe("match"),rD=function(t){var e=/./;try{"/./"[t](e)}catch{try{return e[JX]=!1,"/./"[t](e)}catch{}}return!1},QX=pt("".indexOf);De({target:"String",proto:!0,forced:!rD("includes")},{includes:function(t){return!!~QX(ue(_r(this)),ue(nD(t)),arguments.length>1?arguments[1]:void 0)}});var tZ=/"/g,eZ=pt("".replace);De({target:"String",proto:!0,forced:Zt(function(){var t="".anchor('"');return t!==t.toLowerCase()||t.split('"').length>3})},{anchor:function(t){return e=t,n=ue(_r(this)),r="<a",(r+=' name="'+eZ(ue(e),tZ,""")+'"')+">"+n+"</a>";var e,n,r}});var wE=function(t,e,n){var r,o;Le(t);try{if(!(r=Xu(t,"return"))){if(e==="throw")throw n;return n}r=Ut(r,t)}catch(i){o=!0,r=i}if(e==="throw")throw n;if(o)throw r;return Le(r),n},nZ=function(t,e,n,r){try{return r?e(Le(n)[0],n[1]):e(n)}catch(o){wE(t,"throw",o)}},Hl={},rZ=xe("iterator"),oZ=Array.prototype,lN=function(t){return t!==void 0&&(Hl.Array===t||oZ[rZ]===t)},Wd=function(t,e,n){var r=Z5(e);r in t?ro.f(t,r,W1(0,n)):t[r]=n},iZ=xe("iterator"),oD=function(t){if(t!=null)return Xu(t,iZ)||Xu(t,"@@iterator")||Hl[K1(t)]},aZ=X.TypeError,cN=function(t,e){var n=arguments.length<2?oD(t):e;if(xa(n))return Le(Ut(n,t));throw aZ(U1(t)+" is not iterable")},N7=X.Array,fN=xe("iterator"),dN=!1;try{var uZ=0,I7={next:function(){return{done:!!uZ++}},return:function(){dN=!0}};I7[fN]=function(){return this},Array.from(I7,function(){throw 2})}catc
|
|
|
|
|
`)&&t.flags==="s")}),LZ=X.RegExp,cD=Zt(function(){var t=LZ("(?<a>b)","g");return t.exec("b").groups.a!=="b"||"b".replace(t,"$<a>c")!=="bc"}),RZ=kn.get,MZ=q5("native-string-replace",String.prototype.replace),cv=RegExp.prototype.exec,xE=cv,zZ=pt("".charAt),$Z=pt("".indexOf),HZ=pt("".replace),tb=pt("".slice),eb=function(){var t=/a/,e=/b*/g;return Ut(cv,t,"a"),Ut(cv,e,"a"),t.lastIndex!==0||e.lastIndex!==0}(),W7=Q1.BROKEN_CARET,nb=/()??/.exec("")[1]!==void 0;(eb||nb||W7||lD||cD)&&(xE=function(t){var e,n,r,o,i,a,u,s=this,l=RZ(s),c=ue(t),f=l.raw;if(f)return f.lastIndex=s.lastIndex,e=Ut(xE,f,c),s.lastIndex=f.lastIndex,e;var p=l.groups,d=W7&&s.sticky,v=Ut(tD,s),g=s.source,m=0,y=c;if(d&&(v=HZ(v,"y",""),$Z(v,"g")===-1&&(v+="g"),y=tb(c,s.lastIndex),s.lastIndex>0&&(!s.multiline||s.multiline&&zZ(c,s.lastIndex-1)!==`
|
|
|
|
|
`)&&(g="(?: "+g+")",y=" "+y,m++),n=new RegExp("^(?:"+g+")",v)),nb&&(n=new RegExp("^"+g+"$(?!\\s)",v)),eb&&(r=s.lastIndex),o=Ut(cv,d?n:s,y),d?o?(o.input=tb(o.input,m),o[0]=tb(o[0],m),o.index=s.lastIndex,s.lastIndex+=o[0].length):s.lastIndex=0:eb&&o&&(s.lastIndex=s.global?o.index+o[0].length:r),nb&&o&&o.length>1&&Ut(MZ,o[0],n,function(){for(i=1;i<arguments.length-2;i++)arguments[i]===void 0&&(o[i]=void 0)}),o&&p)for(o.groups=a=Z1(null),i=0;i<p.length;i++)a[(u=p[i])[0]]=o[u[1]];return o});var Gd=xE;De({target:"RegExp",proto:!0,forced:/./.exec!==Gd},{exec:Gd});var fD=Function.prototype,G7=fD.apply,VZ=fD.bind,q7=fD.call,dD=typeof Reflect=="object"&&Reflect.apply||(VZ?q7.bind(G7):function(){return q7.apply(G7,arguments)}),UZ=xe("species"),rb=RegExp.prototype,pD=function(t,e,n,r){var o=xe(t),i=!Zt(function(){var l={};return l[o]=function(){return 7},""[t](l)!=7}),a=i&&!Zt(function(){var l=!1,c=/a/;return t==="split"&&((c={}).constructor={},c.constructor[UZ]=function(){return c},c.flags="",c[o]=/./[o]),c.exec=function(){return l=!0,null},c[o](""),!l});if(!i||!a||n){var u=pt(/./[o]),s=e(o,""[t],function(l,c,f,p,d){var v=pt(l),g=c.exec;return g===Gd||g===rb.exec?i&&!d?{done:!0,value:u(c,f,p)}:{done:!0,value:v(f,c,p)}:{done:!1}});Un(String.prototype,t,s[0]),Un(rb,o,s[1])}r&&Xr(rb[o],"sham",!0)},WZ=pN.charAt,hD=function(t,e,n){return e+(n?WZ(t,e).length:1)},GZ=Math.floor,ob=pt("".charAt),qZ=pt("".replace),ib=pt("".slice),KZ=/\$([$&'`]|\d{1,2}|<[^>]*>)/g,YZ=/\$([$&'`]|\d{1,2})/g,XZ=function(t,e,n,r,o,i){var a=n+t.length,u=r.length,s=YZ;return o!==void 0&&(o=Na(o),s=KZ),qZ(i,s,function(l,c){var f;switch(ob(c,0)){case"$":return"$";case"&":return t;case"`":return ib(e,0,n);case"'":return ib(e,a);case"<":f=o[ib(c,1,-1)];break;default:var p=+c;if(p===0)return l;if(p>u){var d=GZ(p/10);return d===0?l:d<=u?r[d-1]===void 0?ob(c,1):r[d-1]+ob(c,1):l}f=r[p-1]}return f===void 0?"":f})},ZZ=X.TypeError,qd=function(t,e){var n=t.exec;if(re(n)){var r=Ut(n,t,e);return r!==null&&Le(r),r}if(Zr(t)==="RegExp")return Ut(Gd,t,e);throw ZZ("RegExp#exec called on incompatible receiver")},SE=xe("replace"),JZ=Math.max,QZ=Math.min,tJ=pt([].concat),ab=pt([].push),K7=pt("".indexOf),Y7=pt("".slice),eJ="a".replace(/./,"$0")==="$0",X7=!!/./[SE]&&/./[SE]("a","$0")==="";pD("replace",function(t,e,n){var r=X7?"$":"$0";return[function(o,i){var a=_r(this),u=o==null?void 0:Xu(o,SE);return u?Ut(u,o,a,i):Ut(e,ue(a),o,i)},function(o,i){var a=Le(this),u=ue(o);if(typeof i=="string"&&K7(i,r)===-1&&K7(i,"$<")===-1){var s=n(e,a,u,i);if(s.done)return s.value}var l=re(i);l||(i=ue(i));var c=a.global;if(c){var f=a.unicode;a.lastIndex=0}for(var p=[];;){var d=qd(a,u);if(d===null||(ab(p,d),!c))break;ue(d[0])===""&&(a.lastIndex=hD(u,lc(a.lastIndex),f))}for(var v,g="",m=0,y=0;y<p.length;y++){for(var h=ue((d=p[y])[0]),b=JZ(QZ(Vp(d.index),u.length),0),w=[],D=1;D<d.length;D++)ab(w,(v=d[D])===void 0?v:String(v));var x=d.groups;if(l){var C=tJ([h],w,b,u);x!==void 0&&ab(C,x);var O=ue(dD(i,void 0,C))}else O=XZ(h,u,b,w,x,i);b>=m&&(g+=Y7(u,m,b)+O,m=b+h.length)}return g+Y7(u,m)}]},!!Zt(function(){var t=/./;return t.exec=function(){var e=[];return e.groups={a:"7"},e},"".replace(t,"$<a>")!=="7"})||!eJ||X7);/*! *****************************************************************************
|
|
|
|
|
Copyright (c) Microsoft Corporation.
|
|
|
|
|
|
|
|
|
|
Permission to use, copy, modify, and/or distribute this software for any
|
|
|
|
|
purpose with or without fee is hereby granted.
|
|
|
|
|
|
|
|
|
|
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
|
|
|
|
|
REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
|
|
|
|
|
AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
|
|
|
|
|
INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
|
|
|
|
|
LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
|
|
|
|
|
OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
|
|
|
|
|
PERFORMANCE OF THIS SOFTWARE.
|
|
|
|
|
***************************************************************************** */var AE=function(t,e){return AE=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,r){n.__proto__=r}||function(n,r){for(var o in r)Object.prototype.hasOwnProperty.call(r,o)&&(n[o]=r[o])},AE(t,e)};function fc(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function n(){this.constructor=t}AE(t,e),t.prototype=e===null?Object.create(e):(n.prototype=e.prototype,new n)}var Er=function(){return Er=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},Er.apply(this,arguments)};function Dr(t){var e=typeof Symbol=="function"&&Symbol.iterator,n=e&&t[e],r=0;if(n)return n.call(t);if(t&&typeof t.length=="number")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 Ht(t,e){var n=typeof Symbol=="function"&&t[Symbol.iterator];if(!n)return t;var r,o,i=n.call(t),a=[];try{for(;(e===void 0||e-- >0)&&!(r=i.next()).done;)a.push(r.value)}catch(u){o={error:u}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a}function OE(t,e){for(var n=0,r=e.length,o=t.length;n<r;n++,o++)t[o]=e[n];return t}var nJ=0,Z7=function(){this.id=""+nJ++},rJ=kn.set,oJ=kn.getterFor("Array Iterator"),Zf=uD(Array,"Array",function(t,e){rJ(this,{type:"Array Iterator",target:Ia(t),index:0,kind:e})},function(){var t=oJ(this),e=t.target,n=t.kind,r=t.index++;return!e||r>=e.length?(t.target=void 0,{value:void 0,done:!0}):n=="keys"?{value:r,done:!1}:n=="values"?{value:e[r],done:!1}:{value:[r,e[r]],done:!1}},"values");Hl.Arguments=Hl.Array,ld("keys"),ld("values"),ld("entries");var Ul=function(t,e,n){for(var r in e)Un(t,r,e[r],n);return t},iJ=X.Array,aJ=Math.max,kE=function(t,e,n){for(var r=ps(t),o=$l(e,r),i=$l(n===void 0?r:n,r),a=iJ(aJ(i-o,0)),u=0;o<i;o++,u++)Wd(a,u,t[o]);return a.length=u,a},J7=Vd.f,Q7=typeof window=="object"&&window&&Object.getOwnPropertyNames?Object.getOwnPropertyNames(window):[],uJ={f:function(t){return Q7&&Zr(t)=="Window"?function(e){try{return J7(e)}catch{return kE(Q7)}}(t):J7(Ia(t))}},t9=Zt(function(){if(typeof ArrayBuffer=="function"){var t=new ArrayBuffer(8);Object.isExtensible(t)&&Object.defineProperty(t,"a",{value:8})}}),Wh=Object.isExtensible,mu=Zt(function(){Wh(1)})||t9?function(t){return!!ce(t)&&(!t9||Zr(t)!="ArrayBuffer")&&(!Wh||Wh(t))}:Wh,sJ=!Zt(function(){return Object.isExtensible(Object.preventExtensions({}))}),tm=Hp(function(t){var e=ro.f,n=!1,r=K5("meta"),o=0,i=function(u){e(u,r,{value:{objectID:"O"+o++,weakData:{}}})},a=t.exports={enable:function(){a.enable=function(){},n=!0;var u=Vd.f,s=pt([].splice),l={};l[r]=1,u(l).length&&(Vd.f=function(c){for(var f=u(c),p=0,d=f.length;p<d;p++)if(f[p]===r){s(f,p,1);break}return f},De({target:"Object",stat:!0,forced:!0},{getOwnPropertyNames:uJ.f}))},fastKey:function(u,s){if(!ce(u))return typeof u=="symbol"?u:(typeof u=="string"?"S":"P")+u;if(!Ie(u,r)){if(!mu(u))return"F";if(!s)return"E";i(u)}return u[r].objectID},getWeakData:function(u,s){if(!Ie(u,r)){if(!mu(u))return!0;if(!s)return!1;i(u)}return u[r].weakData},onFreeze:function(u){return sJ&&n&&mu(u)&&!Ie(u,r)&&i(u),u}};q1[r]=!0}),lJ=X.TypeError,Q0=function(t,e){this.stopped=t,this.result=e},e9=Q0.prototype,Kd=function(t,e,n){var r,o,i,a,u,s,l,c=n&&n.that,f=!(!n||!n.AS_ENTRIES),p=!(!n||!n.IS_ITERATOR),d=!(!n||!n.INTERRUPTED),v=Zu(e,c),g=function(y){return r&&wE(r,"normal",y),new Q0(!0,y)},m=function(y){return f?(Le(y),d?v(y[0],y[1],g):v(y[0],y[1])):d?v(y,g):v(y)};if(p)r=t;else{if(!(o=oD(t)))throw lJ(U1(t)+" is not iterable");if(lN(o)){for(i=0,a=ps(t);a>i;i++)if((u=m(t[i]))&&Yu(e9,u))return u;return new Q0(!1)}r=cN(t,o)}for(s=r.next;!(l=Ut(s,r)).done;){try{u=m(l.value)}catch(y){wE(r,"throw",y)}if(typeof u=="object"&&u&&Yu(e9,u))return u}return new Q0(!1)},cJ=X.TypeError,em=function(t,e){if(Yu(e,t))return t;throw cJ("Incorrect invo
|
|
|
|
|
`)}return o};function SN(t,e){if(!(t instanceof HTMLElement&&t.dataset.slateVoid==="true"))for(var n=t.childNodes,r=n.length;r--;){var o=n[r],i=o.nodeType;i==3?e(o,t):i!=1&&i!=9&&i!=11||SN(o,e)}}function p9(t){if(t.length===0)return"";var e=t[0];return e.nodeType!==yo.ELEMENT_NODE?"":e.tagName.toLowerCase()}(xn=yo||(yo={}))[xn.ELEMENT_NODE=1]="ELEMENT_NODE",xn[xn.TEXT_NODE=3]="TEXT_NODE",xn[xn.CDATA_SECTION_NODE=4]="CDATA_SECTION_NODE",xn[xn.PROCESSING_INSTRUCTION_NODE=7]="PROCESSING_INSTRUCTION_NODE",xn[xn.COMMENT_NODE=8]="COMMENT_NODE",xn[xn.DOCUMENT_NODE=9]="DOCUMENT_NODE",xn[xn.DOCUMENT_TYPE_NODE=10]="DOCUMENT_TYPE_NODE",xn[xn.DOCUMENT_FRAGMENT_NODE=11]="DOCUMENT_FRAGMENT_NODE";var NE=typeof navigator<"u"&&/Mac OS X/.test(navigator.userAgent),cd=typeof navigator<"u"&&/^(?!.*Seamonkey)(?=.*Firefox).*/i.test(navigator.userAgent),Zc=typeof navigator<"u"&&/Version\/[\d\.]+.*Safari/.test(navigator.userAgent),CJ=typeof navigator<"u"&&/Edge?\/(?:[0-6][0-9]|[0-7][0-8])(?:\.)/i.test(navigator.userAgent),xJ=typeof navigator<"u"&&/Chrome?\/(?:[0-7][0-5]|[0-6][0-9])(?:\.)/i.test(navigator.userAgent),IE=typeof navigator<"u"&&/Chrome/i.test(navigator.userAgent),Jc=!xJ&&!CJ&&typeof globalThis<"u"&&globalThis.InputEvent&&typeof globalThis.InputEvent.prototype.getTargetRanges=="function",A={getWindow:function(t){var e=DN.get(t);if(!e)throw new Error("Unable to find a host window element for this editor");return e},findKey:function(t,e){var n=eg.get(e);return n||(n=new Z7,eg.set(e,n)),n},setNewKey:function(t){var e=new Z7;eg.set(t,e)},findPath:function(t,e){for(var n=[],r=e;;){var o=Wl.get(r);if(o==null){if(E.isEditor(r))return n;break}var i=Yd.get(r);if(i==null)break;n.unshift(i),r=o}throw new Error("Unable to find the path for Slate node: "+JSON.stringify(e))},findDocumentOrShadowRoot:function(t){if(t.isDestroyed)return window.document;var e=A.toDOMNode(t,t),n=e.getRootNode();return(n instanceof Document||n instanceof ShadowRoot)&&n.getSelection!=null?n:e.ownerDocument},getParentNode:function(t,e){return Wl.get(e)||null},getParentsNodes:function(t,e){for(var n=[],r=e;r!==t&&r!=null;){var o=A.getParentNode(t,r);if(o==null)break;n.push(o),r=o}return n},getTopNode:function(t,e){var n=[A.findPath(t,e)[0]];return Q.get(t,n)},toDOMNode:function(t,e){var n;if(E.isEditor(e))n=mD.get(t);else{var r=A.findKey(t,e);n=PE.get(r)}if(!n)throw new Error("Cannot resolve a DOM node from Slate node: "+JSON.stringify(e));return n},hasDOMNode:function(t,e,n){n===void 0&&(n={});var r,o=n.editable,i=o!==void 0&&o,a=A.toDOMNode(t,t);try{r=$r(e)?e:e.parentElement}catch(u){if(!u.message.includes('Permission denied to access property "nodeType"'))throw u}return!!r&&r.closest("[data-slate-editor]")===a&&(!i||r.isContentEditable||!!r.getAttribute("data-slate-zero-width"))},toDOMRange:function(t,e){var n=e.anchor,r=e.focus,o=L.isBackward(e),i=A.toDOMPoint(t,n),a=L.isCollapsed(e)?i:A.toDOMPoint(t,r),u=A.getWindow(t).document.createRange(),s=Ht(o?a:i,2),l=s[0],c=s[1],f=Ht(o?i:a,2),p=f[0],d=f[1],v=!!($r(l)?l:l.parentElement).getAttribute("data-slate-zero-width"),g=!!($r(p)?p:p.parentElement).getAttribute("data-slate-zero-width");return u.setStart(l,v?1:c),u.setEnd(p,g?1:d),u},toDOMPoint:function(t,e){var n,r,o,i=Ht(E.node(t,e.path),1)[0],a=A.toDOMNode(t,i);E.void(t,{at:e})&&(e={path:e.path,offset:0});var u=Array.from(a.querySelectorAll("[data-slate-string], [data-slate-zero-width]")),s=0;try{for(var l=Dr(u),c=l.next();!c.done;c=l.next()){var f=c.value,p=f.childNodes[0];if(p!=null&&p.textContent!=null){var d=p.textContent.length,v=f.getAttribute("data-slate-length"),g=s+(v==null?d:parseInt(v,10));if(e.offset<=g){o=[p,Math.min(d,Math.max(0,e.offset-s))];break}s=g}}}catch(m){n={error:m}}finally{try{c&&!c.done&&(r=l.return)&&r.call(l)}finally{if(n)throw n.error}}if(!o)throw new Error("Cannot resolve a DOM point from Slate point: "+JSON.stringify(e));return o},toSlateNode:function(t,e){var n=$r(e)?e:e.parentElement;n&&!n.hasAttribute("data-slate-node")&&(n=n.closest("[data-slate-node]"));var r=n?dv.get(n):null;if(!r)throw new Error("Cannot resolve a Slate node from DOM
|
|
|
|
|
`)))&&f--}if(!c){if(i)return null;throw new Error("Cannot resolve a Slate point from DOM point: "+e)}var y=A.toSlateNode(t,c);return{path:A.findPath(t,y),offset:f}},hasRange:function(t,e){var n=e.anchor,r=e.focus;return E.hasPath(t,n.path)&&E.hasPath(t,r.path)},getNodeType:function(t){return ct.isElement(t)?t.type:""},checkNodeType:function(t,e){return this.getNodeType(t)===e},getNodesStr:function(t){return t.map(function(e){return Q.string(e)}).join("")},getSelectedElems:function(t){var e,n,r=[],o=E.nodes(t,{universal:!0});try{for(var i=Dr(o),a=i.next();!a.done;a=i.next()){var u=Ht(a.value,1)[0];ct.isElement(u)&&r.push(u)}}catch(s){e={error:s}}finally{try{a&&!a.done&&(n=i.return)&&n.call(i)}finally{if(e)throw e.error}}return r},getSelectedNodeByType:function(t,e){var n=this,r=Ht(E.nodes(t,{match:function(i){return n.checkNodeType(i,e)},universal:!0}),1),o=r[0];return o==null?null:o[0]},getSelectedTextNode:function(t){var e=Ht(E.nodes(t,{match:function(r){return ot.isText(r)},universal:!0}),1),n=e[0];return n==null?null:n[0]},isNodeSelected:function(t,e){var n=Ht(E.nodes(t,{match:function(o){return o===e},universal:!0}),1),r=n[0];return r!=null&&Ht(r,1)[0]===e},isSelectionAtLineEnd:function(t,e){var n=t.selection;return!!n&&(E.isEnd(t,n.anchor,e)||E.isEnd(t,n.focus,e))},getTextarea:function(t){var e=BE.get(t);if(e==null)throw new Error("Cannot find textarea instance by editor");return e},getToolbar:function(t){return nm.get(t)||null},getHoverbar:function(t){return fv.get(t)||null},normalizeContent:function(t){t.children.forEach(function(e,n){t.normalizeNode([e,[n]])})},getLeftLengthOfMaxLength:function(t){var e=t.getConfig(),n=e.maxLength,r=e.onMaxLength;if(typeof n!="number"||n<=0)return 1/0;var o=n-t.getText().replace(/\r|\n|(\r\n)/g,"").length;return o<=0&&r&&r(t),o},cleanExposedTexNodeInSelectionBlock:function(t){var e,n,r,o,i=A.getTextarea(t).$textArea,a=i==null?void 0:i[0].childNodes;if(a)try{for(var u=Dr(Array.from(a)),s=u.next();!s.done;s=u.next()){var l=s.value;if(l.nodeType!==3)break;l.remove()}}catch(g){e={error:g}}finally{try{s&&!s.done&&(n=u.return)&&n.call(u)}finally{if(e)throw e.error}}var c=E.nodes(t,{match:function(g){return!(!ct.isElement(g)||t.isInline(g))},universal:!0});try{for(var f=Dr(c),p=f.next();!p.done;p=f.next()){var d=p.value;if(d!=null){var v=d[0];SN(A.toDOMNode(t,v),function(g,m){var y=B(m);y.attr("data-slate-string")||y.attr("data-slate-zero-width")||y.attr("data-w-e-reserve")||m.removeChild(g)})}}}catch(g){r={error:g}}finally{try{p&&!p.done&&(o=f.return)&&o.call(f)}finally{if(r)throw r.error}}},isLastNode:function(t,e){var n=t.children||[];return n[n.length-1]===e},genEmptyParagraph:function(){return{type:"paragraph",children:[{text:""}]}},isSelectedVoidNode:function(t){var e,n,r=E.nodes(t,{match:function(u){return t.isVoid(u)}}),o=0;try{for(var i=Dr(r),a=i.next();!a.done;a=i.next())a.value,o++}catch(u){e={error:u}}finally{try{a&&!a.done&&(n=i.return)&&n.call(i)}finally{if(e)throw e.error}}return o>0},isSelectedEmptyParagraph:function(t){var e=t.selection;if(e==null||L.isExpanded(e))return!1;var n=A.getSelectedNodeByType(t,"paragraph");if(n===null)return!1;var r=n.children;return r.length===1&&(r[0].text===""||void 0)},isEmptyPath:function(t,e){var n=E.node(t,e);if(n==null)return!1;var r=Ht(n,1)[0].children;return r.length===1&&r[0].text===""}},SJ=1,AN={},Xd={},AJ=cc.filter,OJ=J1("filter");De({target:"Array",proto:!0,forced:!OJ},{filter:function(t){return AJ(this,t,arguments.length>1?arguments[1]:void 0)}});var LE=`
|
|
|
|
|
\v\f\r \u2028\u2029\uFEFF`,h9=pt("".replace),hv="["+LE+"]",kJ=RegExp("^"+hv+hv+"*"),BJ=RegExp(hv+hv+"*$"),pb=function(t){return function(e){var n=ue(_r(e));return 1&t&&(n=h9(n,kJ,"")),2&t&&(n=h9(n,BJ,"")),n}},FJ={start:pb(1),end:pb(2),trim:pb(3)},TJ=sc.PROPER,_J=FJ.trim;De({target:"String",proto:!0,forced:function(t){return Zt(function(){return!!LE[t]()||"
"[t]()!=="
"||TJ&&LE[t].name!==t})}("trim")},{trim:function(){return _J(this)}});var RE=[],ON={};function PJ(t,e,n){var r=n.isInline(t)?"span":"div";return"<"+r+">"+e+"</"+r+">"}var Zd,Fs,g9,hb,gv=X.Promise,v9=xe("species"),bD=function(t){var e=ds(t),n=ro.f;an&&e&&!e[v9]&&n(e,v9,{configurable:!0,get:function(){return this}})},jJ=X.TypeError,NJ=xe("species"),kN=function(t,e){var n,r=Le(t).constructor;return r===void 0||(n=Le(r)[NJ])==null?e:function(o){if(X1(o))return o;throw jJ(U1(o)+" is not a constructor")}(n)},BN=pt([].slice),FN=/(?:ipad|iphone|ipod).*applewebkit/i.test(hl),ia=Zr(X.process)=="process",ME=X.setImmediate,zE=X.clearImmediate,IJ=X.process,gb=X.Dispatch,LJ=X.Function,m9=X.MessageChannel,RJ=X.String,vb=0,fd={};try{Zd=X.location}catch{}var wD=function(t){if(Ie(fd,t)){var e=fd[t];delete fd[t],e()}},mb=function(t){return function(){wD(t)}},y9=function(t){wD(t.data)},b9=function(t){X.postMessage(RJ(t),Zd.protocol+"//"+Zd.host)};ME&&zE||(ME=function(t){var e=BN(arguments,1);return fd[++vb]=function(){dD(re(t)?t:LJ(t),void 0,e)},Fs(vb),vb},zE=function(t){delete fd[t]},ia?Fs=function(t){IJ.nextTick(mb(t))}:gb&&gb.now?Fs=function(t){gb.now(mb(t))}:m9&&!FN?(hb=(g9=new m9).port2,g9.port1.onmessage=y9,Fs=Zu(hb.postMessage,hb)):X.addEventListener&&re(X.postMessage)&&!X.importScripts&&Zd&&Zd.protocol!=="file:"&&!Zt(b9)?(Fs=b9,X.addEventListener("message",y9,!1)):Fs="onreadystatechange"in Hd("script")?function(t){mE.appendChild(Hd("script")).onreadystatechange=function(){mE.removeChild(this),wD(t)}}:function(t){setTimeout(mb(t),0)});var Qc,pu,dd,nl,yb,bb,wb,w9,TN={set:ME,clear:zE},MJ=/ipad|iphone|ipod/i.test(hl)&&X.Pebble!==void 0,zJ=/web0s(?!.*chrome)/i.test(hl),$J=Up.f,Eb=TN.set,E9=X.MutationObserver||X.WebKitMutationObserver,D9=X.document,C9=X.process,Xh=X.Promise,x9=$J(X,"queueMicrotask"),_N=x9&&x9.value;_N||(Qc=function(){var t,e;for(ia&&(t=C9.domain)&&t.exit();pu;){e=pu.fn,pu=pu.next;try{e()}catch(n){throw pu?nl():dd=void 0,n}}dd=void 0,t&&t.enter()},FN||ia||zJ||!E9||!D9?!MJ&&Xh&&Xh.resolve?((wb=Xh.resolve(void 0)).constructor=Xh,w9=Zu(wb.then,wb),nl=function(){w9(Qc)}):ia?nl=function(){C9.nextTick(Qc)}:(Eb=Zu(Eb,X),nl=function(){Eb(Qc)}):(yb=!0,bb=D9.createTextNode(""),new E9(Qc).observe(bb,{characterData:!0}),nl=function(){bb.data=yb=!yb}));var Db,S9,PN,A9,jN=_N||function(t){var e={fn:t,next:void 0};dd&&(dd.next=e),pu||(pu=e,nl()),dd=e},HJ=function(t){var e,n;this.promise=new t(function(r,o){if(e!==void 0||n!==void 0)throw TypeError("Bad Promise constructor");e=r,n=o}),this.resolve=xa(e),this.reject=xa(n)},ED={f:function(t){return new HJ(t)}},$E=function(t){try{return{error:!1,value:t()}}catch(e){return{error:!0,value:e}}},VJ=typeof window=="object",NN=TN.set,UJ=xe("species"),go="Promise",O9=kn.getterFor(go),WJ=kn.set,GJ=kn.getterFor(go),uu=gv&&gv.prototype,bo=gv,tf=uu,IN=X.TypeError,HE=X.document,DD=X.process,vl=ED.f,qJ=vl,KJ=!!(HE&&HE.createEvent&&X.dispatchEvent),LN=re(X.PromiseRejectionEvent),RN=!1,pd=Ud(go,function(){var t=G1(bo),e=t!==String(bo);if(!e&&$d===66)return!0;if($d>=51&&/native code/.test(t))return!1;var n=new bo(function(o){o(1)}),r=function(o){o(function(){},function(){})};return(n.constructor={})[UJ]=r,!(RN=n.then(function(){})instanceof r)||!e&&VJ&&!LN}),YJ=pd||!iD(function(t){bo.all(t).catch(function(){})}),MN=function(t){var e;return!(!ce(t)||!re(e=t.then))&&e},CD=function(t,e){if(!t.notified){t.notified=!0;var n=t.reactions;jN(function(){for(var r=t.value,o=t.state==1,i=0;n.length>i;){var a,u,s,l=n[i++],c=o?l.ok:l.fail,f=l.resolve,p=l.reject,d=l.domain;try{c?(o||(t.rejection===2&&ZJ(t),t.rejection=1),c===!0?a=r:(d&&d.enter(),a=c(r),d&&(d.exit(),s=!0)),a===l.promise?p(IN("Promis
|
|
|
|
|
`)>=0)return;c&&(c=qN(c),N9(u,c)||u.push({text:c}))}}else{if(l.nodeName==="BR")return void(N9(u,`
|
|
|
|
|
`)||u.push({text:`
|
|
|
|
|
`}));var f=SD(B(l),a);Array.isArray(f)?f.forEach(function(p){return u.push(p)}):u.push(f)}}),u)}(t,e),r=function(i){for(var a in vv)if(i[0].matches(a))return vv[a];return hQ}(t),o=r(t[0],n,e);return Array.isArray(o)||(o=[o]),o.forEach(function(i){E.isVoid(e,i)||(n.length===0&&(i.children=[{text:t.text().replace(/\s+/gm," ")}]),xD.forEach(function(a){i=a(t[0],i,e)}))}),o}function Sb(t,e){t.parents("pre").length===0&&(t[0].innerHTML=t[0].innerHTML.replace(/\s+/gm," ").replace(/<br>/g,`
|
|
|
|
|
`));var n=t[0].textContent||"";n=function(o){return o.replace(/ /g," ").replace(/</g,"<").replace(/>/g,">").replace(/®/g,"®").replace(/©/g,"©").replace(/™/g,"™").replace(/"/g,'"')}(n);var r={text:n=qN(n)};return xD.forEach(function(o){r=o(t[0],r,e)}),r}function SD(t,e){WN.forEach(function(r){var o=r.selector,i=r.preParseHtml;t[0].matches(o)&&(t=B(i(t[0])))});var n=p9(t);return n==="span"?t.attr("data-w-e-type")?xb(t,e):Sb(t,e):n==="code"?p9(t.parent())==="pre"?xb(t,e):Sb(t,e):UN.includes(n)?Sb(t,e):xb(t,e)}function KN(t,e,n){var r=B(n);return!!r.attr(e)||(r.attr(e,"true"),t.on("destroyed",function(){r.removeAttr(e)}),!1)}function I9(t,e){e===void 0&&(e="");var n=[];e===""&&(e="<p><br></p>"),e.indexOf("<")!==0&&(e=e.split(/\n/).map(function(o){return"<p>"+o+"</p>"}).join(""));var r=B("<div>"+e+"</div>");return Array.from(r.children()).forEach(function(o){var i=SD(B(o),t);Array.isArray(i)?i.forEach(function(a){return n.push(a)}):n.push(i)}),n}var gQ=ro.f,L9=tm.fastKey,R9=kn.set,Ab=kn.getterFor,vQ={getConstructor:function(t,e,n,r){var o=t(function(l,c){em(l,i),R9(l,{type:e,index:Z1(null),first:void 0,last:void 0,size:0}),an||(l.size=0),c!=null&&Kd(c,l[r],{that:l,AS_ENTRIES:n})}),i=o.prototype,a=Ab(e),u=function(l,c,f){var p,d,v=a(l),g=s(l,c);return g?g.value=f:(v.last=g={index:d=L9(c,!0),key:c,value:f,previous:p=v.last,next:void 0,removed:!1},v.first||(v.first=g),p&&(p.next=g),an?v.size++:l.size++,d!=="F"&&(v.index[d]=g)),l},s=function(l,c){var f,p=a(l),d=L9(c);if(d!=="F")return p.index[d];for(f=p.first;f;f=f.next)if(f.key==c)return f};return Ul(i,{clear:function(){for(var l=a(this),c=l.index,f=l.first;f;)f.removed=!0,f.previous&&(f.previous=f.previous.next=void 0),delete c[f.index],f=f.next;l.first=l.last=void 0,an?l.size=0:this.size=0},delete:function(l){var c=this,f=a(c),p=s(c,l);if(p){var d=p.next,v=p.previous;delete f.index[p.index],p.removed=!0,v&&(v.next=d),d&&(d.previous=v),f.first==p&&(f.first=d),f.last==p&&(f.last=v),an?f.size--:c.size--}return!!p},forEach:function(l){for(var c,f=a(this),p=Zu(l,arguments.length>1?arguments[1]:void 0);c=c?c.next:f.first;)for(p(c.value,c.key,this);c&&c.removed;)c=c.previous},has:function(l){return!!s(this,l)}}),Ul(i,n?{get:function(l){var c=s(this,l);return c&&c.value},set:function(l,c){return u(this,l===0?0:l,c)}}:{add:function(l){return u(this,l=l===0?0:l,l)}}),an&&gQ(i,"size",{get:function(){return a(this).size}}),o},setStrong:function(t,e,n){var r=e+" Iterator",o=Ab(e),i=Ab(r);uD(t,e,function(a,u){R9(this,{type:r,target:a,state:o(a),kind:u,last:void 0})},function(){for(var a=i(this),u=a.kind,s=a.last;s&&s.removed;)s=s.previous;return a.target&&(a.last=s=s?s.next:a.state.first)?u=="keys"?{value:s.key,done:!1}:u=="values"?{value:s.value,done:!1}:{value:[s.key,s.value],done:!1}:(a.target=void 0,{value:void 0,done:!0})},n?"entries":"values",!n,!0),bD(e)}};mN("Set",function(t){return function(){return t(this,arguments.length?arguments[0]:void 0)}},vQ);var M9=new Set(["doctype","!doctype","meta","script","style","link","frame","iframe","title","svg"]);function z9(t,e){t.isInline(e)?(t.insertNode(e),e.type==="link"&&t.insertFragment([{text:""}])):N.insertNodes(t,e,{mode:"highest"})}var mQ=function(t){var e=t,n=e.insertText;return e.insertFragment,e.setFragmentData=function(r){var o=e.selection;if(o){var i=Ht(L.edges(o),2),a=i[0],u=i[1],s=E.void(e,{at:a.path}),l=E.void(e,{at:u.path});if(!L.isCollapsed(o)||s){var c=A.toDOMRange(e,o),f=c.cloneContents(),p=f.childNodes[0];if(f.childNodes.forEach(function(D){D.textContent&&D.textContent.trim()!==""&&(p=D)}),l){var d=Ht(l,1)[0],v=c.cloneRange(),g=A.toDOMNode(e,d);v.setEndAfter(g),f=v.cloneContents()}if(s&&(p=f.querySelector("[data-slate-spacer]")),Array.from(f.querySelectorAll("[data-slate-zero-width]")).forEach(function(D){var x=D.getAttribute("data-slate-zero-width")==="n";D.textContent=x?`
|
|
|
|
|
`:""}),CN(p)){var m=p.ownerDocument.createElement("span");m.style.whiteSpace="pre",m.appendChild(p),f.appendChild(m),p=m}var y=e.getFragment(),h=JSON.stringify(y),b=window.btoa(encodeURIComponent(h));p.setAttribute("data-slate-fragment",b),r.setData("application/x-slate-fragment",b);var w=f.ownerDocument.createElement("div");return w.appendChild(f),w.setAttribute("hidden","true"),f.ownerDocument.body.appendChild(w),r.setData("text/html",w.innerHTML),r.setData("text/plain",DJ(w)),f.ownerDocument.body.removeChild(w),r}}},e.insertData=function(r){var o,i,a=r.getData("application/x-slate-fragment");if(a){var u=decodeURIComponent(window.atob(a)),s=JSON.parse(u);e.insertFragment(s)}else{var l=r.getData("text/plain"),c=r.getData("text/html");if(c)e.dangerouslyInsertHtml(c);else if(l){var f=l.split(/\r\n|\r|\n/),p=!1;try{for(var d=Dr(f),v=d.next();!v.done;v=d.next()){var g=v.value;p&&N.splitNodes(e,{always:!0}),n(g),p=!0}}catch(m){o={error:m}}finally{try{v&&!v.done&&(i=d.return)&&i.call(d)}finally{if(o)throw o.error}}}}},e},Jf=function(t){return t!=null},yQ={object:!0,function:!0,undefined:!0},bQ=/^\s*class[\s{/}]/,wQ=Function.prototype.toString,$9=function(t){return!!function(e){if(typeof e!="function"||!hasOwnProperty.call(e,"length"))return!1;try{if(typeof e.length!="number"||typeof e.call!="function"||typeof e.apply!="function")return!1}catch{return!1}return!function(n){if(!function(r){return!!Jf(r)&&hasOwnProperty.call(yQ,typeof r)}(n))return!1;try{return!!n.constructor&&n.constructor.prototype===n}catch{return!1}}(e)}(t)&&!bQ.test(wQ.call(t))},AD=function(t){return t!=null},EQ=Object.keys,DQ=function(){try{return Object.keys("primitive"),!0}catch{return!1}}()?Object.keys:function(t){return EQ(AD(t)?Object(t):t)},CQ=function(t){if(!AD(t))throw new TypeError("Cannot use null or undefined");return t},xQ=Math.max,H9=function(){var t,e=Object.assign;return typeof e=="function"&&(e(t={foo:"raz"},{bar:"dwa"},{trzy:"trzy"}),t.foo+t.bar+t.trzy==="razdwatrzy")}()?Object.assign:function(t,e){var n,r,o,i=xQ(arguments.length,2);for(t=Object(CQ(t)),o=function(a){try{t[a]=e[a]}catch(u){n||(n=u)}},r=1;r<i;++r)DQ(e=arguments[r]).forEach(o);if(n!==void 0)throw n;return t},SQ=Array.prototype.forEach,AQ=Object.create,OQ=function(t,e){var n;for(n in t)e[n]=t[n]},V9=function(t){var e=AQ(null);return SQ.call(arguments,function(n){AD(n)&&OQ(Object(n),e)}),e},Ob="razdwatrzy",kQ=String.prototype.indexOf,nf=typeof Ob.contains=="function"&&Ob.contains("dwa")===!0&&Ob.contains("foo")===!1?String.prototype.contains:function(t){return kQ.call(this,t,arguments[1])>-1},Jh=Hp(function(t){var e=t.exports=function(n,r){var o,i,a,u,s;return arguments.length<2||typeof n!="string"?(u=r,r=n,n=null):u=arguments[2],Jf(n)?(o=nf.call(n,"c"),i=nf.call(n,"e"),a=nf.call(n,"w")):(o=a=!0,i=!1),s={value:r,configurable:o,enumerable:i,writable:a},u?H9(V9(u),s):s};e.gs=function(n,r,o){var i,a,u,s;return typeof n!="string"?(u=o,o=r,r=n,n=null):u=arguments[3],Jf(r)?$9(r)?Jf(o)?$9(o)||(u=o,o=void 0):o=void 0:(u=r,r=o=void 0):r=void 0,Jf(n)?(i=nf.call(n,"c"),a=nf.call(n,"e")):(i=!0,a=!1),s={get:r,set:o,configurable:i,enumerable:a},u?H9(V9(u),s):s}}),kb=function(t){if(typeof t!="function")throw new TypeError(t+" is not a function");return t},BQ=Hp(function(t,e){var n,r,o,i,a,u,s,l=Function.prototype.apply,c=Function.prototype.call,f=Object.create,p=Object.defineProperty,d=Object.defineProperties,v=Object.prototype.hasOwnProperty,g={configurable:!0,enumerable:!1,writable:!0};n=function(m,y){var h;return kb(y),v.call(this,"__ee__")?h=this.__ee__:(h=g.value=f(null),p(this,"__ee__",g),g.value=null),h[m]?typeof h[m]=="object"?h[m].push(y):h[m]=[h[m],y]:h[m]=y,this},r=function(m,y){var h,b;return kb(y),b=this,n.call(this,m,h=function(){o.call(b,m,h),l.call(y,this,arguments)}),h.__eeOnceListener__=y,this},o=function(m,y){var h,b,w,D;if(kb(y),!v.call(this,"__ee__"))return this;if(!(h=this.__ee__)[m])return this;if(typeof(b=h[m])=="object")for(D=0;w=b[D];++D)w!==y&&w.__eeOnceListener__!==y||(b.length===2?h[m]=b[D?0:1]:b.splice(D,1));else b!==y&&b.__eeOnceListener__!==y||delete h[m];retur
|
|
|
|
|
`:t)}function Fb(t,e){return t===void 0&&(t=0),e===void 0&&(e=!1),bt("span",{"data-slate-zero-width":e?"n":"z","data-slate-length":t},"\uFEFF",e?bt("br",null):null)}function GE(t,e,n,r){return Yd.set(t,e),Wl.set(t,n),ct.isElement(t)?function(o,i){var a,u=A.findKey(i,o),s=i.isInline(o),l=E.isVoid(i,o),c=VN(u.id),f={id:c,key:u.id,"data-slate-node":"element","data-slate-inline":s},p=o.type,d=o.children,v=d===void 0?[]:d,g=function(D){return ZN[D]||$Q}(p);a=l?null:v.map(function(D,x){return GE(D,x,o,i)});var m=g(o,a,i);if(l){f["data-slate-void"]=!0;var y=s?"span":"div",h=Ht(Q.texts(o),1),b=Ht(h[0],1)[0],w=bt(y,{"data-slate-spacer":!0,style:{height:"0",color:"transparent",outline:"none",position:"absolute"}},GE(b,0,o,i));m=bt(y,{style:{position:"relative"}},m,w),Yd.set(b,0),Wl.set(b,o)}return m.data==null&&(m.data={}),Object.assign(m.data,f),l||s||(m=function(D,x){var C=x;return WE.forEach(function(O){C=O(D,x)}),C}(o,m)),Pr(function(){var D=jE(c);D!=null&&(PE.set(u,D),pv.set(o,D),dv.set(D,o))}),m}(t,r):function(o,i,a){if(o.text==null)throw new Error("Current node is not slate Text "+JSON.stringify(o));var u=A.findKey(a,o),s=a.getConfig().decorate;if(s==null)throw new Error("Can not get config.decorate");var l=A.findPath(a,o),c=s([o,l]),f=ot.decorations(o,c),p=f.map(function(g,m){var y=function(h,b,w,D,x){b===void 0&&(b=!1);var C=h.text,O=A.findPath(x,w),T=j.parent(O);if(E.isEditor(D))throw new Error("Text node "+JSON.stringify(w)+" parent is Editor");return x.isVoid(D)?Fb(Q.string(D).length):C!==""||D.children[D.children.length-1]!==w||x.isInline(D)||E.string(x,T)!==""?C===""?Fb():b&&C.slice(-1)===`
|
|
|
|
|
`?K9(C,!0):K9(C):Fb(0,!0)}(g,m===f.length-1,o,i,a);return y=function(h,b){var w=b;return WE.forEach(function(D){w=D(h,w)}),w}(g,y),bt("span",{"data-slate-leaf":!0},y)}),d=function(g){return"w-e-text-"+g}(u.id),v=bt("span",{"data-slate-node":"text",id:d,key:u.id},p);return Pr(function(){var g=jE(d);g!=null&&(PE.set(u,g),pv.set(o,g),dv.set(g,o))}),v}(t,n,r)}function HQ(t,e){var n,r=t.$scroll,o=function(g){return"w-e-textarea-"+g}(t.id),i=e.getConfig(),a=i.readOnly,u=i.autoFocus,s=function(g,m){return m===void 0&&(m=!1),zl("div#"+g,{props:{contentEditable:!m}})}(o,a),l=e.children||[];s.children=l.map(function(g,m){var y=GE(g,m,e,e);return XN(y),y});var c=u9.get(t);if(c==null&&(c=!0),c){var f=function(g,m){return B(`<div
|
|
|
|
|
id="`+g+`"
|
|
|
|
|
data-slate-editor
|
|
|
|
|
data-slate-node="value"
|
|
|
|
|
suppressContentEditableWarning
|
|
|
|
|
role="textarea"
|
|
|
|
|
spellCheck="true"
|
|
|
|
|
autoCorrect="true"
|
|
|
|
|
autoCapitalize="true"
|
|
|
|
|
></div>`)}(o);r.append(f),t.$textArea=f,n=f[0],(d=_q([jq,Rq,zq,Nq,Lq,Pq]))(n,s),u9.set(t,!1),s9.set(t,d)}else{var p=l9.get(t),d=s9.get(t);if(p==null||d==null)return;n=p.elm,d(p,s)}if(n!=null||(n=jE(o))!=null){if((c?u:e.isFocused())&&n.focus({preventScroll:!0}),c){var v=yD(n);v&&DN.set(e,v)}mD.set(e,n),pv.set(e,n),dv.set(n,e),l9.set(t,s)}}function Y9(t){return typeof t=="object"&&t!=null&&t.nodeType===1}function X9(t,e){return(!e||t!=="hidden")&&t!=="visible"&&t!=="clip"}function Tb(t,e){if(t.clientHeight<t.scrollHeight||t.clientWidth<t.scrollWidth){var n=getComputedStyle(t,null);return X9(n.overflowY,e)||X9(n.overflowX,e)||function(r){var o=function(i){if(!i.ownerDocument||!i.ownerDocument.defaultView)return null;try{return i.ownerDocument.defaultView.frameElement}catch{return null}}(r);return!!o&&(o.clientHeight<r.scrollHeight||o.clientWidth<r.scrollWidth)}(t)}return!1}function t0(t,e,n,r,o,i,a,u){return i<t&&a>e||i>t&&a<e?0:i<=t&&u<=n||a>=e&&u>=n?i-t-r:a>e&&u<n||i<t&&u>n?a-e+o:0}function Z9(t,e){var n=window,r=e.scrollMode,o=e.block,i=e.inline,a=e.boundary,u=e.skipOverflowHiddenElements,s=typeof a=="function"?a:function(Dt){return Dt!==a};if(!Y9(t))throw new TypeError("Invalid target");for(var l=document.scrollingElement||document.documentElement,c=[],f=t;Y9(f)&&s(f);){if((f=f.parentElement)===l){c.push(f);break}f!=null&&f===document.body&&Tb(f)&&!Tb(document.documentElement)||f!=null&&Tb(f,u)&&c.push(f)}for(var p=n.visualViewport?n.visualViewport.width:innerWidth,d=n.visualViewport?n.visualViewport.height:innerHeight,v=window.scrollX||pageXOffset,g=window.scrollY||pageYOffset,m=t.getBoundingClientRect(),y=m.height,h=m.width,b=m.top,w=m.right,D=m.bottom,x=m.left,C=o==="start"||o==="nearest"?b:o==="end"?D:b+y/2,O=i==="center"?x+h/2:i==="end"?w:x,T=[],R=0;R<c.length;R++){var H=c[R],M=H.getBoundingClientRect(),K=M.height,U=M.width,W=M.top,q=M.right,nt=M.bottom,lt=M.left;if(r==="if-needed"&&b>=0&&x>=0&&D<=d&&w<=p&&b>=W&&D<=nt&&x>=lt&&w<=q)return T;var st=getComputedStyle(H),at=parseInt(st.borderLeftWidth,10),k=parseInt(st.borderTopWidth,10),S=parseInt(st.borderRightWidth,10),P=parseInt(st.borderBottomWidth,10),$=0,Y=0,V="offsetWidth"in H?H.offsetWidth-H.clientWidth-at-S:0,it="offsetHeight"in H?H.offsetHeight-H.clientHeight-k-P:0;if(l===H)$=o==="start"?C:o==="end"?C-d:o==="nearest"?t0(g,g+d,d,k,P,g+C,g+C+y,y):C-d/2,Y=i==="start"?O:i==="center"?O-p/2:i==="end"?O-p:t0(v,v+p,p,at,S,v+O,v+O+h,h),$=Math.max(0,$+g),Y=Math.max(0,Y+v);else{$=o==="start"?C-W-k:o==="end"?C-nt+P+it:o==="nearest"?t0(W,nt,K,k,P+it,C,C+y,y):C-(W+K/2)+it/2,Y=i==="start"?O-lt-at:i==="center"?O-(lt+U/2)+V/2:i==="end"?O-q+S+V:t0(lt,q,U,at,S+V,O,O+h,h);var gt=H.scrollLeft,vt=H.scrollTop;C+=vt-($=Math.max(0,Math.min(vt+$,H.scrollHeight-K+it))),O+=gt-(Y=Math.max(0,Math.min(gt+Y,H.scrollWidth-U+V)))}T.push({el:H,top:$,left:Y})}return T}function J9(t){return t===Object(t)&&Object.keys(t).length!==0}function yr(t,e){return Ju(e)&&A.hasDOMNode(t,e,{editable:!0})}function Q9(t,e){if(t.getConfig().readOnly)return!1;var n=ol(t,e)&&A.toSlateNode(t,e);return E.isVoid(t,n)}function ol(t,e){return Ju(e)&&A.hasDOMNode(t,e)}function JN(t,e,n){n===void 0&&(n=!1);var r=e.selection,o=e.getConfig(),i=A.findDocumentOrShadowRoot(e).getSelection();if(i&&(!t.isComposing||n)&&e.isFocused()){var a=i.type!=="None";if(r||a){var u=mD.get(e),s=!1;if(u.contains(i.anchorNode)&&u.contains(i.focusNode)&&(s=!0),a&&s&&r){var l=A.toSlateRange(e,i,{exactMatch:!0,suppressThrow:!0});if(l&&L.equals(l,r)){var c=!0;if(L.isCollapsed(r)){var f=i.anchorNode,p=i.anchorOffset;if(f===u){var d=u.childNodes,v=void 0;(v=d[p])&&v.matches("table")&&(c=!1),(v=d[p-1])&&v.matches("table")&&(c=!1)}}if(c)return}}if(!r||A.hasRange(e,r)){t.isUpdatingSelection=!0;var g=r&&A.toDOMRange(e,r);if(g){L.isBackward(r)?i.setBaseAndExtent(g.endContainer,g.endOffset,g.startContainer,g.startOffset):i.setBaseAndExtent(g.startContainer,g.startOffset,g.endContainer,g.endOffset);var m=g.startContainer.parentElement;if(!m.closest("[data-slate-spacer]")){m.getBoundingClientRect=g.getBoundingClientRect.bind(g);var y=document.body;(
|
|
|
|
|
`+r:n;t.attr("data-tooltip",a),t.addClass("w-e-menu-tooltip-v5")}}}pD("match",function(t,e,n){return[function(r){var o=_r(this),i=r==null?void 0:Xu(r,t);return i?Ut(i,r,o):new RegExp(r)[t](ue(o))},function(r){var o=Le(this),i=ue(r),a=n(e,o,i);if(a.done)return a.value;if(!o.global)return qd(o,i);var u=o.unicode;o.lastIndex=0;for(var s,l=[],c=0;(s=qd(o,i))!==null;){var f=ue(s[0]);l[c]=f,f===""&&(o.lastIndex=hD(i,lc(o.lastIndex),u)),c++}return c===0?null:l}]});var _D=function(){function t(e,n,r){var o=this;r===void 0&&(r=!1),this.$elem=B('<div class="w-e-bar-item"></div>'),this.$button=B('<button type="button"></button>'),this.disabled=!1,this.menu=n;var i=n.tag,a=n.width;if(i!=="button")throw new Error("Invalid tag '"+i+"', expected 'button'");var u=n.title,s=n.hotkey,l=s===void 0?"":s,c=n.iconSvg,f=c===void 0?"":c,p=this.$button;if(f){var d=B(f);FD(d),p.append(d)}else p.text(u);tI(p,f,u,l,r),r&&f&&p.append(B('<span class="title">'+u+"</span>")),a&&p.css("width",a+"px"),p.attr("data-menu-key",e),this.$elem.append(p),Pr(function(){return o.init()})}return t.prototype.init=function(){var e=this;this.setActive(),this.setDisabled(),this.$button.on("click",function(n){n.preventDefault(),er(e).hidePanelOrModal(),e.disabled||(e.exec(),e.onButtonClick())})},t.prototype.exec=function(){var e=er(this),n=this.menu,r=n.getValue(e);n.exec(e,r)},t.prototype.setActive=function(){var e=er(this),n=this.$button,r="active";this.menu.isActive(e)?n.addClass(r):n.removeClass(r)},t.prototype.setDisabled=function(){var e=er(this),n=this.$button,r=this.menu.isDisabled(e);(e.selection==null||e.isDisabled())&&(r=!0),this.menu.alwaysEnable&&(r=!1);var o="disabled";r?n.addClass(o):n.removeClass(o),this.disabled=r},t.prototype.changeMenuState=function(){this.setActive(),this.setDisabled()},t}(),YQ=function(t){function e(n,r,o){return o===void 0&&(o=!1),t.call(this,n,r,o)||this}return fc(e,t),e.prototype.onButtonClick=function(){},e}(_D),PD=function(){function t(e){this.isShow=!1,this.showTime=0,this.record(e)}return t.prototype.record=function(e){var n=_E.get(e);n==null&&(n=new Set,_E.set(e,n)),n.add(this),tg.set(this,e)},t.prototype.renderContent=function(e){var n=this.$elem;n.empty(),n.append(e);var r=this.genSelfElem();r&&n.append(r)},t.prototype.appendTo=function(e){var n=this.$elem;e.append(n)},t.prototype.show=function(){if(!this.isShow){this.showTime=Date.now(),this.$elem.show(),this.isShow=!0;var e=tg.get(this);e&&e.emit("modalOrPanelShow",this)}},t.prototype.hide=function(){if(this.isShow&&!(Date.now()-this.showTime<200)){this.$elem.hide(),this.isShow=!1;var e=tg.get(this);e&&e.emit("modalOrPanelHide")}},t}(),XQ=function(t){function e(n){var r=t.call(this,n)||this;return r.type="dropPanel",r.$elem=B('<div class="w-e-drop-panel"></div>'),r}return fc(e,t),e.prototype.genSelfElem=function(){return null},e}(PD),ZQ=function(t){function e(n,r,o){o===void 0&&(o=!1);var i=t.call(this,n,r,o)||this;if(i.dropPanel=null,i.menu=r,r.showDropPanel){var a=TD();i.$button.append(a)}return i}return fc(e,t),e.prototype.onButtonClick=function(){this.menu.showDropPanel&&this.handleDropPanel()},e.prototype.handleDropPanel=function(){var n=this.menu;if(n.getPanelContentElem!=null){var r=er(this);if(this.dropPanel==null){var o=new XQ(r),i=n.getPanelContentElem(r);o.renderContent(i),o.appendTo(this.$elem),o.show(),this.dropPanel=o}else{var a=this.dropPanel;a.isShow?a.hide():(i=n.getPanelContentElem(r),a.renderContent(i),a.show())}var u=this.dropPanel;if(u.isShow){var s=this.$elem,l=s.offset().left,c=s.parents(".w-e-bar");l-c.offset().left>=c.width()/2?u.$elem.css({left:"none",right:"0"}):u.$elem.css({left:"0",right:"none"})}}},e}(_D),JQ=function(t){function e(n,r){r===void 0&&(r=0);var o=t.call(this,n)||this;o.type="modal",o.$elem=B('<div class="w-e-modal"></div>'),o.width=0,r&&(o.width=r);var i=o.$elem;return i.on("click",function(a){return a.stopPropagation()}),i.on("keyup",function(a){a.code==="Escape"&&(o.hide(),n.restoreSelection())}),o}return fc(e,t),e.prototype.genSelfElem=function(){var n=this,r=B('<span class="btn-close"><svg viewBox="0 0 1024 1024"><path d="
|
|
|
|
|
`)},h.getSelectionText=function(){var C=h.selection;return C==null?"":E.string(y,C)},h.getElemsByType=function(C,O){var T,R;O===void 0&&(O=!1);var H=[],M=E.nodes(h,{at:[],universal:!0});try{for(var K=Dr(M),U=K.next();!U.done;U=K.next()){var W=Ht(U.value,1)[0];if(ct.isElement(W)&&(O?W.type.indexOf(C)>=0:W.type===C)){var q=VN(A.findKey(h,W).id);H.push(Er(Er({},W),{id:q}))}}}catch(nt){T={error:nt}}finally{try{U&&!U.done&&(R=K.return)&&R.call(K)}finally{if(T)throw T.error}}return H},h.getElemsByTypePrefix=function(C){return h.getElemsByType(C,!0)},h.isEmpty=function(){var C=h.children,O=C===void 0?[]:C;if(O.length>1)return!1;var T=O[0];if(T==null)return!0;if(ct.isElement(T)&&T.type==="paragraph"){var R=T.children,H=R===void 0?[]:R;if(H.length>1)return!1;var M=H[0];if(M==null||ot.isText(M)&&M.text==="")return!0}return!1},h.clear=function(){N.delete(h,{at:{anchor:E.start(h,[]),focus:E.end(h,[])}}),h.children.length===0&&N.insertNodes(h,[{type:"paragraph",children:[{text:""}]}])},h.getParentNode=function(C){return A.getParentNode(h,C)},h.dangerouslyInsertHtml=function(C,O){if(C===void 0&&(C=""),O===void 0&&(O=!1),C){var T=document.createElement("div");T.innerHTML=C;var R=Array.from(T.childNodes);if(R=R.filter(function(U){var W=U.nodeType,q=U.nodeName;return W===yo.TEXT_NODE||W===yo.ELEMENT_NODE&&!M9.has(q.toLowerCase())}),R.length!==0){var H=h.selection;if(H!=null){var M=null;A.isSelectedEmptyParagraph(h)&&!O&&(M=[H.focus.path[0]]),T.setAttribute("hidden","true"),document.body.appendChild(T);var K=0;R.forEach(function(U){var W=U.nodeType,q=U.nodeName,nt=U.textContent,lt=nt===void 0?"":nt;if(W!==yo.TEXT_NODE)if(q!=="BR"){var st=U,at=!1;if(UN.includes(q.toLowerCase()))at=!0;else for(var k in vv)if(st.matches(k)){at=!0;break}if(at){var S=SD(B(st),h);return Array.isArray(S)?(S.forEach(function($){return z9(h,$)}),K++):(z9(h,S),K++),void(A.isSelectedVoidNode(h)&&h.move(1))}var P=window.getComputedStyle(st).display;A.isSelectedEmptyParagraph(h)||P.indexOf("inline")<0&&h.insertBreak(),h.dangerouslyInsertHtml(st.innerHTML,!0)}else h.insertText(`
|
|
|
|
|
`);else{if(!lt||!lt.trim())return;h.insertNode({text:lt})}}),K&&M&&A.isEmptyPath(h,M)&&N.removeNodes(h,{at:M}),T.remove()}}}},h.setHtml=function(C){C===void 0&&(C="");var O=h.isDisabled(),T=h.isFocused(),R=JSON.stringify(h.selection);h.enable(),h.focus(),h.clear();var H=I9(h,C);if(N.insertFragment(h,H),T||(h.deselect(),h.blur()),O&&(h.deselect(),h.disable()),h.isFocused())try{h.select(JSON.parse(R))}catch{h.select(E.start(h,[]))}},h}(function(y){var h=y;return h.getAllMenuKeys=function(){var b=[];for(var w in Xd)b.push(w);return b},h.getConfig=function(){var b=a9.get(h);if(b==null)throw new Error("Can not get editor config");return b},h.getMenuConfig=function(b){var w=h.getConfig().MENU_CONF;return(w===void 0?{}:w)[b]||{}},h.alert=function(b,w){w===void 0&&(w="info");var D=h.getConfig().customAlert;D&&D(b,w)},h}(function(y){var h=mQ(zW());return h.id="wangEditor-"+SJ++,h.isDestroyed=!1,h.isFullScreen=!1,h.focus=function(b){if(A.toDOMNode(h,h).focus({preventScroll:!0}),Bu.set(h,!0),b){var w=E.end(h,[]);N.select(h,w)}else{var D=fb.get(h);D?N.select(h,D):N.select(h,E.start(h,[]))}},h.isFocused=function(){return!!Bu.get(h)},h.blur=function(){A.toDOMNode(h,h).blur(),N.deselect(h),Bu.set(h,!1)},h.updateView=function(){A.getTextarea(h).changeViewState();var b=A.getToolbar(h);b&&b.changeToolbarState();var w=A.getHoverbar(h);w&&w.changeHoverbarState()},h.destroy=function(){if(!h.isDestroyed){var b=A.getTextarea(h);b.destroy(),BE.delete(h),FE.delete(b);var w=A.getToolbar(h);w&&(w.destroy(),nm.delete(h),gD.delete(w));var D=A.getHoverbar(h);D&&(D.destroy(),fv.delete(h),TE.delete(D)),h.isDestroyed=!0,h.emit("destroyed")}},h.scrollToElem=function(b){if(!h.getConfig().scroll){var w="编辑器禁用了 scroll ,编辑器内容无法滚动,请自行实现该功能";return w+=`
|
|
|
|
|
You has disabled editor scroll, please do this yourself`,void console.warn(w)}var D=B("#"+b);if(D.length!==0){var x=D[0];if(!A.hasDOMNode(h,x))return w="Element (found by id is '"+b+"') is not in editor DOM",w+=`
|
|
|
|
|
通过 id '`+b+"' 找到的 element 不在 editor DOM 之内",void console.error(w,x);var C=A.getTextarea(h),O=C.$textAreaContainer,T=C.$scroll,R=D.offset().top,H=O.offset().top;T[0].scrollBy({top:R-H,behavior:"smooth"})}},h.showProgressBar=function(b){b<1||A.getTextarea(h).changeProgress(b)},h.hidePanelOrModal=function(){var b=_E.get(h);b!=null&&b.forEach(function(w){return w.hide()})},h.enable=function(){h.getConfig().readOnly=!1,h.updateView()},h.disable=function(){h.getConfig().readOnly=!0,h.updateView()},h.isDisabled=function(){return h.getConfig().readOnly},h.toDOMNode=function(b){return A.toDOMNode(h,b)},h.fullScreen=function(){if(!h.isFullScreen){var b=null,w=A.getToolbar(h);w&&(b=w.$box);var D=A.getTextarea(h).$box.parent();if(b&&b.parent()[0]!==D[0])throw new Error(`Can not set full screen, cause toolbar DOM parent is not equal to textarea DOM parent
|
|
|
|
|
不能设置全屏,因为 toolbar DOM 父节点和 textarea DOM 父节点不一致`);D.addClass("w-e-full-screen-container");var x=D.css("z-index");D.attr("data-z-index",x.toString()),h.isFullScreen=!0,h.emit("fullScreen")}},h.unFullScreen=function(){if(h.isFullScreen){var b=A.getTextarea(h).$box.parent();setTimeout(function(){b.removeClass("w-e-full-screen-container"),h.isFullScreen=!1,h.emit("unFullScreen")},200)}},h.getEditableContainer=function(){return A.getTextarea(h).$textAreaContainer[0]},h}()))))));if(n&&function(y,h){return KN(y,"data-w-e-textarea",h)}(l,n))throw new Error("Repeated create editor by selector '"+n+"'");var c=function(y){y===void 0&&(y={});var h=_j(AN),b={},w=y.MENU_CONF,D=w===void 0?{}:w;return M5(h,function(x,C){b[C]=Er(Er({},x),D[C]||{})}),delete y.MENU_CONF,Er({scroll:!0,readOnly:!1,autoFocus:!0,decorate:function(){return[]},maxLength:0,MENU_CONF:b,hoverbarKeys:{},customAlert:function(x,C){window.alert(C+`:
|
|
|
|
|
`+x)}},y)}(o);a9.set(l,c);var f=c.hoverbarKeys,p=f===void 0?{}:f;if(s.forEach(function(y){l=y(l)}),a!=null&&(l.children=I9(l,a)),i&&i.length&&(l.children=i),l.children.length===0&&(l.children=[{type:"paragraph",children:[{text:""}]}]),A.normalizeContent(l),n){var d=new KQ(n);BE.set(l,d),FE.set(d,l),d.changeViewState(),Pr(function(){var y=d.$scroll;y!=null&&y.height()<300&&console.warn(`编辑区域高度 < 300px 这可能会导致 modal hoverbar 定位异常
|
|
|
|
|
Textarea height < 300px . This may be cause modal and hoverbar position error`,y)});var v=void 0;Object.keys(p).length>0&&(v=new rtt,TE.set(v,l),fv.set(l,v)),l.on("change",function(){l.hidePanelOrModal()}),l.on("scroll",function(){l.hidePanelOrModal()})}else l.children.forEach(function(y,h){return nI(y,h,l,l)});var g=c.onCreated,m=c.onDestroyed;return g&&l.on("created",function(){return g(l)}),m&&l.on("destroyed",function(){return m(l)}),Pr(function(){return l.emit("created")}),l}var itt=J1("splice"),att=X.TypeError,utt=Math.max,stt=Math.min;De({target:"Array",proto:!0,forced:!itt},{splice:function(t,e){var n,r,o,i,a,u,s=Na(this),l=ps(s),c=$l(t,l),f=arguments.length;if(f===0?n=r=0:f===1?(n=0,r=l-c):(n=f-2,r=stt(utt(Vp(e),0),l-c)),l+n-r>9007199254740991)throw att("Maximum allowed length exceeded");for(o=Qj(s,r),i=0;i<r;i++)(a=c+i)in s&&Wd(o,i,s[a]);if(o.length=r,n<r){for(i=c;i<l-r;i++)u=i+n,(a=i+r)in s?s[u]=s[a]:delete s[u];for(i=l;i>l-r+n;i--)delete s[i-1]}else if(n>r)for(i=l-r;i>c;i--)u=i+n-1,(a=i+r-1)in s?s[u]=s[a]:delete s[u];for(i=0;i<n;i++)s[i+c]=arguments[i+2];return s.length=l-r+n,o}});var ltt=function(){function t(e,n){var r=this;this.$toolbar=B('<div class="w-e-bar w-e-bar-show w-e-toolbar"></div>'),this.menus={},this.toolbarItems=[],this.config={},this.changeToolbarState=Tj(function(){r.toolbarItems.forEach(function(a){a.changeMenuState()})},200),this.config=n;var o=B(e);if(o.length===0)throw new Error("Cannot find toolbar DOM by selector '"+e+"'");this.$box=o;var i=this.$toolbar;i.on("mousedown",function(a){return a.preventDefault()},{passive:!1}),o.append(i),Pr(function(){r.registerItems(),r.changeToolbarState(),r.getEditorInstance().on("change",r.changeToolbarState)})}return t.prototype.getMenus=function(){return this.menus},t.prototype.getConfig=function(){return this.config},t.prototype.registerItems=function(){var e=this,n="",r=this.$toolbar,o=this.config,i=o.toolbarKeys,a=i===void 0?[]:i,u=o.insertKeys,s=u===void 0?{index:0,keys:[]}:u,l=o.excludeKeys,c=l===void 0?[]:l,f=_j(a);s.keys.length>0&&(typeof s.keys=="string"&&(s.keys=[s.keys]),s.keys.forEach(function(v,g){f.splice(s.index+g,0,v)}));var p=f.filter(function(v){if(typeof v=="string"){if(c.includes(v))return!1}else if(c.includes(v.key))return!1;return!0}),d=p.length;p.forEach(function(v,g){if(v==="|"){if(g===0||g+1===d||n==="|")return;var m=QN();return r.append(m),void(n=v)}if(typeof v=="string")return e.registerSingleItem(v,e),void(n=v);e.registerGroup(v),n="group"})},t.prototype.registerGroup=function(e){var n=this,r=this.$toolbar,o=function(l){return new eO(l)}(e),i=e.menuKeys,a=i===void 0?[]:i,u=this.config.excludeKeys,s=u===void 0?[]:u;a.forEach(function(l){s.includes(l)||n.registerSingleItem(l,o)}),r.append(o.$elem)},t.prototype.registerSingleItem=function(e,n){var r=this.getEditorInstance(),o=n instanceof eO,i=this.menus,a=i[e];if(a==null){var u=Xd[e];if(u==null)throw new Error("Not found menu item factory by key '"+e+"'");if(typeof u!="function")throw new Error("Menu item factory (key='"+e+"') is not a function");a=u(),i[e]=a}else console.warn("Duplicated toolbar menu key '"+e+`'
|
|
|
|
|
重复注册了菜单栏 menu '`+e+"'");var s=eI(e,a,o);this.toolbarItems.push(s),vD.set(s,r),o?n.appendBarItem(s):n.$toolbar.append(s.$elem)},t.prototype.getEditorInstance=function(){var e=gD.get(this);if(e==null)throw new Error("Can not get editor instance");return e},t.prototype.destroy=function(){this.$toolbar.remove(),this.menus={},this.toolbarItems=[]},t}(),ctt=sc.EXISTS,ftt=ro.f,rI=Function.prototype,dtt=pt(rI.toString),oI=/function\b(?:\s|\/\*[\S\s]*?\*\/|\/\/[^\n\r]*[\n\r]+)*([^\s(/]*)/,ptt=pt(oI.exec);function iI(t){var e=t.server,n=e===void 0?"":e,r=t.fieldName,o=r===void 0?"":r,i=t.maxFileSize,a=i===void 0?10485760:i,u=t.maxNumberOfFiles,s=u===void 0?100:u,l=t.meta,c=l===void 0?{}:l,f=t.metaWithUrl,p=f!==void 0&&f,d=t.headers,v=d===void 0?{}:d,g=t.withCredentials,m=g!==void 0&&g,y=t.timeout,h=y===void 0?1e4:y,b=t.onBeforeUpload,w=b===void 0?function(K){return K}:b,D=t.onSuccess,x=D===void 0?function(K,U){}:D,C=t.onError,O=C===void 0?function(K,U,W){console.error(K.name+" upload error",U,W)}:C,T=t.onProgress,R=T===void 0?function(K){}:T;if(!n)throw new Error(`Cannot get upload server address
|
|
|
|
|
没有配置上传地址`);if(!o)throw new Error(`Cannot get fieldName
|
|
|
|
|
没有配置 fieldName`);var H=n;p&&(H=function(K,U){var W=Ht(K.split("#"),2),q=W[0],nt=W[1],lt=[];M5(U,function(at,k){lt.push(k+"="+at)});var st=lt.join("&");return q=q.indexOf("?")>0?q+"&"+st:q+"?"+st,nt?q+"#"+nt:q}(H,c));var M=new Yf({onBeforeUpload:w,restrictions:{maxFileSize:a,maxNumberOfFiles:s},meta:c}).use(zY,{endpoint:H,headers:v,formData:!0,fieldName:o,bundle:!0,withCredentials:m,timeout:h});return M.on("upload-success",function(K,U){var W=U.body,q=W===void 0?{}:W;try{x(K,q)}catch(nt){console.error("wangEditor upload file - onSuccess error",nt)}M.removeFile(K.id)}),M.on("progress",function(K){K<1||R(K)}),M.on("upload-error",function(K,U,W){try{O(K,U,W)}catch(q){console.error("wangEditor upload file - onError error",q)}M.removeFile(K.id)}),M.on("restriction-failed",function(K,U){try{O(K,U)}catch(W){console.error("wangEditor upload file - onError error",W)}M.removeFile(K.id)}),M}function aa(t){return aa=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(e){return typeof e}:function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},aa(t)}function htt(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function Ve(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?Object(arguments[e]):{},r=Object.keys(n);typeof Object.getOwnPropertySymbols=="function"&&r.push.apply(r,Object.getOwnPropertySymbols(n).filter(function(o){return Object.getOwnPropertyDescriptor(n,o).enumerable})),r.forEach(function(o){htt(t,o,n[o])})}return t}function si(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function rO(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}function li(t,e,n){return e&&rO(t.prototype,e),n&&rO(t,n),t}function Qu(t){if(t===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function Jd(t,e){if(e&&(aa(e)==="object"||typeof e=="function"))return e;if(e!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Qu(t)}function Gl(t){return Gl=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},Gl(t)}function qE(t,e){return qE=Object.setPrototypeOf||function(n,r){return n.__proto__=r,n},qE(t,e)}function rm(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),e&&qE(t,e)}an&&!ctt&&ftt(rI,"name",{configurable:!0,get:function(){try{return ptt(oI,dtt(this))[1]}catch{return""}}});var gtt={type:"logger",log:function(t){this.output("log",t)},warn:function(t){this.output("warn",t)},error:function(t){this.output("error",t)},output:function(t,e){console&&console[t]&&console[t].apply(console,e)}},Qo=new(function(){function t(e){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};si(this,t),this.init(e,n)}return li(t,[{key:"init",value:function(e){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};this.prefix=n.prefix||"i18next:",this.logger=e||gtt,this.options=n,this.debug=n.debug}},{key:"setDebug",value:function(e){this.debug=e}},{key:"log",value:function(){for(var e=arguments.length,n=new Array(e),r=0;r<e;r++)n[r]=arguments[r];return this.forward(n,"log","",!0)}},{key:"warn",value:function(){for(var e=arguments.length,n=new Array(e),r=0;r<e;r++)n[r]=arguments[r];return this.forward(n,"warn","",!0)}},{key:"error",value:function(){for(var e=arguments.length,n=new Array(e),r=0;r<e;r++)n[r]=arguments[r];return this.forward(n,"error","")}},{key:"deprecate",value:function(){for(var e=arguments.length,n=new Array(e),r=0;r<e;r++)n[r]=arguments[r];return this.forward(n,"warn","WARNING DEPRECATED: ",!0)}},{key:"forward",value:function(e,n,r,o){return o&&!this.debug?null:(typeof e[0]=="string"&&(e[0]="".concat(r).concat(this.prefix," ").concat(e[0])),this.
|
|
|
|
|
`)&&t.flags==="s")}),Jet=St.RegExp,Qet=Ce(function(){var t=Jet("(?<a>b)","g");return t.exec("b").groups.a!=="b"||"b".replace(t,"$<a>c")!=="bc"}),tnt=t6.get,ent=MD("native-string-replace",String.prototype.replace),Sv=RegExp.prototype.exec,n6=Sv,nnt=mt("".charAt),rnt=mt("".indexOf),ont=mt("".replace),Hb=mt("".slice),Vb=($b=/b*/g,Te(Sv,TO=/a/,"a"),Te(Sv,$b,"a"),TO.lastIndex!==0||$b.lastIndex!==0),_O=kI.BROKEN_CARET,Ub=/()??/.exec("")[1]!==void 0;(Vb||Ub||_O||Zet||Qet)&&(n6=function(t){var e,n,r,o,i,a,u,s=this,l=tnt(s),c=Ee(t),f=l.raw;if(f)return f.lastIndex=s.lastIndex,e=Te(n6,f,c),s.lastIndex=f.lastIndex,e;var p=l.groups,d=_O&&s.sticky,v=Te(OI,s),g=s.source,m=0,y=c;if(d&&(v=ont(v,"y",""),rnt(v,"g")===-1&&(v+="g"),y=Hb(c,s.lastIndex),s.lastIndex>0&&(!s.multiline||s.multiline&&nnt(c,s.lastIndex-1)!==`
|
|
|
|
|
`)&&(g="(?: "+g+")",y=" "+y,m++),n=new RegExp("^(?:"+g+")",v)),Ub&&(n=new RegExp("^"+g+"$(?!\\s)",v)),Vb&&(r=s.lastIndex),o=Te(Sv,d?n:s,y),d?o?(o.input=Hb(o.input,m),o[0]=Hb(o[0],m),o.index=s.lastIndex,s.lastIndex+=o[0].length):s.lastIndex=0:Vb&&o&&(s.lastIndex=s.global?o.index+o[0].length:r),Ub&&o&&o.length>1&&Te(ent,o[0],n,function(){for(i=1;i<arguments.length-2;i++)arguments[i]===void 0&&(o[i]=void 0)}),o&&p)for(o.groups=a=TI(null),i=0;i<p.length;i++)a[(u=p[i])[0]]=o[u[1]];return o});var ep=n6;tn({target:"RegExp",proto:!0,forced:/./.exec!==ep},{exec:ep});var ZD=Function.prototype,PO=ZD.apply,int=ZD.bind,jO=ZD.call,_I=typeof Reflect=="object"&&Reflect.apply||(int?jO.bind(PO):function(){return jO.apply(PO,arguments)}),ant=dr("species"),Wb=RegExp.prototype,JD=function(t,e,n,r){var o=dr(t),i=!Ce(function(){var l={};return l[o]=function(){return 7},""[t](l)!=7}),a=i&&!Ce(function(){var l=!1,c=/a/;return t==="split"&&((c={}).constructor={},c.constructor[ant]=function(){return c},c.flags="",c[o]=/./[o]),c.exec=function(){return l=!0,null},c[o](""),!l});if(!i||!a||n){var u=mt(/./[o]),s=e(o,""[t],function(l,c,f,p,d){var v=mt(l),g=c.exec;return g===ep||g===Wb.exec?i&&!d?{done:!0,value:u(c,f,p)}:{done:!0,value:v(f,c,p)}:{done:!1}});Qd(String.prototype,t,s[0]),Qd(Wb,o,s[1])}r&&ql(Wb[o],"sham",!0)},unt=mt("".charAt),NO=mt("".charCodeAt),snt=mt("".slice),lnt=function(t){return function(e,n){var r,o,i=Ee(jr(e)),a=gc(n),u=i.length;return a<0||a>=u?t?"":void 0:(r=NO(i,a))<55296||r>56319||a+1===u||(o=NO(i,a+1))<56320||o>57343?t?unt(i,a):r:t?snt(i,a,a+2):o-56320+(r-55296<<10)+65536}},cnt=lnt(!0),QD=function(t,e,n){return e+(n?cnt(t,e).length:1)},fnt=Math.floor,Gb=mt("".charAt),dnt=mt("".replace),qb=mt("".slice),pnt=/\$([$&'`]|\d{1,2}|<[^>]*>)/g,hnt=/\$([$&'`]|\d{1,2})/g,gnt=function(t,e,n,r,o,i){var a=n+t.length,u=r.length,s=hnt;return o!==void 0&&(o=qp(o),s=pnt),dnt(i,s,function(l,c){var f;switch(Gb(c,0)){case"$":return"$";case"&":return t;case"`":return qb(e,0,n);case"'":return qb(e,a);case"<":f=o[qb(c,1,-1)];break;default:var p=+c;if(p===0)return l;if(p>u){var d=fnt(p/10);return d===0?l:d<=u?r[d-1]===void 0?Gb(c,1):r[d-1]+Gb(c,1):l}f=r[p-1]}return f===void 0?"":f})},vnt=St.TypeError,np=function(t,e){var n=t.exec;if(hn(n)){var r=Te(n,t,e);return r!==null&&rr(r),r}if(ua(t)==="RegExp")return Te(ep,t,e);throw vnt("RegExp#exec called on incompatible receiver")},r6=dr("replace"),mnt=Math.max,ynt=Math.min,bnt=mt([].concat),Kb=mt([].push),IO=mt("".indexOf),LO=mt("".slice),wnt="a".replace(/./,"$0")==="$0",RO=!!/./[r6]&&/./[r6]("a","$0")==="";JD("replace",function(t,e,n){var r=RO?"$":"$0";return[function(o,i){var a=jr(this),u=o==null?void 0:um(o,r6);return u?Te(u,o,a,i):Te(e,Ee(a),o,i)},function(o,i){var a=rr(this),u=Ee(o);if(typeof i=="string"&&IO(i,r)===-1&&IO(i,"$<")===-1){var s=n(e,a,u,i);if(s.done)return s.value}var l=hn(i);l||(i=Ee(i));var c=a.global;if(c){var f=a.unicode;a.lastIndex=0}for(var p=[];;){var d=np(a,u);if(d===null||(Kb(p,d),!c))break;Ee(d[0])===""&&(a.lastIndex=QD(u,Kp(a.lastIndex),f))}for(var v,g="",m=0,y=0;y<p.length;y++){for(var h=Ee((d=p[y])[0]),b=mnt(ynt(gc(d.index),u.length),0),w=[],D=1;D<d.length;D++)Kb(w,(v=d[D])===void 0?v:String(v));var x=d.groups;if(l){var C=bnt([h],w,b,u);x!==void 0&&Kb(C,x);var O=Ee(_I(i,void 0,C))}else O=gnt(h,u,b,w,x,i);b>=m&&(g+=LO(u,m,b)+O,m=b+h.length)}return g+LO(u,m)}]},!!Ce(function(){var t=/./;return t.exec=function(){var e=[];return e.groups={a:"7"},e},"".replace(t,"$<a>")!=="7"})||!wnt||RO);var o6=dr("unscopables"),i6=Array.prototype;i6[o6]==null&&hc.f(i6,o6,{configurable:!0,value:TI(null)});var PI=function(t){i6[o6][t]=!0},Ent=cm.find,MO=!0;"find"in[]&&Array(1).find(function(){MO=!1}),tn({target:"Array",proto:!0,forced:MO},{find:function(t){return Ent(this,t,arguments.length>1?arguments[1]:void 0)}}),PI("find");var Dnt=dr("match"),jI=function(t){var e;return Cr(t)&&((e=t[Dnt])!==void 0?!!e:ua(t)=="RegExp")},Cnt=St.TypeError,xnt=dr("species"),NI=function(t,e,n){var r=zD(e);r in t?hc.f(t,r,ID(0,n)):t[r]=n},Snt=St.Array,Ant=Math.max,zO=function(t,e,n){for(var r=lm(t),o=tp(e,r),i=tp(n==
|
|
|
|
|
\v\f\r \u2028\u2029\uFEFF`,$O=mt("".replace),Av="["+a6+"]",Bnt=RegExp("^"+Av+Av+"*"),Fnt=RegExp(Av+Av+"*$"),Yb=function(t){return function(e){var n=Ee(jr(e));return 1&t&&(n=$O(n,Bnt,"")),2&t&&(n=$O(n,Fnt,"")),n}},Tnt={start:Yb(1),end:Yb(2),trim:Yb(3)},_nt=sm.PROPER,Pnt=Tnt.trim;function tC(t){return B("<div>"+t+"</div>").children().filter(function(e){return e.tagName!=="BR"}).length===0}function vc(t){return t.length===0?"":t[0].outerHTML}function mc(t){return t.length?t[0].tagName.toLowerCase():""}function Jr(t,e){for(var n="",r=(t.attr("style")||"").split(";"),o=r.length,i=0;i<o;i++){var a=r[i];if(a){var u=a.split(":");u[0].trim()===e&&(n=u[1].trim())}}return n}tn({target:"String",proto:!0,forced:Ce(function(){return!!a6.trim()||"
".trim()!=="
"||_nt&&a6.trim.name!=="trim"})},{trim:function(){return Pnt(this)}}),tn({global:!0},{globalThis:St}),Zg&&(B.fn.css=Zg),Tr&&(B.fn.append=Tr),kA&&(B.fn.prepend=kA),Fl&&(B.fn.addClass=Fl),Tl&&(B.fn.removeClass=Tl),_l&&(B.fn.hasClass=_l),ko&&(B.fn.on=ko),xA&&(B.fn.off=xA),Ca&&(B.fn.focus=Ca),Fr&&(B.fn.attr=Fr),qg&&(B.fn.removeAttr=qg),jl&&(B.fn.hide=jl),Xg&&(B.fn.show=Xg),tv&&(B.fn.parents=tv),Pl&&(B.fn.dataset=Pl),Oo&&(B.fn.val=Oo),Qg&&(B.fn.text=Qg),Da&&(B.fn.html=Da),Ll&&(B.fn.children=Ll),Rl&&(B.fn.remove=Rl),Il&&(B.fn.find=Il),Kg&&(B.fn.width=Kg),Yg&&(B.fn.height=Yg),AA&&(B.fn.filter=AA),Ml&&(B.fn.empty=Ml);var jnt={selector:"p:not([data-w-e-type])",parseElemHtml:function(t,e,n){var r=B(t);return(e=e.filter(function(o){return!!ot.isText(o)||!!n.isInline(o)})).length===0&&(e=[{text:r.text().replace(/\s+/gm," ")}]),{type:"paragraph",children:e}}},u6=function(t,e){return u6=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,r){n.__proto__=r}||function(n,r){for(var o in r)Object.prototype.hasOwnProperty.call(r,o)&&(n[o]=r[o])},u6(t,e);/*! *****************************************************************************
|
|
|
|
|
Copyright (c) Microsoft Corporation.
|
|
|
|
|
|
|
|
|
|
Permission to use, copy, modify, and/or distribute this software for any
|
|
|
|
|
purpose with or without fee is hereby granted.
|
|
|
|
|
|
|
|
|
|
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
|
|
|
|
|
REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
|
|
|
|
|
AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
|
|
|
|
|
INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
|
|
|
|
|
LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
|
|
|
|
|
OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
|
|
|
|
|
PERFORMANCE OF THIS SOFTWARE.
|
|
|
|
|
***************************************************************************** */};function be(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function n(){this.constructor=t}u6(t,e),t.prototype=e===null?Object.create(e):(n.prototype=e.prototype,new n)}var Aa=function(){return Aa=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},Aa.apply(this,arguments)};function La(t,e,n,r){return new(n||(n=Promise))(function(o,i){function a(l){try{s(r.next(l))}catch(c){i(c)}}function u(l){try{s(r.throw(l))}catch(c){i(c)}}function s(l){var c;l.done?o(l.value):(c=l.value,c instanceof n?c:new n(function(f){f(c)})).then(a,u)}s((r=r.apply(t,e||[])).next())})}function Ra(t,e){var n,r,o,i,a={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]};return i={next:u(0),throw:u(1),return:u(2)},typeof Symbol=="function"&&(i[Symbol.iterator]=function(){return this}),i;function u(s){return function(l){return function(c){if(n)throw new TypeError("Generator is already executing.");for(;a;)try{if(n=1,r&&(o=2&c[0]?r.return:c[0]?r.throw||((o=r.return)&&o.call(r),0):r.next)&&!(o=o.call(r,c[1])).done)return o;switch(r=0,o&&(c=[2&c[0],o.value]),c[0]){case 0:case 1:o=c;break;case 4:return a.label++,{value:c[1],done:!1};case 5:a.label++,r=c[1],c=[0];continue;case 7:c=a.ops.pop(),a.trys.pop();continue;default:if(!((o=(o=a.trys).length>0&&o[o.length-1])||c[0]!==6&&c[0]!==2)){a=0;continue}if(c[0]===3&&(!o||c[1]>o[0]&&c[1]<o[3])){a.label=c[1];break}if(c[0]===6&&a.label<o[1]){a.label=o[1],o=c;break}if(o&&a.label<o[2]){a.label=o[2],a.ops.push(c);break}o[2]&&a.ops.pop(),a.trys.pop();continue}c=e.call(t,a)}catch(f){c=[6,f],r=0}finally{n=o=0}if(5&c[0])throw c[1];return{value:c[0]?c[1]:void 0,done:!0}}([s,l])}}}function LI(t){var e=typeof Symbol=="function"&&Symbol.iterator,n=e&&t[e],r=0;if(n)return n.call(t);if(t&&typeof t.length=="number")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 Yt(t,e){var n=typeof Symbol=="function"&&t[Symbol.iterator];if(!n)return t;var r,o,i=n.call(t),a=[];try{for(;(e===void 0||e-- >0)&&!(r=i.next()).done;)a.push(r.value)}catch(u){o={error:u}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a}function HO(t){var e=Yt(E.nodes(t,{match:function(i){return t.children[0]===i},mode:"highest"}),1)[0];if(e==null)return!1;var n=e[0];if(!ct.isElement(n)||n.type==="paragraph"||Q.string(n)!=="")return!1;var r=n.children,o=r===void 0?[]:r;return!!ot.isText(o[0])&&(N.setNodes(t,{type:"paragraph"}),!0)}var Nnt={renderElems:[Rtt],elemsToHtml:[{type:"paragraph",elemToHtml:function(t,e){return e===""?"<p><br></p>":"<p>"+e+"</p>"}}],parseElemsHtml:[jnt],editorPlugin:function(t){var e=t.deleteBackward,n=t.deleteForward;t.insertText,t.insertBreak;var r=t;return r.deleteBackward=function(o){HO(r)||e(o)},r.deleteForward=function(o){HO(r)||n(o)},r}},Int=/"/g,Lnt=mt("".replace),Qf=function(t,e,n,r){var o=Ee(jr(t)),i="<"+e;return n!==""&&(i+=" "+n+'="'+Lnt(Ee(r),Int,""")+'"'),i+">"+o+"</"+e+">"},td=function(t){return Ce(function(){var e=""[t]('"');return e!==e.toLowerCase()||e.split('"').length>3})};function Xb(t,e){var n=e,r=t,o=r.bold,i=r.italic,a=r.underline;return o&&(n="<strong>"+n+"</strong>"),r.code&&(n="<code>"+n+"</code>"),i&&(n="<em>"+n+"</em>"),a&&(n="<u>"+n+"</u>"),r.through&&(n="<s>"+n+"</s>"),r.sub&&(n="<sub>"+n+"</sub>"),r.sup&&(n="<sup>"+n+"</sup>"),n}function Ja(t,e){return t.length!==0&&(!!t[0].matches(e)||t.find(e).length>0)}tn({target:"String",proto:!0,forced:td("bold")},{bold:function(){return Qf(this,"b","","")}}),tn({target:"String",proto:!0,forced:td("italics")},{italics:function(){return Qf(this,"i","","")}}),tn({target:"String",proto:!0,forced:td("sub")},{sub:function(){return Qf(this,"sub","","")}}),tn({target:"String",proto:!0,forced:td("sup")},{sup:function(){return Qf(t
|
|
|
|
|
<li data-value="0" class="clear">
|
|
|
|
|
<svg viewBox="0 0 1024 1024"><path d="M236.8 128L896 787.2V128H236.8z m614.4 704L192 172.8V832h659.2zM192 64h704c38.4 0 64 25.6 64 64v704c0 38.4-25.6 64-64 64H192c-38.4 0-64-25.6-64-64V128c0-38.4 25.6-64 64-64z"></path></svg>
|
|
|
|
|
`+u+`
|
|
|
|
|
</li>
|
|
|
|
|
`);return o.prepend(s),o[0]},t}(),Hrt=function(t){function e(){var n=t!==null&&t.apply(this,arguments)||this;return n.title=tt("color.color"),n.iconSvg=Gnt,n.mark="color",n}return be(e,t),e}(YI),Vrt=function(t){function e(){var n=t!==null&&t.apply(this,arguments)||this;return n.title=tt("color.bgColor"),n.iconSvg=qnt,n.mark="bgColor",n}return be(e,t),e}(YI),YO=["rgb(0, 0, 0)","rgb(38, 38, 38)","rgb(89, 89, 89)","rgb(140, 140, 140)","rgb(191, 191, 191)","rgb(217, 217, 217)","rgb(233, 233, 233)","rgb(245, 245, 245)","rgb(250, 250, 250)","rgb(255, 255, 255)","rgb(225, 60, 57)","rgb(231, 95, 51)","rgb(235, 144, 58)","rgb(245, 219, 77)","rgb(114, 192, 64)","rgb(89, 191, 192)","rgb(66, 144, 247)","rgb(54, 88, 226)","rgb(106, 57, 201)","rgb(216, 68, 147)","rgb(251, 233, 230)","rgb(252, 237, 225)","rgb(252, 239, 212)","rgb(252, 251, 207)","rgb(231, 246, 213)","rgb(218, 244, 240)","rgb(217, 237, 250)","rgb(224, 232, 250)","rgb(237, 225, 248)","rgb(246, 226, 234)","rgb(255, 163, 158)","rgb(255, 187, 150)","rgb(255, 213, 145)","rgb(255, 251, 143)","rgb(183, 235, 143)","rgb(135, 232, 222)","rgb(145, 213, 255)","rgb(173, 198, 255)","rgb(211, 173, 247)","rgb(255, 173, 210)","rgb(255, 77, 79)","rgb(255, 122, 69)","rgb(255, 169, 64)","rgb(255, 236, 61)","rgb(115, 209, 61)","rgb(54, 207, 201)","rgb(64, 169, 255)","rgb(89, 126, 247)","rgb(146, 84, 222)","rgb(247, 89, 171)","rgb(207, 19, 34)","rgb(212, 56, 13)","rgb(212, 107, 8)","rgb(212, 177, 6)","rgb(56, 158, 13)","rgb(8, 151, 156)","rgb(9, 109, 217)","rgb(29, 57, 196)","rgb(83, 29, 171)","rgb(196, 29, 127)","rgb(130, 0, 20)","rgb(135, 20, 0)","rgb(135, 56, 0)","rgb(97, 71, 0)","rgb(19, 82, 0)","rgb(0, 71, 79)","rgb(0, 58, 140)","rgb(6, 17, 120)","rgb(34, 7, 94)","rgb(120, 6, 80)"],Urt={renderStyle:function(t,e){var n=t,r=n.color,o=n.bgColor,i=e;return r&&ts(i,{color:r}),o&&ts(i,{backgroundColor:o}),i},styleToHtml:function(t,e){if(!ot.isText(t))return e;var n,r=t,o=r.color,i=r.bgColor;return o||i?((tC(e)||mc(n=B(e))!=="span")&&(n=B("<span>"+e+"</span>")),o&&n.css("color",o),i&&n.css("background-color",i),vc(n)):e},preParseHtml:[$rt],parseStyleHtml:function(t,e,n){var r=B(t);if(!ot.isText(e))return e;var o=e,i=Jr(r,"color");i&&(o.color=i);var a=Jr(r,"background-color");return a||(a=Jr(r,"background")),a&&(o.bgColor=a),o},menus:[{key:"color",factory:function(){return new Hrt},config:{colors:YO}},{key:"bgColor",factory:function(){return new Vrt},config:{colors:YO}}]},Wrt=/^(?:\w+:)?\/\/(\S+)$/,Grt=/^localhost[\:?\d]*(?:[^\:?\d]\S*)?$/,qrt=/^[^\s\.]+\.\S{2,}$/,Krt=EI.includes;function fm(t){return t===void 0&&(t="r"),t+"-"+mj()}function eC(t){return t.replace(/</g,"<").replace(/>/g,">")}function XI(t,e,n,r){return La(this,void 0,void 0,function(){var o,i;return Ra(this,function(a){switch(a.label){case 0:return(o=e.getMenuConfig(t).checkLink)?[4,o(n,r)]:[3,2];case 1:if(typeof(i=a.sent())=="string")return e.alert(i,"error"),[2,!1];if(i==null)return[2,!1];a.label=2;case 2:return[2,!0]}})})}function ZI(t,e,n){return La(this,void 0,void 0,function(){var r;return Ra(this,function(o){switch(o.label){case 0:return(r=e.getMenuConfig(t).parseLinkUrl)?[4,r(n)]:[3,2];case 1:return[2,o.sent()];case 2:return[2,n]}})})}function nC(t){return t.selection==null||!!A.getSelectedElems(t).some(function(e){var n=e.type;return!!t.isVoid(e)||!!["pre","code","link"].includes(n)||void 0})}function e2(t,e){return{type:"link",url:eC(t),children:e?[{text:e}]:[]}}function JI(t,e,n){return La(this,void 0,void 0,function(){var r,o,i;return Ra(this,function(a){switch(a.label){case 0:return n?(e||(e=n),t.restoreSelection(),nC(t)?[2]:[4,XI("insertLink",t,e,n)]):[2];case 1:return a.sent()?[4,ZI("insertLink",t,n)]:[2];case 2:return r=a.sent(),(o=t.selection)==null||(L.isCollapsed(o)?(t.insertText(" "),i=e2(r,e),N.insertNodes(t,i),t.insertFragment([{text:" "}])):E.string(t,o)!==e?(t.deleteFragment(),i=e2(r,e),N.insertNodes(t,i)):(i=e2(r),N.wrapNodes(t,i,{split:!0}),N.collapse(t,{edge:"end"}))),[2]}})})}tn({target:"Array",proto:!0},{includes:function(t){return Krt(this,t,arguments.length>1?arguments[1]:void 0)}}),PI("
|
|
|
|
|
`)return t.deleteBackward("character"),void N.insertNodes(r,{type:"paragraph",children:[{text:""}]},{mode:"highest"})}n(`
|
|
|
|
|
`)},r}},kot=function(){function t(){this.title=tt("emotion.title"),this.iconSvg='<svg viewBox="0 0 1024 1024"><path d="M512 1024C230.4 1024 0 793.6 0 512S230.4 0 512 0s512 230.4 512 512-230.4 512-512 512z m0-102.4c226.742857 0 409.6-182.857143 409.6-409.6S738.742857 102.4 512 102.4 102.4 285.257143 102.4 512s182.857143 409.6 409.6 409.6z m-204.8-358.4h409.6c0 113.371429-91.428571 204.8-204.8 204.8s-204.8-91.428571-204.8-204.8z m0-102.4c-43.885714 0-76.8-32.914286-76.8-76.8s32.914286-76.8 76.8-76.8 76.8 32.914286 76.8 76.8-32.914286 76.8-76.8 76.8z m409.6 0c-43.885714 0-76.8-32.914286-76.8-76.8s32.914286-76.8 76.8-76.8c43.885714 0 76.8 32.914286 76.8 76.8s-32.914286 76.8-76.8 76.8z"></path></svg>',this.tag="button",this.showDropPanel=!0,this.$content=null}return t.prototype.exec=function(e,n){},t.prototype.getValue=function(e){return""},t.prototype.isActive=function(e){return!1},t.prototype.isDisabled=function(e){return e.selection==null||!!Yt(E.nodes(e,{match:function(n){return A.getNodeType(n)==="pre"||!!E.isVoid(e,n)},universal:!0}),1)[0]},t.prototype.getPanelContentElem=function(e){if(this.$content==null){var n=B('<ul class="w-e-panel-content-emotion"></ul>');n.on("click","li",function(i){var a=i.target;if(a!=null){i.preventDefault();var u=B(a).text();e.insertText(u)}}),this.$content=n}var r=this.$content;if(r==null)return document.createElement("ul");r.empty();var o=e.getMenuConfig("emotion").emotions;return(o===void 0?[]:o).forEach(function(i){var a=B("<li>"+i+"</li>");r.append(a)}),r[0]},t}(),Bot={menus:[{key:"emotion",factory:function(){return new kot},config:{emotions:"😀 😃 😄 😁 😆 😅 😂 🤣 😊 😇 🙂 🙃 😉 😌 😍 😘 😗 😙 😚 😋 😛 😝 😜 🤓 😎 😏 😒 😞 😔 😟 😕 🙁 😣 😖 😫 😩 😢 😭 😤 😠 😡 😳 😱 😨 🤗 🤔 😶 😑 😬 🙄 😯 😴 😷 🤑 😈 🤡 💩 👻 💀 👀 👣 👐 🙌 👏 🤝 👍 👎 👊 ✊ 🤛 🤜 🤞 ✌️ 🤘 👌 👈 👉 👆 👇 ☝️ ✋ 🤚 🖐 🖖 👋 🤙 💪 🖕 ✍️ 🙏".split(" ")}}]},Fot={1:"12px",2:"14px",3:"16px",4:"19px",5:"24px",6:"32px",7:"48px"},Tot={selector:"font",preParseHtml:function(t){var e=B(t);if(mc(e)!=="font")return t;var n=e.attr("size")||"";n&&(e.removeAttr("size"),e.css("font-size",Fot[n]));var r=e.attr("face")||"";return r&&(e.removeAttr("face"),e.css("font-family",r)),e[0]}},_ot=mt("".indexOf);tn({target:"String",proto:!0,forced:!WI("includes")},{includes:function(t){return!!~_ot(Ee(jr(this)),Ee(UI(t)),arguments.length>1?arguments[1]:void 0)}});var Fi,og,a0=function(t){return t&&t.Math==Math&&t},Ft=a0(typeof globalThis=="object"&&globalThis)||a0(typeof window=="object"&&window)||a0(typeof self=="object"&&self)||a0(typeof wv=="object"&&wv)||function(){return this}()||Function("return this")(),oC=Function.prototype,nk=oC.apply,Pot=oC.bind,rk=oC.call,rL=typeof Reflect=="object"&&Reflect.apply||(Pot?rk.bind(nk):function(){return rk.apply(nk,arguments)}),oL=Function.prototype,c6=oL.bind,f6=oL.call,jot=c6&&c6.bind(f6),_e=c6?function(t){return t&&jot(f6,t)}:function(t){return t&&function(){return f6.apply(t,arguments)}},gn=function(t){return typeof t=="function"},lr=function(t){try{return!!t()}catch{return!0}},Wn=!lr(function(){return Object.defineProperty({},1,{get:function(){return 7}})[1]!=7}),pf=Function.prototype.call,qr=pf.bind?pf.bind(pf):function(){return pf.apply(pf,arguments)},ok={}.propertyIsEnumerable,ik=Object.getOwnPropertyDescriptor,Not=ik&&!ok.call({1:2},1)?function(t){var e=ik(this,t);return!!e&&e.enumerable}:ok,iC={f:Not},es=function(t,e){return{enumerable:!(1&t),configurable:!(2&t),writable:!(4&t),value:e}},Iot=_e({}.toString),Lot=_e("".slice),Pu=function(t){return Lot(Iot(t),8,-1)},i2=Ft.Object,Rot=_e("".split),iL=lr(function(){return!i2("z").propertyIsEnumerable(0)})?function(t){return Pu(t)=="String"?Rot(t,""):i2(t)}:i2,Mot=Ft.TypeError,aC=function(t){if(t==null)throw Mot("Can't call method on "+t);return t},No=function(t){return iL(aC(t))},xr=function(t){return typeof t=="object"?t!==null:gn(t)},br={},ak=function(t){return gn(t)?
|
|
|
|
|
`).map(function(i){return{type:"paragraph",children:[{text:i}]}});N.insertNodes(e,o,{mode:"highest"})}},t.prototype.changeToCodeBlock=function(e,n){var r,o,i=[],a=E.nodes(e,{match:function(f){return e.children.includes(f)},universal:!0});try{for(var u=LI(a),s=u.next();!s.done;s=u.next()){var l=Yt(s.value,1)[0];l&&i.push(Q.string(l))}}catch(f){r={error:f}}finally{try{s&&!s.done&&(o=u.return)&&o.call(u)}finally{if(r)throw r.error}}N.removeNodes(e,{mode:"highest"});var c={type:"pre",children:[{type:"code",language:n,children:[{text:i.join(`
|
|
|
|
|
`)}]}]};N.insertNodes(e,c,{mode:"highest"})},t}(),Gat={key:"codeBlock",factory:function(){return new Wat}};tn({target:"String",proto:!0,forced:td("anchor")},{anchor:function(t){return Qf(this,"a","name",t)}}),JD("match",function(t,e,n){return[function(r){var o=jr(this),i=r==null?void 0:um(r,t);return i?Te(i,r,o):new RegExp(r)[t](Ee(o))},function(r){var o=rr(this),i=Ee(r),a=n(e,o,i);if(a.done)return a.value;if(!o.global)return np(o,i);var u=o.unicode;o.lastIndex=0;for(var s,l=[],c=0;(s=np(o,i))!==null;){var f=Ee(s[0]);l[c]=f,f===""&&(o.lastIndex=QD(i,Kp(o.lastIndex),u)),c++}return c===0?null:l}]});var qat={type:"pre",renderElem:function(t,e,n){return bt("pre",null,e)}},Kat={type:"code",renderElem:function(t,e,n){return bt("code",null,e)}},Yat={selector:"pre:not([data-w-e-type])",parseElemHtml:function(t,e,n){var r=B(t);return(e=e.filter(function(o){return A.getNodeType(o)==="code"})).length===0&&(e=[{type:"code",language:"",children:[{text:r[0].textContent||""}]}]),{type:"pre",children:e.filter(function(o){return A.getNodeType(o)==="code"})}}},Xat={menus:[Gat],editorPlugin:function(t){var e=t.insertBreak,n=t.normalizeNode,r=t.insertData;t.insertNode;var o=t;return o.insertBreak=function(){var i=A.getSelectedNodeByType(o,"code");if(i!=null){var a=function(l,c){var f=c.selection;if(f==null)return"";var p=Q.string(l),d=f.anchor.offset,v=p.slice(0,d).split(`
|
|
|
|
|
`),g=v.length;return g===0?"":v[g-1]}(i,o);if(a){var u=a.match(/^\s+/);if(u!=null&&u[0]!=null){var s=u[0];return void o.insertText(`
|
|
|
|
|
`+s)}}o.insertText(`
|
|
|
|
|
`)}else e()},o.normalizeNode=function(i){var a=Yt(i,2),u=a[0],s=a[1],l=A.getNodeType(u);return l==="code"&&s.length<=1&&N.setNodes(o,{type:"paragraph"},{at:s}),l==="pre"&&(A.isLastNode(o,u)&&N.insertNodes(o,A.genEmptyParagraph(),{at:[s[0]+1]}),A.getNodeType(u.children[0])!=="code"&&(N.unwrapNodes(o),N.setNodes(o,{type:"paragraph"},{mode:"highest"}))),n([u,s])},o.insertData=function(i){if(A.getSelectedNodeByType(o,"code")!=null){var a=i.getData("text/plain");E.insertText(o,a)}else r(i)},o},renderElems:[qat,Kat],elemsToHtml:[{type:"code",elemToHtml:function(t,e){return"<code>"+e+"</code>"}},{type:"pre",elemToHtml:function(t,e){return"<pre>"+e+"</pre>"}}],preParseHtml:[{selector:"pre>code",preParseHtml:function(t){var e=B(t);if(mc(e)!=="code")return t;var n=e.find("xmp");if(n.length===0)return t;var r=n.text();return n.remove(),e.text(r),e[0]}}],parseElemsHtml:[{selector:"pre:not([data-w-e-type])>code",parseElemHtml:function(t,e,n){return{type:"code",language:"",children:[{text:B(t)[0].textContent||""}]}}},Yat]},Zat=function(){function t(){this.title=tt("fullScreen.title"),this.iconSvg='<svg viewBox="0 0 1024 1024"><path d="M133.705143 335.433143V133.851429h201.581714a29.622857 29.622857 0 0 0 29.622857-29.549715V68.754286a29.622857 29.622857 0 0 0-29.622857-29.622857H61.732571A22.893714 22.893714 0 0 0 38.765714 62.025143V335.725714c0 16.310857 13.238857 29.622857 29.622857 29.622857h35.547429a29.842286 29.842286 0 0 0 29.696-29.842285zM690.980571 133.851429h201.581715v201.654857c0 16.310857 13.238857 29.549714 29.622857 29.549714h35.547428a29.622857 29.622857 0 0 0 29.549715-29.549714V61.952a22.893714 22.893714 0 0 0-22.820572-22.893714h-273.554285a29.622857 29.622857 0 0 0-29.549715 29.622857v35.547428c0 16.310857 13.238857 29.696 29.622857 29.696zM335.286857 892.781714H133.705143V691.2a29.622857 29.622857 0 0 0-29.622857-29.622857H68.534857a29.622857 29.622857 0 0 0-29.549714 29.622857v273.554286c0 12.653714 10.24 22.893714 22.820571 22.893714h273.554286a29.622857 29.622857 0 0 0 29.696-29.622857v-35.547429a29.769143 29.769143 0 0 0-29.769143-29.696z m557.348572-201.581714v201.581714H690.907429a29.622857 29.622857 0 0 0-29.622858 29.622857v35.547429c0 16.310857 13.238857 29.622857 29.622858 29.622857h273.554285c12.580571 0 22.893714-10.313143 22.893715-22.893714V691.2a29.622857 29.622857 0 0 0-29.622858-29.622857h-35.547428a29.622857 29.622857 0 0 0-29.696 29.622857z"></path></svg>',this.tag="button",this.alwaysEnable=!0}return t.prototype.getValue=function(e){return""},t.prototype.isActive=function(e){return e.isFullScreen},t.prototype.isDisabled=function(e){return!1},t.prototype.exec=function(e,n){e.isFullScreen?e.unFullScreen():e.fullScreen()},t}(),Jat={menus:[{key:"fullScreen",factory:function(){return new Zat}}]},Qat=function(){function t(){this.title=tt("common.enter"),this.iconSvg='<svg viewBox="0 0 1255 1024"><path d="M1095.111111 731.477333h-625.777778V1024L0 658.318222 469.333333 292.408889v292.636444h625.777778V0h156.444445v731.477333z"></path></svg>',this.tag="button"}return t.prototype.getValue=function(e){return""},t.prototype.isActive=function(e){return!1},t.prototype.isDisabled=function(e){var n=e.selection;return n==null||!!L.isExpanded(n)},t.prototype.exec=function(e,n){var r=e.selection;if(r!=null){var o=[r.anchor.path[0]];N.insertNodes(e,{type:"paragraph",children:[{text:""}]},{at:o}),e.select(E.start(e,o))}},t}(),tut=[drt,Urt,Cat,Oat,_at,jat,hot,zat,Bot,eot,Xat,Oot,Mrt,Nnt,yot,Lat,Jat,{menus:[{key:"enter",factory:function(){return new Qat}}]}];qn("en",{listModule:{unOrderedList:"Unordered list",orderedList:"Ordered list"}}),qn("zh-CN",{listModule:{unOrderedList:"无序列表",orderedList:"有序列表"}});var Mk=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function hC(t){var e={exports:{}};return t(e,e.exports),e.exports}var _i,ag,c0=function(t){return t&&t.Math==Math&&t},wt=c0(typeof globalThis=="object"&&globalThis)||c0(typeof window=="object"&&window)||c0(typeof self=="object"&&self)||c0(typeof Mk=="object"&&Mk)||function(){return thi
|
|
|
|
|
Copyright (c) Microsoft Corporation.
|
|
|
|
|
|
|
|
|
|
Permission to use, copy, modify, and/or distribute this software for any
|
|
|
|
|
purpose with or without fee is hereby granted.
|
|
|
|
|
|
|
|
|
|
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
|
|
|
|
|
REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
|
|
|
|
|
AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
|
|
|
|
|
INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
|
|
|
|
|
LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
|
|
|
|
|
OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
|
|
|
|
|
PERFORMANCE OF THIS SOFTWARE.
|
|
|
|
|
***************************************************************************** */};function sR(t,e){if(typeof e!="function"&&e!==null)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function n(){this.constructor=t}R6(t,e),t.prototype=e===null?Object.create(e):(n.prototype=e.prototype,new n)}function CB(t){var e=typeof Symbol=="function"&&Symbol.iterator,n=e&&t[e],r=0;if(n)return n.call(t);if(t&&typeof t.length=="number")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 yd(t,e){var n=typeof Symbol=="function"&&t[Symbol.iterator];if(!n)return t;var r,o,i=n.call(t),a=[];try{for(;(e===void 0||e-- >0)&&!(r=i.next()).done;)a.push(r.value)}catch(u){o={error:u}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a}function xB(t){return E.nodes(t,{at:t.selection||void 0,match:function(e){return A.findPath(t,e).length===1}})}var Wst=ML.includes;ka({target:"Array",proto:!0},{includes:function(t){return Wst(this,t,arguments.length>1?arguments[1]:void 0)}}),vd("includes");var SB,k2,Gst=function(){var t=Kn(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},_C=wt.RegExp,M6=Oe(function(){var t=_C("a","y");return t.lastIndex=2,t.exec("abcd")!=null}),qst=M6||Oe(function(){return!_C("a","y").sticky}),Kst={BROKEN_CARET:M6||Oe(function(){var t=_C("^r","gy");return t.lastIndex=2,t.exec("str")!=null}),MISSED_STICKY:qst,UNSUPPORTED_Y:M6},Yst=wt.RegExp,Xst=Oe(function(){var t=Yst(".","s");return!(t.dotAll&&t.exec(`
|
|
|
|
|
`)&&t.flags==="s")}),Zst=wt.RegExp,Jst=Oe(function(){var t=Zst("(?<a>b)","g");return t.exec("b").groups.a!=="b"||"b".replace(t,"$<a>c")!=="bc"}),Qst=Bo.get,tlt=vC("native-string-replace",String.prototype.replace),Vv=RegExp.prototype.exec,z6=Vv,elt=jt("".charAt),nlt=jt("".indexOf),rlt=jt("".replace),B2=jt("".slice),F2=(k2=/b*/g,en(Vv,SB=/a/,"a"),en(Vv,k2,"a"),SB.lastIndex!==0||k2.lastIndex!==0),AB=Kst.BROKEN_CARET,T2=/()??/.exec("")[1]!==void 0;(F2||T2||AB||Xst||Jst)&&(z6=function(t){var e,n,r,o,i,a,u,s=this,l=Qst(s),c=Ko(t),f=l.raw;if(f)return f.lastIndex=s.lastIndex,e=en(z6,f,c),s.lastIndex=f.lastIndex,e;var p=l.groups,d=AB&&s.sticky,v=en(Gst,s),g=s.source,m=0,y=c;if(d&&(v=rlt(v,"y",""),nlt(v,"g")===-1&&(v+="g"),y=B2(c,s.lastIndex),s.lastIndex>0&&(!s.multiline||s.multiline&&elt(c,s.lastIndex-1)!==`
|
|
|
|
|
`)&&(g="(?: "+g+")",y=" "+y,m++),n=new RegExp("^(?:"+g+")",v)),T2&&(n=new RegExp("^"+g+"$(?!\\s)",v)),F2&&(r=s.lastIndex),o=en(Vv,d?n:s,y),d?o?(o.input=B2(o.input,m),o[0]=B2(o[0],m),o.index=s.lastIndex,s.lastIndex+=o[0].length):s.lastIndex=0:F2&&o&&(s.lastIndex=s.global?o.index+o[0].length:r),T2&&o&&o.length>1&&en(tlt,o[0],n,function(){for(i=1;i<arguments.length-2;i++)arguments[i]===void 0&&(o[i]=void 0)}),o&&p)for(o.groups=a=CC(null),i=0;i<p.length;i++)a[(u=p[i])[0]]=o[u[1]];return o});var Uv=z6;ka({target:"RegExp",proto:!0,forced:/./.exec!==Uv},{exec:Uv});var lR=function(){function t(){this.type="list-item",this.tag="button"}return t.prototype.getListNode=function(e){var n=this.type;return A.getSelectedNodeByType(e,n)},t.prototype.getValue=function(e){return""},t.prototype.isActive=function(e){var n=this.getListNode(e);if(n==null)return!1;var r=n.ordered;return(r!==void 0&&r)===this.ordered},t.prototype.isDisabled=function(e){return e.selection==null||!!A.getSelectedElems(e).some(function(n){if(E.isVoid(e,n)&&E.isBlock(e,n))return!0;var r=n.type;return!!["pre","code","table"].includes(r)||void 0})},t.prototype.exec=function(e,n){this.isActive(e)?N.setNodes(e,{type:"paragraph",ordered:void 0,level:void 0}):N.setNodes(e,{type:"list-item",ordered:this.ordered,indent:void 0})},t}(),olt='<svg viewBox="0 0 1024 1024"><path d="M384 64h640v128H384V64z m0 384h640v128H384v-128z m0 384h640v128H384v-128zM0 128a128 128 0 1 1 256 0 128 128 0 0 1-256 0z m0 384a128 128 0 1 1 256 0 128 128 0 0 1-256 0z m0 384a128 128 0 1 1 256 0 128 128 0 0 1-256 0z"></path></svg>',ilt='<svg viewBox="0 0 1024 1024"><path d="M384 832h640v128H384z m0-384h640v128H384z m0-384h640v128H384zM192 0v256H128V64H64V0zM128 526.016v50.016h128v64H64v-146.016l128-60V384H64v-64h192v146.016zM256 704v320H64v-64h128v-64H64v-64h128v-64H64v-64z"></path></svg>',alt=function(t){function e(){var n=t!==null&&t.apply(this,arguments)||this;return n.ordered=!1,n.title=tt("listModule.unOrderedList"),n.iconSvg=olt,n}return sR(e,t),e}(lR),ult=function(t){function e(){var n=t!==null&&t.apply(this,arguments)||this;return n.ordered=!0,n.title=tt("listModule.orderedList"),n.iconSvg=ilt,n}return sR(e,t),e}(lR),slt={key:"bulletedList",factory:function(){return new alt}},llt={key:"numberedList",factory:function(){return new ult}},OB=[],clt={type:"list-item",elemToHtml:function(t,e){var n="",r="",o=t.ordered,i=o!==void 0&&o?"ol":"ul",a=function(l){var c=L6.get(l);if(c==null)return 0;var f=l,p=f.type,d=f.ordered,v=d!==void 0&&d,g=f.level,m=g===void 0?0:g,y=A.findPath(c,l);if(y[0]===0)return m+1;var h=j.previous(y),b=E.node(c,h);if(!b)return 0;var w=yd(b,1)[0];if(A.getNodeType(w)!==p)return m+1;var D=w,x=D.ordered,C=x!==void 0&&x,O=D.level,T=O===void 0?0:O;return T<m?m-T:T>m?0:T===m?C===v?0:1:0}(t);if(a>0)for(var u=0;u<a;u++)n+="<"+i+">",OB.push(i);var s=function(l){var c=L6.get(l);if(c==null)return 0;var f=l,p=f.type,d=f.ordered,v=d!==void 0&&d,g=f.level,m=g===void 0?0:g,y=A.findPath(c,l);if(y[0]===c.children.length-1)return m+1;var h=j.next(y),b=E.node(c,h);if(!b)return 0;var w=yd(b,1)[0];if(A.getNodeType(w)!==p)return m+1;var D=w,x=D.ordered,C=x!==void 0&&x,O=D.level,T=O===void 0?0:O;return T<m?m-T:T>m?0:T===m?C===v?0:1:0}(t);if(s>0)for(u=0;u<s;u++)r+="</"+OB.pop()+">";return{html:"<li>"+e+"</li>",prefix:n,suffix:r}}},flt=mn("species"),dlt=TC.filter,plt=C6>=51||!Oe(function(){var t=[];return(t.constructor={})[flt]=function(){return{foo:1}},t.filter(Boolean).foo!==1});ka({target:"Array",proto:!0,forced:!plt},{filter:function(t){return dlt(this,t,arguments.length>1?arguments[1]:void 0)}});var PC=Function.prototype,kB=PC.apply,hlt=PC.bind,BB=PC.call,glt=typeof Reflect=="object"&&Reflect.apply||(hlt?BB.bind(kB):function(){return BB.apply(kB,arguments)}),FB=(mn("species"),RegExp.prototype),vlt=YL.charAt,mlt=function(t,e,n){return e+(n?vlt(t,e).length:1)},ylt=Math.floor,_2=jt("".charAt),blt=jt("".replace),P2=jt("".slice),wlt=/\$([$&'`]|\d{1,2}|<[^>]*>)/g,Elt=/\$([$&'`]|\d{1,2})/g,Dlt=function(t,e,n,r,o,i){var a=n+t.length,u=r.length,s=Elt;return o!==void 0&&(o=rh(o),s=wlt),blt(i,s,function(l,c)
|
|
|
|
|
`)&&t.flags==="s")}),zct=_t.RegExp,$ct=Ye(function(){var t=zct("(?<a>b)","g");return t.exec("b").groups.a!=="b"||"b".replace(t,"$<a>c")!=="bc"}),Hct=K6.get,Vct=RC("native-string-replace",String.prototype.replace),Kv=RegExp.prototype.exec,X6=Kv,Uct=Rt("".charAt),Wct=Rt("".indexOf),Gct=Rt("".replace),H2=Rt("".slice),V2=($2=/b*/g,We(Kv,YB=/a/,"a"),We(Kv,$2,"a"),YB.lastIndex!==0||$2.lastIndex!==0),XB=AR.BROKEN_CARET,U2=/()??/.exec("")[1]!==void 0;(V2||U2||XB||Mct||$ct)&&(X6=function(t){var e,n,r,o,i,a,u,s=this,l=Hct(s),c=An(t),f=l.raw;if(f)return f.lastIndex=s.lastIndex,e=We(X6,f,c),s.lastIndex=f.lastIndex,e;var p=l.groups,d=XB&&s.sticky,v=We(SR,s),g=s.source,m=0,y=c;if(d&&(v=Gct(v,"y",""),Wct(v,"g")===-1&&(v+="g"),y=H2(c,s.lastIndex),s.lastIndex>0&&(!s.multiline||s.multiline&&Uct(c,s.lastIndex-1)!==`
|
|
|
|
|
`)&&(g="(?: "+g+")",y=" "+y,m++),n=new RegExp("^(?:"+g+")",v)),U2&&(n=new RegExp("^"+g+"$(?!\\s)",v)),V2&&(r=s.lastIndex),o=We(Kv,d?n:s,y),d?o?(o.input=H2(o.input,m),o[0]=H2(o[0],m),o.index=s.lastIndex,s.lastIndex+=o[0].length):s.lastIndex=0:V2&&o&&(s.lastIndex=s.global?o.index+o[0].length:r),U2&&o&&o.length>1&&We(Vct,o[0],n,function(){for(i=1;i<arguments.length-2;i++)arguments[i]===void 0&&(o[i]=void 0)}),o&&p)for(o.groups=a=BR(null),i=0;i<p.length;i++)a[(u=p[i])[0]]=o[u[1]];return o});var ap=X6;Ta({target:"RegExp",proto:!0,forced:/./.exec!==ap},{exec:ap});var Yv=Array.isArray||function(t){return da(t)=="Array"},FR=function(){},qct=[],TR=sh("Reflect","construct"),YC=/^\s*(?:class|function)\b/,Kct=Rt(YC.exec),Yct=!YC.exec(FR),Sf=function(t){if(!vn(t))return!1;try{return TR(FR,qct,t),!0}catch{return!1}},XC=!TR||Ye(function(){var t;return Sf(Sf.call)||!Sf(Object)||!Sf(function(){t=!0})||t})?function(t){if(!vn(t))return!1;switch(qC(t)){case"AsyncFunction":case"GeneratorFunction":case"AsyncGeneratorFunction":return!1}return Yct||!!Kct(YC,HC(t))}:Sf,_R=function(t,e,n){var r=zC(e);r in t?lh.f(t,r,jC(0,n)):t[r]=n},Xct=Nr("species"),ZC=function(t){return U6>=51||!Ye(function(){var e=[];return(e.constructor={})[Xct]=function(){return{foo:1}},e[t](Boolean).foo!==1})},Zct=Rt([].slice),Jct=ZC("slice"),Qct=Nr("species"),W2=_t.Array,tft=Math.max;function no(t,e){var n=typeof Symbol=="function"&&t[Symbol.iterator];if(!n)return t;var r,o,i=n.call(t),a=[];try{for(;(e===void 0||e-- >0)&&!(r=i.next()).done;)a.push(r.value)}catch(u){o={error:u}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a}function ZB(t){var e=t.selection;if(e==null)return!1;var n=no(E.nodes(t,{match:function(i){return A.checkNodeType(i,"table-cell")}}),1)[0];if(n){var r=no(n,2)[1],o=E.start(t,r);if(Bt.equals(e.anchor,o))return!0}return!1}function JB(t,e){var n,r,o=E.nodes(t,{at:e,match:function(s){return A.getNodeType(s)==="table"}}),i=!1;try{for(var a=function(s){var l=typeof Symbol=="function"&&Symbol.iterator,c=l&&s[l],f=0;if(c)return c.call(s);if(s&&typeof s.length=="number")return{next:function(){return s&&f>=s.length&&(s=void 0),{value:s&&s[f++],done:!s}}};throw new TypeError(l?"Object is not iterable.":"Symbol.iterator is not defined.")}(o),u=a.next();!u.done;u=a.next())u.value,i=!0}catch(s){n={error:s}}finally{try{u&&!u.done&&(r=a.return)&&r.call(a)}finally{if(n)throw n.error}}return i}Ta({target:"Array",proto:!0,forced:!Jct},{slice:function(t,e){var n,r,o,i=uh(this),a=Cm(i),u=ip(t,a),s=ip(e===void 0?a:e,a);if(Yv(i)&&(n=i.constructor,(XC(n)&&(n===W2||Yv(n.prototype))||Sr(n)&&(n=n[Qct])===null)&&(n=void 0),n===W2||n===void 0))return Zct(i,u,s);for(r=new(n===void 0?W2:n)(tft(s-u,0)),o=0;u<s;u++,o++)u in i&&_R(r,o,i[u]);return r.length=o,r}});var QB=Rt(Rt.bind),eft=Nr("species"),tF=_t.Array,nft=function(t,e){return new(function(n){var r;return Yv(n)&&(r=n.constructor,(XC(r)&&(r===tF||Yv(r.prototype))||Sr(r)&&(r=r[eft])===null)&&(r=void 0)),r===void 0?tF:r}(t))(e===0?0:e)},eF=Rt([].push),Ni=function(t){var e=t==1,n=t==2,r=t==3,o=t==4,i=t==6,a=t==7,u=t==5||i;return function(s,l,c,f){for(var p,d,v=MC(s),g=hR(v),m=function(D,x){return mR(D),x===void 0?D:QB?QB(D,x):function(){return D.apply(x,arguments)}}(l,c),y=Cm(g),h=0,b=f||nft,w=e?b(s,y):n||a?b(s,0):void 0;y>h;h++)if((u||h in g)&&(d=m(p=g[h],h,v),t))if(e)w[h]=d;else if(d)switch(t){case 3:return!0;case 5:return p;case 6:return h;case 2:eF(w,p)}else switch(t){case 4:return!1;case 7:eF(w,p)}return i?-1:r||o?o:w}},xm={forEach:Ni(0),map:Ni(1),filter:Ni(2),some:Ni(3),every:Ni(4),find:Ni(5),findIndex:Ni(6),filterReject:Ni(7)},rft=xm.map;Ta({target:"Array",proto:!0,forced:!ZC("map")},{map:function(t){return rft(this,t,arguments.length>1?arguments[1]:void 0)}});var oft=GC?{}.toString:function(){return"[object "+qC(this)+"]"};function Sm(t){var e=t.children||[];return e.length===0?[]:(e[0]||{}).children||[]}function PR(t){return Sm(t).every(function(e){return!!e.isHeader})}GC||op(Object.prototype,"toString",oft,{unsafe:!0});var ift=UC.PROPER,Z6=RegExp.prototype,jR=Z6.toString,aft=Rt(SR),uf
|
|
|
|
|
\v\f\r \u2028\u2029\uFEFF`,uF=Rt("".replace),Xv="["+e3+"]",xft=RegExp("^"+Xv+Xv+"*"),Sft=RegExp(Xv+Xv+"*$"),q2=function(t){return function(e){var n=An(Fa(e));return 1&t&&(n=uF(n,xft,"")),2&t&&(n=uF(n,Sft,"")),n}},Aft={start:q2(1),end:q2(2),trim:q2(3)},Oft=UC.PROPER,kft=Aft.trim;function MR(t){return t.length?t[0].tagName.toLowerCase():""}Ta({target:"String",proto:!0,forced:function(t){return Ye(function(){return!!e3[t]()||"
"[t]()!=="
"||Oft&&e3[t].name!==t})}("trim")},{trim:function(){return kft(this)}}),Ta({global:!0},{globalThis:_t}),Tr&&(B.fn.append=Tr),ko&&(B.fn.on=ko),Ca&&(B.fn.focus=Ca),Fr&&(B.fn.attr=Fr),Oo&&(B.fn.val=Oo),Da&&(B.fn.html=Da),Pl&&(B.fn.dataset=Pl),Fl&&(B.fn.addClass=Fl),Tl&&(B.fn.removeClass=Tl),Ll&&(B.fn.children=Ll),Jg&&(B.fn.each=Jg),Il&&(B.fn.find=Il);var up=!1,zR=0,$R=0,sp=null,lp=null,wd=B("body");function HR(t){up=!1,lp=null,sp=null,wd.off("mousemove",VR),wd.off("mouseup",HR)}wd.on("mousedown",function(t){var e=t.target;if((e.tagName==="TH"||e.tagName==="TD")&&e.style.cursor==="col-resize"){e.style.cursor="auto",t.preventDefault(),up=!0;var n=t.clientX;zR=n;var r=e.getBoundingClientRect().width;$R=r,wd.on("mousemove",VR),wd.on("mouseup",HR)}});var VR=Ku(function(t){if(up&&lp!=null&&sp!=null){t.preventDefault();var e=t.clientX,n=$R+(e-zR);(n=Math.floor(100*n)/100)<30&&(n=30),N.setNodes(lp,{width:n.toString()},{at:sp})}},100),Bft={type:"table",renderElem:function(t,e,n){var r=function(u,s){if(u.isDisabled())return!1;var l=u.selection;if(l==null||L.isCollapsed(l))return!0;var c=l.anchor,f=l.focus,p=A.findPath(u,s),d=E.start(u,p),v=E.end(u,p),g=Bt.compare(c,v)<=0&&Bt.compare(c,d)>=0,m=Bt.compare(f,v)<=0&&Bt.compare(f,d)>=0;return!!(g&&m&&j.equals(c.path.slice(0,3),f.path.slice(0,3)))}(n,t),o=t.width,i=o===void 0?"auto":o,a=bt("div",{className:"table-container","data-selected":A.isNodeSelected(n,t),on:{mousedown:function(u){if(u.target.tagName==="DIV"&&u.preventDefault(),!n.isDisabled()){var s=A.findPath(n,t),l=E.start(n,s),c=n.selection;c!=null?c.anchor.path[0]!==s[0]&&n.select(l):n.select(l)}}}},bt("table",{width:i,contentEditable:r},bt("colgroup",null,Sm(t).map(function(u){var s=u.width;return bt("col",{width:s===void 0?"auto":s})})),bt("tbody",null,e)));return a}},Fft={type:"table-row",renderElem:function(t,e,n){return bt("tr",null,e)}},Tft={type:"table-cell",renderElem:function(t,e,n){var r=function(p,d){var v=A.getParentNode(p,d);if(v==null)return!1;var g=A.getParentNode(p,v);return g!=null&&Sm(g).some(function(m){return m===d})}(n,t),o=t,i=o.colSpan,a=i===void 0?1:i,u=o.rowSpan,s=u===void 0?1:u,l=o.isHeader,c=l!==void 0&&l;if(!r)return bt("td",{colSpan:a,rowSpan:s},e);var f=bt(c?"th":"td",{colSpan:a,rowSpan:s,style:{borderRightWidth:"3px"},on:{mousemove:Ku(function(p){var d=this.elm;if(d!=null){var v=d.getBoundingClientRect(),g=v.left,m=v.width,y=v.top,h=v.height,b=p.clientX,w=p.clientY;up||(b>g+m-5&&b<g+m&&w>y&&w<y+h?(d.style.cursor="col-resize",lp=n,sp=A.findPath(n,t)):up||(d.style.cursor="auto",lp=null,sp=null))}},100)}},e);return f}},_ft={selector:"table",preParseHtml:function(t){var e=B(t);if(MR(e)!=="table")return t;var n=e.find("tbody");if(n.length===0)return t;var r=e.find("tr");return e.append(r),n.remove(),e[0]}},Pft=xm.filter;Ta({target:"Array",proto:!0,forced:!ZC("filter")},{filter:function(t){return Pft(this,t,arguments.length>1?arguments[1]:void 0)}});var jft=Math.floor,K2=Rt("".charAt),Nft=Rt("".replace),Y2=Rt("".slice),Ift=/\$([$&'`]|\d{1,2}|<[^>]*>)/g,Lft=/\$([$&'`]|\d{1,2})/g,Rft=function(t,e,n,r,o,i){var a=n+t.length,u=r.length,s=Lft;return o!==void 0&&(o=MC(o),s=Ift),Nft(i,s,function(l,c){var f;switch(K2(c,0)){case"$":return"$";case"&":return t;case"`":return Y2(e,0,n);case"'":return Y2(e,a);case"<":f=o[Y2(c,1,-1)];break;default:var p=+c;if(p===0)return l;if(p>u){var d=jft(p/10);return d===0?l:d<=u?r[d-1]===void 0?K2(c,1):r[d-1]+K2(c,1):l}f=r[p-1]}return f===void 0?"":f})},n3=Nr("replace"),Mft=Math.max,zft=Math.min,$ft=Rt([].concat),X2=Rt([].push),sF=Rt("".indexOf),lF=Rt("".slice),Hft="a".replace(/./,"$0")===
|
|
|
|
|
`)},s.deleteBackward=function(l){if(!ZB(s)){var c=s.selection;if(c){var f=E.before(s,c);if(f){var p=JB(s,f),d=JB(s,c);if(p&&!d)return}}n(l)}},s.handleTab=function(){var l;if(A.getSelectedNodeByType(s,"table")){var c=E.above(t);A.checkNodeType(c[0],"table-cell")&&N.select(t,c[1]);var f=E.next(t);if(f)f[0]&&f[0].text&&(f=(l=E.above(t,{at:f[1]}))!==null&&l!==void 0?l:f),N.select(t,f[1]);else{var p=s.children||[],d=p.length;if(A.checkNodeType(p[d-1],"table")){var v=A.genEmptyParagraph();N.insertNodes(s,v,{at:[d]}),s.handleTab()}}}else a()},s.deleteForward=function(l){ZB(s)||r(l)},s.normalizeNode=function(l){var c=no(l,2),f=c[0],p=c[1];if(A.getNodeType(f)!=="table")return o([f,p]);if(A.isLastNode(s,f)){var d=A.genEmptyParagraph();N.insertNodes(s,d,{at:[p[0]+1]})}},s.insertData=function(l){if(A.getSelectedNodeByType(s,"table")!=null){var c=l.getData("text/plain");c===`
|
|
|
|
|
`||/<img[^>]+>/.test(l.getData("text/html"))?i(l):E.insertText(s,c)}else i(l)},s.selectAll=function(){var l=s.selection;if(l!=null){var c=A.getSelectedNodeByType(s,"table-cell");if(c!=null){var f=l.anchor,p=l.focus;if(j.equals(f.path.slice(0,3),p.path.slice(0,3)))if(Q.string(c).length!==0){var d=A.findPath(s,c),v={anchor:E.start(s,d),focus:E.end(s,d)};s.select(v)}else u();else u()}else u()}else u()},s}};qn("en",{videoModule:{delete:"Delete",uploadVideo:"Upload video",insertVideo:"Insert video",videoSrc:"Video source",videoSrcPlaceHolder:"Video file url, or third-party <iframe>",videoPoster:"Video poster",videoPosterPlaceHolder:"Poster image url",ok:"Ok",editSize:"Edit size",width:"Width",height:"Height"}}),qn("zh-CN",{videoModule:{delete:"删除视频",uploadVideo:"上传视频",insertVideo:"插入视频",videoSrc:"视频地址",videoSrcPlaceHolder:"视频文件 url 或第三方 <iframe>",videoPoster:"视频封面",videoPosterPlaceHolder:"封面图片 url",ok:"确定",editSize:"修改尺寸",width:"宽度",height:"高度"}});/*! *****************************************************************************
|
|
|
|
|
Copyright (c) Microsoft Corporation.
|
|
|
|
|
|
|
|
|
|
Permission to use, copy, modify, and/or distribute this software for any
|
|
|
|
|
purpose with or without fee is hereby granted.
|
|
|
|
|
|
|
|
|
|
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
|
|
|
|
|
REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
|
|
|
|
|
AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
|
|
|
|
|
INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
|
|
|
|
|
LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
|
|
|
|
|
OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
|
|
|
|
|
PERFORMANCE OF THIS SOFTWARE.
|
|
|
|
|
***************************************************************************** */var Zv=function(){return Zv=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},Zv.apply(this,arguments)};function Am(t,e,n,r){return new(n||(n=Promise))(function(o,i){function a(l){try{s(r.next(l))}catch(c){i(c)}}function u(l){try{s(r.throw(l))}catch(c){i(c)}}function s(l){var c;l.done?o(l.value):(c=l.value,c instanceof n?c:new n(function(f){f(c)})).then(a,u)}s((r=r.apply(t,e||[])).next())})}function Om(t,e){var n,r,o,i,a={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]};return i={next:u(0),throw:u(1),return:u(2)},typeof Symbol=="function"&&(i[Symbol.iterator]=function(){return this}),i;function u(s){return function(l){return function(c){if(n)throw new TypeError("Generator is already executing.");for(;a;)try{if(n=1,r&&(o=2&c[0]?r.return:c[0]?r.throw||((o=r.return)&&o.call(r),0):r.next)&&!(o=o.call(r,c[1])).done)return o;switch(r=0,o&&(c=[2&c[0],o.value]),c[0]){case 0:case 1:o=c;break;case 4:return a.label++,{value:c[1],done:!1};case 5:a.label++,r=c[1],c=[0];continue;case 7:c=a.ops.pop(),a.trys.pop();continue;default:if(!((o=(o=a.trys).length>0&&o[o.length-1])||c[0]!==6&&c[0]!==2)){a=0;continue}if(c[0]===3&&(!o||c[1]>o[0]&&c[1]<o[3])){a.label=c[1];break}if(c[0]===6&&a.label<o[1]){a.label=o[1],o=c;break}if(o&&a.label<o[2]){a.label=o[2],a.ops.push(c);break}o[2]&&a.ops.pop(),a.trys.pop();continue}c=e.call(t,a)}catch(f){c=[6,f],r=0}finally{n=o=0}if(5&c[0])throw c[1];return{value:c[0]?c[1]:void 0,done:!0}}([s,l])}}}function Mu(t,e){var n=typeof Symbol=="function"&&t[Symbol.iterator];if(!n)return t;var r,o,i=n.call(t),a=[];try{for(;(e===void 0||e-- >0)&&!(r=i.next()).done;)a.push(r.value)}catch(u){o={error:u}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a}function odt(t){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var e,n=t[Symbol.asyncIterator];return n?n.call(t):(t=function(o){var i=typeof Symbol=="function"&&Symbol.iterator,a=i&&o[i],u=0;if(a)return a.call(o);if(o&&typeof o.length=="number")return{next:function(){return o&&u>=o.length&&(o=void 0),{value:o&&o[u++],done:!o}}};throw new TypeError(i?"Object is not iterable.":"Symbol.iterator is not defined.")}(t),e={},r("next"),r("throw"),r("return"),e[Symbol.asyncIterator]=function(){return this},e);function r(o){e[o]=t[o]&&function(i){return new Promise(function(a,u){(function(s,l,c,f){Promise.resolve(f).then(function(p){s({value:p,done:c})},l)})(a,u,(i=t[o](i)).done,i.value)})}}}var pF=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function QC(t){var e={exports:{}};return t(e,e.exports),e.exports}var Ii,fg,w0=function(t){return t&&t.Math==Math&&t},rt=w0(typeof globalThis=="object"&&globalThis)||w0(typeof window=="object"&&window)||w0(typeof self=="object"&&self)||w0(typeof pF=="object"&&pF)||function(){return this}()||Function("return this")(),de=function(t){try{return!!t()}catch{return!0}},Fo=!de(function(){return Object.defineProperty({},1,{get:function(){return 7}})[1]!=7}),Of=Function.prototype.call,le=Of.bind?Of.bind(Of):function(){return Of.apply(Of,arguments)},hF={}.propertyIsEnumerable,gF=Object.getOwnPropertyDescriptor,idt={f:gF&&!hF.call({1:2},1)?function(t){var e=gF(this,t);return!!e&&e.enumerable}:hF},km=function(t,e){return{enumerable:!(1&t),configurable:!(2&t),writable:!(4&t),value:e}},WR=Function.prototype,r3=WR.bind,o3=WR.call,adt=r3&&r3.bind(o3),Ct=r3?function(t){return t&&adt(o3,t)}:function(t){return t&&function(){return o3.apply(t,arguments)}},udt=Ct({}.toString),sdt=Ct("".slice),xo=function(t){return sdt(udt(t),8,-1)},tw=rt.Object,ldt=Ct("".split),t8=de(function(){return!tw("z").propertyIsEnumerable(0)})?function(t){return xo(t)=="String"?ldt(t,""):tw(t)}:tw,cdt=rt.TypeError,fh=function(t){if(t==null)throw cdt("Can't call method on "+t);return t},Ma=function(t){return t8(fh(t))},oe=function(t){return typeof
|
|
|
|
|
\v\f\r \u2028\u2029\uFEFF`,kF=Ct("".replace),o1="["+s3+"]",ept=RegExp("^"+o1+o1+"*"),npt=RegExp(o1+o1+"*$"),rw=function(t){return function(e){var n=wr(fh(e));return 1&t&&(n=kF(n,ept,"")),2&t&&(n=kF(n,npt,"")),n}},rpt={start:rw(1),end:rw(2),trim:rw(3)},opt=Dc.PROPER,ipt=rpt.trim;function BF(t){return t.length?t[0].tagName.toLowerCase():""}function QR(t,e,n){e===void 0&&(e="auto"),n===void 0&&(n="auto");var r=B(t);return r.attr("width",e),r.attr("height",n),r[0].outerHTML}$n({target:"String",proto:!0,forced:de(function(){return!!s3.trim()||"
".trim()!=="
"||opt&&s3.trim.name!=="trim"})},{trim:function(){return ipt(this)}}),$n({global:!0},{globalThis:rt}),Tr&&(B.fn.append=Tr),ko&&(B.fn.on=ko),Ca&&(B.fn.focus=Ca),Fr&&(B.fn.attr=Fr),Oo&&(B.fn.val=Oo),Da&&(B.fn.html=Da),Nl&&(B.fn.parent=Nl),_l&&(B.fn.hasClass=_l),Ml&&(B.fn.empty=Ml);var E0,apt={type:"video",renderElem:function(t,e,n){var r,o=t,i=o.src,a=i===void 0?"":i,u=o.poster,s=u===void 0?"":u,l=o.width,c=l===void 0?"auto":l,f=o.height,p=f===void 0?"auto":f,d=A.isNodeSelected(n,t);if(a.trim().indexOf("<iframe ")===0)r=bt("div",{className:"w-e-textarea-video-container","data-selected":d?"true":"",innerHTML:QR(a,c,p)});else{var v=bt("video",{poster:s,controls:!0},bt("source",{src:a,type:"video/mp4"}),`Sorry, your browser doesn't support embedded videos.
|
|
|
|
|
抱歉,浏览器不支持 video 视频`);c!=="auto"&&(v.data.width=c),p!=="auto"&&(v.data.height=p),r=bt("div",{className:"w-e-textarea-video-container","data-selected":d?"true":""},v)}return zl("div",{props:{contentEditable:!1},on:{mousedown:function(g){return g.preventDefault()}}},r)}},upt={type:"video",elemToHtml:function(t,e){var n=t,r=n.src,o=r===void 0?"":r,i=n.poster,a=i===void 0?"":i,u=n.width,s=u===void 0?"auto":u,l=n.height,c=l===void 0?"auto":l,f=`<div data-w-e-type="video" data-w-e-is-void>
|
|
|
|
|
`;return o.trim().indexOf("<iframe ")===0?f+=QR(o,s,c):f+='<video poster="'+a+'" controls="true" width="'+s+'" height="'+c+'"><source src="'+o+'" type="video/mp4"/></video>',f+`
|
|
|
|
|
</div>`}},spt=Object.keys||function(t){return ZR(t,e1)},lpt=Fo?Object.defineProperties:function(t,e){fn(t);for(var n,r=Ma(e),o=spt(e),i=o.length,a=0;i>a;)ci.f(t,n=o[a++],r[n]);return t},l3=os("document","documentElement"),tM=u8("IE_PROTO"),ow=function(){},eM=function(t){return"<script>"+t+"<\/script>"},FF=function(t){t.write(eM("")),t.close();var e=t.parentWindow.Object;return t=null,e},dg=function(){try{E0=new ActiveXObject("htmlfile")}catch{}var t,e;dg=typeof document<"u"?document.domain&&E0?FF(E0):((e=pp("iframe")).style.display="none",l3.appendChild(e),e.src="javascript:",(t=e.contentWindow.document).open(),t.write(eM("document.F=Object")),t.close(),t.F):FF(E0);for(var n=e1.length;n--;)delete dg.prototype[e1[n]];return dg()};Tm[tM]=!0;var l8=Object.create||function(t,e){var n;return t!==null?(ow.prototype=fn(t),n=new ow,ow.prototype=null,n[tM]=t):n=dg(),e===void 0?n:lpt(n,e)},c3=Re("unscopables"),f3=Array.prototype;f3[c3]==null&&ci.f(f3,c3,{configurable:!0,value:l8(null)});var Dd=function(t){f3[c3][t]=!0},cpt=XR.includes;$n({target:"Array",proto:!0},{includes:function(t){return cpt(this,t,arguments.length>1?arguments[1]:void 0)}}),Dd("includes");var fpt={selector:"iframe,video,p",preParseHtml:function(t){var e=B(t),n=e;if(BF(e)==="p"){var r=e.children();if(r.length===1){var o=r[0],i=o.tagName.toLowerCase();["iframe","video"].includes(i)&&(n=B(o))}}var a=BF(n);if(a!=="iframe"&&a!=="video"||n.parent().attr("data-w-e-type")==="video")return n[0];var u=B('<div data-w-e-type="video" data-w-e-is-void></div>');return u.append(n),u[0]}},TF=Ct(Ct.bind),gp=function(t,e){return _a(t),e===void 0?t:TF?TF(t,e):function(){return t.apply(e,arguments)}},i1=Array.isArray||function(t){return xo(t)=="Array"},nM=function(){},dpt=[],rM=os("Reflect","construct"),c8=/^\s*(?:class|function)\b/,ppt=Ct(c8.exec),hpt=!c8.exec(nM),Bf=function(t){if(!oe(t))return!1;try{return rM(nM,dpt,t),!0}catch{return!1}},f8=!rM||de(function(){var t;return Bf(Bf.call)||!Bf(Object)||!Bf(function(){t=!0})||t})?function(t){if(!oe(t))return!1;switch(Pm(t)){case"AsyncFunction":case"GeneratorFunction":case"AsyncGeneratorFunction":return!1}return hpt||!!ppt(c8,Fm(t))}:Bf,gpt=Re("species"),_F=rt.Array,vpt=function(t,e){return new(function(n){var r;return i1(n)&&(r=n.constructor,(f8(r)&&(r===_F||i1(r.prototype))||he(r)&&(r=r[gpt])===null)&&(r=void 0)),r===void 0?_F:r}(t))(e===0?0:e)},PF=Ct([].push),Li=function(t){var e=t==1,n=t==2,r=t==3,o=t==4,i=t==6,a=t==7,u=t==5||i;return function(s,l,c,f){for(var p,d,v=Bm(s),g=t8(v),m=gp(l,c),y=dh(g),h=0,b=f||vpt,w=e?b(s,y):n||a?b(s,0):void 0;y>h;h++)if((u||h in g)&&(d=m(p=g[h],h,v),t))if(e)w[h]=d;else if(d)switch(t){case 3:return!0;case 5:return p;case 6:return h;case 2:PF(w,p)}else switch(t){case 4:return!1;case 7:PF(w,p)}return i?-1:r||o?o:w}},d8={forEach:Li(0),map:Li(1),filter:Li(2),some:Li(3),every:Li(4),find:Li(5),findIndex:Li(6),filterReject:Li(7)},mpt=d8.find,jF=!0;"find"in[]&&Array(1).find(function(){jF=!1}),$n({target:"Array",proto:!0,forced:jF},{find:function(t){return mpt(this,t,arguments.length>1?arguments[1]:void 0)}}),Dd("find");var ypt=s8?{}.toString:function(){return"[object "+Pm(this)+"]"};function NF(t,e,n,r){return e===void 0&&(e=""),n===void 0&&(n="auto"),r===void 0&&(r="auto"),{type:"video",src:t,poster:e,width:n,height:r,children:[{text:""}]}}s8||or(Object.prototype,"toString",ypt,{unsafe:!0});var IF,iw,bpt={selector:'div[data-w-e-type="video"]',parseElemHtml:function(t,e,n){var r=B(t),o="",i="",a="auto",u="auto",s=r.find("iframe");if(s.length>0)return a=s.attr("width")||"auto",u=s.attr("height")||"auto",NF(o=s[0].outerHTML,i,a,u);var l=r.find("video");return(o=l.attr("src")||"")||l.length>0&&(o=l.find("source").attr("src")||""),a=l.attr("width")||"auto",u=l.attr("height")||"auto",NF(o,i=l.attr("poster")||"",a,u)}},oM=function(){var t=fn(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},p8=rt.RegExp,d3=de(function(){var t=p8("a","y");return t.lastIndex=2,t.exec("abcd")!=null}),wpt=d3||de(function(){return!p8("a","y").
|
|
|
|
|
`)&&t.flags==="s")}),xpt=rt.RegExp,Spt=de(function(){var t=xpt("(?<a>b)","g");return t.exec("b").groups.a!=="b"||"b".replace(t,"$<a>c")!=="bc"}),Apt=cr.get,Opt=r8("native-string-replace",String.prototype.replace),a1=RegExp.prototype.exec,p3=a1,kpt=Ct("".charAt),Bpt=Ct("".indexOf),Fpt=Ct("".replace),aw=Ct("".slice),uw=(iw=/b*/g,le(a1,IF=/a/,"a"),le(a1,iw,"a"),IF.lastIndex!==0||iw.lastIndex!==0),LF=Ept.BROKEN_CARET,sw=/()??/.exec("")[1]!==void 0;(uw||sw||LF||Cpt||Spt)&&(p3=function(t){var e,n,r,o,i,a,u,s=this,l=Apt(s),c=wr(t),f=l.raw;if(f)return f.lastIndex=s.lastIndex,e=le(p3,f,c),s.lastIndex=f.lastIndex,e;var p=l.groups,d=LF&&s.sticky,v=le(oM,s),g=s.source,m=0,y=c;if(d&&(v=Fpt(v,"y",""),Bpt(v,"g")===-1&&(v+="g"),y=aw(c,s.lastIndex),s.lastIndex>0&&(!s.multiline||s.multiline&&kpt(c,s.lastIndex-1)!==`
|
|
|
|
|
`)&&(g="(?: "+g+")",y=" "+y,m++),n=new RegExp("^(?:"+g+")",v)),sw&&(n=new RegExp("^"+g+"$(?!\\s)",v)),uw&&(r=s.lastIndex),o=le(a1,d?n:s,y),d?o?(o.input=aw(o.input,m),o[0]=aw(o[0],m),o.index=s.lastIndex,s.lastIndex+=o[0].length):s.lastIndex=0:uw&&o&&(s.lastIndex=s.global?o.index+o[0].length:r),sw&&o&&o.length>1&&le(Opt,o[0],n,function(){for(i=1;i<arguments.length-2;i++)arguments[i]===void 0&&(o[i]=void 0)}),o&&p)for(o.groups=a=l8(null),i=0;i<p.length;i++)a[(u=p[i])[0]]=o[u[1]];return o});var u1=p3;$n({target:"RegExp",proto:!0,forced:/./.exec!==u1},{exec:u1});var h8=Function.prototype,RF=h8.apply,Tpt=h8.bind,MF=h8.call,iM=typeof Reflect=="object"&&Reflect.apply||(Tpt?MF.bind(RF):function(){return MF.apply(RF,arguments)}),zF=(Re("species"),RegExp.prototype),_pt=Ct("".charAt),$F=Ct("".charCodeAt),Ppt=Ct("".slice),HF=function(t){return function(e,n){var r,o,i=wr(fh(e)),a=_m(n),u=i.length;return a<0||a>=u?t?"":void 0:(r=$F(i,a))<55296||r>56319||a+1===u||(o=$F(i,a+1))<56320||o>57343?t?_pt(i,a):r:t?Ppt(i,a,a+2):o-56320+(r-55296<<10)+65536}},aM={codeAt:HF(!1),charAt:HF(!0)},jpt=aM.charAt,Npt=function(t,e,n){return e+(n?jpt(t,e).length:1)},Ipt=Math.floor,lw=Ct("".charAt),Lpt=Ct("".replace),cw=Ct("".slice),Rpt=/\$([$&'`]|\d{1,2}|<[^>]*>)/g,Mpt=/\$([$&'`]|\d{1,2})/g,zpt=function(t,e,n,r,o,i){var a=n+t.length,u=r.length,s=Mpt;return o!==void 0&&(o=Bm(o),s=Rpt),Lpt(i,s,function(l,c){var f;switch(lw(c,0)){case"$":return"$";case"&":return t;case"`":return cw(e,0,n);case"'":return cw(e,a);case"<":f=o[cw(c,1,-1)];break;default:var p=+c;if(p===0)return l;if(p>u){var d=Ipt(p/10);return d===0?l:d<=u?r[d-1]===void 0?lw(c,1):r[d-1]+lw(c,1):l}f=r[p-1]}return f===void 0?"":f})},$pt=rt.TypeError,Hpt=function(t,e){var n=t.exec;if(oe(n)){var r=le(n,t,e);return r!==null&&fn(r),r}if(xo(t)==="RegExp")return le(u1,t,e);throw $pt("RegExp#exec called on incompatible receiver")},h3=Re("replace"),Vpt=Math.max,Upt=Math.min,Wpt=Ct([].concat),fw=Ct([].push),VF=Ct("".indexOf),UF=Ct("".slice),Gpt="a".replace(/./,"$0")==="$0",WF=!!/./[h3]&&/./[h3]("a","$0")==="";function uM(t){return t===void 0&&(t="r"),t+"-"+mj()}(function(t,e,n,r){var o=Re(t),i=!de(function(){var l={};return l[o]=function(){return 7},""[t](l)!=7}),a=i&&!de(function(){var l=!1,c=/a/;return c.exec=function(){return l=!0,null},c[o](""),!l});if(!i||!a||n){var u=Ct(/./[o]),s=function(l,c,f){var p=WF?"$":"$0";return[function(d,v){var g=fh(this),m=d==null?void 0:dp(d,h3);return m?le(m,d,g,v):le(c,wr(g),d,v)},function(d,v){var g=fn(this),m=wr(d);if(typeof v=="string"&&VF(v,p)===-1&&VF(v,"$<")===-1){var y=f(c,g,m,v);if(y.done)return y.value}var h=oe(v);h||(v=wr(v));var b=g.global;if(b){var w=g.unicode;g.lastIndex=0}for(var D=[];;){var x=Hpt(g,m);if(x===null||(fw(D,x),!b))break;wr(x[0])===""&&(g.lastIndex=Npt(m,YR(g.lastIndex),w))}for(var C,O="",T=0,R=0;R<D.length;R++){for(var H=wr((x=D[R])[0]),M=Vpt(Upt(_m(x.index),m.length),0),K=[],U=1;U<x.length;U++)fw(K,(C=x[U])===void 0?C:String(C));var W=x.groups;if(h){var q=Wpt([H],K,M,m);W!==void 0&&fw(q,W);var nt=wr(iM(v,void 0,q))}else nt=zpt(H,m,M,K,W,v);M>=T&&(O+=UF(m,T,M)+nt,T=M+H.length)}return O+UF(m,T)}]}(0,""[t],function(l,c,f,p,d){var v=Ct(l),g=c.exec;return g===u1||g===zF.exec?i&&!d?{done:!0,value:u(c,f,p)}:{done:!0,value:v(f,c,p)}:{done:!1}});or(String.prototype,t,s[0]),or(zF,o,s[1])}})("replace",0,!!de(function(){var t=/./;return t.exec=function(){var e=[];return e.groups={a:"7"},e},"".replace(t,"$<a>")!=="7"})||!Gpt||WF);var s1=rt.Promise,l1=function(t,e,n){for(var r in e)or(t,r,e[r],n);return t},qpt=rt.String,Kpt=rt.TypeError,Zl=Object.setPrototypeOf||("__proto__"in{}?function(){var t,e=!1,n={};try{(t=Ct(Object.getOwnPropertyDescriptor(Object.prototype,"__proto__").set))(n,[]),e=n instanceof Array}catch{}return function(r,o){return fn(r),function(i){if(typeof i=="object"||oe(i))return i;throw Kpt("Can't set "+qpt(i)+" as a prototype")}(o),e?t(r,o):r.__proto__=o,r}}():void 0),Ypt=ci.f,GF=Re("toStringTag"),c1=function(t,e,n){t&&!qe(t=n?t:t.prototype,GF)&&Ypt(t,GF,{configurable:!0,value:e})},qF=Re("species"),Xpt=rt.TypeError,g8=function(t,e){if(cp(e
|
|
|
|
|
`)&&t.flags==="s")}),Cgt=et.RegExp,xgt=ve(function(){var t=Cgt("(?<a>b)","g");return t.exec("b").groups.a!=="b"||"b".replace(t,"$<a>c")!=="bc"}),Sgt=fr.get,Agt=A8("native-string-replace",String.prototype.replace),w1=RegExp.prototype.exec,F3=w1,Ogt=Tt("".charAt),kgt=Tt("".indexOf),Bgt=Tt("".replace),Nw=Tt("".slice),Iw=(jw=/b*/g,Jt(w1,MT=/a/,"a"),Jt(w1,jw,"a"),MT.lastIndex!==0||jw.lastIndex!==0),zT=qM.BROKEN_CARET,Lw=/()??/.exec("")[1]!==void 0;(Iw||Lw||zT||Dgt||xgt)&&(F3=function(t){var e,n,r,o,i,a,u,s=this,l=Sgt(s),c=ya(t),f=l.raw;if(f)return f.lastIndex=s.lastIndex,e=Jt(F3,f,c),s.lastIndex=f.lastIndex,e;var p=l.groups,d=zT&&s.sticky,v=Jt(GM,s),g=s.source,m=0,y=c;if(d&&(v=Bgt(v,"y",""),kgt(v,"g")===-1&&(v+="g"),y=Nw(c,s.lastIndex),s.lastIndex>0&&(!s.multiline||s.multiline&&Ogt(c,s.lastIndex-1)!==`
|
|
|
|
|
`)&&(g="(?: "+g+")",y=" "+y,m++),n=new RegExp("^(?:"+g+")",v)),Lw&&(n=new RegExp("^"+g+"$(?!\\s)",v)),Iw&&(r=s.lastIndex),o=Jt(w1,d?n:s,y),d?o?(o.input=Nw(o.input,m),o[0]=Nw(o[0],m),o.index=s.lastIndex,s.lastIndex+=o[0].length):s.lastIndex=0:Iw&&o&&(s.lastIndex=s.global?o.index+o[0].length:r),Lw&&o&&o.length>1&&Jt(Agt,o[0],n,function(){for(i=1;i<arguments.length-2;i++)arguments[i]===void 0&&(o[i]=void 0)}),o&&p)for(o.groups=a=L8(null),i=0;i<p.length;i++)a[(u=p[i])[0]]=o[u[1]];return o});var xp=F3;Eo({target:"RegExp",proto:!0,forced:/./.exec!==xp},{exec:xp});var R8=Function.prototype,$T=R8.apply,Fgt=R8.bind,HT=R8.call,XM=typeof Reflect=="object"&&Reflect.apply||(Fgt?HT.bind($T):function(){return HT.apply($T,arguments)}),Tgt=Me("species"),Rw=RegExp.prototype,_gt=Me("match"),Pgt=et.TypeError,jgt=Me("species"),ZM=function(t,e){var n,r=dn(t).constructor;return r===void 0||(n=dn(r)[jgt])==null?e:function(o){if(N8(o))return o;throw Pgt(p1(o)+" is not a constructor")}(n)},Ngt=Tt("".charAt),VT=Tt("".charCodeAt),Igt=Tt("".slice),UT=function(t){return function(e,n){var r,o,i=ya(yp(e)),a=_8(n),u=i.length;return a<0||a>=u?t?"":void 0:(r=VT(i,a))<55296||r>56319||a+1===u||(o=VT(i,a+1))<56320||o>57343?t?Ngt(i,a):r:t?Igt(i,a,a+2):o-56320+(r-55296<<10)+65536}},JM={codeAt:UT(!1),charAt:UT(!0)},Lgt=JM.charAt,Rgt=function(t,e,n){return e+(n?Lgt(t,e).length:1)},Mgt=et.Array,zgt=Math.max,T3=function(t,e,n){for(var r=gh(t),o=Cp(e,r),i=Cp(n===void 0?r:n,r),a=Mgt(zgt(i-o,0)),u=0;o<i;o++,u++)UM(a,u,t[o]);return a.length=u,a},$gt=et.TypeError,WT=function(t,e){var n=t.exec;if(ae(n)){var r=Jt(n,t,e);return r!==null&&dn(r),r}if(Qr(t)==="RegExp")return Jt(xp,t,e);throw $gt("RegExp#exec called on incompatible receiver")},Ks=qM.UNSUPPORTED_Y,Hgt=Math.min,QM=[].push,Vgt=Tt(/./.exec),Ys=Tt(QM),Rf=Tt("".slice);(function(t,e,n,r){var o=Me(t),i=!ve(function(){var l={};return l[o]=function(){return 7},""[t](l)!=7}),a=i&&!ve(function(){var l=!1,c=/a/;return(c={}).constructor={},c.constructor[Tgt]=function(){return c},c.flags="",c[o]=/./[o],c.exec=function(){return l=!0,null},c[o](""),!l});if(!i||!a||n){var u=Tt(/./[o]),s=function(l,c,f){var p;return p="abbc".split(/(b)*/)[1]=="c"||"test".split(/(?:)/,-1).length!=4||"ab".split(/(?:ab)*/).length!=2||".".split(/(.?)(.?)/).length!=4||".".split(/()()/).length>1||"".split(/.?/).length?function(d,v){var g,m,y=ya(yp(this)),h=v===void 0?4294967295:v>>>0;if(h===0)return[];if(d===void 0)return[y];if(!fe(g=d)||!((m=g[_gt])!==void 0?m:Qr(g)=="RegExp"))return Jt(c,y,d,h);for(var b,w,D,x=[],C=(d.ignoreCase?"i":"")+(d.multiline?"m":"")+(d.unicode?"u":"")+(d.sticky?"y":""),O=0,T=new RegExp(d.source,C+"g");(b=Jt(xp,T,y))&&!((w=T.lastIndex)>O&&(Ys(x,Rf(y,O,b.index)),b.length>1&&b.index<y.length&&XM(QM,x,T3(b,1)),D=b[0].length,O=w,x.length>=h));)T.lastIndex===b.index&&T.lastIndex++;return O===y.length?!D&&Vgt(T,"")||Ys(x,""):Ys(x,Rf(y,O)),x.length>h?T3(x,0,h):x}:"0".split(void 0,0).length?function(d,v){return d===void 0&&v===0?[]:Jt(c,this,d,v)}:c,[function(d,v){var g=yp(this),m=d==null?void 0:Ep(d,l);return m?Jt(m,d,g,v):Jt(p,ya(g),d,v)},function(d,v){var g=dn(this),m=ya(d),y=f(p,g,m,v,p!==c);if(y.done)return y.value;var h=ZM(g,RegExp),b=g.unicode,w=(g.ignoreCase?"i":"")+(g.multiline?"m":"")+(g.unicode?"u":"")+(Ks?"g":"y"),D=new h(Ks?"^(?:"+g.source+")":g,w),x=v===void 0?4294967295:v>>>0;if(x===0)return[];if(m.length===0)return WT(D,m)===null?[m]:[];for(var C=0,O=0,T=[];O<m.length;){D.lastIndex=Ks?0:O;var R,H=WT(D,Ks?Rf(m,O):m);if(H===null||(R=Hgt(MM(D.lastIndex+(Ks?O:0)),m.length))===C)O=Rgt(m,O,b);else{if(Ys(T,Rf(m,C,O)),T.length===x)return T;for(var M=1;M<=H.length-1;M++)if(Ys(T,H[M]),T.length===x)return T;O=C=R}}return Ys(T,Rf(m,C)),T}]}(o,""[t],function(l,c,f,p,d){var v=Tt(l),g=c.exec;return g===xp||g===Rw.exec?i&&!d?{done:!0,value:u(c,f,p)}:{done:!0,value:v(f,c,p)}:{done:!1}});ir(String.prototype,t,s[0]),ir(Rw,o,s[1])}r&&So(Rw[o],"sham",!0)})("split",0,!!ve(function(){var t=/(?:)/,e=t.exec;t.exec=function(){return e.apply(this,arguments)};var n="ab".split(t);return n.length!==2||n[0]!=="a"||n[1]!=="b"}),Ks);/*! ***********
|
|
|
|
|
Copyright (c) Microsoft Corporation.
|
|
|
|
|
|
|
|
|
|
Permission to use, copy, modify, and/or distribute this software for any
|
|
|
|
|
purpose with or without fee is hereby granted.
|
|
|
|
|
|
|
|
|
|
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
|
|
|
|
|
REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
|
|
|
|
|
AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
|
|
|
|
|
INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
|
|
|
|
|
LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
|
|
|
|
|
OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
|
|
|
|
|
PERFORMANCE OF THIS SOFTWARE.
|
|
|
|
|
***************************************************************************** */var E1=function(){return E1=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},E1.apply(this,arguments)};function M8(t,e,n,r){return new(n||(n=Promise))(function(o,i){function a(l){try{s(r.next(l))}catch(c){i(c)}}function u(l){try{s(r.throw(l))}catch(c){i(c)}}function s(l){var c;l.done?o(l.value):(c=l.value,c instanceof n?c:new n(function(f){f(c)})).then(a,u)}s((r=r.apply(t,e||[])).next())})}function z8(t,e){var n,r,o,i,a={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]};return i={next:u(0),throw:u(1),return:u(2)},typeof Symbol=="function"&&(i[Symbol.iterator]=function(){return this}),i;function u(s){return function(l){return function(c){if(n)throw new TypeError("Generator is already executing.");for(;a;)try{if(n=1,r&&(o=2&c[0]?r.return:c[0]?r.throw||((o=r.return)&&o.call(r),0):r.next)&&!(o=o.call(r,c[1])).done)return o;switch(r=0,o&&(c=[2&c[0],o.value]),c[0]){case 0:case 1:o=c;break;case 4:return a.label++,{value:c[1],done:!1};case 5:a.label++,r=c[1],c=[0];continue;case 7:c=a.ops.pop(),a.trys.pop();continue;default:if(!((o=(o=a.trys).length>0&&o[o.length-1])||c[0]!==6&&c[0]!==2)){a=0;continue}if(c[0]===3&&(!o||c[1]>o[0]&&c[1]<o[3])){a.label=c[1];break}if(c[0]===6&&a.label<o[1]){a.label=o[1],o=c;break}if(o&&a.label<o[2]){a.label=o[2],a.ops.push(c);break}o[2]&&a.ops.pop(),a.trys.pop();continue}c=e.call(t,a)}catch(f){c=[6,f],r=0}finally{n=o=0}if(5&c[0])throw c[1];return{value:c[0]?c[1]:void 0,done:!0}}([s,l])}}}function Ugt(t){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var e,n=t[Symbol.asyncIterator];return n?n.call(t):(t=function(o){var i=typeof Symbol=="function"&&Symbol.iterator,a=i&&o[i],u=0;if(a)return a.call(o);if(o&&typeof o.length=="number")return{next:function(){return o&&u>=o.length&&(o=void 0),{value:o&&o[u++],done:!o}}};throw new TypeError(i?"Object is not iterable.":"Symbol.iterator is not defined.")}(t),e={},r("next"),r("throw"),r("return"),e[Symbol.asyncIterator]=function(){return this},e);function r(o){e[o]=t[o]&&function(i){return new Promise(function(a,u){(function(s,l,c,f){Promise.resolve(f).then(function(p){s({value:p,done:c})},l)})(a,u,(i=t[o](i)).done,i.value)})}}}var _3=Me("unscopables"),P3=Array.prototype;P3[_3]==null&&fi.f(P3,_3,{configurable:!0,value:L8(null)});var Vu,GT,qT,Mw=function(t){P3[_3][t]=!0},Ql={},Wgt=!ve(function(){function t(){}return t.prototype.constructor=null,Object.getPrototypeOf(new t)!==t.prototype}),KT=T8("IE_PROTO"),j3=et.Object,Ggt=j3.prototype,D1=Wgt?j3.getPrototypeOf:function(t){var e=O8(t);if(Ke(e,KT))return e[KT];var n=e.constructor;return ae(n)&&e instanceof n?n.prototype:e instanceof j3?Ggt:null},N3=Me("iterator"),tz=!1;[].keys&&("next"in(qT=[].keys())?(GT=D1(D1(qT)))!==Object.prototype&&(Vu=GT):tz=!0);var qgt=Vu==null||ve(function(){var t={};return Vu[N3].call(t)!==t});qgt&&(Vu={}),ae(Vu[N3])||ir(Vu,N3,function(){return this});var $8={IteratorPrototype:Vu,BUGGY_SAFARI_ITERATORS:tz},Kgt=fi.f,YT=Me("toStringTag"),C1=function(t,e,n){t&&!Ke(t=n?t:t.prototype,YT)&&Kgt(t,YT,{configurable:!0,value:e})},Ygt=$8.IteratorPrototype,Xgt=function(){return this},Zgt=et.String,Jgt=et.TypeError,tc=Object.setPrototypeOf||("__proto__"in{}?function(){var t,e=!1,n={};try{(t=Tt(Object.getOwnPropertyDescriptor(Object.prototype,"__proto__").set))(n,[]),e=n instanceof Array}catch{}return function(r,o){return dn(r),function(i){if(typeof i=="object"||ae(i))return i;throw Jgt("Can't set "+Zgt(i)+" as a prototype")}(o),e?t(r,o):r.__proto__=o,r}}():void 0),Qgt=hh.PROPER,tvt=hh.CONFIGURABLE,XT=$8.IteratorPrototype,T0=$8.BUGGY_SAFARI_ITERATORS,Mf=Me("iterator"),evt=function(){return this},ez=function(t,e,n,r,o,i,a){(function(y,h,b,w){var D=h+" Iterator";y.prototype=L8(Ygt,{next:jm(1,b)}),C1(y,D,!1),Ql[D]=Xgt})(n,e,r);var u,s,l,c=function(y){if(y===o&&g)return g;if(!T0&&y in d)return d[y];switch(y){case"keys":case"values":case"entries":return func
|
|
|
|
|
* Prism: Lightweight, robust, elegant syntax highlighting
|
|
|
|
|
*
|
|
|
|
|
* @license MIT <https://opensource.org/licenses/MIT>
|
|
|
|
|
* @author Lea Verou <https://lea.verou.me>
|
|
|
|
|
* @namespace
|
|
|
|
|
* @public
|
|
|
|
|
*/t.exports&&(t.exports=e),k1!==void 0&&(k1.Prism=e),e.languages.markup={comment:{pattern:/<!--(?:(?!<!--)[\s\S])*?-->/,greedy:!0},prolog:{pattern:/<\?[\s\S]+?\?>/,greedy:!0},doctype:{pattern:/<!DOCTYPE(?:[^>"'[\]]|"[^"]*"|'[^']*')+(?:\[(?:[^<"'\]]|"[^"]*"|'[^']*'|<(?!!--)|<!--(?:[^-]|-(?!->))*-->)*\]\s*)?>/i,greedy:!0,inside:{"internal-subset":{pattern:/(^[^\[]*\[)[\s\S]+(?=\]>$)/,lookbehind:!0,greedy:!0,inside:null},string:{pattern:/"[^"]*"|'[^']*'/,greedy:!0},punctuation:/^<!|>$|[[\]]/,"doctype-tag":/^DOCTYPE/i,name:/[^\s<>'"]+/}},cdata:{pattern:/<!\[CDATA\[[\s\S]*?\]\]>/i,greedy:!0},tag:{pattern:/<\/?(?!\d)[^\s>\/=$<%]+(?:\s(?:\s*[^\s>\/=]+(?:\s*=\s*(?:"[^"]*"|'[^']*'|[^\s'">=]+(?=[\s>]))|(?=[\s/>])))+)?\s*\/?>/,greedy:!0,inside:{tag:{pattern:/^<\/?[^\s>\/]+/,inside:{punctuation:/^<\/?/,namespace:/^[^\s>\/:]+:/}},"special-attr":[],"attr-value":{pattern:/=\s*(?:"[^"]*"|'[^']*'|[^\s'">=]+)/,inside:{punctuation:[{pattern:/^=/,alias:"attr-equals"},/"|'/]}},punctuation:/\/?>/,"attr-name":{pattern:/[^\s>\/]+/,inside:{namespace:/^[^\s>\/:]+:/}}}},entity:[{pattern:/&[\da-z]{1,8};/i,alias:"named-entity"},/&#x?[\da-f]{1,8};/i]},e.languages.markup.tag.inside["attr-value"].inside.entity=e.languages.markup.entity,e.languages.markup.doctype.inside["internal-subset"].inside=e.languages.markup,e.hooks.add("wrap",function(n){n.type==="entity"&&(n.attributes.title=n.content.replace(/&/,"&"))}),Object.defineProperty(e.languages.markup.tag,"addInlined",{value:function(n,r){var o={};o["language-"+r]={pattern:/(^<!\[CDATA\[)[\s\S]+?(?=\]\]>$)/i,lookbehind:!0,inside:e.languages[r]},o.cdata=/^<!\[CDATA\[|\]\]>$/i;var i={"included-cdata":{pattern:/<!\[CDATA\[[\s\S]*?\]\]>/i,inside:o}};i["language-"+r]={pattern:/[\s\S]+/,inside:e.languages[r]};var a={};a[n]={pattern:RegExp(/(<__[^>]*>)(?:<!\[CDATA\[(?:[^\]]|\](?!\]>))*\]\]>|(?!<!\[CDATA\[)[\s\S])*?(?=<\/__>)/.source.replace(/__/g,function(){return n}),"i"),lookbehind:!0,greedy:!0,inside:i},e.languages.insertBefore("markup","cdata",a)}}),Object.defineProperty(e.languages.markup.tag,"addAttribute",{value:function(n,r){e.languages.markup.tag.inside["special-attr"].push({pattern:RegExp(/(^|["'\s])/.source+"(?:"+n+")"+/\s*=\s*(?:"[^"]*"|'[^']*'|[^\s'">=]+(?=[\s>]))/.source,"i"),lookbehind:!0,inside:{"attr-name":/^[^\s=]+/,"attr-value":{pattern:/=[\s\S]+/,inside:{value:{pattern:/(^=\s*(["']|(?!["'])))\S[\s\S]*(?=\2$)/,lookbehind:!0,alias:[r,"language-"+r],inside:e.languages[r]},punctuation:[{pattern:/^=/,alias:"attr-equals"},/"|'/]}}}})}}),e.languages.html=e.languages.markup,e.languages.mathml=e.languages.markup,e.languages.svg=e.languages.markup,e.languages.xml=e.languages.extend("markup",{}),e.languages.ssml=e.languages.xml,e.languages.atom=e.languages.xml,e.languages.rss=e.languages.xml,function(n){var r=/(?:"(?:\\(?:\r\n|[\s\S])|[^"\\\r\n])*"|'(?:\\(?:\r\n|[\s\S])|[^'\\\r\n])*')/;n.languages.css={comment:/\/\*[\s\S]*?\*\//,atrule:{pattern:/@[\w-](?:[^;{\s]|\s+(?![\s{]))*(?:;|(?=\s*\{))/,inside:{rule:/^@[\w-]+/,"selector-function-argument":{pattern:/(\bselector\s*\(\s*(?![\s)]))(?:[^()\s]|\s+(?![\s)])|\((?:[^()]|\([^()]*\))*\))+(?=\s*\))/,lookbehind:!0,alias:"selector"},keyword:{pattern:/(^|[^\w-])(?:and|not|only|or)(?![\w-])/,lookbehind:!0}}},url:{pattern:RegExp("\\burl\\((?:"+r.source+"|"+/(?:[^\\\r\n()"']|\\[\s\S])*/.source+")\\)","i"),greedy:!0,inside:{function:/^url/i,punctuation:/^\(|\)$/,string:{pattern:RegExp("^"+r.source+"$"),alias:"url"}}},selector:{pattern:RegExp(`(^|[{}\\s])[^{}\\s](?:[^{};"'\\s]|\\s+(?![\\s{])|`+r.source+")*(?=\\s*\\{)"),lookbehind:!0},string:{pattern:r,greedy:!0},property:{pattern:/(^|[^-\w\xA0-\uFFFF])(?!\s)[-_a-z\xA0-\uFFFF](?:(?!\s)[-\w\xA0-\uFFFF])*(?=\s*:)/i,lookbehind:!0},important:/!important\b/i,function:{pattern:/(^|[^-a-z0-9])[-a-z0-9]+(?=\()/i,lookbehind:!0},punctuation:/[(){};:,]/},n.languages.css.atrule.inside.rest=n.languages.css;var o=n.languages.markup;o&&(o.tag.addInlined("style","css"),o.tag.addAttribute("style","css"))}(e),e.languages.clike={comment:[{pattern:/(^|[^\\])\/\*[\s\S]*?(?:\*\/|$)/,lookbehind:!0,greedy:!0},{pattern:/(^|[^\\:])\/\
|
|
|
|
|
`)&&t.flags==="s")}),ymt=Nt.RegExp,bmt=ln(function(){var t=ymt("(?<a>b)","g");return t.exec("b").groups.a!=="b"||"b".replace(t,"$<a>c")!=="bc"}),wmt=q3.get,Emt=Z8("native-string-replace",String.prototype.replace),_1=RegExp.prototype.exec,X3=_1,Dmt=Qt("".charAt),Cmt=Qt("".indexOf),xmt=Qt("".replace),f4=Qt("".slice),d4=(c4=/b*/g,Qe(_1,J_=/a/,"a"),Qe(_1,c4,"a"),J_.lastIndex!==0||c4.lastIndex!==0),Q_=Xz.BROKEN_CARET,p4=/()??/.exec("")[1]!==void 0;(d4||p4||Q_||mmt||bmt)&&(X3=function(t){var e,n,r,o,i,a,u,s=this,l=wmt(s),c=ri(t),f=l.raw;if(f)return f.lastIndex=s.lastIndex,e=Qe(X3,f,c),s.lastIndex=f.lastIndex,e;var p=l.groups,d=Q_&&s.sticky,v=Qe(Yz,s),g=s.source,m=0,y=c;if(d&&(v=xmt(v,"y",""),Cmt(v,"g")===-1&&(v+="g"),y=f4(c,s.lastIndex),s.lastIndex>0&&(!s.multiline||s.multiline&&Dmt(c,s.lastIndex-1)!==`
|
|
|
|
|
`)&&(g="(?: "+g+")",y=" "+y,m++),n=new RegExp("^(?:"+g+")",v)),p4&&(n=new RegExp("^"+g+"$(?!\\s)",v)),d4&&(r=s.lastIndex),o=Qe(_1,d?n:s,y),d?o?(o.input=f4(o.input,m),o[0]=f4(o[0],m),o.index=s.lastIndex,s.lastIndex+=o[0].length):s.lastIndex=0:d4&&o&&(s.lastIndex=s.global?o.index+o[0].length:r),p4&&o&&o.length>1&&Qe(Emt,o[0],n,function(){for(i=1;i<arguments.length-2;i++)arguments[i]===void 0&&(o[i]=void 0)}),o&&p)for(o.groups=a=gmt(null),i=0;i<p.length;i++)a[(u=p[i])[0]]=o[u[1]];return o});var kp=X3;zm({target:"RegExp",proto:!0,forced:/./.exec!==kp},{exec:kp});var dx=Function.prototype,tP=dx.apply,Smt=dx.bind,eP=dx.call,Amt=typeof Reflect=="object"&&Reflect.apply||(Smt?eP.bind(tP):function(){return eP.apply(tP,arguments)}),Omt=$a("species"),h4=RegExp.prototype,kmt=$a("match"),Bmt=Nt.TypeError,Fmt=$a("species"),Tmt=Qt("".charAt),nP=Qt("".charCodeAt),_mt=Qt("".slice),Pmt=function(t){return function(e,n){var r,o,i=ri(ec(e)),a=sx(n),u=i.length;return a<0||a>=u?t?"":void 0:(r=nP(i,a))<55296||r>56319||a+1===u||(o=nP(i,a+1))<56320||o>57343?t?Tmt(i,a):r:t?_mt(i,a,a+2):o-56320+(r-55296<<10)+65536}},jmt=Pmt(!0),Nmt=function(t,e,n){return e+(n?jmt(t,e).length:1)},Imt=Nt.Array,Lmt=Math.max,rP=function(t,e,n){for(var r,o,i,a,u=lx(t),s=K3(e,u),l=K3(n===void 0?u:n,u),c=Imt(Lmt(l-s,0)),f=0;s<l;s++,f++)r=c,o=f,i=t[s],(a=nx(o))in r?Rm.f(r,a,rx(0,i)):r[a]=i;return c.length=f,c},Rmt=Nt.TypeError,oP=function(t,e){var n=t.exec;if(On(n)){var r=Qe(n,t,e);return r!==null&&to(r),r}if(Ea(t)==="RegExp")return Qe(kp,t,e);throw Rmt("RegExp#exec called on incompatible receiver")},Qs=Xz.UNSUPPORTED_Y,Mmt=Math.min,Qz=[].push,zmt=Qt(/./.exec),tl=Qt(Qz),qf=Qt("".slice);(function(t,e,n,r){var o=$a(t),i=!ln(function(){var l={};return l[o]=function(){return 7},""[t](l)!=7}),a=i&&!ln(function(){var l=!1,c=/a/;return(c={}).constructor={},c.constructor[Omt]=function(){return c},c.flags="",c[o]=/./[o],c.exec=function(){return l=!0,null},c[o](""),!l});if(!i||!a||n){var u=Qt(/./[o]),s=function(l,c,f){var p;return p="abbc".split(/(b)*/)[1]=="c"||"test".split(/(?:)/,-1).length!=4||"ab".split(/(?:ab)*/).length!=2||".".split(/(.?)(.?)/).length!=4||".".split(/()()/).length>1||"".split(/.?/).length?function(d,v){var g,m,y=ri(ec(this)),h=v===void 0?4294967295:v>>>0;if(h===0)return[];if(d===void 0)return[y];if(!Wr(g=d)||!((m=g[kmt])!==void 0?m:Ea(g)=="RegExp"))return Qe(c,y,d,h);for(var b,w,D,x=[],C=(d.ignoreCase?"i":"")+(d.multiline?"m":"")+(d.unicode?"u":"")+(d.sticky?"y":""),O=0,T=new RegExp(d.source,C+"g");(b=Qe(kp,T,y))&&!((w=T.lastIndex)>O&&(tl(x,qf(y,O,b.index)),b.length>1&&b.index<y.length&&Amt(Qz,x,rP(b,1)),D=b[0].length,O=w,x.length>=h));)T.lastIndex===b.index&&T.lastIndex++;return O===y.length?!D&&zmt(T,"")||tl(x,""):tl(x,qf(y,O)),x.length>h?rP(x,0,h):x}:"0".split(void 0,0).length?function(d,v){return d===void 0&&v===0?[]:Qe(c,this,d,v)}:c,[function(d,v){var g=ec(this),m=d==null?void 0:Nz(d,l);return m?Qe(m,d,g,v):Qe(p,ri(g),d,v)},function(d,v){var g=to(this),m=ri(d),y=f(p,g,m,v,p!==c);if(y.done)return y.value;var h=function(K,U){var W,q=to(K).constructor;return q===void 0||(W=to(q)[Fmt])==null?U:function(nt){if(Hz(nt))return nt;throw Bmt(Pz(nt)+" is not a constructor")}(W)}(g,RegExp),b=g.unicode,w=(g.ignoreCase?"i":"")+(g.multiline?"m":"")+(g.unicode?"u":"")+(Qs?"g":"y"),D=new h(Qs?"^(?:"+g.source+")":g,w),x=v===void 0?4294967295:v>>>0;if(x===0)return[];if(m.length===0)return oP(D,m)===null?[m]:[];for(var C=0,O=0,T=[];O<m.length;){D.lastIndex=Qs?0:O;var R,H=oP(D,Qs?qf(m,O):m);if(H===null||(R=Mmt(Mz(D.lastIndex+(Qs?O:0)),m.length))===C)O=Nmt(m,O,b);else{if(tl(T,qf(m,C,O)),T.length===x)return T;for(var M=1;M<=H.length-1;M++)if(tl(T,H[M]),T.length===x)return T;O=C=R}}return tl(T,qf(m,C)),T}]}(o,""[t],function(l,c,f,p,d){var v=Qt(l),g=c.exec;return g===kp||g===h4.exec?i&&!d?{done:!0,value:u(c,f,p)}:{done:!0,value:v(f,c,p)}:{done:!1}});Op(String.prototype,t,s[0]),Op(h4,o,s[1])}r&&nc(h4[o],"sham",!0)})("split",0,!!ln(function(){var t=/(?:)/,e=t.exec;t.exec=function(){return e.apply(this,arguments)};var n="ab".split(t);return n.length!==2||n[0]!=="a"||n[1]!=="b"}),Qs)
|
|
|
|
|
Can not construct a instance`)}return t.setEditorConfig=function(e){e===void 0&&(e={}),this.editorConfig=Se(Se({},this.editorConfig),e)},t.setSimpleEditorConfig=function(e){e===void 0&&(e={}),this.simpleEditorConfig=Se(Se({},this.simpleEditorConfig),e)},t.setToolbarConfig=function(e){e===void 0&&(e={}),this.toolbarConfig=Se(Se({},this.toolbarConfig),e)},t.setSimpleToolbarConfig=function(e){e===void 0&&(e={}),this.simpleToolbarConfig=Se(Se({},this.simpleToolbarConfig),e)},t.registerPlugin=function(e){this.plugins.push(e)},t.registerMenu=function(e,n){(function(r,o){var i=r.key,a=r.factory,u=r.config,s=Er(Er({},u),o||{});if(Xd[i]!=null)throw new Error("Duplicated key '"+i+"' in menu items");Xd[i]=a,function(l,c){c!=null&&(AN[l]=c)}(i,s)})(e,n)},t.registerRenderElem=function(e){(function(n){var r=n.type,o=n.renderElem;ZN[r||""]=o})(e)},t.registerRenderStyle=function(e){(function(n){WE.push(n)})(e)},t.registerElemToHtml=function(e){(function(n){var r=n.type,o=n.elemToHtml;ON[r||""]=o})(e)},t.registerStyleToHtml=function(e){(function(n){RE.push(n)})(e)},t.registerPreParseHtml=function(e){(function(n){WN.push(n)})(e)},t.registerParseElemHtml=function(e){(function(n){var r=n.selector,o=n.parseElemHtml;vv[r]=o})(e)},t.registerParseStyleHtml=function(e){(function(n){xD.push(n)})(e)},t.registerModule=function(e){cu(e)},t.editorConfig={},t.simpleEditorConfig={},t.toolbarConfig={},t.simpleToolbarConfig={},t.plugins=[],t}();/*! *****************************************************************************
|
|
|
|
|
Copyright (c) Microsoft Corporation.
|
|
|
|
|
|
|
|
|
|
Permission to use, copy, modify, and/or distribute this software for any
|
|
|
|
|
purpose with or without fee is hereby granted.
|
|
|
|
|
|
|
|
|
|
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
|
|
|
|
|
REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
|
|
|
|
|
AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
|
|
|
|
|
INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
|
|
|
|
|
LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
|
|
|
|
|
OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
|
|
|
|
|
PERFORMANCE OF THIS SOFTWARE.
|
|
|
|
|
***************************************************************************** */function cu(t){var e=t.menus,n=t.renderElems,r=t.renderStyle,o=t.elemsToHtml,i=t.styleToHtml,a=t.preParseHtml,u=t.parseElemsHtml,s=t.parseStyleHtml,l=t.editorPlugin;e&&e.forEach(function(c){return on.registerMenu(c)}),n&&n.forEach(function(c){return on.registerRenderElem(c)}),r&&on.registerRenderStyle(r),o&&o.forEach(function(c){return on.registerElemToHtml(c)}),i&&on.registerStyleToHtml(i),a&&a.forEach(function(c){return on.registerPreParseHtml(c)}),u&&u.forEach(function(c){return on.registerParseElemHtml(c)}),s&&on.registerParseStyleHtml(s),l&&on.registerPlugin(l)}tut.forEach(function(t){return cu(t)}),cu(Tlt),cu(rdt),cu(d0t),cu(r1t),cu(Gmt);var n$='<svg viewBox="0 0 1024 1024"><path d="M959.877 128l0.123 0.123v767.775l-0.123 0.122H64.102l-0.122-0.122V128.123l0.122-0.123h895.775zM960 64H64C28.795 64 0 92.795 0 128v768c0 35.205 28.795 64 64 64h896c35.205 0 64-28.795 64-64V128c0-35.205-28.795-64-64-64zM832 288.01c0 53.023-42.988 96.01-96.01 96.01s-96.01-42.987-96.01-96.01S682.967 192 735.99 192 832 234.988 832 288.01zM896 832H128V704l224.01-384 256 320h64l224.01-192z"></path></svg>',r$={link:{menuKeys:["editLink","unLink","viewLink"]},image:{menuKeys:["imageWidth30","imageWidth50","imageWidth100","editImage","viewImageLink","deleteImage"]},pre:{menuKeys:["enter","codeBlock","codeSelectLang"]},table:{menuKeys:["enter","tableHeader","tableFullWidth","insertTableRow","deleteTableRow","insertTableCol","deleteTableCol","deleteTable"]},divider:{menuKeys:["enter"]},video:{menuKeys:["enter","editVideoSize"]}},Ymt={hoverbarKeys:Se(Se({},r$),{text:{menuKeys:["headerSelect","insertLink","bulletedList","|","bold","through","color","bgColor","clearStyle"]}})};on.setEditorConfig(Se(Se({},Ymt),{decorate:e$}));var Xmt={hoverbarKeys:r$};on.setSimpleEditorConfig(Se(Se({},Xmt),{decorate:e$}));var Zmt={toolbarKeys:["headerSelect","blockquote","|","bold","underline","italic",{key:"group-more-style",title:tt("editor.more"),iconSvg:'<svg viewBox="0 0 1024 1024"><path d="M204.8 505.6m-76.8 0a76.8 76.8 0 1 0 153.6 0 76.8 76.8 0 1 0-153.6 0Z"></path><path d="M505.6 505.6m-76.8 0a76.8 76.8 0 1 0 153.6 0 76.8 76.8 0 1 0-153.6 0Z"></path><path d="M806.4 505.6m-76.8 0a76.8 76.8 0 1 0 153.6 0 76.8 76.8 0 1 0-153.6 0Z"></path></svg>',menuKeys:["through","code","sup","sub","clearStyle"]},"color","bgColor","|","fontSize","fontFamily","lineHeight","|","bulletedList","numberedList","todo",{key:"group-justify",title:tt("editor.justify"),iconSvg:'<svg viewBox="0 0 1024 1024"><path d="M768 793.6v102.4H51.2v-102.4h716.8z m204.8-230.4v102.4H51.2v-102.4h921.6z m-204.8-230.4v102.4H51.2v-102.4h716.8zM972.8 102.4v102.4H51.2V102.4h921.6z"></path></svg>',menuKeys:["justifyLeft","justifyRight","justifyCenter","justifyJustify"]},{key:"group-indent",title:tt("editor.indent"),iconSvg:'<svg viewBox="0 0 1024 1024"><path d="M0 64h1024v128H0z m384 192h640v128H384z m0 192h640v128H384z m0 192h640v128H384zM0 832h1024v128H0z m0-128V320l256 192z"></path></svg>',menuKeys:["indent","delIndent"]},"|","emotion","insertLink",{key:"group-image",title:tt("editor.image"),iconSvg:n$,menuKeys:["insertImage","uploadImage"]},{key:"group-video",title:tt("editor.video"),iconSvg:'<svg viewBox="0 0 1024 1024"><path d="M981.184 160.096C837.568 139.456 678.848 128 512 128S186.432 139.456 42.816 160.096C15.296 267.808 0 386.848 0 512s15.264 244.16 42.816 351.904C186.464 884.544 345.152 896 512 896s325.568-11.456 469.184-32.096C1008.704 756.192 1024 637.152 1024 512s-15.264-244.16-42.816-351.904zM384 704V320l320 192-320 192z"></path></svg>',menuKeys:["insertVideo","uploadVideo"]},"insertTable","codeBlock","divider","|","undo","redo","|","fullScreen"]};on.setToolbarConfig(Zmt);var Jmt={toolbarKeys:["blockquote","header1","header2","header3","|","bold","underline","italic","through","color","bgColor","clearStyle","|","bulletedList","numberedList","todo","justifyLeft","justifyRight","justifyCenter","|","insertLink",{key:"group-image",title:tt("editor.image"),iconSvg:n$,menuKeys:["insertImage","uploadImage"]},"insertVideo"
|
|
|
|
|
Please use '@${t}' event instead of props`,e}var o$=(t,e)=>{for(const[n,r]of e)t[n]=r;return t};const syt=uP({props:{mode:{type:String,default:"default"},defaultContent:{type:Array,default:[]},defaultHtml:{type:String,default:""},defaultConfig:{type:Object,default:{}},modelValue:{type:String,default:""}},setup(t,e){const n=wg(null),r=sP(null),o=wg(""),i=()=>{if(!n.value)return;const u=u$(t.defaultContent);Qmt({selector:n.value,mode:t.mode,content:u||[],html:t.defaultHtml||t.modelValue||"",config:uyt(ayt({},t.defaultConfig),{onCreated(s){if(r.value=s,e.emit("onCreated",s),t.defaultConfig.onCreated){const l=Hi("onCreated");throw new Error(l)}},onChange(s){const l=s.getHtml();if(o.value=l,e.emit("update:modelValue",l),e.emit("onChange",s),t.defaultConfig.onChange){const c=Hi("onChange");throw new Error(c)}},onDestroyed(s){if(e.emit("onDestroyed",s),t.defaultConfig.onDestroyed){const l=Hi("onDestroyed");throw new Error(l)}},onMaxLength(s){if(e.emit("onMaxLength",s),t.defaultConfig.onMaxLength){const l=Hi("onMaxLength");throw new Error(l)}},onFocus(s){if(e.emit("onFocus",s),t.defaultConfig.onFocus){const l=Hi("onFocus");throw new Error(l)}},onBlur(s){if(e.emit("onBlur",s),t.defaultConfig.onBlur){const l=Hi("onBlur");throw new Error(l)}},customAlert(s,l){if(e.emit("customAlert",s,l),t.defaultConfig.customAlert){const c=Hi("customAlert");throw new Error(c)}},customPaste:(s,l)=>{if(t.defaultConfig.customPaste){const f=Hi("customPaste");throw new Error(f)}let c;return e.emit("customPaste",s,l,f=>{c=f}),c}})})};function a(u){const s=r.value;s!=null&&s.setHtml(u)}return lP(()=>{i()}),i$(()=>t.modelValue,u=>{u!==o.value&&a(u)}),{box:n}}}),lyt={ref:"box",style:{height:"100%"}};function cyt(t,e,n,r,o,i){return J3(),Q3("div",lyt,null,512)}var fyt=o$(syt,[["render",cyt]]);const dyt=uP({props:{editor:{type:Object},mode:{type:String,default:"default"},defaultConfig:{type:Object,default:{}}},setup(t){const e=wg(null),n=r=>{if(e.value){if(r==null)throw new Error("Not found instance of Editor when create <Toolbar/> component");A.getToolbar(r)||tyt({editor:r,selector:e.value||"<div></div>",mode:t.mode,config:t.defaultConfig})}};return a$(()=>{const{editor:r}=t;r!=null&&n(r)}),{selector:e}}}),pyt={ref:"selector"};function hyt(t,e,n,r,o,i){return J3(),Q3("div",pyt,null,512)}var gyt=o$(dyt,[["render",hyt]]);const vyt={components:{Editor:fyt,Toolbar:gyt},setup(){const t=sP(),e=wg("");lP(()=>{l$(()=>{t.value})});const n={excludeKeys:["headerSelect","italic","group-more-style"]},r={placeholder:"请输入内容..."};return c$(()=>{const v=t.value;v!=null&&v.destroy()}),{editorRef:t,mode:"default",valueHtml:e,toolbarConfig:n,editorConfig:r,handleCreated:v=>{t.value=v},handleChange:v=>{},handleDestroyed:v=>{},handleFocus:v=>{},handleBlur:v=>{},customAlert:(v,g)=>{alert(`【自定义提示】${g} - ${v}`)},customPaste:(v,g,m)=>{m(!0)},insertText:v=>{const g=t.value;g!=null&&g.insertText(v)},printHtml:()=>{t.value!=null},disable:()=>{const v=t.value;v!=null&&v.disable()}}}},myt={style:{"margin-top":"10px",border:"1px solid #ccc"}};function yyt(t,e,n,r,o,i){const a=gx("Toolbar"),u=gx("Editor");return J3(),Q3("div",null,[f$("div",myt,[vx(a,{editor:r.editorRef,defaultConfig:r.toolbarConfig,mode:r.mode,style:{"border-bottom":"1px solid #ccc"}},null,8,["editor","defaultConfig","mode"]),vx(u,{defaultConfig:r.editorConfig,mode:r.mode,modelValue:r.valueHtml,"onUpdate:modelValue":e[0]||(e[0]=s=>r.valueHtml=s),style:{height:"400px","overflow-y":"auto"},onOnCreated:r.handleCreated,onOnChange:r.handleChange,onOnDestroyed:r.handleDestroyed,onOnFocus:r.handleFocus,onOnBlur:r.handleBlur,onCustomAlert:r.customAlert,onCustomPaste:r.customPaste},null,8,["defaultConfig","mode","modelValue","onOnCreated","onOnChange","onOnDestroyed","onOnFocus","onOnBlur","onCustomAlert","onCustomPaste"])])])}const wyt=s$(vyt,[["render",yyt]]);export{wyt as W};
|