jodit 4.11.14 → 4.12.2

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.
Files changed (62) hide show
  1. package/CHANGELOG.md +36 -0
  2. package/es2015/jodit.css +1 -1
  3. package/es2015/jodit.fat.min.js +5 -5
  4. package/es2015/jodit.js +86 -7
  5. package/es2015/jodit.min.js +5 -5
  6. package/es2015/plugins/debug/debug.css +1 -1
  7. package/es2015/plugins/debug/debug.js +1 -1
  8. package/es2015/plugins/debug/debug.min.js +1 -1
  9. package/es2015/plugins/speech-recognize/speech-recognize.css +1 -1
  10. package/es2015/plugins/speech-recognize/speech-recognize.js +1 -1
  11. package/es2015/plugins/speech-recognize/speech-recognize.min.js +1 -1
  12. package/es2018/jodit.fat.min.js +5 -5
  13. package/es2018/jodit.min.js +5 -5
  14. package/es2018/plugins/debug/debug.min.js +1 -1
  15. package/es2018/plugins/speech-recognize/speech-recognize.min.js +1 -1
  16. package/es2021/jodit.css +1 -1
  17. package/es2021/jodit.fat.min.js +6 -6
  18. package/es2021/jodit.js +86 -7
  19. package/es2021/jodit.min.js +6 -6
  20. package/es2021/plugins/debug/debug.css +1 -1
  21. package/es2021/plugins/debug/debug.js +1 -1
  22. package/es2021/plugins/debug/debug.min.js +1 -1
  23. package/es2021/plugins/speech-recognize/speech-recognize.css +1 -1
  24. package/es2021/plugins/speech-recognize/speech-recognize.js +1 -1
  25. package/es2021/plugins/speech-recognize/speech-recognize.min.js +1 -1
  26. package/es2021.en/jodit.css +1 -1
  27. package/es2021.en/jodit.fat.min.js +6 -6
  28. package/es2021.en/jodit.js +86 -7
  29. package/es2021.en/jodit.min.js +7 -7
  30. package/es2021.en/plugins/debug/debug.css +1 -1
  31. package/es2021.en/plugins/debug/debug.js +1 -1
  32. package/es2021.en/plugins/debug/debug.min.js +1 -1
  33. package/es2021.en/plugins/speech-recognize/speech-recognize.css +1 -1
  34. package/es2021.en/plugins/speech-recognize/speech-recognize.js +1 -1
  35. package/es2021.en/plugins/speech-recognize/speech-recognize.min.js +1 -1
  36. package/es5/jodit.css +2 -2
  37. package/es5/jodit.fat.min.js +2 -2
  38. package/es5/jodit.js +88 -6
  39. package/es5/jodit.min.css +2 -2
  40. package/es5/jodit.min.js +2 -2
  41. package/es5/plugins/debug/debug.css +1 -1
  42. package/es5/plugins/debug/debug.js +1 -1
  43. package/es5/plugins/debug/debug.min.js +1 -1
  44. package/es5/plugins/speech-recognize/speech-recognize.css +1 -1
  45. package/es5/plugins/speech-recognize/speech-recognize.js +1 -1
  46. package/es5/plugins/speech-recognize/speech-recognize.min.js +1 -1
  47. package/es5/polyfills.fat.min.js +1 -1
  48. package/es5/polyfills.js +1 -1
  49. package/es5/polyfills.min.js +1 -1
  50. package/esm/core/constants.js +1 -1
  51. package/esm/core/helpers/utils/config-proto.d.ts +21 -0
  52. package/esm/core/helpers/utils/config-proto.js +32 -0
  53. package/esm/jodit.d.ts +44 -0
  54. package/esm/jodit.js +47 -1
  55. package/esm/modules/widget/file-selector/file-selector.js +2 -1
  56. package/esm/plugins/image-properties/ui/ui-image-main-tab.js +2 -2
  57. package/esm/plugins/link/link.js +2 -1
  58. package/esm/typings.d.ts +1 -0
  59. package/package.json +1 -1
  60. package/types/core/helpers/utils/config-proto.d.ts +21 -0
  61. package/types/jodit.d.ts +44 -0
  62. package/types/typings.d.ts +1 -0
@@ -1,11 +1,11 @@
1
1
  /*!
2
2
  * jodit - Jodit is an awesome and useful wysiwyg editor with filebrowser
3
3
  * Author: Chupurnov <chupurnov@gmail.com> (https://xdsoft.net/jodit/)
4
- * Version: v4.11.14
4
+ * Version: v4.12.2
5
5
  * Url: https://xdsoft.net/jodit/
6
6
  * License(s): MIT
7
7
  */
8
- !function(e,t){if("object"==typeof exports&&"object"==typeof module)module.exports=t();else if("function"==typeof define&&define.amd)define([],t);else{var i=t();for(var n in i)("object"==typeof exports?exports:e)[n]=i[n]}}(self,function(){return function(){var e,t,i,n,o={5266:function(e,t,i){"use strict";i.d(t,{Config:function(){return s}});var n=i(25045),o=i(81937);let r={};class s{static get defaultOptions(){return s.__defaultOptions||(s.__defaultOptions=new s),s.__defaultOptions}constructor(){(0,n._)(this,"cache",!0),(0,n._)(this,"defaultTimeout",100),(0,n._)(this,"namespace",""),(0,n._)(this,"safeMode",!1),(0,n._)(this,"width","auto"),(0,n._)(this,"height","auto"),(0,n._)(this,"safePluginsList",["about","enter","backspace","size","bold","hotkeys"]),(0,n._)(this,"commandToHotkeys",void 0),(0,n._)(this,"license",""),(0,n._)(this,"preset","custom"),(0,n._)(this,"presets",{inline:{inline:!0,toolbar:!1,toolbarInline:!0,toolbarInlineForSelection:!0,showXPathInStatusbar:!1,showCharsCounter:!1,showWordsCounter:!1,showPlaceholder:!1}}),(0,n._)(this,"ownerDocument",o.globalDocument),(0,n._)(this,"ownerWindow",o.globalWindow),(0,n._)(this,"shadowRoot",null),(0,n._)(this,"zIndex",0),(0,n._)(this,"readonly",!1),(0,n._)(this,"disabled",!1),(0,n._)(this,"activeButtonsInReadOnly",["source","fullsize","print","about","dots","selectall"]),(0,n._)(this,"allowCommandsInReadOnly",["selectall","preview","print"]),(0,n._)(this,"toolbarButtonSize","middle"),(0,n._)(this,"allowTabNavigation",!1),(0,n._)(this,"inline",!1),(0,n._)(this,"theme","default"),(0,n._)(this,"saveModeInStorage",!1),(0,n._)(this,"editorClassName",!1),(0,n._)(this,"className",!1),(0,n._)(this,"style",!1),(0,n._)(this,"containerStyle",!1),(0,n._)(this,"styleValues",{}),(0,n._)(this,"triggerChangeEvent",!0),(0,n._)(this,"direction",""),(0,n._)(this,"language","auto"),(0,n._)(this,"debugLanguage",!1),(0,n._)(this,"i18n",!1),(0,n._)(this,"tabIndex",-1),(0,n._)(this,"toolbar",!0),(0,n._)(this,"statusbar",!0),(0,n._)(this,"showTooltip",!0),(0,n._)(this,"showTooltipDelay",200),(0,n._)(this,"useNativeTooltip",!1),(0,n._)(this,"defaultActionOnPaste",o.INSERT_AS_HTML),(0,n._)(this,"enter",o.PARAGRAPH),(0,n._)(this,"iframe",!1),(0,n._)(this,"editHTMLDocumentMode",!1),(0,n._)(this,"enterBlock","br"!==this.enter?this.enter:o.PARAGRAPH),(0,n._)(this,"defaultMode",o.MODE_WYSIWYG),(0,n._)(this,"useSplitMode",!1),(0,n._)(this,"colors",{greyscale:["#000000","#434343","#666666","#999999","#B7B7B7","#CCCCCC","#D9D9D9","#EFEFEF","#F3F3F3","#FFFFFF"],palette:["#980000","#FF0000","#FF9900","#FFFF00","#00F0F0","#00FFFF","#4A86E8","#0000FF","#9900FF","#FF00FF"],full:["#E6B8AF","#F4CCCC","#FCE5CD","#FFF2CC","#D9EAD3","#D0E0E3","#C9DAF8","#CFE2F3","#D9D2E9","#EAD1DC","#DD7E6B","#EA9999","#F9CB9C","#FFE599","#B6D7A8","#A2C4C9","#A4C2F4","#9FC5E8","#B4A7D6","#D5A6BD","#CC4125","#E06666","#F6B26B","#FFD966","#93C47D","#76A5AF","#6D9EEB","#6FA8DC","#8E7CC3","#C27BA0","#A61C00","#CC0000","#E69138","#F1C232","#6AA84F","#45818E","#3C78D8","#3D85C6","#674EA7","#A64D79","#85200C","#990000","#B45F06","#BF9000","#38761D","#134F5C","#1155CC","#0B5394","#351C75","#733554","#5B0F00","#660000","#783F04","#7F6000","#274E13","#0C343D","#1C4587","#073763","#20124D","#4C1130"]}),(0,n._)(this,"colorPickerDefaultTab","background"),(0,n._)(this,"imageDefaultWidth",300),(0,n._)(this,"removeButtons",[]),(0,n._)(this,"disablePlugins",[]),(0,n._)(this,"extraPlugins",[]),(0,n._)(this,"basePath",void 0),(0,n._)(this,"extraButtons",[]),(0,n._)(this,"extraIcons",{}),(0,n._)(this,"createAttributes",{table:{style:"border-collapse:collapse;width: 100%;"}}),(0,n._)(this,"sizeLG",900),(0,n._)(this,"sizeMD",700),(0,n._)(this,"sizeSM",400),(0,n._)(this,"buttons",[{group:"font-style",buttons:[]},{group:"list",buttons:[]},{group:"font",buttons:[]},"---",{group:"script",buttons:[]},{group:"media",buttons:[]},"\n",{group:"state",buttons:[]},{group:"clipboard",buttons:[]},{group:"insert",buttons:[]},{group:"indent",buttons:[]},{group:"color",buttons:[]},{group:"form",buttons:[]},"---",{group:"history",buttons:[]},{group:"search",buttons:[]},{group:"source",buttons:[]},{group:"other",buttons:[]},{group:"info",buttons:[]}]),(0,n._)(this,"controls",void 0),(0,n._)(this,"events",{}),(0,n._)(this,"textIcons",!1),(0,n._)(this,"popupRoot",null),(0,n._)(this,"showBrowserColorPicker",!0),Object.assign(this,r)}}(0,n._)(s,"__defaultOptions",void 0),r=s.prototype,s.prototype.controls={}},24735:function(e,t,i){"use strict";i.d(t,{Async:function(){return m}});var n=i(25045),o=i(81937),r=i(61077),s=i(72068),a=i(91565),l=i(72412),u=i(62101),c=i(52100),d=i(85932),h=i(18303),p=i(28712),f=i(14228);class m{delay(e){return this.promise(t=>this.setTimeout(t,e))}setTimeout(e,t,...i){if(this.isDestructed)return 0;let n={};(0,h.isVoid)(t)&&(t=0),(0,l.isNumber)(t)||(t=(n=t).timeout||0),n.label&&this.clearLabel(n.label);let o=(0,r.setTimeout)(e,t,...i),s=n.label||o;return this.timers.set(s,o),this.__callbacks.set(s,e),o}updateTimeout(e,t){if((0,p.assert)(e&&this.timers.has(e),"Label does not exist"),!e||!this.timers.has(e))return null;let i=this.__callbacks.get(e);return(0,p.assert)((0,a.isFunction)(i),"Callback is not a function"),this.setTimeout(i,{label:e,timeout:t})}clearLabel(e){e&&this.timers.has(e)&&((0,r.clearTimeout)(this.timers.get(e)),this.timers.delete(e),this.__callbacks.delete(e))}clearTimeout(e){if((0,d.isString)(e))return this.clearLabel(e);(0,r.clearTimeout)(e),this.timers.delete(e),this.__callbacks.delete(e)}debounce(e,t,i=!1){let n=0,o=!1,l=[],d=(...t)=>{if(!o){n=0;let i=e(...t);if(o=!0,l.length){let e=()=>{l.forEach(e=>e()),l.length=0};(0,c.isPromise)(i)?i.finally(e):e()}}},h=(...s)=>{o=!1,t?(!n&&i&&d(...s),(0,r.clearTimeout)(n),n=this.setTimeout(()=>d(...s),(0,a.isFunction)(t)?t():t),this.timers.set(e,n)):d(...s)};return(0,u.isPlainObject)(t)&&t.promisify?(...e)=>{let t=this.promise(e=>{l.push(e)}).catch(e=>{if((0,s.isAbortError)(e))return null;throw e});return h(...e),t}:h}microDebounce(e,t=!1){let i,n=!1,o=!0;return(...r)=>{if(i=r,n){o=!0;return}o=!0,t&&(o=!1,e(...i)),n=!0,this.__queueMicrotaskNative(()=>{n=!1,!this.isDestructed&&o&&e(...i)})}}throttle(e,t,i=!1){let n=null,o,r,s;return(...i)=>{(o=!0,s=i,t)?n||(r=()=>{o?(e(...s),o=!1,n=this.setTimeout(r,(0,a.isFunction)(t)?t():t),this.timers.set(r,n)):n=null})():e(...s)}}promise(e){let t=()=>{},i=new Promise((i,n)=>{t=()=>n((0,f.abort)("Abort async")),this.promisesRejections.add(t),e(i,n)});return!i.finally&&"u">typeof process&&!o.IS_ES_NEXT&&(i.finally=e=>(i.then(e).catch(e),i)),i.finally(()=>{this.promisesRejections.delete(t)}).catch(()=>null),i.rejectCallback=t,i}promiseState(e){if(e.status)return e.status;if(!Promise.race)return new Promise(t=>{e.then(e=>(t("fulfilled"),e),e=>{throw t("rejected"),e}),this.setTimeout(()=>{t("pending")},100)});let t={};return Promise.race([e,t]).then(e=>e===t?"pending":"fulfilled",()=>"rejected")}requestIdleCallback(e,t={timeout:100}){let i=this.__requestIdleCallbackNative(e,t);return this.__requestsIdle.add(i),i}requestIdlePromise(e){return this.promise(t=>{let i=this.requestIdleCallback(()=>t(i),e)})}schedulerPostTask(e,t={delay:0,priority:"user-visible"}){let i=new AbortController;if(t.signal&&t.signal.addEventListener("abort",()=>i.abort()),this.__controllers.add(i),void 0!==globalThis.scheduler){let n=globalThis.scheduler.postTask(e,{...t,signal:i.signal});return n.finally(()=>{this.__controllers.delete(i)}).catch(()=>null),n}return this.promise((n,o)=>{let r=this.setTimeout(()=>{try{n(e())}catch(e){o(e)}this.__controllers.delete(i)},t.delay||1);i.signal.addEventListener("abort",()=>{this.clearTimeout(r),this.__controllers.delete(i),o((0,f.abort)())})})}schedulerYield(){return this.schedulerPostTask(()=>{},{priority:"user-visible"})}cancelIdleCallback(e){return this.__requestsIdle.delete(e),this.__cancelIdleCallbackNative(e)}requestAnimationFrame(e){let t=requestAnimationFrame(e);return this.__requestsRaf.add(t),t}cancelAnimationFrame(e){this.__requestsRaf.delete(e),cancelAnimationFrame(e)}clear(){this.__requestsIdle.forEach(e=>this.cancelIdleCallback(e)),this.__requestsRaf.forEach(e=>this.cancelAnimationFrame(e)),this.__controllers.forEach(e=>e.abort()),this.timers.forEach(e=>(0,r.clearTimeout)(this.timers.get(e))),this.timers.clear(),this.promisesRejections.forEach(e=>e()),this.promisesRejections.clear()}destruct(){this.clear(),this.isDestructed=!0}constructor(){var e,t,i,o,r,s;(0,n._)(this,"timers",new Map),(0,n._)(this,"__callbacks",new Map),(0,n._)(this,"__queueMicrotaskNative",null!=(e=null==(o=queueMicrotask)?void 0:o.bind(window))?e:Promise.resolve().then.bind(Promise.resolve())),(0,n._)(this,"promisesRejections",new Set),(0,n._)(this,"__requestsIdle",new Set),(0,n._)(this,"__controllers",new Set),(0,n._)(this,"__requestsRaf",new Set),(0,n._)(this,"__requestIdleCallbackNative",null!=(t=null==(r=window.requestIdleCallback)?void 0:r.bind(window))?t:(e,t)=>{var i;let n=Date.now();return this.setTimeout(()=>{e({didTimeout:!1,timeRemaining:()=>Math.max(0,50-(Date.now()-n))})},null!=(i=null==t?void 0:t.timeout)?i:1)}),(0,n._)(this,"__cancelIdleCallbackNative",null!=(i=null==(s=window.cancelIdleCallback)?void 0:s.bind(window))?i:e=>{this.clearTimeout(e)}),(0,n._)(this,"isDestructed",!1)}}},91231:function(e,t,i){"use strict";i.d(t,{Async:function(){return n.Async}});var n=i(24735)},80251:function(e,t,i){"use strict";i.d(t,{Component:function(){return u}});var n=i(25045),o=i(91231),r=i(69364),s=i(28077),a=i(65946);let l=new Map;class u{get componentName(){return this.__componentName||(this.__componentName="jodit-"+(0,a.kebabCase)(((0,a.isFunction)(this.className)?this.className():"")||(0,a.getClassName)(this))),this.__componentName}getFullElName(e,t,i){let n=[this.componentName];return e&&(e=e.replace(/[^a-z0-9-]/gi,"-"),n.push(`__${e}`)),t&&(n.push("_",t),n.push("_",(0,a.isVoid)(i)?"true":i.toString())),n.join("")}get ownerDocument(){return this.ow.document}get od(){return this.ownerDocument}get ow(){return this.ownerWindow}get(e,t){return(0,a.get)(e,t||this)}get isReady(){return this.componentStatus===r.STATUSES.ready}get isDestructed(){return this.componentStatus===r.STATUSES.destructed}get isInDestruct(){return r.STATUSES.beforeDestruct===this.componentStatus||r.STATUSES.destructed===this.componentStatus}bindDestruct(e){return e.hookStatus(r.STATUSES.beforeDestruct,()=>!this.isInDestruct&&this.destruct()),this}destruct(){this.setStatus(r.STATUSES.destructed),this.async&&(this.async.destruct(),this.async=void 0),l.get(this)&&l.delete(this),this.ownerWindow=void 0}get componentStatus(){return this.__componentStatus}set componentStatus(e){this.setStatus(e)}setStatus(e){return this.setStatusComponent(e,this)}setStatusComponent(e,t){if(e===this.__componentStatus)return;t===this&&(this.__componentStatus=e);let i=Object.getPrototypeOf(this);i&&(0,a.isFunction)(i.setStatusComponent)&&i.setStatusComponent(e,t);let n=l.get(this),o=null==n?void 0:n[e];o&&o.length&&o.forEach(e=>e(t))}hookStatus(e,t){let i=l.get(this);i||(i={},l.set(this,i)),i[e]||(i[e]=[]),i[e].push(t)}static isInstanceOf(e,t){return e instanceof t}constructor(){(0,n._)(this,"__componentName",void 0),(0,n._)(this,"async",new o.Async),(0,n._)(this,"uid",void 0),(0,n._)(this,"ownerWindow",window),(0,n._)(this,"__componentStatus",r.STATUSES.beforeInit),this.uid="jodit-uid-"+(0,s.uniqueUid)()}}(0,n._)(u,"STATUSES",r.STATUSES)},16964:function(e,t,i){"use strict";i.d(t,{Component:function(){return n.Component},STATUSES:function(){return o.STATUSES},ViewComponent:function(){return r.ViewComponent}});var n=i(80251),o=i(69364),r=i(59609)},69364:function(e,t,i){"use strict";i.d(t,{STATUSES:function(){return n}});let n={beforeInit:"beforeInit",ready:"ready",beforeDestruct:"beforeDestruct",destructed:"destructed"}},59609:function(e,t,i){"use strict";i.d(t,{ViewComponent:function(){return r}});var n=i(25045),o=i(80251);class r extends o.Component{get j(){return this.jodit}get defaultTimeout(){return this.j.defaultTimeout}i18n(e,...t){return this.j.i18n(e,...t)}setParentView(e){return this.jodit=e,e.components.add(this),this}destruct(){return this.j.components.delete(this),super.destruct()}constructor(e){super(),(0,n._)(this,"jodit",void 0),this.setParentView(e)}}},81937:function(e,t,i){"use strict";i.r(t),i.d(t,{ACCURACY:function(){return V},APP_VERSION:function(){return n},BASE_PATH:function(){return eh},BASE_PATH_IS_MIN:function(){return ep},BR:function(){return W},CLIPBOARD_ID:function(){return eg},COMMAND_KEYS:function(){return U},EMULATE_DBLCLICK_TIMEOUT:function(){return et},ES:function(){return o},FAT_MODE:function(){return u},HOMEPAGE:function(){return c},INSEPARABLE_TAGS:function(){return T},INSERT_AS_HTML:function(){return ei},INSERT_AS_TEXT:function(){return eo},INSERT_CLEAR_HTML:function(){return en},INSERT_ONLY_TEXT:function(){return er},INVISIBLE_SPACE:function(){return p},INVISIBLE_SPACE_REG_EXP:function(){return m},INVISIBLE_SPACE_REG_EXP_END:function(){return g},INVISIBLE_SPACE_REG_EXP_START:function(){return v},IS_BLOCK:function(){return C},IS_ES_MODERN:function(){return r},IS_ES_NEXT:function(){return s},IS_IE:function(){return X},IS_INLINE:function(){return k},IS_MAC:function(){return ea},IS_PROD:function(){return a},IS_TEST:function(){return l},KEY_ALIASES:function(){return el},KEY_ALT:function(){return P},KEY_BACKSPACE:function(){return j},KEY_DELETE:function(){return F},KEY_DOWN:function(){return B},KEY_ENTER:function(){return L},KEY_ESC:function(){return A},KEY_F3:function(){return q},KEY_LEFT:function(){return M},KEY_META:function(){return D},KEY_RIGHT:function(){return R},KEY_SPACE:function(){return O},KEY_TAB:function(){return z},KEY_UP:function(){return N},LIST_TAGS:function(){return E},MARKER_CLASS:function(){return ee},MODE_SOURCE:function(){return K},MODE_SPLIT:function(){return G},MODE_WYSIWYG:function(){return Y},NBSP_SPACE:function(){return f},NEARBY:function(){return H},NO_EMPTY_TAGS:function(){return x},PARAGRAPH:function(){return $},PASSIVE_EVENTS:function(){return e_},SAFE_COUNT_CHANGE_CALL:function(){return es},SET_TEST:function(){return d},SOURCE_CONSUMER:function(){return ev},SPACE_REG_EXP:function(){return _},SPACE_REG_EXP_END:function(){return y},SPACE_REG_EXP_START:function(){return b},TEMP_ATTR:function(){return ef},TEXT_HTML:function(){return Z},TEXT_PLAIN:function(){return J},TEXT_RTF:function(){return Q},TOKENS:function(){return h},globalDocument:function(){return w},globalWindow:function(){return S},lang:function(){return em}});let n="4.11.14",o="es2018",r=!0,s=!1,a=!0,l=!1,u=!1,c="https://xdsoft.net/jodit/",d=()=>l=!0,h={},p="\uFEFF",f="\xa0",m=()=>/[\uFEFF]/g,g=()=>/[\uFEFF]+$/g,v=()=>/^[\uFEFF]+/g,_=()=>/[\s\n\t\r\uFEFF\u200b]+/g,b=()=>/^[\s\n\t\r\uFEFF\u200b]+/g,y=()=>/[\s\n\t\r\uFEFF\u200b]+$/g,S="u">typeof window?window:void 0,w="u">typeof document?document:void 0,C=/^(ADDRESS|ARTICLE|ASIDE|BLOCKQUOTE|CANVAS|DD|DFN|DIV|DL|DT|FIELDSET|FIGCAPTION|FIGURE|FOOTER|FORM|H[1-6]|HEADER|HGROUP|HR|LI|MAIN|NAV|NOSCRIPT|OUTPUT|P|PRE|RUBY|SCRIPT|STYLE|OBJECT|OL|SECTION|IFRAME|JODIT|JODIT-MEDIA|UL|TR|TD|TH|TBODY|THEAD|TFOOT|TABLE|BODY|HTML|VIDEO)$/i,k=/^(STRONG|SPAN|I|EM|B|SUP|SUB|A|U)$/i,E=new Set(["ul","ol"]),I=["img","video","svg","iframe","script","input","textarea","link","jodit","jodit-media"],T=new Set([...I,"br","hr"]),x=new Set(I),D="Meta",j="Backspace",z="Tab",L="Enter",A="Escape",P="Alt",M="ArrowLeft",N="ArrowUp",R="ArrowRight",B="ArrowDown",O="Space",F="Delete",q="F3",H=5,V=10,U=[D,j,F,N,B,R,M,L,A,q,z],W="br",$="p",Y=1,K=2,G=3,X="u">typeof navigator&&(-1!==navigator.userAgent.indexOf("MSIE")||/rv:11.0/i.test(navigator.userAgent)),J=X?"text":"text/plain",Z=X?"html":"text/html",Q=X?"rtf":"text/rtf",ee="jodit-selection_marker",et=300,ei="insert_as_html",en="insert_clear_html",eo="insert_as_text",er="insert_only_text",es=10,ea=void 0!==S&&/Mac|iPod|iPhone|iPad/.test(S.navigator.platform),el={add:"+",break:"pause",cmd:"meta",command:"meta",ctl:"control",ctrl:"control",del:"delete",down:"arrowdown",esc:"escape",ins:"insert",left:"arrowleft",mod:ea?"meta":"control",opt:"alt",option:"alt",return:"enter",right:"arrowright",space:"space",spacebar:"space",up:"arrowup",win:"meta",windows:"meta"},eu=e=>{let t=e.split("/");return/\.js/.test(t[t.length-1])?{basePath:t.slice(0,t.length-1).join("/")+"/",isMin:!0}:{basePath:e,isMin:!0}},{basePath:ec,isMin:ed}=(()=>{if("u"<typeof document)return{basePath:"",isMin:!0};let e=w.currentScript;if(e)return eu(e.src);let t=w.querySelectorAll("script[src]");return t&&t.length?eu(t[t.length-1].src):eu(S.location.href)})(),eh=ec,ep=ed,ef="data-jodit-temp",em={},eg="clipboard",ev="source-consumer",e_=new Set(["touchstart","touchend","scroll","mousewheel","mousemove","touchmove"])},76517:function(e,t,i){"use strict";i.d(t,{Create:function(){return l}});var n=i(25045),o=i(81937),r=i(23211),s=i(65946),a=i(28712);class l{get doc(){return(0,s.isFunction)(this.document)?this.document():this.document}element(e,t,i){let n=this.doc.createElement(e.toLowerCase());return this.applyCreateAttributes(n),t&&((0,s.isPlainObject)(t)?(0,s.attr)(n,t):i=t),i&&(0,s.asArray)(i).forEach(e=>n.appendChild((0,s.isString)(e)?this.fromHTML(e):e)),n}div(e,t,i){let n=this.element("div",t,i);return e&&(n.className=e),n}sandbox(){var e;let t=this.element("iframe",{sandbox:"allow-same-origin"});this.doc.body.appendChild(t);let i=null==(e=t.contentWindow)?void 0:e.document;if((0,a.assert)(i,"iframe.contentWindow.document"),!i)throw Error("Iframe error");return i.open(),i.write("<!DOCTYPE html><html><head></head><body></body></html>"),i.close(),[i.body,t]}span(e,t,i){let n=this.element("span",t,i);return e&&(n.className=e),n}a(e,t,i){let n=this.element("a",t,i);return e&&(n.className=e),n}text(e){return this.doc.createTextNode(e)}fake(){return this.text(o.INVISIBLE_SPACE)}fragment(){return this.doc.createDocumentFragment()}fromHTML(e,t){let i=this.div();i.innerHTML=e.toString();let n=i.firstChild===i.lastChild&&i.firstChild?i.firstChild:i;if(r.Dom.safeRemove(n),t){let e=(0,s.refs)(n);Object.keys(t).forEach(i=>{let n=e[i];n&&!1===t[i]&&r.Dom.hide(n)})}return n}applyCreateAttributes(e){if(this.createAttributes){let t=this.createAttributes;if(t&&t[e.tagName.toLowerCase()]){let i=t[e.tagName.toLowerCase()];(0,s.isFunction)(i)?i(e):(0,s.isPlainObject)(i)&&(0,s.attr)(e,i)}}}constructor(e,t){(0,n._)(this,"document",void 0),(0,n._)(this,"createAttributes",void 0),this.document=e,this.createAttributes=t}}},79821:function(e,t,i){"use strict";i.d(t,{Create:function(){return n.Create}});var n=i(76517)},49574:function(e,t,i){"use strict";i.d(t,{autobind:function(){return o}});var n=i(91565);function o(e,t,i){if(!(0,n.isFunction)(i.value))throw TypeError(`@autobind can only be applied to methods, but "${t}" is not a function`);let o=i.value;return{configurable:!0,get(){let e=o.bind(this);return Object.defineProperty(this,t,{value:e,configurable:!0,writable:!0}),e}}}},51676:function(e,t,i){"use strict";i.d(t,{cache:function(){return l},cacheHTML:function(){return u},cached:function(){return a}});var n=i(69364),o=i(23211),r=i(28686),s=i(38027);function a(e,t){let i=Object.getOwnPropertyDescriptor(e,t);return!i||(0,r.isFunction)(i.get)?null:i.value}function l(e,t,i){let n=i.get;if(!n)throw(0,s.error)("Getter property descriptor expected");i.get=function(){let e=n.call(this);return e&&!0===e.noCache||Object.defineProperty(this,t,{configurable:i.configurable,enumerable:i.enumerable,writable:!1,value:e}),e}}function u(e,t,i){let a=i.value;if(!(0,r.isFunction)(a))throw(0,s.error)("Handler must be a Function");let l=!0,u=new WeakMap;i.value=function(...e){if(l&&u.has(this.constructor)){var t;return null==(t=u.get(this.constructor))?void 0:t.cloneNode(!0)}let i=a.apply(this,e);return l&&o.Dom.isElement(i)&&u.set(this.constructor,i),l?i.cloneNode(!0):i},e.hookStatus(n.STATUSES.ready,e=>{l=!!((0,r.isViewObject)(e)?e:e.jodit).options.cache})}},91672:function(e,t,i){"use strict";i.d(t,{component:function(){return s},getComponentClass:function(){return a}});var n=i(81937),o=i(421);let r=new Map;function s(e){class t extends e{constructor(...e){super(...e),this.constructor===t&&(this instanceof t||Object.setPrototypeOf(this,t.prototype),this.setStatus("ready"))}}let i=(0,o.getClassName)(e.prototype);if(r.has(i)&&!n.IS_PROD)throw Error(`Component with name "${i}" is already registered`);return r.set(i,t),t}function a(e){return r.get(e)}},55184:function(e,t,i){"use strict";i.d(t,{debounce:function(){return a},throttle:function(){return l}});var n=i(16964),o=i(28686),r=i(28712),s=i(33201);function a(e,t=!1,i="debounce"){return(a,l)=>{let u=a[l];if(!(0,o.isFunction)(u))throw(0,s.error)("Handler must be a Function");return a.hookStatus(n.STATUSES.ready,n=>{let{async:s}=n;(0,r.assert)(null!=s,`Component ${n.componentName||n.constructor.name} should have "async:IAsync" field`);let a=(0,o.isFunction)(e)?e(n):e,u=(0,o.isNumber)(a)||(0,o.isPlainObject)(a)?a:n.defaultTimeout;Object.defineProperty(n,l,{configurable:!0,value:s[i](n[l].bind(n),u,t)})}),{configurable:!0,get(){return u.bind(this)}}}}function l(e,t=!1){return a(e,t,"throttle")}},24968:function(e,t,i){"use strict";i.d(t,{derive:function(){return o}});var n=i(91565);function o(...e){return t=>{let i=t.prototype;for(let t=0;t<e.length;t++){let o=e[t],r=Object.getOwnPropertyNames(o.prototype);for(let e=0;e<r.length;e++){let t=r[e],s=Object.getOwnPropertyDescriptor(o.prototype,t);null!=s&&(0,n.isFunction)(s.value)&&!(0,n.isFunction)(i[t])&&Object.defineProperty(i,t,{enumerable:!0,configurable:!0,writable:!0,value:function(...e){return s.value.call(this,...e)}})}}}}},29200:function(e,t,i){"use strict";i.d(t,{hook:function(){return r}});var n=i(91565),o=i(33201);function r(e){return(t,i)=>{if(!(0,n.isFunction)(t[i]))throw(0,o.error)("Handler must be a Function");t.hookStatus(e,e=>{e[i].call(e)})}}},35718:function(e,t,i){"use strict";i.d(t,{idle:function(){return s}});var n=i(16964),o=i(91565),r=i(33201);function s(){return(e,t)=>{if(!(0,o.isFunction)(e[t]))throw(0,r.error)("Handler must be a Function");e.hookStatus(n.STATUSES.ready,e=>{let{async:i}=e,n=e[t];e[t]=(...t)=>i.requestIdleCallback(n.bind(e,...t))})}}},84839:function(e,t,i){"use strict";i.r(t),i.d(t,{autobind:function(){return n.autobind},cache:function(){return o.cache},cacheHTML:function(){return o.cacheHTML},cached:function(){return o.cached},component:function(){return r.component},debounce:function(){return s.debounce},derive:function(){return a.derive},getComponentClass:function(){return r.getComponentClass},hook:function(){return l.hook},idle:function(){return u.idle},nonenumerable:function(){return c.nonenumerable},persistent:function(){return d.persistent},throttle:function(){return s.throttle},wait:function(){return h.wait},watch:function(){return p.watch}});var n=i(49574),o=i(51676),r=i(91672),s=i(55184),a=i(24968),l=i(29200),u=i(35718),c=i(41360),d=i(77036),h=i(80840),p=i(68616)},41360:function(e,t,i){"use strict";i.d(t,{nonenumerable:function(){return n}});let n=(e,t)=>{!1!==(Object.getOwnPropertyDescriptor(e,t)||{}).enumerable&&Object.defineProperty(e,t,{enumerable:!1,set(e){Object.defineProperty(this,t,{enumerable:!1,writable:!0,value:e})}})}},77036:function(e,t,i){"use strict";i.d(t,{persistent:function(){return r}});var n=i(69364),o=i(31534);function r(e,t){e.hookStatus(n.STATUSES.ready,e=>{let i=(0,o.isViewObject)(e)?e:e.jodit,n=`${i.options.namespace}${e.componentName}_prop_${t}`,r=e[t];Object.defineProperty(e,t,{get(){var e;return null!=(e=i.storage.get(n))?e:r},set(e){i.storage.set(n,e)}})})}},80840:function(e,t,i){"use strict";i.d(t,{wait:function(){return s}});var n=i(69364),o=i(91565),r=i(33201);function s(e){return(t,i)=>{let s=t[i];if(!(0,o.isFunction)(s))throw(0,r.error)("Handler must be a Function");t.hookStatus(n.STATUSES.ready,t=>{let{async:n}=t,o=t[i],r=0;Object.defineProperty(t,i,{configurable:!0,value:function i(...s){n.clearTimeout(r),e(t)?o.apply(t,s):r=n.setTimeout(()=>i(...s),10)}})})}}},68616:function(e,t,i){"use strict";i.d(t,{watch:function(){return d}});var n=i(69364),o=i(70535),r=i(32328),s=i(91565),a=i(62101),l=i(31534),u=i(33201),c=i(71125);function d(e,t){return(i,d)=>{var h;if(!(0,s.isFunction)(i[d]))throw(0,u.error)("Handler must be a Function");let p=null==(h=null==t?void 0:t.immediately)||h,f=null==t?void 0:t.context,m=t=>{let n=(0,l.isViewObject)(t)?t:t.jodit,u=(e,...i)=>{if(!t.isInDestruct)return t[d](e,...i)};p||(u=t.async.microDebounce(u,!0)),(0,r.splitArray)(e).forEach(e=>{if(/:/.test(e)){let[i,o]=e.split(":"),r=f;i.length&&(r=t.get(i)),(0,s.isFunction)(r)&&(r=r(t)),n.events.on(r||t,o,u),r||n.events.on(o,u),t.hookStatus("beforeDestruct",()=>{n.events.off(r||t,o,u).off(o,u)});return}let r=e.split("."),[l]=r,d=r.slice(1),h=t[l];(0,a.isPlainObject)(h)&&(0,o.observable)(h).on(`change.${d.join(".")}`,u);let p=(0,c.getPropertyDescriptor)(i,l);Object.defineProperty(t,l,{configurable:!0,set(e){let i=h;i!==e&&(h=e,p&&p.set&&p.set.call(t,e),(0,a.isPlainObject)(h)&&(h=(0,o.observable)(h)).on(`change.${d.join(".")}`,u),u(l,i,h))},get(){return p&&p.get?p.get.call(t):h}})})};(0,s.isFunction)(i.hookStatus)?i.hookStatus(n.STATUSES.ready,m):m(i)}}},23211:function(e,t,i){"use strict";i.d(t,{Dom:function(){return _}});var n=i(81937),o=i(88475),r=i(17312),s=i(91565),a=i(46248),l=i(3213),u=i(85932),c=i(18303),d=i(4040),h=i(28712),p=i(7909),f=i(80991),m=i(36400),g=i(33201),v=i(71125);class _{static detach(e){for(;e&&e.firstChild;)e.removeChild(e.firstChild)}static wrapNextInline(e,t,i){let n,o=e;i.s.save();let r=!1;do r=!1,(n=o.nextSibling)&&!_.isBlock(n)&&!_.isTag(n,"br")&&(r=!0,o=n);while(r);return _.__wrapElements(t,i,e,o)}static __wrapElements(e,t,i,n){let o=(0,u.isString)(e)?t.createInside.element(e):e;i.parentNode&&i.parentNode.insertBefore(o,i);let r=i;for(;r&&(r=i.nextSibling,o.appendChild(i),i!==n&&r);)i=r;return t.s.restore(),o}static wrapInline(e,t,i){let n,o=e,r=e;i.s.save();let s=!1;do s=!1,(n=o.previousSibling)&&!_.isBlock(n)&&(s=!0,o=n);while(s);do s=!1,(n=r.nextSibling)&&!_.isBlock(n)&&(s=!0,r=n);while(s);return _.__wrapElements(t,i,o,r)}static wrap(e,t,i){let n=(0,u.isString)(t)?i.element(t):t;if(_.isNode(e)){if(!e.parentNode)throw(0,g.error)("Element should be in DOM");e.parentNode.insertBefore(n,e),n.appendChild(e)}else{let t=e.extractContents();e.insertNode(n),n.appendChild(t)}return n}static unwrap(e){let t=e.parentNode;if(t){for(;e.firstChild;)t.insertBefore(e.firstChild,e);_.safeRemove(e)}}static between(e,t,i){let n=e;for(;n&&n!==t&&!(e!==n&&i(n));){let e=n.firstChild||n.nextSibling;if(!e){for(;n&&!n.nextSibling;)n=n.parentNode;e=null==n?void 0:n.nextSibling}n=e}}static replace(e,t,i,n=!1,r=!1){let s;if((0,a.isHTML)(t)&&((0,h.assert)(i,"Need create instance for new tag"),t=i.fromHTML(t)),(0,u.isString)(t)?((0,h.assert)(i,"Need create instance for new tag"),s=i.element(t)):s=t,!r)for(;e.firstChild;)s.appendChild(e.firstChild);return n&&_.isElement(e)&&_.isElement(s)&&(0,o.toArray)(e.attributes).forEach(e=>{s.setAttribute(e.name,e.value)}),e.parentNode&&e.parentNode.replaceChild(s,e),s}static isEmptyTextNode(e){return _.isText(e)&&(!e.nodeValue||0===e.nodeValue.replace(n.INVISIBLE_SPACE_REG_EXP(),"").trim().length)}static isEmptyContent(e){return _.each(e,e=>_.isEmptyTextNode(e))}static isContentEditable(e,t){return _.isNode(e)&&!_.closest(e,e=>_.isElement(e)&&"false"===e.getAttribute("contenteditable"),t)}static isEmpty(e,t=n.NO_EMPTY_TAGS){let i;if(!e)return!0;i=(0,s.isFunction)(t)?t:e=>t.has(e.nodeName.toLowerCase());let o=e=>null==e.nodeValue||0===(0,d.trim)(e.nodeValue).length;return _.isText(e)?o(e):!(_.isElement(e)&&i(e))&&_.each(e,e=>{if(_.isText(e)&&!o(e)||_.isElement(e)&&i(e))return!1})}static isNode(e){return!!(e&&(0,u.isString)(e.nodeName)&&"number"==typeof e.nodeType&&e.childNodes&&(0,s.isFunction)(e.appendChild))}static isCell(e){return _.isNode(e)&&("TD"===e.nodeName||"TH"===e.nodeName)}static isList(e){return _.isTag(e,n.LIST_TAGS)}static isLeaf(e){return _.isTag(e,"li")}static isImage(e){return _.isNode(e)&&/^(img|svg|picture|canvas)$/i.test(e.nodeName)}static isBlock(e){return!(0,c.isVoid)(e)&&"object"==typeof e&&_.isNode(e)&&n.IS_BLOCK.test(e.nodeName)}static isText(e){return!!(e&&e.nodeType===Node.TEXT_NODE)}static isComment(e){return!!(e&&e.nodeType===Node.COMMENT_NODE)}static isElement(e){var t;return!!_.isNode(e)&&!!((null==(t=e.ownerDocument)?void 0:t.defaultView)&&e.nodeType===Node.ELEMENT_NODE)}static isFragment(e){var t;return!!_.isNode(e)&&!!((null==(t=e.ownerDocument)?void 0:t.defaultView)&&e.nodeType===Node.DOCUMENT_FRAGMENT_NODE)}static isHTMLElement(e){var t;if(!_.isNode(e))return!1;let i=null==(t=e.ownerDocument)?void 0:t.defaultView;return!!(i&&e instanceof i.HTMLElement)}static isInlineBlock(e){return _.isElement(e)&&!/^(BR|HR)$/i.test(e.tagName)&&-1!==["inline","inline-block"].indexOf((0,f.css)(e,"display").toString())}static canSplitBlock(e){return!(0,c.isVoid)(e)&&_.isHTMLElement(e)&&_.isBlock(e)&&!/^(TD|TH|CAPTION|FORM)$/.test(e.nodeName)&&void 0!==e.style&&!/^(fixed|absolute)/i.test(e.style.position)}static first(e,t){let i=null==e?void 0:e.firstChild;if(!i)return null;do{if(t(i))return i;let n=i.firstChild;if(n||(n=i.nextSibling),!n&&i.parentNode!==e){do i=i.parentNode;while(i&&!(null==i?void 0:i.nextSibling)&&i.parentNode!==e);n=null==i?void 0:i.nextSibling}i=n}while(i);return null}static last(e,t){let i=null==e?void 0:e.lastChild;if(!i)return null;do{if(t(i))return i;let n=i.lastChild;if(n||(n=i.previousSibling),!n&&i.parentNode!==e){do i=i.parentNode;while(i&&!(null==i?void 0:i.previousSibling)&&i.parentNode!==e);n=null==i?void 0:i.previousSibling}i=n}while(i);return null}static prev(e,t,i,n=!0){return _.find(e,t,i,!1,n)}static next(e,t,i,n=!0){return _.find(e,t,i,!0,n)}static prevWithClass(e,t){return _.prev(e,e=>_.isElement(e)&&e.classList.contains(t),e.parentNode)}static nextWithClass(e,t){return _.next(e,e=>_.isElement(e)&&e.classList.contains(t),e.parentNode)}static find(e,t,i,n=!0,o=!0){let r=this.nextGen(e,i,n,o),s=r.next();for(;!s.done;){if(t(s.value))return s.value;s=r.next()}return null}static*nextGen(e,t,i=!0,n=!0){let o=[],r=e;do{let t=i?r.nextSibling:r.previousSibling;for(;t;)o.unshift(t),t=i?t.nextSibling:t.previousSibling;yield*this.runInStack(e,o,i,n),r=r.parentNode}while(r&&r!==t);return null}static each(e,t,i=!0){let n=this.eachGen(e,i),o=n.next();for(;!o.done;){if(!1===t(o.value))return!1;o=n.next()}return!0}static eachGen(e,t=!0){return this.runInStack(e,[e],t)}static*runInStack(e,t,i,n=!0){for(;t.length;){let o=t.pop();if(n){let e=i?o.lastChild:o.firstChild;for(;e;)t.push(e),e=i?e.previousSibling:e.nextSibling}e!==o&&(yield o)}}static findWithCurrent(e,t,i,n="nextSibling",o="firstChild"){let r=e;do{if(t(r))return r||null;if(o&&r&&r[o]){let e=_.findWithCurrent(r[o],t,r,n,o);if(e)return e}for(;r&&!r[n]&&r!==i;)r=r.parentNode;r&&r[n]&&r!==i&&(r=r[n])}while(r&&r!==i);return null}static findSibling(e,t=!0,i=e=>!_.isEmptyTextNode(e)){let n=_.sibling(e,t);for(;n&&!i(n);)n=_.sibling(n,t);return n&&i(n)?n:null}static findNotEmptySibling(e,t){return _.findSibling(e,t,e=>{var t;return!_.isEmptyTextNode(e)&&!!(!_.isText(e)||(null==(t=e.nodeValue)?void 0:t.length)&&(0,d.trim)(e.nodeValue))})}static findNotEmptyNeighbor(e,t,i){return(0,v.call)(t?_.prev:_.next,e,e=>!!(e&&(!(_.isText(e)||_.isComment(e))||(0,d.trim)((null==e?void 0:e.nodeValue)||"").length)),i)}static sibling(e,t){return t?e.previousSibling:e.nextSibling}static up(e,t,i,n=!1){let o=e;if(!o)return null;do{if(t(o))return o;if(o===i||!o.parentNode)break;o=o.parentNode}while(o&&o!==i);return o===i&&n&&t(o)?o:null}static closest(e,t,i){let n,o=e=>e.toLowerCase();if((0,s.isFunction)(t))n=t;else if((0,r.isArray)(t)||(0,l.isSet)(t)){let e=(0,l.isSet)(t)?t:new Set(t.map(o));n=t=>!!(t&&e.has(o(t.nodeName)))}else n=e=>!!(e&&o(t)===o(e.nodeName));return _.up(e,n,i)}static furthest(e,t,i){let n=null,o=null==e?void 0:e.parentElement;for(;o&&o!==i;)t(o)&&(n=o),o=null==o?void 0:o.parentElement;return n}static appendChildFirst(e,t){let i=e.firstChild;i?i!==t&&e.insertBefore(t,i):e.appendChild(t)}static after(e,t){let{parentNode:i}=e;i&&(i.lastChild===e?i.appendChild(t):i.insertBefore(t,e.nextSibling))}static before(e,t){let{parentNode:i}=e;i&&i.insertBefore(t,e)}static prepend(e,t){e.insertBefore(t,e.firstChild)}static append(e,t){(0,r.isArray)(t)?t.forEach(t=>{this.append(e,t)}):e.appendChild(t)}static moveContent(e,t,i=!1,r=()=>!0){let s=(e.ownerDocument||n.globalDocument).createDocumentFragment();(0,o.toArray)(e.childNodes).filter(e=>!!r(e)||(_.safeRemove(e),!1)).forEach(e=>{s.appendChild(e)}),i&&t.firstChild?t.insertBefore(s,t.firstChild):t.appendChild(s)}static isOrContains(e,t,i=!1){return e===t?!i:!!(t&&e&&this.up(t,t=>t===e,e,!0))}static safeRemove(...e){e.forEach(e=>_.isNode(e)&&e.parentNode&&e.parentNode.removeChild(e))}static safeInsertNode(e,t){e.collapsed||e.deleteContents();let i=_.isFragment(t)?t.lastChild:t;e.startContainer===e.endContainer&&e.collapsed&&_.isTag(e.startContainer,n.INSEPARABLE_TAGS)?_.after(e.startContainer,t):(e.insertNode(t),i&&e.setStartBefore(i)),e.collapse(!0),[t.nextSibling,t.previousSibling].forEach(e=>_.isText(e)&&!e.nodeValue&&_.safeRemove(e))}static hide(e){e&&((0,m.dataBind)(e,"__old_display",e.style.display),e.style.display="none")}static show(e){if(!e)return;let t=(0,m.dataBind)(e,"__old_display");"none"===e.style.display&&(e.style.display=t||"")}static isTag(e,t){if(!this.isElement(e))return!1;let i=e.tagName.toLowerCase(),n=e.tagName.toUpperCase();if(t instanceof Set)return t.has(i)||t.has(n);if(Array.isArray(t))throw TypeError("Dom.isTag does not support array");return i===t||n===t}static markTemporary(e,t){return t&&(0,p.attr)(e,t),(0,p.attr)(e,n.TEMP_ATTR,!0),e}static isTemporary(e){return!!_.isElement(e)&&(_.isMarker(e)||"true"===(0,p.attr)(e,n.TEMP_ATTR))}static isMarker(e){return _.isNode(e)&&_.isTag(e,"span")&&e.hasAttribute("data-"+n.MARKER_CLASS)}static replaceTemporaryFromString(e){return e.replace(/<([a-z]+)[^>]+data-jodit-temp[^>]+>(.+?)<\/\1>/gi,"$2")}static temporaryList(e){return(0,o.toArray)(e.querySelectorAll(`[${n.TEMP_ATTR}]`))}constructor(){throw Error("Dom is static module")}}},27795:function(e,t,i){"use strict";i.d(t,{Dom:function(){return n.Dom},LazyWalker:function(){return o.LazyWalker}});var n=i(23211),o=i(1080)},1080:function(e,t,i){"use strict";i.d(t,{LazyWalker:function(){return l}});var n=i(25045),o=i(31635),r=i(49574),s=i(23211),a=i(60216);class l extends a.Eventify{setWork(e){return this.isWorked&&this.break(),this.workNodes=s.Dom.eachGen(e,!this.options.reverse),this.isFinished=!1,this._requestStarting(),this}_requestStarting(){this.__schedulerController=new AbortController,this.async.schedulerPostTask(this.__workPerform,{delay:this.options.timeout,signal:this.__schedulerController.signal}).catch(()=>null)}break(e){this.isWorked&&(this.stop(),this.emit("break",e))}end(){this.isWorked&&(this.stop(),this.emit("end",this.hadAffect),this.hadAffect=!1)}stop(){this.isWorked=!1,this.isFinished=!0,this.workNodes=null,this.async.cancelIdleCallback(this.idleId)}destruct(){super.destruct(),this.stop()}__workPerform(){if(this.workNodes){var e;this.isWorked=!0;let t=0,i=null!=(e=this.options.timeoutChunkSize)?e:50;for(;!this.isFinished&&t<=i;){let e=this.workNodes.next();if(t+=1,this.visitNode(e.value)&&(this.hadAffect=!0),e.done)return void this.end()}}else this.end();this.isFinished||this._requestStarting()}visitNode(e){var t;return!!e&&(void 0===this.options.whatToShow||e.nodeType===this.options.whatToShow)&&null!=(t=this.emit("visit",e))&&t}constructor(e,t={}){super(),(0,n._)(this,"async",void 0),(0,n._)(this,"options",void 0),(0,n._)(this,"workNodes",void 0),(0,n._)(this,"hadAffect",void 0),(0,n._)(this,"isWorked",void 0),(0,n._)(this,"isFinished",void 0),(0,n._)(this,"idleId",void 0),(0,n._)(this,"__schedulerController",void 0),this.async=e,this.options=t,this.workNodes=null,this.hadAffect=!1,this.isWorked=!1,this.isFinished=!1,this.idleId=0,this.__schedulerController=null}}(0,o.__decorate)([r.autobind],l.prototype,"__workPerform",null)},93747:function(e,t,i){"use strict";i.d(t,{EventEmitter:function(){return d}});var n=i(25045),o=i(81937),r=i(32328),s=i(17312),a=i(91565),l=i(85932),u=i(33201),c=i(18869);class d{mute(e){return this.__mutedEvents.add(null!=e?e:"*"),this}isMuted(e){return!!(e&&this.__mutedEvents.has(e))||this.__mutedEvents.has("*")}unmute(e){return this.__mutedEvents.delete(null!=e?e:"*"),this}__eachEvent(e,t){(0,r.splitArray)(e).map(e=>e.trim()).forEach(e=>{let i=e.split("."),n=i[1]||c.defaultNameSpace;t.call(this,i[0],n)})}__getStore(e){if(!e)throw(0,u.error)("Need subject");if(void 0===e[this.__key]){let t=new c.EventHandlersStore;Object.defineProperty(e,this.__key,{enumerable:!1,configurable:!0,writable:!0,value:t})}return e[this.__key]}__removeStoreFromSubject(e){void 0!==e[this.__key]&&Object.defineProperty(e,this.__key,{enumerable:!1,configurable:!0,writable:!0,value:void 0})}__triggerNativeEvent(e,t){let i=this.__doc.createEvent("HTMLEvents");(0,l.isString)(t)?i.initEvent(t,!0,!0):(i.initEvent(t.type,t.bubbles,t.cancelable),["screenX","screenY","clientX","clientY","target","srcElement","currentTarget","timeStamp","which","keyCode"].forEach(e=>{Object.defineProperty(i,e,{value:t[e],enumerable:!0})}),Object.defineProperty(i,"originalEvent",{value:t,enumerable:!0})),e.dispatchEvent(i)}get current(){return this.currents[this.currents.length-1]}on(e,t,i,n){let r,c,d,p;if((0,l.isString)(e)||(0,l.isStringArray)(e)?(r=this,c=e,d=t,p=i):(r=e,c=t,d=i,p=n),!((0,l.isString)(c)||(0,l.isStringArray)(c))||0===c.length)throw(0,u.error)("Need events names");if(!(0,a.isFunction)(d))throw(0,u.error)("Need event handler");if((0,s.isArray)(r))return r.forEach(e=>{this.on(e,c,d,p)}),this;let f=r,m=this.__getStore(f),g=this,v=function(e,...t){if(!g.isMuted(e))return d&&d.call(this,...t)};return h(f)&&(v=function(e){if(!g.isMuted(e.type)&&(g.__prepareEvent(e),d&&!1===d.call(this,e)))return e.preventDefault(),e.stopImmediatePropagation(),!1}),this.__eachEvent(c,(e,t)=>{if(0===e.length)throw(0,u.error)("Need event name");if(!1===m.indexOf(e,t,d)){let r={event:e,originalCallback:d,syntheticCallback:v};if(m.set(e,t,r,null==p?void 0:p.top),h(f)){var i,n;let t=o.PASSIVE_EVENTS.has(e)?{passive:!0,capture:null!=(i=null==p?void 0:p.capture)&&i}:null!=(n=null==p?void 0:p.capture)&&n;v.options=t,f.addEventListener(e,v,t),this.__memoryDOMSubjectToHandler(f,v)}}}),this}__memoryDOMSubjectToHandler(e,t){let i=this.__domEventsMap.get(e)||new Set;i.add(t),this.__domEventsMap.set(e,i)}__unmemoryDOMSubjectToHandler(e,t){let i=this.__domEventsMap,n=i.get(e)||new Set;n.delete(t),n.size?i.set(e,n):i.delete(e)}one(e,t,i,n){let o,r,s,a;(0,l.isString)(e)||(0,l.isStringArray)(e)?(o=this,r=e,s=t,a=i):(o=e,r=t,s=i,a=n);let u=(...e)=>(this.off(o,r,u),s(...e));return this.on(o,r,u,a),this}off(e,t,i){let n,o,r;if((0,l.isString)(e)||(0,l.isStringArray)(e)?(n=this,o=e,r=t):(n=e,o=t,r=i),(0,s.isArray)(n))return n.forEach(e=>{this.off(e,o,r)}),this;let u=n,d=this.__getStore(u);if(!((0,l.isString)(o)||(0,l.isStringArray)(o))||0===o.length)return d.namespaces().forEach(e=>{this.off(u,"."+e)}),this.__removeStoreFromSubject(u),this;let p=e=>{if(h(u)){var t;u.removeEventListener(e.event,e.syntheticCallback,null!=(t=e.syntheticCallback.options)&&t),this.__unmemoryDOMSubjectToHandler(u,e.syntheticCallback)}},f=(e,t)=>{if(""===e)return void d.events(t).forEach(e=>{""!==e&&f(e,t)});let i=d.get(e,t);if(i&&i.length)if((0,a.isFunction)(r)){let n=d.indexOf(e,t,r);!1!==n&&(p(i[n]),i.splice(n,1),i.length||d.clearEvents(t,e))}else i.forEach(p),i.length=0,d.clearEvents(t,e)};return this.__eachEvent(o,(e,t)=>{t===c.defaultNameSpace?d.namespaces().forEach(t=>{f(e,t)}):f(e,t)}),d.isEmpty()&&this.__removeStoreFromSubject(u),this}stopPropagation(e,t){let i=(0,l.isString)(e)?this:e,n=(0,l.isString)(e)?e:t;if("string"!=typeof n)throw(0,u.error)("Need event names");let o=this.__getStore(i);this.__eachEvent(n,(e,t)=>{let n=o.get(e,t);n&&this.__stopped.push(n),t===c.defaultNameSpace&&o.namespaces(!0).forEach(t=>this.stopPropagation(i,e+"."+t))})}__removeStop(e){if(e){let t=this.__stopped.indexOf(e);-1!==t&&this.__stopped.splice(0,t+1)}}__isStopped(e){return void 0!==e&&-1!==this.__stopped.indexOf(e)}fire(e,t,...i){let n,o,r=(0,l.isString)(e)?this:e,s=(0,l.isString)(e)?e:t,a=(0,l.isString)(e)?[t,...i]:i;if(!h(r)&&!(0,l.isString)(s))throw(0,u.error)("Need events names");let d=this.__getStore(r);return!(0,l.isString)(s)&&h(r)?this.__triggerNativeEvent(r,t):this.__eachEvent(s,(e,t)=>{if(h(r))this.__triggerNativeEvent(r,e);else{let i=d.get(e,t);if(i)try{[...i].every(t=>!this.__isStopped(i)&&(this.currents.push(e),o=t.syntheticCallback.call(r,e,...a),this.currents.pop(),void 0!==o&&(n=o),!0))}finally{this.__removeStop(i)}t!==c.defaultNameSpace||h(r)||d.namespaces().filter(e=>e!==t).forEach(t=>{let i=this.fire.apply(this,[r,e+"."+t,...a]);void 0!==i&&(n=i)})}}),n}destruct(){this.__isDestructed||(this.__isDestructed=!0,this.__domEventsMap.forEach((e,t)=>{this.off(t)}),this.__domEventsMap.clear(),this.__mutedEvents.clear(),this.currents.length=0,this.__stopped.length=0,this.off(this),this.__getStore(this).clear(),this.__removeStoreFromSubject(this))}constructor(e){(0,n._)(this,"__domEventsMap",new Map),(0,n._)(this,"__mutedEvents",new Set),(0,n._)(this,"__key","__JoditEventEmitterNamespaces"),(0,n._)(this,"__doc",o.globalDocument),(0,n._)(this,"__prepareEvent",e=>{!e.cancelBubble&&(e.composed&&(0,a.isFunction)(e.composedPath)&&e.composedPath()[0]&&Object.defineProperty(e,"target",{value:e.composedPath()[0],configurable:!0,enumerable:!0}),e.type.match(/^touch/)&&e.changedTouches&&e.changedTouches.length&&["clientX","clientY","pageX","pageY"].forEach(t=>{Object.defineProperty(e,t,{value:e.changedTouches[0][t],configurable:!0,enumerable:!0})}),e.originalEvent||(e.originalEvent=e),"paste"===e.type&&void 0===e.clipboardData&&this.__doc.defaultView.clipboardData&&Object.defineProperty(e,"clipboardData",{get:()=>this.__doc.defaultView.clipboardData,configurable:!0,enumerable:!0}))}),(0,n._)(this,"currents",[]),(0,n._)(this,"__stopped",[]),(0,n._)(this,"__isDestructed",!1),e&&(this.__doc=e),this.__key+=new Date().getTime()}}function h(e){return e&&(0,a.isFunction)(e.addEventListener)}},60216:function(e,t,i){"use strict";i.d(t,{Eventify:function(){return o}});var n=i(25045);class o{on(e,t){var i;return this.__map.has(e)||this.__map.set(e,new Set),null==(i=this.__map.get(e))||i.add(t),this}off(e,t){if(this.__map.has(e)){var i;null==(i=this.__map.get(e))||i.delete(t)}return this}destruct(){this.__map.clear()}emit(e,...t){let i;if(this.__map.has(e)){var n;null==(n=this.__map.get(e))||n.forEach(e=>{i=e(...t)})}return i}constructor(){(0,n._)(this,"__map",new Map)}}},42689:function(e,t,i){"use strict";i.d(t,{eventEmitter:function(){return n}});let n=new(i(93747)).EventEmitter},1496:function(e,t,i){"use strict";i.d(t,{EventEmitter:function(){return n.EventEmitter},EventHandlersStore:function(){return s.EventHandlersStore},Eventify:function(){return o.Eventify},defaultNameSpace:function(){return s.defaultNameSpace},observable:function(){return r.observable}});var n=i(93747),o=i(60216),r=i(70535),s=i(18869)},70535:function(e,t,i){"use strict";i.d(t,{observable:function(){return u}});var n=i(17312),o=i(94013),r=i(62101),s=i(71125);let a=Symbol("observable-object");function l(e){return void 0!==e[a]}function u(e){if(l(e))return e;let t={},i={},u=(t,o)=>((0,n.isArray)(t)?t.map(e=>u(e,o)):(i[t]||(i[t]=[]),i[t].push(o)),e),c=(o,...r)=>{if((0,n.isArray)(o))return void o.map(e=>c(e,...r));try{!t[o]&&i[o]&&(t[o]=!0,i[o].forEach(t=>t.call(e,...r)))}finally{t[o]=!1}},d=(t,i=[])=>{let n={};l(t)||(Object.defineProperty(t,a,{enumerable:!1,value:!0}),Object.keys(t).forEach(a=>{let l=i.concat(a).filter(e=>e.length);n[a]=t[a];let u=(0,s.getPropertyDescriptor)(t,a);Object.defineProperty(t,a,{set:t=>{let i=n[a];if(!(0,o.isFastEqual)(n[a],t)){c(["beforeChange",`beforeChange.${l.join(".")}`],a,t),(0,r.isPlainObject)(t)&&d(t,l),u&&u.set?u.set.call(e,t):n[a]=t;let o=[];c(["change",...l.reduce((e,t)=>(o.push(t),e.push(`change.${o.join(".")}`),e),[])],l.join("."),i,(null==t?void 0:t.valueOf)?t.valueOf():t)}},get:()=>u&&u.get?u.get.call(e):n[a],enumerable:!0,configurable:!0}),(0,r.isPlainObject)(n[a])&&d(n[a],l)}),Object.defineProperty(e,"on",{value:u}))};return d(e),e}},18869:function(e,t,i){"use strict";i.d(t,{EventHandlersStore:function(){return a},defaultNameSpace:function(){return s}});var n=i(25045),o=i(88475),r=i(28712);let s="JoditEventDefaultNamespace";class a{get(e,t){if(this.__store.has(t)){let i=this.__store.get(t);return(0,r.assert)(i,"-"),i[e]}}indexOf(e,t,i){let n=this.get(e,t);if(n){for(let e=0;e<n.length;e+=1)if(n[e].originalCallback===i)return e}return!1}namespaces(e=!1){let t=(0,o.toArray)(this.__store.keys());return e?t.filter(e=>e!==s):t}events(e){let t=this.__store.get(e);return t?Object.keys(t):[]}set(e,t,i,n=!1){let o=this.__store.get(t);o||(o={},this.__store.set(t,o)),void 0===o[e]&&(o[e]=[]),n?o[e].unshift(i):o[e].push(i)}clear(){this.__store.clear()}clearEvents(e,t){let i=this.__store.get(e);i&&i[t]&&(delete i[t],Object.keys(i).length||this.__store.delete(e))}isEmpty(){return 0===this.__store.size}constructor(){(0,n._)(this,"__store",new Map)}}},28077:function(e,t,i){"use strict";i.d(t,{eventEmitter:function(){return C},extendLang:function(){return b},getContainer:function(){return S},getPopupViewRoot:function(){return w},instances:function(){return p},modules:function(){return _},pluginSystem:function(){return v},uniqueUid:function(){return g}});var n=i(24497),o=i(85932),r=i(31534),s=i(74264),a=i(80991),l=i(421),u=i(85305),c=i(42689),d=i(81937),h=i(27795);let p={},f=1,m=new Set;function g(){function e(){return Math.round(f+=10*(Math.random()+1)).toString(16)}let t=e();for(;m.has(t);)t=e();return m.add(t),t}let v=new u.PluginSystem({getContainer:S}),_={},b=e=>{Object.keys(e).forEach(t=>{d.lang[t]?Object.assign(d.lang[t],e[t]):d.lang[t]=e[t]})},y=new WeakMap;function S(e,t,i="div",a=!1){let u=(0,o.isString)(t)?t:t?(0,l.getClassName)(t.prototype):"jodit-utils",c=y.get(e)||{},d=u+i,p=(0,r.isViewObject)(e)?e:e.j,f=null;if(!c[d]){let t=p.c;if(f=w(p.o,p.container,e.od.body),a&&(0,n.isJoditObject)(e)&&e.od!==e.ed){t=e.createInside;let o="style"===i?e.ed.head:e.ed.body;f=(0,n.isJoditObject)(e)&&e.o.shadowRoot?e.o.shadowRoot:o}let o=t.element(i,{className:`jodit jodit-${(0,s.kebabCase)(u)}-container jodit-box`});o.classList.add(`jodit_theme_${p.o.theme||"default"}`),f.appendChild(o),c[d]=o,e.hookStatus("beforeDestruct",()=>{p.events.off(o),h.Dom.safeRemove(o),delete c[d],Object.keys(c).length&&y.delete(e)}),y.set(e,c),p.events.fire("getContainer",o)}return c[d].classList.remove("jodit_theme_default","jodit_theme_dark"),c[d].classList.add(`jodit_theme_${p.o.theme||"default"}`),c[d]}function w(e,t,i){var n,o,r;return null!=(n=null!=(o=null!=(r=e.popupRoot)?r:e.shadowRoot)?o:h.Dom.closest(t,e=>h.Dom.isHTMLElement(e)&&(h.Dom.isTag(e,"dialog")||["fixed","absolute"].includes((0,a.css)(e,"position"))),i))?n:i}let C=c.eventEmitter},78982:function(e,t,i){"use strict";i.d(t,{asArray:function(){return o}});var n=i(17312);let o=e=>(0,n.isArray)(e)?e:[e]},45664:function(e,t,i){"use strict";i.d(t,{asArray:function(){return n.asArray},splitArray:function(){return o.splitArray},toArray:function(){return r.toArray}});var n=i(78982),o=i(32328),r=i(88475)},32328:function(e,t,i){"use strict";function n(e){return Array.isArray(e)?e:e.split(/[,\s]+/)}i.d(t,{splitArray:function(){return n}})},88475:function(e,t,i){"use strict";i.d(t,{toArray:function(){return r}});var n=i(23283),o=i(43379);let r=function(...e){var t;return((0,n.isNativeFunction)(Array.from)?Array.from:null!=(t=(0,o.reset)("Array.from"))?t:Array.from).apply(Array,e)}},61077:function(e,t,i){"use strict";i.d(t,{clearTimeout:function(){return n.clearTimeout},setTimeout:function(){return n.setTimeout}});var n=i(79947)},79947:function(e,t,i){"use strict";i.d(t,{clearTimeout:function(){return r},setTimeout:function(){return o}});var n=i(81937);function o(e,t,...i){return t?n.globalWindow.setTimeout(e,t,...i):(e.call(null,...i),0)}function r(e){n.globalWindow.clearTimeout(e)}},98740:function(e,t,i){"use strict";i.d(t,{hasBrowserColorPicker:function(){return o}});var n=i(81937);function o(){let e=!0;try{let t=n.globalDocument.createElement("input");t.type="color",t.value="!",e="color"===t.type&&"!"!==t.value}catch(t){e=!1}return e}},28686:function(e,t,i){"use strict";i.d(t,{hasBrowserColorPicker:function(){return n.hasBrowserColorPicker},hasContainer:function(){return d.hasContainer},isAbortError:function(){return o.isAbortError},isArray:function(){return r.isArray},isBoolean:function(){return s.isBoolean},isDestructable:function(){return d.isDestructable},isEqual:function(){return a.isEqual},isFastEqual:function(){return a.isFastEqual},isFunction:function(){return l.isFunction},isHTML:function(){return u.isHTML},isHtmlFromWord:function(){return c.isHtmlFromWord},isInitable:function(){return d.isInitable},isInt:function(){return h.isInt},isJoditObject:function(){return p.isJoditObject},isLicense:function(){return f.isLicense},isMarker:function(){return m.isMarker},isNativeFunction:function(){return g.isNativeFunction},isNumber:function(){return v.isNumber},isNumeric:function(){return _.isNumeric},isPlainObject:function(){return b.isPlainObject},isPromise:function(){return y.isPromise},isSet:function(){return S.isSet},isString:function(){return w.isString},isStringArray:function(){return w.isStringArray},isURL:function(){return C.isURL},isValidName:function(){return k.isValidName},isViewObject:function(){return E.isViewObject},isVoid:function(){return I.isVoid},isWindow:function(){return T.isWindow}});var n=i(98740),o=i(72068),r=i(17312),s=i(22289),a=i(94013),l=i(91565),u=i(46248),c=i(82166),d=i(52433),h=i(99732),p=i(24497),f=i(44998),m=i(23175),g=i(23283),v=i(72412),_=i(70222),b=i(62101),y=i(52100),S=i(3213),w=i(85932),C=i(91764),k=i(50083),E=i(31534),I=i(18303),T=i(3513)},72068:function(e,t,i){"use strict";function n(e){return!!e&&e instanceof DOMException&&"AbortError"===e.name}i.d(t,{isAbortError:function(){return n}})},17312:function(e,t,i){"use strict";function n(e){return Array.isArray(e)}i.d(t,{isArray:function(){return n}})},22289:function(e,t,i){"use strict";function n(e){return"boolean"==typeof e}i.d(t,{isBoolean:function(){return n}})},94013:function(e,t,i){"use strict";i.d(t,{isEqual:function(){return o},isFastEqual:function(){return r}});var n=i(3347);function o(e,t){return e===t||(0,n.stringify)(e)===(0,n.stringify)(t)}function r(e,t){return e===t}},91565:function(e,t,i){"use strict";function n(e){return"function"==typeof e}i.d(t,{isFunction:function(){return n}})},82166:function(e,t,i){"use strict";function n(e){return -1!==e.search(/<meta.*?Microsoft Excel\s[\d].*?>/)||-1!==e.search(/<meta.*?Microsoft Word\s[\d].*?>/)||-1!==e.search(/style="[^"]*mso-/)&&-1!==e.search(/<font/)}i.d(t,{isHtmlFromWord:function(){return n}})},46248:function(e,t,i){"use strict";i.d(t,{isHTML:function(){return o}});var n=i(85932);let o=e=>(0,n.isString)(e)&&/<([A-Za-z][A-Za-z0-9]*)\b[^>]*>(.*?)<\/\1>/m.test(e.replace(/[\r\n]/g,""))},52433:function(e,t,i){"use strict";i.d(t,{hasContainer:function(){return l},isDestructable:function(){return a},isInitable:function(){return s}});var n=i(23211),o=i(91565),r=i(18303);function s(e){return!(0,r.isVoid)(e)&&(0,o.isFunction)(e.init)}function a(e){return!(0,r.isVoid)(e)&&(0,o.isFunction)(e.destruct)}function l(e){return!(0,r.isVoid)(e)&&n.Dom.isElement(e.container)}},99732:function(e,t,i){"use strict";i.d(t,{isInt:function(){return r}});var n=i(70222),o=i(85932);function r(e){return(0,o.isString)(e)&&(0,n.isNumeric)(e)&&(e=parseFloat(e)),"number"==typeof e&&Number.isFinite(e)&&!(e%1)}},24497:function(e,t,i){"use strict";i.d(t,{isJoditObject:function(){return o}});var n=i(91565);function o(e){return!!(e&&e instanceof Object&&(0,n.isFunction)(e.constructor)&&("u">typeof Jodit&&e instanceof Jodit||e.isJodit))}},44998:function(e,t,i){"use strict";i.d(t,{isLicense:function(){return o}});var n=i(85932);let o=e=>(0,n.isString)(e)&&23===e.length&&/^[a-z0-9]{5}-[a-z0-9]{5}-[a-z0-9]{5}-[a-z0-9]{5}$/i.test(e)},23175:function(e,t,i){"use strict";i.d(t,{isMarker:function(){return o}});var n=i(23211);function o(e){return n.Dom.isMarker(e)}},23283:function(e,t,i){"use strict";function n(e){return!!e&&"function"===(typeof e).toLowerCase()&&(e===Function.prototype||/^\s*function\s*(\b[a-z$_][a-z0-9$_]*\b)*\s*\((|([a-z$_][a-z0-9$_]*)(\s*,[a-z$_][a-z0-9$_]*)*)\)\s*{\s*\[native code]\s*}\s*$/i.test(String(e)))}i.d(t,{isNativeFunction:function(){return n}})},72412:function(e,t,i){"use strict";function n(e){return"number"==typeof e&&!isNaN(e)&&isFinite(e)}i.d(t,{isNumber:function(){return n}})},70222:function(e,t,i){"use strict";i.d(t,{isNumeric:function(){return o}});var n=i(85932);function o(e){if((0,n.isString)(e)){if(!e.match(/^([+-])?[0-9]+(\.?)([0-9]+)?(e[0-9]+)?$/))return!1;e=parseFloat(e)}return"number"==typeof e&&!isNaN(e)&&isFinite(e)}},62101:function(e,t,i){"use strict";i.d(t,{isPlainObject:function(){return o}});var n=i(3513);function o(e){return!(!e||"object"!=typeof e||e.nodeType||(0,n.isWindow)(e))&&!(e.constructor&&!({}).hasOwnProperty.call(e.constructor.prototype,"isPrototypeOf"))}},52100:function(e,t,i){"use strict";function n(e){return e&&"function"==typeof e.then}i.d(t,{isPromise:function(){return n}})},3213:function(e,t,i){"use strict";i.d(t,{isSet:function(){return o}});var n=i(91565);function o(e){return!!e&&(0,n.isFunction)(e.has)&&(0,n.isFunction)(e.add)&&(0,n.isFunction)(e.delete)}},85932:function(e,t,i){"use strict";i.d(t,{isString:function(){return o},isStringArray:function(){return r}});var n=i(17312);function o(e){return"string"==typeof e}function r(e){return(0,n.isArray)(e)&&o(e[0])}},91764:function(e,t,i){"use strict";i.d(t,{isURL:function(){return o}});var n=i(81937);function o(e){if(e.includes(" "))return!1;if("u">typeof URL)try{let t=new URL(e);return["https:","http:","ftp:","file:","rtmp:"].includes(t.protocol)}catch(e){return!1}let t=n.globalDocument.createElement("a");return t.href=e,!!t.hostname}},50083:function(e,t,i){"use strict";function n(e){return!!e.length&&!/[^0-9A-Za-zа-яА-ЯЁё\w\-_. ]/.test(e)&&e.trim().length>0}i.d(t,{isValidName:function(){return n}})},31534:function(e,t,i){"use strict";i.d(t,{isViewObject:function(){return o}});var n=i(91565);function o(e){return!!(e&&e instanceof Object&&(0,n.isFunction)(e.constructor)&&e.isView)}},18303:function(e,t,i){"use strict";function n(e){return null==e}i.d(t,{isVoid:function(){return n}})},3513:function(e,t,i){"use strict";function n(e){return null!=e&&e===e.window}i.d(t,{isWindow:function(){return n}})},93387:function(e,t,i){"use strict";i.d(t,{colorToHex:function(){return n}});let n=e=>{if("rgba(0, 0, 0, 0)"===e||""===e)return!1;if(!e)return"#000000";if("#"===e.substr(0,1))return e;let t=/([\s\n\t\r]*?)rgb\((\d+), (\d+), (\d+)\)/.exec(e)||/([\s\n\t\r]*?)rgba\((\d+), (\d+), (\d+), ([\d.]+)\)/.exec(e);if(!t)return"#000000";let i=parseInt(t[2],10),n=parseInt(t[3],10),o=(parseInt(t[4],10)|n<<8|i<<16).toString(16).toUpperCase();for(;o.length<6;)o="0"+o;return t[1]+"#"+o}},7018:function(e,t,i){"use strict";i.d(t,{colorToHex:function(){return n.colorToHex}});var n=i(93387)},30893:function(e,t,i){"use strict";i.d(t,{applyStyles:function(){return l}});var n=i(81937),o=i(23211),r=i(4040),s=i(28723);function a(e){return e.replace(/mso-[a-z-]+:[\s]*[^;]+;/gi,"").replace(/mso-[a-z-]+:[\s]*[^";']+$/gi,"").replace(/border[a-z-]*:[\s]*[^;]+;/gi,"").replace(/([0-9.]+)(pt|cm)/gi,(e,t,i)=>{switch(i.toLowerCase()){case"pt":return(1.328*parseFloat(t)).toFixed(0)+"px";case"cm":return(.02645833*parseFloat(t)).toFixed(0)+"px"}return e})}function l(e){if(-1===e.indexOf("<html "))return e;e=(e=e.substring(e.indexOf("<html "),e.length)).substring(0,e.lastIndexOf("</html>")+7);let t=n.globalDocument.createElement("iframe");t.style.display="none",n.globalDocument.body.appendChild(t);let i="";try{let l=t.contentDocument||(t.contentWindow?t.contentWindow.document:null);if(l){l.open(),l.write(e),l.close();try{for(let e=0;e<l.styleSheets.length;e+=1){let t=l.styleSheets[e].cssRules;for(let e=0;e<t.length;e+=1)""!==t[e].selectorText&&(0,s.$$)(t[e].selectorText,l.body).forEach(i=>{i.style.cssText=a(t[e].style.cssText+";"+i.style.cssText)})}}catch(e){if(!n.IS_PROD)throw e}o.Dom.each(l.body,e=>{if(o.Dom.isElement(e)){let t=e.getAttribute("style");t&&(e.style.cssText=a(t)),e.hasAttribute("style")&&!e.getAttribute("style")&&e.removeAttribute("style")}}),i=l.firstChild?(0,r.trim)(l.body.innerHTML):""}}catch(e){}finally{o.Dom.safeRemove(t)}return i&&(e=i),(0,r.trim)(e.replace(/<(\/)?(html|colgroup|col|o:p)[^>]*>/g,"").replace(/<!--[^>]*>/g,""))}},1277:function(e,t,i){"use strict";i.d(t,{cleanFromWord:function(){return a}});var n=i(81937),o=i(23211),r=i(88475),s=i(4040);function a(e){-1!==e.indexOf("<html ")&&(e=(e=e.substring(e.indexOf("<html "),e.length)).substring(0,e.lastIndexOf("</html>")+7));let t="";try{let i=n.globalDocument.createElement("div");i.innerHTML=e;let s=[];i.firstChild&&o.Dom.each(i,e=>{if(e)switch(e.nodeType){case Node.ELEMENT_NODE:switch(e.nodeName){case"STYLE":case"LINK":case"META":s.push(e);break;case"W:SDT":case"W:SDTPR":case"FONT":o.Dom.unwrap(e);break;default:(0,r.toArray)(e.attributes).forEach(t=>{-1===["src","href","rel","content"].indexOf(t.name.toLowerCase())&&e.removeAttribute(t.name)})}break;case Node.TEXT_NODE:break;default:s.push(e)}}),o.Dom.safeRemove.apply(null,s),t=i.innerHTML}catch(e){}return t&&(e=t),(e=e.split(/(\n)/).filter(s.trim).join("\n")).replace(/<(\/)?(html|colgroup|col|o:p)[^>]*>/g,"").replace(/<!--[^>]*>/g,"")}},6609:function(e,t,i){"use strict";i.d(t,{htmlspecialchars:function(){return o}});var n=i(81937);function o(e){let t=n.globalDocument.createElement("div");return t.textContent=e,t.innerHTML}},82658:function(e,t,i){"use strict";i.d(t,{applyStyles:function(){return n.applyStyles},cleanFromWord:function(){return o.cleanFromWord},htmlspecialchars:function(){return r.htmlspecialchars},nl2br:function(){return s.nl2br},safeHTML:function(){return a.safeHTML},sanitizeHTMLElement:function(){return a.sanitizeHTMLElement},stripTags:function(){return l.stripTags}});var n=i(30893),o=i(1277),r=i(6609),s=i(48838),a=i(48155),l=i(22852)},48838:function(e,t,i){"use strict";function n(e){return e.replace(/\r\n|\r|\n/g,"<br/>")}i.d(t,{nl2br:function(){return n}})},48155:function(e,t,i){"use strict";i.d(t,{safeHTML:function(){return r},sanitizeHTMLElement:function(){return a}});var n=i(23211),o=i(93640);function r(e,t){var i;(n.Dom.isElement(e)||n.Dom.isFragment(e))&&((null!=(i=t.removeEventAttributes)?i:t.removeOnError)?(s(e),(0,o.$$)("*",e).forEach(e=>s(e))):t.removeOnError&&(a(e,t),(0,o.$$)("[onerror]",e).forEach(e=>a(e,t))),t.safeJavaScriptLink&&(a(e,t),(0,o.$$)('a[href^="javascript"]',e).forEach(e=>a(e,t))),t.safeLinksTarget&&(0,o.$$)('a[target="_blank"]',e).forEach(e=>{let t=(e.getAttribute("rel")||"").split(/\s+/).filter(Boolean);t.includes("noopener")||t.push("noopener"),t.includes("noreferrer")||t.push("noreferrer"),(0,o.attr)(e,"rel",t.join(" "))}))}function s(e){if(!n.Dom.isElement(e))return!1;let t=!1,i=[];for(let t=0;t<e.attributes.length;t++)e.attributes[t].name.toLowerCase().startsWith("on")&&i.push(e.attributes[t].name);for(let n of i)e.removeAttribute(n),t=!0;return t}function a(e,{safeJavaScriptLink:t,removeOnError:i}={safeJavaScriptLink:!0,removeOnError:!0}){if(!n.Dom.isElement(e))return!1;let r=!1;i&&e.hasAttribute("onerror")&&((0,o.attr)(e,"onerror",null),r=!0);let s=e.getAttribute("href");return t&&s&&0===s.trim().indexOf("javascript")&&((0,o.attr)(e,"href",location.protocol+"//"+s),r=!0),r}},22852:function(e,t,i){"use strict";i.d(t,{stripTags:function(){return function e(t,i=document,c=null){let d=i.createElement("div");return(0,o.isString)(t)?d.innerHTML=t:d.appendChild(t),(0,s.$$)("*",d).forEach(t=>{let o=t.parentNode;if(!o)return;if(c&&n.Dom.isTag(t,c)){let o=t.nodeName.toLowerCase(),r=n.Dom.isTag(t,u)?`%%%jodit-single-${o}%%%`:`%%%jodit-${o}%%%${e(t.innerHTML,i,c)}%%%/jodit-${o}%%%`;n.Dom.before(t,i.createTextNode(r)),n.Dom.safeRemove(t);return}if(n.Dom.isTag(t,l))return void n.Dom.safeRemove(t);if(!n.Dom.isTag(t,a))return;let r=t.nextSibling;!(n.Dom.isText(r)&&/^\s/.test(r.nodeValue||""))&&r&&o.insertBefore(i.createTextNode(" "),r)}),(0,r.trim)(d.innerText).replace(/%%%(\/)?jodit(-single)?-([\w\n]+)%%%/g,(e,t,i,n)=>`<${t?"/":""}${n}>`)}}});var n=i(23211),o=i(85932),r=i(4040),s=i(93640);let a=new Set(["div","p","br","h1","h2","h3","h4","h5","h6","hr"]),l=new Set(["script","style"]),u=new Set(["br","hr","input"])},65946:function(e,t,i){"use strict";i.r(t),i.d(t,{CamelCaseToKebabCase:function(){return c.CamelCaseToKebabCase},NUMBER_FIELDS_REG:function(){return l.NUMBER_FIELDS_REG},applyStyles:function(){return a.applyStyles},asArray:function(){return n.asArray},camelCase:function(){return c.camelCase},cleanFromWord:function(){return a.cleanFromWord},clearTimeout:function(){return o.clearTimeout},colorToHex:function(){return s.colorToHex},fuzzySearchIndex:function(){return c.fuzzySearchIndex},getContentWidth:function(){return u.getContentWidth},getScrollParent:function(){return u.getScrollParent},hasBrowserColorPicker:function(){return r.hasBrowserColorPicker},hasContainer:function(){return r.hasContainer},htmlspecialchars:function(){return a.htmlspecialchars},i18n:function(){return c.i18n},innerWidth:function(){return u.innerWidth},isAbortError:function(){return r.isAbortError},isArray:function(){return r.isArray},isBoolean:function(){return r.isBoolean},isDestructable:function(){return r.isDestructable},isEqual:function(){return r.isEqual},isFastEqual:function(){return r.isFastEqual},isFunction:function(){return r.isFunction},isHTML:function(){return r.isHTML},isHtmlFromWord:function(){return r.isHtmlFromWord},isInitable:function(){return r.isInitable},isInt:function(){return r.isInt},isJoditObject:function(){return r.isJoditObject},isLicense:function(){return r.isLicense},isMarker:function(){return r.isMarker},isNativeFunction:function(){return r.isNativeFunction},isNumber:function(){return r.isNumber},isNumeric:function(){return r.isNumeric},isPlainObject:function(){return r.isPlainObject},isPromise:function(){return r.isPromise},isSet:function(){return r.isSet},isString:function(){return r.isString},isStringArray:function(){return r.isStringArray},isURL:function(){return r.isURL},isValidName:function(){return r.isValidName},isViewObject:function(){return r.isViewObject},isVoid:function(){return r.isVoid},isWindow:function(){return r.isWindow},kebabCase:function(){return c.kebabCase},nl2br:function(){return a.nl2br},normalizeColor:function(){return l.normalizeColor},normalizeCssNumericValue:function(){return l.normalizeCssNumericValue},normalizeCssValue:function(){return l.normalizeCssValue},normalizeKeyAliases:function(){return l.normalizeKeyAliases},normalizeLicense:function(){return l.normalizeLicense},normalizePath:function(){return l.normalizePath},normalizeRelativePath:function(){return l.normalizeRelativePath},normalizeSize:function(){return l.normalizeSize},normalizeUrl:function(){return l.normalizeUrl},offset:function(){return u.offset},position:function(){return u.position},safeHTML:function(){return a.safeHTML},sanitizeHTMLElement:function(){return a.sanitizeHTMLElement},setTimeout:function(){return o.setTimeout},size:function(){return u.size},splitArray:function(){return n.splitArray},sprintf:function(){return c.sprintf},stringify:function(){return c.stringify},stripTags:function(){return a.stripTags},toArray:function(){return n.toArray},trim:function(){return c.trim},trimChars:function(){return c.trimChars},trimInv:function(){return c.trimInv},ucfirst:function(){return c.ucfirst}});var n=i(45664),o=i(61077),r=i(28686),s=i(7018),a=i(82658),l=i(97022),u=i(86878),c=i(97642),d=i(93640),h={};for(var p in d)0>["default","asArray","splitArray","toArray","clearTimeout","setTimeout","hasBrowserColorPicker","hasContainer","isAbortError","isArray","isBoolean","isDestructable","isEqual","isFastEqual","isFunction","isHTML","isHtmlFromWord","isInitable","isInt","isJoditObject","isLicense","isMarker","isNativeFunction","isNumber","isNumeric","isPlainObject","isPromise","isSet","isString","isStringArray","isURL","isValidName","isViewObject","isVoid","isWindow","colorToHex","applyStyles","cleanFromWord","htmlspecialchars","nl2br","safeHTML","sanitizeHTMLElement","stripTags","NUMBER_FIELDS_REG","normalizeColor","normalizeCssNumericValue","normalizeCssValue","normalizeKeyAliases","normalizeLicense","normalizePath","normalizeRelativePath","normalizeSize","normalizeUrl","getContentWidth","getScrollParent","innerWidth","offset","position","size","CamelCaseToKebabCase","camelCase","fuzzySearchIndex","i18n","kebabCase","sprintf","stringify","trim","trimChars","trimInv","ucfirst"].indexOf(p)&&(h[p]=(function(e){return d[e]}).bind(0,p));i.d(t,h)},97022:function(e,t,i){"use strict";i.d(t,{NUMBER_FIELDS_REG:function(){return o.NUMBER_FIELDS_REG},normalizeColor:function(){return n.normalizeColor},normalizeCssNumericValue:function(){return o.normalizeCssNumericValue},normalizeCssValue:function(){return o.normalizeCssValue},normalizeKeyAliases:function(){return r.normalizeKeyAliases},normalizeLicense:function(){return s.normalizeLicense},normalizePath:function(){return a.normalizePath},normalizeRelativePath:function(){return l.normalizeRelativePath},normalizeSize:function(){return u.normalizeSize},normalizeUrl:function(){return c.normalizeUrl}});var n=i(77367),o=i(19147),r=i(27978),s=i(49663),a=i(18377),l=i(96340),u=i(98831),c=i(48009)},77367:function(e,t,i){"use strict";i.d(t,{normalizeColor:function(){return r}});var n=i(93387),o=i(4040);let r=e=>{let t=["#"],i=(0,n.colorToHex)(e);if(!i)return!1;if(3===(i=(i=(0,o.trim)(i.toUpperCase())).substring(1)).length){for(let e=0;e<3;e+=1)t.push(i[e]),t.push(i[e]);return t.join("")}return i.length>6&&(i=i.slice(0,6)),"#"+i}},19147:function(e,t,i){"use strict";i.d(t,{NUMBER_FIELDS_REG:function(){return a},normalizeCssNumericValue:function(){return l},normalizeCssValue:function(){return u}});var n=i(70222),o=i(18303),r=i(93387),s=i(74264);let a=/^(left|top|bottom|right|width|min|max|height|margin|padding|fontsize|font-size)/i;function l(e,t){return!(0,o.isVoid)(t)&&a.test(e)&&(0,n.isNumeric)(t.toString())?parseInt(t.toString(),10)+"px":t}function u(e,t){if("font-weight"===(0,s.kebabCase)(e)){switch(t.toString().toLowerCase()){case"700":case"bold":return 700;case"400":case"normal":return 400;case"900":case"heavy":return 900}return(0,n.isNumeric)(t)?Number(t):t}return/color/i.test(e)&&/^rgb/i.test(t.toString())&&(0,r.colorToHex)(t.toString())||t}},27978:function(e,t,i){"use strict";i.d(t,{normalizeKeyAliases:function(){return r}});var n=i(81937),o=i(4040);function r(e){let t={},i={meta:1,ctrl:2,control:2,alt:3,shift:4,space:5};return e.replace(/\+\+/g,"+add").split(/[\s]*\+[\s]*/).map(e=>(0,o.trim)(e.toLowerCase())).map(e=>n.KEY_ALIASES[e]||e).sort((e,t)=>i[e]&&!i[t]?-1:!i[e]&&i[t]?1:i[e]&&i[t]?i[e]-i[t]:e>t?1:-1).filter(e=>!t[e]&&""!==e&&(t[e]=!0)).join("+")}},49663:function(e,t,i){"use strict";i.d(t,{normalizeLicense:function(){return n}});let n=(e,t=8)=>{let i=[];for(;e.length;)i.push(e.substr(0,t)),e=e.substr(t);return i[1]=i[1].replace(/./g,"*"),i[2]=i[2].replace(/./g,"*"),i.join("-")}},18377:function(e,t,i){"use strict";i.d(t,{normalizePath:function(){return o}});var n=i(4040);let o=(...e)=>e.filter(e=>(0,n.trim)(e).length).map((t,i)=>(t=t.replace(/([^:])[\\/]+/g,"$1/"),i&&(t=t.replace(/^\//,"")),i!==e.length-1&&(t=t.replace(/\/$/,"")),t)).join("/")},96340:function(e,t,i){"use strict";i.d(t,{normalizeRelativePath:function(){return n}});let n=e=>e.split("/").reduce((e,t)=>{switch(t){case"":case".":break;case"..":e.pop();break;default:e.push(t)}return e},[]).join("/")+(e.endsWith("/")?"/":"")},98831:function(e,t,i){"use strict";i.d(t,{normalizeSize:function(){return n}});let n=(e,t)=>/^[0-9]+$/.test(e.toString())?e+t:e.toString()},48009:function(e,t,i){"use strict";i.d(t,{normalizeUrl:function(){return n}});let n=(...e)=>e.filter(e=>e.length).map(e=>e.replace(/\/$/,"")).join("/").replace(/([^:])[\\/]+/g,"$1/")},54447:function(e,t,i){"use strict";i.d(t,{getContentWidth:function(){return n}});let n=(e,t)=>{let i=t.getComputedStyle(e);return e.offsetWidth-parseInt(i.getPropertyValue("padding-left")||"0",10)-parseInt(i.getPropertyValue("padding-right")||"0",10)}},34027:function(e,t,i){"use strict";i.d(t,{getScrollParent:function(){return function e(t){if(!t)return null;let i=o.Dom.isHTMLElement(t),s=i&&(0,r.css)(t,"overflowY");return i&&"visible"!==s&&"hidden"!==s&&t.scrollHeight>=t.clientHeight?t:e(t.parentNode)||n.globalDocument.scrollingElement||n.globalDocument.body}}});var n=i(81937),o=i(23211),r=i(93640)},86878:function(e,t,i){"use strict";i.d(t,{getContentWidth:function(){return n.getContentWidth},getScrollParent:function(){return o.getScrollParent},innerWidth:function(){return r.innerWidth},offset:function(){return a.offset},position:function(){return l.position},size:function(){return s.size}});var n=i(54447),o=i(34027),r=i(83215),s=i(18073),a=i(69143),l=i(23599)},83215:function(e,t,i){"use strict";i.d(t,{innerWidth:function(){return n}});let n=(e,t)=>{let i=t.getComputedStyle(e);return e.clientWidth-(parseFloat(i.paddingLeft||"0")+parseFloat(i.paddingRight||"0"))}},18073:function(e,t,i){"use strict";i.d(t,{size:function(){return o}});var n=i(28686);function o(e){return(0,n.isString)(e)||(0,n.isArray)(e)?e.length:(0,n.isPlainObject)(e)?Object.keys(e).length:0}},69143:function(e,t,i){"use strict";i.d(t,{offset:function(){return n}});let n=(e,t,i,o=!1)=>{let r,s,a;try{r=e.getBoundingClientRect()}catch(e){r={top:0,bottom:0,left:0,right:0,width:0,height:0}}let l=i.body,u=i.documentElement||{clientTop:0,clientLeft:0,scrollTop:0,scrollLeft:0},c=i.defaultView||i.parentWindow,d=c.pageYOffset||u.scrollTop||l.scrollTop,h=c.pageXOffset||u.scrollLeft||l.scrollLeft,p=u.clientTop||l.clientTop||0,f=u.clientLeft||l.clientLeft||0,m=t.iframe;if(!o&&t&&t.options&&t.o.iframe&&m){let{top:e,left:i}=n(m,t,t.od,!0);s=r.top+e,a=r.left+i}else s=r.top+d-p,a=r.left+h-f;return{top:Math.round(s),left:Math.round(a),width:r.width,height:r.height}}},23599:function(e,t,i){"use strict";i.d(t,{position:function(){return function e(t,i,o=!1){var r,s;let a=t.getBoundingClientRect(),l=a.left,u=a.top;if((0,n.isJoditObject)(i)&&i.iframe&&i.ed.body.contains(t)&&!o){let{left:t,top:n}=e(i.iframe,i,!0);l+=t,u+=n}return{left:Math.round(l),top:Math.round(u),width:Math.round(null!=(r=t.offsetWidth)?r:a.width),height:Math.round(null!=(s=t.offsetHeight)?s:a.height)}}}});var n=i(24497)},57821:function(e,t,i){"use strict";i.d(t,{camelCase:function(){return n}});let n=e=>e.replace(/([-_])(.)/g,(e,t,i)=>i.toUpperCase())},57626:function(e,t,i){"use strict";i.d(t,{fuzzySearchIndex:function(){return o}});var n=i(81937);function o(e,t,i=0,r=1){let s=0,a=0,l=-1,u=0,c=0;for(a=i;s<e.length&&a<t.length;)e[s].toLowerCase()===t[a].toLowerCase()?(s++,u++,c=0,-1===l&&(l=a)):s>0&&(c>=r&&t[a]!==n.INVISIBLE_SPACE?(s=0,l=-1,u=0,c=0,a--):(c++,u++)),a++;return s===e.length?[l,u]:[-1,0]}},18080:function(e,t,i){"use strict";i.d(t,{i18n:function(){return u},sprintf:function(){return l}});var n=i(81937),o=i(85932),r=i(99436),s=i(93640),a=i(5266);let l=(e,t)=>{if(!t||!t.length)return e;let i=/%([sd])/g,n=i.exec(e),o=e,r=0;for(;n&&void 0!==t[r];)o=o.replace(n[0],t[r].toString()),r+=1,n=i.exec(e);return o};function u(e,t,i){if(!(0,o.isString)(e))throw(0,s.error)("i18n: Need string in first argument");if(!e.length)return e;let u=!!(null==i?void 0:i.debugLanguage),c={},d=e=>t&&t.length?l(e,t):e,h=(0,s.defaultLanguage)(a.Config.defaultOptions.language,a.Config.defaultOptions.language),p=(0,s.defaultLanguage)(null==i?void 0:i.language,h),f=t=>{if(!t)return;if((0,o.isString)(t[e]))return d(t[e]);let i=e.toLowerCase();if((0,o.isString)(t[i]))return d(t[i]);let n=(0,r.ucfirst)(e);if((0,o.isString)(t[n]))return d(t[n])};void 0!==n.lang[p]?c=n.lang[p]:u||(c=void 0!==n.lang[h]?n.lang[h]:n.lang.en);let m=null==i?void 0:i.i18n;if(m&&m[p]){let e=f(m[p]);if(e)return e}return f(c)||(!u&&n.lang.en&&(0,o.isString)(n.lang.en[e])&&n.lang.en[e]?d(n.lang.en[e]):u?"{"+e+"}":(n.IS_PROD,d(e)))}},97642:function(e,t,i){"use strict";i.d(t,{CamelCaseToKebabCase:function(){return s.CamelCaseToKebabCase},camelCase:function(){return n.camelCase},fuzzySearchIndex:function(){return o.fuzzySearchIndex},i18n:function(){return r.i18n},kebabCase:function(){return s.kebabCase},sprintf:function(){return r.sprintf},stringify:function(){return a.stringify},trim:function(){return l.trim},trimChars:function(){return l.trimChars},trimInv:function(){return l.trimInv},ucfirst:function(){return u.ucfirst}});var n=i(57821),o=i(57626),r=i(18080),s=i(74264),a=i(3347),l=i(4040),u=i(99436)},74264:function(e,t,i){"use strict";i.d(t,{CamelCaseToKebabCase:function(){return o},kebabCase:function(){return n}});let n=e=>e.replace(/([A-Z])([A-Z])([a-z])/g,"$1-$2$3").replace(/([a-z])([A-Z])/g,"$1-$2").replace(/[\s_]+/g,"-").toLowerCase(),o=e=>e.replace(/([A-Z])([A-Z])([a-z])/g,"$1-$2$3").replace(/([a-z])([A-Z])/g,"$1-$2").toLowerCase()},3347:function(e,t,i){"use strict";function n(e,t={}){if("object"!=typeof e)return String(e);let i=new Set(t.excludeKeys),o=new WeakMap;return JSON.stringify(e,(e,t)=>{if(!i.has(e)){if("object"==typeof t&&null!=t){if(o.get(t))return"[refObject]";o.set(t,!0)}return t}},t.prettify)}i.d(t,{stringify:function(){return n}})},4040:function(e,t,i){"use strict";i.d(t,{trim:function(){return o},trimChars:function(){return r},trimInv:function(){return s}});var n=i(81937);function o(e){return e.replace((0,n.SPACE_REG_EXP_END)(),"").replace((0,n.SPACE_REG_EXP_START)(),"")}function r(e,t){return e.replace(RegExp(`[${t}]+$`),"").replace(RegExp(`^[${t}]+`),"")}function s(e){return e.replace((0,n.INVISIBLE_SPACE_REG_EXP_END)(),"").replace((0,n.INVISIBLE_SPACE_REG_EXP_START)(),"")}},99436:function(e,t,i){"use strict";function n(e){return e.length?e[0].toUpperCase()+e.substring(1):""}i.d(t,{ucfirst:function(){return n}})},16849:function(e,t,i){"use strict";i.d(t,{alignElement:function(){return a},clearAlign:function(){return s},hAlignElement:function(){return r}});var n=i(27795),o=i(80991);function r(e,t){t&&"normal"!==t?"center"!==t?((0,o.css)(e,"float",t),(0,o.clearCenterAlign)(e)):(0,o.css)(e,{float:"",display:"block",marginLeft:"auto",marginRight:"auto"}):((0,o.css)(e,"float")&&-1!==["right","left"].indexOf((0,o.css)(e,"float").toString().toLowerCase())&&(0,o.css)(e,"float",""),(0,o.clearCenterAlign)(e))}function s(e){n.Dom.each(e,e=>{n.Dom.isHTMLElement(e)&&e.style.textAlign&&(e.style.textAlign="",e.style.cssText.trim().length||e.removeAttribute("style"))})}function a(e,t){if(n.Dom.isNode(t)&&n.Dom.isElement(t))switch(s(t),e.toLowerCase()){case"justifyfull":t.style.textAlign="justify";break;case"justifyright":t.style.textAlign="right";break;case"justifyleft":t.style.textAlign="left";break;case"justifycenter":t.style.textAlign="center"}}},47760:function(e,t,i){"use strict";i.d(t,{alreadyLoadedList:function(){return r},appendScriptAsync:function(){return a},appendStyleAsync:function(){return l},loadNext:function(){return function e(t,i,o=0){return(0,n.isString)(i[o])?a(t,i[o]).then(()=>e(t,i,o+1)):Promise.resolve()}},loadNextStyle:function(){return function e(t,i,o=0){return(0,n.isString)(i[o])?l(t,i[o]).then(()=>e(t,i,o+1)):Promise.resolve()}}});var n=i(85932),o=i(91321);let r=new Map,s=e=>(t,i)=>{if(r.has(i))return r.get(i);let n=e(t,i);return r.set(i,n),n},a=s((e,t)=>e.async.promise((i,n)=>{if(e.isInDestruct)return n();let r=e.c.element("script",{type:"text/javascript",crossorigin:"anonymous",referrerpolicy:"no-referrer",async:!0,src:(0,o.completeUrl)(t)});e.e.one(r,"error",n).one(r,"load",i),e.od.body.appendChild(r)})),l=s((e,t)=>e.async.promise((i,n)=>{if(e.isInDestruct)return n();let r=e.c.element("link");r.rel="stylesheet",r.media="all",r.crossOrigin="anonymous",e.isInDestruct||e.e.on(r,"load",()=>i(r)).on(r,"error",n),r.href=(0,o.completeUrl)(t),e.o.shadowRoot?e.o.shadowRoot.appendChild(r):e.od.body.appendChild(r)}))},7909:function(e,t,i){"use strict";i.d(t,{attr:function(){return function e(t,i,l){if(!t||!(0,n.isFunction)(t.getAttribute))return null;if(!(0,r.isString)(i))return Object.keys(i).forEach(n=>{let r=i[n];(0,o.isPlainObject)(r)&&"style"===n?(0,a.css)(t,r):("className"===n&&(n="class"),e(t,n,r))}),null;let u=(0,s.CamelCaseToKebabCase)(i);if(/^-/.test(u)){let i=e(t,`data${u}`);if(i)return i;u=u.substr(1)}if(void 0!==l)if(null==l)t.hasAttribute(u)&&t.removeAttribute(u);else{let e=l.toString();return"IMG"===t.nodeName&&("width"===u||"height"===u)&&(e=e.replace("px","")),t.setAttribute(u,e),e}return t.getAttribute(u)}}});var n=i(91565),o=i(62101),r=i(85932),s=i(74264),a=i(80991)},26136:function(e,t,i){"use strict";i.d(t,{browser:function(){return n}});let n=e=>{let t=navigator.userAgent.toLowerCase(),i=/(firefox)[\s/]([\w.]+)/.exec(t)||/(chrome)[\s/]([\w.]+)/.exec(t)||/(webkit)[\s/]([\w.]+)/.exec(t)||/(opera)(?:.*version)[\s/]([\w.]+)/.exec(t)||/(msie)[\s]([\w.]+)/.exec(t)||/(trident)\/([\w.]+)/.exec(t)||0>t.indexOf("compatible")||[];return"version"===e?i[2]:"webkit"===e?"chrome"===i[1]||"webkit"===i[1]:"ff"===e?"firefox"===i[1]:"msie"===e?"trident"===i[1]||"msie"===i[1]:i[1]===e}},36833:function(e,t,i){"use strict";i.d(t,{buildQuery:function(){return o}});var n=i(62101);let o=(e,t)=>{let i=[],r=encodeURIComponent;for(let s in e)if(Object.prototype.hasOwnProperty.call(e,s)){let a=t?t+"["+s+"]":s,l=e[s];i.push((0,n.isPlainObject)(l)?o(l,a):r(a)+"="+r(l))}return i.join("&")}},91321:function(e,t,i){"use strict";i.d(t,{completeUrl:function(){return o}});var n=i(81937);let o=e=>("file:"===n.globalWindow.location.protocol&&/^\/\//.test(e)&&(e="https:"+e),e)},77483:function(e,t,i){"use strict";i.d(t,{ConfigDeepFlatten:function(){return function e(t){return(0,u.keys)(t,!1).reduce((i,n)=>(i[n]=(0,o.isPlainObject)(t[n])?e(t[n]):t[n],i),{})}},ConfigFlatten:function(){return c},ConfigProto:function(){return function e(t,i,u=0){if(Object.getPrototypeOf(t)!==Object.prototype)return t;let c=a.Config.defaultOptions;if((0,r.isString)(t.preset)){if(void 0!==c.presets[t.preset]){let e=c.presets[t.preset];Object.keys(e).forEach(i=>{(0,s.isVoid)(t[i])&&(t[i]=e[i])})}delete t.preset}let d={};return Object.keys(t).forEach(r=>{let s=t[r],a=i?i[r]:null;if((0,o.isPlainObject)(s)&&(0,o.isPlainObject)(a)&&!(0,l.isAtom)(s)){d[r]=e(s,a,u+1);return}if(0!==u&&(0,n.isArray)(s)&&!(0,l.isAtom)(s)&&(0,n.isArray)(a)){d[r]=[...s,...a.slice(s.length)];return}d[r]=s}),Object.setPrototypeOf(d,i),d}}});var n=i(17312),o=i(62101),r=i(85932),s=i(18303),a=i(5266),l=i(54794),u=i(71125);function c(e){return(0,u.keys)(e,!1).reduce((t,i)=>(t[i]=e[i],t),{})}},3856:function(e,t,i){"use strict";i.d(t,{convertMediaUrlToVideoEmbed:function(){return s}});var n=i(81937),o=i(91764),r=i(36310);let s=(e,{width:t=400,height:i=345}={})=>{if(!(0,o.isURL)(e))return e;let s=n.globalDocument.createElement("a"),a=/(?:http?s?:\/\/)?(?:www\.)?(?:vimeo\.com)\/?(.+)/g;s.href=e,t||(t=400),i||(i=345);let l=s.protocol||"";switch(s.hostname){case"www.vimeo.com":case"vimeo.com":return a.test(e)?e.replace(a,'<iframe width="'+t+'" height="'+i+'" src="'+l+'//player.vimeo.com/video/$1" frameborder="0" allowfullscreen></iframe>'):e;case"youtube.com":case"www.youtube.com":case"youtu.be":case"www.youtu.be":{let n=s.search?(0,r.parseQuery)(s.search):{v:s.pathname.substring(1)};return/^embed\/.*/.test(n.v)&&(n.v=n.v.substring(6)),n.v?'<iframe width="'+t+'" height="'+i+'" src="'+l+"//www.youtube.com/embed/"+n.v+'" frameborder="0" allowfullscreen></iframe>':e}}return e}},80991:function(e,t,i){"use strict";i.d(t,{clearCenterAlign:function(){return u},css:function(){return l}});var n=i(22289),o=i(62101),r=i(19147),s=i(57821),a=i(74264);function l(e,t,i,u=!1){if((0,n.isBoolean)(i)&&(u=i,i=void 0),(0,o.isPlainObject)(t)||void 0!==i){let n=(e,t,i)=>{void 0!==(i=(0,r.normalizeCssNumericValue)(t,i))&&(null==i||l(e,t,!0)!==(0,r.normalizeCssValue)(t,i))&&(e.style[t]=i)};if((0,o.isPlainObject)(t)){let i=Object.keys(t);for(let o=0;o<i.length;o+=1)n(e,(0,s.camelCase)(i[o]),t[i[o]])}else n(e,(0,s.camelCase)(t),i);return""}let c=(0,a.kebabCase)(t),d=e.ownerDocument||document,h=!!d&&(d.defaultView||d.parentWindow),p=e.style[t],f="";return void 0!==p&&""!==p?f=p:h&&!u&&(f=h.getComputedStyle(e).getPropertyValue(c)),r.NUMBER_FIELDS_REG.test(t)&&/^[-+]?[0-9.]+px$/.test(f.toString())&&(f=parseInt(f.toString(),10)),(0,r.normalizeCssValue)(t,f)}let u=e=>{"block"===l(e,"display")&&l(e,"display","");let{style:t}=e;"auto"===t.marginLeft&&"auto"===t.marginRight&&(t.marginLeft="",t.marginRight="")}},77213:function(e,t,i){"use strict";i.d(t,{ctrlKey:function(){return n}});let n=e=>{if("u">typeof navigator&&-1!==navigator.userAgent.indexOf("Mac OS X")){if(e.metaKey&&!e.altKey)return!0}else if(e.ctrlKey&&!e.altKey)return!0;return!1}},36400:function(e,t,i){"use strict";i.d(t,{dataBind:function(){return r}});var n=i(31534);let o=new WeakMap,r=(e,t,i)=>{let r=o.get(e);if(!r){r={},o.set(e,r);let t=null;(0,n.isViewObject)(e.j)&&(t=e.j.e),(0,n.isViewObject)(e)&&(t=e.e),t&&t.on("beforeDestruct",()=>{o.delete(e)})}return void 0===i?r[t]:(r[t]=i,i)}},97228:function(e,t,i){"use strict";i.d(t,{defaultLanguage:function(){return r}});var n=i(81937),o=i(85932);let r=(e,t="en")=>"auto"!==e&&(0,o.isString)(e)?e:n.globalDocument.documentElement&&n.globalDocument.documentElement.lang?n.globalDocument.documentElement.lang:navigator.language?navigator.language.substring(0,2):t},38027:function(e,t,i){"use strict";i.d(t,{connection:function(){return r},error:function(){return o},options:function(){return s}});var n=i(29953);function o(e){return TypeError(e)}function r(e){return new n.ConnectionError(e)}function s(e){return new n.OptionsError(e)}},14228:function(e,t,i){"use strict";function n(e="Aborted"){return new DOMException(e,"AbortError")}i.d(t,{abort:function(){return n}})},58250:function(e,t,i){"use strict";i.d(t,{ConnectionError:function(){return n}});class n extends Error{constructor(e){super(e),Object.setPrototypeOf(this,n.prototype)}}},29953:function(e,t,i){"use strict";i.d(t,{ConnectionError:function(){return o.ConnectionError},OptionsError:function(){return r.OptionsError},abort:function(){return n.abort}});var n=i(14228),o=i(58250),r=i(11080)},11080:function(e,t,i){"use strict";i.d(t,{OptionsError:function(){return n}});class n extends TypeError{constructor(e){super(e),Object.setPrototypeOf(this,n.prototype)}}},33201:function(e,t,i){"use strict";i.d(t,{ConnectionError:function(){return o.ConnectionError},OptionsError:function(){return o.OptionsError},abort:function(){return o.abort},connection:function(){return n.connection},error:function(){return n.error},options:function(){return n.options}});var n=i(38027),o=i(29953)},54794:function(e,t,i){"use strict";i.d(t,{fastClone:function(){return s},isAtom:function(){return o},markAsAtomic:function(){return r}});var n=i(3347);function o(e){return e&&e.isAtom}function r(e){return Object.defineProperty(e,"isAtom",{enumerable:!1,value:!0,configurable:!1}),e}function s(e){return JSON.parse((0,n.stringify)(e))}},421:function(e,t,i){"use strict";i.d(t,{getClassName:function(){return r},keepNames:function(){return o}});var n=i(91565);let o=new Map,r=e=>{var t;if((0,n.isFunction)(e.className))return e.className();let i=(null==(t=e.constructor)?void 0:t.originalConstructor)||e.constructor;if(o.has(i))return o.get(i);if(i.name)return i.name;let r=new RegExp(/^\s*function\s*(\S*)\s*\(/),s=i.toString().match(r);return s?s[1]:""}},89308:function(e,t,i){"use strict";i.d(t,{get:function(){return r}});var n=i(85932),o=i(18303);function r(e,t){if(!(0,n.isString)(e)||!e.length)return null;let i=e.split("."),r=t;try{for(let e of i){if((0,o.isVoid)(r[e]))return null;r=r[e]}}catch(e){return null}return(0,o.isVoid)(r)?null:r}},37427:function(e,t,i){"use strict";i.d(t,{humanSizeToBytes:function(){return n}});let n=e=>{if(/^[0-9.]+$/.test(e.toString()))return parseFloat(e);let t=e.substr(-2,2).toUpperCase(),i=["KB","MB","GB","TB"],n=parseFloat(e.substr(0,e.length-2));return -1!==i.indexOf(t)?n*Math.pow(1024,i.indexOf(t)+1):parseInt(e,10)}},93640:function(e,t,i){"use strict";i.r(t),i.d(t,{$$:function(){return x.$$},ConfigDeepFlatten:function(){return h.ConfigDeepFlatten},ConfigFlatten:function(){return h.ConfigFlatten},ConfigProto:function(){return h.ConfigProto},ConnectionError:function(){return _.ConnectionError},LimitedStack:function(){return j.LimitedStack},OptionsError:function(){return _.OptionsError},abort:function(){return _.abort},alignElement:function(){return n.alignElement},alreadyLoadedList:function(){return o.alreadyLoadedList},appendScriptAsync:function(){return o.appendScriptAsync},appendStyleAsync:function(){return o.appendStyleAsync},attr:function(){return l.attr},browser:function(){return u.browser},buildQuery:function(){return c.buildQuery},call:function(){return z.call},callPromise:function(){return z.callPromise},callThis:function(){return z.callThis},clearAlign:function(){return n.clearAlign},clearCenterAlign:function(){return f.clearCenterAlign},cns:function(){return C.cns},completeUrl:function(){return d.completeUrl},connection:function(){return _.connection},convertMediaUrlToVideoEmbed:function(){return p.convertMediaUrlToVideoEmbed},css:function(){return f.css},cssPath:function(){return x.cssPath},ctrlKey:function(){return m.ctrlKey},dataBind:function(){return g.dataBind},defaultLanguage:function(){return v.defaultLanguage},error:function(){return _.error},fastClone:function(){return b.fastClone},get:function(){return y.get},getClassName:function(){return S.getClassName},getDataTransfer:function(){return z.getDataTransfer},getPropertyDescriptor:function(){return z.getPropertyDescriptor},getXPathByElement:function(){return x.getXPathByElement},hAlignElement:function(){return n.hAlignElement},humanSizeToBytes:function(){return w.humanSizeToBytes},inView:function(){return T.inView},isAtom:function(){return b.isAtom},keepNames:function(){return S.keepNames},keys:function(){return z.keys},loadImage:function(){return z.loadImage},loadNext:function(){return o.loadNext},loadNextStyle:function(){return o.loadNextStyle},markAsAtomic:function(){return b.markAsAtomic},markDeprecated:function(){return C.markDeprecated},markOwner:function(){return z.markOwner},memorizeExec:function(){return z.memorizeExec},options:function(){return _.options},parseQuery:function(){return k.parseQuery},previewBox:function(){return E.previewBox},refs:function(){return x.refs},reset:function(){return I.reset},resolveElement:function(){return x.resolveElement},scrollIntoViewIfNeeded:function(){return T.scrollIntoViewIfNeeded},set:function(){return D.set}});var n=i(16849),o=i(47760),r=i(28712),s={};for(var a in r)0>["default","alignElement","clearAlign","hAlignElement","alreadyLoadedList","appendScriptAsync","appendStyleAsync","loadNext","loadNextStyle"].indexOf(a)&&(s[a]=(function(e){return r[e]}).bind(0,a));i.d(t,s);var l=i(7909),u=i(26136),c=i(36833),d=i(91321),h=i(77483),p=i(3856),f=i(80991),m=i(77213),g=i(36400),v=i(97228),_=i(33201),b=i(54794),y=i(89308),S=i(421),w=i(37427),C=i(49385),k=i(36310),E=i(57075),I=i(43379),T=i(60898),x=i(28723),D=i(52144),j=i(42820),z=i(71125)},49385:function(e,t,i){"use strict";i.d(t,{cns:function(){return n},markDeprecated:function(){return o}});let n=console;function o(e,t=[""],i=null){return(...o)=>(n.warn(`Method "${t[0]}" deprecated.`+(t[1]?` Use "${t[1]}" instead`:"")),e.call(i,...o))}},36310:function(e,t,i){"use strict";i.d(t,{parseQuery:function(){return n}});let n=e=>{let t={},i=e.substring(1).split("&");for(let e=0;e<i.length;e+=1){let n=i[e].split("=");t[decodeURIComponent(n[0])]=decodeURIComponent(n[1]||"")}return t}},57075:function(e,t,i){"use strict";i.d(t,{previewBox:function(){return l}});var n=i(23211),o=i(85932),r=i(7909),s=i(80991),a=i(28723);function l(e,t,i="px",u=null){let c=[],d=function(e,t){let i=[];try{(0,a.$$)("img",e.editor).forEach(o=>{let s=[(0,r.attr)(o,"width"),(0,r.attr)(o,"height"),o.src];(0,r.attr)(o,{width:o.offsetWidth+t,height:o.offsetHeight+t});let a=e.createInside.a();e.ed.body.appendChild(a),a.href=o.src,o.src=a.href,n.Dom.safeRemove(a),i.push(()=>{var e;o.src=null!=(e=s[2])?e:"",(0,r.attr)(o,{width:s[0]||null,height:s[1]||null})})})}catch(e){throw i.forEach(e=>e()),i.length=0,e}return i}(e,i);try{let a=e.e.fire("beforePreviewBox",t,i);if(null!=a)return a;let l=e.c.div("jodit__preview-box jodit-context");u&&u.appendChild(l),(0,s.css)(l,{position:"relative",padding:16});let d=e.value||`<div style='position: absolute;left:50%;top:50%;transform: translateX(-50%) translateY(-50%);color:#ccc;'>${e.i18n("Empty")}</div>`;if(e.iframe){let t=e.create.element("iframe");(0,s.css)(t,{minWidth:800,minHeight:600,border:0}),l.appendChild(t);let i=t.contentWindow;if(i&&(e.e.fire("generateDocumentStructure.iframe",i.document,e),l=i.document.body,"function"==typeof ResizeObserver)){let n=!1,o=i.document.body,r=new ResizeObserver(e.async.debounce(()=>{r.unobserve(o),t.style.height=`${o.offsetHeight+20}px`,e.async.requestAnimationFrame(()=>{n||r.observe(o)})},100)),s=()=>{n=!0,r.unobserve(o),r.disconnect(),e.e.off("beforeDestruct",s)};c.push(s),e.e.on("beforeDestruct",s)}}else(0,s.css)(l,{minWidth:1024,minHeight:600,border:0});let h=(t,i)=>{let s=(0,o.isString)(i)?e.c.div():i;(0,o.isString)(i)&&(s.innerHTML=i);for(let e=0;e<s.childNodes.length;e+=1){let i=s.childNodes[e];if(n.Dom.isElement(i)){let e=t.ownerDocument.createElement(i.nodeName);for(let t=0;t<i.attributes.length;t+=1)(0,r.attr)(e,i.attributes[t].nodeName,i.attributes[t].nodeValue);0===i.childNodes.length||n.Dom.isTag(i,"table")?"SCRIPT"===i.nodeName?i.textContent&&(e.textContent=i.textContent):i.innerHTML&&(e.innerHTML=i.innerHTML):h(e,i);try{t.appendChild(e)}catch(e){}}else try{t.appendChild(i.cloneNode(!0))}catch(e){}}};return h(l,d),e.e.fire("afterPreviewBox",l),[l,()=>{c.forEach(e=>e())}]}finally{d.forEach(e=>e())}}},43379:function(e,t,i){"use strict";i.d(t,{reset:function(){return a}});var n=i(81937),o=i(91565),r=i(89308);let s={};function a(e){var t,i;if(!(e in s)){let t=n.globalDocument.createElement("iframe");try{if(t.src="about:blank",n.globalDocument.body.appendChild(t),!t.contentWindow)return null;let i=(0,r.get)(e,t.contentWindow),a=(0,r.get)(e.split(".").slice(0,-1).join("."),t.contentWindow);(0,o.isFunction)(i)&&(s[e]=i.bind(a))}catch(e){if(!n.IS_PROD)throw e}finally{null==(i=t.parentNode)||i.removeChild(t)}}return null!=(t=s[e])?t:null}},60898:function(e,t,i){"use strict";i.d(t,{inView:function(){return o},scrollIntoViewIfNeeded:function(){return r}});var n=i(23211);function o(e,t,i){let n=e.getBoundingClientRect(),o=e,r=n.top,s=n.height;for(;o&&o!==t&&o.parentNode;)if(!(r<=(n=(o=o.parentNode).getBoundingClientRect()).bottom)||r+s<=n.top)return!1;return r<=(i.documentElement&&i.documentElement.clientHeight||0)}function r(e,t,i){n.Dom.isHTMLElement(e)&&!o(e,t,i)&&(t.clientHeight!==t.scrollHeight&&(t.scrollTop=e.offsetTop),o(e,t,i)||e.scrollIntoView())}},28723:function(e,t,i){"use strict";i.d(t,{$$:function(){return d},cssPath:function(){return f},getXPathByElement:function(){return h},refs:function(){return p},resolveElement:function(){return m}});var n=i(81937),o=i(23211),r=i(88475),s=i(85932),a=i(57821),l=i(7909),u=i(33201);let c=1;function d(e,t){let i;if(!n.IS_ES_NEXT&&/:scope/.test(e)&&n.IS_IE&&!(t&&t.nodeType===Node.DOCUMENT_NODE)){let n=t.id,o=n||"_selector_id_"+String(Math.random()).slice(2)+ ++c;e=e.replace(/:scope/g,"#"+o),n||t.setAttribute("id",o),i=t.parentNode.querySelectorAll(e),n||t.removeAttribute("id")}else i=t.querySelectorAll(e);return[].slice.call(i)}let h=(e,t)=>{if(!e||e.nodeType!==Node.ELEMENT_NODE||!e.parentNode||t===e)return"";if(e.id)return"//*[@id='"+e.id+"']";let i=[].filter.call(e.parentNode.childNodes,t=>t.nodeName===e.nodeName);return h(e.parentNode,t)+"/"+e.nodeName.toLowerCase()+(i.length>1?"["+((0,r.toArray)(i).indexOf(e)+1)+"]":"")},p=e=>("container"in e&&(e=e.container),d("[ref],[data-ref]",e).reduce((e,t)=>{let i=(0,l.attr)(t,"-ref");return i&&(0,s.isString)(i)&&(e[(0,a.camelCase)(i)]=t,e[i]=t),e},{})),f=e=>{if(!o.Dom.isElement(e))return null;let t=[],i=e;for(;i&&i.nodeType===Node.ELEMENT_NODE;){let e=i.nodeName.toLowerCase();if(i.id){e+="#"+i.id,t.unshift(e);break}{let t=i,n=1;do(t=t.previousElementSibling)&&t.nodeName.toLowerCase()===e&&n++;while(t);e+=":nth-of-type("+n+")"}t.unshift(e),i=i.parentNode}return t.join(" > ")};function m(e,t){let i=e;if((0,s.isString)(e))try{i=t.querySelector(e)}catch(t){throw(0,u.error)('String "'+e+'" should be valid HTML selector')}if(!i||"object"!=typeof i||!o.Dom.isElement(i)||!i.cloneNode)throw(0,u.error)('Element "'+e+'" should be string or HTMLElement instance');return i}},52144:function(e,t,i){"use strict";i.d(t,{set:function(){return a}});var n=i(17312),o=i(70222),r=i(62101),s=i(85932);function a(e,t,i){if(!(0,s.isString)(e)||!e.length)return;let a=e.split("."),l=i,u=a[0];for(let e=0;e<a.length-1;e+=1)u=a[e],(0,n.isArray)(l[u])||(0,r.isPlainObject)(l[u])||(l[u]=(0,o.isNumeric)(a[e+1])?[]:{}),l=l[u];l&&(l[a[a.length-1]]=t)}},42820:function(e,t,i){"use strict";i.d(t,{LimitedStack:function(){return o}});var n=i(25045);class o{push(e){return this.stack.push(e),this.stack.length>this.limit&&this.stack.shift(),this}pop(){return this.stack.pop()}find(e){return this.stack.find(e)}constructor(e){(0,n._)(this,"limit",void 0),(0,n._)(this,"stack",void 0),this.limit=e,this.stack=[]}}},71125:function(e,t,i){"use strict";i.d(t,{call:function(){return a},callPromise:function(){return c},callThis:function(){return l},getDataTransfer:function(){return f},getPropertyDescriptor:function(){return m},keys:function(){return h},loadImage:function(){return d},markOwner:function(){return u},memorizeExec:function(){return p}});var n=i(52100),o=i(18303),r=i(7909),s=i(36400);function a(e,...t){return e(...t)}function l(e,t,...i){return e.apply(t,i)}function u(e,t){(0,r.attr)(t,"data-editor_id",e.id),t.component||Object.defineProperty(t,"jodit",{value:e})}function c(e,t){return(0,n.isPromise)(e)?e.then(e=>e,()=>null).finally(t):null==t?void 0:t()}let d=(e,t)=>t.async.promise((i,n)=>{let o=new Image,r=()=>{t.e.off(o),null==n||n()},s=()=>{t.e.off(o),i(o)};t.e.one(o,"load",s).one(o,"error",r).one(o,"abort",r),o.src=e,o.complete&&s()}),h=(e,t=!0)=>{if(t)return Object.keys(e);let i=[];for(let t in e)i.push(t);return i},p=(e,t,{control:i},n)=>{var r;let a=`button${i.command}`,l=null!=(r=i.args&&i.args[0])?r:(0,s.dataBind)(e,a);if((0,o.isVoid)(l))return!1;(0,s.dataBind)(e,a,l),n&&(l=n(l)),e.execCommand(i.command,!1,null!=l?l:void 0)},f=e=>{if(e.clipboardData)return e.clipboardData;try{return e.dataTransfer||new DataTransfer}catch(e){return null}};function m(e,t){let i;do i=Object.getOwnPropertyDescriptor(e,t),e=Object.getPrototypeOf(e);while(!i&&e);return i}},55810:function(e,t,i){"use strict";i.d(t,{init:function(){return s}});var n=i(81937),o=i(52433),r=i(3050);function s(e,t,i,s,a,l,u){if((0,o.isInitable)(s))try{s.init(e)}catch(e){if(!n.IS_PROD)throw e}a.set(t,s),l.delete(t),s.hasStyle&&(0,r.loadStyle)(e,t).catch(e=>{n.IS_PROD}),s.styles&&(u(e,t,"style").innerHTML=s.styles)}},3050:function(e,t,i){"use strict";i.d(t,{loadExtras:function(){return c},loadStyle:function(){return l}});var n=i(81937),o=i(74264),r=i(47760),s=i(86189);let a=new Set;async function l(e,t){let i=u(e,t,!1);if(!a.has(i))return a.add(i),(0,r.appendStyleAsync)(e,i)}function u(e,t,i){t=(0,o.kebabCase)(t);let n=e.minified?".min":"";return e.basePath+"plugins/"+t+"/"+t+n+"."+(i?"js":"css")}function c(e,t,i,o){try{let n=i.filter(t=>!e.has((0,s.normalizeName)(t.name)));n.length&&n.map(e=>{let i=e.url||u(t,e.name,!0);return(0,r.appendScriptAsync)(t,i).then(o).catch(()=>null)})}catch(e){if(!n.IS_PROD)throw e}}},25974:function(e,t,i){"use strict";i.d(t,{makeInstance:function(){return r}});var n=i(81937),o=i(91565);function r(e,t){try{try{return(0,o.isFunction)(t)?new t(e):t}catch(i){if((0,o.isFunction)(t)&&!t.prototype)return t(e)}}catch(e){if(!n.IS_PROD)throw e}return null}},86189:function(e,t,i){"use strict";i.d(t,{normalizeName:function(){return o}});var n=i(74264);function o(e){return(0,n.kebabCase)(e).toLowerCase()}},91206:function(e,t,i){"use strict";i.d(t,{Plugin:function(){return n.Plugin}});var n=i(18855);i(85305)},85305:function(e,t,i){"use strict";i.d(t,{PluginSystem:function(){return f}});var n=i(25045),o=i(81937),r=i(42689),s=i(32328),a=i(17312),l=i(52433),u=i(85932),c=i(55810),d=i(3050),h=i(25974),p=i(86189);class f{get size(){return this.__items.size}add(e,t){this.__items.set((0,p.normalizeName)(e),t),r.eventEmitter.fire(`plugin:${e}:ready`)}get(e){return this.__items.get((0,p.normalizeName)(e))}remove(e){this.__items.delete((0,p.normalizeName)(e))}__getFullPluginsList(e){let t=[];return this.__items.forEach((i,n)=>{(!e||e.has(n))&&t.push([n,i])}),t}__init(e){let{extraList:t,disableList:i,filter:n}={extraList:e.o.extraPlugins.map(e=>(0,u.isString)(e)?{name:e}:e),disableList:new Set((0,s.splitArray)(e.o.disablePlugins).map(p.normalizeName)),filter:e.o.safeMode?new Set(e.o.safePluginsList):null},r=new Map,f={},m=new Set;e.__plugins=f;let g=()=>{if(e.isInDestruct)return;let t=!1;this.__getFullPluginsList(n).forEach(([n,o])=>{if(i.has(n)||r.has(n))return;let s=null==o?void 0:o.requires;if(s&&(0,a.isArray)(s)&&s.length){if(s.some(e=>i.has(e)))return;if(!s.every(e=>r.has(e)))return void m.add(n)}t=!0;let l=(0,h.makeInstance)(e,o);if(!l){r.set(n,null),m.delete(n);return}(0,c.init)(e,n,o,l,r,m,this.opts.getContainer),f[n]=l}),t&&(e.e.fire("updatePlugins"),g())};t&&t.length&&(0,d.loadExtras)(this.__items,e,t,g),g(),e.e.on("beforeDestruct",()=>{Object.keys(f).forEach(t=>{let i=f[t];(0,l.isDestructable)(i)&&i.destruct(e),delete f[t]}),delete e.__plugins}),o.IS_PROD||m.size}wait(e){return new Promise(t=>{if(this.get(e))return t();let i=()=>{t(),r.eventEmitter.off(`plugin:${e}:ready`,i)};r.eventEmitter.on(`plugin:${e}:ready`,i)})}constructor(e){(0,n._)(this,"opts",void 0),(0,n._)(this,"__items",void 0),this.opts=e,this.__items=new Map}}},18855:function(e,t,i){"use strict";i.d(t,{Plugin:function(){return l}});var n=i(25045),o=i(31635),r=i(16964),s=i(84839),a=i(24497);class l extends r.ViewComponent{className(){return"Plugin"}__afterPluginSystemInit(){let{j:e,buttons:t}=this;t&&(0,a.isJoditObject)(e)&&t.forEach(t=>{e.registerButton(t)})}__afterInit(){this.__inited=!0,this.setStatus(r.STATUSES.ready),this.afterInit(this.jodit)}init(e){this.jodit.isReady&&(this.afterInit(this.jodit),this.__afterPluginSystemInit(),this.jodit.e.fire("rebuildToolbar"))}__beforeDestruct(){if(this.isInDestruct)return;let{j:e}=this;if(e.e.off("afterPluginSystemInit",this.__afterPluginSystemInit).off("afterInit",this.__afterInit).off("beforeDestruct",this.destruct),this.setStatus(r.STATUSES.beforeDestruct),!this.__inited)return super.destruct();if((0,a.isJoditObject)(e)){var t;null==(t=this.buttons)||t.forEach(t=>{null==e||e.unregisterButton(t)})}this.beforeDestruct(this.j),super.destruct()}constructor(e){super(e),(0,n._)(this,"buttons",[]),(0,n._)(this,"hasStyle",!1),(0,n._)(this,"styles",void 0),(0,n._)(this,"__inited",!1),e.e.on("afterPluginSystemInit",this.__afterPluginSystemInit).on("afterInit",this.__afterInit).on("beforeDestruct",this.__beforeDestruct)}}(0,n._)(l,"requires",[]),(0,o.__decorate)([s.autobind],l.prototype,"__afterPluginSystemInit",null),(0,o.__decorate)([s.autobind],l.prototype,"__afterInit",null),(0,o.__decorate)([s.autobind],l.prototype,"__beforeDestruct",null)},17338:function(e,t,i){"use strict";i.d(t,{Ajax:function(){return h}});var n=i(25045),o=i(31635),r=i(91231),s=i(81937),a=i(49574),l=i(65946),u=i(33201),c=i(5266);i(37102);var d=i(32855);class h{className(){return"Ajax"}__buildParams(e,t){return(0,l.isPlainObject)(e)&&this.options.contentType&&this.options.contentType.includes("application/json")?JSON.stringify(e):(0,l.isFunction)(this.o.queryBuild)?this.o.queryBuild.call(this,e,t):(0,l.isString)(e)||e instanceof s.globalWindow.FormData||"object"==typeof e&&null!=e&&(0,l.isFunction)(e.append)?e:(0,l.buildQuery)(e)}get o(){return this.options}abort(){if(this.__isFulfilled)return this;try{this.__isFulfilled=!0,this.xhr.abort()}catch(e){}return this}send(){this.__activated=!0;let{xhr:e,o:t}=this,i=this.prepareRequest();return this.__async.promise(async(n,o)=>{var r;let s=()=>{this.__isFulfilled=!0,o(u.connection("Connection error"))},a=()=>{this.__isFulfilled=!0,n(new d.Response(i,e.status,e.statusText,!e.responseType?e.responseText:e.response))};e.onload=a,e.onabort=()=>{this.__isFulfilled=!0,o(u.abort("Abort connection"))},e.onerror=s,e.ontimeout=s,t.responseType&&(e.responseType=t.responseType),e.onprogress=e=>{var t,i;let n=0;e.lengthComputable&&(n=e.loaded/e.total*100),null==(t=(i=this.options).onProgress)||t.call(i,n)},e.onreadystatechange=()=>{var i,n;null==(i=(n=this.options).onProgress)||i.call(n,10),e.readyState===XMLHttpRequest.DONE&&(t.successStatuses.includes(e.status)?a():e.statusText&&(this.__isFulfilled=!0,o(u.connection(e.statusText))))},e.withCredentials=null!=(r=t.withCredentials)&&r;let{url:c,data:h,method:p}=i;e.open(p,c,!0),t.contentType&&e.setRequestHeader&&e.setRequestHeader("Content-type",t.contentType);let{headers:f}=t;(0,l.isFunction)(f)&&(f=await f.call(this)),f&&e.setRequestHeader&&Object.keys(f).forEach(t=>{e.setRequestHeader(t,f[t])}),this.__async.setTimeout(()=>{e.send(h?this.__buildParams(h):void 0)},0)})}async *stream(){var e;this.__activated=!0;let{xhr:t,o:i}=this,n=this.prepareRequest(),o=0,r="",s=[],a=null,c=!1,d=null,h=()=>{if(a){let e=a;a=null,e()}},p=e=>{var i;let n=t.responseText;r+=n.substring(o),o=n.length;let a=r.split("\n\n");for(let t of(r=e?"":null!=(i=a.pop())?i:"",a)){let e=t.trim();if(!e)continue;let i=[];for(let t of e.split("\n"))t.startsWith("data: ")?i.push(t.slice(6)):t.startsWith("data:")&&i.push(t.slice(5));i.length&&s.push(i.join("\n"))}h()};t.onprogress=()=>p(!1),t.onload=()=>{p(!0),c=!0,this.__isFulfilled=!0,h()},t.onerror=()=>{d=u.connection("Connection error"),c=!0,this.__isFulfilled=!0,h()},t.onabort=()=>{d=u.abort("Abort connection"),c=!0,this.__isFulfilled=!0,h()},t.withCredentials=null!=(e=i.withCredentials)&&e;let{url:f,data:m,method:g}=n;t.open(g,f,!0),i.contentType&&t.setRequestHeader&&t.setRequestHeader("Content-type",i.contentType);let{headers:v}=i;(0,l.isFunction)(v)&&(v=await v.call(this)),v&&t.setRequestHeader&&Object.keys(v).forEach(e=>{t.setRequestHeader(e,v[e])}),t.send(m?this.__buildParams(m):void 0);try{for(;;)if(s.length>0)yield s.shift();else if(c)break;else await new Promise(e=>{a=e})}finally{this.__isFulfilled||this.abort()}if(d)throw d}prepareRequest(){if(!this.o.url)throw u.error("Need URL for AJAX request");let e=this.o.url,t=this.o.data,i=(this.o.method||"get").toLowerCase();if("get"===i&&t&&(0,l.isPlainObject)(t)){let i=e.indexOf("?");if(-1!==i){let n=(0,l.parseQuery)(e);e=e.substring(0,i)+"?"+(0,l.buildQuery)({...n,...t})}else e+="?"+(0,l.buildQuery)(this.o.data)}let n={url:e,method:i,data:t};return h.log.splice(100),h.log.push(n),n}destruct(){this.__isDestructed||(this.__isDestructed=!0,this.__activated&&!this.__isFulfilled&&(this.abort(),this.__isFulfilled=!0),this.__async.destruct())}constructor(e,t=c.Config.prototype.defaultAjaxOptions){(0,n._)(this,"__async",new r.Async),(0,n._)(this,"xhr",void 0),(0,n._)(this,"options",void 0),(0,n._)(this,"__isFulfilled",!1),(0,n._)(this,"__activated",!1),(0,n._)(this,"__isDestructed",!1),this.options=(0,l.ConfigProto)(e||{},t),this.xhr=this.o.xhr?this.o.xhr():new XMLHttpRequest}}(0,n._)(h,"log",[]),(0,o.__decorate)([a.autobind],h.prototype,"destruct",null)},37102:function(e,t,i){"use strict";i(5266).Config.prototype.defaultAjaxOptions={successStatuses:[200,201,202],method:"GET",url:"",data:null,contentType:"application/x-www-form-urlencoded; charset=UTF-8",headers:{"X-REQUESTED-WITH":"XMLHttpRequest"},withCredentials:!1,xhr(){return new XMLHttpRequest}}},73714:function(e,t,i){"use strict";i.d(t,{Ajax:function(){return n.Ajax},Response:function(){return o.Response}});var n=i(17338),o=i(32855)},32855:function(e,t,i){"use strict";i.d(t,{Response:function(){return o}});var n=i(25045);class o{get url(){return this.request.url}async json(){return JSON.parse(this.body)}text(){return Promise.resolve(this.body)}async blob(){return this.body}constructor(e,t,i,o){(0,n._)(this,"status",void 0),(0,n._)(this,"statusText",void 0),(0,n._)(this,"request",void 0),(0,n._)(this,"body",void 0),this.request=e,this.status=t,this.statusText=i,this.body=o}}},42259:function(e,t,i){"use strict";i.d(t,{cursorInTheEdgeOfString:function(){return s},findCorrectCurrentNode:function(){return a},moveNodeInsideStart:function(){return r.moveNodeInsideStart}});var n=i(81937),o=i(23211),r=i(89817);function s(e,t,i,o){var r;let s=(null==(r=e.nodeValue)?void 0:r.length)?e.nodeValue:"";if(o&&s.replace((0,n.INVISIBLE_SPACE_REG_EXP_END)(),"").length>t)return!0;let a=(0,n.INVISIBLE_SPACE_REG_EXP_START)().exec(s);return i&&(a&&a[0].length<t||!a&&t>0)}function a(e,t,i,n,r,s){if((e=t.startContainer.childNodes[t.startOffset])||(e=t.startContainer.childNodes[t.startOffset-1],i=!0),e&&n&&!o.Dom.isText(e)){if(!i&&o.Dom.isText(e.previousSibling))e=e.previousSibling;else if(r){let t=s(e);for(;t;){if(t&&o.Dom.isText(t)){e=t;break}t=s(t)}}}if(e&&!n&&!o.Dom.isText(e)){let t=e,i=e;do t=t.firstChild,i=i.lastChild;while(t&&i&&!o.Dom.isText(t));t===i&&t&&o.Dom.isText(t)&&(e=t)}return{node:e,rightMode:i}}i(7470)},89817:function(e,t,i){"use strict";i.d(t,{moveNodeInsideStart:function(){return r}});var n=i(81937),o=i(23211);function r(e,t,i){let r=o.Dom.findSibling(t,i),s=o.Dom.findSibling(t,!i);for(;o.Dom.isElement(r)&&!o.Dom.isTag(r,n.INSEPARABLE_TAGS)&&o.Dom.isContentEditable(r,e.editor)&&(!s||!o.Dom.closest(t,o.Dom.isElement,e.editor));)i||!r.firstChild?r.appendChild(t):o.Dom.before(r.firstChild,t),r=o.Dom.sibling(t,i),s=o.Dom.sibling(t,!i)}},7470:function(e,t,i){"use strict";i.d(t,{moveTheNodeAlongTheEdgeOutward:function(){return o}});var n=i(23211);function o(e,t,i){let o=e;for(;o&&o!==i&&!(n.Dom.findSibling(o,t)||n.Dom.isBlock(o.parentElement));)(o=o.parentElement)&&o!==i&&(t?n.Dom.before(o,e):n.Dom.after(o,e))}},59841:function(e,t,i){"use strict";i.d(t,{CommitStyle:function(){return o.CommitStyle},Selection:function(){return n.Selection}});var n=i(98595),o=i(84578)},98595:function(e,t,i){"use strict";i.d(t,{Selection:function(){return f}});var n=i(25045),o=i(31635),r=i(81937),s=i(84839),a=i(23211),l=i(65946),u=i(28686),c=i(28712),d=i(7470),h=i(84578),p=i(42259);class f{get j(){return this.jodit}errorNode(e){if(!a.Dom.isNode(e))throw(0,l.error)("Parameter node must be instance of Node")}get area(){return this.j.editor}get win(){return this.j.ew}get doc(){return this.j.ed}get sel(){return this.j.o.shadowRoot&&(0,u.isFunction)(this.j.o.shadowRoot.getSelection)?this.j.o.shadowRoot.getSelection():this.win.getSelection()}get range(){let e=this.sel;return e&&e.rangeCount?e.getRangeAt(0):this.createRange()}get isInsideArea(){let{sel:e}=this,t=(null==e?void 0:e.rangeCount)?e.getRangeAt(0):null;return!(!t||!a.Dom.isOrContains(this.area,t.startContainer))}createRange(e=!1){let t=this.doc.createRange();return e&&this.selectRange(t),t}remove(){let e=this.sel,t=this.current();if(e&&t)for(let t=0;t<e.rangeCount;t+=1)e.getRangeAt(t).deleteContents(),e.getRangeAt(t).collapse(!0)}clear(){var e,t;(null==(e=this.sel)?void 0:e.rangeCount)&&(null==(t=this.sel)||t.removeAllRanges())}removeNode(e){if(!a.Dom.isOrContains(this.j.editor,e,!0))throw(0,l.error)("Selection.removeNode can remove only editor's children");a.Dom.safeRemove(e),this.j.e.fire("afterRemoveNode",e)}insertCursorAtPoint(e,t){this.removeMarkers();try{let i=this.createRange();return(()=>{if(this.doc.caretPositionFromPoint){let n=this.doc.caretPositionFromPoint(e,t);if(n)return i.setStart(n.offsetNode,n.offset)}if(this.doc.caretRangeFromPoint){let n=this.doc.caretRangeFromPoint(e,t);(0,c.assert)(n,"Incorrect caretRangeFromPoint behaviour"),i.setStart(n.startContainer,n.startOffset)}})(),i.collapse(!0),this.selectRange(i),!0}catch(e){}return!1}get hasMarkers(){return!!this.markers.length}get markers(){return(0,l.$$)("span[data-"+r.MARKER_CLASS+"]",this.area)}removeMarkers(){a.Dom.safeRemove.apply(null,this.markers)}marker(e=!1,t){let i=null;t&&(i=t.cloneRange()).collapse(e);let n=this.j.createInside.span();return n.id=r.MARKER_CLASS+"_"+Number(new Date)+"_"+String(Math.random()).slice(2),n.style.lineHeight="0",n.style.display="none",a.Dom.markTemporary(n),(0,l.attr)(n,"data-"+r.MARKER_CLASS,e?"start":"end"),n.appendChild(this.j.createInside.text(r.INVISIBLE_SPACE)),i&&a.Dom.isOrContains(this.area,e?i.startContainer:i.endContainer)&&i.insertNode(n),n}restore(){let e=!1,t=e=>`span[data-${r.MARKER_CLASS}=${e?"start":"end"}]`,i=this.area.querySelector(t(!0)),n=this.area.querySelector(t(!1));if(i){if(e=this.createRange(),n)e.setStartAfter(i),a.Dom.safeRemove(i),e.setEndBefore(n),a.Dom.safeRemove(n);else{let t=i.previousSibling;a.Dom.isText(t)?e.setStart(t,t.nodeValue?t.nodeValue.length:0):e.setStartBefore(i),a.Dom.safeRemove(i),e.collapse(!0)}e&&this.selectRange(e)}}fakes(){let e=this.sel;if(!e||!e.rangeCount)return[];let t=e.getRangeAt(0);(0,c.assert)(t,"Range is null");let i=t.cloneRange();i.collapse(!0);let n=this.j.createInside.fake();a.Dom.safeInsertNode(i,n),t.setStartBefore(n);let o=[n];if(!t.collapsed){let e=t.cloneRange();e.collapse(!1);let i=this.j.createInside.fake();a.Dom.safeInsertNode(e,i),t.setEndAfter(i),o.push(i)}return this.selectRange(t),o}restoreFakes(e){var t,i,n,o;let r=e.filter(e=>e.isConnected);if(!r.length)return;let[s,l]=r,u=this.createRange();u.setStartAfter(s),l&&u.setEndBefore(l),this.selectRange(u),(null==(t=s.parentNode)?void 0:t.firstChild)!==(null==(i=s.parentNode)?void 0:i.lastChild)&&a.Dom.safeRemove(s),(null==l||null==(n=l.parentNode)?void 0:n.firstChild)!==(null==l||null==(o=l.parentNode)?void 0:o.lastChild)&&a.Dom.safeRemove(l)}save(e=!1){if(this.hasMarkers)return[];let t=this.sel;if(!t||!t.rangeCount)return[];let i=[],n=t.rangeCount,o=[];for(let e=0;n>e;e+=1)if(o[e]=t.getRangeAt(e),o[e].collapsed){let t=this.marker(!0,o[e]);i[e]={startId:t.id,collapsed:!0,startMarker:t.outerHTML}}else{let t=this.marker(!0,o[e]),n=this.marker(!1,o[e]);i[e]={startId:t.id,endId:n.id,collapsed:!1,startMarker:t.outerHTML,endMarker:n.outerHTML}}if(!e){t.removeAllRanges();for(let e=n-1;e>=0;--e){let n=this.doc.getElementById(i[e].startId);if(n){if(i[e].collapsed)o[e].setStartAfter(n),o[e].collapse(!0);else if(o[e].setStartBefore(n),i[e].endId){let t=this.doc.getElementById(i[e].endId);t&&o[e].setEndAfter(t)}try{t.addRange(o[e].cloneRange())}catch(e){}}}}return i}focus(e={preventScroll:!0}){if(!this.isFocused()){let n=(0,l.getScrollParent)(this.j.container),o=null==n?void 0:n.scrollTop;this.j.iframe&&"complete"===this.doc.readyState&&this.j.iframe.focus(e),this.win.focus(),this.area.focus(e),o&&(null==n?void 0:n.scrollTo)&&n.scrollTo(0,o);let r=this.sel,s=(null==r?void 0:r.rangeCount)?null==r?void 0:r.getRangeAt(0):null;if(!s||!a.Dom.isOrContains(this.area,s.startContainer)){let e=this.createRange();e.setStart(this.area,0),e.collapse(!0),this.selectRange(e,!1)}if(!this.j.editorIsActive){var t,i;null==(i=this.j)||null==(t=i.events)||t.fire("focus")}return!0}return!1}isCollapsed(){let e=this.sel;for(let t=0;e&&t<e.rangeCount;t+=1)if(!e.getRangeAt(t).collapsed)return!1;return!0}isFocused(){return this.doc.hasFocus&&this.doc.hasFocus()&&this.area===this.doc.activeElement}current(e=!0){if(this.j.getRealMode()!==r.MODE_WYSIWYG)return null;let t=this.sel;if(!t||0===t.rangeCount)return null;let i=t.getRangeAt(0),n=i.startContainer,o=!1;if(a.Dom.isTag(n,"br")&&t.isCollapsed)return n;if(!a.Dom.isText(n)){let r=(0,p.findCorrectCurrentNode)(n,i,o,t.isCollapsed,e,e=>o?e.lastChild:e.firstChild);n=r.node,o=r.rightMode}return n&&a.Dom.isOrContains(this.area,n)?n:null}insertNode(e,t=!0,i=!0){this.errorNode(e);let n=a.Dom.isFragment(e)?e.lastChild:e;this.j.e.fire("safeHTML",e),!this.isFocused()&&this.j.isEditorMode()&&(this.focus(),this.restore());let o=this.sel;this.j.history.snapshot.transaction(()=>{if(this.isCollapsed()||this.j.execCommand("Delete"),this.j.e.fire("beforeInsertNode",e),o&&o.rangeCount){let t=o.getRangeAt(0),{firstChild:i}=e;a.Dom.isOrContains(this.area,t.commonAncestorContainer)?a.Dom.safeInsertNode(t,e):this.area.appendChild(e),[()=>null==i?void 0:i.previousSibling,()=>null==i?void 0:i.previousSibling,()=>{var e;return null==i||null==(e=i.previousSibling)?void 0:e.lastChild}].forEach(e=>{let t=e();t&&a.Dom.isEmptyTextNode(t)&&a.Dom.safeRemove(t)})}else this.area.appendChild(e);let i=e=>{if(a.Dom.isBlock(e)){let t=e.lastChild;if(t)return i(t)}this.setCursorAfter(e)};t&&(a.Dom.isFragment(e)?n&&i(n):i(e)),this.j.o.scrollToPastedContent&&(0,l.scrollIntoViewIfNeeded)(null!=n?n:e,this.j.editor,this.doc)}),i&&this.j.events&&this.j.__imdSynchronizeValues(),this.j.events&&this.j.e.fire("afterInsertNode",a.Dom.isFragment(e)?n:e)}insertHTML(e,t=!0){if(""===e)return;let i=this.j.createInside.div(),n=this.j.createInside.fragment();if(!this.isFocused()&&this.j.isEditorMode()&&(this.focus(),this.restore()),a.Dom.isNode(e)?i.appendChild(e):i.innerHTML=e.toString(),(this.j.isEditorMode()||!1!==this.j.e.fire("insertHTML",i.innerHTML))&&i.lastChild){for(;i.firstChild;)i.firstChild,n.appendChild(i.firstChild);this.insertNode(n,t,!1),this.j.__imdSynchronizeValues()}}insertImage(e,t=null,i=null){let n=(0,u.isString)(e)?this.j.createInside.element("img"):e;if((0,u.isString)(e)&&n.setAttribute("src",e),null!=i){let e=i.toString();e&&"auto"!==e&&0>String(e).indexOf("px")&&0>String(e).indexOf("%")&&(e+="px"),(0,l.attr)(n,"width",e)}t&&"object"==typeof t&&(0,l.css)(n,t);let o=()=>{(n.naturalHeight<n.offsetHeight||n.naturalWidth<n.offsetWidth)&&(n.style.width="",n.style.height=""),n.removeEventListener("load",o)};this.j.e.on(n,"load",o),n.complete&&o(),this.insertNode(n),this.j.e.fire("afterInsertImage",n)}eachSelection(e){var t;let i=this.sel;if(!i||!i.rangeCount)return;let n=i.getRangeAt(0),o=n.commonAncestorContainer;a.Dom.isHTMLElement(o)||(o=o.parentElement);let s=[],c=n.startOffset,d=o.childNodes.length,h=n.startContainer===this.area?o.childNodes[c<d?c:d-1]:n.startContainer,p=n.endContainer===this.area?o.childNodes[n.endOffset-1]:n.endContainer;a.Dom.isText(h)&&h===n.startContainer&&n.startOffset===(null==(t=h.nodeValue)?void 0:t.length)&&h.nextSibling&&(h=h.nextSibling),a.Dom.isText(p)&&p===n.endContainer&&0===n.endOffset&&p.previousSibling&&(p=p.previousSibling);let f=e=>{!e||e===o||a.Dom.isEmptyTextNode(e)||(0,u.isMarker)(e)||s.push(e)};f(h),h!==p&&a.Dom.isOrContains(o,h,!0)&&a.Dom.find(h,e=>(f(e),e===p||e&&e.contains&&e.contains(p)),o,!0,!1);let m=t=>{if(a.Dom.isOrContains(this.j.editor,t,!0)){if(t.nodeName.match(/^(UL|OL)$/))return(0,l.toArray)(t.childNodes).forEach(m);if(a.Dom.isTag(t,"li"))if(t.firstChild)t=t.firstChild;else{let e=this.j.createInside.text(r.INVISIBLE_SPACE);t.appendChild(e),t=e}e(t)}};0===s.length&&(a.Dom.isEmptyTextNode(h)&&s.push(h),h.firstChild&&s.push(h.firstChild)),s.forEach(m)}cursorInTheEdge(e,t,i=null){var n;let o=!e,r=null==(n=this.sel)?void 0:n.getRangeAt(0);if(null!=i||(i=this.current(!1)),!r||!i||!a.Dom.isOrContains(t,i,!0))return null;let s=e?r.startContainer:r.endContainer,u=e?r.startOffset:r.endOffset,c=e=>!!(e&&!a.Dom.isTag(e,"br")&&!a.Dom.isEmptyTextNode(e)&&!a.Dom.isTemporary(e)&&!(a.Dom.isElement(e)&&!0===this.j.e.fire("isInvisibleForCursor",e)));if(a.Dom.isText(s)){if((0,p.cursorInTheEdgeOfString)(s,u,e,o))return!1}else{let e=(0,l.toArray)(s.childNodes);if(o){if(e.slice(u).some(c))return!1}else if(e.slice(0,u).some(c))return!1}let d=i;for(;d&&d!==t;){let t=a.Dom.sibling(d,e);if(!t){d=d.parentNode;continue}if((d=t)&&c(d))return!1}return!0}cursorOnTheLeft(e,t){return this.cursorInTheEdge(!0,e,t)}cursorOnTheRight(e,t){return this.cursorInTheEdge(!1,e,t)}setCursorAfter(e){return this.setCursorNearWith(e,!1)}setCursorBefore(e){return this.setCursorNearWith(e,!0)}setCursorNearWith(e,t){if(this.errorNode(e),!a.Dom.up(e,e=>e===this.area||e&&e.parentNode===this.area,this.area))throw(0,l.error)("Node element must be in editor");let i=this.createRange(),n=null;if(a.Dom.isText(e))if(t)i.setStart(e,0);else{var o,r;i.setEnd(e,null!=(o=null==(r=e.nodeValue)?void 0:r.length)?o:0)}else n=this.j.createInside.fake(),t?i.setStartBefore(e):i.setEndAfter(e),i.collapse(t),a.Dom.safeInsertNode(i,n),i.selectNode(n);return i.collapse(t),this.selectRange(i),n}setCursorIn(e,t=!1){if(this.errorNode(e),!a.Dom.up(e,e=>e===this.area||e&&e.parentNode===this.area,this.area))throw(0,l.error)("Node element must be in editor");let i=this.createRange(),n=e,o=e;do{if(a.Dom.isText(n)||a.Dom.isTag(n,r.INSEPARABLE_TAGS))break;o=n,n=t?n.firstChild:n.lastChild}while(n);if(!n){let e=this.j.createInside.text(r.INVISIBLE_SPACE);a.Dom.isTag(o,r.INSEPARABLE_TAGS)?n=o:(o.appendChild(e),o=e)}let s=n||o;return a.Dom.isTag(s,r.INSEPARABLE_TAGS)?t||a.Dom.isTag(s,"br")?i.setStartBefore(s):i.setEndAfter(s):i.selectNodeContents(s),i.collapse(t),this.selectRange(i),o}selectRange(e,t=!0){let i=this.sel;return t&&!this.isFocused()&&"focus"!==this.j.e.current&&this.focus(),i&&(i.removeAllRanges(),i.addRange(e)),this.j.e.fire("changeSelection"),this}select(e,t=!1){if(this.errorNode(e),!a.Dom.up(e,e=>e===this.area||e&&e.parentNode===this.area,this.area))throw(0,l.error)("Node element must be in editor");let i=this.createRange();return i[t?"selectNodeContents":"selectNode"](e),this.selectRange(i)}get html(){let e=this.sel;if(e&&e.rangeCount>0){let t=e.getRangeAt(0).cloneContents(),i=this.j.createInside.div();return i.appendChild(t),i.innerHTML}return""}*wrapInTagGen(e){if(this.isCollapsed()){let t=this.jodit.createInside.element("font",r.INVISIBLE_SPACE);this.insertNode(t,!1,!1),e&&e[0]&&t.appendChild(e[0]),yield t,a.Dom.unwrap(t);return}for(let e of((0,l.$$)("*[style*=font-size]",this.area).forEach(e=>{(0,l.attr)(e,"data-font-size",e.style.fontSize.toString()),e.style.removeProperty("font-size")}),this.j.nativeExecCommand("fontsize",!1,"7"),(0,l.$$)("*[data-font-size]",this.area).forEach(e=>{let t=(0,l.attr)(e,"data-font-size");t&&(e.style.fontSize=t,(0,l.attr)(e,"data-font-size",null))}),(0,l.$$)('font[size="7"]',this.area))){let{firstChild:t,lastChild:i}=e;if(t&&t===i&&(0,u.isMarker)(t)){a.Dom.unwrap(e);continue}t&&(0,u.isMarker)(t)&&a.Dom.before(e,t),i&&(0,u.isMarker)(i)&&a.Dom.after(e,i),yield e,a.Dom.unwrap(e)}}wrapInTag(e){let t=[];for(let i of this.wrapInTagGen())try{if(i.firstChild&&i.firstChild===i.lastChild&&(0,u.isMarker)(i.firstChild))continue;(0,u.isFunction)(e)?e(i):t.push(a.Dom.replace(i,e,this.j.createInside))}finally{let e=i.parentNode;e&&(a.Dom.unwrap(i),a.Dom.isEmpty(e)&&a.Dom.unwrap(e))}return t}commitStyle(e){(0,c.assert)((0,l.size)(e)>0,"Need to pass at least one option"),new h.CommitStyle(e).apply(this.j)}splitSelection(e,t){if(!this.isCollapsed())return null;let i=this.createRange(),n=this.range;i.setStartBefore(e);let o=this.cursorOnTheRight(e,t),s=this.cursorOnTheLeft(e,t),l=this.j.createInside.element("br"),u=this.j.createInside.fake(),d=u.cloneNode();try{if(o||s){t?a.Dom.before(t,l):a.Dom.safeInsertNode(n,l);let e=(e,t)=>{let i=t(e);for(;i;){let e=t(i);if(i&&(a.Dom.isTag(i,"br")||a.Dom.isEmptyTextNode(i)))a.Dom.safeRemove(i);else break;i=e}};e(l,e=>e.nextSibling),e(l,e=>e.previousSibling),a.Dom.after(l,d),a.Dom.before(l,u),o?(i.setEndBefore(l),n.setEndBefore(l)):(i.setEndAfter(l),n.setEndAfter(l))}else i.setEnd(n.startContainer,n.startOffset);let h=i.extractContents(),p=e=>a.Dom.each(e,e=>a.Dom.isEmptyTextNode(e)&&a.Dom.safeRemove(e));(0,c.assert)(e.parentNode,"Splitting fails");try{if(p(h),p(e),e.parentNode.insertBefore(h,e),!t&&o&&(null==l?void 0:l.parentNode)){let e=this.createRange();e.setStartBefore(l),this.selectRange(e)}}catch(e){if(!r.IS_PROD)throw e}let f=e=>{var t,i,n;(null==e||null==(t=e.parentNode)?void 0:t.firstChild)===(null==e||null==(i=e.parentNode)?void 0:i.lastChild)&&(null==e||null==(n=e.parentNode)||n.appendChild(l.cloneNode()))};f(u),f(d)}finally{a.Dom.safeRemove(u),a.Dom.safeRemove(d)}return e.previousElementSibling}expandSelection(){if(this.isCollapsed())return this;let{range:e}=this,t=e.cloneRange();if(!a.Dom.isOrContains(this.j.editor,e.commonAncestorContainer,!0))return this;let i=t=>{let i=this.j.createInside.fake(),n=e.cloneRange();return n.collapse(t),a.Dom.safeInsertNode(n,i),(0,d.moveTheNodeAlongTheEdgeOutward)(i,t,this.j.editor),i},n=i(!0),o=i(!1);t.setStartAfter(n),t.setEndBefore(o);let r=a.Dom.findSibling(n,!1),s=a.Dom.findSibling(o,!0);if(r!==s){let e=a.Dom.isElement(r)&&a.Dom.isOrContains(r,o),i=!e&&a.Dom.isElement(s)&&a.Dom.isOrContains(s,n);if(e||i){let i=e?r:s,l=i;for(;a.Dom.isElement(i);)(i=e?i.firstElementChild:i.lastElementChild)&&(e?a.Dom.isOrContains(i,o):a.Dom.isOrContains(i,n))&&(l=i);e?t.setStart(l,0):t.setEnd(l,l.childNodes.length)}}if(this.selectRange(t),a.Dom.safeRemove(n,o),this.isCollapsed())throw(0,l.error)("Selection is collapsed");return this}constructor(e){(0,n._)(this,"jodit",void 0),this.jodit=e,e.e.on("removeMarkers",()=>{this.removeMarkers()})}}(0,o.__decorate)([s.autobind],f.prototype,"createRange",null),(0,o.__decorate)([s.autobind],f.prototype,"focus",null),(0,o.__decorate)([s.autobind],f.prototype,"setCursorAfter",null),(0,o.__decorate)([s.autobind],f.prototype,"setCursorBefore",null),(0,o.__decorate)([s.autobind],f.prototype,"setCursorIn",null)},17481:function(e,t,i){"use strict";i.d(t,{extractSelectedPart:function(){return a}});var n=i(23211),o=i(23175),r=i(4040),s=i(71125);function a(e,t,i){let n=i.s.createRange(),r=(0,o.isMarker)(t.previousSibling)?t.previousSibling:t;n.setStartBefore(e),n.setEndBefore(r),l(e,n,!0);let s=(0,o.isMarker)(t.nextSibling)?t.nextSibling:t;n.setStartAfter(s),n.setEndAfter(e),l(e,n,!1)}function l(e,t,i){let o=t.extractContents();o.textContent&&(0,r.trim)(o.textContent).length||!o.firstChild||n.Dom.unwrap(o.firstChild),e.parentNode&&(0,s.call)(i?n.Dom.before:n.Dom.after,e,o)}},48729:function(e,t,i){"use strict";i.d(t,{FiniteStateMachine:function(){return a}});var n=i(25045),o=i(81937),r=i(85932),s=i(28712);class a{setState(e){(0,s.assert)(!this.__previewsStates.has(e),"Circled states"),this.__previewsStates.add(e),this.__state=e}getState(){return this.__state}disableSilent(){this.silent=!1}dispatch(e,t){let i=this.transitions[this.getState()][e];if(i){let e=i.call(this,t);return(0,s.assert)(e&&e!==t,"Action should return new value"),(0,s.assert)((0,r.isString)(e.next),"Value should contain the next state"),(0,s.assert)(e.next!==this.getState(),"The new state should not be equal to the old one."),this.setState(e.next),o.IS_PROD||this.silent,e}throw Error(`invalid action: ${this.getState()}.${e.toString()}`)}constructor(e,t){(0,n._)(this,"transitions",void 0),(0,n._)(this,"__state",void 0),(0,n._)(this,"silent",void 0),(0,n._)(this,"__previewsStates",void 0),this.transitions=t,this.silent=!0,this.__previewsStates=new Set,this.setState(e)}}},10171:function(e,t,i){"use strict";i.d(t,{getSuitChild:function(){return s}});var n=i(23211),o=i(83653),r=i(73019);function s(e,t){let{firstChild:i}=t;for(;i&&!(0,o.isNormalNode)(i);)if(!(i=i.nextSibling))return null;return i&&!n.Dom.next(i,o.isNormalNode,t)&&(0,r.isSuitElement)(e,i,!1)?i:null}},19549:function(e,t,i){"use strict";i.d(t,{getSuitParent:function(){return function e(t,i,s){let{parentNode:a}=i;return a===s||!n.Dom.isHTMLElement(a)||n.Dom.next(i,o.isNormalNode,a)||n.Dom.prev(i,o.isNormalNode,a)?null:t.isElementCommit&&t.elementIsBlock&&!n.Dom.isBlock(a)?e(t,a,s):(0,r.isSuitElement)(t,a,!1)&&(!n.Dom.isBlock(a)||t.elementIsBlock)?a:t.isElementCommit&&!n.Dom.isBlock(a)?e(t,a,s):null}}});var n=i(23211),o=i(83653),r=i(73019)},9703:function(e,t,i){"use strict";i.d(t,{hasSameStyle:function(){return u},hasSameStyleKeys:function(){return c}});var n=i(81937),o=i(23211),r=i(18303),s=i(19147),a=i(28712),l=i(80991);function u(e,t){return!!(!o.Dom.isTag(e,"font")&&o.Dom.isHTMLElement(e)&&Object.keys(t).every(i=>{let n=(0,l.css)(e,i,!0);return""===n&&(""===t[i]||null==t[i])||!(0,r.isVoid)(n)&&""!==n&&!(0,r.isVoid)(t[i])&&(0,s.normalizeCssValue)(i,t[i]).toString().toLowerCase()===n.toString().toLowerCase()}))}if(n.globalDocument){let e=n.globalDocument.createElement("div");e.style.color="red",(0,a.assert)(u(e,{color:"red"}),"Style test"),(0,a.assert)(u(e,{fontSize:null}),"Style test"),(0,a.assert)(u(e,{fontSize:""}),"Style test")}function c(e,t){return!!(!o.Dom.isTag(e,"font")&&o.Dom.isHTMLElement(e)&&Object.keys(t).every(t=>""!==(0,l.css)(e,t,!0)))}if(n.globalDocument){let e=n.globalDocument.createElement("div");e.style.color="red",(0,a.assert)(c(e,{color:"red"}),"Style test"),(0,a.assert)(!c(e,{font:"Arial",color:"red"}),"Style test"),(0,a.assert)(!c(e,{border:"1px solid #ccc"}),"Style test")}},51640:function(e,t,i){"use strict";i.d(t,{FiniteStateMachine:function(){return o.FiniteStateMachine},extractSelectedPart:function(){return n.extractSelectedPart},getSuitChild:function(){return r.getSuitChild},getSuitParent:function(){return s.getSuitParent},isInsideInvisibleElement:function(){return a.isInsideInvisibleElement},suitableClosest:function(){return l.suitableClosest},toggleAttributes:function(){return c.toggleAttributes},toggleOrderedList:function(){return u.toggleOrderedList},unwrapChildren:function(){return d.unwrapChildren},wrap:function(){return h.wrap}});var n=i(17481),o=i(48729),r=i(10171),s=i(19549);i(9703);var a=i(39608);i(83653),i(95971);var l=i(73019),u=i(34582);i(97110);var c=i(82794),d=i(89081),h=i(73154);i(83335)},39608:function(e,t,i){"use strict";i.d(t,{isInsideInvisibleElement:function(){return o}});var n=i(23211);function o(e,t){return!!n.Dom.closest(e,["style","script"],t)}},83653:function(e,t,i){"use strict";i.d(t,{isNormalNode:function(){return r}});var n=i(23211),o=i(23175);function r(e){return!!(e&&!n.Dom.isEmptyTextNode(e)&&!n.Dom.isTemporary(e)&&!(0,o.isMarker)(e))}},95971:function(e,t,i){"use strict";i.d(t,{elementsEqualAttributes:function(){return l},isSameAttributes:function(){return a}});var n=i(18073),o=i(93640),r=i(28712),s=i(9703);function a(e,t){return!((e.attributes.length||(0,n.size)(t))&&(0,n.size)(t))||((0,r.assert)(t,"Attrs must be a non-empty object"),Object.keys(t).every(i=>"class"===i||"className"===i?e.classList.contains(t[i]):"style"===i?(0,s.hasSameStyle)(e,t[i]):(0,o.attr)(e,i)===t[i]))}function l(e,t){return e.attributes.length===t.attributes.length&&Array.from(e.attributes).every(e=>t.hasAttribute(e.name)&&t.getAttribute(e.name)===e.value)}},73019:function(e,t,i){"use strict";i.d(t,{isSameStyleChild:function(){return l},isSuitElement:function(){return s},suitableClosest:function(){return a}});var n=i(23211),o=i(9703),r=i(83653);function s(e,t,i,a=!0){var l;if(!t||!(0,r.isNormalNode)(t))return!1;let{element:u,elementIsDefault:c,options:d}=e;if(n.Dom.isList(t)&&e.elementIsList)return!0;let h=n.Dom.isTag(t,u);return!!(h&&!(c&&i)||(null==(l=d.attributes)?void 0:l.style)&&(a?(0,o.hasSameStyle)(t,d.attributes.style):(0,o.hasSameStyleKeys)(t,d.attributes.style))&&!e.elementIsList)||!h&&!i&&c&&n.Dom.isInlineBlock(t)}function a(e,t,i){return n.Dom.closest(t,t=>s(e,t,!0,!1),i)}function l(e,t){var i,n;let{element:s,options:a}=e;if(!t||!(0,r.isNormalNode)(t))return!1;let l=t.nodeName.toLowerCase()===s,u=!!((null==(i=a.attributes)?void 0:i.style)&&(0,o.hasSameStyleKeys)(t,null==(n=a.attributes)?void 0:n.style));return l&&u}},34582:function(e,t,i){"use strict";i.d(t,{toggleOrderedList:function(){return u}});var n=i(23211),o=i(28712),r=i(17481),s=i(82794),a=i(98394),l=i(97110);function u(e,t,i,n){if(!t)return n;let o=t.parentElement;if(!o)return n;let r=i.e.fire(`${a._PREFIX}BeforeToggleList`,n,e,o);if(void 0!==r)return r;let u=i.e.fire.bind(i.e,`${a._PREFIX}AfterToggleList`);if(n!==a.UNWRAP){let r=(0,s.toggleAttributes)(e,t.parentElement,i,a.INITIAL,!0)===a.CHANGE;if(n===a.REPLACE||r||o.tagName.toLowerCase()!==e.element){let n=c(a.REPLACE,o,t,i,e),r=(0,l.wrapList)(e,n,i);return u(a.REPLACE,r,e),a.REPLACE}}let d=c(a.UNWRAP,o,t,i,e);return u(a.UNWRAP,d,e),a.UNWRAP}function c(e,t,i,s,l){let u=s.e.fire(`${a._PREFIX}BeforeUnwrapList`,e,t,l);return u?((0,o.assert)(n.Dom.isHTMLElement(u),`${a._PREFIX}BeforeUnwrapList hook must return HTMLElement`),u):((0,r.extractSelectedPart)(t,i,s),(0,o.assert)(n.Dom.isHTMLElement(i.parentElement),"Element should be inside the list"),n.Dom.unwrap(i.parentElement),n.Dom.replace(i,"br"!==s.o.enter.toLowerCase()?s.o.enter:s.createInside.fragment(),s.createInside))}},97110:function(e,t,i){"use strict";i.d(t,{wrapList:function(){return a}});var n=i(23211),o=i(95971),r=i(82794),s=i(98394);function a(e,t,i){let a=i.e.fire(`${s._PREFIX}BeforeWrapList`,s.REPLACE,t,e),l=null!=a?a:n.Dom.replace(t,"li",i.createInside),u=l.previousElementSibling,c=l.nextElementSibling,d=n.Dom.isTag(u,e.element)?u:null;return null!=d||(d=n.Dom.isTag(c,e.element)?c:null),n.Dom.isList(d)&&(0,o.isSameAttributes)(d,e.options.attributes)||(d=i.createInside.element(e.element),(0,r.toggleAttributes)(e,d,i,s.INITIAL),n.Dom.before(l,d)),u===d?n.Dom.append(d,l):n.Dom.prepend(d,l),n.Dom.isTag(d.nextElementSibling,e.element)&&(0,o.elementsEqualAttributes)(d,d.nextElementSibling)&&(n.Dom.append(d,Array.from(d.nextElementSibling.childNodes)),n.Dom.safeRemove(d.nextElementSibling)),i.e.fire(`${s._PREFIX}AfterWrapList`,s.WRAP,d,e),d}},82794:function(e,t,i){"use strict";i.d(t,{toggleAttributes:function(){return m}});var n=i(81937),o=i(23211),r=i(28077),s=i(28686),a=i(19147),l=i(18073),u=i(74264),c=i(93640),d=i(80991),h=i(36400),p=i(98394);let f="toggleAttributes";function m(e,t,i,v,_=!1){if(!_&&e.isApplied(t,f))return v;_||e.setApplied(t,f);let{attributes:b}=e.options;return b&&(0,l.size)(b)>0&&Object.keys(b).forEach(f=>{var m,y,S;let w=b[f];switch(f){case"style":m=v,(0,c.assert)((0,s.isPlainObject)(w)&&(0,l.size)(w),"Style must be an object"),Object.keys(w).forEach(s=>{let l=t.style.getPropertyValue((0,u.kebabCase)(s)),c=w[s];if(""!==l||null!=c){let u,f;if((u=i.create.element(t.tagName.toLowerCase())).style.cssText=t.style.cssText,(function(e){var t;if(void 0!==(0,h.dataBind)(e,"shadowRoot"))return(0,h.dataBind)(e,"shadowRoot");let i=(0,r.getContainer)(e),o=n.globalDocument.createElement("iframe");(0,d.css)(o,{width:0,height:0,position:"absolute",border:0}),o.src="about:blank",i.appendChild(o);let s=null==(t=o.contentWindow)?void 0:t.document,a=s?s.body:e.od.body;return(0,h.dataBind)(e,"shadowRoot",a),a})(i).appendChild(u),f=(0,d.css)(u,s),o.Dom.safeRemove(u),f===(0,a.normalizeCssValue)(s,c)){if(!l)return;_||(0,d.css)(t,s,null),m=g(e,t,m=p.UNSET);return}m=p.CHANGE,_||((0,d.css)(t,s,c),m=g(e,t,m))}}),v=m;break;case"className":case"class":let C;y=v,(0,c.assert)((0,s.isString)(w),"Class name must be a string"),C=i.e.fire.bind(i.e,`${p._PREFIX}AfterToggleAttribute`),t.classList.contains(w.toString())?(y=p.UNSET,_||(t.classList.remove(w),0===t.classList.length&&((0,c.attr)(t,"class",null),C(y,t,"class",null)))):(y=p.CHANGE,_||(t.classList.add(w),C(y,t,"class",w))),v=y;break;default:let k;S=v,(0,c.assert)((0,s.isString)(w)||(0,s.isNumber)(w)||(0,s.isBoolean)(w)||null==w,"Attribute value must be a string or number or boolean or null"),k=i.e.fire.bind(i.e,`${p._PREFIX}AfterToggleAttribute`),(0,c.attr)(t,f)===w?(_||(0,c.attr)(t,f,null),S=p.UNSET,_||k(S,t,f,w)):(S=p.CHANGE,_||((0,c.attr)(t,f,w),k(S,t,f,w))),v=S}}),v}function g(e,t,i){return(0,c.attr)(t,"style")||((0,c.attr)(t,"style",null),t.tagName.toLowerCase()===e.defaultTag&&(o.Dom.unwrap(t),i=p.UNWRAP)),i}},89081:function(e,t,i){"use strict";i.d(t,{unwrapChildren:function(){return a}});var n=i(23211),o=i(93640),r=i(9703),s=i(73019);function a(e,t){var i;let a,l=[],u=[],c=null==(i=e.options.attributes)?void 0:i.style;if(t.firstChild){let i=n.Dom.eachGen(t),d=i.next();for(;!d.done;){let t=d.value;(0,s.isSuitElement)(e,t,!0)&&(!c||(0,r.hasSameStyleKeys)(t,c))?(void 0===a&&(a=!0),l.push(t)):c&&(0,s.isSameStyleChild)(e,t)?(void 0===a&&(a=!1),u.push(()=>{(0,o.css)(t,Object.keys(c).reduce((e,t)=>(e[t]=null,e),{})),(0,o.attr)(t,"style")||(0,o.attr)(t,"style",null),(0,o.attr)(t,"style")||t.nodeName.toLowerCase()!==e.element||l.push(t)})):n.Dom.isEmptyTextNode(t)||void 0!==a||(a=!1),d=i.next()}}return u.forEach(e=>e()),l.forEach(n.Dom.unwrap),!!a}},83335:function(e,t,i){"use strict";i.d(t,{wrapUnwrappedText:function(){return r}});var n=i(23211),o=i(23175);function r(e,t,i){let r=i.editor,s=i.createInside,a=(e,t="previousSibling")=>{let s=e,a=e;for(;a&&!(0,o.isMarker)(a)&&!n.Dom.isTag(a,i.o.enter)&&(s=a,a=a[t]?a[t]:a.parentNode&&!n.Dom.isBlock(a.parentNode)&&a.parentNode!==r?a.parentNode:null,!n.Dom.isBlock(a)););return s},l=a(t),u=a(t,"nextSibling"),c=i.s.createRange();c.setStartBefore(l),c.setEndAfter(u);let d=c.extractContents(),h=s.element(e.element);return h.appendChild(d),n.Dom.safeInsertNode(c,h),e.elementIsBlock&&n.Dom.isEmpty(h)&&!n.Dom.isTag(h.firstElementChild,"br")&&h.appendChild(s.element("br")),h}},73154:function(e,t,i){"use strict";i.d(t,{wrap:function(){return a}});var n=i(27795),o=i(7909),r=i(97110),s=i(83335);function a(e,t,i){var a,u,c;let d=(a=e,u=t,c=i,a.elementIsBlock?n.Dom.up(u,e=>n.Dom.isBlock(e)&&!n.Dom.isTag(e,l),c.editor)||(0,s.wrapUnwrappedText)(a,u,c):((0,o.attr)(u,"size",null),u));return e.elementIsList?(0,r.wrapList)(e,d,i):n.Dom.replace(d,e.element,i.createInside,!0)}let l=new Set(["td","th","tr","tbody","table","li","ul","ol"])},96127:function(e,t,i){"use strict";i.d(t,{ApplyStyle:function(){return s}});var n=i(51640),o=i(98394),r=i(78462);function s(e,t){var i;let{s:s,editor:a}=e;null==(i=a.firstChild)||i.normalize();let l=s.fakes(),u=e.s.wrapInTagGen(l),c=u.next();if(c.done)return;let d={collapsed:s.isCollapsed(),mode:o.INITIAL,element:c.value,next:r.states.START,jodit:e,style:t};for(;c&&!c.done;){let e=new n.FiniteStateMachine(r.states.START,r.transactions);for(d.element=c.value;e.getState()!==r.states.END;)d=e.dispatch("exec",d);c=u.next()}s.restoreFakes(l)}},84578:function(e,t,i){"use strict";i.d(t,{CommitStyle:function(){return l}});var n=i(25045),o=i(81937),r=i(57821),s=i(98394),a=i(96127);class l{isApplied(e,t){let i=this.__applyMap.get(e);return!!i&&i[t]}setApplied(e,t){var i;let n=null!=(i=this.__applyMap.get(e))?i:{};n[t]=!0,this.__applyMap.set(e,n)}get elementIsList(){return!!(this.options.element&&o.LIST_TAGS.has(this.options.element))}get element(){return this.options.element||this.defaultTag}get elementIsBlock(){return!!(this.options.element&&o.IS_BLOCK.test(this.options.element))}get isElementCommit(){return!!(this.options.element&&this.options.element!==this.options.defaultTag)}get defaultTag(){return this.options.defaultTag?this.options.defaultTag:this.elementIsBlock?"p":"span"}get elementIsDefault(){return this.element===this.defaultTag}apply(e){let{hooks:t}=this.options,i=t?Object.keys(t):[];try{i.forEach(i=>{e.e.on((0,r.camelCase)(s._PREFIX+"_"+i),t[i])}),(0,a.ApplyStyle)(e,this)}finally{i.forEach(i=>{e.e.off((0,r.camelCase)(s._PREFIX+"_"+i),t[i])}),this.__applyMap=new WeakMap}e.synchronizeValues(),e.e.fire("afterCommitStyle",this)}constructor(e){(0,n._)(this,"options",void 0),(0,n._)(this,"__applyMap",void 0),this.options=e,this.__applyMap=new WeakMap}}},98394:function(e,t,i){"use strict";i.d(t,{CHANGE:function(){return r},INITIAL:function(){return a},REPLACE:function(){return l},UNSET:function(){return s},UNWRAP:function(){return o},WRAP:function(){return n},_PREFIX:function(){return u}});let n="wrap",o="unwrap",r="change",s="unset",a="initial",l="replace",u="commitStyle"},78462:function(e,t,i){"use strict";i.d(t,{states:function(){return l},transactions:function(){return u}});var n=i(81937),o=i(23211),r=i(28712),s=i(51640),a=i(98394);let l={START:"START",ELEMENT:"ELEMENT",UNWRAP:"UNWRAP",UNWRAP_CHILDREN:"UNWRAP_CHILDREN",CHANGE:"CHANGE",REPLACE_DEFAULT:"REPLACE_DEFAULT",LIST:"LIST",TOGGLE_LIST:"TOGGLE_LIST",WRAP:"WRAP",EXTRACT:"EXTRACT",END:"END"},u={[l.START]:{exec(e){let{element:t,jodit:i,style:n,mode:r,collapsed:u}=e;if((0,s.isInsideInvisibleElement)(t,i.editor)||!u&&o.Dom.isEmptyContent(t))return{...e,next:l.END};let c=(0,s.getSuitParent)(n,t,i.editor)||(0,s.getSuitChild)(n,t);if(c)return{...e,next:l.ELEMENT,element:c};let d=(0,s.suitableClosest)(n,t,i.editor);return n.elementIsList&&o.Dom.isList(d)?{...e,next:l.LIST}:d?{...e,next:l.EXTRACT}:{...e,next:r!==a.UNWRAP?l.UNWRAP_CHILDREN:l.END}}},[l.LIST]:{exec(e){let{element:t,jodit:i,mode:r}=e;if(r!==a.INITIAL&&r!==a.UNWRAP&&r!==a.REPLACE)return{...e,next:l.END};let s=o.Dom.closest(t,"li",i.editor);return s&&o.Dom.closest(t,n.LIST_TAGS,i.editor)?{...e,element:s,next:l.TOGGLE_LIST}:{...e,next:l.END}}},[l.TOGGLE_LIST]:{exec(e){return{...e,mode:(0,s.toggleOrderedList)(e.style,e.element,e.jodit,e.mode),next:l.END}}},[l.EXTRACT]:{exec(e){var t;let{element:i,jodit:n,style:a}=e,u=(0,s.suitableClosest)(a,i,n.editor);return((0,r.assert)(u,"This place should have an element"),!a.elementIsBlock&&(null==(t=a.options.attributes)?void 0:t.style)&&o.Dom.isBlock(u))?{...e,next:l.WRAP}:(a.elementIsBlock||(0,s.extractSelectedPart)(u,i,n),{...e,element:u,next:l.ELEMENT})}},[l.UNWRAP_CHILDREN]:{exec(e){let{element:t,style:i}=e;return(0,s.unwrapChildren)(i,t)?{...e,mode:a.UNWRAP,next:l.END}:{...e,next:l.WRAP}}},[l.WRAP]:{exec(e){let{element:t,jodit:i,style:n}=e,o=(0,s.wrap)(n,t,i);return{...e,next:n.elementIsList?l.END:l.CHANGE,mode:a.WRAP,element:o}}},[l.ELEMENT]:{exec(e){let{style:t,element:i,jodit:n}=e;return(0,s.toggleAttributes)(t,i,n,a.INITIAL,!0)!==a.INITIAL?{...e,next:l.CHANGE}:o.Dom.isTag(i,t.element)?{...e,next:l.UNWRAP}:{...e,next:l.END}}},[l.CHANGE]:{exec(e){let{style:t,element:i,jodit:n,mode:r}=e,u=(0,s.toggleAttributes)(t,i,n,e.mode);return r!==a.WRAP&&u===a.UNSET&&!i.attributes.length&&o.Dom.isTag(i,t.element)?{...e,next:l.UNWRAP}:{...e,mode:u,next:l.END}}},[l.UNWRAP]:{exec(e){return e.element.attributes.length&&o.Dom.isTag(e.element,e.style.element)?{...e,next:l.REPLACE_DEFAULT}:(o.Dom.unwrap(e.element),{...e,mode:a.UNWRAP,next:l.END})}},[l.REPLACE_DEFAULT]:{exec(e){return o.Dom.replace(e.element,e.style.defaultTag,e.jodit.createInside,!0),{...e,mode:a.REPLACE,next:l.END}}},[l.END]:{exec(e){return e}}}},8006:function(e,t,i){"use strict";i.d(t,{AsyncStorage:function(){return u}});var n=i(25045),o=i(57821),r=i(91162),s=i(59807),a=i(9505),l=i(24475);class u{async set(e,t){let i=await this.provider;return await i.set((0,o.camelCase)(this.prefix+e),t),this}async delete(e){let t=await this.provider;return await t.delete((0,o.camelCase)(this.prefix+e)),this}async get(e){return(await this.provider).get((0,o.camelCase)(this.prefix+e))}async exists(e){return(await this.provider).exists((0,o.camelCase)(this.prefix+e))}async clear(){let e=await this.provider;return await e.clear(),this}async close(){let e=await this.provider;"close"in e&&"function"==typeof e.close&&await e.close()}static makeStorage(e=!1,t){let i;return"localStorage"===e||"sessionStorage"===e?(0,s.canUsePersistentStorage)(e)&&(i=new s.LocalStorageProvider(l.StorageKey+(t||""),e)):("indexedDB"===e||!0===e)&&(i=(0,r.canUseIndexedDB)().then(e=>e?new r.IndexedDBProvider(l.StorageKey+(t||""),"keyValueStore"):new a.MemoryStorageProvider)),i||(i=new a.MemoryStorageProvider),new u(Promise.resolve(i),t)}constructor(e,t){(0,n._)(this,"provider",void 0),(0,n._)(this,"prefix",void 0),this.provider=e,this.prefix=l.StorageKey,t&&(this.prefix+=t)}}},91162:function(e,t,i){"use strict";i.d(t,{IndexedDBProvider:function(){return r},canUseIndexedDB:function(){return l},clearUseIndexedDBCache:function(){return a}});var n=i(25045),o=i(81937);class r{getDB(){return this.dbPromise||(this.dbPromise=new Promise((e,t)=>{let i=indexedDB.open(this.dbName,this.DB_VERSION);i.onerror=()=>{t(i.error)},i.onsuccess=()=>{e(i.result)},i.onupgradeneeded=e=>{let t=e.target.result;t.objectStoreNames.contains(this.storeName)||t.createObjectStore(this.storeName)}})),this.dbPromise}async performTransaction(e,t){try{let i=(await this.getDB()).transaction([this.storeName],e).objectStore(this.storeName),n=t(i);return new Promise((e,t)=>{n.onsuccess=()=>{e(n.result)},n.onerror=()=>{t(n.error)}})}catch(e){return Promise.reject(e)}}async set(e,t){try{await this.performTransaction("readwrite",i=>i.put(t,e))}catch(e){o.IS_PROD}return this}async delete(e){try{await this.performTransaction("readwrite",t=>t.delete(e))}catch(e){}return this}async get(e){try{return await this.performTransaction("readonly",t=>t.get(e))}catch(e){return}}async exists(e){try{let t=await this.performTransaction("readonly",t=>t.get(e));return void 0!==t}catch(e){return!1}}async clear(){try{await this.performTransaction("readwrite",e=>e.clear())}catch(e){}return this}async close(){if(this.dbPromise){try{(await this.dbPromise).close()}catch(e){}this.dbPromise=null}}async keys(){try{let e=await this.performTransaction("readonly",e=>e.getAllKeys());return e&&"object"==typeof e&&"then"in e&&(e=await e),e.map(e=>String(e))}catch(e){return[]}}async values(){try{let e=await this.performTransaction("readonly",e=>e.getAll());return e&&"object"==typeof e&&"then"in e&&(e=await e),e}catch(e){return[]}}async entries(){try{let[e,t]=await Promise.all([this.keys(),this.values()]);return e.map((e,i)=>[e,t[i]])}catch(e){return[]}}constructor(e="JoditDB",t="keyValueStore"){(0,n._)(this,"dbName",void 0),(0,n._)(this,"dbPromise",void 0),(0,n._)(this,"DB_VERSION",void 0),(0,n._)(this,"storeName",void 0),this.dbName=e,this.dbPromise=null,this.DB_VERSION=1,this.storeName=t}}let s=null;function a(){s=null}async function l(){if(null!=s)return s;try{if("u"<typeof indexedDB)return s=!1,!1;let e="___Jodit___"+Math.random().toString(),t=indexedDB.open(e);return s=await new Promise(i=>{t.onerror=()=>{i(!1)},t.onsuccess=()=>{indexedDB.deleteDatabase(e),i(!0)}})}catch(e){return s=!1,!1}}},59807:function(e,t,i){"use strict";i.d(t,{LocalStorageProvider:function(){return r},canUsePersistentStorage:function(){return o}});var n=i(25045);let o=(e="localStorage")=>{let t=new Map;if(t.has(e))return t.get(e);let i="___Jodit___"+Math.random().toString(),n="sessionStorage"===e?sessionStorage:localStorage;try{n.setItem(i,"1");let o="1"===n.getItem(i);return n.removeItem(i),t.set(e,o),o}catch(e){}return t.set(e,!1),!1};class r{get storage(){return"sessionStorage"===this.strategy?sessionStorage:localStorage}set(e,t){try{let i=this.storage.getItem(this.rootKey),n=i?JSON.parse(i):{};n[e]=t,this.storage.setItem(this.rootKey,JSON.stringify(n))}catch(e){}return this}delete(e){try{this.storage.removeItem(this.rootKey)}catch(e){}return this}get(e){try{let t=this.storage.getItem(this.rootKey),i=t?JSON.parse(t):{};return void 0!==i[e]?i[e]:void 0}catch(e){}}exists(e){return null!=this.get(e)}clear(){try{this.storage.removeItem(this.rootKey)}catch(e){}return this}constructor(e,t="localStorage"){(0,n._)(this,"rootKey",void 0),(0,n._)(this,"strategy",void 0),this.rootKey=e,this.strategy=t}}},9505:function(e,t,i){"use strict";i.d(t,{MemoryStorageProvider:function(){return o}});var n=i(25045);class o{set(e,t){return this.data.set(e,t),this}delete(e){return this.data.delete(e),this}get(e){return this.data.get(e)}exists(e){return this.data.has(e)}clear(){return this.data.clear(),this}constructor(){(0,n._)(this,"data",new Map)}}},25222:function(e,t,i){"use strict";i.d(t,{AsyncStorage:function(){return n.AsyncStorage},IndexedDBProvider:function(){return o.IndexedDBProvider},LocalStorageProvider:function(){return r.LocalStorageProvider},MemoryStorageProvider:function(){return s.MemoryStorageProvider},Storage:function(){return a.Storage},StorageKey:function(){return a.StorageKey},canUseIndexedDB:function(){return o.canUseIndexedDB},canUsePersistentStorage:function(){return r.canUsePersistentStorage},clearUseIndexedDBCache:function(){return o.clearUseIndexedDBCache}});var n=i(8006),o=i(91162),r=i(59807),s=i(9505),a=i(24475)},24475:function(e,t,i){"use strict";i.d(t,{Storage:function(){return l},StorageKey:function(){return a}});var n=i(25045),o=i(57821),r=i(59807),s=i(9505);let a="Jodit_";class l{set(e,t){return this.provider.set((0,o.camelCase)(this.prefix+e),t),this}delete(e){return this.provider.delete((0,o.camelCase)(this.prefix+e)),this}get(e){return this.provider.get((0,o.camelCase)(this.prefix+e))}exists(e){return this.provider.exists((0,o.camelCase)(this.prefix+e))}clear(){return this.provider.clear(),this}static makeStorage(e=!1,t){let i;return"localStorage"===e||"sessionStorage"===e?(0,r.canUsePersistentStorage)(e)&&(i=new r.LocalStorageProvider(a+(t||""),e)):!0===e&&(0,r.canUsePersistentStorage)("localStorage")&&(i=new r.LocalStorageProvider(a+(t||""))),i||(i=new s.MemoryStorageProvider),new l(i,t)}constructor(e,t){(0,n._)(this,"provider",void 0),(0,n._)(this,"prefix",void 0),this.provider=e,this.prefix=a,t&&(this.prefix+=t)}}},80512:function(e,t,i){"use strict";i.d(t,{Dlgs:function(){return a}});var n=i(28077),o=i(28686),r=i(71125),s=i(37333);class a{dlg(e){let t=(0,n.getPopupViewRoot)(this.o,this.container,this.od.body),i=new s.Dialog({language:this.o.language,shadowRoot:this.o.shadowRoot,popupRoot:t,ownerWindow:this.o.ownerWindow,defaultTimeout:this.o.defaultTimeout,direction:this.o.direction,theme:this.o.theme,globalFullSize:this.o.globalFullSize,...e});return(0,r.markOwner)(this,i.container),i.parent=this,i.bindDestruct(this)}confirm(e,t,i){return e=l(e,this),t=l(t,this),s.Confirm.call(this.dlg({closeOnClickOverlay:!0}),e,t,i)}prompt(e,t,i,n,o){return e=l(e,this),t=l(t,this),n=l(n,this),s.Prompt.call(this.dlg({closeOnClickOverlay:!0}),e,t,i,n,o)}alert(e,t,i,n){return e=l(e,this),t=l(t,this),s.Alert.call(this.dlg({closeOnClickOverlay:!0}),e,t,i,n)}}function l(e,t){return(0,o.isString)(e)&&!(0,o.isHTML)(e)&&(e=t.i18n(e)),e}},23183:function(e,t,i){"use strict";i.d(t,{Elms:function(){return o}});var n=i(88475);class o{getElm(e){return this.container.querySelector(`.${this.getFullElName(e)}`)}getElms(e){return(0,n.toArray)(this.container.querySelectorAll(`.${this.getFullElName(e)}`))}}},81987:function(e,t,i){"use strict";i.d(t,{Mods:function(){return o}});var n=i(18303);class o{afterSetMod(e,t){}setMod(e,t,i){e=e.toLowerCase();let o=this.mods[e];if(o===t)return this;let r=`${this.componentName}_${e}_`,s=(i||this.container).classList;return null!=o&&s.remove(`${r}${o.toString().toLowerCase()}`),(0,n.isVoid)(t)||""===t||s.add(`${r}${t.toString().toLowerCase()}`),this.mods[e]=t,this.afterSetMod(e,t),this}getMod(e){var t;return null!=(t=this.mods[e])?t:null}}},53681:function(e,t,i){"use strict";i.d(t,{Button:function(){return _},UIButton:function(){return v},UIButtonState:function(){return g}});var n=i(25045),o=i(31635),r=i(69364),s=i(51676),a=i(91672),l=i(68616),u=i(23211),c=i(91565),d=i(85932),h=i(28712),p=i(7909),f=i(96007),m=i(29434);let g=()=>({size:"middle",type:"button",role:"button",name:"",value:"",variant:"initial",disabled:!1,activated:!1,icon:{name:"empty",fill:"",iconURL:"",scale:void 0},tooltip:"",text:"",tabIndex:void 0});class v extends f.UIElement{className(){return"UIButton"}setState(e){return Object.assign(this.state,e),this}get text(){let e=this.getElm("text");return(0,h.assert)(e,"Text element not found"),e}get icon(){let e=this.getElm("icon");return(0,h.assert)(e,"Icon element not found"),e}onChangeSize(){this.setMod("size",this.state.size)}onChangeType(){(0,p.attr)(this.container,"type",this.state.type)}onChangeRole(){(0,p.attr)(this.container,"role",this.state.role)}updateSize(){let e=(0,a.getComponentClass)("UIList"),t=this.closest(e);if(t){this.state.size=t.buttonSize;return}}onChangeStatus(){this.setMod("variant",this.state.variant)}onChangeText(){this.text.textContent=this.jodit.i18n(this.state.text),this.updateAriaLabel()}onChangeTextSetMode(){this.setMod("text-icons",!!this.state.text.trim().length)}onChangeDisabled(){(0,p.attr)(this.container,"disabled",this.state.disabled||null)}onChangeActivated(){(0,p.attr)(this.container,"aria-pressed",this.state.activated)}onChangeName(){this.container.classList.add(`${this.componentName}_${this.clearName(this.state.name)}`),this.name=this.state.name,(0,p.attr)(this.container,"data-ref",this.state.name),(0,p.attr)(this.container,"ref",this.state.name)}onChangeTooltip(){let e=this.state.tooltip?this.jodit.i18n(this.state.tooltip):null;this.get("j.o.useNativeTooltip")&&(0,p.attr)(this.container,"title",e),(0,p.attr)(this.container,"aria-label",e),this.updateAriaLabel()}updateAriaLabel(){let e=this.state.text.trim().length>0,t=this.state.tooltip?this.jodit.i18n(this.state.tooltip):null;(0,p.attr)(this.container,"aria-label",t),(0,p.attr)(this.button,"aria-label",e?null:t)}onChangeTabIndex(){(0,p.attr)(this.container,"tabindex",this.state.tabIndex)}onChangeIcon(){let e=this.get("j.o.textIcons");if(!0===e||(0,c.isFunction)(e)&&e(this.state.name))return;u.Dom.detach(this.icon);let t=m.Icon.makeIcon(this.j,this.state.icon);t&&this.icon.appendChild(t)}focus(){this.container.focus()}isFocused(){let{activeElement:e}=this.od;return!!(e&&u.Dom.isOrContains(this.container,e))}createContainer(){let e=this.componentName,t=this.j.c.element("button",{class:e,type:"button",role:"button",ariaPressed:!1}),i=this.j.c.span(e+"__icon"),n=this.j.c.span(e+"__text");return t.appendChild(i),t.appendChild(n),t}destruct(){return this.j.e.off(this),this.j.e.off(this.container),super.destruct()}onAction(e){return this.actionHandlers.push(e),this}__onActionFire(e){e.buffer={actionTrigger:this},this.actionHandlers.forEach(t=>t.call(this,e)),this.j.e.fire(this,"click",e)}constructor(e,t){super(e),(0,n._)(this,"isButton",!0),(0,n._)(this,"state",g()),(0,n._)(this,"button",void 0),(0,n._)(this,"actionHandlers",[]),this.button=this.container,this.updateSize(),this.onChangeSize(),this.onChangeStatus(),t&&this.hookStatus(r.STATUSES.ready,()=>{this.setState(t)})}}function _(e,t,i,n){let o=new v(e);return o.state.tabIndex=e.o.allowTabNavigation?0:-1,(0,d.isString)(t)?(o.state.icon.name=t,o.state.name=t,n&&(o.state.variant=n),i&&(o.state.text=i)):o.setState(t),o}(0,o.__decorate)([s.cache],v.prototype,"text",null),(0,o.__decorate)([s.cache],v.prototype,"icon",null),(0,o.__decorate)([(0,l.watch)("state.size",{immediately:!1})],v.prototype,"onChangeSize",null),(0,o.__decorate)([(0,l.watch)("state.type",{immediately:!1})],v.prototype,"onChangeType",null),(0,o.__decorate)([(0,l.watch)("state.role",{immediately:!1})],v.prototype,"onChangeRole",null),(0,o.__decorate)([(0,l.watch)("parentElement")],v.prototype,"updateSize",null),(0,o.__decorate)([(0,l.watch)("state.variant",{immediately:!1})],v.prototype,"onChangeStatus",null),(0,o.__decorate)([(0,l.watch)("state.text",{immediately:!1})],v.prototype,"onChangeText",null),(0,o.__decorate)([(0,l.watch)("state.text",{immediately:!1})],v.prototype,"onChangeTextSetMode",null),(0,o.__decorate)([(0,l.watch)("state.disabled")],v.prototype,"onChangeDisabled",null),(0,o.__decorate)([(0,l.watch)("state.activated")],v.prototype,"onChangeActivated",null),(0,o.__decorate)([(0,l.watch)("state.name",{immediately:!1})],v.prototype,"onChangeName",null),(0,o.__decorate)([(0,l.watch)("state.tooltip",{immediately:!1})],v.prototype,"onChangeTooltip",null),(0,o.__decorate)([(0,l.watch)("state.tabIndex",{immediately:!1})],v.prototype,"onChangeTabIndex",null),(0,o.__decorate)([(0,l.watch)("state.icon",{immediately:!1})],v.prototype,"onChangeIcon",null),(0,o.__decorate)([s.cacheHTML],v.prototype,"createContainer",null),(0,o.__decorate)([(0,l.watch)("button:click")],v.prototype,"__onActionFire",null),v=(0,o.__decorate)([a.component],v)},15367:function(e,t,i){"use strict";i.d(t,{UIButtonGroup:function(){return u}});var n=i(25045),o=i(31635),r=i(91672),s=i(28712),a=i(53681),l=i(63468);class u extends l.UIGroup{className(){return"UIButtonGroup"}render(e){return`<div>
8
+ !function(e,t){if("object"==typeof exports&&"object"==typeof module)module.exports=t();else if("function"==typeof define&&define.amd)define([],t);else{var i=t();for(var n in i)("object"==typeof exports?exports:e)[n]=i[n]}}(self,function(){return function(){var e,t,i,n,o={5266:function(e,t,i){"use strict";i.d(t,{Config:function(){return s}});var n=i(25045),o=i(81937);let r={};class s{static get defaultOptions(){return s.__defaultOptions||(s.__defaultOptions=new s),s.__defaultOptions}constructor(){(0,n._)(this,"cache",!0),(0,n._)(this,"defaultTimeout",100),(0,n._)(this,"namespace",""),(0,n._)(this,"safeMode",!1),(0,n._)(this,"width","auto"),(0,n._)(this,"height","auto"),(0,n._)(this,"safePluginsList",["about","enter","backspace","size","bold","hotkeys"]),(0,n._)(this,"commandToHotkeys",void 0),(0,n._)(this,"license",""),(0,n._)(this,"preset","custom"),(0,n._)(this,"presets",{inline:{inline:!0,toolbar:!1,toolbarInline:!0,toolbarInlineForSelection:!0,showXPathInStatusbar:!1,showCharsCounter:!1,showWordsCounter:!1,showPlaceholder:!1}}),(0,n._)(this,"ownerDocument",o.globalDocument),(0,n._)(this,"ownerWindow",o.globalWindow),(0,n._)(this,"shadowRoot",null),(0,n._)(this,"zIndex",0),(0,n._)(this,"readonly",!1),(0,n._)(this,"disabled",!1),(0,n._)(this,"activeButtonsInReadOnly",["source","fullsize","print","about","dots","selectall"]),(0,n._)(this,"allowCommandsInReadOnly",["selectall","preview","print"]),(0,n._)(this,"toolbarButtonSize","middle"),(0,n._)(this,"allowTabNavigation",!1),(0,n._)(this,"inline",!1),(0,n._)(this,"theme","default"),(0,n._)(this,"saveModeInStorage",!1),(0,n._)(this,"editorClassName",!1),(0,n._)(this,"className",!1),(0,n._)(this,"style",!1),(0,n._)(this,"containerStyle",!1),(0,n._)(this,"styleValues",{}),(0,n._)(this,"triggerChangeEvent",!0),(0,n._)(this,"direction",""),(0,n._)(this,"language","auto"),(0,n._)(this,"debugLanguage",!1),(0,n._)(this,"i18n",!1),(0,n._)(this,"tabIndex",-1),(0,n._)(this,"toolbar",!0),(0,n._)(this,"statusbar",!0),(0,n._)(this,"showTooltip",!0),(0,n._)(this,"showTooltipDelay",200),(0,n._)(this,"useNativeTooltip",!1),(0,n._)(this,"defaultActionOnPaste",o.INSERT_AS_HTML),(0,n._)(this,"enter",o.PARAGRAPH),(0,n._)(this,"iframe",!1),(0,n._)(this,"editHTMLDocumentMode",!1),(0,n._)(this,"enterBlock","br"!==this.enter?this.enter:o.PARAGRAPH),(0,n._)(this,"defaultMode",o.MODE_WYSIWYG),(0,n._)(this,"useSplitMode",!1),(0,n._)(this,"colors",{greyscale:["#000000","#434343","#666666","#999999","#B7B7B7","#CCCCCC","#D9D9D9","#EFEFEF","#F3F3F3","#FFFFFF"],palette:["#980000","#FF0000","#FF9900","#FFFF00","#00F0F0","#00FFFF","#4A86E8","#0000FF","#9900FF","#FF00FF"],full:["#E6B8AF","#F4CCCC","#FCE5CD","#FFF2CC","#D9EAD3","#D0E0E3","#C9DAF8","#CFE2F3","#D9D2E9","#EAD1DC","#DD7E6B","#EA9999","#F9CB9C","#FFE599","#B6D7A8","#A2C4C9","#A4C2F4","#9FC5E8","#B4A7D6","#D5A6BD","#CC4125","#E06666","#F6B26B","#FFD966","#93C47D","#76A5AF","#6D9EEB","#6FA8DC","#8E7CC3","#C27BA0","#A61C00","#CC0000","#E69138","#F1C232","#6AA84F","#45818E","#3C78D8","#3D85C6","#674EA7","#A64D79","#85200C","#990000","#B45F06","#BF9000","#38761D","#134F5C","#1155CC","#0B5394","#351C75","#733554","#5B0F00","#660000","#783F04","#7F6000","#274E13","#0C343D","#1C4587","#073763","#20124D","#4C1130"]}),(0,n._)(this,"colorPickerDefaultTab","background"),(0,n._)(this,"imageDefaultWidth",300),(0,n._)(this,"removeButtons",[]),(0,n._)(this,"disablePlugins",[]),(0,n._)(this,"extraPlugins",[]),(0,n._)(this,"basePath",void 0),(0,n._)(this,"extraButtons",[]),(0,n._)(this,"extraIcons",{}),(0,n._)(this,"createAttributes",{table:{style:"border-collapse:collapse;width: 100%;"}}),(0,n._)(this,"sizeLG",900),(0,n._)(this,"sizeMD",700),(0,n._)(this,"sizeSM",400),(0,n._)(this,"buttons",[{group:"font-style",buttons:[]},{group:"list",buttons:[]},{group:"font",buttons:[]},"---",{group:"script",buttons:[]},{group:"media",buttons:[]},"\n",{group:"state",buttons:[]},{group:"clipboard",buttons:[]},{group:"insert",buttons:[]},{group:"indent",buttons:[]},{group:"color",buttons:[]},{group:"form",buttons:[]},"---",{group:"history",buttons:[]},{group:"search",buttons:[]},{group:"source",buttons:[]},{group:"other",buttons:[]},{group:"info",buttons:[]}]),(0,n._)(this,"controls",void 0),(0,n._)(this,"events",{}),(0,n._)(this,"textIcons",!1),(0,n._)(this,"popupRoot",null),(0,n._)(this,"showBrowserColorPicker",!0),Object.assign(this,r)}}(0,n._)(s,"__defaultOptions",void 0),r=s.prototype,s.prototype.controls={}},24735:function(e,t,i){"use strict";i.d(t,{Async:function(){return m}});var n=i(25045),o=i(81937),r=i(61077),s=i(72068),a=i(91565),l=i(72412),u=i(62101),c=i(52100),d=i(85932),h=i(18303),p=i(28712),f=i(14228);class m{delay(e){return this.promise(t=>this.setTimeout(t,e))}setTimeout(e,t,...i){if(this.isDestructed)return 0;let n={};(0,h.isVoid)(t)&&(t=0),(0,l.isNumber)(t)||(t=(n=t).timeout||0),n.label&&this.clearLabel(n.label);let o=(0,r.setTimeout)(e,t,...i),s=n.label||o;return this.timers.set(s,o),this.__callbacks.set(s,e),o}updateTimeout(e,t){if((0,p.assert)(e&&this.timers.has(e),"Label does not exist"),!e||!this.timers.has(e))return null;let i=this.__callbacks.get(e);return(0,p.assert)((0,a.isFunction)(i),"Callback is not a function"),this.setTimeout(i,{label:e,timeout:t})}clearLabel(e){e&&this.timers.has(e)&&((0,r.clearTimeout)(this.timers.get(e)),this.timers.delete(e),this.__callbacks.delete(e))}clearTimeout(e){if((0,d.isString)(e))return this.clearLabel(e);(0,r.clearTimeout)(e),this.timers.delete(e),this.__callbacks.delete(e)}debounce(e,t,i=!1){let n=0,o=!1,l=[],d=(...t)=>{if(!o){n=0;let i=e(...t);if(o=!0,l.length){let e=()=>{l.forEach(e=>e()),l.length=0};(0,c.isPromise)(i)?i.finally(e):e()}}},h=(...s)=>{o=!1,t?(!n&&i&&d(...s),(0,r.clearTimeout)(n),n=this.setTimeout(()=>d(...s),(0,a.isFunction)(t)?t():t),this.timers.set(e,n)):d(...s)};return(0,u.isPlainObject)(t)&&t.promisify?(...e)=>{let t=this.promise(e=>{l.push(e)}).catch(e=>{if((0,s.isAbortError)(e))return null;throw e});return h(...e),t}:h}microDebounce(e,t=!1){let i,n=!1,o=!0;return(...r)=>{if(i=r,n){o=!0;return}o=!0,t&&(o=!1,e(...i)),n=!0,this.__queueMicrotaskNative(()=>{n=!1,!this.isDestructed&&o&&e(...i)})}}throttle(e,t,i=!1){let n=null,o,r,s;return(...i)=>{(o=!0,s=i,t)?n||(r=()=>{o?(e(...s),o=!1,n=this.setTimeout(r,(0,a.isFunction)(t)?t():t),this.timers.set(r,n)):n=null})():e(...s)}}promise(e){let t=()=>{},i=new Promise((i,n)=>{t=()=>n((0,f.abort)("Abort async")),this.promisesRejections.add(t),e(i,n)});return!i.finally&&"u">typeof process&&!o.IS_ES_NEXT&&(i.finally=e=>(i.then(e).catch(e),i)),i.finally(()=>{this.promisesRejections.delete(t)}).catch(()=>null),i.rejectCallback=t,i}promiseState(e){if(e.status)return e.status;if(!Promise.race)return new Promise(t=>{e.then(e=>(t("fulfilled"),e),e=>{throw t("rejected"),e}),this.setTimeout(()=>{t("pending")},100)});let t={};return Promise.race([e,t]).then(e=>e===t?"pending":"fulfilled",()=>"rejected")}requestIdleCallback(e,t={timeout:100}){let i=this.__requestIdleCallbackNative(e,t);return this.__requestsIdle.add(i),i}requestIdlePromise(e){return this.promise(t=>{let i=this.requestIdleCallback(()=>t(i),e)})}schedulerPostTask(e,t={delay:0,priority:"user-visible"}){let i=new AbortController;if(t.signal&&t.signal.addEventListener("abort",()=>i.abort()),this.__controllers.add(i),void 0!==globalThis.scheduler){let n=globalThis.scheduler.postTask(e,{...t,signal:i.signal});return n.finally(()=>{this.__controllers.delete(i)}).catch(()=>null),n}return this.promise((n,o)=>{let r=this.setTimeout(()=>{try{n(e())}catch(e){o(e)}this.__controllers.delete(i)},t.delay||1);i.signal.addEventListener("abort",()=>{this.clearTimeout(r),this.__controllers.delete(i),o((0,f.abort)())})})}schedulerYield(){return this.schedulerPostTask(()=>{},{priority:"user-visible"})}cancelIdleCallback(e){return this.__requestsIdle.delete(e),this.__cancelIdleCallbackNative(e)}requestAnimationFrame(e){let t=requestAnimationFrame(e);return this.__requestsRaf.add(t),t}cancelAnimationFrame(e){this.__requestsRaf.delete(e),cancelAnimationFrame(e)}clear(){this.__requestsIdle.forEach(e=>this.cancelIdleCallback(e)),this.__requestsRaf.forEach(e=>this.cancelAnimationFrame(e)),this.__controllers.forEach(e=>e.abort()),this.timers.forEach(e=>(0,r.clearTimeout)(this.timers.get(e))),this.timers.clear(),this.promisesRejections.forEach(e=>e()),this.promisesRejections.clear()}destruct(){this.clear(),this.isDestructed=!0}constructor(){var e,t,i,o,r,s;(0,n._)(this,"timers",new Map),(0,n._)(this,"__callbacks",new Map),(0,n._)(this,"__queueMicrotaskNative",null!=(e=null==(o=queueMicrotask)?void 0:o.bind(window))?e:Promise.resolve().then.bind(Promise.resolve())),(0,n._)(this,"promisesRejections",new Set),(0,n._)(this,"__requestsIdle",new Set),(0,n._)(this,"__controllers",new Set),(0,n._)(this,"__requestsRaf",new Set),(0,n._)(this,"__requestIdleCallbackNative",null!=(t=null==(r=window.requestIdleCallback)?void 0:r.bind(window))?t:(e,t)=>{var i;let n=Date.now();return this.setTimeout(()=>{e({didTimeout:!1,timeRemaining:()=>Math.max(0,50-(Date.now()-n))})},null!=(i=null==t?void 0:t.timeout)?i:1)}),(0,n._)(this,"__cancelIdleCallbackNative",null!=(i=null==(s=window.cancelIdleCallback)?void 0:s.bind(window))?i:e=>{this.clearTimeout(e)}),(0,n._)(this,"isDestructed",!1)}}},91231:function(e,t,i){"use strict";i.d(t,{Async:function(){return n.Async}});var n=i(24735)},80251:function(e,t,i){"use strict";i.d(t,{Component:function(){return u}});var n=i(25045),o=i(91231),r=i(69364),s=i(28077),a=i(65946);let l=new Map;class u{get componentName(){return this.__componentName||(this.__componentName="jodit-"+(0,a.kebabCase)(((0,a.isFunction)(this.className)?this.className():"")||(0,a.getClassName)(this))),this.__componentName}getFullElName(e,t,i){let n=[this.componentName];return e&&(e=e.replace(/[^a-z0-9-]/gi,"-"),n.push(`__${e}`)),t&&(n.push("_",t),n.push("_",(0,a.isVoid)(i)?"true":i.toString())),n.join("")}get ownerDocument(){return this.ow.document}get od(){return this.ownerDocument}get ow(){return this.ownerWindow}get(e,t){return(0,a.get)(e,t||this)}get isReady(){return this.componentStatus===r.STATUSES.ready}get isDestructed(){return this.componentStatus===r.STATUSES.destructed}get isInDestruct(){return r.STATUSES.beforeDestruct===this.componentStatus||r.STATUSES.destructed===this.componentStatus}bindDestruct(e){return e.hookStatus(r.STATUSES.beforeDestruct,()=>!this.isInDestruct&&this.destruct()),this}destruct(){this.setStatus(r.STATUSES.destructed),this.async&&(this.async.destruct(),this.async=void 0),l.get(this)&&l.delete(this),this.ownerWindow=void 0}get componentStatus(){return this.__componentStatus}set componentStatus(e){this.setStatus(e)}setStatus(e){return this.setStatusComponent(e,this)}setStatusComponent(e,t){if(e===this.__componentStatus)return;t===this&&(this.__componentStatus=e);let i=Object.getPrototypeOf(this);i&&(0,a.isFunction)(i.setStatusComponent)&&i.setStatusComponent(e,t);let n=l.get(this),o=null==n?void 0:n[e];o&&o.length&&o.forEach(e=>e(t))}hookStatus(e,t){let i=l.get(this);i||(i={},l.set(this,i)),i[e]||(i[e]=[]),i[e].push(t)}static isInstanceOf(e,t){return e instanceof t}constructor(){(0,n._)(this,"__componentName",void 0),(0,n._)(this,"async",new o.Async),(0,n._)(this,"uid",void 0),(0,n._)(this,"ownerWindow",window),(0,n._)(this,"__componentStatus",r.STATUSES.beforeInit),this.uid="jodit-uid-"+(0,s.uniqueUid)()}}(0,n._)(u,"STATUSES",r.STATUSES)},16964:function(e,t,i){"use strict";i.d(t,{Component:function(){return n.Component},STATUSES:function(){return o.STATUSES},ViewComponent:function(){return r.ViewComponent}});var n=i(80251),o=i(69364),r=i(59609)},69364:function(e,t,i){"use strict";i.d(t,{STATUSES:function(){return n}});let n={beforeInit:"beforeInit",ready:"ready",beforeDestruct:"beforeDestruct",destructed:"destructed"}},59609:function(e,t,i){"use strict";i.d(t,{ViewComponent:function(){return r}});var n=i(25045),o=i(80251);class r extends o.Component{get j(){return this.jodit}get defaultTimeout(){return this.j.defaultTimeout}i18n(e,...t){return this.j.i18n(e,...t)}setParentView(e){return this.jodit=e,e.components.add(this),this}destruct(){return this.j.components.delete(this),super.destruct()}constructor(e){super(),(0,n._)(this,"jodit",void 0),this.setParentView(e)}}},81937:function(e,t,i){"use strict";i.r(t),i.d(t,{ACCURACY:function(){return V},APP_VERSION:function(){return n},BASE_PATH:function(){return eh},BASE_PATH_IS_MIN:function(){return ep},BR:function(){return W},CLIPBOARD_ID:function(){return eg},COMMAND_KEYS:function(){return U},EMULATE_DBLCLICK_TIMEOUT:function(){return et},ES:function(){return o},FAT_MODE:function(){return u},HOMEPAGE:function(){return c},INSEPARABLE_TAGS:function(){return T},INSERT_AS_HTML:function(){return ei},INSERT_AS_TEXT:function(){return eo},INSERT_CLEAR_HTML:function(){return en},INSERT_ONLY_TEXT:function(){return er},INVISIBLE_SPACE:function(){return p},INVISIBLE_SPACE_REG_EXP:function(){return m},INVISIBLE_SPACE_REG_EXP_END:function(){return g},INVISIBLE_SPACE_REG_EXP_START:function(){return v},IS_BLOCK:function(){return C},IS_ES_MODERN:function(){return r},IS_ES_NEXT:function(){return s},IS_IE:function(){return X},IS_INLINE:function(){return k},IS_MAC:function(){return ea},IS_PROD:function(){return a},IS_TEST:function(){return l},KEY_ALIASES:function(){return el},KEY_ALT:function(){return P},KEY_BACKSPACE:function(){return j},KEY_DELETE:function(){return F},KEY_DOWN:function(){return B},KEY_ENTER:function(){return L},KEY_ESC:function(){return A},KEY_F3:function(){return q},KEY_LEFT:function(){return M},KEY_META:function(){return D},KEY_RIGHT:function(){return R},KEY_SPACE:function(){return O},KEY_TAB:function(){return z},KEY_UP:function(){return N},LIST_TAGS:function(){return E},MARKER_CLASS:function(){return ee},MODE_SOURCE:function(){return K},MODE_SPLIT:function(){return G},MODE_WYSIWYG:function(){return Y},NBSP_SPACE:function(){return f},NEARBY:function(){return H},NO_EMPTY_TAGS:function(){return x},PARAGRAPH:function(){return $},PASSIVE_EVENTS:function(){return e_},SAFE_COUNT_CHANGE_CALL:function(){return es},SET_TEST:function(){return d},SOURCE_CONSUMER:function(){return ev},SPACE_REG_EXP:function(){return _},SPACE_REG_EXP_END:function(){return y},SPACE_REG_EXP_START:function(){return b},TEMP_ATTR:function(){return ef},TEXT_HTML:function(){return Z},TEXT_PLAIN:function(){return J},TEXT_RTF:function(){return Q},TOKENS:function(){return h},globalDocument:function(){return w},globalWindow:function(){return S},lang:function(){return em}});let n="4.12.2",o="es2018",r=!0,s=!1,a=!0,l=!1,u=!1,c="https://xdsoft.net/jodit/",d=()=>l=!0,h={},p="\uFEFF",f="\xa0",m=()=>/[\uFEFF]/g,g=()=>/[\uFEFF]+$/g,v=()=>/^[\uFEFF]+/g,_=()=>/[\s\n\t\r\uFEFF\u200b]+/g,b=()=>/^[\s\n\t\r\uFEFF\u200b]+/g,y=()=>/[\s\n\t\r\uFEFF\u200b]+$/g,S="u">typeof window?window:void 0,w="u">typeof document?document:void 0,C=/^(ADDRESS|ARTICLE|ASIDE|BLOCKQUOTE|CANVAS|DD|DFN|DIV|DL|DT|FIELDSET|FIGCAPTION|FIGURE|FOOTER|FORM|H[1-6]|HEADER|HGROUP|HR|LI|MAIN|NAV|NOSCRIPT|OUTPUT|P|PRE|RUBY|SCRIPT|STYLE|OBJECT|OL|SECTION|IFRAME|JODIT|JODIT-MEDIA|UL|TR|TD|TH|TBODY|THEAD|TFOOT|TABLE|BODY|HTML|VIDEO)$/i,k=/^(STRONG|SPAN|I|EM|B|SUP|SUB|A|U)$/i,E=new Set(["ul","ol"]),I=["img","video","svg","iframe","script","input","textarea","link","jodit","jodit-media"],T=new Set([...I,"br","hr"]),x=new Set(I),D="Meta",j="Backspace",z="Tab",L="Enter",A="Escape",P="Alt",M="ArrowLeft",N="ArrowUp",R="ArrowRight",B="ArrowDown",O="Space",F="Delete",q="F3",H=5,V=10,U=[D,j,F,N,B,R,M,L,A,q,z],W="br",$="p",Y=1,K=2,G=3,X="u">typeof navigator&&(-1!==navigator.userAgent.indexOf("MSIE")||/rv:11.0/i.test(navigator.userAgent)),J=X?"text":"text/plain",Z=X?"html":"text/html",Q=X?"rtf":"text/rtf",ee="jodit-selection_marker",et=300,ei="insert_as_html",en="insert_clear_html",eo="insert_as_text",er="insert_only_text",es=10,ea=void 0!==S&&/Mac|iPod|iPhone|iPad/.test(S.navigator.platform),el={add:"+",break:"pause",cmd:"meta",command:"meta",ctl:"control",ctrl:"control",del:"delete",down:"arrowdown",esc:"escape",ins:"insert",left:"arrowleft",mod:ea?"meta":"control",opt:"alt",option:"alt",return:"enter",right:"arrowright",space:"space",spacebar:"space",up:"arrowup",win:"meta",windows:"meta"},eu=e=>{let t=e.split("/");return/\.js/.test(t[t.length-1])?{basePath:t.slice(0,t.length-1).join("/")+"/",isMin:!0}:{basePath:e,isMin:!0}},{basePath:ec,isMin:ed}=(()=>{if("u"<typeof document)return{basePath:"",isMin:!0};let e=w.currentScript;if(e)return eu(e.src);let t=w.querySelectorAll("script[src]");return t&&t.length?eu(t[t.length-1].src):eu(S.location.href)})(),eh=ec,ep=ed,ef="data-jodit-temp",em={},eg="clipboard",ev="source-consumer",e_=new Set(["touchstart","touchend","scroll","mousewheel","mousemove","touchmove"])},76517:function(e,t,i){"use strict";i.d(t,{Create:function(){return l}});var n=i(25045),o=i(81937),r=i(23211),s=i(65946),a=i(28712);class l{get doc(){return(0,s.isFunction)(this.document)?this.document():this.document}element(e,t,i){let n=this.doc.createElement(e.toLowerCase());return this.applyCreateAttributes(n),t&&((0,s.isPlainObject)(t)?(0,s.attr)(n,t):i=t),i&&(0,s.asArray)(i).forEach(e=>n.appendChild((0,s.isString)(e)?this.fromHTML(e):e)),n}div(e,t,i){let n=this.element("div",t,i);return e&&(n.className=e),n}sandbox(){var e;let t=this.element("iframe",{sandbox:"allow-same-origin"});this.doc.body.appendChild(t);let i=null==(e=t.contentWindow)?void 0:e.document;if((0,a.assert)(i,"iframe.contentWindow.document"),!i)throw Error("Iframe error");return i.open(),i.write("<!DOCTYPE html><html><head></head><body></body></html>"),i.close(),[i.body,t]}span(e,t,i){let n=this.element("span",t,i);return e&&(n.className=e),n}a(e,t,i){let n=this.element("a",t,i);return e&&(n.className=e),n}text(e){return this.doc.createTextNode(e)}fake(){return this.text(o.INVISIBLE_SPACE)}fragment(){return this.doc.createDocumentFragment()}fromHTML(e,t){let i=this.div();i.innerHTML=e.toString();let n=i.firstChild===i.lastChild&&i.firstChild?i.firstChild:i;if(r.Dom.safeRemove(n),t){let e=(0,s.refs)(n);Object.keys(t).forEach(i=>{let n=e[i];n&&!1===t[i]&&r.Dom.hide(n)})}return n}applyCreateAttributes(e){if(this.createAttributes){let t=this.createAttributes;if(t&&t[e.tagName.toLowerCase()]){let i=t[e.tagName.toLowerCase()];(0,s.isFunction)(i)?i(e):(0,s.isPlainObject)(i)&&(0,s.attr)(e,i)}}}constructor(e,t){(0,n._)(this,"document",void 0),(0,n._)(this,"createAttributes",void 0),this.document=e,this.createAttributes=t}}},79821:function(e,t,i){"use strict";i.d(t,{Create:function(){return n.Create}});var n=i(76517)},49574:function(e,t,i){"use strict";i.d(t,{autobind:function(){return o}});var n=i(91565);function o(e,t,i){if(!(0,n.isFunction)(i.value))throw TypeError(`@autobind can only be applied to methods, but "${t}" is not a function`);let o=i.value;return{configurable:!0,get(){let e=o.bind(this);return Object.defineProperty(this,t,{value:e,configurable:!0,writable:!0}),e}}}},51676:function(e,t,i){"use strict";i.d(t,{cache:function(){return l},cacheHTML:function(){return u},cached:function(){return a}});var n=i(69364),o=i(23211),r=i(28686),s=i(38027);function a(e,t){let i=Object.getOwnPropertyDescriptor(e,t);return!i||(0,r.isFunction)(i.get)?null:i.value}function l(e,t,i){let n=i.get;if(!n)throw(0,s.error)("Getter property descriptor expected");i.get=function(){let e=n.call(this);return e&&!0===e.noCache||Object.defineProperty(this,t,{configurable:i.configurable,enumerable:i.enumerable,writable:!1,value:e}),e}}function u(e,t,i){let a=i.value;if(!(0,r.isFunction)(a))throw(0,s.error)("Handler must be a Function");let l=!0,u=new WeakMap;i.value=function(...e){if(l&&u.has(this.constructor)){var t;return null==(t=u.get(this.constructor))?void 0:t.cloneNode(!0)}let i=a.apply(this,e);return l&&o.Dom.isElement(i)&&u.set(this.constructor,i),l?i.cloneNode(!0):i},e.hookStatus(n.STATUSES.ready,e=>{l=!!((0,r.isViewObject)(e)?e:e.jodit).options.cache})}},91672:function(e,t,i){"use strict";i.d(t,{component:function(){return s},getComponentClass:function(){return a}});var n=i(81937),o=i(421);let r=new Map;function s(e){class t extends e{constructor(...e){super(...e),this.constructor===t&&(this instanceof t||Object.setPrototypeOf(this,t.prototype),this.setStatus("ready"))}}let i=(0,o.getClassName)(e.prototype);if(r.has(i)&&!n.IS_PROD)throw Error(`Component with name "${i}" is already registered`);return r.set(i,t),t}function a(e){return r.get(e)}},55184:function(e,t,i){"use strict";i.d(t,{debounce:function(){return a},throttle:function(){return l}});var n=i(16964),o=i(28686),r=i(28712),s=i(33201);function a(e,t=!1,i="debounce"){return(a,l)=>{let u=a[l];if(!(0,o.isFunction)(u))throw(0,s.error)("Handler must be a Function");return a.hookStatus(n.STATUSES.ready,n=>{let{async:s}=n;(0,r.assert)(null!=s,`Component ${n.componentName||n.constructor.name} should have "async:IAsync" field`);let a=(0,o.isFunction)(e)?e(n):e,u=(0,o.isNumber)(a)||(0,o.isPlainObject)(a)?a:n.defaultTimeout;Object.defineProperty(n,l,{configurable:!0,value:s[i](n[l].bind(n),u,t)})}),{configurable:!0,get(){return u.bind(this)}}}}function l(e,t=!1){return a(e,t,"throttle")}},24968:function(e,t,i){"use strict";i.d(t,{derive:function(){return o}});var n=i(91565);function o(...e){return t=>{let i=t.prototype;for(let t=0;t<e.length;t++){let o=e[t],r=Object.getOwnPropertyNames(o.prototype);for(let e=0;e<r.length;e++){let t=r[e],s=Object.getOwnPropertyDescriptor(o.prototype,t);null!=s&&(0,n.isFunction)(s.value)&&!(0,n.isFunction)(i[t])&&Object.defineProperty(i,t,{enumerable:!0,configurable:!0,writable:!0,value:function(...e){return s.value.call(this,...e)}})}}}}},29200:function(e,t,i){"use strict";i.d(t,{hook:function(){return r}});var n=i(91565),o=i(33201);function r(e){return(t,i)=>{if(!(0,n.isFunction)(t[i]))throw(0,o.error)("Handler must be a Function");t.hookStatus(e,e=>{e[i].call(e)})}}},35718:function(e,t,i){"use strict";i.d(t,{idle:function(){return s}});var n=i(16964),o=i(91565),r=i(33201);function s(){return(e,t)=>{if(!(0,o.isFunction)(e[t]))throw(0,r.error)("Handler must be a Function");e.hookStatus(n.STATUSES.ready,e=>{let{async:i}=e,n=e[t];e[t]=(...t)=>i.requestIdleCallback(n.bind(e,...t))})}}},84839:function(e,t,i){"use strict";i.r(t),i.d(t,{autobind:function(){return n.autobind},cache:function(){return o.cache},cacheHTML:function(){return o.cacheHTML},cached:function(){return o.cached},component:function(){return r.component},debounce:function(){return s.debounce},derive:function(){return a.derive},getComponentClass:function(){return r.getComponentClass},hook:function(){return l.hook},idle:function(){return u.idle},nonenumerable:function(){return c.nonenumerable},persistent:function(){return d.persistent},throttle:function(){return s.throttle},wait:function(){return h.wait},watch:function(){return p.watch}});var n=i(49574),o=i(51676),r=i(91672),s=i(55184),a=i(24968),l=i(29200),u=i(35718),c=i(41360),d=i(77036),h=i(80840),p=i(68616)},41360:function(e,t,i){"use strict";i.d(t,{nonenumerable:function(){return n}});let n=(e,t)=>{!1!==(Object.getOwnPropertyDescriptor(e,t)||{}).enumerable&&Object.defineProperty(e,t,{enumerable:!1,set(e){Object.defineProperty(this,t,{enumerable:!1,writable:!0,value:e})}})}},77036:function(e,t,i){"use strict";i.d(t,{persistent:function(){return r}});var n=i(69364),o=i(31534);function r(e,t){e.hookStatus(n.STATUSES.ready,e=>{let i=(0,o.isViewObject)(e)?e:e.jodit,n=`${i.options.namespace}${e.componentName}_prop_${t}`,r=e[t];Object.defineProperty(e,t,{get(){var e;return null!=(e=i.storage.get(n))?e:r},set(e){i.storage.set(n,e)}})})}},80840:function(e,t,i){"use strict";i.d(t,{wait:function(){return s}});var n=i(69364),o=i(91565),r=i(33201);function s(e){return(t,i)=>{let s=t[i];if(!(0,o.isFunction)(s))throw(0,r.error)("Handler must be a Function");t.hookStatus(n.STATUSES.ready,t=>{let{async:n}=t,o=t[i],r=0;Object.defineProperty(t,i,{configurable:!0,value:function i(...s){n.clearTimeout(r),e(t)?o.apply(t,s):r=n.setTimeout(()=>i(...s),10)}})})}}},68616:function(e,t,i){"use strict";i.d(t,{watch:function(){return d}});var n=i(69364),o=i(70535),r=i(32328),s=i(91565),a=i(62101),l=i(31534),u=i(33201),c=i(71125);function d(e,t){return(i,d)=>{var h;if(!(0,s.isFunction)(i[d]))throw(0,u.error)("Handler must be a Function");let p=null==(h=null==t?void 0:t.immediately)||h,f=null==t?void 0:t.context,m=t=>{let n=(0,l.isViewObject)(t)?t:t.jodit,u=(e,...i)=>{if(!t.isInDestruct)return t[d](e,...i)};p||(u=t.async.microDebounce(u,!0)),(0,r.splitArray)(e).forEach(e=>{if(/:/.test(e)){let[i,o]=e.split(":"),r=f;i.length&&(r=t.get(i)),(0,s.isFunction)(r)&&(r=r(t)),n.events.on(r||t,o,u),r||n.events.on(o,u),t.hookStatus("beforeDestruct",()=>{n.events.off(r||t,o,u).off(o,u)});return}let r=e.split("."),[l]=r,d=r.slice(1),h=t[l];(0,a.isPlainObject)(h)&&(0,o.observable)(h).on(`change.${d.join(".")}`,u);let p=(0,c.getPropertyDescriptor)(i,l);Object.defineProperty(t,l,{configurable:!0,set(e){let i=h;i!==e&&(h=e,p&&p.set&&p.set.call(t,e),(0,a.isPlainObject)(h)&&(h=(0,o.observable)(h)).on(`change.${d.join(".")}`,u),u(l,i,h))},get(){return p&&p.get?p.get.call(t):h}})})};(0,s.isFunction)(i.hookStatus)?i.hookStatus(n.STATUSES.ready,m):m(i)}}},23211:function(e,t,i){"use strict";i.d(t,{Dom:function(){return _}});var n=i(81937),o=i(88475),r=i(17312),s=i(91565),a=i(46248),l=i(3213),u=i(85932),c=i(18303),d=i(4040),h=i(28712),p=i(7909),f=i(80991),m=i(36400),g=i(33201),v=i(71125);class _{static detach(e){for(;e&&e.firstChild;)e.removeChild(e.firstChild)}static wrapNextInline(e,t,i){let n,o=e;i.s.save();let r=!1;do r=!1,(n=o.nextSibling)&&!_.isBlock(n)&&!_.isTag(n,"br")&&(r=!0,o=n);while(r);return _.__wrapElements(t,i,e,o)}static __wrapElements(e,t,i,n){let o=(0,u.isString)(e)?t.createInside.element(e):e;i.parentNode&&i.parentNode.insertBefore(o,i);let r=i;for(;r&&(r=i.nextSibling,o.appendChild(i),i!==n&&r);)i=r;return t.s.restore(),o}static wrapInline(e,t,i){let n,o=e,r=e;i.s.save();let s=!1;do s=!1,(n=o.previousSibling)&&!_.isBlock(n)&&(s=!0,o=n);while(s);do s=!1,(n=r.nextSibling)&&!_.isBlock(n)&&(s=!0,r=n);while(s);return _.__wrapElements(t,i,o,r)}static wrap(e,t,i){let n=(0,u.isString)(t)?i.element(t):t;if(_.isNode(e)){if(!e.parentNode)throw(0,g.error)("Element should be in DOM");e.parentNode.insertBefore(n,e),n.appendChild(e)}else{let t=e.extractContents();e.insertNode(n),n.appendChild(t)}return n}static unwrap(e){let t=e.parentNode;if(t){for(;e.firstChild;)t.insertBefore(e.firstChild,e);_.safeRemove(e)}}static between(e,t,i){let n=e;for(;n&&n!==t&&!(e!==n&&i(n));){let e=n.firstChild||n.nextSibling;if(!e){for(;n&&!n.nextSibling;)n=n.parentNode;e=null==n?void 0:n.nextSibling}n=e}}static replace(e,t,i,n=!1,r=!1){let s;if((0,a.isHTML)(t)&&((0,h.assert)(i,"Need create instance for new tag"),t=i.fromHTML(t)),(0,u.isString)(t)?((0,h.assert)(i,"Need create instance for new tag"),s=i.element(t)):s=t,!r)for(;e.firstChild;)s.appendChild(e.firstChild);return n&&_.isElement(e)&&_.isElement(s)&&(0,o.toArray)(e.attributes).forEach(e=>{s.setAttribute(e.name,e.value)}),e.parentNode&&e.parentNode.replaceChild(s,e),s}static isEmptyTextNode(e){return _.isText(e)&&(!e.nodeValue||0===e.nodeValue.replace(n.INVISIBLE_SPACE_REG_EXP(),"").trim().length)}static isEmptyContent(e){return _.each(e,e=>_.isEmptyTextNode(e))}static isContentEditable(e,t){return _.isNode(e)&&!_.closest(e,e=>_.isElement(e)&&"false"===e.getAttribute("contenteditable"),t)}static isEmpty(e,t=n.NO_EMPTY_TAGS){let i;if(!e)return!0;i=(0,s.isFunction)(t)?t:e=>t.has(e.nodeName.toLowerCase());let o=e=>null==e.nodeValue||0===(0,d.trim)(e.nodeValue).length;return _.isText(e)?o(e):!(_.isElement(e)&&i(e))&&_.each(e,e=>{if(_.isText(e)&&!o(e)||_.isElement(e)&&i(e))return!1})}static isNode(e){return!!(e&&(0,u.isString)(e.nodeName)&&"number"==typeof e.nodeType&&e.childNodes&&(0,s.isFunction)(e.appendChild))}static isCell(e){return _.isNode(e)&&("TD"===e.nodeName||"TH"===e.nodeName)}static isList(e){return _.isTag(e,n.LIST_TAGS)}static isLeaf(e){return _.isTag(e,"li")}static isImage(e){return _.isNode(e)&&/^(img|svg|picture|canvas)$/i.test(e.nodeName)}static isBlock(e){return!(0,c.isVoid)(e)&&"object"==typeof e&&_.isNode(e)&&n.IS_BLOCK.test(e.nodeName)}static isText(e){return!!(e&&e.nodeType===Node.TEXT_NODE)}static isComment(e){return!!(e&&e.nodeType===Node.COMMENT_NODE)}static isElement(e){var t;return!!_.isNode(e)&&!!((null==(t=e.ownerDocument)?void 0:t.defaultView)&&e.nodeType===Node.ELEMENT_NODE)}static isFragment(e){var t;return!!_.isNode(e)&&!!((null==(t=e.ownerDocument)?void 0:t.defaultView)&&e.nodeType===Node.DOCUMENT_FRAGMENT_NODE)}static isHTMLElement(e){var t;if(!_.isNode(e))return!1;let i=null==(t=e.ownerDocument)?void 0:t.defaultView;return!!(i&&e instanceof i.HTMLElement)}static isInlineBlock(e){return _.isElement(e)&&!/^(BR|HR)$/i.test(e.tagName)&&-1!==["inline","inline-block"].indexOf((0,f.css)(e,"display").toString())}static canSplitBlock(e){return!(0,c.isVoid)(e)&&_.isHTMLElement(e)&&_.isBlock(e)&&!/^(TD|TH|CAPTION|FORM)$/.test(e.nodeName)&&void 0!==e.style&&!/^(fixed|absolute)/i.test(e.style.position)}static first(e,t){let i=null==e?void 0:e.firstChild;if(!i)return null;do{if(t(i))return i;let n=i.firstChild;if(n||(n=i.nextSibling),!n&&i.parentNode!==e){do i=i.parentNode;while(i&&!(null==i?void 0:i.nextSibling)&&i.parentNode!==e);n=null==i?void 0:i.nextSibling}i=n}while(i);return null}static last(e,t){let i=null==e?void 0:e.lastChild;if(!i)return null;do{if(t(i))return i;let n=i.lastChild;if(n||(n=i.previousSibling),!n&&i.parentNode!==e){do i=i.parentNode;while(i&&!(null==i?void 0:i.previousSibling)&&i.parentNode!==e);n=null==i?void 0:i.previousSibling}i=n}while(i);return null}static prev(e,t,i,n=!0){return _.find(e,t,i,!1,n)}static next(e,t,i,n=!0){return _.find(e,t,i,!0,n)}static prevWithClass(e,t){return _.prev(e,e=>_.isElement(e)&&e.classList.contains(t),e.parentNode)}static nextWithClass(e,t){return _.next(e,e=>_.isElement(e)&&e.classList.contains(t),e.parentNode)}static find(e,t,i,n=!0,o=!0){let r=this.nextGen(e,i,n,o),s=r.next();for(;!s.done;){if(t(s.value))return s.value;s=r.next()}return null}static*nextGen(e,t,i=!0,n=!0){let o=[],r=e;do{let t=i?r.nextSibling:r.previousSibling;for(;t;)o.unshift(t),t=i?t.nextSibling:t.previousSibling;yield*this.runInStack(e,o,i,n),r=r.parentNode}while(r&&r!==t);return null}static each(e,t,i=!0){let n=this.eachGen(e,i),o=n.next();for(;!o.done;){if(!1===t(o.value))return!1;o=n.next()}return!0}static eachGen(e,t=!0){return this.runInStack(e,[e],t)}static*runInStack(e,t,i,n=!0){for(;t.length;){let o=t.pop();if(n){let e=i?o.lastChild:o.firstChild;for(;e;)t.push(e),e=i?e.previousSibling:e.nextSibling}e!==o&&(yield o)}}static findWithCurrent(e,t,i,n="nextSibling",o="firstChild"){let r=e;do{if(t(r))return r||null;if(o&&r&&r[o]){let e=_.findWithCurrent(r[o],t,r,n,o);if(e)return e}for(;r&&!r[n]&&r!==i;)r=r.parentNode;r&&r[n]&&r!==i&&(r=r[n])}while(r&&r!==i);return null}static findSibling(e,t=!0,i=e=>!_.isEmptyTextNode(e)){let n=_.sibling(e,t);for(;n&&!i(n);)n=_.sibling(n,t);return n&&i(n)?n:null}static findNotEmptySibling(e,t){return _.findSibling(e,t,e=>{var t;return!_.isEmptyTextNode(e)&&!!(!_.isText(e)||(null==(t=e.nodeValue)?void 0:t.length)&&(0,d.trim)(e.nodeValue))})}static findNotEmptyNeighbor(e,t,i){return(0,v.call)(t?_.prev:_.next,e,e=>!!(e&&(!(_.isText(e)||_.isComment(e))||(0,d.trim)((null==e?void 0:e.nodeValue)||"").length)),i)}static sibling(e,t){return t?e.previousSibling:e.nextSibling}static up(e,t,i,n=!1){let o=e;if(!o)return null;do{if(t(o))return o;if(o===i||!o.parentNode)break;o=o.parentNode}while(o&&o!==i);return o===i&&n&&t(o)?o:null}static closest(e,t,i){let n,o=e=>e.toLowerCase();if((0,s.isFunction)(t))n=t;else if((0,r.isArray)(t)||(0,l.isSet)(t)){let e=(0,l.isSet)(t)?t:new Set(t.map(o));n=t=>!!(t&&e.has(o(t.nodeName)))}else n=e=>!!(e&&o(t)===o(e.nodeName));return _.up(e,n,i)}static furthest(e,t,i){let n=null,o=null==e?void 0:e.parentElement;for(;o&&o!==i;)t(o)&&(n=o),o=null==o?void 0:o.parentElement;return n}static appendChildFirst(e,t){let i=e.firstChild;i?i!==t&&e.insertBefore(t,i):e.appendChild(t)}static after(e,t){let{parentNode:i}=e;i&&(i.lastChild===e?i.appendChild(t):i.insertBefore(t,e.nextSibling))}static before(e,t){let{parentNode:i}=e;i&&i.insertBefore(t,e)}static prepend(e,t){e.insertBefore(t,e.firstChild)}static append(e,t){(0,r.isArray)(t)?t.forEach(t=>{this.append(e,t)}):e.appendChild(t)}static moveContent(e,t,i=!1,r=()=>!0){let s=(e.ownerDocument||n.globalDocument).createDocumentFragment();(0,o.toArray)(e.childNodes).filter(e=>!!r(e)||(_.safeRemove(e),!1)).forEach(e=>{s.appendChild(e)}),i&&t.firstChild?t.insertBefore(s,t.firstChild):t.appendChild(s)}static isOrContains(e,t,i=!1){return e===t?!i:!!(t&&e&&this.up(t,t=>t===e,e,!0))}static safeRemove(...e){e.forEach(e=>_.isNode(e)&&e.parentNode&&e.parentNode.removeChild(e))}static safeInsertNode(e,t){e.collapsed||e.deleteContents();let i=_.isFragment(t)?t.lastChild:t;e.startContainer===e.endContainer&&e.collapsed&&_.isTag(e.startContainer,n.INSEPARABLE_TAGS)?_.after(e.startContainer,t):(e.insertNode(t),i&&e.setStartBefore(i)),e.collapse(!0),[t.nextSibling,t.previousSibling].forEach(e=>_.isText(e)&&!e.nodeValue&&_.safeRemove(e))}static hide(e){e&&((0,m.dataBind)(e,"__old_display",e.style.display),e.style.display="none")}static show(e){if(!e)return;let t=(0,m.dataBind)(e,"__old_display");"none"===e.style.display&&(e.style.display=t||"")}static isTag(e,t){if(!this.isElement(e))return!1;let i=e.tagName.toLowerCase(),n=e.tagName.toUpperCase();if(t instanceof Set)return t.has(i)||t.has(n);if(Array.isArray(t))throw TypeError("Dom.isTag does not support array");return i===t||n===t}static markTemporary(e,t){return t&&(0,p.attr)(e,t),(0,p.attr)(e,n.TEMP_ATTR,!0),e}static isTemporary(e){return!!_.isElement(e)&&(_.isMarker(e)||"true"===(0,p.attr)(e,n.TEMP_ATTR))}static isMarker(e){return _.isNode(e)&&_.isTag(e,"span")&&e.hasAttribute("data-"+n.MARKER_CLASS)}static replaceTemporaryFromString(e){return e.replace(/<([a-z]+)[^>]+data-jodit-temp[^>]+>(.+?)<\/\1>/gi,"$2")}static temporaryList(e){return(0,o.toArray)(e.querySelectorAll(`[${n.TEMP_ATTR}]`))}constructor(){throw Error("Dom is static module")}}},27795:function(e,t,i){"use strict";i.d(t,{Dom:function(){return n.Dom},LazyWalker:function(){return o.LazyWalker}});var n=i(23211),o=i(1080)},1080:function(e,t,i){"use strict";i.d(t,{LazyWalker:function(){return l}});var n=i(25045),o=i(31635),r=i(49574),s=i(23211),a=i(60216);class l extends a.Eventify{setWork(e){return this.isWorked&&this.break(),this.workNodes=s.Dom.eachGen(e,!this.options.reverse),this.isFinished=!1,this._requestStarting(),this}_requestStarting(){this.__schedulerController=new AbortController,this.async.schedulerPostTask(this.__workPerform,{delay:this.options.timeout,signal:this.__schedulerController.signal}).catch(()=>null)}break(e){this.isWorked&&(this.stop(),this.emit("break",e))}end(){this.isWorked&&(this.stop(),this.emit("end",this.hadAffect),this.hadAffect=!1)}stop(){this.isWorked=!1,this.isFinished=!0,this.workNodes=null,this.async.cancelIdleCallback(this.idleId)}destruct(){super.destruct(),this.stop()}__workPerform(){if(this.workNodes){var e;this.isWorked=!0;let t=0,i=null!=(e=this.options.timeoutChunkSize)?e:50;for(;!this.isFinished&&t<=i;){let e=this.workNodes.next();if(t+=1,this.visitNode(e.value)&&(this.hadAffect=!0),e.done)return void this.end()}}else this.end();this.isFinished||this._requestStarting()}visitNode(e){var t;return!!e&&(void 0===this.options.whatToShow||e.nodeType===this.options.whatToShow)&&null!=(t=this.emit("visit",e))&&t}constructor(e,t={}){super(),(0,n._)(this,"async",void 0),(0,n._)(this,"options",void 0),(0,n._)(this,"workNodes",void 0),(0,n._)(this,"hadAffect",void 0),(0,n._)(this,"isWorked",void 0),(0,n._)(this,"isFinished",void 0),(0,n._)(this,"idleId",void 0),(0,n._)(this,"__schedulerController",void 0),this.async=e,this.options=t,this.workNodes=null,this.hadAffect=!1,this.isWorked=!1,this.isFinished=!1,this.idleId=0,this.__schedulerController=null}}(0,o.__decorate)([r.autobind],l.prototype,"__workPerform",null)},93747:function(e,t,i){"use strict";i.d(t,{EventEmitter:function(){return d}});var n=i(25045),o=i(81937),r=i(32328),s=i(17312),a=i(91565),l=i(85932),u=i(33201),c=i(18869);class d{mute(e){return this.__mutedEvents.add(null!=e?e:"*"),this}isMuted(e){return!!(e&&this.__mutedEvents.has(e))||this.__mutedEvents.has("*")}unmute(e){return this.__mutedEvents.delete(null!=e?e:"*"),this}__eachEvent(e,t){(0,r.splitArray)(e).map(e=>e.trim()).forEach(e=>{let i=e.split("."),n=i[1]||c.defaultNameSpace;t.call(this,i[0],n)})}__getStore(e){if(!e)throw(0,u.error)("Need subject");if(void 0===e[this.__key]){let t=new c.EventHandlersStore;Object.defineProperty(e,this.__key,{enumerable:!1,configurable:!0,writable:!0,value:t})}return e[this.__key]}__removeStoreFromSubject(e){void 0!==e[this.__key]&&Object.defineProperty(e,this.__key,{enumerable:!1,configurable:!0,writable:!0,value:void 0})}__triggerNativeEvent(e,t){let i=this.__doc.createEvent("HTMLEvents");(0,l.isString)(t)?i.initEvent(t,!0,!0):(i.initEvent(t.type,t.bubbles,t.cancelable),["screenX","screenY","clientX","clientY","target","srcElement","currentTarget","timeStamp","which","keyCode"].forEach(e=>{Object.defineProperty(i,e,{value:t[e],enumerable:!0})}),Object.defineProperty(i,"originalEvent",{value:t,enumerable:!0})),e.dispatchEvent(i)}get current(){return this.currents[this.currents.length-1]}on(e,t,i,n){let r,c,d,p;if((0,l.isString)(e)||(0,l.isStringArray)(e)?(r=this,c=e,d=t,p=i):(r=e,c=t,d=i,p=n),!((0,l.isString)(c)||(0,l.isStringArray)(c))||0===c.length)throw(0,u.error)("Need events names");if(!(0,a.isFunction)(d))throw(0,u.error)("Need event handler");if((0,s.isArray)(r))return r.forEach(e=>{this.on(e,c,d,p)}),this;let f=r,m=this.__getStore(f),g=this,v=function(e,...t){if(!g.isMuted(e))return d&&d.call(this,...t)};return h(f)&&(v=function(e){if(!g.isMuted(e.type)&&(g.__prepareEvent(e),d&&!1===d.call(this,e)))return e.preventDefault(),e.stopImmediatePropagation(),!1}),this.__eachEvent(c,(e,t)=>{if(0===e.length)throw(0,u.error)("Need event name");if(!1===m.indexOf(e,t,d)){let r={event:e,originalCallback:d,syntheticCallback:v};if(m.set(e,t,r,null==p?void 0:p.top),h(f)){var i,n;let t=o.PASSIVE_EVENTS.has(e)?{passive:!0,capture:null!=(i=null==p?void 0:p.capture)&&i}:null!=(n=null==p?void 0:p.capture)&&n;v.options=t,f.addEventListener(e,v,t),this.__memoryDOMSubjectToHandler(f,v)}}}),this}__memoryDOMSubjectToHandler(e,t){let i=this.__domEventsMap.get(e)||new Set;i.add(t),this.__domEventsMap.set(e,i)}__unmemoryDOMSubjectToHandler(e,t){let i=this.__domEventsMap,n=i.get(e)||new Set;n.delete(t),n.size?i.set(e,n):i.delete(e)}one(e,t,i,n){let o,r,s,a;(0,l.isString)(e)||(0,l.isStringArray)(e)?(o=this,r=e,s=t,a=i):(o=e,r=t,s=i,a=n);let u=(...e)=>(this.off(o,r,u),s(...e));return this.on(o,r,u,a),this}off(e,t,i){let n,o,r;if((0,l.isString)(e)||(0,l.isStringArray)(e)?(n=this,o=e,r=t):(n=e,o=t,r=i),(0,s.isArray)(n))return n.forEach(e=>{this.off(e,o,r)}),this;let u=n,d=this.__getStore(u);if(!((0,l.isString)(o)||(0,l.isStringArray)(o))||0===o.length)return d.namespaces().forEach(e=>{this.off(u,"."+e)}),this.__removeStoreFromSubject(u),this;let p=e=>{if(h(u)){var t;u.removeEventListener(e.event,e.syntheticCallback,null!=(t=e.syntheticCallback.options)&&t),this.__unmemoryDOMSubjectToHandler(u,e.syntheticCallback)}},f=(e,t)=>{if(""===e)return void d.events(t).forEach(e=>{""!==e&&f(e,t)});let i=d.get(e,t);if(i&&i.length)if((0,a.isFunction)(r)){let n=d.indexOf(e,t,r);!1!==n&&(p(i[n]),i.splice(n,1),i.length||d.clearEvents(t,e))}else i.forEach(p),i.length=0,d.clearEvents(t,e)};return this.__eachEvent(o,(e,t)=>{t===c.defaultNameSpace?d.namespaces().forEach(t=>{f(e,t)}):f(e,t)}),d.isEmpty()&&this.__removeStoreFromSubject(u),this}stopPropagation(e,t){let i=(0,l.isString)(e)?this:e,n=(0,l.isString)(e)?e:t;if("string"!=typeof n)throw(0,u.error)("Need event names");let o=this.__getStore(i);this.__eachEvent(n,(e,t)=>{let n=o.get(e,t);n&&this.__stopped.push(n),t===c.defaultNameSpace&&o.namespaces(!0).forEach(t=>this.stopPropagation(i,e+"."+t))})}__removeStop(e){if(e){let t=this.__stopped.indexOf(e);-1!==t&&this.__stopped.splice(0,t+1)}}__isStopped(e){return void 0!==e&&-1!==this.__stopped.indexOf(e)}fire(e,t,...i){let n,o,r=(0,l.isString)(e)?this:e,s=(0,l.isString)(e)?e:t,a=(0,l.isString)(e)?[t,...i]:i;if(!h(r)&&!(0,l.isString)(s))throw(0,u.error)("Need events names");let d=this.__getStore(r);return!(0,l.isString)(s)&&h(r)?this.__triggerNativeEvent(r,t):this.__eachEvent(s,(e,t)=>{if(h(r))this.__triggerNativeEvent(r,e);else{let i=d.get(e,t);if(i)try{[...i].every(t=>!this.__isStopped(i)&&(this.currents.push(e),o=t.syntheticCallback.call(r,e,...a),this.currents.pop(),void 0!==o&&(n=o),!0))}finally{this.__removeStop(i)}t!==c.defaultNameSpace||h(r)||d.namespaces().filter(e=>e!==t).forEach(t=>{let i=this.fire.apply(this,[r,e+"."+t,...a]);void 0!==i&&(n=i)})}}),n}destruct(){this.__isDestructed||(this.__isDestructed=!0,this.__domEventsMap.forEach((e,t)=>{this.off(t)}),this.__domEventsMap.clear(),this.__mutedEvents.clear(),this.currents.length=0,this.__stopped.length=0,this.off(this),this.__getStore(this).clear(),this.__removeStoreFromSubject(this))}constructor(e){(0,n._)(this,"__domEventsMap",new Map),(0,n._)(this,"__mutedEvents",new Set),(0,n._)(this,"__key","__JoditEventEmitterNamespaces"),(0,n._)(this,"__doc",o.globalDocument),(0,n._)(this,"__prepareEvent",e=>{!e.cancelBubble&&(e.composed&&(0,a.isFunction)(e.composedPath)&&e.composedPath()[0]&&Object.defineProperty(e,"target",{value:e.composedPath()[0],configurable:!0,enumerable:!0}),e.type.match(/^touch/)&&e.changedTouches&&e.changedTouches.length&&["clientX","clientY","pageX","pageY"].forEach(t=>{Object.defineProperty(e,t,{value:e.changedTouches[0][t],configurable:!0,enumerable:!0})}),e.originalEvent||(e.originalEvent=e),"paste"===e.type&&void 0===e.clipboardData&&this.__doc.defaultView.clipboardData&&Object.defineProperty(e,"clipboardData",{get:()=>this.__doc.defaultView.clipboardData,configurable:!0,enumerable:!0}))}),(0,n._)(this,"currents",[]),(0,n._)(this,"__stopped",[]),(0,n._)(this,"__isDestructed",!1),e&&(this.__doc=e),this.__key+=new Date().getTime()}}function h(e){return e&&(0,a.isFunction)(e.addEventListener)}},60216:function(e,t,i){"use strict";i.d(t,{Eventify:function(){return o}});var n=i(25045);class o{on(e,t){var i;return this.__map.has(e)||this.__map.set(e,new Set),null==(i=this.__map.get(e))||i.add(t),this}off(e,t){if(this.__map.has(e)){var i;null==(i=this.__map.get(e))||i.delete(t)}return this}destruct(){this.__map.clear()}emit(e,...t){let i;if(this.__map.has(e)){var n;null==(n=this.__map.get(e))||n.forEach(e=>{i=e(...t)})}return i}constructor(){(0,n._)(this,"__map",new Map)}}},42689:function(e,t,i){"use strict";i.d(t,{eventEmitter:function(){return n}});let n=new(i(93747)).EventEmitter},1496:function(e,t,i){"use strict";i.d(t,{EventEmitter:function(){return n.EventEmitter},EventHandlersStore:function(){return s.EventHandlersStore},Eventify:function(){return o.Eventify},defaultNameSpace:function(){return s.defaultNameSpace},observable:function(){return r.observable}});var n=i(93747),o=i(60216),r=i(70535),s=i(18869)},70535:function(e,t,i){"use strict";i.d(t,{observable:function(){return u}});var n=i(17312),o=i(94013),r=i(62101),s=i(71125);let a=Symbol("observable-object");function l(e){return void 0!==e[a]}function u(e){if(l(e))return e;let t={},i={},u=(t,o)=>((0,n.isArray)(t)?t.map(e=>u(e,o)):(i[t]||(i[t]=[]),i[t].push(o)),e),c=(o,...r)=>{if((0,n.isArray)(o))return void o.map(e=>c(e,...r));try{!t[o]&&i[o]&&(t[o]=!0,i[o].forEach(t=>t.call(e,...r)))}finally{t[o]=!1}},d=(t,i=[])=>{let n={};l(t)||(Object.defineProperty(t,a,{enumerable:!1,value:!0}),Object.keys(t).forEach(a=>{let l=i.concat(a).filter(e=>e.length);n[a]=t[a];let u=(0,s.getPropertyDescriptor)(t,a);Object.defineProperty(t,a,{set:t=>{let i=n[a];if(!(0,o.isFastEqual)(n[a],t)){c(["beforeChange",`beforeChange.${l.join(".")}`],a,t),(0,r.isPlainObject)(t)&&d(t,l),u&&u.set?u.set.call(e,t):n[a]=t;let o=[];c(["change",...l.reduce((e,t)=>(o.push(t),e.push(`change.${o.join(".")}`),e),[])],l.join("."),i,(null==t?void 0:t.valueOf)?t.valueOf():t)}},get:()=>u&&u.get?u.get.call(e):n[a],enumerable:!0,configurable:!0}),(0,r.isPlainObject)(n[a])&&d(n[a],l)}),Object.defineProperty(e,"on",{value:u}))};return d(e),e}},18869:function(e,t,i){"use strict";i.d(t,{EventHandlersStore:function(){return a},defaultNameSpace:function(){return s}});var n=i(25045),o=i(88475),r=i(28712);let s="JoditEventDefaultNamespace";class a{get(e,t){if(this.__store.has(t)){let i=this.__store.get(t);return(0,r.assert)(i,"-"),i[e]}}indexOf(e,t,i){let n=this.get(e,t);if(n){for(let e=0;e<n.length;e+=1)if(n[e].originalCallback===i)return e}return!1}namespaces(e=!1){let t=(0,o.toArray)(this.__store.keys());return e?t.filter(e=>e!==s):t}events(e){let t=this.__store.get(e);return t?Object.keys(t):[]}set(e,t,i,n=!1){let o=this.__store.get(t);o||(o={},this.__store.set(t,o)),void 0===o[e]&&(o[e]=[]),n?o[e].unshift(i):o[e].push(i)}clear(){this.__store.clear()}clearEvents(e,t){let i=this.__store.get(e);i&&i[t]&&(delete i[t],Object.keys(i).length||this.__store.delete(e))}isEmpty(){return 0===this.__store.size}constructor(){(0,n._)(this,"__store",new Map)}}},28077:function(e,t,i){"use strict";i.d(t,{eventEmitter:function(){return C},extendLang:function(){return b},getContainer:function(){return S},getPopupViewRoot:function(){return w},instances:function(){return p},modules:function(){return _},pluginSystem:function(){return v},uniqueUid:function(){return g}});var n=i(24497),o=i(85932),r=i(31534),s=i(74264),a=i(80991),l=i(421),u=i(85305),c=i(42689),d=i(81937),h=i(27795);let p={},f=1,m=new Set;function g(){function e(){return Math.round(f+=10*(Math.random()+1)).toString(16)}let t=e();for(;m.has(t);)t=e();return m.add(t),t}let v=new u.PluginSystem({getContainer:S}),_={},b=e=>{Object.keys(e).forEach(t=>{d.lang[t]?Object.assign(d.lang[t],e[t]):d.lang[t]=e[t]})},y=new WeakMap;function S(e,t,i="div",a=!1){let u=(0,o.isString)(t)?t:t?(0,l.getClassName)(t.prototype):"jodit-utils",c=y.get(e)||{},d=u+i,p=(0,r.isViewObject)(e)?e:e.j,f=null;if(!c[d]){let t=p.c;if(f=w(p.o,p.container,e.od.body),a&&(0,n.isJoditObject)(e)&&e.od!==e.ed){t=e.createInside;let o="style"===i?e.ed.head:e.ed.body;f=(0,n.isJoditObject)(e)&&e.o.shadowRoot?e.o.shadowRoot:o}let o=t.element(i,{className:`jodit jodit-${(0,s.kebabCase)(u)}-container jodit-box`});o.classList.add(`jodit_theme_${p.o.theme||"default"}`),f.appendChild(o),c[d]=o,e.hookStatus("beforeDestruct",()=>{p.events.off(o),h.Dom.safeRemove(o),delete c[d],Object.keys(c).length&&y.delete(e)}),y.set(e,c),p.events.fire("getContainer",o)}return c[d].classList.remove("jodit_theme_default","jodit_theme_dark"),c[d].classList.add(`jodit_theme_${p.o.theme||"default"}`),c[d]}function w(e,t,i){var n,o,r;return null!=(n=null!=(o=null!=(r=e.popupRoot)?r:e.shadowRoot)?o:h.Dom.closest(t,e=>h.Dom.isHTMLElement(e)&&(h.Dom.isTag(e,"dialog")||["fixed","absolute"].includes((0,a.css)(e,"position"))),i))?n:i}let C=c.eventEmitter},78982:function(e,t,i){"use strict";i.d(t,{asArray:function(){return o}});var n=i(17312);let o=e=>(0,n.isArray)(e)?e:[e]},45664:function(e,t,i){"use strict";i.d(t,{asArray:function(){return n.asArray},splitArray:function(){return o.splitArray},toArray:function(){return r.toArray}});var n=i(78982),o=i(32328),r=i(88475)},32328:function(e,t,i){"use strict";function n(e){return Array.isArray(e)?e:e.split(/[,\s]+/)}i.d(t,{splitArray:function(){return n}})},88475:function(e,t,i){"use strict";i.d(t,{toArray:function(){return r}});var n=i(23283),o=i(43379);let r=function(...e){var t;return((0,n.isNativeFunction)(Array.from)?Array.from:null!=(t=(0,o.reset)("Array.from"))?t:Array.from).apply(Array,e)}},61077:function(e,t,i){"use strict";i.d(t,{clearTimeout:function(){return n.clearTimeout},setTimeout:function(){return n.setTimeout}});var n=i(79947)},79947:function(e,t,i){"use strict";i.d(t,{clearTimeout:function(){return r},setTimeout:function(){return o}});var n=i(81937);function o(e,t,...i){return t?n.globalWindow.setTimeout(e,t,...i):(e.call(null,...i),0)}function r(e){n.globalWindow.clearTimeout(e)}},98740:function(e,t,i){"use strict";i.d(t,{hasBrowserColorPicker:function(){return o}});var n=i(81937);function o(){let e=!0;try{let t=n.globalDocument.createElement("input");t.type="color",t.value="!",e="color"===t.type&&"!"!==t.value}catch(t){e=!1}return e}},28686:function(e,t,i){"use strict";i.d(t,{hasBrowserColorPicker:function(){return n.hasBrowserColorPicker},hasContainer:function(){return d.hasContainer},isAbortError:function(){return o.isAbortError},isArray:function(){return r.isArray},isBoolean:function(){return s.isBoolean},isDestructable:function(){return d.isDestructable},isEqual:function(){return a.isEqual},isFastEqual:function(){return a.isFastEqual},isFunction:function(){return l.isFunction},isHTML:function(){return u.isHTML},isHtmlFromWord:function(){return c.isHtmlFromWord},isInitable:function(){return d.isInitable},isInt:function(){return h.isInt},isJoditObject:function(){return p.isJoditObject},isLicense:function(){return f.isLicense},isMarker:function(){return m.isMarker},isNativeFunction:function(){return g.isNativeFunction},isNumber:function(){return v.isNumber},isNumeric:function(){return _.isNumeric},isPlainObject:function(){return b.isPlainObject},isPromise:function(){return y.isPromise},isSet:function(){return S.isSet},isString:function(){return w.isString},isStringArray:function(){return w.isStringArray},isURL:function(){return C.isURL},isValidName:function(){return k.isValidName},isViewObject:function(){return E.isViewObject},isVoid:function(){return I.isVoid},isWindow:function(){return T.isWindow}});var n=i(98740),o=i(72068),r=i(17312),s=i(22289),a=i(94013),l=i(91565),u=i(46248),c=i(82166),d=i(52433),h=i(99732),p=i(24497),f=i(44998),m=i(23175),g=i(23283),v=i(72412),_=i(70222),b=i(62101),y=i(52100),S=i(3213),w=i(85932),C=i(91764),k=i(50083),E=i(31534),I=i(18303),T=i(3513)},72068:function(e,t,i){"use strict";function n(e){return!!e&&e instanceof DOMException&&"AbortError"===e.name}i.d(t,{isAbortError:function(){return n}})},17312:function(e,t,i){"use strict";function n(e){return Array.isArray(e)}i.d(t,{isArray:function(){return n}})},22289:function(e,t,i){"use strict";function n(e){return"boolean"==typeof e}i.d(t,{isBoolean:function(){return n}})},94013:function(e,t,i){"use strict";i.d(t,{isEqual:function(){return o},isFastEqual:function(){return r}});var n=i(3347);function o(e,t){return e===t||(0,n.stringify)(e)===(0,n.stringify)(t)}function r(e,t){return e===t}},91565:function(e,t,i){"use strict";function n(e){return"function"==typeof e}i.d(t,{isFunction:function(){return n}})},82166:function(e,t,i){"use strict";function n(e){return -1!==e.search(/<meta.*?Microsoft Excel\s[\d].*?>/)||-1!==e.search(/<meta.*?Microsoft Word\s[\d].*?>/)||-1!==e.search(/style="[^"]*mso-/)&&-1!==e.search(/<font/)}i.d(t,{isHtmlFromWord:function(){return n}})},46248:function(e,t,i){"use strict";i.d(t,{isHTML:function(){return o}});var n=i(85932);let o=e=>(0,n.isString)(e)&&/<([A-Za-z][A-Za-z0-9]*)\b[^>]*>(.*?)<\/\1>/m.test(e.replace(/[\r\n]/g,""))},52433:function(e,t,i){"use strict";i.d(t,{hasContainer:function(){return l},isDestructable:function(){return a},isInitable:function(){return s}});var n=i(23211),o=i(91565),r=i(18303);function s(e){return!(0,r.isVoid)(e)&&(0,o.isFunction)(e.init)}function a(e){return!(0,r.isVoid)(e)&&(0,o.isFunction)(e.destruct)}function l(e){return!(0,r.isVoid)(e)&&n.Dom.isElement(e.container)}},99732:function(e,t,i){"use strict";i.d(t,{isInt:function(){return r}});var n=i(70222),o=i(85932);function r(e){return(0,o.isString)(e)&&(0,n.isNumeric)(e)&&(e=parseFloat(e)),"number"==typeof e&&Number.isFinite(e)&&!(e%1)}},24497:function(e,t,i){"use strict";i.d(t,{isJoditObject:function(){return o}});var n=i(91565);function o(e){return!!(e&&e instanceof Object&&(0,n.isFunction)(e.constructor)&&("u">typeof Jodit&&e instanceof Jodit||e.isJodit))}},44998:function(e,t,i){"use strict";i.d(t,{isLicense:function(){return o}});var n=i(85932);let o=e=>(0,n.isString)(e)&&23===e.length&&/^[a-z0-9]{5}-[a-z0-9]{5}-[a-z0-9]{5}-[a-z0-9]{5}$/i.test(e)},23175:function(e,t,i){"use strict";i.d(t,{isMarker:function(){return o}});var n=i(23211);function o(e){return n.Dom.isMarker(e)}},23283:function(e,t,i){"use strict";function n(e){return!!e&&"function"===(typeof e).toLowerCase()&&(e===Function.prototype||/^\s*function\s*(\b[a-z$_][a-z0-9$_]*\b)*\s*\((|([a-z$_][a-z0-9$_]*)(\s*,[a-z$_][a-z0-9$_]*)*)\)\s*{\s*\[native code]\s*}\s*$/i.test(String(e)))}i.d(t,{isNativeFunction:function(){return n}})},72412:function(e,t,i){"use strict";function n(e){return"number"==typeof e&&!isNaN(e)&&isFinite(e)}i.d(t,{isNumber:function(){return n}})},70222:function(e,t,i){"use strict";i.d(t,{isNumeric:function(){return o}});var n=i(85932);function o(e){if((0,n.isString)(e)){if(!e.match(/^([+-])?[0-9]+(\.?)([0-9]+)?(e[0-9]+)?$/))return!1;e=parseFloat(e)}return"number"==typeof e&&!isNaN(e)&&isFinite(e)}},62101:function(e,t,i){"use strict";i.d(t,{isPlainObject:function(){return o}});var n=i(3513);function o(e){return!(!e||"object"!=typeof e||e.nodeType||(0,n.isWindow)(e))&&!(e.constructor&&!({}).hasOwnProperty.call(e.constructor.prototype,"isPrototypeOf"))}},52100:function(e,t,i){"use strict";function n(e){return e&&"function"==typeof e.then}i.d(t,{isPromise:function(){return n}})},3213:function(e,t,i){"use strict";i.d(t,{isSet:function(){return o}});var n=i(91565);function o(e){return!!e&&(0,n.isFunction)(e.has)&&(0,n.isFunction)(e.add)&&(0,n.isFunction)(e.delete)}},85932:function(e,t,i){"use strict";i.d(t,{isString:function(){return o},isStringArray:function(){return r}});var n=i(17312);function o(e){return"string"==typeof e}function r(e){return(0,n.isArray)(e)&&o(e[0])}},91764:function(e,t,i){"use strict";i.d(t,{isURL:function(){return o}});var n=i(81937);function o(e){if(e.includes(" "))return!1;if("u">typeof URL)try{let t=new URL(e);return["https:","http:","ftp:","file:","rtmp:"].includes(t.protocol)}catch(e){return!1}let t=n.globalDocument.createElement("a");return t.href=e,!!t.hostname}},50083:function(e,t,i){"use strict";function n(e){return!!e.length&&!/[^0-9A-Za-zа-яА-ЯЁё\w\-_. ]/.test(e)&&e.trim().length>0}i.d(t,{isValidName:function(){return n}})},31534:function(e,t,i){"use strict";i.d(t,{isViewObject:function(){return o}});var n=i(91565);function o(e){return!!(e&&e instanceof Object&&(0,n.isFunction)(e.constructor)&&e.isView)}},18303:function(e,t,i){"use strict";function n(e){return null==e}i.d(t,{isVoid:function(){return n}})},3513:function(e,t,i){"use strict";function n(e){return null!=e&&e===e.window}i.d(t,{isWindow:function(){return n}})},93387:function(e,t,i){"use strict";i.d(t,{colorToHex:function(){return n}});let n=e=>{if("rgba(0, 0, 0, 0)"===e||""===e)return!1;if(!e)return"#000000";if("#"===e.substr(0,1))return e;let t=/([\s\n\t\r]*?)rgb\((\d+), (\d+), (\d+)\)/.exec(e)||/([\s\n\t\r]*?)rgba\((\d+), (\d+), (\d+), ([\d.]+)\)/.exec(e);if(!t)return"#000000";let i=parseInt(t[2],10),n=parseInt(t[3],10),o=(parseInt(t[4],10)|n<<8|i<<16).toString(16).toUpperCase();for(;o.length<6;)o="0"+o;return t[1]+"#"+o}},7018:function(e,t,i){"use strict";i.d(t,{colorToHex:function(){return n.colorToHex}});var n=i(93387)},30893:function(e,t,i){"use strict";i.d(t,{applyStyles:function(){return l}});var n=i(81937),o=i(23211),r=i(4040),s=i(28723);function a(e){return e.replace(/mso-[a-z-]+:[\s]*[^;]+;/gi,"").replace(/mso-[a-z-]+:[\s]*[^";']+$/gi,"").replace(/border[a-z-]*:[\s]*[^;]+;/gi,"").replace(/([0-9.]+)(pt|cm)/gi,(e,t,i)=>{switch(i.toLowerCase()){case"pt":return(1.328*parseFloat(t)).toFixed(0)+"px";case"cm":return(.02645833*parseFloat(t)).toFixed(0)+"px"}return e})}function l(e){if(-1===e.indexOf("<html "))return e;e=(e=e.substring(e.indexOf("<html "),e.length)).substring(0,e.lastIndexOf("</html>")+7);let t=n.globalDocument.createElement("iframe");t.style.display="none",n.globalDocument.body.appendChild(t);let i="";try{let l=t.contentDocument||(t.contentWindow?t.contentWindow.document:null);if(l){l.open(),l.write(e),l.close();try{for(let e=0;e<l.styleSheets.length;e+=1){let t=l.styleSheets[e].cssRules;for(let e=0;e<t.length;e+=1)""!==t[e].selectorText&&(0,s.$$)(t[e].selectorText,l.body).forEach(i=>{i.style.cssText=a(t[e].style.cssText+";"+i.style.cssText)})}}catch(e){if(!n.IS_PROD)throw e}o.Dom.each(l.body,e=>{if(o.Dom.isElement(e)){let t=e.getAttribute("style");t&&(e.style.cssText=a(t)),e.hasAttribute("style")&&!e.getAttribute("style")&&e.removeAttribute("style")}}),i=l.firstChild?(0,r.trim)(l.body.innerHTML):""}}catch(e){}finally{o.Dom.safeRemove(t)}return i&&(e=i),(0,r.trim)(e.replace(/<(\/)?(html|colgroup|col|o:p)[^>]*>/g,"").replace(/<!--[^>]*>/g,""))}},1277:function(e,t,i){"use strict";i.d(t,{cleanFromWord:function(){return a}});var n=i(81937),o=i(23211),r=i(88475),s=i(4040);function a(e){-1!==e.indexOf("<html ")&&(e=(e=e.substring(e.indexOf("<html "),e.length)).substring(0,e.lastIndexOf("</html>")+7));let t="";try{let i=n.globalDocument.createElement("div");i.innerHTML=e;let s=[];i.firstChild&&o.Dom.each(i,e=>{if(e)switch(e.nodeType){case Node.ELEMENT_NODE:switch(e.nodeName){case"STYLE":case"LINK":case"META":s.push(e);break;case"W:SDT":case"W:SDTPR":case"FONT":o.Dom.unwrap(e);break;default:(0,r.toArray)(e.attributes).forEach(t=>{-1===["src","href","rel","content"].indexOf(t.name.toLowerCase())&&e.removeAttribute(t.name)})}break;case Node.TEXT_NODE:break;default:s.push(e)}}),o.Dom.safeRemove.apply(null,s),t=i.innerHTML}catch(e){}return t&&(e=t),(e=e.split(/(\n)/).filter(s.trim).join("\n")).replace(/<(\/)?(html|colgroup|col|o:p)[^>]*>/g,"").replace(/<!--[^>]*>/g,"")}},6609:function(e,t,i){"use strict";i.d(t,{htmlspecialchars:function(){return o}});var n=i(81937);function o(e){let t=n.globalDocument.createElement("div");return t.textContent=e,t.innerHTML}},82658:function(e,t,i){"use strict";i.d(t,{applyStyles:function(){return n.applyStyles},cleanFromWord:function(){return o.cleanFromWord},htmlspecialchars:function(){return r.htmlspecialchars},nl2br:function(){return s.nl2br},safeHTML:function(){return a.safeHTML},sanitizeHTMLElement:function(){return a.sanitizeHTMLElement},stripTags:function(){return l.stripTags}});var n=i(30893),o=i(1277),r=i(6609),s=i(48838),a=i(48155),l=i(22852)},48838:function(e,t,i){"use strict";function n(e){return e.replace(/\r\n|\r|\n/g,"<br/>")}i.d(t,{nl2br:function(){return n}})},48155:function(e,t,i){"use strict";i.d(t,{safeHTML:function(){return r},sanitizeHTMLElement:function(){return a}});var n=i(23211),o=i(93640);function r(e,t){var i;(n.Dom.isElement(e)||n.Dom.isFragment(e))&&((null!=(i=t.removeEventAttributes)?i:t.removeOnError)?(s(e),(0,o.$$)("*",e).forEach(e=>s(e))):t.removeOnError&&(a(e,t),(0,o.$$)("[onerror]",e).forEach(e=>a(e,t))),t.safeJavaScriptLink&&(a(e,t),(0,o.$$)('a[href^="javascript"]',e).forEach(e=>a(e,t))),t.safeLinksTarget&&(0,o.$$)('a[target="_blank"]',e).forEach(e=>{let t=(e.getAttribute("rel")||"").split(/\s+/).filter(Boolean);t.includes("noopener")||t.push("noopener"),t.includes("noreferrer")||t.push("noreferrer"),(0,o.attr)(e,"rel",t.join(" "))}))}function s(e){if(!n.Dom.isElement(e))return!1;let t=!1,i=[];for(let t=0;t<e.attributes.length;t++)e.attributes[t].name.toLowerCase().startsWith("on")&&i.push(e.attributes[t].name);for(let n of i)e.removeAttribute(n),t=!0;return t}function a(e,{safeJavaScriptLink:t,removeOnError:i}={safeJavaScriptLink:!0,removeOnError:!0}){if(!n.Dom.isElement(e))return!1;let r=!1;i&&e.hasAttribute("onerror")&&((0,o.attr)(e,"onerror",null),r=!0);let s=e.getAttribute("href");return t&&s&&0===s.trim().indexOf("javascript")&&((0,o.attr)(e,"href",location.protocol+"//"+s),r=!0),r}},22852:function(e,t,i){"use strict";i.d(t,{stripTags:function(){return function e(t,i=document,c=null){let d=i.createElement("div");return(0,o.isString)(t)?d.innerHTML=t:d.appendChild(t),(0,s.$$)("*",d).forEach(t=>{let o=t.parentNode;if(!o)return;if(c&&n.Dom.isTag(t,c)){let o=t.nodeName.toLowerCase(),r=n.Dom.isTag(t,u)?`%%%jodit-single-${o}%%%`:`%%%jodit-${o}%%%${e(t.innerHTML,i,c)}%%%/jodit-${o}%%%`;n.Dom.before(t,i.createTextNode(r)),n.Dom.safeRemove(t);return}if(n.Dom.isTag(t,l))return void n.Dom.safeRemove(t);if(!n.Dom.isTag(t,a))return;let r=t.nextSibling;!(n.Dom.isText(r)&&/^\s/.test(r.nodeValue||""))&&r&&o.insertBefore(i.createTextNode(" "),r)}),(0,r.trim)(d.innerText).replace(/%%%(\/)?jodit(-single)?-([\w\n]+)%%%/g,(e,t,i,n)=>`<${t?"/":""}${n}>`)}}});var n=i(23211),o=i(85932),r=i(4040),s=i(93640);let a=new Set(["div","p","br","h1","h2","h3","h4","h5","h6","hr"]),l=new Set(["script","style"]),u=new Set(["br","hr","input"])},65946:function(e,t,i){"use strict";i.r(t),i.d(t,{CamelCaseToKebabCase:function(){return c.CamelCaseToKebabCase},NUMBER_FIELDS_REG:function(){return l.NUMBER_FIELDS_REG},applyStyles:function(){return a.applyStyles},asArray:function(){return n.asArray},camelCase:function(){return c.camelCase},cleanFromWord:function(){return a.cleanFromWord},clearTimeout:function(){return o.clearTimeout},colorToHex:function(){return s.colorToHex},fuzzySearchIndex:function(){return c.fuzzySearchIndex},getContentWidth:function(){return u.getContentWidth},getScrollParent:function(){return u.getScrollParent},hasBrowserColorPicker:function(){return r.hasBrowserColorPicker},hasContainer:function(){return r.hasContainer},htmlspecialchars:function(){return a.htmlspecialchars},i18n:function(){return c.i18n},innerWidth:function(){return u.innerWidth},isAbortError:function(){return r.isAbortError},isArray:function(){return r.isArray},isBoolean:function(){return r.isBoolean},isDestructable:function(){return r.isDestructable},isEqual:function(){return r.isEqual},isFastEqual:function(){return r.isFastEqual},isFunction:function(){return r.isFunction},isHTML:function(){return r.isHTML},isHtmlFromWord:function(){return r.isHtmlFromWord},isInitable:function(){return r.isInitable},isInt:function(){return r.isInt},isJoditObject:function(){return r.isJoditObject},isLicense:function(){return r.isLicense},isMarker:function(){return r.isMarker},isNativeFunction:function(){return r.isNativeFunction},isNumber:function(){return r.isNumber},isNumeric:function(){return r.isNumeric},isPlainObject:function(){return r.isPlainObject},isPromise:function(){return r.isPromise},isSet:function(){return r.isSet},isString:function(){return r.isString},isStringArray:function(){return r.isStringArray},isURL:function(){return r.isURL},isValidName:function(){return r.isValidName},isViewObject:function(){return r.isViewObject},isVoid:function(){return r.isVoid},isWindow:function(){return r.isWindow},kebabCase:function(){return c.kebabCase},nl2br:function(){return a.nl2br},normalizeColor:function(){return l.normalizeColor},normalizeCssNumericValue:function(){return l.normalizeCssNumericValue},normalizeCssValue:function(){return l.normalizeCssValue},normalizeKeyAliases:function(){return l.normalizeKeyAliases},normalizeLicense:function(){return l.normalizeLicense},normalizePath:function(){return l.normalizePath},normalizeRelativePath:function(){return l.normalizeRelativePath},normalizeSize:function(){return l.normalizeSize},normalizeUrl:function(){return l.normalizeUrl},offset:function(){return u.offset},position:function(){return u.position},safeHTML:function(){return a.safeHTML},sanitizeHTMLElement:function(){return a.sanitizeHTMLElement},setTimeout:function(){return o.setTimeout},size:function(){return u.size},splitArray:function(){return n.splitArray},sprintf:function(){return c.sprintf},stringify:function(){return c.stringify},stripTags:function(){return a.stripTags},toArray:function(){return n.toArray},trim:function(){return c.trim},trimChars:function(){return c.trimChars},trimInv:function(){return c.trimInv},ucfirst:function(){return c.ucfirst}});var n=i(45664),o=i(61077),r=i(28686),s=i(7018),a=i(82658),l=i(97022),u=i(86878),c=i(97642),d=i(93640),h={};for(var p in d)0>["default","asArray","splitArray","toArray","clearTimeout","setTimeout","hasBrowserColorPicker","hasContainer","isAbortError","isArray","isBoolean","isDestructable","isEqual","isFastEqual","isFunction","isHTML","isHtmlFromWord","isInitable","isInt","isJoditObject","isLicense","isMarker","isNativeFunction","isNumber","isNumeric","isPlainObject","isPromise","isSet","isString","isStringArray","isURL","isValidName","isViewObject","isVoid","isWindow","colorToHex","applyStyles","cleanFromWord","htmlspecialchars","nl2br","safeHTML","sanitizeHTMLElement","stripTags","NUMBER_FIELDS_REG","normalizeColor","normalizeCssNumericValue","normalizeCssValue","normalizeKeyAliases","normalizeLicense","normalizePath","normalizeRelativePath","normalizeSize","normalizeUrl","getContentWidth","getScrollParent","innerWidth","offset","position","size","CamelCaseToKebabCase","camelCase","fuzzySearchIndex","i18n","kebabCase","sprintf","stringify","trim","trimChars","trimInv","ucfirst"].indexOf(p)&&(h[p]=(function(e){return d[e]}).bind(0,p));i.d(t,h)},97022:function(e,t,i){"use strict";i.d(t,{NUMBER_FIELDS_REG:function(){return o.NUMBER_FIELDS_REG},normalizeColor:function(){return n.normalizeColor},normalizeCssNumericValue:function(){return o.normalizeCssNumericValue},normalizeCssValue:function(){return o.normalizeCssValue},normalizeKeyAliases:function(){return r.normalizeKeyAliases},normalizeLicense:function(){return s.normalizeLicense},normalizePath:function(){return a.normalizePath},normalizeRelativePath:function(){return l.normalizeRelativePath},normalizeSize:function(){return u.normalizeSize},normalizeUrl:function(){return c.normalizeUrl}});var n=i(77367),o=i(19147),r=i(27978),s=i(49663),a=i(18377),l=i(96340),u=i(98831),c=i(48009)},77367:function(e,t,i){"use strict";i.d(t,{normalizeColor:function(){return r}});var n=i(93387),o=i(4040);let r=e=>{let t=["#"],i=(0,n.colorToHex)(e);if(!i)return!1;if(3===(i=(i=(0,o.trim)(i.toUpperCase())).substring(1)).length){for(let e=0;e<3;e+=1)t.push(i[e]),t.push(i[e]);return t.join("")}return i.length>6&&(i=i.slice(0,6)),"#"+i}},19147:function(e,t,i){"use strict";i.d(t,{NUMBER_FIELDS_REG:function(){return a},normalizeCssNumericValue:function(){return l},normalizeCssValue:function(){return u}});var n=i(70222),o=i(18303),r=i(93387),s=i(74264);let a=/^(left|top|bottom|right|width|min|max|height|margin|padding|fontsize|font-size)/i;function l(e,t){return!(0,o.isVoid)(t)&&a.test(e)&&(0,n.isNumeric)(t.toString())?parseInt(t.toString(),10)+"px":t}function u(e,t){if("font-weight"===(0,s.kebabCase)(e)){switch(t.toString().toLowerCase()){case"700":case"bold":return 700;case"400":case"normal":return 400;case"900":case"heavy":return 900}return(0,n.isNumeric)(t)?Number(t):t}return/color/i.test(e)&&/^rgb/i.test(t.toString())&&(0,r.colorToHex)(t.toString())||t}},27978:function(e,t,i){"use strict";i.d(t,{normalizeKeyAliases:function(){return r}});var n=i(81937),o=i(4040);function r(e){let t={},i={meta:1,ctrl:2,control:2,alt:3,shift:4,space:5};return e.replace(/\+\+/g,"+add").split(/[\s]*\+[\s]*/).map(e=>(0,o.trim)(e.toLowerCase())).map(e=>n.KEY_ALIASES[e]||e).sort((e,t)=>i[e]&&!i[t]?-1:!i[e]&&i[t]?1:i[e]&&i[t]?i[e]-i[t]:e>t?1:-1).filter(e=>!t[e]&&""!==e&&(t[e]=!0)).join("+")}},49663:function(e,t,i){"use strict";i.d(t,{normalizeLicense:function(){return n}});let n=(e,t=8)=>{let i=[];for(;e.length;)i.push(e.substr(0,t)),e=e.substr(t);return i[1]=i[1].replace(/./g,"*"),i[2]=i[2].replace(/./g,"*"),i.join("-")}},18377:function(e,t,i){"use strict";i.d(t,{normalizePath:function(){return o}});var n=i(4040);let o=(...e)=>e.filter(e=>(0,n.trim)(e).length).map((t,i)=>(t=t.replace(/([^:])[\\/]+/g,"$1/"),i&&(t=t.replace(/^\//,"")),i!==e.length-1&&(t=t.replace(/\/$/,"")),t)).join("/")},96340:function(e,t,i){"use strict";i.d(t,{normalizeRelativePath:function(){return n}});let n=e=>e.split("/").reduce((e,t)=>{switch(t){case"":case".":break;case"..":e.pop();break;default:e.push(t)}return e},[]).join("/")+(e.endsWith("/")?"/":"")},98831:function(e,t,i){"use strict";i.d(t,{normalizeSize:function(){return n}});let n=(e,t)=>/^[0-9]+$/.test(e.toString())?e+t:e.toString()},48009:function(e,t,i){"use strict";i.d(t,{normalizeUrl:function(){return n}});let n=(...e)=>e.filter(e=>e.length).map(e=>e.replace(/\/$/,"")).join("/").replace(/([^:])[\\/]+/g,"$1/")},54447:function(e,t,i){"use strict";i.d(t,{getContentWidth:function(){return n}});let n=(e,t)=>{let i=t.getComputedStyle(e);return e.offsetWidth-parseInt(i.getPropertyValue("padding-left")||"0",10)-parseInt(i.getPropertyValue("padding-right")||"0",10)}},34027:function(e,t,i){"use strict";i.d(t,{getScrollParent:function(){return function e(t){if(!t)return null;let i=o.Dom.isHTMLElement(t),s=i&&(0,r.css)(t,"overflowY");return i&&"visible"!==s&&"hidden"!==s&&t.scrollHeight>=t.clientHeight?t:e(t.parentNode)||n.globalDocument.scrollingElement||n.globalDocument.body}}});var n=i(81937),o=i(23211),r=i(93640)},86878:function(e,t,i){"use strict";i.d(t,{getContentWidth:function(){return n.getContentWidth},getScrollParent:function(){return o.getScrollParent},innerWidth:function(){return r.innerWidth},offset:function(){return a.offset},position:function(){return l.position},size:function(){return s.size}});var n=i(54447),o=i(34027),r=i(83215),s=i(18073),a=i(69143),l=i(23599)},83215:function(e,t,i){"use strict";i.d(t,{innerWidth:function(){return n}});let n=(e,t)=>{let i=t.getComputedStyle(e);return e.clientWidth-(parseFloat(i.paddingLeft||"0")+parseFloat(i.paddingRight||"0"))}},18073:function(e,t,i){"use strict";i.d(t,{size:function(){return o}});var n=i(28686);function o(e){return(0,n.isString)(e)||(0,n.isArray)(e)?e.length:(0,n.isPlainObject)(e)?Object.keys(e).length:0}},69143:function(e,t,i){"use strict";i.d(t,{offset:function(){return n}});let n=(e,t,i,o=!1)=>{let r,s,a;try{r=e.getBoundingClientRect()}catch(e){r={top:0,bottom:0,left:0,right:0,width:0,height:0}}let l=i.body,u=i.documentElement||{clientTop:0,clientLeft:0,scrollTop:0,scrollLeft:0},c=i.defaultView||i.parentWindow,d=c.pageYOffset||u.scrollTop||l.scrollTop,h=c.pageXOffset||u.scrollLeft||l.scrollLeft,p=u.clientTop||l.clientTop||0,f=u.clientLeft||l.clientLeft||0,m=t.iframe;if(!o&&t&&t.options&&t.o.iframe&&m){let{top:e,left:i}=n(m,t,t.od,!0);s=r.top+e,a=r.left+i}else s=r.top+d-p,a=r.left+h-f;return{top:Math.round(s),left:Math.round(a),width:r.width,height:r.height}}},23599:function(e,t,i){"use strict";i.d(t,{position:function(){return function e(t,i,o=!1){var r,s;let a=t.getBoundingClientRect(),l=a.left,u=a.top;if((0,n.isJoditObject)(i)&&i.iframe&&i.ed.body.contains(t)&&!o){let{left:t,top:n}=e(i.iframe,i,!0);l+=t,u+=n}return{left:Math.round(l),top:Math.round(u),width:Math.round(null!=(r=t.offsetWidth)?r:a.width),height:Math.round(null!=(s=t.offsetHeight)?s:a.height)}}}});var n=i(24497)},57821:function(e,t,i){"use strict";i.d(t,{camelCase:function(){return n}});let n=e=>e.replace(/([-_])(.)/g,(e,t,i)=>i.toUpperCase())},57626:function(e,t,i){"use strict";i.d(t,{fuzzySearchIndex:function(){return o}});var n=i(81937);function o(e,t,i=0,r=1){let s=0,a=0,l=-1,u=0,c=0;for(a=i;s<e.length&&a<t.length;)e[s].toLowerCase()===t[a].toLowerCase()?(s++,u++,c=0,-1===l&&(l=a)):s>0&&(c>=r&&t[a]!==n.INVISIBLE_SPACE?(s=0,l=-1,u=0,c=0,a--):(c++,u++)),a++;return s===e.length?[l,u]:[-1,0]}},18080:function(e,t,i){"use strict";i.d(t,{i18n:function(){return u},sprintf:function(){return l}});var n=i(81937),o=i(85932),r=i(99436),s=i(93640),a=i(5266);let l=(e,t)=>{if(!t||!t.length)return e;let i=/%([sd])/g,n=i.exec(e),o=e,r=0;for(;n&&void 0!==t[r];)o=o.replace(n[0],t[r].toString()),r+=1,n=i.exec(e);return o};function u(e,t,i){if(!(0,o.isString)(e))throw(0,s.error)("i18n: Need string in first argument");if(!e.length)return e;let u=!!(null==i?void 0:i.debugLanguage),c={},d=e=>t&&t.length?l(e,t):e,h=(0,s.defaultLanguage)(a.Config.defaultOptions.language,a.Config.defaultOptions.language),p=(0,s.defaultLanguage)(null==i?void 0:i.language,h),f=t=>{if(!t)return;if((0,o.isString)(t[e]))return d(t[e]);let i=e.toLowerCase();if((0,o.isString)(t[i]))return d(t[i]);let n=(0,r.ucfirst)(e);if((0,o.isString)(t[n]))return d(t[n])};void 0!==n.lang[p]?c=n.lang[p]:u||(c=void 0!==n.lang[h]?n.lang[h]:n.lang.en);let m=null==i?void 0:i.i18n;if(m&&m[p]){let e=f(m[p]);if(e)return e}return f(c)||(!u&&n.lang.en&&(0,o.isString)(n.lang.en[e])&&n.lang.en[e]?d(n.lang.en[e]):u?"{"+e+"}":(n.IS_PROD,d(e)))}},97642:function(e,t,i){"use strict";i.d(t,{CamelCaseToKebabCase:function(){return s.CamelCaseToKebabCase},camelCase:function(){return n.camelCase},fuzzySearchIndex:function(){return o.fuzzySearchIndex},i18n:function(){return r.i18n},kebabCase:function(){return s.kebabCase},sprintf:function(){return r.sprintf},stringify:function(){return a.stringify},trim:function(){return l.trim},trimChars:function(){return l.trimChars},trimInv:function(){return l.trimInv},ucfirst:function(){return u.ucfirst}});var n=i(57821),o=i(57626),r=i(18080),s=i(74264),a=i(3347),l=i(4040),u=i(99436)},74264:function(e,t,i){"use strict";i.d(t,{CamelCaseToKebabCase:function(){return o},kebabCase:function(){return n}});let n=e=>e.replace(/([A-Z])([A-Z])([a-z])/g,"$1-$2$3").replace(/([a-z])([A-Z])/g,"$1-$2").replace(/[\s_]+/g,"-").toLowerCase(),o=e=>e.replace(/([A-Z])([A-Z])([a-z])/g,"$1-$2$3").replace(/([a-z])([A-Z])/g,"$1-$2").toLowerCase()},3347:function(e,t,i){"use strict";function n(e,t={}){if("object"!=typeof e)return String(e);let i=new Set(t.excludeKeys),o=new WeakMap;return JSON.stringify(e,(e,t)=>{if(!i.has(e)){if("object"==typeof t&&null!=t){if(o.get(t))return"[refObject]";o.set(t,!0)}return t}},t.prettify)}i.d(t,{stringify:function(){return n}})},4040:function(e,t,i){"use strict";i.d(t,{trim:function(){return o},trimChars:function(){return r},trimInv:function(){return s}});var n=i(81937);function o(e){return e.replace((0,n.SPACE_REG_EXP_END)(),"").replace((0,n.SPACE_REG_EXP_START)(),"")}function r(e,t){return e.replace(RegExp(`[${t}]+$`),"").replace(RegExp(`^[${t}]+`),"")}function s(e){return e.replace((0,n.INVISIBLE_SPACE_REG_EXP_END)(),"").replace((0,n.INVISIBLE_SPACE_REG_EXP_START)(),"")}},99436:function(e,t,i){"use strict";function n(e){return e.length?e[0].toUpperCase()+e.substring(1):""}i.d(t,{ucfirst:function(){return n}})},16849:function(e,t,i){"use strict";i.d(t,{alignElement:function(){return a},clearAlign:function(){return s},hAlignElement:function(){return r}});var n=i(27795),o=i(80991);function r(e,t){t&&"normal"!==t?"center"!==t?((0,o.css)(e,"float",t),(0,o.clearCenterAlign)(e)):(0,o.css)(e,{float:"",display:"block",marginLeft:"auto",marginRight:"auto"}):((0,o.css)(e,"float")&&-1!==["right","left"].indexOf((0,o.css)(e,"float").toString().toLowerCase())&&(0,o.css)(e,"float",""),(0,o.clearCenterAlign)(e))}function s(e){n.Dom.each(e,e=>{n.Dom.isHTMLElement(e)&&e.style.textAlign&&(e.style.textAlign="",e.style.cssText.trim().length||e.removeAttribute("style"))})}function a(e,t){if(n.Dom.isNode(t)&&n.Dom.isElement(t))switch(s(t),e.toLowerCase()){case"justifyfull":t.style.textAlign="justify";break;case"justifyright":t.style.textAlign="right";break;case"justifyleft":t.style.textAlign="left";break;case"justifycenter":t.style.textAlign="center"}}},47760:function(e,t,i){"use strict";i.d(t,{alreadyLoadedList:function(){return r},appendScriptAsync:function(){return a},appendStyleAsync:function(){return l},loadNext:function(){return function e(t,i,o=0){return(0,n.isString)(i[o])?a(t,i[o]).then(()=>e(t,i,o+1)):Promise.resolve()}},loadNextStyle:function(){return function e(t,i,o=0){return(0,n.isString)(i[o])?l(t,i[o]).then(()=>e(t,i,o+1)):Promise.resolve()}}});var n=i(85932),o=i(91321);let r=new Map,s=e=>(t,i)=>{if(r.has(i))return r.get(i);let n=e(t,i);return r.set(i,n),n},a=s((e,t)=>e.async.promise((i,n)=>{if(e.isInDestruct)return n();let r=e.c.element("script",{type:"text/javascript",crossorigin:"anonymous",referrerpolicy:"no-referrer",async:!0,src:(0,o.completeUrl)(t)});e.e.one(r,"error",n).one(r,"load",i),e.od.body.appendChild(r)})),l=s((e,t)=>e.async.promise((i,n)=>{if(e.isInDestruct)return n();let r=e.c.element("link");r.rel="stylesheet",r.media="all",r.crossOrigin="anonymous",e.isInDestruct||e.e.on(r,"load",()=>i(r)).on(r,"error",n),r.href=(0,o.completeUrl)(t),e.o.shadowRoot?e.o.shadowRoot.appendChild(r):e.od.body.appendChild(r)}))},7909:function(e,t,i){"use strict";i.d(t,{attr:function(){return function e(t,i,l){if(!t||!(0,n.isFunction)(t.getAttribute))return null;if(!(0,r.isString)(i))return Object.keys(i).forEach(n=>{let r=i[n];(0,o.isPlainObject)(r)&&"style"===n?(0,a.css)(t,r):("className"===n&&(n="class"),e(t,n,r))}),null;let u=(0,s.CamelCaseToKebabCase)(i);if(/^-/.test(u)){let i=e(t,`data${u}`);if(i)return i;u=u.substr(1)}if(void 0!==l)if(null==l)t.hasAttribute(u)&&t.removeAttribute(u);else{let e=l.toString();return"IMG"===t.nodeName&&("width"===u||"height"===u)&&(e=e.replace("px","")),t.setAttribute(u,e),e}return t.getAttribute(u)}}});var n=i(91565),o=i(62101),r=i(85932),s=i(74264),a=i(80991)},26136:function(e,t,i){"use strict";i.d(t,{browser:function(){return n}});let n=e=>{let t=navigator.userAgent.toLowerCase(),i=/(firefox)[\s/]([\w.]+)/.exec(t)||/(chrome)[\s/]([\w.]+)/.exec(t)||/(webkit)[\s/]([\w.]+)/.exec(t)||/(opera)(?:.*version)[\s/]([\w.]+)/.exec(t)||/(msie)[\s]([\w.]+)/.exec(t)||/(trident)\/([\w.]+)/.exec(t)||0>t.indexOf("compatible")||[];return"version"===e?i[2]:"webkit"===e?"chrome"===i[1]||"webkit"===i[1]:"ff"===e?"firefox"===i[1]:"msie"===e?"trident"===i[1]||"msie"===i[1]:i[1]===e}},36833:function(e,t,i){"use strict";i.d(t,{buildQuery:function(){return o}});var n=i(62101);let o=(e,t)=>{let i=[],r=encodeURIComponent;for(let s in e)if(Object.prototype.hasOwnProperty.call(e,s)){let a=t?t+"["+s+"]":s,l=e[s];i.push((0,n.isPlainObject)(l)?o(l,a):r(a)+"="+r(l))}return i.join("&")}},91321:function(e,t,i){"use strict";i.d(t,{completeUrl:function(){return o}});var n=i(81937);let o=e=>("file:"===n.globalWindow.location.protocol&&/^\/\//.test(e)&&(e="https:"+e),e)},77483:function(e,t,i){"use strict";i.d(t,{ConfigDeepFlatten:function(){return function e(t){return(0,u.keys)(t,!1).reduce((i,n)=>(i[n]=(0,o.isPlainObject)(t[n])?e(t[n]):t[n],i),{})}},ConfigFlatten:function(){return c},ConfigMerge:function(){return function e(t,i){Object.keys(i).forEach(n=>{let r=i[n],s=t[n];(0,o.isPlainObject)(r)&&(0,o.isPlainObject)(s)&&!(0,l.isAtom)(r)?e(s,r):t[n]=r})}},ConfigProto:function(){return function e(t,i,u=0){if(Object.getPrototypeOf(t)!==Object.prototype)return t;let c=a.Config.defaultOptions;if((0,r.isString)(t.preset)){if(void 0!==c.presets[t.preset]){let e=c.presets[t.preset];Object.keys(e).forEach(i=>{(0,s.isVoid)(t[i])&&(t[i]=e[i])})}delete t.preset}let d={};return Object.keys(t).forEach(r=>{let s=t[r],a=i?i[r]:null;if((0,o.isPlainObject)(s)&&(0,o.isPlainObject)(a)&&!(0,l.isAtom)(s)){d[r]=e(s,a,u+1);return}if(0!==u&&(0,n.isArray)(s)&&!(0,l.isAtom)(s)&&(0,n.isArray)(a)){d[r]=[...s,...a.slice(s.length)];return}d[r]=s}),Object.setPrototypeOf(d,i),d}}});var n=i(17312),o=i(62101),r=i(85932),s=i(18303),a=i(5266),l=i(54794),u=i(71125);function c(e){return(0,u.keys)(e,!1).reduce((t,i)=>(t[i]=e[i],t),{})}},3856:function(e,t,i){"use strict";i.d(t,{convertMediaUrlToVideoEmbed:function(){return s}});var n=i(81937),o=i(91764),r=i(36310);let s=(e,{width:t=400,height:i=345}={})=>{if(!(0,o.isURL)(e))return e;let s=n.globalDocument.createElement("a"),a=/(?:http?s?:\/\/)?(?:www\.)?(?:vimeo\.com)\/?(.+)/g;s.href=e,t||(t=400),i||(i=345);let l=s.protocol||"";switch(s.hostname){case"www.vimeo.com":case"vimeo.com":return a.test(e)?e.replace(a,'<iframe width="'+t+'" height="'+i+'" src="'+l+'//player.vimeo.com/video/$1" frameborder="0" allowfullscreen></iframe>'):e;case"youtube.com":case"www.youtube.com":case"youtu.be":case"www.youtu.be":{let n=s.search?(0,r.parseQuery)(s.search):{v:s.pathname.substring(1)};return/^embed\/.*/.test(n.v)&&(n.v=n.v.substring(6)),n.v?'<iframe width="'+t+'" height="'+i+'" src="'+l+"//www.youtube.com/embed/"+n.v+'" frameborder="0" allowfullscreen></iframe>':e}}return e}},80991:function(e,t,i){"use strict";i.d(t,{clearCenterAlign:function(){return u},css:function(){return l}});var n=i(22289),o=i(62101),r=i(19147),s=i(57821),a=i(74264);function l(e,t,i,u=!1){if((0,n.isBoolean)(i)&&(u=i,i=void 0),(0,o.isPlainObject)(t)||void 0!==i){let n=(e,t,i)=>{void 0!==(i=(0,r.normalizeCssNumericValue)(t,i))&&(null==i||l(e,t,!0)!==(0,r.normalizeCssValue)(t,i))&&(e.style[t]=i)};if((0,o.isPlainObject)(t)){let i=Object.keys(t);for(let o=0;o<i.length;o+=1)n(e,(0,s.camelCase)(i[o]),t[i[o]])}else n(e,(0,s.camelCase)(t),i);return""}let c=(0,a.kebabCase)(t),d=e.ownerDocument||document,h=!!d&&(d.defaultView||d.parentWindow),p=e.style[t],f="";return void 0!==p&&""!==p?f=p:h&&!u&&(f=h.getComputedStyle(e).getPropertyValue(c)),r.NUMBER_FIELDS_REG.test(t)&&/^[-+]?[0-9.]+px$/.test(f.toString())&&(f=parseInt(f.toString(),10)),(0,r.normalizeCssValue)(t,f)}let u=e=>{"block"===l(e,"display")&&l(e,"display","");let{style:t}=e;"auto"===t.marginLeft&&"auto"===t.marginRight&&(t.marginLeft="",t.marginRight="")}},77213:function(e,t,i){"use strict";i.d(t,{ctrlKey:function(){return n}});let n=e=>{if("u">typeof navigator&&-1!==navigator.userAgent.indexOf("Mac OS X")){if(e.metaKey&&!e.altKey)return!0}else if(e.ctrlKey&&!e.altKey)return!0;return!1}},36400:function(e,t,i){"use strict";i.d(t,{dataBind:function(){return r}});var n=i(31534);let o=new WeakMap,r=(e,t,i)=>{let r=o.get(e);if(!r){r={},o.set(e,r);let t=null;(0,n.isViewObject)(e.j)&&(t=e.j.e),(0,n.isViewObject)(e)&&(t=e.e),t&&t.on("beforeDestruct",()=>{o.delete(e)})}return void 0===i?r[t]:(r[t]=i,i)}},97228:function(e,t,i){"use strict";i.d(t,{defaultLanguage:function(){return r}});var n=i(81937),o=i(85932);let r=(e,t="en")=>"auto"!==e&&(0,o.isString)(e)?e:n.globalDocument.documentElement&&n.globalDocument.documentElement.lang?n.globalDocument.documentElement.lang:navigator.language?navigator.language.substring(0,2):t},38027:function(e,t,i){"use strict";i.d(t,{connection:function(){return r},error:function(){return o},options:function(){return s}});var n=i(29953);function o(e){return TypeError(e)}function r(e){return new n.ConnectionError(e)}function s(e){return new n.OptionsError(e)}},14228:function(e,t,i){"use strict";function n(e="Aborted"){return new DOMException(e,"AbortError")}i.d(t,{abort:function(){return n}})},58250:function(e,t,i){"use strict";i.d(t,{ConnectionError:function(){return n}});class n extends Error{constructor(e){super(e),Object.setPrototypeOf(this,n.prototype)}}},29953:function(e,t,i){"use strict";i.d(t,{ConnectionError:function(){return o.ConnectionError},OptionsError:function(){return r.OptionsError},abort:function(){return n.abort}});var n=i(14228),o=i(58250),r=i(11080)},11080:function(e,t,i){"use strict";i.d(t,{OptionsError:function(){return n}});class n extends TypeError{constructor(e){super(e),Object.setPrototypeOf(this,n.prototype)}}},33201:function(e,t,i){"use strict";i.d(t,{ConnectionError:function(){return o.ConnectionError},OptionsError:function(){return o.OptionsError},abort:function(){return o.abort},connection:function(){return n.connection},error:function(){return n.error},options:function(){return n.options}});var n=i(38027),o=i(29953)},54794:function(e,t,i){"use strict";i.d(t,{fastClone:function(){return s},isAtom:function(){return o},markAsAtomic:function(){return r}});var n=i(3347);function o(e){return e&&e.isAtom}function r(e){return Object.defineProperty(e,"isAtom",{enumerable:!1,value:!0,configurable:!1}),e}function s(e){return JSON.parse((0,n.stringify)(e))}},421:function(e,t,i){"use strict";i.d(t,{getClassName:function(){return r},keepNames:function(){return o}});var n=i(91565);let o=new Map,r=e=>{var t;if((0,n.isFunction)(e.className))return e.className();let i=(null==(t=e.constructor)?void 0:t.originalConstructor)||e.constructor;if(o.has(i))return o.get(i);if(i.name)return i.name;let r=new RegExp(/^\s*function\s*(\S*)\s*\(/),s=i.toString().match(r);return s?s[1]:""}},89308:function(e,t,i){"use strict";i.d(t,{get:function(){return r}});var n=i(85932),o=i(18303);function r(e,t){if(!(0,n.isString)(e)||!e.length)return null;let i=e.split("."),r=t;try{for(let e of i){if((0,o.isVoid)(r[e]))return null;r=r[e]}}catch(e){return null}return(0,o.isVoid)(r)?null:r}},37427:function(e,t,i){"use strict";i.d(t,{humanSizeToBytes:function(){return n}});let n=e=>{if(/^[0-9.]+$/.test(e.toString()))return parseFloat(e);let t=e.substr(-2,2).toUpperCase(),i=["KB","MB","GB","TB"],n=parseFloat(e.substr(0,e.length-2));return -1!==i.indexOf(t)?n*Math.pow(1024,i.indexOf(t)+1):parseInt(e,10)}},93640:function(e,t,i){"use strict";i.r(t),i.d(t,{$$:function(){return x.$$},ConfigDeepFlatten:function(){return h.ConfigDeepFlatten},ConfigFlatten:function(){return h.ConfigFlatten},ConfigMerge:function(){return h.ConfigMerge},ConfigProto:function(){return h.ConfigProto},ConnectionError:function(){return _.ConnectionError},LimitedStack:function(){return j.LimitedStack},OptionsError:function(){return _.OptionsError},abort:function(){return _.abort},alignElement:function(){return n.alignElement},alreadyLoadedList:function(){return o.alreadyLoadedList},appendScriptAsync:function(){return o.appendScriptAsync},appendStyleAsync:function(){return o.appendStyleAsync},attr:function(){return l.attr},browser:function(){return u.browser},buildQuery:function(){return c.buildQuery},call:function(){return z.call},callPromise:function(){return z.callPromise},callThis:function(){return z.callThis},clearAlign:function(){return n.clearAlign},clearCenterAlign:function(){return f.clearCenterAlign},cns:function(){return C.cns},completeUrl:function(){return d.completeUrl},connection:function(){return _.connection},convertMediaUrlToVideoEmbed:function(){return p.convertMediaUrlToVideoEmbed},css:function(){return f.css},cssPath:function(){return x.cssPath},ctrlKey:function(){return m.ctrlKey},dataBind:function(){return g.dataBind},defaultLanguage:function(){return v.defaultLanguage},error:function(){return _.error},fastClone:function(){return b.fastClone},get:function(){return y.get},getClassName:function(){return S.getClassName},getDataTransfer:function(){return z.getDataTransfer},getPropertyDescriptor:function(){return z.getPropertyDescriptor},getXPathByElement:function(){return x.getXPathByElement},hAlignElement:function(){return n.hAlignElement},humanSizeToBytes:function(){return w.humanSizeToBytes},inView:function(){return T.inView},isAtom:function(){return b.isAtom},keepNames:function(){return S.keepNames},keys:function(){return z.keys},loadImage:function(){return z.loadImage},loadNext:function(){return o.loadNext},loadNextStyle:function(){return o.loadNextStyle},markAsAtomic:function(){return b.markAsAtomic},markDeprecated:function(){return C.markDeprecated},markOwner:function(){return z.markOwner},memorizeExec:function(){return z.memorizeExec},options:function(){return _.options},parseQuery:function(){return k.parseQuery},previewBox:function(){return E.previewBox},refs:function(){return x.refs},reset:function(){return I.reset},resolveElement:function(){return x.resolveElement},scrollIntoViewIfNeeded:function(){return T.scrollIntoViewIfNeeded},set:function(){return D.set}});var n=i(16849),o=i(47760),r=i(28712),s={};for(var a in r)0>["default","alignElement","clearAlign","hAlignElement","alreadyLoadedList","appendScriptAsync","appendStyleAsync","loadNext","loadNextStyle"].indexOf(a)&&(s[a]=(function(e){return r[e]}).bind(0,a));i.d(t,s);var l=i(7909),u=i(26136),c=i(36833),d=i(91321),h=i(77483),p=i(3856),f=i(80991),m=i(77213),g=i(36400),v=i(97228),_=i(33201),b=i(54794),y=i(89308),S=i(421),w=i(37427),C=i(49385),k=i(36310),E=i(57075),I=i(43379),T=i(60898),x=i(28723),D=i(52144),j=i(42820),z=i(71125)},49385:function(e,t,i){"use strict";i.d(t,{cns:function(){return n},markDeprecated:function(){return o}});let n=console;function o(e,t=[""],i=null){return(...o)=>(n.warn(`Method "${t[0]}" deprecated.`+(t[1]?` Use "${t[1]}" instead`:"")),e.call(i,...o))}},36310:function(e,t,i){"use strict";i.d(t,{parseQuery:function(){return n}});let n=e=>{let t={},i=e.substring(1).split("&");for(let e=0;e<i.length;e+=1){let n=i[e].split("=");t[decodeURIComponent(n[0])]=decodeURIComponent(n[1]||"")}return t}},57075:function(e,t,i){"use strict";i.d(t,{previewBox:function(){return l}});var n=i(23211),o=i(85932),r=i(7909),s=i(80991),a=i(28723);function l(e,t,i="px",u=null){let c=[],d=function(e,t){let i=[];try{(0,a.$$)("img",e.editor).forEach(o=>{let s=[(0,r.attr)(o,"width"),(0,r.attr)(o,"height"),o.src];(0,r.attr)(o,{width:o.offsetWidth+t,height:o.offsetHeight+t});let a=e.createInside.a();e.ed.body.appendChild(a),a.href=o.src,o.src=a.href,n.Dom.safeRemove(a),i.push(()=>{var e;o.src=null!=(e=s[2])?e:"",(0,r.attr)(o,{width:s[0]||null,height:s[1]||null})})})}catch(e){throw i.forEach(e=>e()),i.length=0,e}return i}(e,i);try{let a=e.e.fire("beforePreviewBox",t,i);if(null!=a)return a;let l=e.c.div("jodit__preview-box jodit-context");u&&u.appendChild(l),(0,s.css)(l,{position:"relative",padding:16});let d=e.value||`<div style='position: absolute;left:50%;top:50%;transform: translateX(-50%) translateY(-50%);color:#ccc;'>${e.i18n("Empty")}</div>`;if(e.iframe){let t=e.create.element("iframe");(0,s.css)(t,{minWidth:800,minHeight:600,border:0}),l.appendChild(t);let i=t.contentWindow;if(i&&(e.e.fire("generateDocumentStructure.iframe",i.document,e),l=i.document.body,"function"==typeof ResizeObserver)){let n=!1,o=i.document.body,r=new ResizeObserver(e.async.debounce(()=>{r.unobserve(o),t.style.height=`${o.offsetHeight+20}px`,e.async.requestAnimationFrame(()=>{n||r.observe(o)})},100)),s=()=>{n=!0,r.unobserve(o),r.disconnect(),e.e.off("beforeDestruct",s)};c.push(s),e.e.on("beforeDestruct",s)}}else(0,s.css)(l,{minWidth:1024,minHeight:600,border:0});let h=(t,i)=>{let s=(0,o.isString)(i)?e.c.div():i;(0,o.isString)(i)&&(s.innerHTML=i);for(let e=0;e<s.childNodes.length;e+=1){let i=s.childNodes[e];if(n.Dom.isElement(i)){let e=t.ownerDocument.createElement(i.nodeName);for(let t=0;t<i.attributes.length;t+=1)(0,r.attr)(e,i.attributes[t].nodeName,i.attributes[t].nodeValue);0===i.childNodes.length||n.Dom.isTag(i,"table")?"SCRIPT"===i.nodeName?i.textContent&&(e.textContent=i.textContent):i.innerHTML&&(e.innerHTML=i.innerHTML):h(e,i);try{t.appendChild(e)}catch(e){}}else try{t.appendChild(i.cloneNode(!0))}catch(e){}}};return h(l,d),e.e.fire("afterPreviewBox",l),[l,()=>{c.forEach(e=>e())}]}finally{d.forEach(e=>e())}}},43379:function(e,t,i){"use strict";i.d(t,{reset:function(){return a}});var n=i(81937),o=i(91565),r=i(89308);let s={};function a(e){var t,i;if(!(e in s)){let t=n.globalDocument.createElement("iframe");try{if(t.src="about:blank",n.globalDocument.body.appendChild(t),!t.contentWindow)return null;let i=(0,r.get)(e,t.contentWindow),a=(0,r.get)(e.split(".").slice(0,-1).join("."),t.contentWindow);(0,o.isFunction)(i)&&(s[e]=i.bind(a))}catch(e){if(!n.IS_PROD)throw e}finally{null==(i=t.parentNode)||i.removeChild(t)}}return null!=(t=s[e])?t:null}},60898:function(e,t,i){"use strict";i.d(t,{inView:function(){return o},scrollIntoViewIfNeeded:function(){return r}});var n=i(23211);function o(e,t,i){let n=e.getBoundingClientRect(),o=e,r=n.top,s=n.height;for(;o&&o!==t&&o.parentNode;)if(!(r<=(n=(o=o.parentNode).getBoundingClientRect()).bottom)||r+s<=n.top)return!1;return r<=(i.documentElement&&i.documentElement.clientHeight||0)}function r(e,t,i){n.Dom.isHTMLElement(e)&&!o(e,t,i)&&(t.clientHeight!==t.scrollHeight&&(t.scrollTop=e.offsetTop),o(e,t,i)||e.scrollIntoView())}},28723:function(e,t,i){"use strict";i.d(t,{$$:function(){return d},cssPath:function(){return f},getXPathByElement:function(){return h},refs:function(){return p},resolveElement:function(){return m}});var n=i(81937),o=i(23211),r=i(88475),s=i(85932),a=i(57821),l=i(7909),u=i(33201);let c=1;function d(e,t){let i;if(!n.IS_ES_NEXT&&/:scope/.test(e)&&n.IS_IE&&!(t&&t.nodeType===Node.DOCUMENT_NODE)){let n=t.id,o=n||"_selector_id_"+String(Math.random()).slice(2)+ ++c;e=e.replace(/:scope/g,"#"+o),n||t.setAttribute("id",o),i=t.parentNode.querySelectorAll(e),n||t.removeAttribute("id")}else i=t.querySelectorAll(e);return[].slice.call(i)}let h=(e,t)=>{if(!e||e.nodeType!==Node.ELEMENT_NODE||!e.parentNode||t===e)return"";if(e.id)return"//*[@id='"+e.id+"']";let i=[].filter.call(e.parentNode.childNodes,t=>t.nodeName===e.nodeName);return h(e.parentNode,t)+"/"+e.nodeName.toLowerCase()+(i.length>1?"["+((0,r.toArray)(i).indexOf(e)+1)+"]":"")},p=e=>("container"in e&&(e=e.container),d("[ref],[data-ref]",e).reduce((e,t)=>{let i=(0,l.attr)(t,"-ref");return i&&(0,s.isString)(i)&&(e[(0,a.camelCase)(i)]=t,e[i]=t),e},{})),f=e=>{if(!o.Dom.isElement(e))return null;let t=[],i=e;for(;i&&i.nodeType===Node.ELEMENT_NODE;){let e=i.nodeName.toLowerCase();if(i.id){e+="#"+i.id,t.unshift(e);break}{let t=i,n=1;do(t=t.previousElementSibling)&&t.nodeName.toLowerCase()===e&&n++;while(t);e+=":nth-of-type("+n+")"}t.unshift(e),i=i.parentNode}return t.join(" > ")};function m(e,t){let i=e;if((0,s.isString)(e))try{i=t.querySelector(e)}catch(t){throw(0,u.error)('String "'+e+'" should be valid HTML selector')}if(!i||"object"!=typeof i||!o.Dom.isElement(i)||!i.cloneNode)throw(0,u.error)('Element "'+e+'" should be string or HTMLElement instance');return i}},52144:function(e,t,i){"use strict";i.d(t,{set:function(){return a}});var n=i(17312),o=i(70222),r=i(62101),s=i(85932);function a(e,t,i){if(!(0,s.isString)(e)||!e.length)return;let a=e.split("."),l=i,u=a[0];for(let e=0;e<a.length-1;e+=1)u=a[e],(0,n.isArray)(l[u])||(0,r.isPlainObject)(l[u])||(l[u]=(0,o.isNumeric)(a[e+1])?[]:{}),l=l[u];l&&(l[a[a.length-1]]=t)}},42820:function(e,t,i){"use strict";i.d(t,{LimitedStack:function(){return o}});var n=i(25045);class o{push(e){return this.stack.push(e),this.stack.length>this.limit&&this.stack.shift(),this}pop(){return this.stack.pop()}find(e){return this.stack.find(e)}constructor(e){(0,n._)(this,"limit",void 0),(0,n._)(this,"stack",void 0),this.limit=e,this.stack=[]}}},71125:function(e,t,i){"use strict";i.d(t,{call:function(){return a},callPromise:function(){return c},callThis:function(){return l},getDataTransfer:function(){return f},getPropertyDescriptor:function(){return m},keys:function(){return h},loadImage:function(){return d},markOwner:function(){return u},memorizeExec:function(){return p}});var n=i(52100),o=i(18303),r=i(7909),s=i(36400);function a(e,...t){return e(...t)}function l(e,t,...i){return e.apply(t,i)}function u(e,t){(0,r.attr)(t,"data-editor_id",e.id),t.component||Object.defineProperty(t,"jodit",{value:e})}function c(e,t){return(0,n.isPromise)(e)?e.then(e=>e,()=>null).finally(t):null==t?void 0:t()}let d=(e,t)=>t.async.promise((i,n)=>{let o=new Image,r=()=>{t.e.off(o),null==n||n()},s=()=>{t.e.off(o),i(o)};t.e.one(o,"load",s).one(o,"error",r).one(o,"abort",r),o.src=e,o.complete&&s()}),h=(e,t=!0)=>{if(t)return Object.keys(e);let i=[];for(let t in e)i.push(t);return i},p=(e,t,{control:i},n)=>{var r;let a=`button${i.command}`,l=null!=(r=i.args&&i.args[0])?r:(0,s.dataBind)(e,a);if((0,o.isVoid)(l))return!1;(0,s.dataBind)(e,a,l),n&&(l=n(l)),e.execCommand(i.command,!1,null!=l?l:void 0)},f=e=>{if(e.clipboardData)return e.clipboardData;try{return e.dataTransfer||new DataTransfer}catch(e){return null}};function m(e,t){let i;do i=Object.getOwnPropertyDescriptor(e,t),e=Object.getPrototypeOf(e);while(!i&&e);return i}},55810:function(e,t,i){"use strict";i.d(t,{init:function(){return s}});var n=i(81937),o=i(52433),r=i(3050);function s(e,t,i,s,a,l,u){if((0,o.isInitable)(s))try{s.init(e)}catch(e){if(!n.IS_PROD)throw e}a.set(t,s),l.delete(t),s.hasStyle&&(0,r.loadStyle)(e,t).catch(e=>{n.IS_PROD}),s.styles&&(u(e,t,"style").innerHTML=s.styles)}},3050:function(e,t,i){"use strict";i.d(t,{loadExtras:function(){return c},loadStyle:function(){return l}});var n=i(81937),o=i(74264),r=i(47760),s=i(86189);let a=new Set;async function l(e,t){let i=u(e,t,!1);if(!a.has(i))return a.add(i),(0,r.appendStyleAsync)(e,i)}function u(e,t,i){t=(0,o.kebabCase)(t);let n=e.minified?".min":"";return e.basePath+"plugins/"+t+"/"+t+n+"."+(i?"js":"css")}function c(e,t,i,o){try{let n=i.filter(t=>!e.has((0,s.normalizeName)(t.name)));n.length&&n.map(e=>{let i=e.url||u(t,e.name,!0);return(0,r.appendScriptAsync)(t,i).then(o).catch(()=>null)})}catch(e){if(!n.IS_PROD)throw e}}},25974:function(e,t,i){"use strict";i.d(t,{makeInstance:function(){return r}});var n=i(81937),o=i(91565);function r(e,t){try{try{return(0,o.isFunction)(t)?new t(e):t}catch(i){if((0,o.isFunction)(t)&&!t.prototype)return t(e)}}catch(e){if(!n.IS_PROD)throw e}return null}},86189:function(e,t,i){"use strict";i.d(t,{normalizeName:function(){return o}});var n=i(74264);function o(e){return(0,n.kebabCase)(e).toLowerCase()}},91206:function(e,t,i){"use strict";i.d(t,{Plugin:function(){return n.Plugin}});var n=i(18855);i(85305)},85305:function(e,t,i){"use strict";i.d(t,{PluginSystem:function(){return f}});var n=i(25045),o=i(81937),r=i(42689),s=i(32328),a=i(17312),l=i(52433),u=i(85932),c=i(55810),d=i(3050),h=i(25974),p=i(86189);class f{get size(){return this.__items.size}add(e,t){this.__items.set((0,p.normalizeName)(e),t),r.eventEmitter.fire(`plugin:${e}:ready`)}get(e){return this.__items.get((0,p.normalizeName)(e))}remove(e){this.__items.delete((0,p.normalizeName)(e))}__getFullPluginsList(e){let t=[];return this.__items.forEach((i,n)=>{(!e||e.has(n))&&t.push([n,i])}),t}__init(e){let{extraList:t,disableList:i,filter:n}={extraList:e.o.extraPlugins.map(e=>(0,u.isString)(e)?{name:e}:e),disableList:new Set((0,s.splitArray)(e.o.disablePlugins).map(p.normalizeName)),filter:e.o.safeMode?new Set(e.o.safePluginsList):null},r=new Map,f={},m=new Set;e.__plugins=f;let g=()=>{if(e.isInDestruct)return;let t=!1;this.__getFullPluginsList(n).forEach(([n,o])=>{if(i.has(n)||r.has(n))return;let s=null==o?void 0:o.requires;if(s&&(0,a.isArray)(s)&&s.length){if(s.some(e=>i.has(e)))return;if(!s.every(e=>r.has(e)))return void m.add(n)}t=!0;let l=(0,h.makeInstance)(e,o);if(!l){r.set(n,null),m.delete(n);return}(0,c.init)(e,n,o,l,r,m,this.opts.getContainer),f[n]=l}),t&&(e.e.fire("updatePlugins"),g())};t&&t.length&&(0,d.loadExtras)(this.__items,e,t,g),g(),e.e.on("beforeDestruct",()=>{Object.keys(f).forEach(t=>{let i=f[t];(0,l.isDestructable)(i)&&i.destruct(e),delete f[t]}),delete e.__plugins}),o.IS_PROD||m.size}wait(e){return new Promise(t=>{if(this.get(e))return t();let i=()=>{t(),r.eventEmitter.off(`plugin:${e}:ready`,i)};r.eventEmitter.on(`plugin:${e}:ready`,i)})}constructor(e){(0,n._)(this,"opts",void 0),(0,n._)(this,"__items",void 0),this.opts=e,this.__items=new Map}}},18855:function(e,t,i){"use strict";i.d(t,{Plugin:function(){return l}});var n=i(25045),o=i(31635),r=i(16964),s=i(84839),a=i(24497);class l extends r.ViewComponent{className(){return"Plugin"}__afterPluginSystemInit(){let{j:e,buttons:t}=this;t&&(0,a.isJoditObject)(e)&&t.forEach(t=>{e.registerButton(t)})}__afterInit(){this.__inited=!0,this.setStatus(r.STATUSES.ready),this.afterInit(this.jodit)}init(e){this.jodit.isReady&&(this.afterInit(this.jodit),this.__afterPluginSystemInit(),this.jodit.e.fire("rebuildToolbar"))}__beforeDestruct(){if(this.isInDestruct)return;let{j:e}=this;if(e.e.off("afterPluginSystemInit",this.__afterPluginSystemInit).off("afterInit",this.__afterInit).off("beforeDestruct",this.destruct),this.setStatus(r.STATUSES.beforeDestruct),!this.__inited)return super.destruct();if((0,a.isJoditObject)(e)){var t;null==(t=this.buttons)||t.forEach(t=>{null==e||e.unregisterButton(t)})}this.beforeDestruct(this.j),super.destruct()}constructor(e){super(e),(0,n._)(this,"buttons",[]),(0,n._)(this,"hasStyle",!1),(0,n._)(this,"styles",void 0),(0,n._)(this,"__inited",!1),e.e.on("afterPluginSystemInit",this.__afterPluginSystemInit).on("afterInit",this.__afterInit).on("beforeDestruct",this.__beforeDestruct)}}(0,n._)(l,"requires",[]),(0,o.__decorate)([s.autobind],l.prototype,"__afterPluginSystemInit",null),(0,o.__decorate)([s.autobind],l.prototype,"__afterInit",null),(0,o.__decorate)([s.autobind],l.prototype,"__beforeDestruct",null)},17338:function(e,t,i){"use strict";i.d(t,{Ajax:function(){return h}});var n=i(25045),o=i(31635),r=i(91231),s=i(81937),a=i(49574),l=i(65946),u=i(33201),c=i(5266);i(37102);var d=i(32855);class h{className(){return"Ajax"}__buildParams(e,t){return(0,l.isPlainObject)(e)&&this.options.contentType&&this.options.contentType.includes("application/json")?JSON.stringify(e):(0,l.isFunction)(this.o.queryBuild)?this.o.queryBuild.call(this,e,t):(0,l.isString)(e)||e instanceof s.globalWindow.FormData||"object"==typeof e&&null!=e&&(0,l.isFunction)(e.append)?e:(0,l.buildQuery)(e)}get o(){return this.options}abort(){if(this.__isFulfilled)return this;try{this.__isFulfilled=!0,this.xhr.abort()}catch(e){}return this}send(){this.__activated=!0;let{xhr:e,o:t}=this,i=this.prepareRequest();return this.__async.promise(async(n,o)=>{var r;let s=()=>{this.__isFulfilled=!0,o(u.connection("Connection error"))},a=()=>{this.__isFulfilled=!0,n(new d.Response(i,e.status,e.statusText,!e.responseType?e.responseText:e.response))};e.onload=a,e.onabort=()=>{this.__isFulfilled=!0,o(u.abort("Abort connection"))},e.onerror=s,e.ontimeout=s,t.responseType&&(e.responseType=t.responseType),e.onprogress=e=>{var t,i;let n=0;e.lengthComputable&&(n=e.loaded/e.total*100),null==(t=(i=this.options).onProgress)||t.call(i,n)},e.onreadystatechange=()=>{var i,n;null==(i=(n=this.options).onProgress)||i.call(n,10),e.readyState===XMLHttpRequest.DONE&&(t.successStatuses.includes(e.status)?a():e.statusText&&(this.__isFulfilled=!0,o(u.connection(e.statusText))))},e.withCredentials=null!=(r=t.withCredentials)&&r;let{url:c,data:h,method:p}=i;e.open(p,c,!0),t.contentType&&e.setRequestHeader&&e.setRequestHeader("Content-type",t.contentType);let{headers:f}=t;(0,l.isFunction)(f)&&(f=await f.call(this)),f&&e.setRequestHeader&&Object.keys(f).forEach(t=>{e.setRequestHeader(t,f[t])}),this.__async.setTimeout(()=>{e.send(h?this.__buildParams(h):void 0)},0)})}async *stream(){var e;this.__activated=!0;let{xhr:t,o:i}=this,n=this.prepareRequest(),o=0,r="",s=[],a=null,c=!1,d=null,h=()=>{if(a){let e=a;a=null,e()}},p=e=>{var i;let n=t.responseText;r+=n.substring(o),o=n.length;let a=r.split("\n\n");for(let t of(r=e?"":null!=(i=a.pop())?i:"",a)){let e=t.trim();if(!e)continue;let i=[];for(let t of e.split("\n"))t.startsWith("data: ")?i.push(t.slice(6)):t.startsWith("data:")&&i.push(t.slice(5));i.length&&s.push(i.join("\n"))}h()};t.onprogress=()=>p(!1),t.onload=()=>{p(!0),c=!0,this.__isFulfilled=!0,h()},t.onerror=()=>{d=u.connection("Connection error"),c=!0,this.__isFulfilled=!0,h()},t.onabort=()=>{d=u.abort("Abort connection"),c=!0,this.__isFulfilled=!0,h()},t.withCredentials=null!=(e=i.withCredentials)&&e;let{url:f,data:m,method:g}=n;t.open(g,f,!0),i.contentType&&t.setRequestHeader&&t.setRequestHeader("Content-type",i.contentType);let{headers:v}=i;(0,l.isFunction)(v)&&(v=await v.call(this)),v&&t.setRequestHeader&&Object.keys(v).forEach(e=>{t.setRequestHeader(e,v[e])}),t.send(m?this.__buildParams(m):void 0);try{for(;;)if(s.length>0)yield s.shift();else if(c)break;else await new Promise(e=>{a=e})}finally{this.__isFulfilled||this.abort()}if(d)throw d}prepareRequest(){if(!this.o.url)throw u.error("Need URL for AJAX request");let e=this.o.url,t=this.o.data,i=(this.o.method||"get").toLowerCase();if("get"===i&&t&&(0,l.isPlainObject)(t)){let i=e.indexOf("?");if(-1!==i){let n=(0,l.parseQuery)(e);e=e.substring(0,i)+"?"+(0,l.buildQuery)({...n,...t})}else e+="?"+(0,l.buildQuery)(this.o.data)}let n={url:e,method:i,data:t};return h.log.splice(100),h.log.push(n),n}destruct(){this.__isDestructed||(this.__isDestructed=!0,this.__activated&&!this.__isFulfilled&&(this.abort(),this.__isFulfilled=!0),this.__async.destruct())}constructor(e,t=c.Config.prototype.defaultAjaxOptions){(0,n._)(this,"__async",new r.Async),(0,n._)(this,"xhr",void 0),(0,n._)(this,"options",void 0),(0,n._)(this,"__isFulfilled",!1),(0,n._)(this,"__activated",!1),(0,n._)(this,"__isDestructed",!1),this.options=(0,l.ConfigProto)(e||{},t),this.xhr=this.o.xhr?this.o.xhr():new XMLHttpRequest}}(0,n._)(h,"log",[]),(0,o.__decorate)([a.autobind],h.prototype,"destruct",null)},37102:function(e,t,i){"use strict";i(5266).Config.prototype.defaultAjaxOptions={successStatuses:[200,201,202],method:"GET",url:"",data:null,contentType:"application/x-www-form-urlencoded; charset=UTF-8",headers:{"X-REQUESTED-WITH":"XMLHttpRequest"},withCredentials:!1,xhr(){return new XMLHttpRequest}}},73714:function(e,t,i){"use strict";i.d(t,{Ajax:function(){return n.Ajax},Response:function(){return o.Response}});var n=i(17338),o=i(32855)},32855:function(e,t,i){"use strict";i.d(t,{Response:function(){return o}});var n=i(25045);class o{get url(){return this.request.url}async json(){return JSON.parse(this.body)}text(){return Promise.resolve(this.body)}async blob(){return this.body}constructor(e,t,i,o){(0,n._)(this,"status",void 0),(0,n._)(this,"statusText",void 0),(0,n._)(this,"request",void 0),(0,n._)(this,"body",void 0),this.request=e,this.status=t,this.statusText=i,this.body=o}}},42259:function(e,t,i){"use strict";i.d(t,{cursorInTheEdgeOfString:function(){return s},findCorrectCurrentNode:function(){return a},moveNodeInsideStart:function(){return r.moveNodeInsideStart}});var n=i(81937),o=i(23211),r=i(89817);function s(e,t,i,o){var r;let s=(null==(r=e.nodeValue)?void 0:r.length)?e.nodeValue:"";if(o&&s.replace((0,n.INVISIBLE_SPACE_REG_EXP_END)(),"").length>t)return!0;let a=(0,n.INVISIBLE_SPACE_REG_EXP_START)().exec(s);return i&&(a&&a[0].length<t||!a&&t>0)}function a(e,t,i,n,r,s){if((e=t.startContainer.childNodes[t.startOffset])||(e=t.startContainer.childNodes[t.startOffset-1],i=!0),e&&n&&!o.Dom.isText(e)){if(!i&&o.Dom.isText(e.previousSibling))e=e.previousSibling;else if(r){let t=s(e);for(;t;){if(t&&o.Dom.isText(t)){e=t;break}t=s(t)}}}if(e&&!n&&!o.Dom.isText(e)){let t=e,i=e;do t=t.firstChild,i=i.lastChild;while(t&&i&&!o.Dom.isText(t));t===i&&t&&o.Dom.isText(t)&&(e=t)}return{node:e,rightMode:i}}i(7470)},89817:function(e,t,i){"use strict";i.d(t,{moveNodeInsideStart:function(){return r}});var n=i(81937),o=i(23211);function r(e,t,i){let r=o.Dom.findSibling(t,i),s=o.Dom.findSibling(t,!i);for(;o.Dom.isElement(r)&&!o.Dom.isTag(r,n.INSEPARABLE_TAGS)&&o.Dom.isContentEditable(r,e.editor)&&(!s||!o.Dom.closest(t,o.Dom.isElement,e.editor));)i||!r.firstChild?r.appendChild(t):o.Dom.before(r.firstChild,t),r=o.Dom.sibling(t,i),s=o.Dom.sibling(t,!i)}},7470:function(e,t,i){"use strict";i.d(t,{moveTheNodeAlongTheEdgeOutward:function(){return o}});var n=i(23211);function o(e,t,i){let o=e;for(;o&&o!==i&&!(n.Dom.findSibling(o,t)||n.Dom.isBlock(o.parentElement));)(o=o.parentElement)&&o!==i&&(t?n.Dom.before(o,e):n.Dom.after(o,e))}},59841:function(e,t,i){"use strict";i.d(t,{CommitStyle:function(){return o.CommitStyle},Selection:function(){return n.Selection}});var n=i(98595),o=i(84578)},98595:function(e,t,i){"use strict";i.d(t,{Selection:function(){return f}});var n=i(25045),o=i(31635),r=i(81937),s=i(84839),a=i(23211),l=i(65946),u=i(28686),c=i(28712),d=i(7470),h=i(84578),p=i(42259);class f{get j(){return this.jodit}errorNode(e){if(!a.Dom.isNode(e))throw(0,l.error)("Parameter node must be instance of Node")}get area(){return this.j.editor}get win(){return this.j.ew}get doc(){return this.j.ed}get sel(){return this.j.o.shadowRoot&&(0,u.isFunction)(this.j.o.shadowRoot.getSelection)?this.j.o.shadowRoot.getSelection():this.win.getSelection()}get range(){let e=this.sel;return e&&e.rangeCount?e.getRangeAt(0):this.createRange()}get isInsideArea(){let{sel:e}=this,t=(null==e?void 0:e.rangeCount)?e.getRangeAt(0):null;return!(!t||!a.Dom.isOrContains(this.area,t.startContainer))}createRange(e=!1){let t=this.doc.createRange();return e&&this.selectRange(t),t}remove(){let e=this.sel,t=this.current();if(e&&t)for(let t=0;t<e.rangeCount;t+=1)e.getRangeAt(t).deleteContents(),e.getRangeAt(t).collapse(!0)}clear(){var e,t;(null==(e=this.sel)?void 0:e.rangeCount)&&(null==(t=this.sel)||t.removeAllRanges())}removeNode(e){if(!a.Dom.isOrContains(this.j.editor,e,!0))throw(0,l.error)("Selection.removeNode can remove only editor's children");a.Dom.safeRemove(e),this.j.e.fire("afterRemoveNode",e)}insertCursorAtPoint(e,t){this.removeMarkers();try{let i=this.createRange();return(()=>{if(this.doc.caretPositionFromPoint){let n=this.doc.caretPositionFromPoint(e,t);if(n)return i.setStart(n.offsetNode,n.offset)}if(this.doc.caretRangeFromPoint){let n=this.doc.caretRangeFromPoint(e,t);(0,c.assert)(n,"Incorrect caretRangeFromPoint behaviour"),i.setStart(n.startContainer,n.startOffset)}})(),i.collapse(!0),this.selectRange(i),!0}catch(e){}return!1}get hasMarkers(){return!!this.markers.length}get markers(){return(0,l.$$)("span[data-"+r.MARKER_CLASS+"]",this.area)}removeMarkers(){a.Dom.safeRemove.apply(null,this.markers)}marker(e=!1,t){let i=null;t&&(i=t.cloneRange()).collapse(e);let n=this.j.createInside.span();return n.id=r.MARKER_CLASS+"_"+Number(new Date)+"_"+String(Math.random()).slice(2),n.style.lineHeight="0",n.style.display="none",a.Dom.markTemporary(n),(0,l.attr)(n,"data-"+r.MARKER_CLASS,e?"start":"end"),n.appendChild(this.j.createInside.text(r.INVISIBLE_SPACE)),i&&a.Dom.isOrContains(this.area,e?i.startContainer:i.endContainer)&&i.insertNode(n),n}restore(){let e=!1,t=e=>`span[data-${r.MARKER_CLASS}=${e?"start":"end"}]`,i=this.area.querySelector(t(!0)),n=this.area.querySelector(t(!1));if(i){if(e=this.createRange(),n)e.setStartAfter(i),a.Dom.safeRemove(i),e.setEndBefore(n),a.Dom.safeRemove(n);else{let t=i.previousSibling;a.Dom.isText(t)?e.setStart(t,t.nodeValue?t.nodeValue.length:0):e.setStartBefore(i),a.Dom.safeRemove(i),e.collapse(!0)}e&&this.selectRange(e)}}fakes(){let e=this.sel;if(!e||!e.rangeCount)return[];let t=e.getRangeAt(0);(0,c.assert)(t,"Range is null");let i=t.cloneRange();i.collapse(!0);let n=this.j.createInside.fake();a.Dom.safeInsertNode(i,n),t.setStartBefore(n);let o=[n];if(!t.collapsed){let e=t.cloneRange();e.collapse(!1);let i=this.j.createInside.fake();a.Dom.safeInsertNode(e,i),t.setEndAfter(i),o.push(i)}return this.selectRange(t),o}restoreFakes(e){var t,i,n,o;let r=e.filter(e=>e.isConnected);if(!r.length)return;let[s,l]=r,u=this.createRange();u.setStartAfter(s),l&&u.setEndBefore(l),this.selectRange(u),(null==(t=s.parentNode)?void 0:t.firstChild)!==(null==(i=s.parentNode)?void 0:i.lastChild)&&a.Dom.safeRemove(s),(null==l||null==(n=l.parentNode)?void 0:n.firstChild)!==(null==l||null==(o=l.parentNode)?void 0:o.lastChild)&&a.Dom.safeRemove(l)}save(e=!1){if(this.hasMarkers)return[];let t=this.sel;if(!t||!t.rangeCount)return[];let i=[],n=t.rangeCount,o=[];for(let e=0;n>e;e+=1)if(o[e]=t.getRangeAt(e),o[e].collapsed){let t=this.marker(!0,o[e]);i[e]={startId:t.id,collapsed:!0,startMarker:t.outerHTML}}else{let t=this.marker(!0,o[e]),n=this.marker(!1,o[e]);i[e]={startId:t.id,endId:n.id,collapsed:!1,startMarker:t.outerHTML,endMarker:n.outerHTML}}if(!e){t.removeAllRanges();for(let e=n-1;e>=0;--e){let n=this.doc.getElementById(i[e].startId);if(n){if(i[e].collapsed)o[e].setStartAfter(n),o[e].collapse(!0);else if(o[e].setStartBefore(n),i[e].endId){let t=this.doc.getElementById(i[e].endId);t&&o[e].setEndAfter(t)}try{t.addRange(o[e].cloneRange())}catch(e){}}}}return i}focus(e={preventScroll:!0}){if(!this.isFocused()){let n=(0,l.getScrollParent)(this.j.container),o=null==n?void 0:n.scrollTop;this.j.iframe&&"complete"===this.doc.readyState&&this.j.iframe.focus(e),this.win.focus(),this.area.focus(e),o&&(null==n?void 0:n.scrollTo)&&n.scrollTo(0,o);let r=this.sel,s=(null==r?void 0:r.rangeCount)?null==r?void 0:r.getRangeAt(0):null;if(!s||!a.Dom.isOrContains(this.area,s.startContainer)){let e=this.createRange();e.setStart(this.area,0),e.collapse(!0),this.selectRange(e,!1)}if(!this.j.editorIsActive){var t,i;null==(i=this.j)||null==(t=i.events)||t.fire("focus")}return!0}return!1}isCollapsed(){let e=this.sel;for(let t=0;e&&t<e.rangeCount;t+=1)if(!e.getRangeAt(t).collapsed)return!1;return!0}isFocused(){return this.doc.hasFocus&&this.doc.hasFocus()&&this.area===this.doc.activeElement}current(e=!0){if(this.j.getRealMode()!==r.MODE_WYSIWYG)return null;let t=this.sel;if(!t||0===t.rangeCount)return null;let i=t.getRangeAt(0),n=i.startContainer,o=!1;if(a.Dom.isTag(n,"br")&&t.isCollapsed)return n;if(!a.Dom.isText(n)){let r=(0,p.findCorrectCurrentNode)(n,i,o,t.isCollapsed,e,e=>o?e.lastChild:e.firstChild);n=r.node,o=r.rightMode}return n&&a.Dom.isOrContains(this.area,n)?n:null}insertNode(e,t=!0,i=!0){this.errorNode(e);let n=a.Dom.isFragment(e)?e.lastChild:e;this.j.e.fire("safeHTML",e),!this.isFocused()&&this.j.isEditorMode()&&(this.focus(),this.restore());let o=this.sel;this.j.history.snapshot.transaction(()=>{if(this.isCollapsed()||this.j.execCommand("Delete"),this.j.e.fire("beforeInsertNode",e),o&&o.rangeCount){let t=o.getRangeAt(0),{firstChild:i}=e;a.Dom.isOrContains(this.area,t.commonAncestorContainer)?a.Dom.safeInsertNode(t,e):this.area.appendChild(e),[()=>null==i?void 0:i.previousSibling,()=>null==i?void 0:i.previousSibling,()=>{var e;return null==i||null==(e=i.previousSibling)?void 0:e.lastChild}].forEach(e=>{let t=e();t&&a.Dom.isEmptyTextNode(t)&&a.Dom.safeRemove(t)})}else this.area.appendChild(e);let i=e=>{if(a.Dom.isBlock(e)){let t=e.lastChild;if(t)return i(t)}this.setCursorAfter(e)};t&&(a.Dom.isFragment(e)?n&&i(n):i(e)),this.j.o.scrollToPastedContent&&(0,l.scrollIntoViewIfNeeded)(null!=n?n:e,this.j.editor,this.doc)}),i&&this.j.events&&this.j.__imdSynchronizeValues(),this.j.events&&this.j.e.fire("afterInsertNode",a.Dom.isFragment(e)?n:e)}insertHTML(e,t=!0){if(""===e)return;let i=this.j.createInside.div(),n=this.j.createInside.fragment();if(!this.isFocused()&&this.j.isEditorMode()&&(this.focus(),this.restore()),a.Dom.isNode(e)?i.appendChild(e):i.innerHTML=e.toString(),(this.j.isEditorMode()||!1!==this.j.e.fire("insertHTML",i.innerHTML))&&i.lastChild){for(;i.firstChild;)i.firstChild,n.appendChild(i.firstChild);this.insertNode(n,t,!1),this.j.__imdSynchronizeValues()}}insertImage(e,t=null,i=null){let n=(0,u.isString)(e)?this.j.createInside.element("img"):e;if((0,u.isString)(e)&&n.setAttribute("src",e),null!=i){let e=i.toString();e&&"auto"!==e&&0>String(e).indexOf("px")&&0>String(e).indexOf("%")&&(e+="px"),(0,l.attr)(n,"width",e)}t&&"object"==typeof t&&(0,l.css)(n,t);let o=()=>{(n.naturalHeight<n.offsetHeight||n.naturalWidth<n.offsetWidth)&&(n.style.width="",n.style.height=""),n.removeEventListener("load",o)};this.j.e.on(n,"load",o),n.complete&&o(),this.insertNode(n),this.j.e.fire("afterInsertImage",n)}eachSelection(e){var t;let i=this.sel;if(!i||!i.rangeCount)return;let n=i.getRangeAt(0),o=n.commonAncestorContainer;a.Dom.isHTMLElement(o)||(o=o.parentElement);let s=[],c=n.startOffset,d=o.childNodes.length,h=n.startContainer===this.area?o.childNodes[c<d?c:d-1]:n.startContainer,p=n.endContainer===this.area?o.childNodes[n.endOffset-1]:n.endContainer;a.Dom.isText(h)&&h===n.startContainer&&n.startOffset===(null==(t=h.nodeValue)?void 0:t.length)&&h.nextSibling&&(h=h.nextSibling),a.Dom.isText(p)&&p===n.endContainer&&0===n.endOffset&&p.previousSibling&&(p=p.previousSibling);let f=e=>{!e||e===o||a.Dom.isEmptyTextNode(e)||(0,u.isMarker)(e)||s.push(e)};f(h),h!==p&&a.Dom.isOrContains(o,h,!0)&&a.Dom.find(h,e=>(f(e),e===p||e&&e.contains&&e.contains(p)),o,!0,!1);let m=t=>{if(a.Dom.isOrContains(this.j.editor,t,!0)){if(t.nodeName.match(/^(UL|OL)$/))return(0,l.toArray)(t.childNodes).forEach(m);if(a.Dom.isTag(t,"li"))if(t.firstChild)t=t.firstChild;else{let e=this.j.createInside.text(r.INVISIBLE_SPACE);t.appendChild(e),t=e}e(t)}};0===s.length&&(a.Dom.isEmptyTextNode(h)&&s.push(h),h.firstChild&&s.push(h.firstChild)),s.forEach(m)}cursorInTheEdge(e,t,i=null){var n;let o=!e,r=null==(n=this.sel)?void 0:n.getRangeAt(0);if(null!=i||(i=this.current(!1)),!r||!i||!a.Dom.isOrContains(t,i,!0))return null;let s=e?r.startContainer:r.endContainer,u=e?r.startOffset:r.endOffset,c=e=>!!(e&&!a.Dom.isTag(e,"br")&&!a.Dom.isEmptyTextNode(e)&&!a.Dom.isTemporary(e)&&!(a.Dom.isElement(e)&&!0===this.j.e.fire("isInvisibleForCursor",e)));if(a.Dom.isText(s)){if((0,p.cursorInTheEdgeOfString)(s,u,e,o))return!1}else{let e=(0,l.toArray)(s.childNodes);if(o){if(e.slice(u).some(c))return!1}else if(e.slice(0,u).some(c))return!1}let d=i;for(;d&&d!==t;){let t=a.Dom.sibling(d,e);if(!t){d=d.parentNode;continue}if((d=t)&&c(d))return!1}return!0}cursorOnTheLeft(e,t){return this.cursorInTheEdge(!0,e,t)}cursorOnTheRight(e,t){return this.cursorInTheEdge(!1,e,t)}setCursorAfter(e){return this.setCursorNearWith(e,!1)}setCursorBefore(e){return this.setCursorNearWith(e,!0)}setCursorNearWith(e,t){if(this.errorNode(e),!a.Dom.up(e,e=>e===this.area||e&&e.parentNode===this.area,this.area))throw(0,l.error)("Node element must be in editor");let i=this.createRange(),n=null;if(a.Dom.isText(e))if(t)i.setStart(e,0);else{var o,r;i.setEnd(e,null!=(o=null==(r=e.nodeValue)?void 0:r.length)?o:0)}else n=this.j.createInside.fake(),t?i.setStartBefore(e):i.setEndAfter(e),i.collapse(t),a.Dom.safeInsertNode(i,n),i.selectNode(n);return i.collapse(t),this.selectRange(i),n}setCursorIn(e,t=!1){if(this.errorNode(e),!a.Dom.up(e,e=>e===this.area||e&&e.parentNode===this.area,this.area))throw(0,l.error)("Node element must be in editor");let i=this.createRange(),n=e,o=e;do{if(a.Dom.isText(n)||a.Dom.isTag(n,r.INSEPARABLE_TAGS))break;o=n,n=t?n.firstChild:n.lastChild}while(n);if(!n){let e=this.j.createInside.text(r.INVISIBLE_SPACE);a.Dom.isTag(o,r.INSEPARABLE_TAGS)?n=o:(o.appendChild(e),o=e)}let s=n||o;return a.Dom.isTag(s,r.INSEPARABLE_TAGS)?t||a.Dom.isTag(s,"br")?i.setStartBefore(s):i.setEndAfter(s):i.selectNodeContents(s),i.collapse(t),this.selectRange(i),o}selectRange(e,t=!0){let i=this.sel;return t&&!this.isFocused()&&"focus"!==this.j.e.current&&this.focus(),i&&(i.removeAllRanges(),i.addRange(e)),this.j.e.fire("changeSelection"),this}select(e,t=!1){if(this.errorNode(e),!a.Dom.up(e,e=>e===this.area||e&&e.parentNode===this.area,this.area))throw(0,l.error)("Node element must be in editor");let i=this.createRange();return i[t?"selectNodeContents":"selectNode"](e),this.selectRange(i)}get html(){let e=this.sel;if(e&&e.rangeCount>0){let t=e.getRangeAt(0).cloneContents(),i=this.j.createInside.div();return i.appendChild(t),i.innerHTML}return""}*wrapInTagGen(e){if(this.isCollapsed()){let t=this.jodit.createInside.element("font",r.INVISIBLE_SPACE);this.insertNode(t,!1,!1),e&&e[0]&&t.appendChild(e[0]),yield t,a.Dom.unwrap(t);return}for(let e of((0,l.$$)("*[style*=font-size]",this.area).forEach(e=>{(0,l.attr)(e,"data-font-size",e.style.fontSize.toString()),e.style.removeProperty("font-size")}),this.j.nativeExecCommand("fontsize",!1,"7"),(0,l.$$)("*[data-font-size]",this.area).forEach(e=>{let t=(0,l.attr)(e,"data-font-size");t&&(e.style.fontSize=t,(0,l.attr)(e,"data-font-size",null))}),(0,l.$$)('font[size="7"]',this.area))){let{firstChild:t,lastChild:i}=e;if(t&&t===i&&(0,u.isMarker)(t)){a.Dom.unwrap(e);continue}t&&(0,u.isMarker)(t)&&a.Dom.before(e,t),i&&(0,u.isMarker)(i)&&a.Dom.after(e,i),yield e,a.Dom.unwrap(e)}}wrapInTag(e){let t=[];for(let i of this.wrapInTagGen())try{if(i.firstChild&&i.firstChild===i.lastChild&&(0,u.isMarker)(i.firstChild))continue;(0,u.isFunction)(e)?e(i):t.push(a.Dom.replace(i,e,this.j.createInside))}finally{let e=i.parentNode;e&&(a.Dom.unwrap(i),a.Dom.isEmpty(e)&&a.Dom.unwrap(e))}return t}commitStyle(e){(0,c.assert)((0,l.size)(e)>0,"Need to pass at least one option"),new h.CommitStyle(e).apply(this.j)}splitSelection(e,t){if(!this.isCollapsed())return null;let i=this.createRange(),n=this.range;i.setStartBefore(e);let o=this.cursorOnTheRight(e,t),s=this.cursorOnTheLeft(e,t),l=this.j.createInside.element("br"),u=this.j.createInside.fake(),d=u.cloneNode();try{if(o||s){t?a.Dom.before(t,l):a.Dom.safeInsertNode(n,l);let e=(e,t)=>{let i=t(e);for(;i;){let e=t(i);if(i&&(a.Dom.isTag(i,"br")||a.Dom.isEmptyTextNode(i)))a.Dom.safeRemove(i);else break;i=e}};e(l,e=>e.nextSibling),e(l,e=>e.previousSibling),a.Dom.after(l,d),a.Dom.before(l,u),o?(i.setEndBefore(l),n.setEndBefore(l)):(i.setEndAfter(l),n.setEndAfter(l))}else i.setEnd(n.startContainer,n.startOffset);let h=i.extractContents(),p=e=>a.Dom.each(e,e=>a.Dom.isEmptyTextNode(e)&&a.Dom.safeRemove(e));(0,c.assert)(e.parentNode,"Splitting fails");try{if(p(h),p(e),e.parentNode.insertBefore(h,e),!t&&o&&(null==l?void 0:l.parentNode)){let e=this.createRange();e.setStartBefore(l),this.selectRange(e)}}catch(e){if(!r.IS_PROD)throw e}let f=e=>{var t,i,n;(null==e||null==(t=e.parentNode)?void 0:t.firstChild)===(null==e||null==(i=e.parentNode)?void 0:i.lastChild)&&(null==e||null==(n=e.parentNode)||n.appendChild(l.cloneNode()))};f(u),f(d)}finally{a.Dom.safeRemove(u),a.Dom.safeRemove(d)}return e.previousElementSibling}expandSelection(){if(this.isCollapsed())return this;let{range:e}=this,t=e.cloneRange();if(!a.Dom.isOrContains(this.j.editor,e.commonAncestorContainer,!0))return this;let i=t=>{let i=this.j.createInside.fake(),n=e.cloneRange();return n.collapse(t),a.Dom.safeInsertNode(n,i),(0,d.moveTheNodeAlongTheEdgeOutward)(i,t,this.j.editor),i},n=i(!0),o=i(!1);t.setStartAfter(n),t.setEndBefore(o);let r=a.Dom.findSibling(n,!1),s=a.Dom.findSibling(o,!0);if(r!==s){let e=a.Dom.isElement(r)&&a.Dom.isOrContains(r,o),i=!e&&a.Dom.isElement(s)&&a.Dom.isOrContains(s,n);if(e||i){let i=e?r:s,l=i;for(;a.Dom.isElement(i);)(i=e?i.firstElementChild:i.lastElementChild)&&(e?a.Dom.isOrContains(i,o):a.Dom.isOrContains(i,n))&&(l=i);e?t.setStart(l,0):t.setEnd(l,l.childNodes.length)}}if(this.selectRange(t),a.Dom.safeRemove(n,o),this.isCollapsed())throw(0,l.error)("Selection is collapsed");return this}constructor(e){(0,n._)(this,"jodit",void 0),this.jodit=e,e.e.on("removeMarkers",()=>{this.removeMarkers()})}}(0,o.__decorate)([s.autobind],f.prototype,"createRange",null),(0,o.__decorate)([s.autobind],f.prototype,"focus",null),(0,o.__decorate)([s.autobind],f.prototype,"setCursorAfter",null),(0,o.__decorate)([s.autobind],f.prototype,"setCursorBefore",null),(0,o.__decorate)([s.autobind],f.prototype,"setCursorIn",null)},17481:function(e,t,i){"use strict";i.d(t,{extractSelectedPart:function(){return a}});var n=i(23211),o=i(23175),r=i(4040),s=i(71125);function a(e,t,i){let n=i.s.createRange(),r=(0,o.isMarker)(t.previousSibling)?t.previousSibling:t;n.setStartBefore(e),n.setEndBefore(r),l(e,n,!0);let s=(0,o.isMarker)(t.nextSibling)?t.nextSibling:t;n.setStartAfter(s),n.setEndAfter(e),l(e,n,!1)}function l(e,t,i){let o=t.extractContents();o.textContent&&(0,r.trim)(o.textContent).length||!o.firstChild||n.Dom.unwrap(o.firstChild),e.parentNode&&(0,s.call)(i?n.Dom.before:n.Dom.after,e,o)}},48729:function(e,t,i){"use strict";i.d(t,{FiniteStateMachine:function(){return a}});var n=i(25045),o=i(81937),r=i(85932),s=i(28712);class a{setState(e){(0,s.assert)(!this.__previewsStates.has(e),"Circled states"),this.__previewsStates.add(e),this.__state=e}getState(){return this.__state}disableSilent(){this.silent=!1}dispatch(e,t){let i=this.transitions[this.getState()][e];if(i){let e=i.call(this,t);return(0,s.assert)(e&&e!==t,"Action should return new value"),(0,s.assert)((0,r.isString)(e.next),"Value should contain the next state"),(0,s.assert)(e.next!==this.getState(),"The new state should not be equal to the old one."),this.setState(e.next),o.IS_PROD||this.silent,e}throw Error(`invalid action: ${this.getState()}.${e.toString()}`)}constructor(e,t){(0,n._)(this,"transitions",void 0),(0,n._)(this,"__state",void 0),(0,n._)(this,"silent",void 0),(0,n._)(this,"__previewsStates",void 0),this.transitions=t,this.silent=!0,this.__previewsStates=new Set,this.setState(e)}}},10171:function(e,t,i){"use strict";i.d(t,{getSuitChild:function(){return s}});var n=i(23211),o=i(83653),r=i(73019);function s(e,t){let{firstChild:i}=t;for(;i&&!(0,o.isNormalNode)(i);)if(!(i=i.nextSibling))return null;return i&&!n.Dom.next(i,o.isNormalNode,t)&&(0,r.isSuitElement)(e,i,!1)?i:null}},19549:function(e,t,i){"use strict";i.d(t,{getSuitParent:function(){return function e(t,i,s){let{parentNode:a}=i;return a===s||!n.Dom.isHTMLElement(a)||n.Dom.next(i,o.isNormalNode,a)||n.Dom.prev(i,o.isNormalNode,a)?null:t.isElementCommit&&t.elementIsBlock&&!n.Dom.isBlock(a)?e(t,a,s):(0,r.isSuitElement)(t,a,!1)&&(!n.Dom.isBlock(a)||t.elementIsBlock)?a:t.isElementCommit&&!n.Dom.isBlock(a)?e(t,a,s):null}}});var n=i(23211),o=i(83653),r=i(73019)},9703:function(e,t,i){"use strict";i.d(t,{hasSameStyle:function(){return u},hasSameStyleKeys:function(){return c}});var n=i(81937),o=i(23211),r=i(18303),s=i(19147),a=i(28712),l=i(80991);function u(e,t){return!!(!o.Dom.isTag(e,"font")&&o.Dom.isHTMLElement(e)&&Object.keys(t).every(i=>{let n=(0,l.css)(e,i,!0);return""===n&&(""===t[i]||null==t[i])||!(0,r.isVoid)(n)&&""!==n&&!(0,r.isVoid)(t[i])&&(0,s.normalizeCssValue)(i,t[i]).toString().toLowerCase()===n.toString().toLowerCase()}))}if(n.globalDocument){let e=n.globalDocument.createElement("div");e.style.color="red",(0,a.assert)(u(e,{color:"red"}),"Style test"),(0,a.assert)(u(e,{fontSize:null}),"Style test"),(0,a.assert)(u(e,{fontSize:""}),"Style test")}function c(e,t){return!!(!o.Dom.isTag(e,"font")&&o.Dom.isHTMLElement(e)&&Object.keys(t).every(t=>""!==(0,l.css)(e,t,!0)))}if(n.globalDocument){let e=n.globalDocument.createElement("div");e.style.color="red",(0,a.assert)(c(e,{color:"red"}),"Style test"),(0,a.assert)(!c(e,{font:"Arial",color:"red"}),"Style test"),(0,a.assert)(!c(e,{border:"1px solid #ccc"}),"Style test")}},51640:function(e,t,i){"use strict";i.d(t,{FiniteStateMachine:function(){return o.FiniteStateMachine},extractSelectedPart:function(){return n.extractSelectedPart},getSuitChild:function(){return r.getSuitChild},getSuitParent:function(){return s.getSuitParent},isInsideInvisibleElement:function(){return a.isInsideInvisibleElement},suitableClosest:function(){return l.suitableClosest},toggleAttributes:function(){return c.toggleAttributes},toggleOrderedList:function(){return u.toggleOrderedList},unwrapChildren:function(){return d.unwrapChildren},wrap:function(){return h.wrap}});var n=i(17481),o=i(48729),r=i(10171),s=i(19549);i(9703);var a=i(39608);i(83653),i(95971);var l=i(73019),u=i(34582);i(97110);var c=i(82794),d=i(89081),h=i(73154);i(83335)},39608:function(e,t,i){"use strict";i.d(t,{isInsideInvisibleElement:function(){return o}});var n=i(23211);function o(e,t){return!!n.Dom.closest(e,["style","script"],t)}},83653:function(e,t,i){"use strict";i.d(t,{isNormalNode:function(){return r}});var n=i(23211),o=i(23175);function r(e){return!!(e&&!n.Dom.isEmptyTextNode(e)&&!n.Dom.isTemporary(e)&&!(0,o.isMarker)(e))}},95971:function(e,t,i){"use strict";i.d(t,{elementsEqualAttributes:function(){return l},isSameAttributes:function(){return a}});var n=i(18073),o=i(93640),r=i(28712),s=i(9703);function a(e,t){return!((e.attributes.length||(0,n.size)(t))&&(0,n.size)(t))||((0,r.assert)(t,"Attrs must be a non-empty object"),Object.keys(t).every(i=>"class"===i||"className"===i?e.classList.contains(t[i]):"style"===i?(0,s.hasSameStyle)(e,t[i]):(0,o.attr)(e,i)===t[i]))}function l(e,t){return e.attributes.length===t.attributes.length&&Array.from(e.attributes).every(e=>t.hasAttribute(e.name)&&t.getAttribute(e.name)===e.value)}},73019:function(e,t,i){"use strict";i.d(t,{isSameStyleChild:function(){return l},isSuitElement:function(){return s},suitableClosest:function(){return a}});var n=i(23211),o=i(9703),r=i(83653);function s(e,t,i,a=!0){var l;if(!t||!(0,r.isNormalNode)(t))return!1;let{element:u,elementIsDefault:c,options:d}=e;if(n.Dom.isList(t)&&e.elementIsList)return!0;let h=n.Dom.isTag(t,u);return!!(h&&!(c&&i)||(null==(l=d.attributes)?void 0:l.style)&&(a?(0,o.hasSameStyle)(t,d.attributes.style):(0,o.hasSameStyleKeys)(t,d.attributes.style))&&!e.elementIsList)||!h&&!i&&c&&n.Dom.isInlineBlock(t)}function a(e,t,i){return n.Dom.closest(t,t=>s(e,t,!0,!1),i)}function l(e,t){var i,n;let{element:s,options:a}=e;if(!t||!(0,r.isNormalNode)(t))return!1;let l=t.nodeName.toLowerCase()===s,u=!!((null==(i=a.attributes)?void 0:i.style)&&(0,o.hasSameStyleKeys)(t,null==(n=a.attributes)?void 0:n.style));return l&&u}},34582:function(e,t,i){"use strict";i.d(t,{toggleOrderedList:function(){return u}});var n=i(23211),o=i(28712),r=i(17481),s=i(82794),a=i(98394),l=i(97110);function u(e,t,i,n){if(!t)return n;let o=t.parentElement;if(!o)return n;let r=i.e.fire(`${a._PREFIX}BeforeToggleList`,n,e,o);if(void 0!==r)return r;let u=i.e.fire.bind(i.e,`${a._PREFIX}AfterToggleList`);if(n!==a.UNWRAP){let r=(0,s.toggleAttributes)(e,t.parentElement,i,a.INITIAL,!0)===a.CHANGE;if(n===a.REPLACE||r||o.tagName.toLowerCase()!==e.element){let n=c(a.REPLACE,o,t,i,e),r=(0,l.wrapList)(e,n,i);return u(a.REPLACE,r,e),a.REPLACE}}let d=c(a.UNWRAP,o,t,i,e);return u(a.UNWRAP,d,e),a.UNWRAP}function c(e,t,i,s,l){let u=s.e.fire(`${a._PREFIX}BeforeUnwrapList`,e,t,l);return u?((0,o.assert)(n.Dom.isHTMLElement(u),`${a._PREFIX}BeforeUnwrapList hook must return HTMLElement`),u):((0,r.extractSelectedPart)(t,i,s),(0,o.assert)(n.Dom.isHTMLElement(i.parentElement),"Element should be inside the list"),n.Dom.unwrap(i.parentElement),n.Dom.replace(i,"br"!==s.o.enter.toLowerCase()?s.o.enter:s.createInside.fragment(),s.createInside))}},97110:function(e,t,i){"use strict";i.d(t,{wrapList:function(){return a}});var n=i(23211),o=i(95971),r=i(82794),s=i(98394);function a(e,t,i){let a=i.e.fire(`${s._PREFIX}BeforeWrapList`,s.REPLACE,t,e),l=null!=a?a:n.Dom.replace(t,"li",i.createInside),u=l.previousElementSibling,c=l.nextElementSibling,d=n.Dom.isTag(u,e.element)?u:null;return null!=d||(d=n.Dom.isTag(c,e.element)?c:null),n.Dom.isList(d)&&(0,o.isSameAttributes)(d,e.options.attributes)||(d=i.createInside.element(e.element),(0,r.toggleAttributes)(e,d,i,s.INITIAL),n.Dom.before(l,d)),u===d?n.Dom.append(d,l):n.Dom.prepend(d,l),n.Dom.isTag(d.nextElementSibling,e.element)&&(0,o.elementsEqualAttributes)(d,d.nextElementSibling)&&(n.Dom.append(d,Array.from(d.nextElementSibling.childNodes)),n.Dom.safeRemove(d.nextElementSibling)),i.e.fire(`${s._PREFIX}AfterWrapList`,s.WRAP,d,e),d}},82794:function(e,t,i){"use strict";i.d(t,{toggleAttributes:function(){return m}});var n=i(81937),o=i(23211),r=i(28077),s=i(28686),a=i(19147),l=i(18073),u=i(74264),c=i(93640),d=i(80991),h=i(36400),p=i(98394);let f="toggleAttributes";function m(e,t,i,v,_=!1){if(!_&&e.isApplied(t,f))return v;_||e.setApplied(t,f);let{attributes:b}=e.options;return b&&(0,l.size)(b)>0&&Object.keys(b).forEach(f=>{var m,y,S;let w=b[f];switch(f){case"style":m=v,(0,c.assert)((0,s.isPlainObject)(w)&&(0,l.size)(w),"Style must be an object"),Object.keys(w).forEach(s=>{let l=t.style.getPropertyValue((0,u.kebabCase)(s)),c=w[s];if(""!==l||null!=c){let u,f;if((u=i.create.element(t.tagName.toLowerCase())).style.cssText=t.style.cssText,(function(e){var t;if(void 0!==(0,h.dataBind)(e,"shadowRoot"))return(0,h.dataBind)(e,"shadowRoot");let i=(0,r.getContainer)(e),o=n.globalDocument.createElement("iframe");(0,d.css)(o,{width:0,height:0,position:"absolute",border:0}),o.src="about:blank",i.appendChild(o);let s=null==(t=o.contentWindow)?void 0:t.document,a=s?s.body:e.od.body;return(0,h.dataBind)(e,"shadowRoot",a),a})(i).appendChild(u),f=(0,d.css)(u,s),o.Dom.safeRemove(u),f===(0,a.normalizeCssValue)(s,c)){if(!l)return;_||(0,d.css)(t,s,null),m=g(e,t,m=p.UNSET);return}m=p.CHANGE,_||((0,d.css)(t,s,c),m=g(e,t,m))}}),v=m;break;case"className":case"class":let C;y=v,(0,c.assert)((0,s.isString)(w),"Class name must be a string"),C=i.e.fire.bind(i.e,`${p._PREFIX}AfterToggleAttribute`),t.classList.contains(w.toString())?(y=p.UNSET,_||(t.classList.remove(w),0===t.classList.length&&((0,c.attr)(t,"class",null),C(y,t,"class",null)))):(y=p.CHANGE,_||(t.classList.add(w),C(y,t,"class",w))),v=y;break;default:let k;S=v,(0,c.assert)((0,s.isString)(w)||(0,s.isNumber)(w)||(0,s.isBoolean)(w)||null==w,"Attribute value must be a string or number or boolean or null"),k=i.e.fire.bind(i.e,`${p._PREFIX}AfterToggleAttribute`),(0,c.attr)(t,f)===w?(_||(0,c.attr)(t,f,null),S=p.UNSET,_||k(S,t,f,w)):(S=p.CHANGE,_||((0,c.attr)(t,f,w),k(S,t,f,w))),v=S}}),v}function g(e,t,i){return(0,c.attr)(t,"style")||((0,c.attr)(t,"style",null),t.tagName.toLowerCase()===e.defaultTag&&(o.Dom.unwrap(t),i=p.UNWRAP)),i}},89081:function(e,t,i){"use strict";i.d(t,{unwrapChildren:function(){return a}});var n=i(23211),o=i(93640),r=i(9703),s=i(73019);function a(e,t){var i;let a,l=[],u=[],c=null==(i=e.options.attributes)?void 0:i.style;if(t.firstChild){let i=n.Dom.eachGen(t),d=i.next();for(;!d.done;){let t=d.value;(0,s.isSuitElement)(e,t,!0)&&(!c||(0,r.hasSameStyleKeys)(t,c))?(void 0===a&&(a=!0),l.push(t)):c&&(0,s.isSameStyleChild)(e,t)?(void 0===a&&(a=!1),u.push(()=>{(0,o.css)(t,Object.keys(c).reduce((e,t)=>(e[t]=null,e),{})),(0,o.attr)(t,"style")||(0,o.attr)(t,"style",null),(0,o.attr)(t,"style")||t.nodeName.toLowerCase()!==e.element||l.push(t)})):n.Dom.isEmptyTextNode(t)||void 0!==a||(a=!1),d=i.next()}}return u.forEach(e=>e()),l.forEach(n.Dom.unwrap),!!a}},83335:function(e,t,i){"use strict";i.d(t,{wrapUnwrappedText:function(){return r}});var n=i(23211),o=i(23175);function r(e,t,i){let r=i.editor,s=i.createInside,a=(e,t="previousSibling")=>{let s=e,a=e;for(;a&&!(0,o.isMarker)(a)&&!n.Dom.isTag(a,i.o.enter)&&(s=a,a=a[t]?a[t]:a.parentNode&&!n.Dom.isBlock(a.parentNode)&&a.parentNode!==r?a.parentNode:null,!n.Dom.isBlock(a)););return s},l=a(t),u=a(t,"nextSibling"),c=i.s.createRange();c.setStartBefore(l),c.setEndAfter(u);let d=c.extractContents(),h=s.element(e.element);return h.appendChild(d),n.Dom.safeInsertNode(c,h),e.elementIsBlock&&n.Dom.isEmpty(h)&&!n.Dom.isTag(h.firstElementChild,"br")&&h.appendChild(s.element("br")),h}},73154:function(e,t,i){"use strict";i.d(t,{wrap:function(){return a}});var n=i(27795),o=i(7909),r=i(97110),s=i(83335);function a(e,t,i){var a,u,c;let d=(a=e,u=t,c=i,a.elementIsBlock?n.Dom.up(u,e=>n.Dom.isBlock(e)&&!n.Dom.isTag(e,l),c.editor)||(0,s.wrapUnwrappedText)(a,u,c):((0,o.attr)(u,"size",null),u));return e.elementIsList?(0,r.wrapList)(e,d,i):n.Dom.replace(d,e.element,i.createInside,!0)}let l=new Set(["td","th","tr","tbody","table","li","ul","ol"])},96127:function(e,t,i){"use strict";i.d(t,{ApplyStyle:function(){return s}});var n=i(51640),o=i(98394),r=i(78462);function s(e,t){var i;let{s:s,editor:a}=e;null==(i=a.firstChild)||i.normalize();let l=s.fakes(),u=e.s.wrapInTagGen(l),c=u.next();if(c.done)return;let d={collapsed:s.isCollapsed(),mode:o.INITIAL,element:c.value,next:r.states.START,jodit:e,style:t};for(;c&&!c.done;){let e=new n.FiniteStateMachine(r.states.START,r.transactions);for(d.element=c.value;e.getState()!==r.states.END;)d=e.dispatch("exec",d);c=u.next()}s.restoreFakes(l)}},84578:function(e,t,i){"use strict";i.d(t,{CommitStyle:function(){return l}});var n=i(25045),o=i(81937),r=i(57821),s=i(98394),a=i(96127);class l{isApplied(e,t){let i=this.__applyMap.get(e);return!!i&&i[t]}setApplied(e,t){var i;let n=null!=(i=this.__applyMap.get(e))?i:{};n[t]=!0,this.__applyMap.set(e,n)}get elementIsList(){return!!(this.options.element&&o.LIST_TAGS.has(this.options.element))}get element(){return this.options.element||this.defaultTag}get elementIsBlock(){return!!(this.options.element&&o.IS_BLOCK.test(this.options.element))}get isElementCommit(){return!!(this.options.element&&this.options.element!==this.options.defaultTag)}get defaultTag(){return this.options.defaultTag?this.options.defaultTag:this.elementIsBlock?"p":"span"}get elementIsDefault(){return this.element===this.defaultTag}apply(e){let{hooks:t}=this.options,i=t?Object.keys(t):[];try{i.forEach(i=>{e.e.on((0,r.camelCase)(s._PREFIX+"_"+i),t[i])}),(0,a.ApplyStyle)(e,this)}finally{i.forEach(i=>{e.e.off((0,r.camelCase)(s._PREFIX+"_"+i),t[i])}),this.__applyMap=new WeakMap}e.synchronizeValues(),e.e.fire("afterCommitStyle",this)}constructor(e){(0,n._)(this,"options",void 0),(0,n._)(this,"__applyMap",void 0),this.options=e,this.__applyMap=new WeakMap}}},98394:function(e,t,i){"use strict";i.d(t,{CHANGE:function(){return r},INITIAL:function(){return a},REPLACE:function(){return l},UNSET:function(){return s},UNWRAP:function(){return o},WRAP:function(){return n},_PREFIX:function(){return u}});let n="wrap",o="unwrap",r="change",s="unset",a="initial",l="replace",u="commitStyle"},78462:function(e,t,i){"use strict";i.d(t,{states:function(){return l},transactions:function(){return u}});var n=i(81937),o=i(23211),r=i(28712),s=i(51640),a=i(98394);let l={START:"START",ELEMENT:"ELEMENT",UNWRAP:"UNWRAP",UNWRAP_CHILDREN:"UNWRAP_CHILDREN",CHANGE:"CHANGE",REPLACE_DEFAULT:"REPLACE_DEFAULT",LIST:"LIST",TOGGLE_LIST:"TOGGLE_LIST",WRAP:"WRAP",EXTRACT:"EXTRACT",END:"END"},u={[l.START]:{exec(e){let{element:t,jodit:i,style:n,mode:r,collapsed:u}=e;if((0,s.isInsideInvisibleElement)(t,i.editor)||!u&&o.Dom.isEmptyContent(t))return{...e,next:l.END};let c=(0,s.getSuitParent)(n,t,i.editor)||(0,s.getSuitChild)(n,t);if(c)return{...e,next:l.ELEMENT,element:c};let d=(0,s.suitableClosest)(n,t,i.editor);return n.elementIsList&&o.Dom.isList(d)?{...e,next:l.LIST}:d?{...e,next:l.EXTRACT}:{...e,next:r!==a.UNWRAP?l.UNWRAP_CHILDREN:l.END}}},[l.LIST]:{exec(e){let{element:t,jodit:i,mode:r}=e;if(r!==a.INITIAL&&r!==a.UNWRAP&&r!==a.REPLACE)return{...e,next:l.END};let s=o.Dom.closest(t,"li",i.editor);return s&&o.Dom.closest(t,n.LIST_TAGS,i.editor)?{...e,element:s,next:l.TOGGLE_LIST}:{...e,next:l.END}}},[l.TOGGLE_LIST]:{exec(e){return{...e,mode:(0,s.toggleOrderedList)(e.style,e.element,e.jodit,e.mode),next:l.END}}},[l.EXTRACT]:{exec(e){var t;let{element:i,jodit:n,style:a}=e,u=(0,s.suitableClosest)(a,i,n.editor);return((0,r.assert)(u,"This place should have an element"),!a.elementIsBlock&&(null==(t=a.options.attributes)?void 0:t.style)&&o.Dom.isBlock(u))?{...e,next:l.WRAP}:(a.elementIsBlock||(0,s.extractSelectedPart)(u,i,n),{...e,element:u,next:l.ELEMENT})}},[l.UNWRAP_CHILDREN]:{exec(e){let{element:t,style:i}=e;return(0,s.unwrapChildren)(i,t)?{...e,mode:a.UNWRAP,next:l.END}:{...e,next:l.WRAP}}},[l.WRAP]:{exec(e){let{element:t,jodit:i,style:n}=e,o=(0,s.wrap)(n,t,i);return{...e,next:n.elementIsList?l.END:l.CHANGE,mode:a.WRAP,element:o}}},[l.ELEMENT]:{exec(e){let{style:t,element:i,jodit:n}=e;return(0,s.toggleAttributes)(t,i,n,a.INITIAL,!0)!==a.INITIAL?{...e,next:l.CHANGE}:o.Dom.isTag(i,t.element)?{...e,next:l.UNWRAP}:{...e,next:l.END}}},[l.CHANGE]:{exec(e){let{style:t,element:i,jodit:n,mode:r}=e,u=(0,s.toggleAttributes)(t,i,n,e.mode);return r!==a.WRAP&&u===a.UNSET&&!i.attributes.length&&o.Dom.isTag(i,t.element)?{...e,next:l.UNWRAP}:{...e,mode:u,next:l.END}}},[l.UNWRAP]:{exec(e){return e.element.attributes.length&&o.Dom.isTag(e.element,e.style.element)?{...e,next:l.REPLACE_DEFAULT}:(o.Dom.unwrap(e.element),{...e,mode:a.UNWRAP,next:l.END})}},[l.REPLACE_DEFAULT]:{exec(e){return o.Dom.replace(e.element,e.style.defaultTag,e.jodit.createInside,!0),{...e,mode:a.REPLACE,next:l.END}}},[l.END]:{exec(e){return e}}}},8006:function(e,t,i){"use strict";i.d(t,{AsyncStorage:function(){return u}});var n=i(25045),o=i(57821),r=i(91162),s=i(59807),a=i(9505),l=i(24475);class u{async set(e,t){let i=await this.provider;return await i.set((0,o.camelCase)(this.prefix+e),t),this}async delete(e){let t=await this.provider;return await t.delete((0,o.camelCase)(this.prefix+e)),this}async get(e){return(await this.provider).get((0,o.camelCase)(this.prefix+e))}async exists(e){return(await this.provider).exists((0,o.camelCase)(this.prefix+e))}async clear(){let e=await this.provider;return await e.clear(),this}async close(){let e=await this.provider;"close"in e&&"function"==typeof e.close&&await e.close()}static makeStorage(e=!1,t){let i;return"localStorage"===e||"sessionStorage"===e?(0,s.canUsePersistentStorage)(e)&&(i=new s.LocalStorageProvider(l.StorageKey+(t||""),e)):("indexedDB"===e||!0===e)&&(i=(0,r.canUseIndexedDB)().then(e=>e?new r.IndexedDBProvider(l.StorageKey+(t||""),"keyValueStore"):new a.MemoryStorageProvider)),i||(i=new a.MemoryStorageProvider),new u(Promise.resolve(i),t)}constructor(e,t){(0,n._)(this,"provider",void 0),(0,n._)(this,"prefix",void 0),this.provider=e,this.prefix=l.StorageKey,t&&(this.prefix+=t)}}},91162:function(e,t,i){"use strict";i.d(t,{IndexedDBProvider:function(){return r},canUseIndexedDB:function(){return l},clearUseIndexedDBCache:function(){return a}});var n=i(25045),o=i(81937);class r{getDB(){return this.dbPromise||(this.dbPromise=new Promise((e,t)=>{let i=indexedDB.open(this.dbName,this.DB_VERSION);i.onerror=()=>{t(i.error)},i.onsuccess=()=>{e(i.result)},i.onupgradeneeded=e=>{let t=e.target.result;t.objectStoreNames.contains(this.storeName)||t.createObjectStore(this.storeName)}})),this.dbPromise}async performTransaction(e,t){try{let i=(await this.getDB()).transaction([this.storeName],e).objectStore(this.storeName),n=t(i);return new Promise((e,t)=>{n.onsuccess=()=>{e(n.result)},n.onerror=()=>{t(n.error)}})}catch(e){return Promise.reject(e)}}async set(e,t){try{await this.performTransaction("readwrite",i=>i.put(t,e))}catch(e){o.IS_PROD}return this}async delete(e){try{await this.performTransaction("readwrite",t=>t.delete(e))}catch(e){}return this}async get(e){try{return await this.performTransaction("readonly",t=>t.get(e))}catch(e){return}}async exists(e){try{let t=await this.performTransaction("readonly",t=>t.get(e));return void 0!==t}catch(e){return!1}}async clear(){try{await this.performTransaction("readwrite",e=>e.clear())}catch(e){}return this}async close(){if(this.dbPromise){try{(await this.dbPromise).close()}catch(e){}this.dbPromise=null}}async keys(){try{let e=await this.performTransaction("readonly",e=>e.getAllKeys());return e&&"object"==typeof e&&"then"in e&&(e=await e),e.map(e=>String(e))}catch(e){return[]}}async values(){try{let e=await this.performTransaction("readonly",e=>e.getAll());return e&&"object"==typeof e&&"then"in e&&(e=await e),e}catch(e){return[]}}async entries(){try{let[e,t]=await Promise.all([this.keys(),this.values()]);return e.map((e,i)=>[e,t[i]])}catch(e){return[]}}constructor(e="JoditDB",t="keyValueStore"){(0,n._)(this,"dbName",void 0),(0,n._)(this,"dbPromise",void 0),(0,n._)(this,"DB_VERSION",void 0),(0,n._)(this,"storeName",void 0),this.dbName=e,this.dbPromise=null,this.DB_VERSION=1,this.storeName=t}}let s=null;function a(){s=null}async function l(){if(null!=s)return s;try{if("u"<typeof indexedDB)return s=!1,!1;let e="___Jodit___"+Math.random().toString(),t=indexedDB.open(e);return s=await new Promise(i=>{t.onerror=()=>{i(!1)},t.onsuccess=()=>{indexedDB.deleteDatabase(e),i(!0)}})}catch(e){return s=!1,!1}}},59807:function(e,t,i){"use strict";i.d(t,{LocalStorageProvider:function(){return r},canUsePersistentStorage:function(){return o}});var n=i(25045);let o=(e="localStorage")=>{let t=new Map;if(t.has(e))return t.get(e);let i="___Jodit___"+Math.random().toString(),n="sessionStorage"===e?sessionStorage:localStorage;try{n.setItem(i,"1");let o="1"===n.getItem(i);return n.removeItem(i),t.set(e,o),o}catch(e){}return t.set(e,!1),!1};class r{get storage(){return"sessionStorage"===this.strategy?sessionStorage:localStorage}set(e,t){try{let i=this.storage.getItem(this.rootKey),n=i?JSON.parse(i):{};n[e]=t,this.storage.setItem(this.rootKey,JSON.stringify(n))}catch(e){}return this}delete(e){try{this.storage.removeItem(this.rootKey)}catch(e){}return this}get(e){try{let t=this.storage.getItem(this.rootKey),i=t?JSON.parse(t):{};return void 0!==i[e]?i[e]:void 0}catch(e){}}exists(e){return null!=this.get(e)}clear(){try{this.storage.removeItem(this.rootKey)}catch(e){}return this}constructor(e,t="localStorage"){(0,n._)(this,"rootKey",void 0),(0,n._)(this,"strategy",void 0),this.rootKey=e,this.strategy=t}}},9505:function(e,t,i){"use strict";i.d(t,{MemoryStorageProvider:function(){return o}});var n=i(25045);class o{set(e,t){return this.data.set(e,t),this}delete(e){return this.data.delete(e),this}get(e){return this.data.get(e)}exists(e){return this.data.has(e)}clear(){return this.data.clear(),this}constructor(){(0,n._)(this,"data",new Map)}}},25222:function(e,t,i){"use strict";i.d(t,{AsyncStorage:function(){return n.AsyncStorage},IndexedDBProvider:function(){return o.IndexedDBProvider},LocalStorageProvider:function(){return r.LocalStorageProvider},MemoryStorageProvider:function(){return s.MemoryStorageProvider},Storage:function(){return a.Storage},StorageKey:function(){return a.StorageKey},canUseIndexedDB:function(){return o.canUseIndexedDB},canUsePersistentStorage:function(){return r.canUsePersistentStorage},clearUseIndexedDBCache:function(){return o.clearUseIndexedDBCache}});var n=i(8006),o=i(91162),r=i(59807),s=i(9505),a=i(24475)},24475:function(e,t,i){"use strict";i.d(t,{Storage:function(){return l},StorageKey:function(){return a}});var n=i(25045),o=i(57821),r=i(59807),s=i(9505);let a="Jodit_";class l{set(e,t){return this.provider.set((0,o.camelCase)(this.prefix+e),t),this}delete(e){return this.provider.delete((0,o.camelCase)(this.prefix+e)),this}get(e){return this.provider.get((0,o.camelCase)(this.prefix+e))}exists(e){return this.provider.exists((0,o.camelCase)(this.prefix+e))}clear(){return this.provider.clear(),this}static makeStorage(e=!1,t){let i;return"localStorage"===e||"sessionStorage"===e?(0,r.canUsePersistentStorage)(e)&&(i=new r.LocalStorageProvider(a+(t||""),e)):!0===e&&(0,r.canUsePersistentStorage)("localStorage")&&(i=new r.LocalStorageProvider(a+(t||""))),i||(i=new s.MemoryStorageProvider),new l(i,t)}constructor(e,t){(0,n._)(this,"provider",void 0),(0,n._)(this,"prefix",void 0),this.provider=e,this.prefix=a,t&&(this.prefix+=t)}}},80512:function(e,t,i){"use strict";i.d(t,{Dlgs:function(){return a}});var n=i(28077),o=i(28686),r=i(71125),s=i(37333);class a{dlg(e){let t=(0,n.getPopupViewRoot)(this.o,this.container,this.od.body),i=new s.Dialog({language:this.o.language,shadowRoot:this.o.shadowRoot,popupRoot:t,ownerWindow:this.o.ownerWindow,defaultTimeout:this.o.defaultTimeout,direction:this.o.direction,theme:this.o.theme,globalFullSize:this.o.globalFullSize,...e});return(0,r.markOwner)(this,i.container),i.parent=this,i.bindDestruct(this)}confirm(e,t,i){return e=l(e,this),t=l(t,this),s.Confirm.call(this.dlg({closeOnClickOverlay:!0}),e,t,i)}prompt(e,t,i,n,o){return e=l(e,this),t=l(t,this),n=l(n,this),s.Prompt.call(this.dlg({closeOnClickOverlay:!0}),e,t,i,n,o)}alert(e,t,i,n){return e=l(e,this),t=l(t,this),s.Alert.call(this.dlg({closeOnClickOverlay:!0}),e,t,i,n)}}function l(e,t){return(0,o.isString)(e)&&!(0,o.isHTML)(e)&&(e=t.i18n(e)),e}},23183:function(e,t,i){"use strict";i.d(t,{Elms:function(){return o}});var n=i(88475);class o{getElm(e){return this.container.querySelector(`.${this.getFullElName(e)}`)}getElms(e){return(0,n.toArray)(this.container.querySelectorAll(`.${this.getFullElName(e)}`))}}},81987:function(e,t,i){"use strict";i.d(t,{Mods:function(){return o}});var n=i(18303);class o{afterSetMod(e,t){}setMod(e,t,i){e=e.toLowerCase();let o=this.mods[e];if(o===t)return this;let r=`${this.componentName}_${e}_`,s=(i||this.container).classList;return null!=o&&s.remove(`${r}${o.toString().toLowerCase()}`),(0,n.isVoid)(t)||""===t||s.add(`${r}${t.toString().toLowerCase()}`),this.mods[e]=t,this.afterSetMod(e,t),this}getMod(e){var t;return null!=(t=this.mods[e])?t:null}}},53681:function(e,t,i){"use strict";i.d(t,{Button:function(){return _},UIButton:function(){return v},UIButtonState:function(){return g}});var n=i(25045),o=i(31635),r=i(69364),s=i(51676),a=i(91672),l=i(68616),u=i(23211),c=i(91565),d=i(85932),h=i(28712),p=i(7909),f=i(96007),m=i(29434);let g=()=>({size:"middle",type:"button",role:"button",name:"",value:"",variant:"initial",disabled:!1,activated:!1,icon:{name:"empty",fill:"",iconURL:"",scale:void 0},tooltip:"",text:"",tabIndex:void 0});class v extends f.UIElement{className(){return"UIButton"}setState(e){return Object.assign(this.state,e),this}get text(){let e=this.getElm("text");return(0,h.assert)(e,"Text element not found"),e}get icon(){let e=this.getElm("icon");return(0,h.assert)(e,"Icon element not found"),e}onChangeSize(){this.setMod("size",this.state.size)}onChangeType(){(0,p.attr)(this.container,"type",this.state.type)}onChangeRole(){(0,p.attr)(this.container,"role",this.state.role)}updateSize(){let e=(0,a.getComponentClass)("UIList"),t=this.closest(e);if(t){this.state.size=t.buttonSize;return}}onChangeStatus(){this.setMod("variant",this.state.variant)}onChangeText(){this.text.textContent=this.jodit.i18n(this.state.text),this.updateAriaLabel()}onChangeTextSetMode(){this.setMod("text-icons",!!this.state.text.trim().length)}onChangeDisabled(){(0,p.attr)(this.container,"disabled",this.state.disabled||null)}onChangeActivated(){(0,p.attr)(this.container,"aria-pressed",this.state.activated)}onChangeName(){this.container.classList.add(`${this.componentName}_${this.clearName(this.state.name)}`),this.name=this.state.name,(0,p.attr)(this.container,"data-ref",this.state.name),(0,p.attr)(this.container,"ref",this.state.name)}onChangeTooltip(){let e=this.state.tooltip?this.jodit.i18n(this.state.tooltip):null;this.get("j.o.useNativeTooltip")&&(0,p.attr)(this.container,"title",e),(0,p.attr)(this.container,"aria-label",e),this.updateAriaLabel()}updateAriaLabel(){let e=this.state.text.trim().length>0,t=this.state.tooltip?this.jodit.i18n(this.state.tooltip):null;(0,p.attr)(this.container,"aria-label",t),(0,p.attr)(this.button,"aria-label",e?null:t)}onChangeTabIndex(){(0,p.attr)(this.container,"tabindex",this.state.tabIndex)}onChangeIcon(){let e=this.get("j.o.textIcons");if(!0===e||(0,c.isFunction)(e)&&e(this.state.name))return;u.Dom.detach(this.icon);let t=m.Icon.makeIcon(this.j,this.state.icon);t&&this.icon.appendChild(t)}focus(){this.container.focus()}isFocused(){let{activeElement:e}=this.od;return!!(e&&u.Dom.isOrContains(this.container,e))}createContainer(){let e=this.componentName,t=this.j.c.element("button",{class:e,type:"button",role:"button",ariaPressed:!1}),i=this.j.c.span(e+"__icon"),n=this.j.c.span(e+"__text");return t.appendChild(i),t.appendChild(n),t}destruct(){return this.j.e.off(this),this.j.e.off(this.container),super.destruct()}onAction(e){return this.actionHandlers.push(e),this}__onActionFire(e){e.buffer={actionTrigger:this},this.actionHandlers.forEach(t=>t.call(this,e)),this.j.e.fire(this,"click",e)}constructor(e,t){super(e),(0,n._)(this,"isButton",!0),(0,n._)(this,"state",g()),(0,n._)(this,"button",void 0),(0,n._)(this,"actionHandlers",[]),this.button=this.container,this.updateSize(),this.onChangeSize(),this.onChangeStatus(),t&&this.hookStatus(r.STATUSES.ready,()=>{this.setState(t)})}}function _(e,t,i,n){let o=new v(e);return o.state.tabIndex=e.o.allowTabNavigation?0:-1,(0,d.isString)(t)?(o.state.icon.name=t,o.state.name=t,n&&(o.state.variant=n),i&&(o.state.text=i)):o.setState(t),o}(0,o.__decorate)([s.cache],v.prototype,"text",null),(0,o.__decorate)([s.cache],v.prototype,"icon",null),(0,o.__decorate)([(0,l.watch)("state.size",{immediately:!1})],v.prototype,"onChangeSize",null),(0,o.__decorate)([(0,l.watch)("state.type",{immediately:!1})],v.prototype,"onChangeType",null),(0,o.__decorate)([(0,l.watch)("state.role",{immediately:!1})],v.prototype,"onChangeRole",null),(0,o.__decorate)([(0,l.watch)("parentElement")],v.prototype,"updateSize",null),(0,o.__decorate)([(0,l.watch)("state.variant",{immediately:!1})],v.prototype,"onChangeStatus",null),(0,o.__decorate)([(0,l.watch)("state.text",{immediately:!1})],v.prototype,"onChangeText",null),(0,o.__decorate)([(0,l.watch)("state.text",{immediately:!1})],v.prototype,"onChangeTextSetMode",null),(0,o.__decorate)([(0,l.watch)("state.disabled")],v.prototype,"onChangeDisabled",null),(0,o.__decorate)([(0,l.watch)("state.activated")],v.prototype,"onChangeActivated",null),(0,o.__decorate)([(0,l.watch)("state.name",{immediately:!1})],v.prototype,"onChangeName",null),(0,o.__decorate)([(0,l.watch)("state.tooltip",{immediately:!1})],v.prototype,"onChangeTooltip",null),(0,o.__decorate)([(0,l.watch)("state.tabIndex",{immediately:!1})],v.prototype,"onChangeTabIndex",null),(0,o.__decorate)([(0,l.watch)("state.icon",{immediately:!1})],v.prototype,"onChangeIcon",null),(0,o.__decorate)([s.cacheHTML],v.prototype,"createContainer",null),(0,o.__decorate)([(0,l.watch)("button:click")],v.prototype,"__onActionFire",null),v=(0,o.__decorate)([a.component],v)},15367:function(e,t,i){"use strict";i.d(t,{UIButtonGroup:function(){return u}});var n=i(25045),o=i(31635),r=i(91672),s=i(28712),a=i(53681),l=i(63468);class u extends l.UIGroup{className(){return"UIButtonGroup"}render(e){return`<div>
9
9
  <div class="&__label">~${e.label}~</div>
10
10
  <div class="&__options"></div>
11
11
  </div>`}appendChildToContainer(e){let t=this.getElm("options");(0,s.assert)(null!=t,"Options does not exist"),t.appendChild(e)}select(e){var t,i;this.elements.forEach((t,i)=>{i===e||t.state.value===e?t.state.activated=!0:this.options.radio&&(t.state.activated=!1)});let n=this.elements.filter(e=>e.state.activated).map(e=>({text:e.state.text,value:e.state.value}));this.jodit.e.fire(this,"select",n),null==(t=(i=this.options).onChange)||t.call(i,n)}constructor(e,t={radio:!0}){var i,o;super(e,null==(o=t.options)?void 0:o.map(t=>{let i=new a.UIButton(e,{text:t.text,value:t.value,variant:"primary"});return i.onAction(()=>{this.select(t.value)}),i}),t),(0,n._)(this,"options",void 0),this.options=t,this.select(null!=(i=t.value)?i:0)}}u=(0,o.__decorate)([r.component],u)},59400:function(e,t,i){"use strict";i.d(t,{Button:function(){return n.Button},UIButton:function(){return n.UIButton},UIButtonGroup:function(){return o.UIButtonGroup},UIButtonState:function(){return n.UIButtonState},UITooltip:function(){return r.UITooltip}});var n=i(53681),o=i(15367),r=i(95399)},95399:function(e,t,i){"use strict";i.d(t,{UITooltip:function(){return f}});var n=i(25045),o=i(31635),r=i(16964),s=i(84839),a=i(27795),l=i(28077),u=i(23599),c=i(93640),d=i(96007);let h=["scroll.tooltip","joditCloseDialog","mouseleave.tooltip"],p=["escape.tooltip","change.tooltip","changePlace.tooltip","afterOpenPopup.tooltip","hidePopup.tooltip","beforePopupClose.tooltip","closeAllPopups.tooltip"];class f extends d.UIElement{className(){return"UITooltip"}render(){return'<div><div class="&__content"></div></div>'}__onAttach(e){(0,l.getContainer)(this.j,f).appendChild(this.container),this.__attachedContainers.add(e),this.__attachedContainers.add(this.j.container),this.j.e.on(e,"mouseenter.tooltip",this.__onMouseEnter,{capture:!0}).on(e,"mouseleave.tooltip",this.__onMouseLeave,{capture:!0}).on(this.j.container,"mouseleave.tooltip",this.__onMouseLeave,{capture:!0})}__addListenersOnEnter(){if(this.__listenClose)return;this.__listenClose=!0;let e=this.j;e.e.on(e.ow,h,this.__hide).on(p,this.__hide)}__removeListenersOnLeave(){if(!this.__listenClose)return;this.__listenClose=!1;let e=this.j;e.e.off(e.ow,h,this.__hide).off(p,this.__hide)}__onMouseLeave(e){this.__currentTarget===e.target&&(this.__hideDelay(),this.__currentTarget=null)}__onMouseEnter(e){if(!a.Dom.isHTMLElement(e.target))return;let t=(0,c.attr)(e.target,"aria-label");if(!t||(0,c.attr)(e.target,"disabled")||!e.target.className.includes("jodit"))return;this.__currentTarget=e.target;let i=e.target;this.__open(()=>{let e=(0,u.position)(i);return{x:e.left+e.width/2,y:e.top+e.height}},t)}__open(e,t){this.__addListenersOnEnter(),this.__isOpened=!0,this.j.async.clearTimeout(this.__hideTimeout),this.j.async.clearTimeout(this.__delayShowTimeout);let i=this.j.o.showTooltipDelay||this.j.defaultTimeout;i?this.__delayShowTimeout=this.j.async.setTimeout(()=>this.__show(e,t),i):this.__show(e,t)}__show(e,t){this.setMod("visible",!0),this.setMod("above",!1),this.getElm("content").innerHTML=t;let i=e();(0,c.css)(this.container,{left:i.x,top:i.y});let n=(0,u.position)(this.container),o=this.j.ow.innerHeight;if(n.top+n.height>o){let e=(0,u.position)(this.__currentTarget);this.setMod("above",!0),(0,c.css)(this.container,{top:e.top-n.height})}}__hide(){this.j.async.clearTimeout(this.__delayShowTimeout),this.j.async.clearTimeout(this.__hideTimeout),this.__removeListenersOnLeave(),this.__isOpened&&(this.__isOpened=!1,this.setMod("visible",!1),this.getElm("content").innerHTML="",(0,c.css)(this.container,{left:-5e3}))}__hideDelay(){this.j.async.clearTimeout(this.__delayShowTimeout),this.j.async.clearTimeout(this.__hideTimeout),this.__isOpened&&(this.__hideTimeout=this.async.setTimeout(this.__hide,this.j.defaultTimeout))}destruct(){this.__attachedContainers.forEach(e=>{this.j.e.off(e,"mouseenter.tooltip",this.__onMouseEnter).off(e,"mouseleave.tooltip",this.__onMouseLeave)}),this.__hide(),super.destruct()}constructor(e){super(e),(0,n._)(this,"__isOpened",!1),(0,n._)(this,"__attachedContainers",new Set),(0,n._)(this,"__listenClose",!1),(0,n._)(this,"__currentTarget",null),(0,n._)(this,"__delayShowTimeout",0),(0,n._)(this,"__hideTimeout",0),e.o.textIcons||!e.o.showTooltip||e.o.useNativeTooltip||(this.j.e.on("getContainer",e=>{this.__onAttach(e)}),e.hookStatus(r.STATUSES.ready,()=>{this.__onAttach(this.j.container)}))}}(0,o.__decorate)([s.autobind],f.prototype,"__onMouseLeave",null),(0,o.__decorate)([s.autobind],f.prototype,"__onMouseEnter",null),(0,o.__decorate)([s.autobind],f.prototype,"__hide",null),(0,o.__decorate)([s.autobind],f.prototype,"__hideDelay",null),f=(0,o.__decorate)([s.component],f)},96007:function(e,t,i){"use strict";i.d(t,{UIElement:function(){return p}});var n=i(25045),o=i(31635),r=i(16964),s=i(24968),a=i(23211),l=i(85932),u=i(7909),c=i(23183),d=i(81987),h=i(29434);class p extends r.ViewComponent{getRole(){var e;return(null==(e=this.options)?void 0:e.role)||""}get parentElement(){return this.__parentElement}set parentElement(e){this.__parentElement=e,e&&e.hookStatus("beforeDestruct",()=>this.destruct()),this.updateParentElement(this)}bubble(e){let t=this.parentElement;for(;t;)e(t),t=t.parentElement;return this}updateParentElement(e){var t;return null==(t=this.__parentElement)||t.updateParentElement(e),this}get(e,t){return super.get(e,t)||this.getElm(e)}closest(e){let t="object"==typeof e?t=>t===e:t=>r.Component.isInstanceOf(t,e),i=this.__parentElement;for(;i;){if(t(i))return i;i=!i.parentElement&&i.container.parentElement?p.closestElement(i.container.parentElement,p):i.parentElement}return null}static closestElement(e,t){let i=a.Dom.up(e,e=>{if(e){let{component:i}=e;return i&&r.Component.isInstanceOf(i,t)}return!1});return i?null==i?void 0:i.component:null}update(){}appendTo(e){return e.appendChild(this.container),this}clearName(e){return e.replace(/[^a-zA-Z0-9]/g,"_")}render(e){return this.j.c.div(this.componentName)}createContainer(e){let t=this.render(e);if((0,l.isString)(t)){let e=this.parseTemplate(t);return e.classList.add(this.componentName),e}return t}parseTemplate(e){return this.j.c.fromHTML(e.replace(/\*([^*]+?)\*/g,(e,t)=>h.Icon.get(t)||"").replace(/&_/g,this.componentName+"_").replace(/~([^~]+?)~/g,(e,t)=>this.i18n(t)))}destruct(){return a.Dom.safeRemove(this.container),this.parentElement=null,super.destruct()}constructor(e,t){super(e),(0,n._)(this,"container",void 0),(0,n._)(this,"name",""),(0,n._)(this,"options",void 0),(0,n._)(this,"__parentElement",null),(0,n._)(this,"mods",{}),this.options=t,this.container=this.createContainer(t);const i=this.getRole();i&&(0,u.attr)(this.container,"role",i),Object.defineProperty(this.container,"component",{value:this,configurable:!0})}}p=(0,o.__decorate)([(0,s.derive)(d.Mods,c.Elms)],p)},4561:function(e,t,i){"use strict";i.d(t,{UIBlock:function(){return l}});var n=i(25045),o=i(31635),r=i(91672),s=i(93640),a=i(63468);class l extends a.UIGroup{className(){return"UIBlock"}constructor(e,t,i={align:"left"}){super(e,t),(0,n._)(this,"options",void 0),this.options=i,this.setMod("align",this.options.align||"left"),this.setMod("width",this.options.width||""),this.options.mod&&this.setMod(this.options.mod,!0),this.options.className&&this.container.classList.add(this.options.className),(0,s.attr)(this.container,"data-ref",i.ref),(0,s.attr)(this.container,"ref",i.ref)}}l=(0,o.__decorate)([r.component],l)},98838:function(e,t,i){"use strict";i.d(t,{UIForm:function(){return c}});var n=i(31635),o=i(80251),r=i(91672),s=i(93640),a=i(65273),l=i(49999),u=i(63468);class c extends u.UIGroup{className(){return"UIForm"}submit(){this.j.e.fire(this.container,"submit")}validate(){for(let e of this.allChildren.filter(e=>o.Component.isInstanceOf(e,a.UIInput)))if(!e.validate())return!1;for(let e of this.allChildren.filter(e=>o.Component.isInstanceOf(e,l.UISelect)))if(!e.validate())return!1;return!0}onSubmit(e){return this.j.e.on(this.container,"submit",()=>{let t=this.allChildren.filter(e=>o.Component.isInstanceOf(e,a.UIInput));return!!this.validate()&&(e(t.reduce((e,t)=>(e[t.state.name]=t.value,e),{})),!1)}),this}createContainer(){let e=this.j.c.element("form");return e.classList.add(this.componentName),(0,s.attr)(e,"dir",this.j.o.direction||"auto"),(0,s.attr)(e,"novalidate",""),e}constructor(...e){var t,i;super(...e),(null==(t=this.options)?void 0:t.className)&&this.container.classList.add(null==(i=this.options)?void 0:i.className)}}c=(0,n.__decorate)([r.component],c)},5658:function(e,t,i){"use strict";i.d(t,{UIBlock:function(){return n.UIBlock},UICheckbox:function(){return r.UICheckbox},UIFileInput:function(){return r.UIFileInput},UIForm:function(){return o.UIForm},UIInput:function(){return r.UIInput},UISelect:function(){return r.UISelect},UITextArea:function(){return r.UITextArea}});var n=i(4561),o=i(98838),r=i(2602)},87329:function(e,t,i){"use strict";i.d(t,{UITextArea:function(){return l}});var n=i(25045),o=i(31635),r=i(84839),s=i(91672),a=i(65273);class l extends a.UIInput{className(){return"UITextArea"}createNativeInput(e){return this.j.create.element("textarea")}onChangeStateSize(){let{size:e,resizable:t}=this.state;this.nativeInput.style.resize=t?"auto":"none",this.nativeInput.rows=null!=e?e:5}constructor(e,t){super(e,t),(0,n._)(this,"state",{...l.defaultState}),Object.assign(this.state,t),!1===this.state.resizable&&(this.nativeInput.style.resize="none")}}(0,n._)(l,"defaultState",{...a.UIInput.defaultState,size:5,resizable:!0}),(0,o.__decorate)([(0,r.watch)(["state.size","state.resizable"])],l.prototype,"onChangeStateSize",null),l=(0,o.__decorate)([s.component],l)},24641:function(e,t,i){"use strict";i.d(t,{UICheckbox:function(){return l}});var n=i(25045),o=i(31635),r=i(84839),s=i(23211),a=i(65273);class l extends a.UIInput{className(){return"UICheckbox"}render(){return this.j.c.element("label",{className:this.componentName})}onChangeChecked(){this.value=this.state.checked.toString(),this.nativeInput.checked=this.state.checked,this.setMod("checked",this.state.checked)}onChangeNativeCheckBox(){this.state.checked=this.nativeInput.checked}onChangeSwitch(){this.setMod("switch",this.state.switch);let e=this.getElm("switch-slider");this.state.switch?(e||(e=this.j.c.div(this.getFullElName("switch-slider"))),s.Dom.after(this.nativeInput,e)):s.Dom.safeRemove(e)}constructor(e,t){super(e,{...t,type:"checkbox"}),(0,n._)(this,"state",{...l.defaultState}),Object.assign(this.state,t)}}(0,n._)(l,"defaultState",{...a.UIInput.defaultState,checked:!1,switch:!1}),(0,o.__decorate)([(0,r.watch)("state.checked"),(0,r.hook)("ready")],l.prototype,"onChangeChecked",null),(0,o.__decorate)([(0,r.watch)("nativeInput:change")],l.prototype,"onChangeNativeCheckBox",null),(0,o.__decorate)([(0,r.watch)("state.switch"),(0,r.hook)("ready")],l.prototype,"onChangeSwitch",null),l=(0,o.__decorate)([r.component],l)},75587:function(e,t,i){"use strict";i.d(t,{UIFileInput:function(){return l}});var n=i(25045),o=i(31635),r=i(91672),s=i(53681),a=i(65273);class l extends a.UIInput{className(){return"UIFileInput"}createContainer(e){this.button=new s.UIButton(this.j,{tooltip:e.tooltip,icon:{name:"plus"}});let{container:t}=this.button;this.nativeInput||(this.nativeInput=this.createNativeInput(e));let{nativeInput:i}=this;return i.classList.add(this.getFullElName("input")),t.classList.add(this.componentName),t.appendChild(i),t}createNativeInput(e){return this.j.create.fromHTML(`<input
@@ -16,7 +16,7 @@
16
16
  multiple=""
17
17
  />`)}constructor(e,t){super(e,{type:"file",...t}),(0,n._)(this,"state",{...a.UIInput.defaultState,type:"file",onlyImages:!0})}}l=(0,o.__decorate)([r.component],l)},2602:function(e,t,i){"use strict";i.d(t,{UICheckbox:function(){return o.UICheckbox},UIFileInput:function(){return r.UIFileInput},UIInput:function(){return s.UIInput},UISelect:function(){return a.UISelect},UITextArea:function(){return n.UITextArea}});var n=i(87329),o=i(24641),r=i(75587),s=i(65273),a=i(49999)},65273:function(e,t,i){"use strict";i.d(t,{UIInput:function(){return h}});var n=i(25045),o=i(31635),r=i(84839),s=i(23211),a=i(88475),l=i(93640),u=i(96007),c=i(81488),d=i(29434);class h extends u.UIElement{className(){return"UIInput"}onChangeClear(){this.state.clearButton?s.Dom.after(this.nativeInput,this.clearButton):s.Dom.safeRemove(this.clearButton)}onChangeClassName(e,t){t&&this.container.classList.remove(t),this.state.className&&this.container.classList.add(this.state.className)}onChangeState(){this.name=this.state.name;let e=this.nativeInput,{name:t,icon:i,type:n,ref:o,required:r,placeholder:a,autocomplete:u,label:c}=this.state;(0,l.attr)(e,"name",t),(0,l.attr)(e,"type",n),(0,l.attr)(e,"data-ref",o||t),(0,l.attr)(e,"ref",o||t),(0,l.attr)(e,"required",r||null),(0,l.attr)(e,"autocomplete",u?null:"off"),(0,l.attr)(e,"placeholder",a?this.j.i18n(a):""),i&&d.Icon.exists(i)?(s.Dom.before(e,this.icon),this.icon.innerHTML=d.Icon.get(i)):s.Dom.safeRemove(this.icon),c?(s.Dom.before(this.wrapper,this.label),this.label.innerText=this.j.i18n(c)):s.Dom.safeRemove(this.label),this.updateValidators()}updateValidators(){var e;this.validators.clear(),this.state.required&&this.validators.add(c.inputValidators.required),null==(e=this.state.validators)||e.forEach(e=>{let t=c.inputValidators[e];t&&this.validators.add(t)})}set error(e){this.setMod("has-error",!!e),e?(this.__errorBox.innerText=this.j.i18n(e,this.j.i18n(this.state.label||"")),this.container.appendChild(this.__errorBox)):s.Dom.safeRemove(this.__errorBox)}get value(){return this.nativeInput.value}set value(e){this.value!==e&&(this.nativeInput.value=e,this.onChangeValue())}onChangeStateValue(){let e=this.state.value.toString();e!==this.value&&(this.value=e)}onChangeValue(){let{value:e}=this;if(this.state.value!==e){var t,i;this.state.value=e,this.j.e.fire(this,"change",e),null==(t=(i=this.state).onChange)||t.call(i,e)}}validate(){this.error="";let e=(0,a.toArray)(this.validators).every(e=>e(this));return this.__markInputInvalid(),e}__markInputInvalid(){var e,t,i,n;this.error?(this.nativeInput.setAttribute("aria-invalid","true"),null==(e=(t=this.nativeInput).setCustomValidity)||e.call(t,this.error)):(this.nativeInput.removeAttribute("aria-invalid"),null==(i=(n=this.nativeInput).setCustomValidity)||i.call(n,""))}createContainer(e){let t=super.createContainer();this.wrapper=this.j.c.div(this.getFullElName("wrapper")),this.nativeInput||(this.nativeInput=this.createNativeInput());let{nativeInput:i}=this;return i.classList.add(this.getFullElName("input")),this.wrapper.appendChild(i),t.appendChild(this.wrapper),(0,l.attr)(i,"dir",this.j.o.direction||"auto"),t}createNativeInput(e){return this.j.create.element("input")}focus(){this.nativeInput.focus()}get isFocused(){return this.nativeInput===this.j.od.activeElement}onChangeFocus(){this.setMod("focused",this.isFocused)}constructor(e,t){super(e,t),(0,n._)(this,"label",this.j.c.span(this.getFullElName("label"))),(0,n._)(this,"icon",this.j.c.span(this.getFullElName("icon"))),(0,n._)(this,"clearButton",this.j.c.span(this.getFullElName("clear"),d.Icon.get("cancel"))),(0,n._)(this,"state",{...h.defaultState}),(0,n._)(this,"__errorBox",this.j.c.span(this.getFullElName("error"))),(0,n._)(this,"validators",new Set([])),(null==t?void 0:t.value)!==void 0&&(t.value=t.value.toString()),Object.assign(this.state,t),void 0!==this.state.clearButton&&(this.j.e.on(this.clearButton,"click",e=>{e.preventDefault(),this.nativeInput.value="",this.j.e.fire(this.nativeInput,"input"),this.focus()}).on(this.nativeInput,"input",()=>{this.state.clearButton=!!this.value.length}),this.state.clearButton=!!this.value.length),this.j.e.on(this.nativeInput,"focus blur",()=>{this.onChangeFocus()}).on(this.nativeInput,"input change",this.onChangeValue),this.onChangeState(),this.onChangeClassName(),this.onChangeStateValue()}}(0,n._)(h,"defaultState",{className:"",autocomplete:!0,name:"",value:"",icon:"",label:"",ref:"",type:"text",placeholder:"",required:!1,validators:[]}),(0,o.__decorate)([(0,r.watch)("state.clearButton")],h.prototype,"onChangeClear",null),(0,o.__decorate)([(0,r.watch)("state.className")],h.prototype,"onChangeClassName",null),(0,o.__decorate)([(0,r.watch)(["state.name","state.type","state.label","state.placeholder","state.autocomplete","state.icon"],{immediately:!1}),(0,r.debounce)()],h.prototype,"onChangeState",null),(0,o.__decorate)([(0,r.watch)("state.value")],h.prototype,"onChangeStateValue",null),(0,o.__decorate)([r.autobind],h.prototype,"onChangeValue",null),h=(0,o.__decorate)([r.component],h)},49999:function(e,t,i){"use strict";i.d(t,{UISelect:function(){return u}});var n=i(25045),o=i(31635),r=i(91672),s=i(7909),a=i(65273),l=i(81488);class u extends a.UIInput{className(){return"UISelect"}createContainer(e){var t;let i=super.createContainer(e),{j:n}=this,{nativeInput:o}=this;if(void 0!==e.placeholder){let t=n.create.element("option");t.value="",t.text=n.i18n(e.placeholder),o.add(t)}return null==(t=e.options)||t.forEach(e=>{let t=n.create.element("option");t.value=e.value.toString(),t.text=n.i18n(e.text),o.add(t)}),e.size&&e.size>0&&(0,s.attr)(o,"size",e.size),e.multiple&&(0,s.attr)(o,"multiple",""),i}createNativeInput(){return this.j.create.element("select")}updateValidators(){super.updateValidators(),this.state.required&&(this.validators.delete(l.inputValidators.required),this.validators.add(l.selectValidators.required))}constructor(e,t){super(e,t),(0,n._)(this,"state",{...u.defaultState}),Object.assign(this.state,t)}}(0,n._)(u,"defaultState",{...a.UIInput.defaultState,options:[],size:1,multiple:!1}),u=(0,o.__decorate)([r.component],u)},81488:function(e,t,i){"use strict";i.d(t,{inputValidators:function(){return n},selectValidators:function(){return o}});var n=i(48776),o=i(6490)},48776:function(e,t,i){"use strict";i.r(t),i.d(t,{required:function(){return r},url:function(){return s}});var n=i(91764),o=i(4040);let r=function(e){return!!(0,o.trim)(e.value).length||(e.error="Please fill out this field",!1)},s=function(e){return!!(0,n.isURL)((0,o.trim)(e.value))||(e.error="Please enter a web address",!1)}},6490:function(e,t,i){"use strict";i.d(t,{required:function(){return o}});var n=i(4040);let o=function(e){return!!(0,n.trim)(e.value).length||(e.error="Please fill out this field",!1)}},63468:function(e,t,i){"use strict";i.d(t,{UIGroup:function(){return c}});var n=i(25045),o=i(31635),r=i(80251),s=i(84839),a=i(23211),l=i(65946),u=i(96007);class c extends u.UIElement{className(){return"UIGroup"}getRole(){var e;return(null==(e=this.options)?void 0:e.role)||"list"}get allChildren(){let e=[],t=[...this.elements];for(;t.length;){let i=t.shift();(0,l.isArray)(i)?t.push(...i):r.Component.isInstanceOf(i,c)?t.push(...i.elements):i&&e.push(i)}return e}update(){this.elements.forEach(e=>e.update()),this.setMod("size",this.buttonSize)}append(e,t){let i;if((0,l.isArray)(e)){if("number"==typeof t)throw Error("You can not use index when append array of elements");return e.forEach(e=>this.append(e,t)),this}if("number"==typeof t?(i=Math.min(Math.max(0,t),this.elements.length),this.elements.splice(i,0,e)):this.elements.push(e),e.name&&e.container.classList.add(this.getFullElName(e.name)),t&&"string"==typeof t){let i=this.getElm(t);if(null==i)throw Error("Element does not exist");i.appendChild(e.container)}else this.appendChildToContainer(e.container,i);return e.parentElement=this,this}afterSetMod(e,t){this.syncMod&&this.elements.forEach(i=>i.setMod(e,t))}appendChildToContainer(e,t){void 0===t||t<0||t>this.elements.length-1||null==this.container.children[t]?this.container.appendChild(e):this.container.insertBefore(e,this.container.children[t])}remove(e){let t=this.elements.indexOf(e);return -1!==t&&(this.elements.splice(t,1),a.Dom.safeRemove(e.container),e.parentElement=null),this}clear(){return this.elements.forEach(e=>e.destruct()),this.elements.length=0,this}setParentView(e){var t;return null==(t=this.elements)||t.forEach(t=>t.setParentView(e)),super.setParentView(e)}destruct(){return this.clear(),super.destruct()}constructor(e,t,i){super(e,i),(0,n._)(this,"options",void 0),(0,n._)(this,"syncMod",void 0),(0,n._)(this,"elements",void 0),(0,n._)(this,"buttonSize",void 0),this.options=i,this.syncMod=!1,this.elements=[],this.buttonSize="middle",null==t||t.forEach(e=>e&&this.append(e)),(null==i?void 0:i.name)&&(this.name=i.name)}}(0,o.__decorate)([(0,s.watch)("buttonSize")],c.prototype,"update",null),c=(0,o.__decorate)([s.component],c)},64847:function(e,t,i){"use strict";i.d(t,{UIGroup:function(){return n.UIGroup},UIList:function(){return o.UIList},UISeparator:function(){return r.UISeparator},UISpacer:function(){return s.UISpacer}});var n=i(63468),o=i(97959),r=i(35676),s=i(27987)},97959:function(e,t,i){"use strict";i.d(t,{UIList:function(){return v}});var n=i(25045),o=i(31635),r=i(80251),s=i(91672),a=i(29200),l=i(68616),u=i(32328),c=i(53681),d=i(63468),h=i(35676),p=i(27987),f=i(2496),m=i(15982),g=i(40253);class v extends d.UIGroup{className(){return"UIList"}getRole(){return"list"}__onChangeMode(){this.setMod("mode",this.mode)}makeGroup(e){return new d.UIGroup(this.jodit,[],e?{role:e}:void 0)}get buttons(){return this.allChildren.filter(e=>r.Component.isInstanceOf(e,c.UIButton))}getButtonsNames(){return this.buttons.map(e=>e instanceof c.UIButton&&e.state.name||"").filter(e=>""!==e)}setRemoveButtons(e){return this.removeButtons=e||[],this}build(e,t=null){let i;e=(0,u.splitArray)(e),this.clear();let n=!1,o=this.makeGroup("group");this.append(o),o.setMod("line",!0);let r=e=>{let r=null;switch(e.name){case"\n":(o=this.makeGroup("group")).setMod("line",!0),i=this.makeGroup(),o.append(i),this.append(o);break;case"|":n||(n=!0,r=new h.UISeparator(this.j));break;case"---":{i.setMod("before-spacer",!0);let e=new p.UISpacer(this.j);o.append(e),i=this.makeGroup(),o.append(i),n=!1;break}default:n=!1,r="select"===e.component?this.makeSelect(e,t):this.makeButton(e,t)}r&&(i||(i=this.makeGroup(),o.append(i)),i.append(r))},s=e=>{var t;return!this.removeButtons.includes(e.name)&&(!e.isVisible||(null==(t=e.isVisible)?void 0:t.call(e,this.j,e)))};return e.forEach(e=>{if((0,f.isButtonGroup)(e)){let t=e.buttons.filter(e=>e);t.length&&((i=this.makeGroup()).setMod("separated",!0).setMod("group",e.group),o.append(i),(0,g.getStrongControlTypes)(t,this.j.o.controls).filter(s).forEach(r))}else{i||(i=this.makeGroup(),o.append(i));let t=(0,m.getControlType)(e,this.j.o.controls);s(t)&&r(t)}}),this.update(),this}makeSelect(e,t){throw Error("Not implemented behaviour")}makeButton(e,t){return new c.UIButton(this.j,{name:e.name})}constructor(...e){super(...e),(0,n._)(this,"mode","horizontal"),(0,n._)(this,"removeButtons",[])}}(0,o.__decorate)([(0,l.watch)("mode"),(0,a.hook)("ready")],v.prototype,"__onChangeMode",null),v=(0,o.__decorate)([s.component],v)},35676:function(e,t,i){"use strict";i.d(t,{UISeparator:function(){return s}});var n=i(31635),o=i(91672),r=i(96007);class s extends r.UIElement{className(){return"UISeparator"}}s=(0,n.__decorate)([o.component],s)},27987:function(e,t,i){"use strict";i.d(t,{UISpacer:function(){return s}});var n=i(31635),o=i(91672),r=i(96007);class s extends r.UIElement{className(){return"UISpacer"}}s=(0,n.__decorate)([o.component],s)},2496:function(e,t,i){"use strict";i.d(t,{flatButtonsSet:function(){return r},isButtonGroup:function(){return o}});var n=i(17312);let o=e=>(0,n.isArray)(e.buttons);function r(e,t){let i=t.getRegisteredButtonGroups();return new Set(e.reduce((e,t)=>{if(o(t)){var n;e=e.concat([...t.buttons,...null!=(n=i[t.group])?n:[]])}else e.push(t);return e},[]))}},15982:function(e,t,i){"use strict";i.d(t,{findControlType:function(){return s},getControlType:function(){return r}});var n=i(65946),o=i(5266);function r(e,t){let i;return t||(t=o.Config.defaultOptions.controls),(0,n.isString)(e)?i=s(e,t)||{name:e,command:e,tooltip:e}:void 0!==t[(i={name:"empty",...(0,n.ConfigFlatten)(e)}).name]&&(i={...(0,n.ConfigFlatten)(t[i.name]),...(0,n.ConfigFlatten)(i)}),i}function s(e,t){let[i,o]=e.split(/\./),r=t;return null!=o?void 0!==t[i]&&(r=t[i]):o=i,r[o]?{name:o,...(0,n.ConfigFlatten)(r[o])}:void 0}},40253:function(e,t,i){"use strict";i.d(t,{getStrongControlTypes:function(){return a}});var n=i(17312),o=i(93640),r=i(5266),s=i(15982);function a(e,t){return((0,n.isArray)(e)?e:(0,o.keys)(e,!1).map(t=>{let i=e[t]||{};return(0,o.ConfigProto)({name:t},i)})).map(e=>(0,s.getControlType)(e,t||r.Config.defaultOptions.controls))}},29434:function(e,t,i){"use strict";i.d(t,{Icon:function(){return a}});var n=i(25045),o=i(81937),r=i(65946),s=i(80991);class a{static getIcon(e){if(/<svg/i.test(e))return e;let t=a.icons[e]||a.icons[e.replace(/-/g,"_")]||a.icons[e.replace(/_/g,"-")]||a.icons[(0,r.camelCase)(e)]||a.icons[(0,r.kebabCase)(e)]||a.icons[e.toLowerCase()];return o.IS_PROD,t}static exists(e){return void 0!==this.getIcon(e)}static get(e,t="<span></span>"){return this.getIcon(e)||t}static set(e,t){return this.icons[e.replace("_","-")]=t,this}static makeIcon(e,t){var i,n,o,r;let l,u;if(!t)return;let{name:c,iconURL:d,fill:h,scale:p}=t,f=c.replace(/[^a-zA-Z0-9]/g,"_");/<svg/.test(c)||(u=null==(i=(n=e.o).getIcon)?void 0:i.call(n,c,f));let m=`${c}${d}${h}${null!=p?p:""}${null!=u?u:""}`;if(e.o.cache&&this.__cache.has(m))return null==(o=this.__cache.get(m))?void 0:o.cloneNode(!0);if(d)l=e.c.span(),(0,s.css)(l,"backgroundImage","url("+d.replace("{basePath}",(null==e?void 0:e.basePath)||"")+")");else{let t=u||a.get(c,"")||(null==(r=e.o.extraIcons)?void 0:r[c]);t&&(l=e.c.fromHTML(t.trim()),/^<svg/i.test(c)||l.classList.add("jodit-icon_"+f))}return l&&(l.classList.add("jodit-icon"),l.style.fill=h,null!=p&&(l.style.transform=`scale(${p})`),e.o.cache&&this.__cache.set(m,l.cloneNode(!0))),l}}(0,n._)(a,"icons",{}),(0,n._)(a,"__cache",new Map)},4099:function(e,t,i){"use strict";i.d(t,{Button:function(){return n.Button},Icon:function(){return a.Icon},Popup:function(){return l.Popup},ProgressBar:function(){return u.ProgressBar},UIBlock:function(){return r.UIBlock},UIButton:function(){return n.UIButton},UIButtonGroup:function(){return n.UIButtonGroup},UIButtonState:function(){return n.UIButtonState},UICheckbox:function(){return r.UICheckbox},UIElement:function(){return o.UIElement},UIFileInput:function(){return r.UIFileInput},UIForm:function(){return r.UIForm},UIGroup:function(){return s.UIGroup},UIInput:function(){return r.UIInput},UIList:function(){return s.UIList},UISelect:function(){return r.UISelect},UISeparator:function(){return s.UISeparator},UISpacer:function(){return s.UISpacer},UITextArea:function(){return r.UITextArea},UITooltip:function(){return n.UITooltip}});var n=i(59400),o=i(96007),r=i(5658),s=i(64847),a=i(29434),l=i(56490),u=i(34396)},56490:function(e,t,i){"use strict";i.d(t,{Popup:function(){return n.Popup}});var n=i(51116)},51116:function(e,t,i){"use strict";i.d(t,{Popup:function(){return f}});var n=i(25045),o=i(31635),r=i(80251),s=i(84839),a=i(23211),l=i(28077),u=i(65946),c=i(28712),d=i(96007),h=i(63468);let p=["escape","cut","delete","backSpaceAfterDelete","beforeCommandDelete"];class f extends h.UIGroup{className(){return"Popup"}appendChildToContainer(e){let t=this.getElm("content");(0,c.assert)(t,"Content element should exist"),t.appendChild(e)}updateParentElement(e){return e!==this&&r.Component.isInstanceOf(e,f)&&(this.__childrenPopups.forEach(t=>{!e.closest(t)&&t.isOpened&&t.close()}),this.__childrenPopups.has(e)||this.j.e.on(e,"beforeClose",()=>{this.__childrenPopups.delete(e)}),this.__childrenPopups.add(e)),super.updateParentElement(e)}setContent(e){if(this.allChildren.length)throw Error("Remove children");if(r.Component.isInstanceOf(e,d.UIElement))this.append(e);else{let t=(0,u.isString)(e)?this.j.c.fromHTML(e):e;this.appendChildToContainer(t)}return this.updatePosition(),this}open(e,t=!1,i){if((0,u.markOwner)(this.jodit,this.container),this.container.classList.add(`jodit_theme_${this.jodit.o.theme}`),this.__calculateZIndex(),this.isOpened=!0,this.__addGlobalListeners(),this.__targetBound=t?this.getKeepBound(e):e,i)i.appendChild(this.container);else{let e=(0,l.getContainer)(this.jodit,f);i!==this.container.parentElement&&e.appendChild(this.container)}return this.updatePosition(),this.j.e.fire(this,"afterOpen"),this.j.e.fire("afterOpenPopup",this),this}__calculateZIndex(){if(this.container.style.zIndex)return;let e=e=>{let t=e.container.style.zIndex||e.o.zIndex;return!!t&&(this.setZIndex(1+parseInt(t.toString(),10)),!0)},{j:t}=this;if(e(t))return;let i=this.parentElement;for(;i;){if(e(i.j))return;if(i.container.style.zIndex)return void this.setZIndex(1+parseInt(i.container.style.zIndex.toString(),10));if(!i.parentElement&&i.container.parentElement){let e=d.UIElement.closestElement(i.container.parentElement,d.UIElement);if(e){i=e;continue}}i=i.parentElement}}getKeepBound(e){let t=e(),i=this.od.elementFromPoint(t.left,t.top);if(!i)return e;let n=a.Dom.isHTMLElement(i)?i:i.parentElement,o=(0,u.position)(n,this.j);return()=>{let t=e(),i=(0,u.position)(n,this.j);return{...t,top:t.top+(i.top-o.top),left:t.left+(i.left-o.left)}}}updatePosition(){if(!this.isOpened)return this;let[e,t]=this.__calculatePosition(this.__targetBound(),this.viewBound(),(0,u.position)(this.container,this.j));return this.setMod("strategy",t),(0,u.css)(this.container,{left:e.left,top:e.top}),this.__childrenPopups.forEach(e=>e.updatePosition()),this}__throttleUpdatePosition(){this.updatePosition()}__calculatePosition(e,t,i,n=this.strategy){let o={left:e.left,right:e.left-(i.width-e.width)},r={bottom:e.top+e.height,top:e.top-i.height},s=Object.keys(o).reduce((e,t)=>e.concat(Object.keys(r).map(e=>`${t}${(0,u.ucfirst)(e)}`)),[]),a=e=>{let[t,n]=(0,u.kebabCase)(e).split("-");return{left:o[t],top:r[n],width:i.width,height:i.height}},l=e=>f.boxInView(a(n),e)?n:s.find(t=>{if(f.boxInView(a(t),e))return t})||null,c=l((0,u.position)(this.j.container,this.j));return c&&f.boxInView(a(c),t)||(c=l(t)||c||n),[a(c),c]}static boxInView(e,t){return e.top-t.top>=-2&&e.left-t.left>=-2&&t.top+t.height-(e.top+e.height)>=-2&&t.left+t.width-(e.left+e.width)>=-2}close(){return this.isOpened&&(this.isOpened=!1,this.__childrenPopups.forEach(e=>e.close()),this.j.e.fire(this,"beforeClose"),this.j.e.fire("beforePopupClose",this),this.__removeGlobalListeners(),a.Dom.safeRemove(this.container)),this}__closeOnOutsideClick(e){!this.isOpened||this.isOwnClick(e)||this.close()}isOwnClick(e){if(!e.target)return!1;let t=d.UIElement.closestElement(e.target,f);return!!(t&&(this===t||t.closest(this)))}__addGlobalListeners(){let e=this.__throttleUpdatePosition,t=this.ow;l.eventEmitter.on("closeAllPopups",this.close),this.smart&&this.j.e.on(p,this.close).on("mousedown touchstart",this.__closeOnOutsideClick).on(t,"mousedown touchstart",this.__closeOnOutsideClick),this.j.e.on("closeAllPopups",this.close).on("resize",e).on(this.container,"scroll mousewheel",e).on(t,"scroll",e).on(t,"resize",e),a.Dom.up(this.j.container,t=>{t&&this.j.e.on(t,"scroll mousewheel",e)})}__removeGlobalListeners(){let e=this.__throttleUpdatePosition,t=this.ow;l.eventEmitter.off("closeAllPopups",this.close),this.smart&&this.j.e.off(p,this.close).off("mousedown touchstart",this.__closeOnOutsideClick).off(t,"mousedown touchstart",this.__closeOnOutsideClick),this.j.e.off("closeAllPopups",this.close).off("resize",e).off(this.container,"scroll mousewheel",e).off(t,"scroll",e).off(t,"resize",e),this.j.container.isConnected&&a.Dom.up(this.j.container,t=>{t&&this.j.e.off(t,"scroll mousewheel",e)})}setZIndex(e){this.container.style.zIndex=e.toString()}render(){return`<div>
18
18
  <div class="&__content"></div>
19
- </div>`}destruct(){return this.close(),super.destruct()}constructor(e,t=!0){super(e),(0,n._)(this,"smart",void 0),(0,n._)(this,"isOpened",void 0),(0,n._)(this,"strategy",void 0),(0,n._)(this,"viewBound",void 0),(0,n._)(this,"__targetBound",void 0),(0,n._)(this,"__childrenPopups",void 0),this.smart=t,this.isOpened=!1,this.strategy="leftBottom",this.viewBound=()=>({left:0,top:0,width:this.ow.innerWidth,height:this.ow.innerHeight}),this.__childrenPopups=new Set,(0,u.attr)(this.container,"role","popup")}}(0,o.__decorate)([s.autobind],f.prototype,"updatePosition",null),(0,o.__decorate)([(0,s.throttle)(10),s.autobind],f.prototype,"__throttleUpdatePosition",null),(0,o.__decorate)([s.autobind],f.prototype,"close",null),(0,o.__decorate)([s.autobind],f.prototype,"__closeOnOutsideClick",null)},34396:function(e,t,i){"use strict";i.d(t,{ProgressBar:function(){return c}});var n=i(25045),o=i(23211),r=i(28077),s=i(23599),a=i(80991),l=i(96007),u=i(29434);class c extends l.UIElement{className(){return"ProgressBar"}render(){return"<div><div></div></div>"}show(){return(this.j.workplace||this.j.container).appendChild(this.container),this}hide(){return o.Dom.safeRemove(this.container),this}progress(e){return this.container.style.width=e.toFixed(2)+"%",this}showFileUploadAnimation(e,t){this.__cleanUpAnimation();let i=(0,r.getContainer)(this.j,c),n=(0,s.position)(this.j.container,this.j),o=this.j.c.div(this.getFullElName("file-animation")),l=u.Icon.get("file","");l&&(o.innerHTML=l);let d=null!=e?e:{x:n.width/2,y:0},h=null!=t?t:{x:d.x+60,y:d.y-80};(0,a.css)(o,{left:n.left+d.x,top:n.top+d.y}),i.appendChild(o),this.__animationElement=o,o.offsetWidth,(0,a.css)(o,{left:n.left+h.x,top:n.top+h.y,opacity:0,transform:"scale(0.4)"});let p=()=>{o.removeEventListener("transitionend",p),this.__cleanUpAnimation()};o.addEventListener("transitionend",p)}__cleanUpAnimation(){this.__animationElement&&(o.Dom.safeRemove(this.__animationElement),this.__animationElement=null)}destruct(){return this.__cleanUpAnimation(),this.hide(),super.destruct()}constructor(...e){super(...e),(0,n._)(this,"__animationElement",null)}}},2222:function(e,t,i){"use strict";i.d(t,{ViewWithToolbar:function(){return g}});var n=i(25045),o=i(31635),r=i(69364),s=i(49574),a=i(68616),l=i(23211),u=i(45664),c=i(85932),d=i(28723),h=i(4099),p=i(2496),f=i(35099),m=i(4274);class g extends f.View{get toolbarContainer(){return!this.o.fullsize&&((0,c.isString)(this.o.toolbar)||l.Dom.isHTMLElement(this.o.toolbar))?(0,d.resolveElement)(this.o.toolbar,this.o.shadowRoot||this.od):(this.o.toolbar&&l.Dom.appendChildFirst(this.container,this.__defaultToolbarContainer),this.__defaultToolbarContainer)}setPanel(e){this.o.toolbar=e,this.buildToolbar()}buildToolbar(){var e;if(!this.o.toolbar)return;let t=this.o.buttons?(0,u.splitArray)(this.o.buttons):[];null==(e=this.toolbar)||e.setRemoveButtons(this.o.removeButtons).build(t.concat(this.o.extraButtons||[])).appendTo(this.toolbarContainer)}getRegisteredButtonGroups(){return this.groupToButtons}registerButton(e){var t;this.registeredButtons.add(e);let i=null!=(t=e.group)?t:"other";return this.groupToButtons[i]||(this.groupToButtons[i]=[]),null!=e.position?this.groupToButtons[i][e.position]=e.name:this.groupToButtons[i].push(e.name),this}unregisterButton(e){var t;this.registeredButtons.delete(e);let i=null!=(t=e.group)?t:"other",n=this.groupToButtons[i];if(n){let t=n.indexOf(e.name);-1!==t&&n.splice(t,1),0===n.length&&delete this.groupToButtons[i]}return this}beforeToolbarBuild(e){if(Object.keys(this.groupToButtons).length)return e.map(e=>(0,p.isButtonGroup)(e)&&e.group&&this.groupToButtons[e.group]?{group:e.group,buttons:[...e.buttons,...this.groupToButtons[e.group]]}:e)}destruct(){this.isDestructed||(this.setStatus(r.STATUSES.beforeDestruct),this.e.off("beforeToolbarBuild",this.beforeToolbarBuild),this.__tooltip.destruct(),this.toolbar.destruct(),this.toolbar=void 0,super.destruct())}constructor(e,t=!1){super(e,t),(0,n._)(this,"toolbar",(0,m.makeCollection)(this)),(0,n._)(this,"__defaultToolbarContainer",this.c.div("jodit-toolbar__box")),(0,n._)(this,"registeredButtons",new Set),(0,n._)(this,"groupToButtons",{}),(0,n._)(this,"isJodit",!1),(0,n._)(this,"__tooltip",new h.UITooltip(this)),this.isJodit=t,this.e.on("beforeToolbarBuild",this.beforeToolbarBuild)}}(0,o.__decorate)([(0,a.watch)(":rebuildToolbar")],g.prototype,"buildToolbar",null),(0,o.__decorate)([s.autobind],g.prototype,"beforeToolbarBuild",null)},35099:function(e,t,i){"use strict";i.d(t,{View:function(){return C}});var n=i(25045),o=i(31635),r=i(16964),s=i(80251),a=i(69364),l=i(81937),u=i(76517),c=i(51676),d=i(24968),h=i(29200),p=i(27795),f=i(1496),m=i(28077),g=i(65946),v=i(8006),_=i(24475),b=i(23183),y=i(81987),S=i(34396),w=i(10081);class C extends s.Component{get basePath(){return this.o.basePath?this.o.basePath:l.BASE_PATH}get minified(){return void 0!==this.o.minified?this.o.minified:l.BASE_PATH_IS_MIN}get defaultTimeout(){return(0,g.isVoid)(this.o.defaultTimeout)?100:this.o.defaultTimeout}get buffer(){return _.Storage.makeStorage()}get message(){return this.getMessageModule(this.container)}getMessageModule(e){return new w.UIMessages(this,e)}get storage(){return _.Storage.makeStorage(!0,this.id)}get asyncStorage(){return v.AsyncStorage.makeStorage(!0,this.id)}get c(){return this.create}get container(){return this.__container}set container(e){this.__container=e}get e(){return this.events}get progressbar(){return new S.ProgressBar(this)}get options(){return this.__options}set options(e){this.__options=e}get o(){return this.options}i18n(e,...t){return(0,g.i18n)(e,t,this.options)}toggleFullSize(e){void 0===e&&(e=!this.__isFullSize),e!==this.__isFullSize&&(this.__isFullSize=e,this.e.fire("toggleFullSize",e))}get isLocked(){return""!==this.__whoLocked}lock(e="any"){return!this.isLocked&&(this.__whoLocked=e,!0)}unlock(){return!!this.isLocked&&(this.__whoLocked="",!0)}get isFullSize(){return this.__isFullSize}getVersion(){return C.version}static getVersion(){return C.version}initOptions(e){this.options=(0,g.ConfigProto)(e||{},(0,g.ConfigProto)(this.options||{},C.defaultOptions))}initOwners(){var e;this.ownerWindow=null!=(e=this.o.ownerWindow)?e:window}attachEvents(e){if(!e)return;let t=null==e?void 0:e.events;t&&Object.keys(t).forEach(e=>this.e.on(e,t[e]))}getInstance(e,t){let i=(0,g.isFunction)(e)?e.prototype.className():e,n=this.e.fire((0,g.camelCase)("getInstance_"+i),t);if(n)return n;let o=(0,g.isFunction)(e)?e:m.modules[i],s=this.__modulesInstances;if(!(0,g.isFunction)(o))throw(0,g.error)("Need real module name");if(!s.has(i)){let e=o.prototype instanceof r.ViewComponent?new o(this,t):new o(t);this.components.add(e),s.set(i,e)}return s.get(i)}addDisclaimer(e){this.container.appendChild(e)}beforeDestruct(){this.e.fire(a.STATUSES.beforeDestruct,this),this.components.forEach(e=>{(0,g.isDestructable)(e)&&!e.isInDestruct&&e.destruct()}),this.components.clear()}destruct(){var e,t,i,n;this.isDestructed||(null==(e=(0,c.cached)(this,"progressbar"))||e.destruct(),null==(t=(0,c.cached)(this,"message"))||t.destruct(),null==(i=(0,c.cached)(this,"asyncStorage"))||i.close(),this.events&&(this.events.destruct(),this.events=void 0),null==(n=(0,c.cached)(this,"buffer"))||n.clear(),p.Dom.safeRemove(this.container),super.destruct())}constructor(e,t=!1){var i;super(),(0,n._)(this,"isJodit",void 0),(0,n._)(this,"isView",void 0),(0,n._)(this,"parent",void 0),(0,n._)(this,"mods",void 0),(0,n._)(this,"id",void 0),(0,n._)(this,"components",void 0),(0,n._)(this,"events",void 0),(0,n._)(this,"create",void 0),(0,n._)(this,"__container",void 0),(0,n._)(this,"OPTIONS",void 0),(0,n._)(this,"__options",void 0),(0,n._)(this,"__isFullSize",void 0),(0,n._)(this,"__whoLocked",void 0),(0,n._)(this,"isLockedNotBy",void 0),(0,n._)(this,"__modulesInstances",void 0),this.isJodit=t,this.isView=!0,this.parent=null,this.mods={},this.components=new Set,this.OPTIONS=C.defaultOptions,this.__isFullSize=!1,this.__whoLocked="",this.isLockedNotBy=e=>this.isLocked&&this.__whoLocked!==e,this.__modulesInstances=new Map,this.id=new Date().getTime().toString(),this.initOptions(e),this.initOwners(),this.events=null!=(i=null==e?void 0:e.eventEmmiter)?i:new f.EventEmitter(this.od),this.create=new u.Create(this.od),this.__container=this.c.div(`jodit ${this.componentName}`)}}(0,n._)(C,"ES",l.ES),(0,n._)(C,"version",l.APP_VERSION),(0,n._)(C,"esNext",l.IS_ES_NEXT),(0,n._)(C,"esModern",l.IS_ES_MODERN),(0,n._)(C,"defaultOptions",void 0),(0,o.__decorate)([c.cache],C.prototype,"buffer",null),(0,o.__decorate)([c.cache],C.prototype,"message",null),(0,o.__decorate)([c.cache],C.prototype,"storage",null),(0,o.__decorate)([c.cache],C.prototype,"asyncStorage",null),(0,o.__decorate)([c.cache],C.prototype,"c",null),(0,o.__decorate)([c.cache],C.prototype,"e",null),(0,o.__decorate)([c.cache],C.prototype,"progressbar",null),(0,o.__decorate)([(0,h.hook)(a.STATUSES.beforeDestruct)],C.prototype,"beforeDestruct",null),(C=(0,o.__decorate)([(0,d.derive)(y.Mods,b.Elms)],C)).defaultOptions={extraButtons:[],cache:!0,textIcons:!1,namespace:"",removeButtons:[],zIndex:100002,defaultTimeout:100,fullsize:!1,showTooltip:!0,useNativeTooltip:!1,buttons:[],globalFullSize:!0,language:"auto"}},73302:function(e,t,i){"use strict";i.d(t,{Jodit:function(){return Jodit}});var n=i(25045),o=i(31635),r=i(81937),s=i(84839),a=i(28077),l=i(65946),u=i(73714),c=i(80512),d=i(5266),h=i(60936);let p="data-jodit-default-style-display",f="data-jodit-default-classes",m={contenteditable:!1};class Jodit extends h.ViewWithToolbar{className(){return"Jodit"}waitForReady(){return this.isReady?Promise.resolve(this):this.async.promise(e=>{this.hookStatus("ready",()=>e(this))})}static get ready(){return new Promise(e=>{a.eventEmitter.on("joditready",e)})}get text(){if(this.editor)return this.editor.innerText||"";let e=this.createInside.div();return e.innerHTML=this.getElementValue(),e.innerText||""}get defaultTimeout(){return(0,l.isNumber)(this.o.defaultTimeout)?this.o.defaultTimeout:d.Config.defaultOptions.defaultTimeout}static atom(e){return(0,l.markAsAtomic)(e)}static make(e,t){return new this(e,t)}static isJoditAssigned(e){return e&&(0,l.isJoditObject)(e.component)&&!e.component.isInDestruct}static get defaultOptions(){return d.Config.defaultOptions}get createInside(){return new h.Create(()=>this.ed,this.o.createAttributes)}__setPlaceField(e,t){this.currentPlace||(this.currentPlace={},this.places=[this.currentPlace]),this.currentPlace[e]=t}get element(){return this.currentPlace.element}get editor(){return this.currentPlace.editor}set editor(e){this.__setPlaceField("editor",e)}get container(){return this.currentPlace.container}set container(e){this.__setPlaceField("container",e)}get workplace(){return this.currentPlace.workplace}get message(){return this.getMessageModule(this.workplace)}get statusbar(){return this.currentPlace.statusbar}get iframe(){return this.currentPlace.iframe}set iframe(e){this.__setPlaceField("iframe",e)}get history(){return this.currentPlace.history}get editorWindow(){return this.currentPlace.editorWindow}set editorWindow(e){this.__setPlaceField("editorWindow",e)}get ew(){return this.editorWindow}get editorDocument(){return this.currentPlace.editorWindow.document}get ed(){return this.editorDocument}get options(){return this.currentPlace.options}set options(e){this.__options=e,this.__setPlaceField("options",e)}get s(){return this.selection}get uploader(){return this.getInstance("Uploader",this.o.uploader)}get filebrowser(){let e=this,t=(0,l.ConfigProto)({defaultTimeout:e.defaultTimeout,uploader:e.o.uploader,language:e.o.language,license:e.o.license,theme:e.o.theme,shadowRoot:e.o.shadowRoot,defaultCallback(t){t.files&&t.files.length&&t.files.forEach((i,n)=>{let o=t.baseurl+i;t.isImages&&t.isImages[n]?e.s.insertImage(o,null,e.o.imageDefaultWidth):e.s.insertNode(e.createInside.fromHTML(`<a href='${o}' title='${o}'>${o}</a>`))})}},this.o.filebrowser);return e.getInstance("FileBrowser",t)}get mode(){return this.__mode}set mode(e){this.setMode(e)}getNativeEditorValue(){let e=this.e.fire("beforeGetNativeEditorValue");return(0,l.isString)(e)?e:this.editor?this.editor.innerHTML:this.getElementValue()}setNativeEditorValue(e){let t={value:e};!this.e.fire("beforeSetNativeEditorValue",t)&&this.editor&&(this.editor.innerHTML=t.value)}get value(){return this.getEditorValue()}set value(e){this.setEditorValue(e),this.history.__processChanges()}synchronizeValues(){this.__imdSynchronizeValues()}__imdSynchronizeValues(){this.setEditorValue()}getEditorValue(e=!0,t){let i;if(void 0!==(i=this.e.fire("beforeGetValueFromEditor",t)))return i;i=this.getNativeEditorValue().replace(r.INVISIBLE_SPACE_REG_EXP(),""),e&&(i=i.replace(/<span[^>]+id="jodit-selection_marker_[^>]+><\/span>/g,"")),"<br>"===i&&(i="");let n={value:i};return this.e.fire("afterGetValueFromEditor",n,t),n.value}setEditorValue(e){let t=this.e.fire("beforeSetValueToEditor",e);if(!1===t)return;if((0,l.isString)(t)&&(e=t),!this.editor){void 0!==e&&this.__setElementValue(e);return}if(!(0,l.isString)(e)&&!(0,l.isVoid)(e))throw(0,l.error)("value must be string");(0,l.isVoid)(e)||this.getNativeEditorValue()===e||this.setNativeEditorValue(e),this.e.fire("postProcessSetEditorValue");let i=this.getElementValue(),n=this.getEditorValue();if(!this.__isSilentChange&&i!==n&&this.__callChangeCount<r.SAFE_COUNT_CHANGE_CALL){this.__setElementValue(n),this.__callChangeCount+=1,r.IS_PROD||this.__callChangeCount;try{this.history.__upTick(),this.e.fire("change",n,i),this.e.fire(this.history,"change",n,i)}finally{this.__callChangeCount=0}}}updateElementValue(){this.__setElementValue(this.getEditorValue())}getElementValue(){return void 0!==this.element.value?this.element.value:this.element.innerHTML}__setElementValue(e){if(!(0,l.isString)(e))throw(0,l.error)("value must be string");if(this.element!==this.container&&e!==this.getElementValue()){let t={value:e},i=this.e.fire("beforeSetElementValue",t);(0,l.callPromise)(i,()=>{void 0!==this.element.value?this.element.value=t.value:this.element.innerHTML=t.value,this.e.fire("afterSetElementValue",t)})}}registerCommand(e,t,i){let n=e.toLowerCase(),o=this.commands.get(n);if(void 0===o&&(o=[],this.commands.set(n,o)),o.push(t),!(0,l.isFunction)(t)){let o=this.o.commandToHotkeys[n]||this.o.commandToHotkeys[e]||t.hotkeys;o&&this.registerHotkeyToCommand(o,n,null==i?void 0:i.stopPropagation)}return this}registerHotkeyToCommand(e,t,i=!0){let n=(0,l.asArray)(e).map(l.normalizeKeyAliases).map(e=>e+".hotkey").join(" ");this.e.off(n).on(n,(e,n)=>(n&&(n.shouldStop=null==i||i),this.execCommand(t)))}execCommand(e,t,i,...n){let o;if(this.s.isFocused()||this.s.focus(),!this.o.readonly||this.o.allowCommandsInReadOnly.includes(e)){if(e=e.toLowerCase(),!1!==(o=this.e.fire(`beforeCommand${(0,l.ucfirst)(e)}`,t,i,...n))&&(o=this.e.fire("beforeCommand",e,t,i,...n)),!1!==o&&(o=this.__execCustomCommands(e,t,i,...n)),!1!==o){this.s.focus();try{o=this.nativeExecCommand(e,t,i)}catch(e){if(!r.IS_PROD)throw e}}return this.e.fire("afterCommand",e,t,i),this.__imdSynchronizeValues(),o}}nativeExecCommand(e,t,i){this.__isSilentChange=!0;try{return this.ed.execCommand(e,t,i)}finally{this.__isSilentChange=!1}}__execCustomCommands(e,t,i,...n){e=e.toLowerCase();let o=this.commands.get(e);if(void 0!==o){let r;return o.forEach(o=>{let s=((0,l.isFunction)(o)?o:o.exec).call(this,e,t,i,...n);void 0!==s&&(r=s)}),r}}lock(e="any"){return!!super.lock(e)&&(this.__selectionLocked=this.s.save(),this.s.clear(),this.container.classList.add("jodit_lock"),this.e.fire("lock",!0),!0)}unlock(){return!!super.unlock()&&(this.container.classList.remove("jodit_lock"),this.__selectionLocked&&this.s.restore(),this.e.fire("lock",!1),!0)}getMode(){return this.mode}isEditorMode(){return this.getRealMode()===r.MODE_WYSIWYG}getRealMode(){if(this.getMode()!==r.MODE_SPLIT)return this.getMode();let e=this.od.activeElement;return e&&(e===this.iframe||h.Dom.isOrContains(this.editor,e)||h.Dom.isOrContains(this.toolbar.container,e))?r.MODE_WYSIWYG:r.MODE_SOURCE}setMode(e){let t=this.getMode(),i={mode:parseInt(e.toString(),10)},n=["jodit-wysiwyg_mode","jodit-source__mode","jodit_split_mode"];!1!==this.e.fire("beforeSetMode",i)&&(this.__mode=[r.MODE_SOURCE,r.MODE_WYSIWYG,r.MODE_SPLIT].includes(i.mode)?i.mode:r.MODE_WYSIWYG,this.o.saveModeInStorage&&this.storage.set("jodit_default_mode",this.mode),n.forEach(e=>{this.container.classList.remove(e)}),this.container.classList.add(n[this.mode-1]),t!==this.getMode()&&this.e.fire("afterSetMode"))}toggleMode(){let e=this.getMode();[r.MODE_SOURCE,r.MODE_WYSIWYG,this.o.useSplitMode?r.MODE_SPLIT:9].includes(e+1)?e+=1:e=r.MODE_WYSIWYG,this.setMode(e)}setDisabled(e){this.o.disabled=e;let t=this.__wasReadOnly;this.setReadOnly(e||t),this.__wasReadOnly=t,this.editor&&(this.editor.setAttribute("aria-disabled",e.toString()),this.container.classList.toggle("jodit_disabled",e),this.e.fire("disabled",e))}getDisabled(){return this.o.disabled}setReadOnly(e){this.__wasReadOnly!==e&&(this.__wasReadOnly=e,this.o.readonly=e,e?this.editor&&this.editor.removeAttribute("contenteditable"):this.editor&&this.editor.setAttribute("contenteditable","true"),this.e&&this.e.fire("readonly",e))}getReadOnly(){return this.o.readonly}focus(){this.getMode()!==r.MODE_SOURCE&&this.s.focus()}get isFocused(){return this.s.isFocused()}beforeInitHook(){}afterInitHook(){}initOptions(e){this.options=(0,l.ConfigProto)(e||{},d.Config.defaultOptions)}initOwners(){this.editorWindow=this.o.ownerWindow,this.ownerWindow=this.o.ownerWindow}addPlace(e,t){let i=(0,l.resolveElement)(e,this.o.shadowRoot||this.od);this.attachEvents(t),i.attributes&&(0,l.toArray)(i.attributes).forEach(e=>{let i=e.name,n=e.value;void 0===d.Config.defaultOptions[i]||t&&void 0!==t[i]||(-1!==["readonly","disabled"].indexOf(i)&&(n=""===n||"true"===n),/^[0-9]+(\.)?([0-9]+)?$/.test(n.toString())&&(n=Number(n)),this.options[i]=n)});let n=this.c.div("jodit-container");n.classList.add("jodit"),n.classList.add("jodit-container"),n.classList.add(`jodit_theme_${this.o.theme||"default"}`),g(this.o.className,n),this.o.containerStyle&&(0,l.css)(n,this.o.containerStyle);let{styleValues:o}=this.o;Object.keys(o).forEach(e=>{let t=(0,l.kebabCase)(e);n.style.setProperty(`--jd-${t}`,o[e])}),n.setAttribute("contenteditable","false");let r=null;this.o.inline&&(-1===["TEXTAREA","INPUT"].indexOf(i.nodeName)&&(n=i,i.setAttribute(f,i.className.toString()),r=n.innerHTML,n.innerHTML=""),n.classList.add("jodit_inline"),n.classList.add("jodit-container")),i!==n&&(i.style.display&&i.setAttribute(p,i.style.display),i.style.display="none");let s="workplace-slot",a=this.c.div(this.getFullElName(s,"top"),m);n.appendChild(a);let u=this.c.div(this.getFullElName(s,"center"),m),c=this.c.div("jodit-workplace",m),v=this.c.div(this.getFullElName(s,"left"),m),_=this.c.div(this.getFullElName(s,"right"),m);u.appendChild(v),u.appendChild(c),u.appendChild(_),n.appendChild(u);let b=this.c.div(this.getFullElName(s,"bottom"),m);n.appendChild(b),i.parentNode&&i!==n&&i.parentNode.insertBefore(n,i),Object.defineProperty(i,"component",{enumerable:!1,configurable:!0,value:this});let y=this.c.div("jodit-wysiwyg",{contenteditable:!0,"aria-disabled":!1,tabindex:this.o.tabIndex});c.appendChild(y);let S={editor:y,element:i,container:n,workplace:c,slots:{top:a,bottom:b,center:u,left:v,right:_},statusbar:new h.StatusBar(this,n),options:this.isReady?(0,l.ConfigProto)(t||{},d.Config.defaultOptions):this.options,history:new h.History(this),editorWindow:this.ow};this.__elementToPlace.set(y,S),this.setCurrentPlace(S),this.places.push(S),this.setNativeEditorValue(this.getElementValue());let w=this.__initEditor(r),C=this.options,k=()=>{C.enableDragAndDropFileToEditor&&C.uploader&&(C.uploader.url||C.uploader.insertImageAsBase64URI)&&this.uploader.bind(this.editor),this.__elementToPlace.get(this.editor)||this.__elementToPlace.set(this.editor,S),this.e.fire("afterAddPlace",S)};return(0,l.callPromise)(w,k)}addDisclaimer(e){this.workplace.appendChild(e)}setCurrentPlace(e){this.currentPlace!==e&&(this.isEditorMode()||this.setMode(r.MODE_WYSIWYG),this.currentPlace=e,this.buildToolbar(),this.isReady&&this.e.fire("changePlace",e))}__initEditor(e){let t=this.__createEditor();return(0,l.callPromise)(t,()=>{if(this.isInDestruct)return;if(this.element!==this.container){let e=this.getElementValue();e!==this.getEditorValue()&&this.setEditorValue(e)}else null!=e&&this.setEditorValue(e);let t=this.o.defaultMode;if(this.o.saveModeInStorage){let e=this.storage.get("jodit_default_mode");"string"==typeof e&&(t=parseInt(e,10))}this.setMode(t),this.o.readonly&&(this.__wasReadOnly=!1,this.setReadOnly(!0)),this.o.disabled&&this.setDisabled(!0);try{this.ed.execCommand("defaultParagraphSeparator",!1,this.o.enter.toLowerCase())}catch(e){}})}__createEditor(){let e=this.editor,t=this.e.fire("createEditor",this);return(0,l.callPromise)(t,()=>{!this.isInDestruct&&((!1===t||(0,l.isPromise)(t))&&h.Dom.safeRemove(e),g(this.o.editorClassName,this.editor),this.o.style&&(0,l.css)(this.editor,this.o.style),this.e.on("synchro",()=>{this.setEditorValue()}).on("focus",()=>{this.editorIsActive=!0}).on("blur",()=>this.editorIsActive=!1),this.__prepareWYSIWYGEditor(),this.o.triggerChangeEvent&&this.e.on("change",this.async.debounce(()=>{this.e&&this.e.fire(this.element,"change")},this.defaultTimeout)))})}__prepareWYSIWYGEditor(){let{editor:e}=this;if(this.o.direction){let e="rtl"===this.o.direction.toLowerCase()?"rtl":"ltr";this.editor.style.direction=e,this.editor.setAttribute("dir",e),this.container.style.direction=e,this.container.setAttribute("dir",e),this.toolbar.setDirection(e)}this.e.on(e,"mousedown touchstart focus",()=>{let t=this.__elementToPlace.get(e);t&&this.setCurrentPlace(t)}).on(e,"compositionend",this.synchronizeValues).on(e,"selectionchange selectionstart keydown keyup input keypress dblclick mousedown mouseup click copy cut dragstart drop dragover paste resize touchstart touchend focus blur",e=>{if(!this.o.readonly&&!this.__isSilentChange&&(!(e instanceof this.ew.KeyboardEvent)||!e.isComposing)&&this.e&&this.e.fire){if(!1===this.e.fire(e.type,e))return!1;this.synchronizeValues()}})}fetch(e,t){let i=new u.Ajax({url:e,...t},this.o.defaultAjaxOptions),n=()=>{this.e.off("beforeDestruct",n),this.progressbar.progress(100).hide(),i.destruct()};this.e.one("beforeDestruct",n),this.progressbar.show().progress(30);let o=i.send();return o.finally(n).catch(()=>null),o}destruct(){var e,t;if(this.isInDestruct)return;this.setStatus(h.STATUSES.beforeDestruct),this.__elementToPlace.clear(),null==(e=(0,s.cached)(this,"storage"))||e.clear(),null==(t=(0,s.cached)(this,"buffer"))||t.clear(),this.commands.clear(),this.__selectionLocked=null,this.e.off(this.ow,"resize"),this.e.off(this.ow),this.e.off(this.od),this.e.off(this.od.body);let i=this.editor?this.getEditorValue():"";this.places.forEach(({container:e,workplace:t,statusbar:n,element:o,iframe:r,editor:s,history:a})=>{if(o){if(o!==e)if(o.hasAttribute(p)){let e=(0,l.attr)(o,p);e&&(o.style.display=e,o.removeAttribute(p))}else o.style.display="";else o.hasAttribute(f)&&(o.className=(0,l.attr)(o,f)||"",o.removeAttribute(f));o.hasAttribute("style")&&!(0,l.attr)(o,"style")&&o.removeAttribute("style"),n.destruct(),this.e.off(e),this.e.off(o),this.e.off(s),h.Dom.safeRemove(t),h.Dom.safeRemove(s),e!==o&&h.Dom.safeRemove(e),Object.defineProperty(o,"component",{enumerable:!1,configurable:!0,value:null}),h.Dom.safeRemove(r),e===o&&(o.innerHTML=i),a.destruct()}}),this.places.length=0,this.currentPlace={},delete a.instances[this.id],super.destruct()}constructor(e,t){super(t,!0),(0,n._)(this,"isJodit",!0),(0,n._)(this,"commands",new Map),(0,n._)(this,"__selectionLocked",null),(0,n._)(this,"__wasReadOnly",!1),(0,n._)(this,"editorIsActive",!1),(0,n._)(this,"selection",void 0),(0,n._)(this,"__mode",r.MODE_WYSIWYG),(0,n._)(this,"__callChangeCount",0),(0,n._)(this,"__isSilentChange",!1),(0,n._)(this,"currentPlace",{options:this.__options,container:this.__container}),(0,n._)(this,"places",[]),(0,n._)(this,"__elementToPlace",new Map);try{const t=(0,l.resolveElement)(e,this.options.shadowRoot||this.od);if(Jodit.isJoditAssigned(t))return t.component}catch(e){if(!r.IS_PROD)throw e;throw this.destruct(),e}this.setStatus(h.STATUSES.beforeInit),this.id=(0,l.attr)((0,l.resolveElement)(e,this.o.shadowRoot||this.od),"id")||new Date().getTime().toString(),a.instances[this.id]=this,this.attachEvents(t),this.e.on(this.ow,"resize",()=>{this.e&&this.e.fire("resize")}),this.e.on("prepareWYSIWYGEditor",this.__prepareWYSIWYGEditor),this.selection=new h.Selection(this);const i=this.beforeInitHook();(0,l.callPromise)(i,()=>{if(this.isInDestruct)return;this.e.fire("beforeInit",this),a.pluginSystem.__init(this),this.e.fire("afterPluginSystemInit",this),this.e.on("changePlace",()=>{this.setReadOnly(this.o.readonly),this.setDisabled(this.o.disabled)}),this.places.length=0;let i=this.addPlace(e,t);a.instances[this.id]=this;let n=()=>{this.isInDestruct||(this.e&&this.e.fire("afterInit",this),(0,l.callPromise)(this.afterInitHook()),this.setStatus(h.STATUSES.ready),this.e.fire("afterConstructor",this))};(0,l.callPromise)(i,n)})}}function g(e,t){e&&e.split(/\s+/).forEach(e=>t.classList.add(e))}(0,n._)(Jodit,"fatMode",r.FAT_MODE),(0,n._)(Jodit,"plugins",a.pluginSystem),(0,n._)(Jodit,"modules",a.modules),(0,n._)(Jodit,"ns",a.modules),(0,n._)(Jodit,"decorators",{}),(0,n._)(Jodit,"constants",r),(0,n._)(Jodit,"instances",a.instances),(0,n._)(Jodit,"lang",r.lang),(0,n._)(Jodit,"core",{Plugin:h.Plugin}),(0,o.__decorate)([s.cache],Jodit.prototype,"createInside",null),(0,o.__decorate)([s.cache],Jodit.prototype,"message",null),(0,o.__decorate)([s.cache],Jodit.prototype,"s",null),(0,o.__decorate)([s.cache],Jodit.prototype,"uploader",null),(0,o.__decorate)([s.cache],Jodit.prototype,"filebrowser",null),(0,o.__decorate)([(0,s.throttle)()],Jodit.prototype,"synchronizeValues",null),(0,o.__decorate)([(0,s.watch)(":internalChange")],Jodit.prototype,"updateElementValue",null),(0,o.__decorate)([s.autobind],Jodit.prototype,"__prepareWYSIWYGEditor",null),Jodit=(0,o.__decorate)([(0,s.derive)(c.Dlgs)],Jodit)},89317:function(e,t,i){"use strict";var n=i(17312),o=i(57741),r=i(56014),s=i(95461),a=i(63837),l=i(39386),u=i(62327),c=i(25090),d=i(53113),h=i(81321),p=i(4679),f=i(31927),m=i(21195),g=i(53414),v=i(11012),_=i(87061),b=i(3268),y=i(85325),S=i(97834),w=i(86433),C=i(28359),k=i(68368),E=i(57456),I=i(25182),T=i(44906);let x={};x={ar:o,cs_cz:r,de:s,en:a,es:l,fi:u,fr:c,he:d,hu:h,id:p,it:f,ja:m,ko:v,mn:_,nl:b,no:y,pl:S,pt_br:w,ru:C,tr:k,ua:E,zh_cn:I,zh_tw:T};let D=e=>e?e.default||e:{},j={};(0,n.isArray)(D(g))&&D(g).forEach((e,t)=>{j[t]=e}),Object.keys(x).forEach(e=>{let t=D(x[e]);(0,n.isArray)(t)?(x[e]={},t.forEach((t,i)=>{x[e][j[i]]=t})):x[e]=t}),t.default=x},67399:function(e,t,i){"use strict";i.d(t,{ContextMenu:function(){return l}});var n=i(31635),o=i(91672),r=i(17312),s=i(53681),a=i(51116);class l extends a.Popup{className(){return"ContextMenu"}show(e,t,i){let n=this;n.clear(),(0,r.isArray)(i)&&(i.forEach(e=>{if(!e)return;let t=(0,s.Button)(this.jodit,e.icon||"empty",e.title);this.jodit&&t.setParentView(this.jodit),t.setMod("context","menu"),t.onAction(t=>{var i;return null==(i=e.exec)||i.call(n,t),n.clear(),n.close(),!1}),this.append(t)}),this.open(()=>({left:e,top:t,width:0,height:0}),!0))}}l=(0,n.__decorate)([o.component],l)},91535:function(e,t,i){"use strict";i.d(t,{Alert:function(){return l}});var n=i(23211),o=i(78982),r=i(91565),s=i(53681),a=i(76841);function l(e,t,i,u="jodit-dialog_alert"){(0,r.isFunction)(t)&&(i=t,t=void 0);let c=this instanceof a.Dialog?this:new a.Dialog({closeOnClickOverlay:!0}),d=c.c.div(u),h=(0,s.Button)(c,"ok","Ok");return(0,o.asArray)(e).forEach(e=>{d.appendChild(n.Dom.isNode(e)?e:c.c.fromHTML(e))}),h.onAction(()=>{i&&(0,r.isFunction)(i)&&!1===i(c)||c.close()}),c.setFooter([h]),c.open(d,t||"&nbsp;",!0,!0),h.focus(),c}},88329:function(e,t,i){"use strict";i.d(t,{Confirm:function(){return s}});var n=i(91565),o=i(53681),r=i(76841);function s(e,t,i){let s=this instanceof r.Dialog?this:new r.Dialog({closeOnClickOverlay:!0}),a=s.c.fromHTML('<form class="jodit-dialog_prompt"></form>'),l=s.c.element("label");(0,n.isFunction)(t)&&(i=t,t=void 0),l.appendChild(s.c.fromHTML(e)),a.appendChild(l);let u=e=>()=>{i&&!1===i(e)||s.close()},c=(0,o.Button)(s,"cancel","Cancel"),d=(0,o.Button)(s,"ok","Yes");return c.onAction(u(!1)),d.onAction(u(!0)),s.e.on(a,"submit",()=>(u(!0)(),!1)),s.setFooter([d,c]),s.open(a,t||"&nbsp;",!0,!0),d.focus(),s}},76841:function(e,t,i){"use strict";i.d(t,{Dialog:function(){return _}});var n=i(25045),o=i(31635),r=i(16964),s=i(81937),a=i(84839),l=i(23211),u=i(28077),c=i(45664),d=i(28686),h=i(93640),p=i(28712),f=i(4099),m=i(35099),g=i(2222),v=i(5266);v.Config.prototype.dialog={namespace:"",extraButtons:[],resizable:!0,draggable:!0,buttons:["dialog.close"],removeButtons:[],toolbarButtonSize:"middle",zIndex:"inherit"},v.Config.prototype.controls.dialog={close:{icon:"cancel",exec:e=>{e.close()}}};class _ extends g.ViewWithToolbar{className(){return"Dialog"}get destination(){let{popupRoot:e,shadowRoot:t}=this.o;return e||t||this.od.body}setElements(e,t){let i=[];(0,c.asArray)(t).forEach(t=>{let n;if((0,d.isArray)(t)){let n=this.c.div(this.getFullElName("column"));return i.push(n),e.appendChild(n),this.setElements(n,t)}n=(0,d.isString)(t)?this.c.fromHTML(t):(0,d.hasContainer)(t)?t.container:t,i.push(n),n.parentNode!==e&&e.appendChild(n)}),(0,c.toArray)(e.childNodes).forEach(t=>{-1===i.indexOf(t)&&e.removeChild(t)})}__onMouseUp(){(this.draggable||this.resizable)&&(this.__removeGlobalResizeListeners(),this.draggable=!1,this.resizable=!1,this.unlockSelect(),this.e&&(this.__removeGlobalResizeListeners(),this.e.fire(this,"endResize endMove")))}__onHeaderMouseDown(e){let t=e.target;!(!this.o.draggable||t&&t.nodeName.match(/^(INPUT|SELECT)$/))&&(this.draggable=!0,this.startX=e.clientX,this.startY=e.clientY,this.startPoint.x=(0,h.css)(this.dialog,"left"),this.startPoint.y=(0,h.css)(this.dialog,"top"),this.setMaxZIndex(),e.cancelable&&e.preventDefault(),this.lockSelect(),this.__addGlobalResizeListeners(),this.e&&(this.e.fire(this,"startMove"),this.e.fire("closeAllPopups")))}__onMouseMove(e){this.draggable&&this.o.draggable&&(this.setPosition(this.startPoint.x+e.clientX-this.startX,this.startPoint.y+e.clientY-this.startY),this.e&&this.e.fire(this,"move",e.clientX-this.startX,e.clientY-this.startY),e.stopImmediatePropagation()),this.resizable&&this.o.resizable&&(this.setSize(this.startPoint.w+e.clientX-this.startX,this.startPoint.h+e.clientY-this.startY),this.e&&this.e.fire(this,"resizeDialog",e.clientX-this.startX,e.clientY-this.startY))}__onEsc(e){if(this.o.closeOnEsc&&this.isOpened&&e.key===s.KEY_ESC&&!0!==this.getMod("static")){let t=this.getMaxZIndexDialog();t?t.close():this.close(),e.stopImmediatePropagation()}}__onResizerMouseDown(e){this.resizable=!0,this.startX=e.clientX,this.startY=e.clientY,this.startPoint.w=this.dialog.offsetWidth,this.startPoint.h=this.dialog.offsetHeight,this.lockSelect(),this.__addGlobalResizeListeners(),this.e&&this.e.fire(this,"startResize")}__addGlobalResizeListeners(){this.e.on(this.ow,"pointermove touchmove",this.__onMouseMove).on(this.ow,"pointerup touchend",this.__onMouseUp)}__removeGlobalResizeListeners(){this.e.off(this.ow,"mousemove pointermove",this.__onMouseMove).off(this.ow,"mouseup pointerup",this.__onMouseUp)}setSize(e,t){return null==e&&(e=this.dialog.offsetWidth),null==t&&(t=this.dialog.offsetHeight),(0,h.css)(this.dialog,{width:e,height:t}),this}calcAutoSize(){return this.setSize("auto","auto"),this.setSize(),this}setPosition(e,t){let i=this.ow.innerWidth,n=this.ow.innerHeight,o=i/2-this.dialog.offsetWidth/2,r=n/2-this.dialog.offsetHeight/2;return o<0&&(o=0),r<0&&(r=0),void 0!==e&&void 0!==t&&(this.offsetX=e,this.offsetY=t,this.moved=Math.abs(e-o)>100||Math.abs(t-r)>100),this.dialog.style.left=(e||o)+"px",this.dialog.style.top=(t||r)+"px",this}setHeader(e){return this.setElements(this.dialogbox_header,e),this}setContent(e){return this.setElements(this.dialogbox_content,e),this}setFooter(e){return this.setElements(this.dialogbox_footer,e),this.setMod("footer",!!e),this}getZIndex(){return parseInt((0,h.css)(this.container,"zIndex"),10)||0}getMaxZIndexDialog(){let e=0,t,i,n=this;return(0,h.$$)(".jodit-dialog",this.destination).forEach(o=>{t=o.component,i=parseInt((0,h.css)(o,"zIndex"),10),t.isOpened&&!isNaN(i)&&i>e&&(n=t,e=i)}),n}setMaxZIndex(){if(this.getMod("static"))return;let e=0x1312d04,t=0;(0,h.$$)(".jodit-dialog",this.destination).forEach(i=>{e=Math.max(isNaN(t=parseInt((0,h.css)(i,"zIndex"),10))?0:t,e)}),this.container.style.zIndex=(e+1).toString()}toggleFullSize(e){(0,d.isVoid)(e)&&(e=!this.getMod("fullsize")),this.setMod("fullsize",e),super.toggleFullSize(e)}open(e,t,i,n){if(u.eventEmitter.fire("closeAllPopups hideHelpers"),!1===this.e.fire(this,"beforeOpen"))return this;(0,d.isBoolean)(e)&&(i=e),(0,d.isBoolean)(t)&&(n=t),this.destroyAfterClose=!0===i;let o=(0,d.isBoolean)(e)?void 0:e,r=(0,d.isBoolean)(t)?void 0:t;return void 0!==r&&this.setHeader(r),o&&this.setContent(o),this.setMod("active",!0),this.isOpened=!0,this.setModal(n),this.destination.appendChild(this.container),!0!==this.getMod("static")?(this.setPosition(this.offsetX,this.offsetY),this.setMaxZIndex()):this.container.style.removeProperty("z-index"),this.o.fullsize&&this.toggleFullSize(!0),this.e.fire("afterOpen",this),this}setModal(e){return this.isModal=!!e,this.setMod("modal",this.isModal),this}close(){if(this.isDestructed||!this.isOpened||!0===this.getMod("static"))return this;let{e}=this;return!1===e.fire(this,"beforeClose")||!1===e.fire("beforeClose",this)||(this.setMod("active",!1),this.isOpened=!1,this.isFullSize&&this.toggleFullSize(!1),l.Dom.safeRemove(this.container),this.__removeGlobalResizeListeners(),e.fire(this,"afterClose"),e.fire(this.ow,"joditCloseDialog"),this.destroyAfterClose&&this.destruct()),this}buildToolbar(){this.o.buttons&&this.toolbar.build((0,c.splitArray)(this.o.buttons)).setMod("mode","header").appendTo(this.dialogbox_toolbar)}destruct(){this.isInDestruct||(this.setStatus(r.STATUSES.beforeDestruct),this.isOpened&&this.close(),this.events&&(this.__removeGlobalResizeListeners(),this.events.off(this.container,"close_dialog",self.close).off(this.ow,"keydown",this.__onEsc).off(this.ow,"resize",this.__onResize)),super.destruct())}constructor(e={}){super(e),(0,n._)(this,"resizer",void 0),(0,n._)(this,"offsetX",void 0),(0,n._)(this,"offsetY",void 0),(0,n._)(this,"destroyAfterClose",!1),(0,n._)(this,"moved",!1),(0,n._)(this,"resizable",!1),(0,n._)(this,"draggable",!1),(0,n._)(this,"startX",0),(0,n._)(this,"startY",0),(0,n._)(this,"startPoint",{x:0,y:0,w:0,h:0}),(0,n._)(this,"lockSelect",()=>{this.setMod("moved",!0)}),(0,n._)(this,"unlockSelect",()=>{this.setMod("moved",!1)}),(0,n._)(this,"__onResize",()=>{this.options&&this.o.resizable&&!this.moved&&this.isOpened&&!this.offsetX&&!this.offsetY&&this.setPosition()}),(0,n._)(this,"dialog",void 0),(0,n._)(this,"workplace",void 0),(0,n._)(this,"dialogbox_header",void 0),(0,n._)(this,"dialogbox_content",void 0),(0,n._)(this,"dialogbox_footer",void 0),(0,n._)(this,"dialogbox_toolbar",void 0),(0,n._)(this,"isModal",!1),(0,n._)(this,"isOpened",!1),this.options=(0,h.ConfigProto)(e,(0,h.ConfigProto)(v.Config.prototype.dialog,_.defaultOptions)),l.Dom.safeRemove(this.container);const t=this.getFullElName.bind(this);this.container=this.c.fromHTML(`<div class="jodit jodit-dialog ${this.componentName}">
19
+ </div>`}destruct(){return this.close(),super.destruct()}constructor(e,t=!0){super(e),(0,n._)(this,"smart",void 0),(0,n._)(this,"isOpened",void 0),(0,n._)(this,"strategy",void 0),(0,n._)(this,"viewBound",void 0),(0,n._)(this,"__targetBound",void 0),(0,n._)(this,"__childrenPopups",void 0),this.smart=t,this.isOpened=!1,this.strategy="leftBottom",this.viewBound=()=>({left:0,top:0,width:this.ow.innerWidth,height:this.ow.innerHeight}),this.__childrenPopups=new Set,(0,u.attr)(this.container,"role","popup")}}(0,o.__decorate)([s.autobind],f.prototype,"updatePosition",null),(0,o.__decorate)([(0,s.throttle)(10),s.autobind],f.prototype,"__throttleUpdatePosition",null),(0,o.__decorate)([s.autobind],f.prototype,"close",null),(0,o.__decorate)([s.autobind],f.prototype,"__closeOnOutsideClick",null)},34396:function(e,t,i){"use strict";i.d(t,{ProgressBar:function(){return c}});var n=i(25045),o=i(23211),r=i(28077),s=i(23599),a=i(80991),l=i(96007),u=i(29434);class c extends l.UIElement{className(){return"ProgressBar"}render(){return"<div><div></div></div>"}show(){return(this.j.workplace||this.j.container).appendChild(this.container),this}hide(){return o.Dom.safeRemove(this.container),this}progress(e){return this.container.style.width=e.toFixed(2)+"%",this}showFileUploadAnimation(e,t){this.__cleanUpAnimation();let i=(0,r.getContainer)(this.j,c),n=(0,s.position)(this.j.container,this.j),o=this.j.c.div(this.getFullElName("file-animation")),l=u.Icon.get("file","");l&&(o.innerHTML=l);let d=null!=e?e:{x:n.width/2,y:0},h=null!=t?t:{x:d.x+60,y:d.y-80};(0,a.css)(o,{left:n.left+d.x,top:n.top+d.y}),i.appendChild(o),this.__animationElement=o,o.offsetWidth,(0,a.css)(o,{left:n.left+h.x,top:n.top+h.y,opacity:0,transform:"scale(0.4)"});let p=()=>{o.removeEventListener("transitionend",p),this.__cleanUpAnimation()};o.addEventListener("transitionend",p)}__cleanUpAnimation(){this.__animationElement&&(o.Dom.safeRemove(this.__animationElement),this.__animationElement=null)}destruct(){return this.__cleanUpAnimation(),this.hide(),super.destruct()}constructor(...e){super(...e),(0,n._)(this,"__animationElement",null)}}},2222:function(e,t,i){"use strict";i.d(t,{ViewWithToolbar:function(){return g}});var n=i(25045),o=i(31635),r=i(69364),s=i(49574),a=i(68616),l=i(23211),u=i(45664),c=i(85932),d=i(28723),h=i(4099),p=i(2496),f=i(35099),m=i(4274);class g extends f.View{get toolbarContainer(){return!this.o.fullsize&&((0,c.isString)(this.o.toolbar)||l.Dom.isHTMLElement(this.o.toolbar))?(0,d.resolveElement)(this.o.toolbar,this.o.shadowRoot||this.od):(this.o.toolbar&&l.Dom.appendChildFirst(this.container,this.__defaultToolbarContainer),this.__defaultToolbarContainer)}setPanel(e){this.o.toolbar=e,this.buildToolbar()}buildToolbar(){var e;if(!this.o.toolbar)return;let t=this.o.buttons?(0,u.splitArray)(this.o.buttons):[];null==(e=this.toolbar)||e.setRemoveButtons(this.o.removeButtons).build(t.concat(this.o.extraButtons||[])).appendTo(this.toolbarContainer)}getRegisteredButtonGroups(){return this.groupToButtons}registerButton(e){var t;this.registeredButtons.add(e);let i=null!=(t=e.group)?t:"other";return this.groupToButtons[i]||(this.groupToButtons[i]=[]),null!=e.position?this.groupToButtons[i][e.position]=e.name:this.groupToButtons[i].push(e.name),this}unregisterButton(e){var t;this.registeredButtons.delete(e);let i=null!=(t=e.group)?t:"other",n=this.groupToButtons[i];if(n){let t=n.indexOf(e.name);-1!==t&&n.splice(t,1),0===n.length&&delete this.groupToButtons[i]}return this}beforeToolbarBuild(e){if(Object.keys(this.groupToButtons).length)return e.map(e=>(0,p.isButtonGroup)(e)&&e.group&&this.groupToButtons[e.group]?{group:e.group,buttons:[...e.buttons,...this.groupToButtons[e.group]]}:e)}destruct(){this.isDestructed||(this.setStatus(r.STATUSES.beforeDestruct),this.e.off("beforeToolbarBuild",this.beforeToolbarBuild),this.__tooltip.destruct(),this.toolbar.destruct(),this.toolbar=void 0,super.destruct())}constructor(e,t=!1){super(e,t),(0,n._)(this,"toolbar",(0,m.makeCollection)(this)),(0,n._)(this,"__defaultToolbarContainer",this.c.div("jodit-toolbar__box")),(0,n._)(this,"registeredButtons",new Set),(0,n._)(this,"groupToButtons",{}),(0,n._)(this,"isJodit",!1),(0,n._)(this,"__tooltip",new h.UITooltip(this)),this.isJodit=t,this.e.on("beforeToolbarBuild",this.beforeToolbarBuild)}}(0,o.__decorate)([(0,a.watch)(":rebuildToolbar")],g.prototype,"buildToolbar",null),(0,o.__decorate)([s.autobind],g.prototype,"beforeToolbarBuild",null)},35099:function(e,t,i){"use strict";i.d(t,{View:function(){return C}});var n=i(25045),o=i(31635),r=i(16964),s=i(80251),a=i(69364),l=i(81937),u=i(76517),c=i(51676),d=i(24968),h=i(29200),p=i(27795),f=i(1496),m=i(28077),g=i(65946),v=i(8006),_=i(24475),b=i(23183),y=i(81987),S=i(34396),w=i(10081);class C extends s.Component{get basePath(){return this.o.basePath?this.o.basePath:l.BASE_PATH}get minified(){return void 0!==this.o.minified?this.o.minified:l.BASE_PATH_IS_MIN}get defaultTimeout(){return(0,g.isVoid)(this.o.defaultTimeout)?100:this.o.defaultTimeout}get buffer(){return _.Storage.makeStorage()}get message(){return this.getMessageModule(this.container)}getMessageModule(e){return new w.UIMessages(this,e)}get storage(){return _.Storage.makeStorage(!0,this.id)}get asyncStorage(){return v.AsyncStorage.makeStorage(!0,this.id)}get c(){return this.create}get container(){return this.__container}set container(e){this.__container=e}get e(){return this.events}get progressbar(){return new S.ProgressBar(this)}get options(){return this.__options}set options(e){this.__options=e}get o(){return this.options}i18n(e,...t){return(0,g.i18n)(e,t,this.options)}toggleFullSize(e){void 0===e&&(e=!this.__isFullSize),e!==this.__isFullSize&&(this.__isFullSize=e,this.e.fire("toggleFullSize",e))}get isLocked(){return""!==this.__whoLocked}lock(e="any"){return!this.isLocked&&(this.__whoLocked=e,!0)}unlock(){return!!this.isLocked&&(this.__whoLocked="",!0)}get isFullSize(){return this.__isFullSize}getVersion(){return C.version}static getVersion(){return C.version}initOptions(e){this.options=(0,g.ConfigProto)(e||{},(0,g.ConfigProto)(this.options||{},C.defaultOptions))}initOwners(){var e;this.ownerWindow=null!=(e=this.o.ownerWindow)?e:window}attachEvents(e){if(!e)return;let t=null==e?void 0:e.events;t&&Object.keys(t).forEach(e=>this.e.on(e,t[e]))}getInstance(e,t){let i=(0,g.isFunction)(e)?e.prototype.className():e,n=this.e.fire((0,g.camelCase)("getInstance_"+i),t);if(n)return n;let o=(0,g.isFunction)(e)?e:m.modules[i],s=this.__modulesInstances;if(!(0,g.isFunction)(o))throw(0,g.error)("Need real module name");if(!s.has(i)){let e=o.prototype instanceof r.ViewComponent?new o(this,t):new o(t);this.components.add(e),s.set(i,e)}return s.get(i)}addDisclaimer(e){this.container.appendChild(e)}beforeDestruct(){this.e.fire(a.STATUSES.beforeDestruct,this),this.components.forEach(e=>{(0,g.isDestructable)(e)&&!e.isInDestruct&&e.destruct()}),this.components.clear()}destruct(){var e,t,i,n;this.isDestructed||(null==(e=(0,c.cached)(this,"progressbar"))||e.destruct(),null==(t=(0,c.cached)(this,"message"))||t.destruct(),null==(i=(0,c.cached)(this,"asyncStorage"))||i.close(),this.events&&(this.events.destruct(),this.events=void 0),null==(n=(0,c.cached)(this,"buffer"))||n.clear(),p.Dom.safeRemove(this.container),super.destruct())}constructor(e,t=!1){var i;super(),(0,n._)(this,"isJodit",void 0),(0,n._)(this,"isView",void 0),(0,n._)(this,"parent",void 0),(0,n._)(this,"mods",void 0),(0,n._)(this,"id",void 0),(0,n._)(this,"components",void 0),(0,n._)(this,"events",void 0),(0,n._)(this,"create",void 0),(0,n._)(this,"__container",void 0),(0,n._)(this,"OPTIONS",void 0),(0,n._)(this,"__options",void 0),(0,n._)(this,"__isFullSize",void 0),(0,n._)(this,"__whoLocked",void 0),(0,n._)(this,"isLockedNotBy",void 0),(0,n._)(this,"__modulesInstances",void 0),this.isJodit=t,this.isView=!0,this.parent=null,this.mods={},this.components=new Set,this.OPTIONS=C.defaultOptions,this.__isFullSize=!1,this.__whoLocked="",this.isLockedNotBy=e=>this.isLocked&&this.__whoLocked!==e,this.__modulesInstances=new Map,this.id=new Date().getTime().toString(),this.initOptions(e),this.initOwners(),this.events=null!=(i=null==e?void 0:e.eventEmmiter)?i:new f.EventEmitter(this.od),this.create=new u.Create(this.od),this.__container=this.c.div(`jodit ${this.componentName}`)}}(0,n._)(C,"ES",l.ES),(0,n._)(C,"version",l.APP_VERSION),(0,n._)(C,"esNext",l.IS_ES_NEXT),(0,n._)(C,"esModern",l.IS_ES_MODERN),(0,n._)(C,"defaultOptions",void 0),(0,o.__decorate)([c.cache],C.prototype,"buffer",null),(0,o.__decorate)([c.cache],C.prototype,"message",null),(0,o.__decorate)([c.cache],C.prototype,"storage",null),(0,o.__decorate)([c.cache],C.prototype,"asyncStorage",null),(0,o.__decorate)([c.cache],C.prototype,"c",null),(0,o.__decorate)([c.cache],C.prototype,"e",null),(0,o.__decorate)([c.cache],C.prototype,"progressbar",null),(0,o.__decorate)([(0,h.hook)(a.STATUSES.beforeDestruct)],C.prototype,"beforeDestruct",null),(C=(0,o.__decorate)([(0,d.derive)(y.Mods,b.Elms)],C)).defaultOptions={extraButtons:[],cache:!0,textIcons:!1,namespace:"",removeButtons:[],zIndex:100002,defaultTimeout:100,fullsize:!1,showTooltip:!0,useNativeTooltip:!1,buttons:[],globalFullSize:!0,language:"auto"}},73302:function(e,t,i){"use strict";i.d(t,{Jodit:function(){return Jodit}});var n=i(25045),o=i(31635),r=i(81937),s=i(84839),a=i(28077),l=i(65946),u=i(73714),c=i(80512),d=i(5266),h=i(60936);let p="data-jodit-default-style-display",f="data-jodit-default-classes",m={contenteditable:!1};class Jodit extends h.ViewWithToolbar{className(){return"Jodit"}waitForReady(){return this.isReady?Promise.resolve(this):this.async.promise(e=>{this.hookStatus("ready",()=>e(this))})}static get ready(){return new Promise(e=>{a.eventEmitter.on("joditready",e)})}get text(){if(this.editor)return this.editor.innerText||"";let e=this.createInside.div();return e.innerHTML=this.getElementValue(),e.innerText||""}get defaultTimeout(){return(0,l.isNumber)(this.o.defaultTimeout)?this.o.defaultTimeout:d.Config.defaultOptions.defaultTimeout}static atom(e){return(0,l.markAsAtomic)(e)}static make(e,t){return new this(e,t)}static isJoditAssigned(e){return e&&(0,l.isJoditObject)(e.component)&&!e.component.isInDestruct}static get defaultOptions(){return d.Config.defaultOptions}static configure(e){(0,l.ConfigMerge)(Jodit.defaultOptions,e)}get createInside(){return new h.Create(()=>this.ed,this.o.createAttributes)}__setPlaceField(e,t){this.currentPlace||(this.currentPlace={},this.places=[this.currentPlace]),this.currentPlace[e]=t}get element(){return this.currentPlace.element}get editor(){return this.currentPlace.editor}set editor(e){this.__setPlaceField("editor",e)}get container(){return this.currentPlace.container}set container(e){this.__setPlaceField("container",e)}get workplace(){return this.currentPlace.workplace}get message(){return this.getMessageModule(this.workplace)}get statusbar(){return this.currentPlace.statusbar}get iframe(){return this.currentPlace.iframe}set iframe(e){this.__setPlaceField("iframe",e)}get history(){return this.currentPlace.history}get editorWindow(){return this.currentPlace.editorWindow}set editorWindow(e){this.__setPlaceField("editorWindow",e)}get ew(){return this.editorWindow}get editorDocument(){return this.currentPlace.editorWindow.document}get ed(){return this.editorDocument}get options(){return this.currentPlace.options}set options(e){this.__options=e,this.__setPlaceField("options",e)}get s(){return this.selection}get uploader(){return this.getInstance("Uploader",this.o.uploader)}get filebrowser(){let e=this,t=(0,l.ConfigProto)({defaultTimeout:e.defaultTimeout,uploader:e.o.uploader,language:e.o.language,license:e.o.license,theme:e.o.theme,shadowRoot:e.o.shadowRoot,defaultCallback(t){t.files&&t.files.length&&t.files.forEach((i,n)=>{let o=t.baseurl+i;t.isImages&&t.isImages[n]?e.s.insertImage(o,null,e.o.imageDefaultWidth):e.s.insertNode(e.createInside.fromHTML(`<a href='${o}' title='${o}'>${o}</a>`))})}},this.o.filebrowser);return e.getInstance("FileBrowser",t)}get mode(){return this.__mode}set mode(e){this.setMode(e)}getNativeEditorValue(){let e=this.e.fire("beforeGetNativeEditorValue");return(0,l.isString)(e)?e:this.editor?this.editor.innerHTML:this.getElementValue()}setNativeEditorValue(e){let t={value:e};!this.e.fire("beforeSetNativeEditorValue",t)&&this.editor&&(this.editor.innerHTML=t.value)}get value(){return this.getEditorValue()}set value(e){this.setEditorValue(e),this.history.__processChanges()}synchronizeValues(){this.__imdSynchronizeValues()}__imdSynchronizeValues(){this.setEditorValue()}getEditorValue(e=!0,t){let i;if(void 0!==(i=this.e.fire("beforeGetValueFromEditor",t)))return i;i=this.getNativeEditorValue().replace(r.INVISIBLE_SPACE_REG_EXP(),""),e&&(i=i.replace(/<span[^>]+id="jodit-selection_marker_[^>]+><\/span>/g,"")),"<br>"===i&&(i="");let n={value:i};return this.e.fire("afterGetValueFromEditor",n,t),n.value}setEditorValue(e){let t=this.e.fire("beforeSetValueToEditor",e);if(!1===t)return;if((0,l.isString)(t)&&(e=t),!this.editor){void 0!==e&&this.__setElementValue(e);return}if(!(0,l.isString)(e)&&!(0,l.isVoid)(e))throw(0,l.error)("value must be string");(0,l.isVoid)(e)||this.getNativeEditorValue()===e||this.setNativeEditorValue(e),this.e.fire("postProcessSetEditorValue");let i=this.getElementValue(),n=this.getEditorValue();if(!this.__isSilentChange&&i!==n&&this.__callChangeCount<r.SAFE_COUNT_CHANGE_CALL){this.__setElementValue(n),this.__callChangeCount+=1,r.IS_PROD||this.__callChangeCount;try{this.history.__upTick(),this.e.fire("change",n,i),this.e.fire(this.history,"change",n,i)}finally{this.__callChangeCount=0}}}updateElementValue(){this.__setElementValue(this.getEditorValue())}getElementValue(){return void 0!==this.element.value?this.element.value:this.element.innerHTML}__setElementValue(e){if(!(0,l.isString)(e))throw(0,l.error)("value must be string");if(this.element!==this.container&&e!==this.getElementValue()){let t={value:e},i=this.e.fire("beforeSetElementValue",t);(0,l.callPromise)(i,()=>{void 0!==this.element.value?this.element.value=t.value:this.element.innerHTML=t.value,this.e.fire("afterSetElementValue",t)})}}registerCommand(e,t,i){let n=e.toLowerCase(),o=this.commands.get(n);if(void 0===o&&(o=[],this.commands.set(n,o)),o.push(t),!(0,l.isFunction)(t)){let o=this.o.commandToHotkeys[n]||this.o.commandToHotkeys[e]||t.hotkeys;o&&this.registerHotkeyToCommand(o,n,null==i?void 0:i.stopPropagation)}return this}registerHotkeyToCommand(e,t,i=!0){let n=(0,l.asArray)(e).map(l.normalizeKeyAliases).map(e=>e+".hotkey").join(" ");this.e.off(n).on(n,(e,n)=>(n&&(n.shouldStop=null==i||i),this.execCommand(t)))}execCommand(e,t,i,...n){let o;if(this.s.isFocused()||this.s.focus(),!this.o.readonly||this.o.allowCommandsInReadOnly.includes(e)){if(e=e.toLowerCase(),!1!==(o=this.e.fire(`beforeCommand${(0,l.ucfirst)(e)}`,t,i,...n))&&(o=this.e.fire("beforeCommand",e,t,i,...n)),!1!==o&&(o=this.__execCustomCommands(e,t,i,...n)),!1!==o){this.s.focus();try{o=this.nativeExecCommand(e,t,i)}catch(e){if(!r.IS_PROD)throw e}}return this.e.fire("afterCommand",e,t,i),this.__imdSynchronizeValues(),o}}nativeExecCommand(e,t,i){this.__isSilentChange=!0;try{return this.ed.execCommand(e,t,i)}finally{this.__isSilentChange=!1}}__execCustomCommands(e,t,i,...n){e=e.toLowerCase();let o=this.commands.get(e);if(void 0!==o){let r;return o.forEach(o=>{let s=((0,l.isFunction)(o)?o:o.exec).call(this,e,t,i,...n);void 0!==s&&(r=s)}),r}}lock(e="any"){return!!super.lock(e)&&(this.__selectionLocked=this.s.save(),this.s.clear(),this.container.classList.add("jodit_lock"),this.e.fire("lock",!0),!0)}unlock(){return!!super.unlock()&&(this.container.classList.remove("jodit_lock"),this.__selectionLocked&&this.s.restore(),this.e.fire("lock",!1),!0)}getMode(){return this.mode}isEditorMode(){return this.getRealMode()===r.MODE_WYSIWYG}getRealMode(){if(this.getMode()!==r.MODE_SPLIT)return this.getMode();let e=this.od.activeElement;return e&&(e===this.iframe||h.Dom.isOrContains(this.editor,e)||h.Dom.isOrContains(this.toolbar.container,e))?r.MODE_WYSIWYG:r.MODE_SOURCE}setMode(e){let t=this.getMode(),i={mode:parseInt(e.toString(),10)},n=["jodit-wysiwyg_mode","jodit-source__mode","jodit_split_mode"];!1!==this.e.fire("beforeSetMode",i)&&(this.__mode=[r.MODE_SOURCE,r.MODE_WYSIWYG,r.MODE_SPLIT].includes(i.mode)?i.mode:r.MODE_WYSIWYG,this.o.saveModeInStorage&&this.storage.set("jodit_default_mode",this.mode),n.forEach(e=>{this.container.classList.remove(e)}),this.container.classList.add(n[this.mode-1]),t!==this.getMode()&&this.e.fire("afterSetMode"))}toggleMode(){let e=this.getMode();[r.MODE_SOURCE,r.MODE_WYSIWYG,this.o.useSplitMode?r.MODE_SPLIT:9].includes(e+1)?e+=1:e=r.MODE_WYSIWYG,this.setMode(e)}setDisabled(e){this.o.disabled=e;let t=this.__wasReadOnly;this.setReadOnly(e||t),this.__wasReadOnly=t,this.editor&&(this.editor.setAttribute("aria-disabled",e.toString()),this.container.classList.toggle("jodit_disabled",e),this.e.fire("disabled",e))}getDisabled(){return this.o.disabled}setReadOnly(e){this.__wasReadOnly!==e&&(this.__wasReadOnly=e,this.o.readonly=e,e?this.editor&&this.editor.removeAttribute("contenteditable"):this.editor&&this.editor.setAttribute("contenteditable","true"),this.e&&this.e.fire("readonly",e))}getReadOnly(){return this.o.readonly}focus(){this.getMode()!==r.MODE_SOURCE&&this.s.focus()}get isFocused(){return this.s.isFocused()}beforeInitHook(){}afterInitHook(){}initOptions(e){this.options=(0,l.ConfigProto)(e||{},d.Config.defaultOptions)}initOwners(){this.editorWindow=this.o.ownerWindow,this.ownerWindow=this.o.ownerWindow}addPlace(e,t){let i=(0,l.resolveElement)(e,this.o.shadowRoot||this.od);this.attachEvents(t),i.attributes&&(0,l.toArray)(i.attributes).forEach(e=>{let i=e.name,n=e.value;void 0===d.Config.defaultOptions[i]||t&&void 0!==t[i]||(-1!==["readonly","disabled"].indexOf(i)&&(n=""===n||"true"===n),/^[0-9]+(\.)?([0-9]+)?$/.test(n.toString())&&(n=Number(n)),this.options[i]=n)});let n=this.c.div("jodit-container");n.classList.add("jodit"),n.classList.add("jodit-container"),n.classList.add(`jodit_theme_${this.o.theme||"default"}`),g(this.o.className,n),this.o.containerStyle&&(0,l.css)(n,this.o.containerStyle);let{styleValues:o}=this.o;Object.keys(o).forEach(e=>{let t=(0,l.kebabCase)(e);n.style.setProperty(`--jd-${t}`,o[e])}),n.setAttribute("contenteditable","false");let r=null;this.o.inline&&(-1===["TEXTAREA","INPUT"].indexOf(i.nodeName)&&(n=i,i.setAttribute(f,i.className.toString()),r=n.innerHTML,n.innerHTML=""),n.classList.add("jodit_inline"),n.classList.add("jodit-container")),i!==n&&(i.style.display&&i.setAttribute(p,i.style.display),i.style.display="none");let s="workplace-slot",a=this.c.div(this.getFullElName(s,"top"),m);n.appendChild(a);let u=this.c.div(this.getFullElName(s,"center"),m),c=this.c.div("jodit-workplace",m),v=this.c.div(this.getFullElName(s,"left"),m),_=this.c.div(this.getFullElName(s,"right"),m);u.appendChild(v),u.appendChild(c),u.appendChild(_),n.appendChild(u);let b=this.c.div(this.getFullElName(s,"bottom"),m);n.appendChild(b),i.parentNode&&i!==n&&i.parentNode.insertBefore(n,i),Object.defineProperty(i,"component",{enumerable:!1,configurable:!0,value:this});let y=this.c.div("jodit-wysiwyg",{contenteditable:!0,"aria-disabled":!1,tabindex:this.o.tabIndex});c.appendChild(y);let S={editor:y,element:i,container:n,workplace:c,slots:{top:a,bottom:b,center:u,left:v,right:_},statusbar:new h.StatusBar(this,n),options:this.isReady?(0,l.ConfigProto)(t||{},d.Config.defaultOptions):this.options,history:new h.History(this),editorWindow:this.ow};this.__elementToPlace.set(y,S),this.setCurrentPlace(S),this.places.push(S),this.setNativeEditorValue(this.getElementValue());let w=this.__initEditor(r),C=this.options,k=()=>{C.enableDragAndDropFileToEditor&&C.uploader&&(C.uploader.url||C.uploader.insertImageAsBase64URI)&&this.uploader.bind(this.editor),this.__elementToPlace.get(this.editor)||this.__elementToPlace.set(this.editor,S),this.e.fire("afterAddPlace",S)};return(0,l.callPromise)(w,k)}addDisclaimer(e){this.workplace.appendChild(e)}setCurrentPlace(e){this.currentPlace!==e&&(this.isEditorMode()||this.setMode(r.MODE_WYSIWYG),this.currentPlace=e,this.buildToolbar(),this.isReady&&this.e.fire("changePlace",e))}__initEditor(e){let t=this.__createEditor();return(0,l.callPromise)(t,()=>{if(this.isInDestruct)return;if(this.element!==this.container){let e=this.getElementValue();e!==this.getEditorValue()&&this.setEditorValue(e)}else null!=e&&this.setEditorValue(e);let t=this.o.defaultMode;if(this.o.saveModeInStorage){let e=this.storage.get("jodit_default_mode");"string"==typeof e&&(t=parseInt(e,10))}this.setMode(t),this.o.readonly&&(this.__wasReadOnly=!1,this.setReadOnly(!0)),this.o.disabled&&this.setDisabled(!0);try{this.ed.execCommand("defaultParagraphSeparator",!1,this.o.enter.toLowerCase())}catch(e){}})}__createEditor(){let e=this.editor,t=this.e.fire("createEditor",this);return(0,l.callPromise)(t,()=>{!this.isInDestruct&&((!1===t||(0,l.isPromise)(t))&&h.Dom.safeRemove(e),g(this.o.editorClassName,this.editor),this.o.style&&(0,l.css)(this.editor,this.o.style),this.e.on("synchro",()=>{this.setEditorValue()}).on("focus",()=>{this.editorIsActive=!0}).on("blur",()=>this.editorIsActive=!1),this.__prepareWYSIWYGEditor(),this.o.triggerChangeEvent&&this.e.on("change",this.async.debounce(()=>{this.e&&this.e.fire(this.element,"change")},this.defaultTimeout)))})}__prepareWYSIWYGEditor(){let{editor:e}=this;if(this.o.direction){let e="rtl"===this.o.direction.toLowerCase()?"rtl":"ltr";this.editor.style.direction=e,this.editor.setAttribute("dir",e),this.container.style.direction=e,this.container.setAttribute("dir",e),this.toolbar.setDirection(e)}this.e.on(e,"mousedown touchstart focus",()=>{let t=this.__elementToPlace.get(e);t&&this.setCurrentPlace(t)}).on(e,"compositionend",this.synchronizeValues).on(e,"selectionchange selectionstart keydown keyup input keypress dblclick mousedown mouseup click copy cut dragstart drop dragover paste resize touchstart touchend focus blur",e=>{if(!this.o.readonly&&!this.__isSilentChange&&(!(e instanceof this.ew.KeyboardEvent)||!e.isComposing)&&this.e&&this.e.fire){if(!1===this.e.fire(e.type,e))return!1;this.synchronizeValues()}})}fetch(e,t){let i=new u.Ajax({url:e,...t},this.o.defaultAjaxOptions),n=()=>{this.e.off("beforeDestruct",n),this.progressbar.progress(100).hide(),i.destruct()};this.e.one("beforeDestruct",n),this.progressbar.show().progress(30);let o=i.send();return o.finally(n).catch(()=>null),o}destruct(){var e,t;if(this.isInDestruct)return;this.setStatus(h.STATUSES.beforeDestruct),this.__elementToPlace.clear(),null==(e=(0,s.cached)(this,"storage"))||e.clear(),null==(t=(0,s.cached)(this,"buffer"))||t.clear(),this.commands.clear(),this.__selectionLocked=null,this.e.off(this.ow,"resize"),this.e.off(this.ow),this.e.off(this.od),this.e.off(this.od.body);let i=this.editor?this.getEditorValue():"";this.places.forEach(({container:e,workplace:t,statusbar:n,element:o,iframe:r,editor:s,history:a})=>{if(o){if(o!==e)if(o.hasAttribute(p)){let e=(0,l.attr)(o,p);e&&(o.style.display=e,o.removeAttribute(p))}else o.style.display="";else o.hasAttribute(f)&&(o.className=(0,l.attr)(o,f)||"",o.removeAttribute(f));o.hasAttribute("style")&&!(0,l.attr)(o,"style")&&o.removeAttribute("style"),n.destruct(),this.e.off(e),this.e.off(o),this.e.off(s),h.Dom.safeRemove(t),h.Dom.safeRemove(s),e!==o&&h.Dom.safeRemove(e),Object.defineProperty(o,"component",{enumerable:!1,configurable:!0,value:null}),h.Dom.safeRemove(r),e===o&&(o.innerHTML=i),a.destruct()}}),this.places.length=0,this.currentPlace={},delete a.instances[this.id],super.destruct()}constructor(e,t){super(t,!0),(0,n._)(this,"isJodit",!0),(0,n._)(this,"commands",new Map),(0,n._)(this,"__selectionLocked",null),(0,n._)(this,"__wasReadOnly",!1),(0,n._)(this,"editorIsActive",!1),(0,n._)(this,"selection",void 0),(0,n._)(this,"__mode",r.MODE_WYSIWYG),(0,n._)(this,"__callChangeCount",0),(0,n._)(this,"__isSilentChange",!1),(0,n._)(this,"currentPlace",{options:this.__options,container:this.__container}),(0,n._)(this,"places",[]),(0,n._)(this,"__elementToPlace",new Map);try{const t=(0,l.resolveElement)(e,this.options.shadowRoot||this.od);if(Jodit.isJoditAssigned(t))return t.component}catch(e){if(!r.IS_PROD)throw e;throw this.destruct(),e}this.setStatus(h.STATUSES.beforeInit),this.id=(0,l.attr)((0,l.resolveElement)(e,this.o.shadowRoot||this.od),"id")||new Date().getTime().toString(),a.instances[this.id]=this,this.attachEvents(t),this.e.on(this.ow,"resize",()=>{this.e&&this.e.fire("resize")}),this.e.on("prepareWYSIWYGEditor",this.__prepareWYSIWYGEditor),this.selection=new h.Selection(this);const i=this.beforeInitHook();(0,l.callPromise)(i,()=>{if(this.isInDestruct)return;this.e.fire("beforeInit",this),a.pluginSystem.__init(this),this.e.fire("afterPluginSystemInit",this),this.e.on("changePlace",()=>{this.setReadOnly(this.o.readonly),this.setDisabled(this.o.disabled)}),this.places.length=0;let i=this.addPlace(e,t);a.instances[this.id]=this;let n=()=>{this.isInDestruct||(this.e&&this.e.fire("afterInit",this),(0,l.callPromise)(this.afterInitHook()),this.setStatus(h.STATUSES.ready),this.e.fire("afterConstructor",this))};(0,l.callPromise)(i,n)})}}function g(e,t){e&&e.split(/\s+/).forEach(e=>t.classList.add(e))}(0,n._)(Jodit,"fatMode",r.FAT_MODE),(0,n._)(Jodit,"plugins",a.pluginSystem),(0,n._)(Jodit,"modules",a.modules),(0,n._)(Jodit,"ns",a.modules),(0,n._)(Jodit,"decorators",{}),(0,n._)(Jodit,"constants",r),(0,n._)(Jodit,"instances",a.instances),(0,n._)(Jodit,"lang",r.lang),(0,n._)(Jodit,"core",{Plugin:h.Plugin}),(0,o.__decorate)([s.cache],Jodit.prototype,"createInside",null),(0,o.__decorate)([s.cache],Jodit.prototype,"message",null),(0,o.__decorate)([s.cache],Jodit.prototype,"s",null),(0,o.__decorate)([s.cache],Jodit.prototype,"uploader",null),(0,o.__decorate)([s.cache],Jodit.prototype,"filebrowser",null),(0,o.__decorate)([(0,s.throttle)()],Jodit.prototype,"synchronizeValues",null),(0,o.__decorate)([(0,s.watch)(":internalChange")],Jodit.prototype,"updateElementValue",null),(0,o.__decorate)([s.autobind],Jodit.prototype,"__prepareWYSIWYGEditor",null),Jodit=(0,o.__decorate)([(0,s.derive)(c.Dlgs)],Jodit)},89317:function(e,t,i){"use strict";var n=i(17312),o=i(57741),r=i(56014),s=i(95461),a=i(63837),l=i(39386),u=i(62327),c=i(25090),d=i(53113),h=i(81321),p=i(4679),f=i(31927),m=i(21195),g=i(53414),v=i(11012),_=i(87061),b=i(3268),y=i(85325),S=i(97834),w=i(86433),C=i(28359),k=i(68368),E=i(57456),I=i(25182),T=i(44906);let x={};x={ar:o,cs_cz:r,de:s,en:a,es:l,fi:u,fr:c,he:d,hu:h,id:p,it:f,ja:m,ko:v,mn:_,nl:b,no:y,pl:S,pt_br:w,ru:C,tr:k,ua:E,zh_cn:I,zh_tw:T};let D=e=>e?e.default||e:{},j={};(0,n.isArray)(D(g))&&D(g).forEach((e,t)=>{j[t]=e}),Object.keys(x).forEach(e=>{let t=D(x[e]);(0,n.isArray)(t)?(x[e]={},t.forEach((t,i)=>{x[e][j[i]]=t})):x[e]=t}),t.default=x},67399:function(e,t,i){"use strict";i.d(t,{ContextMenu:function(){return l}});var n=i(31635),o=i(91672),r=i(17312),s=i(53681),a=i(51116);class l extends a.Popup{className(){return"ContextMenu"}show(e,t,i){let n=this;n.clear(),(0,r.isArray)(i)&&(i.forEach(e=>{if(!e)return;let t=(0,s.Button)(this.jodit,e.icon||"empty",e.title);this.jodit&&t.setParentView(this.jodit),t.setMod("context","menu"),t.onAction(t=>{var i;return null==(i=e.exec)||i.call(n,t),n.clear(),n.close(),!1}),this.append(t)}),this.open(()=>({left:e,top:t,width:0,height:0}),!0))}}l=(0,n.__decorate)([o.component],l)},91535:function(e,t,i){"use strict";i.d(t,{Alert:function(){return l}});var n=i(23211),o=i(78982),r=i(91565),s=i(53681),a=i(76841);function l(e,t,i,u="jodit-dialog_alert"){(0,r.isFunction)(t)&&(i=t,t=void 0);let c=this instanceof a.Dialog?this:new a.Dialog({closeOnClickOverlay:!0}),d=c.c.div(u),h=(0,s.Button)(c,"ok","Ok");return(0,o.asArray)(e).forEach(e=>{d.appendChild(n.Dom.isNode(e)?e:c.c.fromHTML(e))}),h.onAction(()=>{i&&(0,r.isFunction)(i)&&!1===i(c)||c.close()}),c.setFooter([h]),c.open(d,t||"&nbsp;",!0,!0),h.focus(),c}},88329:function(e,t,i){"use strict";i.d(t,{Confirm:function(){return s}});var n=i(91565),o=i(53681),r=i(76841);function s(e,t,i){let s=this instanceof r.Dialog?this:new r.Dialog({closeOnClickOverlay:!0}),a=s.c.fromHTML('<form class="jodit-dialog_prompt"></form>'),l=s.c.element("label");(0,n.isFunction)(t)&&(i=t,t=void 0),l.appendChild(s.c.fromHTML(e)),a.appendChild(l);let u=e=>()=>{i&&!1===i(e)||s.close()},c=(0,o.Button)(s,"cancel","Cancel"),d=(0,o.Button)(s,"ok","Yes");return c.onAction(u(!1)),d.onAction(u(!0)),s.e.on(a,"submit",()=>(u(!0)(),!1)),s.setFooter([d,c]),s.open(a,t||"&nbsp;",!0,!0),d.focus(),s}},76841:function(e,t,i){"use strict";i.d(t,{Dialog:function(){return _}});var n=i(25045),o=i(31635),r=i(16964),s=i(81937),a=i(84839),l=i(23211),u=i(28077),c=i(45664),d=i(28686),h=i(93640),p=i(28712),f=i(4099),m=i(35099),g=i(2222),v=i(5266);v.Config.prototype.dialog={namespace:"",extraButtons:[],resizable:!0,draggable:!0,buttons:["dialog.close"],removeButtons:[],toolbarButtonSize:"middle",zIndex:"inherit"},v.Config.prototype.controls.dialog={close:{icon:"cancel",exec:e=>{e.close()}}};class _ extends g.ViewWithToolbar{className(){return"Dialog"}get destination(){let{popupRoot:e,shadowRoot:t}=this.o;return e||t||this.od.body}setElements(e,t){let i=[];(0,c.asArray)(t).forEach(t=>{let n;if((0,d.isArray)(t)){let n=this.c.div(this.getFullElName("column"));return i.push(n),e.appendChild(n),this.setElements(n,t)}n=(0,d.isString)(t)?this.c.fromHTML(t):(0,d.hasContainer)(t)?t.container:t,i.push(n),n.parentNode!==e&&e.appendChild(n)}),(0,c.toArray)(e.childNodes).forEach(t=>{-1===i.indexOf(t)&&e.removeChild(t)})}__onMouseUp(){(this.draggable||this.resizable)&&(this.__removeGlobalResizeListeners(),this.draggable=!1,this.resizable=!1,this.unlockSelect(),this.e&&(this.__removeGlobalResizeListeners(),this.e.fire(this,"endResize endMove")))}__onHeaderMouseDown(e){let t=e.target;!(!this.o.draggable||t&&t.nodeName.match(/^(INPUT|SELECT)$/))&&(this.draggable=!0,this.startX=e.clientX,this.startY=e.clientY,this.startPoint.x=(0,h.css)(this.dialog,"left"),this.startPoint.y=(0,h.css)(this.dialog,"top"),this.setMaxZIndex(),e.cancelable&&e.preventDefault(),this.lockSelect(),this.__addGlobalResizeListeners(),this.e&&(this.e.fire(this,"startMove"),this.e.fire("closeAllPopups")))}__onMouseMove(e){this.draggable&&this.o.draggable&&(this.setPosition(this.startPoint.x+e.clientX-this.startX,this.startPoint.y+e.clientY-this.startY),this.e&&this.e.fire(this,"move",e.clientX-this.startX,e.clientY-this.startY),e.stopImmediatePropagation()),this.resizable&&this.o.resizable&&(this.setSize(this.startPoint.w+e.clientX-this.startX,this.startPoint.h+e.clientY-this.startY),this.e&&this.e.fire(this,"resizeDialog",e.clientX-this.startX,e.clientY-this.startY))}__onEsc(e){if(this.o.closeOnEsc&&this.isOpened&&e.key===s.KEY_ESC&&!0!==this.getMod("static")){let t=this.getMaxZIndexDialog();t?t.close():this.close(),e.stopImmediatePropagation()}}__onResizerMouseDown(e){this.resizable=!0,this.startX=e.clientX,this.startY=e.clientY,this.startPoint.w=this.dialog.offsetWidth,this.startPoint.h=this.dialog.offsetHeight,this.lockSelect(),this.__addGlobalResizeListeners(),this.e&&this.e.fire(this,"startResize")}__addGlobalResizeListeners(){this.e.on(this.ow,"pointermove touchmove",this.__onMouseMove).on(this.ow,"pointerup touchend",this.__onMouseUp)}__removeGlobalResizeListeners(){this.e.off(this.ow,"mousemove pointermove",this.__onMouseMove).off(this.ow,"mouseup pointerup",this.__onMouseUp)}setSize(e,t){return null==e&&(e=this.dialog.offsetWidth),null==t&&(t=this.dialog.offsetHeight),(0,h.css)(this.dialog,{width:e,height:t}),this}calcAutoSize(){return this.setSize("auto","auto"),this.setSize(),this}setPosition(e,t){let i=this.ow.innerWidth,n=this.ow.innerHeight,o=i/2-this.dialog.offsetWidth/2,r=n/2-this.dialog.offsetHeight/2;return o<0&&(o=0),r<0&&(r=0),void 0!==e&&void 0!==t&&(this.offsetX=e,this.offsetY=t,this.moved=Math.abs(e-o)>100||Math.abs(t-r)>100),this.dialog.style.left=(e||o)+"px",this.dialog.style.top=(t||r)+"px",this}setHeader(e){return this.setElements(this.dialogbox_header,e),this}setContent(e){return this.setElements(this.dialogbox_content,e),this}setFooter(e){return this.setElements(this.dialogbox_footer,e),this.setMod("footer",!!e),this}getZIndex(){return parseInt((0,h.css)(this.container,"zIndex"),10)||0}getMaxZIndexDialog(){let e=0,t,i,n=this;return(0,h.$$)(".jodit-dialog",this.destination).forEach(o=>{t=o.component,i=parseInt((0,h.css)(o,"zIndex"),10),t.isOpened&&!isNaN(i)&&i>e&&(n=t,e=i)}),n}setMaxZIndex(){if(this.getMod("static"))return;let e=0x1312d04,t=0;(0,h.$$)(".jodit-dialog",this.destination).forEach(i=>{e=Math.max(isNaN(t=parseInt((0,h.css)(i,"zIndex"),10))?0:t,e)}),this.container.style.zIndex=(e+1).toString()}toggleFullSize(e){(0,d.isVoid)(e)&&(e=!this.getMod("fullsize")),this.setMod("fullsize",e),super.toggleFullSize(e)}open(e,t,i,n){if(u.eventEmitter.fire("closeAllPopups hideHelpers"),!1===this.e.fire(this,"beforeOpen"))return this;(0,d.isBoolean)(e)&&(i=e),(0,d.isBoolean)(t)&&(n=t),this.destroyAfterClose=!0===i;let o=(0,d.isBoolean)(e)?void 0:e,r=(0,d.isBoolean)(t)?void 0:t;return void 0!==r&&this.setHeader(r),o&&this.setContent(o),this.setMod("active",!0),this.isOpened=!0,this.setModal(n),this.destination.appendChild(this.container),!0!==this.getMod("static")?(this.setPosition(this.offsetX,this.offsetY),this.setMaxZIndex()):this.container.style.removeProperty("z-index"),this.o.fullsize&&this.toggleFullSize(!0),this.e.fire("afterOpen",this),this}setModal(e){return this.isModal=!!e,this.setMod("modal",this.isModal),this}close(){if(this.isDestructed||!this.isOpened||!0===this.getMod("static"))return this;let{e}=this;return!1===e.fire(this,"beforeClose")||!1===e.fire("beforeClose",this)||(this.setMod("active",!1),this.isOpened=!1,this.isFullSize&&this.toggleFullSize(!1),l.Dom.safeRemove(this.container),this.__removeGlobalResizeListeners(),e.fire(this,"afterClose"),e.fire(this.ow,"joditCloseDialog"),this.destroyAfterClose&&this.destruct()),this}buildToolbar(){this.o.buttons&&this.toolbar.build((0,c.splitArray)(this.o.buttons)).setMod("mode","header").appendTo(this.dialogbox_toolbar)}destruct(){this.isInDestruct||(this.setStatus(r.STATUSES.beforeDestruct),this.isOpened&&this.close(),this.events&&(this.__removeGlobalResizeListeners(),this.events.off(this.container,"close_dialog",self.close).off(this.ow,"keydown",this.__onEsc).off(this.ow,"resize",this.__onResize)),super.destruct())}constructor(e={}){super(e),(0,n._)(this,"resizer",void 0),(0,n._)(this,"offsetX",void 0),(0,n._)(this,"offsetY",void 0),(0,n._)(this,"destroyAfterClose",!1),(0,n._)(this,"moved",!1),(0,n._)(this,"resizable",!1),(0,n._)(this,"draggable",!1),(0,n._)(this,"startX",0),(0,n._)(this,"startY",0),(0,n._)(this,"startPoint",{x:0,y:0,w:0,h:0}),(0,n._)(this,"lockSelect",()=>{this.setMod("moved",!0)}),(0,n._)(this,"unlockSelect",()=>{this.setMod("moved",!1)}),(0,n._)(this,"__onResize",()=>{this.options&&this.o.resizable&&!this.moved&&this.isOpened&&!this.offsetX&&!this.offsetY&&this.setPosition()}),(0,n._)(this,"dialog",void 0),(0,n._)(this,"workplace",void 0),(0,n._)(this,"dialogbox_header",void 0),(0,n._)(this,"dialogbox_content",void 0),(0,n._)(this,"dialogbox_footer",void 0),(0,n._)(this,"dialogbox_toolbar",void 0),(0,n._)(this,"isModal",!1),(0,n._)(this,"isOpened",!1),this.options=(0,h.ConfigProto)(e,(0,h.ConfigProto)(v.Config.prototype.dialog,_.defaultOptions)),l.Dom.safeRemove(this.container);const t=this.getFullElName.bind(this);this.container=this.c.fromHTML(`<div class="jodit jodit-dialog ${this.componentName}">
20
20
  <div class="${t("overlay")}"></div>
21
21
  <div class="${this.getFullElName("panel")}">
22
22
  <div class="${t("header")}">
@@ -146,8 +146,8 @@
146
146
  <div class="jodit-input_group">
147
147
  <input class="jodit-input &__imageSrc" type="text"/>
148
148
  <div class="jodit-input_group-buttons &__fixImage">
149
- <a class="jodit-button &__changeImage">*image*</a>
150
- <a class="jodit-button &__editImage">*crop*</a>
149
+ <a class="jodit-button &__changeImage" data-ref="changeImage">*image*</a>
150
+ <a class="jodit-button &__editImage" data-ref="editImage">*crop*</a>
151
151
  </div>
152
152
  </div>
153
153
  </div>