@wangeditor-next/plugin-float-image 1.0.26 → 1.0.28
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.
@@ -2,10 +2,11 @@
|
|
2
2
|
* @description parse html
|
3
3
|
* @author wangfupeng
|
4
4
|
*/
|
5
|
-
import {
|
6
|
-
import { Element as SlateElement, Descendant } from 'slate';
|
5
|
+
import { Descendant, Element as SlateElement } from 'slate';
|
7
6
|
import { IDomEditor } from '../editor/interface';
|
7
|
+
import { DOMElement } from '../utils/dom';
|
8
8
|
export declare const TEXT_TAGS: string[];
|
9
|
+
export declare const SPAN_WITH_SPECIAL_TAGS: string[];
|
9
10
|
export type PreParseHtmlFnType = ($node: DOMElement) => DOMElement;
|
10
11
|
export interface IPreParseHtmlConf {
|
11
12
|
selector: string;
|
@@ -3,6 +3,7 @@
|
|
3
3
|
* @author wangfupeng
|
4
4
|
*/
|
5
5
|
import { UppyFile } from '@uppy/core';
|
6
|
+
import { IDomEditor } from '../editor/interface';
|
6
7
|
type FilesType = {
|
7
8
|
[key: string]: UppyFile<{}, {}>;
|
8
9
|
};
|
@@ -23,14 +24,14 @@ interface IBaseUploadConfig {
|
|
23
24
|
onError: (file: UppyFile<{}, {}>, error: any, res: any) => void;
|
24
25
|
allowedFileTypes?: string[];
|
25
26
|
customInsert?: (res: any, insertFn: InsertFn) => void;
|
26
|
-
customUpload?: (files: File, insertFn: InsertFn) => void;
|
27
|
+
customUpload?: (files: File, insertFn: InsertFn, editor: IDomEditor) => void;
|
27
28
|
customBrowseAndUpload?: (insertFn: InsertFn) => void;
|
28
29
|
uppyConfig?: Record<string, any>;
|
29
30
|
xhrConfig?: Record<string, any>;
|
30
31
|
}
|
31
32
|
interface IUploadConfigWithCustomUpload extends IBaseUploadConfig {
|
32
33
|
server?: string;
|
33
|
-
customUpload: (files: File, insertFn: InsertFn) => void;
|
34
|
+
customUpload: (files: File, insertFn: InsertFn, editor: IDomEditor) => void;
|
34
35
|
}
|
35
36
|
interface IUploadConfigWithoutCustomUpload extends IBaseUploadConfig {
|
36
37
|
server: string;
|
package/dist/index.js
CHANGED
@@ -1,2 +1,2 @@
|
|
1
|
-
!function(t,r){"object"==typeof exports&&"undefined"!=typeof module?module.exports=r(require("@wangeditor-next/editor"),require("dom7"),require("snabbdom")):"function"==typeof define&&define.amd?define(["@wangeditor-next/editor","dom7","snabbdom"],r):(t="undefined"!=typeof globalThis?globalThis:t||self).WangEditorFloatImagePlugin=r(t.editor,t.$,t.snabbdom)}(this,function(t,r,n){"use strict";t.i18nAddResources("en",{float:{none:"Default",left:"Float Left",right:"Float Right"}}),t.i18nAddResources("zh-CN",{float:{none:"默认",left:"左浮动",right:"右浮动"}});var e="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{};function o(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}var i,u,a={};function f(){if(u)return i;u=1;var t=function(t){return t&&t.Math===Math&&t};return i=t("object"==typeof globalThis&&globalThis)||t("object"==typeof window&&window)||t("object"==typeof self&&self)||t("object"==typeof e&&e)||t("object"==typeof i&&i)||function(){return this}()||Function("return this")()}var c,l,s,v,d,p,h,g,y={};function m(){return l?c:(l=1,c=function(t){try{return!!t()}catch(t){return!0}})}function b(){if(v)return s;v=1;var t=m();return s=!t(function(){return 7!==Object.defineProperty({},1,{get:function(){return 7}})[1]})}function w(){if(p)return d;p=1;var t=m();return d=!t(function(){var t=function(){}.bind();return"function"!=typeof t||t.hasOwnProperty("prototype")})}function x(){if(g)return h;g=1;var t=w(),r=Function.prototype.call;return h=t?r.bind(r):function(){return r.apply(r,arguments)},h}var O,S,j,E,q,T,C,P,A,I,N,R,M,F,D,_,k,z,$,L,W,Z,B,H,U,G,K,X,Y,V,J,Q,tt,rt,nt,et,ot,it,ut,at,ft,ct={};function lt(){return j?S:(j=1,S=function(t,r){return{enumerable:!(1&t),configurable:!(2&t),writable:!(4&t),value:r}})}function st(){if(q)return E;q=1;var t=w(),r=Function.prototype,n=r.call,e=t&&r.bind.bind(n,n);return E=t?e:function(t){return function(){return n.apply(t,arguments)}},E}function vt(){if(C)return T;C=1;var t=st(),r=t({}.toString),n=t("".slice);return T=function(t){return n(r(t),8,-1)}}function dt(){if(A)return P;A=1;var t=st(),r=m(),n=vt(),e=Object,o=t("".split);return P=r(function(){return!e("z").propertyIsEnumerable(0)})?function(t){return"String"===n(t)?o(t,""):e(t)}:e}function pt(){return N?I:(N=1,I=function(t){return null==t})}function ht(){if(M)return R;M=1;var t=pt(),r=TypeError;return R=function(n){if(t(n))throw new r("Can't call method on "+n);return n}}function gt(){if(D)return F;D=1;var t=dt(),r=ht();return F=function(n){return t(r(n))}}function yt(){if(k)return _;k=1;var t="object"==typeof document&&document.all;return _=void 0===t&&void 0!==t?function(r){return"function"==typeof r||r===t}:function(t){return"function"==typeof t}}function mt(){if($)return z;$=1;var t=yt();return z=function(r){return"object"==typeof r?null!==r:t(r)}}function bt(){if(W)return L;W=1;var t=f(),r=yt();return L=function(n,e){return arguments.length<2?(o=t[n],r(o)?o:void 0):t[n]&&t[n][e];var o},L}function wt(){if(K)return G;K=1;var t,r,n=f(),e=function(){if(U)return H;U=1;var t=f().navigator,r=t&&t.userAgent;return H=r?String(r):""}(),o=n.process,i=n.Deno,u=o&&o.versions||i&&i.version,a=u&&u.v8;return a&&(r=(t=a.split("."))[0]>0&&t[0]<4?1:+(t[0]+t[1])),!r&&e&&(!(t=e.match(/Edge\/(\d+)/))||t[1]>=74)&&(t=e.match(/Chrome\/(\d+)/))&&(r=+t[1]),G=r}function xt(){if(Y)return X;Y=1;var t=wt(),r=m(),n=f().String;return X=!!Object.getOwnPropertySymbols&&!r(function(){var r=Symbol("symbol detection");return!n(r)||!(Object(r)instanceof Symbol)||!Symbol.sham&&t&&t<41})}function Ot(){if(J)return V;J=1;var t=xt();return V=t&&!Symbol.sham&&"symbol"==typeof Symbol.iterator}function St(){if(tt)return Q;tt=1;var t=bt(),r=yt(),n=function(){if(B)return Z;B=1;var t=st();return Z=t({}.isPrototypeOf)}(),e=Ot(),o=Object;return Q=e?function(t){return"symbol"==typeof t}:function(e){var i=t("Symbol");return r(i)&&n(i.prototype,o(e))}}function jt(){if(nt)return rt;nt=1;var t=String;return rt=function(r){try{return t(r)}catch(t){return"Object"}}}function Et(){if(ot)return et;ot=1;var t=yt(),r=jt(),n=TypeError;return et=function(e){if(t(e))return e;throw new n(r(e)+" is not a function")}}function qt(){if(ut)return it;ut=1;var t=Et(),r=pt();return it=function(n,e){var o=n[e];return r(o)?void 0:t(o)}}function Tt(){if(ft)return at;ft=1;var t=x(),r=yt(),n=mt(),e=TypeError;return at=function(o,i){var u,a;if("string"===i&&r(u=o.toString)&&!n(a=t(u,o)))return a;if(r(u=o.valueOf)&&!n(a=t(u,o)))return a;if("string"!==i&&r(u=o.toString)&&!n(a=t(u,o)))return a;throw new e("Can't convert object to primitive value")}}var Ct,Pt,At,It,Nt,Rt,Mt,Ft,Dt,_t,kt,zt,$t,Lt,Wt,Zt,Bt,Ht,Ut,Gt,Kt,Xt,Yt,Vt,Jt={exports:{}};function Qt(){if(It)return At;It=1;var t=f(),r=Object.defineProperty;return At=function(n,e){try{r(t,n,{value:e,configurable:!0,writable:!0})}catch(r){t[n]=e}return e}}function tr(){if(Nt)return Jt.exports;Nt=1;var t=Pt?Ct:(Pt=1,Ct=!1),r=f(),n=Qt(),e="__core-js_shared__",o=Jt.exports=r[e]||n(e,{});return(o.versions||(o.versions=[])).push({version:"3.44.0",mode:t?"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"}),Jt.exports}function rr(){if(Mt)return Rt;Mt=1;var t=tr();return Rt=function(r,n){return t[r]||(t[r]=n||{})}}function nr(){if(Dt)return Ft;Dt=1;var t=ht(),r=Object;return Ft=function(n){return r(t(n))}}function er(){if(kt)return _t;kt=1;var t=st(),r=nr(),n=t({}.hasOwnProperty);return _t=Object.hasOwn||function(t,e){return n(r(t),e)}}function or(){if($t)return zt;$t=1;var t=st(),r=0,n=Math.random(),e=t(1.1.toString);return zt=function(t){return"Symbol("+(void 0===t?"":t)+")_"+e(++r+n,36)}}function ir(){if(Wt)return Lt;Wt=1;var t=f(),r=rr(),n=er(),e=or(),o=xt(),i=Ot(),u=t.Symbol,a=r("wks"),c=i?u.for||u:u&&u.withoutSetter||e;return Lt=function(t){return n(a,t)||(a[t]=o&&n(u,t)?u[t]:c("Symbol."+t)),a[t]}}function ur(){if(Bt)return Zt;Bt=1;var t=x(),r=mt(),n=St(),e=qt(),o=Tt(),i=ir(),u=TypeError,a=i("toPrimitive");return Zt=function(i,f){if(!r(i)||n(i))return i;var c,l=e(i,a);if(l){if(void 0===f&&(f="default"),c=t(l,i,f),!r(c)||n(c))return c;throw new u("Can't convert object to primitive value")}return void 0===f&&(f="number"),o(i,f)}}function ar(){if(Ut)return Ht;Ut=1;var t=ur(),r=St();return Ht=function(n){var e=t(n,"string");return r(e)?e:e+""}}function fr(){if(Kt)return Gt;Kt=1;var t=f(),r=mt(),n=t.document,e=r(n)&&r(n.createElement);return Gt=function(t){return e?n.createElement(t):{}}}function cr(){if(Yt)return Xt;Yt=1;var t=b(),r=m(),n=fr();return Xt=!t&&!r(function(){return 7!==Object.defineProperty(n("div"),"a",{get:function(){return 7}}).a})}function lr(){if(Vt)return y;Vt=1;var t=b(),r=x(),n=function(){if(O)return ct;O=1;var t={}.propertyIsEnumerable,r=Object.getOwnPropertyDescriptor,n=r&&!t.call({1:2},1);return ct.f=n?function(t){var n=r(this,t);return!!n&&n.enumerable}:t,ct}(),e=lt(),o=gt(),i=ar(),u=er(),a=cr(),f=Object.getOwnPropertyDescriptor;return y.f=t?f:function(t,c){if(t=o(t),c=i(c),a)try{return f(t,c)}catch(t){}if(u(t,c))return e(!r(n.f,t,c),t[c])},y}var sr,vr,dr,pr,hr,gr,yr,mr={};function br(){if(vr)return sr;vr=1;var t=b(),r=m();return sr=t&&r(function(){return 42!==Object.defineProperty(function(){},"prototype",{value:42,writable:!1}).prototype})}function wr(){if(pr)return dr;pr=1;var t=mt(),r=String,n=TypeError;return dr=function(e){if(t(e))return e;throw new n(r(e)+" is not an object")}}function xr(){if(hr)return mr;hr=1;var t=b(),r=cr(),n=br(),e=wr(),o=ar(),i=TypeError,u=Object.defineProperty,a=Object.getOwnPropertyDescriptor,f="enumerable",c="configurable",l="writable";return mr.f=t?n?function(t,r,n){if(e(t),r=o(r),e(n),"function"==typeof t&&"prototype"===r&&"value"in n&&l in n&&!n[l]){var i=a(t,r);i&&i[l]&&(t[r]=n.value,n={configurable:c in n?n[c]:i[c],enumerable:f in n?n[f]:i[f],writable:!1})}return u(t,r,n)}:u:function(t,n,a){if(e(t),n=o(n),e(a),r)try{return u(t,n,a)}catch(t){}if("get"in a||"set"in a)throw new i("Accessors not supported");return"value"in a&&(t[n]=a.value),t},mr}function Or(){if(yr)return gr;yr=1;var t=b(),r=xr(),n=lt();return gr=t?function(t,e,o){return r.f(t,e,n(1,o))}:function(t,r,n){return t[r]=n,t}}var Sr,jr,Er,qr,Tr,Cr,Pr,Ar,Ir,Nr,Rr,Mr,Fr,Dr,_r,kr={exports:{}};function zr(){if(jr)return Sr;jr=1;var t=b(),r=er(),n=Function.prototype,e=t&&Object.getOwnPropertyDescriptor,o=r(n,"name"),i=o&&"something"===function(){}.name,u=o&&(!t||t&&e(n,"name").configurable);return Sr={EXISTS:o,PROPER:i,CONFIGURABLE:u}}function $r(){if(qr)return Er;qr=1;var t=st(),r=yt(),n=tr(),e=t(Function.toString);return r(n.inspectSource)||(n.inspectSource=function(t){return e(t)}),Er=n.inspectSource}function Lr(){if(Ar)return Pr;Ar=1;var t=rr(),r=or(),n=t("keys");return Pr=function(t){return n[t]||(n[t]=r(t))}}function Wr(){return Nr?Ir:(Nr=1,Ir={})}function Zr(){if(Mr)return Rr;Mr=1;var t,r,n,e=function(){if(Cr)return Tr;Cr=1;var t=f(),r=yt(),n=t.WeakMap;return Tr=r(n)&&/native code/.test(String(n))}(),o=f(),i=mt(),u=Or(),a=er(),c=tr(),l=Lr(),s=Wr(),v="Object already initialized",d=o.TypeError,p=o.WeakMap;if(e||c.state){var h=c.state||(c.state=new p);h.get=h.get,h.has=h.has,h.set=h.set,t=function(t,r){if(h.has(t))throw new d(v);return r.facade=t,h.set(t,r),r},r=function(t){return h.get(t)||{}},n=function(t){return h.has(t)}}else{var g=l("state");s[g]=!0,t=function(t,r){if(a(t,g))throw new d(v);return r.facade=t,u(t,g,r),r},r=function(t){return a(t,g)?t[g]:{}},n=function(t){return a(t,g)}}return Rr={set:t,get:r,has:n,enforce:function(e){return n(e)?r(e):t(e,{})},getterFor:function(t){return function(n){var e;if(!i(n)||(e=r(n)).type!==t)throw new d("Incompatible receiver, "+t+" required");return e}}}}function Br(){if(Fr)return kr.exports;Fr=1;var t=st(),r=m(),n=yt(),e=er(),o=b(),i=zr().CONFIGURABLE,u=$r(),a=Zr(),f=a.enforce,c=a.get,l=String,s=Object.defineProperty,v=t("".slice),d=t("".replace),p=t([].join),h=o&&!r(function(){return 8!==s(function(){},"length",{value:8}).length}),g=String(String).split("String"),y=kr.exports=function(t,r,n){"Symbol("===v(l(r),0,7)&&(r="["+d(l(r),/^Symbol\(([^)]*)\).*$/,"$1")+"]"),n&&n.getter&&(r="get "+r),n&&n.setter&&(r="set "+r),(!e(t,"name")||i&&t.name!==r)&&(o?s(t,"name",{value:r,configurable:!0}):t.name=r),h&&n&&e(n,"arity")&&t.length!==n.arity&&s(t,"length",{value:n.arity});try{n&&e(n,"constructor")&&n.constructor?o&&s(t,"prototype",{writable:!1}):t.prototype&&(t.prototype=void 0)}catch(t){}var u=f(t);return e(u,"source")||(u.source=p(g,"string"==typeof r?r:"")),t};return Function.prototype.toString=y(function(){return n(this)&&c(this).source||u(this)},"toString"),kr.exports}function Hr(){if(_r)return Dr;_r=1;var t=yt(),r=xr(),n=Br(),e=Qt();return Dr=function(o,i,u,a){a||(a={});var f=a.enumerable,c=void 0!==a.name?a.name:i;if(t(u)&&n(u,c,a),a.global)f?o[i]=u:e(i,u);else{try{a.unsafe?o[i]&&(f=!0):delete o[i]}catch(t){}f?o[i]=u:r.f(o,i,{value:u,enumerable:!1,configurable:!a.nonConfigurable,writable:!a.nonWritable})}return o}}var Ur,Gr,Kr,Xr,Yr,Vr,Jr,Qr,tn,rn,nn,en,on,un,an,fn,cn,ln={};function sn(){if(Xr)return Kr;Xr=1;var t=function(){if(Gr)return Ur;Gr=1;var t=Math.ceil,r=Math.floor;return Ur=Math.trunc||function(n){var e=+n;return(e>0?r:t)(e)}}();return Kr=function(r){var n=+r;return n!=n||0===n?0:t(n)}}function vn(){if(Vr)return Yr;Vr=1;var t=sn(),r=Math.max,n=Math.min;return Yr=function(e,o){var i=t(e);return i<0?r(i+o,0):n(i,o)}}function dn(){if(Qr)return Jr;Qr=1;var t=sn(),r=Math.min;return Jr=function(n){var e=t(n);return e>0?r(e,9007199254740991):0}}function pn(){if(rn)return tn;rn=1;var t=dn();return tn=function(r){return t(r.length)}}function hn(){if(un)return on;un=1;var t=st(),r=er(),n=gt(),e=function(){if(en)return nn;en=1;var t=gt(),r=vn(),n=pn(),e=function(e){return function(o,i,u){var a=t(o),f=n(a);if(0===f)return!e&&-1;var c,l=r(u,f);if(e&&i!=i){for(;f>l;)if((c=a[l++])!=c)return!0}else for(;f>l;l++)if((e||l in a)&&a[l]===i)return e||l||0;return!e&&-1}};return nn={includes:e(!0),indexOf:e(!1)}}().indexOf,o=Wr(),i=t([].push);return on=function(t,u){var a,f=n(t),c=0,l=[];for(a in f)!r(o,a)&&r(f,a)&&i(l,a);for(;u.length>c;)r(f,a=u[c++])&&(~e(l,a)||i(l,a));return l}}function gn(){return fn?an:(fn=1,an=["constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleString","toString","valueOf"])}var yn,mn,bn,wn,xn,On,Sn,jn,En,qn,Tn,Cn,Pn,An,In,Nn,Rn,Mn,Fn,Dn,_n,kn,zn,$n,Ln,Wn,Zn,Bn,Hn={};function Un(){if(bn)return mn;bn=1;var t=bt(),r=st(),n=function(){if(cn)return ln;cn=1;var t=hn(),r=gn().concat("length","prototype");return ln.f=Object.getOwnPropertyNames||function(n){return t(n,r)},ln}(),e=(yn||(yn=1,Hn.f=Object.getOwnPropertySymbols),Hn),o=wr(),i=r([].concat);return mn=t("Reflect","ownKeys")||function(t){var r=n.f(o(t)),u=e.f;return u?i(r,u(t)):r}}function Gn(){if(xn)return wn;xn=1;var t=er(),r=Un(),n=lr(),e=xr();return wn=function(o,i,u){for(var a=r(i),f=e.f,c=n.f,l=0;l<a.length;l++){var s=a[l];t(o,s)||u&&t(u,s)||f(o,s,c(i,s))}}}function Kn(){if(En)return jn;En=1;var t=f(),r=lr().f,n=Or(),e=Hr(),o=Qt(),i=Gn(),u=function(){if(Sn)return On;Sn=1;var t=m(),r=yt(),n=/#|\.prototype\./,e=function(n,e){var f=i[o(n)];return f===a||f!==u&&(r(e)?t(e):!!e)},o=e.normalize=function(t){return String(t).replace(n,".").toLowerCase()},i=e.data={},u=e.NATIVE="N",a=e.POLYFILL="P";return On=e}();return jn=function(a,f){var c,l,s,v,d,p=a.target,h=a.global,g=a.stat;if(c=h?t:g?t[p]||o(p,{}):t[p]&&t[p].prototype)for(l in f){if(v=f[l],s=a.dontCallGetSet?(d=r(c,l))&&d.value:c[l],!u(h?l:p+(g?".":"#")+l,a.forced)&&void 0!==s){if(typeof v==typeof s)continue;i(v,s)}(a.sham||s&&s.sham)&&n(v,"sham",!0),e(c,l,v,a)}}}function Xn(){if(Tn)return qn;Tn=1;var t=vt();return qn=Array.isArray||function(r){return"Array"===t(r)}}function Yn(){if(Pn)return Cn;Pn=1;var t=TypeError;return Cn=function(r){if(r>9007199254740991)throw t("Maximum allowed index exceeded");return r}}function Vn(){if(In)return An;In=1;var t=b(),r=xr(),n=lt();return An=function(e,o,i){t?r.f(e,o,n(0,i)):e[o]=i}}function Jn(){if(Rn)return Nn;Rn=1;var t={};return t[ir()("toStringTag")]="z",Nn="[object z]"===String(t)}function Qn(){if(Fn)return Mn;Fn=1;var t=Jn(),r=yt(),n=vt(),e=ir()("toStringTag"),o=Object,i="Arguments"===n(function(){return arguments}());return Mn=t?n:function(t){var u,a,f;return void 0===t?"Undefined":null===t?"Null":"string"==typeof(a=function(t,r){try{return t[r]}catch(t){}}(u=o(t),e))?a:i?n(u):"Object"===(f=n(u))&&r(u.callee)?"Arguments":f}}function te(){if(_n)return Dn;_n=1;var t=st(),r=m(),n=yt(),e=Qn(),o=bt(),i=$r(),u=function(){},a=o("Reflect","construct"),f=/^\s*(?:class|function)\b/,c=t(f.exec),l=!f.test(u),s=function(t){if(!n(t))return!1;try{return a(u,[],t),!0}catch(t){return!1}},v=function(t){if(!n(t))return!1;switch(e(t)){case"AsyncFunction":case"GeneratorFunction":case"AsyncGeneratorFunction":return!1}try{return l||!!c(f,i(t))}catch(t){return!0}};return v.sham=!0,Dn=!a||r(function(){var t;return s(s.call)||!s(Object)||!s(function(){t=!0})||t})?v:s}function re(){if(zn)return kn;zn=1;var t=Xn(),r=te(),n=mt(),e=ir()("species"),o=Array;return kn=function(i){var u;return t(i)&&(u=i.constructor,(r(u)&&(u===o||t(u.prototype))||n(u)&&null===(u=u[e]))&&(u=void 0)),void 0===u?o:u}}function ne(){if(Ln)return $n;Ln=1;var t=re();return $n=function(r,n){return new(t(r))(0===n?0:n)}}function ee(){if(Zn)return Wn;Zn=1;var t=m(),r=ir(),n=wt(),e=r("species");return Wn=function(r){return n>=51||!t(function(){var t=[];return(t.constructor={})[e]=function(){return{foo:1}},1!==t[r](Boolean).foo})}}!function(){if(Bn)return a;Bn=1;var t=Kn(),r=m(),n=Xn(),e=mt(),o=nr(),i=pn(),u=Yn(),f=Vn(),c=ne(),l=ee(),s=ir(),v=wt(),d=s("isConcatSpreadable"),p=v>=51||!r(function(){var t=[];return t[d]=!1,t.concat()[0]!==t}),h=function(t){if(!e(t))return!1;var r=t[d];return void 0!==r?!!r:n(t)};t({target:"Array",proto:!0,arity:1,forced:!p||!l("concat")},{concat:function(t){var r,n,e,a,l,s=o(this),v=c(s,0),d=0;for(r=-1,e=arguments.length;r<e;r++)if(h(l=-1===r?s:arguments[r]))for(a=i(l),u(d+a),n=0;n<a;n++,d++)n in l&&f(v,d,l[n]);else u(d+1),f(v,d++,l);return v.length=d,v}})}();var oe={type:"image",elemToHtml:function(t,r){var n=t,e=n.src,o=n.alt,i=void 0===o?"":o,u=n.href,a=void 0===u?"":u,f=n.style,c=void 0===f?{}:f,l=c.width,s=void 0===l?"":l,v=c.height,d=void 0===v?"":v,p=c.float,h=void 0===p?"":p,g="";return s&&(g+="width: ".concat(s,";")),d&&(g+="height: ".concat(d,";")),h&&(g+="float: ".concat(h,";")),'<img src="'.concat(e,'" alt="').concat(i,'" data-href="').concat(a,'" style="').concat(g,'"/>')}},ie=function(t,r){return ie=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,r){t.__proto__=r}||function(t,r){for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(t[n]=r[n])},ie(t,r)};function ue(t,r){if("function"!=typeof r&&null!==r)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");function n(){this.constructor=t}ie(t,r),t.prototype=null===r?Object.create(r):(n.prototype=r.prototype,new n)}var ae=function(){return ae=Object.assign||function(t){for(var r,n=1,e=arguments.length;n<e;n++)for(var o in r=arguments[n])Object.prototype.hasOwnProperty.call(r,o)&&(t[o]=r[o]);return t},ae.apply(this,arguments)};function fe(t,r){var n="function"==typeof Symbol&&t[Symbol.iterator];if(!n)return t;var e,o,i=n.call(t),u=[];try{for(;(void 0===r||r-- >0)&&!(e=i.next()).done;)u.push(e.value)}catch(t){o={error:t}}finally{try{e&&!e.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return u}function ce(t,r,n){if(n||2===arguments.length)for(var e,o=0,i=r.length;o<i;o++)!e&&o in r||(e||(e=Array.prototype.slice.call(r,0,o)),e[o]=r[o]);return t.concat(e||Array.prototype.slice.call(r))}"function"==typeof SuppressedError&&SuppressedError;var le,se,ve,de,pe,he,ge={};function ye(){if(se)return le;se=1;var t=Qn(),r=String;return le=function(n){if("Symbol"===t(n))throw new TypeError("Cannot convert a Symbol value to a string");return r(n)}}function me(){if(de)return ve;de=1;var t=wr();return ve=function(){var r=t(this),n="";return r.hasIndices&&(n+="d"),r.global&&(n+="g"),r.ignoreCase&&(n+="i"),r.multiline&&(n+="m"),r.dotAll&&(n+="s"),r.unicode&&(n+="u"),r.unicodeSets&&(n+="v"),r.sticky&&(n+="y"),n}}var be,we,xe,Oe,Se,je,Ee,qe,Te,Ce,Pe,Ae,Ie,Ne,Re={};function Me(){if(we)return be;we=1;var t=hn(),r=gn();return be=Object.keys||function(n){return t(n,r)}}function Fe(){if(Se)return Oe;Se=1;var t=bt();return Oe=t("document","documentElement")}function De(){if(Ee)return je;Ee=1;var t,r=wr(),n=function(){if(xe)return Re;xe=1;var t=b(),r=br(),n=xr(),e=wr(),o=gt(),i=Me();return Re.f=t&&!r?Object.defineProperties:function(t,r){e(t);for(var u,a=o(r),f=i(r),c=f.length,l=0;c>l;)n.f(t,u=f[l++],a[u]);return t},Re}(),e=gn(),o=Wr(),i=Fe(),u=fr(),a=Lr(),f="prototype",c="script",l=a("IE_PROTO"),s=function(){},v=function(t){return"<"+c+">"+t+"</"+c+">"},d=function(t){t.write(v("")),t.close();var r=t.parentWindow.Object;return t=null,r},p=function(){try{t=new ActiveXObject("htmlfile")}catch(t){}var r,n,o;p="undefined"!=typeof document?document.domain&&t?d(t):(n=u("iframe"),o="java"+c+":",n.style.display="none",i.appendChild(n),n.src=String(o),(r=n.contentWindow.document).open(),r.write(v("document.F=Object")),r.close(),r.F):d(t);for(var a=e.length;a--;)delete p[f][e[a]];return p()};return o[l]=!0,je=Object.create||function(t,e){var o;return null!==t?(s[f]=r(t),o=new s,s[f]=null,o[l]=t):o=p(),void 0===e?o:n.f(o,e)}}function _e(){if(Ie)return Ae;Ie=1;var t,r,n=x(),e=st(),o=ye(),i=me(),u=function(){if(he)return pe;he=1;var t=m(),r=f().RegExp,n=t(function(){var t=r("a","y");return t.lastIndex=2,null!==t.exec("abcd")}),e=n||t(function(){return!r("a","y").sticky}),o=n||t(function(){var t=r("^r","gy");return t.lastIndex=2,null!==t.exec("str")});return pe={BROKEN_CARET:o,MISSED_STICKY:e,UNSUPPORTED_Y:n}}(),a=rr(),c=De(),l=Zr().get,s=function(){if(Te)return qe;Te=1;var t=m(),r=f().RegExp;return qe=t(function(){var t=r(".","s");return!(t.dotAll&&t.test("\n")&&"s"===t.flags)})}(),v=function(){if(Pe)return Ce;Pe=1;var t=m(),r=f().RegExp;return Ce=t(function(){var t=r("(?<a>b)","g");return"b"!==t.exec("b").groups.a||"bc"!=="b".replace(t,"$<a>c")})}(),d=a("native-string-replace",String.prototype.replace),p=RegExp.prototype.exec,h=p,g=e("".charAt),y=e("".indexOf),b=e("".replace),w=e("".slice),O=(r=/b*/g,n(p,t=/a/,"a"),n(p,r,"a"),0!==t.lastIndex||0!==r.lastIndex),S=u.BROKEN_CARET,j=void 0!==/()??/.exec("")[1];return(O||j||S||s||v)&&(h=function(t){var r,e,u,a,f,s,v,m=this,x=l(m),E=o(t),q=x.raw;if(q)return q.lastIndex=m.lastIndex,r=n(h,q,E),m.lastIndex=q.lastIndex,r;var T=x.groups,C=S&&m.sticky,P=n(i,m),A=m.source,I=0,N=E;if(C&&(P=b(P,"y",""),-1===y(P,"g")&&(P+="g"),N=w(E,m.lastIndex),m.lastIndex>0&&(!m.multiline||m.multiline&&"\n"!==g(E,m.lastIndex-1))&&(A="(?: "+A+")",N=" "+N,I++),e=new RegExp("^(?:"+A+")",P)),j&&(e=new RegExp("^"+A+"$(?!\\s)",P)),O&&(u=m.lastIndex),a=n(p,C?e:m,N),C?a?(a.input=w(a.input,I),a[0]=w(a[0],I),a.index=m.lastIndex,m.lastIndex+=a[0].length):m.lastIndex=0:O&&a&&(m.lastIndex=m.global?a.index+a[0].length:u),j&&a&&a.length>1&&n(d,a[0],e,function(){for(f=1;f<arguments.length-2;f++)void 0===arguments[f]&&(a[f]=void 0)}),a&&T)for(a.groups=s=c(null),f=0;f<T.length;f++)s[(v=T[f])[0]]=a[v[1]];return a}),Ae=h}!function(){if(Ne)return ge;Ne=1;var t=Kn(),r=_e();t({target:"RegExp",proto:!0,forced:/./.exec!==r},{exec:r})}();var ke,ze,$e,Le,We,Ze,Be,He=function(){function r(){this.tag="button"}return r.prototype.getValue=function(t){return""},r.prototype.isActive=function(t){return!1},r.prototype.getSelectedNode=function(r){return t.DomEditor.getSelectedNodeByType(r,"image")},r.prototype.isDisabled=function(t){return null==t.selection||null==this.getSelectedNode(t)},r.prototype.exec=function(r,n){if(!this.isDisabled(r)){var e=this.getSelectedNode(r);if(null!=e){var o=t.DomEditor.getHoverbar(r);o&&o.hideAndClean();var i=e.style,u={style:ae(ae({},void 0===i?{}:i),{float:this.value})};t.SlateTransforms.setNodes(r,u,{match:function(r){return t.DomEditor.checkNodeType(r,"image")}})}}},r}(),Ue=function(r){function n(){var n=r.apply(this,ce([],fe(arguments),!1))||this;return n.title=t.t("float.left"),n.value="left",n.iconSvg='<svg viewBox="0 0 1024 1024"><path d="M77.03514075 117.83964445m12.4275674 0l845.0745837 0q12.42756741 0 12.4275674 12.4275674l0 68.35162074q0 12.42756741-12.4275674 12.42756741l-845.0745837 0q-12.42756741 0-12.4275674-12.42756741l0-68.35162074q0-12.42756741 12.4275674-12.4275674Z"></path><path d="M77.03514075 801.35585185m12.4275674 0l845.0745837 0q12.42756741 0 12.4275674 12.42756741l0 68.35162074q0 12.42756741-12.4275674 12.42756742l-845.0745837 0q-12.42756741 0-12.4275674-12.42756742l0-68.35162074q0-12.42756741 12.4275674-12.42756741Z"></path><path d="M89.46270815 304.25315556h347.9718874c6.83516208 0 12.42756741 5.59240533 12.42756742 12.42756741v410.10972445a12.42756741 12.42756741 0 0 1-12.42756742 12.4275674h-347.9718874a12.42756741 12.42756741 0 0 1-12.4275674-12.4275674v-410.10972445c0-6.83516208 5.59240533-12.42756741 12.4275674-12.42756741z"></path><path d="M512 552.8045037m12.42756741 0l410.10972444 0q12.42756741 0 12.4275674 12.42756742l0 68.35162073q0 12.42756741-12.4275674 12.42756741l-410.10972444 0q-12.42756741 0-12.42756741-12.42756741l0-68.35162073q0-12.42756741 12.42756741-12.42756742Z"></path><path d="M512 366.39099259m12.42756741 0l410.10972444 0q12.42756741 0 12.4275674 12.42756741l0 68.35162075q0 12.42756741-12.4275674 12.4275674l-410.10972444 0q-12.42756741 0-12.42756741-12.4275674l0-68.35162075q0-12.42756741 12.42756741-12.42756741Z"></path></svg>',n}return ue(n,r),n}(He),Ge=function(r){function n(){var n=r.apply(this,ce([],fe(arguments),!1))||this;return n.title=t.t("float.none"),n.value="none",n.iconSvg='<svg viewBox="0 0 1024 1024"><path d="M76.73805432 117.83964445m12.42756741 0l845.0745837 0q12.42756741 0 12.42756741 12.4275674l0 68.35162074q0 12.42756741-12.42756741 12.42756741l-845.0745837 0q-12.42756741 0-12.42756741-12.42756741l0-68.35162074q0-12.42756741 12.42756741-12.4275674Z"></path><path d="M76.73805432 801.35585185m12.42756741 0l845.0745837 0q12.42756741 0 12.42756741 12.42756741l0 68.35162074q0 12.42756741-12.42756741 12.42756742l-845.0745837 0q-12.42756741 0-12.42756741-12.42756742l0-68.35162074q0-12.42756741 12.42756741-12.42756741Z"></path><path d="M89.16562173 304.25315556h410.10972444c6.83516208 0 12.42756741 5.59240533 12.42756741 12.42756741v410.10972445a12.42756741 12.42756741 0 0 1-12.42756741 12.4275674h-410.10972444a12.42756741 12.42756741 0 0 1-12.42756741-12.4275674v-410.10972445c0-6.83516208 5.59240533-12.42756741 12.42756741-12.42756741z"></path></svg>',n}return ue(n,r),n}(He),Ke=function(r){function n(){var n=r.apply(this,ce([],fe(arguments),!1))||this;return n.title=t.t("float.right"),n.value="right",n.iconSvg='<svg viewBox="0 0 1024 1024"><path d="M77.03514075 117.83964445m12.4275674 0l845.0745837 0q12.42756741 0 12.4275674 12.4275674l0 68.35162074q0 12.42756741-12.4275674 12.42756741l-845.0745837 0q-12.42756741 0-12.4275674-12.42756741l0-68.35162074q0-12.42756741 12.4275674-12.4275674Z"></path><path d="M77.03514075 801.35585185m12.4275674 0l845.0745837 0q12.42756741 0 12.4275674 12.42756741l0 68.35162074q0 12.42756741-12.4275674 12.42756742l-845.0745837 0q-12.42756741 0-12.4275674-12.42756742l0-68.35162074q0-12.42756741 12.4275674-12.42756741Z"></path><path d="M586.56540445 304.25315556h347.9718874c6.83516208 0 12.42756741 5.59240533 12.4275674 12.42756741v410.10972445a12.42756741 12.42756741 0 0 1-12.4275674 12.4275674h-347.9718874a12.42756741 12.42756741 0 0 1-12.42756742-12.4275674v-410.10972445c0-6.83516208 5.59240533-12.42756741 12.42756742-12.42756741z"></path><path d="M77.03514075 552.8045037m12.4275674 0l410.10972444 0q12.42756741 0 12.42756741 12.42756742l0 68.35162073q0 12.42756741-12.42756741 12.42756741l-410.10972444 0q-12.42756741 0-12.4275674-12.42756741l0-68.35162073q0-12.42756741 12.4275674-12.42756742Z"></path><path d="M77.03514075 366.39099259m12.4275674 0l410.10972444 0q12.42756741 0 12.42756741 12.42756741l0 68.35162075q0 12.42756741-12.42756741 12.4275674l-410.10972444 0q-12.42756741 0-12.4275674-12.4275674l0-68.35162075q0-12.42756741 12.4275674-12.42756741Z"></path></svg>',n}return ue(n,r),n}(He),Xe={key:"imageFloatNone",factory:function(){return new Ge}},Ye={key:"imageFloatLeft",factory:function(){return new Ue}},Ve={key:"imageFloatRight",factory:function(){return new Ke}},Je={};function Qe(){if(Le)return $e;Le=1;var t=function(){if(ze)return ke;ze=1;var t=vt(),r=st();return ke=function(n){if("Function"===t(n))return r(n)}}(),r=Et(),n=w(),e=t(t.bind);return $e=function(t,o){return r(t),void 0===o?t:n?e(t,o):function(){return t.apply(o,arguments)}},$e}function to(){if(Ze)return We;Ze=1;var t=Qe(),r=st(),n=dt(),e=nr(),o=pn(),i=ne(),u=r([].push),a=function(r){var a=1===r,f=2===r,c=3===r,l=4===r,s=6===r,v=7===r,d=5===r||s;return function(p,h,g,y){for(var m,b,w=e(p),x=n(w),O=o(x),S=t(h,g),j=0,E=y||i,q=a?E(p,O):f||v?E(p,0):void 0;O>j;j++)if((d||j in x)&&(b=S(m=x[j],j,w),r))if(a)q[j]=b;else if(b)switch(r){case 3:return!0;case 5:return m;case 6:return j;case 2:u(q,m)}else switch(r){case 4:return!1;case 7:u(q,m)}return s?-1:c||l?l:q}};return We={forEach:a(0),map:a(1),filter:a(2),some:a(3),every:a(4),find:a(5),findIndex:a(6),filterReject:a(7)}}!function(){if(Be)return Je;Be=1;var t=Kn(),r=to().filter;t({target:"Array",proto:!0,forced:!ee()("filter")},{filter:function(t){return r(this,t,arguments.length>1?arguments[1]:void 0)}})}();var ro,no,eo,oo={};function io(){if(no)return ro;no=1;var t=ir(),r=De(),n=xr().f,e=t("unscopables"),o=Array.prototype;return void 0===o[e]&&n(o,e,{configurable:!0,value:r(null)}),ro=function(t){o[e][t]=!0}}!function(){if(eo)return oo;eo=1;var t=Kn(),r=to().find,n=io(),e="find",o=!0;e in[]&&Array(1)[e](function(){o=!1}),t({target:"Array",proto:!0,forced:o},{find:function(t){return r(this,t,arguments.length>1?arguments[1]:void 0)}}),n(e)}();var uo,ao,fo,co={};!function(){if(fo)return co;fo=1;var t=Jn(),r=Hr(),n=function(){if(ao)return uo;ao=1;var t=Jn(),r=Qn();return uo=t?{}.toString:function(){return"[object "+r(this)+"]"}}();t||r(Object.prototype,"toString",n,{unsafe:!0})}();var lo,so,vo,po,ho,go,yo,mo={};function bo(){return so?lo:(so=1,lo="\t\n\v\f\r \u2028\u2029\ufeff")}!function(){if(yo)return mo;yo=1;var t=Kn(),r=function(){if(po)return vo;po=1;var t=st(),r=ht(),n=ye(),e=bo(),o=t("".replace),i=RegExp("^["+e+"]+"),u=RegExp("(^|[^"+e+"])["+e+"]+$"),a=function(t){return function(e){var a=n(r(e));return 1&t&&(a=o(a,i,"")),2&t&&(a=o(a,u,"$1")),a}};return vo={start:a(1),end:a(2),trim:a(3)}}().trim,n=function(){if(go)return ho;go=1;var t=zr().PROPER,r=m(),n=bo();return ho=function(e){return r(function(){return!!n[e]()||"
"!=="
"[e]()||t&&n[e].name!==e})}}();t({target:"String",proto:!0,forced:n("trim")},{trim:function(){return r(this)}})}();var wo,xo,Oo={};function So(t,r){for(var n="",e=(t.attr("style")||"").split(";"),o=e.length,i=0;i<o;i+=1){var u=e[i];if(u){var a=u.split(":");a[0].trim()===r&&(n=a[1].trim())}}return n}xo||(xo=1,function(){if(wo)return Oo;wo=1;var t=Kn(),r=f();t({global:!0,forced:r.globalThis!==r},{globalThis:r})}()),r.css&&(r.fn.css=r.css),r.append&&(r.fn.append=r.append),r.prepend&&(r.fn.prepend=r.prepend),r.addClass&&(r.fn.addClass=r.addClass),r.removeClass&&(r.fn.removeClass=r.removeClass),r.hasClass&&(r.fn.hasClass=r.hasClass),r.on&&(r.fn.on=r.on),r.off&&(r.fn.off=r.off),r.focus&&(r.fn.focus=r.focus),r.attr&&(r.fn.attr=r.attr),r.removeAttr&&(r.fn.removeAttr=r.removeAttr),r.hide&&(r.fn.hide=r.hide),r.show&&(r.fn.show=r.show),r.parents&&(r.fn.parents=r.parents),r.dataset&&(r.fn.dataset=r.dataset),r.val&&(r.fn.val=r.val),r.text&&(r.fn.text=r.text),r.html&&(r.fn.html=r.html),r.children&&(r.fn.children=r.children),r.remove&&(r.fn.remove=r.remove),r.find&&(r.fn.find=r.find),r.width&&(r.fn.width=r.width),r.height&&(r.fn.height=r.height),r.filter&&(r.fn.filter=r.filter),r.empty&&(r.fn.empty=r.empty);var jo,Eo,qo,To,Co,Po,Ao,Io={selector:"img:not([data-w-e-type])",parseElemHtml:function(t,n,e){var o=r(t),i=o.attr("data-href")||"";return i=decodeURIComponent(i),{type:"image",src:o.attr("src")||"",alt:o.attr("alt")||"",href:i,style:{width:So(o,"width"),height:So(o,"height"),float:So(o,"float")||""},width:o.attr("width")||"",height:o.attr("height")||"",children:[{text:""}]}}},No={};function Ro(){if(Eo)return jo;Eo=1;var t=st();return jo=t(1.1.valueOf)}!function(){if(Co)return No;Co=1;var t=Kn(),r=st(),n=sn(),e=Ro(),o=function(){if(To)return qo;To=1;var t=sn(),r=ye(),n=ht(),e=RangeError;return qo=function(o){var i=r(n(this)),u="",a=t(o);if(a<0||a===1/0)throw new e("Wrong number of repetitions");for(;a>0;(a>>>=1)&&(i+=i))1&a&&(u+=i);return u}}(),i=m(),u=RangeError,a=String,f=Math.floor,c=r(o),l=r("".slice),s=r(1.1.toFixed),v=function(t,r,n){return 0===r?n:r%2==1?v(t,r-1,n*t):v(t*t,r/2,n)},d=function(t,r,n){for(var e=-1,o=n;++e<6;)o+=r*t[e],t[e]=o%1e7,o=f(o/1e7)},p=function(t,r){for(var n=6,e=0;--n>=0;)e+=t[n],t[n]=f(e/r),e=e%r*1e7},h=function(t){for(var r=6,n="";--r>=0;)if(""!==n||0===r||0!==t[r]){var e=a(t[r]);n=""===n?e:n+c("0",7-e.length)+e}return n};t({target:"Number",proto:!0,forced:i(function(){return"0.000"!==s(8e-5,3)||"1"!==s(.9,0)||"1.25"!==s(1.255,2)||"1000000000000000128"!==s(0xde0b6b3a7640080,0)})||!i(function(){s({})})},{toFixed:function(t){var r,o,i,f,s=e(this),g=n(t),y=[0,0,0,0,0,0],m="",b="0";if(g<0||g>20)throw new u("Incorrect fraction digits");if(s!=s)return"NaN";if(s<=-1e21||s>=1e21)return a(s);if(s<0&&(m="-",s=-s),s>1e-21)if(o=(r=function(t){for(var r=0,n=t;n>=4096;)r+=12,n/=4096;for(;n>=2;)r+=1,n/=2;return r}(s*v(2,69,1))-69)<0?s*v(2,-r,1):s/v(2,r,1),o*=4503599627370496,(r=52-r)>0){for(d(y,0,o),i=g;i>=7;)d(y,1e7,0),i-=7;for(d(y,v(10,i,1),0),i=r-1;i>=23;)p(y,1<<23),i-=23;p(y,1<<i),d(y,1,1),p(y,2),b=h(y)}else d(y,0,o),d(y,1<<-r,0),b=h(y)+c("0",g);return b=g>0?m+((f=b.length)<=g?"0."+c("0",g-f)+b:l(b,0,f-g)+"."+l(b,f-g)):m+b}})}();var Mo=function(){if(Ao)return Po;Ao=1;var t="Expected a function",r=/^\s+|\s+$/g,n=/^[-+]0x[0-9a-f]+$/i,o=/^0b[01]+$/i,i=/^0o[0-7]+$/i,u=parseInt,a="object"==typeof e&&e&&e.Object===Object&&e,f="object"==typeof self&&self&&self.Object===Object&&self,c=a||f||Function("return this")(),l=Object.prototype.toString,s=Math.max,v=Math.min,d=function(){return c.Date.now()};function p(r,n,e){var o,i,u,a,f,c,l=0,p=!1,y=!1,m=!0;if("function"!=typeof r)throw new TypeError(t);function b(t){var n=o,e=i;return o=i=void 0,l=t,a=r.apply(e,n)}function w(t){var r=t-c;return void 0===c||r>=n||r<0||y&&t-l>=u}function x(){var t=d();if(w(t))return O(t);f=setTimeout(x,function(t){var r=n-(t-c);return y?v(r,u-(t-l)):r}(t))}function O(t){return f=void 0,m&&o?b(t):(o=i=void 0,a)}function S(){var t=d(),r=w(t);if(o=arguments,i=this,c=t,r){if(void 0===f)return function(t){return l=t,f=setTimeout(x,n),p?b(t):a}(c);if(y)return f=setTimeout(x,n),b(c)}return void 0===f&&(f=setTimeout(x,n)),a}return n=g(n)||0,h(e)&&(p=!!e.leading,u=(y="maxWait"in e)?s(g(e.maxWait)||0,n):u,m="trailing"in e?!!e.trailing:m),S.cancel=function(){void 0!==f&&clearTimeout(f),l=0,o=c=i=f=void 0},S.flush=function(){return void 0===f?a:O(d())},S}function h(t){var r=typeof t;return!!t&&("object"==r||"function"==r)}function g(t){if("number"==typeof t)return t;if(function(t){return"symbol"==typeof t||function(t){return!!t&&"object"==typeof t}(t)&&"[object Symbol]"==l.call(t)}(t))return NaN;if(h(t)){var e="function"==typeof t.valueOf?t.valueOf():t;t=h(e)?e+"":e}if("string"!=typeof t)return 0===t?t:+t;t=t.replace(r,"");var a=o.test(t);return a||i.test(t)?u(t.slice(2),a?2:8):n.test(t)?NaN:+t}return Po=function(r,n,e){var o=!0,i=!0;if("function"!=typeof r)throw new TypeError(t);return h(e)&&(o="leading"in e?!!e.leading:o,i="trailing"in e?!!e.trailing:i),p(r,n,{leading:o,maxWait:n,trailing:i})}}(),Fo=o(Mo);function Do(r,n){var e=t.DomEditor.findKey(r,n).id;return"w-e-image-container-".concat(e)}function _o(e,o,i,u){var a=r("body"),f=Do(e,o),c=u.width,l=u.height,s=u.float,v=0,d=0,p=0,h=!1,g=null;var y=Fo(function(t){t.preventDefault();var r=t.clientX,n=d+(h?v-r:r-v),e=p*(n/d);null!=g&&(n<=15||e<=15||(g.css("width","".concat(n,"px")),g.css("height","".concat(e,"px"))))},100);function m(r){if(a.off("mousemove",y),null!=g){var n=g.width().toFixed(2),i=g.height().toFixed(2),u={style:ae(ae({},o.style),{width:"".concat(n,"px"),height:"".concat(i,"px")})};t.SlateTransforms.setNodes(e,u,{at:t.DomEditor.findPath(e,o)}),a.off("mouseup",m)}}function b(n){g=function(){var t=r("#".concat(f));if(0===t.length)throw new Error("Cannot find image container elem");return t}(),v=n;var o=g.find("img");if(0===o.length)throw new Error("Cannot find image elem");d=o.width(),p=o.height(),a.on("mousemove",y),a.on("mouseup",m);var i=t.DomEditor.getHoverbar(e);i&&i.hideAndClean()}var w={};return c&&(w.width=c),l&&(w.height=l),s&&(w.float=s),n.jsx("div",{id:f,style:w,className:"w-e-image-container w-e-selected-image-container",on:{mousedown:function(t){var n=r(t.target);n.hasClass("w-e-image-dragger")&&(t.preventDefault(),(n.hasClass("left-top")||n.hasClass("left-bottom"))&&(h=!0),b(t.clientX))}}},i,n.jsx("div",{className:"w-e-image-dragger left-top"}),n.jsx("div",{className:"w-e-image-dragger right-top"}),n.jsx("div",{className:"w-e-image-dragger left-bottom"}),n.jsx("div",{className:"w-e-image-dragger right-bottom"}))}return{renderElems:[{type:"image",renderElem:function(r,e,o){var i=r,u=i.src,a=i.alt,f=void 0===a?"":a,c=i.href,l=void 0===c?"":c,s=i.style,v=void 0===s?{}:s,d=v.width,p=void 0===d?"":d,h=v.height,g=void 0===h?"":h,y=v.float,m=t.DomEditor.isNodeSelected(o,r),b={};p&&(b.width="100%"),g&&(b.height="100%"),y&&(b.float=y);var w=n.jsx("img",{style:b,src:u,alt:f,"data-href":l}),x=o.isDisabled();return m&&!x?_o(o,r,w,{width:p,height:g,float:y}):function(t,r,e,o){var i=o.width,u=o.height,a=o.float,f={};i&&(f.width=i),u&&(f.height=u),a&&(f.float=a);var c=Do(t,r);return n.jsx("div",{id:c,style:f,className:"w-e-image-container"},e)}(o,r,w,{width:p,height:g,float:y})}}],elemsToHtml:[oe],parseElemsHtml:[Io],menus:[Ye,Ve,Xe]}});
|
1
|
+
!function(t,r){"object"==typeof exports&&"undefined"!=typeof module?module.exports=r(require("@wangeditor-next/editor"),require("dom7"),require("snabbdom")):"function"==typeof define&&define.amd?define(["@wangeditor-next/editor","dom7","snabbdom"],r):(t="undefined"!=typeof globalThis?globalThis:t||self).WangEditorFloatImagePlugin=r(t.editor,t.$,t.snabbdom)}(this,function(t,r,n){"use strict";t.i18nAddResources("en",{float:{none:"Default",left:"Float Left",right:"Float Right"}}),t.i18nAddResources("zh-CN",{float:{none:"默认",left:"左浮动",right:"右浮动"}});var e="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{};function o(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}var i,u,a={};function f(){if(u)return i;u=1;var t=function(t){return t&&t.Math===Math&&t};return i=t("object"==typeof globalThis&&globalThis)||t("object"==typeof window&&window)||t("object"==typeof self&&self)||t("object"==typeof e&&e)||t("object"==typeof i&&i)||function(){return this}()||Function("return this")()}var c,l,s,v,d,p,h,g,y={};function m(){return l?c:(l=1,c=function(t){try{return!!t()}catch(t){return!0}})}function b(){if(v)return s;v=1;var t=m();return s=!t(function(){return 7!==Object.defineProperty({},1,{get:function(){return 7}})[1]})}function w(){if(p)return d;p=1;var t=m();return d=!t(function(){var t=function(){}.bind();return"function"!=typeof t||t.hasOwnProperty("prototype")})}function x(){if(g)return h;g=1;var t=w(),r=Function.prototype.call;return h=t?r.bind(r):function(){return r.apply(r,arguments)},h}var O,S,j,E,q,T,C,P,A,I,N,R,M,F,D,_,k,z,$,L,W,Z,B,H,U,G,K,X,Y,V,J,Q,tt,rt,nt,et,ot,it,ut,at,ft,ct={};function lt(){return j?S:(j=1,S=function(t,r){return{enumerable:!(1&t),configurable:!(2&t),writable:!(4&t),value:r}})}function st(){if(q)return E;q=1;var t=w(),r=Function.prototype,n=r.call,e=t&&r.bind.bind(n,n);return E=t?e:function(t){return function(){return n.apply(t,arguments)}},E}function vt(){if(C)return T;C=1;var t=st(),r=t({}.toString),n=t("".slice);return T=function(t){return n(r(t),8,-1)}}function dt(){if(A)return P;A=1;var t=st(),r=m(),n=vt(),e=Object,o=t("".split);return P=r(function(){return!e("z").propertyIsEnumerable(0)})?function(t){return"String"===n(t)?o(t,""):e(t)}:e}function pt(){return N?I:(N=1,I=function(t){return null==t})}function ht(){if(M)return R;M=1;var t=pt(),r=TypeError;return R=function(n){if(t(n))throw new r("Can't call method on "+n);return n}}function gt(){if(D)return F;D=1;var t=dt(),r=ht();return F=function(n){return t(r(n))}}function yt(){if(k)return _;k=1;var t="object"==typeof document&&document.all;return _=void 0===t&&void 0!==t?function(r){return"function"==typeof r||r===t}:function(t){return"function"==typeof t}}function mt(){if($)return z;$=1;var t=yt();return z=function(r){return"object"==typeof r?null!==r:t(r)}}function bt(){if(W)return L;W=1;var t=f(),r=yt();return L=function(n,e){return arguments.length<2?(o=t[n],r(o)?o:void 0):t[n]&&t[n][e];var o},L}function wt(){if(K)return G;K=1;var t,r,n=f(),e=function(){if(U)return H;U=1;var t=f().navigator,r=t&&t.userAgent;return H=r?String(r):""}(),o=n.process,i=n.Deno,u=o&&o.versions||i&&i.version,a=u&&u.v8;return a&&(r=(t=a.split("."))[0]>0&&t[0]<4?1:+(t[0]+t[1])),!r&&e&&(!(t=e.match(/Edge\/(\d+)/))||t[1]>=74)&&(t=e.match(/Chrome\/(\d+)/))&&(r=+t[1]),G=r}function xt(){if(Y)return X;Y=1;var t=wt(),r=m(),n=f().String;return X=!!Object.getOwnPropertySymbols&&!r(function(){var r=Symbol("symbol detection");return!n(r)||!(Object(r)instanceof Symbol)||!Symbol.sham&&t&&t<41})}function Ot(){if(J)return V;J=1;var t=xt();return V=t&&!Symbol.sham&&"symbol"==typeof Symbol.iterator}function St(){if(tt)return Q;tt=1;var t=bt(),r=yt(),n=function(){if(B)return Z;B=1;var t=st();return Z=t({}.isPrototypeOf)}(),e=Ot(),o=Object;return Q=e?function(t){return"symbol"==typeof t}:function(e){var i=t("Symbol");return r(i)&&n(i.prototype,o(e))}}function jt(){if(nt)return rt;nt=1;var t=String;return rt=function(r){try{return t(r)}catch(t){return"Object"}}}function Et(){if(ot)return et;ot=1;var t=yt(),r=jt(),n=TypeError;return et=function(e){if(t(e))return e;throw new n(r(e)+" is not a function")}}function qt(){if(ut)return it;ut=1;var t=Et(),r=pt();return it=function(n,e){var o=n[e];return r(o)?void 0:t(o)}}function Tt(){if(ft)return at;ft=1;var t=x(),r=yt(),n=mt(),e=TypeError;return at=function(o,i){var u,a;if("string"===i&&r(u=o.toString)&&!n(a=t(u,o)))return a;if(r(u=o.valueOf)&&!n(a=t(u,o)))return a;if("string"!==i&&r(u=o.toString)&&!n(a=t(u,o)))return a;throw new e("Can't convert object to primitive value")}}var Ct,Pt,At,It,Nt,Rt,Mt,Ft,Dt,_t,kt,zt,$t,Lt,Wt,Zt,Bt,Ht,Ut,Gt,Kt,Xt,Yt,Vt,Jt={exports:{}};function Qt(){if(It)return At;It=1;var t=f(),r=Object.defineProperty;return At=function(n,e){try{r(t,n,{value:e,configurable:!0,writable:!0})}catch(r){t[n]=e}return e}}function tr(){if(Nt)return Jt.exports;Nt=1;var t=Pt?Ct:(Pt=1,Ct=!1),r=f(),n=Qt(),e="__core-js_shared__",o=Jt.exports=r[e]||n(e,{});return(o.versions||(o.versions=[])).push({version:"3.45.0",mode:t?"pure":"global",copyright:"© 2014-2025 Denis Pushkarev (zloirock.ru)",license:"https://github.com/zloirock/core-js/blob/v3.45.0/LICENSE",source:"https://github.com/zloirock/core-js"}),Jt.exports}function rr(){if(Mt)return Rt;Mt=1;var t=tr();return Rt=function(r,n){return t[r]||(t[r]=n||{})}}function nr(){if(Dt)return Ft;Dt=1;var t=ht(),r=Object;return Ft=function(n){return r(t(n))}}function er(){if(kt)return _t;kt=1;var t=st(),r=nr(),n=t({}.hasOwnProperty);return _t=Object.hasOwn||function(t,e){return n(r(t),e)}}function or(){if($t)return zt;$t=1;var t=st(),r=0,n=Math.random(),e=t(1.1.toString);return zt=function(t){return"Symbol("+(void 0===t?"":t)+")_"+e(++r+n,36)}}function ir(){if(Wt)return Lt;Wt=1;var t=f(),r=rr(),n=er(),e=or(),o=xt(),i=Ot(),u=t.Symbol,a=r("wks"),c=i?u.for||u:u&&u.withoutSetter||e;return Lt=function(t){return n(a,t)||(a[t]=o&&n(u,t)?u[t]:c("Symbol."+t)),a[t]}}function ur(){if(Bt)return Zt;Bt=1;var t=x(),r=mt(),n=St(),e=qt(),o=Tt(),i=ir(),u=TypeError,a=i("toPrimitive");return Zt=function(i,f){if(!r(i)||n(i))return i;var c,l=e(i,a);if(l){if(void 0===f&&(f="default"),c=t(l,i,f),!r(c)||n(c))return c;throw new u("Can't convert object to primitive value")}return void 0===f&&(f="number"),o(i,f)}}function ar(){if(Ut)return Ht;Ut=1;var t=ur(),r=St();return Ht=function(n){var e=t(n,"string");return r(e)?e:e+""}}function fr(){if(Kt)return Gt;Kt=1;var t=f(),r=mt(),n=t.document,e=r(n)&&r(n.createElement);return Gt=function(t){return e?n.createElement(t):{}}}function cr(){if(Yt)return Xt;Yt=1;var t=b(),r=m(),n=fr();return Xt=!t&&!r(function(){return 7!==Object.defineProperty(n("div"),"a",{get:function(){return 7}}).a})}function lr(){if(Vt)return y;Vt=1;var t=b(),r=x(),n=function(){if(O)return ct;O=1;var t={}.propertyIsEnumerable,r=Object.getOwnPropertyDescriptor,n=r&&!t.call({1:2},1);return ct.f=n?function(t){var n=r(this,t);return!!n&&n.enumerable}:t,ct}(),e=lt(),o=gt(),i=ar(),u=er(),a=cr(),f=Object.getOwnPropertyDescriptor;return y.f=t?f:function(t,c){if(t=o(t),c=i(c),a)try{return f(t,c)}catch(t){}if(u(t,c))return e(!r(n.f,t,c),t[c])},y}var sr,vr,dr,pr,hr,gr,yr,mr={};function br(){if(vr)return sr;vr=1;var t=b(),r=m();return sr=t&&r(function(){return 42!==Object.defineProperty(function(){},"prototype",{value:42,writable:!1}).prototype})}function wr(){if(pr)return dr;pr=1;var t=mt(),r=String,n=TypeError;return dr=function(e){if(t(e))return e;throw new n(r(e)+" is not an object")}}function xr(){if(hr)return mr;hr=1;var t=b(),r=cr(),n=br(),e=wr(),o=ar(),i=TypeError,u=Object.defineProperty,a=Object.getOwnPropertyDescriptor,f="enumerable",c="configurable",l="writable";return mr.f=t?n?function(t,r,n){if(e(t),r=o(r),e(n),"function"==typeof t&&"prototype"===r&&"value"in n&&l in n&&!n[l]){var i=a(t,r);i&&i[l]&&(t[r]=n.value,n={configurable:c in n?n[c]:i[c],enumerable:f in n?n[f]:i[f],writable:!1})}return u(t,r,n)}:u:function(t,n,a){if(e(t),n=o(n),e(a),r)try{return u(t,n,a)}catch(t){}if("get"in a||"set"in a)throw new i("Accessors not supported");return"value"in a&&(t[n]=a.value),t},mr}function Or(){if(yr)return gr;yr=1;var t=b(),r=xr(),n=lt();return gr=t?function(t,e,o){return r.f(t,e,n(1,o))}:function(t,r,n){return t[r]=n,t}}var Sr,jr,Er,qr,Tr,Cr,Pr,Ar,Ir,Nr,Rr,Mr,Fr,Dr,_r,kr={exports:{}};function zr(){if(jr)return Sr;jr=1;var t=b(),r=er(),n=Function.prototype,e=t&&Object.getOwnPropertyDescriptor,o=r(n,"name"),i=o&&"something"===function(){}.name,u=o&&(!t||t&&e(n,"name").configurable);return Sr={EXISTS:o,PROPER:i,CONFIGURABLE:u}}function $r(){if(qr)return Er;qr=1;var t=st(),r=yt(),n=tr(),e=t(Function.toString);return r(n.inspectSource)||(n.inspectSource=function(t){return e(t)}),Er=n.inspectSource}function Lr(){if(Ar)return Pr;Ar=1;var t=rr(),r=or(),n=t("keys");return Pr=function(t){return n[t]||(n[t]=r(t))}}function Wr(){return Nr?Ir:(Nr=1,Ir={})}function Zr(){if(Mr)return Rr;Mr=1;var t,r,n,e=function(){if(Cr)return Tr;Cr=1;var t=f(),r=yt(),n=t.WeakMap;return Tr=r(n)&&/native code/.test(String(n))}(),o=f(),i=mt(),u=Or(),a=er(),c=tr(),l=Lr(),s=Wr(),v="Object already initialized",d=o.TypeError,p=o.WeakMap;if(e||c.state){var h=c.state||(c.state=new p);h.get=h.get,h.has=h.has,h.set=h.set,t=function(t,r){if(h.has(t))throw new d(v);return r.facade=t,h.set(t,r),r},r=function(t){return h.get(t)||{}},n=function(t){return h.has(t)}}else{var g=l("state");s[g]=!0,t=function(t,r){if(a(t,g))throw new d(v);return r.facade=t,u(t,g,r),r},r=function(t){return a(t,g)?t[g]:{}},n=function(t){return a(t,g)}}return Rr={set:t,get:r,has:n,enforce:function(e){return n(e)?r(e):t(e,{})},getterFor:function(t){return function(n){var e;if(!i(n)||(e=r(n)).type!==t)throw new d("Incompatible receiver, "+t+" required");return e}}}}function Br(){if(Fr)return kr.exports;Fr=1;var t=st(),r=m(),n=yt(),e=er(),o=b(),i=zr().CONFIGURABLE,u=$r(),a=Zr(),f=a.enforce,c=a.get,l=String,s=Object.defineProperty,v=t("".slice),d=t("".replace),p=t([].join),h=o&&!r(function(){return 8!==s(function(){},"length",{value:8}).length}),g=String(String).split("String"),y=kr.exports=function(t,r,n){"Symbol("===v(l(r),0,7)&&(r="["+d(l(r),/^Symbol\(([^)]*)\).*$/,"$1")+"]"),n&&n.getter&&(r="get "+r),n&&n.setter&&(r="set "+r),(!e(t,"name")||i&&t.name!==r)&&(o?s(t,"name",{value:r,configurable:!0}):t.name=r),h&&n&&e(n,"arity")&&t.length!==n.arity&&s(t,"length",{value:n.arity});try{n&&e(n,"constructor")&&n.constructor?o&&s(t,"prototype",{writable:!1}):t.prototype&&(t.prototype=void 0)}catch(t){}var u=f(t);return e(u,"source")||(u.source=p(g,"string"==typeof r?r:"")),t};return Function.prototype.toString=y(function(){return n(this)&&c(this).source||u(this)},"toString"),kr.exports}function Hr(){if(_r)return Dr;_r=1;var t=yt(),r=xr(),n=Br(),e=Qt();return Dr=function(o,i,u,a){a||(a={});var f=a.enumerable,c=void 0!==a.name?a.name:i;if(t(u)&&n(u,c,a),a.global)f?o[i]=u:e(i,u);else{try{a.unsafe?o[i]&&(f=!0):delete o[i]}catch(t){}f?o[i]=u:r.f(o,i,{value:u,enumerable:!1,configurable:!a.nonConfigurable,writable:!a.nonWritable})}return o}}var Ur,Gr,Kr,Xr,Yr,Vr,Jr,Qr,tn,rn,nn,en,on,un,an,fn,cn,ln={};function sn(){if(Xr)return Kr;Xr=1;var t=function(){if(Gr)return Ur;Gr=1;var t=Math.ceil,r=Math.floor;return Ur=Math.trunc||function(n){var e=+n;return(e>0?r:t)(e)}}();return Kr=function(r){var n=+r;return n!=n||0===n?0:t(n)}}function vn(){if(Vr)return Yr;Vr=1;var t=sn(),r=Math.max,n=Math.min;return Yr=function(e,o){var i=t(e);return i<0?r(i+o,0):n(i,o)}}function dn(){if(Qr)return Jr;Qr=1;var t=sn(),r=Math.min;return Jr=function(n){var e=t(n);return e>0?r(e,9007199254740991):0}}function pn(){if(rn)return tn;rn=1;var t=dn();return tn=function(r){return t(r.length)}}function hn(){if(un)return on;un=1;var t=st(),r=er(),n=gt(),e=function(){if(en)return nn;en=1;var t=gt(),r=vn(),n=pn(),e=function(e){return function(o,i,u){var a=t(o),f=n(a);if(0===f)return!e&&-1;var c,l=r(u,f);if(e&&i!=i){for(;f>l;)if((c=a[l++])!=c)return!0}else for(;f>l;l++)if((e||l in a)&&a[l]===i)return e||l||0;return!e&&-1}};return nn={includes:e(!0),indexOf:e(!1)}}().indexOf,o=Wr(),i=t([].push);return on=function(t,u){var a,f=n(t),c=0,l=[];for(a in f)!r(o,a)&&r(f,a)&&i(l,a);for(;u.length>c;)r(f,a=u[c++])&&(~e(l,a)||i(l,a));return l}}function gn(){return fn?an:(fn=1,an=["constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleString","toString","valueOf"])}var yn,mn,bn,wn,xn,On,Sn,jn,En,qn,Tn,Cn,Pn,An,In,Nn,Rn,Mn,Fn,Dn,_n,kn,zn,$n,Ln,Wn,Zn,Bn,Hn={};function Un(){if(bn)return mn;bn=1;var t=bt(),r=st(),n=function(){if(cn)return ln;cn=1;var t=hn(),r=gn().concat("length","prototype");return ln.f=Object.getOwnPropertyNames||function(n){return t(n,r)},ln}(),e=(yn||(yn=1,Hn.f=Object.getOwnPropertySymbols),Hn),o=wr(),i=r([].concat);return mn=t("Reflect","ownKeys")||function(t){var r=n.f(o(t)),u=e.f;return u?i(r,u(t)):r}}function Gn(){if(xn)return wn;xn=1;var t=er(),r=Un(),n=lr(),e=xr();return wn=function(o,i,u){for(var a=r(i),f=e.f,c=n.f,l=0;l<a.length;l++){var s=a[l];t(o,s)||u&&t(u,s)||f(o,s,c(i,s))}}}function Kn(){if(En)return jn;En=1;var t=f(),r=lr().f,n=Or(),e=Hr(),o=Qt(),i=Gn(),u=function(){if(Sn)return On;Sn=1;var t=m(),r=yt(),n=/#|\.prototype\./,e=function(n,e){var f=i[o(n)];return f===a||f!==u&&(r(e)?t(e):!!e)},o=e.normalize=function(t){return String(t).replace(n,".").toLowerCase()},i=e.data={},u=e.NATIVE="N",a=e.POLYFILL="P";return On=e}();return jn=function(a,f){var c,l,s,v,d,p=a.target,h=a.global,g=a.stat;if(c=h?t:g?t[p]||o(p,{}):t[p]&&t[p].prototype)for(l in f){if(v=f[l],s=a.dontCallGetSet?(d=r(c,l))&&d.value:c[l],!u(h?l:p+(g?".":"#")+l,a.forced)&&void 0!==s){if(typeof v==typeof s)continue;i(v,s)}(a.sham||s&&s.sham)&&n(v,"sham",!0),e(c,l,v,a)}}}function Xn(){if(Tn)return qn;Tn=1;var t=vt();return qn=Array.isArray||function(r){return"Array"===t(r)}}function Yn(){if(Pn)return Cn;Pn=1;var t=TypeError;return Cn=function(r){if(r>9007199254740991)throw t("Maximum allowed index exceeded");return r}}function Vn(){if(In)return An;In=1;var t=b(),r=xr(),n=lt();return An=function(e,o,i){t?r.f(e,o,n(0,i)):e[o]=i}}function Jn(){if(Rn)return Nn;Rn=1;var t={};return t[ir()("toStringTag")]="z",Nn="[object z]"===String(t)}function Qn(){if(Fn)return Mn;Fn=1;var t=Jn(),r=yt(),n=vt(),e=ir()("toStringTag"),o=Object,i="Arguments"===n(function(){return arguments}());return Mn=t?n:function(t){var u,a,f;return void 0===t?"Undefined":null===t?"Null":"string"==typeof(a=function(t,r){try{return t[r]}catch(t){}}(u=o(t),e))?a:i?n(u):"Object"===(f=n(u))&&r(u.callee)?"Arguments":f}}function te(){if(_n)return Dn;_n=1;var t=st(),r=m(),n=yt(),e=Qn(),o=bt(),i=$r(),u=function(){},a=o("Reflect","construct"),f=/^\s*(?:class|function)\b/,c=t(f.exec),l=!f.test(u),s=function(t){if(!n(t))return!1;try{return a(u,[],t),!0}catch(t){return!1}},v=function(t){if(!n(t))return!1;switch(e(t)){case"AsyncFunction":case"GeneratorFunction":case"AsyncGeneratorFunction":return!1}try{return l||!!c(f,i(t))}catch(t){return!0}};return v.sham=!0,Dn=!a||r(function(){var t;return s(s.call)||!s(Object)||!s(function(){t=!0})||t})?v:s}function re(){if(zn)return kn;zn=1;var t=Xn(),r=te(),n=mt(),e=ir()("species"),o=Array;return kn=function(i){var u;return t(i)&&(u=i.constructor,(r(u)&&(u===o||t(u.prototype))||n(u)&&null===(u=u[e]))&&(u=void 0)),void 0===u?o:u}}function ne(){if(Ln)return $n;Ln=1;var t=re();return $n=function(r,n){return new(t(r))(0===n?0:n)}}function ee(){if(Zn)return Wn;Zn=1;var t=m(),r=ir(),n=wt(),e=r("species");return Wn=function(r){return n>=51||!t(function(){var t=[];return(t.constructor={})[e]=function(){return{foo:1}},1!==t[r](Boolean).foo})}}!function(){if(Bn)return a;Bn=1;var t=Kn(),r=m(),n=Xn(),e=mt(),o=nr(),i=pn(),u=Yn(),f=Vn(),c=ne(),l=ee(),s=ir(),v=wt(),d=s("isConcatSpreadable"),p=v>=51||!r(function(){var t=[];return t[d]=!1,t.concat()[0]!==t}),h=function(t){if(!e(t))return!1;var r=t[d];return void 0!==r?!!r:n(t)};t({target:"Array",proto:!0,arity:1,forced:!p||!l("concat")},{concat:function(t){var r,n,e,a,l,s=o(this),v=c(s,0),d=0;for(r=-1,e=arguments.length;r<e;r++)if(h(l=-1===r?s:arguments[r]))for(a=i(l),u(d+a),n=0;n<a;n++,d++)n in l&&f(v,d,l[n]);else u(d+1),f(v,d++,l);return v.length=d,v}})}();var oe={type:"image",elemToHtml:function(t,r){var n=t,e=n.src,o=n.alt,i=void 0===o?"":o,u=n.href,a=void 0===u?"":u,f=n.style,c=void 0===f?{}:f,l=c.width,s=void 0===l?"":l,v=c.height,d=void 0===v?"":v,p=c.float,h=void 0===p?"":p,g="";return s&&(g+="width: ".concat(s,";")),d&&(g+="height: ".concat(d,";")),h&&(g+="float: ".concat(h,";")),'<img src="'.concat(e,'" alt="').concat(i,'" data-href="').concat(a,'" style="').concat(g,'"/>')}},ie=function(t,r){return ie=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,r){t.__proto__=r}||function(t,r){for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(t[n]=r[n])},ie(t,r)};function ue(t,r){if("function"!=typeof r&&null!==r)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");function n(){this.constructor=t}ie(t,r),t.prototype=null===r?Object.create(r):(n.prototype=r.prototype,new n)}var ae=function(){return ae=Object.assign||function(t){for(var r,n=1,e=arguments.length;n<e;n++)for(var o in r=arguments[n])Object.prototype.hasOwnProperty.call(r,o)&&(t[o]=r[o]);return t},ae.apply(this,arguments)};function fe(t,r){var n="function"==typeof Symbol&&t[Symbol.iterator];if(!n)return t;var e,o,i=n.call(t),u=[];try{for(;(void 0===r||r-- >0)&&!(e=i.next()).done;)u.push(e.value)}catch(t){o={error:t}}finally{try{e&&!e.done&&(n=i.return)&&n.call(i)}finally{if(o)throw o.error}}return u}function ce(t,r,n){if(n||2===arguments.length)for(var e,o=0,i=r.length;o<i;o++)!e&&o in r||(e||(e=Array.prototype.slice.call(r,0,o)),e[o]=r[o]);return t.concat(e||Array.prototype.slice.call(r))}"function"==typeof SuppressedError&&SuppressedError;var le,se,ve,de,pe,he,ge={};function ye(){if(se)return le;se=1;var t=Qn(),r=String;return le=function(n){if("Symbol"===t(n))throw new TypeError("Cannot convert a Symbol value to a string");return r(n)}}function me(){if(de)return ve;de=1;var t=wr();return ve=function(){var r=t(this),n="";return r.hasIndices&&(n+="d"),r.global&&(n+="g"),r.ignoreCase&&(n+="i"),r.multiline&&(n+="m"),r.dotAll&&(n+="s"),r.unicode&&(n+="u"),r.unicodeSets&&(n+="v"),r.sticky&&(n+="y"),n}}var be,we,xe,Oe,Se,je,Ee,qe,Te,Ce,Pe,Ae,Ie,Ne,Re={};function Me(){if(we)return be;we=1;var t=hn(),r=gn();return be=Object.keys||function(n){return t(n,r)}}function Fe(){if(Se)return Oe;Se=1;var t=bt();return Oe=t("document","documentElement")}function De(){if(Ee)return je;Ee=1;var t,r=wr(),n=function(){if(xe)return Re;xe=1;var t=b(),r=br(),n=xr(),e=wr(),o=gt(),i=Me();return Re.f=t&&!r?Object.defineProperties:function(t,r){e(t);for(var u,a=o(r),f=i(r),c=f.length,l=0;c>l;)n.f(t,u=f[l++],a[u]);return t},Re}(),e=gn(),o=Wr(),i=Fe(),u=fr(),a=Lr(),f="prototype",c="script",l=a("IE_PROTO"),s=function(){},v=function(t){return"<"+c+">"+t+"</"+c+">"},d=function(t){t.write(v("")),t.close();var r=t.parentWindow.Object;return t=null,r},p=function(){try{t=new ActiveXObject("htmlfile")}catch(t){}var r,n,o;p="undefined"!=typeof document?document.domain&&t?d(t):(n=u("iframe"),o="java"+c+":",n.style.display="none",i.appendChild(n),n.src=String(o),(r=n.contentWindow.document).open(),r.write(v("document.F=Object")),r.close(),r.F):d(t);for(var a=e.length;a--;)delete p[f][e[a]];return p()};return o[l]=!0,je=Object.create||function(t,e){var o;return null!==t?(s[f]=r(t),o=new s,s[f]=null,o[l]=t):o=p(),void 0===e?o:n.f(o,e)}}function _e(){if(Ie)return Ae;Ie=1;var t,r,n=x(),e=st(),o=ye(),i=me(),u=function(){if(he)return pe;he=1;var t=m(),r=f().RegExp,n=t(function(){var t=r("a","y");return t.lastIndex=2,null!==t.exec("abcd")}),e=n||t(function(){return!r("a","y").sticky}),o=n||t(function(){var t=r("^r","gy");return t.lastIndex=2,null!==t.exec("str")});return pe={BROKEN_CARET:o,MISSED_STICKY:e,UNSUPPORTED_Y:n}}(),a=rr(),c=De(),l=Zr().get,s=function(){if(Te)return qe;Te=1;var t=m(),r=f().RegExp;return qe=t(function(){var t=r(".","s");return!(t.dotAll&&t.test("\n")&&"s"===t.flags)})}(),v=function(){if(Pe)return Ce;Pe=1;var t=m(),r=f().RegExp;return Ce=t(function(){var t=r("(?<a>b)","g");return"b"!==t.exec("b").groups.a||"bc"!=="b".replace(t,"$<a>c")})}(),d=a("native-string-replace",String.prototype.replace),p=RegExp.prototype.exec,h=p,g=e("".charAt),y=e("".indexOf),b=e("".replace),w=e("".slice),O=(r=/b*/g,n(p,t=/a/,"a"),n(p,r,"a"),0!==t.lastIndex||0!==r.lastIndex),S=u.BROKEN_CARET,j=void 0!==/()??/.exec("")[1];return(O||j||S||s||v)&&(h=function(t){var r,e,u,a,f,s,v,m=this,x=l(m),E=o(t),q=x.raw;if(q)return q.lastIndex=m.lastIndex,r=n(h,q,E),m.lastIndex=q.lastIndex,r;var T=x.groups,C=S&&m.sticky,P=n(i,m),A=m.source,I=0,N=E;if(C&&(P=b(P,"y",""),-1===y(P,"g")&&(P+="g"),N=w(E,m.lastIndex),m.lastIndex>0&&(!m.multiline||m.multiline&&"\n"!==g(E,m.lastIndex-1))&&(A="(?: "+A+")",N=" "+N,I++),e=new RegExp("^(?:"+A+")",P)),j&&(e=new RegExp("^"+A+"$(?!\\s)",P)),O&&(u=m.lastIndex),a=n(p,C?e:m,N),C?a?(a.input=w(a.input,I),a[0]=w(a[0],I),a.index=m.lastIndex,m.lastIndex+=a[0].length):m.lastIndex=0:O&&a&&(m.lastIndex=m.global?a.index+a[0].length:u),j&&a&&a.length>1&&n(d,a[0],e,function(){for(f=1;f<arguments.length-2;f++)void 0===arguments[f]&&(a[f]=void 0)}),a&&T)for(a.groups=s=c(null),f=0;f<T.length;f++)s[(v=T[f])[0]]=a[v[1]];return a}),Ae=h}!function(){if(Ne)return ge;Ne=1;var t=Kn(),r=_e();t({target:"RegExp",proto:!0,forced:/./.exec!==r},{exec:r})}();var ke,ze,$e,Le,We,Ze,Be,He=function(){function r(){this.tag="button"}return r.prototype.getValue=function(t){return""},r.prototype.isActive=function(t){return!1},r.prototype.getSelectedNode=function(r){return t.DomEditor.getSelectedNodeByType(r,"image")},r.prototype.isDisabled=function(t){return null==t.selection||null==this.getSelectedNode(t)},r.prototype.exec=function(r,n){if(!this.isDisabled(r)){var e=this.getSelectedNode(r);if(null!=e){var o=t.DomEditor.getHoverbar(r);o&&o.hideAndClean();var i=e.style,u={style:ae(ae({},void 0===i?{}:i),{float:this.value})};t.SlateTransforms.setNodes(r,u,{match:function(r){return t.DomEditor.checkNodeType(r,"image")}})}}},r}(),Ue=function(r){function n(){var n=r.apply(this,ce([],fe(arguments),!1))||this;return n.title=t.t("float.left"),n.value="left",n.iconSvg='<svg viewBox="0 0 1024 1024"><path d="M77.03514075 117.83964445m12.4275674 0l845.0745837 0q12.42756741 0 12.4275674 12.4275674l0 68.35162074q0 12.42756741-12.4275674 12.42756741l-845.0745837 0q-12.42756741 0-12.4275674-12.42756741l0-68.35162074q0-12.42756741 12.4275674-12.4275674Z"></path><path d="M77.03514075 801.35585185m12.4275674 0l845.0745837 0q12.42756741 0 12.4275674 12.42756741l0 68.35162074q0 12.42756741-12.4275674 12.42756742l-845.0745837 0q-12.42756741 0-12.4275674-12.42756742l0-68.35162074q0-12.42756741 12.4275674-12.42756741Z"></path><path d="M89.46270815 304.25315556h347.9718874c6.83516208 0 12.42756741 5.59240533 12.42756742 12.42756741v410.10972445a12.42756741 12.42756741 0 0 1-12.42756742 12.4275674h-347.9718874a12.42756741 12.42756741 0 0 1-12.4275674-12.4275674v-410.10972445c0-6.83516208 5.59240533-12.42756741 12.4275674-12.42756741z"></path><path d="M512 552.8045037m12.42756741 0l410.10972444 0q12.42756741 0 12.4275674 12.42756742l0 68.35162073q0 12.42756741-12.4275674 12.42756741l-410.10972444 0q-12.42756741 0-12.42756741-12.42756741l0-68.35162073q0-12.42756741 12.42756741-12.42756742Z"></path><path d="M512 366.39099259m12.42756741 0l410.10972444 0q12.42756741 0 12.4275674 12.42756741l0 68.35162075q0 12.42756741-12.4275674 12.4275674l-410.10972444 0q-12.42756741 0-12.42756741-12.4275674l0-68.35162075q0-12.42756741 12.42756741-12.42756741Z"></path></svg>',n}return ue(n,r),n}(He),Ge=function(r){function n(){var n=r.apply(this,ce([],fe(arguments),!1))||this;return n.title=t.t("float.none"),n.value="none",n.iconSvg='<svg viewBox="0 0 1024 1024"><path d="M76.73805432 117.83964445m12.42756741 0l845.0745837 0q12.42756741 0 12.42756741 12.4275674l0 68.35162074q0 12.42756741-12.42756741 12.42756741l-845.0745837 0q-12.42756741 0-12.42756741-12.42756741l0-68.35162074q0-12.42756741 12.42756741-12.4275674Z"></path><path d="M76.73805432 801.35585185m12.42756741 0l845.0745837 0q12.42756741 0 12.42756741 12.42756741l0 68.35162074q0 12.42756741-12.42756741 12.42756742l-845.0745837 0q-12.42756741 0-12.42756741-12.42756742l0-68.35162074q0-12.42756741 12.42756741-12.42756741Z"></path><path d="M89.16562173 304.25315556h410.10972444c6.83516208 0 12.42756741 5.59240533 12.42756741 12.42756741v410.10972445a12.42756741 12.42756741 0 0 1-12.42756741 12.4275674h-410.10972444a12.42756741 12.42756741 0 0 1-12.42756741-12.4275674v-410.10972445c0-6.83516208 5.59240533-12.42756741 12.42756741-12.42756741z"></path></svg>',n}return ue(n,r),n}(He),Ke=function(r){function n(){var n=r.apply(this,ce([],fe(arguments),!1))||this;return n.title=t.t("float.right"),n.value="right",n.iconSvg='<svg viewBox="0 0 1024 1024"><path d="M77.03514075 117.83964445m12.4275674 0l845.0745837 0q12.42756741 0 12.4275674 12.4275674l0 68.35162074q0 12.42756741-12.4275674 12.42756741l-845.0745837 0q-12.42756741 0-12.4275674-12.42756741l0-68.35162074q0-12.42756741 12.4275674-12.4275674Z"></path><path d="M77.03514075 801.35585185m12.4275674 0l845.0745837 0q12.42756741 0 12.4275674 12.42756741l0 68.35162074q0 12.42756741-12.4275674 12.42756742l-845.0745837 0q-12.42756741 0-12.4275674-12.42756742l0-68.35162074q0-12.42756741 12.4275674-12.42756741Z"></path><path d="M586.56540445 304.25315556h347.9718874c6.83516208 0 12.42756741 5.59240533 12.4275674 12.42756741v410.10972445a12.42756741 12.42756741 0 0 1-12.4275674 12.4275674h-347.9718874a12.42756741 12.42756741 0 0 1-12.42756742-12.4275674v-410.10972445c0-6.83516208 5.59240533-12.42756741 12.42756742-12.42756741z"></path><path d="M77.03514075 552.8045037m12.4275674 0l410.10972444 0q12.42756741 0 12.42756741 12.42756742l0 68.35162073q0 12.42756741-12.42756741 12.42756741l-410.10972444 0q-12.42756741 0-12.4275674-12.42756741l0-68.35162073q0-12.42756741 12.4275674-12.42756742Z"></path><path d="M77.03514075 366.39099259m12.4275674 0l410.10972444 0q12.42756741 0 12.42756741 12.42756741l0 68.35162075q0 12.42756741-12.42756741 12.4275674l-410.10972444 0q-12.42756741 0-12.4275674-12.4275674l0-68.35162075q0-12.42756741 12.4275674-12.42756741Z"></path></svg>',n}return ue(n,r),n}(He),Xe={key:"imageFloatNone",factory:function(){return new Ge}},Ye={key:"imageFloatLeft",factory:function(){return new Ue}},Ve={key:"imageFloatRight",factory:function(){return new Ke}},Je={};function Qe(){if(Le)return $e;Le=1;var t=function(){if(ze)return ke;ze=1;var t=vt(),r=st();return ke=function(n){if("Function"===t(n))return r(n)}}(),r=Et(),n=w(),e=t(t.bind);return $e=function(t,o){return r(t),void 0===o?t:n?e(t,o):function(){return t.apply(o,arguments)}},$e}function to(){if(Ze)return We;Ze=1;var t=Qe(),r=st(),n=dt(),e=nr(),o=pn(),i=ne(),u=r([].push),a=function(r){var a=1===r,f=2===r,c=3===r,l=4===r,s=6===r,v=7===r,d=5===r||s;return function(p,h,g,y){for(var m,b,w=e(p),x=n(w),O=o(x),S=t(h,g),j=0,E=y||i,q=a?E(p,O):f||v?E(p,0):void 0;O>j;j++)if((d||j in x)&&(b=S(m=x[j],j,w),r))if(a)q[j]=b;else if(b)switch(r){case 3:return!0;case 5:return m;case 6:return j;case 2:u(q,m)}else switch(r){case 4:return!1;case 7:u(q,m)}return s?-1:c||l?l:q}};return We={forEach:a(0),map:a(1),filter:a(2),some:a(3),every:a(4),find:a(5),findIndex:a(6),filterReject:a(7)}}!function(){if(Be)return Je;Be=1;var t=Kn(),r=to().filter;t({target:"Array",proto:!0,forced:!ee()("filter")},{filter:function(t){return r(this,t,arguments.length>1?arguments[1]:void 0)}})}();var ro,no,eo,oo={};function io(){if(no)return ro;no=1;var t=ir(),r=De(),n=xr().f,e=t("unscopables"),o=Array.prototype;return void 0===o[e]&&n(o,e,{configurable:!0,value:r(null)}),ro=function(t){o[e][t]=!0}}!function(){if(eo)return oo;eo=1;var t=Kn(),r=to().find,n=io(),e="find",o=!0;e in[]&&Array(1)[e](function(){o=!1}),t({target:"Array",proto:!0,forced:o},{find:function(t){return r(this,t,arguments.length>1?arguments[1]:void 0)}}),n(e)}();var uo,ao,fo,co={};!function(){if(fo)return co;fo=1;var t=Jn(),r=Hr(),n=function(){if(ao)return uo;ao=1;var t=Jn(),r=Qn();return uo=t?{}.toString:function(){return"[object "+r(this)+"]"}}();t||r(Object.prototype,"toString",n,{unsafe:!0})}();var lo,so,vo,po,ho,go,yo,mo={};function bo(){return so?lo:(so=1,lo="\t\n\v\f\r \u2028\u2029\ufeff")}!function(){if(yo)return mo;yo=1;var t=Kn(),r=function(){if(po)return vo;po=1;var t=st(),r=ht(),n=ye(),e=bo(),o=t("".replace),i=RegExp("^["+e+"]+"),u=RegExp("(^|[^"+e+"])["+e+"]+$"),a=function(t){return function(e){var a=n(r(e));return 1&t&&(a=o(a,i,"")),2&t&&(a=o(a,u,"$1")),a}};return vo={start:a(1),end:a(2),trim:a(3)}}().trim,n=function(){if(go)return ho;go=1;var t=zr().PROPER,r=m(),n=bo();return ho=function(e){return r(function(){return!!n[e]()||"
"!=="
"[e]()||t&&n[e].name!==e})}}();t({target:"String",proto:!0,forced:n("trim")},{trim:function(){return r(this)}})}();var wo,xo,Oo={};function So(t,r){for(var n="",e=(t.attr("style")||"").split(";"),o=e.length,i=0;i<o;i+=1){var u=e[i];if(u){var a=u.split(":");a[0].trim()===r&&(n=a[1].trim())}}return n}xo||(xo=1,function(){if(wo)return Oo;wo=1;var t=Kn(),r=f();t({global:!0,forced:r.globalThis!==r},{globalThis:r})}()),r.css&&(r.fn.css=r.css),r.append&&(r.fn.append=r.append),r.prepend&&(r.fn.prepend=r.prepend),r.addClass&&(r.fn.addClass=r.addClass),r.removeClass&&(r.fn.removeClass=r.removeClass),r.hasClass&&(r.fn.hasClass=r.hasClass),r.on&&(r.fn.on=r.on),r.off&&(r.fn.off=r.off),r.focus&&(r.fn.focus=r.focus),r.attr&&(r.fn.attr=r.attr),r.removeAttr&&(r.fn.removeAttr=r.removeAttr),r.hide&&(r.fn.hide=r.hide),r.show&&(r.fn.show=r.show),r.parents&&(r.fn.parents=r.parents),r.dataset&&(r.fn.dataset=r.dataset),r.val&&(r.fn.val=r.val),r.text&&(r.fn.text=r.text),r.html&&(r.fn.html=r.html),r.children&&(r.fn.children=r.children),r.remove&&(r.fn.remove=r.remove),r.find&&(r.fn.find=r.find),r.width&&(r.fn.width=r.width),r.height&&(r.fn.height=r.height),r.filter&&(r.fn.filter=r.filter),r.empty&&(r.fn.empty=r.empty);var jo,Eo,qo,To,Co,Po,Ao,Io={selector:"img:not([data-w-e-type])",parseElemHtml:function(t,n,e){var o=r(t),i=o.attr("data-href")||"";return i=decodeURIComponent(i),{type:"image",src:o.attr("src")||"",alt:o.attr("alt")||"",href:i,style:{width:So(o,"width"),height:So(o,"height"),float:So(o,"float")||""},width:o.attr("width")||"",height:o.attr("height")||"",children:[{text:""}]}}},No={};function Ro(){if(Eo)return jo;Eo=1;var t=st();return jo=t(1.1.valueOf)}!function(){if(Co)return No;Co=1;var t=Kn(),r=st(),n=sn(),e=Ro(),o=function(){if(To)return qo;To=1;var t=sn(),r=ye(),n=ht(),e=RangeError;return qo=function(o){var i=r(n(this)),u="",a=t(o);if(a<0||a===1/0)throw new e("Wrong number of repetitions");for(;a>0;(a>>>=1)&&(i+=i))1&a&&(u+=i);return u}}(),i=m(),u=RangeError,a=String,f=Math.floor,c=r(o),l=r("".slice),s=r(1.1.toFixed),v=function(t,r,n){return 0===r?n:r%2==1?v(t,r-1,n*t):v(t*t,r/2,n)},d=function(t,r,n){for(var e=-1,o=n;++e<6;)o+=r*t[e],t[e]=o%1e7,o=f(o/1e7)},p=function(t,r){for(var n=6,e=0;--n>=0;)e+=t[n],t[n]=f(e/r),e=e%r*1e7},h=function(t){for(var r=6,n="";--r>=0;)if(""!==n||0===r||0!==t[r]){var e=a(t[r]);n=""===n?e:n+c("0",7-e.length)+e}return n};t({target:"Number",proto:!0,forced:i(function(){return"0.000"!==s(8e-5,3)||"1"!==s(.9,0)||"1.25"!==s(1.255,2)||"1000000000000000128"!==s(0xde0b6b3a7640080,0)})||!i(function(){s({})})},{toFixed:function(t){var r,o,i,f,s=e(this),g=n(t),y=[0,0,0,0,0,0],m="",b="0";if(g<0||g>20)throw new u("Incorrect fraction digits");if(s!=s)return"NaN";if(s<=-1e21||s>=1e21)return a(s);if(s<0&&(m="-",s=-s),s>1e-21)if(o=(r=function(t){for(var r=0,n=t;n>=4096;)r+=12,n/=4096;for(;n>=2;)r+=1,n/=2;return r}(s*v(2,69,1))-69)<0?s*v(2,-r,1):s/v(2,r,1),o*=4503599627370496,(r=52-r)>0){for(d(y,0,o),i=g;i>=7;)d(y,1e7,0),i-=7;for(d(y,v(10,i,1),0),i=r-1;i>=23;)p(y,1<<23),i-=23;p(y,1<<i),d(y,1,1),p(y,2),b=h(y)}else d(y,0,o),d(y,1<<-r,0),b=h(y)+c("0",g);return b=g>0?m+((f=b.length)<=g?"0."+c("0",g-f)+b:l(b,0,f-g)+"."+l(b,f-g)):m+b}})}();var Mo=function(){if(Ao)return Po;Ao=1;var t="Expected a function",r=/^\s+|\s+$/g,n=/^[-+]0x[0-9a-f]+$/i,o=/^0b[01]+$/i,i=/^0o[0-7]+$/i,u=parseInt,a="object"==typeof e&&e&&e.Object===Object&&e,f="object"==typeof self&&self&&self.Object===Object&&self,c=a||f||Function("return this")(),l=Object.prototype.toString,s=Math.max,v=Math.min,d=function(){return c.Date.now()};function p(r,n,e){var o,i,u,a,f,c,l=0,p=!1,y=!1,m=!0;if("function"!=typeof r)throw new TypeError(t);function b(t){var n=o,e=i;return o=i=void 0,l=t,a=r.apply(e,n)}function w(t){var r=t-c;return void 0===c||r>=n||r<0||y&&t-l>=u}function x(){var t=d();if(w(t))return O(t);f=setTimeout(x,function(t){var r=n-(t-c);return y?v(r,u-(t-l)):r}(t))}function O(t){return f=void 0,m&&o?b(t):(o=i=void 0,a)}function S(){var t=d(),r=w(t);if(o=arguments,i=this,c=t,r){if(void 0===f)return function(t){return l=t,f=setTimeout(x,n),p?b(t):a}(c);if(y)return f=setTimeout(x,n),b(c)}return void 0===f&&(f=setTimeout(x,n)),a}return n=g(n)||0,h(e)&&(p=!!e.leading,u=(y="maxWait"in e)?s(g(e.maxWait)||0,n):u,m="trailing"in e?!!e.trailing:m),S.cancel=function(){void 0!==f&&clearTimeout(f),l=0,o=c=i=f=void 0},S.flush=function(){return void 0===f?a:O(d())},S}function h(t){var r=typeof t;return!!t&&("object"==r||"function"==r)}function g(t){if("number"==typeof t)return t;if(function(t){return"symbol"==typeof t||function(t){return!!t&&"object"==typeof t}(t)&&"[object Symbol]"==l.call(t)}(t))return NaN;if(h(t)){var e="function"==typeof t.valueOf?t.valueOf():t;t=h(e)?e+"":e}if("string"!=typeof t)return 0===t?t:+t;t=t.replace(r,"");var a=o.test(t);return a||i.test(t)?u(t.slice(2),a?2:8):n.test(t)?NaN:+t}return Po=function(r,n,e){var o=!0,i=!0;if("function"!=typeof r)throw new TypeError(t);return h(e)&&(o="leading"in e?!!e.leading:o,i="trailing"in e?!!e.trailing:i),p(r,n,{leading:o,maxWait:n,trailing:i})}}(),Fo=o(Mo);function Do(r,n){var e=t.DomEditor.findKey(r,n).id;return"w-e-image-container-".concat(e)}function _o(e,o,i,u){var a=r("body"),f=Do(e,o),c=u.width,l=u.height,s=u.float,v=0,d=0,p=0,h=!1,g=null;var y=Fo(function(t){t.preventDefault();var r=t.clientX,n=d+(h?v-r:r-v),e=p*(n/d);null!=g&&(n<=15||e<=15||(g.css("width","".concat(n,"px")),g.css("height","".concat(e,"px"))))},100);function m(r){if(a.off("mousemove",y),null!=g){var n=g.width().toFixed(2),i=g.height().toFixed(2),u={style:ae(ae({},o.style),{width:"".concat(n,"px"),height:"".concat(i,"px")})};t.SlateTransforms.setNodes(e,u,{at:t.DomEditor.findPath(e,o)}),a.off("mouseup",m)}}function b(n){g=function(){var t=r("#".concat(f));if(0===t.length)throw new Error("Cannot find image container elem");return t}(),v=n;var o=g.find("img");if(0===o.length)throw new Error("Cannot find image elem");d=o.width(),p=o.height(),a.on("mousemove",y),a.on("mouseup",m);var i=t.DomEditor.getHoverbar(e);i&&i.hideAndClean()}var w={};return c&&(w.width=c),l&&(w.height=l),s&&(w.float=s),n.jsx("div",{id:f,style:w,className:"w-e-image-container w-e-selected-image-container",on:{mousedown:function(t){var n=r(t.target);n.hasClass("w-e-image-dragger")&&(t.preventDefault(),(n.hasClass("left-top")||n.hasClass("left-bottom"))&&(h=!0),b(t.clientX))}}},i,n.jsx("div",{className:"w-e-image-dragger left-top"}),n.jsx("div",{className:"w-e-image-dragger right-top"}),n.jsx("div",{className:"w-e-image-dragger left-bottom"}),n.jsx("div",{className:"w-e-image-dragger right-bottom"}))}return{renderElems:[{type:"image",renderElem:function(r,e,o){var i=r,u=i.src,a=i.alt,f=void 0===a?"":a,c=i.href,l=void 0===c?"":c,s=i.style,v=void 0===s?{}:s,d=v.width,p=void 0===d?"":d,h=v.height,g=void 0===h?"":h,y=v.float,m=t.DomEditor.isNodeSelected(o,r),b={};p&&(b.width="100%"),g&&(b.height="100%"),y&&(b.float=y);var w=n.jsx("img",{style:b,src:u,alt:f,"data-href":l}),x=o.isDisabled();return m&&!x?_o(o,r,w,{width:p,height:g,float:y}):function(t,r,e,o){var i=o.width,u=o.height,a=o.float,f={};i&&(f.width=i),u&&(f.height=u),a&&(f.float=a);var c=Do(t,r);return n.jsx("div",{id:c,style:f,className:"w-e-image-container"},e)}(o,r,w,{width:p,height:g,float:y})}}],elemsToHtml:[oe],parseElemsHtml:[Io],menus:[Ye,Ve,Xe]}});
|
2
2
|
//# sourceMappingURL=index.js.map
|