@wangeditor-kai/editor 5.6.40 → 5.6.42
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/core/src/parse-html/index.d.ts +2 -2
- package/dist/core/src/parse-html/parse-elem-html.d.ts +1 -7
- package/dist/css/style.css +1 -0
- package/dist/editor/src/register-builtin-modules/index.d.ts +1 -0
- package/dist/index.js +11 -4
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +10 -4
- package/dist/index.mjs.map +1 -1
- package/package.json +3 -1
package/dist/index.mjs
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
var e,t,n,r,o,i,a,s,u,l,c,d,f,p,h,g,v,m,y="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{};function b(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function E(e){if(Object.prototype.hasOwnProperty.call(e,"__esModule"))return e;var t=e.default;if("function"==typeof t){var n=function e(){var n=!1;try{n=this instanceof e}catch{}return n?Reflect.construct(t,arguments,this.constructor):t.apply(this,arguments)};n.prototype=t.prototype}else n={};return Object.defineProperty(n,"__esModule",{value:!0}),Object.keys(e).forEach(function(t){var r=Object.getOwnPropertyDescriptor(e,t);Object.defineProperty(n,t,r.get?r:{enumerable:!0,get:function(){return e[t]}})}),n}function C(){return t?e:(t=1,e=function(e){try{return!!e()}catch(e){return!0}})}function D(){if(r)return n;r=1;var e=C();return n=!e(function(){var e=function(){}.bind();return"function"!=typeof e||e.hasOwnProperty("prototype")})}function w(){if(i)return o;i=1;var e=D(),t=Function.prototype,n=t.call,r=e&&t.bind.bind(n,n);return o=e?r:function(e){return function(){return n.apply(e,arguments)}},o}function S(){if(s)return a;s=1;var e=w(),t=e({}.toString),n=e("".slice);return a=function(e){return n(t(e),8,-1)}}function A(){if(l)return u;l=1;var e=w(),t=C(),n=S(),r=Object,o=e("".split);return u=t(function(){return!r("z").propertyIsEnumerable(0)})?function(e){return"String"===n(e)?o(e,""):r(e)}:r}function x(){return d?c:(d=1,c=function(e){return null==e})}function O(){if(p)return f;p=1;var e=x(),t=TypeError;return f=function(n){if(e(n))throw new t("Can't call method on "+n);return n}}function N(){if(g)return h;g=1;var e=A(),t=O();return h=function(n){return e(t(n))}}function B(){if(m)return v;m=1;var e=function(e){return e&&e.Math===Math&&e};return v=e("object"==typeof globalThis&&globalThis)||e("object"==typeof window&&window)||e("object"==typeof self&&self)||e("object"==typeof y&&y)||e("object"==typeof v&&v)||function(){return this}()||Function("return this")()}var T,k,F,I,P,_,L,R,M,j,H,z,$,U,V,W,G,q,K,Y,X,Z,J,Q,ee,te,ne,re,oe,ie={exports:{}};function ae(){return k?T:(k=1,T=!1)}function se(){if(I)return F;I=1;var e=B(),t=Object.defineProperty;return F=function(n,r){try{t(e,n,{value:r,configurable:!0,writable:!0})}catch(t){e[n]=r}return r}}function ue(){if(P)return ie.exports;P=1;var e=ae(),t=B(),n=se(),r="__core-js_shared__",o=ie.exports=t[r]||n(r,{});return(o.versions||(o.versions=[])).push({version:"3.44.0",mode:e?"pure":"global",copyright:"© 2014-2025 Denis Pushkarev (zloirock.ru)",license:"https://github.com/zloirock/core-js/blob/v3.44.0/LICENSE",source:"https://github.com/zloirock/core-js"}),ie.exports}function le(){if(L)return _;L=1;var e=ue();return _=function(t,n){return e[t]||(e[t]=n||{})}}function ce(){if(M)return R;M=1;var e=O(),t=Object;return R=function(n){return t(e(n))}}function de(){if(H)return j;H=1;var e=w(),t=ce(),n=e({}.hasOwnProperty);return j=Object.hasOwn||function(e,r){return n(t(e),r)}}function fe(){if($)return z;$=1;var e=w(),t=0,n=Math.random(),r=e(1.1.toString);return z=function(e){return"Symbol("+(void 0===e?"":e)+")_"+r(++t+n,36)}}function pe(){if(G)return W;G=1;var e,t,n=B(),r=function(){if(V)return U;V=1;var e=B().navigator,t=e&&e.userAgent;return U=t?String(t):""}(),o=n.process,i=n.Deno,a=o&&o.versions||i&&i.version,s=a&&a.v8;return s&&(t=(e=s.split("."))[0]>0&&e[0]<4?1:+(e[0]+e[1])),!t&&r&&(!(e=r.match(/Edge\/(\d+)/))||e[1]>=74)&&(e=r.match(/Chrome\/(\d+)/))&&(t=+e[1]),W=t}function he(){if(K)return q;K=1;var e=pe(),t=C(),n=B().String;return q=!!Object.getOwnPropertySymbols&&!t(function(){var t=Symbol("symbol detection");return!n(t)||!(Object(t)instanceof Symbol)||!Symbol.sham&&e&&e<41}),q}function ge(){if(X)return Y;X=1;var e=he();return Y=e&&!Symbol.sham&&"symbol"==typeof Symbol.iterator}function ve(){if(J)return Z;J=1;var e=B(),t=le(),n=de(),r=fe(),o=he(),i=ge(),a=e.Symbol,s=t("wks"),u=i?a.for||a:a&&a.withoutSetter||r;return Z=function(e){return n(s,e)||(s[e]=o&&n(a,e)?a[e]:u("Symbol."+e)),s[e]}}function me(){if(ee)return Q;ee=1;var e="object"==typeof document&&document.all;return Q=void 0===e&&void 0!==e?function(t){return"function"==typeof t||t===e}:function(e){return"function"==typeof e}}function ye(){if(ne)return te;ne=1;var e=me();return te=function(t){return"object"==typeof t?null!==t:e(t)}}function be(){if(oe)return re;oe=1;var e=ye(),t=String,n=TypeError;return re=function(r){if(e(r))return r;throw new n(t(r)+" is not an object")}}var Ee,Ce,De,we,Se={};function Ae(){if(Ce)return Ee;Ce=1;var e=C();return Ee=!e(function(){return 7!==Object.defineProperty({},1,{get:function(){return 7}})[1]})}function xe(){if(we)return De;we=1;var e=Ae(),t=C();return De=e&&t(function(){return 42!==Object.defineProperty(function(){},"prototype",{value:42,writable:!1}).prototype})}var Oe,Ne,Be,Te,ke,Fe,Ie,Pe,_e,Le,Re,Me,je,He,ze,$e,Ue,Ve,We,Ge,qe,Ke,Ye,Xe,Ze,Je,Qe,et,tt,nt,rt,ot,it,at,st,ut,lt,ct,dt,ft,pt,ht,gt,vt,mt,yt,bt,Et,Ct,Dt,wt,St,At,xt,Ot,Nt,Bt,Tt,kt,Ft,It,Pt,_t,Lt,Rt={};function Mt(){if(Ne)return Oe;Ne=1;var e=B(),t=ye(),n=e.document,r=t(n)&&t(n.createElement);return Oe=function(e){return r?n.createElement(e):{}}}function jt(){if(Te)return Be;Te=1;var e=Ae(),t=C(),n=Mt();return Be=!e&&!t(function(){return 7!==Object.defineProperty(n("div"),"a",{get:function(){return 7}}).a})}function Ht(){if(Fe)return ke;Fe=1;var e=D(),t=Function.prototype.call;return ke=e?t.bind(t):function(){return t.apply(t,arguments)},ke}function zt(){if(Pe)return Ie;Pe=1;var e=B(),t=me();return Ie=function(n,r){return arguments.length<2?(o=e[n],t(o)?o:void 0):e[n]&&e[n][r];var o},Ie}function $t(){if(Le)return _e;Le=1;var e=w();return _e=e({}.isPrototypeOf)}function Ut(){if(Me)return Re;Me=1;var e=zt(),t=me(),n=$t(),r=ge(),o=Object;return Re=r?function(e){return"symbol"==typeof e}:function(r){var i=e("Symbol");return t(i)&&n(i.prototype,o(r))}}function Vt(){if(He)return je;He=1;var e=String;return je=function(t){try{return e(t)}catch(e){return"Object"}}}function Wt(){if($e)return ze;$e=1;var e=me(),t=Vt(),n=TypeError;return ze=function(r){if(e(r))return r;throw new n(t(r)+" is not a function")}}function Gt(){if(Ve)return Ue;Ve=1;var e=Wt(),t=x();return Ue=function(n,r){var o=n[r];return t(o)?void 0:e(o)},Ue}function qt(){if(Ke)return qe;Ke=1;var e=Ht(),t=ye(),n=Ut(),r=Gt(),o=function(){if(Ge)return We;Ge=1;var e=Ht(),t=me(),n=ye(),r=TypeError;return We=function(o,i){var a,s;if("string"===i&&t(a=o.toString)&&!n(s=e(a,o)))return s;if(t(a=o.valueOf)&&!n(s=e(a,o)))return s;if("string"!==i&&t(a=o.toString)&&!n(s=e(a,o)))return s;throw new r("Can't convert object to primitive value")},We}(),i=ve(),a=TypeError,s=i("toPrimitive");return qe=function(i,u){if(!t(i)||n(i))return i;var l,c=r(i,s);if(c){if(void 0===u&&(u="default"),l=e(c,i,u),!t(l)||n(l))return l;throw new a("Can't convert object to primitive value")}return void 0===u&&(u="number"),o(i,u)}}function Kt(){if(Xe)return Ye;Xe=1;var e=qt(),t=Ut();return Ye=function(n){var r=e(n,"string");return t(r)?r:r+""}}function Yt(){if(Ze)return Rt;Ze=1;var e=Ae(),t=jt(),n=xe(),r=be(),o=Kt(),i=TypeError,a=Object.defineProperty,s=Object.getOwnPropertyDescriptor,u="enumerable",l="configurable",c="writable";return Rt.f=e?n?function(e,t,n){if(r(e),t=o(t),r(n),"function"==typeof e&&"prototype"===t&&"value"in n&&c in n&&!n[c]){var i=s(e,t);i&&i[c]&&(e[t]=n.value,n={configurable:l in n?n[l]:i[l],enumerable:u in n?n[u]:i[u],writable:!1})}return a(e,t,n)}:a:function(e,n,s){if(r(e),n=o(n),r(s),t)try{return a(e,n,s)}catch(e){}if("get"in s||"set"in s)throw new i("Accessors not supported");return"value"in s&&(e[n]=s.value),e},Rt}function Xt(){if(tt)return et;tt=1;var e=function(){if(Qe)return Je;Qe=1;var e=Math.ceil,t=Math.floor;return Je=Math.trunc||function(n){var r=+n;return(r>0?t:e)(r)},Je}();return et=function(t){var n=+t;return n!=n||0===n?0:e(n)}}function Zt(){if(it)return ot;it=1;var e=Xt(),t=Math.min;return ot=function(n){var r=e(n);return r>0?t(r,9007199254740991):0}}function Jt(){if(st)return at;st=1;var e=Zt();return at=function(t){return e(t.length)}}function Qt(){if(lt)return ut;lt=1;var e=N(),t=function(){if(rt)return nt;rt=1;var e=Xt(),t=Math.max,n=Math.min;return nt=function(r,o){var i=e(r);return i<0?t(i+o,0):n(i,o)},nt}(),n=Jt(),r=function(r){return function(o,i,a){var s=e(o),u=n(s);if(0===u)return!r&&-1;var l,c=t(a,u);if(r&&i!=i){for(;u>c;)if((l=s[c++])!=l)return!0}else for(;u>c;c++)if((r||c in s)&&s[c]===i)return r||c||0;return!r&&-1}};return ut={includes:r(!0),indexOf:r(!1)}}function en(){return dt?ct:(dt=1,ct={})}function tn(){if(pt)return ft;pt=1;var e=w(),t=de(),n=N(),r=Qt().indexOf,o=en(),i=e([].push);return ft=function(e,a){var s,u=n(e),l=0,c=[];for(s in u)!t(o,s)&&t(u,s)&&i(c,s);for(;a.length>l;)t(u,s=a[l++])&&(~r(c,s)||i(c,s));return c},ft}function nn(){return gt?ht:(gt=1,ht=["constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleString","toString","valueOf"])}function rn(){if(yt)return Se;yt=1;var e=Ae(),t=xe(),n=Yt(),r=be(),o=N(),i=function(){if(mt)return vt;mt=1;var e=tn(),t=nn();return vt=Object.keys||function(n){return e(n,t)},vt}();return Se.f=e&&!t?Object.defineProperties:function(e,t){r(e);for(var a,s=o(t),u=i(t),l=u.length,c=0;l>c;)n.f(e,a=u[c++],s[a]);return e},Se}function on(){if(Dt)return Ct;Dt=1;var e=le(),t=fe(),n=e("keys");return Ct=function(e){return n[e]||(n[e]=t(e))}}function an(){if(St)return wt;St=1;var e,t=be(),n=rn(),r=nn(),o=en(),i=function(){if(Et)return bt;Et=1;var e=zt();return bt=e("document","documentElement")}(),a=Mt(),s=on(),u="prototype",l="script",c=s("IE_PROTO"),d=function(){},f=function(e){return"<"+l+">"+e+"</"+l+">"},p=function(e){e.write(f("")),e.close();var t=e.parentWindow.Object;return e=null,t},h=function(){try{e=new ActiveXObject("htmlfile")}catch(e){}var t,n,o;h="undefined"!=typeof document?document.domain&&e?p(e):(n=a("iframe"),o="java"+l+":",n.style.display="none",i.appendChild(n),n.src=String(o),(t=n.contentWindow.document).open(),t.write(f("document.F=Object")),t.close(),t.F):p(e);for(var s=r.length;s--;)delete h[u][r[s]];return h()};return o[c]=!0,wt=Object.create||function(e,r){var o;return null!==e?(d[u]=t(e),o=new d,d[u]=null,o[c]=e):o=h(),void 0===r?o:n.f(o,r)},wt}function sn(){return Nt?Ot:(Nt=1,Ot={})}function un(){return Ft?kt:(Ft=1,kt=function(e,t){return{enumerable:!(1&e),configurable:!(2&e),writable:!(4&e),value:t}})}function ln(){if(Pt)return It;Pt=1;var e=Ae(),t=Yt(),n=un();return It=e?function(e,r,o){return t.f(e,r,n(1,o))}:function(e,t,n){return e[t]=n,e}}function cn(){if(Lt)return _t;Lt=1;var e,t,n,r=function(){if(Tt)return Bt;Tt=1;var e=B(),t=me(),n=e.WeakMap;return Bt=t(n)&&/native code/.test(String(n))}(),o=B(),i=ye(),a=ln(),s=de(),u=ue(),l=on(),c=en(),d="Object already initialized",f=o.TypeError,p=o.WeakMap;if(r||u.state){var h=u.state||(u.state=new p);h.get=h.get,h.has=h.has,h.set=h.set,e=function(e,t){if(h.has(e))throw new f(d);return t.facade=e,h.set(e,t),t},t=function(e){return h.get(e)||{}},n=function(e){return h.has(e)}}else{var g=l("state");c[g]=!0,e=function(e,t){if(s(e,g))throw new f(d);return t.facade=e,a(e,g,t),t},t=function(e){return s(e,g)?e[g]:{}},n=function(e){return s(e,g)}}return _t={set:e,get:t,has:n,enforce:function(r){return n(r)?t(r):e(r,{})},getterFor:function(e){return function(n){var r;if(!i(n)||(r=t(n)).type!==e)throw new f("Incompatible receiver, "+e+" required");return r}}}}var dn,fn,pn={},hn={};function gn(){if(fn)return pn;fn=1;var e=Ae(),t=Ht(),n=function(){if(dn)return hn;dn=1;var e={}.propertyIsEnumerable,t=Object.getOwnPropertyDescriptor,n=t&&!e.call({1:2},1);return hn.f=n?function(e){var n=t(this,e);return!!n&&n.enumerable}:e,hn}(),r=un(),o=N(),i=Kt(),a=de(),s=jt(),u=Object.getOwnPropertyDescriptor;return pn.f=e?u:function(e,l){if(e=o(e),l=i(l),s)try{return u(e,l)}catch(e){}if(a(e,l))return r(!t(n.f,e,l),e[l])},pn}var vn,mn,yn,bn,En,Cn,Dn,wn={exports:{}};function Sn(){if(mn)return vn;mn=1;var e=Ae(),t=de(),n=Function.prototype,r=e&&Object.getOwnPropertyDescriptor,o=t(n,"name"),i=o&&"something"===function(){}.name,a=o&&(!e||e&&r(n,"name").configurable);return vn={EXISTS:o,PROPER:i,CONFIGURABLE:a}}function An(){if(bn)return yn;bn=1;var e=w(),t=me(),n=ue(),r=e(Function.toString);return t(n.inspectSource)||(n.inspectSource=function(e){return r(e)}),yn=n.inspectSource}function xn(){if(En)return wn.exports;En=1;var e=w(),t=C(),n=me(),r=de(),o=Ae(),i=Sn().CONFIGURABLE,a=An(),s=cn(),u=s.enforce,l=s.get,c=String,d=Object.defineProperty,f=e("".slice),p=e("".replace),h=e([].join),g=o&&!t(function(){return 8!==d(function(){},"length",{value:8}).length}),v=String(String).split("String"),m=wn.exports=function(e,t,n){"Symbol("===f(c(t),0,7)&&(t="["+p(c(t),/^Symbol\(([^)]*)\).*$/,"$1")+"]"),n&&n.getter&&(t="get "+t),n&&n.setter&&(t="set "+t),(!r(e,"name")||i&&e.name!==t)&&(o?d(e,"name",{value:t,configurable:!0}):e.name=t),g&&n&&r(n,"arity")&&e.length!==n.arity&&d(e,"length",{value:n.arity});try{n&&r(n,"constructor")&&n.constructor?o&&d(e,"prototype",{writable:!1}):e.prototype&&(e.prototype=void 0)}catch(e){}var a=u(e);return r(a,"source")||(a.source=h(v,"string"==typeof t?t:"")),e};return Function.prototype.toString=m(function(){return n(this)&&l(this).source||a(this)},"toString"),wn.exports}function On(){if(Dn)return Cn;Dn=1;var e=me(),t=Yt(),n=xn(),r=se();return Cn=function(o,i,a,s){s||(s={});var u=s.enumerable,l=void 0!==s.name?s.name:i;if(e(a)&&n(a,l,s),s.global)u?o[i]=a:r(i,a);else{try{s.unsafe?o[i]&&(u=!0):delete o[i]}catch(e){}u?o[i]=a:t.f(o,i,{value:a,enumerable:!1,configurable:!s.nonConfigurable,writable:!s.nonWritable})}return o},Cn}var Nn,Bn={};var Tn,kn,Fn,In,Pn,_n,Ln,Rn,Mn,jn,Hn,zn,$n,Un,Vn,Wn,Gn,qn,Kn,Yn,Xn,Zn,Jn,Qn,er,tr,nr,rr,or,ir,ar,sr,ur,lr={};function cr(){if(Fn)return kn;Fn=1;var e=zt(),t=w(),n=function(){if(Nn)return Bn;Nn=1;var e=tn(),t=nn().concat("length","prototype");return Bn.f=Object.getOwnPropertyNames||function(n){return e(n,t)},Bn}(),r=(Tn||(Tn=1,lr.f=Object.getOwnPropertySymbols),lr),o=be(),i=t([].concat);return kn=e("Reflect","ownKeys")||function(e){var t=n.f(o(e)),a=r.f;return a?i(t,a(e)):t},kn}function dr(){if(Pn)return In;Pn=1;var e=de(),t=cr(),n=gn(),r=Yt();return In=function(o,i,a){for(var s=t(i),u=r.f,l=n.f,c=0;c<s.length;c++){var d=s[c];e(o,d)||a&&e(a,d)||u(o,d,l(i,d))}},In}function fr(){if(Mn)return Rn;Mn=1;var e=B(),t=gn().f,n=ln(),r=On(),o=se(),i=dr(),a=function(){if(Ln)return _n;Ln=1;var e=C(),t=me(),n=/#|\.prototype\./,r=function(n,r){var u=i[o(n)];return u===s||u!==a&&(t(r)?e(r):!!r)},o=r.normalize=function(e){return String(e).replace(n,".").toLowerCase()},i=r.data={},a=r.NATIVE="N",s=r.POLYFILL="P";return _n=r}();return Rn=function(s,u){var l,c,d,f,p,h=s.target,g=s.global,v=s.stat;if(l=g?e:v?e[h]||o(h,{}):e[h]&&e[h].prototype)for(c in u){if(f=u[c],d=s.dontCallGetSet?(p=t(l,c))&&p.value:l[c],!a(g?c:h+(v?".":"#")+c,s.forced)&&void 0!==d){if(typeof f==typeof d)continue;i(f,d)}(s.sham||d&&d.sham)&&n(f,"sham",!0),r(l,c,f,s)}}}function pr(){if($n)return zn;$n=1;var e=de(),t=me(),n=ce(),r=on(),o=function(){if(Hn)return jn;Hn=1;var e=C();return jn=!e(function(){function e(){}return e.prototype.constructor=null,Object.getPrototypeOf(new e)!==e.prototype}),jn}(),i=r("IE_PROTO"),a=Object,s=a.prototype;return zn=o?a.getPrototypeOf:function(r){var o=n(r);if(e(o,i))return o[i];var u=o.constructor;return t(u)&&o instanceof u?u.prototype:o instanceof a?s:null},zn}function hr(){if(Vn)return Un;Vn=1;var e,t,n,r=C(),o=me(),i=ye(),a=an(),s=pr(),u=On(),l=ve(),c=ae(),d=l("iterator"),f=!1;return[].keys&&("next"in(n=[].keys())?(t=s(s(n)))!==Object.prototype&&(e=t):f=!0),!i(e)||r(function(){var t={};return e[d].call(t)!==t})?e={}:c&&(e=a(e)),o(e[d])||u(e,d,function(){return this}),Un={IteratorPrototype:e,BUGGY_SAFARI_ITERATORS:f}}function gr(){if(Gn)return Wn;Gn=1;var e=Yt().f,t=de(),n=ve()("toStringTag");return Wn=function(r,o,i){r&&!i&&(r=r.prototype),r&&!t(r,n)&&e(r,n,{configurable:!0,value:o})}}function vr(){if(er)return Qn;er=1;var e=function(){if(Jn)return Zn;Jn=1;var e=ye();return Zn=function(t){return e(t)||null===t}}(),t=String,n=TypeError;return Qn=function(r){if(e(r))return r;throw new n("Can't set "+t(r)+" as a prototype")}}function mr(){if(nr)return tr;nr=1;var e=function(){if(Xn)return Yn;Xn=1;var e=w(),t=Wt();return Yn=function(n,r,o){try{return e(t(Object.getOwnPropertyDescriptor(n,r)[o]))}catch(e){}}}(),t=ye(),n=O(),r=vr();return tr=Object.setPrototypeOf||("__proto__"in{}?function(){var o,i=!1,a={};try{(o=e(Object.prototype,"__proto__","set"))(a,[]),i=a instanceof Array}catch(e){}return function(e,a){return n(e),r(a),t(e)?(i?o(e,a):e.__proto__=a,e):e}}():void 0),tr}function yr(){if(or)return rr;or=1;var e=fr(),t=Ht(),n=ae(),r=Sn(),o=me(),i=function(){if(Kn)return qn;Kn=1;var e=hr().IteratorPrototype,t=an(),n=un(),r=gr(),o=sn(),i=function(){return this};return qn=function(a,s,u,l){var c=s+" Iterator";return a.prototype=t(e,{next:n(+!l,u)}),r(a,c,!1,!0),o[c]=i,a}}(),a=pr(),s=mr(),u=gr(),l=ln(),c=On(),d=ve(),f=sn(),p=hr(),h=r.PROPER,g=r.CONFIGURABLE,v=p.IteratorPrototype,m=p.BUGGY_SAFARI_ITERATORS,y=d("iterator"),b="keys",E="values",C="entries",D=function(){return this};return rr=function(r,d,p,w,S,A,x){i(p,d,w);var O,N,B,T=function(e){if(e===S&&_)return _;if(!m&&e&&e in I)return I[e];switch(e){case b:case E:case C:return function(){return new p(this,e)}}return function(){return new p(this)}},k=d+" Iterator",F=!1,I=r.prototype,P=I[y]||I["@@iterator"]||S&&I[S],_=!m&&P||T(S),L="Array"===d&&I.entries||P;if(L&&(O=a(L.call(new r)))!==Object.prototype&&O.next&&(n||a(O)===v||(s?s(O,v):o(O[y])||c(O,y,D)),u(O,k,!0,!0),n&&(f[k]=D)),h&&S===E&&P&&P.name!==E&&(!n&&g?l(I,"name",E):(F=!0,_=function(){return t(P,this)})),S)if(N={values:T(E),keys:A?_:T(b),entries:T(C)},x)for(B in N)(m||F||!(B in I))&&c(I,B,N[B]);else e({target:d,proto:!0,forced:m||F},N);return n&&!x||I[y]===_||c(I,y,_,{name:S}),f[d]=_,N}}function br(){return ar?ir:(ar=1,ir=function(e,t){return{value:e,done:t}})}function Er(){if(ur)return sr;ur=1;var e=N(),t=function(){if(xt)return At;xt=1;var e=ve(),t=an(),n=Yt().f,r=e("unscopables"),o=Array.prototype;return void 0===o[r]&&n(o,r,{configurable:!0,value:t(null)}),At=function(e){o[r][e]=!0}}(),n=sn(),r=cn(),o=Yt().f,i=yr(),a=br(),s=ae(),u=Ae(),l="Array Iterator",c=r.set,d=r.getterFor(l);sr=i(Array,"Array",function(t,n){c(this,{type:l,target:e(t),index:0,kind:n})},function(){var e=d(this),t=e.target,n=e.index++;if(!t||n>=t.length)return e.target=null,a(void 0,!0);switch(e.kind){case"keys":return a(n,!1);case"values":return a(t[n],!1)}return a([n,t[n]],!1)},"values");var f=n.Arguments=n.Array;if(t("keys"),t("values"),t("entries"),!s&&u&&"values"!==f.name)try{o(f,"name",{value:"values"})}catch(e){}return sr}Er();var Cr,Dr,wr,Sr,Ar,xr,Or,Nr={};function Br(){if(Dr)return Cr;Dr=1;var e={};return e[ve()("toStringTag")]="z",Cr="[object z]"===String(e)}function Tr(){if(Sr)return wr;Sr=1;var e=Br(),t=me(),n=S(),r=ve()("toStringTag"),o=Object,i="Arguments"===n(function(){return arguments}());return wr=e?n:function(e){var a,s,u;return void 0===e?"Undefined":null===e?"Null":"string"==typeof(s=function(e,t){try{return e[t]}catch(e){}}(a=o(e),r))?s:i?n(a):"Object"===(u=n(a))&&t(a.callee)?"Arguments":u},wr}!function(){if(Or)return Nr;Or=1;var e=Br(),t=On(),n=function(){if(xr)return Ar;xr=1;var e=Br(),t=Tr();return Ar=e?{}.toString:function(){return"[object "+t(this)+"]"}}();e||t(Object.prototype,"toString",n,{unsafe:!0})}();var kr,Fr,Ir,Pr,_r,Lr,Rr,Mr,jr,Hr,zr,$r,Ur,Vr={};function Wr(){if(Fr)return kr;Fr=1;var e=Tr(),t=String;return kr=function(n){if("Symbol"===e(n))throw new TypeError("Cannot convert a Symbol value to a string");return t(n)}}function Gr(){if(Pr)return Ir;Pr=1;var e=be();return Ir=function(){var t=e(this),n="";return t.hasIndices&&(n+="d"),t.global&&(n+="g"),t.ignoreCase&&(n+="i"),t.multiline&&(n+="m"),t.dotAll&&(n+="s"),t.unicode&&(n+="u"),t.unicodeSets&&(n+="v"),t.sticky&&(n+="y"),n}}function qr(){if($r)return zr;$r=1;var e,t,n=Ht(),r=w(),o=Wr(),i=Gr(),a=function(){if(Lr)return _r;Lr=1;var e=C(),t=B().RegExp,n=e(function(){var e=t("a","y");return e.lastIndex=2,null!==e.exec("abcd")}),r=n||e(function(){return!t("a","y").sticky}),o=n||e(function(){var e=t("^r","gy");return e.lastIndex=2,null!==e.exec("str")});return _r={BROKEN_CARET:o,MISSED_STICKY:r,UNSUPPORTED_Y:n}}(),s=le(),u=an(),l=cn().get,c=function(){if(Mr)return Rr;Mr=1;var e=C(),t=B().RegExp;return Rr=e(function(){var e=t(".","s");return!(e.dotAll&&e.test("\n")&&"s"===e.flags)})}(),d=function(){if(Hr)return jr;Hr=1;var e=C(),t=B().RegExp;return jr=e(function(){var e=t("(?<a>b)","g");return"b"!==e.exec("b").groups.a||"bc"!=="b".replace(e,"$<a>c")})}(),f=s("native-string-replace",String.prototype.replace),p=RegExp.prototype.exec,h=p,g=r("".charAt),v=r("".indexOf),m=r("".replace),y=r("".slice),b=(t=/b*/g,n(p,e=/a/,"a"),n(p,t,"a"),0!==e.lastIndex||0!==t.lastIndex),E=a.BROKEN_CARET,D=void 0!==/()??/.exec("")[1];return(b||D||E||c||d)&&(h=function(e){var t,r,a,s,c,d,C,w=this,S=l(w),A=o(e),x=S.raw;if(x)return x.lastIndex=w.lastIndex,t=n(h,x,A),w.lastIndex=x.lastIndex,t;var O=S.groups,N=E&&w.sticky,B=n(i,w),T=w.source,k=0,F=A;if(N&&(B=m(B,"y",""),-1===v(B,"g")&&(B+="g"),F=y(A,w.lastIndex),w.lastIndex>0&&(!w.multiline||w.multiline&&"\n"!==g(A,w.lastIndex-1))&&(T="(?: "+T+")",F=" "+F,k++),r=new RegExp("^(?:"+T+")",B)),D&&(r=new RegExp("^"+T+"$(?!\\s)",B)),b&&(a=w.lastIndex),s=n(p,N?r:w,F),N?s?(s.input=y(s.input,k),s[0]=y(s[0],k),s.index=w.lastIndex,w.lastIndex+=s[0].length):w.lastIndex=0:b&&s&&(w.lastIndex=w.global?s.index+s[0].length:a),D&&s&&s.length>1&&n(f,s[0],r,function(){for(c=1;c<arguments.length-2;c++)void 0===arguments[c]&&(s[c]=void 0)}),s&&O)for(s.groups=d=u(null),c=0;c<O.length;c++)d[(C=O[c])[0]]=s[C[1]];return s}),zr=h}function Kr(){if(Ur)return Vr;Ur=1;var e=fr(),t=qr();return e({target:"RegExp",proto:!0,forced:/./.exec!==t},{exec:t}),Vr}Kr();var Yr,Xr,Zr,Jr={};function Qr(){if(Xr)return Yr;Xr=1;var e=w(),t=Xt(),n=Wr(),r=O(),o=e("".charAt),i=e("".charCodeAt),a=e("".slice),s=function(e){return function(s,u){var l,c,d=n(r(s)),f=t(u),p=d.length;return f<0||f>=p?e?"":void 0:(l=i(d,f))<55296||l>56319||f+1===p||(c=i(d,f+1))<56320||c>57343?e?o(d,f):l:e?a(d,f,f+2):c-56320+(l-55296<<10)+65536}};return Yr={codeAt:s(!1),charAt:s(!0)}}!function(){if(Zr)return Jr;Zr=1;var e=Qr().charAt,t=Wr(),n=cn(),r=yr(),o=br(),i="String Iterator",a=n.set,s=n.getterFor(i);r(String,"String",function(e){a(this,{type:i,string:t(e),index:0})},function(){var t,n=s(this),r=n.string,i=n.index;return i>=r.length?o(void 0,!0):(t=e(r,i),n.index+=t.length,o(t,!1))})}();var eo,to,no,ro,oo,io,ao,so,uo,lo,co,fo={};function po(){if(ro)return no;ro=1;var e=Qr().charAt;return no=function(t,n,r){return n+(r?e(t,n).length:1)},no}function ho(){if(so)return ao;so=1;var e=Ht(),t=de(),n=$t(),r=function(){if(io)return oo;io=1;var e=B(),t=C(),n=e.RegExp,r=!t(function(){var e=!0;try{n(".","d")}catch(t){e=!1}var t={},r="",o=e?"dgimsy":"gimsy",i=function(e,n){Object.defineProperty(t,e,{get:function(){return r+=n,!0}})},a={dotAll:"s",global:"g",ignoreCase:"i",multiline:"m",sticky:"y"};for(var s in e&&(a.hasIndices="d"),a)i(s,a[s]);return Object.getOwnPropertyDescriptor(n.prototype,"flags").get.call(t)!==o||r!==o});return oo={correct:r}}(),o=Gr(),i=RegExp.prototype;return ao=r.correct?function(e){return e.flags}:function(a){return r.correct||!n(i,a)||t(a,"flags")?a.flags:e(o,a)}}!function(){if(co)return fo;co=1;var e=Ht(),t=w(),n=function(){if(to)return eo;to=1,Kr();var e=Ht(),t=On(),n=qr(),r=C(),o=ve(),i=ln(),a=o("species"),s=RegExp.prototype;return eo=function(u,l,c,d){var f=o(u),p=!r(function(){var e={};return e[f]=function(){return 7},7!==""[u](e)}),h=p&&!r(function(){var e=!1,t=/a/;return"split"===u&&((t={}).constructor={},t.constructor[a]=function(){return t},t.flags="",t[f]=/./[f]),t.exec=function(){return e=!0,null},t[f](""),!e});if(!p||!h||c){var g=/./[f],v=l(f,""[u],function(t,r,o,i,a){var u=r.exec;return u===n||u===s.exec?p&&!a?{done:!0,value:e(g,r,o,i)}:{done:!0,value:e(t,o,r,i)}:{done:!1}});t(String.prototype,u,v[0]),t(s,f,v[1])}d&&i(s[f],"sham",!0)},eo}(),r=be(),o=ye(),i=Zt(),a=Wr(),s=O(),u=Gt(),l=po(),c=ho(),d=function(){if(lo)return uo;lo=1;var e=Ht(),t=be(),n=me(),r=S(),o=qr(),i=TypeError;return uo=function(a,s){var u=a.exec;if(n(u)){var l=e(u,a,s);return null!==l&&t(l),l}if("RegExp"===r(a))return e(o,a,s);throw new i("RegExp#exec called on incompatible receiver")},uo}(),f=t("".indexOf);n("match",function(t,n,p){return[function(n){var r=s(this),i=o(n)?u(n,t):void 0;return i?e(i,n,r):new RegExp(n)[t](a(r))},function(e){var t=r(this),o=a(e),s=p(n,t,o);if(s.done)return s.value;var u=a(c(t));if(-1===f(u,"g"))return d(t,o);var h=-1!==f(u,"u");t.lastIndex=0;for(var g,v=[],m=0;null!==(g=d(t,o));){var y=a(g[0]);v[m]=y,""===y&&(t.lastIndex=l(o,i(t.lastIndex),h)),m++}return 0===m?null:v}]})}();var go,vo,mo,yo,bo,Eo,Co,Do,wo,So,Ao,xo,Oo,No,Bo,To,ko,Fo,Io,Po,_o,Lo,Ro,Mo,jo,Ho,zo,$o={},Uo={};function Vo(){if(vo)return go;vo=1;var e=ye(),t=ln();return go=function(n,r){e(r)&&"cause"in r&&t(n,"cause",r.cause)},go}function Wo(){if(Do)return Co;Do=1;var e=ln(),t=function(){if(yo)return mo;yo=1;var e=w(),t=Error,n=e("".replace),r=String(new t("zxcasd").stack),o=/\n\s*at [^:]*:[^\n]*/,i=o.test(r);return mo=function(e,r){if(i&&"string"==typeof e&&!t.prepareStackTrace)for(;r--;)e=n(e,o,"");return e}}(),n=function(){if(Eo)return bo;Eo=1;var e=C(),t=un();return bo=!e(function(){var e=new Error("a");return!("stack"in e)||(Object.defineProperty(e,"stack",t(1,7)),7!==e.stack)})}(),r=Error.captureStackTrace;return Co=function(o,i,a,s){n&&(r?r(o,i):e(o,"stack",t(a,s)))},Co}function Go(){if(xo)return Ao;xo=1;var e=function(){if(So)return wo;So=1;var e=S(),t=w();return wo=function(n){if("Function"===e(n))return t(n)},wo}(),t=Wt(),n=D(),r=e(e.bind);return Ao=function(e,o){return t(e),void 0===o?e:n?r(e,o):function(){return e.apply(o,arguments)}},Ao}function qo(){if(No)return Oo;No=1;var e=ve(),t=sn(),n=e("iterator"),r=Array.prototype;return Oo=function(e){return void 0!==e&&(t.Array===e||r[n]===e)}}function Ko(){if(To)return Bo;To=1;var e=Tr(),t=Gt(),n=x(),r=sn(),o=ve()("iterator");return Bo=function(i){if(!n(i))return t(i,o)||t(i,"@@iterator")||r[e(i)]}}function Yo(){if(Fo)return ko;Fo=1;var e=Ht(),t=Wt(),n=be(),r=Vt(),o=Ko(),i=TypeError;return ko=function(a,s){var u=arguments.length<2?o(a):s;if(t(u))return n(e(u,a));throw new i(r(a)+" is not iterable")},ko}function Xo(){if(Po)return Io;Po=1;var e=Ht(),t=be(),n=Gt();return Io=function(r,o,i){var a,s;t(r);try{if(!(a=n(r,"return"))){if("throw"===o)throw i;return i}a=e(a,r)}catch(e){s=!0,a=e}if("throw"===o)throw i;if(s)throw a;return t(a),i},Io}function Zo(){if(Lo)return _o;Lo=1;var e=Go(),t=Ht(),n=be(),r=Vt(),o=qo(),i=Jt(),a=$t(),s=Yo(),u=Ko(),l=Xo(),c=TypeError,d=function(e,t){this.stopped=e,this.result=t},f=d.prototype;return _o=function(p,h,g){var v,m,y,b,E,C,D,w=g&&g.that,S=!(!g||!g.AS_ENTRIES),A=!(!g||!g.IS_RECORD),x=!(!g||!g.IS_ITERATOR),O=!(!g||!g.INTERRUPTED),N=e(h,w),B=function(e){return v&&l(v,"normal"),new d(!0,e)},T=function(e){return S?(n(e),O?N(e[0],e[1],B):N(e[0],e[1])):O?N(e,B):N(e)};if(A)v=p.iterator;else if(x)v=p;else{if(!(m=u(p)))throw new c(r(p)+" is not iterable");if(o(m)){for(y=0,b=i(p);b>y;y++)if((E=T(p[y]))&&a(f,E))return E;return new d(!1)}v=s(p,m)}for(C=A?p.next:v.next;!(D=t(C,v)).done;){try{E=T(D.value)}catch(e){l(v,"throw",e)}if("object"==typeof E&&E&&a(f,E))return E}return new d(!1)},_o}function Jo(){if(Mo)return Ro;Mo=1;var e=Wr();return Ro=function(t,n){return void 0===t?arguments.length<2?"":n:e(t)},Ro}function Qo(){return Ho||(Ho=1,function(){if(jo)return Uo;jo=1;var e=fr(),t=$t(),n=pr(),r=mr(),o=dr(),i=an(),a=ln(),s=un(),u=Vo(),l=Wo(),c=Zo(),d=Jo(),f=ve()("toStringTag"),p=Error,h=[].push,g=function(e,o){var s,m=t(v,this);r?s=r(new p,m?n(this):v):(s=m?this:i(v),a(s,f,"Error")),void 0!==o&&a(s,"message",d(o)),l(s,g,s.stack,1),arguments.length>2&&u(s,arguments[2]);var y=[];return c(e,h,{that:y}),a(s,"errors",y),s};r?r(g,p):o(g,p,{name:!0});var v=g.prototype=i(p.prototype,{constructor:s(1,g),message:s(1,""),name:s(1,"AggregateError")});e({global:!0,constructor:!0,arity:2},{AggregateError:g})}()),$o}zo||(zo=1,Qo());var ei,ti,ni={};ti||(ti=1,function(){if(ei)return ni;ei=1;var e=fr(),t=B();e({global:!0,forced:t.globalThis!==t},{globalThis:t})}());var ri,oi,ii,ai,si,ui,li={};function ci(){return oi?ri:(oi=1,ri={CSSRuleList:0,CSSStyleDeclaration:0,CSSValueList:0,ClientRectList:0,DOMRectList:0,DOMStringList:0,DOMTokenList:1,DataTransferItemList:0,FileList:0,HTMLAllCollection:0,HTMLCollection:0,HTMLFormElement:0,HTMLSelectElement:0,MediaList:0,MimeTypeArray:0,NamedNodeMap:0,NodeList:1,PaintRequestList:0,Plugin:0,PluginArray:0,SVGLengthList:0,SVGNumberList:0,SVGPathSegList:0,SVGPointList:0,SVGStringList:0,SVGTransformList:0,SourceBufferList:0,StyleSheetList:0,TextTrackCueList:0,TextTrackList:0,TouchList:0})}function di(){if(ai)return ii;ai=1;var e=Mt()("span").classList,t=e&&e.constructor&&e.constructor.prototype;return ii=t===Object.prototype?void 0:t}if(function(){if(si)return li;si=1;var e=B(),t=ci(),n=di(),r=Er(),o=ln(),i=gr(),a=ve()("iterator"),s=r.values,u=function(e,n){if(e){if(e[a]!==s)try{o(e,a,s)}catch(t){e[a]=s}if(i(e,n,!0),t[n])for(var u in r)if(e[u]!==r[u])try{o(e,u,r[u])}catch(t){e[u]=r[u]}}};for(var l in t)u(e[l]&&e[l].prototype,l);u(n,"DOMTokenList")}(),"undefined"==typeof global){if("ActiveXObject"in window){console.error("抱歉,wangEditor V5+ 版本开始,不在支持 IE 浏览器\n Sorry, wangEditor V5+ versions do not support IE browser.")}fi(),pi()}else global&&(null===(ui=global.navigator)||void 0===ui?void 0:ui.userAgent.match("QQBrowser"))&&(fi(),pi());function fi(){"undefined"==typeof globalThis&&(window.globalThis=window)}function pi(){"undefined"==typeof AggregateError&&(window.AggregateError=function(e,t){var n=new Error(t);return n.errors=e,n})}var hi,gi,vi,mi,yi,bi,Ei,Ci,Di,wi,Si,Ai,xi,Oi,Ni,Bi,Ti={};function ki(){if(gi)return hi;gi=1;var e=function(e){return e&&e.Math===Math&&e};return hi=e("object"==typeof globalThis&&globalThis)||e("object"==typeof window&&window)||e("object"==typeof self&&self)||e("object"==typeof y&&y)||e("object"==typeof hi&&hi)||function(){return this}()||Function("return this")()}function Fi(){return mi?vi:(mi=1,vi=function(e){try{return!!e()}catch(e){return!0}})}function Ii(){return bi?yi:(bi=1,yi=!Fi()(function(){var e=function(){}.bind();return"function"!=typeof e||e.hasOwnProperty("prototype")}))}function Pi(){if(Ci)return Ei;Ci=1;var e=Ii(),t=Function.prototype,n=t.apply,r=t.call;return Ei="object"==typeof Reflect&&Reflect.apply||(e?r.bind(n):function(){return r.apply(n,arguments)}),Ei}function _i(){if(wi)return Di;wi=1;var e=Ii(),t=Function.prototype,n=t.call,r=e&&t.bind.bind(n,n);return Di=e?r:function(e){return function(){return n.apply(e,arguments)}},Di}function Li(){if(Ai)return Si;Ai=1;var e=_i(),t=e({}.toString),n=e("".slice);return Si=function(e){return n(t(e),8,-1)}}function Ri(){if(Oi)return xi;Oi=1;var e=Li(),t=_i();return xi=function(n){if("Function"===e(n))return t(n)},xi}function Mi(){if(Bi)return Ni;Bi=1;var e="object"==typeof document&&document.all;return Ni=void 0===e&&void 0!==e?function(t){return"function"==typeof t||t===e}:function(e){return"function"==typeof e}}var ji,Hi,zi,$i,Ui={};function Vi(){return Hi?ji:(Hi=1,ji=!Fi()(function(){return 7!==Object.defineProperty({},1,{get:function(){return 7}})[1]}))}function Wi(){if($i)return zi;$i=1;var e=Ii(),t=Function.prototype.call;return zi=e?t.bind(t):function(){return t.apply(t,arguments)},zi}var Gi,qi,Ki,Yi,Xi,Zi,Ji,Qi,ea,ta,na,ra,oa,ia,aa,sa,ua,la,ca,da,fa,pa,ha,ga,va,ma,ya,ba,Ea,Ca,Da,wa,Sa,Aa,xa,Oa,Na,Ba={};function Ta(){if(Gi)return Ba;Gi=1;var e={}.propertyIsEnumerable,t=Object.getOwnPropertyDescriptor,n=t&&!e.call({1:2},1);return Ba.f=n?function(e){var n=t(this,e);return!!n&&n.enumerable}:e,Ba}function ka(){return Ki?qi:(Ki=1,qi=function(e,t){return{enumerable:!(1&e),configurable:!(2&e),writable:!(4&e),value:t}})}function Fa(){if(Xi)return Yi;Xi=1;var e=_i(),t=Fi(),n=Li(),r=Object,o=e("".split);return Yi=t(function(){return!r("z").propertyIsEnumerable(0)})?function(e){return"String"===n(e)?o(e,""):r(e)}:r}function Ia(){return Ji?Zi:(Ji=1,Zi=function(e){return null==e})}function Pa(){if(ea)return Qi;ea=1;var e=Ia(),t=TypeError;return Qi=function(n){if(e(n))throw new t("Can't call method on "+n);return n}}function _a(){if(na)return ta;na=1;var e=Fa(),t=Pa();return ta=function(n){return e(t(n))}}function La(){if(oa)return ra;oa=1;var e=Mi();return ra=function(t){return"object"==typeof t?null!==t:e(t)}}function Ra(){return aa?ia:(aa=1,ia={})}function Ma(){if(ua)return sa;ua=1;var e=Ra(),t=ki(),n=Mi(),r=function(e){return n(e)?e:void 0};return sa=function(n,o){return arguments.length<2?r(e[n])||r(t[n]):e[n]&&e[n][o]||t[n]&&t[n][o]},sa}function ja(){return ca?la:(ca=1,la=_i()({}.isPrototypeOf))}function Ha(){if(fa)return da;fa=1;var e=ki().navigator,t=e&&e.userAgent;return da=t?String(t):""}function za(){if(ha)return pa;ha=1;var e,t,n=ki(),r=Ha(),o=n.process,i=n.Deno,a=o&&o.versions||i&&i.version,s=a&&a.v8;return s&&(t=(e=s.split("."))[0]>0&&e[0]<4?1:+(e[0]+e[1])),!t&&r&&(!(e=r.match(/Edge\/(\d+)/))||e[1]>=74)&&(e=r.match(/Chrome\/(\d+)/))&&(t=+e[1]),pa=t}function $a(){if(va)return ga;va=1;var e=za(),t=Fi(),n=ki().String;return ga=!!Object.getOwnPropertySymbols&&!t(function(){var t=Symbol("symbol detection");return!n(t)||!(Object(t)instanceof Symbol)||!Symbol.sham&&e&&e<41}),ga}function Ua(){return ya?ma:(ya=1,ma=$a()&&!Symbol.sham&&"symbol"==typeof Symbol.iterator)}function Va(){if(Ea)return ba;Ea=1;var e=Ma(),t=Mi(),n=ja(),r=Object;return ba=Ua()?function(e){return"symbol"==typeof e}:function(o){var i=e("Symbol");return t(i)&&n(i.prototype,r(o))}}function Wa(){if(Da)return Ca;Da=1;var e=String;return Ca=function(t){try{return e(t)}catch(e){return"Object"}}}function Ga(){if(Sa)return wa;Sa=1;var e=Mi(),t=Wa(),n=TypeError;return wa=function(r){if(e(r))return r;throw new n(t(r)+" is not a function")}}function qa(){if(xa)return Aa;xa=1;var e=Ga(),t=Ia();return Aa=function(n,r){var o=n[r];return t(o)?void 0:e(o)},Aa}function Ka(){if(Na)return Oa;Na=1;var e=Wi(),t=Mi(),n=La(),r=TypeError;return Oa=function(o,i){var a,s;if("string"===i&&t(a=o.toString)&&!n(s=e(a,o)))return s;if(t(a=o.valueOf)&&!n(s=e(a,o)))return s;if("string"!==i&&t(a=o.toString)&&!n(s=e(a,o)))return s;throw new r("Can't convert object to primitive value")},Oa}var Ya,Xa,Za,Ja,Qa,es,ts,ns,rs,os,is,as,ss,us,ls,cs,ds,fs,ps,hs,gs,vs,ms,ys,bs,Es,Cs,Ds,ws={exports:{}};function Ss(){return Xa?Ya:(Xa=1,Ya=!0)}function As(){if(Ja)return Za;Ja=1;var e=ki(),t=Object.defineProperty;return Za=function(n,r){try{t(e,n,{value:r,configurable:!0,writable:!0})}catch(t){e[n]=r}return r}}function xs(){if(Qa)return ws.exports;Qa=1;var e=Ss(),t=ki(),n=As(),r="__core-js_shared__",o=ws.exports=t[r]||n(r,{});return(o.versions||(o.versions=[])).push({version:"3.44.0",mode:e?"pure":"global",copyright:"© 2014-2025 Denis Pushkarev (zloirock.ru)",license:"https://github.com/zloirock/core-js/blob/v3.44.0/LICENSE",source:"https://github.com/zloirock/core-js"}),ws.exports}function Os(){if(ts)return es;ts=1;var e=xs();return es=function(t,n){return e[t]||(e[t]=n||{})}}function Ns(){if(rs)return ns;rs=1;var e=Pa(),t=Object;return ns=function(n){return t(e(n))}}function Bs(){if(is)return os;is=1;var e=_i(),t=Ns(),n=e({}.hasOwnProperty);return os=Object.hasOwn||function(e,r){return n(t(e),r)}}function Ts(){if(ss)return as;ss=1;var e=_i(),t=0,n=Math.random(),r=e(1.1.toString);return as=function(e){return"Symbol("+(void 0===e?"":e)+")_"+r(++t+n,36)}}function ks(){if(ls)return us;ls=1;var e=ki(),t=Os(),n=Bs(),r=Ts(),o=$a(),i=Ua(),a=e.Symbol,s=t("wks"),u=i?a.for||a:a&&a.withoutSetter||r;return us=function(e){return n(s,e)||(s[e]=o&&n(a,e)?a[e]:u("Symbol."+e)),s[e]}}function Fs(){if(ds)return cs;ds=1;var e=Wi(),t=La(),n=Va(),r=qa(),o=Ka(),i=TypeError,a=ks()("toPrimitive");return cs=function(s,u){if(!t(s)||n(s))return s;var l,c=r(s,a);if(c){if(void 0===u&&(u="default"),l=e(c,s,u),!t(l)||n(l))return l;throw new i("Can't convert object to primitive value")}return void 0===u&&(u="number"),o(s,u)}}function Is(){if(ps)return fs;ps=1;var e=Fs(),t=Va();return fs=function(n){var r=e(n,"string");return t(r)?r:r+""}}function Ps(){if(gs)return hs;gs=1;var e=ki(),t=La(),n=e.document,r=t(n)&&t(n.createElement);return hs=function(e){return r?n.createElement(e):{}}}function _s(){if(ms)return vs;ms=1;var e=Vi(),t=Fi(),n=Ps();return vs=!e&&!t(function(){return 7!==Object.defineProperty(n("div"),"a",{get:function(){return 7}}).a})}function Ls(){if(ys)return Ui;ys=1;var e=Vi(),t=Wi(),n=Ta(),r=ka(),o=_a(),i=Is(),a=Bs(),s=_s(),u=Object.getOwnPropertyDescriptor;return Ui.f=e?u:function(e,l){if(e=o(e),l=i(l),s)try{return u(e,l)}catch(e){}if(a(e,l))return r(!t(n.f,e,l),e[l])},Ui}function Rs(){if(Es)return bs;Es=1;var e=Fi(),t=Mi(),n=/#|\.prototype\./,r=function(n,r){var u=i[o(n)];return u===s||u!==a&&(t(r)?e(r):!!r)},o=r.normalize=function(e){return String(e).replace(n,".").toLowerCase()},i=r.data={},a=r.NATIVE="N",s=r.POLYFILL="P";return bs=r}function Ms(){if(Ds)return Cs;Ds=1;var e=Ri(),t=Ga(),n=Ii(),r=e(e.bind);return Cs=function(e,o){return t(e),void 0===o?e:n?r(e,o):function(){return e.apply(o,arguments)}},Cs}var js,Hs,zs,$s,Us,Vs,Ws,Gs,qs,Ks,Ys,Xs,Zs,Js,Qs,eu,tu,nu,ru,ou,iu,au,su,uu,lu,cu,du,fu,pu,hu,gu,vu,mu,yu,bu,Eu,Cu,Du,wu={};function Su(){return Hs?js:(Hs=1,js=Vi()&&Fi()(function(){return 42!==Object.defineProperty(function(){},"prototype",{value:42,writable:!1}).prototype}))}function Au(){if($s)return zs;$s=1;var e=La(),t=String,n=TypeError;return zs=function(r){if(e(r))return r;throw new n(t(r)+" is not an object")}}function xu(){if(Us)return wu;Us=1;var e=Vi(),t=_s(),n=Su(),r=Au(),o=Is(),i=TypeError,a=Object.defineProperty,s=Object.getOwnPropertyDescriptor,u="enumerable",l="configurable",c="writable";return wu.f=e?n?function(e,t,n){if(r(e),t=o(t),r(n),"function"==typeof e&&"prototype"===t&&"value"in n&&c in n&&!n[c]){var i=s(e,t);i&&i[c]&&(e[t]=n.value,n={configurable:l in n?n[l]:i[l],enumerable:u in n?n[u]:i[u],writable:!1})}return a(e,t,n)}:a:function(e,n,s){if(r(e),n=o(n),r(s),t)try{return a(e,n,s)}catch(e){}if("get"in s||"set"in s)throw new i("Accessors not supported");return"value"in s&&(e[n]=s.value),e},wu}function Ou(){if(Ws)return Vs;Ws=1;var e=Vi(),t=xu(),n=ka();return Vs=e?function(e,r,o){return t.f(e,r,n(1,o))}:function(e,t,n){return e[t]=n,e}}function Nu(){if(qs)return Gs;qs=1;var e=ki(),t=Pi(),n=Ri(),r=Mi(),o=Ls().f,i=Rs(),a=Ra(),s=Ms(),u=Ou(),l=Bs(),c=function(e){var n=function(r,o,i){if(this instanceof n){switch(arguments.length){case 0:return new e;case 1:return new e(r);case 2:return new e(r,o)}return new e(r,o,i)}return t(e,this,arguments)};return n.prototype=e.prototype,n};return Gs=function(t,d){var f,p,h,g,v,m,y,b,E,C=t.target,D=t.global,w=t.stat,S=t.proto,A=D?e:w?e[C]:e[C]&&e[C].prototype,x=D?a:a[C]||u(a,C,{})[C],O=x.prototype;for(g in d)p=!(f=i(D?g:C+(w?".":"#")+g,t.forced))&&A&&l(A,g),m=x[g],p&&(y=t.dontCallGetSet?(E=o(A,g))&&E.value:A[g]),v=p&&y?y:d[g],(f||S||typeof m!=typeof v)&&(b=t.bind&&p?s(v,e):t.wrap&&p?c(v):S&&r(v)?n(v):v,(t.sham||v&&v.sham||m&&m.sham)&&u(b,"sham",!0),u(x,g,b),S&&(l(a,h=C+"Prototype")||u(a,h,{}),u(a[h],g,v),t.real&&O&&(f||!O[g])&&u(O,g,v)))}}function Bu(){if(Ys)return Ks;Ys=1;var e=Li();return Ks=Array.isArray||function(t){return"Array"===e(t)}}function Tu(){if(Zs)return Xs;Zs=1;var e=Math.ceil,t=Math.floor;return Xs=Math.trunc||function(n){var r=+n;return(r>0?t:e)(r)},Xs}function ku(){if(Qs)return Js;Qs=1;var e=Tu();return Js=function(t){var n=+t;return n!=n||0===n?0:e(n)}}function Fu(){if(tu)return eu;tu=1;var e=ku(),t=Math.min;return eu=function(n){var r=e(n);return r>0?t(r,9007199254740991):0}}function Iu(){if(ru)return nu;ru=1;var e=Fu();return nu=function(t){return e(t.length)}}function Pu(){if(iu)return ou;iu=1;var e=TypeError;return ou=function(t){if(t>9007199254740991)throw e("Maximum allowed index exceeded");return t}}function _u(){if(su)return au;su=1;var e=Vi(),t=xu(),n=ka();return au=function(r,o,i){e?t.f(r,o,n(0,i)):r[o]=i}}function Lu(){if(lu)return uu;lu=1;var e={};return e[ks()("toStringTag")]="z",uu="[object z]"===String(e)}function Ru(){if(du)return cu;du=1;var e=Lu(),t=Mi(),n=Li(),r=ks()("toStringTag"),o=Object,i="Arguments"===n(function(){return arguments}());return cu=e?n:function(e){var a,s,u;return void 0===e?"Undefined":null===e?"Null":"string"==typeof(s=function(e,t){try{return e[t]}catch(e){}}(a=o(e),r))?s:i?n(a):"Object"===(u=n(a))&&t(a.callee)?"Arguments":u},cu}function Mu(){if(pu)return fu;pu=1;var e=_i(),t=Mi(),n=xs(),r=e(Function.toString);return t(n.inspectSource)||(n.inspectSource=function(e){return r(e)}),fu=n.inspectSource}function ju(){if(gu)return hu;gu=1;var e=_i(),t=Fi(),n=Mi(),r=Ru(),o=Ma(),i=Mu(),a=function(){},s=o("Reflect","construct"),u=/^\s*(?:class|function)\b/,l=e(u.exec),c=!u.test(a),d=function(e){if(!n(e))return!1;try{return s(a,[],e),!0}catch(e){return!1}},f=function(e){if(!n(e))return!1;switch(r(e)){case"AsyncFunction":case"GeneratorFunction":case"AsyncGeneratorFunction":return!1}try{return c||!!l(u,i(e))}catch(e){return!0}};return f.sham=!0,hu=!s||t(function(){var e;return d(d.call)||!d(Object)||!d(function(){e=!0})||e})?f:d}function Hu(){if(mu)return vu;mu=1;var e=Bu(),t=ju(),n=La(),r=ks()("species"),o=Array;return vu=function(i){var a;return e(i)&&(a=i.constructor,(t(a)&&(a===o||e(a.prototype))||n(a)&&null===(a=a[r]))&&(a=void 0)),void 0===a?o:a},vu}function zu(){if(bu)return yu;bu=1;var e=Hu();return yu=function(t,n){return new(e(t))(0===n?0:n)}}function $u(){if(Cu)return Eu;Cu=1;var e=Fi(),t=ks(),n=za(),r=t("species");return Eu=function(t){return n>=51||!e(function(){var e=[];return(e.constructor={})[r]=function(){return{foo:1}},1!==e[t](Boolean).foo})},Eu}var Uu,Vu,Wu={},Gu={};function qu(){if(Vu)return Uu;Vu=1;var e=Ru(),t=String;return Uu=function(n){if("Symbol"===e(n))throw new TypeError("Cannot convert a Symbol value to a string");return t(n)}}var Ku,Yu,Xu,Zu,Ju,Qu,el,tl,nl,rl,ol,il,al,sl,ul,ll,cl,dl,fl,pl={};function hl(){if(Yu)return Ku;Yu=1;var e=ku(),t=Math.max,n=Math.min;return Ku=function(r,o){var i=e(r);return i<0?t(i+o,0):n(i,o)},Ku}function gl(){if(Zu)return Xu;Zu=1;var e=_a(),t=hl(),n=Iu(),r=function(r){return function(o,i,a){var s=e(o),u=n(s);if(0===u)return!r&&-1;var l,c=t(a,u);if(r&&i!=i){for(;u>c;)if((l=s[c++])!=l)return!0}else for(;u>c;c++)if((r||c in s)&&s[c]===i)return r||c||0;return!r&&-1}};return Xu={includes:r(!0),indexOf:r(!1)}}function vl(){return Qu?Ju:(Qu=1,Ju={})}function ml(){if(tl)return el;tl=1;var e=_i(),t=Bs(),n=_a(),r=gl().indexOf,o=vl(),i=e([].push);return el=function(e,a){var s,u=n(e),l=0,c=[];for(s in u)!t(o,s)&&t(u,s)&&i(c,s);for(;a.length>l;)t(u,s=a[l++])&&(~r(c,s)||i(c,s));return c},el}function yl(){return rl?nl:(rl=1,nl=["constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleString","toString","valueOf"])}function bl(){if(il)return ol;il=1;var e=ml(),t=yl();return ol=Object.keys||function(n){return e(n,t)},ol}function El(){if(al)return pl;al=1;var e=Vi(),t=Su(),n=xu(),r=Au(),o=_a(),i=bl();return pl.f=e&&!t?Object.defineProperties:function(e,t){r(e);for(var a,s=o(t),u=i(t),l=u.length,c=0;l>c;)n.f(e,a=u[c++],s[a]);return e},pl}function Cl(){return ul?sl:(ul=1,sl=Ma()("document","documentElement"))}function Dl(){if(cl)return ll;cl=1;var e=Os(),t=Ts(),n=e("keys");return ll=function(e){return n[e]||(n[e]=t(e))}}function wl(){if(fl)return dl;fl=1;var e,t=Au(),n=El(),r=yl(),o=vl(),i=Cl(),a=Ps(),s="prototype",u="script",l=Dl()("IE_PROTO"),c=function(){},d=function(e){return"<"+u+">"+e+"</"+u+">"},f=function(e){e.write(d("")),e.close();var t=e.parentWindow.Object;return e=null,t},p=function(){try{e=new ActiveXObject("htmlfile")}catch(e){}var t,n,o;p="undefined"!=typeof document?document.domain&&e?f(e):(n=a("iframe"),o="java"+u+":",n.style.display="none",i.appendChild(n),n.src=String(o),(t=n.contentWindow.document).open(),t.write(d("document.F=Object")),t.close(),t.F):f(e);for(var l=r.length;l--;)delete p[s][r[l]];return p()};return o[l]=!0,dl=Object.create||function(e,r){var o;return null!==e?(c[s]=t(e),o=new c,c[s]=null,o[l]=e):o=p(),void 0===r?o:n.f(o,r)},dl}var Sl,Al={};function xl(){if(Sl)return Al;Sl=1;var e=ml(),t=yl().concat("length","prototype");return Al.f=Object.getOwnPropertyNames||function(n){return e(n,t)},Al}var Ol,Nl,Bl,Tl={};function kl(){return Nl?Ol:(Nl=1,Ol=_i()([].slice))}function Fl(){if(Bl)return Tl;Bl=1;var e=Li(),t=_a(),n=xl().f,r=kl(),o="object"==typeof window&&window&&Object.getOwnPropertyNames?Object.getOwnPropertyNames(window):[];return Tl.f=function(i){return o&&"Window"===e(i)?function(e){try{return n(e)}catch(e){return r(o)}}(i):n(t(i))},Tl}var Il,Pl,_l,Ll,Rl,Ml={};function jl(){return Il||(Il=1,Ml.f=Object.getOwnPropertySymbols),Ml}function Hl(){if(_l)return Pl;_l=1;var e=Ou();return Pl=function(t,n,r,o){return o&&o.enumerable?t[n]=r:e(t,n,r),t}}function zl(){if(Rl)return Ll;Rl=1;var e=xu();return Ll=function(t,n,r){return e.f(t,n,r)}}var $l,Ul,Vl,Wl,Gl,ql,Kl,Yl,Xl,Zl,Jl,Ql,ec,tc,nc,rc,oc={};function ic(){if($l)return oc;$l=1;var e=ks();return oc.f=e,oc}function ac(){if(Vl)return Ul;Vl=1;var e=Ra(),t=Bs(),n=ic(),r=xu().f;return Ul=function(o){var i=e.Symbol||(e.Symbol={});t(i,o)||r(i,o,{value:n.f(o)})}}function sc(){if(Gl)return Wl;Gl=1;var e=Wi(),t=Ma(),n=ks(),r=Hl();return Wl=function(){var o=t("Symbol"),i=o&&o.prototype,a=i&&i.valueOf,s=n("toPrimitive");i&&!i[s]&&r(i,s,function(t){return e(a,this)},{arity:1})}}function uc(){if(Kl)return ql;Kl=1;var e=Lu(),t=Ru();return ql=e?{}.toString:function(){return"[object "+t(this)+"]"}}function lc(){if(Xl)return Yl;Xl=1;var e=Lu(),t=xu().f,n=Ou(),r=Bs(),o=uc(),i=ks()("toStringTag");return Yl=function(a,s,u,l){var c=u?a:a&&a.prototype;c&&(r(c,i)||t(c,i,{configurable:!0,value:s}),l&&!e&&n(c,"toString",o))}}function cc(){if(Jl)return Zl;Jl=1;var e=ki(),t=Mi(),n=e.WeakMap;return Zl=t(n)&&/native code/.test(String(n))}function dc(){if(ec)return Ql;ec=1;var e,t,n,r=cc(),o=ki(),i=La(),a=Ou(),s=Bs(),u=xs(),l=Dl(),c=vl(),d="Object already initialized",f=o.TypeError,p=o.WeakMap;if(r||u.state){var h=u.state||(u.state=new p);h.get=h.get,h.has=h.has,h.set=h.set,e=function(e,t){if(h.has(e))throw new f(d);return t.facade=e,h.set(e,t),t},t=function(e){return h.get(e)||{}},n=function(e){return h.has(e)}}else{var g=l("state");c[g]=!0,e=function(e,t){if(s(e,g))throw new f(d);return t.facade=e,a(e,g,t),t},t=function(e){return s(e,g)?e[g]:{}},n=function(e){return s(e,g)}}return Ql={set:e,get:t,has:n,enforce:function(r){return n(r)?t(r):e(r,{})},getterFor:function(e){return function(n){var r;if(!i(n)||(r=t(n)).type!==e)throw new f("Incompatible receiver, "+e+" required");return r}}}}function fc(){if(nc)return tc;nc=1;var e=Ms(),t=_i(),n=Fa(),r=Ns(),o=Iu(),i=zu(),a=t([].push),s=function(t){var s=1===t,u=2===t,l=3===t,c=4===t,d=6===t,f=7===t,p=5===t||d;return function(h,g,v,m){for(var y,b,E=r(h),C=n(E),D=o(C),w=e(g,v),S=0,A=m||i,x=s?A(h,D):u||f?A(h,0):void 0;D>S;S++)if((p||S in C)&&(b=w(y=C[S],S,E),t))if(s)x[S]=b;else if(b)switch(t){case 3:return!0;case 5:return y;case 6:return S;case 2:a(x,y)}else switch(t){case 4:return!1;case 7:a(x,y)}return d?-1:l||c?c:x}};return tc={forEach:s(0),map:s(1),filter:s(2),some:s(3),every:s(4),find:s(5),findIndex:s(6),filterReject:s(7)}}var pc,hc,gc,vc={};function mc(){return hc?pc:(hc=1,pc=$a()&&!!Symbol.for&&!!Symbol.keyFor)}var yc,bc={};var Ec,Cc,Dc,wc={};function Sc(){if(Cc)return Ec;Cc=1;var e=_i(),t=Bu(),n=Mi(),r=Li(),o=qu(),i=e([].push);return Ec=function(e){if(n(e))return e;if(t(e)){for(var a=e.length,s=[],u=0;u<a;u++){var l=e[u];"string"==typeof l?i(s,l):"number"!=typeof l&&"Number"!==r(l)&&"String"!==r(l)||i(s,o(l))}var c=s.length,d=!0;return function(e,n){if(d)return d=!1,n;if(t(this))return n;for(var r=0;r<c;r++)if(s[r]===e)return n}}},Ec}var Ac,xc,Oc={};function Nc(){return xc||(xc=1,function(){if(rc)return Gu;rc=1;var e=Nu(),t=ki(),n=Wi(),r=_i(),o=Ss(),i=Vi(),a=$a(),s=Fi(),u=Bs(),l=ja(),c=Au(),d=_a(),f=Is(),p=qu(),h=ka(),g=wl(),v=bl(),m=xl(),y=Fl(),b=jl(),E=Ls(),C=xu(),D=El(),w=Ta(),S=Hl(),A=zl(),x=Os(),O=Dl(),N=vl(),B=Ts(),T=ks(),k=ic(),F=ac(),I=sc(),P=lc(),_=dc(),L=fc().forEach,R=O("hidden"),M="Symbol",j="prototype",H=_.set,z=_.getterFor(M),$=Object[j],U=t.Symbol,V=U&&U[j],W=t.RangeError,G=t.TypeError,q=t.QObject,K=E.f,Y=C.f,X=y.f,Z=w.f,J=r([].push),Q=x("symbols"),ee=x("op-symbols"),te=x("wks"),ne=!q||!q[j]||!q[j].findChild,re=function(e,t,n){var r=K($,t);r&&delete $[t],Y(e,t,n),r&&e!==$&&Y($,t,r)},oe=i&&s(function(){return 7!==g(Y({},"a",{get:function(){return Y(this,"a",{value:7}).a}})).a})?re:Y,ie=function(e,t){var n=Q[e]=g(V);return H(n,{type:M,tag:e,description:t}),i||(n.description=t),n},ae=function(e,t,n){e===$&&ae(ee,t,n),c(e);var r=f(t);return c(n),u(Q,r)?(n.enumerable?(u(e,R)&&e[R][r]&&(e[R][r]=!1),n=g(n,{enumerable:h(0,!1)})):(u(e,R)||Y(e,R,h(1,g(null))),e[R][r]=!0),oe(e,r,n)):Y(e,r,n)},se=function(e,t){c(e);var r=d(t),o=v(r).concat(de(r));return L(o,function(t){i&&!n(ue,r,t)||ae(e,t,r[t])}),e},ue=function(e){var t=f(e),r=n(Z,this,t);return!(this===$&&u(Q,t)&&!u(ee,t))&&(!(r||!u(this,t)||!u(Q,t)||u(this,R)&&this[R][t])||r)},le=function(e,t){var n=d(e),r=f(t);if(n!==$||!u(Q,r)||u(ee,r)){var o=K(n,r);return!o||!u(Q,r)||u(n,R)&&n[R][r]||(o.enumerable=!0),o}},ce=function(e){var t=X(d(e)),n=[];return L(t,function(e){u(Q,e)||u(N,e)||J(n,e)}),n},de=function(e){var t=e===$,n=X(t?ee:d(e)),r=[];return L(n,function(e){!u(Q,e)||t&&!u($,e)||J(r,Q[e])}),r};a||(U=function(){if(l(V,this))throw new G("Symbol is not a constructor");var e=arguments.length&&void 0!==arguments[0]?p(arguments[0]):void 0,r=B(e),o=function(e){var i=void 0===this?t:this;i===$&&n(o,ee,e),u(i,R)&&u(i[R],r)&&(i[R][r]=!1);var a=h(1,e);try{oe(i,r,a)}catch(e){if(!(e instanceof W))throw e;re(i,r,a)}};return i&&ne&&oe($,r,{configurable:!0,set:o}),ie(r,e)},S(V=U[j],"toString",function(){return z(this).tag}),S(U,"withoutSetter",function(e){return ie(B(e),e)}),w.f=ue,C.f=ae,D.f=se,E.f=le,m.f=y.f=ce,b.f=de,k.f=function(e){return ie(T(e),e)},i&&(A(V,"description",{configurable:!0,get:function(){return z(this).description}}),o||S($,"propertyIsEnumerable",ue,{unsafe:!0}))),e({global:!0,constructor:!0,wrap:!0,forced:!a,sham:!a},{Symbol:U}),L(v(te),function(e){F(e)}),e({target:M,stat:!0,forced:!a},{useSetter:function(){ne=!0},useSimple:function(){ne=!1}}),e({target:"Object",stat:!0,forced:!a,sham:!i},{create:function(e,t){return void 0===t?g(e):se(g(e),t)},defineProperty:ae,defineProperties:se,getOwnPropertyDescriptor:le}),e({target:"Object",stat:!0,forced:!a},{getOwnPropertyNames:ce}),I(),P(U,M),N[R]=!0}(),function(){if(gc)return vc;gc=1;var e=Nu(),t=Ma(),n=Bs(),r=qu(),o=Os(),i=mc(),a=o("string-to-symbol-registry"),s=o("symbol-to-string-registry");e({target:"Symbol",stat:!0,forced:!i},{for:function(e){var o=r(e);if(n(a,o))return a[o];var i=t("Symbol")(o);return a[o]=i,s[i]=o,i}})}(),function(){if(yc)return bc;yc=1;var e=Nu(),t=Bs(),n=Va(),r=Wa(),o=Os(),i=mc(),a=o("symbol-to-string-registry");e({target:"Symbol",stat:!0,forced:!i},{keyFor:function(e){if(!n(e))throw new TypeError(r(e)+" is not a symbol");if(t(a,e))return a[e]}})}(),function(){if(Dc)return wc;Dc=1;var e=Nu(),t=Ma(),n=Pi(),r=Wi(),o=_i(),i=Fi(),a=Mi(),s=Va(),u=kl(),l=Sc(),c=$a(),d=String,f=t("JSON","stringify"),p=o(/./.exec),h=o("".charAt),g=o("".charCodeAt),v=o("".replace),m=o(1.1.toString),y=/[\uD800-\uDFFF]/g,b=/^[\uD800-\uDBFF]$/,E=/^[\uDC00-\uDFFF]$/,C=!c||i(function(){var e=t("Symbol")("stringify detection");return"[null]"!==f([e])||"{}"!==f({a:e})||"{}"!==f(Object(e))}),D=i(function(){return'"\\udf06\\ud834"'!==f("\udf06\ud834")||'"\\udead"'!==f("\udead")}),w=function(e,t){var o=u(arguments),i=l(t);if(a(i)||void 0!==e&&!s(e))return o[1]=function(e,t){if(a(i)&&(t=r(i,this,d(e),t)),!s(t))return t},n(f,null,o)},S=function(e,t,n){var r=h(n,t-1),o=h(n,t+1);return p(b,e)&&!p(E,o)||p(E,e)&&!p(b,r)?"\\u"+m(g(e,0),16):e};f&&e({target:"JSON",stat:!0,arity:3,forced:C||D},{stringify:function(e,t,r){var o=u(arguments),i=n(C?w:f,null,o);return D&&"string"==typeof i?v(i,y,S):i}})}(),function(){if(Ac)return Oc;Ac=1;var e=Nu(),t=$a(),n=Fi(),r=jl(),o=Ns();e({target:"Object",stat:!0,forced:!t||n(function(){r.f(1)})},{getOwnPropertySymbols:function(e){var t=r.f;return t?t(o(e)):[]}})}()),Wu}var Bc,Tc={};function kc(){return Bc||(Bc=1,ac()("asyncDispose")),Tc}var Fc;var Ic,Pc={};function _c(){return Ic||(Ic=1,ac()("dispose")),Pc}var Lc;var Rc;var Mc,jc={};function Hc(){return Mc||(Mc=1,ac()("iterator")),jc}var zc;var $c;var Uc;var Vc;var Wc;var Gc;var qc,Kc={};var Yc,Xc={};var Zc;var Jc,Qc,ed,td={};function nd(){return ed?Qc:(ed=1,function(){if(Du)return Ti;Du=1;var e=Nu(),t=Fi(),n=Bu(),r=La(),o=Ns(),i=Iu(),a=Pu(),s=_u(),u=zu(),l=$u(),c=ks(),d=za(),f=c("isConcatSpreadable"),p=d>=51||!t(function(){var e=[];return e[f]=!1,e.concat()[0]!==e}),h=function(e){if(!r(e))return!1;var t=e[f];return void 0!==t?!!t:n(e)};e({target:"Array",proto:!0,arity:1,forced:!p||!l("concat")},{concat:function(e){var t,n,r,l,c,d=o(this),f=u(d,0),p=0;for(t=-1,r=arguments.length;t<r;t++)if(h(c=-1===t?d:arguments[t]))for(l=i(c),a(p+l),n=0;n<l;n++,p++)n in c&&s(f,p,c[n]);else a(p+1),s(f,p++,c);return f.length=p,f}})}(),Nc(),kc(),Fc||(Fc=1,ac()("asyncIterator")),_c(),Lc||(Lc=1,ac()("hasInstance")),Rc||(Rc=1,ac()("isConcatSpreadable")),Hc(),zc||(zc=1,ac()("match")),$c||($c=1,ac()("matchAll")),Uc||(Uc=1,ac()("replace")),Vc||(Vc=1,ac()("search")),Wc||(Wc=1,ac()("species")),Gc||(Gc=1,ac()("split")),function(){if(qc)return Kc;qc=1;var e=ac(),t=sc();e("toPrimitive"),t()}(),function(){if(Yc)return Xc;Yc=1;var e=Ma(),t=ac(),n=lc();t("toStringTag"),n(e("Symbol"),"Symbol")}(),Zc||(Zc=1,ac()("unscopables")),function(){if(Jc)return td;Jc=1;var e=ki();lc()(e.JSON,"JSON",!0)}(),Qc=Ra().Symbol)}var rd,od,id,ad,sd,ud,ld,cd,dd,fd,pd,hd,gd,vd,md,yd,bd,Ed,Cd,Dd,wd,Sd,Ad,xd,Od,Nd,Bd,Td,kd,Fd,Id,Pd,_d,Ld={};function Rd(){return od?rd:(od=1,rd=function(){})}function Md(){return ad?id:(ad=1,id={})}function jd(){if(ud)return sd;ud=1;var e=Vi(),t=Bs(),n=Function.prototype,r=e&&Object.getOwnPropertyDescriptor,o=t(n,"name"),i=o&&"something"===function(){}.name,a=o&&(!e||e&&r(n,"name").configurable);return sd={EXISTS:o,PROPER:i,CONFIGURABLE:a}}function Hd(){return cd||(cd=1,ld=!Fi()(function(){function e(){}return e.prototype.constructor=null,Object.getPrototypeOf(new e)!==e.prototype})),ld}function zd(){if(fd)return dd;fd=1;var e=Bs(),t=Mi(),n=Ns(),r=Dl(),o=Hd(),i=r("IE_PROTO"),a=Object,s=a.prototype;return dd=o?a.getPrototypeOf:function(r){var o=n(r);if(e(o,i))return o[i];var u=o.constructor;return t(u)&&o instanceof u?u.prototype:o instanceof a?s:null},dd}function $d(){if(hd)return pd;hd=1;var e,t,n,r=Fi(),o=Mi(),i=La(),a=wl(),s=zd(),u=Hl(),l=ks(),c=Ss(),d=l("iterator"),f=!1;return[].keys&&("next"in(n=[].keys())?(t=s(s(n)))!==Object.prototype&&(e=t):f=!0),!i(e)||r(function(){var t={};return e[d].call(t)!==t})?e={}:c&&(e=a(e)),o(e[d])||u(e,d,function(){return this}),pd={IteratorPrototype:e,BUGGY_SAFARI_ITERATORS:f}}function Ud(){if(vd)return gd;vd=1;var e=$d().IteratorPrototype,t=wl(),n=ka(),r=lc(),o=Md(),i=function(){return this};return gd=function(a,s,u,l){var c=s+" Iterator";return a.prototype=t(e,{next:n(+!l,u)}),r(a,c,!1,!0),o[c]=i,a}}function Vd(){if(yd)return md;yd=1;var e=_i(),t=Ga();return md=function(n,r,o){try{return e(t(Object.getOwnPropertyDescriptor(n,r)[o]))}catch(e){}}}function Wd(){if(Ed)return bd;Ed=1;var e=La();return bd=function(t){return e(t)||null===t}}function Gd(){if(Dd)return Cd;Dd=1;var e=Wd(),t=String,n=TypeError;return Cd=function(r){if(e(r))return r;throw new n("Can't set "+t(r)+" as a prototype")}}function qd(){if(Sd)return wd;Sd=1;var e=Vd(),t=La(),n=Pa(),r=Gd();return wd=Object.setPrototypeOf||("__proto__"in{}?function(){var o,i=!1,a={};try{(o=e(Object.prototype,"__proto__","set"))(a,[]),i=a instanceof Array}catch(e){}return function(e,a){return n(e),r(a),t(e)?(i?o(e,a):e.__proto__=a,e):e}}():void 0),wd}function Kd(){if(xd)return Ad;xd=1;var e=Nu(),t=Wi(),n=Ss(),r=jd(),o=Mi(),i=Ud(),a=zd(),s=qd(),u=lc(),l=Ou(),c=Hl(),d=ks(),f=Md(),p=$d(),h=r.PROPER,g=r.CONFIGURABLE,v=p.IteratorPrototype,m=p.BUGGY_SAFARI_ITERATORS,y=d("iterator"),b="keys",E="values",C="entries",D=function(){return this};return Ad=function(r,d,p,w,S,A,x){i(p,d,w);var O,N,B,T=function(e){if(e===S&&_)return _;if(!m&&e&&e in I)return I[e];switch(e){case b:case E:case C:return function(){return new p(this,e)}}return function(){return new p(this)}},k=d+" Iterator",F=!1,I=r.prototype,P=I[y]||I["@@iterator"]||S&&I[S],_=!m&&P||T(S),L="Array"===d&&I.entries||P;if(L&&(O=a(L.call(new r)))!==Object.prototype&&O.next&&(n||a(O)===v||(s?s(O,v):o(O[y])||c(O,y,D)),u(O,k,!0,!0),n&&(f[k]=D)),h&&S===E&&P&&P.name!==E&&(!n&&g?l(I,"name",E):(F=!0,_=function(){return t(P,this)})),S)if(N={values:T(E),keys:A?_:T(b),entries:T(C)},x)for(B in N)(m||F||!(B in I))&&c(I,B,N[B]);else e({target:d,proto:!0,forced:m||F},N);return n&&!x||I[y]===_||c(I,y,_,{name:S}),f[d]=_,N}}function Yd(){return Nd?Od:(Nd=1,Od=function(e,t){return{value:e,done:t}})}function Xd(){if(Td)return Bd;Td=1;var e=_a(),t=Rd(),n=Md(),r=dc(),o=xu().f,i=Kd(),a=Yd(),s=Ss(),u=Vi(),l="Array Iterator",c=r.set,d=r.getterFor(l);Bd=i(Array,"Array",function(t,n){c(this,{type:l,target:e(t),index:0,kind:n})},function(){var e=d(this),t=e.target,n=e.index++;if(!t||n>=t.length)return e.target=null,a(void 0,!0);switch(e.kind){case"keys":return a(n,!1);case"values":return a(t[n],!1)}return a([n,t[n]],!1)},"values");var f=n.Arguments=n.Array;if(t("keys"),t("values"),t("entries"),!s&&u&&"values"!==f.name)try{o(f,"name",{value:"values"})}catch(e){}return Bd}function Zd(){return Fd?kd:(Fd=1,kd={CSSRuleList:0,CSSStyleDeclaration:0,CSSValueList:0,ClientRectList:0,DOMRectList:0,DOMStringList:0,DOMTokenList:1,DataTransferItemList:0,FileList:0,HTMLAllCollection:0,HTMLCollection:0,HTMLFormElement:0,HTMLSelectElement:0,MediaList:0,MimeTypeArray:0,NamedNodeMap:0,NodeList:1,PaintRequestList:0,Plugin:0,PluginArray:0,SVGLengthList:0,SVGNumberList:0,SVGPathSegList:0,SVGPointList:0,SVGStringList:0,SVGTransformList:0,SourceBufferList:0,StyleSheetList:0,TextTrackCueList:0,TextTrackList:0,TouchList:0})}function Jd(){if(Id)return Ld;Id=1,Xd();var e=Zd(),t=ki(),n=lc(),r=Md();for(var o in e)n(t[o],o),r[o]=r.Array;return Ld}function Qd(){if(_d)return Pd;_d=1;var e=nd();return Jd(),Pd=e}var ef,tf={};var nf;var rf;var of,af,sf;function uf(){if(sf)return af;sf=1;var e=Qd();return function(){if(ef)return tf;ef=1;var e=ks(),t=xu().f,n=e("metadata"),r=Function.prototype;void 0===r[n]&&t(r,n,{value:null})}(),nf||(nf=1,kc()),rf||(rf=1,_c()),of||(of=1,ac()("metadata")),af=e}var lf,cf,df;function ff(){if(cf)return lf;cf=1;var e=Ma(),t=_i(),n=e("Symbol"),r=n.keyFor,o=t(n.prototype.valueOf);return lf=n.isRegisteredSymbol||function(e){try{return void 0!==r(o(e))}catch(e){return!1}}}var pf,hf,gf;function vf(){if(hf)return pf;hf=1;for(var e=Os(),t=Ma(),n=_i(),r=Va(),o=ks(),i=t("Symbol"),a=i.isWellKnownSymbol,s=t("Object","getOwnPropertyNames"),u=n(i.prototype.valueOf),l=e("wks"),c=0,d=s(i),f=d.length;c<f;c++)try{var p=d[c];r(i[p])&&o(p)}catch(e){}return pf=function(e){if(a&&a(e))return!0;try{for(var t=u(e),n=0,r=s(l),o=r.length;n<o;n++)if(l[r[n]]==t)return!0}catch(e){}return!1},pf}var mf;var yf;var bf;var Ef;var Cf;var Df;var wf;var Sf,Af,xf,Of,Nf;function Bf(){if(xf)return Af;xf=1;var e=uf();return df||(df=1,Nu()({target:"Symbol",stat:!0},{isRegisteredSymbol:ff()})),gf||(gf=1,Nu()({target:"Symbol",stat:!0,forced:!0},{isWellKnownSymbol:vf()})),mf||(mf=1,ac()("customMatcher")),yf||(yf=1,ac()("observable")),bf||(bf=1,Nu()({target:"Symbol",stat:!0,name:"isRegisteredSymbol"},{isRegistered:ff()})),Ef||(Ef=1,Nu()({target:"Symbol",stat:!0,name:"isWellKnownSymbol",forced:!0},{isWellKnown:vf()})),Cf||(Cf=1,ac()("matcher")),Df||(Df=1,ac()("metadataKey")),wf||(wf=1,ac()("patternMatch")),Sf||(Sf=1,ac()("replaceAll")),Af=e}function Tf(){return Nf?Of:(Nf=1,Of=Bf())}var kf,Ff,If,Pf,_f,Lf,Rf,Mf,jf,Hf,zf,$f,Uf,Vf=b(Tf()),Wf={};function Gf(){if(Ff)return kf;Ff=1;var e=_i(),t=ku(),n=qu(),r=Pa(),o=e("".charAt),i=e("".charCodeAt),a=e("".slice),s=function(e){return function(s,u){var l,c,d=n(r(s)),f=t(u),p=d.length;return f<0||f>=p?e?"":void 0:(l=i(d,f))<55296||l>56319||f+1===p||(c=i(d,f+1))<56320||c>57343?e?o(d,f):l:e?a(d,f,f+2):c-56320+(l-55296<<10)+65536}};return kf={codeAt:s(!1),charAt:s(!0)}}function qf(){return _f?Pf:(_f=1,Xd(),function(){if(If)return Wf;If=1;var e=Gf().charAt,t=qu(),n=dc(),r=Kd(),o=Yd(),i="String Iterator",a=n.set,s=n.getterFor(i);r(String,"String",function(e){a(this,{type:i,string:t(e),index:0})},function(){var t,n=s(this),r=n.string,i=n.index;return i>=r.length?o(void 0,!0):(t=e(r,i),n.index+=t.length,o(t,!1))})}(),Hc(),Pf=ic().f("iterator"))}function Kf(){if(Rf)return Lf;Rf=1;var e=qf();return Jd(),Lf=e}function Yf(){return jf?Mf:(jf=1,Mf=Kf())}function Xf(){return zf?Hf:(zf=1,Hf=Yf())}function Zf(){return Uf?$f:(Uf=1,$f=Xf())}var Jf=b(Zf());function Qf(e){return Qf="function"==typeof Vf&&"symbol"==typeof Jf?function(e){return typeof e}:function(e){return e&&"function"==typeof Vf&&e.constructor===Vf&&e!==Vf.prototype?"symbol":typeof e},Qf(e)}var ep,tp={};if(function(){if(ep)return tp;ep=1;var e=fr(),t=C(),n=N(),r=gn().f,o=Ae();e({target:"Object",stat:!0,forced:!o||t(function(){r(1)}),sham:!o},{getOwnPropertyDescriptor:function(e,t){return r(n(e),t)}})}(),"object"===("undefined"==typeof global?"undefined":Qf(global))){var np=Object.getOwnPropertyDescriptor(global,"window");global.window&&!np.set||(global.window=global,global.requestAnimationFrame=function(){},global.navigator={userAgent:""},global.location={hostname:"0.0.0.0",port:0,protocol:"http:"},global.btoa=function(){},global.crypto={getRandomValues:function(e){return nodeCrypto.randomFillSync(e)}}),null!=global.document&&null==global.document.getElementsByTagName&&(global.document.getElementsByTagName=function(){return[]})}
|
|
1
|
+
var e,t,r,n,o,i,a,s,u,l,c,d,h,f,p,g,m,v,y="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{};function b(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function D(e){if(Object.prototype.hasOwnProperty.call(e,"__esModule"))return e;var t=e.default;if("function"==typeof t){var r=function e(){var r=!1;try{r=this instanceof e}catch{}return r?Reflect.construct(t,arguments,this.constructor):t.apply(this,arguments)};r.prototype=t.prototype}else r={};return Object.defineProperty(r,"__esModule",{value:!0}),Object.keys(e).forEach(function(t){var n=Object.getOwnPropertyDescriptor(e,t);Object.defineProperty(r,t,n.get?n:{enumerable:!0,get:function(){return e[t]}})}),r}function C(){return t?e:(t=1,e=function(e){try{return!!e()}catch(e){return!0}})}function w(){if(n)return r;n=1;var e=C();return r=!e(function(){var e=function(){}.bind();return"function"!=typeof e||e.hasOwnProperty("prototype")})}function E(){if(i)return o;i=1;var e=w(),t=Function.prototype,r=t.call,n=e&&t.bind.bind(r,r);return o=e?n:function(e){return function(){return r.apply(e,arguments)}},o}function A(){if(s)return a;s=1;var e=E(),t=e({}.toString),r=e("".slice);return a=function(e){return r(t(e),8,-1)}}function x(){if(l)return u;l=1;var e=E(),t=C(),r=A(),n=Object,o=e("".split);return u=t(function(){return!n("z").propertyIsEnumerable(0)})?function(e){return"String"===r(e)?o(e,""):n(e)}:n}function B(){return d?c:(d=1,c=function(e){return null==e})}function S(){if(f)return h;f=1;var e=B(),t=TypeError;return h=function(r){if(e(r))throw new t("Can't call method on "+r);return r}}function F(){if(g)return p;g=1;var e=x(),t=S();return p=function(r){return e(t(r))}}function k(){if(v)return m;v=1;var e=function(e){return e&&e.Math===Math&&e};return m=e("object"==typeof globalThis&&globalThis)||e("object"==typeof window&&window)||e("object"==typeof self&&self)||e("object"==typeof y&&y)||e("object"==typeof m&&m)||function(){return this}()||Function("return this")()}var O,T,N,P,M,I,R,L,_,z,j,H,V,$,U,q,W,G,Y,K,X,Z,J,Q,ee,te,re,ne,oe,ie={exports:{}};function ae(){return T?O:(T=1,O=!1)}function se(){if(P)return N;P=1;var e=k(),t=Object.defineProperty;return N=function(r,n){try{t(e,r,{value:n,configurable:!0,writable:!0})}catch(t){e[r]=n}return n}}function ue(){if(M)return ie.exports;M=1;var e=ae(),t=k(),r=se(),n="__core-js_shared__",o=ie.exports=t[n]||r(n,{});return(o.versions||(o.versions=[])).push({version:"3.44.0",mode:e?"pure":"global",copyright:"© 2014-2025 Denis Pushkarev (zloirock.ru)",license:"https://github.com/zloirock/core-js/blob/v3.44.0/LICENSE",source:"https://github.com/zloirock/core-js"}),ie.exports}function le(){if(R)return I;R=1;var e=ue();return I=function(t,r){return e[t]||(e[t]=r||{})}}function ce(){if(_)return L;_=1;var e=S(),t=Object;return L=function(r){return t(e(r))}}function de(){if(j)return z;j=1;var e=E(),t=ce(),r=e({}.hasOwnProperty);return z=Object.hasOwn||function(e,n){return r(t(e),n)}}function he(){if(V)return H;V=1;var e=E(),t=0,r=Math.random(),n=e(1.1.toString);return H=function(e){return"Symbol("+(void 0===e?"":e)+")_"+n(++t+r,36)}}function fe(){if(W)return q;W=1;var e,t,r=k(),n=function(){if(U)return $;U=1;var e=k().navigator,t=e&&e.userAgent;return $=t?String(t):""}(),o=r.process,i=r.Deno,a=o&&o.versions||i&&i.version,s=a&&a.v8;return s&&(t=(e=s.split("."))[0]>0&&e[0]<4?1:+(e[0]+e[1])),!t&&n&&(!(e=n.match(/Edge\/(\d+)/))||e[1]>=74)&&(e=n.match(/Chrome\/(\d+)/))&&(t=+e[1]),q=t}function pe(){if(Y)return G;Y=1;var e=fe(),t=C(),r=k().String;return G=!!Object.getOwnPropertySymbols&&!t(function(){var t=Symbol("symbol detection");return!r(t)||!(Object(t)instanceof Symbol)||!Symbol.sham&&e&&e<41}),G}function ge(){if(X)return K;X=1;var e=pe();return K=e&&!Symbol.sham&&"symbol"==typeof Symbol.iterator}function me(){if(J)return Z;J=1;var e=k(),t=le(),r=de(),n=he(),o=pe(),i=ge(),a=e.Symbol,s=t("wks"),u=i?a.for||a:a&&a.withoutSetter||n;return Z=function(e){return r(s,e)||(s[e]=o&&r(a,e)?a[e]:u("Symbol."+e)),s[e]}}function ve(){if(ee)return Q;ee=1;var e="object"==typeof document&&document.all;return Q=void 0===e&&void 0!==e?function(t){return"function"==typeof t||t===e}:function(e){return"function"==typeof e}}function ye(){if(re)return te;re=1;var e=ve();return te=function(t){return"object"==typeof t?null!==t:e(t)}}function be(){if(oe)return ne;oe=1;var e=ye(),t=String,r=TypeError;return ne=function(n){if(e(n))return n;throw new r(t(n)+" is not an object")}}var De,Ce,we,Ee,Ae={};function xe(){if(Ce)return De;Ce=1;var e=C();return De=!e(function(){return 7!==Object.defineProperty({},1,{get:function(){return 7}})[1]})}function Be(){if(Ee)return we;Ee=1;var e=xe(),t=C();return we=e&&t(function(){return 42!==Object.defineProperty(function(){},"prototype",{value:42,writable:!1}).prototype})}var Se,Fe,ke,Oe,Te,Ne,Pe,Me,Ie,Re,Le,_e,ze,je,He,Ve,$e,Ue,qe,We,Ge,Ye,Ke,Xe,Ze,Je,Qe,et,tt,rt,nt,ot,it,at,st,ut,lt,ct,dt,ht,ft,pt,gt,mt,vt,yt,bt,Dt,Ct,wt,Et,At,xt,Bt,St,Ft,kt,Ot,Tt,Nt,Pt,Mt,It,Rt,Lt={};function _t(){if(Fe)return Se;Fe=1;var e=k(),t=ye(),r=e.document,n=t(r)&&t(r.createElement);return Se=function(e){return n?r.createElement(e):{}}}function zt(){if(Oe)return ke;Oe=1;var e=xe(),t=C(),r=_t();return ke=!e&&!t(function(){return 7!==Object.defineProperty(r("div"),"a",{get:function(){return 7}}).a})}function jt(){if(Ne)return Te;Ne=1;var e=w(),t=Function.prototype.call;return Te=e?t.bind(t):function(){return t.apply(t,arguments)},Te}function Ht(){if(Me)return Pe;Me=1;var e=k(),t=ve();return Pe=function(r,n){return arguments.length<2?(o=e[r],t(o)?o:void 0):e[r]&&e[r][n];var o},Pe}function Vt(){if(Re)return Ie;Re=1;var e=E();return Ie=e({}.isPrototypeOf)}function $t(){if(_e)return Le;_e=1;var e=Ht(),t=ve(),r=Vt(),n=ge(),o=Object;return Le=n?function(e){return"symbol"==typeof e}:function(n){var i=e("Symbol");return t(i)&&r(i.prototype,o(n))}}function Ut(){if(je)return ze;je=1;var e=String;return ze=function(t){try{return e(t)}catch(e){return"Object"}}}function qt(){if(Ve)return He;Ve=1;var e=ve(),t=Ut(),r=TypeError;return He=function(n){if(e(n))return n;throw new r(t(n)+" is not a function")}}function Wt(){if(Ue)return $e;Ue=1;var e=qt(),t=B();return $e=function(r,n){var o=r[n];return t(o)?void 0:e(o)},$e}function Gt(){if(Ye)return Ge;Ye=1;var e=jt(),t=ye(),r=$t(),n=Wt(),o=function(){if(We)return qe;We=1;var e=jt(),t=ve(),r=ye(),n=TypeError;return qe=function(o,i){var a,s;if("string"===i&&t(a=o.toString)&&!r(s=e(a,o)))return s;if(t(a=o.valueOf)&&!r(s=e(a,o)))return s;if("string"!==i&&t(a=o.toString)&&!r(s=e(a,o)))return s;throw new n("Can't convert object to primitive value")},qe}(),i=me(),a=TypeError,s=i("toPrimitive");return Ge=function(i,u){if(!t(i)||r(i))return i;var l,c=n(i,s);if(c){if(void 0===u&&(u="default"),l=e(c,i,u),!t(l)||r(l))return l;throw new a("Can't convert object to primitive value")}return void 0===u&&(u="number"),o(i,u)}}function Yt(){if(Xe)return Ke;Xe=1;var e=Gt(),t=$t();return Ke=function(r){var n=e(r,"string");return t(n)?n:n+""}}function Kt(){if(Ze)return Lt;Ze=1;var e=xe(),t=zt(),r=Be(),n=be(),o=Yt(),i=TypeError,a=Object.defineProperty,s=Object.getOwnPropertyDescriptor,u="enumerable",l="configurable",c="writable";return Lt.f=e?r?function(e,t,r){if(n(e),t=o(t),n(r),"function"==typeof e&&"prototype"===t&&"value"in r&&c in r&&!r[c]){var i=s(e,t);i&&i[c]&&(e[t]=r.value,r={configurable:l in r?r[l]:i[l],enumerable:u in r?r[u]:i[u],writable:!1})}return a(e,t,r)}:a:function(e,r,s){if(n(e),r=o(r),n(s),t)try{return a(e,r,s)}catch(e){}if("get"in s||"set"in s)throw new i("Accessors not supported");return"value"in s&&(e[r]=s.value),e},Lt}function Xt(){if(tt)return et;tt=1;var e=function(){if(Qe)return Je;Qe=1;var e=Math.ceil,t=Math.floor;return Je=Math.trunc||function(r){var n=+r;return(n>0?t:e)(n)},Je}();return et=function(t){var r=+t;return r!=r||0===r?0:e(r)}}function Zt(){if(it)return ot;it=1;var e=Xt(),t=Math.min;return ot=function(r){var n=e(r);return n>0?t(n,9007199254740991):0}}function Jt(){if(st)return at;st=1;var e=Zt();return at=function(t){return e(t.length)}}function Qt(){if(lt)return ut;lt=1;var e=F(),t=function(){if(nt)return rt;nt=1;var e=Xt(),t=Math.max,r=Math.min;return rt=function(n,o){var i=e(n);return i<0?t(i+o,0):r(i,o)},rt}(),r=Jt(),n=function(n){return function(o,i,a){var s=e(o),u=r(s);if(0===u)return!n&&-1;var l,c=t(a,u);if(n&&i!=i){for(;u>c;)if((l=s[c++])!=l)return!0}else for(;u>c;c++)if((n||c in s)&&s[c]===i)return n||c||0;return!n&&-1}};return ut={includes:n(!0),indexOf:n(!1)}}function er(){return dt?ct:(dt=1,ct={})}function tr(){if(ft)return ht;ft=1;var e=E(),t=de(),r=F(),n=Qt().indexOf,o=er(),i=e([].push);return ht=function(e,a){var s,u=r(e),l=0,c=[];for(s in u)!t(o,s)&&t(u,s)&&i(c,s);for(;a.length>l;)t(u,s=a[l++])&&(~n(c,s)||i(c,s));return c},ht}function rr(){return gt?pt:(gt=1,pt=["constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleString","toString","valueOf"])}function nr(){if(yt)return Ae;yt=1;var e=xe(),t=Be(),r=Kt(),n=be(),o=F(),i=function(){if(vt)return mt;vt=1;var e=tr(),t=rr();return mt=Object.keys||function(r){return e(r,t)},mt}();return Ae.f=e&&!t?Object.defineProperties:function(e,t){n(e);for(var a,s=o(t),u=i(t),l=u.length,c=0;l>c;)r.f(e,a=u[c++],s[a]);return e},Ae}function or(){if(wt)return Ct;wt=1;var e=le(),t=he(),r=e("keys");return Ct=function(e){return r[e]||(r[e]=t(e))}}function ir(){if(At)return Et;At=1;var e,t=be(),r=nr(),n=rr(),o=er(),i=function(){if(Dt)return bt;Dt=1;var e=Ht();return bt=e("document","documentElement")}(),a=_t(),s=or(),u="prototype",l="script",c=s("IE_PROTO"),d=function(){},h=function(e){return"<"+l+">"+e+"</"+l+">"},f=function(e){e.write(h("")),e.close();var t=e.parentWindow.Object;return e=null,t},p=function(){try{e=new ActiveXObject("htmlfile")}catch(e){}var t,r,o;p="undefined"!=typeof document?document.domain&&e?f(e):(r=a("iframe"),o="java"+l+":",r.style.display="none",i.appendChild(r),r.src=String(o),(t=r.contentWindow.document).open(),t.write(h("document.F=Object")),t.close(),t.F):f(e);for(var s=n.length;s--;)delete p[u][n[s]];return p()};return o[c]=!0,Et=Object.create||function(e,n){var o;return null!==e?(d[u]=t(e),o=new d,d[u]=null,o[c]=e):o=p(),void 0===n?o:r.f(o,n)},Et}function ar(){return Ft?St:(Ft=1,St={})}function sr(){return Nt?Tt:(Nt=1,Tt=function(e,t){return{enumerable:!(1&e),configurable:!(2&e),writable:!(4&e),value:t}})}function ur(){if(Mt)return Pt;Mt=1;var e=xe(),t=Kt(),r=sr();return Pt=e?function(e,n,o){return t.f(e,n,r(1,o))}:function(e,t,r){return e[t]=r,e}}function lr(){if(Rt)return It;Rt=1;var e,t,r,n=function(){if(Ot)return kt;Ot=1;var e=k(),t=ve(),r=e.WeakMap;return kt=t(r)&&/native code/.test(String(r))}(),o=k(),i=ye(),a=ur(),s=de(),u=ue(),l=or(),c=er(),d="Object already initialized",h=o.TypeError,f=o.WeakMap;if(n||u.state){var p=u.state||(u.state=new f);p.get=p.get,p.has=p.has,p.set=p.set,e=function(e,t){if(p.has(e))throw new h(d);return t.facade=e,p.set(e,t),t},t=function(e){return p.get(e)||{}},r=function(e){return p.has(e)}}else{var g=l("state");c[g]=!0,e=function(e,t){if(s(e,g))throw new h(d);return t.facade=e,a(e,g,t),t},t=function(e){return s(e,g)?e[g]:{}},r=function(e){return s(e,g)}}return It={set:e,get:t,has:r,enforce:function(n){return r(n)?t(n):e(n,{})},getterFor:function(e){return function(r){var n;if(!i(r)||(n=t(r)).type!==e)throw new h("Incompatible receiver, "+e+" required");return n}}}}var cr,dr,hr={},fr={};function pr(){if(dr)return hr;dr=1;var e=xe(),t=jt(),r=function(){if(cr)return fr;cr=1;var e={}.propertyIsEnumerable,t=Object.getOwnPropertyDescriptor,r=t&&!e.call({1:2},1);return fr.f=r?function(e){var r=t(this,e);return!!r&&r.enumerable}:e,fr}(),n=sr(),o=F(),i=Yt(),a=de(),s=zt(),u=Object.getOwnPropertyDescriptor;return hr.f=e?u:function(e,l){if(e=o(e),l=i(l),s)try{return u(e,l)}catch(e){}if(a(e,l))return n(!t(r.f,e,l),e[l])},hr}var gr,mr,vr,yr,br,Dr,Cr,wr={exports:{}};function Er(){if(mr)return gr;mr=1;var e=xe(),t=de(),r=Function.prototype,n=e&&Object.getOwnPropertyDescriptor,o=t(r,"name"),i=o&&"something"===function(){}.name,a=o&&(!e||e&&n(r,"name").configurable);return gr={EXISTS:o,PROPER:i,CONFIGURABLE:a}}function Ar(){if(yr)return vr;yr=1;var e=E(),t=ve(),r=ue(),n=e(Function.toString);return t(r.inspectSource)||(r.inspectSource=function(e){return n(e)}),vr=r.inspectSource}function xr(){if(br)return wr.exports;br=1;var e=E(),t=C(),r=ve(),n=de(),o=xe(),i=Er().CONFIGURABLE,a=Ar(),s=lr(),u=s.enforce,l=s.get,c=String,d=Object.defineProperty,h=e("".slice),f=e("".replace),p=e([].join),g=o&&!t(function(){return 8!==d(function(){},"length",{value:8}).length}),m=String(String).split("String"),v=wr.exports=function(e,t,r){"Symbol("===h(c(t),0,7)&&(t="["+f(c(t),/^Symbol\(([^)]*)\).*$/,"$1")+"]"),r&&r.getter&&(t="get "+t),r&&r.setter&&(t="set "+t),(!n(e,"name")||i&&e.name!==t)&&(o?d(e,"name",{value:t,configurable:!0}):e.name=t),g&&r&&n(r,"arity")&&e.length!==r.arity&&d(e,"length",{value:r.arity});try{r&&n(r,"constructor")&&r.constructor?o&&d(e,"prototype",{writable:!1}):e.prototype&&(e.prototype=void 0)}catch(e){}var a=u(e);return n(a,"source")||(a.source=p(m,"string"==typeof t?t:"")),e};return Function.prototype.toString=v(function(){return r(this)&&l(this).source||a(this)},"toString"),wr.exports}function Br(){if(Cr)return Dr;Cr=1;var e=ve(),t=Kt(),r=xr(),n=se();return Dr=function(o,i,a,s){s||(s={});var u=s.enumerable,l=void 0!==s.name?s.name:i;if(e(a)&&r(a,l,s),s.global)u?o[i]=a:n(i,a);else{try{s.unsafe?o[i]&&(u=!0):delete o[i]}catch(e){}u?o[i]=a:t.f(o,i,{value:a,enumerable:!1,configurable:!s.nonConfigurable,writable:!s.nonWritable})}return o},Dr}var Sr,Fr={};var kr,Or,Tr,Nr,Pr,Mr,Ir,Rr,Lr,_r,zr,jr,Hr,Vr,$r,Ur,qr,Wr,Gr,Yr,Kr,Xr,Zr,Jr,Qr,en,tn,rn,nn,on,an,sn,un,ln={};function cn(){if(Tr)return Or;Tr=1;var e=Ht(),t=E(),r=function(){if(Sr)return Fr;Sr=1;var e=tr(),t=rr().concat("length","prototype");return Fr.f=Object.getOwnPropertyNames||function(r){return e(r,t)},Fr}(),n=(kr||(kr=1,ln.f=Object.getOwnPropertySymbols),ln),o=be(),i=t([].concat);return Or=e("Reflect","ownKeys")||function(e){var t=r.f(o(e)),a=n.f;return a?i(t,a(e)):t},Or}function dn(){if(Pr)return Nr;Pr=1;var e=de(),t=cn(),r=pr(),n=Kt();return Nr=function(o,i,a){for(var s=t(i),u=n.f,l=r.f,c=0;c<s.length;c++){var d=s[c];e(o,d)||a&&e(a,d)||u(o,d,l(i,d))}},Nr}function hn(){if(Lr)return Rr;Lr=1;var e=k(),t=pr().f,r=ur(),n=Br(),o=se(),i=dn(),a=function(){if(Ir)return Mr;Ir=1;var e=C(),t=ve(),r=/#|\.prototype\./,n=function(r,n){var u=i[o(r)];return u===s||u!==a&&(t(n)?e(n):!!n)},o=n.normalize=function(e){return String(e).replace(r,".").toLowerCase()},i=n.data={},a=n.NATIVE="N",s=n.POLYFILL="P";return Mr=n}();return Rr=function(s,u){var l,c,d,h,f,p=s.target,g=s.global,m=s.stat;if(l=g?e:m?e[p]||o(p,{}):e[p]&&e[p].prototype)for(c in u){if(h=u[c],d=s.dontCallGetSet?(f=t(l,c))&&f.value:l[c],!a(g?c:p+(m?".":"#")+c,s.forced)&&void 0!==d){if(typeof h==typeof d)continue;i(h,d)}(s.sham||d&&d.sham)&&r(h,"sham",!0),n(l,c,h,s)}}}function fn(){if(Hr)return jr;Hr=1;var e=de(),t=ve(),r=ce(),n=or(),o=function(){if(zr)return _r;zr=1;var e=C();return _r=!e(function(){function e(){}return e.prototype.constructor=null,Object.getPrototypeOf(new e)!==e.prototype}),_r}(),i=n("IE_PROTO"),a=Object,s=a.prototype;return jr=o?a.getPrototypeOf:function(n){var o=r(n);if(e(o,i))return o[i];var u=o.constructor;return t(u)&&o instanceof u?u.prototype:o instanceof a?s:null},jr}function pn(){if($r)return Vr;$r=1;var e,t,r,n=C(),o=ve(),i=ye(),a=ir(),s=fn(),u=Br(),l=me(),c=ae(),d=l("iterator"),h=!1;return[].keys&&("next"in(r=[].keys())?(t=s(s(r)))!==Object.prototype&&(e=t):h=!0),!i(e)||n(function(){var t={};return e[d].call(t)!==t})?e={}:c&&(e=a(e)),o(e[d])||u(e,d,function(){return this}),Vr={IteratorPrototype:e,BUGGY_SAFARI_ITERATORS:h}}function gn(){if(qr)return Ur;qr=1;var e=Kt().f,t=de(),r=me()("toStringTag");return Ur=function(n,o,i){n&&!i&&(n=n.prototype),n&&!t(n,r)&&e(n,r,{configurable:!0,value:o})}}function mn(){if(Qr)return Jr;Qr=1;var e=function(){if(Zr)return Xr;Zr=1;var e=ye();return Xr=function(t){return e(t)||null===t}}(),t=String,r=TypeError;return Jr=function(n){if(e(n))return n;throw new r("Can't set "+t(n)+" as a prototype")}}function vn(){if(tn)return en;tn=1;var e=function(){if(Kr)return Yr;Kr=1;var e=E(),t=qt();return Yr=function(r,n,o){try{return e(t(Object.getOwnPropertyDescriptor(r,n)[o]))}catch(e){}}}(),t=ye(),r=S(),n=mn();return en=Object.setPrototypeOf||("__proto__"in{}?function(){var o,i=!1,a={};try{(o=e(Object.prototype,"__proto__","set"))(a,[]),i=a instanceof Array}catch(e){}return function(e,a){return r(e),n(a),t(e)?(i?o(e,a):e.__proto__=a,e):e}}():void 0),en}function yn(){if(nn)return rn;nn=1;var e=hn(),t=jt(),r=ae(),n=Er(),o=ve(),i=function(){if(Gr)return Wr;Gr=1;var e=pn().IteratorPrototype,t=ir(),r=sr(),n=gn(),o=ar(),i=function(){return this};return Wr=function(a,s,u,l){var c=s+" Iterator";return a.prototype=t(e,{next:r(+!l,u)}),n(a,c,!1,!0),o[c]=i,a}}(),a=fn(),s=vn(),u=gn(),l=ur(),c=Br(),d=me(),h=ar(),f=pn(),p=n.PROPER,g=n.CONFIGURABLE,m=f.IteratorPrototype,v=f.BUGGY_SAFARI_ITERATORS,y=d("iterator"),b="keys",D="values",C="entries",w=function(){return this};return rn=function(n,d,f,E,A,x,B){i(f,d,E);var S,F,k,O=function(e){if(e===A&&I)return I;if(!v&&e&&e in P)return P[e];switch(e){case b:case D:case C:return function(){return new f(this,e)}}return function(){return new f(this)}},T=d+" Iterator",N=!1,P=n.prototype,M=P[y]||P["@@iterator"]||A&&P[A],I=!v&&M||O(A),R="Array"===d&&P.entries||M;if(R&&(S=a(R.call(new n)))!==Object.prototype&&S.next&&(r||a(S)===m||(s?s(S,m):o(S[y])||c(S,y,w)),u(S,T,!0,!0),r&&(h[T]=w)),p&&A===D&&M&&M.name!==D&&(!r&&g?l(P,"name",D):(N=!0,I=function(){return t(M,this)})),A)if(F={values:O(D),keys:x?I:O(b),entries:O(C)},B)for(k in F)(v||N||!(k in P))&&c(P,k,F[k]);else e({target:d,proto:!0,forced:v||N},F);return r&&!B||P[y]===I||c(P,y,I,{name:A}),h[d]=I,F}}function bn(){return an?on:(an=1,on=function(e,t){return{value:e,done:t}})}function Dn(){if(un)return sn;un=1;var e=F(),t=function(){if(Bt)return xt;Bt=1;var e=me(),t=ir(),r=Kt().f,n=e("unscopables"),o=Array.prototype;return void 0===o[n]&&r(o,n,{configurable:!0,value:t(null)}),xt=function(e){o[n][e]=!0}}(),r=ar(),n=lr(),o=Kt().f,i=yn(),a=bn(),s=ae(),u=xe(),l="Array Iterator",c=n.set,d=n.getterFor(l);sn=i(Array,"Array",function(t,r){c(this,{type:l,target:e(t),index:0,kind:r})},function(){var e=d(this),t=e.target,r=e.index++;if(!t||r>=t.length)return e.target=null,a(void 0,!0);switch(e.kind){case"keys":return a(r,!1);case"values":return a(t[r],!1)}return a([r,t[r]],!1)},"values");var h=r.Arguments=r.Array;if(t("keys"),t("values"),t("entries"),!s&&u&&"values"!==h.name)try{o(h,"name",{value:"values"})}catch(e){}return sn}Dn();var Cn,wn,En,An,xn,Bn,Sn,Fn={};function kn(){if(wn)return Cn;wn=1;var e={};return e[me()("toStringTag")]="z",Cn="[object z]"===String(e)}function On(){if(An)return En;An=1;var e=kn(),t=ve(),r=A(),n=me()("toStringTag"),o=Object,i="Arguments"===r(function(){return arguments}());return En=e?r:function(e){var a,s,u;return void 0===e?"Undefined":null===e?"Null":"string"==typeof(s=function(e,t){try{return e[t]}catch(e){}}(a=o(e),n))?s:i?r(a):"Object"===(u=r(a))&&t(a.callee)?"Arguments":u},En}!function(){if(Sn)return Fn;Sn=1;var e=kn(),t=Br(),r=function(){if(Bn)return xn;Bn=1;var e=kn(),t=On();return xn=e?{}.toString:function(){return"[object "+t(this)+"]"}}();e||t(Object.prototype,"toString",r,{unsafe:!0})}();var Tn,Nn,Pn,Mn,In,Rn,Ln,_n,zn,jn,Hn,Vn,$n,Un={};function qn(){if(Nn)return Tn;Nn=1;var e=On(),t=String;return Tn=function(r){if("Symbol"===e(r))throw new TypeError("Cannot convert a Symbol value to a string");return t(r)}}function Wn(){if(Mn)return Pn;Mn=1;var e=be();return Pn=function(){var t=e(this),r="";return t.hasIndices&&(r+="d"),t.global&&(r+="g"),t.ignoreCase&&(r+="i"),t.multiline&&(r+="m"),t.dotAll&&(r+="s"),t.unicode&&(r+="u"),t.unicodeSets&&(r+="v"),t.sticky&&(r+="y"),r}}function Gn(){if(Vn)return Hn;Vn=1;var e,t,r=jt(),n=E(),o=qn(),i=Wn(),a=function(){if(Rn)return In;Rn=1;var e=C(),t=k().RegExp,r=e(function(){var e=t("a","y");return e.lastIndex=2,null!==e.exec("abcd")}),n=r||e(function(){return!t("a","y").sticky}),o=r||e(function(){var e=t("^r","gy");return e.lastIndex=2,null!==e.exec("str")});return In={BROKEN_CARET:o,MISSED_STICKY:n,UNSUPPORTED_Y:r}}(),s=le(),u=ir(),l=lr().get,c=function(){if(_n)return Ln;_n=1;var e=C(),t=k().RegExp;return Ln=e(function(){var e=t(".","s");return!(e.dotAll&&e.test("\n")&&"s"===e.flags)})}(),d=function(){if(jn)return zn;jn=1;var e=C(),t=k().RegExp;return zn=e(function(){var e=t("(?<a>b)","g");return"b"!==e.exec("b").groups.a||"bc"!=="b".replace(e,"$<a>c")})}(),h=s("native-string-replace",String.prototype.replace),f=RegExp.prototype.exec,p=f,g=n("".charAt),m=n("".indexOf),v=n("".replace),y=n("".slice),b=(t=/b*/g,r(f,e=/a/,"a"),r(f,t,"a"),0!==e.lastIndex||0!==t.lastIndex),D=a.BROKEN_CARET,w=void 0!==/()??/.exec("")[1];return(b||w||D||c||d)&&(p=function(e){var t,n,a,s,c,d,C,E=this,A=l(E),x=o(e),B=A.raw;if(B)return B.lastIndex=E.lastIndex,t=r(p,B,x),E.lastIndex=B.lastIndex,t;var S=A.groups,F=D&&E.sticky,k=r(i,E),O=E.source,T=0,N=x;if(F&&(k=v(k,"y",""),-1===m(k,"g")&&(k+="g"),N=y(x,E.lastIndex),E.lastIndex>0&&(!E.multiline||E.multiline&&"\n"!==g(x,E.lastIndex-1))&&(O="(?: "+O+")",N=" "+N,T++),n=new RegExp("^(?:"+O+")",k)),w&&(n=new RegExp("^"+O+"$(?!\\s)",k)),b&&(a=E.lastIndex),s=r(f,F?n:E,N),F?s?(s.input=y(s.input,T),s[0]=y(s[0],T),s.index=E.lastIndex,E.lastIndex+=s[0].length):E.lastIndex=0:b&&s&&(E.lastIndex=E.global?s.index+s[0].length:a),w&&s&&s.length>1&&r(h,s[0],n,function(){for(c=1;c<arguments.length-2;c++)void 0===arguments[c]&&(s[c]=void 0)}),s&&S)for(s.groups=d=u(null),c=0;c<S.length;c++)d[(C=S[c])[0]]=s[C[1]];return s}),Hn=p}function Yn(){if($n)return Un;$n=1;var e=hn(),t=Gn();return e({target:"RegExp",proto:!0,forced:/./.exec!==t},{exec:t}),Un}Yn();var Kn,Xn,Zn,Jn={};function Qn(){if(Xn)return Kn;Xn=1;var e=E(),t=Xt(),r=qn(),n=S(),o=e("".charAt),i=e("".charCodeAt),a=e("".slice),s=function(e){return function(s,u){var l,c,d=r(n(s)),h=t(u),f=d.length;return h<0||h>=f?e?"":void 0:(l=i(d,h))<55296||l>56319||h+1===f||(c=i(d,h+1))<56320||c>57343?e?o(d,h):l:e?a(d,h,h+2):c-56320+(l-55296<<10)+65536}};return Kn={codeAt:s(!1),charAt:s(!0)}}!function(){if(Zn)return Jn;Zn=1;var e=Qn().charAt,t=qn(),r=lr(),n=yn(),o=bn(),i="String Iterator",a=r.set,s=r.getterFor(i);n(String,"String",function(e){a(this,{type:i,string:t(e),index:0})},function(){var t,r=s(this),n=r.string,i=r.index;return i>=n.length?o(void 0,!0):(t=e(n,i),r.index+=t.length,o(t,!1))})}();var eo,to,ro,no,oo,io,ao,so,uo,lo,co,ho={};function fo(){if(no)return ro;no=1;var e=Qn().charAt;return ro=function(t,r,n){return r+(n?e(t,r).length:1)},ro}function po(){if(so)return ao;so=1;var e=jt(),t=de(),r=Vt(),n=function(){if(io)return oo;io=1;var e=k(),t=C(),r=e.RegExp,n=!t(function(){var e=!0;try{r(".","d")}catch(t){e=!1}var t={},n="",o=e?"dgimsy":"gimsy",i=function(e,r){Object.defineProperty(t,e,{get:function(){return n+=r,!0}})},a={dotAll:"s",global:"g",ignoreCase:"i",multiline:"m",sticky:"y"};for(var s in e&&(a.hasIndices="d"),a)i(s,a[s]);return Object.getOwnPropertyDescriptor(r.prototype,"flags").get.call(t)!==o||n!==o});return oo={correct:n}}(),o=Wn(),i=RegExp.prototype;return ao=n.correct?function(e){return e.flags}:function(a){return n.correct||!r(i,a)||t(a,"flags")?a.flags:e(o,a)}}!function(){if(co)return ho;co=1;var e=jt(),t=E(),r=function(){if(to)return eo;to=1,Yn();var e=jt(),t=Br(),r=Gn(),n=C(),o=me(),i=ur(),a=o("species"),s=RegExp.prototype;return eo=function(u,l,c,d){var h=o(u),f=!n(function(){var e={};return e[h]=function(){return 7},7!==""[u](e)}),p=f&&!n(function(){var e=!1,t=/a/;return"split"===u&&((t={}).constructor={},t.constructor[a]=function(){return t},t.flags="",t[h]=/./[h]),t.exec=function(){return e=!0,null},t[h](""),!e});if(!f||!p||c){var g=/./[h],m=l(h,""[u],function(t,n,o,i,a){var u=n.exec;return u===r||u===s.exec?f&&!a?{done:!0,value:e(g,n,o,i)}:{done:!0,value:e(t,o,n,i)}:{done:!1}});t(String.prototype,u,m[0]),t(s,h,m[1])}d&&i(s[h],"sham",!0)},eo}(),n=be(),o=ye(),i=Zt(),a=qn(),s=S(),u=Wt(),l=fo(),c=po(),d=function(){if(lo)return uo;lo=1;var e=jt(),t=be(),r=ve(),n=A(),o=Gn(),i=TypeError;return uo=function(a,s){var u=a.exec;if(r(u)){var l=e(u,a,s);return null!==l&&t(l),l}if("RegExp"===n(a))return e(o,a,s);throw new i("RegExp#exec called on incompatible receiver")},uo}(),h=t("".indexOf);r("match",function(t,r,f){return[function(r){var n=s(this),i=o(r)?u(r,t):void 0;return i?e(i,r,n):new RegExp(r)[t](a(n))},function(e){var t=n(this),o=a(e),s=f(r,t,o);if(s.done)return s.value;var u=a(c(t));if(-1===h(u,"g"))return d(t,o);var p=-1!==h(u,"u");t.lastIndex=0;for(var g,m=[],v=0;null!==(g=d(t,o));){var y=a(g[0]);m[v]=y,""===y&&(t.lastIndex=l(o,i(t.lastIndex),p)),v++}return 0===v?null:m}]})}();var go,mo,vo,yo,bo,Do,Co,wo,Eo,Ao,xo,Bo,So,Fo,ko,Oo,To,No,Po,Mo,Io,Ro,Lo,_o,zo,jo,Ho,Vo={},$o={};function Uo(){if(mo)return go;mo=1;var e=ye(),t=ur();return go=function(r,n){e(n)&&"cause"in n&&t(r,"cause",n.cause)},go}function qo(){if(wo)return Co;wo=1;var e=ur(),t=function(){if(yo)return vo;yo=1;var e=E(),t=Error,r=e("".replace),n=String(new t("zxcasd").stack),o=/\n\s*at [^:]*:[^\n]*/,i=o.test(n);return vo=function(e,n){if(i&&"string"==typeof e&&!t.prepareStackTrace)for(;n--;)e=r(e,o,"");return e}}(),r=function(){if(Do)return bo;Do=1;var e=C(),t=sr();return bo=!e(function(){var e=new Error("a");return!("stack"in e)||(Object.defineProperty(e,"stack",t(1,7)),7!==e.stack)})}(),n=Error.captureStackTrace;return Co=function(o,i,a,s){r&&(n?n(o,i):e(o,"stack",t(a,s)))},Co}function Wo(){if(Bo)return xo;Bo=1;var e=function(){if(Ao)return Eo;Ao=1;var e=A(),t=E();return Eo=function(r){if("Function"===e(r))return t(r)},Eo}(),t=qt(),r=w(),n=e(e.bind);return xo=function(e,o){return t(e),void 0===o?e:r?n(e,o):function(){return e.apply(o,arguments)}},xo}function Go(){if(Fo)return So;Fo=1;var e=me(),t=ar(),r=e("iterator"),n=Array.prototype;return So=function(e){return void 0!==e&&(t.Array===e||n[r]===e)}}function Yo(){if(Oo)return ko;Oo=1;var e=On(),t=Wt(),r=B(),n=ar(),o=me()("iterator");return ko=function(i){if(!r(i))return t(i,o)||t(i,"@@iterator")||n[e(i)]}}function Ko(){if(No)return To;No=1;var e=jt(),t=qt(),r=be(),n=Ut(),o=Yo(),i=TypeError;return To=function(a,s){var u=arguments.length<2?o(a):s;if(t(u))return r(e(u,a));throw new i(n(a)+" is not iterable")},To}function Xo(){if(Mo)return Po;Mo=1;var e=jt(),t=be(),r=Wt();return Po=function(n,o,i){var a,s;t(n);try{if(!(a=r(n,"return"))){if("throw"===o)throw i;return i}a=e(a,n)}catch(e){s=!0,a=e}if("throw"===o)throw i;if(s)throw a;return t(a),i},Po}function Zo(){if(Ro)return Io;Ro=1;var e=Wo(),t=jt(),r=be(),n=Ut(),o=Go(),i=Jt(),a=Vt(),s=Ko(),u=Yo(),l=Xo(),c=TypeError,d=function(e,t){this.stopped=e,this.result=t},h=d.prototype;return Io=function(f,p,g){var m,v,y,b,D,C,w,E=g&&g.that,A=!(!g||!g.AS_ENTRIES),x=!(!g||!g.IS_RECORD),B=!(!g||!g.IS_ITERATOR),S=!(!g||!g.INTERRUPTED),F=e(p,E),k=function(e){return m&&l(m,"normal"),new d(!0,e)},O=function(e){return A?(r(e),S?F(e[0],e[1],k):F(e[0],e[1])):S?F(e,k):F(e)};if(x)m=f.iterator;else if(B)m=f;else{if(!(v=u(f)))throw new c(n(f)+" is not iterable");if(o(v)){for(y=0,b=i(f);b>y;y++)if((D=O(f[y]))&&a(h,D))return D;return new d(!1)}m=s(f,v)}for(C=x?f.next:m.next;!(w=t(C,m)).done;){try{D=O(w.value)}catch(e){l(m,"throw",e)}if("object"==typeof D&&D&&a(h,D))return D}return new d(!1)},Io}function Jo(){if(_o)return Lo;_o=1;var e=qn();return Lo=function(t,r){return void 0===t?arguments.length<2?"":r:e(t)},Lo}function Qo(){return jo||(jo=1,function(){if(zo)return $o;zo=1;var e=hn(),t=Vt(),r=fn(),n=vn(),o=dn(),i=ir(),a=ur(),s=sr(),u=Uo(),l=qo(),c=Zo(),d=Jo(),h=me()("toStringTag"),f=Error,p=[].push,g=function(e,o){var s,v=t(m,this);n?s=n(new f,v?r(this):m):(s=v?this:i(m),a(s,h,"Error")),void 0!==o&&a(s,"message",d(o)),l(s,g,s.stack,1),arguments.length>2&&u(s,arguments[2]);var y=[];return c(e,p,{that:y}),a(s,"errors",y),s};n?n(g,f):o(g,f,{name:!0});var m=g.prototype=i(f.prototype,{constructor:s(1,g),message:s(1,""),name:s(1,"AggregateError")});e({global:!0,constructor:!0,arity:2},{AggregateError:g})}()),Vo}Ho||(Ho=1,Qo());var ei,ti,ri={};ti||(ti=1,function(){if(ei)return ri;ei=1;var e=hn(),t=k();e({global:!0,forced:t.globalThis!==t},{globalThis:t})}());var ni,oi,ii,ai,si,ui,li={};function ci(){return oi?ni:(oi=1,ni={CSSRuleList:0,CSSStyleDeclaration:0,CSSValueList:0,ClientRectList:0,DOMRectList:0,DOMStringList:0,DOMTokenList:1,DataTransferItemList:0,FileList:0,HTMLAllCollection:0,HTMLCollection:0,HTMLFormElement:0,HTMLSelectElement:0,MediaList:0,MimeTypeArray:0,NamedNodeMap:0,NodeList:1,PaintRequestList:0,Plugin:0,PluginArray:0,SVGLengthList:0,SVGNumberList:0,SVGPathSegList:0,SVGPointList:0,SVGStringList:0,SVGTransformList:0,SourceBufferList:0,StyleSheetList:0,TextTrackCueList:0,TextTrackList:0,TouchList:0})}function di(){if(ai)return ii;ai=1;var e=_t()("span").classList,t=e&&e.constructor&&e.constructor.prototype;return ii=t===Object.prototype?void 0:t}if(function(){if(si)return li;si=1;var e=k(),t=ci(),r=di(),n=Dn(),o=ur(),i=gn(),a=me()("iterator"),s=n.values,u=function(e,r){if(e){if(e[a]!==s)try{o(e,a,s)}catch(t){e[a]=s}if(i(e,r,!0),t[r])for(var u in n)if(e[u]!==n[u])try{o(e,u,n[u])}catch(t){e[u]=n[u]}}};for(var l in t)u(e[l]&&e[l].prototype,l);u(r,"DOMTokenList")}(),"undefined"==typeof global){if("ActiveXObject"in window){console.error("抱歉,wangEditor V5+ 版本开始,不在支持 IE 浏览器\n Sorry, wangEditor V5+ versions do not support IE browser.")}hi(),fi()}else global&&(null===(ui=global.navigator)||void 0===ui?void 0:ui.userAgent.match("QQBrowser"))&&(hi(),fi());function hi(){"undefined"==typeof globalThis&&(window.globalThis=window)}function fi(){"undefined"==typeof AggregateError&&(window.AggregateError=function(e,t){var r=new Error(t);return r.errors=e,r})}var pi,gi,mi,vi,yi,bi,Di,Ci,wi,Ei,Ai,xi,Bi,Si,Fi,ki,Oi={};function Ti(){if(gi)return pi;gi=1;var e=function(e){return e&&e.Math===Math&&e};return pi=e("object"==typeof globalThis&&globalThis)||e("object"==typeof window&&window)||e("object"==typeof self&&self)||e("object"==typeof y&&y)||e("object"==typeof pi&&pi)||function(){return this}()||Function("return this")()}function Ni(){return vi?mi:(vi=1,mi=function(e){try{return!!e()}catch(e){return!0}})}function Pi(){return bi?yi:(bi=1,yi=!Ni()(function(){var e=function(){}.bind();return"function"!=typeof e||e.hasOwnProperty("prototype")}))}function Mi(){if(Ci)return Di;Ci=1;var e=Pi(),t=Function.prototype,r=t.apply,n=t.call;return Di="object"==typeof Reflect&&Reflect.apply||(e?n.bind(r):function(){return n.apply(r,arguments)}),Di}function Ii(){if(Ei)return wi;Ei=1;var e=Pi(),t=Function.prototype,r=t.call,n=e&&t.bind.bind(r,r);return wi=e?n:function(e){return function(){return r.apply(e,arguments)}},wi}function Ri(){if(xi)return Ai;xi=1;var e=Ii(),t=e({}.toString),r=e("".slice);return Ai=function(e){return r(t(e),8,-1)}}function Li(){if(Si)return Bi;Si=1;var e=Ri(),t=Ii();return Bi=function(r){if("Function"===e(r))return t(r)},Bi}function _i(){if(ki)return Fi;ki=1;var e="object"==typeof document&&document.all;return Fi=void 0===e&&void 0!==e?function(t){return"function"==typeof t||t===e}:function(e){return"function"==typeof e}}var zi,ji,Hi,Vi,$i={};function Ui(){return ji?zi:(ji=1,zi=!Ni()(function(){return 7!==Object.defineProperty({},1,{get:function(){return 7}})[1]}))}function qi(){if(Vi)return Hi;Vi=1;var e=Pi(),t=Function.prototype.call;return Hi=e?t.bind(t):function(){return t.apply(t,arguments)},Hi}var Wi,Gi,Yi,Ki,Xi,Zi,Ji,Qi,ea,ta,ra,na,oa,ia,aa,sa,ua,la,ca,da,ha,fa,pa,ga,ma,va,ya,ba,Da,Ca,wa,Ea,Aa,xa,Ba,Sa,Fa,ka={};function Oa(){if(Wi)return ka;Wi=1;var e={}.propertyIsEnumerable,t=Object.getOwnPropertyDescriptor,r=t&&!e.call({1:2},1);return ka.f=r?function(e){var r=t(this,e);return!!r&&r.enumerable}:e,ka}function Ta(){return Yi?Gi:(Yi=1,Gi=function(e,t){return{enumerable:!(1&e),configurable:!(2&e),writable:!(4&e),value:t}})}function Na(){if(Xi)return Ki;Xi=1;var e=Ii(),t=Ni(),r=Ri(),n=Object,o=e("".split);return Ki=t(function(){return!n("z").propertyIsEnumerable(0)})?function(e){return"String"===r(e)?o(e,""):n(e)}:n}function Pa(){return Ji?Zi:(Ji=1,Zi=function(e){return null==e})}function Ma(){if(ea)return Qi;ea=1;var e=Pa(),t=TypeError;return Qi=function(r){if(e(r))throw new t("Can't call method on "+r);return r}}function Ia(){if(ra)return ta;ra=1;var e=Na(),t=Ma();return ta=function(r){return e(t(r))}}function Ra(){if(oa)return na;oa=1;var e=_i();return na=function(t){return"object"==typeof t?null!==t:e(t)}}function La(){return aa?ia:(aa=1,ia={})}function _a(){if(ua)return sa;ua=1;var e=La(),t=Ti(),r=_i(),n=function(e){return r(e)?e:void 0};return sa=function(r,o){return arguments.length<2?n(e[r])||n(t[r]):e[r]&&e[r][o]||t[r]&&t[r][o]},sa}function za(){return ca?la:(ca=1,la=Ii()({}.isPrototypeOf))}function ja(){if(ha)return da;ha=1;var e=Ti().navigator,t=e&&e.userAgent;return da=t?String(t):""}function Ha(){if(pa)return fa;pa=1;var e,t,r=Ti(),n=ja(),o=r.process,i=r.Deno,a=o&&o.versions||i&&i.version,s=a&&a.v8;return s&&(t=(e=s.split("."))[0]>0&&e[0]<4?1:+(e[0]+e[1])),!t&&n&&(!(e=n.match(/Edge\/(\d+)/))||e[1]>=74)&&(e=n.match(/Chrome\/(\d+)/))&&(t=+e[1]),fa=t}function Va(){if(ma)return ga;ma=1;var e=Ha(),t=Ni(),r=Ti().String;return ga=!!Object.getOwnPropertySymbols&&!t(function(){var t=Symbol("symbol detection");return!r(t)||!(Object(t)instanceof Symbol)||!Symbol.sham&&e&&e<41}),ga}function $a(){return ya?va:(ya=1,va=Va()&&!Symbol.sham&&"symbol"==typeof Symbol.iterator)}function Ua(){if(Da)return ba;Da=1;var e=_a(),t=_i(),r=za(),n=Object;return ba=$a()?function(e){return"symbol"==typeof e}:function(o){var i=e("Symbol");return t(i)&&r(i.prototype,n(o))}}function qa(){if(wa)return Ca;wa=1;var e=String;return Ca=function(t){try{return e(t)}catch(e){return"Object"}}}function Wa(){if(Aa)return Ea;Aa=1;var e=_i(),t=qa(),r=TypeError;return Ea=function(n){if(e(n))return n;throw new r(t(n)+" is not a function")}}function Ga(){if(Ba)return xa;Ba=1;var e=Wa(),t=Pa();return xa=function(r,n){var o=r[n];return t(o)?void 0:e(o)},xa}function Ya(){if(Fa)return Sa;Fa=1;var e=qi(),t=_i(),r=Ra(),n=TypeError;return Sa=function(o,i){var a,s;if("string"===i&&t(a=o.toString)&&!r(s=e(a,o)))return s;if(t(a=o.valueOf)&&!r(s=e(a,o)))return s;if("string"!==i&&t(a=o.toString)&&!r(s=e(a,o)))return s;throw new n("Can't convert object to primitive value")},Sa}var Ka,Xa,Za,Ja,Qa,es,ts,rs,ns,os,is,as,ss,us,ls,cs,ds,hs,fs,ps,gs,ms,vs,ys,bs,Ds,Cs,ws,Es={exports:{}};function As(){return Xa?Ka:(Xa=1,Ka=!0)}function xs(){if(Ja)return Za;Ja=1;var e=Ti(),t=Object.defineProperty;return Za=function(r,n){try{t(e,r,{value:n,configurable:!0,writable:!0})}catch(t){e[r]=n}return n}}function Bs(){if(Qa)return Es.exports;Qa=1;var e=As(),t=Ti(),r=xs(),n="__core-js_shared__",o=Es.exports=t[n]||r(n,{});return(o.versions||(o.versions=[])).push({version:"3.44.0",mode:e?"pure":"global",copyright:"© 2014-2025 Denis Pushkarev (zloirock.ru)",license:"https://github.com/zloirock/core-js/blob/v3.44.0/LICENSE",source:"https://github.com/zloirock/core-js"}),Es.exports}function Ss(){if(ts)return es;ts=1;var e=Bs();return es=function(t,r){return e[t]||(e[t]=r||{})}}function Fs(){if(ns)return rs;ns=1;var e=Ma(),t=Object;return rs=function(r){return t(e(r))}}function ks(){if(is)return os;is=1;var e=Ii(),t=Fs(),r=e({}.hasOwnProperty);return os=Object.hasOwn||function(e,n){return r(t(e),n)}}function Os(){if(ss)return as;ss=1;var e=Ii(),t=0,r=Math.random(),n=e(1.1.toString);return as=function(e){return"Symbol("+(void 0===e?"":e)+")_"+n(++t+r,36)}}function Ts(){if(ls)return us;ls=1;var e=Ti(),t=Ss(),r=ks(),n=Os(),o=Va(),i=$a(),a=e.Symbol,s=t("wks"),u=i?a.for||a:a&&a.withoutSetter||n;return us=function(e){return r(s,e)||(s[e]=o&&r(a,e)?a[e]:u("Symbol."+e)),s[e]}}function Ns(){if(ds)return cs;ds=1;var e=qi(),t=Ra(),r=Ua(),n=Ga(),o=Ya(),i=TypeError,a=Ts()("toPrimitive");return cs=function(s,u){if(!t(s)||r(s))return s;var l,c=n(s,a);if(c){if(void 0===u&&(u="default"),l=e(c,s,u),!t(l)||r(l))return l;throw new i("Can't convert object to primitive value")}return void 0===u&&(u="number"),o(s,u)}}function Ps(){if(fs)return hs;fs=1;var e=Ns(),t=Ua();return hs=function(r){var n=e(r,"string");return t(n)?n:n+""}}function Ms(){if(gs)return ps;gs=1;var e=Ti(),t=Ra(),r=e.document,n=t(r)&&t(r.createElement);return ps=function(e){return n?r.createElement(e):{}}}function Is(){if(vs)return ms;vs=1;var e=Ui(),t=Ni(),r=Ms();return ms=!e&&!t(function(){return 7!==Object.defineProperty(r("div"),"a",{get:function(){return 7}}).a})}function Rs(){if(ys)return $i;ys=1;var e=Ui(),t=qi(),r=Oa(),n=Ta(),o=Ia(),i=Ps(),a=ks(),s=Is(),u=Object.getOwnPropertyDescriptor;return $i.f=e?u:function(e,l){if(e=o(e),l=i(l),s)try{return u(e,l)}catch(e){}if(a(e,l))return n(!t(r.f,e,l),e[l])},$i}function Ls(){if(Ds)return bs;Ds=1;var e=Ni(),t=_i(),r=/#|\.prototype\./,n=function(r,n){var u=i[o(r)];return u===s||u!==a&&(t(n)?e(n):!!n)},o=n.normalize=function(e){return String(e).replace(r,".").toLowerCase()},i=n.data={},a=n.NATIVE="N",s=n.POLYFILL="P";return bs=n}function _s(){if(ws)return Cs;ws=1;var e=Li(),t=Wa(),r=Pi(),n=e(e.bind);return Cs=function(e,o){return t(e),void 0===o?e:r?n(e,o):function(){return e.apply(o,arguments)}},Cs}var zs,js,Hs,Vs,$s,Us,qs,Ws,Gs,Ys,Ks,Xs,Zs,Js,Qs,eu,tu,ru,nu,ou,iu,au,su,uu,lu,cu,du,hu,fu,pu,gu,mu,vu,yu,bu,Du,Cu,wu,Eu={};function Au(){return js?zs:(js=1,zs=Ui()&&Ni()(function(){return 42!==Object.defineProperty(function(){},"prototype",{value:42,writable:!1}).prototype}))}function xu(){if(Vs)return Hs;Vs=1;var e=Ra(),t=String,r=TypeError;return Hs=function(n){if(e(n))return n;throw new r(t(n)+" is not an object")}}function Bu(){if($s)return Eu;$s=1;var e=Ui(),t=Is(),r=Au(),n=xu(),o=Ps(),i=TypeError,a=Object.defineProperty,s=Object.getOwnPropertyDescriptor,u="enumerable",l="configurable",c="writable";return Eu.f=e?r?function(e,t,r){if(n(e),t=o(t),n(r),"function"==typeof e&&"prototype"===t&&"value"in r&&c in r&&!r[c]){var i=s(e,t);i&&i[c]&&(e[t]=r.value,r={configurable:l in r?r[l]:i[l],enumerable:u in r?r[u]:i[u],writable:!1})}return a(e,t,r)}:a:function(e,r,s){if(n(e),r=o(r),n(s),t)try{return a(e,r,s)}catch(e){}if("get"in s||"set"in s)throw new i("Accessors not supported");return"value"in s&&(e[r]=s.value),e},Eu}function Su(){if(qs)return Us;qs=1;var e=Ui(),t=Bu(),r=Ta();return Us=e?function(e,n,o){return t.f(e,n,r(1,o))}:function(e,t,r){return e[t]=r,e}}function Fu(){if(Gs)return Ws;Gs=1;var e=Ti(),t=Mi(),r=Li(),n=_i(),o=Rs().f,i=Ls(),a=La(),s=_s(),u=Su(),l=ks(),c=function(e){var r=function(n,o,i){if(this instanceof r){switch(arguments.length){case 0:return new e;case 1:return new e(n);case 2:return new e(n,o)}return new e(n,o,i)}return t(e,this,arguments)};return r.prototype=e.prototype,r};return Ws=function(t,d){var h,f,p,g,m,v,y,b,D,C=t.target,w=t.global,E=t.stat,A=t.proto,x=w?e:E?e[C]:e[C]&&e[C].prototype,B=w?a:a[C]||u(a,C,{})[C],S=B.prototype;for(g in d)f=!(h=i(w?g:C+(E?".":"#")+g,t.forced))&&x&&l(x,g),v=B[g],f&&(y=t.dontCallGetSet?(D=o(x,g))&&D.value:x[g]),m=f&&y?y:d[g],(h||A||typeof v!=typeof m)&&(b=t.bind&&f?s(m,e):t.wrap&&f?c(m):A&&n(m)?r(m):m,(t.sham||m&&m.sham||v&&v.sham)&&u(b,"sham",!0),u(B,g,b),A&&(l(a,p=C+"Prototype")||u(a,p,{}),u(a[p],g,m),t.real&&S&&(h||!S[g])&&u(S,g,m)))}}function ku(){if(Ks)return Ys;Ks=1;var e=Ri();return Ys=Array.isArray||function(t){return"Array"===e(t)}}function Ou(){if(Zs)return Xs;Zs=1;var e=Math.ceil,t=Math.floor;return Xs=Math.trunc||function(r){var n=+r;return(n>0?t:e)(n)},Xs}function Tu(){if(Qs)return Js;Qs=1;var e=Ou();return Js=function(t){var r=+t;return r!=r||0===r?0:e(r)}}function Nu(){if(tu)return eu;tu=1;var e=Tu(),t=Math.min;return eu=function(r){var n=e(r);return n>0?t(n,9007199254740991):0}}function Pu(){if(nu)return ru;nu=1;var e=Nu();return ru=function(t){return e(t.length)}}function Mu(){if(iu)return ou;iu=1;var e=TypeError;return ou=function(t){if(t>9007199254740991)throw e("Maximum allowed index exceeded");return t}}function Iu(){if(su)return au;su=1;var e=Ui(),t=Bu(),r=Ta();return au=function(n,o,i){e?t.f(n,o,r(0,i)):n[o]=i}}function Ru(){if(lu)return uu;lu=1;var e={};return e[Ts()("toStringTag")]="z",uu="[object z]"===String(e)}function Lu(){if(du)return cu;du=1;var e=Ru(),t=_i(),r=Ri(),n=Ts()("toStringTag"),o=Object,i="Arguments"===r(function(){return arguments}());return cu=e?r:function(e){var a,s,u;return void 0===e?"Undefined":null===e?"Null":"string"==typeof(s=function(e,t){try{return e[t]}catch(e){}}(a=o(e),n))?s:i?r(a):"Object"===(u=r(a))&&t(a.callee)?"Arguments":u},cu}function _u(){if(fu)return hu;fu=1;var e=Ii(),t=_i(),r=Bs(),n=e(Function.toString);return t(r.inspectSource)||(r.inspectSource=function(e){return n(e)}),hu=r.inspectSource}function zu(){if(gu)return pu;gu=1;var e=Ii(),t=Ni(),r=_i(),n=Lu(),o=_a(),i=_u(),a=function(){},s=o("Reflect","construct"),u=/^\s*(?:class|function)\b/,l=e(u.exec),c=!u.test(a),d=function(e){if(!r(e))return!1;try{return s(a,[],e),!0}catch(e){return!1}},h=function(e){if(!r(e))return!1;switch(n(e)){case"AsyncFunction":case"GeneratorFunction":case"AsyncGeneratorFunction":return!1}try{return c||!!l(u,i(e))}catch(e){return!0}};return h.sham=!0,pu=!s||t(function(){var e;return d(d.call)||!d(Object)||!d(function(){e=!0})||e})?h:d}function ju(){if(vu)return mu;vu=1;var e=ku(),t=zu(),r=Ra(),n=Ts()("species"),o=Array;return mu=function(i){var a;return e(i)&&(a=i.constructor,(t(a)&&(a===o||e(a.prototype))||r(a)&&null===(a=a[n]))&&(a=void 0)),void 0===a?o:a},mu}function Hu(){if(bu)return yu;bu=1;var e=ju();return yu=function(t,r){return new(e(t))(0===r?0:r)}}function Vu(){if(Cu)return Du;Cu=1;var e=Ni(),t=Ts(),r=Ha(),n=t("species");return Du=function(t){return r>=51||!e(function(){var e=[];return(e.constructor={})[n]=function(){return{foo:1}},1!==e[t](Boolean).foo})},Du}var $u,Uu,qu={},Wu={};function Gu(){if(Uu)return $u;Uu=1;var e=Lu(),t=String;return $u=function(r){if("Symbol"===e(r))throw new TypeError("Cannot convert a Symbol value to a string");return t(r)}}var Yu,Ku,Xu,Zu,Ju,Qu,el,tl,rl,nl,ol,il,al,sl,ul,ll,cl,dl,hl,fl={};function pl(){if(Ku)return Yu;Ku=1;var e=Tu(),t=Math.max,r=Math.min;return Yu=function(n,o){var i=e(n);return i<0?t(i+o,0):r(i,o)},Yu}function gl(){if(Zu)return Xu;Zu=1;var e=Ia(),t=pl(),r=Pu(),n=function(n){return function(o,i,a){var s=e(o),u=r(s);if(0===u)return!n&&-1;var l,c=t(a,u);if(n&&i!=i){for(;u>c;)if((l=s[c++])!=l)return!0}else for(;u>c;c++)if((n||c in s)&&s[c]===i)return n||c||0;return!n&&-1}};return Xu={includes:n(!0),indexOf:n(!1)}}function ml(){return Qu?Ju:(Qu=1,Ju={})}function vl(){if(tl)return el;tl=1;var e=Ii(),t=ks(),r=Ia(),n=gl().indexOf,o=ml(),i=e([].push);return el=function(e,a){var s,u=r(e),l=0,c=[];for(s in u)!t(o,s)&&t(u,s)&&i(c,s);for(;a.length>l;)t(u,s=a[l++])&&(~n(c,s)||i(c,s));return c},el}function yl(){return nl?rl:(nl=1,rl=["constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleString","toString","valueOf"])}function bl(){if(il)return ol;il=1;var e=vl(),t=yl();return ol=Object.keys||function(r){return e(r,t)},ol}function Dl(){if(al)return fl;al=1;var e=Ui(),t=Au(),r=Bu(),n=xu(),o=Ia(),i=bl();return fl.f=e&&!t?Object.defineProperties:function(e,t){n(e);for(var a,s=o(t),u=i(t),l=u.length,c=0;l>c;)r.f(e,a=u[c++],s[a]);return e},fl}function Cl(){return ul?sl:(ul=1,sl=_a()("document","documentElement"))}function wl(){if(cl)return ll;cl=1;var e=Ss(),t=Os(),r=e("keys");return ll=function(e){return r[e]||(r[e]=t(e))}}function El(){if(hl)return dl;hl=1;var e,t=xu(),r=Dl(),n=yl(),o=ml(),i=Cl(),a=Ms(),s="prototype",u="script",l=wl()("IE_PROTO"),c=function(){},d=function(e){return"<"+u+">"+e+"</"+u+">"},h=function(e){e.write(d("")),e.close();var t=e.parentWindow.Object;return e=null,t},f=function(){try{e=new ActiveXObject("htmlfile")}catch(e){}var t,r,o;f="undefined"!=typeof document?document.domain&&e?h(e):(r=a("iframe"),o="java"+u+":",r.style.display="none",i.appendChild(r),r.src=String(o),(t=r.contentWindow.document).open(),t.write(d("document.F=Object")),t.close(),t.F):h(e);for(var l=n.length;l--;)delete f[s][n[l]];return f()};return o[l]=!0,dl=Object.create||function(e,n){var o;return null!==e?(c[s]=t(e),o=new c,c[s]=null,o[l]=e):o=f(),void 0===n?o:r.f(o,n)},dl}var Al,xl={};function Bl(){if(Al)return xl;Al=1;var e=vl(),t=yl().concat("length","prototype");return xl.f=Object.getOwnPropertyNames||function(r){return e(r,t)},xl}var Sl,Fl,kl,Ol={};function Tl(){return Fl?Sl:(Fl=1,Sl=Ii()([].slice))}function Nl(){if(kl)return Ol;kl=1;var e=Ri(),t=Ia(),r=Bl().f,n=Tl(),o="object"==typeof window&&window&&Object.getOwnPropertyNames?Object.getOwnPropertyNames(window):[];return Ol.f=function(i){return o&&"Window"===e(i)?function(e){try{return r(e)}catch(e){return n(o)}}(i):r(t(i))},Ol}var Pl,Ml,Il,Rl,Ll,_l={};function zl(){return Pl||(Pl=1,_l.f=Object.getOwnPropertySymbols),_l}function jl(){if(Il)return Ml;Il=1;var e=Su();return Ml=function(t,r,n,o){return o&&o.enumerable?t[r]=n:e(t,r,n),t}}function Hl(){if(Ll)return Rl;Ll=1;var e=Bu();return Rl=function(t,r,n){return e.f(t,r,n)}}var Vl,$l,Ul,ql,Wl,Gl,Yl,Kl,Xl,Zl,Jl,Ql,ec,tc,rc,nc,oc={};function ic(){if(Vl)return oc;Vl=1;var e=Ts();return oc.f=e,oc}function ac(){if(Ul)return $l;Ul=1;var e=La(),t=ks(),r=ic(),n=Bu().f;return $l=function(o){var i=e.Symbol||(e.Symbol={});t(i,o)||n(i,o,{value:r.f(o)})}}function sc(){if(Wl)return ql;Wl=1;var e=qi(),t=_a(),r=Ts(),n=jl();return ql=function(){var o=t("Symbol"),i=o&&o.prototype,a=i&&i.valueOf,s=r("toPrimitive");i&&!i[s]&&n(i,s,function(t){return e(a,this)},{arity:1})}}function uc(){if(Yl)return Gl;Yl=1;var e=Ru(),t=Lu();return Gl=e?{}.toString:function(){return"[object "+t(this)+"]"}}function lc(){if(Xl)return Kl;Xl=1;var e=Ru(),t=Bu().f,r=Su(),n=ks(),o=uc(),i=Ts()("toStringTag");return Kl=function(a,s,u,l){var c=u?a:a&&a.prototype;c&&(n(c,i)||t(c,i,{configurable:!0,value:s}),l&&!e&&r(c,"toString",o))}}function cc(){if(Jl)return Zl;Jl=1;var e=Ti(),t=_i(),r=e.WeakMap;return Zl=t(r)&&/native code/.test(String(r))}function dc(){if(ec)return Ql;ec=1;var e,t,r,n=cc(),o=Ti(),i=Ra(),a=Su(),s=ks(),u=Bs(),l=wl(),c=ml(),d="Object already initialized",h=o.TypeError,f=o.WeakMap;if(n||u.state){var p=u.state||(u.state=new f);p.get=p.get,p.has=p.has,p.set=p.set,e=function(e,t){if(p.has(e))throw new h(d);return t.facade=e,p.set(e,t),t},t=function(e){return p.get(e)||{}},r=function(e){return p.has(e)}}else{var g=l("state");c[g]=!0,e=function(e,t){if(s(e,g))throw new h(d);return t.facade=e,a(e,g,t),t},t=function(e){return s(e,g)?e[g]:{}},r=function(e){return s(e,g)}}return Ql={set:e,get:t,has:r,enforce:function(n){return r(n)?t(n):e(n,{})},getterFor:function(e){return function(r){var n;if(!i(r)||(n=t(r)).type!==e)throw new h("Incompatible receiver, "+e+" required");return n}}}}function hc(){if(rc)return tc;rc=1;var e=_s(),t=Ii(),r=Na(),n=Fs(),o=Pu(),i=Hu(),a=t([].push),s=function(t){var s=1===t,u=2===t,l=3===t,c=4===t,d=6===t,h=7===t,f=5===t||d;return function(p,g,m,v){for(var y,b,D=n(p),C=r(D),w=o(C),E=e(g,m),A=0,x=v||i,B=s?x(p,w):u||h?x(p,0):void 0;w>A;A++)if((f||A in C)&&(b=E(y=C[A],A,D),t))if(s)B[A]=b;else if(b)switch(t){case 3:return!0;case 5:return y;case 6:return A;case 2:a(B,y)}else switch(t){case 4:return!1;case 7:a(B,y)}return d?-1:l||c?c:B}};return tc={forEach:s(0),map:s(1),filter:s(2),some:s(3),every:s(4),find:s(5),findIndex:s(6),filterReject:s(7)}}var fc,pc,gc,mc={};function vc(){return pc?fc:(pc=1,fc=Va()&&!!Symbol.for&&!!Symbol.keyFor)}var yc,bc={};var Dc,Cc,wc,Ec={};function Ac(){if(Cc)return Dc;Cc=1;var e=Ii(),t=ku(),r=_i(),n=Ri(),o=Gu(),i=e([].push);return Dc=function(e){if(r(e))return e;if(t(e)){for(var a=e.length,s=[],u=0;u<a;u++){var l=e[u];"string"==typeof l?i(s,l):"number"!=typeof l&&"Number"!==n(l)&&"String"!==n(l)||i(s,o(l))}var c=s.length,d=!0;return function(e,r){if(d)return d=!1,r;if(t(this))return r;for(var n=0;n<c;n++)if(s[n]===e)return r}}},Dc}var xc,Bc,Sc={};function Fc(){return Bc||(Bc=1,function(){if(nc)return Wu;nc=1;var e=Fu(),t=Ti(),r=qi(),n=Ii(),o=As(),i=Ui(),a=Va(),s=Ni(),u=ks(),l=za(),c=xu(),d=Ia(),h=Ps(),f=Gu(),p=Ta(),g=El(),m=bl(),v=Bl(),y=Nl(),b=zl(),D=Rs(),C=Bu(),w=Dl(),E=Oa(),A=jl(),x=Hl(),B=Ss(),S=wl(),F=ml(),k=Os(),O=Ts(),T=ic(),N=ac(),P=sc(),M=lc(),I=dc(),R=hc().forEach,L=S("hidden"),_="Symbol",z="prototype",j=I.set,H=I.getterFor(_),V=Object[z],$=t.Symbol,U=$&&$[z],q=t.RangeError,W=t.TypeError,G=t.QObject,Y=D.f,K=C.f,X=y.f,Z=E.f,J=n([].push),Q=B("symbols"),ee=B("op-symbols"),te=B("wks"),re=!G||!G[z]||!G[z].findChild,ne=function(e,t,r){var n=Y(V,t);n&&delete V[t],K(e,t,r),n&&e!==V&&K(V,t,n)},oe=i&&s(function(){return 7!==g(K({},"a",{get:function(){return K(this,"a",{value:7}).a}})).a})?ne:K,ie=function(e,t){var r=Q[e]=g(U);return j(r,{type:_,tag:e,description:t}),i||(r.description=t),r},ae=function(e,t,r){e===V&&ae(ee,t,r),c(e);var n=h(t);return c(r),u(Q,n)?(r.enumerable?(u(e,L)&&e[L][n]&&(e[L][n]=!1),r=g(r,{enumerable:p(0,!1)})):(u(e,L)||K(e,L,p(1,g(null))),e[L][n]=!0),oe(e,n,r)):K(e,n,r)},se=function(e,t){c(e);var n=d(t),o=m(n).concat(de(n));return R(o,function(t){i&&!r(ue,n,t)||ae(e,t,n[t])}),e},ue=function(e){var t=h(e),n=r(Z,this,t);return!(this===V&&u(Q,t)&&!u(ee,t))&&(!(n||!u(this,t)||!u(Q,t)||u(this,L)&&this[L][t])||n)},le=function(e,t){var r=d(e),n=h(t);if(r!==V||!u(Q,n)||u(ee,n)){var o=Y(r,n);return!o||!u(Q,n)||u(r,L)&&r[L][n]||(o.enumerable=!0),o}},ce=function(e){var t=X(d(e)),r=[];return R(t,function(e){u(Q,e)||u(F,e)||J(r,e)}),r},de=function(e){var t=e===V,r=X(t?ee:d(e)),n=[];return R(r,function(e){!u(Q,e)||t&&!u(V,e)||J(n,Q[e])}),n};a||($=function(){if(l(U,this))throw new W("Symbol is not a constructor");var e=arguments.length&&void 0!==arguments[0]?f(arguments[0]):void 0,n=k(e),o=function(e){var i=void 0===this?t:this;i===V&&r(o,ee,e),u(i,L)&&u(i[L],n)&&(i[L][n]=!1);var a=p(1,e);try{oe(i,n,a)}catch(e){if(!(e instanceof q))throw e;ne(i,n,a)}};return i&&re&&oe(V,n,{configurable:!0,set:o}),ie(n,e)},A(U=$[z],"toString",function(){return H(this).tag}),A($,"withoutSetter",function(e){return ie(k(e),e)}),E.f=ue,C.f=ae,w.f=se,D.f=le,v.f=y.f=ce,b.f=de,T.f=function(e){return ie(O(e),e)},i&&(x(U,"description",{configurable:!0,get:function(){return H(this).description}}),o||A(V,"propertyIsEnumerable",ue,{unsafe:!0}))),e({global:!0,constructor:!0,wrap:!0,forced:!a,sham:!a},{Symbol:$}),R(m(te),function(e){N(e)}),e({target:_,stat:!0,forced:!a},{useSetter:function(){re=!0},useSimple:function(){re=!1}}),e({target:"Object",stat:!0,forced:!a,sham:!i},{create:function(e,t){return void 0===t?g(e):se(g(e),t)},defineProperty:ae,defineProperties:se,getOwnPropertyDescriptor:le}),e({target:"Object",stat:!0,forced:!a},{getOwnPropertyNames:ce}),P(),M($,_),F[L]=!0}(),function(){if(gc)return mc;gc=1;var e=Fu(),t=_a(),r=ks(),n=Gu(),o=Ss(),i=vc(),a=o("string-to-symbol-registry"),s=o("symbol-to-string-registry");e({target:"Symbol",stat:!0,forced:!i},{for:function(e){var o=n(e);if(r(a,o))return a[o];var i=t("Symbol")(o);return a[o]=i,s[i]=o,i}})}(),function(){if(yc)return bc;yc=1;var e=Fu(),t=ks(),r=Ua(),n=qa(),o=Ss(),i=vc(),a=o("symbol-to-string-registry");e({target:"Symbol",stat:!0,forced:!i},{keyFor:function(e){if(!r(e))throw new TypeError(n(e)+" is not a symbol");if(t(a,e))return a[e]}})}(),function(){if(wc)return Ec;wc=1;var e=Fu(),t=_a(),r=Mi(),n=qi(),o=Ii(),i=Ni(),a=_i(),s=Ua(),u=Tl(),l=Ac(),c=Va(),d=String,h=t("JSON","stringify"),f=o(/./.exec),p=o("".charAt),g=o("".charCodeAt),m=o("".replace),v=o(1.1.toString),y=/[\uD800-\uDFFF]/g,b=/^[\uD800-\uDBFF]$/,D=/^[\uDC00-\uDFFF]$/,C=!c||i(function(){var e=t("Symbol")("stringify detection");return"[null]"!==h([e])||"{}"!==h({a:e})||"{}"!==h(Object(e))}),w=i(function(){return'"\\udf06\\ud834"'!==h("\udf06\ud834")||'"\\udead"'!==h("\udead")}),E=function(e,t){var o=u(arguments),i=l(t);if(a(i)||void 0!==e&&!s(e))return o[1]=function(e,t){if(a(i)&&(t=n(i,this,d(e),t)),!s(t))return t},r(h,null,o)},A=function(e,t,r){var n=p(r,t-1),o=p(r,t+1);return f(b,e)&&!f(D,o)||f(D,e)&&!f(b,n)?"\\u"+v(g(e,0),16):e};h&&e({target:"JSON",stat:!0,arity:3,forced:C||w},{stringify:function(e,t,n){var o=u(arguments),i=r(C?E:h,null,o);return w&&"string"==typeof i?m(i,y,A):i}})}(),function(){if(xc)return Sc;xc=1;var e=Fu(),t=Va(),r=Ni(),n=zl(),o=Fs();e({target:"Object",stat:!0,forced:!t||r(function(){n.f(1)})},{getOwnPropertySymbols:function(e){var t=n.f;return t?t(o(e)):[]}})}()),qu}var kc,Oc={};function Tc(){return kc||(kc=1,ac()("asyncDispose")),Oc}var Nc;var Pc,Mc={};function Ic(){return Pc||(Pc=1,ac()("dispose")),Mc}var Rc;var Lc;var _c,zc={};function jc(){return _c||(_c=1,ac()("iterator")),zc}var Hc;var Vc;var $c;var Uc;var qc;var Wc;var Gc,Yc={};var Kc,Xc={};var Zc;var Jc,Qc,ed,td={};function rd(){return ed?Qc:(ed=1,function(){if(wu)return Oi;wu=1;var e=Fu(),t=Ni(),r=ku(),n=Ra(),o=Fs(),i=Pu(),a=Mu(),s=Iu(),u=Hu(),l=Vu(),c=Ts(),d=Ha(),h=c("isConcatSpreadable"),f=d>=51||!t(function(){var e=[];return e[h]=!1,e.concat()[0]!==e}),p=function(e){if(!n(e))return!1;var t=e[h];return void 0!==t?!!t:r(e)};e({target:"Array",proto:!0,arity:1,forced:!f||!l("concat")},{concat:function(e){var t,r,n,l,c,d=o(this),h=u(d,0),f=0;for(t=-1,n=arguments.length;t<n;t++)if(p(c=-1===t?d:arguments[t]))for(l=i(c),a(f+l),r=0;r<l;r++,f++)r in c&&s(h,f,c[r]);else a(f+1),s(h,f++,c);return h.length=f,h}})}(),Fc(),Tc(),Nc||(Nc=1,ac()("asyncIterator")),Ic(),Rc||(Rc=1,ac()("hasInstance")),Lc||(Lc=1,ac()("isConcatSpreadable")),jc(),Hc||(Hc=1,ac()("match")),Vc||(Vc=1,ac()("matchAll")),$c||($c=1,ac()("replace")),Uc||(Uc=1,ac()("search")),qc||(qc=1,ac()("species")),Wc||(Wc=1,ac()("split")),function(){if(Gc)return Yc;Gc=1;var e=ac(),t=sc();e("toPrimitive"),t()}(),function(){if(Kc)return Xc;Kc=1;var e=_a(),t=ac(),r=lc();t("toStringTag"),r(e("Symbol"),"Symbol")}(),Zc||(Zc=1,ac()("unscopables")),function(){if(Jc)return td;Jc=1;var e=Ti();lc()(e.JSON,"JSON",!0)}(),Qc=La().Symbol)}var nd,od,id,ad,sd,ud,ld,cd,dd,hd,fd,pd,gd,md,vd,yd,bd,Dd,Cd,wd,Ed,Ad,xd,Bd,Sd,Fd,kd,Od,Td,Nd,Pd,Md,Id,Rd={};function Ld(){return od?nd:(od=1,nd=function(){})}function _d(){return ad?id:(ad=1,id={})}function zd(){if(ud)return sd;ud=1;var e=Ui(),t=ks(),r=Function.prototype,n=e&&Object.getOwnPropertyDescriptor,o=t(r,"name"),i=o&&"something"===function(){}.name,a=o&&(!e||e&&n(r,"name").configurable);return sd={EXISTS:o,PROPER:i,CONFIGURABLE:a}}function jd(){return cd||(cd=1,ld=!Ni()(function(){function e(){}return e.prototype.constructor=null,Object.getPrototypeOf(new e)!==e.prototype})),ld}function Hd(){if(hd)return dd;hd=1;var e=ks(),t=_i(),r=Fs(),n=wl(),o=jd(),i=n("IE_PROTO"),a=Object,s=a.prototype;return dd=o?a.getPrototypeOf:function(n){var o=r(n);if(e(o,i))return o[i];var u=o.constructor;return t(u)&&o instanceof u?u.prototype:o instanceof a?s:null},dd}function Vd(){if(pd)return fd;pd=1;var e,t,r,n=Ni(),o=_i(),i=Ra(),a=El(),s=Hd(),u=jl(),l=Ts(),c=As(),d=l("iterator"),h=!1;return[].keys&&("next"in(r=[].keys())?(t=s(s(r)))!==Object.prototype&&(e=t):h=!0),!i(e)||n(function(){var t={};return e[d].call(t)!==t})?e={}:c&&(e=a(e)),o(e[d])||u(e,d,function(){return this}),fd={IteratorPrototype:e,BUGGY_SAFARI_ITERATORS:h}}function $d(){if(md)return gd;md=1;var e=Vd().IteratorPrototype,t=El(),r=Ta(),n=lc(),o=_d(),i=function(){return this};return gd=function(a,s,u,l){var c=s+" Iterator";return a.prototype=t(e,{next:r(+!l,u)}),n(a,c,!1,!0),o[c]=i,a}}function Ud(){if(yd)return vd;yd=1;var e=Ii(),t=Wa();return vd=function(r,n,o){try{return e(t(Object.getOwnPropertyDescriptor(r,n)[o]))}catch(e){}}}function qd(){if(Dd)return bd;Dd=1;var e=Ra();return bd=function(t){return e(t)||null===t}}function Wd(){if(wd)return Cd;wd=1;var e=qd(),t=String,r=TypeError;return Cd=function(n){if(e(n))return n;throw new r("Can't set "+t(n)+" as a prototype")}}function Gd(){if(Ad)return Ed;Ad=1;var e=Ud(),t=Ra(),r=Ma(),n=Wd();return Ed=Object.setPrototypeOf||("__proto__"in{}?function(){var o,i=!1,a={};try{(o=e(Object.prototype,"__proto__","set"))(a,[]),i=a instanceof Array}catch(e){}return function(e,a){return r(e),n(a),t(e)?(i?o(e,a):e.__proto__=a,e):e}}():void 0),Ed}function Yd(){if(Bd)return xd;Bd=1;var e=Fu(),t=qi(),r=As(),n=zd(),o=_i(),i=$d(),a=Hd(),s=Gd(),u=lc(),l=Su(),c=jl(),d=Ts(),h=_d(),f=Vd(),p=n.PROPER,g=n.CONFIGURABLE,m=f.IteratorPrototype,v=f.BUGGY_SAFARI_ITERATORS,y=d("iterator"),b="keys",D="values",C="entries",w=function(){return this};return xd=function(n,d,f,E,A,x,B){i(f,d,E);var S,F,k,O=function(e){if(e===A&&I)return I;if(!v&&e&&e in P)return P[e];switch(e){case b:case D:case C:return function(){return new f(this,e)}}return function(){return new f(this)}},T=d+" Iterator",N=!1,P=n.prototype,M=P[y]||P["@@iterator"]||A&&P[A],I=!v&&M||O(A),R="Array"===d&&P.entries||M;if(R&&(S=a(R.call(new n)))!==Object.prototype&&S.next&&(r||a(S)===m||(s?s(S,m):o(S[y])||c(S,y,w)),u(S,T,!0,!0),r&&(h[T]=w)),p&&A===D&&M&&M.name!==D&&(!r&&g?l(P,"name",D):(N=!0,I=function(){return t(M,this)})),A)if(F={values:O(D),keys:x?I:O(b),entries:O(C)},B)for(k in F)(v||N||!(k in P))&&c(P,k,F[k]);else e({target:d,proto:!0,forced:v||N},F);return r&&!B||P[y]===I||c(P,y,I,{name:A}),h[d]=I,F}}function Kd(){return Fd?Sd:(Fd=1,Sd=function(e,t){return{value:e,done:t}})}function Xd(){if(Od)return kd;Od=1;var e=Ia(),t=Ld(),r=_d(),n=dc(),o=Bu().f,i=Yd(),a=Kd(),s=As(),u=Ui(),l="Array Iterator",c=n.set,d=n.getterFor(l);kd=i(Array,"Array",function(t,r){c(this,{type:l,target:e(t),index:0,kind:r})},function(){var e=d(this),t=e.target,r=e.index++;if(!t||r>=t.length)return e.target=null,a(void 0,!0);switch(e.kind){case"keys":return a(r,!1);case"values":return a(t[r],!1)}return a([r,t[r]],!1)},"values");var h=r.Arguments=r.Array;if(t("keys"),t("values"),t("entries"),!s&&u&&"values"!==h.name)try{o(h,"name",{value:"values"})}catch(e){}return kd}function Zd(){return Nd?Td:(Nd=1,Td={CSSRuleList:0,CSSStyleDeclaration:0,CSSValueList:0,ClientRectList:0,DOMRectList:0,DOMStringList:0,DOMTokenList:1,DataTransferItemList:0,FileList:0,HTMLAllCollection:0,HTMLCollection:0,HTMLFormElement:0,HTMLSelectElement:0,MediaList:0,MimeTypeArray:0,NamedNodeMap:0,NodeList:1,PaintRequestList:0,Plugin:0,PluginArray:0,SVGLengthList:0,SVGNumberList:0,SVGPathSegList:0,SVGPointList:0,SVGStringList:0,SVGTransformList:0,SourceBufferList:0,StyleSheetList:0,TextTrackCueList:0,TextTrackList:0,TouchList:0})}function Jd(){if(Pd)return Rd;Pd=1,Xd();var e=Zd(),t=Ti(),r=lc(),n=_d();for(var o in e)r(t[o],o),n[o]=n.Array;return Rd}function Qd(){if(Id)return Md;Id=1;var e=rd();return Jd(),Md=e}var eh,th={};var rh;var nh;var oh,ih,ah;function sh(){if(ah)return ih;ah=1;var e=Qd();return function(){if(eh)return th;eh=1;var e=Ts(),t=Bu().f,r=e("metadata"),n=Function.prototype;void 0===n[r]&&t(n,r,{value:null})}(),rh||(rh=1,Tc()),nh||(nh=1,Ic()),oh||(oh=1,ac()("metadata")),ih=e}var uh,lh,ch;function dh(){if(lh)return uh;lh=1;var e=_a(),t=Ii(),r=e("Symbol"),n=r.keyFor,o=t(r.prototype.valueOf);return uh=r.isRegisteredSymbol||function(e){try{return void 0!==n(o(e))}catch(e){return!1}}}var hh,fh,ph;function gh(){if(fh)return hh;fh=1;for(var e=Ss(),t=_a(),r=Ii(),n=Ua(),o=Ts(),i=t("Symbol"),a=i.isWellKnownSymbol,s=t("Object","getOwnPropertyNames"),u=r(i.prototype.valueOf),l=e("wks"),c=0,d=s(i),h=d.length;c<h;c++)try{var f=d[c];n(i[f])&&o(f)}catch(e){}return hh=function(e){if(a&&a(e))return!0;try{for(var t=u(e),r=0,n=s(l),o=n.length;r<o;r++)if(l[n[r]]==t)return!0}catch(e){}return!1},hh}var mh;var vh;var yh;var bh;var Dh;var Ch;var wh;var Eh,Ah,xh,Bh,Sh;function Fh(){if(xh)return Ah;xh=1;var e=sh();return ch||(ch=1,Fu()({target:"Symbol",stat:!0},{isRegisteredSymbol:dh()})),ph||(ph=1,Fu()({target:"Symbol",stat:!0,forced:!0},{isWellKnownSymbol:gh()})),mh||(mh=1,ac()("customMatcher")),vh||(vh=1,ac()("observable")),yh||(yh=1,Fu()({target:"Symbol",stat:!0,name:"isRegisteredSymbol"},{isRegistered:dh()})),bh||(bh=1,Fu()({target:"Symbol",stat:!0,name:"isWellKnownSymbol",forced:!0},{isWellKnown:gh()})),Dh||(Dh=1,ac()("matcher")),Ch||(Ch=1,ac()("metadataKey")),wh||(wh=1,ac()("patternMatch")),Eh||(Eh=1,ac()("replaceAll")),Ah=e}function kh(){return Sh?Bh:(Sh=1,Bh=Fh())}var Oh,Th,Nh,Ph,Mh,Ih,Rh,Lh,_h,zh,jh,Hh,Vh,$h=b(kh()),Uh={};function qh(){if(Th)return Oh;Th=1;var e=Ii(),t=Tu(),r=Gu(),n=Ma(),o=e("".charAt),i=e("".charCodeAt),a=e("".slice),s=function(e){return function(s,u){var l,c,d=r(n(s)),h=t(u),f=d.length;return h<0||h>=f?e?"":void 0:(l=i(d,h))<55296||l>56319||h+1===f||(c=i(d,h+1))<56320||c>57343?e?o(d,h):l:e?a(d,h,h+2):c-56320+(l-55296<<10)+65536}};return Oh={codeAt:s(!1),charAt:s(!0)}}function Wh(){return Mh?Ph:(Mh=1,Xd(),function(){if(Nh)return Uh;Nh=1;var e=qh().charAt,t=Gu(),r=dc(),n=Yd(),o=Kd(),i="String Iterator",a=r.set,s=r.getterFor(i);n(String,"String",function(e){a(this,{type:i,string:t(e),index:0})},function(){var t,r=s(this),n=r.string,i=r.index;return i>=n.length?o(void 0,!0):(t=e(n,i),r.index+=t.length,o(t,!1))})}(),jc(),Ph=ic().f("iterator"))}function Gh(){if(Rh)return Ih;Rh=1;var e=Wh();return Jd(),Ih=e}function Yh(){return _h?Lh:(_h=1,Lh=Gh())}function Kh(){return jh?zh:(jh=1,zh=Yh())}function Xh(){return Vh?Hh:(Vh=1,Hh=Kh())}var Zh=b(Xh());function Jh(e){return Jh="function"==typeof $h&&"symbol"==typeof Zh?function(e){return typeof e}:function(e){return e&&"function"==typeof $h&&e.constructor===$h&&e!==$h.prototype?"symbol":typeof e},Jh(e)}var Qh,ef={};if(function(){if(Qh)return ef;Qh=1;var e=hn(),t=C(),r=F(),n=pr().f,o=xe();e({target:"Object",stat:!0,forced:!o||t(function(){n(1)}),sham:!o},{getOwnPropertyDescriptor:function(e,t){return n(r(e),t)}})}(),"object"===("undefined"==typeof global?"undefined":Jh(global))){var tf=Object.getOwnPropertyDescriptor(global,"window");global.window&&!tf.set||(global.window=global,global.requestAnimationFrame=function(){},global.navigator={userAgent:""},global.location={hostname:"0.0.0.0",port:0,protocol:"http:"},global.btoa=function(){},global.crypto={getRandomValues:function(e){return nodeCrypto.randomFillSync(e)}}),null!=global.document&&null==global.document.getElementsByTagName&&(global.document.getElementsByTagName=function(){return[]})}
|
|
2
2
|
/*!
|
|
3
3
|
* is-plain-object <https://github.com/jonschlinkert/is-plain-object>
|
|
4
4
|
*
|
|
5
5
|
* Copyright (c) 2014-2017, Jon Schlinkert.
|
|
6
6
|
* Released under the MIT License.
|
|
7
|
-
*/function rp(e){return"[object Object]"===Object.prototype.toString.call(e)}function op(e){var t,n;return!1!==rp(e)&&(void 0===(t=e.constructor)||!1!==rp(n=t.prototype)&&!1!==n.hasOwnProperty("isPrototypeOf"))}function ip(e){for(var t=arguments.length,n=Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];throw Error("[Immer] minified error nr: "+e+(n.length?" "+n.map(function(e){return"'"+e+"'"}).join(","):"")+". Find the full error at: https://bit.ly/3cXEKWf")}function ap(e){return!!e&&!!e[Wp]}function sp(e){var t;return!!e&&(function(e){if(!e||"object"!=typeof e)return!1;var t=Object.getPrototypeOf(e);if(null===t)return!0;var n=Object.hasOwnProperty.call(t,"constructor")&&t.constructor;return n===Object||"function"==typeof n&&Function.toString.call(n)===Gp}(e)||Array.isArray(e)||!!e[Vp]||!!(null===(t=e.constructor)||void 0===t?void 0:t[Vp])||fp(e)||pp(e))}function up(e,t,n){void 0===n&&(n=!1),0===lp(e)?(n?Object.keys:qp)(e).forEach(function(r){n&&"symbol"==typeof r||t(r,e[r],e)}):e.forEach(function(n,r){return t(r,n,e)})}function lp(e){var t=e[Wp];return t?t.i>3?t.i-4:t.i:Array.isArray(e)?1:fp(e)?2:pp(e)?3:0}function cp(e,t){return 2===lp(e)?e.has(t):Object.prototype.hasOwnProperty.call(e,t)}function dp(e,t,n){var r=lp(e);2===r?e.set(t,n):3===r?e.add(n):e[t]=n}function fp(e){return Hp&&e instanceof Map}function pp(e){return zp&&e instanceof Set}function hp(e){return e.o||e.t}function gp(e){if(Array.isArray(e))return Array.prototype.slice.call(e);var t=Kp(e);delete t[Wp];for(var n=qp(t),r=0;r<n.length;r++){var o=n[r],i=t[o];!1===i.writable&&(i.writable=!0,i.configurable=!0),(i.get||i.set)&&(t[o]={configurable:!0,writable:!0,enumerable:i.enumerable,value:e[o]})}return Object.create(Object.getPrototypeOf(e),t)}function vp(e,t){return void 0===t&&(t=!1),yp(e)||ap(e)||!sp(e)||(lp(e)>1&&(e.set=e.add=e.clear=e.delete=mp),Object.freeze(e),t&&up(e,function(e,t){return vp(t,!0)},!0)),e}function mp(){ip(2)}function yp(e){return null==e||"object"!=typeof e||Object.isFrozen(e)}function bp(e){var t=Yp[e];return t||ip(18,e),t}function Ep(){return Mp}function Cp(e,t){t&&(bp("Patches"),e.u=[],e.s=[],e.v=t)}function Dp(e){wp(e),e.p.forEach(Ap),e.p=null}function wp(e){e===Mp&&(Mp=e.l)}function Sp(e){return Mp={p:[],l:Mp,h:e,m:!0,_:0}}function Ap(e){var t=e[Wp];0===t.i||1===t.i?t.j():t.g=!0}function xp(e,t){t._=t.p.length;var n=t.p[0],r=void 0!==e&&e!==n;return t.h.O||bp("ES5").S(t,e,r),r?(n[Wp].P&&(Dp(t),ip(4)),sp(e)&&(e=Op(t,e),t.l||Bp(t,e)),t.u&&bp("Patches").M(n[Wp].t,e,t.u,t.s)):e=Op(t,n,[]),Dp(t),t.u&&t.v(t.u,t.s),e!==Up?e:void 0}function Op(e,t,n){if(yp(t))return t;var r=t[Wp];if(!r)return up(t,function(o,i){return Np(e,r,t,o,i,n)},!0),t;if(r.A!==e)return t;if(!r.P)return Bp(e,r.t,!0),r.t;if(!r.I){r.I=!0,r.A._--;var o=4===r.i||5===r.i?r.o=gp(r.k):r.o,i=o,a=!1;3===r.i&&(i=new Set(o),o.clear(),a=!0),up(i,function(t,i){return Np(e,r,o,t,i,n,a)}),Bp(e,o,!1),n&&e.u&&bp("Patches").N(r,n,e.u,e.s)}return r.o}function Np(e,t,n,r,o,i,a){if(ap(o)){var s=Op(e,o,i&&t&&3!==t.i&&!cp(t.R,r)?i.concat(r):void 0);if(dp(n,r,s),!ap(s))return;e.m=!1}else a&&n.add(o);if(sp(o)&&!yp(o)){if(!e.h.D&&e._<1)return;Op(e,o),t&&t.A.l||Bp(e,o)}}function Bp(e,t,n){void 0===n&&(n=!1),!e.l&&e.h.D&&e.m&&vp(t,n)}function Tp(e,t){var n=e[Wp];return(n?hp(n):e)[t]}function kp(e,t){if(t in e)for(var n=Object.getPrototypeOf(e);n;){var r=Object.getOwnPropertyDescriptor(n,t);if(r)return r;n=Object.getPrototypeOf(n)}}function Fp(e){e.P||(e.P=!0,e.l&&Fp(e.l))}function Ip(e){e.o||(e.o=gp(e.t))}function Pp(e,t,n){var r=fp(t)?bp("MapSet").F(t,n):pp(t)?bp("MapSet").T(t,n):e.O?function(e,t){var n=Array.isArray(e),r={i:n?1:0,A:t?t.A:Ep(),P:!1,I:!1,R:{},l:t,t:e,k:null,o:null,j:null,C:!1},o=r,i=Xp;n&&(o=[r],i=Zp);var a=Proxy.revocable(o,i),s=a.revoke,u=a.proxy;return r.k=u,r.j=s,u}(t,n):bp("ES5").J(t,n);return(n?n.A:Ep()).p.push(r),r}function _p(e){return ap(e)||ip(22,e),function e(t){if(!sp(t))return t;var n,r=t[Wp],o=lp(t);if(r){if(!r.P&&(r.i<4||!bp("ES5").K(r)))return r.t;r.I=!0,n=Lp(t,o),r.I=!1}else n=Lp(t,o);return up(n,function(t,o){r&&function(e,t){return 2===lp(e)?e.get(t):e[t]}(r.t,t)===o||dp(n,t,e(o))}),3===o?new Set(n):n}(e)}function Lp(e,t){switch(t){case 2:return new Map(e);case 3:return Array.from(e)}return gp(e)}var Rp,Mp,jp="undefined"!=typeof Symbol&&"symbol"==typeof Symbol("x"),Hp="undefined"!=typeof Map,zp="undefined"!=typeof Set,$p="undefined"!=typeof Proxy&&void 0!==Proxy.revocable&&"undefined"!=typeof Reflect,Up=jp?Symbol.for("immer-nothing"):((Rp={})["immer-nothing"]=!0,Rp),Vp=jp?Symbol.for("immer-draftable"):"__$immer_draftable",Wp=jp?Symbol.for("immer-state"):"__$immer_state",Gp=""+Object.prototype.constructor,qp="undefined"!=typeof Reflect&&Reflect.ownKeys?Reflect.ownKeys:void 0!==Object.getOwnPropertySymbols?function(e){return Object.getOwnPropertyNames(e).concat(Object.getOwnPropertySymbols(e))}:Object.getOwnPropertyNames,Kp=Object.getOwnPropertyDescriptors||function(e){var t={};return qp(e).forEach(function(n){t[n]=Object.getOwnPropertyDescriptor(e,n)}),t},Yp={},Xp={get:function(e,t){if(t===Wp)return e;var n=hp(e);if(!cp(n,t))return function(e,t,n){var r,o=kp(t,n);return o?"value"in o?o.value:null===(r=o.get)||void 0===r?void 0:r.call(e.k):void 0}(e,n,t);var r=n[t];return e.I||!sp(r)?r:r===Tp(e.t,t)?(Ip(e),e.o[t]=Pp(e.A.h,r,e)):r},has:function(e,t){return t in hp(e)},ownKeys:function(e){return Reflect.ownKeys(hp(e))},set:function(e,t,n){var r=kp(hp(e),t);if(null==r?void 0:r.set)return r.set.call(e.k,n),!0;if(!e.P){var o=Tp(hp(e),t),i=null==o?void 0:o[Wp];if(i&&i.t===n)return e.o[t]=n,e.R[t]=!1,!0;if(function(e,t){return e===t?0!==e||1/e==1/t:e!=e&&t!=t}(n,o)&&(void 0!==n||cp(e.t,t)))return!0;Ip(e),Fp(e)}return e.o[t]===n&&(void 0!==n||t in e.o)||Number.isNaN(n)&&Number.isNaN(e.o[t])||(e.o[t]=n,e.R[t]=!0),!0},deleteProperty:function(e,t){return void 0!==Tp(e.t,t)||t in e.t?(e.R[t]=!1,Ip(e),Fp(e)):delete e.R[t],e.o&&delete e.o[t],!0},getOwnPropertyDescriptor:function(e,t){var n=hp(e),r=Reflect.getOwnPropertyDescriptor(n,t);return r?{writable:!0,configurable:1!==e.i||"length"!==t,enumerable:r.enumerable,value:n[t]}:r},defineProperty:function(){ip(11)},getPrototypeOf:function(e){return Object.getPrototypeOf(e.t)},setPrototypeOf:function(){ip(12)}},Zp={};up(Xp,function(e,t){Zp[e]=function(){return arguments[0]=arguments[0][0],t.apply(this,arguments)}}),Zp.deleteProperty=function(e,t){return Zp.set.call(this,e,t,void 0)},Zp.set=function(e,t,n){return Xp.set.call(this,e[0],t,n,e[0])};var Jp=function(){function e(e){var t=this;this.O=$p,this.D=!0,this.produce=function(e,n,r){if("function"==typeof e&&"function"!=typeof n){var o=n;n=e;var i=t;return function(e){var t=this;void 0===e&&(e=o);for(var r=arguments.length,a=Array(r>1?r-1:0),s=1;s<r;s++)a[s-1]=arguments[s];return i.produce(e,function(e){var r;return(r=n).call.apply(r,[t,e].concat(a))})}}var a;if("function"!=typeof n&&ip(6),void 0!==r&&"function"!=typeof r&&ip(7),sp(e)){var s=Sp(t),u=Pp(t,e,void 0),l=!0;try{a=n(u),l=!1}finally{l?Dp(s):wp(s)}return"undefined"!=typeof Promise&&a instanceof Promise?a.then(function(e){return Cp(s,r),xp(e,s)},function(e){throw Dp(s),e}):(Cp(s,r),xp(a,s))}if(!e||"object"!=typeof e){if(void 0===(a=n(e))&&(a=e),a===Up&&(a=void 0),t.D&&vp(a,!0),r){var c=[],d=[];bp("Patches").M(e,a,c,d),r(c,d)}return a}ip(21,e)},this.produceWithPatches=function(e,n){if("function"==typeof e)return function(n){for(var r=arguments.length,o=Array(r>1?r-1:0),i=1;i<r;i++)o[i-1]=arguments[i];return t.produceWithPatches(n,function(t){return e.apply(void 0,[t].concat(o))})};var r,o,i=t.produce(e,n,function(e,t){r=e,o=t});return"undefined"!=typeof Promise&&i instanceof Promise?i.then(function(e){return[e,r,o]}):[i,r,o]},"boolean"==typeof(null==e?void 0:e.useProxies)&&this.setUseProxies(e.useProxies),"boolean"==typeof(null==e?void 0:e.autoFreeze)&&this.setAutoFreeze(e.autoFreeze)}var t=e.prototype;return t.createDraft=function(e){sp(e)||ip(8),ap(e)&&(e=_p(e));var t=Sp(this),n=Pp(this,e,void 0);return n[Wp].C=!0,wp(t),n},t.finishDraft=function(e,t){var n=(e&&e[Wp]).A;return Cp(n,t),xp(void 0,n)},t.setAutoFreeze=function(e){this.D=e},t.setUseProxies=function(e){e&&!$p&&ip(20),this.O=e},t.applyPatches=function(e,t){var n;for(n=t.length-1;n>=0;n--){var r=t[n];if(0===r.path.length&&"replace"===r.op){e=r.value;break}}n>-1&&(t=t.slice(n+1));var o=bp("Patches").$;return ap(e)?o(e,t):this.produce(e,function(e){return o(e,t)})},e}(),Qp=new Jp,eh=Qp.produce;Qp.produceWithPatches.bind(Qp),Qp.setAutoFreeze.bind(Qp),Qp.setUseProxies.bind(Qp),Qp.applyPatches.bind(Qp);var th=Qp.createDraft.bind(Qp),nh=Qp.finishDraft.bind(Qp);function rh(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var oh=new WeakMap,ih=new WeakMap,ah=new WeakMap,sh=new WeakMap,uh=new WeakMap,lh=new WeakMap,ch=new WeakMap;function dh(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function fh(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?dh(Object(n),!0).forEach(function(t){rh(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):dh(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}function ph(e,t){if(null==e)return{};var n,r,o=function(e,t){if(null==e)return{};var n,r,o={},i=Object.keys(e);for(r=0;r<i.length;r++)n=i[r],t.indexOf(n)>=0||(o[n]=e[n]);return o}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(r=0;r<i.length;r++)n=i[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}var hh,gh=function(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1],n=!t,r=t?Ch(e):e,o=hh.None,i=hh.None,a=0,s=null;for(var u of r){var l=u.codePointAt(0);if(!l)break;var c=Ih(u,l);if([o,i]=n?[i,c]:[c,o],Ph(o,hh.ZWJ)&&Ph(i,hh.ExtPict)&&!Mh(n?e.substring(0,a):e.substring(0,e.length-a)))break;if(Ph(o,hh.RI)&&Ph(i,hh.RI)&&!(s=null!==s?!s:!!n||Hh(e.substring(0,e.length-a))))break;if(o!==hh.None&&i!==hh.None&&Lh(o,i))break;a+=u.length}return a||1},vh=/\s/,mh=/[\u0021-\u0023\u0025-\u002A\u002C-\u002F\u003A\u003B\u003F\u0040\u005B-\u005D\u005F\u007B\u007D\u00A1\u00A7\u00AB\u00B6\u00B7\u00BB\u00BF\u037E\u0387\u055A-\u055F\u0589\u058A\u05BE\u05C0\u05C3\u05C6\u05F3\u05F4\u0609\u060A\u060C\u060D\u061B\u061E\u061F\u066A-\u066D\u06D4\u0700-\u070D\u07F7-\u07F9\u0830-\u083E\u085E\u0964\u0965\u0970\u0AF0\u0DF4\u0E4F\u0E5A\u0E5B\u0F04-\u0F12\u0F14\u0F3A-\u0F3D\u0F85\u0FD0-\u0FD4\u0FD9\u0FDA\u104A-\u104F\u10FB\u1360-\u1368\u1400\u166D\u166E\u169B\u169C\u16EB-\u16ED\u1735\u1736\u17D4-\u17D6\u17D8-\u17DA\u1800-\u180A\u1944\u1945\u1A1E\u1A1F\u1AA0-\u1AA6\u1AA8-\u1AAD\u1B5A-\u1B60\u1BFC-\u1BFF\u1C3B-\u1C3F\u1C7E\u1C7F\u1CC0-\u1CC7\u1CD3\u2010-\u2027\u2030-\u2043\u2045-\u2051\u2053-\u205E\u207D\u207E\u208D\u208E\u2329\u232A\u2768-\u2775\u27C5\u27C6\u27E6-\u27EF\u2983-\u2998\u29D8-\u29DB\u29FC\u29FD\u2CF9-\u2CFC\u2CFE\u2CFF\u2D70\u2E00-\u2E2E\u2E30-\u2E3B\u3001-\u3003\u3008-\u3011\u3014-\u301F\u3030\u303D\u30A0\u30FB\uA4FE\uA4FF\uA60D-\uA60F\uA673\uA67E\uA6F2-\uA6F7\uA874-\uA877\uA8CE\uA8CF\uA8F8-\uA8FA\uA92E\uA92F\uA95F\uA9C1-\uA9CD\uA9DE\uA9DF\uAA5C-\uAA5F\uAADE\uAADF\uAAF0\uAAF1\uABEB\uFD3E\uFD3F\uFE10-\uFE19\uFE30-\uFE52\uFE54-\uFE61\uFE63\uFE68\uFE6A\uFE6B\uFF01-\uFF03\uFF05-\uFF0A\uFF0C-\uFF0F\uFF1A\uFF1B\uFF1F\uFF20\uFF3B-\uFF3D\uFF3F\uFF5B\uFF5D\uFF5F-\uFF65]/,yh=/['\u2018\u2019]/,bh=(e,t,n)=>{if(n){var r=e.length-t;return[e.slice(r,e.length),e.slice(0,r)]}return[e.slice(0,t),e.slice(t)]},Eh=function e(t,n){var r=arguments.length>2&&void 0!==arguments[2]&&arguments[2];if(vh.test(t))return!1;if(yh.test(t)){var o=gh(n,r),[i,a]=bh(n,o,r);if(e(i,a,r))return!0}return!mh.test(t)},Ch=function*(e){for(var t=e.length-1,n=0;n<e.length;n++){var r=e.charAt(t-n);if(wh(r.charCodeAt(0))){var o=e.charAt(t-n-1);if(Dh(o.charCodeAt(0))){yield o+r,n++;continue}}yield r}},Dh=e=>e>=55296&&e<=56319,wh=e=>e>=56320&&e<=57343;!function(e){e[e.None=0]="None",e[e.Extend=1]="Extend",e[e.ZWJ=2]="ZWJ",e[e.RI=4]="RI",e[e.Prepend=8]="Prepend",e[e.SpacingMark=16]="SpacingMark",e[e.L=32]="L",e[e.V=64]="V",e[e.T=128]="T",e[e.LV=256]="LV",e[e.LVT=512]="LVT",e[e.ExtPict=1024]="ExtPict",e[e.Any=2048]="Any"}(hh||(hh={}));var Sh=/^(?:[\u0300-\u036F\u0483-\u0489\u0591-\u05BD\u05BF\u05C1\u05C2\u05C4\u05C5\u05C7\u0610-\u061A\u064B-\u065F\u0670\u06D6-\u06DC\u06DF-\u06E4\u06E7\u06E8\u06EA-\u06ED\u0711\u0730-\u074A\u07A6-\u07B0\u07EB-\u07F3\u07FD\u0816-\u0819\u081B-\u0823\u0825-\u0827\u0829-\u082D\u0859-\u085B\u08D3-\u08E1\u08E3-\u0902\u093A\u093C\u0941-\u0948\u094D\u0951-\u0957\u0962\u0963\u0981\u09BC\u09BE\u09C1-\u09C4\u09CD\u09D7\u09E2\u09E3\u09FE\u0A01\u0A02\u0A3C\u0A41\u0A42\u0A47\u0A48\u0A4B-\u0A4D\u0A51\u0A70\u0A71\u0A75\u0A81\u0A82\u0ABC\u0AC1-\u0AC5\u0AC7\u0AC8\u0ACD\u0AE2\u0AE3\u0AFA-\u0AFF\u0B01\u0B3C\u0B3E\u0B3F\u0B41-\u0B44\u0B4D\u0B55-\u0B57\u0B62\u0B63\u0B82\u0BBE\u0BC0\u0BCD\u0BD7\u0C00\u0C04\u0C3E-\u0C40\u0C46-\u0C48\u0C4A-\u0C4D\u0C55\u0C56\u0C62\u0C63\u0C81\u0CBC\u0CBF\u0CC2\u0CC6\u0CCC\u0CCD\u0CD5\u0CD6\u0CE2\u0CE3\u0D00\u0D01\u0D3B\u0D3C\u0D3E\u0D41-\u0D44\u0D4D\u0D57\u0D62\u0D63\u0D81\u0DCA\u0DCF\u0DD2-\u0DD4\u0DD6\u0DDF\u0E31\u0E34-\u0E3A\u0E47-\u0E4E\u0EB1\u0EB4-\u0EBC\u0EC8-\u0ECD\u0F18\u0F19\u0F35\u0F37\u0F39\u0F71-\u0F7E\u0F80-\u0F84\u0F86\u0F87\u0F8D-\u0F97\u0F99-\u0FBC\u0FC6\u102D-\u1030\u1032-\u1037\u1039\u103A\u103D\u103E\u1058\u1059\u105E-\u1060\u1071-\u1074\u1082\u1085\u1086\u108D\u109D\u135D-\u135F\u1712-\u1714\u1732-\u1734\u1752\u1753\u1772\u1773\u17B4\u17B5\u17B7-\u17BD\u17C6\u17C9-\u17D3\u17DD\u180B-\u180D\u1885\u1886\u18A9\u1920-\u1922\u1927\u1928\u1932\u1939-\u193B\u1A17\u1A18\u1A1B\u1A56\u1A58-\u1A5E\u1A60\u1A62\u1A65-\u1A6C\u1A73-\u1A7C\u1A7F\u1AB0-\u1AC0\u1B00-\u1B03\u1B34-\u1B3A\u1B3C\u1B42\u1B6B-\u1B73\u1B80\u1B81\u1BA2-\u1BA5\u1BA8\u1BA9\u1BAB-\u1BAD\u1BE6\u1BE8\u1BE9\u1BED\u1BEF-\u1BF1\u1C2C-\u1C33\u1C36\u1C37\u1CD0-\u1CD2\u1CD4-\u1CE0\u1CE2-\u1CE8\u1CED\u1CF4\u1CF8\u1CF9\u1DC0-\u1DF9\u1DFB-\u1DFF\u200C\u20D0-\u20F0\u2CEF-\u2CF1\u2D7F\u2DE0-\u2DFF\u302A-\u302F\u3099\u309A\uA66F-\uA672\uA674-\uA67D\uA69E\uA69F\uA6F0\uA6F1\uA802\uA806\uA80B\uA825\uA826\uA82C\uA8C4\uA8C5\uA8E0-\uA8F1\uA8FF\uA926-\uA92D\uA947-\uA951\uA980-\uA982\uA9B3\uA9B6-\uA9B9\uA9BC\uA9BD\uA9E5\uAA29-\uAA2E\uAA31\uAA32\uAA35\uAA36\uAA43\uAA4C\uAA7C\uAAB0\uAAB2-\uAAB4\uAAB7\uAAB8\uAABE\uAABF\uAAC1\uAAEC\uAAED\uAAF6\uABE5\uABE8\uABED\uFB1E\uFE00-\uFE0F\uFE20-\uFE2F\uFF9E\uFF9F]|\uD800[\uDDFD\uDEE0\uDF76-\uDF7A]|\uD802[\uDE01-\uDE03\uDE05\uDE06\uDE0C-\uDE0F\uDE38-\uDE3A\uDE3F\uDEE5\uDEE6]|\uD803[\uDD24-\uDD27\uDEAB\uDEAC\uDF46-\uDF50]|\uD804[\uDC01\uDC38-\uDC46\uDC7F-\uDC81\uDCB3-\uDCB6\uDCB9\uDCBA\uDD00-\uDD02\uDD27-\uDD2B\uDD2D-\uDD34\uDD73\uDD80\uDD81\uDDB6-\uDDBE\uDDC9-\uDDCC\uDDCF\uDE2F-\uDE31\uDE34\uDE36\uDE37\uDE3E\uDEDF\uDEE3-\uDEEA\uDF00\uDF01\uDF3B\uDF3C\uDF3E\uDF40\uDF57\uDF66-\uDF6C\uDF70-\uDF74]|\uD805[\uDC38-\uDC3F\uDC42-\uDC44\uDC46\uDC5E\uDCB0\uDCB3-\uDCB8\uDCBA\uDCBD\uDCBF\uDCC0\uDCC2\uDCC3\uDDAF\uDDB2-\uDDB5\uDDBC\uDDBD\uDDBF\uDDC0\uDDDC\uDDDD\uDE33-\uDE3A\uDE3D\uDE3F\uDE40\uDEAB\uDEAD\uDEB0-\uDEB5\uDEB7\uDF1D-\uDF1F\uDF22-\uDF25\uDF27-\uDF2B]|\uD806[\uDC2F-\uDC37\uDC39\uDC3A\uDD30\uDD3B\uDD3C\uDD3E\uDD43\uDDD4-\uDDD7\uDDDA\uDDDB\uDDE0\uDE01-\uDE0A\uDE33-\uDE38\uDE3B-\uDE3E\uDE47\uDE51-\uDE56\uDE59-\uDE5B\uDE8A-\uDE96\uDE98\uDE99]|\uD807[\uDC30-\uDC36\uDC38-\uDC3D\uDC3F\uDC92-\uDCA7\uDCAA-\uDCB0\uDCB2\uDCB3\uDCB5\uDCB6\uDD31-\uDD36\uDD3A\uDD3C\uDD3D\uDD3F-\uDD45\uDD47\uDD90\uDD91\uDD95\uDD97\uDEF3\uDEF4]|\uD81A[\uDEF0-\uDEF4\uDF30-\uDF36]|\uD81B[\uDF4F\uDF8F-\uDF92\uDFE4]|\uD82F[\uDC9D\uDC9E]|\uD834[\uDD65\uDD67-\uDD69\uDD6E-\uDD72\uDD7B-\uDD82\uDD85-\uDD8B\uDDAA-\uDDAD\uDE42-\uDE44]|\uD836[\uDE00-\uDE36\uDE3B-\uDE6C\uDE75\uDE84\uDE9B-\uDE9F\uDEA1-\uDEAF]|\uD838[\uDC00-\uDC06\uDC08-\uDC18\uDC1B-\uDC21\uDC23\uDC24\uDC26-\uDC2A\uDD30-\uDD36\uDEEC-\uDEEF]|\uD83A[\uDCD0-\uDCD6\uDD44-\uDD4A]|\uD83C[\uDFFB-\uDFFF]|\uDB40[\uDC20-\uDC7F\uDD00-\uDDEF])$/,Ah=/^(?:[\u0600-\u0605\u06DD\u070F\u0890\u0891\u08E2\u0D4E]|\uD804[\uDCBD\uDCCD\uDDC2\uDDC3]|\uD806[\uDD3F\uDD41\uDE3A\uDE84-\uDE89]|\uD807\uDD46)$/,xh=/^(?:[\u0903\u093B\u093E-\u0940\u0949-\u094C\u094E\u094F\u0982\u0983\u09BF\u09C0\u09C7\u09C8\u09CB\u09CC\u0A03\u0A3E-\u0A40\u0A83\u0ABE-\u0AC0\u0AC9\u0ACB\u0ACC\u0B02\u0B03\u0B40\u0B47\u0B48\u0B4B\u0B4C\u0BBF\u0BC1\u0BC2\u0BC6-\u0BC8\u0BCA-\u0BCC\u0C01-\u0C03\u0C41-\u0C44\u0C82\u0C83\u0CBE\u0CC0\u0CC1\u0CC3\u0CC4\u0CC7\u0CC8\u0CCA\u0CCB\u0D02\u0D03\u0D3F\u0D40\u0D46-\u0D48\u0D4A-\u0D4C\u0D82\u0D83\u0DD0\u0DD1\u0DD8-\u0DDE\u0DF2\u0DF3\u0E33\u0EB3\u0F3E\u0F3F\u0F7F\u1031\u103B\u103C\u1056\u1057\u1084\u1715\u1734\u17B6\u17BE-\u17C5\u17C7\u17C8\u1923-\u1926\u1929-\u192B\u1930\u1931\u1933-\u1938\u1A19\u1A1A\u1A55\u1A57\u1A6D-\u1A72\u1B04\u1B3B\u1B3D-\u1B41\u1B43\u1B44\u1B82\u1BA1\u1BA6\u1BA7\u1BAA\u1BE7\u1BEA-\u1BEC\u1BEE\u1BF2\u1BF3\u1C24-\u1C2B\u1C34\u1C35\u1CE1\u1CF7\uA823\uA824\uA827\uA880\uA881\uA8B4-\uA8C3\uA952\uA953\uA983\uA9B4\uA9B5\uA9BA\uA9BB\uA9BE-\uA9C0\uAA2F\uAA30\uAA33\uAA34\uAA4D\uAAEB\uAAEE\uAAEF\uAAF5\uABE3\uABE4\uABE6\uABE7\uABE9\uABEA\uABEC]|\uD804[\uDC00\uDC02\uDC82\uDCB0-\uDCB2\uDCB7\uDCB8\uDD2C\uDD45\uDD46\uDD82\uDDB3-\uDDB5\uDDBF\uDDC0\uDDCE\uDE2C-\uDE2E\uDE32\uDE33\uDE35\uDEE0-\uDEE2\uDF02\uDF03\uDF3F\uDF41-\uDF44\uDF47\uDF48\uDF4B-\uDF4D\uDF62\uDF63]|\uD805[\uDC35-\uDC37\uDC40\uDC41\uDC45\uDCB1\uDCB2\uDCB9\uDCBB\uDCBC\uDCBE\uDCC1\uDDB0\uDDB1\uDDB8-\uDDBB\uDDBE\uDE30-\uDE32\uDE3B\uDE3C\uDE3E\uDEAC\uDEAE\uDEAF\uDEB6\uDF26]|\uD806[\uDC2C-\uDC2E\uDC38\uDD31-\uDD35\uDD37\uDD38\uDD3D\uDD40\uDD42\uDDD1-\uDDD3\uDDDC-\uDDDF\uDDE4\uDE39\uDE57\uDE58\uDE97]|\uD807[\uDC2F\uDC3E\uDCA9\uDCB1\uDCB4\uDD8A-\uDD8E\uDD93\uDD94\uDD96\uDEF5\uDEF6]|\uD81B[\uDF51-\uDF87\uDFF0\uDFF1]|\uD834[\uDD66\uDD6D])$/,Oh=/^[\u1100-\u115F\uA960-\uA97C]$/,Nh=/^[\u1160-\u11A7\uD7B0-\uD7C6]$/,Bh=/^[\u11A8-\u11FF\uD7CB-\uD7FB]$/,Th=/^[\uAC00\uAC1C\uAC38\uAC54\uAC70\uAC8C\uACA8\uACC4\uACE0\uACFC\uAD18\uAD34\uAD50\uAD6C\uAD88\uADA4\uADC0\uADDC\uADF8\uAE14\uAE30\uAE4C\uAE68\uAE84\uAEA0\uAEBC\uAED8\uAEF4\uAF10\uAF2C\uAF48\uAF64\uAF80\uAF9C\uAFB8\uAFD4\uAFF0\uB00C\uB028\uB044\uB060\uB07C\uB098\uB0B4\uB0D0\uB0EC\uB108\uB124\uB140\uB15C\uB178\uB194\uB1B0\uB1CC\uB1E8\uB204\uB220\uB23C\uB258\uB274\uB290\uB2AC\uB2C8\uB2E4\uB300\uB31C\uB338\uB354\uB370\uB38C\uB3A8\uB3C4\uB3E0\uB3FC\uB418\uB434\uB450\uB46C\uB488\uB4A4\uB4C0\uB4DC\uB4F8\uB514\uB530\uB54C\uB568\uB584\uB5A0\uB5BC\uB5D8\uB5F4\uB610\uB62C\uB648\uB664\uB680\uB69C\uB6B8\uB6D4\uB6F0\uB70C\uB728\uB744\uB760\uB77C\uB798\uB7B4\uB7D0\uB7EC\uB808\uB824\uB840\uB85C\uB878\uB894\uB8B0\uB8CC\uB8E8\uB904\uB920\uB93C\uB958\uB974\uB990\uB9AC\uB9C8\uB9E4\uBA00\uBA1C\uBA38\uBA54\uBA70\uBA8C\uBAA8\uBAC4\uBAE0\uBAFC\uBB18\uBB34\uBB50\uBB6C\uBB88\uBBA4\uBBC0\uBBDC\uBBF8\uBC14\uBC30\uBC4C\uBC68\uBC84\uBCA0\uBCBC\uBCD8\uBCF4\uBD10\uBD2C\uBD48\uBD64\uBD80\uBD9C\uBDB8\uBDD4\uBDF0\uBE0C\uBE28\uBE44\uBE60\uBE7C\uBE98\uBEB4\uBED0\uBEEC\uBF08\uBF24\uBF40\uBF5C\uBF78\uBF94\uBFB0\uBFCC\uBFE8\uC004\uC020\uC03C\uC058\uC074\uC090\uC0AC\uC0C8\uC0E4\uC100\uC11C\uC138\uC154\uC170\uC18C\uC1A8\uC1C4\uC1E0\uC1FC\uC218\uC234\uC250\uC26C\uC288\uC2A4\uC2C0\uC2DC\uC2F8\uC314\uC330\uC34C\uC368\uC384\uC3A0\uC3BC\uC3D8\uC3F4\uC410\uC42C\uC448\uC464\uC480\uC49C\uC4B8\uC4D4\uC4F0\uC50C\uC528\uC544\uC560\uC57C\uC598\uC5B4\uC5D0\uC5EC\uC608\uC624\uC640\uC65C\uC678\uC694\uC6B0\uC6CC\uC6E8\uC704\uC720\uC73C\uC758\uC774\uC790\uC7AC\uC7C8\uC7E4\uC800\uC81C\uC838\uC854\uC870\uC88C\uC8A8\uC8C4\uC8E0\uC8FC\uC918\uC934\uC950\uC96C\uC988\uC9A4\uC9C0\uC9DC\uC9F8\uCA14\uCA30\uCA4C\uCA68\uCA84\uCAA0\uCABC\uCAD8\uCAF4\uCB10\uCB2C\uCB48\uCB64\uCB80\uCB9C\uCBB8\uCBD4\uCBF0\uCC0C\uCC28\uCC44\uCC60\uCC7C\uCC98\uCCB4\uCCD0\uCCEC\uCD08\uCD24\uCD40\uCD5C\uCD78\uCD94\uCDB0\uCDCC\uCDE8\uCE04\uCE20\uCE3C\uCE58\uCE74\uCE90\uCEAC\uCEC8\uCEE4\uCF00\uCF1C\uCF38\uCF54\uCF70\uCF8C\uCFA8\uCFC4\uCFE0\uCFFC\uD018\uD034\uD050\uD06C\uD088\uD0A4\uD0C0\uD0DC\uD0F8\uD114\uD130\uD14C\uD168\uD184\uD1A0\uD1BC\uD1D8\uD1F4\uD210\uD22C\uD248\uD264\uD280\uD29C\uD2B8\uD2D4\uD2F0\uD30C\uD328\uD344\uD360\uD37C\uD398\uD3B4\uD3D0\uD3EC\uD408\uD424\uD440\uD45C\uD478\uD494\uD4B0\uD4CC\uD4E8\uD504\uD520\uD53C\uD558\uD574\uD590\uD5AC\uD5C8\uD5E4\uD600\uD61C\uD638\uD654\uD670\uD68C\uD6A8\uD6C4\uD6E0\uD6FC\uD718\uD734\uD750\uD76C\uD788]$/,kh=/^[\uAC01-\uAC1B\uAC1D-\uAC37\uAC39-\uAC53\uAC55-\uAC6F\uAC71-\uAC8B\uAC8D-\uACA7\uACA9-\uACC3\uACC5-\uACDF\uACE1-\uACFB\uACFD-\uAD17\uAD19-\uAD33\uAD35-\uAD4F\uAD51-\uAD6B\uAD6D-\uAD87\uAD89-\uADA3\uADA5-\uADBF\uADC1-\uADDB\uADDD-\uADF7\uADF9-\uAE13\uAE15-\uAE2F\uAE31-\uAE4B\uAE4D-\uAE67\uAE69-\uAE83\uAE85-\uAE9F\uAEA1-\uAEBB\uAEBD-\uAED7\uAED9-\uAEF3\uAEF5-\uAF0F\uAF11-\uAF2B\uAF2D-\uAF47\uAF49-\uAF63\uAF65-\uAF7F\uAF81-\uAF9B\uAF9D-\uAFB7\uAFB9-\uAFD3\uAFD5-\uAFEF\uAFF1-\uB00B\uB00D-\uB027\uB029-\uB043\uB045-\uB05F\uB061-\uB07B\uB07D-\uB097\uB099-\uB0B3\uB0B5-\uB0CF\uB0D1-\uB0EB\uB0ED-\uB107\uB109-\uB123\uB125-\uB13F\uB141-\uB15B\uB15D-\uB177\uB179-\uB193\uB195-\uB1AF\uB1B1-\uB1CB\uB1CD-\uB1E7\uB1E9-\uB203\uB205-\uB21F\uB221-\uB23B\uB23D-\uB257\uB259-\uB273\uB275-\uB28F\uB291-\uB2AB\uB2AD-\uB2C7\uB2C9-\uB2E3\uB2E5-\uB2FF\uB301-\uB31B\uB31D-\uB337\uB339-\uB353\uB355-\uB36F\uB371-\uB38B\uB38D-\uB3A7\uB3A9-\uB3C3\uB3C5-\uB3DF\uB3E1-\uB3FB\uB3FD-\uB417\uB419-\uB433\uB435-\uB44F\uB451-\uB46B\uB46D-\uB487\uB489-\uB4A3\uB4A5-\uB4BF\uB4C1-\uB4DB\uB4DD-\uB4F7\uB4F9-\uB513\uB515-\uB52F\uB531-\uB54B\uB54D-\uB567\uB569-\uB583\uB585-\uB59F\uB5A1-\uB5BB\uB5BD-\uB5D7\uB5D9-\uB5F3\uB5F5-\uB60F\uB611-\uB62B\uB62D-\uB647\uB649-\uB663\uB665-\uB67F\uB681-\uB69B\uB69D-\uB6B7\uB6B9-\uB6D3\uB6D5-\uB6EF\uB6F1-\uB70B\uB70D-\uB727\uB729-\uB743\uB745-\uB75F\uB761-\uB77B\uB77D-\uB797\uB799-\uB7B3\uB7B5-\uB7CF\uB7D1-\uB7EB\uB7ED-\uB807\uB809-\uB823\uB825-\uB83F\uB841-\uB85B\uB85D-\uB877\uB879-\uB893\uB895-\uB8AF\uB8B1-\uB8CB\uB8CD-\uB8E7\uB8E9-\uB903\uB905-\uB91F\uB921-\uB93B\uB93D-\uB957\uB959-\uB973\uB975-\uB98F\uB991-\uB9AB\uB9AD-\uB9C7\uB9C9-\uB9E3\uB9E5-\uB9FF\uBA01-\uBA1B\uBA1D-\uBA37\uBA39-\uBA53\uBA55-\uBA6F\uBA71-\uBA8B\uBA8D-\uBAA7\uBAA9-\uBAC3\uBAC5-\uBADF\uBAE1-\uBAFB\uBAFD-\uBB17\uBB19-\uBB33\uBB35-\uBB4F\uBB51-\uBB6B\uBB6D-\uBB87\uBB89-\uBBA3\uBBA5-\uBBBF\uBBC1-\uBBDB\uBBDD-\uBBF7\uBBF9-\uBC13\uBC15-\uBC2F\uBC31-\uBC4B\uBC4D-\uBC67\uBC69-\uBC83\uBC85-\uBC9F\uBCA1-\uBCBB\uBCBD-\uBCD7\uBCD9-\uBCF3\uBCF5-\uBD0F\uBD11-\uBD2B\uBD2D-\uBD47\uBD49-\uBD63\uBD65-\uBD7F\uBD81-\uBD9B\uBD9D-\uBDB7\uBDB9-\uBDD3\uBDD5-\uBDEF\uBDF1-\uBE0B\uBE0D-\uBE27\uBE29-\uBE43\uBE45-\uBE5F\uBE61-\uBE7B\uBE7D-\uBE97\uBE99-\uBEB3\uBEB5-\uBECF\uBED1-\uBEEB\uBEED-\uBF07\uBF09-\uBF23\uBF25-\uBF3F\uBF41-\uBF5B\uBF5D-\uBF77\uBF79-\uBF93\uBF95-\uBFAF\uBFB1-\uBFCB\uBFCD-\uBFE7\uBFE9-\uC003\uC005-\uC01F\uC021-\uC03B\uC03D-\uC057\uC059-\uC073\uC075-\uC08F\uC091-\uC0AB\uC0AD-\uC0C7\uC0C9-\uC0E3\uC0E5-\uC0FF\uC101-\uC11B\uC11D-\uC137\uC139-\uC153\uC155-\uC16F\uC171-\uC18B\uC18D-\uC1A7\uC1A9-\uC1C3\uC1C5-\uC1DF\uC1E1-\uC1FB\uC1FD-\uC217\uC219-\uC233\uC235-\uC24F\uC251-\uC26B\uC26D-\uC287\uC289-\uC2A3\uC2A5-\uC2BF\uC2C1-\uC2DB\uC2DD-\uC2F7\uC2F9-\uC313\uC315-\uC32F\uC331-\uC34B\uC34D-\uC367\uC369-\uC383\uC385-\uC39F\uC3A1-\uC3BB\uC3BD-\uC3D7\uC3D9-\uC3F3\uC3F5-\uC40F\uC411-\uC42B\uC42D-\uC447\uC449-\uC463\uC465-\uC47F\uC481-\uC49B\uC49D-\uC4B7\uC4B9-\uC4D3\uC4D5-\uC4EF\uC4F1-\uC50B\uC50D-\uC527\uC529-\uC543\uC545-\uC55F\uC561-\uC57B\uC57D-\uC597\uC599-\uC5B3\uC5B5-\uC5CF\uC5D1-\uC5EB\uC5ED-\uC607\uC609-\uC623\uC625-\uC63F\uC641-\uC65B\uC65D-\uC677\uC679-\uC693\uC695-\uC6AF\uC6B1-\uC6CB\uC6CD-\uC6E7\uC6E9-\uC703\uC705-\uC71F\uC721-\uC73B\uC73D-\uC757\uC759-\uC773\uC775-\uC78F\uC791-\uC7AB\uC7AD-\uC7C7\uC7C9-\uC7E3\uC7E5-\uC7FF\uC801-\uC81B\uC81D-\uC837\uC839-\uC853\uC855-\uC86F\uC871-\uC88B\uC88D-\uC8A7\uC8A9-\uC8C3\uC8C5-\uC8DF\uC8E1-\uC8FB\uC8FD-\uC917\uC919-\uC933\uC935-\uC94F\uC951-\uC96B\uC96D-\uC987\uC989-\uC9A3\uC9A5-\uC9BF\uC9C1-\uC9DB\uC9DD-\uC9F7\uC9F9-\uCA13\uCA15-\uCA2F\uCA31-\uCA4B\uCA4D-\uCA67\uCA69-\uCA83\uCA85-\uCA9F\uCAA1-\uCABB\uCABD-\uCAD7\uCAD9-\uCAF3\uCAF5-\uCB0F\uCB11-\uCB2B\uCB2D-\uCB47\uCB49-\uCB63\uCB65-\uCB7F\uCB81-\uCB9B\uCB9D-\uCBB7\uCBB9-\uCBD3\uCBD5-\uCBEF\uCBF1-\uCC0B\uCC0D-\uCC27\uCC29-\uCC43\uCC45-\uCC5F\uCC61-\uCC7B\uCC7D-\uCC97\uCC99-\uCCB3\uCCB5-\uCCCF\uCCD1-\uCCEB\uCCED-\uCD07\uCD09-\uCD23\uCD25-\uCD3F\uCD41-\uCD5B\uCD5D-\uCD77\uCD79-\uCD93\uCD95-\uCDAF\uCDB1-\uCDCB\uCDCD-\uCDE7\uCDE9-\uCE03\uCE05-\uCE1F\uCE21-\uCE3B\uCE3D-\uCE57\uCE59-\uCE73\uCE75-\uCE8F\uCE91-\uCEAB\uCEAD-\uCEC7\uCEC9-\uCEE3\uCEE5-\uCEFF\uCF01-\uCF1B\uCF1D-\uCF37\uCF39-\uCF53\uCF55-\uCF6F\uCF71-\uCF8B\uCF8D-\uCFA7\uCFA9-\uCFC3\uCFC5-\uCFDF\uCFE1-\uCFFB\uCFFD-\uD017\uD019-\uD033\uD035-\uD04F\uD051-\uD06B\uD06D-\uD087\uD089-\uD0A3\uD0A5-\uD0BF\uD0C1-\uD0DB\uD0DD-\uD0F7\uD0F9-\uD113\uD115-\uD12F\uD131-\uD14B\uD14D-\uD167\uD169-\uD183\uD185-\uD19F\uD1A1-\uD1BB\uD1BD-\uD1D7\uD1D9-\uD1F3\uD1F5-\uD20F\uD211-\uD22B\uD22D-\uD247\uD249-\uD263\uD265-\uD27F\uD281-\uD29B\uD29D-\uD2B7\uD2B9-\uD2D3\uD2D5-\uD2EF\uD2F1-\uD30B\uD30D-\uD327\uD329-\uD343\uD345-\uD35F\uD361-\uD37B\uD37D-\uD397\uD399-\uD3B3\uD3B5-\uD3CF\uD3D1-\uD3EB\uD3ED-\uD407\uD409-\uD423\uD425-\uD43F\uD441-\uD45B\uD45D-\uD477\uD479-\uD493\uD495-\uD4AF\uD4B1-\uD4CB\uD4CD-\uD4E7\uD4E9-\uD503\uD505-\uD51F\uD521-\uD53B\uD53D-\uD557\uD559-\uD573\uD575-\uD58F\uD591-\uD5AB\uD5AD-\uD5C7\uD5C9-\uD5E3\uD5E5-\uD5FF\uD601-\uD61B\uD61D-\uD637\uD639-\uD653\uD655-\uD66F\uD671-\uD68B\uD68D-\uD6A7\uD6A9-\uD6C3\uD6C5-\uD6DF\uD6E1-\uD6FB\uD6FD-\uD717\uD719-\uD733\uD735-\uD74F\uD751-\uD76B\uD76D-\uD787\uD789-\uD7A3]$/,Fh=/^(?:[\xA9\xAE\u203C\u2049\u2122\u2139\u2194-\u2199\u21A9\u21AA\u231A\u231B\u2328\u2388\u23CF\u23E9-\u23F3\u23F8-\u23FA\u24C2\u25AA\u25AB\u25B6\u25C0\u25FB-\u25FE\u2600-\u2605\u2607-\u2612\u2614-\u2685\u2690-\u2705\u2708-\u2712\u2714\u2716\u271D\u2721\u2728\u2733\u2734\u2744\u2747\u274C\u274E\u2753-\u2755\u2757\u2763-\u2767\u2795-\u2797\u27A1\u27B0\u27BF\u2934\u2935\u2B05-\u2B07\u2B1B\u2B1C\u2B50\u2B55\u3030\u303D\u3297\u3299]|\uD83C[\uDC00-\uDCFF\uDD0D-\uDD0F\uDD2F\uDD6C-\uDD71\uDD7E\uDD7F\uDD8E\uDD91-\uDD9A\uDDAD-\uDDE5\uDE01-\uDE0F\uDE1A\uDE2F\uDE32-\uDE3A\uDE3C-\uDE3F\uDE49-\uDFFA]|\uD83D[\uDC00-\uDD3D\uDD46-\uDE4F\uDE80-\uDEFF\uDF74-\uDF7F\uDFD5-\uDFFF]|\uD83E[\uDC0C-\uDC0F\uDC48-\uDC4F\uDC5A-\uDC5F\uDC88-\uDC8F\uDCAE-\uDCFF\uDD0C-\uDD3A\uDD3C-\uDD45\uDD47-\uDEFF]|\uD83F[\uDC00-\uDFFD])$/,Ih=(e,t)=>{var n=hh.Any;return-1!==e.search(Sh)&&(n|=hh.Extend),8205===t&&(n|=hh.ZWJ),t>=127462&&t<=127487&&(n|=hh.RI),-1!==e.search(Ah)&&(n|=hh.Prepend),-1!==e.search(xh)&&(n|=hh.SpacingMark),-1!==e.search(Oh)&&(n|=hh.L),-1!==e.search(Nh)&&(n|=hh.V),-1!==e.search(Bh)&&(n|=hh.T),-1!==e.search(Th)&&(n|=hh.LV),-1!==e.search(kh)&&(n|=hh.LVT),-1!==e.search(Fh)&&(n|=hh.ExtPict),n};function Ph(e,t){return 0!==(e&t)}var _h=[[hh.L,hh.L|hh.V|hh.LV|hh.LVT],[hh.LV|hh.V,hh.V|hh.T],[hh.LVT|hh.T,hh.T],[hh.Any,hh.Extend|hh.ZWJ],[hh.Any,hh.SpacingMark],[hh.Prepend,hh.Any],[hh.ZWJ,hh.ExtPict],[hh.RI,hh.RI]];function Lh(e,t){return-1===_h.findIndex(n=>Ph(e,n[0])&&Ph(t,n[1]))}var Rh=/(?:[\xA9\xAE\u203C\u2049\u2122\u2139\u2194-\u2199\u21A9\u21AA\u231A\u231B\u2328\u2388\u23CF\u23E9-\u23F3\u23F8-\u23FA\u24C2\u25AA\u25AB\u25B6\u25C0\u25FB-\u25FE\u2600-\u2605\u2607-\u2612\u2614-\u2685\u2690-\u2705\u2708-\u2712\u2714\u2716\u271D\u2721\u2728\u2733\u2734\u2744\u2747\u274C\u274E\u2753-\u2755\u2757\u2763-\u2767\u2795-\u2797\u27A1\u27B0\u27BF\u2934\u2935\u2B05-\u2B07\u2B1B\u2B1C\u2B50\u2B55\u3030\u303D\u3297\u3299]|\uD83C[\uDC00-\uDCFF\uDD0D-\uDD0F\uDD2F\uDD6C-\uDD71\uDD7E\uDD7F\uDD8E\uDD91-\uDD9A\uDDAD-\uDDE5\uDE01-\uDE0F\uDE1A\uDE2F\uDE32-\uDE3A\uDE3C-\uDE3F\uDE49-\uDFFA]|\uD83D[\uDC00-\uDD3D\uDD46-\uDE4F\uDE80-\uDEFF\uDF74-\uDF7F\uDFD5-\uDFFF]|\uD83E[\uDC0C-\uDC0F\uDC48-\uDC4F\uDC5A-\uDC5F\uDC88-\uDC8F\uDCAE-\uDCFF\uDD0C-\uDD3A\uDD3C-\uDD45\uDD47-\uDEFF]|\uD83F[\uDC00-\uDFFD])(?:[\u0300-\u036F\u0483-\u0489\u0591-\u05BD\u05BF\u05C1\u05C2\u05C4\u05C5\u05C7\u0610-\u061A\u064B-\u065F\u0670\u06D6-\u06DC\u06DF-\u06E4\u06E7\u06E8\u06EA-\u06ED\u0711\u0730-\u074A\u07A6-\u07B0\u07EB-\u07F3\u07FD\u0816-\u0819\u081B-\u0823\u0825-\u0827\u0829-\u082D\u0859-\u085B\u08D3-\u08E1\u08E3-\u0902\u093A\u093C\u0941-\u0948\u094D\u0951-\u0957\u0962\u0963\u0981\u09BC\u09BE\u09C1-\u09C4\u09CD\u09D7\u09E2\u09E3\u09FE\u0A01\u0A02\u0A3C\u0A41\u0A42\u0A47\u0A48\u0A4B-\u0A4D\u0A51\u0A70\u0A71\u0A75\u0A81\u0A82\u0ABC\u0AC1-\u0AC5\u0AC7\u0AC8\u0ACD\u0AE2\u0AE3\u0AFA-\u0AFF\u0B01\u0B3C\u0B3E\u0B3F\u0B41-\u0B44\u0B4D\u0B55-\u0B57\u0B62\u0B63\u0B82\u0BBE\u0BC0\u0BCD\u0BD7\u0C00\u0C04\u0C3E-\u0C40\u0C46-\u0C48\u0C4A-\u0C4D\u0C55\u0C56\u0C62\u0C63\u0C81\u0CBC\u0CBF\u0CC2\u0CC6\u0CCC\u0CCD\u0CD5\u0CD6\u0CE2\u0CE3\u0D00\u0D01\u0D3B\u0D3C\u0D3E\u0D41-\u0D44\u0D4D\u0D57\u0D62\u0D63\u0D81\u0DCA\u0DCF\u0DD2-\u0DD4\u0DD6\u0DDF\u0E31\u0E34-\u0E3A\u0E47-\u0E4E\u0EB1\u0EB4-\u0EBC\u0EC8-\u0ECD\u0F18\u0F19\u0F35\u0F37\u0F39\u0F71-\u0F7E\u0F80-\u0F84\u0F86\u0F87\u0F8D-\u0F97\u0F99-\u0FBC\u0FC6\u102D-\u1030\u1032-\u1037\u1039\u103A\u103D\u103E\u1058\u1059\u105E-\u1060\u1071-\u1074\u1082\u1085\u1086\u108D\u109D\u135D-\u135F\u1712-\u1714\u1732-\u1734\u1752\u1753\u1772\u1773\u17B4\u17B5\u17B7-\u17BD\u17C6\u17C9-\u17D3\u17DD\u180B-\u180D\u1885\u1886\u18A9\u1920-\u1922\u1927\u1928\u1932\u1939-\u193B\u1A17\u1A18\u1A1B\u1A56\u1A58-\u1A5E\u1A60\u1A62\u1A65-\u1A6C\u1A73-\u1A7C\u1A7F\u1AB0-\u1AC0\u1B00-\u1B03\u1B34-\u1B3A\u1B3C\u1B42\u1B6B-\u1B73\u1B80\u1B81\u1BA2-\u1BA5\u1BA8\u1BA9\u1BAB-\u1BAD\u1BE6\u1BE8\u1BE9\u1BED\u1BEF-\u1BF1\u1C2C-\u1C33\u1C36\u1C37\u1CD0-\u1CD2\u1CD4-\u1CE0\u1CE2-\u1CE8\u1CED\u1CF4\u1CF8\u1CF9\u1DC0-\u1DF9\u1DFB-\u1DFF\u200C\u20D0-\u20F0\u2CEF-\u2CF1\u2D7F\u2DE0-\u2DFF\u302A-\u302F\u3099\u309A\uA66F-\uA672\uA674-\uA67D\uA69E\uA69F\uA6F0\uA6F1\uA802\uA806\uA80B\uA825\uA826\uA82C\uA8C4\uA8C5\uA8E0-\uA8F1\uA8FF\uA926-\uA92D\uA947-\uA951\uA980-\uA982\uA9B3\uA9B6-\uA9B9\uA9BC\uA9BD\uA9E5\uAA29-\uAA2E\uAA31\uAA32\uAA35\uAA36\uAA43\uAA4C\uAA7C\uAAB0\uAAB2-\uAAB4\uAAB7\uAAB8\uAABE\uAABF\uAAC1\uAAEC\uAAED\uAAF6\uABE5\uABE8\uABED\uFB1E\uFE00-\uFE0F\uFE20-\uFE2F\uFF9E\uFF9F]|\uD800[\uDDFD\uDEE0\uDF76-\uDF7A]|\uD802[\uDE01-\uDE03\uDE05\uDE06\uDE0C-\uDE0F\uDE38-\uDE3A\uDE3F\uDEE5\uDEE6]|\uD803[\uDD24-\uDD27\uDEAB\uDEAC\uDF46-\uDF50]|\uD804[\uDC01\uDC38-\uDC46\uDC7F-\uDC81\uDCB3-\uDCB6\uDCB9\uDCBA\uDD00-\uDD02\uDD27-\uDD2B\uDD2D-\uDD34\uDD73\uDD80\uDD81\uDDB6-\uDDBE\uDDC9-\uDDCC\uDDCF\uDE2F-\uDE31\uDE34\uDE36\uDE37\uDE3E\uDEDF\uDEE3-\uDEEA\uDF00\uDF01\uDF3B\uDF3C\uDF3E\uDF40\uDF57\uDF66-\uDF6C\uDF70-\uDF74]|\uD805[\uDC38-\uDC3F\uDC42-\uDC44\uDC46\uDC5E\uDCB0\uDCB3-\uDCB8\uDCBA\uDCBD\uDCBF\uDCC0\uDCC2\uDCC3\uDDAF\uDDB2-\uDDB5\uDDBC\uDDBD\uDDBF\uDDC0\uDDDC\uDDDD\uDE33-\uDE3A\uDE3D\uDE3F\uDE40\uDEAB\uDEAD\uDEB0-\uDEB5\uDEB7\uDF1D-\uDF1F\uDF22-\uDF25\uDF27-\uDF2B]|\uD806[\uDC2F-\uDC37\uDC39\uDC3A\uDD30\uDD3B\uDD3C\uDD3E\uDD43\uDDD4-\uDDD7\uDDDA\uDDDB\uDDE0\uDE01-\uDE0A\uDE33-\uDE38\uDE3B-\uDE3E\uDE47\uDE51-\uDE56\uDE59-\uDE5B\uDE8A-\uDE96\uDE98\uDE99]|\uD807[\uDC30-\uDC36\uDC38-\uDC3D\uDC3F\uDC92-\uDCA7\uDCAA-\uDCB0\uDCB2\uDCB3\uDCB5\uDCB6\uDD31-\uDD36\uDD3A\uDD3C\uDD3D\uDD3F-\uDD45\uDD47\uDD90\uDD91\uDD95\uDD97\uDEF3\uDEF4]|\uD81A[\uDEF0-\uDEF4\uDF30-\uDF36]|\uD81B[\uDF4F\uDF8F-\uDF92\uDFE4]|\uD82F[\uDC9D\uDC9E]|\uD834[\uDD65\uDD67-\uDD69\uDD6E-\uDD72\uDD7B-\uDD82\uDD85-\uDD8B\uDDAA-\uDDAD\uDE42-\uDE44]|\uD836[\uDE00-\uDE36\uDE3B-\uDE6C\uDE75\uDE84\uDE9B-\uDE9F\uDEA1-\uDEAF]|\uD838[\uDC00-\uDC06\uDC08-\uDC18\uDC1B-\uDC21\uDC23\uDC24\uDC26-\uDC2A\uDD30-\uDD36\uDEEC-\uDEEF]|\uD83A[\uDCD0-\uDCD6\uDD44-\uDD4A]|\uD83C[\uDFFB-\uDFFF]|\uDB40[\uDC20-\uDC7F\uDD00-\uDDEF])*\u200D$/,Mh=e=>-1!==e.search(Rh),jh=/(?:\uD83C[\uDDE6-\uDDFF])+$/g,Hh=e=>{var t=e.match(jh);return null!==t&&t[0].length/2%2==1},zh=e=>op(e)&&eg.isNodeList(e.children)&&!Kh.isEditor(e),$h={isAncestor:e=>op(e)&&eg.isNodeList(e.children),isElement:zh,isElementList:e=>Array.isArray(e)&&e.every(e=>$h.isElement(e)),isElementProps:e=>void 0!==e.children,isElementType:function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"type";return zh(e)&&e[n]===t},matches(e,t){for(var n in t)if("children"!==n&&e[n]!==t[n])return!1;return!0}},Uh=["text"],Vh=["text"];function Wh(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function Gh(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Wh(Object(n),!0).forEach(function(t){rh(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Wh(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}var qh=new WeakMap,Kh={above(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{voids:n=!1,mode:r="lowest",at:o=e.selection,match:i}=t;if(o){var a=Kh.path(e,o),s="lowest"===r;for(var[u,l]of Kh.levels(e,{at:a,voids:n,match:i,reverse:s}))if(!Cg.isText(u)&&!og.equals(a,l))return[u,l]}},addMark(e,t,n){e.addMark(t,n)},after(e,t){var n,r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},o={anchor:Kh.point(e,t,{edge:"end"}),focus:Kh.end(e,[])},{distance:i=1}=r,a=0;for(var s of Kh.positions(e,Gh(Gh({},r),{},{at:o}))){if(a>i)break;0!==a&&(n=s),a++}return n},before(e,t){var n,r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},o={anchor:Kh.start(e,[]),focus:Kh.point(e,t,{edge:"start"})},{distance:i=1}=r,a=0;for(var s of Kh.positions(e,Gh(Gh({},r),{},{at:o,reverse:!0}))){if(a>i)break;0!==a&&(n=s),a++}return n},deleteBackward(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{unit:n="character"}=t;e.deleteBackward(n)},deleteForward(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{unit:n="character"}=t;e.deleteForward(n)},deleteFragment(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{direction:n="forward"}=t;e.deleteFragment(n)},edges:(e,t)=>[Kh.start(e,t),Kh.end(e,t)],end:(e,t)=>Kh.point(e,t,{edge:"end"}),first(e,t){var n=Kh.path(e,t,{edge:"start"});return Kh.node(e,n)},fragment(e,t){var n=Kh.range(e,t);return eg.fragment(e,n)},hasBlocks:(e,t)=>t.children.some(t=>Kh.isBlock(e,t)),hasInlines:(e,t)=>t.children.some(t=>Cg.isText(t)||Kh.isInline(e,t)),hasTexts:(e,t)=>t.children.every(e=>Cg.isText(e)),insertBreak(e){e.insertBreak()},insertSoftBreak(e){e.insertSoftBreak()},insertFragment(e,t){e.insertFragment(t)},insertNode(e,t){e.insertNode(t)},insertText(e,t){e.insertText(t)},isBlock:(e,t)=>$h.isElement(t)&&!e.isInline(t),isEditor(e){var t=qh.get(e);if(void 0!==t)return t;if(!op(e))return!1;var n="function"==typeof e.addMark&&"function"==typeof e.apply&&"function"==typeof e.deleteBackward&&"function"==typeof e.deleteForward&&"function"==typeof e.deleteFragment&&"function"==typeof e.insertBreak&&"function"==typeof e.insertSoftBreak&&"function"==typeof e.insertFragment&&"function"==typeof e.insertNode&&"function"==typeof e.insertText&&"function"==typeof e.isInline&&"function"==typeof e.isVoid&&"function"==typeof e.normalizeNode&&"function"==typeof e.onChange&&"function"==typeof e.removeMark&&"function"==typeof e.getDirtyPaths&&(null===e.marks||op(e.marks))&&(null===e.selection||fg.isRange(e.selection))&&eg.isNodeList(e.children)&&rg.isOperationList(e.operations);return qh.set(e,n),n},isEnd(e,t,n){var r=Kh.end(e,n);return ug.equals(t,r)},isEdge:(e,t,n)=>Kh.isStart(e,t,n)||Kh.isEnd(e,t,n),isEmpty(e,t){var{children:n}=t,[r]=n;return 0===n.length||1===n.length&&Cg.isText(r)&&""===r.text&&!e.isVoid(t)},isInline:(e,t)=>$h.isElement(t)&&e.isInline(t),isNormalizing(e){var t=sh.get(e);return void 0===t||t},isStart(e,t,n){if(0!==t.offset)return!1;var r=Kh.start(e,n);return ug.equals(t,r)},isVoid:(e,t)=>$h.isElement(t)&&e.isVoid(t),last(e,t){var n=Kh.path(e,t,{edge:"end"});return Kh.node(e,n)},leaf(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},r=Kh.path(e,t,n);return[eg.leaf(e,r),r]},*levels(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{at:n=e.selection,reverse:r=!1,voids:o=!1}=t,{match:i}=t;if(null==i&&(i=()=>!0),n){var a=[],s=Kh.path(e,n);for(var[u,l]of eg.levels(e,s))if(i(u,l)&&(a.push([u,l]),!o&&Kh.isVoid(e,u)))break;r&&a.reverse(),yield*a}},marks(e){var{marks:t,selection:n}=e;if(!n)return null;if(t)return t;if(fg.isExpanded(n)){var[r]=Kh.nodes(e,{match:Cg.isText});if(r){var[o]=r;return ph(o,Uh)}return{}}var{anchor:i}=n,{path:a}=i,[s]=Kh.leaf(e,a);if(0===i.offset){var u=Kh.previous(e,{at:a,match:Cg.isText}),l=Kh.above(e,{match:t=>Kh.isBlock(e,t)});if(u&&l){var[c,d]=u,[,f]=l;og.isAncestor(f,d)&&(s=c)}}return ph(s,Vh)},next(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{mode:n="lowest",voids:r=!1}=t,{match:o,at:i=e.selection}=t;if(i){var a=Kh.after(e,i,{voids:r});if(a){var[,s]=Kh.last(e,[]),u=[a.path,s];if(og.isPath(i)&&0===i.length)throw new Error("Cannot get the next node from the root node!");if(null==o)if(og.isPath(i)){var[l]=Kh.parent(e,i);o=e=>l.children.includes(e)}else o=()=>!0;var[c]=Kh.nodes(e,{at:u,match:o,mode:n,voids:r});return c}}},node(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},r=Kh.path(e,t,n);return[eg.get(e,r),r]},*nodes(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{at:n=e.selection,mode:r="all",universal:o=!1,reverse:i=!1,voids:a=!1}=t,{match:s}=t;if(s||(s=()=>!0),n){var u,l;if(Xh.isSpan(n))u=n[0],l=n[1];else{var c=Kh.path(e,n,{edge:"start"}),d=Kh.path(e,n,{edge:"end"});u=i?d:c,l=i?c:d}var f,p=eg.nodes(e,{reverse:i,from:u,to:l,pass:t=>{var[n]=t;return!a&&Kh.isVoid(e,n)}}),h=[];for(var[g,v]of p){var m=f&&0===og.compare(v,f[1]);if("highest"!==r||!m)if(s(g,v))if("lowest"===r&&m)f=[g,v];else{var y="lowest"===r?f:[g,v];y&&(o?h.push(y):yield y),f=[g,v]}else if(o&&!m&&Cg.isText(g))return}"lowest"===r&&f&&(o?h.push(f):yield f),o&&(yield*h)}},normalize(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{force:n=!1}=t,r=e=>oh.get(e)||[],o=e=>{var t=r(e).pop(),n=t.join(",");return(e=>ih.get(e)||new Set)(e).delete(n),t};if(Kh.isNormalizing(e)){if(n){var i=Array.from(eg.nodes(e),e=>{var[,t]=e;return t}),a=new Set(i.map(e=>e.join(",")));oh.set(e,i),ih.set(e,a)}0!==r(e).length&&Kh.withoutNormalizing(e,()=>{for(var t of r(e))if(eg.has(e,t)){var n=Kh.node(e,t),[i,a]=n;$h.isElement(i)&&0===i.children.length&&e.normalizeNode(n)}for(var s=42*r(e).length,u=0;0!==r(e).length;){if(u>s)throw new Error("\n Could not completely normalize the editor after ".concat(s," iterations! This is usually due to incorrect normalization logic that leaves a node in an invalid state.\n "));var l=o(e);if(eg.has(e,l)){var c=Kh.node(e,l);e.normalizeNode(c)}u++}})}},parent(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},r=Kh.path(e,t,n),o=og.parent(r);return Kh.node(e,o)},path(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},{depth:r,edge:o}=n;if(og.isPath(t))if("start"===o){var[,i]=eg.first(e,t);t=i}else if("end"===o){var[,a]=eg.last(e,t);t=a}return fg.isRange(t)&&(t="start"===o?fg.start(t):"end"===o?fg.end(t):og.common(t.anchor.path,t.focus.path)),ug.isPoint(t)&&(t=t.path),null!=r&&(t=t.slice(0,r)),t},hasPath:(e,t)=>eg.has(e,t),pathRef(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},{affinity:r="forward"}=n,o={current:t,affinity:r,unref(){var{current:t}=o;return Kh.pathRefs(e).delete(o),o.current=null,t}};return Kh.pathRefs(e).add(o),o},pathRefs(e){var t=uh.get(e);return t||(t=new Set,uh.set(e,t)),t},point(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},{edge:r="start"}=n;if(og.isPath(t)){var o;if("end"===r){var[,i]=eg.last(e,t);o=i}else{var[,a]=eg.first(e,t);o=a}var s=eg.get(e,o);if(!Cg.isText(s))throw new Error("Cannot get the ".concat(r," point in the node at path [").concat(t,"] because it has no ").concat(r," text node."));return{path:o,offset:"end"===r?s.text.length:0}}if(fg.isRange(t)){var[u,l]=fg.edges(t);return"start"===r?u:l}return t},pointRef(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},{affinity:r="forward"}=n,o={current:t,affinity:r,unref(){var{current:t}=o;return Kh.pointRefs(e).delete(o),o.current=null,t}};return Kh.pointRefs(e).add(o),o},pointRefs(e){var t=lh.get(e);return t||(t=new Set,lh.set(e,t)),t},*positions(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{at:n=e.selection,unit:r="offset",reverse:o=!1,voids:i=!1}=t;if(n){var a=Kh.range(e,n),[s,u]=fg.edges(a),l=o?u:s,c=!1,d="",f=0,p=0,h=0;for(var[g,v]of Kh.nodes(e,{at:n,reverse:o,voids:i})){if($h.isElement(g)){if(!i&&e.isVoid(g)){yield Kh.start(e,v);continue}if(e.isInline(g))continue;if(Kh.hasInlines(e,g)){var m=og.isAncestor(v,u.path)?u:Kh.end(e,v),y=og.isAncestor(v,s.path)?s:Kh.start(e,v);d=Kh.string(e,{anchor:y,focus:m},{voids:i}),c=!0}}if(Cg.isText(g)){var b=og.equals(v,l.path);for(b?(p=o?l.offset:g.text.length-l.offset,h=l.offset):(p=g.text.length,h=o?p:0),(b||c||"offset"===r)&&(yield{path:v,offset:h},c=!1);;){if(0===f){if(""===d)break;f=E(d,r,o),d=bh(d,f,o)[1]}if(h=o?h-f:h+f,(p-=f)<0){f=-p;break}f=0,yield{path:v,offset:h}}}}}function E(e,t,n){return"character"===t?gh(e,n):"word"===t?function(e){for(var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1],n=0,r=!1;e.length>0;){var o=gh(e,t),[i,a]=bh(e,o,t);if(Eh(i,a,t))r=!0,n+=o;else{if(r)break;n+=o}e=a}return n}(e,n):"line"===t||"block"===t?e.length:1}},previous(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{mode:n="lowest",voids:r=!1}=t,{match:o,at:i=e.selection}=t;if(i){var a=Kh.before(e,i,{voids:r});if(a){var[,s]=Kh.first(e,[]),u=[a.path,s];if(og.isPath(i)&&0===i.length)throw new Error("Cannot get the previous node from the root node!");if(null==o)if(og.isPath(i)){var[l]=Kh.parent(e,i);o=e=>l.children.includes(e)}else o=()=>!0;var[c]=Kh.nodes(e,{reverse:!0,at:u,match:o,mode:n,voids:r});return c}}},range:(e,t,n)=>fg.isRange(t)&&!n?t:{anchor:Kh.start(e,t),focus:Kh.end(e,n||t)},rangeRef(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},{affinity:r="forward"}=n,o={current:t,affinity:r,unref(){var{current:t}=o;return Kh.rangeRefs(e).delete(o),o.current=null,t}};return Kh.rangeRefs(e).add(o),o},rangeRefs(e){var t=ch.get(e);return t||(t=new Set,ch.set(e,t)),t},removeMark(e,t){e.removeMark(t)},setNormalizing(e,t){sh.set(e,t)},start:(e,t)=>Kh.point(e,t,{edge:"start"}),string(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},{voids:r=!1}=n,o=Kh.range(e,t),[i,a]=fg.edges(o),s="";for(var[u,l]of Kh.nodes(e,{at:o,match:Cg.isText,voids:r})){var c=u.text;og.equals(l,a.path)&&(c=c.slice(0,a.offset)),og.equals(l,i.path)&&(c=c.slice(i.offset)),s+=c}return s},unhangRange(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},{voids:r=!1}=n,[o,i]=fg.edges(t);if(0!==o.offset||0!==i.offset||fg.isCollapsed(t))return t;var a=Kh.above(e,{at:i,match:t=>Kh.isBlock(e,t)}),s=a?a[1]:[],u={anchor:Kh.start(e,o),focus:i},l=!0;for(var[c,d]of Kh.nodes(e,{at:u,match:Cg.isText,reverse:!0,voids:r}))if(l)l=!1;else if(""!==c.text||og.isBefore(d,s)){i={path:d,offset:c.text.length};break}return{anchor:o,focus:i}},void(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return Kh.above(e,Gh(Gh({},t),{},{match:t=>Kh.isVoid(e,t)}))},withoutNormalizing(e,t){var n=Kh.isNormalizing(e);Kh.setNormalizing(e,!1);try{t()}finally{Kh.setNormalizing(e,n)}Kh.normalize(e)}},Yh={isLocation:e=>og.isPath(e)||ug.isPoint(e)||fg.isRange(e)},Xh={isSpan:e=>Array.isArray(e)&&2===e.length&&e.every(og.isPath)},Zh=["children"],Jh=["text"],Qh=new WeakMap,eg={ancestor(e,t){var n=eg.get(e,t);if(Cg.isText(n))throw new Error("Cannot get the ancestor node at path [".concat(t,"] because it refers to a text node instead: ").concat(gg.stringify(n)));return n},*ancestors(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};for(var r of og.ancestors(t,n)){var o=[eg.ancestor(e,r),r];yield o}},child(e,t){if(Cg.isText(e))throw new Error("Cannot get the child of a text node: ".concat(gg.stringify(e)));var n=e.children[t];if(null==n)throw new Error("Cannot get child at index `".concat(t,"` in node: ").concat(gg.stringify(e)));return n},*children(e,t){for(var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},{reverse:r=!1}=n,o=eg.ancestor(e,t),{children:i}=o,a=r?i.length-1:0;r?a>=0:a<i.length;){var s=eg.child(o,a),u=t.concat(a);yield[s,u],a=r?a-1:a+1}},common(e,t,n){var r=og.common(t,n);return[eg.get(e,r),r]},descendant(e,t){var n=eg.get(e,t);if(Kh.isEditor(n))throw new Error("Cannot get the descendant node at path [".concat(t,"] because it refers to the root editor node instead: ").concat(gg.stringify(n)));return n},*descendants(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};for(var[n,r]of eg.nodes(e,t))0!==r.length&&(yield[n,r])},*elements(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};for(var[n,r]of eg.nodes(e,t))$h.isElement(n)&&(yield[n,r])},extractProps:e=>$h.isAncestor(e)?ph(e,Zh):ph(e,Jh),first(e,t){for(var n=t.slice(),r=eg.get(e,n);r&&!Cg.isText(r)&&0!==r.children.length;)r=r.children[0],n.push(0);return[r,n]},fragment(e,t){if(Cg.isText(e))throw new Error("Cannot get a fragment starting from a root text node: ".concat(gg.stringify(e)));var n=eh({children:e.children},e=>{var[n,r]=fg.edges(t),o=eg.nodes(e,{reverse:!0,pass:e=>{var[,n]=e;return!fg.includes(t,n)}});for(var[,i]of o){if(!fg.includes(t,i)){var a=eg.parent(e,i),s=i[i.length-1];a.children.splice(s,1)}if(og.equals(i,r.path)){var u=eg.leaf(e,i);u.text=u.text.slice(0,r.offset)}if(og.equals(i,n.path)){var l=eg.leaf(e,i);l.text=l.text.slice(n.offset)}}Kh.isEditor(e)&&(e.selection=null)});return n.children},get(e,t){for(var n=e,r=0;r<t.length;r++){var o=t[r];if(Cg.isText(n)||!n.children[o])throw new Error("Cannot find a descendant at path [".concat(t,"] in node: ").concat(gg.stringify(e)));n=n.children[o]}return n},has(e,t){for(var n=e,r=0;r<t.length;r++){var o=t[r];if(Cg.isText(n)||!n.children[o])return!1;n=n.children[o]}return!0},isNode:e=>Cg.isText(e)||$h.isElement(e)||Kh.isEditor(e),isNodeList(e){if(!Array.isArray(e))return!1;var t=Qh.get(e);if(void 0!==t)return t;var n=e.every(e=>eg.isNode(e));return Qh.set(e,n),n},last(e,t){for(var n=t.slice(),r=eg.get(e,n);r&&!Cg.isText(r)&&0!==r.children.length;){var o=r.children.length-1;r=r.children[o],n.push(o)}return[r,n]},leaf(e,t){var n=eg.get(e,t);if(!Cg.isText(n))throw new Error("Cannot get the leaf node at path [".concat(t,"] because it refers to a non-leaf node: ").concat(gg.stringify(n)));return n},*levels(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};for(var r of og.levels(t,n)){var o=eg.get(e,r);yield[o,r]}},matches:(e,t)=>$h.isElement(e)&&$h.isElementProps(t)&&$h.matches(e,t)||Cg.isText(e)&&Cg.isTextProps(t)&&Cg.matches(e,t),*nodes(e){for(var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{pass:n,reverse:r=!1}=t,{from:o=[],to:i}=t,a=new Set,s=[],u=e;!i||!(r?og.isBefore(s,i):og.isAfter(s,i));)if(a.has(u)||(yield[u,s]),a.has(u)||Cg.isText(u)||0===u.children.length||null!=n&&!1!==n([u,s])){if(0===s.length)break;if(!r){var l=og.next(s);if(eg.has(e,l)){s=l,u=eg.get(e,s);continue}}if(r&&0!==s[s.length-1])s=og.previous(s),u=eg.get(e,s);else s=og.parent(s),u=eg.get(e,s),a.add(u)}else{a.add(u);var c=r?u.children.length-1:0;og.isAncestor(s,o)&&(c=o[s.length]),s=s.concat(c),u=eg.get(e,s)}},parent(e,t){var n=og.parent(t),r=eg.get(e,n);if(Cg.isText(r))throw new Error("Cannot get the parent of path [".concat(t,"] because it does not exist in the root."));return r},string:e=>Cg.isText(e)?e.text:e.children.map(eg.string).join(""),*texts(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};for(var[n,r]of eg.nodes(e,t))Cg.isText(n)&&(yield[n,r])}};function tg(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function ng(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?tg(Object(n),!0).forEach(function(t){rh(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):tg(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}var rg={isNodeOperation:e=>rg.isOperation(e)&&e.type.endsWith("_node"),isOperation(e){if(!op(e))return!1;switch(e.type){case"insert_node":case"remove_node":return og.isPath(e.path)&&eg.isNode(e.node);case"insert_text":case"remove_text":return"number"==typeof e.offset&&"string"==typeof e.text&&og.isPath(e.path);case"merge_node":return"number"==typeof e.position&&og.isPath(e.path)&&op(e.properties);case"move_node":return og.isPath(e.path)&&og.isPath(e.newPath);case"set_node":return og.isPath(e.path)&&op(e.properties)&&op(e.newProperties);case"set_selection":return null===e.properties&&fg.isRange(e.newProperties)||null===e.newProperties&&fg.isRange(e.properties)||op(e.properties)&&op(e.newProperties);case"split_node":return og.isPath(e.path)&&"number"==typeof e.position&&op(e.properties);default:return!1}},isOperationList:e=>Array.isArray(e)&&e.every(e=>rg.isOperation(e)),isSelectionOperation:e=>rg.isOperation(e)&&e.type.endsWith("_selection"),isTextOperation:e=>rg.isOperation(e)&&e.type.endsWith("_text"),inverse(e){switch(e.type){case"insert_node":return ng(ng({},e),{},{type:"remove_node"});case"insert_text":return ng(ng({},e),{},{type:"remove_text"});case"merge_node":return ng(ng({},e),{},{type:"split_node",path:og.previous(e.path)});case"move_node":var{newPath:t,path:n}=e;if(og.equals(t,n))return e;if(og.isSibling(n,t))return ng(ng({},e),{},{path:t,newPath:n});var r=og.transform(n,e),o=og.transform(og.next(n),e);return ng(ng({},e),{},{path:r,newPath:o});case"remove_node":return ng(ng({},e),{},{type:"insert_node"});case"remove_text":return ng(ng({},e),{},{type:"insert_text"});case"set_node":var{properties:i,newProperties:a}=e;return ng(ng({},e),{},{properties:a,newProperties:i});case"set_selection":var{properties:s,newProperties:u}=e;return ng(ng({},e),{},null==s?{properties:u,newProperties:null}:null==u?{properties:null,newProperties:s}:{properties:u,newProperties:s});case"split_node":return ng(ng({},e),{},{type:"merge_node",path:og.next(e.path)})}}},og={ancestors(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{reverse:n=!1}=t,r=og.levels(e,t);return r=n?r.slice(1):r.slice(0,-1)},common(e,t){for(var n=[],r=0;r<e.length&&r<t.length;r++){var o=e[r];if(o!==t[r])break;n.push(o)}return n},compare(e,t){for(var n=Math.min(e.length,t.length),r=0;r<n;r++){if(e[r]<t[r])return-1;if(e[r]>t[r])return 1}return 0},endsAfter(e,t){var n=e.length-1,r=e.slice(0,n),o=t.slice(0,n),i=e[n],a=t[n];return og.equals(r,o)&&i>a},endsAt(e,t){var n=e.length,r=e.slice(0,n),o=t.slice(0,n);return og.equals(r,o)},endsBefore(e,t){var n=e.length-1,r=e.slice(0,n),o=t.slice(0,n),i=e[n],a=t[n];return og.equals(r,o)&&i<a},equals:(e,t)=>e.length===t.length&&e.every((e,n)=>e===t[n]),hasPrevious:e=>e[e.length-1]>0,isAfter:(e,t)=>1===og.compare(e,t),isAncestor:(e,t)=>e.length<t.length&&0===og.compare(e,t),isBefore:(e,t)=>-1===og.compare(e,t),isChild:(e,t)=>e.length===t.length+1&&0===og.compare(e,t),isCommon:(e,t)=>e.length<=t.length&&0===og.compare(e,t),isDescendant:(e,t)=>e.length>t.length&&0===og.compare(e,t),isParent:(e,t)=>e.length+1===t.length&&0===og.compare(e,t),isPath:e=>Array.isArray(e)&&(0===e.length||"number"==typeof e[0]),isSibling(e,t){if(e.length!==t.length)return!1;var n=e.slice(0,-1),r=t.slice(0,-1);return e[e.length-1]!==t[t.length-1]&&og.equals(n,r)},levels(e){for(var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{reverse:n=!1}=t,r=[],o=0;o<=e.length;o++)r.push(e.slice(0,o));return n&&r.reverse(),r},next(e){if(0===e.length)throw new Error("Cannot get the next path of a root path [".concat(e,"], because it has no next index."));var t=e[e.length-1];return e.slice(0,-1).concat(t+1)},operationCanTransformPath(e){switch(e.type){case"insert_node":case"remove_node":case"merge_node":case"split_node":case"move_node":return!0;default:return!1}},parent(e){if(0===e.length)throw new Error("Cannot get the parent path of the root path [".concat(e,"]."));return e.slice(0,-1)},previous(e){if(0===e.length)throw new Error("Cannot get the previous path of a root path [".concat(e,"], because it has no previous index."));var t=e[e.length-1];if(t<=0)throw new Error("Cannot get the previous path of a first child path [".concat(e,"] because it would result in a negative index."));return e.slice(0,-1).concat(t-1)},relative(e,t){if(!og.isAncestor(t,e)&&!og.equals(e,t))throw new Error("Cannot get the relative path of [".concat(e,"] inside ancestor [").concat(t,"], because it is not above or equal to the path."));return e.slice(t.length)},transform(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return eh(e,r=>{var{affinity:o="forward"}=n;if(e&&0!==(null==e?void 0:e.length)){if(null===r)return null;switch(t.type){case"insert_node":var{path:i}=t;(og.equals(i,r)||og.endsBefore(i,r)||og.isAncestor(i,r))&&(r[i.length-1]+=1);break;case"remove_node":var{path:a}=t;if(og.equals(a,r)||og.isAncestor(a,r))return null;og.endsBefore(a,r)&&(r[a.length-1]-=1);break;case"merge_node":var{path:s,position:u}=t;og.equals(s,r)||og.endsBefore(s,r)?r[s.length-1]-=1:og.isAncestor(s,r)&&(r[s.length-1]-=1,r[s.length]+=u);break;case"split_node":var{path:l,position:c}=t;if(og.equals(l,r)){if("forward"===o)r[r.length-1]+=1;else if("backward"!==o)return null}else og.endsBefore(l,r)?r[l.length-1]+=1:og.isAncestor(l,r)&&e[l.length]>=c&&(r[l.length-1]+=1,r[l.length]-=c);break;case"move_node":var{path:d,newPath:f}=t;if(og.equals(d,f))return;if(og.isAncestor(d,r)||og.equals(d,r)){var p=f.slice();return og.endsBefore(d,f)&&d.length<f.length&&(p[d.length-1]-=1),p.concat(r.slice(d.length))}og.isSibling(d,f)&&(og.isAncestor(f,r)||og.equals(f,r))?og.endsBefore(d,r)?r[d.length-1]-=1:r[d.length-1]+=1:og.endsBefore(f,r)||og.equals(f,r)||og.isAncestor(f,r)?(og.endsBefore(d,r)&&(r[d.length-1]-=1),r[f.length-1]+=1):og.endsBefore(d,r)&&(og.equals(f,r)&&(r[f.length-1]+=1),r[d.length-1]-=1)}}})}},ig={transform(e,t){var{current:n,affinity:r}=e;if(null!=n){var o=og.transform(n,t,{affinity:r});e.current=o,null==o&&e.unref()}}};function ag(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function sg(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?ag(Object(n),!0).forEach(function(t){rh(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):ag(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}var ug={compare(e,t){var n=og.compare(e.path,t.path);return 0===n?e.offset<t.offset?-1:e.offset>t.offset?1:0:n},isAfter:(e,t)=>1===ug.compare(e,t),isBefore:(e,t)=>-1===ug.compare(e,t),equals:(e,t)=>e.offset===t.offset&&og.equals(e.path,t.path),isPoint:e=>op(e)&&"number"==typeof e.offset&&og.isPath(e.path),transform(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return eh(e,e=>{if(null===e)return null;var{affinity:r="forward"}=n,{path:o,offset:i}=e;switch(t.type){case"insert_node":case"move_node":e.path=og.transform(o,t,n);break;case"insert_text":og.equals(t.path,o)&&(t.offset<i||t.offset===i&&"forward"===r)&&(e.offset+=t.text.length);break;case"merge_node":og.equals(t.path,o)&&(e.offset+=t.position),e.path=og.transform(o,t,n);break;case"remove_text":og.equals(t.path,o)&&t.offset<=i&&(e.offset-=Math.min(i-t.offset,t.text.length));break;case"remove_node":if(og.equals(t.path,o)||og.isAncestor(t.path,o))return null;e.path=og.transform(o,t,n);break;case"split_node":if(og.equals(t.path,o)){if(t.position===i&&null==r)return null;(t.position<i||t.position===i&&"forward"===r)&&(e.offset-=t.position,e.path=og.transform(o,t,sg(sg({},n),{},{affinity:"forward"})))}else e.path=og.transform(o,t,n)}})}},lg={transform(e,t){var{current:n,affinity:r}=e;if(null!=n){var o=ug.transform(n,t,{affinity:r});e.current=o,null==o&&e.unref()}}},cg=["anchor","focus"];function dg(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}var fg={edges(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{reverse:n=!1}=t,{anchor:r,focus:o}=e;return fg.isBackward(e)===n?[r,o]:[o,r]},end(e){var[,t]=fg.edges(e);return t},equals:(e,t)=>ug.equals(e.anchor,t.anchor)&&ug.equals(e.focus,t.focus),includes(e,t){if(fg.isRange(t)){if(fg.includes(e,t.anchor)||fg.includes(e,t.focus))return!0;var[n,r]=fg.edges(e),[o,i]=fg.edges(t);return ug.isBefore(n,o)&&ug.isAfter(r,i)}var[a,s]=fg.edges(e),u=!1,l=!1;return ug.isPoint(t)?(u=ug.compare(t,a)>=0,l=ug.compare(t,s)<=0):(u=og.compare(t,a.path)>=0,l=og.compare(t,s.path)<=0),u&&l},intersection(e,t){var n=ph(e,cg),[r,o]=fg.edges(e),[i,a]=fg.edges(t),s=ug.isBefore(r,i)?i:r,u=ug.isBefore(o,a)?o:a;return ug.isBefore(u,s)?null:function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?dg(Object(n),!0).forEach(function(t){rh(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):dg(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}({anchor:s,focus:u},n)},isBackward(e){var{anchor:t,focus:n}=e;return ug.isAfter(t,n)},isCollapsed(e){var{anchor:t,focus:n}=e;return ug.equals(t,n)},isExpanded:e=>!fg.isCollapsed(e),isForward:e=>!fg.isBackward(e),isRange:e=>op(e)&&ug.isPoint(e.anchor)&&ug.isPoint(e.focus),*points(e){yield[e.anchor,"anchor"],yield[e.focus,"focus"]},start(e){var[t]=fg.edges(e);return t},transform(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return eh(e,e=>{if(null===e)return null;var r,o,{affinity:i="inward"}=n;if("inward"===i){var a=fg.isCollapsed(e);fg.isForward(e)?(r="forward",o=a?r:"backward"):(r="backward",o=a?r:"forward")}else"outward"===i?fg.isForward(e)?(r="backward",o="forward"):(r="forward",o="backward"):(r=i,o=i);var s=ug.transform(e.anchor,t,{affinity:r}),u=ug.transform(e.focus,t,{affinity:o});if(!s||!u)return null;e.anchor=s,e.focus=u})}},pg={transform(e,t){var{current:n,affinity:r}=e;if(null!=n){var o=fg.transform(n,t,{affinity:r});e.current=o,null==o&&e.unref()}}},hg=void 0,gg={setScrubber(e){hg=e},stringify:e=>JSON.stringify(e,hg)},vg=(e,t)=>{for(var n in e){var r=e[n],o=t[n];if(op(r)&&op(o)){if(!vg(r,o))return!1}else if(Array.isArray(r)&&Array.isArray(o)){if(r.length!==o.length)return!1;for(var i=0;i<r.length;i++)if(r[i]!==o[i])return!1}else if(r!==o)return!1}for(var a in t)if(void 0===e[a]&&void 0!==t[a])return!1;return!0},mg=["text"],yg=["anchor","focus"];function bg(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function Eg(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?bg(Object(n),!0).forEach(function(t){rh(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):bg(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}var Cg={equals(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},{loose:r=!1}=n;function o(e){return ph(e,mg)}return vg(r?o(e):e,r?o(t):t)},isText:e=>op(e)&&"string"==typeof e.text,isTextList:e=>Array.isArray(e)&&e.every(e=>Cg.isText(e)),isTextProps:e=>void 0!==e.text,matches(e,t){for(var n in t)if("text"!==n&&(!e.hasOwnProperty(n)||e[n]!==t[n]))return!1;return!0},decorations(e,t){var n=[Eg({},e)];for(var r of t){var o=ph(r,yg),[i,a]=fg.edges(r),s=[],u=0,l=i.offset,c=a.offset;for(var d of n){var{length:f}=d.text,p=u;if(u+=f,l<=p&&u<=c)Object.assign(d,o),s.push(d);else if(l!==c&&(l===u||c===p)||l>u||c<p||c===p&&0!==p)s.push(d);else{var h=d,g=void 0,v=void 0;if(c<u){var m=c-p;v=Eg(Eg({},h),{},{text:h.text.slice(m)}),h=Eg(Eg({},h),{},{text:h.text.slice(0,m)})}if(l>p){var y=l-p;g=Eg(Eg({},h),{},{text:h.text.slice(0,y)}),h=Eg(Eg({},h),{},{text:h.text.slice(y)})}Object.assign(h,o),g&&s.push(g),s.push(h),v&&s.push(v)}}n=s}return n}};function Dg(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function wg(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Dg(Object(n),!0).forEach(function(t){rh(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Dg(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}var Sg={transform(e,t){e.children=th(e.children);var n=e.selection&&th(e.selection);try{n=((e,t,n)=>{switch(n.type){case"insert_node":var{path:r,node:o}=n,i=eg.parent(e,r),a=r[r.length-1];if(a>i.children.length)throw new Error('Cannot apply an "insert_node" operation at path ['.concat(r,"] because the destination is past the end of the node."));if(i.children.splice(a,0,o),t)for(var[s,u]of fg.points(t))t[u]=ug.transform(s,n);break;case"insert_text":var{path:l,offset:c,text:d}=n;if(0===d.length)break;var f=eg.leaf(e,l),p=f.text.slice(0,c),h=f.text.slice(c);if(f.text=p+d+h,t)for(var[g,v]of fg.points(t))t[v]=ug.transform(g,n);break;case"merge_node":var{path:m}=n,y=eg.get(e,m),b=og.previous(m),E=eg.get(e,b),C=eg.parent(e,m),D=m[m.length-1];if(Cg.isText(y)&&Cg.isText(E))E.text+=y.text;else{if(Cg.isText(y)||Cg.isText(E))throw new Error('Cannot apply a "merge_node" operation at path ['.concat(m,"] to nodes of different interfaces: ").concat(gg.stringify(y)," ").concat(gg.stringify(E)));E.children.push(...y.children)}if(C.children.splice(D,1),t)for(var[w,S]of fg.points(t))t[S]=ug.transform(w,n);break;case"move_node":var{path:A,newPath:x}=n;if(og.isAncestor(A,x))throw new Error("Cannot move a path [".concat(A,"] to new path [").concat(x,"] because the destination is inside itself."));var O=eg.get(e,A),N=eg.parent(e,A),B=A[A.length-1];N.children.splice(B,1);var T=og.transform(A,n),k=eg.get(e,og.parent(T)),F=T[T.length-1];if(k.children.splice(F,0,O),t)for(var[I,P]of fg.points(t))t[P]=ug.transform(I,n);break;case"remove_node":var{path:_}=n,L=_[_.length-1];if(eg.parent(e,_).children.splice(L,1),t)for(var[R,M]of fg.points(t)){var j=ug.transform(R,n);if(null!=t&&null!=j)t[M]=j;else{var H=void 0,z=void 0;for(var[$,U]of eg.texts(e)){if(-1!==og.compare(U,_)){z=[$,U];break}H=[$,U]}var V=!1;H&&z&&(V=og.equals(z[1],_)?!og.hasPrevious(z[1]):og.common(H[1],_).length<og.common(z[1],_).length),H&&!V?(R.path=H[1],R.offset=H[0].text.length):z?(R.path=z[1],R.offset=0):t=null}}break;case"remove_text":var{path:W,offset:G,text:q}=n;if(0===q.length)break;var K=eg.leaf(e,W),Y=K.text.slice(0,G),X=K.text.slice(G+q.length);if(K.text=Y+X,t)for(var[Z,J]of fg.points(t))t[J]=ug.transform(Z,n);break;case"set_node":var{path:Q,properties:ee,newProperties:te}=n;if(0===Q.length)throw new Error("Cannot set properties on the root node!");var ne=eg.get(e,Q);for(var re in te){if("children"===re||"text"===re)throw new Error('Cannot set the "'.concat(re,'" property of nodes!'));var oe=te[re];null==oe?delete ne[re]:ne[re]=oe}for(var ie in ee)te.hasOwnProperty(ie)||delete ne[ie];break;case"set_selection":var{newProperties:ae}=n;if(null==ae)t=ae;else{if(null==t){if(!fg.isRange(ae))throw new Error('Cannot apply an incomplete "set_selection" operation properties '.concat(gg.stringify(ae)," when there is no current selection."));t=wg({},ae)}for(var se in ae){var ue=ae[se];if(null==ue){if("anchor"===se||"focus"===se)throw new Error('Cannot remove the "'.concat(se,'" selection property'));delete t[se]}else t[se]=ue}}break;case"split_node":var{path:le,position:ce,properties:de}=n;if(0===le.length)throw new Error('Cannot apply a "split_node" operation at path ['.concat(le,"] because the root node cannot be split."));var fe,pe=eg.get(e,le),he=eg.parent(e,le),ge=le[le.length-1];if(Cg.isText(pe)){var ve=pe.text.slice(0,ce),me=pe.text.slice(ce);pe.text=ve,fe=wg(wg({},de),{},{text:me})}else{var ye=pe.children.slice(0,ce),be=pe.children.slice(ce);pe.children=ye,fe=wg(wg({},de),{},{children:be})}if(he.children.splice(ge+1,0,fe),t)for(var[Ee,Ce]of fg.points(t))t[Ce]=ug.transform(Ee,n)}return t})(e,n,t)}finally{e.children=nh(e.children),e.selection=n?ap(n)?nh(n):n:null}}},Ag=["text"],xg=["children"];function Og(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function Ng(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Og(Object(n),!0).forEach(function(t){rh(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Og(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}var Bg={insertNodes(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};Kh.withoutNormalizing(e,()=>{var{hanging:r=!1,voids:o=!1,mode:i="lowest"}=n,{at:a,match:s,select:u}=n;if(eg.isNode(t)&&(t=[t]),0!==t.length){var[l]=t;if(a||(a=e.selection?e.selection:e.children.length>0?Kh.end(e,[]):[0],u=!0),null==u&&(u=!1),fg.isRange(a))if(r||(a=Kh.unhangRange(e,a)),fg.isCollapsed(a))a=a.anchor;else{var[,c]=fg.edges(a),d=Kh.pointRef(e,c);jg.delete(e,{at:a}),a=d.unref()}if(ug.isPoint(a)){null==s&&(s=Cg.isText(l)?e=>Cg.isText(e):e.isInline(l)?t=>Cg.isText(t)||Kh.isInline(e,t):t=>Kh.isBlock(e,t));var[f]=Kh.nodes(e,{at:a.path,match:s,mode:i,voids:o});if(!f)return;var[,p]=f,h=Kh.pathRef(e,p),g=Kh.isEnd(e,a,p);jg.splitNodes(e,{at:a,match:s,mode:i,voids:o});var v=h.unref();a=g?og.next(v):v}var m=og.parent(a),y=a[a.length-1];if(o||!Kh.void(e,{at:m})){for(var b of t){var E=m.concat(y);y++,e.apply({type:"insert_node",path:E,node:b}),a=og.next(a)}if(a=og.previous(a),u){var C=Kh.end(e,a);C&&jg.select(e,C)}}}})},liftNodes(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};Kh.withoutNormalizing(e,()=>{var{at:n=e.selection,mode:r="lowest",voids:o=!1}=t,{match:i}=t;if(null==i&&(i=og.isPath(n)?Fg(e,n):t=>Kh.isBlock(e,t)),n){var a=Kh.nodes(e,{at:n,match:i,mode:r,voids:o}),s=Array.from(a,t=>{var[,n]=t;return Kh.pathRef(e,n)});for(var u of s){var l=u.unref();if(l.length<2)throw new Error("Cannot lift node at a path [".concat(l,"] because it has a depth of less than `2`."));var c=Kh.node(e,og.parent(l)),[d,f]=c,p=l[l.length-1],{length:h}=d.children;if(1===h){var g=og.next(f);jg.moveNodes(e,{at:l,to:g,voids:o}),jg.removeNodes(e,{at:f,voids:o})}else if(0===p)jg.moveNodes(e,{at:l,to:f,voids:o});else if(p===h-1){var v=og.next(f);jg.moveNodes(e,{at:l,to:v,voids:o})}else{var m=og.next(l),y=og.next(f);jg.splitNodes(e,{at:m,voids:o}),jg.moveNodes(e,{at:l,to:y,voids:o})}}}})},mergeNodes(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};Kh.withoutNormalizing(e,()=>{var{match:n,at:r=e.selection}=t,{hanging:o=!1,voids:i=!1,mode:a="lowest"}=t;if(r){if(null==n)if(og.isPath(r)){var[s]=Kh.parent(e,r);n=e=>s.children.includes(e)}else n=t=>Kh.isBlock(e,t);if(!o&&fg.isRange(r)&&(r=Kh.unhangRange(e,r)),fg.isRange(r))if(fg.isCollapsed(r))r=r.anchor;else{var[,u]=fg.edges(r),l=Kh.pointRef(e,u);jg.delete(e,{at:r}),r=l.unref(),null==t.at&&jg.select(e,r)}var[c]=Kh.nodes(e,{at:r,match:n,voids:i,mode:a}),d=Kh.previous(e,{at:r,match:n,voids:i,mode:a});if(c&&d){var[f,p]=c,[h,g]=d;if(0!==p.length&&0!==g.length){var v,m,y=og.next(g),b=og.common(p,g),E=og.isSibling(p,g),C=Array.from(Kh.levels(e,{at:p}),e=>{var[t]=e;return t}).slice(b.length).slice(0,-1),D=Kh.above(e,{at:p,mode:"highest",match:t=>C.includes(t)&&Tg(e,t)}),w=D&&Kh.pathRef(e,D[1]);if(Cg.isText(f)&&Cg.isText(h)){var S=ph(f,Ag);m=h.text.length,v=S}else{if(!$h.isElement(f)||!$h.isElement(h))throw new Error("Cannot merge the node at path [".concat(p,"] with the previous sibling because it is not the same kind: ").concat(gg.stringify(f)," ").concat(gg.stringify(h)));S=ph(f,xg);m=h.children.length,v=S}E||jg.moveNodes(e,{at:p,to:y,voids:i}),w&&jg.removeNodes(e,{at:w.current,voids:i}),$h.isElement(h)&&Kh.isEmpty(e,h)||Cg.isText(h)&&""===h.text&&0!==g[g.length-1]?jg.removeNodes(e,{at:g,voids:i}):e.apply({type:"merge_node",path:y,position:m,properties:v}),w&&w.unref()}}}})},moveNodes(e,t){Kh.withoutNormalizing(e,()=>{var{to:n,at:r=e.selection,mode:o="lowest",voids:i=!1}=t,{match:a}=t;if(r){null==a&&(a=og.isPath(r)?Fg(e,r):t=>Kh.isBlock(e,t));var s=Kh.pathRef(e,n),u=Kh.nodes(e,{at:r,match:a,mode:o,voids:i}),l=Array.from(u,t=>{var[,n]=t;return Kh.pathRef(e,n)});for(var c of l){var d=c.unref(),f=s.current;0!==d.length&&e.apply({type:"move_node",path:d,newPath:f}),s.current&&og.isSibling(f,d)&&og.isAfter(f,d)&&(s.current=og.next(s.current))}s.unref()}})},removeNodes(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};Kh.withoutNormalizing(e,()=>{var{hanging:n=!1,voids:r=!1,mode:o="lowest"}=t,{at:i=e.selection,match:a}=t;if(i){null==a&&(a=og.isPath(i)?Fg(e,i):t=>Kh.isBlock(e,t)),!n&&fg.isRange(i)&&(i=Kh.unhangRange(e,i));var s=Kh.nodes(e,{at:i,match:a,mode:o,voids:r}),u=Array.from(s,t=>{var[,n]=t;return Kh.pathRef(e,n)});for(var l of u){var c=l.unref();if(c){var[d]=Kh.node(e,c);e.apply({type:"remove_node",path:c,node:d})}}}})},setNodes(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};Kh.withoutNormalizing(e,()=>{var{match:r,at:o=e.selection,compare:i,merge:a}=n,{hanging:s=!1,mode:u="lowest",split:l=!1,voids:c=!1}=n;if(o){if(null==r&&(r=og.isPath(o)?Fg(e,o):t=>Kh.isBlock(e,t)),!s&&fg.isRange(o)&&(o=Kh.unhangRange(e,o)),l&&fg.isRange(o)){if(fg.isCollapsed(o)&&Kh.leaf(e,o.anchor)[0].text.length>0)return;var d=Kh.rangeRef(e,o,{affinity:"inward"}),[f,p]=fg.edges(o),h="lowest"===u?"lowest":"highest",g=Kh.isEnd(e,p,p.path);jg.splitNodes(e,{at:p,match:r,mode:h,voids:c,always:!g});var v=Kh.isStart(e,f,f.path);jg.splitNodes(e,{at:f,match:r,mode:h,voids:c,always:!v}),o=d.unref(),null==n.at&&jg.select(e,o)}for(var[m,y]of(i||(i=(e,t)=>e!==t),Kh.nodes(e,{at:o,match:r,mode:u,voids:c}))){var b={},E={};if(0!==y.length){var C=!1;for(var D in t)"children"!==D&&"text"!==D&&i(t[D],m[D])&&(C=!0,m.hasOwnProperty(D)&&(b[D]=m[D]),a?null!=t[D]&&(E[D]=a(m[D],t[D])):null!=t[D]&&(E[D]=t[D]));C&&e.apply({type:"set_node",path:y,properties:b,newProperties:E})}}}})},splitNodes(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};Kh.withoutNormalizing(e,()=>{var{mode:n="lowest",voids:r=!1}=t,{match:o,at:i=e.selection,height:a=0,always:s=!1}=t;if(null==o&&(o=t=>Kh.isBlock(e,t)),fg.isRange(i)&&(i=kg(e,i)),og.isPath(i)){var u=i,l=Kh.point(e,u),[c]=Kh.parent(e,u);o=e=>e===c,a=l.path.length-u.length+1,i=l,s=!0}if(i){var d,f=Kh.pointRef(e,i,{affinity:"backward"});try{var[p]=Kh.nodes(e,{at:i,match:o,mode:n,voids:r});if(!p)return;var h=Kh.void(e,{at:i,mode:"highest"});if(!r&&h){var[g,v]=h;if($h.isElement(g)&&e.isInline(g)){var m=Kh.after(e,v);if(!m){var y=og.next(v);jg.insertNodes(e,{text:""},{at:y,voids:r}),m=Kh.point(e,y)}i=m,s=!0}a=i.path.length-v.length+1,s=!0}d=Kh.pointRef(e,i);var b=i.path.length-a,[,E]=p,C=i.path.slice(0,b),D=0===a?i.offset:i.path[b]+0;for(var[w,S]of Kh.levels(e,{at:C,reverse:!0,voids:r})){var A=!1;if(S.length<E.length||0===S.length||!r&&Kh.isVoid(e,w))break;var x=f.current,O=Kh.isEnd(e,x,S);if(s||!f||!Kh.isEdge(e,x,S)){A=!0;var N=eg.extractProps(w);e.apply({type:"split_node",path:S,position:D,properties:N})}D=S[S.length-1]+(A||O?1:0)}if(null==t.at){var B=d.current||Kh.end(e,[]);jg.select(e,B)}}finally{var T;f.unref(),null===(T=d)||void 0===T||T.unref()}}})},unsetNodes(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};Array.isArray(t)||(t=[t]);var r={};for(var o of t)r[o]=null;jg.setNodes(e,r,n)},unwrapNodes(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};Kh.withoutNormalizing(e,()=>{var{mode:n="lowest",split:r=!1,voids:o=!1}=t,{at:i=e.selection,match:a}=t;if(i){null==a&&(a=og.isPath(i)?Fg(e,i):t=>Kh.isBlock(e,t)),og.isPath(i)&&(i=Kh.range(e,i));var s=fg.isRange(i)?Kh.rangeRef(e,i):null,u=Kh.nodes(e,{at:i,match:a,mode:n,voids:o}),l=Array.from(u,t=>{var[,n]=t;return Kh.pathRef(e,n)}).reverse(),c=function(t){var n=t.unref(),[i]=Kh.node(e,n),a=Kh.range(e,n);r&&s&&(a=fg.intersection(s.current,a)),jg.liftNodes(e,{at:a,match:e=>$h.isAncestor(i)&&i.children.includes(e),voids:o})};for(var d of l)c(d);s&&s.unref()}})},wrapNodes(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};Kh.withoutNormalizing(e,()=>{var{mode:r="lowest",split:o=!1,voids:i=!1}=n,{match:a,at:s=e.selection}=n;if(s){if(null==a&&(a=og.isPath(s)?Fg(e,s):e.isInline(t)?t=>Kh.isInline(e,t)||Cg.isText(t):t=>Kh.isBlock(e,t)),o&&fg.isRange(s)){var[u,l]=fg.edges(s),c=Kh.rangeRef(e,s,{affinity:"inward"});jg.splitNodes(e,{at:l,match:a,voids:i}),jg.splitNodes(e,{at:u,match:a,voids:i}),s=c.unref(),null==n.at&&jg.select(e,s)}var d=Array.from(Kh.nodes(e,{at:s,match:e.isInline(t)?t=>Kh.isBlock(e,t):e=>Kh.isEditor(e),mode:"lowest",voids:i}));for(var[,f]of d){var p=fg.isRange(s)?fg.intersection(s,Kh.range(e,f)):s;if(p){var h=Array.from(Kh.nodes(e,{at:p,match:a,mode:r,voids:i}));if(h.length>0){var g=function(){var[n]=h,r=h[h.length-1],[,o]=n,[,a]=r;if(0===o.length&&0===a.length)return"continue";var s=og.equals(o,a)?og.parent(o):og.common(o,a),u=Kh.range(e,o,a),l=Kh.node(e,s),[c]=l,d=s.length+1,f=og.next(a.slice(0,d)),p=Ng(Ng({},t),{},{children:[]});jg.insertNodes(e,p,{at:f,voids:i}),jg.moveNodes(e,{at:u,match:e=>$h.isAncestor(c)&&c.children.includes(e),to:f.concat(0),voids:i})}();if("continue"===g)continue}}}}})}},Tg=(e,t)=>{if($h.isElement(t)){var n=t;return!!Kh.isVoid(e,t)||1===n.children.length&&Tg(e,n.children[0])}return!Kh.isEditor(t)},kg=(e,t)=>{if(fg.isCollapsed(t))return t.anchor;var[,n]=fg.edges(t),r=Kh.pointRef(e,n);return jg.delete(e,{at:t}),r.unref()},Fg=(e,t)=>{var[n]=Kh.node(e,t);return e=>e===n};function Ig(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function Pg(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Ig(Object(n),!0).forEach(function(t){rh(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Ig(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}var _g={collapse(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{edge:n="anchor"}=t,{selection:r}=e;if(r)if("anchor"===n)jg.select(e,r.anchor);else if("focus"===n)jg.select(e,r.focus);else if("start"===n){var[o]=fg.edges(r);jg.select(e,o)}else if("end"===n){var[,i]=fg.edges(r);jg.select(e,i)}},deselect(e){var{selection:t}=e;t&&e.apply({type:"set_selection",properties:t,newProperties:null})},move(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{selection:n}=e,{distance:r=1,unit:o="character",reverse:i=!1}=t,{edge:a=null}=t;if(n){"start"===a&&(a=fg.isBackward(n)?"focus":"anchor"),"end"===a&&(a=fg.isBackward(n)?"anchor":"focus");var{anchor:s,focus:u}=n,l={distance:r,unit:o},c={};if(null==a||"anchor"===a){var d=i?Kh.before(e,s,l):Kh.after(e,s,l);d&&(c.anchor=d)}if(null==a||"focus"===a){var f=i?Kh.before(e,u,l):Kh.after(e,u,l);f&&(c.focus=f)}jg.setSelection(e,c)}},select(e,t){var{selection:n}=e;if(t=Kh.range(e,t),n)jg.setSelection(e,t);else{if(!fg.isRange(t))throw new Error("When setting the selection and the current selection is `null` you must provide at least an `anchor` and `focus`, but you passed: ".concat(gg.stringify(t)));e.apply({type:"set_selection",properties:n,newProperties:t})}},setPoint(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},{selection:r}=e,{edge:o="both"}=n;if(r){"start"===o&&(o=fg.isBackward(r)?"focus":"anchor"),"end"===o&&(o=fg.isBackward(r)?"anchor":"focus");var{anchor:i,focus:a}=r,s="anchor"===o?i:a;jg.setSelection(e,{["anchor"===o?"anchor":"focus"]:Pg(Pg({},s),t)})}},setSelection(e,t){var{selection:n}=e,r={},o={};if(n){for(var i in t)("anchor"===i&&null!=t.anchor&&!ug.equals(t.anchor,n.anchor)||"focus"===i&&null!=t.focus&&!ug.equals(t.focus,n.focus)||"anchor"!==i&&"focus"!==i&&t[i]!==n[i])&&(r[i]=n[i],o[i]=t[i]);Object.keys(r).length>0&&e.apply({type:"set_selection",properties:r,newProperties:o})}}},Lg={delete(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};Kh.withoutNormalizing(e,()=>{var{reverse:n=!1,unit:r="character",distance:o=1,voids:i=!1}=t,{at:a=e.selection,hanging:s=!1}=t;if(a){var u=!1;if(fg.isRange(a)&&fg.isCollapsed(a)&&(u=!0,a=a.anchor),ug.isPoint(a)){var l=Kh.void(e,{at:a,mode:"highest"});if(!i&&l){var[,c]=l;a=c}else{var d={unit:r,distance:o};a={anchor:a,focus:n?Kh.before(e,a,d)||Kh.start(e,[]):Kh.after(e,a,d)||Kh.end(e,[])},s=!0}}if(og.isPath(a))jg.removeNodes(e,{at:a,voids:i});else if(!fg.isCollapsed(a)){if(!s){var[,f]=fg.edges(a),p=Kh.end(e,[]);ug.equals(f,p)||(a=Kh.unhangRange(e,a,{voids:i}))}var[h,g]=fg.edges(a),v=Kh.above(e,{match:t=>Kh.isBlock(e,t),at:h,voids:i}),m=Kh.above(e,{match:t=>Kh.isBlock(e,t),at:g,voids:i}),y=v&&m&&!og.equals(v[1],m[1]),b=og.equals(h.path,g.path),E=i?null:Kh.void(e,{at:h,mode:"highest"}),C=i?null:Kh.void(e,{at:g,mode:"highest"});if(E){var D=Kh.before(e,h);D&&v&&og.isAncestor(v[1],D.path)&&(h=D)}if(C){var w=Kh.after(e,g);w&&m&&og.isAncestor(m[1],w.path)&&(g=w)}var S,A=[];for(var x of Kh.nodes(e,{at:a,voids:i})){var[O,N]=x;S&&0===og.compare(N,S)||(!i&&Kh.isVoid(e,O)||!og.isCommon(N,h.path)&&!og.isCommon(N,g.path))&&(A.push(x),S=N)}var B=Array.from(A,t=>{var[,n]=t;return Kh.pathRef(e,n)}),T=Kh.pointRef(e,h),k=Kh.pointRef(e,g),F="";if(!b&&!E){var I=T.current,[P]=Kh.leaf(e,I),{path:_}=I,{offset:L}=h,R=P.text.slice(L);R.length>0&&(e.apply({type:"remove_text",path:_,offset:L,text:R}),F=R)}for(var M of B){var j=M.unref();jg.removeNodes(e,{at:j,voids:i})}if(!C){var H=k.current,[z]=Kh.leaf(e,H),{path:$}=H,U=b?h.offset:0,V=z.text.slice(U,g.offset);V.length>0&&(e.apply({type:"remove_text",path:$,offset:U,text:V}),F=V)}!b&&y&&k.current&&T.current&&jg.mergeNodes(e,{at:k.current,hanging:!0,voids:i}),u&&n&&"character"===r&&F.length>1&&F.match(/[\u0E00-\u0E7F]+/)&&jg.insertText(e,F.slice(0,F.length-o));var W=T.unref(),G=k.unref(),q=n?W||G:G||W;null==t.at&&q&&jg.select(e,q)}}})},insertFragment(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};Kh.withoutNormalizing(e,()=>{var{hanging:r=!1,voids:o=!1}=n,{at:i=e.selection}=n;if(t.length&&i){if(fg.isRange(i))if(r||(i=Kh.unhangRange(e,i)),fg.isCollapsed(i))i=i.anchor;else{var[,a]=fg.edges(i);if(!o&&Kh.void(e,{at:a}))return;var s=Kh.pointRef(e,a);jg.delete(e,{at:i}),i=s.unref()}else og.isPath(i)&&(i=Kh.start(e,i));if(o||!Kh.void(e,{at:i})){var u=Kh.above(e,{at:i,match:t=>Kh.isInline(e,t),mode:"highest",voids:o});if(u){var[,l]=u;if(Kh.isEnd(e,i,l))i=Kh.after(e,l);else if(Kh.isStart(e,i,l)){i=Kh.before(e,l)}}var c=Kh.above(e,{match:t=>Kh.isBlock(e,t),at:i,voids:o}),[,d]=c,f=Kh.isStart(e,i,d),p=Kh.isEnd(e,i,d),h=f&&p,g=!f||f&&p,v=!p,[,m]=eg.first({children:t},[]),[,y]=eg.last({children:t},[]),b=[],E=t=>{var[n,r]=t;return!(0===r.length)&&(!!h||!(g&&og.isAncestor(r,m)&&$h.isElement(n)&&!e.isVoid(n)&&!e.isInline(n))&&!(v&&og.isAncestor(r,y)&&$h.isElement(n)&&!e.isVoid(n)&&!e.isInline(n)))};for(var C of eg.nodes({children:t},{pass:E}))E(C)&&b.push(C);var D=[],w=[],S=[],A=!0,x=!1;for(var[O]of b)$h.isElement(O)&&!e.isInline(O)?(A=!1,x=!0,w.push(O)):A?D.push(O):S.push(O);var[N]=Kh.nodes(e,{at:i,match:t=>Cg.isText(t)||Kh.isInline(e,t),mode:"highest",voids:o}),[,B]=N,T=Kh.isStart(e,i,B),k=Kh.isEnd(e,i,B),F=Kh.pathRef(e,p&&!S.length?og.next(d):d),I=Kh.pathRef(e,k?og.next(B):B);jg.splitNodes(e,{at:i,match:t=>x?Kh.isBlock(e,t):Cg.isText(t)||Kh.isInline(e,t),mode:x?"lowest":"highest",always:x&&(!f||D.length>0)&&(!p||S.length>0),voids:o});var P,_=Kh.pathRef(e,!T||T&&k?og.next(B):B);if(jg.insertNodes(e,D,{at:_.current,match:t=>Cg.isText(t)||Kh.isInline(e,t),mode:"highest",voids:o}),h&&!D.length&&w.length&&!S.length&&jg.delete(e,{at:d,voids:o}),jg.insertNodes(e,w,{at:F.current,match:t=>Kh.isBlock(e,t),mode:"lowest",voids:o}),jg.insertNodes(e,S,{at:I.current,match:t=>Cg.isText(t)||Kh.isInline(e,t),mode:"highest",voids:o}),!n.at)if(S.length>0&&I.current?P=og.previous(I.current):w.length>0&&F.current?P=og.previous(F.current):_.current&&(P=og.previous(_.current)),P){var L=Kh.end(e,P);jg.select(e,L)}_.unref(),F.unref(),I.unref()}}})},insertText(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};Kh.withoutNormalizing(e,()=>{var{voids:r=!1}=n,{at:o=e.selection}=n;if(o){if(og.isPath(o)&&(o=Kh.range(e,o)),fg.isRange(o))if(fg.isCollapsed(o))o=o.anchor;else{var i=fg.end(o);if(!r&&Kh.void(e,{at:i}))return;var a=fg.start(o),s=Kh.pointRef(e,a),u=Kh.pointRef(e,i);jg.delete(e,{at:o,voids:r});var l=s.unref(),c=u.unref();o=l||c,jg.setSelection(e,{anchor:o,focus:o})}if(r||!Kh.void(e,{at:o})){var{path:d,offset:f}=o;t.length>0&&e.apply({type:"insert_text",path:d,offset:f,text:t})}}})}};function Rg(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),n.push.apply(n,r)}return n}function Mg(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?Rg(Object(n),!0).forEach(function(t){rh(e,t,n[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Rg(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}var jg=Mg(Mg(Mg(Mg({},Sg),Bg),_g),Lg),Hg={isHistory:e=>op(e)&&Array.isArray(e.redos)&&Array.isArray(e.undos)&&(0===e.redos.length||rg.isOperationList(e.redos[0].operations))&&(0===e.undos.length||rg.isOperationList(e.undos[0].operations))},zg=new WeakMap,$g=new WeakMap,Ug={isHistoryEditor:e=>Hg.isHistory(e.history)&&Kh.isEditor(e),isMerging:e=>$g.get(e),isSaving:e=>zg.get(e),redo(e){e.redo()},undo(e){e.undo()},withMerging(e,t){var n=Ug.isMerging(e);$g.set(e,!0),t(),$g.set(e,n)},withoutMerging(e,t){var n=Ug.isMerging(e);$g.set(e,!1),t(),$g.set(e,n)},withoutSaving(e,t){var n=Ug.isSaving(e);zg.set(e,!1),t(),zg.set(e,n)}},Vg=e=>{var t=e,{apply:n}=t;return t.history={undos:[],redos:[]},t.redo=()=>{var{history:e}=t,{redos:n}=e;if(n.length>0){var r=n[n.length-1];r.selectionBefore&&jg.setSelection(t,r.selectionBefore),Ug.withoutSaving(t,()=>{Kh.withoutNormalizing(t,()=>{for(var e of r.operations)t.apply(e)})}),e.redos.pop(),t.writeHistory("undos",r)}},t.undo=()=>{var{history:e}=t,{undos:n}=e;if(n.length>0){var r=n[n.length-1];Ug.withoutSaving(t,()=>{Kh.withoutNormalizing(t,()=>{var e=r.operations.map(rg.inverse).reverse();for(var n of e)t.apply(n);r.selectionBefore&&jg.setSelection(t,r.selectionBefore)})}),t.writeHistory("redos",r),e.undos.pop()}},t.apply=e=>{var{operations:r,history:o}=t,{undos:i}=o,a=i[i.length-1],s=a&&a.operations[a.operations.length-1],u=Ug.isSaving(t),l=Ug.isMerging(t);if(null==u&&(u=Gg(e)),u){if(null==l&&(l=null!=a&&(0!==r.length||Wg(e,s))),a&&l)a.operations.push(e);else{var c={operations:[e],selectionBefore:t.selection};t.writeHistory("undos",c)}for(;i.length>100;)i.shift();o.redos=[]}n(e)},t.writeHistory=(e,n)=>{t.history[e].push(n)},t},Wg=(e,t)=>!(!t||"insert_text"!==e.type||"insert_text"!==t.type||e.offset!==t.offset+t.text.length||!og.equals(e.path,t.path))||!(!t||"remove_text"!==e.type||"remove_text"!==t.type||e.offset+e.text.length!==t.offset||!og.equals(e.path,t.path)),Gg=(e,t)=>"set_selection"!==e.type,qg=function(e,t){return qg=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])},qg(e,t)};function Kg(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}qg(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}var Yg=function(){return Yg=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e},Yg.apply(this,arguments)};function Xg(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(r=Object.getOwnPropertySymbols(e);o<r.length;o++)t.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]])}return n}function Zg(e,t,n,r){return new(n||(n=Promise))(function(o,i){function a(e){try{u(r.next(e))}catch(e){i(e)}}function s(e){try{u(r.throw(e))}catch(e){i(e)}}function u(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n(function(e){e(t)})).then(a,s)}u((r=r.apply(e,t||[])).next())})}function Jg(e,t){var n,r,o,i={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]},a=Object.create(("function"==typeof Iterator?Iterator:Object).prototype);return a.next=s(0),a.throw=s(1),a.return=s(2),"function"==typeof Symbol&&(a[Symbol.iterator]=function(){return this}),a;function s(s){return function(u){return function(s){if(n)throw new TypeError("Generator is already executing.");for(;a&&(a=0,s[0]&&(i=0)),i;)try{if(n=1,r&&(o=2&s[0]?r.return:s[0]?r.throw||((o=r.return)&&o.call(r),0):r.next)&&!(o=o.call(r,s[1])).done)return o;switch(r=0,o&&(s=[2&s[0],o.value]),s[0]){case 0:case 1:o=s;break;case 4:return i.label++,{value:s[1],done:!1};case 5:i.label++,r=s[1],s=[0];continue;case 7:s=i.ops.pop(),i.trys.pop();continue;default:if(!(o=i.trys,(o=o.length>0&&o[o.length-1])||6!==s[0]&&2!==s[0])){i=0;continue}if(3===s[0]&&(!o||s[1]>o[0]&&s[1]<o[3])){i.label=s[1];break}if(6===s[0]&&i.label<o[1]){i.label=o[1],o=s;break}if(o&&i.label<o[2]){i.label=o[2],i.ops.push(s);break}o[2]&&i.ops.pop(),i.trys.pop();continue}s=t.call(e,i)}catch(e){s=[6,e],r=0}finally{n=o=0}if(5&s[0])throw s[1];return{value:s[0]?s[1]:void 0,done:!0}}([s,u])}}}function Qg(e){var t="function"==typeof Symbol&&Symbol.iterator,n=t&&e[t],r=0;if(n)return n.call(e);if(e&&"number"==typeof e.length)return{next:function(){return e&&r>=e.length&&(e=void 0),{value:e&&e[r++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}function ev(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,o,i=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=i.next()).done;)a.push(r.value)}catch(e){o={error:e}}finally{try{r&&!r.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return a}function tv(e,t,n){if(n||2===arguments.length)for(var r,o=0,i=t.length;o<i;o++)!r&&o in t||(r||(r=Array.prototype.slice.call(t,0,o)),r[o]=t[o]);return e.concat(r||Array.prototype.slice.call(t))}function nv(e){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var t,n=e[Symbol.asyncIterator];return n?n.call(e):(e=Qg(e),t={},r("next"),r("throw"),r("return"),t[Symbol.asyncIterator]=function(){return this},t);function r(n){t[n]=e[n]&&function(t){return new Promise(function(r,o){(function(e,t,n,r){Promise.resolve(r).then(function(t){e({value:t,done:n})},t)})(r,o,(t=e[n](t)).done,t.value)})}}}"function"==typeof SuppressedError&&SuppressedError;var rv,ov={exports:{}};var iv,av,sv=(rv||(rv=1,function(e,t){var n="__lodash_hash_undefined__",r=9007199254740991,o="[object Arguments]",i="[object Boolean]",a="[object Date]",s="[object Function]",u="[object GeneratorFunction]",l="[object Map]",c="[object Number]",d="[object Object]",f="[object Promise]",p="[object RegExp]",h="[object Set]",g="[object String]",v="[object Symbol]",m="[object WeakMap]",b="[object ArrayBuffer]",E="[object DataView]",C="[object Float32Array]",D="[object Float64Array]",w="[object Int8Array]",S="[object Int16Array]",A="[object Int32Array]",x="[object Uint8Array]",O="[object Uint8ClampedArray]",N="[object Uint16Array]",B="[object Uint32Array]",T=/\w*$/,k=/^\[object .+?Constructor\]$/,F=/^(?:0|[1-9]\d*)$/,I={};I[o]=I["[object Array]"]=I[b]=I[E]=I[i]=I[a]=I[C]=I[D]=I[w]=I[S]=I[A]=I[l]=I[c]=I[d]=I[p]=I[h]=I[g]=I[v]=I[x]=I[O]=I[N]=I[B]=!0,I["[object Error]"]=I[s]=I[m]=!1;var P="object"==typeof y&&y&&y.Object===Object&&y,_="object"==typeof self&&self&&self.Object===Object&&self,L=P||_||Function("return this")(),R=t&&!t.nodeType&&t,M=R&&e&&!e.nodeType&&e,j=M&&M.exports===R;function H(e,t){return e.set(t[0],t[1]),e}function z(e,t){return e.add(t),e}function $(e,t,n,r){for(var o=-1,i=e?e.length:0;++o<i;)n=t(n,e[o],o,e);return n}function U(e){var t=!1;if(null!=e&&"function"!=typeof e.toString)try{t=!!(e+"")}catch(e){}return t}function V(e){var t=-1,n=Array(e.size);return e.forEach(function(e,r){n[++t]=[r,e]}),n}function W(e,t){return function(n){return e(t(n))}}function G(e){var t=-1,n=Array(e.size);return e.forEach(function(e){n[++t]=e}),n}var q=Array.prototype,K=Function.prototype,Y=Object.prototype,X=L["__core-js_shared__"],Z=function(){var e=/[^.]+$/.exec(X&&X.keys&&X.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""}(),J=K.toString,Q=Y.hasOwnProperty,ee=Y.toString,te=RegExp("^"+J.call(Q).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),ne=j?L.Buffer:void 0,re=L.Symbol,oe=L.Uint8Array,ie=W(Object.getPrototypeOf,Object),ae=Object.create,se=Y.propertyIsEnumerable,ue=q.splice,le=Object.getOwnPropertySymbols,ce=ne?ne.isBuffer:void 0,de=W(Object.keys,Object),fe=Re(L,"DataView"),pe=Re(L,"Map"),he=Re(L,"Promise"),ge=Re(L,"Set"),ve=Re(L,"WeakMap"),me=Re(Object,"create"),ye=$e(fe),be=$e(pe),Ee=$e(he),Ce=$e(ge),De=$e(ve),we=re?re.prototype:void 0,Se=we?we.valueOf:void 0;function Ae(e){var t=-1,n=e?e.length:0;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}function xe(e){var t=-1,n=e?e.length:0;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}function Oe(e){var t=-1,n=e?e.length:0;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}function Ne(e){this.__data__=new xe(e)}function Be(e,t){var n=Ve(e)||function(e){return function(e){return function(e){return!!e&&"object"==typeof e}(e)&&We(e)}(e)&&Q.call(e,"callee")&&(!se.call(e,"callee")||ee.call(e)==o)}(e)?function(e,t){for(var n=-1,r=Array(e);++n<e;)r[n]=t(n);return r}(e.length,String):[],r=n.length,i=!!r;for(var a in e)!Q.call(e,a)||i&&("length"==a||He(a,r))||n.push(a);return n}function Te(e,t,n){var r=e[t];Q.call(e,t)&&Ue(r,n)&&(void 0!==n||t in e)||(e[t]=n)}function ke(e,t){for(var n=e.length;n--;)if(Ue(e[n][0],t))return n;return-1}function Fe(e,t,n,r,f,m,y){var k;if(r&&(k=m?r(e,f,m,y):r(e)),void 0!==k)return k;if(!Ke(e))return e;var F=Ve(e);if(F){if(k=function(e){var t=e.length,n=e.constructor(t);return t&&"string"==typeof e[0]&&Q.call(e,"index")&&(n.index=e.index,n.input=e.input),n}(e),!t)return function(e,t){var n=-1,r=e.length;for(t||(t=Array(r));++n<r;)t[n]=e[n];return t}(e,k)}else{var P=je(e),_=P==s||P==u;if(Ge(e))return function(e,t){if(t)return e.slice();var n=new e.constructor(e.length);return e.copy(n),n}(e,t);if(P==d||P==o||_&&!m){if(U(e))return m?e:{};if(k=function(e){return"function"!=typeof e.constructor||ze(e)?{}:Ke(t=ie(e))?ae(t):{};var t}(_?{}:e),!t)return function(e,t){return _e(e,Me(e),t)}(e,function(e,t){return e&&_e(t,Ye(t),e)}(k,e))}else{if(!I[P])return m?e:{};k=function(e,t,n,r){var o=e.constructor;switch(t){case b:return Pe(e);case i:case a:return new o(+e);case E:return function(e,t){var n=t?Pe(e.buffer):e.buffer;return new e.constructor(n,e.byteOffset,e.byteLength)}(e,r);case C:case D:case w:case S:case A:case x:case O:case N:case B:return function(e,t){var n=t?Pe(e.buffer):e.buffer;return new e.constructor(n,e.byteOffset,e.length)}(e,r);case l:return function(e,t,n){var r=t?n(V(e),!0):V(e);return $(r,H,new e.constructor)}(e,r,n);case c:case g:return new o(e);case p:return function(e){var t=new e.constructor(e.source,T.exec(e));return t.lastIndex=e.lastIndex,t}(e);case h:return function(e,t,n){var r=t?n(G(e),!0):G(e);return $(r,z,new e.constructor)}(e,r,n);case v:return function(e){return Se?Object(Se.call(e)):{}}(e)}}(e,P,Fe,t)}}y||(y=new Ne);var L=y.get(e);if(L)return L;if(y.set(e,k),!F)var R=n?function(e){return function(e,t,n){var r=t(e);return Ve(e)?r:function(e,t){for(var n=-1,r=t.length,o=e.length;++n<r;)e[o+n]=t[n];return e}(r,n(e))}(e,Ye,Me)}(e):Ye(e);return function(e,t){for(var n=-1,r=e?e.length:0;++n<r&&!1!==t(e[n],n,e););}(R||e,function(o,i){R&&(o=e[i=o]),Te(k,i,Fe(o,t,n,r,i,e,y))}),k}function Ie(e){return!(!Ke(e)||(t=e,Z&&Z in t))&&(qe(e)||U(e)?te:k).test($e(e));var t}function Pe(e){var t=new e.constructor(e.byteLength);return new oe(t).set(new oe(e)),t}function _e(e,t,n,r){n||(n={});for(var o=-1,i=t.length;++o<i;){var a=t[o];Te(n,a,e[a])}return n}function Le(e,t){var n,r,o=e.__data__;return("string"==(r=typeof(n=t))||"number"==r||"symbol"==r||"boolean"==r?"__proto__"!==n:null===n)?o["string"==typeof t?"string":"hash"]:o.map}function Re(e,t){var n=function(e,t){return null==e?void 0:e[t]}(e,t);return Ie(n)?n:void 0}Ae.prototype.clear=function(){this.__data__=me?me(null):{}},Ae.prototype.delete=function(e){return this.has(e)&&delete this.__data__[e]},Ae.prototype.get=function(e){var t=this.__data__;if(me){var r=t[e];return r===n?void 0:r}return Q.call(t,e)?t[e]:void 0},Ae.prototype.has=function(e){var t=this.__data__;return me?void 0!==t[e]:Q.call(t,e)},Ae.prototype.set=function(e,t){return this.__data__[e]=me&&void 0===t?n:t,this},xe.prototype.clear=function(){this.__data__=[]},xe.prototype.delete=function(e){var t=this.__data__,n=ke(t,e);return!(n<0||(n==t.length-1?t.pop():ue.call(t,n,1),0))},xe.prototype.get=function(e){var t=this.__data__,n=ke(t,e);return n<0?void 0:t[n][1]},xe.prototype.has=function(e){return ke(this.__data__,e)>-1},xe.prototype.set=function(e,t){var n=this.__data__,r=ke(n,e);return r<0?n.push([e,t]):n[r][1]=t,this},Oe.prototype.clear=function(){this.__data__={hash:new Ae,map:new(pe||xe),string:new Ae}},Oe.prototype.delete=function(e){return Le(this,e).delete(e)},Oe.prototype.get=function(e){return Le(this,e).get(e)},Oe.prototype.has=function(e){return Le(this,e).has(e)},Oe.prototype.set=function(e,t){return Le(this,e).set(e,t),this},Ne.prototype.clear=function(){this.__data__=new xe},Ne.prototype.delete=function(e){return this.__data__.delete(e)},Ne.prototype.get=function(e){return this.__data__.get(e)},Ne.prototype.has=function(e){return this.__data__.has(e)},Ne.prototype.set=function(e,t){var n=this.__data__;if(n instanceof xe){var r=n.__data__;if(!pe||r.length<199)return r.push([e,t]),this;n=this.__data__=new Oe(r)}return n.set(e,t),this};var Me=le?W(le,Object):function(){return[]},je=function(e){return ee.call(e)};function He(e,t){return!!(t=null==t?r:t)&&("number"==typeof e||F.test(e))&&e>-1&&e%1==0&&e<t}function ze(e){var t=e&&e.constructor;return e===("function"==typeof t&&t.prototype||Y)}function $e(e){if(null!=e){try{return J.call(e)}catch(e){}try{return e+""}catch(e){}}return""}function Ue(e,t){return e===t||e!=e&&t!=t}(fe&&je(new fe(new ArrayBuffer(1)))!=E||pe&&je(new pe)!=l||he&&je(he.resolve())!=f||ge&&je(new ge)!=h||ve&&je(new ve)!=m)&&(je=function(e){var t=ee.call(e),n=t==d?e.constructor:void 0,r=n?$e(n):void 0;if(r)switch(r){case ye:return E;case be:return l;case Ee:return f;case Ce:return h;case De:return m}return t});var Ve=Array.isArray;function We(e){return null!=e&&function(e){return"number"==typeof e&&e>-1&&e%1==0&&e<=r}(e.length)&&!qe(e)}var Ge=ce||function(){return!1};function qe(e){var t=Ke(e)?ee.call(e):"";return t==s||t==u}function Ke(e){var t=typeof e;return!!e&&("object"==t||"function"==t)}function Ye(e){return We(e)?Be(e):function(e){if(!ze(e))return de(e);var t=[];for(var n in Object(e))Q.call(e,n)&&"constructor"!=n&&t.push(n);return t}(e)}e.exports=function(e){return Fe(e,!0,!0)}}(ov,ov.exports)),ov.exports),uv=b(sv);var lv=function(){if(av)return iv;av=1;var e=9007199254740991,t="[object Arguments]",n="[object Function]",r="[object GeneratorFunction]",o=/^(?:0|[1-9]\d*)$/;function i(e,t){for(var n=-1,r=e?e.length:0;++n<r&&!1!==t(e[n],n,e););return e}var a,s,u=Object.prototype,l=u.hasOwnProperty,c=u.toString,d=u.propertyIsEnumerable,f=(a=Object.keys,s=Object,function(e){return a(s(e))});function p(e,n){var r=b(e)||function(e){return function(e){return function(e){return!!e&&"object"==typeof e}(e)&&E(e)}(e)&&l.call(e,"callee")&&(!d.call(e,"callee")||c.call(e)==t)}(e)?function(e,t){for(var n=-1,r=Array(e);++n<e;)r[n]=t(n);return r}(e.length,String):[],o=r.length,i=!!o;for(var a in e)!l.call(e,a)||i&&("length"==a||y(a,o))||r.push(a);return r}var h,g=(h=function(e,t){return e&&v(e,t,C)},function(e,t){if(null==e)return e;if(!E(e))return h(e,t);for(var n=e.length,r=-1,o=Object(e);++r<n&&!1!==t(o[r],r,o););return e}),v=function(e,t,n){for(var r=-1,o=Object(e),i=n(e),a=i.length;a--;){var s=i[++r];if(!1===t(o[s],s,o))break}return e};function m(e){if(n=(t=e)&&t.constructor,r="function"==typeof n&&n.prototype||u,t!==r)return f(e);var t,n,r,o=[];for(var i in Object(e))l.call(e,i)&&"constructor"!=i&&o.push(i);return o}function y(t,n){return!!(n=null==n?e:n)&&("number"==typeof t||o.test(t))&&t>-1&&t%1==0&&t<n}var b=Array.isArray;function E(t){return null!=t&&function(t){return"number"==typeof t&&t>-1&&t%1==0&&t<=e}(t.length)&&!function(e){var t=function(e){var t=typeof e;return!!e&&("object"==t||"function"==t)}(e)?c.call(e):"";return t==n||t==r}(t)}function C(e){return E(e)?p(e):m(e)}function D(e){return e}return iv=function(e,t){return(b(e)?i:g)(e,"function"==typeof t?t:D)}}(),cv=b(lv),dv={};var fv="created",pv="destroyed",hv="change",gv="scroll",vv="fullscreen",mv="unFullScreen",yv={};function bv(e,t){var n=e.key,r=e.factory,o=e.config,i=Yg(Yg({},o),t||{});if(null!=yv[n])throw new Error("Duplicated key '".concat(n,"' in menu items"));yv[n]=r,function(e,t){null!=t&&(dv[e]=t)}(n,i)}var Ev=new WeakMap,Cv=new WeakMap,Dv=new WeakMap,wv=new WeakMap,Sv=new WeakMap,Av=new WeakMap,xv=new WeakMap,Ov=new WeakMap,Nv=new WeakMap,Bv=new WeakMap,Tv=new WeakMap,kv=new WeakMap,Fv=new WeakMap,Iv=new WeakMap,Pv=new WeakMap,_v=new WeakMap,Lv=new WeakMap,Rv=new WeakMap,Mv=new WeakMap,jv=new WeakMap,Hv=new WeakMap,zv=new WeakMap,$v=new WeakMap,Uv=new WeakMap,Vv=new WeakMap,Wv=new WeakMap,Gv=new WeakMap,qv=function(e){var t=e;return t.getAllMenuKeys=function(){var e=[];for(var t in yv)e.push(t);return e},t.getConfig=function(){var e=Bv.get(t);if(null==e)throw new Error("Can not get editor config");return e},t.getMenuConfig=function(e){var n=t.getConfig().MENU_CONF;return(void 0===n?{}:n)[e]||{}},t.alert=function(e,n){void 0===n&&(n="info");var r=t.getConfig().customAlert;r&&r(e,n)},t},Kv=new Set(["doctype","!doctype","meta","script","style","link","frame","iframe","title","svg"]);function Yv(e){return null!==e&&"object"==typeof e&&"constructor"in e&&e.constructor===Object}function Xv(e={},t={}){Object.keys(t).forEach(n=>{void 0===e[n]?e[n]=t[n]:Yv(t[n])&&Yv(e[n])&&Object.keys(t[n]).length>0&&Xv(e[n],t[n])})}const Zv={body:{},addEventListener(){},removeEventListener(){},activeElement:{blur(){},nodeName:""},querySelector:()=>null,querySelectorAll:()=>[],getElementById:()=>null,createEvent:()=>({initEvent(){}}),createElement:()=>({children:[],childNodes:[],style:{},setAttribute(){},getElementsByTagName:()=>[]}),createElementNS:()=>({}),importNode:()=>null,location:{hash:"",host:"",hostname:"",href:"",origin:"",pathname:"",protocol:"",search:""}};function Jv(){const e="undefined"!=typeof document?document:{};return Xv(e,Zv),e}const Qv={document:Zv,navigator:{userAgent:""},location:{hash:"",host:"",hostname:"",href:"",origin:"",pathname:"",protocol:"",search:""},history:{replaceState(){},pushState(){},go(){},back(){}},CustomEvent:function(){return this},addEventListener(){},removeEventListener(){},getComputedStyle:()=>({getPropertyValue:()=>""}),Image(){},Date(){},screen:{},setTimeout(){},clearTimeout(){},matchMedia:()=>({}),requestAnimationFrame:e=>"undefined"==typeof setTimeout?(e(),null):setTimeout(e,0),cancelAnimationFrame(e){"undefined"!=typeof setTimeout&&clearTimeout(e)}};function em(){const e="undefined"!=typeof window?window:{};return Xv(e,Qv),e}class tm extends Array{constructor(e){"number"==typeof e?super(e):(super(...e||[]),function(e){const t=e.__proto__;Object.defineProperty(e,"__proto__",{get:()=>t,set(e){t.__proto__=e}})}(this))}}function nm(e=[]){const t=[];return e.forEach(e=>{Array.isArray(e)?t.push(...nm(e)):t.push(e)}),t}function rm(e,t){return Array.prototype.filter.call(e,t)}function om(e){return e.toLowerCase().replace(/-(.)/g,(e,t)=>t.toUpperCase())}function im(e,t){const n=em(),r=Jv();let o=[];if(!t&&e instanceof tm)return e;if(!e)return new tm(o);if("string"==typeof e){const n=e.trim();if(n.indexOf("<")>=0&&n.indexOf(">")>=0){let e="div";0===n.indexOf("<li")&&(e="ul"),0===n.indexOf("<tr")&&(e="tbody"),0!==n.indexOf("<td")&&0!==n.indexOf("<th")||(e="tr"),0===n.indexOf("<tbody")&&(e="table"),0===n.indexOf("<option")&&(e="select");const t=r.createElement(e);t.innerHTML=n;for(let e=0;e<t.childNodes.length;e+=1)o.push(t.childNodes[e])}else o=function(e,t){if("string"!=typeof e)return[e];const n=[],r=t.querySelectorAll(e);for(let e=0;e<r.length;e+=1)n.push(r[e]);return n}(e.trim(),t||r)}else if(e.nodeType||e===n||e===r)o.push(e);else if(Array.isArray(e)){if(e instanceof tm)return e;o=e}return new tm(function(e){const t=[];for(let n=0;n<e.length;n+=1)-1===t.indexOf(e[n])&&t.push(e[n]);return t}(o))}function am(...e){const t=nm(e.map(e=>e.split(" ")));return this.forEach(e=>{e.classList.add(...t)}),this}function sm(...e){const t=nm(e.map(e=>e.split(" ")));return this.forEach(e=>{e.classList.remove(...t)}),this}function um(...e){const t=nm(e.map(e=>e.split(" ")));return rm(this,e=>t.filter(t=>e.classList.contains(t)).length>0).length>0}function lm(e,t){if(1===arguments.length&&"string"==typeof e)return this[0]?this[0].getAttribute(e):void 0;for(let n=0;n<this.length;n+=1)if(2===arguments.length)this[n].setAttribute(e,t);else for(const t in e)this[n][t]=e[t],this[n].setAttribute(t,e[t]);return this}function cm(e){for(let t=0;t<this.length;t+=1)this[t].removeAttribute(e);return this}function dm(e,t){let n;if(void 0===t){if(n=this[0],!n)return;if(n.dom7ElementDataStorage&&e in n.dom7ElementDataStorage)return n.dom7ElementDataStorage[e];const t=n.getAttribute(`data-${e}`);return t||void 0}for(let r=0;r<this.length;r+=1)n=this[r],n.dom7ElementDataStorage||(n.dom7ElementDataStorage={}),n.dom7ElementDataStorage[e]=t;return this}function fm(){const e=this[0];if(!e)return;const t={};if(e.dataset)for(const n in e.dataset)t[n]=e.dataset[n];else for(let n=0;n<e.attributes.length;n+=1){const r=e.attributes[n];r.name.indexOf("data-")>=0&&(t[om(r.name.split("data-")[1])]=r.value)}for(const e in t)"false"===t[e]?t[e]=!1:"true"===t[e]?t[e]=!0:parseFloat(t[e])===1*t[e]&&(t[e]*=1);return t}function pm(e){if(void 0===e){const e=this[0];if(!e)return;if(e.multiple&&"select"===e.nodeName.toLowerCase()){const t=[];for(let n=0;n<e.selectedOptions.length;n+=1)t.push(e.selectedOptions[n].value);return t}return e.value}for(let t=0;t<this.length;t+=1){const n=this[t];if(Array.isArray(e)&&n.multiple&&"select"===n.nodeName.toLowerCase())for(let t=0;t<n.options.length;t+=1)n.options[t].selected=e.indexOf(n.options[t].value)>=0;else n.value=e}return this}function hm(...e){let[t,n,r,o]=e;function i(e){const t=e.target;if(!t)return;const o=e.target.dom7EventData||[];if(o.indexOf(e)<0&&o.unshift(e),im(t).is(n))r.apply(t,o);else{const e=im(t).parents();for(let t=0;t<e.length;t+=1)im(e[t]).is(n)&&r.apply(e[t],o)}}function a(e){const t=e&&e.target&&e.target.dom7EventData||[];t.indexOf(e)<0&&t.unshift(e),r.apply(this,t)}"function"==typeof e[1]&&([t,r,o]=e,n=void 0),o||(o=!1);const s=t.split(" ");let u;for(let e=0;e<this.length;e+=1){const t=this[e];if(n)for(u=0;u<s.length;u+=1){const e=s[u];t.dom7LiveListeners||(t.dom7LiveListeners={}),t.dom7LiveListeners[e]||(t.dom7LiveListeners[e]=[]),t.dom7LiveListeners[e].push({listener:r,proxyListener:i}),t.addEventListener(e,i,o)}else for(u=0;u<s.length;u+=1){const e=s[u];t.dom7Listeners||(t.dom7Listeners={}),t.dom7Listeners[e]||(t.dom7Listeners[e]=[]),t.dom7Listeners[e].push({listener:r,proxyListener:a}),t.addEventListener(e,a,o)}}return this}function gm(...e){let[t,n,r,o]=e;"function"==typeof e[1]&&([t,r,o]=e,n=void 0),o||(o=!1);const i=t.split(" ");for(let e=0;e<i.length;e+=1){const t=i[e];for(let e=0;e<this.length;e+=1){const i=this[e];let a;if(!n&&i.dom7Listeners?a=i.dom7Listeners[t]:n&&i.dom7LiveListeners&&(a=i.dom7LiveListeners[t]),a&&a.length)for(let e=a.length-1;e>=0;e-=1){const n=a[e];r&&n.listener===r||r&&n.listener&&n.listener.dom7proxy&&n.listener.dom7proxy===r?(i.removeEventListener(t,n.proxyListener,o),a.splice(e,1)):r||(i.removeEventListener(t,n.proxyListener,o),a.splice(e,1))}}}return this}function vm(){const e=em();return this[0]===e?e.innerWidth:this.length>0?parseFloat(this.css("width")):null}function mm(){const e=em();return this[0]===e?e.innerHeight:this.length>0?parseFloat(this.css("height")):null}function ym(){if(this.length>0){const e=em(),t=Jv(),n=this[0],r=n.getBoundingClientRect(),o=t.body,i=n.clientTop||o.clientTop||0,a=n.clientLeft||o.clientLeft||0,s=n===e?e.scrollY:n.scrollTop,u=n===e?e.scrollX:n.scrollLeft;return{top:r.top+s-i,left:r.left+u-a}}return null}function bm(){for(let e=0;e<this.length;e+=1)this[e].style.display="none";return this}function Em(){const e=em();for(let t=0;t<this.length;t+=1){const n=this[t];"none"===n.style.display&&(n.style.display=""),"none"===e.getComputedStyle(n,null).getPropertyValue("display")&&(n.style.display="block")}return this}function Cm(e,t){const n=em();let r;if(1===arguments.length){if("string"!=typeof e){for(r=0;r<this.length;r+=1)for(const t in e)this[r].style[t]=e[t];return this}if(this[0])return n.getComputedStyle(this[0],null).getPropertyValue(e)}if(2===arguments.length&&"string"==typeof e){for(r=0;r<this.length;r+=1)this[r].style[e]=t;return this}return this}function Dm(e){return e?(this.forEach((t,n)=>{e.apply(t,[t,n])}),this):this}function wm(e){return im(rm(this,e))}function Sm(e){if(void 0===e)return this[0]?this[0].innerHTML:null;for(let t=0;t<this.length;t+=1)this[t].innerHTML=e;return this}function Am(e){if(void 0===e)return this[0]?this[0].textContent.trim():null;for(let t=0;t<this.length;t+=1)this[t].textContent=e;return this}function xm(e){const t=em(),n=Jv(),r=this[0];let o,i;if(!r||void 0===e)return!1;if("string"==typeof e){if(r.matches)return r.matches(e);if(r.webkitMatchesSelector)return r.webkitMatchesSelector(e);if(r.msMatchesSelector)return r.msMatchesSelector(e);for(o=im(e),i=0;i<o.length;i+=1)if(o[i]===r)return!0;return!1}if(e===n)return r===n;if(e===t)return r===t;if(e.nodeType||e instanceof tm){for(o=e.nodeType?[e]:e,i=0;i<o.length;i+=1)if(o[i]===r)return!0;return!1}return!1}function Om(...e){let t;const n=Jv();for(let r=0;r<e.length;r+=1){t=e[r];for(let e=0;e<this.length;e+=1)if("string"==typeof t){const r=n.createElement("div");for(r.innerHTML=t;r.firstChild;)this[e].appendChild(r.firstChild)}else if(t instanceof tm)for(let n=0;n<t.length;n+=1)this[e].appendChild(t[n]);else this[e].appendChild(t)}return this}function Nm(e){const t=Jv();let n,r;for(n=0;n<this.length;n+=1)if("string"==typeof e){const o=t.createElement("div");for(o.innerHTML=e,r=o.childNodes.length-1;r>=0;r-=1)this[n].insertBefore(o.childNodes[r],this[n].childNodes[0])}else if(e instanceof tm)for(r=0;r<e.length;r+=1)this[n].insertBefore(e[r],this[n].childNodes[0]);else this[n].insertBefore(e,this[n].childNodes[0]);return this}function Bm(e){const t=[];for(let n=0;n<this.length;n+=1)null!==this[n].parentNode&&(e?im(this[n].parentNode).is(e)&&t.push(this[n].parentNode):t.push(this[n].parentNode));return im(t)}function Tm(e){const t=[];for(let n=0;n<this.length;n+=1){let r=this[n].parentNode;for(;r;)e?im(r).is(e)&&t.push(r):t.push(r),r=r.parentNode}return im(t)}function km(e){const t=[];for(let n=0;n<this.length;n+=1){const r=this[n].querySelectorAll(e);for(let e=0;e<r.length;e+=1)t.push(r[e])}return im(t)}function Fm(e){const t=[];for(let n=0;n<this.length;n+=1){const r=this[n].children;for(let n=0;n<r.length;n+=1)e&&!im(r[n]).is(e)||t.push(r[n])}return im(t)}function Im(){for(let e=0;e<this.length;e+=1)this[e].parentNode&&this[e].parentNode.removeChild(this[e]);return this}function Pm(){for(let e=0;e<this.length;e+=1){const t=this[e];if(1===t.nodeType){for(let e=0;e<t.childNodes.length;e+=1)t.childNodes[e].parentNode&&t.childNodes[e].parentNode.removeChild(t.childNodes[e]);t.textContent=""}}return this}im.fn=tm.prototype;const _m="resize scroll".split(" ");function Lm(e){return function(...t){if(void 0===t[0]){for(let t=0;t<this.length;t+=1)_m.indexOf(e)<0&&(e in this[t]?this[t][e]():im(this[t]).trigger(e));return this}return this.on(e,...t)}}const Rm=Lm("click"),Mm=Lm("focus"),jm=["area","base","basefont","bgsound","br","col","command","embed","frame","hr","image","img","input","keygen","link","meta","param","source","track","wbr"];let Hm=(e=21)=>{let t="",n=crypto.getRandomValues(new Uint8Array(e|=0));for(;e--;)t+="useandom-26T198340PX75pxJACKVERYMINDBUSHWOLF_GQZbfghjklqvwyzrict"[63&n[e]];return t};function zm(e){Promise.resolve().then(e)}var $m,Um=function(e){return Object.prototype.toString.call(e)};Cm&&(im.fn.css=Cm),Om&&(im.fn.append=Om),am&&(im.fn.addClass=am),sm&&(im.fn.removeClass=sm),um&&(im.fn.hasClass=um),hm&&(im.fn.on=hm),Mm&&(im.fn.focus=Mm),lm&&(im.fn.attr=lm),cm&&(im.fn.removeAttr=cm),bm&&(im.fn.hide=bm),Em&&(im.fn.show=Em),ym&&(im.fn.offset=ym),vm&&(im.fn.width=vm),mm&&(im.fn.height=mm),Bm&&(im.fn.parent=Bm),Tm&&(im.fn.parents=Tm),xm&&(im.fn.is=xm),fm&&(im.fn.dataset=fm),pm&&(im.fn.val=pm),Am&&(im.fn.text=Am),Sm&&(im.fn.html=Sm),Fm&&(im.fn.children=Fm),Im&&(im.fn.remove=Im),km&&(im.fn.find=km),Dm&&(im.fn.each=Dm),Pm&&(im.fn.empty=Pm),function(e){e[e.ELEMENT_NODE=1]="ELEMENT_NODE",e[e.TEXT_NODE=3]="TEXT_NODE",e[e.CDATA_SECTION_NODE=4]="CDATA_SECTION_NODE",e[e.PROCESSING_INSTRUCTION_NODE=7]="PROCESSING_INSTRUCTION_NODE",e[e.COMMENT_NODE=8]="COMMENT_NODE",e[e.DOCUMENT_NODE=9]="DOCUMENT_NODE",e[e.DOCUMENT_TYPE_NODE=10]="DOCUMENT_TYPE_NODE",e[e.DOCUMENT_FRAGMENT_NODE=11]="DOCUMENT_FRAGMENT_NODE"}($m||($m={}));var Vm=/\[object HTML([A-Z][a-z]*)*Element\]/,Wm=function(e){return Vm.test(Um(e))},Gm=function(e){return null!=e&&"number"==typeof e.nodeType},qm=function(e){return Gm(e)&&e.nodeType===$m.COMMENT_NODE},Km=function(e){return Gm(e)&&e.nodeType===$m.ELEMENT_NODE},Ym=function(e){return"[object Selection]"===Um(e)},Xm=function(e){return Gm(e)&&e.nodeType===$m.TEXT_NODE},Zm=function(e){var t,n,r;return null!==(t=window&&window.document.getElementById(e))&&void 0!==t?t:window&&(null===(r=null===(n=window.document.activeElement)||void 0===n?void 0:n.shadowRoot)||void 0===r?void 0:r.getElementById(e))||null},Jm=function(e,t,n){for(var r=e.childNodes,o=r[t],i=t,a=!1,s=!1;(qm(o)||Km(o)&&0===o.childNodes.length||Km(o)&&"false"===o.getAttribute("contenteditable"))&&(!a||!s);)i>=r.length?(a=!0,i=t-1,n="backward"):i<0?(s=!0,i=t+1,n="forward"):(o=r[i],t=i,i+="forward"===n?1:-1);return[o,t]},Qm=function(e,t,n){return ev(Jm(e,t,n),1)[0]},ey=function(e){var t,n,r="";if(Xm(e)&&e.nodeValue)return e.nodeValue;if(Km(e)){try{for(var o=Qg(Array.from(e.childNodes)),i=o.next();!i.done;i=o.next()){var a=i.value;r+=ey(a)}}catch(e){t={error:e}}finally{try{i&&!i.done&&(n=o.return)&&n.call(o)}finally{if(t)throw t.error}}var s=getComputedStyle(e).getPropertyValue("display");"block"!==s&&"list"!==s&&"table-row"!==s&&"BR"!==e.tagName||(r+="\n")}return r};function ty(e,t){if(!Wm(e)||"true"!==e.dataset.slateVoid)for(var n=e.childNodes,r=n.length;r-=1;){var o=n[r],i=o.nodeType;Xm(o)?t(o,e):[$m.ELEMENT_NODE,$m.DOCUMENT_NODE,$m.DOCUMENT_FRAGMENT_NODE].includes(i)&&ty(o,t)}}function ny(e){if(0===e.length)return"";var t=e[0];return t.nodeType!==$m.ELEMENT_NODE?"":t.tagName.toLowerCase()}var ry=new RegExp(String.fromCharCode(160),"g");function oy(e){return e.replace(ry," ")}var iy=["span","b","strong","i","em","s","strike","u","font","sub","sup"],ay=[];var sy=[];var uy={};function ly(e,t){var n=e.length;if(n){var r=e[n-1];if(Cg.isText(r)){var o=Object.keys(r);if(1===o.length&&"text"===o[0])return r.text+=t,!0}}return!1}function cy(e,t,n){return{type:"paragraph",children:[{text:im(e).text().replace(/\s+/gm," ")}]}}function dy(e,t){var n=function(e,t){var n=[];if(null!=e.attr("data-w-e-is-void"))return n;var r=e[0].childNodes;return 1===r.length&&"BR"===r[0].nodeName?(n.push({text:""}),n):(r.forEach(function(e){if(Km(e)){if("BR"===e.nodeName)return void(ly(n,"\n")||n.push({text:"\n"}));var r=py(im(e),t);Array.isArray(r)?r.forEach(function(e){return n.push(e)}):n.push(r)}else if(Xm(e)){var o=e.textContent||"";if(""===o.trim()&&o.indexOf("\n")>=0)return;o&&(o=oy(o),ly(n,o)||n.push({text:o}))}}),n)}(e,t),r=function(e){for(var t in uy)if(e[0].matches(t))return uy[t];return cy}(e),o=r(e[0],n,t);return Array.isArray(o)||(o=[o]),o.forEach(function(r){Kh.isVoid(t,r)||(0===n.length&&(r.children=[{text:e.text().replace(/\s+/gm," ")}]),sy.forEach(function(n){r=n(e[0],r,t)}))}),o}function fy(e,t){0===e.parents("pre").length&&(e[0].innerHTML=e[0].innerHTML.replace(/\s+/gm," ").replace(/<br>/g,"\n"));var n=e[0].textContent||"";n=function(e){return e.replace(/ /g," ").replace(/</g,"<").replace(/>/g,">").replace(/®/g,"®").replace(/©/g,"©").replace(/™/g,"™").replace(/"/g,'"')}(n);var r={text:n=oy(n)};return sy.forEach(function(n){r=n(e[0],r,t)}),r}function py(e,t){ay.forEach(function(t){var n=t.selector,r=t.preParseHtml;e[0].matches(n)&&(e=im(r(e[0])))});var n=ny(e);if("span"===n){if(e.attr("data-w-e-type"))return dy(e,t);if(e[0].childNodes.length>1){var r=e[0].childNodes,o=function(e,t){var n={text:""};return sy.forEach(function(r){n=r(e[0],n,t)}),n}(im(e[0]),t),i=o;i.bold,i.italic,i.underline,i.through,i.sub,i.sup,i.code;var a=Xg(i,["bold","italic","underline","through","sub","sup","code"]);return Array.from(r).flatMap(function(e){var n=function(e,t,n){var r=e[0];if(Km(r)){var o=py(e,n);return Array.isArray(o)?o.map(function(e){return Yg(Yg({},t),e)}):[Yg(Yg({},t),o)]}if(qm(r))return null;var i=Xm(r)?{text:r.textContent||""}:fy(e,n);return[Yg(Yg({},t),i)]}(im(e),a,t);return n||[]})}return 1===e[0].childNodes.length&&"span"===ny(im(e[0].childNodes[0]))?py(im(e[0].childNodes[0]),t):fy(e,t)}if("code"===n)return"pre"===ny(e.parent())?dy(e,t):fy(e,t);if(iy.includes(n)){if(e[0].childNodes.length>0&&3!==e[0].childNodes[0].nodeType){var s=py(im((r=e[0].childNodes)[0]),t),u=fy(e,t),l=void 0;if(Array.isArray(s)){var c=u;c.text;var d=c.bold,f=c.italic,p=c.underline,h=c.through;c.sub,c.sup;var g=c.code,v=Xg(c,["text","bold","italic","underline","through","sub","sup","code"]);l=s.map(function(e){return Yg(Yg({},v),e)}),(d||f||p||h||g)&&(l=l.map(function(e){var t=Yg({},e),n=e;return d&&!n.bold&&(t.bold=!0),f&&!n.italic&&(t.italic=!0),p&&!n.underline&&(t.underline=!0),h&&!n.through&&(t.through=!0),g&&!n.code&&(t.code=!0),t}))}else l=Yg(Yg({},s),u);return l}return fy(e,t)}return dy(e,t)}function hy(e,t,n){var r=im(n);return!!r.attr(t)||(r.attr(t,"true"),e.on(pv,function(){r.removeAttr(t)}),!1)}function gy(e,t){void 0===t&&(t="");var n=[];""===t&&(t="<p><br></p>"),0!==t.indexOf("<")&&(t=t.split(/\n/).map(function(e){return"<p>".concat(e,"</p>")}).join(""));var r=im("<div>".concat(t,"</div>"));return Array.from(r.children()).forEach(function(t){var r=py(im(t),e);Array.isArray(r)?r.forEach(function(e){return n.push(e)}):n.push(r)}),n}function vy(e,t){return"w-e-element-".concat(e,"-").concat(t)}var my=[];var yy,by,Ey={};function Cy(e,t,n){var r=n.isInline(e)?"span":"div";return"<".concat(r,">").concat(t,"</").concat(r,">")}function Dy(e,t){var n=e.type,r=void 0===n?"":n,o=e.children,i=void 0===o?[]:o,a=Kh.isVoid(t,e),s="";a||(s=i.map(function(e){return _y(e,t)}).join(""));var u=function(e){return Ey[e]||Cy}(r),l=u(e,s,t),c="";if(c="string"==typeof l?l:l.html||"",a||my.forEach(function(t){return c=t(e,c)}),"string"==typeof l)return c;var d=l.prefix,f=void 0===d?"":d,p=l.suffix,h=void 0===p?"":p;return f&&(c=f+c),h&&(c+=h),c}var wy=function(){if(by)return yy;by=1;var e=9007199254740991,t="[object Arguments]",n="[object Map]",r="[object Promise]",o="[object Set]",i="[object WeakMap]",a="[object DataView]",s=/^\[object .+?Constructor\]$/,u=/^(?:0|[1-9]\d*)$/,l="\\ud800-\\udfff",c="\\u0300-\\u036f\\ufe20-\\ufe23",d="\\u20d0-\\u20f0",f="\\ufe0e\\ufe0f",p="["+l+"]",h="["+c+d+"]",g="\\ud83c[\\udffb-\\udfff]",v="[^"+l+"]",m="(?:\\ud83c[\\udde6-\\uddff]){2}",b="[\\ud800-\\udbff][\\udc00-\\udfff]",E="\\u200d",C="(?:"+h+"|"+g+")"+"?",D="["+f+"]?",w=D+C+("(?:"+E+"(?:"+[v,m,b].join("|")+")"+D+C+")*"),S="(?:"+[v+h+"?",h,m,b,p].join("|")+")",A=RegExp(g+"(?="+g+")|"+S+w,"g"),x=RegExp("["+E+l+c+d+f+"]"),O="object"==typeof y&&y&&y.Object===Object&&y,N="object"==typeof self&&self&&self.Object===Object&&self,B=O||N||Function("return this")();function T(e,t){return function(e,t){for(var n=-1,r=e?e.length:0,o=Array(r);++n<r;)o[n]=t(e[n],n,e);return o}(t,function(t){return e[t]})}function k(e){var t=-1,n=Array(e.size);return e.forEach(function(e,r){n[++t]=[r,e]}),n}function F(e){var t=-1,n=Array(e.size);return e.forEach(function(e){n[++t]=e}),n}function I(e){return function(e){return x.test(e)}(e)?function(e){return e.match(A)||[]}(e):function(e){return e.split("")}(e)}var P,_,L=Function.prototype,R=Object.prototype,M=B["__core-js_shared__"],j=function(){var e=/[^.]+$/.exec(M&&M.keys&&M.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""}(),H=L.toString,z=R.hasOwnProperty,$=R.toString,U=RegExp("^"+H.call(z).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),V=B.Symbol,W=V?V.iterator:void 0,G=R.propertyIsEnumerable,q=(P=Object.keys,_=Object,function(e){return P(_(e))}),K=se(B,"DataView"),Y=se(B,"Map"),X=se(B,"Promise"),Z=se(B,"Set"),J=se(B,"WeakMap"),Q=ce(K),ee=ce(Y),te=ce(X),ne=ce(Z),re=ce(J);function oe(e,n){var r=de(e)||function(e){return function(e){return ge(e)&&fe(e)}(e)&&z.call(e,"callee")&&(!G.call(e,"callee")||$.call(e)==t)}(e)?function(e,t){for(var n=-1,r=Array(e);++n<e;)r[n]=t(n);return r}(e.length,String):[],o=r.length,i=!!o;for(var a in e)!z.call(e,a)||i&&("length"==a||le(a,o))||r.push(a);return r}function ie(e){if(!he(e)||function(e){return!!j&&j in e}(e))return!1;var t=pe(e)||function(e){var t=!1;if(null!=e&&"function"!=typeof e.toString)try{t=!!(e+"")}catch(e){}return t}(e)?U:s;return t.test(ce(e))}function ae(e){if(n=(t=e)&&t.constructor,r="function"==typeof n&&n.prototype||R,t!==r)return q(e);var t,n,r,o=[];for(var i in Object(e))z.call(e,i)&&"constructor"!=i&&o.push(i);return o}function se(e,t){var n=function(e,t){return null==e?void 0:e[t]}(e,t);return ie(n)?n:void 0}var ue=function(e){return $.call(e)};function le(t,n){return!!(n=null==n?e:n)&&("number"==typeof t||u.test(t))&&t>-1&&t%1==0&&t<n}function ce(e){if(null!=e){try{return H.call(e)}catch(e){}try{return e+""}catch(e){}}return""}(K&&ue(new K(new ArrayBuffer(1)))!=a||Y&&ue(new Y)!=n||X&&ue(X.resolve())!=r||Z&&ue(new Z)!=o||J&&ue(new J)!=i)&&(ue=function(e){var t=$.call(e),s="[object Object]"==t?e.constructor:void 0,u=s?ce(s):void 0;if(u)switch(u){case Q:return a;case ee:return n;case te:return r;case ne:return o;case re:return i}return t});var de=Array.isArray;function fe(t){return null!=t&&function(t){return"number"==typeof t&&t>-1&&t%1==0&&t<=e}(t.length)&&!pe(t)}function pe(e){var t=he(e)?$.call(e):"";return"[object Function]"==t||"[object GeneratorFunction]"==t}function he(e){var t=typeof e;return!!e&&("object"==t||"function"==t)}function ge(e){return!!e&&"object"==typeof e}function ve(e){return e?T(e,function(e){return fe(e)?oe(e):ae(e)}(e)):[]}return yy=function(e){if(!e)return[];if(fe(e))return function(e){return"string"==typeof e||!de(e)&&ge(e)&&"[object String]"==$.call(e)}(e)?I(e):function(e,t){var n=-1,r=e.length;for(t||(t=Array(r));++n<r;)t[n]=e[n];return t}(e);if(W&&e[W])return function(e){for(var t,n=[];!(t=e.next()).done;)n.push(t.value);return n}(e[W]());var t=ue(e);return(t==n?k:t==o?F:ve)(e)},yy}(),Sy=b(wy),Ay=0,xy=function(){this.id="".concat(Ay++)},Oy="undefined"!=typeof navigator&&/Mac OS X/.test(navigator.userAgent),Ny="undefined"!=typeof navigator&&/^(?!.*Seamonkey)(?=.*Firefox).*/i.test(navigator.userAgent),By="undefined"!=typeof navigator&&/^((?!chrome|android).)*safari/i.test(navigator.userAgent),Ty="undefined"!=typeof navigator&&/Edge?\/(?:[0-6][0-9]|[0-7][0-8])(?:\.)/i.test(navigator.userAgent),ky="undefined"!=typeof navigator&&/Chrome?\/(?:[0-7][0-5]|[0-6][0-9])(?:\.)/i.test(navigator.userAgent),Fy="undefined"!=typeof navigator&&/Chrome/i.test(navigator.userAgent),Iy=!ky&&!Ty&&"undefined"!=typeof globalThis&&globalThis.InputEvent&&"function"==typeof globalThis.InputEvent.prototype.getTargetRanges,Py={getWindow:function(e){var t=$v.get(e);if(!t)throw new Error("Unable to find a host window element for this editor");return t},findKey:function(e,t){var n=zv.get(t);return n||(n=new xy,zv.set(t,n)),n},setNewKey:function(e){var t=new xy;zv.set(e,t)},findPath:function(e,t){for(var n=[],r=t;;){var o=Lv.get(r);if(null==o){if(Kh.isEditor(r))return n;break}var i=_v.get(r);if(null==i)break;n.unshift(i),r=o}throw new Error("Unable to find the path for Slate node: ".concat(JSON.stringify(t)))},findDocumentOrShadowRoot:function(e){if(e.isDestroyed)return window.document;var t=Py.toDOMNode(e,e),n=t.getRootNode();return"[object HTMLDocument]"!==Um(n)&&!function(e){return"[object ShadowRoot]"===Um(e)}(n)||null==Reflect.get(n,"getSelection")?t.ownerDocument:n},getParentNode:function(e,t){return Lv.get(t)||null},getParentsNodes:function(e,t){for(var n=[],r=t;r!==e&&null!=r;){var o=Py.getParentNode(e,r);if(null==o)break;n.push(o),r=o}return n},getTopNode:function(e,t){var n=[Py.findPath(e,t)[0]];return eg.get(e,n)},toDOMNode:function(e,t){var n;if(Kh.isEditor(t))n=Rv.get(e);else{var r=Py.findKey(e,t);n=jv.get(r)}if(!n)throw new Error("Cannot resolve a DOM node from Slate node: ".concat(JSON.stringify(t)));return n},hasDOMNode:function(e,t,n){void 0===n&&(n={});var r,o=n.editable,i=void 0!==o&&o,a=Py.toDOMNode(e,e);try{r=Km(t)?t:t.parentElement}catch(e){if(e instanceof Error&&!e.message.includes('Permission denied to access property "nodeType"'))throw e}return!!r&&(r.closest("[data-slate-editor]")===a&&(!i||r.isContentEditable||!!r.getAttribute("data-slate-zero-width"))||!!r.getAttribute("data-slate-string"))},toDOMRange:function(e,t){var n=t.anchor,r=t.focus,o=fg.isBackward(t),i=Py.toDOMPoint(e,n),a=fg.isCollapsed(t)?i:Py.toDOMPoint(e,r),s=Py.getWindow(e).document.createRange(),u=ev(o?a:i,2),l=u[0],c=u[1],d=ev(o?i:a,2),f=d[0],p=d[1],h=!!(Km(l)?l:l.parentElement).getAttribute("data-slate-zero-width"),g=!!(Km(f)?f:f.parentElement).getAttribute("data-slate-zero-width");return s.setStart(l,h?1:c),s.setEnd(f,g?1:p),s},toDOMPoint:function(e,t){var n,r,o,i=ev(Kh.node(e,t.path),1)[0],a=Py.toDOMNode(e,i);Kh.void(e,{at:t})&&(t={path:t.path,offset:0});var s=Array.from(a.querySelectorAll("[data-slate-string], [data-slate-zero-width]")),u=0;try{for(var l=Qg(s),c=l.next();!c.done;c=l.next()){var d=c.value,f=d.childNodes[0];if(null!=f&&null!=f.textContent){var p=f.textContent.length,h=d.getAttribute("data-slate-length"),g=u+(null==h?p:parseInt(h,10));if(t.offset<=g){o=[f,Math.min(p,Math.max(0,t.offset-u))];break}u=g}}}catch(e){n={error:e}}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: ".concat(JSON.stringify(t)));return o},toSlateNode:function(e,t){var n=Km(t)?t:t.parentElement;n&&!n.hasAttribute("data-slate-node")&&(n=n.closest("[data-slate-node]"));var r=n?Mv.get(n):null;if(!r)throw new Error("Cannot resolve a Slate node from DOM node: ".concat(n));return r},findEventRange:function(e,t){"nativeEvent"in t&&(t=t.nativeEvent);var n=t.clientX,r=t.clientY,o=t.target;if(null==n||null==r)throw new Error("Cannot resolve a Slate range from a DOM event: ".concat(t));var i,a=Py.toSlateNode(e,t.target),s=Py.findPath(e,a);if(Kh.isVoid(e,a)){var u=o.getBoundingClientRect(),l=e.isInline(a)?n-u.left<u.left+u.width-n:r-u.top<u.top+u.height-r,c=Kh.point(e,s,{edge:l?"start":"end"}),d=l?Kh.before(e,c):Kh.after(e,c);if(d)return Kh.range(e,d)}var f=this.getWindow(e).document;if(f.caretRangeFromPoint)i=f.caretRangeFromPoint(n,r);else{var p=f.caretPositionFromPoint(n,r);p&&((i=f.createRange()).setStart(p.offsetNode,p.offset),i.setEnd(p.offsetNode,p.offset))}if(!i)throw new Error("Cannot resolve a Slate range from a DOM event: ".concat(t));return Py.toSlateRange(e,i,{exactMatch:!1,suppressThrow:!1})},toSlateRange:function(e,t,n){var r,o,i,a,s,u=n.exactMatch,l=n.suppressThrow;if((Ym(t)?t.anchorNode:t.startContainer)&&(Ym(t)?(r=t.anchorNode,o=t.anchorOffset,i=t.focusNode,a=t.focusOffset,s=Fy&&window.document.activeElement&&window.document.activeElement.shadowRoot?t.anchorNode===t.focusNode&&t.anchorOffset===t.focusOffset:t.isCollapsed):(r=t.startContainer,o=t.startOffset,i=t.endContainer,a=t.endOffset,s=t.collapsed)),null==r||null==i||null==o||null==a)throw new Error("Cannot resolve a Slate range from DOM range: ".concat(t));var c=Py.toSlatePoint(e,[r,o],{exactMatch:u,suppressThrow:l});if(!c)return null;var d=s?c:Py.toSlatePoint(e,[i,a],{exactMatch:u,suppressThrow:l});if(!d)return null;var f={anchor:c,focus:d};return fg.isExpanded(f)&&fg.isForward(f)&&Km(i)&&Kh.void(e,{at:f.focus,mode:"highest"})&&(f=Kh.unhangRange(e,f,{voids:!0})),f},toSlatePoint:function(e,t,n){var r,o=n.exactMatch,i=n.suppressThrow,a=ev(o?t:function(e){var t,n=ev(e,2),r=n[0],o=n[1];if(Km(r)&&r.childNodes.length){var i=o===r.childNodes.length,a=i?o-1:o;for(r=(t=ev(Jm(r,a,i?"backward":"forward"),2))[0],i=(a=t[1])<o;Km(r)&&r.childNodes.length;){var s=i?r.childNodes.length-1:0;r=Qm(r,s,i?"backward":"forward")}o=i&&null!=r.textContent?r.textContent.length:0}return[r,o]}(t),2),s=a[0],u=a[1],l=s.parentNode,c=null,d=0;if(l){var f=l.closest('[data-slate-void="true"]'),p=l.closest("[data-slate-leaf]"),h=null,g=Py.getWindow(e);if(p&&g.document.createRange){c=p.closest('[data-slate-node="text"]');var v=g.document.createRange();v.setStart(c,0),v.setEnd(s,u);var m=v.cloneContents();tv(tv([],ev(Sy(m.querySelectorAll("[data-slate-zero-width]"))),!1),ev(Sy(m.querySelectorAll("[contenteditable=false]"))),!1).forEach(function(e){e.parentNode.removeChild(e)}),d=m.textContent.length,h=c}else f&&((p=f.querySelector("[data-slate-leaf]"))?(c=p.closest('[data-slate-node="text"]'),d=(h=p).textContent.length,h.querySelectorAll("[data-slate-zero-width]").forEach(function(e){d-=e.textContent.length})):d=1);h&&d===h.textContent.length&&(l.hasAttribute("data-slate-zero-width")||Ny&&(null===(r=h.textContent)||void 0===r?void 0:r.endsWith("\n")))&&(d-=1)}if(!c){if(i)return null;throw new Error("Cannot resolve a Slate point from DOM point: ".concat(t))}var y=Py.toSlateNode(e,c);return{path:Py.findPath(e,y),offset:d}},hasRange:function(e,t){var n=t.anchor,r=t.focus;return Kh.hasPath(e,n.path)&&Kh.hasPath(e,r.path)},getNodeType:function(e){return $h.isElement(e)?e.type:""},checkNodeType:function(e,t){return this.getNodeType(e)===t},getNodesStr:function(e){return e.map(function(e){return eg.string(e)}).join("")},getSelectedElems:function(e){var t,n,r=[],o=Kh.nodes(e,{universal:!0});try{for(var i=Qg(o),a=i.next();!a.done;a=i.next()){var s=ev(a.value,1)[0];$h.isElement(s)&&r.push(s)}}catch(e){t={error:e}}finally{try{a&&!a.done&&(n=i.return)&&n.call(i)}finally{if(t)throw t.error}}return r},getSelectedNodeByType:function(e,t){var n=this,r=ev(Kh.nodes(e,{match:function(e){return n.checkNodeType(e,t)},universal:!0}),1),o=r[0];return null==o?null:o[0]},getSelectedTextNode:function(e){var t=ev(Kh.nodes(e,{match:function(e){return Cg.isText(e)},universal:!0}),1),n=t[0];return null==n?null:n[0]},isNodeSelected:function(e,t){var n=ev(Kh.nodes(e,{match:function(e){return e===t},universal:!0}),1),r=n[0];return null!=r&&ev(r,1)[0]===t},isSelectionAtLineEnd:function(e,t){var n=e.selection;return!!n&&(Kh.isEnd(e,n.anchor,t)||Kh.isEnd(e,n.focus,t))},getTextarea:function(e){var t=Ev.get(e);if(null==t)throw new Error("Cannot find textarea instance by editor");return t},getToolbar:function(e){return wv.get(e)||null},getHoverbar:function(e){return Av.get(e)||null},normalizeContent:function(e){e.children.forEach(function(t,n){e.normalizeNode([t,[n]])})},getLeftLengthOfMaxLength:function(e){var t=e.getConfig(),n=t.maxLength,r=t.onMaxLength;if("number"!=typeof n||n<=0)return 1/0;var o=n-e.getText().replace(/\r|\n|(\r\n)|(\n\r)/g,"").length;return o<=0&&r&&r(e),o},cleanExposedTexNodeInSelectionBlock:function(e){var t,n,r,o,i=Py.getTextarea(e).$textArea,a=null==i?void 0:i[0].childNodes;if(a)try{for(var s=Qg(Array.from(a)),u=s.next();!u.done;u=s.next()){var l=u.value;if(!Xm(l))break;l.remove()}}catch(e){t={error:e}}finally{try{u&&!u.done&&(n=s.return)&&n.call(s)}finally{if(t)throw t.error}}var c=Kh.nodes(e,{match:function(t){return!(!$h.isElement(t)||e.isInline(t))},universal:!0});try{for(var d=Qg(c),f=d.next();!f.done;f=d.next()){var p=f.value;if(null!=p){var h=p[0];ty(Py.toDOMNode(e,h),function(e,t){var n=im(t);n.attr("data-slate-string")||n.attr("data-slate-zero-width")||n.attr("data-w-e-reserve")||t.removeChild(e)})}}}catch(e){r={error:e}}finally{try{f&&!f.done&&(o=d.return)&&o.call(d)}finally{if(r)throw r.error}}},isLastNode:function(e,t){var n=e.children||[];return n[n.length-1]===t},genEmptyParagraph:function(){return{type:"paragraph",children:[{text:""}]}},isSelectedVoidNode:function(e){var t,n,r=Kh.nodes(e,{match:function(t){return e.isVoid(t)}}),o=0;try{for(var i=Qg(r),a=i.next();!a.done;a=i.next()){a.value&&(o+=1)}}catch(e){t={error:e}}finally{try{a&&!a.done&&(n=i.return)&&n.call(i)}finally{if(t)throw t.error}}return o>0},isSelectedEmptyParagraph:function(e){var t=e.selection;if(null==t)return!1;if(fg.isExpanded(t))return!1;var n=Py.getSelectedNodeByType(e,"paragraph");if(null===n)return!1;var r=n.children;return 1===r.length&&(""===r[0].text||void 0)},isEmptyPath:function(e,t){var n=Kh.node(e,t);if(null==n)return!1;var r=ev(n,1)[0].children;if(1===r.length&&""===r[0].text)return!0;return!1}};function _y(e,t){return $h.isElement(e)?Dy(e,t):function(e,t){var n=e.text;if(null==n)throw new Error("Current node is not slate Text ".concat(JSON.stringify(e)));var r=n;r=function(e){return e.replace(/ {2}/g," ").replace(/</g,"<").replace(/>/g,">").replace(/®/g,"®").replace(/©/g,"©").replace(/™/g,"™")}(r);var o=Py.getParentsNodes(t,e).some(function(e){return"pre"===Py.getNodeType(e)});if(o||(r=r.replace(/\n\r|\r\n|\r|\n/g,"<br>")),o&&(r=r.replace(/ /g," ")),""===r){var i=Py.getParentNode(null,e);if(!i||0!==i.children.length)return r;r="<br>"}return my.forEach(function(t){return r=t(e,r)}),r}(e,t)}var Ly=function(e,t){var n=(t.top+t.bottom)/2;return e.top<=n&&e.bottom>=n},Ry=function(e,t,n){var r=Py.toDOMRange(e,t).getBoundingClientRect(),o=Py.toDOMRange(e,n).getBoundingClientRect();return Ly(r,o)&&Ly(o,r)},My=function(e,t){var n,r,o=[];try{for(var i=Qg(Kh.levels(e,{at:t})),a=i.next();!a.done;a=i.next()){var s=ev(a.value,2),u=s[0],l=s[1],c=Py.findKey(e,u);o.push([l,c])}}catch(e){n={error:e}}finally{try{a&&!a.done&&(r=i.return)&&r.call(i)}finally{if(n)throw n.error}}return o};function jy(e,t){e.isInline(t)?(e.insertNode(t),"link"===t.type&&e.insertFragment([{text:""}])):jg.insertNodes(e,t,{mode:"highest"})}var Hy,zy,$y,Uy,Vy,Wy,Gy,qy,Ky,Yy,Xy,Zy,Jy,Qy,eb,tb,nb,rb,ob,ib,ab,sb,ub,lb,cb,db,fb,pb,hb,gb,vb,mb,yb,bb,Eb,Cb,Db,wb,Sb,Ab,xb=function(e){var t=e,n=t.onChange,r=t.insertText,o=t.apply,i=t.deleteBackward;return t.insertText=function(e){t.getConfig().readOnly||r(e)},t.apply=function(e){var n,r,i,a,s,u,l,c,d=[];switch(e.type){case"insert_text":case"remove_text":case"set_node":case"split_node":d.push.apply(d,tv([],ev(My(t,e.path)),!1));break;case"insert_node":case"remove_node":d.push.apply(d,tv([],ev(My(t,og.parent(e.path))),!1));break;case"merge_node":var f=og.previous(e.path);d.push.apply(d,tv([],ev(My(t,f)),!1));break;case"move_node":var p=og.common(og.parent(e.path),og.parent(e.newPath));d.push.apply(d,tv([],ev(My(t,p)),!1));break;case"set_selection":(null===(a=null===(i=e.newProperties)||void 0===i?void 0:i.focus)||void 0===a?void 0:a.path)&&(d.push.apply(d,tv([],ev(My(t,null===(u=null===(s=e.newProperties)||void 0===s?void 0:s.focus)||void 0===u?void 0:u.path)),!1)),d.push.apply(d,tv([],ev(My(t,null===(c=null===(l=e.properties)||void 0===l?void 0:l.focus)||void 0===c?void 0:c.path)),!1)))}o(e);try{for(var h=Qg(d),g=h.next();!g.done;g=h.next()){var v=ev(g.value,2),m=v[0],y=v[1],b=ev(Kh.node(t,m),1)[0];zv.set(b,y),"type"in b&&(Iv.has(b)&&Iv.delete(b),Pv.has(b)&&Pv.delete(b))}}catch(e){n={error:e}}finally{try{g&&!g.done&&(r=h.return)&&r.call(h)}finally{if(n)throw n.error}}},t.deleteBackward=function(n){if("line"!==n)return i(n);if(e.selection&&fg.isCollapsed(e.selection)){var r=Kh.above(e,{match:function(t){return Kh.isBlock(e,t)},at:e.selection});if(r){var o=ev(r,2)[1],a=Kh.range(e,o,e.selection.anchor),s=function(e,t){var n=Kh.range(e,fg.end(t)),r=Array.from(Kh.positions(e,{at:t})),o=0,i=r.length,a=Math.floor(i/2);if(Ry(e,Kh.range(e,r[o]),n))return Kh.range(e,r[o],n);if(r.length<2)return Kh.range(e,r[r.length-1],n);for(;a!==r.length&&a!==o;)Ry(e,Kh.range(e,r[a]),n)?i=a:o=a,a=Math.floor((o+i)/2);return Kh.range(e,r[i],n)}(t,a);fg.isCollapsed(s)||jg.delete(e,{at:s})}}},t.onChange=function(){var e=t.selection;null!=e&&Vv.set(t,e),t.emit("change"),n()},t.handleTab=function(){t.insertText(" ")},t.getHtml=function(){var e=t.children,n=void 0===e?[]:e,r=t.getConfig().skipCacheTypes,o=void 0===r?["list-item"]:r;return n.map(function(e){var n=Py.getNodeType(e);if(o.includes(n))return _y(e,t);var r=Pv.get(e);if(r)return r;var i=_y(e,t);return Pv.set(e,i),i}).join("")},t.getText=function(){var e=t.children;return(void 0===e?[]:e).map(function(e){return eg.string(e)}).join("\n")},t.getSelectionText=function(){var n=t.selection;return null==n?"":Kh.string(e,n)},t.getElemsByType=function(e,n){var r,o;void 0===n&&(n=!1);var i=[],a=Kh.nodes(t,{at:[],universal:!0});try{for(var s=Qg(a),u=s.next();!u.done;u=s.next()){var l=ev(u.value,1)[0];if($h.isElement(l))if(n?l.type.indexOf(e)>=0:l.type===e){var c=Py.findKey(t,l),d=vy(l.type,c.id);i.push(Yg(Yg({},l),{id:d}))}}}catch(e){r={error:e}}finally{try{u&&!u.done&&(o=s.return)&&o.call(s)}finally{if(r)throw r.error}}return i},t.getElemsByTypePrefix=function(e){return t.getElemsByType(e,!0)},t.isEmpty=function(){var e=t.children,n=void 0===e?[]:e;if(n.length>1)return!1;var r=n[0];if(null==r)return!0;if(!$h.isElement(r)||"paragraph"!==r.type)return!1;var o=r.children,i=void 0===o?[]:o;if(i.length>1)return!1;var a=i[0];return null==a||Cg.isText(a)&&""===a.text},t.clear=function(){jg.delete(t,{at:{anchor:Kh.start(t,[]),focus:Kh.end(t,[])}}),0===t.children.length&&jg.insertNodes(t,[{type:"paragraph",children:[{text:""}]}])},t.getParentNode=function(e){return Py.getParentNode(t,e)},t.dangerouslyInsertHtml=function(e,n){if(void 0===e&&(e=""),void 0===n&&(n=!1),e){var r=document.createElement("div");r.innerHTML=e;var o=Array.from(r.childNodes);if(o=o.filter(function(e){var t=e.nodeName;return!!Xm(e)||!!Km(e)&&!Kv.has(t.toLowerCase())}),0!==o.length){var i=t.selection;if(null!=i){var a=null;if(Py.isSelectedEmptyParagraph(t)&&!n)a=[i.focus.path[0]];r.setAttribute("hidden","true"),document.body.appendChild(r);var s=0;o.forEach(function(e,n){var r=e.nodeName,i=e.textContent,a=void 0===i?"":i;if(Xm(e)){if(!a||!a.trim())return;t.insertNode({text:a})}else if("BR"!==r){var u=e,l=!1;if(iy.includes(r.toLowerCase()))l=!0;else for(var c in uy)if(u.matches(c)){l=!0;break}if(l){var d=py(im(u),t);return Array.isArray(d)?(d.forEach(function(e){return jy(t,e)}),s+=1):(jy(t,d),s+=1),void(Py.isSelectedVoidNode(t)&&t.move(1))}var f=window.getComputedStyle(u).display;if(!Py.isSelectedEmptyParagraph(t)&&f.indexOf("inline")<0){if(n>=1)(function(e){return"matches"in e&&/^[ou]l$/i.test(e.tagName)&&!e.hasAttribute("data-w-e-type")})(o[n-1])&&t.insertBreak();t.insertBreak()}t.dangerouslyInsertHtml(u.innerHTML,!0)}else t.insertText("\n")}),s&&a&&Py.isEmptyPath(t,a)&&jg.removeNodes(t,{at:a}),r.remove()}}}},t.setHtml=function(e){void 0===e&&(e="");var n=t.isDisabled(),r=t.isFocused(),o=JSON.stringify(t.selection);t.enable(),t.focus(),t.clear();var i=gy(t,null==e?"":e);if(jg.insertFragment(t,i),r||(t.deselect(),t.blur()),n&&(t.deselect(),t.disable()),t.isFocused())try{t.select(JSON.parse(o))}catch(e){t.select(Kh.start(t,[]))}},t},Ob=1,Nb=function(e){var t=e;return t.id="wangEditor-".concat(Ob++),t.isDestroyed=!1,t.isFullScreen=!1,t.focus=function(e){if(Py.toDOMNode(t,t).focus({preventScroll:!0}),Uv.set(t,!0),e){var n=Kh.end(t,[]);jg.select(t,n)}else{var r=Vv.get(t);r?jg.select(t,r):jg.select(t,Kh.start(t,[]))}},t.isFocused=function(){return!!Uv.get(t)},t.blur=function(){Py.toDOMNode(t,t).blur(),jg.deselect(t),Uv.set(t,!1)},t.updateView=function(){Py.getTextarea(t).changeViewState();var e=Py.getToolbar(t);e&&e.changeToolbarState();var n=Py.getHoverbar(t);n&&n.changeHoverbarState()},t.destroy=function(){if(!t.isDestroyed){var e=Py.getTextarea(t);e.destroy(),Ev.delete(t),Cv.delete(e);var n=Py.getToolbar(t);n&&(n.destroy(),wv.delete(t),Dv.delete(n));var r=Py.getHoverbar(t);r&&(r.destroy(),Av.delete(t),Sv.delete(r)),t.isDestroyed=!0,t.emit("destroyed")}},t.scrollToElem=function(e){if(!t.getConfig().scroll){var n="编辑器禁用了 scroll ,编辑器内容无法滚动,请自行实现该功能";return n+="\nYou has disabled editor scroll, please do this yourself",void console.warn(n)}var r=im("#".concat(e));if(0!==r.length){var o=r[0];if(!Py.hasDOMNode(t,o)){n="Element (found by id is '".concat(e,"') is not in editor DOM");return n+="\n 通过 id '".concat(e,"' 找到的 element 不在 editor DOM 之内"),void console.error(n,o)}var i=Py.getTextarea(t),a=i.$textAreaContainer,s=i.$scroll,u=r.offset().top,l=a.offset().top;s[0].scrollBy({top:u-l,behavior:"smooth"})}},t.showProgressBar=function(e){e<1||Py.getTextarea(t).changeProgress(e)},t.hidePanelOrModal=function(){var e=Ov.get(t);null!=e&&e.forEach(function(e){return e.hide()})},t.enable=function(){t.getConfig().readOnly=!1,t.updateView()},t.disable=function(){t.getConfig().readOnly=!0,t.updateView()},t.isDisabled=function(){return t.getConfig().readOnly},t.toDOMNode=function(e){return Py.toDOMNode(t,e)},t.fullScreen=function(){if(!t.isFullScreen){var e=null,n=Py.getToolbar(t);n&&(e=n.$box);var r=Py.getTextarea(t).$box.parent();if(e&&e.parent()[0]!==r[0]){throw new Error("Can not set full screen, cause toolbar DOM parent is not equal to textarea DOM parent\n不能设置全屏,因为 toolbar DOM 父节点和 textarea DOM 父节点不一致")}r.addClass("w-e-full-screen-container");var o=r.css("z-index");r.attr("data-z-index",o.toString()),t.isFullScreen=!0,t.emit("fullScreen")}},t.unFullScreen=function(){if(t.isFullScreen){var e=Py.getTextarea(t).$box.parent();setTimeout(function(){e.removeClass("w-e-full-screen-container"),t.isFullScreen=!1,t.emit("unFullScreen")},200)}},t.getEditableContainer=function(){return Py.getTextarea(t).$textAreaContainer[0]},t},Bb={exports:{}},Tb={exports:{}};function kb(){if(zy)return Hy;zy=1;return Hy=function(e){return null!=e}}function Fb(){if(Wy)return Vy;Wy=1;var e=function(){if(Uy)return $y;Uy=1;var e=kb(),t={object:!0,function:!0,undefined:!0};return $y=function(n){return!!e(n)&&hasOwnProperty.call(t,typeof n)}}();return Vy=function(t){if(!e(t))return!1;try{return!!t.constructor&&t.constructor.prototype===t}catch(e){return!1}}}function Ib(){if(Yy)return Ky;Yy=1;var e=function(){if(qy)return Gy;qy=1;var e=Fb();return Gy=function(t){if("function"!=typeof t)return!1;if(!hasOwnProperty.call(t,"length"))return!1;try{if("number"!=typeof t.length)return!1;if("function"!=typeof t.call)return!1;if("function"!=typeof t.apply)return!1}catch(e){return!1}return!e(t)}}(),t=/^\s*class[\s{/}]/,n=Function.prototype.toString;return Ky=function(r){return!!e(r)&&!t.test(n.call(r))}}function Pb(){if(rb)return nb;rb=1;var e=(tb?eb:(tb=1,eb=function(){}))();return nb=function(t){return t!==e&&null!==t},nb}function _b(){return sb||(sb=1,ab=(Qy?Jy:(Qy=1,Jy=function(){try{return Object.keys("primitive"),!0}catch(e){return!1}}))()?Object.keys:function(){if(ib)return ob;ib=1;var e=Pb(),t=Object.keys;return ob=function(n){return t(e(n)?Object(n):n)}}()),ab}function Lb(){if(db)return cb;db=1;var e=_b(),t=function(){if(lb)return ub;lb=1;var e=Pb();return ub=function(t){if(!e(t))throw new TypeError("Cannot use null or undefined");return t}}(),n=Math.max;return cb=function(r,o){var i,a,s,u=n(arguments.length,2);for(r=Object(t(r)),s=function(e){try{r[e]=o[e]}catch(e){i||(i=e)}},a=1;a<u;++a)e(o=arguments[a]).forEach(s);if(void 0!==i)throw i;return r},cb}function Rb(){return pb?fb:(pb=1,fb=(Zy||(Zy=1,Xy=function(){var e,t=Object.assign;return"function"==typeof t&&(t(e={foo:"raz"},{bar:"dwa"},{trzy:"trzy"}),e.foo+e.bar+e.trzy==="razdwatrzy")}),Xy)()?Object.assign:Lb())}function Mb(){return Cb||(Cb=1,Eb=function(){if(mb)return vb;mb=1;var e="razdwatrzy";return vb=function(){return"function"==typeof e.contains&&!0===e.contains("dwa")&&!1===e.contains("foo")}}()()?String.prototype.contains:function(){if(bb)return yb;bb=1;var e=String.prototype.indexOf;return yb=function(t){return e.call(this,t,arguments[1])>-1},yb}()),Eb}function jb(){if(Db)return Tb.exports;Db=1;var e=kb(),t=Ib(),n=Rb(),r=function(){if(gb)return hb;gb=1;var e=Pb(),t=Array.prototype.forEach,n=Object.create;return hb=function(r){var o=n(null);return t.call(arguments,function(t){e(t)&&function(e,t){var n;for(n in e)t[n]=e[n]}(Object(t),o)}),o},hb}(),o=Mb(),i=Tb.exports=function(t,i){var a,s,u,l,c;return arguments.length<2||"string"!=typeof t?(l=i,i=t,t=null):l=arguments[2],e(t)?(a=o.call(t,"c"),s=o.call(t,"e"),u=o.call(t,"w")):(a=u=!0,s=!1),c={value:i,configurable:a,enumerable:s,writable:u},l?n(r(l),c):c};return i.gs=function(i,a,s){var u,l,c,d;return"string"!=typeof i?(c=s,s=a,a=i,i=null):c=arguments[3],e(a)?t(a)?e(s)?t(s)||(c=s,s=void 0):s=void 0:(c=a,a=s=void 0):a=void 0,e(i)?(u=o.call(i,"c"),l=o.call(i,"e")):(u=!0,l=!1),d={get:a,set:s,configurable:u,enumerable:l},c?n(r(c),d):d},Tb.exports}var Hb=(Ab||(Ab=1,function(e,t){var n,r,o,i,a,s,u,l=jb(),c=(Sb||(Sb=1,wb=function(e){if("function"!=typeof e)throw new TypeError(e+" is not a function");return e}),wb),d=Function.prototype.apply,f=Function.prototype.call,p=Object.create,h=Object.defineProperty,g=Object.defineProperties,v=Object.prototype.hasOwnProperty,m={configurable:!0,enumerable:!1,writable:!0};n=function(e,t){var n;return c(t),v.call(this,"__ee__")?n=this.__ee__:(n=m.value=p(null),h(this,"__ee__",m),m.value=null),n[e]?"object"==typeof n[e]?n[e].push(t):n[e]=[n[e],t]:n[e]=t,this},r=function(e,t){var r,i;return c(t),i=this,n.call(this,e,r=function(){o.call(i,e,r),d.call(t,this,arguments)}),r.__eeOnceListener__=t,this},o=function(e,t){var n,r,o,i;if(c(t),!v.call(this,"__ee__"))return this;if(!(n=this.__ee__)[e])return this;if("object"==typeof(r=n[e]))for(i=0;o=r[i];++i)o!==t&&o.__eeOnceListener__!==t||(2===r.length?n[e]=r[i?0:1]:r.splice(i,1));else r!==t&&r.__eeOnceListener__!==t||delete n[e];return this},i=function(e){var t,n,r,o,i;if(v.call(this,"__ee__")&&(o=this.__ee__[e]))if("object"==typeof o){for(n=arguments.length,i=new Array(n-1),t=1;t<n;++t)i[t-1]=arguments[t];for(o=o.slice(),t=0;r=o[t];++t)d.call(r,this,i)}else switch(arguments.length){case 1:f.call(o,this);break;case 2:f.call(o,this,arguments[1]);break;case 3:f.call(o,this,arguments[1],arguments[2]);break;default:for(n=arguments.length,i=new Array(n-1),t=1;t<n;++t)i[t-1]=arguments[t];d.call(o,this,i)}},a={on:n,once:r,off:o,emit:i},s={on:l(n),once:l(r),off:l(o),emit:l(i)},u=g({},s),e.exports=t=function(e){return null==e?p(u):g(Object(e),s)},t.methods=a}(Bb,Bb.exports)),Bb.exports),zb=b(Hb);function $b(e){var t=Wv.get(e);return null==t&&(t=zb(),Wv.set(e,t)),t}var Ub=new WeakMap;function Vb(e,t){var n=Ub.get(e);null==n&&(n=new Set,Ub.set(e,n)),n.add(t)}var Wb=function(e){var t=e;return t.on=function(e,n){var r=$b(t);if(r.on(e,n),"destroyed"===e&&Vb(t,n),"destroyed"!==e){var o=function(){return r.off(e,n)};r.on("destroyed",o),Vb(t,o)}},t.once=function(e,n){$b(t).once(e,n)},t.off=function(e,n){$b(t).off(e,n)},t.emit=function(e){for(var n=[],r=1;r<arguments.length;r++)n[r-1]=arguments[r];var o=$b(t);if(o.emit.apply(o,tv([e],ev(n),!1)),"destroyed"===e){var i=function(e){return Ub.get(e)||new Set}(t);i.forEach(function(e){return o.off("destroyed",e)}),function(e){Ub.set(e,new Set)}(t)}},t},Gb=function(e){var t=e;return t.setFragmentData=function(e){var n=t.selection;if(n){var r=ev(fg.edges(n),2),o=r[0],i=r[1],a=Kh.void(t,{at:o.path}),s=Kh.void(t,{at:i.path});if(!fg.isCollapsed(n)||a){var u=Py.toDOMRange(t,n),l=u.cloneContents(),c=l.childNodes[0];if(l.childNodes.forEach(function(e){e.textContent&&""!==e.textContent.trim()&&(c=e)}),s){var d=ev(s,1)[0],f=u.cloneRange(),p=Py.toDOMNode(t,d);f.setEndAfter(p),l=f.cloneContents()}if(a&&(c=l.querySelector("[data-slate-spacer]")),Array.from(l.querySelectorAll("[data-slate-zero-width]")).forEach(function(e){var t="n"===e.getAttribute("data-slate-zero-width");e.textContent=t?"\n":""}),Xm(c)){var h=c.ownerDocument.createElement("span");h.style.whiteSpace="pre",h.appendChild(c),l.appendChild(h),c=h}var g=t.getFragment(),v=JSON.stringify(g),m=window.btoa(encodeURIComponent(v));c.setAttribute("data-slate-fragment",m),e.setData("application/x-slate-fragment",m);var y=l.ownerDocument.createElement("div");return y.appendChild(l),y.setAttribute("hidden","true"),l.ownerDocument.body.appendChild(y),e.setData("text/html",y.innerHTML),e.setData("text/plain",ey(y)),l.ownerDocument.body.removeChild(y),e}}},t.insertData=function(e){var n,r,o=e.getData("application/x-slate-fragment");if(o){var i=decodeURIComponent(window.atob(o)),a=JSON.parse(i);t.insertFragment(a)}else{var s=e.getData("text/plain"),u=e.getData("text/html");if(u)t.dangerouslyInsertHtml(u);else if(s){var l=s.split(/\n\r|\r\n|\r|\n/),c=!1;try{for(var d=Qg(l),f=d.next();!f.done;f=d.next()){var p=f.value,h=Py.getLeftLengthOfMaxLength(t);c&&h>0&&jg.splitNodes(t,{always:!0}),t.insertText(p),c=!0}}catch(e){n={error:e}}finally{try{f&&!f.done&&(r=d.return)&&r.call(d)}finally{if(n)throw n.error}}}}},t},qb=function(e){var t=e,n=t.insertText,r=t.insertNode,o=t.insertFragment,i=t.dangerouslyInsertHtml;return t.insertText=function(e){if(t.getConfig().maxLength){var r=Py.getLeftLengthOfMaxLength(t);r<=0||(r<e.length?n(e.slice(0,r)):n(e))}else n(e)},t.insertNode=function(e){if(t.getConfig().maxLength){var n=Py.getLeftLengthOfMaxLength(t);if(!(n<=0))n<eg.string(e).length||r(e)}else r(e)},t.insertFragment=function(e){if(t.getConfig().maxLength){if(e.length>0){var n=e[0];if(Py.getLeftLengthOfMaxLength(t)<eg.string(n).length)return;o([n]);for(var r=1;r<e.length;r+=1)t.insertNode(e[r])}}else o(e)},t.dangerouslyInsertHtml=function(e,n){if(void 0===e&&(e=""),void 0===n&&(n=!1),e)if(t.getConfig().maxLength){var r=Py.getLeftLengthOfMaxLength(t);if(!(r<=0)){var o=document.createElement("div");o.innerHTML=e,r<Array.from(o.childNodes).reduce(function(e,t){var n=t.nodeName;return t?Xm(t)?e+(t.textContent||""):Km(t)?Kv.has(n.toLowerCase())?e:e+(t.textContent||""):e:e},"").length||i(e,n)}}else i(e,n)},t};function Kb(e){var t=Py.getTextarea(e).$textAreaContainer,n=t.width(),r=t.height(),o=t.offset();return{top:o.top,left:o.left,width:n,height:r}}function Yb(e){var t={top:"0",left:"0"},n=e.selection;if(null==n)return t;var r=Kb(e);if(null==r)return t;var o=r.top,i=r.left,a=r.width,s=r.height,u=Py.toDOMRange(e,n).getClientRects(),l=u?u[0]:null;if(null==l)return t;var c={},d=l.top-o,f=l.left-i;if(f>a/2){var p=a-f;c.right="".concat(p+5,"px")}else c.left="".concat(f+5,"px");if(d>s/2){var h=s-d;c.bottom="".concat(h+5,"px")}else{var g=u[u.length-1],v=g.top-o+g.height;v<0&&(v=0),c.top="".concat(v+5,"px")}return c}function Xb(e,t,n){void 0===n&&(n="modal");var r={top:"0",left:"0"};if(null==e.selection)return r;var o=$h.isElement(t)&&e.isVoid(t),i=$h.isElement(t)&&e.isInline(t),a=Hv.get(t);if(null==a)return r;var s=a.getBoundingClientRect(),u=s.top,l=s.left,c=s.height,d=s.width;if(o){var f=function(e){var t=[];t.push(e);for(var n=0;t.length>0;){var r=t.pop();if(null==r)break;if((n+=1)>1e4)break;var o=r.nodeName;if(r.nodeType===$m.ELEMENT_NODE){var i=o.toLowerCase();if(jm.includes(i)||"iframe"===i||"video"===i)return r;var a=r.children||[],s=a.length;if(s)for(var u=s-1;u>=0;u-=1)t.push(a[u])}}return null}(a);if(null!=f){var p=f.getBoundingClientRect();u=p.top,c=p.height}}var h=Kb(e);if(null==h)return r;var g=h.top,v=h.left,m=h.width,y=h.height,b={},E=u-g,C=l-v;if("bar"===n)return b.left="".concat(C,"px"),E>40?b.bottom="".concat(y-E+5,"px"):b.top="".concat(E+c+5,"px"),b;if("modal"===n){if(o?i?C>(m-d)/2?b.right="".concat(m-C+5,"px"):b.left="".concat(C+d+5,"px"):b.left="20px":b.left="".concat(C,"px"),o)(D=E)<0&&(D=0),b.top="".concat(D,"px");else if(E>(y-c)/2)b.bottom="".concat(y-E+5,"px");else{var D;(D=E+c)<0&&(D=0),b.top="".concat(D+5,"px")}return b}throw new Error("type '".concat(n,"' is invalid"))}function Zb(e,t){zm(function(){var n=Kb(e);if(null!=n){var r,o=n.top,i=n.left,a=n.width,s=n.height,u=t.offset(),l=u.top,c=u.left,d=t.width(),f=t.height(),p=l-o,h=c-i,g=t.attr("style");if(g.indexOf("top")>=0)if((r=p+f-s)>0){var v=t.css("top"),m=parseInt(v.toString(),10)-r;m<0&&(m=0),t.css("top","".concat(m,"px"))}if(g.indexOf("bottom")>=0&&l<0){var y=t.css("bottom"),b=parseInt(y.toString(),10)-Math.abs(l);t.css("bottom","".concat(b,"px"))}if(g.indexOf("left")>=0)if((r=h+d-a)>0){var E=t.css("left"),C=parseInt(E.toString(),10)-r;C<0&&(C=0),t.css("left","".concat(C,"px"))}if(g.indexOf("right")>=0&&c<0){var D=t.css("right"),w=parseInt(D.toString(),10)-Math.abs(c);t.css("right","".concat(w,"px"))}}})}var Jb,Qb,eE=function(e){var t=e;return t.select=function(e){jg.select(t,e)},t.deselect=function(){var n=t.selection,r=Py.findDocumentOrShadowRoot(t).getSelection();r&&r.rangeCount>0&&r.removeAllRanges(),n&&jg.deselect(e)},t.move=function(t,n){void 0===n&&(n=!1),t&&(t<0||jg.move(e,{distance:t,unit:"character",reverse:n}))},t.moveReverse=function(e){t.move(e,!0)},t.restoreSelection=function(){var e=Vv.get(t);null!=e&&(t.focus(),jg.select(t,e))},t.getSelectionPosition=function(){return Yb(t)},t.getNodePosition=function(e){return Xb(t,e)},t.isSelectedAll=function(){var e=t.selection;if(null==e)return!1;var n=ev(fg.edges(e),2),r=n[0],o=n[1],i=ev(Kh.edges(t,[]),2),a=i[0],s=i[1];return!(!ug.equals(r,a)||!ug.equals(o,s))},t.selectAll=function(){var e=Kh.start(t,[]),n=Kh.end(t,[]);jg.select(t,{anchor:e,focus:n})},t};var tE=function(){if(Qb)return Jb;Qb=1;var e=/^\s+|\s+$/g,t=/^[-+]0x[0-9a-f]+$/i,n=/^0b[01]+$/i,r=/^0o[0-7]+$/i,o=parseInt,i="object"==typeof y&&y&&y.Object===Object&&y,a="object"==typeof self&&self&&self.Object===Object&&self,s=i||a||Function("return this")(),u=Object.prototype.toString,l=Math.max,c=Math.min,d=function(){return s.Date.now()};function f(e){var t=typeof e;return!!e&&("object"==t||"function"==t)}function p(i){if("number"==typeof i)return i;if(function(e){return"symbol"==typeof e||function(e){return!!e&&"object"==typeof e}(e)&&"[object Symbol]"==u.call(e)}(i))return NaN;if(f(i)){var a="function"==typeof i.valueOf?i.valueOf():i;i=f(a)?a+"":a}if("string"!=typeof i)return 0===i?i:+i;i=i.replace(e,"");var s=n.test(i);return s||r.test(i)?o(i.slice(2),s?2:8):t.test(i)?NaN:+i}return Jb=function(e,t,n){var r,o,i,a,s,u,h=0,g=!1,v=!1,m=!0;if("function"!=typeof e)throw new TypeError("Expected a function");function y(t){var n=r,i=o;return r=o=void 0,h=t,a=e.apply(i,n)}function b(e){var n=e-u;return void 0===u||n>=t||n<0||v&&e-h>=i}function E(){var e=d();if(b(e))return C(e);s=setTimeout(E,function(e){var n=t-(e-u);return v?c(n,i-(e-h)):n}(e))}function C(e){return s=void 0,m&&r?y(e):(r=o=void 0,a)}function D(){var e=d(),n=b(e);if(r=arguments,o=this,u=e,n){if(void 0===s)return function(e){return h=e,s=setTimeout(E,t),g?y(e):a}(u);if(v)return s=setTimeout(E,t),y(u)}return void 0===s&&(s=setTimeout(E,t)),a}return t=p(t)||0,f(n)&&(g=!!n.leading,i=(v="maxWait"in n)?l(p(n.maxWait)||0,t):i,m="trailing"in n?!!n.trailing:m),D.cancel=function(){void 0!==s&&clearTimeout(s),h=0,r=u=o=s=void 0},D.flush=function(){return void 0===s?a:C(d())},D},Jb}(),nE=b(tE);const rE=e=>"string"==typeof e,oE=()=>{let e,t;const n=new Promise((n,r)=>{e=n,t=r});return n.resolve=e,n.reject=t,n},iE=e=>null==e?"":""+e,aE=/###/g,sE=e=>e&&e.indexOf("###")>-1?e.replace(aE,"."):e,uE=e=>!e||rE(e),lE=(e,t,n)=>{const r=rE(t)?t.split("."):t;let o=0;for(;o<r.length-1;){if(uE(e))return{};const t=sE(r[o]);!e[t]&&n&&(e[t]=new n),e=Object.prototype.hasOwnProperty.call(e,t)?e[t]:{},++o}return uE(e)?{}:{obj:e,k:sE(r[o])}},cE=(e,t,n)=>{const{obj:r,k:o}=lE(e,t,Object);if(void 0!==r||1===t.length)return void(r[o]=n);let i=t[t.length-1],a=t.slice(0,t.length-1),s=lE(e,a,Object);for(;void 0===s.obj&&a.length;)i=`${a[a.length-1]}.${i}`,a=a.slice(0,a.length-1),s=lE(e,a,Object),s&&s.obj&&void 0!==s.obj[`${s.k}.${i}`]&&(s.obj=void 0);s.obj[`${s.k}.${i}`]=n},dE=(e,t)=>{const{obj:n,k:r}=lE(e,t);if(n)return n[r]},fE=(e,t,n)=>{for(const r in t)"__proto__"!==r&&"constructor"!==r&&(r in e?rE(e[r])||e[r]instanceof String||rE(t[r])||t[r]instanceof String?n&&(e[r]=t[r]):fE(e[r],t[r],n):e[r]=t[r]);return e},pE=e=>e.replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g,"\\$&");var hE={"&":"&","<":"<",">":">",'"':""","'":"'","/":"/"};const gE=e=>rE(e)?e.replace(/[&<>"'\/]/g,e=>hE[e]):e;const vE=[" ",",","?","!",";"],mE=new class{constructor(e){this.capacity=e,this.regExpMap=new Map,this.regExpQueue=[]}getRegExp(e){const t=this.regExpMap.get(e);if(void 0!==t)return t;const n=new RegExp(e);return this.regExpQueue.length===this.capacity&&this.regExpMap.delete(this.regExpQueue.shift()),this.regExpMap.set(e,n),this.regExpQueue.push(e),n}}(20),yE=function(e,t){let n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:".";if(!e)return;if(e[t])return e[t];const r=t.split(n);let o=e;for(let e=0;e<r.length;){if(!o||"object"!=typeof o)return;let t,i="";for(let a=e;a<r.length;++a)if(a!==e&&(i+=n),i+=r[a],t=o[i],void 0!==t){if(["string","number","boolean"].indexOf(typeof t)>-1&&a<r.length-1)continue;e+=a-e+1;break}o=t}return o},bE=e=>e&&e.replace("_","-"),EE={type:"logger",log(e){this.output("log",e)},warn(e){this.output("warn",e)},error(e){this.output("error",e)},output(e,t){console&&console[e]&&console[e].apply(console,t)}};class CE{constructor(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};this.init(e,t)}init(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};this.prefix=t.prefix||"i18next:",this.logger=e||EE,this.options=t,this.debug=t.debug}log(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return this.forward(t,"log","",!0)}warn(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return this.forward(t,"warn","",!0)}error(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return this.forward(t,"error","")}deprecate(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return this.forward(t,"warn","WARNING DEPRECATED: ",!0)}forward(e,t,n,r){return r&&!this.debug?null:(rE(e[0])&&(e[0]=`${n}${this.prefix} ${e[0]}`),this.logger[t](e))}create(e){return new CE(this.logger,{prefix:`${this.prefix}:${e}:`,...this.options})}clone(e){return(e=e||this.options).prefix=e.prefix||this.prefix,new CE(this.logger,e)}}var DE=new CE;class wE{constructor(){this.observers={}}on(e,t){return e.split(" ").forEach(e=>{this.observers[e]||(this.observers[e]=new Map);const n=this.observers[e].get(t)||0;this.observers[e].set(t,n+1)}),this}off(e,t){this.observers[e]&&(t?this.observers[e].delete(t):delete this.observers[e])}emit(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];if(this.observers[e]){Array.from(this.observers[e].entries()).forEach(e=>{let[t,r]=e;for(let e=0;e<r;e++)t(...n)})}if(this.observers["*"]){Array.from(this.observers["*"].entries()).forEach(t=>{let[r,o]=t;for(let t=0;t<o;t++)r.apply(r,[e,...n])})}}}class SE extends wE{constructor(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{ns:["translation"],defaultNS:"translation"};super(),this.data=e||{},this.options=t,void 0===this.options.keySeparator&&(this.options.keySeparator="."),void 0===this.options.ignoreJSONStructure&&(this.options.ignoreJSONStructure=!0)}addNamespaces(e){this.options.ns.indexOf(e)<0&&this.options.ns.push(e)}removeNamespaces(e){const t=this.options.ns.indexOf(e);t>-1&&this.options.ns.splice(t,1)}getResource(e,t,n){let r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{};const o=void 0!==r.keySeparator?r.keySeparator:this.options.keySeparator,i=void 0!==r.ignoreJSONStructure?r.ignoreJSONStructure:this.options.ignoreJSONStructure;let a;e.indexOf(".")>-1?a=e.split("."):(a=[e,t],n&&(Array.isArray(n)?a.push(...n):rE(n)&&o?a.push(...n.split(o)):a.push(n)));const s=dE(this.data,a);return!s&&!t&&!n&&e.indexOf(".")>-1&&(e=a[0],t=a[1],n=a.slice(2).join(".")),!s&&i&&rE(n)?yE(this.data&&this.data[e]&&this.data[e][t],n,o):s}addResource(e,t,n,r){let o=arguments.length>4&&void 0!==arguments[4]?arguments[4]:{silent:!1};const i=void 0!==o.keySeparator?o.keySeparator:this.options.keySeparator;let a=[e,t];n&&(a=a.concat(i?n.split(i):n)),e.indexOf(".")>-1&&(a=e.split("."),r=t,t=a[1]),this.addNamespaces(t),cE(this.data,a,r),o.silent||this.emit("added",e,t,n,r)}addResources(e,t,n){let r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{silent:!1};for(const r in n)(rE(n[r])||Array.isArray(n[r]))&&this.addResource(e,t,r,n[r],{silent:!0});r.silent||this.emit("added",e,t,n)}addResourceBundle(e,t,n,r,o){let i=arguments.length>5&&void 0!==arguments[5]?arguments[5]:{silent:!1,skipCopy:!1},a=[e,t];e.indexOf(".")>-1&&(a=e.split("."),r=n,n=t,t=a[1]),this.addNamespaces(t);let s=dE(this.data,a)||{};i.skipCopy||(n=JSON.parse(JSON.stringify(n))),r?fE(s,n,o):s={...s,...n},cE(this.data,a,s),i.silent||this.emit("added",e,t,n)}removeResourceBundle(e,t){this.hasResourceBundle(e,t)&&delete this.data[e][t],this.removeNamespaces(t),this.emit("removed",e,t)}hasResourceBundle(e,t){return void 0!==this.getResource(e,t)}getResourceBundle(e,t){return t||(t=this.options.defaultNS),"v1"===this.options.compatibilityAPI?{...this.getResource(e,t)}:this.getResource(e,t)}getDataByLanguage(e){return this.data[e]}hasLanguageSomeTranslations(e){const t=this.getDataByLanguage(e);return!!(t&&Object.keys(t)||[]).find(e=>t[e]&&Object.keys(t[e]).length>0)}toJSON(){return this.data}}var AE={processors:{},addPostProcessor(e){this.processors[e.name]=e},handle(e,t,n,r,o){return e.forEach(e=>{this.processors[e]&&(t=this.processors[e].process(t,n,r,o))}),t}};const xE={};class OE extends wE{constructor(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};super(),((e,t,n)=>{e.forEach(e=>{t[e]&&(n[e]=t[e])})})(["resourceStore","languageUtils","pluralResolver","interpolator","backendConnector","i18nFormat","utils"],e,this),this.options=t,void 0===this.options.keySeparator&&(this.options.keySeparator="."),this.logger=DE.create("translator")}changeLanguage(e){e&&(this.language=e)}exists(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{interpolation:{}};if(null==e)return!1;const n=this.resolve(e,t);return n&&void 0!==n.res}extractFromKey(e,t){let n=void 0!==t.nsSeparator?t.nsSeparator:this.options.nsSeparator;void 0===n&&(n=":");const r=void 0!==t.keySeparator?t.keySeparator:this.options.keySeparator;let o=t.ns||this.options.defaultNS||[];const i=n&&e.indexOf(n)>-1,a=!(this.options.userDefinedKeySeparator||t.keySeparator||this.options.userDefinedNsSeparator||t.nsSeparator||((e,t,n)=>{t=t||"",n=n||"";const r=vE.filter(e=>t.indexOf(e)<0&&n.indexOf(e)<0);if(0===r.length)return!0;const o=mE.getRegExp(`(${r.map(e=>"?"===e?"\\?":e).join("|")})`);let i=!o.test(e);if(!i){const t=e.indexOf(n);t>0&&!o.test(e.substring(0,t))&&(i=!0)}return i})(e,n,r));if(i&&!a){const t=e.match(this.interpolator.nestingRegexp);if(t&&t.length>0)return{key:e,namespaces:rE(o)?[o]:o};const i=e.split(n);(n!==r||n===r&&this.options.ns.indexOf(i[0])>-1)&&(o=i.shift()),e=i.join(r)}return{key:e,namespaces:rE(o)?[o]:o}}translate(e,t,n){if("object"!=typeof t&&this.options.overloadTranslationOptionHandler&&(t=this.options.overloadTranslationOptionHandler(arguments)),"object"==typeof t&&(t={...t}),t||(t={}),null==e)return"";Array.isArray(e)||(e=[String(e)]);const r=void 0!==t.returnDetails?t.returnDetails:this.options.returnDetails,o=void 0!==t.keySeparator?t.keySeparator:this.options.keySeparator,{key:i,namespaces:a}=this.extractFromKey(e[e.length-1],t),s=a[a.length-1],u=t.lng||this.language,l=t.appendNamespaceToCIMode||this.options.appendNamespaceToCIMode;if(u&&"cimode"===u.toLowerCase()){if(l){const e=t.nsSeparator||this.options.nsSeparator;return r?{res:`${s}${e}${i}`,usedKey:i,exactUsedKey:i,usedLng:u,usedNS:s,usedParams:this.getUsedParamsDetails(t)}:`${s}${e}${i}`}return r?{res:i,usedKey:i,exactUsedKey:i,usedLng:u,usedNS:s,usedParams:this.getUsedParamsDetails(t)}:i}const c=this.resolve(e,t);let d=c&&c.res;const f=c&&c.usedKey||i,p=c&&c.exactUsedKey||i,h=Object.prototype.toString.apply(d),g=void 0!==t.joinArrays?t.joinArrays:this.options.joinArrays,v=!this.i18nFormat||this.i18nFormat.handleAsObject,m=!rE(d)&&"boolean"!=typeof d&&"number"!=typeof d;if(!(v&&d&&m&&["[object Number]","[object Function]","[object RegExp]"].indexOf(h)<0)||rE(g)&&Array.isArray(d))if(v&&rE(g)&&Array.isArray(d))d=d.join(g),d&&(d=this.extendTranslation(d,e,t,n));else{let r=!1,a=!1;const l=void 0!==t.count&&!rE(t.count),f=OE.hasDefaultValue(t),p=l?this.pluralResolver.getSuffix(u,t.count,t):"",h=t.ordinal&&l?this.pluralResolver.getSuffix(u,t.count,{ordinal:!1}):"",g=l&&!t.ordinal&&0===t.count&&this.pluralResolver.shouldUseIntlApi(),v=g&&t[`defaultValue${this.options.pluralSeparator}zero`]||t[`defaultValue${p}`]||t[`defaultValue${h}`]||t.defaultValue;!this.isValidLookup(d)&&f&&(r=!0,d=v),this.isValidLookup(d)||(a=!0,d=i);const m=(t.missingKeyNoValueFallbackToKey||this.options.missingKeyNoValueFallbackToKey)&&a?void 0:d,y=f&&v!==d&&this.options.updateMissing;if(a||r||y){if(this.logger.log(y?"updateKey":"missingKey",u,s,i,y?v:d),o){const e=this.resolve(i,{...t,keySeparator:!1});e&&e.res&&this.logger.warn("Seems the loaded translations were in flat JSON format instead of nested. Either set keySeparator: false on init or make sure your translations are published in nested format.")}let e=[];const n=this.languageUtils.getFallbackCodes(this.options.fallbackLng,t.lng||this.language);if("fallback"===this.options.saveMissingTo&&n&&n[0])for(let t=0;t<n.length;t++)e.push(n[t]);else"all"===this.options.saveMissingTo?e=this.languageUtils.toResolveHierarchy(t.lng||this.language):e.push(t.lng||this.language);const r=(e,n,r)=>{const o=f&&r!==d?r:m;this.options.missingKeyHandler?this.options.missingKeyHandler(e,s,n,o,y,t):this.backendConnector&&this.backendConnector.saveMissing&&this.backendConnector.saveMissing(e,s,n,o,y,t),this.emit("missingKey",e,s,n,d)};this.options.saveMissing&&(this.options.saveMissingPlurals&&l?e.forEach(e=>{const n=this.pluralResolver.getSuffixes(e,t);g&&t[`defaultValue${this.options.pluralSeparator}zero`]&&n.indexOf(`${this.options.pluralSeparator}zero`)<0&&n.push(`${this.options.pluralSeparator}zero`),n.forEach(n=>{r([e],i+n,t[`defaultValue${n}`]||v)})}):r(e,i,v))}d=this.extendTranslation(d,e,t,c,n),a&&d===i&&this.options.appendNamespaceToMissingKey&&(d=`${s}:${i}`),(a||r)&&this.options.parseMissingKeyHandler&&(d="v1"!==this.options.compatibilityAPI?this.options.parseMissingKeyHandler(this.options.appendNamespaceToMissingKey?`${s}:${i}`:i,r?d:void 0):this.options.parseMissingKeyHandler(d))}else{if(!t.returnObjects&&!this.options.returnObjects){this.options.returnedObjectHandler||this.logger.warn("accessing an object - but returnObjects options is not enabled!");const e=this.options.returnedObjectHandler?this.options.returnedObjectHandler(f,d,{...t,ns:a}):`key '${i} (${this.language})' returned an object instead of string.`;return r?(c.res=e,c.usedParams=this.getUsedParamsDetails(t),c):e}if(o){const e=Array.isArray(d),n=e?[]:{},r=e?p:f;for(const e in d)if(Object.prototype.hasOwnProperty.call(d,e)){const i=`${r}${o}${e}`;n[e]=this.translate(i,{...t,joinArrays:!1,ns:a}),n[e]===i&&(n[e]=d[e])}d=n}}return r?(c.res=d,c.usedParams=this.getUsedParamsDetails(t),c):d}extendTranslation(e,t,n,r,o){var i=this;if(this.i18nFormat&&this.i18nFormat.parse)e=this.i18nFormat.parse(e,{...this.options.interpolation.defaultVariables,...n},n.lng||this.language||r.usedLng,r.usedNS,r.usedKey,{resolved:r});else if(!n.skipInterpolation){n.interpolation&&this.interpolator.init({...n,interpolation:{...this.options.interpolation,...n.interpolation}});const a=rE(e)&&(n&&n.interpolation&&void 0!==n.interpolation.skipOnVariables?n.interpolation.skipOnVariables:this.options.interpolation.skipOnVariables);let s;if(a){const t=e.match(this.interpolator.nestingRegexp);s=t&&t.length}let u=n.replace&&!rE(n.replace)?n.replace:n;if(this.options.interpolation.defaultVariables&&(u={...this.options.interpolation.defaultVariables,...u}),e=this.interpolator.interpolate(e,u,n.lng||this.language||r.usedLng,n),a){const t=e.match(this.interpolator.nestingRegexp);s<(t&&t.length)&&(n.nest=!1)}!n.lng&&"v1"!==this.options.compatibilityAPI&&r&&r.res&&(n.lng=this.language||r.usedLng),!1!==n.nest&&(e=this.interpolator.nest(e,function(){for(var e=arguments.length,r=new Array(e),a=0;a<e;a++)r[a]=arguments[a];return o&&o[0]===r[0]&&!n.context?(i.logger.warn(`It seems you are nesting recursively key: ${r[0]} in key: ${t[0]}`),null):i.translate(...r,t)},n)),n.interpolation&&this.interpolator.reset()}const a=n.postProcess||this.options.postProcess,s=rE(a)?[a]:a;return null!=e&&s&&s.length&&!1!==n.applyPostProcessor&&(e=AE.handle(s,e,t,this.options&&this.options.postProcessPassResolved?{i18nResolved:{...r,usedParams:this.getUsedParamsDetails(n)},...n}:n,this)),e}resolve(e){let t,n,r,o,i,a=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return rE(e)&&(e=[e]),e.forEach(e=>{if(this.isValidLookup(t))return;const s=this.extractFromKey(e,a),u=s.key;n=u;let l=s.namespaces;this.options.fallbackNS&&(l=l.concat(this.options.fallbackNS));const c=void 0!==a.count&&!rE(a.count),d=c&&!a.ordinal&&0===a.count&&this.pluralResolver.shouldUseIntlApi(),f=void 0!==a.context&&(rE(a.context)||"number"==typeof a.context)&&""!==a.context,p=a.lngs?a.lngs:this.languageUtils.toResolveHierarchy(a.lng||this.language,a.fallbackLng);l.forEach(e=>{this.isValidLookup(t)||(i=e,!xE[`${p[0]}-${e}`]&&this.utils&&this.utils.hasLoadedNamespace&&!this.utils.hasLoadedNamespace(i)&&(xE[`${p[0]}-${e}`]=!0,this.logger.warn(`key "${n}" for languages "${p.join(", ")}" won't get resolved as namespace "${i}" was not yet loaded`,"This means something IS WRONG in your setup. You access the t function before i18next.init / i18next.loadNamespace / i18next.changeLanguage was done. Wait for the callback or Promise to resolve before accessing it!!!")),p.forEach(n=>{if(this.isValidLookup(t))return;o=n;const i=[u];if(this.i18nFormat&&this.i18nFormat.addLookupKeys)this.i18nFormat.addLookupKeys(i,u,n,e,a);else{let e;c&&(e=this.pluralResolver.getSuffix(n,a.count,a));const t=`${this.options.pluralSeparator}zero`,r=`${this.options.pluralSeparator}ordinal${this.options.pluralSeparator}`;if(c&&(i.push(u+e),a.ordinal&&0===e.indexOf(r)&&i.push(u+e.replace(r,this.options.pluralSeparator)),d&&i.push(u+t)),f){const n=`${u}${this.options.contextSeparator}${a.context}`;i.push(n),c&&(i.push(n+e),a.ordinal&&0===e.indexOf(r)&&i.push(n+e.replace(r,this.options.pluralSeparator)),d&&i.push(n+t))}}let s;for(;s=i.pop();)this.isValidLookup(t)||(r=s,t=this.getResource(n,e,s,a))}))})}),{res:t,usedKey:n,exactUsedKey:r,usedLng:o,usedNS:i}}isValidLookup(e){return!(void 0===e||!this.options.returnNull&&null===e||!this.options.returnEmptyString&&""===e)}getResource(e,t,n){let r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{};return this.i18nFormat&&this.i18nFormat.getResource?this.i18nFormat.getResource(e,t,n,r):this.resourceStore.getResource(e,t,n,r)}getUsedParamsDetails(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};const t=["defaultValue","ordinal","context","replace","lng","lngs","fallbackLng","ns","keySeparator","nsSeparator","returnObjects","returnDetails","joinArrays","postProcess","interpolation"],n=e.replace&&!rE(e.replace);let r=n?e.replace:e;if(n&&void 0!==e.count&&(r.count=e.count),this.options.interpolation.defaultVariables&&(r={...this.options.interpolation.defaultVariables,...r}),!n){r={...r};for(const e of t)delete r[e]}return r}static hasDefaultValue(e){const t="defaultValue";for(const n in e)if(Object.prototype.hasOwnProperty.call(e,n)&&t===n.substring(0,12)&&void 0!==e[n])return!0;return!1}}const NE=e=>e.charAt(0).toUpperCase()+e.slice(1);class BE{constructor(e){this.options=e,this.supportedLngs=this.options.supportedLngs||!1,this.logger=DE.create("languageUtils")}getScriptPartFromCode(e){if(!(e=bE(e))||e.indexOf("-")<0)return null;const t=e.split("-");return 2===t.length?null:(t.pop(),"x"===t[t.length-1].toLowerCase()?null:this.formatLanguageCode(t.join("-")))}getLanguagePartFromCode(e){if(!(e=bE(e))||e.indexOf("-")<0)return e;const t=e.split("-");return this.formatLanguageCode(t[0])}formatLanguageCode(e){if(rE(e)&&e.indexOf("-")>-1){if("undefined"!=typeof Intl&&void 0!==Intl.getCanonicalLocales)try{let t=Intl.getCanonicalLocales(e)[0];if(t&&this.options.lowerCaseLng&&(t=t.toLowerCase()),t)return t}catch(e){}const t=["hans","hant","latn","cyrl","cans","mong","arab"];let n=e.split("-");return this.options.lowerCaseLng?n=n.map(e=>e.toLowerCase()):2===n.length?(n[0]=n[0].toLowerCase(),n[1]=n[1].toUpperCase(),t.indexOf(n[1].toLowerCase())>-1&&(n[1]=NE(n[1].toLowerCase()))):3===n.length&&(n[0]=n[0].toLowerCase(),2===n[1].length&&(n[1]=n[1].toUpperCase()),"sgn"!==n[0]&&2===n[2].length&&(n[2]=n[2].toUpperCase()),t.indexOf(n[1].toLowerCase())>-1&&(n[1]=NE(n[1].toLowerCase())),t.indexOf(n[2].toLowerCase())>-1&&(n[2]=NE(n[2].toLowerCase()))),n.join("-")}return this.options.cleanCode||this.options.lowerCaseLng?e.toLowerCase():e}isSupportedCode(e){return("languageOnly"===this.options.load||this.options.nonExplicitSupportedLngs)&&(e=this.getLanguagePartFromCode(e)),!this.supportedLngs||!this.supportedLngs.length||this.supportedLngs.indexOf(e)>-1}getBestMatchFromCodes(e){if(!e)return null;let t;return e.forEach(e=>{if(t)return;const n=this.formatLanguageCode(e);this.options.supportedLngs&&!this.isSupportedCode(n)||(t=n)}),!t&&this.options.supportedLngs&&e.forEach(e=>{if(t)return;const n=this.getLanguagePartFromCode(e);if(this.isSupportedCode(n))return t=n;t=this.options.supportedLngs.find(e=>e===n?e:e.indexOf("-")<0&&n.indexOf("-")<0?void 0:e.indexOf("-")>0&&n.indexOf("-")<0&&e.substring(0,e.indexOf("-"))===n||0===e.indexOf(n)&&n.length>1?e:void 0)}),t||(t=this.getFallbackCodes(this.options.fallbackLng)[0]),t}getFallbackCodes(e,t){if(!e)return[];if("function"==typeof e&&(e=e(t)),rE(e)&&(e=[e]),Array.isArray(e))return e;if(!t)return e.default||[];let n=e[t];return n||(n=e[this.getScriptPartFromCode(t)]),n||(n=e[this.formatLanguageCode(t)]),n||(n=e[this.getLanguagePartFromCode(t)]),n||(n=e.default),n||[]}toResolveHierarchy(e,t){const n=this.getFallbackCodes(t||this.options.fallbackLng||[],e),r=[],o=e=>{e&&(this.isSupportedCode(e)?r.push(e):this.logger.warn(`rejecting language code not found in supportedLngs: ${e}`))};return rE(e)&&(e.indexOf("-")>-1||e.indexOf("_")>-1)?("languageOnly"!==this.options.load&&o(this.formatLanguageCode(e)),"languageOnly"!==this.options.load&&"currentOnly"!==this.options.load&&o(this.getScriptPartFromCode(e)),"currentOnly"!==this.options.load&&o(this.getLanguagePartFromCode(e))):rE(e)&&o(this.formatLanguageCode(e)),n.forEach(e=>{r.indexOf(e)<0&&o(this.formatLanguageCode(e))}),r}}let TE=[{lngs:["ach","ak","am","arn","br","fil","gun","ln","mfe","mg","mi","oc","pt","pt-BR","tg","tl","ti","tr","uz","wa"],nr:[1,2],fc:1},{lngs:["af","an","ast","az","bg","bn","ca","da","de","dev","el","en","eo","es","et","eu","fi","fo","fur","fy","gl","gu","ha","hi","hu","hy","ia","it","kk","kn","ku","lb","mai","ml","mn","mr","nah","nap","nb","ne","nl","nn","no","nso","pa","pap","pms","ps","pt-PT","rm","sco","se","si","so","son","sq","sv","sw","ta","te","tk","ur","yo"],nr:[1,2],fc:2},{lngs:["ay","bo","cgg","fa","ht","id","ja","jbo","ka","km","ko","ky","lo","ms","sah","su","th","tt","ug","vi","wo","zh"],nr:[1],fc:3},{lngs:["be","bs","cnr","dz","hr","ru","sr","uk"],nr:[1,2,5],fc:4},{lngs:["ar"],nr:[0,1,2,3,11,100],fc:5},{lngs:["cs","sk"],nr:[1,2,5],fc:6},{lngs:["csb","pl"],nr:[1,2,5],fc:7},{lngs:["cy"],nr:[1,2,3,8],fc:8},{lngs:["fr"],nr:[1,2],fc:9},{lngs:["ga"],nr:[1,2,3,7,11],fc:10},{lngs:["gd"],nr:[1,2,3,20],fc:11},{lngs:["is"],nr:[1,2],fc:12},{lngs:["jv"],nr:[0,1],fc:13},{lngs:["kw"],nr:[1,2,3,4],fc:14},{lngs:["lt"],nr:[1,2,10],fc:15},{lngs:["lv"],nr:[1,2,0],fc:16},{lngs:["mk"],nr:[1,2],fc:17},{lngs:["mnk"],nr:[0,1,2],fc:18},{lngs:["mt"],nr:[1,2,11,20],fc:19},{lngs:["or"],nr:[2,1],fc:2},{lngs:["ro"],nr:[1,2,20],fc:20},{lngs:["sl"],nr:[5,1,2,3],fc:21},{lngs:["he","iw"],nr:[1,2,20,21],fc:22}],kE={1:e=>Number(e>1),2:e=>Number(1!=e),3:e=>0,4:e=>Number(e%10==1&&e%100!=11?0:e%10>=2&&e%10<=4&&(e%100<10||e%100>=20)?1:2),5:e=>Number(0==e?0:1==e?1:2==e?2:e%100>=3&&e%100<=10?3:e%100>=11?4:5),6:e=>Number(1==e?0:e>=2&&e<=4?1:2),7:e=>Number(1==e?0:e%10>=2&&e%10<=4&&(e%100<10||e%100>=20)?1:2),8:e=>Number(1==e?0:2==e?1:8!=e&&11!=e?2:3),9:e=>Number(e>=2),10:e=>Number(1==e?0:2==e?1:e<7?2:e<11?3:4),11:e=>Number(1==e||11==e?0:2==e||12==e?1:e>2&&e<20?2:3),12:e=>Number(e%10!=1||e%100==11),13:e=>Number(0!==e),14:e=>Number(1==e?0:2==e?1:3==e?2:3),15:e=>Number(e%10==1&&e%100!=11?0:e%10>=2&&(e%100<10||e%100>=20)?1:2),16:e=>Number(e%10==1&&e%100!=11?0:0!==e?1:2),17:e=>Number(1==e||e%10==1&&e%100!=11?0:1),18:e=>Number(0==e?0:1==e?1:2),19:e=>Number(1==e?0:0==e||e%100>1&&e%100<11?1:e%100>10&&e%100<20?2:3),20:e=>Number(1==e?0:0==e||e%100>0&&e%100<20?1:2),21:e=>Number(e%100==1?1:e%100==2?2:e%100==3||e%100==4?3:0),22:e=>Number(1==e?0:2==e?1:(e<0||e>10)&&e%10==0?2:3)};const FE=["v1","v2","v3"],IE=["v4"],PE={zero:0,one:1,two:2,few:3,many:4,other:5};class _E{constructor(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};this.languageUtils=e,this.options=t,this.logger=DE.create("pluralResolver"),this.options.compatibilityJSON&&!IE.includes(this.options.compatibilityJSON)||"undefined"!=typeof Intl&&Intl.PluralRules||(this.options.compatibilityJSON="v3",this.logger.error("Your environment seems not to be Intl API compatible, use an Intl.PluralRules polyfill. Will fallback to the compatibilityJSON v3 format handling.")),this.rules=(()=>{const e={};return TE.forEach(t=>{t.lngs.forEach(n=>{e[n]={numbers:t.nr,plurals:kE[t.fc]}})}),e})(),this.pluralRulesCache={}}addRule(e,t){this.rules[e]=t}clearCache(){this.pluralRulesCache={}}getRule(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if(this.shouldUseIntlApi()){const n=bE("dev"===e?"en":e),r=t.ordinal?"ordinal":"cardinal",o=JSON.stringify({cleanedCode:n,type:r});if(o in this.pluralRulesCache)return this.pluralRulesCache[o];let i;try{i=new Intl.PluralRules(n,{type:r})}catch(n){if(!e.match(/-|_/))return;const r=this.languageUtils.getLanguagePartFromCode(e);i=this.getRule(r,t)}return this.pluralRulesCache[o]=i,i}return this.rules[e]||this.rules[this.languageUtils.getLanguagePartFromCode(e)]}needsPlural(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};const n=this.getRule(e,t);return this.shouldUseIntlApi()?n&&n.resolvedOptions().pluralCategories.length>1:n&&n.numbers.length>1}getPluralFormsOfKey(e,t){let n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return this.getSuffixes(e,n).map(e=>`${t}${e}`)}getSuffixes(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};const n=this.getRule(e,t);return n?this.shouldUseIntlApi()?n.resolvedOptions().pluralCategories.sort((e,t)=>PE[e]-PE[t]).map(e=>`${this.options.prepend}${t.ordinal?`ordinal${this.options.prepend}`:""}${e}`):n.numbers.map(n=>this.getSuffix(e,n,t)):[]}getSuffix(e,t){let n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};const r=this.getRule(e,n);return r?this.shouldUseIntlApi()?`${this.options.prepend}${n.ordinal?`ordinal${this.options.prepend}`:""}${r.select(t)}`:this.getSuffixRetroCompatible(r,t):(this.logger.warn(`no plural rule found for: ${e}`),"")}getSuffixRetroCompatible(e,t){const n=e.noAbs?e.plurals(t):e.plurals(Math.abs(t));let r=e.numbers[n];this.options.simplifyPluralSuffix&&2===e.numbers.length&&1===e.numbers[0]&&(2===r?r="plural":1===r&&(r=""));const o=()=>this.options.prepend&&r.toString()?this.options.prepend+r.toString():r.toString();return"v1"===this.options.compatibilityJSON?1===r?"":"number"==typeof r?`_plural_${r.toString()}`:o():"v2"===this.options.compatibilityJSON||this.options.simplifyPluralSuffix&&2===e.numbers.length&&1===e.numbers[0]?o():this.options.prepend&&n.toString()?this.options.prepend+n.toString():n.toString()}shouldUseIntlApi(){return!FE.includes(this.options.compatibilityJSON)}}const LE=function(e,t,n){let r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:".",o=!(arguments.length>4&&void 0!==arguments[4])||arguments[4],i=((e,t,n)=>{const r=dE(e,n);return void 0!==r?r:dE(t,n)})(e,t,n);return!i&&o&&rE(n)&&(i=yE(e,n,r),void 0===i&&(i=yE(t,n,r))),i},RE=e=>e.replace(/\$/g,"$$$$");class ME{constructor(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};this.logger=DE.create("interpolator"),this.options=e,this.format=e.interpolation&&e.interpolation.format||(e=>e),this.init(e)}init(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};e.interpolation||(e.interpolation={escapeValue:!0});const{escape:t,escapeValue:n,useRawValueToEscape:r,prefix:o,prefixEscaped:i,suffix:a,suffixEscaped:s,formatSeparator:u,unescapeSuffix:l,unescapePrefix:c,nestingPrefix:d,nestingPrefixEscaped:f,nestingSuffix:p,nestingSuffixEscaped:h,nestingOptionsSeparator:g,maxReplaces:v,alwaysFormat:m}=e.interpolation;this.escape=void 0!==t?t:gE,this.escapeValue=void 0===n||n,this.useRawValueToEscape=void 0!==r&&r,this.prefix=o?pE(o):i||"{{",this.suffix=a?pE(a):s||"}}",this.formatSeparator=u||",",this.unescapePrefix=l?"":c||"-",this.unescapeSuffix=this.unescapePrefix?"":l||"",this.nestingPrefix=d?pE(d):f||pE("$t("),this.nestingSuffix=p?pE(p):h||pE(")"),this.nestingOptionsSeparator=g||",",this.maxReplaces=v||1e3,this.alwaysFormat=void 0!==m&&m,this.resetRegExp()}reset(){this.options&&this.init(this.options)}resetRegExp(){const e=(e,t)=>e&&e.source===t?(e.lastIndex=0,e):new RegExp(t,"g");this.regexp=e(this.regexp,`${this.prefix}(.+?)${this.suffix}`),this.regexpUnescape=e(this.regexpUnescape,`${this.prefix}${this.unescapePrefix}(.+?)${this.unescapeSuffix}${this.suffix}`),this.nestingRegexp=e(this.nestingRegexp,`${this.nestingPrefix}(.+?)${this.nestingSuffix}`)}interpolate(e,t,n,r){let o,i,a;const s=this.options&&this.options.interpolation&&this.options.interpolation.defaultVariables||{},u=e=>{if(e.indexOf(this.formatSeparator)<0){const o=LE(t,s,e,this.options.keySeparator,this.options.ignoreJSONStructure);return this.alwaysFormat?this.format(o,void 0,n,{...r,...t,interpolationkey:e}):o}const o=e.split(this.formatSeparator),i=o.shift().trim(),a=o.join(this.formatSeparator).trim();return this.format(LE(t,s,i,this.options.keySeparator,this.options.ignoreJSONStructure),a,n,{...r,...t,interpolationkey:i})};this.resetRegExp();const l=r&&r.missingInterpolationHandler||this.options.missingInterpolationHandler,c=r&&r.interpolation&&void 0!==r.interpolation.skipOnVariables?r.interpolation.skipOnVariables:this.options.interpolation.skipOnVariables,d=[{regex:this.regexpUnescape,safeValue:e=>RE(e)},{regex:this.regexp,safeValue:e=>this.escapeValue?RE(this.escape(e)):RE(e)}];return d.forEach(t=>{for(a=0;o=t.regex.exec(e);){const n=o[1].trim();if(i=u(n),void 0===i)if("function"==typeof l){const t=l(e,o,r);i=rE(t)?t:""}else if(r&&Object.prototype.hasOwnProperty.call(r,n))i="";else{if(c){i=o[0];continue}this.logger.warn(`missed to pass in variable ${n} for interpolating ${e}`),i=""}else rE(i)||this.useRawValueToEscape||(i=iE(i));const s=t.safeValue(i);if(e=e.replace(o[0],s),c?(t.regex.lastIndex+=i.length,t.regex.lastIndex-=o[0].length):t.regex.lastIndex=0,a++,a>=this.maxReplaces)break}}),e}nest(e,t){let n,r,o,i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};const a=(e,t)=>{const n=this.nestingOptionsSeparator;if(e.indexOf(n)<0)return e;const r=e.split(new RegExp(`${n}[ ]*{`));let i=`{${r[1]}`;e=r[0],i=this.interpolate(i,o);const a=i.match(/'/g),s=i.match(/"/g);(a&&a.length%2==0&&!s||s.length%2!=0)&&(i=i.replace(/'/g,'"'));try{o=JSON.parse(i),t&&(o={...t,...o})}catch(t){return this.logger.warn(`failed parsing options string in nesting for key ${e}`,t),`${e}${n}${i}`}return o.defaultValue&&o.defaultValue.indexOf(this.prefix)>-1&&delete o.defaultValue,e};for(;n=this.nestingRegexp.exec(e);){let s=[];o={...i},o=o.replace&&!rE(o.replace)?o.replace:o,o.applyPostProcessor=!1,delete o.defaultValue;let u=!1;if(-1!==n[0].indexOf(this.formatSeparator)&&!/{.*}/.test(n[1])){const e=n[1].split(this.formatSeparator).map(e=>e.trim());n[1]=e.shift(),s=e,u=!0}if(r=t(a.call(this,n[1].trim(),o),o),r&&n[0]===e&&!rE(r))return r;rE(r)||(r=iE(r)),r||(this.logger.warn(`missed to resolve ${n[1]} for nesting ${e}`),r=""),u&&(r=s.reduce((e,t)=>this.format(e,t,i.lng,{...i,interpolationkey:n[1].trim()}),r.trim())),e=e.replace(n[0],r),this.regexp.lastIndex=0}return e}}const jE=e=>{const t={};return(n,r,o)=>{let i=o;o&&o.interpolationkey&&o.formatParams&&o.formatParams[o.interpolationkey]&&o[o.interpolationkey]&&(i={...i,[o.interpolationkey]:void 0});const a=r+JSON.stringify(i);let s=t[a];return s||(s=e(bE(r),o),t[a]=s),s(n)}};class HE{constructor(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};this.logger=DE.create("formatter"),this.options=e,this.formats={number:jE((e,t)=>{const n=new Intl.NumberFormat(e,{...t});return e=>n.format(e)}),currency:jE((e,t)=>{const n=new Intl.NumberFormat(e,{...t,style:"currency"});return e=>n.format(e)}),datetime:jE((e,t)=>{const n=new Intl.DateTimeFormat(e,{...t});return e=>n.format(e)}),relativetime:jE((e,t)=>{const n=new Intl.RelativeTimeFormat(e,{...t});return e=>n.format(e,t.range||"day")}),list:jE((e,t)=>{const n=new Intl.ListFormat(e,{...t});return e=>n.format(e)})},this.init(e)}init(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{interpolation:{}};this.formatSeparator=t.interpolation.formatSeparator||","}add(e,t){this.formats[e.toLowerCase().trim()]=t}addCached(e,t){this.formats[e.toLowerCase().trim()]=jE(t)}format(e,t,n){let r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{};const o=t.split(this.formatSeparator);if(o.length>1&&o[0].indexOf("(")>1&&o[0].indexOf(")")<0&&o.find(e=>e.indexOf(")")>-1)){const e=o.findIndex(e=>e.indexOf(")")>-1);o[0]=[o[0],...o.splice(1,e)].join(this.formatSeparator)}const i=o.reduce((e,t)=>{const{formatName:o,formatOptions:i}=(e=>{let t=e.toLowerCase().trim();const n={};if(e.indexOf("(")>-1){const r=e.split("(");t=r[0].toLowerCase().trim();const o=r[1].substring(0,r[1].length-1);"currency"===t&&o.indexOf(":")<0?n.currency||(n.currency=o.trim()):"relativetime"===t&&o.indexOf(":")<0?n.range||(n.range=o.trim()):o.split(";").forEach(e=>{if(e){const[t,...r]=e.split(":"),o=r.join(":").trim().replace(/^'+|'+$/g,""),i=t.trim();n[i]||(n[i]=o),"false"===o&&(n[i]=!1),"true"===o&&(n[i]=!0),isNaN(o)||(n[i]=parseInt(o,10))}})}return{formatName:t,formatOptions:n}})(t);if(this.formats[o]){let t=e;try{const a=r&&r.formatParams&&r.formatParams[r.interpolationkey]||{},s=a.locale||a.lng||r.locale||r.lng||n;t=this.formats[o](e,s,{...i,...r,...a})}catch(e){this.logger.warn(e)}return t}return this.logger.warn(`there was no format function for ${o}`),e},e);return i}}class zE extends wE{constructor(e,t,n){let r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{};super(),this.backend=e,this.store=t,this.services=n,this.languageUtils=n.languageUtils,this.options=r,this.logger=DE.create("backendConnector"),this.waitingReads=[],this.maxParallelReads=r.maxParallelReads||10,this.readingCalls=0,this.maxRetries=r.maxRetries>=0?r.maxRetries:5,this.retryTimeout=r.retryTimeout>=1?r.retryTimeout:350,this.state={},this.queue=[],this.backend&&this.backend.init&&this.backend.init(n,r.backend,r)}queueLoad(e,t,n,r){const o={},i={},a={},s={};return e.forEach(e=>{let r=!0;t.forEach(t=>{const a=`${e}|${t}`;!n.reload&&this.store.hasResourceBundle(e,t)?this.state[a]=2:this.state[a]<0||(1===this.state[a]?void 0===i[a]&&(i[a]=!0):(this.state[a]=1,r=!1,void 0===i[a]&&(i[a]=!0),void 0===o[a]&&(o[a]=!0),void 0===s[t]&&(s[t]=!0)))}),r||(a[e]=!0)}),(Object.keys(o).length||Object.keys(i).length)&&this.queue.push({pending:i,pendingCount:Object.keys(i).length,loaded:{},errors:[],callback:r}),{toLoad:Object.keys(o),pending:Object.keys(i),toLoadLanguages:Object.keys(a),toLoadNamespaces:Object.keys(s)}}loaded(e,t,n){const r=e.split("|"),o=r[0],i=r[1];t&&this.emit("failedLoading",o,i,t),!t&&n&&this.store.addResourceBundle(o,i,n,void 0,void 0,{skipCopy:!0}),this.state[e]=t?-1:2,t&&n&&(this.state[e]=0);const a={};this.queue.forEach(n=>{((e,t,n)=>{const{obj:r,k:o}=lE(e,t,Object);r[o]=r[o]||[],r[o].push(n)})(n.loaded,[o],i),((e,t)=>{void 0!==e.pending[t]&&(delete e.pending[t],e.pendingCount--)})(n,e),t&&n.errors.push(t),0!==n.pendingCount||n.done||(Object.keys(n.loaded).forEach(e=>{a[e]||(a[e]={});const t=n.loaded[e];t.length&&t.forEach(t=>{void 0===a[e][t]&&(a[e][t]=!0)})}),n.done=!0,n.errors.length?n.callback(n.errors):n.callback())}),this.emit("loaded",a),this.queue=this.queue.filter(e=>!e.done)}read(e,t,n){let r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:0,o=arguments.length>4&&void 0!==arguments[4]?arguments[4]:this.retryTimeout,i=arguments.length>5?arguments[5]:void 0;if(!e.length)return i(null,{});if(this.readingCalls>=this.maxParallelReads)return void this.waitingReads.push({lng:e,ns:t,fcName:n,tried:r,wait:o,callback:i});this.readingCalls++;const a=(a,s)=>{if(this.readingCalls--,this.waitingReads.length>0){const e=this.waitingReads.shift();this.read(e.lng,e.ns,e.fcName,e.tried,e.wait,e.callback)}a&&s&&r<this.maxRetries?setTimeout(()=>{this.read.call(this,e,t,n,r+1,2*o,i)},o):i(a,s)},s=this.backend[n].bind(this.backend);if(2!==s.length)return s(e,t,a);try{const n=s(e,t);n&&"function"==typeof n.then?n.then(e=>a(null,e)).catch(a):a(null,n)}catch(e){a(e)}}prepareLoading(e,t){let n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},r=arguments.length>3?arguments[3]:void 0;if(!this.backend)return this.logger.warn("No backend was added via i18next.use. Will not load resources."),r&&r();rE(e)&&(e=this.languageUtils.toResolveHierarchy(e)),rE(t)&&(t=[t]);const o=this.queueLoad(e,t,n,r);if(!o.toLoad.length)return o.pending.length||r(),null;o.toLoad.forEach(e=>{this.loadOne(e)})}load(e,t,n){this.prepareLoading(e,t,{},n)}reload(e,t,n){this.prepareLoading(e,t,{reload:!0},n)}loadOne(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";const n=e.split("|"),r=n[0],o=n[1];this.read(r,o,"read",void 0,void 0,(n,i)=>{n&&this.logger.warn(`${t}loading namespace ${o} for language ${r} failed`,n),!n&&i&&this.logger.log(`${t}loaded namespace ${o} for language ${r}`,i),this.loaded(e,n,i)})}saveMissing(e,t,n,r,o){let i=arguments.length>5&&void 0!==arguments[5]?arguments[5]:{},a=arguments.length>6&&void 0!==arguments[6]?arguments[6]:()=>{};if(this.services.utils&&this.services.utils.hasLoadedNamespace&&!this.services.utils.hasLoadedNamespace(t))this.logger.warn(`did not save key "${n}" as the namespace "${t}" was not yet loaded`,"This means something IS WRONG in your setup. You access the t function before i18next.init / i18next.loadNamespace / i18next.changeLanguage was done. Wait for the callback or Promise to resolve before accessing it!!!");else if(null!=n&&""!==n){if(this.backend&&this.backend.create){const s={...i,isUpdate:o},u=this.backend.create.bind(this.backend);if(u.length<6)try{let o;o=5===u.length?u(e,t,n,r,s):u(e,t,n,r),o&&"function"==typeof o.then?o.then(e=>a(null,e)).catch(a):a(null,o)}catch(e){a(e)}else u(e,t,n,r,a,s)}e&&e[0]&&this.store.addResource(e[0],t,n,r)}}}const $E=()=>({debug:!1,initImmediate:!0,ns:["translation"],defaultNS:["translation"],fallbackLng:["dev"],fallbackNS:!1,supportedLngs:!1,nonExplicitSupportedLngs:!1,load:"all",preload:!1,simplifyPluralSuffix:!0,keySeparator:".",nsSeparator:":",pluralSeparator:"_",contextSeparator:"_",partialBundledLanguages:!1,saveMissing:!1,updateMissing:!1,saveMissingTo:"fallback",saveMissingPlurals:!0,missingKeyHandler:!1,missingInterpolationHandler:!1,postProcess:!1,postProcessPassResolved:!1,returnNull:!1,returnEmptyString:!0,returnObjects:!1,joinArrays:!1,returnedObjectHandler:!1,parseMissingKeyHandler:!1,appendNamespaceToMissingKey:!1,appendNamespaceToCIMode:!1,overloadTranslationOptionHandler:e=>{let t={};if("object"==typeof e[1]&&(t=e[1]),rE(e[1])&&(t.defaultValue=e[1]),rE(e[2])&&(t.tDescription=e[2]),"object"==typeof e[2]||"object"==typeof e[3]){const n=e[3]||e[2];Object.keys(n).forEach(e=>{t[e]=n[e]})}return t},interpolation:{escapeValue:!0,format:e=>e,prefix:"{{",suffix:"}}",formatSeparator:",",unescapePrefix:"-",nestingPrefix:"$t(",nestingSuffix:")",nestingOptionsSeparator:",",maxReplaces:1e3,skipOnVariables:!0}}),UE=e=>(rE(e.ns)&&(e.ns=[e.ns]),rE(e.fallbackLng)&&(e.fallbackLng=[e.fallbackLng]),rE(e.fallbackNS)&&(e.fallbackNS=[e.fallbackNS]),e.supportedLngs&&e.supportedLngs.indexOf("cimode")<0&&(e.supportedLngs=e.supportedLngs.concat(["cimode"])),e),VE=()=>{};class WE extends wE{constructor(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1?arguments[1]:void 0;var n;if(super(),this.options=UE(e),this.services={},this.logger=DE,this.modules={external:[]},n=this,Object.getOwnPropertyNames(Object.getPrototypeOf(n)).forEach(e=>{"function"==typeof n[e]&&(n[e]=n[e].bind(n))}),t&&!this.isInitialized&&!e.isClone){if(!this.options.initImmediate)return this.init(e,t),this;setTimeout(()=>{this.init(e,t)},0)}}init(){var e=this;let t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=arguments.length>1?arguments[1]:void 0;this.isInitializing=!0,"function"==typeof t&&(n=t,t={}),!t.defaultNS&&!1!==t.defaultNS&&t.ns&&(rE(t.ns)?t.defaultNS=t.ns:t.ns.indexOf("translation")<0&&(t.defaultNS=t.ns[0]));const r=$E();this.options={...r,...this.options,...UE(t)},"v1"!==this.options.compatibilityAPI&&(this.options.interpolation={...r.interpolation,...this.options.interpolation}),void 0!==t.keySeparator&&(this.options.userDefinedKeySeparator=t.keySeparator),void 0!==t.nsSeparator&&(this.options.userDefinedNsSeparator=t.nsSeparator);const o=e=>e?"function"==typeof e?new e:e:null;if(!this.options.isClone){let t;this.modules.logger?DE.init(o(this.modules.logger),this.options):DE.init(null,this.options),this.modules.formatter?t=this.modules.formatter:"undefined"!=typeof Intl&&(t=HE);const n=new BE(this.options);this.store=new SE(this.options.resources,this.options);const i=this.services;i.logger=DE,i.resourceStore=this.store,i.languageUtils=n,i.pluralResolver=new _E(n,{prepend:this.options.pluralSeparator,compatibilityJSON:this.options.compatibilityJSON,simplifyPluralSuffix:this.options.simplifyPluralSuffix}),!t||this.options.interpolation.format&&this.options.interpolation.format!==r.interpolation.format||(i.formatter=o(t),i.formatter.init(i,this.options),this.options.interpolation.format=i.formatter.format.bind(i.formatter)),i.interpolator=new ME(this.options),i.utils={hasLoadedNamespace:this.hasLoadedNamespace.bind(this)},i.backendConnector=new zE(o(this.modules.backend),i.resourceStore,i,this.options),i.backendConnector.on("*",function(t){for(var n=arguments.length,r=new Array(n>1?n-1:0),o=1;o<n;o++)r[o-1]=arguments[o];e.emit(t,...r)}),this.modules.languageDetector&&(i.languageDetector=o(this.modules.languageDetector),i.languageDetector.init&&i.languageDetector.init(i,this.options.detection,this.options)),this.modules.i18nFormat&&(i.i18nFormat=o(this.modules.i18nFormat),i.i18nFormat.init&&i.i18nFormat.init(this)),this.translator=new OE(this.services,this.options),this.translator.on("*",function(t){for(var n=arguments.length,r=new Array(n>1?n-1:0),o=1;o<n;o++)r[o-1]=arguments[o];e.emit(t,...r)}),this.modules.external.forEach(e=>{e.init&&e.init(this)})}if(this.format=this.options.interpolation.format,n||(n=VE),this.options.fallbackLng&&!this.services.languageDetector&&!this.options.lng){const e=this.services.languageUtils.getFallbackCodes(this.options.fallbackLng);e.length>0&&"dev"!==e[0]&&(this.options.lng=e[0])}this.services.languageDetector||this.options.lng||this.logger.warn("init: no languageDetector is used and no lng is defined");["getResource","hasResourceBundle","getResourceBundle","getDataByLanguage"].forEach(t=>{this[t]=function(){return e.store[t](...arguments)}});["addResource","addResources","addResourceBundle","removeResourceBundle"].forEach(t=>{this[t]=function(){return e.store[t](...arguments),e}});const i=oE(),a=()=>{const e=(e,t)=>{this.isInitializing=!1,this.isInitialized&&!this.initializedStoreOnce&&this.logger.warn("init: i18next is already initialized. You should call init just once!"),this.isInitialized=!0,this.options.isClone||this.logger.log("initialized",this.options),this.emit("initialized",this.options),i.resolve(t),n(e,t)};if(this.languages&&"v1"!==this.options.compatibilityAPI&&!this.isInitialized)return e(null,this.t.bind(this));this.changeLanguage(this.options.lng,e)};return this.options.resources||!this.options.initImmediate?a():setTimeout(a,0),i}loadResources(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:VE;const n=rE(e)?e:this.language;if("function"==typeof e&&(t=e),!this.options.resources||this.options.partialBundledLanguages){if(n&&"cimode"===n.toLowerCase()&&(!this.options.preload||0===this.options.preload.length))return t();const e=[],r=t=>{if(!t)return;if("cimode"===t)return;this.services.languageUtils.toResolveHierarchy(t).forEach(t=>{"cimode"!==t&&e.indexOf(t)<0&&e.push(t)})};if(n)r(n);else{this.services.languageUtils.getFallbackCodes(this.options.fallbackLng).forEach(e=>r(e))}this.options.preload&&this.options.preload.forEach(e=>r(e)),this.services.backendConnector.load(e,this.options.ns,e=>{e||this.resolvedLanguage||!this.language||this.setResolvedLanguage(this.language),t(e)})}else t(null)}reloadResources(e,t,n){const r=oE();return"function"==typeof e&&(n=e,e=void 0),"function"==typeof t&&(n=t,t=void 0),e||(e=this.languages),t||(t=this.options.ns),n||(n=VE),this.services.backendConnector.reload(e,t,e=>{r.resolve(),n(e)}),r}use(e){if(!e)throw new Error("You are passing an undefined module! Please check the object you are passing to i18next.use()");if(!e.type)throw new Error("You are passing a wrong module! Please check the object you are passing to i18next.use()");return"backend"===e.type&&(this.modules.backend=e),("logger"===e.type||e.log&&e.warn&&e.error)&&(this.modules.logger=e),"languageDetector"===e.type&&(this.modules.languageDetector=e),"i18nFormat"===e.type&&(this.modules.i18nFormat=e),"postProcessor"===e.type&&AE.addPostProcessor(e),"formatter"===e.type&&(this.modules.formatter=e),"3rdParty"===e.type&&this.modules.external.push(e),this}setResolvedLanguage(e){if(e&&this.languages&&!(["cimode","dev"].indexOf(e)>-1))for(let e=0;e<this.languages.length;e++){const t=this.languages[e];if(!(["cimode","dev"].indexOf(t)>-1)&&this.store.hasLanguageSomeTranslations(t)){this.resolvedLanguage=t;break}}}changeLanguage(e,t){var n=this;this.isLanguageChangingTo=e;const r=oE();this.emit("languageChanging",e);const o=e=>{this.language=e,this.languages=this.services.languageUtils.toResolveHierarchy(e),this.resolvedLanguage=void 0,this.setResolvedLanguage(e)},i=(e,i)=>{i?(o(i),this.translator.changeLanguage(i),this.isLanguageChangingTo=void 0,this.emit("languageChanged",i),this.logger.log("languageChanged",i)):this.isLanguageChangingTo=void 0,r.resolve(function(){return n.t(...arguments)}),t&&t(e,function(){return n.t(...arguments)})},a=t=>{e||t||!this.services.languageDetector||(t=[]);const n=rE(t)?t:this.services.languageUtils.getBestMatchFromCodes(t);n&&(this.language||o(n),this.translator.language||this.translator.changeLanguage(n),this.services.languageDetector&&this.services.languageDetector.cacheUserLanguage&&this.services.languageDetector.cacheUserLanguage(n)),this.loadResources(n,e=>{i(e,n)})};return e||!this.services.languageDetector||this.services.languageDetector.async?!e&&this.services.languageDetector&&this.services.languageDetector.async?0===this.services.languageDetector.detect.length?this.services.languageDetector.detect().then(a):this.services.languageDetector.detect(a):a(e):a(this.services.languageDetector.detect()),r}getFixedT(e,t,n){var r=this;const o=function(e,t){let i;if("object"!=typeof t){for(var a=arguments.length,s=new Array(a>2?a-2:0),u=2;u<a;u++)s[u-2]=arguments[u];i=r.options.overloadTranslationOptionHandler([e,t].concat(s))}else i={...t};i.lng=i.lng||o.lng,i.lngs=i.lngs||o.lngs,i.ns=i.ns||o.ns,""!==i.keyPrefix&&(i.keyPrefix=i.keyPrefix||n||o.keyPrefix);const l=r.options.keySeparator||".";let c;return c=i.keyPrefix&&Array.isArray(e)?e.map(e=>`${i.keyPrefix}${l}${e}`):i.keyPrefix?`${i.keyPrefix}${l}${e}`:e,r.t(c,i)};return rE(e)?o.lng=e:o.lngs=e,o.ns=t,o.keyPrefix=n,o}t(){return this.translator&&this.translator.translate(...arguments)}exists(){return this.translator&&this.translator.exists(...arguments)}setDefaultNamespace(e){this.options.defaultNS=e}hasLoadedNamespace(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if(!this.isInitialized)return this.logger.warn("hasLoadedNamespace: i18next was not initialized",this.languages),!1;if(!this.languages||!this.languages.length)return this.logger.warn("hasLoadedNamespace: i18n.languages were undefined or empty",this.languages),!1;const n=t.lng||this.resolvedLanguage||this.languages[0],r=!!this.options&&this.options.fallbackLng,o=this.languages[this.languages.length-1];if("cimode"===n.toLowerCase())return!0;const i=(e,t)=>{const n=this.services.backendConnector.state[`${e}|${t}`];return-1===n||0===n||2===n};if(t.precheck){const e=t.precheck(this,i);if(void 0!==e)return e}return!!this.hasResourceBundle(n,e)||(!(this.services.backendConnector.backend&&(!this.options.resources||this.options.partialBundledLanguages))||!(!i(n,e)||r&&!i(o,e)))}loadNamespaces(e,t){const n=oE();return this.options.ns?(rE(e)&&(e=[e]),e.forEach(e=>{this.options.ns.indexOf(e)<0&&this.options.ns.push(e)}),this.loadResources(e=>{n.resolve(),t&&t(e)}),n):(t&&t(),Promise.resolve())}loadLanguages(e,t){const n=oE();rE(e)&&(e=[e]);const r=this.options.preload||[],o=e.filter(e=>r.indexOf(e)<0&&this.services.languageUtils.isSupportedCode(e));return o.length?(this.options.preload=r.concat(o),this.loadResources(e=>{n.resolve(),t&&t(e)}),n):(t&&t(),Promise.resolve())}dir(e){if(e||(e=this.resolvedLanguage||(this.languages&&this.languages.length>0?this.languages[0]:this.language)),!e)return"rtl";const t=this.services&&this.services.languageUtils||new BE($E());return["ar","shu","sqr","ssh","xaa","yhd","yud","aao","abh","abv","acm","acq","acw","acx","acy","adf","ads","aeb","aec","afb","ajp","apc","apd","arb","arq","ars","ary","arz","auz","avl","ayh","ayl","ayn","ayp","bbz","pga","he","iw","ps","pbt","pbu","pst","prp","prd","ug","ur","ydd","yds","yih","ji","yi","hbo","men","xmn","fa","jpr","peo","pes","prs","dv","sam","ckb"].indexOf(t.getLanguagePartFromCode(e))>-1||e.toLowerCase().indexOf("-arab")>1?"rtl":"ltr"}static createInstance(){return new WE(arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},arguments.length>1?arguments[1]:void 0)}cloneInstance(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:VE;const n=e.forkResourceStore;n&&delete e.forkResourceStore;const r={...this.options,...e,isClone:!0},o=new WE(r);void 0===e.debug&&void 0===e.prefix||(o.logger=o.logger.clone(e));return["store","services","language"].forEach(e=>{o[e]=this[e]}),o.services={...this.services},o.services.utils={hasLoadedNamespace:o.hasLoadedNamespace.bind(o)},n&&(o.store=new SE(this.store.data,r),o.services.resourceStore=o.store),o.translator=new OE(o.services,r),o.translator.on("*",function(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];o.emit(e,...n)}),o.init(r,t),o.translator.options=r,o.translator.backendConnector.services.utils={hasLoadedNamespace:o.hasLoadedNamespace.bind(o)},o}toJSON(){return{options:this.options,store:this.store,language:this.language,languages:this.languages,resolvedLanguage:this.resolvedLanguage}}}const GE=WE.createInstance();GE.createInstance=WE.createInstance,GE.createInstance,GE.dir,GE.init,GE.loadResources,GE.reloadResources,GE.use,GE.changeLanguage,GE.getFixedT,GE.t,GE.exists,GE.setDefaultNamespace,GE.hasLoadedNamespace,GE.loadNamespaces,GE.loadLanguages;var qE="translation";function KE(e,t){GE.addResourceBundle(e,qE,t,!0,!0)}function YE(e){GE.changeLanguage(e)}function XE(e){return GE.getResourceBundle(e,qE)}function ZE(e){return GE.on("languageChanged",e),function(){return GE.off("languageChanged",e)}}GE.init({lng:"zh-CN",resources:{}});var JE=GE.t.bind(GE);function QE(e){if(e.removeAttr){e.removeAttr("width"),e.removeAttr("height"),e.removeAttr("fill"),e.removeAttr("class"),e.removeAttr("t"),e.removeAttr("p-id");var t=e.children();t.length&&QE(t)}}function eC(){return im('<svg viewBox="0 0 1024 1024"><path d="M498.7 655.8l-197.6-268c-8.1-10.9-0.3-26.4 13.3-26.4h395.2c13.6 0 21.4 15.4 13.3 26.4l-197.6 268c-6.6 9-20 9-26.6 0z"></path></svg>')}function tC(){return im('<div class="w-e-bar-divider"></div>')}function nC(e,t,n,r,o){if(void 0===r&&(r=""),void 0===o&&(o=!1),t){if(r){var i=Oy?"cmd":"ctrl";r=r.replace("mod",i)}if(o)r&&(e.attr("data-tooltip",r),e.addClass("w-e-menu-tooltip-v5"),e.addClass("tooltip-right"));else{var a=r?"".concat(n,"\n").concat(r):n;e.attr("data-tooltip",a),e.addClass("w-e-menu-tooltip-v5")}}}var rC=function(){function e(e,t,n){void 0===n&&(n=!1);var r=this;this.$elem=im('<div class="w-e-bar-item"></div>'),this.$button=im('<button type="button"></button>'),this.disabled=!1,this.menu=t;var o=t.tag,i=t.width;if("button"!==o)throw new Error("Invalid tag '".concat(o,"', expected 'button'"));var a=t.title,s=t.hotkey,u=void 0===s?"":s,l=t.iconSvg,c=void 0===l?"":l,d=this.$button;if(c){var f=im(c);QE(f),d.append(f)}else d.text(a);nC(d,c,a,u,n),n&&c&&d.append(im('<span class="title">'.concat(a,"</span>"))),i&&d.css("width","".concat(i,"px")),d.attr("data-menu-key",e),this.$elem.append(d),zm(function(){return r.init()})}return e.prototype.init=function(){var e=this;this.setActive(),this.setDisabled(),this.$button.on("click",function(t){t.preventDefault(),mC(e).hidePanelOrModal(),e.disabled||(e.exec(),e.onButtonClick())})},e.prototype.exec=function(){var e=mC(this),t=this.menu,n=t.getValue(e);this.setIcon(),this.setTooltip(),t.exec(e,n)},e.prototype.setActive=function(){var e=mC(this),t=this.$button,n="active";this.menu.isActive(e)?t.addClass(n):t.removeClass(n)},e.prototype.setDisabled=function(){var e=mC(this),t=this.$button,n=this.menu.isDisabled(e);(null==e.selection||e.isDisabled())&&(n=!0),this.menu.alwaysEnable&&(n=!1);var r="disabled";n?t.addClass(r):t.removeClass(r),this.disabled=n},e.prototype.setIcon=function(){var e=mC(this),t=this.$button;if(this.menu.getIcon){var n=this.menu.getIcon(e);if(n){t.find("svg").remove();var r=im(n);QE(r),t.append(r)}}},e.prototype.setTooltip=function(){var e=mC(this),t=this.$button;if(this.menu.getTitle){var n=this.menu.getTitle(e),r=this.menu.iconSvg;n&&r&&nC(t,r,n)}},e.prototype.changeMenuState=function(){this.setActive(),this.setDisabled()},e}(),oC=function(e){function t(t,n,r){return void 0===r&&(r=!1),e.call(this,t,n,r)||this}return Kg(t,e),t.prototype.onButtonClick=function(){},t}(rC),iC=function(){function e(e){this.isShow=!1,this.showTime=0,this.record(e)}return e.prototype.record=function(e){var t=Ov.get(e);null==t&&(t=new Set,Ov.set(e,t)),t.add(this),Nv.set(this,e)},e.prototype.renderContent=function(e){var t=this.$elem;t.empty(),t.append(e);var n=this.genSelfElem();n&&t.append(n)},e.prototype.appendTo=function(e){var t=this.$elem;e.append(t)},e.prototype.show=function(){if(!this.isShow){this.showTime=Date.now(),this.$elem.show(),this.isShow=!0;var e=Nv.get(this);e&&e.emit("modalOrPanelShow",this)}},e.prototype.hide=function(){if(this.isShow&&!(Date.now()-this.showTime<200)){this.$elem.hide(),this.isShow=!1;var e=Nv.get(this);e&&e.emit("modalOrPanelHide")}},e}(),aC=function(e){function t(t){var n=e.call(this,t)||this;return n.type="dropPanel",n.$elem=im('<div class="w-e-drop-panel"></div>'),n}return Kg(t,e),t.prototype.genSelfElem=function(){return null},t}(iC),sC=function(e){function t(t,n,r){void 0===r&&(r=!1);var o=e.call(this,t,n,r)||this;if(o.dropPanel=null,o.menu=n,n.showDropPanel){var i=eC();o.$button.append(i)}return o}return Kg(t,e),t.prototype.onButtonClick=function(){this.menu.showDropPanel&&this.handleDropPanel()},t.prototype.handleDropPanel=function(){var e=this.menu;if(null!=e.getPanelContentElem){var t=mC(this);if(null==this.dropPanel){var n=new aC(t),r=e.getPanelContentElem(t);n.renderContent(r),n.appendTo(this.$elem),n.show(),this.dropPanel=n}else{var o=this.dropPanel;if(o.isShow)o.hide();else{r=e.getPanelContentElem(t);o.renderContent(r),o.show()}}var i=this.dropPanel;if(i.isShow){var a=this.$elem,s=a.offset().left,u=a.parents(".w-e-bar");s-u.offset().left>=u.width()/2?i.$elem.css({left:"none",right:"0"}):i.$elem.css({left:"0",right:"none"})}}},t}(rC),uC=function(e){function t(t,n){void 0===n&&(n=0);var r=e.call(this,t)||this;r.type="modal",r.$elem=im('<div class="w-e-modal"></div>'),r.width=0,n&&(r.width=n);var o=r.$elem;return o.on("click",function(e){return e.stopPropagation()}),o.on("keyup",function(e){"Escape"===e.code&&(r.hide(),t.restoreSelection())}),r}return Kg(t,e),t.prototype.genSelfElem=function(){var e=this,t=im('<span class="btn-close">'.concat('<svg viewBox="0 0 1024 1024"><path d="M1024 896.1024l-128 128L512 640 128 1024 0 896 384 512 0 128 128 0 512 384 896.1024 0l128 128L640 512z"></path></svg>',"</span>")),n=Nv.get(this);return t.on("click",function(){e.hide(),null==n||n.restoreSelection()}),t},t.prototype.setStyle=function(e){var t=this.width,n=this.$elem;n.attr("style",""),t&&n.css("width","".concat(t,"px")),n.css(e)},t}(iC);function lC(e,t,n){var r=im('<label class="babel-container"></label>');r.append("<span>".concat(e,"</span>"));var o=im('<input type="text" id="'.concat(t,'" placeholder="').concat(n||"",'">'));return r.append(o),[r[0],o[0]]}function cC(e,t,n){var r=im('<label class="babel-container"></label>');r.append("<span>".concat(e,"</span>"));var o=im('<textarea type="text" id="'.concat(t,'" placeholder="').concat(n||"",'"></textarea>'));return r.append(o),[r[0],o[0]]}function dC(e,t){var n=im('<div class="button-container"></div>'),r=im('<button type="button" id="'.concat(e,'">').concat(t,"</button>"));return n.append(r),[n[0],r[0]]}var fC=function(e){function t(t,n,r){void 0===r&&(r=!1);var o=e.call(this,t,n,r)||this;return o.$body=im("body"),o.modal=null,o.menu=n,o}return Kg(t,e),t.prototype.onButtonClick=function(){this.menu.showModal&&this.handleModal()},t.prototype.getPosition=function(){var e=mC(this),t=this.menu.getModalPositionNode(e);return $h.isElement(t)?Xb(e,t,"modal"):Yb(e)},t.prototype.handleModal=function(){var e=mC(this),t=this.menu;if(null==this.modal){var n=new uC(e,t.modalWidth);this.renderAndShowModal(n,!0),this.modal=n}else{(n=this.modal).isShow?n.hide():this.renderAndShowModal(n,!1)}},t.prototype.renderAndShowModal=function(e,t){void 0===t&&(t=!1);var n=mC(this),r=this.menu;if(null!=r.getModalContentElem){var o=Py.getTextarea(n),i=Py.getToolbar(n),a=((null==i?void 0:i.getConfig())||{}).modalAppendToBody,s=r.getModalContentElem(n);if(e.renderContent(s),a)e.setStyle({left:"0",right:"0"});else{var u=this.getPosition();e.setStyle(u)}t&&(a?e.appendTo(this.$body):e.appendTo(o.$textAreaContainer)),e.show(),a||Zb(n,e.$elem),setTimeout(function(){n.blur()})}},t}(rC);var pC=function(e){function t(t,n){var r=e.call(this,t)||this;return r.type="selectList",r.$elem=im('<div class="w-e-select-list"></div>'),n&&r.$elem.css("width","".concat(n,"px")),r.$elem.on("click",function(e){e.stopPropagation()}),r}return Kg(t,e),t.prototype.renderList=function(e){var t=this.$elem;t.empty();var n=im("<ul></ul>");e.forEach(function(e){var t=e.value,r=e.text,o=e.selected,i=e.styleForRenderMenuList,a=im('<li data-value="'.concat(t,'"></li>'));if(i&&a.css(i),o){var s=im('<svg viewBox="0 0 1446 1024"><path d="M574.116299 786.736392 1238.811249 48.517862C1272.390222 11.224635 1329.414799 7.827718 1366.75664 41.450462 1403.840015 74.840484 1406.731043 132.084741 1373.10189 169.433699L655.118888 966.834607C653.072421 969.716875 650.835807 972.514337 648.407938 975.210759 615.017957 1012.29409 558.292155 1015.652019 521.195664 982.250188L72.778218 578.493306C35.910826 545.297758 32.859041 488.584019 66.481825 451.242134 99.871807 414.158803 156.597563 410.800834 193.694055 444.202665L574.116299 786.736392Z"></path></svg>');a.append(s),a.addClass("selected")}a.append(im('<span data-value="'.concat(t,'">').concat(r,"</span>"))),a.attr("title",r),n.append(a)}),t.append(n)},t.prototype.genSelfElem=function(){return null},t}(iC);var hC=function(){function e(e,t,n){void 0===n&&(n=!1);var r=this;this.$elem=im('<div class="w-e-bar-item"></div>'),this.$button=im('<button type="button" class="select-button"></button>'),this.disabled=!1,this.selectList=null;var o=t.tag,i=t.title,a=t.width,s=t.iconSvg,u=void 0===s?"":s,l=t.hotkey,c=void 0===l?"":l;if("select"!==o)throw new Error("Invalid tag '".concat(o,"', expected 'select'"));var d=this.$button;a&&d.css("width","".concat(a,"px")),d.attr("data-menu-key",e),nC(d,u,i,c,n),this.$elem.append(d),this.menu=t,zm(function(){return r.init()})}return e.prototype.init=function(){var e=this;this.setSelectedValue(),this.$button.on("click",function(t){t.preventDefault(),mC(e).hidePanelOrModal(),e.trigger()})},e.prototype.trigger=function(){var e=this,t=mC(this);if(!t.isDisabled()&&!this.disabled){var n=this.menu;if(null==this.selectList){this.selectList=new pC(t,n.selectPanelWidth);var r=this.selectList,o=n.getOptions(t);r.renderList(o),r.appendTo(this.$elem),r.show(),r.$elem.on("click","li",function(t){var n=t.target;if(null!=n){t.preventDefault();var r=im(n).attr("data-value");e.onChange(r)}})}else{if((r=this.selectList).isShow)r.hide();else{o=n.getOptions(t);r.renderList(o),r.show()}}}},e.prototype.onChange=function(e){var t=mC(this),n=this.menu;n.exec&&n.exec(t,e)},e.prototype.setSelectedValue=function(){var e=mC(this),t=this.menu,n=t.getValue(e),r=function(e,t){for(var n=e.length,r="",o=0;o<n;o++){var i=e[o];if(i.value===t){r=i.text;break}}return r}(t.getOptions(e),n.toString()),o=this.$button,i=eC();o.empty(),o.text(r),o.append(i)},e.prototype.setDisabled=function(){var e=mC(this),t=this.menu.isDisabled(e),n=this.$button;(null==e.selection||e.isDisabled())&&(t=!0);var r="disabled";t?n.addClass(r):n.removeClass(r),this.disabled=t},e.prototype.changeMenuState=function(){this.setSelectedValue(),this.setDisabled()},e}(),gC=function(){function e(e){this.$elem=im('<div class="w-e-bar-item w-e-bar-item-group"></div>'),this.$container=im('<div class="w-e-bar-item-menus-container"></div>'),this.$button=im('<button type="button"></button>');var t=e.key,n=e.iconSvg,r=e.title,o=this.$elem,i=this.$button;if(n){var a=im(n);QE(a),i.append(a)}else i.text(r);i.attr("data-menu-key",t);var s=eC();i.append(s),o.append(i);var u=this.$container;o.append(u);var l=this.createObserver();this.observe(l)}return e.prototype.appendBarItem=function(e){var t=e.$elem;this.$container.append(t)},e.prototype.observe=function(e){var t=this.$container;e.observe(t[0],{childList:!0,subtree:!0,attributes:!0})},e.prototype.createObserver=function(){var e=this,t=this.$container,n=this.$button,r=new MutationObserver(function(){var o=t.find("button"),i=o.length;if(0!==i){var a=0;o.each(function(e){im(e).hasClass("disabled")&&a++}),r.disconnect(),a===i?n.addClass("disabled"):n.removeClass("disabled"),e.observe(r)}});return r},e}(),vC=new WeakMap;function mC(e){var t=xv.get(e);if(null==t)throw new Error("Can not get editor instance");return t}function yC(e,t,n){void 0===n&&(n=!1);var r=vC.get(t);if(r)return r;var o=t.tag;if("button"===o){var i=t.showDropPanel,a=t.showModal;r=i?new sC(e,t,n):a?new fC(e,t,n):new oC(e,t,n)}if("select"===o&&(r=new hC(e,t,n)),null==r)throw new Error("Invalid tag in menu ".concat(JSON.stringify(t)));return vC.set(t,r),r}function bC(e,t){var n=e.selection;return null!=n&&(!fg.isCollapsed(n)&&(!Py.getSelectedElems(e).some(function(t){if(e.isVoid(t))return!0;var n=t.type;return!!["pre","code","table"].includes(n)})&&!!Cg.isText(t)))}var EC,CC,DC=function(){function e(){var e=this;this.$elem=im('<div class="w-e-bar w-e-bar-hidden w-e-hover-bar"></div>'),this.menus={},this.hoverbarItems=[],this.prevSelectedNode=null,this.isShow=!1,this.lngListen=function(){},this.changeHoverbarState=nE(function(){var t=e.isShow,n=e.getSelectedNodeAndMenuKeys()||{},r=n.node,o=void 0===r?null:r,i=n.menuKeys,a=void 0===i?[]:i,s=e.getEditorInstance();if(null!=o&&e.changeItemsState(),o&&$h.isElement(o)&&t){var u=e.isSamePath(o,e.prevSelectedNode);if(!Kh.isBlock(s,o)&&u)return}e.hideAndClean(),null!=o&&(e.registerItems(a),e.setPosition(o),e.show()),e.prevSelectedNode=o},200),zm(function(){var t=e.getEditorInstance(),n=e.$elem;n.on("mousedown",function(e){return e.preventDefault()},{passive:!1}),Py.getTextarea(t).$textAreaContainer.append(n),t.on(hv,e.changeHoverbarState);var r=e.hideAndClean.bind(e);t.on(gv,r),t.on(vv,r),t.on(mv,r)}),this.lngListen=ZE(function(){e.menus={},e.hideAndClean(),e.getEditorInstance().deselect()})}return e.prototype.getMenus=function(){return this.menus},e.prototype.hideAndClean=function(){var e=this.$elem;e.removeClass("w-e-bar-show").addClass("w-e-bar-hidden"),this.hoverbarItems=[],e.empty(),this.isShow=!1},e.prototype.checkPositionBottom=function(){var e=this.$elem,t=!1,n="undefined"!=typeof window?window.innerHeight:null;n&&n>=360&&(n-e[0].getBoundingClientRect().bottom<360&&(t=!0));t?e.addClass("w-e-bar-bottom"):e.removeClass("w-e-bar-bottom")},e.prototype.show=function(){this.$elem.removeClass("w-e-bar-hidden").addClass("w-e-bar-show"),this.isShow=!0,this.checkPositionBottom()},e.prototype.changeItemsState=function(){var e=this;zm(function(){e.hoverbarItems.forEach(function(e){e.changeMenuState()})})},e.prototype.registerItems=function(e){var t=this,n=this.$elem;e.forEach(function(e){if("|"!==e)t.registerSingleItem(e);else{var r=tC();n.append(r)}})},e.prototype.registerSingleItem=function(e){var t=this.getEditorInstance(),n=this.menus,r=n[e];if(null==r){var o=yv[e];if(null==o)throw new Error("Not found menu item factory by key '".concat(e,"'"));if("function"!=typeof o)throw new Error("Menu item factory (key='".concat(e,"') is not a function"));r=o(),n[e]=r}var i=t.getMenuConfig(e);i&&void 0!==i.iconSvg&&(r.iconSvg=i.iconSvg);var a=yC(e,r);this.hoverbarItems.push(a),xv.set(a,t),this.$elem.append(a.$elem)},e.prototype.setPosition=function(e){var t=this.getEditorInstance(),n=this.$elem;if(n.attr("style",""),$h.isElement(e)){var r=Xb(t,e,"bar");return n.css(r),void Zb(t,n)}if(Cg.isText(e)){r=Yb(t);return n.css(r),void Zb(t,n)}throw new Error("hoverbar.setPosition error, current selected node is not elem nor text")},e.prototype.getSelectedNodeAndMenuKeys=function(){var e=this.getEditorInstance();if(null==e.selection)return null;var t=this.getHoverbarKeysConf(),n=null,r=[],o=function(o){var i=t[o],a=i.match,s=i.menuKeys,u=void 0===s?[]:s,l=a||function(e,t){return Py.checkNodeType(t,o)},c=ev(Kh.nodes(e,{match:function(t){return l(e,t)},universal:!0}),1),d=c[0];if(null!=d)return n=d[0],r=u,"break"};for(var i in t){if("break"===o(i))break}return null==n||0===r.length?null:{node:n,menuKeys:r}},e.prototype.getEditorInstance=function(){var e=Sv.get(this);if(null==e)throw new Error("Can not get editor instance");return e},e.prototype.getHoverbarKeysConf=function(){var e=this.getEditorInstance().getConfig().hoverbarKeys,t=void 0===e?{}:e,n=t.text;return n&&null==n.match&&(n.match=bC),t},e.prototype.isSamePath=function(e,t){if(null==e||null==t)return!1;var n=Py.findPath(null,e),r=Py.findPath(null,t);return og.equals(n,r)},e.prototype.destroy=function(){var e;this.changeHoverbarState.cancel(),this.$elem.remove(),null===(e=this.lngListen)||void 0===e||e.call(this),this.menus={},this.hoverbarItems=[],this.prevSelectedNode=null},e}();function wC(){if(CC)return EC;CC=1;var e="Expected a function",t=/^\s+|\s+$/g,n=/^[-+]0x[0-9a-f]+$/i,r=/^0b[01]+$/i,o=/^0o[0-7]+$/i,i=parseInt,a="object"==typeof y&&y&&y.Object===Object&&y,s="object"==typeof self&&self&&self.Object===Object&&self,u=a||s||Function("return this")(),l=Object.prototype.toString,c=Math.max,d=Math.min,f=function(){return u.Date.now()};function p(t,n,r){var o,i,a,s,u,l,p=0,v=!1,m=!1,y=!0;if("function"!=typeof t)throw new TypeError(e);function b(e){var n=o,r=i;return o=i=void 0,p=e,s=t.apply(r,n)}function E(e){var t=e-l;return void 0===l||t>=n||t<0||m&&e-p>=a}function C(){var e=f();if(E(e))return D(e);u=setTimeout(C,function(e){var t=n-(e-l);return m?d(t,a-(e-p)):t}(e))}function D(e){return u=void 0,y&&o?b(e):(o=i=void 0,s)}function w(){var e=f(),t=E(e);if(o=arguments,i=this,l=e,t){if(void 0===u)return function(e){return p=e,u=setTimeout(C,n),v?b(e):s}(l);if(m)return u=setTimeout(C,n),b(l)}return void 0===u&&(u=setTimeout(C,n)),s}return n=g(n)||0,h(r)&&(v=!!r.leading,a=(m="maxWait"in r)?c(g(r.maxWait)||0,n):a,y="trailing"in r?!!r.trailing:y),w.cancel=function(){void 0!==u&&clearTimeout(u),p=0,o=l=i=u=void 0},w.flush=function(){return void 0===u?s:D(f())},w}function h(e){var t=typeof e;return!!e&&("object"==t||"function"==t)}function g(e){if("number"==typeof e)return e;if(function(e){return"symbol"==typeof e||function(e){return!!e&&"object"==typeof e}(e)&&"[object Symbol]"==l.call(e)}(e))return NaN;if(h(e)){var a="function"==typeof e.valueOf?e.valueOf():e;e=h(a)?a+"":a}if("string"!=typeof e)return 0===e?e:+e;e=e.replace(t,"");var s=r.test(e);return s||o.test(e)?i(e.slice(2),s?2:8):n.test(e)?NaN:+e}return EC=function(t,n,r){var o=!0,i=!0;if("function"!=typeof t)throw new TypeError(e);return h(r)&&(o="leading"in r?!!r.leading:o,i="trailing"in r?!!r.trailing:i),p(t,n,{leading:o,maxWait:n,trailing:i})}}var SC=b(wC());function AC(e,t){return Gm(t)&&Py.hasDOMNode(e,t,{editable:!0})}function xC(e,t){if(e.getConfig().readOnly)return!1;var n=OC(e,t)&&Py.toSlateNode(e,t);return Kh.isVoid(e,n)}function OC(e,t){return Gm(t)&&Py.hasDOMNode(e,t)}const NC=e=>"object"==typeof e&&null!=e&&1===e.nodeType,BC=(e,t)=>(!t||"hidden"!==e)&&"visible"!==e&&"clip"!==e,TC=(e,t)=>{if(e.clientHeight<e.scrollHeight||e.clientWidth<e.scrollWidth){const n=getComputedStyle(e,null);return BC(n.overflowY,t)||BC(n.overflowX,t)||(e=>{const t=(e=>{if(!e.ownerDocument||!e.ownerDocument.defaultView)return null;try{return e.ownerDocument.defaultView.frameElement}catch(e){return null}})(e);return!!t&&(t.clientHeight<e.scrollHeight||t.clientWidth<e.scrollWidth)})(e)}return!1},kC=(e,t,n,r,o,i,a,s)=>i<e&&a>t||i>e&&a<t?0:i<=e&&s<=n||a>=t&&s>=n?i-e-r:a>t&&s<n||i<e&&s>n?a-t+o:0,FC=e=>{const t=e.parentElement;return null==t?e.getRootNode().host||null:t},IC=(e,t)=>{var n,r,o,i;if("undefined"==typeof document)return[];const{scrollMode:a,block:s,inline:u,boundary:l,skipOverflowHiddenElements:c}=t,d="function"==typeof l?l:e=>e!==l;if(!NC(e))throw new TypeError("Invalid target");const f=document.scrollingElement||document.documentElement,p=[];let h=e;for(;NC(h)&&d(h);){if(h=FC(h),h===f){p.push(h);break}null!=h&&h===document.body&&TC(h)&&!TC(document.documentElement)||null!=h&&TC(h,c)&&p.push(h)}const g=null!=(r=null==(n=window.visualViewport)?void 0:n.width)?r:innerWidth,v=null!=(i=null==(o=window.visualViewport)?void 0:o.height)?i:innerHeight,{scrollX:m,scrollY:y}=window,{height:b,width:E,top:C,right:D,bottom:w,left:S}=e.getBoundingClientRect(),{top:A,right:x,bottom:O,left:N}=(e=>{const t=window.getComputedStyle(e);return{top:parseFloat(t.scrollMarginTop)||0,right:parseFloat(t.scrollMarginRight)||0,bottom:parseFloat(t.scrollMarginBottom)||0,left:parseFloat(t.scrollMarginLeft)||0}})(e);let B="start"===s||"nearest"===s?C-A:"end"===s?w+O:C+b/2-A+O,T="center"===u?S+E/2-N+x:"end"===u?D+x:S-N;const k=[];for(let e=0;e<p.length;e++){const t=p[e],{height:n,width:r,top:o,right:i,bottom:l,left:c}=t.getBoundingClientRect();if("if-needed"===a&&C>=0&&S>=0&&w<=v&&D<=g&&(t===f&&!TC(t)||C>=o&&w<=l&&S>=c&&D<=i))return k;const d=getComputedStyle(t),h=parseInt(d.borderLeftWidth,10),A=parseInt(d.borderTopWidth,10),x=parseInt(d.borderRightWidth,10),O=parseInt(d.borderBottomWidth,10);let N=0,F=0;const I="offsetWidth"in t?t.offsetWidth-t.clientWidth-h-x:0,P="offsetHeight"in t?t.offsetHeight-t.clientHeight-A-O:0,_="offsetWidth"in t?0===t.offsetWidth?0:r/t.offsetWidth:0,L="offsetHeight"in t?0===t.offsetHeight?0:n/t.offsetHeight:0;if(f===t)N="start"===s?B:"end"===s?B-v:"nearest"===s?kC(y,y+v,v,A,O,y+B,y+B+b,b):B-v/2,F="start"===u?T:"center"===u?T-g/2:"end"===u?T-g:kC(m,m+g,g,h,x,m+T,m+T+E,E),N=Math.max(0,N+y),F=Math.max(0,F+m);else{N="start"===s?B-o-A:"end"===s?B-l+O+P:"nearest"===s?kC(o,l,n,A,O+P,B,B+b,b):B-(o+n/2)+P/2,F="start"===u?T-c-h:"center"===u?T-(c+r/2)+I/2:"end"===u?T-i+x+I:kC(c,i,r,h,x+I,T,T+E,E);const{scrollLeft:e,scrollTop:a}=t;N=0===L?0:Math.max(0,Math.min(a+N/L,t.scrollHeight-n/L+P)),F=0===_?0:Math.max(0,Math.min(e+F/_,t.scrollWidth-r/_+I)),B+=a-N,T+=e-F}k.push({el:t,top:N,left:F})}return k};function PC(e,t){if(!e.isConnected||!(e=>{let t=e;for(;t&&t.parentNode;){if(t.parentNode===document)return!0;t=t.parentNode instanceof ShadowRoot?t.parentNode.host:t.parentNode}return!1})(e))return;const n=(e=>{const t=window.getComputedStyle(e);return{top:parseFloat(t.scrollMarginTop)||0,right:parseFloat(t.scrollMarginRight)||0,bottom:parseFloat(t.scrollMarginBottom)||0,left:parseFloat(t.scrollMarginLeft)||0}})(e);if((e=>"object"==typeof e&&"function"==typeof e.behavior)(t))return t.behavior(IC(e,t));const r="boolean"==typeof t||null==t?void 0:t.behavior;for(const{el:o,top:i,left:a}of IC(e,(e=>!1===e?{block:"end",inline:"nearest"}:(e=>e===Object(e)&&0!==Object.keys(e).length)(e)?e:{block:"start",inline:"nearest"})(t))){const e=i-n.top+n.bottom,t=a-n.left+n.right;o.scroll({top:e,left:t,behavior:r})}}function _C(e,t,n){void 0===n&&(n=!1);var r=t.selection,o=t.getConfig(),i=Py.findDocumentOrShadowRoot(t).getSelection();if(i&&(!e.isComposing||n)&&t.isFocused()){var a="None"!==i.type;if(r||a){var s=Rv.get(t),u=!1;if(s.contains(i.anchorNode)&&s.contains(i.focusNode)&&(u=!0),a&&u&&r){var l=Py.toSlateRange(t,i,{exactMatch:!0,suppressThrow:!0});if(l&&fg.equals(l,r)){var c=!0;if(fg.isCollapsed(r)){var d=i.anchorNode,f=i.anchorOffset;if(d===s){var p=s.childNodes,h=void 0;(h=p[f])&&h.matches("table")&&(c=!1),(h=p[f-1])&&h.matches("table")&&(c=!1)}}if(c)return}}if(!r||Py.hasRange(t,r)){e.isUpdatingSelection=!0;var g=r&&Py.toDOMRange(t,r);if(g){fg.isBackward(r)?i.setBaseAndExtent(g.endContainer,g.endOffset,g.startContainer,g.startOffset):i.setBaseAndExtent(g.startContainer,g.startOffset,g.endContainer,g.endOffset);var v=g.startContainer.parentElement;if(!v.closest("[data-slate-spacer]")&&g.getBoundingClientRect){v.getBoundingClientRect=g.getBoundingClientRect.bind(g);var m=document.body;PC(v,{scrollMode:"if-needed",boundary:o.scroll?s.parentElement:m,block:"end",behavior:"smooth"}),delete v.getBoundingClientRect}}else i.removeAllRanges();setTimeout(function(){g&&Ny&&s.focus(),e.isUpdatingSelection=!1})}else t.selection=Py.toSlateRange(t,i,{exactMatch:!1,suppressThrow:!1})}}}var LC=new WeakMap,RC=new WeakMap;var MC,jC={};var HC=function(){if(MC)return jC;MC=1,Object.defineProperty(jC,"__esModule",{value:!0});for(var e="undefined"!=typeof window&&/Mac|iPod|iPhone|iPad/.test(window.navigator.platform),t={alt:"altKey",control:"ctrlKey",meta:"metaKey",shift:"shiftKey"},n={add:"+",break:"pause",cmd:"meta",command:"meta",ctl:"control",ctrl:"control",del:"delete",down:"arrowdown",esc:"escape",ins:"insert",left:"arrowleft",mod:e?"meta":"control",opt:"alt",option:"alt",return:"enter",right:"arrowright",space:" ",spacebar:" ",up:"arrowup",win:"meta",windows:"meta"},r={backspace:8,tab:9,enter:13,shift:16,control:17,alt:18,pause:19,capslock:20,escape:27," ":32,pageup:33,pagedown:34,end:35,home:36,arrowleft:37,arrowup:38,arrowright:39,arrowdown:40,insert:45,delete:46,meta:91,numlock:144,scrolllock:145,";":186,"=":187,",":188,"-":189,".":190,"/":191,"`":192,"[":219,"\\":220,"]":221,"'":222},o=1;o<20;o++)r["f"+o]=111+o;function i(e,t,n){t&&!("byKey"in t)&&(n=t,t=null),Array.isArray(e)||(e=[e]);var r=e.map(function(e){return a(e,t)}),o=function(e){return r.some(function(t){return s(t,e)})};return null==n?o:o(n)}function a(e,o){var i=o&&o.byKey,a={},s=(e=e.replace("++","+add")).split("+"),c=s.length;for(var d in t)a[t[d]]=!1;var f=!0,p=!1,h=void 0;try{for(var g,v=s[Symbol.iterator]();!(f=(g=v.next()).done);f=!0){var m=g.value,y=m.endsWith("?")&&m.length>1;y&&(m=m.slice(0,-1));var b=l(m),E=t[b];if(m.length>1&&!E&&!n[m]&&!r[b])throw new TypeError('Unknown modifier: "'+m+'"');1!==c&&E||(i?a.key=b:a.which=u(m)),E&&(a[E]=!y||null)}}catch(e){p=!0,h=e}finally{try{!f&&v.return&&v.return()}finally{if(p)throw h}}return a}function s(e,t){for(var n in e){var r=e[n],o=void 0;if(null!=r&&((null!=(o="key"===n&&null!=t.key?t.key.toLowerCase():"which"===n?91===r&&93===t.which?91:t.which:t[n])||!1!==r)&&o!==r))return!1}return!0}function u(e){return e=l(e),r[e]||e.toUpperCase().charCodeAt(0)}function l(e){return e=e.toLowerCase(),e=n[e]||e}return jC.default=i,jC.isHotkey=i,jC.isCodeHotkey=function(e,t){return i(e,t)},jC.isKeyHotkey=function(e,t){return i(e,{byKey:!0},t)},jC.parseHotkey=a,jC.compareHotkey=s,jC.toKeyCode=u,jC.toKeyName=l,jC}(),zC={bold:"mod+b",compose:["down","left","right","up","backspace","enter"],moveBackward:"left",moveForward:"right",moveWordBackward:"ctrl+left",moveWordForward:"ctrl+right",deleteBackward:"shift?+backspace",deleteForward:"shift?+delete",extendBackward:"shift+left",extendForward:"shift+right",italic:"mod+i",splitBlock:"shift?+enter",undo:"mod+z",tab:"tab",selectAll:"mod+a"},$C={moveLineBackward:"opt+up",moveLineForward:"opt+down",moveWordBackward:"opt+left",moveWordForward:"opt+right",deleteBackward:["ctrl+backspace","ctrl+h"],deleteForward:["ctrl+delete","ctrl+d"],deleteLineBackward:"cmd+shift?+backspace",deleteLineForward:["cmd+shift?+delete","ctrl+k"],deleteWordBackward:"opt+shift?+backspace",deleteWordForward:"opt+shift?+delete",extendLineBackward:"opt+shift+up",extendLineForward:"opt+shift+down",redo:"cmd+shift+z",transposeCharacter:"ctrl+t"},UC={deleteWordBackward:"ctrl+shift?+backspace",deleteWordForward:"ctrl+shift?+delete",redo:["ctrl+y","ctrl+shift+z"]},VC=function(e){var t=zC[e],n=$C[e],r=UC[e],o=t&&HC.isKeyHotkey(t),i=n&&HC.isKeyHotkey(n),a=r&&HC.isKeyHotkey(r);return function(e){return!(!o||!o(e))||(!!(Oy&&i&&i(e))||!(Oy||!a||!a(e)))}},WC={isBold:VC("bold"),isCompose:VC("compose"),isMoveBackward:VC("moveBackward"),isMoveForward:VC("moveForward"),isDeleteBackward:VC("deleteBackward"),isDeleteForward:VC("deleteForward"),isDeleteLineBackward:VC("deleteLineBackward"),isDeleteLineForward:VC("deleteLineForward"),isDeleteWordBackward:VC("deleteWordBackward"),isDeleteWordForward:VC("deleteWordForward"),isExtendBackward:VC("extendBackward"),isExtendForward:VC("extendForward"),isExtendLineBackward:VC("extendLineBackward"),isExtendLineForward:VC("extendLineForward"),isItalic:VC("italic"),isMoveLineBackward:VC("moveLineBackward"),isMoveLineForward:VC("moveLineForward"),isMoveWordBackward:VC("moveWordBackward"),isMoveWordForward:VC("moveWordForward"),isRedo:VC("redo"),isSplitBlock:VC("splitBlock"),isTransposeCharacter:VC("transposeCharacter"),isUndo:VC("undo"),isTab:VC("tab"),isSelectAll:VC("selectAll")};function GC(e){e.preventDefault()}var qC={beforeinput:function(e,t,n){var r=e,o=n.getConfig().readOnly;if(Iy&&!o&&AC(n,r.target)){var i=n.selection,a=r.inputType,s=r.dataTransfer||r.data||void 0;if("insertCompositionText"!==a&&"deleteCompositionText"!==a){if(r.preventDefault(),!a.startsWith("delete")||a.startsWith("deleteBy")){var u=ev(r.getTargetRanges(),1)[0];if(u){var l=Py.toSlateRange(n,u,{exactMatch:!1,suppressThrow:!1});i&&fg.equals(i,l)||jg.select(n,l)}}if(i&&fg.isExpanded(i)){var c=Py.getSelectedElems(n),d="table"===c[0].type,f="table-cell"!==c[c.length-1].type;if(d&&f)return;if(a.startsWith("delete")){var p=a.endsWith("Backward")?"backward":"forward";return void Kh.deleteFragment(n,{direction:p})}}switch(a){case"deleteByComposition":case"deleteByCut":case"deleteByDrag":Kh.deleteFragment(n);break;case"deleteContent":case"deleteContentForward":Kh.deleteForward(n);break;case"deleteContentBackward":Kh.deleteBackward(n);break;case"deleteEntireSoftLine":Kh.deleteBackward(n,{unit:"line"}),Kh.deleteForward(n,{unit:"line"});break;case"deleteHardLineBackward":Kh.deleteBackward(n,{unit:"block"});break;case"deleteSoftLineBackward":Kh.deleteBackward(n,{unit:"line"});break;case"deleteHardLineForward":Kh.deleteForward(n,{unit:"block"});break;case"deleteSoftLineForward":Kh.deleteForward(n,{unit:"line"});break;case"deleteWordBackward":Kh.deleteBackward(n,{unit:"word"});break;case"deleteWordForward":Kh.deleteForward(n,{unit:"word"});break;case"insertLineBreak":case"insertParagraph":Kh.insertBreak(n);break;case"insertFromDrop":case"insertFromPaste":case"insertFromYank":case"insertReplacementText":case"insertText":if("insertFromPaste"===a&&!Gv.get(n))break;"[object DataTransfer]"===Um(s)?n.insertData(s):"string"==typeof s&&Kh.insertText(n,s)}}}},blur:function(e,t,n){var r=e,o=t.isUpdatingSelection,i=t.latestElement;if(!n.getConfig().readOnly&&!o&&AC(n,r.target)){var a=Py.findDocumentOrShadowRoot(n);if(i!==a.activeElement){var s=r.relatedTarget;if(!(s===Py.toDOMNode(n,n)||Km(s)&&s.hasAttribute("data-slate-spacer"))){if(null!=s&&Gm(s)&&Py.hasDOMNode(n,s)){var u=Py.toSlateNode(n,s);if($h.isElement(u)&&!n.isVoid(u))return}if(By){var l=a.getSelection();null==l||l.removeAllRanges()}Uv.delete(n)}}}},focus:function(e,t,n){var r=Py.toDOMNode(n,n),o=Py.findDocumentOrShadowRoot(n);t.latestElement=o.activeElement,Ny&&e.target!==r?r.focus():Uv.set(n,!0)},click:function(e,t,n){if(!n.getConfig().readOnly&&OC(n,e.target)&&Gm(e.target)){var r=Py.toSlateNode(n,e.target),o=Py.findPath(n,r);if(Kh.hasPath(n,o))if(eg.get(n,o)===r){var i=Kh.start(n,o),a=Kh.end(n,o),s=Kh.void(n,{at:i}),u=Kh.void(n,{at:a});if(s&&u&&og.equals(s[1],u[1])){var l=Kh.range(n,i);jg.select(n,l)}}}},compositionstart:function(e,t,n){if(AC(n,e.target)){var r=n.selection;if(r&&fg.isExpanded(r)&&(Kh.deleteFragment(n),Promise.resolve().then(function(){_C(t,n,!0)})),n.selection){var o=Py.toDOMRange(n,n.selection).startContainer,i=o.textContent||"";LC.set(n,i),RC.set(n,o)}t.isComposing=!0,function(e,t){var n;t.getConfig().placeholder&&t.isEmpty()&&e.showPlaceholder&&(null===(n=e.$placeholder)||void 0===n||n.hide(),e.showPlaceholder=!1)}(t,n)}},compositionend:function(e,t,n){var r=e;if(AC(n,r.target)){t.isComposing=!1;var o=n.selection;if(null!=o){(Fy||Ny)&&Py.cleanExposedTexNodeInSelectionBlock(n);for(var i=fg.isBackward(o)?o.focus:o.anchor,a=ev(Kh.node(n,[i.path[0]]),1)[0],s=0;s<i.path.length;s+=1){var u=ev(Kh.node(n,i.path.slice(0,s+1)),1)[0];if($h.isElement(u)&&((By||Ny)&&"link"===u.type||"code"===u.type)){Py.setNewKey(a);break}}var l=r.data;if(l){if(n.getConfig().maxLength){var c=Py.getLeftLengthOfMaxLength(n);if(c<l.length){var d=Py.toDOMRange(n,o);d.startContainer.nodeType===Node.TEXT_NODE&&(d.startContainer.textContent=LC.get(n)||""),c>0&&Kh.insertText(n,l.slice(0,c)),t.changeViewState()}else Kh.insertText(n,l)}else{var f=Py.findDocumentOrShadowRoot(n).getSelection();f&&function(e,t){if(fg.isCollapsed(t)){var n=t.anchor,r=t.focus;if([2,3].includes(n.path.length)&&[2,3].includes(r.path.length)&&(0===n.offset||0===r.offset)){var o=Kh.node(e,n.path),i=0===n.offset?n.path:r.path,a=[i[0],i[1]-1];if(0===i[1])return!1;var s=Kh.node(e,a);if(Cg.isText(s[0])&&Cg.isText(o[0]))return!0}}}(n,o)&&(n.selection=Py.toSlateRange(n,f,{exactMatch:!1,suppressThrow:!1})),Kh.insertText(n,l)}By||setTimeout(function(){var e=n.selection;if(null!=e){var t=RC.get(n);if(null!=t)Py.toDOMRange(n,e).startContainer!==t&&(t.textContent=LC.get(n)||"")}})}}}},compositionupdate:function(e,t,n){AC(n,e.target)&&(t.isComposing=!0)},keydown:function(e,t,n){var r=e,o=n.selection;if(!n.getConfig().readOnly&&!t.isComposing&&AC(n,r.target)){if(function(e,t){var n=wv.get(e),r=n&&n.getMenus(),o=Av.get(e),i=o&&o.getMenus(),a=Yg(Yg({},r),i);for(var s in a){var u=a[s],l=u.hotkey;if(l&&HC.isHotkey(l,t)&&!u.isDisabled(e)){var c=u.getValue(e);u.exec(e,c)}}}(n,r),WC.isTab(r))return GC(r),void n.handleTab();if(WC.isRedo(r))return GC(r),void("function"==typeof n.redo&&n.redo());if(WC.isUndo(r))return GC(r),void("function"==typeof n.undo&&n.undo());if(WC.isMoveLineBackward(r))return GC(r),void jg.move(n,{unit:"line",reverse:!0});if(WC.isMoveLineForward(r))return GC(r),void jg.move(n,{unit:"line"});if(WC.isExtendLineBackward(r))return GC(r),void jg.move(n,{unit:"line",edge:"focus",reverse:!0});if(WC.isExtendLineForward(r))return GC(r),void jg.move(n,{unit:"line",edge:"focus"});if(WC.isMoveBackward(r))return GC(r),void(o&&fg.isCollapsed(o)?jg.move(n,{reverse:!0}):jg.collapse(n,{edge:"start"}));if(WC.isMoveForward(r))return GC(r),void(o&&fg.isCollapsed(o)?jg.move(n):jg.collapse(n,{edge:"end"}));if(WC.isMoveWordBackward(r))return GC(r),o&&fg.isExpanded(o)&&jg.collapse(n,{edge:"focus"}),void jg.move(n,{unit:"word",reverse:!0});if(WC.isMoveWordForward(r))return GC(r),o&&fg.isExpanded(o)&&jg.collapse(n,{edge:"focus"}),void jg.move(n,{unit:"word"});if(WC.isSelectAll(r))return GC(r),void n.selectAll();if(Iy){if((Fy||By)&&o&&(WC.isDeleteBackward(r)||WC.isDeleteForward(r))&&fg.isCollapsed(o)){var i=eg.parent(n,o.anchor.path);if($h.isElement(i)&&Kh.isVoid(n,i)&&Kh.isInline(n,i))return r.preventDefault(),void jg.delete(n,{unit:"block"})}}else{if(WC.isBold(r)||WC.isItalic(r)||WC.isTransposeCharacter(r))return void GC(r);if(WC.isSplitBlock(r))return GC(r),void Kh.insertBreak(n);if(WC.isDeleteBackward(r))return GC(r),void(o&&fg.isExpanded(o)?Kh.deleteFragment(n,{direction:"backward"}):Kh.deleteBackward(n));if(WC.isDeleteForward(r))return GC(r),void(o&&fg.isExpanded(o)?Kh.deleteFragment(n,{direction:"forward"}):Kh.deleteForward(n));if(WC.isDeleteLineBackward(r))return GC(r),void(o&&fg.isExpanded(o)?Kh.deleteFragment(n,{direction:"backward"}):Kh.deleteBackward(n,{unit:"line"}));if(WC.isDeleteLineForward(r))return GC(r),void(o&&fg.isExpanded(o)?Kh.deleteFragment(n,{direction:"forward"}):Kh.deleteForward(n,{unit:"line"}));if(WC.isDeleteWordBackward(r))return GC(r),void(o&&fg.isExpanded(o)?Kh.deleteFragment(n,{direction:"backward"}):Kh.deleteBackward(n,{unit:"word"}));if(WC.isDeleteWordForward(r))return GC(r),void(o&&fg.isExpanded(o)?Kh.deleteFragment(n,{direction:"forward"}):Kh.deleteForward(n,{unit:"word"}))}}},keypress:function(e,t,n){if(!Iy&&!n.getConfig().readOnly&&AC(n,e.target)){e.preventDefault();var r=e.key;Kh.insertText(n,r)}},copy:function(e,t,n){var r=e;if(AC(n,r.target)){n.getConfig().readOnly||r.preventDefault();var o=r.clipboardData;if(null!=o){n.setFragmentData(o);var i=n.getConfig().customCopy;i&&i(n,r)}}},cut:function(e,t,n){var r=e,o=n.selection;if(!n.getConfig().readOnly&&(r.preventDefault(),AC(n,r.target))){var i=r.clipboardData;if(null!=i&&(n.setFragmentData(i),o))if(fg.isExpanded(o))Kh.deleteFragment(n);else{var a=eg.parent(n,o.anchor.path);Kh.isVoid(n,a)&&jg.delete(n)}}},paste:function(e,t,n){Gv.set(n,!0);var r=e;if(!n.getConfig().readOnly&&AC(n,r.target)){var o=n.getConfig().customPaste;if(o)if(!1===o(n,r))return void Gv.set(n,!1);if(By||!Iy||function(e){return e.clipboardData&&""!==e.clipboardData.getData("text/plain")&&1===e.clipboardData.types.length}(r)){r.preventDefault();var i=r.clipboardData;null!=i&&n.insertData(i)}}},dragover:function(e,t,n){if(OC(n,e.target)){var r=Py.toSlateNode(n,e.target);Kh.isVoid(n,r)&&e.preventDefault()}},dragstart:function(e,t,n){var r=e;if(OC(n,r.target)&&!n.getConfig().readOnly){var o=Py.toSlateNode(n,r.target),i=Py.findPath(n,o);if(Kh.isVoid(n,o)||Kh.void(n,{at:i,voids:!0})){var a=Kh.range(n,i);jg.select(n,a)}var s=r.dataTransfer;if(null!=s)Py.getSelectedNodeByType(n,"table")||(t.isDraggingInternally=!0,n.setFragmentData(s))}},dragend:function(e,t,n){var r=e;n.getConfig().readOnly||t.isDraggingInternally&&OC(n,r.target)&&(t.isDraggingInternally=!1)},drop:function(e,t,n){var r=e,o=r.dataTransfer;if(!n.getConfig().readOnly&&OC(n,r.target)&&null!=o&&!(Iy&&By&&o.files.length>0)){r.preventDefault();var i=n.selection,a=Py.findEventRange(n,r);jg.select(n,a),t.isDraggingInternally&&(i&&jg.delete(n,{at:i}),t.isDraggingInternally=!1),n.insertData(o),n.isFocused()||n.focus()}}};function KC(e){if(YC(e)){for(;e&&YC(e);){e=XC(e).parent}return null!=e?e:null}return e.parentNode}function YC(e){return 11===e.nodeType}function XC(e,t){var n,r,o;const i=e;return null!==(n=i.parent)&&void 0!==n||(i.parent=null!=t?t:null),null!==(r=i.firstChildNode)&&void 0!==r||(i.firstChildNode=e.firstChild),null!==(o=i.lastChildNode)&&void 0!==o||(i.lastChildNode=e.lastChild),i}const ZC={createElement:function(e,t){return document.createElement(e,t)},createElementNS:function(e,t,n){return document.createElementNS(e,t,n)},createTextNode:function(e){return document.createTextNode(e)},createDocumentFragment:function(){return XC(document.createDocumentFragment())},createComment:function(e){return document.createComment(e)},insertBefore:function(e,t,n){if(YC(e)){let t=e;for(;t&&YC(t);){t=XC(t).parent}e=null!=t?t:e}YC(t)&&(t=XC(t,e)),n&&YC(n)&&(n=XC(n).firstChildNode),e.insertBefore(t,n)},removeChild:function(e,t){e.removeChild(t)},appendChild:function(e,t){YC(t)&&(t=XC(t,e)),e.appendChild(t)},parentNode:KC,nextSibling:function(e){var t;if(YC(e)){const n=XC(e),r=KC(n);if(r&&n.lastChildNode){const e=Array.from(r.childNodes),o=e.indexOf(n.lastChildNode);return null!==(t=e[o+1])&&void 0!==t?t:null}return null}return e.nextSibling},tagName:function(e){return e.tagName},setTextContent:function(e,t){e.textContent=t},getTextContent:function(e){return e.textContent},isElement:function(e){return 1===e.nodeType},isText:function(e){return 3===e.nodeType},isComment:function(e){return 8===e.nodeType},isDocumentFragment:YC};function JC(e,t,n,r,o){return{sel:e,data:t,children:n,text:r,elm:o,key:void 0===t?void 0:t.key}}const QC=Array.isArray;function eD(e){return"string"==typeof e||"number"==typeof e||e instanceof String||e instanceof Number}function tD(e){return void 0===e}function nD(e){return void 0!==e}const rD=JC("",{},[],void 0,void 0);function oD(e,t){var n,r;const o=e.key===t.key,i=(null===(n=e.data)||void 0===n?void 0:n.is)===(null===(r=t.data)||void 0===r?void 0:r.is),a=e.sel===t.sel,s=!(!e.sel&&e.sel===t.sel)||typeof e.text==typeof t.text;return a&&o&&i&&s}function iD(e,t,n){var r;const o={};for(let i=t;i<=n;++i){const t=null===(r=e[i])||void 0===r?void 0:r.key;void 0!==t&&(o[t]=i)}return o}const aD=["create","update","remove","destroy","pre","post"];function sD(e,t,n){const r={create:[],update:[],remove:[],destroy:[],pre:[],post:[]},o=ZC;for(const t of aD)for(const n of e){const e=n[t];void 0!==e&&r[t].push(e)}function i(e){const t=e.id?"#"+e.id:"",n=e.getAttribute("class"),r=n?"."+n.split(" ").join("."):"";return JC(o.tagName(e).toLowerCase()+t+r,{},[],void 0,e)}function a(e){return JC(void 0,{},[],void 0,e)}function s(e,t){return function(){if(0===--t){const t=o.parentNode(e);null!==t&&o.removeChild(t,e)}}}function u(e,t){var n,i;let a,s=e.data;if(void 0!==s){const t=null===(n=s.hook)||void 0===n?void 0:n.init;nD(t)&&(t(e),s=e.data)}const l=e.children,c=e.sel;if("!"===c)tD(e.text)&&(e.text=""),e.elm=o.createComment(e.text);else if(""===c)e.elm=o.createTextNode(e.text);else if(void 0!==c){const n=c.indexOf("#"),d=c.indexOf(".",n),f=n>0?n:c.length,p=d>0?d:c.length,h=-1!==n||-1!==d?c.slice(0,Math.min(f,p)):c,g=e.elm=nD(s)&&nD(a=s.ns)?o.createElementNS(a,h,s):o.createElement(h,s);for(f<p&&g.setAttribute("id",c.slice(f+1,p)),d>0&&g.setAttribute("class",c.slice(p+1).replace(/\./g," ")),a=0;a<r.create.length;++a)r.create[a](rD,e);if(!eD(e.text)||QC(l)&&0!==l.length||o.appendChild(g,o.createTextNode(e.text)),QC(l))for(a=0;a<l.length;++a){const e=l[a];null!=e&&o.appendChild(g,u(e,t))}const v=e.data.hook;nD(v)&&(null===(i=v.create)||void 0===i||i.call(v,rD,e),v.insert&&t.push(e))}else e.elm=o.createTextNode(e.text);return e.elm}function l(e,t,n,r,i,a){for(;r<=i;++r){const i=n[r];null!=i&&o.insertBefore(e,u(i,a),t)}}function c(e){var t,n;const o=e.data;if(void 0!==o){null===(n=null===(t=null==o?void 0:o.hook)||void 0===t?void 0:t.destroy)||void 0===n||n.call(t,e);for(let t=0;t<r.destroy.length;++t)r.destroy[t](e);if(void 0!==e.children)for(let t=0;t<e.children.length;++t){const n=e.children[t];null!=n&&"string"!=typeof n&&c(n)}}}function d(e,t,n,i){for(var a,u;n<=i;++n){let i,l;const f=t[n];if(null!=f)if(nD(f.sel)){c(f),i=r.remove.length+1,l=s(f.elm,i);for(let e=0;e<r.remove.length;++e)r.remove[e](f,l);const e=null===(u=null===(a=null==f?void 0:f.data)||void 0===a?void 0:a.hook)||void 0===u?void 0:u.remove;nD(e)?e(f,l):l()}else f.children?(c(f),d(e,f.children,0,f.children.length-1)):o.removeChild(e,f.elm)}}function f(e,t,n){var i,a,s,c,p,h,g,v;const m=null===(i=t.data)||void 0===i?void 0:i.hook;null===(a=null==m?void 0:m.prepatch)||void 0===a||a.call(m,e,t);const y=t.elm=e.elm;if(e===t)return;if(void 0!==t.data||nD(t.text)&&t.text!==e.text){null!==(s=t.data)&&void 0!==s||(t.data={}),null!==(c=e.data)&&void 0!==c||(e.data={});for(let n=0;n<r.update.length;++n)r.update[n](e,t);null===(g=null===(h=null===(p=t.data)||void 0===p?void 0:p.hook)||void 0===h?void 0:h.update)||void 0===g||g.call(h,e,t)}const b=e.children,E=t.children;tD(t.text)?nD(b)&&nD(E)?b!==E&&function(e,t,n,r){let i,a,s,c,p=0,h=0,g=t.length-1,v=t[0],m=t[g],y=n.length-1,b=n[0],E=n[y];for(;p<=g&&h<=y;)null==v?v=t[++p]:null==m?m=t[--g]:null==b?b=n[++h]:null==E?E=n[--y]:oD(v,b)?(f(v,b,r),v=t[++p],b=n[++h]):oD(m,E)?(f(m,E,r),m=t[--g],E=n[--y]):oD(v,E)?(f(v,E,r),o.insertBefore(e,v.elm,o.nextSibling(m.elm)),v=t[++p],E=n[--y]):oD(m,b)?(f(m,b,r),o.insertBefore(e,m.elm,v.elm),m=t[--g],b=n[++h]):(void 0===i&&(i=iD(t,p,g)),a=i[b.key],tD(a)?(o.insertBefore(e,u(b,r),v.elm),b=n[++h]):tD(i[E.key])?(o.insertBefore(e,u(E,r),o.nextSibling(m.elm)),E=n[--y]):(s=t[a],s.sel!==b.sel?o.insertBefore(e,u(b,r),v.elm):(f(s,b,r),t[a]=void 0,o.insertBefore(e,s.elm,v.elm)),b=n[++h]));h<=y&&(c=null==n[y+1]?null:n[y+1].elm,l(e,c,n,h,y,r)),p<=g&&d(e,t,p,g)}(y,b,E,n):nD(E)?(nD(e.text)&&o.setTextContent(y,""),l(y,null,E,0,E.length-1,n)):nD(b)?d(y,b,0,b.length-1):nD(e.text)&&o.setTextContent(y,""):e.text!==t.text&&(nD(b)&&d(y,b,0,b.length-1),o.setTextContent(y,t.text)),null===(v=null==m?void 0:m.postpatch)||void 0===v||v.call(m,e,t)}return function(e,t){let n,s,l;const c=[];for(n=0;n<r.pre.length;++n)r.pre[n]();for(!function(e,t){return e.isElement(t)}(o,e)?function(e,t){return e.isDocumentFragment(t)}(o,e)&&(e=a(e)):e=i(e),oD(e,t)?f(e,t,c):(s=e.elm,l=o.parentNode(s),u(t,c),null!==l&&(o.insertBefore(l,t.elm,o.nextSibling(s)),d(l,[e],0,0))),n=0;n<c.length;++n)c[n].data.hook.insert(c[n]);for(n=0;n<r.post.length;++n)r.post[n]();return t}}function uD(e,t,n){if(e.ns="http://www.w3.org/2000/svg","foreignObject"!==n&&void 0!==t)for(let e=0;e<t.length;++e){const n=t[e];if("string"==typeof n)continue;const r=n.data;void 0!==r&&uD(r,n.children,n.sel)}}function lD(e,t,n){let r,o,i,a={};if(void 0!==n?(null!==t&&(a=t),QC(n)?r=n:eD(n)?o=n.toString():n&&n.sel&&(r=[n])):null!=t&&(QC(t)?r=t:eD(t)?o=t.toString():t&&t.sel?r=[t]:a=t),void 0!==r)for(i=0;i<r.length;++i)eD(r[i])&&(r[i]=JC(void 0,void 0,void 0,r[i],void 0));return!e.startsWith("svg")||3!==e.length&&"."!==e[3]&&"#"!==e[3]||uD(a,r,e),JC(e,a,r,o,void 0)}function cD(e,t){let n;const r=t.elm;let o=e.data.attrs,i=t.data.attrs;if((o||i)&&o!==i){for(n in o=o||{},i=i||{},i){const e=i[n];o[n]!==e&&(!0===e?r.setAttribute(n,""):!1===e?r.removeAttribute(n):120!==n.charCodeAt(0)?r.setAttribute(n,e):58===n.charCodeAt(3)?r.setAttributeNS("http://www.w3.org/XML/1998/namespace",n,e):58===n.charCodeAt(5)?109===n.charCodeAt(1)?r.setAttributeNS("http://www.w3.org/2000/xmlns/",n,e):r.setAttributeNS("http://www.w3.org/1999/xlink",n,e):r.setAttribute(n,e))}for(n in o)n in i||r.removeAttribute(n)}}const dD={create:cD,update:cD};function fD(e,t){let n,r;const o=t.elm;let i=e.data.class,a=t.data.class;if((i||a)&&i!==a){for(r in i=i||{},a=a||{},i)i[r]&&!Object.prototype.hasOwnProperty.call(a,r)&&o.classList.remove(r);for(r in a)n=a[r],n!==i[r]&&o.classList[n?"add":"remove"](r)}}const pD={create:fD,update:fD},hD=/[A-Z]/g;function gD(e,t){const n=t.elm;let r,o=e.data.dataset,i=t.data.dataset;if(!o&&!i)return;if(o===i)return;o=o||{},i=i||{};const a=n.dataset;for(r in o)r in i||(a?r in a&&delete a[r]:n.removeAttribute("data-"+r.replace(hD,"-$&").toLowerCase()));for(r in i)o[r]!==i[r]&&(a?a[r]=i[r]:n.setAttribute("data-"+r.replace(hD,"-$&").toLowerCase(),i[r]))}const vD={create:gD,update:gD};function mD(e,t,n){if("function"==typeof e)e.call(t,n,t);else if("object"==typeof e)for(let r=0;r<e.length;r++)mD(e[r],t,n)}function yD(e,t){const n=e.type,r=t.data.on;r&&r[n]&&mD(r[n],t,e)}function bD(e,t){const n=e.data.on,r=e.listener,o=e.elm,i=t&&t.data.on,a=t&&t.elm;let s;if(n!==i){if(n&&r)if(i)for(s in n)i[s]||o.removeEventListener(s,r,!1);else for(s in n)o.removeEventListener(s,r,!1);if(i){const r=t.listener=e.listener||function e(t){yD(t,e.vnode)};if(r.vnode=t,n)for(s in i)n[s]||a.addEventListener(s,r,!1);else for(s in i)a.addEventListener(s,r,!1)}}}const ED={create:bD,update:bD,destroy:bD};function CD(e,t){let n,r,o;const i=t.elm;let a=e.data.props,s=t.data.props;if((a||s)&&a!==s)for(n in a=a||{},s=s||{},s)r=s[n],o=a[n],o===r||"value"===n&&i[n]===r||(i[n]=r)}const DD={create:CD,update:CD},wD="function"==typeof(null===window||void 0===window?void 0:window.requestAnimationFrame)?window.requestAnimationFrame.bind(window):setTimeout;let SD=!1;function AD(e,t,n){!function(e){wD(function(){wD(e)})}(function(){e[t]=n})}function xD(e,t){let n,r;const o=t.elm;let i=e.data.style,a=t.data.style;if(!i&&!a)return;if(i===a)return;i=i||{},a=a||{};const s="delayed"in i;for(r in i)r in a||("-"===r[0]&&"-"===r[1]?o.style.removeProperty(r):o.style[r]="");for(r in a)if(n=a[r],"delayed"===r&&a.delayed)for(const e in a.delayed)n=a.delayed[e],s&&n===i.delayed[e]||AD(o.style,e,n);else"remove"!==r&&n!==i[r]&&("-"===r[0]&&"-"===r[1]?o.style.setProperty(r,n):o.style[r]=n)}const OD={pre:function(){SD=!1},create:xD,update:xD,destroy:function(e){let t,n;const r=e.elm,o=e.data.style;if(o&&(t=o.destroy))for(n in t)r.style[n]=t[n]},remove:function(e,t){const n=e.data.style;if(!n||!n.remove)return void t();let r;SD||(e.elm.offsetLeft,SD=!0);const o=e.elm;let i=0;const a=n.remove;let s=0;const u=[];for(r in a)u.push(r),o.style[r]=a[r];const l=getComputedStyle(o)["transition-property"].split(", ");for(;i<l.length;++i)-1!==u.indexOf(l[i])&&s++;o.addEventListener("transitionend",function(e){e.target===o&&--s,0===s&&t()})}};function ND(e,t){for(const n of e)null!=n&&!1!==n&&""!==n&&(Array.isArray(n)?ND(n,t):"string"==typeof n||"number"==typeof n||"boolean"==typeof n?t.push(JC(void 0,void 0,void 0,String(n),void 0)):t.push(n));return t}function BD(e,t,...n){const r=ND(n,[]);return"function"==typeof e?e(t,r):1===r.length&&!r[0].sel&&r[0].text?lD(e,t,r[0].text):lD(e,t,r)}var TD=[];var kD,FD,ID={};function PD(e,t,n){return BD(n.isInline(e)?"span":"div",null,t)}function _D(e,t){var n,r=Py.findKey(t,e),o=t.isInline(e),i=Kh.isVoid(t,e),a=vy(e.type,r.id),s={id:a,key:r.id,"data-slate-node":"element","data-slate-inline":o},u=e.type,l=e.children,c=void 0===l?[]:l,d=function(e){return ID[e]||PD}(u);n=i?null:c.map(function(n,r){return jD(n,r,e,t)});var f=d(e,n,t);if(i){s["data-slate-void"]=!0;var p=o?"span":"div",h=ev(eg.texts(e),1),g=ev(h[0],1)[0],v=BD(p,{"data-slate-spacer":!0,style:{height:"0",color:"transparent",outline:"none",position:"absolute"}},jD(g,0,e,t));f=BD(p,{style:{position:"relative"}},f,v),_v.set(g,0),Lv.set(g,e)}return null==f.data&&(f.data={}),Object.assign(f.data,s),i||o||(f=function(e,t){var n=t;return TD.forEach(function(r){n=r(e,t)}),n}(e,f)),zm(function(){var t=Zm(a);null!=t&&(jv.set(r,t),Hv.set(e,t),Mv.set(t,e))}),f}function LD(e,t){return void 0===t&&(t=!1),BD("span",{"data-slate-string":!0},t?e+"\n":e)}function RD(e,t){return void 0===e&&(e=0),void 0===t&&(t=!1),BD("span",{"data-slate-zero-width":t?"n":"z","data-slate-length":e},"\ufeff",t?BD("br",null):null)}function MD(e,t,n){if(null==e.text)throw new Error("Current node is not slate Text ".concat(JSON.stringify(e)));var r=Py.findKey(n,e),o=n.getConfig().decorate;if(null==o)throw new Error("Can not get config.decorate");var i,a=Py.findPath(n,e),s=o([e,a]),u=Cg.decorations(e,s),l=u.map(function(r,o){var i=function(e,t,n,r,o){void 0===t&&(t=!1);var i=e.text,a=Py.findPath(o,n),s=og.parent(a);if(Kh.isEditor(r))throw new Error("Text node ".concat(JSON.stringify(n)," parent is Editor"));return o.isVoid(r)?RD(eg.string(r).length):""!==i||r.children[r.children.length-1]!==n||o.isInline(r)||""!==Kh.string(o,s)?""===i?RD():t&&"\n"===i.slice(-1)?LD(i,!0):LD(i):RD(0,!0)}(r,o===u.length-1,e,t,n);return i=function(e,t){var n=t;return TD.forEach(function(t){n=t(e,n)}),n}(r,i),BD("span",{"data-slate-leaf":!0},i)}),c=(i=r.id,"w-e-text-".concat(i)),d=BD("span",{"data-slate-node":"text",id:c,key:r.id},l);return zm(function(){var t=Zm(c);null!=t&&(jv.set(r,t),Hv.set(e,t),Mv.set(t,e))}),d}function jD(e,t,n,r){return _v.set(e,t),Lv.set(e,n),$h.isElement(e)?_D(e,r):MD(e,n,r)}var HD=function(){if(FD)return kD;FD=1;var e,t="[object Symbol]",n=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g,r=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,o="\\ud800-\\udfff",i="\\u0300-\\u036f\\ufe20-\\ufe23",a="\\u20d0-\\u20f0",s="\\u2700-\\u27bf",u="a-z\\xdf-\\xf6\\xf8-\\xff",l="A-Z\\xc0-\\xd6\\xd8-\\xde",c="\\ufe0e\\ufe0f",d="\\xac\\xb1\\xd7\\xf7\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf\\u2000-\\u206f \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",f="['’]",p="["+o+"]",h="["+d+"]",g="["+i+a+"]",v="\\d+",m="["+s+"]",b="["+u+"]",E="[^"+o+d+v+s+u+l+"]",C="\\ud83c[\\udffb-\\udfff]",D="[^"+o+"]",w="(?:\\ud83c[\\udde6-\\uddff]){2}",S="[\\ud800-\\udbff][\\udc00-\\udfff]",A="["+l+"]",x="\\u200d",O="(?:"+b+"|"+E+")",N="(?:"+A+"|"+E+")",B="(?:['’](?:d|ll|m|re|s|t|ve))?",T="(?:['’](?:D|LL|M|RE|S|T|VE))?",k="(?:"+g+"|"+C+")"+"?",F="["+c+"]?",I=F+k+("(?:"+x+"(?:"+[D,w,S].join("|")+")"+F+k+")*"),P="(?:"+[m,w,S].join("|")+")"+I,_="(?:"+[D+g+"?",g,w,S,p].join("|")+")",L=RegExp(f,"g"),R=RegExp(g,"g"),M=RegExp(C+"(?="+C+")|"+_+I,"g"),j=RegExp([A+"?"+b+"+"+B+"(?="+[h,A,"$"].join("|")+")",N+"+"+T+"(?="+[h,A+O,"$"].join("|")+")",A+"?"+O+"+"+B,A+"+"+T,v,P].join("|"),"g"),H=RegExp("["+x+o+i+a+c+"]"),z=/[a-z][A-Z]|[A-Z]{2,}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/,$="object"==typeof y&&y&&y.Object===Object&&y,U="object"==typeof self&&self&&self.Object===Object&&self,V=$||U||Function("return this")(),W=(e={"À":"A","Á":"A","Â":"A","Ã":"A","Ä":"A","Å":"A","à":"a","á":"a","â":"a","ã":"a","ä":"a","å":"a","Ç":"C","ç":"c","Ð":"D","ð":"d","È":"E","É":"E","Ê":"E","Ë":"E","è":"e","é":"e","ê":"e","ë":"e","Ì":"I","Í":"I","Î":"I","Ï":"I","ì":"i","í":"i","î":"i","ï":"i","Ñ":"N","ñ":"n","Ò":"O","Ó":"O","Ô":"O","Õ":"O","Ö":"O","Ø":"O","ò":"o","ó":"o","ô":"o","õ":"o","ö":"o","ø":"o","Ù":"U","Ú":"U","Û":"U","Ü":"U","ù":"u","ú":"u","û":"u","ü":"u","Ý":"Y","ý":"y","ÿ":"y","Æ":"Ae","æ":"ae","Þ":"Th","þ":"th","ß":"ss","Ā":"A","Ă":"A","Ą":"A","ā":"a","ă":"a","ą":"a","Ć":"C","Ĉ":"C","Ċ":"C","Č":"C","ć":"c","ĉ":"c","ċ":"c","č":"c","Ď":"D","Đ":"D","ď":"d","đ":"d","Ē":"E","Ĕ":"E","Ė":"E","Ę":"E","Ě":"E","ē":"e","ĕ":"e","ė":"e","ę":"e","ě":"e","Ĝ":"G","Ğ":"G","Ġ":"G","Ģ":"G","ĝ":"g","ğ":"g","ġ":"g","ģ":"g","Ĥ":"H","Ħ":"H","ĥ":"h","ħ":"h","Ĩ":"I","Ī":"I","Ĭ":"I","Į":"I","İ":"I","ĩ":"i","ī":"i","ĭ":"i","į":"i","ı":"i","Ĵ":"J","ĵ":"j","Ķ":"K","ķ":"k","ĸ":"k","Ĺ":"L","Ļ":"L","Ľ":"L","Ŀ":"L","Ł":"L","ĺ":"l","ļ":"l","ľ":"l","ŀ":"l","ł":"l","Ń":"N","Ņ":"N","Ň":"N","Ŋ":"N","ń":"n","ņ":"n","ň":"n","ŋ":"n","Ō":"O","Ŏ":"O","Ő":"O","ō":"o","ŏ":"o","ő":"o","Ŕ":"R","Ŗ":"R","Ř":"R","ŕ":"r","ŗ":"r","ř":"r","Ś":"S","Ŝ":"S","Ş":"S","Š":"S","ś":"s","ŝ":"s","ş":"s","š":"s","Ţ":"T","Ť":"T","Ŧ":"T","ţ":"t","ť":"t","ŧ":"t","Ũ":"U","Ū":"U","Ŭ":"U","Ů":"U","Ű":"U","Ų":"U","ũ":"u","ū":"u","ŭ":"u","ů":"u","ű":"u","ų":"u","Ŵ":"W","ŵ":"w","Ŷ":"Y","ŷ":"y","Ÿ":"Y","Ź":"Z","Ż":"Z","Ž":"Z","ź":"z","ż":"z","ž":"z","IJ":"IJ","ij":"ij","Œ":"Oe","œ":"oe","ʼn":"'n","ſ":"ss"},function(t){return null==e?void 0:e[t]});function G(e){return H.test(e)}function q(e){return G(e)?function(e){return e.match(M)||[]}(e):function(e){return e.split("")}(e)}var K=Object.prototype.toString,Y=V.Symbol,X=Y?Y.prototype:void 0,Z=X?X.toString:void 0;function J(e){if("string"==typeof e)return e;if(function(e){return"symbol"==typeof e||function(e){return!!e&&"object"==typeof e}(e)&&K.call(e)==t}(e))return Z?Z.call(e):"";var n=e+"";return"0"==n&&1/e==-1/0?"-0":n}function Q(e,t,n){var r=e.length;return n=void 0===n?r:n,!t&&n>=r?e:function(e,t,n){var r=-1,o=e.length;t<0&&(t=-t>o?0:o+t),(n=n>o?o:n)<0&&(n+=o),o=t>n?0:n-t>>>0,t>>>=0;for(var i=Array(o);++r<o;)i[r]=e[r+t];return i}(e,t,n)}function ee(e){return null==e?"":J(e)}var te,ne,re=(te=function(e,t,n){return t=t.toLowerCase(),e+(n?oe(ee(t).toLowerCase()):t)},function(e){return function(e,t,n){for(var r=-1,o=e?e.length:0;++r<o;)n=t(n,e[r],r,e);return n}(function(e,t){return e=ee(e),void 0===t?function(e){return z.test(e)}(e)?function(e){return e.match(j)||[]}(e):function(e){return e.match(n)||[]}(e):e.match(t)||[]}(function(e){return(e=ee(e))&&e.replace(r,W).replace(R,"")}(e).replace(L,"")),te,"")}),oe=(ne="toUpperCase",function(e){var t=G(e=ee(e))?q(e):void 0,n=t?t[0]:e.charAt(0),r=t?Q(t,1).join(""):e.slice(1);return n[ne]()+r});return kD=re}(),zD=b(HD);var $D=["props","attrs","style","dataset","on","hook"];function UD(e){var t=e.data,n=void 0===t?{}:t,r=e.children,o=void 0===r?[]:r;Object.keys(n).forEach(function(t){var r,o,i=n[t];if("key"!==t){if(!$D.includes(t)){if(t.startsWith("data-")){var a=t.slice(5);return a=zD(a),function(e,t){null==e.data&&(e.data={});var n=e.data;null==n.dataset&&(n.dataset={});Object.assign(n.dataset,t)}(e,((r={})[a]=i,r)),void delete n[t]}!function(e,t){null==e.data&&(e.data={});var n=e.data;null==n.props&&(n.props={});Object.assign(n.props,t)}(e,(o={},o[t]=i,o)),delete n[t]}}else e.key=i}),o.length>0&&o.forEach(function(e){"string"!=typeof e&&UD(e)})}function VD(e,t){var n,r,o=e.$scroll,i=(n=e.id,"w-e-textarea-".concat(n)),a=t.getConfig(),s=a.readOnly,u=a.autoFocus,l=function(e,t){return void 0===t&&(t=!1),lD("div#".concat(e),{props:{contentEditable:!t}})}(i,s),c=t.children||[];l.children=c.map(function(e,n){if(Iv.has(e)){var r=Iv.get(e);if(r){var o=ev(r,2),i=o[0],a=o[1];if(a)return i!==n&&(_v.set(e,n),Iv.set(e,[n,a])),a}}var s=jD(e,n,t,t);UD(s);var u=t.getConfig().skipCacheTypes,l=void 0===u?["list-item"]:u;return $h.isElement(e)&&l.includes(e.type)||Iv.set(e,[n,s]),s});var d=Tv.get(e);if(null==d&&(d=!0),d){var f=function(e){return im('<div\n id="'.concat(e,'"\n data-slate-editor\n data-slate-node="value"\n suppressContentEditableWarning\n role="textarea"\n spellCheck="true"\n autoCorrect="true"\n autoCapitalize="true"\n ></div>'))}(i);o.append(f),e.$textArea=f,r=f[0],(h=sD([pD,DD,OD,vD,ED,dD]))(r,l),Tv.set(e,!1),kv.set(e,h)}else{var p=Fv.get(e),h=kv.get(e);if(null==p||null==h)return;r=p.elm,h(p,l)}if(null!=r||null!=(r=Zm(i))){var g;if((d?u:t.isFocused())&&r.focus({preventScroll:!0}),d){var v=(g=r)&&g.ownerDocument&&g.ownerDocument.defaultView||null;v&&$v.set(t,v)}Rv.set(t,r),Hv.set(t,r),Mv.set(r,t),Fv.set(e,l)}}var WD=1,GD=function(){function e(e){var t=this;this.id=WD++,this.$textArea=null,this.$progressBar=im('<div class="w-e-progress-bar"></div>'),this.$maxLengthInfo=im('<div class="w-e-max-length-info"></div>'),this.isComposing=!1,this.isUpdatingSelection=!1,this.isDraggingInternally=!1,this.latestElement=null,this.showPlaceholder=!1,this.$placeholder=null,this.latestEditorSelection=null,this.onDOMSelectionChange=SC(function(){var e=t.editorInstance;!function(e,t){var n=e.isComposing,r=e.isUpdatingSelection,o=e.isDraggingInternally;if(!(t.getConfig().readOnly||n||r||o)){var i=Py.findDocumentOrShadowRoot(t),a=i.activeElement,s=Py.toDOMNode(t,t),u=i.getSelection();if(a!==s)return Uv.delete(t),void jg.deselect(t);if(e.latestElement=a,Uv.set(t,!0),!u)return jg.deselect(t);var l=u.anchorNode,c=u.focusNode,d=AC(t,l)||xC(t,l),f=AC(t,c)||xC(t,c);if(d&&f){var p=Py.toSlateRange(t,u,{exactMatch:!1,suppressThrow:!1});jg.select(t,p)}}}(t,e)},100);var n=im(e);if(0===n.length)throw new Error("Cannot find textarea DOM by selector '".concat(e,"'"));this.$box=n;var r=im('<div class="w-e-text-container"></div>');r.append(this.$progressBar),r.append(this.$maxLengthInfo),n.append(r);var o=im('<div class="w-e-scroll"></div>');r.append(o),this.$scroll=o,this.$textAreaContainer=r,zm(function(){var e=t.editorInstance,o=Py.getWindow(e);o.document.addEventListener("selectionchange",t.onDOMSelectionChange),e.on(pv,function(){o.document.removeEventListener("selectionchange",t.onDOMSelectionChange)}),r.on("click",function(){return e.hidePanelOrModal()}),e.on(hv,t.changeViewState.bind(t));var i=e.getConfig(),a=i.onChange,s=i.scroll;a&&e.on(hv,function(){return a(e)}),s||(n.css("position","relative"),r.addClass("no-scroll")),t.onFocusAndOnBlur(),e.on(hv,t.changeMaxLengthInfo.bind(t)),t.bindEvent()})}return Object.defineProperty(e.prototype,"editorInstance",{get:function(){var e=Cv.get(this);if(null==e)throw new Error("Can not get editor instance");return e},enumerable:!1,configurable:!0}),e.prototype.bindEvent=function(){var e=this,t=this.$textArea,n=this.$scroll,r=this.editorInstance;null!=t&&(cv(qC,function(n,o){t.on(o,function(t){n(t,e,r)})}),r.getConfig().scroll&&(n.css("overflow-y","auto"),n.on("scroll",SC(function(){r.emit("scroll")},100))))},e.prototype.onFocusAndOnBlur=function(){var e=this,t=this.editorInstance,n=t.getConfig(),r=n.onBlur,o=n.onFocus;this.latestEditorSelection=t.selection,t.on(hv,function(){null==e.latestEditorSelection&&null!=t.selection?setTimeout(function(){return o&&o(t)}):null!=e.latestEditorSelection&&null==t.selection&&setTimeout(function(){return r&&r(t)}),e.latestEditorSelection=t.selection})},e.prototype.changeMaxLengthInfo=function(){var e=this.editorInstance,t=e.getConfig().maxLength;if(t){var n=t-Py.getLeftLengthOfMaxLength(e);this.$maxLengthInfo[0].innerHTML="".concat(n,"/").concat(t)}},e.prototype.changeProgress=function(e){var t=this.$progressBar;t.css("width","".concat(e,"%")),e>=100&&setTimeout(function(){t.hide(),t.css("width","0"),t.show()},1e3)},e.prototype.changeViewState=function(){var e=this,t=this.editorInstance;VD(this,t),function(e,t){var n,r=t.getConfig().placeholder;if(r){var o=t.isEmpty();if(o&&!e.showPlaceholder&&!e.isComposing){if(null==e.$placeholder){var i=im('<div class="w-e-text-placeholder">'.concat(r,"</div>"));e.$textAreaContainer.append(i),e.$placeholder=i}return e.$placeholder.show(),void(e.showPlaceholder=!0)}!o&&e.showPlaceholder&&(null===(n=e.$placeholder)||void 0===n||n.hide(),e.showPlaceholder=!1)}}(this,t),zm(function(){_C(e,t)})},e.prototype.destroy=function(){this.$textAreaContainer.remove()},e}();function qD(e,t,n,r){if(_v.set(e,t),Lv.set(e,n),$h.isElement(e)){var o=e.children;if((void 0===o?[]:o).forEach(function(t,n){return qD(t,n,e,r)}),Kh.isVoid(r,e)){var i=ev(eg.texts(e),1),a=ev(i[0],1)[0];_v.set(a,0),Lv.set(a,e)}}}var KD={en:"Textarea height < 300px. This may cause modal and hoverbar position error",zh:"编辑区域高度 < 300px 这可能会导致 modal hoverbar 定位异常"};function YD(e){var t=e.selector,n=void 0===t?"":t,r=e.config,o=void 0===r?{}:r,i=e.content,a=e.html,s=e.plugins,u=void 0===s?[]:s,l=function(e){return[Gb,Nb,qv,xb,eE,Wb,qb,Vg].reduce(function(e,t){return t(e)},e)}((()=>{var e={children:[],operations:[],selection:null,marks:null,isInline:()=>!1,isVoid:()=>!1,onChange:()=>{},apply:t=>{for(var n of Kh.pathRefs(e))ig.transform(n,t);for(var r of Kh.pointRefs(e))lg.transform(r,t);for(var o of Kh.rangeRefs(e))pg.transform(o,t);var i,a,s=oh.get(e)||[],u=ih.get(e)||new Set,l=e=>{if(e){var t=e.join(",");a.has(t)||(a.add(t),i.push(e))}};if(og.operationCanTransformPath(t))for(var c of(i=[],a=new Set,s))l(og.transform(c,t));else i=s,a=u;var d=e.getDirtyPaths(t);for(var f of d)l(f);oh.set(e,i),ih.set(e,a),jg.transform(e,t),e.operations.push(t),Kh.normalize(e),"set_selection"===t.type&&(e.marks=null),ah.get(e)||(ah.set(e,!0),Promise.resolve().then(()=>{ah.set(e,!1),e.onChange(),e.operations=[]}))},addMark:(t,n)=>{var{selection:r}=e;if(r)if(fg.isExpanded(r))jg.setNodes(e,{[t]:n},{match:Cg.isText,split:!0});else{var o=fh(fh({},Kh.marks(e)||{}),{},{[t]:n});e.marks=o,ah.get(e)||e.onChange()}},deleteBackward:t=>{var{selection:n}=e;n&&fg.isCollapsed(n)&&jg.delete(e,{unit:t,reverse:!0})},deleteForward:t=>{var{selection:n}=e;n&&fg.isCollapsed(n)&&jg.delete(e,{unit:t})},deleteFragment:t=>{var{selection:n}=e;n&&fg.isExpanded(n)&&jg.delete(e,{reverse:"backward"===t})},getFragment:()=>{var{selection:t}=e;return t?eg.fragment(e,t):[]},insertBreak:()=>{jg.splitNodes(e,{always:!0})},insertSoftBreak:()=>{jg.splitNodes(e,{always:!0})},insertFragment:t=>{jg.insertFragment(e,t)},insertNode:t=>{jg.insertNodes(e,t)},insertText:t=>{var{selection:n,marks:r}=e;if(n){if(r){var o=fh({text:t},r);jg.insertNodes(e,o)}else jg.insertText(e,t);e.marks=null}},normalizeNode:t=>{var[n,r]=t;if(!Cg.isText(n))if($h.isElement(n)&&0===n.children.length)jg.insertNodes(e,{text:""},{at:r.concat(0),voids:!0});else for(var o=!Kh.isEditor(n)&&$h.isElement(n)&&(e.isInline(n)||0===n.children.length||Cg.isText(n.children[0])||e.isInline(n.children[0])),i=0,a=0;a<n.children.length;a++,i++){var s=eg.get(e,r);if(!Cg.isText(s)){var u=n.children[a],l=s.children[i-1],c=a===n.children.length-1;(Cg.isText(u)||$h.isElement(u)&&e.isInline(u))!==o?(jg.removeNodes(e,{at:r.concat(i),voids:!0}),i--):$h.isElement(u)?e.isInline(u)&&(null!=l&&Cg.isText(l)?c&&(jg.insertNodes(e,{text:""},{at:r.concat(i+1),voids:!0}),i++):(jg.insertNodes(e,{text:""},{at:r.concat(i),voids:!0}),i++)):null!=l&&Cg.isText(l)&&(Cg.equals(u,l,{loose:!0})?(jg.mergeNodes(e,{at:r.concat(i),voids:!0}),i--):""===l.text?(jg.removeNodes(e,{at:r.concat(i-1),voids:!0}),i--):""===u.text&&(jg.removeNodes(e,{at:r.concat(i),voids:!0}),i--))}}},removeMark:t=>{var{selection:n}=e;if(n)if(fg.isExpanded(n))jg.unsetNodes(e,t,{match:Cg.isText,split:!0});else{var r=fh({},Kh.marks(e)||{});delete r[t],e.marks=r,ah.get(e)||e.onChange()}},getDirtyPaths:e=>{switch(e.type){case"insert_text":case"remove_text":case"set_node":var{path:t}=e;return og.levels(t);case"insert_node":var{node:n,path:r}=e,o=og.levels(r),i=Cg.isText(n)?[]:Array.from(eg.nodes(n),e=>{var[,t]=e;return r.concat(t)});return[...o,...i];case"merge_node":var{path:a}=e;return[...og.ancestors(a),og.previous(a)];case"move_node":var{path:s,newPath:u}=e;if(og.equals(s,u))return[];var l=[],c=[];for(var d of og.ancestors(s)){var f=og.transform(d,e);l.push(f)}for(var p of og.ancestors(u)){var h=og.transform(p,e);c.push(h)}var g=c[c.length-1],v=u[u.length-1],m=g.concat(v);return[...l,...c,m];case"remove_node":var{path:y}=e;return[...og.ancestors(y)];case"split_node":var{path:b}=e;return[...og.levels(b),og.next(b)];default:return[]}}};return e})());if(n&&function(e,t){return hy(e,"data-w-e-textarea",t)}(l,n))throw new Error("Repeated create editor by selector '".concat(n,"'"));var c=function(e){void 0===e&&(e={});var t=uv(dv),n={},r=e.MENU_CONF,o=void 0===r?{}:r;return cv(t,function(e,t){n[t]=Yg(Yg({},e),o[t]||{})}),delete e.MENU_CONF,Yg({scroll:!0,readOnly:!1,autoFocus:!0,decorate:function(){return[]},maxLength:0,MENU_CONF:n,hoverbarKeys:{},customAlert:function(e,t){window.alert("".concat(t,":\n").concat(e))}},e)}(o);Bv.set(l,c);var d=c.hoverbarKeys,f=void 0===d?{}:d;if(u.forEach(function(e){l=e(l)}),function(e,t){var n=t.html,r=t.content;null!=n?e.children=gy(e,n):r&&r.length&&(e.children=r),0===e.children.length&&(e.children=[{type:"paragraph",children:[{text:""}]}])}(l,{html:a,content:i}),n){var p=new GD(n);Ev.set(l,p),Cv.set(p,l),p.changeViewState(),zm(function(){var e=p.$scroll;null!=e&&e.height()<300&&console.warn("".concat(KD.zh,"\n").concat(KD.en),{element:e,height:e.height()})});var h=void 0;Object.keys(f).length>0&&(h=new DC,Sv.set(h,l),Av.set(l,h)),l.on(hv,function(){l.hidePanelOrModal()}),l.on(gv,function(){l.hidePanelOrModal()})}else l.children.forEach(function(e,t){return qD(e,t,l,l)});var g=c.onCreated,v=c.onDestroyed;return g&&l.on(fv,function(){return g(l)}),v&&l.on(pv,function(){return v(l)}),zm(function(){return l.emit("created")}),l}var XD=function(){function e(e,t){var n=this;this.$toolbar=im('<div class="w-e-bar w-e-bar-show w-e-toolbar"></div>'),this.menus={},this.toolbarItems=[],this.config={},this.lngListen=function(){},this.changeToolbarState=nE(function(){n.toolbarItems.forEach(function(e){e.changeMenuState()})},200),this.config=t;var r=im(e);if(0===r.length)throw new Error("Cannot find toolbar DOM by selector '".concat(e,"'"));this.$box=r;var o=this.$toolbar;o.on("mousedown",function(e){return e.preventDefault()},{passive:!1}),r.append(o),zm(function(){n.initToolbar(),n.lngListen=ZE(function(){return n.initToolbar()}),n.getEditorInstance().on(hv,n.changeToolbarState)})}return e.prototype.getMenus=function(){return this.menus},e.prototype.getConfig=function(){return this.config},e.prototype.initToolbar=function(){this.menus={};var e=this.$toolbar;null==e||e.empty(),this.registerItems(),this.changeToolbarState()},e.prototype.registerItems=function(){var e=this,t="",n=this.$toolbar,r=this.config,o=r.toolbarKeys,i=void 0===o?[]:o,a=r.insertKeys,s=void 0===a?{index:0,keys:[]}:a,u=r.excludeKeys,l=void 0===u?[]:u,c=uv(i);s.keys.length>0&&("string"==typeof s.keys&&(s.keys=[s.keys]),s.keys.forEach(function(e,t){c.splice(s.index+t,0,e)}));var d=c.filter(function(e){var t="string"==typeof e?e:e.key;return!l.includes(t)}),f=d.length;d.forEach(function(r,o){if("|"===r){if(0===o)return;if(o+1===f)return;if("|"===t)return;var i=tC();return n.append(i),void(t=r)}if("string"==typeof r)return e.registerSingleItem(r,e),void(t=r);e.registerGroup(r),t="group"})},e.prototype.registerGroup=function(e){var t=this,n=this.$toolbar,r=function(e){return new gC(e)}(e),o=e.menuKeys,i=void 0===o?[]:o,a=this.config.excludeKeys,s=void 0===a?[]:a;i.forEach(function(e){s.includes(e)||t.registerSingleItem(e,r)}),n.append(r.$elem)},e.prototype.registerSingleItem=function(e,t){var n=this.getEditorInstance(),r=t instanceof gC,o=this.menus,i=o[e];if(null==i){var a=yv[e];if(null==a)throw new Error("Not found menu item factory by key '".concat(e,"'"));if("function"!=typeof a)throw new Error("Menu item factory (key='".concat(e,"') is not a function"));i=a(),o[e]=i}else console.warn("Duplicated toolbar menu key '".concat(e,"'\n重复注册了菜单栏 menu '").concat(e,"'"));var s=n.getMenuConfig(e);s&&void 0!==s.iconSvg&&(i.iconSvg=s.iconSvg);var u=yC(e,i,r);(this.toolbarItems.push(u),xv.set(u,n),r)?t.appendBarItem(u):t.$toolbar.append(u.$elem)},e.prototype.getEditorInstance=function(){var e=Dv.get(this);if(null==e)throw new Error("Can not get editor instance");return e},e.prototype.destroy=function(){var e;this.$toolbar.remove(),null===(e=this.lngListen)||void 0===e||e.call(this),this.menus={},this.toolbarItems=[]},e}();function ZD(e,t){if(null==e)throw new Error("Cannot create toolbar, because editor is null");var n=t.selector,r=t.config,o=void 0===r?{}:r;if(function(e,t){return hy(e,"data-w-e-toolbar",t)}(e,n))throw new Error("Repeated create toolbar by selector '".concat(n,"'"));var i=Yg({toolbarKeys:[],excludeKeys:[],insertKeys:{index:0,keys:[]},modalAppendToBody:!1},o||{}),a=new XD(n,i);return Dv.set(a,e),wv.set(e,a),a}var JD,QD,ew,tw,nw,rw={exports:{}},ow={};function iw(){if(ew)return ow;ew=1,Object.defineProperty(ow,"__esModule",{value:!0}),ow.justErrorsLogger=ow.debugLogger=void 0;const e=function(){if(QD)return JD;function e(e){return e<10?`0${e}`:e.toString()}return QD=1,JD=function(){const t=new Date;return`${e(t.getHours())}:${e(t.getMinutes())}:${e(t.getSeconds())}`}}(),t={debug:()=>{},warn:()=>{},error:function(){for(var t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];return console.error(`[Uppy] [${e()}]`,...n)}};ow.justErrorsLogger=t;const n={debug:function(){for(var t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];return console.debug(`[Uppy] [${e()}]`,...n)},warn:function(){for(var t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];return console.warn(`[Uppy] [${e()}]`,...n)},error:function(){for(var t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];return console.error(`[Uppy] [${e()}]`,...n)}};return ow.debugLogger=n,ow}function aw(){if(nw)return tw;nw=1;return tw={nanoid:(e=21)=>{let t="",n=0|e;for(;n--;)t+="useandom-26T198340PX75pxJACKVERYMINDBUSHWOLF_GQZbfghjklqvwyzrict"[64*Math.random()|0];return t},customAlphabet:(e,t=21)=>(n=t)=>{let r="",o=0|n;for(;o--;)r+=e[Math.random()*e.length|0];return r}},tw}var sw,uw,lw,cw,dw,fw,pw,hw,gw,vw,mw,yw,bw,Ew,Cw,Dw,ww,Sw,Aw,xw,Ow,Nw,Bw,Tw,kw,Fw,Iw,Pw,_w,Lw,Rw,Mw={};function jw(){return uw?sw:(uw=1,sw=function(e){if("number"!=typeof e||isNaN(e))throw new TypeError("Expected a number, got "+typeof e);var t=e<0,n=["B","KB","MB","GB","TB","PB","EB","ZB","YB"];if(t&&(e=-e),e<1)return(t?"-":"")+e+" B";var r=Math.min(Math.floor(Math.log(e)/Math.log(1024)),n.length-1);e=Number(e/Math.pow(1024,r));var o=n[r];return e>=10||e%1==0?(t?"-":"")+e.toFixed(0)+" "+o:(t?"-":"")+e.toFixed(1)+" "+o})}function Hw(){if(cw)return lw;function e(e,t){this.text=e=e||"",this.hasWild=~e.indexOf("*"),this.separator=t,this.parts=e.split(t)}return cw=1,e.prototype.match=function(e){var t,n,r=!0,o=this.parts,i=o.length;if("string"==typeof e||e instanceof String)if(this.hasWild||this.text==e){for(n=(e||"").split(this.separator),t=0;r&&t<i;t++)"*"!==o[t]&&(r=t<n.length&&o[t]===n[t]);r=r&&n}else r=!1;else if("function"==typeof e.splice)for(r=[],t=e.length;t--;)this.match(e[t])&&(r[r.length]=e[t]);else if("object"==typeof e)for(var a in r={},e)this.match(a)&&(r[a]=e[a]);return r},lw=function(t,n,r){var o=new e(t,r||/[\/\.]/);return void 0!==n?o.match(n):o},lw}function zw(){if(pw)return Mw;pw=1,Object.defineProperty(Mw,"__esModule",{value:!0}),Mw.defaultOptions=Mw.RestrictionError=Mw.Restricter=void 0;const e=jw(),t=function(){if(fw)return dw;fw=1;var e=Hw(),t=/[\/\+\.]/;return dw=function(n,r){function o(r){var o=e(r,n,t);return o&&o.length>=2}return r?o(r.split(";")[0]):o}}();Mw.defaultOptions={maxFileSize:null,minFileSize:null,maxTotalFileSize:null,maxNumberOfFiles:null,minNumberOfFiles:null,allowedFileTypes:null,requiredMetaFields:[]};class n extends Error{constructor(){super(...arguments),this.isRestriction=!0}}Mw.RestrictionError=n,"undefined"==typeof AggregateError&&(globalThis.AggregateError=class extends Error{constructor(e,t){super(t),this.errors=e}});return Mw.Restricter=class{constructor(e,t){this.i18n=t,this.getOpts=()=>{const t=e();if(null!=t.restrictions.allowedFileTypes&&!Array.isArray(t.restrictions.allowedFileTypes))throw new TypeError("`restrictions.allowedFileTypes` must be an array");return t}}validate(r,o){const{maxFileSize:i,minFileSize:a,maxTotalFileSize:s,maxNumberOfFiles:u,allowedFileTypes:l}=this.getOpts().restrictions;if(u){const e=o.filter(e=>!e.isGhost);if(e.length+1>u)throw new n(`${this.i18n("youCanOnlyUploadX",{smart_count:u})}`)}if(l){if(!l.some(e=>e.includes("/")?!!r.type&&t(r.type.replace(/;.*?$/,""),e):!("."!==e[0]||!r.extension)&&r.extension.toLowerCase()===e.slice(1).toLowerCase())){const e=l.join(", ");throw new n(this.i18n("youCanOnlyUploadFileTypes",{types:e}))}}if(s&&null!=r.size){const t=o.reduce((e,t)=>e+t.size,r.size);if(t>s)throw new n(this.i18n("exceedsSize",{size:e(s),file:r.name}))}if(i&&null!=r.size&&r.size>i)throw new n(this.i18n("exceedsSize",{size:e(i),file:r.name}));if(a&&null!=r.size&&r.size<a)throw new n(this.i18n("inferiorSize",{size:e(a)}))}validateMinNumberOfFiles(e){const{minNumberOfFiles:t}=this.getOpts().restrictions;if(Object.keys(e).length<t)throw new n(this.i18n("youHaveToAtLeastSelectX",{smart_count:t}))}getMissingRequiredMetaFields(e){const t=new n(this.i18n("missingRequiredMetaFieldOnFile",{fileName:e.name})),{requiredMetaFields:r}=this.getOpts().restrictions,o=Object.prototype.hasOwnProperty,i=[];for(const t of r)o.call(e.meta,t)&&""!==e.meta[t]||i.push(t);return{missingFields:i,error:t}}},Mw}function $w(){if(gw)return hw;return gw=1,hw=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)}}function Uw(){if(mw)return vw;function e(e,t){if(!Object.prototype.hasOwnProperty.call(e,t))throw new TypeError("attempted to use private field on non-instance");return e}mw=1;var t=0;function n(e){return"__private_"+t+++"_"+e}const r=$w();function o(e,t,n){const r=[];return e.forEach(e=>"string"!=typeof e?r.push(e):t[Symbol.split](e).forEach((e,t,o)=>{""!==e&&r.push(e),t<o.length-1&&r.push(n)})),r}
|
|
7
|
+
*/function rf(e){return"[object Object]"===Object.prototype.toString.call(e)}function nf(e){var t,r;return!1!==rf(e)&&(void 0===(t=e.constructor)||!1!==rf(r=t.prototype)&&!1!==r.hasOwnProperty("isPrototypeOf"))}function of(e){for(var t=arguments.length,r=Array(t>1?t-1:0),n=1;n<t;n++)r[n-1]=arguments[n];throw Error("[Immer] minified error nr: "+e+(r.length?" "+r.map(function(e){return"'"+e+"'"}).join(","):"")+". Find the full error at: https://bit.ly/3cXEKWf")}function af(e){return!!e&&!!e[qf]}function sf(e){var t;return!!e&&(function(e){if(!e||"object"!=typeof e)return!1;var t=Object.getPrototypeOf(e);if(null===t)return!0;var r=Object.hasOwnProperty.call(t,"constructor")&&t.constructor;return r===Object||"function"==typeof r&&Function.toString.call(r)===Wf}(e)||Array.isArray(e)||!!e[Uf]||!!(null===(t=e.constructor)||void 0===t?void 0:t[Uf])||hf(e)||ff(e))}function uf(e,t,r){void 0===r&&(r=!1),0===lf(e)?(r?Object.keys:Gf)(e).forEach(function(n){r&&"symbol"==typeof n||t(n,e[n],e)}):e.forEach(function(r,n){return t(n,r,e)})}function lf(e){var t=e[qf];return t?t.i>3?t.i-4:t.i:Array.isArray(e)?1:hf(e)?2:ff(e)?3:0}function cf(e,t){return 2===lf(e)?e.has(t):Object.prototype.hasOwnProperty.call(e,t)}function df(e,t,r){var n=lf(e);2===n?e.set(t,r):3===n?e.add(r):e[t]=r}function hf(e){return jf&&e instanceof Map}function ff(e){return Hf&&e instanceof Set}function pf(e){return e.o||e.t}function gf(e){if(Array.isArray(e))return Array.prototype.slice.call(e);var t=Yf(e);delete t[qf];for(var r=Gf(t),n=0;n<r.length;n++){var o=r[n],i=t[o];!1===i.writable&&(i.writable=!0,i.configurable=!0),(i.get||i.set)&&(t[o]={configurable:!0,writable:!0,enumerable:i.enumerable,value:e[o]})}return Object.create(Object.getPrototypeOf(e),t)}function mf(e,t){return void 0===t&&(t=!1),yf(e)||af(e)||!sf(e)||(lf(e)>1&&(e.set=e.add=e.clear=e.delete=vf),Object.freeze(e),t&&uf(e,function(e,t){return mf(t,!0)},!0)),e}function vf(){of(2)}function yf(e){return null==e||"object"!=typeof e||Object.isFrozen(e)}function bf(e){var t=Kf[e];return t||of(18,e),t}function Df(){return _f}function Cf(e,t){t&&(bf("Patches"),e.u=[],e.s=[],e.v=t)}function wf(e){Ef(e),e.p.forEach(xf),e.p=null}function Ef(e){e===_f&&(_f=e.l)}function Af(e){return _f={p:[],l:_f,h:e,m:!0,_:0}}function xf(e){var t=e[qf];0===t.i||1===t.i?t.j():t.g=!0}function Bf(e,t){t._=t.p.length;var r=t.p[0],n=void 0!==e&&e!==r;return t.h.O||bf("ES5").S(t,e,n),n?(r[qf].P&&(wf(t),of(4)),sf(e)&&(e=Sf(t,e),t.l||kf(t,e)),t.u&&bf("Patches").M(r[qf].t,e,t.u,t.s)):e=Sf(t,r,[]),wf(t),t.u&&t.v(t.u,t.s),e!==$f?e:void 0}function Sf(e,t,r){if(yf(t))return t;var n=t[qf];if(!n)return uf(t,function(o,i){return Ff(e,n,t,o,i,r)},!0),t;if(n.A!==e)return t;if(!n.P)return kf(e,n.t,!0),n.t;if(!n.I){n.I=!0,n.A._--;var o=4===n.i||5===n.i?n.o=gf(n.k):n.o,i=o,a=!1;3===n.i&&(i=new Set(o),o.clear(),a=!0),uf(i,function(t,i){return Ff(e,n,o,t,i,r,a)}),kf(e,o,!1),r&&e.u&&bf("Patches").N(n,r,e.u,e.s)}return n.o}function Ff(e,t,r,n,o,i,a){if(af(o)){var s=Sf(e,o,i&&t&&3!==t.i&&!cf(t.R,n)?i.concat(n):void 0);if(df(r,n,s),!af(s))return;e.m=!1}else a&&r.add(o);if(sf(o)&&!yf(o)){if(!e.h.D&&e._<1)return;Sf(e,o),t&&t.A.l||kf(e,o)}}function kf(e,t,r){void 0===r&&(r=!1),!e.l&&e.h.D&&e.m&&mf(t,r)}function Of(e,t){var r=e[qf];return(r?pf(r):e)[t]}function Tf(e,t){if(t in e)for(var r=Object.getPrototypeOf(e);r;){var n=Object.getOwnPropertyDescriptor(r,t);if(n)return n;r=Object.getPrototypeOf(r)}}function Nf(e){e.P||(e.P=!0,e.l&&Nf(e.l))}function Pf(e){e.o||(e.o=gf(e.t))}function Mf(e,t,r){var n=hf(t)?bf("MapSet").F(t,r):ff(t)?bf("MapSet").T(t,r):e.O?function(e,t){var r=Array.isArray(e),n={i:r?1:0,A:t?t.A:Df(),P:!1,I:!1,R:{},l:t,t:e,k:null,o:null,j:null,C:!1},o=n,i=Xf;r&&(o=[n],i=Zf);var a=Proxy.revocable(o,i),s=a.revoke,u=a.proxy;return n.k=u,n.j=s,u}(t,r):bf("ES5").J(t,r);return(r?r.A:Df()).p.push(n),n}function If(e){return af(e)||of(22,e),function e(t){if(!sf(t))return t;var r,n=t[qf],o=lf(t);if(n){if(!n.P&&(n.i<4||!bf("ES5").K(n)))return n.t;n.I=!0,r=Rf(t,o),n.I=!1}else r=Rf(t,o);return uf(r,function(t,o){n&&function(e,t){return 2===lf(e)?e.get(t):e[t]}(n.t,t)===o||df(r,t,e(o))}),3===o?new Set(r):r}(e)}function Rf(e,t){switch(t){case 2:return new Map(e);case 3:return Array.from(e)}return gf(e)}var Lf,_f,zf="undefined"!=typeof Symbol&&"symbol"==typeof Symbol("x"),jf="undefined"!=typeof Map,Hf="undefined"!=typeof Set,Vf="undefined"!=typeof Proxy&&void 0!==Proxy.revocable&&"undefined"!=typeof Reflect,$f=zf?Symbol.for("immer-nothing"):((Lf={})["immer-nothing"]=!0,Lf),Uf=zf?Symbol.for("immer-draftable"):"__$immer_draftable",qf=zf?Symbol.for("immer-state"):"__$immer_state",Wf=""+Object.prototype.constructor,Gf="undefined"!=typeof Reflect&&Reflect.ownKeys?Reflect.ownKeys:void 0!==Object.getOwnPropertySymbols?function(e){return Object.getOwnPropertyNames(e).concat(Object.getOwnPropertySymbols(e))}:Object.getOwnPropertyNames,Yf=Object.getOwnPropertyDescriptors||function(e){var t={};return Gf(e).forEach(function(r){t[r]=Object.getOwnPropertyDescriptor(e,r)}),t},Kf={},Xf={get:function(e,t){if(t===qf)return e;var r=pf(e);if(!cf(r,t))return function(e,t,r){var n,o=Tf(t,r);return o?"value"in o?o.value:null===(n=o.get)||void 0===n?void 0:n.call(e.k):void 0}(e,r,t);var n=r[t];return e.I||!sf(n)?n:n===Of(e.t,t)?(Pf(e),e.o[t]=Mf(e.A.h,n,e)):n},has:function(e,t){return t in pf(e)},ownKeys:function(e){return Reflect.ownKeys(pf(e))},set:function(e,t,r){var n=Tf(pf(e),t);if(null==n?void 0:n.set)return n.set.call(e.k,r),!0;if(!e.P){var o=Of(pf(e),t),i=null==o?void 0:o[qf];if(i&&i.t===r)return e.o[t]=r,e.R[t]=!1,!0;if(function(e,t){return e===t?0!==e||1/e==1/t:e!=e&&t!=t}(r,o)&&(void 0!==r||cf(e.t,t)))return!0;Pf(e),Nf(e)}return e.o[t]===r&&(void 0!==r||t in e.o)||Number.isNaN(r)&&Number.isNaN(e.o[t])||(e.o[t]=r,e.R[t]=!0),!0},deleteProperty:function(e,t){return void 0!==Of(e.t,t)||t in e.t?(e.R[t]=!1,Pf(e),Nf(e)):delete e.R[t],e.o&&delete e.o[t],!0},getOwnPropertyDescriptor:function(e,t){var r=pf(e),n=Reflect.getOwnPropertyDescriptor(r,t);return n?{writable:!0,configurable:1!==e.i||"length"!==t,enumerable:n.enumerable,value:r[t]}:n},defineProperty:function(){of(11)},getPrototypeOf:function(e){return Object.getPrototypeOf(e.t)},setPrototypeOf:function(){of(12)}},Zf={};uf(Xf,function(e,t){Zf[e]=function(){return arguments[0]=arguments[0][0],t.apply(this,arguments)}}),Zf.deleteProperty=function(e,t){return Zf.set.call(this,e,t,void 0)},Zf.set=function(e,t,r){return Xf.set.call(this,e[0],t,r,e[0])};var Jf=function(){function e(e){var t=this;this.O=Vf,this.D=!0,this.produce=function(e,r,n){if("function"==typeof e&&"function"!=typeof r){var o=r;r=e;var i=t;return function(e){var t=this;void 0===e&&(e=o);for(var n=arguments.length,a=Array(n>1?n-1:0),s=1;s<n;s++)a[s-1]=arguments[s];return i.produce(e,function(e){var n;return(n=r).call.apply(n,[t,e].concat(a))})}}var a;if("function"!=typeof r&&of(6),void 0!==n&&"function"!=typeof n&&of(7),sf(e)){var s=Af(t),u=Mf(t,e,void 0),l=!0;try{a=r(u),l=!1}finally{l?wf(s):Ef(s)}return"undefined"!=typeof Promise&&a instanceof Promise?a.then(function(e){return Cf(s,n),Bf(e,s)},function(e){throw wf(s),e}):(Cf(s,n),Bf(a,s))}if(!e||"object"!=typeof e){if(void 0===(a=r(e))&&(a=e),a===$f&&(a=void 0),t.D&&mf(a,!0),n){var c=[],d=[];bf("Patches").M(e,a,c,d),n(c,d)}return a}of(21,e)},this.produceWithPatches=function(e,r){if("function"==typeof e)return function(r){for(var n=arguments.length,o=Array(n>1?n-1:0),i=1;i<n;i++)o[i-1]=arguments[i];return t.produceWithPatches(r,function(t){return e.apply(void 0,[t].concat(o))})};var n,o,i=t.produce(e,r,function(e,t){n=e,o=t});return"undefined"!=typeof Promise&&i instanceof Promise?i.then(function(e){return[e,n,o]}):[i,n,o]},"boolean"==typeof(null==e?void 0:e.useProxies)&&this.setUseProxies(e.useProxies),"boolean"==typeof(null==e?void 0:e.autoFreeze)&&this.setAutoFreeze(e.autoFreeze)}var t=e.prototype;return t.createDraft=function(e){sf(e)||of(8),af(e)&&(e=If(e));var t=Af(this),r=Mf(this,e,void 0);return r[qf].C=!0,Ef(t),r},t.finishDraft=function(e,t){var r=(e&&e[qf]).A;return Cf(r,t),Bf(void 0,r)},t.setAutoFreeze=function(e){this.D=e},t.setUseProxies=function(e){e&&!Vf&&of(20),this.O=e},t.applyPatches=function(e,t){var r;for(r=t.length-1;r>=0;r--){var n=t[r];if(0===n.path.length&&"replace"===n.op){e=n.value;break}}r>-1&&(t=t.slice(r+1));var o=bf("Patches").$;return af(e)?o(e,t):this.produce(e,function(e){return o(e,t)})},e}(),Qf=new Jf,ep=Qf.produce;Qf.produceWithPatches.bind(Qf),Qf.setAutoFreeze.bind(Qf),Qf.setUseProxies.bind(Qf),Qf.applyPatches.bind(Qf);var tp=Qf.createDraft.bind(Qf),rp=Qf.finishDraft.bind(Qf);function np(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var op=new WeakMap,ip=new WeakMap,ap=new WeakMap,sp=new WeakMap,up=new WeakMap,lp=new WeakMap,cp=new WeakMap;function dp(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),r.push.apply(r,n)}return r}function hp(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?dp(Object(r),!0).forEach(function(t){np(e,t,r[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):dp(Object(r)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))})}return e}function fp(e,t){if(null==e)return{};var r,n,o=function(e,t){if(null==e)return{};var r,n,o={},i=Object.keys(e);for(n=0;n<i.length;n++)r=i[n],t.indexOf(r)>=0||(o[r]=e[r]);return o}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(n=0;n<i.length;n++)r=i[n],t.indexOf(r)>=0||Object.prototype.propertyIsEnumerable.call(e,r)&&(o[r]=e[r])}return o}var pp,gp=function(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1],r=!t,n=t?Cp(e):e,o=pp.None,i=pp.None,a=0,s=null;for(var u of n){var l=u.codePointAt(0);if(!l)break;var c=Pp(u,l);if([o,i]=r?[i,c]:[c,o],Mp(o,pp.ZWJ)&&Mp(i,pp.ExtPict)&&!_p(r?e.substring(0,a):e.substring(0,e.length-a)))break;if(Mp(o,pp.RI)&&Mp(i,pp.RI)&&!(s=null!==s?!s:!!r||jp(e.substring(0,e.length-a))))break;if(o!==pp.None&&i!==pp.None&&Rp(o,i))break;a+=u.length}return a||1},mp=/\s/,vp=/[\u0021-\u0023\u0025-\u002A\u002C-\u002F\u003A\u003B\u003F\u0040\u005B-\u005D\u005F\u007B\u007D\u00A1\u00A7\u00AB\u00B6\u00B7\u00BB\u00BF\u037E\u0387\u055A-\u055F\u0589\u058A\u05BE\u05C0\u05C3\u05C6\u05F3\u05F4\u0609\u060A\u060C\u060D\u061B\u061E\u061F\u066A-\u066D\u06D4\u0700-\u070D\u07F7-\u07F9\u0830-\u083E\u085E\u0964\u0965\u0970\u0AF0\u0DF4\u0E4F\u0E5A\u0E5B\u0F04-\u0F12\u0F14\u0F3A-\u0F3D\u0F85\u0FD0-\u0FD4\u0FD9\u0FDA\u104A-\u104F\u10FB\u1360-\u1368\u1400\u166D\u166E\u169B\u169C\u16EB-\u16ED\u1735\u1736\u17D4-\u17D6\u17D8-\u17DA\u1800-\u180A\u1944\u1945\u1A1E\u1A1F\u1AA0-\u1AA6\u1AA8-\u1AAD\u1B5A-\u1B60\u1BFC-\u1BFF\u1C3B-\u1C3F\u1C7E\u1C7F\u1CC0-\u1CC7\u1CD3\u2010-\u2027\u2030-\u2043\u2045-\u2051\u2053-\u205E\u207D\u207E\u208D\u208E\u2329\u232A\u2768-\u2775\u27C5\u27C6\u27E6-\u27EF\u2983-\u2998\u29D8-\u29DB\u29FC\u29FD\u2CF9-\u2CFC\u2CFE\u2CFF\u2D70\u2E00-\u2E2E\u2E30-\u2E3B\u3001-\u3003\u3008-\u3011\u3014-\u301F\u3030\u303D\u30A0\u30FB\uA4FE\uA4FF\uA60D-\uA60F\uA673\uA67E\uA6F2-\uA6F7\uA874-\uA877\uA8CE\uA8CF\uA8F8-\uA8FA\uA92E\uA92F\uA95F\uA9C1-\uA9CD\uA9DE\uA9DF\uAA5C-\uAA5F\uAADE\uAADF\uAAF0\uAAF1\uABEB\uFD3E\uFD3F\uFE10-\uFE19\uFE30-\uFE52\uFE54-\uFE61\uFE63\uFE68\uFE6A\uFE6B\uFF01-\uFF03\uFF05-\uFF0A\uFF0C-\uFF0F\uFF1A\uFF1B\uFF1F\uFF20\uFF3B-\uFF3D\uFF3F\uFF5B\uFF5D\uFF5F-\uFF65]/,yp=/['\u2018\u2019]/,bp=(e,t,r)=>{if(r){var n=e.length-t;return[e.slice(n,e.length),e.slice(0,n)]}return[e.slice(0,t),e.slice(t)]},Dp=function e(t,r){var n=arguments.length>2&&void 0!==arguments[2]&&arguments[2];if(mp.test(t))return!1;if(yp.test(t)){var o=gp(r,n),[i,a]=bp(r,o,n);if(e(i,a,n))return!0}return!vp.test(t)},Cp=function*(e){for(var t=e.length-1,r=0;r<e.length;r++){var n=e.charAt(t-r);if(Ep(n.charCodeAt(0))){var o=e.charAt(t-r-1);if(wp(o.charCodeAt(0))){yield o+n,r++;continue}}yield n}},wp=e=>e>=55296&&e<=56319,Ep=e=>e>=56320&&e<=57343;!function(e){e[e.None=0]="None",e[e.Extend=1]="Extend",e[e.ZWJ=2]="ZWJ",e[e.RI=4]="RI",e[e.Prepend=8]="Prepend",e[e.SpacingMark=16]="SpacingMark",e[e.L=32]="L",e[e.V=64]="V",e[e.T=128]="T",e[e.LV=256]="LV",e[e.LVT=512]="LVT",e[e.ExtPict=1024]="ExtPict",e[e.Any=2048]="Any"}(pp||(pp={}));var Ap=/^(?:[\u0300-\u036F\u0483-\u0489\u0591-\u05BD\u05BF\u05C1\u05C2\u05C4\u05C5\u05C7\u0610-\u061A\u064B-\u065F\u0670\u06D6-\u06DC\u06DF-\u06E4\u06E7\u06E8\u06EA-\u06ED\u0711\u0730-\u074A\u07A6-\u07B0\u07EB-\u07F3\u07FD\u0816-\u0819\u081B-\u0823\u0825-\u0827\u0829-\u082D\u0859-\u085B\u08D3-\u08E1\u08E3-\u0902\u093A\u093C\u0941-\u0948\u094D\u0951-\u0957\u0962\u0963\u0981\u09BC\u09BE\u09C1-\u09C4\u09CD\u09D7\u09E2\u09E3\u09FE\u0A01\u0A02\u0A3C\u0A41\u0A42\u0A47\u0A48\u0A4B-\u0A4D\u0A51\u0A70\u0A71\u0A75\u0A81\u0A82\u0ABC\u0AC1-\u0AC5\u0AC7\u0AC8\u0ACD\u0AE2\u0AE3\u0AFA-\u0AFF\u0B01\u0B3C\u0B3E\u0B3F\u0B41-\u0B44\u0B4D\u0B55-\u0B57\u0B62\u0B63\u0B82\u0BBE\u0BC0\u0BCD\u0BD7\u0C00\u0C04\u0C3E-\u0C40\u0C46-\u0C48\u0C4A-\u0C4D\u0C55\u0C56\u0C62\u0C63\u0C81\u0CBC\u0CBF\u0CC2\u0CC6\u0CCC\u0CCD\u0CD5\u0CD6\u0CE2\u0CE3\u0D00\u0D01\u0D3B\u0D3C\u0D3E\u0D41-\u0D44\u0D4D\u0D57\u0D62\u0D63\u0D81\u0DCA\u0DCF\u0DD2-\u0DD4\u0DD6\u0DDF\u0E31\u0E34-\u0E3A\u0E47-\u0E4E\u0EB1\u0EB4-\u0EBC\u0EC8-\u0ECD\u0F18\u0F19\u0F35\u0F37\u0F39\u0F71-\u0F7E\u0F80-\u0F84\u0F86\u0F87\u0F8D-\u0F97\u0F99-\u0FBC\u0FC6\u102D-\u1030\u1032-\u1037\u1039\u103A\u103D\u103E\u1058\u1059\u105E-\u1060\u1071-\u1074\u1082\u1085\u1086\u108D\u109D\u135D-\u135F\u1712-\u1714\u1732-\u1734\u1752\u1753\u1772\u1773\u17B4\u17B5\u17B7-\u17BD\u17C6\u17C9-\u17D3\u17DD\u180B-\u180D\u1885\u1886\u18A9\u1920-\u1922\u1927\u1928\u1932\u1939-\u193B\u1A17\u1A18\u1A1B\u1A56\u1A58-\u1A5E\u1A60\u1A62\u1A65-\u1A6C\u1A73-\u1A7C\u1A7F\u1AB0-\u1AC0\u1B00-\u1B03\u1B34-\u1B3A\u1B3C\u1B42\u1B6B-\u1B73\u1B80\u1B81\u1BA2-\u1BA5\u1BA8\u1BA9\u1BAB-\u1BAD\u1BE6\u1BE8\u1BE9\u1BED\u1BEF-\u1BF1\u1C2C-\u1C33\u1C36\u1C37\u1CD0-\u1CD2\u1CD4-\u1CE0\u1CE2-\u1CE8\u1CED\u1CF4\u1CF8\u1CF9\u1DC0-\u1DF9\u1DFB-\u1DFF\u200C\u20D0-\u20F0\u2CEF-\u2CF1\u2D7F\u2DE0-\u2DFF\u302A-\u302F\u3099\u309A\uA66F-\uA672\uA674-\uA67D\uA69E\uA69F\uA6F0\uA6F1\uA802\uA806\uA80B\uA825\uA826\uA82C\uA8C4\uA8C5\uA8E0-\uA8F1\uA8FF\uA926-\uA92D\uA947-\uA951\uA980-\uA982\uA9B3\uA9B6-\uA9B9\uA9BC\uA9BD\uA9E5\uAA29-\uAA2E\uAA31\uAA32\uAA35\uAA36\uAA43\uAA4C\uAA7C\uAAB0\uAAB2-\uAAB4\uAAB7\uAAB8\uAABE\uAABF\uAAC1\uAAEC\uAAED\uAAF6\uABE5\uABE8\uABED\uFB1E\uFE00-\uFE0F\uFE20-\uFE2F\uFF9E\uFF9F]|\uD800[\uDDFD\uDEE0\uDF76-\uDF7A]|\uD802[\uDE01-\uDE03\uDE05\uDE06\uDE0C-\uDE0F\uDE38-\uDE3A\uDE3F\uDEE5\uDEE6]|\uD803[\uDD24-\uDD27\uDEAB\uDEAC\uDF46-\uDF50]|\uD804[\uDC01\uDC38-\uDC46\uDC7F-\uDC81\uDCB3-\uDCB6\uDCB9\uDCBA\uDD00-\uDD02\uDD27-\uDD2B\uDD2D-\uDD34\uDD73\uDD80\uDD81\uDDB6-\uDDBE\uDDC9-\uDDCC\uDDCF\uDE2F-\uDE31\uDE34\uDE36\uDE37\uDE3E\uDEDF\uDEE3-\uDEEA\uDF00\uDF01\uDF3B\uDF3C\uDF3E\uDF40\uDF57\uDF66-\uDF6C\uDF70-\uDF74]|\uD805[\uDC38-\uDC3F\uDC42-\uDC44\uDC46\uDC5E\uDCB0\uDCB3-\uDCB8\uDCBA\uDCBD\uDCBF\uDCC0\uDCC2\uDCC3\uDDAF\uDDB2-\uDDB5\uDDBC\uDDBD\uDDBF\uDDC0\uDDDC\uDDDD\uDE33-\uDE3A\uDE3D\uDE3F\uDE40\uDEAB\uDEAD\uDEB0-\uDEB5\uDEB7\uDF1D-\uDF1F\uDF22-\uDF25\uDF27-\uDF2B]|\uD806[\uDC2F-\uDC37\uDC39\uDC3A\uDD30\uDD3B\uDD3C\uDD3E\uDD43\uDDD4-\uDDD7\uDDDA\uDDDB\uDDE0\uDE01-\uDE0A\uDE33-\uDE38\uDE3B-\uDE3E\uDE47\uDE51-\uDE56\uDE59-\uDE5B\uDE8A-\uDE96\uDE98\uDE99]|\uD807[\uDC30-\uDC36\uDC38-\uDC3D\uDC3F\uDC92-\uDCA7\uDCAA-\uDCB0\uDCB2\uDCB3\uDCB5\uDCB6\uDD31-\uDD36\uDD3A\uDD3C\uDD3D\uDD3F-\uDD45\uDD47\uDD90\uDD91\uDD95\uDD97\uDEF3\uDEF4]|\uD81A[\uDEF0-\uDEF4\uDF30-\uDF36]|\uD81B[\uDF4F\uDF8F-\uDF92\uDFE4]|\uD82F[\uDC9D\uDC9E]|\uD834[\uDD65\uDD67-\uDD69\uDD6E-\uDD72\uDD7B-\uDD82\uDD85-\uDD8B\uDDAA-\uDDAD\uDE42-\uDE44]|\uD836[\uDE00-\uDE36\uDE3B-\uDE6C\uDE75\uDE84\uDE9B-\uDE9F\uDEA1-\uDEAF]|\uD838[\uDC00-\uDC06\uDC08-\uDC18\uDC1B-\uDC21\uDC23\uDC24\uDC26-\uDC2A\uDD30-\uDD36\uDEEC-\uDEEF]|\uD83A[\uDCD0-\uDCD6\uDD44-\uDD4A]|\uD83C[\uDFFB-\uDFFF]|\uDB40[\uDC20-\uDC7F\uDD00-\uDDEF])$/,xp=/^(?:[\u0600-\u0605\u06DD\u070F\u0890\u0891\u08E2\u0D4E]|\uD804[\uDCBD\uDCCD\uDDC2\uDDC3]|\uD806[\uDD3F\uDD41\uDE3A\uDE84-\uDE89]|\uD807\uDD46)$/,Bp=/^(?:[\u0903\u093B\u093E-\u0940\u0949-\u094C\u094E\u094F\u0982\u0983\u09BF\u09C0\u09C7\u09C8\u09CB\u09CC\u0A03\u0A3E-\u0A40\u0A83\u0ABE-\u0AC0\u0AC9\u0ACB\u0ACC\u0B02\u0B03\u0B40\u0B47\u0B48\u0B4B\u0B4C\u0BBF\u0BC1\u0BC2\u0BC6-\u0BC8\u0BCA-\u0BCC\u0C01-\u0C03\u0C41-\u0C44\u0C82\u0C83\u0CBE\u0CC0\u0CC1\u0CC3\u0CC4\u0CC7\u0CC8\u0CCA\u0CCB\u0D02\u0D03\u0D3F\u0D40\u0D46-\u0D48\u0D4A-\u0D4C\u0D82\u0D83\u0DD0\u0DD1\u0DD8-\u0DDE\u0DF2\u0DF3\u0E33\u0EB3\u0F3E\u0F3F\u0F7F\u1031\u103B\u103C\u1056\u1057\u1084\u1715\u1734\u17B6\u17BE-\u17C5\u17C7\u17C8\u1923-\u1926\u1929-\u192B\u1930\u1931\u1933-\u1938\u1A19\u1A1A\u1A55\u1A57\u1A6D-\u1A72\u1B04\u1B3B\u1B3D-\u1B41\u1B43\u1B44\u1B82\u1BA1\u1BA6\u1BA7\u1BAA\u1BE7\u1BEA-\u1BEC\u1BEE\u1BF2\u1BF3\u1C24-\u1C2B\u1C34\u1C35\u1CE1\u1CF7\uA823\uA824\uA827\uA880\uA881\uA8B4-\uA8C3\uA952\uA953\uA983\uA9B4\uA9B5\uA9BA\uA9BB\uA9BE-\uA9C0\uAA2F\uAA30\uAA33\uAA34\uAA4D\uAAEB\uAAEE\uAAEF\uAAF5\uABE3\uABE4\uABE6\uABE7\uABE9\uABEA\uABEC]|\uD804[\uDC00\uDC02\uDC82\uDCB0-\uDCB2\uDCB7\uDCB8\uDD2C\uDD45\uDD46\uDD82\uDDB3-\uDDB5\uDDBF\uDDC0\uDDCE\uDE2C-\uDE2E\uDE32\uDE33\uDE35\uDEE0-\uDEE2\uDF02\uDF03\uDF3F\uDF41-\uDF44\uDF47\uDF48\uDF4B-\uDF4D\uDF62\uDF63]|\uD805[\uDC35-\uDC37\uDC40\uDC41\uDC45\uDCB1\uDCB2\uDCB9\uDCBB\uDCBC\uDCBE\uDCC1\uDDB0\uDDB1\uDDB8-\uDDBB\uDDBE\uDE30-\uDE32\uDE3B\uDE3C\uDE3E\uDEAC\uDEAE\uDEAF\uDEB6\uDF26]|\uD806[\uDC2C-\uDC2E\uDC38\uDD31-\uDD35\uDD37\uDD38\uDD3D\uDD40\uDD42\uDDD1-\uDDD3\uDDDC-\uDDDF\uDDE4\uDE39\uDE57\uDE58\uDE97]|\uD807[\uDC2F\uDC3E\uDCA9\uDCB1\uDCB4\uDD8A-\uDD8E\uDD93\uDD94\uDD96\uDEF5\uDEF6]|\uD81B[\uDF51-\uDF87\uDFF0\uDFF1]|\uD834[\uDD66\uDD6D])$/,Sp=/^[\u1100-\u115F\uA960-\uA97C]$/,Fp=/^[\u1160-\u11A7\uD7B0-\uD7C6]$/,kp=/^[\u11A8-\u11FF\uD7CB-\uD7FB]$/,Op=/^[\uAC00\uAC1C\uAC38\uAC54\uAC70\uAC8C\uACA8\uACC4\uACE0\uACFC\uAD18\uAD34\uAD50\uAD6C\uAD88\uADA4\uADC0\uADDC\uADF8\uAE14\uAE30\uAE4C\uAE68\uAE84\uAEA0\uAEBC\uAED8\uAEF4\uAF10\uAF2C\uAF48\uAF64\uAF80\uAF9C\uAFB8\uAFD4\uAFF0\uB00C\uB028\uB044\uB060\uB07C\uB098\uB0B4\uB0D0\uB0EC\uB108\uB124\uB140\uB15C\uB178\uB194\uB1B0\uB1CC\uB1E8\uB204\uB220\uB23C\uB258\uB274\uB290\uB2AC\uB2C8\uB2E4\uB300\uB31C\uB338\uB354\uB370\uB38C\uB3A8\uB3C4\uB3E0\uB3FC\uB418\uB434\uB450\uB46C\uB488\uB4A4\uB4C0\uB4DC\uB4F8\uB514\uB530\uB54C\uB568\uB584\uB5A0\uB5BC\uB5D8\uB5F4\uB610\uB62C\uB648\uB664\uB680\uB69C\uB6B8\uB6D4\uB6F0\uB70C\uB728\uB744\uB760\uB77C\uB798\uB7B4\uB7D0\uB7EC\uB808\uB824\uB840\uB85C\uB878\uB894\uB8B0\uB8CC\uB8E8\uB904\uB920\uB93C\uB958\uB974\uB990\uB9AC\uB9C8\uB9E4\uBA00\uBA1C\uBA38\uBA54\uBA70\uBA8C\uBAA8\uBAC4\uBAE0\uBAFC\uBB18\uBB34\uBB50\uBB6C\uBB88\uBBA4\uBBC0\uBBDC\uBBF8\uBC14\uBC30\uBC4C\uBC68\uBC84\uBCA0\uBCBC\uBCD8\uBCF4\uBD10\uBD2C\uBD48\uBD64\uBD80\uBD9C\uBDB8\uBDD4\uBDF0\uBE0C\uBE28\uBE44\uBE60\uBE7C\uBE98\uBEB4\uBED0\uBEEC\uBF08\uBF24\uBF40\uBF5C\uBF78\uBF94\uBFB0\uBFCC\uBFE8\uC004\uC020\uC03C\uC058\uC074\uC090\uC0AC\uC0C8\uC0E4\uC100\uC11C\uC138\uC154\uC170\uC18C\uC1A8\uC1C4\uC1E0\uC1FC\uC218\uC234\uC250\uC26C\uC288\uC2A4\uC2C0\uC2DC\uC2F8\uC314\uC330\uC34C\uC368\uC384\uC3A0\uC3BC\uC3D8\uC3F4\uC410\uC42C\uC448\uC464\uC480\uC49C\uC4B8\uC4D4\uC4F0\uC50C\uC528\uC544\uC560\uC57C\uC598\uC5B4\uC5D0\uC5EC\uC608\uC624\uC640\uC65C\uC678\uC694\uC6B0\uC6CC\uC6E8\uC704\uC720\uC73C\uC758\uC774\uC790\uC7AC\uC7C8\uC7E4\uC800\uC81C\uC838\uC854\uC870\uC88C\uC8A8\uC8C4\uC8E0\uC8FC\uC918\uC934\uC950\uC96C\uC988\uC9A4\uC9C0\uC9DC\uC9F8\uCA14\uCA30\uCA4C\uCA68\uCA84\uCAA0\uCABC\uCAD8\uCAF4\uCB10\uCB2C\uCB48\uCB64\uCB80\uCB9C\uCBB8\uCBD4\uCBF0\uCC0C\uCC28\uCC44\uCC60\uCC7C\uCC98\uCCB4\uCCD0\uCCEC\uCD08\uCD24\uCD40\uCD5C\uCD78\uCD94\uCDB0\uCDCC\uCDE8\uCE04\uCE20\uCE3C\uCE58\uCE74\uCE90\uCEAC\uCEC8\uCEE4\uCF00\uCF1C\uCF38\uCF54\uCF70\uCF8C\uCFA8\uCFC4\uCFE0\uCFFC\uD018\uD034\uD050\uD06C\uD088\uD0A4\uD0C0\uD0DC\uD0F8\uD114\uD130\uD14C\uD168\uD184\uD1A0\uD1BC\uD1D8\uD1F4\uD210\uD22C\uD248\uD264\uD280\uD29C\uD2B8\uD2D4\uD2F0\uD30C\uD328\uD344\uD360\uD37C\uD398\uD3B4\uD3D0\uD3EC\uD408\uD424\uD440\uD45C\uD478\uD494\uD4B0\uD4CC\uD4E8\uD504\uD520\uD53C\uD558\uD574\uD590\uD5AC\uD5C8\uD5E4\uD600\uD61C\uD638\uD654\uD670\uD68C\uD6A8\uD6C4\uD6E0\uD6FC\uD718\uD734\uD750\uD76C\uD788]$/,Tp=/^[\uAC01-\uAC1B\uAC1D-\uAC37\uAC39-\uAC53\uAC55-\uAC6F\uAC71-\uAC8B\uAC8D-\uACA7\uACA9-\uACC3\uACC5-\uACDF\uACE1-\uACFB\uACFD-\uAD17\uAD19-\uAD33\uAD35-\uAD4F\uAD51-\uAD6B\uAD6D-\uAD87\uAD89-\uADA3\uADA5-\uADBF\uADC1-\uADDB\uADDD-\uADF7\uADF9-\uAE13\uAE15-\uAE2F\uAE31-\uAE4B\uAE4D-\uAE67\uAE69-\uAE83\uAE85-\uAE9F\uAEA1-\uAEBB\uAEBD-\uAED7\uAED9-\uAEF3\uAEF5-\uAF0F\uAF11-\uAF2B\uAF2D-\uAF47\uAF49-\uAF63\uAF65-\uAF7F\uAF81-\uAF9B\uAF9D-\uAFB7\uAFB9-\uAFD3\uAFD5-\uAFEF\uAFF1-\uB00B\uB00D-\uB027\uB029-\uB043\uB045-\uB05F\uB061-\uB07B\uB07D-\uB097\uB099-\uB0B3\uB0B5-\uB0CF\uB0D1-\uB0EB\uB0ED-\uB107\uB109-\uB123\uB125-\uB13F\uB141-\uB15B\uB15D-\uB177\uB179-\uB193\uB195-\uB1AF\uB1B1-\uB1CB\uB1CD-\uB1E7\uB1E9-\uB203\uB205-\uB21F\uB221-\uB23B\uB23D-\uB257\uB259-\uB273\uB275-\uB28F\uB291-\uB2AB\uB2AD-\uB2C7\uB2C9-\uB2E3\uB2E5-\uB2FF\uB301-\uB31B\uB31D-\uB337\uB339-\uB353\uB355-\uB36F\uB371-\uB38B\uB38D-\uB3A7\uB3A9-\uB3C3\uB3C5-\uB3DF\uB3E1-\uB3FB\uB3FD-\uB417\uB419-\uB433\uB435-\uB44F\uB451-\uB46B\uB46D-\uB487\uB489-\uB4A3\uB4A5-\uB4BF\uB4C1-\uB4DB\uB4DD-\uB4F7\uB4F9-\uB513\uB515-\uB52F\uB531-\uB54B\uB54D-\uB567\uB569-\uB583\uB585-\uB59F\uB5A1-\uB5BB\uB5BD-\uB5D7\uB5D9-\uB5F3\uB5F5-\uB60F\uB611-\uB62B\uB62D-\uB647\uB649-\uB663\uB665-\uB67F\uB681-\uB69B\uB69D-\uB6B7\uB6B9-\uB6D3\uB6D5-\uB6EF\uB6F1-\uB70B\uB70D-\uB727\uB729-\uB743\uB745-\uB75F\uB761-\uB77B\uB77D-\uB797\uB799-\uB7B3\uB7B5-\uB7CF\uB7D1-\uB7EB\uB7ED-\uB807\uB809-\uB823\uB825-\uB83F\uB841-\uB85B\uB85D-\uB877\uB879-\uB893\uB895-\uB8AF\uB8B1-\uB8CB\uB8CD-\uB8E7\uB8E9-\uB903\uB905-\uB91F\uB921-\uB93B\uB93D-\uB957\uB959-\uB973\uB975-\uB98F\uB991-\uB9AB\uB9AD-\uB9C7\uB9C9-\uB9E3\uB9E5-\uB9FF\uBA01-\uBA1B\uBA1D-\uBA37\uBA39-\uBA53\uBA55-\uBA6F\uBA71-\uBA8B\uBA8D-\uBAA7\uBAA9-\uBAC3\uBAC5-\uBADF\uBAE1-\uBAFB\uBAFD-\uBB17\uBB19-\uBB33\uBB35-\uBB4F\uBB51-\uBB6B\uBB6D-\uBB87\uBB89-\uBBA3\uBBA5-\uBBBF\uBBC1-\uBBDB\uBBDD-\uBBF7\uBBF9-\uBC13\uBC15-\uBC2F\uBC31-\uBC4B\uBC4D-\uBC67\uBC69-\uBC83\uBC85-\uBC9F\uBCA1-\uBCBB\uBCBD-\uBCD7\uBCD9-\uBCF3\uBCF5-\uBD0F\uBD11-\uBD2B\uBD2D-\uBD47\uBD49-\uBD63\uBD65-\uBD7F\uBD81-\uBD9B\uBD9D-\uBDB7\uBDB9-\uBDD3\uBDD5-\uBDEF\uBDF1-\uBE0B\uBE0D-\uBE27\uBE29-\uBE43\uBE45-\uBE5F\uBE61-\uBE7B\uBE7D-\uBE97\uBE99-\uBEB3\uBEB5-\uBECF\uBED1-\uBEEB\uBEED-\uBF07\uBF09-\uBF23\uBF25-\uBF3F\uBF41-\uBF5B\uBF5D-\uBF77\uBF79-\uBF93\uBF95-\uBFAF\uBFB1-\uBFCB\uBFCD-\uBFE7\uBFE9-\uC003\uC005-\uC01F\uC021-\uC03B\uC03D-\uC057\uC059-\uC073\uC075-\uC08F\uC091-\uC0AB\uC0AD-\uC0C7\uC0C9-\uC0E3\uC0E5-\uC0FF\uC101-\uC11B\uC11D-\uC137\uC139-\uC153\uC155-\uC16F\uC171-\uC18B\uC18D-\uC1A7\uC1A9-\uC1C3\uC1C5-\uC1DF\uC1E1-\uC1FB\uC1FD-\uC217\uC219-\uC233\uC235-\uC24F\uC251-\uC26B\uC26D-\uC287\uC289-\uC2A3\uC2A5-\uC2BF\uC2C1-\uC2DB\uC2DD-\uC2F7\uC2F9-\uC313\uC315-\uC32F\uC331-\uC34B\uC34D-\uC367\uC369-\uC383\uC385-\uC39F\uC3A1-\uC3BB\uC3BD-\uC3D7\uC3D9-\uC3F3\uC3F5-\uC40F\uC411-\uC42B\uC42D-\uC447\uC449-\uC463\uC465-\uC47F\uC481-\uC49B\uC49D-\uC4B7\uC4B9-\uC4D3\uC4D5-\uC4EF\uC4F1-\uC50B\uC50D-\uC527\uC529-\uC543\uC545-\uC55F\uC561-\uC57B\uC57D-\uC597\uC599-\uC5B3\uC5B5-\uC5CF\uC5D1-\uC5EB\uC5ED-\uC607\uC609-\uC623\uC625-\uC63F\uC641-\uC65B\uC65D-\uC677\uC679-\uC693\uC695-\uC6AF\uC6B1-\uC6CB\uC6CD-\uC6E7\uC6E9-\uC703\uC705-\uC71F\uC721-\uC73B\uC73D-\uC757\uC759-\uC773\uC775-\uC78F\uC791-\uC7AB\uC7AD-\uC7C7\uC7C9-\uC7E3\uC7E5-\uC7FF\uC801-\uC81B\uC81D-\uC837\uC839-\uC853\uC855-\uC86F\uC871-\uC88B\uC88D-\uC8A7\uC8A9-\uC8C3\uC8C5-\uC8DF\uC8E1-\uC8FB\uC8FD-\uC917\uC919-\uC933\uC935-\uC94F\uC951-\uC96B\uC96D-\uC987\uC989-\uC9A3\uC9A5-\uC9BF\uC9C1-\uC9DB\uC9DD-\uC9F7\uC9F9-\uCA13\uCA15-\uCA2F\uCA31-\uCA4B\uCA4D-\uCA67\uCA69-\uCA83\uCA85-\uCA9F\uCAA1-\uCABB\uCABD-\uCAD7\uCAD9-\uCAF3\uCAF5-\uCB0F\uCB11-\uCB2B\uCB2D-\uCB47\uCB49-\uCB63\uCB65-\uCB7F\uCB81-\uCB9B\uCB9D-\uCBB7\uCBB9-\uCBD3\uCBD5-\uCBEF\uCBF1-\uCC0B\uCC0D-\uCC27\uCC29-\uCC43\uCC45-\uCC5F\uCC61-\uCC7B\uCC7D-\uCC97\uCC99-\uCCB3\uCCB5-\uCCCF\uCCD1-\uCCEB\uCCED-\uCD07\uCD09-\uCD23\uCD25-\uCD3F\uCD41-\uCD5B\uCD5D-\uCD77\uCD79-\uCD93\uCD95-\uCDAF\uCDB1-\uCDCB\uCDCD-\uCDE7\uCDE9-\uCE03\uCE05-\uCE1F\uCE21-\uCE3B\uCE3D-\uCE57\uCE59-\uCE73\uCE75-\uCE8F\uCE91-\uCEAB\uCEAD-\uCEC7\uCEC9-\uCEE3\uCEE5-\uCEFF\uCF01-\uCF1B\uCF1D-\uCF37\uCF39-\uCF53\uCF55-\uCF6F\uCF71-\uCF8B\uCF8D-\uCFA7\uCFA9-\uCFC3\uCFC5-\uCFDF\uCFE1-\uCFFB\uCFFD-\uD017\uD019-\uD033\uD035-\uD04F\uD051-\uD06B\uD06D-\uD087\uD089-\uD0A3\uD0A5-\uD0BF\uD0C1-\uD0DB\uD0DD-\uD0F7\uD0F9-\uD113\uD115-\uD12F\uD131-\uD14B\uD14D-\uD167\uD169-\uD183\uD185-\uD19F\uD1A1-\uD1BB\uD1BD-\uD1D7\uD1D9-\uD1F3\uD1F5-\uD20F\uD211-\uD22B\uD22D-\uD247\uD249-\uD263\uD265-\uD27F\uD281-\uD29B\uD29D-\uD2B7\uD2B9-\uD2D3\uD2D5-\uD2EF\uD2F1-\uD30B\uD30D-\uD327\uD329-\uD343\uD345-\uD35F\uD361-\uD37B\uD37D-\uD397\uD399-\uD3B3\uD3B5-\uD3CF\uD3D1-\uD3EB\uD3ED-\uD407\uD409-\uD423\uD425-\uD43F\uD441-\uD45B\uD45D-\uD477\uD479-\uD493\uD495-\uD4AF\uD4B1-\uD4CB\uD4CD-\uD4E7\uD4E9-\uD503\uD505-\uD51F\uD521-\uD53B\uD53D-\uD557\uD559-\uD573\uD575-\uD58F\uD591-\uD5AB\uD5AD-\uD5C7\uD5C9-\uD5E3\uD5E5-\uD5FF\uD601-\uD61B\uD61D-\uD637\uD639-\uD653\uD655-\uD66F\uD671-\uD68B\uD68D-\uD6A7\uD6A9-\uD6C3\uD6C5-\uD6DF\uD6E1-\uD6FB\uD6FD-\uD717\uD719-\uD733\uD735-\uD74F\uD751-\uD76B\uD76D-\uD787\uD789-\uD7A3]$/,Np=/^(?:[\xA9\xAE\u203C\u2049\u2122\u2139\u2194-\u2199\u21A9\u21AA\u231A\u231B\u2328\u2388\u23CF\u23E9-\u23F3\u23F8-\u23FA\u24C2\u25AA\u25AB\u25B6\u25C0\u25FB-\u25FE\u2600-\u2605\u2607-\u2612\u2614-\u2685\u2690-\u2705\u2708-\u2712\u2714\u2716\u271D\u2721\u2728\u2733\u2734\u2744\u2747\u274C\u274E\u2753-\u2755\u2757\u2763-\u2767\u2795-\u2797\u27A1\u27B0\u27BF\u2934\u2935\u2B05-\u2B07\u2B1B\u2B1C\u2B50\u2B55\u3030\u303D\u3297\u3299]|\uD83C[\uDC00-\uDCFF\uDD0D-\uDD0F\uDD2F\uDD6C-\uDD71\uDD7E\uDD7F\uDD8E\uDD91-\uDD9A\uDDAD-\uDDE5\uDE01-\uDE0F\uDE1A\uDE2F\uDE32-\uDE3A\uDE3C-\uDE3F\uDE49-\uDFFA]|\uD83D[\uDC00-\uDD3D\uDD46-\uDE4F\uDE80-\uDEFF\uDF74-\uDF7F\uDFD5-\uDFFF]|\uD83E[\uDC0C-\uDC0F\uDC48-\uDC4F\uDC5A-\uDC5F\uDC88-\uDC8F\uDCAE-\uDCFF\uDD0C-\uDD3A\uDD3C-\uDD45\uDD47-\uDEFF]|\uD83F[\uDC00-\uDFFD])$/,Pp=(e,t)=>{var r=pp.Any;return-1!==e.search(Ap)&&(r|=pp.Extend),8205===t&&(r|=pp.ZWJ),t>=127462&&t<=127487&&(r|=pp.RI),-1!==e.search(xp)&&(r|=pp.Prepend),-1!==e.search(Bp)&&(r|=pp.SpacingMark),-1!==e.search(Sp)&&(r|=pp.L),-1!==e.search(Fp)&&(r|=pp.V),-1!==e.search(kp)&&(r|=pp.T),-1!==e.search(Op)&&(r|=pp.LV),-1!==e.search(Tp)&&(r|=pp.LVT),-1!==e.search(Np)&&(r|=pp.ExtPict),r};function Mp(e,t){return 0!==(e&t)}var Ip=[[pp.L,pp.L|pp.V|pp.LV|pp.LVT],[pp.LV|pp.V,pp.V|pp.T],[pp.LVT|pp.T,pp.T],[pp.Any,pp.Extend|pp.ZWJ],[pp.Any,pp.SpacingMark],[pp.Prepend,pp.Any],[pp.ZWJ,pp.ExtPict],[pp.RI,pp.RI]];function Rp(e,t){return-1===Ip.findIndex(r=>Mp(e,r[0])&&Mp(t,r[1]))}var Lp=/(?:[\xA9\xAE\u203C\u2049\u2122\u2139\u2194-\u2199\u21A9\u21AA\u231A\u231B\u2328\u2388\u23CF\u23E9-\u23F3\u23F8-\u23FA\u24C2\u25AA\u25AB\u25B6\u25C0\u25FB-\u25FE\u2600-\u2605\u2607-\u2612\u2614-\u2685\u2690-\u2705\u2708-\u2712\u2714\u2716\u271D\u2721\u2728\u2733\u2734\u2744\u2747\u274C\u274E\u2753-\u2755\u2757\u2763-\u2767\u2795-\u2797\u27A1\u27B0\u27BF\u2934\u2935\u2B05-\u2B07\u2B1B\u2B1C\u2B50\u2B55\u3030\u303D\u3297\u3299]|\uD83C[\uDC00-\uDCFF\uDD0D-\uDD0F\uDD2F\uDD6C-\uDD71\uDD7E\uDD7F\uDD8E\uDD91-\uDD9A\uDDAD-\uDDE5\uDE01-\uDE0F\uDE1A\uDE2F\uDE32-\uDE3A\uDE3C-\uDE3F\uDE49-\uDFFA]|\uD83D[\uDC00-\uDD3D\uDD46-\uDE4F\uDE80-\uDEFF\uDF74-\uDF7F\uDFD5-\uDFFF]|\uD83E[\uDC0C-\uDC0F\uDC48-\uDC4F\uDC5A-\uDC5F\uDC88-\uDC8F\uDCAE-\uDCFF\uDD0C-\uDD3A\uDD3C-\uDD45\uDD47-\uDEFF]|\uD83F[\uDC00-\uDFFD])(?:[\u0300-\u036F\u0483-\u0489\u0591-\u05BD\u05BF\u05C1\u05C2\u05C4\u05C5\u05C7\u0610-\u061A\u064B-\u065F\u0670\u06D6-\u06DC\u06DF-\u06E4\u06E7\u06E8\u06EA-\u06ED\u0711\u0730-\u074A\u07A6-\u07B0\u07EB-\u07F3\u07FD\u0816-\u0819\u081B-\u0823\u0825-\u0827\u0829-\u082D\u0859-\u085B\u08D3-\u08E1\u08E3-\u0902\u093A\u093C\u0941-\u0948\u094D\u0951-\u0957\u0962\u0963\u0981\u09BC\u09BE\u09C1-\u09C4\u09CD\u09D7\u09E2\u09E3\u09FE\u0A01\u0A02\u0A3C\u0A41\u0A42\u0A47\u0A48\u0A4B-\u0A4D\u0A51\u0A70\u0A71\u0A75\u0A81\u0A82\u0ABC\u0AC1-\u0AC5\u0AC7\u0AC8\u0ACD\u0AE2\u0AE3\u0AFA-\u0AFF\u0B01\u0B3C\u0B3E\u0B3F\u0B41-\u0B44\u0B4D\u0B55-\u0B57\u0B62\u0B63\u0B82\u0BBE\u0BC0\u0BCD\u0BD7\u0C00\u0C04\u0C3E-\u0C40\u0C46-\u0C48\u0C4A-\u0C4D\u0C55\u0C56\u0C62\u0C63\u0C81\u0CBC\u0CBF\u0CC2\u0CC6\u0CCC\u0CCD\u0CD5\u0CD6\u0CE2\u0CE3\u0D00\u0D01\u0D3B\u0D3C\u0D3E\u0D41-\u0D44\u0D4D\u0D57\u0D62\u0D63\u0D81\u0DCA\u0DCF\u0DD2-\u0DD4\u0DD6\u0DDF\u0E31\u0E34-\u0E3A\u0E47-\u0E4E\u0EB1\u0EB4-\u0EBC\u0EC8-\u0ECD\u0F18\u0F19\u0F35\u0F37\u0F39\u0F71-\u0F7E\u0F80-\u0F84\u0F86\u0F87\u0F8D-\u0F97\u0F99-\u0FBC\u0FC6\u102D-\u1030\u1032-\u1037\u1039\u103A\u103D\u103E\u1058\u1059\u105E-\u1060\u1071-\u1074\u1082\u1085\u1086\u108D\u109D\u135D-\u135F\u1712-\u1714\u1732-\u1734\u1752\u1753\u1772\u1773\u17B4\u17B5\u17B7-\u17BD\u17C6\u17C9-\u17D3\u17DD\u180B-\u180D\u1885\u1886\u18A9\u1920-\u1922\u1927\u1928\u1932\u1939-\u193B\u1A17\u1A18\u1A1B\u1A56\u1A58-\u1A5E\u1A60\u1A62\u1A65-\u1A6C\u1A73-\u1A7C\u1A7F\u1AB0-\u1AC0\u1B00-\u1B03\u1B34-\u1B3A\u1B3C\u1B42\u1B6B-\u1B73\u1B80\u1B81\u1BA2-\u1BA5\u1BA8\u1BA9\u1BAB-\u1BAD\u1BE6\u1BE8\u1BE9\u1BED\u1BEF-\u1BF1\u1C2C-\u1C33\u1C36\u1C37\u1CD0-\u1CD2\u1CD4-\u1CE0\u1CE2-\u1CE8\u1CED\u1CF4\u1CF8\u1CF9\u1DC0-\u1DF9\u1DFB-\u1DFF\u200C\u20D0-\u20F0\u2CEF-\u2CF1\u2D7F\u2DE0-\u2DFF\u302A-\u302F\u3099\u309A\uA66F-\uA672\uA674-\uA67D\uA69E\uA69F\uA6F0\uA6F1\uA802\uA806\uA80B\uA825\uA826\uA82C\uA8C4\uA8C5\uA8E0-\uA8F1\uA8FF\uA926-\uA92D\uA947-\uA951\uA980-\uA982\uA9B3\uA9B6-\uA9B9\uA9BC\uA9BD\uA9E5\uAA29-\uAA2E\uAA31\uAA32\uAA35\uAA36\uAA43\uAA4C\uAA7C\uAAB0\uAAB2-\uAAB4\uAAB7\uAAB8\uAABE\uAABF\uAAC1\uAAEC\uAAED\uAAF6\uABE5\uABE8\uABED\uFB1E\uFE00-\uFE0F\uFE20-\uFE2F\uFF9E\uFF9F]|\uD800[\uDDFD\uDEE0\uDF76-\uDF7A]|\uD802[\uDE01-\uDE03\uDE05\uDE06\uDE0C-\uDE0F\uDE38-\uDE3A\uDE3F\uDEE5\uDEE6]|\uD803[\uDD24-\uDD27\uDEAB\uDEAC\uDF46-\uDF50]|\uD804[\uDC01\uDC38-\uDC46\uDC7F-\uDC81\uDCB3-\uDCB6\uDCB9\uDCBA\uDD00-\uDD02\uDD27-\uDD2B\uDD2D-\uDD34\uDD73\uDD80\uDD81\uDDB6-\uDDBE\uDDC9-\uDDCC\uDDCF\uDE2F-\uDE31\uDE34\uDE36\uDE37\uDE3E\uDEDF\uDEE3-\uDEEA\uDF00\uDF01\uDF3B\uDF3C\uDF3E\uDF40\uDF57\uDF66-\uDF6C\uDF70-\uDF74]|\uD805[\uDC38-\uDC3F\uDC42-\uDC44\uDC46\uDC5E\uDCB0\uDCB3-\uDCB8\uDCBA\uDCBD\uDCBF\uDCC0\uDCC2\uDCC3\uDDAF\uDDB2-\uDDB5\uDDBC\uDDBD\uDDBF\uDDC0\uDDDC\uDDDD\uDE33-\uDE3A\uDE3D\uDE3F\uDE40\uDEAB\uDEAD\uDEB0-\uDEB5\uDEB7\uDF1D-\uDF1F\uDF22-\uDF25\uDF27-\uDF2B]|\uD806[\uDC2F-\uDC37\uDC39\uDC3A\uDD30\uDD3B\uDD3C\uDD3E\uDD43\uDDD4-\uDDD7\uDDDA\uDDDB\uDDE0\uDE01-\uDE0A\uDE33-\uDE38\uDE3B-\uDE3E\uDE47\uDE51-\uDE56\uDE59-\uDE5B\uDE8A-\uDE96\uDE98\uDE99]|\uD807[\uDC30-\uDC36\uDC38-\uDC3D\uDC3F\uDC92-\uDCA7\uDCAA-\uDCB0\uDCB2\uDCB3\uDCB5\uDCB6\uDD31-\uDD36\uDD3A\uDD3C\uDD3D\uDD3F-\uDD45\uDD47\uDD90\uDD91\uDD95\uDD97\uDEF3\uDEF4]|\uD81A[\uDEF0-\uDEF4\uDF30-\uDF36]|\uD81B[\uDF4F\uDF8F-\uDF92\uDFE4]|\uD82F[\uDC9D\uDC9E]|\uD834[\uDD65\uDD67-\uDD69\uDD6E-\uDD72\uDD7B-\uDD82\uDD85-\uDD8B\uDDAA-\uDDAD\uDE42-\uDE44]|\uD836[\uDE00-\uDE36\uDE3B-\uDE6C\uDE75\uDE84\uDE9B-\uDE9F\uDEA1-\uDEAF]|\uD838[\uDC00-\uDC06\uDC08-\uDC18\uDC1B-\uDC21\uDC23\uDC24\uDC26-\uDC2A\uDD30-\uDD36\uDEEC-\uDEEF]|\uD83A[\uDCD0-\uDCD6\uDD44-\uDD4A]|\uD83C[\uDFFB-\uDFFF]|\uDB40[\uDC20-\uDC7F\uDD00-\uDDEF])*\u200D$/,_p=e=>-1!==e.search(Lp),zp=/(?:\uD83C[\uDDE6-\uDDFF])+$/g,jp=e=>{var t=e.match(zp);return null!==t&&t[0].length/2%2==1},Hp=e=>nf(e)&&eg.isNodeList(e.children)&&!Yp.isEditor(e),Vp={isAncestor:e=>nf(e)&&eg.isNodeList(e.children),isElement:Hp,isElementList:e=>Array.isArray(e)&&e.every(e=>Vp.isElement(e)),isElementProps:e=>void 0!==e.children,isElementType:function(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"type";return Hp(e)&&e[r]===t},matches(e,t){for(var r in t)if("children"!==r&&e[r]!==t[r])return!1;return!0}},$p=["text"],Up=["text"];function qp(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),r.push.apply(r,n)}return r}function Wp(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?qp(Object(r),!0).forEach(function(t){np(e,t,r[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):qp(Object(r)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))})}return e}var Gp=new WeakMap,Yp={above(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{voids:r=!1,mode:n="lowest",at:o=e.selection,match:i}=t;if(o){var a=Yp.path(e,o),s="lowest"===n;for(var[u,l]of Yp.levels(e,{at:a,voids:r,match:i,reverse:s}))if(!Cg.isText(u)&&!og.equals(a,l))return[u,l]}},addMark(e,t,r){e.addMark(t,r)},after(e,t){var r,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},o={anchor:Yp.point(e,t,{edge:"end"}),focus:Yp.end(e,[])},{distance:i=1}=n,a=0;for(var s of Yp.positions(e,Wp(Wp({},n),{},{at:o}))){if(a>i)break;0!==a&&(r=s),a++}return r},before(e,t){var r,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},o={anchor:Yp.start(e,[]),focus:Yp.point(e,t,{edge:"start"})},{distance:i=1}=n,a=0;for(var s of Yp.positions(e,Wp(Wp({},n),{},{at:o,reverse:!0}))){if(a>i)break;0!==a&&(r=s),a++}return r},deleteBackward(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{unit:r="character"}=t;e.deleteBackward(r)},deleteForward(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{unit:r="character"}=t;e.deleteForward(r)},deleteFragment(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{direction:r="forward"}=t;e.deleteFragment(r)},edges:(e,t)=>[Yp.start(e,t),Yp.end(e,t)],end:(e,t)=>Yp.point(e,t,{edge:"end"}),first(e,t){var r=Yp.path(e,t,{edge:"start"});return Yp.node(e,r)},fragment(e,t){var r=Yp.range(e,t);return eg.fragment(e,r)},hasBlocks:(e,t)=>t.children.some(t=>Yp.isBlock(e,t)),hasInlines:(e,t)=>t.children.some(t=>Cg.isText(t)||Yp.isInline(e,t)),hasTexts:(e,t)=>t.children.every(e=>Cg.isText(e)),insertBreak(e){e.insertBreak()},insertSoftBreak(e){e.insertSoftBreak()},insertFragment(e,t){e.insertFragment(t)},insertNode(e,t){e.insertNode(t)},insertText(e,t){e.insertText(t)},isBlock:(e,t)=>Vp.isElement(t)&&!e.isInline(t),isEditor(e){var t=Gp.get(e);if(void 0!==t)return t;if(!nf(e))return!1;var r="function"==typeof e.addMark&&"function"==typeof e.apply&&"function"==typeof e.deleteBackward&&"function"==typeof e.deleteForward&&"function"==typeof e.deleteFragment&&"function"==typeof e.insertBreak&&"function"==typeof e.insertSoftBreak&&"function"==typeof e.insertFragment&&"function"==typeof e.insertNode&&"function"==typeof e.insertText&&"function"==typeof e.isInline&&"function"==typeof e.isVoid&&"function"==typeof e.normalizeNode&&"function"==typeof e.onChange&&"function"==typeof e.removeMark&&"function"==typeof e.getDirtyPaths&&(null===e.marks||nf(e.marks))&&(null===e.selection||hg.isRange(e.selection))&&eg.isNodeList(e.children)&&ng.isOperationList(e.operations);return Gp.set(e,r),r},isEnd(e,t,r){var n=Yp.end(e,r);return ug.equals(t,n)},isEdge:(e,t,r)=>Yp.isStart(e,t,r)||Yp.isEnd(e,t,r),isEmpty(e,t){var{children:r}=t,[n]=r;return 0===r.length||1===r.length&&Cg.isText(n)&&""===n.text&&!e.isVoid(t)},isInline:(e,t)=>Vp.isElement(t)&&e.isInline(t),isNormalizing(e){var t=sp.get(e);return void 0===t||t},isStart(e,t,r){if(0!==t.offset)return!1;var n=Yp.start(e,r);return ug.equals(t,n)},isVoid:(e,t)=>Vp.isElement(t)&&e.isVoid(t),last(e,t){var r=Yp.path(e,t,{edge:"end"});return Yp.node(e,r)},leaf(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},n=Yp.path(e,t,r);return[eg.leaf(e,n),n]},*levels(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{at:r=e.selection,reverse:n=!1,voids:o=!1}=t,{match:i}=t;if(null==i&&(i=()=>!0),r){var a=[],s=Yp.path(e,r);for(var[u,l]of eg.levels(e,s))if(i(u,l)&&(a.push([u,l]),!o&&Yp.isVoid(e,u)))break;n&&a.reverse(),yield*a}},marks(e){var{marks:t,selection:r}=e;if(!r)return null;if(t)return t;if(hg.isExpanded(r)){var[n]=Yp.nodes(e,{match:Cg.isText});if(n){var[o]=n;return fp(o,$p)}return{}}var{anchor:i}=r,{path:a}=i,[s]=Yp.leaf(e,a);if(0===i.offset){var u=Yp.previous(e,{at:a,match:Cg.isText}),l=Yp.above(e,{match:t=>Yp.isBlock(e,t)});if(u&&l){var[c,d]=u,[,h]=l;og.isAncestor(h,d)&&(s=c)}}return fp(s,Up)},next(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{mode:r="lowest",voids:n=!1}=t,{match:o,at:i=e.selection}=t;if(i){var a=Yp.after(e,i,{voids:n});if(a){var[,s]=Yp.last(e,[]),u=[a.path,s];if(og.isPath(i)&&0===i.length)throw new Error("Cannot get the next node from the root node!");if(null==o)if(og.isPath(i)){var[l]=Yp.parent(e,i);o=e=>l.children.includes(e)}else o=()=>!0;var[c]=Yp.nodes(e,{at:u,match:o,mode:r,voids:n});return c}}},node(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},n=Yp.path(e,t,r);return[eg.get(e,n),n]},*nodes(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{at:r=e.selection,mode:n="all",universal:o=!1,reverse:i=!1,voids:a=!1}=t,{match:s}=t;if(s||(s=()=>!0),r){var u,l;if(Xp.isSpan(r))u=r[0],l=r[1];else{var c=Yp.path(e,r,{edge:"start"}),d=Yp.path(e,r,{edge:"end"});u=i?d:c,l=i?c:d}var h,f=eg.nodes(e,{reverse:i,from:u,to:l,pass:t=>{var[r]=t;return!a&&Yp.isVoid(e,r)}}),p=[];for(var[g,m]of f){var v=h&&0===og.compare(m,h[1]);if("highest"!==n||!v)if(s(g,m))if("lowest"===n&&v)h=[g,m];else{var y="lowest"===n?h:[g,m];y&&(o?p.push(y):yield y),h=[g,m]}else if(o&&!v&&Cg.isText(g))return}"lowest"===n&&h&&(o?p.push(h):yield h),o&&(yield*p)}},normalize(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{force:r=!1}=t,n=e=>op.get(e)||[],o=e=>{var t=n(e).pop(),r=t.join(",");return(e=>ip.get(e)||new Set)(e).delete(r),t};if(Yp.isNormalizing(e)){if(r){var i=Array.from(eg.nodes(e),e=>{var[,t]=e;return t}),a=new Set(i.map(e=>e.join(",")));op.set(e,i),ip.set(e,a)}0!==n(e).length&&Yp.withoutNormalizing(e,()=>{for(var t of n(e))if(eg.has(e,t)){var r=Yp.node(e,t),[i,a]=r;Vp.isElement(i)&&0===i.children.length&&e.normalizeNode(r)}for(var s=42*n(e).length,u=0;0!==n(e).length;){if(u>s)throw new Error("\n Could not completely normalize the editor after ".concat(s," iterations! This is usually due to incorrect normalization logic that leaves a node in an invalid state.\n "));var l=o(e);if(eg.has(e,l)){var c=Yp.node(e,l);e.normalizeNode(c)}u++}})}},parent(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},n=Yp.path(e,t,r),o=og.parent(n);return Yp.node(e,o)},path(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},{depth:n,edge:o}=r;if(og.isPath(t))if("start"===o){var[,i]=eg.first(e,t);t=i}else if("end"===o){var[,a]=eg.last(e,t);t=a}return hg.isRange(t)&&(t="start"===o?hg.start(t):"end"===o?hg.end(t):og.common(t.anchor.path,t.focus.path)),ug.isPoint(t)&&(t=t.path),null!=n&&(t=t.slice(0,n)),t},hasPath:(e,t)=>eg.has(e,t),pathRef(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},{affinity:n="forward"}=r,o={current:t,affinity:n,unref(){var{current:t}=o;return Yp.pathRefs(e).delete(o),o.current=null,t}};return Yp.pathRefs(e).add(o),o},pathRefs(e){var t=up.get(e);return t||(t=new Set,up.set(e,t)),t},point(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},{edge:n="start"}=r;if(og.isPath(t)){var o;if("end"===n){var[,i]=eg.last(e,t);o=i}else{var[,a]=eg.first(e,t);o=a}var s=eg.get(e,o);if(!Cg.isText(s))throw new Error("Cannot get the ".concat(n," point in the node at path [").concat(t,"] because it has no ").concat(n," text node."));return{path:o,offset:"end"===n?s.text.length:0}}if(hg.isRange(t)){var[u,l]=hg.edges(t);return"start"===n?u:l}return t},pointRef(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},{affinity:n="forward"}=r,o={current:t,affinity:n,unref(){var{current:t}=o;return Yp.pointRefs(e).delete(o),o.current=null,t}};return Yp.pointRefs(e).add(o),o},pointRefs(e){var t=lp.get(e);return t||(t=new Set,lp.set(e,t)),t},*positions(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{at:r=e.selection,unit:n="offset",reverse:o=!1,voids:i=!1}=t;if(r){var a=Yp.range(e,r),[s,u]=hg.edges(a),l=o?u:s,c=!1,d="",h=0,f=0,p=0;for(var[g,m]of Yp.nodes(e,{at:r,reverse:o,voids:i})){if(Vp.isElement(g)){if(!i&&e.isVoid(g)){yield Yp.start(e,m);continue}if(e.isInline(g))continue;if(Yp.hasInlines(e,g)){var v=og.isAncestor(m,u.path)?u:Yp.end(e,m),y=og.isAncestor(m,s.path)?s:Yp.start(e,m);d=Yp.string(e,{anchor:y,focus:v},{voids:i}),c=!0}}if(Cg.isText(g)){var b=og.equals(m,l.path);for(b?(f=o?l.offset:g.text.length-l.offset,p=l.offset):(f=g.text.length,p=o?f:0),(b||c||"offset"===n)&&(yield{path:m,offset:p},c=!1);;){if(0===h){if(""===d)break;h=D(d,n,o),d=bp(d,h,o)[1]}if(p=o?p-h:p+h,(f-=h)<0){h=-f;break}h=0,yield{path:m,offset:p}}}}}function D(e,t,r){return"character"===t?gp(e,r):"word"===t?function(e){for(var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1],r=0,n=!1;e.length>0;){var o=gp(e,t),[i,a]=bp(e,o,t);if(Dp(i,a,t))n=!0,r+=o;else{if(n)break;r+=o}e=a}return r}(e,r):"line"===t||"block"===t?e.length:1}},previous(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{mode:r="lowest",voids:n=!1}=t,{match:o,at:i=e.selection}=t;if(i){var a=Yp.before(e,i,{voids:n});if(a){var[,s]=Yp.first(e,[]),u=[a.path,s];if(og.isPath(i)&&0===i.length)throw new Error("Cannot get the previous node from the root node!");if(null==o)if(og.isPath(i)){var[l]=Yp.parent(e,i);o=e=>l.children.includes(e)}else o=()=>!0;var[c]=Yp.nodes(e,{reverse:!0,at:u,match:o,mode:r,voids:n});return c}}},range:(e,t,r)=>hg.isRange(t)&&!r?t:{anchor:Yp.start(e,t),focus:Yp.end(e,r||t)},rangeRef(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},{affinity:n="forward"}=r,o={current:t,affinity:n,unref(){var{current:t}=o;return Yp.rangeRefs(e).delete(o),o.current=null,t}};return Yp.rangeRefs(e).add(o),o},rangeRefs(e){var t=cp.get(e);return t||(t=new Set,cp.set(e,t)),t},removeMark(e,t){e.removeMark(t)},setNormalizing(e,t){sp.set(e,t)},start:(e,t)=>Yp.point(e,t,{edge:"start"}),string(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},{voids:n=!1}=r,o=Yp.range(e,t),[i,a]=hg.edges(o),s="";for(var[u,l]of Yp.nodes(e,{at:o,match:Cg.isText,voids:n})){var c=u.text;og.equals(l,a.path)&&(c=c.slice(0,a.offset)),og.equals(l,i.path)&&(c=c.slice(i.offset)),s+=c}return s},unhangRange(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},{voids:n=!1}=r,[o,i]=hg.edges(t);if(0!==o.offset||0!==i.offset||hg.isCollapsed(t))return t;var a=Yp.above(e,{at:i,match:t=>Yp.isBlock(e,t)}),s=a?a[1]:[],u={anchor:Yp.start(e,o),focus:i},l=!0;for(var[c,d]of Yp.nodes(e,{at:u,match:Cg.isText,reverse:!0,voids:n}))if(l)l=!1;else if(""!==c.text||og.isBefore(d,s)){i={path:d,offset:c.text.length};break}return{anchor:o,focus:i}},void(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return Yp.above(e,Wp(Wp({},t),{},{match:t=>Yp.isVoid(e,t)}))},withoutNormalizing(e,t){var r=Yp.isNormalizing(e);Yp.setNormalizing(e,!1);try{t()}finally{Yp.setNormalizing(e,r)}Yp.normalize(e)}},Kp={isLocation:e=>og.isPath(e)||ug.isPoint(e)||hg.isRange(e)},Xp={isSpan:e=>Array.isArray(e)&&2===e.length&&e.every(og.isPath)},Zp=["children"],Jp=["text"],Qp=new WeakMap,eg={ancestor(e,t){var r=eg.get(e,t);if(Cg.isText(r))throw new Error("Cannot get the ancestor node at path [".concat(t,"] because it refers to a text node instead: ").concat(gg.stringify(r)));return r},*ancestors(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};for(var n of og.ancestors(t,r)){var o=[eg.ancestor(e,n),n];yield o}},child(e,t){if(Cg.isText(e))throw new Error("Cannot get the child of a text node: ".concat(gg.stringify(e)));var r=e.children[t];if(null==r)throw new Error("Cannot get child at index `".concat(t,"` in node: ").concat(gg.stringify(e)));return r},*children(e,t){for(var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},{reverse:n=!1}=r,o=eg.ancestor(e,t),{children:i}=o,a=n?i.length-1:0;n?a>=0:a<i.length;){var s=eg.child(o,a),u=t.concat(a);yield[s,u],a=n?a-1:a+1}},common(e,t,r){var n=og.common(t,r);return[eg.get(e,n),n]},descendant(e,t){var r=eg.get(e,t);if(Yp.isEditor(r))throw new Error("Cannot get the descendant node at path [".concat(t,"] because it refers to the root editor node instead: ").concat(gg.stringify(r)));return r},*descendants(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};for(var[r,n]of eg.nodes(e,t))0!==n.length&&(yield[r,n])},*elements(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};for(var[r,n]of eg.nodes(e,t))Vp.isElement(r)&&(yield[r,n])},extractProps:e=>Vp.isAncestor(e)?fp(e,Zp):fp(e,Jp),first(e,t){for(var r=t.slice(),n=eg.get(e,r);n&&!Cg.isText(n)&&0!==n.children.length;)n=n.children[0],r.push(0);return[n,r]},fragment(e,t){if(Cg.isText(e))throw new Error("Cannot get a fragment starting from a root text node: ".concat(gg.stringify(e)));var r=ep({children:e.children},e=>{var[r,n]=hg.edges(t),o=eg.nodes(e,{reverse:!0,pass:e=>{var[,r]=e;return!hg.includes(t,r)}});for(var[,i]of o){if(!hg.includes(t,i)){var a=eg.parent(e,i),s=i[i.length-1];a.children.splice(s,1)}if(og.equals(i,n.path)){var u=eg.leaf(e,i);u.text=u.text.slice(0,n.offset)}if(og.equals(i,r.path)){var l=eg.leaf(e,i);l.text=l.text.slice(r.offset)}}Yp.isEditor(e)&&(e.selection=null)});return r.children},get(e,t){for(var r=e,n=0;n<t.length;n++){var o=t[n];if(Cg.isText(r)||!r.children[o])throw new Error("Cannot find a descendant at path [".concat(t,"] in node: ").concat(gg.stringify(e)));r=r.children[o]}return r},has(e,t){for(var r=e,n=0;n<t.length;n++){var o=t[n];if(Cg.isText(r)||!r.children[o])return!1;r=r.children[o]}return!0},isNode:e=>Cg.isText(e)||Vp.isElement(e)||Yp.isEditor(e),isNodeList(e){if(!Array.isArray(e))return!1;var t=Qp.get(e);if(void 0!==t)return t;var r=e.every(e=>eg.isNode(e));return Qp.set(e,r),r},last(e,t){for(var r=t.slice(),n=eg.get(e,r);n&&!Cg.isText(n)&&0!==n.children.length;){var o=n.children.length-1;n=n.children[o],r.push(o)}return[n,r]},leaf(e,t){var r=eg.get(e,t);if(!Cg.isText(r))throw new Error("Cannot get the leaf node at path [".concat(t,"] because it refers to a non-leaf node: ").concat(gg.stringify(r)));return r},*levels(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};for(var n of og.levels(t,r)){var o=eg.get(e,n);yield[o,n]}},matches:(e,t)=>Vp.isElement(e)&&Vp.isElementProps(t)&&Vp.matches(e,t)||Cg.isText(e)&&Cg.isTextProps(t)&&Cg.matches(e,t),*nodes(e){for(var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{pass:r,reverse:n=!1}=t,{from:o=[],to:i}=t,a=new Set,s=[],u=e;!i||!(n?og.isBefore(s,i):og.isAfter(s,i));)if(a.has(u)||(yield[u,s]),a.has(u)||Cg.isText(u)||0===u.children.length||null!=r&&!1!==r([u,s])){if(0===s.length)break;if(!n){var l=og.next(s);if(eg.has(e,l)){s=l,u=eg.get(e,s);continue}}if(n&&0!==s[s.length-1])s=og.previous(s),u=eg.get(e,s);else s=og.parent(s),u=eg.get(e,s),a.add(u)}else{a.add(u);var c=n?u.children.length-1:0;og.isAncestor(s,o)&&(c=o[s.length]),s=s.concat(c),u=eg.get(e,s)}},parent(e,t){var r=og.parent(t),n=eg.get(e,r);if(Cg.isText(n))throw new Error("Cannot get the parent of path [".concat(t,"] because it does not exist in the root."));return n},string:e=>Cg.isText(e)?e.text:e.children.map(eg.string).join(""),*texts(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};for(var[r,n]of eg.nodes(e,t))Cg.isText(r)&&(yield[r,n])}};function tg(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),r.push.apply(r,n)}return r}function rg(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?tg(Object(r),!0).forEach(function(t){np(e,t,r[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):tg(Object(r)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))})}return e}var ng={isNodeOperation:e=>ng.isOperation(e)&&e.type.endsWith("_node"),isOperation(e){if(!nf(e))return!1;switch(e.type){case"insert_node":case"remove_node":return og.isPath(e.path)&&eg.isNode(e.node);case"insert_text":case"remove_text":return"number"==typeof e.offset&&"string"==typeof e.text&&og.isPath(e.path);case"merge_node":return"number"==typeof e.position&&og.isPath(e.path)&&nf(e.properties);case"move_node":return og.isPath(e.path)&&og.isPath(e.newPath);case"set_node":return og.isPath(e.path)&&nf(e.properties)&&nf(e.newProperties);case"set_selection":return null===e.properties&&hg.isRange(e.newProperties)||null===e.newProperties&&hg.isRange(e.properties)||nf(e.properties)&&nf(e.newProperties);case"split_node":return og.isPath(e.path)&&"number"==typeof e.position&&nf(e.properties);default:return!1}},isOperationList:e=>Array.isArray(e)&&e.every(e=>ng.isOperation(e)),isSelectionOperation:e=>ng.isOperation(e)&&e.type.endsWith("_selection"),isTextOperation:e=>ng.isOperation(e)&&e.type.endsWith("_text"),inverse(e){switch(e.type){case"insert_node":return rg(rg({},e),{},{type:"remove_node"});case"insert_text":return rg(rg({},e),{},{type:"remove_text"});case"merge_node":return rg(rg({},e),{},{type:"split_node",path:og.previous(e.path)});case"move_node":var{newPath:t,path:r}=e;if(og.equals(t,r))return e;if(og.isSibling(r,t))return rg(rg({},e),{},{path:t,newPath:r});var n=og.transform(r,e),o=og.transform(og.next(r),e);return rg(rg({},e),{},{path:n,newPath:o});case"remove_node":return rg(rg({},e),{},{type:"insert_node"});case"remove_text":return rg(rg({},e),{},{type:"insert_text"});case"set_node":var{properties:i,newProperties:a}=e;return rg(rg({},e),{},{properties:a,newProperties:i});case"set_selection":var{properties:s,newProperties:u}=e;return rg(rg({},e),{},null==s?{properties:u,newProperties:null}:null==u?{properties:null,newProperties:s}:{properties:u,newProperties:s});case"split_node":return rg(rg({},e),{},{type:"merge_node",path:og.next(e.path)})}}},og={ancestors(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{reverse:r=!1}=t,n=og.levels(e,t);return n=r?n.slice(1):n.slice(0,-1)},common(e,t){for(var r=[],n=0;n<e.length&&n<t.length;n++){var o=e[n];if(o!==t[n])break;r.push(o)}return r},compare(e,t){for(var r=Math.min(e.length,t.length),n=0;n<r;n++){if(e[n]<t[n])return-1;if(e[n]>t[n])return 1}return 0},endsAfter(e,t){var r=e.length-1,n=e.slice(0,r),o=t.slice(0,r),i=e[r],a=t[r];return og.equals(n,o)&&i>a},endsAt(e,t){var r=e.length,n=e.slice(0,r),o=t.slice(0,r);return og.equals(n,o)},endsBefore(e,t){var r=e.length-1,n=e.slice(0,r),o=t.slice(0,r),i=e[r],a=t[r];return og.equals(n,o)&&i<a},equals:(e,t)=>e.length===t.length&&e.every((e,r)=>e===t[r]),hasPrevious:e=>e[e.length-1]>0,isAfter:(e,t)=>1===og.compare(e,t),isAncestor:(e,t)=>e.length<t.length&&0===og.compare(e,t),isBefore:(e,t)=>-1===og.compare(e,t),isChild:(e,t)=>e.length===t.length+1&&0===og.compare(e,t),isCommon:(e,t)=>e.length<=t.length&&0===og.compare(e,t),isDescendant:(e,t)=>e.length>t.length&&0===og.compare(e,t),isParent:(e,t)=>e.length+1===t.length&&0===og.compare(e,t),isPath:e=>Array.isArray(e)&&(0===e.length||"number"==typeof e[0]),isSibling(e,t){if(e.length!==t.length)return!1;var r=e.slice(0,-1),n=t.slice(0,-1);return e[e.length-1]!==t[t.length-1]&&og.equals(r,n)},levels(e){for(var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{reverse:r=!1}=t,n=[],o=0;o<=e.length;o++)n.push(e.slice(0,o));return r&&n.reverse(),n},next(e){if(0===e.length)throw new Error("Cannot get the next path of a root path [".concat(e,"], because it has no next index."));var t=e[e.length-1];return e.slice(0,-1).concat(t+1)},operationCanTransformPath(e){switch(e.type){case"insert_node":case"remove_node":case"merge_node":case"split_node":case"move_node":return!0;default:return!1}},parent(e){if(0===e.length)throw new Error("Cannot get the parent path of the root path [".concat(e,"]."));return e.slice(0,-1)},previous(e){if(0===e.length)throw new Error("Cannot get the previous path of a root path [".concat(e,"], because it has no previous index."));var t=e[e.length-1];if(t<=0)throw new Error("Cannot get the previous path of a first child path [".concat(e,"] because it would result in a negative index."));return e.slice(0,-1).concat(t-1)},relative(e,t){if(!og.isAncestor(t,e)&&!og.equals(e,t))throw new Error("Cannot get the relative path of [".concat(e,"] inside ancestor [").concat(t,"], because it is not above or equal to the path."));return e.slice(t.length)},transform(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return ep(e,n=>{var{affinity:o="forward"}=r;if(e&&0!==(null==e?void 0:e.length)){if(null===n)return null;switch(t.type){case"insert_node":var{path:i}=t;(og.equals(i,n)||og.endsBefore(i,n)||og.isAncestor(i,n))&&(n[i.length-1]+=1);break;case"remove_node":var{path:a}=t;if(og.equals(a,n)||og.isAncestor(a,n))return null;og.endsBefore(a,n)&&(n[a.length-1]-=1);break;case"merge_node":var{path:s,position:u}=t;og.equals(s,n)||og.endsBefore(s,n)?n[s.length-1]-=1:og.isAncestor(s,n)&&(n[s.length-1]-=1,n[s.length]+=u);break;case"split_node":var{path:l,position:c}=t;if(og.equals(l,n)){if("forward"===o)n[n.length-1]+=1;else if("backward"!==o)return null}else og.endsBefore(l,n)?n[l.length-1]+=1:og.isAncestor(l,n)&&e[l.length]>=c&&(n[l.length-1]+=1,n[l.length]-=c);break;case"move_node":var{path:d,newPath:h}=t;if(og.equals(d,h))return;if(og.isAncestor(d,n)||og.equals(d,n)){var f=h.slice();return og.endsBefore(d,h)&&d.length<h.length&&(f[d.length-1]-=1),f.concat(n.slice(d.length))}og.isSibling(d,h)&&(og.isAncestor(h,n)||og.equals(h,n))?og.endsBefore(d,n)?n[d.length-1]-=1:n[d.length-1]+=1:og.endsBefore(h,n)||og.equals(h,n)||og.isAncestor(h,n)?(og.endsBefore(d,n)&&(n[d.length-1]-=1),n[h.length-1]+=1):og.endsBefore(d,n)&&(og.equals(h,n)&&(n[h.length-1]+=1),n[d.length-1]-=1)}}})}},ig={transform(e,t){var{current:r,affinity:n}=e;if(null!=r){var o=og.transform(r,t,{affinity:n});e.current=o,null==o&&e.unref()}}};function ag(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),r.push.apply(r,n)}return r}function sg(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?ag(Object(r),!0).forEach(function(t){np(e,t,r[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):ag(Object(r)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))})}return e}var ug={compare(e,t){var r=og.compare(e.path,t.path);return 0===r?e.offset<t.offset?-1:e.offset>t.offset?1:0:r},isAfter:(e,t)=>1===ug.compare(e,t),isBefore:(e,t)=>-1===ug.compare(e,t),equals:(e,t)=>e.offset===t.offset&&og.equals(e.path,t.path),isPoint:e=>nf(e)&&"number"==typeof e.offset&&og.isPath(e.path),transform(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return ep(e,e=>{if(null===e)return null;var{affinity:n="forward"}=r,{path:o,offset:i}=e;switch(t.type){case"insert_node":case"move_node":e.path=og.transform(o,t,r);break;case"insert_text":og.equals(t.path,o)&&(t.offset<i||t.offset===i&&"forward"===n)&&(e.offset+=t.text.length);break;case"merge_node":og.equals(t.path,o)&&(e.offset+=t.position),e.path=og.transform(o,t,r);break;case"remove_text":og.equals(t.path,o)&&t.offset<=i&&(e.offset-=Math.min(i-t.offset,t.text.length));break;case"remove_node":if(og.equals(t.path,o)||og.isAncestor(t.path,o))return null;e.path=og.transform(o,t,r);break;case"split_node":if(og.equals(t.path,o)){if(t.position===i&&null==n)return null;(t.position<i||t.position===i&&"forward"===n)&&(e.offset-=t.position,e.path=og.transform(o,t,sg(sg({},r),{},{affinity:"forward"})))}else e.path=og.transform(o,t,r)}})}},lg={transform(e,t){var{current:r,affinity:n}=e;if(null!=r){var o=ug.transform(r,t,{affinity:n});e.current=o,null==o&&e.unref()}}},cg=["anchor","focus"];function dg(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),r.push.apply(r,n)}return r}var hg={edges(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{reverse:r=!1}=t,{anchor:n,focus:o}=e;return hg.isBackward(e)===r?[n,o]:[o,n]},end(e){var[,t]=hg.edges(e);return t},equals:(e,t)=>ug.equals(e.anchor,t.anchor)&&ug.equals(e.focus,t.focus),includes(e,t){if(hg.isRange(t)){if(hg.includes(e,t.anchor)||hg.includes(e,t.focus))return!0;var[r,n]=hg.edges(e),[o,i]=hg.edges(t);return ug.isBefore(r,o)&&ug.isAfter(n,i)}var[a,s]=hg.edges(e),u=!1,l=!1;return ug.isPoint(t)?(u=ug.compare(t,a)>=0,l=ug.compare(t,s)<=0):(u=og.compare(t,a.path)>=0,l=og.compare(t,s.path)<=0),u&&l},intersection(e,t){var r=fp(e,cg),[n,o]=hg.edges(e),[i,a]=hg.edges(t),s=ug.isBefore(n,i)?i:n,u=ug.isBefore(o,a)?o:a;return ug.isBefore(u,s)?null:function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?dg(Object(r),!0).forEach(function(t){np(e,t,r[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):dg(Object(r)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))})}return e}({anchor:s,focus:u},r)},isBackward(e){var{anchor:t,focus:r}=e;return ug.isAfter(t,r)},isCollapsed(e){var{anchor:t,focus:r}=e;return ug.equals(t,r)},isExpanded:e=>!hg.isCollapsed(e),isForward:e=>!hg.isBackward(e),isRange:e=>nf(e)&&ug.isPoint(e.anchor)&&ug.isPoint(e.focus),*points(e){yield[e.anchor,"anchor"],yield[e.focus,"focus"]},start(e){var[t]=hg.edges(e);return t},transform(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return ep(e,e=>{if(null===e)return null;var n,o,{affinity:i="inward"}=r;if("inward"===i){var a=hg.isCollapsed(e);hg.isForward(e)?(n="forward",o=a?n:"backward"):(n="backward",o=a?n:"forward")}else"outward"===i?hg.isForward(e)?(n="backward",o="forward"):(n="forward",o="backward"):(n=i,o=i);var s=ug.transform(e.anchor,t,{affinity:n}),u=ug.transform(e.focus,t,{affinity:o});if(!s||!u)return null;e.anchor=s,e.focus=u})}},fg={transform(e,t){var{current:r,affinity:n}=e;if(null!=r){var o=hg.transform(r,t,{affinity:n});e.current=o,null==o&&e.unref()}}},pg=void 0,gg={setScrubber(e){pg=e},stringify:e=>JSON.stringify(e,pg)},mg=(e,t)=>{for(var r in e){var n=e[r],o=t[r];if(nf(n)&&nf(o)){if(!mg(n,o))return!1}else if(Array.isArray(n)&&Array.isArray(o)){if(n.length!==o.length)return!1;for(var i=0;i<n.length;i++)if(n[i]!==o[i])return!1}else if(n!==o)return!1}for(var a in t)if(void 0===e[a]&&void 0!==t[a])return!1;return!0},vg=["text"],yg=["anchor","focus"];function bg(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),r.push.apply(r,n)}return r}function Dg(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?bg(Object(r),!0).forEach(function(t){np(e,t,r[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):bg(Object(r)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))})}return e}var Cg={equals(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},{loose:n=!1}=r;function o(e){return fp(e,vg)}return mg(n?o(e):e,n?o(t):t)},isText:e=>nf(e)&&"string"==typeof e.text,isTextList:e=>Array.isArray(e)&&e.every(e=>Cg.isText(e)),isTextProps:e=>void 0!==e.text,matches(e,t){for(var r in t)if("text"!==r&&(!e.hasOwnProperty(r)||e[r]!==t[r]))return!1;return!0},decorations(e,t){var r=[Dg({},e)];for(var n of t){var o=fp(n,yg),[i,a]=hg.edges(n),s=[],u=0,l=i.offset,c=a.offset;for(var d of r){var{length:h}=d.text,f=u;if(u+=h,l<=f&&u<=c)Object.assign(d,o),s.push(d);else if(l!==c&&(l===u||c===f)||l>u||c<f||c===f&&0!==f)s.push(d);else{var p=d,g=void 0,m=void 0;if(c<u){var v=c-f;m=Dg(Dg({},p),{},{text:p.text.slice(v)}),p=Dg(Dg({},p),{},{text:p.text.slice(0,v)})}if(l>f){var y=l-f;g=Dg(Dg({},p),{},{text:p.text.slice(0,y)}),p=Dg(Dg({},p),{},{text:p.text.slice(y)})}Object.assign(p,o),g&&s.push(g),s.push(p),m&&s.push(m)}}r=s}return r}};function wg(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),r.push.apply(r,n)}return r}function Eg(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?wg(Object(r),!0).forEach(function(t){np(e,t,r[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):wg(Object(r)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))})}return e}var Ag={transform(e,t){e.children=tp(e.children);var r=e.selection&&tp(e.selection);try{r=((e,t,r)=>{switch(r.type){case"insert_node":var{path:n,node:o}=r,i=eg.parent(e,n),a=n[n.length-1];if(a>i.children.length)throw new Error('Cannot apply an "insert_node" operation at path ['.concat(n,"] because the destination is past the end of the node."));if(i.children.splice(a,0,o),t)for(var[s,u]of hg.points(t))t[u]=ug.transform(s,r);break;case"insert_text":var{path:l,offset:c,text:d}=r;if(0===d.length)break;var h=eg.leaf(e,l),f=h.text.slice(0,c),p=h.text.slice(c);if(h.text=f+d+p,t)for(var[g,m]of hg.points(t))t[m]=ug.transform(g,r);break;case"merge_node":var{path:v}=r,y=eg.get(e,v),b=og.previous(v),D=eg.get(e,b),C=eg.parent(e,v),w=v[v.length-1];if(Cg.isText(y)&&Cg.isText(D))D.text+=y.text;else{if(Cg.isText(y)||Cg.isText(D))throw new Error('Cannot apply a "merge_node" operation at path ['.concat(v,"] to nodes of different interfaces: ").concat(gg.stringify(y)," ").concat(gg.stringify(D)));D.children.push(...y.children)}if(C.children.splice(w,1),t)for(var[E,A]of hg.points(t))t[A]=ug.transform(E,r);break;case"move_node":var{path:x,newPath:B}=r;if(og.isAncestor(x,B))throw new Error("Cannot move a path [".concat(x,"] to new path [").concat(B,"] because the destination is inside itself."));var S=eg.get(e,x),F=eg.parent(e,x),k=x[x.length-1];F.children.splice(k,1);var O=og.transform(x,r),T=eg.get(e,og.parent(O)),N=O[O.length-1];if(T.children.splice(N,0,S),t)for(var[P,M]of hg.points(t))t[M]=ug.transform(P,r);break;case"remove_node":var{path:I}=r,R=I[I.length-1];if(eg.parent(e,I).children.splice(R,1),t)for(var[L,_]of hg.points(t)){var z=ug.transform(L,r);if(null!=t&&null!=z)t[_]=z;else{var j=void 0,H=void 0;for(var[V,$]of eg.texts(e)){if(-1!==og.compare($,I)){H=[V,$];break}j=[V,$]}var U=!1;j&&H&&(U=og.equals(H[1],I)?!og.hasPrevious(H[1]):og.common(j[1],I).length<og.common(H[1],I).length),j&&!U?(L.path=j[1],L.offset=j[0].text.length):H?(L.path=H[1],L.offset=0):t=null}}break;case"remove_text":var{path:q,offset:W,text:G}=r;if(0===G.length)break;var Y=eg.leaf(e,q),K=Y.text.slice(0,W),X=Y.text.slice(W+G.length);if(Y.text=K+X,t)for(var[Z,J]of hg.points(t))t[J]=ug.transform(Z,r);break;case"set_node":var{path:Q,properties:ee,newProperties:te}=r;if(0===Q.length)throw new Error("Cannot set properties on the root node!");var re=eg.get(e,Q);for(var ne in te){if("children"===ne||"text"===ne)throw new Error('Cannot set the "'.concat(ne,'" property of nodes!'));var oe=te[ne];null==oe?delete re[ne]:re[ne]=oe}for(var ie in ee)te.hasOwnProperty(ie)||delete re[ie];break;case"set_selection":var{newProperties:ae}=r;if(null==ae)t=ae;else{if(null==t){if(!hg.isRange(ae))throw new Error('Cannot apply an incomplete "set_selection" operation properties '.concat(gg.stringify(ae)," when there is no current selection."));t=Eg({},ae)}for(var se in ae){var ue=ae[se];if(null==ue){if("anchor"===se||"focus"===se)throw new Error('Cannot remove the "'.concat(se,'" selection property'));delete t[se]}else t[se]=ue}}break;case"split_node":var{path:le,position:ce,properties:de}=r;if(0===le.length)throw new Error('Cannot apply a "split_node" operation at path ['.concat(le,"] because the root node cannot be split."));var he,fe=eg.get(e,le),pe=eg.parent(e,le),ge=le[le.length-1];if(Cg.isText(fe)){var me=fe.text.slice(0,ce),ve=fe.text.slice(ce);fe.text=me,he=Eg(Eg({},de),{},{text:ve})}else{var ye=fe.children.slice(0,ce),be=fe.children.slice(ce);fe.children=ye,he=Eg(Eg({},de),{},{children:be})}if(pe.children.splice(ge+1,0,he),t)for(var[De,Ce]of hg.points(t))t[Ce]=ug.transform(De,r)}return t})(e,r,t)}finally{e.children=rp(e.children),e.selection=r?af(r)?rp(r):r:null}}},xg=["text"],Bg=["children"];function Sg(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),r.push.apply(r,n)}return r}function Fg(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?Sg(Object(r),!0).forEach(function(t){np(e,t,r[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Sg(Object(r)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))})}return e}var kg={insertNodes(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};Yp.withoutNormalizing(e,()=>{var{hanging:n=!1,voids:o=!1,mode:i="lowest"}=r,{at:a,match:s,select:u}=r;if(eg.isNode(t)&&(t=[t]),0!==t.length){var[l]=t;if(a||(a=e.selection?e.selection:e.children.length>0?Yp.end(e,[]):[0],u=!0),null==u&&(u=!1),hg.isRange(a))if(n||(a=Yp.unhangRange(e,a)),hg.isCollapsed(a))a=a.anchor;else{var[,c]=hg.edges(a),d=Yp.pointRef(e,c);zg.delete(e,{at:a}),a=d.unref()}if(ug.isPoint(a)){null==s&&(s=Cg.isText(l)?e=>Cg.isText(e):e.isInline(l)?t=>Cg.isText(t)||Yp.isInline(e,t):t=>Yp.isBlock(e,t));var[h]=Yp.nodes(e,{at:a.path,match:s,mode:i,voids:o});if(!h)return;var[,f]=h,p=Yp.pathRef(e,f),g=Yp.isEnd(e,a,f);zg.splitNodes(e,{at:a,match:s,mode:i,voids:o});var m=p.unref();a=g?og.next(m):m}var v=og.parent(a),y=a[a.length-1];if(o||!Yp.void(e,{at:v})){for(var b of t){var D=v.concat(y);y++,e.apply({type:"insert_node",path:D,node:b}),a=og.next(a)}if(a=og.previous(a),u){var C=Yp.end(e,a);C&&zg.select(e,C)}}}})},liftNodes(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};Yp.withoutNormalizing(e,()=>{var{at:r=e.selection,mode:n="lowest",voids:o=!1}=t,{match:i}=t;if(null==i&&(i=og.isPath(r)?Ng(e,r):t=>Yp.isBlock(e,t)),r){var a=Yp.nodes(e,{at:r,match:i,mode:n,voids:o}),s=Array.from(a,t=>{var[,r]=t;return Yp.pathRef(e,r)});for(var u of s){var l=u.unref();if(l.length<2)throw new Error("Cannot lift node at a path [".concat(l,"] because it has a depth of less than `2`."));var c=Yp.node(e,og.parent(l)),[d,h]=c,f=l[l.length-1],{length:p}=d.children;if(1===p){var g=og.next(h);zg.moveNodes(e,{at:l,to:g,voids:o}),zg.removeNodes(e,{at:h,voids:o})}else if(0===f)zg.moveNodes(e,{at:l,to:h,voids:o});else if(f===p-1){var m=og.next(h);zg.moveNodes(e,{at:l,to:m,voids:o})}else{var v=og.next(l),y=og.next(h);zg.splitNodes(e,{at:v,voids:o}),zg.moveNodes(e,{at:l,to:y,voids:o})}}}})},mergeNodes(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};Yp.withoutNormalizing(e,()=>{var{match:r,at:n=e.selection}=t,{hanging:o=!1,voids:i=!1,mode:a="lowest"}=t;if(n){if(null==r)if(og.isPath(n)){var[s]=Yp.parent(e,n);r=e=>s.children.includes(e)}else r=t=>Yp.isBlock(e,t);if(!o&&hg.isRange(n)&&(n=Yp.unhangRange(e,n)),hg.isRange(n))if(hg.isCollapsed(n))n=n.anchor;else{var[,u]=hg.edges(n),l=Yp.pointRef(e,u);zg.delete(e,{at:n}),n=l.unref(),null==t.at&&zg.select(e,n)}var[c]=Yp.nodes(e,{at:n,match:r,voids:i,mode:a}),d=Yp.previous(e,{at:n,match:r,voids:i,mode:a});if(c&&d){var[h,f]=c,[p,g]=d;if(0!==f.length&&0!==g.length){var m,v,y=og.next(g),b=og.common(f,g),D=og.isSibling(f,g),C=Array.from(Yp.levels(e,{at:f}),e=>{var[t]=e;return t}).slice(b.length).slice(0,-1),w=Yp.above(e,{at:f,mode:"highest",match:t=>C.includes(t)&&Og(e,t)}),E=w&&Yp.pathRef(e,w[1]);if(Cg.isText(h)&&Cg.isText(p)){var A=fp(h,xg);v=p.text.length,m=A}else{if(!Vp.isElement(h)||!Vp.isElement(p))throw new Error("Cannot merge the node at path [".concat(f,"] with the previous sibling because it is not the same kind: ").concat(gg.stringify(h)," ").concat(gg.stringify(p)));A=fp(h,Bg);v=p.children.length,m=A}D||zg.moveNodes(e,{at:f,to:y,voids:i}),E&&zg.removeNodes(e,{at:E.current,voids:i}),Vp.isElement(p)&&Yp.isEmpty(e,p)||Cg.isText(p)&&""===p.text&&0!==g[g.length-1]?zg.removeNodes(e,{at:g,voids:i}):e.apply({type:"merge_node",path:y,position:v,properties:m}),E&&E.unref()}}}})},moveNodes(e,t){Yp.withoutNormalizing(e,()=>{var{to:r,at:n=e.selection,mode:o="lowest",voids:i=!1}=t,{match:a}=t;if(n){null==a&&(a=og.isPath(n)?Ng(e,n):t=>Yp.isBlock(e,t));var s=Yp.pathRef(e,r),u=Yp.nodes(e,{at:n,match:a,mode:o,voids:i}),l=Array.from(u,t=>{var[,r]=t;return Yp.pathRef(e,r)});for(var c of l){var d=c.unref(),h=s.current;0!==d.length&&e.apply({type:"move_node",path:d,newPath:h}),s.current&&og.isSibling(h,d)&&og.isAfter(h,d)&&(s.current=og.next(s.current))}s.unref()}})},removeNodes(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};Yp.withoutNormalizing(e,()=>{var{hanging:r=!1,voids:n=!1,mode:o="lowest"}=t,{at:i=e.selection,match:a}=t;if(i){null==a&&(a=og.isPath(i)?Ng(e,i):t=>Yp.isBlock(e,t)),!r&&hg.isRange(i)&&(i=Yp.unhangRange(e,i));var s=Yp.nodes(e,{at:i,match:a,mode:o,voids:n}),u=Array.from(s,t=>{var[,r]=t;return Yp.pathRef(e,r)});for(var l of u){var c=l.unref();if(c){var[d]=Yp.node(e,c);e.apply({type:"remove_node",path:c,node:d})}}}})},setNodes(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};Yp.withoutNormalizing(e,()=>{var{match:n,at:o=e.selection,compare:i,merge:a}=r,{hanging:s=!1,mode:u="lowest",split:l=!1,voids:c=!1}=r;if(o){if(null==n&&(n=og.isPath(o)?Ng(e,o):t=>Yp.isBlock(e,t)),!s&&hg.isRange(o)&&(o=Yp.unhangRange(e,o)),l&&hg.isRange(o)){if(hg.isCollapsed(o)&&Yp.leaf(e,o.anchor)[0].text.length>0)return;var d=Yp.rangeRef(e,o,{affinity:"inward"}),[h,f]=hg.edges(o),p="lowest"===u?"lowest":"highest",g=Yp.isEnd(e,f,f.path);zg.splitNodes(e,{at:f,match:n,mode:p,voids:c,always:!g});var m=Yp.isStart(e,h,h.path);zg.splitNodes(e,{at:h,match:n,mode:p,voids:c,always:!m}),o=d.unref(),null==r.at&&zg.select(e,o)}for(var[v,y]of(i||(i=(e,t)=>e!==t),Yp.nodes(e,{at:o,match:n,mode:u,voids:c}))){var b={},D={};if(0!==y.length){var C=!1;for(var w in t)"children"!==w&&"text"!==w&&i(t[w],v[w])&&(C=!0,v.hasOwnProperty(w)&&(b[w]=v[w]),a?null!=t[w]&&(D[w]=a(v[w],t[w])):null!=t[w]&&(D[w]=t[w]));C&&e.apply({type:"set_node",path:y,properties:b,newProperties:D})}}}})},splitNodes(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};Yp.withoutNormalizing(e,()=>{var{mode:r="lowest",voids:n=!1}=t,{match:o,at:i=e.selection,height:a=0,always:s=!1}=t;if(null==o&&(o=t=>Yp.isBlock(e,t)),hg.isRange(i)&&(i=Tg(e,i)),og.isPath(i)){var u=i,l=Yp.point(e,u),[c]=Yp.parent(e,u);o=e=>e===c,a=l.path.length-u.length+1,i=l,s=!0}if(i){var d,h=Yp.pointRef(e,i,{affinity:"backward"});try{var[f]=Yp.nodes(e,{at:i,match:o,mode:r,voids:n});if(!f)return;var p=Yp.void(e,{at:i,mode:"highest"});if(!n&&p){var[g,m]=p;if(Vp.isElement(g)&&e.isInline(g)){var v=Yp.after(e,m);if(!v){var y=og.next(m);zg.insertNodes(e,{text:""},{at:y,voids:n}),v=Yp.point(e,y)}i=v,s=!0}a=i.path.length-m.length+1,s=!0}d=Yp.pointRef(e,i);var b=i.path.length-a,[,D]=f,C=i.path.slice(0,b),w=0===a?i.offset:i.path[b]+0;for(var[E,A]of Yp.levels(e,{at:C,reverse:!0,voids:n})){var x=!1;if(A.length<D.length||0===A.length||!n&&Yp.isVoid(e,E))break;var B=h.current,S=Yp.isEnd(e,B,A);if(s||!h||!Yp.isEdge(e,B,A)){x=!0;var F=eg.extractProps(E);e.apply({type:"split_node",path:A,position:w,properties:F})}w=A[A.length-1]+(x||S?1:0)}if(null==t.at){var k=d.current||Yp.end(e,[]);zg.select(e,k)}}finally{var O;h.unref(),null===(O=d)||void 0===O||O.unref()}}})},unsetNodes(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};Array.isArray(t)||(t=[t]);var n={};for(var o of t)n[o]=null;zg.setNodes(e,n,r)},unwrapNodes(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};Yp.withoutNormalizing(e,()=>{var{mode:r="lowest",split:n=!1,voids:o=!1}=t,{at:i=e.selection,match:a}=t;if(i){null==a&&(a=og.isPath(i)?Ng(e,i):t=>Yp.isBlock(e,t)),og.isPath(i)&&(i=Yp.range(e,i));var s=hg.isRange(i)?Yp.rangeRef(e,i):null,u=Yp.nodes(e,{at:i,match:a,mode:r,voids:o}),l=Array.from(u,t=>{var[,r]=t;return Yp.pathRef(e,r)}).reverse(),c=function(t){var r=t.unref(),[i]=Yp.node(e,r),a=Yp.range(e,r);n&&s&&(a=hg.intersection(s.current,a)),zg.liftNodes(e,{at:a,match:e=>Vp.isAncestor(i)&&i.children.includes(e),voids:o})};for(var d of l)c(d);s&&s.unref()}})},wrapNodes(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};Yp.withoutNormalizing(e,()=>{var{mode:n="lowest",split:o=!1,voids:i=!1}=r,{match:a,at:s=e.selection}=r;if(s){if(null==a&&(a=og.isPath(s)?Ng(e,s):e.isInline(t)?t=>Yp.isInline(e,t)||Cg.isText(t):t=>Yp.isBlock(e,t)),o&&hg.isRange(s)){var[u,l]=hg.edges(s),c=Yp.rangeRef(e,s,{affinity:"inward"});zg.splitNodes(e,{at:l,match:a,voids:i}),zg.splitNodes(e,{at:u,match:a,voids:i}),s=c.unref(),null==r.at&&zg.select(e,s)}var d=Array.from(Yp.nodes(e,{at:s,match:e.isInline(t)?t=>Yp.isBlock(e,t):e=>Yp.isEditor(e),mode:"lowest",voids:i}));for(var[,h]of d){var f=hg.isRange(s)?hg.intersection(s,Yp.range(e,h)):s;if(f){var p=Array.from(Yp.nodes(e,{at:f,match:a,mode:n,voids:i}));if(p.length>0){var g=function(){var[r]=p,n=p[p.length-1],[,o]=r,[,a]=n;if(0===o.length&&0===a.length)return"continue";var s=og.equals(o,a)?og.parent(o):og.common(o,a),u=Yp.range(e,o,a),l=Yp.node(e,s),[c]=l,d=s.length+1,h=og.next(a.slice(0,d)),f=Fg(Fg({},t),{},{children:[]});zg.insertNodes(e,f,{at:h,voids:i}),zg.moveNodes(e,{at:u,match:e=>Vp.isAncestor(c)&&c.children.includes(e),to:h.concat(0),voids:i})}();if("continue"===g)continue}}}}})}},Og=(e,t)=>{if(Vp.isElement(t)){var r=t;return!!Yp.isVoid(e,t)||1===r.children.length&&Og(e,r.children[0])}return!Yp.isEditor(t)},Tg=(e,t)=>{if(hg.isCollapsed(t))return t.anchor;var[,r]=hg.edges(t),n=Yp.pointRef(e,r);return zg.delete(e,{at:t}),n.unref()},Ng=(e,t)=>{var[r]=Yp.node(e,t);return e=>e===r};function Pg(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),r.push.apply(r,n)}return r}function Mg(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?Pg(Object(r),!0).forEach(function(t){np(e,t,r[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Pg(Object(r)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))})}return e}var Ig={collapse(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{edge:r="anchor"}=t,{selection:n}=e;if(n)if("anchor"===r)zg.select(e,n.anchor);else if("focus"===r)zg.select(e,n.focus);else if("start"===r){var[o]=hg.edges(n);zg.select(e,o)}else if("end"===r){var[,i]=hg.edges(n);zg.select(e,i)}},deselect(e){var{selection:t}=e;t&&e.apply({type:"set_selection",properties:t,newProperties:null})},move(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{selection:r}=e,{distance:n=1,unit:o="character",reverse:i=!1}=t,{edge:a=null}=t;if(r){"start"===a&&(a=hg.isBackward(r)?"focus":"anchor"),"end"===a&&(a=hg.isBackward(r)?"anchor":"focus");var{anchor:s,focus:u}=r,l={distance:n,unit:o},c={};if(null==a||"anchor"===a){var d=i?Yp.before(e,s,l):Yp.after(e,s,l);d&&(c.anchor=d)}if(null==a||"focus"===a){var h=i?Yp.before(e,u,l):Yp.after(e,u,l);h&&(c.focus=h)}zg.setSelection(e,c)}},select(e,t){var{selection:r}=e;if(t=Yp.range(e,t),r)zg.setSelection(e,t);else{if(!hg.isRange(t))throw new Error("When setting the selection and the current selection is `null` you must provide at least an `anchor` and `focus`, but you passed: ".concat(gg.stringify(t)));e.apply({type:"set_selection",properties:r,newProperties:t})}},setPoint(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},{selection:n}=e,{edge:o="both"}=r;if(n){"start"===o&&(o=hg.isBackward(n)?"focus":"anchor"),"end"===o&&(o=hg.isBackward(n)?"anchor":"focus");var{anchor:i,focus:a}=n,s="anchor"===o?i:a;zg.setSelection(e,{["anchor"===o?"anchor":"focus"]:Mg(Mg({},s),t)})}},setSelection(e,t){var{selection:r}=e,n={},o={};if(r){for(var i in t)("anchor"===i&&null!=t.anchor&&!ug.equals(t.anchor,r.anchor)||"focus"===i&&null!=t.focus&&!ug.equals(t.focus,r.focus)||"anchor"!==i&&"focus"!==i&&t[i]!==r[i])&&(n[i]=r[i],o[i]=t[i]);Object.keys(n).length>0&&e.apply({type:"set_selection",properties:n,newProperties:o})}}},Rg={delete(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};Yp.withoutNormalizing(e,()=>{var{reverse:r=!1,unit:n="character",distance:o=1,voids:i=!1}=t,{at:a=e.selection,hanging:s=!1}=t;if(a){var u=!1;if(hg.isRange(a)&&hg.isCollapsed(a)&&(u=!0,a=a.anchor),ug.isPoint(a)){var l=Yp.void(e,{at:a,mode:"highest"});if(!i&&l){var[,c]=l;a=c}else{var d={unit:n,distance:o};a={anchor:a,focus:r?Yp.before(e,a,d)||Yp.start(e,[]):Yp.after(e,a,d)||Yp.end(e,[])},s=!0}}if(og.isPath(a))zg.removeNodes(e,{at:a,voids:i});else if(!hg.isCollapsed(a)){if(!s){var[,h]=hg.edges(a),f=Yp.end(e,[]);ug.equals(h,f)||(a=Yp.unhangRange(e,a,{voids:i}))}var[p,g]=hg.edges(a),m=Yp.above(e,{match:t=>Yp.isBlock(e,t),at:p,voids:i}),v=Yp.above(e,{match:t=>Yp.isBlock(e,t),at:g,voids:i}),y=m&&v&&!og.equals(m[1],v[1]),b=og.equals(p.path,g.path),D=i?null:Yp.void(e,{at:p,mode:"highest"}),C=i?null:Yp.void(e,{at:g,mode:"highest"});if(D){var w=Yp.before(e,p);w&&m&&og.isAncestor(m[1],w.path)&&(p=w)}if(C){var E=Yp.after(e,g);E&&v&&og.isAncestor(v[1],E.path)&&(g=E)}var A,x=[];for(var B of Yp.nodes(e,{at:a,voids:i})){var[S,F]=B;A&&0===og.compare(F,A)||(!i&&Yp.isVoid(e,S)||!og.isCommon(F,p.path)&&!og.isCommon(F,g.path))&&(x.push(B),A=F)}var k=Array.from(x,t=>{var[,r]=t;return Yp.pathRef(e,r)}),O=Yp.pointRef(e,p),T=Yp.pointRef(e,g),N="";if(!b&&!D){var P=O.current,[M]=Yp.leaf(e,P),{path:I}=P,{offset:R}=p,L=M.text.slice(R);L.length>0&&(e.apply({type:"remove_text",path:I,offset:R,text:L}),N=L)}for(var _ of k){var z=_.unref();zg.removeNodes(e,{at:z,voids:i})}if(!C){var j=T.current,[H]=Yp.leaf(e,j),{path:V}=j,$=b?p.offset:0,U=H.text.slice($,g.offset);U.length>0&&(e.apply({type:"remove_text",path:V,offset:$,text:U}),N=U)}!b&&y&&T.current&&O.current&&zg.mergeNodes(e,{at:T.current,hanging:!0,voids:i}),u&&r&&"character"===n&&N.length>1&&N.match(/[\u0E00-\u0E7F]+/)&&zg.insertText(e,N.slice(0,N.length-o));var q=O.unref(),W=T.unref(),G=r?q||W:W||q;null==t.at&&G&&zg.select(e,G)}}})},insertFragment(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};Yp.withoutNormalizing(e,()=>{var{hanging:n=!1,voids:o=!1}=r,{at:i=e.selection}=r;if(t.length&&i){if(hg.isRange(i))if(n||(i=Yp.unhangRange(e,i)),hg.isCollapsed(i))i=i.anchor;else{var[,a]=hg.edges(i);if(!o&&Yp.void(e,{at:a}))return;var s=Yp.pointRef(e,a);zg.delete(e,{at:i}),i=s.unref()}else og.isPath(i)&&(i=Yp.start(e,i));if(o||!Yp.void(e,{at:i})){var u=Yp.above(e,{at:i,match:t=>Yp.isInline(e,t),mode:"highest",voids:o});if(u){var[,l]=u;if(Yp.isEnd(e,i,l))i=Yp.after(e,l);else if(Yp.isStart(e,i,l)){i=Yp.before(e,l)}}var c=Yp.above(e,{match:t=>Yp.isBlock(e,t),at:i,voids:o}),[,d]=c,h=Yp.isStart(e,i,d),f=Yp.isEnd(e,i,d),p=h&&f,g=!h||h&&f,m=!f,[,v]=eg.first({children:t},[]),[,y]=eg.last({children:t},[]),b=[],D=t=>{var[r,n]=t;return!(0===n.length)&&(!!p||!(g&&og.isAncestor(n,v)&&Vp.isElement(r)&&!e.isVoid(r)&&!e.isInline(r))&&!(m&&og.isAncestor(n,y)&&Vp.isElement(r)&&!e.isVoid(r)&&!e.isInline(r)))};for(var C of eg.nodes({children:t},{pass:D}))D(C)&&b.push(C);var w=[],E=[],A=[],x=!0,B=!1;for(var[S]of b)Vp.isElement(S)&&!e.isInline(S)?(x=!1,B=!0,E.push(S)):x?w.push(S):A.push(S);var[F]=Yp.nodes(e,{at:i,match:t=>Cg.isText(t)||Yp.isInline(e,t),mode:"highest",voids:o}),[,k]=F,O=Yp.isStart(e,i,k),T=Yp.isEnd(e,i,k),N=Yp.pathRef(e,f&&!A.length?og.next(d):d),P=Yp.pathRef(e,T?og.next(k):k);zg.splitNodes(e,{at:i,match:t=>B?Yp.isBlock(e,t):Cg.isText(t)||Yp.isInline(e,t),mode:B?"lowest":"highest",always:B&&(!h||w.length>0)&&(!f||A.length>0),voids:o});var M,I=Yp.pathRef(e,!O||O&&T?og.next(k):k);if(zg.insertNodes(e,w,{at:I.current,match:t=>Cg.isText(t)||Yp.isInline(e,t),mode:"highest",voids:o}),p&&!w.length&&E.length&&!A.length&&zg.delete(e,{at:d,voids:o}),zg.insertNodes(e,E,{at:N.current,match:t=>Yp.isBlock(e,t),mode:"lowest",voids:o}),zg.insertNodes(e,A,{at:P.current,match:t=>Cg.isText(t)||Yp.isInline(e,t),mode:"highest",voids:o}),!r.at)if(A.length>0&&P.current?M=og.previous(P.current):E.length>0&&N.current?M=og.previous(N.current):I.current&&(M=og.previous(I.current)),M){var R=Yp.end(e,M);zg.select(e,R)}I.unref(),N.unref(),P.unref()}}})},insertText(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};Yp.withoutNormalizing(e,()=>{var{voids:n=!1}=r,{at:o=e.selection}=r;if(o){if(og.isPath(o)&&(o=Yp.range(e,o)),hg.isRange(o))if(hg.isCollapsed(o))o=o.anchor;else{var i=hg.end(o);if(!n&&Yp.void(e,{at:i}))return;var a=hg.start(o),s=Yp.pointRef(e,a),u=Yp.pointRef(e,i);zg.delete(e,{at:o,voids:n});var l=s.unref(),c=u.unref();o=l||c,zg.setSelection(e,{anchor:o,focus:o})}if(n||!Yp.void(e,{at:o})){var{path:d,offset:h}=o;t.length>0&&e.apply({type:"insert_text",path:d,offset:h,text:t})}}})}};function Lg(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),r.push.apply(r,n)}return r}function _g(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?Lg(Object(r),!0).forEach(function(t){np(e,t,r[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Lg(Object(r)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))})}return e}var zg=_g(_g(_g(_g({},Ag),kg),Ig),Rg),jg={isHistory:e=>nf(e)&&Array.isArray(e.redos)&&Array.isArray(e.undos)&&(0===e.redos.length||ng.isOperationList(e.redos[0].operations))&&(0===e.undos.length||ng.isOperationList(e.undos[0].operations))},Hg=new WeakMap,Vg=new WeakMap,$g={isHistoryEditor:e=>jg.isHistory(e.history)&&Yp.isEditor(e),isMerging:e=>Vg.get(e),isSaving:e=>Hg.get(e),redo(e){e.redo()},undo(e){e.undo()},withMerging(e,t){var r=$g.isMerging(e);Vg.set(e,!0),t(),Vg.set(e,r)},withoutMerging(e,t){var r=$g.isMerging(e);Vg.set(e,!1),t(),Vg.set(e,r)},withoutSaving(e,t){var r=$g.isSaving(e);Hg.set(e,!1),t(),Hg.set(e,r)}},Ug=e=>{var t=e,{apply:r}=t;return t.history={undos:[],redos:[]},t.redo=()=>{var{history:e}=t,{redos:r}=e;if(r.length>0){var n=r[r.length-1];n.selectionBefore&&zg.setSelection(t,n.selectionBefore),$g.withoutSaving(t,()=>{Yp.withoutNormalizing(t,()=>{for(var e of n.operations)t.apply(e)})}),e.redos.pop(),t.writeHistory("undos",n)}},t.undo=()=>{var{history:e}=t,{undos:r}=e;if(r.length>0){var n=r[r.length-1];$g.withoutSaving(t,()=>{Yp.withoutNormalizing(t,()=>{var e=n.operations.map(ng.inverse).reverse();for(var r of e)t.apply(r);n.selectionBefore&&zg.setSelection(t,n.selectionBefore)})}),t.writeHistory("redos",n),e.undos.pop()}},t.apply=e=>{var{operations:n,history:o}=t,{undos:i}=o,a=i[i.length-1],s=a&&a.operations[a.operations.length-1],u=$g.isSaving(t),l=$g.isMerging(t);if(null==u&&(u=Wg(e)),u){if(null==l&&(l=null!=a&&(0!==n.length||qg(e,s))),a&&l)a.operations.push(e);else{var c={operations:[e],selectionBefore:t.selection};t.writeHistory("undos",c)}for(;i.length>100;)i.shift();o.redos=[]}r(e)},t.writeHistory=(e,r)=>{t.history[e].push(r)},t},qg=(e,t)=>!(!t||"insert_text"!==e.type||"insert_text"!==t.type||e.offset!==t.offset+t.text.length||!og.equals(e.path,t.path))||!(!t||"remove_text"!==e.type||"remove_text"!==t.type||e.offset+e.text.length!==t.offset||!og.equals(e.path,t.path)),Wg=(e,t)=>"set_selection"!==e.type,Gg=function(e,t){return Gg=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r])},Gg(e,t)};function Yg(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function r(){this.constructor=e}Gg(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)}var Kg=function(){return Kg=Object.assign||function(e){for(var t,r=1,n=arguments.length;r<n;r++)for(var o in t=arguments[r])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e},Kg.apply(this,arguments)};function Xg(e,t,r,n){return new(r||(r=Promise))(function(o,i){function a(e){try{u(n.next(e))}catch(e){i(e)}}function s(e){try{u(n.throw(e))}catch(e){i(e)}}function u(e){var t;e.done?o(e.value):(t=e.value,t instanceof r?t:new r(function(e){e(t)})).then(a,s)}u((n=n.apply(e,t||[])).next())})}function Zg(e,t){var r,n,o,i={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]},a=Object.create(("function"==typeof Iterator?Iterator:Object).prototype);return a.next=s(0),a.throw=s(1),a.return=s(2),"function"==typeof Symbol&&(a[Symbol.iterator]=function(){return this}),a;function s(s){return function(u){return function(s){if(r)throw new TypeError("Generator is already executing.");for(;a&&(a=0,s[0]&&(i=0)),i;)try{if(r=1,n&&(o=2&s[0]?n.return:s[0]?n.throw||((o=n.return)&&o.call(n),0):n.next)&&!(o=o.call(n,s[1])).done)return o;switch(n=0,o&&(s=[2&s[0],o.value]),s[0]){case 0:case 1:o=s;break;case 4:return i.label++,{value:s[1],done:!1};case 5:i.label++,n=s[1],s=[0];continue;case 7:s=i.ops.pop(),i.trys.pop();continue;default:if(!(o=i.trys,(o=o.length>0&&o[o.length-1])||6!==s[0]&&2!==s[0])){i=0;continue}if(3===s[0]&&(!o||s[1]>o[0]&&s[1]<o[3])){i.label=s[1];break}if(6===s[0]&&i.label<o[1]){i.label=o[1],o=s;break}if(o&&i.label<o[2]){i.label=o[2],i.ops.push(s);break}o[2]&&i.ops.pop(),i.trys.pop();continue}s=t.call(e,i)}catch(e){s=[6,e],n=0}finally{r=o=0}if(5&s[0])throw s[1];return{value:s[0]?s[1]:void 0,done:!0}}([s,u])}}}function Jg(e){var t="function"==typeof Symbol&&Symbol.iterator,r=t&&e[t],n=0;if(r)return r.call(e);if(e&&"number"==typeof e.length)return{next:function(){return e&&n>=e.length&&(e=void 0),{value:e&&e[n++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}function Qg(e,t){var r="function"==typeof Symbol&&e[Symbol.iterator];if(!r)return e;var n,o,i=r.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(n=i.next()).done;)a.push(n.value)}catch(e){o={error:e}}finally{try{n&&!n.done&&(r=i.return)&&r.call(i)}finally{if(o)throw o.error}}return a}function em(e,t,r){if(r||2===arguments.length)for(var n,o=0,i=t.length;o<i;o++)!n&&o in t||(n||(n=Array.prototype.slice.call(t,0,o)),n[o]=t[o]);return e.concat(n||Array.prototype.slice.call(t))}function tm(e){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var t,r=e[Symbol.asyncIterator];return r?r.call(e):(e=Jg(e),t={},n("next"),n("throw"),n("return"),t[Symbol.asyncIterator]=function(){return this},t);function n(r){t[r]=e[r]&&function(t){return new Promise(function(n,o){(function(e,t,r,n){Promise.resolve(n).then(function(t){e({value:t,done:r})},t)})(n,o,(t=e[r](t)).done,t.value)})}}}"function"==typeof SuppressedError&&SuppressedError;var rm,nm={exports:{}};var om,im,am=(rm||(rm=1,function(e,t){var r="__lodash_hash_undefined__",n=9007199254740991,o="[object Arguments]",i="[object Boolean]",a="[object Date]",s="[object Function]",u="[object GeneratorFunction]",l="[object Map]",c="[object Number]",d="[object Object]",h="[object Promise]",f="[object RegExp]",p="[object Set]",g="[object String]",m="[object Symbol]",v="[object WeakMap]",b="[object ArrayBuffer]",D="[object DataView]",C="[object Float32Array]",w="[object Float64Array]",E="[object Int8Array]",A="[object Int16Array]",x="[object Int32Array]",B="[object Uint8Array]",S="[object Uint8ClampedArray]",F="[object Uint16Array]",k="[object Uint32Array]",O=/\w*$/,T=/^\[object .+?Constructor\]$/,N=/^(?:0|[1-9]\d*)$/,P={};P[o]=P["[object Array]"]=P[b]=P[D]=P[i]=P[a]=P[C]=P[w]=P[E]=P[A]=P[x]=P[l]=P[c]=P[d]=P[f]=P[p]=P[g]=P[m]=P[B]=P[S]=P[F]=P[k]=!0,P["[object Error]"]=P[s]=P[v]=!1;var M="object"==typeof y&&y&&y.Object===Object&&y,I="object"==typeof self&&self&&self.Object===Object&&self,R=M||I||Function("return this")(),L=t&&!t.nodeType&&t,_=L&&e&&!e.nodeType&&e,z=_&&_.exports===L;function j(e,t){return e.set(t[0],t[1]),e}function H(e,t){return e.add(t),e}function V(e,t,r,n){for(var o=-1,i=e?e.length:0;++o<i;)r=t(r,e[o],o,e);return r}function $(e){var t=!1;if(null!=e&&"function"!=typeof e.toString)try{t=!!(e+"")}catch(e){}return t}function U(e){var t=-1,r=Array(e.size);return e.forEach(function(e,n){r[++t]=[n,e]}),r}function q(e,t){return function(r){return e(t(r))}}function W(e){var t=-1,r=Array(e.size);return e.forEach(function(e){r[++t]=e}),r}var G=Array.prototype,Y=Function.prototype,K=Object.prototype,X=R["__core-js_shared__"],Z=function(){var e=/[^.]+$/.exec(X&&X.keys&&X.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""}(),J=Y.toString,Q=K.hasOwnProperty,ee=K.toString,te=RegExp("^"+J.call(Q).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),re=z?R.Buffer:void 0,ne=R.Symbol,oe=R.Uint8Array,ie=q(Object.getPrototypeOf,Object),ae=Object.create,se=K.propertyIsEnumerable,ue=G.splice,le=Object.getOwnPropertySymbols,ce=re?re.isBuffer:void 0,de=q(Object.keys,Object),he=Le(R,"DataView"),fe=Le(R,"Map"),pe=Le(R,"Promise"),ge=Le(R,"Set"),me=Le(R,"WeakMap"),ve=Le(Object,"create"),ye=Ve(he),be=Ve(fe),De=Ve(pe),Ce=Ve(ge),we=Ve(me),Ee=ne?ne.prototype:void 0,Ae=Ee?Ee.valueOf:void 0;function xe(e){var t=-1,r=e?e.length:0;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}function Be(e){var t=-1,r=e?e.length:0;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}function Se(e){var t=-1,r=e?e.length:0;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}function Fe(e){this.__data__=new Be(e)}function ke(e,t){var r=Ue(e)||function(e){return function(e){return function(e){return!!e&&"object"==typeof e}(e)&&qe(e)}(e)&&Q.call(e,"callee")&&(!se.call(e,"callee")||ee.call(e)==o)}(e)?function(e,t){for(var r=-1,n=Array(e);++r<e;)n[r]=t(r);return n}(e.length,String):[],n=r.length,i=!!n;for(var a in e)!Q.call(e,a)||i&&("length"==a||je(a,n))||r.push(a);return r}function Oe(e,t,r){var n=e[t];Q.call(e,t)&&$e(n,r)&&(void 0!==r||t in e)||(e[t]=r)}function Te(e,t){for(var r=e.length;r--;)if($e(e[r][0],t))return r;return-1}function Ne(e,t,r,n,h,v,y){var T;if(n&&(T=v?n(e,h,v,y):n(e)),void 0!==T)return T;if(!Ye(e))return e;var N=Ue(e);if(N){if(T=function(e){var t=e.length,r=e.constructor(t);return t&&"string"==typeof e[0]&&Q.call(e,"index")&&(r.index=e.index,r.input=e.input),r}(e),!t)return function(e,t){var r=-1,n=e.length;for(t||(t=Array(n));++r<n;)t[r]=e[r];return t}(e,T)}else{var M=ze(e),I=M==s||M==u;if(We(e))return function(e,t){if(t)return e.slice();var r=new e.constructor(e.length);return e.copy(r),r}(e,t);if(M==d||M==o||I&&!v){if($(e))return v?e:{};if(T=function(e){return"function"!=typeof e.constructor||He(e)?{}:Ye(t=ie(e))?ae(t):{};var t}(I?{}:e),!t)return function(e,t){return Ie(e,_e(e),t)}(e,function(e,t){return e&&Ie(t,Ke(t),e)}(T,e))}else{if(!P[M])return v?e:{};T=function(e,t,r,n){var o=e.constructor;switch(t){case b:return Me(e);case i:case a:return new o(+e);case D:return function(e,t){var r=t?Me(e.buffer):e.buffer;return new e.constructor(r,e.byteOffset,e.byteLength)}(e,n);case C:case w:case E:case A:case x:case B:case S:case F:case k:return function(e,t){var r=t?Me(e.buffer):e.buffer;return new e.constructor(r,e.byteOffset,e.length)}(e,n);case l:return function(e,t,r){var n=t?r(U(e),!0):U(e);return V(n,j,new e.constructor)}(e,n,r);case c:case g:return new o(e);case f:return function(e){var t=new e.constructor(e.source,O.exec(e));return t.lastIndex=e.lastIndex,t}(e);case p:return function(e,t,r){var n=t?r(W(e),!0):W(e);return V(n,H,new e.constructor)}(e,n,r);case m:return function(e){return Ae?Object(Ae.call(e)):{}}(e)}}(e,M,Ne,t)}}y||(y=new Fe);var R=y.get(e);if(R)return R;if(y.set(e,T),!N)var L=r?function(e){return function(e,t,r){var n=t(e);return Ue(e)?n:function(e,t){for(var r=-1,n=t.length,o=e.length;++r<n;)e[o+r]=t[r];return e}(n,r(e))}(e,Ke,_e)}(e):Ke(e);return function(e,t){for(var r=-1,n=e?e.length:0;++r<n&&!1!==t(e[r],r,e););}(L||e,function(o,i){L&&(o=e[i=o]),Oe(T,i,Ne(o,t,r,n,i,e,y))}),T}function Pe(e){return!(!Ye(e)||(t=e,Z&&Z in t))&&(Ge(e)||$(e)?te:T).test(Ve(e));var t}function Me(e){var t=new e.constructor(e.byteLength);return new oe(t).set(new oe(e)),t}function Ie(e,t,r,n){r||(r={});for(var o=-1,i=t.length;++o<i;){var a=t[o];Oe(r,a,e[a])}return r}function Re(e,t){var r,n,o=e.__data__;return("string"==(n=typeof(r=t))||"number"==n||"symbol"==n||"boolean"==n?"__proto__"!==r:null===r)?o["string"==typeof t?"string":"hash"]:o.map}function Le(e,t){var r=function(e,t){return null==e?void 0:e[t]}(e,t);return Pe(r)?r:void 0}xe.prototype.clear=function(){this.__data__=ve?ve(null):{}},xe.prototype.delete=function(e){return this.has(e)&&delete this.__data__[e]},xe.prototype.get=function(e){var t=this.__data__;if(ve){var n=t[e];return n===r?void 0:n}return Q.call(t,e)?t[e]:void 0},xe.prototype.has=function(e){var t=this.__data__;return ve?void 0!==t[e]:Q.call(t,e)},xe.prototype.set=function(e,t){return this.__data__[e]=ve&&void 0===t?r:t,this},Be.prototype.clear=function(){this.__data__=[]},Be.prototype.delete=function(e){var t=this.__data__,r=Te(t,e);return!(r<0||(r==t.length-1?t.pop():ue.call(t,r,1),0))},Be.prototype.get=function(e){var t=this.__data__,r=Te(t,e);return r<0?void 0:t[r][1]},Be.prototype.has=function(e){return Te(this.__data__,e)>-1},Be.prototype.set=function(e,t){var r=this.__data__,n=Te(r,e);return n<0?r.push([e,t]):r[n][1]=t,this},Se.prototype.clear=function(){this.__data__={hash:new xe,map:new(fe||Be),string:new xe}},Se.prototype.delete=function(e){return Re(this,e).delete(e)},Se.prototype.get=function(e){return Re(this,e).get(e)},Se.prototype.has=function(e){return Re(this,e).has(e)},Se.prototype.set=function(e,t){return Re(this,e).set(e,t),this},Fe.prototype.clear=function(){this.__data__=new Be},Fe.prototype.delete=function(e){return this.__data__.delete(e)},Fe.prototype.get=function(e){return this.__data__.get(e)},Fe.prototype.has=function(e){return this.__data__.has(e)},Fe.prototype.set=function(e,t){var r=this.__data__;if(r instanceof Be){var n=r.__data__;if(!fe||n.length<199)return n.push([e,t]),this;r=this.__data__=new Se(n)}return r.set(e,t),this};var _e=le?q(le,Object):function(){return[]},ze=function(e){return ee.call(e)};function je(e,t){return!!(t=null==t?n:t)&&("number"==typeof e||N.test(e))&&e>-1&&e%1==0&&e<t}function He(e){var t=e&&e.constructor;return e===("function"==typeof t&&t.prototype||K)}function Ve(e){if(null!=e){try{return J.call(e)}catch(e){}try{return e+""}catch(e){}}return""}function $e(e,t){return e===t||e!=e&&t!=t}(he&&ze(new he(new ArrayBuffer(1)))!=D||fe&&ze(new fe)!=l||pe&&ze(pe.resolve())!=h||ge&&ze(new ge)!=p||me&&ze(new me)!=v)&&(ze=function(e){var t=ee.call(e),r=t==d?e.constructor:void 0,n=r?Ve(r):void 0;if(n)switch(n){case ye:return D;case be:return l;case De:return h;case Ce:return p;case we:return v}return t});var Ue=Array.isArray;function qe(e){return null!=e&&function(e){return"number"==typeof e&&e>-1&&e%1==0&&e<=n}(e.length)&&!Ge(e)}var We=ce||function(){return!1};function Ge(e){var t=Ye(e)?ee.call(e):"";return t==s||t==u}function Ye(e){var t=typeof e;return!!e&&("object"==t||"function"==t)}function Ke(e){return qe(e)?ke(e):function(e){if(!He(e))return de(e);var t=[];for(var r in Object(e))Q.call(e,r)&&"constructor"!=r&&t.push(r);return t}(e)}e.exports=function(e){return Ne(e,!0,!0)}}(nm,nm.exports)),nm.exports),sm=b(am);var um=function(){if(im)return om;im=1;var e=9007199254740991,t="[object Arguments]",r="[object Function]",n="[object GeneratorFunction]",o=/^(?:0|[1-9]\d*)$/;function i(e,t){for(var r=-1,n=e?e.length:0;++r<n&&!1!==t(e[r],r,e););return e}var a,s,u=Object.prototype,l=u.hasOwnProperty,c=u.toString,d=u.propertyIsEnumerable,h=(a=Object.keys,s=Object,function(e){return a(s(e))});function f(e,r){var n=b(e)||function(e){return function(e){return function(e){return!!e&&"object"==typeof e}(e)&&D(e)}(e)&&l.call(e,"callee")&&(!d.call(e,"callee")||c.call(e)==t)}(e)?function(e,t){for(var r=-1,n=Array(e);++r<e;)n[r]=t(r);return n}(e.length,String):[],o=n.length,i=!!o;for(var a in e)!l.call(e,a)||i&&("length"==a||y(a,o))||n.push(a);return n}var p,g=(p=function(e,t){return e&&m(e,t,C)},function(e,t){if(null==e)return e;if(!D(e))return p(e,t);for(var r=e.length,n=-1,o=Object(e);++n<r&&!1!==t(o[n],n,o););return e}),m=function(e,t,r){for(var n=-1,o=Object(e),i=r(e),a=i.length;a--;){var s=i[++n];if(!1===t(o[s],s,o))break}return e};function v(e){if(r=(t=e)&&t.constructor,n="function"==typeof r&&r.prototype||u,t!==n)return h(e);var t,r,n,o=[];for(var i in Object(e))l.call(e,i)&&"constructor"!=i&&o.push(i);return o}function y(t,r){return!!(r=null==r?e:r)&&("number"==typeof t||o.test(t))&&t>-1&&t%1==0&&t<r}var b=Array.isArray;function D(t){return null!=t&&function(t){return"number"==typeof t&&t>-1&&t%1==0&&t<=e}(t.length)&&!function(e){var t=function(e){var t=typeof e;return!!e&&("object"==t||"function"==t)}(e)?c.call(e):"";return t==r||t==n}(t)}function C(e){return D(e)?f(e):v(e)}function w(e){return e}return om=function(e,t){return(b(e)?i:g)(e,"function"==typeof t?t:w)}}(),lm=b(um),cm={};var dm="created",hm="destroyed",fm="change",pm="scroll",gm="fullscreen",mm="unFullScreen",vm={};function ym(e,t){var r=e.key,n=e.factory,o=e.config,i=Kg(Kg({},o),t||{});if(null!=vm[r])throw new Error("Duplicated key '".concat(r,"' in menu items"));vm[r]=n,function(e,t){null!=t&&(cm[e]=t)}(r,i)}var bm=new WeakMap,Dm=new WeakMap,Cm=new WeakMap,wm=new WeakMap,Em=new WeakMap,Am=new WeakMap,xm=new WeakMap,Bm=new WeakMap,Sm=new WeakMap,Fm=new WeakMap,km=new WeakMap,Om=new WeakMap,Tm=new WeakMap,Nm=new WeakMap,Pm=new WeakMap,Mm=new WeakMap,Im=new WeakMap,Rm=new WeakMap,Lm=new WeakMap,_m=new WeakMap,zm=new WeakMap,jm=new WeakMap,Hm=new WeakMap,Vm=new WeakMap,$m=new WeakMap,Um=new WeakMap,qm=new WeakMap,Wm=function(e){var t=e;return t.getAllMenuKeys=function(){var e=[];for(var t in vm)e.push(t);return e},t.getConfig=function(){var e=Fm.get(t);if(null==e)throw new Error("Can not get editor config");return e},t.getMenuConfig=function(e){var r=t.getConfig().MENU_CONF;return(void 0===r?{}:r)[e]||{}},t.alert=function(e,r){void 0===r&&(r="info");var n=t.getConfig().customAlert;n&&n(e,r)},t},Gm=new Set(["doctype","!doctype","meta","script","style","link","frame","iframe","title","svg"]);function Ym(e){return null!==e&&"object"==typeof e&&"constructor"in e&&e.constructor===Object}function Km(e={},t={}){Object.keys(t).forEach(r=>{void 0===e[r]?e[r]=t[r]:Ym(t[r])&&Ym(e[r])&&Object.keys(t[r]).length>0&&Km(e[r],t[r])})}const Xm={body:{},addEventListener(){},removeEventListener(){},activeElement:{blur(){},nodeName:""},querySelector:()=>null,querySelectorAll:()=>[],getElementById:()=>null,createEvent:()=>({initEvent(){}}),createElement:()=>({children:[],childNodes:[],style:{},setAttribute(){},getElementsByTagName:()=>[]}),createElementNS:()=>({}),importNode:()=>null,location:{hash:"",host:"",hostname:"",href:"",origin:"",pathname:"",protocol:"",search:""}};function Zm(){const e="undefined"!=typeof document?document:{};return Km(e,Xm),e}const Jm={document:Xm,navigator:{userAgent:""},location:{hash:"",host:"",hostname:"",href:"",origin:"",pathname:"",protocol:"",search:""},history:{replaceState(){},pushState(){},go(){},back(){}},CustomEvent:function(){return this},addEventListener(){},removeEventListener(){},getComputedStyle:()=>({getPropertyValue:()=>""}),Image(){},Date(){},screen:{},setTimeout(){},clearTimeout(){},matchMedia:()=>({}),requestAnimationFrame:e=>"undefined"==typeof setTimeout?(e(),null):setTimeout(e,0),cancelAnimationFrame(e){"undefined"!=typeof setTimeout&&clearTimeout(e)}};function Qm(){const e="undefined"!=typeof window?window:{};return Km(e,Jm),e}class ev extends Array{constructor(e){"number"==typeof e?super(e):(super(...e||[]),function(e){const t=e.__proto__;Object.defineProperty(e,"__proto__",{get:()=>t,set(e){t.__proto__=e}})}(this))}}function tv(e=[]){const t=[];return e.forEach(e=>{Array.isArray(e)?t.push(...tv(e)):t.push(e)}),t}function rv(e,t){return Array.prototype.filter.call(e,t)}function nv(e){return e.toLowerCase().replace(/-(.)/g,(e,t)=>t.toUpperCase())}function ov(e,t){const r=Qm(),n=Zm();let o=[];if(!t&&e instanceof ev)return e;if(!e)return new ev(o);if("string"==typeof e){const r=e.trim();if(r.indexOf("<")>=0&&r.indexOf(">")>=0){let e="div";0===r.indexOf("<li")&&(e="ul"),0===r.indexOf("<tr")&&(e="tbody"),0!==r.indexOf("<td")&&0!==r.indexOf("<th")||(e="tr"),0===r.indexOf("<tbody")&&(e="table"),0===r.indexOf("<option")&&(e="select");const t=n.createElement(e);t.innerHTML=r;for(let e=0;e<t.childNodes.length;e+=1)o.push(t.childNodes[e])}else o=function(e,t){if("string"!=typeof e)return[e];const r=[],n=t.querySelectorAll(e);for(let e=0;e<n.length;e+=1)r.push(n[e]);return r}(e.trim(),t||n)}else if(e.nodeType||e===r||e===n)o.push(e);else if(Array.isArray(e)){if(e instanceof ev)return e;o=e}return new ev(function(e){const t=[];for(let r=0;r<e.length;r+=1)-1===t.indexOf(e[r])&&t.push(e[r]);return t}(o))}function iv(...e){const t=tv(e.map(e=>e.split(" ")));return this.forEach(e=>{e.classList.add(...t)}),this}function av(...e){const t=tv(e.map(e=>e.split(" ")));return this.forEach(e=>{e.classList.remove(...t)}),this}function sv(...e){const t=tv(e.map(e=>e.split(" ")));return rv(this,e=>t.filter(t=>e.classList.contains(t)).length>0).length>0}function uv(e,t){if(1===arguments.length&&"string"==typeof e)return this[0]?this[0].getAttribute(e):void 0;for(let r=0;r<this.length;r+=1)if(2===arguments.length)this[r].setAttribute(e,t);else for(const t in e)this[r][t]=e[t],this[r].setAttribute(t,e[t]);return this}function lv(e){for(let t=0;t<this.length;t+=1)this[t].removeAttribute(e);return this}function cv(e,t){let r;if(void 0===t){if(r=this[0],!r)return;if(r.dom7ElementDataStorage&&e in r.dom7ElementDataStorage)return r.dom7ElementDataStorage[e];const t=r.getAttribute(`data-${e}`);return t||void 0}for(let n=0;n<this.length;n+=1)r=this[n],r.dom7ElementDataStorage||(r.dom7ElementDataStorage={}),r.dom7ElementDataStorage[e]=t;return this}function dv(){const e=this[0];if(!e)return;const t={};if(e.dataset)for(const r in e.dataset)t[r]=e.dataset[r];else for(let r=0;r<e.attributes.length;r+=1){const n=e.attributes[r];n.name.indexOf("data-")>=0&&(t[nv(n.name.split("data-")[1])]=n.value)}for(const e in t)"false"===t[e]?t[e]=!1:"true"===t[e]?t[e]=!0:parseFloat(t[e])===1*t[e]&&(t[e]*=1);return t}function hv(e){if(void 0===e){const e=this[0];if(!e)return;if(e.multiple&&"select"===e.nodeName.toLowerCase()){const t=[];for(let r=0;r<e.selectedOptions.length;r+=1)t.push(e.selectedOptions[r].value);return t}return e.value}for(let t=0;t<this.length;t+=1){const r=this[t];if(Array.isArray(e)&&r.multiple&&"select"===r.nodeName.toLowerCase())for(let t=0;t<r.options.length;t+=1)r.options[t].selected=e.indexOf(r.options[t].value)>=0;else r.value=e}return this}function fv(...e){let[t,r,n,o]=e;function i(e){const t=e.target;if(!t)return;const o=e.target.dom7EventData||[];if(o.indexOf(e)<0&&o.unshift(e),ov(t).is(r))n.apply(t,o);else{const e=ov(t).parents();for(let t=0;t<e.length;t+=1)ov(e[t]).is(r)&&n.apply(e[t],o)}}function a(e){const t=e&&e.target&&e.target.dom7EventData||[];t.indexOf(e)<0&&t.unshift(e),n.apply(this,t)}"function"==typeof e[1]&&([t,n,o]=e,r=void 0),o||(o=!1);const s=t.split(" ");let u;for(let e=0;e<this.length;e+=1){const t=this[e];if(r)for(u=0;u<s.length;u+=1){const e=s[u];t.dom7LiveListeners||(t.dom7LiveListeners={}),t.dom7LiveListeners[e]||(t.dom7LiveListeners[e]=[]),t.dom7LiveListeners[e].push({listener:n,proxyListener:i}),t.addEventListener(e,i,o)}else for(u=0;u<s.length;u+=1){const e=s[u];t.dom7Listeners||(t.dom7Listeners={}),t.dom7Listeners[e]||(t.dom7Listeners[e]=[]),t.dom7Listeners[e].push({listener:n,proxyListener:a}),t.addEventListener(e,a,o)}}return this}function pv(...e){let[t,r,n,o]=e;"function"==typeof e[1]&&([t,n,o]=e,r=void 0),o||(o=!1);const i=t.split(" ");for(let e=0;e<i.length;e+=1){const t=i[e];for(let e=0;e<this.length;e+=1){const i=this[e];let a;if(!r&&i.dom7Listeners?a=i.dom7Listeners[t]:r&&i.dom7LiveListeners&&(a=i.dom7LiveListeners[t]),a&&a.length)for(let e=a.length-1;e>=0;e-=1){const r=a[e];n&&r.listener===n||n&&r.listener&&r.listener.dom7proxy&&r.listener.dom7proxy===n?(i.removeEventListener(t,r.proxyListener,o),a.splice(e,1)):n||(i.removeEventListener(t,r.proxyListener,o),a.splice(e,1))}}}return this}function gv(){const e=Qm();return this[0]===e?e.innerWidth:this.length>0?parseFloat(this.css("width")):null}function mv(){const e=Qm();return this[0]===e?e.innerHeight:this.length>0?parseFloat(this.css("height")):null}function vv(){if(this.length>0){const e=Qm(),t=Zm(),r=this[0],n=r.getBoundingClientRect(),o=t.body,i=r.clientTop||o.clientTop||0,a=r.clientLeft||o.clientLeft||0,s=r===e?e.scrollY:r.scrollTop,u=r===e?e.scrollX:r.scrollLeft;return{top:n.top+s-i,left:n.left+u-a}}return null}function yv(){for(let e=0;e<this.length;e+=1)this[e].style.display="none";return this}function bv(){const e=Qm();for(let t=0;t<this.length;t+=1){const r=this[t];"none"===r.style.display&&(r.style.display=""),"none"===e.getComputedStyle(r,null).getPropertyValue("display")&&(r.style.display="block")}return this}function Dv(e,t){const r=Qm();let n;if(1===arguments.length){if("string"!=typeof e){for(n=0;n<this.length;n+=1)for(const t in e)this[n].style[t]=e[t];return this}if(this[0])return r.getComputedStyle(this[0],null).getPropertyValue(e)}if(2===arguments.length&&"string"==typeof e){for(n=0;n<this.length;n+=1)this[n].style[e]=t;return this}return this}function Cv(e){return e?(this.forEach((t,r)=>{e.apply(t,[t,r])}),this):this}function wv(e){return ov(rv(this,e))}function Ev(e){if(void 0===e)return this[0]?this[0].innerHTML:null;for(let t=0;t<this.length;t+=1)this[t].innerHTML=e;return this}function Av(e){if(void 0===e)return this[0]?this[0].textContent.trim():null;for(let t=0;t<this.length;t+=1)this[t].textContent=e;return this}function xv(e){const t=Qm(),r=Zm(),n=this[0];let o,i;if(!n||void 0===e)return!1;if("string"==typeof e){if(n.matches)return n.matches(e);if(n.webkitMatchesSelector)return n.webkitMatchesSelector(e);if(n.msMatchesSelector)return n.msMatchesSelector(e);for(o=ov(e),i=0;i<o.length;i+=1)if(o[i]===n)return!0;return!1}if(e===r)return n===r;if(e===t)return n===t;if(e.nodeType||e instanceof ev){for(o=e.nodeType?[e]:e,i=0;i<o.length;i+=1)if(o[i]===n)return!0;return!1}return!1}function Bv(...e){let t;const r=Zm();for(let n=0;n<e.length;n+=1){t=e[n];for(let e=0;e<this.length;e+=1)if("string"==typeof t){const n=r.createElement("div");for(n.innerHTML=t;n.firstChild;)this[e].appendChild(n.firstChild)}else if(t instanceof ev)for(let r=0;r<t.length;r+=1)this[e].appendChild(t[r]);else this[e].appendChild(t)}return this}function Sv(e){const t=Zm();let r,n;for(r=0;r<this.length;r+=1)if("string"==typeof e){const o=t.createElement("div");for(o.innerHTML=e,n=o.childNodes.length-1;n>=0;n-=1)this[r].insertBefore(o.childNodes[n],this[r].childNodes[0])}else if(e instanceof ev)for(n=0;n<e.length;n+=1)this[r].insertBefore(e[n],this[r].childNodes[0]);else this[r].insertBefore(e,this[r].childNodes[0]);return this}function Fv(e){const t=[];for(let r=0;r<this.length;r+=1)null!==this[r].parentNode&&(e?ov(this[r].parentNode).is(e)&&t.push(this[r].parentNode):t.push(this[r].parentNode));return ov(t)}function kv(e){const t=[];for(let r=0;r<this.length;r+=1){let n=this[r].parentNode;for(;n;)e?ov(n).is(e)&&t.push(n):t.push(n),n=n.parentNode}return ov(t)}function Ov(e){const t=[];for(let r=0;r<this.length;r+=1){const n=this[r].querySelectorAll(e);for(let e=0;e<n.length;e+=1)t.push(n[e])}return ov(t)}function Tv(e){const t=[];for(let r=0;r<this.length;r+=1){const n=this[r].children;for(let r=0;r<n.length;r+=1)e&&!ov(n[r]).is(e)||t.push(n[r])}return ov(t)}function Nv(){for(let e=0;e<this.length;e+=1)this[e].parentNode&&this[e].parentNode.removeChild(this[e]);return this}function Pv(){for(let e=0;e<this.length;e+=1){const t=this[e];if(1===t.nodeType){for(let e=0;e<t.childNodes.length;e+=1)t.childNodes[e].parentNode&&t.childNodes[e].parentNode.removeChild(t.childNodes[e]);t.textContent=""}}return this}ov.fn=ev.prototype;const Mv="resize scroll".split(" ");function Iv(e){return function(...t){if(void 0===t[0]){for(let t=0;t<this.length;t+=1)Mv.indexOf(e)<0&&(e in this[t]?this[t][e]():ov(this[t]).trigger(e));return this}return this.on(e,...t)}}const Rv=Iv("click"),Lv=Iv("focus"),_v=["area","base","basefont","bgsound","br","col","command","embed","frame","hr","image","img","input","keygen","link","meta","param","source","track","wbr"];let zv=(e=21)=>{let t="",r=crypto.getRandomValues(new Uint8Array(e|=0));for(;e--;)t+="useandom-26T198340PX75pxJACKVERYMINDBUSHWOLF_GQZbfghjklqvwyzrict"[63&r[e]];return t};function jv(e){Promise.resolve().then(e)}var Hv,Vv=function(e){return Object.prototype.toString.call(e)};Dv&&(ov.fn.css=Dv),Bv&&(ov.fn.append=Bv),iv&&(ov.fn.addClass=iv),av&&(ov.fn.removeClass=av),sv&&(ov.fn.hasClass=sv),fv&&(ov.fn.on=fv),Lv&&(ov.fn.focus=Lv),uv&&(ov.fn.attr=uv),lv&&(ov.fn.removeAttr=lv),yv&&(ov.fn.hide=yv),bv&&(ov.fn.show=bv),vv&&(ov.fn.offset=vv),gv&&(ov.fn.width=gv),mv&&(ov.fn.height=mv),Fv&&(ov.fn.parent=Fv),kv&&(ov.fn.parents=kv),xv&&(ov.fn.is=xv),dv&&(ov.fn.dataset=dv),hv&&(ov.fn.val=hv),Av&&(ov.fn.text=Av),Ev&&(ov.fn.html=Ev),Tv&&(ov.fn.children=Tv),Nv&&(ov.fn.remove=Nv),Ov&&(ov.fn.find=Ov),Cv&&(ov.fn.each=Cv),Pv&&(ov.fn.empty=Pv),function(e){e[e.ELEMENT_NODE=1]="ELEMENT_NODE",e[e.TEXT_NODE=3]="TEXT_NODE",e[e.CDATA_SECTION_NODE=4]="CDATA_SECTION_NODE",e[e.PROCESSING_INSTRUCTION_NODE=7]="PROCESSING_INSTRUCTION_NODE",e[e.COMMENT_NODE=8]="COMMENT_NODE",e[e.DOCUMENT_NODE=9]="DOCUMENT_NODE",e[e.DOCUMENT_TYPE_NODE=10]="DOCUMENT_TYPE_NODE",e[e.DOCUMENT_FRAGMENT_NODE=11]="DOCUMENT_FRAGMENT_NODE"}(Hv||(Hv={}));var $v=/\[object HTML([A-Z][a-z]*)*Element\]/,Uv=function(e){return $v.test(Vv(e))},qv=function(e){return null!=e&&"number"==typeof e.nodeType},Wv=function(e){return qv(e)&&e.nodeType===Hv.COMMENT_NODE},Gv=function(e){return qv(e)&&e.nodeType===Hv.ELEMENT_NODE},Yv=function(e){return"[object Selection]"===Vv(e)},Kv=function(e){return qv(e)&&e.nodeType===Hv.TEXT_NODE},Xv=function(e){var t,r,n;return null!==(t=window&&window.document.getElementById(e))&&void 0!==t?t:window&&(null===(n=null===(r=window.document.activeElement)||void 0===r?void 0:r.shadowRoot)||void 0===n?void 0:n.getElementById(e))||null},Zv=function(e,t,r){for(var n=e.childNodes,o=n[t],i=t,a=!1,s=!1;(Wv(o)||Gv(o)&&0===o.childNodes.length||Gv(o)&&"false"===o.getAttribute("contenteditable"))&&(!a||!s);)i>=n.length?(a=!0,i=t-1,r="backward"):i<0?(s=!0,i=t+1,r="forward"):(o=n[i],t=i,i+="forward"===r?1:-1);return[o,t]},Jv=function(e,t,r){return Qg(Zv(e,t,r),1)[0]},Qv=function(e){var t,r,n="";if(Kv(e)&&e.nodeValue)return e.nodeValue;if(Gv(e)){try{for(var o=Jg(Array.from(e.childNodes)),i=o.next();!i.done;i=o.next()){var a=i.value;n+=Qv(a)}}catch(e){t={error:e}}finally{try{i&&!i.done&&(r=o.return)&&r.call(o)}finally{if(t)throw t.error}}var s=getComputedStyle(e).getPropertyValue("display");"block"!==s&&"list"!==s&&"table-row"!==s&&"BR"!==e.tagName||(n+="\n")}return n};function ey(e,t){if(!Uv(e)||"true"!==e.dataset.slateVoid)for(var r=e.childNodes,n=r.length;n-=1;){var o=r[n],i=o.nodeType;Kv(o)?t(o,e):[Hv.ELEMENT_NODE,Hv.DOCUMENT_NODE,Hv.DOCUMENT_FRAGMENT_NODE].includes(i)&&ey(o,t)}}function ty(e){if(0===e.length)return"";var t=e[0];return t.nodeType!==Hv.ELEMENT_NODE?"":t.tagName.toLowerCase()}var ry=new RegExp(String.fromCharCode(160),"g");function ny(e){return e.replace(ry," ")}var oy=["span","b","strong","i","em","s","strike","u","font","sub","sup"],iy=[];var ay={};function sy(e,t){var r=e.length;if(r){var n=e[r-1];if(Cg.isText(n)){var o=Object.keys(n);if(1===o.length&&"text"===o[0])return n.text+=t,!0}}return!1}function uy(e,t,r){return{type:"paragraph",children:t&&t.length>0?t:[{text:ov(e).text().replace(/\s+/gm," ")}]}}function ly(e,t){var r=function(e,t){var r=[];if(null!=e.attr("data-w-e-is-void"))return r;var n=e[0].childNodes;return 1===n.length&&"BR"===n[0].nodeName?(r.push({text:""}),r):(n.forEach(function(e){if(Gv(e)){if("BR"===e.nodeName)return void(sy(r,"\n")||r.push({text:"\n"}));var n=gy(ov(e),t);Array.isArray(n)?n.forEach(function(e){return r.push(e)}):r.push(n)}else if(Kv(e)){var o=e.textContent||"";if(""===o.trim()&&o.indexOf("\n")>=0)return;o&&(o=ny(o),sy(r,o)||r.push({text:o}))}}),r)}(e,t),n=function(e){for(var t in ay)if(e[0].matches(t))return ay[t];return uy}(e),o=n(e[0],r,t);return Array.isArray(o)||(o=[o]),o.forEach(function(n){Yp.isVoid(t,n)||(0===r.length&&(n.children=[{text:e.text().replace(/\s+/gm," ")}]),iy.forEach(function(r){n=r(e[0],n,t)}))}),o}function cy(e,t){0===e.parents("pre").length&&(e[0].innerHTML=e[0].innerHTML.replace(/\s+/gm," ").replace(/<br>/g,"\n"));var r=e[0].textContent||"";r=function(e){return e.replace(/ /g," ").replace(/</g,"<").replace(/>/g,">").replace(/®/g,"®").replace(/©/g,"©").replace(/™/g,"™").replace(/"/g,'"')}(r);var n={text:r=ny(r)};return iy.forEach(function(r){n=r(e[0],n,t)}),n}function dy(e){var t=ty(e),r=e.attr&&e.attr("style")||"",n={};return["i","em"].includes(t)&&(n.italic=!0),["b","strong"].includes(t)&&(n.bold=!0),["u"].includes(t)&&(n.underline=!0),["s","strike","del"].includes(t)&&(n.through=!0),["code"].includes(t)&&(n.code=!0),["sub"].includes(t)&&(n.sub=!0),["sup"].includes(t)&&(n.sup=!0),/font-style\s*:\s*italic/i.test(r)&&(n.italic=!0),/vertical-align\s*:\s*sub/i.test(r)&&(n.sub=!0),/vertical-align\s*:\s*super/i.test(r)&&(n.sup=!0),n}function hy(e){var t=e.attr&&e.attr("style")||"",r={},n=t.match(/font-size\s*:\s*([^;]+)/i);n&&(r.fontSize=n[1].trim());var o=t.match(/font-family\s*:\s*([^;]+)/i);o&&(r.fontFamily=o[1].trim().replace(/["']/g,""));var i=t.match(/line-height\s*:\s*([^;]+)/i);return i&&(r.lineHeight=i[1].trim()),r}function fy(e,t,r){var n=Kg({},e);return Object.keys(r||{}).forEach(function(e){void 0===n[e]&&(n[e]=r[e])}),t&&(t.bold&&!n.bold&&(n.bold=!0),t.italic&&!n.italic&&(n.italic=!0),t.underline&&!n.underline&&(n.underline=!0),t.through&&!n.through&&(n.through=!0),t.code&&!n.code&&(n.code=!0),!t.sub||n.sub||n.sup||(n.sub=!0),!t.sup||n.sup||n.sub||(n.sup=!0)),n}function py(e){var t,r,n,o,i=[];try{for(var a=Jg(e),s=a.next();!s.done;s=a.next()){var u=s.value,l=i[i.length-1];if(l&&void 0!==l.text&&void 0!==u.text){var c=Object.keys(l).filter(function(e){return"text"!==e}).sort(),d=Object.keys(u).filter(function(e){return"text"!==e}).sort();if(JSON.stringify(c)===JSON.stringify(d)){var h=!0;try{for(var f=(n=void 0,Jg(c)),p=f.next();!p.done;p=f.next()){var g=p.value;if(JSON.stringify(l[g])!==JSON.stringify(u[g])){h=!1;break}}}catch(e){n={error:e}}finally{try{p&&!p.done&&(o=f.return)&&o.call(f)}finally{if(n)throw n.error}}if(h){l.text+=u.text;continue}}}i.push(u)}}catch(e){t={error:e}}finally{try{s&&!s.done&&(r=a.return)&&r.call(a)}finally{if(t)throw t.error}}return i}function gy(e,t,r,n){var o,i,a,s;void 0===r&&(r={}),void 0===n&&(n={});var u=e[0];if(u.nodeType===Node.TEXT_NODE)return fy({text:k=u.nodeValue||""},r,n);var l=ty(e);if("a"===l&&!e.attr("href")){var c=dy(e),d=hy(e),h=Kg({},r);Object.keys(c).forEach(function(e){c[e]&&(h[e]=!0)});var f=Kg(Kg({},n||{}),d||{}),p=Array.from(u.childNodes),g=[];try{for(var m=Jg(p),v=m.next();!v.done;v=m.next()){if((F=v.value).nodeType!==Node.TEXT_NODE){var y=gy(ov(F),t,h,f);Array.isArray(y)?y.forEach(function(e){return g.push(e)}):g.push(y)}else{""!==(k=F.nodeValue||"")&&g.push(fy({text:k},h,f))}}}catch(e){o={error:e}}finally{try{v&&!v.done&&(i=m.return)&&i.call(m)}finally{if(o)throw o.error}}if(0===g.length)return ly(e,t);var b=py(g);return 1===b.length?b[0]:b}if("code"===l)return"pre"===ty(e.parent())?ly(e,t):cy(e,t);if(!oy.includes(l))return ly(e,t);var D=dy(e),C=hy(e),w=Kg({},r);Object.keys(D).forEach(function(e){D[e]&&(w[e]=!0)});var E=Kg(Kg({},n||{}),C||{}),A=Array.from(u.childNodes),x=[];try{for(var B=Jg(A),S=B.next();!S.done;S=B.next()){var F;if((F=S.value).nodeType!==Node.TEXT_NODE){y=gy(ov(F),t,w,E);Array.isArray(y)?y.forEach(function(e){return x.push(e)}):x.push(y)}else{var k;""!==(k=F.nodeValue||"")&&x.push(fy({text:k},w,E))}}}catch(e){a={error:e}}finally{try{S&&!S.done&&(s=B.return)&&s.call(B)}finally{if(a)throw a.error}}if(0===x.length)return cy(e,t);var O=py(x);return 1===O.length?O[0]:O}function my(e,t,r){var n=ov(r);return!!n.attr(t)||(n.attr(t,"true"),e.on(hm,function(){n.removeAttr(t)}),!1)}function vy(e,t){void 0===t&&(t="");var r=[];""===t&&(t="<p><br></p>"),0!==t.indexOf("<")&&(t=t.split(/\n/).map(function(e){return"<p>".concat(e,"</p>")}).join(""));var n=ov("<div>".concat(t,"</div>"));return Array.from(n.children()).forEach(function(t){var n=gy(ov(t),e);Array.isArray(n)?n.forEach(function(e){return r.push(e)}):r.push(n)}),r}function yy(e,t){return"w-e-element-".concat(e,"-").concat(t)}var by=[];var Dy,Cy,wy={};function Ey(e,t,r){var n=r.isInline(e)?"span":"div";return"<".concat(n,">").concat(t,"</").concat(n,">")}function Ay(e,t){var r=e.type,n=void 0===r?"":r,o=e.children,i=void 0===o?[]:o,a=Yp.isVoid(t,e),s="";a||(s=i.map(function(e){return Ly(e,t)}).join(""));var u=function(e){return wy[e]||Ey}(n),l=u(e,s,t),c="";if(c="string"==typeof l?l:l.html||"",a||by.forEach(function(t){return c=t(e,c)}),"string"==typeof l)return c;var d=l.prefix,h=void 0===d?"":d,f=l.suffix,p=void 0===f?"":f;return h&&(c=h+c),p&&(c+=p),c}var xy=function(){if(Cy)return Dy;Cy=1;var e=9007199254740991,t="[object Arguments]",r="[object Map]",n="[object Promise]",o="[object Set]",i="[object WeakMap]",a="[object DataView]",s=/^\[object .+?Constructor\]$/,u=/^(?:0|[1-9]\d*)$/,l="\\ud800-\\udfff",c="\\u0300-\\u036f\\ufe20-\\ufe23",d="\\u20d0-\\u20f0",h="\\ufe0e\\ufe0f",f="["+l+"]",p="["+c+d+"]",g="\\ud83c[\\udffb-\\udfff]",m="[^"+l+"]",v="(?:\\ud83c[\\udde6-\\uddff]){2}",b="[\\ud800-\\udbff][\\udc00-\\udfff]",D="\\u200d",C="(?:"+p+"|"+g+")"+"?",w="["+h+"]?",E=w+C+("(?:"+D+"(?:"+[m,v,b].join("|")+")"+w+C+")*"),A="(?:"+[m+p+"?",p,v,b,f].join("|")+")",x=RegExp(g+"(?="+g+")|"+A+E,"g"),B=RegExp("["+D+l+c+d+h+"]"),S="object"==typeof y&&y&&y.Object===Object&&y,F="object"==typeof self&&self&&self.Object===Object&&self,k=S||F||Function("return this")();function O(e,t){return function(e,t){for(var r=-1,n=e?e.length:0,o=Array(n);++r<n;)o[r]=t(e[r],r,e);return o}(t,function(t){return e[t]})}function T(e){var t=-1,r=Array(e.size);return e.forEach(function(e,n){r[++t]=[n,e]}),r}function N(e){var t=-1,r=Array(e.size);return e.forEach(function(e){r[++t]=e}),r}function P(e){return function(e){return B.test(e)}(e)?function(e){return e.match(x)||[]}(e):function(e){return e.split("")}(e)}var M,I,R=Function.prototype,L=Object.prototype,_=k["__core-js_shared__"],z=function(){var e=/[^.]+$/.exec(_&&_.keys&&_.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""}(),j=R.toString,H=L.hasOwnProperty,V=L.toString,$=RegExp("^"+j.call(H).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),U=k.Symbol,q=U?U.iterator:void 0,W=L.propertyIsEnumerable,G=(M=Object.keys,I=Object,function(e){return M(I(e))}),Y=se(k,"DataView"),K=se(k,"Map"),X=se(k,"Promise"),Z=se(k,"Set"),J=se(k,"WeakMap"),Q=ce(Y),ee=ce(K),te=ce(X),re=ce(Z),ne=ce(J);function oe(e,r){var n=de(e)||function(e){return function(e){return ge(e)&&he(e)}(e)&&H.call(e,"callee")&&(!W.call(e,"callee")||V.call(e)==t)}(e)?function(e,t){for(var r=-1,n=Array(e);++r<e;)n[r]=t(r);return n}(e.length,String):[],o=n.length,i=!!o;for(var a in e)!H.call(e,a)||i&&("length"==a||le(a,o))||n.push(a);return n}function ie(e){if(!pe(e)||function(e){return!!z&&z in e}(e))return!1;var t=fe(e)||function(e){var t=!1;if(null!=e&&"function"!=typeof e.toString)try{t=!!(e+"")}catch(e){}return t}(e)?$:s;return t.test(ce(e))}function ae(e){if(r=(t=e)&&t.constructor,n="function"==typeof r&&r.prototype||L,t!==n)return G(e);var t,r,n,o=[];for(var i in Object(e))H.call(e,i)&&"constructor"!=i&&o.push(i);return o}function se(e,t){var r=function(e,t){return null==e?void 0:e[t]}(e,t);return ie(r)?r:void 0}var ue=function(e){return V.call(e)};function le(t,r){return!!(r=null==r?e:r)&&("number"==typeof t||u.test(t))&&t>-1&&t%1==0&&t<r}function ce(e){if(null!=e){try{return j.call(e)}catch(e){}try{return e+""}catch(e){}}return""}(Y&&ue(new Y(new ArrayBuffer(1)))!=a||K&&ue(new K)!=r||X&&ue(X.resolve())!=n||Z&&ue(new Z)!=o||J&&ue(new J)!=i)&&(ue=function(e){var t=V.call(e),s="[object Object]"==t?e.constructor:void 0,u=s?ce(s):void 0;if(u)switch(u){case Q:return a;case ee:return r;case te:return n;case re:return o;case ne:return i}return t});var de=Array.isArray;function he(t){return null!=t&&function(t){return"number"==typeof t&&t>-1&&t%1==0&&t<=e}(t.length)&&!fe(t)}function fe(e){var t=pe(e)?V.call(e):"";return"[object Function]"==t||"[object GeneratorFunction]"==t}function pe(e){var t=typeof e;return!!e&&("object"==t||"function"==t)}function ge(e){return!!e&&"object"==typeof e}function me(e){return e?O(e,function(e){return he(e)?oe(e):ae(e)}(e)):[]}return Dy=function(e){if(!e)return[];if(he(e))return function(e){return"string"==typeof e||!de(e)&&ge(e)&&"[object String]"==V.call(e)}(e)?P(e):function(e,t){var r=-1,n=e.length;for(t||(t=Array(n));++r<n;)t[r]=e[r];return t}(e);if(q&&e[q])return function(e){for(var t,r=[];!(t=e.next()).done;)r.push(t.value);return r}(e[q]());var t=ue(e);return(t==r?T:t==o?N:me)(e)},Dy}(),By=b(xy),Sy=0,Fy=function(){this.id="".concat(Sy++)},ky="undefined"!=typeof navigator&&/Mac OS X/.test(navigator.userAgent),Oy="undefined"!=typeof navigator&&/^(?!.*Seamonkey)(?=.*Firefox).*/i.test(navigator.userAgent),Ty="undefined"!=typeof navigator&&/^((?!chrome|android).)*safari/i.test(navigator.userAgent),Ny="undefined"!=typeof navigator&&/Edge?\/(?:[0-6][0-9]|[0-7][0-8])(?:\.)/i.test(navigator.userAgent),Py="undefined"!=typeof navigator&&/Chrome?\/(?:[0-7][0-5]|[0-6][0-9])(?:\.)/i.test(navigator.userAgent),My="undefined"!=typeof navigator&&/Chrome/i.test(navigator.userAgent),Iy=!Py&&!Ny&&"undefined"!=typeof globalThis&&globalThis.InputEvent&&"function"==typeof globalThis.InputEvent.prototype.getTargetRanges,Ry={getWindow:function(e){var t=Hm.get(e);if(!t)throw new Error("Unable to find a host window element for this editor");return t},findKey:function(e,t){var r=jm.get(t);return r||(r=new Fy,jm.set(t,r)),r},setNewKey:function(e){var t=new Fy;jm.set(e,t)},findPath:function(e,t){for(var r=[],n=t;;){var o=Im.get(n);if(null==o){if(Yp.isEditor(n))return r;break}var i=Mm.get(n);if(null==i)break;r.unshift(i),n=o}throw new Error("Unable to find the path for Slate node: ".concat(JSON.stringify(t)))},findDocumentOrShadowRoot:function(e){if(e.isDestroyed)return window.document;var t=Ry.toDOMNode(e,e),r=t.getRootNode();return"[object HTMLDocument]"!==Vv(r)&&!function(e){return"[object ShadowRoot]"===Vv(e)}(r)||null==Reflect.get(r,"getSelection")?t.ownerDocument:r},getParentNode:function(e,t){return Im.get(t)||null},getParentsNodes:function(e,t){for(var r=[],n=t;n!==e&&null!=n;){var o=Ry.getParentNode(e,n);if(null==o)break;r.push(o),n=o}return r},getTopNode:function(e,t){var r=[Ry.findPath(e,t)[0]];return eg.get(e,r)},toDOMNode:function(e,t){var r;if(Yp.isEditor(t))r=Rm.get(e);else{var n=Ry.findKey(e,t);r=_m.get(n)}if(!r)throw new Error("Cannot resolve a DOM node from Slate node: ".concat(JSON.stringify(t)));return r},hasDOMNode:function(e,t,r){void 0===r&&(r={});var n,o=r.editable,i=void 0!==o&&o,a=Ry.toDOMNode(e,e);try{n=Gv(t)?t:t.parentElement}catch(e){if(e instanceof Error&&!e.message.includes('Permission denied to access property "nodeType"'))throw e}return!!n&&(n.closest("[data-slate-editor]")===a&&(!i||n.isContentEditable||!!n.getAttribute("data-slate-zero-width"))||!!n.getAttribute("data-slate-string"))},toDOMRange:function(e,t){var r=t.anchor,n=t.focus,o=hg.isBackward(t),i=Ry.toDOMPoint(e,r),a=hg.isCollapsed(t)?i:Ry.toDOMPoint(e,n),s=Ry.getWindow(e).document.createRange(),u=Qg(o?a:i,2),l=u[0],c=u[1],d=Qg(o?i:a,2),h=d[0],f=d[1],p=!!(Gv(l)?l:l.parentElement).getAttribute("data-slate-zero-width"),g=!!(Gv(h)?h:h.parentElement).getAttribute("data-slate-zero-width");return s.setStart(l,p?1:c),s.setEnd(h,g?1:f),s},toDOMPoint:function(e,t){var r,n,o,i=Qg(Yp.node(e,t.path),1)[0],a=Ry.toDOMNode(e,i);Yp.void(e,{at:t})&&(t={path:t.path,offset:0});var s=Array.from(a.querySelectorAll("[data-slate-string], [data-slate-zero-width]")),u=0;try{for(var l=Jg(s),c=l.next();!c.done;c=l.next()){var d=c.value,h=d.childNodes[0];if(null!=h&&null!=h.textContent){var f=h.textContent.length,p=d.getAttribute("data-slate-length"),g=u+(null==p?f:parseInt(p,10));if(t.offset<=g){o=[h,Math.min(f,Math.max(0,t.offset-u))];break}u=g}}}catch(e){r={error:e}}finally{try{c&&!c.done&&(n=l.return)&&n.call(l)}finally{if(r)throw r.error}}if(!o)throw new Error("Cannot resolve a DOM point from Slate point: ".concat(JSON.stringify(t)));return o},toSlateNode:function(e,t){var r=Gv(t)?t:t.parentElement;r&&!r.hasAttribute("data-slate-node")&&(r=r.closest("[data-slate-node]"));var n=r?Lm.get(r):null;if(!n)throw new Error("Cannot resolve a Slate node from DOM node: ".concat(r));return n},findEventRange:function(e,t){"nativeEvent"in t&&(t=t.nativeEvent);var r=t.clientX,n=t.clientY,o=t.target;if(null==r||null==n)throw new Error("Cannot resolve a Slate range from a DOM event: ".concat(t));var i,a=Ry.toSlateNode(e,t.target),s=Ry.findPath(e,a);if(Yp.isVoid(e,a)){var u=o.getBoundingClientRect(),l=e.isInline(a)?r-u.left<u.left+u.width-r:n-u.top<u.top+u.height-n,c=Yp.point(e,s,{edge:l?"start":"end"}),d=l?Yp.before(e,c):Yp.after(e,c);if(d)return Yp.range(e,d)}var h=this.getWindow(e).document;if(h.caretRangeFromPoint)i=h.caretRangeFromPoint(r,n);else{var f=h.caretPositionFromPoint(r,n);f&&((i=h.createRange()).setStart(f.offsetNode,f.offset),i.setEnd(f.offsetNode,f.offset))}if(!i)throw new Error("Cannot resolve a Slate range from a DOM event: ".concat(t));return Ry.toSlateRange(e,i,{exactMatch:!1,suppressThrow:!1})},toSlateRange:function(e,t,r){var n,o,i,a,s,u=r.exactMatch,l=r.suppressThrow;if((Yv(t)?t.anchorNode:t.startContainer)&&(Yv(t)?(n=t.anchorNode,o=t.anchorOffset,i=t.focusNode,a=t.focusOffset,s=My&&window.document.activeElement&&window.document.activeElement.shadowRoot?t.anchorNode===t.focusNode&&t.anchorOffset===t.focusOffset:t.isCollapsed):(n=t.startContainer,o=t.startOffset,i=t.endContainer,a=t.endOffset,s=t.collapsed)),null==n||null==i||null==o||null==a)throw new Error("Cannot resolve a Slate range from DOM range: ".concat(t));var c=Ry.toSlatePoint(e,[n,o],{exactMatch:u,suppressThrow:l});if(!c)return null;var d=s?c:Ry.toSlatePoint(e,[i,a],{exactMatch:u,suppressThrow:l});if(!d)return null;var h={anchor:c,focus:d};return hg.isExpanded(h)&&hg.isForward(h)&&Gv(i)&&Yp.void(e,{at:h.focus,mode:"highest"})&&(h=Yp.unhangRange(e,h,{voids:!0})),h},toSlatePoint:function(e,t,r){var n,o=r.exactMatch,i=r.suppressThrow,a=Qg(o?t:function(e){var t,r=Qg(e,2),n=r[0],o=r[1];if(Gv(n)&&n.childNodes.length){var i=o===n.childNodes.length,a=i?o-1:o;for(n=(t=Qg(Zv(n,a,i?"backward":"forward"),2))[0],i=(a=t[1])<o;Gv(n)&&n.childNodes.length;){var s=i?n.childNodes.length-1:0;n=Jv(n,s,i?"backward":"forward")}o=i&&null!=n.textContent?n.textContent.length:0}return[n,o]}(t),2),s=a[0],u=a[1],l=s.parentNode,c=null,d=0;if(l){var h=l.closest('[data-slate-void="true"]'),f=l.closest("[data-slate-leaf]"),p=null,g=Ry.getWindow(e);if(f&&g.document.createRange){c=f.closest('[data-slate-node="text"]');var m=g.document.createRange();m.setStart(c,0),m.setEnd(s,u);var v=m.cloneContents();em(em([],Qg(By(v.querySelectorAll("[data-slate-zero-width]"))),!1),Qg(By(v.querySelectorAll("[contenteditable=false]"))),!1).forEach(function(e){e.parentNode.removeChild(e)}),d=v.textContent.length,p=c}else h&&((f=h.querySelector("[data-slate-leaf]"))?(c=f.closest('[data-slate-node="text"]'),d=(p=f).textContent.length,p.querySelectorAll("[data-slate-zero-width]").forEach(function(e){d-=e.textContent.length})):d=1);p&&d===p.textContent.length&&(l.hasAttribute("data-slate-zero-width")||Oy&&(null===(n=p.textContent)||void 0===n?void 0:n.endsWith("\n")))&&(d-=1)}if(!c){if(i)return null;throw new Error("Cannot resolve a Slate point from DOM point: ".concat(t))}var y=Ry.toSlateNode(e,c);return{path:Ry.findPath(e,y),offset:d}},hasRange:function(e,t){var r=t.anchor,n=t.focus;return Yp.hasPath(e,r.path)&&Yp.hasPath(e,n.path)},getNodeType:function(e){return Vp.isElement(e)?e.type:""},checkNodeType:function(e,t){return this.getNodeType(e)===t},getNodesStr:function(e){return e.map(function(e){return eg.string(e)}).join("")},getSelectedElems:function(e){var t,r,n=[],o=Yp.nodes(e,{universal:!0});try{for(var i=Jg(o),a=i.next();!a.done;a=i.next()){var s=Qg(a.value,1)[0];Vp.isElement(s)&&n.push(s)}}catch(e){t={error:e}}finally{try{a&&!a.done&&(r=i.return)&&r.call(i)}finally{if(t)throw t.error}}return n},getSelectedNodeByType:function(e,t){var r=this,n=Qg(Yp.nodes(e,{match:function(e){return r.checkNodeType(e,t)},universal:!0}),1),o=n[0];return null==o?null:o[0]},getSelectedTextNode:function(e){var t=Qg(Yp.nodes(e,{match:function(e){return Cg.isText(e)},universal:!0}),1),r=t[0];return null==r?null:r[0]},isNodeSelected:function(e,t){var r=Qg(Yp.nodes(e,{match:function(e){return e===t},universal:!0}),1),n=r[0];return null!=n&&Qg(n,1)[0]===t},isSelectionAtLineEnd:function(e,t){var r=e.selection;return!!r&&(Yp.isEnd(e,r.anchor,t)||Yp.isEnd(e,r.focus,t))},getTextarea:function(e){var t=bm.get(e);if(null==t)throw new Error("Cannot find textarea instance by editor");return t},getToolbar:function(e){return wm.get(e)||null},getHoverbar:function(e){return Am.get(e)||null},normalizeContent:function(e){e.children.forEach(function(t,r){e.normalizeNode([t,[r]])})},getLeftLengthOfMaxLength:function(e){var t=e.getConfig(),r=t.maxLength,n=t.onMaxLength;if("number"!=typeof r||r<=0)return 1/0;var o=r-e.getText().replace(/\r|\n|(\r\n)|(\n\r)/g,"").length;return o<=0&&n&&n(e),o},cleanExposedTexNodeInSelectionBlock:function(e){var t,r,n,o,i=Ry.getTextarea(e).$textArea,a=null==i?void 0:i[0].childNodes;if(a)try{for(var s=Jg(Array.from(a)),u=s.next();!u.done;u=s.next()){var l=u.value;if(!Kv(l))break;l.remove()}}catch(e){t={error:e}}finally{try{u&&!u.done&&(r=s.return)&&r.call(s)}finally{if(t)throw t.error}}var c=Yp.nodes(e,{match:function(t){return!(!Vp.isElement(t)||e.isInline(t))},universal:!0});try{for(var d=Jg(c),h=d.next();!h.done;h=d.next()){var f=h.value;if(null!=f){var p=f[0];ey(Ry.toDOMNode(e,p),function(e,t){var r=ov(t);r.attr("data-slate-string")||r.attr("data-slate-zero-width")||r.attr("data-w-e-reserve")||t.removeChild(e)})}}}catch(e){n={error:e}}finally{try{h&&!h.done&&(o=d.return)&&o.call(d)}finally{if(n)throw n.error}}},isLastNode:function(e,t){var r=e.children||[];return r[r.length-1]===t},genEmptyParagraph:function(){return{type:"paragraph",children:[{text:""}]}},isSelectedVoidNode:function(e){var t,r,n=Yp.nodes(e,{match:function(t){return e.isVoid(t)}}),o=0;try{for(var i=Jg(n),a=i.next();!a.done;a=i.next()){a.value&&(o+=1)}}catch(e){t={error:e}}finally{try{a&&!a.done&&(r=i.return)&&r.call(i)}finally{if(t)throw t.error}}return o>0},isSelectedEmptyParagraph:function(e){var t=e.selection;if(null==t)return!1;if(hg.isExpanded(t))return!1;var r=Ry.getSelectedNodeByType(e,"paragraph");if(null===r)return!1;var n=r.children;return 1===n.length&&(""===n[0].text||void 0)},isEmptyPath:function(e,t){var r=Yp.node(e,t);if(null==r)return!1;var n=Qg(r,1)[0].children;if(1===n.length&&""===n[0].text)return!0;return!1}};function Ly(e,t){return Vp.isElement(e)?Ay(e,t):function(e,t){var r=e.text;if(null==r)throw new Error("Current node is not slate Text ".concat(JSON.stringify(e)));var n=r;n=function(e){return e.replace(/ {2}/g," ").replace(/</g,"<").replace(/>/g,">").replace(/®/g,"®").replace(/©/g,"©").replace(/™/g,"™")}(n);var o=Ry.getParentsNodes(t,e).some(function(e){return"pre"===Ry.getNodeType(e)});if(o||(n=n.replace(/\n\r|\r\n|\r|\n/g,"<br>")),o&&(n=n.replace(/ /g," ")),""===n){var i=Ry.getParentNode(null,e);if(!i||0!==i.children.length)return n;n="<br>"}return by.forEach(function(t){return n=t(e,n)}),n}(e,t)}var _y=function(e,t){var r=(t.top+t.bottom)/2;return e.top<=r&&e.bottom>=r},zy=function(e,t,r){var n=Ry.toDOMRange(e,t).getBoundingClientRect(),o=Ry.toDOMRange(e,r).getBoundingClientRect();return _y(n,o)&&_y(o,n)},jy=function(e,t){var r,n,o=[];try{for(var i=Jg(Yp.levels(e,{at:t})),a=i.next();!a.done;a=i.next()){var s=Qg(a.value,2),u=s[0],l=s[1],c=Ry.findKey(e,u);o.push([l,c])}}catch(e){r={error:e}}finally{try{a&&!a.done&&(n=i.return)&&n.call(i)}finally{if(r)throw r.error}}return o};function Hy(e,t){e.isInline(t)?(e.insertNode(t),"link"===t.type&&e.insertFragment([{text:""}])):zg.insertNodes(e,t,{mode:"highest"})}var Vy,$y,Uy,qy,Wy,Gy,Yy,Ky,Xy,Zy,Jy,Qy,eb,tb,rb,nb,ob,ib,ab,sb,ub,lb,cb,db,hb,fb,pb,gb,mb,vb,yb,bb,Db,Cb,wb,Eb,Ab,xb,Bb,Sb,Fb=function(e){var t=e,r=t.onChange,n=t.insertText,o=t.apply,i=t.deleteBackward;return t.insertText=function(e){t.getConfig().readOnly||n(e)},t.apply=function(e){var r,n,i,a,s,u,l,c,d=[];switch(e.type){case"insert_text":case"remove_text":case"set_node":case"split_node":d.push.apply(d,em([],Qg(jy(t,e.path)),!1));break;case"insert_node":case"remove_node":d.push.apply(d,em([],Qg(jy(t,og.parent(e.path))),!1));break;case"merge_node":var h=og.previous(e.path);d.push.apply(d,em([],Qg(jy(t,h)),!1));break;case"move_node":var f=og.common(og.parent(e.path),og.parent(e.newPath));d.push.apply(d,em([],Qg(jy(t,f)),!1));break;case"set_selection":(null===(a=null===(i=e.newProperties)||void 0===i?void 0:i.focus)||void 0===a?void 0:a.path)&&(d.push.apply(d,em([],Qg(jy(t,null===(u=null===(s=e.newProperties)||void 0===s?void 0:s.focus)||void 0===u?void 0:u.path)),!1)),d.push.apply(d,em([],Qg(jy(t,null===(c=null===(l=e.properties)||void 0===l?void 0:l.focus)||void 0===c?void 0:c.path)),!1)))}o(e);try{for(var p=Jg(d),g=p.next();!g.done;g=p.next()){var m=Qg(g.value,2),v=m[0],y=m[1],b=Qg(Yp.node(t,v),1)[0];jm.set(b,y),"type"in b&&(Nm.has(b)&&Nm.delete(b),Pm.has(b)&&Pm.delete(b))}}catch(e){r={error:e}}finally{try{g&&!g.done&&(n=p.return)&&n.call(p)}finally{if(r)throw r.error}}},t.deleteBackward=function(r){if("line"!==r)return i(r);if(e.selection&&hg.isCollapsed(e.selection)){var n=Yp.above(e,{match:function(t){return Yp.isBlock(e,t)},at:e.selection});if(n){var o=Qg(n,2)[1],a=Yp.range(e,o,e.selection.anchor),s=function(e,t){var r=Yp.range(e,hg.end(t)),n=Array.from(Yp.positions(e,{at:t})),o=0,i=n.length,a=Math.floor(i/2);if(zy(e,Yp.range(e,n[o]),r))return Yp.range(e,n[o],r);if(n.length<2)return Yp.range(e,n[n.length-1],r);for(;a!==n.length&&a!==o;)zy(e,Yp.range(e,n[a]),r)?i=a:o=a,a=Math.floor((o+i)/2);return Yp.range(e,n[i],r)}(t,a);hg.isCollapsed(s)||zg.delete(e,{at:s})}}},t.onChange=function(){var e=t.selection;null!=e&&$m.set(t,e),t.emit("change"),r()},t.handleTab=function(){t.insertText(" ")},t.getHtml=function(){var e=t.children,r=void 0===e?[]:e,n=t.getConfig().skipCacheTypes,o=void 0===n?["list-item"]:n;return r.map(function(e){var r=Ry.getNodeType(e);if(o.includes(r))return Ly(e,t);var n=Pm.get(e);if(n)return n;var i=Ly(e,t);return Pm.set(e,i),i}).join("")},t.getText=function(){var e=t.children;return(void 0===e?[]:e).map(function(e){return eg.string(e)}).join("\n")},t.getSelectionText=function(){var r=t.selection;return null==r?"":Yp.string(e,r)},t.getElemsByType=function(e,r){var n,o;void 0===r&&(r=!1);var i=[],a=Yp.nodes(t,{at:[],universal:!0});try{for(var s=Jg(a),u=s.next();!u.done;u=s.next()){var l=Qg(u.value,1)[0];if(Vp.isElement(l))if(r?l.type.indexOf(e)>=0:l.type===e){var c=Ry.findKey(t,l),d=yy(l.type,c.id);i.push(Kg(Kg({},l),{id:d}))}}}catch(e){n={error:e}}finally{try{u&&!u.done&&(o=s.return)&&o.call(s)}finally{if(n)throw n.error}}return i},t.getElemsByTypePrefix=function(e){return t.getElemsByType(e,!0)},t.isEmpty=function(){var e=t.children,r=void 0===e?[]:e;if(r.length>1)return!1;var n=r[0];if(null==n)return!0;if(!Vp.isElement(n)||"paragraph"!==n.type)return!1;var o=n.children,i=void 0===o?[]:o;if(i.length>1)return!1;var a=i[0];return null==a||Cg.isText(a)&&""===a.text},t.clear=function(){zg.delete(t,{at:{anchor:Yp.start(t,[]),focus:Yp.end(t,[])}}),0===t.children.length&&zg.insertNodes(t,[{type:"paragraph",children:[{text:""}]}])},t.getParentNode=function(e){return Ry.getParentNode(t,e)},t.dangerouslyInsertHtml=function(e,r){if(void 0===e&&(e=""),void 0===r&&(r=!1),e){var n=document.createElement("div");n.innerHTML=e;var o=Array.from(n.childNodes);if(o=o.filter(function(e){var t=e.nodeName;return!!Kv(e)||!!Gv(e)&&!Gm.has(t.toLowerCase())}),0!==o.length){var i=t.selection;if(null!=i){var a=null;if(Ry.isSelectedEmptyParagraph(t)&&!r)a=[i.focus.path[0]];n.setAttribute("hidden","true"),document.body.appendChild(n);var s=0;o.forEach(function(e,r){var n=e.nodeName,i=e.textContent,a=void 0===i?"":i;if(Kv(e)){if(!a||!a.trim())return;t.insertNode({text:a})}else if("BR"!==n){var u=e,l=!1;if(oy.includes(n.toLowerCase()))l=!0;else for(var c in ay)if(u.matches(c)){l=!0;break}if(l){var d=gy(ov(u),t);return Array.isArray(d)?(d.forEach(function(e){return Hy(t,e)}),s+=1):(Hy(t,d),s+=1),void(Ry.isSelectedVoidNode(t)&&t.move(1))}var h=window.getComputedStyle(u).display;if(!Ry.isSelectedEmptyParagraph(t)&&h.indexOf("inline")<0){if(r>=1)(function(e){return"matches"in e&&/^[ou]l$/i.test(e.tagName)&&!e.hasAttribute("data-w-e-type")})(o[r-1])&&t.insertBreak();t.insertBreak()}t.dangerouslyInsertHtml(u.innerHTML,!0)}else t.insertText("\n")}),s&&a&&Ry.isEmptyPath(t,a)&&zg.removeNodes(t,{at:a}),n.remove()}}}},t.setHtml=function(e){void 0===e&&(e="");var r=t.isDisabled(),n=t.isFocused(),o=JSON.stringify(t.selection);t.enable(),t.focus(),t.clear();var i=vy(t,null==e?"":e);if(zg.insertFragment(t,i),n||(t.deselect(),t.blur()),r&&(t.deselect(),t.disable()),t.isFocused())try{t.select(JSON.parse(o))}catch(e){t.select(Yp.start(t,[]))}},t},kb=1,Ob=function(e){var t=e;return t.id="wangEditor-".concat(kb++),t.isDestroyed=!1,t.isFullScreen=!1,t.focus=function(e){if(Ry.toDOMNode(t,t).focus({preventScroll:!0}),Vm.set(t,!0),e){var r=Yp.end(t,[]);zg.select(t,r)}else{var n=$m.get(t);n?zg.select(t,n):zg.select(t,Yp.start(t,[]))}},t.isFocused=function(){return!!Vm.get(t)},t.blur=function(){Ry.toDOMNode(t,t).blur(),zg.deselect(t),Vm.set(t,!1)},t.updateView=function(){Ry.getTextarea(t).changeViewState();var e=Ry.getToolbar(t);e&&e.changeToolbarState();var r=Ry.getHoverbar(t);r&&r.changeHoverbarState()},t.destroy=function(){if(!t.isDestroyed){var e=Ry.getTextarea(t);e.destroy(),bm.delete(t),Dm.delete(e);var r=Ry.getToolbar(t);r&&(r.destroy(),wm.delete(t),Cm.delete(r));var n=Ry.getHoverbar(t);n&&(n.destroy(),Am.delete(t),Em.delete(n)),t.isDestroyed=!0,t.emit("destroyed")}},t.scrollToElem=function(e){if(!t.getConfig().scroll){var r="编辑器禁用了 scroll ,编辑器内容无法滚动,请自行实现该功能";return r+="\nYou has disabled editor scroll, please do this yourself",void console.warn(r)}var n=ov("#".concat(e));if(0!==n.length){var o=n[0];if(!Ry.hasDOMNode(t,o)){r="Element (found by id is '".concat(e,"') is not in editor DOM");return r+="\n 通过 id '".concat(e,"' 找到的 element 不在 editor DOM 之内"),void console.error(r,o)}var i=Ry.getTextarea(t),a=i.$textAreaContainer,s=i.$scroll,u=n.offset().top,l=a.offset().top;s[0].scrollBy({top:u-l,behavior:"smooth"})}},t.showProgressBar=function(e){e<1||Ry.getTextarea(t).changeProgress(e)},t.hidePanelOrModal=function(){var e=Bm.get(t);null!=e&&e.forEach(function(e){return e.hide()})},t.enable=function(){t.getConfig().readOnly=!1,t.updateView()},t.disable=function(){t.getConfig().readOnly=!0,t.updateView()},t.isDisabled=function(){return t.getConfig().readOnly},t.toDOMNode=function(e){return Ry.toDOMNode(t,e)},t.fullScreen=function(){if(!t.isFullScreen){var e=null,r=Ry.getToolbar(t);r&&(e=r.$box);var n=Ry.getTextarea(t).$box.parent();if(e&&e.parent()[0]!==n[0]){throw new Error("Can not set full screen, cause toolbar DOM parent is not equal to textarea DOM parent\n不能设置全屏,因为 toolbar DOM 父节点和 textarea DOM 父节点不一致")}n.addClass("w-e-full-screen-container");var o=n.css("z-index");n.attr("data-z-index",o.toString()),t.isFullScreen=!0,t.emit("fullScreen")}},t.unFullScreen=function(){if(t.isFullScreen){var e=Ry.getTextarea(t).$box.parent();setTimeout(function(){e.removeClass("w-e-full-screen-container"),t.isFullScreen=!1,t.emit("unFullScreen")},200)}},t.getEditableContainer=function(){return Ry.getTextarea(t).$textAreaContainer[0]},t},Tb={exports:{}},Nb={exports:{}};function Pb(){if($y)return Vy;$y=1;return Vy=function(e){return null!=e}}function Mb(){if(Gy)return Wy;Gy=1;var e=function(){if(qy)return Uy;qy=1;var e=Pb(),t={object:!0,function:!0,undefined:!0};return Uy=function(r){return!!e(r)&&hasOwnProperty.call(t,typeof r)}}();return Wy=function(t){if(!e(t))return!1;try{return!!t.constructor&&t.constructor.prototype===t}catch(e){return!1}}}function Ib(){if(Zy)return Xy;Zy=1;var e=function(){if(Ky)return Yy;Ky=1;var e=Mb();return Yy=function(t){if("function"!=typeof t)return!1;if(!hasOwnProperty.call(t,"length"))return!1;try{if("number"!=typeof t.length)return!1;if("function"!=typeof t.call)return!1;if("function"!=typeof t.apply)return!1}catch(e){return!1}return!e(t)}}(),t=/^\s*class[\s{/}]/,r=Function.prototype.toString;return Xy=function(n){return!!e(n)&&!t.test(r.call(n))}}function Rb(){if(ib)return ob;ib=1;var e=(nb?rb:(nb=1,rb=function(){}))();return ob=function(t){return t!==e&&null!==t},ob}function Lb(){return lb||(lb=1,ub=(tb?eb:(tb=1,eb=function(){try{return Object.keys("primitive"),!0}catch(e){return!1}}))()?Object.keys:function(){if(sb)return ab;sb=1;var e=Rb(),t=Object.keys;return ab=function(r){return t(e(r)?Object(r):r)}}()),ub}function _b(){if(fb)return hb;fb=1;var e=Lb(),t=function(){if(db)return cb;db=1;var e=Rb();return cb=function(t){if(!e(t))throw new TypeError("Cannot use null or undefined");return t}}(),r=Math.max;return hb=function(n,o){var i,a,s,u=r(arguments.length,2);for(n=Object(t(n)),s=function(e){try{n[e]=o[e]}catch(e){i||(i=e)}},a=1;a<u;++a)e(o=arguments[a]).forEach(s);if(void 0!==i)throw i;return n},hb}function zb(){return gb?pb:(gb=1,pb=(Qy||(Qy=1,Jy=function(){var e,t=Object.assign;return"function"==typeof t&&(t(e={foo:"raz"},{bar:"dwa"},{trzy:"trzy"}),e.foo+e.bar+e.trzy==="razdwatrzy")}),Jy)()?Object.assign:_b())}function jb(){return Eb||(Eb=1,wb=function(){if(bb)return yb;bb=1;var e="razdwatrzy";return yb=function(){return"function"==typeof e.contains&&!0===e.contains("dwa")&&!1===e.contains("foo")}}()()?String.prototype.contains:function(){if(Cb)return Db;Cb=1;var e=String.prototype.indexOf;return Db=function(t){return e.call(this,t,arguments[1])>-1},Db}()),wb}function Hb(){if(Ab)return Nb.exports;Ab=1;var e=Pb(),t=Ib(),r=zb(),n=function(){if(vb)return mb;vb=1;var e=Rb(),t=Array.prototype.forEach,r=Object.create;return mb=function(n){var o=r(null);return t.call(arguments,function(t){e(t)&&function(e,t){var r;for(r in e)t[r]=e[r]}(Object(t),o)}),o},mb}(),o=jb(),i=Nb.exports=function(t,i){var a,s,u,l,c;return arguments.length<2||"string"!=typeof t?(l=i,i=t,t=null):l=arguments[2],e(t)?(a=o.call(t,"c"),s=o.call(t,"e"),u=o.call(t,"w")):(a=u=!0,s=!1),c={value:i,configurable:a,enumerable:s,writable:u},l?r(n(l),c):c};return i.gs=function(i,a,s){var u,l,c,d;return"string"!=typeof i?(c=s,s=a,a=i,i=null):c=arguments[3],e(a)?t(a)?e(s)?t(s)||(c=s,s=void 0):s=void 0:(c=a,a=s=void 0):a=void 0,e(i)?(u=o.call(i,"c"),l=o.call(i,"e")):(u=!0,l=!1),d={get:a,set:s,configurable:u,enumerable:l},c?r(n(c),d):d},Nb.exports}var Vb=(Sb||(Sb=1,function(e,t){var r,n,o,i,a,s,u,l=Hb(),c=(Bb||(Bb=1,xb=function(e){if("function"!=typeof e)throw new TypeError(e+" is not a function");return e}),xb),d=Function.prototype.apply,h=Function.prototype.call,f=Object.create,p=Object.defineProperty,g=Object.defineProperties,m=Object.prototype.hasOwnProperty,v={configurable:!0,enumerable:!1,writable:!0};r=function(e,t){var r;return c(t),m.call(this,"__ee__")?r=this.__ee__:(r=v.value=f(null),p(this,"__ee__",v),v.value=null),r[e]?"object"==typeof r[e]?r[e].push(t):r[e]=[r[e],t]:r[e]=t,this},n=function(e,t){var n,i;return c(t),i=this,r.call(this,e,n=function(){o.call(i,e,n),d.call(t,this,arguments)}),n.__eeOnceListener__=t,this},o=function(e,t){var r,n,o,i;if(c(t),!m.call(this,"__ee__"))return this;if(!(r=this.__ee__)[e])return this;if("object"==typeof(n=r[e]))for(i=0;o=n[i];++i)o!==t&&o.__eeOnceListener__!==t||(2===n.length?r[e]=n[i?0:1]:n.splice(i,1));else n!==t&&n.__eeOnceListener__!==t||delete r[e];return this},i=function(e){var t,r,n,o,i;if(m.call(this,"__ee__")&&(o=this.__ee__[e]))if("object"==typeof o){for(r=arguments.length,i=new Array(r-1),t=1;t<r;++t)i[t-1]=arguments[t];for(o=o.slice(),t=0;n=o[t];++t)d.call(n,this,i)}else switch(arguments.length){case 1:h.call(o,this);break;case 2:h.call(o,this,arguments[1]);break;case 3:h.call(o,this,arguments[1],arguments[2]);break;default:for(r=arguments.length,i=new Array(r-1),t=1;t<r;++t)i[t-1]=arguments[t];d.call(o,this,i)}},a={on:r,once:n,off:o,emit:i},s={on:l(r),once:l(n),off:l(o),emit:l(i)},u=g({},s),e.exports=t=function(e){return null==e?f(u):g(Object(e),s)},t.methods=a}(Tb,Tb.exports)),Tb.exports),$b=b(Vb);function Ub(e){var t=Um.get(e);return null==t&&(t=$b(),Um.set(e,t)),t}var qb=new WeakMap;function Wb(e,t){var r=qb.get(e);null==r&&(r=new Set,qb.set(e,r)),r.add(t)}var Gb=function(e){var t=e;return t.on=function(e,r){var n=Ub(t);if(n.on(e,r),"destroyed"===e&&Wb(t,r),"destroyed"!==e){var o=function(){return n.off(e,r)};n.on("destroyed",o),Wb(t,o)}},t.once=function(e,r){Ub(t).once(e,r)},t.off=function(e,r){Ub(t).off(e,r)},t.emit=function(e){for(var r=[],n=1;n<arguments.length;n++)r[n-1]=arguments[n];var o=Ub(t);if(o.emit.apply(o,em([e],Qg(r),!1)),"destroyed"===e){var i=function(e){return qb.get(e)||new Set}(t);i.forEach(function(e){return o.off("destroyed",e)}),function(e){qb.set(e,new Set)}(t)}},t},Yb=function(e){var t=e;return t.setFragmentData=function(e){var r=t.selection;if(r){var n=Qg(hg.edges(r),2),o=n[0],i=n[1],a=Yp.void(t,{at:o.path}),s=Yp.void(t,{at:i.path});if(!hg.isCollapsed(r)||a){var u=Ry.toDOMRange(t,r),l=u.cloneContents(),c=l.childNodes[0];if(l.childNodes.forEach(function(e){e.textContent&&""!==e.textContent.trim()&&(c=e)}),s){var d=Qg(s,1)[0],h=u.cloneRange(),f=Ry.toDOMNode(t,d);h.setEndAfter(f),l=h.cloneContents()}if(a&&(c=l.querySelector("[data-slate-spacer]")),Array.from(l.querySelectorAll("[data-slate-zero-width]")).forEach(function(e){var t="n"===e.getAttribute("data-slate-zero-width");e.textContent=t?"\n":""}),Kv(c)){var p=c.ownerDocument.createElement("span");p.style.whiteSpace="pre",p.appendChild(c),l.appendChild(p),c=p}var g=t.getFragment(),m=JSON.stringify(g),v=window.btoa(encodeURIComponent(m));c.setAttribute("data-slate-fragment",v),e.setData("application/x-slate-fragment",v);var y=l.ownerDocument.createElement("div");return y.appendChild(l),y.setAttribute("hidden","true"),l.ownerDocument.body.appendChild(y),e.setData("text/html",y.innerHTML),e.setData("text/plain",Qv(y)),l.ownerDocument.body.removeChild(y),e}}},t.insertData=function(e){var r,n,o=e.getData("application/x-slate-fragment");if(o){var i=decodeURIComponent(window.atob(o)),a=JSON.parse(i);t.insertFragment(a)}else{var s=e.getData("text/plain"),u=e.getData("text/html");if(u)t.dangerouslyInsertHtml(u);else if(s){var l=s.split(/\n\r|\r\n|\r|\n/),c=!1;try{for(var d=Jg(l),h=d.next();!h.done;h=d.next()){var f=h.value,p=Ry.getLeftLengthOfMaxLength(t);c&&p>0&&zg.splitNodes(t,{always:!0}),t.insertText(f),c=!0}}catch(e){r={error:e}}finally{try{h&&!h.done&&(n=d.return)&&n.call(d)}finally{if(r)throw r.error}}}}},t},Kb=function(e){var t=e,r=t.insertText,n=t.insertNode,o=t.insertFragment,i=t.dangerouslyInsertHtml;return t.insertText=function(e){if(t.getConfig().maxLength){var n=Ry.getLeftLengthOfMaxLength(t);n<=0||(n<e.length?r(e.slice(0,n)):r(e))}else r(e)},t.insertNode=function(e){if(t.getConfig().maxLength){var r=Ry.getLeftLengthOfMaxLength(t);if(!(r<=0))r<eg.string(e).length||n(e)}else n(e)},t.insertFragment=function(e){if(t.getConfig().maxLength){if(e.length>0){var r=e[0];if(Ry.getLeftLengthOfMaxLength(t)<eg.string(r).length)return;o([r]);for(var n=1;n<e.length;n+=1)t.insertNode(e[n])}}else o(e)},t.dangerouslyInsertHtml=function(e,r){if(void 0===e&&(e=""),void 0===r&&(r=!1),e)if(t.getConfig().maxLength){var n=Ry.getLeftLengthOfMaxLength(t);if(!(n<=0)){var o=document.createElement("div");o.innerHTML=e,n<Array.from(o.childNodes).reduce(function(e,t){var r=t.nodeName;return t?Kv(t)?e+(t.textContent||""):Gv(t)?Gm.has(r.toLowerCase())?e:e+(t.textContent||""):e:e},"").length||i(e,r)}}else i(e,r)},t};function Xb(e){var t=Ry.getTextarea(e).$textAreaContainer,r=t.width(),n=t.height(),o=t.offset();return{top:o.top,left:o.left,width:r,height:n}}function Zb(e){var t={top:"0",left:"0"},r=e.selection;if(null==r)return t;var n=Xb(e);if(null==n)return t;var o=n.top,i=n.left,a=n.width,s=n.height,u=Ry.toDOMRange(e,r).getClientRects(),l=u?u[0]:null;if(null==l)return t;var c={},d=l.top-o,h=l.left-i;if(h>a/2){var f=a-h;c.right="".concat(f+5,"px")}else c.left="".concat(h+5,"px");if(d>s/2){var p=s-d;c.bottom="".concat(p+5,"px")}else{var g=u[u.length-1],m=g.top-o+g.height;m<0&&(m=0),c.top="".concat(m+5,"px")}return c}function Jb(e,t,r){void 0===r&&(r="modal");var n={top:"0",left:"0"};if(null==e.selection)return n;var o=Vp.isElement(t)&&e.isVoid(t),i=Vp.isElement(t)&&e.isInline(t),a=zm.get(t);if(null==a)return n;var s=a.getBoundingClientRect(),u=s.top,l=s.left,c=s.height,d=s.width;if(o){var h=function(e){var t=[];t.push(e);for(var r=0;t.length>0;){var n=t.pop();if(null==n)break;if((r+=1)>1e4)break;var o=n.nodeName;if(n.nodeType===Hv.ELEMENT_NODE){var i=o.toLowerCase();if(_v.includes(i)||"iframe"===i||"video"===i)return n;var a=n.children||[],s=a.length;if(s)for(var u=s-1;u>=0;u-=1)t.push(a[u])}}return null}(a);if(null!=h){var f=h.getBoundingClientRect();u=f.top,c=f.height}}var p=Xb(e);if(null==p)return n;var g=p.top,m=p.left,v=p.width,y=p.height,b={},D=u-g,C=l-m;if("bar"===r)return b.left="".concat(C,"px"),D>40?b.bottom="".concat(y-D+5,"px"):b.top="".concat(D+c+5,"px"),b;if("modal"===r){if(o?i?C>(v-d)/2?b.right="".concat(v-C+5,"px"):b.left="".concat(C+d+5,"px"):b.left="20px":b.left="".concat(C,"px"),o)(w=D)<0&&(w=0),b.top="".concat(w,"px");else if(D>(y-c)/2)b.bottom="".concat(y-D+5,"px");else{var w;(w=D+c)<0&&(w=0),b.top="".concat(w+5,"px")}return b}throw new Error("type '".concat(r,"' is invalid"))}function Qb(e,t){jv(function(){var r=Xb(e);if(null!=r){var n,o=r.top,i=r.left,a=r.width,s=r.height,u=t.offset(),l=u.top,c=u.left,d=t.width(),h=t.height(),f=l-o,p=c-i,g=t.attr("style");if(g.indexOf("top")>=0)if((n=f+h-s)>0){var m=t.css("top"),v=parseInt(m.toString(),10)-n;v<0&&(v=0),t.css("top","".concat(v,"px"))}if(g.indexOf("bottom")>=0&&l<0){var y=t.css("bottom"),b=parseInt(y.toString(),10)-Math.abs(l);t.css("bottom","".concat(b,"px"))}if(g.indexOf("left")>=0)if((n=p+d-a)>0){var D=t.css("left"),C=parseInt(D.toString(),10)-n;C<0&&(C=0),t.css("left","".concat(C,"px"))}if(g.indexOf("right")>=0&&c<0){var w=t.css("right"),E=parseInt(w.toString(),10)-Math.abs(c);t.css("right","".concat(E,"px"))}}})}var eD,tD,rD=function(e){var t=e;return t.select=function(e){zg.select(t,e)},t.deselect=function(){var r=t.selection,n=Ry.findDocumentOrShadowRoot(t).getSelection();n&&n.rangeCount>0&&n.removeAllRanges(),r&&zg.deselect(e)},t.move=function(t,r){void 0===r&&(r=!1),t&&(t<0||zg.move(e,{distance:t,unit:"character",reverse:r}))},t.moveReverse=function(e){t.move(e,!0)},t.restoreSelection=function(){var e=$m.get(t);null!=e&&(t.focus(),zg.select(t,e))},t.getSelectionPosition=function(){return Zb(t)},t.getNodePosition=function(e){return Jb(t,e)},t.isSelectedAll=function(){var e=t.selection;if(null==e)return!1;var r=Qg(hg.edges(e),2),n=r[0],o=r[1],i=Qg(Yp.edges(t,[]),2),a=i[0],s=i[1];return!(!ug.equals(n,a)||!ug.equals(o,s))},t.selectAll=function(){var e=Yp.start(t,[]),r=Yp.end(t,[]);zg.select(t,{anchor:e,focus:r})},t};var nD=function(){if(tD)return eD;tD=1;var e=/^\s+|\s+$/g,t=/^[-+]0x[0-9a-f]+$/i,r=/^0b[01]+$/i,n=/^0o[0-7]+$/i,o=parseInt,i="object"==typeof y&&y&&y.Object===Object&&y,a="object"==typeof self&&self&&self.Object===Object&&self,s=i||a||Function("return this")(),u=Object.prototype.toString,l=Math.max,c=Math.min,d=function(){return s.Date.now()};function h(e){var t=typeof e;return!!e&&("object"==t||"function"==t)}function f(i){if("number"==typeof i)return i;if(function(e){return"symbol"==typeof e||function(e){return!!e&&"object"==typeof e}(e)&&"[object Symbol]"==u.call(e)}(i))return NaN;if(h(i)){var a="function"==typeof i.valueOf?i.valueOf():i;i=h(a)?a+"":a}if("string"!=typeof i)return 0===i?i:+i;i=i.replace(e,"");var s=r.test(i);return s||n.test(i)?o(i.slice(2),s?2:8):t.test(i)?NaN:+i}return eD=function(e,t,r){var n,o,i,a,s,u,p=0,g=!1,m=!1,v=!0;if("function"!=typeof e)throw new TypeError("Expected a function");function y(t){var r=n,i=o;return n=o=void 0,p=t,a=e.apply(i,r)}function b(e){var r=e-u;return void 0===u||r>=t||r<0||m&&e-p>=i}function D(){var e=d();if(b(e))return C(e);s=setTimeout(D,function(e){var r=t-(e-u);return m?c(r,i-(e-p)):r}(e))}function C(e){return s=void 0,v&&n?y(e):(n=o=void 0,a)}function w(){var e=d(),r=b(e);if(n=arguments,o=this,u=e,r){if(void 0===s)return function(e){return p=e,s=setTimeout(D,t),g?y(e):a}(u);if(m)return s=setTimeout(D,t),y(u)}return void 0===s&&(s=setTimeout(D,t)),a}return t=f(t)||0,h(r)&&(g=!!r.leading,i=(m="maxWait"in r)?l(f(r.maxWait)||0,t):i,v="trailing"in r?!!r.trailing:v),w.cancel=function(){void 0!==s&&clearTimeout(s),p=0,n=u=o=s=void 0},w.flush=function(){return void 0===s?a:C(d())},w},eD}(),oD=b(nD);const iD=e=>"string"==typeof e,aD=()=>{let e,t;const r=new Promise((r,n)=>{e=r,t=n});return r.resolve=e,r.reject=t,r},sD=e=>null==e?"":""+e,uD=/###/g,lD=e=>e&&e.indexOf("###")>-1?e.replace(uD,"."):e,cD=e=>!e||iD(e),dD=(e,t,r)=>{const n=iD(t)?t.split("."):t;let o=0;for(;o<n.length-1;){if(cD(e))return{};const t=lD(n[o]);!e[t]&&r&&(e[t]=new r),e=Object.prototype.hasOwnProperty.call(e,t)?e[t]:{},++o}return cD(e)?{}:{obj:e,k:lD(n[o])}},hD=(e,t,r)=>{const{obj:n,k:o}=dD(e,t,Object);if(void 0!==n||1===t.length)return void(n[o]=r);let i=t[t.length-1],a=t.slice(0,t.length-1),s=dD(e,a,Object);for(;void 0===s.obj&&a.length;)i=`${a[a.length-1]}.${i}`,a=a.slice(0,a.length-1),s=dD(e,a,Object),s&&s.obj&&void 0!==s.obj[`${s.k}.${i}`]&&(s.obj=void 0);s.obj[`${s.k}.${i}`]=r},fD=(e,t)=>{const{obj:r,k:n}=dD(e,t);if(r)return r[n]},pD=(e,t,r)=>{for(const n in t)"__proto__"!==n&&"constructor"!==n&&(n in e?iD(e[n])||e[n]instanceof String||iD(t[n])||t[n]instanceof String?r&&(e[n]=t[n]):pD(e[n],t[n],r):e[n]=t[n]);return e},gD=e=>e.replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g,"\\$&");var mD={"&":"&","<":"<",">":">",'"':""","'":"'","/":"/"};const vD=e=>iD(e)?e.replace(/[&<>"'\/]/g,e=>mD[e]):e;const yD=[" ",",","?","!",";"],bD=new class{constructor(e){this.capacity=e,this.regExpMap=new Map,this.regExpQueue=[]}getRegExp(e){const t=this.regExpMap.get(e);if(void 0!==t)return t;const r=new RegExp(e);return this.regExpQueue.length===this.capacity&&this.regExpMap.delete(this.regExpQueue.shift()),this.regExpMap.set(e,r),this.regExpQueue.push(e),r}}(20),DD=function(e,t){let r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:".";if(!e)return;if(e[t])return e[t];const n=t.split(r);let o=e;for(let e=0;e<n.length;){if(!o||"object"!=typeof o)return;let t,i="";for(let a=e;a<n.length;++a)if(a!==e&&(i+=r),i+=n[a],t=o[i],void 0!==t){if(["string","number","boolean"].indexOf(typeof t)>-1&&a<n.length-1)continue;e+=a-e+1;break}o=t}return o},CD=e=>e&&e.replace("_","-"),wD={type:"logger",log(e){this.output("log",e)},warn(e){this.output("warn",e)},error(e){this.output("error",e)},output(e,t){console&&console[e]&&console[e].apply(console,t)}};class ED{constructor(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};this.init(e,t)}init(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};this.prefix=t.prefix||"i18next:",this.logger=e||wD,this.options=t,this.debug=t.debug}log(){for(var e=arguments.length,t=new Array(e),r=0;r<e;r++)t[r]=arguments[r];return this.forward(t,"log","",!0)}warn(){for(var e=arguments.length,t=new Array(e),r=0;r<e;r++)t[r]=arguments[r];return this.forward(t,"warn","",!0)}error(){for(var e=arguments.length,t=new Array(e),r=0;r<e;r++)t[r]=arguments[r];return this.forward(t,"error","")}deprecate(){for(var e=arguments.length,t=new Array(e),r=0;r<e;r++)t[r]=arguments[r];return this.forward(t,"warn","WARNING DEPRECATED: ",!0)}forward(e,t,r,n){return n&&!this.debug?null:(iD(e[0])&&(e[0]=`${r}${this.prefix} ${e[0]}`),this.logger[t](e))}create(e){return new ED(this.logger,{prefix:`${this.prefix}:${e}:`,...this.options})}clone(e){return(e=e||this.options).prefix=e.prefix||this.prefix,new ED(this.logger,e)}}var AD=new ED;class xD{constructor(){this.observers={}}on(e,t){return e.split(" ").forEach(e=>{this.observers[e]||(this.observers[e]=new Map);const r=this.observers[e].get(t)||0;this.observers[e].set(t,r+1)}),this}off(e,t){this.observers[e]&&(t?this.observers[e].delete(t):delete this.observers[e])}emit(e){for(var t=arguments.length,r=new Array(t>1?t-1:0),n=1;n<t;n++)r[n-1]=arguments[n];if(this.observers[e]){Array.from(this.observers[e].entries()).forEach(e=>{let[t,n]=e;for(let e=0;e<n;e++)t(...r)})}if(this.observers["*"]){Array.from(this.observers["*"].entries()).forEach(t=>{let[n,o]=t;for(let t=0;t<o;t++)n.apply(n,[e,...r])})}}}class BD extends xD{constructor(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{ns:["translation"],defaultNS:"translation"};super(),this.data=e||{},this.options=t,void 0===this.options.keySeparator&&(this.options.keySeparator="."),void 0===this.options.ignoreJSONStructure&&(this.options.ignoreJSONStructure=!0)}addNamespaces(e){this.options.ns.indexOf(e)<0&&this.options.ns.push(e)}removeNamespaces(e){const t=this.options.ns.indexOf(e);t>-1&&this.options.ns.splice(t,1)}getResource(e,t,r){let n=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{};const o=void 0!==n.keySeparator?n.keySeparator:this.options.keySeparator,i=void 0!==n.ignoreJSONStructure?n.ignoreJSONStructure:this.options.ignoreJSONStructure;let a;e.indexOf(".")>-1?a=e.split("."):(a=[e,t],r&&(Array.isArray(r)?a.push(...r):iD(r)&&o?a.push(...r.split(o)):a.push(r)));const s=fD(this.data,a);return!s&&!t&&!r&&e.indexOf(".")>-1&&(e=a[0],t=a[1],r=a.slice(2).join(".")),!s&&i&&iD(r)?DD(this.data&&this.data[e]&&this.data[e][t],r,o):s}addResource(e,t,r,n){let o=arguments.length>4&&void 0!==arguments[4]?arguments[4]:{silent:!1};const i=void 0!==o.keySeparator?o.keySeparator:this.options.keySeparator;let a=[e,t];r&&(a=a.concat(i?r.split(i):r)),e.indexOf(".")>-1&&(a=e.split("."),n=t,t=a[1]),this.addNamespaces(t),hD(this.data,a,n),o.silent||this.emit("added",e,t,r,n)}addResources(e,t,r){let n=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{silent:!1};for(const n in r)(iD(r[n])||Array.isArray(r[n]))&&this.addResource(e,t,n,r[n],{silent:!0});n.silent||this.emit("added",e,t,r)}addResourceBundle(e,t,r,n,o){let i=arguments.length>5&&void 0!==arguments[5]?arguments[5]:{silent:!1,skipCopy:!1},a=[e,t];e.indexOf(".")>-1&&(a=e.split("."),n=r,r=t,t=a[1]),this.addNamespaces(t);let s=fD(this.data,a)||{};i.skipCopy||(r=JSON.parse(JSON.stringify(r))),n?pD(s,r,o):s={...s,...r},hD(this.data,a,s),i.silent||this.emit("added",e,t,r)}removeResourceBundle(e,t){this.hasResourceBundle(e,t)&&delete this.data[e][t],this.removeNamespaces(t),this.emit("removed",e,t)}hasResourceBundle(e,t){return void 0!==this.getResource(e,t)}getResourceBundle(e,t){return t||(t=this.options.defaultNS),"v1"===this.options.compatibilityAPI?{...this.getResource(e,t)}:this.getResource(e,t)}getDataByLanguage(e){return this.data[e]}hasLanguageSomeTranslations(e){const t=this.getDataByLanguage(e);return!!(t&&Object.keys(t)||[]).find(e=>t[e]&&Object.keys(t[e]).length>0)}toJSON(){return this.data}}var SD={processors:{},addPostProcessor(e){this.processors[e.name]=e},handle(e,t,r,n,o){return e.forEach(e=>{this.processors[e]&&(t=this.processors[e].process(t,r,n,o))}),t}};const FD={};class kD extends xD{constructor(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};super(),((e,t,r)=>{e.forEach(e=>{t[e]&&(r[e]=t[e])})})(["resourceStore","languageUtils","pluralResolver","interpolator","backendConnector","i18nFormat","utils"],e,this),this.options=t,void 0===this.options.keySeparator&&(this.options.keySeparator="."),this.logger=AD.create("translator")}changeLanguage(e){e&&(this.language=e)}exists(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{interpolation:{}};if(null==e)return!1;const r=this.resolve(e,t);return r&&void 0!==r.res}extractFromKey(e,t){let r=void 0!==t.nsSeparator?t.nsSeparator:this.options.nsSeparator;void 0===r&&(r=":");const n=void 0!==t.keySeparator?t.keySeparator:this.options.keySeparator;let o=t.ns||this.options.defaultNS||[];const i=r&&e.indexOf(r)>-1,a=!(this.options.userDefinedKeySeparator||t.keySeparator||this.options.userDefinedNsSeparator||t.nsSeparator||((e,t,r)=>{t=t||"",r=r||"";const n=yD.filter(e=>t.indexOf(e)<0&&r.indexOf(e)<0);if(0===n.length)return!0;const o=bD.getRegExp(`(${n.map(e=>"?"===e?"\\?":e).join("|")})`);let i=!o.test(e);if(!i){const t=e.indexOf(r);t>0&&!o.test(e.substring(0,t))&&(i=!0)}return i})(e,r,n));if(i&&!a){const t=e.match(this.interpolator.nestingRegexp);if(t&&t.length>0)return{key:e,namespaces:iD(o)?[o]:o};const i=e.split(r);(r!==n||r===n&&this.options.ns.indexOf(i[0])>-1)&&(o=i.shift()),e=i.join(n)}return{key:e,namespaces:iD(o)?[o]:o}}translate(e,t,r){if("object"!=typeof t&&this.options.overloadTranslationOptionHandler&&(t=this.options.overloadTranslationOptionHandler(arguments)),"object"==typeof t&&(t={...t}),t||(t={}),null==e)return"";Array.isArray(e)||(e=[String(e)]);const n=void 0!==t.returnDetails?t.returnDetails:this.options.returnDetails,o=void 0!==t.keySeparator?t.keySeparator:this.options.keySeparator,{key:i,namespaces:a}=this.extractFromKey(e[e.length-1],t),s=a[a.length-1],u=t.lng||this.language,l=t.appendNamespaceToCIMode||this.options.appendNamespaceToCIMode;if(u&&"cimode"===u.toLowerCase()){if(l){const e=t.nsSeparator||this.options.nsSeparator;return n?{res:`${s}${e}${i}`,usedKey:i,exactUsedKey:i,usedLng:u,usedNS:s,usedParams:this.getUsedParamsDetails(t)}:`${s}${e}${i}`}return n?{res:i,usedKey:i,exactUsedKey:i,usedLng:u,usedNS:s,usedParams:this.getUsedParamsDetails(t)}:i}const c=this.resolve(e,t);let d=c&&c.res;const h=c&&c.usedKey||i,f=c&&c.exactUsedKey||i,p=Object.prototype.toString.apply(d),g=void 0!==t.joinArrays?t.joinArrays:this.options.joinArrays,m=!this.i18nFormat||this.i18nFormat.handleAsObject,v=!iD(d)&&"boolean"!=typeof d&&"number"!=typeof d;if(!(m&&d&&v&&["[object Number]","[object Function]","[object RegExp]"].indexOf(p)<0)||iD(g)&&Array.isArray(d))if(m&&iD(g)&&Array.isArray(d))d=d.join(g),d&&(d=this.extendTranslation(d,e,t,r));else{let n=!1,a=!1;const l=void 0!==t.count&&!iD(t.count),h=kD.hasDefaultValue(t),f=l?this.pluralResolver.getSuffix(u,t.count,t):"",p=t.ordinal&&l?this.pluralResolver.getSuffix(u,t.count,{ordinal:!1}):"",g=l&&!t.ordinal&&0===t.count&&this.pluralResolver.shouldUseIntlApi(),m=g&&t[`defaultValue${this.options.pluralSeparator}zero`]||t[`defaultValue${f}`]||t[`defaultValue${p}`]||t.defaultValue;!this.isValidLookup(d)&&h&&(n=!0,d=m),this.isValidLookup(d)||(a=!0,d=i);const v=(t.missingKeyNoValueFallbackToKey||this.options.missingKeyNoValueFallbackToKey)&&a?void 0:d,y=h&&m!==d&&this.options.updateMissing;if(a||n||y){if(this.logger.log(y?"updateKey":"missingKey",u,s,i,y?m:d),o){const e=this.resolve(i,{...t,keySeparator:!1});e&&e.res&&this.logger.warn("Seems the loaded translations were in flat JSON format instead of nested. Either set keySeparator: false on init or make sure your translations are published in nested format.")}let e=[];const r=this.languageUtils.getFallbackCodes(this.options.fallbackLng,t.lng||this.language);if("fallback"===this.options.saveMissingTo&&r&&r[0])for(let t=0;t<r.length;t++)e.push(r[t]);else"all"===this.options.saveMissingTo?e=this.languageUtils.toResolveHierarchy(t.lng||this.language):e.push(t.lng||this.language);const n=(e,r,n)=>{const o=h&&n!==d?n:v;this.options.missingKeyHandler?this.options.missingKeyHandler(e,s,r,o,y,t):this.backendConnector&&this.backendConnector.saveMissing&&this.backendConnector.saveMissing(e,s,r,o,y,t),this.emit("missingKey",e,s,r,d)};this.options.saveMissing&&(this.options.saveMissingPlurals&&l?e.forEach(e=>{const r=this.pluralResolver.getSuffixes(e,t);g&&t[`defaultValue${this.options.pluralSeparator}zero`]&&r.indexOf(`${this.options.pluralSeparator}zero`)<0&&r.push(`${this.options.pluralSeparator}zero`),r.forEach(r=>{n([e],i+r,t[`defaultValue${r}`]||m)})}):n(e,i,m))}d=this.extendTranslation(d,e,t,c,r),a&&d===i&&this.options.appendNamespaceToMissingKey&&(d=`${s}:${i}`),(a||n)&&this.options.parseMissingKeyHandler&&(d="v1"!==this.options.compatibilityAPI?this.options.parseMissingKeyHandler(this.options.appendNamespaceToMissingKey?`${s}:${i}`:i,n?d:void 0):this.options.parseMissingKeyHandler(d))}else{if(!t.returnObjects&&!this.options.returnObjects){this.options.returnedObjectHandler||this.logger.warn("accessing an object - but returnObjects options is not enabled!");const e=this.options.returnedObjectHandler?this.options.returnedObjectHandler(h,d,{...t,ns:a}):`key '${i} (${this.language})' returned an object instead of string.`;return n?(c.res=e,c.usedParams=this.getUsedParamsDetails(t),c):e}if(o){const e=Array.isArray(d),r=e?[]:{},n=e?f:h;for(const e in d)if(Object.prototype.hasOwnProperty.call(d,e)){const i=`${n}${o}${e}`;r[e]=this.translate(i,{...t,joinArrays:!1,ns:a}),r[e]===i&&(r[e]=d[e])}d=r}}return n?(c.res=d,c.usedParams=this.getUsedParamsDetails(t),c):d}extendTranslation(e,t,r,n,o){var i=this;if(this.i18nFormat&&this.i18nFormat.parse)e=this.i18nFormat.parse(e,{...this.options.interpolation.defaultVariables,...r},r.lng||this.language||n.usedLng,n.usedNS,n.usedKey,{resolved:n});else if(!r.skipInterpolation){r.interpolation&&this.interpolator.init({...r,interpolation:{...this.options.interpolation,...r.interpolation}});const a=iD(e)&&(r&&r.interpolation&&void 0!==r.interpolation.skipOnVariables?r.interpolation.skipOnVariables:this.options.interpolation.skipOnVariables);let s;if(a){const t=e.match(this.interpolator.nestingRegexp);s=t&&t.length}let u=r.replace&&!iD(r.replace)?r.replace:r;if(this.options.interpolation.defaultVariables&&(u={...this.options.interpolation.defaultVariables,...u}),e=this.interpolator.interpolate(e,u,r.lng||this.language||n.usedLng,r),a){const t=e.match(this.interpolator.nestingRegexp);s<(t&&t.length)&&(r.nest=!1)}!r.lng&&"v1"!==this.options.compatibilityAPI&&n&&n.res&&(r.lng=this.language||n.usedLng),!1!==r.nest&&(e=this.interpolator.nest(e,function(){for(var e=arguments.length,n=new Array(e),a=0;a<e;a++)n[a]=arguments[a];return o&&o[0]===n[0]&&!r.context?(i.logger.warn(`It seems you are nesting recursively key: ${n[0]} in key: ${t[0]}`),null):i.translate(...n,t)},r)),r.interpolation&&this.interpolator.reset()}const a=r.postProcess||this.options.postProcess,s=iD(a)?[a]:a;return null!=e&&s&&s.length&&!1!==r.applyPostProcessor&&(e=SD.handle(s,e,t,this.options&&this.options.postProcessPassResolved?{i18nResolved:{...n,usedParams:this.getUsedParamsDetails(r)},...r}:r,this)),e}resolve(e){let t,r,n,o,i,a=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return iD(e)&&(e=[e]),e.forEach(e=>{if(this.isValidLookup(t))return;const s=this.extractFromKey(e,a),u=s.key;r=u;let l=s.namespaces;this.options.fallbackNS&&(l=l.concat(this.options.fallbackNS));const c=void 0!==a.count&&!iD(a.count),d=c&&!a.ordinal&&0===a.count&&this.pluralResolver.shouldUseIntlApi(),h=void 0!==a.context&&(iD(a.context)||"number"==typeof a.context)&&""!==a.context,f=a.lngs?a.lngs:this.languageUtils.toResolveHierarchy(a.lng||this.language,a.fallbackLng);l.forEach(e=>{this.isValidLookup(t)||(i=e,!FD[`${f[0]}-${e}`]&&this.utils&&this.utils.hasLoadedNamespace&&!this.utils.hasLoadedNamespace(i)&&(FD[`${f[0]}-${e}`]=!0,this.logger.warn(`key "${r}" for languages "${f.join(", ")}" won't get resolved as namespace "${i}" was not yet loaded`,"This means something IS WRONG in your setup. You access the t function before i18next.init / i18next.loadNamespace / i18next.changeLanguage was done. Wait for the callback or Promise to resolve before accessing it!!!")),f.forEach(r=>{if(this.isValidLookup(t))return;o=r;const i=[u];if(this.i18nFormat&&this.i18nFormat.addLookupKeys)this.i18nFormat.addLookupKeys(i,u,r,e,a);else{let e;c&&(e=this.pluralResolver.getSuffix(r,a.count,a));const t=`${this.options.pluralSeparator}zero`,n=`${this.options.pluralSeparator}ordinal${this.options.pluralSeparator}`;if(c&&(i.push(u+e),a.ordinal&&0===e.indexOf(n)&&i.push(u+e.replace(n,this.options.pluralSeparator)),d&&i.push(u+t)),h){const r=`${u}${this.options.contextSeparator}${a.context}`;i.push(r),c&&(i.push(r+e),a.ordinal&&0===e.indexOf(n)&&i.push(r+e.replace(n,this.options.pluralSeparator)),d&&i.push(r+t))}}let s;for(;s=i.pop();)this.isValidLookup(t)||(n=s,t=this.getResource(r,e,s,a))}))})}),{res:t,usedKey:r,exactUsedKey:n,usedLng:o,usedNS:i}}isValidLookup(e){return!(void 0===e||!this.options.returnNull&&null===e||!this.options.returnEmptyString&&""===e)}getResource(e,t,r){let n=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{};return this.i18nFormat&&this.i18nFormat.getResource?this.i18nFormat.getResource(e,t,r,n):this.resourceStore.getResource(e,t,r,n)}getUsedParamsDetails(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};const t=["defaultValue","ordinal","context","replace","lng","lngs","fallbackLng","ns","keySeparator","nsSeparator","returnObjects","returnDetails","joinArrays","postProcess","interpolation"],r=e.replace&&!iD(e.replace);let n=r?e.replace:e;if(r&&void 0!==e.count&&(n.count=e.count),this.options.interpolation.defaultVariables&&(n={...this.options.interpolation.defaultVariables,...n}),!r){n={...n};for(const e of t)delete n[e]}return n}static hasDefaultValue(e){const t="defaultValue";for(const r in e)if(Object.prototype.hasOwnProperty.call(e,r)&&t===r.substring(0,12)&&void 0!==e[r])return!0;return!1}}const OD=e=>e.charAt(0).toUpperCase()+e.slice(1);class TD{constructor(e){this.options=e,this.supportedLngs=this.options.supportedLngs||!1,this.logger=AD.create("languageUtils")}getScriptPartFromCode(e){if(!(e=CD(e))||e.indexOf("-")<0)return null;const t=e.split("-");return 2===t.length?null:(t.pop(),"x"===t[t.length-1].toLowerCase()?null:this.formatLanguageCode(t.join("-")))}getLanguagePartFromCode(e){if(!(e=CD(e))||e.indexOf("-")<0)return e;const t=e.split("-");return this.formatLanguageCode(t[0])}formatLanguageCode(e){if(iD(e)&&e.indexOf("-")>-1){if("undefined"!=typeof Intl&&void 0!==Intl.getCanonicalLocales)try{let t=Intl.getCanonicalLocales(e)[0];if(t&&this.options.lowerCaseLng&&(t=t.toLowerCase()),t)return t}catch(e){}const t=["hans","hant","latn","cyrl","cans","mong","arab"];let r=e.split("-");return this.options.lowerCaseLng?r=r.map(e=>e.toLowerCase()):2===r.length?(r[0]=r[0].toLowerCase(),r[1]=r[1].toUpperCase(),t.indexOf(r[1].toLowerCase())>-1&&(r[1]=OD(r[1].toLowerCase()))):3===r.length&&(r[0]=r[0].toLowerCase(),2===r[1].length&&(r[1]=r[1].toUpperCase()),"sgn"!==r[0]&&2===r[2].length&&(r[2]=r[2].toUpperCase()),t.indexOf(r[1].toLowerCase())>-1&&(r[1]=OD(r[1].toLowerCase())),t.indexOf(r[2].toLowerCase())>-1&&(r[2]=OD(r[2].toLowerCase()))),r.join("-")}return this.options.cleanCode||this.options.lowerCaseLng?e.toLowerCase():e}isSupportedCode(e){return("languageOnly"===this.options.load||this.options.nonExplicitSupportedLngs)&&(e=this.getLanguagePartFromCode(e)),!this.supportedLngs||!this.supportedLngs.length||this.supportedLngs.indexOf(e)>-1}getBestMatchFromCodes(e){if(!e)return null;let t;return e.forEach(e=>{if(t)return;const r=this.formatLanguageCode(e);this.options.supportedLngs&&!this.isSupportedCode(r)||(t=r)}),!t&&this.options.supportedLngs&&e.forEach(e=>{if(t)return;const r=this.getLanguagePartFromCode(e);if(this.isSupportedCode(r))return t=r;t=this.options.supportedLngs.find(e=>e===r?e:e.indexOf("-")<0&&r.indexOf("-")<0?void 0:e.indexOf("-")>0&&r.indexOf("-")<0&&e.substring(0,e.indexOf("-"))===r||0===e.indexOf(r)&&r.length>1?e:void 0)}),t||(t=this.getFallbackCodes(this.options.fallbackLng)[0]),t}getFallbackCodes(e,t){if(!e)return[];if("function"==typeof e&&(e=e(t)),iD(e)&&(e=[e]),Array.isArray(e))return e;if(!t)return e.default||[];let r=e[t];return r||(r=e[this.getScriptPartFromCode(t)]),r||(r=e[this.formatLanguageCode(t)]),r||(r=e[this.getLanguagePartFromCode(t)]),r||(r=e.default),r||[]}toResolveHierarchy(e,t){const r=this.getFallbackCodes(t||this.options.fallbackLng||[],e),n=[],o=e=>{e&&(this.isSupportedCode(e)?n.push(e):this.logger.warn(`rejecting language code not found in supportedLngs: ${e}`))};return iD(e)&&(e.indexOf("-")>-1||e.indexOf("_")>-1)?("languageOnly"!==this.options.load&&o(this.formatLanguageCode(e)),"languageOnly"!==this.options.load&&"currentOnly"!==this.options.load&&o(this.getScriptPartFromCode(e)),"currentOnly"!==this.options.load&&o(this.getLanguagePartFromCode(e))):iD(e)&&o(this.formatLanguageCode(e)),r.forEach(e=>{n.indexOf(e)<0&&o(this.formatLanguageCode(e))}),n}}let ND=[{lngs:["ach","ak","am","arn","br","fil","gun","ln","mfe","mg","mi","oc","pt","pt-BR","tg","tl","ti","tr","uz","wa"],nr:[1,2],fc:1},{lngs:["af","an","ast","az","bg","bn","ca","da","de","dev","el","en","eo","es","et","eu","fi","fo","fur","fy","gl","gu","ha","hi","hu","hy","ia","it","kk","kn","ku","lb","mai","ml","mn","mr","nah","nap","nb","ne","nl","nn","no","nso","pa","pap","pms","ps","pt-PT","rm","sco","se","si","so","son","sq","sv","sw","ta","te","tk","ur","yo"],nr:[1,2],fc:2},{lngs:["ay","bo","cgg","fa","ht","id","ja","jbo","ka","km","ko","ky","lo","ms","sah","su","th","tt","ug","vi","wo","zh"],nr:[1],fc:3},{lngs:["be","bs","cnr","dz","hr","ru","sr","uk"],nr:[1,2,5],fc:4},{lngs:["ar"],nr:[0,1,2,3,11,100],fc:5},{lngs:["cs","sk"],nr:[1,2,5],fc:6},{lngs:["csb","pl"],nr:[1,2,5],fc:7},{lngs:["cy"],nr:[1,2,3,8],fc:8},{lngs:["fr"],nr:[1,2],fc:9},{lngs:["ga"],nr:[1,2,3,7,11],fc:10},{lngs:["gd"],nr:[1,2,3,20],fc:11},{lngs:["is"],nr:[1,2],fc:12},{lngs:["jv"],nr:[0,1],fc:13},{lngs:["kw"],nr:[1,2,3,4],fc:14},{lngs:["lt"],nr:[1,2,10],fc:15},{lngs:["lv"],nr:[1,2,0],fc:16},{lngs:["mk"],nr:[1,2],fc:17},{lngs:["mnk"],nr:[0,1,2],fc:18},{lngs:["mt"],nr:[1,2,11,20],fc:19},{lngs:["or"],nr:[2,1],fc:2},{lngs:["ro"],nr:[1,2,20],fc:20},{lngs:["sl"],nr:[5,1,2,3],fc:21},{lngs:["he","iw"],nr:[1,2,20,21],fc:22}],PD={1:e=>Number(e>1),2:e=>Number(1!=e),3:e=>0,4:e=>Number(e%10==1&&e%100!=11?0:e%10>=2&&e%10<=4&&(e%100<10||e%100>=20)?1:2),5:e=>Number(0==e?0:1==e?1:2==e?2:e%100>=3&&e%100<=10?3:e%100>=11?4:5),6:e=>Number(1==e?0:e>=2&&e<=4?1:2),7:e=>Number(1==e?0:e%10>=2&&e%10<=4&&(e%100<10||e%100>=20)?1:2),8:e=>Number(1==e?0:2==e?1:8!=e&&11!=e?2:3),9:e=>Number(e>=2),10:e=>Number(1==e?0:2==e?1:e<7?2:e<11?3:4),11:e=>Number(1==e||11==e?0:2==e||12==e?1:e>2&&e<20?2:3),12:e=>Number(e%10!=1||e%100==11),13:e=>Number(0!==e),14:e=>Number(1==e?0:2==e?1:3==e?2:3),15:e=>Number(e%10==1&&e%100!=11?0:e%10>=2&&(e%100<10||e%100>=20)?1:2),16:e=>Number(e%10==1&&e%100!=11?0:0!==e?1:2),17:e=>Number(1==e||e%10==1&&e%100!=11?0:1),18:e=>Number(0==e?0:1==e?1:2),19:e=>Number(1==e?0:0==e||e%100>1&&e%100<11?1:e%100>10&&e%100<20?2:3),20:e=>Number(1==e?0:0==e||e%100>0&&e%100<20?1:2),21:e=>Number(e%100==1?1:e%100==2?2:e%100==3||e%100==4?3:0),22:e=>Number(1==e?0:2==e?1:(e<0||e>10)&&e%10==0?2:3)};const MD=["v1","v2","v3"],ID=["v4"],RD={zero:0,one:1,two:2,few:3,many:4,other:5};class LD{constructor(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};this.languageUtils=e,this.options=t,this.logger=AD.create("pluralResolver"),this.options.compatibilityJSON&&!ID.includes(this.options.compatibilityJSON)||"undefined"!=typeof Intl&&Intl.PluralRules||(this.options.compatibilityJSON="v3",this.logger.error("Your environment seems not to be Intl API compatible, use an Intl.PluralRules polyfill. Will fallback to the compatibilityJSON v3 format handling.")),this.rules=(()=>{const e={};return ND.forEach(t=>{t.lngs.forEach(r=>{e[r]={numbers:t.nr,plurals:PD[t.fc]}})}),e})(),this.pluralRulesCache={}}addRule(e,t){this.rules[e]=t}clearCache(){this.pluralRulesCache={}}getRule(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if(this.shouldUseIntlApi()){const r=CD("dev"===e?"en":e),n=t.ordinal?"ordinal":"cardinal",o=JSON.stringify({cleanedCode:r,type:n});if(o in this.pluralRulesCache)return this.pluralRulesCache[o];let i;try{i=new Intl.PluralRules(r,{type:n})}catch(r){if(!e.match(/-|_/))return;const n=this.languageUtils.getLanguagePartFromCode(e);i=this.getRule(n,t)}return this.pluralRulesCache[o]=i,i}return this.rules[e]||this.rules[this.languageUtils.getLanguagePartFromCode(e)]}needsPlural(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};const r=this.getRule(e,t);return this.shouldUseIntlApi()?r&&r.resolvedOptions().pluralCategories.length>1:r&&r.numbers.length>1}getPluralFormsOfKey(e,t){let r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return this.getSuffixes(e,r).map(e=>`${t}${e}`)}getSuffixes(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};const r=this.getRule(e,t);return r?this.shouldUseIntlApi()?r.resolvedOptions().pluralCategories.sort((e,t)=>RD[e]-RD[t]).map(e=>`${this.options.prepend}${t.ordinal?`ordinal${this.options.prepend}`:""}${e}`):r.numbers.map(r=>this.getSuffix(e,r,t)):[]}getSuffix(e,t){let r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};const n=this.getRule(e,r);return n?this.shouldUseIntlApi()?`${this.options.prepend}${r.ordinal?`ordinal${this.options.prepend}`:""}${n.select(t)}`:this.getSuffixRetroCompatible(n,t):(this.logger.warn(`no plural rule found for: ${e}`),"")}getSuffixRetroCompatible(e,t){const r=e.noAbs?e.plurals(t):e.plurals(Math.abs(t));let n=e.numbers[r];this.options.simplifyPluralSuffix&&2===e.numbers.length&&1===e.numbers[0]&&(2===n?n="plural":1===n&&(n=""));const o=()=>this.options.prepend&&n.toString()?this.options.prepend+n.toString():n.toString();return"v1"===this.options.compatibilityJSON?1===n?"":"number"==typeof n?`_plural_${n.toString()}`:o():"v2"===this.options.compatibilityJSON||this.options.simplifyPluralSuffix&&2===e.numbers.length&&1===e.numbers[0]?o():this.options.prepend&&r.toString()?this.options.prepend+r.toString():r.toString()}shouldUseIntlApi(){return!MD.includes(this.options.compatibilityJSON)}}const _D=function(e,t,r){let n=arguments.length>3&&void 0!==arguments[3]?arguments[3]:".",o=!(arguments.length>4&&void 0!==arguments[4])||arguments[4],i=((e,t,r)=>{const n=fD(e,r);return void 0!==n?n:fD(t,r)})(e,t,r);return!i&&o&&iD(r)&&(i=DD(e,r,n),void 0===i&&(i=DD(t,r,n))),i},zD=e=>e.replace(/\$/g,"$$$$");class jD{constructor(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};this.logger=AD.create("interpolator"),this.options=e,this.format=e.interpolation&&e.interpolation.format||(e=>e),this.init(e)}init(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};e.interpolation||(e.interpolation={escapeValue:!0});const{escape:t,escapeValue:r,useRawValueToEscape:n,prefix:o,prefixEscaped:i,suffix:a,suffixEscaped:s,formatSeparator:u,unescapeSuffix:l,unescapePrefix:c,nestingPrefix:d,nestingPrefixEscaped:h,nestingSuffix:f,nestingSuffixEscaped:p,nestingOptionsSeparator:g,maxReplaces:m,alwaysFormat:v}=e.interpolation;this.escape=void 0!==t?t:vD,this.escapeValue=void 0===r||r,this.useRawValueToEscape=void 0!==n&&n,this.prefix=o?gD(o):i||"{{",this.suffix=a?gD(a):s||"}}",this.formatSeparator=u||",",this.unescapePrefix=l?"":c||"-",this.unescapeSuffix=this.unescapePrefix?"":l||"",this.nestingPrefix=d?gD(d):h||gD("$t("),this.nestingSuffix=f?gD(f):p||gD(")"),this.nestingOptionsSeparator=g||",",this.maxReplaces=m||1e3,this.alwaysFormat=void 0!==v&&v,this.resetRegExp()}reset(){this.options&&this.init(this.options)}resetRegExp(){const e=(e,t)=>e&&e.source===t?(e.lastIndex=0,e):new RegExp(t,"g");this.regexp=e(this.regexp,`${this.prefix}(.+?)${this.suffix}`),this.regexpUnescape=e(this.regexpUnescape,`${this.prefix}${this.unescapePrefix}(.+?)${this.unescapeSuffix}${this.suffix}`),this.nestingRegexp=e(this.nestingRegexp,`${this.nestingPrefix}(.+?)${this.nestingSuffix}`)}interpolate(e,t,r,n){let o,i,a;const s=this.options&&this.options.interpolation&&this.options.interpolation.defaultVariables||{},u=e=>{if(e.indexOf(this.formatSeparator)<0){const o=_D(t,s,e,this.options.keySeparator,this.options.ignoreJSONStructure);return this.alwaysFormat?this.format(o,void 0,r,{...n,...t,interpolationkey:e}):o}const o=e.split(this.formatSeparator),i=o.shift().trim(),a=o.join(this.formatSeparator).trim();return this.format(_D(t,s,i,this.options.keySeparator,this.options.ignoreJSONStructure),a,r,{...n,...t,interpolationkey:i})};this.resetRegExp();const l=n&&n.missingInterpolationHandler||this.options.missingInterpolationHandler,c=n&&n.interpolation&&void 0!==n.interpolation.skipOnVariables?n.interpolation.skipOnVariables:this.options.interpolation.skipOnVariables,d=[{regex:this.regexpUnescape,safeValue:e=>zD(e)},{regex:this.regexp,safeValue:e=>this.escapeValue?zD(this.escape(e)):zD(e)}];return d.forEach(t=>{for(a=0;o=t.regex.exec(e);){const r=o[1].trim();if(i=u(r),void 0===i)if("function"==typeof l){const t=l(e,o,n);i=iD(t)?t:""}else if(n&&Object.prototype.hasOwnProperty.call(n,r))i="";else{if(c){i=o[0];continue}this.logger.warn(`missed to pass in variable ${r} for interpolating ${e}`),i=""}else iD(i)||this.useRawValueToEscape||(i=sD(i));const s=t.safeValue(i);if(e=e.replace(o[0],s),c?(t.regex.lastIndex+=i.length,t.regex.lastIndex-=o[0].length):t.regex.lastIndex=0,a++,a>=this.maxReplaces)break}}),e}nest(e,t){let r,n,o,i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};const a=(e,t)=>{const r=this.nestingOptionsSeparator;if(e.indexOf(r)<0)return e;const n=e.split(new RegExp(`${r}[ ]*{`));let i=`{${n[1]}`;e=n[0],i=this.interpolate(i,o);const a=i.match(/'/g),s=i.match(/"/g);(a&&a.length%2==0&&!s||s.length%2!=0)&&(i=i.replace(/'/g,'"'));try{o=JSON.parse(i),t&&(o={...t,...o})}catch(t){return this.logger.warn(`failed parsing options string in nesting for key ${e}`,t),`${e}${r}${i}`}return o.defaultValue&&o.defaultValue.indexOf(this.prefix)>-1&&delete o.defaultValue,e};for(;r=this.nestingRegexp.exec(e);){let s=[];o={...i},o=o.replace&&!iD(o.replace)?o.replace:o,o.applyPostProcessor=!1,delete o.defaultValue;let u=!1;if(-1!==r[0].indexOf(this.formatSeparator)&&!/{.*}/.test(r[1])){const e=r[1].split(this.formatSeparator).map(e=>e.trim());r[1]=e.shift(),s=e,u=!0}if(n=t(a.call(this,r[1].trim(),o),o),n&&r[0]===e&&!iD(n))return n;iD(n)||(n=sD(n)),n||(this.logger.warn(`missed to resolve ${r[1]} for nesting ${e}`),n=""),u&&(n=s.reduce((e,t)=>this.format(e,t,i.lng,{...i,interpolationkey:r[1].trim()}),n.trim())),e=e.replace(r[0],n),this.regexp.lastIndex=0}return e}}const HD=e=>{const t={};return(r,n,o)=>{let i=o;o&&o.interpolationkey&&o.formatParams&&o.formatParams[o.interpolationkey]&&o[o.interpolationkey]&&(i={...i,[o.interpolationkey]:void 0});const a=n+JSON.stringify(i);let s=t[a];return s||(s=e(CD(n),o),t[a]=s),s(r)}};class VD{constructor(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};this.logger=AD.create("formatter"),this.options=e,this.formats={number:HD((e,t)=>{const r=new Intl.NumberFormat(e,{...t});return e=>r.format(e)}),currency:HD((e,t)=>{const r=new Intl.NumberFormat(e,{...t,style:"currency"});return e=>r.format(e)}),datetime:HD((e,t)=>{const r=new Intl.DateTimeFormat(e,{...t});return e=>r.format(e)}),relativetime:HD((e,t)=>{const r=new Intl.RelativeTimeFormat(e,{...t});return e=>r.format(e,t.range||"day")}),list:HD((e,t)=>{const r=new Intl.ListFormat(e,{...t});return e=>r.format(e)})},this.init(e)}init(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{interpolation:{}};this.formatSeparator=t.interpolation.formatSeparator||","}add(e,t){this.formats[e.toLowerCase().trim()]=t}addCached(e,t){this.formats[e.toLowerCase().trim()]=HD(t)}format(e,t,r){let n=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{};const o=t.split(this.formatSeparator);if(o.length>1&&o[0].indexOf("(")>1&&o[0].indexOf(")")<0&&o.find(e=>e.indexOf(")")>-1)){const e=o.findIndex(e=>e.indexOf(")")>-1);o[0]=[o[0],...o.splice(1,e)].join(this.formatSeparator)}const i=o.reduce((e,t)=>{const{formatName:o,formatOptions:i}=(e=>{let t=e.toLowerCase().trim();const r={};if(e.indexOf("(")>-1){const n=e.split("(");t=n[0].toLowerCase().trim();const o=n[1].substring(0,n[1].length-1);"currency"===t&&o.indexOf(":")<0?r.currency||(r.currency=o.trim()):"relativetime"===t&&o.indexOf(":")<0?r.range||(r.range=o.trim()):o.split(";").forEach(e=>{if(e){const[t,...n]=e.split(":"),o=n.join(":").trim().replace(/^'+|'+$/g,""),i=t.trim();r[i]||(r[i]=o),"false"===o&&(r[i]=!1),"true"===o&&(r[i]=!0),isNaN(o)||(r[i]=parseInt(o,10))}})}return{formatName:t,formatOptions:r}})(t);if(this.formats[o]){let t=e;try{const a=n&&n.formatParams&&n.formatParams[n.interpolationkey]||{},s=a.locale||a.lng||n.locale||n.lng||r;t=this.formats[o](e,s,{...i,...n,...a})}catch(e){this.logger.warn(e)}return t}return this.logger.warn(`there was no format function for ${o}`),e},e);return i}}class $D extends xD{constructor(e,t,r){let n=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{};super(),this.backend=e,this.store=t,this.services=r,this.languageUtils=r.languageUtils,this.options=n,this.logger=AD.create("backendConnector"),this.waitingReads=[],this.maxParallelReads=n.maxParallelReads||10,this.readingCalls=0,this.maxRetries=n.maxRetries>=0?n.maxRetries:5,this.retryTimeout=n.retryTimeout>=1?n.retryTimeout:350,this.state={},this.queue=[],this.backend&&this.backend.init&&this.backend.init(r,n.backend,n)}queueLoad(e,t,r,n){const o={},i={},a={},s={};return e.forEach(e=>{let n=!0;t.forEach(t=>{const a=`${e}|${t}`;!r.reload&&this.store.hasResourceBundle(e,t)?this.state[a]=2:this.state[a]<0||(1===this.state[a]?void 0===i[a]&&(i[a]=!0):(this.state[a]=1,n=!1,void 0===i[a]&&(i[a]=!0),void 0===o[a]&&(o[a]=!0),void 0===s[t]&&(s[t]=!0)))}),n||(a[e]=!0)}),(Object.keys(o).length||Object.keys(i).length)&&this.queue.push({pending:i,pendingCount:Object.keys(i).length,loaded:{},errors:[],callback:n}),{toLoad:Object.keys(o),pending:Object.keys(i),toLoadLanguages:Object.keys(a),toLoadNamespaces:Object.keys(s)}}loaded(e,t,r){const n=e.split("|"),o=n[0],i=n[1];t&&this.emit("failedLoading",o,i,t),!t&&r&&this.store.addResourceBundle(o,i,r,void 0,void 0,{skipCopy:!0}),this.state[e]=t?-1:2,t&&r&&(this.state[e]=0);const a={};this.queue.forEach(r=>{((e,t,r)=>{const{obj:n,k:o}=dD(e,t,Object);n[o]=n[o]||[],n[o].push(r)})(r.loaded,[o],i),((e,t)=>{void 0!==e.pending[t]&&(delete e.pending[t],e.pendingCount--)})(r,e),t&&r.errors.push(t),0!==r.pendingCount||r.done||(Object.keys(r.loaded).forEach(e=>{a[e]||(a[e]={});const t=r.loaded[e];t.length&&t.forEach(t=>{void 0===a[e][t]&&(a[e][t]=!0)})}),r.done=!0,r.errors.length?r.callback(r.errors):r.callback())}),this.emit("loaded",a),this.queue=this.queue.filter(e=>!e.done)}read(e,t,r){let n=arguments.length>3&&void 0!==arguments[3]?arguments[3]:0,o=arguments.length>4&&void 0!==arguments[4]?arguments[4]:this.retryTimeout,i=arguments.length>5?arguments[5]:void 0;if(!e.length)return i(null,{});if(this.readingCalls>=this.maxParallelReads)return void this.waitingReads.push({lng:e,ns:t,fcName:r,tried:n,wait:o,callback:i});this.readingCalls++;const a=(a,s)=>{if(this.readingCalls--,this.waitingReads.length>0){const e=this.waitingReads.shift();this.read(e.lng,e.ns,e.fcName,e.tried,e.wait,e.callback)}a&&s&&n<this.maxRetries?setTimeout(()=>{this.read.call(this,e,t,r,n+1,2*o,i)},o):i(a,s)},s=this.backend[r].bind(this.backend);if(2!==s.length)return s(e,t,a);try{const r=s(e,t);r&&"function"==typeof r.then?r.then(e=>a(null,e)).catch(a):a(null,r)}catch(e){a(e)}}prepareLoading(e,t){let r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},n=arguments.length>3?arguments[3]:void 0;if(!this.backend)return this.logger.warn("No backend was added via i18next.use. Will not load resources."),n&&n();iD(e)&&(e=this.languageUtils.toResolveHierarchy(e)),iD(t)&&(t=[t]);const o=this.queueLoad(e,t,r,n);if(!o.toLoad.length)return o.pending.length||n(),null;o.toLoad.forEach(e=>{this.loadOne(e)})}load(e,t,r){this.prepareLoading(e,t,{},r)}reload(e,t,r){this.prepareLoading(e,t,{reload:!0},r)}loadOne(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";const r=e.split("|"),n=r[0],o=r[1];this.read(n,o,"read",void 0,void 0,(r,i)=>{r&&this.logger.warn(`${t}loading namespace ${o} for language ${n} failed`,r),!r&&i&&this.logger.log(`${t}loaded namespace ${o} for language ${n}`,i),this.loaded(e,r,i)})}saveMissing(e,t,r,n,o){let i=arguments.length>5&&void 0!==arguments[5]?arguments[5]:{},a=arguments.length>6&&void 0!==arguments[6]?arguments[6]:()=>{};if(this.services.utils&&this.services.utils.hasLoadedNamespace&&!this.services.utils.hasLoadedNamespace(t))this.logger.warn(`did not save key "${r}" as the namespace "${t}" was not yet loaded`,"This means something IS WRONG in your setup. You access the t function before i18next.init / i18next.loadNamespace / i18next.changeLanguage was done. Wait for the callback or Promise to resolve before accessing it!!!");else if(null!=r&&""!==r){if(this.backend&&this.backend.create){const s={...i,isUpdate:o},u=this.backend.create.bind(this.backend);if(u.length<6)try{let o;o=5===u.length?u(e,t,r,n,s):u(e,t,r,n),o&&"function"==typeof o.then?o.then(e=>a(null,e)).catch(a):a(null,o)}catch(e){a(e)}else u(e,t,r,n,a,s)}e&&e[0]&&this.store.addResource(e[0],t,r,n)}}}const UD=()=>({debug:!1,initImmediate:!0,ns:["translation"],defaultNS:["translation"],fallbackLng:["dev"],fallbackNS:!1,supportedLngs:!1,nonExplicitSupportedLngs:!1,load:"all",preload:!1,simplifyPluralSuffix:!0,keySeparator:".",nsSeparator:":",pluralSeparator:"_",contextSeparator:"_",partialBundledLanguages:!1,saveMissing:!1,updateMissing:!1,saveMissingTo:"fallback",saveMissingPlurals:!0,missingKeyHandler:!1,missingInterpolationHandler:!1,postProcess:!1,postProcessPassResolved:!1,returnNull:!1,returnEmptyString:!0,returnObjects:!1,joinArrays:!1,returnedObjectHandler:!1,parseMissingKeyHandler:!1,appendNamespaceToMissingKey:!1,appendNamespaceToCIMode:!1,overloadTranslationOptionHandler:e=>{let t={};if("object"==typeof e[1]&&(t=e[1]),iD(e[1])&&(t.defaultValue=e[1]),iD(e[2])&&(t.tDescription=e[2]),"object"==typeof e[2]||"object"==typeof e[3]){const r=e[3]||e[2];Object.keys(r).forEach(e=>{t[e]=r[e]})}return t},interpolation:{escapeValue:!0,format:e=>e,prefix:"{{",suffix:"}}",formatSeparator:",",unescapePrefix:"-",nestingPrefix:"$t(",nestingSuffix:")",nestingOptionsSeparator:",",maxReplaces:1e3,skipOnVariables:!0}}),qD=e=>(iD(e.ns)&&(e.ns=[e.ns]),iD(e.fallbackLng)&&(e.fallbackLng=[e.fallbackLng]),iD(e.fallbackNS)&&(e.fallbackNS=[e.fallbackNS]),e.supportedLngs&&e.supportedLngs.indexOf("cimode")<0&&(e.supportedLngs=e.supportedLngs.concat(["cimode"])),e),WD=()=>{};class GD extends xD{constructor(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1?arguments[1]:void 0;var r;if(super(),this.options=qD(e),this.services={},this.logger=AD,this.modules={external:[]},r=this,Object.getOwnPropertyNames(Object.getPrototypeOf(r)).forEach(e=>{"function"==typeof r[e]&&(r[e]=r[e].bind(r))}),t&&!this.isInitialized&&!e.isClone){if(!this.options.initImmediate)return this.init(e,t),this;setTimeout(()=>{this.init(e,t)},0)}}init(){var e=this;let t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},r=arguments.length>1?arguments[1]:void 0;this.isInitializing=!0,"function"==typeof t&&(r=t,t={}),!t.defaultNS&&!1!==t.defaultNS&&t.ns&&(iD(t.ns)?t.defaultNS=t.ns:t.ns.indexOf("translation")<0&&(t.defaultNS=t.ns[0]));const n=UD();this.options={...n,...this.options,...qD(t)},"v1"!==this.options.compatibilityAPI&&(this.options.interpolation={...n.interpolation,...this.options.interpolation}),void 0!==t.keySeparator&&(this.options.userDefinedKeySeparator=t.keySeparator),void 0!==t.nsSeparator&&(this.options.userDefinedNsSeparator=t.nsSeparator);const o=e=>e?"function"==typeof e?new e:e:null;if(!this.options.isClone){let t;this.modules.logger?AD.init(o(this.modules.logger),this.options):AD.init(null,this.options),this.modules.formatter?t=this.modules.formatter:"undefined"!=typeof Intl&&(t=VD);const r=new TD(this.options);this.store=new BD(this.options.resources,this.options);const i=this.services;i.logger=AD,i.resourceStore=this.store,i.languageUtils=r,i.pluralResolver=new LD(r,{prepend:this.options.pluralSeparator,compatibilityJSON:this.options.compatibilityJSON,simplifyPluralSuffix:this.options.simplifyPluralSuffix}),!t||this.options.interpolation.format&&this.options.interpolation.format!==n.interpolation.format||(i.formatter=o(t),i.formatter.init(i,this.options),this.options.interpolation.format=i.formatter.format.bind(i.formatter)),i.interpolator=new jD(this.options),i.utils={hasLoadedNamespace:this.hasLoadedNamespace.bind(this)},i.backendConnector=new $D(o(this.modules.backend),i.resourceStore,i,this.options),i.backendConnector.on("*",function(t){for(var r=arguments.length,n=new Array(r>1?r-1:0),o=1;o<r;o++)n[o-1]=arguments[o];e.emit(t,...n)}),this.modules.languageDetector&&(i.languageDetector=o(this.modules.languageDetector),i.languageDetector.init&&i.languageDetector.init(i,this.options.detection,this.options)),this.modules.i18nFormat&&(i.i18nFormat=o(this.modules.i18nFormat),i.i18nFormat.init&&i.i18nFormat.init(this)),this.translator=new kD(this.services,this.options),this.translator.on("*",function(t){for(var r=arguments.length,n=new Array(r>1?r-1:0),o=1;o<r;o++)n[o-1]=arguments[o];e.emit(t,...n)}),this.modules.external.forEach(e=>{e.init&&e.init(this)})}if(this.format=this.options.interpolation.format,r||(r=WD),this.options.fallbackLng&&!this.services.languageDetector&&!this.options.lng){const e=this.services.languageUtils.getFallbackCodes(this.options.fallbackLng);e.length>0&&"dev"!==e[0]&&(this.options.lng=e[0])}this.services.languageDetector||this.options.lng||this.logger.warn("init: no languageDetector is used and no lng is defined");["getResource","hasResourceBundle","getResourceBundle","getDataByLanguage"].forEach(t=>{this[t]=function(){return e.store[t](...arguments)}});["addResource","addResources","addResourceBundle","removeResourceBundle"].forEach(t=>{this[t]=function(){return e.store[t](...arguments),e}});const i=aD(),a=()=>{const e=(e,t)=>{this.isInitializing=!1,this.isInitialized&&!this.initializedStoreOnce&&this.logger.warn("init: i18next is already initialized. You should call init just once!"),this.isInitialized=!0,this.options.isClone||this.logger.log("initialized",this.options),this.emit("initialized",this.options),i.resolve(t),r(e,t)};if(this.languages&&"v1"!==this.options.compatibilityAPI&&!this.isInitialized)return e(null,this.t.bind(this));this.changeLanguage(this.options.lng,e)};return this.options.resources||!this.options.initImmediate?a():setTimeout(a,0),i}loadResources(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:WD;const r=iD(e)?e:this.language;if("function"==typeof e&&(t=e),!this.options.resources||this.options.partialBundledLanguages){if(r&&"cimode"===r.toLowerCase()&&(!this.options.preload||0===this.options.preload.length))return t();const e=[],n=t=>{if(!t)return;if("cimode"===t)return;this.services.languageUtils.toResolveHierarchy(t).forEach(t=>{"cimode"!==t&&e.indexOf(t)<0&&e.push(t)})};if(r)n(r);else{this.services.languageUtils.getFallbackCodes(this.options.fallbackLng).forEach(e=>n(e))}this.options.preload&&this.options.preload.forEach(e=>n(e)),this.services.backendConnector.load(e,this.options.ns,e=>{e||this.resolvedLanguage||!this.language||this.setResolvedLanguage(this.language),t(e)})}else t(null)}reloadResources(e,t,r){const n=aD();return"function"==typeof e&&(r=e,e=void 0),"function"==typeof t&&(r=t,t=void 0),e||(e=this.languages),t||(t=this.options.ns),r||(r=WD),this.services.backendConnector.reload(e,t,e=>{n.resolve(),r(e)}),n}use(e){if(!e)throw new Error("You are passing an undefined module! Please check the object you are passing to i18next.use()");if(!e.type)throw new Error("You are passing a wrong module! Please check the object you are passing to i18next.use()");return"backend"===e.type&&(this.modules.backend=e),("logger"===e.type||e.log&&e.warn&&e.error)&&(this.modules.logger=e),"languageDetector"===e.type&&(this.modules.languageDetector=e),"i18nFormat"===e.type&&(this.modules.i18nFormat=e),"postProcessor"===e.type&&SD.addPostProcessor(e),"formatter"===e.type&&(this.modules.formatter=e),"3rdParty"===e.type&&this.modules.external.push(e),this}setResolvedLanguage(e){if(e&&this.languages&&!(["cimode","dev"].indexOf(e)>-1))for(let e=0;e<this.languages.length;e++){const t=this.languages[e];if(!(["cimode","dev"].indexOf(t)>-1)&&this.store.hasLanguageSomeTranslations(t)){this.resolvedLanguage=t;break}}}changeLanguage(e,t){var r=this;this.isLanguageChangingTo=e;const n=aD();this.emit("languageChanging",e);const o=e=>{this.language=e,this.languages=this.services.languageUtils.toResolveHierarchy(e),this.resolvedLanguage=void 0,this.setResolvedLanguage(e)},i=(e,i)=>{i?(o(i),this.translator.changeLanguage(i),this.isLanguageChangingTo=void 0,this.emit("languageChanged",i),this.logger.log("languageChanged",i)):this.isLanguageChangingTo=void 0,n.resolve(function(){return r.t(...arguments)}),t&&t(e,function(){return r.t(...arguments)})},a=t=>{e||t||!this.services.languageDetector||(t=[]);const r=iD(t)?t:this.services.languageUtils.getBestMatchFromCodes(t);r&&(this.language||o(r),this.translator.language||this.translator.changeLanguage(r),this.services.languageDetector&&this.services.languageDetector.cacheUserLanguage&&this.services.languageDetector.cacheUserLanguage(r)),this.loadResources(r,e=>{i(e,r)})};return e||!this.services.languageDetector||this.services.languageDetector.async?!e&&this.services.languageDetector&&this.services.languageDetector.async?0===this.services.languageDetector.detect.length?this.services.languageDetector.detect().then(a):this.services.languageDetector.detect(a):a(e):a(this.services.languageDetector.detect()),n}getFixedT(e,t,r){var n=this;const o=function(e,t){let i;if("object"!=typeof t){for(var a=arguments.length,s=new Array(a>2?a-2:0),u=2;u<a;u++)s[u-2]=arguments[u];i=n.options.overloadTranslationOptionHandler([e,t].concat(s))}else i={...t};i.lng=i.lng||o.lng,i.lngs=i.lngs||o.lngs,i.ns=i.ns||o.ns,""!==i.keyPrefix&&(i.keyPrefix=i.keyPrefix||r||o.keyPrefix);const l=n.options.keySeparator||".";let c;return c=i.keyPrefix&&Array.isArray(e)?e.map(e=>`${i.keyPrefix}${l}${e}`):i.keyPrefix?`${i.keyPrefix}${l}${e}`:e,n.t(c,i)};return iD(e)?o.lng=e:o.lngs=e,o.ns=t,o.keyPrefix=r,o}t(){return this.translator&&this.translator.translate(...arguments)}exists(){return this.translator&&this.translator.exists(...arguments)}setDefaultNamespace(e){this.options.defaultNS=e}hasLoadedNamespace(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if(!this.isInitialized)return this.logger.warn("hasLoadedNamespace: i18next was not initialized",this.languages),!1;if(!this.languages||!this.languages.length)return this.logger.warn("hasLoadedNamespace: i18n.languages were undefined or empty",this.languages),!1;const r=t.lng||this.resolvedLanguage||this.languages[0],n=!!this.options&&this.options.fallbackLng,o=this.languages[this.languages.length-1];if("cimode"===r.toLowerCase())return!0;const i=(e,t)=>{const r=this.services.backendConnector.state[`${e}|${t}`];return-1===r||0===r||2===r};if(t.precheck){const e=t.precheck(this,i);if(void 0!==e)return e}return!!this.hasResourceBundle(r,e)||(!(this.services.backendConnector.backend&&(!this.options.resources||this.options.partialBundledLanguages))||!(!i(r,e)||n&&!i(o,e)))}loadNamespaces(e,t){const r=aD();return this.options.ns?(iD(e)&&(e=[e]),e.forEach(e=>{this.options.ns.indexOf(e)<0&&this.options.ns.push(e)}),this.loadResources(e=>{r.resolve(),t&&t(e)}),r):(t&&t(),Promise.resolve())}loadLanguages(e,t){const r=aD();iD(e)&&(e=[e]);const n=this.options.preload||[],o=e.filter(e=>n.indexOf(e)<0&&this.services.languageUtils.isSupportedCode(e));return o.length?(this.options.preload=n.concat(o),this.loadResources(e=>{r.resolve(),t&&t(e)}),r):(t&&t(),Promise.resolve())}dir(e){if(e||(e=this.resolvedLanguage||(this.languages&&this.languages.length>0?this.languages[0]:this.language)),!e)return"rtl";const t=this.services&&this.services.languageUtils||new TD(UD());return["ar","shu","sqr","ssh","xaa","yhd","yud","aao","abh","abv","acm","acq","acw","acx","acy","adf","ads","aeb","aec","afb","ajp","apc","apd","arb","arq","ars","ary","arz","auz","avl","ayh","ayl","ayn","ayp","bbz","pga","he","iw","ps","pbt","pbu","pst","prp","prd","ug","ur","ydd","yds","yih","ji","yi","hbo","men","xmn","fa","jpr","peo","pes","prs","dv","sam","ckb"].indexOf(t.getLanguagePartFromCode(e))>-1||e.toLowerCase().indexOf("-arab")>1?"rtl":"ltr"}static createInstance(){return new GD(arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},arguments.length>1?arguments[1]:void 0)}cloneInstance(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:WD;const r=e.forkResourceStore;r&&delete e.forkResourceStore;const n={...this.options,...e,isClone:!0},o=new GD(n);void 0===e.debug&&void 0===e.prefix||(o.logger=o.logger.clone(e));return["store","services","language"].forEach(e=>{o[e]=this[e]}),o.services={...this.services},o.services.utils={hasLoadedNamespace:o.hasLoadedNamespace.bind(o)},r&&(o.store=new BD(this.store.data,n),o.services.resourceStore=o.store),o.translator=new kD(o.services,n),o.translator.on("*",function(e){for(var t=arguments.length,r=new Array(t>1?t-1:0),n=1;n<t;n++)r[n-1]=arguments[n];o.emit(e,...r)}),o.init(n,t),o.translator.options=n,o.translator.backendConnector.services.utils={hasLoadedNamespace:o.hasLoadedNamespace.bind(o)},o}toJSON(){return{options:this.options,store:this.store,language:this.language,languages:this.languages,resolvedLanguage:this.resolvedLanguage}}}const YD=GD.createInstance();YD.createInstance=GD.createInstance,YD.createInstance,YD.dir,YD.init,YD.loadResources,YD.reloadResources,YD.use,YD.changeLanguage,YD.getFixedT,YD.t,YD.exists,YD.setDefaultNamespace,YD.hasLoadedNamespace,YD.loadNamespaces,YD.loadLanguages;var KD="translation";function XD(e,t){YD.addResourceBundle(e,KD,t,!0,!0)}function ZD(e){YD.changeLanguage(e)}function JD(e){return YD.getResourceBundle(e,KD)}function QD(e){return YD.on("languageChanged",e),function(){return YD.off("languageChanged",e)}}YD.init({lng:"zh-CN",resources:{}});var eC=YD.t.bind(YD);function tC(e){if(e.removeAttr){e.removeAttr("width"),e.removeAttr("height"),e.removeAttr("fill"),e.removeAttr("class"),e.removeAttr("t"),e.removeAttr("p-id");var t=e.children();t.length&&tC(t)}}function rC(){return ov('<svg viewBox="0 0 1024 1024"><path d="M498.7 655.8l-197.6-268c-8.1-10.9-0.3-26.4 13.3-26.4h395.2c13.6 0 21.4 15.4 13.3 26.4l-197.6 268c-6.6 9-20 9-26.6 0z"></path></svg>')}function nC(){return ov('<div class="w-e-bar-divider"></div>')}function oC(e,t,r,n,o){if(void 0===n&&(n=""),void 0===o&&(o=!1),t){if(n){var i=ky?"cmd":"ctrl";n=n.replace("mod",i)}if(o)n&&(e.attr("data-tooltip",n),e.addClass("w-e-menu-tooltip-v5"),e.addClass("tooltip-right"));else{var a=n?"".concat(r,"\n").concat(n):r;e.attr("data-tooltip",a),e.addClass("w-e-menu-tooltip-v5")}}}var iC=function(){function e(e,t,r){void 0===r&&(r=!1);var n=this;this.$elem=ov('<div class="w-e-bar-item"></div>'),this.$button=ov('<button type="button"></button>'),this.disabled=!1,this.menu=t;var o=t.tag,i=t.width;if("button"!==o)throw new Error("Invalid tag '".concat(o,"', expected 'button'"));var a=t.title,s=t.hotkey,u=void 0===s?"":s,l=t.iconSvg,c=void 0===l?"":l,d=this.$button;if(c){var h=ov(c);tC(h),d.append(h)}else d.text(a);oC(d,c,a,u,r),r&&c&&d.append(ov('<span class="title">'.concat(a,"</span>"))),i&&d.css("width","".concat(i,"px")),d.attr("data-menu-key",e),this.$elem.append(d),jv(function(){return n.init()})}return e.prototype.init=function(){var e=this;this.setActive(),this.setDisabled(),this.$button.on("click",function(t){t.preventDefault(),bC(e).hidePanelOrModal(),e.disabled||(e.exec(),e.onButtonClick())})},e.prototype.exec=function(){var e=bC(this),t=this.menu,r=t.getValue(e);this.setIcon(),this.setTooltip(),t.exec(e,r)},e.prototype.setActive=function(){var e=bC(this),t=this.$button,r="active";this.menu.isActive(e)?t.addClass(r):t.removeClass(r)},e.prototype.setDisabled=function(){var e=bC(this),t=this.$button,r=this.menu.isDisabled(e);(null==e.selection||e.isDisabled())&&(r=!0),this.menu.alwaysEnable&&(r=!1);var n="disabled";r?t.addClass(n):t.removeClass(n),this.disabled=r},e.prototype.setIcon=function(){var e=bC(this),t=this.$button;if(this.menu.getIcon){var r=this.menu.getIcon(e);if(r){t.find("svg").remove();var n=ov(r);tC(n),t.append(n)}}},e.prototype.setTooltip=function(){var e=bC(this),t=this.$button;if(this.menu.getTitle){var r=this.menu.getTitle(e),n=this.menu.iconSvg;r&&n&&oC(t,n,r)}},e.prototype.changeMenuState=function(){this.setActive(),this.setDisabled()},e}(),aC=function(e){function t(t,r,n){return void 0===n&&(n=!1),e.call(this,t,r,n)||this}return Yg(t,e),t.prototype.onButtonClick=function(){},t}(iC),sC=function(){function e(e){this.isShow=!1,this.showTime=0,this.record(e)}return e.prototype.record=function(e){var t=Bm.get(e);null==t&&(t=new Set,Bm.set(e,t)),t.add(this),Sm.set(this,e)},e.prototype.renderContent=function(e){var t=this.$elem;t.empty(),t.append(e);var r=this.genSelfElem();r&&t.append(r)},e.prototype.appendTo=function(e){var t=this.$elem;e.append(t)},e.prototype.show=function(){if(!this.isShow){this.showTime=Date.now(),this.$elem.show(),this.isShow=!0;var e=Sm.get(this);e&&e.emit("modalOrPanelShow",this)}},e.prototype.hide=function(){if(this.isShow&&!(Date.now()-this.showTime<200)){this.$elem.hide(),this.isShow=!1;var e=Sm.get(this);e&&e.emit("modalOrPanelHide")}},e}(),uC=function(e){function t(t){var r=e.call(this,t)||this;return r.type="dropPanel",r.$elem=ov('<div class="w-e-drop-panel"></div>'),r}return Yg(t,e),t.prototype.genSelfElem=function(){return null},t}(sC),lC=function(e){function t(t,r,n){void 0===n&&(n=!1);var o=e.call(this,t,r,n)||this;if(o.dropPanel=null,o.menu=r,r.showDropPanel){var i=rC();o.$button.append(i)}return o}return Yg(t,e),t.prototype.onButtonClick=function(){this.menu.showDropPanel&&this.handleDropPanel()},t.prototype.handleDropPanel=function(){var e=this.menu;if(null!=e.getPanelContentElem){var t=bC(this);if(null==this.dropPanel){var r=new uC(t),n=e.getPanelContentElem(t);r.renderContent(n),r.appendTo(this.$elem),r.show(),this.dropPanel=r}else{var o=this.dropPanel;if(o.isShow)o.hide();else{n=e.getPanelContentElem(t);o.renderContent(n),o.show()}}var i=this.dropPanel;if(i.isShow){var a=this.$elem,s=a.offset().left,u=a.parents(".w-e-bar");s-u.offset().left>=u.width()/2?i.$elem.css({left:"none",right:"0"}):i.$elem.css({left:"0",right:"none"})}}},t}(iC),cC=function(e){function t(t,r){void 0===r&&(r=0);var n=e.call(this,t)||this;n.type="modal",n.$elem=ov('<div class="w-e-modal"></div>'),n.width=0,r&&(n.width=r);var o=n.$elem;return o.on("click",function(e){return e.stopPropagation()}),o.on("keyup",function(e){"Escape"===e.code&&(n.hide(),t.restoreSelection())}),n}return Yg(t,e),t.prototype.genSelfElem=function(){var e=this,t=ov('<span class="btn-close">'.concat('<svg viewBox="0 0 1024 1024"><path d="M1024 896.1024l-128 128L512 640 128 1024 0 896 384 512 0 128 128 0 512 384 896.1024 0l128 128L640 512z"></path></svg>',"</span>")),r=Sm.get(this);return t.on("click",function(){e.hide(),null==r||r.restoreSelection()}),t},t.prototype.setStyle=function(e){var t=this.width,r=this.$elem;r.attr("style",""),t&&r.css("width","".concat(t,"px")),r.css(e)},t}(sC);function dC(e,t,r){var n=ov('<label class="babel-container"></label>');n.append("<span>".concat(e,"</span>"));var o=ov('<input type="text" id="'.concat(t,'" placeholder="').concat(r||"",'">'));return n.append(o),[n[0],o[0]]}function hC(e,t,r){var n=ov('<label class="babel-container"></label>');n.append("<span>".concat(e,"</span>"));var o=ov('<textarea type="text" id="'.concat(t,'" placeholder="').concat(r||"",'"></textarea>'));return n.append(o),[n[0],o[0]]}function fC(e,t){var r=ov('<div class="button-container"></div>'),n=ov('<button type="button" id="'.concat(e,'">').concat(t,"</button>"));return r.append(n),[r[0],n[0]]}var pC=function(e){function t(t,r,n){void 0===n&&(n=!1);var o=e.call(this,t,r,n)||this;return o.$body=ov("body"),o.modal=null,o.menu=r,o}return Yg(t,e),t.prototype.onButtonClick=function(){this.menu.showModal&&this.handleModal()},t.prototype.getPosition=function(){var e=bC(this),t=this.menu.getModalPositionNode(e);return Vp.isElement(t)?Jb(e,t,"modal"):Zb(e)},t.prototype.handleModal=function(){var e=bC(this),t=this.menu;if(null==this.modal){var r=new cC(e,t.modalWidth);this.renderAndShowModal(r,!0),this.modal=r}else{(r=this.modal).isShow?r.hide():this.renderAndShowModal(r,!1)}},t.prototype.renderAndShowModal=function(e,t){void 0===t&&(t=!1);var r=bC(this),n=this.menu;if(null!=n.getModalContentElem){var o=Ry.getTextarea(r),i=Ry.getToolbar(r),a=((null==i?void 0:i.getConfig())||{}).modalAppendToBody,s=n.getModalContentElem(r);if(e.renderContent(s),a)e.setStyle({left:"0",right:"0"});else{var u=this.getPosition();e.setStyle(u)}t&&(a?e.appendTo(this.$body):e.appendTo(o.$textAreaContainer)),e.show(),a||Qb(r,e.$elem),setTimeout(function(){r.blur()})}},t}(iC);var gC=function(e){function t(t,r){var n=e.call(this,t)||this;return n.type="selectList",n.$elem=ov('<div class="w-e-select-list"></div>'),r&&n.$elem.css("width","".concat(r,"px")),n.$elem.on("click",function(e){e.stopPropagation()}),n}return Yg(t,e),t.prototype.renderList=function(e){var t=this.$elem;t.empty();var r=ov("<ul></ul>");e.forEach(function(e){var t=e.value,n=e.text,o=e.selected,i=e.styleForRenderMenuList,a=ov('<li data-value="'.concat(t,'"></li>'));if(i&&a.css(i),o){var s=ov('<svg viewBox="0 0 1446 1024"><path d="M574.116299 786.736392 1238.811249 48.517862C1272.390222 11.224635 1329.414799 7.827718 1366.75664 41.450462 1403.840015 74.840484 1406.731043 132.084741 1373.10189 169.433699L655.118888 966.834607C653.072421 969.716875 650.835807 972.514337 648.407938 975.210759 615.017957 1012.29409 558.292155 1015.652019 521.195664 982.250188L72.778218 578.493306C35.910826 545.297758 32.859041 488.584019 66.481825 451.242134 99.871807 414.158803 156.597563 410.800834 193.694055 444.202665L574.116299 786.736392Z"></path></svg>');a.append(s),a.addClass("selected")}a.append(ov('<span data-value="'.concat(t,'">').concat(n,"</span>"))),a.attr("title",n),r.append(a)}),t.append(r)},t.prototype.genSelfElem=function(){return null},t}(sC);var mC=function(){function e(e,t,r){void 0===r&&(r=!1);var n=this;this.$elem=ov('<div class="w-e-bar-item"></div>'),this.$button=ov('<button type="button" class="select-button"></button>'),this.disabled=!1,this.selectList=null;var o=t.tag,i=t.title,a=t.width,s=t.iconSvg,u=void 0===s?"":s,l=t.hotkey,c=void 0===l?"":l;if("select"!==o)throw new Error("Invalid tag '".concat(o,"', expected 'select'"));var d=this.$button;a&&d.css("width","".concat(a,"px")),d.attr("data-menu-key",e),oC(d,u,i,c,r),this.$elem.append(d),this.menu=t,jv(function(){return n.init()})}return e.prototype.init=function(){var e=this;this.setSelectedValue(),this.$button.on("click",function(t){t.preventDefault(),bC(e).hidePanelOrModal(),e.trigger()})},e.prototype.trigger=function(){var e=this,t=bC(this);if(!t.isDisabled()&&!this.disabled){var r=this.menu;if(null==this.selectList){this.selectList=new gC(t,r.selectPanelWidth);var n=this.selectList,o=r.getOptions(t);n.renderList(o),n.appendTo(this.$elem),n.show(),n.$elem.on("click","li",function(t){var r=t.target;if(null!=r){t.preventDefault();var n=ov(r).attr("data-value");e.onChange(n)}})}else{if((n=this.selectList).isShow)n.hide();else{o=r.getOptions(t);n.renderList(o),n.show()}}}},e.prototype.onChange=function(e){var t=bC(this),r=this.menu;r.exec&&r.exec(t,e)},e.prototype.setSelectedValue=function(){var e=bC(this),t=this.menu,r=t.getValue(e),n=function(e,t){for(var r=e.length,n="",o=0;o<r;o++){var i=e[o];if(i.value===t){n=i.text;break}}return n}(t.getOptions(e),r.toString()),o=this.$button,i=rC();o.empty(),o.text(n),o.append(i)},e.prototype.setDisabled=function(){var e=bC(this),t=this.menu.isDisabled(e),r=this.$button;(null==e.selection||e.isDisabled())&&(t=!0);var n="disabled";t?r.addClass(n):r.removeClass(n),this.disabled=t},e.prototype.changeMenuState=function(){this.setSelectedValue(),this.setDisabled()},e}(),vC=function(){function e(e){this.$elem=ov('<div class="w-e-bar-item w-e-bar-item-group"></div>'),this.$container=ov('<div class="w-e-bar-item-menus-container"></div>'),this.$button=ov('<button type="button"></button>');var t=e.key,r=e.iconSvg,n=e.title,o=this.$elem,i=this.$button;if(r){var a=ov(r);tC(a),i.append(a)}else i.text(n);i.attr("data-menu-key",t);var s=rC();i.append(s),o.append(i);var u=this.$container;o.append(u);var l=this.createObserver();this.observe(l)}return e.prototype.appendBarItem=function(e){var t=e.$elem;this.$container.append(t)},e.prototype.observe=function(e){var t=this.$container;e.observe(t[0],{childList:!0,subtree:!0,attributes:!0})},e.prototype.createObserver=function(){var e=this,t=this.$container,r=this.$button,n=new MutationObserver(function(){var o=t.find("button"),i=o.length;if(0!==i){var a=0;o.each(function(e){ov(e).hasClass("disabled")&&a++}),n.disconnect(),a===i?r.addClass("disabled"):r.removeClass("disabled"),e.observe(n)}});return n},e}(),yC=new WeakMap;function bC(e){var t=xm.get(e);if(null==t)throw new Error("Can not get editor instance");return t}function DC(e,t,r){void 0===r&&(r=!1);var n=yC.get(t);if(n)return n;var o=t.tag;if("button"===o){var i=t.showDropPanel,a=t.showModal;n=i?new lC(e,t,r):a?new pC(e,t,r):new aC(e,t,r)}if("select"===o&&(n=new mC(e,t,r)),null==n)throw new Error("Invalid tag in menu ".concat(JSON.stringify(t)));return yC.set(t,n),n}function CC(e,t){var r=e.selection;return null!=r&&(!hg.isCollapsed(r)&&(!Ry.getSelectedElems(e).some(function(t){if(e.isVoid(t))return!0;var r=t.type;return!!["pre","code","table"].includes(r)})&&!!Cg.isText(t)))}var wC,EC,AC=function(){function e(){var e=this;this.$elem=ov('<div class="w-e-bar w-e-bar-hidden w-e-hover-bar"></div>'),this.menus={},this.hoverbarItems=[],this.prevSelectedNode=null,this.isShow=!1,this.lngListen=function(){},this.changeHoverbarState=oD(function(){var t=e.isShow,r=e.getSelectedNodeAndMenuKeys()||{},n=r.node,o=void 0===n?null:n,i=r.menuKeys,a=void 0===i?[]:i,s=e.getEditorInstance();if(null!=o&&e.changeItemsState(),o&&Vp.isElement(o)&&t){var u=e.isSamePath(o,e.prevSelectedNode);if(!Yp.isBlock(s,o)&&u)return}e.hideAndClean(),null!=o&&(e.registerItems(a),e.setPosition(o),e.show()),e.prevSelectedNode=o},200),jv(function(){var t=e.getEditorInstance(),r=e.$elem;r.on("mousedown",function(e){return e.preventDefault()},{passive:!1}),Ry.getTextarea(t).$textAreaContainer.append(r),t.on(fm,e.changeHoverbarState);var n=e.hideAndClean.bind(e);t.on(pm,n),t.on(gm,n),t.on(mm,n)}),this.lngListen=QD(function(){e.menus={},e.hideAndClean(),e.getEditorInstance().deselect()})}return e.prototype.getMenus=function(){return this.menus},e.prototype.hideAndClean=function(){var e=this.$elem;e.removeClass("w-e-bar-show").addClass("w-e-bar-hidden"),this.hoverbarItems=[],e.empty(),this.isShow=!1},e.prototype.checkPositionBottom=function(){var e=this.$elem,t=!1,r="undefined"!=typeof window?window.innerHeight:null;r&&r>=360&&(r-e[0].getBoundingClientRect().bottom<360&&(t=!0));t?e.addClass("w-e-bar-bottom"):e.removeClass("w-e-bar-bottom")},e.prototype.show=function(){this.$elem.removeClass("w-e-bar-hidden").addClass("w-e-bar-show"),this.isShow=!0,this.checkPositionBottom()},e.prototype.changeItemsState=function(){var e=this;jv(function(){e.hoverbarItems.forEach(function(e){e.changeMenuState()})})},e.prototype.registerItems=function(e){var t=this,r=this.$elem;e.forEach(function(e){if("|"!==e)t.registerSingleItem(e);else{var n=nC();r.append(n)}})},e.prototype.registerSingleItem=function(e){var t=this.getEditorInstance(),r=this.menus,n=r[e];if(null==n){var o=vm[e];if(null==o)throw new Error("Not found menu item factory by key '".concat(e,"'"));if("function"!=typeof o)throw new Error("Menu item factory (key='".concat(e,"') is not a function"));n=o(),r[e]=n}var i=t.getMenuConfig(e);i&&void 0!==i.iconSvg&&(n.iconSvg=i.iconSvg);var a=DC(e,n);this.hoverbarItems.push(a),xm.set(a,t),this.$elem.append(a.$elem)},e.prototype.setPosition=function(e){var t=this.getEditorInstance(),r=this.$elem;if(r.attr("style",""),Vp.isElement(e)){var n=Jb(t,e,"bar");return r.css(n),void Qb(t,r)}if(Cg.isText(e)){n=Zb(t);return r.css(n),void Qb(t,r)}throw new Error("hoverbar.setPosition error, current selected node is not elem nor text")},e.prototype.getSelectedNodeAndMenuKeys=function(){var e=this.getEditorInstance();if(null==e.selection)return null;var t=this.getHoverbarKeysConf(),r=null,n=[],o=function(o){var i=t[o],a=i.match,s=i.menuKeys,u=void 0===s?[]:s,l=a||function(e,t){return Ry.checkNodeType(t,o)},c=Qg(Yp.nodes(e,{match:function(t){return l(e,t)},universal:!0}),1),d=c[0];if(null!=d)return r=d[0],n=u,"break"};for(var i in t){if("break"===o(i))break}return null==r||0===n.length?null:{node:r,menuKeys:n}},e.prototype.getEditorInstance=function(){var e=Em.get(this);if(null==e)throw new Error("Can not get editor instance");return e},e.prototype.getHoverbarKeysConf=function(){var e=this.getEditorInstance().getConfig().hoverbarKeys,t=void 0===e?{}:e,r=t.text;return r&&null==r.match&&(r.match=CC),t},e.prototype.isSamePath=function(e,t){if(null==e||null==t)return!1;var r=Ry.findPath(null,e),n=Ry.findPath(null,t);return og.equals(r,n)},e.prototype.destroy=function(){var e;this.changeHoverbarState.cancel(),this.$elem.remove(),null===(e=this.lngListen)||void 0===e||e.call(this),this.menus={},this.hoverbarItems=[],this.prevSelectedNode=null},e}();function xC(){if(EC)return wC;EC=1;var e="Expected a function",t=/^\s+|\s+$/g,r=/^[-+]0x[0-9a-f]+$/i,n=/^0b[01]+$/i,o=/^0o[0-7]+$/i,i=parseInt,a="object"==typeof y&&y&&y.Object===Object&&y,s="object"==typeof self&&self&&self.Object===Object&&self,u=a||s||Function("return this")(),l=Object.prototype.toString,c=Math.max,d=Math.min,h=function(){return u.Date.now()};function f(t,r,n){var o,i,a,s,u,l,f=0,m=!1,v=!1,y=!0;if("function"!=typeof t)throw new TypeError(e);function b(e){var r=o,n=i;return o=i=void 0,f=e,s=t.apply(n,r)}function D(e){var t=e-l;return void 0===l||t>=r||t<0||v&&e-f>=a}function C(){var e=h();if(D(e))return w(e);u=setTimeout(C,function(e){var t=r-(e-l);return v?d(t,a-(e-f)):t}(e))}function w(e){return u=void 0,y&&o?b(e):(o=i=void 0,s)}function E(){var e=h(),t=D(e);if(o=arguments,i=this,l=e,t){if(void 0===u)return function(e){return f=e,u=setTimeout(C,r),m?b(e):s}(l);if(v)return u=setTimeout(C,r),b(l)}return void 0===u&&(u=setTimeout(C,r)),s}return r=g(r)||0,p(n)&&(m=!!n.leading,a=(v="maxWait"in n)?c(g(n.maxWait)||0,r):a,y="trailing"in n?!!n.trailing:y),E.cancel=function(){void 0!==u&&clearTimeout(u),f=0,o=l=i=u=void 0},E.flush=function(){return void 0===u?s:w(h())},E}function p(e){var t=typeof e;return!!e&&("object"==t||"function"==t)}function g(e){if("number"==typeof e)return e;if(function(e){return"symbol"==typeof e||function(e){return!!e&&"object"==typeof e}(e)&&"[object Symbol]"==l.call(e)}(e))return NaN;if(p(e)){var a="function"==typeof e.valueOf?e.valueOf():e;e=p(a)?a+"":a}if("string"!=typeof e)return 0===e?e:+e;e=e.replace(t,"");var s=n.test(e);return s||o.test(e)?i(e.slice(2),s?2:8):r.test(e)?NaN:+e}return wC=function(t,r,n){var o=!0,i=!0;if("function"!=typeof t)throw new TypeError(e);return p(n)&&(o="leading"in n?!!n.leading:o,i="trailing"in n?!!n.trailing:i),f(t,r,{leading:o,maxWait:r,trailing:i})}}var BC=b(xC());function SC(e,t){return qv(t)&&Ry.hasDOMNode(e,t,{editable:!0})}function FC(e,t){if(e.getConfig().readOnly)return!1;var r=kC(e,t)&&Ry.toSlateNode(e,t);return Yp.isVoid(e,r)}function kC(e,t){return qv(t)&&Ry.hasDOMNode(e,t)}const OC=e=>"object"==typeof e&&null!=e&&1===e.nodeType,TC=(e,t)=>(!t||"hidden"!==e)&&"visible"!==e&&"clip"!==e,NC=(e,t)=>{if(e.clientHeight<e.scrollHeight||e.clientWidth<e.scrollWidth){const r=getComputedStyle(e,null);return TC(r.overflowY,t)||TC(r.overflowX,t)||(e=>{const t=(e=>{if(!e.ownerDocument||!e.ownerDocument.defaultView)return null;try{return e.ownerDocument.defaultView.frameElement}catch(e){return null}})(e);return!!t&&(t.clientHeight<e.scrollHeight||t.clientWidth<e.scrollWidth)})(e)}return!1},PC=(e,t,r,n,o,i,a,s)=>i<e&&a>t||i>e&&a<t?0:i<=e&&s<=r||a>=t&&s>=r?i-e-n:a>t&&s<r||i<e&&s>r?a-t+o:0,MC=e=>{const t=e.parentElement;return null==t?e.getRootNode().host||null:t},IC=(e,t)=>{var r,n,o,i;if("undefined"==typeof document)return[];const{scrollMode:a,block:s,inline:u,boundary:l,skipOverflowHiddenElements:c}=t,d="function"==typeof l?l:e=>e!==l;if(!OC(e))throw new TypeError("Invalid target");const h=document.scrollingElement||document.documentElement,f=[];let p=e;for(;OC(p)&&d(p);){if(p=MC(p),p===h){f.push(p);break}null!=p&&p===document.body&&NC(p)&&!NC(document.documentElement)||null!=p&&NC(p,c)&&f.push(p)}const g=null!=(n=null==(r=window.visualViewport)?void 0:r.width)?n:innerWidth,m=null!=(i=null==(o=window.visualViewport)?void 0:o.height)?i:innerHeight,{scrollX:v,scrollY:y}=window,{height:b,width:D,top:C,right:w,bottom:E,left:A}=e.getBoundingClientRect(),{top:x,right:B,bottom:S,left:F}=(e=>{const t=window.getComputedStyle(e);return{top:parseFloat(t.scrollMarginTop)||0,right:parseFloat(t.scrollMarginRight)||0,bottom:parseFloat(t.scrollMarginBottom)||0,left:parseFloat(t.scrollMarginLeft)||0}})(e);let k="start"===s||"nearest"===s?C-x:"end"===s?E+S:C+b/2-x+S,O="center"===u?A+D/2-F+B:"end"===u?w+B:A-F;const T=[];for(let e=0;e<f.length;e++){const t=f[e],{height:r,width:n,top:o,right:i,bottom:l,left:c}=t.getBoundingClientRect();if("if-needed"===a&&C>=0&&A>=0&&E<=m&&w<=g&&(t===h&&!NC(t)||C>=o&&E<=l&&A>=c&&w<=i))return T;const d=getComputedStyle(t),p=parseInt(d.borderLeftWidth,10),x=parseInt(d.borderTopWidth,10),B=parseInt(d.borderRightWidth,10),S=parseInt(d.borderBottomWidth,10);let F=0,N=0;const P="offsetWidth"in t?t.offsetWidth-t.clientWidth-p-B:0,M="offsetHeight"in t?t.offsetHeight-t.clientHeight-x-S:0,I="offsetWidth"in t?0===t.offsetWidth?0:n/t.offsetWidth:0,R="offsetHeight"in t?0===t.offsetHeight?0:r/t.offsetHeight:0;if(h===t)F="start"===s?k:"end"===s?k-m:"nearest"===s?PC(y,y+m,m,x,S,y+k,y+k+b,b):k-m/2,N="start"===u?O:"center"===u?O-g/2:"end"===u?O-g:PC(v,v+g,g,p,B,v+O,v+O+D,D),F=Math.max(0,F+y),N=Math.max(0,N+v);else{F="start"===s?k-o-x:"end"===s?k-l+S+M:"nearest"===s?PC(o,l,r,x,S+M,k,k+b,b):k-(o+r/2)+M/2,N="start"===u?O-c-p:"center"===u?O-(c+n/2)+P/2:"end"===u?O-i+B+P:PC(c,i,n,p,B+P,O,O+D,D);const{scrollLeft:e,scrollTop:a}=t;F=0===R?0:Math.max(0,Math.min(a+F/R,t.scrollHeight-r/R+M)),N=0===I?0:Math.max(0,Math.min(e+N/I,t.scrollWidth-n/I+P)),k+=a-F,O+=e-N}T.push({el:t,top:F,left:N})}return T};function RC(e,t){if(!e.isConnected||!(e=>{let t=e;for(;t&&t.parentNode;){if(t.parentNode===document)return!0;t=t.parentNode instanceof ShadowRoot?t.parentNode.host:t.parentNode}return!1})(e))return;const r=(e=>{const t=window.getComputedStyle(e);return{top:parseFloat(t.scrollMarginTop)||0,right:parseFloat(t.scrollMarginRight)||0,bottom:parseFloat(t.scrollMarginBottom)||0,left:parseFloat(t.scrollMarginLeft)||0}})(e);if((e=>"object"==typeof e&&"function"==typeof e.behavior)(t))return t.behavior(IC(e,t));const n="boolean"==typeof t||null==t?void 0:t.behavior;for(const{el:o,top:i,left:a}of IC(e,(e=>!1===e?{block:"end",inline:"nearest"}:(e=>e===Object(e)&&0!==Object.keys(e).length)(e)?e:{block:"start",inline:"nearest"})(t))){const e=i-r.top+r.bottom,t=a-r.left+r.right;o.scroll({top:e,left:t,behavior:n})}}function LC(e,t,r){void 0===r&&(r=!1);var n=t.selection,o=t.getConfig(),i=Ry.findDocumentOrShadowRoot(t).getSelection();if(i&&(!e.isComposing||r)&&t.isFocused()){var a="None"!==i.type;if(n||a){var s=Rm.get(t),u=!1;if(s.contains(i.anchorNode)&&s.contains(i.focusNode)&&(u=!0),a&&u&&n){var l=Ry.toSlateRange(t,i,{exactMatch:!0,suppressThrow:!0});if(l&&hg.equals(l,n)){var c=!0;if(hg.isCollapsed(n)){var d=i.anchorNode,h=i.anchorOffset;if(d===s){var f=s.childNodes,p=void 0;(p=f[h])&&p.matches("table")&&(c=!1),(p=f[h-1])&&p.matches("table")&&(c=!1)}}if(c)return}}if(!n||Ry.hasRange(t,n)){e.isUpdatingSelection=!0;var g=n&&Ry.toDOMRange(t,n);if(g){hg.isBackward(n)?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]")&&g.getBoundingClientRect){m.getBoundingClientRect=g.getBoundingClientRect.bind(g);var v=document.body;RC(m,{scrollMode:"if-needed",boundary:o.scroll?s.parentElement:v,block:"end",behavior:"smooth"}),delete m.getBoundingClientRect}}else i.removeAllRanges();setTimeout(function(){g&&Oy&&s.focus(),e.isUpdatingSelection=!1})}else t.selection=Ry.toSlateRange(t,i,{exactMatch:!1,suppressThrow:!1})}}}var _C=new WeakMap,zC=new WeakMap;var jC,HC={};var VC=function(){if(jC)return HC;jC=1,Object.defineProperty(HC,"__esModule",{value:!0});for(var e="undefined"!=typeof window&&/Mac|iPod|iPhone|iPad/.test(window.navigator.platform),t={alt:"altKey",control:"ctrlKey",meta:"metaKey",shift:"shiftKey"},r={add:"+",break:"pause",cmd:"meta",command:"meta",ctl:"control",ctrl:"control",del:"delete",down:"arrowdown",esc:"escape",ins:"insert",left:"arrowleft",mod:e?"meta":"control",opt:"alt",option:"alt",return:"enter",right:"arrowright",space:" ",spacebar:" ",up:"arrowup",win:"meta",windows:"meta"},n={backspace:8,tab:9,enter:13,shift:16,control:17,alt:18,pause:19,capslock:20,escape:27," ":32,pageup:33,pagedown:34,end:35,home:36,arrowleft:37,arrowup:38,arrowright:39,arrowdown:40,insert:45,delete:46,meta:91,numlock:144,scrolllock:145,";":186,"=":187,",":188,"-":189,".":190,"/":191,"`":192,"[":219,"\\":220,"]":221,"'":222},o=1;o<20;o++)n["f"+o]=111+o;function i(e,t,r){t&&!("byKey"in t)&&(r=t,t=null),Array.isArray(e)||(e=[e]);var n=e.map(function(e){return a(e,t)}),o=function(e){return n.some(function(t){return s(t,e)})};return null==r?o:o(r)}function a(e,o){var i=o&&o.byKey,a={},s=(e=e.replace("++","+add")).split("+"),c=s.length;for(var d in t)a[t[d]]=!1;var h=!0,f=!1,p=void 0;try{for(var g,m=s[Symbol.iterator]();!(h=(g=m.next()).done);h=!0){var v=g.value,y=v.endsWith("?")&&v.length>1;y&&(v=v.slice(0,-1));var b=l(v),D=t[b];if(v.length>1&&!D&&!r[v]&&!n[b])throw new TypeError('Unknown modifier: "'+v+'"');1!==c&&D||(i?a.key=b:a.which=u(v)),D&&(a[D]=!y||null)}}catch(e){f=!0,p=e}finally{try{!h&&m.return&&m.return()}finally{if(f)throw p}}return a}function s(e,t){for(var r in e){var n=e[r],o=void 0;if(null!=n&&((null!=(o="key"===r&&null!=t.key?t.key.toLowerCase():"which"===r?91===n&&93===t.which?91:t.which:t[r])||!1!==n)&&o!==n))return!1}return!0}function u(e){return e=l(e),n[e]||e.toUpperCase().charCodeAt(0)}function l(e){return e=e.toLowerCase(),e=r[e]||e}return HC.default=i,HC.isHotkey=i,HC.isCodeHotkey=function(e,t){return i(e,t)},HC.isKeyHotkey=function(e,t){return i(e,{byKey:!0},t)},HC.parseHotkey=a,HC.compareHotkey=s,HC.toKeyCode=u,HC.toKeyName=l,HC}(),$C={bold:"mod+b",compose:["down","left","right","up","backspace","enter"],moveBackward:"left",moveForward:"right",moveWordBackward:"ctrl+left",moveWordForward:"ctrl+right",deleteBackward:"shift?+backspace",deleteForward:"shift?+delete",extendBackward:"shift+left",extendForward:"shift+right",italic:"mod+i",splitBlock:"shift?+enter",undo:"mod+z",tab:"tab",selectAll:"mod+a"},UC={moveLineBackward:"opt+up",moveLineForward:"opt+down",moveWordBackward:"opt+left",moveWordForward:"opt+right",deleteBackward:["ctrl+backspace","ctrl+h"],deleteForward:["ctrl+delete","ctrl+d"],deleteLineBackward:"cmd+shift?+backspace",deleteLineForward:["cmd+shift?+delete","ctrl+k"],deleteWordBackward:"opt+shift?+backspace",deleteWordForward:"opt+shift?+delete",extendLineBackward:"opt+shift+up",extendLineForward:"opt+shift+down",redo:"cmd+shift+z",transposeCharacter:"ctrl+t"},qC={deleteWordBackward:"ctrl+shift?+backspace",deleteWordForward:"ctrl+shift?+delete",redo:["ctrl+y","ctrl+shift+z"]},WC=function(e){var t=$C[e],r=UC[e],n=qC[e],o=t&&VC.isKeyHotkey(t),i=r&&VC.isKeyHotkey(r),a=n&&VC.isKeyHotkey(n);return function(e){return!(!o||!o(e))||(!!(ky&&i&&i(e))||!(ky||!a||!a(e)))}},GC={isBold:WC("bold"),isCompose:WC("compose"),isMoveBackward:WC("moveBackward"),isMoveForward:WC("moveForward"),isDeleteBackward:WC("deleteBackward"),isDeleteForward:WC("deleteForward"),isDeleteLineBackward:WC("deleteLineBackward"),isDeleteLineForward:WC("deleteLineForward"),isDeleteWordBackward:WC("deleteWordBackward"),isDeleteWordForward:WC("deleteWordForward"),isExtendBackward:WC("extendBackward"),isExtendForward:WC("extendForward"),isExtendLineBackward:WC("extendLineBackward"),isExtendLineForward:WC("extendLineForward"),isItalic:WC("italic"),isMoveLineBackward:WC("moveLineBackward"),isMoveLineForward:WC("moveLineForward"),isMoveWordBackward:WC("moveWordBackward"),isMoveWordForward:WC("moveWordForward"),isRedo:WC("redo"),isSplitBlock:WC("splitBlock"),isTransposeCharacter:WC("transposeCharacter"),isUndo:WC("undo"),isTab:WC("tab"),isSelectAll:WC("selectAll")};function YC(e){e.preventDefault()}var KC={beforeinput:function(e,t,r){var n=e,o=r.getConfig().readOnly;if(Iy&&!o&&SC(r,n.target)){var i=r.selection,a=n.inputType,s=n.dataTransfer||n.data||void 0;if("insertCompositionText"!==a&&"deleteCompositionText"!==a){if(n.preventDefault(),!a.startsWith("delete")||a.startsWith("deleteBy")){var u=Qg(n.getTargetRanges(),1)[0];if(u){var l=Ry.toSlateRange(r,u,{exactMatch:!1,suppressThrow:!1});i&&hg.equals(i,l)||zg.select(r,l)}}if(i&&hg.isExpanded(i)){var c=Ry.getSelectedElems(r),d="table"===c[0].type,h="table-cell"!==c[c.length-1].type;if(d&&h)return;if(a.startsWith("delete")){var f=a.endsWith("Backward")?"backward":"forward";return void Yp.deleteFragment(r,{direction:f})}}switch(a){case"deleteByComposition":case"deleteByCut":case"deleteByDrag":Yp.deleteFragment(r);break;case"deleteContent":case"deleteContentForward":Yp.deleteForward(r);break;case"deleteContentBackward":Yp.deleteBackward(r);break;case"deleteEntireSoftLine":Yp.deleteBackward(r,{unit:"line"}),Yp.deleteForward(r,{unit:"line"});break;case"deleteHardLineBackward":Yp.deleteBackward(r,{unit:"block"});break;case"deleteSoftLineBackward":Yp.deleteBackward(r,{unit:"line"});break;case"deleteHardLineForward":Yp.deleteForward(r,{unit:"block"});break;case"deleteSoftLineForward":Yp.deleteForward(r,{unit:"line"});break;case"deleteWordBackward":Yp.deleteBackward(r,{unit:"word"});break;case"deleteWordForward":Yp.deleteForward(r,{unit:"word"});break;case"insertLineBreak":case"insertParagraph":Yp.insertBreak(r);break;case"insertFromDrop":case"insertFromPaste":case"insertFromYank":case"insertReplacementText":case"insertText":if("insertFromPaste"===a&&!qm.get(r))break;"[object DataTransfer]"===Vv(s)?r.insertData(s):"string"==typeof s&&Yp.insertText(r,s)}}}},blur:function(e,t,r){var n=e,o=t.isUpdatingSelection,i=t.latestElement;if(!r.getConfig().readOnly&&!o&&SC(r,n.target)){var a=Ry.findDocumentOrShadowRoot(r);if(i!==a.activeElement){var s=n.relatedTarget;if(!(s===Ry.toDOMNode(r,r)||Gv(s)&&s.hasAttribute("data-slate-spacer"))){if(null!=s&&qv(s)&&Ry.hasDOMNode(r,s)){var u=Ry.toSlateNode(r,s);if(Vp.isElement(u)&&!r.isVoid(u))return}if(Ty){var l=a.getSelection();null==l||l.removeAllRanges()}Vm.delete(r)}}}},focus:function(e,t,r){var n=Ry.toDOMNode(r,r),o=Ry.findDocumentOrShadowRoot(r);t.latestElement=o.activeElement,Oy&&e.target!==n?n.focus():Vm.set(r,!0)},click:function(e,t,r){if(!r.getConfig().readOnly&&kC(r,e.target)&&qv(e.target)){var n=Ry.toSlateNode(r,e.target),o=Ry.findPath(r,n);if(Yp.hasPath(r,o))if(eg.get(r,o)===n){var i=Yp.start(r,o),a=Yp.end(r,o),s=Yp.void(r,{at:i}),u=Yp.void(r,{at:a});if(s&&u&&og.equals(s[1],u[1])){var l=Yp.range(r,i);zg.select(r,l)}}}},compositionstart:function(e,t,r){if(SC(r,e.target)){var n=r.selection;if(n&&hg.isExpanded(n)&&(Yp.deleteFragment(r),Promise.resolve().then(function(){LC(t,r,!0)})),r.selection){var o=Ry.toDOMRange(r,r.selection).startContainer,i=o.textContent||"";_C.set(r,i),zC.set(r,o)}t.isComposing=!0,function(e,t){var r;t.getConfig().placeholder&&t.isEmpty()&&e.showPlaceholder&&(null===(r=e.$placeholder)||void 0===r||r.hide(),e.showPlaceholder=!1)}(t,r)}},compositionend:function(e,t,r){var n=e;if(SC(r,n.target)){t.isComposing=!1;var o=r.selection;if(null!=o){(My||Oy)&&Ry.cleanExposedTexNodeInSelectionBlock(r);for(var i=hg.isBackward(o)?o.focus:o.anchor,a=Qg(Yp.node(r,[i.path[0]]),1)[0],s=0;s<i.path.length;s+=1){var u=Qg(Yp.node(r,i.path.slice(0,s+1)),1)[0];if(Vp.isElement(u)&&((Ty||Oy)&&"link"===u.type||"code"===u.type)){Ry.setNewKey(a);break}}var l=n.data;if(l){if(r.getConfig().maxLength){var c=Ry.getLeftLengthOfMaxLength(r);if(c<l.length){var d=Ry.toDOMRange(r,o);d.startContainer.nodeType===Node.TEXT_NODE&&(d.startContainer.textContent=_C.get(r)||""),c>0&&Yp.insertText(r,l.slice(0,c)),t.changeViewState()}else Yp.insertText(r,l)}else{var h=Ry.findDocumentOrShadowRoot(r).getSelection();h&&function(e,t){if(hg.isCollapsed(t)){var r=t.anchor,n=t.focus;if([2,3].includes(r.path.length)&&[2,3].includes(n.path.length)&&(0===r.offset||0===n.offset)){var o=Yp.node(e,r.path),i=0===r.offset?r.path:n.path,a=[i[0],i[1]-1];if(0===i[1])return!1;var s=Yp.node(e,a);if(Cg.isText(s[0])&&Cg.isText(o[0]))return!0}}}(r,o)&&(r.selection=Ry.toSlateRange(r,h,{exactMatch:!1,suppressThrow:!1})),Yp.insertText(r,l)}Ty||setTimeout(function(){var e=r.selection;if(null!=e){var t=zC.get(r);if(null!=t)Ry.toDOMRange(r,e).startContainer!==t&&(t.textContent=_C.get(r)||"")}})}}}},compositionupdate:function(e,t,r){SC(r,e.target)&&(t.isComposing=!0)},keydown:function(e,t,r){var n=e,o=r.selection;if(!r.getConfig().readOnly&&!t.isComposing&&SC(r,n.target)){if(function(e,t){var r=wm.get(e),n=r&&r.getMenus(),o=Am.get(e),i=o&&o.getMenus(),a=Kg(Kg({},n),i);for(var s in a){var u=a[s],l=u.hotkey;if(l&&VC.isHotkey(l,t)&&!u.isDisabled(e)){var c=u.getValue(e);u.exec(e,c)}}}(r,n),GC.isTab(n))return YC(n),void r.handleTab();if(GC.isRedo(n))return YC(n),void("function"==typeof r.redo&&r.redo());if(GC.isUndo(n))return YC(n),void("function"==typeof r.undo&&r.undo());if(GC.isMoveLineBackward(n))return YC(n),void zg.move(r,{unit:"line",reverse:!0});if(GC.isMoveLineForward(n))return YC(n),void zg.move(r,{unit:"line"});if(GC.isExtendLineBackward(n))return YC(n),void zg.move(r,{unit:"line",edge:"focus",reverse:!0});if(GC.isExtendLineForward(n))return YC(n),void zg.move(r,{unit:"line",edge:"focus"});if(GC.isMoveBackward(n))return YC(n),void(o&&hg.isCollapsed(o)?zg.move(r,{reverse:!0}):zg.collapse(r,{edge:"start"}));if(GC.isMoveForward(n))return YC(n),void(o&&hg.isCollapsed(o)?zg.move(r):zg.collapse(r,{edge:"end"}));if(GC.isMoveWordBackward(n))return YC(n),o&&hg.isExpanded(o)&&zg.collapse(r,{edge:"focus"}),void zg.move(r,{unit:"word",reverse:!0});if(GC.isMoveWordForward(n))return YC(n),o&&hg.isExpanded(o)&&zg.collapse(r,{edge:"focus"}),void zg.move(r,{unit:"word"});if(GC.isSelectAll(n))return YC(n),void r.selectAll();if(Iy){if((My||Ty)&&o&&(GC.isDeleteBackward(n)||GC.isDeleteForward(n))&&hg.isCollapsed(o)){var i=eg.parent(r,o.anchor.path);if(Vp.isElement(i)&&Yp.isVoid(r,i)&&Yp.isInline(r,i))return n.preventDefault(),void zg.delete(r,{unit:"block"})}}else{if(GC.isBold(n)||GC.isItalic(n)||GC.isTransposeCharacter(n))return void YC(n);if(GC.isSplitBlock(n))return YC(n),void Yp.insertBreak(r);if(GC.isDeleteBackward(n))return YC(n),void(o&&hg.isExpanded(o)?Yp.deleteFragment(r,{direction:"backward"}):Yp.deleteBackward(r));if(GC.isDeleteForward(n))return YC(n),void(o&&hg.isExpanded(o)?Yp.deleteFragment(r,{direction:"forward"}):Yp.deleteForward(r));if(GC.isDeleteLineBackward(n))return YC(n),void(o&&hg.isExpanded(o)?Yp.deleteFragment(r,{direction:"backward"}):Yp.deleteBackward(r,{unit:"line"}));if(GC.isDeleteLineForward(n))return YC(n),void(o&&hg.isExpanded(o)?Yp.deleteFragment(r,{direction:"forward"}):Yp.deleteForward(r,{unit:"line"}));if(GC.isDeleteWordBackward(n))return YC(n),void(o&&hg.isExpanded(o)?Yp.deleteFragment(r,{direction:"backward"}):Yp.deleteBackward(r,{unit:"word"}));if(GC.isDeleteWordForward(n))return YC(n),void(o&&hg.isExpanded(o)?Yp.deleteFragment(r,{direction:"forward"}):Yp.deleteForward(r,{unit:"word"}))}}},keypress:function(e,t,r){if(!Iy&&!r.getConfig().readOnly&&SC(r,e.target)){e.preventDefault();var n=e.key;Yp.insertText(r,n)}},copy:function(e,t,r){var n=e;if(SC(r,n.target)){r.getConfig().readOnly||n.preventDefault();var o=n.clipboardData;if(null!=o){r.setFragmentData(o);var i=r.getConfig().customCopy;i&&i(r,n)}}},cut:function(e,t,r){var n=e,o=r.selection;if(!r.getConfig().readOnly&&(n.preventDefault(),SC(r,n.target))){var i=n.clipboardData;if(null!=i&&(r.setFragmentData(i),o))if(hg.isExpanded(o))Yp.deleteFragment(r);else{var a=eg.parent(r,o.anchor.path);Yp.isVoid(r,a)&&zg.delete(r)}}},paste:function(e,t,r){qm.set(r,!0);var n=e;if(!r.getConfig().readOnly&&SC(r,n.target)){var o=r.getConfig().customPaste;if(o)if(!1===o(r,n))return void qm.set(r,!1);if(Ty||!Iy||function(e){return e.clipboardData&&""!==e.clipboardData.getData("text/plain")&&1===e.clipboardData.types.length}(n)){n.preventDefault();var i=n.clipboardData;null!=i&&r.insertData(i)}}},dragover:function(e,t,r){if(kC(r,e.target)){var n=Ry.toSlateNode(r,e.target);Yp.isVoid(r,n)&&e.preventDefault()}},dragstart:function(e,t,r){var n=e;if(kC(r,n.target)&&!r.getConfig().readOnly){var o=Ry.toSlateNode(r,n.target),i=Ry.findPath(r,o);if(Yp.isVoid(r,o)||Yp.void(r,{at:i,voids:!0})){var a=Yp.range(r,i);zg.select(r,a)}var s=n.dataTransfer;if(null!=s)Ry.getSelectedNodeByType(r,"table")||(t.isDraggingInternally=!0,r.setFragmentData(s))}},dragend:function(e,t,r){var n=e;r.getConfig().readOnly||t.isDraggingInternally&&kC(r,n.target)&&(t.isDraggingInternally=!1)},drop:function(e,t,r){var n=e,o=n.dataTransfer;if(!r.getConfig().readOnly&&kC(r,n.target)&&null!=o&&!(Iy&&Ty&&o.files.length>0)){n.preventDefault();var i=r.selection,a=Ry.findEventRange(r,n);zg.select(r,a),t.isDraggingInternally&&(i&&zg.delete(r,{at:i}),t.isDraggingInternally=!1),r.insertData(o),r.isFocused()||r.focus()}}};function XC(e){if(ZC(e)){for(;e&&ZC(e);){e=JC(e).parent}return null!=e?e:null}return e.parentNode}function ZC(e){return 11===e.nodeType}function JC(e,t){var r,n,o;const i=e;return null!==(r=i.parent)&&void 0!==r||(i.parent=null!=t?t:null),null!==(n=i.firstChildNode)&&void 0!==n||(i.firstChildNode=e.firstChild),null!==(o=i.lastChildNode)&&void 0!==o||(i.lastChildNode=e.lastChild),i}const QC={createElement:function(e,t){return document.createElement(e,t)},createElementNS:function(e,t,r){return document.createElementNS(e,t,r)},createTextNode:function(e){return document.createTextNode(e)},createDocumentFragment:function(){return JC(document.createDocumentFragment())},createComment:function(e){return document.createComment(e)},insertBefore:function(e,t,r){if(ZC(e)){let t=e;for(;t&&ZC(t);){t=JC(t).parent}e=null!=t?t:e}ZC(t)&&(t=JC(t,e)),r&&ZC(r)&&(r=JC(r).firstChildNode),e.insertBefore(t,r)},removeChild:function(e,t){e.removeChild(t)},appendChild:function(e,t){ZC(t)&&(t=JC(t,e)),e.appendChild(t)},parentNode:XC,nextSibling:function(e){var t;if(ZC(e)){const r=JC(e),n=XC(r);if(n&&r.lastChildNode){const e=Array.from(n.childNodes),o=e.indexOf(r.lastChildNode);return null!==(t=e[o+1])&&void 0!==t?t:null}return null}return e.nextSibling},tagName:function(e){return e.tagName},setTextContent:function(e,t){e.textContent=t},getTextContent:function(e){return e.textContent},isElement:function(e){return 1===e.nodeType},isText:function(e){return 3===e.nodeType},isComment:function(e){return 8===e.nodeType},isDocumentFragment:ZC};function ew(e,t,r,n,o){return{sel:e,data:t,children:r,text:n,elm:o,key:void 0===t?void 0:t.key}}const tw=Array.isArray;function rw(e){return"string"==typeof e||"number"==typeof e||e instanceof String||e instanceof Number}function nw(e){return void 0===e}function ow(e){return void 0!==e}const iw=ew("",{},[],void 0,void 0);function aw(e,t){var r,n;const o=e.key===t.key,i=(null===(r=e.data)||void 0===r?void 0:r.is)===(null===(n=t.data)||void 0===n?void 0:n.is),a=e.sel===t.sel,s=!(!e.sel&&e.sel===t.sel)||typeof e.text==typeof t.text;return a&&o&&i&&s}function sw(e,t,r){var n;const o={};for(let i=t;i<=r;++i){const t=null===(n=e[i])||void 0===n?void 0:n.key;void 0!==t&&(o[t]=i)}return o}const uw=["create","update","remove","destroy","pre","post"];function lw(e,t,r){const n={create:[],update:[],remove:[],destroy:[],pre:[],post:[]},o=QC;for(const t of uw)for(const r of e){const e=r[t];void 0!==e&&n[t].push(e)}function i(e){const t=e.id?"#"+e.id:"",r=e.getAttribute("class"),n=r?"."+r.split(" ").join("."):"";return ew(o.tagName(e).toLowerCase()+t+n,{},[],void 0,e)}function a(e){return ew(void 0,{},[],void 0,e)}function s(e,t){return function(){if(0===--t){const t=o.parentNode(e);null!==t&&o.removeChild(t,e)}}}function u(e,t){var r,i;let a,s=e.data;if(void 0!==s){const t=null===(r=s.hook)||void 0===r?void 0:r.init;ow(t)&&(t(e),s=e.data)}const l=e.children,c=e.sel;if("!"===c)nw(e.text)&&(e.text=""),e.elm=o.createComment(e.text);else if(""===c)e.elm=o.createTextNode(e.text);else if(void 0!==c){const r=c.indexOf("#"),d=c.indexOf(".",r),h=r>0?r:c.length,f=d>0?d:c.length,p=-1!==r||-1!==d?c.slice(0,Math.min(h,f)):c,g=e.elm=ow(s)&&ow(a=s.ns)?o.createElementNS(a,p,s):o.createElement(p,s);for(h<f&&g.setAttribute("id",c.slice(h+1,f)),d>0&&g.setAttribute("class",c.slice(f+1).replace(/\./g," ")),a=0;a<n.create.length;++a)n.create[a](iw,e);if(!rw(e.text)||tw(l)&&0!==l.length||o.appendChild(g,o.createTextNode(e.text)),tw(l))for(a=0;a<l.length;++a){const e=l[a];null!=e&&o.appendChild(g,u(e,t))}const m=e.data.hook;ow(m)&&(null===(i=m.create)||void 0===i||i.call(m,iw,e),m.insert&&t.push(e))}else e.elm=o.createTextNode(e.text);return e.elm}function l(e,t,r,n,i,a){for(;n<=i;++n){const i=r[n];null!=i&&o.insertBefore(e,u(i,a),t)}}function c(e){var t,r;const o=e.data;if(void 0!==o){null===(r=null===(t=null==o?void 0:o.hook)||void 0===t?void 0:t.destroy)||void 0===r||r.call(t,e);for(let t=0;t<n.destroy.length;++t)n.destroy[t](e);if(void 0!==e.children)for(let t=0;t<e.children.length;++t){const r=e.children[t];null!=r&&"string"!=typeof r&&c(r)}}}function d(e,t,r,i){for(var a,u;r<=i;++r){let i,l;const h=t[r];if(null!=h)if(ow(h.sel)){c(h),i=n.remove.length+1,l=s(h.elm,i);for(let e=0;e<n.remove.length;++e)n.remove[e](h,l);const e=null===(u=null===(a=null==h?void 0:h.data)||void 0===a?void 0:a.hook)||void 0===u?void 0:u.remove;ow(e)?e(h,l):l()}else h.children?(c(h),d(e,h.children,0,h.children.length-1)):o.removeChild(e,h.elm)}}function h(e,t,r){var i,a,s,c,f,p,g,m;const v=null===(i=t.data)||void 0===i?void 0:i.hook;null===(a=null==v?void 0:v.prepatch)||void 0===a||a.call(v,e,t);const y=t.elm=e.elm;if(e===t)return;if(void 0!==t.data||ow(t.text)&&t.text!==e.text){null!==(s=t.data)&&void 0!==s||(t.data={}),null!==(c=e.data)&&void 0!==c||(e.data={});for(let r=0;r<n.update.length;++r)n.update[r](e,t);null===(g=null===(p=null===(f=t.data)||void 0===f?void 0:f.hook)||void 0===p?void 0:p.update)||void 0===g||g.call(p,e,t)}const b=e.children,D=t.children;nw(t.text)?ow(b)&&ow(D)?b!==D&&function(e,t,r,n){let i,a,s,c,f=0,p=0,g=t.length-1,m=t[0],v=t[g],y=r.length-1,b=r[0],D=r[y];for(;f<=g&&p<=y;)null==m?m=t[++f]:null==v?v=t[--g]:null==b?b=r[++p]:null==D?D=r[--y]:aw(m,b)?(h(m,b,n),m=t[++f],b=r[++p]):aw(v,D)?(h(v,D,n),v=t[--g],D=r[--y]):aw(m,D)?(h(m,D,n),o.insertBefore(e,m.elm,o.nextSibling(v.elm)),m=t[++f],D=r[--y]):aw(v,b)?(h(v,b,n),o.insertBefore(e,v.elm,m.elm),v=t[--g],b=r[++p]):(void 0===i&&(i=sw(t,f,g)),a=i[b.key],nw(a)?(o.insertBefore(e,u(b,n),m.elm),b=r[++p]):nw(i[D.key])?(o.insertBefore(e,u(D,n),o.nextSibling(v.elm)),D=r[--y]):(s=t[a],s.sel!==b.sel?o.insertBefore(e,u(b,n),m.elm):(h(s,b,n),t[a]=void 0,o.insertBefore(e,s.elm,m.elm)),b=r[++p]));p<=y&&(c=null==r[y+1]?null:r[y+1].elm,l(e,c,r,p,y,n)),f<=g&&d(e,t,f,g)}(y,b,D,r):ow(D)?(ow(e.text)&&o.setTextContent(y,""),l(y,null,D,0,D.length-1,r)):ow(b)?d(y,b,0,b.length-1):ow(e.text)&&o.setTextContent(y,""):e.text!==t.text&&(ow(b)&&d(y,b,0,b.length-1),o.setTextContent(y,t.text)),null===(m=null==v?void 0:v.postpatch)||void 0===m||m.call(v,e,t)}return function(e,t){let r,s,l;const c=[];for(r=0;r<n.pre.length;++r)n.pre[r]();for(!function(e,t){return e.isElement(t)}(o,e)?function(e,t){return e.isDocumentFragment(t)}(o,e)&&(e=a(e)):e=i(e),aw(e,t)?h(e,t,c):(s=e.elm,l=o.parentNode(s),u(t,c),null!==l&&(o.insertBefore(l,t.elm,o.nextSibling(s)),d(l,[e],0,0))),r=0;r<c.length;++r)c[r].data.hook.insert(c[r]);for(r=0;r<n.post.length;++r)n.post[r]();return t}}function cw(e,t,r){if(e.ns="http://www.w3.org/2000/svg","foreignObject"!==r&&void 0!==t)for(let e=0;e<t.length;++e){const r=t[e];if("string"==typeof r)continue;const n=r.data;void 0!==n&&cw(n,r.children,r.sel)}}function dw(e,t,r){let n,o,i,a={};if(void 0!==r?(null!==t&&(a=t),tw(r)?n=r:rw(r)?o=r.toString():r&&r.sel&&(n=[r])):null!=t&&(tw(t)?n=t:rw(t)?o=t.toString():t&&t.sel?n=[t]:a=t),void 0!==n)for(i=0;i<n.length;++i)rw(n[i])&&(n[i]=ew(void 0,void 0,void 0,n[i],void 0));return!e.startsWith("svg")||3!==e.length&&"."!==e[3]&&"#"!==e[3]||cw(a,n,e),ew(e,a,n,o,void 0)}function hw(e,t){let r;const n=t.elm;let o=e.data.attrs,i=t.data.attrs;if((o||i)&&o!==i){for(r in o=o||{},i=i||{},i){const e=i[r];o[r]!==e&&(!0===e?n.setAttribute(r,""):!1===e?n.removeAttribute(r):120!==r.charCodeAt(0)?n.setAttribute(r,e):58===r.charCodeAt(3)?n.setAttributeNS("http://www.w3.org/XML/1998/namespace",r,e):58===r.charCodeAt(5)?109===r.charCodeAt(1)?n.setAttributeNS("http://www.w3.org/2000/xmlns/",r,e):n.setAttributeNS("http://www.w3.org/1999/xlink",r,e):n.setAttribute(r,e))}for(r in o)r in i||n.removeAttribute(r)}}const fw={create:hw,update:hw};function pw(e,t){let r,n;const o=t.elm;let i=e.data.class,a=t.data.class;if((i||a)&&i!==a){for(n in i=i||{},a=a||{},i)i[n]&&!Object.prototype.hasOwnProperty.call(a,n)&&o.classList.remove(n);for(n in a)r=a[n],r!==i[n]&&o.classList[r?"add":"remove"](n)}}const gw={create:pw,update:pw},mw=/[A-Z]/g;function vw(e,t){const r=t.elm;let n,o=e.data.dataset,i=t.data.dataset;if(!o&&!i)return;if(o===i)return;o=o||{},i=i||{};const a=r.dataset;for(n in o)n in i||(a?n in a&&delete a[n]:r.removeAttribute("data-"+n.replace(mw,"-$&").toLowerCase()));for(n in i)o[n]!==i[n]&&(a?a[n]=i[n]:r.setAttribute("data-"+n.replace(mw,"-$&").toLowerCase(),i[n]))}const yw={create:vw,update:vw};function bw(e,t,r){if("function"==typeof e)e.call(t,r,t);else if("object"==typeof e)for(let n=0;n<e.length;n++)bw(e[n],t,r)}function Dw(e,t){const r=e.type,n=t.data.on;n&&n[r]&&bw(n[r],t,e)}function Cw(e,t){const r=e.data.on,n=e.listener,o=e.elm,i=t&&t.data.on,a=t&&t.elm;let s;if(r!==i){if(r&&n)if(i)for(s in r)i[s]||o.removeEventListener(s,n,!1);else for(s in r)o.removeEventListener(s,n,!1);if(i){const n=t.listener=e.listener||function e(t){Dw(t,e.vnode)};if(n.vnode=t,r)for(s in i)r[s]||a.addEventListener(s,n,!1);else for(s in i)a.addEventListener(s,n,!1)}}}const ww={create:Cw,update:Cw,destroy:Cw};function Ew(e,t){let r,n,o;const i=t.elm;let a=e.data.props,s=t.data.props;if((a||s)&&a!==s)for(r in a=a||{},s=s||{},s)n=s[r],o=a[r],o===n||"value"===r&&i[r]===n||(i[r]=n)}const Aw={create:Ew,update:Ew},xw="function"==typeof(null===window||void 0===window?void 0:window.requestAnimationFrame)?window.requestAnimationFrame.bind(window):setTimeout;let Bw=!1;function Sw(e,t,r){!function(e){xw(function(){xw(e)})}(function(){e[t]=r})}function Fw(e,t){let r,n;const o=t.elm;let i=e.data.style,a=t.data.style;if(!i&&!a)return;if(i===a)return;i=i||{},a=a||{};const s="delayed"in i;for(n in i)n in a||("-"===n[0]&&"-"===n[1]?o.style.removeProperty(n):o.style[n]="");for(n in a)if(r=a[n],"delayed"===n&&a.delayed)for(const e in a.delayed)r=a.delayed[e],s&&r===i.delayed[e]||Sw(o.style,e,r);else"remove"!==n&&r!==i[n]&&("-"===n[0]&&"-"===n[1]?o.style.setProperty(n,r):o.style[n]=r)}const kw={pre:function(){Bw=!1},create:Fw,update:Fw,destroy:function(e){let t,r;const n=e.elm,o=e.data.style;if(o&&(t=o.destroy))for(r in t)n.style[r]=t[r]},remove:function(e,t){const r=e.data.style;if(!r||!r.remove)return void t();let n;Bw||(e.elm.offsetLeft,Bw=!0);const o=e.elm;let i=0;const a=r.remove;let s=0;const u=[];for(n in a)u.push(n),o.style[n]=a[n];const l=getComputedStyle(o)["transition-property"].split(", ");for(;i<l.length;++i)-1!==u.indexOf(l[i])&&s++;o.addEventListener("transitionend",function(e){e.target===o&&--s,0===s&&t()})}};function Ow(e,t){for(const r of e)null!=r&&!1!==r&&""!==r&&(Array.isArray(r)?Ow(r,t):"string"==typeof r||"number"==typeof r||"boolean"==typeof r?t.push(ew(void 0,void 0,void 0,String(r),void 0)):t.push(r));return t}function Tw(e,t,...r){const n=Ow(r,[]);return"function"==typeof e?e(t,n):1===n.length&&!n[0].sel&&n[0].text?dw(e,t,n[0].text):dw(e,t,n)}var Nw=[];var Pw,Mw,Iw={};function Rw(e,t,r){return Tw(r.isInline(e)?"span":"div",null,t)}function Lw(e,t){var r,n=Ry.findKey(t,e),o=t.isInline(e),i=Yp.isVoid(t,e),a=yy(e.type,n.id),s={id:a,key:n.id,"data-slate-node":"element","data-slate-inline":o},u=e.type,l=e.children,c=void 0===l?[]:l,d=function(e){return Iw[e]||Rw}(u);r=i?null:c.map(function(r,n){return Hw(r,n,e,t)});var h=d(e,r,t);if(i){s["data-slate-void"]=!0;var f=o?"span":"div",p=Qg(eg.texts(e),1),g=Qg(p[0],1)[0],m=Tw(f,{"data-slate-spacer":!0,style:{height:"0",color:"transparent",outline:"none",position:"absolute"}},Hw(g,0,e,t));h=Tw(f,{style:{position:"relative"}},h,m),Mm.set(g,0),Im.set(g,e)}return null==h.data&&(h.data={}),Object.assign(h.data,s),i||o||(h=function(e,t){var r=t;return Nw.forEach(function(n){r=n(e,t)}),r}(e,h)),jv(function(){var t=Xv(a);null!=t&&(_m.set(n,t),zm.set(e,t),Lm.set(t,e))}),h}function _w(e,t){return void 0===t&&(t=!1),Tw("span",{"data-slate-string":!0},t?e+"\n":e)}function zw(e,t){return void 0===e&&(e=0),void 0===t&&(t=!1),Tw("span",{"data-slate-zero-width":t?"n":"z","data-slate-length":e},"\ufeff",t?Tw("br",null):null)}function jw(e,t,r){if(null==e.text)throw new Error("Current node is not slate Text ".concat(JSON.stringify(e)));var n=Ry.findKey(r,e),o=r.getConfig().decorate;if(null==o)throw new Error("Can not get config.decorate");var i,a=Ry.findPath(r,e),s=o([e,a]),u=Cg.decorations(e,s),l=u.map(function(n,o){var i=function(e,t,r,n,o){void 0===t&&(t=!1);var i=e.text,a=Ry.findPath(o,r),s=og.parent(a);if(Yp.isEditor(n))throw new Error("Text node ".concat(JSON.stringify(r)," parent is Editor"));return o.isVoid(n)?zw(eg.string(n).length):""!==i||n.children[n.children.length-1]!==r||o.isInline(n)||""!==Yp.string(o,s)?""===i?zw():t&&"\n"===i.slice(-1)?_w(i,!0):_w(i):zw(0,!0)}(n,o===u.length-1,e,t,r);return i=function(e,t){var r=t;return Nw.forEach(function(t){r=t(e,r)}),r}(n,i),Tw("span",{"data-slate-leaf":!0},i)}),c=(i=n.id,"w-e-text-".concat(i)),d=Tw("span",{"data-slate-node":"text",id:c,key:n.id},l);return jv(function(){var t=Xv(c);null!=t&&(_m.set(n,t),zm.set(e,t),Lm.set(t,e))}),d}function Hw(e,t,r,n){return Mm.set(e,t),Im.set(e,r),Vp.isElement(e)?Lw(e,n):jw(e,r,n)}var Vw=function(){if(Mw)return Pw;Mw=1;var e,t="[object Symbol]",r=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g,n=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,o="\\ud800-\\udfff",i="\\u0300-\\u036f\\ufe20-\\ufe23",a="\\u20d0-\\u20f0",s="\\u2700-\\u27bf",u="a-z\\xdf-\\xf6\\xf8-\\xff",l="A-Z\\xc0-\\xd6\\xd8-\\xde",c="\\ufe0e\\ufe0f",d="\\xac\\xb1\\xd7\\xf7\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf\\u2000-\\u206f \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",h="['’]",f="["+o+"]",p="["+d+"]",g="["+i+a+"]",m="\\d+",v="["+s+"]",b="["+u+"]",D="[^"+o+d+m+s+u+l+"]",C="\\ud83c[\\udffb-\\udfff]",w="[^"+o+"]",E="(?:\\ud83c[\\udde6-\\uddff]){2}",A="[\\ud800-\\udbff][\\udc00-\\udfff]",x="["+l+"]",B="\\u200d",S="(?:"+b+"|"+D+")",F="(?:"+x+"|"+D+")",k="(?:['’](?:d|ll|m|re|s|t|ve))?",O="(?:['’](?:D|LL|M|RE|S|T|VE))?",T="(?:"+g+"|"+C+")"+"?",N="["+c+"]?",P=N+T+("(?:"+B+"(?:"+[w,E,A].join("|")+")"+N+T+")*"),M="(?:"+[v,E,A].join("|")+")"+P,I="(?:"+[w+g+"?",g,E,A,f].join("|")+")",R=RegExp(h,"g"),L=RegExp(g,"g"),_=RegExp(C+"(?="+C+")|"+I+P,"g"),z=RegExp([x+"?"+b+"+"+k+"(?="+[p,x,"$"].join("|")+")",F+"+"+O+"(?="+[p,x+S,"$"].join("|")+")",x+"?"+S+"+"+k,x+"+"+O,m,M].join("|"),"g"),j=RegExp("["+B+o+i+a+c+"]"),H=/[a-z][A-Z]|[A-Z]{2,}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/,V="object"==typeof y&&y&&y.Object===Object&&y,$="object"==typeof self&&self&&self.Object===Object&&self,U=V||$||Function("return this")(),q=(e={"À":"A","Á":"A","Â":"A","Ã":"A","Ä":"A","Å":"A","à":"a","á":"a","â":"a","ã":"a","ä":"a","å":"a","Ç":"C","ç":"c","Ð":"D","ð":"d","È":"E","É":"E","Ê":"E","Ë":"E","è":"e","é":"e","ê":"e","ë":"e","Ì":"I","Í":"I","Î":"I","Ï":"I","ì":"i","í":"i","î":"i","ï":"i","Ñ":"N","ñ":"n","Ò":"O","Ó":"O","Ô":"O","Õ":"O","Ö":"O","Ø":"O","ò":"o","ó":"o","ô":"o","õ":"o","ö":"o","ø":"o","Ù":"U","Ú":"U","Û":"U","Ü":"U","ù":"u","ú":"u","û":"u","ü":"u","Ý":"Y","ý":"y","ÿ":"y","Æ":"Ae","æ":"ae","Þ":"Th","þ":"th","ß":"ss","Ā":"A","Ă":"A","Ą":"A","ā":"a","ă":"a","ą":"a","Ć":"C","Ĉ":"C","Ċ":"C","Č":"C","ć":"c","ĉ":"c","ċ":"c","č":"c","Ď":"D","Đ":"D","ď":"d","đ":"d","Ē":"E","Ĕ":"E","Ė":"E","Ę":"E","Ě":"E","ē":"e","ĕ":"e","ė":"e","ę":"e","ě":"e","Ĝ":"G","Ğ":"G","Ġ":"G","Ģ":"G","ĝ":"g","ğ":"g","ġ":"g","ģ":"g","Ĥ":"H","Ħ":"H","ĥ":"h","ħ":"h","Ĩ":"I","Ī":"I","Ĭ":"I","Į":"I","İ":"I","ĩ":"i","ī":"i","ĭ":"i","į":"i","ı":"i","Ĵ":"J","ĵ":"j","Ķ":"K","ķ":"k","ĸ":"k","Ĺ":"L","Ļ":"L","Ľ":"L","Ŀ":"L","Ł":"L","ĺ":"l","ļ":"l","ľ":"l","ŀ":"l","ł":"l","Ń":"N","Ņ":"N","Ň":"N","Ŋ":"N","ń":"n","ņ":"n","ň":"n","ŋ":"n","Ō":"O","Ŏ":"O","Ő":"O","ō":"o","ŏ":"o","ő":"o","Ŕ":"R","Ŗ":"R","Ř":"R","ŕ":"r","ŗ":"r","ř":"r","Ś":"S","Ŝ":"S","Ş":"S","Š":"S","ś":"s","ŝ":"s","ş":"s","š":"s","Ţ":"T","Ť":"T","Ŧ":"T","ţ":"t","ť":"t","ŧ":"t","Ũ":"U","Ū":"U","Ŭ":"U","Ů":"U","Ű":"U","Ų":"U","ũ":"u","ū":"u","ŭ":"u","ů":"u","ű":"u","ų":"u","Ŵ":"W","ŵ":"w","Ŷ":"Y","ŷ":"y","Ÿ":"Y","Ź":"Z","Ż":"Z","Ž":"Z","ź":"z","ż":"z","ž":"z","IJ":"IJ","ij":"ij","Œ":"Oe","œ":"oe","ʼn":"'n","ſ":"ss"},function(t){return null==e?void 0:e[t]});function W(e){return j.test(e)}function G(e){return W(e)?function(e){return e.match(_)||[]}(e):function(e){return e.split("")}(e)}var Y=Object.prototype.toString,K=U.Symbol,X=K?K.prototype:void 0,Z=X?X.toString:void 0;function J(e){if("string"==typeof e)return e;if(function(e){return"symbol"==typeof e||function(e){return!!e&&"object"==typeof e}(e)&&Y.call(e)==t}(e))return Z?Z.call(e):"";var r=e+"";return"0"==r&&1/e==-1/0?"-0":r}function Q(e,t,r){var n=e.length;return r=void 0===r?n:r,!t&&r>=n?e:function(e,t,r){var n=-1,o=e.length;t<0&&(t=-t>o?0:o+t),(r=r>o?o:r)<0&&(r+=o),o=t>r?0:r-t>>>0,t>>>=0;for(var i=Array(o);++n<o;)i[n]=e[n+t];return i}(e,t,r)}function ee(e){return null==e?"":J(e)}var te,re,ne=(te=function(e,t,r){return t=t.toLowerCase(),e+(r?oe(ee(t).toLowerCase()):t)},function(e){return function(e,t,r){for(var n=-1,o=e?e.length:0;++n<o;)r=t(r,e[n],n,e);return r}(function(e,t){return e=ee(e),void 0===t?function(e){return H.test(e)}(e)?function(e){return e.match(z)||[]}(e):function(e){return e.match(r)||[]}(e):e.match(t)||[]}(function(e){return(e=ee(e))&&e.replace(n,q).replace(L,"")}(e).replace(R,"")),te,"")}),oe=(re="toUpperCase",function(e){var t=W(e=ee(e))?G(e):void 0,r=t?t[0]:e.charAt(0),n=t?Q(t,1).join(""):e.slice(1);return r[re]()+n});return Pw=ne}(),$w=b(Vw);var Uw=["props","attrs","style","dataset","on","hook"];function qw(e){var t=e.data,r=void 0===t?{}:t,n=e.children,o=void 0===n?[]:n;Object.keys(r).forEach(function(t){var n,o,i=r[t];if("key"!==t){if(!Uw.includes(t)){if(t.startsWith("data-")){var a=t.slice(5);return a=$w(a),function(e,t){null==e.data&&(e.data={});var r=e.data;null==r.dataset&&(r.dataset={});Object.assign(r.dataset,t)}(e,((n={})[a]=i,n)),void delete r[t]}!function(e,t){null==e.data&&(e.data={});var r=e.data;null==r.props&&(r.props={});Object.assign(r.props,t)}(e,(o={},o[t]=i,o)),delete r[t]}}else e.key=i}),o.length>0&&o.forEach(function(e){"string"!=typeof e&&qw(e)})}function Ww(e,t){var r,n,o=e.$scroll,i=(r=e.id,"w-e-textarea-".concat(r)),a=t.getConfig(),s=a.readOnly,u=a.autoFocus,l=function(e,t){return void 0===t&&(t=!1),dw("div#".concat(e),{props:{contentEditable:!t}})}(i,s),c=t.children||[];l.children=c.map(function(e,r){if(Nm.has(e)){var n=Nm.get(e);if(n){var o=Qg(n,2),i=o[0],a=o[1];if(a)return i!==r&&(Mm.set(e,r),Nm.set(e,[r,a])),a}}var s=Hw(e,r,t,t);qw(s);var u=t.getConfig().skipCacheTypes,l=void 0===u?["list-item"]:u;return Vp.isElement(e)&&l.includes(e.type)||Nm.set(e,[r,s]),s});var d=km.get(e);if(null==d&&(d=!0),d){var h=function(e){return ov('<div\n id="'.concat(e,'"\n data-slate-editor\n data-slate-node="value"\n suppressContentEditableWarning\n role="textarea"\n spellCheck="true"\n autoCorrect="true"\n autoCapitalize="true"\n ></div>'))}(i);o.append(h),e.$textArea=h,n=h[0],(p=lw([gw,Aw,kw,yw,ww,fw]))(n,l),km.set(e,!1),Om.set(e,p)}else{var f=Tm.get(e),p=Om.get(e);if(null==f||null==p)return;n=f.elm,p(f,l)}if(null!=n||null!=(n=Xv(i))){var g;if((d?u:t.isFocused())&&n.focus({preventScroll:!0}),d){var m=(g=n)&&g.ownerDocument&&g.ownerDocument.defaultView||null;m&&Hm.set(t,m)}Rm.set(t,n),zm.set(t,n),Lm.set(n,t),Tm.set(e,l)}}var Gw=1,Yw=function(){function e(e){var t=this;this.id=Gw++,this.$textArea=null,this.$progressBar=ov('<div class="w-e-progress-bar"></div>'),this.$maxLengthInfo=ov('<div class="w-e-max-length-info"></div>'),this.isComposing=!1,this.isUpdatingSelection=!1,this.isDraggingInternally=!1,this.latestElement=null,this.showPlaceholder=!1,this.$placeholder=null,this.latestEditorSelection=null,this.onDOMSelectionChange=BC(function(){var e=t.editorInstance;!function(e,t){var r=e.isComposing,n=e.isUpdatingSelection,o=e.isDraggingInternally;if(!(t.getConfig().readOnly||r||n||o)){var i=Ry.findDocumentOrShadowRoot(t),a=i.activeElement,s=Ry.toDOMNode(t,t),u=i.getSelection();if(a!==s)return Vm.delete(t),void zg.deselect(t);if(e.latestElement=a,Vm.set(t,!0),!u)return zg.deselect(t);var l=u.anchorNode,c=u.focusNode,d=SC(t,l)||FC(t,l),h=SC(t,c)||FC(t,c);if(d&&h){var f=Ry.toSlateRange(t,u,{exactMatch:!1,suppressThrow:!1});zg.select(t,f)}}}(t,e)},100);var r=ov(e);if(0===r.length)throw new Error("Cannot find textarea DOM by selector '".concat(e,"'"));this.$box=r;var n=ov('<div class="w-e-text-container"></div>');n.append(this.$progressBar),n.append(this.$maxLengthInfo),r.append(n);var o=ov('<div class="w-e-scroll"></div>');n.append(o),this.$scroll=o,this.$textAreaContainer=n,jv(function(){var e=t.editorInstance,o=Ry.getWindow(e);o.document.addEventListener("selectionchange",t.onDOMSelectionChange),e.on(hm,function(){o.document.removeEventListener("selectionchange",t.onDOMSelectionChange)}),n.on("click",function(){return e.hidePanelOrModal()}),e.on(fm,t.changeViewState.bind(t));var i=e.getConfig(),a=i.onChange,s=i.scroll;a&&e.on(fm,function(){return a(e)}),s||(r.css("position","relative"),n.addClass("no-scroll")),t.onFocusAndOnBlur(),e.on(fm,t.changeMaxLengthInfo.bind(t)),t.bindEvent()})}return Object.defineProperty(e.prototype,"editorInstance",{get:function(){var e=Dm.get(this);if(null==e)throw new Error("Can not get editor instance");return e},enumerable:!1,configurable:!0}),e.prototype.bindEvent=function(){var e=this,t=this.$textArea,r=this.$scroll,n=this.editorInstance;null!=t&&(lm(KC,function(r,o){t.on(o,function(t){r(t,e,n)})}),n.getConfig().scroll&&(r.css("overflow-y","auto"),r.on("scroll",BC(function(){n.emit("scroll")},100))))},e.prototype.onFocusAndOnBlur=function(){var e=this,t=this.editorInstance,r=t.getConfig(),n=r.onBlur,o=r.onFocus;this.latestEditorSelection=t.selection,t.on(fm,function(){null==e.latestEditorSelection&&null!=t.selection?setTimeout(function(){return o&&o(t)}):null!=e.latestEditorSelection&&null==t.selection&&setTimeout(function(){return n&&n(t)}),e.latestEditorSelection=t.selection})},e.prototype.changeMaxLengthInfo=function(){var e=this.editorInstance,t=e.getConfig().maxLength;if(t){var r=t-Ry.getLeftLengthOfMaxLength(e);this.$maxLengthInfo[0].innerHTML="".concat(r,"/").concat(t)}},e.prototype.changeProgress=function(e){var t=this.$progressBar;t.css("width","".concat(e,"%")),e>=100&&setTimeout(function(){t.hide(),t.css("width","0"),t.show()},1e3)},e.prototype.changeViewState=function(){var e=this,t=this.editorInstance;Ww(this,t),function(e,t){var r,n=t.getConfig().placeholder;if(n){var o=t.isEmpty();if(o&&!e.showPlaceholder&&!e.isComposing){if(null==e.$placeholder){var i=ov('<div class="w-e-text-placeholder">'.concat(n,"</div>"));e.$textAreaContainer.append(i),e.$placeholder=i}return e.$placeholder.show(),void(e.showPlaceholder=!0)}!o&&e.showPlaceholder&&(null===(r=e.$placeholder)||void 0===r||r.hide(),e.showPlaceholder=!1)}}(this,t),jv(function(){LC(e,t)})},e.prototype.destroy=function(){this.$textAreaContainer.remove()},e}();function Kw(e,t,r,n){if(Mm.set(e,t),Im.set(e,r),Vp.isElement(e)){var o=e.children;if((void 0===o?[]:o).forEach(function(t,r){return Kw(t,r,e,n)}),Yp.isVoid(n,e)){var i=Qg(eg.texts(e),1),a=Qg(i[0],1)[0];Mm.set(a,0),Im.set(a,e)}}}var Xw={en:"Textarea height < 300px. This may cause modal and hoverbar position error",zh:"编辑区域高度 < 300px 这可能会导致 modal hoverbar 定位异常"};function Zw(e){var t=e.selector,r=void 0===t?"":t,n=e.config,o=void 0===n?{}:n,i=e.content,a=e.html,s=e.plugins,u=void 0===s?[]:s,l=function(e){return[Yb,Ob,Wm,Fb,rD,Gb,Kb,Ug].reduce(function(e,t){return t(e)},e)}((()=>{var e={children:[],operations:[],selection:null,marks:null,isInline:()=>!1,isVoid:()=>!1,onChange:()=>{},apply:t=>{for(var r of Yp.pathRefs(e))ig.transform(r,t);for(var n of Yp.pointRefs(e))lg.transform(n,t);for(var o of Yp.rangeRefs(e))fg.transform(o,t);var i,a,s=op.get(e)||[],u=ip.get(e)||new Set,l=e=>{if(e){var t=e.join(",");a.has(t)||(a.add(t),i.push(e))}};if(og.operationCanTransformPath(t))for(var c of(i=[],a=new Set,s))l(og.transform(c,t));else i=s,a=u;var d=e.getDirtyPaths(t);for(var h of d)l(h);op.set(e,i),ip.set(e,a),zg.transform(e,t),e.operations.push(t),Yp.normalize(e),"set_selection"===t.type&&(e.marks=null),ap.get(e)||(ap.set(e,!0),Promise.resolve().then(()=>{ap.set(e,!1),e.onChange(),e.operations=[]}))},addMark:(t,r)=>{var{selection:n}=e;if(n)if(hg.isExpanded(n))zg.setNodes(e,{[t]:r},{match:Cg.isText,split:!0});else{var o=hp(hp({},Yp.marks(e)||{}),{},{[t]:r});e.marks=o,ap.get(e)||e.onChange()}},deleteBackward:t=>{var{selection:r}=e;r&&hg.isCollapsed(r)&&zg.delete(e,{unit:t,reverse:!0})},deleteForward:t=>{var{selection:r}=e;r&&hg.isCollapsed(r)&&zg.delete(e,{unit:t})},deleteFragment:t=>{var{selection:r}=e;r&&hg.isExpanded(r)&&zg.delete(e,{reverse:"backward"===t})},getFragment:()=>{var{selection:t}=e;return t?eg.fragment(e,t):[]},insertBreak:()=>{zg.splitNodes(e,{always:!0})},insertSoftBreak:()=>{zg.splitNodes(e,{always:!0})},insertFragment:t=>{zg.insertFragment(e,t)},insertNode:t=>{zg.insertNodes(e,t)},insertText:t=>{var{selection:r,marks:n}=e;if(r){if(n){var o=hp({text:t},n);zg.insertNodes(e,o)}else zg.insertText(e,t);e.marks=null}},normalizeNode:t=>{var[r,n]=t;if(!Cg.isText(r))if(Vp.isElement(r)&&0===r.children.length)zg.insertNodes(e,{text:""},{at:n.concat(0),voids:!0});else for(var o=!Yp.isEditor(r)&&Vp.isElement(r)&&(e.isInline(r)||0===r.children.length||Cg.isText(r.children[0])||e.isInline(r.children[0])),i=0,a=0;a<r.children.length;a++,i++){var s=eg.get(e,n);if(!Cg.isText(s)){var u=r.children[a],l=s.children[i-1],c=a===r.children.length-1;(Cg.isText(u)||Vp.isElement(u)&&e.isInline(u))!==o?(zg.removeNodes(e,{at:n.concat(i),voids:!0}),i--):Vp.isElement(u)?e.isInline(u)&&(null!=l&&Cg.isText(l)?c&&(zg.insertNodes(e,{text:""},{at:n.concat(i+1),voids:!0}),i++):(zg.insertNodes(e,{text:""},{at:n.concat(i),voids:!0}),i++)):null!=l&&Cg.isText(l)&&(Cg.equals(u,l,{loose:!0})?(zg.mergeNodes(e,{at:n.concat(i),voids:!0}),i--):""===l.text?(zg.removeNodes(e,{at:n.concat(i-1),voids:!0}),i--):""===u.text&&(zg.removeNodes(e,{at:n.concat(i),voids:!0}),i--))}}},removeMark:t=>{var{selection:r}=e;if(r)if(hg.isExpanded(r))zg.unsetNodes(e,t,{match:Cg.isText,split:!0});else{var n=hp({},Yp.marks(e)||{});delete n[t],e.marks=n,ap.get(e)||e.onChange()}},getDirtyPaths:e=>{switch(e.type){case"insert_text":case"remove_text":case"set_node":var{path:t}=e;return og.levels(t);case"insert_node":var{node:r,path:n}=e,o=og.levels(n),i=Cg.isText(r)?[]:Array.from(eg.nodes(r),e=>{var[,t]=e;return n.concat(t)});return[...o,...i];case"merge_node":var{path:a}=e;return[...og.ancestors(a),og.previous(a)];case"move_node":var{path:s,newPath:u}=e;if(og.equals(s,u))return[];var l=[],c=[];for(var d of og.ancestors(s)){var h=og.transform(d,e);l.push(h)}for(var f of og.ancestors(u)){var p=og.transform(f,e);c.push(p)}var g=c[c.length-1],m=u[u.length-1],v=g.concat(m);return[...l,...c,v];case"remove_node":var{path:y}=e;return[...og.ancestors(y)];case"split_node":var{path:b}=e;return[...og.levels(b),og.next(b)];default:return[]}}};return e})());if(r&&function(e,t){return my(e,"data-w-e-textarea",t)}(l,r))throw new Error("Repeated create editor by selector '".concat(r,"'"));var c=function(e){void 0===e&&(e={});var t=sm(cm),r={},n=e.MENU_CONF,o=void 0===n?{}:n;return lm(t,function(e,t){r[t]=Kg(Kg({},e),o[t]||{})}),delete e.MENU_CONF,Kg({scroll:!0,readOnly:!1,autoFocus:!0,decorate:function(){return[]},maxLength:0,MENU_CONF:r,hoverbarKeys:{},customAlert:function(e,t){window.alert("".concat(t,":\n").concat(e))}},e)}(o);Fm.set(l,c);var d=c.hoverbarKeys,h=void 0===d?{}:d;if(u.forEach(function(e){l=e(l)}),function(e,t){var r=t.html,n=t.content;null!=r?e.children=vy(e,r):n&&n.length&&(e.children=n),0===e.children.length&&(e.children=[{type:"paragraph",children:[{text:""}]}])}(l,{html:a,content:i}),r){var f=new Yw(r);bm.set(l,f),Dm.set(f,l),f.changeViewState(),jv(function(){var e=f.$scroll;null!=e&&e.height()<300&&console.warn("".concat(Xw.zh,"\n").concat(Xw.en),{element:e,height:e.height()})});var p=void 0;Object.keys(h).length>0&&(p=new AC,Em.set(p,l),Am.set(l,p)),l.on(fm,function(){l.hidePanelOrModal()}),l.on(pm,function(){l.hidePanelOrModal()})}else l.children.forEach(function(e,t){return Kw(e,t,l,l)});var g=c.onCreated,m=c.onDestroyed;return g&&l.on(dm,function(){return g(l)}),m&&l.on(hm,function(){return m(l)}),jv(function(){return l.emit("created")}),l}var Jw=function(){function e(e,t){var r=this;this.$toolbar=ov('<div class="w-e-bar w-e-bar-show w-e-toolbar"></div>'),this.menus={},this.toolbarItems=[],this.config={},this.lngListen=function(){},this.changeToolbarState=oD(function(){r.toolbarItems.forEach(function(e){e.changeMenuState()})},200),this.config=t;var n=ov(e);if(0===n.length)throw new Error("Cannot find toolbar DOM by selector '".concat(e,"'"));this.$box=n;var o=this.$toolbar;o.on("mousedown",function(e){return e.preventDefault()},{passive:!1}),n.append(o),jv(function(){r.initToolbar(),r.lngListen=QD(function(){return r.initToolbar()}),r.getEditorInstance().on(fm,r.changeToolbarState)})}return e.prototype.getMenus=function(){return this.menus},e.prototype.getConfig=function(){return this.config},e.prototype.initToolbar=function(){this.menus={};var e=this.$toolbar;null==e||e.empty(),this.registerItems(),this.changeToolbarState()},e.prototype.registerItems=function(){var e=this,t="",r=this.$toolbar,n=this.config,o=n.toolbarKeys,i=void 0===o?[]:o,a=n.insertKeys,s=void 0===a?{index:0,keys:[]}:a,u=n.excludeKeys,l=void 0===u?[]:u,c=sm(i);s.keys.length>0&&("string"==typeof s.keys&&(s.keys=[s.keys]),s.keys.forEach(function(e,t){c.splice(s.index+t,0,e)}));var d=c.filter(function(e){var t="string"==typeof e?e:e.key;return!l.includes(t)}),h=d.length;d.forEach(function(n,o){if("|"===n){if(0===o)return;if(o+1===h)return;if("|"===t)return;var i=nC();return r.append(i),void(t=n)}if("string"==typeof n)return e.registerSingleItem(n,e),void(t=n);e.registerGroup(n),t="group"})},e.prototype.registerGroup=function(e){var t=this,r=this.$toolbar,n=function(e){return new vC(e)}(e),o=e.menuKeys,i=void 0===o?[]:o,a=this.config.excludeKeys,s=void 0===a?[]:a;i.forEach(function(e){s.includes(e)||t.registerSingleItem(e,n)}),r.append(n.$elem)},e.prototype.registerSingleItem=function(e,t){var r=this.getEditorInstance(),n=t instanceof vC,o=this.menus,i=o[e];if(null==i){var a=vm[e];if(null==a)throw new Error("Not found menu item factory by key '".concat(e,"'"));if("function"!=typeof a)throw new Error("Menu item factory (key='".concat(e,"') is not a function"));i=a(),o[e]=i}else console.warn("Duplicated toolbar menu key '".concat(e,"'\n重复注册了菜单栏 menu '").concat(e,"'"));var s=r.getMenuConfig(e);s&&void 0!==s.iconSvg&&(i.iconSvg=s.iconSvg);var u=DC(e,i,n);(this.toolbarItems.push(u),xm.set(u,r),n)?t.appendBarItem(u):t.$toolbar.append(u.$elem)},e.prototype.getEditorInstance=function(){var e=Cm.get(this);if(null==e)throw new Error("Can not get editor instance");return e},e.prototype.destroy=function(){var e;this.$toolbar.remove(),null===(e=this.lngListen)||void 0===e||e.call(this),this.menus={},this.toolbarItems=[]},e}();function Qw(e,t){if(null==e)throw new Error("Cannot create toolbar, because editor is null");var r=t.selector,n=t.config,o=void 0===n?{}:n;if(function(e,t){return my(e,"data-w-e-toolbar",t)}(e,r))throw new Error("Repeated create toolbar by selector '".concat(r,"'"));var i=Kg({toolbarKeys:[],excludeKeys:[],insertKeys:{index:0,keys:[]},modalAppendToBody:!1},o||{}),a=new Jw(r,i);return Cm.set(a,e),wm.set(e,a),a}var eE,tE,rE,nE,oE,iE={exports:{}},aE={};function sE(){if(rE)return aE;rE=1,Object.defineProperty(aE,"__esModule",{value:!0}),aE.justErrorsLogger=aE.debugLogger=void 0;const e=function(){if(tE)return eE;function e(e){return e<10?`0${e}`:e.toString()}return tE=1,eE=function(){const t=new Date;return`${e(t.getHours())}:${e(t.getMinutes())}:${e(t.getSeconds())}`}}(),t={debug:()=>{},warn:()=>{},error:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return console.error(`[Uppy] [${e()}]`,...r)}};aE.justErrorsLogger=t;const r={debug:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return console.debug(`[Uppy] [${e()}]`,...r)},warn:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return console.warn(`[Uppy] [${e()}]`,...r)},error:function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];return console.error(`[Uppy] [${e()}]`,...r)}};return aE.debugLogger=r,aE}function uE(){if(oE)return nE;oE=1;return nE={nanoid:(e=21)=>{let t="",r=0|e;for(;r--;)t+="useandom-26T198340PX75pxJACKVERYMINDBUSHWOLF_GQZbfghjklqvwyzrict"[64*Math.random()|0];return t},customAlphabet:(e,t=21)=>(r=t)=>{let n="",o=0|r;for(;o--;)n+=e[Math.random()*e.length|0];return n}},nE}var lE,cE,dE,hE,fE,pE,gE,mE,vE,yE,bE,DE,CE,wE,EE,AE,xE,BE,SE,FE,kE,OE,TE,NE,PE,ME,IE,RE,LE,_E,zE,jE={};function HE(){return cE?lE:(cE=1,lE=function(e){if("number"!=typeof e||isNaN(e))throw new TypeError("Expected a number, got "+typeof e);var t=e<0,r=["B","KB","MB","GB","TB","PB","EB","ZB","YB"];if(t&&(e=-e),e<1)return(t?"-":"")+e+" B";var n=Math.min(Math.floor(Math.log(e)/Math.log(1024)),r.length-1);e=Number(e/Math.pow(1024,n));var o=r[n];return e>=10||e%1==0?(t?"-":"")+e.toFixed(0)+" "+o:(t?"-":"")+e.toFixed(1)+" "+o})}function VE(){if(hE)return dE;function e(e,t){this.text=e=e||"",this.hasWild=~e.indexOf("*"),this.separator=t,this.parts=e.split(t)}return hE=1,e.prototype.match=function(e){var t,r,n=!0,o=this.parts,i=o.length;if("string"==typeof e||e instanceof String)if(this.hasWild||this.text==e){for(r=(e||"").split(this.separator),t=0;n&&t<i;t++)"*"!==o[t]&&(n=t<r.length&&o[t]===r[t]);n=n&&r}else n=!1;else if("function"==typeof e.splice)for(n=[],t=e.length;t--;)this.match(e[t])&&(n[n.length]=e[t]);else if("object"==typeof e)for(var a in n={},e)this.match(a)&&(n[a]=e[a]);return n},dE=function(t,r,n){var o=new e(t,n||/[\/\.]/);return void 0!==r?o.match(r):o},dE}function $E(){if(gE)return jE;gE=1,Object.defineProperty(jE,"__esModule",{value:!0}),jE.defaultOptions=jE.RestrictionError=jE.Restricter=void 0;const e=HE(),t=function(){if(pE)return fE;pE=1;var e=VE(),t=/[\/\+\.]/;return fE=function(r,n){function o(n){var o=e(n,r,t);return o&&o.length>=2}return n?o(n.split(";")[0]):o}}();jE.defaultOptions={maxFileSize:null,minFileSize:null,maxTotalFileSize:null,maxNumberOfFiles:null,minNumberOfFiles:null,allowedFileTypes:null,requiredMetaFields:[]};class r extends Error{constructor(){super(...arguments),this.isRestriction=!0}}jE.RestrictionError=r,"undefined"==typeof AggregateError&&(globalThis.AggregateError=class extends Error{constructor(e,t){super(t),this.errors=e}});return jE.Restricter=class{constructor(e,t){this.i18n=t,this.getOpts=()=>{const t=e();if(null!=t.restrictions.allowedFileTypes&&!Array.isArray(t.restrictions.allowedFileTypes))throw new TypeError("`restrictions.allowedFileTypes` must be an array");return t}}validate(n,o){const{maxFileSize:i,minFileSize:a,maxTotalFileSize:s,maxNumberOfFiles:u,allowedFileTypes:l}=this.getOpts().restrictions;if(u){const e=o.filter(e=>!e.isGhost);if(e.length+1>u)throw new r(`${this.i18n("youCanOnlyUploadX",{smart_count:u})}`)}if(l){if(!l.some(e=>e.includes("/")?!!n.type&&t(n.type.replace(/;.*?$/,""),e):!("."!==e[0]||!n.extension)&&n.extension.toLowerCase()===e.slice(1).toLowerCase())){const e=l.join(", ");throw new r(this.i18n("youCanOnlyUploadFileTypes",{types:e}))}}if(s&&null!=n.size){const t=o.reduce((e,t)=>e+t.size,n.size);if(t>s)throw new r(this.i18n("exceedsSize",{size:e(s),file:n.name}))}if(i&&null!=n.size&&n.size>i)throw new r(this.i18n("exceedsSize",{size:e(i),file:n.name}));if(a&&null!=n.size&&n.size<a)throw new r(this.i18n("inferiorSize",{size:e(a)}))}validateMinNumberOfFiles(e){const{minNumberOfFiles:t}=this.getOpts().restrictions;if(Object.keys(e).length<t)throw new r(this.i18n("youHaveToAtLeastSelectX",{smart_count:t}))}getMissingRequiredMetaFields(e){const t=new r(this.i18n("missingRequiredMetaFieldOnFile",{fileName:e.name})),{requiredMetaFields:n}=this.getOpts().restrictions,o=Object.prototype.hasOwnProperty,i=[];for(const t of n)o.call(e.meta,t)&&""!==e.meta[t]||i.push(t);return{missingFields:i,error:t}}},jE}function UE(){if(vE)return mE;return vE=1,mE=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)}}function qE(){if(bE)return yE;function e(e,t){if(!Object.prototype.hasOwnProperty.call(e,t))throw new TypeError("attempted to use private field on non-instance");return e}bE=1;var t=0;function r(e){return"__private_"+t+++"_"+e}const n=UE();function o(e,t,r){const n=[];return e.forEach(e=>"string"!=typeof e?n.push(e):t[Symbol.split](e).forEach((e,t,o)=>{""!==e&&n.push(e),t<o.length-1&&n.push(r)})),n}
|
|
8
8
|
/**
|
|
9
9
|
* Takes a string with placeholder variables like `%{smart_count} file selected`
|
|
10
10
|
* and replaces it with values from options `{smart_count: 5}`
|
|
@@ -15,7 +15,7 @@ var e,t,n,r,o,i,a,s,u,l,c,d,f,p,h,g,v,m,y="undefined"!=typeof globalThis?globalT
|
|
|
15
15
|
* @param {string} phrase that needs interpolation, with placeholders
|
|
16
16
|
* @param {object} options with values that will be used to replace placeholders
|
|
17
17
|
* @returns {any[]} interpolated
|
|
18
|
-
*/function i(e,t){const n=/\$/g;let r=[e];if(null==t)return r;for(const e of Object.keys(t))if("_"!==e){let i=t[e];"string"==typeof i&&(i=n[Symbol.replace](i,"$$$$")),r=o(r,new RegExp(`%\\{${e}\\}`,"g"),i)}return r}var a=n("apply");function s(e){if(null==e||!e.strings)return;const t=this.locale;this.locale={...t,strings:{...t.strings,...e.strings}},this.locale.pluralize=e.pluralize||t.pluralize}return vw=class{constructor(t){Object.defineProperty(this,a,{value:s}),this.locale={strings:{},pluralize:e=>1===e?0:1},Array.isArray(t)?t.forEach(e(this,a)[a],this):e(this,a)[a](t)}translate(e,t){return this.translateArray(e,t).join("")}translateArray(e,t){if(!r(this.locale.strings,e))throw new Error(`missing string: ${e}`);const n=this.locale.strings[e];if("object"==typeof n){if(t&&void 0!==t.smart_count){return i(n[this.locale.pluralize(t.smart_count)],t)}throw new Error("Attempted to use a string with plural forms, but no value was given for %{smart_count}")}return i(n,t)}},vw}function Vw(){return bw||(bw=1,yw=function(){var e={},t=e._fns={};return e.emit=function(e,n,r,o,i,a,s){var u=function(e){var n=t[e]?t[e]:[],r=e.indexOf(":"),o=-1===r?[e]:[e.substring(0,r),e.substring(r+1)],i=Object.keys(t),a=0,s=i.length;for(;a<s;a++){var u=i[a];if("*"===u&&(n=n.concat(t[u])),2===o.length&&o[0]===u){n=n.concat(t[u]);break}}return n}(e);u.length&&function(e,t,n){var r=0,o=t.length;for(;r<o&&t[r];r++)t[r].event=e,t[r].apply(t[r],n)}(e,u,[n,r,o,i,a,s])},e.on=function(e,n){t[e]||(t[e]=[]),t[e].push(n)},e.once=function(t,n){this.on(t,function r(){n.apply(this,arguments),e.off(t,r)})},e.off=function(e,t){var n=[];if(e&&t)for(var r=this._fns[e],o=0,i=r?r.length:0;o<i;o++)r[o]!==t&&n.push(r[o]);n.length?this._fns[e]=n:delete this._fns[e]},e}),yw}function Ww(){if(Cw)return Ew;Cw=1;var e=0;function t(t){return"__private_"+e+++"_"+t}var n=t("publish");class r{constructor(){Object.defineProperty(this,n,{value:o}),this.state={},this.callbacks=[]}getState(){return this.state}setState(e){const t={...this.state},r={...this.state,...e};this.state=r,function(e,t){if(!Object.prototype.hasOwnProperty.call(e,t))throw new TypeError("attempted to use private field on non-instance");return e}(this,n)[n](t,r,e)}subscribe(e){return this.callbacks.push(e),()=>{this.callbacks.splice(this.callbacks.indexOf(e),1)}}}function o(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];this.callbacks.forEach(e=>{e(...t)})}return r.VERSION="2.1.1",Ew=function(){return new r}}function Gw(){if(ww)return Dw;return ww=1,Dw=function(e){const t=e.lastIndexOf(".");return-1===t||t===e.length-1?{name:e,extension:void 0}:{name:e.slice(0,t),extension:e.slice(t+1)}}}function qw(){return Aw?Sw:(Aw=1,Sw={md:"text/markdown",markdown:"text/markdown",mp4:"video/mp4",mp3:"audio/mp3",svg:"image/svg+xml",jpg:"image/jpeg",png:"image/png",gif:"image/gif",heic:"image/heic",heif:"image/heif",yaml:"text/yaml",yml:"text/yaml",csv:"text/csv",tsv:"text/tab-separated-values",tab:"text/tab-separated-values",avi:"video/x-msvideo",mks:"video/x-matroska",mkv:"video/x-matroska",mov:"video/quicktime",dicom:"application/dicom",doc:"application/msword",docm:"application/vnd.ms-word.document.macroenabled.12",docx:"application/vnd.openxmlformats-officedocument.wordprocessingml.document",dot:"application/msword",dotm:"application/vnd.ms-word.template.macroenabled.12",dotx:"application/vnd.openxmlformats-officedocument.wordprocessingml.template",xla:"application/vnd.ms-excel",xlam:"application/vnd.ms-excel.addin.macroenabled.12",xlc:"application/vnd.ms-excel",xlf:"application/x-xliff+xml",xlm:"application/vnd.ms-excel",xls:"application/vnd.ms-excel",xlsb:"application/vnd.ms-excel.sheet.binary.macroenabled.12",xlsm:"application/vnd.ms-excel.sheet.macroenabled.12",xlsx:"application/vnd.openxmlformats-officedocument.spreadsheetml.sheet",xlt:"application/vnd.ms-excel",xltm:"application/vnd.ms-excel.template.macroenabled.12",xltx:"application/vnd.openxmlformats-officedocument.spreadsheetml.template",xlw:"application/vnd.ms-excel",txt:"text/plain",text:"text/plain",conf:"text/plain",log:"text/plain",pdf:"application/pdf",zip:"application/zip","7z":"application/x-7z-compressed",rar:"application/x-rar-compressed",tar:"application/x-tar",gz:"application/gzip",dmg:"application/x-apple-diskimage"})}function Kw(){if(Rw)return Lw;Rw=1;var e=aw(),t=iw(),n=zw();let r,o;function i(e,t){if(!Object.prototype.hasOwnProperty.call(e,t))throw new TypeError("attempted to use private field on non-instance");return e}var a=0;function s(e){return"__private_"+a+++"_"+e}const u=Uw(),l=Vw(),c=wC(),d=Ww(),f=function(){if(Ow)return xw;Ow=1;const e=Gw(),t=qw();return xw=function(n){var r;if(n.type)return n.type;const o=n.name?null==(r=e(n.name).extension)?void 0:r.toLowerCase():null;return o&&o in t?t[o]:"application/octet-stream"}}(),p=Gw(),h=function(){if(Bw)return Nw;function e(e){let t="";return e.replace(/[^A-Z0-9]/gi,e=>(t+=`-${function(e){return e.charCodeAt(0).toString(32)}(e)}`,"/"))+t}return Bw=1,Nw=function(t){let n="uppy";return"string"==typeof t.name&&(n+=`-${e(t.name.toLowerCase())}`),void 0!==t.type&&(n+=`-${t.type}`),t.meta&&"string"==typeof t.meta.relativePath&&(n+=`-${e(t.meta.relativePath.toLowerCase())}`),void 0!==t.data.size&&(n+=`-${t.data.size}`),void 0!==t.data.lastModified&&(n+=`-${t.data.lastModified}`),n}}(),g=(kw||(kw=1,Tw=function(e){if(null==e&&"undefined"!=typeof navigator&&(e=navigator.userAgent),!e)return!0;const t=/Edge\/(\d+\.\d+)/.exec(e);if(!t)return!0;const n=t[1];let[r,o]=n.split(".");return r=parseInt(r,10),o=parseInt(o,10),r<15||15===r&&o<15063||r>18||18===r&&o>=18218}),Tw),v=Iw?Fw:(Iw=1,Fw=function(e,t){return t.name?t.name:"image"===e.split("/")[0]?`${e.split("/")[0]}.${e.split("/")[1]}`:"noname"}),m=_w?Pw:(_w=1,Pw={strings:{addBulkFilesFailed:{0:"Failed to add %{smart_count} file due to an internal error",1:"Failed to add %{smart_count} files due to internal errors"},youCanOnlyUploadX:{0:"You can only upload %{smart_count} file",1:"You can only upload %{smart_count} files"},youHaveToAtLeastSelectX:{0:"You have to select at least %{smart_count} file",1:"You have to select at least %{smart_count} files"},exceedsSize:"%{file} exceeds maximum allowed size of %{size}",missingRequiredMetaField:"Missing required meta fields",missingRequiredMetaFieldOnFile:"Missing required meta fields in %{fileName}",inferiorSize:"This file is smaller than the allowed size of %{size}",youCanOnlyUploadFileTypes:"You can only upload: %{types}",noMoreFilesAllowed:"Cannot add more files",noDuplicates:"Cannot add the duplicate file '%{fileName}', it already exists",companionError:"Connection with Companion failed",authAborted:"Authentication aborted",companionUnauthorizeHint:"To unauthorize to your %{provider} account, please go to %{url}",failedToUpload:"Failed to upload %{file}",noInternetConnection:"No Internet connection",connectedToInternet:"Connected to the Internet",noFilesFound:"You have no files or folders here",selectX:{0:"Select %{smart_count}",1:"Select %{smart_count}"},allFilesFromFolderNamed:"All files from folder %{name}",openFolderNamed:"Open folder %{name}",cancel:"Cancel",logOut:"Log out",filter:"Filter",resetFilter:"Reset filter",loading:"Loading...",authenticateWithTitle:"Please authenticate with %{pluginName} to select files",authenticateWith:"Connect to %{pluginName}",signInWithGoogle:"Sign in with Google",searchImages:"Search for images",enterTextToSearch:"Enter text to search for images",search:"Search",emptyFolderAdded:"No files were added from empty folder",folderAlreadyAdded:'The folder "%{folder}" was already added',folderAdded:{0:"Added %{smart_count} file from %{folder}",1:"Added %{smart_count} files from %{folder}"}}});var y=s("plugins"),b=s("restricter"),E=s("storeUnsubscribe"),C=s("emitter"),D=s("preProcessors"),w=s("uploaders"),S=s("postProcessors"),A=s("informAndEmit"),x=s("checkRequiredMetaFieldsOnFile"),O=s("checkRequiredMetaFields"),N=s("assertNewUploadAllowed"),B=s("checkAndCreateFileStateObject"),T=s("startIfAutoProceed"),k=s("addListeners"),F=s("updateOnlineStatus"),I=s("createUpload"),P=s("getUpload"),_=s("removeUpload"),L=s("runUpload");r=Symbol.for("uppy test: getPlugins"),o=Symbol.for("uppy test: createUpload");class R{constructor(e){Object.defineProperty(this,L,{value:K}),Object.defineProperty(this,_,{value:q}),Object.defineProperty(this,P,{value:G}),Object.defineProperty(this,I,{value:W}),Object.defineProperty(this,k,{value:V}),Object.defineProperty(this,T,{value:U}),Object.defineProperty(this,B,{value:$}),Object.defineProperty(this,N,{value:z}),Object.defineProperty(this,O,{value:H}),Object.defineProperty(this,x,{value:j}),Object.defineProperty(this,A,{value:M}),Object.defineProperty(this,y,{writable:!0,value:Object.create(null)}),Object.defineProperty(this,b,{writable:!0,value:void 0}),Object.defineProperty(this,E,{writable:!0,value:void 0}),Object.defineProperty(this,C,{writable:!0,value:l()}),Object.defineProperty(this,D,{writable:!0,value:new Set}),Object.defineProperty(this,w,{writable:!0,value:new Set}),Object.defineProperty(this,S,{writable:!0,value:new Set}),Object.defineProperty(this,F,{writable:!0,value:this.updateOnlineStatus.bind(this)}),this.defaultLocale=m;const r={id:"uppy",autoProceed:!1,allowMultipleUploads:!0,allowMultipleUploadBatches:!0,debug:!1,restrictions:n.defaultOptions,meta:{},onBeforeFileAdded:e=>e,onBeforeUpload:e=>e,store:d(),logger:t.justErrorsLogger,infoTimeout:5e3};this.opts={...r,...e,restrictions:{...r.restrictions,...e&&e.restrictions}},e&&e.logger&&e.debug?this.log("You are using a custom `logger`, but also set `debug: true`, which uses built-in logger to output logs to console. Ignoring `debug: true` and using your custom `logger`.","warning"):e&&e.debug&&(this.opts.logger=t.debugLogger),this.log(`Using Core v${this.constructor.VERSION}`),this.i18nInit(),this.calculateProgress=c(this.calculateProgress.bind(this),500,{leading:!0,trailing:!0}),this.store=this.opts.store,this.setState({plugins:{},files:{},currentUploads:{},allowNewUpload:!0,capabilities:{uploadProgress:g(),individualCancellation:!0,resumableUploads:!1},totalProgress:0,meta:{...this.opts.meta},info:[],recoveredState:null}),i(this,b)[b]=new n.Restricter(()=>this.opts,this.i18n),i(this,E)[E]=this.store.subscribe((e,t,n)=>{this.emit("state-update",e,t,n),this.updateAll(t)}),this.opts.debug&&"undefined"!=typeof window&&(window[this.opts.id]=this),i(this,k)[k]()}emit(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];i(this,C)[C].emit(e,...n)}on(e,t){return i(this,C)[C].on(e,t),this}once(e,t){return i(this,C)[C].once(e,t),this}off(e,t){return i(this,C)[C].off(e,t),this}updateAll(e){this.iteratePlugins(t=>{t.update(e)})}setState(e){this.store.setState(e)}getState(){return this.store.getState()}get state(){return this.getState()}setFileState(e,t){if(!this.getState().files[e])throw new Error(`Can’t set state for ${e} (the file could have been removed)`);this.setState({files:{...this.getState().files,[e]:{...this.getState().files[e],...t}}})}i18nInit(){const e=new u([this.defaultLocale,this.opts.locale]);this.i18n=e.translate.bind(e),this.i18nArray=e.translateArray.bind(e),this.locale=e.locale}setOptions(e){this.opts={...this.opts,...e,restrictions:{...this.opts.restrictions,...e&&e.restrictions}},e.meta&&this.setMeta(e.meta),this.i18nInit(),e.locale&&this.iteratePlugins(e=>{e.setOptions()}),this.setState()}resetProgress(){const e={percentage:0,bytesUploaded:0,uploadComplete:!1,uploadStarted:null},t={...this.getState().files},n={};Object.keys(t).forEach(r=>{const o={...t[r]};o.progress={...o.progress,...e},n[r]=o}),this.setState({files:n,totalProgress:0}),this.emit("reset-progress")}addPreProcessor(e){i(this,D)[D].add(e)}removePreProcessor(e){return i(this,D)[D].delete(e)}addPostProcessor(e){i(this,S)[S].add(e)}removePostProcessor(e){return i(this,S)[S].delete(e)}addUploader(e){i(this,w)[w].add(e)}removeUploader(e){return i(this,w)[w].delete(e)}setMeta(e){const t={...this.getState().meta,...e},n={...this.getState().files};Object.keys(n).forEach(t=>{n[t]={...n[t],meta:{...n[t].meta,...e}}}),this.log("Adding metadata:"),this.log(e),this.setState({meta:t,files:n})}setFileMeta(e,t){const n={...this.getState().files};if(!n[e])return void this.log("Was trying to set metadata for a file that has been removed: ",e);const r={...n[e].meta,...t};n[e]={...n[e],meta:r},this.setState({files:n})}getFile(e){return this.getState().files[e]}getFiles(){const{files:e}=this.getState();return Object.values(e)}getObjectOfFilesPerState(){const{files:e,totalProgress:t,error:n}=this.getState(),r=Object.values(e),o=r.filter(e=>{let{progress:t}=e;return!t.uploadComplete&&t.uploadStarted}),i=r.filter(e=>!e.progress.uploadStarted),a=r.filter(e=>e.progress.uploadStarted||e.progress.preprocess||e.progress.postprocess),s=r.filter(e=>e.progress.uploadStarted),u=r.filter(e=>e.isPaused),l=r.filter(e=>e.progress.uploadComplete),c=r.filter(e=>e.error),d=o.filter(e=>!e.isPaused),f=r.filter(e=>e.progress.preprocess||e.progress.postprocess);return{newFiles:i,startedFiles:a,uploadStartedFiles:s,pausedFiles:u,completeFiles:l,erroredFiles:c,inProgressFiles:o,inProgressNotPausedFiles:d,processingFiles:f,isUploadStarted:s.length>0,isAllComplete:100===t&&l.length===r.length&&0===f.length,isAllErrored:!!n&&c.length===r.length,isAllPaused:0!==o.length&&u.length===o.length,isUploadInProgress:o.length>0,isSomeGhost:r.some(e=>e.isGhost)}}validateRestrictions(e,t){void 0===t&&(t=this.getFiles());try{return i(this,b)[b].validate(e,t),{result:!0}}catch(e){return{result:!1,reason:e.message}}}checkIfFileAlreadyExists(e){const{files:t}=this.getState();return!(!t[e]||t[e].isGhost)}addFile(e){i(this,N)[N](e);const{files:t}=this.getState();let n=i(this,B)[B](t,e);return t[n.id]&&t[n.id].isGhost&&(n={...t[n.id],data:e.data,isGhost:!1},this.log(`Replaced the blob in the restored ghost file: ${n.name}, ${n.id}`)),this.setState({files:{...t,[n.id]:n}}),this.emit("file-added",n),this.emit("files-added",[n]),this.log(`Added file: ${n.name}, ${n.id}, mime type: ${n.type}`),i(this,T)[T](),n.id}addFiles(e){i(this,N)[N]();const t={...this.getState().files},n=[],r=[];for(let o=0;o<e.length;o++)try{let r=i(this,B)[B](t,e[o]);t[r.id]&&t[r.id].isGhost&&(r={...t[r.id],data:e[o].data,isGhost:!1},this.log(`Replaced blob in a ghost file: ${r.name}, ${r.id}`)),t[r.id]=r,n.push(r)}catch(e){e.isRestriction||r.push(e)}if(this.setState({files:t}),n.forEach(e=>{this.emit("file-added",e)}),this.emit("files-added",n),n.length>5?this.log(`Added batch of ${n.length} files`):Object.keys(n).forEach(e=>{this.log(`Added file: ${n[e].name}\n id: ${n[e].id}\n type: ${n[e].type}`)}),n.length>0&&i(this,T)[T](),r.length>0){let e="Multiple errors occurred while adding files:\n";if(r.forEach(t=>{e+=`\n * ${t.message}`}),this.info({message:this.i18n("addBulkFilesFailed",{smart_count:r.length}),details:e},"error",this.opts.infoTimeout),"function"==typeof AggregateError)throw new AggregateError(r,e);{const t=new Error(e);throw t.errors=r,t}}}removeFiles(e,t){const{files:n,currentUploads:r}=this.getState(),o={...n},i={...r},a=Object.create(null);function s(e){return void 0===a[e]}e.forEach(e=>{n[e]&&(a[e]=n[e],delete o[e])}),Object.keys(i).forEach(e=>{const t=r[e].fileIDs.filter(s);if(0===t.length)return void delete i[e];const{capabilities:n}=this.getState();if(t.length!==r[e].fileIDs.length&&!n.individualCancellation)throw new Error("individualCancellation is disabled");i[e]={...r[e],fileIDs:t}});const u={currentUploads:i,files:o};0===Object.keys(o).length&&(u.allowNewUpload=!0,u.error=null,u.recoveredState=null),this.setState(u),this.calculateTotalProgress();const l=Object.keys(a);l.forEach(e=>{this.emit("file-removed",a[e],t)}),l.length>5?this.log(`Removed ${l.length} files`):this.log(`Removed files: ${l.join(", ")}`)}removeFile(e,t){void 0===t&&(t=null),this.removeFiles([e],t)}pauseResume(e){if(!this.getState().capabilities.resumableUploads||this.getFile(e).uploadComplete)return;const t=!(this.getFile(e).isPaused||!1);return this.setFileState(e,{isPaused:t}),this.emit("upload-pause",e,t),t}pauseAll(){const e={...this.getState().files};Object.keys(e).filter(t=>!e[t].progress.uploadComplete&&e[t].progress.uploadStarted).forEach(t=>{const n={...e[t],isPaused:!0};e[t]=n}),this.setState({files:e}),this.emit("pause-all")}resumeAll(){const e={...this.getState().files};Object.keys(e).filter(t=>!e[t].progress.uploadComplete&&e[t].progress.uploadStarted).forEach(t=>{const n={...e[t],isPaused:!1,error:null};e[t]=n}),this.setState({files:e}),this.emit("resume-all")}retryAll(){const e={...this.getState().files},t=Object.keys(e).filter(t=>e[t].error);if(t.forEach(t=>{const n={...e[t],isPaused:!1,error:null};e[t]=n}),this.setState({files:e,error:null}),this.emit("retry-all",t),0===t.length)return Promise.resolve({successful:[],failed:[]});const n=i(this,I)[I](t,{forceAllowNewUpload:!0});return i(this,L)[L](n)}cancelAll(e){let{reason:t="user"}=void 0===e?{}:e;if(this.emit("cancel-all",{reason:t}),"user"===t){const{files:e}=this.getState(),t=Object.keys(e);t.length&&this.removeFiles(t,"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 t=i(this,I)[I]([e],{forceAllowNewUpload:!0});return i(this,L)[L](t)}reset(){this.cancelAll(...arguments)}logout(){this.iteratePlugins(e=>{e.provider&&e.provider.logout&&e.provider.logout()})}calculateProgress(e,t){if(null==e||!this.getFile(e.id))return void this.log(`Not setting progress for a file that has been removed: ${null==e?void 0:e.id}`);const n=Number.isFinite(t.bytesTotal)&&t.bytesTotal>0;this.setFileState(e.id,{progress:{...this.getFile(e.id).progress,bytesUploaded:t.bytesUploaded,bytesTotal:t.bytesTotal,percentage:n?Math.round(t.bytesUploaded/t.bytesTotal*100):0}}),this.calculateTotalProgress()}calculateTotalProgress(){const e=this.getFiles().filter(e=>e.progress.uploadStarted||e.progress.preprocess||e.progress.postprocess);if(0===e.length)return this.emit("progress",0),void this.setState({totalProgress:0});const t=e.filter(e=>null!=e.progress.bytesTotal),n=e.filter(e=>null==e.progress.bytesTotal);if(0===t.length){const t=100*e.length,r=n.reduce((e,t)=>e+t.progress.percentage,0),o=Math.round(r/t*100);return void this.setState({totalProgress:o})}let r=t.reduce((e,t)=>e+t.progress.bytesTotal,0);const o=r/t.length;r+=o*n.length;let i=0;t.forEach(e=>{i+=e.progress.bytesUploaded}),n.forEach(e=>{i+=o*(e.progress.percentage||0)/100});let a=0===r?0:Math.round(i/r*100);a>100&&(a=100),this.setState({totalProgress:a}),this.emit("progress",a)}updateOnlineStatus(){void 0===window.navigator.onLine||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,t){if("function"!=typeof e){throw new TypeError(`Expected a plugin class, but got ${null===e?"null":typeof e}. Please verify that the plugin was imported and spelled correctly.`)}const n=new e(this,t),r=n.id;if(!r)throw new Error("Your plugin must have an id");if(!n.type)throw new Error("Your plugin must have a type");const o=this.getPlugin(r);if(o){const e=`Already found a plugin named '${o.id}'. Tried to use: '${r}'.\nUppy plugins must have unique \`id\` options. See https://uppy.io/docs/plugins/#id.`;throw new Error(e)}return e.VERSION&&this.log(`Using ${r} v${e.VERSION}`),n.type in i(this,y)[y]?i(this,y)[y][n.type].push(n):i(this,y)[y][n.type]=[n],n.install(),this}getPlugin(e){for(const t of Object.values(i(this,y)[y])){const n=t.find(t=>t.id===e);if(null!=n)return n}}[r](e){return i(this,y)[y][e]}iteratePlugins(e){Object.values(i(this,y)[y]).flat(1).forEach(e)}removePlugin(e){this.log(`Removing plugin ${e.id}`),this.emit("plugin-remove",e),e.uninstall&&e.uninstall();const t=i(this,y)[y][e.type],n=t.findIndex(t=>t.id===e.id);-1!==n&&t.splice(n,1);const r={plugins:{...this.getState().plugins,[e.id]:void 0}};this.setState(r)}close(e){let{reason:t}=void 0===e?{}:e;this.log(`Closing Uppy instance ${this.opts.id}: removing all files and uninstalling plugins`),this.cancelAll({reason:t}),i(this,E)[E](),this.iteratePlugins(e=>{this.removePlugin(e)}),"undefined"!=typeof window&&window.removeEventListener&&(window.removeEventListener("online",i(this,F)[F]),window.removeEventListener("offline",i(this,F)[F]))}hideInfo(){const{info:e}=this.getState();this.setState({info:e.slice(1)}),this.emit("info-hidden")}info(e,t,n){void 0===t&&(t="info"),void 0===n&&(n=3e3);const r="object"==typeof e;this.setState({info:[...this.getState().info,{type:t,message:r?e.message:e,details:r?e.details:null}]}),setTimeout(()=>this.hideInfo(),n),this.emit("info-visible")}log(e,t){const{logger:n}=this.opts;switch(t){case"error":n.error(e);break;case"warning":n.warn(e);break;default:n.debug(e)}}restore(e){return this.log(`Core: attempting to restore upload "${e}"`),this.getState().currentUploads[e]?i(this,L)[L](e):(i(this,_)[_](e),Promise.reject(new Error("Nonexistent upload")))}[o](){return i(this,I)[I](...arguments)}addResultData(e,t){if(!i(this,P)[P](e))return void this.log(`Not setting result for an upload that has been removed: ${e}`);const{currentUploads:n}=this.getState(),r={...n[e],result:{...n[e].result,...t}};this.setState({currentUploads:{...n,[e]:r}})}upload(){var e;null!=(e=i(this,y)[y].uploader)&&e.length||this.log("No uploader type plugins are used","warning");let{files:t}=this.getState();const r=this.opts.onBeforeUpload(t);return!1===r?Promise.reject(new Error("Not starting the upload because onBeforeUpload returned false")):(r&&"object"==typeof r&&(t=r,this.setState({files:t})),Promise.resolve().then(()=>i(this,b)[b].validateMinNumberOfFiles(t)).catch(e=>{throw i(this,A)[A](e),e}).then(()=>{if(!i(this,O)[O](t))throw new n.RestrictionError(this.i18n("missingRequiredMetaField"))}).catch(e=>{throw e}).then(()=>{const{currentUploads:e}=this.getState(),n=Object.values(e).flatMap(e=>e.fileIDs),r=[];Object.keys(t).forEach(e=>{const t=this.getFile(e);t.progress.uploadStarted||-1!==n.indexOf(e)||r.push(t.id)});const o=i(this,I)[I](r);return i(this,L)[L](o)}).catch(e=>{throw this.emit("error",e),this.log(e,"error"),e}))}}function M(e,t){const{message:n,details:r=""}=e;e.isRestriction?this.emit("restriction-failed",t,e):this.emit("error",e),this.info({message:n,details:r},"error",this.opts.infoTimeout),this.log(`${n} ${r}`.trim(),"error")}function j(e){const{missingFields:t,error:n}=i(this,b)[b].getMissingRequiredMetaFields(e);return!(t.length>0)||(this.setFileState(e.id,{missingRequiredMetaFields:t}),this.log(n.message),this.emit("restriction-failed",e,n),!1)}function H(e){let t=!0;for(const n of Object.values(e))i(this,x)[x](n)||(t=!1);return t}function z(e){const{allowNewUpload:t}=this.getState();if(!1===t){const t=new n.RestrictionError(this.i18n("noMoreFilesAllowed"));throw i(this,A)[A](t,e),t}}function $(e,t){const r=f(t),o=v(r,t),a=p(o).extension,s=Boolean(t.isRemote),u=h({...t,type:r});if(this.checkIfFileAlreadyExists(u)){const e=new n.RestrictionError(this.i18n("noDuplicates",{fileName:o}));throw i(this,A)[A](e,t),e}const l=t.meta||{};l.name=o,l.type=r;const c=Number.isFinite(t.data.size)?t.data.size:null;let d={source:t.source||"",id:u,name:o,extension:a||"",meta:{...this.getState().meta,...l},type:r,data:t.data,progress:{percentage:0,bytesUploaded:0,bytesTotal:c,uploadComplete:!1,uploadStarted:null},size:c,isRemote:s,remote:t.remote||"",preview:t.preview};const g=this.opts.onBeforeFileAdded(d,e);if(!1===g){const e=new n.RestrictionError("Cannot add the file because onBeforeFileAdded returned false.");throw this.emit("restriction-failed",t,e),e}"object"==typeof g&&null!==g&&(d=g);try{const t=Object.keys(e).map(t=>e[t]);i(this,b)[b].validate(d,t)}catch(e){throw i(this,A)[A](e,d),e}return d}function U(){this.opts.autoProceed&&!this.scheduledAutoProceed&&(this.scheduledAutoProceed=setTimeout(()=>{this.scheduledAutoProceed=null,this.upload().catch(e=>{e.isRestriction||this.log(e.stack||e.message||e)})},4))}function V(){const e=(e,t,n)=>{let r=e.message||"Unknown error";e.details&&(r+=` ${e.details}`),this.setState({error:r}),null!=t&&t.id in this.getState().files&&this.setFileState(t.id,{error:r,response:n})};this.on("error",e),this.on("upload-error",(t,n,r)=>{if(e(n,t,r),"object"==typeof n&&n.message){const e=new Error(n.message);e.details=n.message,n.details&&(e.details+=` ${n.details}`),e.message=this.i18n("failedToUpload",{file:null==t?void 0:t.name}),i(this,A)[A](e)}else i(this,A)[A](n)}),this.on("upload",()=>{this.setState({error:null})}),this.on("upload-started",e=>{null!=e&&this.getFile(e.id)?this.setFileState(e.id,{progress:{uploadStarted:Date.now(),uploadComplete:!1,percentage:0,bytesUploaded:0,bytesTotal:e.size}}):this.log(`Not setting progress for a file that has been removed: ${null==e?void 0:e.id}`)}),this.on("upload-progress",this.calculateProgress),this.on("upload-success",(e,t)=>{if(null==e||!this.getFile(e.id))return void this.log(`Not setting progress for a file that has been removed: ${null==e?void 0:e.id}`);const n=this.getFile(e.id).progress;this.setFileState(e.id,{progress:{...n,postprocess:i(this,S)[S].size>0?{mode:"indeterminate"}:null,uploadComplete:!0,percentage:100,bytesUploaded:n.bytesTotal},response:t,uploadURL:t.uploadURL,isPaused:!1}),null==e.size&&this.setFileState(e.id,{size:t.bytesUploaded||n.bytesTotal}),this.calculateTotalProgress()}),this.on("preprocess-progress",(e,t)=>{null!=e&&this.getFile(e.id)?this.setFileState(e.id,{progress:{...this.getFile(e.id).progress,preprocess:t}}):this.log(`Not setting progress for a file that has been removed: ${null==e?void 0:e.id}`)}),this.on("preprocess-complete",e=>{if(null==e||!this.getFile(e.id))return void this.log(`Not setting progress for a file that has been removed: ${null==e?void 0:e.id}`);const t={...this.getState().files};t[e.id]={...t[e.id],progress:{...t[e.id].progress}},delete t[e.id].progress.preprocess,this.setState({files:t})}),this.on("postprocess-progress",(e,t)=>{null!=e&&this.getFile(e.id)?this.setFileState(e.id,{progress:{...this.getState().files[e.id].progress,postprocess:t}}):this.log(`Not setting progress for a file that has been removed: ${null==e?void 0:e.id}`)}),this.on("postprocess-complete",e=>{if(null==e||!this.getFile(e.id))return void this.log(`Not setting progress for a file that has been removed: ${null==e?void 0:e.id}`);const t={...this.getState().files};t[e.id]={...t[e.id],progress:{...t[e.id].progress}},delete t[e.id].progress.postprocess,this.setState({files:t})}),this.on("restored",()=>{this.calculateTotalProgress()}),this.on("dashboard:file-edit-complete",e=>{e&&i(this,x)[x](e)}),"undefined"!=typeof window&&window.addEventListener&&(window.addEventListener("online",i(this,F)[F]),window.addEventListener("offline",i(this,F)[F]),setTimeout(i(this,F)[F],3e3))}function W(t,n){void 0===n&&(n={});const{forceAllowNewUpload:r=!1}=n,{allowNewUpload:o,currentUploads:i}=this.getState();if(!o&&!r)throw new Error("Cannot create a new upload: already uploading.");const a=(0,e.nanoid)();return this.emit("upload",{id:a,fileIDs:t}),this.setState({allowNewUpload:!1!==this.opts.allowMultipleUploadBatches&&!1!==this.opts.allowMultipleUploads,currentUploads:{...i,[a]:{fileIDs:t,step:0,result:{}}}}),a}function G(e){const{currentUploads:t}=this.getState();return t[e]}function q(e){const t={...this.getState().currentUploads};delete t[e],this.setState({currentUploads:t})}async function K(e){let{currentUploads:t}=this.getState(),n=t[e];const r=n.step||0,o=[...i(this,D)[D],...i(this,w)[w],...i(this,S)[S]];try{for(let i=r;i<o.length&&n;i++){const r=o[i],a={...n,step:i};this.setState({currentUploads:{...t,[e]:a}}),await r(a.fileIDs,e),t=this.getState().currentUploads,n=t[e]}}catch(t){throw i(this,_)[_](e),t}if(n){n.fileIDs.forEach(e=>{const t=this.getFile(e);t&&t.progress.postprocess&&this.emit("postprocess-complete",t)});const r=n.fileIDs.map(e=>this.getFile(e)),o=r.filter(e=>!e.error),i=r.filter(e=>e.error);await this.addResultData(e,{successful:o,failed:i,uploadID:e}),t=this.getState().currentUploads,n=t[e]}let a;return n&&(a=n.result,this.emit("complete",a),i(this,_)[_](e)),null==a&&this.log(`Not setting result for an upload that has been removed: ${e}`),a}return R.VERSION="2.3.4",Lw=R}var Yw,Xw,Zw,Jw,Qw,eS,tS,nS,rS,oS,iS,aS,sS,uS={},lS=[],cS=/acit|ex(?:s|g|n|p|$)|rph|grid|ows|mnc|ntw|ine[ch]|zoo|^ord|itera/i,dS=Array.isArray;function fS(e,t){for(var n in t)e[n]=t[n];return e}function pS(e){e&&e.parentNode&&e.parentNode.removeChild(e)}function hS(e,t,n){var r,o,i,a={};for(i in t)"key"==i?r=t[i]:"ref"==i?o=t[i]:a[i]=t[i];if(arguments.length>2&&(a.children=arguments.length>3?Yw.call(arguments,2):n),"function"==typeof e&&null!=e.defaultProps)for(i in e.defaultProps)void 0===a[i]&&(a[i]=e.defaultProps[i]);return gS(e,a,r,o,null)}function gS(e,t,n,r,o){var i={type:e,props:t,key:n,ref:r,__k:null,__:null,__b:0,__e:null,__c:null,constructor:void 0,__v:null==o?++Zw:o,__i:-1,__u:0};return null==o&&null!=Xw.vnode&&Xw.vnode(i),i}function vS(e){return e.children}function mS(e,t){this.props=e,this.context=t}function yS(e,t){if(null==t)return e.__?yS(e.__,e.__i+1):null;for(var n;t<e.__k.length;t++)if(null!=(n=e.__k[t])&&null!=n.__e)return n.__e;return"function"==typeof e.type?yS(e):null}function bS(e){var t,n;if(null!=(e=e.__)&&null!=e.__c){for(e.__e=e.__c.base=null,t=0;t<e.__k.length;t++)if(null!=(n=e.__k[t])&&null!=n.__e){e.__e=e.__c.base=n.__e;break}return bS(e)}}function ES(e){(!e.__d&&(e.__d=!0)&&Qw.push(e)&&!CS.__r++||eS!=Xw.debounceRendering)&&((eS=Xw.debounceRendering)||tS)(CS)}function CS(){for(var e,t,n,r,o,i,a,s=1;Qw.length;)Qw.length>s&&Qw.sort(nS),e=Qw.shift(),s=Qw.length,e.__d&&(n=void 0,o=(r=(t=e).__v).__e,i=[],a=[],t.__P&&((n=fS({},r)).__v=r.__v+1,Xw.vnode&&Xw.vnode(n),BS(t.__P,n,r,t.__n,t.__P.namespaceURI,32&r.__u?[o]:null,i,null==o?yS(r):o,!!(32&r.__u),a),n.__v=r.__v,n.__.__k[n.__i]=n,TS(i,n,a),n.__e!=o&&bS(n)));CS.__r=0}function DS(e,t,n,r,o,i,a,s,u,l,c){var d,f,p,h,g,v,m=r&&r.__k||lS,y=t.length;for(u=wS(n,t,m,u,y),d=0;d<y;d++)null!=(p=n.__k[d])&&(f=-1==p.__i?uS:m[p.__i]||uS,p.__i=d,v=BS(e,p,f,o,i,a,s,u,l,c),h=p.__e,p.ref&&f.ref!=p.ref&&(f.ref&&IS(f.ref,null,p),c.push(p.ref,p.__c||h,p)),null==g&&null!=h&&(g=h),4&p.__u||f.__k===p.__k?u=SS(p,u,e):"function"==typeof p.type&&void 0!==v?u=v:h&&(u=h.nextSibling),p.__u&=-7);return n.__e=g,u}function wS(e,t,n,r,o){var i,a,s,u,l,c=n.length,d=c,f=0;for(e.__k=new Array(o),i=0;i<o;i++)null!=(a=t[i])&&"boolean"!=typeof a&&"function"!=typeof a?(u=i+f,(a=e.__k[i]="string"==typeof a||"number"==typeof a||"bigint"==typeof a||a.constructor==String?gS(null,a,null,null,null):dS(a)?gS(vS,{children:a},null,null,null):null==a.constructor&&a.__b>0?gS(a.type,a.props,a.key,a.ref?a.ref:null,a.__v):a).__=e,a.__b=e.__b+1,s=null,-1!=(l=a.__i=AS(a,n,u,d))&&(d--,(s=n[l])&&(s.__u|=2)),null==s||null==s.__v?(-1==l&&(o>c?f--:o<c&&f++),"function"!=typeof a.type&&(a.__u|=4)):l!=u&&(l==u-1?f--:l==u+1?f++:(l>u?f--:f++,a.__u|=4))):e.__k[i]=null;if(d)for(i=0;i<c;i++)null!=(s=n[i])&&!(2&s.__u)&&(s.__e==r&&(r=yS(s)),PS(s,s));return r}function SS(e,t,n){var r,o;if("function"==typeof e.type){for(r=e.__k,o=0;r&&o<r.length;o++)r[o]&&(r[o].__=e,t=SS(r[o],t,n));return t}e.__e!=t&&(t&&e.type&&!n.contains(t)&&(t=yS(e)),n.insertBefore(e.__e,t||null),t=e.__e);do{t=t&&t.nextSibling}while(null!=t&&8==t.nodeType);return t}function AS(e,t,n,r){var o,i,a=e.key,s=e.type,u=t[n];if(null===u&&null==e.key||u&&a==u.key&&s==u.type&&!(2&u.__u))return n;if(r>(null==u||2&u.__u?0:1))for(o=n-1,i=n+1;o>=0||i<t.length;){if(o>=0){if((u=t[o])&&!(2&u.__u)&&a==u.key&&s==u.type)return o;o--}if(i<t.length){if((u=t[i])&&!(2&u.__u)&&a==u.key&&s==u.type)return i;i++}}return-1}function xS(e,t,n){"-"==t[0]?e.setProperty(t,null==n?"":n):e[t]=null==n?"":"number"!=typeof n||cS.test(t)?n:n+"px"}function OS(e,t,n,r,o){var i,a;e:if("style"==t)if("string"==typeof n)e.style.cssText=n;else{if("string"==typeof r&&(e.style.cssText=r=""),r)for(t in r)n&&t in n||xS(e.style,t,"");if(n)for(t in n)r&&n[t]==r[t]||xS(e.style,t,n[t])}else if("o"==t[0]&&"n"==t[1])i=t!=(t=t.replace(rS,"$1")),a=t.toLowerCase(),t=a in e||"onFocusOut"==t||"onFocusIn"==t?a.slice(2):t.slice(2),e.l||(e.l={}),e.l[t+i]=n,n?r?n.u=r.u:(n.u=oS,e.addEventListener(t,i?aS:iS,i)):e.removeEventListener(t,i?aS:iS,i);else{if("http://www.w3.org/2000/svg"==o)t=t.replace(/xlink(H|:h)/,"h").replace(/sName$/,"s");else if("width"!=t&&"height"!=t&&"href"!=t&&"list"!=t&&"form"!=t&&"tabIndex"!=t&&"download"!=t&&"rowSpan"!=t&&"colSpan"!=t&&"role"!=t&&"popover"!=t&&t in e)try{e[t]=null==n?"":n;break e}catch(e){}"function"==typeof n||(null==n||!1===n&&"-"!=t[4]?e.removeAttribute(t):e.setAttribute(t,"popover"==t&&1==n?"":n))}}function NS(e){return function(t){if(this.l){var n=this.l[t.type+e];if(null==t.t)t.t=oS++;else if(t.t<n.u)return;return n(Xw.event?Xw.event(t):t)}}}function BS(e,t,n,r,o,i,a,s,u,l){var c,d,f,p,h,g,v,m,y,b,E,C,D,w,S,A,x,O=t.type;if(null!=t.constructor)return null;128&n.__u&&(u=!!(32&n.__u),i=[s=t.__e=n.__e]),(c=Xw.__b)&&c(t);e:if("function"==typeof O)try{if(m=t.props,y="prototype"in O&&O.prototype.render,b=(c=O.contextType)&&r[c.__c],E=c?b?b.props.value:c.__:r,n.__c?v=(d=t.__c=n.__c).__=d.__E:(y?t.__c=d=new O(m,E):(t.__c=d=new mS(m,E),d.constructor=O,d.render=_S),b&&b.sub(d),d.props=m,d.state||(d.state={}),d.context=E,d.__n=r,f=d.__d=!0,d.__h=[],d._sb=[]),y&&null==d.__s&&(d.__s=d.state),y&&null!=O.getDerivedStateFromProps&&(d.__s==d.state&&(d.__s=fS({},d.__s)),fS(d.__s,O.getDerivedStateFromProps(m,d.__s))),p=d.props,h=d.state,d.__v=t,f)y&&null==O.getDerivedStateFromProps&&null!=d.componentWillMount&&d.componentWillMount(),y&&null!=d.componentDidMount&&d.__h.push(d.componentDidMount);else{if(y&&null==O.getDerivedStateFromProps&&m!==p&&null!=d.componentWillReceiveProps&&d.componentWillReceiveProps(m,E),!d.__e&&null!=d.shouldComponentUpdate&&!1===d.shouldComponentUpdate(m,d.__s,E)||t.__v==n.__v){for(t.__v!=n.__v&&(d.props=m,d.state=d.__s,d.__d=!1),t.__e=n.__e,t.__k=n.__k,t.__k.some(function(e){e&&(e.__=t)}),C=0;C<d._sb.length;C++)d.__h.push(d._sb[C]);d._sb=[],d.__h.length&&a.push(d);break e}null!=d.componentWillUpdate&&d.componentWillUpdate(m,d.__s,E),y&&null!=d.componentDidUpdate&&d.__h.push(function(){d.componentDidUpdate(p,h,g)})}if(d.context=E,d.props=m,d.__P=e,d.__e=!1,D=Xw.__r,w=0,y){for(d.state=d.__s,d.__d=!1,D&&D(t),c=d.render(d.props,d.state,d.context),S=0;S<d._sb.length;S++)d.__h.push(d._sb[S]);d._sb=[]}else do{d.__d=!1,D&&D(t),c=d.render(d.props,d.state,d.context),d.state=d.__s}while(d.__d&&++w<25);d.state=d.__s,null!=d.getChildContext&&(r=fS(fS({},r),d.getChildContext())),y&&!f&&null!=d.getSnapshotBeforeUpdate&&(g=d.getSnapshotBeforeUpdate(p,h)),A=c,null!=c&&c.type===vS&&null==c.key&&(A=kS(c.props.children)),s=DS(e,dS(A)?A:[A],t,n,r,o,i,a,s,u,l),d.base=t.__e,t.__u&=-161,d.__h.length&&a.push(d),v&&(d.__E=d.__=null)}catch(e){if(t.__v=null,u||null!=i)if(e.then){for(t.__u|=u?160:128;s&&8==s.nodeType&&s.nextSibling;)s=s.nextSibling;i[i.indexOf(s)]=null,t.__e=s}else for(x=i.length;x--;)pS(i[x]);else t.__e=n.__e,t.__k=n.__k;Xw.__e(e,t,n)}else null==i&&t.__v==n.__v?(t.__k=n.__k,t.__e=n.__e):s=t.__e=FS(n.__e,t,n,r,o,i,a,u,l);return(c=Xw.diffed)&&c(t),128&t.__u?void 0:s}function TS(e,t,n){for(var r=0;r<n.length;r++)IS(n[r],n[++r],n[++r]);Xw.__c&&Xw.__c(t,e),e.some(function(t){try{e=t.__h,t.__h=[],e.some(function(e){e.call(t)})}catch(e){Xw.__e(e,t.__v)}})}function kS(e){return"object"!=typeof e||null==e||e.__b&&e.__b>0?e:dS(e)?e.map(kS):fS({},e)}function FS(e,t,n,r,o,i,a,s,u){var l,c,d,f,p,h,g,v=n.props,m=t.props,y=t.type;if("svg"==y?o="http://www.w3.org/2000/svg":"math"==y?o="http://www.w3.org/1998/Math/MathML":o||(o="http://www.w3.org/1999/xhtml"),null!=i)for(l=0;l<i.length;l++)if((p=i[l])&&"setAttribute"in p==!!y&&(y?p.localName==y:3==p.nodeType)){e=p,i[l]=null;break}if(null==e){if(null==y)return document.createTextNode(m);e=document.createElementNS(o,y,m.is&&m),s&&(Xw.__m&&Xw.__m(t,i),s=!1),i=null}if(null==y)v===m||s&&e.data==m||(e.data=m);else{if(i=i&&Yw.call(e.childNodes),v=n.props||uS,!s&&null!=i)for(v={},l=0;l<e.attributes.length;l++)v[(p=e.attributes[l]).name]=p.value;for(l in v)if(p=v[l],"children"==l);else if("dangerouslySetInnerHTML"==l)d=p;else if(!(l in m)){if("value"==l&&"defaultValue"in m||"checked"==l&&"defaultChecked"in m)continue;OS(e,l,null,p,o)}for(l in m)p=m[l],"children"==l?f=p:"dangerouslySetInnerHTML"==l?c=p:"value"==l?h=p:"checked"==l?g=p:s&&"function"!=typeof p||v[l]===p||OS(e,l,p,v[l],o);if(c)s||d&&(c.__html==d.__html||c.__html==e.innerHTML)||(e.innerHTML=c.__html),t.__k=[];else if(d&&(e.innerHTML=""),DS("template"==t.type?e.content:e,dS(f)?f:[f],t,n,r,"foreignObject"==y?"http://www.w3.org/1999/xhtml":o,i,a,i?i[0]:n.__k&&yS(n,0),s,u),null!=i)for(l=i.length;l--;)pS(i[l]);s||(l="value","progress"==y&&null==h?e.removeAttribute("value"):null!=h&&(h!==e[l]||"progress"==y&&!h||"option"==y&&h!=v[l])&&OS(e,l,h,v[l],o),l="checked",null!=g&&g!=e[l]&&OS(e,l,g,v[l],o))}return e}function IS(e,t,n){try{if("function"==typeof e){var r="function"==typeof e.__u;r&&e.__u(),r&&null==t||(e.__u=e(t))}else e.current=t}catch(e){Xw.__e(e,n)}}function PS(e,t,n){var r,o;if(Xw.unmount&&Xw.unmount(e),(r=e.ref)&&(r.current&&r.current!=e.__e||IS(r,null,t)),null!=(r=e.__c)){if(r.componentWillUnmount)try{r.componentWillUnmount()}catch(e){Xw.__e(e,t)}r.base=r.__P=null}if(r=e.__k)for(o=0;o<r.length;o++)r[o]&&PS(r[o],t,n||"function"!=typeof e.type);n||pS(e.__e),e.__c=e.__=e.__e=void 0}function _S(e,t,n){return this.constructor(e,n)}function LS(e,t,n){var r,o,i,a;t==document&&(t=document.documentElement),Xw.__&&Xw.__(e,t),o=(r="function"==typeof n)?null:n&&n.__k||t.__k,i=[],a=[],BS(t,e=(!r&&n||t).__k=hS(vS,null,[e]),o||uS,uS,t.namespaceURI,!r&&n?[n]:o?null:t.firstChild?Yw.call(t.childNodes):null,i,!r&&n?n:o?o.__e:t.firstChild,r,a),TS(i,e,a)}Yw=lS.slice,Xw={__e:function(e,t,n,r){for(var o,i,a;t=t.__;)if((o=t.__c)&&!o.__)try{if((i=o.constructor)&&null!=i.getDerivedStateFromError&&(o.setState(i.getDerivedStateFromError(e)),a=o.__d),null!=o.componentDidCatch&&(o.componentDidCatch(e,r||{}),a=o.__d),a)return o.__E=o}catch(t){e=t}throw e}},Zw=0,Jw=function(e){return null!=e&&null==e.constructor},mS.prototype.setState=function(e,t){var n;n=null!=this.__s&&this.__s!=this.state?this.__s:this.__s=fS({},this.state),"function"==typeof e&&(e=e(fS({},n),this.props)),e&&fS(n,e),null!=e&&this.__v&&(t&&this._sb.push(t),ES(this))},mS.prototype.forceUpdate=function(e){this.__v&&(this.__e=!0,e&&this.__h.push(e),ES(this))},mS.prototype.render=vS,Qw=[],tS="function"==typeof Promise?Promise.prototype.then.bind(Promise.resolve()):setTimeout,nS=function(e,t){return e.__v.__b-t.__v.__b},CS.__r=0,rS=/(PointerCapture)$|Capture$/i,oS=0,iS=NS(!1),aS=NS(!0),sS=0;var RS,MS,jS,HS,zS,$S,US,VS,WS,GS,qS,KS=Object.freeze({__proto__:null,Component:mS,Fragment:vS,cloneElement:function(e,t,n){var r,o,i,a,s=fS({},e.props);for(i in e.type&&e.type.defaultProps&&(a=e.type.defaultProps),t)"key"==i?r=t[i]:"ref"==i?o=t[i]:s[i]=void 0===t[i]&&null!=a?a[i]:t[i];return arguments.length>2&&(s.children=arguments.length>3?Yw.call(arguments,2):n),gS(e.type,s,r||e.key,o||e.ref,null)},createContext:function(e){function t(e){var n,r;return this.getChildContext||(n=new Set,(r={})[t.__c]=this,this.getChildContext=function(){return r},this.componentWillUnmount=function(){n=null},this.shouldComponentUpdate=function(e){this.props.value!=e.value&&n.forEach(function(e){e.__e=!0,ES(e)})},this.sub=function(e){n.add(e);var t=e.componentWillUnmount;e.componentWillUnmount=function(){n&&n.delete(e),t&&t.call(e)}}),e.children}return t.__c="__cC"+sS++,t.__=e,t.Provider=t.__l=(t.Consumer=function(e,t){return e.children(t)}).contextType=t,t},createElement:hS,createRef:function(){return{current:null}},h:hS,hydrate:function e(t,n){LS(t,n,e)},get isValidElement(){return Jw},get options(){return Xw},render:LS,toChildArray:function e(t,n){return n=n||[],null==t||"boolean"==typeof t||(dS(t)?t.some(function(t){e(t,n)}):n.push(t)),n}}),YS=E(KS);function XS(){if(HS)return jS;HS=1;const e=MS?RS:(MS=1,RS=function(e){return(null==e?void 0:e.nodeType)===Node.ELEMENT_NODE});return jS=function(t,n){return void 0===n&&(n=document),"string"==typeof t?n.querySelector(t):e(t)?t:null}}function ZS(){if(VS)return US;VS=1;const e=Uw();return US=class{constructor(e,t){void 0===t&&(t={}),this.uppy=e,this.opts=t}getPluginState(){const{plugins:e}=this.uppy.getState();return e[this.id]||{}}setPluginState(e){const{plugins:t}=this.uppy.getState();this.uppy.setState({plugins:{...t,[this.id]:{...t[this.id],...e}}})}setOptions(e){this.opts={...this.opts,...e},this.setPluginState(),this.i18nInit()}i18nInit(){const t=new e([this.defaultLocale,this.uppy.locale,this.opts.locale]);this.i18n=t.translate.bind(t),this.i18nArray=t.translateArray.bind(t),this.setPluginState()}addTarget(){throw new Error("Extend the addTarget method to add your plugin to another plugin's target")}install(){}uninstall(){}render(){throw new Error("Extend the render method to add your plugin to a DOM element")}update(){}afterUpdate(){}}}function JS(){if(GS)return WS;GS=1;var e=YS;function t(e,t){if(!Object.prototype.hasOwnProperty.call(e,t))throw new TypeError("attempted to use private field on non-instance");return e}var n=0;function r(e){return"__private_"+n+++"_"+e}const o=XS(),i=$S?zS:($S=1,zS=function(e){for(var t;e&&!e.dir;)e=e.parentNode;return null==(t=e)?void 0:t.dir}),a=ZS();var s=r("updateUI");class u extends a{constructor(){super(...arguments),Object.defineProperty(this,s,{writable:!0,value:void 0})}mount(n,r){const a=r.id,l=o(n);if(l){this.isTargetDOMEl=!0;const r=document.createElement("div");return r.classList.add("uppy-Root"),t(this,s)[s]=function(e){let t=null,n=null;return function(){for(var r=arguments.length,o=new Array(r),i=0;i<r;i++)o[i]=arguments[i];return n=o,t||(t=Promise.resolve().then(()=>(t=null,e(...n)))),t}}(t=>{this.uppy.getPlugin(this.id)&&((0,e.render)(this.render(t),r),this.afterUpdate())}),this.uppy.log(`Installing ${a} to a DOM element '${n}'`),this.opts.replaceTargetContent&&(l.innerHTML=""),(0,e.render)(this.render(this.uppy.getState()),r),this.el=r,l.appendChild(r),r.dir=this.opts.direction||i(r)||"ltr",this.onMount(),this.el}let c;if("object"==typeof n&&n instanceof u)c=n;else if("function"==typeof n){const e=n;this.uppy.iteratePlugins(t=>{t instanceof e&&(c=t)})}if(c)return this.uppy.log(`Installing ${a} to ${c.id}`),this.parent=c,this.el=c.addTarget(r),this.onMount(),this.el;this.uppy.log(`Not installing ${a}`);let d=`Invalid target option given to ${a}.`;throw d+="function"==typeof n?" The given target is not a Plugin class. Please check that you're not specifying a React Component instead of a plugin. If you are using @uppy/* packages directly, make sure you have only 1 version of @uppy/core installed: run `npm ls @uppy/core` on the command line and verify that all the versions match and are deduped correctly.":"If you meant to target an HTML element, please make sure that the element exists. Check that the <script> tag initializing Uppy is right before the closing </body> tag at the end of the page. (see https://github.com/transloadit/uppy/issues/1042)\n\nIf you meant to target a plugin, please confirm that your `import` statements or `require` calls are correct.",new Error(d)}update(e){var n,r;null!=this.el&&(null==(n=(r=t(this,s))[s])||n.call(r,e))}unmount(){var e;this.isTargetDOMEl&&(null==(e=this.el)||e.remove());this.onUnmount()}onMount(){}onUnmount(){}}return WS=u}var QS,eA,tA,nA,rA,oA,iA,aA,sA,uA,lA=(qS||(qS=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.Uppy=t.UIPlugin=t.BasePlugin=void 0,Object.defineProperty(t,"debugLogger",{enumerable:!0,get:function(){return n.debugLogger}});var n=iw();e.exports=Kw();const r=JS();t.UIPlugin=r;const o=ZS();t.BasePlugin=o;const i=Kw();t.Uppy=i;const a=JS(),s=ZS();i.Uppy=i,i.UIPlugin=a,i.BasePlugin=s,i.debugLogger=n.debugLogger}(rw,rw.exports)),rw.exports),cA=b(lA),dA={};function fA(){if(eA)return QS;eA=1;class e extends Error{constructor(e,t){void 0===t&&(t=null),super("This looks like a network error, the endpoint might be blocked by an internet provider or a firewall."),this.cause=e,this.isNetworkError=!0,this.request=t}}return QS=e}function pA(){if(uA)return sA;let e;function t(e,t){if(!Object.prototype.hasOwnProperty.call(e,t))throw new TypeError("attempted to use private field on non-instance");return e}uA=1;var n=0;function r(e){return"__private_"+n+++"_"+e}const o=function(){if(nA)return tA;nA=1;const e=fA();return tA=function(){return fetch(...arguments).catch(t=>{throw"AbortError"===t.name?t:new e(t)})},tA}(),i=function(){if(oA)return rA;oA=1;const e=$w();class t extends Error{constructor(t,n){void 0===n&&(n={}),super(t),this.cause=n.cause,this.cause&&e(this.cause,"isNetworkError")&&(this.isNetworkError=this.cause.isNetworkError)}}return rA=t}(),a=function(){if(aA)return iA;aA=1;class e extends Error{constructor(){super("Authorization required"),this.name="AuthError",this.isAuthError=!0}}return iA=e}();async function s(e){if(401===e.status)throw new a;const t=e.json();if(e.status<200||e.status>300){let n=`Failed request with status: ${e.status}. ${e.statusText}`;try{const e=await t;n=e.message?`${n} message: ${e.message}`:n,n=e.requestId?`${n} request-Id: ${e.requestId}`:n}finally{throw new Error(n)}}return t}var u=r("companionHeaders"),l=r("getPostResponseFunc"),c=r("getUrl"),d=r("errorHandler");e=Symbol.for("uppy test: getCompanionHeaders");class f{constructor(e,n){Object.defineProperty(this,d,{value:h}),Object.defineProperty(this,c,{value:p}),Object.defineProperty(this,u,{writable:!0,value:void 0}),Object.defineProperty(this,l,{writable:!0,value:e=>t=>e?t:this.onReceiveResponse(t)}),this.uppy=e,this.opts=n,this.onReceiveResponse=this.onReceiveResponse.bind(this),this.allowedHeaders=["accept","content-type","uppy-auth-token"],this.preflightDone=!1,t(this,u)[u]=null==n?void 0:n.companionHeaders}setCompanionHeaders(e){t(this,u)[u]=e}[e](){return t(this,u)[u]}get hostname(){const{companion:e}=this.uppy.getState(),t=this.opts.companionUrl;return(e&&e[t]?e[t]:t).replace(/\/$/,"")}headers(){return Promise.resolve({...f.defaultHeaders,...t(this,u)[u]})}onReceiveResponse(e){const t=this.uppy.getState().companion||{},n=this.opts.companionUrl,{headers:r}=e;return r.has("i-am")&&r.get("i-am")!==t[n]&&this.uppy.setState({companion:{...t,[n]:r.get("i-am")}}),e}preflight(e){return this.preflightDone?Promise.resolve(this.allowedHeaders.slice()):fetch(t(this,c)[c](e),{method:"OPTIONS"}).then(e=>(e.headers.has("access-control-allow-headers")&&(this.allowedHeaders=e.headers.get("access-control-allow-headers").split(",").map(e=>e.trim().toLowerCase())),this.preflightDone=!0,this.allowedHeaders.slice())).catch(e=>(this.uppy.log(`[CompanionClient] unable to make preflight request ${e}`,"warning"),this.preflightDone=!0,this.allowedHeaders.slice()))}preflightAndHeaders(e){return Promise.all([this.preflight(e),this.headers()]).then(e=>{let[t,n]=e;return Object.keys(n).forEach(e=>{t.includes(e.toLowerCase())||(this.uppy.log(`[CompanionClient] excluding disallowed header ${e}`),delete n[e])}),n})}get(e,n){return this.preflightAndHeaders(e).then(n=>o(t(this,c)[c](e),{method:"get",headers:n,credentials:this.opts.companionCookiesRule||"same-origin"})).then(t(this,l)[l](n)).then(s).catch(t(this,d)[d]("get",e))}post(e,n,r){const i="post";return this.preflightAndHeaders(e).then(r=>o(t(this,c)[c](e),{method:i,headers:r,credentials:this.opts.companionCookiesRule||"same-origin",body:JSON.stringify(n)})).then(t(this,l)[l](r)).then(s).catch(t(this,d)[d](i,e))}delete(e,n,r){const i="delete";return this.preflightAndHeaders(e).then(t=>o(`${this.hostname}/${e}`,{method:i,headers:t,credentials:this.opts.companionCookiesRule||"same-origin",body:n?JSON.stringify(n):null})).then(t(this,l)[l](r)).then(s).catch(t(this,d)[d](i,e))}}function p(e){return/^(https?:|)\/\//.test(e)?e:`${this.hostname}/${e}`}function h(e,n){return r=>{var o;return null!=(o=r)&&o.isAuthError||(r=new i(`Could not ${e} ${t(this,c)[c](n)}`,{cause:r})),Promise.reject(r)}}return f.VERSION="2.2.2",f.defaultHeaders={Accept:"application/json","Content-Type":"application/json","Uppy-Versions":`@uppy/companion-client=${f.VERSION}`},sA=f}var hA,gA,vA,mA,yA,bA,EA,CA,DA={};function wA(){if(hA)return DA;return hA=1,Object.defineProperty(DA,"__esModule",{value:!0}),DA.getItem=function(e){return Promise.resolve(localStorage.getItem(e))},DA.removeItem=function(e){return new Promise(t=>{localStorage.removeItem(e),t()})},DA.setItem=function(e,t){return new Promise(n=>{localStorage.setItem(e,t),n()})},DA}function SA(){if(CA)return dA;CA=1,Object.defineProperty(dA,"__esModule",{value:!0}),dA.Socket=dA.SearchProvider=dA.RequestClient=dA.Provider=void 0;const e=pA();dA.RequestClient=e;const t=function(){if(vA)return gA;vA=1;var e=wA();const t=pA();return gA=class extends t{constructor(e,t){super(e,t),this.provider=t.provider,this.id=this.provider,this.name=this.opts.name||this.id.split("-").map(e=>e.charAt(0).toUpperCase()+e.slice(1)).join(" "),this.pluginId=this.opts.pluginId,this.tokenKey=`companion-${this.pluginId}-auth-token`,this.companionKeysParams=this.opts.companionKeysParams,this.preAuthToken=null}headers(){return Promise.all([super.headers(),this.getAuthToken()]).then(e=>{let[t,n]=e;const r={};return n&&(r["uppy-auth-token"]=n),this.companionKeysParams&&(r["uppy-credentials-params"]=btoa(JSON.stringify({params:this.companionKeysParams}))),{...t,...r}})}onReceiveResponse(e){e=super.onReceiveResponse(e);const t=this.uppy.getPlugin(this.pluginId),n=t.getPluginState().authenticated?401!==e.status:e.status<400;return t.setPluginState({authenticated:n}),e}setAuthToken(e){return this.uppy.getPlugin(this.pluginId).storage.setItem(this.tokenKey,e)}getAuthToken(){return this.uppy.getPlugin(this.pluginId).storage.getItem(this.tokenKey)}async ensurePreAuth(){if(this.companionKeysParams&&!this.preAuthToken&&(await this.fetchPreAuthToken(),!this.preAuthToken))throw new Error("Could not load authentication data required for third-party login. Please try again later.")}authUrl(e){void 0===e&&(e={});const t=new URLSearchParams(e);return this.preAuthToken&&t.set("uppyPreAuthToken",this.preAuthToken),`${this.hostname}/${this.id}/connect?${t}`}fileUrl(e){return`${this.hostname}/${this.id}/get/${e}`}async fetchPreAuthToken(){if(this.companionKeysParams)try{const e=await this.post(`${this.id}/preauth/`,{params:this.companionKeysParams});this.preAuthToken=e.token}catch(e){this.uppy.log(`[CompanionClient] unable to fetch preAuthToken ${e}`,"warning")}}list(e){return this.get(`${this.id}/list/${e||""}`)}logout(){return this.get(`${this.id}/logout`).then(e=>Promise.all([e,this.uppy.getPlugin(this.pluginId).storage.removeItem(this.tokenKey)])).then(e=>{let[t]=e;return t})}static initPlugin(t,n,r){if(t.type="acquirer",t.files=[],r&&(t.opts={...r,...n}),n.serverUrl||n.serverPattern)throw new Error("`serverUrl` and `serverPattern` have been renamed to `companionUrl` and `companionAllowedHosts` respectively in the 0.30.5 release. Please consult the docs (for example, https://uppy.io/docs/instagram/ for the Instagram plugin) and use the updated options.`");if(n.companionAllowedHosts){const e=n.companionAllowedHosts;if(!("string"==typeof e||Array.isArray(e)||e instanceof RegExp))throw new TypeError(`${t.id}: the option "companionAllowedHosts" must be one of string, Array, RegExp`);t.opts.companionAllowedHosts=e}else/^(?!https?:\/\/).*$/i.test(n.companionUrl)?t.opts.companionAllowedHosts=`https://${n.companionUrl.replace(/^\/\//,"")}`:t.opts.companionAllowedHosts=new URL(n.companionUrl).origin;t.storage=t.opts.storage||e}},gA}();dA.Provider=t;const n=function(){if(yA)return mA;yA=1;const e=pA();return mA=class extends e{constructor(e,t){super(e,t),this.provider=t.provider,this.id=this.provider,this.name=this.opts.name||this.id.split("-").map(e=>e.charAt(0).toUpperCase()+e.slice(1)).join(" "),this.pluginId=this.opts.pluginId}fileUrl(e){return`${this.hostname}/search/${this.id}/get/${e}`}search(e,t){return this.get(`search/${this.id}/list?q=${encodeURIComponent(e)}${t?`&${t}`:""}`)}},mA}();dA.SearchProvider=n;const r=function(){if(EA)return bA;let e,t;function n(e,t){if(!Object.prototype.hasOwnProperty.call(e,t))throw new TypeError("attempted to use private field on non-instance");return e}EA=1;var r=0;function o(e){return"__private_"+r+++"_"+e}const i=Vw();var a=o("queued"),s=o("emitter"),u=o("isOpen"),l=o("socket"),c=o("handleMessage");return e=Symbol.for("uppy test: getSocket"),t=Symbol.for("uppy test: getQueued"),bA=class{constructor(e){Object.defineProperty(this,a,{writable:!0,value:[]}),Object.defineProperty(this,s,{writable:!0,value:i()}),Object.defineProperty(this,u,{writable:!0,value:!1}),Object.defineProperty(this,l,{writable:!0,value:void 0}),Object.defineProperty(this,c,{writable:!0,value:e=>{try{const t=JSON.parse(e.data);this.emit(t.action,t.payload)}catch(e){console.log(e)}}}),this.opts=e,e&&!1===e.autoOpen||this.open()}get isOpen(){return n(this,u)[u]}[e](){return n(this,l)[l]}[t](){return n(this,a)[a]}open(){n(this,l)[l]=new WebSocket(this.opts.target),n(this,l)[l].onopen=()=>{for(n(this,u)[u]=!0;n(this,a)[a].length>0&&n(this,u)[u];){const e=n(this,a)[a].shift();this.send(e.action,e.payload)}},n(this,l)[l].onclose=()=>{n(this,u)[u]=!1},n(this,l)[l].onmessage=n(this,c)[c]}close(){var e;null==(e=n(this,l)[l])||e.close()}send(e,t){n(this,u)[u]?n(this,l)[l].send(JSON.stringify({action:e,payload:t})):n(this,a)[a].push({action:e,payload:t})}on(e,t){n(this,s)[s].on(e,t)}emit(e,t){n(this,s)[s].emit(e,t)}once(e,t){n(this,s)[s].once(e,t)}},bA}();return dA.Socket=r,dA}var AA,xA,OA,NA,BA,TA,kA,FA,IA,PA,_A,LA,RA,MA,jA,HA,zA,$A={};function UA(){if(AA)return $A;function e(e,t){if(!Object.prototype.hasOwnProperty.call(e,t))throw new TypeError("attempted to use private field on non-instance");return e}AA=1,Object.defineProperty($A,"__esModule",{value:!0}),$A.internalRateLimitedQueue=$A.RateLimitedQueue=void 0;var t=0;function n(e){return"__private_"+t+++"_"+e}var r=n("activeRequests"),o=n("queuedHandlers"),i=n("paused"),a=n("pauseTimer"),s=n("downLimit"),u=n("upperLimit"),l=n("rateLimitingTimer"),c=n("call"),d=n("queueNext"),f=n("next"),p=n("queue"),h=n("dequeue"),g=n("resume"),v=n("increaseLimit");function m(t){e(this,r)[r]+=1;let n,o=!1;try{n=t()}catch(t){throw e(this,r)[r]-=1,t}return{abort:()=>{o||(o=!0,e(this,r)[r]-=1,n(),e(this,d)[d]())},done:()=>{o||(o=!0,e(this,r)[r]-=1,e(this,d)[d]())}}}function y(){queueMicrotask(()=>e(this,f)[f]())}function b(){if(e(this,i)[i]||e(this,r)[r]>=this.limit)return;if(0===e(this,o)[o].length)return;const t=e(this,o)[o].shift(),n=e(this,c)[c](t.fn);t.abort=n.abort,t.done=n.done}function E(t,n){void 0===n&&(n={});const r={fn:t,priority:n.priority||0,abort:()=>{e(this,h)[h](r)},done:()=>{throw new Error("Cannot mark a queued request as done: this indicates a bug")}},i=e(this,o)[o].findIndex(e=>r.priority>e.priority);return-1===i?e(this,o)[o].push(r):e(this,o)[o].splice(i,0,r),r}function C(t){const n=e(this,o)[o].indexOf(t);-1!==n&&e(this,o)[o].splice(n,1)}$A.RateLimitedQueue=class{constructor(t){Object.defineProperty(this,h,{value:C}),Object.defineProperty(this,p,{value:E}),Object.defineProperty(this,f,{value:b}),Object.defineProperty(this,d,{value:y}),Object.defineProperty(this,c,{value:m}),Object.defineProperty(this,r,{writable:!0,value:0}),Object.defineProperty(this,o,{writable:!0,value:[]}),Object.defineProperty(this,i,{writable:!0,value:!1}),Object.defineProperty(this,a,{writable:!0,value:void 0}),Object.defineProperty(this,s,{writable:!0,value:1}),Object.defineProperty(this,u,{writable:!0,value:void 0}),Object.defineProperty(this,l,{writable:!0,value:void 0}),Object.defineProperty(this,g,{writable:!0,value:()=>this.resume()}),Object.defineProperty(this,v,{writable:!0,value:()=>{if(e(this,i)[i])e(this,l)[l]=setTimeout(e(this,v)[v],0);else{e(this,s)[s]=this.limit,this.limit=Math.ceil((e(this,u)[u]+e(this,s)[s])/2);for(let t=e(this,s)[s];t<=this.limit;t++)e(this,d)[d]();e(this,u)[u]-e(this,s)[s]>3?e(this,l)[l]=setTimeout(e(this,v)[v],2e3):e(this,s)[s]=Math.floor(e(this,s)[s]/2)}}}),this.limit="number"!=typeof t||0===t?1/0:t}run(t,n){return!e(this,i)[i]&&e(this,r)[r]<this.limit?e(this,c)[c](t):e(this,p)[p](t,n)}wrapPromiseFunction(e,t){var n=this;return function(){for(var r=arguments.length,o=new Array(r),i=0;i<r;i++)o[i]=arguments[i];let a;const s=new Promise((r,i)=>{a=n.run(()=>{let t,n;try{n=Promise.resolve(e(...o))}catch(e){n=Promise.reject(e)}return n.then(e=>{t?i(t):(a.done(),r(e))},e=>{t?i(t):(a.done(),i(e))}),()=>{t=new Error("Cancelled")}},t)});return s.abort=()=>{a.abort()},s}}resume(){e(this,i)[i]=!1,clearTimeout(e(this,a)[a]);for(let t=0;t<this.limit;t++)e(this,d)[d]()}pause(t){void 0===t&&(t=null),e(this,i)[i]=!0,clearTimeout(e(this,a)[a]),null!=t&&(e(this,a)[a]=setTimeout(e(this,g)[g],t))}rateLimit(t){clearTimeout(e(this,l)[l]),this.pause(t),this.limit>1&&Number.isFinite(this.limit)&&(e(this,u)[u]=this.limit-1,this.limit=e(this,s)[s],e(this,l)[l]=setTimeout(e(this,v)[v],t))}get isPaused(){return e(this,i)[i]}};const D=Symbol("__queue");return $A.internalRateLimitedQueue=D,$A}function VA(){return jA?MA:(jA=1,MA={strings:{timedOut:"Upload stalled for %{seconds} seconds, aborting."}})}var WA=function(){if(zA)return HA;zA=1;var e=aw(),t=SA(),n=UA();const r=ZS(),o=function(){if(OA)return xA;OA=1;const e=wC();return xA=e(function(e,t,n){const{progress:r,bytesUploaded:o,bytesTotal:i}=t;r&&(e.uppy.log(`Upload progress: ${r}`),e.uppy.emit("upload-progress",n,{uploader:e,bytesUploaded:o,bytesTotal:i}))},300,{leading:!0,trailing:!0})}(),i=BA?NA:(BA=1,NA=function(e){const t=/^(?:https?:\/\/|\/\/)?(?:[^@\n]+@)?(?:www\.)?([^\n]+)/i.exec(e)[1];return`${/^http:\/\//i.test(e)?"ws":"wss"}://${t}`}),a=kA?TA:(kA=1,TA=function(e){const t=[],n=[];function r(e){t.push(e)}function o(e){n.push(e)}return Promise.all(e.map(e=>e.then(r,o))).then(()=>({successful:t,failed:n}))}),s=function(){if(IA)return FA;function e(e,t){if(!Object.prototype.hasOwnProperty.call(e,t))throw new TypeError("attempted to use private field on non-instance");return e}IA=1;var t=0;function n(e){return"__private_"+t+++"_"+e}var r=n("emitter"),o=n("events");return FA=class{constructor(t){Object.defineProperty(this,r,{writable:!0,value:void 0}),Object.defineProperty(this,o,{writable:!0,value:[]}),e(this,r)[r]=t}on(t,n){return e(this,o)[o].push([t,n]),e(this,r)[r].on(t,n)}remove(){for(const[t,n]of e(this,o)[o].splice(0))e(this,r)[r].off(t,n)}},FA}(),u=function(){if(_A)return PA;function e(e,t){if(!Object.prototype.hasOwnProperty.call(e,t))throw new TypeError("attempted to use private field on non-instance");return e}_A=1;var t=0;function n(e){return"__private_"+t+++"_"+e}var r=n("aliveTimer"),o=n("isDone"),i=n("onTimedOut"),a=n("timeout");return PA=class{constructor(t,n){Object.defineProperty(this,r,{writable:!0,value:void 0}),Object.defineProperty(this,o,{writable:!0,value:!1}),Object.defineProperty(this,i,{writable:!0,value:void 0}),Object.defineProperty(this,a,{writable:!0,value:void 0}),e(this,a)[a]=t,e(this,i)[i]=n}progress(){e(this,o)[o]||e(this,a)[a]>0&&(clearTimeout(e(this,r)[r]),e(this,r)[r]=setTimeout(e(this,i)[i],e(this,a)[a]))}done(){e(this,o)[o]||(clearTimeout(e(this,r)[r]),e(this,r)[r]=null,e(this,o)[o]=!0)}}}(),l=fA(),c=RA?LA:(RA=1,LA=function(e){return!!e&&(0!==e.readyState&&4!==e.readyState||0===e.status)}),d=VA();function f(e,t){let n=t;return n||(n=new Error("Upload error")),"string"==typeof n&&(n=new Error(n)),n instanceof Error||(n=Object.assign(new Error("Upload error"),{data:n})),c(e)?(n=new l(n,e),n):(n.request=e,n)}function p(e){return e.data.slice(0,e.data.size,e.meta.type)}class h extends r{constructor(e,t){super(e,t),this.type="uploader",this.id=this.opts.id||"XHRUpload",this.title="XHRUpload",this.defaultLocale=d;const r={formData:!0,fieldName:t.bundle?"files[]":"file",method:"post",metaFields:null,responseUrlFieldName:"url",bundle:!1,headers:{},timeout:3e4,limit:5,withCredentials:!1,responseType:"",getResponseData(t){let n={};try{n=JSON.parse(t)}catch(t){e.log(t)}return n},getResponseError(e,t){let n=new Error("Upload error");return c(t)&&(n=new l(n,t)),n},validateStatus:e=>e>=200&&e<300};if(this.opts={...r,...t},this.i18nInit(),this.handleUpload=this.handleUpload.bind(this),n.internalRateLimitedQueue in this.opts?this.requests=this.opts[n.internalRateLimitedQueue]:this.requests=new n.RateLimitedQueue(this.opts.limit),this.opts.bundle&&!this.opts.formData)throw new Error("`opts.formData` must be true when `opts.bundle` is enabled.");this.uploaderEvents=Object.create(null)}getOptions(e){const t=this.uppy.getState().xhrUpload,{headers:n}=this.opts,r={...this.opts,...t||{},...e.xhrUpload||{},headers:{}};return"function"==typeof n?r.headers=n(e):Object.assign(r.headers,this.opts.headers),t&&Object.assign(r.headers,t.headers),e.xhrUpload&&Object.assign(r.headers,e.xhrUpload.headers),r}addMetadata(e,t,n){(Array.isArray(n.metaFields)?n.metaFields:Object.keys(t)).forEach(n=>{e.append(n,t[n])})}createFormDataUpload(e,t){const n=new FormData;this.addMetadata(n,e.meta,t);const r=p(e);return e.name?n.append(t.fieldName,r,e.meta.name):n.append(t.fieldName,r),n}createBundledUpload(e,t){const n=new FormData,{meta:r}=this.uppy.getState();return this.addMetadata(n,r,t),e.forEach(e=>{const t=this.getOptions(e),r=p(e);e.name?n.append(t.fieldName,r,e.name):n.append(t.fieldName,r)}),n}upload(t,n,r){const o=this.getOptions(t);return this.uppy.log(`uploading ${n} of ${r}`),new Promise((n,r)=>{this.uppy.emit("upload-started",t);const i=o.formData?this.createFormDataUpload(t,o):t.data,a=new XMLHttpRequest;let l;this.uploaderEvents[t.id]=new s(this.uppy);const c=new u(o.timeout,()=>{a.abort(),l.done();const e=new Error(this.i18n("timedOut",{seconds:Math.ceil(o.timeout/1e3)}));this.uppy.emit("upload-error",t,e),r(e)}),d=(0,e.nanoid)();a.upload.addEventListener("loadstart",()=>{this.uppy.log(`[XHRUpload] ${d} started`)}),a.upload.addEventListener("progress",e=>{this.uppy.log(`[XHRUpload] ${d} progress: ${e.loaded} / ${e.total}`),c.progress(),e.lengthComputable&&this.uppy.emit("upload-progress",t,{uploader:this,bytesUploaded:e.loaded,bytesTotal:e.total})}),a.addEventListener("load",()=>{if(this.uppy.log(`[XHRUpload] ${d} finished`),c.done(),l.done(),this.uploaderEvents[t.id]&&(this.uploaderEvents[t.id].remove(),this.uploaderEvents[t.id]=null),o.validateStatus(a.status,a.responseText,a)){const e=o.getResponseData(a.responseText,a),r=e[o.responseUrlFieldName],i={status:a.status,body:e,uploadURL:r};return this.uppy.emit("upload-success",t,i),r&&this.uppy.log(`Download ${t.name} from ${r}`),n(t)}const e=o.getResponseData(a.responseText,a),i=f(a,o.getResponseError(a.responseText,a)),s={status:a.status,body:e};return this.uppy.emit("upload-error",t,i,s),r(i)}),a.addEventListener("error",()=>{this.uppy.log(`[XHRUpload] ${d} errored`),c.done(),l.done(),this.uploaderEvents[t.id]&&(this.uploaderEvents[t.id].remove(),this.uploaderEvents[t.id]=null);const e=f(a,o.getResponseError(a.responseText,a));return this.uppy.emit("upload-error",t,e),r(e)}),a.open(o.method.toUpperCase(),o.endpoint,!0),a.withCredentials=o.withCredentials,""!==o.responseType&&(a.responseType=o.responseType),l=this.requests.run(()=>{this.uppy.emit("upload-started",t);const e=this.getOptions(t);return Object.keys(e.headers).forEach(t=>{a.setRequestHeader(t,e.headers[t])}),a.send(i),()=>{c.done(),a.abort()}}),this.onFileRemove(t.id,()=>{l.abort(),r(new Error("File removed"))}),this.onCancelAll(t.id,e=>{let{reason:t}=e;"user"===t&&l.abort(),r(new Error("Upload cancelled"))})})}uploadRemote(e){const n=this.getOptions(e);return new Promise((r,a)=>{this.uppy.emit("upload-started",e);const u={};(Array.isArray(n.metaFields)?n.metaFields:Object.keys(e.meta)).forEach(t=>{u[t]=e.meta[t]});new(e.remote.providerOptions.provider?t.Provider:t.RequestClient)(this.uppy,e.remote.providerOptions).post(e.remote.url,{...e.remote.body,endpoint:n.endpoint,size:e.data.size,fieldname:n.fieldName,metadata:u,httpMethod:n.method,useFormData:n.formData,headers:n.headers}).then(u=>{const{token:l}=u,c=i(e.remote.companionUrl),d=new t.Socket({target:`${c}/api/${l}`,autoOpen:!1});let f;this.uploaderEvents[e.id]=new s(this.uppy),this.onFileRemove(e.id,()=>{d.send("cancel",{}),f.abort(),r(`upload ${e.id} was removed`)}),this.onCancelAll(e.id,function(t){let{reason:n}=void 0===t?{}:t;"user"===n&&(d.send("cancel",{}),f.abort()),r(`upload ${e.id} was canceled`)}),this.onRetry(e.id,()=>{d.send("pause",{}),d.send("resume",{})}),this.onRetryAll(e.id,()=>{d.send("pause",{}),d.send("resume",{})}),d.on("progress",t=>o(this,t,e)),d.on("success",t=>{const o=n.getResponseData(t.response.responseText,t.response),i=o[n.responseUrlFieldName],a={status:t.response.status,body:o,uploadURL:i};return this.uppy.emit("upload-success",e,a),f.done(),this.uploaderEvents[e.id]&&(this.uploaderEvents[e.id].remove(),this.uploaderEvents[e.id]=null),r()}),d.on("error",t=>{const r=t.response,o=r?n.getResponseError(r.responseText,r):Object.assign(new Error(t.error.message),{cause:t.error});this.uppy.emit("upload-error",e,o),f.done(),this.uploaderEvents[e.id]&&(this.uploaderEvents[e.id].remove(),this.uploaderEvents[e.id]=null),a(o)}),f=this.requests.run(()=>(d.open(),e.isPaused&&d.send("pause",{}),()=>d.close()))}).catch(t=>{this.uppy.emit("upload-error",e,t),a(t)})})}uploadBundle(e){return new Promise((t,n)=>{const{endpoint:r}=this.opts,{method:o}=this.opts,i=this.uppy.getState().xhrUpload,a=this.createBundledUpload(e,{...this.opts,...i||{}}),s=new XMLHttpRequest,l=t=>{e.forEach(e=>{this.uppy.emit("upload-error",e,t)})},c=new u(this.opts.timeout,()=>{s.abort();const e=new Error(this.i18n("timedOut",{seconds:Math.ceil(this.opts.timeout/1e3)}));l(e),n(e)});s.upload.addEventListener("loadstart",()=>{this.uppy.log("[XHRUpload] started uploading bundle"),c.progress()}),s.upload.addEventListener("progress",t=>{c.progress(),t.lengthComputable&&e.forEach(e=>{this.uppy.emit("upload-progress",e,{uploader:this,bytesUploaded:t.loaded/t.total*e.size,bytesTotal:e.size})})}),s.addEventListener("load",r=>{if(c.done(),this.opts.validateStatus(r.target.status,s.responseText,s)){const n=this.opts.getResponseData(s.responseText,s),o={status:r.target.status,body:n};return e.forEach(e=>{this.uppy.emit("upload-success",e,o)}),t()}const o=this.opts.getResponseError(s.responseText,s)||new Error("Upload error");return o.request=s,l(o),n(o)}),s.addEventListener("error",()=>{c.done();const e=this.opts.getResponseError(s.responseText,s)||new Error("Upload error");return l(e),n(e)}),this.uppy.on("cancel-all",function(e){let{reason:t}=void 0===e?{}:e;"user"===t&&(c.done(),s.abort())}),s.open(o.toUpperCase(),r,!0),s.withCredentials=this.opts.withCredentials,""!==this.opts.responseType&&(s.responseType=this.opts.responseType),Object.keys(this.opts.headers).forEach(e=>{s.setRequestHeader(e,this.opts.headers[e])}),s.send(a),e.forEach(e=>{this.uppy.emit("upload-started",e)})})}uploadFiles(e){const t=e.map((t,n)=>{const r=parseInt(n,10)+1,o=e.length;return t.error?Promise.reject(new Error(t.error)):t.isRemote?this.uploadRemote(t,r,o):this.upload(t,r,o)});return a(t)}onFileRemove(e,t){this.uploaderEvents[e].on("file-removed",n=>{e===n.id&&t(n.id)})}onRetry(e,t){this.uploaderEvents[e].on("upload-retry",n=>{e===n&&t()})}onRetryAll(e,t){this.uploaderEvents[e].on("retry-all",()=>{this.uppy.getFile(e)&&t()})}onCancelAll(e,t){var n=this;this.uploaderEvents[e].on("cancel-all",function(){n.uppy.getFile(e)&&t(...arguments)})}handleUpload(e){if(0===e.length)return this.uppy.log("[XHRUpload] No files to upload!"),Promise.resolve();0!==this.opts.limit||this.opts[n.internalRateLimitedQueue]||this.uppy.log("[XHRUpload] When uploading multiple files at once, consider setting the `limit` option (to `10` for example), to limit the number of concurrent uploads, which helps prevent memory and network issues: https://uppy.io/docs/xhr-upload/#limit-0","warning"),this.uppy.log("[XHRUpload] Uploading...");const t=e.map(e=>this.uppy.getFile(e));if(this.opts.bundle){if(t.some(e=>e.isRemote))throw new Error("Can’t upload remote files when the `bundle: true` option is set");if("function"==typeof this.opts.headers)throw new TypeError("`headers` may not be a function when the `bundle: true` option is set");return this.uploadBundle(t)}return this.uploadFiles(t).then(()=>null)}install(){if(this.opts.bundle){const{capabilities:e}=this.uppy.getState();this.uppy.setState({capabilities:{...e,individualCancellation:!1}})}this.uppy.addUploader(this.handleUpload)}uninstall(){if(this.opts.bundle){const{capabilities:e}=this.uppy.getState();this.uppy.setState({capabilities:{...e,individualCancellation:!0}})}this.uppy.removeUploader(this.handleUpload)}}return h.VERSION="2.1.3",HA=h}(),GA=b(WA);function qA(e){var t=e.server,n=void 0===t?"":t,r=e.fieldName,o=void 0===r?"":r,i=e.maxFileSize,a=void 0===i?10485760:i,s=e.maxNumberOfFiles,u=void 0===s?100:s,l=e.meta,c=void 0===l?{}:l,d=e.metaWithUrl,f=void 0!==d&&d,p=e.headers,h=void 0===p?{}:p,g=e.withCredentials,v=void 0!==g&&g,m=e.timeout,y=void 0===m?1e4:m,b=e.onBeforeUpload,E=void 0===b?function(e){return e}:b,C=e.onSuccess,D=void 0===C?function(e,t){}:C,w=e.onError,S=void 0===w?function(e,t,n){console.error("".concat(e.name," upload error"),t,n)}:w,A=e.onProgress,x=void 0===A?function(e){}:A;if(!n)throw new Error("Cannot get upload server address\n没有配置上传地址");if(!o)throw new Error("Cannot get fieldName\n没有配置 fieldName");var O=n;f&&(O=function(e,t){var n=ev(e.split("#"),2),r=n[0],o=n[1],i=[];cv(t,function(e,t){i.push("".concat(t,"=").concat(e))});var a=i.join("&");return r=r.indexOf("?")>0?"".concat(r,"&").concat(a):"".concat(r,"?").concat(a),o?"".concat(r,"#").concat(o):r}(O,c));var N=new cA(Yg({onBeforeUpload:E,restrictions:{maxFileSize:a,maxNumberOfFiles:u},meta:c},e.uppyConfig)).use(GA,Yg({endpoint:O,headers:h,formData:!0,fieldName:o,bundle:!0,withCredentials:v,timeout:y},e.xhrConfig));return N.on("complete",function(e){var t=e.successful[0],n=t.response,r=(null!=n?n:{}).body,o=void 0===r?{}:r;try{D(t,o)}catch(e){console.error("wangEditor upload file - onSuccess error",e)}}),N.on("progress",function(e){e<1||x(e)}),N.on("upload-error",function(e,t,n){try{S(e,t,n)}catch(e){console.error("wangEditor upload file - onError error",e)}}),N.on("restriction-failed",function(e,t){try{S(e,t)}catch(e){console.error("wangEditor upload file - onError error",e)}}),N}KE("en",{editor:{more:"More",justify:"Justify",indent:"Indent",image:"Image",video:"Video"}}),KE("zh-CN",{editor:{more:"更多",justify:"对齐",indent:"缩进",image:"图片",video:"视频"}});var KA,YA,XA,ZA,JA,QA,ex,tx,nx,rx,ox,ix,ax,sx,ux,lx={};function cx(){if(YA)return KA;YA=1;var e=S();return KA=Array.isArray||function(t){return"Array"===e(t)}}function dx(){if(ZA)return XA;ZA=1;var e=w(),t=C(),n=me(),r=Tr(),o=zt(),i=An(),a=function(){},s=o("Reflect","construct"),u=/^\s*(?:class|function)\b/,l=e(u.exec),c=!u.test(a),d=function(e){if(!n(e))return!1;try{return s(a,[],e),!0}catch(e){return!1}},f=function(e){if(!n(e))return!1;switch(r(e)){case"AsyncFunction":case"GeneratorFunction":case"AsyncGeneratorFunction":return!1}try{return c||!!l(u,i(e))}catch(e){return!0}};return f.sham=!0,XA=!s||t(function(){var e;return d(d.call)||!d(Object)||!d(function(){e=!0})||e})?f:d}function fx(){if(QA)return JA;QA=1;var e=cx(),t=dx(),n=ye(),r=ve()("species"),o=Array;return JA=function(i){var a;return e(i)&&(a=i.constructor,(t(a)&&(a===o||e(a.prototype))||n(a)&&null===(a=a[r]))&&(a=void 0)),void 0===a?o:a},JA}function px(){if(tx)return ex;tx=1;var e=fx();return ex=function(t,n){return new(e(t))(0===n?0:n)}}function hx(){if(ix)return ox;ix=1;var e=C();return ox=function(t,n){var r=[][t];return!!r&&e(function(){r.call(null,n||function(){return 1},1)})}}function gx(){if(sx)return ax;sx=1;var e=function(){if(rx)return nx;rx=1;var e=Go(),t=w(),n=A(),r=ce(),o=Jt(),i=px(),a=t([].push),s=function(t){var s=1===t,u=2===t,l=3===t,c=4===t,d=6===t,f=7===t,p=5===t||d;return function(h,g,v,m){for(var y,b,E=r(h),C=n(E),D=o(C),w=e(g,v),S=0,A=m||i,x=s?A(h,D):u||f?A(h,0):void 0;D>S;S++)if((p||S in C)&&(b=w(y=C[S],S,E),t))if(s)x[S]=b;else if(b)switch(t){case 3:return!0;case 5:return y;case 6:return S;case 2:a(x,y)}else switch(t){case 4:return!1;case 7:a(x,y)}return d?-1:l||c?c:x}};return nx={forEach:s(0),map:s(1),filter:s(2),some:s(3),every:s(4),find:s(5),findIndex:s(6),filterReject:s(7)}}().forEach,t=hx()("forEach");return ax=t?[].forEach:function(t){return e(this,t,arguments.length>1?arguments[1]:void 0)},ax}!function(){if(ux)return lx;ux=1;var e=B(),t=ci(),n=di(),r=gx(),o=ln(),i=function(e){if(e&&e.forEach!==r)try{o(e,"forEach",r)}catch(t){e.forEach=r}};for(var a in t)t[a]&&i(e[a]&&e[a].prototype);i(n)}();KE("en",{common:{ok:"OK",delete:"Delete",enter:"Enter"},blockQuote:{title:"Quote"},codeBlock:{title:"Code block"},color:{color:"Font color",bgColor:"Back color",default:"Default color",clear:"Clear back color"},divider:{title:"Divider"},emotion:{title:"Emotion"},fontSize:{title:"Font size",default:"Default"},fontFamily:{title:"Font family",default:"Default"},fullScreen:{title:"Full screen",cancelTitle:"Cancel full screen"},header:{title:"Header",text:"Text"},image:{netImage:"Net image",delete:"Delete image",edit:"Edit image",editSize:"Edit size",viewLink:"View link",src:"Image src",desc:"Description",link:"Image link",ok:"Ok",width:"Width",height:"Height"},indent:{decrease:"Decrease",increase:"Increase"},justify:{left:"Left",right:"Right",center:"Center",justify:"Justify"},lineHeight:{title:"Line height",default:"Default"},link:{insert:"Insert link",text:"Link text",url:"Link source",unLink:"Unlink",edit:"Edit link",view:"View link"},textStyle:{bold:"Bold",clear:"Clear styles",code:"Inline code",italic:"Italic",sub:"Sub",sup:"Sup",through:"Through",underline:"Underline"},undo:{undo:"undo",redo:"Redo"},todo:{todo:"Todo"},formatPainter:{title:"Format Painter"}}),KE("zh-CN",{common:{ok:"确定",delete:"删除",enter:"回车"},blockQuote:{title:"引用"},codeBlock:{title:"代码块"},color:{color:"文字颜色",bgColor:"背景色",default:"默认颜色",clear:"清除背景色"},divider:{title:"分割线"},emotion:{title:"表情"},fontSize:{title:"字号",default:"默认字号"},fontFamily:{title:"字体",default:"默认字体"},fullScreen:{title:"全屏",cancelTitle:"取消全屏"},header:{title:"标题",text:"正文"},image:{netImage:"网络图片",delete:"删除图片",edit:"编辑图片",editSize:"修改尺寸",viewLink:"查看链接",src:"图片地址",desc:"图片描述",link:"图片链接",ok:"确定",width:"宽度",height:"高度"},indent:{decrease:"减少缩进",increase:"增加缩进"},justify:{left:"左对齐",right:"右对齐",center:"居中对齐",justify:"两端对齐"},lineHeight:{title:"行高",default:"默认行高"},link:{insert:"插入链接",text:"链接文本",url:"链接地址",unLink:"取消链接",edit:"修改链接",view:"查看链接"},textStyle:{bold:"粗体",clear:"清除格式",code:"行内代码",italic:"斜体",sub:"下标",sup:"上标",through:"删除线",underline:"下划线"},undo:{undo:"撤销",redo:"重做"},todo:{todo:"待办"},formatPainter:{title:"格式刷"}});var vx={type:"blockquote",elemToHtml:function(e,t){return"<blockquote>".concat(t,"</blockquote>")}},mx='<svg viewBox="0 0 1024 1024"><path d="M864 0a160 160 0 0 1 128 256l-64 64-224-224 64-64c26.752-20.096 59.968-32 96-32zM64 736l-64 288 288-64 592-592-224-224L64 736z m651.584-372.416l-448 448-55.168-55.168 448-448 55.168 55.168z"></path></svg>',yx='<svg viewBox="0 0 1024 1024"><path d="M924.402464 1023.068211H0.679665V99.345412h461.861399v98.909208H99.596867v725.896389h725.896389V561.206811h98.909208z" p-id="10909"></path><path d="M930.805104 22.977336l69.965436 69.965436-453.492405 453.492404-69.965435-69.901489z" p-id="10910"></path><path d="M1022.464381 304.030081h-98.917201V99.345412H709.230573V0.428211h313.233808z"></path></svg>',bx='<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>',Ex=function(){function e(){this.title=JE("blockQuote.title"),this.iconSvg='<svg viewBox="0 0 1024 1024"><path d="M894.6 907.1H605.4c-32.6 0-59-26.4-59-59V608.2l-4-14.9c0-315.9 125.5-485.1 376.5-507.5v59.8C752.7 180.4 711.3 315.8 711.3 442.4v41.2l31.5 12.3h151.8c32.6 0 59 26.4 59 59v293.2c0 32.5-26.4 59-59 59z m-472 0H133.4c-32.6 0-59-26.4-59-59V608.2l-4-14.9c0-315.9 125.5-485.1 376.5-507.5v59.8C280.7 180.4 239.3 315.8 239.3 442.4v41.2l31.5 12.3h151.8c32.6 0 59 26.4 59 59v293.2c0 32.5-26.4 59-59 59z"></path></svg>',this.tag="button"}return e.prototype.getValue=function(e){return""},e.prototype.isActive=function(e){return!!Py.getSelectedNodeByType(e,"blockquote")},e.prototype.isDisabled=function(e){if(null==e.selection)return!0;var t=ev(Kh.nodes(e,{match:function(e){var t=Py.getNodeType(e);return"paragraph"===t||"blockquote"===t},universal:!0,mode:"highest"}),1);return!t[0]},e.prototype.exec=function(e,t){if(!this.isDisabled(e)){var n=this.isActive(e)?"paragraph":"blockquote";jg.setNodes(e,{type:n},{mode:"highest"})}},e}(),Cx={key:"blockquote",factory:function(){return new Ex}};function Dx(e){return 0===im("<div>".concat(e,"</div>")).children().filter(function(e){return"BR"!==e.tagName}).length}function wx(e){return 0===e.length?"":e[0].outerHTML}function Sx(e){return e.length?e[0].tagName.toLowerCase():""}function Ax(e,t){for(var n="",r=(e.attr("style")||"").split(";"),o=r.length,i=0;i<o;i+=1){var a=r[i];if(a){var s=a.split(":");s[0].trim()===t&&(n=s[1].trim())}}return n}Cm&&(im.fn.css=Cm),Om&&(im.fn.append=Om),Nm&&(im.fn.prepend=Nm),am&&(im.fn.addClass=am),sm&&(im.fn.removeClass=sm),um&&(im.fn.hasClass=um),hm&&(im.fn.on=hm),gm&&(im.fn.off=gm),Mm&&(im.fn.focus=Mm),lm&&(im.fn.attr=lm),cm&&(im.fn.removeAttr=cm),bm&&(im.fn.hide=bm),Em&&(im.fn.show=Em),Tm&&(im.fn.parents=Tm),fm&&(im.fn.dataset=fm),pm&&(im.fn.val=pm),Am&&(im.fn.text=Am),Sm&&(im.fn.html=Sm),Fm&&(im.fn.children=Fm),Im&&(im.fn.remove=Im),km&&(im.fn.find=km),vm&&(im.fn.width=vm),mm&&(im.fn.height=mm),wm&&(im.fn.filter=wm),Pm&&(im.fn.empty=Pm);var xx={selector:"blockquote:not([data-w-e-type])",parseElemHtml:function(e,t,n){var r=im(e);return 0===(t=t.filter(function(e){return!!Cg.isText(e)||!!n.isInline(e)})).length&&(t=[{text:r.text().replace(/\s+/gm," ")}]),{type:"blockquote",children:t}}};function Ox(e){e.deleteBackward("character");jg.insertNodes(e,{type:"paragraph",children:[{text:""}]},{mode:"highest"})}var Nx={type:"blockquote",renderElem:function(e,t,n){return BD("blockquote",null,t)}},Bx={renderElems:[Nx],elemsToHtml:[vx],parseElemsHtml:[xx],menus:[Cx],editorPlugin:function(e){var t=e.insertBreak,n=e.insertText,r=e;return r.insertBreak=function(){var o=r.selection;if(null==o)return t();var i=ev(Kh.nodes(e,{match:function(e){return Py.checkNodeType(e,"blockquote")},universal:!0}),1),a=i[0];if(!a)return t();var s=a[0];if(Py.getParentNode(e,s)){var u=Py.findPath(e,s),l=Kh.end(e,u);if(ug.equals(l,o.focus)){var c=eg.string(s);if(c&&"\n"===c.slice(-1))return void Ox(r)}n("\n")}else Ox(r)},r}};var Tx={type:"code",elemToHtml:function(e,t){return"<code>".concat(t,"</code>")}};var kx={type:"pre",elemToHtml:function(e,t){return"<pre>".concat(t,"</pre>")}},Fx=function(){function e(){this.title=JE("codeBlock.title"),this.iconSvg='<svg viewBox="0 0 1280 1024"><path d="M832 736l96 96 320-320L928 192l-96 96 224 224zM448 288l-96-96L32 512l320 320 96-96-224-224zM701.312 150.528l69.472 18.944-192 704.032-69.472-18.944 192-704.032z"></path></svg>',this.tag="button"}return e.prototype.getSelectCodeElem=function(e){var t=Py.getSelectedNodeByType(e,"code");if(null==t)return null;var n=Py.getParentNode(e,t);return null==n||"pre"!==Py.getNodeType(n)?null:t},e.prototype.getValue=function(e){var t=this.getSelectCodeElem(e);if(null==t){var n=e.getMenuConfig("codeSelectLang").codeLangs,r=(void 0===n?[]:n).find(function(e){return e.selected});return(null==r?void 0:r.value)||""}return t.language||""},e.prototype.isActive=function(e){return!!this.getSelectCodeElem(e)},e.prototype.isDisabled=function(e){if(null==e.selection)return!0;var t=Py.getSelectedElems(e);return!!t.some(function(t){return e.isVoid(t)})||!t.some(function(e){var t=Py.getNodeType(e);return"pre"===t||"paragraph"===t})},e.prototype.exec=function(e,t){this.isActive(e)?this.changeToPlainText(e):this.changeToCodeBlock(e,t.toString())},e.prototype.changeToPlainText=function(e){var t=this.getSelectCodeElem(e);if(null!=t){var n=eg.string(t);jg.removeNodes(e,{mode:"highest"});var r=n.split("\n").map(function(e){return{type:"paragraph",children:[{text:e}]}});jg.insertNodes(e,r,{mode:"highest"})}},e.prototype.changeToCodeBlock=function(e,t){var n,r,o=[],i=Kh.nodes(e,{match:function(t){return e.children.includes(t)},universal:!0});try{for(var a=Qg(i),s=a.next();!s.done;s=a.next()){var u=ev(s.value,1)[0];u&&o.push(eg.string(u))}}catch(e){n={error:e}}finally{try{s&&!s.done&&(r=a.return)&&r.call(a)}finally{if(n)throw n.error}}jg.removeNodes(e,{mode:"highest"});var l={type:"pre",children:[{type:"code",language:t,children:[{text:o.join("\n")}]}]};jg.insertNodes(e,l,{mode:"highest"})},e}();var Ix={selector:"pre:not([data-w-e-type])",parseElemHtml:function(e,t,n){var r=im(e);return 0===(t=t.filter(function(e){return"code"===Py.getNodeType(e)})).length&&(t=[{type:"code",language:"",children:[{text:r[0].textContent||""}]}]),{type:"pre",children:t.filter(function(e){return"code"===Py.getNodeType(e)})}}};var Px={type:"pre",renderElem:function(e,t,n){return BD("pre",null,t)}},_x={type:"code",renderElem:function(e,t,n){return BD("code",null,t)}},Lx={menus:[{key:"codeBlock",factory:function(){return new Fx}}],editorPlugin:function(e){var t=e.insertBreak,n=e.normalizeNode,r=e.insertData,o=e.handleTab,i=e;return i.insertBreak=function(){var e=Py.getSelectedNodeByType(i,"code");if(null!=e){var n=function(e,t){var n=t.selection;if(null==n)return"";var r=eg.string(e),o=n.anchor.offset,i=r.slice(0,o).split("\n"),a=i.length;return 0===a?"":i[a-1]}(e,i);if(n){var r=n.match(/^\s+/);if(null!=r&&null!=r[0]){var o=r[0];return void i.insertText("\n".concat(o))}}i.insertText("\n")}else t()},e.handleTab=function(){var t=e.selection;if(t){var n=Py.getSelectedNodeByType(e,"code");if(n&&!fg.isCollapsed(t)){var r=ev([t.anchor,t.focus].sort(function(e,t){return e.offset-t.offset}),2),i=r[0],a=r[1],s=n.children[0].text,u=s.split("\n"),l=s.slice(0,i.offset).split("\n").length-1,c=s.slice(0,a.offset).split("\n").length-1,d=u.map(function(e,t){return t>=l&&t<=c?" ".concat(e):e}),f=d.join("\n"),p={anchor:{path:i.path,offset:i.offset+2},focus:{path:a.path,offset:a.offset+2}};jg.insertText(e,f,{at:{anchor:{path:i.path,offset:0},focus:{path:a.path,offset:s.length}}}),jg.select(e,p)}else o()}},i.normalizeNode=function(e){var t=ev(e,2),r=t[0],o=t[1],a=Py.getNodeType(r);("code"===a&&o.length<=1&&jg.setNodes(i,{type:"paragraph"},{at:o}),"pre"===a)&&(Py.isLastNode(i,r)&&jg.insertNodes(i,Py.genEmptyParagraph(),{at:[o[0]+1]}),"code"!==Py.getNodeType(r.children[0])&&(jg.unwrapNodes(i),jg.setNodes(i,{type:"paragraph"},{mode:"highest"})));return n([r,o])},i.insertData=function(e){if(null!=Py.getSelectedNodeByType(i,"code")){var t=e.getData("text/plain");Kh.insertText(i,t)}else r(e)},i},renderElems:[Px,_x],elemsToHtml:[Tx,kx],preParseHtml:[{selector:"pre>code",preParseHtml:function(e){var t=im(e);if("code"!==Sx(t))return e;var n=t.find("xmp");if(0===n.length)return e;var r=n.text();return n.remove(),t.text(r),t[0]}}],parseElemsHtml:[{selector:"pre:not([data-w-e-type])>code",parseElemHtml:function(e,t,n){return{type:"code",language:"",children:[{text:im(e)[0].textContent||""}]}}},Ix]},Rx=function(){function e(){this.tag="button",this.showDropPanel=!0,this.$content=null}return e.prototype.exec=function(e,t){},e.prototype.getValue=function(e){var t=this.mark,n=Kh.marks(e);return n&&n[t]?n[t]:""},e.prototype.isActive=function(e){return!!this.getValue(e)},e.prototype.isDisabled=function(e){if(null==e.selection)return!0;var t=ev(Kh.nodes(e,{match:function(t){return"pre"===Py.getNodeType(t)||!!Kh.isVoid(e,t)},universal:!0}),1);return!!t[0]},e.prototype.getPanelContentElem=function(e){var t=this.mark;if(null==this.$content){var n=im('<ul class="w-e-panel-content-color"></ul>');n.on("click","li",function(n){var r=n.target;if(null!=r&&(n.preventDefault(),null!=e.selection)){var o=im(r).attr("data-value");"0"===o?Kh.removeMark(e,t):Kh.addMark(e,t,o)}}),this.$content=n}var r=this.$content;if(null==r)return document.createElement("ul");r.empty();var o=this.getValue(e),i=e.getMenuConfig(t).colors;(void 0===i?[]:i).forEach(function(e){var t=im('<div class="color-block" data-value="'.concat(e,'"></div>'));t.css("background-color",e);var n=im('<li data-value="'.concat(e,'"></li>'));o===e&&n.addClass("active"),n.append(t),r.append(n)});var a="";"color"===t&&(a=JE("color.default")),"bgColor"===t&&(a=JE("color.clear"));var s=im('\n <li data-value="0" class="clear">\n '.concat('<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>',"\n ").concat(a,"\n </li>\n "));return r.prepend(s),r[0]},e}(),Mx=function(e){function t(){var t=e.apply(this,tv([],ev(arguments),!1))||this;return t.title=JE("color.bgColor"),t.iconSvg='<svg viewBox="0 0 1024 1024"><path d="M510.030769 315.076923l84.676923 196.923077h-177.230769l76.8-196.923077h15.753846zM945.230769 157.538462v708.923076c0 43.323077-35.446154 78.769231-78.769231 78.769231H157.538462c-43.323077 0-78.769231-35.446154-78.769231-78.769231V157.538462c0-43.323077 35.446154-78.769231 78.769231-78.769231h708.923076c43.323077 0 78.769231 35.446154 78.769231 78.769231z m-108.307692 643.938461L600.615385 216.615385c-5.907692-11.815385-15.753846-19.692308-29.538462-19.692308h-139.815385c-11.815385 0-23.630769 7.876923-27.56923 19.692308l-216.615385 584.861538c-3.938462 11.815385 3.938462 25.6 17.723077 25.6h80.738462c11.815385 0 23.630769-9.846154 27.56923-21.661538l63.015385-175.261539h263.876923l68.923077 175.261539c3.938462 11.815385 15.753846 21.661538 27.569231 21.661538h80.738461c13.784615 0 23.630769-13.784615 19.692308-25.6z"></path></svg>',t.mark="bgColor",t}return Kg(t,e),t}(Rx),jx=function(e){function t(){var t=e.apply(this,tv([],ev(arguments),!1))||this;return t.title=JE("color.color"),t.iconSvg='<svg viewBox="0 0 1024 1024"><path d="M64 864h896v96H64zM360.58 576h302.85l81.53 224h102.16L579.24 64H444.77L176.89 800h102.16l81.53-224zM512 159.96L628.49 480H395.52L512 159.96z"></path></svg>',t.mark="color",t}return Kg(t,e),t}(Rx),Hx=["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)"];var zx={selector:"font",preParseHtml:function(e){var t=im(e);if("font"!==Sx(t))return e;var n=t.attr("color")||"";return n&&(t.removeAttr("color"),t.css("color",n)),t[0]}};function $x(e,t){null==e.data&&(e.data={});var n=e.data;null==n.style&&(n.style={}),Object.assign(n.style,t)}var Ux={renderStyle:function(e,t){var n=e,r=n.color,o=n.bgColor,i=t;return r&&$x(i,{color:r}),o&&$x(i,{backgroundColor:o}),i},styleToHtml:function(e,t){if(!Cg.isText(e))return t;var n,r=e,o=r.color,i=r.bgColor;return o||i?((Dx(t)||"span"!==Sx(n=im(t)))&&(n=im("<span>".concat(t,"</span>"))),o&&n.css("color",o),i&&n.css("background-color",i),wx(n)):t},preParseHtml:[zx],parseStyleHtml:function(e,t,n){var r=im(e);if(!Cg.isText(t))return t;var o=t,i=Ax(r,"color");i&&(o.color=i);var a=Ax(r,"background-color");return a||(a=Ax(r,"background")),a&&(o.bgColor=a),o},menus:[{key:"color",factory:function(){return new jx},config:{colors:Hx}},{key:"bgColor",factory:function(){return new Mx},config:{colors:Hx}}]},Vx=function(){function e(){this.title=JE("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 e.prototype.getValue=function(e){return""},e.prototype.isActive=function(e){return!1},e.prototype.isDisabled=function(e){var t=e.selection;return null==t||!!fg.isExpanded(t)},e.prototype.exec=function(e,t){var n=e.selection;if(null!=n){var r=[n.anchor.path[0]];jg.insertNodes(e,{type:"paragraph",children:[{text:""}]},{at:r}),e.select(Kh.start(e,r))}},e}(),Wx={menus:[{key:"enter",factory:function(){return new Vx}}]};var Gx={type:"divider",elemToHtml:function(e,t){return"<hr/>"}},qx=function(){function e(){this.title=JE("divider.title"),this.iconSvg='<svg viewBox="0 0 1092 1024"><path d="M0 51.2m51.2 0l989.866667 0q51.2 0 51.2 51.2l0 0q0 51.2-51.2 51.2l-989.866667 0q-51.2 0-51.2-51.2l0 0q0-51.2 51.2-51.2Z"></path><path d="M0 460.8m51.2 0l170.666667 0q51.2 0 51.2 51.2l0 0q0 51.2-51.2 51.2l-170.666667 0q-51.2 0-51.2-51.2l0 0q0-51.2 51.2-51.2Z"></path><path d="M819.2 460.8m51.2 0l170.666667 0q51.2 0 51.2 51.2l0 0q0 51.2-51.2 51.2l-170.666667 0q-51.2 0-51.2-51.2l0 0q0-51.2 51.2-51.2Z"></path><path d="M409.6 460.8m51.2 0l170.666667 0q51.2 0 51.2 51.2l0 0q0 51.2-51.2 51.2l-170.666667 0q-51.2 0-51.2-51.2l0 0q0-51.2 51.2-51.2Z"></path><path d="M0 870.4m51.2 0l989.866667 0q51.2 0 51.2 51.2l0 0q0 51.2-51.2 51.2l-989.866667 0q-51.2 0-51.2-51.2l0 0q0-51.2 51.2-51.2Z"></path></svg>',this.tag="button"}return e.prototype.getValue=function(e){return""},e.prototype.isActive=function(e){return!1},e.prototype.isDisabled=function(e){return null==e.selection||!!Py.getSelectedElems(e).some(function(t){if(e.isVoid(t))return!0;var n=Py.getNodeType(t);return"table"===n||"pre"===n})},e.prototype.exec=function(e,t){Py.isSelectedEmptyParagraph(e)&&jg.removeNodes(e,{mode:"highest"}),jg.insertNodes(e,{type:"divider",children:[{text:""}]},{mode:"highest"})},e}();var Kx={renderElems:[{type:"divider",renderElem:function(e,t,n){return lD("div",{props:{contentEditable:!1,className:"w-e-textarea-divider"},dataset:{selected:Py.isNodeSelected(n,e)?"true":""},style:{},on:{mousedown:function(e){return e.preventDefault()}}},[lD("hr")])}}],elemsToHtml:[Gx],parseElemsHtml:[{selector:"hr:not([data-w-e-type])",parseElemHtml:function(e,t,n){return{type:"divider",children:[{text:""}]}}}],menus:[{key:"divider",factory:function(){return new qx}}],editorPlugin:function(e){var t=e.isVoid,n=e.normalizeNode,r=e;return r.isVoid=function(e){return"divider"===e.type||t(e)},r.normalizeNode=function(e){var t=ev(e,2),o=t[0],i=t[1];if("divider"!==Py.getNodeType(o))return n([o,i]);Py.isLastNode(r,o)&&jg.insertNodes(r,Py.genEmptyParagraph(),{at:[i[0]+1]})},r}};var Yx=function(){function e(){this.title=JE("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 e.prototype.exec=function(e,t){},e.prototype.getValue=function(e){return""},e.prototype.isActive=function(e){return!1},e.prototype.isDisabled=function(e){if(null==e.selection)return!0;var t=ev(Kh.nodes(e,{match:function(t){return"pre"===Py.getNodeType(t)||!!Kh.isVoid(e,t)},universal:!0}),1);return!!t[0]},e.prototype.getPanelContentElem=function(e){if(null==this.$content){var t=im('<ul class="w-e-panel-content-emotion"></ul>');t.on("click","li",function(t){var n=t.target;if(null!=n){t.preventDefault();var r=im(n).text();e.insertText(r)}}),this.$content=t}var n=this.$content;if(null==n)return document.createElement("ul");n.empty();var r=e.getMenuConfig("emotion").emotions;return(void 0===r?[]:r).forEach(function(e){var t=im("<li>".concat(e,"</li>"));n.append(t)}),n[0]},e}(),Xx={menus:[{key:"emotion",factory:function(){return new Yx},config:{emotions:"😀 😃 😄 😁 😆 😅 😂 🤣 😊 😇 🙂 🙃 😉 😌 😍 😘 😗 😙 😚 😋 😛 😝 😜 🤓 😎 😏 😒 😞 😔 😟 😕 🙁 😣 😖 😫 😩 😢 😭 😤 😠 😡 😳 😱 😨 🤗 🤔 😶 😑 😬 🙄 😯 😴 😷 🤑 😈 🤡 💩 👻 💀 👀 👣 👐 🙌 👏 🤝 👍 👎 👊 ✊ 🤛 🤜 🤞 ✌️ 🤘 👌 👈 👉 👆 👇 ☝️ ✋ 🤚 🖐 🖖 👋 🤙 💪 🖕 ✍️ 🙏".split(" ")}}]};var Zx=function(){function e(){this.tag="select",this.width=80}return e.prototype.isActive=function(e){return!1},e.prototype.getValue=function(e){var t=this.mark,n=Kh.marks(e);return n&&n[t]?n[t]:""},e.prototype.isDisabled=function(e){if(null==e.selection)return!0;var t=ev(Kh.nodes(e,{match:function(t){return"pre"===Py.getNodeType(t)||!!Kh.isVoid(e,t)},universal:!0}),1);return!!t[0]},e.prototype.exec=function(e,t){var n=this.mark;t?e.addMark(n,t):e.removeMark(n)},e}(),Jx=function(e){function t(){var t=e.apply(this,tv([],ev(arguments),!1))||this;return t.title=JE("fontFamily.title"),t.iconSvg='<svg viewBox="0 0 1024 1024"><path d="M956.788364 152.110545h-24.110546l23.924364 9.029819 0.186182 121.018181h-65.070546l-86.574545-130.048H566.551273v650.14691l130.048 64.977454v65.163636h-390.050909v-65.163636l129.954909-64.977454V152.110545H198.283636L111.429818 282.065455H46.545455V69.259636C46.545455 33.792 82.664727 22.062545 98.955636 22.062545h812.683637c23.738182 0 45.056 15.173818 45.056 41.053091V169.425455v-17.221819z"></path></svg>',t.mark="fontFamily",t.selectPanelWidth=150,t}return Kg(t,e),t.prototype.getOptions=function(e){var t=[],n=e.getMenuConfig(this.mark).fontFamilyList,r=void 0===n?[]:n;t.push({text:JE("fontFamily.default"),value:""}),r.forEach(function(e){if("string"==typeof e)t.push({text:e,value:e,styleForRenderMenuList:{"font-family":e}});else if("object"==typeof e){var n=e.name,r=e.value;t.push({text:n,value:r,styleForRenderMenuList:{"font-family":r}})}});var o=this.getValue(e),i=!1;return t.forEach(function(e){e.value===o?(i=!0,e.selected=!0):e.selected=void 0}),i||"string"!=typeof o||t.push({text:o,value:o,selected:!0}),t},t}(Zx),Qx=function(e){function t(){var t=e.apply(this,tv([],ev(arguments),!1))||this;return t.title=JE("fontSize.title"),t.iconSvg='<svg viewBox="0 0 1024 1024"><path d="M64 512h384v128h-128V1024h-128V640h-128z m896-256H708.2496v768h-136.4992V256H320V128h640z"></path></svg>',t.mark="fontSize",t}return Kg(t,e),t.prototype.getOptions=function(e){var t=[],n=e.getMenuConfig(this.mark).fontSizeList,r=void 0===n?[]:n;t.push({text:JE("fontSize.default"),value:""}),r.forEach(function(e){if("string"==typeof e)t.push({text:e,value:e});else if("object"==typeof e){var n=e.name,r=e.value;t.push({text:n,value:r})}});var o=this.getValue(e),i=!1;return t.forEach(function(e){e.value===o?(i=!0,e.selected=!0):e.selected=void 0}),i||"string"!=typeof o||t.push({text:o,value:o,selected:!0}),t},t}(Zx);var eO={1:"12px",2:"14px",3:"16px",4:"19px",5:"24px",6:"32px",7:"48px"};var tO={renderStyle:function(e,t){var n=e,r=n.fontSize,o=n.fontFamily,i=t;return r&&$x(i,{fontSize:r}),o&&$x(i,{fontFamily:o}),i},styleToHtml:function(e,t){if(!Cg.isText(e))return t;var n,r=e,o=r.fontSize,i=r.fontFamily;return o||i?((Dx(t)||"span"!==Sx(n=im(t)))&&(n=im("<span>".concat(t,"</span>"))),o&&n.css("font-size",o),i&&n.css("font-family",i),wx(n)):t},preParseHtml:[{selector:"font",preParseHtml:function(e){var t=im(e);if("font"!==Sx(t))return e;var n=t.attr("size")||"";n&&(t.removeAttr("size"),t.css("font-size",eO[n]));var r=t.attr("face")||"";return r&&(t.removeAttr("face"),t.css("font-family",r)),t[0]}}],parseStyleHtml:function(e,t,n){var r=im(e);if(!Cg.isText(t))return t;var o=t,i=Ax(r,"font-size");i&&(o.fontSize=i);var a=Ax(r,"font-family").replace(/"/g,"");return a&&(o.fontFamily=a),o},menus:[{key:"fontSize",factory:function(){return new Qx},config:{fontSizeList:["12px",{name:"13px",value:"13px"},"14px","15px","16px","19px",{name:"22px",value:"22px"},"24px","29px","32px","40px","48px"]}},{key:"fontFamily",factory:function(){return new Jx},config:{fontFamilyList:["黑体",{name:"仿宋",value:"仿宋"},"楷体","标楷体","华文仿宋","华文楷体",{name:"宋体",value:"宋体"},"微软雅黑","Arial","Tahoma","Verdana","Times New Roman","Courier New"]}}]};var nO=function(){function e(){this.title=JE("formatPainter.title"),this.iconSvg='<svg viewBox="0 0 24 24"><path d="M8 19.997v-5h2v5h9v-7H5v7zm-4-9h16v-3h-6v-4h-4v4H4zm-1 10v-8H2v-6a1 1 0 0 1 1-1h5v-3a1 1 0 0 1 1-1h6a1 1 0 0 1 1 1v3h5a1 1 0 0 1 1 1v6h-1v8a1 1 0 0 1-1 1H4a1 1 0 0 1-1-1"/></svg>',this.tag="button"}return e.prototype.getValue=function(e){return""},e.prototype.isActive=function(t){return e.attrs.isSelect},e.prototype.isDisabled=function(e){return!1},e.prototype.setFormatHtml=function(t){var n,r;if(t.getSelectionText().length){if(e.attrs.formatStyle){!function(e){var t=Kh.marks(e);t&&Object.keys(t).forEach(function(t){e.removeMark(t)})}(t);try{for(var o=Qg(Object.entries(e.attrs.formatStyle)),i=o.next();!i.done;i=o.next()){var a=ev(i.value,2),s=a[0],u=a[1];t.addMark(s,u)}}catch(e){n={error:e}}finally{try{i&&!i.done&&(r=o.return)&&r.call(o)}finally{if(n)throw n.error}}}e.attrs.formatStyle=null,e.attrs.isSelect=!1}},e.prototype.exec=function(t){e.attrs.isSelect?(e.attrs.isSelect=!1,e.attrs.formatStyle=null):t.getSelectionText().length&&(e.attrs.formatStyle=Kh.marks(t),e.attrs.isSelect=!0);t.blur(),t.focus()},e.attrs={isSelect:!1,formatStyle:null},e}();var rO={menus:[{key:"formatPainter",factory:function(){return new nO}}],editorPlugin:function(e){var t=new nO,n=e.onChange,r=e,o=function(){t.setFormatHtml(r),document.removeEventListener("mouseup",o)};return r.onChange=function(){n(),nO.attrs.isSelect&&(document.removeEventListener("mouseup",o),document.addEventListener("mouseup",o))},r}},oO=function(){function e(){this.title=JE("fullScreen.title"),this.iconSvg=bx,this.tag="button",this.alwaysEnable=!0}return e.prototype.getValue=function(e){return""},e.prototype.isActive=function(e){return e.isFullScreen},e.prototype.isDisabled=function(e){return!1},e.prototype.getIcon=function(e){return e.isFullScreen?bx:'<svg t="1723361745825" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="8705" width="200" height="200"><path d="M703.926857 362.642286a42.642286 42.642286 0 0 1-42.642286-42.642286V128a42.642286 42.642286 0 1 1 85.357715 0v149.357714h149.357714c21.211429 0 38.765714 15.433143 42.057143 35.693715l0.585143 6.948571a42.642286 42.642286 0 0 1-42.642286 42.642286H703.926857zM703.926857 938.642286a42.642286 42.642286 0 0 1-42.642286-42.642286V704c0-23.552 19.090286-42.642286 42.642286-42.642286h192.073143a42.642286 42.642286 0 1 1 0 85.284572l-149.357714 0.073143v149.284571c0 21.211429-15.506286 38.765714-35.84 42.130286l-6.875429 0.512zM319.853714 938.642286a42.642286 42.642286 0 0 1-42.642285-42.642286v-149.284571H127.853714a42.642286 42.642286 0 0 1-42.130285-35.84l-0.585143-6.875429c0-23.552 19.163429-42.642286 42.715428-42.642286h192c23.552 0 42.715429 19.017143 42.715429 42.642286v192a42.642286 42.642286 0 0 1-42.715429 42.642286zM127.853714 362.642286a42.642286 42.642286 0 1 1 0-85.284572H277.211429V128c0-21.211429 15.433143-38.765714 35.766857-42.130286l6.875428-0.512c23.552 0 42.715429 19.017143 42.715429 42.642286v192a42.642286 42.642286 0 0 1-42.715429 42.642286H127.853714z" fill="#333333" p-id="8706"></path></svg>'},e.prototype.getTitle=function(e){return e.isFullScreen?JE("fullScreen.title"):JE("fullScreen.cancelTitle")},e.prototype.exec=function(e,t){e.isFullScreen?e.unFullScreen():e.fullScreen()},e}(),iO={menus:[{key:"fullScreen",factory:function(){return new oO}}]};function aO(e){return function(t,n){return"<h".concat(e,">").concat(n,"</h").concat(e,">")}}var sO={type:"header1",elemToHtml:aO(1)},uO={type:"header2",elemToHtml:aO(2)},lO={type:"header3",elemToHtml:aO(3)},cO={type:"header4",elemToHtml:aO(4)},dO={type:"header5",elemToHtml:aO(5)},fO={type:"header6",elemToHtml:aO(6)};function pO(e){var t=ev(Kh.nodes(e,{match:function(e){return Py.getNodeType(e).startsWith("header")},universal:!0}),1),n=t[0];if(null==n)return"paragraph";var r=ev(n,1)[0];return Py.getNodeType(r)}function hO(e){if(null==e.selection)return!0;var t=ev(Kh.nodes(e,{match:function(e){var t=Py.getNodeType(e);return"paragraph"===t||!!t.startsWith("header")},universal:!0,mode:"highest"}),1);return!t[0]}function gO(e,t){t&&jg.setNodes(e,{type:t})}var vO=function(){function e(){this.tag="button"}return e.prototype.getValue=function(e){return pO(e)},e.prototype.isActive=function(e){return this.getValue(e)===this.type},e.prototype.isDisabled=function(e){return hO(e)},e.prototype.exec=function(e,t){var n=this.type;gO(e,t===n?"paragraph":n)},e}(),mO=function(e){function t(){var t=e.apply(this,tv([],ev(arguments),!1))||this;return t.title="H1",t.type="header1",t}return Kg(t,e),t}(vO),yO=function(e){function t(){var t=e.apply(this,tv([],ev(arguments),!1))||this;return t.title="H2",t.type="header2",t}return Kg(t,e),t}(vO),bO=function(e){function t(){var t=e.apply(this,tv([],ev(arguments),!1))||this;return t.title="H3",t.type="header3",t}return Kg(t,e),t}(vO),EO=function(e){function t(){var t=e.apply(this,tv([],ev(arguments),!1))||this;return t.title="H4",t.type="header4",t}return Kg(t,e),t}(vO),CO=function(e){function t(){var t=e.apply(this,tv([],ev(arguments),!1))||this;return t.title="H5",t.type="header5",t}return Kg(t,e),t}(vO),DO=function(e){function t(){var t=e.apply(this,tv([],ev(arguments),!1))||this;return t.title="H6",t.type="header6",t}return Kg(t,e),t}(vO),wO=function(){function e(){this.title=JE("header.title"),this.iconSvg='<svg viewBox="0 0 1024 1024"><path d="M960 960c-51.2 0-102.4-3.2-153.6-3.2-51.2 0-99.2 3.2-150.4 3.2-19.2 0-28.8-22.4-28.8-38.4 0-51.2 57.6-28.8 86.4-48 19.2-12.8 19.2-60.8 19.2-80v-224-19.2c-9.6-3.2-19.2-3.2-28.8-3.2H320c-9.6 0-19.2 0-28.8 3.2V780.8c0 22.4 0 80 22.4 92.8 28.8 19.2 96-6.4 96 44.8 0 16-9.6 41.6-28.8 41.6-54.4 0-105.6-3.2-160-3.2-48 0-96 3.2-147.2 3.2-19.2 0-28.8-22.4-28.8-38.4 0-51.2 51.2-28.8 80-48 19.2-12.8 19.2-60.8 19.2-83.2V294.4c0-28.8 3.2-115.2-22.4-131.2-25.6-16-86.4 9.6-86.4-41.6 0-16 6.4-41.6 28.8-41.6 51.2 0 105.6 3.2 156.8 3.2 48 0 96-3.2 144-3.2 19.2 0 28.8 22.4 28.8 41.6 0 48-57.6 25.6-83.2 41.6-19.2 12.8-19.2 73.6-19.2 92.8v201.6c6.4 3.2 16 3.2 22.4 3.2h400c6.4 0 12.8 0 22.4-3.2V256c0-22.4 0-80-19.2-92.8-28.8-16-86.4 6.4-86.4-41.6 0-16 9.6-41.6 28.8-41.6 51.2 0 99.2 3.2 150.4 3.2 48 0 99.2-3.2 147.2-3.2 19.2 0 28.8 22.4 28.8 41.6 0 51.2-57.6 25.6-86.4 41.6-19.2 12.8-19.2 70.4-19.2 92.8v537.6c0 19.2 0 67.2 19.2 80 28.8 19.2 89.6-6.4 89.6 44.8 0 19.2-6.4 41.6-28.8 41.6z"></path></svg>',this.tag="select",this.width=60}return e.prototype.getOptions=function(e){var t=[{value:"header1",text:"H1",styleForRenderMenuList:{"font-size":"32px","font-weight":"bold"}},{value:"header2",text:"H2",styleForRenderMenuList:{"font-size":"24px","font-weight":"bold"}},{value:"header3",text:"H3",styleForRenderMenuList:{"font-size":"18px","font-weight":"bold"}},{value:"header4",text:"H4",styleForRenderMenuList:{"font-size":"16px","font-weight":"bold"}},{value:"header5",text:"H5",styleForRenderMenuList:{"font-size":"13px","font-weight":"bold"}},{value:"header6",text:"H6",styleForRenderMenuList:{"font-size":"11px","font-weight":"bold"}},{value:"paragraph",text:JE("header.text")}],n=this.getValue(e).toString();return t.forEach(function(e){e.value===n?e.selected=!0:e.selected=void 0}),t},e.prototype.isActive=function(e){return!1},e.prototype.getValue=function(e){return pO(e)},e.prototype.isDisabled=function(e){return hO(e)},e.prototype.exec=function(e,t){gO(e,t.toString())},e}(),SO={key:"headerSelect",factory:function(){return new wO}},AO={key:"header1",factory:function(){return new mO}},xO={key:"header2",factory:function(){return new yO}},OO={key:"header3",factory:function(){return new bO}},NO={key:"header4",factory:function(){return new EO}},BO={key:"header5",factory:function(){return new CO}},TO={key:"header6",factory:function(){return new DO}};function kO(e){return function(t,n,r){var o=im(t);return 0===(n=n.filter(function(e){return!!Cg.isText(e)||!!r.isInline(e)})).length&&(n=[{text:o.text().replace(/\s+/gm," ")}]),{type:"header".concat(e),children:n}}}var FO={selector:"h1:not([data-w-e-type])",parseElemHtml:kO(1)},IO={selector:"h2:not([data-w-e-type])",parseElemHtml:kO(2)},PO={selector:"h3:not([data-w-e-type])",parseElemHtml:kO(3)},_O={selector:"h4:not([data-w-e-type])",parseElemHtml:kO(4)},LO={selector:"h5:not([data-w-e-type])",parseElemHtml:kO(5)},RO={selector:"h6:not([data-w-e-type])",parseElemHtml:kO(6)};function MO(e){return function(t,n,r){return BD("h".concat(e),null,n)}}var jO={renderElems:[{type:"header1",renderElem:MO(1)},{type:"header2",renderElem:MO(2)},{type:"header3",renderElem:MO(3)},{type:"header4",renderElem:MO(4)},{type:"header5",renderElem:MO(5)},{type:"header6",renderElem:MO(6)}],elemsToHtml:[sO,uO,lO,cO,dO,fO],parseElemsHtml:[FO,IO,PO,_O,LO,RO],menus:[SO,AO,xO,OO,NO,BO,TO],editorPlugin:function(e){var t=e.insertBreak,n=e;return n.insertBreak=function(){var r=ev(Kh.nodes(n,{match:function(e){return Py.getNodeType(e).startsWith("header")},universal:!0}),1),o=r[0];if(o)if(Py.isSelectionAtLineEnd(e,o[1])){jg.insertNodes(n,{type:"paragraph",children:[{text:""}]},{mode:"highest"})}else t();else t()},n}};var HO={type:"image",elemToHtml:function(e,t){var n=e,r=n.src,o=n.alt,i=void 0===o?"":o,a=n.href,s=void 0===a?"":a,u=n.width,l=void 0===u?"":u,c=n.height,d=void 0===c?"":c,f=n.style,p=void 0===f?{}:f,h=p.width,g=void 0===h?"":h,v=p.height,m=void 0===v?"":v,y="";return g&&(y+="width: ".concat(g,";")),m&&(y+="height: ".concat(m,";")),'<img src="'.concat(r,'" alt="').concat(i,'" data-href="').concat(s,'" width="').concat(l,'" height="').concat(d,'" style="').concat(y,'"/>')}};var zO=function(){function e(){this.title=JE("image.delete"),this.iconSvg='<svg viewBox="0 0 1024 1024"><path d="M826.8032 356.5312c-19.328 0-36.3776 15.6928-36.3776 35.0464v524.2624c0 19.328-16 34.56-35.328 34.56H264.9344c-19.328 0-35.5072-15.3088-35.5072-34.56V390.0416c0-19.328-14.1568-35.0464-33.5104-35.0464s-33.5104 15.6928-33.5104 35.0464V915.712c0 57.9328 44.6208 108.288 102.528 108.288H755.2c57.9328 0 108.0832-50.4576 108.0832-108.288V391.4752c-0.1024-19.2512-17.1264-34.944-36.48-34.944z" p-id="9577"></path><path d="M437.1712 775.7568V390.6048c0-19.328-14.1568-35.0464-33.5104-35.0464s-33.5104 15.616-33.5104 35.0464v385.152c0 19.328 14.1568 35.0464 33.5104 35.0464s33.5104-15.7184 33.5104-35.0464zM649.7024 775.7568V390.6048c0-19.328-17.0496-35.0464-36.3776-35.0464s-36.3776 15.616-36.3776 35.0464v385.152c0 19.328 17.0496 35.0464 36.3776 35.0464s36.3776-15.7184 36.3776-35.0464zM965.0432 217.0368h-174.6176V145.5104c0-57.9328-47.2064-101.76-104.6528-101.76h-350.976c-57.8304 0-105.3952 43.8528-105.3952 101.76v71.5264H54.784c-19.4304 0-35.0464 14.1568-35.0464 33.5104 0 19.328 15.616 33.5104 35.0464 33.5104h910.3616c19.328 0 35.0464-14.1568 35.0464-33.5104 0-19.3536-15.6928-33.5104-35.1488-33.5104z m-247.3728 0H297.3952V145.5104c0-19.328 18.2016-34.7648 37.4272-34.7648h350.976c19.1488 0 31.872 15.1296 31.872 34.7648v71.5264z"></path></svg>',this.tag="button"}return e.prototype.getValue=function(e){return""},e.prototype.isActive=function(e){return!1},e.prototype.isDisabled=function(e){return null==e.selection||null==Py.getSelectedNodeByType(e,"image")},e.prototype.exec=function(e,t){this.isDisabled(e)||jg.removeNodes(e,{match:function(e){return Py.checkNodeType(e,"image")}})},e}();function $O(e){return void 0===e&&(e="r"),"".concat(e,"-").concat(Hm())}function UO(e){return e.replace(/</g,"<").replace(/>/g,">")}function VO(e){var t=e.selection;if(null==t)return!0;if(!fg.isCollapsed(t))return!0;var n=ev(Kh.nodes(e,{match:function(t){var n=Py.getNodeType(t);return"code"===n||("pre"===n||("link"===n||("list-item"===n||(!!n.startsWith("header")||("blockquote"===n||!!Kh.isVoid(e,t))))))},universal:!0}),1);return!!n[0]}function WO(e,t,n){return Zg(this,arguments,void 0,function(e,t,n,r,o){var i,a;return void 0===r&&(r=""),void 0===o&&(o=""),Jg(this,function(s){switch(s.label){case 0:return(i=t.getMenuConfig(e).checkImage)?[4,i(n,r,o)]:[3,2];case 1:if("string"==typeof(a=s.sent()))return t.alert(a,"error"),[2,!1];if(null==a)return[2,!1];s.label=2;case 2:return[2,!0]}})})}function GO(e,t,n){return Zg(this,void 0,void 0,function(){var r;return Jg(this,function(o){switch(o.label){case 0:return(r=t.getMenuConfig(e).parseImageSrc)?[4,r(n)]:[3,2];case 1:return[2,o.sent()];case 2:return[2,n]}})})}function qO(e,t){return Zg(this,arguments,void 0,function(e,t,n,r){var o,i,a;return void 0===n&&(n=""),void 0===r&&(r=""),Jg(this,function(s){switch(s.label){case 0:return[4,WO("insertImage",e,t,n,r)];case 1:return s.sent()?[4,GO("insertImage",e,t)]:[2];case 2:return o=s.sent(),i={type:"image",src:UO(o),href:r,alt:n,style:{},children:[{text:""}]},null===e.selection&&e.restoreSelection(),Py.getSelectedNodeByType(e,"image")&&e.move(1),VO(e)?[2]:(jg.insertNodes(e,i),(a=e.getMenuConfig("insertImage").onInsertedImage)&&a(i),[2])}})})}function KO(){return $O("w-e-edit-image")}var YO=function(){function e(){this.title=JE("image.edit"),this.iconSvg=mx,this.tag="button",this.showModal=!0,this.modalWidth=300,this.$content=null,this.srcInputId=KO(),this.altInputId=KO(),this.hrefInputId=KO(),this.buttonId=KO()}return e.prototype.getValue=function(e){return""},e.prototype.getImageNode=function(e){return Py.getSelectedNodeByType(e,"image")},e.prototype.isActive=function(e){return!1},e.prototype.exec=function(e,t){},e.prototype.isDisabled=function(e){var t=e.selection;return null==t||(!fg.isCollapsed(t)||null==Py.getSelectedNodeByType(e,"image"))},e.prototype.getModalPositionNode=function(e){return this.getImageNode(e)},e.prototype.getModalContentElem=function(e){var t=this,n=this,r=n.srcInputId,o=n.altInputId,i=n.hrefInputId,a=n.buttonId,s=this.getImageNode(e);if(null==s)throw new Error("Not found selected image node");var u=ev(lC(JE("image.src"),r),2),l=u[0],c=im(u[1]),d=ev(lC(JE("image.desc"),o),2),f=d[0],p=im(d[1]),h=ev(lC(JE("image.link"),i),2),g=h[0],v=im(h[1]),m=ev(dC(a,JE("common.ok")),1)[0];if(null==this.$content){var y=im("<div></div>");y.on("click","#".concat(a),function(n){n.preventDefault();var a=y.find("#".concat(r)).val(),s=y.find("#".concat(o)).val(),u=y.find("#".concat(i)).val();t.updateImage(e,a,s,u),e.hidePanelOrModal()}),this.$content=y}var b=this.$content;b.empty(),b.append(l),b.append(f),b.append(g),b.append(m);var E=s,C=E.src,D=E.alt,w=void 0===D?"":D,S=E.href,A=void 0===S?"":S;return c.val(C),p.val(w),v.val(A),setTimeout(function(){c.focus()}),b[0]},e.prototype.updateImage=function(e,t,n,r,o){void 0===n&&(n=""),void 0===r&&(r=""),void 0===o&&(o={}),t&&(e.restoreSelection(),this.isDisabled(e)||function(e,t){Zg(this,arguments,void 0,function(e,t,n,r,o){var i,a,s,u,l,c;return void 0===n&&(n=""),void 0===r&&(r=""),void 0===o&&(o={}),Jg(this,function(d){switch(d.label){case 0:return[4,WO("editImage",e,t,n,r)];case 1:return d.sent()?[4,GO("editImage",e,t)]:[2];case 2:return i=d.sent(),null==(a=Py.getSelectedNodeByType(e,"image"))||(s=a.style,u={src:i,alt:n,href:r,style:Yg(Yg({},void 0===s?{}:s),o)},jg.setNodes(e,u,{match:function(e){return Py.checkNodeType(e,"image")}}),l=Py.getSelectedNodeByType(e,"image"),(c=e.getMenuConfig("editImage").onUpdatedImage)&&c(l)),[2]}})})}(e,t,n,r,o))},e}();function XO(){return $O("w-e-insert-image")}var ZO=function(){function e(){this.title=JE("image.editSize"),this.tag="button",this.showModal=!0,this.modalWidth=320,this.$content=null,this.widthInputId=XO(),this.heightInputId=XO(),this.buttonId=XO()}return e.prototype.getSelectedImageNode=function(e){return Py.getSelectedNodeByType(e,"image")},e.prototype.getValue=function(e){return""},e.prototype.isActive=function(e){return!1},e.prototype.exec=function(e,t){},e.prototype.isDisabled=function(e){return null==e.selection||null==this.getSelectedImageNode(e)},e.prototype.getModalPositionNode=function(e){return this.getSelectedImageNode(e)},e.prototype.getModalContentElem=function(e){var t=this,n=t.widthInputId,r=t.heightInputId,o=t.buttonId,i=ev(lC(JE("image.width"),n,"auto"),2),a=i[0],s=im(i[1]),u=ev(lC(JE("image.height"),r,"auto"),2),l=u[0],c=im(u[1]),d=ev(dC(o,JE("image.ok")),1)[0],f=this.getSelectedImageNode(e);if(null==this.$content){var p=im("<div></div>");p.on("click","#".concat(o),function(t){t.preventDefault();var o=p.find("#".concat(n)).val().trim(),i=p.find("#".concat(r)).val().trim(),a=function(e){return/^\d+(\.\d+)?%$/.test(e)},s=function(e){return/^\d+(\.\d+)?$/.test(e)},u=function(e){return/^\d+(\.\d+)?px$/.test(e)},l="auto",c="auto";a(o)?l=o:s(o)?l="".concat(parseInt(o,10),"px"):u(o)&&(l=o),a(i)?c=i:s(i)?c="".concat(parseInt(i,10),"px"):u(i)&&(c=i);var d=f.style,h=void 0===d?{}:d;e.restoreSelection();var g=Yg(Yg({},h),{style:{width:l,height:c}});jg.setNodes(e,g,{match:function(e){return Py.checkNodeType(e,"image")}}),e.hidePanelOrModal()}),this.$content=p}var h=this.$content;if(h.empty(),h.append(a),h.append(l),h.append(d),null==f)return h[0];var g=f.style,v=void 0===g?{}:g,m=v.width,y=void 0===m?"auto":m,b=v.height,E=void 0===b?"auto":b;return s.val(y),c.val(E),setTimeout(function(){s.focus()}),h[0]},e}();function JO(){return $O("w-e-insert-image")}var QO=function(){function e(){this.title=JE("image.netImage"),this.iconSvg='<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>',this.tag="button",this.showModal=!0,this.modalWidth=300,this.$content=null,this.srcInputId=JO(),this.altInputId=JO(),this.hrefInputId=JO(),this.buttonId=JO()}return e.prototype.getValue=function(e){return""},e.prototype.isActive=function(e){return!1},e.prototype.exec=function(e,t){},e.prototype.isDisabled=function(e){return VO(e)},e.prototype.getModalPositionNode=function(e){return null},e.prototype.getModalContentElem=function(e){var t=this,n=this,r=n.srcInputId,o=n.altInputId,i=n.hrefInputId,a=n.buttonId,s=ev(lC(JE("image.src"),r),2),u=s[0],l=im(s[1]),c=ev(lC(JE("image.desc"),o),2),d=c[0],f=im(c[1]),p=ev(lC(JE("image.link"),i),2),h=p[0],g=im(p[1]),v=ev(dC(a,JE("common.ok")),1)[0];if(null==this.$content){var m=im("<div></div>");m.on("click","#".concat(a),function(n){n.preventDefault();var a=m.find("#".concat(r)).val().trim(),s=m.find("#".concat(o)).val().trim(),u=m.find("#".concat(i)).val().trim();t.insertImage(e,a,s,u),e.hidePanelOrModal()}),this.$content=m}var y=this.$content;return y.empty(),y.append(u),y.append(d),y.append(h),y.append(v),l.val(""),f.val(""),g.val(""),setTimeout(function(){l.focus()}),y[0]},e.prototype.insertImage=function(e,t,n,r){void 0===n&&(n=""),void 0===r&&(r=""),t&&(e.restoreSelection(),this.isDisabled(e)||qO(e,t,n,r))},e}(),eN=function(){function e(){this.title=JE("image.viewLink"),this.iconSvg=yx,this.tag="button"}return e.prototype.getValue=function(e){var t=Py.getSelectedNodeByType(e,"image");return t&&t.href||""},e.prototype.isActive=function(e){return!1},e.prototype.isDisabled=function(e){return null==e.selection||!this.getValue(e)},e.prototype.exec=function(e,t){if(!this.isDisabled(e)){if(!t||"string"!=typeof t)throw new Error("View image link failed, image.href is '".concat(t,"'"));window.open(t,"_blank")}},e}(),tN=function(){function e(){this.tag="button"}return e.prototype.getValue=function(e){return""},e.prototype.isActive=function(e){return!1},e.prototype.getSelectedNode=function(e){return Py.getSelectedNodeByType(e,"image")},e.prototype.isDisabled=function(e){return null==e.selection||null==this.getSelectedNode(e)},e.prototype.exec=function(e,t){if(!this.isDisabled(e)){var n=this.getSelectedNode(e);if(null!=n){var r=Py.getHoverbar(e);r&&r.hideAndClean();var o=n.style,i={style:Yg(Yg({},void 0===o?{}:o),{width:this.value,height:""})};jg.setNodes(e,i,{match:function(e){return Py.checkNodeType(e,"image")}})}}},e}(),nN=function(e){function t(){var t=e.apply(this,tv([],ev(arguments),!1))||this;return t.title="30%",t.value="30%",t}return Kg(t,e),t}(tN),rN=function(e){function t(){var t=e.apply(this,tv([],ev(arguments),!1))||this;return t.title="50%",t.value="50%",t}return Kg(t,e),t}(tN),oN=function(e){function t(){var t=e.apply(this,tv([],ev(arguments),!1))||this;return t.title="100%",t.value="100%",t}return Kg(t,e),t}(tN),iN={onInsertedImage:function(e){},onUpdatedImage:function(e){},checkImage:function(e,t,n){return!0},parseImageSrc:function(e){return e}};function aN(e,t){var n=Py.findKey(e,t).id;return"w-e-image-container-".concat(n)}function sN(e,t,n,r){var o=im("body"),i=aN(e,t),a=r.width,s=r.height,u=0,l=0,c=0,d=0,f=!1,p=null;var h=SC(function(e){e.preventDefault();var t=e.clientX,n=l+(f?u-t:t-u),r=c*(n/l);n>d-6||null!=p&&(n<=15||r<=15||(p.css("width","".concat(n,"px")),p.css("height","".concat(r,"px"))))},100);function g(n){if(o.off("mousemove",h),null!=p){var r=p.width().toFixed(2),i=p.height().toFixed(2),a={style:Yg(Yg({},t.style),{width:"".concat(r,"px"),height:"".concat(i,"px")})};jg.setNodes(e,a,{at:Py.findPath(e,t)}),o.off("mouseup",g)}}function v(t,n){p=function(){var e=im("#".concat(i));if(0===e.length)throw new Error("Cannot find image container elem");return e}(),u=t,d=n;var r=p.find("img");if(0===r.length)throw new Error("Cannot find image elem");l=r.width(),c=r.height(),o.on("mousemove",h),o.on("mouseup",g);var a=Py.getHoverbar(e);a&&a.hideAndClean()}var m={};return a&&(m.width=a),s&&(m.height=s),m.boxShadow="0 0 0 1px #B4D5FF",BD("div",{id:i,style:m,className:"w-e-image-container w-e-selected-image-container",on:{mousedown:function(n){var r=im(n.target);if(r.hasClass("w-e-image-dragger")){n.preventDefault(),(r.hasClass("left-top")||r.hasClass("left-bottom"))&&(f=!0);var o=Py.getParentNode(e,t);if(null!=o){var i=Py.toDOMNode(e,o),a=i.getBoundingClientRect?i.getBoundingClientRect():{width:0},s=window.getComputedStyle(i),u=parseFloat(s.paddingLeft),l=parseFloat(s.paddingRight),c=parseFloat(s.borderLeftWidth),d=parseFloat(s.borderRightWidth);v(n.clientX,a.width-u-l-c-d)}}}}},n,BD("div",{className:"w-e-image-dragger left-top"}),BD("div",{className:"w-e-image-dragger right-top"}),BD("div",{className:"w-e-image-dragger left-bottom"}),BD("div",{className:"w-e-image-dragger right-bottom"}))}var uN={type:"image",renderElem:function(e,t,n){var r=e,o=r.src,i=r.alt,a=void 0===i?"":i,s=r.href,u=void 0===s?"":s,l=r.style,c=void 0===l?{}:l,d=c.width,f=void 0===d?"":d,p=c.height,h=void 0===p?"":p,g=Py.isNodeSelected(n,e),v={maxWidth:"100%"};f&&(v.width="100%"),h&&(v.height="100%");var m=BD("img",{style:v,src:o,alt:a,"data-href":u}),y=n.isDisabled();return g&&!y?sN(n,e,m,{width:f,height:h}):function(e,t,n,r){var o=r.width,i=r.height,a={};return o&&(a.width=o),i&&(a.height=i),BD("div",{id:aN(e,t),style:a,className:"w-e-image-container"},n)}(n,e,m,{width:f,height:h})}},lN={renderElems:[uN],elemsToHtml:[HO],parseElemsHtml:[{selector:"img:not([data-w-e-type])",parseElemHtml:function(e,t,n){var r=im(e),o=r.attr("data-href")||"";return o=decodeURIComponent(o),{type:"image",src:r.attr("src")||"",alt:r.attr("alt")||"",href:o,style:{width:Ax(r,"width"),height:Ax(r,"height")},width:r.attr("width")||"",height:r.attr("height")||"",children:[{text:""}]}}}],menus:[{key:"insertImage",factory:function(){return new QO},config:iN},{key:"deleteImage",factory:function(){return new zO}},{key:"editImage",factory:function(){return new YO},config:iN},{key:"viewImageLink",factory:function(){return new eN}},{key:"imageWidth30",factory:function(){return new nN}},{key:"imageWidth50",factory:function(){return new rN}},{key:"imageWidth100",factory:function(){return new oN}},{key:"editorImageSizeMenu",factory:function(){return new ZO}}],editorPlugin:function(e){var t=e.isInline,n=e.isVoid,r=e;return r.isInline=function(e){return"image"===e.type||t(e)},r.isVoid=function(e){return"image"===e.type||n(e)},r}},cN=function(){function e(){this.tag="button"}return e.prototype.getValue=function(e){var t=ev(Kh.nodes(e,{match:function(e){return!!e.indent},universal:!0}),1),n=t[0];return null==n?"":ev(n,1)[0].indent||""},e.prototype.isActive=function(e){return!1},e.prototype.getMatchNode=function(e){var t=ev(Kh.nodes(e,{match:function(e){var t=Py.getNodeType(e);return"paragraph"===t||!!t.startsWith("header")},universal:!0,mode:"highest"}),1),n=t[0];return null==n?null:n[0]},e}(),dN=function(e){function t(){var t=e.apply(this,tv([],ev(arguments),!1))||this;return t.title=JE("indent.decrease"),t.iconSvg='<svg viewBox="0 0 1024 1024"><path d="M0 64h1024v128H0z m384 192h640v128H384z m0 192h640v128H384z m0 192h640v128H384zM0 832h1024v128H0z m256-512v384l-256-192z"></path></svg>',t}return Kg(t,e),t.prototype.isDisabled=function(e){var t=this.getMatchNode(e);return null==t||!t.indent},t.prototype.exec=function(e,t){jg.setNodes(e,{indent:null},{match:function(e){return $h.isElement(e)}})},t}(cN),fN=function(e){function t(){var t=e.apply(this,tv([],ev(arguments),!1))||this;return t.title=JE("indent.increase"),t.iconSvg='<svg viewBox="0 0 1024 1024"><path d="M0 64h1024v128H0z m384 192h640v128H384z m0 192h640v128H384z m0 192h640v128H384zM0 832h1024v128H0z m0-128V320l256 192z"></path></svg>',t.DEFAULT_INDENT_VALUE="2em",t}return Kg(t,e),t.prototype.isDisabled=function(e){var t=this.getMatchNode(e);return null==t||!!t.indent},t.prototype.getIndentValue=function(e){var t=this.getMatchNode(e);if(!t)return this.DEFAULT_INDENT_VALUE;var n=t.children.filter(Cg.isText)[0];if(!n||!n.fontSize)return this.DEFAULT_INDENT_VALUE;var r=n.fontSize,o=parseInt(n.fontSize,10),i=r.replace("".concat(o),"");return"".concat(2*o).concat(i)},t.prototype.exec=function(e,t){var n=this.getIndentValue(e);jg.setNodes(e,{indent:n},{match:function(e){return $h.isElement(e)},mode:"highest"})},t}(cN);var pN={renderStyle:function(e,t){if(!$h.isElement(e))return t;var n=e.indent,r=t;return n&&$x(r,{textIndent:n}),r},styleToHtml:function(e,t){if(!$h.isElement(e))return t;var n=e.indent;if(!n)return t;var r=im(t);return r.css("text-indent",n),wx(r)},preParseHtml:[{selector:"p,h1,h2,h3,h4,h5",preParseHtml:function(e){var t=im(e),n=Ax(t,"padding-left");return/^[1-9]\d*em$/.test(n)&&t.css("text-indent","2em"),/^[1-9]\d*px$/.test(n)&&parseInt(n,10)%32==0&&t.css("text-indent","2em"),t[0]}}],parseStyleHtml:function(e,t,n){var r=im(e);if(!$h.isElement(t))return t;var o=t,i=Ax(r,"text-indent"),a=parseInt(i,10);return i&&a>0&&(o.indent=i),o},menus:[{key:"indent",factory:function(){return new fN}},{key:"delIndent",factory:function(){return new dN}}]},hN=function(){function e(){this.tag="button"}return e.prototype.getValue=function(e){return""},e.prototype.isActive=function(e){return!1},e.prototype.isDisabled=function(e){return null==e.selection||!!Py.getSelectedElems(e).some(function(t){var n=t.type;return!(!Kh.isVoid(e,t)||!Kh.isBlock(e,t)||"video"===n)||!!["pre","code"].includes(n)})},e}(),gN=function(e){function t(){var t=e.apply(this,tv([],ev(arguments),!1))||this;return t.title=JE("justify.center"),t.iconSvg='<svg viewBox="0 0 1024 1024"><path d="M870.4 793.6v102.4H153.6v-102.4h716.8z m102.4-230.4v102.4H51.2v-102.4h921.6z m-102.4-230.4v102.4H153.6v-102.4h716.8zM972.8 102.4v102.4H51.2V102.4h921.6z"></path></svg>',t}return Kg(t,e),t.prototype.exec=function(e,t){jg.setNodes(e,{textAlign:"center"},{match:function(t){return $h.isElement(t)&&!e.isInline(t)}})},t}(hN),vN=function(e){function t(){var t=e.apply(this,tv([],ev(arguments),!1))||this;return t.title=JE("justify.justify"),t.iconSvg='<svg viewBox="0 0 1024 1024"><path d="M0 64h1024v128H0z m0 192h1024v128H0z m0 192h1024v128H0z m0 192h1024v128H0z m0 192h1024v128H0z"></path></svg>',t}return Kg(t,e),t.prototype.exec=function(e,t){jg.setNodes(e,{textAlign:"justify"},{match:function(t){return $h.isElement(t)&&!e.isInline(t)}})},t}(hN),mN=function(e){function t(){var t=e.apply(this,tv([],ev(arguments),!1))||this;return t.title=JE("justify.left"),t.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>',t}return Kg(t,e),t.prototype.exec=function(e,t){jg.setNodes(e,{textAlign:"left"},{match:function(t){return $h.isElement(t)&&!e.isInline(t)}})},t}(hN),yN=function(e){function t(){var t=e.apply(this,tv([],ev(arguments),!1))||this;return t.title=JE("justify.right"),t.iconSvg='<svg viewBox="0 0 1024 1024"><path d="M972.8 793.6v102.4H256v-102.4h716.8z m0-230.4v102.4H51.2v-102.4h921.6z m0-230.4v102.4H256v-102.4h716.8zM972.8 102.4v102.4H51.2V102.4h921.6z"></path></svg>',t}return Kg(t,e),t.prototype.exec=function(e,t){jg.setNodes(e,{textAlign:"right"},{match:function(t){return $h.isElement(t)&&!e.isInline(t)}})},t}(hN);var bN={renderStyle:function(e,t){if(!$h.isElement(e))return t;var n=e.textAlign,r=t;return n&&$x(r,{textAlign:n}),r},styleToHtml:function(e,t){if(!$h.isElement(e))return t;var n=e.textAlign;if(!n)return t;var r=im(t);return r.css("text-align",n),wx(r)},parseStyleHtml:function(e,t,n){var r=im(e);if(!$h.isElement(t))return t;var o=t,i=Ax(r,"text-align");return i&&(o.textAlign=i),o},menus:[{key:"justifyLeft",factory:function(){return new mN}},{key:"justifyRight",factory:function(){return new yN}},{key:"justifyCenter",factory:function(){return new gN}},{key:"justifyJustify",factory:function(){return new vN}}]};var EN=function(){function e(){this.title=JE("lineHeight.title"),this.iconSvg='<svg viewBox="0 0 1024 1024"><path d="M964 788a8 8 0 0 1 8 8v98a8 8 0 0 1-8 8H438a8 8 0 0 1-8-8v-98a8 8 0 0 1 8-8h526zM198.93 144.306c6.668-5.798 16.774-5.094 22.573 1.574l122.26 140.582a16 16 0 0 1 3.927 10.5c0 8.836-7.164 16-16 16h-61.8a8 8 0 0 0-8 8v390.077h69.819a16 16 0 0 1 10.502 3.928c6.666 5.8 7.37 15.906 1.57 22.573L221.476 878.123a16 16 0 0 1-1.57 1.57c-6.668 5.8-16.774 5.097-22.574-1.57L75.051 737.538a16 16 0 0 1-3.928-10.5c0-8.837 7.163-16 16-16h69.822V312.96H87.127a16 16 0 0 1-10.502-3.928c-6.666-5.8-7.37-15.906-1.57-22.573l122.303-140.582a16 16 0 0 1 1.572-1.572zM964 465a8 8 0 0 1 8 8v98a8 8 0 0 1-8 8H438a8 8 0 0 1-8-8v-98a8 8 0 0 1 8-8h526z m0-323a8 8 0 0 1 8 8v98a8 8 0 0 1-8 8H438a8 8 0 0 1-8-8v-98a8 8 0 0 1 8-8h526z"></path></svg>',this.tag="select",this.width=80}return e.prototype.getOptions=function(e){var t=[],n=e.getMenuConfig("lineHeight").lineHeightList,r=void 0===n?[]:n;t.push({text:JE("lineHeight.default"),value:""}),r.forEach(function(e){t.push({text:e,value:e})});var o=this.getValue(e);return t.forEach(function(e){e.value===o?e.selected=!0:e.selected=void 0}),t},e.prototype.getMatchNode=function(e){var t=ev(Kh.nodes(e,{match:function(e){var t=Py.getNodeType(e);return!!t.startsWith("header")||!!["paragraph","blockquote","list-item"].includes(t)},universal:!0,mode:"highest"}),1),n=t[0];return null==n?null:n[0]},e.prototype.isActive=function(e){return!1},e.prototype.getValue=function(e){var t=this.getMatchNode(e);return null==t?"":$h.isElement(t)&&t.lineHeight||""},e.prototype.isDisabled=function(e){return null==e.selection||null==this.getMatchNode(e)},e.prototype.exec=function(e,t){jg.setNodes(e,{lineHeight:t.toString()},{mode:"highest"})},e}();var CN={renderStyle:function(e,t){if(!$h.isElement(e))return t;var n=e.lineHeight,r=t;return n&&$x(r,{lineHeight:n}),r},styleToHtml:function(e,t){if(!$h.isElement(e))return t;var n=e.lineHeight;if(!n)return t;var r=im(t);return r.css("line-height",n),wx(r)},parseStyleHtml:function(e,t,n){var r=im(e);if(!$h.isElement(t))return t;var o=t,i=n.getMenuConfig("lineHeight").lineHeightList,a=void 0===i?[]:i,s=Ax(r,"line-height");return s&&a.includes(s)&&(o.lineHeight=s),o},menus:[{key:"lineHeight",factory:function(){return new EN},config:{lineHeightList:["1","1.15","1.5","2","2.5","3"]}}]};var DN={type:"link",elemToHtml:function(e,t){var n=e,r=n.url,o=n.target,i=void 0===o?"_blank":o;return'<a href="'.concat(r,'" target="').concat(i,'">').concat(t,"</a>")}};function wN(e,t,n,r){return Zg(this,void 0,void 0,function(){var o,i;return Jg(this,function(a){switch(a.label){case 0:return(o=t.getMenuConfig(e).checkLink)?[4,o(n,r)]:[3,2];case 1:if("string"==typeof(i=a.sent()))return t.alert(i,"error"),[2,!1];if(null==i)return[2,!1];a.label=2;case 2:return[2,!0]}})})}function SN(e,t,n){return Zg(this,void 0,void 0,function(){var r;return Jg(this,function(o){switch(o.label){case 0:return(r=t.getMenuConfig(e).parseLinkUrl)?[4,r(n)]:[3,2];case 1:return[2,o.sent()];case 2:return[2,n]}})})}function AN(e){return null==e.selection||!!Py.getSelectedElems(e).some(function(t){var n=t.type;return!!e.isVoid(t)||!!["pre","code","link"].includes(n)})}function xN(e,t){return{type:"link",url:UO(e),children:t?[{text:t}]:[]}}function ON(e,t,n){return Zg(this,void 0,void 0,function(){var r,o,i,a,s;return Jg(this,function(u){switch(u.label){case 0:return n?(t||(t=n),e.restoreSelection(),AN(e)?[2]:[4,wN("insertLink",e,t,n)]):[2];case 1:return u.sent()?[4,SN("insertLink",e,n)]:[2];case 2:if(r=u.sent(),null==(o=e.selection))return[2];if(fg.isCollapsed(o)){if((a=Py.getLeftLengthOfMaxLength(e))<=0)return[2];e.insertText(" "),a<t.length+1&&(t=t.slice(0,a-1)),s=xN(r,t),jg.insertNodes(e,s),e.insertFragment([{text:" "}])}else if((i=Kh.string(e,o))!==t){if((a=Py.getLeftLengthOfMaxLength(e))<=0)return[2];a<i.length-t.length&&(t=t.slice(0,a)),e.deleteFragment(),s=xN(r,t),jg.insertNodes(e,s)}else s=xN(r),jg.wrapNodes(e,s,{split:!0}),jg.collapse(e,{edge:"end"});return[2]}})})}function NN(){return $O("w-e-update-link")}var BN=function(){function e(){this.title=JE("link.edit"),this.iconSvg=mx,this.tag="button",this.showModal=!0,this.modalWidth=300,this.$content=null,this.urlInputId=NN(),this.buttonId=NN()}return e.prototype.getSelectedLinkElem=function(e){var t=Py.getSelectedNodeByType(e,"link");return null==t?null:t},e.prototype.getValue=function(e){var t=this.getSelectedLinkElem(e);return t&&t.url||""},e.prototype.isActive=function(e){return!1},e.prototype.exec=function(e,t){},e.prototype.isDisabled=function(e){return null==e.selection||null==this.getSelectedLinkElem(e)},e.prototype.getModalPositionNode=function(e){return Py.getSelectedNodeByType(e,"link")},e.prototype.getModalContentElem=function(e){var t=this.urlInputId,n=this.buttonId,r=ev(lC(JE("link.url"),t),2),o=r[0],i=im(r[1]),a=ev(dC(n,JE("common.ok")),1)[0];if(null==this.$content){var s=im("<div></div>");s.on("click","#".concat(n),function(n){n.preventDefault(),e.restoreSelection();var r=Py.getSelectedNodeByType(e,"link"),o=r?eg.string(r):"",i=s.find("#".concat(t)).val();!function(e,t,n){Zg(this,void 0,void 0,function(){var r,o;return Jg(this,function(i){switch(i.label){case 0:return n?[4,wN("editLink",e,t,n)]:[2];case 1:return i.sent()?[4,SN("editLink",e,n)]:[2];case 2:return r=i.sent(),o={url:UO(r)},jg.setNodes(e,o,{match:function(e){return Py.checkNodeType(e,"link")}}),[2]}})})}(e,o,i),e.hidePanelOrModal()}),this.$content=s}var u=this.$content;u.empty(),u.append(o),u.append(a);var l=this.getValue(e);return i.val(l),setTimeout(function(){i.focus()}),u[0]},e}();function TN(){return $O("w-e-insert-link")}var kN=function(){function e(){this.title=JE("link.insert"),this.iconSvg='<svg viewBox="0 0 1024 1024"><path d="M440.224 635.776a51.84 51.84 0 0 1-36.768-15.232c-95.136-95.136-95.136-249.92 0-345.056l192-192C641.536 37.408 702.816 12.032 768 12.032s126.432 25.376 172.544 71.456c95.136 95.136 95.136 249.92 0 345.056l-87.776 87.776a51.968 51.968 0 1 1-73.536-73.536l87.776-87.776a140.16 140.16 0 0 0 0-197.984c-26.432-26.432-61.6-40.992-99.008-40.992s-72.544 14.56-99.008 40.992l-192 192a140.16 140.16 0 0 0 0 197.984 51.968 51.968 0 0 1-36.768 88.768z"></path><path d="M256 1012a242.4 242.4 0 0 1-172.544-71.456c-95.136-95.136-95.136-249.92 0-345.056l87.776-87.776a51.968 51.968 0 1 1 73.536 73.536l-87.776 87.776a140.16 140.16 0 0 0 0 197.984c26.432 26.432 61.6 40.992 99.008 40.992s72.544-14.56 99.008-40.992l192-192a140.16 140.16 0 0 0 0-197.984 51.968 51.968 0 1 1 73.536-73.536c95.136 95.136 95.136 249.92 0 345.056l-192 192A242.4 242.4 0 0 1 256 1012z"></path></svg>',this.tag="button",this.showModal=!0,this.modalWidth=300,this.$content=null,this.textInputId=TN(),this.urlInputId=TN(),this.buttonId=TN()}return e.prototype.getValue=function(e){return""},e.prototype.isActive=function(e){return!1},e.prototype.exec=function(e,t){},e.prototype.isDisabled=function(e){return AN(e)},e.prototype.getModalPositionNode=function(e){return null},e.prototype.getModalContentElem=function(e){var t=e.selection,n=this,r=n.textInputId,o=n.urlInputId,i=n.buttonId,a=ev(lC(JE("link.text"),r),2),s=a[0],u=im(a[1]),l=ev(lC(JE("link.url"),o),2),c=l[0],d=im(l[1]),f=ev(dC(i,JE("common.ok")),1)[0];if(null==this.$content){var p=im("<div></div>");p.on("click","#".concat(i),function(t){t.preventDefault();var n=p.find("#".concat(r)).val(),i=p.find("#".concat(o)).val();ON(e,n,i),e.hidePanelOrModal()}),this.$content=p}var h=this.$content;if(h.empty(),h.append(s),h.append(c),h.append(f),null==t||fg.isCollapsed(t))u.val("");else{var g=Kh.string(e,t);u.val(g)}return d.val(""),setTimeout(function(){u.focus()}),h[0]},e}(),FN=function(){function e(){this.title=JE("link.unLink"),this.iconSvg='<svg viewBox="0 0 1024 1024"><path d="M608.16328 811.815036c9.371954 9.371954 9.371954 24.56788 0 33.941834l-89.347563 89.347564c-118.525421 118.523421-311.38448 118.531421-429.919901 0-118.527421-118.529421-118.527421-311.39048 0-429.917901l89.349564-89.349563c9.371954-9.371954 24.56788-9.371954 33.941834 0l79.195613 79.195613c9.371954 9.371954 9.371954 24.56788 0 33.941834l-89.349563 89.347564c-56.143726 56.145726-56.143726 147.49928 0 203.645005 56.143726 56.143726 147.49928 56.145726 203.647005 0l89.347564-89.347563c9.371954-9.371954 24.56788-9.371954 33.941834 0l79.193613 79.195613z m-113.135447-520.429459c9.371954 9.371954 24.56788 9.371954 33.941834 0l89.347564-89.347564c56.143726-56.149726 147.49928-56.145726 203.647006 0 56.143726 56.145726 56.143726 147.49928 0 203.645006l-89.349564 89.347564c-9.371954 9.371954-9.371954 24.56788 0 33.941834l79.195613 79.195613c9.371954 9.371954 24.56788 9.371954 33.941834 0l89.349564-89.349563c118.529421-118.529421 118.529421-311.38848 0-429.917901-118.531421-118.527421-311.38848-118.527421-429.919901 0l-89.347563 89.347564c-9.371954 9.371954-9.371954 24.56788 0 33.941834l79.193613 79.195613z m469.653707 718.556492l45.253779-45.253779c18.745908-18.745908 18.745908-49.13776 0-67.881669L127.195629 14.062931c-18.745908-18.745908-49.13776-18.745908-67.881669 0L14.058181 59.31871c-18.745908 18.745908-18.745908 49.13776 0 67.881669l882.74169 882.74169c18.745908 18.743908 49.13776 18.743908 67.881669 0z"></path></svg>',this.tag="button"}return e.prototype.getValue=function(e){return""},e.prototype.isActive=function(e){return!1},e.prototype.isDisabled=function(e){return null==e.selection||null==Py.getSelectedNodeByType(e,"link")},e.prototype.exec=function(e,t){this.isDisabled(e)||jg.unwrapNodes(e,{match:function(e){return Py.checkNodeType(e,"link")}})},e}(),IN=function(){function e(){this.title=JE("link.view"),this.iconSvg=yx,this.tag="button"}return e.prototype.getSelectedLinkElem=function(e){var t=Py.getSelectedNodeByType(e,"link");return null==t?null:t},e.prototype.getValue=function(e){var t=this.getSelectedLinkElem(e);return t&&t.url||""},e.prototype.isActive=function(e){return!1},e.prototype.isDisabled=function(e){return null==e.selection||null==this.getSelectedLinkElem(e)},e.prototype.exec=function(e,t){if(!this.isDisabled(e)){if(!t||"string"!=typeof t)throw new Error("View link failed, link url is '".concat(t,"'"));window.open(t,"_blank")}},e}(),PN={checkLink:function(e,t){return!0},parseLinkUrl:function(e){return e}},_N={key:"insertLink",factory:function(){return new kN},config:PN},LN={key:"editLink",factory:function(){return new BN},config:PN},RN={key:"unLink",factory:function(){return new FN}},MN={key:"viewLink",factory:function(){return new IN}};var jN,HN,zN={selector:"a:not([data-w-e-type])",parseElemHtml:function(e,t,n){var r=im(e).text().replace(/\s+/gm," ");return t.length>0?{text:t.filter(function(e){return Cg.isText(e)}).map(function(e){return e.text}).join("")||r}:{text:r}}};var $N=b(function(){if(HN)return jN;HN=1,jN=function(r){if("string"!=typeof r)return!1;var o=r.match(e);if(!o)return!1;var i=o[1];if(!i)return!1;if(t.test(i)||n.test(i))return!0;return!1};var e=/^(?:\w+:)?\/\/(\S+)$/,t=/^localhost[\:?\d]*(?:[^\:?\d]\S*)?$/,n=/^[^\s\.]+\.\S{2,}$/;return jN}());var UN={type:"link",renderElem:function(e,t,n){var r=e,o=r.url,i=r.target;return BD("a",{href:o,target:void 0===i?"_blank":i},t)}},VN={renderElems:[UN],elemsToHtml:[DN],parseElemsHtml:[zN],menus:[_N,LN,RN,MN],editorPlugin:function(e){var t=e.isInline,n=e.insertData,r=e.normalizeNode,o=e;return o.isInline=function(e){return"link"===e.type||t(e)},o.insertData=function(e){var t=e.getData("text/plain");if($N(t)){if(/<img[^>]+>/.test(e.getData("text/html")))n(e);else if(!AN(o)){var r=o.selection;if(null!=r){var i=Kh.string(o,r);ON(o,i,t)}}}else n(e)},o.normalizeNode=function(e){var t=ev(e,2),n=t[0],i=t[1];return"link"!==Py.getNodeType(n)?r([n,i]):""===eg.string(n)?jg.removeNodes(o,{at:i}):r([n,i])},o}};var WN={selector:"p:not([data-w-e-type])",parseElemHtml:function(e,t,n){var r=im(e);return 0===(t=t.filter(function(e){return!!Cg.isText(e)||!!n.isInline(e)})).length&&(t=[{text:r.text().replace(/\s+/gm," ")}]),{type:"paragraph",children:t}}};function GN(e){var t=ev(Kh.nodes(e,{match:function(t){return e.children[0]===t},mode:"highest"}),1),n=t[0];if(null==n)return!1;var r=n[0];if(!$h.isElement(r))return!1;if("paragraph"===r.type)return!1;if(""!==eg.string(r))return!1;var o=r.children,i=void 0===o?[]:o;return!!Cg.isText(i[0])&&(jg.setNodes(e,{type:"paragraph"}),!0)}var qN={type:"paragraph",renderElem:function(e,t,n){return BD("p",null,t)}},KN={renderElems:[qN],elemsToHtml:[{type:"paragraph",elemToHtml:function(e,t){return""===t?"<p><br></p>":"<p>".concat(t,"</p>")}}],parseElemsHtml:[WN],editorPlugin:function(e){var t=e.deleteBackward,n=e.deleteForward,r=e;return r.deleteBackward=function(e){GN(r)||t(e)},r.deleteForward=function(e){GN(r)||n(e)},r}};function YN(e,t){if(null==e.selection)return!0;var n=ev(Kh.nodes(e,{match:function(t){return"pre"===Py.getNodeType(t)||!!Kh.isVoid(e,t)},universal:!0}),1);return!!n[0]}function XN(e,t){Object.keys(t).forEach(function(t){"text"!==t&&Kh.removeMark(e,t)})}var ZN=function(){function e(){this.marksNeedToRemove=[],this.tag="button"}return e.prototype.getValue=function(e){var t=this.mark,n=Kh.marks(e);if(n)return n[t];var r=ev(Kh.nodes(e,{match:function(e){return!0===e[t]}}),1);return!!r[0]},e.prototype.isActive=function(e){return!!this.getValue(e)},e.prototype.isDisabled=function(e){return YN(e,this.mark)},e.prototype.exec=function(e,t){var n=this.mark,r=this.marksNeedToRemove;t?e.removeMark(n):(e.addMark(n,!0),r&&r.forEach(function(t){return e.removeMark(t)}))},e}(),JN=function(e){function t(){var t=e.apply(this,tv([],ev(arguments),!1))||this;return t.mark="bold",t.title=JE("textStyle.bold"),t.iconSvg='<svg viewBox="0 0 1024 1024"><path d="M707.872 484.64A254.88 254.88 0 0 0 768 320c0-141.152-114.848-256-256-256H192v896h384c141.152 0 256-114.848 256-256a256.096 256.096 0 0 0-124.128-219.36zM384 192h101.504c55.968 0 101.504 57.408 101.504 128s-45.536 128-101.504 128H384V192z m159.008 640H384v-256h159.008c58.464 0 106.016 57.408 106.016 128s-47.552 128-106.016 128z"></path></svg>',t.hotkey="mod+b",t}return Kg(t,e),t}(ZN),QN=function(){function e(){this.title=JE("textStyle.clear"),this.iconSvg='<svg viewBox="0 0 1024 1024"><path d="M969.382408 288.738615l-319.401123-270.852152a67.074236 67.074236 0 0 0-96.459139 5.74922l-505.931379 574.922021a68.35184 68.35184 0 0 0-17.886463 47.910169 74.101061 74.101061 0 0 0 24.274486 47.910168l156.50655 132.232065h373.060512L975.131628 383.281347a67.074236 67.074236 0 0 0-5.74922-96.459139z m-440.134747 433.746725H264.144729l-90.071117-78.572676c-5.74922-5.74922-12.137243-12.137243-12.137243-17.886463a36.411728 36.411728 0 0 1 5.749221-24.274485l210.804741-240.828447 265.102932 228.691204z m-439.495945 180.781036h843.218964a60.047411 60.047411 0 1 1 0 120.733624H89.751716a60.047411 60.047411 0 1 1 0-120.733624z m0 0"></path></svg>',this.tag="button"}return e.prototype.getValue=function(e){return""},e.prototype.isActive=function(e){return!1},e.prototype.isDisabled=function(e){return YN(e)},e.prototype.exec=function(e,t){var n,r,o=Kh.nodes(e,{match:function(e){return Cg.isText(e)},universal:!0});try{for(var i=Qg(o),a=i.next();!a.done;a=i.next()){XN(e,a.value[0])}}catch(e){n={error:e}}finally{try{a&&!a.done&&(r=i.return)&&r.call(i)}finally{if(n)throw n.error}}},e}(),eB=function(e){function t(){var t=e.apply(this,tv([],ev(arguments),!1))||this;return t.mark="code",t.title=JE("textStyle.code"),t.iconSvg='<svg viewBox="0 0 1024 1024"><path d="M576 736l96 96 320-320L672 192l-96 96 224 224zM448 288l-96-96L32 512l320 320 96-96-224-224z"></path></svg>',t.hotkey="mod+e",t}return Kg(t,e),t}(ZN),tB=function(e){function t(){var t=e.apply(this,tv([],ev(arguments),!1))||this;return t.mark="italic",t.title=JE("textStyle.italic"),t.iconSvg='<svg viewBox="0 0 1024 1024"><path d="M896 64v64h-128L448 896h128v64H128v-64h128L576 128h-128V64z"></path></svg>',t.hotkey="mod+i",t}return Kg(t,e),t}(ZN),nB=function(e){function t(){var t=e.apply(this,tv([],ev(arguments),!1))||this;return t.mark="sub",t.marksNeedToRemove=["sup"],t.title=JE("textStyle.sub"),t.iconSvg='<svg viewBox="0 0 1024 1024"><path d="M768 910.016v50.016h128v64h-192v-146.016l128-60V768h-128v-64h192v146.016zM676 256h-136L352 444 164 256H28l256 256-256 256h136L352 580 540 768h136l-256-256z"></path></svg>',t.hotkey="",t}return Kg(t,e),t}(ZN),rB=function(e){function t(){var t=e.apply(this,tv([],ev(arguments),!1))||this;return t.mark="sup",t.marksNeedToRemove=["sub"],t.title=JE("textStyle.sup"),t.iconSvg='<svg viewBox="0 0 1024 1024"><path d="M768 206.016v50.016h128v64h-192V174.016l128-60V64h-128V0h192v146.016zM676 256h-136L352 444 164 256H28l256 256-256 256h136L352 580 540 768h136l-256-256z"></path></svg>',t.hotkey="",t}return Kg(t,e),t}(ZN),oB=function(e){function t(){var t=e.apply(this,tv([],ev(arguments),!1))||this;return t.mark="through",t.title=JE("textStyle.through"),t.iconSvg='<svg viewBox="0 0 1024 1024"><path d="M1024 512v64h-234.496c27.52 38.496 42.496 82.688 42.496 128 0 70.88-36.672 139.04-100.576 186.976C672.064 935.488 594.144 960 512 960s-160.064-24.512-219.424-69.024C228.64 843.04 192 774.88 192 704h128c0 69.376 87.936 128 192 128s192-58.624 192-128-87.936-128-192-128H0v-64h299.52a385.984 385.984 0 0 1-6.944-5.024C228.64 459.04 192 390.88 192 320s36.672-139.04 100.576-186.976C351.936 88.512 429.856 64 512 64s160.064 24.512 219.424 69.024C795.328 180.96 832 249.12 832 320h-128c0-69.376-87.936-128-192-128s-192 58.624-192 128 87.936 128 192 128c78.976 0 154.048 22.688 212.48 64H1024z"></path></svg>',t.hotkey="mod+shift+x",t}return Kg(t,e),t}(ZN),iB=function(e){function t(){var t=e.apply(this,tv([],ev(arguments),!1))||this;return t.mark="underline",t.title=JE("textStyle.underline"),t.iconSvg='<svg viewBox="0 0 1024 1024"><path d="M704 64l128 0 0 416c0 159.072-143.264 288-320 288s-320-128.928-320-288l0-416 128 0 0 416c0 40.16 18.24 78.688 51.36 108.512 36.896 33.216 86.848 51.488 140.64 51.488s103.744-18.304 140.64-51.488c33.12-29.792 51.36-68.352 51.36-108.512l0-416zM192 832l640 0 0 128-640 0z"></path></svg>',t.hotkey="mod+u",t}return Kg(t,e),t}(ZN);function aB(e,t){return 0!==e.length&&(!!e[0].matches(t)||e.find(t).length>0)}function sB(e,t){var n=t,r=e,o=r.bold,i=r.italic,a=r.underline,s=r.code,u=r.through,l=r.sub,c=r.sup;return o&&(n="<strong>".concat(n,"</strong>")),s&&(n="<code>".concat(n,"</code>")),i&&(n="<em>".concat(n,"</em>")),a&&(n="<u>".concat(n,"</u>")),u&&(n="<s>".concat(n,"</s>")),l&&(n="<sub>".concat(n,"</sub>")),c&&(n="<sup>".concat(n,"</sup>")),n}var uB={renderStyle:function(e,t){var n=e,r=n.bold,o=n.italic,i=n.underline,a=n.code,s=n.through,u=n.sub,l=n.sup,c=t;return r&&(c=BD("strong",null,c)),a&&(c=BD("code",null,c)),o&&(c=BD("em",null,c)),i&&(c=BD("u",null,c)),s&&(c=BD("s",null,c)),u&&(c=BD("sub",null,c)),l&&(c=BD("sup",null,c)),c},menus:[{key:"bold",factory:function(){return new JN}},{key:"underline",factory:function(){return new iB}},{key:"italic",factory:function(){return new tB}},{key:"through",factory:function(){return new oB}},{key:"code",factory:function(){return new eB}},{key:"sub",factory:function(){return new nB}},{key:"sup",factory:function(){return new rB}},{key:"clearStyle",factory:function(){return new QN}}],styleToHtml:function(e,t){if(!Cg.isText(e))return t;if(Dx(t))return sB(e,t);var n=im(t),r=n.html();return r=sB(e,r),n.html(r),wx(n)},parseStyleHtml:function(e,t,n){var r=im(e);if(!Cg.isText(t))return t;var o=t;return aB(r,"b,strong")&&(o.bold=!0),aB(r,"i,em")&&(o.italic=!0),aB(r,"u")&&(o.underline=!0),aB(r,"s,strike")&&(o.through=!0),aB(r,"sub")&&(o.sub=!0),aB(r,"sup")&&(o.sup=!0),aB(r,"code")&&(o.code=!0),o}};var lB={type:"todo",elemToHtml:function(e,t){var n=e.checked;return'<div data-w-e-type="todo"><input type="checkbox" disabled '.concat(n?"checked":"",">").concat(t,"</div>")}},cB=function(){function e(){this.title=JE("todo.todo"),this.iconSvg='<svg viewBox="0 0 1024 1024"><path d="M278.755556 403.911111l-79.644445 79.644445L455.111111 739.555556l568.888889-568.888889-79.644444-79.644445L455.111111 580.266667l-176.355555-176.355556zM910.222222 910.222222H113.777778V113.777778h568.888889V0H113.777778C51.2 0 0 51.2 0 113.777778v796.444444c0 62.577778 51.2 113.777778 113.777778 113.777778h796.444444c62.577778 0 113.777778-51.2 113.777778-113.777778V455.111111h-113.777778v455.111111z"></path></svg>',this.tag="button"}return e.prototype.getValue=function(e){return""},e.prototype.isActive=function(e){return!!Py.getSelectedNodeByType(e,"todo")},e.prototype.isDisabled=function(e){return null==e.selection||!!Py.getSelectedElems(e).some(function(t){if(Kh.isVoid(e,t)&&Kh.isBlock(e,t))return!0;var n=t.type;return!!["pre","table","list-item"].includes(n)})},e.prototype.exec=function(e,t){var n=this.isActive(e);jg.setNodes(e,{type:n?"paragraph":"todo"})},e}();var dB={selector:'div[data-w-e-type="todo"]',parseElemHtml:function(e,t,n){var r=im(e);0===(t=t.filter(function(e){return!!Cg.isText(e)||!!n.isInline(e)})).length&&(t=[{text:r.text().replace(/\s+/gm," ")}]);var o=!1;return null!=r.find('input[type="checkbox"]').attr("checked")&&(o=!0),{type:"todo",checked:o,children:t}}};var fB={type:"todo",renderElem:function(e,t,n){var r=!1;n.isDisabled()&&(r=!0);var o=BD("div",{style:{margin:"5px 0"}},BD("span",{contentEditable:!1,style:{marginRight:"0.5em"}},BD("input",{type:"checkbox",checked:e.checked,disabled:r,on:{change:function(t){var r=Py.findPath(n,e),o={checked:t.target.checked};jg.setNodes(n,o,{at:r})}}})),BD("span",null,t));return o}},pB={renderElems:[fB],elemsToHtml:[lB],preParseHtml:[{selector:"ul.w-e-todo",preParseHtml:function(e){var t=im(e).find("li"),n=im('<div data-w-e-type="todo"></div>'),r=t.find("input[type]");return n.append(r),t.children()[0].remove(),n[0].innerHTML+=t[0].innerHTML,n[0]}}],parseElemsHtml:[dB],menus:[{key:"todo",factory:function(){return new cB}}],editorPlugin:function(e){var t=e.deleteBackward,n=e;return n.deleteBackward=function(n){var r=e.selection;if(r&&fg.isCollapsed(r)){var o=Py.getSelectedNodeByType(e,"todo");if(o&&0===eg.string(o).length)return void jg.setNodes(e,{type:"paragraph"},{mode:"highest"})}t(n)},n}},hB=function(){function e(){this.title=JE("undo.redo"),this.iconSvg='<svg viewBox="0 0 1024 1024"><path d="M0.00032 576a510.72 510.72 0 0 0 173.344 384l84.672-96A383.136 383.136 0 0 1 128.00032 576C128.00032 363.936 299.93632 192 512.00032 192c106.048 0 202.048 42.976 271.52 112.48L640.00032 448h384V64l-149.984 149.984A510.272 510.272 0 0 0 512.00032 64C229.21632 64 0.00032 293.216 0.00032 576z"></path></svg>',this.tag="button"}return e.prototype.getValue=function(e){return""},e.prototype.isActive=function(e){return!1},e.prototype.isDisabled=function(e){return null==e.selection},e.prototype.exec=function(e,t){"function"==typeof e.redo&&e.redo()},e}(),gB=function(){function e(){this.title=JE("undo.undo"),this.iconSvg='<svg viewBox="0 0 1024 1024"><path d="M512 64A510.272 510.272 0 0 0 149.984 213.984L0.032 64v384h384L240.512 304.48A382.784 382.784 0 0 1 512.032 192c212.064 0 384 171.936 384 384 0 114.688-50.304 217.632-130.016 288l84.672 96a510.72 510.72 0 0 0 173.344-384c0-282.784-229.216-512-512-512z"></path></svg>',this.tag="button"}return e.prototype.getValue=function(e){return""},e.prototype.isActive=function(e){return!1},e.prototype.isDisabled=function(e){return null==e.selection},e.prototype.exec=function(e,t){"function"==typeof e.undo&&e.undo()},e}(),vB=[uB,Ux,tO,pN,bN,CN,lN,Kx,Xx,VN,Lx,Bx,jO,KN,pB,rO,{menus:[{key:"redo",factory:function(){return new hB}},{key:"undo",factory:function(){return new gB}}]},iO,Wx];KE("en",{highLightModule:{selectLang:"Language"}}),KE("zh-CN",{highLightModule:{selectLang:"选择语言"}});var mB,yB={exports:{}};var bB=(mB||(mB=1,function(e){var t=function(e){var t=/(?:^|\s)lang(?:uage)?-([\w-]+)(?=\s|$)/i,n=0,r={},o={manual:e.Prism&&e.Prism.manual,disableWorkerMessageHandler:e.Prism&&e.Prism.disableWorkerMessageHandler,util:{encode:function e(t){return t instanceof i?new i(t.type,e(t.content),t.alias):Array.isArray(t)?t.map(e):t.replace(/&/g,"&").replace(/</g,"<").replace(/\u00a0/g," ")},type:function(e){return Object.prototype.toString.call(e).slice(8,-1)},objId:function(e){return e.__id||Object.defineProperty(e,"__id",{value:++n}),e.__id},clone:function e(t,n){var r,i;switch(n=n||{},o.util.type(t)){case"Object":if(i=o.util.objId(t),n[i])return n[i];for(var a in r={},n[i]=r,t)t.hasOwnProperty(a)&&(r[a]=e(t[a],n));return r;case"Array":return i=o.util.objId(t),n[i]?n[i]:(r=[],n[i]=r,t.forEach(function(t,o){r[o]=e(t,n)}),r);default:return t}},getLanguage:function(e){for(;e;){var n=t.exec(e.className);if(n)return n[1].toLowerCase();e=e.parentElement}return"none"},setLanguage:function(e,n){e.className=e.className.replace(RegExp(t,"gi"),""),e.classList.add("language-"+n)},currentScript:function(){if("undefined"==typeof document)return null;if(document.currentScript&&"SCRIPT"===document.currentScript.tagName)return document.currentScript;try{throw new Error}catch(r){var e=(/at [^(\r\n]*\((.*):[^:]+:[^:]+\)$/i.exec(r.stack)||[])[1];if(e){var t=document.getElementsByTagName("script");for(var n in t)if(t[n].src==e)return t[n]}return null}},isActive:function(e,t,n){for(var r="no-"+t;e;){var o=e.classList;if(o.contains(t))return!0;if(o.contains(r))return!1;e=e.parentElement}return!!n}},languages:{plain:r,plaintext:r,text:r,txt:r,extend:function(e,t){var n=o.util.clone(o.languages[e]);for(var r in t)n[r]=t[r];return n},insertBefore:function(e,t,n,r){var i=(r=r||o.languages)[e],a={};for(var s in i)if(i.hasOwnProperty(s)){if(s==t)for(var u in n)n.hasOwnProperty(u)&&(a[u]=n[u]);n.hasOwnProperty(s)||(a[s]=i[s])}var l=r[e];return r[e]=a,o.languages.DFS(o.languages,function(t,n){n===l&&t!=e&&(this[t]=a)}),a},DFS:function e(t,n,r,i){i=i||{};var a=o.util.objId;for(var s in t)if(t.hasOwnProperty(s)){n.call(t,s,t[s],r||s);var u=t[s],l=o.util.type(u);"Object"!==l||i[a(u)]?"Array"!==l||i[a(u)]||(i[a(u)]=!0,e(u,n,s,i)):(i[a(u)]=!0,e(u,n,null,i))}}},plugins:{},highlightAll:function(e,t){o.highlightAllUnder(document,e,t)},highlightAllUnder:function(e,t,n){var r={callback:n,container:e,selector:'code[class*="language-"], [class*="language-"] code, code[class*="lang-"], [class*="lang-"] code'};o.hooks.run("before-highlightall",r),r.elements=Array.prototype.slice.apply(r.container.querySelectorAll(r.selector)),o.hooks.run("before-all-elements-highlight",r);for(var i,a=0;i=r.elements[a++];)o.highlightElement(i,!0===t,r.callback)},highlightElement:function(t,n,r){var i=o.util.getLanguage(t),a=o.languages[i];o.util.setLanguage(t,i);var s=t.parentElement;s&&"pre"===s.nodeName.toLowerCase()&&o.util.setLanguage(s,i);var u={element:t,language:i,grammar:a,code:t.textContent};function l(e){u.highlightedCode=e,o.hooks.run("before-insert",u),u.element.innerHTML=u.highlightedCode,o.hooks.run("after-highlight",u),o.hooks.run("complete",u),r&&r.call(u.element)}if(o.hooks.run("before-sanity-check",u),(s=u.element.parentElement)&&"pre"===s.nodeName.toLowerCase()&&!s.hasAttribute("tabindex")&&s.setAttribute("tabindex","0"),!u.code)return o.hooks.run("complete",u),void(r&&r.call(u.element));if(o.hooks.run("before-highlight",u),u.grammar)if(n&&e.Worker){var c=new Worker(o.filename);c.onmessage=function(e){l(e.data)},c.postMessage(JSON.stringify({language:u.language,code:u.code,immediateClose:!0}))}else l(o.highlight(u.code,u.grammar,u.language));else l(o.util.encode(u.code))},highlight:function(e,t,n){var r={code:e,grammar:t,language:n};if(o.hooks.run("before-tokenize",r),!r.grammar)throw new Error('The language "'+r.language+'" has no grammar.');return r.tokens=o.tokenize(r.code,r.grammar),o.hooks.run("after-tokenize",r),i.stringify(o.util.encode(r.tokens),r.language)},tokenize:function(e,t){var n=t.rest;if(n){for(var r in n)t[r]=n[r];delete t.rest}var o=new u;return l(o,o.head,e),s(e,o,t,o.head,0),function(e){for(var t=[],n=e.head.next;n!==e.tail;)t.push(n.value),n=n.next;return t}(o)},hooks:{all:{},add:function(e,t){var n=o.hooks.all;n[e]=n[e]||[],n[e].push(t)},run:function(e,t){var n=o.hooks.all[e];if(n&&n.length)for(var r,i=0;r=n[i++];)r(t)}},Token:i};function i(e,t,n,r){this.type=e,this.content=t,this.alias=n,this.length=0|(r||"").length}function a(e,t,n,r){e.lastIndex=t;var o=e.exec(n);if(o&&r&&o[1]){var i=o[1].length;o.index+=i,o[0]=o[0].slice(i)}return o}function s(e,t,n,r,u,d){for(var f in n)if(n.hasOwnProperty(f)&&n[f]){var p=n[f];p=Array.isArray(p)?p:[p];for(var h=0;h<p.length;++h){if(d&&d.cause==f+","+h)return;var g=p[h],v=g.inside,m=!!g.lookbehind,y=!!g.greedy,b=g.alias;if(y&&!g.pattern.global){var E=g.pattern.toString().match(/[imsuy]*$/)[0];g.pattern=RegExp(g.pattern.source,E+"g")}for(var C=g.pattern||g,D=r.next,w=u;D!==t.tail&&!(d&&w>=d.reach);w+=D.value.length,D=D.next){var S=D.value;if(t.length>e.length)return;if(!(S instanceof i)){var A,x=1;if(y){if(!(A=a(C,w,e,m))||A.index>=e.length)break;var O=A.index,N=A.index+A[0].length,B=w;for(B+=D.value.length;O>=B;)B+=(D=D.next).value.length;if(w=B-=D.value.length,D.value instanceof i)continue;for(var T=D;T!==t.tail&&(B<N||"string"==typeof T.value);T=T.next)x++,B+=T.value.length;x--,S=e.slice(w,B),A.index-=w}else if(!(A=a(C,0,S,m)))continue;O=A.index;var k=A[0],F=S.slice(0,O),I=S.slice(O+k.length),P=w+S.length;d&&P>d.reach&&(d.reach=P);var _=D.prev;if(F&&(_=l(t,_,F),w+=F.length),c(t,_,x),D=l(t,_,new i(f,v?o.tokenize(k,v):k,b,k)),I&&l(t,D,I),x>1){var L={cause:f+","+h,reach:P};s(e,t,n,D.prev,w,L),d&&L.reach>d.reach&&(d.reach=L.reach)}}}}}}function u(){var e={value:null,prev:null,next:null},t={value:null,prev:e,next:null};e.next=t,this.head=e,this.tail=t,this.length=0}function l(e,t,n){var r=t.next,o={value:n,prev:t,next:r};return t.next=o,r.prev=o,e.length++,o}function c(e,t,n){for(var r=t.next,o=0;o<n&&r!==e.tail;o++)r=r.next;t.next=r,r.prev=t,e.length-=o}if(e.Prism=o,i.stringify=function e(t,n){if("string"==typeof t)return t;if(Array.isArray(t)){var r="";return t.forEach(function(t){r+=e(t,n)}),r}var i={type:t.type,content:e(t.content,n),tag:"span",classes:["token",t.type],attributes:{},language:n},a=t.alias;a&&(Array.isArray(a)?Array.prototype.push.apply(i.classes,a):i.classes.push(a)),o.hooks.run("wrap",i);var s="";for(var u in i.attributes)s+=" "+u+'="'+(i.attributes[u]||"").replace(/"/g,""")+'"';return"<"+i.tag+' class="'+i.classes.join(" ")+'"'+s+">"+i.content+"</"+i.tag+">"},!e.document)return e.addEventListener?(o.disableWorkerMessageHandler||e.addEventListener("message",function(t){var n=JSON.parse(t.data),r=n.language,i=n.code,a=n.immediateClose;e.postMessage(o.highlight(i,o.languages[r],r)),a&&e.close()},!1),o):o;var d=o.util.currentScript();function f(){o.manual||o.highlightAll()}if(d&&(o.filename=d.src,d.hasAttribute("data-manual")&&(o.manual=!0)),!o.manual){var p=document.readyState;"loading"===p||"interactive"===p&&d&&d.defer?document.addEventListener("DOMContentLoaded",f):window.requestAnimationFrame?window.requestAnimationFrame(f):window.setTimeout(f,16)}return o}("undefined"!=typeof window?window:"undefined"!=typeof WorkerGlobalScope&&self instanceof WorkerGlobalScope?self:{});
|
|
18
|
+
*/function i(e,t){const r=/\$/g;let n=[e];if(null==t)return n;for(const e of Object.keys(t))if("_"!==e){let i=t[e];"string"==typeof i&&(i=r[Symbol.replace](i,"$$$$")),n=o(n,new RegExp(`%\\{${e}\\}`,"g"),i)}return n}var a=r("apply");function s(e){if(null==e||!e.strings)return;const t=this.locale;this.locale={...t,strings:{...t.strings,...e.strings}},this.locale.pluralize=e.pluralize||t.pluralize}return yE=class{constructor(t){Object.defineProperty(this,a,{value:s}),this.locale={strings:{},pluralize:e=>1===e?0:1},Array.isArray(t)?t.forEach(e(this,a)[a],this):e(this,a)[a](t)}translate(e,t){return this.translateArray(e,t).join("")}translateArray(e,t){if(!n(this.locale.strings,e))throw new Error(`missing string: ${e}`);const r=this.locale.strings[e];if("object"==typeof r){if(t&&void 0!==t.smart_count){return i(r[this.locale.pluralize(t.smart_count)],t)}throw new Error("Attempted to use a string with plural forms, but no value was given for %{smart_count}")}return i(r,t)}},yE}function WE(){return CE||(CE=1,DE=function(){var e={},t=e._fns={};return e.emit=function(e,r,n,o,i,a,s){var u=function(e){var r=t[e]?t[e]:[],n=e.indexOf(":"),o=-1===n?[e]:[e.substring(0,n),e.substring(n+1)],i=Object.keys(t),a=0,s=i.length;for(;a<s;a++){var u=i[a];if("*"===u&&(r=r.concat(t[u])),2===o.length&&o[0]===u){r=r.concat(t[u]);break}}return r}(e);u.length&&function(e,t,r){var n=0,o=t.length;for(;n<o&&t[n];n++)t[n].event=e,t[n].apply(t[n],r)}(e,u,[r,n,o,i,a,s])},e.on=function(e,r){t[e]||(t[e]=[]),t[e].push(r)},e.once=function(t,r){this.on(t,function n(){r.apply(this,arguments),e.off(t,n)})},e.off=function(e,t){var r=[];if(e&&t)for(var n=this._fns[e],o=0,i=n?n.length:0;o<i;o++)n[o]!==t&&r.push(n[o]);r.length?this._fns[e]=r:delete this._fns[e]},e}),DE}function GE(){if(EE)return wE;EE=1;var e=0;function t(t){return"__private_"+e+++"_"+t}var r=t("publish");class n{constructor(){Object.defineProperty(this,r,{value:o}),this.state={},this.callbacks=[]}getState(){return this.state}setState(e){const t={...this.state},n={...this.state,...e};this.state=n,function(e,t){if(!Object.prototype.hasOwnProperty.call(e,t))throw new TypeError("attempted to use private field on non-instance");return e}(this,r)[r](t,n,e)}subscribe(e){return this.callbacks.push(e),()=>{this.callbacks.splice(this.callbacks.indexOf(e),1)}}}function o(){for(var e=arguments.length,t=new Array(e),r=0;r<e;r++)t[r]=arguments[r];this.callbacks.forEach(e=>{e(...t)})}return n.VERSION="2.1.1",wE=function(){return new n}}function YE(){if(xE)return AE;return xE=1,AE=function(e){const t=e.lastIndexOf(".");return-1===t||t===e.length-1?{name:e,extension:void 0}:{name:e.slice(0,t),extension:e.slice(t+1)}}}function KE(){return SE?BE:(SE=1,BE={md:"text/markdown",markdown:"text/markdown",mp4:"video/mp4",mp3:"audio/mp3",svg:"image/svg+xml",jpg:"image/jpeg",png:"image/png",gif:"image/gif",heic:"image/heic",heif:"image/heif",yaml:"text/yaml",yml:"text/yaml",csv:"text/csv",tsv:"text/tab-separated-values",tab:"text/tab-separated-values",avi:"video/x-msvideo",mks:"video/x-matroska",mkv:"video/x-matroska",mov:"video/quicktime",dicom:"application/dicom",doc:"application/msword",docm:"application/vnd.ms-word.document.macroenabled.12",docx:"application/vnd.openxmlformats-officedocument.wordprocessingml.document",dot:"application/msword",dotm:"application/vnd.ms-word.template.macroenabled.12",dotx:"application/vnd.openxmlformats-officedocument.wordprocessingml.template",xla:"application/vnd.ms-excel",xlam:"application/vnd.ms-excel.addin.macroenabled.12",xlc:"application/vnd.ms-excel",xlf:"application/x-xliff+xml",xlm:"application/vnd.ms-excel",xls:"application/vnd.ms-excel",xlsb:"application/vnd.ms-excel.sheet.binary.macroenabled.12",xlsm:"application/vnd.ms-excel.sheet.macroenabled.12",xlsx:"application/vnd.openxmlformats-officedocument.spreadsheetml.sheet",xlt:"application/vnd.ms-excel",xltm:"application/vnd.ms-excel.template.macroenabled.12",xltx:"application/vnd.openxmlformats-officedocument.spreadsheetml.template",xlw:"application/vnd.ms-excel",txt:"text/plain",text:"text/plain",conf:"text/plain",log:"text/plain",pdf:"application/pdf",zip:"application/zip","7z":"application/x-7z-compressed",rar:"application/x-rar-compressed",tar:"application/x-tar",gz:"application/gzip",dmg:"application/x-apple-diskimage"})}function XE(){if(zE)return _E;zE=1;var e=uE(),t=sE(),r=$E();let n,o;function i(e,t){if(!Object.prototype.hasOwnProperty.call(e,t))throw new TypeError("attempted to use private field on non-instance");return e}var a=0;function s(e){return"__private_"+a+++"_"+e}const u=qE(),l=WE(),c=xC(),d=GE(),h=function(){if(kE)return FE;kE=1;const e=YE(),t=KE();return FE=function(r){var n;if(r.type)return r.type;const o=r.name?null==(n=e(r.name).extension)?void 0:n.toLowerCase():null;return o&&o in t?t[o]:"application/octet-stream"}}(),f=YE(),p=function(){if(TE)return OE;function e(e){let t="";return e.replace(/[^A-Z0-9]/gi,e=>(t+=`-${function(e){return e.charCodeAt(0).toString(32)}(e)}`,"/"))+t}return TE=1,OE=function(t){let r="uppy";return"string"==typeof t.name&&(r+=`-${e(t.name.toLowerCase())}`),void 0!==t.type&&(r+=`-${t.type}`),t.meta&&"string"==typeof t.meta.relativePath&&(r+=`-${e(t.meta.relativePath.toLowerCase())}`),void 0!==t.data.size&&(r+=`-${t.data.size}`),void 0!==t.data.lastModified&&(r+=`-${t.data.lastModified}`),r}}(),g=(PE||(PE=1,NE=function(e){if(null==e&&"undefined"!=typeof navigator&&(e=navigator.userAgent),!e)return!0;const t=/Edge\/(\d+\.\d+)/.exec(e);if(!t)return!0;const r=t[1];let[n,o]=r.split(".");return n=parseInt(n,10),o=parseInt(o,10),n<15||15===n&&o<15063||n>18||18===n&&o>=18218}),NE),m=IE?ME:(IE=1,ME=function(e,t){return t.name?t.name:"image"===e.split("/")[0]?`${e.split("/")[0]}.${e.split("/")[1]}`:"noname"}),v=LE?RE:(LE=1,RE={strings:{addBulkFilesFailed:{0:"Failed to add %{smart_count} file due to an internal error",1:"Failed to add %{smart_count} files due to internal errors"},youCanOnlyUploadX:{0:"You can only upload %{smart_count} file",1:"You can only upload %{smart_count} files"},youHaveToAtLeastSelectX:{0:"You have to select at least %{smart_count} file",1:"You have to select at least %{smart_count} files"},exceedsSize:"%{file} exceeds maximum allowed size of %{size}",missingRequiredMetaField:"Missing required meta fields",missingRequiredMetaFieldOnFile:"Missing required meta fields in %{fileName}",inferiorSize:"This file is smaller than the allowed size of %{size}",youCanOnlyUploadFileTypes:"You can only upload: %{types}",noMoreFilesAllowed:"Cannot add more files",noDuplicates:"Cannot add the duplicate file '%{fileName}', it already exists",companionError:"Connection with Companion failed",authAborted:"Authentication aborted",companionUnauthorizeHint:"To unauthorize to your %{provider} account, please go to %{url}",failedToUpload:"Failed to upload %{file}",noInternetConnection:"No Internet connection",connectedToInternet:"Connected to the Internet",noFilesFound:"You have no files or folders here",selectX:{0:"Select %{smart_count}",1:"Select %{smart_count}"},allFilesFromFolderNamed:"All files from folder %{name}",openFolderNamed:"Open folder %{name}",cancel:"Cancel",logOut:"Log out",filter:"Filter",resetFilter:"Reset filter",loading:"Loading...",authenticateWithTitle:"Please authenticate with %{pluginName} to select files",authenticateWith:"Connect to %{pluginName}",signInWithGoogle:"Sign in with Google",searchImages:"Search for images",enterTextToSearch:"Enter text to search for images",search:"Search",emptyFolderAdded:"No files were added from empty folder",folderAlreadyAdded:'The folder "%{folder}" was already added',folderAdded:{0:"Added %{smart_count} file from %{folder}",1:"Added %{smart_count} files from %{folder}"}}});var y=s("plugins"),b=s("restricter"),D=s("storeUnsubscribe"),C=s("emitter"),w=s("preProcessors"),E=s("uploaders"),A=s("postProcessors"),x=s("informAndEmit"),B=s("checkRequiredMetaFieldsOnFile"),S=s("checkRequiredMetaFields"),F=s("assertNewUploadAllowed"),k=s("checkAndCreateFileStateObject"),O=s("startIfAutoProceed"),T=s("addListeners"),N=s("updateOnlineStatus"),P=s("createUpload"),M=s("getUpload"),I=s("removeUpload"),R=s("runUpload");n=Symbol.for("uppy test: getPlugins"),o=Symbol.for("uppy test: createUpload");class L{constructor(e){Object.defineProperty(this,R,{value:Y}),Object.defineProperty(this,I,{value:G}),Object.defineProperty(this,M,{value:W}),Object.defineProperty(this,P,{value:q}),Object.defineProperty(this,T,{value:U}),Object.defineProperty(this,O,{value:$}),Object.defineProperty(this,k,{value:V}),Object.defineProperty(this,F,{value:H}),Object.defineProperty(this,S,{value:j}),Object.defineProperty(this,B,{value:z}),Object.defineProperty(this,x,{value:_}),Object.defineProperty(this,y,{writable:!0,value:Object.create(null)}),Object.defineProperty(this,b,{writable:!0,value:void 0}),Object.defineProperty(this,D,{writable:!0,value:void 0}),Object.defineProperty(this,C,{writable:!0,value:l()}),Object.defineProperty(this,w,{writable:!0,value:new Set}),Object.defineProperty(this,E,{writable:!0,value:new Set}),Object.defineProperty(this,A,{writable:!0,value:new Set}),Object.defineProperty(this,N,{writable:!0,value:this.updateOnlineStatus.bind(this)}),this.defaultLocale=v;const n={id:"uppy",autoProceed:!1,allowMultipleUploads:!0,allowMultipleUploadBatches:!0,debug:!1,restrictions:r.defaultOptions,meta:{},onBeforeFileAdded:e=>e,onBeforeUpload:e=>e,store:d(),logger:t.justErrorsLogger,infoTimeout:5e3};this.opts={...n,...e,restrictions:{...n.restrictions,...e&&e.restrictions}},e&&e.logger&&e.debug?this.log("You are using a custom `logger`, but also set `debug: true`, which uses built-in logger to output logs to console. Ignoring `debug: true` and using your custom `logger`.","warning"):e&&e.debug&&(this.opts.logger=t.debugLogger),this.log(`Using Core v${this.constructor.VERSION}`),this.i18nInit(),this.calculateProgress=c(this.calculateProgress.bind(this),500,{leading:!0,trailing:!0}),this.store=this.opts.store,this.setState({plugins:{},files:{},currentUploads:{},allowNewUpload:!0,capabilities:{uploadProgress:g(),individualCancellation:!0,resumableUploads:!1},totalProgress:0,meta:{...this.opts.meta},info:[],recoveredState:null}),i(this,b)[b]=new r.Restricter(()=>this.opts,this.i18n),i(this,D)[D]=this.store.subscribe((e,t,r)=>{this.emit("state-update",e,t,r),this.updateAll(t)}),this.opts.debug&&"undefined"!=typeof window&&(window[this.opts.id]=this),i(this,T)[T]()}emit(e){for(var t=arguments.length,r=new Array(t>1?t-1:0),n=1;n<t;n++)r[n-1]=arguments[n];i(this,C)[C].emit(e,...r)}on(e,t){return i(this,C)[C].on(e,t),this}once(e,t){return i(this,C)[C].once(e,t),this}off(e,t){return i(this,C)[C].off(e,t),this}updateAll(e){this.iteratePlugins(t=>{t.update(e)})}setState(e){this.store.setState(e)}getState(){return this.store.getState()}get state(){return this.getState()}setFileState(e,t){if(!this.getState().files[e])throw new Error(`Can’t set state for ${e} (the file could have been removed)`);this.setState({files:{...this.getState().files,[e]:{...this.getState().files[e],...t}}})}i18nInit(){const e=new u([this.defaultLocale,this.opts.locale]);this.i18n=e.translate.bind(e),this.i18nArray=e.translateArray.bind(e),this.locale=e.locale}setOptions(e){this.opts={...this.opts,...e,restrictions:{...this.opts.restrictions,...e&&e.restrictions}},e.meta&&this.setMeta(e.meta),this.i18nInit(),e.locale&&this.iteratePlugins(e=>{e.setOptions()}),this.setState()}resetProgress(){const e={percentage:0,bytesUploaded:0,uploadComplete:!1,uploadStarted:null},t={...this.getState().files},r={};Object.keys(t).forEach(n=>{const o={...t[n]};o.progress={...o.progress,...e},r[n]=o}),this.setState({files:r,totalProgress:0}),this.emit("reset-progress")}addPreProcessor(e){i(this,w)[w].add(e)}removePreProcessor(e){return i(this,w)[w].delete(e)}addPostProcessor(e){i(this,A)[A].add(e)}removePostProcessor(e){return i(this,A)[A].delete(e)}addUploader(e){i(this,E)[E].add(e)}removeUploader(e){return i(this,E)[E].delete(e)}setMeta(e){const t={...this.getState().meta,...e},r={...this.getState().files};Object.keys(r).forEach(t=>{r[t]={...r[t],meta:{...r[t].meta,...e}}}),this.log("Adding metadata:"),this.log(e),this.setState({meta:t,files:r})}setFileMeta(e,t){const r={...this.getState().files};if(!r[e])return void this.log("Was trying to set metadata for a file that has been removed: ",e);const n={...r[e].meta,...t};r[e]={...r[e],meta:n},this.setState({files:r})}getFile(e){return this.getState().files[e]}getFiles(){const{files:e}=this.getState();return Object.values(e)}getObjectOfFilesPerState(){const{files:e,totalProgress:t,error:r}=this.getState(),n=Object.values(e),o=n.filter(e=>{let{progress:t}=e;return!t.uploadComplete&&t.uploadStarted}),i=n.filter(e=>!e.progress.uploadStarted),a=n.filter(e=>e.progress.uploadStarted||e.progress.preprocess||e.progress.postprocess),s=n.filter(e=>e.progress.uploadStarted),u=n.filter(e=>e.isPaused),l=n.filter(e=>e.progress.uploadComplete),c=n.filter(e=>e.error),d=o.filter(e=>!e.isPaused),h=n.filter(e=>e.progress.preprocess||e.progress.postprocess);return{newFiles:i,startedFiles:a,uploadStartedFiles:s,pausedFiles:u,completeFiles:l,erroredFiles:c,inProgressFiles:o,inProgressNotPausedFiles:d,processingFiles:h,isUploadStarted:s.length>0,isAllComplete:100===t&&l.length===n.length&&0===h.length,isAllErrored:!!r&&c.length===n.length,isAllPaused:0!==o.length&&u.length===o.length,isUploadInProgress:o.length>0,isSomeGhost:n.some(e=>e.isGhost)}}validateRestrictions(e,t){void 0===t&&(t=this.getFiles());try{return i(this,b)[b].validate(e,t),{result:!0}}catch(e){return{result:!1,reason:e.message}}}checkIfFileAlreadyExists(e){const{files:t}=this.getState();return!(!t[e]||t[e].isGhost)}addFile(e){i(this,F)[F](e);const{files:t}=this.getState();let r=i(this,k)[k](t,e);return t[r.id]&&t[r.id].isGhost&&(r={...t[r.id],data:e.data,isGhost:!1},this.log(`Replaced the blob in the restored ghost file: ${r.name}, ${r.id}`)),this.setState({files:{...t,[r.id]:r}}),this.emit("file-added",r),this.emit("files-added",[r]),this.log(`Added file: ${r.name}, ${r.id}, mime type: ${r.type}`),i(this,O)[O](),r.id}addFiles(e){i(this,F)[F]();const t={...this.getState().files},r=[],n=[];for(let o=0;o<e.length;o++)try{let n=i(this,k)[k](t,e[o]);t[n.id]&&t[n.id].isGhost&&(n={...t[n.id],data:e[o].data,isGhost:!1},this.log(`Replaced blob in a ghost file: ${n.name}, ${n.id}`)),t[n.id]=n,r.push(n)}catch(e){e.isRestriction||n.push(e)}if(this.setState({files:t}),r.forEach(e=>{this.emit("file-added",e)}),this.emit("files-added",r),r.length>5?this.log(`Added batch of ${r.length} files`):Object.keys(r).forEach(e=>{this.log(`Added file: ${r[e].name}\n id: ${r[e].id}\n type: ${r[e].type}`)}),r.length>0&&i(this,O)[O](),n.length>0){let e="Multiple errors occurred while adding files:\n";if(n.forEach(t=>{e+=`\n * ${t.message}`}),this.info({message:this.i18n("addBulkFilesFailed",{smart_count:n.length}),details:e},"error",this.opts.infoTimeout),"function"==typeof AggregateError)throw new AggregateError(n,e);{const t=new Error(e);throw t.errors=n,t}}}removeFiles(e,t){const{files:r,currentUploads:n}=this.getState(),o={...r},i={...n},a=Object.create(null);function s(e){return void 0===a[e]}e.forEach(e=>{r[e]&&(a[e]=r[e],delete o[e])}),Object.keys(i).forEach(e=>{const t=n[e].fileIDs.filter(s);if(0===t.length)return void delete i[e];const{capabilities:r}=this.getState();if(t.length!==n[e].fileIDs.length&&!r.individualCancellation)throw new Error("individualCancellation is disabled");i[e]={...n[e],fileIDs:t}});const u={currentUploads:i,files:o};0===Object.keys(o).length&&(u.allowNewUpload=!0,u.error=null,u.recoveredState=null),this.setState(u),this.calculateTotalProgress();const l=Object.keys(a);l.forEach(e=>{this.emit("file-removed",a[e],t)}),l.length>5?this.log(`Removed ${l.length} files`):this.log(`Removed files: ${l.join(", ")}`)}removeFile(e,t){void 0===t&&(t=null),this.removeFiles([e],t)}pauseResume(e){if(!this.getState().capabilities.resumableUploads||this.getFile(e).uploadComplete)return;const t=!(this.getFile(e).isPaused||!1);return this.setFileState(e,{isPaused:t}),this.emit("upload-pause",e,t),t}pauseAll(){const e={...this.getState().files};Object.keys(e).filter(t=>!e[t].progress.uploadComplete&&e[t].progress.uploadStarted).forEach(t=>{const r={...e[t],isPaused:!0};e[t]=r}),this.setState({files:e}),this.emit("pause-all")}resumeAll(){const e={...this.getState().files};Object.keys(e).filter(t=>!e[t].progress.uploadComplete&&e[t].progress.uploadStarted).forEach(t=>{const r={...e[t],isPaused:!1,error:null};e[t]=r}),this.setState({files:e}),this.emit("resume-all")}retryAll(){const e={...this.getState().files},t=Object.keys(e).filter(t=>e[t].error);if(t.forEach(t=>{const r={...e[t],isPaused:!1,error:null};e[t]=r}),this.setState({files:e,error:null}),this.emit("retry-all",t),0===t.length)return Promise.resolve({successful:[],failed:[]});const r=i(this,P)[P](t,{forceAllowNewUpload:!0});return i(this,R)[R](r)}cancelAll(e){let{reason:t="user"}=void 0===e?{}:e;if(this.emit("cancel-all",{reason:t}),"user"===t){const{files:e}=this.getState(),t=Object.keys(e);t.length&&this.removeFiles(t,"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 t=i(this,P)[P]([e],{forceAllowNewUpload:!0});return i(this,R)[R](t)}reset(){this.cancelAll(...arguments)}logout(){this.iteratePlugins(e=>{e.provider&&e.provider.logout&&e.provider.logout()})}calculateProgress(e,t){if(null==e||!this.getFile(e.id))return void this.log(`Not setting progress for a file that has been removed: ${null==e?void 0:e.id}`);const r=Number.isFinite(t.bytesTotal)&&t.bytesTotal>0;this.setFileState(e.id,{progress:{...this.getFile(e.id).progress,bytesUploaded:t.bytesUploaded,bytesTotal:t.bytesTotal,percentage:r?Math.round(t.bytesUploaded/t.bytesTotal*100):0}}),this.calculateTotalProgress()}calculateTotalProgress(){const e=this.getFiles().filter(e=>e.progress.uploadStarted||e.progress.preprocess||e.progress.postprocess);if(0===e.length)return this.emit("progress",0),void this.setState({totalProgress:0});const t=e.filter(e=>null!=e.progress.bytesTotal),r=e.filter(e=>null==e.progress.bytesTotal);if(0===t.length){const t=100*e.length,n=r.reduce((e,t)=>e+t.progress.percentage,0),o=Math.round(n/t*100);return void this.setState({totalProgress:o})}let n=t.reduce((e,t)=>e+t.progress.bytesTotal,0);const o=n/t.length;n+=o*r.length;let i=0;t.forEach(e=>{i+=e.progress.bytesUploaded}),r.forEach(e=>{i+=o*(e.progress.percentage||0)/100});let a=0===n?0:Math.round(i/n*100);a>100&&(a=100),this.setState({totalProgress:a}),this.emit("progress",a)}updateOnlineStatus(){void 0===window.navigator.onLine||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,t){if("function"!=typeof e){throw new TypeError(`Expected a plugin class, but got ${null===e?"null":typeof e}. Please verify that the plugin was imported and spelled correctly.`)}const r=new e(this,t),n=r.id;if(!n)throw new Error("Your plugin must have an id");if(!r.type)throw new Error("Your plugin must have a type");const o=this.getPlugin(n);if(o){const e=`Already found a plugin named '${o.id}'. Tried to use: '${n}'.\nUppy plugins must have unique \`id\` options. See https://uppy.io/docs/plugins/#id.`;throw new Error(e)}return e.VERSION&&this.log(`Using ${n} v${e.VERSION}`),r.type in i(this,y)[y]?i(this,y)[y][r.type].push(r):i(this,y)[y][r.type]=[r],r.install(),this}getPlugin(e){for(const t of Object.values(i(this,y)[y])){const r=t.find(t=>t.id===e);if(null!=r)return r}}[n](e){return i(this,y)[y][e]}iteratePlugins(e){Object.values(i(this,y)[y]).flat(1).forEach(e)}removePlugin(e){this.log(`Removing plugin ${e.id}`),this.emit("plugin-remove",e),e.uninstall&&e.uninstall();const t=i(this,y)[y][e.type],r=t.findIndex(t=>t.id===e.id);-1!==r&&t.splice(r,1);const n={plugins:{...this.getState().plugins,[e.id]:void 0}};this.setState(n)}close(e){let{reason:t}=void 0===e?{}:e;this.log(`Closing Uppy instance ${this.opts.id}: removing all files and uninstalling plugins`),this.cancelAll({reason:t}),i(this,D)[D](),this.iteratePlugins(e=>{this.removePlugin(e)}),"undefined"!=typeof window&&window.removeEventListener&&(window.removeEventListener("online",i(this,N)[N]),window.removeEventListener("offline",i(this,N)[N]))}hideInfo(){const{info:e}=this.getState();this.setState({info:e.slice(1)}),this.emit("info-hidden")}info(e,t,r){void 0===t&&(t="info"),void 0===r&&(r=3e3);const n="object"==typeof e;this.setState({info:[...this.getState().info,{type:t,message:n?e.message:e,details:n?e.details:null}]}),setTimeout(()=>this.hideInfo(),r),this.emit("info-visible")}log(e,t){const{logger:r}=this.opts;switch(t){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]?i(this,R)[R](e):(i(this,I)[I](e),Promise.reject(new Error("Nonexistent upload")))}[o](){return i(this,P)[P](...arguments)}addResultData(e,t){if(!i(this,M)[M](e))return void this.log(`Not setting result for an upload that has been removed: ${e}`);const{currentUploads:r}=this.getState(),n={...r[e],result:{...r[e].result,...t}};this.setState({currentUploads:{...r,[e]:n}})}upload(){var e;null!=(e=i(this,y)[y].uploader)&&e.length||this.log("No uploader type plugins are used","warning");let{files:t}=this.getState();const n=this.opts.onBeforeUpload(t);return!1===n?Promise.reject(new Error("Not starting the upload because onBeforeUpload returned false")):(n&&"object"==typeof n&&(t=n,this.setState({files:t})),Promise.resolve().then(()=>i(this,b)[b].validateMinNumberOfFiles(t)).catch(e=>{throw i(this,x)[x](e),e}).then(()=>{if(!i(this,S)[S](t))throw new r.RestrictionError(this.i18n("missingRequiredMetaField"))}).catch(e=>{throw e}).then(()=>{const{currentUploads:e}=this.getState(),r=Object.values(e).flatMap(e=>e.fileIDs),n=[];Object.keys(t).forEach(e=>{const t=this.getFile(e);t.progress.uploadStarted||-1!==r.indexOf(e)||n.push(t.id)});const o=i(this,P)[P](n);return i(this,R)[R](o)}).catch(e=>{throw this.emit("error",e),this.log(e,"error"),e}))}}function _(e,t){const{message:r,details:n=""}=e;e.isRestriction?this.emit("restriction-failed",t,e):this.emit("error",e),this.info({message:r,details:n},"error",this.opts.infoTimeout),this.log(`${r} ${n}`.trim(),"error")}function z(e){const{missingFields:t,error:r}=i(this,b)[b].getMissingRequiredMetaFields(e);return!(t.length>0)||(this.setFileState(e.id,{missingRequiredMetaFields:t}),this.log(r.message),this.emit("restriction-failed",e,r),!1)}function j(e){let t=!0;for(const r of Object.values(e))i(this,B)[B](r)||(t=!1);return t}function H(e){const{allowNewUpload:t}=this.getState();if(!1===t){const t=new r.RestrictionError(this.i18n("noMoreFilesAllowed"));throw i(this,x)[x](t,e),t}}function V(e,t){const n=h(t),o=m(n,t),a=f(o).extension,s=Boolean(t.isRemote),u=p({...t,type:n});if(this.checkIfFileAlreadyExists(u)){const e=new r.RestrictionError(this.i18n("noDuplicates",{fileName:o}));throw i(this,x)[x](e,t),e}const l=t.meta||{};l.name=o,l.type=n;const c=Number.isFinite(t.data.size)?t.data.size:null;let d={source:t.source||"",id:u,name:o,extension:a||"",meta:{...this.getState().meta,...l},type:n,data:t.data,progress:{percentage:0,bytesUploaded:0,bytesTotal:c,uploadComplete:!1,uploadStarted:null},size:c,isRemote:s,remote:t.remote||"",preview:t.preview};const g=this.opts.onBeforeFileAdded(d,e);if(!1===g){const e=new r.RestrictionError("Cannot add the file because onBeforeFileAdded returned false.");throw this.emit("restriction-failed",t,e),e}"object"==typeof g&&null!==g&&(d=g);try{const t=Object.keys(e).map(t=>e[t]);i(this,b)[b].validate(d,t)}catch(e){throw i(this,x)[x](e,d),e}return d}function $(){this.opts.autoProceed&&!this.scheduledAutoProceed&&(this.scheduledAutoProceed=setTimeout(()=>{this.scheduledAutoProceed=null,this.upload().catch(e=>{e.isRestriction||this.log(e.stack||e.message||e)})},4))}function U(){const e=(e,t,r)=>{let n=e.message||"Unknown error";e.details&&(n+=` ${e.details}`),this.setState({error:n}),null!=t&&t.id in this.getState().files&&this.setFileState(t.id,{error:n,response:r})};this.on("error",e),this.on("upload-error",(t,r,n)=>{if(e(r,t,n),"object"==typeof r&&r.message){const e=new Error(r.message);e.details=r.message,r.details&&(e.details+=` ${r.details}`),e.message=this.i18n("failedToUpload",{file:null==t?void 0:t.name}),i(this,x)[x](e)}else i(this,x)[x](r)}),this.on("upload",()=>{this.setState({error:null})}),this.on("upload-started",e=>{null!=e&&this.getFile(e.id)?this.setFileState(e.id,{progress:{uploadStarted:Date.now(),uploadComplete:!1,percentage:0,bytesUploaded:0,bytesTotal:e.size}}):this.log(`Not setting progress for a file that has been removed: ${null==e?void 0:e.id}`)}),this.on("upload-progress",this.calculateProgress),this.on("upload-success",(e,t)=>{if(null==e||!this.getFile(e.id))return void this.log(`Not setting progress for a file that has been removed: ${null==e?void 0:e.id}`);const r=this.getFile(e.id).progress;this.setFileState(e.id,{progress:{...r,postprocess:i(this,A)[A].size>0?{mode:"indeterminate"}:null,uploadComplete:!0,percentage:100,bytesUploaded:r.bytesTotal},response:t,uploadURL:t.uploadURL,isPaused:!1}),null==e.size&&this.setFileState(e.id,{size:t.bytesUploaded||r.bytesTotal}),this.calculateTotalProgress()}),this.on("preprocess-progress",(e,t)=>{null!=e&&this.getFile(e.id)?this.setFileState(e.id,{progress:{...this.getFile(e.id).progress,preprocess:t}}):this.log(`Not setting progress for a file that has been removed: ${null==e?void 0:e.id}`)}),this.on("preprocess-complete",e=>{if(null==e||!this.getFile(e.id))return void this.log(`Not setting progress for a file that has been removed: ${null==e?void 0:e.id}`);const t={...this.getState().files};t[e.id]={...t[e.id],progress:{...t[e.id].progress}},delete t[e.id].progress.preprocess,this.setState({files:t})}),this.on("postprocess-progress",(e,t)=>{null!=e&&this.getFile(e.id)?this.setFileState(e.id,{progress:{...this.getState().files[e.id].progress,postprocess:t}}):this.log(`Not setting progress for a file that has been removed: ${null==e?void 0:e.id}`)}),this.on("postprocess-complete",e=>{if(null==e||!this.getFile(e.id))return void this.log(`Not setting progress for a file that has been removed: ${null==e?void 0:e.id}`);const t={...this.getState().files};t[e.id]={...t[e.id],progress:{...t[e.id].progress}},delete t[e.id].progress.postprocess,this.setState({files:t})}),this.on("restored",()=>{this.calculateTotalProgress()}),this.on("dashboard:file-edit-complete",e=>{e&&i(this,B)[B](e)}),"undefined"!=typeof window&&window.addEventListener&&(window.addEventListener("online",i(this,N)[N]),window.addEventListener("offline",i(this,N)[N]),setTimeout(i(this,N)[N],3e3))}function q(t,r){void 0===r&&(r={});const{forceAllowNewUpload:n=!1}=r,{allowNewUpload:o,currentUploads:i}=this.getState();if(!o&&!n)throw new Error("Cannot create a new upload: already uploading.");const a=(0,e.nanoid)();return this.emit("upload",{id:a,fileIDs:t}),this.setState({allowNewUpload:!1!==this.opts.allowMultipleUploadBatches&&!1!==this.opts.allowMultipleUploads,currentUploads:{...i,[a]:{fileIDs:t,step:0,result:{}}}}),a}function W(e){const{currentUploads:t}=this.getState();return t[e]}function G(e){const t={...this.getState().currentUploads};delete t[e],this.setState({currentUploads:t})}async function Y(e){let{currentUploads:t}=this.getState(),r=t[e];const n=r.step||0,o=[...i(this,w)[w],...i(this,E)[E],...i(this,A)[A]];try{for(let i=n;i<o.length&&r;i++){const n=o[i],a={...r,step:i};this.setState({currentUploads:{...t,[e]:a}}),await n(a.fileIDs,e),t=this.getState().currentUploads,r=t[e]}}catch(t){throw i(this,I)[I](e),t}if(r){r.fileIDs.forEach(e=>{const t=this.getFile(e);t&&t.progress.postprocess&&this.emit("postprocess-complete",t)});const n=r.fileIDs.map(e=>this.getFile(e)),o=n.filter(e=>!e.error),i=n.filter(e=>e.error);await this.addResultData(e,{successful:o,failed:i,uploadID:e}),t=this.getState().currentUploads,r=t[e]}let a;return r&&(a=r.result,this.emit("complete",a),i(this,I)[I](e)),null==a&&this.log(`Not setting result for an upload that has been removed: ${e}`),a}return L.VERSION="2.3.4",_E=L}var ZE,JE,QE,eA,tA,rA,nA,oA,iA,aA,sA,uA,lA,cA={},dA=[],hA=/acit|ex(?:s|g|n|p|$)|rph|grid|ows|mnc|ntw|ine[ch]|zoo|^ord|itera/i,fA=Array.isArray;function pA(e,t){for(var r in t)e[r]=t[r];return e}function gA(e){e&&e.parentNode&&e.parentNode.removeChild(e)}function mA(e,t,r){var n,o,i,a={};for(i in t)"key"==i?n=t[i]:"ref"==i?o=t[i]:a[i]=t[i];if(arguments.length>2&&(a.children=arguments.length>3?ZE.call(arguments,2):r),"function"==typeof e&&null!=e.defaultProps)for(i in e.defaultProps)void 0===a[i]&&(a[i]=e.defaultProps[i]);return vA(e,a,n,o,null)}function vA(e,t,r,n,o){var i={type:e,props:t,key:r,ref:n,__k:null,__:null,__b:0,__e:null,__c:null,constructor:void 0,__v:null==o?++QE:o,__i:-1,__u:0};return null==o&&null!=JE.vnode&&JE.vnode(i),i}function yA(e){return e.children}function bA(e,t){this.props=e,this.context=t}function DA(e,t){if(null==t)return e.__?DA(e.__,e.__i+1):null;for(var r;t<e.__k.length;t++)if(null!=(r=e.__k[t])&&null!=r.__e)return r.__e;return"function"==typeof e.type?DA(e):null}function CA(e){var t,r;if(null!=(e=e.__)&&null!=e.__c){for(e.__e=e.__c.base=null,t=0;t<e.__k.length;t++)if(null!=(r=e.__k[t])&&null!=r.__e){e.__e=e.__c.base=r.__e;break}return CA(e)}}function wA(e){(!e.__d&&(e.__d=!0)&&tA.push(e)&&!EA.__r++||rA!=JE.debounceRendering)&&((rA=JE.debounceRendering)||nA)(EA)}function EA(){for(var e,t,r,n,o,i,a,s=1;tA.length;)tA.length>s&&tA.sort(oA),e=tA.shift(),s=tA.length,e.__d&&(r=void 0,o=(n=(t=e).__v).__e,i=[],a=[],t.__P&&((r=pA({},n)).__v=n.__v+1,JE.vnode&&JE.vnode(r),TA(t.__P,r,n,t.__n,t.__P.namespaceURI,32&n.__u?[o]:null,i,null==o?DA(n):o,!!(32&n.__u),a),r.__v=n.__v,r.__.__k[r.__i]=r,NA(i,r,a),r.__e!=o&&CA(r)));EA.__r=0}function AA(e,t,r,n,o,i,a,s,u,l,c){var d,h,f,p,g,m,v=n&&n.__k||dA,y=t.length;for(u=xA(r,t,v,u,y),d=0;d<y;d++)null!=(f=r.__k[d])&&(h=-1==f.__i?cA:v[f.__i]||cA,f.__i=d,m=TA(e,f,h,o,i,a,s,u,l,c),p=f.__e,f.ref&&h.ref!=f.ref&&(h.ref&&MA(h.ref,null,f),c.push(f.ref,f.__c||p,f)),null==g&&null!=p&&(g=p),4&f.__u||h.__k===f.__k?u=BA(f,u,e):"function"==typeof f.type&&void 0!==m?u=m:p&&(u=p.nextSibling),f.__u&=-7);return r.__e=g,u}function xA(e,t,r,n,o){var i,a,s,u,l,c=r.length,d=c,h=0;for(e.__k=new Array(o),i=0;i<o;i++)null!=(a=t[i])&&"boolean"!=typeof a&&"function"!=typeof a?(u=i+h,(a=e.__k[i]="string"==typeof a||"number"==typeof a||"bigint"==typeof a||a.constructor==String?vA(null,a,null,null,null):fA(a)?vA(yA,{children:a},null,null,null):null==a.constructor&&a.__b>0?vA(a.type,a.props,a.key,a.ref?a.ref:null,a.__v):a).__=e,a.__b=e.__b+1,s=null,-1!=(l=a.__i=SA(a,r,u,d))&&(d--,(s=r[l])&&(s.__u|=2)),null==s||null==s.__v?(-1==l&&(o>c?h--:o<c&&h++),"function"!=typeof a.type&&(a.__u|=4)):l!=u&&(l==u-1?h--:l==u+1?h++:(l>u?h--:h++,a.__u|=4))):e.__k[i]=null;if(d)for(i=0;i<c;i++)null!=(s=r[i])&&!(2&s.__u)&&(s.__e==n&&(n=DA(s)),IA(s,s));return n}function BA(e,t,r){var n,o;if("function"==typeof e.type){for(n=e.__k,o=0;n&&o<n.length;o++)n[o]&&(n[o].__=e,t=BA(n[o],t,r));return t}e.__e!=t&&(t&&e.type&&!r.contains(t)&&(t=DA(e)),r.insertBefore(e.__e,t||null),t=e.__e);do{t=t&&t.nextSibling}while(null!=t&&8==t.nodeType);return t}function SA(e,t,r,n){var o,i,a=e.key,s=e.type,u=t[r];if(null===u&&null==e.key||u&&a==u.key&&s==u.type&&!(2&u.__u))return r;if(n>(null==u||2&u.__u?0:1))for(o=r-1,i=r+1;o>=0||i<t.length;){if(o>=0){if((u=t[o])&&!(2&u.__u)&&a==u.key&&s==u.type)return o;o--}if(i<t.length){if((u=t[i])&&!(2&u.__u)&&a==u.key&&s==u.type)return i;i++}}return-1}function FA(e,t,r){"-"==t[0]?e.setProperty(t,null==r?"":r):e[t]=null==r?"":"number"!=typeof r||hA.test(t)?r:r+"px"}function kA(e,t,r,n,o){var i,a;e:if("style"==t)if("string"==typeof r)e.style.cssText=r;else{if("string"==typeof n&&(e.style.cssText=n=""),n)for(t in n)r&&t in r||FA(e.style,t,"");if(r)for(t in r)n&&r[t]==n[t]||FA(e.style,t,r[t])}else if("o"==t[0]&&"n"==t[1])i=t!=(t=t.replace(iA,"$1")),a=t.toLowerCase(),t=a in e||"onFocusOut"==t||"onFocusIn"==t?a.slice(2):t.slice(2),e.l||(e.l={}),e.l[t+i]=r,r?n?r.u=n.u:(r.u=aA,e.addEventListener(t,i?uA:sA,i)):e.removeEventListener(t,i?uA:sA,i);else{if("http://www.w3.org/2000/svg"==o)t=t.replace(/xlink(H|:h)/,"h").replace(/sName$/,"s");else if("width"!=t&&"height"!=t&&"href"!=t&&"list"!=t&&"form"!=t&&"tabIndex"!=t&&"download"!=t&&"rowSpan"!=t&&"colSpan"!=t&&"role"!=t&&"popover"!=t&&t in e)try{e[t]=null==r?"":r;break e}catch(e){}"function"==typeof r||(null==r||!1===r&&"-"!=t[4]?e.removeAttribute(t):e.setAttribute(t,"popover"==t&&1==r?"":r))}}function OA(e){return function(t){if(this.l){var r=this.l[t.type+e];if(null==t.t)t.t=aA++;else if(t.t<r.u)return;return r(JE.event?JE.event(t):t)}}}function TA(e,t,r,n,o,i,a,s,u,l){var c,d,h,f,p,g,m,v,y,b,D,C,w,E,A,x,B,S=t.type;if(null!=t.constructor)return null;128&r.__u&&(u=!!(32&r.__u),i=[s=t.__e=r.__e]),(c=JE.__b)&&c(t);e:if("function"==typeof S)try{if(v=t.props,y="prototype"in S&&S.prototype.render,b=(c=S.contextType)&&n[c.__c],D=c?b?b.props.value:c.__:n,r.__c?m=(d=t.__c=r.__c).__=d.__E:(y?t.__c=d=new S(v,D):(t.__c=d=new bA(v,D),d.constructor=S,d.render=RA),b&&b.sub(d),d.props=v,d.state||(d.state={}),d.context=D,d.__n=n,h=d.__d=!0,d.__h=[],d._sb=[]),y&&null==d.__s&&(d.__s=d.state),y&&null!=S.getDerivedStateFromProps&&(d.__s==d.state&&(d.__s=pA({},d.__s)),pA(d.__s,S.getDerivedStateFromProps(v,d.__s))),f=d.props,p=d.state,d.__v=t,h)y&&null==S.getDerivedStateFromProps&&null!=d.componentWillMount&&d.componentWillMount(),y&&null!=d.componentDidMount&&d.__h.push(d.componentDidMount);else{if(y&&null==S.getDerivedStateFromProps&&v!==f&&null!=d.componentWillReceiveProps&&d.componentWillReceiveProps(v,D),!d.__e&&null!=d.shouldComponentUpdate&&!1===d.shouldComponentUpdate(v,d.__s,D)||t.__v==r.__v){for(t.__v!=r.__v&&(d.props=v,d.state=d.__s,d.__d=!1),t.__e=r.__e,t.__k=r.__k,t.__k.some(function(e){e&&(e.__=t)}),C=0;C<d._sb.length;C++)d.__h.push(d._sb[C]);d._sb=[],d.__h.length&&a.push(d);break e}null!=d.componentWillUpdate&&d.componentWillUpdate(v,d.__s,D),y&&null!=d.componentDidUpdate&&d.__h.push(function(){d.componentDidUpdate(f,p,g)})}if(d.context=D,d.props=v,d.__P=e,d.__e=!1,w=JE.__r,E=0,y){for(d.state=d.__s,d.__d=!1,w&&w(t),c=d.render(d.props,d.state,d.context),A=0;A<d._sb.length;A++)d.__h.push(d._sb[A]);d._sb=[]}else do{d.__d=!1,w&&w(t),c=d.render(d.props,d.state,d.context),d.state=d.__s}while(d.__d&&++E<25);d.state=d.__s,null!=d.getChildContext&&(n=pA(pA({},n),d.getChildContext())),y&&!h&&null!=d.getSnapshotBeforeUpdate&&(g=d.getSnapshotBeforeUpdate(f,p)),x=c,null!=c&&c.type===yA&&null==c.key&&(x=PA(c.props.children)),s=AA(e,fA(x)?x:[x],t,r,n,o,i,a,s,u,l),d.base=t.__e,t.__u&=-161,d.__h.length&&a.push(d),m&&(d.__E=d.__=null)}catch(e){if(t.__v=null,u||null!=i)if(e.then){for(t.__u|=u?160:128;s&&8==s.nodeType&&s.nextSibling;)s=s.nextSibling;i[i.indexOf(s)]=null,t.__e=s}else for(B=i.length;B--;)gA(i[B]);else t.__e=r.__e,t.__k=r.__k;JE.__e(e,t,r)}else null==i&&t.__v==r.__v?(t.__k=r.__k,t.__e=r.__e):s=t.__e=function(e,t,r,n,o,i,a,s,u){var l,c,d,h,f,p,g,m=r.props,v=t.props,y=t.type;if("svg"==y?o="http://www.w3.org/2000/svg":"math"==y?o="http://www.w3.org/1998/Math/MathML":o||(o="http://www.w3.org/1999/xhtml"),null!=i)for(l=0;l<i.length;l++)if((f=i[l])&&"setAttribute"in f==!!y&&(y?f.localName==y:3==f.nodeType)){e=f,i[l]=null;break}if(null==e){if(null==y)return document.createTextNode(v);e=document.createElementNS(o,y,v.is&&v),s&&(JE.__m&&JE.__m(t,i),s=!1),i=null}if(null==y)m===v||s&&e.data==v||(e.data=v);else{if(i=i&&ZE.call(e.childNodes),m=r.props||cA,!s&&null!=i)for(m={},l=0;l<e.attributes.length;l++)m[(f=e.attributes[l]).name]=f.value;for(l in m)if(f=m[l],"children"==l);else if("dangerouslySetInnerHTML"==l)d=f;else if(!(l in v)){if("value"==l&&"defaultValue"in v||"checked"==l&&"defaultChecked"in v)continue;kA(e,l,null,f,o)}for(l in v)f=v[l],"children"==l?h=f:"dangerouslySetInnerHTML"==l?c=f:"value"==l?p=f:"checked"==l?g=f:s&&"function"!=typeof f||m[l]===f||kA(e,l,f,m[l],o);if(c)s||d&&(c.__html==d.__html||c.__html==e.innerHTML)||(e.innerHTML=c.__html),t.__k=[];else if(d&&(e.innerHTML=""),AA("template"==t.type?e.content:e,fA(h)?h:[h],t,r,n,"foreignObject"==y?"http://www.w3.org/1999/xhtml":o,i,a,i?i[0]:r.__k&&DA(r,0),s,u),null!=i)for(l=i.length;l--;)gA(i[l]);s||(l="value","progress"==y&&null==p?e.removeAttribute("value"):null!=p&&(p!==e[l]||"progress"==y&&!p||"option"==y&&p!=m[l])&&kA(e,l,p,m[l],o),l="checked",null!=g&&g!=e[l]&&kA(e,l,g,m[l],o))}return e}(r.__e,t,r,n,o,i,a,u,l);return(c=JE.diffed)&&c(t),128&t.__u?void 0:s}function NA(e,t,r){for(var n=0;n<r.length;n++)MA(r[n],r[++n],r[++n]);JE.__c&&JE.__c(t,e),e.some(function(t){try{e=t.__h,t.__h=[],e.some(function(e){e.call(t)})}catch(e){JE.__e(e,t.__v)}})}function PA(e){return"object"!=typeof e||null==e||e.__b&&e.__b>0?e:fA(e)?e.map(PA):pA({},e)}function MA(e,t,r){try{if("function"==typeof e){var n="function"==typeof e.__u;n&&e.__u(),n&&null==t||(e.__u=e(t))}else e.current=t}catch(e){JE.__e(e,r)}}function IA(e,t,r){var n,o;if(JE.unmount&&JE.unmount(e),(n=e.ref)&&(n.current&&n.current!=e.__e||MA(n,null,t)),null!=(n=e.__c)){if(n.componentWillUnmount)try{n.componentWillUnmount()}catch(e){JE.__e(e,t)}n.base=n.__P=null}if(n=e.__k)for(o=0;o<n.length;o++)n[o]&&IA(n[o],t,r||"function"!=typeof e.type);r||gA(e.__e),e.__c=e.__=e.__e=void 0}function RA(e,t,r){return this.constructor(e,r)}function LA(e,t,r){var n,o,i,a;t==document&&(t=document.documentElement),JE.__&&JE.__(e,t),o=(n="function"==typeof r)?null:r&&r.__k||t.__k,i=[],a=[],TA(t,e=(!n&&r||t).__k=mA(yA,null,[e]),o||cA,cA,t.namespaceURI,!n&&r?[r]:o?null:t.firstChild?ZE.call(t.childNodes):null,i,!n&&r?r:o?o.__e:t.firstChild,n,a),NA(i,e,a)}ZE=dA.slice,JE={__e:function(e,t,r,n){for(var o,i,a;t=t.__;)if((o=t.__c)&&!o.__)try{if((i=o.constructor)&&null!=i.getDerivedStateFromError&&(o.setState(i.getDerivedStateFromError(e)),a=o.__d),null!=o.componentDidCatch&&(o.componentDidCatch(e,n||{}),a=o.__d),a)return o.__E=o}catch(t){e=t}throw e}},QE=0,eA=function(e){return null!=e&&null==e.constructor},bA.prototype.setState=function(e,t){var r;r=null!=this.__s&&this.__s!=this.state?this.__s:this.__s=pA({},this.state),"function"==typeof e&&(e=e(pA({},r),this.props)),e&&pA(r,e),null!=e&&this.__v&&(t&&this._sb.push(t),wA(this))},bA.prototype.forceUpdate=function(e){this.__v&&(this.__e=!0,e&&this.__h.push(e),wA(this))},bA.prototype.render=yA,tA=[],nA="function"==typeof Promise?Promise.prototype.then.bind(Promise.resolve()):setTimeout,oA=function(e,t){return e.__v.__b-t.__v.__b},EA.__r=0,iA=/(PointerCapture)$|Capture$/i,aA=0,sA=OA(!1),uA=OA(!0),lA=0;var _A,zA,jA,HA,VA,$A,UA,qA,WA,GA,YA,KA=Object.freeze({__proto__:null,Component:bA,Fragment:yA,cloneElement:function(e,t,r){var n,o,i,a,s=pA({},e.props);for(i in e.type&&e.type.defaultProps&&(a=e.type.defaultProps),t)"key"==i?n=t[i]:"ref"==i?o=t[i]:s[i]=void 0===t[i]&&null!=a?a[i]:t[i];return arguments.length>2&&(s.children=arguments.length>3?ZE.call(arguments,2):r),vA(e.type,s,n||e.key,o||e.ref,null)},createContext:function(e){function t(e){var r,n;return this.getChildContext||(r=new Set,(n={})[t.__c]=this,this.getChildContext=function(){return n},this.componentWillUnmount=function(){r=null},this.shouldComponentUpdate=function(e){this.props.value!=e.value&&r.forEach(function(e){e.__e=!0,wA(e)})},this.sub=function(e){r.add(e);var t=e.componentWillUnmount;e.componentWillUnmount=function(){r&&r.delete(e),t&&t.call(e)}}),e.children}return t.__c="__cC"+lA++,t.__=e,t.Provider=t.__l=(t.Consumer=function(e,t){return e.children(t)}).contextType=t,t},createElement:mA,createRef:function(){return{current:null}},h:mA,hydrate:function e(t,r){LA(t,r,e)},get isValidElement(){return eA},get options(){return JE},render:LA,toChildArray:function e(t,r){return r=r||[],null==t||"boolean"==typeof t||(fA(t)?t.some(function(t){e(t,r)}):r.push(t)),r}}),XA=D(KA);function ZA(){if(HA)return jA;HA=1;const e=zA?_A:(zA=1,_A=function(e){return(null==e?void 0:e.nodeType)===Node.ELEMENT_NODE});return jA=function(t,r){return void 0===r&&(r=document),"string"==typeof t?r.querySelector(t):e(t)?t:null}}function JA(){if(qA)return UA;qA=1;const e=qE();return UA=class{constructor(e,t){void 0===t&&(t={}),this.uppy=e,this.opts=t}getPluginState(){const{plugins:e}=this.uppy.getState();return e[this.id]||{}}setPluginState(e){const{plugins:t}=this.uppy.getState();this.uppy.setState({plugins:{...t,[this.id]:{...t[this.id],...e}}})}setOptions(e){this.opts={...this.opts,...e},this.setPluginState(),this.i18nInit()}i18nInit(){const t=new e([this.defaultLocale,this.uppy.locale,this.opts.locale]);this.i18n=t.translate.bind(t),this.i18nArray=t.translateArray.bind(t),this.setPluginState()}addTarget(){throw new Error("Extend the addTarget method to add your plugin to another plugin's target")}install(){}uninstall(){}render(){throw new Error("Extend the render method to add your plugin to a DOM element")}update(){}afterUpdate(){}}}function QA(){if(GA)return WA;GA=1;var e=XA;function t(e,t){if(!Object.prototype.hasOwnProperty.call(e,t))throw new TypeError("attempted to use private field on non-instance");return e}var r=0;function n(e){return"__private_"+r+++"_"+e}const o=ZA(),i=$A?VA:($A=1,VA=function(e){for(var t;e&&!e.dir;)e=e.parentNode;return null==(t=e)?void 0:t.dir}),a=JA();var s=n("updateUI");class u extends a{constructor(){super(...arguments),Object.defineProperty(this,s,{writable:!0,value:void 0})}mount(r,n){const a=n.id,l=o(r);if(l){this.isTargetDOMEl=!0;const n=document.createElement("div");return n.classList.add("uppy-Root"),t(this,s)[s]=function(e){let t=null,r=null;return function(){for(var n=arguments.length,o=new Array(n),i=0;i<n;i++)o[i]=arguments[i];return r=o,t||(t=Promise.resolve().then(()=>(t=null,e(...r)))),t}}(t=>{this.uppy.getPlugin(this.id)&&((0,e.render)(this.render(t),n),this.afterUpdate())}),this.uppy.log(`Installing ${a} to a DOM element '${r}'`),this.opts.replaceTargetContent&&(l.innerHTML=""),(0,e.render)(this.render(this.uppy.getState()),n),this.el=n,l.appendChild(n),n.dir=this.opts.direction||i(n)||"ltr",this.onMount(),this.el}let c;if("object"==typeof r&&r instanceof u)c=r;else if("function"==typeof r){const e=r;this.uppy.iteratePlugins(t=>{t instanceof e&&(c=t)})}if(c)return this.uppy.log(`Installing ${a} to ${c.id}`),this.parent=c,this.el=c.addTarget(n),this.onMount(),this.el;this.uppy.log(`Not installing ${a}`);let d=`Invalid target option given to ${a}.`;throw d+="function"==typeof r?" The given target is not a Plugin class. Please check that you're not specifying a React Component instead of a plugin. If you are using @uppy/* packages directly, make sure you have only 1 version of @uppy/core installed: run `npm ls @uppy/core` on the command line and verify that all the versions match and are deduped correctly.":"If you meant to target an HTML element, please make sure that the element exists. Check that the <script> tag initializing Uppy is right before the closing </body> tag at the end of the page. (see https://github.com/transloadit/uppy/issues/1042)\n\nIf you meant to target a plugin, please confirm that your `import` statements or `require` calls are correct.",new Error(d)}update(e){var r,n;null!=this.el&&(null==(r=(n=t(this,s))[s])||r.call(n,e))}unmount(){var e;this.isTargetDOMEl&&(null==(e=this.el)||e.remove());this.onUnmount()}onMount(){}onUnmount(){}}return WA=u}var ex,tx,rx,nx,ox,ix,ax,sx,ux,lx,cx=(YA||(YA=1,function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.Uppy=t.UIPlugin=t.BasePlugin=void 0,Object.defineProperty(t,"debugLogger",{enumerable:!0,get:function(){return r.debugLogger}});var r=sE();e.exports=XE();const n=QA();t.UIPlugin=n;const o=JA();t.BasePlugin=o;const i=XE();t.Uppy=i;const a=QA(),s=JA();i.Uppy=i,i.UIPlugin=a,i.BasePlugin=s,i.debugLogger=r.debugLogger}(iE,iE.exports)),iE.exports),dx=b(cx),hx={};function fx(){if(tx)return ex;tx=1;class e extends Error{constructor(e,t){void 0===t&&(t=null),super("This looks like a network error, the endpoint might be blocked by an internet provider or a firewall."),this.cause=e,this.isNetworkError=!0,this.request=t}}return ex=e}function px(){if(lx)return ux;let e;function t(e,t){if(!Object.prototype.hasOwnProperty.call(e,t))throw new TypeError("attempted to use private field on non-instance");return e}lx=1;var r=0;function n(e){return"__private_"+r+++"_"+e}const o=function(){if(nx)return rx;nx=1;const e=fx();return rx=function(){return fetch(...arguments).catch(t=>{throw"AbortError"===t.name?t:new e(t)})},rx}(),i=function(){if(ix)return ox;ix=1;const e=UE();class t extends Error{constructor(t,r){void 0===r&&(r={}),super(t),this.cause=r.cause,this.cause&&e(this.cause,"isNetworkError")&&(this.isNetworkError=this.cause.isNetworkError)}}return ox=t}(),a=function(){if(sx)return ax;sx=1;class e extends Error{constructor(){super("Authorization required"),this.name="AuthError",this.isAuthError=!0}}return ax=e}();async function s(e){if(401===e.status)throw new a;const t=e.json();if(e.status<200||e.status>300){let r=`Failed request with status: ${e.status}. ${e.statusText}`;try{const e=await t;r=e.message?`${r} message: ${e.message}`:r,r=e.requestId?`${r} request-Id: ${e.requestId}`:r}finally{throw new Error(r)}}return t}var u=n("companionHeaders"),l=n("getPostResponseFunc"),c=n("getUrl"),d=n("errorHandler");e=Symbol.for("uppy test: getCompanionHeaders");class h{constructor(e,r){Object.defineProperty(this,d,{value:p}),Object.defineProperty(this,c,{value:f}),Object.defineProperty(this,u,{writable:!0,value:void 0}),Object.defineProperty(this,l,{writable:!0,value:e=>t=>e?t:this.onReceiveResponse(t)}),this.uppy=e,this.opts=r,this.onReceiveResponse=this.onReceiveResponse.bind(this),this.allowedHeaders=["accept","content-type","uppy-auth-token"],this.preflightDone=!1,t(this,u)[u]=null==r?void 0:r.companionHeaders}setCompanionHeaders(e){t(this,u)[u]=e}[e](){return t(this,u)[u]}get hostname(){const{companion:e}=this.uppy.getState(),t=this.opts.companionUrl;return(e&&e[t]?e[t]:t).replace(/\/$/,"")}headers(){return Promise.resolve({...h.defaultHeaders,...t(this,u)[u]})}onReceiveResponse(e){const t=this.uppy.getState().companion||{},r=this.opts.companionUrl,{headers:n}=e;return n.has("i-am")&&n.get("i-am")!==t[r]&&this.uppy.setState({companion:{...t,[r]:n.get("i-am")}}),e}preflight(e){return this.preflightDone?Promise.resolve(this.allowedHeaders.slice()):fetch(t(this,c)[c](e),{method:"OPTIONS"}).then(e=>(e.headers.has("access-control-allow-headers")&&(this.allowedHeaders=e.headers.get("access-control-allow-headers").split(",").map(e=>e.trim().toLowerCase())),this.preflightDone=!0,this.allowedHeaders.slice())).catch(e=>(this.uppy.log(`[CompanionClient] unable to make preflight request ${e}`,"warning"),this.preflightDone=!0,this.allowedHeaders.slice()))}preflightAndHeaders(e){return Promise.all([this.preflight(e),this.headers()]).then(e=>{let[t,r]=e;return Object.keys(r).forEach(e=>{t.includes(e.toLowerCase())||(this.uppy.log(`[CompanionClient] excluding disallowed header ${e}`),delete r[e])}),r})}get(e,r){return this.preflightAndHeaders(e).then(r=>o(t(this,c)[c](e),{method:"get",headers:r,credentials:this.opts.companionCookiesRule||"same-origin"})).then(t(this,l)[l](r)).then(s).catch(t(this,d)[d]("get",e))}post(e,r,n){const i="post";return this.preflightAndHeaders(e).then(n=>o(t(this,c)[c](e),{method:i,headers:n,credentials:this.opts.companionCookiesRule||"same-origin",body:JSON.stringify(r)})).then(t(this,l)[l](n)).then(s).catch(t(this,d)[d](i,e))}delete(e,r,n){const i="delete";return this.preflightAndHeaders(e).then(t=>o(`${this.hostname}/${e}`,{method:i,headers:t,credentials:this.opts.companionCookiesRule||"same-origin",body:r?JSON.stringify(r):null})).then(t(this,l)[l](n)).then(s).catch(t(this,d)[d](i,e))}}function f(e){return/^(https?:|)\/\//.test(e)?e:`${this.hostname}/${e}`}function p(e,r){return n=>{var o;return null!=(o=n)&&o.isAuthError||(n=new i(`Could not ${e} ${t(this,c)[c](r)}`,{cause:n})),Promise.reject(n)}}return h.VERSION="2.2.2",h.defaultHeaders={Accept:"application/json","Content-Type":"application/json","Uppy-Versions":`@uppy/companion-client=${h.VERSION}`},ux=h}var gx,mx,vx,yx,bx,Dx,Cx,wx,Ex={};function Ax(){if(gx)return Ex;return gx=1,Object.defineProperty(Ex,"__esModule",{value:!0}),Ex.getItem=function(e){return Promise.resolve(localStorage.getItem(e))},Ex.removeItem=function(e){return new Promise(t=>{localStorage.removeItem(e),t()})},Ex.setItem=function(e,t){return new Promise(r=>{localStorage.setItem(e,t),r()})},Ex}function xx(){if(wx)return hx;wx=1,Object.defineProperty(hx,"__esModule",{value:!0}),hx.Socket=hx.SearchProvider=hx.RequestClient=hx.Provider=void 0;const e=px();hx.RequestClient=e;const t=function(){if(vx)return mx;vx=1;var e=Ax();const t=px();return mx=class extends t{constructor(e,t){super(e,t),this.provider=t.provider,this.id=this.provider,this.name=this.opts.name||this.id.split("-").map(e=>e.charAt(0).toUpperCase()+e.slice(1)).join(" "),this.pluginId=this.opts.pluginId,this.tokenKey=`companion-${this.pluginId}-auth-token`,this.companionKeysParams=this.opts.companionKeysParams,this.preAuthToken=null}headers(){return Promise.all([super.headers(),this.getAuthToken()]).then(e=>{let[t,r]=e;const n={};return r&&(n["uppy-auth-token"]=r),this.companionKeysParams&&(n["uppy-credentials-params"]=btoa(JSON.stringify({params:this.companionKeysParams}))),{...t,...n}})}onReceiveResponse(e){e=super.onReceiveResponse(e);const t=this.uppy.getPlugin(this.pluginId),r=t.getPluginState().authenticated?401!==e.status:e.status<400;return t.setPluginState({authenticated:r}),e}setAuthToken(e){return this.uppy.getPlugin(this.pluginId).storage.setItem(this.tokenKey,e)}getAuthToken(){return this.uppy.getPlugin(this.pluginId).storage.getItem(this.tokenKey)}async ensurePreAuth(){if(this.companionKeysParams&&!this.preAuthToken&&(await this.fetchPreAuthToken(),!this.preAuthToken))throw new Error("Could not load authentication data required for third-party login. Please try again later.")}authUrl(e){void 0===e&&(e={});const t=new URLSearchParams(e);return this.preAuthToken&&t.set("uppyPreAuthToken",this.preAuthToken),`${this.hostname}/${this.id}/connect?${t}`}fileUrl(e){return`${this.hostname}/${this.id}/get/${e}`}async fetchPreAuthToken(){if(this.companionKeysParams)try{const e=await this.post(`${this.id}/preauth/`,{params:this.companionKeysParams});this.preAuthToken=e.token}catch(e){this.uppy.log(`[CompanionClient] unable to fetch preAuthToken ${e}`,"warning")}}list(e){return this.get(`${this.id}/list/${e||""}`)}logout(){return this.get(`${this.id}/logout`).then(e=>Promise.all([e,this.uppy.getPlugin(this.pluginId).storage.removeItem(this.tokenKey)])).then(e=>{let[t]=e;return t})}static initPlugin(t,r,n){if(t.type="acquirer",t.files=[],n&&(t.opts={...n,...r}),r.serverUrl||r.serverPattern)throw new Error("`serverUrl` and `serverPattern` have been renamed to `companionUrl` and `companionAllowedHosts` respectively in the 0.30.5 release. Please consult the docs (for example, https://uppy.io/docs/instagram/ for the Instagram plugin) and use the updated options.`");if(r.companionAllowedHosts){const e=r.companionAllowedHosts;if(!("string"==typeof e||Array.isArray(e)||e instanceof RegExp))throw new TypeError(`${t.id}: the option "companionAllowedHosts" must be one of string, Array, RegExp`);t.opts.companionAllowedHosts=e}else/^(?!https?:\/\/).*$/i.test(r.companionUrl)?t.opts.companionAllowedHosts=`https://${r.companionUrl.replace(/^\/\//,"")}`:t.opts.companionAllowedHosts=new URL(r.companionUrl).origin;t.storage=t.opts.storage||e}},mx}();hx.Provider=t;const r=function(){if(bx)return yx;bx=1;const e=px();return yx=class extends e{constructor(e,t){super(e,t),this.provider=t.provider,this.id=this.provider,this.name=this.opts.name||this.id.split("-").map(e=>e.charAt(0).toUpperCase()+e.slice(1)).join(" "),this.pluginId=this.opts.pluginId}fileUrl(e){return`${this.hostname}/search/${this.id}/get/${e}`}search(e,t){return this.get(`search/${this.id}/list?q=${encodeURIComponent(e)}${t?`&${t}`:""}`)}},yx}();hx.SearchProvider=r;const n=function(){if(Cx)return Dx;let e,t;function r(e,t){if(!Object.prototype.hasOwnProperty.call(e,t))throw new TypeError("attempted to use private field on non-instance");return e}Cx=1;var n=0;function o(e){return"__private_"+n+++"_"+e}const i=WE();var a=o("queued"),s=o("emitter"),u=o("isOpen"),l=o("socket"),c=o("handleMessage");return e=Symbol.for("uppy test: getSocket"),t=Symbol.for("uppy test: getQueued"),Dx=class{constructor(e){Object.defineProperty(this,a,{writable:!0,value:[]}),Object.defineProperty(this,s,{writable:!0,value:i()}),Object.defineProperty(this,u,{writable:!0,value:!1}),Object.defineProperty(this,l,{writable:!0,value:void 0}),Object.defineProperty(this,c,{writable:!0,value:e=>{try{const t=JSON.parse(e.data);this.emit(t.action,t.payload)}catch(e){console.log(e)}}}),this.opts=e,e&&!1===e.autoOpen||this.open()}get isOpen(){return r(this,u)[u]}[e](){return r(this,l)[l]}[t](){return r(this,a)[a]}open(){r(this,l)[l]=new WebSocket(this.opts.target),r(this,l)[l].onopen=()=>{for(r(this,u)[u]=!0;r(this,a)[a].length>0&&r(this,u)[u];){const e=r(this,a)[a].shift();this.send(e.action,e.payload)}},r(this,l)[l].onclose=()=>{r(this,u)[u]=!1},r(this,l)[l].onmessage=r(this,c)[c]}close(){var e;null==(e=r(this,l)[l])||e.close()}send(e,t){r(this,u)[u]?r(this,l)[l].send(JSON.stringify({action:e,payload:t})):r(this,a)[a].push({action:e,payload:t})}on(e,t){r(this,s)[s].on(e,t)}emit(e,t){r(this,s)[s].emit(e,t)}once(e,t){r(this,s)[s].once(e,t)}},Dx}();return hx.Socket=n,hx}var Bx,Sx,Fx,kx,Ox,Tx,Nx,Px,Mx,Ix,Rx,Lx,_x,zx,jx,Hx,Vx,$x={};function Ux(){if(Bx)return $x;function e(e,t){if(!Object.prototype.hasOwnProperty.call(e,t))throw new TypeError("attempted to use private field on non-instance");return e}Bx=1,Object.defineProperty($x,"__esModule",{value:!0}),$x.internalRateLimitedQueue=$x.RateLimitedQueue=void 0;var t=0;function r(e){return"__private_"+t+++"_"+e}var n=r("activeRequests"),o=r("queuedHandlers"),i=r("paused"),a=r("pauseTimer"),s=r("downLimit"),u=r("upperLimit"),l=r("rateLimitingTimer"),c=r("call"),d=r("queueNext"),h=r("next"),f=r("queue"),p=r("dequeue"),g=r("resume"),m=r("increaseLimit");function v(t){e(this,n)[n]+=1;let r,o=!1;try{r=t()}catch(t){throw e(this,n)[n]-=1,t}return{abort:()=>{o||(o=!0,e(this,n)[n]-=1,r(),e(this,d)[d]())},done:()=>{o||(o=!0,e(this,n)[n]-=1,e(this,d)[d]())}}}function y(){queueMicrotask(()=>e(this,h)[h]())}function b(){if(e(this,i)[i]||e(this,n)[n]>=this.limit)return;if(0===e(this,o)[o].length)return;const t=e(this,o)[o].shift(),r=e(this,c)[c](t.fn);t.abort=r.abort,t.done=r.done}function D(t,r){void 0===r&&(r={});const n={fn:t,priority:r.priority||0,abort:()=>{e(this,p)[p](n)},done:()=>{throw new Error("Cannot mark a queued request as done: this indicates a bug")}},i=e(this,o)[o].findIndex(e=>n.priority>e.priority);return-1===i?e(this,o)[o].push(n):e(this,o)[o].splice(i,0,n),n}function C(t){const r=e(this,o)[o].indexOf(t);-1!==r&&e(this,o)[o].splice(r,1)}$x.RateLimitedQueue=class{constructor(t){Object.defineProperty(this,p,{value:C}),Object.defineProperty(this,f,{value:D}),Object.defineProperty(this,h,{value:b}),Object.defineProperty(this,d,{value:y}),Object.defineProperty(this,c,{value:v}),Object.defineProperty(this,n,{writable:!0,value:0}),Object.defineProperty(this,o,{writable:!0,value:[]}),Object.defineProperty(this,i,{writable:!0,value:!1}),Object.defineProperty(this,a,{writable:!0,value:void 0}),Object.defineProperty(this,s,{writable:!0,value:1}),Object.defineProperty(this,u,{writable:!0,value:void 0}),Object.defineProperty(this,l,{writable:!0,value:void 0}),Object.defineProperty(this,g,{writable:!0,value:()=>this.resume()}),Object.defineProperty(this,m,{writable:!0,value:()=>{if(e(this,i)[i])e(this,l)[l]=setTimeout(e(this,m)[m],0);else{e(this,s)[s]=this.limit,this.limit=Math.ceil((e(this,u)[u]+e(this,s)[s])/2);for(let t=e(this,s)[s];t<=this.limit;t++)e(this,d)[d]();e(this,u)[u]-e(this,s)[s]>3?e(this,l)[l]=setTimeout(e(this,m)[m],2e3):e(this,s)[s]=Math.floor(e(this,s)[s]/2)}}}),this.limit="number"!=typeof t||0===t?1/0:t}run(t,r){return!e(this,i)[i]&&e(this,n)[n]<this.limit?e(this,c)[c](t):e(this,f)[f](t,r)}wrapPromiseFunction(e,t){var r=this;return function(){for(var n=arguments.length,o=new Array(n),i=0;i<n;i++)o[i]=arguments[i];let a;const s=new Promise((n,i)=>{a=r.run(()=>{let t,r;try{r=Promise.resolve(e(...o))}catch(e){r=Promise.reject(e)}return r.then(e=>{t?i(t):(a.done(),n(e))},e=>{t?i(t):(a.done(),i(e))}),()=>{t=new Error("Cancelled")}},t)});return s.abort=()=>{a.abort()},s}}resume(){e(this,i)[i]=!1,clearTimeout(e(this,a)[a]);for(let t=0;t<this.limit;t++)e(this,d)[d]()}pause(t){void 0===t&&(t=null),e(this,i)[i]=!0,clearTimeout(e(this,a)[a]),null!=t&&(e(this,a)[a]=setTimeout(e(this,g)[g],t))}rateLimit(t){clearTimeout(e(this,l)[l]),this.pause(t),this.limit>1&&Number.isFinite(this.limit)&&(e(this,u)[u]=this.limit-1,this.limit=e(this,s)[s],e(this,l)[l]=setTimeout(e(this,m)[m],t))}get isPaused(){return e(this,i)[i]}};const w=Symbol("__queue");return $x.internalRateLimitedQueue=w,$x}function qx(){return jx?zx:(jx=1,zx={strings:{timedOut:"Upload stalled for %{seconds} seconds, aborting."}})}var Wx=function(){if(Vx)return Hx;Vx=1;var e=uE(),t=xx(),r=Ux();const n=JA(),o=function(){if(Fx)return Sx;Fx=1;const e=xC();return Sx=e(function(e,t,r){const{progress:n,bytesUploaded:o,bytesTotal:i}=t;n&&(e.uppy.log(`Upload progress: ${n}`),e.uppy.emit("upload-progress",r,{uploader:e,bytesUploaded:o,bytesTotal:i}))},300,{leading:!0,trailing:!0})}(),i=Ox?kx:(Ox=1,kx=function(e){const t=/^(?:https?:\/\/|\/\/)?(?:[^@\n]+@)?(?:www\.)?([^\n]+)/i.exec(e)[1];return`${/^http:\/\//i.test(e)?"ws":"wss"}://${t}`}),a=Nx?Tx:(Nx=1,Tx=function(e){const t=[],r=[];function n(e){t.push(e)}function o(e){r.push(e)}return Promise.all(e.map(e=>e.then(n,o))).then(()=>({successful:t,failed:r}))}),s=function(){if(Mx)return Px;function e(e,t){if(!Object.prototype.hasOwnProperty.call(e,t))throw new TypeError("attempted to use private field on non-instance");return e}Mx=1;var t=0;function r(e){return"__private_"+t+++"_"+e}var n=r("emitter"),o=r("events");return Px=class{constructor(t){Object.defineProperty(this,n,{writable:!0,value:void 0}),Object.defineProperty(this,o,{writable:!0,value:[]}),e(this,n)[n]=t}on(t,r){return e(this,o)[o].push([t,r]),e(this,n)[n].on(t,r)}remove(){for(const[t,r]of e(this,o)[o].splice(0))e(this,n)[n].off(t,r)}},Px}(),u=function(){if(Rx)return Ix;function e(e,t){if(!Object.prototype.hasOwnProperty.call(e,t))throw new TypeError("attempted to use private field on non-instance");return e}Rx=1;var t=0;function r(e){return"__private_"+t+++"_"+e}var n=r("aliveTimer"),o=r("isDone"),i=r("onTimedOut"),a=r("timeout");return Ix=class{constructor(t,r){Object.defineProperty(this,n,{writable:!0,value:void 0}),Object.defineProperty(this,o,{writable:!0,value:!1}),Object.defineProperty(this,i,{writable:!0,value:void 0}),Object.defineProperty(this,a,{writable:!0,value:void 0}),e(this,a)[a]=t,e(this,i)[i]=r}progress(){e(this,o)[o]||e(this,a)[a]>0&&(clearTimeout(e(this,n)[n]),e(this,n)[n]=setTimeout(e(this,i)[i],e(this,a)[a]))}done(){e(this,o)[o]||(clearTimeout(e(this,n)[n]),e(this,n)[n]=null,e(this,o)[o]=!0)}}}(),l=fx(),c=_x?Lx:(_x=1,Lx=function(e){return!!e&&(0!==e.readyState&&4!==e.readyState||0===e.status)}),d=qx();function h(e,t){let r=t;return r||(r=new Error("Upload error")),"string"==typeof r&&(r=new Error(r)),r instanceof Error||(r=Object.assign(new Error("Upload error"),{data:r})),c(e)?(r=new l(r,e),r):(r.request=e,r)}function f(e){return e.data.slice(0,e.data.size,e.meta.type)}class p extends n{constructor(e,t){super(e,t),this.type="uploader",this.id=this.opts.id||"XHRUpload",this.title="XHRUpload",this.defaultLocale=d;const n={formData:!0,fieldName:t.bundle?"files[]":"file",method:"post",metaFields:null,responseUrlFieldName:"url",bundle:!1,headers:{},timeout:3e4,limit:5,withCredentials:!1,responseType:"",getResponseData(t){let r={};try{r=JSON.parse(t)}catch(t){e.log(t)}return r},getResponseError(e,t){let r=new Error("Upload error");return c(t)&&(r=new l(r,t)),r},validateStatus:e=>e>=200&&e<300};if(this.opts={...n,...t},this.i18nInit(),this.handleUpload=this.handleUpload.bind(this),r.internalRateLimitedQueue in this.opts?this.requests=this.opts[r.internalRateLimitedQueue]:this.requests=new r.RateLimitedQueue(this.opts.limit),this.opts.bundle&&!this.opts.formData)throw new Error("`opts.formData` must be true when `opts.bundle` is enabled.");this.uploaderEvents=Object.create(null)}getOptions(e){const t=this.uppy.getState().xhrUpload,{headers:r}=this.opts,n={...this.opts,...t||{},...e.xhrUpload||{},headers:{}};return"function"==typeof r?n.headers=r(e):Object.assign(n.headers,this.opts.headers),t&&Object.assign(n.headers,t.headers),e.xhrUpload&&Object.assign(n.headers,e.xhrUpload.headers),n}addMetadata(e,t,r){(Array.isArray(r.metaFields)?r.metaFields:Object.keys(t)).forEach(r=>{e.append(r,t[r])})}createFormDataUpload(e,t){const r=new FormData;this.addMetadata(r,e.meta,t);const n=f(e);return e.name?r.append(t.fieldName,n,e.meta.name):r.append(t.fieldName,n),r}createBundledUpload(e,t){const r=new FormData,{meta:n}=this.uppy.getState();return this.addMetadata(r,n,t),e.forEach(e=>{const t=this.getOptions(e),n=f(e);e.name?r.append(t.fieldName,n,e.name):r.append(t.fieldName,n)}),r}upload(t,r,n){const o=this.getOptions(t);return this.uppy.log(`uploading ${r} of ${n}`),new Promise((r,n)=>{this.uppy.emit("upload-started",t);const i=o.formData?this.createFormDataUpload(t,o):t.data,a=new XMLHttpRequest;let l;this.uploaderEvents[t.id]=new s(this.uppy);const c=new u(o.timeout,()=>{a.abort(),l.done();const e=new Error(this.i18n("timedOut",{seconds:Math.ceil(o.timeout/1e3)}));this.uppy.emit("upload-error",t,e),n(e)}),d=(0,e.nanoid)();a.upload.addEventListener("loadstart",()=>{this.uppy.log(`[XHRUpload] ${d} started`)}),a.upload.addEventListener("progress",e=>{this.uppy.log(`[XHRUpload] ${d} progress: ${e.loaded} / ${e.total}`),c.progress(),e.lengthComputable&&this.uppy.emit("upload-progress",t,{uploader:this,bytesUploaded:e.loaded,bytesTotal:e.total})}),a.addEventListener("load",()=>{if(this.uppy.log(`[XHRUpload] ${d} finished`),c.done(),l.done(),this.uploaderEvents[t.id]&&(this.uploaderEvents[t.id].remove(),this.uploaderEvents[t.id]=null),o.validateStatus(a.status,a.responseText,a)){const e=o.getResponseData(a.responseText,a),n=e[o.responseUrlFieldName],i={status:a.status,body:e,uploadURL:n};return this.uppy.emit("upload-success",t,i),n&&this.uppy.log(`Download ${t.name} from ${n}`),r(t)}const e=o.getResponseData(a.responseText,a),i=h(a,o.getResponseError(a.responseText,a)),s={status:a.status,body:e};return this.uppy.emit("upload-error",t,i,s),n(i)}),a.addEventListener("error",()=>{this.uppy.log(`[XHRUpload] ${d} errored`),c.done(),l.done(),this.uploaderEvents[t.id]&&(this.uploaderEvents[t.id].remove(),this.uploaderEvents[t.id]=null);const e=h(a,o.getResponseError(a.responseText,a));return this.uppy.emit("upload-error",t,e),n(e)}),a.open(o.method.toUpperCase(),o.endpoint,!0),a.withCredentials=o.withCredentials,""!==o.responseType&&(a.responseType=o.responseType),l=this.requests.run(()=>{this.uppy.emit("upload-started",t);const e=this.getOptions(t);return Object.keys(e.headers).forEach(t=>{a.setRequestHeader(t,e.headers[t])}),a.send(i),()=>{c.done(),a.abort()}}),this.onFileRemove(t.id,()=>{l.abort(),n(new Error("File removed"))}),this.onCancelAll(t.id,e=>{let{reason:t}=e;"user"===t&&l.abort(),n(new Error("Upload cancelled"))})})}uploadRemote(e){const r=this.getOptions(e);return new Promise((n,a)=>{this.uppy.emit("upload-started",e);const u={};(Array.isArray(r.metaFields)?r.metaFields:Object.keys(e.meta)).forEach(t=>{u[t]=e.meta[t]});new(e.remote.providerOptions.provider?t.Provider:t.RequestClient)(this.uppy,e.remote.providerOptions).post(e.remote.url,{...e.remote.body,endpoint:r.endpoint,size:e.data.size,fieldname:r.fieldName,metadata:u,httpMethod:r.method,useFormData:r.formData,headers:r.headers}).then(u=>{const{token:l}=u,c=i(e.remote.companionUrl),d=new t.Socket({target:`${c}/api/${l}`,autoOpen:!1});let h;this.uploaderEvents[e.id]=new s(this.uppy),this.onFileRemove(e.id,()=>{d.send("cancel",{}),h.abort(),n(`upload ${e.id} was removed`)}),this.onCancelAll(e.id,function(t){let{reason:r}=void 0===t?{}:t;"user"===r&&(d.send("cancel",{}),h.abort()),n(`upload ${e.id} was canceled`)}),this.onRetry(e.id,()=>{d.send("pause",{}),d.send("resume",{})}),this.onRetryAll(e.id,()=>{d.send("pause",{}),d.send("resume",{})}),d.on("progress",t=>o(this,t,e)),d.on("success",t=>{const o=r.getResponseData(t.response.responseText,t.response),i=o[r.responseUrlFieldName],a={status:t.response.status,body:o,uploadURL:i};return this.uppy.emit("upload-success",e,a),h.done(),this.uploaderEvents[e.id]&&(this.uploaderEvents[e.id].remove(),this.uploaderEvents[e.id]=null),n()}),d.on("error",t=>{const n=t.response,o=n?r.getResponseError(n.responseText,n):Object.assign(new Error(t.error.message),{cause:t.error});this.uppy.emit("upload-error",e,o),h.done(),this.uploaderEvents[e.id]&&(this.uploaderEvents[e.id].remove(),this.uploaderEvents[e.id]=null),a(o)}),h=this.requests.run(()=>(d.open(),e.isPaused&&d.send("pause",{}),()=>d.close()))}).catch(t=>{this.uppy.emit("upload-error",e,t),a(t)})})}uploadBundle(e){return new Promise((t,r)=>{const{endpoint:n}=this.opts,{method:o}=this.opts,i=this.uppy.getState().xhrUpload,a=this.createBundledUpload(e,{...this.opts,...i||{}}),s=new XMLHttpRequest,l=t=>{e.forEach(e=>{this.uppy.emit("upload-error",e,t)})},c=new u(this.opts.timeout,()=>{s.abort();const e=new Error(this.i18n("timedOut",{seconds:Math.ceil(this.opts.timeout/1e3)}));l(e),r(e)});s.upload.addEventListener("loadstart",()=>{this.uppy.log("[XHRUpload] started uploading bundle"),c.progress()}),s.upload.addEventListener("progress",t=>{c.progress(),t.lengthComputable&&e.forEach(e=>{this.uppy.emit("upload-progress",e,{uploader:this,bytesUploaded:t.loaded/t.total*e.size,bytesTotal:e.size})})}),s.addEventListener("load",n=>{if(c.done(),this.opts.validateStatus(n.target.status,s.responseText,s)){const r=this.opts.getResponseData(s.responseText,s),o={status:n.target.status,body:r};return e.forEach(e=>{this.uppy.emit("upload-success",e,o)}),t()}const o=this.opts.getResponseError(s.responseText,s)||new Error("Upload error");return o.request=s,l(o),r(o)}),s.addEventListener("error",()=>{c.done();const e=this.opts.getResponseError(s.responseText,s)||new Error("Upload error");return l(e),r(e)}),this.uppy.on("cancel-all",function(e){let{reason:t}=void 0===e?{}:e;"user"===t&&(c.done(),s.abort())}),s.open(o.toUpperCase(),n,!0),s.withCredentials=this.opts.withCredentials,""!==this.opts.responseType&&(s.responseType=this.opts.responseType),Object.keys(this.opts.headers).forEach(e=>{s.setRequestHeader(e,this.opts.headers[e])}),s.send(a),e.forEach(e=>{this.uppy.emit("upload-started",e)})})}uploadFiles(e){const t=e.map((t,r)=>{const n=parseInt(r,10)+1,o=e.length;return t.error?Promise.reject(new Error(t.error)):t.isRemote?this.uploadRemote(t,n,o):this.upload(t,n,o)});return a(t)}onFileRemove(e,t){this.uploaderEvents[e].on("file-removed",r=>{e===r.id&&t(r.id)})}onRetry(e,t){this.uploaderEvents[e].on("upload-retry",r=>{e===r&&t()})}onRetryAll(e,t){this.uploaderEvents[e].on("retry-all",()=>{this.uppy.getFile(e)&&t()})}onCancelAll(e,t){var r=this;this.uploaderEvents[e].on("cancel-all",function(){r.uppy.getFile(e)&&t(...arguments)})}handleUpload(e){if(0===e.length)return this.uppy.log("[XHRUpload] No files to upload!"),Promise.resolve();0!==this.opts.limit||this.opts[r.internalRateLimitedQueue]||this.uppy.log("[XHRUpload] When uploading multiple files at once, consider setting the `limit` option (to `10` for example), to limit the number of concurrent uploads, which helps prevent memory and network issues: https://uppy.io/docs/xhr-upload/#limit-0","warning"),this.uppy.log("[XHRUpload] Uploading...");const t=e.map(e=>this.uppy.getFile(e));if(this.opts.bundle){if(t.some(e=>e.isRemote))throw new Error("Can’t upload remote files when the `bundle: true` option is set");if("function"==typeof this.opts.headers)throw new TypeError("`headers` may not be a function when the `bundle: true` option is set");return this.uploadBundle(t)}return this.uploadFiles(t).then(()=>null)}install(){if(this.opts.bundle){const{capabilities:e}=this.uppy.getState();this.uppy.setState({capabilities:{...e,individualCancellation:!1}})}this.uppy.addUploader(this.handleUpload)}uninstall(){if(this.opts.bundle){const{capabilities:e}=this.uppy.getState();this.uppy.setState({capabilities:{...e,individualCancellation:!0}})}this.uppy.removeUploader(this.handleUpload)}}return p.VERSION="2.1.3",Hx=p}(),Gx=b(Wx);function Yx(e){var t=e.server,r=void 0===t?"":t,n=e.fieldName,o=void 0===n?"":n,i=e.maxFileSize,a=void 0===i?10485760:i,s=e.maxNumberOfFiles,u=void 0===s?100:s,l=e.meta,c=void 0===l?{}:l,d=e.metaWithUrl,h=void 0!==d&&d,f=e.headers,p=void 0===f?{}:f,g=e.withCredentials,m=void 0!==g&&g,v=e.timeout,y=void 0===v?1e4:v,b=e.onBeforeUpload,D=void 0===b?function(e){return e}:b,C=e.onSuccess,w=void 0===C?function(e,t){}:C,E=e.onError,A=void 0===E?function(e,t,r){console.error("".concat(e.name," upload error"),t,r)}:E,x=e.onProgress,B=void 0===x?function(e){}:x;if(!r)throw new Error("Cannot get upload server address\n没有配置上传地址");if(!o)throw new Error("Cannot get fieldName\n没有配置 fieldName");var S=r;h&&(S=function(e,t){var r=Qg(e.split("#"),2),n=r[0],o=r[1],i=[];lm(t,function(e,t){i.push("".concat(t,"=").concat(e))});var a=i.join("&");return n=n.indexOf("?")>0?"".concat(n,"&").concat(a):"".concat(n,"?").concat(a),o?"".concat(n,"#").concat(o):n}(S,c));var F=new dx(Kg({onBeforeUpload:D,restrictions:{maxFileSize:a,maxNumberOfFiles:u},meta:c},e.uppyConfig)).use(Gx,Kg({endpoint:S,headers:p,formData:!0,fieldName:o,bundle:!0,withCredentials:m,timeout:y},e.xhrConfig));return F.on("complete",function(e){var t=e.successful[0],r=t.response,n=(null!=r?r:{}).body,o=void 0===n?{}:n;try{w(t,o)}catch(e){console.error("wangEditor upload file - onSuccess error",e)}}),F.on("progress",function(e){e<1||B(e)}),F.on("upload-error",function(e,t,r){try{A(e,t,r)}catch(e){console.error("wangEditor upload file - onError error",e)}}),F.on("restriction-failed",function(e,t){try{A(e,t)}catch(e){console.error("wangEditor upload file - onError error",e)}}),F}XD("en",{editor:{more:"More",justify:"Justify",indent:"Indent",image:"Image",video:"Video"}}),XD("zh-CN",{editor:{more:"更多",justify:"对齐",indent:"缩进",image:"图片",video:"视频"}});var Kx,Xx,Zx,Jx,Qx,eB,tB,rB,nB,oB,iB,aB,sB,uB,lB,cB={};function dB(){if(Xx)return Kx;Xx=1;var e=A();return Kx=Array.isArray||function(t){return"Array"===e(t)}}function hB(){if(Jx)return Zx;Jx=1;var e=E(),t=C(),r=ve(),n=On(),o=Ht(),i=Ar(),a=function(){},s=o("Reflect","construct"),u=/^\s*(?:class|function)\b/,l=e(u.exec),c=!u.test(a),d=function(e){if(!r(e))return!1;try{return s(a,[],e),!0}catch(e){return!1}},h=function(e){if(!r(e))return!1;switch(n(e)){case"AsyncFunction":case"GeneratorFunction":case"AsyncGeneratorFunction":return!1}try{return c||!!l(u,i(e))}catch(e){return!0}};return h.sham=!0,Zx=!s||t(function(){var e;return d(d.call)||!d(Object)||!d(function(){e=!0})||e})?h:d}function fB(){if(eB)return Qx;eB=1;var e=dB(),t=hB(),r=ye(),n=me()("species"),o=Array;return Qx=function(i){var a;return e(i)&&(a=i.constructor,(t(a)&&(a===o||e(a.prototype))||r(a)&&null===(a=a[n]))&&(a=void 0)),void 0===a?o:a},Qx}function pB(){if(rB)return tB;rB=1;var e=fB();return tB=function(t,r){return new(e(t))(0===r?0:r)}}function gB(){if(aB)return iB;aB=1;var e=C();return iB=function(t,r){var n=[][t];return!!n&&e(function(){n.call(null,r||function(){return 1},1)})}}function mB(){if(uB)return sB;uB=1;var e=function(){if(oB)return nB;oB=1;var e=Wo(),t=E(),r=x(),n=ce(),o=Jt(),i=pB(),a=t([].push),s=function(t){var s=1===t,u=2===t,l=3===t,c=4===t,d=6===t,h=7===t,f=5===t||d;return function(p,g,m,v){for(var y,b,D=n(p),C=r(D),w=o(C),E=e(g,m),A=0,x=v||i,B=s?x(p,w):u||h?x(p,0):void 0;w>A;A++)if((f||A in C)&&(b=E(y=C[A],A,D),t))if(s)B[A]=b;else if(b)switch(t){case 3:return!0;case 5:return y;case 6:return A;case 2:a(B,y)}else switch(t){case 4:return!1;case 7:a(B,y)}return d?-1:l||c?c:B}};return nB={forEach:s(0),map:s(1),filter:s(2),some:s(3),every:s(4),find:s(5),findIndex:s(6),filterReject:s(7)}}().forEach,t=gB()("forEach");return sB=t?[].forEach:function(t){return e(this,t,arguments.length>1?arguments[1]:void 0)},sB}!function(){if(lB)return cB;lB=1;var e=k(),t=ci(),r=di(),n=mB(),o=ur(),i=function(e){if(e&&e.forEach!==n)try{o(e,"forEach",n)}catch(t){e.forEach=n}};for(var a in t)t[a]&&i(e[a]&&e[a].prototype);i(r)}();XD("en",{common:{ok:"OK",delete:"Delete",enter:"Enter"},blockQuote:{title:"Quote"},codeBlock:{title:"Code block"},color:{color:"Font color",bgColor:"Back color",default:"Default color",clear:"Clear back color"},divider:{title:"Divider"},emotion:{title:"Emotion"},fontSize:{title:"Font size",default:"Default"},fontFamily:{title:"Font family",default:"Default"},fullScreen:{title:"Full screen",cancelTitle:"Cancel full screen"},header:{title:"Header",text:"Text"},image:{netImage:"Net image",delete:"Delete image",edit:"Edit image",editSize:"Edit size",viewLink:"View link",src:"Image src",desc:"Description",link:"Image link",ok:"Ok",width:"Width",height:"Height"},indent:{decrease:"Decrease",increase:"Increase"},justify:{left:"Left",right:"Right",center:"Center",justify:"Justify"},lineHeight:{title:"Line height",default:"Default"},link:{insert:"Insert link",text:"Link text",url:"Link source",unLink:"Unlink",edit:"Edit link",view:"View link"},textStyle:{bold:"Bold",clear:"Clear styles",code:"Inline code",italic:"Italic",sub:"Sub",sup:"Sup",through:"Through",underline:"Underline"},undo:{undo:"undo",redo:"Redo"},todo:{todo:"Todo"},formatPainter:{title:"Format Painter"}}),XD("zh-CN",{common:{ok:"确定",delete:"删除",enter:"回车"},blockQuote:{title:"引用"},codeBlock:{title:"代码块"},color:{color:"文字颜色",bgColor:"背景色",default:"默认颜色",clear:"清除背景色"},divider:{title:"分割线"},emotion:{title:"表情"},fontSize:{title:"字号",default:"默认字号"},fontFamily:{title:"字体",default:"默认字体"},fullScreen:{title:"全屏",cancelTitle:"取消全屏"},header:{title:"标题",text:"正文"},image:{netImage:"网络图片",delete:"删除图片",edit:"编辑图片",editSize:"修改尺寸",viewLink:"查看链接",src:"图片地址",desc:"图片描述",link:"图片链接",ok:"确定",width:"宽度",height:"高度"},indent:{decrease:"减少缩进",increase:"增加缩进"},justify:{left:"左对齐",right:"右对齐",center:"居中对齐",justify:"两端对齐"},lineHeight:{title:"行高",default:"默认行高"},link:{insert:"插入链接",text:"链接文本",url:"链接地址",unLink:"取消链接",edit:"修改链接",view:"查看链接"},textStyle:{bold:"粗体",clear:"清除格式",code:"行内代码",italic:"斜体",sub:"下标",sup:"上标",through:"删除线",underline:"下划线"},undo:{undo:"撤销",redo:"重做"},todo:{todo:"待办"},formatPainter:{title:"格式刷"}});var vB={type:"blockquote",elemToHtml:function(e,t){return"<blockquote>".concat(t,"</blockquote>")}},yB='<svg viewBox="0 0 1024 1024"><path d="M864 0a160 160 0 0 1 128 256l-64 64-224-224 64-64c26.752-20.096 59.968-32 96-32zM64 736l-64 288 288-64 592-592-224-224L64 736z m651.584-372.416l-448 448-55.168-55.168 448-448 55.168 55.168z"></path></svg>',bB='<svg viewBox="0 0 1024 1024"><path d="M924.402464 1023.068211H0.679665V99.345412h461.861399v98.909208H99.596867v725.896389h725.896389V561.206811h98.909208z" p-id="10909"></path><path d="M930.805104 22.977336l69.965436 69.965436-453.492405 453.492404-69.965435-69.901489z" p-id="10910"></path><path d="M1022.464381 304.030081h-98.917201V99.345412H709.230573V0.428211h313.233808z"></path></svg>',DB='<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>',CB=function(){function e(){this.title=eC("blockQuote.title"),this.iconSvg='<svg viewBox="0 0 1024 1024"><path d="M894.6 907.1H605.4c-32.6 0-59-26.4-59-59V608.2l-4-14.9c0-315.9 125.5-485.1 376.5-507.5v59.8C752.7 180.4 711.3 315.8 711.3 442.4v41.2l31.5 12.3h151.8c32.6 0 59 26.4 59 59v293.2c0 32.5-26.4 59-59 59z m-472 0H133.4c-32.6 0-59-26.4-59-59V608.2l-4-14.9c0-315.9 125.5-485.1 376.5-507.5v59.8C280.7 180.4 239.3 315.8 239.3 442.4v41.2l31.5 12.3h151.8c32.6 0 59 26.4 59 59v293.2c0 32.5-26.4 59-59 59z"></path></svg>',this.tag="button"}return e.prototype.getValue=function(e){return""},e.prototype.isActive=function(e){return!!Ry.getSelectedNodeByType(e,"blockquote")},e.prototype.isDisabled=function(e){if(null==e.selection)return!0;var t=Qg(Yp.nodes(e,{match:function(e){var t=Ry.getNodeType(e);return"paragraph"===t||"blockquote"===t},universal:!0,mode:"highest"}),1);return!t[0]},e.prototype.exec=function(e,t){if(!this.isDisabled(e)){var r=this.isActive(e)?"paragraph":"blockquote";zg.setNodes(e,{type:r},{mode:"highest"})}},e}(),wB={key:"blockquote",factory:function(){return new CB}};function EB(e){return 0===ov("<div>".concat(e,"</div>")).children().filter(function(e){return"BR"!==e.tagName}).length}function AB(e){return 0===e.length?"":e[0].outerHTML}function xB(e){return e.length?e[0].tagName.toLowerCase():""}function BB(e,t){for(var r="",n=(e.attr("style")||"").split(";"),o=n.length,i=0;i<o;i+=1){var a=n[i];if(a){var s=a.split(":");s[0].trim()===t&&(r=s[1].trim())}}return r}Dv&&(ov.fn.css=Dv),Bv&&(ov.fn.append=Bv),Sv&&(ov.fn.prepend=Sv),iv&&(ov.fn.addClass=iv),av&&(ov.fn.removeClass=av),sv&&(ov.fn.hasClass=sv),fv&&(ov.fn.on=fv),pv&&(ov.fn.off=pv),Lv&&(ov.fn.focus=Lv),uv&&(ov.fn.attr=uv),lv&&(ov.fn.removeAttr=lv),yv&&(ov.fn.hide=yv),bv&&(ov.fn.show=bv),kv&&(ov.fn.parents=kv),dv&&(ov.fn.dataset=dv),hv&&(ov.fn.val=hv),Av&&(ov.fn.text=Av),Ev&&(ov.fn.html=Ev),Tv&&(ov.fn.children=Tv),Nv&&(ov.fn.remove=Nv),Ov&&(ov.fn.find=Ov),gv&&(ov.fn.width=gv),mv&&(ov.fn.height=mv),wv&&(ov.fn.filter=wv),Pv&&(ov.fn.empty=Pv);var SB={selector:"blockquote:not([data-w-e-type])",parseElemHtml:function(e,t,r){var n=ov(e);return 0===(t=t.filter(function(e){return!!Cg.isText(e)||!!r.isInline(e)})).length&&(t=[{text:n.text().replace(/\s+/gm," ")}]),{type:"blockquote",children:t}}};function FB(e){e.deleteBackward("character");zg.insertNodes(e,{type:"paragraph",children:[{text:""}]},{mode:"highest"})}var kB={type:"blockquote",renderElem:function(e,t,r){return Tw("blockquote",null,t)}},OB={renderElems:[kB],elemsToHtml:[vB],parseElemsHtml:[SB],menus:[wB],editorPlugin:function(e){var t=e.insertBreak,r=e.insertText,n=e;return n.insertBreak=function(){var o=n.selection;if(null==o)return t();var i=Qg(Yp.nodes(e,{match:function(e){return Ry.checkNodeType(e,"blockquote")},universal:!0}),1),a=i[0];if(!a)return t();var s=a[0];if(Ry.getParentNode(e,s)){var u=Ry.findPath(e,s),l=Yp.end(e,u);if(ug.equals(l,o.focus)){var c=eg.string(s);if(c&&"\n"===c.slice(-1))return void FB(n)}r("\n")}else FB(n)},n}};var TB={type:"code",elemToHtml:function(e,t){return"<code>".concat(t,"</code>")}};var NB={type:"pre",elemToHtml:function(e,t){return"<pre>".concat(t,"</pre>")}},PB=function(){function e(){this.title=eC("codeBlock.title"),this.iconSvg='<svg viewBox="0 0 1280 1024"><path d="M832 736l96 96 320-320L928 192l-96 96 224 224zM448 288l-96-96L32 512l320 320 96-96-224-224zM701.312 150.528l69.472 18.944-192 704.032-69.472-18.944 192-704.032z"></path></svg>',this.tag="button"}return e.prototype.getSelectCodeElem=function(e){var t=Ry.getSelectedNodeByType(e,"code");if(null==t)return null;var r=Ry.getParentNode(e,t);return null==r||"pre"!==Ry.getNodeType(r)?null:t},e.prototype.getValue=function(e){var t=this.getSelectCodeElem(e);if(null==t){var r=e.getMenuConfig("codeSelectLang").codeLangs,n=(void 0===r?[]:r).find(function(e){return e.selected});return(null==n?void 0:n.value)||""}return t.language||""},e.prototype.isActive=function(e){return!!this.getSelectCodeElem(e)},e.prototype.isDisabled=function(e){if(null==e.selection)return!0;var t=Ry.getSelectedElems(e);return!!t.some(function(t){return e.isVoid(t)})||!t.some(function(e){var t=Ry.getNodeType(e);return"pre"===t||"paragraph"===t})},e.prototype.exec=function(e,t){this.isActive(e)?this.changeToPlainText(e):this.changeToCodeBlock(e,t.toString())},e.prototype.changeToPlainText=function(e){var t=this.getSelectCodeElem(e);if(null!=t){var r=eg.string(t);zg.removeNodes(e,{mode:"highest"});var n=r.split("\n").map(function(e){return{type:"paragraph",children:[{text:e}]}});zg.insertNodes(e,n,{mode:"highest"})}},e.prototype.changeToCodeBlock=function(e,t){var r,n,o=[],i=Yp.nodes(e,{match:function(t){return e.children.includes(t)},universal:!0});try{for(var a=Jg(i),s=a.next();!s.done;s=a.next()){var u=Qg(s.value,1)[0];u&&o.push(eg.string(u))}}catch(e){r={error:e}}finally{try{s&&!s.done&&(n=a.return)&&n.call(a)}finally{if(r)throw r.error}}zg.removeNodes(e,{mode:"highest"});var l={type:"pre",children:[{type:"code",language:t,children:[{text:o.join("\n")}]}]};zg.insertNodes(e,l,{mode:"highest"})},e}();var MB={selector:"pre:not([data-w-e-type])",parseElemHtml:function(e,t,r){var n=ov(e);return 0===(t=t.filter(function(e){return"code"===Ry.getNodeType(e)})).length&&(t=[{type:"code",language:"",children:[{text:n[0].textContent||""}]}]),{type:"pre",children:t.filter(function(e){return"code"===Ry.getNodeType(e)})}}};var IB={type:"pre",renderElem:function(e,t,r){return Tw("pre",null,t)}},RB={type:"code",renderElem:function(e,t,r){return Tw("code",null,t)}},LB={menus:[{key:"codeBlock",factory:function(){return new PB}}],editorPlugin:function(e){var t=e.insertBreak,r=e.normalizeNode,n=e.insertData,o=e.handleTab,i=e;return i.insertBreak=function(){var e=Ry.getSelectedNodeByType(i,"code");if(null!=e){var r=function(e,t){var r=t.selection;if(null==r)return"";var n=eg.string(e),o=r.anchor.offset,i=n.slice(0,o).split("\n"),a=i.length;return 0===a?"":i[a-1]}(e,i);if(r){var n=r.match(/^\s+/);if(null!=n&&null!=n[0]){var o=n[0];return void i.insertText("\n".concat(o))}}i.insertText("\n")}else t()},e.handleTab=function(){var t=e.selection;if(t){var r=Ry.getSelectedNodeByType(e,"code");if(r&&!hg.isCollapsed(t)){var n=Qg([t.anchor,t.focus].sort(function(e,t){return e.offset-t.offset}),2),i=n[0],a=n[1],s=r.children[0].text,u=s.split("\n"),l=s.slice(0,i.offset).split("\n").length-1,c=s.slice(0,a.offset).split("\n").length-1,d=u.map(function(e,t){return t>=l&&t<=c?" ".concat(e):e}),h=d.join("\n"),f={anchor:{path:i.path,offset:i.offset+2},focus:{path:a.path,offset:a.offset+2}};zg.insertText(e,h,{at:{anchor:{path:i.path,offset:0},focus:{path:a.path,offset:s.length}}}),zg.select(e,f)}else o()}},i.normalizeNode=function(e){var t=Qg(e,2),n=t[0],o=t[1],a=Ry.getNodeType(n);("code"===a&&o.length<=1&&zg.setNodes(i,{type:"paragraph"},{at:o}),"pre"===a)&&(Ry.isLastNode(i,n)&&zg.insertNodes(i,Ry.genEmptyParagraph(),{at:[o[0]+1]}),"code"!==Ry.getNodeType(n.children[0])&&(zg.unwrapNodes(i),zg.setNodes(i,{type:"paragraph"},{mode:"highest"})));return r([n,o])},i.insertData=function(e){if(null!=Ry.getSelectedNodeByType(i,"code")){var t=e.getData("text/plain");Yp.insertText(i,t)}else n(e)},i},renderElems:[IB,RB],elemsToHtml:[TB,NB],preParseHtml:[{selector:"pre>code",preParseHtml:function(e){var t=ov(e);if("code"!==xB(t))return e;var r=t.find("xmp");if(0===r.length)return e;var n=r.text();return r.remove(),t.text(n),t[0]}}],parseElemsHtml:[{selector:"pre:not([data-w-e-type])>code",parseElemHtml:function(e,t,r){return{type:"code",language:"",children:[{text:ov(e)[0].textContent||""}]}}},MB]},_B=function(){function e(){this.tag="button",this.showDropPanel=!0,this.$content=null}return e.prototype.exec=function(e,t){},e.prototype.getValue=function(e){var t=this.mark,r=Yp.marks(e);return r&&r[t]?r[t]:""},e.prototype.isActive=function(e){return!!this.getValue(e)},e.prototype.isDisabled=function(e){if(null==e.selection)return!0;var t=Qg(Yp.nodes(e,{match:function(t){return"pre"===Ry.getNodeType(t)||!!Yp.isVoid(e,t)},universal:!0}),1);return!!t[0]},e.prototype.getPanelContentElem=function(e){var t=this.mark;if(null==this.$content){var r=ov('<ul class="w-e-panel-content-color"></ul>');r.on("click","li",function(r){var n=r.target;if(null!=n&&(r.preventDefault(),null!=e.selection)){var o=ov(n).attr("data-value");"0"===o?Yp.removeMark(e,t):Yp.addMark(e,t,o)}}),this.$content=r}var n=this.$content;if(null==n)return document.createElement("ul");n.empty();var o=this.getValue(e),i=e.getMenuConfig(t).colors;(void 0===i?[]:i).forEach(function(e){var t=ov('<div class="color-block" data-value="'.concat(e,'"></div>'));t.css("background-color",e);var r=ov('<li data-value="'.concat(e,'"></li>'));o===e&&r.addClass("active"),r.append(t),n.append(r)});var a="";"color"===t&&(a=eC("color.default")),"bgColor"===t&&(a=eC("color.clear"));var s=ov('\n <li data-value="0" class="clear">\n '.concat('<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>',"\n ").concat(a,"\n </li>\n "));return n.prepend(s),n[0]},e}(),zB=function(e){function t(){var t=e.apply(this,em([],Qg(arguments),!1))||this;return t.title=eC("color.bgColor"),t.iconSvg='<svg viewBox="0 0 1024 1024"><path d="M510.030769 315.076923l84.676923 196.923077h-177.230769l76.8-196.923077h15.753846zM945.230769 157.538462v708.923076c0 43.323077-35.446154 78.769231-78.769231 78.769231H157.538462c-43.323077 0-78.769231-35.446154-78.769231-78.769231V157.538462c0-43.323077 35.446154-78.769231 78.769231-78.769231h708.923076c43.323077 0 78.769231 35.446154 78.769231 78.769231z m-108.307692 643.938461L600.615385 216.615385c-5.907692-11.815385-15.753846-19.692308-29.538462-19.692308h-139.815385c-11.815385 0-23.630769 7.876923-27.56923 19.692308l-216.615385 584.861538c-3.938462 11.815385 3.938462 25.6 17.723077 25.6h80.738462c11.815385 0 23.630769-9.846154 27.56923-21.661538l63.015385-175.261539h263.876923l68.923077 175.261539c3.938462 11.815385 15.753846 21.661538 27.569231 21.661538h80.738461c13.784615 0 23.630769-13.784615 19.692308-25.6z"></path></svg>',t.mark="bgColor",t}return Yg(t,e),t}(_B),jB=function(e){function t(){var t=e.apply(this,em([],Qg(arguments),!1))||this;return t.title=eC("color.color"),t.iconSvg='<svg viewBox="0 0 1024 1024"><path d="M64 864h896v96H64zM360.58 576h302.85l81.53 224h102.16L579.24 64H444.77L176.89 800h102.16l81.53-224zM512 159.96L628.49 480H395.52L512 159.96z"></path></svg>',t.mark="color",t}return Yg(t,e),t}(_B),HB=["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)"];var VB={selector:"font",preParseHtml:function(e){var t=ov(e);if("font"!==xB(t))return e;var r=t.attr("color")||"";return r&&(t.removeAttr("color"),t.css("color",r)),t[0]}};function $B(e,t){null==e.data&&(e.data={});var r=e.data;null==r.style&&(r.style={}),Object.assign(r.style,t)}var UB={renderStyle:function(e,t){var r=e,n=r.color,o=r.bgColor,i=t;return n&&$B(i,{color:n}),o&&$B(i,{backgroundColor:o}),i},styleToHtml:function(e,t){if(!Cg.isText(e))return t;var r,n=e,o=n.color,i=n.bgColor;return o||i?((EB(t)||"span"!==xB(r=ov(t)))&&(r=ov("<span>".concat(t,"</span>"))),o&&r.css("color",o),i&&r.css("background-color",i),AB(r)):t},preParseHtml:[VB],parseStyleHtml:function(e,t,r){var n=ov(e);if(!Cg.isText(t))return t;var o=t,i=BB(n,"color");i&&(o.color=i);var a=BB(n,"background-color");return a||(a=BB(n,"background")),a&&(o.bgColor=a),o},menus:[{key:"color",factory:function(){return new jB},config:{colors:HB}},{key:"bgColor",factory:function(){return new zB},config:{colors:HB}}]},qB=function(){function e(){this.title=eC("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 e.prototype.getValue=function(e){return""},e.prototype.isActive=function(e){return!1},e.prototype.isDisabled=function(e){var t=e.selection;return null==t||!!hg.isExpanded(t)},e.prototype.exec=function(e,t){var r=e.selection;if(null!=r){var n=[r.anchor.path[0]];zg.insertNodes(e,{type:"paragraph",children:[{text:""}]},{at:n}),e.select(Yp.start(e,n))}},e}(),WB={menus:[{key:"enter",factory:function(){return new qB}}]};var GB={type:"divider",elemToHtml:function(e,t){return"<hr/>"}},YB=function(){function e(){this.title=eC("divider.title"),this.iconSvg='<svg viewBox="0 0 1092 1024"><path d="M0 51.2m51.2 0l989.866667 0q51.2 0 51.2 51.2l0 0q0 51.2-51.2 51.2l-989.866667 0q-51.2 0-51.2-51.2l0 0q0-51.2 51.2-51.2Z"></path><path d="M0 460.8m51.2 0l170.666667 0q51.2 0 51.2 51.2l0 0q0 51.2-51.2 51.2l-170.666667 0q-51.2 0-51.2-51.2l0 0q0-51.2 51.2-51.2Z"></path><path d="M819.2 460.8m51.2 0l170.666667 0q51.2 0 51.2 51.2l0 0q0 51.2-51.2 51.2l-170.666667 0q-51.2 0-51.2-51.2l0 0q0-51.2 51.2-51.2Z"></path><path d="M409.6 460.8m51.2 0l170.666667 0q51.2 0 51.2 51.2l0 0q0 51.2-51.2 51.2l-170.666667 0q-51.2 0-51.2-51.2l0 0q0-51.2 51.2-51.2Z"></path><path d="M0 870.4m51.2 0l989.866667 0q51.2 0 51.2 51.2l0 0q0 51.2-51.2 51.2l-989.866667 0q-51.2 0-51.2-51.2l0 0q0-51.2 51.2-51.2Z"></path></svg>',this.tag="button"}return e.prototype.getValue=function(e){return""},e.prototype.isActive=function(e){return!1},e.prototype.isDisabled=function(e){return null==e.selection||!!Ry.getSelectedElems(e).some(function(t){if(e.isVoid(t))return!0;var r=Ry.getNodeType(t);return"table"===r||"pre"===r})},e.prototype.exec=function(e,t){Ry.isSelectedEmptyParagraph(e)&&zg.removeNodes(e,{mode:"highest"}),zg.insertNodes(e,{type:"divider",children:[{text:""}]},{mode:"highest"})},e}();var KB={renderElems:[{type:"divider",renderElem:function(e,t,r){return dw("div",{props:{contentEditable:!1,className:"w-e-textarea-divider"},dataset:{selected:Ry.isNodeSelected(r,e)?"true":""},style:{},on:{mousedown:function(e){return e.preventDefault()}}},[dw("hr")])}}],elemsToHtml:[GB],parseElemsHtml:[{selector:"hr:not([data-w-e-type])",parseElemHtml:function(e,t,r){return{type:"divider",children:[{text:""}]}}}],menus:[{key:"divider",factory:function(){return new YB}}],editorPlugin:function(e){var t=e.isVoid,r=e.normalizeNode,n=e;return n.isVoid=function(e){return"divider"===e.type||t(e)},n.normalizeNode=function(e){var t=Qg(e,2),o=t[0],i=t[1];if("divider"!==Ry.getNodeType(o))return r([o,i]);Ry.isLastNode(n,o)&&zg.insertNodes(n,Ry.genEmptyParagraph(),{at:[i[0]+1]})},n}};var XB=function(){function e(){this.title=eC("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 e.prototype.exec=function(e,t){},e.prototype.getValue=function(e){return""},e.prototype.isActive=function(e){return!1},e.prototype.isDisabled=function(e){if(null==e.selection)return!0;var t=Qg(Yp.nodes(e,{match:function(t){return"pre"===Ry.getNodeType(t)||!!Yp.isVoid(e,t)},universal:!0}),1);return!!t[0]},e.prototype.getPanelContentElem=function(e){if(null==this.$content){var t=ov('<ul class="w-e-panel-content-emotion"></ul>');t.on("click","li",function(t){var r=t.target;if(null!=r){t.preventDefault();var n=ov(r).text();e.insertText(n)}}),this.$content=t}var r=this.$content;if(null==r)return document.createElement("ul");r.empty();var n=e.getMenuConfig("emotion").emotions;return(void 0===n?[]:n).forEach(function(e){var t=ov("<li>".concat(e,"</li>"));r.append(t)}),r[0]},e}(),ZB={menus:[{key:"emotion",factory:function(){return new XB},config:{emotions:"😀 😃 😄 😁 😆 😅 😂 🤣 😊 😇 🙂 🙃 😉 😌 😍 😘 😗 😙 😚 😋 😛 😝 😜 🤓 😎 😏 😒 😞 😔 😟 😕 🙁 😣 😖 😫 😩 😢 😭 😤 😠 😡 😳 😱 😨 🤗 🤔 😶 😑 😬 🙄 😯 😴 😷 🤑 😈 🤡 💩 👻 💀 👀 👣 👐 🙌 👏 🤝 👍 👎 👊 ✊ 🤛 🤜 🤞 ✌️ 🤘 👌 👈 👉 👆 👇 ☝️ ✋ 🤚 🖐 🖖 👋 🤙 💪 🖕 ✍️ 🙏".split(" ")}}]};var JB=function(){function e(){this.tag="select",this.width=80}return e.prototype.isActive=function(e){return!1},e.prototype.getValue=function(e){var t=this.mark,r=Yp.marks(e);return r&&r[t]?r[t]:""},e.prototype.isDisabled=function(e){if(null==e.selection)return!0;var t=Qg(Yp.nodes(e,{match:function(t){return"pre"===Ry.getNodeType(t)||!!Yp.isVoid(e,t)},universal:!0}),1);return!!t[0]},e.prototype.exec=function(e,t){var r=this.mark;t?e.addMark(r,t):e.removeMark(r)},e}(),QB=function(e){function t(){var t=e.apply(this,em([],Qg(arguments),!1))||this;return t.title=eC("fontFamily.title"),t.iconSvg='<svg viewBox="0 0 1024 1024"><path d="M956.788364 152.110545h-24.110546l23.924364 9.029819 0.186182 121.018181h-65.070546l-86.574545-130.048H566.551273v650.14691l130.048 64.977454v65.163636h-390.050909v-65.163636l129.954909-64.977454V152.110545H198.283636L111.429818 282.065455H46.545455V69.259636C46.545455 33.792 82.664727 22.062545 98.955636 22.062545h812.683637c23.738182 0 45.056 15.173818 45.056 41.053091V169.425455v-17.221819z"></path></svg>',t.mark="fontFamily",t.selectPanelWidth=150,t}return Yg(t,e),t.prototype.getOptions=function(e){var t=[],r=e.getMenuConfig(this.mark).fontFamilyList,n=void 0===r?[]:r;t.push({text:eC("fontFamily.default"),value:""}),n.forEach(function(e){if("string"==typeof e)t.push({text:e,value:e,styleForRenderMenuList:{"font-family":e}});else if("object"==typeof e){var r=e.name,n=e.value;t.push({text:r,value:n,styleForRenderMenuList:{"font-family":n}})}});var o=this.getValue(e),i=!1;return t.forEach(function(e){e.value===o?(i=!0,e.selected=!0):e.selected=void 0}),i||"string"!=typeof o||t.push({text:o,value:o,selected:!0}),t},t}(JB),eS=function(e){function t(){var t=e.apply(this,em([],Qg(arguments),!1))||this;return t.title=eC("fontSize.title"),t.iconSvg='<svg viewBox="0 0 1024 1024"><path d="M64 512h384v128h-128V1024h-128V640h-128z m896-256H708.2496v768h-136.4992V256H320V128h640z"></path></svg>',t.mark="fontSize",t}return Yg(t,e),t.prototype.getOptions=function(e){var t=[],r=e.getMenuConfig(this.mark).fontSizeList,n=void 0===r?[]:r;t.push({text:eC("fontSize.default"),value:""}),n.forEach(function(e){if("string"==typeof e)t.push({text:e,value:e});else if("object"==typeof e){var r=e.name,n=e.value;t.push({text:r,value:n})}});var o=this.getValue(e),i=!1;return t.forEach(function(e){e.value===o?(i=!0,e.selected=!0):e.selected=void 0}),i||"string"!=typeof o||t.push({text:o,value:o,selected:!0}),t},t}(JB);var tS={1:"12px",2:"14px",3:"16px",4:"19px",5:"24px",6:"32px",7:"48px"};var rS={renderStyle:function(e,t){var r=e,n=r.fontSize,o=r.fontFamily,i=t;return n&&$B(i,{fontSize:n}),o&&$B(i,{fontFamily:o}),i},styleToHtml:function(e,t){if(!Cg.isText(e))return t;var r,n=e,o=n.fontSize,i=n.fontFamily;return o||i?((EB(t)||"span"!==xB(r=ov(t)))&&(r=ov("<span>".concat(t,"</span>"))),o&&r.css("font-size",o),i&&r.css("font-family",i),AB(r)):t},preParseHtml:[{selector:"font",preParseHtml:function(e){var t=ov(e);if("font"!==xB(t))return e;var r=t.attr("size")||"";r&&(t.removeAttr("size"),t.css("font-size",tS[r]));var n=t.attr("face")||"";return n&&(t.removeAttr("face"),t.css("font-family",n)),t[0]}}],parseStyleHtml:function(e,t,r){var n=ov(e);if(!Cg.isText(t))return t;var o=t,i=BB(n,"font-size");i&&(o.fontSize=i);var a=BB(n,"font-family").replace(/"/g,"");return a&&(o.fontFamily=a),o},menus:[{key:"fontSize",factory:function(){return new eS},config:{fontSizeList:["12px",{name:"13px",value:"13px"},"14px","15px","16px","19px",{name:"22px",value:"22px"},"24px","29px","32px","40px","48px"]}},{key:"fontFamily",factory:function(){return new QB},config:{fontFamilyList:["黑体",{name:"仿宋",value:"仿宋"},"楷体","标楷体","华文仿宋","华文楷体",{name:"宋体",value:"宋体"},"微软雅黑","Arial","Tahoma","Verdana","Times New Roman","Courier New"]}}]};var nS=function(){function e(){this.title=eC("formatPainter.title"),this.iconSvg='<svg viewBox="0 0 24 24"><path d="M8 19.997v-5h2v5h9v-7H5v7zm-4-9h16v-3h-6v-4h-4v4H4zm-1 10v-8H2v-6a1 1 0 0 1 1-1h5v-3a1 1 0 0 1 1-1h6a1 1 0 0 1 1 1v3h5a1 1 0 0 1 1 1v6h-1v8a1 1 0 0 1-1 1H4a1 1 0 0 1-1-1"/></svg>',this.tag="button"}return e.prototype.getValue=function(e){return""},e.prototype.isActive=function(t){return e.attrs.isSelect},e.prototype.isDisabled=function(e){return!1},e.prototype.setFormatHtml=function(t){var r,n;if(t.getSelectionText().length){if(e.attrs.formatStyle){!function(e){var t=Yp.marks(e);t&&Object.keys(t).forEach(function(t){e.removeMark(t)})}(t);try{for(var o=Jg(Object.entries(e.attrs.formatStyle)),i=o.next();!i.done;i=o.next()){var a=Qg(i.value,2),s=a[0],u=a[1];t.addMark(s,u)}}catch(e){r={error:e}}finally{try{i&&!i.done&&(n=o.return)&&n.call(o)}finally{if(r)throw r.error}}}e.attrs.formatStyle=null,e.attrs.isSelect=!1}},e.prototype.exec=function(t){e.attrs.isSelect?(e.attrs.isSelect=!1,e.attrs.formatStyle=null):t.getSelectionText().length&&(e.attrs.formatStyle=Yp.marks(t),e.attrs.isSelect=!0);t.blur(),t.focus()},e.attrs={isSelect:!1,formatStyle:null},e}();var oS={menus:[{key:"formatPainter",factory:function(){return new nS}}],editorPlugin:function(e){var t=new nS,r=e.onChange,n=e,o=function(){t.setFormatHtml(n),document.removeEventListener("mouseup",o)};return n.onChange=function(){r(),nS.attrs.isSelect&&(document.removeEventListener("mouseup",o),document.addEventListener("mouseup",o))},n}},iS=function(){function e(){this.title=eC("fullScreen.title"),this.iconSvg=DB,this.tag="button",this.alwaysEnable=!0}return e.prototype.getValue=function(e){return""},e.prototype.isActive=function(e){return e.isFullScreen},e.prototype.isDisabled=function(e){return!1},e.prototype.getIcon=function(e){return e.isFullScreen?DB:'<svg t="1723361745825" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="8705" width="200" height="200"><path d="M703.926857 362.642286a42.642286 42.642286 0 0 1-42.642286-42.642286V128a42.642286 42.642286 0 1 1 85.357715 0v149.357714h149.357714c21.211429 0 38.765714 15.433143 42.057143 35.693715l0.585143 6.948571a42.642286 42.642286 0 0 1-42.642286 42.642286H703.926857zM703.926857 938.642286a42.642286 42.642286 0 0 1-42.642286-42.642286V704c0-23.552 19.090286-42.642286 42.642286-42.642286h192.073143a42.642286 42.642286 0 1 1 0 85.284572l-149.357714 0.073143v149.284571c0 21.211429-15.506286 38.765714-35.84 42.130286l-6.875429 0.512zM319.853714 938.642286a42.642286 42.642286 0 0 1-42.642285-42.642286v-149.284571H127.853714a42.642286 42.642286 0 0 1-42.130285-35.84l-0.585143-6.875429c0-23.552 19.163429-42.642286 42.715428-42.642286h192c23.552 0 42.715429 19.017143 42.715429 42.642286v192a42.642286 42.642286 0 0 1-42.715429 42.642286zM127.853714 362.642286a42.642286 42.642286 0 1 1 0-85.284572H277.211429V128c0-21.211429 15.433143-38.765714 35.766857-42.130286l6.875428-0.512c23.552 0 42.715429 19.017143 42.715429 42.642286v192a42.642286 42.642286 0 0 1-42.715429 42.642286H127.853714z" fill="#333333" p-id="8706"></path></svg>'},e.prototype.getTitle=function(e){return e.isFullScreen?eC("fullScreen.title"):eC("fullScreen.cancelTitle")},e.prototype.exec=function(e,t){e.isFullScreen?e.unFullScreen():e.fullScreen()},e}(),aS={menus:[{key:"fullScreen",factory:function(){return new iS}}]};function sS(e){return function(t,r){return"<h".concat(e,">").concat(r,"</h").concat(e,">")}}var uS={type:"header1",elemToHtml:sS(1)},lS={type:"header2",elemToHtml:sS(2)},cS={type:"header3",elemToHtml:sS(3)},dS={type:"header4",elemToHtml:sS(4)},hS={type:"header5",elemToHtml:sS(5)},fS={type:"header6",elemToHtml:sS(6)};function pS(e){var t=Qg(Yp.nodes(e,{match:function(e){return Ry.getNodeType(e).startsWith("header")},universal:!0}),1),r=t[0];if(null==r)return"paragraph";var n=Qg(r,1)[0];return Ry.getNodeType(n)}function gS(e){if(null==e.selection)return!0;var t=Qg(Yp.nodes(e,{match:function(e){var t=Ry.getNodeType(e);return"paragraph"===t||!!t.startsWith("header")},universal:!0,mode:"highest"}),1);return!t[0]}function mS(e,t){t&&zg.setNodes(e,{type:t})}var vS=function(){function e(){this.tag="button"}return e.prototype.getValue=function(e){return pS(e)},e.prototype.isActive=function(e){return this.getValue(e)===this.type},e.prototype.isDisabled=function(e){return gS(e)},e.prototype.exec=function(e,t){var r=this.type;mS(e,t===r?"paragraph":r)},e}(),yS=function(e){function t(){var t=e.apply(this,em([],Qg(arguments),!1))||this;return t.title="H1",t.type="header1",t}return Yg(t,e),t}(vS),bS=function(e){function t(){var t=e.apply(this,em([],Qg(arguments),!1))||this;return t.title="H2",t.type="header2",t}return Yg(t,e),t}(vS),DS=function(e){function t(){var t=e.apply(this,em([],Qg(arguments),!1))||this;return t.title="H3",t.type="header3",t}return Yg(t,e),t}(vS),CS=function(e){function t(){var t=e.apply(this,em([],Qg(arguments),!1))||this;return t.title="H4",t.type="header4",t}return Yg(t,e),t}(vS),wS=function(e){function t(){var t=e.apply(this,em([],Qg(arguments),!1))||this;return t.title="H5",t.type="header5",t}return Yg(t,e),t}(vS),ES=function(e){function t(){var t=e.apply(this,em([],Qg(arguments),!1))||this;return t.title="H6",t.type="header6",t}return Yg(t,e),t}(vS),AS=function(){function e(){this.title=eC("header.title"),this.iconSvg='<svg viewBox="0 0 1024 1024"><path d="M960 960c-51.2 0-102.4-3.2-153.6-3.2-51.2 0-99.2 3.2-150.4 3.2-19.2 0-28.8-22.4-28.8-38.4 0-51.2 57.6-28.8 86.4-48 19.2-12.8 19.2-60.8 19.2-80v-224-19.2c-9.6-3.2-19.2-3.2-28.8-3.2H320c-9.6 0-19.2 0-28.8 3.2V780.8c0 22.4 0 80 22.4 92.8 28.8 19.2 96-6.4 96 44.8 0 16-9.6 41.6-28.8 41.6-54.4 0-105.6-3.2-160-3.2-48 0-96 3.2-147.2 3.2-19.2 0-28.8-22.4-28.8-38.4 0-51.2 51.2-28.8 80-48 19.2-12.8 19.2-60.8 19.2-83.2V294.4c0-28.8 3.2-115.2-22.4-131.2-25.6-16-86.4 9.6-86.4-41.6 0-16 6.4-41.6 28.8-41.6 51.2 0 105.6 3.2 156.8 3.2 48 0 96-3.2 144-3.2 19.2 0 28.8 22.4 28.8 41.6 0 48-57.6 25.6-83.2 41.6-19.2 12.8-19.2 73.6-19.2 92.8v201.6c6.4 3.2 16 3.2 22.4 3.2h400c6.4 0 12.8 0 22.4-3.2V256c0-22.4 0-80-19.2-92.8-28.8-16-86.4 6.4-86.4-41.6 0-16 9.6-41.6 28.8-41.6 51.2 0 99.2 3.2 150.4 3.2 48 0 99.2-3.2 147.2-3.2 19.2 0 28.8 22.4 28.8 41.6 0 51.2-57.6 25.6-86.4 41.6-19.2 12.8-19.2 70.4-19.2 92.8v537.6c0 19.2 0 67.2 19.2 80 28.8 19.2 89.6-6.4 89.6 44.8 0 19.2-6.4 41.6-28.8 41.6z"></path></svg>',this.tag="select",this.width=60}return e.prototype.getOptions=function(e){var t=[{value:"header1",text:"H1",styleForRenderMenuList:{"font-size":"32px","font-weight":"bold"}},{value:"header2",text:"H2",styleForRenderMenuList:{"font-size":"24px","font-weight":"bold"}},{value:"header3",text:"H3",styleForRenderMenuList:{"font-size":"18px","font-weight":"bold"}},{value:"header4",text:"H4",styleForRenderMenuList:{"font-size":"16px","font-weight":"bold"}},{value:"header5",text:"H5",styleForRenderMenuList:{"font-size":"13px","font-weight":"bold"}},{value:"header6",text:"H6",styleForRenderMenuList:{"font-size":"11px","font-weight":"bold"}},{value:"paragraph",text:eC("header.text")}],r=this.getValue(e).toString();return t.forEach(function(e){e.value===r?e.selected=!0:e.selected=void 0}),t},e.prototype.isActive=function(e){return!1},e.prototype.getValue=function(e){return pS(e)},e.prototype.isDisabled=function(e){return gS(e)},e.prototype.exec=function(e,t){mS(e,t.toString())},e}(),xS={key:"headerSelect",factory:function(){return new AS}},BS={key:"header1",factory:function(){return new yS}},SS={key:"header2",factory:function(){return new bS}},FS={key:"header3",factory:function(){return new DS}},kS={key:"header4",factory:function(){return new CS}},OS={key:"header5",factory:function(){return new wS}},TS={key:"header6",factory:function(){return new ES}};function NS(e){return function(t,r,n){var o=ov(t);return 0===(r=r.filter(function(e){return!!Cg.isText(e)||!!n.isInline(e)})).length&&(r=[{text:o.text().replace(/\s+/gm," ")}]),{type:"header".concat(e),children:r}}}var PS={selector:"h1:not([data-w-e-type])",parseElemHtml:NS(1)},MS={selector:"h2:not([data-w-e-type])",parseElemHtml:NS(2)},IS={selector:"h3:not([data-w-e-type])",parseElemHtml:NS(3)},RS={selector:"h4:not([data-w-e-type])",parseElemHtml:NS(4)},LS={selector:"h5:not([data-w-e-type])",parseElemHtml:NS(5)},_S={selector:"h6:not([data-w-e-type])",parseElemHtml:NS(6)};function zS(e){return function(t,r,n){return Tw("h".concat(e),null,r)}}var jS={renderElems:[{type:"header1",renderElem:zS(1)},{type:"header2",renderElem:zS(2)},{type:"header3",renderElem:zS(3)},{type:"header4",renderElem:zS(4)},{type:"header5",renderElem:zS(5)},{type:"header6",renderElem:zS(6)}],elemsToHtml:[uS,lS,cS,dS,hS,fS],parseElemsHtml:[PS,MS,IS,RS,LS,_S],menus:[xS,BS,SS,FS,kS,OS,TS],editorPlugin:function(e){var t=e.insertBreak,r=e;return r.insertBreak=function(){var n=Qg(Yp.nodes(r,{match:function(e){return Ry.getNodeType(e).startsWith("header")},universal:!0}),1),o=n[0];if(o)if(Ry.isSelectionAtLineEnd(e,o[1])){zg.insertNodes(r,{type:"paragraph",children:[{text:""}]},{mode:"highest"})}else t();else t()},r}};var HS={type:"image",elemToHtml:function(e,t){var r=e,n=r.src,o=r.alt,i=void 0===o?"":o,a=r.href,s=void 0===a?"":a,u=r.width,l=void 0===u?"":u,c=r.height,d=void 0===c?"":c,h=r.style,f=void 0===h?{}:h,p=f.width,g=void 0===p?"":p,m=f.height,v=void 0===m?"":m,y="";return g&&(y+="width: ".concat(g,";")),v&&(y+="height: ".concat(v,";")),'<img src="'.concat(n,'" alt="').concat(i,'" data-href="').concat(s,'" width="').concat(l,'" height="').concat(d,'" style="').concat(y,'"/>')}};var VS=function(){function e(){this.title=eC("image.delete"),this.iconSvg='<svg viewBox="0 0 1024 1024"><path d="M826.8032 356.5312c-19.328 0-36.3776 15.6928-36.3776 35.0464v524.2624c0 19.328-16 34.56-35.328 34.56H264.9344c-19.328 0-35.5072-15.3088-35.5072-34.56V390.0416c0-19.328-14.1568-35.0464-33.5104-35.0464s-33.5104 15.6928-33.5104 35.0464V915.712c0 57.9328 44.6208 108.288 102.528 108.288H755.2c57.9328 0 108.0832-50.4576 108.0832-108.288V391.4752c-0.1024-19.2512-17.1264-34.944-36.48-34.944z" p-id="9577"></path><path d="M437.1712 775.7568V390.6048c0-19.328-14.1568-35.0464-33.5104-35.0464s-33.5104 15.616-33.5104 35.0464v385.152c0 19.328 14.1568 35.0464 33.5104 35.0464s33.5104-15.7184 33.5104-35.0464zM649.7024 775.7568V390.6048c0-19.328-17.0496-35.0464-36.3776-35.0464s-36.3776 15.616-36.3776 35.0464v385.152c0 19.328 17.0496 35.0464 36.3776 35.0464s36.3776-15.7184 36.3776-35.0464zM965.0432 217.0368h-174.6176V145.5104c0-57.9328-47.2064-101.76-104.6528-101.76h-350.976c-57.8304 0-105.3952 43.8528-105.3952 101.76v71.5264H54.784c-19.4304 0-35.0464 14.1568-35.0464 33.5104 0 19.328 15.616 33.5104 35.0464 33.5104h910.3616c19.328 0 35.0464-14.1568 35.0464-33.5104 0-19.3536-15.6928-33.5104-35.1488-33.5104z m-247.3728 0H297.3952V145.5104c0-19.328 18.2016-34.7648 37.4272-34.7648h350.976c19.1488 0 31.872 15.1296 31.872 34.7648v71.5264z"></path></svg>',this.tag="button"}return e.prototype.getValue=function(e){return""},e.prototype.isActive=function(e){return!1},e.prototype.isDisabled=function(e){return null==e.selection||null==Ry.getSelectedNodeByType(e,"image")},e.prototype.exec=function(e,t){this.isDisabled(e)||zg.removeNodes(e,{match:function(e){return Ry.checkNodeType(e,"image")}})},e}();function $S(e){return void 0===e&&(e="r"),"".concat(e,"-").concat(zv())}function US(e){return e.replace(/</g,"<").replace(/>/g,">")}function qS(e){var t=e.selection;if(null==t)return!0;if(!hg.isCollapsed(t))return!0;var r=Qg(Yp.nodes(e,{match:function(t){var r=Ry.getNodeType(t);return"code"===r||("pre"===r||("link"===r||("list-item"===r||(!!r.startsWith("header")||("blockquote"===r||!!Yp.isVoid(e,t))))))},universal:!0}),1);return!!r[0]}function WS(e,t,r){return Xg(this,arguments,void 0,function(e,t,r,n,o){var i,a;return void 0===n&&(n=""),void 0===o&&(o=""),Zg(this,function(s){switch(s.label){case 0:return(i=t.getMenuConfig(e).checkImage)?[4,i(r,n,o)]:[3,2];case 1:if("string"==typeof(a=s.sent()))return t.alert(a,"error"),[2,!1];if(null==a)return[2,!1];s.label=2;case 2:return[2,!0]}})})}function GS(e,t,r){return Xg(this,void 0,void 0,function(){var n;return Zg(this,function(o){switch(o.label){case 0:return(n=t.getMenuConfig(e).parseImageSrc)?[4,n(r)]:[3,2];case 1:return[2,o.sent()];case 2:return[2,r]}})})}function YS(e,t){return Xg(this,arguments,void 0,function(e,t,r,n){var o,i,a;return void 0===r&&(r=""),void 0===n&&(n=""),Zg(this,function(s){switch(s.label){case 0:return[4,WS("insertImage",e,t,r,n)];case 1:return s.sent()?[4,GS("insertImage",e,t)]:[2];case 2:return o=s.sent(),i={type:"image",src:US(o),href:n,alt:r,style:{},children:[{text:""}]},null===e.selection&&e.restoreSelection(),Ry.getSelectedNodeByType(e,"image")&&e.move(1),qS(e)?[2]:(zg.insertNodes(e,i),(a=e.getMenuConfig("insertImage").onInsertedImage)&&a(i),[2])}})})}function KS(){return $S("w-e-edit-image")}var XS=function(){function e(){this.title=eC("image.edit"),this.iconSvg=yB,this.tag="button",this.showModal=!0,this.modalWidth=300,this.$content=null,this.srcInputId=KS(),this.altInputId=KS(),this.hrefInputId=KS(),this.buttonId=KS()}return e.prototype.getValue=function(e){return""},e.prototype.getImageNode=function(e){return Ry.getSelectedNodeByType(e,"image")},e.prototype.isActive=function(e){return!1},e.prototype.exec=function(e,t){},e.prototype.isDisabled=function(e){var t=e.selection;return null==t||(!hg.isCollapsed(t)||null==Ry.getSelectedNodeByType(e,"image"))},e.prototype.getModalPositionNode=function(e){return this.getImageNode(e)},e.prototype.getModalContentElem=function(e){var t=this,r=this,n=r.srcInputId,o=r.altInputId,i=r.hrefInputId,a=r.buttonId,s=this.getImageNode(e);if(null==s)throw new Error("Not found selected image node");var u=Qg(dC(eC("image.src"),n),2),l=u[0],c=ov(u[1]),d=Qg(dC(eC("image.desc"),o),2),h=d[0],f=ov(d[1]),p=Qg(dC(eC("image.link"),i),2),g=p[0],m=ov(p[1]),v=Qg(fC(a,eC("common.ok")),1)[0];if(null==this.$content){var y=ov("<div></div>");y.on("click","#".concat(a),function(r){r.preventDefault();var a=y.find("#".concat(n)).val(),s=y.find("#".concat(o)).val(),u=y.find("#".concat(i)).val();t.updateImage(e,a,s,u),e.hidePanelOrModal()}),this.$content=y}var b=this.$content;b.empty(),b.append(l),b.append(h),b.append(g),b.append(v);var D=s,C=D.src,w=D.alt,E=void 0===w?"":w,A=D.href,x=void 0===A?"":A;return c.val(C),f.val(E),m.val(x),setTimeout(function(){c.focus()}),b[0]},e.prototype.updateImage=function(e,t,r,n,o){void 0===r&&(r=""),void 0===n&&(n=""),void 0===o&&(o={}),t&&(e.restoreSelection(),this.isDisabled(e)||function(e,t){Xg(this,arguments,void 0,function(e,t,r,n,o){var i,a,s,u,l,c;return void 0===r&&(r=""),void 0===n&&(n=""),void 0===o&&(o={}),Zg(this,function(d){switch(d.label){case 0:return[4,WS("editImage",e,t,r,n)];case 1:return d.sent()?[4,GS("editImage",e,t)]:[2];case 2:return i=d.sent(),null==(a=Ry.getSelectedNodeByType(e,"image"))||(s=a.style,u={src:i,alt:r,href:n,style:Kg(Kg({},void 0===s?{}:s),o)},zg.setNodes(e,u,{match:function(e){return Ry.checkNodeType(e,"image")}}),l=Ry.getSelectedNodeByType(e,"image"),(c=e.getMenuConfig("editImage").onUpdatedImage)&&c(l)),[2]}})})}(e,t,r,n,o))},e}();function ZS(){return $S("w-e-insert-image")}var JS=function(){function e(){this.title=eC("image.editSize"),this.tag="button",this.showModal=!0,this.modalWidth=320,this.$content=null,this.widthInputId=ZS(),this.heightInputId=ZS(),this.buttonId=ZS()}return e.prototype.getSelectedImageNode=function(e){return Ry.getSelectedNodeByType(e,"image")},e.prototype.getValue=function(e){return""},e.prototype.isActive=function(e){return!1},e.prototype.exec=function(e,t){},e.prototype.isDisabled=function(e){return null==e.selection||null==this.getSelectedImageNode(e)},e.prototype.getModalPositionNode=function(e){return this.getSelectedImageNode(e)},e.prototype.getModalContentElem=function(e){var t=this,r=t.widthInputId,n=t.heightInputId,o=t.buttonId,i=Qg(dC(eC("image.width"),r,"auto"),2),a=i[0],s=ov(i[1]),u=Qg(dC(eC("image.height"),n,"auto"),2),l=u[0],c=ov(u[1]),d=Qg(fC(o,eC("image.ok")),1)[0],h=this.getSelectedImageNode(e);if(null==this.$content){var f=ov("<div></div>");f.on("click","#".concat(o),function(t){t.preventDefault();var o=f.find("#".concat(r)).val().trim(),i=f.find("#".concat(n)).val().trim(),a=function(e){return/^\d+(\.\d+)?%$/.test(e)},s=function(e){return/^\d+(\.\d+)?$/.test(e)},u=function(e){return/^\d+(\.\d+)?px$/.test(e)},l="auto",c="auto";a(o)?l=o:s(o)?l="".concat(parseInt(o,10),"px"):u(o)&&(l=o),a(i)?c=i:s(i)?c="".concat(parseInt(i,10),"px"):u(i)&&(c=i);var d=h.style,p=void 0===d?{}:d;e.restoreSelection();var g=Kg(Kg({},p),{style:{width:l,height:c}});zg.setNodes(e,g,{match:function(e){return Ry.checkNodeType(e,"image")}}),e.hidePanelOrModal()}),this.$content=f}var p=this.$content;if(p.empty(),p.append(a),p.append(l),p.append(d),null==h)return p[0];var g=h.style,m=void 0===g?{}:g,v=m.width,y=void 0===v?"auto":v,b=m.height,D=void 0===b?"auto":b;return s.val(y),c.val(D),setTimeout(function(){s.focus()}),p[0]},e}();function QS(){return $S("w-e-insert-image")}var eF=function(){function e(){this.title=eC("image.netImage"),this.iconSvg='<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>',this.tag="button",this.showModal=!0,this.modalWidth=300,this.$content=null,this.srcInputId=QS(),this.altInputId=QS(),this.hrefInputId=QS(),this.buttonId=QS()}return e.prototype.getValue=function(e){return""},e.prototype.isActive=function(e){return!1},e.prototype.exec=function(e,t){},e.prototype.isDisabled=function(e){return qS(e)},e.prototype.getModalPositionNode=function(e){return null},e.prototype.getModalContentElem=function(e){var t=this,r=this,n=r.srcInputId,o=r.altInputId,i=r.hrefInputId,a=r.buttonId,s=Qg(dC(eC("image.src"),n),2),u=s[0],l=ov(s[1]),c=Qg(dC(eC("image.desc"),o),2),d=c[0],h=ov(c[1]),f=Qg(dC(eC("image.link"),i),2),p=f[0],g=ov(f[1]),m=Qg(fC(a,eC("common.ok")),1)[0];if(null==this.$content){var v=ov("<div></div>");v.on("click","#".concat(a),function(r){r.preventDefault();var a=v.find("#".concat(n)).val().trim(),s=v.find("#".concat(o)).val().trim(),u=v.find("#".concat(i)).val().trim();t.insertImage(e,a,s,u),e.hidePanelOrModal()}),this.$content=v}var y=this.$content;return y.empty(),y.append(u),y.append(d),y.append(p),y.append(m),l.val(""),h.val(""),g.val(""),setTimeout(function(){l.focus()}),y[0]},e.prototype.insertImage=function(e,t,r,n){void 0===r&&(r=""),void 0===n&&(n=""),t&&(e.restoreSelection(),this.isDisabled(e)||YS(e,t,r,n))},e}(),tF=function(){function e(){this.title=eC("image.viewLink"),this.iconSvg=bB,this.tag="button"}return e.prototype.getValue=function(e){var t=Ry.getSelectedNodeByType(e,"image");return t&&t.href||""},e.prototype.isActive=function(e){return!1},e.prototype.isDisabled=function(e){return null==e.selection||!this.getValue(e)},e.prototype.exec=function(e,t){if(!this.isDisabled(e)){if(!t||"string"!=typeof t)throw new Error("View image link failed, image.href is '".concat(t,"'"));window.open(t,"_blank")}},e}(),rF=function(){function e(){this.tag="button"}return e.prototype.getValue=function(e){return""},e.prototype.isActive=function(e){return!1},e.prototype.getSelectedNode=function(e){return Ry.getSelectedNodeByType(e,"image")},e.prototype.isDisabled=function(e){return null==e.selection||null==this.getSelectedNode(e)},e.prototype.exec=function(e,t){if(!this.isDisabled(e)){var r=this.getSelectedNode(e);if(null!=r){var n=Ry.getHoverbar(e);n&&n.hideAndClean();var o=r.style,i={style:Kg(Kg({},void 0===o?{}:o),{width:this.value,height:""})};zg.setNodes(e,i,{match:function(e){return Ry.checkNodeType(e,"image")}})}}},e}(),nF=function(e){function t(){var t=e.apply(this,em([],Qg(arguments),!1))||this;return t.title="30%",t.value="30%",t}return Yg(t,e),t}(rF),oF=function(e){function t(){var t=e.apply(this,em([],Qg(arguments),!1))||this;return t.title="50%",t.value="50%",t}return Yg(t,e),t}(rF),iF=function(e){function t(){var t=e.apply(this,em([],Qg(arguments),!1))||this;return t.title="100%",t.value="100%",t}return Yg(t,e),t}(rF),aF={onInsertedImage:function(e){},onUpdatedImage:function(e){},checkImage:function(e,t,r){return!0},parseImageSrc:function(e){return e}};function sF(e,t){var r=Ry.findKey(e,t).id;return"w-e-image-container-".concat(r)}function uF(e,t,r,n){var o=ov("body"),i=sF(e,t),a=n.width,s=n.height,u=0,l=0,c=0,d=0,h=!1,f=null;var p=BC(function(e){e.preventDefault();var t=e.clientX,r=l+(h?u-t:t-u),n=c*(r/l);r>d-6||null!=f&&(r<=15||n<=15||(f.css("width","".concat(r,"px")),f.css("height","".concat(n,"px"))))},100);function g(r){if(o.off("mousemove",p),null!=f){var n=f.width().toFixed(2),i=f.height().toFixed(2),a={style:Kg(Kg({},t.style),{width:"".concat(n,"px"),height:"".concat(i,"px")})};zg.setNodes(e,a,{at:Ry.findPath(e,t)}),o.off("mouseup",g)}}function m(t,r){f=function(){var e=ov("#".concat(i));if(0===e.length)throw new Error("Cannot find image container elem");return e}(),u=t,d=r;var n=f.find("img");if(0===n.length)throw new Error("Cannot find image elem");l=n.width(),c=n.height(),o.on("mousemove",p),o.on("mouseup",g);var a=Ry.getHoverbar(e);a&&a.hideAndClean()}var v={};return a&&(v.width=a),s&&(v.height=s),v.boxShadow="0 0 0 1px #B4D5FF",Tw("div",{id:i,style:v,className:"w-e-image-container w-e-selected-image-container",on:{mousedown:function(r){var n=ov(r.target);if(n.hasClass("w-e-image-dragger")){r.preventDefault(),(n.hasClass("left-top")||n.hasClass("left-bottom"))&&(h=!0);var o=Ry.getParentNode(e,t);if(null!=o){var i=Ry.toDOMNode(e,o),a=i.getBoundingClientRect?i.getBoundingClientRect():{width:0},s=window.getComputedStyle(i),u=parseFloat(s.paddingLeft),l=parseFloat(s.paddingRight),c=parseFloat(s.borderLeftWidth),d=parseFloat(s.borderRightWidth);m(r.clientX,a.width-u-l-c-d)}}}}},r,Tw("div",{className:"w-e-image-dragger left-top"}),Tw("div",{className:"w-e-image-dragger right-top"}),Tw("div",{className:"w-e-image-dragger left-bottom"}),Tw("div",{className:"w-e-image-dragger right-bottom"}))}var lF={type:"image",renderElem:function(e,t,r){var n=e,o=n.src,i=n.alt,a=void 0===i?"":i,s=n.href,u=void 0===s?"":s,l=n.style,c=void 0===l?{}:l,d=c.width,h=void 0===d?"":d,f=c.height,p=void 0===f?"":f,g=Ry.isNodeSelected(r,e),m={maxWidth:"100%"};h&&(m.width="100%"),p&&(m.height="100%");var v=Tw("img",{style:m,src:o,alt:a,"data-href":u}),y=r.isDisabled();return g&&!y?uF(r,e,v,{width:h,height:p}):function(e,t,r,n){var o=n.width,i=n.height,a={};return o&&(a.width=o),i&&(a.height=i),Tw("div",{id:sF(e,t),style:a,className:"w-e-image-container"},r)}(r,e,v,{width:h,height:p})}},cF={renderElems:[lF],elemsToHtml:[HS],parseElemsHtml:[{selector:"img:not([data-w-e-type])",parseElemHtml:function(e,t,r){var n=ov(e),o=n.attr("data-href")||"";return o=decodeURIComponent(o),{type:"image",src:n.attr("src")||"",alt:n.attr("alt")||"",href:o,style:{width:BB(n,"width"),height:BB(n,"height")},width:n.attr("width")||"",height:n.attr("height")||"",children:[{text:""}]}}}],menus:[{key:"insertImage",factory:function(){return new eF},config:aF},{key:"deleteImage",factory:function(){return new VS}},{key:"editImage",factory:function(){return new XS},config:aF},{key:"viewImageLink",factory:function(){return new tF}},{key:"imageWidth30",factory:function(){return new nF}},{key:"imageWidth50",factory:function(){return new oF}},{key:"imageWidth100",factory:function(){return new iF}},{key:"editorImageSizeMenu",factory:function(){return new JS}}],editorPlugin:function(e){var t=e.isInline,r=e.isVoid,n=e;return n.isInline=function(e){return"image"===e.type||t(e)},n.isVoid=function(e){return"image"===e.type||r(e)},n}},dF=function(){function e(){this.tag="button"}return e.prototype.getValue=function(e){var t=Qg(Yp.nodes(e,{match:function(e){return!!e.indent},universal:!0}),1),r=t[0];return null==r?"":Qg(r,1)[0].indent||""},e.prototype.isActive=function(e){return!1},e.prototype.getMatchNode=function(e){var t=Qg(Yp.nodes(e,{match:function(e){var t=Ry.getNodeType(e);return"paragraph"===t||!!t.startsWith("header")},universal:!0,mode:"highest"}),1),r=t[0];return null==r?null:r[0]},e}(),hF=function(e){function t(){var t=e.apply(this,em([],Qg(arguments),!1))||this;return t.title=eC("indent.decrease"),t.iconSvg='<svg viewBox="0 0 1024 1024"><path d="M0 64h1024v128H0z m384 192h640v128H384z m0 192h640v128H384z m0 192h640v128H384zM0 832h1024v128H0z m256-512v384l-256-192z"></path></svg>',t}return Yg(t,e),t.prototype.isDisabled=function(e){var t=this.getMatchNode(e);return null==t||!t.indent},t.prototype.exec=function(e,t){zg.setNodes(e,{indent:null},{match:function(e){return Vp.isElement(e)}})},t}(dF),fF=function(e){function t(){var t=e.apply(this,em([],Qg(arguments),!1))||this;return t.title=eC("indent.increase"),t.iconSvg='<svg viewBox="0 0 1024 1024"><path d="M0 64h1024v128H0z m384 192h640v128H384z m0 192h640v128H384z m0 192h640v128H384zM0 832h1024v128H0z m0-128V320l256 192z"></path></svg>',t.DEFAULT_INDENT_VALUE="2em",t}return Yg(t,e),t.prototype.isDisabled=function(e){var t=this.getMatchNode(e);return null==t||!!t.indent},t.prototype.getIndentValue=function(e){var t=this.getMatchNode(e);if(!t)return this.DEFAULT_INDENT_VALUE;var r=t.children.filter(Cg.isText)[0];if(!r||!r.fontSize)return this.DEFAULT_INDENT_VALUE;var n=r.fontSize,o=parseInt(r.fontSize,10),i=n.replace("".concat(o),"");return"".concat(2*o).concat(i)},t.prototype.exec=function(e,t){var r=this.getIndentValue(e);zg.setNodes(e,{indent:r},{match:function(e){return Vp.isElement(e)},mode:"highest"})},t}(dF);var pF={renderStyle:function(e,t){if(!Vp.isElement(e))return t;var r=e.indent,n=t;return r&&$B(n,{textIndent:r}),n},styleToHtml:function(e,t){if(!Vp.isElement(e))return t;var r=e.indent;if(!r)return t;var n=ov(t);return n.css("text-indent",r),AB(n)},preParseHtml:[{selector:"p,h1,h2,h3,h4,h5",preParseHtml:function(e){var t=ov(e),r=BB(t,"padding-left");return/^[1-9]\d*em$/.test(r)&&t.css("text-indent","2em"),/^[1-9]\d*px$/.test(r)&&parseInt(r,10)%32==0&&t.css("text-indent","2em"),t[0]}}],parseStyleHtml:function(e,t,r){var n=ov(e);if(!Vp.isElement(t))return t;var o=t,i=BB(n,"text-indent"),a=parseInt(i,10);return i&&a>0&&(o.indent=i),o},menus:[{key:"indent",factory:function(){return new fF}},{key:"delIndent",factory:function(){return new hF}}]},gF=function(){function e(){this.tag="button"}return e.prototype.getValue=function(e){return""},e.prototype.isActive=function(e){return!1},e.prototype.isDisabled=function(e){return null==e.selection||!!Ry.getSelectedElems(e).some(function(t){var r=t.type;return!(!Yp.isVoid(e,t)||!Yp.isBlock(e,t)||"video"===r)||!!["pre","code"].includes(r)})},e}(),mF=function(e){function t(){var t=e.apply(this,em([],Qg(arguments),!1))||this;return t.title=eC("justify.center"),t.iconSvg='<svg viewBox="0 0 1024 1024"><path d="M870.4 793.6v102.4H153.6v-102.4h716.8z m102.4-230.4v102.4H51.2v-102.4h921.6z m-102.4-230.4v102.4H153.6v-102.4h716.8zM972.8 102.4v102.4H51.2V102.4h921.6z"></path></svg>',t}return Yg(t,e),t.prototype.exec=function(e,t){zg.setNodes(e,{textAlign:"center"},{match:function(t){return Vp.isElement(t)&&!e.isInline(t)}})},t}(gF),vF=function(e){function t(){var t=e.apply(this,em([],Qg(arguments),!1))||this;return t.title=eC("justify.justify"),t.iconSvg='<svg viewBox="0 0 1024 1024"><path d="M0 64h1024v128H0z m0 192h1024v128H0z m0 192h1024v128H0z m0 192h1024v128H0z m0 192h1024v128H0z"></path></svg>',t}return Yg(t,e),t.prototype.exec=function(e,t){zg.setNodes(e,{textAlign:"justify"},{match:function(t){return Vp.isElement(t)&&!e.isInline(t)}})},t}(gF),yF=function(e){function t(){var t=e.apply(this,em([],Qg(arguments),!1))||this;return t.title=eC("justify.left"),t.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>',t}return Yg(t,e),t.prototype.exec=function(e,t){zg.setNodes(e,{textAlign:"left"},{match:function(t){return Vp.isElement(t)&&!e.isInline(t)}})},t}(gF),bF=function(e){function t(){var t=e.apply(this,em([],Qg(arguments),!1))||this;return t.title=eC("justify.right"),t.iconSvg='<svg viewBox="0 0 1024 1024"><path d="M972.8 793.6v102.4H256v-102.4h716.8z m0-230.4v102.4H51.2v-102.4h921.6z m0-230.4v102.4H256v-102.4h716.8zM972.8 102.4v102.4H51.2V102.4h921.6z"></path></svg>',t}return Yg(t,e),t.prototype.exec=function(e,t){zg.setNodes(e,{textAlign:"right"},{match:function(t){return Vp.isElement(t)&&!e.isInline(t)}})},t}(gF);var DF={renderStyle:function(e,t){if(!Vp.isElement(e))return t;var r=e.textAlign,n=t;return r&&$B(n,{textAlign:r}),n},styleToHtml:function(e,t){if(!Vp.isElement(e))return t;var r=e.textAlign;if(!r)return t;var n=ov(t);return n.css("text-align",r),AB(n)},parseStyleHtml:function(e,t,r){var n=ov(e);if(!Vp.isElement(t))return t;var o=t,i=BB(n,"text-align");return i&&(o.textAlign=i),o},menus:[{key:"justifyLeft",factory:function(){return new yF}},{key:"justifyRight",factory:function(){return new bF}},{key:"justifyCenter",factory:function(){return new mF}},{key:"justifyJustify",factory:function(){return new vF}}]};var CF=function(){function e(){this.title=eC("lineHeight.title"),this.iconSvg='<svg viewBox="0 0 1024 1024"><path d="M964 788a8 8 0 0 1 8 8v98a8 8 0 0 1-8 8H438a8 8 0 0 1-8-8v-98a8 8 0 0 1 8-8h526zM198.93 144.306c6.668-5.798 16.774-5.094 22.573 1.574l122.26 140.582a16 16 0 0 1 3.927 10.5c0 8.836-7.164 16-16 16h-61.8a8 8 0 0 0-8 8v390.077h69.819a16 16 0 0 1 10.502 3.928c6.666 5.8 7.37 15.906 1.57 22.573L221.476 878.123a16 16 0 0 1-1.57 1.57c-6.668 5.8-16.774 5.097-22.574-1.57L75.051 737.538a16 16 0 0 1-3.928-10.5c0-8.837 7.163-16 16-16h69.822V312.96H87.127a16 16 0 0 1-10.502-3.928c-6.666-5.8-7.37-15.906-1.57-22.573l122.303-140.582a16 16 0 0 1 1.572-1.572zM964 465a8 8 0 0 1 8 8v98a8 8 0 0 1-8 8H438a8 8 0 0 1-8-8v-98a8 8 0 0 1 8-8h526z m0-323a8 8 0 0 1 8 8v98a8 8 0 0 1-8 8H438a8 8 0 0 1-8-8v-98a8 8 0 0 1 8-8h526z"></path></svg>',this.tag="select",this.width=80}return e.prototype.getOptions=function(e){var t=[],r=e.getMenuConfig("lineHeight").lineHeightList,n=void 0===r?[]:r;t.push({text:eC("lineHeight.default"),value:""}),n.forEach(function(e){t.push({text:e,value:e})});var o=this.getValue(e);return t.forEach(function(e){e.value===o?e.selected=!0:e.selected=void 0}),t},e.prototype.getMatchNode=function(e){var t=Qg(Yp.nodes(e,{match:function(e){var t=Ry.getNodeType(e);return!!t.startsWith("header")||!!["paragraph","blockquote","list-item"].includes(t)},universal:!0,mode:"highest"}),1),r=t[0];return null==r?null:r[0]},e.prototype.isActive=function(e){return!1},e.prototype.getValue=function(e){var t=this.getMatchNode(e);return null==t?"":Vp.isElement(t)&&t.lineHeight||""},e.prototype.isDisabled=function(e){return null==e.selection||null==this.getMatchNode(e)},e.prototype.exec=function(e,t){zg.setNodes(e,{lineHeight:t.toString()},{mode:"highest"})},e}();var wF={renderStyle:function(e,t){if(!Vp.isElement(e))return t;var r=e.lineHeight,n=t;return r&&$B(n,{lineHeight:r}),n},styleToHtml:function(e,t){if(!Vp.isElement(e))return t;var r=e.lineHeight;if(!r)return t;var n=ov(t);return n.css("line-height",r),AB(n)},parseStyleHtml:function(e,t,r){var n=ov(e);if(!Vp.isElement(t))return t;var o=t,i=r.getMenuConfig("lineHeight").lineHeightList,a=void 0===i?[]:i,s=BB(n,"line-height");return s&&a.includes(s)&&(o.lineHeight=s),o},menus:[{key:"lineHeight",factory:function(){return new CF},config:{lineHeightList:["1","1.15","1.5","2","2.5","3"]}}]};var EF={type:"link",elemToHtml:function(e,t){var r=e,n=r.url,o=r.target,i=void 0===o?"_blank":o;return'<a href="'.concat(n,'" target="').concat(i,'">').concat(t,"</a>")}};function AF(e,t,r,n){return Xg(this,void 0,void 0,function(){var o,i;return Zg(this,function(a){switch(a.label){case 0:return(o=t.getMenuConfig(e).checkLink)?[4,o(r,n)]:[3,2];case 1:if("string"==typeof(i=a.sent()))return t.alert(i,"error"),[2,!1];if(null==i)return[2,!1];a.label=2;case 2:return[2,!0]}})})}function xF(e,t,r){return Xg(this,void 0,void 0,function(){var n;return Zg(this,function(o){switch(o.label){case 0:return(n=t.getMenuConfig(e).parseLinkUrl)?[4,n(r)]:[3,2];case 1:return[2,o.sent()];case 2:return[2,r]}})})}function BF(e){return null==e.selection||!!Ry.getSelectedElems(e).some(function(t){var r=t.type;return!!e.isVoid(t)||!!["pre","code","link"].includes(r)})}function SF(e,t){return{type:"link",url:US(e),children:t?[{text:t}]:[]}}function FF(e,t,r){return Xg(this,void 0,void 0,function(){var n,o,i,a,s;return Zg(this,function(u){switch(u.label){case 0:return r?(t||(t=r),e.restoreSelection(),BF(e)?[2]:[4,AF("insertLink",e,t,r)]):[2];case 1:return u.sent()?[4,xF("insertLink",e,r)]:[2];case 2:if(n=u.sent(),null==(o=e.selection))return[2];if(hg.isCollapsed(o)){if((a=Ry.getLeftLengthOfMaxLength(e))<=0)return[2];e.insertText(" "),a<t.length+1&&(t=t.slice(0,a-1)),s=SF(n,t),zg.insertNodes(e,s),e.insertFragment([{text:" "}])}else if((i=Yp.string(e,o))!==t){if((a=Ry.getLeftLengthOfMaxLength(e))<=0)return[2];a<i.length-t.length&&(t=t.slice(0,a)),e.deleteFragment(),s=SF(n,t),zg.insertNodes(e,s)}else s=SF(n),zg.wrapNodes(e,s,{split:!0}),zg.collapse(e,{edge:"end"});return[2]}})})}function kF(){return $S("w-e-update-link")}var OF=function(){function e(){this.title=eC("link.edit"),this.iconSvg=yB,this.tag="button",this.showModal=!0,this.modalWidth=300,this.$content=null,this.urlInputId=kF(),this.buttonId=kF()}return e.prototype.getSelectedLinkElem=function(e){var t=Ry.getSelectedNodeByType(e,"link");return null==t?null:t},e.prototype.getValue=function(e){var t=this.getSelectedLinkElem(e);return t&&t.url||""},e.prototype.isActive=function(e){return!1},e.prototype.exec=function(e,t){},e.prototype.isDisabled=function(e){return null==e.selection||null==this.getSelectedLinkElem(e)},e.prototype.getModalPositionNode=function(e){return Ry.getSelectedNodeByType(e,"link")},e.prototype.getModalContentElem=function(e){var t=this.urlInputId,r=this.buttonId,n=Qg(dC(eC("link.url"),t),2),o=n[0],i=ov(n[1]),a=Qg(fC(r,eC("common.ok")),1)[0];if(null==this.$content){var s=ov("<div></div>");s.on("click","#".concat(r),function(r){r.preventDefault(),e.restoreSelection();var n=Ry.getSelectedNodeByType(e,"link"),o=n?eg.string(n):"",i=s.find("#".concat(t)).val();!function(e,t,r){Xg(this,void 0,void 0,function(){var n,o;return Zg(this,function(i){switch(i.label){case 0:return r?[4,AF("editLink",e,t,r)]:[2];case 1:return i.sent()?[4,xF("editLink",e,r)]:[2];case 2:return n=i.sent(),o={url:US(n)},zg.setNodes(e,o,{match:function(e){return Ry.checkNodeType(e,"link")}}),[2]}})})}(e,o,i),e.hidePanelOrModal()}),this.$content=s}var u=this.$content;u.empty(),u.append(o),u.append(a);var l=this.getValue(e);return i.val(l),setTimeout(function(){i.focus()}),u[0]},e}();function TF(){return $S("w-e-insert-link")}var NF=function(){function e(){this.title=eC("link.insert"),this.iconSvg='<svg viewBox="0 0 1024 1024"><path d="M440.224 635.776a51.84 51.84 0 0 1-36.768-15.232c-95.136-95.136-95.136-249.92 0-345.056l192-192C641.536 37.408 702.816 12.032 768 12.032s126.432 25.376 172.544 71.456c95.136 95.136 95.136 249.92 0 345.056l-87.776 87.776a51.968 51.968 0 1 1-73.536-73.536l87.776-87.776a140.16 140.16 0 0 0 0-197.984c-26.432-26.432-61.6-40.992-99.008-40.992s-72.544 14.56-99.008 40.992l-192 192a140.16 140.16 0 0 0 0 197.984 51.968 51.968 0 0 1-36.768 88.768z"></path><path d="M256 1012a242.4 242.4 0 0 1-172.544-71.456c-95.136-95.136-95.136-249.92 0-345.056l87.776-87.776a51.968 51.968 0 1 1 73.536 73.536l-87.776 87.776a140.16 140.16 0 0 0 0 197.984c26.432 26.432 61.6 40.992 99.008 40.992s72.544-14.56 99.008-40.992l192-192a140.16 140.16 0 0 0 0-197.984 51.968 51.968 0 1 1 73.536-73.536c95.136 95.136 95.136 249.92 0 345.056l-192 192A242.4 242.4 0 0 1 256 1012z"></path></svg>',this.tag="button",this.showModal=!0,this.modalWidth=300,this.$content=null,this.textInputId=TF(),this.urlInputId=TF(),this.buttonId=TF()}return e.prototype.getValue=function(e){return""},e.prototype.isActive=function(e){return!1},e.prototype.exec=function(e,t){},e.prototype.isDisabled=function(e){return BF(e)},e.prototype.getModalPositionNode=function(e){return null},e.prototype.getModalContentElem=function(e){var t=e.selection,r=this,n=r.textInputId,o=r.urlInputId,i=r.buttonId,a=Qg(dC(eC("link.text"),n),2),s=a[0],u=ov(a[1]),l=Qg(dC(eC("link.url"),o),2),c=l[0],d=ov(l[1]),h=Qg(fC(i,eC("common.ok")),1)[0];if(null==this.$content){var f=ov("<div></div>");f.on("click","#".concat(i),function(t){t.preventDefault();var r=f.find("#".concat(n)).val(),i=f.find("#".concat(o)).val();FF(e,r,i),e.hidePanelOrModal()}),this.$content=f}var p=this.$content;if(p.empty(),p.append(s),p.append(c),p.append(h),null==t||hg.isCollapsed(t))u.val("");else{var g=Yp.string(e,t);u.val(g)}return d.val(""),setTimeout(function(){u.focus()}),p[0]},e}(),PF=function(){function e(){this.title=eC("link.unLink"),this.iconSvg='<svg viewBox="0 0 1024 1024"><path d="M608.16328 811.815036c9.371954 9.371954 9.371954 24.56788 0 33.941834l-89.347563 89.347564c-118.525421 118.523421-311.38448 118.531421-429.919901 0-118.527421-118.529421-118.527421-311.39048 0-429.917901l89.349564-89.349563c9.371954-9.371954 24.56788-9.371954 33.941834 0l79.195613 79.195613c9.371954 9.371954 9.371954 24.56788 0 33.941834l-89.349563 89.347564c-56.143726 56.145726-56.143726 147.49928 0 203.645005 56.143726 56.143726 147.49928 56.145726 203.647005 0l89.347564-89.347563c9.371954-9.371954 24.56788-9.371954 33.941834 0l79.193613 79.195613z m-113.135447-520.429459c9.371954 9.371954 24.56788 9.371954 33.941834 0l89.347564-89.347564c56.143726-56.149726 147.49928-56.145726 203.647006 0 56.143726 56.145726 56.143726 147.49928 0 203.645006l-89.349564 89.347564c-9.371954 9.371954-9.371954 24.56788 0 33.941834l79.195613 79.195613c9.371954 9.371954 24.56788 9.371954 33.941834 0l89.349564-89.349563c118.529421-118.529421 118.529421-311.38848 0-429.917901-118.531421-118.527421-311.38848-118.527421-429.919901 0l-89.347563 89.347564c-9.371954 9.371954-9.371954 24.56788 0 33.941834l79.193613 79.195613z m469.653707 718.556492l45.253779-45.253779c18.745908-18.745908 18.745908-49.13776 0-67.881669L127.195629 14.062931c-18.745908-18.745908-49.13776-18.745908-67.881669 0L14.058181 59.31871c-18.745908 18.745908-18.745908 49.13776 0 67.881669l882.74169 882.74169c18.745908 18.743908 49.13776 18.743908 67.881669 0z"></path></svg>',this.tag="button"}return e.prototype.getValue=function(e){return""},e.prototype.isActive=function(e){return!1},e.prototype.isDisabled=function(e){return null==e.selection||null==Ry.getSelectedNodeByType(e,"link")},e.prototype.exec=function(e,t){this.isDisabled(e)||zg.unwrapNodes(e,{match:function(e){return Ry.checkNodeType(e,"link")}})},e}(),MF=function(){function e(){this.title=eC("link.view"),this.iconSvg=bB,this.tag="button"}return e.prototype.getSelectedLinkElem=function(e){var t=Ry.getSelectedNodeByType(e,"link");return null==t?null:t},e.prototype.getValue=function(e){var t=this.getSelectedLinkElem(e);return t&&t.url||""},e.prototype.isActive=function(e){return!1},e.prototype.isDisabled=function(e){return null==e.selection||null==this.getSelectedLinkElem(e)},e.prototype.exec=function(e,t){if(!this.isDisabled(e)){if(!t||"string"!=typeof t)throw new Error("View link failed, link url is '".concat(t,"'"));window.open(t,"_blank")}},e}(),IF={checkLink:function(e,t){return!0},parseLinkUrl:function(e){return e}},RF={key:"insertLink",factory:function(){return new NF},config:IF},LF={key:"editLink",factory:function(){return new OF},config:IF},_F={key:"unLink",factory:function(){return new PF}},zF={key:"viewLink",factory:function(){return new MF}};var jF,HF,VF={selector:"a:not([data-w-e-type])",parseElemHtml:function(e,t,r){var n=ov(e).text().replace(/\s+/gm," ");return t.length>0?{text:t.filter(function(e){return Cg.isText(e)}).map(function(e){return e.text}).join("")||n}:{text:n}}};var $F=b(function(){if(HF)return jF;HF=1,jF=function(n){if("string"!=typeof n)return!1;var o=n.match(e);if(!o)return!1;var i=o[1];if(!i)return!1;if(t.test(i)||r.test(i))return!0;return!1};var e=/^(?:\w+:)?\/\/(\S+)$/,t=/^localhost[\:?\d]*(?:[^\:?\d]\S*)?$/,r=/^[^\s\.]+\.\S{2,}$/;return jF}());var UF={type:"link",renderElem:function(e,t,r){var n=e,o=n.url,i=n.target;return Tw("a",{href:o,target:void 0===i?"_blank":i},t)}},qF={renderElems:[UF],elemsToHtml:[EF],parseElemsHtml:[VF],menus:[RF,LF,_F,zF],editorPlugin:function(e){var t=e.isInline,r=e.insertData,n=e.normalizeNode,o=e;return o.isInline=function(e){return"link"===e.type||t(e)},o.insertData=function(e){var t=e.getData("text/plain");if($F(t)){if(/<img[^>]+>/.test(e.getData("text/html")))r(e);else if(!BF(o)){var n=o.selection;if(null!=n){var i=Yp.string(o,n);FF(o,i,t)}}}else r(e)},o.normalizeNode=function(e){var t=Qg(e,2),r=t[0],i=t[1];return"link"!==Ry.getNodeType(r)?n([r,i]):""===eg.string(r)?zg.removeNodes(o,{at:i}):n([r,i])},o}};var WF={selector:"p:not([data-w-e-type])",parseElemHtml:function(e,t,r){var n=ov(e);return 0===(t=t.filter(function(e){return!!Cg.isText(e)||!!r.isInline(e)})).length&&(t=[{text:n.text().replace(/\s+/gm," ")}]),{type:"paragraph",children:t}}};function GF(e){var t=Qg(Yp.nodes(e,{match:function(t){return e.children[0]===t},mode:"highest"}),1),r=t[0];if(null==r)return!1;var n=r[0];if(!Vp.isElement(n))return!1;if("paragraph"===n.type)return!1;if(""!==eg.string(n))return!1;var o=n.children,i=void 0===o?[]:o;return!!Cg.isText(i[0])&&(zg.setNodes(e,{type:"paragraph"}),!0)}var YF={type:"paragraph",renderElem:function(e,t,r){return Tw("p",null,t)}},KF={renderElems:[YF],elemsToHtml:[{type:"paragraph",elemToHtml:function(e,t){return""===t?"<p><br></p>":"<p>".concat(t,"</p>")}}],parseElemsHtml:[WF],editorPlugin:function(e){var t=e.deleteBackward,r=e.deleteForward,n=e;return n.deleteBackward=function(e){GF(n)||t(e)},n.deleteForward=function(e){GF(n)||r(e)},n}};function XF(e,t){if(null==e.selection)return!0;var r=Qg(Yp.nodes(e,{match:function(t){return"pre"===Ry.getNodeType(t)||!!Yp.isVoid(e,t)},universal:!0}),1);return!!r[0]}function ZF(e,t){Object.keys(t).forEach(function(t){"text"!==t&&Yp.removeMark(e,t)})}var JF=function(){function e(){this.marksNeedToRemove=[],this.tag="button"}return e.prototype.getValue=function(e){var t=this.mark,r=Yp.marks(e);if(r)return r[t];var n=Qg(Yp.nodes(e,{match:function(e){return!0===e[t]}}),1);return!!n[0]},e.prototype.isActive=function(e){return!!this.getValue(e)},e.prototype.isDisabled=function(e){return XF(e,this.mark)},e.prototype.exec=function(e,t){var r=this.mark,n=this.marksNeedToRemove;t?e.removeMark(r):(e.addMark(r,!0),n&&n.forEach(function(t){return e.removeMark(t)}))},e}(),QF=function(e){function t(){var t=e.apply(this,em([],Qg(arguments),!1))||this;return t.mark="bold",t.title=eC("textStyle.bold"),t.iconSvg='<svg viewBox="0 0 1024 1024"><path d="M707.872 484.64A254.88 254.88 0 0 0 768 320c0-141.152-114.848-256-256-256H192v896h384c141.152 0 256-114.848 256-256a256.096 256.096 0 0 0-124.128-219.36zM384 192h101.504c55.968 0 101.504 57.408 101.504 128s-45.536 128-101.504 128H384V192z m159.008 640H384v-256h159.008c58.464 0 106.016 57.408 106.016 128s-47.552 128-106.016 128z"></path></svg>',t.hotkey="mod+b",t}return Yg(t,e),t}(JF),ek=function(){function e(){this.title=eC("textStyle.clear"),this.iconSvg='<svg viewBox="0 0 1024 1024"><path d="M969.382408 288.738615l-319.401123-270.852152a67.074236 67.074236 0 0 0-96.459139 5.74922l-505.931379 574.922021a68.35184 68.35184 0 0 0-17.886463 47.910169 74.101061 74.101061 0 0 0 24.274486 47.910168l156.50655 132.232065h373.060512L975.131628 383.281347a67.074236 67.074236 0 0 0-5.74922-96.459139z m-440.134747 433.746725H264.144729l-90.071117-78.572676c-5.74922-5.74922-12.137243-12.137243-12.137243-17.886463a36.411728 36.411728 0 0 1 5.749221-24.274485l210.804741-240.828447 265.102932 228.691204z m-439.495945 180.781036h843.218964a60.047411 60.047411 0 1 1 0 120.733624H89.751716a60.047411 60.047411 0 1 1 0-120.733624z m0 0"></path></svg>',this.tag="button"}return e.prototype.getValue=function(e){return""},e.prototype.isActive=function(e){return!1},e.prototype.isDisabled=function(e){return XF(e)},e.prototype.exec=function(e,t){var r,n,o=Yp.nodes(e,{match:function(e){return Cg.isText(e)},universal:!0});try{for(var i=Jg(o),a=i.next();!a.done;a=i.next()){ZF(e,a.value[0])}}catch(e){r={error:e}}finally{try{a&&!a.done&&(n=i.return)&&n.call(i)}finally{if(r)throw r.error}}},e}(),tk=function(e){function t(){var t=e.apply(this,em([],Qg(arguments),!1))||this;return t.mark="code",t.title=eC("textStyle.code"),t.iconSvg='<svg viewBox="0 0 1024 1024"><path d="M576 736l96 96 320-320L672 192l-96 96 224 224zM448 288l-96-96L32 512l320 320 96-96-224-224z"></path></svg>',t.hotkey="mod+e",t}return Yg(t,e),t}(JF),rk=function(e){function t(){var t=e.apply(this,em([],Qg(arguments),!1))||this;return t.mark="italic",t.title=eC("textStyle.italic"),t.iconSvg='<svg viewBox="0 0 1024 1024"><path d="M896 64v64h-128L448 896h128v64H128v-64h128L576 128h-128V64z"></path></svg>',t.hotkey="mod+i",t}return Yg(t,e),t}(JF),nk=function(e){function t(){var t=e.apply(this,em([],Qg(arguments),!1))||this;return t.mark="sub",t.marksNeedToRemove=["sup"],t.title=eC("textStyle.sub"),t.iconSvg='<svg viewBox="0 0 1024 1024"><path d="M768 910.016v50.016h128v64h-192v-146.016l128-60V768h-128v-64h192v146.016zM676 256h-136L352 444 164 256H28l256 256-256 256h136L352 580 540 768h136l-256-256z"></path></svg>',t.hotkey="",t}return Yg(t,e),t}(JF),ok=function(e){function t(){var t=e.apply(this,em([],Qg(arguments),!1))||this;return t.mark="sup",t.marksNeedToRemove=["sub"],t.title=eC("textStyle.sup"),t.iconSvg='<svg viewBox="0 0 1024 1024"><path d="M768 206.016v50.016h128v64h-192V174.016l128-60V64h-128V0h192v146.016zM676 256h-136L352 444 164 256H28l256 256-256 256h136L352 580 540 768h136l-256-256z"></path></svg>',t.hotkey="",t}return Yg(t,e),t}(JF),ik=function(e){function t(){var t=e.apply(this,em([],Qg(arguments),!1))||this;return t.mark="through",t.title=eC("textStyle.through"),t.iconSvg='<svg viewBox="0 0 1024 1024"><path d="M1024 512v64h-234.496c27.52 38.496 42.496 82.688 42.496 128 0 70.88-36.672 139.04-100.576 186.976C672.064 935.488 594.144 960 512 960s-160.064-24.512-219.424-69.024C228.64 843.04 192 774.88 192 704h128c0 69.376 87.936 128 192 128s192-58.624 192-128-87.936-128-192-128H0v-64h299.52a385.984 385.984 0 0 1-6.944-5.024C228.64 459.04 192 390.88 192 320s36.672-139.04 100.576-186.976C351.936 88.512 429.856 64 512 64s160.064 24.512 219.424 69.024C795.328 180.96 832 249.12 832 320h-128c0-69.376-87.936-128-192-128s-192 58.624-192 128 87.936 128 192 128c78.976 0 154.048 22.688 212.48 64H1024z"></path></svg>',t.hotkey="mod+shift+x",t}return Yg(t,e),t}(JF),ak=function(e){function t(){var t=e.apply(this,em([],Qg(arguments),!1))||this;return t.mark="underline",t.title=eC("textStyle.underline"),t.iconSvg='<svg viewBox="0 0 1024 1024"><path d="M704 64l128 0 0 416c0 159.072-143.264 288-320 288s-320-128.928-320-288l0-416 128 0 0 416c0 40.16 18.24 78.688 51.36 108.512 36.896 33.216 86.848 51.488 140.64 51.488s103.744-18.304 140.64-51.488c33.12-29.792 51.36-68.352 51.36-108.512l0-416zM192 832l640 0 0 128-640 0z"></path></svg>',t.hotkey="mod+u",t}return Yg(t,e),t}(JF);function sk(e,t){return 0!==e.length&&(!!e[0].matches(t)||e.find(t).length>0)}function uk(e,t){var r=t,n=e,o=n.bold,i=n.italic,a=n.underline,s=n.code,u=n.through,l=n.sub,c=n.sup;return o&&(r="<strong>".concat(r,"</strong>")),s&&(r="<code>".concat(r,"</code>")),i&&(r="<em>".concat(r,"</em>")),a&&(r="<u>".concat(r,"</u>")),u&&(r="<s>".concat(r,"</s>")),l&&(r="<sub>".concat(r,"</sub>")),c&&(r="<sup>".concat(r,"</sup>")),r}var lk={renderStyle:function(e,t){var r=e,n=r.bold,o=r.italic,i=r.underline,a=r.code,s=r.through,u=r.sub,l=r.sup,c=t;return n&&(c=Tw("strong",null,c)),a&&(c=Tw("code",null,c)),o&&(c=Tw("em",null,c)),i&&(c=Tw("u",null,c)),s&&(c=Tw("s",null,c)),u&&(c=Tw("sub",null,c)),l&&(c=Tw("sup",null,c)),c},menus:[{key:"bold",factory:function(){return new QF}},{key:"underline",factory:function(){return new ak}},{key:"italic",factory:function(){return new rk}},{key:"through",factory:function(){return new ik}},{key:"code",factory:function(){return new tk}},{key:"sub",factory:function(){return new nk}},{key:"sup",factory:function(){return new ok}},{key:"clearStyle",factory:function(){return new ek}}],styleToHtml:function(e,t){if(!Cg.isText(e))return t;if(EB(t))return uk(e,t);var r=ov(t),n=r.html();return n=uk(e,n),r.html(n),AB(r)},parseStyleHtml:function(e,t,r){var n=ov(e);if(!Cg.isText(t))return t;var o=t;return sk(n,"b,strong")&&(o.bold=!0),sk(n,"i,em")&&(o.italic=!0),sk(n,"u")&&(o.underline=!0),sk(n,"s,strike")&&(o.through=!0),sk(n,"sub")&&(o.sub=!0),sk(n,"sup")&&(o.sup=!0),sk(n,"code")&&(o.code=!0),o}};var ck={type:"todo",elemToHtml:function(e,t){var r=e.checked;return'<div data-w-e-type="todo"><input type="checkbox" disabled '.concat(r?"checked":"",">").concat(t,"</div>")}},dk=function(){function e(){this.title=eC("todo.todo"),this.iconSvg='<svg viewBox="0 0 1024 1024"><path d="M278.755556 403.911111l-79.644445 79.644445L455.111111 739.555556l568.888889-568.888889-79.644444-79.644445L455.111111 580.266667l-176.355555-176.355556zM910.222222 910.222222H113.777778V113.777778h568.888889V0H113.777778C51.2 0 0 51.2 0 113.777778v796.444444c0 62.577778 51.2 113.777778 113.777778 113.777778h796.444444c62.577778 0 113.777778-51.2 113.777778-113.777778V455.111111h-113.777778v455.111111z"></path></svg>',this.tag="button"}return e.prototype.getValue=function(e){return""},e.prototype.isActive=function(e){return!!Ry.getSelectedNodeByType(e,"todo")},e.prototype.isDisabled=function(e){return null==e.selection||!!Ry.getSelectedElems(e).some(function(t){if(Yp.isVoid(e,t)&&Yp.isBlock(e,t))return!0;var r=t.type;return!!["pre","table","list-item"].includes(r)})},e.prototype.exec=function(e,t){var r=this.isActive(e);zg.setNodes(e,{type:r?"paragraph":"todo"})},e}();var hk={selector:'div[data-w-e-type="todo"]',parseElemHtml:function(e,t,r){var n=ov(e);0===(t=t.filter(function(e){return!!Cg.isText(e)||!!r.isInline(e)})).length&&(t=[{text:n.text().replace(/\s+/gm," ")}]);var o=!1;return null!=n.find('input[type="checkbox"]').attr("checked")&&(o=!0),{type:"todo",checked:o,children:t}}};var fk={type:"todo",renderElem:function(e,t,r){var n=!1;r.isDisabled()&&(n=!0);var o=Tw("div",{style:{margin:"5px 0"}},Tw("span",{contentEditable:!1,style:{marginRight:"0.5em"}},Tw("input",{type:"checkbox",checked:e.checked,disabled:n,on:{change:function(t){var n=Ry.findPath(r,e),o={checked:t.target.checked};zg.setNodes(r,o,{at:n})}}})),Tw("span",null,t));return o}},pk={renderElems:[fk],elemsToHtml:[ck],preParseHtml:[{selector:"ul.w-e-todo",preParseHtml:function(e){var t=ov(e).find("li"),r=ov('<div data-w-e-type="todo"></div>'),n=t.find("input[type]");return r.append(n),t.children()[0].remove(),r[0].innerHTML+=t[0].innerHTML,r[0]}}],parseElemsHtml:[hk],menus:[{key:"todo",factory:function(){return new dk}}],editorPlugin:function(e){var t=e.deleteBackward,r=e;return r.deleteBackward=function(r){var n=e.selection;if(n&&hg.isCollapsed(n)){var o=Ry.getSelectedNodeByType(e,"todo");if(o&&0===eg.string(o).length)return void zg.setNodes(e,{type:"paragraph"},{mode:"highest"})}t(r)},r}},gk=function(){function e(){this.title=eC("undo.redo"),this.iconSvg='<svg viewBox="0 0 1024 1024"><path d="M0.00032 576a510.72 510.72 0 0 0 173.344 384l84.672-96A383.136 383.136 0 0 1 128.00032 576C128.00032 363.936 299.93632 192 512.00032 192c106.048 0 202.048 42.976 271.52 112.48L640.00032 448h384V64l-149.984 149.984A510.272 510.272 0 0 0 512.00032 64C229.21632 64 0.00032 293.216 0.00032 576z"></path></svg>',this.tag="button"}return e.prototype.getValue=function(e){return""},e.prototype.isActive=function(e){return!1},e.prototype.isDisabled=function(e){return null==e.selection},e.prototype.exec=function(e,t){"function"==typeof e.redo&&e.redo()},e}(),mk=function(){function e(){this.title=eC("undo.undo"),this.iconSvg='<svg viewBox="0 0 1024 1024"><path d="M512 64A510.272 510.272 0 0 0 149.984 213.984L0.032 64v384h384L240.512 304.48A382.784 382.784 0 0 1 512.032 192c212.064 0 384 171.936 384 384 0 114.688-50.304 217.632-130.016 288l84.672 96a510.72 510.72 0 0 0 173.344-384c0-282.784-229.216-512-512-512z"></path></svg>',this.tag="button"}return e.prototype.getValue=function(e){return""},e.prototype.isActive=function(e){return!1},e.prototype.isDisabled=function(e){return null==e.selection},e.prototype.exec=function(e,t){"function"==typeof e.undo&&e.undo()},e}(),vk=[lk,UB,rS,pF,DF,wF,cF,KB,ZB,qF,LB,OB,jS,KF,pk,oS,{menus:[{key:"redo",factory:function(){return new gk}},{key:"undo",factory:function(){return new mk}}]},aS,WB];XD("en",{highLightModule:{selectLang:"Language"}}),XD("zh-CN",{highLightModule:{selectLang:"选择语言"}});var yk,bk={exports:{}};var Dk=(yk||(yk=1,function(e){var t=function(e){var t=/(?:^|\s)lang(?:uage)?-([\w-]+)(?=\s|$)/i,r=0,n={},o={manual:e.Prism&&e.Prism.manual,disableWorkerMessageHandler:e.Prism&&e.Prism.disableWorkerMessageHandler,util:{encode:function e(t){return t instanceof i?new i(t.type,e(t.content),t.alias):Array.isArray(t)?t.map(e):t.replace(/&/g,"&").replace(/</g,"<").replace(/\u00a0/g," ")},type:function(e){return Object.prototype.toString.call(e).slice(8,-1)},objId:function(e){return e.__id||Object.defineProperty(e,"__id",{value:++r}),e.__id},clone:function e(t,r){var n,i;switch(r=r||{},o.util.type(t)){case"Object":if(i=o.util.objId(t),r[i])return r[i];for(var a in n={},r[i]=n,t)t.hasOwnProperty(a)&&(n[a]=e(t[a],r));return n;case"Array":return i=o.util.objId(t),r[i]?r[i]:(n=[],r[i]=n,t.forEach(function(t,o){n[o]=e(t,r)}),n);default:return t}},getLanguage:function(e){for(;e;){var r=t.exec(e.className);if(r)return r[1].toLowerCase();e=e.parentElement}return"none"},setLanguage:function(e,r){e.className=e.className.replace(RegExp(t,"gi"),""),e.classList.add("language-"+r)},currentScript:function(){if("undefined"==typeof document)return null;if(document.currentScript&&"SCRIPT"===document.currentScript.tagName)return document.currentScript;try{throw new Error}catch(n){var e=(/at [^(\r\n]*\((.*):[^:]+:[^:]+\)$/i.exec(n.stack)||[])[1];if(e){var t=document.getElementsByTagName("script");for(var r in t)if(t[r].src==e)return t[r]}return null}},isActive:function(e,t,r){for(var n="no-"+t;e;){var o=e.classList;if(o.contains(t))return!0;if(o.contains(n))return!1;e=e.parentElement}return!!r}},languages:{plain:n,plaintext:n,text:n,txt:n,extend:function(e,t){var r=o.util.clone(o.languages[e]);for(var n in t)r[n]=t[n];return r},insertBefore:function(e,t,r,n){var i=(n=n||o.languages)[e],a={};for(var s in i)if(i.hasOwnProperty(s)){if(s==t)for(var u in r)r.hasOwnProperty(u)&&(a[u]=r[u]);r.hasOwnProperty(s)||(a[s]=i[s])}var l=n[e];return n[e]=a,o.languages.DFS(o.languages,function(t,r){r===l&&t!=e&&(this[t]=a)}),a},DFS:function e(t,r,n,i){i=i||{};var a=o.util.objId;for(var s in t)if(t.hasOwnProperty(s)){r.call(t,s,t[s],n||s);var u=t[s],l=o.util.type(u);"Object"!==l||i[a(u)]?"Array"!==l||i[a(u)]||(i[a(u)]=!0,e(u,r,s,i)):(i[a(u)]=!0,e(u,r,null,i))}}},plugins:{},highlightAll:function(e,t){o.highlightAllUnder(document,e,t)},highlightAllUnder:function(e,t,r){var n={callback:r,container:e,selector:'code[class*="language-"], [class*="language-"] code, code[class*="lang-"], [class*="lang-"] code'};o.hooks.run("before-highlightall",n),n.elements=Array.prototype.slice.apply(n.container.querySelectorAll(n.selector)),o.hooks.run("before-all-elements-highlight",n);for(var i,a=0;i=n.elements[a++];)o.highlightElement(i,!0===t,n.callback)},highlightElement:function(t,r,n){var i=o.util.getLanguage(t),a=o.languages[i];o.util.setLanguage(t,i);var s=t.parentElement;s&&"pre"===s.nodeName.toLowerCase()&&o.util.setLanguage(s,i);var u={element:t,language:i,grammar:a,code:t.textContent};function l(e){u.highlightedCode=e,o.hooks.run("before-insert",u),u.element.innerHTML=u.highlightedCode,o.hooks.run("after-highlight",u),o.hooks.run("complete",u),n&&n.call(u.element)}if(o.hooks.run("before-sanity-check",u),(s=u.element.parentElement)&&"pre"===s.nodeName.toLowerCase()&&!s.hasAttribute("tabindex")&&s.setAttribute("tabindex","0"),!u.code)return o.hooks.run("complete",u),void(n&&n.call(u.element));if(o.hooks.run("before-highlight",u),u.grammar)if(r&&e.Worker){var c=new Worker(o.filename);c.onmessage=function(e){l(e.data)},c.postMessage(JSON.stringify({language:u.language,code:u.code,immediateClose:!0}))}else l(o.highlight(u.code,u.grammar,u.language));else l(o.util.encode(u.code))},highlight:function(e,t,r){var n={code:e,grammar:t,language:r};if(o.hooks.run("before-tokenize",n),!n.grammar)throw new Error('The language "'+n.language+'" has no grammar.');return n.tokens=o.tokenize(n.code,n.grammar),o.hooks.run("after-tokenize",n),i.stringify(o.util.encode(n.tokens),n.language)},tokenize:function(e,t){var r=t.rest;if(r){for(var n in r)t[n]=r[n];delete t.rest}var o=new u;return l(o,o.head,e),s(e,o,t,o.head,0),function(e){for(var t=[],r=e.head.next;r!==e.tail;)t.push(r.value),r=r.next;return t}(o)},hooks:{all:{},add:function(e,t){var r=o.hooks.all;r[e]=r[e]||[],r[e].push(t)},run:function(e,t){var r=o.hooks.all[e];if(r&&r.length)for(var n,i=0;n=r[i++];)n(t)}},Token:i};function i(e,t,r,n){this.type=e,this.content=t,this.alias=r,this.length=0|(n||"").length}function a(e,t,r,n){e.lastIndex=t;var o=e.exec(r);if(o&&n&&o[1]){var i=o[1].length;o.index+=i,o[0]=o[0].slice(i)}return o}function s(e,t,r,n,u,d){for(var h in r)if(r.hasOwnProperty(h)&&r[h]){var f=r[h];f=Array.isArray(f)?f:[f];for(var p=0;p<f.length;++p){if(d&&d.cause==h+","+p)return;var g=f[p],m=g.inside,v=!!g.lookbehind,y=!!g.greedy,b=g.alias;if(y&&!g.pattern.global){var D=g.pattern.toString().match(/[imsuy]*$/)[0];g.pattern=RegExp(g.pattern.source,D+"g")}for(var C=g.pattern||g,w=n.next,E=u;w!==t.tail&&!(d&&E>=d.reach);E+=w.value.length,w=w.next){var A=w.value;if(t.length>e.length)return;if(!(A instanceof i)){var x,B=1;if(y){if(!(x=a(C,E,e,v))||x.index>=e.length)break;var S=x.index,F=x.index+x[0].length,k=E;for(k+=w.value.length;S>=k;)k+=(w=w.next).value.length;if(E=k-=w.value.length,w.value instanceof i)continue;for(var O=w;O!==t.tail&&(k<F||"string"==typeof O.value);O=O.next)B++,k+=O.value.length;B--,A=e.slice(E,k),x.index-=E}else if(!(x=a(C,0,A,v)))continue;S=x.index;var T=x[0],N=A.slice(0,S),P=A.slice(S+T.length),M=E+A.length;d&&M>d.reach&&(d.reach=M);var I=w.prev;if(N&&(I=l(t,I,N),E+=N.length),c(t,I,B),w=l(t,I,new i(h,m?o.tokenize(T,m):T,b,T)),P&&l(t,w,P),B>1){var R={cause:h+","+p,reach:M};s(e,t,r,w.prev,E,R),d&&R.reach>d.reach&&(d.reach=R.reach)}}}}}}function u(){var e={value:null,prev:null,next:null},t={value:null,prev:e,next:null};e.next=t,this.head=e,this.tail=t,this.length=0}function l(e,t,r){var n=t.next,o={value:r,prev:t,next:n};return t.next=o,n.prev=o,e.length++,o}function c(e,t,r){for(var n=t.next,o=0;o<r&&n!==e.tail;o++)n=n.next;t.next=n,n.prev=t,e.length-=o}if(e.Prism=o,i.stringify=function e(t,r){if("string"==typeof t)return t;if(Array.isArray(t)){var n="";return t.forEach(function(t){n+=e(t,r)}),n}var i={type:t.type,content:e(t.content,r),tag:"span",classes:["token",t.type],attributes:{},language:r},a=t.alias;a&&(Array.isArray(a)?Array.prototype.push.apply(i.classes,a):i.classes.push(a)),o.hooks.run("wrap",i);var s="";for(var u in i.attributes)s+=" "+u+'="'+(i.attributes[u]||"").replace(/"/g,""")+'"';return"<"+i.tag+' class="'+i.classes.join(" ")+'"'+s+">"+i.content+"</"+i.tag+">"},!e.document)return e.addEventListener?(o.disableWorkerMessageHandler||e.addEventListener("message",function(t){var r=JSON.parse(t.data),n=r.language,i=r.code,a=r.immediateClose;e.postMessage(o.highlight(i,o.languages[n],n)),a&&e.close()},!1),o):o;var d=o.util.currentScript();function h(){o.manual||o.highlightAll()}if(d&&(o.filename=d.src,d.hasAttribute("data-manual")&&(o.manual=!0)),!o.manual){var f=document.readyState;"loading"===f||"interactive"===f&&d&&d.defer?document.addEventListener("DOMContentLoaded",h):window.requestAnimationFrame?window.requestAnimationFrame(h):window.setTimeout(h,16)}return o}("undefined"!=typeof window?window:"undefined"!=typeof WorkerGlobalScope&&self instanceof WorkerGlobalScope?self:{});
|
|
19
19
|
/**
|
|
20
20
|
* Prism: Lightweight, robust, elegant syntax highlighting
|
|
21
21
|
*
|
|
@@ -23,5 +23,11 @@ var e,t,n,r,o,i,a,s,u,l,c,d,f,p,h,g,v,m,y="undefined"!=typeof globalThis?globalT
|
|
|
23
23
|
* @author Lea Verou <https://lea.verou.me>
|
|
24
24
|
* @namespace
|
|
25
25
|
* @public
|
|
26
|
-
*/e.exports&&(e.exports=t),void 0!==y&&(y.Prism=t),t.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"},{pattern:/^(\s*)["']|["']$/,lookbehind:!0}]}},punctuation:/\/?>/,"attr-name":{pattern:/[^\s>\/]+/,inside:{namespace:/^[^\s>\/:]+:/}}}},entity:[{pattern:/&[\da-z]{1,8};/i,alias:"named-entity"},/&#x?[\da-f]{1,8};/i]},t.languages.markup.tag.inside["attr-value"].inside.entity=t.languages.markup.entity,t.languages.markup.doctype.inside["internal-subset"].inside=t.languages.markup,t.hooks.add("wrap",function(e){"entity"===e.type&&(e.attributes.title=e.content.replace(/&/,"&"))}),Object.defineProperty(t.languages.markup.tag,"addInlined",{value:function(e,n){var r={};r["language-"+n]={pattern:/(^<!\[CDATA\[)[\s\S]+?(?=\]\]>$)/i,lookbehind:!0,inside:t.languages[n]},r.cdata=/^<!\[CDATA\[|\]\]>$/i;var o={"included-cdata":{pattern:/<!\[CDATA\[[\s\S]*?\]\]>/i,inside:r}};o["language-"+n]={pattern:/[\s\S]+/,inside:t.languages[n]};var i={};i[e]={pattern:RegExp(/(<__[^>]*>)(?:<!\[CDATA\[(?:[^\]]|\](?!\]>))*\]\]>|(?!<!\[CDATA\[)[\s\S])*?(?=<\/__>)/.source.replace(/__/g,function(){return e}),"i"),lookbehind:!0,greedy:!0,inside:o},t.languages.insertBefore("markup","cdata",i)}}),Object.defineProperty(t.languages.markup.tag,"addAttribute",{value:function(e,n){t.languages.markup.tag.inside["special-attr"].push({pattern:RegExp(/(^|["'\s])/.source+"(?:"+e+")"+/\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:[n,"language-"+n],inside:t.languages[n]},punctuation:[{pattern:/^=/,alias:"attr-equals"},/"|'/]}}}})}}),t.languages.html=t.languages.markup,t.languages.mathml=t.languages.markup,t.languages.svg=t.languages.markup,t.languages.xml=t.languages.extend("markup",{}),t.languages.ssml=t.languages.xml,t.languages.atom=t.languages.xml,t.languages.rss=t.languages.xml,function(e){var t=/(?:"(?:\\(?:\r\n|[\s\S])|[^"\\\r\n])*"|'(?:\\(?:\r\n|[\s\S])|[^'\\\r\n])*')/;e.languages.css={comment:/\/\*[\s\S]*?\*\//,atrule:{pattern:RegExp("@[\\w-](?:"+/[^;{\s"']|\s+(?!\s)/.source+"|"+t.source+")*?"+/(?:;|(?=\s*\{))/.source),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\\((?:"+t.source+"|"+/(?:[^\\\r\n()"']|\\[\s\S])*/.source+")\\)","i"),greedy:!0,inside:{function:/^url/i,punctuation:/^\(|\)$/,string:{pattern:RegExp("^"+t.source+"$"),alias:"url"}}},selector:{pattern:RegExp("(^|[{}\\s])[^{}\\s](?:[^{};\"'\\s]|\\s+(?![\\s{])|"+t.source+")*(?=\\s*\\{)"),lookbehind:!0},string:{pattern:t,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:/[(){};:,]/},e.languages.css.atrule.inside.rest=e.languages.css;var n=e.languages.markup;n&&(n.tag.addInlined("style","css"),n.tag.addAttribute("style","css"))}(t),t.languages.clike={comment:[{pattern:/(^|[^\\])\/\*[\s\S]*?(?:\*\/|$)/,lookbehind:!0,greedy:!0},{pattern:/(^|[^\\:])\/\/.*/,lookbehind:!0,greedy:!0}],string:{pattern:/(["'])(?:\\(?:\r\n|[\s\S])|(?!\1)[^\\\r\n])*\1/,greedy:!0},"class-name":{pattern:/(\b(?:class|extends|implements|instanceof|interface|new|trait)\s+|\bcatch\s+\()[\w.\\]+/i,lookbehind:!0,inside:{punctuation:/[.\\]/}},keyword:/\b(?:break|catch|continue|do|else|finally|for|function|if|in|instanceof|new|null|return|throw|try|while)\b/,boolean:/\b(?:false|true)\b/,function:/\b\w+(?=\()/,number:/\b0x[\da-f]+\b|(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:e[+-]?\d+)?/i,operator:/[<>]=?|[!=]=?=?|--?|\+\+?|&&?|\|\|?|[?*/~^%]/,punctuation:/[{}[\];(),.:]/},t.languages.javascript=t.languages.extend("clike",{"class-name":[t.languages.clike["class-name"],{pattern:/(^|[^$\w\xA0-\uFFFF])(?!\s)[_$A-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\.(?:constructor|prototype))/,lookbehind:!0}],keyword:[{pattern:/((?:^|\})\s*)catch\b/,lookbehind:!0},{pattern:/(^|[^.]|\.\.\.\s*)\b(?:as|assert(?=\s*\{)|async(?=\s*(?:function\b|\(|[$\w\xA0-\uFFFF]|$))|await|break|case|class|const|continue|debugger|default|delete|do|else|enum|export|extends|finally(?=\s*(?:\{|$))|for|from(?=\s*(?:['"]|$))|function|(?:get|set)(?=\s*(?:[#\[$\w\xA0-\uFFFF]|$))|if|implements|import|in|instanceof|interface|let|new|null|of|package|private|protected|public|return|static|super|switch|this|throw|try|typeof|undefined|var|void|while|with|yield)\b/,lookbehind:!0}],function:/#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*(?:\.\s*(?:apply|bind|call)\s*)?\()/,number:{pattern:RegExp(/(^|[^\w$])/.source+"(?:"+/NaN|Infinity/.source+"|"+/0[bB][01]+(?:_[01]+)*n?/.source+"|"+/0[oO][0-7]+(?:_[0-7]+)*n?/.source+"|"+/0[xX][\dA-Fa-f]+(?:_[\dA-Fa-f]+)*n?/.source+"|"+/\d+(?:_\d+)*n/.source+"|"+/(?:\d+(?:_\d+)*(?:\.(?:\d+(?:_\d+)*)?)?|\.\d+(?:_\d+)*)(?:[Ee][+-]?\d+(?:_\d+)*)?/.source+")"+/(?![\w$])/.source),lookbehind:!0},operator:/--|\+\+|\*\*=?|=>|&&=?|\|\|=?|[!=]==|<<=?|>>>?=?|[-+*/%&|^!=<>]=?|\.{3}|\?\?=?|\?\.?|[~:]/}),t.languages.javascript["class-name"][0].pattern=/(\b(?:class|extends|implements|instanceof|interface|new)\s+)[\w.\\]+/,t.languages.insertBefore("javascript","keyword",{regex:{pattern:RegExp(/((?:^|[^$\w\xA0-\uFFFF."'\])\s]|\b(?:return|yield))\s*)/.source+/\//.source+"(?:"+/(?:\[(?:[^\]\\\r\n]|\\.)*\]|\\.|[^/\\\[\r\n])+\/[dgimyus]{0,7}/.source+"|"+/(?:\[(?:[^[\]\\\r\n]|\\.|\[(?:[^[\]\\\r\n]|\\.|\[(?:[^[\]\\\r\n]|\\.)*\])*\])*\]|\\.|[^/\\\[\r\n])+\/[dgimyus]{0,7}v[dgimyus]{0,7}/.source+")"+/(?=(?:\s|\/\*(?:[^*]|\*(?!\/))*\*\/)*(?:$|[\r\n,.;:})\]]|\/\/))/.source),lookbehind:!0,greedy:!0,inside:{"regex-source":{pattern:/^(\/)[\s\S]+(?=\/[a-z]*$)/,lookbehind:!0,alias:"language-regex",inside:t.languages.regex},"regex-delimiter":/^\/|\/$/,"regex-flags":/^[a-z]+$/}},"function-variable":{pattern:/#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*[=:]\s*(?:async\s*)?(?:\bfunction\b|(?:\((?:[^()]|\([^()]*\))*\)|(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*)\s*=>))/,alias:"function"},parameter:[{pattern:/(function(?:\s+(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*)?\s*\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\))/,lookbehind:!0,inside:t.languages.javascript},{pattern:/(^|[^$\w\xA0-\uFFFF])(?!\s)[_$a-z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*=>)/i,lookbehind:!0,inside:t.languages.javascript},{pattern:/(\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\)\s*=>)/,lookbehind:!0,inside:t.languages.javascript},{pattern:/((?:\b|\s|^)(?!(?:as|async|await|break|case|catch|class|const|continue|debugger|default|delete|do|else|enum|export|extends|finally|for|from|function|get|if|implements|import|in|instanceof|interface|let|new|null|of|package|private|protected|public|return|set|static|super|switch|this|throw|try|typeof|undefined|var|void|while|with|yield)(?![$\w\xA0-\uFFFF]))(?:(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*\s*)\(\s*|\]\s*\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\)\s*\{)/,lookbehind:!0,inside:t.languages.javascript}],constant:/\b[A-Z](?:[A-Z_]|\dx?)*\b/}),t.languages.insertBefore("javascript","string",{hashbang:{pattern:/^#!.*/,greedy:!0,alias:"comment"},"template-string":{pattern:/`(?:\\[\s\S]|\$\{(?:[^{}]|\{(?:[^{}]|\{[^}]*\})*\})+\}|(?!\$\{)[^\\`])*`/,greedy:!0,inside:{"template-punctuation":{pattern:/^`|`$/,alias:"string"},interpolation:{pattern:/((?:^|[^\\])(?:\\{2})*)\$\{(?:[^{}]|\{(?:[^{}]|\{[^}]*\})*\})+\}/,lookbehind:!0,inside:{"interpolation-punctuation":{pattern:/^\$\{|\}$/,alias:"punctuation"},rest:t.languages.javascript}},string:/[\s\S]+/}},"string-property":{pattern:/((?:^|[,{])[ \t]*)(["'])(?:\\(?:\r\n|[\s\S])|(?!\2)[^\\\r\n])*\2(?=\s*:)/m,lookbehind:!0,greedy:!0,alias:"property"}}),t.languages.insertBefore("javascript","operator",{"literal-property":{pattern:/((?:^|[,{])[ \t]*)(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*:)/m,lookbehind:!0,alias:"property"}}),t.languages.markup&&(t.languages.markup.tag.addInlined("script","javascript"),t.languages.markup.tag.addAttribute(/on(?:abort|blur|change|click|composition(?:end|start|update)|dblclick|error|focus(?:in|out)?|key(?:down|up)|load|mouse(?:down|enter|leave|move|out|over|up)|reset|resize|scroll|select|slotchange|submit|unload|wheel)/.source,"javascript")),t.languages.js=t.languages.javascript,function(){if(void 0!==t&&"undefined"!=typeof document){Element.prototype.matches||(Element.prototype.matches=Element.prototype.msMatchesSelector||Element.prototype.webkitMatchesSelector);var e={js:"javascript",py:"python",rb:"ruby",ps1:"powershell",psm1:"powershell",sh:"bash",bat:"batch",h:"c",tex:"latex"},n="data-src-status",r="loading",o="loaded",i="pre[data-src]:not(["+n+'="'+o+'"]):not(['+n+'="'+r+'"])';t.hooks.add("before-highlightall",function(e){e.selector+=", "+i}),t.hooks.add("before-sanity-check",function(a){var s=a.element;if(s.matches(i)){a.code="",s.setAttribute(n,r);var u=s.appendChild(document.createElement("CODE"));u.textContent="Loading…";var l=s.getAttribute("data-src"),c=a.language;if("none"===c){var d=(/\.(\w+)$/.exec(l)||[,"none"])[1];c=e[d]||d}t.util.setLanguage(u,c),t.util.setLanguage(s,c);var f=t.plugins.autoloader;f&&f.loadLanguages(c),function(e,t,n){var r=new XMLHttpRequest;r.open("GET",e,!0),r.onreadystatechange=function(){4==r.readyState&&(r.status<400&&r.responseText?t(r.responseText):r.status>=400?n("✖ Error "+r.status+" while fetching file: "+r.statusText):n("✖ Error: File does not exist or is empty"))},r.send(null)}(l,function(e){s.setAttribute(n,o);var r=function(e){var t=/^\s*(\d+)\s*(?:(,)\s*(?:(\d+)\s*)?)?$/.exec(e||"");if(t){var n=Number(t[1]),r=t[2],o=t[3];return r?o?[n,Number(o)]:[n,void 0]:[n,n]}}(s.getAttribute("data-range"));if(r){var i=e.split(/\r\n?|\n/g),a=r[0],l=null==r[1]?i.length:r[1];a<0&&(a+=i.length),a=Math.max(0,Math.min(a-1,i.length)),l<0&&(l+=i.length),l=Math.max(0,Math.min(l,i.length)),e=i.slice(a,l).join("\n"),s.hasAttribute("data-start")||s.setAttribute("data-start",String(a+1))}u.textContent=e,t.highlightElement(u)},function(e){s.setAttribute(n,"failed"),u.textContent=e})}}),t.plugins.fileHighlight={highlight:function(e){for(var n,r=(e||document).querySelectorAll(i),o=0;n=r[o++];)t.highlightElement(n)}};var a=!1;t.fileHighlight=function(){a||(console.warn("Prism.fileHighlight is deprecated. Use `Prism.plugins.fileHighlight.highlight` instead."),a=!0),t.plugins.fileHighlight.highlight.apply(this,arguments)}}}()}(yB)),yB.exports),EB=b(bB);!function(e){var t=e.util.clone(e.languages.javascript),n=/(?:\s|\/\/.*(?!.)|\/\*(?:[^*]|\*(?!\/))\*\/)/.source,r=/(?:\{(?:\{(?:\{[^{}]*\}|[^{}])*\}|[^{}])*\})/.source,o=/(?:\{<S>*\.{3}(?:[^{}]|<BRACES>)*\})/.source;function i(e,t){return e=e.replace(/<S>/g,function(){return n}).replace(/<BRACES>/g,function(){return r}).replace(/<SPREAD>/g,function(){return o}),RegExp(e,t)}o=i(o).source,e.languages.jsx=e.languages.extend("markup",t),e.languages.jsx.tag.pattern=i(/<\/?(?:[\w.:-]+(?:<S>+(?:[\w.:$-]+(?:=(?:"(?:\\[\s\S]|[^\\"])*"|'(?:\\[\s\S]|[^\\'])*'|[^\s{'"/>=]+|<BRACES>))?|<SPREAD>))*<S>*\/?)?>/.source),e.languages.jsx.tag.inside.tag.pattern=/^<\/?[^\s>\/]*/,e.languages.jsx.tag.inside["attr-value"].pattern=/=(?!\{)(?:"(?:\\[\s\S]|[^\\"])*"|'(?:\\[\s\S]|[^\\'])*'|[^\s'">]+)/,e.languages.jsx.tag.inside.tag.inside["class-name"]=/^[A-Z]\w*(?:\.[A-Z]\w*)*$/,e.languages.jsx.tag.inside.comment=t.comment,e.languages.insertBefore("inside","attr-name",{spread:{pattern:i(/<SPREAD>/.source),inside:e.languages.jsx}},e.languages.jsx.tag),e.languages.insertBefore("inside","special-attr",{script:{pattern:i(/=<BRACES>/.source),alias:"language-javascript",inside:{"script-punctuation":{pattern:/^=(?=\{)/,alias:"punctuation"},rest:e.languages.jsx}}},e.languages.jsx.tag);var a=function(e){return e?"string"==typeof e?e:"string"==typeof e.content?e.content:e.content.map(a).join(""):""},s=function(t){for(var n=[],r=0;r<t.length;r++){var o=t[r],i=!1;if("string"!=typeof o&&("tag"===o.type&&o.content[0]&&"tag"===o.content[0].type?"</"===o.content[0].content[0].content?n.length>0&&n[n.length-1].tagName===a(o.content[0].content[1])&&n.pop():"/>"===o.content[o.content.length-1].content||n.push({tagName:a(o.content[0].content[1]),openedBraces:0}):n.length>0&&"punctuation"===o.type&&"{"===o.content?n[n.length-1].openedBraces++:n.length>0&&n[n.length-1].openedBraces>0&&"punctuation"===o.type&&"}"===o.content?n[n.length-1].openedBraces--:i=!0),(i||"string"==typeof o)&&n.length>0&&0===n[n.length-1].openedBraces){var u=a(o);r<t.length-1&&("string"==typeof t[r+1]||"plain-text"===t[r+1].type)&&(u+=a(t[r+1]),t.splice(r+1,1)),r>0&&("string"==typeof t[r-1]||"plain-text"===t[r-1].type)&&(u=a(t[r-1])+u,t.splice(r-1,1),r--),t[r]=new e.Token("plain-text",u,null,u)}o.content&&"string"!=typeof o.content&&s(o.content)}};e.hooks.add("after-tokenize",function(e){"jsx"!==e.language&&"tsx"!==e.language||s(e.tokens)})}(Prism);var CB;CB||(CB=1,function(e){e.languages.typescript=e.languages.extend("javascript",{"class-name":{pattern:/(\b(?:class|extends|implements|instanceof|interface|new|type)\s+)(?!keyof\b)(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?:\s*<(?:[^<>]|<(?:[^<>]|<[^<>]*>)*>)*>)?/,lookbehind:!0,greedy:!0,inside:null},builtin:/\b(?:Array|Function|Promise|any|boolean|console|never|number|string|symbol|unknown)\b/}),e.languages.typescript.keyword.push(/\b(?:abstract|declare|is|keyof|readonly|require)\b/,/\b(?:asserts|infer|interface|module|namespace|type)\b(?=\s*(?:[{_$a-zA-Z\xA0-\uFFFF]|$))/,/\btype\b(?=\s*(?:[\{*]|$))/),delete e.languages.typescript.parameter,delete e.languages.typescript["literal-property"];var t=e.languages.extend("typescript",{});delete t["class-name"],e.languages.typescript["class-name"].inside=t,e.languages.insertBefore("typescript","function",{decorator:{pattern:/@[$\w\xA0-\uFFFF]+/,inside:{at:{pattern:/^@/,alias:"operator"},function:/^[\s\S]+/}},"generic-function":{pattern:/#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*\s*<(?:[^<>]|<(?:[^<>]|<[^<>]*>)*>)*>(?=\s*\()/,greedy:!0,inside:{function:/^#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*/,generic:{pattern:/<[\s\S]+/,alias:"class-name",inside:t}}}}),e.languages.ts=e.languages.typescript}(Prism)),Prism.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"},{pattern:/^(\s*)["']|["']$/,lookbehind:!0}]}},punctuation:/\/?>/,"attr-name":{pattern:/[^\s>\/]+/,inside:{namespace:/^[^\s>\/:]+:/}}}},entity:[{pattern:/&[\da-z]{1,8};/i,alias:"named-entity"},/&#x?[\da-f]{1,8};/i]},Prism.languages.markup.tag.inside["attr-value"].inside.entity=Prism.languages.markup.entity,Prism.languages.markup.doctype.inside["internal-subset"].inside=Prism.languages.markup,Prism.hooks.add("wrap",function(e){"entity"===e.type&&(e.attributes.title=e.content.replace(/&/,"&"))}),Object.defineProperty(Prism.languages.markup.tag,"addInlined",{value:function(e,t){var n={};n["language-"+t]={pattern:/(^<!\[CDATA\[)[\s\S]+?(?=\]\]>$)/i,lookbehind:!0,inside:Prism.languages[t]},n.cdata=/^<!\[CDATA\[|\]\]>$/i;var r={"included-cdata":{pattern:/<!\[CDATA\[[\s\S]*?\]\]>/i,inside:n}};r["language-"+t]={pattern:/[\s\S]+/,inside:Prism.languages[t]};var o={};o[e]={pattern:RegExp(/(<__[^>]*>)(?:<!\[CDATA\[(?:[^\]]|\](?!\]>))*\]\]>|(?!<!\[CDATA\[)[\s\S])*?(?=<\/__>)/.source.replace(/__/g,function(){return e}),"i"),lookbehind:!0,greedy:!0,inside:r},Prism.languages.insertBefore("markup","cdata",o)}}),Object.defineProperty(Prism.languages.markup.tag,"addAttribute",{value:function(e,t){Prism.languages.markup.tag.inside["special-attr"].push({pattern:RegExp(/(^|["'\s])/.source+"(?:"+e+")"+/\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:[t,"language-"+t],inside:Prism.languages[t]},punctuation:[{pattern:/^=/,alias:"attr-equals"},/"|'/]}}}})}}),Prism.languages.html=Prism.languages.markup,Prism.languages.mathml=Prism.languages.markup,Prism.languages.svg=Prism.languages.markup,Prism.languages.xml=Prism.languages.extend("markup",{}),Prism.languages.ssml=Prism.languages.xml,Prism.languages.atom=Prism.languages.xml,Prism.languages.rss=Prism.languages.xml,Prism.languages.go=Prism.languages.extend("clike",{string:{pattern:/(^|[^\\])"(?:\\.|[^"\\\r\n])*"|`[^`]*`/,lookbehind:!0,greedy:!0},keyword:/\b(?:break|case|chan|const|continue|default|defer|else|fallthrough|for|func|go(?:to)?|if|import|interface|map|package|range|return|select|struct|switch|type|var)\b/,boolean:/\b(?:_|false|iota|nil|true)\b/,number:[/\b0(?:b[01_]+|o[0-7_]+)i?\b/i,/\b0x(?:[a-f\d_]+(?:\.[a-f\d_]*)?|\.[a-f\d_]+)(?:p[+-]?\d+(?:_\d+)*)?i?(?!\w)/i,/(?:\b\d[\d_]*(?:\.[\d_]*)?|\B\.\d[\d_]*)(?:e[+-]?[\d_]+)?i?(?!\w)/i],operator:/[*\/%^!=]=?|\+[=+]?|-[=-]?|\|[=|]?|&(?:=|&|\^=?)?|>(?:>=?|=)?|<(?:<=?|=|-)?|:=|\.\.\./,builtin:/\b(?:append|bool|byte|cap|close|complex|complex(?:64|128)|copy|delete|error|float(?:32|64)|u?int(?:8|16|32|64)?|imag|len|make|new|panic|print(?:ln)?|real|recover|rune|string|uintptr)\b/}),Prism.languages.insertBefore("go","string",{char:{pattern:/'(?:\\.|[^'\\\r\n]){0,10}'/,greedy:!0}}),delete Prism.languages.go["class-name"];var DB;DB||(DB=1,function(e){var t=/\/\*[\s\S]*?\*\/|\/\/.*|#(?!\[).*/,n=[{pattern:/\b(?:false|true)\b/i,alias:"boolean"},{pattern:/(::\s*)\b[a-z_]\w*\b(?!\s*\()/i,greedy:!0,lookbehind:!0},{pattern:/(\b(?:case|const)\s+)\b[a-z_]\w*(?=\s*[;=])/i,greedy:!0,lookbehind:!0},/\b(?:null)\b/i,/\b[A-Z_][A-Z0-9_]*\b(?!\s*\()/],r=/\b0b[01]+(?:_[01]+)*\b|\b0o[0-7]+(?:_[0-7]+)*\b|\b0x[\da-f]+(?:_[\da-f]+)*\b|(?:\b\d+(?:_\d+)*\.?(?:\d+(?:_\d+)*)?|\B\.\d+)(?:e[+-]?\d+)?/i,o=/<?=>|\?\?=?|\.{3}|\??->|[!=]=?=?|::|\*\*=?|--|\+\+|&&|\|\||<<|>>|[?~]|[/^|%*&<>.+-]=?/,i=/[{}\[\](),:;]/;e.languages.php={delimiter:{pattern:/\?>$|^<\?(?:php(?=\s)|=)?/i,alias:"important"},comment:t,variable:/\$+(?:\w+\b|(?=\{))/,package:{pattern:/(namespace\s+|use\s+(?:function\s+)?)(?:\\?\b[a-z_]\w*)+\b(?!\\)/i,lookbehind:!0,inside:{punctuation:/\\/}},"class-name-definition":{pattern:/(\b(?:class|enum|interface|trait)\s+)\b[a-z_]\w*(?!\\)\b/i,lookbehind:!0,alias:"class-name"},"function-definition":{pattern:/(\bfunction\s+)[a-z_]\w*(?=\s*\()/i,lookbehind:!0,alias:"function"},keyword:[{pattern:/(\(\s*)\b(?:array|bool|boolean|float|int|integer|object|string)\b(?=\s*\))/i,alias:"type-casting",greedy:!0,lookbehind:!0},{pattern:/([(,?]\s*)\b(?:array(?!\s*\()|bool|callable|(?:false|null)(?=\s*\|)|float|int|iterable|mixed|object|self|static|string)\b(?=\s*\$)/i,alias:"type-hint",greedy:!0,lookbehind:!0},{pattern:/(\)\s*:\s*(?:\?\s*)?)\b(?:array(?!\s*\()|bool|callable|(?:false|null)(?=\s*\|)|float|int|iterable|mixed|never|object|self|static|string|void)\b/i,alias:"return-type",greedy:!0,lookbehind:!0},{pattern:/\b(?:array(?!\s*\()|bool|float|int|iterable|mixed|object|string|void)\b/i,alias:"type-declaration",greedy:!0},{pattern:/(\|\s*)(?:false|null)\b|\b(?:false|null)(?=\s*\|)/i,alias:"type-declaration",greedy:!0,lookbehind:!0},{pattern:/\b(?:parent|self|static)(?=\s*::)/i,alias:"static-context",greedy:!0},{pattern:/(\byield\s+)from\b/i,lookbehind:!0},/\bclass\b/i,{pattern:/((?:^|[^\s>:]|(?:^|[^-])>|(?:^|[^:]):)\s*)\b(?:abstract|and|array|as|break|callable|case|catch|clone|const|continue|declare|default|die|do|echo|else|elseif|empty|enddeclare|endfor|endforeach|endif|endswitch|endwhile|enum|eval|exit|extends|final|finally|fn|for|foreach|function|global|goto|if|implements|include|include_once|instanceof|insteadof|interface|isset|list|match|namespace|never|new|or|parent|print|private|protected|public|readonly|require|require_once|return|self|static|switch|throw|trait|try|unset|use|var|while|xor|yield|__halt_compiler)\b/i,lookbehind:!0}],"argument-name":{pattern:/([(,]\s*)\b[a-z_]\w*(?=\s*:(?!:))/i,lookbehind:!0},"class-name":[{pattern:/(\b(?:extends|implements|instanceof|new(?!\s+self|\s+static))\s+|\bcatch\s*\()\b[a-z_]\w*(?!\\)\b/i,greedy:!0,lookbehind:!0},{pattern:/(\|\s*)\b[a-z_]\w*(?!\\)\b/i,greedy:!0,lookbehind:!0},{pattern:/\b[a-z_]\w*(?!\\)\b(?=\s*\|)/i,greedy:!0},{pattern:/(\|\s*)(?:\\?\b[a-z_]\w*)+\b/i,alias:"class-name-fully-qualified",greedy:!0,lookbehind:!0,inside:{punctuation:/\\/}},{pattern:/(?:\\?\b[a-z_]\w*)+\b(?=\s*\|)/i,alias:"class-name-fully-qualified",greedy:!0,inside:{punctuation:/\\/}},{pattern:/(\b(?:extends|implements|instanceof|new(?!\s+self\b|\s+static\b))\s+|\bcatch\s*\()(?:\\?\b[a-z_]\w*)+\b(?!\\)/i,alias:"class-name-fully-qualified",greedy:!0,lookbehind:!0,inside:{punctuation:/\\/}},{pattern:/\b[a-z_]\w*(?=\s*\$)/i,alias:"type-declaration",greedy:!0},{pattern:/(?:\\?\b[a-z_]\w*)+(?=\s*\$)/i,alias:["class-name-fully-qualified","type-declaration"],greedy:!0,inside:{punctuation:/\\/}},{pattern:/\b[a-z_]\w*(?=\s*::)/i,alias:"static-context",greedy:!0},{pattern:/(?:\\?\b[a-z_]\w*)+(?=\s*::)/i,alias:["class-name-fully-qualified","static-context"],greedy:!0,inside:{punctuation:/\\/}},{pattern:/([(,?]\s*)[a-z_]\w*(?=\s*\$)/i,alias:"type-hint",greedy:!0,lookbehind:!0},{pattern:/([(,?]\s*)(?:\\?\b[a-z_]\w*)+(?=\s*\$)/i,alias:["class-name-fully-qualified","type-hint"],greedy:!0,lookbehind:!0,inside:{punctuation:/\\/}},{pattern:/(\)\s*:\s*(?:\?\s*)?)\b[a-z_]\w*(?!\\)\b/i,alias:"return-type",greedy:!0,lookbehind:!0},{pattern:/(\)\s*:\s*(?:\?\s*)?)(?:\\?\b[a-z_]\w*)+\b(?!\\)/i,alias:["class-name-fully-qualified","return-type"],greedy:!0,lookbehind:!0,inside:{punctuation:/\\/}}],constant:n,function:{pattern:/(^|[^\\\w])\\?[a-z_](?:[\w\\]*\w)?(?=\s*\()/i,lookbehind:!0,inside:{punctuation:/\\/}},property:{pattern:/(->\s*)\w+/,lookbehind:!0},number:r,operator:o,punctuation:i};var a={pattern:/\{\$(?:\{(?:\{[^{}]+\}|[^{}]+)\}|[^{}])+\}|(^|[^\\{])\$+(?:\w+(?:\[[^\r\n\[\]]+\]|->\w+)?)/,lookbehind:!0,inside:e.languages.php},s=[{pattern:/<<<'([^']+)'[\r\n](?:.*[\r\n])*?\1;/,alias:"nowdoc-string",greedy:!0,inside:{delimiter:{pattern:/^<<<'[^']+'|[a-z_]\w*;$/i,alias:"symbol",inside:{punctuation:/^<<<'?|[';]$/}}}},{pattern:/<<<(?:"([^"]+)"[\r\n](?:.*[\r\n])*?\1;|([a-z_]\w*)[\r\n](?:.*[\r\n])*?\2;)/i,alias:"heredoc-string",greedy:!0,inside:{delimiter:{pattern:/^<<<(?:"[^"]+"|[a-z_]\w*)|[a-z_]\w*;$/i,alias:"symbol",inside:{punctuation:/^<<<"?|[";]$/}},interpolation:a}},{pattern:/`(?:\\[\s\S]|[^\\`])*`/,alias:"backtick-quoted-string",greedy:!0},{pattern:/'(?:\\[\s\S]|[^\\'])*'/,alias:"single-quoted-string",greedy:!0},{pattern:/"(?:\\[\s\S]|[^\\"])*"/,alias:"double-quoted-string",greedy:!0,inside:{interpolation:a}}];e.languages.insertBefore("php","variable",{string:s,attribute:{pattern:/#\[(?:[^"'\/#]|\/(?![*/])|\/\/.*$|#(?!\[).*$|\/\*(?:[^*]|\*(?!\/))*\*\/|"(?:\\[\s\S]|[^\\"])*"|'(?:\\[\s\S]|[^\\'])*')+\](?=\s*[a-z$#])/im,greedy:!0,inside:{"attribute-content":{pattern:/^(#\[)[\s\S]+(?=\]$)/,lookbehind:!0,inside:{comment:t,string:s,"attribute-class-name":[{pattern:/([^:]|^)\b[a-z_]\w*(?!\\)\b/i,alias:"class-name",greedy:!0,lookbehind:!0},{pattern:/([^:]|^)(?:\\?\b[a-z_]\w*)+/i,alias:["class-name","class-name-fully-qualified"],greedy:!0,lookbehind:!0,inside:{punctuation:/\\/}}],constant:n,number:r,operator:o,punctuation:i}},delimiter:{pattern:/^#\[|\]$/,alias:"punctuation"}}}}),e.hooks.add("before-tokenize",function(t){/<\?/.test(t.code)&&e.languages["markup-templating"].buildPlaceholders(t,"php",/<\?(?:[^"'/#]|\/(?![*/])|("|')(?:\\[\s\S]|(?!\1)[^\\])*\1|(?:\/\/|#(?!\[))(?:[^?\n\r]|\?(?!>))*(?=$|\?>|[\r\n])|#\[|\/\*(?:[^*]|\*(?!\/))*(?:\*\/|$))*?(?:\?>|$)/g)}),e.hooks.add("after-tokenize",function(t){e.languages["markup-templating"].tokenizePlaceholders(t,"php")})}(Prism)),Prism.languages.c=Prism.languages.extend("clike",{comment:{pattern:/\/\/(?:[^\r\n\\]|\\(?:\r\n?|\n|(?![\r\n])))*|\/\*[\s\S]*?(?:\*\/|$)/,greedy:!0},string:{pattern:/"(?:\\(?:\r\n|[\s\S])|[^"\\\r\n])*"/,greedy:!0},"class-name":{pattern:/(\b(?:enum|struct)\s+(?:__attribute__\s*\(\([\s\S]*?\)\)\s*)?)\w+|\b[a-z]\w*_t\b/,lookbehind:!0},keyword:/\b(?:_Alignas|_Alignof|_Atomic|_Bool|_Complex|_Generic|_Imaginary|_Noreturn|_Static_assert|_Thread_local|__attribute__|asm|auto|break|case|char|const|continue|default|do|double|else|enum|extern|float|for|goto|if|inline|int|long|register|return|short|signed|sizeof|static|struct|switch|typedef|typeof|union|unsigned|void|volatile|while)\b/,function:/\b[a-z_]\w*(?=\s*\()/i,number:/(?:\b0x(?:[\da-f]+(?:\.[\da-f]*)?|\.[\da-f]+)(?:p[+-]?\d+)?|(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:e[+-]?\d+)?)[ful]{0,4}/i,operator:/>>=?|<<=?|->|([-+&|:])\1|[?:~]|[-+*/%&|^!=<>]=?/}),Prism.languages.insertBefore("c","string",{char:{pattern:/'(?:\\(?:\r\n|[\s\S])|[^'\\\r\n]){0,32}'/,greedy:!0}}),Prism.languages.insertBefore("c","string",{macro:{pattern:/(^[\t ]*)#\s*[a-z](?:[^\r\n\\/]|\/(?!\*)|\/\*(?:[^*]|\*(?!\/))*\*\/|\\(?:\r\n|[\s\S]))*/im,lookbehind:!0,greedy:!0,alias:"property",inside:{string:[{pattern:/^(#\s*include\s*)<[^>]+>/,lookbehind:!0},Prism.languages.c.string],char:Prism.languages.c.char,comment:Prism.languages.c.comment,"macro-name":[{pattern:/(^#\s*define\s+)\w+\b(?!\()/i,lookbehind:!0},{pattern:/(^#\s*define\s+)\w+\b(?=\()/i,lookbehind:!0,alias:"function"}],directive:{pattern:/^(#\s*)[a-z]+/,lookbehind:!0,alias:"keyword"},"directive-hash":/^#/,punctuation:/##|\\(?=[\r\n])/,expression:{pattern:/\S[\s\S]*/,inside:Prism.languages.c}}}}),Prism.languages.insertBefore("c","function",{constant:/\b(?:EOF|NULL|SEEK_CUR|SEEK_END|SEEK_SET|__DATE__|__FILE__|__LINE__|__TIMESTAMP__|__TIME__|__func__|stderr|stdin|stdout)\b/}),delete Prism.languages.c.boolean;var wB;wB||(wB=1,Prism.languages.python={comment:{pattern:/(^|[^\\])#.*/,lookbehind:!0,greedy:!0},"string-interpolation":{pattern:/(?:f|fr|rf)(?:("""|''')[\s\S]*?\1|("|')(?:\\.|(?!\2)[^\\\r\n])*\2)/i,greedy:!0,inside:{interpolation:{pattern:/((?:^|[^{])(?:\{\{)*)\{(?!\{)(?:[^{}]|\{(?!\{)(?:[^{}]|\{(?!\{)(?:[^{}])+\})+\})+\}/,lookbehind:!0,inside:{"format-spec":{pattern:/(:)[^:(){}]+(?=\}$)/,lookbehind:!0},"conversion-option":{pattern://,alias:"punctuation"},rest:null}},string:/[\s\S]+/}},"triple-quoted-string":{pattern:/(?:[rub]|br|rb)?("""|''')[\s\S]*?\1/i,greedy:!0,alias:"string"},string:{pattern:/(?:[rub]|br|rb)?("|')(?:\\.|(?!\1)[^\\\r\n])*\1/i,greedy:!0},function:{pattern:/((?:^|\s)def[ \t]+)[a-zA-Z_]\w*(?=\s*\()/g,lookbehind:!0},"class-name":{pattern:/(\bclass\s+)\w+/i,lookbehind:!0},decorator:{pattern:/(^[\t ]*)@\w+(?:\.\w+)*/m,lookbehind:!0,alias:["annotation","punctuation"],inside:{punctuation:/\./}},keyword:/\b(?:_(?=\s*:)|and|as|assert|async|await|break|case|class|continue|def|del|elif|else|except|exec|finally|for|from|global|if|import|in|is|lambda|match|nonlocal|not|or|pass|print|raise|return|try|while|with|yield)\b/,builtin:/\b(?:__import__|abs|all|any|apply|ascii|basestring|bin|bool|buffer|bytearray|bytes|callable|chr|classmethod|cmp|coerce|compile|complex|delattr|dict|dir|divmod|enumerate|eval|execfile|file|filter|float|format|frozenset|getattr|globals|hasattr|hash|help|hex|id|input|int|intern|isinstance|issubclass|iter|len|list|locals|long|map|max|memoryview|min|next|object|oct|open|ord|pow|property|range|raw_input|reduce|reload|repr|reversed|round|set|setattr|slice|sorted|staticmethod|str|sum|super|tuple|type|unichr|unicode|vars|xrange|zip)\b/,boolean:/\b(?:False|None|True)\b/,number:/\b0(?:b(?:_?[01])+|o(?:_?[0-7])+|x(?:_?[a-f0-9])+)\b|(?:\b\d+(?:_\d+)*(?:\.(?:\d+(?:_\d+)*)?)?|\B\.\d+(?:_\d+)*)(?:e[+-]?\d+(?:_\d+)*)?j?(?!\w)/i,operator:/[-+%=]=?|!=|:=|\*\*?=?|\/\/?=?|<[<=>]?|>[=>]?|[&|^~]/,punctuation:/[{}[\];(),.:]/},Prism.languages.python["string-interpolation"].inside.interpolation.inside.rest=Prism.languages.python,Prism.languages.py=Prism.languages.python);var SB;SB||(SB=1,function(e){var t=/\b(?:abstract|assert|boolean|break|byte|case|catch|char|class|const|continue|default|do|double|else|enum|exports|extends|final|finally|float|for|goto|if|implements|import|instanceof|int|interface|long|module|native|new|non-sealed|null|open|opens|package|permits|private|protected|provides|public|record(?!\s*[(){}[\]<>=%~.:,;?+\-*/&|^])|requires|return|sealed|short|static|strictfp|super|switch|synchronized|this|throw|throws|to|transient|transitive|try|uses|var|void|volatile|while|with|yield)\b/,n=/(?:[a-z]\w*\s*\.\s*)*(?:[A-Z]\w*\s*\.\s*)*/.source,r={pattern:RegExp(/(^|[^\w.])/.source+n+/[A-Z](?:[\d_A-Z]*[a-z]\w*)?\b/.source),lookbehind:!0,inside:{namespace:{pattern:/^[a-z]\w*(?:\s*\.\s*[a-z]\w*)*(?:\s*\.)?/,inside:{punctuation:/\./}},punctuation:/\./}};e.languages.java=e.languages.extend("clike",{string:{pattern:/(^|[^\\])"(?:\\.|[^"\\\r\n])*"/,lookbehind:!0,greedy:!0},"class-name":[r,{pattern:RegExp(/(^|[^\w.])/.source+n+/[A-Z]\w*(?=\s+\w+\s*[;,=()]|\s*(?:\[[\s,]*\]\s*)?::\s*new\b)/.source),lookbehind:!0,inside:r.inside},{pattern:RegExp(/(\b(?:class|enum|extends|implements|instanceof|interface|new|record|throws)\s+)/.source+n+/[A-Z]\w*\b/.source),lookbehind:!0,inside:r.inside}],keyword:t,function:[e.languages.clike.function,{pattern:/(::\s*)[a-z_]\w*/,lookbehind:!0}],number:/\b0b[01][01_]*L?\b|\b0x(?:\.[\da-f_p+-]+|[\da-f_]+(?:\.[\da-f_p+-]+)?)\b|(?:\b\d[\d_]*(?:\.[\d_]*)?|\B\.\d[\d_]*)(?:e[+-]?\d[\d_]*)?[dfl]?/i,operator:{pattern:/(^|[^.])(?:<<=?|>>>?=?|->|--|\+\+|&&|\|\||::|[?:~]|[-+*/%&|^!=<>]=?)/m,lookbehind:!0},constant:/\b[A-Z][A-Z_\d]+\b/}),e.languages.insertBefore("java","string",{"triple-quoted-string":{pattern:/"""[ \t]*[\r\n](?:(?:"|"")?(?:\\.|[^"\\]))*"""/,greedy:!0,alias:"string"},char:{pattern:/'(?:\\.|[^'\\\r\n]){1,6}'/,greedy:!0}}),e.languages.insertBefore("java","class-name",{annotation:{pattern:/(^|[^.])@\w+(?:\s*\.\s*\w+)*/,lookbehind:!0,alias:"punctuation"},generics:{pattern:/<(?:[\w\s,.?]|&(?!&)|<(?:[\w\s,.?]|&(?!&)|<(?:[\w\s,.?]|&(?!&)|<(?:[\w\s,.?]|&(?!&))*>)*>)*>)*>/,inside:{"class-name":r,keyword:t,punctuation:/[<>(),.:]/,operator:/[?&|]/}},import:[{pattern:RegExp(/(\bimport\s+)/.source+n+/(?:[A-Z]\w*|\*)(?=\s*;)/.source),lookbehind:!0,inside:{namespace:r.inside.namespace,punctuation:/\./,operator:/\*/,"class-name":/\w+/}},{pattern:RegExp(/(\bimport\s+static\s+)/.source+n+/(?:\w+|\*)(?=\s*;)/.source),lookbehind:!0,alias:"static",inside:{namespace:r.inside.namespace,static:/\b\w+$/,punctuation:/\./,operator:/\*/,"class-name":/\w+/}}],namespace:{pattern:RegExp(/(\b(?:exports|import(?:\s+static)?|module|open|opens|package|provides|requires|to|transitive|uses|with)\s+)(?!<keyword>)[a-z]\w*(?:\.[a-z]\w*)*\.?/.source.replace(/<keyword>/g,function(){return t.source})),lookbehind:!0,inside:{punctuation:/\./}}})}(Prism));var AB;AB||(AB=1,function(e){var t=/\b(?:alignas|alignof|asm|auto|bool|break|case|catch|char|char16_t|char32_t|char8_t|class|co_await|co_return|co_yield|compl|concept|const|const_cast|consteval|constexpr|constinit|continue|decltype|default|delete|do|double|dynamic_cast|else|enum|explicit|export|extern|final|float|for|friend|goto|if|import|inline|int|int16_t|int32_t|int64_t|int8_t|long|module|mutable|namespace|new|noexcept|nullptr|operator|override|private|protected|public|register|reinterpret_cast|requires|return|short|signed|sizeof|static|static_assert|static_cast|struct|switch|template|this|thread_local|throw|try|typedef|typeid|typename|uint16_t|uint32_t|uint64_t|uint8_t|union|unsigned|using|virtual|void|volatile|wchar_t|while)\b/,n=/\b(?!<keyword>)\w+(?:\s*\.\s*\w+)*\b/.source.replace(/<keyword>/g,function(){return t.source});e.languages.cpp=e.languages.extend("c",{"class-name":[{pattern:RegExp(/(\b(?:class|concept|enum|struct|typename)\s+)(?!<keyword>)\w+/.source.replace(/<keyword>/g,function(){return t.source})),lookbehind:!0},/\b[A-Z]\w*(?=\s*::\s*\w+\s*\()/,/\b[A-Z_]\w*(?=\s*::\s*~\w+\s*\()/i,/\b\w+(?=\s*<(?:[^<>]|<(?:[^<>]|<[^<>]*>)*>)*>\s*::\s*\w+\s*\()/],keyword:t,number:{pattern:/(?:\b0b[01']+|\b0x(?:[\da-f']+(?:\.[\da-f']*)?|\.[\da-f']+)(?:p[+-]?[\d']+)?|(?:\b[\d']+(?:\.[\d']*)?|\B\.[\d']+)(?:e[+-]?[\d']+)?)[ful]{0,4}/i,greedy:!0},operator:/>>=?|<<=?|->|--|\+\+|&&|\|\||[?:~]|<=>|[-+*/%&|^!=<>]=?|\b(?:and|and_eq|bitand|bitor|not|not_eq|or|or_eq|xor|xor_eq)\b/,boolean:/\b(?:false|true)\b/}),e.languages.insertBefore("cpp","string",{module:{pattern:RegExp(/(\b(?:import|module)\s+)/.source+"(?:"+/"(?:\\(?:\r\n|[\s\S])|[^"\\\r\n])*"|<[^<>\r\n]*>/.source+"|"+/<mod-name>(?:\s*:\s*<mod-name>)?|:\s*<mod-name>/.source.replace(/<mod-name>/g,function(){return n})+")"),lookbehind:!0,greedy:!0,inside:{string:/^[<"][\s\S]+/,operator:/:/,punctuation:/\./}},"raw-string":{pattern:/R"([^()\\ ]{0,16})\([\s\S]*?\)\1"/,alias:"string",greedy:!0}}),e.languages.insertBefore("cpp","keyword",{"generic-function":{pattern:/\b(?!operator\b)[a-z_]\w*\s*<(?:[^<>]|<[^<>]*>)*>(?=\s*\()/i,inside:{function:/^\w+/,generic:{pattern:/<[\s\S]+/,alias:"class-name",inside:e.languages.cpp}}}}),e.languages.insertBefore("cpp","operator",{"double-colon":{pattern:/::/,alias:"punctuation"}}),e.languages.insertBefore("cpp","class-name",{"base-clause":{pattern:/(\b(?:class|struct)\s+\w+\s*:\s*)[^;{}"'\s]+(?:\s+[^;{}"'\s]+)*(?=\s*[;{])/,lookbehind:!0,greedy:!0,inside:e.languages.extend("cpp",{})}}),e.languages.insertBefore("inside","double-colon",{"class-name":/\b[a-z_]\w*\b(?!\s*::)/i},e.languages.cpp["base-clause"])}(Prism));var xB;xB||(xB=1,function(e){function t(e,t){return e.replace(/<<(\d+)>>/g,function(e,n){return"(?:"+t[+n]+")"})}function n(e,n,r){return RegExp(t(e,n),"")}function r(e,t){for(var n=0;n<t;n++)e=e.replace(/<<self>>/g,function(){return"(?:"+e+")"});return e.replace(/<<self>>/g,"[^\\s\\S]")}var o="bool byte char decimal double dynamic float int long object sbyte short string uint ulong ushort var void",i="class enum interface record struct",a="add alias and ascending async await by descending from(?=\\s*(?:\\w|$)) get global group into init(?=\\s*;) join let nameof not notnull on or orderby partial remove select set unmanaged value when where with(?=\\s*{)",s="abstract as base break case catch checked const continue default delegate do else event explicit extern finally fixed for foreach goto if implicit in internal is lock namespace new null operator out override params private protected public readonly ref return sealed sizeof stackalloc static switch this throw try typeof unchecked unsafe using virtual volatile while yield";function u(e){return"\\b(?:"+e.trim().replace(/ /g,"|")+")\\b"}var l=u(i),c=RegExp(u(o+" "+i+" "+a+" "+s)),d=u(i+" "+a+" "+s),f=u(o+" "+i+" "+s),p=r(/<(?:[^<>;=+\-*/%&|^]|<<self>>)*>/.source,2),h=r(/\((?:[^()]|<<self>>)*\)/.source,2),g=/@?\b[A-Za-z_]\w*\b/.source,v=t(/<<0>>(?:\s*<<1>>)?/.source,[g,p]),m=t(/(?!<<0>>)<<1>>(?:\s*\.\s*<<1>>)*/.source,[d,v]),y=/\[\s*(?:,\s*)*\]/.source,b=t(/<<0>>(?:\s*(?:\?\s*)?<<1>>)*(?:\s*\?)?/.source,[m,y]),E=t(/[^,()<>[\];=+\-*/%&|^]|<<0>>|<<1>>|<<2>>/.source,[p,h,y]),C=t(/\(<<0>>+(?:,<<0>>+)+\)/.source,[E]),D=t(/(?:<<0>>|<<1>>)(?:\s*(?:\?\s*)?<<2>>)*(?:\s*\?)?/.source,[C,m,y]),w={keyword:c,punctuation:/[<>()?,.:[\]]/},S=/'(?:[^\r\n'\\]|\\.|\\[Uux][\da-fA-F]{1,8})'/.source,A=/"(?:\\.|[^\\"\r\n])*"/.source,x=/@"(?:""|\\[\s\S]|[^\\"])*"(?!")/.source;e.languages.csharp=e.languages.extend("clike",{string:[{pattern:n(/(^|[^$\\])<<0>>/.source,[x]),lookbehind:!0,greedy:!0},{pattern:n(/(^|[^@$\\])<<0>>/.source,[A]),lookbehind:!0,greedy:!0}],"class-name":[{pattern:n(/(\busing\s+static\s+)<<0>>(?=\s*;)/.source,[m]),lookbehind:!0,inside:w},{pattern:n(/(\busing\s+<<0>>\s*=\s*)<<1>>(?=\s*;)/.source,[g,D]),lookbehind:!0,inside:w},{pattern:n(/(\busing\s+)<<0>>(?=\s*=)/.source,[g]),lookbehind:!0},{pattern:n(/(\b<<0>>\s+)<<1>>/.source,[l,v]),lookbehind:!0,inside:w},{pattern:n(/(\bcatch\s*\(\s*)<<0>>/.source,[m]),lookbehind:!0,inside:w},{pattern:n(/(\bwhere\s+)<<0>>/.source,[g]),lookbehind:!0},{pattern:n(/(\b(?:is(?:\s+not)?|as)\s+)<<0>>/.source,[b]),lookbehind:!0,inside:w},{pattern:n(/\b<<0>>(?=\s+(?!<<1>>|with\s*\{)<<2>>(?:\s*[=,;:{)\]]|\s+(?:in|when)\b))/.source,[D,f,g]),inside:w}],keyword:c,number:/(?:\b0(?:x[\da-f_]*[\da-f]|b[01_]*[01])|(?:\B\.\d+(?:_+\d+)*|\b\d+(?:_+\d+)*(?:\.\d+(?:_+\d+)*)?)(?:e[-+]?\d+(?:_+\d+)*)?)(?:[dflmu]|lu|ul)?\b/i,operator:/>>=?|<<=?|[-=]>|([-+&|])\1|~|\?\?=?|[-+*/%&|^!=<>]=?/,punctuation:/\?\.?|::|[{}[\];(),.:]/}),e.languages.insertBefore("csharp","number",{range:{pattern:/\.\./,alias:"operator"}}),e.languages.insertBefore("csharp","punctuation",{"named-parameter":{pattern:n(/([(,]\s*)<<0>>(?=\s*:)/.source,[g]),lookbehind:!0,alias:"punctuation"}}),e.languages.insertBefore("csharp","class-name",{namespace:{pattern:n(/(\b(?:namespace|using)\s+)<<0>>(?:\s*\.\s*<<0>>)*(?=\s*[;{])/.source,[g]),lookbehind:!0,inside:{punctuation:/\./}},"type-expression":{pattern:n(/(\b(?:default|sizeof|typeof)\s*\(\s*(?!\s))(?:[^()\s]|\s(?!\s)|<<0>>)*(?=\s*\))/.source,[h]),lookbehind:!0,alias:"class-name",inside:w},"return-type":{pattern:n(/<<0>>(?=\s+(?:<<1>>\s*(?:=>|[({]|\.\s*this\s*\[)|this\s*\[))/.source,[D,m]),inside:w,alias:"class-name"},"constructor-invocation":{pattern:n(/(\bnew\s+)<<0>>(?=\s*[[({])/.source,[D]),lookbehind:!0,inside:w,alias:"class-name"},"generic-method":{pattern:n(/<<0>>\s*<<1>>(?=\s*\()/.source,[g,p]),inside:{function:n(/^<<0>>/.source,[g]),generic:{pattern:RegExp(p),alias:"class-name",inside:w}}},"type-list":{pattern:n(/\b((?:<<0>>\s+<<1>>|record\s+<<1>>\s*<<5>>|where\s+<<2>>)\s*:\s*)(?:<<3>>|<<4>>|<<1>>\s*<<5>>|<<6>>)(?:\s*,\s*(?:<<3>>|<<4>>|<<6>>))*(?=\s*(?:where|[{;]|=>|$))/.source,[l,v,g,D,c.source,h,/\bnew\s*\(\s*\)/.source]),lookbehind:!0,inside:{"record-arguments":{pattern:n(/(^(?!new\s*\()<<0>>\s*)<<1>>/.source,[v,h]),lookbehind:!0,greedy:!0,inside:e.languages.csharp},keyword:c,"class-name":{pattern:RegExp(D),greedy:!0,inside:w},punctuation:/[,()]/}},preprocessor:{pattern:/(^[\t ]*)#.*/m,lookbehind:!0,alias:"property",inside:{directive:{pattern:/(#)\b(?:define|elif|else|endif|endregion|error|if|line|nullable|pragma|region|undef|warning)\b/,lookbehind:!0,alias:"keyword"}}}});var O=A+"|"+S,N=t(/\/(?![*/])|\/\/[^\r\n]*[\r\n]|\/\*(?:[^*]|\*(?!\/))*\*\/|<<0>>/.source,[O]),B=r(t(/[^"'/()]|<<0>>|\(<<self>>*\)/.source,[N]),2),T=/\b(?:assembly|event|field|method|module|param|property|return|type)\b/.source,k=t(/<<0>>(?:\s*\(<<1>>*\))?/.source,[m,B]);e.languages.insertBefore("csharp","class-name",{attribute:{pattern:n(/((?:^|[^\s\w>)?])\s*\[\s*)(?:<<0>>\s*:\s*)?<<1>>(?:\s*,\s*<<1>>)*(?=\s*\])/.source,[T,k]),lookbehind:!0,greedy:!0,inside:{target:{pattern:n(/^<<0>>(?=\s*:)/.source,[T]),alias:"keyword"},"attribute-arguments":{pattern:n(/\(<<0>>*\)/.source,[B]),inside:e.languages.csharp},"class-name":{pattern:RegExp(m),inside:{punctuation:/\./}},punctuation:/[:,]/}}});var F=/:[^}\r\n]+/.source,I=r(t(/[^"'/()]|<<0>>|\(<<self>>*\)/.source,[N]),2),P=t(/\{(?!\{)(?:(?![}:])<<0>>)*<<1>>?\}/.source,[I,F]),_=r(t(/[^"'/()]|\/(?!\*)|\/\*(?:[^*]|\*(?!\/))*\*\/|<<0>>|\(<<self>>*\)/.source,[O]),2),L=t(/\{(?!\{)(?:(?![}:])<<0>>)*<<1>>?\}/.source,[_,F]);function R(t,r){return{interpolation:{pattern:n(/((?:^|[^{])(?:\{\{)*)<<0>>/.source,[t]),lookbehind:!0,inside:{"format-string":{pattern:n(/(^\{(?:(?![}:])<<0>>)*)<<1>>(?=\}$)/.source,[r,F]),lookbehind:!0,inside:{punctuation:/^:/}},punctuation:/^\{|\}$/,expression:{pattern:/[\s\S]+/,alias:"language-csharp",inside:e.languages.csharp}}},string:/[\s\S]+/}}e.languages.insertBefore("csharp","string",{"interpolation-string":[{pattern:n(/(^|[^\\])(?:\$@|@\$)"(?:""|\\[\s\S]|\{\{|<<0>>|[^\\{"])*"/.source,[P]),lookbehind:!0,greedy:!0,inside:R(P,I)},{pattern:n(/(^|[^@\\])\$"(?:\\.|\{\{|<<0>>|[^\\"{])*"/.source,[L]),lookbehind:!0,greedy:!0,inside:R(L,_)}],char:{pattern:RegExp(S),greedy:!0}}),e.languages.dotnet=e.languages.cs=e.languages.csharp}(Prism)),Prism.languages["visual-basic"]={comment:{pattern:/(?:['‘’]|REM\b)(?:[^\r\n_]|_(?:\r\n?|\n)?)*/i,inside:{keyword:/^REM/i}},directive:{pattern:/#(?:Const|Else|ElseIf|End|ExternalChecksum|ExternalSource|If|Region)(?:\b_[ \t]*(?:\r\n?|\n)|.)+/i,alias:"property",greedy:!0},string:{pattern:/\$?["“”](?:["“”]{2}|[^"“”])*["“”]C?/i,greedy:!0},date:{pattern:/#[ \t]*(?:\d+([/-])\d+\1\d+(?:[ \t]+(?:\d+[ \t]*(?:AM|PM)|\d+:\d+(?::\d+)?(?:[ \t]*(?:AM|PM))?))?|\d+[ \t]*(?:AM|PM)|\d+:\d+(?::\d+)?(?:[ \t]*(?:AM|PM))?)[ \t]*#/i,alias:"number"},number:/(?:(?:\b\d+(?:\.\d+)?|\.\d+)(?:E[+-]?\d+)?|&[HO][\dA-F]+)(?:[FRD]|U?[ILS])?/i,boolean:/\b(?:False|Nothing|True)\b/i,keyword:/\b(?:AddHandler|AddressOf|Alias|And(?:Also)?|As|Boolean|ByRef|Byte|ByVal|Call|Case|Catch|C(?:Bool|Byte|Char|Date|Dbl|Dec|Int|Lng|Obj|SByte|Short|Sng|Str|Type|UInt|ULng|UShort)|Char|Class|Const|Continue|Currency|Date|Decimal|Declare|Default|Delegate|Dim|DirectCast|Do|Double|Each|Else(?:If)?|End(?:If)?|Enum|Erase|Error|Event|Exit|Finally|For|Friend|Function|Get(?:Type|XMLNamespace)?|Global|GoSub|GoTo|Handles|If|Implements|Imports|In|Inherits|Integer|Interface|Is|IsNot|Let|Lib|Like|Long|Loop|Me|Mod|Module|Must(?:Inherit|Override)|My(?:Base|Class)|Namespace|Narrowing|New|Next|Not(?:Inheritable|Overridable)?|Object|Of|On|Operator|Option(?:al)?|Or(?:Else)?|Out|Overloads|Overridable|Overrides|ParamArray|Partial|Private|Property|Protected|Public|RaiseEvent|ReadOnly|ReDim|RemoveHandler|Resume|Return|SByte|Select|Set|Shadows|Shared|short|Single|Static|Step|Stop|String|Structure|Sub|SyncLock|Then|Throw|To|Try|TryCast|Type|TypeOf|U(?:Integer|Long|Short)|Until|Using|Variant|Wend|When|While|Widening|With(?:Events)?|WriteOnly|Xor)\b/i,operator:/[+\-*/\\^<=>&#@$%!]|\b_(?=[ \t]*[\r\n])/,punctuation:/[{}().,:?]/},Prism.languages.vb=Prism.languages["visual-basic"],Prism.languages.vba=Prism.languages["visual-basic"],Prism.languages.sql={comment:{pattern:/(^|[^\\])(?:\/\*[\s\S]*?\*\/|(?:--|\/\/|#).*)/,lookbehind:!0},variable:[{pattern:/@(["'`])(?:\\[\s\S]|(?!\1)[^\\])+\1/,greedy:!0},/@[\w.$]+/],string:{pattern:/(^|[^@\\])("|')(?:\\[\s\S]|(?!\2)[^\\]|\2\2)*\2/,greedy:!0,lookbehind:!0},identifier:{pattern:/(^|[^@\\])`(?:\\[\s\S]|[^`\\]|``)*`/,greedy:!0,lookbehind:!0,inside:{punctuation:/^`|`$/}},function:/\b(?:AVG|COUNT|FIRST|FORMAT|LAST|LCASE|LEN|MAX|MID|MIN|MOD|NOW|ROUND|SUM|UCASE)(?=\s*\()/i,keyword:/\b(?:ACTION|ADD|AFTER|ALGORITHM|ALL|ALTER|ANALYZE|ANY|APPLY|AS|ASC|AUTHORIZATION|AUTO_INCREMENT|BACKUP|BDB|BEGIN|BERKELEYDB|BIGINT|BINARY|BIT|BLOB|BOOL|BOOLEAN|BREAK|BROWSE|BTREE|BULK|BY|CALL|CASCADED?|CASE|CHAIN|CHAR(?:ACTER|SET)?|CHECK(?:POINT)?|CLOSE|CLUSTERED|COALESCE|COLLATE|COLUMNS?|COMMENT|COMMIT(?:TED)?|COMPUTE|CONNECT|CONSISTENT|CONSTRAINT|CONTAINS(?:TABLE)?|CONTINUE|CONVERT|CREATE|CROSS|CURRENT(?:_DATE|_TIME|_TIMESTAMP|_USER)?|CURSOR|CYCLE|DATA(?:BASES?)?|DATE(?:TIME)?|DAY|DBCC|DEALLOCATE|DEC|DECIMAL|DECLARE|DEFAULT|DEFINER|DELAYED|DELETE|DELIMITERS?|DENY|DESC|DESCRIBE|DETERMINISTIC|DISABLE|DISCARD|DISK|DISTINCT|DISTINCTROW|DISTRIBUTED|DO|DOUBLE|DROP|DUMMY|DUMP(?:FILE)?|DUPLICATE|ELSE(?:IF)?|ENABLE|ENCLOSED|END|ENGINE|ENUM|ERRLVL|ERRORS|ESCAPED?|EXCEPT|EXEC(?:UTE)?|EXISTS|EXIT|EXPLAIN|EXTENDED|FETCH|FIELDS|FILE|FILLFACTOR|FIRST|FIXED|FLOAT|FOLLOWING|FOR(?: EACH ROW)?|FORCE|FOREIGN|FREETEXT(?:TABLE)?|FROM|FULL|FUNCTION|GEOMETRY(?:COLLECTION)?|GLOBAL|GOTO|GRANT|GROUP|HANDLER|HASH|HAVING|HOLDLOCK|HOUR|IDENTITY(?:COL|_INSERT)?|IF|IGNORE|IMPORT|INDEX|INFILE|INNER|INNODB|INOUT|INSERT|INT|INTEGER|INTERSECT|INTERVAL|INTO|INVOKER|ISOLATION|ITERATE|JOIN|KEYS?|KILL|LANGUAGE|LAST|LEAVE|LEFT|LEVEL|LIMIT|LINENO|LINES|LINESTRING|LOAD|LOCAL|LOCK|LONG(?:BLOB|TEXT)|LOOP|MATCH(?:ED)?|MEDIUM(?:BLOB|INT|TEXT)|MERGE|MIDDLEINT|MINUTE|MODE|MODIFIES|MODIFY|MONTH|MULTI(?:LINESTRING|POINT|POLYGON)|NATIONAL|NATURAL|NCHAR|NEXT|NO|NONCLUSTERED|NULLIF|NUMERIC|OFF?|OFFSETS?|ON|OPEN(?:DATASOURCE|QUERY|ROWSET)?|OPTIMIZE|OPTION(?:ALLY)?|ORDER|OUT(?:ER|FILE)?|OVER|PARTIAL|PARTITION|PERCENT|PIVOT|PLAN|POINT|POLYGON|PRECEDING|PRECISION|PREPARE|PREV|PRIMARY|PRINT|PRIVILEGES|PROC(?:EDURE)?|PUBLIC|PURGE|QUICK|RAISERROR|READS?|REAL|RECONFIGURE|REFERENCES|RELEASE|RENAME|REPEAT(?:ABLE)?|REPLACE|REPLICATION|REQUIRE|RESIGNAL|RESTORE|RESTRICT|RETURN(?:ING|S)?|REVOKE|RIGHT|ROLLBACK|ROUTINE|ROW(?:COUNT|GUIDCOL|S)?|RTREE|RULE|SAVE(?:POINT)?|SCHEMA|SECOND|SELECT|SERIAL(?:IZABLE)?|SESSION(?:_USER)?|SET(?:USER)?|SHARE|SHOW|SHUTDOWN|SIMPLE|SMALLINT|SNAPSHOT|SOME|SONAME|SQL|START(?:ING)?|STATISTICS|STATUS|STRIPED|SYSTEM_USER|TABLES?|TABLESPACE|TEMP(?:ORARY|TABLE)?|TERMINATED|TEXT(?:SIZE)?|THEN|TIME(?:STAMP)?|TINY(?:BLOB|INT|TEXT)|TOP?|TRAN(?:SACTIONS?)?|TRIGGER|TRUNCATE|TSEQUAL|TYPES?|UNBOUNDED|UNCOMMITTED|UNDEFINED|UNION|UNIQUE|UNLOCK|UNPIVOT|UNSIGNED|UPDATE(?:TEXT)?|USAGE|USE|USER|USING|VALUES?|VAR(?:BINARY|CHAR|CHARACTER|YING)|VIEW|WAITFOR|WARNINGS|WHEN|WHERE|WHILE|WITH(?: ROLLUP|IN)?|WORK|WRITE(?:TEXT)?|YEAR)\b/i,boolean:/\b(?:FALSE|NULL|TRUE)\b/i,number:/\b0x[\da-f]+\b|\b\d+(?:\.\d*)?|\B\.\d+\b/i,operator:/[-+*\/=%^~]|&&?|\|\|?|!=?|<(?:=>?|<|>)?|>[>=]?|\b(?:AND|BETWEEN|DIV|ILIKE|IN|IS|LIKE|NOT|OR|REGEXP|RLIKE|SOUNDS LIKE|XOR)\b/i,punctuation:/[;[\]()`,.]/};var OB;OB||(OB=1,function(e){e.languages.ruby=e.languages.extend("clike",{comment:{pattern:/#.*|^=begin\s[\s\S]*?^=end/m,greedy:!0},"class-name":{pattern:/(\b(?:class|module)\s+|\bcatch\s+\()[\w.\\]+|\b[A-Z_]\w*(?=\s*\.\s*new\b)/,lookbehind:!0,inside:{punctuation:/[.\\]/}},keyword:/\b(?:BEGIN|END|alias|and|begin|break|case|class|def|define_method|defined|do|each|else|elsif|end|ensure|extend|for|if|in|include|module|new|next|nil|not|or|prepend|private|protected|public|raise|redo|require|rescue|retry|return|self|super|then|throw|undef|unless|until|when|while|yield)\b/,operator:/\.{2,3}|&\.|===|<?=>|[!=]?~|(?:&&|\|\||<<|>>|\*\*|[+\-*/%<>!^&|=])=?|[?:]/,punctuation:/[(){}[\].,;]/}),e.languages.insertBefore("ruby","operator",{"double-colon":{pattern:/::/,alias:"punctuation"}});var t={pattern:/((?:^|[^\\])(?:\\{2})*)#\{(?:[^{}]|\{[^{}]*\})*\}/,lookbehind:!0,inside:{content:{pattern:/^(#\{)[\s\S]+(?=\}$)/,lookbehind:!0,inside:e.languages.ruby},delimiter:{pattern:/^#\{|\}$/,alias:"punctuation"}}};delete e.languages.ruby.function;var n="(?:"+[/([^a-zA-Z0-9\s{(\[<=])(?:(?!\1)[^\\]|\\[\s\S])*\1/.source,/\((?:[^()\\]|\\[\s\S]|\((?:[^()\\]|\\[\s\S])*\))*\)/.source,/\{(?:[^{}\\]|\\[\s\S]|\{(?:[^{}\\]|\\[\s\S])*\})*\}/.source,/\[(?:[^\[\]\\]|\\[\s\S]|\[(?:[^\[\]\\]|\\[\s\S])*\])*\]/.source,/<(?:[^<>\\]|\\[\s\S]|<(?:[^<>\\]|\\[\s\S])*>)*>/.source].join("|")+")",r=/(?:"(?:\\.|[^"\\\r\n])*"|(?:\b[a-zA-Z_]\w*|[^\s\0-\x7F]+)[?!]?|\$.)/.source;e.languages.insertBefore("ruby","keyword",{"regex-literal":[{pattern:RegExp(/%r/.source+n+/[egimnosux]{0,6}/.source),greedy:!0,inside:{interpolation:t,regex:/[\s\S]+/}},{pattern:/(^|[^/])\/(?!\/)(?:\[[^\r\n\]]+\]|\\.|[^[/\\\r\n])+\/[egimnosux]{0,6}(?=\s*(?:$|[\r\n,.;})#]))/,lookbehind:!0,greedy:!0,inside:{interpolation:t,regex:/[\s\S]+/}}],variable:/[@$]+[a-zA-Z_]\w*(?:[?!]|\b)/,symbol:[{pattern:RegExp(/(^|[^:]):/.source+r),lookbehind:!0,greedy:!0},{pattern:RegExp(/([\r\n{(,][ \t]*)/.source+r+/(?=:(?!:))/.source),lookbehind:!0,greedy:!0}],"method-definition":{pattern:/(\bdef\s+)\w+(?:\s*\.\s*\w+)?/,lookbehind:!0,inside:{function:/\b\w+$/,keyword:/^self\b/,"class-name":/^\w+/,punctuation:/\./}}}),e.languages.insertBefore("ruby","string",{"string-literal":[{pattern:RegExp(/%[qQiIwWs]?/.source+n),greedy:!0,inside:{interpolation:t,string:/[\s\S]+/}},{pattern:/("|')(?:#\{[^}]+\}|#(?!\{)|\\(?:\r\n|[\s\S])|(?!\1)[^\\#\r\n])*\1/,greedy:!0,inside:{interpolation:t,string:/[\s\S]+/}},{pattern:/<<[-~]?([a-z_]\w*)[\r\n](?:.*[\r\n])*?[\t ]*\1/i,alias:"heredoc-string",greedy:!0,inside:{delimiter:{pattern:/^<<[-~]?[a-z_]\w*|\b[a-z_]\w*$/i,inside:{symbol:/\b\w+/,punctuation:/^<<[-~]?/}},interpolation:t,string:/[\s\S]+/}},{pattern:/<<[-~]?'([a-z_]\w*)'[\r\n](?:.*[\r\n])*?[\t ]*\1/i,alias:"heredoc-string",greedy:!0,inside:{delimiter:{pattern:/^<<[-~]?'[a-z_]\w*'|\b[a-z_]\w*$/i,inside:{symbol:/\b\w+/,punctuation:/^<<[-~]?'|'$/}},string:/[\s\S]+/}}],"command-literal":[{pattern:RegExp(/%x/.source+n),greedy:!0,inside:{interpolation:t,command:{pattern:/[\s\S]+/,alias:"string"}}},{pattern:/`(?:#\{[^}]+\}|#(?!\{)|\\(?:\r\n|[\s\S])|[^\\`#\r\n])*`/,greedy:!0,inside:{interpolation:t,command:{pattern:/[\s\S]+/,alias:"string"}}}]}),delete e.languages.ruby.string,e.languages.insertBefore("ruby","number",{builtin:/\b(?:Array|Bignum|Binding|Class|Continuation|Dir|Exception|FalseClass|File|Fixnum|Float|Hash|IO|Integer|MatchData|Method|Module|NilClass|Numeric|Object|Proc|Range|Regexp|Stat|String|Struct|Symbol|TMS|Thread|ThreadGroup|Time|TrueClass)\b/,constant:/\b[A-Z][A-Z0-9_]*(?:[?!]|\b)/}),e.languages.rb=e.languages.ruby}(Prism)),Prism.languages.swift={comment:{pattern:/(^|[^\\:])(?:\/\/.*|\/\*(?:[^/*]|\/(?!\*)|\*(?!\/)|\/\*(?:[^*]|\*(?!\/))*\*\/)*\*\/)/,lookbehind:!0,greedy:!0},"string-literal":[{pattern:RegExp(/(^|[^"#])/.source+"(?:"+/"(?:\\(?:\((?:[^()]|\([^()]*\))*\)|\r\n|[^(])|[^\\\r\n"])*"/.source+"|"+/"""(?:\\(?:\((?:[^()]|\([^()]*\))*\)|[^(])|[^\\"]|"(?!""))*"""/.source+")"+/(?!["#])/.source),lookbehind:!0,greedy:!0,inside:{interpolation:{pattern:/(\\\()(?:[^()]|\([^()]*\))*(?=\))/,lookbehind:!0,inside:null},"interpolation-punctuation":{pattern:/^\)|\\\($/,alias:"punctuation"},punctuation:/\\(?=[\r\n])/,string:/[\s\S]+/}},{pattern:RegExp(/(^|[^"#])(#+)/.source+"(?:"+/"(?:\\(?:#+\((?:[^()]|\([^()]*\))*\)|\r\n|[^#])|[^\\\r\n])*?"/.source+"|"+/"""(?:\\(?:#+\((?:[^()]|\([^()]*\))*\)|[^#])|[^\\])*?"""/.source+")\\2"),lookbehind:!0,greedy:!0,inside:{interpolation:{pattern:/(\\#+\()(?:[^()]|\([^()]*\))*(?=\))/,lookbehind:!0,inside:null},"interpolation-punctuation":{pattern:/^\)|\\#+\($/,alias:"punctuation"},string:/[\s\S]+/}}],directive:{pattern:RegExp(/#/.source+"(?:"+/(?:elseif|if)\b/.source+"(?:[ \t]*"+/(?:![ \t]*)?(?:\b\w+\b(?:[ \t]*\((?:[^()]|\([^()]*\))*\))?|\((?:[^()]|\([^()]*\))*\))(?:[ \t]*(?:&&|\|\|))?/.source+")+|"+/(?:else|endif)\b/.source+")"),alias:"property",inside:{"directive-name":/^#\w+/,boolean:/\b(?:false|true)\b/,number:/\b\d+(?:\.\d+)*\b/,operator:/!|&&|\|\||[<>]=?/,punctuation:/[(),]/}},literal:{pattern:/#(?:colorLiteral|column|dsohandle|file(?:ID|Literal|Path)?|function|imageLiteral|line)\b/,alias:"constant"},"other-directive":{pattern:/#\w+\b/,alias:"property"},attribute:{pattern:/@\w+/,alias:"atrule"},"function-definition":{pattern:/(\bfunc\s+)\w+/,lookbehind:!0,alias:"function"},label:{pattern:/\b(break|continue)\s+\w+|\b[a-zA-Z_]\w*(?=\s*:\s*(?:for|repeat|while)\b)/,lookbehind:!0,alias:"important"},keyword:/\b(?:Any|Protocol|Self|Type|actor|as|assignment|associatedtype|associativity|async|await|break|case|catch|class|continue|convenience|default|defer|deinit|didSet|do|dynamic|else|enum|extension|fallthrough|fileprivate|final|for|func|get|guard|higherThan|if|import|in|indirect|infix|init|inout|internal|is|isolated|lazy|left|let|lowerThan|mutating|none|nonisolated|nonmutating|open|operator|optional|override|postfix|precedencegroup|prefix|private|protocol|public|repeat|required|rethrows|return|right|safe|self|set|some|static|struct|subscript|super|switch|throw|throws|try|typealias|unowned|unsafe|var|weak|where|while|willSet)\b/,boolean:/\b(?:false|true)\b/,nil:{pattern:/\bnil\b/,alias:"constant"},"short-argument":/\$\d+\b/,omit:{pattern:/\b_\b/,alias:"keyword"},number:/\b(?:[\d_]+(?:\.[\de_]+)?|0x[a-f0-9_]+(?:\.[a-f0-9p_]+)?|0b[01_]+|0o[0-7_]+)\b/i,"class-name":/\b[A-Z](?:[A-Z_\d]*[a-z]\w*)?\b/,function:/\b[a-z_]\w*(?=\s*\()/i,constant:/\b(?:[A-Z_]{2,}|k[A-Z][A-Za-z_]+)\b/,operator:/[-+*/%=!<>&|^~?]+|\.[.\-+*/%=!<>&|^~?]+/,punctuation:/[{}[\]();,.:\\]/},Prism.languages.swift["string-literal"].forEach(function(e){e.inside.interpolation.inside=Prism.languages.swift}),function(e){var t="\\b(?:BASH|BASHOPTS|BASH_ALIASES|BASH_ARGC|BASH_ARGV|BASH_CMDS|BASH_COMPLETION_COMPAT_DIR|BASH_LINENO|BASH_REMATCH|BASH_SOURCE|BASH_VERSINFO|BASH_VERSION|COLORTERM|COLUMNS|COMP_WORDBREAKS|DBUS_SESSION_BUS_ADDRESS|DEFAULTS_PATH|DESKTOP_SESSION|DIRSTACK|DISPLAY|EUID|GDMSESSION|GDM_LANG|GNOME_KEYRING_CONTROL|GNOME_KEYRING_PID|GPG_AGENT_INFO|GROUPS|HISTCONTROL|HISTFILE|HISTFILESIZE|HISTSIZE|HOME|HOSTNAME|HOSTTYPE|IFS|INSTANCE|JOB|LANG|LANGUAGE|LC_ADDRESS|LC_ALL|LC_IDENTIFICATION|LC_MEASUREMENT|LC_MONETARY|LC_NAME|LC_NUMERIC|LC_PAPER|LC_TELEPHONE|LC_TIME|LESSCLOSE|LESSOPEN|LINES|LOGNAME|LS_COLORS|MACHTYPE|MAILCHECK|MANDATORY_PATH|NO_AT_BRIDGE|OLDPWD|OPTERR|OPTIND|ORBIT_SOCKETDIR|OSTYPE|PAPERSIZE|PATH|PIPESTATUS|PPID|PS1|PS2|PS3|PS4|PWD|RANDOM|REPLY|SECONDS|SELINUX_INIT|SESSION|SESSIONTYPE|SESSION_MANAGER|SHELL|SHELLOPTS|SHLVL|SSH_AUTH_SOCK|TERM|UID|UPSTART_EVENTS|UPSTART_INSTANCE|UPSTART_JOB|UPSTART_SESSION|USER|WINDOWID|XAUTHORITY|XDG_CONFIG_DIRS|XDG_CURRENT_DESKTOP|XDG_DATA_DIRS|XDG_GREETER_DATA_DIR|XDG_MENU_PREFIX|XDG_RUNTIME_DIR|XDG_SEAT|XDG_SEAT_PATH|XDG_SESSION_DESKTOP|XDG_SESSION_ID|XDG_SESSION_PATH|XDG_SESSION_TYPE|XDG_VTNR|XMODIFIERS)\\b",n={pattern:/(^(["']?)\w+\2)[ \t]+\S.*/,lookbehind:!0,alias:"punctuation",inside:null},r={bash:n,environment:{pattern:RegExp("\\$"+t),alias:"constant"},variable:[{pattern:/\$?\(\([\s\S]+?\)\)/,greedy:!0,inside:{variable:[{pattern:/(^\$\(\([\s\S]+)\)\)/,lookbehind:!0},/^\$\(\(/],number:/\b0x[\dA-Fa-f]+\b|(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:[Ee]-?\d+)?/,operator:/--|\+\+|\*\*=?|<<=?|>>=?|&&|\|\||[=!+\-*/%<>^&|]=?|[?~:]/,punctuation:/\(\(?|\)\)?|,|;/}},{pattern:/\$\((?:\([^)]+\)|[^()])+\)|`[^`]+`/,greedy:!0,inside:{variable:/^\$\(|^`|\)$|`$/}},{pattern:/\$\{[^}]+\}/,greedy:!0,inside:{operator:/:[-=?+]?|[!\/]|##?|%%?|\^\^?|,,?/,punctuation:/[\[\]]/,environment:{pattern:RegExp("(\\{)"+t),lookbehind:!0,alias:"constant"}}},/\$(?:\w+|[#?*!@$])/],entity:/\\(?:[abceEfnrtv\\"]|O?[0-7]{1,3}|U[0-9a-fA-F]{8}|u[0-9a-fA-F]{4}|x[0-9a-fA-F]{1,2})/};e.languages.bash={shebang:{pattern:/^#!\s*\/.*/,alias:"important"},comment:{pattern:/(^|[^"{\\$])#.*/,lookbehind:!0},"function-name":[{pattern:/(\bfunction\s+)[\w-]+(?=(?:\s*\(?:\s*\))?\s*\{)/,lookbehind:!0,alias:"function"},{pattern:/\b[\w-]+(?=\s*\(\s*\)\s*\{)/,alias:"function"}],"for-or-select":{pattern:/(\b(?:for|select)\s+)\w+(?=\s+in\s)/,alias:"variable",lookbehind:!0},"assign-left":{pattern:/(^|[\s;|&]|[<>]\()\w+(?:\.\w+)*(?=\+?=)/,inside:{environment:{pattern:RegExp("(^|[\\s;|&]|[<>]\\()"+t),lookbehind:!0,alias:"constant"}},alias:"variable",lookbehind:!0},parameter:{pattern:/(^|\s)-{1,2}(?:\w+:[+-]?)?\w+(?:\.\w+)*(?=[=\s]|$)/,alias:"variable",lookbehind:!0},string:[{pattern:/((?:^|[^<])<<-?\s*)(\w+)\s[\s\S]*?(?:\r?\n|\r)\2/,lookbehind:!0,greedy:!0,inside:r},{pattern:/((?:^|[^<])<<-?\s*)(["'])(\w+)\2\s[\s\S]*?(?:\r?\n|\r)\3/,lookbehind:!0,greedy:!0,inside:{bash:n}},{pattern:/(^|[^\\](?:\\\\)*)"(?:\\[\s\S]|\$\([^)]+\)|\$(?!\()|`[^`]+`|[^"\\`$])*"/,lookbehind:!0,greedy:!0,inside:r},{pattern:/(^|[^$\\])'[^']*'/,lookbehind:!0,greedy:!0},{pattern:/\$'(?:[^'\\]|\\[\s\S])*'/,greedy:!0,inside:{entity:r.entity}}],environment:{pattern:RegExp("\\$?"+t),alias:"constant"},variable:r.variable,function:{pattern:/(^|[\s;|&]|[<>]\()(?:add|apropos|apt|apt-cache|apt-get|aptitude|aspell|automysqlbackup|awk|basename|bash|bc|bconsole|bg|bzip2|cal|cargo|cat|cfdisk|chgrp|chkconfig|chmod|chown|chroot|cksum|clear|cmp|column|comm|composer|cp|cron|crontab|csplit|curl|cut|date|dc|dd|ddrescue|debootstrap|df|diff|diff3|dig|dir|dircolors|dirname|dirs|dmesg|docker|docker-compose|du|egrep|eject|env|ethtool|expand|expect|expr|fdformat|fdisk|fg|fgrep|file|find|fmt|fold|format|free|fsck|ftp|fuser|gawk|git|gparted|grep|groupadd|groupdel|groupmod|groups|grub-mkconfig|gzip|halt|head|hg|history|host|hostname|htop|iconv|id|ifconfig|ifdown|ifup|import|install|ip|java|jobs|join|kill|killall|less|link|ln|locate|logname|logrotate|look|lpc|lpr|lprint|lprintd|lprintq|lprm|ls|lsof|lynx|make|man|mc|mdadm|mkconfig|mkdir|mke2fs|mkfifo|mkfs|mkisofs|mknod|mkswap|mmv|more|most|mount|mtools|mtr|mutt|mv|nano|nc|netstat|nice|nl|node|nohup|notify-send|npm|nslookup|op|open|parted|passwd|paste|pathchk|ping|pkill|pnpm|podman|podman-compose|popd|pr|printcap|printenv|ps|pushd|pv|quota|quotacheck|quotactl|ram|rar|rcp|reboot|remsync|rename|renice|rev|rm|rmdir|rpm|rsync|scp|screen|sdiff|sed|sendmail|seq|service|sftp|sh|shellcheck|shuf|shutdown|sleep|slocate|sort|split|ssh|stat|strace|su|sudo|sum|suspend|swapon|sync|sysctl|tac|tail|tar|tee|time|timeout|top|touch|tr|traceroute|tsort|tty|umount|uname|unexpand|uniq|units|unrar|unshar|unzip|update-grub|uptime|useradd|userdel|usermod|users|uudecode|uuencode|v|vcpkg|vdir|vi|vim|virsh|vmstat|wait|watch|wc|wget|whereis|which|who|whoami|write|xargs|xdg-open|yarn|yes|zenity|zip|zsh|zypper)(?=$|[)\s;|&])/,lookbehind:!0},keyword:{pattern:/(^|[\s;|&]|[<>]\()(?:case|do|done|elif|else|esac|fi|for|function|if|in|select|then|until|while)(?=$|[)\s;|&])/,lookbehind:!0},builtin:{pattern:/(^|[\s;|&]|[<>]\()(?:\.|:|alias|bind|break|builtin|caller|cd|command|continue|declare|echo|enable|eval|exec|exit|export|getopts|hash|help|let|local|logout|mapfile|printf|pwd|read|readarray|readonly|return|set|shift|shopt|source|test|times|trap|type|typeset|ulimit|umask|unalias|unset)(?=$|[)\s;|&])/,lookbehind:!0,alias:"class-name"},boolean:{pattern:/(^|[\s;|&]|[<>]\()(?:false|true)(?=$|[)\s;|&])/,lookbehind:!0},"file-descriptor":{pattern:/\B&\d\b/,alias:"important"},operator:{pattern:/\d?<>|>\||\+=|=[=~]?|!=?|<<[<-]?|[&\d]?>>|\d[<>]&?|[<>][&=]?|&[>&]?|\|[&|]?/,inside:{"file-descriptor":{pattern:/^\d/,alias:"important"}}},punctuation:/\$?\(\(?|\)\)?|\.\.|[{}[\];\\]/,number:{pattern:/(^|\s)(?:[1-9]\d*|0)(?:[.,]\d+)?\b/,lookbehind:!0}},n.inside=e.languages.bash;for(var o=["comment","function-name","for-or-select","assign-left","parameter","string","environment","function","keyword","builtin","boolean","file-descriptor","operator","punctuation","number"],i=r.variable[1].inside,a=0;a<o.length;a++)i[o[a]]=e.languages.bash[o[a]];e.languages.sh=e.languages.bash,e.languages.shell=e.languages.bash}(Prism),function(e){var t=/(?:\\.|[^\\\n\r]|(?:\n|\r\n?)(?![\r\n]))/.source;function n(e){return e=e.replace(/<inner>/g,function(){return t}),RegExp(/((?:^|[^\\])(?:\\{2})*)/.source+"(?:"+e+")")}var r=/(?:\\.|``(?:[^`\r\n]|`(?!`))+``|`[^`\r\n]+`|[^\\|\r\n`])+/.source,o=/\|?__(?:\|__)+\|?(?:(?:\n|\r\n?)|(?![\s\S]))/.source.replace(/__/g,function(){return r}),i=/\|?[ \t]*:?-{3,}:?[ \t]*(?:\|[ \t]*:?-{3,}:?[ \t]*)+\|?(?:\n|\r\n?)/.source;e.languages.markdown=e.languages.extend("markup",{}),e.languages.insertBefore("markdown","prolog",{"front-matter-block":{pattern:/(^(?:\s*[\r\n])?)---(?!.)[\s\S]*?[\r\n]---(?!.)/,lookbehind:!0,greedy:!0,inside:{punctuation:/^---|---$/,"front-matter":{pattern:/\S+(?:\s+\S+)*/,alias:["yaml","language-yaml"],inside:e.languages.yaml}}},blockquote:{pattern:/^>(?:[\t ]*>)*/m,alias:"punctuation"},table:{pattern:RegExp("^"+o+i+"(?:"+o+")*","m"),inside:{"table-data-rows":{pattern:RegExp("^("+o+i+")(?:"+o+")*$"),lookbehind:!0,inside:{"table-data":{pattern:RegExp(r),inside:e.languages.markdown},punctuation:/\|/}},"table-line":{pattern:RegExp("^("+o+")"+i+"$"),lookbehind:!0,inside:{punctuation:/\||:?-{3,}:?/}},"table-header-row":{pattern:RegExp("^"+o+"$"),inside:{"table-header":{pattern:RegExp(r),alias:"important",inside:e.languages.markdown},punctuation:/\|/}}}},code:[{pattern:/((?:^|\n)[ \t]*\n|(?:^|\r\n?)[ \t]*\r\n?)(?: {4}|\t).+(?:(?:\n|\r\n?)(?: {4}|\t).+)*/,lookbehind:!0,alias:"keyword"},{pattern:/^```[\s\S]*?^```$/m,greedy:!0,inside:{"code-block":{pattern:/^(```.*(?:\n|\r\n?))[\s\S]+?(?=(?:\n|\r\n?)^```$)/m,lookbehind:!0},"code-language":{pattern:/^(```).+/,lookbehind:!0},punctuation:/```/}}],title:[{pattern:/\S.*(?:\n|\r\n?)(?:==+|--+)(?=[ \t]*$)/m,alias:"important",inside:{punctuation:/==+$|--+$/}},{pattern:/(^\s*)#.+/m,lookbehind:!0,alias:"important",inside:{punctuation:/^#+|#+$/}}],hr:{pattern:/(^\s*)([*-])(?:[\t ]*\2){2,}(?=\s*$)/m,lookbehind:!0,alias:"punctuation"},list:{pattern:/(^\s*)(?:[*+-]|\d+\.)(?=[\t ].)/m,lookbehind:!0,alias:"punctuation"},"url-reference":{pattern:/!?\[[^\]]+\]:[\t ]+(?:\S+|<(?:\\.|[^>\\])+>)(?:[\t ]+(?:"(?:\\.|[^"\\])*"|'(?:\\.|[^'\\])*'|\((?:\\.|[^)\\])*\)))?/,inside:{variable:{pattern:/^(!?\[)[^\]]+/,lookbehind:!0},string:/(?:"(?:\\.|[^"\\])*"|'(?:\\.|[^'\\])*'|\((?:\\.|[^)\\])*\))$/,punctuation:/^[\[\]!:]|[<>]/},alias:"url"},bold:{pattern:n(/\b__(?:(?!_)<inner>|_(?:(?!_)<inner>)+_)+__\b|\*\*(?:(?!\*)<inner>|\*(?:(?!\*)<inner>)+\*)+\*\*/.source),lookbehind:!0,greedy:!0,inside:{content:{pattern:/(^..)[\s\S]+(?=..$)/,lookbehind:!0,inside:{}},punctuation:/\*\*|__/}},italic:{pattern:n(/\b_(?:(?!_)<inner>|__(?:(?!_)<inner>)+__)+_\b|\*(?:(?!\*)<inner>|\*\*(?:(?!\*)<inner>)+\*\*)+\*/.source),lookbehind:!0,greedy:!0,inside:{content:{pattern:/(^.)[\s\S]+(?=.$)/,lookbehind:!0,inside:{}},punctuation:/[*_]/}},strike:{pattern:n(/(~~?)(?:(?!~)<inner>)+\2/.source),lookbehind:!0,greedy:!0,inside:{content:{pattern:/(^~~?)[\s\S]+(?=\1$)/,lookbehind:!0,inside:{}},punctuation:/~~?/}},"code-snippet":{pattern:/(^|[^\\`])(?:``[^`\r\n]+(?:`[^`\r\n]+)*``(?!`)|`[^`\r\n]+`(?!`))/,lookbehind:!0,greedy:!0,alias:["code","keyword"]},url:{pattern:n(/!?\[(?:(?!\])<inner>)+\](?:\([^\s)]+(?:[\t ]+"(?:\\.|[^"\\])*")?\)|[ \t]?\[(?:(?!\])<inner>)+\])/.source),lookbehind:!0,greedy:!0,inside:{operator:/^!/,content:{pattern:/(^\[)[^\]]+(?=\])/,lookbehind:!0,inside:{}},variable:{pattern:/(^\][ \t]?\[)[^\]]+(?=\]$)/,lookbehind:!0},url:{pattern:/(^\]\()[^\s)]+/,lookbehind:!0},string:{pattern:/(^[ \t]+)"(?:\\.|[^"\\])*"(?=\)$)/,lookbehind:!0}}}}),["url","bold","italic","strike"].forEach(function(t){["url","bold","italic","strike","code-snippet"].forEach(function(n){t!==n&&(e.languages.markdown[t].inside.content.inside[n]=e.languages.markdown[n])})}),e.hooks.add("after-tokenize",function(e){"markdown"!==e.language&&"md"!==e.language||function e(t){if(t&&"string"!=typeof t)for(var n=0,r=t.length;n<r;n++){var o=t[n];if("code"===o.type){var i=o.content[1],a=o.content[3];if(i&&a&&"code-language"===i.type&&"code-block"===a.type&&"string"==typeof i.content){var s=i.content.replace(/\b#/g,"sharp").replace(/\b\+\+/g,"pp"),u="language-"+(s=(/[a-z][\w-]*/i.exec(s)||[""])[0].toLowerCase());a.alias?"string"==typeof a.alias?a.alias=[a.alias,u]:a.alias.push(u):a.alias=[u]}}else e(o.content)}}(e.tokens)}),e.hooks.add("wrap",function(t){if("code-block"===t.type){for(var n="",r=0,o=t.classes.length;r<o;r++){var i=t.classes[r],l=/language-(.+)/.exec(i);if(l){n=l[1];break}}var c=e.languages[n];if(c)t.content=e.highlight(function(e){var t=e.replace(a,"");return t=t.replace(/&(\w{1,8}|#x?[\da-f]{1,8});/gi,function(e,t){var n;if("#"===(t=t.toLowerCase())[0])return n="x"===t[1]?parseInt(t.slice(2),16):Number(t.slice(1)),u(n);var r=s[t];return r||e}),t}(t.content),c,n);else if(n&&"none"!==n&&e.plugins.autoloader){var d="md-"+(new Date).valueOf()+"-"+Math.floor(1e16*Math.random());t.attributes.id=d,e.plugins.autoloader.loadLanguages(n,function(){var t=document.getElementById(d);t&&(t.innerHTML=e.highlight(t.textContent,e.languages[n],n))})}}});var a=RegExp(e.languages.markup.tag.pattern.source,"gi"),s={amp:"&",lt:"<",gt:">",quot:'"'},u=String.fromCodePoint||String.fromCharCode;e.languages.md=e.languages.markdown}(Prism),Prism.languages.lua={comment:/^#!.+|--(?:\[(=*)\[[\s\S]*?\]\1\]|.*)/m,string:{pattern:/(["'])(?:(?!\1)[^\\\r\n]|\\z(?:\r\n|\s)|\\(?:\r\n|[^z]))*\1|\[(=*)\[[\s\S]*?\]\2\]/,greedy:!0},number:/\b0x[a-f\d]+(?:\.[a-f\d]*)?(?:p[+-]?\d+)?\b|\b\d+(?:\.\B|(?:\.\d*)?(?:e[+-]?\d+)?\b)|\B\.\d+(?:e[+-]?\d+)?\b/i,keyword:/\b(?:and|break|do|else|elseif|end|false|for|function|goto|if|in|local|nil|not|or|repeat|return|then|true|until|while)\b/,function:/(?!\d)\w+(?=\s*(?:[({]))/,operator:[/[-+*%^&|#]|\/\/?|<[<=]?|>[>=]?|[=~]=?/,{pattern:/(^|[^.])\.\.(?!\.)/,lookbehind:!0}],punctuation:/[\[\](){},;]|\.+|:+/},function(e){var t={pattern:/((?:^|[^\\$])(?:\\{2})*)\$(?:\w+|\{[^{}]*\})/,lookbehind:!0,inside:{"interpolation-punctuation":{pattern:/^\$\{?|\}$/,alias:"punctuation"},expression:{pattern:/[\s\S]+/,inside:null}}};e.languages.groovy=e.languages.extend("clike",{string:{pattern:/'''(?:[^\\]|\\[\s\S])*?'''|'(?:\\.|[^\\'\r\n])*'/,greedy:!0},keyword:/\b(?:abstract|as|assert|boolean|break|byte|case|catch|char|class|const|continue|def|default|do|double|else|enum|extends|final|finally|float|for|goto|if|implements|import|in|instanceof|int|interface|long|native|new|package|private|protected|public|return|short|static|strictfp|super|switch|synchronized|this|throw|throws|trait|transient|try|void|volatile|while)\b/,number:/\b(?:0b[01_]+|0x[\da-f_]+(?:\.[\da-f_p\-]+)?|[\d_]+(?:\.[\d_]+)?(?:e[+-]?\d+)?)[glidf]?\b/i,operator:{pattern:/(^|[^.])(?:~|==?~?|\?[.:]?|\*(?:[.=]|\*=?)?|\.[@&]|\.\.<|\.\.(?!\.)|-[-=>]?|\+[+=]?|!=?|<(?:<=?|=>?)?|>(?:>>?=?|=)?|&[&=]?|\|[|=]?|\/=?|\^=?|%=?)/,lookbehind:!0},punctuation:/\.+|[{}[\];(),:$]/}),e.languages.insertBefore("groovy","string",{shebang:{pattern:/#!.+/,alias:"comment",greedy:!0},"interpolation-string":{pattern:/"""(?:[^\\]|\\[\s\S])*?"""|(["/])(?:\\.|(?!\1)[^\\\r\n])*\1|\$\/(?:[^/$]|\$(?:[/$]|(?![/$]))|\/(?!\$))*\/\$/,greedy:!0,inside:{interpolation:t,string:/[\s\S]+/}}}),e.languages.insertBefore("groovy","punctuation",{"spock-block":/\b(?:and|cleanup|expect|given|setup|then|when|where):/}),e.languages.insertBefore("groovy","function",{annotation:{pattern:/(^|[^.])@\w+/,lookbehind:!0,alias:"punctuation"}}),t.inside.expression.inside=e.languages.groovy}(Prism),Prism.languages.abap={comment:/^\*.*/m,string:/(`|')(?:\\.|(?!\1)[^\\\r\n])*\1/,"string-template":{pattern:/([|}])(?:\\.|[^\\|{\r\n])*(?=[|{])/,lookbehind:!0,alias:"string"},"eol-comment":{pattern:/(^|\s)".*/m,lookbehind:!0,alias:"comment"},keyword:{pattern:/(\s|\.|^)(?:\*-INPUT|\?TO|ABAP-SOURCE|ABBREVIATED|ABS|ABSTRACT|ACCEPT|ACCEPTING|ACCESSPOLICY|ACCORDING|ACOS|ACTIVATION|ACTUAL|ADD|ADD-CORRESPONDING|ADJACENT|AFTER|ALIAS|ALIASES|ALIGN|ALL|ALLOCATE|ALPHA|ANALYSIS|ANALYZER|AND|ANY|APPEND|APPENDAGE|APPENDING|APPLICATION|ARCHIVE|AREA|ARITHMETIC|AS|ASCENDING|ASIN|ASPECT|ASSERT|ASSIGN|ASSIGNED|ASSIGNING|ASSOCIATION|ASYNCHRONOUS|AT|ATAN|ATTRIBUTES|AUTHORITY|AUTHORITY-CHECK|AVG|BACK|BACKGROUND|BACKUP|BACKWARD|BADI|BASE|BEFORE|BEGIN|BETWEEN|BIG|BINARY|BINDING|BIT|BIT-AND|BIT-NOT|BIT-OR|BIT-XOR|BLACK|BLANK|BLANKS|BLOB|BLOCK|BLOCKS|BLUE|BOUND|BOUNDARIES|BOUNDS|BOXED|BREAK-POINT|BT|BUFFER|BY|BYPASSING|BYTE|BYTE-CA|BYTE-CN|BYTE-CO|BYTE-CS|BYTE-NA|BYTE-NS|BYTE-ORDER|C|CA|CALL|CALLING|CASE|CAST|CASTING|CATCH|CEIL|CENTER|CENTERED|CHAIN|CHAIN-INPUT|CHAIN-REQUEST|CHANGE|CHANGING|CHANNELS|CHAR-TO-HEX|CHARACTER|CHARLEN|CHECK|CHECKBOX|CIRCULAR|CI_|CLASS|CLASS-CODING|CLASS-DATA|CLASS-EVENTS|CLASS-METHODS|CLASS-POOL|CLEANUP|CLEAR|CLIENT|CLOB|CLOCK|CLOSE|CN|CNT|CO|COALESCE|CODE|CODING|COLLECT|COLOR|COLUMN|COLUMNS|COL_BACKGROUND|COL_GROUP|COL_HEADING|COL_KEY|COL_NEGATIVE|COL_NORMAL|COL_POSITIVE|COL_TOTAL|COMMENT|COMMENTS|COMMIT|COMMON|COMMUNICATION|COMPARING|COMPONENT|COMPONENTS|COMPRESSION|COMPUTE|CONCAT|CONCATENATE|COND|CONDENSE|CONDITION|CONNECT|CONNECTION|CONSTANTS|CONTEXT|CONTEXTS|CONTINUE|CONTROL|CONTROLS|CONV|CONVERSION|CONVERT|COPIES|COPY|CORRESPONDING|COS|COSH|COUNT|COUNTRY|COVER|CP|CPI|CREATE|CREATING|CRITICAL|CS|CURRENCY|CURRENCY_CONVERSION|CURRENT|CURSOR|CURSOR-SELECTION|CUSTOMER|CUSTOMER-FUNCTION|DANGEROUS|DATA|DATABASE|DATAINFO|DATASET|DATE|DAYLIGHT|DBMAXLEN|DD\/MM\/YY|DD\/MM\/YYYY|DDMMYY|DEALLOCATE|DECIMALS|DECIMAL_SHIFT|DECLARATIONS|DEEP|DEFAULT|DEFERRED|DEFINE|DEFINING|DEFINITION|DELETE|DELETING|DEMAND|DEPARTMENT|DESCENDING|DESCRIBE|DESTINATION|DETAIL|DIALOG|DIRECTORY|DISCONNECT|DISPLAY|DISPLAY-MODE|DISTANCE|DISTINCT|DIV|DIVIDE|DIVIDE-CORRESPONDING|DIVISION|DO|DUMMY|DUPLICATE|DUPLICATES|DURATION|DURING|DYNAMIC|DYNPRO|E|EACH|EDIT|EDITOR-CALL|ELSE|ELSEIF|EMPTY|ENABLED|ENABLING|ENCODING|END|END-ENHANCEMENT-SECTION|END-LINES|END-OF-DEFINITION|END-OF-FILE|END-OF-PAGE|END-OF-SELECTION|ENDAT|ENDCASE|ENDCATCH|ENDCHAIN|ENDCLASS|ENDDO|ENDENHANCEMENT|ENDEXEC|ENDFOR|ENDFORM|ENDFUNCTION|ENDIAN|ENDIF|ENDING|ENDINTERFACE|ENDLOOP|ENDMETHOD|ENDMODULE|ENDON|ENDPROVIDE|ENDSELECT|ENDTRY|ENDWHILE|ENGINEERING|ENHANCEMENT|ENHANCEMENT-POINT|ENHANCEMENT-SECTION|ENHANCEMENTS|ENTRIES|ENTRY|ENVIRONMENT|EQ|EQUAL|EQUIV|ERRORMESSAGE|ERRORS|ESCAPE|ESCAPING|EVENT|EVENTS|EXACT|EXCEPT|EXCEPTION|EXCEPTION-TABLE|EXCEPTIONS|EXCLUDE|EXCLUDING|EXEC|EXECUTE|EXISTS|EXIT|EXIT-COMMAND|EXP|EXPAND|EXPANDING|EXPIRATION|EXPLICIT|EXPONENT|EXPORT|EXPORTING|EXTEND|EXTENDED|EXTENSION|EXTRACT|FAIL|FETCH|FIELD|FIELD-GROUPS|FIELD-SYMBOL|FIELD-SYMBOLS|FIELDS|FILE|FILTER|FILTER-TABLE|FILTERS|FINAL|FIND|FIRST|FIRST-LINE|FIXED-POINT|FKEQ|FKGE|FLOOR|FLUSH|FONT|FOR|FORM|FORMAT|FORWARD|FOUND|FRAC|FRAME|FRAMES|FREE|FRIENDS|FROM|FUNCTION|FUNCTION-POOL|FUNCTIONALITY|FURTHER|GAPS|GE|GENERATE|GET|GIVING|GKEQ|GKGE|GLOBAL|GRANT|GREATER|GREEN|GROUP|GROUPS|GT|HANDLE|HANDLER|HARMLESS|HASHED|HAVING|HDB|HEAD-LINES|HEADER|HEADERS|HEADING|HELP-ID|HELP-REQUEST|HIDE|HIGH|HINT|HOLD|HOTSPOT|I|ICON|ID|IDENTIFICATION|IDENTIFIER|IDS|IF|IGNORE|IGNORING|IMMEDIATELY|IMPLEMENTATION|IMPLEMENTATIONS|IMPLEMENTED|IMPLICIT|IMPORT|IMPORTING|IN|INACTIVE|INCL|INCLUDE|INCLUDES|INCLUDING|INCREMENT|INDEX|INDEX-LINE|INFOTYPES|INHERITING|INIT|INITIAL|INITIALIZATION|INNER|INOUT|INPUT|INSERT|INSTANCES|INTENSIFIED|INTERFACE|INTERFACE-POOL|INTERFACES|INTERNAL|INTERVALS|INTO|INVERSE|INVERTED-DATE|IS|ISO|ITERATOR|ITNO|JOB|JOIN|KEEP|KEEPING|KERNEL|KEY|KEYS|KEYWORDS|KIND|LANGUAGE|LAST|LATE|LAYOUT|LE|LEADING|LEAVE|LEFT|LEFT-JUSTIFIED|LEFTPLUS|LEFTSPACE|LEGACY|LENGTH|LESS|LET|LEVEL|LEVELS|LIKE|LINE|LINE-COUNT|LINE-SELECTION|LINE-SIZE|LINEFEED|LINES|LIST|LIST-PROCESSING|LISTBOX|LITTLE|LLANG|LOAD|LOAD-OF-PROGRAM|LOB|LOCAL|LOCALE|LOCATOR|LOG|LOG-POINT|LOG10|LOGFILE|LOGICAL|LONG|LOOP|LOW|LOWER|LPAD|LPI|LT|M|MAIL|MAIN|MAJOR-ID|MAPPING|MARGIN|MARK|MASK|MATCH|MATCHCODE|MAX|MAXIMUM|MEDIUM|MEMBERS|MEMORY|MESH|MESSAGE|MESSAGE-ID|MESSAGES|MESSAGING|METHOD|METHODS|MIN|MINIMUM|MINOR-ID|MM\/DD\/YY|MM\/DD\/YYYY|MMDDYY|MOD|MODE|MODIF|MODIFIER|MODIFY|MODULE|MOVE|MOVE-CORRESPONDING|MULTIPLY|MULTIPLY-CORRESPONDING|NA|NAME|NAMETAB|NATIVE|NB|NE|NESTED|NESTING|NEW|NEW-LINE|NEW-PAGE|NEW-SECTION|NEXT|NO|NO-DISPLAY|NO-EXTENSION|NO-GAP|NO-GAPS|NO-GROUPING|NO-HEADING|NO-SCROLLING|NO-SIGN|NO-TITLE|NO-TOPOFPAGE|NO-ZERO|NODE|NODES|NON-UNICODE|NON-UNIQUE|NOT|NP|NS|NULL|NUMBER|NUMOFCHAR|O|OBJECT|OBJECTS|OBLIGATORY|OCCURRENCE|OCCURRENCES|OCCURS|OF|OFF|OFFSET|OLE|ON|ONLY|OPEN|OPTION|OPTIONAL|OPTIONS|OR|ORDER|OTHER|OTHERS|OUT|OUTER|OUTPUT|OUTPUT-LENGTH|OVERFLOW|OVERLAY|PACK|PACKAGE|PAD|PADDING|PAGE|PAGES|PARAMETER|PARAMETER-TABLE|PARAMETERS|PART|PARTIALLY|PATTERN|PERCENTAGE|PERFORM|PERFORMING|PERSON|PF|PF-STATUS|PINK|PLACES|POOL|POSITION|POS_HIGH|POS_LOW|PRAGMAS|PRECOMPILED|PREFERRED|PRESERVING|PRIMARY|PRINT|PRINT-CONTROL|PRIORITY|PRIVATE|PROCEDURE|PROCESS|PROGRAM|PROPERTY|PROTECTED|PROVIDE|PUBLIC|PUSHBUTTON|PUT|QUEUE-ONLY|QUICKINFO|RADIOBUTTON|RAISE|RAISING|RANGE|RANGES|RAW|READ|READ-ONLY|READER|RECEIVE|RECEIVED|RECEIVER|RECEIVING|RED|REDEFINITION|REDUCE|REDUCED|REF|REFERENCE|REFRESH|REGEX|REJECT|REMOTE|RENAMING|REPLACE|REPLACEMENT|REPLACING|REPORT|REQUEST|REQUESTED|RESERVE|RESET|RESOLUTION|RESPECTING|RESPONSIBLE|RESULT|RESULTS|RESUMABLE|RESUME|RETRY|RETURN|RETURNCODE|RETURNING|RIGHT|RIGHT-JUSTIFIED|RIGHTPLUS|RIGHTSPACE|RISK|RMC_COMMUNICATION_FAILURE|RMC_INVALID_STATUS|RMC_SYSTEM_FAILURE|ROLE|ROLLBACK|ROUND|ROWS|RTTI|RUN|SAP|SAP-SPOOL|SAVING|SCALE_PRESERVING|SCALE_PRESERVING_SCIENTIFIC|SCAN|SCIENTIFIC|SCIENTIFIC_WITH_LEADING_ZERO|SCREEN|SCROLL|SCROLL-BOUNDARY|SCROLLING|SEARCH|SECONDARY|SECONDS|SECTION|SELECT|SELECT-OPTIONS|SELECTION|SELECTION-SCREEN|SELECTION-SET|SELECTION-SETS|SELECTION-TABLE|SELECTIONS|SELECTOR|SEND|SEPARATE|SEPARATED|SET|SHARED|SHIFT|SHORT|SHORTDUMP-ID|SIGN|SIGN_AS_POSTFIX|SIMPLE|SIN|SINGLE|SINH|SIZE|SKIP|SKIPPING|SMART|SOME|SORT|SORTABLE|SORTED|SOURCE|SPACE|SPECIFIED|SPLIT|SPOOL|SPOTS|SQL|SQLSCRIPT|SQRT|STABLE|STAMP|STANDARD|START-OF-SELECTION|STARTING|STATE|STATEMENT|STATEMENTS|STATIC|STATICS|STATUSINFO|STEP-LOOP|STOP|STRLEN|STRUCTURE|STRUCTURES|STYLE|SUBKEY|SUBMATCHES|SUBMIT|SUBROUTINE|SUBSCREEN|SUBSTRING|SUBTRACT|SUBTRACT-CORRESPONDING|SUFFIX|SUM|SUMMARY|SUMMING|SUPPLIED|SUPPLY|SUPPRESS|SWITCH|SWITCHSTATES|SYMBOL|SYNCPOINTS|SYNTAX|SYNTAX-CHECK|SYNTAX-TRACE|SYSTEM-CALL|SYSTEM-EXCEPTIONS|SYSTEM-EXIT|TAB|TABBED|TABLE|TABLES|TABLEVIEW|TABSTRIP|TAN|TANH|TARGET|TASK|TASKS|TEST|TESTING|TEXT|TEXTPOOL|THEN|THROW|TIME|TIMES|TIMESTAMP|TIMEZONE|TITLE|TITLE-LINES|TITLEBAR|TO|TOKENIZATION|TOKENS|TOP-LINES|TOP-OF-PAGE|TRACE-FILE|TRACE-TABLE|TRAILING|TRANSACTION|TRANSFER|TRANSFORMATION|TRANSLATE|TRANSPORTING|TRMAC|TRUNC|TRUNCATE|TRUNCATION|TRY|TYPE|TYPE-POOL|TYPE-POOLS|TYPES|ULINE|UNASSIGN|UNDER|UNICODE|UNION|UNIQUE|UNIT|UNIT_CONVERSION|UNIX|UNPACK|UNTIL|UNWIND|UP|UPDATE|UPPER|USER|USER-COMMAND|USING|UTF-8|VALID|VALUE|VALUE-REQUEST|VALUES|VARY|VARYING|VERIFICATION-MESSAGE|VERSION|VIA|VIEW|VISIBLE|WAIT|WARNING|WHEN|WHENEVER|WHERE|WHILE|WIDTH|WINDOW|WINDOWS|WITH|WITH-HEADING|WITH-TITLE|WITHOUT|WORD|WORK|WRITE|WRITER|X|XML|XOR|XSD|XSTRLEN|YELLOW|YES|YYMMDD|Z|ZERO|ZONE)(?![\w-])/i,lookbehind:!0},number:/\b\d+\b/,operator:{pattern:/(\s)(?:\*\*?|<[=>]?|>=?|\?=|[-+\/=])(?=\s)/,lookbehind:!0},"string-operator":{pattern:/(\s)&&?(?=\s)/,lookbehind:!0,alias:"keyword"},"token-operator":[{pattern:/(\w)(?:->?|=>|[~|{}])(?=\w)/,lookbehind:!0,alias:"punctuation"},{pattern:/[|{}]/,alias:"punctuation"}],punctuation:/[,.:()]/};var NB=["comment","prolog","doctype","cdata","punctuation","namespace","property","tag","boolean","number","constant","symbol","deleted","selector","attr-name","string","builtin","inserted","operator","entity","url","string","atrule","attr-value","keyword","function","class-name","regex","important","variable","bold","italic","entity","char"];function BB(e){return"string"==typeof e?e.length:"string"==typeof e.content?e.content.length:e.content.reduce(function(e,t){return e+BB(t)},0)}var TB=function(e){var t,n,r,o=ev(e,2),i=o[0],a=o[1],s=[],u=function(e){if(!Cg.isText(e))return null;var t=Py.getParentNode(null,e);if(t&&"code"===Py.getNodeType(t)){var n=Py.getParentNode(null,t);if(n&&"pre"===Py.getNodeType(n))return t}return null}(i);if(null==u)return s;var l=u.language,c=void 0===l?"":l;if(!c)return s;var d=function(e,t){if(!t)return[];var n=EB.languages[t];return n?EB.tokenize(e.text,n):[]}(i,c),f=0;try{for(var p=Qg(d),h=p.next();!h.done;h=p.next()){var g=h.value,v=f+BB(g);"string"!=typeof g&&s.push(((r={})[g.type]=!0,r.anchor={path:a,offset:f},r.focus={path:a,offset:v},r)),f=v}}catch(e){t={error:e}}finally{try{h&&!h.done&&(n=p.return)&&n.call(p)}finally{if(t)throw t.error}}return s};var kB={type:"code",elemToHtml:function(e,t){var n=e.language,r=void 0===n?"":n,o=r?'class="language-'.concat(r,'"'):"";return"<code ".concat(o,">").concat(t,"</code>")}};var FB=function(){function e(){this.title=JE("highLightModule.selectLang"),this.iconSvg='<svg viewBox="0 0 1024 1024"><path d="M64 64v896h896V64H64z m487.6 698.8c0 87.2-51.2 127-125.8 127-67.4 0-106.4-34.8-126.4-77l68.6-41.4c13.2 23.4 25.2 43.2 54.2 43.2 27.6 0 45.2-10.8 45.2-53V475.4h84.2v287.4z m199.2 127c-78.2 0-128.8-37.2-153.4-86l68.6-39.6c18 29.4 41.6 51.2 83 51.2 34.8 0 57.2-17.4 57.2-41.6 0-28.8-22.8-39-61.4-56l-21-9c-60.8-25.8-101-58.4-101-127 0-63.2 48.2-111.2 123.2-111.2 53.6 0 92 18.6 119.6 67.4L800 580c-14.4-25.8-30-36-54.2-36-24.6 0-40.2 15.6-40.2 36 0 25.2 15.6 35.4 51.8 51.2l21 9c71.6 30.6 111.8 62 111.8 132.4 0 75.6-59.6 117.2-139.4 117.2z"></path></svg>',this.tag="select",this.width=95,this.selectPanelWidth=115,this.defaultCodeLang=""}return e.prototype.getOptions=function(e){var t=this,n=[],r=e.getMenuConfig("codeSelectLang").codeLangs,o=void 0===r?[]:r;n.push({text:"plain text",value:""}),o.forEach(function(e){var r=e.text,o=e.value;e.selected&&(t.defaultCodeLang=o),n.push({text:r,value:o})});var i=this.getValue(e);return n.forEach(function(e){e.value===i?e.selected=!0:e.selected=void 0}),n},e.prototype.isActive=function(e){return!1},e.prototype.getValue=function(e){var t=this.getSelectCodeElem(e);if(null==t)return this.defaultCodeLang;if(!$h.isElement(t))return this.defaultCodeLang;var n=t.language.toString(),r=e.getMenuConfig("codeSelectLang").codeLangs;return(void 0===r?[]:r).some(function(e){return e.value===n})?n:this.defaultCodeLang},e.prototype.isDisabled=function(e){return null==e.selection||!this.getSelectCodeElem(e)},e.prototype.exec=function(e,t){if(null!=this.getSelectCodeElem(e)){var n={language:t.toString()};jg.setNodes(e,n,{match:function(e){return Py.checkNodeType(e,"code")}})}},e.prototype.getSelectCodeElem=function(e){var t=Py.getSelectedNodeByType(e,"code");if(null==t)return null;var n=Py.getParentNode(e,t);return $h.isElement(n)?"pre"!==n.type?null:t:null},e}(),IB={key:"codeSelectLang",factory:function(){return new FB},config:{codeLangs:[{text:"CSS",value:"css"},{text:"HTML",value:"html"},{text:"XML",value:"xml"},{text:"Javascript",value:"javascript"},{text:"Typescript",value:"typescript"},{text:"JSX",value:"jsx"},{text:"Go",value:"go"},{text:"PHP",value:"php"},{text:"C",value:"c"},{text:"Python",value:"python"},{text:"Java",value:"java"},{text:"C++",value:"cpp"},{text:"C#",value:"csharp"},{text:"Visual Basic",value:"visual-basic"},{text:"SQL",value:"sql"},{text:"Ruby",value:"ruby"},{text:"Swift",value:"swift"},{text:"Bash",value:"bash"},{text:"Lua",value:"lua"},{text:"Groovy",value:"groovy"},{text:"Markdown",value:"markdown"},{text:"ABAP",value:"abap"}]}};lm&&(im.fn.attr=lm);var PB={renderStyle:function(e,t){var n=e,r=t,o="";return NB.forEach(function(e){n[e]&&(o=e)}),o&&function(e,t){null==e.data&&(e.data={});var n=e.data;null==n.props&&(n.props={}),Object.assign(n.props,{className:t})}(r,o="token ".concat(o)),r},parseStyleHtml:function(e,t,n){var r=im(e);if(!$h.isElement(t))return t;if("code"!==Py.getNodeType(t))return t;var o=t,i=r.attr("class")||"";return 0===i.indexOf("language-")?o.language=i.split("-")[1]||"":o.language=i.toLowerCase(),o},menus:[IB],elemsToHtml:[kB]};KE("en",{listModule:{unOrderedList:"Unordered list",orderedList:"Ordered list"}}),KE("zh-CN",{listModule:{unOrderedList:"无序列表",orderedList:"有序列表"}});var _B=new WeakMap;function LB(e){var t,n=e.children||[],r=n.length;if(0===r)return"";for(var o=0;o<r&&!t;o+=1){var i=n[o];Cg.isText(i)&&(t=i)}return null==t?"":t.color||""}function RB(e,t,n){for(var r=t.type,o=Xg(t,["type"]),i=void 0!==n?n:o.level||0,a=Py.findPath(e,t),s=a;;){if(0===s.length||0===a[a.length-1])return null;s=og.previous(s);var u=Kh.node(e,s);if(!u)return null;var l=ev(u,1)[0],c=l.level,d=void 0===c?0:c;if(Py.getNodeType(l)!==r)return null;if(d===i)return l}}function MB(e,t,n){var r=RB(e,t,n);return!!r&&r.ordered===t.ordered}var jB=[];var HB={type:"list-item",elemToHtml:function(e,t){var n="",r="",o=e.ordered,i=void 0!==o&&o?"ol":"ul",a=function(e){var t=_B.get(e);if(null==t)return 0;var n=e,r=n.type,o=n.ordered,i=void 0!==o&&o,a=n.level,s=void 0===a?0:a,u=Py.findPath(t,e);if(0===u[0])return s+1;var l=og.previous(u),c=Kh.node(t,l);if(!c)return 0;var d=ev(c,1)[0];if(Py.getNodeType(d)!==r)return s+1;var f=d,p=f.ordered,h=void 0!==p&&p,g=f.level,v=void 0===g?0:g;return v<s?s-v:v>s?MB(t,e)?0:1:v===s?h===i?0:1:0}(e);if(a>0)for(var s=0;s<a;s+=1)n+="<".concat(i,">"),jB.push(i);var u=function(e){var t=_B.get(e);if(null==t)return 0;var n=e,r=n.type,o=n.ordered,i=void 0!==o&&o,a=n.level,s=void 0===a?0:a,u=Py.findPath(t,e);if(u[0]===t.children.length-1)return s+1;var l=og.next(u),c=Kh.node(t,l);if(!c)return 0;var d=ev(c,1)[0];if(Py.getNodeType(d)!==r)return s+1;var f=d,p=f.ordered,h=void 0!==p&&p,g=f.level,v=void 0===g?0:g;return v<s?MB(t,d)?s-v:s-v+1:v>s?0:v===s?h===i?0:1:0}(e);if(u>0)for(s=0;s<u;s+=1){var l=jB.pop();r+="</".concat(l,">")}var c=LB(e),d=c?' style="color:'.concat(c,'"'):"";return{html:"<li".concat(d,">").concat(t,"</li>"),prefix:n,suffix:r}}},zB=function(){function e(){this.type="list-item",this.tag="button"}return e.prototype.getListNode=function(e){var t=this.type;return Py.getSelectedNodeByType(e,t)},e.prototype.getValue=function(e){return""},e.prototype.isActive=function(e){var t=this.getListNode(e);if(null==t)return!1;var n=t.ordered;return(void 0!==n&&n)===this.ordered},e.prototype.isDisabled=function(e){return null==e.selection||!!Py.getSelectedElems(e).some(function(t){if(Kh.isVoid(e,t)&&Kh.isBlock(e,t))return!0;var n=t.type;return!!["pre","code","table"].includes(n)})},e.prototype.exec=function(e,t){this.isActive(e)?jg.setNodes(e,{type:"paragraph",ordered:void 0,level:void 0}):jg.setNodes(e,{type:"list-item",ordered:this.ordered,indent:void 0})},e}(),$B=function(e){function t(){var t=e.apply(this,tv([],ev(arguments),!1))||this;return t.ordered=!1,t.title=JE("listModule.unOrderedList"),t.iconSvg='<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>',t}return Kg(t,e),t}(zB),UB=function(e){function t(){var t=e.apply(this,tv([],ev(arguments),!1))||this;return t.ordered=!0,t.title=JE("listModule.orderedList"),t.iconSvg='<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>',t}return Kg(t,e),t}(zB),VB={key:"bulletedList",factory:function(){return new $B}},WB={key:"numberedList",factory:function(){return new UB}};function GB(e){return e.length?e[0].tagName.toLowerCase():""}Om&&(im.fn.append=Om),lm&&(im.fn.attr=lm),Bm&&(im.fn.parent=Bm);var qB={selector:"li:not([data-w-e-type])",parseElemHtml:function(e,t,n){var r=im(e);0===(t=t.filter(function(e){return!!Cg.isText(e)||!!n.isInline(e)})).length&&(t=[{text:r.text().replace(/\s+/gm," ")}]);var o=function(e){return"ol"===GB(e.parent())}(r),i=function(e){for(var t=0,n=e.parent(),r=GB(n);"ul"===r||"ol"===r;)r=GB(n=n.parent()),t+=1;return t-1}(r);return{type:"list-item",ordered:o,level:i,children:t}}};var KB={selector:"ul:not([data-w-e-type]),ol:not([data-w-e-type])",parseElemHtml:function(e,t,n){return t.flat(1/0)}};function YB(e){return Kh.nodes(e,{at:e.selection||void 0,match:function(t){return 1===Py.findPath(e,t).length}})}var XB={type:"list-item",renderElem:function(e,t,n){_B.set(e,n);var r=e,o=r.level,i=void 0===o?0:o,a=r.ordered,s=void 0!==a&&a,u={margin:"5px 0 5px ".concat(20*i,"px"),display:"flex",alignItems:"flex-start"},l="";if(s){var c=function(e,t){var n=t,r=n.type,o=n.level,i=void 0===o?0:o,a=n.ordered,s=void 0!==a&&a,u=1,l=t,c=Py.findPath(e,l);if(0===c[0])return 1;for(;c[0]>0;){var d=og.previous(c),f=Kh.node(e,d);if(null==f)break;var p=f[0],h=p.level,g=void 0===h?0:h,v=p.type,m=p.ordered;if(v!==r)break;if(g<i)break;if(g===i){if(m!==s)break;u+=1}l=p,c=d}return u}(n,e);l="".concat(c,".")}else l=function(e){void 0===e&&(e=0);var t="";switch(e){case 0:t="•";break;case 1:t="◦";break;default:t="▪"}return t}(i);return BD("div",{style:u},BD("span",{contentEditable:!1,style:{marginRight:"0.5em",color:LB(e)},"data-w-e-reserve":!0},l),BD("span",{style:{flex:"1",wordBreak:"break-word"}},t))}},ZB={renderElems:[XB],editorPlugin:function(e){var t=e.deleteBackward,n=e.handleTab,r=e.normalizeNode,o=e.insertBreak,i=e;return i.insertBreak=function(){var t=ev(Kh.nodes(e,{match:function(e){return Py.checkNodeType(e,"list-item")},universal:!0}),1),n=t[0];return n?""!==n[0].children[0].text?o():void jg.setNodes(i,{type:"paragraph",ordered:void 0,level:void 0}):o()},i.deleteBackward=function(n){var r=i.selection;if(null!=r)if(fg.isExpanded(r))t(n);else{var o=Py.getSelectedNodeByType(i,"list-item");if(null!=o)if(0!==r.focus.offset)t(n);else{var a=o,s=a.level,u=void 0===s?0:s,l=a.ordered,c=void 0!==l&&l;if(u>0){var d=RB(e,o,u-1);d&&d.ordered!==c?jg.setNodes(i,{level:u-1,ordered:!c}):jg.setNodes(i,{level:u-1})}else jg.setNodes(i,{type:"paragraph",ordered:void 0,level:void 0})}else t(n)}else t(n)},i.handleTab=function(){var e,t,r,o,a=i.selection;if(null!=a){if(fg.isCollapsed(a)){var s=Py.getSelectedNodeByType(i,"list-item");if(null==s)return void n();if(0===a.focus.offset){var u=s.level,l=void 0===u?0:u;return void jg.setNodes(i,{level:l+1})}}if(fg.isExpanded(a)){var c=0,d=!1;try{for(var f=Qg(YB(i)),p=f.next();!p.done;p=f.next()){var h=ev(p.value,1)[0];"list-item"===Py.getNodeType(h)?c+=1:d=!0}}catch(t){e={error:t}}finally{try{p&&!p.done&&(t=f.return)&&t.call(f)}finally{if(e)throw e.error}}if(d||c<=1)return void n();try{for(var g=Qg(YB(i)),v=g.next();!v.done;v=g.next()){var m=ev(v.value,2),y=(h=m[0],m[1]),b=h.level;l=void 0===b?0:b;jg.setNodes(i,{level:l+1},{at:y})}}catch(e){r={error:e}}finally{try{v&&!v.done&&(o=g.return)&&o.call(g)}finally{if(r)throw r.error}}}else n()}else n()},i.normalizeNode=function(e){var t=ev(e,2),n=t[0],o=t[1],a=Py.getNodeType(n);return"bulleted-list"!==a&&"numbered-list"!==a||jg.unwrapNodes(i,{at:o}),r([n,o])},i},menus:[VB,WB],elemsToHtml:[HB],parseElemsHtml:[KB,qB]};KE("en",{tableModule:{modal:{border:"Border",borderWidth:"Width",bgColor:"Back color",align:"Text Align",ok:"OK"},color:{default:"Default color",clear:"Clear back color"},borderStyle:{none:"None",solid:"Solid",dotted:"Dotted",dashed:"Dashed",double:"Double",groove:"Groove",ridge:"Ridge",inset:"Inset",outset:"Outset"},deleteCol:"Delete column",deleteRow:"Delete row",deleteTable:"Delete table",widthAuto:"Width auto",insertCol:"Insert column",insertRow:"Insert row",insertTable:"Insert table",header:"Header",mergeCell:"merge cell",splitCell:"split cell",tableProperty:"Table property",cellProperty:"Cell property"}}),KE("zh-CN",{tableModule:{modal:{border:"边框",borderWidth:"宽度",bgColor:"背景色",align:"对齐方式",ok:"确定"},color:{default:"默认颜色",clear:"清除背景色"},borderStyle:{none:"无样式",solid:"实线",dotted:"点状虚线",dashed:"虚线",double:"双线",groove:"凹槽边框",ridge:"菱形边框",inset:"凹边框",outset:"凸边框"},deleteCol:"删除列",deleteRow:"删除行",deleteTable:"删除表格",widthAuto:"宽度自适应",insertCol:"插入列",insertRow:"插入行",insertTable:"插入表格",header:"表头",mergeCell:"合并单元格",splitCell:"拆分单元格",tableProperty:"表格属性",cellProperty:"单元格属性"}});var JB={type:"table",elemToHtml:function(e,t){var n=e,r=n.width,o=void 0===r?"auto":r,i=n.columnWidths,a=n.height,s=void 0===a?"auto":a,u=null==i?void 0:i.map(function(e){return"<col width=".concat(e,"></col>")}).join(""),l=u?'<colgroup contentEditable="false">'.concat(u,"</colgroup>"):"";return'<table style="width: '.concat(o,";table-layout: fixed;height:").concat(s,'">').concat(l,"<tbody>").concat(t,"</tbody></table>")}},QB={type:"table-row",elemToHtml:function(e,t){return"<tr>".concat(t,"</tr>")}},eT={type:"table-cell",elemToHtml:function(e,t){var n=e,r=n.colSpan,o=void 0===r?1:r,i=n.rowSpan,a=void 0===i?1:i,s=n.isHeader,u=void 0!==s&&s,l=n.width,c=void 0===l?"auto":l,d=n.hidden;if(void 0!==d&&d)return"";var f=u?"th":"td";return"<".concat(f,' colSpan="').concat(o,'" rowSpan="').concat(a,'" width="').concat(c,'">').concat(t,"</").concat(f,">")}},tT='<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>',nT={blocks:{td:"table-cell",th:"table-cell",content:"paragraph",tr:"table-row",table:"table",tbody:"table-body"}};function rT(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];var r=nT,o=t.map(function(e){var t;return null===(t=null==r?void 0:r.blocks)||void 0===t?void 0:t[e]});return function(e){return function(e){return!Kh.isEditor(e)&&$h.isElement(e)&&"type"in e}(e)&&o.includes(e.type)}}function oT(e,t){for(var n=ev(t,2),r=n[0],o=n[1],i=[],a=2;a<arguments.length;a++)i[a-2]=arguments[a];var s=ev(eg.common(e,r,o),2),u=s[0],l=s[1];return!!rT.apply(void 0,tv([e],ev(i),!1))(u,l)||!!Kh.above(e,{match:rT.apply(void 0,tv([e],ev(i),!1)),at:l})}function iT(e,t){var n,r;void 0===t&&(t={});var o=[];try{for(var i=Qg(function(e,t){var n,r,o,i,a,s,u,l,c,d,f,p,h,g,v,m,y,b;return void 0===t&&(t={}),Jg(this,function(E){switch(E.label){case 0:if(n=ev(Kh.nodes(e,{match:rT(e,"table"),at:t.at}),1),!(r=n[0]))return[2,[]];o=ev(r,2),i=o[1],E.label=1;case 1:E.trys.push([1,6,7,8]),a=Qg(Kh.nodes(e,{match:rT(e,"table"),at:i})),s=a.next(),E.label=2;case 2:if(s.done)return[3,5];u=ev(s.value,2),l=u[1],c=[];try{for(y=void 0,d=Qg(Kh.nodes(e,{match:rT(e,"tr"),at:l})),f=d.next();!f.done;f=d.next())p=ev(f.value,2),h=p[1],c.push(tv([],ev(Kh.nodes(e,{match:rT(e,"th","td"),at:h})),!1))}catch(e){y={error:e}}finally{try{f&&!f.done&&(b=d.return)&&b.call(d)}finally{if(y)throw y.error}}return[4,c];case 3:E.sent(),E.label=4;case 4:return s=a.next(),[3,2];case 5:return[3,8];case 6:return g=E.sent(),v={error:g},[3,8];case 7:try{s&&!s.done&&(m=a.return)&&m.call(a)}finally{if(v)throw v.error}return[7];case 8:return[2]}})}(e,{at:t.at})),a=i.next();!a.done;a=i.next()){for(var s=a.value,u=[],l=0,c=0;c<s.length;c+=1)s[c]&&(l=Math.max(l,s[c].length));for(c=0;c<s.length;c+=1)if(u[c]||(u[c]=[]),s[c])for(var d=0;d<s[c].length;d+=1)if(s[c][d]&&s[c][d][0]){for(var f=ev(s[c][d],1)[0],p=f.rowSpan,h=void 0===p?1:p,g=f.colSpan,v=void 0===g?1:g,m=d;u[c]&&u[c][m];)m+=1;for(var y=0;y<v;y+=1)for(var b=0;b<h;b+=1){var E=c+b,C=m+y;u[E]||(u[E]=[]),u[E][C]||(u[E][C]=[s[c][d],{rtl:y+1,ltr:v-y,ttb:b+1,btt:h-b}])}}o.push.apply(o,tv([],ev(u),!1))}}catch(e){n={error:e}}finally{try{a&&!a.done&&(r=i.return)&&r.call(i)}finally{if(n)throw n.error}}return o}var aT=function(){function e(e,t){this.x=e,this.y=t}return e.valueOf=function(e,t){return new this(e,t)},e.equals=function(e,t){return e.x===t.x&&e.y===t.y},e}();function sT(e){return e.length?e[0].tagName.toLowerCase():""}function uT(e,t){for(var n="",r=(e.attr("style")||"").split(";"),o=r.length,i=0;i<o;i+=1){var a=r[i];if(a){var s=a.split(":");s[0].trim()===t&&(n=s[1].trim())}}return n}Om&&im.fn&&(im.fn.append=Om),hm&&im.fn&&(im.fn.on=hm),Mm&&im.fn&&(im.fn.focus=Mm),lm&&im.fn&&(im.fn.attr=lm),pm&&im.fn&&(im.fn.val=pm),Sm&&im.fn&&(im.fn.html=Sm),fm&&im.fn&&(im.fn.dataset=fm),am&&im.fn&&(im.fn.addClass=am),sm&&im.fn&&(im.fn.removeClass=sm),Fm&&im.fn&&(im.fn.children=Fm),Dm&&im.fn&&(im.fn.each=Dm),km&&im.fn&&(im.fn.find=km),dm&&im.fn&&(im.fn.data=dm),bm&&im.fn&&(im.fn.hide=bm),Em&&im.fn&&(im.fn.show=Em);var lT=new WeakMap,cT=new WeakMap,dT=function(){function e(){this.title=JE("tableModule.tableProperty"),this.iconSvg='<svg viewBox="0 0 20 20"><path d="M8 2v5h4V2h1v5h5v1h-5v4h.021l-.172.351-1.916.28-.151.027c-.287.063-.54.182-.755.341L8 13v5H7v-5H2v-1h5V8H2V7h5V2h1zm4 6H8v4h4V8z" opacity=".6"/><path d="m15.5 11.5 1.323 2.68 2.957.43-2.14 2.085.505 2.946L15.5 18.25l-2.645 1.39.505-2.945-2.14-2.086 2.957-.43L15.5 11.5zM17 1a2 2 0 0 1 2 2v9.475l-.85-.124-.857-1.736a2.048 2.048 0 0 0-.292-.44L17 3H3v14h7.808l.402.392L10.935 19H3a2 2 0 0 1-2-2V3a2 2 0 0 1 2-2h14z"/></svg>',this.tag="button",this.showModal=!0,this.modalWidth=300,this.menu="table",this.borderStyle=[{value:"none",label:JE("tableModule.borderStyle.none")},{value:"solid",label:JE("tableModule.borderStyle.solid")},{value:"dotted",label:JE("tableModule.borderStyle.dotted")},{value:"dashed",label:JE("tableModule.borderStyle.dashed")},{value:"double",label:JE("tableModule.borderStyle.double")},{value:"groove",label:JE("tableModule.borderStyle.groove")},{value:"ridge",label:JE("tableModule.borderStyle.ridge")},{value:"inset",label:JE("tableModule.borderStyle.inset")},{value:"outset",label:JE("tableModule.borderStyle.outset")}],this.textAlignOptions=[{value:"left",label:JE("justify.left"),svg:'<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>'},{value:"center",label:JE("justify.center"),svg:'<svg viewBox="0 0 1024 1024"><path d="M870.4 793.6v102.4H153.6v-102.4h716.8z m102.4-230.4v102.4H51.2v-102.4h921.6z m-102.4-230.4v102.4H153.6v-102.4h716.8zM972.8 102.4v102.4H51.2V102.4h921.6z"></path></svg>'},{value:"right",label:JE("justify.right"),svg:'<svg viewBox="0 0 1024 1024"><path d="M972.8 793.6v102.4H256v-102.4h716.8z m0-230.4v102.4H51.2v-102.4h921.6z m0-230.4v102.4H256v-102.4h716.8zM972.8 102.4v102.4H51.2V102.4h921.6z"></path></svg>'},{value:"justify",label:JE("justify.justify"),svg:'<svg viewBox="0 0 1024 1024"><path d="M0 64h1024v128H0z m0 192h1024v128H0z m0 192h1024v128H0z m0 192h1024v128H0z m0 192h1024v128H0z"></path></svg>'}]}return e.prototype.getValue=function(e){return""},e.prototype.isActive=function(e){return!1},e.prototype.isDisabled=function(e){return null==Py.getSelectedNodeByType(e,"table")},e.prototype.exec=function(e,t){},e.prototype.getModalContentNode=function(e){return ev(Kh.nodes(e,{match:rT(e,"table")}),1)[0]},e.prototype.getModalPositionNode=function(e){return null},e.prototype.getModalContentElem=function(e){var t=this,n=this.getModalContentNode(e);if(!n)return null;var r=ev(n,2),o=r[0],i=r[1],a=im('<div>\n <label class="babel-container">\n <span>'.concat(JE("tableModule.modal.border"),'</span>\n <span class="babel-container-border">\n <select name="borderStyle">\n ').concat(this.borderStyle.map(function(e){return'<option value="'.concat(e.value,'">').concat(e.label,"</option>")}).join(""),'\n </select>\n <span class="color-group" data-mark="color">\n <span class="color-group-block"></span>\n <input name="borderColor" type="hidden">\n </span>\n <input name="borderWidth" type="number" placeholder="').concat(JE("tableModule.modal.borderWidth"),'">\n </span>\n </label>\n <div class="babel-container">\n <span>').concat(JE("tableModule.modal.bgColor"),'</span>\n <span class="babel-container-background">\n <span class="color-group" data-mark="bgColor">\n <span class="color-group-block"></span>\n <input name="backgroundColor" type="hidden">\n </span>\n </span>\n </div>\n <label class="babel-container">\n <span>').concat(JE("tableModule.modal.align"),'</span>\n <span class="babel-container-align">\n <select name="textAlign">\n ').concat(this.textAlignOptions.map(function(e){return'<option value="'.concat(e.value,'">').concat(e.label,"</option>")}).join(""),'\n </select>\n </span>\n </label>\n <div class="button-container">\n <button type="button">').concat(JE("tableModule.modal.ok"),"</button>\n </div>\n </div>"));a.find("[name]").each(function(e){im(e).val(o[im(e).attr("name")])});var s=function(e,t){t?im(".color-group-block",e).css("background-color",t).empty():im(".color-group-block",e).css("background-color","").html(tT)};return a.find(".color-group").each(function(n){var r=im('[type="hidden"]',n).val()||"";s(n,r);var o=im(n);o.on("click",function(){a.find(".color-group .w-e-drop-panel").hide();var i=o.data("panel");i?i.show():(i=t.getPanelContentElem(e,{mark:o.data("mark"),selectedColor:r,callback:function(e){im('[type="hidden"]',n).val(e||""),s(n,e),i.hide()}}),o.append(i),o.data("panel",i))})}),a.find("button").on("click",function(){var n=Array.from(a.find("[name]")).reduce(function(e,t){return e[im(t).attr("name")]=im(t).val(),e},{}),r=lT.get(e);"cell"===t.menu&&(null==r?void 0:r.length)?r.forEach(function(t){t.forEach(function(t){jg.setNodes(e,n,{at:t[0][1]})})}):jg.setNodes(e,n,{at:i}),setTimeout(function(){e.focus()})}),a[0]},e.prototype.getPanelContentElem=function(e,t){var n=t.mark,r=t.selectedColor,o=t.callback,i=im('<ul class="w-e-panel-content-color"></ul>');i.on("click","li",function(e){var t=e.target;if(t){e.preventDefault(),e.stopPropagation();var n=im(t).attr("data-value");o(n)}});var a=e.getMenuConfig(n).colors;(void 0===a?[]:a).forEach(function(e){var t=im('<div class="color-block" data-value="'.concat(e,'"></div>'));t.css("background-color",e);var n=im('<li data-value="'.concat(e,'"></li>'));r===e&&n.addClass("active"),n.append(t),i.append(n)});var s="";"color"===n&&(s=JE("tableModule.color.default")),"bgColor"===n&&(s=JE("tableModule.color.clear"));var u=im('\n <li data-value="" class="clear">\n '.concat(tT,"\n ").concat(s,"\n </li>\n "));i.prepend(u);var l=im('<div class="w-e-drop-panel"></div>');return l.append(i),l},e}(),fT=function(e){function t(){var t=e.apply(this,tv([],ev(arguments),!1))||this;return t.title=JE("tableModule.cellProperty"),t.iconSvg='<svg viewBox="0 0 20 20"><path d="m11.105 18-.17 1H2.5A1.5 1.5 0 0 1 1 17.5v-15A1.5 1.5 0 0 1 2.5 1h15A1.5 1.5 0 0 1 19 2.5v9.975l-.85-.124-.15-.302V8h-5v4h.021l-.172.351-1.916.28-.151.027c-.287.063-.54.182-.755.341L8 13v5h3.105zM2 12h5V8H2v4zm10-4H8v4h4V8zM2 2v5h5V2H2zm0 16h5v-5H2v5zM13 7h5V2h-5v5zM8 2v5h4V2H8z" opacity=".6"/><path d="m15.5 11.5 1.323 2.68 2.957.43-2.14 2.085.505 2.946L15.5 18.25l-2.645 1.39.505-2.945-2.14-2.086 2.957-.43L15.5 11.5zM13 6a1 1 0 0 1 1 1v3.172a2.047 2.047 0 0 0-.293.443l-.858 1.736-1.916.28-.151.027A1.976 1.976 0 0 0 9.315 14H7a1 1 0 0 1-1-1V7a1 1 0 0 1 1-1h6zm-1 2H8v4h4V8z"/></svg>',t.tag="button",t.showModal=!0,t.modalWidth=300,t.menu="cell",t}return Kg(t,e),t.prototype.getModalContentNode=function(e){return ev(Kh.nodes(e,{match:rT(e,"td")}),1)[0]},t}(dT),pT=function(){function e(){this.title=JE("tableModule.deleteCol"),this.iconSvg='<svg viewBox="0 0 1048 1024"><path d="M327.68 510.976L393.216 445.44v-13.1072L327.68 366.7968V510.976z m327.68-78.4384l65.536-65.536V507.904L655.36 442.368v-9.8304z m393.216 484.9664V0H0v917.504h1048.576z m-65.536-131.072h-262.144v-52.4288l-13.1072 13.1072-52.4288-52.4288v91.7504H393.216v-91.7504l-52.4288 52.4288-13.1072-13.1072v52.4288H65.536V65.536H327.68v121.2416l36.0448-36.0448 29.4912 29.4912V62.2592h262.144V180.224l49.152-49.152 16.384 16.384V62.2592h262.144V786.432z m-294.912-108.1344l-160.5632-160.5632-167.1168 167.1168-78.6432-78.6432 167.1168-167.1168L288.3584 278.528l78.6432-78.6432 160.5632 160.5632 163.84-163.84 78.6432 78.6432-163.84 163.84 160.5632 160.5632-78.6432 78.6432z"></path></svg>',this.tag="button"}return e.prototype.getValue=function(e){return""},e.prototype.isActive=function(e){return!1},e.prototype.isDisabled=function(e){var t=e.selection;return null==t||(!fg.isCollapsed(t)||null==Py.getSelectedNodeByType(e,"table-cell"))},e.prototype.exec=function(e,t){if(!this.isDisabled(e)){var n=ev(Kh.nodes(e,{match:function(e){return Py.checkNodeType(e,"table-cell")},universal:!0}),1),r=ev(n[0],2),o=r[0],i=r[1],a=Py.getParentNode(e,o),s=(null==a?void 0:a.children.length)||0;if(!a||s<=1)jg.removeNodes(e,{mode:"highest"});else if(null!=Py.getParentNode(e,a)){var u=iT(e),l=0;e:for(var c=0;c<u.length;c+=1)for(var d=0;d<u[c].length;d+=1){var f=ev(u[c][d],1),p=ev(f[0],2)[1];if(og.equals(i,p)){l=d;break e}}Kh.withoutNormalizing(e,function(){for(var t,n,r=new Set,o=new Set,i=0;i<u.length;i+=1)if(u[i]&&u[i][l]){var a=ev(u[i][l],2),s=ev(a[0],2)[1],c=a[1],d=c.rtl,f=c.ltr,p=c.ttb,h=c.btt,g=s.join(",");if(d>1||f>1||p>1||h>1){var v=i-(p-1),m=l-(d-1);if(v<0||v>=u.length||!u[v]||!u[v][m])continue;var y=ev(u[v][m],1),b=ev(y[0],2),E=b[0],C=b[1],D=C.join(",");if(!o.has(D)){o.add(D);var w=E.rowSpan,S=void 0===w?1:w,A=E.colSpan,x=void 0===A?1:A,O=Math.max(x-1,1);jg.setNodes(e,{rowSpan:S,colSpan:O},{at:C})}}else r.add(g)}var N=Array.from(r);N.sort(function(e,t){var n=e.split(",").map(Number),r=t.split(",").map(Number);return n[n.length-2]!==r[r.length-2]?r[r.length-2]-n[n.length-2]:r[r.length-1]-n[n.length-1]});try{for(var B=Qg(N),T=B.next();!T.done;T=B.next()){var k=T.value.split(",").map(Number);try{Kh.hasPath(e,k)&&jg.removeNodes(e,{at:k})}catch(e){console.warn("删除单元格失败:",k,e)}}}catch(e){t={error:e}}finally{try{T&&!T.done&&(n=B.return)&&n.call(B)}finally{if(t)throw t.error}}var F=ev(Kh.nodes(e,{match:function(e){return Py.checkNodeType(e,"table")},universal:!0}),1),I=F[0];if(I){var P=ev(I,2),_=P[0],L=P[1],R=_.columnWidths,M=tv([],ev(void 0===R?[]:R),!1);M.splice(l,1),jg.setNodes(e,{columnWidths:M},{at:L})}})}}},e}(),hT=function(){function e(){this.title=JE("tableModule.deleteRow"),this.iconSvg='<svg viewBox="0 0 1048 1024"><path d="M907.6736 586.5472L747.1104 425.984l163.84-163.84-78.6432-78.6432-163.84 163.84L507.904 186.7776 429.2608 262.144l163.84 163.84-167.1168 167.1168 78.6432 78.6432 167.1168-167.1168 160.5632 160.5632 75.3664-78.6432zM0 917.504V0h1048.576v917.504H0z m983.04-327.68h-22.9376l-65.536-65.536H983.04V327.68h-91.7504l65.536-65.536h26.2144V65.536H65.536v196.608h317.8496l65.536 65.536H65.536v196.608h380.1088l-65.536 65.536H65.536v196.608H983.04v-196.608z"></path></svg>',this.tag="button"}return e.prototype.getValue=function(e){return""},e.prototype.isActive=function(e){return!1},e.prototype.isDisabled=function(e){var t=e.selection;return null==t||(!fg.isCollapsed(t)||null==Py.getSelectedNodeByType(e,"table-row"))},e.prototype.exec=function(e,t){if(!this.isDisabled(e)){var n=ev(Kh.nodes(e,{match:function(e){return Py.checkNodeType(e,"table-row")},universal:!0}),1),r=ev(n[0],2),o=r[0],i=r[1],a=Py.getParentNode(e,o);if(((null==a?void 0:a.children.length)||0)<=1)jg.removeNodes(e,{mode:"highest"});else{var s=ev(Kh.nodes(e,{match:function(e){return Py.checkNodeType(e,"table-cell")},universal:!0}),1),u=ev(s[0],2)[1],l=iT(e),c=0;e:for(var d=0;d<l.length;d+=1)for(var f=0;f<l[d].length;f+=1){var p=ev(l[d][f],1),h=ev(p[0],2)[1];if(og.equals(u,h)){c=d;break e}}Kh.withoutNormalizing(e,function(){for(var t,n,r=[],o=0;o<l[c].length;o+=1){var a=ev(l[c][o],2),s=ev(a[0],1)[0].hidden,u=a[1],d=u.ttb,f=u.btt,p=u.rtl;if(d>1||f>1){var h=c-(d-1);if(h<0||h>=l.length||!l[h]||!l[h][o])continue;var g=ev(l[h][o],1),v=ev(g[0],2),m=v[0],y=v[1],b=m,E=b.rowSpan,C=void 0===E?1:E,D=b.colSpan,w=void 0===D?1:D;if(s)jg.setNodes(e,{rowSpan:Math.max(C-1,1),colSpan:w},{at:y});else if(1===d&&1===p){if(c+1<l.length&&C>1){var S={type:"table-cell",rowSpan:C-1,colSpan:w,hidden:!1,children:b.children.map(function(e){return Yg({},e)})};b.isHeader&&(S.isHeader=b.isHeader),b.width&&(S.width=b.width),b.backgroundColor&&(S.backgroundColor=b.backgroundColor),b.borderWidth&&(S.borderWidth=b.borderWidth),b.borderStyle&&(S.borderStyle=b.borderStyle),b.borderColor&&(S.borderColor=b.borderColor),b.textAlign&&(S.textAlign=b.textAlign),r.push({cell:S,columnIndex:o})}else jg.setNodes(e,{rowSpan:Math.max(C-1,1),colSpan:w},{at:y})}else jg.setNodes(e,{rowSpan:Math.max(C-1,1),colSpan:w},{at:y})}}if(jg.removeNodes(e,{at:i}),r.length>0){var A=i;try{r.sort(function(e,t){return e.columnIndex-t.columnIndex});try{for(var x=Qg(r),O=x.next();!O.done;O=x.next()){var N=O.value,B=N.cell,T=N.columnIndex;try{var k=tv(tv([],ev(A),!1),[T],!1);jg.insertNodes(e,B,{at:k})}catch(t){try{var F=ev(Kh.node(e,A),1)[0].children.length,I=tv(tv([],ev(A),!1),[F],!1);jg.insertNodes(e,B,{at:I})}catch(e){console.warn("插入新单元格失败:",e)}}}}catch(e){t={error:e}}finally{try{O&&!O.done&&(n=x.return)&&n.call(x)}finally{if(t)throw t.error}}}catch(e){console.warn("插入新单元格失败:",e)}}})}}},e}(),gT=function(){function e(){this.title=JE("tableModule.deleteTable"),this.iconSvg='<svg viewBox="0 0 1024 1024"><path d="M826.8032 356.5312c-19.328 0-36.3776 15.6928-36.3776 35.0464v524.2624c0 19.328-16 34.56-35.328 34.56H264.9344c-19.328 0-35.5072-15.3088-35.5072-34.56V390.0416c0-19.328-14.1568-35.0464-33.5104-35.0464s-33.5104 15.6928-33.5104 35.0464V915.712c0 57.9328 44.6208 108.288 102.528 108.288H755.2c57.9328 0 108.0832-50.4576 108.0832-108.288V391.4752c-0.1024-19.2512-17.1264-34.944-36.48-34.944z" p-id="9577"></path><path d="M437.1712 775.7568V390.6048c0-19.328-14.1568-35.0464-33.5104-35.0464s-33.5104 15.616-33.5104 35.0464v385.152c0 19.328 14.1568 35.0464 33.5104 35.0464s33.5104-15.7184 33.5104-35.0464zM649.7024 775.7568V390.6048c0-19.328-17.0496-35.0464-36.3776-35.0464s-36.3776 15.616-36.3776 35.0464v385.152c0 19.328 17.0496 35.0464 36.3776 35.0464s36.3776-15.7184 36.3776-35.0464zM965.0432 217.0368h-174.6176V145.5104c0-57.9328-47.2064-101.76-104.6528-101.76h-350.976c-57.8304 0-105.3952 43.8528-105.3952 101.76v71.5264H54.784c-19.4304 0-35.0464 14.1568-35.0464 33.5104 0 19.328 15.616 33.5104 35.0464 33.5104h910.3616c19.328 0 35.0464-14.1568 35.0464-33.5104 0-19.3536-15.6928-33.5104-35.1488-33.5104z m-247.3728 0H297.3952V145.5104c0-19.328 18.2016-34.7648 37.4272-34.7648h350.976c19.1488 0 31.872 15.1296 31.872 34.7648v71.5264z"></path></svg>',this.tag="button"}return e.prototype.getValue=function(e){return""},e.prototype.isActive=function(e){return!1},e.prototype.isDisabled=function(e){return null==e.selection||null==Py.getSelectedNodeByType(e,"table")},e.prototype.exec=function(e,t){this.isDisabled(e)||jg.removeNodes(e,{mode:"highest"})},e}(),vT=function(){function e(){this.title=JE("tableModule.widthAuto"),this.iconSvg='<svg viewBox="0 0 1228 1024"><path d="M862.514337 563.200461H404.581995v121.753478a13.311987 13.311987 0 0 1-6.655993 11.468789 10.23999 10.23999 0 0 1-12.083188-1.433599l-204.799795-179.199821a13.721586 13.721586 0 0 1 0-20.479979l204.799795-179.302221a10.23999 10.23999 0 0 1 12.185588-1.535998 13.209587 13.209587 0 0 1 6.553593 11.673588v115.097485h457.932342V319.693504a11.571188 11.571188 0 0 1 18.841582-10.239989l204.799795 179.19982a13.721586 13.721586 0 0 1 0 20.47998l-204.799795 179.199821a10.23999 10.23999 0 0 1-12.185588 1.535998 13.311987 13.311987 0 0 1-6.655994-11.571188V563.200461zM136.499064 14.951409v993.893406a15.257585 15.257585 0 0 1-15.155185 15.052785H15.155185A15.155185 15.155185 0 0 1 0 1008.844815V14.951409a15.257585 15.257585 0 0 1 15.155185-15.052785h106.086294a15.155185 15.155185 0 0 1 15.257585 15.155185zM1228.798771 14.951409v993.893406a15.257585 15.257585 0 0 1-15.155185 15.052785h-106.188693a15.155185 15.155185 0 0 1-15.155185-15.052785V14.951409a15.257585 15.257585 0 0 1 15.155185-15.052785h106.086293A15.155185 15.155185 0 0 1 1228.798771 15.053809z"></path></svg>',this.tag="button"}return e.prototype.getValue=function(e){var t=Py.getSelectedNodeByType(e,"table");return!!t&&("100%"===t.width||"auto"===t.width)},e.prototype.isActive=function(e){return!!this.getValue(e)},e.prototype.isDisabled=function(e){var t=e.selection;return null==t||(!fg.isCollapsed(t)||null==Py.getSelectedNodeByType(e,"table"))},e.prototype.exec=function(e,t){if(!this.isDisabled(e)){var n={width:t?"auto":"100%"};jg.setNodes(e,n,{mode:"highest"})}},e}();function mT(e){var t=e.children||[];return 0===t.length?[]:(t[0]||{}).children||[]}function yT(e){return mT(e).every(function(e){return!!e.isHeader})}var bT=function(){function e(){this.title=JE("tableModule.insertCol"),this.iconSvg='<svg viewBox="0 0 1048 1024"><path d="M327.68 193.3312v186.7776H140.9024v91.7504H327.68v186.7776h88.4736V471.8592h190.0544V380.1088H416.1536V193.3312zM0 917.504V0h1048.576v917.504H0zM655.36 65.536H65.536v720.896H655.36V65.536z m327.68 0h-262.144v196.608h262.144V65.536z m0 262.144h-262.144v196.608h262.144V327.68z m0 262.144h-262.144v196.608h262.144v-196.608z"></path></svg>',this.tag="button"}return e.prototype.getValue=function(e){return""},e.prototype.isActive=function(e){return!1},e.prototype.isDisabled=function(e){var t=e.selection;if(null==t)return!0;if(!fg.isCollapsed(t))return!0;var n=Py.getSelectedNodeByType(e,"table");if(null==n)return!0;try{var r=ev(Kh.nodes(e,{match:function(e){return Py.checkNodeType(e,"table-cell")},universal:!0}),1),o=r[0];if(!o)return!0;for(var i=ev(o,2)[1],a=iT(e),s=-1,u=0;u<a.length;u+=1){for(var l=0;l<a[u].length;l+=1){var c=ev(a[u][l],1),d=ev(c[0],2)[1];if(og.equals(i,d)){s=l;break}}if(-1!==s)break}if(-1===s)return!0;var f=n.columnWidths,p=(void 0===f?[]:f)[s];if(p&&p<20)return!0}catch(e){return!0}return!1},e.prototype.exec=function(e,t){if(!this.isDisabled(e)){var n=ev(Kh.nodes(e,{match:function(e){return Py.checkNodeType(e,"table-cell")},universal:!0}),1),r=ev(n[0],2),o=r[0],i=r[1],a=Py.getParentNode(e,o);if(null!=a){var s=Py.getParentNode(e,a);if(null!=s){for(var u=iT(e),l=0,c=0;c<u.length;c+=1)for(var d=0;d<u[c].length;d+=1){var f=ev(u[c][d],1),p=ev(f[0],2)[1];if(og.equals(i,p)){l=d;break}}Kh.withoutNormalizing(e,function(){for(var t=new Set,n=new Set,r=0;r<u.length;r+=1)if(u[r]&&u[r][l]){var o=ev(u[r][l],2);ev(o[0],1);var i=o[1],a=i.rtl,c=i.ltr,d=i.ttb,f=i.btt;if(a>1||c>1||d>1||f>1){var p=r-(d-1),h=l-(a-1);if(p<0||p>=u.length||!u[p]||!u[p][h])continue;var g=ev(u[p][h],1),v=ev(g[0],2),m=v[0],y=v[1],b=y.join(",");if(t.has(b))n.add(r);else{t.add(b);var E=m.rowSpan,C=void 0===E?1:E,D=m.colSpan,w=(void 0===D?1:D)+1;m.hidden||jg.setNodes(e,{colSpan:w},{at:y});for(var S=0;S<C;S+=1)n.add(p+S)}}}for(r=0;r<u.length;r+=1)if(!n.has(r)&&u[r]&&u[r][l]){var A={type:"table-cell",children:[{text:""}]};0===r&&yT(s)&&(A.isHeader=!0);var x=ev(u[r][l],1),O=ev(x[0],2)[1];jg.insertNodes(e,A,{at:O})}var N=ev(Kh.nodes(e,{match:function(e){return Py.checkNodeType(e,"table")},universal:!0}),1),B=N[0];if(B){var T=ev(B,2),k=T[0],F=T[1],I=k.columnWidths,P=void 0===I?[]:I,_=tv([],ev(P),!1),L=e.getMenuConfig("insertTable").minWidth,R=void 0===L?60:L,M=P[l]||parseInt(R,10)||60,j=Math.floor(M/2),H=M-j;_.splice(l,0,j),_[l+1]=H,jg.setNodes(e,{columnWidths:_},{at:F})}})}}}},e}(),ET=function(){function e(){this.title=JE("tableModule.insertRow"),this.iconSvg='<svg viewBox="0 0 1048 1024"><path d="M707.7888 521.0112h-147.456v-147.456H488.2432v147.456h-147.456v68.8128h147.456v147.456h72.0896v-147.456h147.456zM0 917.504V0h1048.576v917.504H0zM327.68 65.536H65.536v196.608H327.68V65.536z m327.68 0H393.216v196.608h262.144V65.536z m327.68 0h-262.144v196.608h262.144V65.536z m0 258.8672H65.536v462.0288H983.04V324.4032z"></path></svg>',this.tag="button"}return e.prototype.getValue=function(e){return""},e.prototype.isActive=function(e){return!1},e.prototype.isDisabled=function(e){var t=e.selection;return null==t||(!fg.isCollapsed(t)||null==Py.getSelectedNodeByType(e,"table"))},e.prototype.exec=function(e,t){var n;if(!this.isDisabled(e)){var r=ev(Kh.nodes(e,{match:function(e){return Py.checkNodeType(e,"table-cell")},universal:!0}),1),o=ev(r[0],2)[1],i=iT(e),a=0;e:for(var s=0;s<i.length;s+=1)for(var u=0;u<i[s].length;u+=1){var l=ev(i[s][u],1),c=ev(l[0],2)[1];if(og.equals(o,c)){a=s;break e}}var d=(null===(n=i[a])||void 0===n?void 0:n.length)||0;0!==d&&Kh.withoutNormalizing(e,function(){for(var t=a+1,n=t>=0&&t<i.length,r=[],s=0;n&&s<i[a].length;s+=1){var u=ev(i[a][s],2)[1],l=u.ttb,c=u.btt;if(l>1||c>1){var f=a-(l-1);if(f<0||f>=i.length||!i[f]||!i[f][s])continue;var p=ev(i[f][s],1),h=ev(p[0],2),g=h[0],v=h[1],m=g.rowSpan||1;r.push(s),g.hidden||jg.setNodes(e,{rowSpan:m+1},{at:v})}}for(var y={type:"table-row",children:[]},b=0;b<d;b+=1)if(!r.includes(b)){y.children.push({type:"table-cell",children:[{text:""}]})}var E=og.parent(o),C=og.next(E);jg.insertNodes(e,y,{at:C})})}},e}();var CT=function(){function e(){this.title=JE("tableModule.insertTable"),this.iconSvg='<svg viewBox="0 0 1024 1024"><path d="M0 64v896h1024V64H0z m384 576v-192h256v192h-256z m256 64v192h-256v-192h256z m0-512v192h-256V192h256zM320 192v192H64V192h256z m-256 256h256v192H64v-192z m640 0h256v192h-256v-192z m0-64V192h256v192h-256zM64 704h256v192H64v-192z m640 192v-192h256v192h-256z"></path></svg>',this.tag="button",this.showDropPanel=!0,this.$content=null}return e.prototype.getValue=function(e){return""},e.prototype.isActive=function(e){return!1},e.prototype.exec=function(e,t){},e.prototype.isDisabled=function(e){var t=e.selection;return null==t||(!fg.isCollapsed(t)||!!Py.getSelectedElems(e).some(function(t){var n=Py.getNodeType(t);return"pre"===n||("table"===n||("list-item"===n||!!e.isVoid(t)))}))},e.prototype.getPanelContentElem=function(e){var t=this;if(this.$content)return this.$content[0];for(var n=im('<div class="w-e-panel-content-table"></div>'),r=im("<span>0 × 0</span>"),o=im("<table></table>"),i=0;i<10;i+=1){for(var a=im("<tr></tr>"),s=0;s<10;s+=1){var u=im("<td></td>");u.attr("data-x",s.toString()),u.attr("data-y",i.toString()),a.append(u),u.on("mouseenter",function(e){var t=e.target;if(null!=t){var n=im(t).dataset(),i=n.x,a=n.y;r[0].innerHTML="".concat(i+1," × ").concat(a+1),o.children().each(function(e){im(e).children().each(function(e){var t=im(e),n=t.dataset(),r=n.x,o=n.y;r<=i&&o<=a?t.addClass("active"):t.removeClass("active")})})}}),u.on("click",function(n){n.preventDefault();var r=n.target;if(null!=r){var o=im(r).dataset(),i=o.x,a=o.y;t.insertTable(e,a+1,i+1)}})}o.append(a)}return n.append(o),n.append(r),this.$content=n,n[0]},e.prototype.insertTable=function(e,t,n){var r=parseInt(t,10),o=parseInt(n,10);if(r&&o&&!(r<=0||o<=0)){if(Py.isSelectedEmptyParagraph(e)&&jg.removeNodes(e,{mode:"highest"}),0===e.children.length){jg.insertNodes(e,{type:"paragraph",children:[{text:""}]},{mode:"highest"})}var i=function(e,t,n){for(var r,o=[],i=e.getMenuConfig("insertTable"),a=i.minWidth,s=void 0===a?60:a,u=i.tableFullWidth,l=i.tableHeader,c=Array(n).fill(parseInt(s,10)||60),d=0;d<t;d+=1){for(var f=[],p=0;p<n;p+=1){var h={type:"table-cell",children:[{text:""}]};0===d&&(h.isHeader=null===(r=null==l?void 0:l.selected)||void 0===r||r),f.push(h)}o.push({type:"table-row",children:f})}return{type:"table",width:(null==u?void 0:u.selected)?"100%":"auto",children:o,columnWidths:c}}(e,r,o);jg.insertNodes(e,i,{mode:"highest"})}},e}(),DT={isInTable:function(e,t){return void 0===t&&(t={}),!!ev(Kh.nodes(e,{match:rT(e,"table"),at:t.at}),1)[0]},selection:function(e){var t,n,r,o,i,a,s,u;return Jg(this,function(l){switch(l.label){case 0:t=lT.get(e),n=0,l.label=1;case 1:if(!(t&&n<t.length))return[3,4];for(r=[],o=0;o<t[n].length;o+=1)i=ev(t[n][o],2),a=i[0],s=i[1],u=s.ltr,1===s.ttb&&r.push(a),o+=u-1;return[4,r];case 2:l.sent(),l.label=3;case 3:return n+=1,[3,1];case 4:return[2]}})},unselect:function(e){cT.delete(e),lT.delete(e)},isSelected:function(e,t){var n=cT.get(e);return!!n&&n.has(t)}},wT=function(){function e(){this.title=JE("tableModule.mergeCell"),this.iconSvg='<svg viewBox="0 0 1024 1024"><path d="M482.2 508.4 331.3 389c-3-2.4-7.3-.2-7.3 3.6V478H184V184h204v128c0 2.2 1.8 4 4 4h60c2.2 0 4-1.8 4-4V144c0-15.5-12.5-28-28-28H144c-15.5 0-28 12.5-28 28v736c0 15.5 12.5 28 28 28h284c15.5 0 28-12.5 28-28V712c0-2.2-1.8-4-4-4h-60c-2.2 0-4 1.8-4 4v128H184V546h140v85.4c0 3.8 4.4 6 7.3 3.6l150.9-119.4c2.4-1.8 2.4-5.4 0-7.2zM880 116H596c-15.5 0-28 12.5-28 28v168c0 2.2 1.8 4 4 4h60c2.2 0 4-1.8 4-4V184h204v294H700v-85.4c0-3.8-4.3-6-7.3-3.6l-151 119.4c-2.3 1.8-2.3 5.3 0 7.1l151 119.5c2.9 2.3 7.3.2 7.3-3.6V546h140v294H636V712c0-2.2-1.8-4-4-4h-60c-2.2 0-4 1.8-4 4v168c0 15.5 12.5 28 28 28h284c15.5 0 28-12.5 28-28V144c0-15.5-12.5-28-28-28z"/></svg>',this.tag="button"}return e.prototype.getValue=function(e){return""},e.prototype.isActive=function(e){return!1},e.prototype.isDisabled=function(e){return!this.canMerge(e)},e.prototype.exec=function(e,t){this.isDisabled(e)||(this.merge(e),DT.unselect(e))},e.prototype.canMerge=function(e){var t=lT.get(e);if(!t||!t.length)return!1;var n=ev(t[t.length-1][t[t.length-1].length-1],1),r=ev(n[0],2)[1],o=ev(t[0][0],1);return!!oT(e,[ev(o[0],2)[1],r],"table")},e.prototype.merge=function(e){if(this.canMerge(e)){var t=lT.get(e);if(t&&t.length){var n=ev(t[0][0],1),r=ev(n[0],2)[1],o=ev(eg.children(e,r,{reverse:!0}),1),i=ev(o[0],2)[1];Kh.withoutNormalizing(e,function(){for(var n,o,a,s,u,l,c=new Map,d=[],f=1/0,p=-1/0,h=1/0,g=-1/0,v=0;v<t.length;v+=1)for(var m=0;m<t[v].length;m+=1){var y=ev(t[v][m],2),b=ev(y[0],2),E=b[0],C=b[1],D=y[1].ttb,w=C.join(",");if(1===D&&!c.has(w)){c.set(w,{path:C,x:v,y:m,element:E});var S=E.rowSpan,A=void 0===S?1:S,x=E.colSpan,O=v,N=v+A-1,B=m,T=m+(void 0===x?1:x)-1;f=Math.min(f,O),p=Math.max(p,N),h=Math.min(h,B),g=Math.max(g,T)}}var k=p-f+1,F=g-h+1;try{for(var I=Qg(c),P=I.next();!P.done;P=I.next()){C=ev(P.value,2)[1].path;og.equals(r,C)||d.push(C)}}catch(e){n={error:e}}finally{try{P&&!P.done&&(o=I.return)&&o.call(I)}finally{if(n)throw n.error}}d.sort(function(e,t){for(var n=0;n<Math.min(e.length,t.length);n+=1)if(e[n]!==t[n])return t[n]-e[n];return t.length-e.length});try{for(var _=Qg(d),L=_.next();!L.done;L=_.next()){C=L.value;try{if(!Kh.hasPath(e,C))continue;try{for(var R=(u=void 0,Qg(eg.children(e,C,{reverse:!0}))),M=R.next();!M.done;M=R.next()){var j=ev(M.value,2)[1];jg.moveNodes(e,{to:og.next(i),at:j})}}catch(e){u={error:e}}finally{try{M&&!M.done&&(l=R.return)&&l.call(R)}finally{if(u)throw u.error}}jg.removeNodes(e,{at:C})}catch(e){}}}catch(e){a={error:e}}finally{try{L&&!L.done&&(s=_.return)&&s.call(_)}finally{if(a)throw a.error}}jg.setNodes(e,{rowSpan:k,colSpan:F},{at:r})})}}},e}(),ST=function(){function e(){this.title=JE("tableModule.splitCell"),this.iconSvg='<svg viewBox="0 0 1024 1024"><path d="M362.667 494.933v53.334l25.6-25.6zm0-241.066L460.8 352V78.933H57.6v98.134h305.067zm0 535.466v57.6H57.6v98.134h403.2V691.2zM661.333 494.933v53.334l-25.6-25.6zm0-241.066L563.2 352V78.933h403.2v98.134H661.333zm0 535.466v57.6H966.4v98.134H563.2V691.2z"/><path d="M753.067 341.333 693.333 281.6 512 460.8 330.667 281.6l-59.734 59.733 181.334 181.334L270.933 704l59.734 59.733L512 582.4l181.333 181.333L753.067 704 571.733 522.667z"/></svg>',this.tag="button"}return e.prototype.getValue=function(e){return""},e.prototype.isActive=function(e){return!1},e.prototype.isDisabled=function(e){var t=ev(Kh.nodes(e,{match:function(e){return Py.checkNodeType(e,"table-cell")}}),1),n=t[0];if(!n)return!0;var r=ev(n,1)[0],o=r.rowSpan,i=void 0===o?1:o,a=r.colSpan;return!(i>1||(void 0===a?1:a)>1)},e.prototype.exec=function(e,t){this.isDisabled(e)||this.split(e)},e.prototype.split=function(e,t){void 0===t&&(t={});var n=ev(Kh.nodes(e,{match:rT(e,"table","th","td"),at:t.at}),2),r=n[0],o=n[1];if(r&&o){var i=yT(ev(r,1)[0]),a=ev(o,2),s=a[0],u=a[1],l=s.rowSpan,c=void 0===l?1:l,d=s.colSpan,f=void 0===d?1:d;1===c&&1===f||Kh.withoutNormalizing(e,function(){jg.setNodes(e,{rowSpan:1,colSpan:1},{at:u});for(var t=1;t<f;t+=1){var n={type:"table-cell",children:[{text:""}]};0===u[u.length-2]&&i&&(n.isHeader=!0);var r=u.slice(0,-1),o=u[u.length-1]+t,a=tv(tv([],ev(r),!1),[o],!1);try{jg.insertNodes(e,n,{at:a})}catch(t){try{var s=ev(Kh.node(e,r),1)[0].children.length,l=tv(tv([],ev(r),!1),[s],!1);jg.insertNodes(e,n,{at:l})}catch(e){console.warn("插入同行单元格失败: ".concat(e instanceof Error?e.message:String(e)))}}}for(var d=1;d<c;d+=1){var p=u[u.length-2]+d,h=tv(tv([],ev(u.slice(0,-2)),!1),[p],!1);try{var g=ev(Kh.node(e,h),1)[0];if(!g){console.warn("目标行 ".concat(p," 不存在"));continue}for(t=0;t<f;t+=1){n={type:"table-cell",children:[{text:""}]},o=u[u.length-1]+t,a=tv(tv([],ev(h),!1),[o],!1);try{var v=g.children.length;if(o>=v){var m=tv(tv([],ev(h),!1),[v],!1);jg.insertNodes(e,n,{at:m})}else jg.insertNodes(e,n,{at:a})}catch(t){try{var y=g.children.length;l=tv(tv([],ev(h),!1),[y],!1);jg.insertNodes(e,n,{at:l})}catch(e){console.warn("插入单元格到第".concat(d,"行失败: ").concat(e instanceof Error?e.message:String(e)))}}}}catch(e){console.warn("处理第".concat(d,"行时出错: ").concat(e instanceof Error?e.message:String(e)))}}})}},e}(),AT=function(){function e(){this.title=JE("tableModule.header"),this.iconSvg='<svg viewBox="0 0 1024 1024"><path d="M704 128l-64 0L384 128 320 128 0 128l0 256 0 64 0 192 0 64 0 256 320 0 64 0 256 0 64 0 320 0 0-256 0-64L1024 448 1024 384 1024 128 704 128zM640 640 384 640 384 448l256 0L640 640zM64 448l256 0 0 192L64 640 64 448zM320 896 64 896l0-192 256 0L320 896zM640 896 384 896l0-192 256 0L640 896zM960 896l-256 0 0-192 256 0L960 896zM960 640l-256 0L704 448l256 0L960 640z"></path></svg>',this.tag="button"}return e.prototype.getValue=function(e){var t=Py.getSelectedNodeByType(e,"table");return null!=t&&yT(t)},e.prototype.isActive=function(e){return!!this.getValue(e)},e.prototype.isDisabled=function(e){var t=e.selection;return null==t||(!fg.isCollapsed(t)||null==Py.getSelectedNodeByType(e,"table"))},e.prototype.exec=function(e,t){if(!this.isDisabled(e)){var n=!t,r=Py.getSelectedNodeByType(e,"table");if(null!=r)mT(r).forEach(function(t){return jg.setNodes(e,{isHeader:n},{at:Py.findPath(e,t)})})}},e}(),xT={key:"insertTable",factory:function(){return new CT}},OT={key:"deleteTable",factory:function(){return new gT}},NT={key:"insertTableRow",factory:function(){return new ET}},BT={key:"deleteTableRow",factory:function(){return new hT}},TT={key:"insertTableCol",factory:function(){return new bT}},kT={key:"deleteTableCol",factory:function(){return new pT}},FT={key:"tableHeader",factory:function(){return new AT}},IT={key:"tableFullWidth",factory:function(){return new vT}},PT={key:"mergeTableCell",factory:function(){return new wT}},_T={key:"splitTableCell",factory:function(){return new ST}},LT={key:"setTableProperty",factory:function(){return new dT}},RT={key:"setTableCellProperty",factory:function(){return new fT}};var MT={selector:"td:not([data-w-e-type]),th:not([data-w-e-type])",parseElemHtml:function(e,t,n){var r=im(e);0===(t=t.filter(function(e){return"paragraph"===Py.getNodeType(e)||(!!Cg.isText(e)||!!n.isInline(e))})).length&&(t=[{text:r.text().replace(/\s+/gm," ")}]);var o=parseInt(r.attr("colSpan")||"1",10),i=parseInt(r.attr("rowSpan")||"1",10),a="none"===uT(r,"display"),s=r.attr("width")||"auto";return{type:"table-cell",isHeader:"th"===sT(r),colSpan:o,rowSpan:i,width:s,children:t,hidden:a}}};var jT={selector:"tr:not([data-w-e-type])",parseElemHtml:function(e,t,n){for(var r=[],o=0;o<t.length;o+=1){var i=t[o];if("table-cell"===Py.getNodeType(i)){var a=i;if(a.hidden)continue;r.push(a)}}return{type:"table-row",children:r}}};var HT,zT={selector:"table:not([data-w-e-type])",parseElemHtml:function(e,t,n){var r,o,i=im(e),a="auto";"100%"===uT(i,"width")&&(a="100%"),"100%"===i.attr("width")&&(a="100%");var s={type:"table",width:a,height:parseInt(uT(i,"height")||"0",10),children:t.filter(function(e){return"table-row"===Py.getNodeType(e)})},u=(null===(r=i.find("tr")[0])||void 0===r?void 0:r.children)||[],l=(null===(o=i.find("colgroup")[0])||void 0===o?void 0:o.children)||null,c=t[t.length-1].children.length;if(l&&l.length===c)s.columnWidths=Array.from(l).map(function(e){return parseInt(e.getAttribute("width"),10)});else if(u.length>0){var d=[];Array.from(u).forEach(function(e){var t=parseInt(im(e).attr("colSpan")||"1",10),n=parseInt(uT(im(e),"width")||"90",10);d.push(n);for(var r=1;r<t;r+=1)d.push(90)}),s.columnWidths=d}return s}},$T=null===(HT=null===window||void 0===window?void 0:window.getComputedStyle(document.documentElement))||void 0===HT?void 0:HT.getPropertyValue("--w-e-textarea-border-color");function UT(e){var t=e.selection;if(null==t)return!1;var n=ev(Kh.nodes(e,{match:function(e){return Py.checkNodeType(e,"table-cell")}}),1),r=n[0];if(r){var o=ev(r,2)[1],i=Kh.start(e,o);if(ug.equals(t.anchor,i))return!0}return!1}function VT(e,t){var n=t.offset;if(0===n)return!1;var r=Kh.node(e,t);if(!Cg.isText(r[0]))return!1;var o=eg.string(r[0]);return!(n>=o.length)&&("\n"===o[n-1]&&"\r"===o[n])}function WT(e,t,n){var r=e.selection;if(null==r||"line"===t)return!1;var o=ev(Kh.nodes(e,{match:function(e){return Py.checkNodeType(e,"table-cell")}}),1),i=o[0],a=r.anchor;if("backward"===n&&0===r.anchor.offset&&(a=Kh.before(e,r)),"forward"===n&&Kh.isEnd(e,r.anchor,r.anchor.path)&&(a=Kh.after(e,r)),null==a)return!1;var s=Kh.above(e,{at:a,match:function(e){return Py.checkNodeType(e,"table-cell")}});if(null==s||null==i||!og.equals(s[1],i[1]))return!1;var u=Kh.node(e,a);if(!Cg.isText(u[0])||u[0].text.length<2)return!1;var l="backward"===n?[a.offset-2,a.offset]:[a.offset,a.offset+2],c=eg.string(u[0]);return"\n\r"===c.slice.apply(c,tv([],ev(l),!1))?(jg.insertText(e,c.slice(0,l[0])+c.slice(l[1]),{at:{anchor:Kh.start(e,a.path),focus:Kh.end(e,a.path)}}),!0):!!VT(e,a)&&(jg.insertText(e,c.slice(0,r.anchor.offset-1)+c.slice(r.anchor.offset+1),{at:{anchor:Kh.start(e,a.path),focus:Kh.end(e,a.path)}}),!0)}function GT(e,t){var n=Kh.nodes(e,{at:t,match:function(e){return"table"===Py.getNodeType(e)}});return!!tv([],ev(n),!1).find(function(){return!0})}var qT={selector:"table",preParseHtml:function(e){var t=im(e);if("table"!==sT(t))return e;var n=t.find("tbody");if(0===n.length)return e;var r=t.find("tr");t.append(r),n.remove();for(var o=t.find("td, th"),i=0;i<o.length;i+=1){var a=(u=im(o[i])).attr("style");if(a){/display\s*:\s*none/i.test(a)&&u.remove()}}var s=t.find("td, th");for(i=0;i<s.length;i+=1){var u,l=(u=im(s[i])).html()||"";l=(l=(l=l.replace(/<o:p[^>]*>[\s\S]*?<\/o:p>/gi,"")).replace(/<\/o:p>/gi,"")).replace(/<p[^>]*>([\s\S]*?)<\/p>/gi,function(e,t){var n=t.trim();return n&&" "!==n?t:""}),u.html(l)}return t[0]}};function KT(e){var t,n,r=[],o=0;try{for(var i=Qg(e),a=i.next();!a.done;a=i.next()){o+=a.value,r.push(o)}}catch(e){t={error:e}}finally{try{a&&!a.done&&(n=i.return)&&n.call(i)}finally{if(t)throw t.error}}return r}function YT(e){var t,n,r=[],o=e.reduce(function(e,t){return e+t},0);try{for(var i=Qg(e),a=i.next();!a.done;a=i.next()){var s=a.value;r.push(s/o)}}catch(e){t={error:e}}finally{try{a&&!a.done&&(n=i.return)&&n.call(i)}finally{if(t)throw t.error}}return r}var XT=null;var ZT=!1,JT=!1,QT=0,ek=0,tk=null,nk=im(window);function rk(e,t,n){var r=e.reduce(function(e,t){return e+t},0),o=e[t],i=Math.max(10,n),a=r-o+i;if(a<10*e.length)return e.map(function(){return 10});var s=r-o,u=a-i;if(u<=0){var l=e.map(function(){return 10});return l[t]=Math.max(10,a-10*(e.length-1)),l}var c=s>0?u/s:1,d=e.map(function(e,n){if(n===t)return Math.floor(100*i)/100;var r=e*c;return Math.max(10,Math.floor(100*r)/100)}),f=d.reduce(function(e,t){return e+t},0),p=a-f;return Math.abs(p)>.01&&(d[t]=Math.max(10,d[t]+p)),d}nk.on("mousedown",function(e){var t=e.target;if(t.closest('[data-block-type="table-cell"]'))ZT=!0;else if("DIV"===t.tagName&&t.closest(".column-resizer-item")){if(null===tk)return;var n=ev(Kh.nodes(tk,{match:rT(tk,"table")}),1),r=ev(n[0],1)[0],o=r.columnWidths,i=void 0===o?[]:o,a=r.resizingIndex,s=void 0===a?-1:a;JT=!0;var u=e.clientX;QT=u,ek=i[s],document.body.style.cursor="col-resize",e.preventDefault()}nk.on("mousemove",ok),nk.on("mouseup",ik)});var ok=SC(function(e){if(JT&&null!==tk){e.preventDefault();var t,n=e.clientX,r=n-QT,o=ev(Kh.nodes(tk,{match:rT(tk,"table")}),1),i=ev(o[0],1)[0],a=i.columnWidths,s=void 0===a?[]:a,u=i.resizingIndex,l=void 0===u?-1:u,c=l===s.length-1;if(c){t=rk(s,l,ek+r)}else{var d=document.querySelector(".table");if(d)t=function(e,t,n,r){var o=tv([],ev(e),!1);if(t<0||t>=e.length)return o;var i=0===t?0:r[t-1],a=i+10,s=(t+1<e.length?r[t+1]:r[t])-10,u=Math.max(a,Math.min(s,n))-i,l=t+1;if(l<e.length){var c=e[t]+e[l]-u;o[t]=Math.floor(100*u)/100,o[l]=Math.floor(100*c)/100}return o}(s,l,n-d.getBoundingClientRect().left,KT(s));else t=function(e,t,n){var r=tv([],ev(e),!1),o=t+1;if(o>=r.length)return r;var i=r[t],a=r[o],s=i+a-10,u=i+n,l=i+a-(u=Math.max(10,Math.min(s,u)));return r[t]=Math.floor(100*u)/100,r[o]=Math.floor(100*l)/100,r}(s,l,r)}if(c){var f=document.querySelector(".table-container");if(f){var p=t.reduce(function(e,t){return e+t},0),h=10*s.length,g=f.clientWidth-1;if(p<h)t=s.map(function(){return 10});else if(p>g){var v=t.slice(0,-1).reduce(function(e,t){return e+t},0),m=(t=rk(s,l,Math.max(10,g-v))).reduce(function(e,t){return e+t},0);if(m>g){var y=g/m;t=t.map(function(e){return Math.max(10,Math.floor(e*y*100)/100)})}}}}jg.setNodes(tk,{columnWidths:t},{mode:"highest"})}},100);function ik(e){ZT=!1,JT=!1,tk=null,document.body.style.cursor="",nk.off("mousemove",ok),nk.off("mouseup",ik)}function ak(e,t){"mouseenter"===t.type?jg.setNodes(e,{isResizing:!0},{mode:"highest"}):jg.setNodes(e,{isResizing:!1},{mode:"highest"})}var sk={type:"table",renderElem:function(e,t,n){var r=function(e,t){if(e.isDisabled())return!1;var n=e.selection;if(null==n)return!0;if(fg.isCollapsed(n))return!0;var r=n.anchor,o=n.focus,i=Py.findPath(e,t),a=Kh.start(e,i),s=Kh.end(e,i),u=ug.compare(r,s)<=0&&ug.compare(r,a)>=0,l=ug.compare(o,s)<=0&&ug.compare(o,a)>=0;return!!(u&&l&&og.equals(r.path.slice(0,3),o.path.slice(0,3)))}(n,e),o=e,i=o.width,a=void 0===i?"auto":i,s=o.height,u=o.columnWidths,l=void 0===u?[]:u,c=o.scrollWidth,d=void 0===c?0:c,f=o.isHoverCellBorder,p=o.resizingIndex,h=o.isResizing,g=Py.isNodeSelected(n,e),v=ev(DT.selection(n),1)[0],m=YT(l),y=BD("div",{className:"table-container","data-selected":g,on:{mousedown:function(t){if("DIV"===t.target.tagName&&t.preventDefault(),!n.isDisabled()){t.target.closest('[data-block-type="table-cell"]')&&DT.unselect(n);var r=Py.findPath(n,e),o=Kh.start(n,r),i=n.selection;if(null!=i)i.anchor.path[0]!==r[0]&&"DIV"===t.target.tagName&&n.select(o);else n.select(o)}}}},BD("table",{width:a,contentEditable:r,className:"table ".concat(v?"table-selection-none":""),style:{width:"100%"===a?a:"".concat(l.reduce(function(e,t){return e+t},0),"px")},on:{mousemove:nE(function(t){return function(e,t,n,r){if(!e.isDisabled()&&!ZT&&!JT){var o=t,i=o.width,a=void 0===i?"auto":i,s=o.columnWidths,u=void 0===s?[]:s,l=o.isHoverCellBorder,c=o.resizingIndex,d=n.clientX,f=n.target;if(Wm(f)&&d>(g=f.getBoundingClientRect()).x+5&&d<g.x+g.width-5)return void(l&&jg.setNodes(e,{isHoverCellBorder:!1,resizingIndex:-1},{mode:"highest"}));if(Wm(f)){var p=f.closest(".table");if(p)for(var h=n.clientX,g=p.getBoundingClientRect(),v="100%"===a?YT(u).map(function(e){return e*r}):u,m=KT(v),y=0;y<m.length;y+=1)if(h-g.x>=m[y]-5&&h-g.x<m[y]+5){if(c===y)return;return void jg.setNodes(e,{isHoverCellBorder:!0,resizingIndex:y},{mode:"highest"})}}!0===l&&jg.setNodes(e,{isHoverCellBorder:!1,resizingIndex:-1},{mode:"highest"})}}(n,e,t,d)},25)}},BD("colgroup",{contentEditable:!1},l.map(function(e){return BD("col",{width:e})})),BD("tbody",null,t)),BD("div",{className:"column-resizer",contentEditable:!1},l.map(function(e,t){var r=e;return"100%"===a&&(r=m[t]*d),BD("div",{className:"column-resizer-item",style:{minWidth:"".concat(r,"px")}},BD("div",{className:"resizer-line-hotzone ".concat(f&&t===p?"visible ":"").concat(h&&t===p?"highlight":""),style:{height:"".concat(s,"px")},on:{mouseenter:function(e){return ak(n,e)},mouseleave:function(e){return ak(n,e)},mousedown:function(e){return function(e){JT||(tk=e)}(n)}}},BD("div",{className:"resizer-line"})))}))),b=lD("div",{hook:{insert:function(e){var t=e.elm;return function(e,t){if(Wm(t)){var n=t.querySelector("table");n&&(XT=new ResizeObserver(function(t){var n=ev(t,1)[0].contentRect;jg.setNodes(e,{scrollWidth:n.width,height:n.height},{mode:"highest"})}),XT.observe(n))}}(n,t)},destroy:function(){XT&&(null==XT||XT.disconnect(),XT=null)}}},y);return b}},uk={type:"table-row",renderElem:function(e,t,n){return BD("tr",null,t)}},lk={type:"table-cell",renderElem:function(e,t,n){var r=function(e,t){var n=Py.getParentNode(e,t);if(null==n)return!1;var r=Py.getParentNode(e,n);return null!=r&&mT(r).some(function(e){return e===t})}(n,e),o=e,i=o.colSpan,a=void 0===i?1:i,s=o.rowSpan,u=void 0===s?1:s,l=o.isHeader,c=void 0!==l&&l,d=o.hidden,f=void 0!==d&&d,p=DT.isSelected(n,e);return BD(r&&c?"th":"td",{colSpan:a,rowSpan:u,"data-block-type":"table-cell",className:p?"w-e-selected":"",style:{display:f?"none":""}},t)}};function ck(e,t){null==e.data&&(e.data={});var n=e.data;null==n.style&&(n.style={}),Object.assign(n.style,t)}var dk={renderStyle:function(e,t){var n,r;if(!$h.isElement(e))return t;var o=e,i=o.backgroundColor,a=o.borderWidth,s=o.borderStyle,u=o.borderColor,l=o.textAlign,c={};i&&(c.backgroundColor=i),a&&(c.borderWidth="".concat(a,"px")),s&&(c.borderStyle="none"===s?"":s),u&&(c.borderColor=u),l&&(c.textAlign=l);var d=t;return"table"===e.type?ck(null===(r=(null===(n=d.children)||void 0===n?void 0:n[0]).children)||void 0===r?void 0:r[0],c):ck(d,c),d},styleToHtml:function(e,t){if("table"!==e.type&&"table-cell"!==e.type)return t;var n=e.backgroundColor,r=e.borderWidth,o=e.borderStyle,i=e.borderColor,a=e.textAlign;if(!(n||r||o||i||a))return t;var s=im(t);return n&&s.css("background-color",n),r&&s.css("border-width","".concat(r,"px")),o&&s.css("border-style","none"===o?"":o),i&&s.css("border-color",i),a&&s.css("text-align",a),function(e){return 0===e.length?"":e[0].outerHTML}(s)},parseStyleHtml:function(e,t,n){if(!["TABLE","TD","TH"].includes(e.tagName))return t;var r=im(e),o=t,i=uT(r,"background-color");i||(i=uT(r,"background")),i&&(o.backgroundColor=i);var a=uT(r,"border");a||"TD"!==e.tagName||(a="1px solid ".concat($T));var s=ev((null==a?void 0:a.split(" "))||[],3),u=s[0],l=s[1],c=s[2];(u=uT(r,"border-width")||u)&&(o.borderWidth=u.replace(/[^\d]/g,"")),(l=uT(r,"border-style")||l)&&(o.borderStyle="none"===l?"":l),(c=uT(r,"border-color")||c)&&(o.borderColor=c);var d=uT(r,"text-align");return(d=uT(r,"text-align")||d)&&(o.textAlign=d),t},renderElems:[sk,uk,lk],elemsToHtml:[JB,QB,eT],preParseHtml:[qT],parseElemsHtml:[MT,jT,zT],menus:[xT,OT,NT,BT,TT,kT,FT,IT,PT,_T,LT,RT],editorPlugin:function(e){var t=e.insertBreak,n=e.deleteBackward,r=e.deleteForward,o=e.deleteFragment,i=e.normalizeNode,a=e.insertData,s=e.handleTab,u=e.selectAll,l=e;l.insertBreak=function(){null==Py.getSelectedNodeByType(l,"table")?t():l.insertText("\n\r")},l.deleteBackward=function(e){if(!UT(l)&&!WT(l,e,"backward")){var t=l.selection;if(t){var r=Kh.before(l,t),o=Kh.above(l,{at:t,match:function(e){return Py.checkNodeType(e,"table-cell")}});if(r){var i=GT(l,r);if(!o&&i&&Py.getSelectedNodeByType(l,"paragraph"))return}}n(e)}},l.handleTab=function(){var t;if(Py.getSelectedNodeByType(l,"table")){var n=Kh.above(e);Py.checkNodeType(n[0],"table-cell")&&jg.select(e,n[1]);var r=Kh.next(e);if(r)r[0]&&r[0].text&&(r=null!==(t=Kh.above(e,{at:r[1]}))&&void 0!==t?t:r),jg.select(e,r[1]);else{var o=l.children||[],i=o.length;if(Py.checkNodeType(o[i-1],"table")){var a=Py.genEmptyParagraph();jg.insertNodes(l,a,{at:[i]}),l.handleTab()}}}else s()},l.deleteForward=function(e){if(!UT(l)&&!WT(l,e,"forward")){var t=l.selection;if(t){var n=Kh.after(l,t),o=Kh.above(l,{at:t,match:function(e){return Py.checkNodeType(e,"table-cell")}});if(n){var i=GT(l,n);if(!o&&i&&Py.getSelectedNodeByType(l,"paragraph"))return}}r(e)}},l.deleteFragment=function(e){var t=l.selection;if(t){var n,r=!1,i={anchor:t.anchor,focus:t.focus},a=ug.isBefore(i.anchor,i.focus);if(VT(l,t.anchor))(n=Kh[a?"before":"after"](l,t.anchor))&&(i.anchor=n),r=!0;if(VT(l,t.focus))(n=Kh[a?"after":"before"](l,t.focus))&&(i.focus=n),r=!0;r&&jg.setSelection(l,i),o(e)}},l.normalizeNode=function(e){var t=ev(e,2),n=t[0],r=t[1];if("table"!==Py.getNodeType(n))return i([n,r]);if(Py.isLastNode(l,n)){var o=Py.genEmptyParagraph();jg.insertNodes(l,o,{at:[r[0]+1]})}},l.insertData=function(e){if(null!=Py.getSelectedNodeByType(l,"table")){var t=e.getData("text/plain");"\n"===t||/<img[^>]+>/.test(e.getData("text/html"))?a(e):Kh.insertText(l,t)}else a(e)},l.selectAll=function(){var e=l.selection;if(null!=e){var t=Py.getSelectedNodeByType(l,"table-cell");if(null!=t){var n=e.anchor,r=e.focus;if(og.equals(n.path.slice(0,3),r.path.slice(0,3)))if(0!==eg.string(t).length){var o=Py.findPath(l,t),i={anchor:Kh.start(l,o),focus:Kh.end(l,o)};l.select(i)}else u();else u()}else u()}else u()},function(e){var t=e.apply;e.apply=function(n){if(!rg.isSelectionOperation(n)||!n.newProperties)return t(n);var r=Yg(Yg({},e.selection),n.newProperties);if(!fg.isRange(r))return DT.unselect(e),t(n);var o=function(e){return $h.isElement(e)&&("table-cell"===e.type||"th"===e.type||"td"===e.type)},i=ev(Kh.nodes(e,{match:o,at:fg.start(r),mode:"lowest"}),1)[0],a=ev(Kh.nodes(e,{match:o,at:fg.end(r),mode:"lowest"}),1)[0];if(!i||!a)return DT.unselect(e),t(n);var s=ev(i,2)[1],u=ev(a,2)[1];if(og.equals(s,u)||!oT(e,[s,u],"table"))return DT.unselect(e),t(n);try{var l=iT(e,{at:s});if(!l||0===l.length)return DT.unselect(e),t(n);for(var c=aT.valueOf(0,0),d=aT.valueOf(0,0),f=!1,p=!1,h=0;h<l.length;h+=1)if(l[h])for(var g=0;g<l[h].length;g+=1)if(l[h][g]){var v=ev(l[h][g],1),m=ev(v[0],2)[1];og.equals(s,m)&&(c.x=h,c.y=g,f=!0),og.equals(u,m)&&(d.x=h,d.y=g,p=!0)}if(!f||!p)return DT.unselect(e),t(n);for(var y=aT.valueOf(Math.min(c.x,d.x),Math.min(c.y,d.y)),b=aT.valueOf(Math.max(c.x,d.x),Math.max(c.y,d.y));;){var E=aT.valueOf(y.x,y.y),C=aT.valueOf(b.x,b.y);for(h=E.x;h<=C.x&&h<l.length;h+=1)if(l[h])for(g=E.y;g<=C.y&&g<l[h].length;g+=1)if(l[h][g]){var D=ev(l[h][g],2)[1];if(D){var w=D.rtl,S=D.ltr,A=D.btt,x=D.ttb;E.x=Math.min(E.x,h-(x-1)),E.y=Math.min(E.y,g-(w-1)),C.x=Math.max(C.x,h+(A-1)),C.y=Math.max(C.y,g+(S-1))}}if(aT.equals(y,E)&&aT.equals(b,C))break;y=E,b=C}var O=[],N=new WeakSet;for(h=y.x;h<=b.x&&h<l.length;h+=1)if(l[h]){var B=[];for(g=y.y;g<=b.y&&g<l[h].length;g+=1)if(l[h][g]){var T=ev(l[h][g],1),k=ev(T[0],1)[0];k&&(N.add(k),B.push(l[h][g]))}B.length>0&&O.push(B)}lT.set(e,O),cT.set(e,N)}catch(r){return DT.unselect(e),t(n)}t(n)}}(l),l.getTableSelection=function(){return lT.get(l)||null};var c=l.addMark,d=l.removeMark,f=Yg({},jg);return l.addMark=function(e,t){var n=lT.get(l);if(n&&n.length>0){var r=l.selection;n.forEach(function(n){n.forEach(function(n){var r=ev(n[0],2)[1],o=Kh.start(l,r),i=Kh.end(l,r);jg.select(l,{anchor:o,focus:i}),c(e,t)})}),r&&jg.select(l,r)}else c(e,t)},l.removeMark=function(e){var t=lT.get(l);if(t&&t.length>0){var n=l.selection;t.forEach(function(t){t.forEach(function(t){var n=ev(t[0],2)[1],r=Kh.start(l,n),o=Kh.end(l,n);jg.select(l,{anchor:r,focus:o}),d(e)})}),n&&jg.select(l,n)}else d(e)},jg.setNodes=function(e,t,n){if(void 0===n&&(n={}),e===l){var r=lT.get(l);if(r&&r.length>0)return"hidden"in t||"rowSpan"in t||"colSpan"in t?void f.setNodes(e,t,n):void r.forEach(function(r){r.forEach(function(r){var o=ev(r[0],2)[1];f.setNodes(e,t,Yg(Yg({},n),{at:o}))})})}f.setNodes(e,t,n)},l}};KE("en",{uploadImgModule:{uploadImage:"Upload Image",uploadError:"{{fileName}} upload error"}}),KE("zh-CN",{uploadImgModule:{uploadImage:"上传图片",uploadError:"{{fileName}} 上传出错"}});Om&&(im.fn.append=Om),hm&&(im.fn.on=hm),Im&&(im.fn.remove=Im),pm&&(im.fn.val=pm),Rm&&(im.fn.click=Rm),bm&&(im.fn.hide=bm);var fk=new WeakMap;function pk(e){return e.getMenuConfig("uploadImage")}function hk(e,t){return Zg(this,void 0,void 0,function(){return Jg(this,function(n){return[2,new Promise(function(n){var r=new FileReader;r.readAsDataURL(t),r.onload=function(){var o=r.result;if(o){var i=o.toString(),a=0===i.indexOf("data:image")?"":i;qO(e,i,t.name,a),n("ok")}}})]})})}function gk(e,t){return Zg(this,void 0,void 0,function(){var n,r;return Jg(this,function(o){switch(o.label){case 0:return n=function(e){var t=fk.get(e);if(null!=t)return t;var n=pk(e),r=n.onSuccess,o=n.onProgress,i=n.onFailed,a=n.customInsert,s=n.onError;return t=qA(Yg(Yg({},n),{onProgress:function(t){e.showProgressBar(t),o&&o(t)},onSuccess:function(t,n){if(a)return a(n,function(t,n,r){return qO(e,t,n,r)}),void r(t,n);var o=n.errno,s=void 0===o?1:o,u=n.data,l=void 0===u?{}:u;if(0===s){if(Array.isArray(l))l.forEach(function(t){var n=t.url,r=void 0===n?"":n,o=t.alt,i=void 0===o?"":o,a=t.href;qO(e,r,i,void 0===a?"":a)});else{var c=l.url,d=void 0===c?"":c,f=l.alt,p=void 0===f?"":f,h=l.href;qO(e,d,p,void 0===h?"":h)}r(t,n)}else i(t,n)},onError:function(e,t,n){s(e,t,n)}})),fk.set(e,t),t}(e),r=t.map(function(e){return{name:e.name,type:e.type,size:e.size,data:e}}),n.addFiles(r),[4,n.upload()];case 1:return o.sent(),[2]}})})}function vk(e,t){return Zg(this,void 0,void 0,function(){var n,r,o,i,a,s,u,l,c,d,f,p,h,g,v;return Jg(this,function(m){switch(m.label){case 0:if(null==t)return[2];n=Array.prototype.slice.call(t),r=pk(e),o=r.customUpload,i=r.base64LimitSize,a=[],m.label=1;case 1:m.trys.push([1,10,11,16]),s=!0,u=nv(n),m.label=2;case 2:return[4,u.next()];case 3:return l=m.sent(),(p=l.done)?[3,9]:(v=l.value,s=!1,d=(c=v).size,i&&d<=i?[4,hk(e,c)]:[3,5]);case 4:return m.sent(),[3,8];case 5:return o?[4,o(c,function(t,n,r){return qO(e,t,n,r)})]:[3,7];case 6:return m.sent(),[3,8];case 7:a.push(c),m.label=8;case 8:return s=!0,[3,2];case 9:return[3,16];case 10:return f=m.sent(),h={error:f},[3,16];case 11:return m.trys.push([11,,14,15]),s||p||!(g=u.return)?[3,13]:[4,g.call(u)];case 12:m.sent(),m.label=13;case 13:return[3,15];case 14:if(h)throw h.error;return[7];case 15:return[7];case 16:return a.length>0?[4,gk(e,a)]:[3,18];case 17:m.sent(),m.label=18;case 18:return[2]}})})}var mk=function(){function e(){this.title=JE("uploadImgModule.uploadImage"),this.iconSvg='<svg viewBox="0 0 1024 1024"><path d="M828.708571 585.045333a48.761905 48.761905 0 0 0-48.737523 48.761905v18.529524l-72.143238-72.167619a135.972571 135.972571 0 0 0-191.585524 0l-34.133334 34.133333-120.880762-120.953905a138.898286 138.898286 0 0 0-191.585523 0l-72.167619 72.167619V292.400762a48.786286 48.786286 0 0 1 48.761904-48.761905h341.23581a48.737524 48.737524 0 0 0 34.474667-83.285333 48.737524 48.737524 0 0 0-34.474667-14.287238H146.236952A146.212571 146.212571 0 0 0 0 292.400762v585.289143A146.358857 146.358857 0 0 0 146.236952 1024h584.996572a146.212571 146.212571 0 0 0 146.236952-146.310095V633.807238a48.786286 48.786286 0 0 0-48.761905-48.761905zM146.261333 926.45181a48.737524 48.737524 0 0 1-48.761904-48.761905v-174.128762l141.409523-141.458286a38.497524 38.497524 0 0 1 53.126096 0l154.526476 154.624 209.627428 209.724953H146.236952z m633.734096-48.761905c-0.073143 9.337905-3.145143 18.383238-8.777143 25.843809l-219.843048-220.94019 34.133333-34.133334a37.546667 37.546667 0 0 1 53.613715 0l140.873143 141.897143V877.714286zM1009.615238 160.231619L863.329524 13.897143a48.737524 48.737524 0 0 0-16.091429-10.24c-11.849143-4.87619-25.161143-4.87619-37.059047 0a48.761905 48.761905 0 0 0-16.067048 10.24l-146.236952 146.334476a49.005714 49.005714 0 0 0 69.217523 69.241905l62.902858-63.390476v272.627809a48.761905 48.761905 0 1 0 97.475047 0V166.083048l62.902857 63.390476a48.737524 48.737524 0 0 0 69.217524 0 48.761905 48.761905 0 0 0 0-69.241905z"></path></svg>',this.tag="button"}return e.prototype.getValue=function(e){return""},e.prototype.isActive=function(e){return!1},e.prototype.isDisabled=function(e){return VO(e)},e.prototype.getMenuConfig=function(e){return e.getMenuConfig("uploadImage")},e.prototype.exec=function(e,t){var n=this.getMenuConfig(e),r=n.allowedFileTypes,o=void 0===r?[]:r,i=n.customBrowseAndUpload;if(i)i(function(t,n,r){return qO(e,t,n,r)});else{var a="";o.length>0&&(a='accept="'.concat(o.join(", "),'"'));var s=im("body"),u=im('<input type="file" '.concat(a," multiple/>"));u.hide(),s.append(u),u.click(),u.on("change",function(){var t=u[0].files;vk(e,t)})}},e}();var yk={menus:[{key:"uploadImage",factory:function(){return new mk},config:{server:"",fieldName:"wangeditor-uploaded-image",maxFileSize:2097152,maxNumberOfFiles:100,allowedFileTypes:["image/*"],meta:{},metaWithUrl:!1,withCredentials:!1,timeout:1e4,onBeforeUpload:function(e){return e},onProgress:function(e){},onSuccess:function(e,t){},onFailed:function(e,t){console.error("'".concat(e.name,"' upload failed"),t)},onError:function(e,t,n){console.error("'".concat(e.name,"' upload error"),n)},base64LimitSize:0}}],editorPlugin:function(e){var t=e.insertData,n=e;return n.insertData=function(r){if(VO(n))t(r);else if(r.getData("text/plain"))t(r);else{var o=r.files;if(o.length<=0)t(r);else Array.prototype.slice.call(o).some(function(e){return"image"===ev(e.type.split("/"),1)[0]})?vk(e,o):t(r)}},n}};function bk(e){return e.length?e[0].tagName.toLowerCase():""}function Ek(e,t,n,r){void 0===t&&(t="auto"),void 0===n&&(n="auto"),void 0===r&&(r={});var o=im(e),i=r.width,a=void 0===i?"":i,s=r.height,u=void 0===s?"":s,l="";return a&&(l+="width: ".concat(a,";")),u&&(l+="height: ".concat(u,";")),o.attr("width",t),o.attr("height",n),o.attr("style",l),o[0].outerHTML}KE("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",edit:"Edit video",width:"Width",height:"Height"}}),KE("zh-CN",{videoModule:{delete:"删除视频",uploadVideo:"上传视频",insertVideo:"插入视频",videoSrc:"视频地址",videoSrcPlaceHolder:"视频文件 url 或第三方 <iframe>",videoPoster:"视频封面",videoPosterPlaceHolder:"封面图片 url",ok:"确定",editSize:"修改尺寸",edit:"编辑视频",width:"宽度",height:"高度"}}),Om&&(im.fn.append=Om),hm&&(im.fn.on=hm),Mm&&(im.fn.focus=Mm),lm&&(im.fn.attr=lm),pm&&(im.fn.val=pm),Sm&&(im.fn.html=Sm),Bm&&(im.fn.parent=Bm),um&&(im.fn.hasClass=um),Pm&&(im.fn.empty=Pm);var Ck={type:"video",elemToHtml:function(e,t){var n=e,r=n.src,o=void 0===r?"":r,i=n.poster,a=void 0===i?"":i,s=n.width,u=void 0===s?"auto":s,l=n.height,c=void 0===l?"auto":l,d=n.style,f=void 0===d?{}:d,p=n.textAlign,h='<div data-w-e-type="video" data-w-e-is-void style="text-align: '.concat(void 0===p?"center":p,';">\n');if(0===o.trim().indexOf("<iframe ")){h+=Ek(o,u,c,f)}else{var g=f.width,v=void 0===g?"":g,m=f.height,y=void 0===m?"":m,b="";v&&(b+="width: ".concat(v,";")),y&&(b+="height: ".concat(y,";")),h+='<video poster="'.concat(a,'" controls="true" width="').concat(u,'" height="').concat(c,'" style="').concat(b,'"><source src="').concat(o,'" type="video/mp4"/></video>')}return h+="\n</div>"}};function Dk(e){return void 0===e&&(e="r"),"".concat(e,"-").concat(Hm())}function wk(e){var t={};return e.trim().split(";").forEach(function(e){if(e){var n=ev(e.split(":"),2),r=n[0],o=n[1];r&&o&&(t[r.trim()]=o.trim())}}),t}function Sk(){return Dk("w-e-insert-video")}var Ak=function(){function e(){this.title=JE("videoModule.editSize"),this.tag="button",this.showModal=!0,this.modalWidth=320,this.$content=null,this.widthInputId=Sk(),this.heightInputId=Sk(),this.buttonId=Sk()}return e.prototype.getSelectedVideoNode=function(e){return Py.getSelectedNodeByType(e,"video")},e.prototype.getValue=function(e){return""},e.prototype.isActive=function(e){return!1},e.prototype.exec=function(e,t){},e.prototype.isDisabled=function(e){return null==e.selection||null==this.getSelectedVideoNode(e)},e.prototype.getModalPositionNode=function(e){return this.getSelectedVideoNode(e)},e.prototype.getModalContentElem=function(e){var t=this,n=t.widthInputId,r=t.heightInputId,o=t.buttonId,i=ev(lC(JE("videoModule.width"),n,"auto"),2),a=i[0],s=im(i[1]),u=ev(lC(JE("videoModule.height"),r,"auto"),2),l=u[0],c=im(u[1]),d=ev(dC(o,JE("videoModule.ok")),1)[0],f=this.getSelectedVideoNode(e);if(null==this.$content){var p=im("<div></div>");p.on("click","#".concat(o),function(t){t.preventDefault();var o=p.find("#".concat(n)).val().trim(),i=p.find("#".concat(r)).val().trim(),a=function(e){return/^\d+(\.\d+)?%$/.test(e)},s=function(e){return/^\d+(\.\d+)?$/.test(e)},u="auto",l="auto";a(o)?u=o:s(o)&&(u="".concat(parseInt(o,10),"px")),a(i)?l=i:s(i)&&(l="".concat(parseInt(i,10),"px"));var c=f.style,d=void 0===c?{}:c;e.restoreSelection();var h={style:Yg(Yg({},d),{width:u,height:l})};jg.setNodes(e,h,{match:function(e){return Py.checkNodeType(e,"video")}}),e.hidePanelOrModal()}),this.$content=p}var h=this.$content;if(h.empty(),h.append(a),h.append(l),h.append(d),null==f)return h[0];var g=f.style,v=void 0===g?{}:g,m=v.width,y=void 0===m?"":m,b=v.height,E=void 0===b?"":b;return s.val(y),c.val(E),setTimeout(function(){s.focus()}),h[0]},e}();function xk(){return Dk("w-e-edit-video")}var Ok=function(){function e(){this.title=JE("videoModule.edit"),this.iconSvg='<svg viewBox="0 0 1024 1024"><path d="M864 0a160 160 0 0 1 128 256l-64 64-224-224 64-64c26.752-20.096 59.968-32 96-32zM64 736l-64 288 288-64 592-592-224-224L64 736z m651.584-372.416l-448 448-55.168-55.168 448-448 55.168 55.168z"></path></svg>',this.tag="button",this.showModal=!0,this.modalWidth=300,this.$content=null,this.srcInputId=xk(),this.posterInputId=xk(),this.buttonId=xk()}return e.prototype.getSelectedVideoNode=function(e){return Py.getSelectedNodeByType(e,"video")},e.prototype.getValue=function(e){return""},e.prototype.isActive=function(e){return!1},e.prototype.exec=function(e,t){},e.prototype.isDisabled=function(e){return null==e.selection||null==this.getSelectedVideoNode(e)},e.prototype.getModalPositionNode=function(e){return this.getSelectedVideoNode(e)},e.prototype.getModalContentElem=function(e){var t=this,n=this,r=n.srcInputId,o=n.posterInputId,i=n.buttonId,a=ev(lC(JE("videoModule.videoSrc"),r,JE("videoModule.videoSrcPlaceHolder")),2),s=a[0],u=a[1],l=ev(lC(JE("videoModule.videoPoster"),o,JE("videoModule.videoPosterPlaceHolder")),2),c=l[0],d=l[1],f=im(u),p=im(d),h=ev(dC(i,JE("videoModule.ok")),1)[0];if(null==this.$content){var g=im("<div></div>");g.on("click","#".concat(i),function(n){return Zg(t,void 0,void 0,function(){var t,i,a,s;return Jg(this,function(u){return n.preventDefault(),t=g.find("#".concat(r)).val().trim(),i=g.find("#".concat(o)).val().trim(),a=Dk("video-"),s={src:t,poster:i,key:a},e.restoreSelection(),jg.setNodes(e,s,{match:function(e){return Py.checkNodeType(e,"video")}}),e.hidePanelOrModal(),[2]})})}),this.$content=g}var v=this.$content;v.empty(),v.append(s),v.append(c),v.append(h);var m=this.getSelectedVideoNode(e);if(null==m)return v[0];var y=m.src,b=void 0===y?"":y,E=m.poster,C=void 0===E?"":E;return f.val(b),p.val(C),setTimeout(function(){f.focus()}),v[0]},e}();function Nk(e,t){return Zg(this,arguments,void 0,function(e,t,n,r,o){var i,a,s,u,l,c,d;return void 0===n&&(n=""),void 0===r&&(r=""),void 0===o&&(o=""),Jg(this,function(f){switch(f.label){case 0:return t?(e.restoreSelection(),i=e.getMenuConfig("insertVideo"),a=i.onInsertedVideo,s=i.checkVideo,u=i.parseVideoSrc,[4,s(t,n)]):[2];case 1:return"string"==typeof(l=f.sent())?(e.alert(l,"error"),[2]):null==l?[2]:[4,u(t)];case 2:return 0!==(c=f.sent()).trim().indexOf("<iframe ")&&(c=function(e){return e.replace(/</g,"<").replace(/>/g,">")}(c)),d={type:"video",src:c,poster:n,children:[{text:""}],style:{width:r,height:o}},Promise.resolve().then(function(){Py.isSelectedEmptyParagraph(e)&&jg.removeNodes(e,{mode:"highest"}),jg.insertNodes(e,d,{mode:"highest"})}),a(d),[2]}})})}function Bk(){return Dk("w-e-insert-video")}var Tk=function(){function e(){this.title=JE("videoModule.insertVideo"),this.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>',this.tag="button",this.showModal=!0,this.modalWidth=320,this.$content=null,this.srcInputId=Bk(),this.posterInputId=Bk(),this.buttonId=Bk()}return e.prototype.getValue=function(e){return""},e.prototype.isActive=function(e){return!1},e.prototype.exec=function(e,t){},e.prototype.isDisabled=function(e){var t=e.selection;return null==t||(!fg.isCollapsed(t)||!!Py.getSelectedElems(e).some(function(t){var n=Py.getNodeType(t);return"pre"===n||("list-item"===n||!!e.isVoid(t))}))},e.prototype.getModalPositionNode=function(e){return null},e.prototype.getModalContentElem=function(e){var t=this,n=this,r=n.srcInputId,o=n.posterInputId,i=n.buttonId,a=ev(lC(JE("videoModule.videoSrc"),r,JE("videoModule.videoSrcPlaceHolder")),2),s=a[0],u=a[1],l=ev(lC(JE("videoModule.videoPoster"),o,JE("videoModule.videoPosterPlaceHolder")),2),c=l[0],d=l[1],f=im(u),p=im(d),h=ev(dC(i,JE("videoModule.ok")),1)[0];if(null==this.$content){var g=im("<div></div>");g.on("click","#".concat(i),function(n){return Zg(t,void 0,void 0,function(){var t,i;return Jg(this,function(a){switch(a.label){case 0:return n.preventDefault(),t=g.find("#".concat(r)).val().trim(),i=g.find("#".concat(o)).val().trim(),[4,Nk(e,t,i)];case 1:return a.sent(),e.hidePanelOrModal(),[2]}})})}),this.$content=g}var v=this.$content;return v.empty(),v.append(s),v.append(c),v.append(h),f.val(""),p.val(""),setTimeout(function(){f.focus()}),v[0]},e}();function kk(e){return e.getMenuConfig("uploadVideo")}var Fk=new WeakMap;function Ik(e,t){return Zg(this,void 0,void 0,function(){var n,r;return Jg(this,function(o){switch(o.label){case 0:return n=function(e){var t=Fk.get(e);if(null!=t)return t;var n=kk(e),r=n.onSuccess,o=n.onProgress,i=n.onFailed,a=n.customInsert,s=n.onError;return t=qA(Yg(Yg({},n),{onProgress:function(t){e.showProgressBar(t),o&&o(t)},onSuccess:function(t,n){if(a)return a(n,function(t,n){return Nk(e,t,n)}),void r(t,n);var o=n.errno,s=void 0===o?1:o,u=n.data,l=void 0===u?{}:u;if(0===s){var c=l.url,d=void 0===c?"":c,f=l.poster;Nk(e,d,void 0===f?"":f),r(t,n)}else i(t,n)},onError:function(e,t,n){s(e,t,n)}})),Fk.set(e,t),t}(e),r=t.map(function(e){return{name:e.name,type:e.type,size:e.size,data:e}}),n.addFiles(r),[4,n.upload()];case 1:return o.sent(),[2]}})})}var Pk=function(){function e(){this.title=JE("videoModule.uploadVideo"),this.iconSvg='<svg viewBox="0 0 1056 1024"><path d="M805.902261 521.819882a251.441452 251.441452 0 0 0-251.011972 246.600033 251.051015 251.051015 0 1 0 502.023944 8.823877 253.237463 253.237463 0 0 0-251.011972-255.42391z m59.463561 240.001647v129.898403h-116.701631v-129.898403h-44.041298l101.279368-103.504859 101.279368 103.504859z" p-id="6802"></path><path d="M788.254507 0.000781H99.094092A98.663439 98.663439 0 0 0 0.001171 99.093701v590.067495a98.663439 98.663439 0 0 0 99.092921 99.092921h411.7549a266.434235 266.434235 0 0 1-2.186448-41.815807 275.843767 275.843767 0 0 1 275.180024-270.729042 270.650955 270.650955 0 0 1 103.504859 19.834201V99.093701A101.51363 101.51363 0 0 0 788.254507 0.000781zM295.054441 640.747004V147.507894l394.146189 246.600033z"></path></svg>',this.tag="button"}return e.prototype.getValue=function(e){return""},e.prototype.isActive=function(e){return!1},e.prototype.exec=function(e,t){var n=this.getMenuConfig(e),r=n.allowedFileTypes,o=void 0===r?[]:r,i=n.customBrowseAndUpload;if(i)i(function(t,n){return Nk(e,t,n)});else{var a="";o.length>0&&(a='accept="'.concat(o.join(", "),'"'));var s=im("body"),u=im('<input type="file" '.concat(a," multiple/>"));u.hide(),s.append(u),u.click(),u.on("change",function(){var t=u[0].files;!function(e,t){Zg(this,void 0,void 0,function(){var n,r,o,i,a,s,u,l,c,d,f,p;return Jg(this,function(h){switch(h.label){case 0:if(null==t)return[2];n=Array.prototype.slice.call(t),r=[],o=kk(e).customUpload,h.label=1;case 1:h.trys.push([1,8,9,14]),i=!0,a=nv(n),h.label=2;case 2:return[4,a.next()];case 3:return s=h.sent(),(c=s.done)?[3,7]:(p=s.value,i=!1,u=p,o?[4,o(u,function(t,n){return Nk(e,t,n)})]:[3,5]);case 4:return h.sent(),[3,6];case 5:r.push(u),h.label=6;case 6:return i=!0,[3,2];case 7:return[3,14];case 8:return l=h.sent(),d={error:l},[3,14];case 9:return h.trys.push([9,,12,13]),i||c||!(f=a.return)?[3,11]:[4,f.call(a)];case 10:h.sent(),h.label=11;case 11:return[3,13];case 12:if(d)throw d.error;return[7];case 13:return[7];case 14:return r.length>0?[4,Ik(e,r)]:[3,16];case 15:h.sent(),h.label=16;case 16:return[2]}})})}(e,t)})}},e.prototype.isDisabled=function(e){var t=e.selection;return null==t||(!fg.isCollapsed(t)||!!Py.getSelectedElems(e).some(function(t){var n=Py.getNodeType(t);return"pre"===n||("list-item"===n||!!e.isVoid(t))}))},e.prototype.getMenuConfig=function(e){return e.getMenuConfig("uploadVideo")},e}();function _k(e,t,n,r,o,i){return void 0===t&&(t=""),void 0===n&&(n="auto"),void 0===r&&(r="auto"),void 0===o&&(o={}),void 0===i&&(i="center"),{type:"video",src:e,poster:t,width:n,height:r,style:o,children:[{text:""}],textAlign:i}}var Lk={selector:'div[data-w-e-type="video"]',parseElemHtml:function(e,t,n){var r=im(e),o="",i="",a="auto",s="auto",u={},l=r.find("iframe");if(l.length>0)return a=l.attr("width")||"auto",s=l.attr("height")||"auto",u=wk(u=l.attr("style")||""),_k(o=l[0].outerHTML,i,a,s,u,wk(r.attr("style")||"")["text-align"]||"center");var c=r.find("video");return(o=c.attr("src")||"")||c.length>0&&(o=c.find("source").attr("src")||""),a=c.attr("width")||"auto",s=c.attr("height")||"auto",_k(o,i=c.attr("poster")||"",a,s,u=wk(u=c.attr("style")||""),wk(r.attr("style")||"")["text-align"]||"center")}};var Rk={selector:"iframe,video,p",preParseHtml:function(e){var t=im(e),n=t;if("p"===bk(t)){var r=t.children();if(1===r.length){var o=r[0],i=o.tagName.toLowerCase();["iframe","video"].includes(i)&&(n=im(o))}}var a=bk(n);if("iframe"!==a&&"video"!==a)return n[0];if("video"===n.parent().attr("data-w-e-type"))return n[0];var s=im('<div data-w-e-type="video" data-w-e-is-void style="text-align: center;"></div>');return s.append(n),s[0]}};var Mk={type:"video",renderElem:function(e,t,n){var r,o=e,i=o.src,a=void 0===i?"":i,s=o.poster,u=void 0===s?"":s,l=o.key,c=void 0===l?"":l,d=o.width,f=void 0===d?"auto":d,p=o.height,h=void 0===p?"auto":p,g=o.style,v=void 0===g?{}:g,m=o.textAlign,y=void 0===m?"center":m,b=Py.isNodeSelected(n,e);if(0===a.trim().indexOf("<iframe ")){r=BD("div",{className:"w-e-textarea-video-container","data-selected":b?"true":"",style:{textAlign:y},innerHTML:Ek(a,f,h,v)})}else{var E=BD("video",{key:c,poster:u,controls:!0,style:v},BD("source",{src:a,type:"video/mp4"}),"Sorry, your browser doesn't support embedded videos.\n 抱歉,浏览器不支持 video 视频");"auto"!==f&&(E.data.width=f),"auto"!==h&&(E.data.height=h),r=BD("div",{className:"w-e-textarea-video-container","data-selected":b?"true":"",style:{textAlign:y}},E)}var C=lD("div",{props:{contentEditable:!1},on:{mousedown:function(e){return e.preventDefault()}}},r);return C}},jk={renderElems:[Mk],elemsToHtml:[Ck],preParseHtml:[Rk],parseElemsHtml:[Lk],menus:[{key:"insertVideo",factory:function(){return new Tk},config:{onInsertedVideo:function(e){},checkVideo:function(e,t){return!0},parseVideoSrc:function(e){return e}}},{key:"uploadVideo",factory:function(){return new Pk},config:{server:"",fieldName:"wangeditor-uploaded-video",maxFileSize:10485760,maxNumberOfFiles:5,allowedFileTypes:["video/*"],meta:{},metaWithUrl:!1,withCredentials:!1,timeout:3e4,onBeforeUpload:function(e){return e},onProgress:function(e){},onSuccess:function(e,t){},onFailed:function(e,t){console.error("'".concat(e.name,"' upload failed"),t)},onError:function(e,t,n){console.error("'".concat(e.name," upload error"),t,n)}}},{key:"editVideoSize",factory:function(){return new Ak}},{key:"editVideoSrc",factory:function(){return new Ok}}],editorPlugin:function(e){var t=e.isVoid,n=e.normalizeNode,r=e;return r.isVoid=function(e){return"video"===e.type||t(e)},r.normalizeNode=function(e){var t=ev(e,2),o=t[0],i=t[1];"video"===Py.getNodeType(o)&&(Py.isLastNode(r,o)&&jg.insertNodes(r,Py.genEmptyParagraph(),{at:[i[0]+1]}));return n([o,i])},r}},Hk=function(){function e(){throw new Error("不能实例化\nCan not construct a instance")}return e.setEditorConfig=function(e){void 0===e&&(e={}),this.editorConfig=Yg(Yg({},this.editorConfig),e)},e.setSimpleEditorConfig=function(e){void 0===e&&(e={}),this.simpleEditorConfig=Yg(Yg({},this.simpleEditorConfig),e)},e.setToolbarConfig=function(e){void 0===e&&(e={}),this.toolbarConfig=Yg(Yg({},this.toolbarConfig),e)},e.setSimpleToolbarConfig=function(e){void 0===e&&(e={}),this.simpleToolbarConfig=Yg(Yg({},this.simpleToolbarConfig),e)},e.registerPlugin=function(e){this.plugins.push(e)},e.registerMenu=function(e,t){bv(e,t)},e.registerRenderElem=function(e){var t,n,r;n=(t=e).type,r=t.renderElem,ID[n||""]=r},e.registerRenderStyle=function(e){!function(e){TD.push(e)}(e)},e.registerElemToHtml=function(e){!function(e){var t=e.type,n=e.elemToHtml;Ey[t||""]=n}(e)},e.registerStyleToHtml=function(e){!function(e){my.push(e)}(e)},e.registerPreParseHtml=function(e){var t;t=e,ay.push(t)},e.registerParseElemHtml=function(e){!function(e){var t=e.selector,n=e.parseElemHtml;uy[t]=n}(e)},e.registerParseStyleHtml=function(e){!function(e){sy.push(e)}(e)},e.registerModule=function(e){zk(e)},e.editorConfig={},e.simpleEditorConfig={},e.toolbarConfig={},e.simpleToolbarConfig={},e.plugins=[],e}();function zk(e){var t=e.menus,n=e.renderElems,r=e.renderStyle,o=e.elemsToHtml,i=e.styleToHtml,a=e.preParseHtml,s=e.parseElemsHtml,u=e.parseStyleHtml,l=e.editorPlugin;t&&t.forEach(function(e){return Hk.registerMenu(e)}),n&&n.forEach(function(e){return Hk.registerRenderElem(e)}),r&&Hk.registerRenderStyle(r),o&&o.forEach(function(e){return Hk.registerElemToHtml(e)}),i&&Hk.registerStyleToHtml(i),a&&a.forEach(function(e){return Hk.registerPreParseHtml(e)}),s&&s.forEach(function(e){return Hk.registerParseElemHtml(e)}),u&&Hk.registerParseStyleHtml(u),l&&Hk.registerPlugin(l)}vB.forEach(function(e){return zk(e)}),zk(ZB),zk(dk),zk(jk),zk(yk),zk(PB);var $k='<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>';var Uk={link:{menuKeys:["editLink","unLink","viewLink"]},image:{menuKeys:["imageWidth30","imageWidth50","imageWidth100","editorImageSizeMenu","editImage","viewImageLink","deleteImage"]},pre:{menuKeys:["enter","codeBlock","codeSelectLang"]},table:{menuKeys:["enter","tableHeader","tableFullWidth","insertTableRow","deleteTableRow","insertTableCol","deleteTableCol","deleteTable","mergeTableCell","splitTableCell","setTableProperty","setTableCellProperty"]},divider:{menuKeys:["enter"]},video:{menuKeys:["enter","editVideoSize","editVideoSrc"]}};var Vk,Wk={hoverbarKeys:(Vk=["formatPainter","headerSelect","insertLink","bulletedList","|","bold","through","color","bgColor","clearStyle"],null!=yv.textToFormula&&Vk.push("|","textToFormula"),Yg(Yg({},Uk),{text:{menuKeys:Vk}}))};Hk.setEditorConfig(Yg(Yg({},Wk),{decorate:TB}));var Gk={hoverbarKeys:Uk};Hk.setSimpleEditorConfig(Yg(Yg({},Gk),{decorate:TB}));var qk={toolbarKeys:["headerSelect","blockquote","|","bold","underline","italic",{key:"group-more-style",title:JE("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:JE("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:JE("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:JE("editor.image"),iconSvg:$k,menuKeys:["insertImage","uploadImage"]},{key:"group-video",title:JE("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","|","formatPainter","fullScreen"]};Hk.setToolbarConfig(qk);var Kk={toolbarKeys:["blockquote","header1","header2","header3","|","bold","underline","italic","through","color","bgColor","clearStyle","|","bulletedList","numberedList","todo","justifyLeft","justifyRight","justifyCenter","|","insertLink",{key:"group-image",title:JE("editor.image"),iconSvg:$k,menuKeys:["insertImage","uploadImage"]},"insertVideo","insertTable","codeBlock","|","undo","redo","|","fullScreen"]};function Yk(e){void 0===e&&(e={});var t=e.selector,n=void 0===t?"":t,r=e.content,o=void 0===r?[]:r,i=e.html,a=e.config,s=void 0===a?{}:a,u=e.mode,l="simple"===(void 0===u?"default":u)?Hk.simpleEditorConfig:Hk.editorConfig,c=Yg(Yg({},l.hoverbarKeys||{}),s.hoverbarKeys||{});return YD({selector:n,config:Yg(Yg(Yg({},l),s),{hoverbarKeys:c}),content:o,html:i,plugins:Hk.plugins})}function Xk(e){var t=e.selector,n=e.editor,r=e.config,o=void 0===r?{}:r,i=e.mode,a=void 0===i?"default":i;if(!t)throw new Error("Cannot find 'selector' when create toolbar");var s="simple"===a?Hk.simpleToolbarConfig:Hk.toolbarConfig;return ZD(n,{selector:t,config:Yg(Yg({},s),o)})}Hk.setSimpleToolbarConfig(Kk);var Zk={};export{Hk as Boot,Py as DomEditor,Kh as SlateEditor,$h as SlateElement,Yh as SlateLocation,eg as SlateNode,og as SlatePath,ug as SlatePoint,fg as SlateRange,Cg as SlateText,jg as SlateTransforms,XD as Toolbar,Yk as createEditor,Xk as createToolbar,qA as createUploader,Zk as default,dC as genModalButtonElems,lC as genModalInputElems,cC as genModalTextareaElems,KE as i18nAddResources,YE as i18nChangeLanguage,XE as i18nGetResources,JE as t};
|
|
26
|
+
*/e.exports&&(e.exports=t),void 0!==y&&(y.Prism=t),t.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"},{pattern:/^(\s*)["']|["']$/,lookbehind:!0}]}},punctuation:/\/?>/,"attr-name":{pattern:/[^\s>\/]+/,inside:{namespace:/^[^\s>\/:]+:/}}}},entity:[{pattern:/&[\da-z]{1,8};/i,alias:"named-entity"},/&#x?[\da-f]{1,8};/i]},t.languages.markup.tag.inside["attr-value"].inside.entity=t.languages.markup.entity,t.languages.markup.doctype.inside["internal-subset"].inside=t.languages.markup,t.hooks.add("wrap",function(e){"entity"===e.type&&(e.attributes.title=e.content.replace(/&/,"&"))}),Object.defineProperty(t.languages.markup.tag,"addInlined",{value:function(e,r){var n={};n["language-"+r]={pattern:/(^<!\[CDATA\[)[\s\S]+?(?=\]\]>$)/i,lookbehind:!0,inside:t.languages[r]},n.cdata=/^<!\[CDATA\[|\]\]>$/i;var o={"included-cdata":{pattern:/<!\[CDATA\[[\s\S]*?\]\]>/i,inside:n}};o["language-"+r]={pattern:/[\s\S]+/,inside:t.languages[r]};var i={};i[e]={pattern:RegExp(/(<__[^>]*>)(?:<!\[CDATA\[(?:[^\]]|\](?!\]>))*\]\]>|(?!<!\[CDATA\[)[\s\S])*?(?=<\/__>)/.source.replace(/__/g,function(){return e}),"i"),lookbehind:!0,greedy:!0,inside:o},t.languages.insertBefore("markup","cdata",i)}}),Object.defineProperty(t.languages.markup.tag,"addAttribute",{value:function(e,r){t.languages.markup.tag.inside["special-attr"].push({pattern:RegExp(/(^|["'\s])/.source+"(?:"+e+")"+/\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:t.languages[r]},punctuation:[{pattern:/^=/,alias:"attr-equals"},/"|'/]}}}})}}),t.languages.html=t.languages.markup,t.languages.mathml=t.languages.markup,t.languages.svg=t.languages.markup,t.languages.xml=t.languages.extend("markup",{}),t.languages.ssml=t.languages.xml,t.languages.atom=t.languages.xml,t.languages.rss=t.languages.xml,function(e){var t=/(?:"(?:\\(?:\r\n|[\s\S])|[^"\\\r\n])*"|'(?:\\(?:\r\n|[\s\S])|[^'\\\r\n])*')/;e.languages.css={comment:/\/\*[\s\S]*?\*\//,atrule:{pattern:RegExp("@[\\w-](?:"+/[^;{\s"']|\s+(?!\s)/.source+"|"+t.source+")*?"+/(?:;|(?=\s*\{))/.source),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\\((?:"+t.source+"|"+/(?:[^\\\r\n()"']|\\[\s\S])*/.source+")\\)","i"),greedy:!0,inside:{function:/^url/i,punctuation:/^\(|\)$/,string:{pattern:RegExp("^"+t.source+"$"),alias:"url"}}},selector:{pattern:RegExp("(^|[{}\\s])[^{}\\s](?:[^{};\"'\\s]|\\s+(?![\\s{])|"+t.source+")*(?=\\s*\\{)"),lookbehind:!0},string:{pattern:t,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:/[(){};:,]/},e.languages.css.atrule.inside.rest=e.languages.css;var r=e.languages.markup;r&&(r.tag.addInlined("style","css"),r.tag.addAttribute("style","css"))}(t),t.languages.clike={comment:[{pattern:/(^|[^\\])\/\*[\s\S]*?(?:\*\/|$)/,lookbehind:!0,greedy:!0},{pattern:/(^|[^\\:])\/\/.*/,lookbehind:!0,greedy:!0}],string:{pattern:/(["'])(?:\\(?:\r\n|[\s\S])|(?!\1)[^\\\r\n])*\1/,greedy:!0},"class-name":{pattern:/(\b(?:class|extends|implements|instanceof|interface|new|trait)\s+|\bcatch\s+\()[\w.\\]+/i,lookbehind:!0,inside:{punctuation:/[.\\]/}},keyword:/\b(?:break|catch|continue|do|else|finally|for|function|if|in|instanceof|new|null|return|throw|try|while)\b/,boolean:/\b(?:false|true)\b/,function:/\b\w+(?=\()/,number:/\b0x[\da-f]+\b|(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:e[+-]?\d+)?/i,operator:/[<>]=?|[!=]=?=?|--?|\+\+?|&&?|\|\|?|[?*/~^%]/,punctuation:/[{}[\];(),.:]/},t.languages.javascript=t.languages.extend("clike",{"class-name":[t.languages.clike["class-name"],{pattern:/(^|[^$\w\xA0-\uFFFF])(?!\s)[_$A-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\.(?:constructor|prototype))/,lookbehind:!0}],keyword:[{pattern:/((?:^|\})\s*)catch\b/,lookbehind:!0},{pattern:/(^|[^.]|\.\.\.\s*)\b(?:as|assert(?=\s*\{)|async(?=\s*(?:function\b|\(|[$\w\xA0-\uFFFF]|$))|await|break|case|class|const|continue|debugger|default|delete|do|else|enum|export|extends|finally(?=\s*(?:\{|$))|for|from(?=\s*(?:['"]|$))|function|(?:get|set)(?=\s*(?:[#\[$\w\xA0-\uFFFF]|$))|if|implements|import|in|instanceof|interface|let|new|null|of|package|private|protected|public|return|static|super|switch|this|throw|try|typeof|undefined|var|void|while|with|yield)\b/,lookbehind:!0}],function:/#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*(?:\.\s*(?:apply|bind|call)\s*)?\()/,number:{pattern:RegExp(/(^|[^\w$])/.source+"(?:"+/NaN|Infinity/.source+"|"+/0[bB][01]+(?:_[01]+)*n?/.source+"|"+/0[oO][0-7]+(?:_[0-7]+)*n?/.source+"|"+/0[xX][\dA-Fa-f]+(?:_[\dA-Fa-f]+)*n?/.source+"|"+/\d+(?:_\d+)*n/.source+"|"+/(?:\d+(?:_\d+)*(?:\.(?:\d+(?:_\d+)*)?)?|\.\d+(?:_\d+)*)(?:[Ee][+-]?\d+(?:_\d+)*)?/.source+")"+/(?![\w$])/.source),lookbehind:!0},operator:/--|\+\+|\*\*=?|=>|&&=?|\|\|=?|[!=]==|<<=?|>>>?=?|[-+*/%&|^!=<>]=?|\.{3}|\?\?=?|\?\.?|[~:]/}),t.languages.javascript["class-name"][0].pattern=/(\b(?:class|extends|implements|instanceof|interface|new)\s+)[\w.\\]+/,t.languages.insertBefore("javascript","keyword",{regex:{pattern:RegExp(/((?:^|[^$\w\xA0-\uFFFF."'\])\s]|\b(?:return|yield))\s*)/.source+/\//.source+"(?:"+/(?:\[(?:[^\]\\\r\n]|\\.)*\]|\\.|[^/\\\[\r\n])+\/[dgimyus]{0,7}/.source+"|"+/(?:\[(?:[^[\]\\\r\n]|\\.|\[(?:[^[\]\\\r\n]|\\.|\[(?:[^[\]\\\r\n]|\\.)*\])*\])*\]|\\.|[^/\\\[\r\n])+\/[dgimyus]{0,7}v[dgimyus]{0,7}/.source+")"+/(?=(?:\s|\/\*(?:[^*]|\*(?!\/))*\*\/)*(?:$|[\r\n,.;:})\]]|\/\/))/.source),lookbehind:!0,greedy:!0,inside:{"regex-source":{pattern:/^(\/)[\s\S]+(?=\/[a-z]*$)/,lookbehind:!0,alias:"language-regex",inside:t.languages.regex},"regex-delimiter":/^\/|\/$/,"regex-flags":/^[a-z]+$/}},"function-variable":{pattern:/#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*[=:]\s*(?:async\s*)?(?:\bfunction\b|(?:\((?:[^()]|\([^()]*\))*\)|(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*)\s*=>))/,alias:"function"},parameter:[{pattern:/(function(?:\s+(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*)?\s*\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\))/,lookbehind:!0,inside:t.languages.javascript},{pattern:/(^|[^$\w\xA0-\uFFFF])(?!\s)[_$a-z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*=>)/i,lookbehind:!0,inside:t.languages.javascript},{pattern:/(\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\)\s*=>)/,lookbehind:!0,inside:t.languages.javascript},{pattern:/((?:\b|\s|^)(?!(?:as|async|await|break|case|catch|class|const|continue|debugger|default|delete|do|else|enum|export|extends|finally|for|from|function|get|if|implements|import|in|instanceof|interface|let|new|null|of|package|private|protected|public|return|set|static|super|switch|this|throw|try|typeof|undefined|var|void|while|with|yield)(?![$\w\xA0-\uFFFF]))(?:(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*\s*)\(\s*|\]\s*\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\)\s*\{)/,lookbehind:!0,inside:t.languages.javascript}],constant:/\b[A-Z](?:[A-Z_]|\dx?)*\b/}),t.languages.insertBefore("javascript","string",{hashbang:{pattern:/^#!.*/,greedy:!0,alias:"comment"},"template-string":{pattern:/`(?:\\[\s\S]|\$\{(?:[^{}]|\{(?:[^{}]|\{[^}]*\})*\})+\}|(?!\$\{)[^\\`])*`/,greedy:!0,inside:{"template-punctuation":{pattern:/^`|`$/,alias:"string"},interpolation:{pattern:/((?:^|[^\\])(?:\\{2})*)\$\{(?:[^{}]|\{(?:[^{}]|\{[^}]*\})*\})+\}/,lookbehind:!0,inside:{"interpolation-punctuation":{pattern:/^\$\{|\}$/,alias:"punctuation"},rest:t.languages.javascript}},string:/[\s\S]+/}},"string-property":{pattern:/((?:^|[,{])[ \t]*)(["'])(?:\\(?:\r\n|[\s\S])|(?!\2)[^\\\r\n])*\2(?=\s*:)/m,lookbehind:!0,greedy:!0,alias:"property"}}),t.languages.insertBefore("javascript","operator",{"literal-property":{pattern:/((?:^|[,{])[ \t]*)(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*:)/m,lookbehind:!0,alias:"property"}}),t.languages.markup&&(t.languages.markup.tag.addInlined("script","javascript"),t.languages.markup.tag.addAttribute(/on(?:abort|blur|change|click|composition(?:end|start|update)|dblclick|error|focus(?:in|out)?|key(?:down|up)|load|mouse(?:down|enter|leave|move|out|over|up)|reset|resize|scroll|select|slotchange|submit|unload|wheel)/.source,"javascript")),t.languages.js=t.languages.javascript,function(){if(void 0!==t&&"undefined"!=typeof document){Element.prototype.matches||(Element.prototype.matches=Element.prototype.msMatchesSelector||Element.prototype.webkitMatchesSelector);var e={js:"javascript",py:"python",rb:"ruby",ps1:"powershell",psm1:"powershell",sh:"bash",bat:"batch",h:"c",tex:"latex"},r="data-src-status",n="loading",o="loaded",i="pre[data-src]:not(["+r+'="'+o+'"]):not(['+r+'="'+n+'"])';t.hooks.add("before-highlightall",function(e){e.selector+=", "+i}),t.hooks.add("before-sanity-check",function(a){var s=a.element;if(s.matches(i)){a.code="",s.setAttribute(r,n);var u=s.appendChild(document.createElement("CODE"));u.textContent="Loading…";var l=s.getAttribute("data-src"),c=a.language;if("none"===c){var d=(/\.(\w+)$/.exec(l)||[,"none"])[1];c=e[d]||d}t.util.setLanguage(u,c),t.util.setLanguage(s,c);var h=t.plugins.autoloader;h&&h.loadLanguages(c),function(e,t,r){var n=new XMLHttpRequest;n.open("GET",e,!0),n.onreadystatechange=function(){4==n.readyState&&(n.status<400&&n.responseText?t(n.responseText):n.status>=400?r("✖ Error "+n.status+" while fetching file: "+n.statusText):r("✖ Error: File does not exist or is empty"))},n.send(null)}(l,function(e){s.setAttribute(r,o);var n=function(e){var t=/^\s*(\d+)\s*(?:(,)\s*(?:(\d+)\s*)?)?$/.exec(e||"");if(t){var r=Number(t[1]),n=t[2],o=t[3];return n?o?[r,Number(o)]:[r,void 0]:[r,r]}}(s.getAttribute("data-range"));if(n){var i=e.split(/\r\n?|\n/g),a=n[0],l=null==n[1]?i.length:n[1];a<0&&(a+=i.length),a=Math.max(0,Math.min(a-1,i.length)),l<0&&(l+=i.length),l=Math.max(0,Math.min(l,i.length)),e=i.slice(a,l).join("\n"),s.hasAttribute("data-start")||s.setAttribute("data-start",String(a+1))}u.textContent=e,t.highlightElement(u)},function(e){s.setAttribute(r,"failed"),u.textContent=e})}}),t.plugins.fileHighlight={highlight:function(e){for(var r,n=(e||document).querySelectorAll(i),o=0;r=n[o++];)t.highlightElement(r)}};var a=!1;t.fileHighlight=function(){a||(console.warn("Prism.fileHighlight is deprecated. Use `Prism.plugins.fileHighlight.highlight` instead."),a=!0),t.plugins.fileHighlight.highlight.apply(this,arguments)}}}()}(bk)),bk.exports),Ck=b(Dk);!function(e){var t=e.util.clone(e.languages.javascript),r=/(?:\s|\/\/.*(?!.)|\/\*(?:[^*]|\*(?!\/))\*\/)/.source,n=/(?:\{(?:\{(?:\{[^{}]*\}|[^{}])*\}|[^{}])*\})/.source,o=/(?:\{<S>*\.{3}(?:[^{}]|<BRACES>)*\})/.source;function i(e,t){return e=e.replace(/<S>/g,function(){return r}).replace(/<BRACES>/g,function(){return n}).replace(/<SPREAD>/g,function(){return o}),RegExp(e,t)}o=i(o).source,e.languages.jsx=e.languages.extend("markup",t),e.languages.jsx.tag.pattern=i(/<\/?(?:[\w.:-]+(?:<S>+(?:[\w.:$-]+(?:=(?:"(?:\\[\s\S]|[^\\"])*"|'(?:\\[\s\S]|[^\\'])*'|[^\s{'"/>=]+|<BRACES>))?|<SPREAD>))*<S>*\/?)?>/.source),e.languages.jsx.tag.inside.tag.pattern=/^<\/?[^\s>\/]*/,e.languages.jsx.tag.inside["attr-value"].pattern=/=(?!\{)(?:"(?:\\[\s\S]|[^\\"])*"|'(?:\\[\s\S]|[^\\'])*'|[^\s'">]+)/,e.languages.jsx.tag.inside.tag.inside["class-name"]=/^[A-Z]\w*(?:\.[A-Z]\w*)*$/,e.languages.jsx.tag.inside.comment=t.comment,e.languages.insertBefore("inside","attr-name",{spread:{pattern:i(/<SPREAD>/.source),inside:e.languages.jsx}},e.languages.jsx.tag),e.languages.insertBefore("inside","special-attr",{script:{pattern:i(/=<BRACES>/.source),alias:"language-javascript",inside:{"script-punctuation":{pattern:/^=(?=\{)/,alias:"punctuation"},rest:e.languages.jsx}}},e.languages.jsx.tag);var a=function(e){return e?"string"==typeof e?e:"string"==typeof e.content?e.content:e.content.map(a).join(""):""},s=function(t){for(var r=[],n=0;n<t.length;n++){var o=t[n],i=!1;if("string"!=typeof o&&("tag"===o.type&&o.content[0]&&"tag"===o.content[0].type?"</"===o.content[0].content[0].content?r.length>0&&r[r.length-1].tagName===a(o.content[0].content[1])&&r.pop():"/>"===o.content[o.content.length-1].content||r.push({tagName:a(o.content[0].content[1]),openedBraces:0}):r.length>0&&"punctuation"===o.type&&"{"===o.content?r[r.length-1].openedBraces++:r.length>0&&r[r.length-1].openedBraces>0&&"punctuation"===o.type&&"}"===o.content?r[r.length-1].openedBraces--:i=!0),(i||"string"==typeof o)&&r.length>0&&0===r[r.length-1].openedBraces){var u=a(o);n<t.length-1&&("string"==typeof t[n+1]||"plain-text"===t[n+1].type)&&(u+=a(t[n+1]),t.splice(n+1,1)),n>0&&("string"==typeof t[n-1]||"plain-text"===t[n-1].type)&&(u=a(t[n-1])+u,t.splice(n-1,1),n--),t[n]=new e.Token("plain-text",u,null,u)}o.content&&"string"!=typeof o.content&&s(o.content)}};e.hooks.add("after-tokenize",function(e){"jsx"!==e.language&&"tsx"!==e.language||s(e.tokens)})}(Prism);var wk;wk||(wk=1,function(e){e.languages.typescript=e.languages.extend("javascript",{"class-name":{pattern:/(\b(?:class|extends|implements|instanceof|interface|new|type)\s+)(?!keyof\b)(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?:\s*<(?:[^<>]|<(?:[^<>]|<[^<>]*>)*>)*>)?/,lookbehind:!0,greedy:!0,inside:null},builtin:/\b(?:Array|Function|Promise|any|boolean|console|never|number|string|symbol|unknown)\b/}),e.languages.typescript.keyword.push(/\b(?:abstract|declare|is|keyof|readonly|require)\b/,/\b(?:asserts|infer|interface|module|namespace|type)\b(?=\s*(?:[{_$a-zA-Z\xA0-\uFFFF]|$))/,/\btype\b(?=\s*(?:[\{*]|$))/),delete e.languages.typescript.parameter,delete e.languages.typescript["literal-property"];var t=e.languages.extend("typescript",{});delete t["class-name"],e.languages.typescript["class-name"].inside=t,e.languages.insertBefore("typescript","function",{decorator:{pattern:/@[$\w\xA0-\uFFFF]+/,inside:{at:{pattern:/^@/,alias:"operator"},function:/^[\s\S]+/}},"generic-function":{pattern:/#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*\s*<(?:[^<>]|<(?:[^<>]|<[^<>]*>)*>)*>(?=\s*\()/,greedy:!0,inside:{function:/^#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*/,generic:{pattern:/<[\s\S]+/,alias:"class-name",inside:t}}}}),e.languages.ts=e.languages.typescript}(Prism)),Prism.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"},{pattern:/^(\s*)["']|["']$/,lookbehind:!0}]}},punctuation:/\/?>/,"attr-name":{pattern:/[^\s>\/]+/,inside:{namespace:/^[^\s>\/:]+:/}}}},entity:[{pattern:/&[\da-z]{1,8};/i,alias:"named-entity"},/&#x?[\da-f]{1,8};/i]},Prism.languages.markup.tag.inside["attr-value"].inside.entity=Prism.languages.markup.entity,Prism.languages.markup.doctype.inside["internal-subset"].inside=Prism.languages.markup,Prism.hooks.add("wrap",function(e){"entity"===e.type&&(e.attributes.title=e.content.replace(/&/,"&"))}),Object.defineProperty(Prism.languages.markup.tag,"addInlined",{value:function(e,t){var r={};r["language-"+t]={pattern:/(^<!\[CDATA\[)[\s\S]+?(?=\]\]>$)/i,lookbehind:!0,inside:Prism.languages[t]},r.cdata=/^<!\[CDATA\[|\]\]>$/i;var n={"included-cdata":{pattern:/<!\[CDATA\[[\s\S]*?\]\]>/i,inside:r}};n["language-"+t]={pattern:/[\s\S]+/,inside:Prism.languages[t]};var o={};o[e]={pattern:RegExp(/(<__[^>]*>)(?:<!\[CDATA\[(?:[^\]]|\](?!\]>))*\]\]>|(?!<!\[CDATA\[)[\s\S])*?(?=<\/__>)/.source.replace(/__/g,function(){return e}),"i"),lookbehind:!0,greedy:!0,inside:n},Prism.languages.insertBefore("markup","cdata",o)}}),Object.defineProperty(Prism.languages.markup.tag,"addAttribute",{value:function(e,t){Prism.languages.markup.tag.inside["special-attr"].push({pattern:RegExp(/(^|["'\s])/.source+"(?:"+e+")"+/\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:[t,"language-"+t],inside:Prism.languages[t]},punctuation:[{pattern:/^=/,alias:"attr-equals"},/"|'/]}}}})}}),Prism.languages.html=Prism.languages.markup,Prism.languages.mathml=Prism.languages.markup,Prism.languages.svg=Prism.languages.markup,Prism.languages.xml=Prism.languages.extend("markup",{}),Prism.languages.ssml=Prism.languages.xml,Prism.languages.atom=Prism.languages.xml,Prism.languages.rss=Prism.languages.xml,Prism.languages.go=Prism.languages.extend("clike",{string:{pattern:/(^|[^\\])"(?:\\.|[^"\\\r\n])*"|`[^`]*`/,lookbehind:!0,greedy:!0},keyword:/\b(?:break|case|chan|const|continue|default|defer|else|fallthrough|for|func|go(?:to)?|if|import|interface|map|package|range|return|select|struct|switch|type|var)\b/,boolean:/\b(?:_|false|iota|nil|true)\b/,number:[/\b0(?:b[01_]+|o[0-7_]+)i?\b/i,/\b0x(?:[a-f\d_]+(?:\.[a-f\d_]*)?|\.[a-f\d_]+)(?:p[+-]?\d+(?:_\d+)*)?i?(?!\w)/i,/(?:\b\d[\d_]*(?:\.[\d_]*)?|\B\.\d[\d_]*)(?:e[+-]?[\d_]+)?i?(?!\w)/i],operator:/[*\/%^!=]=?|\+[=+]?|-[=-]?|\|[=|]?|&(?:=|&|\^=?)?|>(?:>=?|=)?|<(?:<=?|=|-)?|:=|\.\.\./,builtin:/\b(?:append|bool|byte|cap|close|complex|complex(?:64|128)|copy|delete|error|float(?:32|64)|u?int(?:8|16|32|64)?|imag|len|make|new|panic|print(?:ln)?|real|recover|rune|string|uintptr)\b/}),Prism.languages.insertBefore("go","string",{char:{pattern:/'(?:\\.|[^'\\\r\n]){0,10}'/,greedy:!0}}),delete Prism.languages.go["class-name"];var Ek;Ek||(Ek=1,function(e){var t=/\/\*[\s\S]*?\*\/|\/\/.*|#(?!\[).*/,r=[{pattern:/\b(?:false|true)\b/i,alias:"boolean"},{pattern:/(::\s*)\b[a-z_]\w*\b(?!\s*\()/i,greedy:!0,lookbehind:!0},{pattern:/(\b(?:case|const)\s+)\b[a-z_]\w*(?=\s*[;=])/i,greedy:!0,lookbehind:!0},/\b(?:null)\b/i,/\b[A-Z_][A-Z0-9_]*\b(?!\s*\()/],n=/\b0b[01]+(?:_[01]+)*\b|\b0o[0-7]+(?:_[0-7]+)*\b|\b0x[\da-f]+(?:_[\da-f]+)*\b|(?:\b\d+(?:_\d+)*\.?(?:\d+(?:_\d+)*)?|\B\.\d+)(?:e[+-]?\d+)?/i,o=/<?=>|\?\?=?|\.{3}|\??->|[!=]=?=?|::|\*\*=?|--|\+\+|&&|\|\||<<|>>|[?~]|[/^|%*&<>.+-]=?/,i=/[{}\[\](),:;]/;e.languages.php={delimiter:{pattern:/\?>$|^<\?(?:php(?=\s)|=)?/i,alias:"important"},comment:t,variable:/\$+(?:\w+\b|(?=\{))/,package:{pattern:/(namespace\s+|use\s+(?:function\s+)?)(?:\\?\b[a-z_]\w*)+\b(?!\\)/i,lookbehind:!0,inside:{punctuation:/\\/}},"class-name-definition":{pattern:/(\b(?:class|enum|interface|trait)\s+)\b[a-z_]\w*(?!\\)\b/i,lookbehind:!0,alias:"class-name"},"function-definition":{pattern:/(\bfunction\s+)[a-z_]\w*(?=\s*\()/i,lookbehind:!0,alias:"function"},keyword:[{pattern:/(\(\s*)\b(?:array|bool|boolean|float|int|integer|object|string)\b(?=\s*\))/i,alias:"type-casting",greedy:!0,lookbehind:!0},{pattern:/([(,?]\s*)\b(?:array(?!\s*\()|bool|callable|(?:false|null)(?=\s*\|)|float|int|iterable|mixed|object|self|static|string)\b(?=\s*\$)/i,alias:"type-hint",greedy:!0,lookbehind:!0},{pattern:/(\)\s*:\s*(?:\?\s*)?)\b(?:array(?!\s*\()|bool|callable|(?:false|null)(?=\s*\|)|float|int|iterable|mixed|never|object|self|static|string|void)\b/i,alias:"return-type",greedy:!0,lookbehind:!0},{pattern:/\b(?:array(?!\s*\()|bool|float|int|iterable|mixed|object|string|void)\b/i,alias:"type-declaration",greedy:!0},{pattern:/(\|\s*)(?:false|null)\b|\b(?:false|null)(?=\s*\|)/i,alias:"type-declaration",greedy:!0,lookbehind:!0},{pattern:/\b(?:parent|self|static)(?=\s*::)/i,alias:"static-context",greedy:!0},{pattern:/(\byield\s+)from\b/i,lookbehind:!0},/\bclass\b/i,{pattern:/((?:^|[^\s>:]|(?:^|[^-])>|(?:^|[^:]):)\s*)\b(?:abstract|and|array|as|break|callable|case|catch|clone|const|continue|declare|default|die|do|echo|else|elseif|empty|enddeclare|endfor|endforeach|endif|endswitch|endwhile|enum|eval|exit|extends|final|finally|fn|for|foreach|function|global|goto|if|implements|include|include_once|instanceof|insteadof|interface|isset|list|match|namespace|never|new|or|parent|print|private|protected|public|readonly|require|require_once|return|self|static|switch|throw|trait|try|unset|use|var|while|xor|yield|__halt_compiler)\b/i,lookbehind:!0}],"argument-name":{pattern:/([(,]\s*)\b[a-z_]\w*(?=\s*:(?!:))/i,lookbehind:!0},"class-name":[{pattern:/(\b(?:extends|implements|instanceof|new(?!\s+self|\s+static))\s+|\bcatch\s*\()\b[a-z_]\w*(?!\\)\b/i,greedy:!0,lookbehind:!0},{pattern:/(\|\s*)\b[a-z_]\w*(?!\\)\b/i,greedy:!0,lookbehind:!0},{pattern:/\b[a-z_]\w*(?!\\)\b(?=\s*\|)/i,greedy:!0},{pattern:/(\|\s*)(?:\\?\b[a-z_]\w*)+\b/i,alias:"class-name-fully-qualified",greedy:!0,lookbehind:!0,inside:{punctuation:/\\/}},{pattern:/(?:\\?\b[a-z_]\w*)+\b(?=\s*\|)/i,alias:"class-name-fully-qualified",greedy:!0,inside:{punctuation:/\\/}},{pattern:/(\b(?:extends|implements|instanceof|new(?!\s+self\b|\s+static\b))\s+|\bcatch\s*\()(?:\\?\b[a-z_]\w*)+\b(?!\\)/i,alias:"class-name-fully-qualified",greedy:!0,lookbehind:!0,inside:{punctuation:/\\/}},{pattern:/\b[a-z_]\w*(?=\s*\$)/i,alias:"type-declaration",greedy:!0},{pattern:/(?:\\?\b[a-z_]\w*)+(?=\s*\$)/i,alias:["class-name-fully-qualified","type-declaration"],greedy:!0,inside:{punctuation:/\\/}},{pattern:/\b[a-z_]\w*(?=\s*::)/i,alias:"static-context",greedy:!0},{pattern:/(?:\\?\b[a-z_]\w*)+(?=\s*::)/i,alias:["class-name-fully-qualified","static-context"],greedy:!0,inside:{punctuation:/\\/}},{pattern:/([(,?]\s*)[a-z_]\w*(?=\s*\$)/i,alias:"type-hint",greedy:!0,lookbehind:!0},{pattern:/([(,?]\s*)(?:\\?\b[a-z_]\w*)+(?=\s*\$)/i,alias:["class-name-fully-qualified","type-hint"],greedy:!0,lookbehind:!0,inside:{punctuation:/\\/}},{pattern:/(\)\s*:\s*(?:\?\s*)?)\b[a-z_]\w*(?!\\)\b/i,alias:"return-type",greedy:!0,lookbehind:!0},{pattern:/(\)\s*:\s*(?:\?\s*)?)(?:\\?\b[a-z_]\w*)+\b(?!\\)/i,alias:["class-name-fully-qualified","return-type"],greedy:!0,lookbehind:!0,inside:{punctuation:/\\/}}],constant:r,function:{pattern:/(^|[^\\\w])\\?[a-z_](?:[\w\\]*\w)?(?=\s*\()/i,lookbehind:!0,inside:{punctuation:/\\/}},property:{pattern:/(->\s*)\w+/,lookbehind:!0},number:n,operator:o,punctuation:i};var a={pattern:/\{\$(?:\{(?:\{[^{}]+\}|[^{}]+)\}|[^{}])+\}|(^|[^\\{])\$+(?:\w+(?:\[[^\r\n\[\]]+\]|->\w+)?)/,lookbehind:!0,inside:e.languages.php},s=[{pattern:/<<<'([^']+)'[\r\n](?:.*[\r\n])*?\1;/,alias:"nowdoc-string",greedy:!0,inside:{delimiter:{pattern:/^<<<'[^']+'|[a-z_]\w*;$/i,alias:"symbol",inside:{punctuation:/^<<<'?|[';]$/}}}},{pattern:/<<<(?:"([^"]+)"[\r\n](?:.*[\r\n])*?\1;|([a-z_]\w*)[\r\n](?:.*[\r\n])*?\2;)/i,alias:"heredoc-string",greedy:!0,inside:{delimiter:{pattern:/^<<<(?:"[^"]+"|[a-z_]\w*)|[a-z_]\w*;$/i,alias:"symbol",inside:{punctuation:/^<<<"?|[";]$/}},interpolation:a}},{pattern:/`(?:\\[\s\S]|[^\\`])*`/,alias:"backtick-quoted-string",greedy:!0},{pattern:/'(?:\\[\s\S]|[^\\'])*'/,alias:"single-quoted-string",greedy:!0},{pattern:/"(?:\\[\s\S]|[^\\"])*"/,alias:"double-quoted-string",greedy:!0,inside:{interpolation:a}}];e.languages.insertBefore("php","variable",{string:s,attribute:{pattern:/#\[(?:[^"'\/#]|\/(?![*/])|\/\/.*$|#(?!\[).*$|\/\*(?:[^*]|\*(?!\/))*\*\/|"(?:\\[\s\S]|[^\\"])*"|'(?:\\[\s\S]|[^\\'])*')+\](?=\s*[a-z$#])/im,greedy:!0,inside:{"attribute-content":{pattern:/^(#\[)[\s\S]+(?=\]$)/,lookbehind:!0,inside:{comment:t,string:s,"attribute-class-name":[{pattern:/([^:]|^)\b[a-z_]\w*(?!\\)\b/i,alias:"class-name",greedy:!0,lookbehind:!0},{pattern:/([^:]|^)(?:\\?\b[a-z_]\w*)+/i,alias:["class-name","class-name-fully-qualified"],greedy:!0,lookbehind:!0,inside:{punctuation:/\\/}}],constant:r,number:n,operator:o,punctuation:i}},delimiter:{pattern:/^#\[|\]$/,alias:"punctuation"}}}}),e.hooks.add("before-tokenize",function(t){/<\?/.test(t.code)&&e.languages["markup-templating"].buildPlaceholders(t,"php",/<\?(?:[^"'/#]|\/(?![*/])|("|')(?:\\[\s\S]|(?!\1)[^\\])*\1|(?:\/\/|#(?!\[))(?:[^?\n\r]|\?(?!>))*(?=$|\?>|[\r\n])|#\[|\/\*(?:[^*]|\*(?!\/))*(?:\*\/|$))*?(?:\?>|$)/g)}),e.hooks.add("after-tokenize",function(t){e.languages["markup-templating"].tokenizePlaceholders(t,"php")})}(Prism)),Prism.languages.c=Prism.languages.extend("clike",{comment:{pattern:/\/\/(?:[^\r\n\\]|\\(?:\r\n?|\n|(?![\r\n])))*|\/\*[\s\S]*?(?:\*\/|$)/,greedy:!0},string:{pattern:/"(?:\\(?:\r\n|[\s\S])|[^"\\\r\n])*"/,greedy:!0},"class-name":{pattern:/(\b(?:enum|struct)\s+(?:__attribute__\s*\(\([\s\S]*?\)\)\s*)?)\w+|\b[a-z]\w*_t\b/,lookbehind:!0},keyword:/\b(?:_Alignas|_Alignof|_Atomic|_Bool|_Complex|_Generic|_Imaginary|_Noreturn|_Static_assert|_Thread_local|__attribute__|asm|auto|break|case|char|const|continue|default|do|double|else|enum|extern|float|for|goto|if|inline|int|long|register|return|short|signed|sizeof|static|struct|switch|typedef|typeof|union|unsigned|void|volatile|while)\b/,function:/\b[a-z_]\w*(?=\s*\()/i,number:/(?:\b0x(?:[\da-f]+(?:\.[\da-f]*)?|\.[\da-f]+)(?:p[+-]?\d+)?|(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:e[+-]?\d+)?)[ful]{0,4}/i,operator:/>>=?|<<=?|->|([-+&|:])\1|[?:~]|[-+*/%&|^!=<>]=?/}),Prism.languages.insertBefore("c","string",{char:{pattern:/'(?:\\(?:\r\n|[\s\S])|[^'\\\r\n]){0,32}'/,greedy:!0}}),Prism.languages.insertBefore("c","string",{macro:{pattern:/(^[\t ]*)#\s*[a-z](?:[^\r\n\\/]|\/(?!\*)|\/\*(?:[^*]|\*(?!\/))*\*\/|\\(?:\r\n|[\s\S]))*/im,lookbehind:!0,greedy:!0,alias:"property",inside:{string:[{pattern:/^(#\s*include\s*)<[^>]+>/,lookbehind:!0},Prism.languages.c.string],char:Prism.languages.c.char,comment:Prism.languages.c.comment,"macro-name":[{pattern:/(^#\s*define\s+)\w+\b(?!\()/i,lookbehind:!0},{pattern:/(^#\s*define\s+)\w+\b(?=\()/i,lookbehind:!0,alias:"function"}],directive:{pattern:/^(#\s*)[a-z]+/,lookbehind:!0,alias:"keyword"},"directive-hash":/^#/,punctuation:/##|\\(?=[\r\n])/,expression:{pattern:/\S[\s\S]*/,inside:Prism.languages.c}}}}),Prism.languages.insertBefore("c","function",{constant:/\b(?:EOF|NULL|SEEK_CUR|SEEK_END|SEEK_SET|__DATE__|__FILE__|__LINE__|__TIMESTAMP__|__TIME__|__func__|stderr|stdin|stdout)\b/}),delete Prism.languages.c.boolean;var Ak;Ak||(Ak=1,Prism.languages.python={comment:{pattern:/(^|[^\\])#.*/,lookbehind:!0,greedy:!0},"string-interpolation":{pattern:/(?:f|fr|rf)(?:("""|''')[\s\S]*?\1|("|')(?:\\.|(?!\2)[^\\\r\n])*\2)/i,greedy:!0,inside:{interpolation:{pattern:/((?:^|[^{])(?:\{\{)*)\{(?!\{)(?:[^{}]|\{(?!\{)(?:[^{}]|\{(?!\{)(?:[^{}])+\})+\})+\}/,lookbehind:!0,inside:{"format-spec":{pattern:/(:)[^:(){}]+(?=\}$)/,lookbehind:!0},"conversion-option":{pattern://,alias:"punctuation"},rest:null}},string:/[\s\S]+/}},"triple-quoted-string":{pattern:/(?:[rub]|br|rb)?("""|''')[\s\S]*?\1/i,greedy:!0,alias:"string"},string:{pattern:/(?:[rub]|br|rb)?("|')(?:\\.|(?!\1)[^\\\r\n])*\1/i,greedy:!0},function:{pattern:/((?:^|\s)def[ \t]+)[a-zA-Z_]\w*(?=\s*\()/g,lookbehind:!0},"class-name":{pattern:/(\bclass\s+)\w+/i,lookbehind:!0},decorator:{pattern:/(^[\t ]*)@\w+(?:\.\w+)*/m,lookbehind:!0,alias:["annotation","punctuation"],inside:{punctuation:/\./}},keyword:/\b(?:_(?=\s*:)|and|as|assert|async|await|break|case|class|continue|def|del|elif|else|except|exec|finally|for|from|global|if|import|in|is|lambda|match|nonlocal|not|or|pass|print|raise|return|try|while|with|yield)\b/,builtin:/\b(?:__import__|abs|all|any|apply|ascii|basestring|bin|bool|buffer|bytearray|bytes|callable|chr|classmethod|cmp|coerce|compile|complex|delattr|dict|dir|divmod|enumerate|eval|execfile|file|filter|float|format|frozenset|getattr|globals|hasattr|hash|help|hex|id|input|int|intern|isinstance|issubclass|iter|len|list|locals|long|map|max|memoryview|min|next|object|oct|open|ord|pow|property|range|raw_input|reduce|reload|repr|reversed|round|set|setattr|slice|sorted|staticmethod|str|sum|super|tuple|type|unichr|unicode|vars|xrange|zip)\b/,boolean:/\b(?:False|None|True)\b/,number:/\b0(?:b(?:_?[01])+|o(?:_?[0-7])+|x(?:_?[a-f0-9])+)\b|(?:\b\d+(?:_\d+)*(?:\.(?:\d+(?:_\d+)*)?)?|\B\.\d+(?:_\d+)*)(?:e[+-]?\d+(?:_\d+)*)?j?(?!\w)/i,operator:/[-+%=]=?|!=|:=|\*\*?=?|\/\/?=?|<[<=>]?|>[=>]?|[&|^~]/,punctuation:/[{}[\];(),.:]/},Prism.languages.python["string-interpolation"].inside.interpolation.inside.rest=Prism.languages.python,Prism.languages.py=Prism.languages.python);var xk;xk||(xk=1,function(e){var t=/\b(?:abstract|assert|boolean|break|byte|case|catch|char|class|const|continue|default|do|double|else|enum|exports|extends|final|finally|float|for|goto|if|implements|import|instanceof|int|interface|long|module|native|new|non-sealed|null|open|opens|package|permits|private|protected|provides|public|record(?!\s*[(){}[\]<>=%~.:,;?+\-*/&|^])|requires|return|sealed|short|static|strictfp|super|switch|synchronized|this|throw|throws|to|transient|transitive|try|uses|var|void|volatile|while|with|yield)\b/,r=/(?:[a-z]\w*\s*\.\s*)*(?:[A-Z]\w*\s*\.\s*)*/.source,n={pattern:RegExp(/(^|[^\w.])/.source+r+/[A-Z](?:[\d_A-Z]*[a-z]\w*)?\b/.source),lookbehind:!0,inside:{namespace:{pattern:/^[a-z]\w*(?:\s*\.\s*[a-z]\w*)*(?:\s*\.)?/,inside:{punctuation:/\./}},punctuation:/\./}};e.languages.java=e.languages.extend("clike",{string:{pattern:/(^|[^\\])"(?:\\.|[^"\\\r\n])*"/,lookbehind:!0,greedy:!0},"class-name":[n,{pattern:RegExp(/(^|[^\w.])/.source+r+/[A-Z]\w*(?=\s+\w+\s*[;,=()]|\s*(?:\[[\s,]*\]\s*)?::\s*new\b)/.source),lookbehind:!0,inside:n.inside},{pattern:RegExp(/(\b(?:class|enum|extends|implements|instanceof|interface|new|record|throws)\s+)/.source+r+/[A-Z]\w*\b/.source),lookbehind:!0,inside:n.inside}],keyword:t,function:[e.languages.clike.function,{pattern:/(::\s*)[a-z_]\w*/,lookbehind:!0}],number:/\b0b[01][01_]*L?\b|\b0x(?:\.[\da-f_p+-]+|[\da-f_]+(?:\.[\da-f_p+-]+)?)\b|(?:\b\d[\d_]*(?:\.[\d_]*)?|\B\.\d[\d_]*)(?:e[+-]?\d[\d_]*)?[dfl]?/i,operator:{pattern:/(^|[^.])(?:<<=?|>>>?=?|->|--|\+\+|&&|\|\||::|[?:~]|[-+*/%&|^!=<>]=?)/m,lookbehind:!0},constant:/\b[A-Z][A-Z_\d]+\b/}),e.languages.insertBefore("java","string",{"triple-quoted-string":{pattern:/"""[ \t]*[\r\n](?:(?:"|"")?(?:\\.|[^"\\]))*"""/,greedy:!0,alias:"string"},char:{pattern:/'(?:\\.|[^'\\\r\n]){1,6}'/,greedy:!0}}),e.languages.insertBefore("java","class-name",{annotation:{pattern:/(^|[^.])@\w+(?:\s*\.\s*\w+)*/,lookbehind:!0,alias:"punctuation"},generics:{pattern:/<(?:[\w\s,.?]|&(?!&)|<(?:[\w\s,.?]|&(?!&)|<(?:[\w\s,.?]|&(?!&)|<(?:[\w\s,.?]|&(?!&))*>)*>)*>)*>/,inside:{"class-name":n,keyword:t,punctuation:/[<>(),.:]/,operator:/[?&|]/}},import:[{pattern:RegExp(/(\bimport\s+)/.source+r+/(?:[A-Z]\w*|\*)(?=\s*;)/.source),lookbehind:!0,inside:{namespace:n.inside.namespace,punctuation:/\./,operator:/\*/,"class-name":/\w+/}},{pattern:RegExp(/(\bimport\s+static\s+)/.source+r+/(?:\w+|\*)(?=\s*;)/.source),lookbehind:!0,alias:"static",inside:{namespace:n.inside.namespace,static:/\b\w+$/,punctuation:/\./,operator:/\*/,"class-name":/\w+/}}],namespace:{pattern:RegExp(/(\b(?:exports|import(?:\s+static)?|module|open|opens|package|provides|requires|to|transitive|uses|with)\s+)(?!<keyword>)[a-z]\w*(?:\.[a-z]\w*)*\.?/.source.replace(/<keyword>/g,function(){return t.source})),lookbehind:!0,inside:{punctuation:/\./}}})}(Prism));var Bk;Bk||(Bk=1,function(e){var t=/\b(?:alignas|alignof|asm|auto|bool|break|case|catch|char|char16_t|char32_t|char8_t|class|co_await|co_return|co_yield|compl|concept|const|const_cast|consteval|constexpr|constinit|continue|decltype|default|delete|do|double|dynamic_cast|else|enum|explicit|export|extern|final|float|for|friend|goto|if|import|inline|int|int16_t|int32_t|int64_t|int8_t|long|module|mutable|namespace|new|noexcept|nullptr|operator|override|private|protected|public|register|reinterpret_cast|requires|return|short|signed|sizeof|static|static_assert|static_cast|struct|switch|template|this|thread_local|throw|try|typedef|typeid|typename|uint16_t|uint32_t|uint64_t|uint8_t|union|unsigned|using|virtual|void|volatile|wchar_t|while)\b/,r=/\b(?!<keyword>)\w+(?:\s*\.\s*\w+)*\b/.source.replace(/<keyword>/g,function(){return t.source});e.languages.cpp=e.languages.extend("c",{"class-name":[{pattern:RegExp(/(\b(?:class|concept|enum|struct|typename)\s+)(?!<keyword>)\w+/.source.replace(/<keyword>/g,function(){return t.source})),lookbehind:!0},/\b[A-Z]\w*(?=\s*::\s*\w+\s*\()/,/\b[A-Z_]\w*(?=\s*::\s*~\w+\s*\()/i,/\b\w+(?=\s*<(?:[^<>]|<(?:[^<>]|<[^<>]*>)*>)*>\s*::\s*\w+\s*\()/],keyword:t,number:{pattern:/(?:\b0b[01']+|\b0x(?:[\da-f']+(?:\.[\da-f']*)?|\.[\da-f']+)(?:p[+-]?[\d']+)?|(?:\b[\d']+(?:\.[\d']*)?|\B\.[\d']+)(?:e[+-]?[\d']+)?)[ful]{0,4}/i,greedy:!0},operator:/>>=?|<<=?|->|--|\+\+|&&|\|\||[?:~]|<=>|[-+*/%&|^!=<>]=?|\b(?:and|and_eq|bitand|bitor|not|not_eq|or|or_eq|xor|xor_eq)\b/,boolean:/\b(?:false|true)\b/}),e.languages.insertBefore("cpp","string",{module:{pattern:RegExp(/(\b(?:import|module)\s+)/.source+"(?:"+/"(?:\\(?:\r\n|[\s\S])|[^"\\\r\n])*"|<[^<>\r\n]*>/.source+"|"+/<mod-name>(?:\s*:\s*<mod-name>)?|:\s*<mod-name>/.source.replace(/<mod-name>/g,function(){return r})+")"),lookbehind:!0,greedy:!0,inside:{string:/^[<"][\s\S]+/,operator:/:/,punctuation:/\./}},"raw-string":{pattern:/R"([^()\\ ]{0,16})\([\s\S]*?\)\1"/,alias:"string",greedy:!0}}),e.languages.insertBefore("cpp","keyword",{"generic-function":{pattern:/\b(?!operator\b)[a-z_]\w*\s*<(?:[^<>]|<[^<>]*>)*>(?=\s*\()/i,inside:{function:/^\w+/,generic:{pattern:/<[\s\S]+/,alias:"class-name",inside:e.languages.cpp}}}}),e.languages.insertBefore("cpp","operator",{"double-colon":{pattern:/::/,alias:"punctuation"}}),e.languages.insertBefore("cpp","class-name",{"base-clause":{pattern:/(\b(?:class|struct)\s+\w+\s*:\s*)[^;{}"'\s]+(?:\s+[^;{}"'\s]+)*(?=\s*[;{])/,lookbehind:!0,greedy:!0,inside:e.languages.extend("cpp",{})}}),e.languages.insertBefore("inside","double-colon",{"class-name":/\b[a-z_]\w*\b(?!\s*::)/i},e.languages.cpp["base-clause"])}(Prism));var Sk;Sk||(Sk=1,function(e){function t(e,t){return e.replace(/<<(\d+)>>/g,function(e,r){return"(?:"+t[+r]+")"})}function r(e,r,n){return RegExp(t(e,r),"")}function n(e,t){for(var r=0;r<t;r++)e=e.replace(/<<self>>/g,function(){return"(?:"+e+")"});return e.replace(/<<self>>/g,"[^\\s\\S]")}var o="bool byte char decimal double dynamic float int long object sbyte short string uint ulong ushort var void",i="class enum interface record struct",a="add alias and ascending async await by descending from(?=\\s*(?:\\w|$)) get global group into init(?=\\s*;) join let nameof not notnull on or orderby partial remove select set unmanaged value when where with(?=\\s*{)",s="abstract as base break case catch checked const continue default delegate do else event explicit extern finally fixed for foreach goto if implicit in internal is lock namespace new null operator out override params private protected public readonly ref return sealed sizeof stackalloc static switch this throw try typeof unchecked unsafe using virtual volatile while yield";function u(e){return"\\b(?:"+e.trim().replace(/ /g,"|")+")\\b"}var l=u(i),c=RegExp(u(o+" "+i+" "+a+" "+s)),d=u(i+" "+a+" "+s),h=u(o+" "+i+" "+s),f=n(/<(?:[^<>;=+\-*/%&|^]|<<self>>)*>/.source,2),p=n(/\((?:[^()]|<<self>>)*\)/.source,2),g=/@?\b[A-Za-z_]\w*\b/.source,m=t(/<<0>>(?:\s*<<1>>)?/.source,[g,f]),v=t(/(?!<<0>>)<<1>>(?:\s*\.\s*<<1>>)*/.source,[d,m]),y=/\[\s*(?:,\s*)*\]/.source,b=t(/<<0>>(?:\s*(?:\?\s*)?<<1>>)*(?:\s*\?)?/.source,[v,y]),D=t(/[^,()<>[\];=+\-*/%&|^]|<<0>>|<<1>>|<<2>>/.source,[f,p,y]),C=t(/\(<<0>>+(?:,<<0>>+)+\)/.source,[D]),w=t(/(?:<<0>>|<<1>>)(?:\s*(?:\?\s*)?<<2>>)*(?:\s*\?)?/.source,[C,v,y]),E={keyword:c,punctuation:/[<>()?,.:[\]]/},A=/'(?:[^\r\n'\\]|\\.|\\[Uux][\da-fA-F]{1,8})'/.source,x=/"(?:\\.|[^\\"\r\n])*"/.source,B=/@"(?:""|\\[\s\S]|[^\\"])*"(?!")/.source;e.languages.csharp=e.languages.extend("clike",{string:[{pattern:r(/(^|[^$\\])<<0>>/.source,[B]),lookbehind:!0,greedy:!0},{pattern:r(/(^|[^@$\\])<<0>>/.source,[x]),lookbehind:!0,greedy:!0}],"class-name":[{pattern:r(/(\busing\s+static\s+)<<0>>(?=\s*;)/.source,[v]),lookbehind:!0,inside:E},{pattern:r(/(\busing\s+<<0>>\s*=\s*)<<1>>(?=\s*;)/.source,[g,w]),lookbehind:!0,inside:E},{pattern:r(/(\busing\s+)<<0>>(?=\s*=)/.source,[g]),lookbehind:!0},{pattern:r(/(\b<<0>>\s+)<<1>>/.source,[l,m]),lookbehind:!0,inside:E},{pattern:r(/(\bcatch\s*\(\s*)<<0>>/.source,[v]),lookbehind:!0,inside:E},{pattern:r(/(\bwhere\s+)<<0>>/.source,[g]),lookbehind:!0},{pattern:r(/(\b(?:is(?:\s+not)?|as)\s+)<<0>>/.source,[b]),lookbehind:!0,inside:E},{pattern:r(/\b<<0>>(?=\s+(?!<<1>>|with\s*\{)<<2>>(?:\s*[=,;:{)\]]|\s+(?:in|when)\b))/.source,[w,h,g]),inside:E}],keyword:c,number:/(?:\b0(?:x[\da-f_]*[\da-f]|b[01_]*[01])|(?:\B\.\d+(?:_+\d+)*|\b\d+(?:_+\d+)*(?:\.\d+(?:_+\d+)*)?)(?:e[-+]?\d+(?:_+\d+)*)?)(?:[dflmu]|lu|ul)?\b/i,operator:/>>=?|<<=?|[-=]>|([-+&|])\1|~|\?\?=?|[-+*/%&|^!=<>]=?/,punctuation:/\?\.?|::|[{}[\];(),.:]/}),e.languages.insertBefore("csharp","number",{range:{pattern:/\.\./,alias:"operator"}}),e.languages.insertBefore("csharp","punctuation",{"named-parameter":{pattern:r(/([(,]\s*)<<0>>(?=\s*:)/.source,[g]),lookbehind:!0,alias:"punctuation"}}),e.languages.insertBefore("csharp","class-name",{namespace:{pattern:r(/(\b(?:namespace|using)\s+)<<0>>(?:\s*\.\s*<<0>>)*(?=\s*[;{])/.source,[g]),lookbehind:!0,inside:{punctuation:/\./}},"type-expression":{pattern:r(/(\b(?:default|sizeof|typeof)\s*\(\s*(?!\s))(?:[^()\s]|\s(?!\s)|<<0>>)*(?=\s*\))/.source,[p]),lookbehind:!0,alias:"class-name",inside:E},"return-type":{pattern:r(/<<0>>(?=\s+(?:<<1>>\s*(?:=>|[({]|\.\s*this\s*\[)|this\s*\[))/.source,[w,v]),inside:E,alias:"class-name"},"constructor-invocation":{pattern:r(/(\bnew\s+)<<0>>(?=\s*[[({])/.source,[w]),lookbehind:!0,inside:E,alias:"class-name"},"generic-method":{pattern:r(/<<0>>\s*<<1>>(?=\s*\()/.source,[g,f]),inside:{function:r(/^<<0>>/.source,[g]),generic:{pattern:RegExp(f),alias:"class-name",inside:E}}},"type-list":{pattern:r(/\b((?:<<0>>\s+<<1>>|record\s+<<1>>\s*<<5>>|where\s+<<2>>)\s*:\s*)(?:<<3>>|<<4>>|<<1>>\s*<<5>>|<<6>>)(?:\s*,\s*(?:<<3>>|<<4>>|<<6>>))*(?=\s*(?:where|[{;]|=>|$))/.source,[l,m,g,w,c.source,p,/\bnew\s*\(\s*\)/.source]),lookbehind:!0,inside:{"record-arguments":{pattern:r(/(^(?!new\s*\()<<0>>\s*)<<1>>/.source,[m,p]),lookbehind:!0,greedy:!0,inside:e.languages.csharp},keyword:c,"class-name":{pattern:RegExp(w),greedy:!0,inside:E},punctuation:/[,()]/}},preprocessor:{pattern:/(^[\t ]*)#.*/m,lookbehind:!0,alias:"property",inside:{directive:{pattern:/(#)\b(?:define|elif|else|endif|endregion|error|if|line|nullable|pragma|region|undef|warning)\b/,lookbehind:!0,alias:"keyword"}}}});var S=x+"|"+A,F=t(/\/(?![*/])|\/\/[^\r\n]*[\r\n]|\/\*(?:[^*]|\*(?!\/))*\*\/|<<0>>/.source,[S]),k=n(t(/[^"'/()]|<<0>>|\(<<self>>*\)/.source,[F]),2),O=/\b(?:assembly|event|field|method|module|param|property|return|type)\b/.source,T=t(/<<0>>(?:\s*\(<<1>>*\))?/.source,[v,k]);e.languages.insertBefore("csharp","class-name",{attribute:{pattern:r(/((?:^|[^\s\w>)?])\s*\[\s*)(?:<<0>>\s*:\s*)?<<1>>(?:\s*,\s*<<1>>)*(?=\s*\])/.source,[O,T]),lookbehind:!0,greedy:!0,inside:{target:{pattern:r(/^<<0>>(?=\s*:)/.source,[O]),alias:"keyword"},"attribute-arguments":{pattern:r(/\(<<0>>*\)/.source,[k]),inside:e.languages.csharp},"class-name":{pattern:RegExp(v),inside:{punctuation:/\./}},punctuation:/[:,]/}}});var N=/:[^}\r\n]+/.source,P=n(t(/[^"'/()]|<<0>>|\(<<self>>*\)/.source,[F]),2),M=t(/\{(?!\{)(?:(?![}:])<<0>>)*<<1>>?\}/.source,[P,N]),I=n(t(/[^"'/()]|\/(?!\*)|\/\*(?:[^*]|\*(?!\/))*\*\/|<<0>>|\(<<self>>*\)/.source,[S]),2),R=t(/\{(?!\{)(?:(?![}:])<<0>>)*<<1>>?\}/.source,[I,N]);function L(t,n){return{interpolation:{pattern:r(/((?:^|[^{])(?:\{\{)*)<<0>>/.source,[t]),lookbehind:!0,inside:{"format-string":{pattern:r(/(^\{(?:(?![}:])<<0>>)*)<<1>>(?=\}$)/.source,[n,N]),lookbehind:!0,inside:{punctuation:/^:/}},punctuation:/^\{|\}$/,expression:{pattern:/[\s\S]+/,alias:"language-csharp",inside:e.languages.csharp}}},string:/[\s\S]+/}}e.languages.insertBefore("csharp","string",{"interpolation-string":[{pattern:r(/(^|[^\\])(?:\$@|@\$)"(?:""|\\[\s\S]|\{\{|<<0>>|[^\\{"])*"/.source,[M]),lookbehind:!0,greedy:!0,inside:L(M,P)},{pattern:r(/(^|[^@\\])\$"(?:\\.|\{\{|<<0>>|[^\\"{])*"/.source,[R]),lookbehind:!0,greedy:!0,inside:L(R,I)}],char:{pattern:RegExp(A),greedy:!0}}),e.languages.dotnet=e.languages.cs=e.languages.csharp}(Prism)),Prism.languages["visual-basic"]={comment:{pattern:/(?:['‘’]|REM\b)(?:[^\r\n_]|_(?:\r\n?|\n)?)*/i,inside:{keyword:/^REM/i}},directive:{pattern:/#(?:Const|Else|ElseIf|End|ExternalChecksum|ExternalSource|If|Region)(?:\b_[ \t]*(?:\r\n?|\n)|.)+/i,alias:"property",greedy:!0},string:{pattern:/\$?["“”](?:["“”]{2}|[^"“”])*["“”]C?/i,greedy:!0},date:{pattern:/#[ \t]*(?:\d+([/-])\d+\1\d+(?:[ \t]+(?:\d+[ \t]*(?:AM|PM)|\d+:\d+(?::\d+)?(?:[ \t]*(?:AM|PM))?))?|\d+[ \t]*(?:AM|PM)|\d+:\d+(?::\d+)?(?:[ \t]*(?:AM|PM))?)[ \t]*#/i,alias:"number"},number:/(?:(?:\b\d+(?:\.\d+)?|\.\d+)(?:E[+-]?\d+)?|&[HO][\dA-F]+)(?:[FRD]|U?[ILS])?/i,boolean:/\b(?:False|Nothing|True)\b/i,keyword:/\b(?:AddHandler|AddressOf|Alias|And(?:Also)?|As|Boolean|ByRef|Byte|ByVal|Call|Case|Catch|C(?:Bool|Byte|Char|Date|Dbl|Dec|Int|Lng|Obj|SByte|Short|Sng|Str|Type|UInt|ULng|UShort)|Char|Class|Const|Continue|Currency|Date|Decimal|Declare|Default|Delegate|Dim|DirectCast|Do|Double|Each|Else(?:If)?|End(?:If)?|Enum|Erase|Error|Event|Exit|Finally|For|Friend|Function|Get(?:Type|XMLNamespace)?|Global|GoSub|GoTo|Handles|If|Implements|Imports|In|Inherits|Integer|Interface|Is|IsNot|Let|Lib|Like|Long|Loop|Me|Mod|Module|Must(?:Inherit|Override)|My(?:Base|Class)|Namespace|Narrowing|New|Next|Not(?:Inheritable|Overridable)?|Object|Of|On|Operator|Option(?:al)?|Or(?:Else)?|Out|Overloads|Overridable|Overrides|ParamArray|Partial|Private|Property|Protected|Public|RaiseEvent|ReadOnly|ReDim|RemoveHandler|Resume|Return|SByte|Select|Set|Shadows|Shared|short|Single|Static|Step|Stop|String|Structure|Sub|SyncLock|Then|Throw|To|Try|TryCast|Type|TypeOf|U(?:Integer|Long|Short)|Until|Using|Variant|Wend|When|While|Widening|With(?:Events)?|WriteOnly|Xor)\b/i,operator:/[+\-*/\\^<=>&#@$%!]|\b_(?=[ \t]*[\r\n])/,punctuation:/[{}().,:?]/},Prism.languages.vb=Prism.languages["visual-basic"],Prism.languages.vba=Prism.languages["visual-basic"],Prism.languages.sql={comment:{pattern:/(^|[^\\])(?:\/\*[\s\S]*?\*\/|(?:--|\/\/|#).*)/,lookbehind:!0},variable:[{pattern:/@(["'`])(?:\\[\s\S]|(?!\1)[^\\])+\1/,greedy:!0},/@[\w.$]+/],string:{pattern:/(^|[^@\\])("|')(?:\\[\s\S]|(?!\2)[^\\]|\2\2)*\2/,greedy:!0,lookbehind:!0},identifier:{pattern:/(^|[^@\\])`(?:\\[\s\S]|[^`\\]|``)*`/,greedy:!0,lookbehind:!0,inside:{punctuation:/^`|`$/}},function:/\b(?:AVG|COUNT|FIRST|FORMAT|LAST|LCASE|LEN|MAX|MID|MIN|MOD|NOW|ROUND|SUM|UCASE)(?=\s*\()/i,keyword:/\b(?:ACTION|ADD|AFTER|ALGORITHM|ALL|ALTER|ANALYZE|ANY|APPLY|AS|ASC|AUTHORIZATION|AUTO_INCREMENT|BACKUP|BDB|BEGIN|BERKELEYDB|BIGINT|BINARY|BIT|BLOB|BOOL|BOOLEAN|BREAK|BROWSE|BTREE|BULK|BY|CALL|CASCADED?|CASE|CHAIN|CHAR(?:ACTER|SET)?|CHECK(?:POINT)?|CLOSE|CLUSTERED|COALESCE|COLLATE|COLUMNS?|COMMENT|COMMIT(?:TED)?|COMPUTE|CONNECT|CONSISTENT|CONSTRAINT|CONTAINS(?:TABLE)?|CONTINUE|CONVERT|CREATE|CROSS|CURRENT(?:_DATE|_TIME|_TIMESTAMP|_USER)?|CURSOR|CYCLE|DATA(?:BASES?)?|DATE(?:TIME)?|DAY|DBCC|DEALLOCATE|DEC|DECIMAL|DECLARE|DEFAULT|DEFINER|DELAYED|DELETE|DELIMITERS?|DENY|DESC|DESCRIBE|DETERMINISTIC|DISABLE|DISCARD|DISK|DISTINCT|DISTINCTROW|DISTRIBUTED|DO|DOUBLE|DROP|DUMMY|DUMP(?:FILE)?|DUPLICATE|ELSE(?:IF)?|ENABLE|ENCLOSED|END|ENGINE|ENUM|ERRLVL|ERRORS|ESCAPED?|EXCEPT|EXEC(?:UTE)?|EXISTS|EXIT|EXPLAIN|EXTENDED|FETCH|FIELDS|FILE|FILLFACTOR|FIRST|FIXED|FLOAT|FOLLOWING|FOR(?: EACH ROW)?|FORCE|FOREIGN|FREETEXT(?:TABLE)?|FROM|FULL|FUNCTION|GEOMETRY(?:COLLECTION)?|GLOBAL|GOTO|GRANT|GROUP|HANDLER|HASH|HAVING|HOLDLOCK|HOUR|IDENTITY(?:COL|_INSERT)?|IF|IGNORE|IMPORT|INDEX|INFILE|INNER|INNODB|INOUT|INSERT|INT|INTEGER|INTERSECT|INTERVAL|INTO|INVOKER|ISOLATION|ITERATE|JOIN|KEYS?|KILL|LANGUAGE|LAST|LEAVE|LEFT|LEVEL|LIMIT|LINENO|LINES|LINESTRING|LOAD|LOCAL|LOCK|LONG(?:BLOB|TEXT)|LOOP|MATCH(?:ED)?|MEDIUM(?:BLOB|INT|TEXT)|MERGE|MIDDLEINT|MINUTE|MODE|MODIFIES|MODIFY|MONTH|MULTI(?:LINESTRING|POINT|POLYGON)|NATIONAL|NATURAL|NCHAR|NEXT|NO|NONCLUSTERED|NULLIF|NUMERIC|OFF?|OFFSETS?|ON|OPEN(?:DATASOURCE|QUERY|ROWSET)?|OPTIMIZE|OPTION(?:ALLY)?|ORDER|OUT(?:ER|FILE)?|OVER|PARTIAL|PARTITION|PERCENT|PIVOT|PLAN|POINT|POLYGON|PRECEDING|PRECISION|PREPARE|PREV|PRIMARY|PRINT|PRIVILEGES|PROC(?:EDURE)?|PUBLIC|PURGE|QUICK|RAISERROR|READS?|REAL|RECONFIGURE|REFERENCES|RELEASE|RENAME|REPEAT(?:ABLE)?|REPLACE|REPLICATION|REQUIRE|RESIGNAL|RESTORE|RESTRICT|RETURN(?:ING|S)?|REVOKE|RIGHT|ROLLBACK|ROUTINE|ROW(?:COUNT|GUIDCOL|S)?|RTREE|RULE|SAVE(?:POINT)?|SCHEMA|SECOND|SELECT|SERIAL(?:IZABLE)?|SESSION(?:_USER)?|SET(?:USER)?|SHARE|SHOW|SHUTDOWN|SIMPLE|SMALLINT|SNAPSHOT|SOME|SONAME|SQL|START(?:ING)?|STATISTICS|STATUS|STRIPED|SYSTEM_USER|TABLES?|TABLESPACE|TEMP(?:ORARY|TABLE)?|TERMINATED|TEXT(?:SIZE)?|THEN|TIME(?:STAMP)?|TINY(?:BLOB|INT|TEXT)|TOP?|TRAN(?:SACTIONS?)?|TRIGGER|TRUNCATE|TSEQUAL|TYPES?|UNBOUNDED|UNCOMMITTED|UNDEFINED|UNION|UNIQUE|UNLOCK|UNPIVOT|UNSIGNED|UPDATE(?:TEXT)?|USAGE|USE|USER|USING|VALUES?|VAR(?:BINARY|CHAR|CHARACTER|YING)|VIEW|WAITFOR|WARNINGS|WHEN|WHERE|WHILE|WITH(?: ROLLUP|IN)?|WORK|WRITE(?:TEXT)?|YEAR)\b/i,boolean:/\b(?:FALSE|NULL|TRUE)\b/i,number:/\b0x[\da-f]+\b|\b\d+(?:\.\d*)?|\B\.\d+\b/i,operator:/[-+*\/=%^~]|&&?|\|\|?|!=?|<(?:=>?|<|>)?|>[>=]?|\b(?:AND|BETWEEN|DIV|ILIKE|IN|IS|LIKE|NOT|OR|REGEXP|RLIKE|SOUNDS LIKE|XOR)\b/i,punctuation:/[;[\]()`,.]/};var Fk;Fk||(Fk=1,function(e){e.languages.ruby=e.languages.extend("clike",{comment:{pattern:/#.*|^=begin\s[\s\S]*?^=end/m,greedy:!0},"class-name":{pattern:/(\b(?:class|module)\s+|\bcatch\s+\()[\w.\\]+|\b[A-Z_]\w*(?=\s*\.\s*new\b)/,lookbehind:!0,inside:{punctuation:/[.\\]/}},keyword:/\b(?:BEGIN|END|alias|and|begin|break|case|class|def|define_method|defined|do|each|else|elsif|end|ensure|extend|for|if|in|include|module|new|next|nil|not|or|prepend|private|protected|public|raise|redo|require|rescue|retry|return|self|super|then|throw|undef|unless|until|when|while|yield)\b/,operator:/\.{2,3}|&\.|===|<?=>|[!=]?~|(?:&&|\|\||<<|>>|\*\*|[+\-*/%<>!^&|=])=?|[?:]/,punctuation:/[(){}[\].,;]/}),e.languages.insertBefore("ruby","operator",{"double-colon":{pattern:/::/,alias:"punctuation"}});var t={pattern:/((?:^|[^\\])(?:\\{2})*)#\{(?:[^{}]|\{[^{}]*\})*\}/,lookbehind:!0,inside:{content:{pattern:/^(#\{)[\s\S]+(?=\}$)/,lookbehind:!0,inside:e.languages.ruby},delimiter:{pattern:/^#\{|\}$/,alias:"punctuation"}}};delete e.languages.ruby.function;var r="(?:"+[/([^a-zA-Z0-9\s{(\[<=])(?:(?!\1)[^\\]|\\[\s\S])*\1/.source,/\((?:[^()\\]|\\[\s\S]|\((?:[^()\\]|\\[\s\S])*\))*\)/.source,/\{(?:[^{}\\]|\\[\s\S]|\{(?:[^{}\\]|\\[\s\S])*\})*\}/.source,/\[(?:[^\[\]\\]|\\[\s\S]|\[(?:[^\[\]\\]|\\[\s\S])*\])*\]/.source,/<(?:[^<>\\]|\\[\s\S]|<(?:[^<>\\]|\\[\s\S])*>)*>/.source].join("|")+")",n=/(?:"(?:\\.|[^"\\\r\n])*"|(?:\b[a-zA-Z_]\w*|[^\s\0-\x7F]+)[?!]?|\$.)/.source;e.languages.insertBefore("ruby","keyword",{"regex-literal":[{pattern:RegExp(/%r/.source+r+/[egimnosux]{0,6}/.source),greedy:!0,inside:{interpolation:t,regex:/[\s\S]+/}},{pattern:/(^|[^/])\/(?!\/)(?:\[[^\r\n\]]+\]|\\.|[^[/\\\r\n])+\/[egimnosux]{0,6}(?=\s*(?:$|[\r\n,.;})#]))/,lookbehind:!0,greedy:!0,inside:{interpolation:t,regex:/[\s\S]+/}}],variable:/[@$]+[a-zA-Z_]\w*(?:[?!]|\b)/,symbol:[{pattern:RegExp(/(^|[^:]):/.source+n),lookbehind:!0,greedy:!0},{pattern:RegExp(/([\r\n{(,][ \t]*)/.source+n+/(?=:(?!:))/.source),lookbehind:!0,greedy:!0}],"method-definition":{pattern:/(\bdef\s+)\w+(?:\s*\.\s*\w+)?/,lookbehind:!0,inside:{function:/\b\w+$/,keyword:/^self\b/,"class-name":/^\w+/,punctuation:/\./}}}),e.languages.insertBefore("ruby","string",{"string-literal":[{pattern:RegExp(/%[qQiIwWs]?/.source+r),greedy:!0,inside:{interpolation:t,string:/[\s\S]+/}},{pattern:/("|')(?:#\{[^}]+\}|#(?!\{)|\\(?:\r\n|[\s\S])|(?!\1)[^\\#\r\n])*\1/,greedy:!0,inside:{interpolation:t,string:/[\s\S]+/}},{pattern:/<<[-~]?([a-z_]\w*)[\r\n](?:.*[\r\n])*?[\t ]*\1/i,alias:"heredoc-string",greedy:!0,inside:{delimiter:{pattern:/^<<[-~]?[a-z_]\w*|\b[a-z_]\w*$/i,inside:{symbol:/\b\w+/,punctuation:/^<<[-~]?/}},interpolation:t,string:/[\s\S]+/}},{pattern:/<<[-~]?'([a-z_]\w*)'[\r\n](?:.*[\r\n])*?[\t ]*\1/i,alias:"heredoc-string",greedy:!0,inside:{delimiter:{pattern:/^<<[-~]?'[a-z_]\w*'|\b[a-z_]\w*$/i,inside:{symbol:/\b\w+/,punctuation:/^<<[-~]?'|'$/}},string:/[\s\S]+/}}],"command-literal":[{pattern:RegExp(/%x/.source+r),greedy:!0,inside:{interpolation:t,command:{pattern:/[\s\S]+/,alias:"string"}}},{pattern:/`(?:#\{[^}]+\}|#(?!\{)|\\(?:\r\n|[\s\S])|[^\\`#\r\n])*`/,greedy:!0,inside:{interpolation:t,command:{pattern:/[\s\S]+/,alias:"string"}}}]}),delete e.languages.ruby.string,e.languages.insertBefore("ruby","number",{builtin:/\b(?:Array|Bignum|Binding|Class|Continuation|Dir|Exception|FalseClass|File|Fixnum|Float|Hash|IO|Integer|MatchData|Method|Module|NilClass|Numeric|Object|Proc|Range|Regexp|Stat|String|Struct|Symbol|TMS|Thread|ThreadGroup|Time|TrueClass)\b/,constant:/\b[A-Z][A-Z0-9_]*(?:[?!]|\b)/}),e.languages.rb=e.languages.ruby}(Prism)),Prism.languages.swift={comment:{pattern:/(^|[^\\:])(?:\/\/.*|\/\*(?:[^/*]|\/(?!\*)|\*(?!\/)|\/\*(?:[^*]|\*(?!\/))*\*\/)*\*\/)/,lookbehind:!0,greedy:!0},"string-literal":[{pattern:RegExp(/(^|[^"#])/.source+"(?:"+/"(?:\\(?:\((?:[^()]|\([^()]*\))*\)|\r\n|[^(])|[^\\\r\n"])*"/.source+"|"+/"""(?:\\(?:\((?:[^()]|\([^()]*\))*\)|[^(])|[^\\"]|"(?!""))*"""/.source+")"+/(?!["#])/.source),lookbehind:!0,greedy:!0,inside:{interpolation:{pattern:/(\\\()(?:[^()]|\([^()]*\))*(?=\))/,lookbehind:!0,inside:null},"interpolation-punctuation":{pattern:/^\)|\\\($/,alias:"punctuation"},punctuation:/\\(?=[\r\n])/,string:/[\s\S]+/}},{pattern:RegExp(/(^|[^"#])(#+)/.source+"(?:"+/"(?:\\(?:#+\((?:[^()]|\([^()]*\))*\)|\r\n|[^#])|[^\\\r\n])*?"/.source+"|"+/"""(?:\\(?:#+\((?:[^()]|\([^()]*\))*\)|[^#])|[^\\])*?"""/.source+")\\2"),lookbehind:!0,greedy:!0,inside:{interpolation:{pattern:/(\\#+\()(?:[^()]|\([^()]*\))*(?=\))/,lookbehind:!0,inside:null},"interpolation-punctuation":{pattern:/^\)|\\#+\($/,alias:"punctuation"},string:/[\s\S]+/}}],directive:{pattern:RegExp(/#/.source+"(?:"+/(?:elseif|if)\b/.source+"(?:[ \t]*"+/(?:![ \t]*)?(?:\b\w+\b(?:[ \t]*\((?:[^()]|\([^()]*\))*\))?|\((?:[^()]|\([^()]*\))*\))(?:[ \t]*(?:&&|\|\|))?/.source+")+|"+/(?:else|endif)\b/.source+")"),alias:"property",inside:{"directive-name":/^#\w+/,boolean:/\b(?:false|true)\b/,number:/\b\d+(?:\.\d+)*\b/,operator:/!|&&|\|\||[<>]=?/,punctuation:/[(),]/}},literal:{pattern:/#(?:colorLiteral|column|dsohandle|file(?:ID|Literal|Path)?|function|imageLiteral|line)\b/,alias:"constant"},"other-directive":{pattern:/#\w+\b/,alias:"property"},attribute:{pattern:/@\w+/,alias:"atrule"},"function-definition":{pattern:/(\bfunc\s+)\w+/,lookbehind:!0,alias:"function"},label:{pattern:/\b(break|continue)\s+\w+|\b[a-zA-Z_]\w*(?=\s*:\s*(?:for|repeat|while)\b)/,lookbehind:!0,alias:"important"},keyword:/\b(?:Any|Protocol|Self|Type|actor|as|assignment|associatedtype|associativity|async|await|break|case|catch|class|continue|convenience|default|defer|deinit|didSet|do|dynamic|else|enum|extension|fallthrough|fileprivate|final|for|func|get|guard|higherThan|if|import|in|indirect|infix|init|inout|internal|is|isolated|lazy|left|let|lowerThan|mutating|none|nonisolated|nonmutating|open|operator|optional|override|postfix|precedencegroup|prefix|private|protocol|public|repeat|required|rethrows|return|right|safe|self|set|some|static|struct|subscript|super|switch|throw|throws|try|typealias|unowned|unsafe|var|weak|where|while|willSet)\b/,boolean:/\b(?:false|true)\b/,nil:{pattern:/\bnil\b/,alias:"constant"},"short-argument":/\$\d+\b/,omit:{pattern:/\b_\b/,alias:"keyword"},number:/\b(?:[\d_]+(?:\.[\de_]+)?|0x[a-f0-9_]+(?:\.[a-f0-9p_]+)?|0b[01_]+|0o[0-7_]+)\b/i,"class-name":/\b[A-Z](?:[A-Z_\d]*[a-z]\w*)?\b/,function:/\b[a-z_]\w*(?=\s*\()/i,constant:/\b(?:[A-Z_]{2,}|k[A-Z][A-Za-z_]+)\b/,operator:/[-+*/%=!<>&|^~?]+|\.[.\-+*/%=!<>&|^~?]+/,punctuation:/[{}[\]();,.:\\]/},Prism.languages.swift["string-literal"].forEach(function(e){e.inside.interpolation.inside=Prism.languages.swift}),function(e){var t="\\b(?:BASH|BASHOPTS|BASH_ALIASES|BASH_ARGC|BASH_ARGV|BASH_CMDS|BASH_COMPLETION_COMPAT_DIR|BASH_LINENO|BASH_REMATCH|BASH_SOURCE|BASH_VERSINFO|BASH_VERSION|COLORTERM|COLUMNS|COMP_WORDBREAKS|DBUS_SESSION_BUS_ADDRESS|DEFAULTS_PATH|DESKTOP_SESSION|DIRSTACK|DISPLAY|EUID|GDMSESSION|GDM_LANG|GNOME_KEYRING_CONTROL|GNOME_KEYRING_PID|GPG_AGENT_INFO|GROUPS|HISTCONTROL|HISTFILE|HISTFILESIZE|HISTSIZE|HOME|HOSTNAME|HOSTTYPE|IFS|INSTANCE|JOB|LANG|LANGUAGE|LC_ADDRESS|LC_ALL|LC_IDENTIFICATION|LC_MEASUREMENT|LC_MONETARY|LC_NAME|LC_NUMERIC|LC_PAPER|LC_TELEPHONE|LC_TIME|LESSCLOSE|LESSOPEN|LINES|LOGNAME|LS_COLORS|MACHTYPE|MAILCHECK|MANDATORY_PATH|NO_AT_BRIDGE|OLDPWD|OPTERR|OPTIND|ORBIT_SOCKETDIR|OSTYPE|PAPERSIZE|PATH|PIPESTATUS|PPID|PS1|PS2|PS3|PS4|PWD|RANDOM|REPLY|SECONDS|SELINUX_INIT|SESSION|SESSIONTYPE|SESSION_MANAGER|SHELL|SHELLOPTS|SHLVL|SSH_AUTH_SOCK|TERM|UID|UPSTART_EVENTS|UPSTART_INSTANCE|UPSTART_JOB|UPSTART_SESSION|USER|WINDOWID|XAUTHORITY|XDG_CONFIG_DIRS|XDG_CURRENT_DESKTOP|XDG_DATA_DIRS|XDG_GREETER_DATA_DIR|XDG_MENU_PREFIX|XDG_RUNTIME_DIR|XDG_SEAT|XDG_SEAT_PATH|XDG_SESSION_DESKTOP|XDG_SESSION_ID|XDG_SESSION_PATH|XDG_SESSION_TYPE|XDG_VTNR|XMODIFIERS)\\b",r={pattern:/(^(["']?)\w+\2)[ \t]+\S.*/,lookbehind:!0,alias:"punctuation",inside:null},n={bash:r,environment:{pattern:RegExp("\\$"+t),alias:"constant"},variable:[{pattern:/\$?\(\([\s\S]+?\)\)/,greedy:!0,inside:{variable:[{pattern:/(^\$\(\([\s\S]+)\)\)/,lookbehind:!0},/^\$\(\(/],number:/\b0x[\dA-Fa-f]+\b|(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:[Ee]-?\d+)?/,operator:/--|\+\+|\*\*=?|<<=?|>>=?|&&|\|\||[=!+\-*/%<>^&|]=?|[?~:]/,punctuation:/\(\(?|\)\)?|,|;/}},{pattern:/\$\((?:\([^)]+\)|[^()])+\)|`[^`]+`/,greedy:!0,inside:{variable:/^\$\(|^`|\)$|`$/}},{pattern:/\$\{[^}]+\}/,greedy:!0,inside:{operator:/:[-=?+]?|[!\/]|##?|%%?|\^\^?|,,?/,punctuation:/[\[\]]/,environment:{pattern:RegExp("(\\{)"+t),lookbehind:!0,alias:"constant"}}},/\$(?:\w+|[#?*!@$])/],entity:/\\(?:[abceEfnrtv\\"]|O?[0-7]{1,3}|U[0-9a-fA-F]{8}|u[0-9a-fA-F]{4}|x[0-9a-fA-F]{1,2})/};e.languages.bash={shebang:{pattern:/^#!\s*\/.*/,alias:"important"},comment:{pattern:/(^|[^"{\\$])#.*/,lookbehind:!0},"function-name":[{pattern:/(\bfunction\s+)[\w-]+(?=(?:\s*\(?:\s*\))?\s*\{)/,lookbehind:!0,alias:"function"},{pattern:/\b[\w-]+(?=\s*\(\s*\)\s*\{)/,alias:"function"}],"for-or-select":{pattern:/(\b(?:for|select)\s+)\w+(?=\s+in\s)/,alias:"variable",lookbehind:!0},"assign-left":{pattern:/(^|[\s;|&]|[<>]\()\w+(?:\.\w+)*(?=\+?=)/,inside:{environment:{pattern:RegExp("(^|[\\s;|&]|[<>]\\()"+t),lookbehind:!0,alias:"constant"}},alias:"variable",lookbehind:!0},parameter:{pattern:/(^|\s)-{1,2}(?:\w+:[+-]?)?\w+(?:\.\w+)*(?=[=\s]|$)/,alias:"variable",lookbehind:!0},string:[{pattern:/((?:^|[^<])<<-?\s*)(\w+)\s[\s\S]*?(?:\r?\n|\r)\2/,lookbehind:!0,greedy:!0,inside:n},{pattern:/((?:^|[^<])<<-?\s*)(["'])(\w+)\2\s[\s\S]*?(?:\r?\n|\r)\3/,lookbehind:!0,greedy:!0,inside:{bash:r}},{pattern:/(^|[^\\](?:\\\\)*)"(?:\\[\s\S]|\$\([^)]+\)|\$(?!\()|`[^`]+`|[^"\\`$])*"/,lookbehind:!0,greedy:!0,inside:n},{pattern:/(^|[^$\\])'[^']*'/,lookbehind:!0,greedy:!0},{pattern:/\$'(?:[^'\\]|\\[\s\S])*'/,greedy:!0,inside:{entity:n.entity}}],environment:{pattern:RegExp("\\$?"+t),alias:"constant"},variable:n.variable,function:{pattern:/(^|[\s;|&]|[<>]\()(?:add|apropos|apt|apt-cache|apt-get|aptitude|aspell|automysqlbackup|awk|basename|bash|bc|bconsole|bg|bzip2|cal|cargo|cat|cfdisk|chgrp|chkconfig|chmod|chown|chroot|cksum|clear|cmp|column|comm|composer|cp|cron|crontab|csplit|curl|cut|date|dc|dd|ddrescue|debootstrap|df|diff|diff3|dig|dir|dircolors|dirname|dirs|dmesg|docker|docker-compose|du|egrep|eject|env|ethtool|expand|expect|expr|fdformat|fdisk|fg|fgrep|file|find|fmt|fold|format|free|fsck|ftp|fuser|gawk|git|gparted|grep|groupadd|groupdel|groupmod|groups|grub-mkconfig|gzip|halt|head|hg|history|host|hostname|htop|iconv|id|ifconfig|ifdown|ifup|import|install|ip|java|jobs|join|kill|killall|less|link|ln|locate|logname|logrotate|look|lpc|lpr|lprint|lprintd|lprintq|lprm|ls|lsof|lynx|make|man|mc|mdadm|mkconfig|mkdir|mke2fs|mkfifo|mkfs|mkisofs|mknod|mkswap|mmv|more|most|mount|mtools|mtr|mutt|mv|nano|nc|netstat|nice|nl|node|nohup|notify-send|npm|nslookup|op|open|parted|passwd|paste|pathchk|ping|pkill|pnpm|podman|podman-compose|popd|pr|printcap|printenv|ps|pushd|pv|quota|quotacheck|quotactl|ram|rar|rcp|reboot|remsync|rename|renice|rev|rm|rmdir|rpm|rsync|scp|screen|sdiff|sed|sendmail|seq|service|sftp|sh|shellcheck|shuf|shutdown|sleep|slocate|sort|split|ssh|stat|strace|su|sudo|sum|suspend|swapon|sync|sysctl|tac|tail|tar|tee|time|timeout|top|touch|tr|traceroute|tsort|tty|umount|uname|unexpand|uniq|units|unrar|unshar|unzip|update-grub|uptime|useradd|userdel|usermod|users|uudecode|uuencode|v|vcpkg|vdir|vi|vim|virsh|vmstat|wait|watch|wc|wget|whereis|which|who|whoami|write|xargs|xdg-open|yarn|yes|zenity|zip|zsh|zypper)(?=$|[)\s;|&])/,lookbehind:!0},keyword:{pattern:/(^|[\s;|&]|[<>]\()(?:case|do|done|elif|else|esac|fi|for|function|if|in|select|then|until|while)(?=$|[)\s;|&])/,lookbehind:!0},builtin:{pattern:/(^|[\s;|&]|[<>]\()(?:\.|:|alias|bind|break|builtin|caller|cd|command|continue|declare|echo|enable|eval|exec|exit|export|getopts|hash|help|let|local|logout|mapfile|printf|pwd|read|readarray|readonly|return|set|shift|shopt|source|test|times|trap|type|typeset|ulimit|umask|unalias|unset)(?=$|[)\s;|&])/,lookbehind:!0,alias:"class-name"},boolean:{pattern:/(^|[\s;|&]|[<>]\()(?:false|true)(?=$|[)\s;|&])/,lookbehind:!0},"file-descriptor":{pattern:/\B&\d\b/,alias:"important"},operator:{pattern:/\d?<>|>\||\+=|=[=~]?|!=?|<<[<-]?|[&\d]?>>|\d[<>]&?|[<>][&=]?|&[>&]?|\|[&|]?/,inside:{"file-descriptor":{pattern:/^\d/,alias:"important"}}},punctuation:/\$?\(\(?|\)\)?|\.\.|[{}[\];\\]/,number:{pattern:/(^|\s)(?:[1-9]\d*|0)(?:[.,]\d+)?\b/,lookbehind:!0}},r.inside=e.languages.bash;for(var o=["comment","function-name","for-or-select","assign-left","parameter","string","environment","function","keyword","builtin","boolean","file-descriptor","operator","punctuation","number"],i=n.variable[1].inside,a=0;a<o.length;a++)i[o[a]]=e.languages.bash[o[a]];e.languages.sh=e.languages.bash,e.languages.shell=e.languages.bash}(Prism),function(e){var t=/(?:\\.|[^\\\n\r]|(?:\n|\r\n?)(?![\r\n]))/.source;function r(e){return e=e.replace(/<inner>/g,function(){return t}),RegExp(/((?:^|[^\\])(?:\\{2})*)/.source+"(?:"+e+")")}var n=/(?:\\.|``(?:[^`\r\n]|`(?!`))+``|`[^`\r\n]+`|[^\\|\r\n`])+/.source,o=/\|?__(?:\|__)+\|?(?:(?:\n|\r\n?)|(?![\s\S]))/.source.replace(/__/g,function(){return n}),i=/\|?[ \t]*:?-{3,}:?[ \t]*(?:\|[ \t]*:?-{3,}:?[ \t]*)+\|?(?:\n|\r\n?)/.source;e.languages.markdown=e.languages.extend("markup",{}),e.languages.insertBefore("markdown","prolog",{"front-matter-block":{pattern:/(^(?:\s*[\r\n])?)---(?!.)[\s\S]*?[\r\n]---(?!.)/,lookbehind:!0,greedy:!0,inside:{punctuation:/^---|---$/,"front-matter":{pattern:/\S+(?:\s+\S+)*/,alias:["yaml","language-yaml"],inside:e.languages.yaml}}},blockquote:{pattern:/^>(?:[\t ]*>)*/m,alias:"punctuation"},table:{pattern:RegExp("^"+o+i+"(?:"+o+")*","m"),inside:{"table-data-rows":{pattern:RegExp("^("+o+i+")(?:"+o+")*$"),lookbehind:!0,inside:{"table-data":{pattern:RegExp(n),inside:e.languages.markdown},punctuation:/\|/}},"table-line":{pattern:RegExp("^("+o+")"+i+"$"),lookbehind:!0,inside:{punctuation:/\||:?-{3,}:?/}},"table-header-row":{pattern:RegExp("^"+o+"$"),inside:{"table-header":{pattern:RegExp(n),alias:"important",inside:e.languages.markdown},punctuation:/\|/}}}},code:[{pattern:/((?:^|\n)[ \t]*\n|(?:^|\r\n?)[ \t]*\r\n?)(?: {4}|\t).+(?:(?:\n|\r\n?)(?: {4}|\t).+)*/,lookbehind:!0,alias:"keyword"},{pattern:/^```[\s\S]*?^```$/m,greedy:!0,inside:{"code-block":{pattern:/^(```.*(?:\n|\r\n?))[\s\S]+?(?=(?:\n|\r\n?)^```$)/m,lookbehind:!0},"code-language":{pattern:/^(```).+/,lookbehind:!0},punctuation:/```/}}],title:[{pattern:/\S.*(?:\n|\r\n?)(?:==+|--+)(?=[ \t]*$)/m,alias:"important",inside:{punctuation:/==+$|--+$/}},{pattern:/(^\s*)#.+/m,lookbehind:!0,alias:"important",inside:{punctuation:/^#+|#+$/}}],hr:{pattern:/(^\s*)([*-])(?:[\t ]*\2){2,}(?=\s*$)/m,lookbehind:!0,alias:"punctuation"},list:{pattern:/(^\s*)(?:[*+-]|\d+\.)(?=[\t ].)/m,lookbehind:!0,alias:"punctuation"},"url-reference":{pattern:/!?\[[^\]]+\]:[\t ]+(?:\S+|<(?:\\.|[^>\\])+>)(?:[\t ]+(?:"(?:\\.|[^"\\])*"|'(?:\\.|[^'\\])*'|\((?:\\.|[^)\\])*\)))?/,inside:{variable:{pattern:/^(!?\[)[^\]]+/,lookbehind:!0},string:/(?:"(?:\\.|[^"\\])*"|'(?:\\.|[^'\\])*'|\((?:\\.|[^)\\])*\))$/,punctuation:/^[\[\]!:]|[<>]/},alias:"url"},bold:{pattern:r(/\b__(?:(?!_)<inner>|_(?:(?!_)<inner>)+_)+__\b|\*\*(?:(?!\*)<inner>|\*(?:(?!\*)<inner>)+\*)+\*\*/.source),lookbehind:!0,greedy:!0,inside:{content:{pattern:/(^..)[\s\S]+(?=..$)/,lookbehind:!0,inside:{}},punctuation:/\*\*|__/}},italic:{pattern:r(/\b_(?:(?!_)<inner>|__(?:(?!_)<inner>)+__)+_\b|\*(?:(?!\*)<inner>|\*\*(?:(?!\*)<inner>)+\*\*)+\*/.source),lookbehind:!0,greedy:!0,inside:{content:{pattern:/(^.)[\s\S]+(?=.$)/,lookbehind:!0,inside:{}},punctuation:/[*_]/}},strike:{pattern:r(/(~~?)(?:(?!~)<inner>)+\2/.source),lookbehind:!0,greedy:!0,inside:{content:{pattern:/(^~~?)[\s\S]+(?=\1$)/,lookbehind:!0,inside:{}},punctuation:/~~?/}},"code-snippet":{pattern:/(^|[^\\`])(?:``[^`\r\n]+(?:`[^`\r\n]+)*``(?!`)|`[^`\r\n]+`(?!`))/,lookbehind:!0,greedy:!0,alias:["code","keyword"]},url:{pattern:r(/!?\[(?:(?!\])<inner>)+\](?:\([^\s)]+(?:[\t ]+"(?:\\.|[^"\\])*")?\)|[ \t]?\[(?:(?!\])<inner>)+\])/.source),lookbehind:!0,greedy:!0,inside:{operator:/^!/,content:{pattern:/(^\[)[^\]]+(?=\])/,lookbehind:!0,inside:{}},variable:{pattern:/(^\][ \t]?\[)[^\]]+(?=\]$)/,lookbehind:!0},url:{pattern:/(^\]\()[^\s)]+/,lookbehind:!0},string:{pattern:/(^[ \t]+)"(?:\\.|[^"\\])*"(?=\)$)/,lookbehind:!0}}}}),["url","bold","italic","strike"].forEach(function(t){["url","bold","italic","strike","code-snippet"].forEach(function(r){t!==r&&(e.languages.markdown[t].inside.content.inside[r]=e.languages.markdown[r])})}),e.hooks.add("after-tokenize",function(e){"markdown"!==e.language&&"md"!==e.language||function e(t){if(t&&"string"!=typeof t)for(var r=0,n=t.length;r<n;r++){var o=t[r];if("code"===o.type){var i=o.content[1],a=o.content[3];if(i&&a&&"code-language"===i.type&&"code-block"===a.type&&"string"==typeof i.content){var s=i.content.replace(/\b#/g,"sharp").replace(/\b\+\+/g,"pp"),u="language-"+(s=(/[a-z][\w-]*/i.exec(s)||[""])[0].toLowerCase());a.alias?"string"==typeof a.alias?a.alias=[a.alias,u]:a.alias.push(u):a.alias=[u]}}else e(o.content)}}(e.tokens)}),e.hooks.add("wrap",function(t){if("code-block"===t.type){for(var r="",n=0,o=t.classes.length;n<o;n++){var i=t.classes[n],l=/language-(.+)/.exec(i);if(l){r=l[1];break}}var c=e.languages[r];if(c)t.content=e.highlight(function(e){var t=e.replace(a,"");return t=t.replace(/&(\w{1,8}|#x?[\da-f]{1,8});/gi,function(e,t){var r;if("#"===(t=t.toLowerCase())[0])return r="x"===t[1]?parseInt(t.slice(2),16):Number(t.slice(1)),u(r);var n=s[t];return n||e}),t}(t.content),c,r);else if(r&&"none"!==r&&e.plugins.autoloader){var d="md-"+(new Date).valueOf()+"-"+Math.floor(1e16*Math.random());t.attributes.id=d,e.plugins.autoloader.loadLanguages(r,function(){var t=document.getElementById(d);t&&(t.innerHTML=e.highlight(t.textContent,e.languages[r],r))})}}});var a=RegExp(e.languages.markup.tag.pattern.source,"gi"),s={amp:"&",lt:"<",gt:">",quot:'"'},u=String.fromCodePoint||String.fromCharCode;e.languages.md=e.languages.markdown}(Prism),Prism.languages.lua={comment:/^#!.+|--(?:\[(=*)\[[\s\S]*?\]\1\]|.*)/m,string:{pattern:/(["'])(?:(?!\1)[^\\\r\n]|\\z(?:\r\n|\s)|\\(?:\r\n|[^z]))*\1|\[(=*)\[[\s\S]*?\]\2\]/,greedy:!0},number:/\b0x[a-f\d]+(?:\.[a-f\d]*)?(?:p[+-]?\d+)?\b|\b\d+(?:\.\B|(?:\.\d*)?(?:e[+-]?\d+)?\b)|\B\.\d+(?:e[+-]?\d+)?\b/i,keyword:/\b(?:and|break|do|else|elseif|end|false|for|function|goto|if|in|local|nil|not|or|repeat|return|then|true|until|while)\b/,function:/(?!\d)\w+(?=\s*(?:[({]))/,operator:[/[-+*%^&|#]|\/\/?|<[<=]?|>[>=]?|[=~]=?/,{pattern:/(^|[^.])\.\.(?!\.)/,lookbehind:!0}],punctuation:/[\[\](){},;]|\.+|:+/},function(e){var t={pattern:/((?:^|[^\\$])(?:\\{2})*)\$(?:\w+|\{[^{}]*\})/,lookbehind:!0,inside:{"interpolation-punctuation":{pattern:/^\$\{?|\}$/,alias:"punctuation"},expression:{pattern:/[\s\S]+/,inside:null}}};e.languages.groovy=e.languages.extend("clike",{string:{pattern:/'''(?:[^\\]|\\[\s\S])*?'''|'(?:\\.|[^\\'\r\n])*'/,greedy:!0},keyword:/\b(?:abstract|as|assert|boolean|break|byte|case|catch|char|class|const|continue|def|default|do|double|else|enum|extends|final|finally|float|for|goto|if|implements|import|in|instanceof|int|interface|long|native|new|package|private|protected|public|return|short|static|strictfp|super|switch|synchronized|this|throw|throws|trait|transient|try|void|volatile|while)\b/,number:/\b(?:0b[01_]+|0x[\da-f_]+(?:\.[\da-f_p\-]+)?|[\d_]+(?:\.[\d_]+)?(?:e[+-]?\d+)?)[glidf]?\b/i,operator:{pattern:/(^|[^.])(?:~|==?~?|\?[.:]?|\*(?:[.=]|\*=?)?|\.[@&]|\.\.<|\.\.(?!\.)|-[-=>]?|\+[+=]?|!=?|<(?:<=?|=>?)?|>(?:>>?=?|=)?|&[&=]?|\|[|=]?|\/=?|\^=?|%=?)/,lookbehind:!0},punctuation:/\.+|[{}[\];(),:$]/}),e.languages.insertBefore("groovy","string",{shebang:{pattern:/#!.+/,alias:"comment",greedy:!0},"interpolation-string":{pattern:/"""(?:[^\\]|\\[\s\S])*?"""|(["/])(?:\\.|(?!\1)[^\\\r\n])*\1|\$\/(?:[^/$]|\$(?:[/$]|(?![/$]))|\/(?!\$))*\/\$/,greedy:!0,inside:{interpolation:t,string:/[\s\S]+/}}}),e.languages.insertBefore("groovy","punctuation",{"spock-block":/\b(?:and|cleanup|expect|given|setup|then|when|where):/}),e.languages.insertBefore("groovy","function",{annotation:{pattern:/(^|[^.])@\w+/,lookbehind:!0,alias:"punctuation"}}),t.inside.expression.inside=e.languages.groovy}(Prism),Prism.languages.abap={comment:/^\*.*/m,string:/(`|')(?:\\.|(?!\1)[^\\\r\n])*\1/,"string-template":{pattern:/([|}])(?:\\.|[^\\|{\r\n])*(?=[|{])/,lookbehind:!0,alias:"string"},"eol-comment":{pattern:/(^|\s)".*/m,lookbehind:!0,alias:"comment"},keyword:{pattern:/(\s|\.|^)(?:\*-INPUT|\?TO|ABAP-SOURCE|ABBREVIATED|ABS|ABSTRACT|ACCEPT|ACCEPTING|ACCESSPOLICY|ACCORDING|ACOS|ACTIVATION|ACTUAL|ADD|ADD-CORRESPONDING|ADJACENT|AFTER|ALIAS|ALIASES|ALIGN|ALL|ALLOCATE|ALPHA|ANALYSIS|ANALYZER|AND|ANY|APPEND|APPENDAGE|APPENDING|APPLICATION|ARCHIVE|AREA|ARITHMETIC|AS|ASCENDING|ASIN|ASPECT|ASSERT|ASSIGN|ASSIGNED|ASSIGNING|ASSOCIATION|ASYNCHRONOUS|AT|ATAN|ATTRIBUTES|AUTHORITY|AUTHORITY-CHECK|AVG|BACK|BACKGROUND|BACKUP|BACKWARD|BADI|BASE|BEFORE|BEGIN|BETWEEN|BIG|BINARY|BINDING|BIT|BIT-AND|BIT-NOT|BIT-OR|BIT-XOR|BLACK|BLANK|BLANKS|BLOB|BLOCK|BLOCKS|BLUE|BOUND|BOUNDARIES|BOUNDS|BOXED|BREAK-POINT|BT|BUFFER|BY|BYPASSING|BYTE|BYTE-CA|BYTE-CN|BYTE-CO|BYTE-CS|BYTE-NA|BYTE-NS|BYTE-ORDER|C|CA|CALL|CALLING|CASE|CAST|CASTING|CATCH|CEIL|CENTER|CENTERED|CHAIN|CHAIN-INPUT|CHAIN-REQUEST|CHANGE|CHANGING|CHANNELS|CHAR-TO-HEX|CHARACTER|CHARLEN|CHECK|CHECKBOX|CIRCULAR|CI_|CLASS|CLASS-CODING|CLASS-DATA|CLASS-EVENTS|CLASS-METHODS|CLASS-POOL|CLEANUP|CLEAR|CLIENT|CLOB|CLOCK|CLOSE|CN|CNT|CO|COALESCE|CODE|CODING|COLLECT|COLOR|COLUMN|COLUMNS|COL_BACKGROUND|COL_GROUP|COL_HEADING|COL_KEY|COL_NEGATIVE|COL_NORMAL|COL_POSITIVE|COL_TOTAL|COMMENT|COMMENTS|COMMIT|COMMON|COMMUNICATION|COMPARING|COMPONENT|COMPONENTS|COMPRESSION|COMPUTE|CONCAT|CONCATENATE|COND|CONDENSE|CONDITION|CONNECT|CONNECTION|CONSTANTS|CONTEXT|CONTEXTS|CONTINUE|CONTROL|CONTROLS|CONV|CONVERSION|CONVERT|COPIES|COPY|CORRESPONDING|COS|COSH|COUNT|COUNTRY|COVER|CP|CPI|CREATE|CREATING|CRITICAL|CS|CURRENCY|CURRENCY_CONVERSION|CURRENT|CURSOR|CURSOR-SELECTION|CUSTOMER|CUSTOMER-FUNCTION|DANGEROUS|DATA|DATABASE|DATAINFO|DATASET|DATE|DAYLIGHT|DBMAXLEN|DD\/MM\/YY|DD\/MM\/YYYY|DDMMYY|DEALLOCATE|DECIMALS|DECIMAL_SHIFT|DECLARATIONS|DEEP|DEFAULT|DEFERRED|DEFINE|DEFINING|DEFINITION|DELETE|DELETING|DEMAND|DEPARTMENT|DESCENDING|DESCRIBE|DESTINATION|DETAIL|DIALOG|DIRECTORY|DISCONNECT|DISPLAY|DISPLAY-MODE|DISTANCE|DISTINCT|DIV|DIVIDE|DIVIDE-CORRESPONDING|DIVISION|DO|DUMMY|DUPLICATE|DUPLICATES|DURATION|DURING|DYNAMIC|DYNPRO|E|EACH|EDIT|EDITOR-CALL|ELSE|ELSEIF|EMPTY|ENABLED|ENABLING|ENCODING|END|END-ENHANCEMENT-SECTION|END-LINES|END-OF-DEFINITION|END-OF-FILE|END-OF-PAGE|END-OF-SELECTION|ENDAT|ENDCASE|ENDCATCH|ENDCHAIN|ENDCLASS|ENDDO|ENDENHANCEMENT|ENDEXEC|ENDFOR|ENDFORM|ENDFUNCTION|ENDIAN|ENDIF|ENDING|ENDINTERFACE|ENDLOOP|ENDMETHOD|ENDMODULE|ENDON|ENDPROVIDE|ENDSELECT|ENDTRY|ENDWHILE|ENGINEERING|ENHANCEMENT|ENHANCEMENT-POINT|ENHANCEMENT-SECTION|ENHANCEMENTS|ENTRIES|ENTRY|ENVIRONMENT|EQ|EQUAL|EQUIV|ERRORMESSAGE|ERRORS|ESCAPE|ESCAPING|EVENT|EVENTS|EXACT|EXCEPT|EXCEPTION|EXCEPTION-TABLE|EXCEPTIONS|EXCLUDE|EXCLUDING|EXEC|EXECUTE|EXISTS|EXIT|EXIT-COMMAND|EXP|EXPAND|EXPANDING|EXPIRATION|EXPLICIT|EXPONENT|EXPORT|EXPORTING|EXTEND|EXTENDED|EXTENSION|EXTRACT|FAIL|FETCH|FIELD|FIELD-GROUPS|FIELD-SYMBOL|FIELD-SYMBOLS|FIELDS|FILE|FILTER|FILTER-TABLE|FILTERS|FINAL|FIND|FIRST|FIRST-LINE|FIXED-POINT|FKEQ|FKGE|FLOOR|FLUSH|FONT|FOR|FORM|FORMAT|FORWARD|FOUND|FRAC|FRAME|FRAMES|FREE|FRIENDS|FROM|FUNCTION|FUNCTION-POOL|FUNCTIONALITY|FURTHER|GAPS|GE|GENERATE|GET|GIVING|GKEQ|GKGE|GLOBAL|GRANT|GREATER|GREEN|GROUP|GROUPS|GT|HANDLE|HANDLER|HARMLESS|HASHED|HAVING|HDB|HEAD-LINES|HEADER|HEADERS|HEADING|HELP-ID|HELP-REQUEST|HIDE|HIGH|HINT|HOLD|HOTSPOT|I|ICON|ID|IDENTIFICATION|IDENTIFIER|IDS|IF|IGNORE|IGNORING|IMMEDIATELY|IMPLEMENTATION|IMPLEMENTATIONS|IMPLEMENTED|IMPLICIT|IMPORT|IMPORTING|IN|INACTIVE|INCL|INCLUDE|INCLUDES|INCLUDING|INCREMENT|INDEX|INDEX-LINE|INFOTYPES|INHERITING|INIT|INITIAL|INITIALIZATION|INNER|INOUT|INPUT|INSERT|INSTANCES|INTENSIFIED|INTERFACE|INTERFACE-POOL|INTERFACES|INTERNAL|INTERVALS|INTO|INVERSE|INVERTED-DATE|IS|ISO|ITERATOR|ITNO|JOB|JOIN|KEEP|KEEPING|KERNEL|KEY|KEYS|KEYWORDS|KIND|LANGUAGE|LAST|LATE|LAYOUT|LE|LEADING|LEAVE|LEFT|LEFT-JUSTIFIED|LEFTPLUS|LEFTSPACE|LEGACY|LENGTH|LESS|LET|LEVEL|LEVELS|LIKE|LINE|LINE-COUNT|LINE-SELECTION|LINE-SIZE|LINEFEED|LINES|LIST|LIST-PROCESSING|LISTBOX|LITTLE|LLANG|LOAD|LOAD-OF-PROGRAM|LOB|LOCAL|LOCALE|LOCATOR|LOG|LOG-POINT|LOG10|LOGFILE|LOGICAL|LONG|LOOP|LOW|LOWER|LPAD|LPI|LT|M|MAIL|MAIN|MAJOR-ID|MAPPING|MARGIN|MARK|MASK|MATCH|MATCHCODE|MAX|MAXIMUM|MEDIUM|MEMBERS|MEMORY|MESH|MESSAGE|MESSAGE-ID|MESSAGES|MESSAGING|METHOD|METHODS|MIN|MINIMUM|MINOR-ID|MM\/DD\/YY|MM\/DD\/YYYY|MMDDYY|MOD|MODE|MODIF|MODIFIER|MODIFY|MODULE|MOVE|MOVE-CORRESPONDING|MULTIPLY|MULTIPLY-CORRESPONDING|NA|NAME|NAMETAB|NATIVE|NB|NE|NESTED|NESTING|NEW|NEW-LINE|NEW-PAGE|NEW-SECTION|NEXT|NO|NO-DISPLAY|NO-EXTENSION|NO-GAP|NO-GAPS|NO-GROUPING|NO-HEADING|NO-SCROLLING|NO-SIGN|NO-TITLE|NO-TOPOFPAGE|NO-ZERO|NODE|NODES|NON-UNICODE|NON-UNIQUE|NOT|NP|NS|NULL|NUMBER|NUMOFCHAR|O|OBJECT|OBJECTS|OBLIGATORY|OCCURRENCE|OCCURRENCES|OCCURS|OF|OFF|OFFSET|OLE|ON|ONLY|OPEN|OPTION|OPTIONAL|OPTIONS|OR|ORDER|OTHER|OTHERS|OUT|OUTER|OUTPUT|OUTPUT-LENGTH|OVERFLOW|OVERLAY|PACK|PACKAGE|PAD|PADDING|PAGE|PAGES|PARAMETER|PARAMETER-TABLE|PARAMETERS|PART|PARTIALLY|PATTERN|PERCENTAGE|PERFORM|PERFORMING|PERSON|PF|PF-STATUS|PINK|PLACES|POOL|POSITION|POS_HIGH|POS_LOW|PRAGMAS|PRECOMPILED|PREFERRED|PRESERVING|PRIMARY|PRINT|PRINT-CONTROL|PRIORITY|PRIVATE|PROCEDURE|PROCESS|PROGRAM|PROPERTY|PROTECTED|PROVIDE|PUBLIC|PUSHBUTTON|PUT|QUEUE-ONLY|QUICKINFO|RADIOBUTTON|RAISE|RAISING|RANGE|RANGES|RAW|READ|READ-ONLY|READER|RECEIVE|RECEIVED|RECEIVER|RECEIVING|RED|REDEFINITION|REDUCE|REDUCED|REF|REFERENCE|REFRESH|REGEX|REJECT|REMOTE|RENAMING|REPLACE|REPLACEMENT|REPLACING|REPORT|REQUEST|REQUESTED|RESERVE|RESET|RESOLUTION|RESPECTING|RESPONSIBLE|RESULT|RESULTS|RESUMABLE|RESUME|RETRY|RETURN|RETURNCODE|RETURNING|RIGHT|RIGHT-JUSTIFIED|RIGHTPLUS|RIGHTSPACE|RISK|RMC_COMMUNICATION_FAILURE|RMC_INVALID_STATUS|RMC_SYSTEM_FAILURE|ROLE|ROLLBACK|ROUND|ROWS|RTTI|RUN|SAP|SAP-SPOOL|SAVING|SCALE_PRESERVING|SCALE_PRESERVING_SCIENTIFIC|SCAN|SCIENTIFIC|SCIENTIFIC_WITH_LEADING_ZERO|SCREEN|SCROLL|SCROLL-BOUNDARY|SCROLLING|SEARCH|SECONDARY|SECONDS|SECTION|SELECT|SELECT-OPTIONS|SELECTION|SELECTION-SCREEN|SELECTION-SET|SELECTION-SETS|SELECTION-TABLE|SELECTIONS|SELECTOR|SEND|SEPARATE|SEPARATED|SET|SHARED|SHIFT|SHORT|SHORTDUMP-ID|SIGN|SIGN_AS_POSTFIX|SIMPLE|SIN|SINGLE|SINH|SIZE|SKIP|SKIPPING|SMART|SOME|SORT|SORTABLE|SORTED|SOURCE|SPACE|SPECIFIED|SPLIT|SPOOL|SPOTS|SQL|SQLSCRIPT|SQRT|STABLE|STAMP|STANDARD|START-OF-SELECTION|STARTING|STATE|STATEMENT|STATEMENTS|STATIC|STATICS|STATUSINFO|STEP-LOOP|STOP|STRLEN|STRUCTURE|STRUCTURES|STYLE|SUBKEY|SUBMATCHES|SUBMIT|SUBROUTINE|SUBSCREEN|SUBSTRING|SUBTRACT|SUBTRACT-CORRESPONDING|SUFFIX|SUM|SUMMARY|SUMMING|SUPPLIED|SUPPLY|SUPPRESS|SWITCH|SWITCHSTATES|SYMBOL|SYNCPOINTS|SYNTAX|SYNTAX-CHECK|SYNTAX-TRACE|SYSTEM-CALL|SYSTEM-EXCEPTIONS|SYSTEM-EXIT|TAB|TABBED|TABLE|TABLES|TABLEVIEW|TABSTRIP|TAN|TANH|TARGET|TASK|TASKS|TEST|TESTING|TEXT|TEXTPOOL|THEN|THROW|TIME|TIMES|TIMESTAMP|TIMEZONE|TITLE|TITLE-LINES|TITLEBAR|TO|TOKENIZATION|TOKENS|TOP-LINES|TOP-OF-PAGE|TRACE-FILE|TRACE-TABLE|TRAILING|TRANSACTION|TRANSFER|TRANSFORMATION|TRANSLATE|TRANSPORTING|TRMAC|TRUNC|TRUNCATE|TRUNCATION|TRY|TYPE|TYPE-POOL|TYPE-POOLS|TYPES|ULINE|UNASSIGN|UNDER|UNICODE|UNION|UNIQUE|UNIT|UNIT_CONVERSION|UNIX|UNPACK|UNTIL|UNWIND|UP|UPDATE|UPPER|USER|USER-COMMAND|USING|UTF-8|VALID|VALUE|VALUE-REQUEST|VALUES|VARY|VARYING|VERIFICATION-MESSAGE|VERSION|VIA|VIEW|VISIBLE|WAIT|WARNING|WHEN|WHENEVER|WHERE|WHILE|WIDTH|WINDOW|WINDOWS|WITH|WITH-HEADING|WITH-TITLE|WITHOUT|WORD|WORK|WRITE|WRITER|X|XML|XOR|XSD|XSTRLEN|YELLOW|YES|YYMMDD|Z|ZERO|ZONE)(?![\w-])/i,lookbehind:!0},number:/\b\d+\b/,operator:{pattern:/(\s)(?:\*\*?|<[=>]?|>=?|\?=|[-+\/=])(?=\s)/,lookbehind:!0},"string-operator":{pattern:/(\s)&&?(?=\s)/,lookbehind:!0,alias:"keyword"},"token-operator":[{pattern:/(\w)(?:->?|=>|[~|{}])(?=\w)/,lookbehind:!0,alias:"punctuation"},{pattern:/[|{}]/,alias:"punctuation"}],punctuation:/[,.:()]/};var kk=["comment","prolog","doctype","cdata","punctuation","namespace","property","tag","boolean","number","constant","symbol","deleted","selector","attr-name","string","builtin","inserted","operator","entity","url","string","atrule","attr-value","keyword","function","class-name","regex","important","variable","bold","italic","entity","char"];function Ok(e){return"string"==typeof e?e.length:"string"==typeof e.content?e.content.length:e.content.reduce(function(e,t){return e+Ok(t)},0)}var Tk=function(e){var t,r,n,o=Qg(e,2),i=o[0],a=o[1],s=[],u=function(e){if(!Cg.isText(e))return null;var t=Ry.getParentNode(null,e);if(t&&"code"===Ry.getNodeType(t)){var r=Ry.getParentNode(null,t);if(r&&"pre"===Ry.getNodeType(r))return t}return null}(i);if(null==u)return s;var l=u.language,c=void 0===l?"":l;if(!c)return s;var d=function(e,t){if(!t)return[];var r=Ck.languages[t];return r?Ck.tokenize(e.text,r):[]}(i,c),h=0;try{for(var f=Jg(d),p=f.next();!p.done;p=f.next()){var g=p.value,m=h+Ok(g);"string"!=typeof g&&s.push(((n={})[g.type]=!0,n.anchor={path:a,offset:h},n.focus={path:a,offset:m},n)),h=m}}catch(e){t={error:e}}finally{try{p&&!p.done&&(r=f.return)&&r.call(f)}finally{if(t)throw t.error}}return s};var Nk={type:"code",elemToHtml:function(e,t){var r=e.language,n=void 0===r?"":r,o=n?'class="language-'.concat(n,'"'):"";return"<code ".concat(o,">").concat(t,"</code>")}};var Pk=function(){function e(){this.title=eC("highLightModule.selectLang"),this.iconSvg='<svg viewBox="0 0 1024 1024"><path d="M64 64v896h896V64H64z m487.6 698.8c0 87.2-51.2 127-125.8 127-67.4 0-106.4-34.8-126.4-77l68.6-41.4c13.2 23.4 25.2 43.2 54.2 43.2 27.6 0 45.2-10.8 45.2-53V475.4h84.2v287.4z m199.2 127c-78.2 0-128.8-37.2-153.4-86l68.6-39.6c18 29.4 41.6 51.2 83 51.2 34.8 0 57.2-17.4 57.2-41.6 0-28.8-22.8-39-61.4-56l-21-9c-60.8-25.8-101-58.4-101-127 0-63.2 48.2-111.2 123.2-111.2 53.6 0 92 18.6 119.6 67.4L800 580c-14.4-25.8-30-36-54.2-36-24.6 0-40.2 15.6-40.2 36 0 25.2 15.6 35.4 51.8 51.2l21 9c71.6 30.6 111.8 62 111.8 132.4 0 75.6-59.6 117.2-139.4 117.2z"></path></svg>',this.tag="select",this.width=95,this.selectPanelWidth=115,this.defaultCodeLang=""}return e.prototype.getOptions=function(e){var t=this,r=[],n=e.getMenuConfig("codeSelectLang").codeLangs,o=void 0===n?[]:n;r.push({text:"plain text",value:""}),o.forEach(function(e){var n=e.text,o=e.value;e.selected&&(t.defaultCodeLang=o),r.push({text:n,value:o})});var i=this.getValue(e);return r.forEach(function(e){e.value===i?e.selected=!0:e.selected=void 0}),r},e.prototype.isActive=function(e){return!1},e.prototype.getValue=function(e){var t=this.getSelectCodeElem(e);if(null==t)return this.defaultCodeLang;if(!Vp.isElement(t))return this.defaultCodeLang;var r=t.language.toString(),n=e.getMenuConfig("codeSelectLang").codeLangs;return(void 0===n?[]:n).some(function(e){return e.value===r})?r:this.defaultCodeLang},e.prototype.isDisabled=function(e){return null==e.selection||!this.getSelectCodeElem(e)},e.prototype.exec=function(e,t){if(null!=this.getSelectCodeElem(e)){var r={language:t.toString()};zg.setNodes(e,r,{match:function(e){return Ry.checkNodeType(e,"code")}})}},e.prototype.getSelectCodeElem=function(e){var t=Ry.getSelectedNodeByType(e,"code");if(null==t)return null;var r=Ry.getParentNode(e,t);return Vp.isElement(r)?"pre"!==r.type?null:t:null},e}(),Mk={key:"codeSelectLang",factory:function(){return new Pk},config:{codeLangs:[{text:"CSS",value:"css"},{text:"HTML",value:"html"},{text:"XML",value:"xml"},{text:"Javascript",value:"javascript"},{text:"Typescript",value:"typescript"},{text:"JSX",value:"jsx"},{text:"Go",value:"go"},{text:"PHP",value:"php"},{text:"C",value:"c"},{text:"Python",value:"python"},{text:"Java",value:"java"},{text:"C++",value:"cpp"},{text:"C#",value:"csharp"},{text:"Visual Basic",value:"visual-basic"},{text:"SQL",value:"sql"},{text:"Ruby",value:"ruby"},{text:"Swift",value:"swift"},{text:"Bash",value:"bash"},{text:"Lua",value:"lua"},{text:"Groovy",value:"groovy"},{text:"Markdown",value:"markdown"},{text:"ABAP",value:"abap"}]}};uv&&(ov.fn.attr=uv);var Ik={renderStyle:function(e,t){var r=e,n=t,o="";return kk.forEach(function(e){r[e]&&(o=e)}),o&&function(e,t){null==e.data&&(e.data={});var r=e.data;null==r.props&&(r.props={}),Object.assign(r.props,{className:t})}(n,o="token ".concat(o)),n},parseStyleHtml:function(e,t,r){var n=ov(e);if(!Vp.isElement(t))return t;if("code"!==Ry.getNodeType(t))return t;var o=t,i=n.attr("class")||"";return 0===i.indexOf("language-")?o.language=i.split("-")[1]||"":o.language=i.toLowerCase(),o},menus:[Mk],elemsToHtml:[Nk]};XD("en",{listModule:{unOrderedList:"Unordered list",orderedList:"Ordered list"}}),XD("zh-CN",{listModule:{unOrderedList:"无序列表",orderedList:"有序列表"}});var Rk=new WeakMap;function Lk(e){var t,r=e.children||[],n=r.length;if(0===n)return"";for(var o=0;o<n&&!t;o+=1){var i=r[o];Cg.isText(i)&&(t=i)}return null==t?"":t.color||""}function _k(e,t,r){for(var n=t.type,o=function(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(n=Object.getOwnPropertySymbols(e);o<n.length;o++)t.indexOf(n[o])<0&&Object.prototype.propertyIsEnumerable.call(e,n[o])&&(r[n[o]]=e[n[o]])}return r}(t,["type"]),i=void 0!==r?r:o.level||0,a=Ry.findPath(e,t),s=a;;){if(0===s.length||0===a[a.length-1])return null;s=og.previous(s);var u=Yp.node(e,s);if(!u)return null;var l=Qg(u,1)[0],c=l.level,d=void 0===c?0:c;if(Ry.getNodeType(l)!==n)return null;if(d===i)return l}}function zk(e,t,r){var n=_k(e,t,r);return!!n&&n.ordered===t.ordered}var jk=[];var Hk={type:"list-item",elemToHtml:function(e,t){var r="",n="",o=e.ordered,i=void 0!==o&&o?"ol":"ul",a=function(e){var t=Rk.get(e);if(null==t)return 0;var r=e,n=r.type,o=r.ordered,i=void 0!==o&&o,a=r.level,s=void 0===a?0:a,u=Ry.findPath(t,e);if(0===u[0])return s+1;var l=og.previous(u),c=Yp.node(t,l);if(!c)return 0;var d=Qg(c,1)[0];if(Ry.getNodeType(d)!==n)return s+1;var h=d,f=h.ordered,p=void 0!==f&&f,g=h.level,m=void 0===g?0:g;return m<s?s-m:m>s?zk(t,e)?0:1:m===s?p===i?0:1:0}(e);if(a>0)for(var s=0;s<a;s+=1)r+="<".concat(i,">"),jk.push(i);var u=function(e){var t=Rk.get(e);if(null==t)return 0;var r=e,n=r.type,o=r.ordered,i=void 0!==o&&o,a=r.level,s=void 0===a?0:a,u=Ry.findPath(t,e);if(u[0]===t.children.length-1)return s+1;var l=og.next(u),c=Yp.node(t,l);if(!c)return 0;var d=Qg(c,1)[0];if(Ry.getNodeType(d)!==n)return s+1;var h=d,f=h.ordered,p=void 0!==f&&f,g=h.level,m=void 0===g?0:g;return m<s?zk(t,d)?s-m:s-m+1:m>s?0:m===s?p===i?0:1:0}(e);if(u>0)for(s=0;s<u;s+=1){var l=jk.pop();n+="</".concat(l,">")}var c=Lk(e),d=c?' style="color:'.concat(c,'"'):"";return{html:"<li".concat(d,">").concat(t,"</li>"),prefix:r,suffix:n}}},Vk=function(){function e(){this.type="list-item",this.tag="button"}return e.prototype.getListNode=function(e){var t=this.type;return Ry.getSelectedNodeByType(e,t)},e.prototype.getValue=function(e){return""},e.prototype.isActive=function(e){var t=this.getListNode(e);if(null==t)return!1;var r=t.ordered;return(void 0!==r&&r)===this.ordered},e.prototype.isDisabled=function(e){return null==e.selection||!!Ry.getSelectedElems(e).some(function(t){if(Yp.isVoid(e,t)&&Yp.isBlock(e,t))return!0;var r=t.type;return!!["pre","code","table"].includes(r)})},e.prototype.exec=function(e,t){this.isActive(e)?zg.setNodes(e,{type:"paragraph",ordered:void 0,level:void 0}):zg.setNodes(e,{type:"list-item",ordered:this.ordered,indent:void 0})},e}(),$k=function(e){function t(){var t=e.apply(this,em([],Qg(arguments),!1))||this;return t.ordered=!1,t.title=eC("listModule.unOrderedList"),t.iconSvg='<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>',t}return Yg(t,e),t}(Vk),Uk=function(e){function t(){var t=e.apply(this,em([],Qg(arguments),!1))||this;return t.ordered=!0,t.title=eC("listModule.orderedList"),t.iconSvg='<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>',t}return Yg(t,e),t}(Vk),qk={key:"bulletedList",factory:function(){return new $k}},Wk={key:"numberedList",factory:function(){return new Uk}};function Gk(e){return e.length?e[0].tagName.toLowerCase():""}Bv&&(ov.fn.append=Bv),uv&&(ov.fn.attr=uv),Fv&&(ov.fn.parent=Fv);var Yk={selector:"li:not([data-w-e-type])",parseElemHtml:function(e,t,r){var n=ov(e);0===(t=t.filter(function(e){return!!Cg.isText(e)||!!r.isInline(e)})).length&&(t=[{text:n.text().replace(/\s+/gm," ")}]);var o=function(e){return"ol"===Gk(e.parent())}(n),i=function(e){for(var t=0,r=e.parent(),n=Gk(r);"ul"===n||"ol"===n;)n=Gk(r=r.parent()),t+=1;return t-1}(n);return{type:"list-item",ordered:o,level:i,children:t}}};var Kk={selector:"ul:not([data-w-e-type]),ol:not([data-w-e-type])",parseElemHtml:function(e,t,r){return t.flat(1/0)}};function Xk(e){return Yp.nodes(e,{at:e.selection||void 0,match:function(t){return 1===Ry.findPath(e,t).length}})}var Zk={type:"list-item",renderElem:function(e,t,r){Rk.set(e,r);var n=e,o=n.level,i=void 0===o?0:o,a=n.ordered,s=void 0!==a&&a,u={margin:"5px 0 5px ".concat(20*i,"px"),display:"flex",alignItems:"flex-start"},l="";if(s){var c=function(e,t){var r=t,n=r.type,o=r.level,i=void 0===o?0:o,a=r.ordered,s=void 0!==a&&a,u=1,l=t,c=Ry.findPath(e,l);if(0===c[0])return 1;for(;c[0]>0;){var d=og.previous(c),h=Yp.node(e,d);if(null==h)break;var f=h[0],p=f.level,g=void 0===p?0:p,m=f.type,v=f.ordered;if(m!==n)break;if(g<i)break;if(g===i){if(v!==s)break;u+=1}l=f,c=d}return u}(r,e);l="".concat(c,".")}else l=function(e){void 0===e&&(e=0);var t="";switch(e){case 0:t="•";break;case 1:t="◦";break;default:t="▪"}return t}(i);return Tw("div",{style:u},Tw("span",{contentEditable:!1,style:{marginRight:"0.5em",color:Lk(e)},"data-w-e-reserve":!0},l),Tw("span",{style:{flex:"1",wordBreak:"break-word"}},t))}},Jk={renderElems:[Zk],editorPlugin:function(e){var t=e.deleteBackward,r=e.handleTab,n=e.normalizeNode,o=e.insertBreak,i=e;return i.insertBreak=function(){var t=Qg(Yp.nodes(e,{match:function(e){return Ry.checkNodeType(e,"list-item")},universal:!0}),1),r=t[0];return r?""!==r[0].children[0].text?o():void zg.setNodes(i,{type:"paragraph",ordered:void 0,level:void 0}):o()},i.deleteBackward=function(r){var n=i.selection;if(null!=n)if(hg.isExpanded(n))t(r);else{var o=Ry.getSelectedNodeByType(i,"list-item");if(null!=o)if(0!==n.focus.offset)t(r);else{var a=o,s=a.level,u=void 0===s?0:s,l=a.ordered,c=void 0!==l&&l;if(u>0){var d=_k(e,o,u-1);d&&d.ordered!==c?zg.setNodes(i,{level:u-1,ordered:!c}):zg.setNodes(i,{level:u-1})}else zg.setNodes(i,{type:"paragraph",ordered:void 0,level:void 0})}else t(r)}else t(r)},i.handleTab=function(){var e,t,n,o,a=i.selection;if(null!=a){if(hg.isCollapsed(a)){var s=Ry.getSelectedNodeByType(i,"list-item");if(null==s)return void r();if(0===a.focus.offset){var u=s.level,l=void 0===u?0:u;return void zg.setNodes(i,{level:l+1})}}if(hg.isExpanded(a)){var c=0,d=!1;try{for(var h=Jg(Xk(i)),f=h.next();!f.done;f=h.next()){var p=Qg(f.value,1)[0];"list-item"===Ry.getNodeType(p)?c+=1:d=!0}}catch(t){e={error:t}}finally{try{f&&!f.done&&(t=h.return)&&t.call(h)}finally{if(e)throw e.error}}if(d||c<=1)return void r();try{for(var g=Jg(Xk(i)),m=g.next();!m.done;m=g.next()){var v=Qg(m.value,2),y=(p=v[0],v[1]),b=p.level;l=void 0===b?0:b;zg.setNodes(i,{level:l+1},{at:y})}}catch(e){n={error:e}}finally{try{m&&!m.done&&(o=g.return)&&o.call(g)}finally{if(n)throw n.error}}}else r()}else r()},i.normalizeNode=function(e){var t=Qg(e,2),r=t[0],o=t[1],a=Ry.getNodeType(r);return"bulleted-list"!==a&&"numbered-list"!==a||zg.unwrapNodes(i,{at:o}),n([r,o])},i},menus:[qk,Wk],elemsToHtml:[Hk],parseElemsHtml:[Kk,Yk]};!function(){if(void 0!==window.Reflect&&void 0!==window.customElements&&!window.customElements.polyfillWrapFlushCallback){var e=HTMLElement,t=function(){return Reflect.construct(e,[],this.constructor)};window.HTMLElement=t,HTMLElement.prototype=e.prototype,HTMLElement.prototype.constructor=HTMLElement,Object.setPrototypeOf(HTMLElement,e)}}();class Qk{constructor(e,t,r){this.lexer=void 0,this.start=void 0,this.end=void 0,this.lexer=e,this.start=t,this.end=r}static range(e,t){return t?e&&e.loc&&t.loc&&e.loc.lexer===t.loc.lexer?new Qk(e.loc.lexer,e.loc.start,t.loc.end):null:e&&e.loc}}class eO{constructor(e,t){this.text=void 0,this.loc=void 0,this.noexpand=void 0,this.treatAsRelax=void 0,this.text=e,this.loc=t}range(e,t){return new eO(t,Qk.range(this,e))}}class tO{constructor(e,t){this.name=void 0,this.position=void 0,this.length=void 0,this.rawMessage=void 0;var r,n,o="KaTeX parse error: "+e,i=t&&t.loc;if(i&&i.start<=i.end){var a=i.lexer.input;r=i.start,n=i.end,r===a.length?o+=" at end of input: ":o+=" at position "+(r+1)+": ";var s=a.slice(r,n).replace(/[^]/g,"$&̲");o+=(r>15?"…"+a.slice(r-15,r):a.slice(0,r))+s+(n+15<a.length?a.slice(n,n+15)+"…":a.slice(n))}var u=new Error(o);return u.name="ParseError",u.__proto__=tO.prototype,u.position=r,null!=r&&null!=n&&(u.length=n-r),u.rawMessage=e,u}}tO.prototype.__proto__=Error.prototype;var rO=/([A-Z])/g,nO={"&":"&",">":">","<":"<",'"':""","'":"'"},oO=/[&><"']/g;var iO=function e(t){return"ordgroup"===t.type||"color"===t.type?1===t.body.length?e(t.body[0]):t:"font"===t.type?e(t.body):t},aO={contains:function(e,t){return-1!==e.indexOf(t)},deflt:function(e,t){return void 0===e?t:e},escape:function(e){return String(e).replace(oO,e=>nO[e])},hyphenate:function(e){return e.replace(rO,"-$1").toLowerCase()},getBaseElem:iO,isCharacterBox:function(e){var t=iO(e);return"mathord"===t.type||"textord"===t.type||"atom"===t.type},protocolFromUrl:function(e){var t=/^[\x00-\x20]*([^\\/#?]*?)(:|�*58|�*3a|&colon)/i.exec(e);return t?":"!==t[2]?null:/^[a-zA-Z][a-zA-Z0-9+\-.]*$/.test(t[1])?t[1].toLowerCase():null:"_relative"}},sO={displayMode:{type:"boolean",description:"Render math in display mode, which puts the math in display style (so \\int and \\sum are large, for example), and centers the math on the page on its own line.",cli:"-d, --display-mode"},output:{type:{enum:["htmlAndMathml","html","mathml"]},description:"Determines the markup language of the output.",cli:"-F, --format <type>"},leqno:{type:"boolean",description:"Render display math in leqno style (left-justified tags)."},fleqn:{type:"boolean",description:"Render display math flush left."},throwOnError:{type:"boolean",default:!0,cli:"-t, --no-throw-on-error",cliDescription:"Render errors (in the color given by --error-color) instead of throwing a ParseError exception when encountering an error."},errorColor:{type:"string",default:"#cc0000",cli:"-c, --error-color <color>",cliDescription:"A color string given in the format 'rgb' or 'rrggbb' (no #). This option determines the color of errors rendered by the -t option.",cliProcessor:e=>"#"+e},macros:{type:"object",cli:"-m, --macro <def>",cliDescription:"Define custom macro of the form '\\foo:expansion' (use multiple -m arguments for multiple macros).",cliDefault:[],cliProcessor:(e,t)=>(t.push(e),t)},minRuleThickness:{type:"number",description:"Specifies a minimum thickness, in ems, for fraction lines, `\\sqrt` top lines, `{array}` vertical lines, `\\hline`, `\\hdashline`, `\\underline`, `\\overline`, and the borders of `\\fbox`, `\\boxed`, and `\\fcolorbox`.",processor:e=>Math.max(0,e),cli:"--min-rule-thickness <size>",cliProcessor:parseFloat},colorIsTextColor:{type:"boolean",description:"Makes \\color behave like LaTeX's 2-argument \\textcolor, instead of LaTeX's one-argument \\color mode change.",cli:"-b, --color-is-text-color"},strict:{type:[{enum:["warn","ignore","error"]},"boolean","function"],description:"Turn on strict / LaTeX faithfulness mode, which throws an error if the input uses features that are not supported by LaTeX.",cli:"-S, --strict",cliDefault:!1},trust:{type:["boolean","function"],description:"Trust the input, enabling all HTML features such as \\url.",cli:"-T, --trust"},maxSize:{type:"number",default:1/0,description:"If non-zero, all user-specified sizes, e.g. in \\rule{500em}{500em}, will be capped to maxSize ems. Otherwise, elements and spaces can be arbitrarily large",processor:e=>Math.max(0,e),cli:"-s, --max-size <n>",cliProcessor:parseInt},maxExpand:{type:"number",default:1e3,description:"Limit the number of macro expansions to the specified number, to prevent e.g. infinite macro loops. If set to Infinity, the macro expander will try to fully expand as in LaTeX.",processor:e=>Math.max(0,e),cli:"-e, --max-expand <n>",cliProcessor:e=>"Infinity"===e?1/0:parseInt(e)},globalGroup:{type:"boolean",cli:!1}};function uO(e){if(e.default)return e.default;var t=e.type,r=Array.isArray(t)?t[0]:t;if("string"!=typeof r)return r.enum[0];switch(r){case"boolean":return!1;case"string":return"";case"number":return 0;case"object":return{}}}class lO{constructor(e){for(var t in this.displayMode=void 0,this.output=void 0,this.leqno=void 0,this.fleqn=void 0,this.throwOnError=void 0,this.errorColor=void 0,this.macros=void 0,this.minRuleThickness=void 0,this.colorIsTextColor=void 0,this.strict=void 0,this.trust=void 0,this.maxSize=void 0,this.maxExpand=void 0,this.globalGroup=void 0,e=e||{},sO)if(sO.hasOwnProperty(t)){var r=sO[t];this[t]=void 0!==e[t]?r.processor?r.processor(e[t]):e[t]:uO(r)}}reportNonstrict(e,t,r){var n=this.strict;if("function"==typeof n&&(n=n(e,t,r)),n&&"ignore"!==n){if(!0===n||"error"===n)throw new tO("LaTeX-incompatible input and strict mode is set to 'error': "+t+" ["+e+"]",r);"warn"===n?"undefined"!=typeof console&&console.warn("LaTeX-incompatible input and strict mode is set to 'warn': "+t+" ["+e+"]"):"undefined"!=typeof console&&console.warn("LaTeX-incompatible input and strict mode is set to unrecognized '"+n+"': "+t+" ["+e+"]")}}useStrictBehavior(e,t,r){var n=this.strict;if("function"==typeof n)try{n=n(e,t,r)}catch(e){n="error"}return!(!n||"ignore"===n)&&(!0===n||"error"===n||("warn"===n?("undefined"!=typeof console&&console.warn("LaTeX-incompatible input and strict mode is set to 'warn': "+t+" ["+e+"]"),!1):("undefined"!=typeof console&&console.warn("LaTeX-incompatible input and strict mode is set to unrecognized '"+n+"': "+t+" ["+e+"]"),!1)))}isTrusted(e){if(e.url&&!e.protocol){var t=aO.protocolFromUrl(e.url);if(null==t)return!1;e.protocol=t}var r="function"==typeof this.trust?this.trust(e):this.trust;return Boolean(r)}}class cO{constructor(e,t,r){this.id=void 0,this.size=void 0,this.cramped=void 0,this.id=e,this.size=t,this.cramped=r}sup(){return dO[hO[this.id]]}sub(){return dO[fO[this.id]]}fracNum(){return dO[pO[this.id]]}fracDen(){return dO[gO[this.id]]}cramp(){return dO[mO[this.id]]}text(){return dO[vO[this.id]]}isTight(){return this.size>=2}}var dO=[new cO(0,0,!1),new cO(1,0,!0),new cO(2,1,!1),new cO(3,1,!0),new cO(4,2,!1),new cO(5,2,!0),new cO(6,3,!1),new cO(7,3,!0)],hO=[4,5,4,5,6,7,6,7],fO=[5,5,5,5,7,7,7,7],pO=[2,3,4,5,6,7,6,7],gO=[3,3,5,5,7,7,7,7],mO=[1,1,3,3,5,5,7,7],vO=[0,1,2,3,2,3,2,3],yO={DISPLAY:dO[0],TEXT:dO[2],SCRIPT:dO[4],SCRIPTSCRIPT:dO[6]},bO=[{name:"latin",blocks:[[256,591],[768,879]]},{name:"cyrillic",blocks:[[1024,1279]]},{name:"armenian",blocks:[[1328,1423]]},{name:"brahmic",blocks:[[2304,4255]]},{name:"georgian",blocks:[[4256,4351]]},{name:"cjk",blocks:[[12288,12543],[19968,40879],[65280,65376]]},{name:"hangul",blocks:[[44032,55215]]}];var DO=[];function CO(e){for(var t=0;t<DO.length;t+=2)if(e>=DO[t]&&e<=DO[t+1])return!0;return!1}bO.forEach(e=>e.blocks.forEach(e=>DO.push(...e)));var wO=80,EO={doubleleftarrow:"M262 157\nl10-10c34-36 62.7-77 86-123 3.3-8 5-13.3 5-16 0-5.3-6.7-8-20-8-7.3\n 0-12.2.5-14.5 1.5-2.3 1-4.8 4.5-7.5 10.5-49.3 97.3-121.7 169.3-217 216-28\n 14-57.3 25-88 33-6.7 2-11 3.8-13 5.5-2 1.7-3 4.2-3 7.5s1 5.8 3 7.5\nc2 1.7 6.3 3.5 13 5.5 68 17.3 128.2 47.8 180.5 91.5 52.3 43.7 93.8 96.2 124.5\n 157.5 9.3 8 15.3 12.3 18 13h6c12-.7 18-4 18-10 0-2-1.7-7-5-15-23.3-46-52-87\n-86-123l-10-10h399738v-40H218c328 0 0 0 0 0l-10-8c-26.7-20-65.7-43-117-69 2.7\n-2 6-3.7 10-5 36.7-16 72.3-37.3 107-64l10-8h399782v-40z\nm8 0v40h399730v-40zm0 194v40h399730v-40z",doublerightarrow:"M399738 392l\n-10 10c-34 36-62.7 77-86 123-3.3 8-5 13.3-5 16 0 5.3 6.7 8 20 8 7.3 0 12.2-.5\n 14.5-1.5 2.3-1 4.8-4.5 7.5-10.5 49.3-97.3 121.7-169.3 217-216 28-14 57.3-25 88\n-33 6.7-2 11-3.8 13-5.5 2-1.7 3-4.2 3-7.5s-1-5.8-3-7.5c-2-1.7-6.3-3.5-13-5.5-68\n-17.3-128.2-47.8-180.5-91.5-52.3-43.7-93.8-96.2-124.5-157.5-9.3-8-15.3-12.3-18\n-13h-6c-12 .7-18 4-18 10 0 2 1.7 7 5 15 23.3 46 52 87 86 123l10 10H0v40h399782\nc-328 0 0 0 0 0l10 8c26.7 20 65.7 43 117 69-2.7 2-6 3.7-10 5-36.7 16-72.3 37.3\n-107 64l-10 8H0v40zM0 157v40h399730v-40zm0 194v40h399730v-40z",leftarrow:"M400000 241H110l3-3c68.7-52.7 113.7-120\n 135-202 4-14.7 6-23 6-25 0-7.3-7-11-21-11-8 0-13.2.8-15.5 2.5-2.3 1.7-4.2 5.8\n-5.5 12.5-1.3 4.7-2.7 10.3-4 17-12 48.7-34.8 92-68.5 130S65.3 228.3 18 247\nc-10 4-16 7.7-18 11 0 8.7 6 14.3 18 17 47.3 18.7 87.8 47 121.5 85S196 441.3 208\n 490c.7 2 1.3 5 2 9s1.2 6.7 1.5 8c.3 1.3 1 3.3 2 6s2.2 4.5 3.5 5.5c1.3 1 3.3\n 1.8 6 2.5s6 1 10 1c14 0 21-3.7 21-11 0-2-2-10.3-6-25-20-79.3-65-146.7-135-202\n l-3-3h399890zM100 241v40h399900v-40z",leftbrace:"M6 548l-6-6v-35l6-11c56-104 135.3-181.3 238-232 57.3-28.7 117\n-45 179-50h399577v120H403c-43.3 7-81 15-113 26-100.7 33-179.7 91-237 174-2.7\n 5-6 9-10 13-.7 1-7.3 1-20 1H6z",leftbraceunder:"M0 6l6-6h17c12.688 0 19.313.3 20 1 4 4 7.313 8.3 10 13\n 35.313 51.3 80.813 93.8 136.5 127.5 55.688 33.7 117.188 55.8 184.5 66.5.688\n 0 2 .3 4 1 18.688 2.7 76 4.3 172 5h399450v120H429l-6-1c-124.688-8-235-61.7\n-331-161C60.687 138.7 32.312 99.3 7 54L0 41V6z",leftgroup:"M400000 80\nH435C64 80 168.3 229.4 21 260c-5.9 1.2-18 0-18 0-2 0-3-1-3-3v-38C76 61 257 0\n 435 0h399565z",leftgroupunder:"M400000 262\nH435C64 262 168.3 112.6 21 82c-5.9-1.2-18 0-18 0-2 0-3 1-3 3v38c76 158 257 219\n 435 219h399565z",leftharpoon:"M0 267c.7 5.3 3 10 7 14h399993v-40H93c3.3\n-3.3 10.2-9.5 20.5-18.5s17.8-15.8 22.5-20.5c50.7-52 88-110.3 112-175 4-11.3 5\n-18.3 3-21-1.3-4-7.3-6-18-6-8 0-13 .7-15 2s-4.7 6.7-8 16c-42 98.7-107.3 174.7\n-196 228-6.7 4.7-10.7 8-12 10-1.3 2-2 5.7-2 11zm100-26v40h399900v-40z",leftharpoonplus:"M0 267c.7 5.3 3 10 7 14h399993v-40H93c3.3-3.3 10.2-9.5\n 20.5-18.5s17.8-15.8 22.5-20.5c50.7-52 88-110.3 112-175 4-11.3 5-18.3 3-21-1.3\n-4-7.3-6-18-6-8 0-13 .7-15 2s-4.7 6.7-8 16c-42 98.7-107.3 174.7-196 228-6.7 4.7\n-10.7 8-12 10-1.3 2-2 5.7-2 11zm100-26v40h399900v-40zM0 435v40h400000v-40z\nm0 0v40h400000v-40z",leftharpoondown:"M7 241c-4 4-6.333 8.667-7 14 0 5.333.667 9 2 11s5.333\n 5.333 12 10c90.667 54 156 130 196 228 3.333 10.667 6.333 16.333 9 17 2 .667 5\n 1 9 1h5c10.667 0 16.667-2 18-6 2-2.667 1-9.667-3-21-32-87.333-82.667-157.667\n-152-211l-3-3h399907v-40zM93 281 H400000 v-40L7 241z",leftharpoondownplus:"M7 435c-4 4-6.3 8.7-7 14 0 5.3.7 9 2 11s5.3 5.3 12\n 10c90.7 54 156 130 196 228 3.3 10.7 6.3 16.3 9 17 2 .7 5 1 9 1h5c10.7 0 16.7\n-2 18-6 2-2.7 1-9.7-3-21-32-87.3-82.7-157.7-152-211l-3-3h399907v-40H7zm93 0\nv40h399900v-40zM0 241v40h399900v-40zm0 0v40h399900v-40z",lefthook:"M400000 281 H103s-33-11.2-61-33.5S0 197.3 0 164s14.2-61.2 42.5\n-83.5C70.8 58.2 104 47 142 47 c16.7 0 25 6.7 25 20 0 12-8.7 18.7-26 20-40 3.3\n-68.7 15.7-86 37-10 12-15 25.3-15 40 0 22.7 9.8 40.7 29.5 54 19.7 13.3 43.5 21\n 71.5 23h399859zM103 281v-40h399897v40z",leftlinesegment:"M40 281 V428 H0 V94 H40 V241 H400000 v40z\nM40 281 V428 H0 V94 H40 V241 H400000 v40z",leftmapsto:"M40 281 V448H0V74H40V241H400000v40z\nM40 281 V448H0V74H40V241H400000v40z",leftToFrom:"M0 147h400000v40H0zm0 214c68 40 115.7 95.7 143 167h22c15.3 0 23\n-.3 23-1 0-1.3-5.3-13.7-16-37-18-35.3-41.3-69-70-101l-7-8h399905v-40H95l7-8\nc28.7-32 52-65.7 70-101 10.7-23.3 16-35.7 16-37 0-.7-7.7-1-23-1h-22C115.7 265.3\n 68 321 0 361zm0-174v-40h399900v40zm100 154v40h399900v-40z",longequal:"M0 50 h400000 v40H0z m0 194h40000v40H0z\nM0 50 h400000 v40H0z m0 194h40000v40H0z",midbrace:"M200428 334\nc-100.7-8.3-195.3-44-280-108-55.3-42-101.7-93-139-153l-9-14c-2.7 4-5.7 8.7-9 14\n-53.3 86.7-123.7 153-211 199-66.7 36-137.3 56.3-212 62H0V214h199568c178.3-11.7\n 311.7-78.3 403-201 6-8 9.7-12 11-12 .7-.7 6.7-1 18-1s17.3.3 18 1c1.3 0 5 4 11\n 12 44.7 59.3 101.3 106.3 170 141s145.3 54.3 229 60h199572v120z",midbraceunder:"M199572 214\nc100.7 8.3 195.3 44 280 108 55.3 42 101.7 93 139 153l9 14c2.7-4 5.7-8.7 9-14\n 53.3-86.7 123.7-153 211-199 66.7-36 137.3-56.3 212-62h199568v120H200432c-178.3\n 11.7-311.7 78.3-403 201-6 8-9.7 12-11 12-.7.7-6.7 1-18 1s-17.3-.3-18-1c-1.3 0\n-5-4-11-12-44.7-59.3-101.3-106.3-170-141s-145.3-54.3-229-60H0V214z",oiintSize1:"M512.6 71.6c272.6 0 320.3 106.8 320.3 178.2 0 70.8-47.7 177.6\n-320.3 177.6S193.1 320.6 193.1 249.8c0-71.4 46.9-178.2 319.5-178.2z\nm368.1 178.2c0-86.4-60.9-215.4-368.1-215.4-306.4 0-367.3 129-367.3 215.4 0 85.8\n60.9 214.8 367.3 214.8 307.2 0 368.1-129 368.1-214.8z",oiintSize2:"M757.8 100.1c384.7 0 451.1 137.6 451.1 230 0 91.3-66.4 228.8\n-451.1 228.8-386.3 0-452.7-137.5-452.7-228.8 0-92.4 66.4-230 452.7-230z\nm502.4 230c0-111.2-82.4-277.2-502.4-277.2s-504 166-504 277.2\nc0 110 84 276 504 276s502.4-166 502.4-276z",oiiintSize1:"M681.4 71.6c408.9 0 480.5 106.8 480.5 178.2 0 70.8-71.6 177.6\n-480.5 177.6S202.1 320.6 202.1 249.8c0-71.4 70.5-178.2 479.3-178.2z\nm525.8 178.2c0-86.4-86.8-215.4-525.7-215.4-437.9 0-524.7 129-524.7 215.4 0\n85.8 86.8 214.8 524.7 214.8 438.9 0 525.7-129 525.7-214.8z",oiiintSize2:"M1021.2 53c603.6 0 707.8 165.8 707.8 277.2 0 110-104.2 275.8\n-707.8 275.8-606 0-710.2-165.8-710.2-275.8C311 218.8 415.2 53 1021.2 53z\nm770.4 277.1c0-131.2-126.4-327.6-770.5-327.6S248.4 198.9 248.4 330.1\nc0 130 128.8 326.4 772.7 326.4s770.5-196.4 770.5-326.4z",rightarrow:"M0 241v40h399891c-47.3 35.3-84 78-110 128\n-16.7 32-27.7 63.7-33 95 0 1.3-.2 2.7-.5 4-.3 1.3-.5 2.3-.5 3 0 7.3 6.7 11 20\n 11 8 0 13.2-.8 15.5-2.5 2.3-1.7 4.2-5.5 5.5-11.5 2-13.3 5.7-27 11-41 14.7-44.7\n 39-84.5 73-119.5s73.7-60.2 119-75.5c6-2 9-5.7 9-11s-3-9-9-11c-45.3-15.3-85\n-40.5-119-75.5s-58.3-74.8-73-119.5c-4.7-14-8.3-27.3-11-40-1.3-6.7-3.2-10.8-5.5\n-12.5-2.3-1.7-7.5-2.5-15.5-2.5-14 0-21 3.7-21 11 0 2 2 10.3 6 25 20.7 83.3 67\n 151.7 139 205zm0 0v40h399900v-40z",rightbrace:"M400000 542l\n-6 6h-17c-12.7 0-19.3-.3-20-1-4-4-7.3-8.3-10-13-35.3-51.3-80.8-93.8-136.5-127.5\ns-117.2-55.8-184.5-66.5c-.7 0-2-.3-4-1-18.7-2.7-76-4.3-172-5H0V214h399571l6 1\nc124.7 8 235 61.7 331 161 31.3 33.3 59.7 72.7 85 118l7 13v35z",rightbraceunder:"M399994 0l6 6v35l-6 11c-56 104-135.3 181.3-238 232-57.3\n 28.7-117 45-179 50H-300V214h399897c43.3-7 81-15 113-26 100.7-33 179.7-91 237\n-174 2.7-5 6-9 10-13 .7-1 7.3-1 20-1h17z",rightgroup:"M0 80h399565c371 0 266.7 149.4 414 180 5.9 1.2 18 0 18 0 2 0\n 3-1 3-3v-38c-76-158-257-219-435-219H0z",rightgroupunder:"M0 262h399565c371 0 266.7-149.4 414-180 5.9-1.2 18 0 18\n 0 2 0 3 1 3 3v38c-76 158-257 219-435 219H0z",rightharpoon:"M0 241v40h399993c4.7-4.7 7-9.3 7-14 0-9.3\n-3.7-15.3-11-18-92.7-56.7-159-133.7-199-231-3.3-9.3-6-14.7-8-16-2-1.3-7-2-15-2\n-10.7 0-16.7 2-18 6-2 2.7-1 9.7 3 21 15.3 42 36.7 81.8 64 119.5 27.3 37.7 58\n 69.2 92 94.5zm0 0v40h399900v-40z",rightharpoonplus:"M0 241v40h399993c4.7-4.7 7-9.3 7-14 0-9.3-3.7-15.3-11\n-18-92.7-56.7-159-133.7-199-231-3.3-9.3-6-14.7-8-16-2-1.3-7-2-15-2-10.7 0-16.7\n 2-18 6-2 2.7-1 9.7 3 21 15.3 42 36.7 81.8 64 119.5 27.3 37.7 58 69.2 92 94.5z\nm0 0v40h399900v-40z m100 194v40h399900v-40zm0 0v40h399900v-40z",rightharpoondown:"M399747 511c0 7.3 6.7 11 20 11 8 0 13-.8 15-2.5s4.7-6.8\n 8-15.5c40-94 99.3-166.3 178-217 13.3-8 20.3-12.3 21-13 5.3-3.3 8.5-5.8 9.5\n-7.5 1-1.7 1.5-5.2 1.5-10.5s-2.3-10.3-7-15H0v40h399908c-34 25.3-64.7 57-92 95\n-27.3 38-48.7 77.7-64 119-3.3 8.7-5 14-5 16zM0 241v40h399900v-40z",rightharpoondownplus:"M399747 705c0 7.3 6.7 11 20 11 8 0 13-.8\n 15-2.5s4.7-6.8 8-15.5c40-94 99.3-166.3 178-217 13.3-8 20.3-12.3 21-13 5.3-3.3\n 8.5-5.8 9.5-7.5 1-1.7 1.5-5.2 1.5-10.5s-2.3-10.3-7-15H0v40h399908c-34 25.3\n-64.7 57-92 95-27.3 38-48.7 77.7-64 119-3.3 8.7-5 14-5 16zM0 435v40h399900v-40z\nm0-194v40h400000v-40zm0 0v40h400000v-40z",righthook:"M399859 241c-764 0 0 0 0 0 40-3.3 68.7-15.7 86-37 10-12 15-25.3\n 15-40 0-22.7-9.8-40.7-29.5-54-19.7-13.3-43.5-21-71.5-23-17.3-1.3-26-8-26-20 0\n-13.3 8.7-20 26-20 38 0 71 11.2 99 33.5 0 0 7 5.6 21 16.7 14 11.2 21 33.5 21\n 66.8s-14 61.2-42 83.5c-28 22.3-61 33.5-99 33.5L0 241z M0 281v-40h399859v40z",rightlinesegment:"M399960 241 V94 h40 V428 h-40 V281 H0 v-40z\nM399960 241 V94 h40 V428 h-40 V281 H0 v-40z",rightToFrom:"M400000 167c-70.7-42-118-97.7-142-167h-23c-15.3 0-23 .3-23\n 1 0 1.3 5.3 13.7 16 37 18 35.3 41.3 69 70 101l7 8H0v40h399905l-7 8c-28.7 32\n-52 65.7-70 101-10.7 23.3-16 35.7-16 37 0 .7 7.7 1 23 1h23c24-69.3 71.3-125 142\n-167z M100 147v40h399900v-40zM0 341v40h399900v-40z",twoheadleftarrow:"M0 167c68 40\n 115.7 95.7 143 167h22c15.3 0 23-.3 23-1 0-1.3-5.3-13.7-16-37-18-35.3-41.3-69\n-70-101l-7-8h125l9 7c50.7 39.3 85 86 103 140h46c0-4.7-6.3-18.7-19-42-18-35.3\n-40-67.3-66-96l-9-9h399716v-40H284l9-9c26-28.7 48-60.7 66-96 12.7-23.333 19\n-37.333 19-42h-46c-18 54-52.3 100.7-103 140l-9 7H95l7-8c28.7-32 52-65.7 70-101\n 10.7-23.333 16-35.7 16-37 0-.7-7.7-1-23-1h-22C115.7 71.3 68 127 0 167z",twoheadrightarrow:"M400000 167\nc-68-40-115.7-95.7-143-167h-22c-15.3 0-23 .3-23 1 0 1.3 5.3 13.7 16 37 18 35.3\n 41.3 69 70 101l7 8h-125l-9-7c-50.7-39.3-85-86-103-140h-46c0 4.7 6.3 18.7 19 42\n 18 35.3 40 67.3 66 96l9 9H0v40h399716l-9 9c-26 28.7-48 60.7-66 96-12.7 23.333\n-19 37.333-19 42h46c18-54 52.3-100.7 103-140l9-7h125l-7 8c-28.7 32-52 65.7-70\n 101-10.7 23.333-16 35.7-16 37 0 .7 7.7 1 23 1h22c27.3-71.3 75-127 143-167z",tilde1:"M200 55.538c-77 0-168 73.953-177 73.953-3 0-7\n-2.175-9-5.437L2 97c-1-2-2-4-2-6 0-4 2-7 5-9l20-12C116 12 171 0 207 0c86 0\n 114 68 191 68 78 0 168-68 177-68 4 0 7 2 9 5l12 19c1 2.175 2 4.35 2 6.525 0\n 4.35-2 7.613-5 9.788l-19 13.05c-92 63.077-116.937 75.308-183 76.128\n-68.267.847-113-73.952-191-73.952z",tilde2:"M344 55.266c-142 0-300.638 81.316-311.5 86.418\n-8.01 3.762-22.5 10.91-23.5 5.562L1 120c-1-2-1-3-1-4 0-5 3-9 8-10l18.4-9C160.9\n 31.9 283 0 358 0c148 0 188 122 331 122s314-97 326-97c4 0 8 2 10 7l7 21.114\nc1 2.14 1 3.21 1 4.28 0 5.347-3 9.626-7 10.696l-22.3 12.622C852.6 158.372 751\n 181.476 676 181.476c-149 0-189-126.21-332-126.21z",tilde3:"M786 59C457 59 32 175.242 13 175.242c-6 0-10-3.457\n-11-10.37L.15 138c-1-7 3-12 10-13l19.2-6.4C378.4 40.7 634.3 0 804.3 0c337 0\n 411.8 157 746.8 157 328 0 754-112 773-112 5 0 10 3 11 9l1 14.075c1 8.066-.697\n 16.595-6.697 17.492l-21.052 7.31c-367.9 98.146-609.15 122.696-778.15 122.696\n -338 0-409-156.573-744-156.573z",tilde4:"M786 58C457 58 32 177.487 13 177.487c-6 0-10-3.345\n-11-10.035L.15 143c-1-7 3-12 10-13l22-6.7C381.2 35 637.15 0 807.15 0c337 0 409\n 177 744 177 328 0 754-127 773-127 5 0 10 3 11 9l1 14.794c1 7.805-3 13.38-9\n 14.495l-20.7 5.574c-366.85 99.79-607.3 139.372-776.3 139.372-338 0-409\n -175.236-744-175.236z",vec:"M377 20c0-5.333 1.833-10 5.5-14S391 0 397 0c4.667 0 8.667 1.667 12 5\n3.333 2.667 6.667 9 10 19 6.667 24.667 20.333 43.667 41 57 7.333 4.667 11\n10.667 11 18 0 6-1 10-3 12s-6.667 5-14 9c-28.667 14.667-53.667 35.667-75 63\n-1.333 1.333-3.167 3.5-5.5 6.5s-4 4.833-5 5.5c-1 .667-2.5 1.333-4.5 2s-4.333 1\n-7 1c-4.667 0-9.167-1.833-13.5-5.5S337 184 337 178c0-12.667 15.667-32.333 47-59\nH213l-171-1c-8.667-6-13-12.333-13-19 0-4.667 4.333-11.333 13-20h359\nc-16-25.333-24-45-24-59z",widehat1:"M529 0h5l519 115c5 1 9 5 9 10 0 1-1 2-1 3l-4 22\nc-1 5-5 9-11 9h-2L532 67 19 159h-2c-5 0-9-4-11-9l-5-22c-1-6 2-12 8-13z",widehat2:"M1181 0h2l1171 176c6 0 10 5 10 11l-2 23c-1 6-5 10\n-11 10h-1L1182 67 15 220h-1c-6 0-10-4-11-10l-2-23c-1-6 4-11 10-11z",widehat3:"M1181 0h2l1171 236c6 0 10 5 10 11l-2 23c-1 6-5 10\n-11 10h-1L1182 67 15 280h-1c-6 0-10-4-11-10l-2-23c-1-6 4-11 10-11z",widehat4:"M1181 0h2l1171 296c6 0 10 5 10 11l-2 23c-1 6-5 10\n-11 10h-1L1182 67 15 340h-1c-6 0-10-4-11-10l-2-23c-1-6 4-11 10-11z",widecheck1:"M529,159h5l519,-115c5,-1,9,-5,9,-10c0,-1,-1,-2,-1,-3l-4,-22c-1,\n-5,-5,-9,-11,-9h-2l-512,92l-513,-92h-2c-5,0,-9,4,-11,9l-5,22c-1,6,2,12,8,13z",widecheck2:"M1181,220h2l1171,-176c6,0,10,-5,10,-11l-2,-23c-1,-6,-5,-10,\n-11,-10h-1l-1168,153l-1167,-153h-1c-6,0,-10,4,-11,10l-2,23c-1,6,4,11,10,11z",widecheck3:"M1181,280h2l1171,-236c6,0,10,-5,10,-11l-2,-23c-1,-6,-5,-10,\n-11,-10h-1l-1168,213l-1167,-213h-1c-6,0,-10,4,-11,10l-2,23c-1,6,4,11,10,11z",widecheck4:"M1181,340h2l1171,-296c6,0,10,-5,10,-11l-2,-23c-1,-6,-5,-10,\n-11,-10h-1l-1168,273l-1167,-273h-1c-6,0,-10,4,-11,10l-2,23c-1,6,4,11,10,11z",baraboveleftarrow:"M400000 620h-399890l3 -3c68.7 -52.7 113.7 -120 135 -202\nc4 -14.7 6 -23 6 -25c0 -7.3 -7 -11 -21 -11c-8 0 -13.2 0.8 -15.5 2.5\nc-2.3 1.7 -4.2 5.8 -5.5 12.5c-1.3 4.7 -2.7 10.3 -4 17c-12 48.7 -34.8 92 -68.5 130\ns-74.2 66.3 -121.5 85c-10 4 -16 7.7 -18 11c0 8.7 6 14.3 18 17c47.3 18.7 87.8 47\n121.5 85s56.5 81.3 68.5 130c0.7 2 1.3 5 2 9s1.2 6.7 1.5 8c0.3 1.3 1 3.3 2 6\ns2.2 4.5 3.5 5.5c1.3 1 3.3 1.8 6 2.5s6 1 10 1c14 0 21 -3.7 21 -11\nc0 -2 -2 -10.3 -6 -25c-20 -79.3 -65 -146.7 -135 -202l-3 -3h399890z\nM100 620v40h399900v-40z M0 241v40h399900v-40zM0 241v40h399900v-40z",rightarrowabovebar:"M0 241v40h399891c-47.3 35.3-84 78-110 128-16.7 32\n-27.7 63.7-33 95 0 1.3-.2 2.7-.5 4-.3 1.3-.5 2.3-.5 3 0 7.3 6.7 11 20 11 8 0\n13.2-.8 15.5-2.5 2.3-1.7 4.2-5.5 5.5-11.5 2-13.3 5.7-27 11-41 14.7-44.7 39\n-84.5 73-119.5s73.7-60.2 119-75.5c6-2 9-5.7 9-11s-3-9-9-11c-45.3-15.3-85-40.5\n-119-75.5s-58.3-74.8-73-119.5c-4.7-14-8.3-27.3-11-40-1.3-6.7-3.2-10.8-5.5\n-12.5-2.3-1.7-7.5-2.5-15.5-2.5-14 0-21 3.7-21 11 0 2 2 10.3 6 25 20.7 83.3 67\n151.7 139 205zm96 379h399894v40H0zm0 0h399904v40H0z",baraboveshortleftharpoon:"M507,435c-4,4,-6.3,8.7,-7,14c0,5.3,0.7,9,2,11\nc1.3,2,5.3,5.3,12,10c90.7,54,156,130,196,228c3.3,10.7,6.3,16.3,9,17\nc2,0.7,5,1,9,1c0,0,5,0,5,0c10.7,0,16.7,-2,18,-6c2,-2.7,1,-9.7,-3,-21\nc-32,-87.3,-82.7,-157.7,-152,-211c0,0,-3,-3,-3,-3l399351,0l0,-40\nc-398570,0,-399437,0,-399437,0z M593 435 v40 H399500 v-40z\nM0 281 v-40 H399908 v40z M0 281 v-40 H399908 v40z",rightharpoonaboveshortbar:"M0,241 l0,40c399126,0,399993,0,399993,0\nc4.7,-4.7,7,-9.3,7,-14c0,-9.3,-3.7,-15.3,-11,-18c-92.7,-56.7,-159,-133.7,-199,\n-231c-3.3,-9.3,-6,-14.7,-8,-16c-2,-1.3,-7,-2,-15,-2c-10.7,0,-16.7,2,-18,6\nc-2,2.7,-1,9.7,3,21c15.3,42,36.7,81.8,64,119.5c27.3,37.7,58,69.2,92,94.5z\nM0 241 v40 H399908 v-40z M0 475 v-40 H399500 v40z M0 475 v-40 H399500 v40z",shortbaraboveleftharpoon:"M7,435c-4,4,-6.3,8.7,-7,14c0,5.3,0.7,9,2,11\nc1.3,2,5.3,5.3,12,10c90.7,54,156,130,196,228c3.3,10.7,6.3,16.3,9,17c2,0.7,5,1,9,\n1c0,0,5,0,5,0c10.7,0,16.7,-2,18,-6c2,-2.7,1,-9.7,-3,-21c-32,-87.3,-82.7,-157.7,\n-152,-211c0,0,-3,-3,-3,-3l399907,0l0,-40c-399126,0,-399993,0,-399993,0z\nM93 435 v40 H400000 v-40z M500 241 v40 H400000 v-40z M500 241 v40 H400000 v-40z",shortrightharpoonabovebar:"M53,241l0,40c398570,0,399437,0,399437,0\nc4.7,-4.7,7,-9.3,7,-14c0,-9.3,-3.7,-15.3,-11,-18c-92.7,-56.7,-159,-133.7,-199,\n-231c-3.3,-9.3,-6,-14.7,-8,-16c-2,-1.3,-7,-2,-15,-2c-10.7,0,-16.7,2,-18,6\nc-2,2.7,-1,9.7,3,21c15.3,42,36.7,81.8,64,119.5c27.3,37.7,58,69.2,92,94.5z\nM500 241 v40 H399408 v-40z M500 435 v40 H400000 v-40z"};class AO{constructor(e){this.children=void 0,this.classes=void 0,this.height=void 0,this.depth=void 0,this.maxFontSize=void 0,this.style=void 0,this.children=e,this.classes=[],this.height=0,this.depth=0,this.maxFontSize=0,this.style={}}hasClass(e){return aO.contains(this.classes,e)}toNode(){for(var e=document.createDocumentFragment(),t=0;t<this.children.length;t++)e.appendChild(this.children[t].toNode());return e}toMarkup(){for(var e="",t=0;t<this.children.length;t++)e+=this.children[t].toMarkup();return e}toText(){return this.children.map(e=>e.toText()).join("")}}var xO={"AMS-Regular":{32:[0,0,0,0,.25],65:[0,.68889,0,0,.72222],66:[0,.68889,0,0,.66667],67:[0,.68889,0,0,.72222],68:[0,.68889,0,0,.72222],69:[0,.68889,0,0,.66667],70:[0,.68889,0,0,.61111],71:[0,.68889,0,0,.77778],72:[0,.68889,0,0,.77778],73:[0,.68889,0,0,.38889],74:[.16667,.68889,0,0,.5],75:[0,.68889,0,0,.77778],76:[0,.68889,0,0,.66667],77:[0,.68889,0,0,.94445],78:[0,.68889,0,0,.72222],79:[.16667,.68889,0,0,.77778],80:[0,.68889,0,0,.61111],81:[.16667,.68889,0,0,.77778],82:[0,.68889,0,0,.72222],83:[0,.68889,0,0,.55556],84:[0,.68889,0,0,.66667],85:[0,.68889,0,0,.72222],86:[0,.68889,0,0,.72222],87:[0,.68889,0,0,1],88:[0,.68889,0,0,.72222],89:[0,.68889,0,0,.72222],90:[0,.68889,0,0,.66667],107:[0,.68889,0,0,.55556],160:[0,0,0,0,.25],165:[0,.675,.025,0,.75],174:[.15559,.69224,0,0,.94666],240:[0,.68889,0,0,.55556],295:[0,.68889,0,0,.54028],710:[0,.825,0,0,2.33334],732:[0,.9,0,0,2.33334],770:[0,.825,0,0,2.33334],771:[0,.9,0,0,2.33334],989:[.08167,.58167,0,0,.77778],1008:[0,.43056,.04028,0,.66667],8245:[0,.54986,0,0,.275],8463:[0,.68889,0,0,.54028],8487:[0,.68889,0,0,.72222],8498:[0,.68889,0,0,.55556],8502:[0,.68889,0,0,.66667],8503:[0,.68889,0,0,.44445],8504:[0,.68889,0,0,.66667],8513:[0,.68889,0,0,.63889],8592:[-.03598,.46402,0,0,.5],8594:[-.03598,.46402,0,0,.5],8602:[-.13313,.36687,0,0,1],8603:[-.13313,.36687,0,0,1],8606:[.01354,.52239,0,0,1],8608:[.01354,.52239,0,0,1],8610:[.01354,.52239,0,0,1.11111],8611:[.01354,.52239,0,0,1.11111],8619:[0,.54986,0,0,1],8620:[0,.54986,0,0,1],8621:[-.13313,.37788,0,0,1.38889],8622:[-.13313,.36687,0,0,1],8624:[0,.69224,0,0,.5],8625:[0,.69224,0,0,.5],8630:[0,.43056,0,0,1],8631:[0,.43056,0,0,1],8634:[.08198,.58198,0,0,.77778],8635:[.08198,.58198,0,0,.77778],8638:[.19444,.69224,0,0,.41667],8639:[.19444,.69224,0,0,.41667],8642:[.19444,.69224,0,0,.41667],8643:[.19444,.69224,0,0,.41667],8644:[.1808,.675,0,0,1],8646:[.1808,.675,0,0,1],8647:[.1808,.675,0,0,1],8648:[.19444,.69224,0,0,.83334],8649:[.1808,.675,0,0,1],8650:[.19444,.69224,0,0,.83334],8651:[.01354,.52239,0,0,1],8652:[.01354,.52239,0,0,1],8653:[-.13313,.36687,0,0,1],8654:[-.13313,.36687,0,0,1],8655:[-.13313,.36687,0,0,1],8666:[.13667,.63667,0,0,1],8667:[.13667,.63667,0,0,1],8669:[-.13313,.37788,0,0,1],8672:[-.064,.437,0,0,1.334],8674:[-.064,.437,0,0,1.334],8705:[0,.825,0,0,.5],8708:[0,.68889,0,0,.55556],8709:[.08167,.58167,0,0,.77778],8717:[0,.43056,0,0,.42917],8722:[-.03598,.46402,0,0,.5],8724:[.08198,.69224,0,0,.77778],8726:[.08167,.58167,0,0,.77778],8733:[0,.69224,0,0,.77778],8736:[0,.69224,0,0,.72222],8737:[0,.69224,0,0,.72222],8738:[.03517,.52239,0,0,.72222],8739:[.08167,.58167,0,0,.22222],8740:[.25142,.74111,0,0,.27778],8741:[.08167,.58167,0,0,.38889],8742:[.25142,.74111,0,0,.5],8756:[0,.69224,0,0,.66667],8757:[0,.69224,0,0,.66667],8764:[-.13313,.36687,0,0,.77778],8765:[-.13313,.37788,0,0,.77778],8769:[-.13313,.36687,0,0,.77778],8770:[-.03625,.46375,0,0,.77778],8774:[.30274,.79383,0,0,.77778],8776:[-.01688,.48312,0,0,.77778],8778:[.08167,.58167,0,0,.77778],8782:[.06062,.54986,0,0,.77778],8783:[.06062,.54986,0,0,.77778],8785:[.08198,.58198,0,0,.77778],8786:[.08198,.58198,0,0,.77778],8787:[.08198,.58198,0,0,.77778],8790:[0,.69224,0,0,.77778],8791:[.22958,.72958,0,0,.77778],8796:[.08198,.91667,0,0,.77778],8806:[.25583,.75583,0,0,.77778],8807:[.25583,.75583,0,0,.77778],8808:[.25142,.75726,0,0,.77778],8809:[.25142,.75726,0,0,.77778],8812:[.25583,.75583,0,0,.5],8814:[.20576,.70576,0,0,.77778],8815:[.20576,.70576,0,0,.77778],8816:[.30274,.79383,0,0,.77778],8817:[.30274,.79383,0,0,.77778],8818:[.22958,.72958,0,0,.77778],8819:[.22958,.72958,0,0,.77778],8822:[.1808,.675,0,0,.77778],8823:[.1808,.675,0,0,.77778],8828:[.13667,.63667,0,0,.77778],8829:[.13667,.63667,0,0,.77778],8830:[.22958,.72958,0,0,.77778],8831:[.22958,.72958,0,0,.77778],8832:[.20576,.70576,0,0,.77778],8833:[.20576,.70576,0,0,.77778],8840:[.30274,.79383,0,0,.77778],8841:[.30274,.79383,0,0,.77778],8842:[.13597,.63597,0,0,.77778],8843:[.13597,.63597,0,0,.77778],8847:[.03517,.54986,0,0,.77778],8848:[.03517,.54986,0,0,.77778],8858:[.08198,.58198,0,0,.77778],8859:[.08198,.58198,0,0,.77778],8861:[.08198,.58198,0,0,.77778],8862:[0,.675,0,0,.77778],8863:[0,.675,0,0,.77778],8864:[0,.675,0,0,.77778],8865:[0,.675,0,0,.77778],8872:[0,.69224,0,0,.61111],8873:[0,.69224,0,0,.72222],8874:[0,.69224,0,0,.88889],8876:[0,.68889,0,0,.61111],8877:[0,.68889,0,0,.61111],8878:[0,.68889,0,0,.72222],8879:[0,.68889,0,0,.72222],8882:[.03517,.54986,0,0,.77778],8883:[.03517,.54986,0,0,.77778],8884:[.13667,.63667,0,0,.77778],8885:[.13667,.63667,0,0,.77778],8888:[0,.54986,0,0,1.11111],8890:[.19444,.43056,0,0,.55556],8891:[.19444,.69224,0,0,.61111],8892:[.19444,.69224,0,0,.61111],8901:[0,.54986,0,0,.27778],8903:[.08167,.58167,0,0,.77778],8905:[.08167,.58167,0,0,.77778],8906:[.08167,.58167,0,0,.77778],8907:[0,.69224,0,0,.77778],8908:[0,.69224,0,0,.77778],8909:[-.03598,.46402,0,0,.77778],8910:[0,.54986,0,0,.76042],8911:[0,.54986,0,0,.76042],8912:[.03517,.54986,0,0,.77778],8913:[.03517,.54986,0,0,.77778],8914:[0,.54986,0,0,.66667],8915:[0,.54986,0,0,.66667],8916:[0,.69224,0,0,.66667],8918:[.0391,.5391,0,0,.77778],8919:[.0391,.5391,0,0,.77778],8920:[.03517,.54986,0,0,1.33334],8921:[.03517,.54986,0,0,1.33334],8922:[.38569,.88569,0,0,.77778],8923:[.38569,.88569,0,0,.77778],8926:[.13667,.63667,0,0,.77778],8927:[.13667,.63667,0,0,.77778],8928:[.30274,.79383,0,0,.77778],8929:[.30274,.79383,0,0,.77778],8934:[.23222,.74111,0,0,.77778],8935:[.23222,.74111,0,0,.77778],8936:[.23222,.74111,0,0,.77778],8937:[.23222,.74111,0,0,.77778],8938:[.20576,.70576,0,0,.77778],8939:[.20576,.70576,0,0,.77778],8940:[.30274,.79383,0,0,.77778],8941:[.30274,.79383,0,0,.77778],8994:[.19444,.69224,0,0,.77778],8995:[.19444,.69224,0,0,.77778],9416:[.15559,.69224,0,0,.90222],9484:[0,.69224,0,0,.5],9488:[0,.69224,0,0,.5],9492:[0,.37788,0,0,.5],9496:[0,.37788,0,0,.5],9585:[.19444,.68889,0,0,.88889],9586:[.19444,.74111,0,0,.88889],9632:[0,.675,0,0,.77778],9633:[0,.675,0,0,.77778],9650:[0,.54986,0,0,.72222],9651:[0,.54986,0,0,.72222],9654:[.03517,.54986,0,0,.77778],9660:[0,.54986,0,0,.72222],9661:[0,.54986,0,0,.72222],9664:[.03517,.54986,0,0,.77778],9674:[.11111,.69224,0,0,.66667],9733:[.19444,.69224,0,0,.94445],10003:[0,.69224,0,0,.83334],10016:[0,.69224,0,0,.83334],10731:[.11111,.69224,0,0,.66667],10846:[.19444,.75583,0,0,.61111],10877:[.13667,.63667,0,0,.77778],10878:[.13667,.63667,0,0,.77778],10885:[.25583,.75583,0,0,.77778],10886:[.25583,.75583,0,0,.77778],10887:[.13597,.63597,0,0,.77778],10888:[.13597,.63597,0,0,.77778],10889:[.26167,.75726,0,0,.77778],10890:[.26167,.75726,0,0,.77778],10891:[.48256,.98256,0,0,.77778],10892:[.48256,.98256,0,0,.77778],10901:[.13667,.63667,0,0,.77778],10902:[.13667,.63667,0,0,.77778],10933:[.25142,.75726,0,0,.77778],10934:[.25142,.75726,0,0,.77778],10935:[.26167,.75726,0,0,.77778],10936:[.26167,.75726,0,0,.77778],10937:[.26167,.75726,0,0,.77778],10938:[.26167,.75726,0,0,.77778],10949:[.25583,.75583,0,0,.77778],10950:[.25583,.75583,0,0,.77778],10955:[.28481,.79383,0,0,.77778],10956:[.28481,.79383,0,0,.77778],57350:[.08167,.58167,0,0,.22222],57351:[.08167,.58167,0,0,.38889],57352:[.08167,.58167,0,0,.77778],57353:[0,.43056,.04028,0,.66667],57356:[.25142,.75726,0,0,.77778],57357:[.25142,.75726,0,0,.77778],57358:[.41951,.91951,0,0,.77778],57359:[.30274,.79383,0,0,.77778],57360:[.30274,.79383,0,0,.77778],57361:[.41951,.91951,0,0,.77778],57366:[.25142,.75726,0,0,.77778],57367:[.25142,.75726,0,0,.77778],57368:[.25142,.75726,0,0,.77778],57369:[.25142,.75726,0,0,.77778],57370:[.13597,.63597,0,0,.77778],57371:[.13597,.63597,0,0,.77778]},"Caligraphic-Regular":{32:[0,0,0,0,.25],65:[0,.68333,0,.19445,.79847],66:[0,.68333,.03041,.13889,.65681],67:[0,.68333,.05834,.13889,.52653],68:[0,.68333,.02778,.08334,.77139],69:[0,.68333,.08944,.11111,.52778],70:[0,.68333,.09931,.11111,.71875],71:[.09722,.68333,.0593,.11111,.59487],72:[0,.68333,.00965,.11111,.84452],73:[0,.68333,.07382,0,.54452],74:[.09722,.68333,.18472,.16667,.67778],75:[0,.68333,.01445,.05556,.76195],76:[0,.68333,0,.13889,.68972],77:[0,.68333,0,.13889,1.2009],78:[0,.68333,.14736,.08334,.82049],79:[0,.68333,.02778,.11111,.79611],80:[0,.68333,.08222,.08334,.69556],81:[.09722,.68333,0,.11111,.81667],82:[0,.68333,0,.08334,.8475],83:[0,.68333,.075,.13889,.60556],84:[0,.68333,.25417,0,.54464],85:[0,.68333,.09931,.08334,.62583],86:[0,.68333,.08222,0,.61278],87:[0,.68333,.08222,.08334,.98778],88:[0,.68333,.14643,.13889,.7133],89:[.09722,.68333,.08222,.08334,.66834],90:[0,.68333,.07944,.13889,.72473],160:[0,0,0,0,.25]},"Fraktur-Regular":{32:[0,0,0,0,.25],33:[0,.69141,0,0,.29574],34:[0,.69141,0,0,.21471],38:[0,.69141,0,0,.73786],39:[0,.69141,0,0,.21201],40:[.24982,.74947,0,0,.38865],41:[.24982,.74947,0,0,.38865],42:[0,.62119,0,0,.27764],43:[.08319,.58283,0,0,.75623],44:[0,.10803,0,0,.27764],45:[.08319,.58283,0,0,.75623],46:[0,.10803,0,0,.27764],47:[.24982,.74947,0,0,.50181],48:[0,.47534,0,0,.50181],49:[0,.47534,0,0,.50181],50:[0,.47534,0,0,.50181],51:[.18906,.47534,0,0,.50181],52:[.18906,.47534,0,0,.50181],53:[.18906,.47534,0,0,.50181],54:[0,.69141,0,0,.50181],55:[.18906,.47534,0,0,.50181],56:[0,.69141,0,0,.50181],57:[.18906,.47534,0,0,.50181],58:[0,.47534,0,0,.21606],59:[.12604,.47534,0,0,.21606],61:[-.13099,.36866,0,0,.75623],63:[0,.69141,0,0,.36245],65:[0,.69141,0,0,.7176],66:[0,.69141,0,0,.88397],67:[0,.69141,0,0,.61254],68:[0,.69141,0,0,.83158],69:[0,.69141,0,0,.66278],70:[.12604,.69141,0,0,.61119],71:[0,.69141,0,0,.78539],72:[.06302,.69141,0,0,.7203],73:[0,.69141,0,0,.55448],74:[.12604,.69141,0,0,.55231],75:[0,.69141,0,0,.66845],76:[0,.69141,0,0,.66602],77:[0,.69141,0,0,1.04953],78:[0,.69141,0,0,.83212],79:[0,.69141,0,0,.82699],80:[.18906,.69141,0,0,.82753],81:[.03781,.69141,0,0,.82699],82:[0,.69141,0,0,.82807],83:[0,.69141,0,0,.82861],84:[0,.69141,0,0,.66899],85:[0,.69141,0,0,.64576],86:[0,.69141,0,0,.83131],87:[0,.69141,0,0,1.04602],88:[0,.69141,0,0,.71922],89:[.18906,.69141,0,0,.83293],90:[.12604,.69141,0,0,.60201],91:[.24982,.74947,0,0,.27764],93:[.24982,.74947,0,0,.27764],94:[0,.69141,0,0,.49965],97:[0,.47534,0,0,.50046],98:[0,.69141,0,0,.51315],99:[0,.47534,0,0,.38946],100:[0,.62119,0,0,.49857],101:[0,.47534,0,0,.40053],102:[.18906,.69141,0,0,.32626],103:[.18906,.47534,0,0,.5037],104:[.18906,.69141,0,0,.52126],105:[0,.69141,0,0,.27899],106:[0,.69141,0,0,.28088],107:[0,.69141,0,0,.38946],108:[0,.69141,0,0,.27953],109:[0,.47534,0,0,.76676],110:[0,.47534,0,0,.52666],111:[0,.47534,0,0,.48885],112:[.18906,.52396,0,0,.50046],113:[.18906,.47534,0,0,.48912],114:[0,.47534,0,0,.38919],115:[0,.47534,0,0,.44266],116:[0,.62119,0,0,.33301],117:[0,.47534,0,0,.5172],118:[0,.52396,0,0,.5118],119:[0,.52396,0,0,.77351],120:[.18906,.47534,0,0,.38865],121:[.18906,.47534,0,0,.49884],122:[.18906,.47534,0,0,.39054],160:[0,0,0,0,.25],8216:[0,.69141,0,0,.21471],8217:[0,.69141,0,0,.21471],58112:[0,.62119,0,0,.49749],58113:[0,.62119,0,0,.4983],58114:[.18906,.69141,0,0,.33328],58115:[.18906,.69141,0,0,.32923],58116:[.18906,.47534,0,0,.50343],58117:[0,.69141,0,0,.33301],58118:[0,.62119,0,0,.33409],58119:[0,.47534,0,0,.50073]},"Main-Bold":{32:[0,0,0,0,.25],33:[0,.69444,0,0,.35],34:[0,.69444,0,0,.60278],35:[.19444,.69444,0,0,.95833],36:[.05556,.75,0,0,.575],37:[.05556,.75,0,0,.95833],38:[0,.69444,0,0,.89444],39:[0,.69444,0,0,.31944],40:[.25,.75,0,0,.44722],41:[.25,.75,0,0,.44722],42:[0,.75,0,0,.575],43:[.13333,.63333,0,0,.89444],44:[.19444,.15556,0,0,.31944],45:[0,.44444,0,0,.38333],46:[0,.15556,0,0,.31944],47:[.25,.75,0,0,.575],48:[0,.64444,0,0,.575],49:[0,.64444,0,0,.575],50:[0,.64444,0,0,.575],51:[0,.64444,0,0,.575],52:[0,.64444,0,0,.575],53:[0,.64444,0,0,.575],54:[0,.64444,0,0,.575],55:[0,.64444,0,0,.575],56:[0,.64444,0,0,.575],57:[0,.64444,0,0,.575],58:[0,.44444,0,0,.31944],59:[.19444,.44444,0,0,.31944],60:[.08556,.58556,0,0,.89444],61:[-.10889,.39111,0,0,.89444],62:[.08556,.58556,0,0,.89444],63:[0,.69444,0,0,.54305],64:[0,.69444,0,0,.89444],65:[0,.68611,0,0,.86944],66:[0,.68611,0,0,.81805],67:[0,.68611,0,0,.83055],68:[0,.68611,0,0,.88194],69:[0,.68611,0,0,.75555],70:[0,.68611,0,0,.72361],71:[0,.68611,0,0,.90416],72:[0,.68611,0,0,.9],73:[0,.68611,0,0,.43611],74:[0,.68611,0,0,.59444],75:[0,.68611,0,0,.90138],76:[0,.68611,0,0,.69166],77:[0,.68611,0,0,1.09166],78:[0,.68611,0,0,.9],79:[0,.68611,0,0,.86388],80:[0,.68611,0,0,.78611],81:[.19444,.68611,0,0,.86388],82:[0,.68611,0,0,.8625],83:[0,.68611,0,0,.63889],84:[0,.68611,0,0,.8],85:[0,.68611,0,0,.88472],86:[0,.68611,.01597,0,.86944],87:[0,.68611,.01597,0,1.18888],88:[0,.68611,0,0,.86944],89:[0,.68611,.02875,0,.86944],90:[0,.68611,0,0,.70277],91:[.25,.75,0,0,.31944],92:[.25,.75,0,0,.575],93:[.25,.75,0,0,.31944],94:[0,.69444,0,0,.575],95:[.31,.13444,.03194,0,.575],97:[0,.44444,0,0,.55902],98:[0,.69444,0,0,.63889],99:[0,.44444,0,0,.51111],100:[0,.69444,0,0,.63889],101:[0,.44444,0,0,.52708],102:[0,.69444,.10903,0,.35139],103:[.19444,.44444,.01597,0,.575],104:[0,.69444,0,0,.63889],105:[0,.69444,0,0,.31944],106:[.19444,.69444,0,0,.35139],107:[0,.69444,0,0,.60694],108:[0,.69444,0,0,.31944],109:[0,.44444,0,0,.95833],110:[0,.44444,0,0,.63889],111:[0,.44444,0,0,.575],112:[.19444,.44444,0,0,.63889],113:[.19444,.44444,0,0,.60694],114:[0,.44444,0,0,.47361],115:[0,.44444,0,0,.45361],116:[0,.63492,0,0,.44722],117:[0,.44444,0,0,.63889],118:[0,.44444,.01597,0,.60694],119:[0,.44444,.01597,0,.83055],120:[0,.44444,0,0,.60694],121:[.19444,.44444,.01597,0,.60694],122:[0,.44444,0,0,.51111],123:[.25,.75,0,0,.575],124:[.25,.75,0,0,.31944],125:[.25,.75,0,0,.575],126:[.35,.34444,0,0,.575],160:[0,0,0,0,.25],163:[0,.69444,0,0,.86853],168:[0,.69444,0,0,.575],172:[0,.44444,0,0,.76666],176:[0,.69444,0,0,.86944],177:[.13333,.63333,0,0,.89444],184:[.17014,0,0,0,.51111],198:[0,.68611,0,0,1.04166],215:[.13333,.63333,0,0,.89444],216:[.04861,.73472,0,0,.89444],223:[0,.69444,0,0,.59722],230:[0,.44444,0,0,.83055],247:[.13333,.63333,0,0,.89444],248:[.09722,.54167,0,0,.575],305:[0,.44444,0,0,.31944],338:[0,.68611,0,0,1.16944],339:[0,.44444,0,0,.89444],567:[.19444,.44444,0,0,.35139],710:[0,.69444,0,0,.575],711:[0,.63194,0,0,.575],713:[0,.59611,0,0,.575],714:[0,.69444,0,0,.575],715:[0,.69444,0,0,.575],728:[0,.69444,0,0,.575],729:[0,.69444,0,0,.31944],730:[0,.69444,0,0,.86944],732:[0,.69444,0,0,.575],733:[0,.69444,0,0,.575],915:[0,.68611,0,0,.69166],916:[0,.68611,0,0,.95833],920:[0,.68611,0,0,.89444],923:[0,.68611,0,0,.80555],926:[0,.68611,0,0,.76666],928:[0,.68611,0,0,.9],931:[0,.68611,0,0,.83055],933:[0,.68611,0,0,.89444],934:[0,.68611,0,0,.83055],936:[0,.68611,0,0,.89444],937:[0,.68611,0,0,.83055],8211:[0,.44444,.03194,0,.575],8212:[0,.44444,.03194,0,1.14999],8216:[0,.69444,0,0,.31944],8217:[0,.69444,0,0,.31944],8220:[0,.69444,0,0,.60278],8221:[0,.69444,0,0,.60278],8224:[.19444,.69444,0,0,.51111],8225:[.19444,.69444,0,0,.51111],8242:[0,.55556,0,0,.34444],8407:[0,.72444,.15486,0,.575],8463:[0,.69444,0,0,.66759],8465:[0,.69444,0,0,.83055],8467:[0,.69444,0,0,.47361],8472:[.19444,.44444,0,0,.74027],8476:[0,.69444,0,0,.83055],8501:[0,.69444,0,0,.70277],8592:[-.10889,.39111,0,0,1.14999],8593:[.19444,.69444,0,0,.575],8594:[-.10889,.39111,0,0,1.14999],8595:[.19444,.69444,0,0,.575],8596:[-.10889,.39111,0,0,1.14999],8597:[.25,.75,0,0,.575],8598:[.19444,.69444,0,0,1.14999],8599:[.19444,.69444,0,0,1.14999],8600:[.19444,.69444,0,0,1.14999],8601:[.19444,.69444,0,0,1.14999],8636:[-.10889,.39111,0,0,1.14999],8637:[-.10889,.39111,0,0,1.14999],8640:[-.10889,.39111,0,0,1.14999],8641:[-.10889,.39111,0,0,1.14999],8656:[-.10889,.39111,0,0,1.14999],8657:[.19444,.69444,0,0,.70277],8658:[-.10889,.39111,0,0,1.14999],8659:[.19444,.69444,0,0,.70277],8660:[-.10889,.39111,0,0,1.14999],8661:[.25,.75,0,0,.70277],8704:[0,.69444,0,0,.63889],8706:[0,.69444,.06389,0,.62847],8707:[0,.69444,0,0,.63889],8709:[.05556,.75,0,0,.575],8711:[0,.68611,0,0,.95833],8712:[.08556,.58556,0,0,.76666],8715:[.08556,.58556,0,0,.76666],8722:[.13333,.63333,0,0,.89444],8723:[.13333,.63333,0,0,.89444],8725:[.25,.75,0,0,.575],8726:[.25,.75,0,0,.575],8727:[-.02778,.47222,0,0,.575],8728:[-.02639,.47361,0,0,.575],8729:[-.02639,.47361,0,0,.575],8730:[.18,.82,0,0,.95833],8733:[0,.44444,0,0,.89444],8734:[0,.44444,0,0,1.14999],8736:[0,.69224,0,0,.72222],8739:[.25,.75,0,0,.31944],8741:[.25,.75,0,0,.575],8743:[0,.55556,0,0,.76666],8744:[0,.55556,0,0,.76666],8745:[0,.55556,0,0,.76666],8746:[0,.55556,0,0,.76666],8747:[.19444,.69444,.12778,0,.56875],8764:[-.10889,.39111,0,0,.89444],8768:[.19444,.69444,0,0,.31944],8771:[.00222,.50222,0,0,.89444],8773:[.027,.638,0,0,.894],8776:[.02444,.52444,0,0,.89444],8781:[.00222,.50222,0,0,.89444],8801:[.00222,.50222,0,0,.89444],8804:[.19667,.69667,0,0,.89444],8805:[.19667,.69667,0,0,.89444],8810:[.08556,.58556,0,0,1.14999],8811:[.08556,.58556,0,0,1.14999],8826:[.08556,.58556,0,0,.89444],8827:[.08556,.58556,0,0,.89444],8834:[.08556,.58556,0,0,.89444],8835:[.08556,.58556,0,0,.89444],8838:[.19667,.69667,0,0,.89444],8839:[.19667,.69667,0,0,.89444],8846:[0,.55556,0,0,.76666],8849:[.19667,.69667,0,0,.89444],8850:[.19667,.69667,0,0,.89444],8851:[0,.55556,0,0,.76666],8852:[0,.55556,0,0,.76666],8853:[.13333,.63333,0,0,.89444],8854:[.13333,.63333,0,0,.89444],8855:[.13333,.63333,0,0,.89444],8856:[.13333,.63333,0,0,.89444],8857:[.13333,.63333,0,0,.89444],8866:[0,.69444,0,0,.70277],8867:[0,.69444,0,0,.70277],8868:[0,.69444,0,0,.89444],8869:[0,.69444,0,0,.89444],8900:[-.02639,.47361,0,0,.575],8901:[-.02639,.47361,0,0,.31944],8902:[-.02778,.47222,0,0,.575],8968:[.25,.75,0,0,.51111],8969:[.25,.75,0,0,.51111],8970:[.25,.75,0,0,.51111],8971:[.25,.75,0,0,.51111],8994:[-.13889,.36111,0,0,1.14999],8995:[-.13889,.36111,0,0,1.14999],9651:[.19444,.69444,0,0,1.02222],9657:[-.02778,.47222,0,0,.575],9661:[.19444,.69444,0,0,1.02222],9667:[-.02778,.47222,0,0,.575],9711:[.19444,.69444,0,0,1.14999],9824:[.12963,.69444,0,0,.89444],9825:[.12963,.69444,0,0,.89444],9826:[.12963,.69444,0,0,.89444],9827:[.12963,.69444,0,0,.89444],9837:[0,.75,0,0,.44722],9838:[.19444,.69444,0,0,.44722],9839:[.19444,.69444,0,0,.44722],10216:[.25,.75,0,0,.44722],10217:[.25,.75,0,0,.44722],10815:[0,.68611,0,0,.9],10927:[.19667,.69667,0,0,.89444],10928:[.19667,.69667,0,0,.89444],57376:[.19444,.69444,0,0,0]},"Main-BoldItalic":{32:[0,0,0,0,.25],33:[0,.69444,.11417,0,.38611],34:[0,.69444,.07939,0,.62055],35:[.19444,.69444,.06833,0,.94444],37:[.05556,.75,.12861,0,.94444],38:[0,.69444,.08528,0,.88555],39:[0,.69444,.12945,0,.35555],40:[.25,.75,.15806,0,.47333],41:[.25,.75,.03306,0,.47333],42:[0,.75,.14333,0,.59111],43:[.10333,.60333,.03306,0,.88555],44:[.19444,.14722,0,0,.35555],45:[0,.44444,.02611,0,.41444],46:[0,.14722,0,0,.35555],47:[.25,.75,.15806,0,.59111],48:[0,.64444,.13167,0,.59111],49:[0,.64444,.13167,0,.59111],50:[0,.64444,.13167,0,.59111],51:[0,.64444,.13167,0,.59111],52:[.19444,.64444,.13167,0,.59111],53:[0,.64444,.13167,0,.59111],54:[0,.64444,.13167,0,.59111],55:[.19444,.64444,.13167,0,.59111],56:[0,.64444,.13167,0,.59111],57:[0,.64444,.13167,0,.59111],58:[0,.44444,.06695,0,.35555],59:[.19444,.44444,.06695,0,.35555],61:[-.10889,.39111,.06833,0,.88555],63:[0,.69444,.11472,0,.59111],64:[0,.69444,.09208,0,.88555],65:[0,.68611,0,0,.86555],66:[0,.68611,.0992,0,.81666],67:[0,.68611,.14208,0,.82666],68:[0,.68611,.09062,0,.87555],69:[0,.68611,.11431,0,.75666],70:[0,.68611,.12903,0,.72722],71:[0,.68611,.07347,0,.89527],72:[0,.68611,.17208,0,.8961],73:[0,.68611,.15681,0,.47166],74:[0,.68611,.145,0,.61055],75:[0,.68611,.14208,0,.89499],76:[0,.68611,0,0,.69777],77:[0,.68611,.17208,0,1.07277],78:[0,.68611,.17208,0,.8961],79:[0,.68611,.09062,0,.85499],80:[0,.68611,.0992,0,.78721],81:[.19444,.68611,.09062,0,.85499],82:[0,.68611,.02559,0,.85944],83:[0,.68611,.11264,0,.64999],84:[0,.68611,.12903,0,.7961],85:[0,.68611,.17208,0,.88083],86:[0,.68611,.18625,0,.86555],87:[0,.68611,.18625,0,1.15999],88:[0,.68611,.15681,0,.86555],89:[0,.68611,.19803,0,.86555],90:[0,.68611,.14208,0,.70888],91:[.25,.75,.1875,0,.35611],93:[.25,.75,.09972,0,.35611],94:[0,.69444,.06709,0,.59111],95:[.31,.13444,.09811,0,.59111],97:[0,.44444,.09426,0,.59111],98:[0,.69444,.07861,0,.53222],99:[0,.44444,.05222,0,.53222],100:[0,.69444,.10861,0,.59111],101:[0,.44444,.085,0,.53222],102:[.19444,.69444,.21778,0,.4],103:[.19444,.44444,.105,0,.53222],104:[0,.69444,.09426,0,.59111],105:[0,.69326,.11387,0,.35555],106:[.19444,.69326,.1672,0,.35555],107:[0,.69444,.11111,0,.53222],108:[0,.69444,.10861,0,.29666],109:[0,.44444,.09426,0,.94444],110:[0,.44444,.09426,0,.64999],111:[0,.44444,.07861,0,.59111],112:[.19444,.44444,.07861,0,.59111],113:[.19444,.44444,.105,0,.53222],114:[0,.44444,.11111,0,.50167],115:[0,.44444,.08167,0,.48694],116:[0,.63492,.09639,0,.385],117:[0,.44444,.09426,0,.62055],118:[0,.44444,.11111,0,.53222],119:[0,.44444,.11111,0,.76777],120:[0,.44444,.12583,0,.56055],121:[.19444,.44444,.105,0,.56166],122:[0,.44444,.13889,0,.49055],126:[.35,.34444,.11472,0,.59111],160:[0,0,0,0,.25],168:[0,.69444,.11473,0,.59111],176:[0,.69444,0,0,.94888],184:[.17014,0,0,0,.53222],198:[0,.68611,.11431,0,1.02277],216:[.04861,.73472,.09062,0,.88555],223:[.19444,.69444,.09736,0,.665],230:[0,.44444,.085,0,.82666],248:[.09722,.54167,.09458,0,.59111],305:[0,.44444,.09426,0,.35555],338:[0,.68611,.11431,0,1.14054],339:[0,.44444,.085,0,.82666],567:[.19444,.44444,.04611,0,.385],710:[0,.69444,.06709,0,.59111],711:[0,.63194,.08271,0,.59111],713:[0,.59444,.10444,0,.59111],714:[0,.69444,.08528,0,.59111],715:[0,.69444,0,0,.59111],728:[0,.69444,.10333,0,.59111],729:[0,.69444,.12945,0,.35555],730:[0,.69444,0,0,.94888],732:[0,.69444,.11472,0,.59111],733:[0,.69444,.11472,0,.59111],915:[0,.68611,.12903,0,.69777],916:[0,.68611,0,0,.94444],920:[0,.68611,.09062,0,.88555],923:[0,.68611,0,0,.80666],926:[0,.68611,.15092,0,.76777],928:[0,.68611,.17208,0,.8961],931:[0,.68611,.11431,0,.82666],933:[0,.68611,.10778,0,.88555],934:[0,.68611,.05632,0,.82666],936:[0,.68611,.10778,0,.88555],937:[0,.68611,.0992,0,.82666],8211:[0,.44444,.09811,0,.59111],8212:[0,.44444,.09811,0,1.18221],8216:[0,.69444,.12945,0,.35555],8217:[0,.69444,.12945,0,.35555],8220:[0,.69444,.16772,0,.62055],8221:[0,.69444,.07939,0,.62055]},"Main-Italic":{32:[0,0,0,0,.25],33:[0,.69444,.12417,0,.30667],34:[0,.69444,.06961,0,.51444],35:[.19444,.69444,.06616,0,.81777],37:[.05556,.75,.13639,0,.81777],38:[0,.69444,.09694,0,.76666],39:[0,.69444,.12417,0,.30667],40:[.25,.75,.16194,0,.40889],41:[.25,.75,.03694,0,.40889],42:[0,.75,.14917,0,.51111],43:[.05667,.56167,.03694,0,.76666],44:[.19444,.10556,0,0,.30667],45:[0,.43056,.02826,0,.35778],46:[0,.10556,0,0,.30667],47:[.25,.75,.16194,0,.51111],48:[0,.64444,.13556,0,.51111],49:[0,.64444,.13556,0,.51111],50:[0,.64444,.13556,0,.51111],51:[0,.64444,.13556,0,.51111],52:[.19444,.64444,.13556,0,.51111],53:[0,.64444,.13556,0,.51111],54:[0,.64444,.13556,0,.51111],55:[.19444,.64444,.13556,0,.51111],56:[0,.64444,.13556,0,.51111],57:[0,.64444,.13556,0,.51111],58:[0,.43056,.0582,0,.30667],59:[.19444,.43056,.0582,0,.30667],61:[-.13313,.36687,.06616,0,.76666],63:[0,.69444,.1225,0,.51111],64:[0,.69444,.09597,0,.76666],65:[0,.68333,0,0,.74333],66:[0,.68333,.10257,0,.70389],67:[0,.68333,.14528,0,.71555],68:[0,.68333,.09403,0,.755],69:[0,.68333,.12028,0,.67833],70:[0,.68333,.13305,0,.65277],71:[0,.68333,.08722,0,.77361],72:[0,.68333,.16389,0,.74333],73:[0,.68333,.15806,0,.38555],74:[0,.68333,.14028,0,.525],75:[0,.68333,.14528,0,.76888],76:[0,.68333,0,0,.62722],77:[0,.68333,.16389,0,.89666],78:[0,.68333,.16389,0,.74333],79:[0,.68333,.09403,0,.76666],80:[0,.68333,.10257,0,.67833],81:[.19444,.68333,.09403,0,.76666],82:[0,.68333,.03868,0,.72944],83:[0,.68333,.11972,0,.56222],84:[0,.68333,.13305,0,.71555],85:[0,.68333,.16389,0,.74333],86:[0,.68333,.18361,0,.74333],87:[0,.68333,.18361,0,.99888],88:[0,.68333,.15806,0,.74333],89:[0,.68333,.19383,0,.74333],90:[0,.68333,.14528,0,.61333],91:[.25,.75,.1875,0,.30667],93:[.25,.75,.10528,0,.30667],94:[0,.69444,.06646,0,.51111],95:[.31,.12056,.09208,0,.51111],97:[0,.43056,.07671,0,.51111],98:[0,.69444,.06312,0,.46],99:[0,.43056,.05653,0,.46],100:[0,.69444,.10333,0,.51111],101:[0,.43056,.07514,0,.46],102:[.19444,.69444,.21194,0,.30667],103:[.19444,.43056,.08847,0,.46],104:[0,.69444,.07671,0,.51111],105:[0,.65536,.1019,0,.30667],106:[.19444,.65536,.14467,0,.30667],107:[0,.69444,.10764,0,.46],108:[0,.69444,.10333,0,.25555],109:[0,.43056,.07671,0,.81777],110:[0,.43056,.07671,0,.56222],111:[0,.43056,.06312,0,.51111],112:[.19444,.43056,.06312,0,.51111],113:[.19444,.43056,.08847,0,.46],114:[0,.43056,.10764,0,.42166],115:[0,.43056,.08208,0,.40889],116:[0,.61508,.09486,0,.33222],117:[0,.43056,.07671,0,.53666],118:[0,.43056,.10764,0,.46],119:[0,.43056,.10764,0,.66444],120:[0,.43056,.12042,0,.46389],121:[.19444,.43056,.08847,0,.48555],122:[0,.43056,.12292,0,.40889],126:[.35,.31786,.11585,0,.51111],160:[0,0,0,0,.25],168:[0,.66786,.10474,0,.51111],176:[0,.69444,0,0,.83129],184:[.17014,0,0,0,.46],198:[0,.68333,.12028,0,.88277],216:[.04861,.73194,.09403,0,.76666],223:[.19444,.69444,.10514,0,.53666],230:[0,.43056,.07514,0,.71555],248:[.09722,.52778,.09194,0,.51111],338:[0,.68333,.12028,0,.98499],339:[0,.43056,.07514,0,.71555],710:[0,.69444,.06646,0,.51111],711:[0,.62847,.08295,0,.51111],713:[0,.56167,.10333,0,.51111],714:[0,.69444,.09694,0,.51111],715:[0,.69444,0,0,.51111],728:[0,.69444,.10806,0,.51111],729:[0,.66786,.11752,0,.30667],730:[0,.69444,0,0,.83129],732:[0,.66786,.11585,0,.51111],733:[0,.69444,.1225,0,.51111],915:[0,.68333,.13305,0,.62722],916:[0,.68333,0,0,.81777],920:[0,.68333,.09403,0,.76666],923:[0,.68333,0,0,.69222],926:[0,.68333,.15294,0,.66444],928:[0,.68333,.16389,0,.74333],931:[0,.68333,.12028,0,.71555],933:[0,.68333,.11111,0,.76666],934:[0,.68333,.05986,0,.71555],936:[0,.68333,.11111,0,.76666],937:[0,.68333,.10257,0,.71555],8211:[0,.43056,.09208,0,.51111],8212:[0,.43056,.09208,0,1.02222],8216:[0,.69444,.12417,0,.30667],8217:[0,.69444,.12417,0,.30667],8220:[0,.69444,.1685,0,.51444],8221:[0,.69444,.06961,0,.51444],8463:[0,.68889,0,0,.54028]},"Main-Regular":{32:[0,0,0,0,.25],33:[0,.69444,0,0,.27778],34:[0,.69444,0,0,.5],35:[.19444,.69444,0,0,.83334],36:[.05556,.75,0,0,.5],37:[.05556,.75,0,0,.83334],38:[0,.69444,0,0,.77778],39:[0,.69444,0,0,.27778],40:[.25,.75,0,0,.38889],41:[.25,.75,0,0,.38889],42:[0,.75,0,0,.5],43:[.08333,.58333,0,0,.77778],44:[.19444,.10556,0,0,.27778],45:[0,.43056,0,0,.33333],46:[0,.10556,0,0,.27778],47:[.25,.75,0,0,.5],48:[0,.64444,0,0,.5],49:[0,.64444,0,0,.5],50:[0,.64444,0,0,.5],51:[0,.64444,0,0,.5],52:[0,.64444,0,0,.5],53:[0,.64444,0,0,.5],54:[0,.64444,0,0,.5],55:[0,.64444,0,0,.5],56:[0,.64444,0,0,.5],57:[0,.64444,0,0,.5],58:[0,.43056,0,0,.27778],59:[.19444,.43056,0,0,.27778],60:[.0391,.5391,0,0,.77778],61:[-.13313,.36687,0,0,.77778],62:[.0391,.5391,0,0,.77778],63:[0,.69444,0,0,.47222],64:[0,.69444,0,0,.77778],65:[0,.68333,0,0,.75],66:[0,.68333,0,0,.70834],67:[0,.68333,0,0,.72222],68:[0,.68333,0,0,.76389],69:[0,.68333,0,0,.68056],70:[0,.68333,0,0,.65278],71:[0,.68333,0,0,.78472],72:[0,.68333,0,0,.75],73:[0,.68333,0,0,.36111],74:[0,.68333,0,0,.51389],75:[0,.68333,0,0,.77778],76:[0,.68333,0,0,.625],77:[0,.68333,0,0,.91667],78:[0,.68333,0,0,.75],79:[0,.68333,0,0,.77778],80:[0,.68333,0,0,.68056],81:[.19444,.68333,0,0,.77778],82:[0,.68333,0,0,.73611],83:[0,.68333,0,0,.55556],84:[0,.68333,0,0,.72222],85:[0,.68333,0,0,.75],86:[0,.68333,.01389,0,.75],87:[0,.68333,.01389,0,1.02778],88:[0,.68333,0,0,.75],89:[0,.68333,.025,0,.75],90:[0,.68333,0,0,.61111],91:[.25,.75,0,0,.27778],92:[.25,.75,0,0,.5],93:[.25,.75,0,0,.27778],94:[0,.69444,0,0,.5],95:[.31,.12056,.02778,0,.5],97:[0,.43056,0,0,.5],98:[0,.69444,0,0,.55556],99:[0,.43056,0,0,.44445],100:[0,.69444,0,0,.55556],101:[0,.43056,0,0,.44445],102:[0,.69444,.07778,0,.30556],103:[.19444,.43056,.01389,0,.5],104:[0,.69444,0,0,.55556],105:[0,.66786,0,0,.27778],106:[.19444,.66786,0,0,.30556],107:[0,.69444,0,0,.52778],108:[0,.69444,0,0,.27778],109:[0,.43056,0,0,.83334],110:[0,.43056,0,0,.55556],111:[0,.43056,0,0,.5],112:[.19444,.43056,0,0,.55556],113:[.19444,.43056,0,0,.52778],114:[0,.43056,0,0,.39167],115:[0,.43056,0,0,.39445],116:[0,.61508,0,0,.38889],117:[0,.43056,0,0,.55556],118:[0,.43056,.01389,0,.52778],119:[0,.43056,.01389,0,.72222],120:[0,.43056,0,0,.52778],121:[.19444,.43056,.01389,0,.52778],122:[0,.43056,0,0,.44445],123:[.25,.75,0,0,.5],124:[.25,.75,0,0,.27778],125:[.25,.75,0,0,.5],126:[.35,.31786,0,0,.5],160:[0,0,0,0,.25],163:[0,.69444,0,0,.76909],167:[.19444,.69444,0,0,.44445],168:[0,.66786,0,0,.5],172:[0,.43056,0,0,.66667],176:[0,.69444,0,0,.75],177:[.08333,.58333,0,0,.77778],182:[.19444,.69444,0,0,.61111],184:[.17014,0,0,0,.44445],198:[0,.68333,0,0,.90278],215:[.08333,.58333,0,0,.77778],216:[.04861,.73194,0,0,.77778],223:[0,.69444,0,0,.5],230:[0,.43056,0,0,.72222],247:[.08333,.58333,0,0,.77778],248:[.09722,.52778,0,0,.5],305:[0,.43056,0,0,.27778],338:[0,.68333,0,0,1.01389],339:[0,.43056,0,0,.77778],567:[.19444,.43056,0,0,.30556],710:[0,.69444,0,0,.5],711:[0,.62847,0,0,.5],713:[0,.56778,0,0,.5],714:[0,.69444,0,0,.5],715:[0,.69444,0,0,.5],728:[0,.69444,0,0,.5],729:[0,.66786,0,0,.27778],730:[0,.69444,0,0,.75],732:[0,.66786,0,0,.5],733:[0,.69444,0,0,.5],915:[0,.68333,0,0,.625],916:[0,.68333,0,0,.83334],920:[0,.68333,0,0,.77778],923:[0,.68333,0,0,.69445],926:[0,.68333,0,0,.66667],928:[0,.68333,0,0,.75],931:[0,.68333,0,0,.72222],933:[0,.68333,0,0,.77778],934:[0,.68333,0,0,.72222],936:[0,.68333,0,0,.77778],937:[0,.68333,0,0,.72222],8211:[0,.43056,.02778,0,.5],8212:[0,.43056,.02778,0,1],8216:[0,.69444,0,0,.27778],8217:[0,.69444,0,0,.27778],8220:[0,.69444,0,0,.5],8221:[0,.69444,0,0,.5],8224:[.19444,.69444,0,0,.44445],8225:[.19444,.69444,0,0,.44445],8230:[0,.123,0,0,1.172],8242:[0,.55556,0,0,.275],8407:[0,.71444,.15382,0,.5],8463:[0,.68889,0,0,.54028],8465:[0,.69444,0,0,.72222],8467:[0,.69444,0,.11111,.41667],8472:[.19444,.43056,0,.11111,.63646],8476:[0,.69444,0,0,.72222],8501:[0,.69444,0,0,.61111],8592:[-.13313,.36687,0,0,1],8593:[.19444,.69444,0,0,.5],8594:[-.13313,.36687,0,0,1],8595:[.19444,.69444,0,0,.5],8596:[-.13313,.36687,0,0,1],8597:[.25,.75,0,0,.5],8598:[.19444,.69444,0,0,1],8599:[.19444,.69444,0,0,1],8600:[.19444,.69444,0,0,1],8601:[.19444,.69444,0,0,1],8614:[.011,.511,0,0,1],8617:[.011,.511,0,0,1.126],8618:[.011,.511,0,0,1.126],8636:[-.13313,.36687,0,0,1],8637:[-.13313,.36687,0,0,1],8640:[-.13313,.36687,0,0,1],8641:[-.13313,.36687,0,0,1],8652:[.011,.671,0,0,1],8656:[-.13313,.36687,0,0,1],8657:[.19444,.69444,0,0,.61111],8658:[-.13313,.36687,0,0,1],8659:[.19444,.69444,0,0,.61111],8660:[-.13313,.36687,0,0,1],8661:[.25,.75,0,0,.61111],8704:[0,.69444,0,0,.55556],8706:[0,.69444,.05556,.08334,.5309],8707:[0,.69444,0,0,.55556],8709:[.05556,.75,0,0,.5],8711:[0,.68333,0,0,.83334],8712:[.0391,.5391,0,0,.66667],8715:[.0391,.5391,0,0,.66667],8722:[.08333,.58333,0,0,.77778],8723:[.08333,.58333,0,0,.77778],8725:[.25,.75,0,0,.5],8726:[.25,.75,0,0,.5],8727:[-.03472,.46528,0,0,.5],8728:[-.05555,.44445,0,0,.5],8729:[-.05555,.44445,0,0,.5],8730:[.2,.8,0,0,.83334],8733:[0,.43056,0,0,.77778],8734:[0,.43056,0,0,1],8736:[0,.69224,0,0,.72222],8739:[.25,.75,0,0,.27778],8741:[.25,.75,0,0,.5],8743:[0,.55556,0,0,.66667],8744:[0,.55556,0,0,.66667],8745:[0,.55556,0,0,.66667],8746:[0,.55556,0,0,.66667],8747:[.19444,.69444,.11111,0,.41667],8764:[-.13313,.36687,0,0,.77778],8768:[.19444,.69444,0,0,.27778],8771:[-.03625,.46375,0,0,.77778],8773:[-.022,.589,0,0,.778],8776:[-.01688,.48312,0,0,.77778],8781:[-.03625,.46375,0,0,.77778],8784:[-.133,.673,0,0,.778],8801:[-.03625,.46375,0,0,.77778],8804:[.13597,.63597,0,0,.77778],8805:[.13597,.63597,0,0,.77778],8810:[.0391,.5391,0,0,1],8811:[.0391,.5391,0,0,1],8826:[.0391,.5391,0,0,.77778],8827:[.0391,.5391,0,0,.77778],8834:[.0391,.5391,0,0,.77778],8835:[.0391,.5391,0,0,.77778],8838:[.13597,.63597,0,0,.77778],8839:[.13597,.63597,0,0,.77778],8846:[0,.55556,0,0,.66667],8849:[.13597,.63597,0,0,.77778],8850:[.13597,.63597,0,0,.77778],8851:[0,.55556,0,0,.66667],8852:[0,.55556,0,0,.66667],8853:[.08333,.58333,0,0,.77778],8854:[.08333,.58333,0,0,.77778],8855:[.08333,.58333,0,0,.77778],8856:[.08333,.58333,0,0,.77778],8857:[.08333,.58333,0,0,.77778],8866:[0,.69444,0,0,.61111],8867:[0,.69444,0,0,.61111],8868:[0,.69444,0,0,.77778],8869:[0,.69444,0,0,.77778],8872:[.249,.75,0,0,.867],8900:[-.05555,.44445,0,0,.5],8901:[-.05555,.44445,0,0,.27778],8902:[-.03472,.46528,0,0,.5],8904:[.005,.505,0,0,.9],8942:[.03,.903,0,0,.278],8943:[-.19,.313,0,0,1.172],8945:[-.1,.823,0,0,1.282],8968:[.25,.75,0,0,.44445],8969:[.25,.75,0,0,.44445],8970:[.25,.75,0,0,.44445],8971:[.25,.75,0,0,.44445],8994:[-.14236,.35764,0,0,1],8995:[-.14236,.35764,0,0,1],9136:[.244,.744,0,0,.412],9137:[.244,.745,0,0,.412],9651:[.19444,.69444,0,0,.88889],9657:[-.03472,.46528,0,0,.5],9661:[.19444,.69444,0,0,.88889],9667:[-.03472,.46528,0,0,.5],9711:[.19444,.69444,0,0,1],9824:[.12963,.69444,0,0,.77778],9825:[.12963,.69444,0,0,.77778],9826:[.12963,.69444,0,0,.77778],9827:[.12963,.69444,0,0,.77778],9837:[0,.75,0,0,.38889],9838:[.19444,.69444,0,0,.38889],9839:[.19444,.69444,0,0,.38889],10216:[.25,.75,0,0,.38889],10217:[.25,.75,0,0,.38889],10222:[.244,.744,0,0,.412],10223:[.244,.745,0,0,.412],10229:[.011,.511,0,0,1.609],10230:[.011,.511,0,0,1.638],10231:[.011,.511,0,0,1.859],10232:[.024,.525,0,0,1.609],10233:[.024,.525,0,0,1.638],10234:[.024,.525,0,0,1.858],10236:[.011,.511,0,0,1.638],10815:[0,.68333,0,0,.75],10927:[.13597,.63597,0,0,.77778],10928:[.13597,.63597,0,0,.77778],57376:[.19444,.69444,0,0,0]},"Math-BoldItalic":{32:[0,0,0,0,.25],48:[0,.44444,0,0,.575],49:[0,.44444,0,0,.575],50:[0,.44444,0,0,.575],51:[.19444,.44444,0,0,.575],52:[.19444,.44444,0,0,.575],53:[.19444,.44444,0,0,.575],54:[0,.64444,0,0,.575],55:[.19444,.44444,0,0,.575],56:[0,.64444,0,0,.575],57:[.19444,.44444,0,0,.575],65:[0,.68611,0,0,.86944],66:[0,.68611,.04835,0,.8664],67:[0,.68611,.06979,0,.81694],68:[0,.68611,.03194,0,.93812],69:[0,.68611,.05451,0,.81007],70:[0,.68611,.15972,0,.68889],71:[0,.68611,0,0,.88673],72:[0,.68611,.08229,0,.98229],73:[0,.68611,.07778,0,.51111],74:[0,.68611,.10069,0,.63125],75:[0,.68611,.06979,0,.97118],76:[0,.68611,0,0,.75555],77:[0,.68611,.11424,0,1.14201],78:[0,.68611,.11424,0,.95034],79:[0,.68611,.03194,0,.83666],80:[0,.68611,.15972,0,.72309],81:[.19444,.68611,0,0,.86861],82:[0,.68611,.00421,0,.87235],83:[0,.68611,.05382,0,.69271],84:[0,.68611,.15972,0,.63663],85:[0,.68611,.11424,0,.80027],86:[0,.68611,.25555,0,.67778],87:[0,.68611,.15972,0,1.09305],88:[0,.68611,.07778,0,.94722],89:[0,.68611,.25555,0,.67458],90:[0,.68611,.06979,0,.77257],97:[0,.44444,0,0,.63287],98:[0,.69444,0,0,.52083],99:[0,.44444,0,0,.51342],100:[0,.69444,0,0,.60972],101:[0,.44444,0,0,.55361],102:[.19444,.69444,.11042,0,.56806],103:[.19444,.44444,.03704,0,.5449],104:[0,.69444,0,0,.66759],105:[0,.69326,0,0,.4048],106:[.19444,.69326,.0622,0,.47083],107:[0,.69444,.01852,0,.6037],108:[0,.69444,.0088,0,.34815],109:[0,.44444,0,0,1.0324],110:[0,.44444,0,0,.71296],111:[0,.44444,0,0,.58472],112:[.19444,.44444,0,0,.60092],113:[.19444,.44444,.03704,0,.54213],114:[0,.44444,.03194,0,.5287],115:[0,.44444,0,0,.53125],116:[0,.63492,0,0,.41528],117:[0,.44444,0,0,.68102],118:[0,.44444,.03704,0,.56666],119:[0,.44444,.02778,0,.83148],120:[0,.44444,0,0,.65903],121:[.19444,.44444,.03704,0,.59028],122:[0,.44444,.04213,0,.55509],160:[0,0,0,0,.25],915:[0,.68611,.15972,0,.65694],916:[0,.68611,0,0,.95833],920:[0,.68611,.03194,0,.86722],923:[0,.68611,0,0,.80555],926:[0,.68611,.07458,0,.84125],928:[0,.68611,.08229,0,.98229],931:[0,.68611,.05451,0,.88507],933:[0,.68611,.15972,0,.67083],934:[0,.68611,0,0,.76666],936:[0,.68611,.11653,0,.71402],937:[0,.68611,.04835,0,.8789],945:[0,.44444,0,0,.76064],946:[.19444,.69444,.03403,0,.65972],947:[.19444,.44444,.06389,0,.59003],948:[0,.69444,.03819,0,.52222],949:[0,.44444,0,0,.52882],950:[.19444,.69444,.06215,0,.50833],951:[.19444,.44444,.03704,0,.6],952:[0,.69444,.03194,0,.5618],953:[0,.44444,0,0,.41204],954:[0,.44444,0,0,.66759],955:[0,.69444,0,0,.67083],956:[.19444,.44444,0,0,.70787],957:[0,.44444,.06898,0,.57685],958:[.19444,.69444,.03021,0,.50833],959:[0,.44444,0,0,.58472],960:[0,.44444,.03704,0,.68241],961:[.19444,.44444,0,0,.6118],962:[.09722,.44444,.07917,0,.42361],963:[0,.44444,.03704,0,.68588],964:[0,.44444,.13472,0,.52083],965:[0,.44444,.03704,0,.63055],966:[.19444,.44444,0,0,.74722],967:[.19444,.44444,0,0,.71805],968:[.19444,.69444,.03704,0,.75833],969:[0,.44444,.03704,0,.71782],977:[0,.69444,0,0,.69155],981:[.19444,.69444,0,0,.7125],982:[0,.44444,.03194,0,.975],1009:[.19444,.44444,0,0,.6118],1013:[0,.44444,0,0,.48333],57649:[0,.44444,0,0,.39352],57911:[.19444,.44444,0,0,.43889]},"Math-Italic":{32:[0,0,0,0,.25],48:[0,.43056,0,0,.5],49:[0,.43056,0,0,.5],50:[0,.43056,0,0,.5],51:[.19444,.43056,0,0,.5],52:[.19444,.43056,0,0,.5],53:[.19444,.43056,0,0,.5],54:[0,.64444,0,0,.5],55:[.19444,.43056,0,0,.5],56:[0,.64444,0,0,.5],57:[.19444,.43056,0,0,.5],65:[0,.68333,0,.13889,.75],66:[0,.68333,.05017,.08334,.75851],67:[0,.68333,.07153,.08334,.71472],68:[0,.68333,.02778,.05556,.82792],69:[0,.68333,.05764,.08334,.7382],70:[0,.68333,.13889,.08334,.64306],71:[0,.68333,0,.08334,.78625],72:[0,.68333,.08125,.05556,.83125],73:[0,.68333,.07847,.11111,.43958],74:[0,.68333,.09618,.16667,.55451],75:[0,.68333,.07153,.05556,.84931],76:[0,.68333,0,.02778,.68056],77:[0,.68333,.10903,.08334,.97014],78:[0,.68333,.10903,.08334,.80347],79:[0,.68333,.02778,.08334,.76278],80:[0,.68333,.13889,.08334,.64201],81:[.19444,.68333,0,.08334,.79056],82:[0,.68333,.00773,.08334,.75929],83:[0,.68333,.05764,.08334,.6132],84:[0,.68333,.13889,.08334,.58438],85:[0,.68333,.10903,.02778,.68278],86:[0,.68333,.22222,0,.58333],87:[0,.68333,.13889,0,.94445],88:[0,.68333,.07847,.08334,.82847],89:[0,.68333,.22222,0,.58056],90:[0,.68333,.07153,.08334,.68264],97:[0,.43056,0,0,.52859],98:[0,.69444,0,0,.42917],99:[0,.43056,0,.05556,.43276],100:[0,.69444,0,.16667,.52049],101:[0,.43056,0,.05556,.46563],102:[.19444,.69444,.10764,.16667,.48959],103:[.19444,.43056,.03588,.02778,.47697],104:[0,.69444,0,0,.57616],105:[0,.65952,0,0,.34451],106:[.19444,.65952,.05724,0,.41181],107:[0,.69444,.03148,0,.5206],108:[0,.69444,.01968,.08334,.29838],109:[0,.43056,0,0,.87801],110:[0,.43056,0,0,.60023],111:[0,.43056,0,.05556,.48472],112:[.19444,.43056,0,.08334,.50313],113:[.19444,.43056,.03588,.08334,.44641],114:[0,.43056,.02778,.05556,.45116],115:[0,.43056,0,.05556,.46875],116:[0,.61508,0,.08334,.36111],117:[0,.43056,0,.02778,.57246],118:[0,.43056,.03588,.02778,.48472],119:[0,.43056,.02691,.08334,.71592],120:[0,.43056,0,.02778,.57153],121:[.19444,.43056,.03588,.05556,.49028],122:[0,.43056,.04398,.05556,.46505],160:[0,0,0,0,.25],915:[0,.68333,.13889,.08334,.61528],916:[0,.68333,0,.16667,.83334],920:[0,.68333,.02778,.08334,.76278],923:[0,.68333,0,.16667,.69445],926:[0,.68333,.07569,.08334,.74236],928:[0,.68333,.08125,.05556,.83125],931:[0,.68333,.05764,.08334,.77986],933:[0,.68333,.13889,.05556,.58333],934:[0,.68333,0,.08334,.66667],936:[0,.68333,.11,.05556,.61222],937:[0,.68333,.05017,.08334,.7724],945:[0,.43056,.0037,.02778,.6397],946:[.19444,.69444,.05278,.08334,.56563],947:[.19444,.43056,.05556,0,.51773],948:[0,.69444,.03785,.05556,.44444],949:[0,.43056,0,.08334,.46632],950:[.19444,.69444,.07378,.08334,.4375],951:[.19444,.43056,.03588,.05556,.49653],952:[0,.69444,.02778,.08334,.46944],953:[0,.43056,0,.05556,.35394],954:[0,.43056,0,0,.57616],955:[0,.69444,0,0,.58334],956:[.19444,.43056,0,.02778,.60255],957:[0,.43056,.06366,.02778,.49398],958:[.19444,.69444,.04601,.11111,.4375],959:[0,.43056,0,.05556,.48472],960:[0,.43056,.03588,0,.57003],961:[.19444,.43056,0,.08334,.51702],962:[.09722,.43056,.07986,.08334,.36285],963:[0,.43056,.03588,0,.57141],964:[0,.43056,.1132,.02778,.43715],965:[0,.43056,.03588,.02778,.54028],966:[.19444,.43056,0,.08334,.65417],967:[.19444,.43056,0,.05556,.62569],968:[.19444,.69444,.03588,.11111,.65139],969:[0,.43056,.03588,0,.62245],977:[0,.69444,0,.08334,.59144],981:[.19444,.69444,0,.08334,.59583],982:[0,.43056,.02778,0,.82813],1009:[.19444,.43056,0,.08334,.51702],1013:[0,.43056,0,.05556,.4059],57649:[0,.43056,0,.02778,.32246],57911:[.19444,.43056,0,.08334,.38403]},"SansSerif-Bold":{32:[0,0,0,0,.25],33:[0,.69444,0,0,.36667],34:[0,.69444,0,0,.55834],35:[.19444,.69444,0,0,.91667],36:[.05556,.75,0,0,.55],37:[.05556,.75,0,0,1.02912],38:[0,.69444,0,0,.83056],39:[0,.69444,0,0,.30556],40:[.25,.75,0,0,.42778],41:[.25,.75,0,0,.42778],42:[0,.75,0,0,.55],43:[.11667,.61667,0,0,.85556],44:[.10556,.13056,0,0,.30556],45:[0,.45833,0,0,.36667],46:[0,.13056,0,0,.30556],47:[.25,.75,0,0,.55],48:[0,.69444,0,0,.55],49:[0,.69444,0,0,.55],50:[0,.69444,0,0,.55],51:[0,.69444,0,0,.55],52:[0,.69444,0,0,.55],53:[0,.69444,0,0,.55],54:[0,.69444,0,0,.55],55:[0,.69444,0,0,.55],56:[0,.69444,0,0,.55],57:[0,.69444,0,0,.55],58:[0,.45833,0,0,.30556],59:[.10556,.45833,0,0,.30556],61:[-.09375,.40625,0,0,.85556],63:[0,.69444,0,0,.51945],64:[0,.69444,0,0,.73334],65:[0,.69444,0,0,.73334],66:[0,.69444,0,0,.73334],67:[0,.69444,0,0,.70278],68:[0,.69444,0,0,.79445],69:[0,.69444,0,0,.64167],70:[0,.69444,0,0,.61111],71:[0,.69444,0,0,.73334],72:[0,.69444,0,0,.79445],73:[0,.69444,0,0,.33056],74:[0,.69444,0,0,.51945],75:[0,.69444,0,0,.76389],76:[0,.69444,0,0,.58056],77:[0,.69444,0,0,.97778],78:[0,.69444,0,0,.79445],79:[0,.69444,0,0,.79445],80:[0,.69444,0,0,.70278],81:[.10556,.69444,0,0,.79445],82:[0,.69444,0,0,.70278],83:[0,.69444,0,0,.61111],84:[0,.69444,0,0,.73334],85:[0,.69444,0,0,.76389],86:[0,.69444,.01528,0,.73334],87:[0,.69444,.01528,0,1.03889],88:[0,.69444,0,0,.73334],89:[0,.69444,.0275,0,.73334],90:[0,.69444,0,0,.67223],91:[.25,.75,0,0,.34306],93:[.25,.75,0,0,.34306],94:[0,.69444,0,0,.55],95:[.35,.10833,.03056,0,.55],97:[0,.45833,0,0,.525],98:[0,.69444,0,0,.56111],99:[0,.45833,0,0,.48889],100:[0,.69444,0,0,.56111],101:[0,.45833,0,0,.51111],102:[0,.69444,.07639,0,.33611],103:[.19444,.45833,.01528,0,.55],104:[0,.69444,0,0,.56111],105:[0,.69444,0,0,.25556],106:[.19444,.69444,0,0,.28611],107:[0,.69444,0,0,.53056],108:[0,.69444,0,0,.25556],109:[0,.45833,0,0,.86667],110:[0,.45833,0,0,.56111],111:[0,.45833,0,0,.55],112:[.19444,.45833,0,0,.56111],113:[.19444,.45833,0,0,.56111],114:[0,.45833,.01528,0,.37222],115:[0,.45833,0,0,.42167],116:[0,.58929,0,0,.40417],117:[0,.45833,0,0,.56111],118:[0,.45833,.01528,0,.5],119:[0,.45833,.01528,0,.74445],120:[0,.45833,0,0,.5],121:[.19444,.45833,.01528,0,.5],122:[0,.45833,0,0,.47639],126:[.35,.34444,0,0,.55],160:[0,0,0,0,.25],168:[0,.69444,0,0,.55],176:[0,.69444,0,0,.73334],180:[0,.69444,0,0,.55],184:[.17014,0,0,0,.48889],305:[0,.45833,0,0,.25556],567:[.19444,.45833,0,0,.28611],710:[0,.69444,0,0,.55],711:[0,.63542,0,0,.55],713:[0,.63778,0,0,.55],728:[0,.69444,0,0,.55],729:[0,.69444,0,0,.30556],730:[0,.69444,0,0,.73334],732:[0,.69444,0,0,.55],733:[0,.69444,0,0,.55],915:[0,.69444,0,0,.58056],916:[0,.69444,0,0,.91667],920:[0,.69444,0,0,.85556],923:[0,.69444,0,0,.67223],926:[0,.69444,0,0,.73334],928:[0,.69444,0,0,.79445],931:[0,.69444,0,0,.79445],933:[0,.69444,0,0,.85556],934:[0,.69444,0,0,.79445],936:[0,.69444,0,0,.85556],937:[0,.69444,0,0,.79445],8211:[0,.45833,.03056,0,.55],8212:[0,.45833,.03056,0,1.10001],8216:[0,.69444,0,0,.30556],8217:[0,.69444,0,0,.30556],8220:[0,.69444,0,0,.55834],8221:[0,.69444,0,0,.55834]},"SansSerif-Italic":{32:[0,0,0,0,.25],33:[0,.69444,.05733,0,.31945],34:[0,.69444,.00316,0,.5],35:[.19444,.69444,.05087,0,.83334],36:[.05556,.75,.11156,0,.5],37:[.05556,.75,.03126,0,.83334],38:[0,.69444,.03058,0,.75834],39:[0,.69444,.07816,0,.27778],40:[.25,.75,.13164,0,.38889],41:[.25,.75,.02536,0,.38889],42:[0,.75,.11775,0,.5],43:[.08333,.58333,.02536,0,.77778],44:[.125,.08333,0,0,.27778],45:[0,.44444,.01946,0,.33333],46:[0,.08333,0,0,.27778],47:[.25,.75,.13164,0,.5],48:[0,.65556,.11156,0,.5],49:[0,.65556,.11156,0,.5],50:[0,.65556,.11156,0,.5],51:[0,.65556,.11156,0,.5],52:[0,.65556,.11156,0,.5],53:[0,.65556,.11156,0,.5],54:[0,.65556,.11156,0,.5],55:[0,.65556,.11156,0,.5],56:[0,.65556,.11156,0,.5],57:[0,.65556,.11156,0,.5],58:[0,.44444,.02502,0,.27778],59:[.125,.44444,.02502,0,.27778],61:[-.13,.37,.05087,0,.77778],63:[0,.69444,.11809,0,.47222],64:[0,.69444,.07555,0,.66667],65:[0,.69444,0,0,.66667],66:[0,.69444,.08293,0,.66667],67:[0,.69444,.11983,0,.63889],68:[0,.69444,.07555,0,.72223],69:[0,.69444,.11983,0,.59722],70:[0,.69444,.13372,0,.56945],71:[0,.69444,.11983,0,.66667],72:[0,.69444,.08094,0,.70834],73:[0,.69444,.13372,0,.27778],74:[0,.69444,.08094,0,.47222],75:[0,.69444,.11983,0,.69445],76:[0,.69444,0,0,.54167],77:[0,.69444,.08094,0,.875],78:[0,.69444,.08094,0,.70834],79:[0,.69444,.07555,0,.73611],80:[0,.69444,.08293,0,.63889],81:[.125,.69444,.07555,0,.73611],82:[0,.69444,.08293,0,.64584],83:[0,.69444,.09205,0,.55556],84:[0,.69444,.13372,0,.68056],85:[0,.69444,.08094,0,.6875],86:[0,.69444,.1615,0,.66667],87:[0,.69444,.1615,0,.94445],88:[0,.69444,.13372,0,.66667],89:[0,.69444,.17261,0,.66667],90:[0,.69444,.11983,0,.61111],91:[.25,.75,.15942,0,.28889],93:[.25,.75,.08719,0,.28889],94:[0,.69444,.0799,0,.5],95:[.35,.09444,.08616,0,.5],97:[0,.44444,.00981,0,.48056],98:[0,.69444,.03057,0,.51667],99:[0,.44444,.08336,0,.44445],100:[0,.69444,.09483,0,.51667],101:[0,.44444,.06778,0,.44445],102:[0,.69444,.21705,0,.30556],103:[.19444,.44444,.10836,0,.5],104:[0,.69444,.01778,0,.51667],105:[0,.67937,.09718,0,.23889],106:[.19444,.67937,.09162,0,.26667],107:[0,.69444,.08336,0,.48889],108:[0,.69444,.09483,0,.23889],109:[0,.44444,.01778,0,.79445],110:[0,.44444,.01778,0,.51667],111:[0,.44444,.06613,0,.5],112:[.19444,.44444,.0389,0,.51667],113:[.19444,.44444,.04169,0,.51667],114:[0,.44444,.10836,0,.34167],115:[0,.44444,.0778,0,.38333],116:[0,.57143,.07225,0,.36111],117:[0,.44444,.04169,0,.51667],118:[0,.44444,.10836,0,.46111],119:[0,.44444,.10836,0,.68334],120:[0,.44444,.09169,0,.46111],121:[.19444,.44444,.10836,0,.46111],122:[0,.44444,.08752,0,.43472],126:[.35,.32659,.08826,0,.5],160:[0,0,0,0,.25],168:[0,.67937,.06385,0,.5],176:[0,.69444,0,0,.73752],184:[.17014,0,0,0,.44445],305:[0,.44444,.04169,0,.23889],567:[.19444,.44444,.04169,0,.26667],710:[0,.69444,.0799,0,.5],711:[0,.63194,.08432,0,.5],713:[0,.60889,.08776,0,.5],714:[0,.69444,.09205,0,.5],715:[0,.69444,0,0,.5],728:[0,.69444,.09483,0,.5],729:[0,.67937,.07774,0,.27778],730:[0,.69444,0,0,.73752],732:[0,.67659,.08826,0,.5],733:[0,.69444,.09205,0,.5],915:[0,.69444,.13372,0,.54167],916:[0,.69444,0,0,.83334],920:[0,.69444,.07555,0,.77778],923:[0,.69444,0,0,.61111],926:[0,.69444,.12816,0,.66667],928:[0,.69444,.08094,0,.70834],931:[0,.69444,.11983,0,.72222],933:[0,.69444,.09031,0,.77778],934:[0,.69444,.04603,0,.72222],936:[0,.69444,.09031,0,.77778],937:[0,.69444,.08293,0,.72222],8211:[0,.44444,.08616,0,.5],8212:[0,.44444,.08616,0,1],8216:[0,.69444,.07816,0,.27778],8217:[0,.69444,.07816,0,.27778],8220:[0,.69444,.14205,0,.5],8221:[0,.69444,.00316,0,.5]},"SansSerif-Regular":{32:[0,0,0,0,.25],33:[0,.69444,0,0,.31945],34:[0,.69444,0,0,.5],35:[.19444,.69444,0,0,.83334],36:[.05556,.75,0,0,.5],37:[.05556,.75,0,0,.83334],38:[0,.69444,0,0,.75834],39:[0,.69444,0,0,.27778],40:[.25,.75,0,0,.38889],41:[.25,.75,0,0,.38889],42:[0,.75,0,0,.5],43:[.08333,.58333,0,0,.77778],44:[.125,.08333,0,0,.27778],45:[0,.44444,0,0,.33333],46:[0,.08333,0,0,.27778],47:[.25,.75,0,0,.5],48:[0,.65556,0,0,.5],49:[0,.65556,0,0,.5],50:[0,.65556,0,0,.5],51:[0,.65556,0,0,.5],52:[0,.65556,0,0,.5],53:[0,.65556,0,0,.5],54:[0,.65556,0,0,.5],55:[0,.65556,0,0,.5],56:[0,.65556,0,0,.5],57:[0,.65556,0,0,.5],58:[0,.44444,0,0,.27778],59:[.125,.44444,0,0,.27778],61:[-.13,.37,0,0,.77778],63:[0,.69444,0,0,.47222],64:[0,.69444,0,0,.66667],65:[0,.69444,0,0,.66667],66:[0,.69444,0,0,.66667],67:[0,.69444,0,0,.63889],68:[0,.69444,0,0,.72223],69:[0,.69444,0,0,.59722],70:[0,.69444,0,0,.56945],71:[0,.69444,0,0,.66667],72:[0,.69444,0,0,.70834],73:[0,.69444,0,0,.27778],74:[0,.69444,0,0,.47222],75:[0,.69444,0,0,.69445],76:[0,.69444,0,0,.54167],77:[0,.69444,0,0,.875],78:[0,.69444,0,0,.70834],79:[0,.69444,0,0,.73611],80:[0,.69444,0,0,.63889],81:[.125,.69444,0,0,.73611],82:[0,.69444,0,0,.64584],83:[0,.69444,0,0,.55556],84:[0,.69444,0,0,.68056],85:[0,.69444,0,0,.6875],86:[0,.69444,.01389,0,.66667],87:[0,.69444,.01389,0,.94445],88:[0,.69444,0,0,.66667],89:[0,.69444,.025,0,.66667],90:[0,.69444,0,0,.61111],91:[.25,.75,0,0,.28889],93:[.25,.75,0,0,.28889],94:[0,.69444,0,0,.5],95:[.35,.09444,.02778,0,.5],97:[0,.44444,0,0,.48056],98:[0,.69444,0,0,.51667],99:[0,.44444,0,0,.44445],100:[0,.69444,0,0,.51667],101:[0,.44444,0,0,.44445],102:[0,.69444,.06944,0,.30556],103:[.19444,.44444,.01389,0,.5],104:[0,.69444,0,0,.51667],105:[0,.67937,0,0,.23889],106:[.19444,.67937,0,0,.26667],107:[0,.69444,0,0,.48889],108:[0,.69444,0,0,.23889],109:[0,.44444,0,0,.79445],110:[0,.44444,0,0,.51667],111:[0,.44444,0,0,.5],112:[.19444,.44444,0,0,.51667],113:[.19444,.44444,0,0,.51667],114:[0,.44444,.01389,0,.34167],115:[0,.44444,0,0,.38333],116:[0,.57143,0,0,.36111],117:[0,.44444,0,0,.51667],118:[0,.44444,.01389,0,.46111],119:[0,.44444,.01389,0,.68334],120:[0,.44444,0,0,.46111],121:[.19444,.44444,.01389,0,.46111],122:[0,.44444,0,0,.43472],126:[.35,.32659,0,0,.5],160:[0,0,0,0,.25],168:[0,.67937,0,0,.5],176:[0,.69444,0,0,.66667],184:[.17014,0,0,0,.44445],305:[0,.44444,0,0,.23889],567:[.19444,.44444,0,0,.26667],710:[0,.69444,0,0,.5],711:[0,.63194,0,0,.5],713:[0,.60889,0,0,.5],714:[0,.69444,0,0,.5],715:[0,.69444,0,0,.5],728:[0,.69444,0,0,.5],729:[0,.67937,0,0,.27778],730:[0,.69444,0,0,.66667],732:[0,.67659,0,0,.5],733:[0,.69444,0,0,.5],915:[0,.69444,0,0,.54167],916:[0,.69444,0,0,.83334],920:[0,.69444,0,0,.77778],923:[0,.69444,0,0,.61111],926:[0,.69444,0,0,.66667],928:[0,.69444,0,0,.70834],931:[0,.69444,0,0,.72222],933:[0,.69444,0,0,.77778],934:[0,.69444,0,0,.72222],936:[0,.69444,0,0,.77778],937:[0,.69444,0,0,.72222],8211:[0,.44444,.02778,0,.5],8212:[0,.44444,.02778,0,1],8216:[0,.69444,0,0,.27778],8217:[0,.69444,0,0,.27778],8220:[0,.69444,0,0,.5],8221:[0,.69444,0,0,.5]},"Script-Regular":{32:[0,0,0,0,.25],65:[0,.7,.22925,0,.80253],66:[0,.7,.04087,0,.90757],67:[0,.7,.1689,0,.66619],68:[0,.7,.09371,0,.77443],69:[0,.7,.18583,0,.56162],70:[0,.7,.13634,0,.89544],71:[0,.7,.17322,0,.60961],72:[0,.7,.29694,0,.96919],73:[0,.7,.19189,0,.80907],74:[.27778,.7,.19189,0,1.05159],75:[0,.7,.31259,0,.91364],76:[0,.7,.19189,0,.87373],77:[0,.7,.15981,0,1.08031],78:[0,.7,.3525,0,.9015],79:[0,.7,.08078,0,.73787],80:[0,.7,.08078,0,1.01262],81:[0,.7,.03305,0,.88282],82:[0,.7,.06259,0,.85],83:[0,.7,.19189,0,.86767],84:[0,.7,.29087,0,.74697],85:[0,.7,.25815,0,.79996],86:[0,.7,.27523,0,.62204],87:[0,.7,.27523,0,.80532],88:[0,.7,.26006,0,.94445],89:[0,.7,.2939,0,.70961],90:[0,.7,.24037,0,.8212],160:[0,0,0,0,.25]},"Size1-Regular":{32:[0,0,0,0,.25],40:[.35001,.85,0,0,.45834],41:[.35001,.85,0,0,.45834],47:[.35001,.85,0,0,.57778],91:[.35001,.85,0,0,.41667],92:[.35001,.85,0,0,.57778],93:[.35001,.85,0,0,.41667],123:[.35001,.85,0,0,.58334],125:[.35001,.85,0,0,.58334],160:[0,0,0,0,.25],710:[0,.72222,0,0,.55556],732:[0,.72222,0,0,.55556],770:[0,.72222,0,0,.55556],771:[0,.72222,0,0,.55556],8214:[-99e-5,.601,0,0,.77778],8593:[1e-5,.6,0,0,.66667],8595:[1e-5,.6,0,0,.66667],8657:[1e-5,.6,0,0,.77778],8659:[1e-5,.6,0,0,.77778],8719:[.25001,.75,0,0,.94445],8720:[.25001,.75,0,0,.94445],8721:[.25001,.75,0,0,1.05556],8730:[.35001,.85,0,0,1],8739:[-.00599,.606,0,0,.33333],8741:[-.00599,.606,0,0,.55556],8747:[.30612,.805,.19445,0,.47222],8748:[.306,.805,.19445,0,.47222],8749:[.306,.805,.19445,0,.47222],8750:[.30612,.805,.19445,0,.47222],8896:[.25001,.75,0,0,.83334],8897:[.25001,.75,0,0,.83334],8898:[.25001,.75,0,0,.83334],8899:[.25001,.75,0,0,.83334],8968:[.35001,.85,0,0,.47222],8969:[.35001,.85,0,0,.47222],8970:[.35001,.85,0,0,.47222],8971:[.35001,.85,0,0,.47222],9168:[-99e-5,.601,0,0,.66667],10216:[.35001,.85,0,0,.47222],10217:[.35001,.85,0,0,.47222],10752:[.25001,.75,0,0,1.11111],10753:[.25001,.75,0,0,1.11111],10754:[.25001,.75,0,0,1.11111],10756:[.25001,.75,0,0,.83334],10758:[.25001,.75,0,0,.83334]},"Size2-Regular":{32:[0,0,0,0,.25],40:[.65002,1.15,0,0,.59722],41:[.65002,1.15,0,0,.59722],47:[.65002,1.15,0,0,.81111],91:[.65002,1.15,0,0,.47222],92:[.65002,1.15,0,0,.81111],93:[.65002,1.15,0,0,.47222],123:[.65002,1.15,0,0,.66667],125:[.65002,1.15,0,0,.66667],160:[0,0,0,0,.25],710:[0,.75,0,0,1],732:[0,.75,0,0,1],770:[0,.75,0,0,1],771:[0,.75,0,0,1],8719:[.55001,1.05,0,0,1.27778],8720:[.55001,1.05,0,0,1.27778],8721:[.55001,1.05,0,0,1.44445],8730:[.65002,1.15,0,0,1],8747:[.86225,1.36,.44445,0,.55556],8748:[.862,1.36,.44445,0,.55556],8749:[.862,1.36,.44445,0,.55556],8750:[.86225,1.36,.44445,0,.55556],8896:[.55001,1.05,0,0,1.11111],8897:[.55001,1.05,0,0,1.11111],8898:[.55001,1.05,0,0,1.11111],8899:[.55001,1.05,0,0,1.11111],8968:[.65002,1.15,0,0,.52778],8969:[.65002,1.15,0,0,.52778],8970:[.65002,1.15,0,0,.52778],8971:[.65002,1.15,0,0,.52778],10216:[.65002,1.15,0,0,.61111],10217:[.65002,1.15,0,0,.61111],10752:[.55001,1.05,0,0,1.51112],10753:[.55001,1.05,0,0,1.51112],10754:[.55001,1.05,0,0,1.51112],10756:[.55001,1.05,0,0,1.11111],10758:[.55001,1.05,0,0,1.11111]},"Size3-Regular":{32:[0,0,0,0,.25],40:[.95003,1.45,0,0,.73611],41:[.95003,1.45,0,0,.73611],47:[.95003,1.45,0,0,1.04445],91:[.95003,1.45,0,0,.52778],92:[.95003,1.45,0,0,1.04445],93:[.95003,1.45,0,0,.52778],123:[.95003,1.45,0,0,.75],125:[.95003,1.45,0,0,.75],160:[0,0,0,0,.25],710:[0,.75,0,0,1.44445],732:[0,.75,0,0,1.44445],770:[0,.75,0,0,1.44445],771:[0,.75,0,0,1.44445],8730:[.95003,1.45,0,0,1],8968:[.95003,1.45,0,0,.58334],8969:[.95003,1.45,0,0,.58334],8970:[.95003,1.45,0,0,.58334],8971:[.95003,1.45,0,0,.58334],10216:[.95003,1.45,0,0,.75],10217:[.95003,1.45,0,0,.75]},"Size4-Regular":{32:[0,0,0,0,.25],40:[1.25003,1.75,0,0,.79167],41:[1.25003,1.75,0,0,.79167],47:[1.25003,1.75,0,0,1.27778],91:[1.25003,1.75,0,0,.58334],92:[1.25003,1.75,0,0,1.27778],93:[1.25003,1.75,0,0,.58334],123:[1.25003,1.75,0,0,.80556],125:[1.25003,1.75,0,0,.80556],160:[0,0,0,0,.25],710:[0,.825,0,0,1.8889],732:[0,.825,0,0,1.8889],770:[0,.825,0,0,1.8889],771:[0,.825,0,0,1.8889],8730:[1.25003,1.75,0,0,1],8968:[1.25003,1.75,0,0,.63889],8969:[1.25003,1.75,0,0,.63889],8970:[1.25003,1.75,0,0,.63889],8971:[1.25003,1.75,0,0,.63889],9115:[.64502,1.155,0,0,.875],9116:[1e-5,.6,0,0,.875],9117:[.64502,1.155,0,0,.875],9118:[.64502,1.155,0,0,.875],9119:[1e-5,.6,0,0,.875],9120:[.64502,1.155,0,0,.875],9121:[.64502,1.155,0,0,.66667],9122:[-99e-5,.601,0,0,.66667],9123:[.64502,1.155,0,0,.66667],9124:[.64502,1.155,0,0,.66667],9125:[-99e-5,.601,0,0,.66667],9126:[.64502,1.155,0,0,.66667],9127:[1e-5,.9,0,0,.88889],9128:[.65002,1.15,0,0,.88889],9129:[.90001,0,0,0,.88889],9130:[0,.3,0,0,.88889],9131:[1e-5,.9,0,0,.88889],9132:[.65002,1.15,0,0,.88889],9133:[.90001,0,0,0,.88889],9143:[.88502,.915,0,0,1.05556],10216:[1.25003,1.75,0,0,.80556],10217:[1.25003,1.75,0,0,.80556],57344:[-.00499,.605,0,0,1.05556],57345:[-.00499,.605,0,0,1.05556],57680:[0,.12,0,0,.45],57681:[0,.12,0,0,.45],57682:[0,.12,0,0,.45],57683:[0,.12,0,0,.45]},"Typewriter-Regular":{32:[0,0,0,0,.525],33:[0,.61111,0,0,.525],34:[0,.61111,0,0,.525],35:[0,.61111,0,0,.525],36:[.08333,.69444,0,0,.525],37:[.08333,.69444,0,0,.525],38:[0,.61111,0,0,.525],39:[0,.61111,0,0,.525],40:[.08333,.69444,0,0,.525],41:[.08333,.69444,0,0,.525],42:[0,.52083,0,0,.525],43:[-.08056,.53055,0,0,.525],44:[.13889,.125,0,0,.525],45:[-.08056,.53055,0,0,.525],46:[0,.125,0,0,.525],47:[.08333,.69444,0,0,.525],48:[0,.61111,0,0,.525],49:[0,.61111,0,0,.525],50:[0,.61111,0,0,.525],51:[0,.61111,0,0,.525],52:[0,.61111,0,0,.525],53:[0,.61111,0,0,.525],54:[0,.61111,0,0,.525],55:[0,.61111,0,0,.525],56:[0,.61111,0,0,.525],57:[0,.61111,0,0,.525],58:[0,.43056,0,0,.525],59:[.13889,.43056,0,0,.525],60:[-.05556,.55556,0,0,.525],61:[-.19549,.41562,0,0,.525],62:[-.05556,.55556,0,0,.525],63:[0,.61111,0,0,.525],64:[0,.61111,0,0,.525],65:[0,.61111,0,0,.525],66:[0,.61111,0,0,.525],67:[0,.61111,0,0,.525],68:[0,.61111,0,0,.525],69:[0,.61111,0,0,.525],70:[0,.61111,0,0,.525],71:[0,.61111,0,0,.525],72:[0,.61111,0,0,.525],73:[0,.61111,0,0,.525],74:[0,.61111,0,0,.525],75:[0,.61111,0,0,.525],76:[0,.61111,0,0,.525],77:[0,.61111,0,0,.525],78:[0,.61111,0,0,.525],79:[0,.61111,0,0,.525],80:[0,.61111,0,0,.525],81:[.13889,.61111,0,0,.525],82:[0,.61111,0,0,.525],83:[0,.61111,0,0,.525],84:[0,.61111,0,0,.525],85:[0,.61111,0,0,.525],86:[0,.61111,0,0,.525],87:[0,.61111,0,0,.525],88:[0,.61111,0,0,.525],89:[0,.61111,0,0,.525],90:[0,.61111,0,0,.525],91:[.08333,.69444,0,0,.525],92:[.08333,.69444,0,0,.525],93:[.08333,.69444,0,0,.525],94:[0,.61111,0,0,.525],95:[.09514,0,0,0,.525],96:[0,.61111,0,0,.525],97:[0,.43056,0,0,.525],98:[0,.61111,0,0,.525],99:[0,.43056,0,0,.525],100:[0,.61111,0,0,.525],101:[0,.43056,0,0,.525],102:[0,.61111,0,0,.525],103:[.22222,.43056,0,0,.525],104:[0,.61111,0,0,.525],105:[0,.61111,0,0,.525],106:[.22222,.61111,0,0,.525],107:[0,.61111,0,0,.525],108:[0,.61111,0,0,.525],109:[0,.43056,0,0,.525],110:[0,.43056,0,0,.525],111:[0,.43056,0,0,.525],112:[.22222,.43056,0,0,.525],113:[.22222,.43056,0,0,.525],114:[0,.43056,0,0,.525],115:[0,.43056,0,0,.525],116:[0,.55358,0,0,.525],117:[0,.43056,0,0,.525],118:[0,.43056,0,0,.525],119:[0,.43056,0,0,.525],120:[0,.43056,0,0,.525],121:[.22222,.43056,0,0,.525],122:[0,.43056,0,0,.525],123:[.08333,.69444,0,0,.525],124:[.08333,.69444,0,0,.525],125:[.08333,.69444,0,0,.525],126:[0,.61111,0,0,.525],127:[0,.61111,0,0,.525],160:[0,0,0,0,.525],176:[0,.61111,0,0,.525],184:[.19445,0,0,0,.525],305:[0,.43056,0,0,.525],567:[.22222,.43056,0,0,.525],711:[0,.56597,0,0,.525],713:[0,.56555,0,0,.525],714:[0,.61111,0,0,.525],715:[0,.61111,0,0,.525],728:[0,.61111,0,0,.525],730:[0,.61111,0,0,.525],770:[0,.61111,0,0,.525],771:[0,.61111,0,0,.525],776:[0,.61111,0,0,.525],915:[0,.61111,0,0,.525],916:[0,.61111,0,0,.525],920:[0,.61111,0,0,.525],923:[0,.61111,0,0,.525],926:[0,.61111,0,0,.525],928:[0,.61111,0,0,.525],931:[0,.61111,0,0,.525],933:[0,.61111,0,0,.525],934:[0,.61111,0,0,.525],936:[0,.61111,0,0,.525],937:[0,.61111,0,0,.525],8216:[0,.61111,0,0,.525],8217:[0,.61111,0,0,.525],8242:[0,.61111,0,0,.525],9251:[.11111,.21944,0,0,.525]}},BO={slant:[.25,.25,.25],space:[0,0,0],stretch:[0,0,0],shrink:[0,0,0],xHeight:[.431,.431,.431],quad:[1,1.171,1.472],extraSpace:[0,0,0],num1:[.677,.732,.925],num2:[.394,.384,.387],num3:[.444,.471,.504],denom1:[.686,.752,1.025],denom2:[.345,.344,.532],sup1:[.413,.503,.504],sup2:[.363,.431,.404],sup3:[.289,.286,.294],sub1:[.15,.143,.2],sub2:[.247,.286,.4],supDrop:[.386,.353,.494],subDrop:[.05,.071,.1],delim1:[2.39,1.7,1.98],delim2:[1.01,1.157,1.42],axisHeight:[.25,.25,.25],defaultRuleThickness:[.04,.049,.049],bigOpSpacing1:[.111,.111,.111],bigOpSpacing2:[.166,.166,.166],bigOpSpacing3:[.2,.2,.2],bigOpSpacing4:[.6,.611,.611],bigOpSpacing5:[.1,.143,.143],sqrtRuleThickness:[.04,.04,.04],ptPerEm:[10,10,10],doubleRuleSep:[.2,.2,.2],arrayRuleWidth:[.04,.04,.04],fboxsep:[.3,.3,.3],fboxrule:[.04,.04,.04]},SO={"Å":"A","Ð":"D","Þ":"o","å":"a","ð":"d","þ":"o","А":"A","Б":"B","В":"B","Г":"F","Д":"A","Е":"E","Ж":"K","З":"3","И":"N","Й":"N","К":"K","Л":"N","М":"M","Н":"H","О":"O","П":"N","Р":"P","С":"C","Т":"T","У":"y","Ф":"O","Х":"X","Ц":"U","Ч":"h","Ш":"W","Щ":"W","Ъ":"B","Ы":"X","Ь":"B","Э":"3","Ю":"X","Я":"R","а":"a","б":"b","в":"a","г":"r","д":"y","е":"e","ж":"m","з":"e","и":"n","й":"n","к":"n","л":"n","м":"m","н":"n","о":"o","п":"n","р":"p","с":"c","т":"o","у":"y","ф":"b","х":"x","ц":"n","ч":"n","ш":"w","щ":"w","ъ":"a","ы":"m","ь":"a","э":"e","ю":"m","я":"r"};function FO(e,t,r){if(!xO[t])throw new Error("Font metrics not found for font: "+t+".");var n=e.charCodeAt(0),o=xO[t][n];if(!o&&e[0]in SO&&(n=SO[e[0]].charCodeAt(0),o=xO[t][n]),o||"text"!==r||CO(n)&&(o=xO[t][77]),o)return{depth:o[0],height:o[1],italic:o[2],skew:o[3],width:o[4]}}var kO={};var OO=[[1,1,1],[2,1,1],[3,1,1],[4,2,1],[5,2,1],[6,3,1],[7,4,2],[8,6,3],[9,7,6],[10,8,7],[11,10,9]],TO=[.5,.6,.7,.8,.9,1,1.2,1.44,1.728,2.074,2.488],NO=function(e,t){return t.size<2?e:OO[e-1][t.size-1]};class PO{constructor(e){this.style=void 0,this.color=void 0,this.size=void 0,this.textSize=void 0,this.phantom=void 0,this.font=void 0,this.fontFamily=void 0,this.fontWeight=void 0,this.fontShape=void 0,this.sizeMultiplier=void 0,this.maxSize=void 0,this.minRuleThickness=void 0,this._fontMetrics=void 0,this.style=e.style,this.color=e.color,this.size=e.size||PO.BASESIZE,this.textSize=e.textSize||this.size,this.phantom=!!e.phantom,this.font=e.font||"",this.fontFamily=e.fontFamily||"",this.fontWeight=e.fontWeight||"",this.fontShape=e.fontShape||"",this.sizeMultiplier=TO[this.size-1],this.maxSize=e.maxSize,this.minRuleThickness=e.minRuleThickness,this._fontMetrics=void 0}extend(e){var t={style:this.style,size:this.size,textSize:this.textSize,color:this.color,phantom:this.phantom,font:this.font,fontFamily:this.fontFamily,fontWeight:this.fontWeight,fontShape:this.fontShape,maxSize:this.maxSize,minRuleThickness:this.minRuleThickness};for(var r in e)e.hasOwnProperty(r)&&(t[r]=e[r]);return new PO(t)}havingStyle(e){return this.style===e?this:this.extend({style:e,size:NO(this.textSize,e)})}havingCrampedStyle(){return this.havingStyle(this.style.cramp())}havingSize(e){return this.size===e&&this.textSize===e?this:this.extend({style:this.style.text(),size:e,textSize:e,sizeMultiplier:TO[e-1]})}havingBaseStyle(e){e=e||this.style.text();var t=NO(PO.BASESIZE,e);return this.size===t&&this.textSize===PO.BASESIZE&&this.style===e?this:this.extend({style:e,size:t})}havingBaseSizing(){var e;switch(this.style.id){case 4:case 5:e=3;break;case 6:case 7:e=1;break;default:e=6}return this.extend({style:this.style.text(),size:e})}withColor(e){return this.extend({color:e})}withPhantom(){return this.extend({phantom:!0})}withFont(e){return this.extend({font:e})}withTextFontFamily(e){return this.extend({fontFamily:e,font:""})}withTextFontWeight(e){return this.extend({fontWeight:e,font:""})}withTextFontShape(e){return this.extend({fontShape:e,font:""})}sizingClasses(e){return e.size!==this.size?["sizing","reset-size"+e.size,"size"+this.size]:[]}baseSizingClasses(){return this.size!==PO.BASESIZE?["sizing","reset-size"+this.size,"size"+PO.BASESIZE]:[]}fontMetrics(){return this._fontMetrics||(this._fontMetrics=function(e){var t;if(!kO[t=e>=5?0:e>=3?1:2]){var r=kO[t]={cssEmPerMu:BO.quad[t]/18};for(var n in BO)BO.hasOwnProperty(n)&&(r[n]=BO[n][t])}return kO[t]}(this.size)),this._fontMetrics}getColor(){return this.phantom?"transparent":this.color}}PO.BASESIZE=6;var MO={pt:1,mm:7227/2540,cm:7227/254,in:72.27,bp:1.00375,pc:12,dd:1238/1157,cc:14856/1157,nd:685/642,nc:1370/107,sp:1/65536,px:1.00375},IO={ex:!0,em:!0,mu:!0},RO=function(e){return"string"!=typeof e&&(e=e.unit),e in MO||e in IO||"ex"===e},LO=function(e,t){var r;if(e.unit in MO)r=MO[e.unit]/t.fontMetrics().ptPerEm/t.sizeMultiplier;else if("mu"===e.unit)r=t.fontMetrics().cssEmPerMu;else{var n;if(n=t.style.isTight()?t.havingStyle(t.style.text()):t,"ex"===e.unit)r=n.fontMetrics().xHeight;else{if("em"!==e.unit)throw new tO("Invalid unit: '"+e.unit+"'");r=n.fontMetrics().quad}n!==t&&(r*=n.sizeMultiplier/t.sizeMultiplier)}return Math.min(e.number*r,t.maxSize)},_O=function(e){return+e.toFixed(4)+"em"},zO=function(e){return e.filter(e=>e).join(" ")},jO=function(e,t,r){if(this.classes=e||[],this.attributes={},this.height=0,this.depth=0,this.maxFontSize=0,this.style=r||{},t){t.style.isTight()&&this.classes.push("mtight");var n=t.getColor();n&&(this.style.color=n)}},HO=function(e){var t=document.createElement(e);for(var r in t.className=zO(this.classes),this.style)this.style.hasOwnProperty(r)&&(t.style[r]=this.style[r]);for(var n in this.attributes)this.attributes.hasOwnProperty(n)&&t.setAttribute(n,this.attributes[n]);for(var o=0;o<this.children.length;o++)t.appendChild(this.children[o].toNode());return t},VO=/[\s"'>/=\x00-\x1f]/,$O=function(e){var t="<"+e;this.classes.length&&(t+=' class="'+aO.escape(zO(this.classes))+'"');var r="";for(var n in this.style)this.style.hasOwnProperty(n)&&(r+=aO.hyphenate(n)+":"+this.style[n]+";");for(var o in r&&(t+=' style="'+aO.escape(r)+'"'),this.attributes)if(this.attributes.hasOwnProperty(o)){if(VO.test(o))throw new tO("Invalid attribute name '"+o+"'");t+=" "+o+'="'+aO.escape(this.attributes[o])+'"'}t+=">";for(var i=0;i<this.children.length;i++)t+=this.children[i].toMarkup();return t+="</"+e+">"};let UO=class{constructor(e,t,r,n){this.children=void 0,this.attributes=void 0,this.classes=void 0,this.height=void 0,this.depth=void 0,this.width=void 0,this.maxFontSize=void 0,this.style=void 0,jO.call(this,e,r,n),this.children=t||[]}setAttribute(e,t){this.attributes[e]=t}hasClass(e){return aO.contains(this.classes,e)}toNode(){return HO.call(this,"span")}toMarkup(){return $O.call(this,"span")}};class qO{constructor(e,t,r,n){this.children=void 0,this.attributes=void 0,this.classes=void 0,this.height=void 0,this.depth=void 0,this.maxFontSize=void 0,this.style=void 0,jO.call(this,t,n),this.children=r||[],this.setAttribute("href",e)}setAttribute(e,t){this.attributes[e]=t}hasClass(e){return aO.contains(this.classes,e)}toNode(){return HO.call(this,"a")}toMarkup(){return $O.call(this,"a")}}class WO{constructor(e,t,r){this.src=void 0,this.alt=void 0,this.classes=void 0,this.height=void 0,this.depth=void 0,this.maxFontSize=void 0,this.style=void 0,this.alt=t,this.src=e,this.classes=["mord"],this.style=r}hasClass(e){return aO.contains(this.classes,e)}toNode(){var e=document.createElement("img");for(var t in e.src=this.src,e.alt=this.alt,e.className="mord",this.style)this.style.hasOwnProperty(t)&&(e.style[t]=this.style[t]);return e}toMarkup(){var e='<img src="'+aO.escape(this.src)+'" alt="'+aO.escape(this.alt)+'"',t="";for(var r in this.style)this.style.hasOwnProperty(r)&&(t+=aO.hyphenate(r)+":"+this.style[r]+";");return t&&(e+=' style="'+aO.escape(t)+'"'),e+="'/>"}}var GO={"î":"ı̂","ï":"ı̈","í":"ı́","ì":"ı̀"};class YO{constructor(e,t,r,n,o,i,a,s){this.text=void 0,this.height=void 0,this.depth=void 0,this.italic=void 0,this.skew=void 0,this.width=void 0,this.maxFontSize=void 0,this.classes=void 0,this.style=void 0,this.text=e,this.height=t||0,this.depth=r||0,this.italic=n||0,this.skew=o||0,this.width=i||0,this.classes=a||[],this.style=s||{},this.maxFontSize=0;var u=function(e){for(var t=0;t<bO.length;t++)for(var r=bO[t],n=0;n<r.blocks.length;n++){var o=r.blocks[n];if(e>=o[0]&&e<=o[1])return r.name}return null}(this.text.charCodeAt(0));u&&this.classes.push(u+"_fallback"),/[îïíì]/.test(this.text)&&(this.text=GO[this.text])}hasClass(e){return aO.contains(this.classes,e)}toNode(){var e=document.createTextNode(this.text),t=null;for(var r in this.italic>0&&((t=document.createElement("span")).style.marginRight=_O(this.italic)),this.classes.length>0&&((t=t||document.createElement("span")).className=zO(this.classes)),this.style)this.style.hasOwnProperty(r)&&((t=t||document.createElement("span")).style[r]=this.style[r]);return t?(t.appendChild(e),t):e}toMarkup(){var e=!1,t="<span";this.classes.length&&(e=!0,t+=' class="',t+=aO.escape(zO(this.classes)),t+='"');var r="";for(var n in this.italic>0&&(r+="margin-right:"+this.italic+"em;"),this.style)this.style.hasOwnProperty(n)&&(r+=aO.hyphenate(n)+":"+this.style[n]+";");r&&(e=!0,t+=' style="'+aO.escape(r)+'"');var o=aO.escape(this.text);return e?(t+=">",t+=o,t+="</span>"):o}}class KO{constructor(e,t){this.children=void 0,this.attributes=void 0,this.children=e||[],this.attributes=t||{}}toNode(){var e=document.createElementNS("http://www.w3.org/2000/svg","svg");for(var t in this.attributes)Object.prototype.hasOwnProperty.call(this.attributes,t)&&e.setAttribute(t,this.attributes[t]);for(var r=0;r<this.children.length;r++)e.appendChild(this.children[r].toNode());return e}toMarkup(){var e='<svg xmlns="http://www.w3.org/2000/svg"';for(var t in this.attributes)Object.prototype.hasOwnProperty.call(this.attributes,t)&&(e+=" "+t+'="'+aO.escape(this.attributes[t])+'"');e+=">";for(var r=0;r<this.children.length;r++)e+=this.children[r].toMarkup();return e+="</svg>"}}class XO{constructor(e,t){this.pathName=void 0,this.alternate=void 0,this.pathName=e,this.alternate=t}toNode(){var e=document.createElementNS("http://www.w3.org/2000/svg","path");return this.alternate?e.setAttribute("d",this.alternate):e.setAttribute("d",EO[this.pathName]),e}toMarkup(){return this.alternate?'<path d="'+aO.escape(this.alternate)+'"/>':'<path d="'+aO.escape(EO[this.pathName])+'"/>'}}class ZO{constructor(e){this.attributes=void 0,this.attributes=e||{}}toNode(){var e=document.createElementNS("http://www.w3.org/2000/svg","line");for(var t in this.attributes)Object.prototype.hasOwnProperty.call(this.attributes,t)&&e.setAttribute(t,this.attributes[t]);return e}toMarkup(){var e="<line";for(var t in this.attributes)Object.prototype.hasOwnProperty.call(this.attributes,t)&&(e+=" "+t+'="'+aO.escape(this.attributes[t])+'"');return e+="/>"}}function JO(e){if(e instanceof YO)return e;throw new Error("Expected symbolNode but got "+String(e)+".")}var QO={bin:1,close:1,inner:1,open:1,punct:1,rel:1},eT={"accent-token":1,mathord:1,"op-token":1,spacing:1,textord:1},tT={math:{},text:{}};function rT(e,t,r,n,o,i){tT[e][o]={font:t,group:r,replace:n},i&&n&&(tT[e][n]=tT[e][o])}var nT="math",oT="text",iT="main",aT="ams",sT="accent-token",uT="bin",lT="close",cT="inner",dT="mathord",hT="op-token",fT="open",pT="punct",gT="rel",mT="spacing",vT="textord";rT(nT,iT,gT,"≡","\\equiv",!0),rT(nT,iT,gT,"≺","\\prec",!0),rT(nT,iT,gT,"≻","\\succ",!0),rT(nT,iT,gT,"∼","\\sim",!0),rT(nT,iT,gT,"⊥","\\perp"),rT(nT,iT,gT,"⪯","\\preceq",!0),rT(nT,iT,gT,"⪰","\\succeq",!0),rT(nT,iT,gT,"≃","\\simeq",!0),rT(nT,iT,gT,"∣","\\mid",!0),rT(nT,iT,gT,"≪","\\ll",!0),rT(nT,iT,gT,"≫","\\gg",!0),rT(nT,iT,gT,"≍","\\asymp",!0),rT(nT,iT,gT,"∥","\\parallel"),rT(nT,iT,gT,"⋈","\\bowtie",!0),rT(nT,iT,gT,"⌣","\\smile",!0),rT(nT,iT,gT,"⊑","\\sqsubseteq",!0),rT(nT,iT,gT,"⊒","\\sqsupseteq",!0),rT(nT,iT,gT,"≐","\\doteq",!0),rT(nT,iT,gT,"⌢","\\frown",!0),rT(nT,iT,gT,"∋","\\ni",!0),rT(nT,iT,gT,"∝","\\propto",!0),rT(nT,iT,gT,"⊢","\\vdash",!0),rT(nT,iT,gT,"⊣","\\dashv",!0),rT(nT,iT,gT,"∋","\\owns"),rT(nT,iT,pT,".","\\ldotp"),rT(nT,iT,pT,"⋅","\\cdotp"),rT(nT,iT,vT,"#","\\#"),rT(oT,iT,vT,"#","\\#"),rT(nT,iT,vT,"&","\\&"),rT(oT,iT,vT,"&","\\&"),rT(nT,iT,vT,"ℵ","\\aleph",!0),rT(nT,iT,vT,"∀","\\forall",!0),rT(nT,iT,vT,"ℏ","\\hbar",!0),rT(nT,iT,vT,"∃","\\exists",!0),rT(nT,iT,vT,"∇","\\nabla",!0),rT(nT,iT,vT,"♭","\\flat",!0),rT(nT,iT,vT,"ℓ","\\ell",!0),rT(nT,iT,vT,"♮","\\natural",!0),rT(nT,iT,vT,"♣","\\clubsuit",!0),rT(nT,iT,vT,"℘","\\wp",!0),rT(nT,iT,vT,"♯","\\sharp",!0),rT(nT,iT,vT,"♢","\\diamondsuit",!0),rT(nT,iT,vT,"ℜ","\\Re",!0),rT(nT,iT,vT,"♡","\\heartsuit",!0),rT(nT,iT,vT,"ℑ","\\Im",!0),rT(nT,iT,vT,"♠","\\spadesuit",!0),rT(nT,iT,vT,"§","\\S",!0),rT(oT,iT,vT,"§","\\S"),rT(nT,iT,vT,"¶","\\P",!0),rT(oT,iT,vT,"¶","\\P"),rT(nT,iT,vT,"†","\\dag"),rT(oT,iT,vT,"†","\\dag"),rT(oT,iT,vT,"†","\\textdagger"),rT(nT,iT,vT,"‡","\\ddag"),rT(oT,iT,vT,"‡","\\ddag"),rT(oT,iT,vT,"‡","\\textdaggerdbl"),rT(nT,iT,lT,"⎱","\\rmoustache",!0),rT(nT,iT,fT,"⎰","\\lmoustache",!0),rT(nT,iT,lT,"⟯","\\rgroup",!0),rT(nT,iT,fT,"⟮","\\lgroup",!0),rT(nT,iT,uT,"∓","\\mp",!0),rT(nT,iT,uT,"⊖","\\ominus",!0),rT(nT,iT,uT,"⊎","\\uplus",!0),rT(nT,iT,uT,"⊓","\\sqcap",!0),rT(nT,iT,uT,"∗","\\ast"),rT(nT,iT,uT,"⊔","\\sqcup",!0),rT(nT,iT,uT,"◯","\\bigcirc",!0),rT(nT,iT,uT,"∙","\\bullet",!0),rT(nT,iT,uT,"‡","\\ddagger"),rT(nT,iT,uT,"≀","\\wr",!0),rT(nT,iT,uT,"⨿","\\amalg"),rT(nT,iT,uT,"&","\\And"),rT(nT,iT,gT,"⟵","\\longleftarrow",!0),rT(nT,iT,gT,"⇐","\\Leftarrow",!0),rT(nT,iT,gT,"⟸","\\Longleftarrow",!0),rT(nT,iT,gT,"⟶","\\longrightarrow",!0),rT(nT,iT,gT,"⇒","\\Rightarrow",!0),rT(nT,iT,gT,"⟹","\\Longrightarrow",!0),rT(nT,iT,gT,"↔","\\leftrightarrow",!0),rT(nT,iT,gT,"⟷","\\longleftrightarrow",!0),rT(nT,iT,gT,"⇔","\\Leftrightarrow",!0),rT(nT,iT,gT,"⟺","\\Longleftrightarrow",!0),rT(nT,iT,gT,"↦","\\mapsto",!0),rT(nT,iT,gT,"⟼","\\longmapsto",!0),rT(nT,iT,gT,"↗","\\nearrow",!0),rT(nT,iT,gT,"↩","\\hookleftarrow",!0),rT(nT,iT,gT,"↪","\\hookrightarrow",!0),rT(nT,iT,gT,"↘","\\searrow",!0),rT(nT,iT,gT,"↼","\\leftharpoonup",!0),rT(nT,iT,gT,"⇀","\\rightharpoonup",!0),rT(nT,iT,gT,"↙","\\swarrow",!0),rT(nT,iT,gT,"↽","\\leftharpoondown",!0),rT(nT,iT,gT,"⇁","\\rightharpoondown",!0),rT(nT,iT,gT,"↖","\\nwarrow",!0),rT(nT,iT,gT,"⇌","\\rightleftharpoons",!0),rT(nT,aT,gT,"≮","\\nless",!0),rT(nT,aT,gT,"","\\@nleqslant"),rT(nT,aT,gT,"","\\@nleqq"),rT(nT,aT,gT,"⪇","\\lneq",!0),rT(nT,aT,gT,"≨","\\lneqq",!0),rT(nT,aT,gT,"","\\@lvertneqq"),rT(nT,aT,gT,"⋦","\\lnsim",!0),rT(nT,aT,gT,"⪉","\\lnapprox",!0),rT(nT,aT,gT,"⊀","\\nprec",!0),rT(nT,aT,gT,"⋠","\\npreceq",!0),rT(nT,aT,gT,"⋨","\\precnsim",!0),rT(nT,aT,gT,"⪹","\\precnapprox",!0),rT(nT,aT,gT,"≁","\\nsim",!0),rT(nT,aT,gT,"","\\@nshortmid"),rT(nT,aT,gT,"∤","\\nmid",!0),rT(nT,aT,gT,"⊬","\\nvdash",!0),rT(nT,aT,gT,"⊭","\\nvDash",!0),rT(nT,aT,gT,"⋪","\\ntriangleleft"),rT(nT,aT,gT,"⋬","\\ntrianglelefteq",!0),rT(nT,aT,gT,"⊊","\\subsetneq",!0),rT(nT,aT,gT,"","\\@varsubsetneq"),rT(nT,aT,gT,"⫋","\\subsetneqq",!0),rT(nT,aT,gT,"","\\@varsubsetneqq"),rT(nT,aT,gT,"≯","\\ngtr",!0),rT(nT,aT,gT,"","\\@ngeqslant"),rT(nT,aT,gT,"","\\@ngeqq"),rT(nT,aT,gT,"⪈","\\gneq",!0),rT(nT,aT,gT,"≩","\\gneqq",!0),rT(nT,aT,gT,"","\\@gvertneqq"),rT(nT,aT,gT,"⋧","\\gnsim",!0),rT(nT,aT,gT,"⪊","\\gnapprox",!0),rT(nT,aT,gT,"⊁","\\nsucc",!0),rT(nT,aT,gT,"⋡","\\nsucceq",!0),rT(nT,aT,gT,"⋩","\\succnsim",!0),rT(nT,aT,gT,"⪺","\\succnapprox",!0),rT(nT,aT,gT,"≆","\\ncong",!0),rT(nT,aT,gT,"","\\@nshortparallel"),rT(nT,aT,gT,"∦","\\nparallel",!0),rT(nT,aT,gT,"⊯","\\nVDash",!0),rT(nT,aT,gT,"⋫","\\ntriangleright"),rT(nT,aT,gT,"⋭","\\ntrianglerighteq",!0),rT(nT,aT,gT,"","\\@nsupseteqq"),rT(nT,aT,gT,"⊋","\\supsetneq",!0),rT(nT,aT,gT,"","\\@varsupsetneq"),rT(nT,aT,gT,"⫌","\\supsetneqq",!0),rT(nT,aT,gT,"","\\@varsupsetneqq"),rT(nT,aT,gT,"⊮","\\nVdash",!0),rT(nT,aT,gT,"⪵","\\precneqq",!0),rT(nT,aT,gT,"⪶","\\succneqq",!0),rT(nT,aT,gT,"","\\@nsubseteqq"),rT(nT,aT,uT,"⊴","\\unlhd"),rT(nT,aT,uT,"⊵","\\unrhd"),rT(nT,aT,gT,"↚","\\nleftarrow",!0),rT(nT,aT,gT,"↛","\\nrightarrow",!0),rT(nT,aT,gT,"⇍","\\nLeftarrow",!0),rT(nT,aT,gT,"⇏","\\nRightarrow",!0),rT(nT,aT,gT,"↮","\\nleftrightarrow",!0),rT(nT,aT,gT,"⇎","\\nLeftrightarrow",!0),rT(nT,aT,gT,"△","\\vartriangle"),rT(nT,aT,vT,"ℏ","\\hslash"),rT(nT,aT,vT,"▽","\\triangledown"),rT(nT,aT,vT,"◊","\\lozenge"),rT(nT,aT,vT,"Ⓢ","\\circledS"),rT(nT,aT,vT,"®","\\circledR"),rT(oT,aT,vT,"®","\\circledR"),rT(nT,aT,vT,"∡","\\measuredangle",!0),rT(nT,aT,vT,"∄","\\nexists"),rT(nT,aT,vT,"℧","\\mho"),rT(nT,aT,vT,"Ⅎ","\\Finv",!0),rT(nT,aT,vT,"⅁","\\Game",!0),rT(nT,aT,vT,"‵","\\backprime"),rT(nT,aT,vT,"▲","\\blacktriangle"),rT(nT,aT,vT,"▼","\\blacktriangledown"),rT(nT,aT,vT,"■","\\blacksquare"),rT(nT,aT,vT,"⧫","\\blacklozenge"),rT(nT,aT,vT,"★","\\bigstar"),rT(nT,aT,vT,"∢","\\sphericalangle",!0),rT(nT,aT,vT,"∁","\\complement",!0),rT(nT,aT,vT,"ð","\\eth",!0),rT(oT,iT,vT,"ð","ð"),rT(nT,aT,vT,"╱","\\diagup"),rT(nT,aT,vT,"╲","\\diagdown"),rT(nT,aT,vT,"□","\\square"),rT(nT,aT,vT,"□","\\Box"),rT(nT,aT,vT,"◊","\\Diamond"),rT(nT,aT,vT,"¥","\\yen",!0),rT(oT,aT,vT,"¥","\\yen",!0),rT(nT,aT,vT,"✓","\\checkmark",!0),rT(oT,aT,vT,"✓","\\checkmark"),rT(nT,aT,vT,"ℶ","\\beth",!0),rT(nT,aT,vT,"ℸ","\\daleth",!0),rT(nT,aT,vT,"ℷ","\\gimel",!0),rT(nT,aT,vT,"ϝ","\\digamma",!0),rT(nT,aT,vT,"ϰ","\\varkappa"),rT(nT,aT,fT,"┌","\\@ulcorner",!0),rT(nT,aT,lT,"┐","\\@urcorner",!0),rT(nT,aT,fT,"└","\\@llcorner",!0),rT(nT,aT,lT,"┘","\\@lrcorner",!0),rT(nT,aT,gT,"≦","\\leqq",!0),rT(nT,aT,gT,"⩽","\\leqslant",!0),rT(nT,aT,gT,"⪕","\\eqslantless",!0),rT(nT,aT,gT,"≲","\\lesssim",!0),rT(nT,aT,gT,"⪅","\\lessapprox",!0),rT(nT,aT,gT,"≊","\\approxeq",!0),rT(nT,aT,uT,"⋖","\\lessdot"),rT(nT,aT,gT,"⋘","\\lll",!0),rT(nT,aT,gT,"≶","\\lessgtr",!0),rT(nT,aT,gT,"⋚","\\lesseqgtr",!0),rT(nT,aT,gT,"⪋","\\lesseqqgtr",!0),rT(nT,aT,gT,"≑","\\doteqdot"),rT(nT,aT,gT,"≓","\\risingdotseq",!0),rT(nT,aT,gT,"≒","\\fallingdotseq",!0),rT(nT,aT,gT,"∽","\\backsim",!0),rT(nT,aT,gT,"⋍","\\backsimeq",!0),rT(nT,aT,gT,"⫅","\\subseteqq",!0),rT(nT,aT,gT,"⋐","\\Subset",!0),rT(nT,aT,gT,"⊏","\\sqsubset",!0),rT(nT,aT,gT,"≼","\\preccurlyeq",!0),rT(nT,aT,gT,"⋞","\\curlyeqprec",!0),rT(nT,aT,gT,"≾","\\precsim",!0),rT(nT,aT,gT,"⪷","\\precapprox",!0),rT(nT,aT,gT,"⊲","\\vartriangleleft"),rT(nT,aT,gT,"⊴","\\trianglelefteq"),rT(nT,aT,gT,"⊨","\\vDash",!0),rT(nT,aT,gT,"⊪","\\Vvdash",!0),rT(nT,aT,gT,"⌣","\\smallsmile"),rT(nT,aT,gT,"⌢","\\smallfrown"),rT(nT,aT,gT,"≏","\\bumpeq",!0),rT(nT,aT,gT,"≎","\\Bumpeq",!0),rT(nT,aT,gT,"≧","\\geqq",!0),rT(nT,aT,gT,"⩾","\\geqslant",!0),rT(nT,aT,gT,"⪖","\\eqslantgtr",!0),rT(nT,aT,gT,"≳","\\gtrsim",!0),rT(nT,aT,gT,"⪆","\\gtrapprox",!0),rT(nT,aT,uT,"⋗","\\gtrdot"),rT(nT,aT,gT,"⋙","\\ggg",!0),rT(nT,aT,gT,"≷","\\gtrless",!0),rT(nT,aT,gT,"⋛","\\gtreqless",!0),rT(nT,aT,gT,"⪌","\\gtreqqless",!0),rT(nT,aT,gT,"≖","\\eqcirc",!0),rT(nT,aT,gT,"≗","\\circeq",!0),rT(nT,aT,gT,"≜","\\triangleq",!0),rT(nT,aT,gT,"∼","\\thicksim"),rT(nT,aT,gT,"≈","\\thickapprox"),rT(nT,aT,gT,"⫆","\\supseteqq",!0),rT(nT,aT,gT,"⋑","\\Supset",!0),rT(nT,aT,gT,"⊐","\\sqsupset",!0),rT(nT,aT,gT,"≽","\\succcurlyeq",!0),rT(nT,aT,gT,"⋟","\\curlyeqsucc",!0),rT(nT,aT,gT,"≿","\\succsim",!0),rT(nT,aT,gT,"⪸","\\succapprox",!0),rT(nT,aT,gT,"⊳","\\vartriangleright"),rT(nT,aT,gT,"⊵","\\trianglerighteq"),rT(nT,aT,gT,"⊩","\\Vdash",!0),rT(nT,aT,gT,"∣","\\shortmid"),rT(nT,aT,gT,"∥","\\shortparallel"),rT(nT,aT,gT,"≬","\\between",!0),rT(nT,aT,gT,"⋔","\\pitchfork",!0),rT(nT,aT,gT,"∝","\\varpropto"),rT(nT,aT,gT,"◀","\\blacktriangleleft"),rT(nT,aT,gT,"∴","\\therefore",!0),rT(nT,aT,gT,"∍","\\backepsilon"),rT(nT,aT,gT,"▶","\\blacktriangleright"),rT(nT,aT,gT,"∵","\\because",!0),rT(nT,aT,gT,"⋘","\\llless"),rT(nT,aT,gT,"⋙","\\gggtr"),rT(nT,aT,uT,"⊲","\\lhd"),rT(nT,aT,uT,"⊳","\\rhd"),rT(nT,aT,gT,"≂","\\eqsim",!0),rT(nT,iT,gT,"⋈","\\Join"),rT(nT,aT,gT,"≑","\\Doteq",!0),rT(nT,aT,uT,"∔","\\dotplus",!0),rT(nT,aT,uT,"∖","\\smallsetminus"),rT(nT,aT,uT,"⋒","\\Cap",!0),rT(nT,aT,uT,"⋓","\\Cup",!0),rT(nT,aT,uT,"⩞","\\doublebarwedge",!0),rT(nT,aT,uT,"⊟","\\boxminus",!0),rT(nT,aT,uT,"⊞","\\boxplus",!0),rT(nT,aT,uT,"⋇","\\divideontimes",!0),rT(nT,aT,uT,"⋉","\\ltimes",!0),rT(nT,aT,uT,"⋊","\\rtimes",!0),rT(nT,aT,uT,"⋋","\\leftthreetimes",!0),rT(nT,aT,uT,"⋌","\\rightthreetimes",!0),rT(nT,aT,uT,"⋏","\\curlywedge",!0),rT(nT,aT,uT,"⋎","\\curlyvee",!0),rT(nT,aT,uT,"⊝","\\circleddash",!0),rT(nT,aT,uT,"⊛","\\circledast",!0),rT(nT,aT,uT,"⋅","\\centerdot"),rT(nT,aT,uT,"⊺","\\intercal",!0),rT(nT,aT,uT,"⋒","\\doublecap"),rT(nT,aT,uT,"⋓","\\doublecup"),rT(nT,aT,uT,"⊠","\\boxtimes",!0),rT(nT,aT,gT,"⇢","\\dashrightarrow",!0),rT(nT,aT,gT,"⇠","\\dashleftarrow",!0),rT(nT,aT,gT,"⇇","\\leftleftarrows",!0),rT(nT,aT,gT,"⇆","\\leftrightarrows",!0),rT(nT,aT,gT,"⇚","\\Lleftarrow",!0),rT(nT,aT,gT,"↞","\\twoheadleftarrow",!0),rT(nT,aT,gT,"↢","\\leftarrowtail",!0),rT(nT,aT,gT,"↫","\\looparrowleft",!0),rT(nT,aT,gT,"⇋","\\leftrightharpoons",!0),rT(nT,aT,gT,"↶","\\curvearrowleft",!0),rT(nT,aT,gT,"↺","\\circlearrowleft",!0),rT(nT,aT,gT,"↰","\\Lsh",!0),rT(nT,aT,gT,"⇈","\\upuparrows",!0),rT(nT,aT,gT,"↿","\\upharpoonleft",!0),rT(nT,aT,gT,"⇃","\\downharpoonleft",!0),rT(nT,iT,gT,"⊶","\\origof",!0),rT(nT,iT,gT,"⊷","\\imageof",!0),rT(nT,aT,gT,"⊸","\\multimap",!0),rT(nT,aT,gT,"↭","\\leftrightsquigarrow",!0),rT(nT,aT,gT,"⇉","\\rightrightarrows",!0),rT(nT,aT,gT,"⇄","\\rightleftarrows",!0),rT(nT,aT,gT,"↠","\\twoheadrightarrow",!0),rT(nT,aT,gT,"↣","\\rightarrowtail",!0),rT(nT,aT,gT,"↬","\\looparrowright",!0),rT(nT,aT,gT,"↷","\\curvearrowright",!0),rT(nT,aT,gT,"↻","\\circlearrowright",!0),rT(nT,aT,gT,"↱","\\Rsh",!0),rT(nT,aT,gT,"⇊","\\downdownarrows",!0),rT(nT,aT,gT,"↾","\\upharpoonright",!0),rT(nT,aT,gT,"⇂","\\downharpoonright",!0),rT(nT,aT,gT,"⇝","\\rightsquigarrow",!0),rT(nT,aT,gT,"⇝","\\leadsto"),rT(nT,aT,gT,"⇛","\\Rrightarrow",!0),rT(nT,aT,gT,"↾","\\restriction"),rT(nT,iT,vT,"‘","`"),rT(nT,iT,vT,"$","\\$"),rT(oT,iT,vT,"$","\\$"),rT(oT,iT,vT,"$","\\textdollar"),rT(nT,iT,vT,"%","\\%"),rT(oT,iT,vT,"%","\\%"),rT(nT,iT,vT,"_","\\_"),rT(oT,iT,vT,"_","\\_"),rT(oT,iT,vT,"_","\\textunderscore"),rT(nT,iT,vT,"∠","\\angle",!0),rT(nT,iT,vT,"∞","\\infty",!0),rT(nT,iT,vT,"′","\\prime"),rT(nT,iT,vT,"△","\\triangle"),rT(nT,iT,vT,"Γ","\\Gamma",!0),rT(nT,iT,vT,"Δ","\\Delta",!0),rT(nT,iT,vT,"Θ","\\Theta",!0),rT(nT,iT,vT,"Λ","\\Lambda",!0),rT(nT,iT,vT,"Ξ","\\Xi",!0),rT(nT,iT,vT,"Π","\\Pi",!0),rT(nT,iT,vT,"Σ","\\Sigma",!0),rT(nT,iT,vT,"Υ","\\Upsilon",!0),rT(nT,iT,vT,"Φ","\\Phi",!0),rT(nT,iT,vT,"Ψ","\\Psi",!0),rT(nT,iT,vT,"Ω","\\Omega",!0),rT(nT,iT,vT,"A","Α"),rT(nT,iT,vT,"B","Β"),rT(nT,iT,vT,"E","Ε"),rT(nT,iT,vT,"Z","Ζ"),rT(nT,iT,vT,"H","Η"),rT(nT,iT,vT,"I","Ι"),rT(nT,iT,vT,"K","Κ"),rT(nT,iT,vT,"M","Μ"),rT(nT,iT,vT,"N","Ν"),rT(nT,iT,vT,"O","Ο"),rT(nT,iT,vT,"P","Ρ"),rT(nT,iT,vT,"T","Τ"),rT(nT,iT,vT,"X","Χ"),rT(nT,iT,vT,"¬","\\neg",!0),rT(nT,iT,vT,"¬","\\lnot"),rT(nT,iT,vT,"⊤","\\top"),rT(nT,iT,vT,"⊥","\\bot"),rT(nT,iT,vT,"∅","\\emptyset"),rT(nT,aT,vT,"∅","\\varnothing"),rT(nT,iT,dT,"α","\\alpha",!0),rT(nT,iT,dT,"β","\\beta",!0),rT(nT,iT,dT,"γ","\\gamma",!0),rT(nT,iT,dT,"δ","\\delta",!0),rT(nT,iT,dT,"ϵ","\\epsilon",!0),rT(nT,iT,dT,"ζ","\\zeta",!0),rT(nT,iT,dT,"η","\\eta",!0),rT(nT,iT,dT,"θ","\\theta",!0),rT(nT,iT,dT,"ι","\\iota",!0),rT(nT,iT,dT,"κ","\\kappa",!0),rT(nT,iT,dT,"λ","\\lambda",!0),rT(nT,iT,dT,"μ","\\mu",!0),rT(nT,iT,dT,"ν","\\nu",!0),rT(nT,iT,dT,"ξ","\\xi",!0),rT(nT,iT,dT,"ο","\\omicron",!0),rT(nT,iT,dT,"π","\\pi",!0),rT(nT,iT,dT,"ρ","\\rho",!0),rT(nT,iT,dT,"σ","\\sigma",!0),rT(nT,iT,dT,"τ","\\tau",!0),rT(nT,iT,dT,"υ","\\upsilon",!0),rT(nT,iT,dT,"ϕ","\\phi",!0),rT(nT,iT,dT,"χ","\\chi",!0),rT(nT,iT,dT,"ψ","\\psi",!0),rT(nT,iT,dT,"ω","\\omega",!0),rT(nT,iT,dT,"ε","\\varepsilon",!0),rT(nT,iT,dT,"ϑ","\\vartheta",!0),rT(nT,iT,dT,"ϖ","\\varpi",!0),rT(nT,iT,dT,"ϱ","\\varrho",!0),rT(nT,iT,dT,"ς","\\varsigma",!0),rT(nT,iT,dT,"φ","\\varphi",!0),rT(nT,iT,uT,"∗","*",!0),rT(nT,iT,uT,"+","+"),rT(nT,iT,uT,"−","-",!0),rT(nT,iT,uT,"⋅","\\cdot",!0),rT(nT,iT,uT,"∘","\\circ",!0),rT(nT,iT,uT,"÷","\\div",!0),rT(nT,iT,uT,"±","\\pm",!0),rT(nT,iT,uT,"×","\\times",!0),rT(nT,iT,uT,"∩","\\cap",!0),rT(nT,iT,uT,"∪","\\cup",!0),rT(nT,iT,uT,"∖","\\setminus",!0),rT(nT,iT,uT,"∧","\\land"),rT(nT,iT,uT,"∨","\\lor"),rT(nT,iT,uT,"∧","\\wedge",!0),rT(nT,iT,uT,"∨","\\vee",!0),rT(nT,iT,vT,"√","\\surd"),rT(nT,iT,fT,"⟨","\\langle",!0),rT(nT,iT,fT,"∣","\\lvert"),rT(nT,iT,fT,"∥","\\lVert"),rT(nT,iT,lT,"?","?"),rT(nT,iT,lT,"!","!"),rT(nT,iT,lT,"⟩","\\rangle",!0),rT(nT,iT,lT,"∣","\\rvert"),rT(nT,iT,lT,"∥","\\rVert"),rT(nT,iT,gT,"=","="),rT(nT,iT,gT,":",":"),rT(nT,iT,gT,"≈","\\approx",!0),rT(nT,iT,gT,"≅","\\cong",!0),rT(nT,iT,gT,"≥","\\ge"),rT(nT,iT,gT,"≥","\\geq",!0),rT(nT,iT,gT,"←","\\gets"),rT(nT,iT,gT,">","\\gt",!0),rT(nT,iT,gT,"∈","\\in",!0),rT(nT,iT,gT,"","\\@not"),rT(nT,iT,gT,"⊂","\\subset",!0),rT(nT,iT,gT,"⊃","\\supset",!0),rT(nT,iT,gT,"⊆","\\subseteq",!0),rT(nT,iT,gT,"⊇","\\supseteq",!0),rT(nT,aT,gT,"⊈","\\nsubseteq",!0),rT(nT,aT,gT,"⊉","\\nsupseteq",!0),rT(nT,iT,gT,"⊨","\\models"),rT(nT,iT,gT,"←","\\leftarrow",!0),rT(nT,iT,gT,"≤","\\le"),rT(nT,iT,gT,"≤","\\leq",!0),rT(nT,iT,gT,"<","\\lt",!0),rT(nT,iT,gT,"→","\\rightarrow",!0),rT(nT,iT,gT,"→","\\to"),rT(nT,aT,gT,"≱","\\ngeq",!0),rT(nT,aT,gT,"≰","\\nleq",!0),rT(nT,iT,mT," ","\\ "),rT(nT,iT,mT," ","\\space"),rT(nT,iT,mT," ","\\nobreakspace"),rT(oT,iT,mT," ","\\ "),rT(oT,iT,mT," "," "),rT(oT,iT,mT," ","\\space"),rT(oT,iT,mT," ","\\nobreakspace"),rT(nT,iT,mT,null,"\\nobreak"),rT(nT,iT,mT,null,"\\allowbreak"),rT(nT,iT,pT,",",","),rT(nT,iT,pT,";",";"),rT(nT,aT,uT,"⊼","\\barwedge",!0),rT(nT,aT,uT,"⊻","\\veebar",!0),rT(nT,iT,uT,"⊙","\\odot",!0),rT(nT,iT,uT,"⊕","\\oplus",!0),rT(nT,iT,uT,"⊗","\\otimes",!0),rT(nT,iT,vT,"∂","\\partial",!0),rT(nT,iT,uT,"⊘","\\oslash",!0),rT(nT,aT,uT,"⊚","\\circledcirc",!0),rT(nT,aT,uT,"⊡","\\boxdot",!0),rT(nT,iT,uT,"△","\\bigtriangleup"),rT(nT,iT,uT,"▽","\\bigtriangledown"),rT(nT,iT,uT,"†","\\dagger"),rT(nT,iT,uT,"⋄","\\diamond"),rT(nT,iT,uT,"⋆","\\star"),rT(nT,iT,uT,"◃","\\triangleleft"),rT(nT,iT,uT,"▹","\\triangleright"),rT(nT,iT,fT,"{","\\{"),rT(oT,iT,vT,"{","\\{"),rT(oT,iT,vT,"{","\\textbraceleft"),rT(nT,iT,lT,"}","\\}"),rT(oT,iT,vT,"}","\\}"),rT(oT,iT,vT,"}","\\textbraceright"),rT(nT,iT,fT,"{","\\lbrace"),rT(nT,iT,lT,"}","\\rbrace"),rT(nT,iT,fT,"[","\\lbrack",!0),rT(oT,iT,vT,"[","\\lbrack",!0),rT(nT,iT,lT,"]","\\rbrack",!0),rT(oT,iT,vT,"]","\\rbrack",!0),rT(nT,iT,fT,"(","\\lparen",!0),rT(nT,iT,lT,")","\\rparen",!0),rT(oT,iT,vT,"<","\\textless",!0),rT(oT,iT,vT,">","\\textgreater",!0),rT(nT,iT,fT,"⌊","\\lfloor",!0),rT(nT,iT,lT,"⌋","\\rfloor",!0),rT(nT,iT,fT,"⌈","\\lceil",!0),rT(nT,iT,lT,"⌉","\\rceil",!0),rT(nT,iT,vT,"\\","\\backslash"),rT(nT,iT,vT,"∣","|"),rT(nT,iT,vT,"∣","\\vert"),rT(oT,iT,vT,"|","\\textbar",!0),rT(nT,iT,vT,"∥","\\|"),rT(nT,iT,vT,"∥","\\Vert"),rT(oT,iT,vT,"∥","\\textbardbl"),rT(oT,iT,vT,"~","\\textasciitilde"),rT(oT,iT,vT,"\\","\\textbackslash"),rT(oT,iT,vT,"^","\\textasciicircum"),rT(nT,iT,gT,"↑","\\uparrow",!0),rT(nT,iT,gT,"⇑","\\Uparrow",!0),rT(nT,iT,gT,"↓","\\downarrow",!0),rT(nT,iT,gT,"⇓","\\Downarrow",!0),rT(nT,iT,gT,"↕","\\updownarrow",!0),rT(nT,iT,gT,"⇕","\\Updownarrow",!0),rT(nT,iT,hT,"∐","\\coprod"),rT(nT,iT,hT,"⋁","\\bigvee"),rT(nT,iT,hT,"⋀","\\bigwedge"),rT(nT,iT,hT,"⨄","\\biguplus"),rT(nT,iT,hT,"⋂","\\bigcap"),rT(nT,iT,hT,"⋃","\\bigcup"),rT(nT,iT,hT,"∫","\\int"),rT(nT,iT,hT,"∫","\\intop"),rT(nT,iT,hT,"∬","\\iint"),rT(nT,iT,hT,"∭","\\iiint"),rT(nT,iT,hT,"∏","\\prod"),rT(nT,iT,hT,"∑","\\sum"),rT(nT,iT,hT,"⨂","\\bigotimes"),rT(nT,iT,hT,"⨁","\\bigoplus"),rT(nT,iT,hT,"⨀","\\bigodot"),rT(nT,iT,hT,"∮","\\oint"),rT(nT,iT,hT,"∯","\\oiint"),rT(nT,iT,hT,"∰","\\oiiint"),rT(nT,iT,hT,"⨆","\\bigsqcup"),rT(nT,iT,hT,"∫","\\smallint"),rT(oT,iT,cT,"…","\\textellipsis"),rT(nT,iT,cT,"…","\\mathellipsis"),rT(oT,iT,cT,"…","\\ldots",!0),rT(nT,iT,cT,"…","\\ldots",!0),rT(nT,iT,cT,"⋯","\\@cdots",!0),rT(nT,iT,cT,"⋱","\\ddots",!0),rT(nT,iT,vT,"⋮","\\varvdots"),rT(oT,iT,vT,"⋮","\\varvdots"),rT(nT,iT,sT,"ˊ","\\acute"),rT(nT,iT,sT,"ˋ","\\grave"),rT(nT,iT,sT,"¨","\\ddot"),rT(nT,iT,sT,"~","\\tilde"),rT(nT,iT,sT,"ˉ","\\bar"),rT(nT,iT,sT,"˘","\\breve"),rT(nT,iT,sT,"ˇ","\\check"),rT(nT,iT,sT,"^","\\hat"),rT(nT,iT,sT,"⃗","\\vec"),rT(nT,iT,sT,"˙","\\dot"),rT(nT,iT,sT,"˚","\\mathring"),rT(nT,iT,dT,"","\\@imath"),rT(nT,iT,dT,"","\\@jmath"),rT(nT,iT,vT,"ı","ı"),rT(nT,iT,vT,"ȷ","ȷ"),rT(oT,iT,vT,"ı","\\i",!0),rT(oT,iT,vT,"ȷ","\\j",!0),rT(oT,iT,vT,"ß","\\ss",!0),rT(oT,iT,vT,"æ","\\ae",!0),rT(oT,iT,vT,"œ","\\oe",!0),rT(oT,iT,vT,"ø","\\o",!0),rT(oT,iT,vT,"Æ","\\AE",!0),rT(oT,iT,vT,"Œ","\\OE",!0),rT(oT,iT,vT,"Ø","\\O",!0),rT(oT,iT,sT,"ˊ","\\'"),rT(oT,iT,sT,"ˋ","\\`"),rT(oT,iT,sT,"ˆ","\\^"),rT(oT,iT,sT,"˜","\\~"),rT(oT,iT,sT,"ˉ","\\="),rT(oT,iT,sT,"˘","\\u"),rT(oT,iT,sT,"˙","\\."),rT(oT,iT,sT,"¸","\\c"),rT(oT,iT,sT,"˚","\\r"),rT(oT,iT,sT,"ˇ","\\v"),rT(oT,iT,sT,"¨",'\\"'),rT(oT,iT,sT,"˝","\\H"),rT(oT,iT,sT,"◯","\\textcircled");var yT={"--":!0,"---":!0,"``":!0,"''":!0};rT(oT,iT,vT,"–","--",!0),rT(oT,iT,vT,"–","\\textendash"),rT(oT,iT,vT,"—","---",!0),rT(oT,iT,vT,"—","\\textemdash"),rT(oT,iT,vT,"‘","`",!0),rT(oT,iT,vT,"‘","\\textquoteleft"),rT(oT,iT,vT,"’","'",!0),rT(oT,iT,vT,"’","\\textquoteright"),rT(oT,iT,vT,"“","``",!0),rT(oT,iT,vT,"“","\\textquotedblleft"),rT(oT,iT,vT,"”","''",!0),rT(oT,iT,vT,"”","\\textquotedblright"),rT(nT,iT,vT,"°","\\degree",!0),rT(oT,iT,vT,"°","\\degree"),rT(oT,iT,vT,"°","\\textdegree",!0),rT(nT,iT,vT,"£","\\pounds"),rT(nT,iT,vT,"£","\\mathsterling",!0),rT(oT,iT,vT,"£","\\pounds"),rT(oT,iT,vT,"£","\\textsterling",!0),rT(nT,aT,vT,"✠","\\maltese"),rT(oT,aT,vT,"✠","\\maltese");for(var bT='0123456789/@."',DT=0;DT<14;DT++){var CT=bT.charAt(DT);rT(nT,iT,vT,CT,CT)}for(var wT='0123456789!@*()-=+";:?/.,',ET=0;ET<25;ET++){var AT=wT.charAt(ET);rT(oT,iT,vT,AT,AT)}for(var xT="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz",BT=0;BT<52;BT++){var ST=xT.charAt(BT);rT(nT,iT,dT,ST,ST),rT(oT,iT,vT,ST,ST)}rT(nT,aT,vT,"C","ℂ"),rT(oT,aT,vT,"C","ℂ"),rT(nT,aT,vT,"H","ℍ"),rT(oT,aT,vT,"H","ℍ"),rT(nT,aT,vT,"N","ℕ"),rT(oT,aT,vT,"N","ℕ"),rT(nT,aT,vT,"P","ℙ"),rT(oT,aT,vT,"P","ℙ"),rT(nT,aT,vT,"Q","ℚ"),rT(oT,aT,vT,"Q","ℚ"),rT(nT,aT,vT,"R","ℝ"),rT(oT,aT,vT,"R","ℝ"),rT(nT,aT,vT,"Z","ℤ"),rT(oT,aT,vT,"Z","ℤ"),rT(nT,iT,dT,"h","ℎ"),rT(oT,iT,dT,"h","ℎ");for(var FT="",kT=0;kT<52;kT++){var OT=xT.charAt(kT);rT(nT,iT,dT,OT,FT=String.fromCharCode(55349,56320+kT)),rT(oT,iT,vT,OT,FT),rT(nT,iT,dT,OT,FT=String.fromCharCode(55349,56372+kT)),rT(oT,iT,vT,OT,FT),rT(nT,iT,dT,OT,FT=String.fromCharCode(55349,56424+kT)),rT(oT,iT,vT,OT,FT),rT(nT,iT,dT,OT,FT=String.fromCharCode(55349,56580+kT)),rT(oT,iT,vT,OT,FT),rT(nT,iT,dT,OT,FT=String.fromCharCode(55349,56684+kT)),rT(oT,iT,vT,OT,FT),rT(nT,iT,dT,OT,FT=String.fromCharCode(55349,56736+kT)),rT(oT,iT,vT,OT,FT),rT(nT,iT,dT,OT,FT=String.fromCharCode(55349,56788+kT)),rT(oT,iT,vT,OT,FT),rT(nT,iT,dT,OT,FT=String.fromCharCode(55349,56840+kT)),rT(oT,iT,vT,OT,FT),rT(nT,iT,dT,OT,FT=String.fromCharCode(55349,56944+kT)),rT(oT,iT,vT,OT,FT),kT<26&&(rT(nT,iT,dT,OT,FT=String.fromCharCode(55349,56632+kT)),rT(oT,iT,vT,OT,FT),rT(nT,iT,dT,OT,FT=String.fromCharCode(55349,56476+kT)),rT(oT,iT,vT,OT,FT))}rT(nT,iT,dT,"k",FT=String.fromCharCode(55349,56668)),rT(oT,iT,vT,"k",FT);for(var TT=0;TT<10;TT++){var NT=TT.toString();rT(nT,iT,dT,NT,FT=String.fromCharCode(55349,57294+TT)),rT(oT,iT,vT,NT,FT),rT(nT,iT,dT,NT,FT=String.fromCharCode(55349,57314+TT)),rT(oT,iT,vT,NT,FT),rT(nT,iT,dT,NT,FT=String.fromCharCode(55349,57324+TT)),rT(oT,iT,vT,NT,FT),rT(nT,iT,dT,NT,FT=String.fromCharCode(55349,57334+TT)),rT(oT,iT,vT,NT,FT)}for(var PT="ÐÞþ",MT=0;MT<3;MT++){var IT=PT.charAt(MT);rT(nT,iT,dT,IT,IT),rT(oT,iT,vT,IT,IT)}var RT=[["mathbf","textbf","Main-Bold"],["mathbf","textbf","Main-Bold"],["mathnormal","textit","Math-Italic"],["mathnormal","textit","Math-Italic"],["boldsymbol","boldsymbol","Main-BoldItalic"],["boldsymbol","boldsymbol","Main-BoldItalic"],["mathscr","textscr","Script-Regular"],["","",""],["","",""],["","",""],["mathfrak","textfrak","Fraktur-Regular"],["mathfrak","textfrak","Fraktur-Regular"],["mathbb","textbb","AMS-Regular"],["mathbb","textbb","AMS-Regular"],["mathboldfrak","textboldfrak","Fraktur-Regular"],["mathboldfrak","textboldfrak","Fraktur-Regular"],["mathsf","textsf","SansSerif-Regular"],["mathsf","textsf","SansSerif-Regular"],["mathboldsf","textboldsf","SansSerif-Bold"],["mathboldsf","textboldsf","SansSerif-Bold"],["mathitsf","textitsf","SansSerif-Italic"],["mathitsf","textitsf","SansSerif-Italic"],["","",""],["","",""],["mathtt","texttt","Typewriter-Regular"],["mathtt","texttt","Typewriter-Regular"]],LT=[["mathbf","textbf","Main-Bold"],["","",""],["mathsf","textsf","SansSerif-Regular"],["mathboldsf","textboldsf","SansSerif-Bold"],["mathtt","texttt","Typewriter-Regular"]],_T=function(e,t,r){return tT[r][e]&&tT[r][e].replace&&(e=tT[r][e].replace),{value:e,metrics:FO(e,t,r)}},zT=function(e,t,r,n,o){var i,a=_T(e,t,r),s=a.metrics;if(e=a.value,s){var u=s.italic;("text"===r||n&&"mathit"===n.font)&&(u=0),i=new YO(e,s.height,s.depth,u,s.skew,s.width,o)}else"undefined"!=typeof console&&console.warn("No character metrics for '"+e+"' in style '"+t+"' and mode '"+r+"'"),i=new YO(e,0,0,0,0,0,o);if(n){i.maxFontSize=n.sizeMultiplier,n.style.isTight()&&i.classes.push("mtight");var l=n.getColor();l&&(i.style.color=l)}return i},jT=(e,t)=>{if(zO(e.classes)!==zO(t.classes)||e.skew!==t.skew||e.maxFontSize!==t.maxFontSize)return!1;if(1===e.classes.length){var r=e.classes[0];if("mbin"===r||"mord"===r)return!1}for(var n in e.style)if(e.style.hasOwnProperty(n)&&e.style[n]!==t.style[n])return!1;for(var o in t.style)if(t.style.hasOwnProperty(o)&&e.style[o]!==t.style[o])return!1;return!0},HT=function(e){for(var t=0,r=0,n=0,o=0;o<e.children.length;o++){var i=e.children[o];i.height>t&&(t=i.height),i.depth>r&&(r=i.depth),i.maxFontSize>n&&(n=i.maxFontSize)}e.height=t,e.depth=r,e.maxFontSize=n},VT=function(e,t,r,n){var o=new UO(e,t,r,n);return HT(o),o},$T=(e,t,r,n)=>new UO(e,t,r,n),UT=function(e){var t=new AO(e);return HT(t),t},qT=function(e,t,r){var n="";switch(e){case"amsrm":n="AMS";break;case"textrm":n="Main";break;case"textsf":n="SansSerif";break;case"texttt":n="Typewriter";break;default:n=e}return n+"-"+("textbf"===t&&"textit"===r?"BoldItalic":"textbf"===t?"Bold":"textit"===t?"Italic":"Regular")},WT={mathbf:{variant:"bold",fontName:"Main-Bold"},mathrm:{variant:"normal",fontName:"Main-Regular"},textit:{variant:"italic",fontName:"Main-Italic"},mathit:{variant:"italic",fontName:"Main-Italic"},mathnormal:{variant:"italic",fontName:"Math-Italic"},mathsfit:{variant:"sans-serif-italic",fontName:"SansSerif-Italic"},mathbb:{variant:"double-struck",fontName:"AMS-Regular"},mathcal:{variant:"script",fontName:"Caligraphic-Regular"},mathfrak:{variant:"fraktur",fontName:"Fraktur-Regular"},mathscr:{variant:"script",fontName:"Script-Regular"},mathsf:{variant:"sans-serif",fontName:"SansSerif-Regular"},mathtt:{variant:"monospace",fontName:"Typewriter-Regular"}},GT={vec:["vec",.471,.714],oiintSize1:["oiintSize1",.957,.499],oiintSize2:["oiintSize2",1.472,.659],oiiintSize1:["oiiintSize1",1.304,.499],oiiintSize2:["oiiintSize2",1.98,.659]},YT={fontMap:WT,makeSymbol:zT,mathsym:function(e,t,r,n){return void 0===n&&(n=[]),"boldsymbol"===r.font&&_T(e,"Main-Bold",t).metrics?zT(e,"Main-Bold",t,r,n.concat(["mathbf"])):"\\"===e||"main"===tT[t][e].font?zT(e,"Main-Regular",t,r,n):zT(e,"AMS-Regular",t,r,n.concat(["amsrm"]))},makeSpan:VT,makeSvgSpan:$T,makeLineSpan:function(e,t,r){var n=VT([e],[],t);return n.height=Math.max(r||t.fontMetrics().defaultRuleThickness,t.minRuleThickness),n.style.borderBottomWidth=_O(n.height),n.maxFontSize=1,n},makeAnchor:function(e,t,r,n){var o=new qO(e,t,r,n);return HT(o),o},makeFragment:UT,wrapFragment:function(e,t){return e instanceof AO?VT([],[e],t):e},makeVList:function(e,t){for(var{children:r,depth:n}=function(e){if("individualShift"===e.positionType){for(var t=e.children,r=[t[0]],n=-t[0].shift-t[0].elem.depth,o=n,i=1;i<t.length;i++){var a=-t[i].shift-o-t[i].elem.depth,s=a-(t[i-1].elem.height+t[i-1].elem.depth);o+=a,r.push({type:"kern",size:s}),r.push(t[i])}return{children:r,depth:n}}var u;if("top"===e.positionType){for(var l=e.positionData,c=0;c<e.children.length;c++){var d=e.children[c];l-="kern"===d.type?d.size:d.elem.height+d.elem.depth}u=l}else if("bottom"===e.positionType)u=-e.positionData;else{var h=e.children[0];if("elem"!==h.type)throw new Error('First child must have type "elem".');if("shift"===e.positionType)u=-h.elem.depth-e.positionData;else{if("firstBaseline"!==e.positionType)throw new Error("Invalid positionType "+e.positionType+".");u=-h.elem.depth}}return{children:e.children,depth:u}}(e),o=0,i=0;i<r.length;i++){var a=r[i];if("elem"===a.type){var s=a.elem;o=Math.max(o,s.maxFontSize,s.height)}}o+=2;var u=VT(["pstrut"],[]);u.style.height=_O(o);for(var l=[],c=n,d=n,h=n,f=0;f<r.length;f++){var p=r[f];if("kern"===p.type)h+=p.size;else{var g=p.elem,m=p.wrapperClasses||[],v=p.wrapperStyle||{},y=VT(m,[u,g],void 0,v);y.style.top=_O(-o-h-g.depth),p.marginLeft&&(y.style.marginLeft=p.marginLeft),p.marginRight&&(y.style.marginRight=p.marginRight),l.push(y),h+=g.height+g.depth}c=Math.min(c,h),d=Math.max(d,h)}var b,D=VT(["vlist"],l);if(D.style.height=_O(d),c<0){var C=VT([],[]),w=VT(["vlist"],[C]);w.style.height=_O(-c);var E=VT(["vlist-s"],[new YO("")]);b=[VT(["vlist-r"],[D,E]),VT(["vlist-r"],[w])]}else b=[VT(["vlist-r"],[D])];var A=VT(["vlist-t"],b);return 2===b.length&&A.classes.push("vlist-t2"),A.height=d,A.depth=-c,A},makeOrd:function(e,t,r){var n=e.mode,o=e.text,i=["mord"],a="math"===n||"text"===n&&t.font,s=a?t.font:t.fontFamily,u="",l="";if(55349===o.charCodeAt(0)&&([u,l]=function(e,t){var r=1024*(e.charCodeAt(0)-55296)+(e.charCodeAt(1)-56320)+65536,n="math"===t?0:1;if(119808<=r&&r<120484){var o=Math.floor((r-119808)/26);return[RT[o][2],RT[o][n]]}if(120782<=r&&r<=120831){var i=Math.floor((r-120782)/10);return[LT[i][2],LT[i][n]]}if(120485===r||120486===r)return[RT[0][2],RT[0][n]];if(120486<r&&r<120782)return["",""];throw new tO("Unsupported character: "+e)}(o,n)),u.length>0)return zT(o,u,n,t,i.concat(l));if(s){var c,d;if("boldsymbol"===s){var h=function(e,t,r,n,o){return"textord"!==o&&_T(e,"Math-BoldItalic",t).metrics?{fontName:"Math-BoldItalic",fontClass:"boldsymbol"}:{fontName:"Main-Bold",fontClass:"mathbf"}}(o,n,0,0,r);c=h.fontName,d=[h.fontClass]}else a?(c=WT[s].fontName,d=[s]):(c=qT(s,t.fontWeight,t.fontShape),d=[s,t.fontWeight,t.fontShape]);if(_T(o,c,n).metrics)return zT(o,c,n,t,i.concat(d));if(yT.hasOwnProperty(o)&&"Typewriter"===c.slice(0,10)){for(var f=[],p=0;p<o.length;p++)f.push(zT(o[p],c,n,t,i.concat(d)));return UT(f)}}if("mathord"===r)return zT(o,"Math-Italic",n,t,i.concat(["mathnormal"]));if("textord"===r){var g=tT[n][o]&&tT[n][o].font;if("ams"===g){var m=qT("amsrm",t.fontWeight,t.fontShape);return zT(o,m,n,t,i.concat("amsrm",t.fontWeight,t.fontShape))}if("main"!==g&&g){var v=qT(g,t.fontWeight,t.fontShape);return zT(o,v,n,t,i.concat(v,t.fontWeight,t.fontShape))}var y=qT("textrm",t.fontWeight,t.fontShape);return zT(o,y,n,t,i.concat(t.fontWeight,t.fontShape))}throw new Error("unexpected type: "+r+" in makeOrd")},makeGlue:(e,t)=>{var r=VT(["mspace"],[],t),n=LO(e,t);return r.style.marginRight=_O(n),r},staticSvg:function(e,t){var[r,n,o]=GT[e],i=new XO(r),a=new KO([i],{width:_O(n),height:_O(o),style:"width:"+_O(n),viewBox:"0 0 "+1e3*n+" "+1e3*o,preserveAspectRatio:"xMinYMin"}),s=$T(["overlay"],[a],t);return s.height=o,s.style.height=_O(o),s.style.width=_O(n),s},svgData:GT,tryCombineChars:e=>{for(var t=0;t<e.length-1;t++){var r=e[t],n=e[t+1];r instanceof YO&&n instanceof YO&&jT(r,n)&&(r.text+=n.text,r.height=Math.max(r.height,n.height),r.depth=Math.max(r.depth,n.depth),r.italic=n.italic,e.splice(t+1,1),t--)}return e}},KT={number:3,unit:"mu"},XT={number:4,unit:"mu"},ZT={number:5,unit:"mu"},JT={mord:{mop:KT,mbin:XT,mrel:ZT,minner:KT},mop:{mord:KT,mop:KT,mrel:ZT,minner:KT},mbin:{mord:XT,mop:XT,mopen:XT,minner:XT},mrel:{mord:ZT,mop:ZT,mopen:ZT,minner:ZT},mopen:{},mclose:{mop:KT,mbin:XT,mrel:ZT,minner:KT},mpunct:{mord:KT,mop:KT,mrel:ZT,mopen:KT,mclose:KT,mpunct:KT,minner:KT},minner:{mord:KT,mop:KT,mbin:XT,mrel:ZT,mopen:KT,mpunct:KT,minner:KT}},QT={mord:{mop:KT},mop:{mord:KT,mop:KT},mbin:{},mrel:{},mopen:{},mclose:{mop:KT},mpunct:{},minner:{mop:KT}},eN={},tN={},rN={};function nN(e){for(var{type:t,names:r,props:n,handler:o,htmlBuilder:i,mathmlBuilder:a}=e,s={type:t,numArgs:n.numArgs,argTypes:n.argTypes,allowedInArgument:!!n.allowedInArgument,allowedInText:!!n.allowedInText,allowedInMath:void 0===n.allowedInMath||n.allowedInMath,numOptionalArgs:n.numOptionalArgs||0,infix:!!n.infix,primitive:!!n.primitive,handler:o},u=0;u<r.length;++u)eN[r[u]]=s;t&&(i&&(tN[t]=i),a&&(rN[t]=a))}function oN(e){var{type:t,htmlBuilder:r,mathmlBuilder:n}=e;nN({type:t,names:[],props:{numArgs:0},handler(){throw new Error("Should never be called.")},htmlBuilder:r,mathmlBuilder:n})}var iN=function(e){return"ordgroup"===e.type&&1===e.body.length?e.body[0]:e},aN=function(e){return"ordgroup"===e.type?e.body:[e]},sN=YT.makeSpan,uN=["leftmost","mbin","mopen","mrel","mop","mpunct"],lN=["rightmost","mrel","mclose","mpunct"],cN={display:yO.DISPLAY,text:yO.TEXT,script:yO.SCRIPT,scriptscript:yO.SCRIPTSCRIPT},dN={mord:"mord",mop:"mop",mbin:"mbin",mrel:"mrel",mopen:"mopen",mclose:"mclose",mpunct:"mpunct",minner:"minner"},hN=function(e,t,r,n){void 0===n&&(n=[null,null]);for(var o=[],i=0;i<e.length;i++){var a=yN(e[i],t);if(a instanceof AO){var s=a.children;o.push(...s)}else o.push(a)}if(YT.tryCombineChars(o),!r)return o;var u=t;if(1===e.length){var l=e[0];"sizing"===l.type?u=t.havingSize(l.size):"styling"===l.type&&(u=t.havingStyle(cN[l.style]))}var c=sN([n[0]||"leftmost"],[],t),d=sN([n[1]||"rightmost"],[],t),h="root"===r;return fN(o,(e,t)=>{var r=t.classes[0],n=e.classes[0];"mbin"===r&&aO.contains(lN,n)?t.classes[0]="mord":"mbin"===n&&aO.contains(uN,r)&&(e.classes[0]="mord")},{node:c},d,h),fN(o,(e,t)=>{var r=mN(t),n=mN(e),o=r&&n?e.hasClass("mtight")?QT[r][n]:JT[r][n]:null;if(o)return YT.makeGlue(o,u)},{node:c},d,h),o},fN=function e(t,r,n,o,i){o&&t.push(o);for(var a=0;a<t.length;a++){var s=t[a],u=pN(s);if(u)e(u.children,r,n,null,i);else{var l=!s.hasClass("mspace");if(l){var c=r(s,n.node);c&&(n.insertAfter?n.insertAfter(c):(t.unshift(c),a++))}l?n.node=s:i&&s.hasClass("newline")&&(n.node=sN(["leftmost"])),n.insertAfter=(e=>r=>{t.splice(e+1,0,r),a++})(a)}}o&&t.pop()},pN=function(e){return e instanceof AO||e instanceof qO||e instanceof UO&&e.hasClass("enclosing")?e:null},gN=function e(t,r){var n=pN(t);if(n){var o=n.children;if(o.length){if("right"===r)return e(o[o.length-1],"right");if("left"===r)return e(o[0],"left")}}return t},mN=function(e,t){return e?(t&&(e=gN(e,t)),dN[e.classes[0]]||null):null},vN=function(e,t){var r=["nulldelimiter"].concat(e.baseSizingClasses());return sN(t.concat(r))},yN=function(e,t,r){if(!e)return sN();if(tN[e.type]){var n=tN[e.type](e,t);if(r&&t.size!==r.size){n=sN(t.sizingClasses(r),[n],t);var o=t.sizeMultiplier/r.sizeMultiplier;n.height*=o,n.depth*=o}return n}throw new tO("Got group of unknown type: '"+e.type+"'")};function bN(e,t){var r=sN(["base"],e,t),n=sN(["strut"]);return n.style.height=_O(r.height+r.depth),r.depth&&(n.style.verticalAlign=_O(-r.depth)),r.children.unshift(n),r}function DN(e,t){var r=null;1===e.length&&"tag"===e[0].type&&(r=e[0].tag,e=e[0].body);var n,o=hN(e,t,"root");2===o.length&&o[1].hasClass("tag")&&(n=o.pop());for(var i,a=[],s=[],u=0;u<o.length;u++)if(s.push(o[u]),o[u].hasClass("mbin")||o[u].hasClass("mrel")||o[u].hasClass("allowbreak")){for(var l=!1;u<o.length-1&&o[u+1].hasClass("mspace")&&!o[u+1].hasClass("newline");)u++,s.push(o[u]),o[u].hasClass("nobreak")&&(l=!0);l||(a.push(bN(s,t)),s=[])}else o[u].hasClass("newline")&&(s.pop(),s.length>0&&(a.push(bN(s,t)),s=[]),a.push(o[u]));s.length>0&&a.push(bN(s,t)),r?((i=bN(hN(r,t,!0))).classes=["tag"],a.push(i)):n&&a.push(n);var c=sN(["katex-html"],a);if(c.setAttribute("aria-hidden","true"),i){var d=i.children[0];d.style.height=_O(c.height+c.depth),c.depth&&(d.style.verticalAlign=_O(-c.depth))}return c}function CN(e){return new AO(e)}class wN{constructor(e,t,r){this.type=void 0,this.attributes=void 0,this.children=void 0,this.classes=void 0,this.type=e,this.attributes={},this.children=t||[],this.classes=r||[]}setAttribute(e,t){this.attributes[e]=t}getAttribute(e){return this.attributes[e]}toNode(){var e=document.createElementNS("http://www.w3.org/1998/Math/MathML",this.type);for(var t in this.attributes)Object.prototype.hasOwnProperty.call(this.attributes,t)&&e.setAttribute(t,this.attributes[t]);this.classes.length>0&&(e.className=zO(this.classes));for(var r=0;r<this.children.length;r++)if(this.children[r]instanceof EN&&this.children[r+1]instanceof EN){for(var n=this.children[r].toText()+this.children[++r].toText();this.children[r+1]instanceof EN;)n+=this.children[++r].toText();e.appendChild(new EN(n).toNode())}else e.appendChild(this.children[r].toNode());return e}toMarkup(){var e="<"+this.type;for(var t in this.attributes)Object.prototype.hasOwnProperty.call(this.attributes,t)&&(e+=" "+t+'="',e+=aO.escape(this.attributes[t]),e+='"');this.classes.length>0&&(e+=' class ="'+aO.escape(zO(this.classes))+'"'),e+=">";for(var r=0;r<this.children.length;r++)e+=this.children[r].toMarkup();return e+="</"+this.type+">"}toText(){return this.children.map(e=>e.toText()).join("")}}class EN{constructor(e){this.text=void 0,this.text=e}toNode(){return document.createTextNode(this.text)}toMarkup(){return aO.escape(this.toText())}toText(){return this.text}}var AN={MathNode:wN,TextNode:EN,SpaceNode:class{constructor(e){this.width=void 0,this.character=void 0,this.width=e,this.character=e>=.05555&&e<=.05556?" ":e>=.1666&&e<=.1667?" ":e>=.2222&&e<=.2223?" ":e>=.2777&&e<=.2778?" ":e>=-.05556&&e<=-.05555?" ":e>=-.1667&&e<=-.1666?" ":e>=-.2223&&e<=-.2222?" ":e>=-.2778&&e<=-.2777?" ":null}toNode(){if(this.character)return document.createTextNode(this.character);var e=document.createElementNS("http://www.w3.org/1998/Math/MathML","mspace");return e.setAttribute("width",_O(this.width)),e}toMarkup(){return this.character?"<mtext>"+this.character+"</mtext>":'<mspace width="'+_O(this.width)+'"/>'}toText(){return this.character?this.character:" "}},newDocumentFragment:CN},xN=function(e,t,r){return!tT[t][e]||!tT[t][e].replace||55349===e.charCodeAt(0)||yT.hasOwnProperty(e)&&r&&(r.fontFamily&&"tt"===r.fontFamily.slice(4,6)||r.font&&"tt"===r.font.slice(4,6))||(e=tT[t][e].replace),new AN.TextNode(e)},BN=function(e){return 1===e.length?e[0]:new AN.MathNode("mrow",e)},SN=function(e,t){if("texttt"===t.fontFamily)return"monospace";if("textsf"===t.fontFamily)return"textit"===t.fontShape&&"textbf"===t.fontWeight?"sans-serif-bold-italic":"textit"===t.fontShape?"sans-serif-italic":"textbf"===t.fontWeight?"bold-sans-serif":"sans-serif";if("textit"===t.fontShape&&"textbf"===t.fontWeight)return"bold-italic";if("textit"===t.fontShape)return"italic";if("textbf"===t.fontWeight)return"bold";var r=t.font;if(!r||"mathnormal"===r)return null;var n=e.mode;if("mathit"===r)return"italic";if("boldsymbol"===r)return"textord"===e.type?"bold":"bold-italic";if("mathbf"===r)return"bold";if("mathbb"===r)return"double-struck";if("mathsfit"===r)return"sans-serif-italic";if("mathfrak"===r)return"fraktur";if("mathscr"===r||"mathcal"===r)return"script";if("mathsf"===r)return"sans-serif";if("mathtt"===r)return"monospace";var o=e.text;return aO.contains(["\\imath","\\jmath"],o)?null:(tT[n][o]&&tT[n][o].replace&&(o=tT[n][o].replace),FO(o,YT.fontMap[r].fontName,n)?YT.fontMap[r].variant:null)};function FN(e){if(!e)return!1;if("mi"===e.type&&1===e.children.length){var t=e.children[0];return t instanceof EN&&"."===t.text}if("mo"===e.type&&1===e.children.length&&"true"===e.getAttribute("separator")&&"0em"===e.getAttribute("lspace")&&"0em"===e.getAttribute("rspace")){var r=e.children[0];return r instanceof EN&&","===r.text}return!1}var kN=function(e,t,r){if(1===e.length){var n=TN(e[0],t);return r&&n instanceof wN&&"mo"===n.type&&(n.setAttribute("lspace","0em"),n.setAttribute("rspace","0em")),[n]}for(var o,i=[],a=0;a<e.length;a++){var s=TN(e[a],t);if(s instanceof wN&&o instanceof wN){if("mtext"===s.type&&"mtext"===o.type&&s.getAttribute("mathvariant")===o.getAttribute("mathvariant")){o.children.push(...s.children);continue}if("mn"===s.type&&"mn"===o.type){o.children.push(...s.children);continue}if(FN(s)&&"mn"===o.type){o.children.push(...s.children);continue}if("mn"===s.type&&FN(o))s.children=[...o.children,...s.children],i.pop();else if(("msup"===s.type||"msub"===s.type)&&s.children.length>=1&&("mn"===o.type||FN(o))){var u=s.children[0];u instanceof wN&&"mn"===u.type&&(u.children=[...o.children,...u.children],i.pop())}else if("mi"===o.type&&1===o.children.length){var l=o.children[0];if(l instanceof EN&&"̸"===l.text&&("mo"===s.type||"mi"===s.type||"mn"===s.type)){var c=s.children[0];c instanceof EN&&c.text.length>0&&(c.text=c.text.slice(0,1)+"̸"+c.text.slice(1),i.pop())}}}i.push(s),o=s}return i},ON=function(e,t,r){return BN(kN(e,t,r))},TN=function(e,t){if(!e)return new AN.MathNode("mrow");if(rN[e.type])return rN[e.type](e,t);throw new tO("Got group of unknown type: '"+e.type+"'")};function NN(e,t,r,n,o){var i,a=kN(e,r);i=1===a.length&&a[0]instanceof wN&&aO.contains(["mrow","mtable"],a[0].type)?a[0]:new AN.MathNode("mrow",a);var s=new AN.MathNode("annotation",[new AN.TextNode(t)]);s.setAttribute("encoding","application/x-tex");var u=new AN.MathNode("semantics",[i,s]),l=new AN.MathNode("math",[u]);l.setAttribute("xmlns","http://www.w3.org/1998/Math/MathML"),n&&l.setAttribute("display","block");var c=o?"katex":"katex-mathml";return YT.makeSpan([c],[l])}var PN=function(e){return new PO({style:e.displayMode?yO.DISPLAY:yO.TEXT,maxSize:e.maxSize,minRuleThickness:e.minRuleThickness})},MN=function(e,t){if(t.displayMode){var r=["katex-display"];t.leqno&&r.push("leqno"),t.fleqn&&r.push("fleqn"),e=YT.makeSpan(r,[e])}return e},IN={widehat:"^",widecheck:"ˇ",widetilde:"~",utilde:"~",overleftarrow:"←",underleftarrow:"←",xleftarrow:"←",overrightarrow:"→",underrightarrow:"→",xrightarrow:"→",underbrace:"⏟",overbrace:"⏞",overgroup:"⏠",undergroup:"⏡",overleftrightarrow:"↔",underleftrightarrow:"↔",xleftrightarrow:"↔",Overrightarrow:"⇒",xRightarrow:"⇒",overleftharpoon:"↼",xleftharpoonup:"↼",overrightharpoon:"⇀",xrightharpoonup:"⇀",xLeftarrow:"⇐",xLeftrightarrow:"⇔",xhookleftarrow:"↩",xhookrightarrow:"↪",xmapsto:"↦",xrightharpoondown:"⇁",xleftharpoondown:"↽",xrightleftharpoons:"⇌",xleftrightharpoons:"⇋",xtwoheadleftarrow:"↞",xtwoheadrightarrow:"↠",xlongequal:"=",xtofrom:"⇄",xrightleftarrows:"⇄",xrightequilibrium:"⇌",xleftequilibrium:"⇋","\\cdrightarrow":"→","\\cdleftarrow":"←","\\cdlongequal":"="},RN={overrightarrow:[["rightarrow"],.888,522,"xMaxYMin"],overleftarrow:[["leftarrow"],.888,522,"xMinYMin"],underrightarrow:[["rightarrow"],.888,522,"xMaxYMin"],underleftarrow:[["leftarrow"],.888,522,"xMinYMin"],xrightarrow:[["rightarrow"],1.469,522,"xMaxYMin"],"\\cdrightarrow":[["rightarrow"],3,522,"xMaxYMin"],xleftarrow:[["leftarrow"],1.469,522,"xMinYMin"],"\\cdleftarrow":[["leftarrow"],3,522,"xMinYMin"],Overrightarrow:[["doublerightarrow"],.888,560,"xMaxYMin"],xRightarrow:[["doublerightarrow"],1.526,560,"xMaxYMin"],xLeftarrow:[["doubleleftarrow"],1.526,560,"xMinYMin"],overleftharpoon:[["leftharpoon"],.888,522,"xMinYMin"],xleftharpoonup:[["leftharpoon"],.888,522,"xMinYMin"],xleftharpoondown:[["leftharpoondown"],.888,522,"xMinYMin"],overrightharpoon:[["rightharpoon"],.888,522,"xMaxYMin"],xrightharpoonup:[["rightharpoon"],.888,522,"xMaxYMin"],xrightharpoondown:[["rightharpoondown"],.888,522,"xMaxYMin"],xlongequal:[["longequal"],.888,334,"xMinYMin"],"\\cdlongequal":[["longequal"],3,334,"xMinYMin"],xtwoheadleftarrow:[["twoheadleftarrow"],.888,334,"xMinYMin"],xtwoheadrightarrow:[["twoheadrightarrow"],.888,334,"xMaxYMin"],overleftrightarrow:[["leftarrow","rightarrow"],.888,522],overbrace:[["leftbrace","midbrace","rightbrace"],1.6,548],underbrace:[["leftbraceunder","midbraceunder","rightbraceunder"],1.6,548],underleftrightarrow:[["leftarrow","rightarrow"],.888,522],xleftrightarrow:[["leftarrow","rightarrow"],1.75,522],xLeftrightarrow:[["doubleleftarrow","doublerightarrow"],1.75,560],xrightleftharpoons:[["leftharpoondownplus","rightharpoonplus"],1.75,716],xleftrightharpoons:[["leftharpoonplus","rightharpoondownplus"],1.75,716],xhookleftarrow:[["leftarrow","righthook"],1.08,522],xhookrightarrow:[["lefthook","rightarrow"],1.08,522],overlinesegment:[["leftlinesegment","rightlinesegment"],.888,522],underlinesegment:[["leftlinesegment","rightlinesegment"],.888,522],overgroup:[["leftgroup","rightgroup"],.888,342],undergroup:[["leftgroupunder","rightgroupunder"],.888,342],xmapsto:[["leftmapsto","rightarrow"],1.5,522],xtofrom:[["leftToFrom","rightToFrom"],1.75,528],xrightleftarrows:[["baraboveleftarrow","rightarrowabovebar"],1.75,901],xrightequilibrium:[["baraboveshortleftharpoon","rightharpoonaboveshortbar"],1.75,716],xleftequilibrium:[["shortbaraboveleftharpoon","shortrightharpoonabovebar"],1.75,716]},LN=function(e,t,r,n,o){var i,a=e.height+e.depth+r+n;if(/fbox|color|angl/.test(t)){if(i=YT.makeSpan(["stretchy",t],[],o),"fbox"===t){var s=o.color&&o.getColor();s&&(i.style.borderColor=s)}}else{var u=[];/^[bx]cancel$/.test(t)&&u.push(new ZO({x1:"0",y1:"0",x2:"100%",y2:"100%","stroke-width":"0.046em"})),/^x?cancel$/.test(t)&&u.push(new ZO({x1:"0",y1:"100%",x2:"100%",y2:"0","stroke-width":"0.046em"}));var l=new KO(u,{width:"100%",height:_O(a)});i=YT.makeSvgSpan([],[l],o)}return i.height=a,i.style.height=_O(a),i},_N=function(e){var t=new AN.MathNode("mo",[new AN.TextNode(IN[e.replace(/^\\/,"")])]);return t.setAttribute("stretchy","true"),t},zN=function(e,t){var{span:r,minWidth:n,height:o}=function(){var r=4e5,n=e.label.slice(1);if(aO.contains(["widehat","widecheck","widetilde","utilde"],n)){var o,i,a,s="ordgroup"===(f=e.base).type?f.body.length:1;if(s>5)"widehat"===n||"widecheck"===n?(o=420,r=2364,a=.42,i=n+"4"):(o=312,r=2340,a=.34,i="tilde4");else{var u=[1,1,2,2,3,3][s];"widehat"===n||"widecheck"===n?(r=[0,1062,2364,2364,2364][u],o=[0,239,300,360,420][u],a=[0,.24,.3,.3,.36,.42][u],i=n+u):(r=[0,600,1033,2339,2340][u],o=[0,260,286,306,312][u],a=[0,.26,.286,.3,.306,.34][u],i="tilde"+u)}var l=new XO(i),c=new KO([l],{width:"100%",height:_O(a),viewBox:"0 0 "+r+" "+o,preserveAspectRatio:"none"});return{span:YT.makeSvgSpan([],[c],t),minWidth:0,height:a}}var d,h,f,p=[],g=RN[n],[m,v,y]=g,b=y/1e3,D=m.length;if(1===D)d=["hide-tail"],h=[g[3]];else if(2===D)d=["halfarrow-left","halfarrow-right"],h=["xMinYMin","xMaxYMin"];else{if(3!==D)throw new Error("Correct katexImagesData or update code here to support\n "+D+" children.");d=["brace-left","brace-center","brace-right"],h=["xMinYMin","xMidYMin","xMaxYMin"]}for(var C=0;C<D;C++){var w=new XO(m[C]),E=new KO([w],{width:"400em",height:_O(b),viewBox:"0 0 "+r+" "+y,preserveAspectRatio:h[C]+" slice"}),A=YT.makeSvgSpan([d[C]],[E],t);if(1===D)return{span:A,minWidth:v,height:b};A.style.height=_O(b),p.push(A)}return{span:YT.makeSpan(["stretchy"],p,t),minWidth:v,height:b}}();return r.height=o,r.style.height=_O(o),n>0&&(r.style.minWidth=_O(n)),r};function jN(e,t){if(!e||e.type!==t)throw new Error("Expected node of type "+t+", but got "+(e?"node of type "+e.type:String(e)));return e}function HN(e){var t=VN(e);if(!t)throw new Error("Expected node of symbol group type, but got "+(e?"node of type "+e.type:String(e)));return t}function VN(e){return e&&("atom"===e.type||eT.hasOwnProperty(e.type))?e:null}var $N=(e,t)=>{var r,n,o;e&&"supsub"===e.type?(r=(n=jN(e.base,"accent")).base,e.base=r,o=function(e){if(e instanceof UO)return e;throw new Error("Expected span<HtmlDomNode> but got "+String(e)+".")}(yN(e,t)),e.base=n):r=(n=jN(e,"accent")).base;var i=yN(r,t.havingCrampedStyle()),a=0;if(n.isShifty&&aO.isCharacterBox(r)){var s=aO.getBaseElem(r);a=JO(yN(s,t.havingCrampedStyle())).skew}var u,l="\\c"===n.label,c=l?i.height+i.depth:Math.min(i.height,t.fontMetrics().xHeight);if(n.isStretchy)u=zN(n,t),u=YT.makeVList({positionType:"firstBaseline",children:[{type:"elem",elem:i},{type:"elem",elem:u,wrapperClasses:["svg-align"],wrapperStyle:a>0?{width:"calc(100% - "+_O(2*a)+")",marginLeft:_O(2*a)}:void 0}]},t);else{var d,h;"\\vec"===n.label?(d=YT.staticSvg("vec",t),h=YT.svgData.vec[1]):((d=JO(d=YT.makeOrd({mode:n.mode,text:n.label},t,"textord"))).italic=0,h=d.width,l&&(c+=d.depth)),u=YT.makeSpan(["accent-body"],[d]);var f="\\textcircled"===n.label;f&&(u.classes.push("accent-full"),c=i.height);var p=a;f||(p-=h/2),u.style.left=_O(p),"\\textcircled"===n.label&&(u.style.top=".2em"),u=YT.makeVList({positionType:"firstBaseline",children:[{type:"elem",elem:i},{type:"kern",size:-c},{type:"elem",elem:u}]},t)}var g=YT.makeSpan(["mord","accent"],[u],t);return o?(o.children[0]=g,o.height=Math.max(g.height,o.height),o.classes[0]="mord",o):g},UN=(e,t)=>{var r=e.isStretchy?_N(e.label):new AN.MathNode("mo",[xN(e.label,e.mode)]),n=new AN.MathNode("mover",[TN(e.base,t),r]);return n.setAttribute("accent","true"),n},qN=new RegExp(["\\acute","\\grave","\\ddot","\\tilde","\\bar","\\breve","\\check","\\hat","\\vec","\\dot","\\mathring"].map(e=>"\\"+e).join("|"));nN({type:"accent",names:["\\acute","\\grave","\\ddot","\\tilde","\\bar","\\breve","\\check","\\hat","\\vec","\\dot","\\mathring","\\widecheck","\\widehat","\\widetilde","\\overrightarrow","\\overleftarrow","\\Overrightarrow","\\overleftrightarrow","\\overgroup","\\overlinesegment","\\overleftharpoon","\\overrightharpoon"],props:{numArgs:1},handler:(e,t)=>{var r=iN(t[0]),n=!qN.test(e.funcName),o=!n||"\\widehat"===e.funcName||"\\widetilde"===e.funcName||"\\widecheck"===e.funcName;return{type:"accent",mode:e.parser.mode,label:e.funcName,isStretchy:n,isShifty:o,base:r}},htmlBuilder:$N,mathmlBuilder:UN}),nN({type:"accent",names:["\\'","\\`","\\^","\\~","\\=","\\u","\\.",'\\"',"\\c","\\r","\\H","\\v","\\textcircled"],props:{numArgs:1,allowedInText:!0,allowedInMath:!0,argTypes:["primitive"]},handler:(e,t)=>{var r=t[0],n=e.parser.mode;return"math"===n&&(e.parser.settings.reportNonstrict("mathVsTextAccents","LaTeX's accent "+e.funcName+" works only in text mode"),n="text"),{type:"accent",mode:n,label:e.funcName,isStretchy:!1,isShifty:!0,base:r}},htmlBuilder:$N,mathmlBuilder:UN}),nN({type:"accentUnder",names:["\\underleftarrow","\\underrightarrow","\\underleftrightarrow","\\undergroup","\\underlinesegment","\\utilde"],props:{numArgs:1},handler:(e,t)=>{var{parser:r,funcName:n}=e,o=t[0];return{type:"accentUnder",mode:r.mode,label:n,base:o}},htmlBuilder:(e,t)=>{var r=yN(e.base,t),n=zN(e,t),o="\\utilde"===e.label?.12:0,i=YT.makeVList({positionType:"top",positionData:r.height,children:[{type:"elem",elem:n,wrapperClasses:["svg-align"]},{type:"kern",size:o},{type:"elem",elem:r}]},t);return YT.makeSpan(["mord","accentunder"],[i],t)},mathmlBuilder:(e,t)=>{var r=_N(e.label),n=new AN.MathNode("munder",[TN(e.base,t),r]);return n.setAttribute("accentunder","true"),n}});var WN=e=>{var t=new AN.MathNode("mpadded",e?[e]:[]);return t.setAttribute("width","+0.6em"),t.setAttribute("lspace","0.3em"),t};nN({type:"xArrow",names:["\\xleftarrow","\\xrightarrow","\\xLeftarrow","\\xRightarrow","\\xleftrightarrow","\\xLeftrightarrow","\\xhookleftarrow","\\xhookrightarrow","\\xmapsto","\\xrightharpoondown","\\xrightharpoonup","\\xleftharpoondown","\\xleftharpoonup","\\xrightleftharpoons","\\xleftrightharpoons","\\xlongequal","\\xtwoheadrightarrow","\\xtwoheadleftarrow","\\xtofrom","\\xrightleftarrows","\\xrightequilibrium","\\xleftequilibrium","\\\\cdrightarrow","\\\\cdleftarrow","\\\\cdlongequal"],props:{numArgs:1,numOptionalArgs:1},handler(e,t,r){var{parser:n,funcName:o}=e;return{type:"xArrow",mode:n.mode,label:o,body:t[0],below:r[0]}},htmlBuilder(e,t){var r,n=t.style,o=t.havingStyle(n.sup()),i=YT.wrapFragment(yN(e.body,o,t),t),a="\\x"===e.label.slice(0,2)?"x":"cd";i.classes.push(a+"-arrow-pad"),e.below&&(o=t.havingStyle(n.sub()),(r=YT.wrapFragment(yN(e.below,o,t),t)).classes.push(a+"-arrow-pad"));var s,u=zN(e,t),l=-t.fontMetrics().axisHeight+.5*u.height,c=-t.fontMetrics().axisHeight-.5*u.height-.111;if((i.depth>.25||"\\xleftequilibrium"===e.label)&&(c-=i.depth),r){var d=-t.fontMetrics().axisHeight+r.height+.5*u.height+.111;s=YT.makeVList({positionType:"individualShift",children:[{type:"elem",elem:i,shift:c},{type:"elem",elem:u,shift:l},{type:"elem",elem:r,shift:d}]},t)}else s=YT.makeVList({positionType:"individualShift",children:[{type:"elem",elem:i,shift:c},{type:"elem",elem:u,shift:l}]},t);return s.children[0].children[0].children[1].classes.push("svg-align"),YT.makeSpan(["mrel","x-arrow"],[s],t)},mathmlBuilder(e,t){var r,n=_N(e.label);if(n.setAttribute("minsize","x"===e.label.charAt(0)?"1.75em":"3.0em"),e.body){var o=WN(TN(e.body,t));if(e.below){var i=WN(TN(e.below,t));r=new AN.MathNode("munderover",[n,i,o])}else r=new AN.MathNode("mover",[n,o])}else if(e.below){var a=WN(TN(e.below,t));r=new AN.MathNode("munder",[n,a])}else r=WN(),r=new AN.MathNode("mover",[n,r]);return r}});var GN=YT.makeSpan;function YN(e,t){var r=hN(e.body,t,!0);return GN([e.mclass],r,t)}function KN(e,t){var r,n=kN(e.body,t);return"minner"===e.mclass?r=new AN.MathNode("mpadded",n):"mord"===e.mclass?e.isCharacterBox?(r=n[0]).type="mi":r=new AN.MathNode("mi",n):(e.isCharacterBox?(r=n[0]).type="mo":r=new AN.MathNode("mo",n),"mbin"===e.mclass?(r.attributes.lspace="0.22em",r.attributes.rspace="0.22em"):"mpunct"===e.mclass?(r.attributes.lspace="0em",r.attributes.rspace="0.17em"):"mopen"===e.mclass||"mclose"===e.mclass?(r.attributes.lspace="0em",r.attributes.rspace="0em"):"minner"===e.mclass&&(r.attributes.lspace="0.0556em",r.attributes.width="+0.1111em")),r}nN({type:"mclass",names:["\\mathord","\\mathbin","\\mathrel","\\mathopen","\\mathclose","\\mathpunct","\\mathinner"],props:{numArgs:1,primitive:!0},handler(e,t){var{parser:r,funcName:n}=e,o=t[0];return{type:"mclass",mode:r.mode,mclass:"m"+n.slice(5),body:aN(o),isCharacterBox:aO.isCharacterBox(o)}},htmlBuilder:YN,mathmlBuilder:KN});var XN=e=>{var t="ordgroup"===e.type&&e.body.length?e.body[0]:e;return"atom"!==t.type||"bin"!==t.family&&"rel"!==t.family?"mord":"m"+t.family};nN({type:"mclass",names:["\\@binrel"],props:{numArgs:2},handler(e,t){var{parser:r}=e;return{type:"mclass",mode:r.mode,mclass:XN(t[0]),body:aN(t[1]),isCharacterBox:aO.isCharacterBox(t[1])}}}),nN({type:"mclass",names:["\\stackrel","\\overset","\\underset"],props:{numArgs:2},handler(e,t){var r,{parser:n,funcName:o}=e,i=t[1],a=t[0];r="\\stackrel"!==o?XN(i):"mrel";var s={type:"op",mode:i.mode,limits:!0,alwaysHandleSupSub:!0,parentIsSupSub:!1,symbol:!1,suppressBaseShift:"\\stackrel"!==o,body:aN(i)},u={type:"supsub",mode:a.mode,base:s,sup:"\\underset"===o?null:a,sub:"\\underset"===o?a:null};return{type:"mclass",mode:n.mode,mclass:r,body:[u],isCharacterBox:aO.isCharacterBox(u)}},htmlBuilder:YN,mathmlBuilder:KN}),nN({type:"pmb",names:["\\pmb"],props:{numArgs:1,allowedInText:!0},handler(e,t){var{parser:r}=e;return{type:"pmb",mode:r.mode,mclass:XN(t[0]),body:aN(t[0])}},htmlBuilder(e,t){var r=hN(e.body,t,!0),n=YT.makeSpan([e.mclass],r,t);return n.style.textShadow="0.02em 0.01em 0.04px",n},mathmlBuilder(e,t){var r=kN(e.body,t),n=new AN.MathNode("mstyle",r);return n.setAttribute("style","text-shadow: 0.02em 0.01em 0.04px"),n}});var ZN={">":"\\\\cdrightarrow","<":"\\\\cdleftarrow","=":"\\\\cdlongequal",A:"\\uparrow",V:"\\downarrow","|":"\\Vert",".":"no arrow"},JN=()=>({type:"styling",body:[],mode:"math",style:"display"}),QN=e=>"textord"===e.type&&"@"===e.text,eP=(e,t)=>("mathord"===e.type||"atom"===e.type)&&e.text===t;function tP(e,t,r){var n=ZN[e];switch(n){case"\\\\cdrightarrow":case"\\\\cdleftarrow":return r.callFunction(n,[t[0]],[t[1]]);case"\\uparrow":case"\\downarrow":var o={type:"atom",text:n,mode:"math",family:"rel"},i={type:"ordgroup",mode:"math",body:[r.callFunction("\\\\cdleft",[t[0]],[]),r.callFunction("\\Big",[o],[]),r.callFunction("\\\\cdright",[t[1]],[])]};return r.callFunction("\\\\cdparent",[i],[]);case"\\\\cdlongequal":return r.callFunction("\\\\cdlongequal",[],[]);case"\\Vert":return r.callFunction("\\Big",[{type:"textord",text:"\\Vert",mode:"math"}],[]);default:return{type:"textord",text:" ",mode:"math"}}}nN({type:"cdlabel",names:["\\\\cdleft","\\\\cdright"],props:{numArgs:1},handler(e,t){var{parser:r,funcName:n}=e;return{type:"cdlabel",mode:r.mode,side:n.slice(4),label:t[0]}},htmlBuilder(e,t){var r=t.havingStyle(t.style.sup()),n=YT.wrapFragment(yN(e.label,r,t),t);return n.classes.push("cd-label-"+e.side),n.style.bottom=_O(.8-n.depth),n.height=0,n.depth=0,n},mathmlBuilder(e,t){var r=new AN.MathNode("mrow",[TN(e.label,t)]);return(r=new AN.MathNode("mpadded",[r])).setAttribute("width","0"),"left"===e.side&&r.setAttribute("lspace","-1width"),r.setAttribute("voffset","0.7em"),(r=new AN.MathNode("mstyle",[r])).setAttribute("displaystyle","false"),r.setAttribute("scriptlevel","1"),r}}),nN({type:"cdlabelparent",names:["\\\\cdparent"],props:{numArgs:1},handler(e,t){var{parser:r}=e;return{type:"cdlabelparent",mode:r.mode,fragment:t[0]}},htmlBuilder(e,t){var r=YT.wrapFragment(yN(e.fragment,t),t);return r.classes.push("cd-vert-arrow"),r},mathmlBuilder:(e,t)=>new AN.MathNode("mrow",[TN(e.fragment,t)])}),nN({type:"textord",names:["\\@char"],props:{numArgs:1,allowedInText:!0},handler(e,t){for(var{parser:r}=e,n=jN(t[0],"ordgroup").body,o="",i=0;i<n.length;i++){o+=jN(n[i],"textord").text}var a,s=parseInt(o);if(isNaN(s))throw new tO("\\@char has non-numeric argument "+o);if(s<0||s>=1114111)throw new tO("\\@char with invalid code point "+o);return s<=65535?a=String.fromCharCode(s):(s-=65536,a=String.fromCharCode(55296+(s>>10),56320+(1023&s))),{type:"textord",mode:r.mode,text:a}}});var rP=(e,t)=>{var r=hN(e.body,t.withColor(e.color),!1);return YT.makeFragment(r)},nP=(e,t)=>{var r=kN(e.body,t.withColor(e.color)),n=new AN.MathNode("mstyle",r);return n.setAttribute("mathcolor",e.color),n};nN({type:"color",names:["\\textcolor"],props:{numArgs:2,allowedInText:!0,argTypes:["color","original"]},handler(e,t){var{parser:r}=e,n=jN(t[0],"color-token").color,o=t[1];return{type:"color",mode:r.mode,color:n,body:aN(o)}},htmlBuilder:rP,mathmlBuilder:nP}),nN({type:"color",names:["\\color"],props:{numArgs:1,allowedInText:!0,argTypes:["color"]},handler(e,t){var{parser:r,breakOnTokenText:n}=e,o=jN(t[0],"color-token").color;r.gullet.macros.set("\\current@color",o);var i=r.parseExpression(!0,n);return{type:"color",mode:r.mode,color:o,body:i}},htmlBuilder:rP,mathmlBuilder:nP}),nN({type:"cr",names:["\\\\"],props:{numArgs:0,numOptionalArgs:0,allowedInText:!0},handler(e,t,r){var{parser:n}=e,o="["===n.gullet.future().text?n.parseSizeGroup(!0):null,i=!n.settings.displayMode||!n.settings.useStrictBehavior("newLineInDisplayMode","In LaTeX, \\\\ or \\newline does nothing in display mode");return{type:"cr",mode:n.mode,newLine:i,size:o&&jN(o,"size").value}},htmlBuilder(e,t){var r=YT.makeSpan(["mspace"],[],t);return e.newLine&&(r.classes.push("newline"),e.size&&(r.style.marginTop=_O(LO(e.size,t)))),r},mathmlBuilder(e,t){var r=new AN.MathNode("mspace");return e.newLine&&(r.setAttribute("linebreak","newline"),e.size&&r.setAttribute("height",_O(LO(e.size,t)))),r}});var oP={"\\global":"\\global","\\long":"\\\\globallong","\\\\globallong":"\\\\globallong","\\def":"\\gdef","\\gdef":"\\gdef","\\edef":"\\xdef","\\xdef":"\\xdef","\\let":"\\\\globallet","\\futurelet":"\\\\globalfuture"},iP=e=>{var t=e.text;if(/^(?:[\\{}$&#^_]|EOF)$/.test(t))throw new tO("Expected a control sequence",e);return t},aP=(e,t,r,n)=>{var o=e.gullet.macros.get(r.text);null==o&&(r.noexpand=!0,o={tokens:[r],numArgs:0,unexpandable:!e.gullet.isExpandable(r.text)}),e.gullet.macros.set(t,o,n)};nN({type:"internal",names:["\\global","\\long","\\\\globallong"],props:{numArgs:0,allowedInText:!0},handler(e){var{parser:t,funcName:r}=e;t.consumeSpaces();var n=t.fetch();if(oP[n.text])return"\\global"!==r&&"\\\\globallong"!==r||(n.text=oP[n.text]),jN(t.parseFunction(),"internal");throw new tO("Invalid token after macro prefix",n)}}),nN({type:"internal",names:["\\def","\\gdef","\\edef","\\xdef"],props:{numArgs:0,allowedInText:!0,primitive:!0},handler(e){var{parser:t,funcName:r}=e,n=t.gullet.popToken(),o=n.text;if(/^(?:[\\{}$&#^_]|EOF)$/.test(o))throw new tO("Expected a control sequence",n);for(var i,a=0,s=[[]];"{"!==t.gullet.future().text;)if("#"===(n=t.gullet.popToken()).text){if("{"===t.gullet.future().text){i=t.gullet.future(),s[a].push("{");break}if(n=t.gullet.popToken(),!/^[1-9]$/.test(n.text))throw new tO('Invalid argument number "'+n.text+'"');if(parseInt(n.text)!==a+1)throw new tO('Argument number "'+n.text+'" out of order');a++,s.push([])}else{if("EOF"===n.text)throw new tO("Expected a macro definition");s[a].push(n.text)}var{tokens:u}=t.gullet.consumeArg();return i&&u.unshift(i),"\\edef"!==r&&"\\xdef"!==r||(u=t.gullet.expandTokens(u)).reverse(),t.gullet.macros.set(o,{tokens:u,numArgs:a,delimiters:s},r===oP[r]),{type:"internal",mode:t.mode}}}),nN({type:"internal",names:["\\let","\\\\globallet"],props:{numArgs:0,allowedInText:!0,primitive:!0},handler(e){var{parser:t,funcName:r}=e,n=iP(t.gullet.popToken());t.gullet.consumeSpaces();var o=(e=>{var t=e.gullet.popToken();return"="===t.text&&" "===(t=e.gullet.popToken()).text&&(t=e.gullet.popToken()),t})(t);return aP(t,n,o,"\\\\globallet"===r),{type:"internal",mode:t.mode}}}),nN({type:"internal",names:["\\futurelet","\\\\globalfuture"],props:{numArgs:0,allowedInText:!0,primitive:!0},handler(e){var{parser:t,funcName:r}=e,n=iP(t.gullet.popToken()),o=t.gullet.popToken(),i=t.gullet.popToken();return aP(t,n,i,"\\\\globalfuture"===r),t.gullet.pushToken(i),t.gullet.pushToken(o),{type:"internal",mode:t.mode}}});var sP=function(e,t,r){var n=FO(tT.math[e]&&tT.math[e].replace||e,t,r);if(!n)throw new Error("Unsupported symbol "+e+" and font size "+t+".");return n},uP=function(e,t,r,n){var o=r.havingBaseStyle(t),i=YT.makeSpan(n.concat(o.sizingClasses(r)),[e],r),a=o.sizeMultiplier/r.sizeMultiplier;return i.height*=a,i.depth*=a,i.maxFontSize=o.sizeMultiplier,i},lP=function(e,t,r){var n=t.havingBaseStyle(r),o=(1-t.sizeMultiplier/n.sizeMultiplier)*t.fontMetrics().axisHeight;e.classes.push("delimcenter"),e.style.top=_O(o),e.height-=o,e.depth+=o},cP=function(e,t,r,n,o,i){var a=function(e,t,r,n){return YT.makeSymbol(e,"Size"+t+"-Regular",r,n)}(e,t,o,n),s=uP(YT.makeSpan(["delimsizing","size"+t],[a],n),yO.TEXT,n,i);return r&&lP(s,n,yO.TEXT),s},dP=function(e,t,r){var n;return n="Size1-Regular"===t?"delim-size1":"delim-size4",{type:"elem",elem:YT.makeSpan(["delimsizinginner",n],[YT.makeSpan([],[YT.makeSymbol(e,t,r)])])}},hP=function(e,t,r){var n=xO["Size4-Regular"][e.charCodeAt(0)]?xO["Size4-Regular"][e.charCodeAt(0)][4]:xO["Size1-Regular"][e.charCodeAt(0)][4],o=new XO("inner",function(e,t){switch(e){case"⎜":return"M291 0 H417 V"+t+" H291z M291 0 H417 V"+t+" H291z";case"∣":return"M145 0 H188 V"+t+" H145z M145 0 H188 V"+t+" H145z";case"∥":return"M145 0 H188 V"+t+" H145z M145 0 H188 V"+t+" H145zM367 0 H410 V"+t+" H367z M367 0 H410 V"+t+" H367z";case"⎟":return"M457 0 H583 V"+t+" H457z M457 0 H583 V"+t+" H457z";case"⎢":return"M319 0 H403 V"+t+" H319z M319 0 H403 V"+t+" H319z";case"⎥":return"M263 0 H347 V"+t+" H263z M263 0 H347 V"+t+" H263z";case"⎪":return"M384 0 H504 V"+t+" H384z M384 0 H504 V"+t+" H384z";case"⏐":return"M312 0 H355 V"+t+" H312z M312 0 H355 V"+t+" H312z";case"‖":return"M257 0 H300 V"+t+" H257z M257 0 H300 V"+t+" H257zM478 0 H521 V"+t+" H478z M478 0 H521 V"+t+" H478z";default:return""}}(e,Math.round(1e3*t))),i=new KO([o],{width:_O(n),height:_O(t),style:"width:"+_O(n),viewBox:"0 0 "+1e3*n+" "+Math.round(1e3*t),preserveAspectRatio:"xMinYMin"}),a=YT.makeSvgSpan([],[i],r);return a.height=t,a.style.height=_O(t),a.style.width=_O(n),{type:"elem",elem:a}},fP={type:"kern",size:-.008},pP=["|","\\lvert","\\rvert","\\vert"],gP=["\\|","\\lVert","\\rVert","\\Vert"],mP=function(e,t,r,n,o,i){var a,s,u,l,c="",d=0;a=u=l=e,s=null;var h="Size1-Regular";"\\uparrow"===e?u=l="⏐":"\\Uparrow"===e?u=l="‖":"\\downarrow"===e?a=u="⏐":"\\Downarrow"===e?a=u="‖":"\\updownarrow"===e?(a="\\uparrow",u="⏐",l="\\downarrow"):"\\Updownarrow"===e?(a="\\Uparrow",u="‖",l="\\Downarrow"):aO.contains(pP,e)?(u="∣",c="vert",d=333):aO.contains(gP,e)?(u="∥",c="doublevert",d=556):"["===e||"\\lbrack"===e?(a="⎡",u="⎢",l="⎣",h="Size4-Regular",c="lbrack",d=667):"]"===e||"\\rbrack"===e?(a="⎤",u="⎥",l="⎦",h="Size4-Regular",c="rbrack",d=667):"\\lfloor"===e||"⌊"===e?(u=a="⎢",l="⎣",h="Size4-Regular",c="lfloor",d=667):"\\lceil"===e||"⌈"===e?(a="⎡",u=l="⎢",h="Size4-Regular",c="lceil",d=667):"\\rfloor"===e||"⌋"===e?(u=a="⎥",l="⎦",h="Size4-Regular",c="rfloor",d=667):"\\rceil"===e||"⌉"===e?(a="⎤",u=l="⎥",h="Size4-Regular",c="rceil",d=667):"("===e||"\\lparen"===e?(a="⎛",u="⎜",l="⎝",h="Size4-Regular",c="lparen",d=875):")"===e||"\\rparen"===e?(a="⎞",u="⎟",l="⎠",h="Size4-Regular",c="rparen",d=875):"\\{"===e||"\\lbrace"===e?(a="⎧",s="⎨",l="⎩",u="⎪",h="Size4-Regular"):"\\}"===e||"\\rbrace"===e?(a="⎫",s="⎬",l="⎭",u="⎪",h="Size4-Regular"):"\\lgroup"===e||"⟮"===e?(a="⎧",l="⎩",u="⎪",h="Size4-Regular"):"\\rgroup"===e||"⟯"===e?(a="⎫",l="⎭",u="⎪",h="Size4-Regular"):"\\lmoustache"===e||"⎰"===e?(a="⎧",l="⎭",u="⎪",h="Size4-Regular"):"\\rmoustache"!==e&&"⎱"!==e||(a="⎫",l="⎩",u="⎪",h="Size4-Regular");var f=sP(a,h,o),p=f.height+f.depth,g=sP(u,h,o),m=g.height+g.depth,v=sP(l,h,o),y=v.height+v.depth,b=0,D=1;if(null!==s){var C=sP(s,h,o);b=C.height+C.depth,D=2}var w=p+y+b,E=w+Math.max(0,Math.ceil((t-w)/(D*m)))*D*m,A=n.fontMetrics().axisHeight;r&&(A*=n.sizeMultiplier);var x=E/2-A,B=[];if(c.length>0){var S=E-p-y,F=Math.round(1e3*E),k=function(e,t){switch(e){case"lbrack":return"M403 1759 V84 H666 V0 H319 V1759 v"+t+" v1759 h347 v-84\nH403z M403 1759 V0 H319 V1759 v"+t+" v1759 h84z";case"rbrack":return"M347 1759 V0 H0 V84 H263 V1759 v"+t+" v1759 H0 v84 H347z\nM347 1759 V0 H263 V1759 v"+t+" v1759 h84z";case"vert":return"M145 15 v585 v"+t+" v585 c2.667,10,9.667,15,21,15\nc10,0,16.667,-5,20,-15 v-585 v"+-t+" v-585 c-2.667,-10,-9.667,-15,-21,-15\nc-10,0,-16.667,5,-20,15z M188 15 H145 v585 v"+t+" v585 h43z";case"doublevert":return"M145 15 v585 v"+t+" v585 c2.667,10,9.667,15,21,15\nc10,0,16.667,-5,20,-15 v-585 v"+-t+" v-585 c-2.667,-10,-9.667,-15,-21,-15\nc-10,0,-16.667,5,-20,15z M188 15 H145 v585 v"+t+" v585 h43z\nM367 15 v585 v"+t+" v585 c2.667,10,9.667,15,21,15\nc10,0,16.667,-5,20,-15 v-585 v"+-t+" v-585 c-2.667,-10,-9.667,-15,-21,-15\nc-10,0,-16.667,5,-20,15z M410 15 H367 v585 v"+t+" v585 h43z";case"lfloor":return"M319 602 V0 H403 V602 v"+t+" v1715 h263 v84 H319z\nMM319 602 V0 H403 V602 v"+t+" v1715 H319z";case"rfloor":return"M319 602 V0 H403 V602 v"+t+" v1799 H0 v-84 H319z\nMM319 602 V0 H403 V602 v"+t+" v1715 H319z";case"lceil":return"M403 1759 V84 H666 V0 H319 V1759 v"+t+" v602 h84z\nM403 1759 V0 H319 V1759 v"+t+" v602 h84z";case"rceil":return"M347 1759 V0 H0 V84 H263 V1759 v"+t+" v602 h84z\nM347 1759 V0 h-84 V1759 v"+t+" v602 h84z";case"lparen":return"M863,9c0,-2,-2,-5,-6,-9c0,0,-17,0,-17,0c-12.7,0,-19.3,0.3,-20,1\nc-5.3,5.3,-10.3,11,-15,17c-242.7,294.7,-395.3,682,-458,1162c-21.3,163.3,-33.3,349,\n-36,557 l0,"+(t+84)+"c0.2,6,0,26,0,60c2,159.3,10,310.7,24,454c53.3,528,210,\n949.7,470,1265c4.7,6,9.7,11.7,15,17c0.7,0.7,7,1,19,1c0,0,18,0,18,0c4,-4,6,-7,6,-9\nc0,-2.7,-3.3,-8.7,-10,-18c-135.3,-192.7,-235.5,-414.3,-300.5,-665c-65,-250.7,-102.5,\n-544.7,-112.5,-882c-2,-104,-3,-167,-3,-189\nl0,-"+(t+92)+"c0,-162.7,5.7,-314,17,-454c20.7,-272,63.7,-513,129,-723c65.3,\n-210,155.3,-396.3,270,-559c6.7,-9.3,10,-15.3,10,-18z";case"rparen":return"M76,0c-16.7,0,-25,3,-25,9c0,2,2,6.3,6,13c21.3,28.7,42.3,60.3,\n63,95c96.7,156.7,172.8,332.5,228.5,527.5c55.7,195,92.8,416.5,111.5,664.5\nc11.3,139.3,17,290.7,17,454c0,28,1.7,43,3.3,45l0,"+(t+9)+"\nc-3,4,-3.3,16.7,-3.3,38c0,162,-5.7,313.7,-17,455c-18.7,248,-55.8,469.3,-111.5,664\nc-55.7,194.7,-131.8,370.3,-228.5,527c-20.7,34.7,-41.7,66.3,-63,95c-2,3.3,-4,7,-6,11\nc0,7.3,5.7,11,17,11c0,0,11,0,11,0c9.3,0,14.3,-0.3,15,-1c5.3,-5.3,10.3,-11,15,-17\nc242.7,-294.7,395.3,-681.7,458,-1161c21.3,-164.7,33.3,-350.7,36,-558\nl0,-"+(t+144)+"c-2,-159.3,-10,-310.7,-24,-454c-53.3,-528,-210,-949.7,\n-470,-1265c-4.7,-6,-9.7,-11.7,-15,-17c-0.7,-0.7,-6.7,-1,-18,-1z";default:throw new Error("Unknown stretchy delimiter.")}}(c,Math.round(1e3*S)),O=new XO(c,k),T=(d/1e3).toFixed(3)+"em",N=(F/1e3).toFixed(3)+"em",P=new KO([O],{width:T,height:N,viewBox:"0 0 "+d+" "+F}),M=YT.makeSvgSpan([],[P],n);M.height=F/1e3,M.style.width=T,M.style.height=N,B.push({type:"elem",elem:M})}else{if(B.push(dP(l,h,o)),B.push(fP),null===s){var I=E-p-y+.016;B.push(hP(u,I,n))}else{var R=(E-p-y-b)/2+.016;B.push(hP(u,R,n)),B.push(fP),B.push(dP(s,h,o)),B.push(fP),B.push(hP(u,R,n))}B.push(fP),B.push(dP(a,h,o))}var L=n.havingBaseStyle(yO.TEXT),_=YT.makeVList({positionType:"bottom",positionData:x,children:B},L);return uP(YT.makeSpan(["delimsizing","mult"],[_],L),yO.TEXT,n,i)},vP=.08,yP=function(e,t,r,n,o){var i=function(e,t,r){t*=1e3;var n="";switch(e){case"sqrtMain":n=function(e,t){return"M95,"+(622+e+t)+"\nc-2.7,0,-7.17,-2.7,-13.5,-8c-5.8,-5.3,-9.5,-10,-9.5,-14\nc0,-2,0.3,-3.3,1,-4c1.3,-2.7,23.83,-20.7,67.5,-54\nc44.2,-33.3,65.8,-50.3,66.5,-51c1.3,-1.3,3,-2,5,-2c4.7,0,8.7,3.3,12,10\ns173,378,173,378c0.7,0,35.3,-71,104,-213c68.7,-142,137.5,-285,206.5,-429\nc69,-144,104.5,-217.7,106.5,-221\nl"+e/2.075+" -"+e+"\nc5.3,-9.3,12,-14,20,-14\nH400000v"+(40+e)+"H845.2724\ns-225.272,467,-225.272,467s-235,486,-235,486c-2.7,4.7,-9,7,-19,7\nc-6,0,-10,-1,-12,-3s-194,-422,-194,-422s-65,47,-65,47z\nM"+(834+e)+" "+t+"h400000v"+(40+e)+"h-400000z"}(t,wO);break;case"sqrtSize1":n=function(e,t){return"M263,"+(601+e+t)+"c0.7,0,18,39.7,52,119\nc34,79.3,68.167,158.7,102.5,238c34.3,79.3,51.8,119.3,52.5,120\nc340,-704.7,510.7,-1060.3,512,-1067\nl"+e/2.084+" -"+e+"\nc4.7,-7.3,11,-11,19,-11\nH40000v"+(40+e)+"H1012.3\ns-271.3,567,-271.3,567c-38.7,80.7,-84,175,-136,283c-52,108,-89.167,185.3,-111.5,232\nc-22.3,46.7,-33.8,70.3,-34.5,71c-4.7,4.7,-12.3,7,-23,7s-12,-1,-12,-1\ns-109,-253,-109,-253c-72.7,-168,-109.3,-252,-110,-252c-10.7,8,-22,16.7,-34,26\nc-22,17.3,-33.3,26,-34,26s-26,-26,-26,-26s76,-59,76,-59s76,-60,76,-60z\nM"+(1001+e)+" "+t+"h400000v"+(40+e)+"h-400000z"}(t,wO);break;case"sqrtSize2":n=function(e,t){return"M983 "+(10+e+t)+"\nl"+e/3.13+" -"+e+"\nc4,-6.7,10,-10,18,-10 H400000v"+(40+e)+"\nH1013.1s-83.4,268,-264.1,840c-180.7,572,-277,876.3,-289,913c-4.7,4.7,-12.7,7,-24,7\ns-12,0,-12,0c-1.3,-3.3,-3.7,-11.7,-7,-25c-35.3,-125.3,-106.7,-373.3,-214,-744\nc-10,12,-21,25,-33,39s-32,39,-32,39c-6,-5.3,-15,-14,-27,-26s25,-30,25,-30\nc26.7,-32.7,52,-63,76,-91s52,-60,52,-60s208,722,208,722\nc56,-175.3,126.3,-397.3,211,-666c84.7,-268.7,153.8,-488.2,207.5,-658.5\nc53.7,-170.3,84.5,-266.8,92.5,-289.5z\nM"+(1001+e)+" "+t+"h400000v"+(40+e)+"h-400000z"}(t,wO);break;case"sqrtSize3":n=function(e,t){return"M424,"+(2398+e+t)+"\nc-1.3,-0.7,-38.5,-172,-111.5,-514c-73,-342,-109.8,-513.3,-110.5,-514\nc0,-2,-10.7,14.3,-32,49c-4.7,7.3,-9.8,15.7,-15.5,25c-5.7,9.3,-9.8,16,-12.5,20\ns-5,7,-5,7c-4,-3.3,-8.3,-7.7,-13,-13s-13,-13,-13,-13s76,-122,76,-122s77,-121,77,-121\ns209,968,209,968c0,-2,84.7,-361.7,254,-1079c169.3,-717.3,254.7,-1077.7,256,-1081\nl"+e/4.223+" -"+e+"c4,-6.7,10,-10,18,-10 H400000\nv"+(40+e)+"H1014.6\ns-87.3,378.7,-272.6,1166c-185.3,787.3,-279.3,1182.3,-282,1185\nc-2,6,-10,9,-24,9\nc-8,0,-12,-0.7,-12,-2z M"+(1001+e)+" "+t+"\nh400000v"+(40+e)+"h-400000z"}(t,wO);break;case"sqrtSize4":n=function(e,t){return"M473,"+(2713+e+t)+"\nc339.3,-1799.3,509.3,-2700,510,-2702 l"+e/5.298+" -"+e+"\nc3.3,-7.3,9.3,-11,18,-11 H400000v"+(40+e)+"H1017.7\ns-90.5,478,-276.2,1466c-185.7,988,-279.5,1483,-281.5,1485c-2,6,-10,9,-24,9\nc-8,0,-12,-0.7,-12,-2c0,-1.3,-5.3,-32,-16,-92c-50.7,-293.3,-119.7,-693.3,-207,-1200\nc0,-1.3,-5.3,8.7,-16,30c-10.7,21.3,-21.3,42.7,-32,64s-16,33,-16,33s-26,-26,-26,-26\ns76,-153,76,-153s77,-151,77,-151c0.7,0.7,35.7,202,105,604c67.3,400.7,102,602.7,104,\n606zM"+(1001+e)+" "+t+"h400000v"+(40+e)+"H1017.7z"}(t,wO);break;case"sqrtTall":n=function(e,t,r){return"M702 "+(e+t)+"H400000"+(40+e)+"\nH742v"+(r-54-t-e)+"l-4 4-4 4c-.667.7 -2 1.5-4 2.5s-4.167 1.833-6.5 2.5-5.5 1-9.5 1\nh-12l-28-84c-16.667-52-96.667 -294.333-240-727l-212 -643 -85 170\nc-4-3.333-8.333-7.667-13 -13l-13-13l77-155 77-156c66 199.333 139 419.667\n219 661 l218 661zM702 "+t+"H400000v"+(40+e)+"H742z"}(t,wO,r)}return n}(e,n,r),a=new XO(e,i),s=new KO([a],{width:"400em",height:_O(t),viewBox:"0 0 400000 "+r,preserveAspectRatio:"xMinYMin slice"});return YT.makeSvgSpan(["hide-tail"],[s],o)},bP=["(","\\lparen",")","\\rparen","[","\\lbrack","]","\\rbrack","\\{","\\lbrace","\\}","\\rbrace","\\lfloor","\\rfloor","⌊","⌋","\\lceil","\\rceil","⌈","⌉","\\surd"],DP=["\\uparrow","\\downarrow","\\updownarrow","\\Uparrow","\\Downarrow","\\Updownarrow","|","\\|","\\vert","\\Vert","\\lvert","\\rvert","\\lVert","\\rVert","\\lgroup","\\rgroup","⟮","⟯","\\lmoustache","\\rmoustache","⎰","⎱"],CP=["<",">","\\langle","\\rangle","/","\\backslash","\\lt","\\gt"],wP=[0,1.2,1.8,2.4,3],EP=[{type:"small",style:yO.SCRIPTSCRIPT},{type:"small",style:yO.SCRIPT},{type:"small",style:yO.TEXT},{type:"large",size:1},{type:"large",size:2},{type:"large",size:3},{type:"large",size:4}],AP=[{type:"small",style:yO.SCRIPTSCRIPT},{type:"small",style:yO.SCRIPT},{type:"small",style:yO.TEXT},{type:"stack"}],xP=[{type:"small",style:yO.SCRIPTSCRIPT},{type:"small",style:yO.SCRIPT},{type:"small",style:yO.TEXT},{type:"large",size:1},{type:"large",size:2},{type:"large",size:3},{type:"large",size:4},{type:"stack"}],BP=function(e){if("small"===e.type)return"Main-Regular";if("large"===e.type)return"Size"+e.size+"-Regular";if("stack"===e.type)return"Size4-Regular";throw new Error("Add support for delim type '"+e.type+"' here.")},SP=function(e,t,r,n){for(var o=Math.min(2,3-n.style.size);o<r.length&&"stack"!==r[o].type;o++){var i=sP(e,BP(r[o]),"math"),a=i.height+i.depth;if("small"===r[o].type&&(a*=n.havingBaseStyle(r[o].style).sizeMultiplier),a>t)return r[o]}return r[r.length-1]},FP=function(e,t,r,n,o,i){var a;"<"===e||"\\lt"===e||"⟨"===e?e="\\langle":">"!==e&&"\\gt"!==e&&"⟩"!==e||(e="\\rangle"),a=aO.contains(CP,e)?EP:aO.contains(bP,e)?xP:AP;var s=SP(e,t,a,n);return"small"===s.type?function(e,t,r,n,o,i){var a=YT.makeSymbol(e,"Main-Regular",o,n),s=uP(a,t,n,i);return r&&lP(s,n,t),s}(e,s.style,r,n,o,i):"large"===s.type?cP(e,s.size,r,n,o,i):mP(e,t,r,n,o,i)},kP={sqrtImage:function(e,t){var r,n,o=t.havingBaseSizing(),i=SP("\\surd",e*o.sizeMultiplier,xP,o),a=o.sizeMultiplier,s=Math.max(0,t.minRuleThickness-t.fontMetrics().sqrtRuleThickness),u=0,l=0,c=0;return"small"===i.type?(e<1?a=1:e<1.4&&(a=.7),l=(1+s)/a,(r=yP("sqrtMain",u=(1+s+vP)/a,c=1e3+1e3*s+80,s,t)).style.minWidth="0.853em",n=.833/a):"large"===i.type?(c=1080*wP[i.size],l=(wP[i.size]+s)/a,u=(wP[i.size]+s+vP)/a,(r=yP("sqrtSize"+i.size,u,c,s,t)).style.minWidth="1.02em",n=1/a):(u=e+s+vP,l=e+s,c=Math.floor(1e3*e+s)+80,(r=yP("sqrtTall",u,c,s,t)).style.minWidth="0.742em",n=1.056),r.height=l,r.style.height=_O(u),{span:r,advanceWidth:n,ruleWidth:(t.fontMetrics().sqrtRuleThickness+s)*a}},sizedDelim:function(e,t,r,n,o){if("<"===e||"\\lt"===e||"⟨"===e?e="\\langle":">"!==e&&"\\gt"!==e&&"⟩"!==e||(e="\\rangle"),aO.contains(bP,e)||aO.contains(CP,e))return cP(e,t,!1,r,n,o);if(aO.contains(DP,e))return mP(e,wP[t],!1,r,n,o);throw new tO("Illegal delimiter: '"+e+"'")},sizeToMaxHeight:wP,customSizedDelim:FP,leftRightDelim:function(e,t,r,n,o,i){var a=n.fontMetrics().axisHeight*n.sizeMultiplier,s=5/n.fontMetrics().ptPerEm,u=Math.max(t-a,r+a),l=Math.max(u/500*901,2*u-s);return FP(e,l,!0,n,o,i)}},OP={"\\bigl":{mclass:"mopen",size:1},"\\Bigl":{mclass:"mopen",size:2},"\\biggl":{mclass:"mopen",size:3},"\\Biggl":{mclass:"mopen",size:4},"\\bigr":{mclass:"mclose",size:1},"\\Bigr":{mclass:"mclose",size:2},"\\biggr":{mclass:"mclose",size:3},"\\Biggr":{mclass:"mclose",size:4},"\\bigm":{mclass:"mrel",size:1},"\\Bigm":{mclass:"mrel",size:2},"\\biggm":{mclass:"mrel",size:3},"\\Biggm":{mclass:"mrel",size:4},"\\big":{mclass:"mord",size:1},"\\Big":{mclass:"mord",size:2},"\\bigg":{mclass:"mord",size:3},"\\Bigg":{mclass:"mord",size:4}},TP=["(","\\lparen",")","\\rparen","[","\\lbrack","]","\\rbrack","\\{","\\lbrace","\\}","\\rbrace","\\lfloor","\\rfloor","⌊","⌋","\\lceil","\\rceil","⌈","⌉","<",">","\\langle","⟨","\\rangle","⟩","\\lt","\\gt","\\lvert","\\rvert","\\lVert","\\rVert","\\lgroup","\\rgroup","⟮","⟯","\\lmoustache","\\rmoustache","⎰","⎱","/","\\backslash","|","\\vert","\\|","\\Vert","\\uparrow","\\Uparrow","\\downarrow","\\Downarrow","\\updownarrow","\\Updownarrow","."];function NP(e,t){var r=VN(e);if(r&&aO.contains(TP,r.text))return r;throw new tO(r?"Invalid delimiter '"+r.text+"' after '"+t.funcName+"'":"Invalid delimiter type '"+e.type+"'",e)}function PP(e){if(!e.body)throw new Error("Bug: The leftright ParseNode wasn't fully parsed.")}nN({type:"delimsizing",names:["\\bigl","\\Bigl","\\biggl","\\Biggl","\\bigr","\\Bigr","\\biggr","\\Biggr","\\bigm","\\Bigm","\\biggm","\\Biggm","\\big","\\Big","\\bigg","\\Bigg"],props:{numArgs:1,argTypes:["primitive"]},handler:(e,t)=>{var r=NP(t[0],e);return{type:"delimsizing",mode:e.parser.mode,size:OP[e.funcName].size,mclass:OP[e.funcName].mclass,delim:r.text}},htmlBuilder:(e,t)=>"."===e.delim?YT.makeSpan([e.mclass]):kP.sizedDelim(e.delim,e.size,t,e.mode,[e.mclass]),mathmlBuilder:e=>{var t=[];"."!==e.delim&&t.push(xN(e.delim,e.mode));var r=new AN.MathNode("mo",t);"mopen"===e.mclass||"mclose"===e.mclass?r.setAttribute("fence","true"):r.setAttribute("fence","false"),r.setAttribute("stretchy","true");var n=_O(kP.sizeToMaxHeight[e.size]);return r.setAttribute("minsize",n),r.setAttribute("maxsize",n),r}}),nN({type:"leftright-right",names:["\\right"],props:{numArgs:1,primitive:!0},handler:(e,t)=>{var r=e.parser.gullet.macros.get("\\current@color");if(r&&"string"!=typeof r)throw new tO("\\current@color set to non-string in \\right");return{type:"leftright-right",mode:e.parser.mode,delim:NP(t[0],e).text,color:r}}}),nN({type:"leftright",names:["\\left"],props:{numArgs:1,primitive:!0},handler:(e,t)=>{var r=NP(t[0],e),n=e.parser;++n.leftrightDepth;var o=n.parseExpression(!1);--n.leftrightDepth,n.expect("\\right",!1);var i=jN(n.parseFunction(),"leftright-right");return{type:"leftright",mode:n.mode,body:o,left:r.text,right:i.delim,rightColor:i.color}},htmlBuilder:(e,t)=>{PP(e);for(var r,n,o=hN(e.body,t,!0,["mopen","mclose"]),i=0,a=0,s=!1,u=0;u<o.length;u++)o[u].isMiddle?s=!0:(i=Math.max(o[u].height,i),a=Math.max(o[u].depth,a));if(i*=t.sizeMultiplier,a*=t.sizeMultiplier,r="."===e.left?vN(t,["mopen"]):kP.leftRightDelim(e.left,i,a,t,e.mode,["mopen"]),o.unshift(r),s)for(var l=1;l<o.length;l++){var c=o[l].isMiddle;c&&(o[l]=kP.leftRightDelim(c.delim,i,a,c.options,e.mode,[]))}if("."===e.right)n=vN(t,["mclose"]);else{var d=e.rightColor?t.withColor(e.rightColor):t;n=kP.leftRightDelim(e.right,i,a,d,e.mode,["mclose"])}return o.push(n),YT.makeSpan(["minner"],o,t)},mathmlBuilder:(e,t)=>{PP(e);var r=kN(e.body,t);if("."!==e.left){var n=new AN.MathNode("mo",[xN(e.left,e.mode)]);n.setAttribute("fence","true"),r.unshift(n)}if("."!==e.right){var o=new AN.MathNode("mo",[xN(e.right,e.mode)]);o.setAttribute("fence","true"),e.rightColor&&o.setAttribute("mathcolor",e.rightColor),r.push(o)}return BN(r)}}),nN({type:"middle",names:["\\middle"],props:{numArgs:1,primitive:!0},handler:(e,t)=>{var r=NP(t[0],e);if(!e.parser.leftrightDepth)throw new tO("\\middle without preceding \\left",r);return{type:"middle",mode:e.parser.mode,delim:r.text}},htmlBuilder:(e,t)=>{var r;if("."===e.delim)r=vN(t,[]);else{r=kP.sizedDelim(e.delim,1,t,e.mode,[]);var n={delim:e.delim,options:t};r.isMiddle=n}return r},mathmlBuilder:(e,t)=>{var r="\\vert"===e.delim||"|"===e.delim?xN("|","text"):xN(e.delim,e.mode),n=new AN.MathNode("mo",[r]);return n.setAttribute("fence","true"),n.setAttribute("lspace","0.05em"),n.setAttribute("rspace","0.05em"),n}});var MP=(e,t)=>{var r,n,o=YT.wrapFragment(yN(e.body,t),t),i=e.label.slice(1),a=t.sizeMultiplier,s=0,u=aO.isCharacterBox(e.body);if("sout"===i)(r=YT.makeSpan(["stretchy","sout"])).height=t.fontMetrics().defaultRuleThickness/a,s=-.5*t.fontMetrics().xHeight;else if("phase"===i){var l=LO({number:.6,unit:"pt"},t),c=LO({number:.35,unit:"ex"},t);a/=t.havingBaseSizing().sizeMultiplier;var d=o.height+o.depth+l+c;o.style.paddingLeft=_O(d/2+l);var h=Math.floor(1e3*d*a),f=function(e){return"M400000 "+e+" H0 L"+e/2+" 0 l65 45 L145 "+(e-80)+" H400000z"}(h),p=new KO([new XO("phase",f)],{width:"400em",height:_O(h/1e3),viewBox:"0 0 400000 "+h,preserveAspectRatio:"xMinYMin slice"});(r=YT.makeSvgSpan(["hide-tail"],[p],t)).style.height=_O(d),s=o.depth+l+c}else{/cancel/.test(i)?u||o.classes.push("cancel-pad"):"angl"===i?o.classes.push("anglpad"):o.classes.push("boxpad");var g=0,m=0,v=0;/box/.test(i)?(v=Math.max(t.fontMetrics().fboxrule,t.minRuleThickness),m=g=t.fontMetrics().fboxsep+("colorbox"===i?0:v)):"angl"===i?(g=4*(v=Math.max(t.fontMetrics().defaultRuleThickness,t.minRuleThickness)),m=Math.max(0,.25-o.depth)):m=g=u?.2:0,r=LN(o,i,g,m,t),/fbox|boxed|fcolorbox/.test(i)?(r.style.borderStyle="solid",r.style.borderWidth=_O(v)):"angl"===i&&.049!==v&&(r.style.borderTopWidth=_O(v),r.style.borderRightWidth=_O(v)),s=o.depth+m,e.backgroundColor&&(r.style.backgroundColor=e.backgroundColor,e.borderColor&&(r.style.borderColor=e.borderColor))}if(e.backgroundColor)n=YT.makeVList({positionType:"individualShift",children:[{type:"elem",elem:r,shift:s},{type:"elem",elem:o,shift:0}]},t);else{var y=/cancel|phase/.test(i)?["svg-align"]:[];n=YT.makeVList({positionType:"individualShift",children:[{type:"elem",elem:o,shift:0},{type:"elem",elem:r,shift:s,wrapperClasses:y}]},t)}return/cancel/.test(i)&&(n.height=o.height,n.depth=o.depth),/cancel/.test(i)&&!u?YT.makeSpan(["mord","cancel-lap"],[n],t):YT.makeSpan(["mord"],[n],t)},IP=(e,t)=>{var r=0,n=new AN.MathNode(e.label.indexOf("colorbox")>-1?"mpadded":"menclose",[TN(e.body,t)]);switch(e.label){case"\\cancel":n.setAttribute("notation","updiagonalstrike");break;case"\\bcancel":n.setAttribute("notation","downdiagonalstrike");break;case"\\phase":n.setAttribute("notation","phasorangle");break;case"\\sout":n.setAttribute("notation","horizontalstrike");break;case"\\fbox":n.setAttribute("notation","box");break;case"\\angl":n.setAttribute("notation","actuarial");break;case"\\fcolorbox":case"\\colorbox":if(r=t.fontMetrics().fboxsep*t.fontMetrics().ptPerEm,n.setAttribute("width","+"+2*r+"pt"),n.setAttribute("height","+"+2*r+"pt"),n.setAttribute("lspace",r+"pt"),n.setAttribute("voffset",r+"pt"),"\\fcolorbox"===e.label){var o=Math.max(t.fontMetrics().fboxrule,t.minRuleThickness);n.setAttribute("style","border: "+o+"em solid "+String(e.borderColor))}break;case"\\xcancel":n.setAttribute("notation","updiagonalstrike downdiagonalstrike")}return e.backgroundColor&&n.setAttribute("mathbackground",e.backgroundColor),n};nN({type:"enclose",names:["\\colorbox"],props:{numArgs:2,allowedInText:!0,argTypes:["color","text"]},handler(e,t,r){var{parser:n,funcName:o}=e,i=jN(t[0],"color-token").color,a=t[1];return{type:"enclose",mode:n.mode,label:o,backgroundColor:i,body:a}},htmlBuilder:MP,mathmlBuilder:IP}),nN({type:"enclose",names:["\\fcolorbox"],props:{numArgs:3,allowedInText:!0,argTypes:["color","color","text"]},handler(e,t,r){var{parser:n,funcName:o}=e,i=jN(t[0],"color-token").color,a=jN(t[1],"color-token").color,s=t[2];return{type:"enclose",mode:n.mode,label:o,backgroundColor:a,borderColor:i,body:s}},htmlBuilder:MP,mathmlBuilder:IP}),nN({type:"enclose",names:["\\fbox"],props:{numArgs:1,argTypes:["hbox"],allowedInText:!0},handler(e,t){var{parser:r}=e;return{type:"enclose",mode:r.mode,label:"\\fbox",body:t[0]}}}),nN({type:"enclose",names:["\\cancel","\\bcancel","\\xcancel","\\sout","\\phase"],props:{numArgs:1},handler(e,t){var{parser:r,funcName:n}=e,o=t[0];return{type:"enclose",mode:r.mode,label:n,body:o}},htmlBuilder:MP,mathmlBuilder:IP}),nN({type:"enclose",names:["\\angl"],props:{numArgs:1,argTypes:["hbox"],allowedInText:!1},handler(e,t){var{parser:r}=e;return{type:"enclose",mode:r.mode,label:"\\angl",body:t[0]}}});var RP={};function LP(e){for(var{type:t,names:r,props:n,handler:o,htmlBuilder:i,mathmlBuilder:a}=e,s={type:t,numArgs:n.numArgs||0,allowedInText:!1,numOptionalArgs:0,handler:o},u=0;u<r.length;++u)RP[r[u]]=s;i&&(tN[t]=i),a&&(rN[t]=a)}var _P={};function zP(e,t){_P[e]=t}function jP(e){var t=[];e.consumeSpaces();var r=e.fetch().text;for("\\relax"===r&&(e.consume(),e.consumeSpaces(),r=e.fetch().text);"\\hline"===r||"\\hdashline"===r;)e.consume(),t.push("\\hdashline"===r),e.consumeSpaces(),r=e.fetch().text;return t}var HP=e=>{if(!e.parser.settings.displayMode)throw new tO("{"+e.envName+"} can be used only in display mode.")};function VP(e){if(-1===e.indexOf("ed"))return-1===e.indexOf("*")}function $P(e,t,r){var{hskipBeforeAndAfter:n,addJot:o,cols:i,arraystretch:a,colSeparationType:s,autoTag:u,singleRow:l,emptySingleRow:c,maxNumCols:d,leqno:h}=t;if(e.gullet.beginGroup(),l||e.gullet.macros.set("\\cr","\\\\\\relax"),!a){var f=e.gullet.expandMacroAsText("\\arraystretch");if(null==f)a=1;else if(!(a=parseFloat(f))||a<0)throw new tO("Invalid \\arraystretch: "+f)}e.gullet.beginGroup();var p=[],g=[p],m=[],v=[],y=null!=u?[]:void 0;function b(){u&&e.gullet.macros.set("\\@eqnsw","1",!0)}function D(){y&&(e.gullet.macros.get("\\df@tag")?(y.push(e.subparse([new eO("\\df@tag")])),e.gullet.macros.set("\\df@tag",void 0,!0)):y.push(Boolean(u)&&"1"===e.gullet.macros.get("\\@eqnsw")))}for(b(),v.push(jP(e));;){var C=e.parseExpression(!1,l?"\\end":"\\\\");e.gullet.endGroup(),e.gullet.beginGroup(),C={type:"ordgroup",mode:e.mode,body:C},r&&(C={type:"styling",mode:e.mode,style:r,body:[C]}),p.push(C);var w=e.fetch().text;if("&"===w){if(d&&p.length===d){if(l||s)throw new tO("Too many tab characters: &",e.nextToken);e.settings.reportNonstrict("textEnv","Too few columns specified in the {array} column argument.")}e.consume()}else{if("\\end"===w){D(),1===p.length&&"styling"===C.type&&0===C.body[0].body.length&&(g.length>1||!c)&&g.pop(),v.length<g.length+1&&v.push([]);break}if("\\\\"!==w)throw new tO("Expected & or \\\\ or \\cr or \\end",e.nextToken);e.consume();var E=void 0;" "!==e.gullet.future().text&&(E=e.parseSizeGroup(!0)),m.push(E?E.value:null),D(),v.push(jP(e)),p=[],g.push(p),b()}}return e.gullet.endGroup(),e.gullet.endGroup(),{type:"array",mode:e.mode,addJot:o,arraystretch:a,body:g,cols:i,rowGaps:m,hskipBeforeAndAfter:n,hLinesBeforeRow:v,colSeparationType:s,tags:y,leqno:h}}function UP(e){return"d"===e.slice(0,1)?"display":"text"}var qP=function(e,t){var r,n,o=e.body.length,i=e.hLinesBeforeRow,a=0,s=new Array(o),u=[],l=Math.max(t.fontMetrics().arrayRuleWidth,t.minRuleThickness),c=1/t.fontMetrics().ptPerEm,d=5*c;e.colSeparationType&&"small"===e.colSeparationType&&(d=t.havingStyle(yO.SCRIPT).sizeMultiplier/t.sizeMultiplier*.2778);var h="CD"===e.colSeparationType?LO({number:3,unit:"ex"},t):12*c,f=3*c,p=e.arraystretch*h,g=.7*p,m=.3*p,v=0;function y(e){for(var t=0;t<e.length;++t)t>0&&(v+=.25),u.push({pos:v,isDashed:e[t]})}for(y(i[0]),r=0;r<e.body.length;++r){var b=e.body[r],D=g,C=m;a<b.length&&(a=b.length);var w=new Array(b.length);for(n=0;n<b.length;++n){var E=yN(b[n],t);C<E.depth&&(C=E.depth),D<E.height&&(D=E.height),w[n]=E}var A=e.rowGaps[r],x=0;A&&(x=LO(A,t))>0&&(C<(x+=m)&&(C=x),x=0),e.addJot&&(C+=f),w.height=D,w.depth=C,v+=D,w.pos=v,v+=C+x,s[r]=w,y(i[r+1])}var B,S,F=v/2+t.fontMetrics().axisHeight,k=e.cols||[],O=[],T=[];if(e.tags&&e.tags.some(e=>e))for(r=0;r<o;++r){var N=s[r],P=N.pos-F,M=e.tags[r],I=void 0;(I=!0===M?YT.makeSpan(["eqn-num"],[],t):!1===M?YT.makeSpan([],[],t):YT.makeSpan([],hN(M,t,!0),t)).depth=N.depth,I.height=N.height,T.push({type:"elem",elem:I,shift:P})}for(n=0,S=0;n<a||S<k.length;++n,++S){for(var R=k[S]||{},L=!0;"separator"===R.type;){if(L||((B=YT.makeSpan(["arraycolsep"],[])).style.width=_O(t.fontMetrics().doubleRuleSep),O.push(B)),"|"!==R.separator&&":"!==R.separator)throw new tO("Invalid separator type: "+R.separator);var _="|"===R.separator?"solid":"dashed",z=YT.makeSpan(["vertical-separator"],[],t);z.style.height=_O(v),z.style.borderRightWidth=_O(l),z.style.borderRightStyle=_,z.style.margin="0 "+_O(-l/2);var j=v-F;j&&(z.style.verticalAlign=_O(-j)),O.push(z),R=k[++S]||{},L=!1}if(!(n>=a)){var H=void 0;(n>0||e.hskipBeforeAndAfter)&&0!==(H=aO.deflt(R.pregap,d))&&((B=YT.makeSpan(["arraycolsep"],[])).style.width=_O(H),O.push(B));var V=[];for(r=0;r<o;++r){var $=s[r],U=$[n];if(U){var q=$.pos-F;U.depth=$.depth,U.height=$.height,V.push({type:"elem",elem:U,shift:q})}}V=YT.makeVList({positionType:"individualShift",children:V},t),V=YT.makeSpan(["col-align-"+(R.align||"c")],[V]),O.push(V),(n<a-1||e.hskipBeforeAndAfter)&&0!==(H=aO.deflt(R.postgap,d))&&((B=YT.makeSpan(["arraycolsep"],[])).style.width=_O(H),O.push(B))}}if(s=YT.makeSpan(["mtable"],O),u.length>0){for(var W=YT.makeLineSpan("hline",t,l),G=YT.makeLineSpan("hdashline",t,l),Y=[{type:"elem",elem:s,shift:0}];u.length>0;){var K=u.pop(),X=K.pos-F;K.isDashed?Y.push({type:"elem",elem:G,shift:X}):Y.push({type:"elem",elem:W,shift:X})}s=YT.makeVList({positionType:"individualShift",children:Y},t)}if(0===T.length)return YT.makeSpan(["mord"],[s],t);var Z=YT.makeVList({positionType:"individualShift",children:T},t);return Z=YT.makeSpan(["tag"],[Z],t),YT.makeFragment([s,Z])},WP={c:"center ",l:"left ",r:"right "},GP=function(e,t){for(var r=[],n=new AN.MathNode("mtd",[],["mtr-glue"]),o=new AN.MathNode("mtd",[],["mml-eqn-num"]),i=0;i<e.body.length;i++){for(var a=e.body[i],s=[],u=0;u<a.length;u++)s.push(new AN.MathNode("mtd",[TN(a[u],t)]));e.tags&&e.tags[i]&&(s.unshift(n),s.push(n),e.leqno?s.unshift(o):s.push(o)),r.push(new AN.MathNode("mtr",s))}var l=new AN.MathNode("mtable",r),c=.5===e.arraystretch?.1:.16+e.arraystretch-1+(e.addJot?.09:0);l.setAttribute("rowspacing",_O(c));var d="",h="";if(e.cols&&e.cols.length>0){var f=e.cols,p="",g=!1,m=0,v=f.length;"separator"===f[0].type&&(d+="top ",m=1),"separator"===f[f.length-1].type&&(d+="bottom ",v-=1);for(var y=m;y<v;y++)"align"===f[y].type?(h+=WP[f[y].align],g&&(p+="none "),g=!0):"separator"===f[y].type&&g&&(p+="|"===f[y].separator?"solid ":"dashed ",g=!1);l.setAttribute("columnalign",h.trim()),/[sd]/.test(p)&&l.setAttribute("columnlines",p.trim())}if("align"===e.colSeparationType){for(var b=e.cols||[],D="",C=1;C<b.length;C++)D+=C%2?"0em ":"1em ";l.setAttribute("columnspacing",D.trim())}else"alignat"===e.colSeparationType||"gather"===e.colSeparationType?l.setAttribute("columnspacing","0em"):"small"===e.colSeparationType?l.setAttribute("columnspacing","0.2778em"):"CD"===e.colSeparationType?l.setAttribute("columnspacing","0.5em"):l.setAttribute("columnspacing","1em");var w="",E=e.hLinesBeforeRow;d+=E[0].length>0?"left ":"",d+=E[E.length-1].length>0?"right ":"";for(var A=1;A<E.length-1;A++)w+=0===E[A].length?"none ":E[A][0]?"dashed ":"solid ";return/[sd]/.test(w)&&l.setAttribute("rowlines",w.trim()),""!==d&&(l=new AN.MathNode("menclose",[l])).setAttribute("notation",d.trim()),e.arraystretch&&e.arraystretch<1&&(l=new AN.MathNode("mstyle",[l])).setAttribute("scriptlevel","1"),l},YP=function(e,t){-1===e.envName.indexOf("ed")&&HP(e);var r,n=[],o=e.envName.indexOf("at")>-1?"alignat":"align",i="split"===e.envName,a=$P(e.parser,{cols:n,addJot:!0,autoTag:i?void 0:VP(e.envName),emptySingleRow:!0,colSeparationType:o,maxNumCols:i?2:void 0,leqno:e.parser.settings.leqno},"display"),s=0,u={type:"ordgroup",mode:e.mode,body:[]};if(t[0]&&"ordgroup"===t[0].type){for(var l="",c=0;c<t[0].body.length;c++){l+=jN(t[0].body[c],"textord").text}r=Number(l),s=2*r}var d=!s;a.body.forEach(function(e){for(var t=1;t<e.length;t+=2){var n=jN(e[t],"styling");jN(n.body[0],"ordgroup").body.unshift(u)}if(d)s<e.length&&(s=e.length);else{var o=e.length/2;if(r<o)throw new tO("Too many math in a row: expected "+r+", but got "+o,e[0])}});for(var h=0;h<s;++h){var f="r",p=0;h%2==1?f="l":h>0&&d&&(p=1),n[h]={type:"align",align:f,pregap:p,postgap:0}}return a.colSeparationType=d?"align":"alignat",a};LP({type:"array",names:["array","darray"],props:{numArgs:1},handler(e,t){var r=(VN(t[0])?[t[0]]:jN(t[0],"ordgroup").body).map(function(e){var t=HN(e).text;if(-1!=="lcr".indexOf(t))return{type:"align",align:t};if("|"===t)return{type:"separator",separator:"|"};if(":"===t)return{type:"separator",separator:":"};throw new tO("Unknown column alignment: "+t,e)}),n={cols:r,hskipBeforeAndAfter:!0,maxNumCols:r.length};return $P(e.parser,n,UP(e.envName))},htmlBuilder:qP,mathmlBuilder:GP}),LP({type:"array",names:["matrix","pmatrix","bmatrix","Bmatrix","vmatrix","Vmatrix","matrix*","pmatrix*","bmatrix*","Bmatrix*","vmatrix*","Vmatrix*"],props:{numArgs:0},handler(e){var t={matrix:null,pmatrix:["(",")"],bmatrix:["[","]"],Bmatrix:["\\{","\\}"],vmatrix:["|","|"],Vmatrix:["\\Vert","\\Vert"]}[e.envName.replace("*","")],r="c",n={hskipBeforeAndAfter:!1,cols:[{type:"align",align:r}]};if("*"===e.envName.charAt(e.envName.length-1)){var o=e.parser;if(o.consumeSpaces(),"["===o.fetch().text){if(o.consume(),o.consumeSpaces(),r=o.fetch().text,-1==="lcr".indexOf(r))throw new tO("Expected l or c or r",o.nextToken);o.consume(),o.consumeSpaces(),o.expect("]"),o.consume(),n.cols=[{type:"align",align:r}]}}var i=$P(e.parser,n,UP(e.envName)),a=Math.max(0,...i.body.map(e=>e.length));return i.cols=new Array(a).fill({type:"align",align:r}),t?{type:"leftright",mode:e.mode,body:[i],left:t[0],right:t[1],rightColor:void 0}:i},htmlBuilder:qP,mathmlBuilder:GP}),LP({type:"array",names:["smallmatrix"],props:{numArgs:0},handler(e){var t=$P(e.parser,{arraystretch:.5},"script");return t.colSeparationType="small",t},htmlBuilder:qP,mathmlBuilder:GP}),LP({type:"array",names:["subarray"],props:{numArgs:1},handler(e,t){var r=(VN(t[0])?[t[0]]:jN(t[0],"ordgroup").body).map(function(e){var t=HN(e).text;if(-1!=="lc".indexOf(t))return{type:"align",align:t};throw new tO("Unknown column alignment: "+t,e)});if(r.length>1)throw new tO("{subarray} can contain only one column");var n={cols:r,hskipBeforeAndAfter:!1,arraystretch:.5};if((n=$P(e.parser,n,"script")).body.length>0&&n.body[0].length>1)throw new tO("{subarray} can contain only one column");return n},htmlBuilder:qP,mathmlBuilder:GP}),LP({type:"array",names:["cases","dcases","rcases","drcases"],props:{numArgs:0},handler(e){var t=$P(e.parser,{arraystretch:1.2,cols:[{type:"align",align:"l",pregap:0,postgap:1},{type:"align",align:"l",pregap:0,postgap:0}]},UP(e.envName));return{type:"leftright",mode:e.mode,body:[t],left:e.envName.indexOf("r")>-1?".":"\\{",right:e.envName.indexOf("r")>-1?"\\}":".",rightColor:void 0}},htmlBuilder:qP,mathmlBuilder:GP}),LP({type:"array",names:["align","align*","aligned","split"],props:{numArgs:0},handler:YP,htmlBuilder:qP,mathmlBuilder:GP}),LP({type:"array",names:["gathered","gather","gather*"],props:{numArgs:0},handler(e){aO.contains(["gather","gather*"],e.envName)&&HP(e);var t={cols:[{type:"align",align:"c"}],addJot:!0,colSeparationType:"gather",autoTag:VP(e.envName),emptySingleRow:!0,leqno:e.parser.settings.leqno};return $P(e.parser,t,"display")},htmlBuilder:qP,mathmlBuilder:GP}),LP({type:"array",names:["alignat","alignat*","alignedat"],props:{numArgs:1},handler:YP,htmlBuilder:qP,mathmlBuilder:GP}),LP({type:"array",names:["equation","equation*"],props:{numArgs:0},handler(e){HP(e);var t={autoTag:VP(e.envName),emptySingleRow:!0,singleRow:!0,maxNumCols:1,leqno:e.parser.settings.leqno};return $P(e.parser,t,"display")},htmlBuilder:qP,mathmlBuilder:GP}),LP({type:"array",names:["CD"],props:{numArgs:0},handler:e=>(HP(e),function(e){var t=[];for(e.gullet.beginGroup(),e.gullet.macros.set("\\cr","\\\\\\relax"),e.gullet.beginGroup();;){t.push(e.parseExpression(!1,"\\\\")),e.gullet.endGroup(),e.gullet.beginGroup();var r=e.fetch().text;if("&"!==r&&"\\\\"!==r){if("\\end"===r){0===t[t.length-1].length&&t.pop();break}throw new tO("Expected \\\\ or \\cr or \\end",e.nextToken)}e.consume()}for(var n=[],o=[n],i=0;i<t.length;i++){for(var a=t[i],s=JN(),u=0;u<a.length;u++)if(QN(a[u])){n.push(s);var l=HN(a[u+=1]).text,c=new Array(2);if(c[0]={type:"ordgroup",mode:"math",body:[]},c[1]={type:"ordgroup",mode:"math",body:[]},"=|.".indexOf(l)>-1);else{if(!("<>AV".indexOf(l)>-1))throw new tO('Expected one of "<>AV=|." after @',a[u]);for(var d=0;d<2;d++){for(var h=!0,f=u+1;f<a.length;f++){if(eP(a[f],l)){h=!1,u=f;break}if(QN(a[f]))throw new tO("Missing a "+l+" character to complete a CD arrow.",a[f]);c[d].body.push(a[f])}if(h)throw new tO("Missing a "+l+" character to complete a CD arrow.",a[u])}}var p={type:"styling",body:[tP(l,c,e)],mode:"math",style:"display"};n.push(p),s=JN()}else s.body.push(a[u]);i%2==0?n.push(s):n.shift(),n=[],o.push(n)}return e.gullet.endGroup(),e.gullet.endGroup(),{type:"array",mode:"math",body:o,arraystretch:1,addJot:!0,rowGaps:[null],cols:new Array(o[0].length).fill({type:"align",align:"c",pregap:.25,postgap:.25}),colSeparationType:"CD",hLinesBeforeRow:new Array(o.length+1).fill([])}}(e.parser)),htmlBuilder:qP,mathmlBuilder:GP}),zP("\\nonumber","\\gdef\\@eqnsw{0}"),zP("\\notag","\\nonumber"),nN({type:"text",names:["\\hline","\\hdashline"],props:{numArgs:0,allowedInText:!0,allowedInMath:!0},handler(e,t){throw new tO(e.funcName+" valid only within array environment")}});var KP=RP;nN({type:"environment",names:["\\begin","\\end"],props:{numArgs:1,argTypes:["text"]},handler(e,t){var{parser:r,funcName:n}=e,o=t[0];if("ordgroup"!==o.type)throw new tO("Invalid environment name",o);for(var i="",a=0;a<o.body.length;++a)i+=jN(o.body[a],"textord").text;if("\\begin"===n){if(!KP.hasOwnProperty(i))throw new tO("No such environment: "+i,o);var s=KP[i],{args:u,optArgs:l}=r.parseArguments("\\begin{"+i+"}",s),c={mode:r.mode,envName:i,parser:r},d=s.handler(c,u,l);r.expect("\\end",!1);var h=r.nextToken,f=jN(r.parseFunction(),"environment");if(f.name!==i)throw new tO("Mismatch: \\begin{"+i+"} matched by \\end{"+f.name+"}",h);return d}return{type:"environment",mode:r.mode,name:i,nameGroup:o}}});var XP=(e,t)=>{var r=e.font,n=t.withFont(r);return yN(e.body,n)},ZP=(e,t)=>{var r=e.font,n=t.withFont(r);return TN(e.body,n)},JP={"\\Bbb":"\\mathbb","\\bold":"\\mathbf","\\frak":"\\mathfrak","\\bm":"\\boldsymbol"};nN({type:"font",names:["\\mathrm","\\mathit","\\mathbf","\\mathnormal","\\mathsfit","\\mathbb","\\mathcal","\\mathfrak","\\mathscr","\\mathsf","\\mathtt","\\Bbb","\\bold","\\frak"],props:{numArgs:1,allowedInArgument:!0},handler:(e,t)=>{var{parser:r,funcName:n}=e,o=iN(t[0]),i=n;return i in JP&&(i=JP[i]),{type:"font",mode:r.mode,font:i.slice(1),body:o}},htmlBuilder:XP,mathmlBuilder:ZP}),nN({type:"mclass",names:["\\boldsymbol","\\bm"],props:{numArgs:1},handler:(e,t)=>{var{parser:r}=e,n=t[0],o=aO.isCharacterBox(n);return{type:"mclass",mode:r.mode,mclass:XN(n),body:[{type:"font",mode:r.mode,font:"boldsymbol",body:n}],isCharacterBox:o}}}),nN({type:"font",names:["\\rm","\\sf","\\tt","\\bf","\\it","\\cal"],props:{numArgs:0,allowedInText:!0},handler:(e,t)=>{var{parser:r,funcName:n,breakOnTokenText:o}=e,{mode:i}=r,a=r.parseExpression(!0,o);return{type:"font",mode:i,font:"math"+n.slice(1),body:{type:"ordgroup",mode:r.mode,body:a}}},htmlBuilder:XP,mathmlBuilder:ZP});var QP=(e,t)=>{var r=t;return"display"===e?r=r.id>=yO.SCRIPT.id?r.text():yO.DISPLAY:"text"===e&&r.size===yO.DISPLAY.size?r=yO.TEXT:"script"===e?r=yO.SCRIPT:"scriptscript"===e&&(r=yO.SCRIPTSCRIPT),r},eM=(e,t)=>{var r,n=QP(e.size,t.style),o=n.fracNum(),i=n.fracDen();r=t.havingStyle(o);var a=yN(e.numer,r,t);if(e.continued){var s=8.5/t.fontMetrics().ptPerEm,u=3.5/t.fontMetrics().ptPerEm;a.height=a.height<s?s:a.height,a.depth=a.depth<u?u:a.depth}r=t.havingStyle(i);var l,c,d,h,f,p,g,m,v,y,b=yN(e.denom,r,t);if(e.hasBarLine?(e.barSize?(c=LO(e.barSize,t),l=YT.makeLineSpan("frac-line",t,c)):l=YT.makeLineSpan("frac-line",t),c=l.height,d=l.height):(l=null,c=0,d=t.fontMetrics().defaultRuleThickness),n.size===yO.DISPLAY.size||"display"===e.size?(h=t.fontMetrics().num1,f=c>0?3*d:7*d,p=t.fontMetrics().denom1):(c>0?(h=t.fontMetrics().num2,f=d):(h=t.fontMetrics().num3,f=3*d),p=t.fontMetrics().denom2),l){var D=t.fontMetrics().axisHeight;h-a.depth-(D+.5*c)<f&&(h+=f-(h-a.depth-(D+.5*c))),D-.5*c-(b.height-p)<f&&(p+=f-(D-.5*c-(b.height-p)));var C=-(D-.5*c);g=YT.makeVList({positionType:"individualShift",children:[{type:"elem",elem:b,shift:p},{type:"elem",elem:l,shift:C},{type:"elem",elem:a,shift:-h}]},t)}else{var w=h-a.depth-(b.height-p);w<f&&(h+=.5*(f-w),p+=.5*(f-w)),g=YT.makeVList({positionType:"individualShift",children:[{type:"elem",elem:b,shift:p},{type:"elem",elem:a,shift:-h}]},t)}return r=t.havingStyle(n),g.height*=r.sizeMultiplier/t.sizeMultiplier,g.depth*=r.sizeMultiplier/t.sizeMultiplier,m=n.size===yO.DISPLAY.size?t.fontMetrics().delim1:n.size===yO.SCRIPTSCRIPT.size?t.havingStyle(yO.SCRIPT).fontMetrics().delim2:t.fontMetrics().delim2,v=null==e.leftDelim?vN(t,["mopen"]):kP.customSizedDelim(e.leftDelim,m,!0,t.havingStyle(n),e.mode,["mopen"]),y=e.continued?YT.makeSpan([]):null==e.rightDelim?vN(t,["mclose"]):kP.customSizedDelim(e.rightDelim,m,!0,t.havingStyle(n),e.mode,["mclose"]),YT.makeSpan(["mord"].concat(r.sizingClasses(t)),[v,YT.makeSpan(["mfrac"],[g]),y],t)},tM=(e,t)=>{var r=new AN.MathNode("mfrac",[TN(e.numer,t),TN(e.denom,t)]);if(e.hasBarLine){if(e.barSize){var n=LO(e.barSize,t);r.setAttribute("linethickness",_O(n))}}else r.setAttribute("linethickness","0px");var o=QP(e.size,t.style);if(o.size!==t.style.size){r=new AN.MathNode("mstyle",[r]);var i=o.size===yO.DISPLAY.size?"true":"false";r.setAttribute("displaystyle",i),r.setAttribute("scriptlevel","0")}if(null!=e.leftDelim||null!=e.rightDelim){var a=[];if(null!=e.leftDelim){var s=new AN.MathNode("mo",[new AN.TextNode(e.leftDelim.replace("\\",""))]);s.setAttribute("fence","true"),a.push(s)}if(a.push(r),null!=e.rightDelim){var u=new AN.MathNode("mo",[new AN.TextNode(e.rightDelim.replace("\\",""))]);u.setAttribute("fence","true"),a.push(u)}return BN(a)}return r};nN({type:"genfrac",names:["\\dfrac","\\frac","\\tfrac","\\dbinom","\\binom","\\tbinom","\\\\atopfrac","\\\\bracefrac","\\\\brackfrac"],props:{numArgs:2,allowedInArgument:!0},handler:(e,t)=>{var r,{parser:n,funcName:o}=e,i=t[0],a=t[1],s=null,u=null,l="auto";switch(o){case"\\dfrac":case"\\frac":case"\\tfrac":r=!0;break;case"\\\\atopfrac":r=!1;break;case"\\dbinom":case"\\binom":case"\\tbinom":r=!1,s="(",u=")";break;case"\\\\bracefrac":r=!1,s="\\{",u="\\}";break;case"\\\\brackfrac":r=!1,s="[",u="]";break;default:throw new Error("Unrecognized genfrac command")}switch(o){case"\\dfrac":case"\\dbinom":l="display";break;case"\\tfrac":case"\\tbinom":l="text"}return{type:"genfrac",mode:n.mode,continued:!1,numer:i,denom:a,hasBarLine:r,leftDelim:s,rightDelim:u,size:l,barSize:null}},htmlBuilder:eM,mathmlBuilder:tM}),nN({type:"genfrac",names:["\\cfrac"],props:{numArgs:2},handler:(e,t)=>{var{parser:r,funcName:n}=e,o=t[0],i=t[1];return{type:"genfrac",mode:r.mode,continued:!0,numer:o,denom:i,hasBarLine:!0,leftDelim:null,rightDelim:null,size:"display",barSize:null}}}),nN({type:"infix",names:["\\over","\\choose","\\atop","\\brace","\\brack"],props:{numArgs:0,infix:!0},handler(e){var t,{parser:r,funcName:n,token:o}=e;switch(n){case"\\over":t="\\frac";break;case"\\choose":t="\\binom";break;case"\\atop":t="\\\\atopfrac";break;case"\\brace":t="\\\\bracefrac";break;case"\\brack":t="\\\\brackfrac";break;default:throw new Error("Unrecognized infix genfrac command")}return{type:"infix",mode:r.mode,replaceWith:t,token:o}}});var rM=["display","text","script","scriptscript"],nM=function(e){var t=null;return e.length>0&&(t="."===(t=e)?null:t),t};nN({type:"genfrac",names:["\\genfrac"],props:{numArgs:6,allowedInArgument:!0,argTypes:["math","math","size","text","math","math"]},handler(e,t){var r,{parser:n}=e,o=t[4],i=t[5],a=iN(t[0]),s="atom"===a.type&&"open"===a.family?nM(a.text):null,u=iN(t[1]),l="atom"===u.type&&"close"===u.family?nM(u.text):null,c=jN(t[2],"size"),d=null;r=!!c.isBlank||(d=c.value).number>0;var h="auto",f=t[3];if("ordgroup"===f.type){if(f.body.length>0){var p=jN(f.body[0],"textord");h=rM[Number(p.text)]}}else f=jN(f,"textord"),h=rM[Number(f.text)];return{type:"genfrac",mode:n.mode,numer:o,denom:i,continued:!1,hasBarLine:r,barSize:d,leftDelim:s,rightDelim:l,size:h}},htmlBuilder:eM,mathmlBuilder:tM}),nN({type:"infix",names:["\\above"],props:{numArgs:1,argTypes:["size"],infix:!0},handler(e,t){var{parser:r,funcName:n,token:o}=e;return{type:"infix",mode:r.mode,replaceWith:"\\\\abovefrac",size:jN(t[0],"size").value,token:o}}}),nN({type:"genfrac",names:["\\\\abovefrac"],props:{numArgs:3,argTypes:["math","size","math"]},handler:(e,t)=>{var{parser:r,funcName:n}=e,o=t[0],i=function(e){if(!e)throw new Error("Expected non-null, but got "+String(e));return e}(jN(t[1],"infix").size),a=t[2],s=i.number>0;return{type:"genfrac",mode:r.mode,numer:o,denom:a,continued:!1,hasBarLine:s,barSize:i,leftDelim:null,rightDelim:null,size:"auto"}},htmlBuilder:eM,mathmlBuilder:tM});var oM=(e,t)=>{var r,n,o=t.style;"supsub"===e.type?(r=e.sup?yN(e.sup,t.havingStyle(o.sup()),t):yN(e.sub,t.havingStyle(o.sub()),t),n=jN(e.base,"horizBrace")):n=jN(e,"horizBrace");var i,a=yN(n.base,t.havingBaseStyle(yO.DISPLAY)),s=zN(n,t);if(n.isOver?(i=YT.makeVList({positionType:"firstBaseline",children:[{type:"elem",elem:a},{type:"kern",size:.1},{type:"elem",elem:s}]},t)).children[0].children[0].children[1].classes.push("svg-align"):(i=YT.makeVList({positionType:"bottom",positionData:a.depth+.1+s.height,children:[{type:"elem",elem:s},{type:"kern",size:.1},{type:"elem",elem:a}]},t)).children[0].children[0].children[0].classes.push("svg-align"),r){var u=YT.makeSpan(["mord",n.isOver?"mover":"munder"],[i],t);i=n.isOver?YT.makeVList({positionType:"firstBaseline",children:[{type:"elem",elem:u},{type:"kern",size:.2},{type:"elem",elem:r}]},t):YT.makeVList({positionType:"bottom",positionData:u.depth+.2+r.height+r.depth,children:[{type:"elem",elem:r},{type:"kern",size:.2},{type:"elem",elem:u}]},t)}return YT.makeSpan(["mord",n.isOver?"mover":"munder"],[i],t)};nN({type:"horizBrace",names:["\\overbrace","\\underbrace"],props:{numArgs:1},handler(e,t){var{parser:r,funcName:n}=e;return{type:"horizBrace",mode:r.mode,label:n,isOver:/^\\over/.test(n),base:t[0]}},htmlBuilder:oM,mathmlBuilder:(e,t)=>{var r=_N(e.label);return new AN.MathNode(e.isOver?"mover":"munder",[TN(e.base,t),r])}}),nN({type:"href",names:["\\href"],props:{numArgs:2,argTypes:["url","original"],allowedInText:!0},handler:(e,t)=>{var{parser:r}=e,n=t[1],o=jN(t[0],"url").url;return r.settings.isTrusted({command:"\\href",url:o})?{type:"href",mode:r.mode,href:o,body:aN(n)}:r.formatUnsupportedCmd("\\href")},htmlBuilder:(e,t)=>{var r=hN(e.body,t,!1);return YT.makeAnchor(e.href,[],r,t)},mathmlBuilder:(e,t)=>{var r=ON(e.body,t);return r instanceof wN||(r=new wN("mrow",[r])),r.setAttribute("href",e.href),r}}),nN({type:"href",names:["\\url"],props:{numArgs:1,argTypes:["url"],allowedInText:!0},handler:(e,t)=>{var{parser:r}=e,n=jN(t[0],"url").url;if(!r.settings.isTrusted({command:"\\url",url:n}))return r.formatUnsupportedCmd("\\url");for(var o=[],i=0;i<n.length;i++){var a=n[i];"~"===a&&(a="\\textasciitilde"),o.push({type:"textord",mode:"text",text:a})}var s={type:"text",mode:r.mode,font:"\\texttt",body:o};return{type:"href",mode:r.mode,href:n,body:aN(s)}}}),nN({type:"hbox",names:["\\hbox"],props:{numArgs:1,argTypes:["text"],allowedInText:!0,primitive:!0},handler(e,t){var{parser:r}=e;return{type:"hbox",mode:r.mode,body:aN(t[0])}},htmlBuilder(e,t){var r=hN(e.body,t,!1);return YT.makeFragment(r)},mathmlBuilder:(e,t)=>new AN.MathNode("mrow",kN(e.body,t))}),nN({type:"html",names:["\\htmlClass","\\htmlId","\\htmlStyle","\\htmlData"],props:{numArgs:2,argTypes:["raw","original"],allowedInText:!0},handler:(e,t)=>{var r,{parser:n,funcName:o,token:i}=e,a=jN(t[0],"raw").string,s=t[1];n.settings.strict&&n.settings.reportNonstrict("htmlExtension","HTML extension is disabled on strict mode");var u={};switch(o){case"\\htmlClass":u.class=a,r={command:"\\htmlClass",class:a};break;case"\\htmlId":u.id=a,r={command:"\\htmlId",id:a};break;case"\\htmlStyle":u.style=a,r={command:"\\htmlStyle",style:a};break;case"\\htmlData":for(var l=a.split(","),c=0;c<l.length;c++){var d=l[c].split("=");if(2!==d.length)throw new tO("Error parsing key-value for \\htmlData");u["data-"+d[0].trim()]=d[1].trim()}r={command:"\\htmlData",attributes:u};break;default:throw new Error("Unrecognized html command")}return n.settings.isTrusted(r)?{type:"html",mode:n.mode,attributes:u,body:aN(s)}:n.formatUnsupportedCmd(o)},htmlBuilder:(e,t)=>{var r=hN(e.body,t,!1),n=["enclosing"];e.attributes.class&&n.push(...e.attributes.class.trim().split(/\s+/));var o=YT.makeSpan(n,r,t);for(var i in e.attributes)"class"!==i&&e.attributes.hasOwnProperty(i)&&o.setAttribute(i,e.attributes[i]);return o},mathmlBuilder:(e,t)=>ON(e.body,t)}),nN({type:"htmlmathml",names:["\\html@mathml"],props:{numArgs:2,allowedInText:!0},handler:(e,t)=>{var{parser:r}=e;return{type:"htmlmathml",mode:r.mode,html:aN(t[0]),mathml:aN(t[1])}},htmlBuilder:(e,t)=>{var r=hN(e.html,t,!1);return YT.makeFragment(r)},mathmlBuilder:(e,t)=>ON(e.mathml,t)});var iM=function(e){if(/^[-+]? *(\d+(\.\d*)?|\.\d+)$/.test(e))return{number:+e,unit:"bp"};var t=/([-+]?) *(\d+(?:\.\d*)?|\.\d+) *([a-z]{2})/.exec(e);if(!t)throw new tO("Invalid size: '"+e+"' in \\includegraphics");var r={number:+(t[1]+t[2]),unit:t[3]};if(!RO(r))throw new tO("Invalid unit: '"+r.unit+"' in \\includegraphics.");return r};nN({type:"includegraphics",names:["\\includegraphics"],props:{numArgs:1,numOptionalArgs:1,argTypes:["raw","url"],allowedInText:!1},handler:(e,t,r)=>{var{parser:n}=e,o={number:0,unit:"em"},i={number:.9,unit:"em"},a={number:0,unit:"em"},s="";if(r[0])for(var u=jN(r[0],"raw").string.split(","),l=0;l<u.length;l++){var c=u[l].split("=");if(2===c.length){var d=c[1].trim();switch(c[0].trim()){case"alt":s=d;break;case"width":o=iM(d);break;case"height":i=iM(d);break;case"totalheight":a=iM(d);break;default:throw new tO("Invalid key: '"+c[0]+"' in \\includegraphics.")}}}var h=jN(t[0],"url").url;return""===s&&(s=(s=(s=h).replace(/^.*[\\/]/,"")).substring(0,s.lastIndexOf("."))),n.settings.isTrusted({command:"\\includegraphics",url:h})?{type:"includegraphics",mode:n.mode,alt:s,width:o,height:i,totalheight:a,src:h}:n.formatUnsupportedCmd("\\includegraphics")},htmlBuilder:(e,t)=>{var r=LO(e.height,t),n=0;e.totalheight.number>0&&(n=LO(e.totalheight,t)-r);var o=0;e.width.number>0&&(o=LO(e.width,t));var i={height:_O(r+n)};o>0&&(i.width=_O(o)),n>0&&(i.verticalAlign=_O(-n));var a=new WO(e.src,e.alt,i);return a.height=r,a.depth=n,a},mathmlBuilder:(e,t)=>{var r=new AN.MathNode("mglyph",[]);r.setAttribute("alt",e.alt);var n=LO(e.height,t),o=0;if(e.totalheight.number>0&&(o=LO(e.totalheight,t)-n,r.setAttribute("valign",_O(-o))),r.setAttribute("height",_O(n+o)),e.width.number>0){var i=LO(e.width,t);r.setAttribute("width",_O(i))}return r.setAttribute("src",e.src),r}}),nN({type:"kern",names:["\\kern","\\mkern","\\hskip","\\mskip"],props:{numArgs:1,argTypes:["size"],primitive:!0,allowedInText:!0},handler(e,t){var{parser:r,funcName:n}=e,o=jN(t[0],"size");if(r.settings.strict){var i="m"===n[1],a="mu"===o.value.unit;i?(a||r.settings.reportNonstrict("mathVsTextUnits","LaTeX's "+n+" supports only mu units, not "+o.value.unit+" units"),"math"!==r.mode&&r.settings.reportNonstrict("mathVsTextUnits","LaTeX's "+n+" works only in math mode")):a&&r.settings.reportNonstrict("mathVsTextUnits","LaTeX's "+n+" doesn't support mu units")}return{type:"kern",mode:r.mode,dimension:o.value}},htmlBuilder:(e,t)=>YT.makeGlue(e.dimension,t),mathmlBuilder(e,t){var r=LO(e.dimension,t);return new AN.SpaceNode(r)}}),nN({type:"lap",names:["\\mathllap","\\mathrlap","\\mathclap"],props:{numArgs:1,allowedInText:!0},handler:(e,t)=>{var{parser:r,funcName:n}=e,o=t[0];return{type:"lap",mode:r.mode,alignment:n.slice(5),body:o}},htmlBuilder:(e,t)=>{var r;"clap"===e.alignment?(r=YT.makeSpan([],[yN(e.body,t)]),r=YT.makeSpan(["inner"],[r],t)):r=YT.makeSpan(["inner"],[yN(e.body,t)]);var n=YT.makeSpan(["fix"],[]),o=YT.makeSpan([e.alignment],[r,n],t),i=YT.makeSpan(["strut"]);return i.style.height=_O(o.height+o.depth),o.depth&&(i.style.verticalAlign=_O(-o.depth)),o.children.unshift(i),o=YT.makeSpan(["thinbox"],[o],t),YT.makeSpan(["mord","vbox"],[o],t)},mathmlBuilder:(e,t)=>{var r=new AN.MathNode("mpadded",[TN(e.body,t)]);if("rlap"!==e.alignment){var n="llap"===e.alignment?"-1":"-0.5";r.setAttribute("lspace",n+"width")}return r.setAttribute("width","0px"),r}}),nN({type:"styling",names:["\\(","$"],props:{numArgs:0,allowedInText:!0,allowedInMath:!1},handler(e,t){var{funcName:r,parser:n}=e,o=n.mode;n.switchMode("math");var i="\\("===r?"\\)":"$",a=n.parseExpression(!1,i);return n.expect(i),n.switchMode(o),{type:"styling",mode:n.mode,style:"text",body:a}}}),nN({type:"text",names:["\\)","\\]"],props:{numArgs:0,allowedInText:!0,allowedInMath:!1},handler(e,t){throw new tO("Mismatched "+e.funcName)}});var aM=(e,t)=>{switch(t.style.size){case yO.DISPLAY.size:return e.display;case yO.TEXT.size:return e.text;case yO.SCRIPT.size:return e.script;case yO.SCRIPTSCRIPT.size:return e.scriptscript;default:return e.text}};nN({type:"mathchoice",names:["\\mathchoice"],props:{numArgs:4,primitive:!0},handler:(e,t)=>{var{parser:r}=e;return{type:"mathchoice",mode:r.mode,display:aN(t[0]),text:aN(t[1]),script:aN(t[2]),scriptscript:aN(t[3])}},htmlBuilder:(e,t)=>{var r=aM(e,t),n=hN(r,t,!1);return YT.makeFragment(n)},mathmlBuilder:(e,t)=>{var r=aM(e,t);return ON(r,t)}});var sM=(e,t,r,n,o,i,a)=>{e=YT.makeSpan([],[e]);var s,u,l,c=r&&aO.isCharacterBox(r);if(t){var d=yN(t,n.havingStyle(o.sup()),n);u={elem:d,kern:Math.max(n.fontMetrics().bigOpSpacing1,n.fontMetrics().bigOpSpacing3-d.depth)}}if(r){var h=yN(r,n.havingStyle(o.sub()),n);s={elem:h,kern:Math.max(n.fontMetrics().bigOpSpacing2,n.fontMetrics().bigOpSpacing4-h.height)}}if(u&&s){var f=n.fontMetrics().bigOpSpacing5+s.elem.height+s.elem.depth+s.kern+e.depth+a;l=YT.makeVList({positionType:"bottom",positionData:f,children:[{type:"kern",size:n.fontMetrics().bigOpSpacing5},{type:"elem",elem:s.elem,marginLeft:_O(-i)},{type:"kern",size:s.kern},{type:"elem",elem:e},{type:"kern",size:u.kern},{type:"elem",elem:u.elem,marginLeft:_O(i)},{type:"kern",size:n.fontMetrics().bigOpSpacing5}]},n)}else if(s){var p=e.height-a;l=YT.makeVList({positionType:"top",positionData:p,children:[{type:"kern",size:n.fontMetrics().bigOpSpacing5},{type:"elem",elem:s.elem,marginLeft:_O(-i)},{type:"kern",size:s.kern},{type:"elem",elem:e}]},n)}else{if(!u)return e;var g=e.depth+a;l=YT.makeVList({positionType:"bottom",positionData:g,children:[{type:"elem",elem:e},{type:"kern",size:u.kern},{type:"elem",elem:u.elem,marginLeft:_O(i)},{type:"kern",size:n.fontMetrics().bigOpSpacing5}]},n)}var m=[l];if(s&&0!==i&&!c){var v=YT.makeSpan(["mspace"],[],n);v.style.marginRight=_O(i),m.unshift(v)}return YT.makeSpan(["mop","op-limits"],m,n)},uM=["\\smallint"],lM=(e,t)=>{var r,n,o,i=!1;"supsub"===e.type?(r=e.sup,n=e.sub,o=jN(e.base,"op"),i=!0):o=jN(e,"op");var a,s=t.style,u=!1;if(s.size===yO.DISPLAY.size&&o.symbol&&!aO.contains(uM,o.name)&&(u=!0),o.symbol){var l=u?"Size2-Regular":"Size1-Regular",c="";if("\\oiint"!==o.name&&"\\oiiint"!==o.name||(c=o.name.slice(1),o.name="oiint"===c?"\\iint":"\\iiint"),a=YT.makeSymbol(o.name,l,"math",t,["mop","op-symbol",u?"large-op":"small-op"]),c.length>0){var d=a.italic,h=YT.staticSvg(c+"Size"+(u?"2":"1"),t);a=YT.makeVList({positionType:"individualShift",children:[{type:"elem",elem:a,shift:0},{type:"elem",elem:h,shift:u?.08:0}]},t),o.name="\\"+c,a.classes.unshift("mop"),a.italic=d}}else if(o.body){var f=hN(o.body,t,!0);1===f.length&&f[0]instanceof YO?(a=f[0]).classes[0]="mop":a=YT.makeSpan(["mop"],f,t)}else{for(var p=[],g=1;g<o.name.length;g++)p.push(YT.mathsym(o.name[g],o.mode,t));a=YT.makeSpan(["mop"],p,t)}var m=0,v=0;return(a instanceof YO||"\\oiint"===o.name||"\\oiiint"===o.name)&&!o.suppressBaseShift&&(m=(a.height-a.depth)/2-t.fontMetrics().axisHeight,v=a.italic),i?sM(a,r,n,t,s,v,m):(m&&(a.style.position="relative",a.style.top=_O(m)),a)},cM=(e,t)=>{var r;if(e.symbol)r=new wN("mo",[xN(e.name,e.mode)]),aO.contains(uM,e.name)&&r.setAttribute("largeop","false");else if(e.body)r=new wN("mo",kN(e.body,t));else{r=new wN("mi",[new EN(e.name.slice(1))]);var n=new wN("mo",[xN("","text")]);r=e.parentIsSupSub?new wN("mrow",[r,n]):CN([r,n])}return r},dM={"∏":"\\prod","∐":"\\coprod","∑":"\\sum","⋀":"\\bigwedge","⋁":"\\bigvee","⋂":"\\bigcap","⋃":"\\bigcup","⨀":"\\bigodot","⨁":"\\bigoplus","⨂":"\\bigotimes","⨄":"\\biguplus","⨆":"\\bigsqcup"};nN({type:"op",names:["\\coprod","\\bigvee","\\bigwedge","\\biguplus","\\bigcap","\\bigcup","\\intop","\\prod","\\sum","\\bigotimes","\\bigoplus","\\bigodot","\\bigsqcup","\\smallint","∏","∐","∑","⋀","⋁","⋂","⋃","⨀","⨁","⨂","⨄","⨆"],props:{numArgs:0},handler:(e,t)=>{var{parser:r,funcName:n}=e,o=n;return 1===o.length&&(o=dM[o]),{type:"op",mode:r.mode,limits:!0,parentIsSupSub:!1,symbol:!0,name:o}},htmlBuilder:lM,mathmlBuilder:cM}),nN({type:"op",names:["\\mathop"],props:{numArgs:1,primitive:!0},handler:(e,t)=>{var{parser:r}=e,n=t[0];return{type:"op",mode:r.mode,limits:!1,parentIsSupSub:!1,symbol:!1,body:aN(n)}},htmlBuilder:lM,mathmlBuilder:cM});var hM={"∫":"\\int","∬":"\\iint","∭":"\\iiint","∮":"\\oint","∯":"\\oiint","∰":"\\oiiint"};nN({type:"op",names:["\\arcsin","\\arccos","\\arctan","\\arctg","\\arcctg","\\arg","\\ch","\\cos","\\cosec","\\cosh","\\cot","\\cotg","\\coth","\\csc","\\ctg","\\cth","\\deg","\\dim","\\exp","\\hom","\\ker","\\lg","\\ln","\\log","\\sec","\\sin","\\sinh","\\sh","\\tan","\\tanh","\\tg","\\th"],props:{numArgs:0},handler(e){var{parser:t,funcName:r}=e;return{type:"op",mode:t.mode,limits:!1,parentIsSupSub:!1,symbol:!1,name:r}},htmlBuilder:lM,mathmlBuilder:cM}),nN({type:"op",names:["\\det","\\gcd","\\inf","\\lim","\\max","\\min","\\Pr","\\sup"],props:{numArgs:0},handler(e){var{parser:t,funcName:r}=e;return{type:"op",mode:t.mode,limits:!0,parentIsSupSub:!1,symbol:!1,name:r}},htmlBuilder:lM,mathmlBuilder:cM}),nN({type:"op",names:["\\int","\\iint","\\iiint","\\oint","\\oiint","\\oiiint","∫","∬","∭","∮","∯","∰"],props:{numArgs:0},handler(e){var{parser:t,funcName:r}=e,n=r;return 1===n.length&&(n=hM[n]),{type:"op",mode:t.mode,limits:!1,parentIsSupSub:!1,symbol:!0,name:n}},htmlBuilder:lM,mathmlBuilder:cM});var fM=(e,t)=>{var r,n,o,i,a=!1;if("supsub"===e.type?(r=e.sup,n=e.sub,o=jN(e.base,"operatorname"),a=!0):o=jN(e,"operatorname"),o.body.length>0){for(var s=o.body.map(e=>{var t=e.text;return"string"==typeof t?{type:"textord",mode:e.mode,text:t}:e}),u=hN(s,t.withFont("mathrm"),!0),l=0;l<u.length;l++){var c=u[l];c instanceof YO&&(c.text=c.text.replace(/\u2212/,"-").replace(/\u2217/,"*"))}i=YT.makeSpan(["mop"],u,t)}else i=YT.makeSpan(["mop"],[],t);return a?sM(i,r,n,t,t.style,0,0):i};function pM(e,t,r){for(var n=hN(e,t,!1),o=t.sizeMultiplier/r.sizeMultiplier,i=0;i<n.length;i++){var a=n[i].classes.indexOf("sizing");a<0?Array.prototype.push.apply(n[i].classes,t.sizingClasses(r)):n[i].classes[a+1]==="reset-size"+t.size&&(n[i].classes[a+1]="reset-size"+r.size),n[i].height*=o,n[i].depth*=o}return YT.makeFragment(n)}nN({type:"operatorname",names:["\\operatorname@","\\operatornamewithlimits"],props:{numArgs:1},handler:(e,t)=>{var{parser:r,funcName:n}=e,o=t[0];return{type:"operatorname",mode:r.mode,body:aN(o),alwaysHandleSupSub:"\\operatornamewithlimits"===n,limits:!1,parentIsSupSub:!1}},htmlBuilder:fM,mathmlBuilder:(e,t)=>{for(var r=kN(e.body,t.withFont("mathrm")),n=!0,o=0;o<r.length;o++){var i=r[o];if(i instanceof AN.SpaceNode);else if(i instanceof AN.MathNode)switch(i.type){case"mi":case"mn":case"ms":case"mspace":case"mtext":break;case"mo":var a=i.children[0];1===i.children.length&&a instanceof AN.TextNode?a.text=a.text.replace(/\u2212/,"-").replace(/\u2217/,"*"):n=!1;break;default:n=!1}else n=!1}if(n){var s=r.map(e=>e.toText()).join("");r=[new AN.TextNode(s)]}var u=new AN.MathNode("mi",r);u.setAttribute("mathvariant","normal");var l=new AN.MathNode("mo",[xN("","text")]);return e.parentIsSupSub?new AN.MathNode("mrow",[u,l]):AN.newDocumentFragment([u,l])}}),zP("\\operatorname","\\@ifstar\\operatornamewithlimits\\operatorname@"),oN({type:"ordgroup",htmlBuilder:(e,t)=>e.semisimple?YT.makeFragment(hN(e.body,t,!1)):YT.makeSpan(["mord"],hN(e.body,t,!0),t),mathmlBuilder:(e,t)=>ON(e.body,t,!0)}),nN({type:"overline",names:["\\overline"],props:{numArgs:1},handler(e,t){var{parser:r}=e,n=t[0];return{type:"overline",mode:r.mode,body:n}},htmlBuilder(e,t){var r=yN(e.body,t.havingCrampedStyle()),n=YT.makeLineSpan("overline-line",t),o=t.fontMetrics().defaultRuleThickness,i=YT.makeVList({positionType:"firstBaseline",children:[{type:"elem",elem:r},{type:"kern",size:3*o},{type:"elem",elem:n},{type:"kern",size:o}]},t);return YT.makeSpan(["mord","overline"],[i],t)},mathmlBuilder(e,t){var r=new AN.MathNode("mo",[new AN.TextNode("‾")]);r.setAttribute("stretchy","true");var n=new AN.MathNode("mover",[TN(e.body,t),r]);return n.setAttribute("accent","true"),n}}),nN({type:"phantom",names:["\\phantom"],props:{numArgs:1,allowedInText:!0},handler:(e,t)=>{var{parser:r}=e,n=t[0];return{type:"phantom",mode:r.mode,body:aN(n)}},htmlBuilder:(e,t)=>{var r=hN(e.body,t.withPhantom(),!1);return YT.makeFragment(r)},mathmlBuilder:(e,t)=>{var r=kN(e.body,t);return new AN.MathNode("mphantom",r)}}),nN({type:"hphantom",names:["\\hphantom"],props:{numArgs:1,allowedInText:!0},handler:(e,t)=>{var{parser:r}=e,n=t[0];return{type:"hphantom",mode:r.mode,body:n}},htmlBuilder:(e,t)=>{var r=YT.makeSpan([],[yN(e.body,t.withPhantom())]);if(r.height=0,r.depth=0,r.children)for(var n=0;n<r.children.length;n++)r.children[n].height=0,r.children[n].depth=0;return r=YT.makeVList({positionType:"firstBaseline",children:[{type:"elem",elem:r}]},t),YT.makeSpan(["mord"],[r],t)},mathmlBuilder:(e,t)=>{var r=kN(aN(e.body),t),n=new AN.MathNode("mphantom",r),o=new AN.MathNode("mpadded",[n]);return o.setAttribute("height","0px"),o.setAttribute("depth","0px"),o}}),nN({type:"vphantom",names:["\\vphantom"],props:{numArgs:1,allowedInText:!0},handler:(e,t)=>{var{parser:r}=e,n=t[0];return{type:"vphantom",mode:r.mode,body:n}},htmlBuilder:(e,t)=>{var r=YT.makeSpan(["inner"],[yN(e.body,t.withPhantom())]),n=YT.makeSpan(["fix"],[]);return YT.makeSpan(["mord","rlap"],[r,n],t)},mathmlBuilder:(e,t)=>{var r=kN(aN(e.body),t),n=new AN.MathNode("mphantom",r),o=new AN.MathNode("mpadded",[n]);return o.setAttribute("width","0px"),o}}),nN({type:"raisebox",names:["\\raisebox"],props:{numArgs:2,argTypes:["size","hbox"],allowedInText:!0},handler(e,t){var{parser:r}=e,n=jN(t[0],"size").value,o=t[1];return{type:"raisebox",mode:r.mode,dy:n,body:o}},htmlBuilder(e,t){var r=yN(e.body,t),n=LO(e.dy,t);return YT.makeVList({positionType:"shift",positionData:-n,children:[{type:"elem",elem:r}]},t)},mathmlBuilder(e,t){var r=new AN.MathNode("mpadded",[TN(e.body,t)]),n=e.dy.number+e.dy.unit;return r.setAttribute("voffset",n),r}}),nN({type:"internal",names:["\\relax"],props:{numArgs:0,allowedInText:!0,allowedInArgument:!0},handler(e){var{parser:t}=e;return{type:"internal",mode:t.mode}}}),nN({type:"rule",names:["\\rule"],props:{numArgs:2,numOptionalArgs:1,allowedInText:!0,allowedInMath:!0,argTypes:["size","size","size"]},handler(e,t,r){var{parser:n}=e,o=r[0],i=jN(t[0],"size"),a=jN(t[1],"size");return{type:"rule",mode:n.mode,shift:o&&jN(o,"size").value,width:i.value,height:a.value}},htmlBuilder(e,t){var r=YT.makeSpan(["mord","rule"],[],t),n=LO(e.width,t),o=LO(e.height,t),i=e.shift?LO(e.shift,t):0;return r.style.borderRightWidth=_O(n),r.style.borderTopWidth=_O(o),r.style.bottom=_O(i),r.width=n,r.height=o+i,r.depth=-i,r.maxFontSize=1.125*o*t.sizeMultiplier,r},mathmlBuilder(e,t){var r=LO(e.width,t),n=LO(e.height,t),o=e.shift?LO(e.shift,t):0,i=t.color&&t.getColor()||"black",a=new AN.MathNode("mspace");a.setAttribute("mathbackground",i),a.setAttribute("width",_O(r)),a.setAttribute("height",_O(n));var s=new AN.MathNode("mpadded",[a]);return o>=0?s.setAttribute("height",_O(o)):(s.setAttribute("height",_O(o)),s.setAttribute("depth",_O(-o))),s.setAttribute("voffset",_O(o)),s}});var gM=["\\tiny","\\sixptsize","\\scriptsize","\\footnotesize","\\small","\\normalsize","\\large","\\Large","\\LARGE","\\huge","\\Huge"];nN({type:"sizing",names:gM,props:{numArgs:0,allowedInText:!0},handler:(e,t)=>{var{breakOnTokenText:r,funcName:n,parser:o}=e,i=o.parseExpression(!1,r);return{type:"sizing",mode:o.mode,size:gM.indexOf(n)+1,body:i}},htmlBuilder:(e,t)=>{var r=t.havingSize(e.size);return pM(e.body,r,t)},mathmlBuilder:(e,t)=>{var r=t.havingSize(e.size),n=kN(e.body,r),o=new AN.MathNode("mstyle",n);return o.setAttribute("mathsize",_O(r.sizeMultiplier)),o}}),nN({type:"smash",names:["\\smash"],props:{numArgs:1,numOptionalArgs:1,allowedInText:!0},handler:(e,t,r)=>{var{parser:n}=e,o=!1,i=!1,a=r[0]&&jN(r[0],"ordgroup");if(a)for(var s="",u=0;u<a.body.length;++u){if("t"===(s=a.body[u].text))o=!0;else{if("b"!==s){o=!1,i=!1;break}i=!0}}else o=!0,i=!0;var l=t[0];return{type:"smash",mode:n.mode,body:l,smashHeight:o,smashDepth:i}},htmlBuilder:(e,t)=>{var r=YT.makeSpan([],[yN(e.body,t)]);if(!e.smashHeight&&!e.smashDepth)return r;if(e.smashHeight&&(r.height=0,r.children))for(var n=0;n<r.children.length;n++)r.children[n].height=0;if(e.smashDepth&&(r.depth=0,r.children))for(var o=0;o<r.children.length;o++)r.children[o].depth=0;var i=YT.makeVList({positionType:"firstBaseline",children:[{type:"elem",elem:r}]},t);return YT.makeSpan(["mord"],[i],t)},mathmlBuilder:(e,t)=>{var r=new AN.MathNode("mpadded",[TN(e.body,t)]);return e.smashHeight&&r.setAttribute("height","0px"),e.smashDepth&&r.setAttribute("depth","0px"),r}}),nN({type:"sqrt",names:["\\sqrt"],props:{numArgs:1,numOptionalArgs:1},handler(e,t,r){var{parser:n}=e,o=r[0],i=t[0];return{type:"sqrt",mode:n.mode,body:i,index:o}},htmlBuilder(e,t){var r=yN(e.body,t.havingCrampedStyle());0===r.height&&(r.height=t.fontMetrics().xHeight),r=YT.wrapFragment(r,t);var n=t.fontMetrics().defaultRuleThickness,o=n;t.style.id<yO.TEXT.id&&(o=t.fontMetrics().xHeight);var i=n+o/4,a=r.height+r.depth+i+n,{span:s,ruleWidth:u,advanceWidth:l}=kP.sqrtImage(a,t),c=s.height-u;c>r.height+r.depth+i&&(i=(i+c-r.height-r.depth)/2);var d=s.height-r.height-i-u;r.style.paddingLeft=_O(l);var h=YT.makeVList({positionType:"firstBaseline",children:[{type:"elem",elem:r,wrapperClasses:["svg-align"]},{type:"kern",size:-(r.height+d)},{type:"elem",elem:s},{type:"kern",size:u}]},t);if(e.index){var f=t.havingStyle(yO.SCRIPTSCRIPT),p=yN(e.index,f,t),g=.6*(h.height-h.depth),m=YT.makeVList({positionType:"shift",positionData:-g,children:[{type:"elem",elem:p}]},t),v=YT.makeSpan(["root"],[m]);return YT.makeSpan(["mord","sqrt"],[v,h],t)}return YT.makeSpan(["mord","sqrt"],[h],t)},mathmlBuilder(e,t){var{body:r,index:n}=e;return n?new AN.MathNode("mroot",[TN(r,t),TN(n,t)]):new AN.MathNode("msqrt",[TN(r,t)])}});var mM={display:yO.DISPLAY,text:yO.TEXT,script:yO.SCRIPT,scriptscript:yO.SCRIPTSCRIPT};nN({type:"styling",names:["\\displaystyle","\\textstyle","\\scriptstyle","\\scriptscriptstyle"],props:{numArgs:0,allowedInText:!0,primitive:!0},handler(e,t){var{breakOnTokenText:r,funcName:n,parser:o}=e,i=o.parseExpression(!0,r),a=n.slice(1,n.length-5);return{type:"styling",mode:o.mode,style:a,body:i}},htmlBuilder(e,t){var r=mM[e.style],n=t.havingStyle(r).withFont("");return pM(e.body,n,t)},mathmlBuilder(e,t){var r=mM[e.style],n=t.havingStyle(r),o=kN(e.body,n),i=new AN.MathNode("mstyle",o),a={display:["0","true"],text:["0","false"],script:["1","false"],scriptscript:["2","false"]}[e.style];return i.setAttribute("scriptlevel",a[0]),i.setAttribute("displaystyle",a[1]),i}});oN({type:"supsub",htmlBuilder(e,t){var r=function(e,t){var r=e.base;return r?"op"===r.type?r.limits&&(t.style.size===yO.DISPLAY.size||r.alwaysHandleSupSub)?lM:null:"operatorname"===r.type?r.alwaysHandleSupSub&&(t.style.size===yO.DISPLAY.size||r.limits)?fM:null:"accent"===r.type?aO.isCharacterBox(r.base)?$N:null:"horizBrace"===r.type&&!e.sub===r.isOver?oM:null:null}(e,t);if(r)return r(e,t);var n,o,i,{base:a,sup:s,sub:u}=e,l=yN(a,t),c=t.fontMetrics(),d=0,h=0,f=a&&aO.isCharacterBox(a);if(s){var p=t.havingStyle(t.style.sup());n=yN(s,p,t),f||(d=l.height-p.fontMetrics().supDrop*p.sizeMultiplier/t.sizeMultiplier)}if(u){var g=t.havingStyle(t.style.sub());o=yN(u,g,t),f||(h=l.depth+g.fontMetrics().subDrop*g.sizeMultiplier/t.sizeMultiplier)}i=t.style===yO.DISPLAY?c.sup1:t.style.cramped?c.sup3:c.sup2;var m,v=t.sizeMultiplier,y=_O(.5/c.ptPerEm/v),b=null;if(o){var D=e.base&&"op"===e.base.type&&e.base.name&&("\\oiint"===e.base.name||"\\oiiint"===e.base.name);(l instanceof YO||D)&&(b=_O(-l.italic))}if(n&&o){d=Math.max(d,i,n.depth+.25*c.xHeight),h=Math.max(h,c.sub2);var C=4*c.defaultRuleThickness;if(d-n.depth-(o.height-h)<C){h=C-(d-n.depth)+o.height;var w=.8*c.xHeight-(d-n.depth);w>0&&(d+=w,h-=w)}var E=[{type:"elem",elem:o,shift:h,marginRight:y,marginLeft:b},{type:"elem",elem:n,shift:-d,marginRight:y}];m=YT.makeVList({positionType:"individualShift",children:E},t)}else if(o){h=Math.max(h,c.sub1,o.height-.8*c.xHeight);var A=[{type:"elem",elem:o,marginLeft:b,marginRight:y}];m=YT.makeVList({positionType:"shift",positionData:h,children:A},t)}else{if(!n)throw new Error("supsub must have either sup or sub.");d=Math.max(d,i,n.depth+.25*c.xHeight),m=YT.makeVList({positionType:"shift",positionData:-d,children:[{type:"elem",elem:n,marginRight:y}]},t)}var x=mN(l,"right")||"mord";return YT.makeSpan([x],[l,YT.makeSpan(["msupsub"],[m])],t)},mathmlBuilder(e,t){var r,n=!1;e.base&&"horizBrace"===e.base.type&&!!e.sup===e.base.isOver&&(n=!0,r=e.base.isOver),!e.base||"op"!==e.base.type&&"operatorname"!==e.base.type||(e.base.parentIsSupSub=!0);var o,i=[TN(e.base,t)];if(e.sub&&i.push(TN(e.sub,t)),e.sup&&i.push(TN(e.sup,t)),n)o=r?"mover":"munder";else if(e.sub)if(e.sup){var a=e.base;o=a&&"op"===a.type&&a.limits&&t.style===yO.DISPLAY||a&&"operatorname"===a.type&&a.alwaysHandleSupSub&&(t.style===yO.DISPLAY||a.limits)?"munderover":"msubsup"}else{var s=e.base;o=s&&"op"===s.type&&s.limits&&(t.style===yO.DISPLAY||s.alwaysHandleSupSub)||s&&"operatorname"===s.type&&s.alwaysHandleSupSub&&(s.limits||t.style===yO.DISPLAY)?"munder":"msub"}else{var u=e.base;o=u&&"op"===u.type&&u.limits&&(t.style===yO.DISPLAY||u.alwaysHandleSupSub)||u&&"operatorname"===u.type&&u.alwaysHandleSupSub&&(u.limits||t.style===yO.DISPLAY)?"mover":"msup"}return new AN.MathNode(o,i)}}),oN({type:"atom",htmlBuilder:(e,t)=>YT.mathsym(e.text,e.mode,t,["m"+e.family]),mathmlBuilder(e,t){var r=new AN.MathNode("mo",[xN(e.text,e.mode)]);if("bin"===e.family){var n=SN(e,t);"bold-italic"===n&&r.setAttribute("mathvariant",n)}else"punct"===e.family?r.setAttribute("separator","true"):"open"!==e.family&&"close"!==e.family||r.setAttribute("stretchy","false");return r}});var vM={mi:"italic",mn:"normal",mtext:"normal"};oN({type:"mathord",htmlBuilder:(e,t)=>YT.makeOrd(e,t,"mathord"),mathmlBuilder(e,t){var r=new AN.MathNode("mi",[xN(e.text,e.mode,t)]),n=SN(e,t)||"italic";return n!==vM[r.type]&&r.setAttribute("mathvariant",n),r}}),oN({type:"textord",htmlBuilder:(e,t)=>YT.makeOrd(e,t,"textord"),mathmlBuilder(e,t){var r,n=xN(e.text,e.mode,t),o=SN(e,t)||"normal";return r="text"===e.mode?new AN.MathNode("mtext",[n]):/[0-9]/.test(e.text)?new AN.MathNode("mn",[n]):"\\prime"===e.text?new AN.MathNode("mo",[n]):new AN.MathNode("mi",[n]),o!==vM[r.type]&&r.setAttribute("mathvariant",o),r}});var yM={"\\nobreak":"nobreak","\\allowbreak":"allowbreak"},bM={" ":{},"\\ ":{},"~":{className:"nobreak"},"\\space":{},"\\nobreakspace":{className:"nobreak"}};oN({type:"spacing",htmlBuilder(e,t){if(bM.hasOwnProperty(e.text)){var r=bM[e.text].className||"";if("text"===e.mode){var n=YT.makeOrd(e,t,"textord");return n.classes.push(r),n}return YT.makeSpan(["mspace",r],[YT.mathsym(e.text,e.mode,t)],t)}if(yM.hasOwnProperty(e.text))return YT.makeSpan(["mspace",yM[e.text]],[],t);throw new tO('Unknown type of space "'+e.text+'"')},mathmlBuilder(e,t){if(!bM.hasOwnProperty(e.text)){if(yM.hasOwnProperty(e.text))return new AN.MathNode("mspace");throw new tO('Unknown type of space "'+e.text+'"')}return new AN.MathNode("mtext",[new AN.TextNode(" ")])}});var DM=()=>{var e=new AN.MathNode("mtd",[]);return e.setAttribute("width","50%"),e};oN({type:"tag",mathmlBuilder(e,t){var r=new AN.MathNode("mtable",[new AN.MathNode("mtr",[DM(),new AN.MathNode("mtd",[ON(e.body,t)]),DM(),new AN.MathNode("mtd",[ON(e.tag,t)])])]);return r.setAttribute("width","100%"),r}});var CM={"\\text":void 0,"\\textrm":"textrm","\\textsf":"textsf","\\texttt":"texttt","\\textnormal":"textrm"},wM={"\\textbf":"textbf","\\textmd":"textmd"},EM={"\\textit":"textit","\\textup":"textup"},AM=(e,t)=>{var r=e.font;return r?CM[r]?t.withTextFontFamily(CM[r]):wM[r]?t.withTextFontWeight(wM[r]):"\\emph"===r?"textit"===t.fontShape?t.withTextFontShape("textup"):t.withTextFontShape("textit"):t.withTextFontShape(EM[r]):t};nN({type:"text",names:["\\text","\\textrm","\\textsf","\\texttt","\\textnormal","\\textbf","\\textmd","\\textit","\\textup","\\emph"],props:{numArgs:1,argTypes:["text"],allowedInArgument:!0,allowedInText:!0},handler(e,t){var{parser:r,funcName:n}=e,o=t[0];return{type:"text",mode:r.mode,body:aN(o),font:n}},htmlBuilder(e,t){var r=AM(e,t),n=hN(e.body,r,!0);return YT.makeSpan(["mord","text"],n,r)},mathmlBuilder(e,t){var r=AM(e,t);return ON(e.body,r)}}),nN({type:"underline",names:["\\underline"],props:{numArgs:1,allowedInText:!0},handler(e,t){var{parser:r}=e;return{type:"underline",mode:r.mode,body:t[0]}},htmlBuilder(e,t){var r=yN(e.body,t),n=YT.makeLineSpan("underline-line",t),o=t.fontMetrics().defaultRuleThickness,i=YT.makeVList({positionType:"top",positionData:r.height,children:[{type:"kern",size:o},{type:"elem",elem:n},{type:"kern",size:3*o},{type:"elem",elem:r}]},t);return YT.makeSpan(["mord","underline"],[i],t)},mathmlBuilder(e,t){var r=new AN.MathNode("mo",[new AN.TextNode("‾")]);r.setAttribute("stretchy","true");var n=new AN.MathNode("munder",[TN(e.body,t),r]);return n.setAttribute("accentunder","true"),n}}),nN({type:"vcenter",names:["\\vcenter"],props:{numArgs:1,argTypes:["original"],allowedInText:!1},handler(e,t){var{parser:r}=e;return{type:"vcenter",mode:r.mode,body:t[0]}},htmlBuilder(e,t){var r=yN(e.body,t),n=t.fontMetrics().axisHeight,o=.5*(r.height-n-(r.depth+n));return YT.makeVList({positionType:"shift",positionData:o,children:[{type:"elem",elem:r}]},t)},mathmlBuilder:(e,t)=>new AN.MathNode("mpadded",[TN(e.body,t)],["vcenter"])}),nN({type:"verb",names:["\\verb"],props:{numArgs:0,allowedInText:!0},handler(e,t,r){throw new tO("\\verb ended by end of line instead of matching delimiter")},htmlBuilder(e,t){for(var r=xM(e),n=[],o=t.havingStyle(t.style.text()),i=0;i<r.length;i++){var a=r[i];"~"===a&&(a="\\textasciitilde"),n.push(YT.makeSymbol(a,"Typewriter-Regular",e.mode,o,["mord","texttt"]))}return YT.makeSpan(["mord","text"].concat(o.sizingClasses(t)),YT.tryCombineChars(n),o)},mathmlBuilder(e,t){var r=new AN.TextNode(xM(e)),n=new AN.MathNode("mtext",[r]);return n.setAttribute("mathvariant","monospace"),n}});var xM=e=>e.body.replace(/ /g,e.star?"␣":" "),BM=eN,SM="[ \r\n\t]",FM="(\\\\[a-zA-Z@]+)"+SM+"*",kM="[̀-ͯ]",OM=new RegExp(kM+"+$"),TM="("+SM+"+)|\\\\(\n|[ \r\t]+\n?)[ \r\t]*|([!-\\[\\]-‧-豈-]"+kM+"*|[\ud800-\udbff][\udc00-\udfff]"+kM+"*|\\\\verb\\*([^]).*?\\4|\\\\verb([^*a-zA-Z]).*?\\5|"+FM+"|\\\\[^\ud800-\udfff])";class NM{constructor(e,t){this.input=void 0,this.settings=void 0,this.tokenRegex=void 0,this.catcodes=void 0,this.input=e,this.settings=t,this.tokenRegex=new RegExp(TM,"g"),this.catcodes={"%":14,"~":13}}setCatcode(e,t){this.catcodes[e]=t}lex(){var e=this.input,t=this.tokenRegex.lastIndex;if(t===e.length)return new eO("EOF",new Qk(this,t,t));var r=this.tokenRegex.exec(e);if(null===r||r.index!==t)throw new tO("Unexpected character: '"+e[t]+"'",new eO(e[t],new Qk(this,t,t+1)));var n=r[6]||r[3]||(r[2]?"\\ ":" ");if(14===this.catcodes[n]){var o=e.indexOf("\n",this.tokenRegex.lastIndex);return-1===o?(this.tokenRegex.lastIndex=e.length,this.settings.reportNonstrict("commentAtEnd","% comment has no terminating newline; LaTeX would fail because of commenting the end of math mode (e.g. $)")):this.tokenRegex.lastIndex=o+1,this.lex()}return new eO(n,new Qk(this,t,this.tokenRegex.lastIndex))}}class PM{constructor(e,t){void 0===e&&(e={}),void 0===t&&(t={}),this.current=void 0,this.builtins=void 0,this.undefStack=void 0,this.current=t,this.builtins=e,this.undefStack=[]}beginGroup(){this.undefStack.push({})}endGroup(){if(0===this.undefStack.length)throw new tO("Unbalanced namespace destruction: attempt to pop global namespace; please report this as a bug");var e=this.undefStack.pop();for(var t in e)e.hasOwnProperty(t)&&(null==e[t]?delete this.current[t]:this.current[t]=e[t])}endGroups(){for(;this.undefStack.length>0;)this.endGroup()}has(e){return this.current.hasOwnProperty(e)||this.builtins.hasOwnProperty(e)}get(e){return this.current.hasOwnProperty(e)?this.current[e]:this.builtins[e]}set(e,t,r){if(void 0===r&&(r=!1),r){for(var n=0;n<this.undefStack.length;n++)delete this.undefStack[n][e];this.undefStack.length>0&&(this.undefStack[this.undefStack.length-1][e]=t)}else{var o=this.undefStack[this.undefStack.length-1];o&&!o.hasOwnProperty(e)&&(o[e]=this.current[e])}null==t?delete this.current[e]:this.current[e]=t}}var MM=_P;zP("\\noexpand",function(e){var t=e.popToken();return e.isExpandable(t.text)&&(t.noexpand=!0,t.treatAsRelax=!0),{tokens:[t],numArgs:0}}),zP("\\expandafter",function(e){var t=e.popToken();return e.expandOnce(!0),{tokens:[t],numArgs:0}}),zP("\\@firstoftwo",function(e){return{tokens:e.consumeArgs(2)[0],numArgs:0}}),zP("\\@secondoftwo",function(e){return{tokens:e.consumeArgs(2)[1],numArgs:0}}),zP("\\@ifnextchar",function(e){var t=e.consumeArgs(3);e.consumeSpaces();var r=e.future();return 1===t[0].length&&t[0][0].text===r.text?{tokens:t[1],numArgs:0}:{tokens:t[2],numArgs:0}}),zP("\\@ifstar","\\@ifnextchar *{\\@firstoftwo{#1}}"),zP("\\TextOrMath",function(e){var t=e.consumeArgs(2);return"text"===e.mode?{tokens:t[0],numArgs:0}:{tokens:t[1],numArgs:0}});var IM={0:0,1:1,2:2,3:3,4:4,5:5,6:6,7:7,8:8,9:9,a:10,A:10,b:11,B:11,c:12,C:12,d:13,D:13,e:14,E:14,f:15,F:15};zP("\\char",function(e){var t,r=e.popToken(),n="";if("'"===r.text)t=8,r=e.popToken();else if('"'===r.text)t=16,r=e.popToken();else if("`"===r.text)if("\\"===(r=e.popToken()).text[0])n=r.text.charCodeAt(1);else{if("EOF"===r.text)throw new tO("\\char` missing argument");n=r.text.charCodeAt(0)}else t=10;if(t){if(null==(n=IM[r.text])||n>=t)throw new tO("Invalid base-"+t+" digit "+r.text);for(var o;null!=(o=IM[e.future().text])&&o<t;)n*=t,n+=o,e.popToken()}return"\\@char{"+n+"}"});var RM=(e,t,r,n)=>{var o=e.consumeArg().tokens;if(1!==o.length)throw new tO("\\newcommand's first argument must be a macro name");var i=o[0].text,a=e.isDefined(i);if(a&&!t)throw new tO("\\newcommand{"+i+"} attempting to redefine "+i+"; use \\renewcommand");if(!a&&!r)throw new tO("\\renewcommand{"+i+"} when command "+i+" does not yet exist; use \\newcommand");var s=0;if(1===(o=e.consumeArg().tokens).length&&"["===o[0].text){for(var u="",l=e.expandNextToken();"]"!==l.text&&"EOF"!==l.text;)u+=l.text,l=e.expandNextToken();if(!u.match(/^\s*[0-9]+\s*$/))throw new tO("Invalid number of arguments: "+u);s=parseInt(u),o=e.consumeArg().tokens}return a&&n||e.macros.set(i,{tokens:o,numArgs:s}),""};zP("\\newcommand",e=>RM(e,!1,!0,!1)),zP("\\renewcommand",e=>RM(e,!0,!1,!1)),zP("\\providecommand",e=>RM(e,!0,!0,!0)),zP("\\message",e=>{var t=e.consumeArgs(1)[0];return console.log(t.reverse().map(e=>e.text).join("")),""}),zP("\\errmessage",e=>{var t=e.consumeArgs(1)[0];return console.error(t.reverse().map(e=>e.text).join("")),""}),zP("\\show",e=>{var t=e.popToken(),r=t.text;return console.log(t,e.macros.get(r),BM[r],tT.math[r],tT.text[r]),""}),zP("\\bgroup","{"),zP("\\egroup","}"),zP("~","\\nobreakspace"),zP("\\lq","`"),zP("\\rq","'"),zP("\\aa","\\r a"),zP("\\AA","\\r A"),zP("\\textcopyright","\\html@mathml{\\textcircled{c}}{\\char`©}"),zP("\\copyright","\\TextOrMath{\\textcopyright}{\\text{\\textcopyright}}"),zP("\\textregistered","\\html@mathml{\\textcircled{\\scriptsize R}}{\\char`®}"),zP("ℬ","\\mathscr{B}"),zP("ℰ","\\mathscr{E}"),zP("ℱ","\\mathscr{F}"),zP("ℋ","\\mathscr{H}"),zP("ℐ","\\mathscr{I}"),zP("ℒ","\\mathscr{L}"),zP("ℳ","\\mathscr{M}"),zP("ℛ","\\mathscr{R}"),zP("ℭ","\\mathfrak{C}"),zP("ℌ","\\mathfrak{H}"),zP("ℨ","\\mathfrak{Z}"),zP("\\Bbbk","\\Bbb{k}"),zP("·","\\cdotp"),zP("\\llap","\\mathllap{\\textrm{#1}}"),zP("\\rlap","\\mathrlap{\\textrm{#1}}"),zP("\\clap","\\mathclap{\\textrm{#1}}"),zP("\\mathstrut","\\vphantom{(}"),zP("\\underbar","\\underline{\\text{#1}}"),zP("\\not",'\\html@mathml{\\mathrel{\\mathrlap\\@not}}{\\char"338}'),zP("\\neq","\\html@mathml{\\mathrel{\\not=}}{\\mathrel{\\char`≠}}"),zP("\\ne","\\neq"),zP("≠","\\neq"),zP("\\notin","\\html@mathml{\\mathrel{{\\in}\\mathllap{/\\mskip1mu}}}{\\mathrel{\\char`∉}}"),zP("∉","\\notin"),zP("≘","\\html@mathml{\\mathrel{=\\kern{-1em}\\raisebox{0.4em}{$\\scriptsize\\frown$}}}{\\mathrel{\\char`≘}}"),zP("≙","\\html@mathml{\\stackrel{\\tiny\\wedge}{=}}{\\mathrel{\\char`≘}}"),zP("≚","\\html@mathml{\\stackrel{\\tiny\\vee}{=}}{\\mathrel{\\char`≚}}"),zP("≛","\\html@mathml{\\stackrel{\\scriptsize\\star}{=}}{\\mathrel{\\char`≛}}"),zP("≝","\\html@mathml{\\stackrel{\\tiny\\mathrm{def}}{=}}{\\mathrel{\\char`≝}}"),zP("≞","\\html@mathml{\\stackrel{\\tiny\\mathrm{m}}{=}}{\\mathrel{\\char`≞}}"),zP("≟","\\html@mathml{\\stackrel{\\tiny?}{=}}{\\mathrel{\\char`≟}}"),zP("⟂","\\perp"),zP("‼","\\mathclose{!\\mkern-0.8mu!}"),zP("∌","\\notni"),zP("⌜","\\ulcorner"),zP("⌝","\\urcorner"),zP("⌞","\\llcorner"),zP("⌟","\\lrcorner"),zP("©","\\copyright"),zP("®","\\textregistered"),zP("️","\\textregistered"),zP("\\ulcorner",'\\html@mathml{\\@ulcorner}{\\mathop{\\char"231c}}'),zP("\\urcorner",'\\html@mathml{\\@urcorner}{\\mathop{\\char"231d}}'),zP("\\llcorner",'\\html@mathml{\\@llcorner}{\\mathop{\\char"231e}}'),zP("\\lrcorner",'\\html@mathml{\\@lrcorner}{\\mathop{\\char"231f}}'),zP("\\vdots","{\\varvdots\\rule{0pt}{15pt}}"),zP("⋮","\\vdots"),zP("\\varGamma","\\mathit{\\Gamma}"),zP("\\varDelta","\\mathit{\\Delta}"),zP("\\varTheta","\\mathit{\\Theta}"),zP("\\varLambda","\\mathit{\\Lambda}"),zP("\\varXi","\\mathit{\\Xi}"),zP("\\varPi","\\mathit{\\Pi}"),zP("\\varSigma","\\mathit{\\Sigma}"),zP("\\varUpsilon","\\mathit{\\Upsilon}"),zP("\\varPhi","\\mathit{\\Phi}"),zP("\\varPsi","\\mathit{\\Psi}"),zP("\\varOmega","\\mathit{\\Omega}"),zP("\\substack","\\begin{subarray}{c}#1\\end{subarray}"),zP("\\colon","\\nobreak\\mskip2mu\\mathpunct{}\\mathchoice{\\mkern-3mu}{\\mkern-3mu}{}{}{:}\\mskip6mu\\relax"),zP("\\boxed","\\fbox{$\\displaystyle{#1}$}"),zP("\\iff","\\DOTSB\\;\\Longleftrightarrow\\;"),zP("\\implies","\\DOTSB\\;\\Longrightarrow\\;"),zP("\\impliedby","\\DOTSB\\;\\Longleftarrow\\;"),zP("\\dddot","{\\overset{\\raisebox{-0.1ex}{\\normalsize ...}}{#1}}"),zP("\\ddddot","{\\overset{\\raisebox{-0.1ex}{\\normalsize ....}}{#1}}");var LM={",":"\\dotsc","\\not":"\\dotsb","+":"\\dotsb","=":"\\dotsb","<":"\\dotsb",">":"\\dotsb","-":"\\dotsb","*":"\\dotsb",":":"\\dotsb","\\DOTSB":"\\dotsb","\\coprod":"\\dotsb","\\bigvee":"\\dotsb","\\bigwedge":"\\dotsb","\\biguplus":"\\dotsb","\\bigcap":"\\dotsb","\\bigcup":"\\dotsb","\\prod":"\\dotsb","\\sum":"\\dotsb","\\bigotimes":"\\dotsb","\\bigoplus":"\\dotsb","\\bigodot":"\\dotsb","\\bigsqcup":"\\dotsb","\\And":"\\dotsb","\\longrightarrow":"\\dotsb","\\Longrightarrow":"\\dotsb","\\longleftarrow":"\\dotsb","\\Longleftarrow":"\\dotsb","\\longleftrightarrow":"\\dotsb","\\Longleftrightarrow":"\\dotsb","\\mapsto":"\\dotsb","\\longmapsto":"\\dotsb","\\hookrightarrow":"\\dotsb","\\doteq":"\\dotsb","\\mathbin":"\\dotsb","\\mathrel":"\\dotsb","\\relbar":"\\dotsb","\\Relbar":"\\dotsb","\\xrightarrow":"\\dotsb","\\xleftarrow":"\\dotsb","\\DOTSI":"\\dotsi","\\int":"\\dotsi","\\oint":"\\dotsi","\\iint":"\\dotsi","\\iiint":"\\dotsi","\\iiiint":"\\dotsi","\\idotsint":"\\dotsi","\\DOTSX":"\\dotsx"};zP("\\dots",function(e){var t="\\dotso",r=e.expandAfterFuture().text;return r in LM?t=LM[r]:("\\not"===r.slice(0,4)||r in tT.math&&aO.contains(["bin","rel"],tT.math[r].group))&&(t="\\dotsb"),t});var _M={")":!0,"]":!0,"\\rbrack":!0,"\\}":!0,"\\rbrace":!0,"\\rangle":!0,"\\rceil":!0,"\\rfloor":!0,"\\rgroup":!0,"\\rmoustache":!0,"\\right":!0,"\\bigr":!0,"\\biggr":!0,"\\Bigr":!0,"\\Biggr":!0,$:!0,";":!0,".":!0,",":!0};zP("\\dotso",function(e){return e.future().text in _M?"\\ldots\\,":"\\ldots"}),zP("\\dotsc",function(e){var t=e.future().text;return t in _M&&","!==t?"\\ldots\\,":"\\ldots"}),zP("\\cdots",function(e){return e.future().text in _M?"\\@cdots\\,":"\\@cdots"}),zP("\\dotsb","\\cdots"),zP("\\dotsm","\\cdots"),zP("\\dotsi","\\!\\cdots"),zP("\\dotsx","\\ldots\\,"),zP("\\DOTSI","\\relax"),zP("\\DOTSB","\\relax"),zP("\\DOTSX","\\relax"),zP("\\tmspace","\\TextOrMath{\\kern#1#3}{\\mskip#1#2}\\relax"),zP("\\,","\\tmspace+{3mu}{.1667em}"),zP("\\thinspace","\\,"),zP("\\>","\\mskip{4mu}"),zP("\\:","\\tmspace+{4mu}{.2222em}"),zP("\\medspace","\\:"),zP("\\;","\\tmspace+{5mu}{.2777em}"),zP("\\thickspace","\\;"),zP("\\!","\\tmspace-{3mu}{.1667em}"),zP("\\negthinspace","\\!"),zP("\\negmedspace","\\tmspace-{4mu}{.2222em}"),zP("\\negthickspace","\\tmspace-{5mu}{.277em}"),zP("\\enspace","\\kern.5em "),zP("\\enskip","\\hskip.5em\\relax"),zP("\\quad","\\hskip1em\\relax"),zP("\\qquad","\\hskip2em\\relax"),zP("\\tag","\\@ifstar\\tag@literal\\tag@paren"),zP("\\tag@paren","\\tag@literal{({#1})}"),zP("\\tag@literal",e=>{if(e.macros.get("\\df@tag"))throw new tO("Multiple \\tag");return"\\gdef\\df@tag{\\text{#1}}"}),zP("\\bmod","\\mathchoice{\\mskip1mu}{\\mskip1mu}{\\mskip5mu}{\\mskip5mu}\\mathbin{\\rm mod}\\mathchoice{\\mskip1mu}{\\mskip1mu}{\\mskip5mu}{\\mskip5mu}"),zP("\\pod","\\allowbreak\\mathchoice{\\mkern18mu}{\\mkern8mu}{\\mkern8mu}{\\mkern8mu}(#1)"),zP("\\pmod","\\pod{{\\rm mod}\\mkern6mu#1}"),zP("\\mod","\\allowbreak\\mathchoice{\\mkern18mu}{\\mkern12mu}{\\mkern12mu}{\\mkern12mu}{\\rm mod}\\,\\,#1"),zP("\\newline","\\\\\\relax"),zP("\\TeX","\\textrm{\\html@mathml{T\\kern-.1667em\\raisebox{-.5ex}{E}\\kern-.125emX}{TeX}}");var zM=_O(xO["Main-Regular"]["T".charCodeAt(0)][1]-.7*xO["Main-Regular"]["A".charCodeAt(0)][1]);zP("\\LaTeX","\\textrm{\\html@mathml{L\\kern-.36em\\raisebox{"+zM+"}{\\scriptstyle A}\\kern-.15em\\TeX}{LaTeX}}"),zP("\\KaTeX","\\textrm{\\html@mathml{K\\kern-.17em\\raisebox{"+zM+"}{\\scriptstyle A}\\kern-.15em\\TeX}{KaTeX}}"),zP("\\hspace","\\@ifstar\\@hspacer\\@hspace"),zP("\\@hspace","\\hskip #1\\relax"),zP("\\@hspacer","\\rule{0pt}{0pt}\\hskip #1\\relax"),zP("\\ordinarycolon",":"),zP("\\vcentcolon","\\mathrel{\\mathop\\ordinarycolon}"),zP("\\dblcolon",'\\html@mathml{\\mathrel{\\vcentcolon\\mathrel{\\mkern-.9mu}\\vcentcolon}}{\\mathop{\\char"2237}}'),zP("\\coloneqq",'\\html@mathml{\\mathrel{\\vcentcolon\\mathrel{\\mkern-1.2mu}=}}{\\mathop{\\char"2254}}'),zP("\\Coloneqq",'\\html@mathml{\\mathrel{\\dblcolon\\mathrel{\\mkern-1.2mu}=}}{\\mathop{\\char"2237\\char"3d}}'),zP("\\coloneq",'\\html@mathml{\\mathrel{\\vcentcolon\\mathrel{\\mkern-1.2mu}\\mathrel{-}}}{\\mathop{\\char"3a\\char"2212}}'),zP("\\Coloneq",'\\html@mathml{\\mathrel{\\dblcolon\\mathrel{\\mkern-1.2mu}\\mathrel{-}}}{\\mathop{\\char"2237\\char"2212}}'),zP("\\eqqcolon",'\\html@mathml{\\mathrel{=\\mathrel{\\mkern-1.2mu}\\vcentcolon}}{\\mathop{\\char"2255}}'),zP("\\Eqqcolon",'\\html@mathml{\\mathrel{=\\mathrel{\\mkern-1.2mu}\\dblcolon}}{\\mathop{\\char"3d\\char"2237}}'),zP("\\eqcolon",'\\html@mathml{\\mathrel{\\mathrel{-}\\mathrel{\\mkern-1.2mu}\\vcentcolon}}{\\mathop{\\char"2239}}'),zP("\\Eqcolon",'\\html@mathml{\\mathrel{\\mathrel{-}\\mathrel{\\mkern-1.2mu}\\dblcolon}}{\\mathop{\\char"2212\\char"2237}}'),zP("\\colonapprox",'\\html@mathml{\\mathrel{\\vcentcolon\\mathrel{\\mkern-1.2mu}\\approx}}{\\mathop{\\char"3a\\char"2248}}'),zP("\\Colonapprox",'\\html@mathml{\\mathrel{\\dblcolon\\mathrel{\\mkern-1.2mu}\\approx}}{\\mathop{\\char"2237\\char"2248}}'),zP("\\colonsim",'\\html@mathml{\\mathrel{\\vcentcolon\\mathrel{\\mkern-1.2mu}\\sim}}{\\mathop{\\char"3a\\char"223c}}'),zP("\\Colonsim",'\\html@mathml{\\mathrel{\\dblcolon\\mathrel{\\mkern-1.2mu}\\sim}}{\\mathop{\\char"2237\\char"223c}}'),zP("∷","\\dblcolon"),zP("∹","\\eqcolon"),zP("≔","\\coloneqq"),zP("≕","\\eqqcolon"),zP("⩴","\\Coloneqq"),zP("\\ratio","\\vcentcolon"),zP("\\coloncolon","\\dblcolon"),zP("\\colonequals","\\coloneqq"),zP("\\coloncolonequals","\\Coloneqq"),zP("\\equalscolon","\\eqqcolon"),zP("\\equalscoloncolon","\\Eqqcolon"),zP("\\colonminus","\\coloneq"),zP("\\coloncolonminus","\\Coloneq"),zP("\\minuscolon","\\eqcolon"),zP("\\minuscoloncolon","\\Eqcolon"),zP("\\coloncolonapprox","\\Colonapprox"),zP("\\coloncolonsim","\\Colonsim"),zP("\\simcolon","\\mathrel{\\sim\\mathrel{\\mkern-1.2mu}\\vcentcolon}"),zP("\\simcoloncolon","\\mathrel{\\sim\\mathrel{\\mkern-1.2mu}\\dblcolon}"),zP("\\approxcolon","\\mathrel{\\approx\\mathrel{\\mkern-1.2mu}\\vcentcolon}"),zP("\\approxcoloncolon","\\mathrel{\\approx\\mathrel{\\mkern-1.2mu}\\dblcolon}"),zP("\\notni","\\html@mathml{\\not\\ni}{\\mathrel{\\char`∌}}"),zP("\\limsup","\\DOTSB\\operatorname*{lim\\,sup}"),zP("\\liminf","\\DOTSB\\operatorname*{lim\\,inf}"),zP("\\injlim","\\DOTSB\\operatorname*{inj\\,lim}"),zP("\\projlim","\\DOTSB\\operatorname*{proj\\,lim}"),zP("\\varlimsup","\\DOTSB\\operatorname*{\\overline{lim}}"),zP("\\varliminf","\\DOTSB\\operatorname*{\\underline{lim}}"),zP("\\varinjlim","\\DOTSB\\operatorname*{\\underrightarrow{lim}}"),zP("\\varprojlim","\\DOTSB\\operatorname*{\\underleftarrow{lim}}"),zP("\\gvertneqq","\\html@mathml{\\@gvertneqq}{≩}"),zP("\\lvertneqq","\\html@mathml{\\@lvertneqq}{≨}"),zP("\\ngeqq","\\html@mathml{\\@ngeqq}{≱}"),zP("\\ngeqslant","\\html@mathml{\\@ngeqslant}{≱}"),zP("\\nleqq","\\html@mathml{\\@nleqq}{≰}"),zP("\\nleqslant","\\html@mathml{\\@nleqslant}{≰}"),zP("\\nshortmid","\\html@mathml{\\@nshortmid}{∤}"),zP("\\nshortparallel","\\html@mathml{\\@nshortparallel}{∦}"),zP("\\nsubseteqq","\\html@mathml{\\@nsubseteqq}{⊈}"),zP("\\nsupseteqq","\\html@mathml{\\@nsupseteqq}{⊉}"),zP("\\varsubsetneq","\\html@mathml{\\@varsubsetneq}{⊊}"),zP("\\varsubsetneqq","\\html@mathml{\\@varsubsetneqq}{⫋}"),zP("\\varsupsetneq","\\html@mathml{\\@varsupsetneq}{⊋}"),zP("\\varsupsetneqq","\\html@mathml{\\@varsupsetneqq}{⫌}"),zP("\\imath","\\html@mathml{\\@imath}{ı}"),zP("\\jmath","\\html@mathml{\\@jmath}{ȷ}"),zP("\\llbracket","\\html@mathml{\\mathopen{[\\mkern-3.2mu[}}{\\mathopen{\\char`⟦}}"),zP("\\rrbracket","\\html@mathml{\\mathclose{]\\mkern-3.2mu]}}{\\mathclose{\\char`⟧}}"),zP("⟦","\\llbracket"),zP("⟧","\\rrbracket"),zP("\\lBrace","\\html@mathml{\\mathopen{\\{\\mkern-3.2mu[}}{\\mathopen{\\char`⦃}}"),zP("\\rBrace","\\html@mathml{\\mathclose{]\\mkern-3.2mu\\}}}{\\mathclose{\\char`⦄}}"),zP("⦃","\\lBrace"),zP("⦄","\\rBrace"),zP("\\minuso","\\mathbin{\\html@mathml{{\\mathrlap{\\mathchoice{\\kern{0.145em}}{\\kern{0.145em}}{\\kern{0.1015em}}{\\kern{0.0725em}}\\circ}{-}}}{\\char`⦵}}"),zP("⦵","\\minuso"),zP("\\darr","\\downarrow"),zP("\\dArr","\\Downarrow"),zP("\\Darr","\\Downarrow"),zP("\\lang","\\langle"),zP("\\rang","\\rangle"),zP("\\uarr","\\uparrow"),zP("\\uArr","\\Uparrow"),zP("\\Uarr","\\Uparrow"),zP("\\N","\\mathbb{N}"),zP("\\R","\\mathbb{R}"),zP("\\Z","\\mathbb{Z}"),zP("\\alef","\\aleph"),zP("\\alefsym","\\aleph"),zP("\\Alpha","\\mathrm{A}"),zP("\\Beta","\\mathrm{B}"),zP("\\bull","\\bullet"),zP("\\Chi","\\mathrm{X}"),zP("\\clubs","\\clubsuit"),zP("\\cnums","\\mathbb{C}"),zP("\\Complex","\\mathbb{C}"),zP("\\Dagger","\\ddagger"),zP("\\diamonds","\\diamondsuit"),zP("\\empty","\\emptyset"),zP("\\Epsilon","\\mathrm{E}"),zP("\\Eta","\\mathrm{H}"),zP("\\exist","\\exists"),zP("\\harr","\\leftrightarrow"),zP("\\hArr","\\Leftrightarrow"),zP("\\Harr","\\Leftrightarrow"),zP("\\hearts","\\heartsuit"),zP("\\image","\\Im"),zP("\\infin","\\infty"),zP("\\Iota","\\mathrm{I}"),zP("\\isin","\\in"),zP("\\Kappa","\\mathrm{K}"),zP("\\larr","\\leftarrow"),zP("\\lArr","\\Leftarrow"),zP("\\Larr","\\Leftarrow"),zP("\\lrarr","\\leftrightarrow"),zP("\\lrArr","\\Leftrightarrow"),zP("\\Lrarr","\\Leftrightarrow"),zP("\\Mu","\\mathrm{M}"),zP("\\natnums","\\mathbb{N}"),zP("\\Nu","\\mathrm{N}"),zP("\\Omicron","\\mathrm{O}"),zP("\\plusmn","\\pm"),zP("\\rarr","\\rightarrow"),zP("\\rArr","\\Rightarrow"),zP("\\Rarr","\\Rightarrow"),zP("\\real","\\Re"),zP("\\reals","\\mathbb{R}"),zP("\\Reals","\\mathbb{R}"),zP("\\Rho","\\mathrm{P}"),zP("\\sdot","\\cdot"),zP("\\sect","\\S"),zP("\\spades","\\spadesuit"),zP("\\sub","\\subset"),zP("\\sube","\\subseteq"),zP("\\supe","\\supseteq"),zP("\\Tau","\\mathrm{T}"),zP("\\thetasym","\\vartheta"),zP("\\weierp","\\wp"),zP("\\Zeta","\\mathrm{Z}"),zP("\\argmin","\\DOTSB\\operatorname*{arg\\,min}"),zP("\\argmax","\\DOTSB\\operatorname*{arg\\,max}"),zP("\\plim","\\DOTSB\\mathop{\\operatorname{plim}}\\limits"),zP("\\bra","\\mathinner{\\langle{#1}|}"),zP("\\ket","\\mathinner{|{#1}\\rangle}"),zP("\\braket","\\mathinner{\\langle{#1}\\rangle}"),zP("\\Bra","\\left\\langle#1\\right|"),zP("\\Ket","\\left|#1\\right\\rangle");var jM=e=>t=>{var r=t.consumeArg().tokens,n=t.consumeArg().tokens,o=t.consumeArg().tokens,i=t.consumeArg().tokens,a=t.macros.get("|"),s=t.macros.get("\\|");t.macros.beginGroup();var u=t=>r=>{e&&(r.macros.set("|",a),o.length&&r.macros.set("\\|",s));var i=t;!t&&o.length&&("|"===r.future().text&&(r.popToken(),i=!0));return{tokens:i?o:n,numArgs:0}};t.macros.set("|",u(!1)),o.length&&t.macros.set("\\|",u(!0));var l=t.consumeArg().tokens,c=t.expandTokens([...i,...l,...r]);return t.macros.endGroup(),{tokens:c.reverse(),numArgs:0}};zP("\\bra@ket",jM(!1)),zP("\\bra@set",jM(!0)),zP("\\Braket","\\bra@ket{\\left\\langle}{\\,\\middle\\vert\\,}{\\,\\middle\\vert\\,}{\\right\\rangle}"),zP("\\Set","\\bra@set{\\left\\{\\:}{\\;\\middle\\vert\\;}{\\;\\middle\\Vert\\;}{\\:\\right\\}}"),zP("\\set","\\bra@set{\\{\\,}{\\mid}{}{\\,\\}}"),zP("\\angln","{\\angl n}"),zP("\\blue","\\textcolor{##6495ed}{#1}"),zP("\\orange","\\textcolor{##ffa500}{#1}"),zP("\\pink","\\textcolor{##ff00af}{#1}"),zP("\\red","\\textcolor{##df0030}{#1}"),zP("\\green","\\textcolor{##28ae7b}{#1}"),zP("\\gray","\\textcolor{gray}{#1}"),zP("\\purple","\\textcolor{##9d38bd}{#1}"),zP("\\blueA","\\textcolor{##ccfaff}{#1}"),zP("\\blueB","\\textcolor{##80f6ff}{#1}"),zP("\\blueC","\\textcolor{##63d9ea}{#1}"),zP("\\blueD","\\textcolor{##11accd}{#1}"),zP("\\blueE","\\textcolor{##0c7f99}{#1}"),zP("\\tealA","\\textcolor{##94fff5}{#1}"),zP("\\tealB","\\textcolor{##26edd5}{#1}"),zP("\\tealC","\\textcolor{##01d1c1}{#1}"),zP("\\tealD","\\textcolor{##01a995}{#1}"),zP("\\tealE","\\textcolor{##208170}{#1}"),zP("\\greenA","\\textcolor{##b6ffb0}{#1}"),zP("\\greenB","\\textcolor{##8af281}{#1}"),zP("\\greenC","\\textcolor{##74cf70}{#1}"),zP("\\greenD","\\textcolor{##1fab54}{#1}"),zP("\\greenE","\\textcolor{##0d923f}{#1}"),zP("\\goldA","\\textcolor{##ffd0a9}{#1}"),zP("\\goldB","\\textcolor{##ffbb71}{#1}"),zP("\\goldC","\\textcolor{##ff9c39}{#1}"),zP("\\goldD","\\textcolor{##e07d10}{#1}"),zP("\\goldE","\\textcolor{##a75a05}{#1}"),zP("\\redA","\\textcolor{##fca9a9}{#1}"),zP("\\redB","\\textcolor{##ff8482}{#1}"),zP("\\redC","\\textcolor{##f9685d}{#1}"),zP("\\redD","\\textcolor{##e84d39}{#1}"),zP("\\redE","\\textcolor{##bc2612}{#1}"),zP("\\maroonA","\\textcolor{##ffbde0}{#1}"),zP("\\maroonB","\\textcolor{##ff92c6}{#1}"),zP("\\maroonC","\\textcolor{##ed5fa6}{#1}"),zP("\\maroonD","\\textcolor{##ca337c}{#1}"),zP("\\maroonE","\\textcolor{##9e034e}{#1}"),zP("\\purpleA","\\textcolor{##ddd7ff}{#1}"),zP("\\purpleB","\\textcolor{##c6b9fc}{#1}"),zP("\\purpleC","\\textcolor{##aa87ff}{#1}"),zP("\\purpleD","\\textcolor{##7854ab}{#1}"),zP("\\purpleE","\\textcolor{##543b78}{#1}"),zP("\\mintA","\\textcolor{##f5f9e8}{#1}"),zP("\\mintB","\\textcolor{##edf2df}{#1}"),zP("\\mintC","\\textcolor{##e0e5cc}{#1}"),zP("\\grayA","\\textcolor{##f6f7f7}{#1}"),zP("\\grayB","\\textcolor{##f0f1f2}{#1}"),zP("\\grayC","\\textcolor{##e3e5e6}{#1}"),zP("\\grayD","\\textcolor{##d6d8da}{#1}"),zP("\\grayE","\\textcolor{##babec2}{#1}"),zP("\\grayF","\\textcolor{##888d93}{#1}"),zP("\\grayG","\\textcolor{##626569}{#1}"),zP("\\grayH","\\textcolor{##3b3e40}{#1}"),zP("\\grayI","\\textcolor{##21242c}{#1}"),zP("\\kaBlue","\\textcolor{##314453}{#1}"),zP("\\kaGreen","\\textcolor{##71B307}{#1}");var HM={"^":!0,_:!0,"\\limits":!0,"\\nolimits":!0};class VM{constructor(e,t,r){this.settings=void 0,this.expansionCount=void 0,this.lexer=void 0,this.macros=void 0,this.stack=void 0,this.mode=void 0,this.settings=t,this.expansionCount=0,this.feed(e),this.macros=new PM(MM,t.macros),this.mode=r,this.stack=[]}feed(e){this.lexer=new NM(e,this.settings)}switchMode(e){this.mode=e}beginGroup(){this.macros.beginGroup()}endGroup(){this.macros.endGroup()}endGroups(){this.macros.endGroups()}future(){return 0===this.stack.length&&this.pushToken(this.lexer.lex()),this.stack[this.stack.length-1]}popToken(){return this.future(),this.stack.pop()}pushToken(e){this.stack.push(e)}pushTokens(e){this.stack.push(...e)}scanArgument(e){var t,r,n;if(e){if(this.consumeSpaces(),"["!==this.future().text)return null;t=this.popToken(),({tokens:n,end:r}=this.consumeArg(["]"]))}else({tokens:n,start:t,end:r}=this.consumeArg());return this.pushToken(new eO("EOF",r.loc)),this.pushTokens(n),t.range(r,"")}consumeSpaces(){for(;;){if(" "!==this.future().text)break;this.stack.pop()}}consumeArg(e){var t=[],r=e&&e.length>0;r||this.consumeSpaces();var n,o=this.future(),i=0,a=0;do{if(n=this.popToken(),t.push(n),"{"===n.text)++i;else if("}"===n.text){if(-1===--i)throw new tO("Extra }",n)}else if("EOF"===n.text)throw new tO("Unexpected end of input in a macro argument, expected '"+(e&&r?e[a]:"}")+"'",n);if(e&&r)if((0===i||1===i&&"{"===e[a])&&n.text===e[a]){if(++a===e.length){t.splice(-a,a);break}}else a=0}while(0!==i||r);return"{"===o.text&&"}"===t[t.length-1].text&&(t.pop(),t.shift()),t.reverse(),{tokens:t,start:o,end:n}}consumeArgs(e,t){if(t){if(t.length!==e+1)throw new tO("The length of delimiters doesn't match the number of args!");for(var r=t[0],n=0;n<r.length;n++){var o=this.popToken();if(r[n]!==o.text)throw new tO("Use of the macro doesn't match its definition",o)}}for(var i=[],a=0;a<e;a++)i.push(this.consumeArg(t&&t[a+1]).tokens);return i}countExpansion(e){if(this.expansionCount+=e,this.expansionCount>this.settings.maxExpand)throw new tO("Too many expansions: infinite loop or need to increase maxExpand setting")}expandOnce(e){var t=this.popToken(),r=t.text,n=t.noexpand?null:this._getExpansion(r);if(null==n||e&&n.unexpandable){if(e&&null==n&&"\\"===r[0]&&!this.isDefined(r))throw new tO("Undefined control sequence: "+r);return this.pushToken(t),!1}this.countExpansion(1);var o=n.tokens,i=this.consumeArgs(n.numArgs,n.delimiters);if(n.numArgs)for(var a=(o=o.slice()).length-1;a>=0;--a){var s=o[a];if("#"===s.text){if(0===a)throw new tO("Incomplete placeholder at end of macro body",s);if("#"===(s=o[--a]).text)o.splice(a+1,1);else{if(!/^[1-9]$/.test(s.text))throw new tO("Not a valid argument number",s);o.splice(a,2,...i[+s.text-1])}}}return this.pushTokens(o),o.length}expandAfterFuture(){return this.expandOnce(),this.future()}expandNextToken(){for(;;)if(!1===this.expandOnce()){var e=this.stack.pop();return e.treatAsRelax&&(e.text="\\relax"),e}throw new Error}expandMacro(e){return this.macros.has(e)?this.expandTokens([new eO(e)]):void 0}expandTokens(e){var t=[],r=this.stack.length;for(this.pushTokens(e);this.stack.length>r;)if(!1===this.expandOnce(!0)){var n=this.stack.pop();n.treatAsRelax&&(n.noexpand=!1,n.treatAsRelax=!1),t.push(n)}return this.countExpansion(t.length),t}expandMacroAsText(e){var t=this.expandMacro(e);return t?t.map(e=>e.text).join(""):t}_getExpansion(e){var t=this.macros.get(e);if(null==t)return t;if(1===e.length){var r=this.lexer.catcodes[e];if(null!=r&&13!==r)return}var n="function"==typeof t?t(this):t;if("string"==typeof n){var o=0;if(-1!==n.indexOf("#"))for(var i=n.replace(/##/g,"");-1!==i.indexOf("#"+(o+1));)++o;for(var a=new NM(n,this.settings),s=[],u=a.lex();"EOF"!==u.text;)s.push(u),u=a.lex();return s.reverse(),{tokens:s,numArgs:o}}return n}isDefined(e){return this.macros.has(e)||BM.hasOwnProperty(e)||tT.math.hasOwnProperty(e)||tT.text.hasOwnProperty(e)||HM.hasOwnProperty(e)}isExpandable(e){var t=this.macros.get(e);return null!=t?"string"==typeof t||"function"==typeof t||!t.unexpandable:BM.hasOwnProperty(e)&&!BM[e].primitive}}var $M=/^[₊₋₌₍₎₀₁₂₃₄₅₆₇₈₉ₐₑₕᵢⱼₖₗₘₙₒₚᵣₛₜᵤᵥₓᵦᵧᵨᵩᵪ]/,UM=Object.freeze({"₊":"+","₋":"-","₌":"=","₍":"(","₎":")","₀":"0","₁":"1","₂":"2","₃":"3","₄":"4","₅":"5","₆":"6","₇":"7","₈":"8","₉":"9","ₐ":"a","ₑ":"e","ₕ":"h","ᵢ":"i","ⱼ":"j","ₖ":"k","ₗ":"l","ₘ":"m","ₙ":"n","ₒ":"o","ₚ":"p","ᵣ":"r","ₛ":"s","ₜ":"t","ᵤ":"u","ᵥ":"v","ₓ":"x","ᵦ":"β","ᵧ":"γ","ᵨ":"ρ","ᵩ":"ϕ","ᵪ":"χ","⁺":"+","⁻":"-","⁼":"=","⁽":"(","⁾":")","⁰":"0","¹":"1","²":"2","³":"3","⁴":"4","⁵":"5","⁶":"6","⁷":"7","⁸":"8","⁹":"9","ᴬ":"A","ᴮ":"B","ᴰ":"D","ᴱ":"E","ᴳ":"G","ᴴ":"H","ᴵ":"I","ᴶ":"J","ᴷ":"K","ᴸ":"L","ᴹ":"M","ᴺ":"N","ᴼ":"O","ᴾ":"P","ᴿ":"R","ᵀ":"T","ᵁ":"U","ⱽ":"V","ᵂ":"W","ᵃ":"a","ᵇ":"b","ᶜ":"c","ᵈ":"d","ᵉ":"e","ᶠ":"f","ᵍ":"g","ʰ":"h","ⁱ":"i","ʲ":"j","ᵏ":"k","ˡ":"l","ᵐ":"m","ⁿ":"n","ᵒ":"o","ᵖ":"p","ʳ":"r","ˢ":"s","ᵗ":"t","ᵘ":"u","ᵛ":"v","ʷ":"w","ˣ":"x","ʸ":"y","ᶻ":"z","ᵝ":"β","ᵞ":"γ","ᵟ":"δ","ᵠ":"ϕ","ᵡ":"χ","ᶿ":"θ"}),qM={"́":{text:"\\'",math:"\\acute"},"̀":{text:"\\`",math:"\\grave"},"̈":{text:'\\"',math:"\\ddot"},"̃":{text:"\\~",math:"\\tilde"},"̄":{text:"\\=",math:"\\bar"},"̆":{text:"\\u",math:"\\breve"},"̌":{text:"\\v",math:"\\check"},"̂":{text:"\\^",math:"\\hat"},"̇":{text:"\\.",math:"\\dot"},"̊":{text:"\\r",math:"\\mathring"},"̋":{text:"\\H"},"̧":{text:"\\c"}},WM={"á":"á","à":"à","ä":"ä","ǟ":"ǟ","ã":"ã","ā":"ā","ă":"ă","ắ":"ắ","ằ":"ằ","ẵ":"ẵ","ǎ":"ǎ","â":"â","ấ":"ấ","ầ":"ầ","ẫ":"ẫ","ȧ":"ȧ","ǡ":"ǡ","å":"å","ǻ":"ǻ","ḃ":"ḃ","ć":"ć","ḉ":"ḉ","č":"č","ĉ":"ĉ","ċ":"ċ","ç":"ç","ď":"ď","ḋ":"ḋ","ḑ":"ḑ","é":"é","è":"è","ë":"ë","ẽ":"ẽ","ē":"ē","ḗ":"ḗ","ḕ":"ḕ","ĕ":"ĕ","ḝ":"ḝ","ě":"ě","ê":"ê","ế":"ế","ề":"ề","ễ":"ễ","ė":"ė","ȩ":"ȩ","ḟ":"ḟ","ǵ":"ǵ","ḡ":"ḡ","ğ":"ğ","ǧ":"ǧ","ĝ":"ĝ","ġ":"ġ","ģ":"ģ","ḧ":"ḧ","ȟ":"ȟ","ĥ":"ĥ","ḣ":"ḣ","ḩ":"ḩ","í":"í","ì":"ì","ï":"ï","ḯ":"ḯ","ĩ":"ĩ","ī":"ī","ĭ":"ĭ","ǐ":"ǐ","î":"î","ǰ":"ǰ","ĵ":"ĵ","ḱ":"ḱ","ǩ":"ǩ","ķ":"ķ","ĺ":"ĺ","ľ":"ľ","ļ":"ļ","ḿ":"ḿ","ṁ":"ṁ","ń":"ń","ǹ":"ǹ","ñ":"ñ","ň":"ň","ṅ":"ṅ","ņ":"ņ","ó":"ó","ò":"ò","ö":"ö","ȫ":"ȫ","õ":"õ","ṍ":"ṍ","ṏ":"ṏ","ȭ":"ȭ","ō":"ō","ṓ":"ṓ","ṑ":"ṑ","ŏ":"ŏ","ǒ":"ǒ","ô":"ô","ố":"ố","ồ":"ồ","ỗ":"ỗ","ȯ":"ȯ","ȱ":"ȱ","ő":"ő","ṕ":"ṕ","ṗ":"ṗ","ŕ":"ŕ","ř":"ř","ṙ":"ṙ","ŗ":"ŗ","ś":"ś","ṥ":"ṥ","š":"š","ṧ":"ṧ","ŝ":"ŝ","ṡ":"ṡ","ş":"ş","ẗ":"ẗ","ť":"ť","ṫ":"ṫ","ţ":"ţ","ú":"ú","ù":"ù","ü":"ü","ǘ":"ǘ","ǜ":"ǜ","ǖ":"ǖ","ǚ":"ǚ","ũ":"ũ","ṹ":"ṹ","ū":"ū","ṻ":"ṻ","ŭ":"ŭ","ǔ":"ǔ","û":"û","ů":"ů","ű":"ű","ṽ":"ṽ","ẃ":"ẃ","ẁ":"ẁ","ẅ":"ẅ","ŵ":"ŵ","ẇ":"ẇ","ẘ":"ẘ","ẍ":"ẍ","ẋ":"ẋ","ý":"ý","ỳ":"ỳ","ÿ":"ÿ","ỹ":"ỹ","ȳ":"ȳ","ŷ":"ŷ","ẏ":"ẏ","ẙ":"ẙ","ź":"ź","ž":"ž","ẑ":"ẑ","ż":"ż","Á":"Á","À":"À","Ä":"Ä","Ǟ":"Ǟ","Ã":"Ã","Ā":"Ā","Ă":"Ă","Ắ":"Ắ","Ằ":"Ằ","Ẵ":"Ẵ","Ǎ":"Ǎ","Â":"Â","Ấ":"Ấ","Ầ":"Ầ","Ẫ":"Ẫ","Ȧ":"Ȧ","Ǡ":"Ǡ","Å":"Å","Ǻ":"Ǻ","Ḃ":"Ḃ","Ć":"Ć","Ḉ":"Ḉ","Č":"Č","Ĉ":"Ĉ","Ċ":"Ċ","Ç":"Ç","Ď":"Ď","Ḋ":"Ḋ","Ḑ":"Ḑ","É":"É","È":"È","Ë":"Ë","Ẽ":"Ẽ","Ē":"Ē","Ḗ":"Ḗ","Ḕ":"Ḕ","Ĕ":"Ĕ","Ḝ":"Ḝ","Ě":"Ě","Ê":"Ê","Ế":"Ế","Ề":"Ề","Ễ":"Ễ","Ė":"Ė","Ȩ":"Ȩ","Ḟ":"Ḟ","Ǵ":"Ǵ","Ḡ":"Ḡ","Ğ":"Ğ","Ǧ":"Ǧ","Ĝ":"Ĝ","Ġ":"Ġ","Ģ":"Ģ","Ḧ":"Ḧ","Ȟ":"Ȟ","Ĥ":"Ĥ","Ḣ":"Ḣ","Ḩ":"Ḩ","Í":"Í","Ì":"Ì","Ï":"Ï","Ḯ":"Ḯ","Ĩ":"Ĩ","Ī":"Ī","Ĭ":"Ĭ","Ǐ":"Ǐ","Î":"Î","İ":"İ","Ĵ":"Ĵ","Ḱ":"Ḱ","Ǩ":"Ǩ","Ķ":"Ķ","Ĺ":"Ĺ","Ľ":"Ľ","Ļ":"Ļ","Ḿ":"Ḿ","Ṁ":"Ṁ","Ń":"Ń","Ǹ":"Ǹ","Ñ":"Ñ","Ň":"Ň","Ṅ":"Ṅ","Ņ":"Ņ","Ó":"Ó","Ò":"Ò","Ö":"Ö","Ȫ":"Ȫ","Õ":"Õ","Ṍ":"Ṍ","Ṏ":"Ṏ","Ȭ":"Ȭ","Ō":"Ō","Ṓ":"Ṓ","Ṑ":"Ṑ","Ŏ":"Ŏ","Ǒ":"Ǒ","Ô":"Ô","Ố":"Ố","Ồ":"Ồ","Ỗ":"Ỗ","Ȯ":"Ȯ","Ȱ":"Ȱ","Ő":"Ő","Ṕ":"Ṕ","Ṗ":"Ṗ","Ŕ":"Ŕ","Ř":"Ř","Ṙ":"Ṙ","Ŗ":"Ŗ","Ś":"Ś","Ṥ":"Ṥ","Š":"Š","Ṧ":"Ṧ","Ŝ":"Ŝ","Ṡ":"Ṡ","Ş":"Ş","Ť":"Ť","Ṫ":"Ṫ","Ţ":"Ţ","Ú":"Ú","Ù":"Ù","Ü":"Ü","Ǘ":"Ǘ","Ǜ":"Ǜ","Ǖ":"Ǖ","Ǚ":"Ǚ","Ũ":"Ũ","Ṹ":"Ṹ","Ū":"Ū","Ṻ":"Ṻ","Ŭ":"Ŭ","Ǔ":"Ǔ","Û":"Û","Ů":"Ů","Ű":"Ű","Ṽ":"Ṽ","Ẃ":"Ẃ","Ẁ":"Ẁ","Ẅ":"Ẅ","Ŵ":"Ŵ","Ẇ":"Ẇ","Ẍ":"Ẍ","Ẋ":"Ẋ","Ý":"Ý","Ỳ":"Ỳ","Ÿ":"Ÿ","Ỹ":"Ỹ","Ȳ":"Ȳ","Ŷ":"Ŷ","Ẏ":"Ẏ","Ź":"Ź","Ž":"Ž","Ẑ":"Ẑ","Ż":"Ż","ά":"ά","ὰ":"ὰ","ᾱ":"ᾱ","ᾰ":"ᾰ","έ":"έ","ὲ":"ὲ","ή":"ή","ὴ":"ὴ","ί":"ί","ὶ":"ὶ","ϊ":"ϊ","ΐ":"ΐ","ῒ":"ῒ","ῑ":"ῑ","ῐ":"ῐ","ό":"ό","ὸ":"ὸ","ύ":"ύ","ὺ":"ὺ","ϋ":"ϋ","ΰ":"ΰ","ῢ":"ῢ","ῡ":"ῡ","ῠ":"ῠ","ώ":"ώ","ὼ":"ὼ","Ύ":"Ύ","Ὺ":"Ὺ","Ϋ":"Ϋ","Ῡ":"Ῡ","Ῠ":"Ῠ","Ώ":"Ώ","Ὼ":"Ὼ"};class GM{constructor(e,t){this.mode=void 0,this.gullet=void 0,this.settings=void 0,this.leftrightDepth=void 0,this.nextToken=void 0,this.mode="math",this.gullet=new VM(e,t,this.mode),this.settings=t,this.leftrightDepth=0}expect(e,t){if(void 0===t&&(t=!0),this.fetch().text!==e)throw new tO("Expected '"+e+"', got '"+this.fetch().text+"'",this.fetch());t&&this.consume()}consume(){this.nextToken=null}fetch(){return null==this.nextToken&&(this.nextToken=this.gullet.expandNextToken()),this.nextToken}switchMode(e){this.mode=e,this.gullet.switchMode(e)}parse(){this.settings.globalGroup||this.gullet.beginGroup(),this.settings.colorIsTextColor&&this.gullet.macros.set("\\color","\\textcolor");try{var e=this.parseExpression(!1);return this.expect("EOF"),this.settings.globalGroup||this.gullet.endGroup(),e}finally{this.gullet.endGroups()}}subparse(e){var t=this.nextToken;this.consume(),this.gullet.pushToken(new eO("}")),this.gullet.pushTokens(e);var r=this.parseExpression(!1);return this.expect("}"),this.nextToken=t,r}parseExpression(e,t){for(var r=[];;){"math"===this.mode&&this.consumeSpaces();var n=this.fetch();if(-1!==GM.endOfExpression.indexOf(n.text))break;if(t&&n.text===t)break;if(e&&BM[n.text]&&BM[n.text].infix)break;var o=this.parseAtom(t);if(!o)break;"internal"!==o.type&&r.push(o)}return"text"===this.mode&&this.formLigatures(r),this.handleInfixNodes(r)}handleInfixNodes(e){for(var t,r=-1,n=0;n<e.length;n++)if("infix"===e[n].type){if(-1!==r)throw new tO("only one infix operator per group",e[n].token);r=n,t=e[n].replaceWith}if(-1!==r&&t){var o,i,a=e.slice(0,r),s=e.slice(r+1);return o=1===a.length&&"ordgroup"===a[0].type?a[0]:{type:"ordgroup",mode:this.mode,body:a},i=1===s.length&&"ordgroup"===s[0].type?s[0]:{type:"ordgroup",mode:this.mode,body:s},["\\\\abovefrac"===t?this.callFunction(t,[o,e[r],i],[]):this.callFunction(t,[o,i],[])]}return e}handleSupSubscript(e){var t,r=this.fetch(),n=r.text;this.consume(),this.consumeSpaces();do{var o;t=this.parseGroup(e)}while("internal"===(null==(o=t)?void 0:o.type));if(!t)throw new tO("Expected group after '"+n+"'",r);return t}formatUnsupportedCmd(e){for(var t=[],r=0;r<e.length;r++)t.push({type:"textord",mode:"text",text:e[r]});var n={type:"text",mode:this.mode,body:t};return{type:"color",mode:this.mode,color:this.settings.errorColor,body:[n]}}parseAtom(e){var t,r,n=this.parseGroup("atom",e);if("internal"===(null==n?void 0:n.type))return n;if("text"===this.mode)return n;for(;;){this.consumeSpaces();var o=this.fetch();if("\\limits"===o.text||"\\nolimits"===o.text){if(n&&"op"===n.type){var i="\\limits"===o.text;n.limits=i,n.alwaysHandleSupSub=!0}else{if(!n||"operatorname"!==n.type)throw new tO("Limit controls must follow a math operator",o);n.alwaysHandleSupSub&&(n.limits="\\limits"===o.text)}this.consume()}else if("^"===o.text){if(t)throw new tO("Double superscript",o);t=this.handleSupSubscript("superscript")}else if("_"===o.text){if(r)throw new tO("Double subscript",o);r=this.handleSupSubscript("subscript")}else if("'"===o.text){if(t)throw new tO("Double superscript",o);var a={type:"textord",mode:this.mode,text:"\\prime"},s=[a];for(this.consume();"'"===this.fetch().text;)s.push(a),this.consume();"^"===this.fetch().text&&s.push(this.handleSupSubscript("superscript")),t={type:"ordgroup",mode:this.mode,body:s}}else{if(!UM[o.text])break;var u=$M.test(o.text),l=[];for(l.push(new eO(UM[o.text])),this.consume();;){var c=this.fetch().text;if(!UM[c])break;if($M.test(c)!==u)break;l.unshift(new eO(UM[c])),this.consume()}var d=this.subparse(l);u?r={type:"ordgroup",mode:"math",body:d}:t={type:"ordgroup",mode:"math",body:d}}}return t||r?{type:"supsub",mode:this.mode,base:n,sup:t,sub:r}:n}parseFunction(e,t){var r=this.fetch(),n=r.text,o=BM[n];if(!o)return null;if(this.consume(),t&&"atom"!==t&&!o.allowedInArgument)throw new tO("Got function '"+n+"' with no arguments"+(t?" as "+t:""),r);if("text"===this.mode&&!o.allowedInText)throw new tO("Can't use function '"+n+"' in text mode",r);if("math"===this.mode&&!1===o.allowedInMath)throw new tO("Can't use function '"+n+"' in math mode",r);var{args:i,optArgs:a}=this.parseArguments(n,o);return this.callFunction(n,i,a,r,e)}callFunction(e,t,r,n,o){var i={funcName:e,parser:this,token:n,breakOnTokenText:o},a=BM[e];if(a&&a.handler)return a.handler(i,t,r);throw new tO("No function handler for "+e)}parseArguments(e,t){var r=t.numArgs+t.numOptionalArgs;if(0===r)return{args:[],optArgs:[]};for(var n=[],o=[],i=0;i<r;i++){var a=t.argTypes&&t.argTypes[i],s=i<t.numOptionalArgs;(t.primitive&&null==a||"sqrt"===t.type&&1===i&&null==o[0])&&(a="primitive");var u=this.parseGroupOfType("argument to '"+e+"'",a,s);if(s)o.push(u);else{if(null==u)throw new tO("Null argument, please report this as a bug");n.push(u)}}return{args:n,optArgs:o}}parseGroupOfType(e,t,r){switch(t){case"color":return this.parseColorGroup(r);case"size":return this.parseSizeGroup(r);case"url":return this.parseUrlGroup(r);case"math":case"text":return this.parseArgumentGroup(r,t);case"hbox":var n=this.parseArgumentGroup(r,"text");return null!=n?{type:"styling",mode:n.mode,body:[n],style:"text"}:null;case"raw":var o=this.parseStringGroup("raw",r);return null!=o?{type:"raw",mode:"text",string:o.text}:null;case"primitive":if(r)throw new tO("A primitive argument cannot be optional");var i=this.parseGroup(e);if(null==i)throw new tO("Expected group as "+e,this.fetch());return i;case"original":case null:case void 0:return this.parseArgumentGroup(r);default:throw new tO("Unknown group type as "+e,this.fetch())}}consumeSpaces(){for(;" "===this.fetch().text;)this.consume()}parseStringGroup(e,t){var r=this.gullet.scanArgument(t);if(null==r)return null;for(var n,o="";"EOF"!==(n=this.fetch()).text;)o+=n.text,this.consume();return this.consume(),r.text=o,r}parseRegexGroup(e,t){for(var r,n=this.fetch(),o=n,i="";"EOF"!==(r=this.fetch()).text&&e.test(i+r.text);)i+=(o=r).text,this.consume();if(""===i)throw new tO("Invalid "+t+": '"+n.text+"'",n);return n.range(o,i)}parseColorGroup(e){var t=this.parseStringGroup("color",e);if(null==t)return null;var r=/^(#[a-f0-9]{3}|#?[a-f0-9]{6}|[a-z]+)$/i.exec(t.text);if(!r)throw new tO("Invalid color: '"+t.text+"'",t);var n=r[0];return/^[0-9a-f]{6}$/i.test(n)&&(n="#"+n),{type:"color-token",mode:this.mode,color:n}}parseSizeGroup(e){var t,r=!1;if(this.gullet.consumeSpaces(),!(t=e||"{"===this.gullet.future().text?this.parseStringGroup("size",e):this.parseRegexGroup(/^[-+]? *(?:$|\d+|\d+\.\d*|\.\d*) *[a-z]{0,2} *$/,"size")))return null;e||0!==t.text.length||(t.text="0pt",r=!0);var n=/([-+]?) *(\d+(?:\.\d*)?|\.\d+) *([a-z]{2})/.exec(t.text);if(!n)throw new tO("Invalid size: '"+t.text+"'",t);var o={number:+(n[1]+n[2]),unit:n[3]};if(!RO(o))throw new tO("Invalid unit: '"+o.unit+"'",t);return{type:"size",mode:this.mode,value:o,isBlank:r}}parseUrlGroup(e){this.gullet.lexer.setCatcode("%",13),this.gullet.lexer.setCatcode("~",12);var t=this.parseStringGroup("url",e);if(this.gullet.lexer.setCatcode("%",14),this.gullet.lexer.setCatcode("~",13),null==t)return null;var r=t.text.replace(/\\([#$%&~_^{}])/g,"$1");return{type:"url",mode:this.mode,url:r}}parseArgumentGroup(e,t){var r=this.gullet.scanArgument(e);if(null==r)return null;var n=this.mode;t&&this.switchMode(t),this.gullet.beginGroup();var o=this.parseExpression(!1,"EOF");this.expect("EOF"),this.gullet.endGroup();var i={type:"ordgroup",mode:this.mode,loc:r.loc,body:o};return t&&this.switchMode(n),i}parseGroup(e,t){var r,n=this.fetch(),o=n.text;if("{"===o||"\\begingroup"===o){this.consume();var i="{"===o?"}":"\\endgroup";this.gullet.beginGroup();var a=this.parseExpression(!1,i),s=this.fetch();this.expect(i),this.gullet.endGroup(),r={type:"ordgroup",mode:this.mode,loc:Qk.range(n,s),body:a,semisimple:"\\begingroup"===o||void 0}}else if(null==(r=this.parseFunction(t,e)||this.parseSymbol())&&"\\"===o[0]&&!HM.hasOwnProperty(o)){if(this.settings.throwOnError)throw new tO("Undefined control sequence: "+o,n);r=this.formatUnsupportedCmd(o),this.consume()}return r}formLigatures(e){for(var t=e.length-1,r=0;r<t;++r){var n=e[r],o=n.text;"-"===o&&"-"===e[r+1].text&&(r+1<t&&"-"===e[r+2].text?(e.splice(r,3,{type:"textord",mode:"text",loc:Qk.range(n,e[r+2]),text:"---"}),t-=2):(e.splice(r,2,{type:"textord",mode:"text",loc:Qk.range(n,e[r+1]),text:"--"}),t-=1)),"'"!==o&&"`"!==o||e[r+1].text!==o||(e.splice(r,2,{type:"textord",mode:"text",loc:Qk.range(n,e[r+1]),text:o+o}),t-=1)}}parseSymbol(){var e=this.fetch(),t=e.text;if(/^\\verb[^a-zA-Z]/.test(t)){this.consume();var r=t.slice(5),n="*"===r.charAt(0);if(n&&(r=r.slice(1)),r.length<2||r.charAt(0)!==r.slice(-1))throw new tO("\\verb assertion failed --\n please report what input caused this bug");return{type:"verb",mode:"text",body:r=r.slice(1,-1),star:n}}WM.hasOwnProperty(t[0])&&!tT[this.mode][t[0]]&&(this.settings.strict&&"math"===this.mode&&this.settings.reportNonstrict("unicodeTextInMathMode",'Accented Unicode text character "'+t[0]+'" used in math mode',e),t=WM[t[0]]+t.slice(1));var o,i=OM.exec(t);if(i&&("i"===(t=t.substring(0,i.index))?t="ı":"j"===t&&(t="ȷ")),tT[this.mode][t]){this.settings.strict&&"math"===this.mode&&PT.indexOf(t)>=0&&this.settings.reportNonstrict("unicodeTextInMathMode",'Latin-1/Unicode text character "'+t[0]+'" used in math mode',e);var a,s=tT[this.mode][t].group,u=Qk.range(e);if(QO.hasOwnProperty(s)){var l=s;a={type:"atom",mode:this.mode,family:l,loc:u,text:t}}else a={type:s,mode:this.mode,loc:u,text:t};o=a}else{if(!(t.charCodeAt(0)>=128))return null;this.settings.strict&&(CO(t.charCodeAt(0))?"math"===this.mode&&this.settings.reportNonstrict("unicodeTextInMathMode",'Unicode text character "'+t[0]+'" used in math mode',e):this.settings.reportNonstrict("unknownSymbol",'Unrecognized Unicode character "'+t[0]+'" ('+t.charCodeAt(0)+")",e)),o={type:"textord",mode:"text",loc:Qk.range(e),text:t}}if(this.consume(),i)for(var c=0;c<i[0].length;c++){var d=i[0][c];if(!qM[d])throw new tO("Unknown accent ' "+d+"'",e);var h=qM[d][this.mode]||qM[d].text;if(!h)throw new tO("Accent "+d+" unsupported in "+this.mode+" mode",e);o={type:"accent",mode:this.mode,loc:Qk.range(e),label:h,isStretchy:!1,isShifty:!0,base:o}}return o}}GM.endOfExpression=["}","\\endgroup","\\end","\\right","&"];var YM=function(e,t){if(!("string"==typeof e||e instanceof String))throw new TypeError("KaTeX can only parse string typed expression");var r=new GM(e,t);delete r.gullet.macros.current["\\df@tag"];var n=r.parse();if(delete r.gullet.macros.current["\\current@color"],delete r.gullet.macros.current["\\color"],r.gullet.macros.get("\\df@tag")){if(!t.displayMode)throw new tO("\\tag works only in display equations");n=[{type:"tag",mode:"text",body:n,tag:r.subparse([new eO("\\df@tag")])}]}return n},KM=function(e,t,r){t.textContent="";var n=ZM(e,r).toNode();t.appendChild(n)};"undefined"!=typeof document&&"CSS1Compat"!==document.compatMode&&("undefined"!=typeof console&&console.warn("Warning: KaTeX doesn't work in quirks mode. Make sure your website has a suitable doctype."),KM=function(){throw new tO("KaTeX doesn't work in quirks mode.")});var XM=function(e,t,r){if(r.throwOnError||!(e instanceof tO))throw e;var n=YT.makeSpan(["katex-error"],[new YO(t)]);return n.setAttribute("title",e.toString()),n.setAttribute("style","color:"+r.errorColor),n},ZM=function(e,t){var r=new lO(t);try{return function(e,t,r){var n,o=PN(r);if("mathml"===r.output)return NN(e,t,o,r.displayMode,!0);if("html"===r.output){var i=DN(e,o);n=YT.makeSpan(["katex"],[i])}else{var a=NN(e,t,o,r.displayMode,!1),s=DN(e,o);n=YT.makeSpan(["katex"],[a,s])}return MN(n,r)}(YM(e,r),e,r)}catch(t){return XM(t,e,r)}},JM={version:"0.16.22",render:KM,renderToString:function(e,t){return ZM(e,t).toMarkup()},ParseError:tO,SETTINGS_SCHEMA:sO,__parse:function(e,t){var r=new lO(t);return YM(e,r)},__renderToDomTree:ZM,__renderToHTMLTree:function(e,t){var r=new lO(t);try{return function(e,t,r){var n=DN(e,PN(r)),o=YT.makeSpan(["katex"],[n]);return MN(o,r)}(YM(e,r),0,r)}catch(t){return XM(t,e,r)}},__setFontMetrics:function(e,t){xO[e]=t},__defineSymbol:rT,__defineFunction:nN,__defineMacro:zP,__domTree:{Span:UO,Anchor:qO,SymbolNode:YO,SvgNode:KO,PathNode:XO,LineNode:ZO}},QM=function(e){function t(){var t=e.call(this)||this,r=t.attachShadow({mode:"open"}),n=r.ownerDocument.createElement("span");return n.style.display="inline-block",r.appendChild(n),t.span=n,t}return Yg(t,e),Object.defineProperty(t,"observedAttributes",{get:function(){return["data-value"]},enumerable:!1,configurable:!0}),t.prototype.attributeChangedCallback=function(e,t,r){if("data-value"===e){if(t===r)return;this.render(r||"")}},t.prototype.render=function(e){JM.render(e,this.span,{throwOnError:!1,output:"mathml"})},t}(HTMLElement);window.customElements.get("w-e-formula-card")||window.customElements.define("w-e-formula-card",QM),XD("en",{formula:{formula:"Formula",placeholder:"Use LateX syntax",insert:"Insert formula",edit:"Edit formula",textToFormula:"Convert to formula",ok:"OK"}}),XD("zh-CN",{formula:{formula:"公式",placeholder:"使用 LateX 语法",insert:"插入公式",edit:"编辑公式",textToFormula:"转换为公式",ok:"确定"}});var eI={type:"formula",elemToHtml:function(e,t){var r=e.value;return'<span data-w-e-type="formula" data-w-e-is-void data-w-e-is-inline data-value="'.concat(void 0===r?"":r,'"></span>')}},tI='<svg viewBox="0 0 1024 1024"><path d="M941.6 734.72L985.984 640H1024l-64 384H0v-74.24l331.552-391.2L0 227.008V0h980L1024 256h-34.368l-18.72-38.88C935.584 143.744 909.024 128 832 128H169.984l353.056 353.056L225.632 832H768c116 0 146.656-41.568 173.6-97.28z"></path></svg>';function rI(e){return void 0===e&&(e="r"),"".concat(e,"-").concat(zv())}function nI(e){return console.warn("composeFnDeal 被调用了"),console.log("原始 latex:",e),e=function(e){return e?(e=e.trim(),/^\$\$([\s\S]*)\$\$$/.test(e)?e=e.replace(/^\$\$([\s\S]*)\$\$$/,"$1"):/^\$([\s\S]*)\$/.test(e)?e=e.replace(/^\$([\s\S]*)\$$/,"$1"):/^\\\(([\s\S]*)\\\)$/.test(e)?e=e.replace(/^\\\(([\s\S]*)\\\)$/,"$1"):/^\\\[([\s\S]*)\\\]$/.test(e)&&(e=e.replace(/^\\\[([\s\S]*)\\\]$/,"$1")),e.trim()):e}(e=function(e){return e.replace(/\\text\{([^}]*)\}/g,function(e,t){var r=t.trim().split(/\s+/).join(" \\quad ");return"\\text{".concat(r,"}")})}(e)),console.log("去掉公式包裹符号后:",e),e=function(e){return e?e=(e=(e=(e=(e=e.replace(/\\begin\{align\}/g,"\\begin{aligned}")).replace(/\\end\{align\}/g,"\\end{aligned}")).replace(/\\frac\{(\d+)\}\{(\d+)\}/g,"\\tfrac{$1}{$2}")).replace(/\\left\\\{/g,"\\left\\{")).replace(/\\right\./g,"\\right."):e}(e),console.log("fixKatexFormula 处理后:",e),e=function(e){return e.replace(/\\left\[\s*\\begin\{matrix\}([\s\S]*?)\\end\{matrix\}\s*\\right\]/g,"\\begin{bmatrix}$1\\end{bmatrix}")}(e),console.log("fixMatrixForKaTeX 处理后:",e),e}function oI(){return rI("w-e-insert-formula")}Bv&&(ov.fn.append=Bv),Ev&&(ov.fn.html=Ev),hv&&(ov.fn.val=hv),fv&&(ov.fn.on=fv),Lv&&(ov.fn.focus=Lv),xv&&(ov.fn.is=xv),kv&&(ov.fn.parents=kv),Ov&&(ov.fn.find=Ov);var iI=function(){function e(){this.title=eC("formula.edit"),this.iconSvg='<svg viewBox="0 0 1024 1024"><path d="M864 0a160 160 0 0 1 128 256l-64 64-224-224 64-64c26.752-20.096 59.968-32 96-32zM64 736l-64 288 288-64 592-592-224-224L64 736z m651.584-372.416l-448 448-55.168-55.168 448-448 55.168 55.168z"></path></svg>',this.tag="button",this.showModal=!0,this.modalWidth=300,this.$content=null,this.textareaId=oI(),this.buttonId=oI()}return e.prototype.getSelectedElem=function(e){var t=Ry.getSelectedNodeByType(e,"formula");return null==t?null:t},e.prototype.getValue=function(e){var t=this.getSelectedElem(e);return t&&t.value||""},e.prototype.isActive=function(e){return!1},e.prototype.exec=function(e,t){},e.prototype.isDisabled=function(e){var t=e.selection;return null==t||(!!hg.isExpanded(t)||null==this.getSelectedElem(e))},e.prototype.getModalPositionNode=function(e){return this.getSelectedElem(e)},e.prototype.getModalContentElem=function(e){var t=this,r=this.textareaId,n=this.buttonId,o=Qg(hC(eC("formula.formula"),r,eC("formula.placeholder")),2),i=o[0],a=ov(o[1]),s=Qg(fC(n,eC("formula.ok")),1)[0];if(null==this.$content){var u=ov("<div></div>");u.on("click","#".concat(n),function(n){n.preventDefault();var o=u.find("#".concat(r)).val().trim();o=nI(o),t.updateFormula(e,o),e.hidePanelOrModal()}),this.$content=u}var l=this.$content;l.html(""),l.append(i),l.append(s);var c=this.getValue(e);return a.val(c),setTimeout(function(){a.focus()}),l[0]},e.prototype.updateFormula=function(e,t){if(t&&(e.restoreSelection(),!this.isDisabled(e))){var r=this.getSelectedElem(e);if(null!=r){var n=Ry.findPath(e,r),o={value:t};zg.setNodes(e,o,{at:n})}}},e}();
|
|
27
|
+
/*!
|
|
28
|
+
* is-plain-object <https://github.com/jonschlinkert/is-plain-object>
|
|
29
|
+
*
|
|
30
|
+
* Copyright (c) 2014-2017, Jon Schlinkert.
|
|
31
|
+
* Released under the MIT License.
|
|
32
|
+
*/function aI(e){return"[object Object]"===Object.prototype.toString.call(e)}function sI(e){var t,r;return!1!==aI(e)&&(void 0===(t=e.constructor)||!1!==aI(r=t.prototype)&&!1!==r.hasOwnProperty("isPrototypeOf"))}function uI(e){for(var t=arguments.length,r=Array(t>1?t-1:0),n=1;n<t;n++)r[n-1]=arguments[n];throw Error("[Immer] minified error nr: "+e+(r.length?" "+r.map(function(e){return"'"+e+"'"}).join(","):"")+". Find the full error at: https://bit.ly/3cXEKWf")}function lI(e){return!!e&&!!e[YI]}function cI(e){var t;return!!e&&(function(e){if(!e||"object"!=typeof e)return!1;var t=Object.getPrototypeOf(e);if(null===t)return!0;var r=Object.hasOwnProperty.call(t,"constructor")&&t.constructor;return r===Object||"function"==typeof r&&Function.toString.call(r)===KI}(e)||Array.isArray(e)||!!e[GI]||!!(null===(t=e.constructor)||void 0===t?void 0:t[GI])||gI(e)||mI(e))}function dI(e,t,r){void 0===r&&(r=!1),0===hI(e)?(r?Object.keys:XI)(e).forEach(function(n){r&&"symbol"==typeof n||t(n,e[n],e)}):e.forEach(function(r,n){return t(n,r,e)})}function hI(e){var t=e[YI];return t?t.i>3?t.i-4:t.i:Array.isArray(e)?1:gI(e)?2:mI(e)?3:0}function fI(e,t){return 2===hI(e)?e.has(t):Object.prototype.hasOwnProperty.call(e,t)}function pI(e,t,r){var n=hI(e);2===n?e.set(t,r):3===n?e.add(r):e[t]=r}function gI(e){return $I&&e instanceof Map}function mI(e){return UI&&e instanceof Set}function vI(e){return e.o||e.t}function yI(e){if(Array.isArray(e))return Array.prototype.slice.call(e);var t=ZI(e);delete t[YI];for(var r=XI(t),n=0;n<r.length;n++){var o=r[n],i=t[o];!1===i.writable&&(i.writable=!0,i.configurable=!0),(i.get||i.set)&&(t[o]={configurable:!0,writable:!0,enumerable:i.enumerable,value:e[o]})}return Object.create(Object.getPrototypeOf(e),t)}function bI(e,t){return void 0===t&&(t=!1),CI(e)||lI(e)||!cI(e)||(hI(e)>1&&(e.set=e.add=e.clear=e.delete=DI),Object.freeze(e),t&&dI(e,function(e,t){return bI(t,!0)},!0)),e}function DI(){uI(2)}function CI(e){return null==e||"object"!=typeof e||Object.isFrozen(e)}function wI(e){var t=JI[e];return t||uI(18,e),t}function EI(){return HI}function AI(e,t){t&&(wI("Patches"),e.u=[],e.s=[],e.v=t)}function xI(e){BI(e),e.p.forEach(FI),e.p=null}function BI(e){e===HI&&(HI=e.l)}function SI(e){return HI={p:[],l:HI,h:e,m:!0,_:0}}function FI(e){var t=e[YI];0===t.i||1===t.i?t.j():t.g=!0}function kI(e,t){t._=t.p.length;var r=t.p[0],n=void 0!==e&&e!==r;return t.h.O||wI("ES5").S(t,e,n),n?(r[YI].P&&(xI(t),uI(4)),cI(e)&&(e=OI(t,e),t.l||NI(t,e)),t.u&&wI("Patches").M(r[YI].t,e,t.u,t.s)):e=OI(t,r,[]),xI(t),t.u&&t.v(t.u,t.s),e!==WI?e:void 0}function OI(e,t,r){if(CI(t))return t;var n=t[YI];if(!n)return dI(t,function(o,i){return TI(e,n,t,o,i,r)},!0),t;if(n.A!==e)return t;if(!n.P)return NI(e,n.t,!0),n.t;if(!n.I){n.I=!0,n.A._--;var o=4===n.i||5===n.i?n.o=yI(n.k):n.o,i=o,a=!1;3===n.i&&(i=new Set(o),o.clear(),a=!0),dI(i,function(t,i){return TI(e,n,o,t,i,r,a)}),NI(e,o,!1),r&&e.u&&wI("Patches").N(n,r,e.u,e.s)}return n.o}function TI(e,t,r,n,o,i,a){if(lI(o)){var s=OI(e,o,i&&t&&3!==t.i&&!fI(t.R,n)?i.concat(n):void 0);if(pI(r,n,s),!lI(s))return;e.m=!1}else a&&r.add(o);if(cI(o)&&!CI(o)){if(!e.h.D&&e._<1)return;OI(e,o),t&&t.A.l||NI(e,o)}}function NI(e,t,r){void 0===r&&(r=!1),!e.l&&e.h.D&&e.m&&bI(t,r)}function PI(e,t){var r=e[YI];return(r?vI(r):e)[t]}function MI(e,t){if(t in e)for(var r=Object.getPrototypeOf(e);r;){var n=Object.getOwnPropertyDescriptor(r,t);if(n)return n;r=Object.getPrototypeOf(r)}}function II(e){e.P||(e.P=!0,e.l&&II(e.l))}function RI(e){e.o||(e.o=yI(e.t))}function LI(e,t,r){var n=gI(t)?wI("MapSet").F(t,r):mI(t)?wI("MapSet").T(t,r):e.O?function(e,t){var r=Array.isArray(e),n={i:r?1:0,A:t?t.A:EI(),P:!1,I:!1,R:{},l:t,t:e,k:null,o:null,j:null,C:!1},o=n,i=QI;r&&(o=[n],i=eR);var a=Proxy.revocable(o,i),s=a.revoke,u=a.proxy;return n.k=u,n.j=s,u}(t,r):wI("ES5").J(t,r);return(r?r.A:EI()).p.push(n),n}function _I(e){return lI(e)||uI(22,e),function e(t){if(!cI(t))return t;var r,n=t[YI],o=hI(t);if(n){if(!n.P&&(n.i<4||!wI("ES5").K(n)))return n.t;n.I=!0,r=zI(t,o),n.I=!1}else r=zI(t,o);return dI(r,function(t,o){n&&function(e,t){return 2===hI(e)?e.get(t):e[t]}(n.t,t)===o||pI(r,t,e(o))}),3===o?new Set(r):r}(e)}function zI(e,t){switch(t){case 2:return new Map(e);case 3:return Array.from(e)}return yI(e)}var jI,HI,VI="undefined"!=typeof Symbol&&"symbol"==typeof Symbol("x"),$I="undefined"!=typeof Map,UI="undefined"!=typeof Set,qI="undefined"!=typeof Proxy&&void 0!==Proxy.revocable&&"undefined"!=typeof Reflect,WI=VI?Symbol.for("immer-nothing"):((jI={})["immer-nothing"]=!0,jI),GI=VI?Symbol.for("immer-draftable"):"__$immer_draftable",YI=VI?Symbol.for("immer-state"):"__$immer_state",KI=""+Object.prototype.constructor,XI="undefined"!=typeof Reflect&&Reflect.ownKeys?Reflect.ownKeys:void 0!==Object.getOwnPropertySymbols?function(e){return Object.getOwnPropertyNames(e).concat(Object.getOwnPropertySymbols(e))}:Object.getOwnPropertyNames,ZI=Object.getOwnPropertyDescriptors||function(e){var t={};return XI(e).forEach(function(r){t[r]=Object.getOwnPropertyDescriptor(e,r)}),t},JI={},QI={get:function(e,t){if(t===YI)return e;var r=vI(e);if(!fI(r,t))return function(e,t,r){var n,o=MI(t,r);return o?"value"in o?o.value:null===(n=o.get)||void 0===n?void 0:n.call(e.k):void 0}(e,r,t);var n=r[t];return e.I||!cI(n)?n:n===PI(e.t,t)?(RI(e),e.o[t]=LI(e.A.h,n,e)):n},has:function(e,t){return t in vI(e)},ownKeys:function(e){return Reflect.ownKeys(vI(e))},set:function(e,t,r){var n=MI(vI(e),t);if(null==n?void 0:n.set)return n.set.call(e.k,r),!0;if(!e.P){var o=PI(vI(e),t),i=null==o?void 0:o[YI];if(i&&i.t===r)return e.o[t]=r,e.R[t]=!1,!0;if(function(e,t){return e===t?0!==e||1/e==1/t:e!=e&&t!=t}(r,o)&&(void 0!==r||fI(e.t,t)))return!0;RI(e),II(e)}return e.o[t]===r&&(void 0!==r||t in e.o)||Number.isNaN(r)&&Number.isNaN(e.o[t])||(e.o[t]=r,e.R[t]=!0),!0},deleteProperty:function(e,t){return void 0!==PI(e.t,t)||t in e.t?(e.R[t]=!1,RI(e),II(e)):delete e.R[t],e.o&&delete e.o[t],!0},getOwnPropertyDescriptor:function(e,t){var r=vI(e),n=Reflect.getOwnPropertyDescriptor(r,t);return n?{writable:!0,configurable:1!==e.i||"length"!==t,enumerable:n.enumerable,value:r[t]}:n},defineProperty:function(){uI(11)},getPrototypeOf:function(e){return Object.getPrototypeOf(e.t)},setPrototypeOf:function(){uI(12)}},eR={};dI(QI,function(e,t){eR[e]=function(){return arguments[0]=arguments[0][0],t.apply(this,arguments)}}),eR.deleteProperty=function(e,t){return eR.set.call(this,e,t,void 0)},eR.set=function(e,t,r){return QI.set.call(this,e[0],t,r,e[0])};var tR=function(){function e(e){var t=this;this.O=qI,this.D=!0,this.produce=function(e,r,n){if("function"==typeof e&&"function"!=typeof r){var o=r;r=e;var i=t;return function(e){var t=this;void 0===e&&(e=o);for(var n=arguments.length,a=Array(n>1?n-1:0),s=1;s<n;s++)a[s-1]=arguments[s];return i.produce(e,function(e){var n;return(n=r).call.apply(n,[t,e].concat(a))})}}var a;if("function"!=typeof r&&uI(6),void 0!==n&&"function"!=typeof n&&uI(7),cI(e)){var s=SI(t),u=LI(t,e,void 0),l=!0;try{a=r(u),l=!1}finally{l?xI(s):BI(s)}return"undefined"!=typeof Promise&&a instanceof Promise?a.then(function(e){return AI(s,n),kI(e,s)},function(e){throw xI(s),e}):(AI(s,n),kI(a,s))}if(!e||"object"!=typeof e){if(void 0===(a=r(e))&&(a=e),a===WI&&(a=void 0),t.D&&bI(a,!0),n){var c=[],d=[];wI("Patches").M(e,a,c,d),n(c,d)}return a}uI(21,e)},this.produceWithPatches=function(e,r){if("function"==typeof e)return function(r){for(var n=arguments.length,o=Array(n>1?n-1:0),i=1;i<n;i++)o[i-1]=arguments[i];return t.produceWithPatches(r,function(t){return e.apply(void 0,[t].concat(o))})};var n,o,i=t.produce(e,r,function(e,t){n=e,o=t});return"undefined"!=typeof Promise&&i instanceof Promise?i.then(function(e){return[e,n,o]}):[i,n,o]},"boolean"==typeof(null==e?void 0:e.useProxies)&&this.setUseProxies(e.useProxies),"boolean"==typeof(null==e?void 0:e.autoFreeze)&&this.setAutoFreeze(e.autoFreeze)}var t=e.prototype;return t.createDraft=function(e){cI(e)||uI(8),lI(e)&&(e=_I(e));var t=SI(this),r=LI(this,e,void 0);return r[YI].C=!0,BI(t),r},t.finishDraft=function(e,t){var r=(e&&e[YI]).A;return AI(r,t),kI(void 0,r)},t.setAutoFreeze=function(e){this.D=e},t.setUseProxies=function(e){e&&!qI&&uI(20),this.O=e},t.applyPatches=function(e,t){var r;for(r=t.length-1;r>=0;r--){var n=t[r];if(0===n.path.length&&"replace"===n.op){e=n.value;break}}r>-1&&(t=t.slice(r+1));var o=wI("Patches").$;return lI(e)?o(e,t):this.produce(e,function(e){return o(e,t)})},e}(),rR=new tR,nR=rR.produce;rR.produceWithPatches.bind(rR),rR.setAutoFreeze.bind(rR),rR.setUseProxies.bind(rR),rR.applyPatches.bind(rR);var oR=rR.createDraft.bind(rR),iR=rR.finishDraft.bind(rR);function aR(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var sR=new WeakMap,uR=new WeakMap,lR=new WeakMap,cR=new WeakMap,dR=new WeakMap,hR=new WeakMap;function fR(e,t){if(null==e)return{};var r,n,o=function(e,t){if(null==e)return{};var r,n,o={},i=Object.keys(e);for(n=0;n<i.length;n++)r=i[n],t.indexOf(r)>=0||(o[r]=e[r]);return o}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(n=0;n<i.length;n++)r=i[n],t.indexOf(r)>=0||Object.prototype.propertyIsEnumerable.call(e,r)&&(o[r]=e[r])}return o}var pR,gR=function(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1],r=!t,n=t?CR(e):e,o=pR.None,i=pR.None,a=0,s=null;for(var u of n){var l=u.codePointAt(0);if(!l)break;var c=PR(u,l);if([o,i]=r?[i,c]:[c,o],MR(o,pR.ZWJ)&&MR(i,pR.ExtPict)&&!_R(r?e.substring(0,a):e.substring(0,e.length-a)))break;if(MR(o,pR.RI)&&MR(i,pR.RI)&&!(s=null!==s?!s:!!r||jR(e.substring(0,e.length-a))))break;if(o!==pR.None&&i!==pR.None&&RR(o,i))break;a+=u.length}return a||1},mR=/\s/,vR=/[\u0021-\u0023\u0025-\u002A\u002C-\u002F\u003A\u003B\u003F\u0040\u005B-\u005D\u005F\u007B\u007D\u00A1\u00A7\u00AB\u00B6\u00B7\u00BB\u00BF\u037E\u0387\u055A-\u055F\u0589\u058A\u05BE\u05C0\u05C3\u05C6\u05F3\u05F4\u0609\u060A\u060C\u060D\u061B\u061E\u061F\u066A-\u066D\u06D4\u0700-\u070D\u07F7-\u07F9\u0830-\u083E\u085E\u0964\u0965\u0970\u0AF0\u0DF4\u0E4F\u0E5A\u0E5B\u0F04-\u0F12\u0F14\u0F3A-\u0F3D\u0F85\u0FD0-\u0FD4\u0FD9\u0FDA\u104A-\u104F\u10FB\u1360-\u1368\u1400\u166D\u166E\u169B\u169C\u16EB-\u16ED\u1735\u1736\u17D4-\u17D6\u17D8-\u17DA\u1800-\u180A\u1944\u1945\u1A1E\u1A1F\u1AA0-\u1AA6\u1AA8-\u1AAD\u1B5A-\u1B60\u1BFC-\u1BFF\u1C3B-\u1C3F\u1C7E\u1C7F\u1CC0-\u1CC7\u1CD3\u2010-\u2027\u2030-\u2043\u2045-\u2051\u2053-\u205E\u207D\u207E\u208D\u208E\u2329\u232A\u2768-\u2775\u27C5\u27C6\u27E6-\u27EF\u2983-\u2998\u29D8-\u29DB\u29FC\u29FD\u2CF9-\u2CFC\u2CFE\u2CFF\u2D70\u2E00-\u2E2E\u2E30-\u2E3B\u3001-\u3003\u3008-\u3011\u3014-\u301F\u3030\u303D\u30A0\u30FB\uA4FE\uA4FF\uA60D-\uA60F\uA673\uA67E\uA6F2-\uA6F7\uA874-\uA877\uA8CE\uA8CF\uA8F8-\uA8FA\uA92E\uA92F\uA95F\uA9C1-\uA9CD\uA9DE\uA9DF\uAA5C-\uAA5F\uAADE\uAADF\uAAF0\uAAF1\uABEB\uFD3E\uFD3F\uFE10-\uFE19\uFE30-\uFE52\uFE54-\uFE61\uFE63\uFE68\uFE6A\uFE6B\uFF01-\uFF03\uFF05-\uFF0A\uFF0C-\uFF0F\uFF1A\uFF1B\uFF1F\uFF20\uFF3B-\uFF3D\uFF3F\uFF5B\uFF5D\uFF5F-\uFF65]/,yR=/['\u2018\u2019]/,bR=(e,t,r)=>{if(r){var n=e.length-t;return[e.slice(n,e.length),e.slice(0,n)]}return[e.slice(0,t),e.slice(t)]},DR=function e(t,r){var n=arguments.length>2&&void 0!==arguments[2]&&arguments[2];if(mR.test(t))return!1;if(yR.test(t)){var o=gR(r,n),[i,a]=bR(r,o,n);if(e(i,a,n))return!0}return!vR.test(t)},CR=function*(e){for(var t=e.length-1,r=0;r<e.length;r++){var n=e.charAt(t-r);if(ER(n.charCodeAt(0))){var o=e.charAt(t-r-1);if(wR(o.charCodeAt(0))){yield o+n,r++;continue}}yield n}},wR=e=>e>=55296&&e<=56319,ER=e=>e>=56320&&e<=57343;!function(e){e[e.None=0]="None",e[e.Extend=1]="Extend",e[e.ZWJ=2]="ZWJ",e[e.RI=4]="RI",e[e.Prepend=8]="Prepend",e[e.SpacingMark=16]="SpacingMark",e[e.L=32]="L",e[e.V=64]="V",e[e.T=128]="T",e[e.LV=256]="LV",e[e.LVT=512]="LVT",e[e.ExtPict=1024]="ExtPict",e[e.Any=2048]="Any"}(pR||(pR={}));var AR=/^(?:[\u0300-\u036F\u0483-\u0489\u0591-\u05BD\u05BF\u05C1\u05C2\u05C4\u05C5\u05C7\u0610-\u061A\u064B-\u065F\u0670\u06D6-\u06DC\u06DF-\u06E4\u06E7\u06E8\u06EA-\u06ED\u0711\u0730-\u074A\u07A6-\u07B0\u07EB-\u07F3\u07FD\u0816-\u0819\u081B-\u0823\u0825-\u0827\u0829-\u082D\u0859-\u085B\u08D3-\u08E1\u08E3-\u0902\u093A\u093C\u0941-\u0948\u094D\u0951-\u0957\u0962\u0963\u0981\u09BC\u09BE\u09C1-\u09C4\u09CD\u09D7\u09E2\u09E3\u09FE\u0A01\u0A02\u0A3C\u0A41\u0A42\u0A47\u0A48\u0A4B-\u0A4D\u0A51\u0A70\u0A71\u0A75\u0A81\u0A82\u0ABC\u0AC1-\u0AC5\u0AC7\u0AC8\u0ACD\u0AE2\u0AE3\u0AFA-\u0AFF\u0B01\u0B3C\u0B3E\u0B3F\u0B41-\u0B44\u0B4D\u0B55-\u0B57\u0B62\u0B63\u0B82\u0BBE\u0BC0\u0BCD\u0BD7\u0C00\u0C04\u0C3E-\u0C40\u0C46-\u0C48\u0C4A-\u0C4D\u0C55\u0C56\u0C62\u0C63\u0C81\u0CBC\u0CBF\u0CC2\u0CC6\u0CCC\u0CCD\u0CD5\u0CD6\u0CE2\u0CE3\u0D00\u0D01\u0D3B\u0D3C\u0D3E\u0D41-\u0D44\u0D4D\u0D57\u0D62\u0D63\u0D81\u0DCA\u0DCF\u0DD2-\u0DD4\u0DD6\u0DDF\u0E31\u0E34-\u0E3A\u0E47-\u0E4E\u0EB1\u0EB4-\u0EBC\u0EC8-\u0ECD\u0F18\u0F19\u0F35\u0F37\u0F39\u0F71-\u0F7E\u0F80-\u0F84\u0F86\u0F87\u0F8D-\u0F97\u0F99-\u0FBC\u0FC6\u102D-\u1030\u1032-\u1037\u1039\u103A\u103D\u103E\u1058\u1059\u105E-\u1060\u1071-\u1074\u1082\u1085\u1086\u108D\u109D\u135D-\u135F\u1712-\u1714\u1732-\u1734\u1752\u1753\u1772\u1773\u17B4\u17B5\u17B7-\u17BD\u17C6\u17C9-\u17D3\u17DD\u180B-\u180D\u1885\u1886\u18A9\u1920-\u1922\u1927\u1928\u1932\u1939-\u193B\u1A17\u1A18\u1A1B\u1A56\u1A58-\u1A5E\u1A60\u1A62\u1A65-\u1A6C\u1A73-\u1A7C\u1A7F\u1AB0-\u1AC0\u1B00-\u1B03\u1B34-\u1B3A\u1B3C\u1B42\u1B6B-\u1B73\u1B80\u1B81\u1BA2-\u1BA5\u1BA8\u1BA9\u1BAB-\u1BAD\u1BE6\u1BE8\u1BE9\u1BED\u1BEF-\u1BF1\u1C2C-\u1C33\u1C36\u1C37\u1CD0-\u1CD2\u1CD4-\u1CE0\u1CE2-\u1CE8\u1CED\u1CF4\u1CF8\u1CF9\u1DC0-\u1DF9\u1DFB-\u1DFF\u200C\u20D0-\u20F0\u2CEF-\u2CF1\u2D7F\u2DE0-\u2DFF\u302A-\u302F\u3099\u309A\uA66F-\uA672\uA674-\uA67D\uA69E\uA69F\uA6F0\uA6F1\uA802\uA806\uA80B\uA825\uA826\uA82C\uA8C4\uA8C5\uA8E0-\uA8F1\uA8FF\uA926-\uA92D\uA947-\uA951\uA980-\uA982\uA9B3\uA9B6-\uA9B9\uA9BC\uA9BD\uA9E5\uAA29-\uAA2E\uAA31\uAA32\uAA35\uAA36\uAA43\uAA4C\uAA7C\uAAB0\uAAB2-\uAAB4\uAAB7\uAAB8\uAABE\uAABF\uAAC1\uAAEC\uAAED\uAAF6\uABE5\uABE8\uABED\uFB1E\uFE00-\uFE0F\uFE20-\uFE2F\uFF9E\uFF9F]|\uD800[\uDDFD\uDEE0\uDF76-\uDF7A]|\uD802[\uDE01-\uDE03\uDE05\uDE06\uDE0C-\uDE0F\uDE38-\uDE3A\uDE3F\uDEE5\uDEE6]|\uD803[\uDD24-\uDD27\uDEAB\uDEAC\uDF46-\uDF50]|\uD804[\uDC01\uDC38-\uDC46\uDC7F-\uDC81\uDCB3-\uDCB6\uDCB9\uDCBA\uDD00-\uDD02\uDD27-\uDD2B\uDD2D-\uDD34\uDD73\uDD80\uDD81\uDDB6-\uDDBE\uDDC9-\uDDCC\uDDCF\uDE2F-\uDE31\uDE34\uDE36\uDE37\uDE3E\uDEDF\uDEE3-\uDEEA\uDF00\uDF01\uDF3B\uDF3C\uDF3E\uDF40\uDF57\uDF66-\uDF6C\uDF70-\uDF74]|\uD805[\uDC38-\uDC3F\uDC42-\uDC44\uDC46\uDC5E\uDCB0\uDCB3-\uDCB8\uDCBA\uDCBD\uDCBF\uDCC0\uDCC2\uDCC3\uDDAF\uDDB2-\uDDB5\uDDBC\uDDBD\uDDBF\uDDC0\uDDDC\uDDDD\uDE33-\uDE3A\uDE3D\uDE3F\uDE40\uDEAB\uDEAD\uDEB0-\uDEB5\uDEB7\uDF1D-\uDF1F\uDF22-\uDF25\uDF27-\uDF2B]|\uD806[\uDC2F-\uDC37\uDC39\uDC3A\uDD30\uDD3B\uDD3C\uDD3E\uDD43\uDDD4-\uDDD7\uDDDA\uDDDB\uDDE0\uDE01-\uDE0A\uDE33-\uDE38\uDE3B-\uDE3E\uDE47\uDE51-\uDE56\uDE59-\uDE5B\uDE8A-\uDE96\uDE98\uDE99]|\uD807[\uDC30-\uDC36\uDC38-\uDC3D\uDC3F\uDC92-\uDCA7\uDCAA-\uDCB0\uDCB2\uDCB3\uDCB5\uDCB6\uDD31-\uDD36\uDD3A\uDD3C\uDD3D\uDD3F-\uDD45\uDD47\uDD90\uDD91\uDD95\uDD97\uDEF3\uDEF4]|\uD81A[\uDEF0-\uDEF4\uDF30-\uDF36]|\uD81B[\uDF4F\uDF8F-\uDF92\uDFE4]|\uD82F[\uDC9D\uDC9E]|\uD834[\uDD65\uDD67-\uDD69\uDD6E-\uDD72\uDD7B-\uDD82\uDD85-\uDD8B\uDDAA-\uDDAD\uDE42-\uDE44]|\uD836[\uDE00-\uDE36\uDE3B-\uDE6C\uDE75\uDE84\uDE9B-\uDE9F\uDEA1-\uDEAF]|\uD838[\uDC00-\uDC06\uDC08-\uDC18\uDC1B-\uDC21\uDC23\uDC24\uDC26-\uDC2A\uDD30-\uDD36\uDEEC-\uDEEF]|\uD83A[\uDCD0-\uDCD6\uDD44-\uDD4A]|\uD83C[\uDFFB-\uDFFF]|\uDB40[\uDC20-\uDC7F\uDD00-\uDDEF])$/,xR=/^(?:[\u0600-\u0605\u06DD\u070F\u0890\u0891\u08E2\u0D4E]|\uD804[\uDCBD\uDCCD\uDDC2\uDDC3]|\uD806[\uDD3F\uDD41\uDE3A\uDE84-\uDE89]|\uD807\uDD46)$/,BR=/^(?:[\u0903\u093B\u093E-\u0940\u0949-\u094C\u094E\u094F\u0982\u0983\u09BF\u09C0\u09C7\u09C8\u09CB\u09CC\u0A03\u0A3E-\u0A40\u0A83\u0ABE-\u0AC0\u0AC9\u0ACB\u0ACC\u0B02\u0B03\u0B40\u0B47\u0B48\u0B4B\u0B4C\u0BBF\u0BC1\u0BC2\u0BC6-\u0BC8\u0BCA-\u0BCC\u0C01-\u0C03\u0C41-\u0C44\u0C82\u0C83\u0CBE\u0CC0\u0CC1\u0CC3\u0CC4\u0CC7\u0CC8\u0CCA\u0CCB\u0D02\u0D03\u0D3F\u0D40\u0D46-\u0D48\u0D4A-\u0D4C\u0D82\u0D83\u0DD0\u0DD1\u0DD8-\u0DDE\u0DF2\u0DF3\u0E33\u0EB3\u0F3E\u0F3F\u0F7F\u1031\u103B\u103C\u1056\u1057\u1084\u1715\u1734\u17B6\u17BE-\u17C5\u17C7\u17C8\u1923-\u1926\u1929-\u192B\u1930\u1931\u1933-\u1938\u1A19\u1A1A\u1A55\u1A57\u1A6D-\u1A72\u1B04\u1B3B\u1B3D-\u1B41\u1B43\u1B44\u1B82\u1BA1\u1BA6\u1BA7\u1BAA\u1BE7\u1BEA-\u1BEC\u1BEE\u1BF2\u1BF3\u1C24-\u1C2B\u1C34\u1C35\u1CE1\u1CF7\uA823\uA824\uA827\uA880\uA881\uA8B4-\uA8C3\uA952\uA953\uA983\uA9B4\uA9B5\uA9BA\uA9BB\uA9BE-\uA9C0\uAA2F\uAA30\uAA33\uAA34\uAA4D\uAAEB\uAAEE\uAAEF\uAAF5\uABE3\uABE4\uABE6\uABE7\uABE9\uABEA\uABEC]|\uD804[\uDC00\uDC02\uDC82\uDCB0-\uDCB2\uDCB7\uDCB8\uDD2C\uDD45\uDD46\uDD82\uDDB3-\uDDB5\uDDBF\uDDC0\uDDCE\uDE2C-\uDE2E\uDE32\uDE33\uDE35\uDEE0-\uDEE2\uDF02\uDF03\uDF3F\uDF41-\uDF44\uDF47\uDF48\uDF4B-\uDF4D\uDF62\uDF63]|\uD805[\uDC35-\uDC37\uDC40\uDC41\uDC45\uDCB1\uDCB2\uDCB9\uDCBB\uDCBC\uDCBE\uDCC1\uDDB0\uDDB1\uDDB8-\uDDBB\uDDBE\uDE30-\uDE32\uDE3B\uDE3C\uDE3E\uDEAC\uDEAE\uDEAF\uDEB6\uDF26]|\uD806[\uDC2C-\uDC2E\uDC38\uDD31-\uDD35\uDD37\uDD38\uDD3D\uDD40\uDD42\uDDD1-\uDDD3\uDDDC-\uDDDF\uDDE4\uDE39\uDE57\uDE58\uDE97]|\uD807[\uDC2F\uDC3E\uDCA9\uDCB1\uDCB4\uDD8A-\uDD8E\uDD93\uDD94\uDD96\uDEF5\uDEF6]|\uD81B[\uDF51-\uDF87\uDFF0\uDFF1]|\uD834[\uDD66\uDD6D])$/,SR=/^[\u1100-\u115F\uA960-\uA97C]$/,FR=/^[\u1160-\u11A7\uD7B0-\uD7C6]$/,kR=/^[\u11A8-\u11FF\uD7CB-\uD7FB]$/,OR=/^[\uAC00\uAC1C\uAC38\uAC54\uAC70\uAC8C\uACA8\uACC4\uACE0\uACFC\uAD18\uAD34\uAD50\uAD6C\uAD88\uADA4\uADC0\uADDC\uADF8\uAE14\uAE30\uAE4C\uAE68\uAE84\uAEA0\uAEBC\uAED8\uAEF4\uAF10\uAF2C\uAF48\uAF64\uAF80\uAF9C\uAFB8\uAFD4\uAFF0\uB00C\uB028\uB044\uB060\uB07C\uB098\uB0B4\uB0D0\uB0EC\uB108\uB124\uB140\uB15C\uB178\uB194\uB1B0\uB1CC\uB1E8\uB204\uB220\uB23C\uB258\uB274\uB290\uB2AC\uB2C8\uB2E4\uB300\uB31C\uB338\uB354\uB370\uB38C\uB3A8\uB3C4\uB3E0\uB3FC\uB418\uB434\uB450\uB46C\uB488\uB4A4\uB4C0\uB4DC\uB4F8\uB514\uB530\uB54C\uB568\uB584\uB5A0\uB5BC\uB5D8\uB5F4\uB610\uB62C\uB648\uB664\uB680\uB69C\uB6B8\uB6D4\uB6F0\uB70C\uB728\uB744\uB760\uB77C\uB798\uB7B4\uB7D0\uB7EC\uB808\uB824\uB840\uB85C\uB878\uB894\uB8B0\uB8CC\uB8E8\uB904\uB920\uB93C\uB958\uB974\uB990\uB9AC\uB9C8\uB9E4\uBA00\uBA1C\uBA38\uBA54\uBA70\uBA8C\uBAA8\uBAC4\uBAE0\uBAFC\uBB18\uBB34\uBB50\uBB6C\uBB88\uBBA4\uBBC0\uBBDC\uBBF8\uBC14\uBC30\uBC4C\uBC68\uBC84\uBCA0\uBCBC\uBCD8\uBCF4\uBD10\uBD2C\uBD48\uBD64\uBD80\uBD9C\uBDB8\uBDD4\uBDF0\uBE0C\uBE28\uBE44\uBE60\uBE7C\uBE98\uBEB4\uBED0\uBEEC\uBF08\uBF24\uBF40\uBF5C\uBF78\uBF94\uBFB0\uBFCC\uBFE8\uC004\uC020\uC03C\uC058\uC074\uC090\uC0AC\uC0C8\uC0E4\uC100\uC11C\uC138\uC154\uC170\uC18C\uC1A8\uC1C4\uC1E0\uC1FC\uC218\uC234\uC250\uC26C\uC288\uC2A4\uC2C0\uC2DC\uC2F8\uC314\uC330\uC34C\uC368\uC384\uC3A0\uC3BC\uC3D8\uC3F4\uC410\uC42C\uC448\uC464\uC480\uC49C\uC4B8\uC4D4\uC4F0\uC50C\uC528\uC544\uC560\uC57C\uC598\uC5B4\uC5D0\uC5EC\uC608\uC624\uC640\uC65C\uC678\uC694\uC6B0\uC6CC\uC6E8\uC704\uC720\uC73C\uC758\uC774\uC790\uC7AC\uC7C8\uC7E4\uC800\uC81C\uC838\uC854\uC870\uC88C\uC8A8\uC8C4\uC8E0\uC8FC\uC918\uC934\uC950\uC96C\uC988\uC9A4\uC9C0\uC9DC\uC9F8\uCA14\uCA30\uCA4C\uCA68\uCA84\uCAA0\uCABC\uCAD8\uCAF4\uCB10\uCB2C\uCB48\uCB64\uCB80\uCB9C\uCBB8\uCBD4\uCBF0\uCC0C\uCC28\uCC44\uCC60\uCC7C\uCC98\uCCB4\uCCD0\uCCEC\uCD08\uCD24\uCD40\uCD5C\uCD78\uCD94\uCDB0\uCDCC\uCDE8\uCE04\uCE20\uCE3C\uCE58\uCE74\uCE90\uCEAC\uCEC8\uCEE4\uCF00\uCF1C\uCF38\uCF54\uCF70\uCF8C\uCFA8\uCFC4\uCFE0\uCFFC\uD018\uD034\uD050\uD06C\uD088\uD0A4\uD0C0\uD0DC\uD0F8\uD114\uD130\uD14C\uD168\uD184\uD1A0\uD1BC\uD1D8\uD1F4\uD210\uD22C\uD248\uD264\uD280\uD29C\uD2B8\uD2D4\uD2F0\uD30C\uD328\uD344\uD360\uD37C\uD398\uD3B4\uD3D0\uD3EC\uD408\uD424\uD440\uD45C\uD478\uD494\uD4B0\uD4CC\uD4E8\uD504\uD520\uD53C\uD558\uD574\uD590\uD5AC\uD5C8\uD5E4\uD600\uD61C\uD638\uD654\uD670\uD68C\uD6A8\uD6C4\uD6E0\uD6FC\uD718\uD734\uD750\uD76C\uD788]$/,TR=/^[\uAC01-\uAC1B\uAC1D-\uAC37\uAC39-\uAC53\uAC55-\uAC6F\uAC71-\uAC8B\uAC8D-\uACA7\uACA9-\uACC3\uACC5-\uACDF\uACE1-\uACFB\uACFD-\uAD17\uAD19-\uAD33\uAD35-\uAD4F\uAD51-\uAD6B\uAD6D-\uAD87\uAD89-\uADA3\uADA5-\uADBF\uADC1-\uADDB\uADDD-\uADF7\uADF9-\uAE13\uAE15-\uAE2F\uAE31-\uAE4B\uAE4D-\uAE67\uAE69-\uAE83\uAE85-\uAE9F\uAEA1-\uAEBB\uAEBD-\uAED7\uAED9-\uAEF3\uAEF5-\uAF0F\uAF11-\uAF2B\uAF2D-\uAF47\uAF49-\uAF63\uAF65-\uAF7F\uAF81-\uAF9B\uAF9D-\uAFB7\uAFB9-\uAFD3\uAFD5-\uAFEF\uAFF1-\uB00B\uB00D-\uB027\uB029-\uB043\uB045-\uB05F\uB061-\uB07B\uB07D-\uB097\uB099-\uB0B3\uB0B5-\uB0CF\uB0D1-\uB0EB\uB0ED-\uB107\uB109-\uB123\uB125-\uB13F\uB141-\uB15B\uB15D-\uB177\uB179-\uB193\uB195-\uB1AF\uB1B1-\uB1CB\uB1CD-\uB1E7\uB1E9-\uB203\uB205-\uB21F\uB221-\uB23B\uB23D-\uB257\uB259-\uB273\uB275-\uB28F\uB291-\uB2AB\uB2AD-\uB2C7\uB2C9-\uB2E3\uB2E5-\uB2FF\uB301-\uB31B\uB31D-\uB337\uB339-\uB353\uB355-\uB36F\uB371-\uB38B\uB38D-\uB3A7\uB3A9-\uB3C3\uB3C5-\uB3DF\uB3E1-\uB3FB\uB3FD-\uB417\uB419-\uB433\uB435-\uB44F\uB451-\uB46B\uB46D-\uB487\uB489-\uB4A3\uB4A5-\uB4BF\uB4C1-\uB4DB\uB4DD-\uB4F7\uB4F9-\uB513\uB515-\uB52F\uB531-\uB54B\uB54D-\uB567\uB569-\uB583\uB585-\uB59F\uB5A1-\uB5BB\uB5BD-\uB5D7\uB5D9-\uB5F3\uB5F5-\uB60F\uB611-\uB62B\uB62D-\uB647\uB649-\uB663\uB665-\uB67F\uB681-\uB69B\uB69D-\uB6B7\uB6B9-\uB6D3\uB6D5-\uB6EF\uB6F1-\uB70B\uB70D-\uB727\uB729-\uB743\uB745-\uB75F\uB761-\uB77B\uB77D-\uB797\uB799-\uB7B3\uB7B5-\uB7CF\uB7D1-\uB7EB\uB7ED-\uB807\uB809-\uB823\uB825-\uB83F\uB841-\uB85B\uB85D-\uB877\uB879-\uB893\uB895-\uB8AF\uB8B1-\uB8CB\uB8CD-\uB8E7\uB8E9-\uB903\uB905-\uB91F\uB921-\uB93B\uB93D-\uB957\uB959-\uB973\uB975-\uB98F\uB991-\uB9AB\uB9AD-\uB9C7\uB9C9-\uB9E3\uB9E5-\uB9FF\uBA01-\uBA1B\uBA1D-\uBA37\uBA39-\uBA53\uBA55-\uBA6F\uBA71-\uBA8B\uBA8D-\uBAA7\uBAA9-\uBAC3\uBAC5-\uBADF\uBAE1-\uBAFB\uBAFD-\uBB17\uBB19-\uBB33\uBB35-\uBB4F\uBB51-\uBB6B\uBB6D-\uBB87\uBB89-\uBBA3\uBBA5-\uBBBF\uBBC1-\uBBDB\uBBDD-\uBBF7\uBBF9-\uBC13\uBC15-\uBC2F\uBC31-\uBC4B\uBC4D-\uBC67\uBC69-\uBC83\uBC85-\uBC9F\uBCA1-\uBCBB\uBCBD-\uBCD7\uBCD9-\uBCF3\uBCF5-\uBD0F\uBD11-\uBD2B\uBD2D-\uBD47\uBD49-\uBD63\uBD65-\uBD7F\uBD81-\uBD9B\uBD9D-\uBDB7\uBDB9-\uBDD3\uBDD5-\uBDEF\uBDF1-\uBE0B\uBE0D-\uBE27\uBE29-\uBE43\uBE45-\uBE5F\uBE61-\uBE7B\uBE7D-\uBE97\uBE99-\uBEB3\uBEB5-\uBECF\uBED1-\uBEEB\uBEED-\uBF07\uBF09-\uBF23\uBF25-\uBF3F\uBF41-\uBF5B\uBF5D-\uBF77\uBF79-\uBF93\uBF95-\uBFAF\uBFB1-\uBFCB\uBFCD-\uBFE7\uBFE9-\uC003\uC005-\uC01F\uC021-\uC03B\uC03D-\uC057\uC059-\uC073\uC075-\uC08F\uC091-\uC0AB\uC0AD-\uC0C7\uC0C9-\uC0E3\uC0E5-\uC0FF\uC101-\uC11B\uC11D-\uC137\uC139-\uC153\uC155-\uC16F\uC171-\uC18B\uC18D-\uC1A7\uC1A9-\uC1C3\uC1C5-\uC1DF\uC1E1-\uC1FB\uC1FD-\uC217\uC219-\uC233\uC235-\uC24F\uC251-\uC26B\uC26D-\uC287\uC289-\uC2A3\uC2A5-\uC2BF\uC2C1-\uC2DB\uC2DD-\uC2F7\uC2F9-\uC313\uC315-\uC32F\uC331-\uC34B\uC34D-\uC367\uC369-\uC383\uC385-\uC39F\uC3A1-\uC3BB\uC3BD-\uC3D7\uC3D9-\uC3F3\uC3F5-\uC40F\uC411-\uC42B\uC42D-\uC447\uC449-\uC463\uC465-\uC47F\uC481-\uC49B\uC49D-\uC4B7\uC4B9-\uC4D3\uC4D5-\uC4EF\uC4F1-\uC50B\uC50D-\uC527\uC529-\uC543\uC545-\uC55F\uC561-\uC57B\uC57D-\uC597\uC599-\uC5B3\uC5B5-\uC5CF\uC5D1-\uC5EB\uC5ED-\uC607\uC609-\uC623\uC625-\uC63F\uC641-\uC65B\uC65D-\uC677\uC679-\uC693\uC695-\uC6AF\uC6B1-\uC6CB\uC6CD-\uC6E7\uC6E9-\uC703\uC705-\uC71F\uC721-\uC73B\uC73D-\uC757\uC759-\uC773\uC775-\uC78F\uC791-\uC7AB\uC7AD-\uC7C7\uC7C9-\uC7E3\uC7E5-\uC7FF\uC801-\uC81B\uC81D-\uC837\uC839-\uC853\uC855-\uC86F\uC871-\uC88B\uC88D-\uC8A7\uC8A9-\uC8C3\uC8C5-\uC8DF\uC8E1-\uC8FB\uC8FD-\uC917\uC919-\uC933\uC935-\uC94F\uC951-\uC96B\uC96D-\uC987\uC989-\uC9A3\uC9A5-\uC9BF\uC9C1-\uC9DB\uC9DD-\uC9F7\uC9F9-\uCA13\uCA15-\uCA2F\uCA31-\uCA4B\uCA4D-\uCA67\uCA69-\uCA83\uCA85-\uCA9F\uCAA1-\uCABB\uCABD-\uCAD7\uCAD9-\uCAF3\uCAF5-\uCB0F\uCB11-\uCB2B\uCB2D-\uCB47\uCB49-\uCB63\uCB65-\uCB7F\uCB81-\uCB9B\uCB9D-\uCBB7\uCBB9-\uCBD3\uCBD5-\uCBEF\uCBF1-\uCC0B\uCC0D-\uCC27\uCC29-\uCC43\uCC45-\uCC5F\uCC61-\uCC7B\uCC7D-\uCC97\uCC99-\uCCB3\uCCB5-\uCCCF\uCCD1-\uCCEB\uCCED-\uCD07\uCD09-\uCD23\uCD25-\uCD3F\uCD41-\uCD5B\uCD5D-\uCD77\uCD79-\uCD93\uCD95-\uCDAF\uCDB1-\uCDCB\uCDCD-\uCDE7\uCDE9-\uCE03\uCE05-\uCE1F\uCE21-\uCE3B\uCE3D-\uCE57\uCE59-\uCE73\uCE75-\uCE8F\uCE91-\uCEAB\uCEAD-\uCEC7\uCEC9-\uCEE3\uCEE5-\uCEFF\uCF01-\uCF1B\uCF1D-\uCF37\uCF39-\uCF53\uCF55-\uCF6F\uCF71-\uCF8B\uCF8D-\uCFA7\uCFA9-\uCFC3\uCFC5-\uCFDF\uCFE1-\uCFFB\uCFFD-\uD017\uD019-\uD033\uD035-\uD04F\uD051-\uD06B\uD06D-\uD087\uD089-\uD0A3\uD0A5-\uD0BF\uD0C1-\uD0DB\uD0DD-\uD0F7\uD0F9-\uD113\uD115-\uD12F\uD131-\uD14B\uD14D-\uD167\uD169-\uD183\uD185-\uD19F\uD1A1-\uD1BB\uD1BD-\uD1D7\uD1D9-\uD1F3\uD1F5-\uD20F\uD211-\uD22B\uD22D-\uD247\uD249-\uD263\uD265-\uD27F\uD281-\uD29B\uD29D-\uD2B7\uD2B9-\uD2D3\uD2D5-\uD2EF\uD2F1-\uD30B\uD30D-\uD327\uD329-\uD343\uD345-\uD35F\uD361-\uD37B\uD37D-\uD397\uD399-\uD3B3\uD3B5-\uD3CF\uD3D1-\uD3EB\uD3ED-\uD407\uD409-\uD423\uD425-\uD43F\uD441-\uD45B\uD45D-\uD477\uD479-\uD493\uD495-\uD4AF\uD4B1-\uD4CB\uD4CD-\uD4E7\uD4E9-\uD503\uD505-\uD51F\uD521-\uD53B\uD53D-\uD557\uD559-\uD573\uD575-\uD58F\uD591-\uD5AB\uD5AD-\uD5C7\uD5C9-\uD5E3\uD5E5-\uD5FF\uD601-\uD61B\uD61D-\uD637\uD639-\uD653\uD655-\uD66F\uD671-\uD68B\uD68D-\uD6A7\uD6A9-\uD6C3\uD6C5-\uD6DF\uD6E1-\uD6FB\uD6FD-\uD717\uD719-\uD733\uD735-\uD74F\uD751-\uD76B\uD76D-\uD787\uD789-\uD7A3]$/,NR=/^(?:[\xA9\xAE\u203C\u2049\u2122\u2139\u2194-\u2199\u21A9\u21AA\u231A\u231B\u2328\u2388\u23CF\u23E9-\u23F3\u23F8-\u23FA\u24C2\u25AA\u25AB\u25B6\u25C0\u25FB-\u25FE\u2600-\u2605\u2607-\u2612\u2614-\u2685\u2690-\u2705\u2708-\u2712\u2714\u2716\u271D\u2721\u2728\u2733\u2734\u2744\u2747\u274C\u274E\u2753-\u2755\u2757\u2763-\u2767\u2795-\u2797\u27A1\u27B0\u27BF\u2934\u2935\u2B05-\u2B07\u2B1B\u2B1C\u2B50\u2B55\u3030\u303D\u3297\u3299]|\uD83C[\uDC00-\uDCFF\uDD0D-\uDD0F\uDD2F\uDD6C-\uDD71\uDD7E\uDD7F\uDD8E\uDD91-\uDD9A\uDDAD-\uDDE5\uDE01-\uDE0F\uDE1A\uDE2F\uDE32-\uDE3A\uDE3C-\uDE3F\uDE49-\uDFFA]|\uD83D[\uDC00-\uDD3D\uDD46-\uDE4F\uDE80-\uDEFF\uDF74-\uDF7F\uDFD5-\uDFFF]|\uD83E[\uDC0C-\uDC0F\uDC48-\uDC4F\uDC5A-\uDC5F\uDC88-\uDC8F\uDCAE-\uDCFF\uDD0C-\uDD3A\uDD3C-\uDD45\uDD47-\uDEFF]|\uD83F[\uDC00-\uDFFD])$/,PR=(e,t)=>{var r=pR.Any;return-1!==e.search(AR)&&(r|=pR.Extend),8205===t&&(r|=pR.ZWJ),t>=127462&&t<=127487&&(r|=pR.RI),-1!==e.search(xR)&&(r|=pR.Prepend),-1!==e.search(BR)&&(r|=pR.SpacingMark),-1!==e.search(SR)&&(r|=pR.L),-1!==e.search(FR)&&(r|=pR.V),-1!==e.search(kR)&&(r|=pR.T),-1!==e.search(OR)&&(r|=pR.LV),-1!==e.search(TR)&&(r|=pR.LVT),-1!==e.search(NR)&&(r|=pR.ExtPict),r};function MR(e,t){return 0!==(e&t)}var IR=[[pR.L,pR.L|pR.V|pR.LV|pR.LVT],[pR.LV|pR.V,pR.V|pR.T],[pR.LVT|pR.T,pR.T],[pR.Any,pR.Extend|pR.ZWJ],[pR.Any,pR.SpacingMark],[pR.Prepend,pR.Any],[pR.ZWJ,pR.ExtPict],[pR.RI,pR.RI]];function RR(e,t){return-1===IR.findIndex(r=>MR(e,r[0])&&MR(t,r[1]))}var LR=/(?:[\xA9\xAE\u203C\u2049\u2122\u2139\u2194-\u2199\u21A9\u21AA\u231A\u231B\u2328\u2388\u23CF\u23E9-\u23F3\u23F8-\u23FA\u24C2\u25AA\u25AB\u25B6\u25C0\u25FB-\u25FE\u2600-\u2605\u2607-\u2612\u2614-\u2685\u2690-\u2705\u2708-\u2712\u2714\u2716\u271D\u2721\u2728\u2733\u2734\u2744\u2747\u274C\u274E\u2753-\u2755\u2757\u2763-\u2767\u2795-\u2797\u27A1\u27B0\u27BF\u2934\u2935\u2B05-\u2B07\u2B1B\u2B1C\u2B50\u2B55\u3030\u303D\u3297\u3299]|\uD83C[\uDC00-\uDCFF\uDD0D-\uDD0F\uDD2F\uDD6C-\uDD71\uDD7E\uDD7F\uDD8E\uDD91-\uDD9A\uDDAD-\uDDE5\uDE01-\uDE0F\uDE1A\uDE2F\uDE32-\uDE3A\uDE3C-\uDE3F\uDE49-\uDFFA]|\uD83D[\uDC00-\uDD3D\uDD46-\uDE4F\uDE80-\uDEFF\uDF74-\uDF7F\uDFD5-\uDFFF]|\uD83E[\uDC0C-\uDC0F\uDC48-\uDC4F\uDC5A-\uDC5F\uDC88-\uDC8F\uDCAE-\uDCFF\uDD0C-\uDD3A\uDD3C-\uDD45\uDD47-\uDEFF]|\uD83F[\uDC00-\uDFFD])(?:[\u0300-\u036F\u0483-\u0489\u0591-\u05BD\u05BF\u05C1\u05C2\u05C4\u05C5\u05C7\u0610-\u061A\u064B-\u065F\u0670\u06D6-\u06DC\u06DF-\u06E4\u06E7\u06E8\u06EA-\u06ED\u0711\u0730-\u074A\u07A6-\u07B0\u07EB-\u07F3\u07FD\u0816-\u0819\u081B-\u0823\u0825-\u0827\u0829-\u082D\u0859-\u085B\u08D3-\u08E1\u08E3-\u0902\u093A\u093C\u0941-\u0948\u094D\u0951-\u0957\u0962\u0963\u0981\u09BC\u09BE\u09C1-\u09C4\u09CD\u09D7\u09E2\u09E3\u09FE\u0A01\u0A02\u0A3C\u0A41\u0A42\u0A47\u0A48\u0A4B-\u0A4D\u0A51\u0A70\u0A71\u0A75\u0A81\u0A82\u0ABC\u0AC1-\u0AC5\u0AC7\u0AC8\u0ACD\u0AE2\u0AE3\u0AFA-\u0AFF\u0B01\u0B3C\u0B3E\u0B3F\u0B41-\u0B44\u0B4D\u0B55-\u0B57\u0B62\u0B63\u0B82\u0BBE\u0BC0\u0BCD\u0BD7\u0C00\u0C04\u0C3E-\u0C40\u0C46-\u0C48\u0C4A-\u0C4D\u0C55\u0C56\u0C62\u0C63\u0C81\u0CBC\u0CBF\u0CC2\u0CC6\u0CCC\u0CCD\u0CD5\u0CD6\u0CE2\u0CE3\u0D00\u0D01\u0D3B\u0D3C\u0D3E\u0D41-\u0D44\u0D4D\u0D57\u0D62\u0D63\u0D81\u0DCA\u0DCF\u0DD2-\u0DD4\u0DD6\u0DDF\u0E31\u0E34-\u0E3A\u0E47-\u0E4E\u0EB1\u0EB4-\u0EBC\u0EC8-\u0ECD\u0F18\u0F19\u0F35\u0F37\u0F39\u0F71-\u0F7E\u0F80-\u0F84\u0F86\u0F87\u0F8D-\u0F97\u0F99-\u0FBC\u0FC6\u102D-\u1030\u1032-\u1037\u1039\u103A\u103D\u103E\u1058\u1059\u105E-\u1060\u1071-\u1074\u1082\u1085\u1086\u108D\u109D\u135D-\u135F\u1712-\u1714\u1732-\u1734\u1752\u1753\u1772\u1773\u17B4\u17B5\u17B7-\u17BD\u17C6\u17C9-\u17D3\u17DD\u180B-\u180D\u1885\u1886\u18A9\u1920-\u1922\u1927\u1928\u1932\u1939-\u193B\u1A17\u1A18\u1A1B\u1A56\u1A58-\u1A5E\u1A60\u1A62\u1A65-\u1A6C\u1A73-\u1A7C\u1A7F\u1AB0-\u1AC0\u1B00-\u1B03\u1B34-\u1B3A\u1B3C\u1B42\u1B6B-\u1B73\u1B80\u1B81\u1BA2-\u1BA5\u1BA8\u1BA9\u1BAB-\u1BAD\u1BE6\u1BE8\u1BE9\u1BED\u1BEF-\u1BF1\u1C2C-\u1C33\u1C36\u1C37\u1CD0-\u1CD2\u1CD4-\u1CE0\u1CE2-\u1CE8\u1CED\u1CF4\u1CF8\u1CF9\u1DC0-\u1DF9\u1DFB-\u1DFF\u200C\u20D0-\u20F0\u2CEF-\u2CF1\u2D7F\u2DE0-\u2DFF\u302A-\u302F\u3099\u309A\uA66F-\uA672\uA674-\uA67D\uA69E\uA69F\uA6F0\uA6F1\uA802\uA806\uA80B\uA825\uA826\uA82C\uA8C4\uA8C5\uA8E0-\uA8F1\uA8FF\uA926-\uA92D\uA947-\uA951\uA980-\uA982\uA9B3\uA9B6-\uA9B9\uA9BC\uA9BD\uA9E5\uAA29-\uAA2E\uAA31\uAA32\uAA35\uAA36\uAA43\uAA4C\uAA7C\uAAB0\uAAB2-\uAAB4\uAAB7\uAAB8\uAABE\uAABF\uAAC1\uAAEC\uAAED\uAAF6\uABE5\uABE8\uABED\uFB1E\uFE00-\uFE0F\uFE20-\uFE2F\uFF9E\uFF9F]|\uD800[\uDDFD\uDEE0\uDF76-\uDF7A]|\uD802[\uDE01-\uDE03\uDE05\uDE06\uDE0C-\uDE0F\uDE38-\uDE3A\uDE3F\uDEE5\uDEE6]|\uD803[\uDD24-\uDD27\uDEAB\uDEAC\uDF46-\uDF50]|\uD804[\uDC01\uDC38-\uDC46\uDC7F-\uDC81\uDCB3-\uDCB6\uDCB9\uDCBA\uDD00-\uDD02\uDD27-\uDD2B\uDD2D-\uDD34\uDD73\uDD80\uDD81\uDDB6-\uDDBE\uDDC9-\uDDCC\uDDCF\uDE2F-\uDE31\uDE34\uDE36\uDE37\uDE3E\uDEDF\uDEE3-\uDEEA\uDF00\uDF01\uDF3B\uDF3C\uDF3E\uDF40\uDF57\uDF66-\uDF6C\uDF70-\uDF74]|\uD805[\uDC38-\uDC3F\uDC42-\uDC44\uDC46\uDC5E\uDCB0\uDCB3-\uDCB8\uDCBA\uDCBD\uDCBF\uDCC0\uDCC2\uDCC3\uDDAF\uDDB2-\uDDB5\uDDBC\uDDBD\uDDBF\uDDC0\uDDDC\uDDDD\uDE33-\uDE3A\uDE3D\uDE3F\uDE40\uDEAB\uDEAD\uDEB0-\uDEB5\uDEB7\uDF1D-\uDF1F\uDF22-\uDF25\uDF27-\uDF2B]|\uD806[\uDC2F-\uDC37\uDC39\uDC3A\uDD30\uDD3B\uDD3C\uDD3E\uDD43\uDDD4-\uDDD7\uDDDA\uDDDB\uDDE0\uDE01-\uDE0A\uDE33-\uDE38\uDE3B-\uDE3E\uDE47\uDE51-\uDE56\uDE59-\uDE5B\uDE8A-\uDE96\uDE98\uDE99]|\uD807[\uDC30-\uDC36\uDC38-\uDC3D\uDC3F\uDC92-\uDCA7\uDCAA-\uDCB0\uDCB2\uDCB3\uDCB5\uDCB6\uDD31-\uDD36\uDD3A\uDD3C\uDD3D\uDD3F-\uDD45\uDD47\uDD90\uDD91\uDD95\uDD97\uDEF3\uDEF4]|\uD81A[\uDEF0-\uDEF4\uDF30-\uDF36]|\uD81B[\uDF4F\uDF8F-\uDF92\uDFE4]|\uD82F[\uDC9D\uDC9E]|\uD834[\uDD65\uDD67-\uDD69\uDD6E-\uDD72\uDD7B-\uDD82\uDD85-\uDD8B\uDDAA-\uDDAD\uDE42-\uDE44]|\uD836[\uDE00-\uDE36\uDE3B-\uDE6C\uDE75\uDE84\uDE9B-\uDE9F\uDEA1-\uDEAF]|\uD838[\uDC00-\uDC06\uDC08-\uDC18\uDC1B-\uDC21\uDC23\uDC24\uDC26-\uDC2A\uDD30-\uDD36\uDEEC-\uDEEF]|\uD83A[\uDCD0-\uDCD6\uDD44-\uDD4A]|\uD83C[\uDFFB-\uDFFF]|\uDB40[\uDC20-\uDC7F\uDD00-\uDDEF])*\u200D$/,_R=e=>-1!==e.search(LR),zR=/(?:\uD83C[\uDDE6-\uDDFF])+$/g,jR=e=>{var t=e.match(zR);return null!==t&&t[0].length/2%2==1},HR=e=>sI(e)&&QR.isNodeList(e.children)&&!YR.isEditor(e),VR={isAncestor:e=>sI(e)&&QR.isNodeList(e.children),isElement:HR,isElementList:e=>Array.isArray(e)&&e.every(e=>VR.isElement(e)),isElementProps:e=>void 0!==e.children,isElementType:function(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"type";return HR(e)&&e[r]===t},matches(e,t){for(var r in t)if("children"!==r&&e[r]!==t[r])return!1;return!0}},$R=["text"],UR=["text"];function qR(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),r.push.apply(r,n)}return r}function WR(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?qR(Object(r),!0).forEach(function(t){aR(e,t,r[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):qR(Object(r)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))})}return e}var GR=new WeakMap,YR={above(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{voids:r=!1,mode:n="lowest",at:o=e.selection,match:i}=t;if(o){var a=YR.path(e,o),s="lowest"===n;for(var[u,l]of YR.levels(e,{at:a,voids:r,match:i,reverse:s}))if(!vL.isText(u)&&!nL.equals(a,l))return[u,l]}},addMark(e,t,r){e.addMark(t,r)},after(e,t){var r,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},o={anchor:YR.point(e,t,{edge:"end"}),focus:YR.end(e,[])},{distance:i=1}=n,a=0;for(var s of YR.positions(e,WR(WR({},n),{},{at:o}))){if(a>i)break;0!==a&&(r=s),a++}return r},before(e,t){var r,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},o={anchor:YR.start(e,[]),focus:YR.point(e,t,{edge:"start"})},{distance:i=1}=n,a=0;for(var s of YR.positions(e,WR(WR({},n),{},{at:o,reverse:!0}))){if(a>i)break;0!==a&&(r=s),a++}return r},deleteBackward(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{unit:r="character"}=t;e.deleteBackward(r)},deleteForward(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{unit:r="character"}=t;e.deleteForward(r)},deleteFragment(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{direction:r="forward"}=t;e.deleteFragment(r)},edges:(e,t)=>[YR.start(e,t),YR.end(e,t)],end:(e,t)=>YR.point(e,t,{edge:"end"}),first(e,t){var r=YR.path(e,t,{edge:"start"});return YR.node(e,r)},fragment(e,t){var r=YR.range(e,t);return QR.fragment(e,r)},hasBlocks:(e,t)=>t.children.some(t=>YR.isBlock(e,t)),hasInlines:(e,t)=>t.children.some(t=>vL.isText(t)||YR.isInline(e,t)),hasTexts:(e,t)=>t.children.every(e=>vL.isText(e)),insertBreak(e){e.insertBreak()},insertSoftBreak(e){e.insertSoftBreak()},insertFragment(e,t){e.insertFragment(t)},insertNode(e,t){e.insertNode(t)},insertText(e,t){e.insertText(t)},isBlock:(e,t)=>VR.isElement(t)&&!e.isInline(t),isEditor(e){var t=GR.get(e);if(void 0!==t)return t;if(!sI(e))return!1;var r="function"==typeof e.addMark&&"function"==typeof e.apply&&"function"==typeof e.deleteBackward&&"function"==typeof e.deleteForward&&"function"==typeof e.deleteFragment&&"function"==typeof e.insertBreak&&"function"==typeof e.insertSoftBreak&&"function"==typeof e.insertFragment&&"function"==typeof e.insertNode&&"function"==typeof e.insertText&&"function"==typeof e.isInline&&"function"==typeof e.isVoid&&"function"==typeof e.normalizeNode&&"function"==typeof e.onChange&&"function"==typeof e.removeMark&&"function"==typeof e.getDirtyPaths&&(null===e.marks||sI(e.marks))&&(null===e.selection||lL.isRange(e.selection))&&QR.isNodeList(e.children)&&rL.isOperationList(e.operations);return GR.set(e,r),r},isEnd(e,t,r){var n=YR.end(e,r);return aL.equals(t,n)},isEdge:(e,t,r)=>YR.isStart(e,t,r)||YR.isEnd(e,t,r),isEmpty(e,t){var{children:r}=t,[n]=r;return 0===r.length||1===r.length&&vL.isText(n)&&""===n.text&&!e.isVoid(t)},isInline:(e,t)=>VR.isElement(t)&&e.isInline(t),isNormalizing(e){var t=lR.get(e);return void 0===t||t},isStart(e,t,r){if(0!==t.offset)return!1;var n=YR.start(e,r);return aL.equals(t,n)},isVoid:(e,t)=>VR.isElement(t)&&e.isVoid(t),last(e,t){var r=YR.path(e,t,{edge:"end"});return YR.node(e,r)},leaf(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},n=YR.path(e,t,r);return[QR.leaf(e,n),n]},*levels(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{at:r=e.selection,reverse:n=!1,voids:o=!1}=t,{match:i}=t;if(null==i&&(i=()=>!0),r){var a=[],s=YR.path(e,r);for(var[u,l]of QR.levels(e,s))if(i(u,l)&&(a.push([u,l]),!o&&YR.isVoid(e,u)))break;n&&a.reverse(),yield*a}},marks(e){var{marks:t,selection:r}=e;if(!r)return null;if(t)return t;if(lL.isExpanded(r)){var[n]=YR.nodes(e,{match:vL.isText});if(n){var[o]=n;return fR(o,$R)}return{}}var{anchor:i}=r,{path:a}=i,[s]=YR.leaf(e,a);if(0===i.offset){var u=YR.previous(e,{at:a,match:vL.isText}),l=YR.above(e,{match:t=>YR.isBlock(e,t)});if(u&&l){var[c,d]=u,[,h]=l;nL.isAncestor(h,d)&&(s=c)}}return fR(s,UR)},next(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{mode:r="lowest",voids:n=!1}=t,{match:o,at:i=e.selection}=t;if(i){var a=YR.after(e,i,{voids:n});if(a){var[,s]=YR.last(e,[]),u=[a.path,s];if(nL.isPath(i)&&0===i.length)throw new Error("Cannot get the next node from the root node!");if(null==o)if(nL.isPath(i)){var[l]=YR.parent(e,i);o=e=>l.children.includes(e)}else o=()=>!0;var[c]=YR.nodes(e,{at:u,match:o,mode:r,voids:n});return c}}},node(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},n=YR.path(e,t,r);return[QR.get(e,n),n]},*nodes(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{at:r=e.selection,mode:n="all",universal:o=!1,reverse:i=!1,voids:a=!1}=t,{match:s}=t;if(s||(s=()=>!0),r){var u,l;if(KR.isSpan(r))u=r[0],l=r[1];else{var c=YR.path(e,r,{edge:"start"}),d=YR.path(e,r,{edge:"end"});u=i?d:c,l=i?c:d}var h,f=QR.nodes(e,{reverse:i,from:u,to:l,pass:t=>{var[r]=t;return!a&&YR.isVoid(e,r)}}),p=[];for(var[g,m]of f){var v=h&&0===nL.compare(m,h[1]);if("highest"!==n||!v)if(s(g,m))if("lowest"===n&&v)h=[g,m];else{var y="lowest"===n?h:[g,m];y&&(o?p.push(y):yield y),h=[g,m]}else if(o&&!v&&vL.isText(g))return}"lowest"===n&&h&&(o?p.push(h):yield h),o&&(yield*p)}},normalize(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{force:r=!1}=t,n=e=>sR.get(e)||[],o=e=>{var t=n(e).pop(),r=t.join(",");return(e=>uR.get(e)||new Set)(e).delete(r),t};if(YR.isNormalizing(e)){if(r){var i=Array.from(QR.nodes(e),e=>{var[,t]=e;return t}),a=new Set(i.map(e=>e.join(",")));sR.set(e,i),uR.set(e,a)}0!==n(e).length&&YR.withoutNormalizing(e,()=>{for(var t of n(e))if(QR.has(e,t)){var r=YR.node(e,t),[i,a]=r;VR.isElement(i)&&0===i.children.length&&e.normalizeNode(r)}for(var s=42*n(e).length,u=0;0!==n(e).length;){if(u>s)throw new Error("\n Could not completely normalize the editor after ".concat(s," iterations! This is usually due to incorrect normalization logic that leaves a node in an invalid state.\n "));var l=o(e);if(QR.has(e,l)){var c=YR.node(e,l);e.normalizeNode(c)}u++}})}},parent(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},n=YR.path(e,t,r),o=nL.parent(n);return YR.node(e,o)},path(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},{depth:n,edge:o}=r;if(nL.isPath(t))if("start"===o){var[,i]=QR.first(e,t);t=i}else if("end"===o){var[,a]=QR.last(e,t);t=a}return lL.isRange(t)&&(t="start"===o?lL.start(t):"end"===o?lL.end(t):nL.common(t.anchor.path,t.focus.path)),aL.isPoint(t)&&(t=t.path),null!=n&&(t=t.slice(0,n)),t},hasPath:(e,t)=>QR.has(e,t),pathRef(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},{affinity:n="forward"}=r,o={current:t,affinity:n,unref(){var{current:t}=o;return YR.pathRefs(e).delete(o),o.current=null,t}};return YR.pathRefs(e).add(o),o},pathRefs(e){var t=cR.get(e);return t||(t=new Set,cR.set(e,t)),t},point(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},{edge:n="start"}=r;if(nL.isPath(t)){var o;if("end"===n){var[,i]=QR.last(e,t);o=i}else{var[,a]=QR.first(e,t);o=a}var s=QR.get(e,o);if(!vL.isText(s))throw new Error("Cannot get the ".concat(n," point in the node at path [").concat(t,"] because it has no ").concat(n," text node."));return{path:o,offset:"end"===n?s.text.length:0}}if(lL.isRange(t)){var[u,l]=lL.edges(t);return"start"===n?u:l}return t},pointRef(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},{affinity:n="forward"}=r,o={current:t,affinity:n,unref(){var{current:t}=o;return YR.pointRefs(e).delete(o),o.current=null,t}};return YR.pointRefs(e).add(o),o},pointRefs(e){var t=dR.get(e);return t||(t=new Set,dR.set(e,t)),t},*positions(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{at:r=e.selection,unit:n="offset",reverse:o=!1,voids:i=!1}=t;if(r){var a=YR.range(e,r),[s,u]=lL.edges(a),l=o?u:s,c=!1,d="",h=0,f=0,p=0;for(var[g,m]of YR.nodes(e,{at:r,reverse:o,voids:i})){if(VR.isElement(g)){if(!i&&e.isVoid(g)){yield YR.start(e,m);continue}if(e.isInline(g))continue;if(YR.hasInlines(e,g)){var v=nL.isAncestor(m,u.path)?u:YR.end(e,m),y=nL.isAncestor(m,s.path)?s:YR.start(e,m);d=YR.string(e,{anchor:y,focus:v},{voids:i}),c=!0}}if(vL.isText(g)){var b=nL.equals(m,l.path);for(b?(f=o?l.offset:g.text.length-l.offset,p=l.offset):(f=g.text.length,p=o?f:0),(b||c||"offset"===n)&&(yield{path:m,offset:p},c=!1);;){if(0===h){if(""===d)break;h=D(d,n,o),d=bR(d,h,o)[1]}if(p=o?p-h:p+h,(f-=h)<0){h=-f;break}h=0,yield{path:m,offset:p}}}}}function D(e,t,r){return"character"===t?gR(e,r):"word"===t?function(e){for(var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1],r=0,n=!1;e.length>0;){var o=gR(e,t),[i,a]=bR(e,o,t);if(DR(i,a,t))n=!0,r+=o;else{if(n)break;r+=o}e=a}return r}(e,r):"line"===t||"block"===t?e.length:1}},previous(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{mode:r="lowest",voids:n=!1}=t,{match:o,at:i=e.selection}=t;if(i){var a=YR.before(e,i,{voids:n});if(a){var[,s]=YR.first(e,[]),u=[a.path,s];if(nL.isPath(i)&&0===i.length)throw new Error("Cannot get the previous node from the root node!");if(null==o)if(nL.isPath(i)){var[l]=YR.parent(e,i);o=e=>l.children.includes(e)}else o=()=>!0;var[c]=YR.nodes(e,{reverse:!0,at:u,match:o,mode:r,voids:n});return c}}},range:(e,t,r)=>lL.isRange(t)&&!r?t:{anchor:YR.start(e,t),focus:YR.end(e,r||t)},rangeRef(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},{affinity:n="forward"}=r,o={current:t,affinity:n,unref(){var{current:t}=o;return YR.rangeRefs(e).delete(o),o.current=null,t}};return YR.rangeRefs(e).add(o),o},rangeRefs(e){var t=hR.get(e);return t||(t=new Set,hR.set(e,t)),t},removeMark(e,t){e.removeMark(t)},setNormalizing(e,t){lR.set(e,t)},start:(e,t)=>YR.point(e,t,{edge:"start"}),string(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},{voids:n=!1}=r,o=YR.range(e,t),[i,a]=lL.edges(o),s="";for(var[u,l]of YR.nodes(e,{at:o,match:vL.isText,voids:n})){var c=u.text;nL.equals(l,a.path)&&(c=c.slice(0,a.offset)),nL.equals(l,i.path)&&(c=c.slice(i.offset)),s+=c}return s},unhangRange(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},{voids:n=!1}=r,[o,i]=lL.edges(t);if(0!==o.offset||0!==i.offset||lL.isCollapsed(t))return t;var a=YR.above(e,{at:i,match:t=>YR.isBlock(e,t)}),s=a?a[1]:[],u={anchor:YR.start(e,o),focus:i},l=!0;for(var[c,d]of YR.nodes(e,{at:u,match:vL.isText,reverse:!0,voids:n}))if(l)l=!1;else if(""!==c.text||nL.isBefore(d,s)){i={path:d,offset:c.text.length};break}return{anchor:o,focus:i}},void(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return YR.above(e,WR(WR({},t),{},{match:t=>YR.isVoid(e,t)}))},withoutNormalizing(e,t){var r=YR.isNormalizing(e);YR.setNormalizing(e,!1);try{t()}finally{YR.setNormalizing(e,r)}YR.normalize(e)}},KR={isSpan:e=>Array.isArray(e)&&2===e.length&&e.every(nL.isPath)},XR=["children"],ZR=["text"],JR=new WeakMap,QR={ancestor(e,t){var r=QR.get(e,t);if(vL.isText(r))throw new Error("Cannot get the ancestor node at path [".concat(t,"] because it refers to a text node instead: ").concat(dL.stringify(r)));return r},*ancestors(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};for(var n of nL.ancestors(t,r)){var o=[QR.ancestor(e,n),n];yield o}},child(e,t){if(vL.isText(e))throw new Error("Cannot get the child of a text node: ".concat(dL.stringify(e)));var r=e.children[t];if(null==r)throw new Error("Cannot get child at index `".concat(t,"` in node: ").concat(dL.stringify(e)));return r},*children(e,t){for(var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},{reverse:n=!1}=r,o=QR.ancestor(e,t),{children:i}=o,a=n?i.length-1:0;n?a>=0:a<i.length;){var s=QR.child(o,a),u=t.concat(a);yield[s,u],a=n?a-1:a+1}},common(e,t,r){var n=nL.common(t,r);return[QR.get(e,n),n]},descendant(e,t){var r=QR.get(e,t);if(YR.isEditor(r))throw new Error("Cannot get the descendant node at path [".concat(t,"] because it refers to the root editor node instead: ").concat(dL.stringify(r)));return r},*descendants(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};for(var[r,n]of QR.nodes(e,t))0!==n.length&&(yield[r,n])},*elements(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};for(var[r,n]of QR.nodes(e,t))VR.isElement(r)&&(yield[r,n])},extractProps:e=>VR.isAncestor(e)?fR(e,XR):fR(e,ZR),first(e,t){for(var r=t.slice(),n=QR.get(e,r);n&&!vL.isText(n)&&0!==n.children.length;)n=n.children[0],r.push(0);return[n,r]},fragment(e,t){if(vL.isText(e))throw new Error("Cannot get a fragment starting from a root text node: ".concat(dL.stringify(e)));var r=nR({children:e.children},e=>{var[r,n]=lL.edges(t),o=QR.nodes(e,{reverse:!0,pass:e=>{var[,r]=e;return!lL.includes(t,r)}});for(var[,i]of o){if(!lL.includes(t,i)){var a=QR.parent(e,i),s=i[i.length-1];a.children.splice(s,1)}if(nL.equals(i,n.path)){var u=QR.leaf(e,i);u.text=u.text.slice(0,n.offset)}if(nL.equals(i,r.path)){var l=QR.leaf(e,i);l.text=l.text.slice(r.offset)}}YR.isEditor(e)&&(e.selection=null)});return r.children},get(e,t){for(var r=e,n=0;n<t.length;n++){var o=t[n];if(vL.isText(r)||!r.children[o])throw new Error("Cannot find a descendant at path [".concat(t,"] in node: ").concat(dL.stringify(e)));r=r.children[o]}return r},has(e,t){for(var r=e,n=0;n<t.length;n++){var o=t[n];if(vL.isText(r)||!r.children[o])return!1;r=r.children[o]}return!0},isNode:e=>vL.isText(e)||VR.isElement(e)||YR.isEditor(e),isNodeList(e){if(!Array.isArray(e))return!1;var t=JR.get(e);if(void 0!==t)return t;var r=e.every(e=>QR.isNode(e));return JR.set(e,r),r},last(e,t){for(var r=t.slice(),n=QR.get(e,r);n&&!vL.isText(n)&&0!==n.children.length;){var o=n.children.length-1;n=n.children[o],r.push(o)}return[n,r]},leaf(e,t){var r=QR.get(e,t);if(!vL.isText(r))throw new Error("Cannot get the leaf node at path [".concat(t,"] because it refers to a non-leaf node: ").concat(dL.stringify(r)));return r},*levels(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};for(var n of nL.levels(t,r)){var o=QR.get(e,n);yield[o,n]}},matches:(e,t)=>VR.isElement(e)&&VR.isElementProps(t)&&VR.matches(e,t)||vL.isText(e)&&vL.isTextProps(t)&&vL.matches(e,t),*nodes(e){for(var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{pass:r,reverse:n=!1}=t,{from:o=[],to:i}=t,a=new Set,s=[],u=e;!i||!(n?nL.isBefore(s,i):nL.isAfter(s,i));)if(a.has(u)||(yield[u,s]),a.has(u)||vL.isText(u)||0===u.children.length||null!=r&&!1!==r([u,s])){if(0===s.length)break;if(!n){var l=nL.next(s);if(QR.has(e,l)){s=l,u=QR.get(e,s);continue}}if(n&&0!==s[s.length-1])s=nL.previous(s),u=QR.get(e,s);else s=nL.parent(s),u=QR.get(e,s),a.add(u)}else{a.add(u);var c=n?u.children.length-1:0;nL.isAncestor(s,o)&&(c=o[s.length]),s=s.concat(c),u=QR.get(e,s)}},parent(e,t){var r=nL.parent(t),n=QR.get(e,r);if(vL.isText(n))throw new Error("Cannot get the parent of path [".concat(t,"] because it does not exist in the root."));return n},string:e=>vL.isText(e)?e.text:e.children.map(QR.string).join(""),*texts(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};for(var[r,n]of QR.nodes(e,t))vL.isText(r)&&(yield[r,n])}};function eL(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),r.push.apply(r,n)}return r}function tL(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?eL(Object(r),!0).forEach(function(t){aR(e,t,r[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):eL(Object(r)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))})}return e}var rL={isNodeOperation:e=>rL.isOperation(e)&&e.type.endsWith("_node"),isOperation(e){if(!sI(e))return!1;switch(e.type){case"insert_node":case"remove_node":return nL.isPath(e.path)&&QR.isNode(e.node);case"insert_text":case"remove_text":return"number"==typeof e.offset&&"string"==typeof e.text&&nL.isPath(e.path);case"merge_node":return"number"==typeof e.position&&nL.isPath(e.path)&&sI(e.properties);case"move_node":return nL.isPath(e.path)&&nL.isPath(e.newPath);case"set_node":return nL.isPath(e.path)&&sI(e.properties)&&sI(e.newProperties);case"set_selection":return null===e.properties&&lL.isRange(e.newProperties)||null===e.newProperties&&lL.isRange(e.properties)||sI(e.properties)&&sI(e.newProperties);case"split_node":return nL.isPath(e.path)&&"number"==typeof e.position&&sI(e.properties);default:return!1}},isOperationList:e=>Array.isArray(e)&&e.every(e=>rL.isOperation(e)),isSelectionOperation:e=>rL.isOperation(e)&&e.type.endsWith("_selection"),isTextOperation:e=>rL.isOperation(e)&&e.type.endsWith("_text"),inverse(e){switch(e.type){case"insert_node":return tL(tL({},e),{},{type:"remove_node"});case"insert_text":return tL(tL({},e),{},{type:"remove_text"});case"merge_node":return tL(tL({},e),{},{type:"split_node",path:nL.previous(e.path)});case"move_node":var{newPath:t,path:r}=e;if(nL.equals(t,r))return e;if(nL.isSibling(r,t))return tL(tL({},e),{},{path:t,newPath:r});var n=nL.transform(r,e),o=nL.transform(nL.next(r),e);return tL(tL({},e),{},{path:n,newPath:o});case"remove_node":return tL(tL({},e),{},{type:"insert_node"});case"remove_text":return tL(tL({},e),{},{type:"insert_text"});case"set_node":var{properties:i,newProperties:a}=e;return tL(tL({},e),{},{properties:a,newProperties:i});case"set_selection":var{properties:s,newProperties:u}=e;return tL(tL({},e),{},null==s?{properties:u,newProperties:null}:null==u?{properties:null,newProperties:s}:{properties:u,newProperties:s});case"split_node":return tL(tL({},e),{},{type:"merge_node",path:nL.next(e.path)})}}},nL={ancestors(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{reverse:r=!1}=t,n=nL.levels(e,t);return n=r?n.slice(1):n.slice(0,-1)},common(e,t){for(var r=[],n=0;n<e.length&&n<t.length;n++){var o=e[n];if(o!==t[n])break;r.push(o)}return r},compare(e,t){for(var r=Math.min(e.length,t.length),n=0;n<r;n++){if(e[n]<t[n])return-1;if(e[n]>t[n])return 1}return 0},endsAfter(e,t){var r=e.length-1,n=e.slice(0,r),o=t.slice(0,r),i=e[r],a=t[r];return nL.equals(n,o)&&i>a},endsAt(e,t){var r=e.length,n=e.slice(0,r),o=t.slice(0,r);return nL.equals(n,o)},endsBefore(e,t){var r=e.length-1,n=e.slice(0,r),o=t.slice(0,r),i=e[r],a=t[r];return nL.equals(n,o)&&i<a},equals:(e,t)=>e.length===t.length&&e.every((e,r)=>e===t[r]),hasPrevious:e=>e[e.length-1]>0,isAfter:(e,t)=>1===nL.compare(e,t),isAncestor:(e,t)=>e.length<t.length&&0===nL.compare(e,t),isBefore:(e,t)=>-1===nL.compare(e,t),isChild:(e,t)=>e.length===t.length+1&&0===nL.compare(e,t),isCommon:(e,t)=>e.length<=t.length&&0===nL.compare(e,t),isDescendant:(e,t)=>e.length>t.length&&0===nL.compare(e,t),isParent:(e,t)=>e.length+1===t.length&&0===nL.compare(e,t),isPath:e=>Array.isArray(e)&&(0===e.length||"number"==typeof e[0]),isSibling(e,t){if(e.length!==t.length)return!1;var r=e.slice(0,-1),n=t.slice(0,-1);return e[e.length-1]!==t[t.length-1]&&nL.equals(r,n)},levels(e){for(var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{reverse:r=!1}=t,n=[],o=0;o<=e.length;o++)n.push(e.slice(0,o));return r&&n.reverse(),n},next(e){if(0===e.length)throw new Error("Cannot get the next path of a root path [".concat(e,"], because it has no next index."));var t=e[e.length-1];return e.slice(0,-1).concat(t+1)},operationCanTransformPath(e){switch(e.type){case"insert_node":case"remove_node":case"merge_node":case"split_node":case"move_node":return!0;default:return!1}},parent(e){if(0===e.length)throw new Error("Cannot get the parent path of the root path [".concat(e,"]."));return e.slice(0,-1)},previous(e){if(0===e.length)throw new Error("Cannot get the previous path of a root path [".concat(e,"], because it has no previous index."));var t=e[e.length-1];if(t<=0)throw new Error("Cannot get the previous path of a first child path [".concat(e,"] because it would result in a negative index."));return e.slice(0,-1).concat(t-1)},relative(e,t){if(!nL.isAncestor(t,e)&&!nL.equals(e,t))throw new Error("Cannot get the relative path of [".concat(e,"] inside ancestor [").concat(t,"], because it is not above or equal to the path."));return e.slice(t.length)},transform(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return nR(e,n=>{var{affinity:o="forward"}=r;if(e&&0!==(null==e?void 0:e.length)){if(null===n)return null;switch(t.type){case"insert_node":var{path:i}=t;(nL.equals(i,n)||nL.endsBefore(i,n)||nL.isAncestor(i,n))&&(n[i.length-1]+=1);break;case"remove_node":var{path:a}=t;if(nL.equals(a,n)||nL.isAncestor(a,n))return null;nL.endsBefore(a,n)&&(n[a.length-1]-=1);break;case"merge_node":var{path:s,position:u}=t;nL.equals(s,n)||nL.endsBefore(s,n)?n[s.length-1]-=1:nL.isAncestor(s,n)&&(n[s.length-1]-=1,n[s.length]+=u);break;case"split_node":var{path:l,position:c}=t;if(nL.equals(l,n)){if("forward"===o)n[n.length-1]+=1;else if("backward"!==o)return null}else nL.endsBefore(l,n)?n[l.length-1]+=1:nL.isAncestor(l,n)&&e[l.length]>=c&&(n[l.length-1]+=1,n[l.length]-=c);break;case"move_node":var{path:d,newPath:h}=t;if(nL.equals(d,h))return;if(nL.isAncestor(d,n)||nL.equals(d,n)){var f=h.slice();return nL.endsBefore(d,h)&&d.length<h.length&&(f[d.length-1]-=1),f.concat(n.slice(d.length))}nL.isSibling(d,h)&&(nL.isAncestor(h,n)||nL.equals(h,n))?nL.endsBefore(d,n)?n[d.length-1]-=1:n[d.length-1]+=1:nL.endsBefore(h,n)||nL.equals(h,n)||nL.isAncestor(h,n)?(nL.endsBefore(d,n)&&(n[d.length-1]-=1),n[h.length-1]+=1):nL.endsBefore(d,n)&&(nL.equals(h,n)&&(n[h.length-1]+=1),n[d.length-1]-=1)}}})}};function oL(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),r.push.apply(r,n)}return r}function iL(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?oL(Object(r),!0).forEach(function(t){aR(e,t,r[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):oL(Object(r)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))})}return e}var aL={compare(e,t){var r=nL.compare(e.path,t.path);return 0===r?e.offset<t.offset?-1:e.offset>t.offset?1:0:r},isAfter:(e,t)=>1===aL.compare(e,t),isBefore:(e,t)=>-1===aL.compare(e,t),equals:(e,t)=>e.offset===t.offset&&nL.equals(e.path,t.path),isPoint:e=>sI(e)&&"number"==typeof e.offset&&nL.isPath(e.path),transform(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return nR(e,e=>{if(null===e)return null;var{affinity:n="forward"}=r,{path:o,offset:i}=e;switch(t.type){case"insert_node":case"move_node":e.path=nL.transform(o,t,r);break;case"insert_text":nL.equals(t.path,o)&&(t.offset<i||t.offset===i&&"forward"===n)&&(e.offset+=t.text.length);break;case"merge_node":nL.equals(t.path,o)&&(e.offset+=t.position),e.path=nL.transform(o,t,r);break;case"remove_text":nL.equals(t.path,o)&&t.offset<=i&&(e.offset-=Math.min(i-t.offset,t.text.length));break;case"remove_node":if(nL.equals(t.path,o)||nL.isAncestor(t.path,o))return null;e.path=nL.transform(o,t,r);break;case"split_node":if(nL.equals(t.path,o)){if(t.position===i&&null==n)return null;(t.position<i||t.position===i&&"forward"===n)&&(e.offset-=t.position,e.path=nL.transform(o,t,iL(iL({},r),{},{affinity:"forward"})))}else e.path=nL.transform(o,t,r)}})}},sL=["anchor","focus"];function uL(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),r.push.apply(r,n)}return r}var lL={edges(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{reverse:r=!1}=t,{anchor:n,focus:o}=e;return lL.isBackward(e)===r?[n,o]:[o,n]},end(e){var[,t]=lL.edges(e);return t},equals:(e,t)=>aL.equals(e.anchor,t.anchor)&&aL.equals(e.focus,t.focus),includes(e,t){if(lL.isRange(t)){if(lL.includes(e,t.anchor)||lL.includes(e,t.focus))return!0;var[r,n]=lL.edges(e),[o,i]=lL.edges(t);return aL.isBefore(r,o)&&aL.isAfter(n,i)}var[a,s]=lL.edges(e),u=!1,l=!1;return aL.isPoint(t)?(u=aL.compare(t,a)>=0,l=aL.compare(t,s)<=0):(u=nL.compare(t,a.path)>=0,l=nL.compare(t,s.path)<=0),u&&l},intersection(e,t){var r=fR(e,sL),[n,o]=lL.edges(e),[i,a]=lL.edges(t),s=aL.isBefore(n,i)?i:n,u=aL.isBefore(o,a)?o:a;return aL.isBefore(u,s)?null:function(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?uL(Object(r),!0).forEach(function(t){aR(e,t,r[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):uL(Object(r)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))})}return e}({anchor:s,focus:u},r)},isBackward(e){var{anchor:t,focus:r}=e;return aL.isAfter(t,r)},isCollapsed(e){var{anchor:t,focus:r}=e;return aL.equals(t,r)},isExpanded:e=>!lL.isCollapsed(e),isForward:e=>!lL.isBackward(e),isRange:e=>sI(e)&&aL.isPoint(e.anchor)&&aL.isPoint(e.focus),*points(e){yield[e.anchor,"anchor"],yield[e.focus,"focus"]},start(e){var[t]=lL.edges(e);return t},transform(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return nR(e,e=>{if(null===e)return null;var n,o,{affinity:i="inward"}=r;if("inward"===i){var a=lL.isCollapsed(e);lL.isForward(e)?(n="forward",o=a?n:"backward"):(n="backward",o=a?n:"forward")}else"outward"===i?lL.isForward(e)?(n="backward",o="forward"):(n="forward",o="backward"):(n=i,o=i);var s=aL.transform(e.anchor,t,{affinity:n}),u=aL.transform(e.focus,t,{affinity:o});if(!s||!u)return null;e.anchor=s,e.focus=u})}},cL=void 0,dL={setScrubber(e){cL=e},stringify:e=>JSON.stringify(e,cL)},hL=(e,t)=>{for(var r in e){var n=e[r],o=t[r];if(sI(n)&&sI(o)){if(!hL(n,o))return!1}else if(Array.isArray(n)&&Array.isArray(o)){if(n.length!==o.length)return!1;for(var i=0;i<n.length;i++)if(n[i]!==o[i])return!1}else if(n!==o)return!1}for(var a in t)if(void 0===e[a]&&void 0!==t[a])return!1;return!0},fL=["text"],pL=["anchor","focus"];function gL(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),r.push.apply(r,n)}return r}function mL(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?gL(Object(r),!0).forEach(function(t){aR(e,t,r[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):gL(Object(r)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))})}return e}var vL={equals(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},{loose:n=!1}=r;function o(e){return fR(e,fL)}return hL(n?o(e):e,n?o(t):t)},isText:e=>sI(e)&&"string"==typeof e.text,isTextList:e=>Array.isArray(e)&&e.every(e=>vL.isText(e)),isTextProps:e=>void 0!==e.text,matches(e,t){for(var r in t)if("text"!==r&&(!e.hasOwnProperty(r)||e[r]!==t[r]))return!1;return!0},decorations(e,t){var r=[mL({},e)];for(var n of t){var o=fR(n,pL),[i,a]=lL.edges(n),s=[],u=0,l=i.offset,c=a.offset;for(var d of r){var{length:h}=d.text,f=u;if(u+=h,l<=f&&u<=c)Object.assign(d,o),s.push(d);else if(l!==c&&(l===u||c===f)||l>u||c<f||c===f&&0!==f)s.push(d);else{var p=d,g=void 0,m=void 0;if(c<u){var v=c-f;m=mL(mL({},p),{},{text:p.text.slice(v)}),p=mL(mL({},p),{},{text:p.text.slice(0,v)})}if(l>f){var y=l-f;g=mL(mL({},p),{},{text:p.text.slice(0,y)}),p=mL(mL({},p),{},{text:p.text.slice(y)})}Object.assign(p,o),g&&s.push(g),s.push(p),m&&s.push(m)}}r=s}return r}};function yL(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),r.push.apply(r,n)}return r}function bL(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?yL(Object(r),!0).forEach(function(t){aR(e,t,r[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):yL(Object(r)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))})}return e}var DL={transform(e,t){e.children=oR(e.children);var r=e.selection&&oR(e.selection);try{r=((e,t,r)=>{switch(r.type){case"insert_node":var{path:n,node:o}=r,i=QR.parent(e,n),a=n[n.length-1];if(a>i.children.length)throw new Error('Cannot apply an "insert_node" operation at path ['.concat(n,"] because the destination is past the end of the node."));if(i.children.splice(a,0,o),t)for(var[s,u]of lL.points(t))t[u]=aL.transform(s,r);break;case"insert_text":var{path:l,offset:c,text:d}=r;if(0===d.length)break;var h=QR.leaf(e,l),f=h.text.slice(0,c),p=h.text.slice(c);if(h.text=f+d+p,t)for(var[g,m]of lL.points(t))t[m]=aL.transform(g,r);break;case"merge_node":var{path:v}=r,y=QR.get(e,v),b=nL.previous(v),D=QR.get(e,b),C=QR.parent(e,v),w=v[v.length-1];if(vL.isText(y)&&vL.isText(D))D.text+=y.text;else{if(vL.isText(y)||vL.isText(D))throw new Error('Cannot apply a "merge_node" operation at path ['.concat(v,"] to nodes of different interfaces: ").concat(dL.stringify(y)," ").concat(dL.stringify(D)));D.children.push(...y.children)}if(C.children.splice(w,1),t)for(var[E,A]of lL.points(t))t[A]=aL.transform(E,r);break;case"move_node":var{path:x,newPath:B}=r;if(nL.isAncestor(x,B))throw new Error("Cannot move a path [".concat(x,"] to new path [").concat(B,"] because the destination is inside itself."));var S=QR.get(e,x),F=QR.parent(e,x),k=x[x.length-1];F.children.splice(k,1);var O=nL.transform(x,r),T=QR.get(e,nL.parent(O)),N=O[O.length-1];if(T.children.splice(N,0,S),t)for(var[P,M]of lL.points(t))t[M]=aL.transform(P,r);break;case"remove_node":var{path:I}=r,R=I[I.length-1];if(QR.parent(e,I).children.splice(R,1),t)for(var[L,_]of lL.points(t)){var z=aL.transform(L,r);if(null!=t&&null!=z)t[_]=z;else{var j=void 0,H=void 0;for(var[V,$]of QR.texts(e)){if(-1!==nL.compare($,I)){H=[V,$];break}j=[V,$]}var U=!1;j&&H&&(U=nL.equals(H[1],I)?!nL.hasPrevious(H[1]):nL.common(j[1],I).length<nL.common(H[1],I).length),j&&!U?(L.path=j[1],L.offset=j[0].text.length):H?(L.path=H[1],L.offset=0):t=null}}break;case"remove_text":var{path:q,offset:W,text:G}=r;if(0===G.length)break;var Y=QR.leaf(e,q),K=Y.text.slice(0,W),X=Y.text.slice(W+G.length);if(Y.text=K+X,t)for(var[Z,J]of lL.points(t))t[J]=aL.transform(Z,r);break;case"set_node":var{path:Q,properties:ee,newProperties:te}=r;if(0===Q.length)throw new Error("Cannot set properties on the root node!");var re=QR.get(e,Q);for(var ne in te){if("children"===ne||"text"===ne)throw new Error('Cannot set the "'.concat(ne,'" property of nodes!'));var oe=te[ne];null==oe?delete re[ne]:re[ne]=oe}for(var ie in ee)te.hasOwnProperty(ie)||delete re[ie];break;case"set_selection":var{newProperties:ae}=r;if(null==ae)t=ae;else{if(null==t){if(!lL.isRange(ae))throw new Error('Cannot apply an incomplete "set_selection" operation properties '.concat(dL.stringify(ae)," when there is no current selection."));t=bL({},ae)}for(var se in ae){var ue=ae[se];if(null==ue){if("anchor"===se||"focus"===se)throw new Error('Cannot remove the "'.concat(se,'" selection property'));delete t[se]}else t[se]=ue}}break;case"split_node":var{path:le,position:ce,properties:de}=r;if(0===le.length)throw new Error('Cannot apply a "split_node" operation at path ['.concat(le,"] because the root node cannot be split."));var he,fe=QR.get(e,le),pe=QR.parent(e,le),ge=le[le.length-1];if(vL.isText(fe)){var me=fe.text.slice(0,ce),ve=fe.text.slice(ce);fe.text=me,he=bL(bL({},de),{},{text:ve})}else{var ye=fe.children.slice(0,ce),be=fe.children.slice(ce);fe.children=ye,he=bL(bL({},de),{},{children:be})}if(pe.children.splice(ge+1,0,he),t)for(var[De,Ce]of lL.points(t))t[Ce]=aL.transform(De,r)}return t})(e,r,t)}finally{e.children=iR(e.children),e.selection=r?lI(r)?iR(r):r:null}}},CL=["text"],wL=["children"];function EL(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),r.push.apply(r,n)}return r}function AL(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?EL(Object(r),!0).forEach(function(t){aR(e,t,r[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):EL(Object(r)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))})}return e}var xL={insertNodes(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};YR.withoutNormalizing(e,()=>{var{hanging:n=!1,voids:o=!1,mode:i="lowest"}=r,{at:a,match:s,select:u}=r;if(QR.isNode(t)&&(t=[t]),0!==t.length){var[l]=t;if(a||(a=e.selection?e.selection:e.children.length>0?YR.end(e,[]):[0],u=!0),null==u&&(u=!1),lL.isRange(a))if(n||(a=YR.unhangRange(e,a)),lL.isCollapsed(a))a=a.anchor;else{var[,c]=lL.edges(a),d=YR.pointRef(e,c);IL.delete(e,{at:a}),a=d.unref()}if(aL.isPoint(a)){null==s&&(s=vL.isText(l)?e=>vL.isText(e):e.isInline(l)?t=>vL.isText(t)||YR.isInline(e,t):t=>YR.isBlock(e,t));var[h]=YR.nodes(e,{at:a.path,match:s,mode:i,voids:o});if(!h)return;var[,f]=h,p=YR.pathRef(e,f),g=YR.isEnd(e,a,f);IL.splitNodes(e,{at:a,match:s,mode:i,voids:o});var m=p.unref();a=g?nL.next(m):m}var v=nL.parent(a),y=a[a.length-1];if(o||!YR.void(e,{at:v})){for(var b of t){var D=v.concat(y);y++,e.apply({type:"insert_node",path:D,node:b}),a=nL.next(a)}if(a=nL.previous(a),u){var C=YR.end(e,a);C&&IL.select(e,C)}}}})},liftNodes(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};YR.withoutNormalizing(e,()=>{var{at:r=e.selection,mode:n="lowest",voids:o=!1}=t,{match:i}=t;if(null==i&&(i=nL.isPath(r)?FL(e,r):t=>YR.isBlock(e,t)),r){var a=YR.nodes(e,{at:r,match:i,mode:n,voids:o}),s=Array.from(a,t=>{var[,r]=t;return YR.pathRef(e,r)});for(var u of s){var l=u.unref();if(l.length<2)throw new Error("Cannot lift node at a path [".concat(l,"] because it has a depth of less than `2`."));var c=YR.node(e,nL.parent(l)),[d,h]=c,f=l[l.length-1],{length:p}=d.children;if(1===p){var g=nL.next(h);IL.moveNodes(e,{at:l,to:g,voids:o}),IL.removeNodes(e,{at:h,voids:o})}else if(0===f)IL.moveNodes(e,{at:l,to:h,voids:o});else if(f===p-1){var m=nL.next(h);IL.moveNodes(e,{at:l,to:m,voids:o})}else{var v=nL.next(l),y=nL.next(h);IL.splitNodes(e,{at:v,voids:o}),IL.moveNodes(e,{at:l,to:y,voids:o})}}}})},mergeNodes(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};YR.withoutNormalizing(e,()=>{var{match:r,at:n=e.selection}=t,{hanging:o=!1,voids:i=!1,mode:a="lowest"}=t;if(n){if(null==r)if(nL.isPath(n)){var[s]=YR.parent(e,n);r=e=>s.children.includes(e)}else r=t=>YR.isBlock(e,t);if(!o&&lL.isRange(n)&&(n=YR.unhangRange(e,n)),lL.isRange(n))if(lL.isCollapsed(n))n=n.anchor;else{var[,u]=lL.edges(n),l=YR.pointRef(e,u);IL.delete(e,{at:n}),n=l.unref(),null==t.at&&IL.select(e,n)}var[c]=YR.nodes(e,{at:n,match:r,voids:i,mode:a}),d=YR.previous(e,{at:n,match:r,voids:i,mode:a});if(c&&d){var[h,f]=c,[p,g]=d;if(0!==f.length&&0!==g.length){var m,v,y=nL.next(g),b=nL.common(f,g),D=nL.isSibling(f,g),C=Array.from(YR.levels(e,{at:f}),e=>{var[t]=e;return t}).slice(b.length).slice(0,-1),w=YR.above(e,{at:f,mode:"highest",match:t=>C.includes(t)&&BL(e,t)}),E=w&&YR.pathRef(e,w[1]);if(vL.isText(h)&&vL.isText(p)){var A=fR(h,CL);v=p.text.length,m=A}else{if(!VR.isElement(h)||!VR.isElement(p))throw new Error("Cannot merge the node at path [".concat(f,"] with the previous sibling because it is not the same kind: ").concat(dL.stringify(h)," ").concat(dL.stringify(p)));A=fR(h,wL);v=p.children.length,m=A}D||IL.moveNodes(e,{at:f,to:y,voids:i}),E&&IL.removeNodes(e,{at:E.current,voids:i}),VR.isElement(p)&&YR.isEmpty(e,p)||vL.isText(p)&&""===p.text&&0!==g[g.length-1]?IL.removeNodes(e,{at:g,voids:i}):e.apply({type:"merge_node",path:y,position:v,properties:m}),E&&E.unref()}}}})},moveNodes(e,t){YR.withoutNormalizing(e,()=>{var{to:r,at:n=e.selection,mode:o="lowest",voids:i=!1}=t,{match:a}=t;if(n){null==a&&(a=nL.isPath(n)?FL(e,n):t=>YR.isBlock(e,t));var s=YR.pathRef(e,r),u=YR.nodes(e,{at:n,match:a,mode:o,voids:i}),l=Array.from(u,t=>{var[,r]=t;return YR.pathRef(e,r)});for(var c of l){var d=c.unref(),h=s.current;0!==d.length&&e.apply({type:"move_node",path:d,newPath:h}),s.current&&nL.isSibling(h,d)&&nL.isAfter(h,d)&&(s.current=nL.next(s.current))}s.unref()}})},removeNodes(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};YR.withoutNormalizing(e,()=>{var{hanging:r=!1,voids:n=!1,mode:o="lowest"}=t,{at:i=e.selection,match:a}=t;if(i){null==a&&(a=nL.isPath(i)?FL(e,i):t=>YR.isBlock(e,t)),!r&&lL.isRange(i)&&(i=YR.unhangRange(e,i));var s=YR.nodes(e,{at:i,match:a,mode:o,voids:n}),u=Array.from(s,t=>{var[,r]=t;return YR.pathRef(e,r)});for(var l of u){var c=l.unref();if(c){var[d]=YR.node(e,c);e.apply({type:"remove_node",path:c,node:d})}}}})},setNodes(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};YR.withoutNormalizing(e,()=>{var{match:n,at:o=e.selection,compare:i,merge:a}=r,{hanging:s=!1,mode:u="lowest",split:l=!1,voids:c=!1}=r;if(o){if(null==n&&(n=nL.isPath(o)?FL(e,o):t=>YR.isBlock(e,t)),!s&&lL.isRange(o)&&(o=YR.unhangRange(e,o)),l&&lL.isRange(o)){if(lL.isCollapsed(o)&&YR.leaf(e,o.anchor)[0].text.length>0)return;var d=YR.rangeRef(e,o,{affinity:"inward"}),[h,f]=lL.edges(o),p="lowest"===u?"lowest":"highest",g=YR.isEnd(e,f,f.path);IL.splitNodes(e,{at:f,match:n,mode:p,voids:c,always:!g});var m=YR.isStart(e,h,h.path);IL.splitNodes(e,{at:h,match:n,mode:p,voids:c,always:!m}),o=d.unref(),null==r.at&&IL.select(e,o)}for(var[v,y]of(i||(i=(e,t)=>e!==t),YR.nodes(e,{at:o,match:n,mode:u,voids:c}))){var b={},D={};if(0!==y.length){var C=!1;for(var w in t)"children"!==w&&"text"!==w&&i(t[w],v[w])&&(C=!0,v.hasOwnProperty(w)&&(b[w]=v[w]),a?null!=t[w]&&(D[w]=a(v[w],t[w])):null!=t[w]&&(D[w]=t[w]));C&&e.apply({type:"set_node",path:y,properties:b,newProperties:D})}}}})},splitNodes(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};YR.withoutNormalizing(e,()=>{var{mode:r="lowest",voids:n=!1}=t,{match:o,at:i=e.selection,height:a=0,always:s=!1}=t;if(null==o&&(o=t=>YR.isBlock(e,t)),lL.isRange(i)&&(i=SL(e,i)),nL.isPath(i)){var u=i,l=YR.point(e,u),[c]=YR.parent(e,u);o=e=>e===c,a=l.path.length-u.length+1,i=l,s=!0}if(i){var d,h=YR.pointRef(e,i,{affinity:"backward"});try{var[f]=YR.nodes(e,{at:i,match:o,mode:r,voids:n});if(!f)return;var p=YR.void(e,{at:i,mode:"highest"});if(!n&&p){var[g,m]=p;if(VR.isElement(g)&&e.isInline(g)){var v=YR.after(e,m);if(!v){var y=nL.next(m);IL.insertNodes(e,{text:""},{at:y,voids:n}),v=YR.point(e,y)}i=v,s=!0}a=i.path.length-m.length+1,s=!0}d=YR.pointRef(e,i);var b=i.path.length-a,[,D]=f,C=i.path.slice(0,b),w=0===a?i.offset:i.path[b]+0;for(var[E,A]of YR.levels(e,{at:C,reverse:!0,voids:n})){var x=!1;if(A.length<D.length||0===A.length||!n&&YR.isVoid(e,E))break;var B=h.current,S=YR.isEnd(e,B,A);if(s||!h||!YR.isEdge(e,B,A)){x=!0;var F=QR.extractProps(E);e.apply({type:"split_node",path:A,position:w,properties:F})}w=A[A.length-1]+(x||S?1:0)}if(null==t.at){var k=d.current||YR.end(e,[]);IL.select(e,k)}}finally{var O;h.unref(),null===(O=d)||void 0===O||O.unref()}}})},unsetNodes(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};Array.isArray(t)||(t=[t]);var n={};for(var o of t)n[o]=null;IL.setNodes(e,n,r)},unwrapNodes(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};YR.withoutNormalizing(e,()=>{var{mode:r="lowest",split:n=!1,voids:o=!1}=t,{at:i=e.selection,match:a}=t;if(i){null==a&&(a=nL.isPath(i)?FL(e,i):t=>YR.isBlock(e,t)),nL.isPath(i)&&(i=YR.range(e,i));var s=lL.isRange(i)?YR.rangeRef(e,i):null,u=YR.nodes(e,{at:i,match:a,mode:r,voids:o}),l=Array.from(u,t=>{var[,r]=t;return YR.pathRef(e,r)}).reverse(),c=function(t){var r=t.unref(),[i]=YR.node(e,r),a=YR.range(e,r);n&&s&&(a=lL.intersection(s.current,a)),IL.liftNodes(e,{at:a,match:e=>VR.isAncestor(i)&&i.children.includes(e),voids:o})};for(var d of l)c(d);s&&s.unref()}})},wrapNodes(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};YR.withoutNormalizing(e,()=>{var{mode:n="lowest",split:o=!1,voids:i=!1}=r,{match:a,at:s=e.selection}=r;if(s){if(null==a&&(a=nL.isPath(s)?FL(e,s):e.isInline(t)?t=>YR.isInline(e,t)||vL.isText(t):t=>YR.isBlock(e,t)),o&&lL.isRange(s)){var[u,l]=lL.edges(s),c=YR.rangeRef(e,s,{affinity:"inward"});IL.splitNodes(e,{at:l,match:a,voids:i}),IL.splitNodes(e,{at:u,match:a,voids:i}),s=c.unref(),null==r.at&&IL.select(e,s)}var d=Array.from(YR.nodes(e,{at:s,match:e.isInline(t)?t=>YR.isBlock(e,t):e=>YR.isEditor(e),mode:"lowest",voids:i}));for(var[,h]of d){var f=lL.isRange(s)?lL.intersection(s,YR.range(e,h)):s;if(f){var p=Array.from(YR.nodes(e,{at:f,match:a,mode:n,voids:i}));if(p.length>0){var g=function(){var[r]=p,n=p[p.length-1],[,o]=r,[,a]=n;if(0===o.length&&0===a.length)return"continue";var s=nL.equals(o,a)?nL.parent(o):nL.common(o,a),u=YR.range(e,o,a),l=YR.node(e,s),[c]=l,d=s.length+1,h=nL.next(a.slice(0,d)),f=AL(AL({},t),{},{children:[]});IL.insertNodes(e,f,{at:h,voids:i}),IL.moveNodes(e,{at:u,match:e=>VR.isAncestor(c)&&c.children.includes(e),to:h.concat(0),voids:i})}();if("continue"===g)continue}}}}})}},BL=(e,t)=>{if(VR.isElement(t)){var r=t;return!!YR.isVoid(e,t)||1===r.children.length&&BL(e,r.children[0])}return!YR.isEditor(t)},SL=(e,t)=>{if(lL.isCollapsed(t))return t.anchor;var[,r]=lL.edges(t),n=YR.pointRef(e,r);return IL.delete(e,{at:t}),n.unref()},FL=(e,t)=>{var[r]=YR.node(e,t);return e=>e===r};function kL(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),r.push.apply(r,n)}return r}function OL(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?kL(Object(r),!0).forEach(function(t){aR(e,t,r[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):kL(Object(r)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))})}return e}var TL={collapse(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{edge:r="anchor"}=t,{selection:n}=e;if(n)if("anchor"===r)IL.select(e,n.anchor);else if("focus"===r)IL.select(e,n.focus);else if("start"===r){var[o]=lL.edges(n);IL.select(e,o)}else if("end"===r){var[,i]=lL.edges(n);IL.select(e,i)}},deselect(e){var{selection:t}=e;t&&e.apply({type:"set_selection",properties:t,newProperties:null})},move(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},{selection:r}=e,{distance:n=1,unit:o="character",reverse:i=!1}=t,{edge:a=null}=t;if(r){"start"===a&&(a=lL.isBackward(r)?"focus":"anchor"),"end"===a&&(a=lL.isBackward(r)?"anchor":"focus");var{anchor:s,focus:u}=r,l={distance:n,unit:o},c={};if(null==a||"anchor"===a){var d=i?YR.before(e,s,l):YR.after(e,s,l);d&&(c.anchor=d)}if(null==a||"focus"===a){var h=i?YR.before(e,u,l):YR.after(e,u,l);h&&(c.focus=h)}IL.setSelection(e,c)}},select(e,t){var{selection:r}=e;if(t=YR.range(e,t),r)IL.setSelection(e,t);else{if(!lL.isRange(t))throw new Error("When setting the selection and the current selection is `null` you must provide at least an `anchor` and `focus`, but you passed: ".concat(dL.stringify(t)));e.apply({type:"set_selection",properties:r,newProperties:t})}},setPoint(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},{selection:n}=e,{edge:o="both"}=r;if(n){"start"===o&&(o=lL.isBackward(n)?"focus":"anchor"),"end"===o&&(o=lL.isBackward(n)?"anchor":"focus");var{anchor:i,focus:a}=n,s="anchor"===o?i:a;IL.setSelection(e,{["anchor"===o?"anchor":"focus"]:OL(OL({},s),t)})}},setSelection(e,t){var{selection:r}=e,n={},o={};if(r){for(var i in t)("anchor"===i&&null!=t.anchor&&!aL.equals(t.anchor,r.anchor)||"focus"===i&&null!=t.focus&&!aL.equals(t.focus,r.focus)||"anchor"!==i&&"focus"!==i&&t[i]!==r[i])&&(n[i]=r[i],o[i]=t[i]);Object.keys(n).length>0&&e.apply({type:"set_selection",properties:n,newProperties:o})}}},NL={delete(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};YR.withoutNormalizing(e,()=>{var{reverse:r=!1,unit:n="character",distance:o=1,voids:i=!1}=t,{at:a=e.selection,hanging:s=!1}=t;if(a){var u=!1;if(lL.isRange(a)&&lL.isCollapsed(a)&&(u=!0,a=a.anchor),aL.isPoint(a)){var l=YR.void(e,{at:a,mode:"highest"});if(!i&&l){var[,c]=l;a=c}else{var d={unit:n,distance:o};a={anchor:a,focus:r?YR.before(e,a,d)||YR.start(e,[]):YR.after(e,a,d)||YR.end(e,[])},s=!0}}if(nL.isPath(a))IL.removeNodes(e,{at:a,voids:i});else if(!lL.isCollapsed(a)){if(!s){var[,h]=lL.edges(a),f=YR.end(e,[]);aL.equals(h,f)||(a=YR.unhangRange(e,a,{voids:i}))}var[p,g]=lL.edges(a),m=YR.above(e,{match:t=>YR.isBlock(e,t),at:p,voids:i}),v=YR.above(e,{match:t=>YR.isBlock(e,t),at:g,voids:i}),y=m&&v&&!nL.equals(m[1],v[1]),b=nL.equals(p.path,g.path),D=i?null:YR.void(e,{at:p,mode:"highest"}),C=i?null:YR.void(e,{at:g,mode:"highest"});if(D){var w=YR.before(e,p);w&&m&&nL.isAncestor(m[1],w.path)&&(p=w)}if(C){var E=YR.after(e,g);E&&v&&nL.isAncestor(v[1],E.path)&&(g=E)}var A,x=[];for(var B of YR.nodes(e,{at:a,voids:i})){var[S,F]=B;A&&0===nL.compare(F,A)||(!i&&YR.isVoid(e,S)||!nL.isCommon(F,p.path)&&!nL.isCommon(F,g.path))&&(x.push(B),A=F)}var k=Array.from(x,t=>{var[,r]=t;return YR.pathRef(e,r)}),O=YR.pointRef(e,p),T=YR.pointRef(e,g),N="";if(!b&&!D){var P=O.current,[M]=YR.leaf(e,P),{path:I}=P,{offset:R}=p,L=M.text.slice(R);L.length>0&&(e.apply({type:"remove_text",path:I,offset:R,text:L}),N=L)}for(var _ of k){var z=_.unref();IL.removeNodes(e,{at:z,voids:i})}if(!C){var j=T.current,[H]=YR.leaf(e,j),{path:V}=j,$=b?p.offset:0,U=H.text.slice($,g.offset);U.length>0&&(e.apply({type:"remove_text",path:V,offset:$,text:U}),N=U)}!b&&y&&T.current&&O.current&&IL.mergeNodes(e,{at:T.current,hanging:!0,voids:i}),u&&r&&"character"===n&&N.length>1&&N.match(/[\u0E00-\u0E7F]+/)&&IL.insertText(e,N.slice(0,N.length-o));var q=O.unref(),W=T.unref(),G=r?q||W:W||q;null==t.at&&G&&IL.select(e,G)}}})},insertFragment(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};YR.withoutNormalizing(e,()=>{var{hanging:n=!1,voids:o=!1}=r,{at:i=e.selection}=r;if(t.length&&i){if(lL.isRange(i))if(n||(i=YR.unhangRange(e,i)),lL.isCollapsed(i))i=i.anchor;else{var[,a]=lL.edges(i);if(!o&&YR.void(e,{at:a}))return;var s=YR.pointRef(e,a);IL.delete(e,{at:i}),i=s.unref()}else nL.isPath(i)&&(i=YR.start(e,i));if(o||!YR.void(e,{at:i})){var u=YR.above(e,{at:i,match:t=>YR.isInline(e,t),mode:"highest",voids:o});if(u){var[,l]=u;if(YR.isEnd(e,i,l))i=YR.after(e,l);else if(YR.isStart(e,i,l)){i=YR.before(e,l)}}var c=YR.above(e,{match:t=>YR.isBlock(e,t),at:i,voids:o}),[,d]=c,h=YR.isStart(e,i,d),f=YR.isEnd(e,i,d),p=h&&f,g=!h||h&&f,m=!f,[,v]=QR.first({children:t},[]),[,y]=QR.last({children:t},[]),b=[],D=t=>{var[r,n]=t;return!(0===n.length)&&(!!p||!(g&&nL.isAncestor(n,v)&&VR.isElement(r)&&!e.isVoid(r)&&!e.isInline(r))&&!(m&&nL.isAncestor(n,y)&&VR.isElement(r)&&!e.isVoid(r)&&!e.isInline(r)))};for(var C of QR.nodes({children:t},{pass:D}))D(C)&&b.push(C);var w=[],E=[],A=[],x=!0,B=!1;for(var[S]of b)VR.isElement(S)&&!e.isInline(S)?(x=!1,B=!0,E.push(S)):x?w.push(S):A.push(S);var[F]=YR.nodes(e,{at:i,match:t=>vL.isText(t)||YR.isInline(e,t),mode:"highest",voids:o}),[,k]=F,O=YR.isStart(e,i,k),T=YR.isEnd(e,i,k),N=YR.pathRef(e,f&&!A.length?nL.next(d):d),P=YR.pathRef(e,T?nL.next(k):k);IL.splitNodes(e,{at:i,match:t=>B?YR.isBlock(e,t):vL.isText(t)||YR.isInline(e,t),mode:B?"lowest":"highest",always:B&&(!h||w.length>0)&&(!f||A.length>0),voids:o});var M,I=YR.pathRef(e,!O||O&&T?nL.next(k):k);if(IL.insertNodes(e,w,{at:I.current,match:t=>vL.isText(t)||YR.isInline(e,t),mode:"highest",voids:o}),p&&!w.length&&E.length&&!A.length&&IL.delete(e,{at:d,voids:o}),IL.insertNodes(e,E,{at:N.current,match:t=>YR.isBlock(e,t),mode:"lowest",voids:o}),IL.insertNodes(e,A,{at:P.current,match:t=>vL.isText(t)||YR.isInline(e,t),mode:"highest",voids:o}),!r.at)if(A.length>0&&P.current?M=nL.previous(P.current):E.length>0&&N.current?M=nL.previous(N.current):I.current&&(M=nL.previous(I.current)),M){var R=YR.end(e,M);IL.select(e,R)}I.unref(),N.unref(),P.unref()}}})},insertText(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};YR.withoutNormalizing(e,()=>{var{voids:n=!1}=r,{at:o=e.selection}=r;if(o){if(nL.isPath(o)&&(o=YR.range(e,o)),lL.isRange(o))if(lL.isCollapsed(o))o=o.anchor;else{var i=lL.end(o);if(!n&&YR.void(e,{at:i}))return;var a=lL.start(o),s=YR.pointRef(e,a),u=YR.pointRef(e,i);IL.delete(e,{at:o,voids:n});var l=s.unref(),c=u.unref();o=l||c,IL.setSelection(e,{anchor:o,focus:o})}if(n||!YR.void(e,{at:o})){var{path:d,offset:h}=o;t.length>0&&e.apply({type:"insert_text",path:d,offset:h,text:t})}}})}};function PL(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),r.push.apply(r,n)}return r}function ML(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?PL(Object(r),!0).forEach(function(t){aR(e,t,r[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):PL(Object(r)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))})}return e}var IL=ML(ML(ML(ML({},DL),xL),TL),NL);function RL(){return rI("w-e-insert-formula")}var LL=function(){function e(){this.title=eC("formula.insert"),this.iconSvg=tI,this.tag="button",this.showModal=!0,this.modalWidth=300,this.$content=null,this.textareaId=RL(),this.buttonId=RL()}return e.prototype.getValue=function(e){return""},e.prototype.isActive=function(e){return!1},e.prototype.exec=function(e,t){},e.prototype.isDisabled=function(e){if(null==e.selection)return!0;var t=Ry.getSelectedElems(e);return!!t.some(function(t){return e.isVoid(t)})||!!t.some(function(e){return"pre"===Ry.getNodeType(e)})},e.prototype.getModalPositionNode=function(e){return null},e.prototype.getModalContentElem=function(e){var t=this,r=this.textareaId,n=this.buttonId,o=Qg(hC(eC("formula.formula"),r,eC("formula.placeholder")),2),i=o[0],a=ov(o[1]),s=Qg(fC(n,eC("formula.ok")),1)[0];if(null==this.$content){var u=ov("<div></div>");u.on("click","#".concat(n),function(n){n.preventDefault();var o=u.find("#".concat(r)).val().trim();o=nI(o),t.insertFormula(e,o),e.hidePanelOrModal()}),this.$content=u}var l=this.$content;l.html(""),l.append(i),l.append(s);var c=e.selection,d="";return c&&hg.isExpanded(c)&&(d=YR.string(e,c)),a.val(d),setTimeout(function(){a.focus()},50),l[0]},e.prototype.insertFormula=function(e,t){if(t&&(e.restoreSelection(),!this.isDisabled(e))){var r=e.selection,n={type:"formula",value:t,children:[{text:""}]};r&&hg.isExpanded(r)&&zg.delete(e),e.insertNode(n)}},e}();function _L(){return rI("w-e-text-to-formula")}var zL=function(){function e(){this.title=eC("formula.textToFormula"),this.iconSvg=tI,this.tag="button",this.showModal=!0,this.modalWidth=300,this.$content=null,this.textareaId=_L(),this.buttonId=_L()}return e.prototype.getValue=function(e){return""},e.prototype.isActive=function(e){return!1},e.prototype.exec=function(e,t){},e.prototype.isDisabled=function(e){if(null==vm.insertFormula)return!0;if(null==e.selection)return!1;var t=Ry.getSelectedElems(e);return!!t.some(function(t){return e.isVoid(t)})||!!t.some(function(e){return"pre"===Ry.getNodeType(e)})},e.prototype.getModalPositionNode=function(e){return null},e.prototype.getModalContentElem=function(e){var t=this,r=this.textareaId,n=this.buttonId,o=Qg(hC(eC("formula.formula"),r,eC("formula.placeholder")),2),i=o[0],a=ov(o[1]),s=Qg(fC(n,eC("formula.ok")),1)[0];if(null==this.$content){var u=ov("<div></div>");u.on("click","#".concat(n),function(n){n.preventDefault();var o=u.find("#".concat(r)).val().trim();o=nI(o),t.insertFormula(e,o),e.hidePanelOrModal()}),this.$content=u}var l=this.$content;l.html(""),l.append(i),l.append(s);var c=e.selection,d="";return c&&hg.isExpanded(c)&&(d=YR.string(e,c)),a.val(d),setTimeout(function(){if(a.focus(),d){var e=a[0];e&&e.select()}},50),l[0]},e.prototype.insertFormula=function(e,t){if(t&&(e.restoreSelection(),!this.isDisabled(e))){var r=e.selection,n={type:"formula",value:t,children:[{text:""}]};r&&hg.isExpanded(r)&&zg.delete(e),e.insertNode(n)}},e}();var jL={type:"formula",renderElem:function(e,t,r){var n=Ry.isNodeSelected(r,e),o=e.value,i=dw("w-e-formula-card",{dataset:{value:void 0===o?"":o}},null);return dw("div",{className:"w-e-textarea-formula-container",props:{contentEditable:!1},style:{display:"inline-block",marginLeft:"3px",marginRight:"3px",border:n?"2px solid var(--w-e-textarea-selected-border-color)":"2px solid transparent",borderRadius:"3px",padding:"3px 3px"}},[i])}},HL={editorPlugin:function(e){var t=e.isInline,r=e.isVoid,n=e;return n.isInline=function(e){return"formula"===Ry.getNodeType(e)||t(e)},n.isVoid=function(e){return"formula"===Ry.getNodeType(e)||r(e)},n},renderElems:[jL],elemsToHtml:[eI],parseElemsHtml:[{selector:'span[data-w-e-type="formula"]',parseElemHtml:function(e,t,r){return{type:"formula",value:e.getAttribute("data-value")||"",children:[{text:""}]}}}],menus:[{key:"insertFormula",factory:function(){return new LL}},{key:"editFormula",factory:function(){return new iI}},{key:"textToFormula",factory:function(){return new zL}}]};XD("en",{tableModule:{modal:{border:"Border",borderWidth:"Width",bgColor:"Back color",align:"Text Align",ok:"OK"},color:{default:"Default color",clear:"Clear back color"},borderStyle:{none:"None",solid:"Solid",dotted:"Dotted",dashed:"Dashed",double:"Double",groove:"Groove",ridge:"Ridge",inset:"Inset",outset:"Outset"},deleteCol:"Delete column",deleteRow:"Delete row",deleteTable:"Delete table",widthAuto:"Width auto",insertCol:"Insert column",insertRow:"Insert row",insertTable:"Insert table",header:"Header",mergeCell:"merge cell",splitCell:"split cell",tableProperty:"Table property",cellProperty:"Cell property"}}),XD("zh-CN",{tableModule:{modal:{border:"边框",borderWidth:"宽度",bgColor:"背景色",align:"对齐方式",ok:"确定"},color:{default:"默认颜色",clear:"清除背景色"},borderStyle:{none:"无样式",solid:"实线",dotted:"点状虚线",dashed:"虚线",double:"双线",groove:"凹槽边框",ridge:"菱形边框",inset:"凹边框",outset:"凸边框"},deleteCol:"删除列",deleteRow:"删除行",deleteTable:"删除表格",widthAuto:"宽度自适应",insertCol:"插入列",insertRow:"插入行",insertTable:"插入表格",header:"表头",mergeCell:"合并单元格",splitCell:"拆分单元格",tableProperty:"表格属性",cellProperty:"单元格属性"}});var VL={type:"table",elemToHtml:function(e,t){var r=e,n=r.width,o=void 0===n?"auto":n,i=r.columnWidths,a=r.height,s=void 0===a?"auto":a,u=null==i?void 0:i.map(function(e){return"<col width=".concat(e,"></col>")}).join(""),l=u?'<colgroup contentEditable="false">'.concat(u,"</colgroup>"):"";return'<table style="width: '.concat(o,";table-layout: fixed;height:").concat(s,'">').concat(l,"<tbody>").concat(t,"</tbody></table>")}},$L={type:"table-row",elemToHtml:function(e,t){return"<tr>".concat(t,"</tr>")}},UL={type:"table-cell",elemToHtml:function(e,t){var r=e,n=r.colSpan,o=void 0===n?1:n,i=r.rowSpan,a=void 0===i?1:i,s=r.isHeader,u=void 0!==s&&s,l=r.width,c=void 0===l?"auto":l,d=r.hidden;if(void 0!==d&&d)return"";var h=u?"th":"td";return"<".concat(h,' colSpan="').concat(o,'" rowSpan="').concat(a,'" width="').concat(c,'">').concat(t,"</").concat(h,">")}},qL='<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>',WL={blocks:{td:"table-cell",th:"table-cell",content:"paragraph",tr:"table-row",table:"table",tbody:"table-body"}};function GL(e){for(var t=[],r=1;r<arguments.length;r++)t[r-1]=arguments[r];var n=WL,o=t.map(function(e){var t;return null===(t=null==n?void 0:n.blocks)||void 0===t?void 0:t[e]});return function(e){return function(e){return!Yp.isEditor(e)&&Vp.isElement(e)&&"type"in e}(e)&&o.includes(e.type)}}function YL(e,t){for(var r=Qg(t,2),n=r[0],o=r[1],i=[],a=2;a<arguments.length;a++)i[a-2]=arguments[a];var s=Qg(eg.common(e,n,o),2),u=s[0],l=s[1];return!!GL.apply(void 0,em([e],Qg(i),!1))(u,l)||!!Yp.above(e,{match:GL.apply(void 0,em([e],Qg(i),!1)),at:l})}function KL(e,t){var r,n;void 0===t&&(t={});var o=[];try{for(var i=Jg(function(e,t){var r,n,o,i,a,s,u,l,c,d,h,f,p,g,m,v,y,b;return void 0===t&&(t={}),Zg(this,function(D){switch(D.label){case 0:if(r=Qg(Yp.nodes(e,{match:GL(e,"table"),at:t.at}),1),!(n=r[0]))return[2,[]];o=Qg(n,2),i=o[1],D.label=1;case 1:D.trys.push([1,6,7,8]),a=Jg(Yp.nodes(e,{match:GL(e,"table"),at:i})),s=a.next(),D.label=2;case 2:if(s.done)return[3,5];u=Qg(s.value,2),l=u[1],c=[];try{for(y=void 0,d=Jg(Yp.nodes(e,{match:GL(e,"tr"),at:l})),h=d.next();!h.done;h=d.next())f=Qg(h.value,2),p=f[1],c.push(em([],Qg(Yp.nodes(e,{match:GL(e,"th","td"),at:p})),!1))}catch(e){y={error:e}}finally{try{h&&!h.done&&(b=d.return)&&b.call(d)}finally{if(y)throw y.error}}return[4,c];case 3:D.sent(),D.label=4;case 4:return s=a.next(),[3,2];case 5:return[3,8];case 6:return g=D.sent(),m={error:g},[3,8];case 7:try{s&&!s.done&&(v=a.return)&&v.call(a)}finally{if(m)throw m.error}return[7];case 8:return[2]}})}(e,{at:t.at})),a=i.next();!a.done;a=i.next()){for(var s=a.value,u=[],l=0,c=0;c<s.length;c+=1)s[c]&&(l=Math.max(l,s[c].length));for(c=0;c<s.length;c+=1)if(u[c]||(u[c]=[]),s[c])for(var d=0;d<s[c].length;d+=1)if(s[c][d]&&s[c][d][0]){for(var h=Qg(s[c][d],1)[0],f=h.rowSpan,p=void 0===f?1:f,g=h.colSpan,m=void 0===g?1:g,v=d;u[c]&&u[c][v];)v+=1;for(var y=0;y<m;y+=1)for(var b=0;b<p;b+=1){var D=c+b,C=v+y;u[D]||(u[D]=[]),u[D][C]||(u[D][C]=[s[c][d],{rtl:y+1,ltr:m-y,ttb:b+1,btt:p-b}])}}o.push.apply(o,em([],Qg(u),!1))}}catch(e){r={error:e}}finally{try{a&&!a.done&&(n=i.return)&&n.call(i)}finally{if(r)throw r.error}}return o}var XL=function(){function e(e,t){this.x=e,this.y=t}return e.valueOf=function(e,t){return new this(e,t)},e.equals=function(e,t){return e.x===t.x&&e.y===t.y},e}();function ZL(e){return e.length?e[0].tagName.toLowerCase():""}function JL(e,t){for(var r="",n=(e.attr("style")||"").split(";"),o=n.length,i=0;i<o;i+=1){var a=n[i];if(a){var s=a.split(":");s[0].trim()===t&&(r=s[1].trim())}}return r}Bv&&ov.fn&&(ov.fn.append=Bv),fv&&ov.fn&&(ov.fn.on=fv),Lv&&ov.fn&&(ov.fn.focus=Lv),uv&&ov.fn&&(ov.fn.attr=uv),hv&&ov.fn&&(ov.fn.val=hv),Ev&&ov.fn&&(ov.fn.html=Ev),dv&&ov.fn&&(ov.fn.dataset=dv),iv&&ov.fn&&(ov.fn.addClass=iv),av&&ov.fn&&(ov.fn.removeClass=av),Tv&&ov.fn&&(ov.fn.children=Tv),Cv&&ov.fn&&(ov.fn.each=Cv),Ov&&ov.fn&&(ov.fn.find=Ov),cv&&ov.fn&&(ov.fn.data=cv),yv&&ov.fn&&(ov.fn.hide=yv),bv&&ov.fn&&(ov.fn.show=bv);var QL=new WeakMap,e_=new WeakMap,t_=function(){function e(){this.title=eC("tableModule.tableProperty"),this.iconSvg='<svg viewBox="0 0 20 20"><path d="M8 2v5h4V2h1v5h5v1h-5v4h.021l-.172.351-1.916.28-.151.027c-.287.063-.54.182-.755.341L8 13v5H7v-5H2v-1h5V8H2V7h5V2h1zm4 6H8v4h4V8z" opacity=".6"/><path d="m15.5 11.5 1.323 2.68 2.957.43-2.14 2.085.505 2.946L15.5 18.25l-2.645 1.39.505-2.945-2.14-2.086 2.957-.43L15.5 11.5zM17 1a2 2 0 0 1 2 2v9.475l-.85-.124-.857-1.736a2.048 2.048 0 0 0-.292-.44L17 3H3v14h7.808l.402.392L10.935 19H3a2 2 0 0 1-2-2V3a2 2 0 0 1 2-2h14z"/></svg>',this.tag="button",this.showModal=!0,this.modalWidth=300,this.menu="table",this.borderStyle=[{value:"none",label:eC("tableModule.borderStyle.none")},{value:"solid",label:eC("tableModule.borderStyle.solid")},{value:"dotted",label:eC("tableModule.borderStyle.dotted")},{value:"dashed",label:eC("tableModule.borderStyle.dashed")},{value:"double",label:eC("tableModule.borderStyle.double")},{value:"groove",label:eC("tableModule.borderStyle.groove")},{value:"ridge",label:eC("tableModule.borderStyle.ridge")},{value:"inset",label:eC("tableModule.borderStyle.inset")},{value:"outset",label:eC("tableModule.borderStyle.outset")}],this.textAlignOptions=[{value:"left",label:eC("justify.left"),svg:'<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>'},{value:"center",label:eC("justify.center"),svg:'<svg viewBox="0 0 1024 1024"><path d="M870.4 793.6v102.4H153.6v-102.4h716.8z m102.4-230.4v102.4H51.2v-102.4h921.6z m-102.4-230.4v102.4H153.6v-102.4h716.8zM972.8 102.4v102.4H51.2V102.4h921.6z"></path></svg>'},{value:"right",label:eC("justify.right"),svg:'<svg viewBox="0 0 1024 1024"><path d="M972.8 793.6v102.4H256v-102.4h716.8z m0-230.4v102.4H51.2v-102.4h921.6z m0-230.4v102.4H256v-102.4h716.8zM972.8 102.4v102.4H51.2V102.4h921.6z"></path></svg>'},{value:"justify",label:eC("justify.justify"),svg:'<svg viewBox="0 0 1024 1024"><path d="M0 64h1024v128H0z m0 192h1024v128H0z m0 192h1024v128H0z m0 192h1024v128H0z m0 192h1024v128H0z"></path></svg>'}]}return e.prototype.getValue=function(e){return""},e.prototype.isActive=function(e){return!1},e.prototype.isDisabled=function(e){return null==Ry.getSelectedNodeByType(e,"table")},e.prototype.exec=function(e,t){},e.prototype.getModalContentNode=function(e){return Qg(Yp.nodes(e,{match:GL(e,"table")}),1)[0]},e.prototype.getModalPositionNode=function(e){return null},e.prototype.getModalContentElem=function(e){var t=this,r=this.getModalContentNode(e);if(!r)return null;var n=Qg(r,2),o=n[0],i=n[1],a=ov('<div>\n <label class="babel-container">\n <span>'.concat(eC("tableModule.modal.border"),'</span>\n <span class="babel-container-border">\n <select name="borderStyle">\n ').concat(this.borderStyle.map(function(e){return'<option value="'.concat(e.value,'">').concat(e.label,"</option>")}).join(""),'\n </select>\n <span class="color-group" data-mark="color">\n <span class="color-group-block"></span>\n <input name="borderColor" type="hidden">\n </span>\n <input name="borderWidth" type="number" placeholder="').concat(eC("tableModule.modal.borderWidth"),'">\n </span>\n </label>\n <div class="babel-container">\n <span>').concat(eC("tableModule.modal.bgColor"),'</span>\n <span class="babel-container-background">\n <span class="color-group" data-mark="bgColor">\n <span class="color-group-block"></span>\n <input name="backgroundColor" type="hidden">\n </span>\n </span>\n </div>\n <label class="babel-container">\n <span>').concat(eC("tableModule.modal.align"),'</span>\n <span class="babel-container-align">\n <select name="textAlign">\n ').concat(this.textAlignOptions.map(function(e){return'<option value="'.concat(e.value,'">').concat(e.label,"</option>")}).join(""),'\n </select>\n </span>\n </label>\n <div class="button-container">\n <button type="button">').concat(eC("tableModule.modal.ok"),"</button>\n </div>\n </div>"));a.find("[name]").each(function(e){ov(e).val(o[ov(e).attr("name")])});var s=function(e,t){t?ov(".color-group-block",e).css("background-color",t).empty():ov(".color-group-block",e).css("background-color","").html(qL)};return a.find(".color-group").each(function(r){var n=ov('[type="hidden"]',r).val()||"";s(r,n);var o=ov(r);o.on("click",function(){a.find(".color-group .w-e-drop-panel").hide();var i=o.data("panel");i?i.show():(i=t.getPanelContentElem(e,{mark:o.data("mark"),selectedColor:n,callback:function(e){ov('[type="hidden"]',r).val(e||""),s(r,e),i.hide()}}),o.append(i),o.data("panel",i))})}),a.find("button").on("click",function(){var r=Array.from(a.find("[name]")).reduce(function(e,t){return e[ov(t).attr("name")]=ov(t).val(),e},{}),n=QL.get(e);"cell"===t.menu&&(null==n?void 0:n.length)?n.forEach(function(t){t.forEach(function(t){zg.setNodes(e,r,{at:t[0][1]})})}):zg.setNodes(e,r,{at:i}),setTimeout(function(){e.focus()})}),a[0]},e.prototype.getPanelContentElem=function(e,t){var r=t.mark,n=t.selectedColor,o=t.callback,i=ov('<ul class="w-e-panel-content-color"></ul>');i.on("click","li",function(e){var t=e.target;if(t){e.preventDefault(),e.stopPropagation();var r=ov(t).attr("data-value");o(r)}});var a=e.getMenuConfig(r).colors;(void 0===a?[]:a).forEach(function(e){var t=ov('<div class="color-block" data-value="'.concat(e,'"></div>'));t.css("background-color",e);var r=ov('<li data-value="'.concat(e,'"></li>'));n===e&&r.addClass("active"),r.append(t),i.append(r)});var s="";"color"===r&&(s=eC("tableModule.color.default")),"bgColor"===r&&(s=eC("tableModule.color.clear"));var u=ov('\n <li data-value="" class="clear">\n '.concat(qL,"\n ").concat(s,"\n </li>\n "));i.prepend(u);var l=ov('<div class="w-e-drop-panel"></div>');return l.append(i),l},e}(),r_=function(e){function t(){var t=e.apply(this,em([],Qg(arguments),!1))||this;return t.title=eC("tableModule.cellProperty"),t.iconSvg='<svg viewBox="0 0 20 20"><path d="m11.105 18-.17 1H2.5A1.5 1.5 0 0 1 1 17.5v-15A1.5 1.5 0 0 1 2.5 1h15A1.5 1.5 0 0 1 19 2.5v9.975l-.85-.124-.15-.302V8h-5v4h.021l-.172.351-1.916.28-.151.027c-.287.063-.54.182-.755.341L8 13v5h3.105zM2 12h5V8H2v4zm10-4H8v4h4V8zM2 2v5h5V2H2zm0 16h5v-5H2v5zM13 7h5V2h-5v5zM8 2v5h4V2H8z" opacity=".6"/><path d="m15.5 11.5 1.323 2.68 2.957.43-2.14 2.085.505 2.946L15.5 18.25l-2.645 1.39.505-2.945-2.14-2.086 2.957-.43L15.5 11.5zM13 6a1 1 0 0 1 1 1v3.172a2.047 2.047 0 0 0-.293.443l-.858 1.736-1.916.28-.151.027A1.976 1.976 0 0 0 9.315 14H7a1 1 0 0 1-1-1V7a1 1 0 0 1 1-1h6zm-1 2H8v4h4V8z"/></svg>',t.tag="button",t.showModal=!0,t.modalWidth=300,t.menu="cell",t}return Yg(t,e),t.prototype.getModalContentNode=function(e){return Qg(Yp.nodes(e,{match:GL(e,"td")}),1)[0]},t}(t_),n_=function(){function e(){this.title=eC("tableModule.deleteCol"),this.iconSvg='<svg viewBox="0 0 1048 1024"><path d="M327.68 510.976L393.216 445.44v-13.1072L327.68 366.7968V510.976z m327.68-78.4384l65.536-65.536V507.904L655.36 442.368v-9.8304z m393.216 484.9664V0H0v917.504h1048.576z m-65.536-131.072h-262.144v-52.4288l-13.1072 13.1072-52.4288-52.4288v91.7504H393.216v-91.7504l-52.4288 52.4288-13.1072-13.1072v52.4288H65.536V65.536H327.68v121.2416l36.0448-36.0448 29.4912 29.4912V62.2592h262.144V180.224l49.152-49.152 16.384 16.384V62.2592h262.144V786.432z m-294.912-108.1344l-160.5632-160.5632-167.1168 167.1168-78.6432-78.6432 167.1168-167.1168L288.3584 278.528l78.6432-78.6432 160.5632 160.5632 163.84-163.84 78.6432 78.6432-163.84 163.84 160.5632 160.5632-78.6432 78.6432z"></path></svg>',this.tag="button"}return e.prototype.getValue=function(e){return""},e.prototype.isActive=function(e){return!1},e.prototype.isDisabled=function(e){var t=e.selection;return null==t||(!hg.isCollapsed(t)||null==Ry.getSelectedNodeByType(e,"table-cell"))},e.prototype.exec=function(e,t){if(!this.isDisabled(e)){var r=Qg(Yp.nodes(e,{match:function(e){return Ry.checkNodeType(e,"table-cell")},universal:!0}),1),n=Qg(r[0],2),o=n[0],i=n[1],a=Ry.getParentNode(e,o),s=(null==a?void 0:a.children.length)||0;if(!a||s<=1)zg.removeNodes(e,{mode:"highest"});else if(null!=Ry.getParentNode(e,a)){var u=KL(e),l=0;e:for(var c=0;c<u.length;c+=1)for(var d=0;d<u[c].length;d+=1){var h=Qg(u[c][d],1),f=Qg(h[0],2)[1];if(og.equals(i,f)){l=d;break e}}Yp.withoutNormalizing(e,function(){for(var t,r,n=new Set,o=new Set,i=0;i<u.length;i+=1)if(u[i]&&u[i][l]){var a=Qg(u[i][l],2),s=Qg(a[0],2)[1],c=a[1],d=c.rtl,h=c.ltr,f=c.ttb,p=c.btt,g=s.join(",");if(d>1||h>1||f>1||p>1){var m=i-(f-1),v=l-(d-1);if(m<0||m>=u.length||!u[m]||!u[m][v])continue;var y=Qg(u[m][v],1),b=Qg(y[0],2),D=b[0],C=b[1],w=C.join(",");if(!o.has(w)){o.add(w);var E=D.rowSpan,A=void 0===E?1:E,x=D.colSpan,B=void 0===x?1:x,S=Math.max(B-1,1);zg.setNodes(e,{rowSpan:A,colSpan:S},{at:C})}}else n.add(g)}var F=Array.from(n);F.sort(function(e,t){var r=e.split(",").map(Number),n=t.split(",").map(Number);return r[r.length-2]!==n[n.length-2]?n[n.length-2]-r[r.length-2]:n[n.length-1]-r[r.length-1]});try{for(var k=Jg(F),O=k.next();!O.done;O=k.next()){var T=O.value.split(",").map(Number);try{Yp.hasPath(e,T)&&zg.removeNodes(e,{at:T})}catch(e){console.warn("删除单元格失败:",T,e)}}}catch(e){t={error:e}}finally{try{O&&!O.done&&(r=k.return)&&r.call(k)}finally{if(t)throw t.error}}var N=Qg(Yp.nodes(e,{match:function(e){return Ry.checkNodeType(e,"table")},universal:!0}),1),P=N[0];if(P){var M=Qg(P,2),I=M[0],R=M[1],L=I.columnWidths,_=em([],Qg(void 0===L?[]:L),!1);_.splice(l,1),zg.setNodes(e,{columnWidths:_},{at:R})}})}}},e}(),o_=function(){function e(){this.title=eC("tableModule.deleteRow"),this.iconSvg='<svg viewBox="0 0 1048 1024"><path d="M907.6736 586.5472L747.1104 425.984l163.84-163.84-78.6432-78.6432-163.84 163.84L507.904 186.7776 429.2608 262.144l163.84 163.84-167.1168 167.1168 78.6432 78.6432 167.1168-167.1168 160.5632 160.5632 75.3664-78.6432zM0 917.504V0h1048.576v917.504H0z m983.04-327.68h-22.9376l-65.536-65.536H983.04V327.68h-91.7504l65.536-65.536h26.2144V65.536H65.536v196.608h317.8496l65.536 65.536H65.536v196.608h380.1088l-65.536 65.536H65.536v196.608H983.04v-196.608z"></path></svg>',this.tag="button"}return e.prototype.getValue=function(e){return""},e.prototype.isActive=function(e){return!1},e.prototype.isDisabled=function(e){var t=e.selection;return null==t||(!hg.isCollapsed(t)||null==Ry.getSelectedNodeByType(e,"table-row"))},e.prototype.exec=function(e,t){if(!this.isDisabled(e)){var r=Qg(Yp.nodes(e,{match:function(e){return Ry.checkNodeType(e,"table-row")},universal:!0}),1),n=Qg(r[0],2),o=n[0],i=n[1],a=Ry.getParentNode(e,o);if(((null==a?void 0:a.children.length)||0)<=1)zg.removeNodes(e,{mode:"highest"});else{var s=Qg(Yp.nodes(e,{match:function(e){return Ry.checkNodeType(e,"table-cell")},universal:!0}),1),u=Qg(s[0],2)[1],l=KL(e),c=0;e:for(var d=0;d<l.length;d+=1)for(var h=0;h<l[d].length;h+=1){var f=Qg(l[d][h],1),p=Qg(f[0],2)[1];if(og.equals(u,p)){c=d;break e}}Yp.withoutNormalizing(e,function(){for(var t,r,n=[],o=0;o<l[c].length;o+=1){var a=Qg(l[c][o],2),s=Qg(a[0],1)[0].hidden,u=a[1],d=u.ttb,h=u.btt,f=u.rtl;if(d>1||h>1){var p=c-(d-1);if(p<0||p>=l.length||!l[p]||!l[p][o])continue;var g=Qg(l[p][o],1),m=Qg(g[0],2),v=m[0],y=m[1],b=v,D=b.rowSpan,C=void 0===D?1:D,w=b.colSpan,E=void 0===w?1:w;if(s)zg.setNodes(e,{rowSpan:Math.max(C-1,1),colSpan:E},{at:y});else if(1===d&&1===f){if(c+1<l.length&&C>1){var A={type:"table-cell",rowSpan:C-1,colSpan:E,hidden:!1,children:b.children.map(function(e){return Kg({},e)})};b.isHeader&&(A.isHeader=b.isHeader),b.width&&(A.width=b.width),b.backgroundColor&&(A.backgroundColor=b.backgroundColor),b.borderWidth&&(A.borderWidth=b.borderWidth),b.borderStyle&&(A.borderStyle=b.borderStyle),b.borderColor&&(A.borderColor=b.borderColor),b.textAlign&&(A.textAlign=b.textAlign),n.push({cell:A,columnIndex:o})}else zg.setNodes(e,{rowSpan:Math.max(C-1,1),colSpan:E},{at:y})}else zg.setNodes(e,{rowSpan:Math.max(C-1,1),colSpan:E},{at:y})}}if(zg.removeNodes(e,{at:i}),n.length>0){var x=i;try{n.sort(function(e,t){return e.columnIndex-t.columnIndex});try{for(var B=Jg(n),S=B.next();!S.done;S=B.next()){var F=S.value,k=F.cell,O=F.columnIndex;try{var T=em(em([],Qg(x),!1),[O],!1);zg.insertNodes(e,k,{at:T})}catch(t){try{var N=Qg(Yp.node(e,x),1)[0].children.length,P=em(em([],Qg(x),!1),[N],!1);zg.insertNodes(e,k,{at:P})}catch(e){console.warn("插入新单元格失败:",e)}}}}catch(e){t={error:e}}finally{try{S&&!S.done&&(r=B.return)&&r.call(B)}finally{if(t)throw t.error}}}catch(e){console.warn("插入新单元格失败:",e)}}})}}},e}(),i_=function(){function e(){this.title=eC("tableModule.deleteTable"),this.iconSvg='<svg viewBox="0 0 1024 1024"><path d="M826.8032 356.5312c-19.328 0-36.3776 15.6928-36.3776 35.0464v524.2624c0 19.328-16 34.56-35.328 34.56H264.9344c-19.328 0-35.5072-15.3088-35.5072-34.56V390.0416c0-19.328-14.1568-35.0464-33.5104-35.0464s-33.5104 15.6928-33.5104 35.0464V915.712c0 57.9328 44.6208 108.288 102.528 108.288H755.2c57.9328 0 108.0832-50.4576 108.0832-108.288V391.4752c-0.1024-19.2512-17.1264-34.944-36.48-34.944z" p-id="9577"></path><path d="M437.1712 775.7568V390.6048c0-19.328-14.1568-35.0464-33.5104-35.0464s-33.5104 15.616-33.5104 35.0464v385.152c0 19.328 14.1568 35.0464 33.5104 35.0464s33.5104-15.7184 33.5104-35.0464zM649.7024 775.7568V390.6048c0-19.328-17.0496-35.0464-36.3776-35.0464s-36.3776 15.616-36.3776 35.0464v385.152c0 19.328 17.0496 35.0464 36.3776 35.0464s36.3776-15.7184 36.3776-35.0464zM965.0432 217.0368h-174.6176V145.5104c0-57.9328-47.2064-101.76-104.6528-101.76h-350.976c-57.8304 0-105.3952 43.8528-105.3952 101.76v71.5264H54.784c-19.4304 0-35.0464 14.1568-35.0464 33.5104 0 19.328 15.616 33.5104 35.0464 33.5104h910.3616c19.328 0 35.0464-14.1568 35.0464-33.5104 0-19.3536-15.6928-33.5104-35.1488-33.5104z m-247.3728 0H297.3952V145.5104c0-19.328 18.2016-34.7648 37.4272-34.7648h350.976c19.1488 0 31.872 15.1296 31.872 34.7648v71.5264z"></path></svg>',this.tag="button"}return e.prototype.getValue=function(e){return""},e.prototype.isActive=function(e){return!1},e.prototype.isDisabled=function(e){return null==e.selection||null==Ry.getSelectedNodeByType(e,"table")},e.prototype.exec=function(e,t){this.isDisabled(e)||zg.removeNodes(e,{mode:"highest"})},e}(),a_=function(){function e(){this.title=eC("tableModule.widthAuto"),this.iconSvg='<svg viewBox="0 0 1228 1024"><path d="M862.514337 563.200461H404.581995v121.753478a13.311987 13.311987 0 0 1-6.655993 11.468789 10.23999 10.23999 0 0 1-12.083188-1.433599l-204.799795-179.199821a13.721586 13.721586 0 0 1 0-20.479979l204.799795-179.302221a10.23999 10.23999 0 0 1 12.185588-1.535998 13.209587 13.209587 0 0 1 6.553593 11.673588v115.097485h457.932342V319.693504a11.571188 11.571188 0 0 1 18.841582-10.239989l204.799795 179.19982a13.721586 13.721586 0 0 1 0 20.47998l-204.799795 179.199821a10.23999 10.23999 0 0 1-12.185588 1.535998 13.311987 13.311987 0 0 1-6.655994-11.571188V563.200461zM136.499064 14.951409v993.893406a15.257585 15.257585 0 0 1-15.155185 15.052785H15.155185A15.155185 15.155185 0 0 1 0 1008.844815V14.951409a15.257585 15.257585 0 0 1 15.155185-15.052785h106.086294a15.155185 15.155185 0 0 1 15.257585 15.155185zM1228.798771 14.951409v993.893406a15.257585 15.257585 0 0 1-15.155185 15.052785h-106.188693a15.155185 15.155185 0 0 1-15.155185-15.052785V14.951409a15.257585 15.257585 0 0 1 15.155185-15.052785h106.086293A15.155185 15.155185 0 0 1 1228.798771 15.053809z"></path></svg>',this.tag="button"}return e.prototype.getValue=function(e){var t=Ry.getSelectedNodeByType(e,"table");return!!t&&("100%"===t.width||"auto"===t.width)},e.prototype.isActive=function(e){return!!this.getValue(e)},e.prototype.isDisabled=function(e){var t=e.selection;return null==t||(!hg.isCollapsed(t)||null==Ry.getSelectedNodeByType(e,"table"))},e.prototype.exec=function(e,t){if(!this.isDisabled(e)){var r={width:t?"auto":"100%"};zg.setNodes(e,r,{mode:"highest"})}},e}();function s_(e){var t=e.children||[];return 0===t.length?[]:(t[0]||{}).children||[]}function u_(e){return s_(e).every(function(e){return!!e.isHeader})}var l_=function(){function e(){this.title=eC("tableModule.insertCol"),this.iconSvg='<svg viewBox="0 0 1048 1024"><path d="M327.68 193.3312v186.7776H140.9024v91.7504H327.68v186.7776h88.4736V471.8592h190.0544V380.1088H416.1536V193.3312zM0 917.504V0h1048.576v917.504H0zM655.36 65.536H65.536v720.896H655.36V65.536z m327.68 0h-262.144v196.608h262.144V65.536z m0 262.144h-262.144v196.608h262.144V327.68z m0 262.144h-262.144v196.608h262.144v-196.608z"></path></svg>',this.tag="button"}return e.prototype.getValue=function(e){return""},e.prototype.isActive=function(e){return!1},e.prototype.isDisabled=function(e){var t=e.selection;if(null==t)return!0;if(!hg.isCollapsed(t))return!0;var r=Ry.getSelectedNodeByType(e,"table");if(null==r)return!0;try{var n=Qg(Yp.nodes(e,{match:function(e){return Ry.checkNodeType(e,"table-cell")},universal:!0}),1),o=n[0];if(!o)return!0;for(var i=Qg(o,2)[1],a=KL(e),s=-1,u=0;u<a.length;u+=1){for(var l=0;l<a[u].length;l+=1){var c=Qg(a[u][l],1),d=Qg(c[0],2)[1];if(og.equals(i,d)){s=l;break}}if(-1!==s)break}if(-1===s)return!0;var h=r.columnWidths,f=(void 0===h?[]:h)[s];if(f&&f<20)return!0}catch(e){return!0}return!1},e.prototype.exec=function(e,t){if(!this.isDisabled(e)){var r=Qg(Yp.nodes(e,{match:function(e){return Ry.checkNodeType(e,"table-cell")},universal:!0}),1),n=Qg(r[0],2),o=n[0],i=n[1],a=Ry.getParentNode(e,o);if(null!=a){var s=Ry.getParentNode(e,a);if(null!=s){for(var u=KL(e),l=0,c=0;c<u.length;c+=1)for(var d=0;d<u[c].length;d+=1){var h=Qg(u[c][d],1),f=Qg(h[0],2)[1];if(og.equals(i,f)){l=d;break}}Yp.withoutNormalizing(e,function(){for(var t=new Set,r=new Set,n=0;n<u.length;n+=1)if(u[n]&&u[n][l]){var o=Qg(u[n][l],2);Qg(o[0],1);var i=o[1],a=i.rtl,c=i.ltr,d=i.ttb,h=i.btt;if(a>1||c>1||d>1||h>1){var f=n-(d-1),p=l-(a-1);if(f<0||f>=u.length||!u[f]||!u[f][p])continue;var g=Qg(u[f][p],1),m=Qg(g[0],2),v=m[0],y=m[1],b=y.join(",");if(t.has(b))r.add(n);else{t.add(b);var D=v.rowSpan,C=void 0===D?1:D,w=v.colSpan,E=(void 0===w?1:w)+1;v.hidden||zg.setNodes(e,{colSpan:E},{at:y});for(var A=0;A<C;A+=1)r.add(f+A)}}}for(n=0;n<u.length;n+=1)if(!r.has(n)&&u[n]&&u[n][l]){var x={type:"table-cell",children:[{text:""}]};0===n&&u_(s)&&(x.isHeader=!0);var B=Qg(u[n][l],1),S=Qg(B[0],2)[1];zg.insertNodes(e,x,{at:S})}var F=Qg(Yp.nodes(e,{match:function(e){return Ry.checkNodeType(e,"table")},universal:!0}),1),k=F[0];if(k){var O=Qg(k,2),T=O[0],N=O[1],P=T.columnWidths,M=void 0===P?[]:P,I=em([],Qg(M),!1),R=e.getMenuConfig("insertTable").minWidth,L=void 0===R?60:R,_=M[l]||parseInt(L,10)||60,z=Math.floor(_/2),j=_-z;I.splice(l,0,z),I[l+1]=j,zg.setNodes(e,{columnWidths:I},{at:N})}})}}}},e}(),c_=function(){function e(){this.title=eC("tableModule.insertRow"),this.iconSvg='<svg viewBox="0 0 1048 1024"><path d="M707.7888 521.0112h-147.456v-147.456H488.2432v147.456h-147.456v68.8128h147.456v147.456h72.0896v-147.456h147.456zM0 917.504V0h1048.576v917.504H0zM327.68 65.536H65.536v196.608H327.68V65.536z m327.68 0H393.216v196.608h262.144V65.536z m327.68 0h-262.144v196.608h262.144V65.536z m0 258.8672H65.536v462.0288H983.04V324.4032z"></path></svg>',this.tag="button"}return e.prototype.getValue=function(e){return""},e.prototype.isActive=function(e){return!1},e.prototype.isDisabled=function(e){var t=e.selection;return null==t||(!hg.isCollapsed(t)||null==Ry.getSelectedNodeByType(e,"table"))},e.prototype.exec=function(e,t){var r;if(!this.isDisabled(e)){var n=Qg(Yp.nodes(e,{match:function(e){return Ry.checkNodeType(e,"table-cell")},universal:!0}),1),o=Qg(n[0],2)[1],i=KL(e),a=0;e:for(var s=0;s<i.length;s+=1)for(var u=0;u<i[s].length;u+=1){var l=Qg(i[s][u],1),c=Qg(l[0],2)[1];if(og.equals(o,c)){a=s;break e}}var d=(null===(r=i[a])||void 0===r?void 0:r.length)||0;0!==d&&Yp.withoutNormalizing(e,function(){for(var t=a+1,r=t>=0&&t<i.length,n=[],s=0;r&&s<i[a].length;s+=1){var u=Qg(i[a][s],2)[1],l=u.ttb,c=u.btt;if(l>1||c>1){var h=a-(l-1);if(h<0||h>=i.length||!i[h]||!i[h][s])continue;var f=Qg(i[h][s],1),p=Qg(f[0],2),g=p[0],m=p[1],v=g.rowSpan||1;n.push(s),g.hidden||zg.setNodes(e,{rowSpan:v+1},{at:m})}}for(var y={type:"table-row",children:[]},b=0;b<d;b+=1)if(!n.includes(b)){y.children.push({type:"table-cell",children:[{text:""}]})}var D=og.parent(o),C=og.next(D);zg.insertNodes(e,y,{at:C})})}},e}();var d_=function(){function e(){this.title=eC("tableModule.insertTable"),this.iconSvg='<svg viewBox="0 0 1024 1024"><path d="M0 64v896h1024V64H0z m384 576v-192h256v192h-256z m256 64v192h-256v-192h256z m0-512v192h-256V192h256zM320 192v192H64V192h256z m-256 256h256v192H64v-192z m640 0h256v192h-256v-192z m0-64V192h256v192h-256zM64 704h256v192H64v-192z m640 192v-192h256v192h-256z"></path></svg>',this.tag="button",this.showDropPanel=!0,this.$content=null}return e.prototype.getValue=function(e){return""},e.prototype.isActive=function(e){return!1},e.prototype.exec=function(e,t){},e.prototype.isDisabled=function(e){var t=e.selection;return null==t||(!hg.isCollapsed(t)||!!Ry.getSelectedElems(e).some(function(t){var r=Ry.getNodeType(t);return"pre"===r||("table"===r||("list-item"===r||!!e.isVoid(t)))}))},e.prototype.getPanelContentElem=function(e){var t=this;if(this.$content)return this.$content[0];for(var r=ov('<div class="w-e-panel-content-table"></div>'),n=ov("<span>0 × 0</span>"),o=ov("<table></table>"),i=0;i<10;i+=1){for(var a=ov("<tr></tr>"),s=0;s<10;s+=1){var u=ov("<td></td>");u.attr("data-x",s.toString()),u.attr("data-y",i.toString()),a.append(u),u.on("mouseenter",function(e){var t=e.target;if(null!=t){var r=ov(t).dataset(),i=r.x,a=r.y;n[0].innerHTML="".concat(i+1," × ").concat(a+1),o.children().each(function(e){ov(e).children().each(function(e){var t=ov(e),r=t.dataset(),n=r.x,o=r.y;n<=i&&o<=a?t.addClass("active"):t.removeClass("active")})})}}),u.on("click",function(r){r.preventDefault();var n=r.target;if(null!=n){var o=ov(n).dataset(),i=o.x,a=o.y;t.insertTable(e,a+1,i+1)}})}o.append(a)}return r.append(o),r.append(n),this.$content=r,r[0]},e.prototype.insertTable=function(e,t,r){var n=parseInt(t,10),o=parseInt(r,10);if(n&&o&&!(n<=0||o<=0)){if(Ry.isSelectedEmptyParagraph(e)&&zg.removeNodes(e,{mode:"highest"}),0===e.children.length){zg.insertNodes(e,{type:"paragraph",children:[{text:""}]},{mode:"highest"})}var i=function(e,t,r){for(var n,o=[],i=e.getMenuConfig("insertTable"),a=i.minWidth,s=void 0===a?60:a,u=i.tableFullWidth,l=i.tableHeader,c=Array(r).fill(parseInt(s,10)||60),d=0;d<t;d+=1){for(var h=[],f=0;f<r;f+=1){var p={type:"table-cell",children:[{text:""}]};0===d&&(p.isHeader=null===(n=null==l?void 0:l.selected)||void 0===n||n),h.push(p)}o.push({type:"table-row",children:h})}return{type:"table",width:(null==u?void 0:u.selected)?"100%":"auto",children:o,columnWidths:c}}(e,n,o);zg.insertNodes(e,i,{mode:"highest"})}},e}(),h_={isInTable:function(e,t){return void 0===t&&(t={}),!!Qg(Yp.nodes(e,{match:GL(e,"table"),at:t.at}),1)[0]},selection:function(e){var t,r,n,o,i,a,s,u;return Zg(this,function(l){switch(l.label){case 0:t=QL.get(e),r=0,l.label=1;case 1:if(!(t&&r<t.length))return[3,4];for(n=[],o=0;o<t[r].length;o+=1)i=Qg(t[r][o],2),a=i[0],s=i[1],u=s.ltr,1===s.ttb&&n.push(a),o+=u-1;return[4,n];case 2:l.sent(),l.label=3;case 3:return r+=1,[3,1];case 4:return[2]}})},unselect:function(e){e_.delete(e),QL.delete(e)},isSelected:function(e,t){var r=e_.get(e);return!!r&&r.has(t)}},f_=function(){function e(){this.title=eC("tableModule.mergeCell"),this.iconSvg='<svg viewBox="0 0 1024 1024"><path d="M482.2 508.4 331.3 389c-3-2.4-7.3-.2-7.3 3.6V478H184V184h204v128c0 2.2 1.8 4 4 4h60c2.2 0 4-1.8 4-4V144c0-15.5-12.5-28-28-28H144c-15.5 0-28 12.5-28 28v736c0 15.5 12.5 28 28 28h284c15.5 0 28-12.5 28-28V712c0-2.2-1.8-4-4-4h-60c-2.2 0-4 1.8-4 4v128H184V546h140v85.4c0 3.8 4.4 6 7.3 3.6l150.9-119.4c2.4-1.8 2.4-5.4 0-7.2zM880 116H596c-15.5 0-28 12.5-28 28v168c0 2.2 1.8 4 4 4h60c2.2 0 4-1.8 4-4V184h204v294H700v-85.4c0-3.8-4.3-6-7.3-3.6l-151 119.4c-2.3 1.8-2.3 5.3 0 7.1l151 119.5c2.9 2.3 7.3.2 7.3-3.6V546h140v294H636V712c0-2.2-1.8-4-4-4h-60c-2.2 0-4 1.8-4 4v168c0 15.5 12.5 28 28 28h284c15.5 0 28-12.5 28-28V144c0-15.5-12.5-28-28-28z"/></svg>',this.tag="button"}return e.prototype.getValue=function(e){return""},e.prototype.isActive=function(e){return!1},e.prototype.isDisabled=function(e){return!this.canMerge(e)},e.prototype.exec=function(e,t){this.isDisabled(e)||(this.merge(e),h_.unselect(e))},e.prototype.canMerge=function(e){var t=QL.get(e);if(!t||!t.length)return!1;var r=Qg(t[t.length-1][t[t.length-1].length-1],1),n=Qg(r[0],2)[1],o=Qg(t[0][0],1);return!!YL(e,[Qg(o[0],2)[1],n],"table")},e.prototype.merge=function(e){if(this.canMerge(e)){var t=QL.get(e);if(t&&t.length){var r=Qg(t[0][0],1),n=Qg(r[0],2)[1],o=Qg(eg.children(e,n,{reverse:!0}),1),i=Qg(o[0],2)[1];Yp.withoutNormalizing(e,function(){for(var r,o,a,s,u,l,c=new Map,d=[],h=1/0,f=-1/0,p=1/0,g=-1/0,m=0;m<t.length;m+=1)for(var v=0;v<t[m].length;v+=1){var y=Qg(t[m][v],2),b=Qg(y[0],2),D=b[0],C=b[1],w=y[1].ttb,E=C.join(",");if(1===w&&!c.has(E)){c.set(E,{path:C,x:m,y:v,element:D});var A=D.rowSpan,x=void 0===A?1:A,B=D.colSpan,S=m,F=m+x-1,k=v,O=v+(void 0===B?1:B)-1;h=Math.min(h,S),f=Math.max(f,F),p=Math.min(p,k),g=Math.max(g,O)}}var T=f-h+1,N=g-p+1;try{for(var P=Jg(c),M=P.next();!M.done;M=P.next()){C=Qg(M.value,2)[1].path;og.equals(n,C)||d.push(C)}}catch(e){r={error:e}}finally{try{M&&!M.done&&(o=P.return)&&o.call(P)}finally{if(r)throw r.error}}d.sort(function(e,t){for(var r=0;r<Math.min(e.length,t.length);r+=1)if(e[r]!==t[r])return t[r]-e[r];return t.length-e.length});try{for(var I=Jg(d),R=I.next();!R.done;R=I.next()){C=R.value;try{if(!Yp.hasPath(e,C))continue;try{for(var L=(u=void 0,Jg(eg.children(e,C,{reverse:!0}))),_=L.next();!_.done;_=L.next()){var z=Qg(_.value,2)[1];zg.moveNodes(e,{to:og.next(i),at:z})}}catch(e){u={error:e}}finally{try{_&&!_.done&&(l=L.return)&&l.call(L)}finally{if(u)throw u.error}}zg.removeNodes(e,{at:C})}catch(e){}}}catch(e){a={error:e}}finally{try{R&&!R.done&&(s=I.return)&&s.call(I)}finally{if(a)throw a.error}}zg.setNodes(e,{rowSpan:T,colSpan:N},{at:n})})}}},e}(),p_=function(){function e(){this.title=eC("tableModule.splitCell"),this.iconSvg='<svg viewBox="0 0 1024 1024"><path d="M362.667 494.933v53.334l25.6-25.6zm0-241.066L460.8 352V78.933H57.6v98.134h305.067zm0 535.466v57.6H57.6v98.134h403.2V691.2zM661.333 494.933v53.334l-25.6-25.6zm0-241.066L563.2 352V78.933h403.2v98.134H661.333zm0 535.466v57.6H966.4v98.134H563.2V691.2z"/><path d="M753.067 341.333 693.333 281.6 512 460.8 330.667 281.6l-59.734 59.733 181.334 181.334L270.933 704l59.734 59.733L512 582.4l181.333 181.333L753.067 704 571.733 522.667z"/></svg>',this.tag="button"}return e.prototype.getValue=function(e){return""},e.prototype.isActive=function(e){return!1},e.prototype.isDisabled=function(e){var t=Qg(Yp.nodes(e,{match:function(e){return Ry.checkNodeType(e,"table-cell")}}),1),r=t[0];if(!r)return!0;var n=Qg(r,1)[0],o=n.rowSpan,i=void 0===o?1:o,a=n.colSpan;return!(i>1||(void 0===a?1:a)>1)},e.prototype.exec=function(e,t){this.isDisabled(e)||this.split(e)},e.prototype.split=function(e,t){void 0===t&&(t={});var r=Qg(Yp.nodes(e,{match:GL(e,"table","th","td"),at:t.at}),2),n=r[0],o=r[1];if(n&&o){var i=u_(Qg(n,1)[0]),a=Qg(o,2),s=a[0],u=a[1],l=s.rowSpan,c=void 0===l?1:l,d=s.colSpan,h=void 0===d?1:d;1===c&&1===h||Yp.withoutNormalizing(e,function(){zg.setNodes(e,{rowSpan:1,colSpan:1},{at:u});for(var t=1;t<h;t+=1){var r={type:"table-cell",children:[{text:""}]};0===u[u.length-2]&&i&&(r.isHeader=!0);var n=u.slice(0,-1),o=u[u.length-1]+t,a=em(em([],Qg(n),!1),[o],!1);try{zg.insertNodes(e,r,{at:a})}catch(t){try{var s=Qg(Yp.node(e,n),1)[0].children.length,l=em(em([],Qg(n),!1),[s],!1);zg.insertNodes(e,r,{at:l})}catch(e){console.warn("插入同行单元格失败: ".concat(e instanceof Error?e.message:String(e)))}}}for(var d=1;d<c;d+=1){var f=u[u.length-2]+d,p=em(em([],Qg(u.slice(0,-2)),!1),[f],!1);try{var g=Qg(Yp.node(e,p),1)[0];if(!g){console.warn("目标行 ".concat(f," 不存在"));continue}for(t=0;t<h;t+=1){r={type:"table-cell",children:[{text:""}]},o=u[u.length-1]+t,a=em(em([],Qg(p),!1),[o],!1);try{var m=g.children.length;if(o>=m){var v=em(em([],Qg(p),!1),[m],!1);zg.insertNodes(e,r,{at:v})}else zg.insertNodes(e,r,{at:a})}catch(t){try{var y=g.children.length;l=em(em([],Qg(p),!1),[y],!1);zg.insertNodes(e,r,{at:l})}catch(e){console.warn("插入单元格到第".concat(d,"行失败: ").concat(e instanceof Error?e.message:String(e)))}}}}catch(e){console.warn("处理第".concat(d,"行时出错: ").concat(e instanceof Error?e.message:String(e)))}}})}},e}(),g_=function(){function e(){this.title=eC("tableModule.header"),this.iconSvg='<svg viewBox="0 0 1024 1024"><path d="M704 128l-64 0L384 128 320 128 0 128l0 256 0 64 0 192 0 64 0 256 320 0 64 0 256 0 64 0 320 0 0-256 0-64L1024 448 1024 384 1024 128 704 128zM640 640 384 640 384 448l256 0L640 640zM64 448l256 0 0 192L64 640 64 448zM320 896 64 896l0-192 256 0L320 896zM640 896 384 896l0-192 256 0L640 896zM960 896l-256 0 0-192 256 0L960 896zM960 640l-256 0L704 448l256 0L960 640z"></path></svg>',this.tag="button"}return e.prototype.getValue=function(e){var t=Ry.getSelectedNodeByType(e,"table");return null!=t&&u_(t)},e.prototype.isActive=function(e){return!!this.getValue(e)},e.prototype.isDisabled=function(e){var t=e.selection;return null==t||(!hg.isCollapsed(t)||null==Ry.getSelectedNodeByType(e,"table"))},e.prototype.exec=function(e,t){if(!this.isDisabled(e)){var r=!t,n=Ry.getSelectedNodeByType(e,"table");if(null!=n)s_(n).forEach(function(t){return zg.setNodes(e,{isHeader:r},{at:Ry.findPath(e,t)})})}},e}(),m_={key:"insertTable",factory:function(){return new d_}},v_={key:"deleteTable",factory:function(){return new i_}},y_={key:"insertTableRow",factory:function(){return new c_}},b_={key:"deleteTableRow",factory:function(){return new o_}},D_={key:"insertTableCol",factory:function(){return new l_}},C_={key:"deleteTableCol",factory:function(){return new n_}},w_={key:"tableHeader",factory:function(){return new g_}},E_={key:"tableFullWidth",factory:function(){return new a_}},A_={key:"mergeTableCell",factory:function(){return new f_}},x_={key:"splitTableCell",factory:function(){return new p_}},B_={key:"setTableProperty",factory:function(){return new t_}},S_={key:"setTableCellProperty",factory:function(){return new r_}};var F_={selector:"td:not([data-w-e-type]),th:not([data-w-e-type])",parseElemHtml:function(e,t,r){var n=ov(e);0===(t=t.filter(function(e){return"paragraph"===Ry.getNodeType(e)||(!!Cg.isText(e)||!!r.isInline(e))})).length&&(t=[{text:n.text().replace(/\s+/gm," ")}]);var o=parseInt(n.attr("colSpan")||"1",10),i=parseInt(n.attr("rowSpan")||"1",10),a="none"===JL(n,"display"),s=n.attr("width")||"auto";return{type:"table-cell",isHeader:"th"===ZL(n),colSpan:o,rowSpan:i,width:s,children:t,hidden:a}}};var k_={selector:"tr:not([data-w-e-type])",parseElemHtml:function(e,t,r){for(var n=[],o=0;o<t.length;o+=1){var i=t[o];if("table-cell"===Ry.getNodeType(i)){var a=i;if(a.hidden)continue;n.push(a)}}return{type:"table-row",children:n}}};var O_,T_={selector:"table:not([data-w-e-type])",parseElemHtml:function(e,t,r){var n,o,i=ov(e),a="auto";"100%"===JL(i,"width")&&(a="100%"),"100%"===i.attr("width")&&(a="100%");var s={type:"table",width:a,height:parseInt(JL(i,"height")||"0",10),children:t.filter(function(e){return"table-row"===Ry.getNodeType(e)})},u=(null===(n=i.find("tr")[0])||void 0===n?void 0:n.children)||[],l=(null===(o=i.find("colgroup")[0])||void 0===o?void 0:o.children)||null,c=t[t.length-1].children.length;if(l&&l.length===c)s.columnWidths=Array.from(l).map(function(e){return parseInt(e.getAttribute("width"),10)});else if(u.length>0){var d=[];Array.from(u).forEach(function(e){var t=parseInt(ov(e).attr("colSpan")||"1",10),r=parseInt(JL(ov(e),"width")||"90",10);d.push(r);for(var n=1;n<t;n+=1)d.push(90)}),s.columnWidths=d}return s}},N_=null===(O_=null===window||void 0===window?void 0:window.getComputedStyle(document.documentElement))||void 0===O_?void 0:O_.getPropertyValue("--w-e-textarea-border-color");function P_(e){var t=e.selection;if(null==t)return!1;var r=Qg(Yp.nodes(e,{match:function(e){return Ry.checkNodeType(e,"table-cell")}}),1),n=r[0];if(n){var o=Qg(n,2)[1],i=Yp.start(e,o);if(ug.equals(t.anchor,i))return!0}return!1}function M_(e,t){var r=t.offset;if(0===r)return!1;var n=Yp.node(e,t);if(!Cg.isText(n[0]))return!1;var o=eg.string(n[0]);return!(r>=o.length)&&("\n"===o[r-1]&&"\r"===o[r])}function I_(e,t,r){var n=e.selection;if(null==n||"line"===t)return!1;var o=Qg(Yp.nodes(e,{match:function(e){return Ry.checkNodeType(e,"table-cell")}}),1),i=o[0],a=n.anchor;if("backward"===r&&0===n.anchor.offset&&(a=Yp.before(e,n)),"forward"===r&&Yp.isEnd(e,n.anchor,n.anchor.path)&&(a=Yp.after(e,n)),null==a)return!1;var s=Yp.above(e,{at:a,match:function(e){return Ry.checkNodeType(e,"table-cell")}});if(null==s||null==i||!og.equals(s[1],i[1]))return!1;var u=Yp.node(e,a);if(!Cg.isText(u[0])||u[0].text.length<2)return!1;var l="backward"===r?[a.offset-2,a.offset]:[a.offset,a.offset+2],c=eg.string(u[0]);return"\n\r"===c.slice.apply(c,em([],Qg(l),!1))?(zg.insertText(e,c.slice(0,l[0])+c.slice(l[1]),{at:{anchor:Yp.start(e,a.path),focus:Yp.end(e,a.path)}}),!0):!!M_(e,a)&&(zg.insertText(e,c.slice(0,n.anchor.offset-1)+c.slice(n.anchor.offset+1),{at:{anchor:Yp.start(e,a.path),focus:Yp.end(e,a.path)}}),!0)}function R_(e,t){var r=Yp.nodes(e,{at:t,match:function(e){return"table"===Ry.getNodeType(e)}});return!!em([],Qg(r),!1).find(function(){return!0})}var L_={selector:"table",preParseHtml:function(e){var t=ov(e);if("table"!==ZL(t))return e;var r=t.find("tbody");if(0===r.length)return e;var n=t.find("tr");t.append(n),r.remove();for(var o=t.find("td, th"),i=0;i<o.length;i+=1){var a=(u=ov(o[i])).attr("style");if(a){/display\s*:\s*none/i.test(a)&&u.remove()}}var s=t.find("td, th");for(i=0;i<s.length;i+=1){var u,l=(u=ov(s[i])).html()||"";l=(l=(l=l.replace(/<o:p[^>]*>[\s\S]*?<\/o:p>/gi,"")).replace(/<\/o:p>/gi,"")).replace(/<p[^>]*>([\s\S]*?)<\/p>/gi,function(e,t){var r=t.trim();return r&&" "!==r?t:""}),u.html(l)}return t[0]}};function __(e){var t,r,n=[],o=0;try{for(var i=Jg(e),a=i.next();!a.done;a=i.next()){o+=a.value,n.push(o)}}catch(e){t={error:e}}finally{try{a&&!a.done&&(r=i.return)&&r.call(i)}finally{if(t)throw t.error}}return n}function z_(e){var t,r,n=[],o=e.reduce(function(e,t){return e+t},0);try{for(var i=Jg(e),a=i.next();!a.done;a=i.next()){var s=a.value;n.push(s/o)}}catch(e){t={error:e}}finally{try{a&&!a.done&&(r=i.return)&&r.call(i)}finally{if(t)throw t.error}}return n}var j_=null;var H_=!1,V_=!1,$_=0,U_=0,q_=null,W_=ov(window);function G_(e,t,r){var n=e.reduce(function(e,t){return e+t},0),o=e[t],i=Math.max(10,r),a=n-o+i;if(a<10*e.length)return e.map(function(){return 10});var s=n-o,u=a-i;if(u<=0){var l=e.map(function(){return 10});return l[t]=Math.max(10,a-10*(e.length-1)),l}var c=s>0?u/s:1,d=e.map(function(e,r){if(r===t)return Math.floor(100*i)/100;var n=e*c;return Math.max(10,Math.floor(100*n)/100)}),h=d.reduce(function(e,t){return e+t},0),f=a-h;return Math.abs(f)>.01&&(d[t]=Math.max(10,d[t]+f)),d}W_.on("mousedown",function(e){var t=e.target;if(t.closest('[data-block-type="table-cell"]'))H_=!0;else if("DIV"===t.tagName&&t.closest(".column-resizer-item")){if(null===q_)return;var r=Qg(Yp.nodes(q_,{match:GL(q_,"table")}),1),n=Qg(r[0],1)[0],o=n.columnWidths,i=void 0===o?[]:o,a=n.resizingIndex,s=void 0===a?-1:a;V_=!0;var u=e.clientX;$_=u,U_=i[s],document.body.style.cursor="col-resize",e.preventDefault()}W_.on("mousemove",Y_),W_.on("mouseup",K_)});var Y_=BC(function(e){if(V_&&null!==q_){e.preventDefault();var t,r=e.clientX,n=r-$_,o=Qg(Yp.nodes(q_,{match:GL(q_,"table")}),1),i=Qg(o[0],1)[0],a=i.columnWidths,s=void 0===a?[]:a,u=i.resizingIndex,l=void 0===u?-1:u,c=l===s.length-1;if(c){t=G_(s,l,U_+n)}else{var d=document.querySelector(".table");if(d)t=function(e,t,r,n){var o=em([],Qg(e),!1);if(t<0||t>=e.length)return o;var i=0===t?0:n[t-1],a=i+10,s=(t+1<e.length?n[t+1]:n[t])-10,u=Math.max(a,Math.min(s,r))-i,l=t+1;if(l<e.length){var c=e[t]+e[l]-u;o[t]=Math.floor(100*u)/100,o[l]=Math.floor(100*c)/100}return o}(s,l,r-d.getBoundingClientRect().left,__(s));else t=function(e,t,r){var n=em([],Qg(e),!1),o=t+1;if(o>=n.length)return n;var i=n[t],a=n[o],s=i+a-10,u=i+r,l=i+a-(u=Math.max(10,Math.min(s,u)));return n[t]=Math.floor(100*u)/100,n[o]=Math.floor(100*l)/100,n}(s,l,n)}if(c){var h=document.querySelector(".table-container");if(h){var f=t.reduce(function(e,t){return e+t},0),p=10*s.length,g=h.clientWidth-1;if(f<p)t=s.map(function(){return 10});else if(f>g){var m=t.slice(0,-1).reduce(function(e,t){return e+t},0),v=(t=G_(s,l,Math.max(10,g-m))).reduce(function(e,t){return e+t},0);if(v>g){var y=g/v;t=t.map(function(e){return Math.max(10,Math.floor(e*y*100)/100)})}}}}zg.setNodes(q_,{columnWidths:t},{mode:"highest"})}},100);function K_(e){H_=!1,V_=!1,q_=null,document.body.style.cursor="",W_.off("mousemove",Y_),W_.off("mouseup",K_)}function X_(e,t){"mouseenter"===t.type?zg.setNodes(e,{isResizing:!0},{mode:"highest"}):zg.setNodes(e,{isResizing:!1},{mode:"highest"})}var Z_={type:"table",renderElem:function(e,t,r){var n=function(e,t){if(e.isDisabled())return!1;var r=e.selection;if(null==r)return!0;if(hg.isCollapsed(r))return!0;var n=r.anchor,o=r.focus,i=Ry.findPath(e,t),a=Yp.start(e,i),s=Yp.end(e,i),u=ug.compare(n,s)<=0&&ug.compare(n,a)>=0,l=ug.compare(o,s)<=0&&ug.compare(o,a)>=0;return!!(u&&l&&og.equals(n.path.slice(0,3),o.path.slice(0,3)))}(r,e),o=e,i=o.width,a=void 0===i?"auto":i,s=o.height,u=o.columnWidths,l=void 0===u?[]:u,c=o.scrollWidth,d=void 0===c?0:c,h=o.isHoverCellBorder,f=o.resizingIndex,p=o.isResizing,g=Ry.isNodeSelected(r,e),m=Qg(h_.selection(r),1)[0],v=z_(l),y=Tw("div",{className:"table-container","data-selected":g,on:{mousedown:function(t){if("DIV"===t.target.tagName&&t.preventDefault(),!r.isDisabled()){t.target.closest('[data-block-type="table-cell"]')&&h_.unselect(r);var n=Ry.findPath(r,e),o=Yp.start(r,n),i=r.selection;if(null!=i)i.anchor.path[0]!==n[0]&&"DIV"===t.target.tagName&&r.select(o);else r.select(o)}}}},Tw("table",{width:a,contentEditable:n,className:"table ".concat(m?"table-selection-none":""),style:{width:"100%"===a?a:"".concat(l.reduce(function(e,t){return e+t},0),"px")},on:{mousemove:oD(function(t){return function(e,t,r,n){if(!e.isDisabled()&&!H_&&!V_){var o=t,i=o.width,a=void 0===i?"auto":i,s=o.columnWidths,u=void 0===s?[]:s,l=o.isHoverCellBorder,c=o.resizingIndex,d=r.clientX,h=r.target;if(Uv(h)&&d>(g=h.getBoundingClientRect()).x+5&&d<g.x+g.width-5)return void(l&&zg.setNodes(e,{isHoverCellBorder:!1,resizingIndex:-1},{mode:"highest"}));if(Uv(h)){var f=h.closest(".table");if(f)for(var p=r.clientX,g=f.getBoundingClientRect(),m="100%"===a?z_(u).map(function(e){return e*n}):u,v=__(m),y=0;y<v.length;y+=1)if(p-g.x>=v[y]-5&&p-g.x<v[y]+5){if(c===y)return;return void zg.setNodes(e,{isHoverCellBorder:!0,resizingIndex:y},{mode:"highest"})}}!0===l&&zg.setNodes(e,{isHoverCellBorder:!1,resizingIndex:-1},{mode:"highest"})}}(r,e,t,d)},25)}},Tw("colgroup",{contentEditable:!1},l.map(function(e){return Tw("col",{width:e})})),Tw("tbody",null,t)),Tw("div",{className:"column-resizer",contentEditable:!1},l.map(function(e,t){var n=e;return"100%"===a&&(n=v[t]*d),Tw("div",{className:"column-resizer-item",style:{minWidth:"".concat(n,"px")}},Tw("div",{className:"resizer-line-hotzone ".concat(h&&t===f?"visible ":"").concat(p&&t===f?"highlight":""),style:{height:"".concat(s,"px")},on:{mouseenter:function(e){return X_(r,e)},mouseleave:function(e){return X_(r,e)},mousedown:function(e){return function(e){V_||(q_=e)}(r)}}},Tw("div",{className:"resizer-line"})))}))),b=dw("div",{hook:{insert:function(e){var t=e.elm;return function(e,t){if(Uv(t)){var r=t.querySelector("table");r&&(j_=new ResizeObserver(function(t){var r=Qg(t,1)[0].contentRect;zg.setNodes(e,{scrollWidth:r.width,height:r.height},{mode:"highest"})}),j_.observe(r))}}(r,t)},destroy:function(){j_&&(null==j_||j_.disconnect(),j_=null)}}},y);return b}},J_={type:"table-row",renderElem:function(e,t,r){return Tw("tr",null,t)}},Q_={type:"table-cell",renderElem:function(e,t,r){var n=function(e,t){var r=Ry.getParentNode(e,t);if(null==r)return!1;var n=Ry.getParentNode(e,r);return null!=n&&s_(n).some(function(e){return e===t})}(r,e),o=e,i=o.colSpan,a=void 0===i?1:i,s=o.rowSpan,u=void 0===s?1:s,l=o.isHeader,c=void 0!==l&&l,d=o.hidden,h=void 0!==d&&d,f=h_.isSelected(r,e);return Tw(n&&c?"th":"td",{colSpan:a,rowSpan:u,"data-block-type":"table-cell",className:f?"w-e-selected":"",style:{display:h?"none":""}},t)}};function ez(e,t){null==e.data&&(e.data={});var r=e.data;null==r.style&&(r.style={}),Object.assign(r.style,t)}var tz={renderStyle:function(e,t){var r,n;if(!Vp.isElement(e))return t;var o=e,i=o.backgroundColor,a=o.borderWidth,s=o.borderStyle,u=o.borderColor,l=o.textAlign,c={};i&&(c.backgroundColor=i),a&&(c.borderWidth="".concat(a,"px")),s&&(c.borderStyle="none"===s?"":s),u&&(c.borderColor=u),l&&(c.textAlign=l);var d=t;return"table"===e.type?ez(null===(n=(null===(r=d.children)||void 0===r?void 0:r[0]).children)||void 0===n?void 0:n[0],c):ez(d,c),d},styleToHtml:function(e,t){if("table"!==e.type&&"table-cell"!==e.type)return t;var r=e.backgroundColor,n=e.borderWidth,o=e.borderStyle,i=e.borderColor,a=e.textAlign;if(!(r||n||o||i||a))return t;var s=ov(t);return r&&s.css("background-color",r),n&&s.css("border-width","".concat(n,"px")),o&&s.css("border-style","none"===o?"":o),i&&s.css("border-color",i),a&&s.css("text-align",a),function(e){return 0===e.length?"":e[0].outerHTML}(s)},parseStyleHtml:function(e,t,r){if(!["TABLE","TD","TH"].includes(e.tagName))return t;var n=ov(e),o=t,i=JL(n,"background-color");i||(i=JL(n,"background")),i&&(o.backgroundColor=i);var a=JL(n,"border");a||"TD"!==e.tagName||(a="1px solid ".concat(N_));var s=Qg((null==a?void 0:a.split(" "))||[],3),u=s[0],l=s[1],c=s[2];(u=JL(n,"border-width")||u)&&(o.borderWidth=u.replace(/[^\d]/g,"")),(l=JL(n,"border-style")||l)&&(o.borderStyle="none"===l?"":l),(c=JL(n,"border-color")||c)&&(o.borderColor=c);var d=JL(n,"text-align");return(d=JL(n,"text-align")||d)&&(o.textAlign=d),t},renderElems:[Z_,J_,Q_],elemsToHtml:[VL,$L,UL],preParseHtml:[L_],parseElemsHtml:[F_,k_,T_],menus:[m_,v_,y_,b_,D_,C_,w_,E_,A_,x_,B_,S_],editorPlugin:function(e){var t=e.insertBreak,r=e.deleteBackward,n=e.deleteForward,o=e.deleteFragment,i=e.normalizeNode,a=e.insertData,s=e.handleTab,u=e.selectAll,l=e;l.insertBreak=function(){null==Ry.getSelectedNodeByType(l,"table")?t():l.insertText("\n\r")},l.deleteBackward=function(e){if(!P_(l)&&!I_(l,e,"backward")){var t=l.selection;if(t){var n=Yp.before(l,t),o=Yp.above(l,{at:t,match:function(e){return Ry.checkNodeType(e,"table-cell")}});if(n){var i=R_(l,n);if(!o&&i&&Ry.getSelectedNodeByType(l,"paragraph"))return}}r(e)}},l.handleTab=function(){var t;if(Ry.getSelectedNodeByType(l,"table")){var r=Yp.above(e);Ry.checkNodeType(r[0],"table-cell")&&zg.select(e,r[1]);var n=Yp.next(e);if(n)n[0]&&n[0].text&&(n=null!==(t=Yp.above(e,{at:n[1]}))&&void 0!==t?t:n),zg.select(e,n[1]);else{var o=l.children||[],i=o.length;if(Ry.checkNodeType(o[i-1],"table")){var a=Ry.genEmptyParagraph();zg.insertNodes(l,a,{at:[i]}),l.handleTab()}}}else s()},l.deleteForward=function(e){if(!P_(l)&&!I_(l,e,"forward")){var t=l.selection;if(t){var r=Yp.after(l,t),o=Yp.above(l,{at:t,match:function(e){return Ry.checkNodeType(e,"table-cell")}});if(r){var i=R_(l,r);if(!o&&i&&Ry.getSelectedNodeByType(l,"paragraph"))return}}n(e)}},l.deleteFragment=function(e){var t=l.selection;if(t){var r,n=!1,i={anchor:t.anchor,focus:t.focus},a=ug.isBefore(i.anchor,i.focus);if(M_(l,t.anchor))(r=Yp[a?"before":"after"](l,t.anchor))&&(i.anchor=r),n=!0;if(M_(l,t.focus))(r=Yp[a?"after":"before"](l,t.focus))&&(i.focus=r),n=!0;n&&zg.setSelection(l,i),o(e)}},l.normalizeNode=function(e){var t=Qg(e,2),r=t[0],n=t[1];if("table"!==Ry.getNodeType(r))return i([r,n]);if(Ry.isLastNode(l,r)){var o=Ry.genEmptyParagraph();zg.insertNodes(l,o,{at:[n[0]+1]})}},l.insertData=function(e){if(null!=Ry.getSelectedNodeByType(l,"table")){var t=e.getData("text/plain");"\n"===t||/<img[^>]+>/.test(e.getData("text/html"))?a(e):Yp.insertText(l,t)}else a(e)},l.selectAll=function(){var e=l.selection;if(null!=e){var t=Ry.getSelectedNodeByType(l,"table-cell");if(null!=t){var r=e.anchor,n=e.focus;if(og.equals(r.path.slice(0,3),n.path.slice(0,3)))if(0!==eg.string(t).length){var o=Ry.findPath(l,t),i={anchor:Yp.start(l,o),focus:Yp.end(l,o)};l.select(i)}else u();else u()}else u()}else u()},function(e){var t=e.apply;e.apply=function(r){if(!ng.isSelectionOperation(r)||!r.newProperties)return t(r);var n=Kg(Kg({},e.selection),r.newProperties);if(!hg.isRange(n))return h_.unselect(e),t(r);var o=function(e){return Vp.isElement(e)&&("table-cell"===e.type||"th"===e.type||"td"===e.type)},i=Qg(Yp.nodes(e,{match:o,at:hg.start(n),mode:"lowest"}),1)[0],a=Qg(Yp.nodes(e,{match:o,at:hg.end(n),mode:"lowest"}),1)[0];if(!i||!a)return h_.unselect(e),t(r);var s=Qg(i,2)[1],u=Qg(a,2)[1];if(og.equals(s,u)||!YL(e,[s,u],"table"))return h_.unselect(e),t(r);try{var l=KL(e,{at:s});if(!l||0===l.length)return h_.unselect(e),t(r);for(var c=XL.valueOf(0,0),d=XL.valueOf(0,0),h=!1,f=!1,p=0;p<l.length;p+=1)if(l[p])for(var g=0;g<l[p].length;g+=1)if(l[p][g]){var m=Qg(l[p][g],1),v=Qg(m[0],2)[1];og.equals(s,v)&&(c.x=p,c.y=g,h=!0),og.equals(u,v)&&(d.x=p,d.y=g,f=!0)}if(!h||!f)return h_.unselect(e),t(r);for(var y=XL.valueOf(Math.min(c.x,d.x),Math.min(c.y,d.y)),b=XL.valueOf(Math.max(c.x,d.x),Math.max(c.y,d.y));;){var D=XL.valueOf(y.x,y.y),C=XL.valueOf(b.x,b.y);for(p=D.x;p<=C.x&&p<l.length;p+=1)if(l[p])for(g=D.y;g<=C.y&&g<l[p].length;g+=1)if(l[p][g]){var w=Qg(l[p][g],2)[1];if(w){var E=w.rtl,A=w.ltr,x=w.btt,B=w.ttb;D.x=Math.min(D.x,p-(B-1)),D.y=Math.min(D.y,g-(E-1)),C.x=Math.max(C.x,p+(x-1)),C.y=Math.max(C.y,g+(A-1))}}if(XL.equals(y,D)&&XL.equals(b,C))break;y=D,b=C}var S=[],F=new WeakSet;for(p=y.x;p<=b.x&&p<l.length;p+=1)if(l[p]){var k=[];for(g=y.y;g<=b.y&&g<l[p].length;g+=1)if(l[p][g]){var O=Qg(l[p][g],1),T=Qg(O[0],1)[0];T&&(F.add(T),k.push(l[p][g]))}k.length>0&&S.push(k)}QL.set(e,S),e_.set(e,F)}catch(n){return h_.unselect(e),t(r)}t(r)}}(l),l.getTableSelection=function(){return QL.get(l)||null};var c=l.addMark,d=l.removeMark,h=Kg({},zg);return l.addMark=function(e,t){var r=QL.get(l);if(r&&r.length>0){var n=l.selection;r.forEach(function(r){r.forEach(function(r){var n=Qg(r[0],2)[1],o=Yp.start(l,n),i=Yp.end(l,n);zg.select(l,{anchor:o,focus:i}),c(e,t)})}),n&&zg.select(l,n)}else c(e,t)},l.removeMark=function(e){var t=QL.get(l);if(t&&t.length>0){var r=l.selection;t.forEach(function(t){t.forEach(function(t){var r=Qg(t[0],2)[1],n=Yp.start(l,r),o=Yp.end(l,r);zg.select(l,{anchor:n,focus:o}),d(e)})}),r&&zg.select(l,r)}else d(e)},zg.setNodes=function(e,t,r){if(void 0===r&&(r={}),e===l){var n=QL.get(l);if(n&&n.length>0)return"hidden"in t||"rowSpan"in t||"colSpan"in t?void h.setNodes(e,t,r):void n.forEach(function(n){n.forEach(function(n){var o=Qg(n[0],2)[1];h.setNodes(e,t,Kg(Kg({},r),{at:o}))})})}h.setNodes(e,t,r)},l}};XD("en",{uploadImgModule:{uploadImage:"Upload Image",uploadError:"{{fileName}} upload error"}}),XD("zh-CN",{uploadImgModule:{uploadImage:"上传图片",uploadError:"{{fileName}} 上传出错"}});Bv&&(ov.fn.append=Bv),fv&&(ov.fn.on=fv),Nv&&(ov.fn.remove=Nv),hv&&(ov.fn.val=hv),Rv&&(ov.fn.click=Rv),yv&&(ov.fn.hide=yv);var rz=new WeakMap;function nz(e){return e.getMenuConfig("uploadImage")}function oz(e,t){return Xg(this,void 0,void 0,function(){return Zg(this,function(r){return[2,new Promise(function(r){var n=new FileReader;n.readAsDataURL(t),n.onload=function(){var o=n.result;if(o){var i=o.toString(),a=0===i.indexOf("data:image")?"":i;YS(e,i,t.name,a),r("ok")}}})]})})}function iz(e,t){return Xg(this,void 0,void 0,function(){var r,n;return Zg(this,function(o){switch(o.label){case 0:return r=function(e){var t=rz.get(e);if(null!=t)return t;var r=nz(e),n=r.onSuccess,o=r.onProgress,i=r.onFailed,a=r.customInsert,s=r.onError;return t=Yx(Kg(Kg({},r),{onProgress:function(t){e.showProgressBar(t),o&&o(t)},onSuccess:function(t,r){if(a)return a(r,function(t,r,n){return YS(e,t,r,n)}),void n(t,r);var o=r.errno,s=void 0===o?1:o,u=r.data,l=void 0===u?{}:u;if(0===s){if(Array.isArray(l))l.forEach(function(t){var r=t.url,n=void 0===r?"":r,o=t.alt,i=void 0===o?"":o,a=t.href;YS(e,n,i,void 0===a?"":a)});else{var c=l.url,d=void 0===c?"":c,h=l.alt,f=void 0===h?"":h,p=l.href;YS(e,d,f,void 0===p?"":p)}n(t,r)}else i(t,r)},onError:function(e,t,r){s(e,t,r)}})),rz.set(e,t),t}(e),n=t.map(function(e){return{name:e.name,type:e.type,size:e.size,data:e}}),r.addFiles(n),[4,r.upload()];case 1:return o.sent(),[2]}})})}function az(e,t){return Xg(this,void 0,void 0,function(){var r,n,o,i,a,s,u,l,c,d,h,f,p,g,m;return Zg(this,function(v){switch(v.label){case 0:if(null==t)return[2];r=Array.prototype.slice.call(t),n=nz(e),o=n.customUpload,i=n.base64LimitSize,a=[],v.label=1;case 1:v.trys.push([1,10,11,16]),s=!0,u=tm(r),v.label=2;case 2:return[4,u.next()];case 3:return l=v.sent(),(f=l.done)?[3,9]:(m=l.value,s=!1,d=(c=m).size,i&&d<=i?[4,oz(e,c)]:[3,5]);case 4:return v.sent(),[3,8];case 5:return o?[4,o(c,function(t,r,n){return YS(e,t,r,n)})]:[3,7];case 6:return v.sent(),[3,8];case 7:a.push(c),v.label=8;case 8:return s=!0,[3,2];case 9:return[3,16];case 10:return h=v.sent(),p={error:h},[3,16];case 11:return v.trys.push([11,,14,15]),s||f||!(g=u.return)?[3,13]:[4,g.call(u)];case 12:v.sent(),v.label=13;case 13:return[3,15];case 14:if(p)throw p.error;return[7];case 15:return[7];case 16:return a.length>0?[4,iz(e,a)]:[3,18];case 17:v.sent(),v.label=18;case 18:return[2]}})})}var sz=function(){function e(){this.title=eC("uploadImgModule.uploadImage"),this.iconSvg='<svg viewBox="0 0 1024 1024"><path d="M828.708571 585.045333a48.761905 48.761905 0 0 0-48.737523 48.761905v18.529524l-72.143238-72.167619a135.972571 135.972571 0 0 0-191.585524 0l-34.133334 34.133333-120.880762-120.953905a138.898286 138.898286 0 0 0-191.585523 0l-72.167619 72.167619V292.400762a48.786286 48.786286 0 0 1 48.761904-48.761905h341.23581a48.737524 48.737524 0 0 0 34.474667-83.285333 48.737524 48.737524 0 0 0-34.474667-14.287238H146.236952A146.212571 146.212571 0 0 0 0 292.400762v585.289143A146.358857 146.358857 0 0 0 146.236952 1024h584.996572a146.212571 146.212571 0 0 0 146.236952-146.310095V633.807238a48.786286 48.786286 0 0 0-48.761905-48.761905zM146.261333 926.45181a48.737524 48.737524 0 0 1-48.761904-48.761905v-174.128762l141.409523-141.458286a38.497524 38.497524 0 0 1 53.126096 0l154.526476 154.624 209.627428 209.724953H146.236952z m633.734096-48.761905c-0.073143 9.337905-3.145143 18.383238-8.777143 25.843809l-219.843048-220.94019 34.133333-34.133334a37.546667 37.546667 0 0 1 53.613715 0l140.873143 141.897143V877.714286zM1009.615238 160.231619L863.329524 13.897143a48.737524 48.737524 0 0 0-16.091429-10.24c-11.849143-4.87619-25.161143-4.87619-37.059047 0a48.761905 48.761905 0 0 0-16.067048 10.24l-146.236952 146.334476a49.005714 49.005714 0 0 0 69.217523 69.241905l62.902858-63.390476v272.627809a48.761905 48.761905 0 1 0 97.475047 0V166.083048l62.902857 63.390476a48.737524 48.737524 0 0 0 69.217524 0 48.761905 48.761905 0 0 0 0-69.241905z"></path></svg>',this.tag="button"}return e.prototype.getValue=function(e){return""},e.prototype.isActive=function(e){return!1},e.prototype.isDisabled=function(e){return qS(e)},e.prototype.getMenuConfig=function(e){return e.getMenuConfig("uploadImage")},e.prototype.exec=function(e,t){var r=this.getMenuConfig(e),n=r.allowedFileTypes,o=void 0===n?[]:n,i=r.customBrowseAndUpload;if(i)i(function(t,r,n){return YS(e,t,r,n)});else{var a="";o.length>0&&(a='accept="'.concat(o.join(", "),'"'));var s=ov("body"),u=ov('<input type="file" '.concat(a," multiple/>"));u.hide(),s.append(u),u.click(),u.on("change",function(){var t=u[0].files;az(e,t)})}},e}();var uz={menus:[{key:"uploadImage",factory:function(){return new sz},config:{server:"",fieldName:"wangeditor-uploaded-image",maxFileSize:2097152,maxNumberOfFiles:100,allowedFileTypes:["image/*"],meta:{},metaWithUrl:!1,withCredentials:!1,timeout:1e4,onBeforeUpload:function(e){return e},onProgress:function(e){},onSuccess:function(e,t){},onFailed:function(e,t){console.error("'".concat(e.name,"' upload failed"),t)},onError:function(e,t,r){console.error("'".concat(e.name,"' upload error"),r)},base64LimitSize:0}}],editorPlugin:function(e){var t=e.insertData,r=e;return r.insertData=function(n){if(qS(r))t(n);else if(n.getData("text/plain"))t(n);else{var o=n.files;if(o.length<=0)t(n);else Array.prototype.slice.call(o).some(function(e){return"image"===Qg(e.type.split("/"),1)[0]})?az(e,o):t(n)}},r}};function lz(e){return e.length?e[0].tagName.toLowerCase():""}function cz(e,t,r,n){void 0===t&&(t="auto"),void 0===r&&(r="auto"),void 0===n&&(n={});var o=ov(e),i=n.width,a=void 0===i?"":i,s=n.height,u=void 0===s?"":s,l="";return a&&(l+="width: ".concat(a,";")),u&&(l+="height: ".concat(u,";")),o.attr("width",t),o.attr("height",r),o.attr("style",l),o[0].outerHTML}XD("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",edit:"Edit video",width:"Width",height:"Height"}}),XD("zh-CN",{videoModule:{delete:"删除视频",uploadVideo:"上传视频",insertVideo:"插入视频",videoSrc:"视频地址",videoSrcPlaceHolder:"视频文件 url 或第三方 <iframe>",videoPoster:"视频封面",videoPosterPlaceHolder:"封面图片 url",ok:"确定",editSize:"修改尺寸",edit:"编辑视频",width:"宽度",height:"高度"}}),Bv&&(ov.fn.append=Bv),fv&&(ov.fn.on=fv),Lv&&(ov.fn.focus=Lv),uv&&(ov.fn.attr=uv),hv&&(ov.fn.val=hv),Ev&&(ov.fn.html=Ev),Fv&&(ov.fn.parent=Fv),sv&&(ov.fn.hasClass=sv),Pv&&(ov.fn.empty=Pv);var dz={type:"video",elemToHtml:function(e,t){var r=e,n=r.src,o=void 0===n?"":n,i=r.poster,a=void 0===i?"":i,s=r.width,u=void 0===s?"auto":s,l=r.height,c=void 0===l?"auto":l,d=r.style,h=void 0===d?{}:d,f=r.textAlign,p='<div data-w-e-type="video" data-w-e-is-void style="text-align: '.concat(void 0===f?"center":f,';">\n');if(0===o.trim().indexOf("<iframe ")){p+=cz(o,u,c,h)}else{var g=h.width,m=void 0===g?"":g,v=h.height,y=void 0===v?"":v,b="";m&&(b+="width: ".concat(m,";")),y&&(b+="height: ".concat(y,";")),p+='<video poster="'.concat(a,'" controls="true" width="').concat(u,'" height="').concat(c,'" style="').concat(b,'"><source src="').concat(o,'" type="video/mp4"/></video>')}return p+="\n</div>"}};function hz(e){return void 0===e&&(e="r"),"".concat(e,"-").concat(zv())}function fz(e){var t={};return e.trim().split(";").forEach(function(e){if(e){var r=Qg(e.split(":"),2),n=r[0],o=r[1];n&&o&&(t[n.trim()]=o.trim())}}),t}function pz(){return hz("w-e-insert-video")}var gz=function(){function e(){this.title=eC("videoModule.editSize"),this.tag="button",this.showModal=!0,this.modalWidth=320,this.$content=null,this.widthInputId=pz(),this.heightInputId=pz(),this.buttonId=pz()}return e.prototype.getSelectedVideoNode=function(e){return Ry.getSelectedNodeByType(e,"video")},e.prototype.getValue=function(e){return""},e.prototype.isActive=function(e){return!1},e.prototype.exec=function(e,t){},e.prototype.isDisabled=function(e){return null==e.selection||null==this.getSelectedVideoNode(e)},e.prototype.getModalPositionNode=function(e){return this.getSelectedVideoNode(e)},e.prototype.getModalContentElem=function(e){var t=this,r=t.widthInputId,n=t.heightInputId,o=t.buttonId,i=Qg(dC(eC("videoModule.width"),r,"auto"),2),a=i[0],s=ov(i[1]),u=Qg(dC(eC("videoModule.height"),n,"auto"),2),l=u[0],c=ov(u[1]),d=Qg(fC(o,eC("videoModule.ok")),1)[0],h=this.getSelectedVideoNode(e);if(null==this.$content){var f=ov("<div></div>");f.on("click","#".concat(o),function(t){t.preventDefault();var o=f.find("#".concat(r)).val().trim(),i=f.find("#".concat(n)).val().trim(),a=function(e){return/^\d+(\.\d+)?%$/.test(e)},s=function(e){return/^\d+(\.\d+)?$/.test(e)},u="auto",l="auto";a(o)?u=o:s(o)&&(u="".concat(parseInt(o,10),"px")),a(i)?l=i:s(i)&&(l="".concat(parseInt(i,10),"px"));var c=h.style,d=void 0===c?{}:c;e.restoreSelection();var p={style:Kg(Kg({},d),{width:u,height:l})};zg.setNodes(e,p,{match:function(e){return Ry.checkNodeType(e,"video")}}),e.hidePanelOrModal()}),this.$content=f}var p=this.$content;if(p.empty(),p.append(a),p.append(l),p.append(d),null==h)return p[0];var g=h.style,m=void 0===g?{}:g,v=m.width,y=void 0===v?"":v,b=m.height,D=void 0===b?"":b;return s.val(y),c.val(D),setTimeout(function(){s.focus()}),p[0]},e}();function mz(){return hz("w-e-edit-video")}var vz=function(){function e(){this.title=eC("videoModule.edit"),this.iconSvg='<svg viewBox="0 0 1024 1024"><path d="M864 0a160 160 0 0 1 128 256l-64 64-224-224 64-64c26.752-20.096 59.968-32 96-32zM64 736l-64 288 288-64 592-592-224-224L64 736z m651.584-372.416l-448 448-55.168-55.168 448-448 55.168 55.168z"></path></svg>',this.tag="button",this.showModal=!0,this.modalWidth=300,this.$content=null,this.srcInputId=mz(),this.posterInputId=mz(),this.buttonId=mz()}return e.prototype.getSelectedVideoNode=function(e){return Ry.getSelectedNodeByType(e,"video")},e.prototype.getValue=function(e){return""},e.prototype.isActive=function(e){return!1},e.prototype.exec=function(e,t){},e.prototype.isDisabled=function(e){return null==e.selection||null==this.getSelectedVideoNode(e)},e.prototype.getModalPositionNode=function(e){return this.getSelectedVideoNode(e)},e.prototype.getModalContentElem=function(e){var t=this,r=this,n=r.srcInputId,o=r.posterInputId,i=r.buttonId,a=Qg(dC(eC("videoModule.videoSrc"),n,eC("videoModule.videoSrcPlaceHolder")),2),s=a[0],u=a[1],l=Qg(dC(eC("videoModule.videoPoster"),o,eC("videoModule.videoPosterPlaceHolder")),2),c=l[0],d=l[1],h=ov(u),f=ov(d),p=Qg(fC(i,eC("videoModule.ok")),1)[0];if(null==this.$content){var g=ov("<div></div>");g.on("click","#".concat(i),function(r){return Xg(t,void 0,void 0,function(){var t,i,a,s;return Zg(this,function(u){return r.preventDefault(),t=g.find("#".concat(n)).val().trim(),i=g.find("#".concat(o)).val().trim(),a=hz("video-"),s={src:t,poster:i,key:a},e.restoreSelection(),zg.setNodes(e,s,{match:function(e){return Ry.checkNodeType(e,"video")}}),e.hidePanelOrModal(),[2]})})}),this.$content=g}var m=this.$content;m.empty(),m.append(s),m.append(c),m.append(p);var v=this.getSelectedVideoNode(e);if(null==v)return m[0];var y=v.src,b=void 0===y?"":y,D=v.poster,C=void 0===D?"":D;return h.val(b),f.val(C),setTimeout(function(){h.focus()}),m[0]},e}();function yz(e,t){return Xg(this,arguments,void 0,function(e,t,r,n,o){var i,a,s,u,l,c,d;return void 0===r&&(r=""),void 0===n&&(n=""),void 0===o&&(o=""),Zg(this,function(h){switch(h.label){case 0:return t?(e.restoreSelection(),i=e.getMenuConfig("insertVideo"),a=i.onInsertedVideo,s=i.checkVideo,u=i.parseVideoSrc,[4,s(t,r)]):[2];case 1:return"string"==typeof(l=h.sent())?(e.alert(l,"error"),[2]):null==l?[2]:[4,u(t)];case 2:return 0!==(c=h.sent()).trim().indexOf("<iframe ")&&(c=function(e){return e.replace(/</g,"<").replace(/>/g,">")}(c)),d={type:"video",src:c,poster:r,children:[{text:""}],style:{width:n,height:o}},Promise.resolve().then(function(){Ry.isSelectedEmptyParagraph(e)&&zg.removeNodes(e,{mode:"highest"}),zg.insertNodes(e,d,{mode:"highest"})}),a(d),[2]}})})}function bz(){return hz("w-e-insert-video")}var Dz=function(){function e(){this.title=eC("videoModule.insertVideo"),this.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>',this.tag="button",this.showModal=!0,this.modalWidth=320,this.$content=null,this.srcInputId=bz(),this.posterInputId=bz(),this.buttonId=bz()}return e.prototype.getValue=function(e){return""},e.prototype.isActive=function(e){return!1},e.prototype.exec=function(e,t){},e.prototype.isDisabled=function(e){var t=e.selection;return null==t||(!hg.isCollapsed(t)||!!Ry.getSelectedElems(e).some(function(t){var r=Ry.getNodeType(t);return"pre"===r||("list-item"===r||!!e.isVoid(t))}))},e.prototype.getModalPositionNode=function(e){return null},e.prototype.getModalContentElem=function(e){var t=this,r=this,n=r.srcInputId,o=r.posterInputId,i=r.buttonId,a=Qg(dC(eC("videoModule.videoSrc"),n,eC("videoModule.videoSrcPlaceHolder")),2),s=a[0],u=a[1],l=Qg(dC(eC("videoModule.videoPoster"),o,eC("videoModule.videoPosterPlaceHolder")),2),c=l[0],d=l[1],h=ov(u),f=ov(d),p=Qg(fC(i,eC("videoModule.ok")),1)[0];if(null==this.$content){var g=ov("<div></div>");g.on("click","#".concat(i),function(r){return Xg(t,void 0,void 0,function(){var t,i;return Zg(this,function(a){switch(a.label){case 0:return r.preventDefault(),t=g.find("#".concat(n)).val().trim(),i=g.find("#".concat(o)).val().trim(),[4,yz(e,t,i)];case 1:return a.sent(),e.hidePanelOrModal(),[2]}})})}),this.$content=g}var m=this.$content;return m.empty(),m.append(s),m.append(c),m.append(p),h.val(""),f.val(""),setTimeout(function(){h.focus()}),m[0]},e}();function Cz(e){return e.getMenuConfig("uploadVideo")}var wz=new WeakMap;function Ez(e,t){return Xg(this,void 0,void 0,function(){var r,n;return Zg(this,function(o){switch(o.label){case 0:return r=function(e){var t=wz.get(e);if(null!=t)return t;var r=Cz(e),n=r.onSuccess,o=r.onProgress,i=r.onFailed,a=r.customInsert,s=r.onError;return t=Yx(Kg(Kg({},r),{onProgress:function(t){e.showProgressBar(t),o&&o(t)},onSuccess:function(t,r){if(a)return a(r,function(t,r){return yz(e,t,r)}),void n(t,r);var o=r.errno,s=void 0===o?1:o,u=r.data,l=void 0===u?{}:u;if(0===s){var c=l.url,d=void 0===c?"":c,h=l.poster;yz(e,d,void 0===h?"":h),n(t,r)}else i(t,r)},onError:function(e,t,r){s(e,t,r)}})),wz.set(e,t),t}(e),n=t.map(function(e){return{name:e.name,type:e.type,size:e.size,data:e}}),r.addFiles(n),[4,r.upload()];case 1:return o.sent(),[2]}})})}var Az=function(){function e(){this.title=eC("videoModule.uploadVideo"),this.iconSvg='<svg viewBox="0 0 1056 1024"><path d="M805.902261 521.819882a251.441452 251.441452 0 0 0-251.011972 246.600033 251.051015 251.051015 0 1 0 502.023944 8.823877 253.237463 253.237463 0 0 0-251.011972-255.42391z m59.463561 240.001647v129.898403h-116.701631v-129.898403h-44.041298l101.279368-103.504859 101.279368 103.504859z" p-id="6802"></path><path d="M788.254507 0.000781H99.094092A98.663439 98.663439 0 0 0 0.001171 99.093701v590.067495a98.663439 98.663439 0 0 0 99.092921 99.092921h411.7549a266.434235 266.434235 0 0 1-2.186448-41.815807 275.843767 275.843767 0 0 1 275.180024-270.729042 270.650955 270.650955 0 0 1 103.504859 19.834201V99.093701A101.51363 101.51363 0 0 0 788.254507 0.000781zM295.054441 640.747004V147.507894l394.146189 246.600033z"></path></svg>',this.tag="button"}return e.prototype.getValue=function(e){return""},e.prototype.isActive=function(e){return!1},e.prototype.exec=function(e,t){var r=this.getMenuConfig(e),n=r.allowedFileTypes,o=void 0===n?[]:n,i=r.customBrowseAndUpload;if(i)i(function(t,r){return yz(e,t,r)});else{var a="";o.length>0&&(a='accept="'.concat(o.join(", "),'"'));var s=ov("body"),u=ov('<input type="file" '.concat(a," multiple/>"));u.hide(),s.append(u),u.click(),u.on("change",function(){var t=u[0].files;!function(e,t){Xg(this,void 0,void 0,function(){var r,n,o,i,a,s,u,l,c,d,h,f;return Zg(this,function(p){switch(p.label){case 0:if(null==t)return[2];r=Array.prototype.slice.call(t),n=[],o=Cz(e).customUpload,p.label=1;case 1:p.trys.push([1,8,9,14]),i=!0,a=tm(r),p.label=2;case 2:return[4,a.next()];case 3:return s=p.sent(),(c=s.done)?[3,7]:(f=s.value,i=!1,u=f,o?[4,o(u,function(t,r){return yz(e,t,r)})]:[3,5]);case 4:return p.sent(),[3,6];case 5:n.push(u),p.label=6;case 6:return i=!0,[3,2];case 7:return[3,14];case 8:return l=p.sent(),d={error:l},[3,14];case 9:return p.trys.push([9,,12,13]),i||c||!(h=a.return)?[3,11]:[4,h.call(a)];case 10:p.sent(),p.label=11;case 11:return[3,13];case 12:if(d)throw d.error;return[7];case 13:return[7];case 14:return n.length>0?[4,Ez(e,n)]:[3,16];case 15:p.sent(),p.label=16;case 16:return[2]}})})}(e,t)})}},e.prototype.isDisabled=function(e){var t=e.selection;return null==t||(!hg.isCollapsed(t)||!!Ry.getSelectedElems(e).some(function(t){var r=Ry.getNodeType(t);return"pre"===r||("list-item"===r||!!e.isVoid(t))}))},e.prototype.getMenuConfig=function(e){return e.getMenuConfig("uploadVideo")},e}();function xz(e,t,r,n,o,i){return void 0===t&&(t=""),void 0===r&&(r="auto"),void 0===n&&(n="auto"),void 0===o&&(o={}),void 0===i&&(i="center"),{type:"video",src:e,poster:t,width:r,height:n,style:o,children:[{text:""}],textAlign:i}}var Bz={selector:'div[data-w-e-type="video"]',parseElemHtml:function(e,t,r){var n=ov(e),o="",i="",a="auto",s="auto",u={},l=n.find("iframe");if(l.length>0)return a=l.attr("width")||"auto",s=l.attr("height")||"auto",u=fz(u=l.attr("style")||""),xz(o=l[0].outerHTML,i,a,s,u,fz(n.attr("style")||"")["text-align"]||"center");var c=n.find("video");return(o=c.attr("src")||"")||c.length>0&&(o=c.find("source").attr("src")||""),a=c.attr("width")||"auto",s=c.attr("height")||"auto",xz(o,i=c.attr("poster")||"",a,s,u=fz(u=c.attr("style")||""),fz(n.attr("style")||"")["text-align"]||"center")}};var Sz={selector:"iframe,video,p",preParseHtml:function(e){var t=ov(e),r=t;if("p"===lz(t)){var n=t.children();if(1===n.length){var o=n[0],i=o.tagName.toLowerCase();["iframe","video"].includes(i)&&(r=ov(o))}}var a=lz(r);if("iframe"!==a&&"video"!==a)return r[0];if("video"===r.parent().attr("data-w-e-type"))return r[0];var s=ov('<div data-w-e-type="video" data-w-e-is-void style="text-align: center;"></div>');return s.append(r),s[0]}};var Fz={type:"video",renderElem:function(e,t,r){var n,o=e,i=o.src,a=void 0===i?"":i,s=o.poster,u=void 0===s?"":s,l=o.key,c=void 0===l?"":l,d=o.width,h=void 0===d?"auto":d,f=o.height,p=void 0===f?"auto":f,g=o.style,m=void 0===g?{}:g,v=o.textAlign,y=void 0===v?"center":v,b=Ry.isNodeSelected(r,e);if(0===a.trim().indexOf("<iframe ")){n=Tw("div",{className:"w-e-textarea-video-container","data-selected":b?"true":"",style:{textAlign:y},innerHTML:cz(a,h,p,m)})}else{var D=Tw("video",{key:c,poster:u,controls:!0,style:m},Tw("source",{src:a,type:"video/mp4"}),"Sorry, your browser doesn't support embedded videos.\n 抱歉,浏览器不支持 video 视频");"auto"!==h&&(D.data.width=h),"auto"!==p&&(D.data.height=p),n=Tw("div",{className:"w-e-textarea-video-container","data-selected":b?"true":"",style:{textAlign:y}},D)}var C=dw("div",{props:{contentEditable:!1},on:{mousedown:function(e){return e.preventDefault()}}},n);return C}},kz={renderElems:[Fz],elemsToHtml:[dz],preParseHtml:[Sz],parseElemsHtml:[Bz],menus:[{key:"insertVideo",factory:function(){return new Dz},config:{onInsertedVideo:function(e){},checkVideo:function(e,t){return!0},parseVideoSrc:function(e){return e}}},{key:"uploadVideo",factory:function(){return new Az},config:{server:"",fieldName:"wangeditor-uploaded-video",maxFileSize:10485760,maxNumberOfFiles:5,allowedFileTypes:["video/*"],meta:{},metaWithUrl:!1,withCredentials:!1,timeout:3e4,onBeforeUpload:function(e){return e},onProgress:function(e){},onSuccess:function(e,t){},onFailed:function(e,t){console.error("'".concat(e.name,"' upload failed"),t)},onError:function(e,t,r){console.error("'".concat(e.name," upload error"),t,r)}}},{key:"editVideoSize",factory:function(){return new gz}},{key:"editVideoSrc",factory:function(){return new vz}}],editorPlugin:function(e){var t=e.isVoid,r=e.normalizeNode,n=e;return n.isVoid=function(e){return"video"===e.type||t(e)},n.normalizeNode=function(e){var t=Qg(e,2),o=t[0],i=t[1];"video"===Ry.getNodeType(o)&&(Ry.isLastNode(n,o)&&zg.insertNodes(n,Ry.genEmptyParagraph(),{at:[i[0]+1]}));return r([o,i])},n}},Oz=function(){function e(){throw new Error("不能实例化\nCan not construct a instance")}return e.setEditorConfig=function(e){void 0===e&&(e={}),this.editorConfig=Kg(Kg({},this.editorConfig),e)},e.setSimpleEditorConfig=function(e){void 0===e&&(e={}),this.simpleEditorConfig=Kg(Kg({},this.simpleEditorConfig),e)},e.setToolbarConfig=function(e){void 0===e&&(e={}),this.toolbarConfig=Kg(Kg({},this.toolbarConfig),e)},e.setSimpleToolbarConfig=function(e){void 0===e&&(e={}),this.simpleToolbarConfig=Kg(Kg({},this.simpleToolbarConfig),e)},e.registerPlugin=function(e){this.plugins.push(e)},e.registerMenu=function(e,t){ym(e,t)},e.registerRenderElem=function(e){!function(e){var t=e.type,r=e.renderElem;Iw[t||""]=r}(e)},e.registerRenderStyle=function(e){!function(e){Nw.push(e)}(e)},e.registerElemToHtml=function(e){!function(e){var t=e.type,r=e.elemToHtml;wy[t||""]=r}(e)},e.registerStyleToHtml=function(e){!function(e){by.push(e)}(e)},e.registerPreParseHtml=function(e){},e.registerParseElemHtml=function(e){!function(e){var t=e.selector,r=e.parseElemHtml;ay[t]=r}(e)},e.registerParseStyleHtml=function(e){!function(e){iy.push(e)}(e)},e.registerModule=function(e){Tz(e)},e.editorConfig={},e.simpleEditorConfig={},e.toolbarConfig={},e.simpleToolbarConfig={},e.plugins=[],e}();function Tz(e){var t=e.menus,r=e.renderElems,n=e.renderStyle,o=e.elemsToHtml,i=e.styleToHtml,a=e.preParseHtml,s=e.parseElemsHtml,u=e.parseStyleHtml,l=e.editorPlugin;t&&t.forEach(function(e){return Oz.registerMenu(e)}),r&&r.forEach(function(e){return Oz.registerRenderElem(e)}),n&&Oz.registerRenderStyle(n),o&&o.forEach(function(e){return Oz.registerElemToHtml(e)}),i&&Oz.registerStyleToHtml(i),a&&a.forEach(function(e){return Oz.registerPreParseHtml(e)}),s&&s.forEach(function(e){return Oz.registerParseElemHtml(e)}),u&&Oz.registerParseStyleHtml(u),l&&Oz.registerPlugin(l)}vk.forEach(function(e){return Tz(e)}),Tz(Jk),Tz(tz),Tz(kz),Tz(uz),Tz(Ik),Tz(HL);var Nz='<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>';var Pz={link:{menuKeys:["editLink","unLink","viewLink"]},image:{menuKeys:["imageWidth30","imageWidth50","imageWidth100","editorImageSizeMenu","editImage","viewImageLink","deleteImage"]},pre:{menuKeys:["enter","codeBlock","codeSelectLang"]},table:{menuKeys:["enter","tableHeader","tableFullWidth","insertTableRow","deleteTableRow","insertTableCol","deleteTableCol","deleteTable","mergeTableCell","splitTableCell","setTableProperty","setTableCellProperty"]},divider:{menuKeys:["enter"]},video:{menuKeys:["enter","editVideoSize","editVideoSrc"]}};var Mz,Iz={hoverbarKeys:(Mz=["formatPainter","headerSelect","insertLink","bulletedList","|","bold","through","color","bgColor","clearStyle"],null!=vm.textToFormula&&Mz.push("|","textToFormula"),Kg(Kg({},Pz),{text:{menuKeys:Mz}}))};Oz.setEditorConfig(Kg(Kg({},Iz),{decorate:Tk}));var Rz={hoverbarKeys:Pz};Oz.setSimpleEditorConfig(Kg(Kg({},Rz),{decorate:Tk}));var Lz={toolbarKeys:["headerSelect","blockquote","|","bold","underline","italic",{key:"group-more-style",title:eC("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:eC("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:eC("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:eC("editor.image"),iconSvg:Nz,menuKeys:["insertImage","uploadImage"]},{key:"group-video",title:eC("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","|","formatPainter","fullScreen"]};Oz.setToolbarConfig(Lz);var _z={toolbarKeys:["blockquote","header1","header2","header3","|","bold","underline","italic","through","color","bgColor","clearStyle","|","bulletedList","numberedList","todo","justifyLeft","justifyRight","justifyCenter","|","insertLink",{key:"group-image",title:eC("editor.image"),iconSvg:Nz,menuKeys:["insertImage","uploadImage"]},"insertVideo","insertTable","codeBlock","|","undo","redo","|","fullScreen"]};function zz(e){void 0===e&&(e={});var t=e.selector,r=void 0===t?"":t,n=e.content,o=void 0===n?[]:n,i=e.html,a=e.config,s=void 0===a?{}:a,u=e.mode,l="simple"===(void 0===u?"default":u)?Oz.simpleEditorConfig:Oz.editorConfig,c=Kg(Kg({},l.hoverbarKeys||{}),s.hoverbarKeys||{});return Zw({selector:r,config:Kg(Kg(Kg({},l),s),{hoverbarKeys:c}),content:o,html:i,plugins:Oz.plugins})}function jz(e){var t=e.selector,r=e.editor,n=e.config,o=void 0===n?{}:n,i=e.mode,a=void 0===i?"default":i;if(!t)throw new Error("Cannot find 'selector' when create toolbar");var s="simple"===a?Oz.simpleToolbarConfig:Oz.toolbarConfig;return Qw(r,{selector:t,config:Kg(Kg({},s),o)})}Oz.setSimpleToolbarConfig(_z);var Hz={};export{Oz as Boot,Ry as DomEditor,Yp as SlateEditor,Vp as SlateElement,Kp as SlateLocation,eg as SlateNode,og as SlatePath,ug as SlatePoint,hg as SlateRange,Cg as SlateText,zg as SlateTransforms,Jw as Toolbar,zz as createEditor,jz as createToolbar,Yx as createUploader,Hz as default,fC as genModalButtonElems,dC as genModalInputElems,hC as genModalTextareaElems,XD as i18nAddResources,ZD as i18nChangeLanguage,JD as i18nGetResources,eC as t};
|
|
27
33
|
//# sourceMappingURL=index.mjs.map
|