Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

jodit-pro

Package Overview
Dependencies
Maintainers
1
Versions
217
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

jodit-pro - npm Package Compare versions

Comparing version 1.0.45 to 1.0.46

build/plugins/tune-block/tune-block.es5.js

3

build/config.js

@@ -21,5 +21,6 @@ /*!

'show-blocks',
'button-generator'
'button-generator',
'tune-block'
];
Jodit.defaultOptions.disablePlugins = [];
/*!
* jodit-pro - PRO Version of Jodit Editor
* Author: Chupurnov Valeriy <chupurnov@gmail.com>
* Version: v1.0.45
* Version: v1.0.46
* Url: https://xdsoft.net/jodit/pro/

@@ -10,2 +10,2 @@ * License(s): SEE LICENSE IN LICENSE.md

!function(e,t){if("object"==typeof exports&&"object"==typeof module)module.exports=t();else if("function"==typeof define&&define.amd)define([],t);else{var o=t();for(var n in o)("object"==typeof exports?exports:e)[n]=o[n]}}(self,(function(){return(self.webpackChunkjodit_pro=self.webpackChunkjodit_pro||[]).push([[633],{505:(e,t,o)=>{"use strict";o.r(t)},503:(e,t,o)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.autocomplete=void 0;var n=o(1),i=o(187),r=o(12),s=o(103),u=o(23),c=o(14),l=o(504),p=o(13),a=o(2);r.Config.prototype.autocomplete={sources:[]};var h=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.requires=["enter","license"],t.hasStyle=!a.Jodit.fatMode,t.sources=[],t}return n.__extends(t,e),t.prototype.afterInit=function(e){var t=this;this.popup=new c.Popup(e),this.popup.setMod("padding",!1),this.list=new l.Autocomplete(e),this.popup.setContent(this.list.container),e.e.on(this.list,"select.autocomplete",(function(o){var n=e.s.current();if(c.Dom.isText(n)&&n.nodeValue){var i=n.nodeValue.split(" ");i[i.length-1]=o.value,n.nodeValue=i.join(" "),e.s.setCursorAfter(n)}else e.s.insertNode(e.createInside.text(o.value),!0);t.popup.close()})).on("keydown.autocomplete",this.onKeyDown).on("keydown.autocomplete",this.onKeyControlDown,void 0,!0).on("autocomplete.autocomplete",this.onAutoComplete).on("registerAutocompleteSource.autocomplete",this.registerAutocompleteSource.bind(this))},t.prototype.registerAutocompleteSource=function(e){this.sources.push(e)},t.isContolKey=function(e){return e===p.KEY_DOWN||e===p.KEY_UP||e===p.KEY_ENTER||e===p.KEY_TAB},t.prototype.onKeyDown=function(e){return n.__awaiter(this,void 0,Promise,(function(){var o,i,r,s;return n.__generator(this,(function(n){switch(n.label){case 0:return t.isContolKey(e.key)||!this.j.s.isCollapsed?[2]:(o=this.j.s.current(),c.Dom.isText(o)&&o.nodeValue?(i=o.nodeValue.split(" "),(r=i.pop())&&u.trim(r).length?[4,this.onAutoComplete(r)]:[3,2]):[3,2]);case 1:if((s=n.sent()).length)return[2,this.openPopup(s)];n.label=2;case 2:return this.popup.isOpened&&this.popup.close(),[2]}}))}))},t.prototype.onKeyControlDown=function(e){if(this.popup.isOpened&&t.isContolKey(e.key)){switch(e.key){case p.KEY_DOWN:this.list.selectNext();break;case p.KEY_UP:this.list.selectPrevious();break;case p.KEY_TAB:case p.KEY_ENTER:this.list.select()}return this.j.e.stopPropagation(e.type),!1}},t.prototype.onAutoComplete=function(e){return n.__awaiter(this,void 0,Promise,(function(){var t,o=this;return n.__generator(this,(function(i){switch(i.label){case 0:return t=[],[4,Promise.all(this.sources.concat(this.j.o.autocomplete.sources).map((function(i){return n.__awaiter(o,void 0,void 0,(function(){var o;return n.__generator(this,(function(n){switch(n.label){case 0:return[4,i(e)];case 1:return(o=n.sent())&&u.isArray(o)&&t.push.apply(t,o),[2]}}))}))})))];case 1:return i.sent(),[2,t]}}))}))},t.prototype.openPopup=function(e){var t=this;this.list.build(e),this.popup.open((function(){return t.j.s.range.getBoundingClientRect()}))},t.prototype.beforeDestruct=function(e){e.e.off(this.list).off("keydown.autocomplete",this.onKeyDown).off("autocomplete.autocomplete",this.onAutoComplete).off(".autocomplete"),this.list.destruct(),this.popup.destruct()},n.__decorate([s.debounce()],t.prototype,"onKeyDown",null),n.__decorate([s.autobind],t.prototype,"onKeyControlDown",null),n.__decorate([s.autobind],t.prototype,"onAutoComplete",null),t}(i.Plugin);t.autocomplete=h,a.Jodit.plugins.add("autocomplete",h)},504:(e,t,o)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Autocomplete=void 0;var n=o(1);o(505);var i=o(103),r=o(79),s=o(506),u=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.elements=[],t.currentSelection=-1,t}return n.__extends(t,e),t.prototype.className=function(){return"Autocomplete"},t.prototype.onChangeSelection=function(e,t){var o;null!=t&&(null===(o=this.elements[t])||void 0===o||o.setMod("active",!1)),this.elements[this.currentSelection].setMod("active",!0),this.elements[this.currentSelection].container.scrollIntoView(!1)},t.prototype.build=function(e){var t=this;this.clear(),e.forEach((function(e,o){var n=new s.AutocompleteItem(t.jodit,e);t.j.e.on(n.container,"click",(function(){t.currentSelection=o,t.select()})),t.append(n)})),this.currentSelection=0,this.onChangeSelection()},t.prototype.selectNext=function(){this.currentSelection+1>this.elements.length-1?this.currentSelection=0:this.currentSelection+=1},t.prototype.selectPrevious=function(){0>this.currentSelection-1?this.currentSelection=this.elements.length-1:this.currentSelection-=1},t.prototype.select=function(){this.j.e.fire(this,"select.autocomplete",this.elements[this.currentSelection].item)},n.__decorate([i.watch("currentSelection")],t.prototype,"onChangeSelection",null),n.__decorate([i.component],t)}(r.UIGroup);t.Autocomplete=u},506:(e,t,o)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AutocompleteItem=void 0;var n=o(1);o(505);var i=function(e){function t(t,o){var n,i=e.call(this,t)||this;return i.item=o,i.container.innerText=null!==(n=o.title)&&void 0!==n?n:o.value,i}return n.__extends(t,e),t.prototype.className=function(){return"AutocompleteItem"},t}(o(79).UIElement);t.AutocompleteItem=i}},e=>{"use strict";e(e.s=503)}])}));
!function(e,t){if("object"==typeof exports&&"object"==typeof module)module.exports=t();else if("function"==typeof define&&define.amd)define([],t);else{var o=t();for(var n in o)("object"==typeof exports?exports:e)[n]=o[n]}}(self,(function(){return(self.webpackChunkjodit_pro=self.webpackChunkjodit_pro||[]).push([[633],{505:(e,t,o)=>{"use strict";o.r(t)},503:(e,t,o)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.autocomplete=void 0;var n=o(1),i=o(187),r=o(12),s=o(103),u=o(23),c=o(14),l=o(504),p=o(13),a=o(2);r.Config.prototype.autocomplete={sources:[]};var h=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.requires=["enter","license"],t.hasStyle=!a.Jodit.fatMode,t.sources=[],t}return n.__extends(t,e),t.prototype.afterInit=function(e){var t=this;this.popup=new c.Popup(e),this.popup.setMod("padding",!1),this.list=new l.Autocomplete(e),this.popup.setContent(this.list.container),e.e.on(this.list,"select.autocomplete",(function(o){var n=e.s.current();if(c.Dom.isText(n)&&n.nodeValue){var i=n.nodeValue.split(" ");i[i.length-1]=o.value,n.nodeValue=i.join(" "),e.s.setCursorAfter(n)}else e.s.insertNode(e.createInside.text(o.value),!0);t.popup.close()})).on("keydown.autocomplete",this.onKeyDown).on("keydown.autocomplete",this.onKeyControlDown,void 0,!0).on("autocomplete.autocomplete",this.onAutoComplete).on("registerAutocompleteSource.autocomplete",this.registerAutocompleteSource.bind(this))},t.prototype.registerAutocompleteSource=function(e){this.sources.push(e)},t.isContolKey=function(e){return e===p.KEY_DOWN||e===p.KEY_UP||e===p.KEY_ENTER||e===p.KEY_TAB},t.prototype.onKeyDown=function(e){return n.__awaiter(this,void 0,Promise,(function(){var o,i,r,s;return n.__generator(this,(function(n){switch(n.label){case 0:return t.isContolKey(e.key)||!this.j.s.isCollapsed?[2]:(o=this.j.s.current(),c.Dom.isText(o)&&o.nodeValue?(i=o.nodeValue.split(" "),(r=i.pop())&&u.trim(r).length?[4,this.onAutoComplete(r)]:[3,2]):[3,2]);case 1:if((s=n.sent()).length)return[2,this.openPopup(s)];n.label=2;case 2:return this.popup.isOpened&&this.popup.close(),[2]}}))}))},t.prototype.onKeyControlDown=function(e){if(this.popup.isOpened&&t.isContolKey(e.key)){switch(e.key){case p.KEY_DOWN:this.list.selectNext();break;case p.KEY_UP:this.list.selectPrevious();break;case p.KEY_TAB:case p.KEY_ENTER:this.list.select()}return this.j.e.stopPropagation(e.type),!1}},t.prototype.onAutoComplete=function(e){return n.__awaiter(this,void 0,Promise,(function(){var t,o=this;return n.__generator(this,(function(i){switch(i.label){case 0:return t=[],[4,Promise.all(this.sources.concat(this.j.o.autocomplete.sources).map((function(i){return n.__awaiter(o,void 0,void 0,(function(){var o;return n.__generator(this,(function(n){switch(n.label){case 0:return[4,i(e)];case 1:return(o=n.sent())&&u.isArray(o)&&t.push.apply(t,o),[2]}}))}))})))];case 1:return i.sent(),[2,t]}}))}))},t.prototype.openPopup=function(e){var t=this;this.list.build(e),this.popup.open((function(){return t.j.s.range.getBoundingClientRect()}))},t.prototype.beforeDestruct=function(e){e.e.off(this.list).off("keydown.autocomplete",this.onKeyDown).off("autocomplete.autocomplete",this.onAutoComplete).off(".autocomplete"),this.list.destruct(),this.popup.destruct()},n.__decorate([s.debounce()],t.prototype,"onKeyDown",null),n.__decorate([s.autobind],t.prototype,"onKeyControlDown",null),n.__decorate([s.autobind],t.prototype,"onAutoComplete",null),t}(i.Plugin);t.autocomplete=h,a.Jodit.plugins.add("autocomplete",h)},504:(e,t,o)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.Autocomplete=void 0;var n=o(1);o(505);var i=o(103),r=o(79),s=o(506),u=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.elements=[],t.currentSelection=-1,t}return n.__extends(t,e),t.prototype.className=function(){return"Autocomplete"},t.prototype.onChangeSelection=function(e,t){var o;null!=t&&(null===(o=this.elements[t])||void 0===o||o.setMod("active",!1)),this.elements[this.currentSelection].setMod("active",!0),this.elements[this.currentSelection].container.scrollIntoView(!1)},t.prototype.build=function(e){var t=this;this.clear(),e.forEach((function(e,o){var n=new s.AutocompleteItem(t.jodit,e);t.j.e.on(n.container,"click",(function(){t.currentSelection=o,t.select()})),t.append(n)})),this.currentSelection=0,this.onChangeSelection()},t.prototype.selectNext=function(){this.currentSelection+1>this.elements.length-1?this.currentSelection=0:this.currentSelection+=1},t.prototype.selectPrevious=function(){0>this.currentSelection-1?this.currentSelection=this.elements.length-1:this.currentSelection-=1},t.prototype.select=function(){this.j.e.fire(this,"select.autocomplete",this.elements[this.currentSelection].item)},n.__decorate([i.watch("currentSelection")],t.prototype,"onChangeSelection",null),n.__decorate([i.component],t)}(r.UIGroup);t.Autocomplete=u},506:(e,t,o)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.AutocompleteItem=void 0;var n=o(1);o(505);var i=function(e){function t(t,o){var n,i=e.call(this,t)||this;return i.item=o,i.container.innerText=null!==(n=o.title)&&void 0!==n?n:o.value,i}return n.__extends(t,e),t.prototype.className=function(){return"AutocompleteItem"},t}(o(79).UIElement);t.AutocompleteItem=i}},e=>{"use strict";return e(e.s=503)}])}));
/*!
* jodit-pro - PRO Version of Jodit Editor
* Author: Chupurnov Valeriy <chupurnov@gmail.com>
* Version: v1.0.45
* Version: v1.0.46
* Url: https://xdsoft.net/jodit/pro/

@@ -10,2 +10,2 @@ * License(s): SEE LICENSE IN LICENSE.md

((e,t)=>{if("object"==typeof exports&&"object"==typeof module)module.exports=t();else if("function"==typeof define&&define.amd)define([],t);else{var o=t();for(var s in o)("object"==typeof exports?exports:e)[s]=o[s]}})(self,(function(){return(self.webpackChunkjodit_pro=self.webpackChunkjodit_pro||[]).push([[633],{195(e,t,o){"use strict";o.r(t),o.d(t,{autocomplete:()=>m});var s=o(39),n=o(56),i=o(2),l=o(36),c=o(10),r=o(4),u=o(27);class p extends u.u1{constructor(e,t){var o;super(e),this.item=t,this.container.innerText=null!==(o=t.title)&&void 0!==o?o:t.value}className(){return"AutocompleteItem"}}let a=class extends u.qe{constructor(){super(...arguments),this.elements=[],this.currentSelection=-1}className(){return"Autocomplete"}onChangeSelection(e,t){var o;null!=t&&(null===(o=this.elements[t])||void 0===o||o.setMod("active",!1)),this.elements[this.currentSelection].setMod("active",!0),this.elements[this.currentSelection].container.scrollIntoView(!1)}build(e){this.clear(),e.forEach(((e,t)=>{const o=new p(this.jodit,e);this.j.e.on(o.container,"click",(()=>{this.currentSelection=t,this.select()})),this.append(o)})),this.currentSelection=0,this.onChangeSelection()}selectNext(){this.currentSelection+1>this.elements.length-1?this.currentSelection=0:this.currentSelection+=1}selectPrevious(){0>this.currentSelection-1?this.currentSelection=this.elements.length-1:this.currentSelection-=1}select(){this.j.e.fire(this,"select.autocomplete",this.elements[this.currentSelection].item)}};(0,s.gn)([(0,l.watch)("currentSelection")],a.prototype,"onChangeSelection",null),a=(0,s.gn)([l.component],a);var h=o(3),d=o(1);i.D.prototype.autocomplete={sources:[]};class m extends n.S{constructor(){super(...arguments),this.requires=["enter","license"],this.hasStyle=!d.Jodit.fatMode,this.sources=[]}afterInit(e){this.popup=new r.Popup(e),this.popup.setMod("padding",!1),this.list=new a(e),this.popup.setContent(this.list.container),e.e.on(this.list,"select.autocomplete",(t=>{const o=e.s.current();if(r.Dom.isText(o)&&o.nodeValue){const s=o.nodeValue.split(" ");s[s.length-1]=t.value,o.nodeValue=s.join(" "),e.s.setCursorAfter(o)}else e.s.insertNode(e.createInside.text(t.value),!0);this.popup.close()})).on("keydown.autocomplete",this.onKeyDown).on("keydown.autocomplete",this.onKeyControlDown,void 0,!0).on("autocomplete.autocomplete",this.onAutoComplete).on("registerAutocompleteSource.autocomplete",this.registerAutocompleteSource.bind(this))}registerAutocompleteSource(e){this.sources.push(e)}static isContolKey(e){return e===h.KEY_DOWN||e===h.KEY_UP||e===h.KEY_ENTER||e===h.KEY_TAB}async onKeyDown(e){if(m.isContolKey(e.key)||!this.j.s.isCollapsed)return;const t=this.j.s.current();if(r.Dom.isText(t)&&t.nodeValue){const e=t.nodeValue.split(" ").pop();if(e&&(0,c.trim)(e).length){const t=await this.onAutoComplete(e);if(t.length)return this.openPopup(t)}}this.popup.isOpened&&this.popup.close()}onKeyControlDown(e){if(this.popup.isOpened&&m.isContolKey(e.key)){switch(e.key){case h.KEY_DOWN:this.list.selectNext();break;case h.KEY_UP:this.list.selectPrevious();break;case h.KEY_TAB:case h.KEY_ENTER:this.list.select()}return this.j.e.stopPropagation(e.type),!1}}async onAutoComplete(e){const t=[];return await Promise.all(this.sources.concat(this.j.o.autocomplete.sources).map((async o=>{const s=await o(e);s&&(0,c.isArray)(s)&&t.push(...s)}))),t}openPopup(e){this.list.build(e),this.popup.open((()=>this.j.s.range.getBoundingClientRect()))}beforeDestruct(e){e.e.off(this.list).off("keydown.autocomplete",this.onKeyDown).off("autocomplete.autocomplete",this.onAutoComplete).off(".autocomplete"),this.list.destruct(),this.popup.destruct()}}(0,s.gn)([(0,l.debounce)()],m.prototype,"onKeyDown",null),(0,s.gn)([l.autobind],m.prototype,"onKeyControlDown",null),(0,s.gn)([l.autobind],m.prototype,"onAutoComplete",null),d.Jodit.plugins.add("autocomplete",m)}},e=>{"use strict";e(e.s=195)}])}));
((e,t)=>{if("object"==typeof exports&&"object"==typeof module)module.exports=t();else if("function"==typeof define&&define.amd)define([],t);else{var o=t();for(var s in o)("object"==typeof exports?exports:e)[s]=o[s]}})(self,(function(){return(self.webpackChunkjodit_pro=self.webpackChunkjodit_pro||[]).push([[633],{195(e,t,o){"use strict";o.r(t),o.d(t,{autocomplete:()=>m});var s=o(39),n=o(56),i=o(2),l=o(36),c=o(10),r=o(4),u=o(27);class p extends u.u1{constructor(e,t){var o;super(e),this.item=t,this.container.innerText=null!==(o=t.title)&&void 0!==o?o:t.value}className(){return"AutocompleteItem"}}let a=class extends u.qe{constructor(){super(...arguments),this.elements=[],this.currentSelection=-1}className(){return"Autocomplete"}onChangeSelection(e,t){var o;null!=t&&(null===(o=this.elements[t])||void 0===o||o.setMod("active",!1)),this.elements[this.currentSelection].setMod("active",!0),this.elements[this.currentSelection].container.scrollIntoView(!1)}build(e){this.clear(),e.forEach(((e,t)=>{const o=new p(this.jodit,e);this.j.e.on(o.container,"click",(()=>{this.currentSelection=t,this.select()})),this.append(o)})),this.currentSelection=0,this.onChangeSelection()}selectNext(){this.currentSelection+1>this.elements.length-1?this.currentSelection=0:this.currentSelection+=1}selectPrevious(){0>this.currentSelection-1?this.currentSelection=this.elements.length-1:this.currentSelection-=1}select(){this.j.e.fire(this,"select.autocomplete",this.elements[this.currentSelection].item)}};(0,s.gn)([(0,l.watch)("currentSelection")],a.prototype,"onChangeSelection",null),a=(0,s.gn)([l.component],a);var h=o(3),d=o(1);i.D.prototype.autocomplete={sources:[]};class m extends n.S{constructor(){super(...arguments),this.requires=["enter","license"],this.hasStyle=!d.Jodit.fatMode,this.sources=[]}afterInit(e){this.popup=new r.Popup(e),this.popup.setMod("padding",!1),this.list=new a(e),this.popup.setContent(this.list.container),e.e.on(this.list,"select.autocomplete",(t=>{const o=e.s.current();if(r.Dom.isText(o)&&o.nodeValue){const s=o.nodeValue.split(" ");s[s.length-1]=t.value,o.nodeValue=s.join(" "),e.s.setCursorAfter(o)}else e.s.insertNode(e.createInside.text(t.value),!0);this.popup.close()})).on("keydown.autocomplete",this.onKeyDown).on("keydown.autocomplete",this.onKeyControlDown,void 0,!0).on("autocomplete.autocomplete",this.onAutoComplete).on("registerAutocompleteSource.autocomplete",this.registerAutocompleteSource.bind(this))}registerAutocompleteSource(e){this.sources.push(e)}static isContolKey(e){return e===h.KEY_DOWN||e===h.KEY_UP||e===h.KEY_ENTER||e===h.KEY_TAB}async onKeyDown(e){if(m.isContolKey(e.key)||!this.j.s.isCollapsed)return;const t=this.j.s.current();if(r.Dom.isText(t)&&t.nodeValue){const e=t.nodeValue.split(" ").pop();if(e&&(0,c.trim)(e).length){const t=await this.onAutoComplete(e);if(t.length)return this.openPopup(t)}}this.popup.isOpened&&this.popup.close()}onKeyControlDown(e){if(this.popup.isOpened&&m.isContolKey(e.key)){switch(e.key){case h.KEY_DOWN:this.list.selectNext();break;case h.KEY_UP:this.list.selectPrevious();break;case h.KEY_TAB:case h.KEY_ENTER:this.list.select()}return this.j.e.stopPropagation(e.type),!1}}async onAutoComplete(e){const t=[];return await Promise.all(this.sources.concat(this.j.o.autocomplete.sources).map((async o=>{const s=await o(e);s&&(0,c.isArray)(s)&&t.push(...s)}))),t}openPopup(e){this.list.build(e),this.popup.open((()=>this.j.s.range.getBoundingClientRect()))}beforeDestruct(e){e.e.off(this.list).off("keydown.autocomplete",this.onKeyDown).off("autocomplete.autocomplete",this.onAutoComplete).off(".autocomplete"),this.list.destruct(),this.popup.destruct()}}(0,s.gn)([(0,l.debounce)()],m.prototype,"onKeyDown",null),(0,s.gn)([l.autobind],m.prototype,"onKeyControlDown",null),(0,s.gn)([l.autobind],m.prototype,"onAutoComplete",null),d.Jodit.plugins.add("autocomplete",m)}},e=>{"use strict";return e(e.s=195)}])}));
/*!
* jodit-pro - PRO Version of Jodit Editor
* Author: Chupurnov Valeriy <chupurnov@gmail.com>
* Version: v1.0.45
* Version: v1.0.46
* Url: https://xdsoft.net/jodit/pro/

@@ -10,2 +10,2 @@ * License(s): SEE LICENSE IN LICENSE.md

!function(t,e){if("object"==typeof exports&&"object"==typeof module)module.exports=e();else if("function"==typeof define&&define.amd)define([],e);else{var o=e();for(var n in o)("object"==typeof exports?exports:t)[n]=o[n]}}(self,(function(){return(self.webpackChunkjodit_pro=self.webpackChunkjodit_pro||[]).push([[391],{509:t=>{t.exports='<?xml version="1.0" ?><svg viewBox="0 0 64 64" xmlns="http://www.w3.org/2000/svg"><title/><g id="Upload"><path d="M16,26h8V50a2,2,0,0,0,2,2H38a2,2,0,0,0,2-2V26h8a2,2,0,0,0,1.4946-3.3291l-16-18a2,2,0,0,0-2.9892,0l-16,18A2,2,0,0,0,16,26ZM32,9.0107,43.5464,22H38a2,2,0,0,0-2,2V48H28V24a2,2,0,0,0-2-2H20.4536Z"/><path d="M53,42a2,2,0,0,0-2,2V54a2.0023,2.0023,0,0,1-2,2H15a2.0023,2.0023,0,0,1-2-2V44a2,2,0,0,0-4,0V54a6.0066,6.0066,0,0,0,6,6H49a6.0066,6.0066,0,0,0,6-6V44A2,2,0,0,0,53,42Z"/></g></svg>'},513:(t,e,o)=>{"use strict";o.r(e)},516:(t,e,o)=>{"use strict";o.r(e)},507:(t,e,o)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.backup=void 0;var n=o(1);o(508);var i=o(187),r=o(511),s=o(166),a=o(512),c=o(79),u=o(103),l=o(2),p=function(t){function e(){var e,o=t.apply(this,arguments)||this;return o.requires=["license"],o.hasStyle=!l.Jodit.fatMode,o.buttons=[{name:"backup.restore",group:"history"}],o.box=new a.UIBackupBox(o.j),o.dialog=null,o.storage=null!==(e=o.jodit.o.backup.remoteStore)&&void 0!==e?e:new r.DefaultStorage(o.jodit),o.timeout=0,o}return n.__extends(e,t),e.prototype.afterInit=function(t){var e=this;t.registerCommand("saveBackup",this.onSaveBackup).registerCommand("openBackupDialog",{exec:this.onOpenBackupDialog,hotkeys:t.o.backup.hotkeys});var o=function(){e.timeout=t.async.setTimeout((function(){e.onSaveBackup(),o()}),1e3*t.o.backup.interval)};o(),t.e.on(this.box,"choose",this.onSelectItem).on(t.ow,"beforeunload.backup",(function(){e.onSaveBackup()}))},e.prototype.prepareDialog=function(){this.dialog||(this.dialog=new s.Dialog({minWidth:this.j.o.backup.dialogWidth,buttons:["fullsize","dialog.close"]}).setContent(this.box.container)),this.dialog.setHeader(this.jodit.i18n("Restore")),this.addButtonsToDialog()},e.prototype.onSaveBackup=function(){this.storage.add({created:new Date,html:this.j.value})},e.prototype.onOpenBackupDialog=function(){return n.__awaiter(this,void 0,Promise,(function(){var t,e;return n.__generator(this,(function(o){switch(o.label){case 0:return this.prepareDialog(),(t=this.dialog)?(t.open().setModal(!0),[4,this.storage.items()]):[2];case 1:return e=o.sent(),this.box.build(n.__spreadArray([{created:new Date,html:this.j.value}],e)),t.calcAutoSize(),t.setPosition(),[2]}}))}))},e.prototype.onSelectItem=function(t){var e;null===(e=this.dialog)||void 0===e||e.close(),this.j.value=t.html,this.j.s.focus()},e.prototype.addButtonsToDialog=function(){var t,e=this,o=this.jodit,n=c.Button(o,{name:"ok",tabIndex:0,status:"primary",text:"Ok"}),i=c.Button(o,{status:"secondary",tabIndex:0,text:"Cancel"}),r=c.Button(o,{name:"clear",tabIndex:0,status:"secondary",text:"Remove all"});n.onAction((function(){e.box.chooseSelected()})),i.onAction((function(){var t;null===(t=e.dialog)||void 0===t||t.close()})),r.onAction((function(){s.Confirm("Are you shure?",void 0,(function(t){var o;t&&(e.storage.clear(),null===(o=e.dialog)||void 0===o||o.close())}))}));var a=new c.UIBlock(o,[r,i,n]);a.container.style.margin="0",a.container.style.justifyContent="flex-end",a.container.style.width="100%",null===(t=this.dialog)||void 0===t||t.setFooter(a)},e.prototype.beforeDestruct=function(){var t,e=this.j;e.async.clearTimeout(this.timeout),e.e.off(this.box,"choose",this.onSelectItem).off(e.ow,"beforeunload.backup"),this.box.destruct(),null===(t=this.dialog)||void 0===t||t.destruct()},n.__decorate([u.autobind],e.prototype,"onSaveBackup",null),n.__decorate([u.autobind],e.prototype,"onOpenBackupDialog",null),n.__decorate([u.autobind],e.prototype,"onSelectItem",null),e}(i.Plugin);e.backup=p,l.Jodit.plugins.add("backup",p)},508:(t,e,o)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});var n=o(12),i=o(84),r=o(34);n.Config.prototype.backup={interval:30,limit:50,dialogWidth:700,hotkeys:["ctrl+shift+b","cmd+shift+b"]},n.Config.prototype.controls.backup={store:{command:"saveBackup",text:"Save backup now"},restore:{tooltip:"Restore",list:["backup.store"],exec:function(t){t.execCommand("openBackupDialog")}}},i.Icon.set("restore",o(509)),r.extendLang(o(510))},510:(t,e)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0})},511:(t,e,o)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.DefaultStorage=void 0;var n=o(1),i=function(){function t(t){this.jodit=t,this.key="backup.default.storage"}return t.prototype.add=function(t){return n.__awaiter(this,void 0,Promise,(function(){var e;return n.__generator(this,(function(o){return t.html.trim().length?((e=this.jodit.storage.get(this.key)||[]).find((function(e){return e.html===t.html}))||(e.unshift(t),e.length>this.jodit.o.backup.limit&&(e.length=this.jodit.o.backup.limit),this.jodit.storage.set(this.key,e)),[2,!1]):[2,!1]}))}))},t.prototype.items=function(){return Promise.resolve(this.jodit.storage.get(this.key)||[])},t.prototype.clear=function(){return this.jodit.storage.delete(this.key),Promise.resolve(!1)},t}();e.DefaultStorage=i},512:(t,e,o)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.UIBackupBox=void 0;var n=o(1);o(513);var i=o(103),r=o(79),s=o(514),a=function(t){function e(e){var o=t.call(this,e)||this;return o.list=new s.UIBackupList(o.j),o.preview=o.j.c.div(o.getFullElName("preview")),o.container.appendChild(o.list.container),o.container.appendChild(o.preview),o.list.container.classList.add(o.getFullElName("list")),e.e.on(o.list,"select",o.onSelectItem).on(o.list,"choose",o.onChooseItem),o}return n.__extends(e,t),e.prototype.className=function(){return"UIBackupBox"},e.prototype.build=function(t){this.preview.innerHTML="",this.list.build(t)},e.prototype.destruct=function(){return this.j.e.off(this.list,"select",this.onSelectItem),this.list.destruct(),t.prototype.destruct.call(this)},e.prototype.onSelectItem=function(t){this.latestSelected=t,this.preview.innerHTML=t.html||'<div class="'+this.getFullElName("empty")+'">'+this.j.i18n("Empty")+"</div>"},e.prototype.onChooseItem=function(t){this.j.e.fire(this,"choose",t)},e.prototype.chooseSelected=function(){this.onChooseItem(this.latestSelected)},n.__decorate([i.autobind],e.prototype,"onSelectItem",null),n.__decorate([i.autobind],e.prototype,"onChooseItem",null),n.__decorate([i.component],e)}(r.UIElement);e.UIBackupBox=a},515:(t,e,o)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.UIBackupItem=void 0;var n=o(1);o(516);var i=o(79),r=o(23),s=function(t){function e(e,o){var n=t.call(this,e)||this;return n.data=o,n.container.innerHTML=n.formatDate(o.created),r.attr(n.container,"tabIndex",0),n}return n.__extends(e,t),e.prototype.className=function(){return"UIBackupItem"},e.prototype.formatDate=function(t){var e=new Date,o=r.isString(t)?new Date(t):t,n=(e.getTime()-o.getTime())/1e3;return r.isFunction(this.j.o.backup.formatDate)?this.j.o.backup.formatDate(o):.2>n?this.j.i18n("Current"):60>n?this.j.i18n("Less minute"):n>3600?n>86400?o.toDateString()+" "+o.toLocaleTimeString():this.j.i18n("%s hours ago",Math.floor(n/3600)):this.j.i18n("%s minutes ago",Math.floor(n/60))},e.prototype.focus=function(){this.container.focus()},e}(i.UIElement);e.UIBackupItem=s},514:(t,e,o)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.UIBackupList=void 0;var n=o(1),i=o(79),r=o(103),s=o(515),a=o(13),c=o(23),u=function(t){function e(e){var o=t.call(this,e)||this;return o.elements=[],o.currentSelection=-1,e.e.on(o.container,"keydown",(function(t){switch(t.key){case a.KEY_ENTER:t.preventDefault(),t.stopPropagation(),o.onChoose(o.currentSelection);break;case a.KEY_DOWN:o.selectNext();break;case a.KEY_UP:o.selectPrevious()}})),o}return n.__extends(e,t),e.prototype.className=function(){return"UIBackupList"},e.prototype.createContainer=function(e){var o=t.prototype.createContainer.call(this,e);return c.attr(o,"tabIndex","-1"),o},e.prototype.build=function(t){var e=this;this.clear(),t.forEach((function(t,o){var n=new s.UIBackupItem(e.jodit,t);e.append(n),e.j.e.on(n.container,"focus",(function(){return e.onSelect(o)})).on(n.container,"click",(function(){return e.onSelect(o)})).on(n.container,"dblclick",(function(){return e.onChoose(o)}))})),this.currentSelection=0,this.onChangeCurrentSelection(void 0,-1,0)},e.prototype.onChangeCurrentSelection=function(t,e,o){var n,i,r;null===(n=this.elements[e])||void 0===n||n.setMod("active",!1),null===(i=this.elements[o])||void 0===i||i.setMod("active",!0),null===(r=this.elements[o])||void 0===r||r.focus(),this.j.e.fire(this,"select",this.elements[o].data)},e.prototype.onSelect=function(t){this.currentSelection=t},e.prototype.onChoose=function(t){this.j.e.fire(this,"choose",this.elements[null!=t?t:this.currentSelection].data)},e.prototype.selectNext=function(){this.currentSelection+1>this.elements.length-1?this.currentSelection=0:this.currentSelection+=1},e.prototype.selectPrevious=function(){0>this.currentSelection-1?this.currentSelection=this.elements.length-1:this.currentSelection-=1},n.__decorate([r.watch("currentSelection")],e.prototype,"onChangeCurrentSelection",null),n.__decorate([r.autobind],e.prototype,"onSelect",null),n.__decorate([r.autobind],e.prototype,"onChoose",null),n.__decorate([r.component],e)}(i.UIGroup);e.UIBackupList=u}},t=>{"use strict";t(t.s=507)}])}));
!function(t,e){if("object"==typeof exports&&"object"==typeof module)module.exports=e();else if("function"==typeof define&&define.amd)define([],e);else{var o=e();for(var n in o)("object"==typeof exports?exports:t)[n]=o[n]}}(self,(function(){return(self.webpackChunkjodit_pro=self.webpackChunkjodit_pro||[]).push([[391],{509:t=>{t.exports='<?xml version="1.0" ?><svg viewBox="0 0 64 64" xmlns="http://www.w3.org/2000/svg"><title/><g id="Upload"><path d="M16,26h8V50a2,2,0,0,0,2,2H38a2,2,0,0,0,2-2V26h8a2,2,0,0,0,1.4946-3.3291l-16-18a2,2,0,0,0-2.9892,0l-16,18A2,2,0,0,0,16,26ZM32,9.0107,43.5464,22H38a2,2,0,0,0-2,2V48H28V24a2,2,0,0,0-2-2H20.4536Z"/><path d="M53,42a2,2,0,0,0-2,2V54a2.0023,2.0023,0,0,1-2,2H15a2.0023,2.0023,0,0,1-2-2V44a2,2,0,0,0-4,0V54a6.0066,6.0066,0,0,0,6,6H49a6.0066,6.0066,0,0,0,6-6V44A2,2,0,0,0,53,42Z"/></g></svg>'},513:(t,e,o)=>{"use strict";o.r(e)},516:(t,e,o)=>{"use strict";o.r(e)},507:(t,e,o)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.backup=void 0;var n=o(1);o(508);var i=o(187),r=o(511),s=o(166),a=o(512),c=o(79),u=o(103),l=o(2),p=function(t){function e(){var e,o=t.apply(this,arguments)||this;return o.requires=["license"],o.hasStyle=!l.Jodit.fatMode,o.buttons=[{name:"backup.restore",group:"history"}],o.box=new a.UIBackupBox(o.j),o.dialog=null,o.storage=null!==(e=o.jodit.o.backup.remoteStore)&&void 0!==e?e:new r.DefaultStorage(o.jodit),o.timeout=0,o}return n.__extends(e,t),e.prototype.afterInit=function(t){var e=this;t.registerCommand("saveBackup",this.onSaveBackup).registerCommand("openBackupDialog",{exec:this.onOpenBackupDialog,hotkeys:t.o.backup.hotkeys});var o=function(){e.timeout=t.async.setTimeout((function(){e.onSaveBackup(),o()}),1e3*t.o.backup.interval)};o(),t.e.on(this.box,"choose",this.onSelectItem).on(t.ow,"beforeunload.backup",(function(){e.onSaveBackup()}))},e.prototype.prepareDialog=function(){this.dialog||(this.dialog=new s.Dialog({minWidth:this.j.o.backup.dialogWidth,buttons:["fullsize","dialog.close"]}).setContent(this.box.container)),this.dialog.setHeader(this.jodit.i18n("Restore")),this.addButtonsToDialog()},e.prototype.onSaveBackup=function(){this.storage.add({created:new Date,html:this.j.value})},e.prototype.onOpenBackupDialog=function(){return n.__awaiter(this,void 0,Promise,(function(){var t,e;return n.__generator(this,(function(o){switch(o.label){case 0:return this.prepareDialog(),(t=this.dialog)?(t.open().setModal(!0),[4,this.storage.items()]):[2];case 1:return e=o.sent(),this.box.build(n.__spreadArray([{created:new Date,html:this.j.value}],e)),t.calcAutoSize(),t.setPosition(),[2]}}))}))},e.prototype.onSelectItem=function(t){var e;null===(e=this.dialog)||void 0===e||e.close(),this.j.value=t.html,this.j.s.focus()},e.prototype.addButtonsToDialog=function(){var t,e=this,o=this.jodit,n=c.Button(o,{name:"ok",tabIndex:0,status:"primary",text:"Ok"}),i=c.Button(o,{status:"secondary",tabIndex:0,text:"Cancel"}),r=c.Button(o,{name:"clear",tabIndex:0,status:"secondary",text:"Remove all"});n.onAction((function(){e.box.chooseSelected()})),i.onAction((function(){var t;null===(t=e.dialog)||void 0===t||t.close()})),r.onAction((function(){s.Confirm("Are you shure?",void 0,(function(t){var o;t&&(e.storage.clear(),null===(o=e.dialog)||void 0===o||o.close())}))}));var a=new c.UIBlock(o,[r,i,n]);a.container.style.margin="0",a.container.style.justifyContent="flex-end",a.container.style.width="100%",null===(t=this.dialog)||void 0===t||t.setFooter(a)},e.prototype.beforeDestruct=function(){var t,e=this.j;e.async.clearTimeout(this.timeout),e.e.off(this.box,"choose",this.onSelectItem).off(e.ow,"beforeunload.backup"),this.box.destruct(),null===(t=this.dialog)||void 0===t||t.destruct()},n.__decorate([u.autobind],e.prototype,"onSaveBackup",null),n.__decorate([u.autobind],e.prototype,"onOpenBackupDialog",null),n.__decorate([u.autobind],e.prototype,"onSelectItem",null),e}(i.Plugin);e.backup=p,l.Jodit.plugins.add("backup",p)},508:(t,e,o)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});var n=o(12),i=o(84),r=o(34);n.Config.prototype.backup={interval:30,limit:50,dialogWidth:700,hotkeys:["ctrl+shift+b","cmd+shift+b"]},n.Config.prototype.controls.backup={store:{command:"saveBackup",text:"Save backup now"},restore:{tooltip:"Restore",list:["backup.store"],exec:function(t){t.execCommand("openBackupDialog")}}},i.Icon.set("restore",o(509)),r.extendLang(o(510))},510:(t,e)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0})},511:(t,e,o)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.DefaultStorage=void 0;var n=o(1),i=function(){function t(t){this.jodit=t,this.key="backup.default.storage"}return t.prototype.add=function(t){return n.__awaiter(this,void 0,Promise,(function(){var e;return n.__generator(this,(function(o){return t.html.trim().length?((e=this.jodit.storage.get(this.key)||[]).find((function(e){return e.html===t.html}))||(e.unshift(t),e.length>this.jodit.o.backup.limit&&(e.length=this.jodit.o.backup.limit),this.jodit.storage.set(this.key,e)),[2,!1]):[2,!1]}))}))},t.prototype.items=function(){return Promise.resolve(this.jodit.storage.get(this.key)||[])},t.prototype.clear=function(){return this.jodit.storage.delete(this.key),Promise.resolve(!1)},t}();e.DefaultStorage=i},512:(t,e,o)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.UIBackupBox=void 0;var n=o(1);o(513);var i=o(103),r=o(79),s=o(514),a=function(t){function e(e){var o=t.call(this,e)||this;return o.list=new s.UIBackupList(o.j),o.preview=o.j.c.div(o.getFullElName("preview")),o.container.appendChild(o.list.container),o.container.appendChild(o.preview),o.list.container.classList.add(o.getFullElName("list")),e.e.on(o.list,"select",o.onSelectItem).on(o.list,"choose",o.onChooseItem),o}return n.__extends(e,t),e.prototype.className=function(){return"UIBackupBox"},e.prototype.build=function(t){this.preview.innerHTML="",this.list.build(t)},e.prototype.destruct=function(){return this.j.e.off(this.list,"select",this.onSelectItem),this.list.destruct(),t.prototype.destruct.call(this)},e.prototype.onSelectItem=function(t){this.latestSelected=t,this.preview.innerHTML=t.html||'<div class="'+this.getFullElName("empty")+'">'+this.j.i18n("Empty")+"</div>"},e.prototype.onChooseItem=function(t){this.j.e.fire(this,"choose",t)},e.prototype.chooseSelected=function(){this.onChooseItem(this.latestSelected)},n.__decorate([i.autobind],e.prototype,"onSelectItem",null),n.__decorate([i.autobind],e.prototype,"onChooseItem",null),n.__decorate([i.component],e)}(r.UIElement);e.UIBackupBox=a},515:(t,e,o)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.UIBackupItem=void 0;var n=o(1);o(516);var i=o(79),r=o(23),s=function(t){function e(e,o){var n=t.call(this,e)||this;return n.data=o,n.container.innerHTML=n.formatDate(o.created),r.attr(n.container,"tabIndex",0),n}return n.__extends(e,t),e.prototype.className=function(){return"UIBackupItem"},e.prototype.formatDate=function(t){var e=new Date,o=r.isString(t)?new Date(t):t,n=(e.getTime()-o.getTime())/1e3;return r.isFunction(this.j.o.backup.formatDate)?this.j.o.backup.formatDate(o):.2>n?this.j.i18n("Current"):60>n?this.j.i18n("Less minute"):n>3600?n>86400?o.toDateString()+" "+o.toLocaleTimeString():this.j.i18n("%s hours ago",Math.floor(n/3600)):this.j.i18n("%s minutes ago",Math.floor(n/60))},e.prototype.focus=function(){this.container.focus()},e}(i.UIElement);e.UIBackupItem=s},514:(t,e,o)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.UIBackupList=void 0;var n=o(1),i=o(79),r=o(103),s=o(515),a=o(13),c=o(23),u=function(t){function e(e){var o=t.call(this,e)||this;return o.elements=[],o.currentSelection=-1,e.e.on(o.container,"keydown",(function(t){switch(t.key){case a.KEY_ENTER:t.preventDefault(),t.stopPropagation(),o.onChoose(o.currentSelection);break;case a.KEY_DOWN:o.selectNext();break;case a.KEY_UP:o.selectPrevious()}})),o}return n.__extends(e,t),e.prototype.className=function(){return"UIBackupList"},e.prototype.createContainer=function(e){var o=t.prototype.createContainer.call(this,e);return c.attr(o,"tabIndex","-1"),o},e.prototype.build=function(t){var e=this;this.clear(),t.forEach((function(t,o){var n=new s.UIBackupItem(e.jodit,t);e.append(n),e.j.e.on(n.container,"focus",(function(){return e.onSelect(o)})).on(n.container,"click",(function(){return e.onSelect(o)})).on(n.container,"dblclick",(function(){return e.onChoose(o)}))})),this.currentSelection=0,this.onChangeCurrentSelection(void 0,-1,0)},e.prototype.onChangeCurrentSelection=function(t,e,o){var n,i,r;null===(n=this.elements[e])||void 0===n||n.setMod("active",!1),null===(i=this.elements[o])||void 0===i||i.setMod("active",!0),null===(r=this.elements[o])||void 0===r||r.focus(),this.j.e.fire(this,"select",this.elements[o].data)},e.prototype.onSelect=function(t){this.currentSelection=t},e.prototype.onChoose=function(t){this.j.e.fire(this,"choose",this.elements[null!=t?t:this.currentSelection].data)},e.prototype.selectNext=function(){this.currentSelection+1>this.elements.length-1?this.currentSelection=0:this.currentSelection+=1},e.prototype.selectPrevious=function(){0>this.currentSelection-1?this.currentSelection=this.elements.length-1:this.currentSelection-=1},n.__decorate([r.watch("currentSelection")],e.prototype,"onChangeCurrentSelection",null),n.__decorate([r.autobind],e.prototype,"onSelect",null),n.__decorate([r.autobind],e.prototype,"onChoose",null),n.__decorate([r.component],e)}(i.UIGroup);e.UIBackupList=u}},t=>{"use strict";return t(t.s=507)}])}));
/*!
* jodit-pro - PRO Version of Jodit Editor
* Author: Chupurnov Valeriy <chupurnov@gmail.com>
* Version: v1.0.45
* Version: v1.0.46
* Url: https://xdsoft.net/jodit/pro/

@@ -10,2 +10,2 @@ * License(s): SEE LICENSE IN LICENSE.md

((t,e)=>{if("object"==typeof exports&&"object"==typeof module)module.exports=e();else if("function"==typeof define&&define.amd)define([],e);else{var o=e();for(var s in o)("object"==typeof exports?exports:t)[s]=o[s]}})(self,(function(){return(self.webpackChunkjodit_pro=self.webpackChunkjodit_pro||[]).push([[391],{197(t){t.exports='<?xml version="1.0" ?><svg viewBox="0 0 64 64" xmlns="http://www.w3.org/2000/svg"><title/><g id="Upload"><path d="M16,26h8V50a2,2,0,0,0,2,2H38a2,2,0,0,0,2-2V26h8a2,2,0,0,0,1.4946-3.3291l-16-18a2,2,0,0,0-2.9892,0l-16,18A2,2,0,0,0,16,26ZM32,9.0107,43.5464,22H38a2,2,0,0,0-2,2V48H28V24a2,2,0,0,0-2-2H20.4536Z"/><path d="M53,42a2,2,0,0,0-2,2V54a2.0023,2.0023,0,0,1-2,2H15a2.0023,2.0023,0,0,1-2-2V44a2,2,0,0,0-4,0V54a6.0066,6.0066,0,0,0,6,6H49a6.0066,6.0066,0,0,0,6-6V44A2,2,0,0,0,53,42Z"/></g></svg>'},196(t,e,o){"use strict";o.r(e),o.d(e,{backup:()=>k});var s=o(39),i=o(2),n=o(30),a=o(14);i.D.prototype.backup={interval:30,limit:50,dialogWidth:700,hotkeys:["ctrl+shift+b","cmd+shift+b"]},i.D.prototype.controls.backup={store:{command:"saveBackup",text:"Save backup now"},restore:{tooltip:"Restore",list:["backup.store"],exec(t){t.execCommand("openBackupDialog")}}},n.J.set("restore",o(197)),(0,a.xl)(o(198));var r=o(56);class l{constructor(t){this.jodit=t,this.key="backup.default.storage"}async add(t){if(!t.html.trim().length)return!1;const e=this.jodit.storage.get(this.key)||[];return e.find((e=>e.html===t.html))||(e.unshift(t),e.length>this.jodit.o.backup.limit&&(e.length=this.jodit.o.backup.limit),this.jodit.storage.set(this.key,e)),!1}items(){return Promise.resolve(this.jodit.storage.get(this.key)||[])}clear(){return this.jodit.storage.delete(this.key),Promise.resolve(!1)}}var c=o(47),h=o(36),u=o(27),d=o(10);class p extends u.u1{constructor(t,e){super(t),this.data=e,this.container.innerHTML=this.formatDate(e.created),(0,d.attr)(this.container,"tabIndex",0)}className(){return"UIBackupItem"}formatDate(t){const e=new Date,o=(0,d.isString)(t)?new Date(t):t,s=(e.getTime()-o.getTime())/1e3;return(0,d.isFunction)(this.j.o.backup.formatDate)?this.j.o.backup.formatDate(o):.2>s?this.j.i18n("Current"):60>s?this.j.i18n("Less minute"):s>3600?s>86400?`${o.toDateString()} ${o.toLocaleTimeString()}`:this.j.i18n("%s hours ago",Math.floor(s/3600)):this.j.i18n("%s minutes ago",Math.floor(s/60))}focus(){this.container.focus()}}var m=o(3);let g=class extends u.qe{constructor(t){super(t),this.elements=[],this.currentSelection=-1,t.e.on(this.container,"keydown",(t=>{switch(t.key){case m.KEY_ENTER:t.preventDefault(),t.stopPropagation(),this.onChoose(this.currentSelection);break;case m.KEY_DOWN:this.selectNext();break;case m.KEY_UP:this.selectPrevious()}}))}className(){return"UIBackupList"}createContainer(t){const e=super.createContainer(t);return(0,d.attr)(e,"tabIndex","-1"),e}build(t){this.clear(),t.forEach(((t,e)=>{const o=new p(this.jodit,t);this.append(o),this.j.e.on(o.container,"focus",(()=>this.onSelect(e))).on(o.container,"click",(()=>this.onSelect(e))).on(o.container,"dblclick",(()=>this.onChoose(e)))})),this.currentSelection=0,this.onChangeCurrentSelection(void 0,-1,0)}onChangeCurrentSelection(t,e,o){var s,i,n;null===(s=this.elements[e])||void 0===s||s.setMod("active",!1),null===(i=this.elements[o])||void 0===i||i.setMod("active",!0),null===(n=this.elements[o])||void 0===n||n.focus(),this.j.e.fire(this,"select",this.elements[o].data)}onSelect(t){this.currentSelection=t}onChoose(t){this.j.e.fire(this,"choose",this.elements[null!=t?t:this.currentSelection].data)}selectNext(){this.currentSelection+1>this.elements.length-1?this.currentSelection=0:this.currentSelection+=1}selectPrevious(){0>this.currentSelection-1?this.currentSelection=this.elements.length-1:this.currentSelection-=1}};(0,s.gn)([(0,h.watch)("currentSelection")],g.prototype,"onChangeCurrentSelection",null),(0,s.gn)([h.autobind],g.prototype,"onSelect",null),(0,s.gn)([h.autobind],g.prototype,"onChoose",null),g=(0,s.gn)([h.component],g);let v=class extends u.u1{constructor(t){super(t),this.list=new g(this.j),this.preview=this.j.c.div(this.getFullElName("preview")),this.container.appendChild(this.list.container),this.container.appendChild(this.preview),this.list.container.classList.add(this.getFullElName("list")),t.e.on(this.list,"select",this.onSelectItem).on(this.list,"choose",this.onChooseItem)}className(){return"UIBackupBox"}build(t){this.preview.innerHTML="",this.list.build(t)}destruct(){return this.j.e.off(this.list,"select",this.onSelectItem),this.list.destruct(),super.destruct()}onSelectItem(t){this.latestSelected=t,this.preview.innerHTML=t.html||`<div class="${this.getFullElName("empty")}">${this.j.i18n("Empty")}</div>`}onChooseItem(t){this.j.e.fire(this,"choose",t)}chooseSelected(){this.onChooseItem(this.latestSelected)}};(0,s.gn)([h.autobind],v.prototype,"onSelectItem",null),(0,s.gn)([h.autobind],v.prototype,"onChooseItem",null),v=(0,s.gn)([h.component],v);var b=o(1);class k extends r.S{constructor(){var t;super(...arguments),this.requires=["license"],this.hasStyle=!b.Jodit.fatMode,this.buttons=[{name:"backup.restore",group:"history"}],this.box=new v(this.j),this.dialog=null,this.storage=null!==(t=this.jodit.o.backup.remoteStore)&&void 0!==t?t:new l(this.jodit),this.timeout=0}afterInit(t){t.registerCommand("saveBackup",this.onSaveBackup).registerCommand("openBackupDialog",{exec:this.onOpenBackupDialog,hotkeys:t.o.backup.hotkeys});const e=()=>{this.timeout=t.async.setTimeout((()=>{this.onSaveBackup(),e()}),1e3*t.o.backup.interval)};e(),t.e.on(this.box,"choose",this.onSelectItem).on(t.ow,"beforeunload.backup",(()=>{this.onSaveBackup()}))}prepareDialog(){this.dialog||(this.dialog=new c.Vq({minWidth:this.j.o.backup.dialogWidth,buttons:["fullsize","dialog.close"]}).setContent(this.box.container)),this.dialog.setHeader(this.jodit.i18n("Restore")),this.addButtonsToDialog()}onSaveBackup(){this.storage.add({created:new Date,html:this.j.value})}async onOpenBackupDialog(){this.prepareDialog();const{dialog:t}=this;if(!t)return;t.open().setModal(!0);const e=await this.storage.items();this.box.build([{created:new Date,html:this.j.value},...e]),t.calcAutoSize(),t.setPosition()}onSelectItem(t){var e;null===(e=this.dialog)||void 0===e||e.close(),this.j.value=t.html,this.j.s.focus()}addButtonsToDialog(){var t;const{jodit:e}=this,o=(0,u.zx)(e,{name:"ok",tabIndex:0,status:"primary",text:"Ok"}),s=(0,u.zx)(e,{status:"secondary",tabIndex:0,text:"Cancel"}),i=(0,u.zx)(e,{name:"clear",tabIndex:0,status:"secondary",text:"Remove all"});o.onAction((()=>{this.box.chooseSelected()})),s.onAction((()=>{var t;null===(t=this.dialog)||void 0===t||t.close()})),i.onAction((()=>{(0,c.I4)("Are you shure?",void 0,(t=>{var e;t&&(this.storage.clear(),null===(e=this.dialog)||void 0===e||e.close())}))}));const n=new u.eC(e,[i,s,o]);n.container.style.margin="0",n.container.style.justifyContent="flex-end",n.container.style.width="100%",null===(t=this.dialog)||void 0===t||t.setFooter(n)}beforeDestruct(){var t;const{j:e}=this;e.async.clearTimeout(this.timeout),e.e.off(this.box,"choose",this.onSelectItem).off(e.ow,"beforeunload.backup"),this.box.destruct(),null===(t=this.dialog)||void 0===t||t.destruct()}}(0,s.gn)([h.autobind],k.prototype,"onSaveBackup",null),(0,s.gn)([h.autobind],k.prototype,"onOpenBackupDialog",null),(0,s.gn)([h.autobind],k.prototype,"onSelectItem",null),b.Jodit.plugins.add("backup",k)},198(t,e,o){"use strict";o.r(e)}},t=>{"use strict";t(t.s=196)}])}));
((t,e)=>{if("object"==typeof exports&&"object"==typeof module)module.exports=e();else if("function"==typeof define&&define.amd)define([],e);else{var o=e();for(var s in o)("object"==typeof exports?exports:t)[s]=o[s]}})(self,(function(){return(self.webpackChunkjodit_pro=self.webpackChunkjodit_pro||[]).push([[391],{197(t){t.exports='<?xml version="1.0" ?><svg viewBox="0 0 64 64" xmlns="http://www.w3.org/2000/svg"><title/><g id="Upload"><path d="M16,26h8V50a2,2,0,0,0,2,2H38a2,2,0,0,0,2-2V26h8a2,2,0,0,0,1.4946-3.3291l-16-18a2,2,0,0,0-2.9892,0l-16,18A2,2,0,0,0,16,26ZM32,9.0107,43.5464,22H38a2,2,0,0,0-2,2V48H28V24a2,2,0,0,0-2-2H20.4536Z"/><path d="M53,42a2,2,0,0,0-2,2V54a2.0023,2.0023,0,0,1-2,2H15a2.0023,2.0023,0,0,1-2-2V44a2,2,0,0,0-4,0V54a6.0066,6.0066,0,0,0,6,6H49a6.0066,6.0066,0,0,0,6-6V44A2,2,0,0,0,53,42Z"/></g></svg>'},196(t,e,o){"use strict";o.r(e),o.d(e,{backup:()=>k});var s=o(39),i=o(2),n=o(30),a=o(14);i.D.prototype.backup={interval:30,limit:50,dialogWidth:700,hotkeys:["ctrl+shift+b","cmd+shift+b"]},i.D.prototype.controls.backup={store:{command:"saveBackup",text:"Save backup now"},restore:{tooltip:"Restore",list:["backup.store"],exec(t){t.execCommand("openBackupDialog")}}},n.J.set("restore",o(197)),(0,a.xl)(o(198));var r=o(56);class l{constructor(t){this.jodit=t,this.key="backup.default.storage"}async add(t){if(!t.html.trim().length)return!1;const e=this.jodit.storage.get(this.key)||[];return e.find((e=>e.html===t.html))||(e.unshift(t),e.length>this.jodit.o.backup.limit&&(e.length=this.jodit.o.backup.limit),this.jodit.storage.set(this.key,e)),!1}items(){return Promise.resolve(this.jodit.storage.get(this.key)||[])}clear(){return this.jodit.storage.delete(this.key),Promise.resolve(!1)}}var c=o(47),h=o(36),u=o(27),d=o(10);class p extends u.u1{constructor(t,e){super(t),this.data=e,this.container.innerHTML=this.formatDate(e.created),(0,d.attr)(this.container,"tabIndex",0)}className(){return"UIBackupItem"}formatDate(t){const e=new Date,o=(0,d.isString)(t)?new Date(t):t,s=(e.getTime()-o.getTime())/1e3;return(0,d.isFunction)(this.j.o.backup.formatDate)?this.j.o.backup.formatDate(o):.2>s?this.j.i18n("Current"):60>s?this.j.i18n("Less minute"):s>3600?s>86400?`${o.toDateString()} ${o.toLocaleTimeString()}`:this.j.i18n("%s hours ago",Math.floor(s/3600)):this.j.i18n("%s minutes ago",Math.floor(s/60))}focus(){this.container.focus()}}var m=o(3);let g=class extends u.qe{constructor(t){super(t),this.elements=[],this.currentSelection=-1,t.e.on(this.container,"keydown",(t=>{switch(t.key){case m.KEY_ENTER:t.preventDefault(),t.stopPropagation(),this.onChoose(this.currentSelection);break;case m.KEY_DOWN:this.selectNext();break;case m.KEY_UP:this.selectPrevious()}}))}className(){return"UIBackupList"}createContainer(t){const e=super.createContainer(t);return(0,d.attr)(e,"tabIndex","-1"),e}build(t){this.clear(),t.forEach(((t,e)=>{const o=new p(this.jodit,t);this.append(o),this.j.e.on(o.container,"focus",(()=>this.onSelect(e))).on(o.container,"click",(()=>this.onSelect(e))).on(o.container,"dblclick",(()=>this.onChoose(e)))})),this.currentSelection=0,this.onChangeCurrentSelection(void 0,-1,0)}onChangeCurrentSelection(t,e,o){var s,i,n;null===(s=this.elements[e])||void 0===s||s.setMod("active",!1),null===(i=this.elements[o])||void 0===i||i.setMod("active",!0),null===(n=this.elements[o])||void 0===n||n.focus(),this.j.e.fire(this,"select",this.elements[o].data)}onSelect(t){this.currentSelection=t}onChoose(t){this.j.e.fire(this,"choose",this.elements[null!=t?t:this.currentSelection].data)}selectNext(){this.currentSelection+1>this.elements.length-1?this.currentSelection=0:this.currentSelection+=1}selectPrevious(){0>this.currentSelection-1?this.currentSelection=this.elements.length-1:this.currentSelection-=1}};(0,s.gn)([(0,h.watch)("currentSelection")],g.prototype,"onChangeCurrentSelection",null),(0,s.gn)([h.autobind],g.prototype,"onSelect",null),(0,s.gn)([h.autobind],g.prototype,"onChoose",null),g=(0,s.gn)([h.component],g);let v=class extends u.u1{constructor(t){super(t),this.list=new g(this.j),this.preview=this.j.c.div(this.getFullElName("preview")),this.container.appendChild(this.list.container),this.container.appendChild(this.preview),this.list.container.classList.add(this.getFullElName("list")),t.e.on(this.list,"select",this.onSelectItem).on(this.list,"choose",this.onChooseItem)}className(){return"UIBackupBox"}build(t){this.preview.innerHTML="",this.list.build(t)}destruct(){return this.j.e.off(this.list,"select",this.onSelectItem),this.list.destruct(),super.destruct()}onSelectItem(t){this.latestSelected=t,this.preview.innerHTML=t.html||`<div class="${this.getFullElName("empty")}">${this.j.i18n("Empty")}</div>`}onChooseItem(t){this.j.e.fire(this,"choose",t)}chooseSelected(){this.onChooseItem(this.latestSelected)}};(0,s.gn)([h.autobind],v.prototype,"onSelectItem",null),(0,s.gn)([h.autobind],v.prototype,"onChooseItem",null),v=(0,s.gn)([h.component],v);var b=o(1);class k extends r.S{constructor(){var t;super(...arguments),this.requires=["license"],this.hasStyle=!b.Jodit.fatMode,this.buttons=[{name:"backup.restore",group:"history"}],this.box=new v(this.j),this.dialog=null,this.storage=null!==(t=this.jodit.o.backup.remoteStore)&&void 0!==t?t:new l(this.jodit),this.timeout=0}afterInit(t){t.registerCommand("saveBackup",this.onSaveBackup).registerCommand("openBackupDialog",{exec:this.onOpenBackupDialog,hotkeys:t.o.backup.hotkeys});const e=()=>{this.timeout=t.async.setTimeout((()=>{this.onSaveBackup(),e()}),1e3*t.o.backup.interval)};e(),t.e.on(this.box,"choose",this.onSelectItem).on(t.ow,"beforeunload.backup",(()=>{this.onSaveBackup()}))}prepareDialog(){this.dialog||(this.dialog=new c.Vq({minWidth:this.j.o.backup.dialogWidth,buttons:["fullsize","dialog.close"]}).setContent(this.box.container)),this.dialog.setHeader(this.jodit.i18n("Restore")),this.addButtonsToDialog()}onSaveBackup(){this.storage.add({created:new Date,html:this.j.value})}async onOpenBackupDialog(){this.prepareDialog();const{dialog:t}=this;if(!t)return;t.open().setModal(!0);const e=await this.storage.items();this.box.build([{created:new Date,html:this.j.value},...e]),t.calcAutoSize(),t.setPosition()}onSelectItem(t){var e;null===(e=this.dialog)||void 0===e||e.close(),this.j.value=t.html,this.j.s.focus()}addButtonsToDialog(){var t;const{jodit:e}=this,o=(0,u.zx)(e,{name:"ok",tabIndex:0,status:"primary",text:"Ok"}),s=(0,u.zx)(e,{status:"secondary",tabIndex:0,text:"Cancel"}),i=(0,u.zx)(e,{name:"clear",tabIndex:0,status:"secondary",text:"Remove all"});o.onAction((()=>{this.box.chooseSelected()})),s.onAction((()=>{var t;null===(t=this.dialog)||void 0===t||t.close()})),i.onAction((()=>{(0,c.I4)("Are you shure?",void 0,(t=>{var e;t&&(this.storage.clear(),null===(e=this.dialog)||void 0===e||e.close())}))}));const n=new u.eC(e,[i,s,o]);n.container.style.margin="0",n.container.style.justifyContent="flex-end",n.container.style.width="100%",null===(t=this.dialog)||void 0===t||t.setFooter(n)}beforeDestruct(){var t;const{j:e}=this;e.async.clearTimeout(this.timeout),e.e.off(this.box,"choose",this.onSelectItem).off(e.ow,"beforeunload.backup"),this.box.destruct(),null===(t=this.dialog)||void 0===t||t.destruct()}}(0,s.gn)([h.autobind],k.prototype,"onSaveBackup",null),(0,s.gn)([h.autobind],k.prototype,"onOpenBackupDialog",null),(0,s.gn)([h.autobind],k.prototype,"onSelectItem",null),b.Jodit.plugins.add("backup",k)},198(t,e,o){"use strict";o.r(e)}},t=>{"use strict";return t(t.s=196)}])}));
/*!
* jodit-pro - PRO Version of Jodit Editor
* Author: Chupurnov Valeriy <chupurnov@gmail.com>
* Version: v1.0.45
* Version: v1.0.46
* Url: https://xdsoft.net/jodit/pro/

@@ -10,2 +10,2 @@ * License(s): SEE LICENSE IN LICENSE.md

!function(e,t){if("object"==typeof exports&&"object"==typeof module)module.exports=t();else if("function"==typeof define&&define.amd)define([],t);else{var n=t();for(var a in n)("object"==typeof exports?exports:e)[a]=n[a]}}(self,(function(){return(self.webpackChunkjodit_pro=self.webpackChunkjodit_pro||[]).push([[102],{530:e=>{e.exports='<svg width="19" height="13" viewBox="0 0 19 13" fill="none" xmlns="http://www.w3.org/2000/svg"> <path d="M12.799 11.449V12H7.764V11.449L8.695 11.487C9.075 11.525 9.265 11.373 9.265 11.031C9.265 10.8157 9.20167 10.5687 9.075 10.29L8.144 8.048H3.717L2.843 10.176C2.66567 10.5687 2.577 10.8853 2.577 11.126C2.577 11.392 2.71633 11.5187 2.995 11.506L3.907 11.449V12H0.62V11.449L1.114 11.487H1.19C1.44333 11.487 1.65233 11.3667 1.817 11.126C2.007 10.8473 2.197 10.48 2.387 10.024L6.358 0.466999H6.852L10.861 10.062C11.0383 10.518 11.222 10.879 11.412 11.145C11.5893 11.373 11.811 11.487 12.077 11.487H12.172L12.799 11.449ZM3.945 7.516H7.916L5.921 2.728L3.945 7.516Z" fill="black"/> <path d="M18.45 11.61V12H16.32C16.33 11.93 16.34 11.84 16.35 11.73C16.37 11.61 16.38 11.515 16.38 11.445L16.41 10.86C16.19 11.29 15.905 11.6 15.555 11.79C15.215 11.98 14.805 12.075 14.325 12.075C13.695 12.075 13.215 11.935 12.885 11.655C12.565 11.365 12.405 10.94 12.405 10.38C12.405 9.61 12.725 9.045 13.365 8.685C14.015 8.315 15.03 8.13 16.41 8.13V7.26C16.41 6.79 16.3 6.455 16.08 6.255C15.86 6.055 15.505 5.955 15.015 5.955C14.255 5.955 13.875 6.165 13.875 6.585C13.875 6.665 13.895 6.76 13.935 6.87C13.985 6.97 14.01 7.065 14.01 7.155C14.01 7.325 13.955 7.455 13.845 7.545C13.735 7.625 13.595 7.665 13.425 7.665C13.215 7.665 13.05 7.6 12.93 7.47C12.82 7.34 12.765 7.17 12.765 6.96C12.765 6.54 12.985 6.2 13.425 5.94C13.865 5.68 14.455 5.55 15.195 5.55C16.865 5.55 17.7 6.255 17.7 7.665V11.355C17.7 11.545 17.765 11.64 17.895 11.64L18.45 11.61ZM14.775 11.535C15.215 11.535 15.59 11.355 15.9 10.995C16.21 10.625 16.38 10.15 16.41 9.57V8.535C15.47 8.535 14.795 8.675 14.385 8.955C13.975 9.225 13.77 9.66 13.77 10.26C13.77 10.68 13.855 11 14.025 11.22C14.205 11.43 14.455 11.535 14.775 11.535Z" fill="black"/> </svg>'},528:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.changeCase=void 0;var a=n(1);n(529);var o=n(187),s=n(14),r=n(23),i=n(2),c=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.requires=["license"],t.buttons=[{name:"changeCase",group:"font-style"}],t}return a.__extends(t,e),t.prototype.afterInit=function(e){var t=this;e.registerCommand("changeCase",{exec:function(n,a,o){o=o.toLowerCase();var r=e.s.range,i=r.startContainer,c=r.startOffset;if(e.s.isCollapsed()){var l=e.s.current(!0);l&&l.parentElement&&t.applyCase(o,l.parentElement),r.setStart(i,c),e.s.selectRange(r)}else{var C=r.cloneRange(),p=r.cloneRange(),f=e.createInside.fake(),u=e.createInside.fake();C.collapse(!0),p.collapse(!1),C.insertNode(f),p.insertNode(u),s.Dom.between(f,u,(function(e){t.applyCase(o,e)})),r.setStartAfter(f),r.setEndBefore(u),e.s.selectRange(r),s.Dom.safeRemove(f),s.Dom.safeRemove(u)}}})},t.prototype.applyCase=function(e,t){var n=this;if(s.Dom.isText(t)){var a=t.nodeValue;a&&(t.nodeValue=function(t){switch(e){case"lowercase":return t.toLowerCase();case"uppercase":return t.toUpperCase();default:return t.split(" ").map(r.ucfirst).join(" ")}}(a))}else s.Dom.each(t,(function(t){n.applyCase(e,t)}))},t.prototype.beforeDestruct=function(e){},t}(o.Plugin);t.changeCase=c,i.Jodit.plugins.add("change-case",c)},529:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var a=n(12),o=n(23);a.Config.prototype.controls.changeCase={tooltip:"Change case",icon:n(530),list:["lowercase","UPPERCASE","Title Case"],isDisabled:function(e){return!e.s.current()},exec:function(e,t,n){var a=n.control,s=a.command+"Selected",r=a.args&&a.args[0]||o.dataBind(e,s);if(!r||!a.command)return!1;o.dataBind(e,s,r),e.execCommand(a.command,null,r)},command:"changeCase"}}},e=>{"use strict";e(e.s=528)}])}));
!function(e,t){if("object"==typeof exports&&"object"==typeof module)module.exports=t();else if("function"==typeof define&&define.amd)define([],t);else{var n=t();for(var a in n)("object"==typeof exports?exports:e)[a]=n[a]}}(self,(function(){return(self.webpackChunkjodit_pro=self.webpackChunkjodit_pro||[]).push([[102],{530:e=>{e.exports='<svg width="19" height="13" viewBox="0 0 19 13" fill="none" xmlns="http://www.w3.org/2000/svg"> <path d="M12.799 11.449V12H7.764V11.449L8.695 11.487C9.075 11.525 9.265 11.373 9.265 11.031C9.265 10.8157 9.20167 10.5687 9.075 10.29L8.144 8.048H3.717L2.843 10.176C2.66567 10.5687 2.577 10.8853 2.577 11.126C2.577 11.392 2.71633 11.5187 2.995 11.506L3.907 11.449V12H0.62V11.449L1.114 11.487H1.19C1.44333 11.487 1.65233 11.3667 1.817 11.126C2.007 10.8473 2.197 10.48 2.387 10.024L6.358 0.466999H6.852L10.861 10.062C11.0383 10.518 11.222 10.879 11.412 11.145C11.5893 11.373 11.811 11.487 12.077 11.487H12.172L12.799 11.449ZM3.945 7.516H7.916L5.921 2.728L3.945 7.516Z" fill="black"/> <path d="M18.45 11.61V12H16.32C16.33 11.93 16.34 11.84 16.35 11.73C16.37 11.61 16.38 11.515 16.38 11.445L16.41 10.86C16.19 11.29 15.905 11.6 15.555 11.79C15.215 11.98 14.805 12.075 14.325 12.075C13.695 12.075 13.215 11.935 12.885 11.655C12.565 11.365 12.405 10.94 12.405 10.38C12.405 9.61 12.725 9.045 13.365 8.685C14.015 8.315 15.03 8.13 16.41 8.13V7.26C16.41 6.79 16.3 6.455 16.08 6.255C15.86 6.055 15.505 5.955 15.015 5.955C14.255 5.955 13.875 6.165 13.875 6.585C13.875 6.665 13.895 6.76 13.935 6.87C13.985 6.97 14.01 7.065 14.01 7.155C14.01 7.325 13.955 7.455 13.845 7.545C13.735 7.625 13.595 7.665 13.425 7.665C13.215 7.665 13.05 7.6 12.93 7.47C12.82 7.34 12.765 7.17 12.765 6.96C12.765 6.54 12.985 6.2 13.425 5.94C13.865 5.68 14.455 5.55 15.195 5.55C16.865 5.55 17.7 6.255 17.7 7.665V11.355C17.7 11.545 17.765 11.64 17.895 11.64L18.45 11.61ZM14.775 11.535C15.215 11.535 15.59 11.355 15.9 10.995C16.21 10.625 16.38 10.15 16.41 9.57V8.535C15.47 8.535 14.795 8.675 14.385 8.955C13.975 9.225 13.77 9.66 13.77 10.26C13.77 10.68 13.855 11 14.025 11.22C14.205 11.43 14.455 11.535 14.775 11.535Z" fill="black"/> </svg>'},528:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.changeCase=void 0;var a=n(1);n(529);var o=n(187),s=n(14),r=n(23),i=n(2),c=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.requires=["license"],t.buttons=[{name:"changeCase",group:"font-style"}],t}return a.__extends(t,e),t.prototype.afterInit=function(e){var t=this;e.registerCommand("changeCase",{exec:function(n,a,o){o=o.toLowerCase();var r=e.s.range,i=r.startContainer,c=r.startOffset;if(e.s.isCollapsed()){var l=e.s.current(!0);l&&l.parentElement&&t.applyCase(o,l.parentElement),r.setStart(i,c),e.s.selectRange(r)}else{var C=r.cloneRange(),p=r.cloneRange(),u=e.createInside.fake(),f=e.createInside.fake();C.collapse(!0),p.collapse(!1),C.insertNode(u),p.insertNode(f),s.Dom.between(u,f,(function(e){t.applyCase(o,e)})),r.setStartAfter(u),r.setEndBefore(f),e.s.selectRange(r),s.Dom.safeRemove(u),s.Dom.safeRemove(f)}}})},t.prototype.applyCase=function(e,t){var n=this;if(s.Dom.isText(t)){var a=t.nodeValue;a&&(t.nodeValue=function(t){switch(e){case"lowercase":return t.toLowerCase();case"uppercase":return t.toUpperCase();default:return t.split(" ").map(r.ucfirst).join(" ")}}(a))}else s.Dom.each(t,(function(t){n.applyCase(e,t)}))},t.prototype.beforeDestruct=function(e){},t}(o.Plugin);t.changeCase=c,i.Jodit.plugins.add("change-case",c)},529:(e,t,n)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var a=n(12),o=n(23);a.Config.prototype.controls.changeCase={tooltip:"Change case",icon:n(530),list:["lowercase","UPPERCASE","Title Case"],isDisabled:function(e){return!e.s.current()},exec:function(e,t,n){var a=n.control,s=a.command+"Selected",r=a.args&&a.args[0]||o.dataBind(e,s);if(!r||!a.command)return!1;o.dataBind(e,s,r),e.execCommand(a.command,null,r)},command:"changeCase"}}},e=>{"use strict";return e(e.s=528)}])}));
/*!
* jodit-pro - PRO Version of Jodit Editor
* Author: Chupurnov Valeriy <chupurnov@gmail.com>
* Version: v1.0.45
* Version: v1.0.46
* Url: https://xdsoft.net/jodit/pro/

@@ -10,2 +10,2 @@ * License(s): SEE LICENSE IN LICENSE.md

((e,t)=>{if("object"==typeof exports&&"object"==typeof module)module.exports=t();else if("function"==typeof define&&define.amd)define([],t);else{var s=t();for(var a in s)("object"==typeof exports?exports:e)[a]=s[a]}})(self,(function(){return(self.webpackChunkjodit_pro=self.webpackChunkjodit_pro||[]).push([[102],{208(e){e.exports='<svg width="19" height="13" viewBox="0 0 19 13" fill="none" xmlns="http://www.w3.org/2000/svg"> <path d="M12.799 11.449V12H7.764V11.449L8.695 11.487C9.075 11.525 9.265 11.373 9.265 11.031C9.265 10.8157 9.20167 10.5687 9.075 10.29L8.144 8.048H3.717L2.843 10.176C2.66567 10.5687 2.577 10.8853 2.577 11.126C2.577 11.392 2.71633 11.5187 2.995 11.506L3.907 11.449V12H0.62V11.449L1.114 11.487H1.19C1.44333 11.487 1.65233 11.3667 1.817 11.126C2.007 10.8473 2.197 10.48 2.387 10.024L6.358 0.466999H6.852L10.861 10.062C11.0383 10.518 11.222 10.879 11.412 11.145C11.5893 11.373 11.811 11.487 12.077 11.487H12.172L12.799 11.449ZM3.945 7.516H7.916L5.921 2.728L3.945 7.516Z" fill="black"/> <path d="M18.45 11.61V12H16.32C16.33 11.93 16.34 11.84 16.35 11.73C16.37 11.61 16.38 11.515 16.38 11.445L16.41 10.86C16.19 11.29 15.905 11.6 15.555 11.79C15.215 11.98 14.805 12.075 14.325 12.075C13.695 12.075 13.215 11.935 12.885 11.655C12.565 11.365 12.405 10.94 12.405 10.38C12.405 9.61 12.725 9.045 13.365 8.685C14.015 8.315 15.03 8.13 16.41 8.13V7.26C16.41 6.79 16.3 6.455 16.08 6.255C15.86 6.055 15.505 5.955 15.015 5.955C14.255 5.955 13.875 6.165 13.875 6.585C13.875 6.665 13.895 6.76 13.935 6.87C13.985 6.97 14.01 7.065 14.01 7.155C14.01 7.325 13.955 7.455 13.845 7.545C13.735 7.625 13.595 7.665 13.425 7.665C13.215 7.665 13.05 7.6 12.93 7.47C12.82 7.34 12.765 7.17 12.765 6.96C12.765 6.54 12.985 6.2 13.425 5.94C13.865 5.68 14.455 5.55 15.195 5.55C16.865 5.55 17.7 6.255 17.7 7.665V11.355C17.7 11.545 17.765 11.64 17.895 11.64L18.45 11.61ZM14.775 11.535C15.215 11.535 15.59 11.355 15.9 10.995C16.21 10.625 16.38 10.15 16.41 9.57V8.535C15.47 8.535 14.795 8.675 14.385 8.955C13.975 9.225 13.77 9.66 13.77 10.26C13.77 10.68 13.855 11 14.025 11.22C14.205 11.43 14.455 11.535 14.775 11.535Z" fill="black"/> </svg>'},207(e,t,s){"use strict";s.r(t),s.d(t,{changeCase:()=>C});var a=s(2),o=s(10);a.D.prototype.controls.changeCase={tooltip:"Change case",icon:s(208),list:["lowercase","UPPERCASE","Title Case"],isDisabled(e){return!e.s.current()},exec(e,t,{control:s}){const a=s.command+"Selected",n=s.args&&s.args[0]||(0,o.dataBind)(e,a);if(!n||!s.command)return!1;(0,o.dataBind)(e,a,n),e.execCommand(s.command,null,n)},command:"changeCase"};var n=s(56),r=s(4),c=s(1);class C extends n.S{constructor(){super(...arguments),this.requires=["license"],this.buttons=[{name:"changeCase",group:"font-style"}]}afterInit(e){e.registerCommand("changeCase",{exec:(t,s,a)=>{a=a.toLowerCase();const o=e.s.range,{startContainer:n,startOffset:c}=o;if(e.s.isCollapsed()){const t=e.s.current(!0);t&&t.parentElement&&this.applyCase(a,t.parentElement),o.setStart(n,c),e.s.selectRange(o)}else{const t=o.cloneRange(),s=o.cloneRange(),n=e.createInside.fake(),c=e.createInside.fake();t.collapse(!0),s.collapse(!1),t.insertNode(n),s.insertNode(c),r.Dom.between(n,c,(e=>{this.applyCase(a,e)})),o.setStartAfter(n),o.setEndBefore(c),e.s.selectRange(o),r.Dom.safeRemove(n),r.Dom.safeRemove(c)}}})}applyCase(e,t){if(r.Dom.isText(t)){const s=t.nodeValue;s&&(t.nodeValue=(t=>{switch(e){case"lowercase":return t.toLowerCase();case"uppercase":return t.toUpperCase();default:return t.split(" ").map(o.ucfirst).join(" ")}})(s))}else r.Dom.each(t,(t=>{this.applyCase(e,t)}))}beforeDestruct(e){}}c.Jodit.plugins.add("change-case",C)}},e=>{"use strict";e(e.s=207)}])}));
((e,t)=>{if("object"==typeof exports&&"object"==typeof module)module.exports=t();else if("function"==typeof define&&define.amd)define([],t);else{var s=t();for(var a in s)("object"==typeof exports?exports:e)[a]=s[a]}})(self,(function(){return(self.webpackChunkjodit_pro=self.webpackChunkjodit_pro||[]).push([[102],{208(e){e.exports='<svg width="19" height="13" viewBox="0 0 19 13" fill="none" xmlns="http://www.w3.org/2000/svg"> <path d="M12.799 11.449V12H7.764V11.449L8.695 11.487C9.075 11.525 9.265 11.373 9.265 11.031C9.265 10.8157 9.20167 10.5687 9.075 10.29L8.144 8.048H3.717L2.843 10.176C2.66567 10.5687 2.577 10.8853 2.577 11.126C2.577 11.392 2.71633 11.5187 2.995 11.506L3.907 11.449V12H0.62V11.449L1.114 11.487H1.19C1.44333 11.487 1.65233 11.3667 1.817 11.126C2.007 10.8473 2.197 10.48 2.387 10.024L6.358 0.466999H6.852L10.861 10.062C11.0383 10.518 11.222 10.879 11.412 11.145C11.5893 11.373 11.811 11.487 12.077 11.487H12.172L12.799 11.449ZM3.945 7.516H7.916L5.921 2.728L3.945 7.516Z" fill="black"/> <path d="M18.45 11.61V12H16.32C16.33 11.93 16.34 11.84 16.35 11.73C16.37 11.61 16.38 11.515 16.38 11.445L16.41 10.86C16.19 11.29 15.905 11.6 15.555 11.79C15.215 11.98 14.805 12.075 14.325 12.075C13.695 12.075 13.215 11.935 12.885 11.655C12.565 11.365 12.405 10.94 12.405 10.38C12.405 9.61 12.725 9.045 13.365 8.685C14.015 8.315 15.03 8.13 16.41 8.13V7.26C16.41 6.79 16.3 6.455 16.08 6.255C15.86 6.055 15.505 5.955 15.015 5.955C14.255 5.955 13.875 6.165 13.875 6.585C13.875 6.665 13.895 6.76 13.935 6.87C13.985 6.97 14.01 7.065 14.01 7.155C14.01 7.325 13.955 7.455 13.845 7.545C13.735 7.625 13.595 7.665 13.425 7.665C13.215 7.665 13.05 7.6 12.93 7.47C12.82 7.34 12.765 7.17 12.765 6.96C12.765 6.54 12.985 6.2 13.425 5.94C13.865 5.68 14.455 5.55 15.195 5.55C16.865 5.55 17.7 6.255 17.7 7.665V11.355C17.7 11.545 17.765 11.64 17.895 11.64L18.45 11.61ZM14.775 11.535C15.215 11.535 15.59 11.355 15.9 10.995C16.21 10.625 16.38 10.15 16.41 9.57V8.535C15.47 8.535 14.795 8.675 14.385 8.955C13.975 9.225 13.77 9.66 13.77 10.26C13.77 10.68 13.855 11 14.025 11.22C14.205 11.43 14.455 11.535 14.775 11.535Z" fill="black"/> </svg>'},207(e,t,s){"use strict";s.r(t),s.d(t,{changeCase:()=>C});var a=s(2),o=s(10);a.D.prototype.controls.changeCase={tooltip:"Change case",icon:s(208),list:["lowercase","UPPERCASE","Title Case"],isDisabled(e){return!e.s.current()},exec(e,t,{control:s}){const a=s.command+"Selected",n=s.args&&s.args[0]||(0,o.dataBind)(e,a);if(!n||!s.command)return!1;(0,o.dataBind)(e,a,n),e.execCommand(s.command,null,n)},command:"changeCase"};var n=s(56),r=s(4),c=s(1);class C extends n.S{constructor(){super(...arguments),this.requires=["license"],this.buttons=[{name:"changeCase",group:"font-style"}]}afterInit(e){e.registerCommand("changeCase",{exec:(t,s,a)=>{a=a.toLowerCase();const o=e.s.range,{startContainer:n,startOffset:c}=o;if(e.s.isCollapsed()){const t=e.s.current(!0);t&&t.parentElement&&this.applyCase(a,t.parentElement),o.setStart(n,c),e.s.selectRange(o)}else{const t=o.cloneRange(),s=o.cloneRange(),n=e.createInside.fake(),c=e.createInside.fake();t.collapse(!0),s.collapse(!1),t.insertNode(n),s.insertNode(c),r.Dom.between(n,c,(e=>{this.applyCase(a,e)})),o.setStartAfter(n),o.setEndBefore(c),e.s.selectRange(o),r.Dom.safeRemove(n),r.Dom.safeRemove(c)}}})}applyCase(e,t){if(r.Dom.isText(t)){const s=t.nodeValue;s&&(t.nodeValue=(t=>{switch(e){case"lowercase":return t.toLowerCase();case"uppercase":return t.toUpperCase();default:return t.split(" ").map(o.ucfirst).join(" ")}})(s))}else r.Dom.each(t,(t=>{this.applyCase(e,t)}))}beforeDestruct(e){}}c.Jodit.plugins.add("change-case",C)}},e=>{"use strict";return e(e.s=207)}])}));
/*!
* jodit-pro - PRO Version of Jodit Editor
* Author: Chupurnov Valeriy <chupurnov@gmail.com>
* Version: v1.0.45
* Version: v1.0.46
* Url: https://xdsoft.net/jodit/pro/

@@ -10,2 +10,2 @@ * License(s): SEE LICENSE IN LICENSE.md

!function(e,t){if("object"==typeof exports&&"object"==typeof module)module.exports=t();else if("function"==typeof define&&define.amd)define([],t);else{var r=t();for(var i in r)("object"==typeof exports?exports:e)[i]=r[i]}}(self,(function(){return(self.webpackChunkjodit_pro=self.webpackChunkjodit_pro||[]).push([[652],{525:function(e){"undefined"!=typeof self&&self,e.exports=function(e){var t={};function r(i){if(t[i])return t[i].exports;var o=t[i]={i:i,l:!1,exports:{}};return e[i].call(o.exports,o,o.exports,r),o.l=!0,o.exports}return r.m=e,r.c=t,r.d=function(e,t,i){r.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:i})},r.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},r.t=function(e,t){if(1&t&&(e=r(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var i=Object.create(null);if(r.r(i),Object.defineProperty(i,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var o in e)r.d(i,o,function(t){return e[t]}.bind(null,o));return i},r.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return r.d(t,"a",t),t},r.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},r.p="",r(r.s=1)}([function(e,t,r){"use strict";var i=r(3);function o(e){return!0===i(e)&&"[object Object]"===Object.prototype.toString.call(e)}e.exports=function(e){var t,r;return!1!==o(e)&&"function"==typeof(t=e.constructor)&&!1!==o(r=t.prototype)&&!1!==r.hasOwnProperty("isPrototypeOf")}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.VERSION=t.PALETTE_MATERIAL_CHROME=t.PALETTE_MATERIAL_500=t.COLOR_NAMES=t.getLuminance=t.intToRgb=t.rgbToInt=t.rgbToHsv=t.rgbToHsl=t.hslToRgb=t.rgbToHex=t.parseColor=t.parseColorToHsla=t.parseColorToHsl=t.parseColorToRgba=t.parseColorToRgb=t.from=t.createPicker=void 0;var i=function(){function e(e,t){for(var r=0;t.length>r;r++){var i=t[r];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,i.key,i)}}return function(t,r,i){return r&&e(t.prototype,r),i&&e(t,i),t}}(),o=function(e,t){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return function(e,t){var r=[],i=!0,o=!1,n=void 0;try{for(var a,s=e[Symbol.iterator]();!(i=(a=s.next()).done)&&(r.push(a.value),!t||r.length!==t);i=!0);}catch(e){o=!0,n=e}finally{try{!i&&s.return&&s.return()}finally{if(o)throw n}}return r}(e,t);throw new TypeError("Invalid attempt to destructure non-iterable instance")},n=r(2),a=l(r(0)),s=l(r(4));function l(e){return e&&e.__esModule?e:{default:e}}function c(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function u(e){if(Array.isArray(e)){for(var t=0,r=Array(e.length);e.length>t;t++)r[t]=e[t];return r}return Array.from(e)}var h="undefined"!=typeof window&&window.navigator.userAgent.indexOf("Edge")>-1,p="undefined"!=typeof window&&window.navigator.userAgent.indexOf("rv:")>-1,d={id:null,attachTo:"body",showHSL:!0,showRGB:!0,showHEX:!0,showAlpha:!1,color:"#ff0000",palette:null,paletteEditable:!1,useAlphaInPalette:"auto",slBarSize:[232,150],hueBarSize:[150,11],alphaBarSize:[150,11]},f="COLOR",g="RGBA_USER",b="HSLA_USER";function v(e,t,r){return e?e instanceof HTMLElement?e:e instanceof NodeList?e[0]:"string"==typeof e?document.querySelector(e):e.jquery?e.get(0):r?t:null:t}function m(e){var t=e.getContext("2d"),r=+e.width,i=+e.height,a=t.createLinearGradient(1,1,1,i-1);return a.addColorStop(0,"white"),a.addColorStop(1,"black"),{setHue:function(e){var o=t.createLinearGradient(1,0,r-1,0);o.addColorStop(0,"hsla("+e+", 100%, 50%, 0)"),o.addColorStop(1,"hsla("+e+", 100%, 50%, 1)"),t.fillStyle=a,t.fillRect(0,0,r,i),t.fillStyle=o,t.globalCompositeOperation="multiply",t.fillRect(0,0,r,i),t.globalCompositeOperation="source-over"},grabColor:function(e,r){return t.getImageData(e,r,1,1).data},findColor:function(e,t,a){var s=(0,n.rgbToHsv)(e,t,a),l=o(s,3);return[l[1]*r,i-l[2]*i]}}}function y(e,t,r){return null===e?t:/^\s*$/.test(e)?r:!!/true|yes|1/i.test(e)||!/false|no|0/i.test(e)&&t}function A(e,t,r){if(null===e)return t;if(/^\s*$/.test(e))return r;var i=e.split(",").map(Number);return 2===i.length&&i[0]&&i[1]?i:t}var k=function(){function e(t,r){if(c(this,e),r?(t=v(t),this.options=Object.assign({},d,r)):t&&(0,a.default)(t)?(this.options=Object.assign({},d,t),t=v(this.options.attachTo)):(this.options=Object.assign({},d),t=v((0,n.nvl)(t,this.options.attachTo))),!t)throw new Error("Container not found: "+this.options.attachTo);!function(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"acp-";if(t.hasAttribute(r+"show-hsl")&&(e.showHSL=y(t.getAttribute(r+"show-hsl"),d.showHSL,!0)),t.hasAttribute(r+"show-rgb")&&(e.showRGB=y(t.getAttribute(r+"show-rgb"),d.showRGB,!0)),t.hasAttribute(r+"show-hex")&&(e.showHEX=y(t.getAttribute(r+"show-hex"),d.showHEX,!0)),t.hasAttribute(r+"show-alpha")&&(e.showAlpha=y(t.getAttribute(r+"show-alpha"),d.showAlpha,!0)),t.hasAttribute(r+"palette-editable")&&(e.paletteEditable=y(t.getAttribute(r+"palette-editable"),d.paletteEditable,!0)),t.hasAttribute(r+"sl-bar-size")&&(e.slBarSize=A(t.getAttribute(r+"sl-bar-size"),d.slBarSize,[232,150])),t.hasAttribute(r+"hue-bar-size")&&(e.hueBarSize=A(t.getAttribute(r+"hue-bar-size"),d.hueBarSize,[150,11]),e.alphaBarSize=e.hueBarSize),t.hasAttribute(r+"palette")){var i=t.getAttribute(r+"palette");switch(i){case"PALETTE_MATERIAL_500":e.palette=n.PALETTE_MATERIAL_500;break;case"PALETTE_MATERIAL_CHROME":case"":e.palette=n.PALETTE_MATERIAL_CHROME;break;default:e.palette=i.split(/[;|]/)}}t.hasAttribute(r+"color")&&(e.color=t.getAttribute(r+"color"))}(this.options,t),this.H=0,this.S=0,this.L=0,this.R=0,this.G=0,this.B=0,this.A=1,this.palette={},this.element=document.createElement("div"),this.options.id&&(this.element.id=this.options.id),this.element.className="a-color-picker",this.element.innerHTML=s.default,t.appendChild(this.element);var i=this.element.querySelector(".a-color-picker-h");this.setupHueCanvas(i),this.hueBarHelper=m(i),this.huePointer=this.element.querySelector(".a-color-picker-h+.a-color-picker-dot");var o=this.element.querySelector(".a-color-picker-sl");this.setupSlCanvas(o),this.slBarHelper=m(o),this.slPointer=this.element.querySelector(".a-color-picker-sl+.a-color-picker-dot"),this.preview=this.element.querySelector(".a-color-picker-preview"),this.setupClipboard(this.preview.querySelector(".a-color-picker-clipbaord")),this.options.showHSL?(this.setupInput(this.inputH=this.element.querySelector(".a-color-picker-hsl>input[nameref=H]")),this.setupInput(this.inputS=this.element.querySelector(".a-color-picker-hsl>input[nameref=S]")),this.setupInput(this.inputL=this.element.querySelector(".a-color-picker-hsl>input[nameref=L]"))):this.element.querySelector(".a-color-picker-hsl").remove(),this.options.showRGB?(this.setupInput(this.inputR=this.element.querySelector(".a-color-picker-rgb>input[nameref=R]")),this.setupInput(this.inputG=this.element.querySelector(".a-color-picker-rgb>input[nameref=G]")),this.setupInput(this.inputB=this.element.querySelector(".a-color-picker-rgb>input[nameref=B]"))):this.element.querySelector(".a-color-picker-rgb").remove(),this.options.showHEX?this.setupInput(this.inputRGBHEX=this.element.querySelector("input[nameref=RGBHEX]")):this.element.querySelector(".a-color-picker-rgbhex").remove(),this.options.paletteEditable||this.options.palette&&this.options.palette.length>0?this.setPalette(this.paletteRow=this.element.querySelector(".a-color-picker-palette")):(this.paletteRow=this.element.querySelector(".a-color-picker-palette"),this.paletteRow.remove()),this.options.showAlpha?(this.setupAlphaCanvas(this.element.querySelector(".a-color-picker-a")),this.alphaPointer=this.element.querySelector(".a-color-picker-a+.a-color-picker-dot")):this.element.querySelector(".a-color-picker-alpha").remove(),this.element.style.width=this.options.slBarSize[0]+"px",this.onValueChanged(f,this.options.color)}return i(e,[{key:"setupHueCanvas",value:function(e){var t=this;e.width=this.options.hueBarSize[0],e.height=this.options.hueBarSize[1];for(var r=e.getContext("2d"),i=r.createLinearGradient(0,0,this.options.hueBarSize[0],0),o=0;1>=o;o+=1/360)i.addColorStop(o,"hsl("+360*o+", 100%, 50%)");r.fillStyle=i,r.fillRect(0,0,this.options.hueBarSize[0],this.options.hueBarSize[1]);var a=function(r){var i=(0,n.limit)(r.clientX-e.getBoundingClientRect().left,0,t.options.hueBarSize[0]),o=Math.round(360*i/t.options.hueBarSize[0]);t.huePointer.style.left=i-7+"px",t.onValueChanged("H",o)},s=function e(){document.removeEventListener("mousemove",a),document.removeEventListener("mouseup",e)};e.addEventListener("mousedown",(function(e){a(e),document.addEventListener("mousemove",a),document.addEventListener("mouseup",s)}))}},{key:"setupSlCanvas",value:function(e){var t=this;e.width=this.options.slBarSize[0],e.height=this.options.slBarSize[1];var r=function(r){var i=(0,n.limit)(r.clientX-e.getBoundingClientRect().left,0,t.options.slBarSize[0]-1),o=(0,n.limit)(r.clientY-e.getBoundingClientRect().top,0,t.options.slBarSize[1]-1),a=t.slBarHelper.grabColor(i,o);t.slPointer.style.left=i-7+"px",t.slPointer.style.top=o-7+"px",t.onValueChanged("RGB",a)},i=function e(){document.removeEventListener("mousemove",r),document.removeEventListener("mouseup",e)};e.addEventListener("mousedown",(function(e){r(e),document.addEventListener("mousemove",r),document.addEventListener("mouseup",i)}))}},{key:"setupAlphaCanvas",value:function(e){var t=this;e.width=this.options.alphaBarSize[0],e.height=this.options.alphaBarSize[1];var r=e.getContext("2d"),i=r.createLinearGradient(0,0,e.width-1,0);i.addColorStop(0,"hsla(0, 0%, 50%, 0)"),i.addColorStop(1,"hsla(0, 0%, 50%, 1)"),r.fillStyle=i,r.fillRect(0,0,this.options.alphaBarSize[0],this.options.alphaBarSize[1]);var o=function(r){var i=(0,n.limit)(r.clientX-e.getBoundingClientRect().left,0,t.options.alphaBarSize[0]),o=+(i/t.options.alphaBarSize[0]).toFixed(2);t.alphaPointer.style.left=i-7+"px",t.onValueChanged("ALPHA",o)},a=function e(){document.removeEventListener("mousemove",o),document.removeEventListener("mouseup",e)};e.addEventListener("mousedown",(function(e){o(e),document.addEventListener("mousemove",o),document.addEventListener("mouseup",a)}))}},{key:"setupInput",value:function(e){var t=this,r=+e.min,i=+e.max,o=e.getAttribute("nameref");e.hasAttribute("select-on-focus")&&e.addEventListener("focus",(function(){e.select()})),"text"===e.type?e.addEventListener("change",(function(){t.onValueChanged(o,e.value)})):((h||p)&&e.addEventListener("keydown",(function(a){"Up"===a.key?(e.value=(0,n.limit)(+e.value+1,r,i),t.onValueChanged(o,e.value),a.returnValue=!1):"Down"===a.key&&(e.value=(0,n.limit)(+e.value-1,r,i),t.onValueChanged(o,e.value),a.returnValue=!1)})),e.addEventListener("change",(function(){t.onValueChanged(o,(0,n.limit)(+e.value,r,i))})))}},{key:"setupClipboard",value:function(e){var t=this;e.title="click to copy",e.addEventListener("click",(function(){e.value=(0,n.parseColor)([t.R,t.G,t.B,t.A],"hexcss4"),e.select(),document.execCommand("copy")}))}},{key:"setPalette",value:function(e){var t=this,r="auto"===this.options.useAlphaInPalette?this.options.showAlpha:this.options.useAlphaInPalette,i=null;switch(this.options.palette){case"PALETTE_MATERIAL_500":i=n.PALETTE_MATERIAL_500;break;case"PALETTE_MATERIAL_CHROME":i=n.PALETTE_MATERIAL_CHROME;break;default:i=(0,n.ensureArray)(this.options.palette)}if(this.options.paletteEditable||i.length>0){var o=function(r,i,o){var n=e.querySelector('.a-color-picker-palette-color[data-color="'+r+'"]')||document.createElement("div");n.className="a-color-picker-palette-color",n.style.backgroundColor=r,n.setAttribute("data-color",r),n.title=r,e.insertBefore(n,i),t.palette[r]=!0,o&&t.onPaletteColorAdd(r)},a=function(r,i){r?(e.removeChild(r),t.palette[r.getAttribute("data-color")]=!1,i&&t.onPaletteColorRemove(r.getAttribute("data-color"))):(e.querySelectorAll(".a-color-picker-palette-color[data-color]").forEach((function(t){e.removeChild(t)})),Object.keys(t.palette).forEach((function(e){t.palette[e]=!1})),i&&t.onPaletteColorRemove())};if(i.map((function(e){return(0,n.parseColor)(e,r?"rgbcss4":"hex")})).filter((function(e){return!!e})).forEach((function(e){return o(e)})),this.options.paletteEditable){var s=document.createElement("div");s.className="a-color-picker-palette-color a-color-picker-palette-add",s.innerHTML="+",e.appendChild(s),e.addEventListener("click",(function(e){/a-color-picker-palette-add/.test(e.target.className)?e.shiftKey?a(null,!0):o(r?(0,n.parseColor)([t.R,t.G,t.B,t.A],"rgbcss4"):(0,n.rgbToHex)(t.R,t.G,t.B),e.target,!0):/a-color-picker-palette-color/.test(e.target.className)&&(e.shiftKey?a(e.target,!0):t.onValueChanged(f,e.target.getAttribute("data-color")))}))}else e.addEventListener("click",(function(e){/a-color-picker-palette-color/.test(e.target.className)&&t.onValueChanged(f,e.target.getAttribute("data-color"))}))}else e.style.display="none"}},{key:"updatePalette",value:function(e){this.paletteRow.innerHTML="",this.palette={},this.paletteRow.parentElement||this.element.appendChild(this.paletteRow),this.options.palette=e,this.setPalette(this.paletteRow)}},{key:"onValueChanged",value:function(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{silent:!1};switch(e){case"H":this.H=t;var i=(0,n.hslToRgb)(this.H,this.S,this.L),a=o(i,3);this.R=a[0],this.G=a[1],this.B=a[2],this.slBarHelper.setHue(t),this.updatePointerH(this.H),this.updateInputHSL(this.H,this.S,this.L),this.updateInputRGB(this.R,this.G,this.B),this.updateInputRGBHEX(this.R,this.G,this.B);break;case"S":this.S=t;var s=(0,n.hslToRgb)(this.H,this.S,this.L),l=o(s,3);this.R=l[0],this.G=l[1],this.B=l[2],this.updatePointerSL(this.H,this.S,this.L),this.updateInputHSL(this.H,this.S,this.L),this.updateInputRGB(this.R,this.G,this.B),this.updateInputRGBHEX(this.R,this.G,this.B);break;case"L":this.L=t;var c=(0,n.hslToRgb)(this.H,this.S,this.L),u=o(c,3);this.R=u[0],this.G=u[1],this.B=u[2],this.updatePointerSL(this.H,this.S,this.L),this.updateInputHSL(this.H,this.S,this.L),this.updateInputRGB(this.R,this.G,this.B),this.updateInputRGBHEX(this.R,this.G,this.B);break;case"R":this.R=t;var h=(0,n.rgbToHsl)(this.R,this.G,this.B),p=o(h,3);this.H=p[0],this.S=p[1],this.L=p[2],this.slBarHelper.setHue(this.H),this.updatePointerH(this.H),this.updatePointerSL(this.H,this.S,this.L),this.updateInputHSL(this.H,this.S,this.L),this.updateInputRGBHEX(this.R,this.G,this.B);break;case"G":this.G=t;var d=(0,n.rgbToHsl)(this.R,this.G,this.B),v=o(d,3);this.H=v[0],this.S=v[1],this.L=v[2],this.slBarHelper.setHue(this.H),this.updatePointerH(this.H),this.updatePointerSL(this.H,this.S,this.L),this.updateInputHSL(this.H,this.S,this.L),this.updateInputRGBHEX(this.R,this.G,this.B);break;case"B":this.B=t;var m=(0,n.rgbToHsl)(this.R,this.G,this.B),y=o(m,3);this.H=y[0],this.S=y[1],this.L=y[2],this.slBarHelper.setHue(this.H),this.updatePointerH(this.H),this.updatePointerSL(this.H,this.S,this.L),this.updateInputHSL(this.H,this.S,this.L),this.updateInputRGBHEX(this.R,this.G,this.B);break;case"RGB":var A=o(t,3);this.R=A[0],this.G=A[1],this.B=A[2];var k=(0,n.rgbToHsl)(this.R,this.G,this.B),F=o(k,3);this.H=F[0],this.S=F[1],this.L=F[2],this.updateInputHSL(this.H,this.S,this.L),this.updateInputRGB(this.R,this.G,this.B),this.updateInputRGBHEX(this.R,this.G,this.B);break;case g:var E=o(t,4);this.R=E[0],this.G=E[1],this.B=E[2],this.A=E[3];var C=(0,n.rgbToHsl)(this.R,this.G,this.B),H=o(C,3);this.H=H[0],this.S=H[1],this.L=H[2],this.slBarHelper.setHue(this.H),this.updatePointerH(this.H),this.updatePointerSL(this.H,this.S,this.L),this.updateInputHSL(this.H,this.S,this.L),this.updateInputRGB(this.R,this.G,this.B),this.updateInputRGBHEX(this.R,this.G,this.B),this.updatePointerA(this.A);break;case b:var B=o(t,4);this.H=B[0],this.S=B[1],this.L=B[2],this.A=B[3];var R=(0,n.hslToRgb)(this.H,this.S,this.L),S=o(R,3);this.R=S[0],this.G=S[1],this.B=S[2],this.slBarHelper.setHue(this.H),this.updatePointerH(this.H),this.updatePointerSL(this.H,this.S,this.L),this.updateInputHSL(this.H,this.S,this.L),this.updateInputRGB(this.R,this.G,this.B),this.updateInputRGBHEX(this.R,this.G,this.B),this.updatePointerA(this.A);break;case"RGBHEX":var L=(0,n.cssColorToRgb)(t)||[this.R,this.G,this.B],w=o(L,3);this.R=w[0],this.G=w[1],this.B=w[2];var x=(0,n.rgbToHsl)(this.R,this.G,this.B),T=o(x,3);this.H=T[0],this.S=T[1],this.L=T[2],this.slBarHelper.setHue(this.H),this.updatePointerH(this.H),this.updatePointerSL(this.H,this.S,this.L),this.updateInputHSL(this.H,this.S,this.L),this.updateInputRGB(this.R,this.G,this.B);break;case f:var I=(0,n.parseColor)(t,"rgba")||[0,0,0,1],G=o(I,4);this.R=G[0],this.G=G[1],this.B=G[2],this.A=G[3];var P=(0,n.rgbToHsl)(this.R,this.G,this.B),_=o(P,3);this.H=_[0],this.S=_[1],this.L=_[2],this.slBarHelper.setHue(this.H),this.updatePointerH(this.H),this.updatePointerSL(this.H,this.S,this.L),this.updateInputHSL(this.H,this.S,this.L),this.updateInputRGB(this.R,this.G,this.B),this.updateInputRGBHEX(this.R,this.G,this.B),this.updatePointerA(this.A);break;case"ALPHA":this.A=t}this.preview.style.backgroundColor=1===this.A?"rgb("+this.R+","+this.G+","+this.B+")":"rgba("+this.R+","+this.G+","+this.B+","+this.A+")",r&&r.silent||this.onchange&&this.onchange(this.preview.style.backgroundColor)}},{key:"onPaletteColorAdd",value:function(e){this.oncoloradd&&this.oncoloradd(e)}},{key:"onPaletteColorRemove",value:function(e){this.oncolorremove&&this.oncolorremove(e)}},{key:"updateInputHSL",value:function(e,t,r){this.options.showHSL&&(this.inputH.value=e,this.inputS.value=t,this.inputL.value=r)}},{key:"updateInputRGB",value:function(e,t,r){this.options.showRGB&&(this.inputR.value=e,this.inputG.value=t,this.inputB.value=r)}},{key:"updateInputRGBHEX",value:function(e,t,r){this.options.showHEX&&(this.inputRGBHEX.value=(0,n.rgbToHex)(e,t,r))}},{key:"updatePointerH",value:function(e){this.huePointer.style.left=this.options.hueBarSize[0]*e/360-7+"px"}},{key:"updatePointerSL",value:function(e,t,r){var i=(0,n.hslToRgb)(e,t,r),a=o(i,3),s=this.slBarHelper.findColor(a[0],a[1],a[2]),l=o(s,2),c=l[0],u=l[1];c>=0&&(this.slPointer.style.left=c-7+"px",this.slPointer.style.top=u-7+"px")}},{key:"updatePointerA",value:function(e){this.options.showAlpha&&(this.alphaPointer.style.left=this.options.alphaBarSize[0]*e-7+"px")}}]),e}(),F=function(){function e(t){c(this,e),this.name=t,this.listeners=[]}return i(e,[{key:"on",value:function(e){e&&this.listeners.push(e)}},{key:"off",value:function(e){this.listeners=e?this.listeners.filter((function(t){return t!==e})):[]}},{key:"emit",value:function(e,t){for(var r=this.listeners.slice(0),i=0;r.length>i;i++)r[i].apply(t,e)}}]),e}();function E(e,t){var r=new k(e,t),i={change:new F("change"),coloradd:new F("coloradd"),colorremove:new F("colorremove")},a=!0,s={},l={get element(){return r.element},get rgb(){return[r.R,r.G,r.B]},set rgb(e){var t=o(e,3),i=t[0],a=t[1],s=t[2],l=[(0,n.limit)(i,0,255),(0,n.limit)(a,0,255),(0,n.limit)(s,0,255)];r.onValueChanged(g,[i=l[0],a=l[1],s=l[2],1])},get hsl(){return[r.H,r.S,r.L]},set hsl(e){var t=o(e,3),i=t[0],a=t[1],s=t[2],l=[(0,n.limit)(i,0,360),(0,n.limit)(a,0,100),(0,n.limit)(s,0,100)];r.onValueChanged(b,[i=l[0],a=l[1],s=l[2],1])},get rgbhex(){return this.all.hex},get rgba(){return[r.R,r.G,r.B,r.A]},set rgba(e){var t=o(e,4),i=t[0],a=t[1],s=t[2],l=t[3],c=[(0,n.limit)(i,0,255),(0,n.limit)(a,0,255),(0,n.limit)(s,0,255),(0,n.limit)(l,0,1)];r.onValueChanged(g,[i=c[0],a=c[1],s=c[2],l=c[3]])},get hsla(){return[r.H,r.S,r.L,r.A]},set hsla(e){var t=o(e,4),i=t[0],a=t[1],s=t[2],l=t[3],c=[(0,n.limit)(i,0,360),(0,n.limit)(a,0,100),(0,n.limit)(s,0,100),(0,n.limit)(l,0,1)];r.onValueChanged(b,[i=c[0],a=c[1],s=c[2],l=c[3]])},get color(){return this.all.toString()},set color(e){r.onValueChanged(f,e)},setColor:function(e){r.onValueChanged(f,e,{silent:arguments.length>1&&void 0!==arguments[1]&&arguments[1]})},get all(){if(a){var e=[r.R,r.G,r.B,r.A],t=1>r.A?"rgba("+r.R+","+r.G+","+r.B+","+r.A+")":n.rgbToHex.apply(void 0,e);(s=(0,n.parseColor)(e,s)).toString=function(){return t},a=!1}return Object.assign({},s)},get onchange(){return i.change&&i.change.listeners[0]},set onchange(e){this.off("change").on("change",e)},get oncoloradd(){return i.coloradd&&i.coloradd.listeners[0]},set oncoloradd(e){this.off("coloradd").on("coloradd",e)},get oncolorremove(){return i.colorremove&&i.colorremove.listeners[0]},set oncolorremove(e){this.off("colorremove").on("colorremove",e)},get palette(){return Object.keys(r.palette).filter((function(e){return r.palette[e]}))},set palette(e){r.updatePalette(e)},show:function(){r.element.classList.remove("hidden")},hide:function(){r.element.classList.add("hidden")},toggle:function(){r.element.classList.toggle("hidden")},on:function(e,t){return e&&i[e]&&i[e].on(t),this},off:function(e,t){return e&&i[e]&&i[e].off(t),this},destroy:function(){i.change.off(),i.coloradd.off(),i.colorremove.off(),r.element.remove(),i=null,r=null}};return r.onchange=function(){for(var e=arguments.length,t=Array(e),r=0;e>r;r++)t[r]=arguments[r];a=!0,i.change.emit([l].concat(t),l)},r.oncoloradd=function(){for(var e=arguments.length,t=Array(e),r=0;e>r;r++)t[r]=arguments[r];i.coloradd.emit([l].concat(t),l)},r.oncolorremove=function(){for(var e=arguments.length,t=Array(e),r=0;e>r;r++)t[r]=arguments[r];i.colorremove.emit([l].concat(t),l)},r.element.ctrl=l,l}if("undefined"!=typeof window&&!document.querySelector('head>style[data-source="a-color-picker"]')){var C=r(5).toString(),H=document.createElement("style");H.setAttribute("type","text/css"),H.setAttribute("data-source","a-color-picker"),H.innerHTML=C,document.querySelector("head").appendChild(H)}t.createPicker=E,t.from=function(e,t){var r=function(e){return e?Array.isArray(e)?e:e instanceof HTMLElement?[e]:e instanceof NodeList?[].concat(u(e)):"string"==typeof e?[].concat(u(document.querySelectorAll(e))):e.jquery?e.get():[]:[]}(e).map((function(e,r){var i=E(e,t);return i.index=r,i}));return r.on=function(e,t){return r.forEach((function(r){return r.on(e,t)})),this},r.off=function(e){return r.forEach((function(t){return t.off(e)})),this},r},t.parseColorToRgb=n.parseColorToRgb,t.parseColorToRgba=n.parseColorToRgba,t.parseColorToHsl=n.parseColorToHsl,t.parseColorToHsla=n.parseColorToHsla,t.parseColor=n.parseColor,t.rgbToHex=n.rgbToHex,t.hslToRgb=n.hslToRgb,t.rgbToHsl=n.rgbToHsl,t.rgbToHsv=n.rgbToHsv,t.rgbToInt=n.rgbToInt,t.intToRgb=n.intToRgb,t.getLuminance=n.getLuminance,t.COLOR_NAMES=n.COLOR_NAMES,t.PALETTE_MATERIAL_500=n.PALETTE_MATERIAL_500,t.PALETTE_MATERIAL_CHROME=n.PALETTE_MATERIAL_CHROME,t.VERSION="1.2.1"},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.nvl=t.ensureArray=t.limit=t.getLuminance=t.parseColor=t.parseColorToHsla=t.parseColorToHsl=t.cssHslaToHsla=t.cssHslToHsl=t.parseColorToRgba=t.parseColorToRgb=t.cssRgbaToRgba=t.cssRgbToRgb=t.cssColorToRgba=t.cssColorToRgb=t.intToRgb=t.rgbToInt=t.rgbToHsv=t.rgbToHsl=t.hslToRgb=t.rgbToHex=t.PALETTE_MATERIAL_CHROME=t.PALETTE_MATERIAL_500=t.COLOR_NAMES=void 0;var i=function(e,t){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return function(e,t){var r=[],i=!0,o=!1,n=void 0;try{for(var a,s=e[Symbol.iterator]();!(i=(a=s.next()).done)&&(r.push(a.value),!t||r.length!==t);i=!0);}catch(e){o=!0,n=e}finally{try{!i&&s.return&&s.return()}finally{if(o)throw n}}return r}(e,t);throw new TypeError("Invalid attempt to destructure non-iterable instance")},o=function(e){return e&&e.__esModule?e:{default:e}}(r(0));function n(e){if(Array.isArray(e)){for(var t=0,r=Array(e.length);e.length>t;t++)r[t]=e[t];return r}return Array.from(e)}var a={aliceblue:"#F0F8FF",antiquewhite:"#FAEBD7",aqua:"#00FFFF",aquamarine:"#7FFFD4",azure:"#F0FFFF",beige:"#F5F5DC",bisque:"#FFE4C4",black:"#000000",blanchedalmond:"#FFEBCD",blue:"#0000FF",blueviolet:"#8A2BE2",brown:"#A52A2A",burlywood:"#DEB887",cadetblue:"#5F9EA0",chartreuse:"#7FFF00",chocolate:"#D2691E",coral:"#FF7F50",cornflowerblue:"#6495ED",cornsilk:"#FFF8DC",crimson:"#DC143C",cyan:"#00FFFF",darkblue:"#00008B",darkcyan:"#008B8B",darkgoldenrod:"#B8860B",darkgray:"#A9A9A9",darkgrey:"#A9A9A9",darkgreen:"#006400",darkkhaki:"#BDB76B",darkmagenta:"#8B008B",darkolivegreen:"#556B2F",darkorange:"#FF8C00",darkorchid:"#9932CC",darkred:"#8B0000",darksalmon:"#E9967A",darkseagreen:"#8FBC8F",darkslateblue:"#483D8B",darkslategray:"#2F4F4F",darkslategrey:"#2F4F4F",darkturquoise:"#00CED1",darkviolet:"#9400D3",deeppink:"#FF1493",deepskyblue:"#00BFFF",dimgray:"#696969",dimgrey:"#696969",dodgerblue:"#1E90FF",firebrick:"#B22222",floralwhite:"#FFFAF0",forestgreen:"#228B22",fuchsia:"#FF00FF",gainsboro:"#DCDCDC",ghostwhite:"#F8F8FF",gold:"#FFD700",goldenrod:"#DAA520",gray:"#808080",grey:"#808080",green:"#008000",greenyellow:"#ADFF2F",honeydew:"#F0FFF0",hotpink:"#FF69B4","indianred ":"#CD5C5C","indigo ":"#4B0082",ivory:"#FFFFF0",khaki:"#F0E68C",lavender:"#E6E6FA",lavenderblush:"#FFF0F5",lawngreen:"#7CFC00",lemonchiffon:"#FFFACD",lightblue:"#ADD8E6",lightcoral:"#F08080",lightcyan:"#E0FFFF",lightgoldenrodyellow:"#FAFAD2",lightgray:"#D3D3D3",lightgrey:"#D3D3D3",lightgreen:"#90EE90",lightpink:"#FFB6C1",lightsalmon:"#FFA07A",lightseagreen:"#20B2AA",lightskyblue:"#87CEFA",lightslategray:"#778899",lightslategrey:"#778899",lightsteelblue:"#B0C4DE",lightyellow:"#FFFFE0",lime:"#00FF00",limegreen:"#32CD32",linen:"#FAF0E6",magenta:"#FF00FF",maroon:"#800000",mediumaquamarine:"#66CDAA",mediumblue:"#0000CD",mediumorchid:"#BA55D3",mediumpurple:"#9370DB",mediumseagreen:"#3CB371",mediumslateblue:"#7B68EE",mediumspringgreen:"#00FA9A",mediumturquoise:"#48D1CC",mediumvioletred:"#C71585",midnightblue:"#191970",mintcream:"#F5FFFA",mistyrose:"#FFE4E1",moccasin:"#FFE4B5",navajowhite:"#FFDEAD",navy:"#000080",oldlace:"#FDF5E6",olive:"#808000",olivedrab:"#6B8E23",orange:"#FFA500",orangered:"#FF4500",orchid:"#DA70D6",palegoldenrod:"#EEE8AA",palegreen:"#98FB98",paleturquoise:"#AFEEEE",palevioletred:"#DB7093",papayawhip:"#FFEFD5",peachpuff:"#FFDAB9",peru:"#CD853F",pink:"#FFC0CB",plum:"#DDA0DD",powderblue:"#B0E0E6",purple:"#800080",rebeccapurple:"#663399",red:"#FF0000",rosybrown:"#BC8F8F",royalblue:"#4169E1",saddlebrown:"#8B4513",salmon:"#FA8072",sandybrown:"#F4A460",seagreen:"#2E8B57",seashell:"#FFF5EE",sienna:"#A0522D",silver:"#C0C0C0",skyblue:"#87CEEB",slateblue:"#6A5ACD",slategray:"#708090",slategrey:"#708090",snow:"#FFFAFA",springgreen:"#00FF7F",steelblue:"#4682B4",tan:"#D2B48C",teal:"#008080",thistle:"#D8BFD8",tomato:"#FF6347",turquoise:"#40E0D0",violet:"#EE82EE",wheat:"#F5DEB3",white:"#FFFFFF",whitesmoke:"#F5F5F5",yellow:"#FFFF00",yellowgreen:"#9ACD32"};function s(e,t,r){return e=+e,isNaN(e)||t>e?t:e>r?r:e}function l(e,t){return null==e?t:e}function c(e,t,r){var i=[s(e,0,255),s(t,0,255),s(r,0,255)];return"#"+("000000"+((e=i[0])<<16|(t=i[1])<<8|(r=i[2])).toString(16)).slice(-6)}function u(e,t,r){var i=void 0,o=void 0,n=void 0,a=[s(e,0,360)/360,s(t,0,100)/100,s(r,0,100)/100];if(e=a[0],r=a[2],0==(t=a[1]))i=o=n=r;else{var l=function(e,t,r){return 0>r&&(r+=1),r>1&&(r-=1),1/6>r?e+6*(t-e)*r:.5>r?t:2/3>r?e+(t-e)*(2/3-r)*6:e},c=.5>r?r*(1+t):r+t-r*t,u=2*r-c;i=l(u,c,e+1/3),o=l(u,c,e),n=l(u,c,e-1/3)}return[255*i,255*o,255*n].map(Math.round)}function h(e,t,r){var i=[s(e,0,255)/255,s(t,0,255)/255,s(r,0,255)/255];e=i[0],t=i[1],r=i[2];var o=Math.max(e,t,r),n=Math.min(e,t,r),a=void 0,l=void 0,c=(o+n)/2;if(o==n)a=l=0;else{var u=o-n;switch(l=c>.5?u/(2-o-n):u/(o+n),o){case e:a=(t-r)/u+(r>t?6:0);break;case t:a=(r-e)/u+2;break;case r:a=(e-t)/u+4}a/=6}return[360*a,100*l,100*c].map(Math.round)}function p(e,t,r){return e<<16|t<<8|r}function d(e){if(e){var t=a[e.toString().toLowerCase()],r=/^\s*#?((([0-9A-F])([0-9A-F])([0-9A-F]))|(([0-9A-F]{2})([0-9A-F]{2})([0-9A-F]{2})))\s*$/i.exec(t||e)||[],o=i(r,10),n=o[3],s=o[4],l=o[5],c=o[7],u=o[8],h=o[9];if(void 0!==n)return[parseInt(n+n,16),parseInt(s+s,16),parseInt(l+l,16)];if(void 0!==c)return[parseInt(c,16),parseInt(u,16),parseInt(h,16)]}}function f(e){if(e){var t=a[e.toString().toLowerCase()],r=/^\s*#?((([0-9A-F])([0-9A-F])([0-9A-F])([0-9A-F])?)|(([0-9A-F]{2})([0-9A-F]{2})([0-9A-F]{2})([0-9A-F]{2})?))\s*$/i.exec(t||e)||[],o=i(r,12),n=o[3],s=o[4],l=o[5],c=o[6],u=o[8],h=o[9],p=o[10],d=o[11];if(void 0!==n)return[parseInt(n+n,16),parseInt(s+s,16),parseInt(l+l,16),c?+(parseInt(c+c,16)/255).toFixed(2):1];if(void 0!==u)return[parseInt(u,16),parseInt(h,16),parseInt(p,16),d?+(parseInt(d,16)/255).toFixed(2):1]}}function g(e){if(e){var t=/^rgb\((\d+)[\s,](\d+)[\s,](\d+)\)/i.exec(e)||[],r=i(t,4),o=r[2],n=r[3];return r[0]?[s(r[1],0,255),s(o,0,255),s(n,0,255)]:void 0}}function b(e){if(e){var t=/^rgba?\((\d+)\s*[\s,]\s*(\d+)\s*[\s,]\s*(\d+)(\s*[\s,]\s*(\d*(.\d+)?))?\)/i.exec(e)||[],r=i(t,6),o=r[2],n=r[3],a=r[5];return r[0]?[s(r[1],0,255),s(o,0,255),s(n,0,255),s(l(a,1),0,1)]:void 0}}function v(e){if(Array.isArray(e))return[s(e[0],0,255),s(e[1],0,255),s(e[2],0,255),s(l(e[3],1),0,1)];var t=f(e)||b(e);return t&&3===t.length&&t.push(1),t}function m(e){if(e){var t=/^hsl\((\d+)[\s,](\d+)[\s,](\d+)\)/i.exec(e)||[],r=i(t,4),o=r[2],n=r[3];return r[0]?[s(r[1],0,360),s(o,0,100),s(n,0,100)]:void 0}}function y(e){if(e){var t=/^hsla?\((\d+)\s*[\s,]\s*(\d+)\s*[\s,]\s*(\d+)(\s*[\s,]\s*(\d*(.\d+)?))?\)/i.exec(e)||[],r=i(t,6),o=r[2],n=r[3],a=r[5];return r[0]?[s(r[1],0,255),s(o,0,255),s(n,0,255),s(l(a,1),0,1)]:void 0}}function A(e){if(Array.isArray(e))return[s(e[0],0,360),s(e[1],0,100),s(e[2],0,100),s(l(e[3],1),0,1)];var t=y(e);return t&&3===t.length&&t.push(1),t}function k(e,t){switch(t){case"rgb":default:return e.slice(0,3);case"rgbcss":return"rgb("+e[0]+", "+e[1]+", "+e[2]+")";case"rgbcss4":return"rgb("+e[0]+", "+e[1]+", "+e[2]+", "+e[3]+")";case"rgba":return e;case"rgbacss":return"rgba("+e[0]+", "+e[1]+", "+e[2]+", "+e[3]+")";case"hsl":return h.apply(void 0,n(e));case"hslcss":return"hsl("+(e=h.apply(void 0,n(e)))[0]+", "+e[1]+", "+e[2]+")";case"hslcss4":var r=h.apply(void 0,n(e));return"hsl("+r[0]+", "+r[1]+", "+r[2]+", "+e[3]+")";case"hsla":return[].concat(n(h.apply(void 0,n(e))),[e[3]]);case"hslacss":var i=h.apply(void 0,n(e));return"hsla("+i[0]+", "+i[1]+", "+i[2]+", "+e[3]+")";case"hex":return c.apply(void 0,n(e));case"hexcss4":return c.apply(void 0,n(e))+("00"+parseInt(255*e[3]).toString(16)).slice(-2);case"int":return p.apply(void 0,n(e))}}t.COLOR_NAMES=a,t.PALETTE_MATERIAL_500=["#F44336","#E91E63","#E91E63","#9C27B0","#9C27B0","#673AB7","#673AB7","#3F51B5","#3F51B5","#2196F3","#2196F3","#03A9F4","#03A9F4","#00BCD4","#00BCD4","#009688","#009688","#4CAF50","#4CAF50","#8BC34A","#8BC34A","#CDDC39","#CDDC39","#FFEB3B","#FFEB3B","#FFC107","#FFC107","#FF9800","#FF9800","#FF5722","#FF5722","#795548","#795548","#9E9E9E","#9E9E9E","#607D8B","#607D8B"],t.PALETTE_MATERIAL_CHROME=["#f44336","#e91e63","#9c27b0","#673ab7","#3f51b5","#2196f3","#03a9f4","#00bcd4","#009688","#4caf50","#8bc34a","#cddc39","#ffeb3b","#ffc107","#ff9800","#ff5722","#795548","#9e9e9e","#607d8b"],t.rgbToHex=c,t.hslToRgb=u,t.rgbToHsl=h,t.rgbToHsv=function(e,t,r){var i=[s(e,0,255)/255,s(t,0,255)/255,s(r,0,255)/255];e=i[0],t=i[1],r=i[2];var o,n=Math.max(e,t,r),a=Math.min(e,t,r),l=void 0,c=n,u=n-a;if(o=0===n?0:u/n,n==a)l=0;else{switch(n){case e:l=(t-r)/u+(r>t?6:0);break;case t:l=(r-e)/u+2;break;case r:l=(e-t)/u+4}l/=6}return[l,o,c]},t.rgbToInt=p,t.intToRgb=function(e){return[e>>16&255,e>>8&255,255&e]},t.cssColorToRgb=d,t.cssColorToRgba=f,t.cssRgbToRgb=g,t.cssRgbaToRgba=b,t.parseColorToRgb=function(e){return Array.isArray(e)?e=[s(e[0],0,255),s(e[1],0,255),s(e[2],0,255)]:d(e)||g(e)},t.parseColorToRgba=v,t.cssHslToHsl=m,t.cssHslaToHsla=y,t.parseColorToHsl=function(e){return Array.isArray(e)?e=[s(e[0],0,360),s(e[1],0,100),s(e[2],0,100)]:m(e)},t.parseColorToHsla=A,t.parseColor=function(e,t){if(t=t||"rgb",null!=e){var r=void 0;if((r=v(e))||(r=A(e))&&(r=[].concat(n(u.apply(void 0,n(r))),[r[3]])))return(0,o.default)(t)?["rgb","rgbcss","rgbcss4","rgba","rgbacss","hsl","hslcss","hslcss4","hsla","hslacss","hex","hexcss4","int"].reduce((function(e,t){return e[t]=k(r,t),e}),t||{}):k(r,t.toString().toLowerCase())}},t.getLuminance=function(e,t,r){return.2126*(e=.03928>(e/=255)?e/12.92:Math.pow((e+.055)/1.055,2.4))+.7152*(t=.03928>(t/=255)?t/12.92:Math.pow((t+.055)/1.055,2.4))+.0722*(.03928>(r/=255)?r/12.92:Math.pow((r+.055)/1.055,2.4))},t.limit=s,t.ensureArray=function(e){return e?Array.from(e):[]},t.nvl=l},function(e,t,r){"use strict";e.exports=function(e){return null!=e&&"object"==typeof e&&!1===Array.isArray(e)}},function(e,t){e.exports='<div class="a-color-picker-row a-color-picker-stack a-color-picker-row-top"> <canvas class="a-color-picker-sl a-color-picker-transparent"></canvas> <div class=a-color-picker-dot></div> </div> <div class=a-color-picker-row> <div class="a-color-picker-stack a-color-picker-transparent a-color-picker-circle"> <div class=a-color-picker-preview> <input class=a-color-picker-clipbaord type=text> </div> </div> <div class=a-color-picker-column> <div class="a-color-picker-cell a-color-picker-stack"> <canvas class=a-color-picker-h></canvas> <div class=a-color-picker-dot></div> </div> <div class="a-color-picker-cell a-color-picker-alpha a-color-picker-stack" show-on-alpha> <canvas class="a-color-picker-a a-color-picker-transparent"></canvas> <div class=a-color-picker-dot></div> </div> </div> </div> <div class="a-color-picker-row a-color-picker-hsl" show-on-hsl> <label>H</label> <input nameref=H type=number maxlength=3 min=0 max=360 value=0> <label>S</label> <input nameref=S type=number maxlength=3 min=0 max=100 value=0> <label>L</label> <input nameref=L type=number maxlength=3 min=0 max=100 value=0> </div> <div class="a-color-picker-row a-color-picker-rgb" show-on-rgb> <label>R</label> <input nameref=R type=number maxlength=3 min=0 max=255 value=0> <label>G</label> <input nameref=G type=number maxlength=3 min=0 max=255 value=0> <label>B</label> <input nameref=B type=number maxlength=3 min=0 max=255 value=0> </div> <div class="a-color-picker-row a-color-picker-rgbhex a-color-picker-single-input" show-on-single-input> <label>HEX</label> <input nameref=RGBHEX type=text select-on-focus> </div> <div class="a-color-picker-row a-color-picker-palette"></div>'},function(e,t,r){var i=r(6);e.exports="string"==typeof i?i:i.toString()},function(e,t,r){(e.exports=r(7)(!1)).push([e.i,"/*!\n * a-color-picker\n * https://github.com/narsenico/a-color-picker\n *\n * Copyright (c) 2017-2018, Gianfranco Caldi.\n * Released under the MIT License.\n */.a-color-picker{background-color:#fff;padding:0;display:inline-flex;flex-direction:column;user-select:none;width:232px;font:400 10px Helvetica,Arial,sans-serif;border-radius:3px;box-shadow:0 0 0 1px rgba(0,0,0,.05),0 2px 4px rgba(0,0,0,.25)}.a-color-picker,.a-color-picker-row,.a-color-picker input{box-sizing:border-box}.a-color-picker-row{padding:15px;display:flex;flex-direction:row;align-items:center;justify-content:space-between;user-select:none}.a-color-picker-row-top{padding:0}.a-color-picker-row:not(:first-child){border-top:1px solid #f5f5f5}.a-color-picker-column{display:flex;flex-direction:column}.a-color-picker-cell{flex:1 1 auto;margin-bottom:4px}.a-color-picker-cell:last-child{margin-bottom:0}.a-color-picker-stack{position:relative}.a-color-picker-dot{position:absolute;width:14px;height:14px;top:0;left:0;background:#fff;pointer-events:none;border-radius:50px;z-index:1000;box-shadow:0 1px 2px rgba(0,0,0,.75)}.a-color-picker-a,.a-color-picker-h,.a-color-picker-sl{cursor:cell}.a-color-picker-a+.a-color-picker-dot,.a-color-picker-h+.a-color-picker-dot{top:-2px}.a-color-picker-a,.a-color-picker-h{border-radius:2px}.a-color-picker-preview{box-sizing:border-box;width:30px;height:30px;user-select:none;border-radius:15px}.a-color-picker-circle{border-radius:50px;border:1px solid #eee}.a-color-picker-hsl,.a-color-picker-rgb,.a-color-picker-single-input{justify-content:space-evenly}.a-color-picker-hsl>label,.a-color-picker-rgb>label,.a-color-picker-single-input>label{padding:0 8px;flex:0 0 auto;color:#969696}.a-color-picker-hsl>input,.a-color-picker-rgb>input,.a-color-picker-single-input>input{text-align:center;padding:2px 0;width:0;flex:1 1 auto;border:1px solid #e0e0e0;line-height:20px}.a-color-picker-hsl>input::-webkit-inner-spin-button,.a-color-picker-rgb>input::-webkit-inner-spin-button,.a-color-picker-single-input>input::-webkit-inner-spin-button{-webkit-appearance:none;margin:0}.a-color-picker-hsl>input:focus,.a-color-picker-rgb>input:focus,.a-color-picker-single-input>input:focus{border-color:#04a9f4;outline:none}.a-color-picker-transparent{background-image:linear-gradient(-45deg,#cdcdcd 25%,transparent 0),linear-gradient(45deg,#cdcdcd 25%,transparent 0),linear-gradient(-45deg,transparent 75%,#cdcdcd 0),linear-gradient(45deg,transparent 75%,#cdcdcd 0);background-size:11px 11px;background-position:0 0,0 -5.5px,-5.5px 5.5px,5.5px 0}.a-color-picker-sl{border-radius:3px 3px 0 0}.a-color-picker.hide-alpha [show-on-alpha],.a-color-picker.hide-hsl [show-on-hsl],.a-color-picker.hide-rgb [show-on-rgb],.a-color-picker.hide-single-input [show-on-single-input]{display:none}.a-color-picker-clipbaord{width:100%;height:100%;opacity:0;cursor:pointer}.a-color-picker-palette{flex-flow:wrap;flex-direction:row;justify-content:flex-start;padding:10px}.a-color-picker-palette-color{width:15px;height:15px;flex:0 1 15px;margin:3px;box-sizing:border-box;cursor:pointer;border-radius:3px;box-shadow:inset 0 0 0 1px rgba(0,0,0,.1)}.a-color-picker-palette-add{text-align:center;line-height:13px;color:#607d8b}.a-color-picker.hidden{display:none}",""])},function(e,t){e.exports=function(e){var t=[];return t.toString=function(){return this.map((function(t){var r=function(e,t){var r=e[1]||"",i=e[3];if(!i)return r;if(t&&"function"==typeof btoa){var o=function(e){return"/*# sourceMappingURL=data:application/json;charset=utf-8;base64,"+btoa(unescape(encodeURIComponent(JSON.stringify(e))))+" */"}(i),n=i.sources.map((function(e){return"/*# sourceURL="+i.sourceRoot+e+" */"}));return[r].concat(n).concat([o]).join("\n")}return[r].join("\n")}(t,e);return t[2]?"@media "+t[2]+"{"+r+"}":r})).join("")},t.i=function(e,r){"string"==typeof e&&(e=[[null,e,""]]);for(var i={},o=0;this.length>o;o++){var n=this[o][0];"number"==typeof n&&(i[n]=!0)}for(o=0;e.length>o;o++){var a=e[o];"number"==typeof a[0]&&i[a[0]]||(r&&!a[2]?a[2]=r:r&&(a[2]="("+a[2]+") and ("+r+")"),t.push(a))}},t}}])},524:(e,t,r)=>{"use strict";r.r(t)},522:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.colorPicker=void 0;var i=r(1),o=r(187),n=r(14),a=r(523),s=r(103),l=r(2),c=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.requires=["license"],t.hasStyle=!l.Jodit.fatMode,t}return i.__extends(t,e),t.prototype.afterInit=function(e){e.e.on("afterGenerateColorPicker",this.onAfterGenerateColorPicker)},t.prototype.onAfterGenerateColorPicker=function(e,t,r,i){n.Dom.detach(t);var o=new a.ColorInput(this.j,r);o.value=i||"#000",t.appendChild(o.container)},t.prototype.beforeDestruct=function(e){e.e.off("afterGenerateColorPicker",this.onAfterGenerateColorPicker)},i.__decorate([s.autobind],t.prototype,"onAfterGenerateColorPicker",null),t}(o.Plugin);t.colorPicker=c,l.Jodit.plugins.add("color-picker",c)},523:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ColorInput=void 0;var i=r(1);r(524);var o=r(79),n=r(103),a=r(23),s=r(525),l=r(14),c=function(e){function t(t,r){var i=e.call(this,t)||this,n=new o.Popup(t);i.trigger.onAction((function(){r(i.value),n.close()})),n.setMod("padding",!1).setMod("max-height",!1);var c=i.j.create.div(i.getFullElName("picker")),u=s.createPicker(c,{paletteEditable:!0,showAlpha:!0,palette:"PALETTE_MATERIAL_CHROME"}).on("change",(function(e,t){i.isFocused||(i.value=s.parseColor(t||"","hex"))}));return i.j.e.on(i,"change",(function(){s.parseColor(i.value,"hex")!==u.color&&(u.color=i.value)})),n.setContent(c),i.j.e.on(i.nativeInput,"click",(function(){n.parentElement=i,i.jodit instanceof l.Dialog&&n.setZIndex(i.jodit.getZIndex()+1),n.open((function(){return a.position(i.container)}))})),i}return i.__extends(t,e),t.prototype.className=function(){return"ColorInput"},t.prototype.createContainer=function(t){var r=e.prototype.createContainer.call(this,t);return this.trigger=o.Button(this.j,"ok"),r.appendChild(this.trigger.container),this.trigger.container.classList.add(this.getFullElName("trigger")),r},t.prototype.setMod=function(t,r,i){return void 0===i&&(i=this.container),"slim"===t&&r&&this.nativeInput.setAttribute("readonly","true"),e.prototype.setMod.call(this,t,r,i)},t.prototype.onChangeSelfValue=function(){this.nativeInput.style.backgroundColor=this.value},i.__decorate([n.watch(":change")],t.prototype,"onChangeSelfValue",null),i.__decorate([n.component],t)}(o.UIInput);t.ColorInput=c}},e=>{"use strict";e(e.s=522)}])}));
!function(e,t){if("object"==typeof exports&&"object"==typeof module)module.exports=t();else if("function"==typeof define&&define.amd)define([],t);else{var r=t();for(var i in r)("object"==typeof exports?exports:e)[i]=r[i]}}(self,(function(){return(self.webpackChunkjodit_pro=self.webpackChunkjodit_pro||[]).push([[652],{525:function(e){"undefined"!=typeof self&&self,e.exports=function(e){var t={};function r(i){if(t[i])return t[i].exports;var o=t[i]={i:i,l:!1,exports:{}};return e[i].call(o.exports,o,o.exports,r),o.l=!0,o.exports}return r.m=e,r.c=t,r.d=function(e,t,i){r.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:i})},r.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},r.t=function(e,t){if(1&t&&(e=r(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var i=Object.create(null);if(r.r(i),Object.defineProperty(i,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var o in e)r.d(i,o,function(t){return e[t]}.bind(null,o));return i},r.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return r.d(t,"a",t),t},r.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},r.p="",r(r.s=1)}([function(e,t,r){"use strict";var i=r(3);function o(e){return!0===i(e)&&"[object Object]"===Object.prototype.toString.call(e)}e.exports=function(e){var t,r;return!1!==o(e)&&"function"==typeof(t=e.constructor)&&!1!==o(r=t.prototype)&&!1!==r.hasOwnProperty("isPrototypeOf")}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.VERSION=t.PALETTE_MATERIAL_CHROME=t.PALETTE_MATERIAL_500=t.COLOR_NAMES=t.getLuminance=t.intToRgb=t.rgbToInt=t.rgbToHsv=t.rgbToHsl=t.hslToRgb=t.rgbToHex=t.parseColor=t.parseColorToHsla=t.parseColorToHsl=t.parseColorToRgba=t.parseColorToRgb=t.from=t.createPicker=void 0;var i=function(){function e(e,t){for(var r=0;t.length>r;r++){var i=t[r];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,i.key,i)}}return function(t,r,i){return r&&e(t.prototype,r),i&&e(t,i),t}}(),o=function(e,t){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return function(e,t){var r=[],i=!0,o=!1,n=void 0;try{for(var a,s=e[Symbol.iterator]();!(i=(a=s.next()).done)&&(r.push(a.value),!t||r.length!==t);i=!0);}catch(e){o=!0,n=e}finally{try{!i&&s.return&&s.return()}finally{if(o)throw n}}return r}(e,t);throw new TypeError("Invalid attempt to destructure non-iterable instance")},n=r(2),a=l(r(0)),s=l(r(4));function l(e){return e&&e.__esModule?e:{default:e}}function c(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function u(e){if(Array.isArray(e)){for(var t=0,r=Array(e.length);e.length>t;t++)r[t]=e[t];return r}return Array.from(e)}var h="undefined"!=typeof window&&window.navigator.userAgent.indexOf("Edge")>-1,p="undefined"!=typeof window&&window.navigator.userAgent.indexOf("rv:")>-1,d={id:null,attachTo:"body",showHSL:!0,showRGB:!0,showHEX:!0,showAlpha:!1,color:"#ff0000",palette:null,paletteEditable:!1,useAlphaInPalette:"auto",slBarSize:[232,150],hueBarSize:[150,11],alphaBarSize:[150,11]},f="COLOR",g="RGBA_USER",b="HSLA_USER";function v(e,t,r){return e?e instanceof HTMLElement?e:e instanceof NodeList?e[0]:"string"==typeof e?document.querySelector(e):e.jquery?e.get(0):r?t:null:t}function m(e){var t=e.getContext("2d"),r=+e.width,i=+e.height,a=t.createLinearGradient(1,1,1,i-1);return a.addColorStop(0,"white"),a.addColorStop(1,"black"),{setHue:function(e){var o=t.createLinearGradient(1,0,r-1,0);o.addColorStop(0,"hsla("+e+", 100%, 50%, 0)"),o.addColorStop(1,"hsla("+e+", 100%, 50%, 1)"),t.fillStyle=a,t.fillRect(0,0,r,i),t.fillStyle=o,t.globalCompositeOperation="multiply",t.fillRect(0,0,r,i),t.globalCompositeOperation="source-over"},grabColor:function(e,r){return t.getImageData(e,r,1,1).data},findColor:function(e,t,a){var s=(0,n.rgbToHsv)(e,t,a),l=o(s,3);return[l[1]*r,i-l[2]*i]}}}function y(e,t,r){return null===e?t:/^\s*$/.test(e)?r:!!/true|yes|1/i.test(e)||!/false|no|0/i.test(e)&&t}function A(e,t,r){if(null===e)return t;if(/^\s*$/.test(e))return r;var i=e.split(",").map(Number);return 2===i.length&&i[0]&&i[1]?i:t}var k=function(){function e(t,r){if(c(this,e),r?(t=v(t),this.options=Object.assign({},d,r)):t&&(0,a.default)(t)?(this.options=Object.assign({},d,t),t=v(this.options.attachTo)):(this.options=Object.assign({},d),t=v((0,n.nvl)(t,this.options.attachTo))),!t)throw new Error("Container not found: "+this.options.attachTo);!function(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"acp-";if(t.hasAttribute(r+"show-hsl")&&(e.showHSL=y(t.getAttribute(r+"show-hsl"),d.showHSL,!0)),t.hasAttribute(r+"show-rgb")&&(e.showRGB=y(t.getAttribute(r+"show-rgb"),d.showRGB,!0)),t.hasAttribute(r+"show-hex")&&(e.showHEX=y(t.getAttribute(r+"show-hex"),d.showHEX,!0)),t.hasAttribute(r+"show-alpha")&&(e.showAlpha=y(t.getAttribute(r+"show-alpha"),d.showAlpha,!0)),t.hasAttribute(r+"palette-editable")&&(e.paletteEditable=y(t.getAttribute(r+"palette-editable"),d.paletteEditable,!0)),t.hasAttribute(r+"sl-bar-size")&&(e.slBarSize=A(t.getAttribute(r+"sl-bar-size"),d.slBarSize,[232,150])),t.hasAttribute(r+"hue-bar-size")&&(e.hueBarSize=A(t.getAttribute(r+"hue-bar-size"),d.hueBarSize,[150,11]),e.alphaBarSize=e.hueBarSize),t.hasAttribute(r+"palette")){var i=t.getAttribute(r+"palette");switch(i){case"PALETTE_MATERIAL_500":e.palette=n.PALETTE_MATERIAL_500;break;case"PALETTE_MATERIAL_CHROME":case"":e.palette=n.PALETTE_MATERIAL_CHROME;break;default:e.palette=i.split(/[;|]/)}}t.hasAttribute(r+"color")&&(e.color=t.getAttribute(r+"color"))}(this.options,t),this.H=0,this.S=0,this.L=0,this.R=0,this.G=0,this.B=0,this.A=1,this.palette={},this.element=document.createElement("div"),this.options.id&&(this.element.id=this.options.id),this.element.className="a-color-picker",this.element.innerHTML=s.default,t.appendChild(this.element);var i=this.element.querySelector(".a-color-picker-h");this.setupHueCanvas(i),this.hueBarHelper=m(i),this.huePointer=this.element.querySelector(".a-color-picker-h+.a-color-picker-dot");var o=this.element.querySelector(".a-color-picker-sl");this.setupSlCanvas(o),this.slBarHelper=m(o),this.slPointer=this.element.querySelector(".a-color-picker-sl+.a-color-picker-dot"),this.preview=this.element.querySelector(".a-color-picker-preview"),this.setupClipboard(this.preview.querySelector(".a-color-picker-clipbaord")),this.options.showHSL?(this.setupInput(this.inputH=this.element.querySelector(".a-color-picker-hsl>input[nameref=H]")),this.setupInput(this.inputS=this.element.querySelector(".a-color-picker-hsl>input[nameref=S]")),this.setupInput(this.inputL=this.element.querySelector(".a-color-picker-hsl>input[nameref=L]"))):this.element.querySelector(".a-color-picker-hsl").remove(),this.options.showRGB?(this.setupInput(this.inputR=this.element.querySelector(".a-color-picker-rgb>input[nameref=R]")),this.setupInput(this.inputG=this.element.querySelector(".a-color-picker-rgb>input[nameref=G]")),this.setupInput(this.inputB=this.element.querySelector(".a-color-picker-rgb>input[nameref=B]"))):this.element.querySelector(".a-color-picker-rgb").remove(),this.options.showHEX?this.setupInput(this.inputRGBHEX=this.element.querySelector("input[nameref=RGBHEX]")):this.element.querySelector(".a-color-picker-rgbhex").remove(),this.options.paletteEditable||this.options.palette&&this.options.palette.length>0?this.setPalette(this.paletteRow=this.element.querySelector(".a-color-picker-palette")):(this.paletteRow=this.element.querySelector(".a-color-picker-palette"),this.paletteRow.remove()),this.options.showAlpha?(this.setupAlphaCanvas(this.element.querySelector(".a-color-picker-a")),this.alphaPointer=this.element.querySelector(".a-color-picker-a+.a-color-picker-dot")):this.element.querySelector(".a-color-picker-alpha").remove(),this.element.style.width=this.options.slBarSize[0]+"px",this.onValueChanged(f,this.options.color)}return i(e,[{key:"setupHueCanvas",value:function(e){var t=this;e.width=this.options.hueBarSize[0],e.height=this.options.hueBarSize[1];for(var r=e.getContext("2d"),i=r.createLinearGradient(0,0,this.options.hueBarSize[0],0),o=0;1>=o;o+=1/360)i.addColorStop(o,"hsl("+360*o+", 100%, 50%)");r.fillStyle=i,r.fillRect(0,0,this.options.hueBarSize[0],this.options.hueBarSize[1]);var a=function(r){var i=(0,n.limit)(r.clientX-e.getBoundingClientRect().left,0,t.options.hueBarSize[0]),o=Math.round(360*i/t.options.hueBarSize[0]);t.huePointer.style.left=i-7+"px",t.onValueChanged("H",o)},s=function e(){document.removeEventListener("mousemove",a),document.removeEventListener("mouseup",e)};e.addEventListener("mousedown",(function(e){a(e),document.addEventListener("mousemove",a),document.addEventListener("mouseup",s)}))}},{key:"setupSlCanvas",value:function(e){var t=this;e.width=this.options.slBarSize[0],e.height=this.options.slBarSize[1];var r=function(r){var i=(0,n.limit)(r.clientX-e.getBoundingClientRect().left,0,t.options.slBarSize[0]-1),o=(0,n.limit)(r.clientY-e.getBoundingClientRect().top,0,t.options.slBarSize[1]-1),a=t.slBarHelper.grabColor(i,o);t.slPointer.style.left=i-7+"px",t.slPointer.style.top=o-7+"px",t.onValueChanged("RGB",a)},i=function e(){document.removeEventListener("mousemove",r),document.removeEventListener("mouseup",e)};e.addEventListener("mousedown",(function(e){r(e),document.addEventListener("mousemove",r),document.addEventListener("mouseup",i)}))}},{key:"setupAlphaCanvas",value:function(e){var t=this;e.width=this.options.alphaBarSize[0],e.height=this.options.alphaBarSize[1];var r=e.getContext("2d"),i=r.createLinearGradient(0,0,e.width-1,0);i.addColorStop(0,"hsla(0, 0%, 50%, 0)"),i.addColorStop(1,"hsla(0, 0%, 50%, 1)"),r.fillStyle=i,r.fillRect(0,0,this.options.alphaBarSize[0],this.options.alphaBarSize[1]);var o=function(r){var i=(0,n.limit)(r.clientX-e.getBoundingClientRect().left,0,t.options.alphaBarSize[0]),o=+(i/t.options.alphaBarSize[0]).toFixed(2);t.alphaPointer.style.left=i-7+"px",t.onValueChanged("ALPHA",o)},a=function e(){document.removeEventListener("mousemove",o),document.removeEventListener("mouseup",e)};e.addEventListener("mousedown",(function(e){o(e),document.addEventListener("mousemove",o),document.addEventListener("mouseup",a)}))}},{key:"setupInput",value:function(e){var t=this,r=+e.min,i=+e.max,o=e.getAttribute("nameref");e.hasAttribute("select-on-focus")&&e.addEventListener("focus",(function(){e.select()})),"text"===e.type?e.addEventListener("change",(function(){t.onValueChanged(o,e.value)})):((h||p)&&e.addEventListener("keydown",(function(a){"Up"===a.key?(e.value=(0,n.limit)(+e.value+1,r,i),t.onValueChanged(o,e.value),a.returnValue=!1):"Down"===a.key&&(e.value=(0,n.limit)(+e.value-1,r,i),t.onValueChanged(o,e.value),a.returnValue=!1)})),e.addEventListener("change",(function(){t.onValueChanged(o,(0,n.limit)(+e.value,r,i))})))}},{key:"setupClipboard",value:function(e){var t=this;e.title="click to copy",e.addEventListener("click",(function(){e.value=(0,n.parseColor)([t.R,t.G,t.B,t.A],"hexcss4"),e.select(),document.execCommand("copy")}))}},{key:"setPalette",value:function(e){var t=this,r="auto"===this.options.useAlphaInPalette?this.options.showAlpha:this.options.useAlphaInPalette,i=null;switch(this.options.palette){case"PALETTE_MATERIAL_500":i=n.PALETTE_MATERIAL_500;break;case"PALETTE_MATERIAL_CHROME":i=n.PALETTE_MATERIAL_CHROME;break;default:i=(0,n.ensureArray)(this.options.palette)}if(this.options.paletteEditable||i.length>0){var o=function(r,i,o){var n=e.querySelector('.a-color-picker-palette-color[data-color="'+r+'"]')||document.createElement("div");n.className="a-color-picker-palette-color",n.style.backgroundColor=r,n.setAttribute("data-color",r),n.title=r,e.insertBefore(n,i),t.palette[r]=!0,o&&t.onPaletteColorAdd(r)},a=function(r,i){r?(e.removeChild(r),t.palette[r.getAttribute("data-color")]=!1,i&&t.onPaletteColorRemove(r.getAttribute("data-color"))):(e.querySelectorAll(".a-color-picker-palette-color[data-color]").forEach((function(t){e.removeChild(t)})),Object.keys(t.palette).forEach((function(e){t.palette[e]=!1})),i&&t.onPaletteColorRemove())};if(i.map((function(e){return(0,n.parseColor)(e,r?"rgbcss4":"hex")})).filter((function(e){return!!e})).forEach((function(e){return o(e)})),this.options.paletteEditable){var s=document.createElement("div");s.className="a-color-picker-palette-color a-color-picker-palette-add",s.innerHTML="+",e.appendChild(s),e.addEventListener("click",(function(e){/a-color-picker-palette-add/.test(e.target.className)?e.shiftKey?a(null,!0):o(r?(0,n.parseColor)([t.R,t.G,t.B,t.A],"rgbcss4"):(0,n.rgbToHex)(t.R,t.G,t.B),e.target,!0):/a-color-picker-palette-color/.test(e.target.className)&&(e.shiftKey?a(e.target,!0):t.onValueChanged(f,e.target.getAttribute("data-color")))}))}else e.addEventListener("click",(function(e){/a-color-picker-palette-color/.test(e.target.className)&&t.onValueChanged(f,e.target.getAttribute("data-color"))}))}else e.style.display="none"}},{key:"updatePalette",value:function(e){this.paletteRow.innerHTML="",this.palette={},this.paletteRow.parentElement||this.element.appendChild(this.paletteRow),this.options.palette=e,this.setPalette(this.paletteRow)}},{key:"onValueChanged",value:function(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{silent:!1};switch(e){case"H":this.H=t;var i=(0,n.hslToRgb)(this.H,this.S,this.L),a=o(i,3);this.R=a[0],this.G=a[1],this.B=a[2],this.slBarHelper.setHue(t),this.updatePointerH(this.H),this.updateInputHSL(this.H,this.S,this.L),this.updateInputRGB(this.R,this.G,this.B),this.updateInputRGBHEX(this.R,this.G,this.B);break;case"S":this.S=t;var s=(0,n.hslToRgb)(this.H,this.S,this.L),l=o(s,3);this.R=l[0],this.G=l[1],this.B=l[2],this.updatePointerSL(this.H,this.S,this.L),this.updateInputHSL(this.H,this.S,this.L),this.updateInputRGB(this.R,this.G,this.B),this.updateInputRGBHEX(this.R,this.G,this.B);break;case"L":this.L=t;var c=(0,n.hslToRgb)(this.H,this.S,this.L),u=o(c,3);this.R=u[0],this.G=u[1],this.B=u[2],this.updatePointerSL(this.H,this.S,this.L),this.updateInputHSL(this.H,this.S,this.L),this.updateInputRGB(this.R,this.G,this.B),this.updateInputRGBHEX(this.R,this.G,this.B);break;case"R":this.R=t;var h=(0,n.rgbToHsl)(this.R,this.G,this.B),p=o(h,3);this.H=p[0],this.S=p[1],this.L=p[2],this.slBarHelper.setHue(this.H),this.updatePointerH(this.H),this.updatePointerSL(this.H,this.S,this.L),this.updateInputHSL(this.H,this.S,this.L),this.updateInputRGBHEX(this.R,this.G,this.B);break;case"G":this.G=t;var d=(0,n.rgbToHsl)(this.R,this.G,this.B),v=o(d,3);this.H=v[0],this.S=v[1],this.L=v[2],this.slBarHelper.setHue(this.H),this.updatePointerH(this.H),this.updatePointerSL(this.H,this.S,this.L),this.updateInputHSL(this.H,this.S,this.L),this.updateInputRGBHEX(this.R,this.G,this.B);break;case"B":this.B=t;var m=(0,n.rgbToHsl)(this.R,this.G,this.B),y=o(m,3);this.H=y[0],this.S=y[1],this.L=y[2],this.slBarHelper.setHue(this.H),this.updatePointerH(this.H),this.updatePointerSL(this.H,this.S,this.L),this.updateInputHSL(this.H,this.S,this.L),this.updateInputRGBHEX(this.R,this.G,this.B);break;case"RGB":var A=o(t,3);this.R=A[0],this.G=A[1],this.B=A[2];var k=(0,n.rgbToHsl)(this.R,this.G,this.B),F=o(k,3);this.H=F[0],this.S=F[1],this.L=F[2],this.updateInputHSL(this.H,this.S,this.L),this.updateInputRGB(this.R,this.G,this.B),this.updateInputRGBHEX(this.R,this.G,this.B);break;case g:var E=o(t,4);this.R=E[0],this.G=E[1],this.B=E[2],this.A=E[3];var C=(0,n.rgbToHsl)(this.R,this.G,this.B),H=o(C,3);this.H=H[0],this.S=H[1],this.L=H[2],this.slBarHelper.setHue(this.H),this.updatePointerH(this.H),this.updatePointerSL(this.H,this.S,this.L),this.updateInputHSL(this.H,this.S,this.L),this.updateInputRGB(this.R,this.G,this.B),this.updateInputRGBHEX(this.R,this.G,this.B),this.updatePointerA(this.A);break;case b:var B=o(t,4);this.H=B[0],this.S=B[1],this.L=B[2],this.A=B[3];var R=(0,n.hslToRgb)(this.H,this.S,this.L),S=o(R,3);this.R=S[0],this.G=S[1],this.B=S[2],this.slBarHelper.setHue(this.H),this.updatePointerH(this.H),this.updatePointerSL(this.H,this.S,this.L),this.updateInputHSL(this.H,this.S,this.L),this.updateInputRGB(this.R,this.G,this.B),this.updateInputRGBHEX(this.R,this.G,this.B),this.updatePointerA(this.A);break;case"RGBHEX":var L=(0,n.cssColorToRgb)(t)||[this.R,this.G,this.B],w=o(L,3);this.R=w[0],this.G=w[1],this.B=w[2];var x=(0,n.rgbToHsl)(this.R,this.G,this.B),T=o(x,3);this.H=T[0],this.S=T[1],this.L=T[2],this.slBarHelper.setHue(this.H),this.updatePointerH(this.H),this.updatePointerSL(this.H,this.S,this.L),this.updateInputHSL(this.H,this.S,this.L),this.updateInputRGB(this.R,this.G,this.B);break;case f:var I=(0,n.parseColor)(t,"rgba")||[0,0,0,1],G=o(I,4);this.R=G[0],this.G=G[1],this.B=G[2],this.A=G[3];var P=(0,n.rgbToHsl)(this.R,this.G,this.B),_=o(P,3);this.H=_[0],this.S=_[1],this.L=_[2],this.slBarHelper.setHue(this.H),this.updatePointerH(this.H),this.updatePointerSL(this.H,this.S,this.L),this.updateInputHSL(this.H,this.S,this.L),this.updateInputRGB(this.R,this.G,this.B),this.updateInputRGBHEX(this.R,this.G,this.B),this.updatePointerA(this.A);break;case"ALPHA":this.A=t}this.preview.style.backgroundColor=1===this.A?"rgb("+this.R+","+this.G+","+this.B+")":"rgba("+this.R+","+this.G+","+this.B+","+this.A+")",r&&r.silent||this.onchange&&this.onchange(this.preview.style.backgroundColor)}},{key:"onPaletteColorAdd",value:function(e){this.oncoloradd&&this.oncoloradd(e)}},{key:"onPaletteColorRemove",value:function(e){this.oncolorremove&&this.oncolorremove(e)}},{key:"updateInputHSL",value:function(e,t,r){this.options.showHSL&&(this.inputH.value=e,this.inputS.value=t,this.inputL.value=r)}},{key:"updateInputRGB",value:function(e,t,r){this.options.showRGB&&(this.inputR.value=e,this.inputG.value=t,this.inputB.value=r)}},{key:"updateInputRGBHEX",value:function(e,t,r){this.options.showHEX&&(this.inputRGBHEX.value=(0,n.rgbToHex)(e,t,r))}},{key:"updatePointerH",value:function(e){this.huePointer.style.left=this.options.hueBarSize[0]*e/360-7+"px"}},{key:"updatePointerSL",value:function(e,t,r){var i=(0,n.hslToRgb)(e,t,r),a=o(i,3),s=this.slBarHelper.findColor(a[0],a[1],a[2]),l=o(s,2),c=l[0],u=l[1];c>=0&&(this.slPointer.style.left=c-7+"px",this.slPointer.style.top=u-7+"px")}},{key:"updatePointerA",value:function(e){this.options.showAlpha&&(this.alphaPointer.style.left=this.options.alphaBarSize[0]*e-7+"px")}}]),e}(),F=function(){function e(t){c(this,e),this.name=t,this.listeners=[]}return i(e,[{key:"on",value:function(e){e&&this.listeners.push(e)}},{key:"off",value:function(e){this.listeners=e?this.listeners.filter((function(t){return t!==e})):[]}},{key:"emit",value:function(e,t){for(var r=this.listeners.slice(0),i=0;r.length>i;i++)r[i].apply(t,e)}}]),e}();function E(e,t){var r=new k(e,t),i={change:new F("change"),coloradd:new F("coloradd"),colorremove:new F("colorremove")},a=!0,s={},l={get element(){return r.element},get rgb(){return[r.R,r.G,r.B]},set rgb(e){var t=o(e,3),i=t[0],a=t[1],s=t[2],l=[(0,n.limit)(i,0,255),(0,n.limit)(a,0,255),(0,n.limit)(s,0,255)];r.onValueChanged(g,[i=l[0],a=l[1],s=l[2],1])},get hsl(){return[r.H,r.S,r.L]},set hsl(e){var t=o(e,3),i=t[0],a=t[1],s=t[2],l=[(0,n.limit)(i,0,360),(0,n.limit)(a,0,100),(0,n.limit)(s,0,100)];r.onValueChanged(b,[i=l[0],a=l[1],s=l[2],1])},get rgbhex(){return this.all.hex},get rgba(){return[r.R,r.G,r.B,r.A]},set rgba(e){var t=o(e,4),i=t[0],a=t[1],s=t[2],l=t[3],c=[(0,n.limit)(i,0,255),(0,n.limit)(a,0,255),(0,n.limit)(s,0,255),(0,n.limit)(l,0,1)];r.onValueChanged(g,[i=c[0],a=c[1],s=c[2],l=c[3]])},get hsla(){return[r.H,r.S,r.L,r.A]},set hsla(e){var t=o(e,4),i=t[0],a=t[1],s=t[2],l=t[3],c=[(0,n.limit)(i,0,360),(0,n.limit)(a,0,100),(0,n.limit)(s,0,100),(0,n.limit)(l,0,1)];r.onValueChanged(b,[i=c[0],a=c[1],s=c[2],l=c[3]])},get color(){return this.all.toString()},set color(e){r.onValueChanged(f,e)},setColor:function(e){r.onValueChanged(f,e,{silent:arguments.length>1&&void 0!==arguments[1]&&arguments[1]})},get all(){if(a){var e=[r.R,r.G,r.B,r.A],t=1>r.A?"rgba("+r.R+","+r.G+","+r.B+","+r.A+")":n.rgbToHex.apply(void 0,e);(s=(0,n.parseColor)(e,s)).toString=function(){return t},a=!1}return Object.assign({},s)},get onchange(){return i.change&&i.change.listeners[0]},set onchange(e){this.off("change").on("change",e)},get oncoloradd(){return i.coloradd&&i.coloradd.listeners[0]},set oncoloradd(e){this.off("coloradd").on("coloradd",e)},get oncolorremove(){return i.colorremove&&i.colorremove.listeners[0]},set oncolorremove(e){this.off("colorremove").on("colorremove",e)},get palette(){return Object.keys(r.palette).filter((function(e){return r.palette[e]}))},set palette(e){r.updatePalette(e)},show:function(){r.element.classList.remove("hidden")},hide:function(){r.element.classList.add("hidden")},toggle:function(){r.element.classList.toggle("hidden")},on:function(e,t){return e&&i[e]&&i[e].on(t),this},off:function(e,t){return e&&i[e]&&i[e].off(t),this},destroy:function(){i.change.off(),i.coloradd.off(),i.colorremove.off(),r.element.remove(),i=null,r=null}};return r.onchange=function(){for(var e=arguments.length,t=Array(e),r=0;e>r;r++)t[r]=arguments[r];a=!0,i.change.emit([l].concat(t),l)},r.oncoloradd=function(){for(var e=arguments.length,t=Array(e),r=0;e>r;r++)t[r]=arguments[r];i.coloradd.emit([l].concat(t),l)},r.oncolorremove=function(){for(var e=arguments.length,t=Array(e),r=0;e>r;r++)t[r]=arguments[r];i.colorremove.emit([l].concat(t),l)},r.element.ctrl=l,l}if("undefined"!=typeof window&&!document.querySelector('head>style[data-source="a-color-picker"]')){var C=r(5).toString(),H=document.createElement("style");H.setAttribute("type","text/css"),H.setAttribute("data-source","a-color-picker"),H.innerHTML=C,document.querySelector("head").appendChild(H)}t.createPicker=E,t.from=function(e,t){var r=function(e){return e?Array.isArray(e)?e:e instanceof HTMLElement?[e]:e instanceof NodeList?[].concat(u(e)):"string"==typeof e?[].concat(u(document.querySelectorAll(e))):e.jquery?e.get():[]:[]}(e).map((function(e,r){var i=E(e,t);return i.index=r,i}));return r.on=function(e,t){return r.forEach((function(r){return r.on(e,t)})),this},r.off=function(e){return r.forEach((function(t){return t.off(e)})),this},r},t.parseColorToRgb=n.parseColorToRgb,t.parseColorToRgba=n.parseColorToRgba,t.parseColorToHsl=n.parseColorToHsl,t.parseColorToHsla=n.parseColorToHsla,t.parseColor=n.parseColor,t.rgbToHex=n.rgbToHex,t.hslToRgb=n.hslToRgb,t.rgbToHsl=n.rgbToHsl,t.rgbToHsv=n.rgbToHsv,t.rgbToInt=n.rgbToInt,t.intToRgb=n.intToRgb,t.getLuminance=n.getLuminance,t.COLOR_NAMES=n.COLOR_NAMES,t.PALETTE_MATERIAL_500=n.PALETTE_MATERIAL_500,t.PALETTE_MATERIAL_CHROME=n.PALETTE_MATERIAL_CHROME,t.VERSION="1.2.1"},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.nvl=t.ensureArray=t.limit=t.getLuminance=t.parseColor=t.parseColorToHsla=t.parseColorToHsl=t.cssHslaToHsla=t.cssHslToHsl=t.parseColorToRgba=t.parseColorToRgb=t.cssRgbaToRgba=t.cssRgbToRgb=t.cssColorToRgba=t.cssColorToRgb=t.intToRgb=t.rgbToInt=t.rgbToHsv=t.rgbToHsl=t.hslToRgb=t.rgbToHex=t.PALETTE_MATERIAL_CHROME=t.PALETTE_MATERIAL_500=t.COLOR_NAMES=void 0;var i=function(e,t){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return function(e,t){var r=[],i=!0,o=!1,n=void 0;try{for(var a,s=e[Symbol.iterator]();!(i=(a=s.next()).done)&&(r.push(a.value),!t||r.length!==t);i=!0);}catch(e){o=!0,n=e}finally{try{!i&&s.return&&s.return()}finally{if(o)throw n}}return r}(e,t);throw new TypeError("Invalid attempt to destructure non-iterable instance")},o=function(e){return e&&e.__esModule?e:{default:e}}(r(0));function n(e){if(Array.isArray(e)){for(var t=0,r=Array(e.length);e.length>t;t++)r[t]=e[t];return r}return Array.from(e)}var a={aliceblue:"#F0F8FF",antiquewhite:"#FAEBD7",aqua:"#00FFFF",aquamarine:"#7FFFD4",azure:"#F0FFFF",beige:"#F5F5DC",bisque:"#FFE4C4",black:"#000000",blanchedalmond:"#FFEBCD",blue:"#0000FF",blueviolet:"#8A2BE2",brown:"#A52A2A",burlywood:"#DEB887",cadetblue:"#5F9EA0",chartreuse:"#7FFF00",chocolate:"#D2691E",coral:"#FF7F50",cornflowerblue:"#6495ED",cornsilk:"#FFF8DC",crimson:"#DC143C",cyan:"#00FFFF",darkblue:"#00008B",darkcyan:"#008B8B",darkgoldenrod:"#B8860B",darkgray:"#A9A9A9",darkgrey:"#A9A9A9",darkgreen:"#006400",darkkhaki:"#BDB76B",darkmagenta:"#8B008B",darkolivegreen:"#556B2F",darkorange:"#FF8C00",darkorchid:"#9932CC",darkred:"#8B0000",darksalmon:"#E9967A",darkseagreen:"#8FBC8F",darkslateblue:"#483D8B",darkslategray:"#2F4F4F",darkslategrey:"#2F4F4F",darkturquoise:"#00CED1",darkviolet:"#9400D3",deeppink:"#FF1493",deepskyblue:"#00BFFF",dimgray:"#696969",dimgrey:"#696969",dodgerblue:"#1E90FF",firebrick:"#B22222",floralwhite:"#FFFAF0",forestgreen:"#228B22",fuchsia:"#FF00FF",gainsboro:"#DCDCDC",ghostwhite:"#F8F8FF",gold:"#FFD700",goldenrod:"#DAA520",gray:"#808080",grey:"#808080",green:"#008000",greenyellow:"#ADFF2F",honeydew:"#F0FFF0",hotpink:"#FF69B4","indianred ":"#CD5C5C","indigo ":"#4B0082",ivory:"#FFFFF0",khaki:"#F0E68C",lavender:"#E6E6FA",lavenderblush:"#FFF0F5",lawngreen:"#7CFC00",lemonchiffon:"#FFFACD",lightblue:"#ADD8E6",lightcoral:"#F08080",lightcyan:"#E0FFFF",lightgoldenrodyellow:"#FAFAD2",lightgray:"#D3D3D3",lightgrey:"#D3D3D3",lightgreen:"#90EE90",lightpink:"#FFB6C1",lightsalmon:"#FFA07A",lightseagreen:"#20B2AA",lightskyblue:"#87CEFA",lightslategray:"#778899",lightslategrey:"#778899",lightsteelblue:"#B0C4DE",lightyellow:"#FFFFE0",lime:"#00FF00",limegreen:"#32CD32",linen:"#FAF0E6",magenta:"#FF00FF",maroon:"#800000",mediumaquamarine:"#66CDAA",mediumblue:"#0000CD",mediumorchid:"#BA55D3",mediumpurple:"#9370DB",mediumseagreen:"#3CB371",mediumslateblue:"#7B68EE",mediumspringgreen:"#00FA9A",mediumturquoise:"#48D1CC",mediumvioletred:"#C71585",midnightblue:"#191970",mintcream:"#F5FFFA",mistyrose:"#FFE4E1",moccasin:"#FFE4B5",navajowhite:"#FFDEAD",navy:"#000080",oldlace:"#FDF5E6",olive:"#808000",olivedrab:"#6B8E23",orange:"#FFA500",orangered:"#FF4500",orchid:"#DA70D6",palegoldenrod:"#EEE8AA",palegreen:"#98FB98",paleturquoise:"#AFEEEE",palevioletred:"#DB7093",papayawhip:"#FFEFD5",peachpuff:"#FFDAB9",peru:"#CD853F",pink:"#FFC0CB",plum:"#DDA0DD",powderblue:"#B0E0E6",purple:"#800080",rebeccapurple:"#663399",red:"#FF0000",rosybrown:"#BC8F8F",royalblue:"#4169E1",saddlebrown:"#8B4513",salmon:"#FA8072",sandybrown:"#F4A460",seagreen:"#2E8B57",seashell:"#FFF5EE",sienna:"#A0522D",silver:"#C0C0C0",skyblue:"#87CEEB",slateblue:"#6A5ACD",slategray:"#708090",slategrey:"#708090",snow:"#FFFAFA",springgreen:"#00FF7F",steelblue:"#4682B4",tan:"#D2B48C",teal:"#008080",thistle:"#D8BFD8",tomato:"#FF6347",turquoise:"#40E0D0",violet:"#EE82EE",wheat:"#F5DEB3",white:"#FFFFFF",whitesmoke:"#F5F5F5",yellow:"#FFFF00",yellowgreen:"#9ACD32"};function s(e,t,r){return e=+e,isNaN(e)||t>e?t:e>r?r:e}function l(e,t){return null==e?t:e}function c(e,t,r){var i=[s(e,0,255),s(t,0,255),s(r,0,255)];return"#"+("000000"+((e=i[0])<<16|(t=i[1])<<8|(r=i[2])).toString(16)).slice(-6)}function u(e,t,r){var i=void 0,o=void 0,n=void 0,a=[s(e,0,360)/360,s(t,0,100)/100,s(r,0,100)/100];if(e=a[0],r=a[2],0==(t=a[1]))i=o=n=r;else{var l=function(e,t,r){return 0>r&&(r+=1),r>1&&(r-=1),1/6>r?e+6*(t-e)*r:.5>r?t:2/3>r?e+(t-e)*(2/3-r)*6:e},c=.5>r?r*(1+t):r+t-r*t,u=2*r-c;i=l(u,c,e+1/3),o=l(u,c,e),n=l(u,c,e-1/3)}return[255*i,255*o,255*n].map(Math.round)}function h(e,t,r){var i=[s(e,0,255)/255,s(t,0,255)/255,s(r,0,255)/255];e=i[0],t=i[1],r=i[2];var o=Math.max(e,t,r),n=Math.min(e,t,r),a=void 0,l=void 0,c=(o+n)/2;if(o==n)a=l=0;else{var u=o-n;switch(l=c>.5?u/(2-o-n):u/(o+n),o){case e:a=(t-r)/u+(r>t?6:0);break;case t:a=(r-e)/u+2;break;case r:a=(e-t)/u+4}a/=6}return[360*a,100*l,100*c].map(Math.round)}function p(e,t,r){return e<<16|t<<8|r}function d(e){if(e){var t=a[e.toString().toLowerCase()],r=/^\s*#?((([0-9A-F])([0-9A-F])([0-9A-F]))|(([0-9A-F]{2})([0-9A-F]{2})([0-9A-F]{2})))\s*$/i.exec(t||e)||[],o=i(r,10),n=o[3],s=o[4],l=o[5],c=o[7],u=o[8],h=o[9];if(void 0!==n)return[parseInt(n+n,16),parseInt(s+s,16),parseInt(l+l,16)];if(void 0!==c)return[parseInt(c,16),parseInt(u,16),parseInt(h,16)]}}function f(e){if(e){var t=a[e.toString().toLowerCase()],r=/^\s*#?((([0-9A-F])([0-9A-F])([0-9A-F])([0-9A-F])?)|(([0-9A-F]{2})([0-9A-F]{2})([0-9A-F]{2})([0-9A-F]{2})?))\s*$/i.exec(t||e)||[],o=i(r,12),n=o[3],s=o[4],l=o[5],c=o[6],u=o[8],h=o[9],p=o[10],d=o[11];if(void 0!==n)return[parseInt(n+n,16),parseInt(s+s,16),parseInt(l+l,16),c?+(parseInt(c+c,16)/255).toFixed(2):1];if(void 0!==u)return[parseInt(u,16),parseInt(h,16),parseInt(p,16),d?+(parseInt(d,16)/255).toFixed(2):1]}}function g(e){if(e){var t=/^rgb\((\d+)[\s,](\d+)[\s,](\d+)\)/i.exec(e)||[],r=i(t,4),o=r[2],n=r[3];return r[0]?[s(r[1],0,255),s(o,0,255),s(n,0,255)]:void 0}}function b(e){if(e){var t=/^rgba?\((\d+)\s*[\s,]\s*(\d+)\s*[\s,]\s*(\d+)(\s*[\s,]\s*(\d*(.\d+)?))?\)/i.exec(e)||[],r=i(t,6),o=r[2],n=r[3],a=r[5];return r[0]?[s(r[1],0,255),s(o,0,255),s(n,0,255),s(l(a,1),0,1)]:void 0}}function v(e){if(Array.isArray(e))return[s(e[0],0,255),s(e[1],0,255),s(e[2],0,255),s(l(e[3],1),0,1)];var t=f(e)||b(e);return t&&3===t.length&&t.push(1),t}function m(e){if(e){var t=/^hsl\((\d+)[\s,](\d+)[\s,](\d+)\)/i.exec(e)||[],r=i(t,4),o=r[2],n=r[3];return r[0]?[s(r[1],0,360),s(o,0,100),s(n,0,100)]:void 0}}function y(e){if(e){var t=/^hsla?\((\d+)\s*[\s,]\s*(\d+)\s*[\s,]\s*(\d+)(\s*[\s,]\s*(\d*(.\d+)?))?\)/i.exec(e)||[],r=i(t,6),o=r[2],n=r[3],a=r[5];return r[0]?[s(r[1],0,255),s(o,0,255),s(n,0,255),s(l(a,1),0,1)]:void 0}}function A(e){if(Array.isArray(e))return[s(e[0],0,360),s(e[1],0,100),s(e[2],0,100),s(l(e[3],1),0,1)];var t=y(e);return t&&3===t.length&&t.push(1),t}function k(e,t){switch(t){case"rgb":default:return e.slice(0,3);case"rgbcss":return"rgb("+e[0]+", "+e[1]+", "+e[2]+")";case"rgbcss4":return"rgb("+e[0]+", "+e[1]+", "+e[2]+", "+e[3]+")";case"rgba":return e;case"rgbacss":return"rgba("+e[0]+", "+e[1]+", "+e[2]+", "+e[3]+")";case"hsl":return h.apply(void 0,n(e));case"hslcss":return"hsl("+(e=h.apply(void 0,n(e)))[0]+", "+e[1]+", "+e[2]+")";case"hslcss4":var r=h.apply(void 0,n(e));return"hsl("+r[0]+", "+r[1]+", "+r[2]+", "+e[3]+")";case"hsla":return[].concat(n(h.apply(void 0,n(e))),[e[3]]);case"hslacss":var i=h.apply(void 0,n(e));return"hsla("+i[0]+", "+i[1]+", "+i[2]+", "+e[3]+")";case"hex":return c.apply(void 0,n(e));case"hexcss4":return c.apply(void 0,n(e))+("00"+parseInt(255*e[3]).toString(16)).slice(-2);case"int":return p.apply(void 0,n(e))}}t.COLOR_NAMES=a,t.PALETTE_MATERIAL_500=["#F44336","#E91E63","#E91E63","#9C27B0","#9C27B0","#673AB7","#673AB7","#3F51B5","#3F51B5","#2196F3","#2196F3","#03A9F4","#03A9F4","#00BCD4","#00BCD4","#009688","#009688","#4CAF50","#4CAF50","#8BC34A","#8BC34A","#CDDC39","#CDDC39","#FFEB3B","#FFEB3B","#FFC107","#FFC107","#FF9800","#FF9800","#FF5722","#FF5722","#795548","#795548","#9E9E9E","#9E9E9E","#607D8B","#607D8B"],t.PALETTE_MATERIAL_CHROME=["#f44336","#e91e63","#9c27b0","#673ab7","#3f51b5","#2196f3","#03a9f4","#00bcd4","#009688","#4caf50","#8bc34a","#cddc39","#ffeb3b","#ffc107","#ff9800","#ff5722","#795548","#9e9e9e","#607d8b"],t.rgbToHex=c,t.hslToRgb=u,t.rgbToHsl=h,t.rgbToHsv=function(e,t,r){var i=[s(e,0,255)/255,s(t,0,255)/255,s(r,0,255)/255];e=i[0],t=i[1],r=i[2];var o,n=Math.max(e,t,r),a=Math.min(e,t,r),l=void 0,c=n,u=n-a;if(o=0===n?0:u/n,n==a)l=0;else{switch(n){case e:l=(t-r)/u+(r>t?6:0);break;case t:l=(r-e)/u+2;break;case r:l=(e-t)/u+4}l/=6}return[l,o,c]},t.rgbToInt=p,t.intToRgb=function(e){return[e>>16&255,e>>8&255,255&e]},t.cssColorToRgb=d,t.cssColorToRgba=f,t.cssRgbToRgb=g,t.cssRgbaToRgba=b,t.parseColorToRgb=function(e){return Array.isArray(e)?e=[s(e[0],0,255),s(e[1],0,255),s(e[2],0,255)]:d(e)||g(e)},t.parseColorToRgba=v,t.cssHslToHsl=m,t.cssHslaToHsla=y,t.parseColorToHsl=function(e){return Array.isArray(e)?e=[s(e[0],0,360),s(e[1],0,100),s(e[2],0,100)]:m(e)},t.parseColorToHsla=A,t.parseColor=function(e,t){if(t=t||"rgb",null!=e){var r=void 0;if((r=v(e))||(r=A(e))&&(r=[].concat(n(u.apply(void 0,n(r))),[r[3]])))return(0,o.default)(t)?["rgb","rgbcss","rgbcss4","rgba","rgbacss","hsl","hslcss","hslcss4","hsla","hslacss","hex","hexcss4","int"].reduce((function(e,t){return e[t]=k(r,t),e}),t||{}):k(r,t.toString().toLowerCase())}},t.getLuminance=function(e,t,r){return.2126*(e=.03928>(e/=255)?e/12.92:Math.pow((e+.055)/1.055,2.4))+.7152*(t=.03928>(t/=255)?t/12.92:Math.pow((t+.055)/1.055,2.4))+.0722*(.03928>(r/=255)?r/12.92:Math.pow((r+.055)/1.055,2.4))},t.limit=s,t.ensureArray=function(e){return e?Array.from(e):[]},t.nvl=l},function(e,t,r){"use strict";e.exports=function(e){return null!=e&&"object"==typeof e&&!1===Array.isArray(e)}},function(e,t){e.exports='<div class="a-color-picker-row a-color-picker-stack a-color-picker-row-top"> <canvas class="a-color-picker-sl a-color-picker-transparent"></canvas> <div class=a-color-picker-dot></div> </div> <div class=a-color-picker-row> <div class="a-color-picker-stack a-color-picker-transparent a-color-picker-circle"> <div class=a-color-picker-preview> <input class=a-color-picker-clipbaord type=text> </div> </div> <div class=a-color-picker-column> <div class="a-color-picker-cell a-color-picker-stack"> <canvas class=a-color-picker-h></canvas> <div class=a-color-picker-dot></div> </div> <div class="a-color-picker-cell a-color-picker-alpha a-color-picker-stack" show-on-alpha> <canvas class="a-color-picker-a a-color-picker-transparent"></canvas> <div class=a-color-picker-dot></div> </div> </div> </div> <div class="a-color-picker-row a-color-picker-hsl" show-on-hsl> <label>H</label> <input nameref=H type=number maxlength=3 min=0 max=360 value=0> <label>S</label> <input nameref=S type=number maxlength=3 min=0 max=100 value=0> <label>L</label> <input nameref=L type=number maxlength=3 min=0 max=100 value=0> </div> <div class="a-color-picker-row a-color-picker-rgb" show-on-rgb> <label>R</label> <input nameref=R type=number maxlength=3 min=0 max=255 value=0> <label>G</label> <input nameref=G type=number maxlength=3 min=0 max=255 value=0> <label>B</label> <input nameref=B type=number maxlength=3 min=0 max=255 value=0> </div> <div class="a-color-picker-row a-color-picker-rgbhex a-color-picker-single-input" show-on-single-input> <label>HEX</label> <input nameref=RGBHEX type=text select-on-focus> </div> <div class="a-color-picker-row a-color-picker-palette"></div>'},function(e,t,r){var i=r(6);e.exports="string"==typeof i?i:i.toString()},function(e,t,r){(e.exports=r(7)(!1)).push([e.i,"/*!\n * a-color-picker\n * https://github.com/narsenico/a-color-picker\n *\n * Copyright (c) 2017-2018, Gianfranco Caldi.\n * Released under the MIT License.\n */.a-color-picker{background-color:#fff;padding:0;display:inline-flex;flex-direction:column;user-select:none;width:232px;font:400 10px Helvetica,Arial,sans-serif;border-radius:3px;box-shadow:0 0 0 1px rgba(0,0,0,.05),0 2px 4px rgba(0,0,0,.25)}.a-color-picker,.a-color-picker-row,.a-color-picker input{box-sizing:border-box}.a-color-picker-row{padding:15px;display:flex;flex-direction:row;align-items:center;justify-content:space-between;user-select:none}.a-color-picker-row-top{padding:0}.a-color-picker-row:not(:first-child){border-top:1px solid #f5f5f5}.a-color-picker-column{display:flex;flex-direction:column}.a-color-picker-cell{flex:1 1 auto;margin-bottom:4px}.a-color-picker-cell:last-child{margin-bottom:0}.a-color-picker-stack{position:relative}.a-color-picker-dot{position:absolute;width:14px;height:14px;top:0;left:0;background:#fff;pointer-events:none;border-radius:50px;z-index:1000;box-shadow:0 1px 2px rgba(0,0,0,.75)}.a-color-picker-a,.a-color-picker-h,.a-color-picker-sl{cursor:cell}.a-color-picker-a+.a-color-picker-dot,.a-color-picker-h+.a-color-picker-dot{top:-2px}.a-color-picker-a,.a-color-picker-h{border-radius:2px}.a-color-picker-preview{box-sizing:border-box;width:30px;height:30px;user-select:none;border-radius:15px}.a-color-picker-circle{border-radius:50px;border:1px solid #eee}.a-color-picker-hsl,.a-color-picker-rgb,.a-color-picker-single-input{justify-content:space-evenly}.a-color-picker-hsl>label,.a-color-picker-rgb>label,.a-color-picker-single-input>label{padding:0 8px;flex:0 0 auto;color:#969696}.a-color-picker-hsl>input,.a-color-picker-rgb>input,.a-color-picker-single-input>input{text-align:center;padding:2px 0;width:0;flex:1 1 auto;border:1px solid #e0e0e0;line-height:20px}.a-color-picker-hsl>input::-webkit-inner-spin-button,.a-color-picker-rgb>input::-webkit-inner-spin-button,.a-color-picker-single-input>input::-webkit-inner-spin-button{-webkit-appearance:none;margin:0}.a-color-picker-hsl>input:focus,.a-color-picker-rgb>input:focus,.a-color-picker-single-input>input:focus{border-color:#04a9f4;outline:none}.a-color-picker-transparent{background-image:linear-gradient(-45deg,#cdcdcd 25%,transparent 0),linear-gradient(45deg,#cdcdcd 25%,transparent 0),linear-gradient(-45deg,transparent 75%,#cdcdcd 0),linear-gradient(45deg,transparent 75%,#cdcdcd 0);background-size:11px 11px;background-position:0 0,0 -5.5px,-5.5px 5.5px,5.5px 0}.a-color-picker-sl{border-radius:3px 3px 0 0}.a-color-picker.hide-alpha [show-on-alpha],.a-color-picker.hide-hsl [show-on-hsl],.a-color-picker.hide-rgb [show-on-rgb],.a-color-picker.hide-single-input [show-on-single-input]{display:none}.a-color-picker-clipbaord{width:100%;height:100%;opacity:0;cursor:pointer}.a-color-picker-palette{flex-flow:wrap;flex-direction:row;justify-content:flex-start;padding:10px}.a-color-picker-palette-color{width:15px;height:15px;flex:0 1 15px;margin:3px;box-sizing:border-box;cursor:pointer;border-radius:3px;box-shadow:inset 0 0 0 1px rgba(0,0,0,.1)}.a-color-picker-palette-add{text-align:center;line-height:13px;color:#607d8b}.a-color-picker.hidden{display:none}",""])},function(e,t){e.exports=function(e){var t=[];return t.toString=function(){return this.map((function(t){var r=function(e,t){var r=e[1]||"",i=e[3];if(!i)return r;if(t&&"function"==typeof btoa){var o=function(e){return"/*# sourceMappingURL=data:application/json;charset=utf-8;base64,"+btoa(unescape(encodeURIComponent(JSON.stringify(e))))+" */"}(i),n=i.sources.map((function(e){return"/*# sourceURL="+i.sourceRoot+e+" */"}));return[r].concat(n).concat([o]).join("\n")}return[r].join("\n")}(t,e);return t[2]?"@media "+t[2]+"{"+r+"}":r})).join("")},t.i=function(e,r){"string"==typeof e&&(e=[[null,e,""]]);for(var i={},o=0;this.length>o;o++){var n=this[o][0];"number"==typeof n&&(i[n]=!0)}for(o=0;e.length>o;o++){var a=e[o];"number"==typeof a[0]&&i[a[0]]||(r&&!a[2]?a[2]=r:r&&(a[2]="("+a[2]+") and ("+r+")"),t.push(a))}},t}}])},524:(e,t,r)=>{"use strict";r.r(t)},522:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.colorPicker=void 0;var i=r(1),o=r(187),n=r(14),a=r(523),s=r(103),l=r(2),c=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.requires=["license"],t.hasStyle=!l.Jodit.fatMode,t}return i.__extends(t,e),t.prototype.afterInit=function(e){e.e.on("afterGenerateColorPicker",this.onAfterGenerateColorPicker)},t.prototype.onAfterGenerateColorPicker=function(e,t,r,i){n.Dom.detach(t);var o=new a.ColorInput(this.j,r);o.value=i||"#000",t.appendChild(o.container)},t.prototype.beforeDestruct=function(e){e.e.off("afterGenerateColorPicker",this.onAfterGenerateColorPicker)},i.__decorate([s.autobind],t.prototype,"onAfterGenerateColorPicker",null),t}(o.Plugin);t.colorPicker=c,l.Jodit.plugins.add("color-picker",c)},523:(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ColorInput=void 0;var i=r(1);r(524);var o=r(79),n=r(103),a=r(23),s=r(525),l=r(14),c=function(e){function t(t,r){var i=e.call(this,t)||this,n=new o.Popup(t);i.trigger.onAction((function(){r(i.value),n.close()})),n.setMod("padding",!1).setMod("max-height",!1);var c=i.j.create.div(i.getFullElName("picker")),u=s.createPicker(c,{paletteEditable:!0,showAlpha:!0,palette:"PALETTE_MATERIAL_CHROME"}).on("change",(function(e,t){i.isFocused||(i.value=s.parseColor(t||"","hex"))}));return i.j.e.on(i,"change",(function(){s.parseColor(i.value,"hex")!==u.color&&(u.color=i.value)})),n.setContent(c),i.j.e.on(i.nativeInput,"click",(function(){n.parentElement=i,i.jodit instanceof l.Dialog&&n.setZIndex(i.jodit.getZIndex()+1),n.open((function(){return a.position(i.container)}))})),i}return i.__extends(t,e),t.prototype.className=function(){return"ColorInput"},t.prototype.createContainer=function(t){var r=e.prototype.createContainer.call(this,t);return this.trigger=o.Button(this.j,"ok"),r.appendChild(this.trigger.container),this.trigger.container.classList.add(this.getFullElName("trigger")),r},t.prototype.setMod=function(t,r,i){return void 0===i&&(i=this.container),"slim"===t&&r&&this.nativeInput.setAttribute("readonly","true"),e.prototype.setMod.call(this,t,r,i)},t.prototype.onChangeSelfValue=function(){this.nativeInput.style.backgroundColor=this.value},i.__decorate([n.watch(":change")],t.prototype,"onChangeSelfValue",null),i.__decorate([n.component],t)}(o.UIInput);t.ColorInput=c}},e=>{"use strict";return e(e.s=522)}])}));
/*!
* jodit-pro - PRO Version of Jodit Editor
* Author: Chupurnov Valeriy <chupurnov@gmail.com>
* Version: v1.0.45
* Version: v1.0.46
* Url: https://xdsoft.net/jodit/pro/

@@ -10,2 +10,2 @@ * License(s): SEE LICENSE IN LICENSE.md

((e,t)=>{if("object"==typeof exports&&"object"==typeof module)module.exports=t();else if("function"==typeof define&&define.amd)define([],t);else{var r=t();for(var i in r)("object"==typeof exports?exports:e)[i]=r[i]}})(self,(function(){return(self.webpackChunkjodit_pro=self.webpackChunkjodit_pro||[]).push([[652],{204(e){"undefined"!=typeof self&&self,e.exports=(e=>{var t={};function r(i){if(t[i])return t[i].exports;var o=t[i]={i,l:!1,exports:{}};return e[i].call(o.exports,o,o.exports,r),o.l=!0,o.exports}return r.m=e,r.c=t,r.d=(e,t,i)=>{r.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:i})},r.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},r.t=(e,t)=>{if(1&t&&(e=r(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var i=Object.create(null);if(r.r(i),Object.defineProperty(i,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var o in e)r.d(i,o,(t=>e[t]).bind(null,o));return i},r.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return r.d(t,"a",t),t},r.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),r.p="",r(r.s=1)})([(e,t,r)=>{"use strict";var i=r(3);function o(e){return!0===i(e)&&"[object Object]"===Object.prototype.toString.call(e)}e.exports=e=>{var t,r;return!1!==o(e)&&"function"==typeof(t=e.constructor)&&!1!==o(r=t.prototype)&&!1!==r.hasOwnProperty("isPrototypeOf")}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.VERSION=t.PALETTE_MATERIAL_CHROME=t.PALETTE_MATERIAL_500=t.COLOR_NAMES=t.getLuminance=t.intToRgb=t.rgbToInt=t.rgbToHsv=t.rgbToHsl=t.hslToRgb=t.rgbToHex=t.parseColor=t.parseColorToHsla=t.parseColorToHsl=t.parseColorToRgba=t.parseColorToRgb=t.from=t.createPicker=void 0;var i=(()=>{function e(e,t){for(var r=0;t.length>r;r++){var i=t[r];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,i.key,i)}}return(t,r,i)=>(r&&e(t.prototype,r),i&&e(t,i),t)})(),o=(e,t)=>{if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return((e,t)=>{var r=[],i=!0,o=!1,s=void 0;try{for(var a,n=e[Symbol.iterator]();!(i=(a=n.next()).done)&&(r.push(a.value),!t||r.length!==t);i=!0);}catch(e){o=!0,s=e}finally{try{!i&&n.return&&n.return()}finally{if(o)throw s}}return r})(e,t);throw new TypeError("Invalid attempt to destructure non-iterable instance")},s=r(2),a=l(r(0)),n=l(r(4));function l(e){return e&&e.__esModule?e:{default:e}}function h(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function c(e){if(Array.isArray(e)){for(var t=0,r=Array(e.length);e.length>t;t++)r[t]=e[t];return r}return Array.from(e)}var p="undefined"!=typeof window&&window.navigator.userAgent.indexOf("Edge")>-1,u="undefined"!=typeof window&&window.navigator.userAgent.indexOf("rv:")>-1,d={id:null,attachTo:"body",showHSL:!0,showRGB:!0,showHEX:!0,showAlpha:!1,color:"#ff0000",palette:null,paletteEditable:!1,useAlphaInPalette:"auto",slBarSize:[232,150],hueBarSize:[150,11],alphaBarSize:[150,11]},g="COLOR",b="RGBA_USER",v="HSLA_USER";function f(e,t,r){return e?e instanceof HTMLElement?e:e instanceof NodeList?e[0]:"string"==typeof e?document.querySelector(e):e.jquery?e.get(0):r?t:null:t}function m(e){var t=e.getContext("2d"),r=+e.width,i=+e.height,a=t.createLinearGradient(1,1,1,i-1);return a.addColorStop(0,"white"),a.addColorStop(1,"black"),{setHue(e){var o=t.createLinearGradient(1,0,r-1,0);o.addColorStop(0,"hsla("+e+", 100%, 50%, 0)"),o.addColorStop(1,"hsla("+e+", 100%, 50%, 1)"),t.fillStyle=a,t.fillRect(0,0,r,i),t.fillStyle=o,t.globalCompositeOperation="multiply",t.fillRect(0,0,r,i),t.globalCompositeOperation="source-over"},grabColor:(e,r)=>t.getImageData(e,r,1,1).data,findColor(e,t,a){var n=(0,s.rgbToHsv)(e,t,a),l=o(n,3);return[l[1]*r,i-l[2]*i]}}}function A(e,t,r){return null===e?t:/^\s*$/.test(e)?r:!!/true|yes|1/i.test(e)||!/false|no|0/i.test(e)&&t}function y(e,t,r){if(null===e)return t;if(/^\s*$/.test(e))return r;var i=e.split(",").map(Number);return 2===i.length&&i[0]&&i[1]?i:t}var k=function(){function e(t,r){if(h(this,e),r?(t=f(t),this.options=Object.assign({},d,r)):t&&(0,a.default)(t)?(this.options=Object.assign({},d,t),t=f(this.options.attachTo)):(this.options=Object.assign({},d),t=f((0,s.nvl)(t,this.options.attachTo))),!t)throw Error("Container not found: "+this.options.attachTo);!function(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"acp-";if(t.hasAttribute(r+"show-hsl")&&(e.showHSL=A(t.getAttribute(r+"show-hsl"),d.showHSL,!0)),t.hasAttribute(r+"show-rgb")&&(e.showRGB=A(t.getAttribute(r+"show-rgb"),d.showRGB,!0)),t.hasAttribute(r+"show-hex")&&(e.showHEX=A(t.getAttribute(r+"show-hex"),d.showHEX,!0)),t.hasAttribute(r+"show-alpha")&&(e.showAlpha=A(t.getAttribute(r+"show-alpha"),d.showAlpha,!0)),t.hasAttribute(r+"palette-editable")&&(e.paletteEditable=A(t.getAttribute(r+"palette-editable"),d.paletteEditable,!0)),t.hasAttribute(r+"sl-bar-size")&&(e.slBarSize=y(t.getAttribute(r+"sl-bar-size"),d.slBarSize,[232,150])),t.hasAttribute(r+"hue-bar-size")&&(e.hueBarSize=y(t.getAttribute(r+"hue-bar-size"),d.hueBarSize,[150,11]),e.alphaBarSize=e.hueBarSize),t.hasAttribute(r+"palette")){var i=t.getAttribute(r+"palette");switch(i){case"PALETTE_MATERIAL_500":e.palette=s.PALETTE_MATERIAL_500;break;case"PALETTE_MATERIAL_CHROME":case"":e.palette=s.PALETTE_MATERIAL_CHROME;break;default:e.palette=i.split(/[;|]/)}}t.hasAttribute(r+"color")&&(e.color=t.getAttribute(r+"color"))}(this.options,t),this.H=0,this.S=0,this.L=0,this.R=0,this.G=0,this.B=0,this.A=1,this.palette={},this.element=document.createElement("div"),this.options.id&&(this.element.id=this.options.id),this.element.className="a-color-picker",this.element.innerHTML=n.default,t.appendChild(this.element);var i=this.element.querySelector(".a-color-picker-h");this.setupHueCanvas(i),this.hueBarHelper=m(i),this.huePointer=this.element.querySelector(".a-color-picker-h+.a-color-picker-dot");var o=this.element.querySelector(".a-color-picker-sl");this.setupSlCanvas(o),this.slBarHelper=m(o),this.slPointer=this.element.querySelector(".a-color-picker-sl+.a-color-picker-dot"),this.preview=this.element.querySelector(".a-color-picker-preview"),this.setupClipboard(this.preview.querySelector(".a-color-picker-clipbaord")),this.options.showHSL?(this.setupInput(this.inputH=this.element.querySelector(".a-color-picker-hsl>input[nameref=H]")),this.setupInput(this.inputS=this.element.querySelector(".a-color-picker-hsl>input[nameref=S]")),this.setupInput(this.inputL=this.element.querySelector(".a-color-picker-hsl>input[nameref=L]"))):this.element.querySelector(".a-color-picker-hsl").remove(),this.options.showRGB?(this.setupInput(this.inputR=this.element.querySelector(".a-color-picker-rgb>input[nameref=R]")),this.setupInput(this.inputG=this.element.querySelector(".a-color-picker-rgb>input[nameref=G]")),this.setupInput(this.inputB=this.element.querySelector(".a-color-picker-rgb>input[nameref=B]"))):this.element.querySelector(".a-color-picker-rgb").remove(),this.options.showHEX?this.setupInput(this.inputRGBHEX=this.element.querySelector("input[nameref=RGBHEX]")):this.element.querySelector(".a-color-picker-rgbhex").remove(),this.options.paletteEditable||this.options.palette&&this.options.palette.length>0?this.setPalette(this.paletteRow=this.element.querySelector(".a-color-picker-palette")):(this.paletteRow=this.element.querySelector(".a-color-picker-palette"),this.paletteRow.remove()),this.options.showAlpha?(this.setupAlphaCanvas(this.element.querySelector(".a-color-picker-a")),this.alphaPointer=this.element.querySelector(".a-color-picker-a+.a-color-picker-dot")):this.element.querySelector(".a-color-picker-alpha").remove(),this.element.style.width=this.options.slBarSize[0]+"px",this.onValueChanged(g,this.options.color)}return i(e,[{key:"setupHueCanvas",value(e){var t=this;e.width=this.options.hueBarSize[0],e.height=this.options.hueBarSize[1];for(var r=e.getContext("2d"),i=r.createLinearGradient(0,0,this.options.hueBarSize[0],0),o=0;1>=o;o+=1/360)i.addColorStop(o,"hsl("+360*o+", 100%, 50%)");r.fillStyle=i,r.fillRect(0,0,this.options.hueBarSize[0],this.options.hueBarSize[1]);var a=r=>{var i=(0,s.limit)(r.clientX-e.getBoundingClientRect().left,0,t.options.hueBarSize[0]),o=Math.round(360*i/t.options.hueBarSize[0]);t.huePointer.style.left=i-7+"px",t.onValueChanged("H",o)},n=function e(){document.removeEventListener("mousemove",a),document.removeEventListener("mouseup",e)};e.addEventListener("mousedown",(e=>{a(e),document.addEventListener("mousemove",a),document.addEventListener("mouseup",n)}))}},{key:"setupSlCanvas",value(e){var t=this;e.width=this.options.slBarSize[0],e.height=this.options.slBarSize[1];var r=r=>{var i=(0,s.limit)(r.clientX-e.getBoundingClientRect().left,0,t.options.slBarSize[0]-1),o=(0,s.limit)(r.clientY-e.getBoundingClientRect().top,0,t.options.slBarSize[1]-1),a=t.slBarHelper.grabColor(i,o);t.slPointer.style.left=i-7+"px",t.slPointer.style.top=o-7+"px",t.onValueChanged("RGB",a)},i=function e(){document.removeEventListener("mousemove",r),document.removeEventListener("mouseup",e)};e.addEventListener("mousedown",(e=>{r(e),document.addEventListener("mousemove",r),document.addEventListener("mouseup",i)}))}},{key:"setupAlphaCanvas",value(e){var t=this;e.width=this.options.alphaBarSize[0],e.height=this.options.alphaBarSize[1];var r=e.getContext("2d"),i=r.createLinearGradient(0,0,e.width-1,0);i.addColorStop(0,"hsla(0, 0%, 50%, 0)"),i.addColorStop(1,"hsla(0, 0%, 50%, 1)"),r.fillStyle=i,r.fillRect(0,0,this.options.alphaBarSize[0],this.options.alphaBarSize[1]);var o=r=>{var i=(0,s.limit)(r.clientX-e.getBoundingClientRect().left,0,t.options.alphaBarSize[0]),o=+(i/t.options.alphaBarSize[0]).toFixed(2);t.alphaPointer.style.left=i-7+"px",t.onValueChanged("ALPHA",o)},a=function e(){document.removeEventListener("mousemove",o),document.removeEventListener("mouseup",e)};e.addEventListener("mousedown",(e=>{o(e),document.addEventListener("mousemove",o),document.addEventListener("mouseup",a)}))}},{key:"setupInput",value(e){var t=this,r=+e.min,i=+e.max,o=e.getAttribute("nameref");e.hasAttribute("select-on-focus")&&e.addEventListener("focus",(()=>{e.select()})),"text"===e.type?e.addEventListener("change",(()=>{t.onValueChanged(o,e.value)})):((p||u)&&e.addEventListener("keydown",(a=>{"Up"===a.key?(e.value=(0,s.limit)(+e.value+1,r,i),t.onValueChanged(o,e.value),a.returnValue=!1):"Down"===a.key&&(e.value=(0,s.limit)(+e.value-1,r,i),t.onValueChanged(o,e.value),a.returnValue=!1)})),e.addEventListener("change",(()=>{t.onValueChanged(o,(0,s.limit)(+e.value,r,i))})))}},{key:"setupClipboard",value(e){var t=this;e.title="click to copy",e.addEventListener("click",(()=>{e.value=(0,s.parseColor)([t.R,t.G,t.B,t.A],"hexcss4"),e.select(),document.execCommand("copy")}))}},{key:"setPalette",value(e){var t=this,r="auto"===this.options.useAlphaInPalette?this.options.showAlpha:this.options.useAlphaInPalette,i=null;switch(this.options.palette){case"PALETTE_MATERIAL_500":i=s.PALETTE_MATERIAL_500;break;case"PALETTE_MATERIAL_CHROME":i=s.PALETTE_MATERIAL_CHROME;break;default:i=(0,s.ensureArray)(this.options.palette)}if(this.options.paletteEditable||i.length>0){var o=(r,i,o)=>{var s=e.querySelector('.a-color-picker-palette-color[data-color="'+r+'"]')||document.createElement("div");s.className="a-color-picker-palette-color",s.style.backgroundColor=r,s.setAttribute("data-color",r),s.title=r,e.insertBefore(s,i),t.palette[r]=!0,o&&t.onPaletteColorAdd(r)},a=(r,i)=>{r?(e.removeChild(r),t.palette[r.getAttribute("data-color")]=!1,i&&t.onPaletteColorRemove(r.getAttribute("data-color"))):(e.querySelectorAll(".a-color-picker-palette-color[data-color]").forEach((t=>{e.removeChild(t)})),Object.keys(t.palette).forEach((e=>{t.palette[e]=!1})),i&&t.onPaletteColorRemove())};if(i.map((e=>(0,s.parseColor)(e,r?"rgbcss4":"hex"))).filter((e=>!!e)).forEach((e=>o(e))),this.options.paletteEditable){var n=document.createElement("div");n.className="a-color-picker-palette-color a-color-picker-palette-add",n.innerHTML="+",e.appendChild(n),e.addEventListener("click",(e=>{/a-color-picker-palette-add/.test(e.target.className)?e.shiftKey?a(null,!0):o(r?(0,s.parseColor)([t.R,t.G,t.B,t.A],"rgbcss4"):(0,s.rgbToHex)(t.R,t.G,t.B),e.target,!0):/a-color-picker-palette-color/.test(e.target.className)&&(e.shiftKey?a(e.target,!0):t.onValueChanged(g,e.target.getAttribute("data-color")))}))}else e.addEventListener("click",(e=>{/a-color-picker-palette-color/.test(e.target.className)&&t.onValueChanged(g,e.target.getAttribute("data-color"))}))}else e.style.display="none"}},{key:"updatePalette",value(e){this.paletteRow.innerHTML="",this.palette={},this.paletteRow.parentElement||this.element.appendChild(this.paletteRow),this.options.palette=e,this.setPalette(this.paletteRow)}},{key:"onValueChanged",value(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{silent:!1};switch(e){case"H":this.H=t;var i=(0,s.hslToRgb)(this.H,this.S,this.L),a=o(i,3);this.R=a[0],this.G=a[1],this.B=a[2],this.slBarHelper.setHue(t),this.updatePointerH(this.H),this.updateInputHSL(this.H,this.S,this.L),this.updateInputRGB(this.R,this.G,this.B),this.updateInputRGBHEX(this.R,this.G,this.B);break;case"S":this.S=t;var n=(0,s.hslToRgb)(this.H,this.S,this.L),l=o(n,3);this.R=l[0],this.G=l[1],this.B=l[2],this.updatePointerSL(this.H,this.S,this.L),this.updateInputHSL(this.H,this.S,this.L),this.updateInputRGB(this.R,this.G,this.B),this.updateInputRGBHEX(this.R,this.G,this.B);break;case"L":this.L=t;var h=(0,s.hslToRgb)(this.H,this.S,this.L),c=o(h,3);this.R=c[0],this.G=c[1],this.B=c[2],this.updatePointerSL(this.H,this.S,this.L),this.updateInputHSL(this.H,this.S,this.L),this.updateInputRGB(this.R,this.G,this.B),this.updateInputRGBHEX(this.R,this.G,this.B);break;case"R":this.R=t;var p=(0,s.rgbToHsl)(this.R,this.G,this.B),u=o(p,3);this.H=u[0],this.S=u[1],this.L=u[2],this.slBarHelper.setHue(this.H),this.updatePointerH(this.H),this.updatePointerSL(this.H,this.S,this.L),this.updateInputHSL(this.H,this.S,this.L),this.updateInputRGBHEX(this.R,this.G,this.B);break;case"G":this.G=t;var d=(0,s.rgbToHsl)(this.R,this.G,this.B),f=o(d,3);this.H=f[0],this.S=f[1],this.L=f[2],this.slBarHelper.setHue(this.H),this.updatePointerH(this.H),this.updatePointerSL(this.H,this.S,this.L),this.updateInputHSL(this.H,this.S,this.L),this.updateInputRGBHEX(this.R,this.G,this.B);break;case"B":this.B=t;var m=(0,s.rgbToHsl)(this.R,this.G,this.B),A=o(m,3);this.H=A[0],this.S=A[1],this.L=A[2],this.slBarHelper.setHue(this.H),this.updatePointerH(this.H),this.updatePointerSL(this.H,this.S,this.L),this.updateInputHSL(this.H,this.S,this.L),this.updateInputRGBHEX(this.R,this.G,this.B);break;case"RGB":var y=o(t,3);this.R=y[0],this.G=y[1],this.B=y[2];var k=(0,s.rgbToHsl)(this.R,this.G,this.B),F=o(k,3);this.H=F[0],this.S=F[1],this.L=F[2],this.updateInputHSL(this.H,this.S,this.L),this.updateInputRGB(this.R,this.G,this.B),this.updateInputRGBHEX(this.R,this.G,this.B);break;case b:var E=o(t,4);this.R=E[0],this.G=E[1],this.B=E[2],this.A=E[3];var C=(0,s.rgbToHsl)(this.R,this.G,this.B),H=o(C,3);this.H=H[0],this.S=H[1],this.L=H[2],this.slBarHelper.setHue(this.H),this.updatePointerH(this.H),this.updatePointerSL(this.H,this.S,this.L),this.updateInputHSL(this.H,this.S,this.L),this.updateInputRGB(this.R,this.G,this.B),this.updateInputRGBHEX(this.R,this.G,this.B),this.updatePointerA(this.A);break;case v:var B=o(t,4);this.H=B[0],this.S=B[1],this.L=B[2],this.A=B[3];var R=(0,s.hslToRgb)(this.H,this.S,this.L),S=o(R,3);this.R=S[0],this.G=S[1],this.B=S[2],this.slBarHelper.setHue(this.H),this.updatePointerH(this.H),this.updatePointerSL(this.H,this.S,this.L),this.updateInputHSL(this.H,this.S,this.L),this.updateInputRGB(this.R,this.G,this.B),this.updateInputRGBHEX(this.R,this.G,this.B),this.updatePointerA(this.A);break;case"RGBHEX":var L=(0,s.cssColorToRgb)(t)||[this.R,this.G,this.B],w=o(L,3);this.R=w[0],this.G=w[1],this.B=w[2];var x=(0,s.rgbToHsl)(this.R,this.G,this.B),T=o(x,3);this.H=T[0],this.S=T[1],this.L=T[2],this.slBarHelper.setHue(this.H),this.updatePointerH(this.H),this.updatePointerSL(this.H,this.S,this.L),this.updateInputHSL(this.H,this.S,this.L),this.updateInputRGB(this.R,this.G,this.B);break;case g:var I=(0,s.parseColor)(t,"rgba")||[0,0,0,1],G=o(I,4);this.R=G[0],this.G=G[1],this.B=G[2],this.A=G[3];var P=(0,s.rgbToHsl)(this.R,this.G,this.B),D=o(P,3);this.H=D[0],this.S=D[1],this.L=D[2],this.slBarHelper.setHue(this.H),this.updatePointerH(this.H),this.updatePointerSL(this.H,this.S,this.L),this.updateInputHSL(this.H,this.S,this.L),this.updateInputRGB(this.R,this.G,this.B),this.updateInputRGBHEX(this.R,this.G,this.B),this.updatePointerA(this.A);break;case"ALPHA":this.A=t}this.preview.style.backgroundColor=1===this.A?"rgb("+this.R+","+this.G+","+this.B+")":"rgba("+this.R+","+this.G+","+this.B+","+this.A+")",r&&r.silent||this.onchange&&this.onchange(this.preview.style.backgroundColor)}},{key:"onPaletteColorAdd",value(e){this.oncoloradd&&this.oncoloradd(e)}},{key:"onPaletteColorRemove",value(e){this.oncolorremove&&this.oncolorremove(e)}},{key:"updateInputHSL",value(e,t,r){this.options.showHSL&&(this.inputH.value=e,this.inputS.value=t,this.inputL.value=r)}},{key:"updateInputRGB",value(e,t,r){this.options.showRGB&&(this.inputR.value=e,this.inputG.value=t,this.inputB.value=r)}},{key:"updateInputRGBHEX",value(e,t,r){this.options.showHEX&&(this.inputRGBHEX.value=(0,s.rgbToHex)(e,t,r))}},{key:"updatePointerH",value(e){this.huePointer.style.left=this.options.hueBarSize[0]*e/360-7+"px"}},{key:"updatePointerSL",value(e,t,r){var i=(0,s.hslToRgb)(e,t,r),a=o(i,3),n=this.slBarHelper.findColor(a[0],a[1],a[2]),l=o(n,2),h=l[0],c=l[1];h>=0&&(this.slPointer.style.left=h-7+"px",this.slPointer.style.top=c-7+"px")}},{key:"updatePointerA",value(e){this.options.showAlpha&&(this.alphaPointer.style.left=this.options.alphaBarSize[0]*e-7+"px")}}]),e}(),F=function(){function e(t){h(this,e),this.name=t,this.listeners=[]}return i(e,[{key:"on",value(e){e&&this.listeners.push(e)}},{key:"off",value(e){this.listeners=e?this.listeners.filter((t=>t!==e)):[]}},{key:"emit",value(e,t){for(var r=this.listeners.slice(0),i=0;r.length>i;i++)r[i].apply(t,e)}}]),e}();function E(e,t){var r=new k(e,t),i={change:new F("change"),coloradd:new F("coloradd"),colorremove:new F("colorremove")},a=!0,n={},l={get element(){return r.element},get rgb(){return[r.R,r.G,r.B]},set rgb(e){var t=o(e,3),i=t[0],a=t[1],n=t[2],l=[(0,s.limit)(i,0,255),(0,s.limit)(a,0,255),(0,s.limit)(n,0,255)];r.onValueChanged(b,[i=l[0],a=l[1],n=l[2],1])},get hsl(){return[r.H,r.S,r.L]},set hsl(e){var t=o(e,3),i=t[0],a=t[1],n=t[2],l=[(0,s.limit)(i,0,360),(0,s.limit)(a,0,100),(0,s.limit)(n,0,100)];r.onValueChanged(v,[i=l[0],a=l[1],n=l[2],1])},get rgbhex(){return this.all.hex},get rgba(){return[r.R,r.G,r.B,r.A]},set rgba(e){var t=o(e,4),i=t[0],a=t[1],n=t[2],l=t[3],h=[(0,s.limit)(i,0,255),(0,s.limit)(a,0,255),(0,s.limit)(n,0,255),(0,s.limit)(l,0,1)];r.onValueChanged(b,[i=h[0],a=h[1],n=h[2],l=h[3]])},get hsla(){return[r.H,r.S,r.L,r.A]},set hsla(e){var t=o(e,4),i=t[0],a=t[1],n=t[2],l=t[3],h=[(0,s.limit)(i,0,360),(0,s.limit)(a,0,100),(0,s.limit)(n,0,100),(0,s.limit)(l,0,1)];r.onValueChanged(v,[i=h[0],a=h[1],n=h[2],l=h[3]])},get color(){return""+this.all},set color(e){r.onValueChanged(g,e)},setColor(e){r.onValueChanged(g,e,{silent:arguments.length>1&&void 0!==arguments[1]&&arguments[1]})},get all(){if(a){var e=[r.R,r.G,r.B,r.A],t=1>r.A?"rgba("+r.R+","+r.G+","+r.B+","+r.A+")":s.rgbToHex.apply(void 0,e);(n=(0,s.parseColor)(e,n)).toString=()=>t,a=!1}return Object.assign({},n)},get onchange(){return i.change&&i.change.listeners[0]},set onchange(e){this.off("change").on("change",e)},get oncoloradd(){return i.coloradd&&i.coloradd.listeners[0]},set oncoloradd(e){this.off("coloradd").on("coloradd",e)},get oncolorremove(){return i.colorremove&&i.colorremove.listeners[0]},set oncolorremove(e){this.off("colorremove").on("colorremove",e)},get palette(){return Object.keys(r.palette).filter((e=>r.palette[e]))},set palette(e){r.updatePalette(e)},show(){r.element.classList.remove("hidden")},hide(){r.element.classList.add("hidden")},toggle(){r.element.classList.toggle("hidden")},on(e,t){return e&&i[e]&&i[e].on(t),this},off(e,t){return e&&i[e]&&i[e].off(t),this},destroy(){i.change.off(),i.coloradd.off(),i.colorremove.off(),r.element.remove(),i=null,r=null}};return r.onchange=function(){for(var e=arguments.length,t=Array(e),r=0;e>r;r++)t[r]=arguments[r];a=!0,i.change.emit([l].concat(t),l)},r.oncoloradd=function(){for(var e=arguments.length,t=Array(e),r=0;e>r;r++)t[r]=arguments[r];i.coloradd.emit([l].concat(t),l)},r.oncolorremove=function(){for(var e=arguments.length,t=Array(e),r=0;e>r;r++)t[r]=arguments[r];i.colorremove.emit([l].concat(t),l)},r.element.ctrl=l,l}if("undefined"!=typeof window&&!document.querySelector('head>style[data-source="a-color-picker"]')){var C=""+r(5),H=document.createElement("style");H.setAttribute("type","text/css"),H.setAttribute("data-source","a-color-picker"),H.innerHTML=C,document.querySelector("head").appendChild(H)}t.createPicker=E,t.from=function(e,t){var r=(e=>e?Array.isArray(e)?e:e instanceof HTMLElement?[e]:e instanceof NodeList?[].concat(c(e)):"string"==typeof e?[].concat(c(document.querySelectorAll(e))):e.jquery?e.get():[]:[])(e).map(((e,r)=>{var i=E(e,t);return i.index=r,i}));return r.on=function(e,t){return r.forEach((r=>r.on(e,t))),this},r.off=function(e){return r.forEach((t=>t.off(e))),this},r},t.parseColorToRgb=s.parseColorToRgb,t.parseColorToRgba=s.parseColorToRgba,t.parseColorToHsl=s.parseColorToHsl,t.parseColorToHsla=s.parseColorToHsla,t.parseColor=s.parseColor,t.rgbToHex=s.rgbToHex,t.hslToRgb=s.hslToRgb,t.rgbToHsl=s.rgbToHsl,t.rgbToHsv=s.rgbToHsv,t.rgbToInt=s.rgbToInt,t.intToRgb=s.intToRgb,t.getLuminance=s.getLuminance,t.COLOR_NAMES=s.COLOR_NAMES,t.PALETTE_MATERIAL_500=s.PALETTE_MATERIAL_500,t.PALETTE_MATERIAL_CHROME=s.PALETTE_MATERIAL_CHROME,t.VERSION="1.2.1"},(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.nvl=t.ensureArray=t.limit=t.getLuminance=t.parseColor=t.parseColorToHsla=t.parseColorToHsl=t.cssHslaToHsla=t.cssHslToHsl=t.parseColorToRgba=t.parseColorToRgb=t.cssRgbaToRgba=t.cssRgbToRgb=t.cssColorToRgba=t.cssColorToRgb=t.intToRgb=t.rgbToInt=t.rgbToHsv=t.rgbToHsl=t.hslToRgb=t.rgbToHex=t.PALETTE_MATERIAL_CHROME=t.PALETTE_MATERIAL_500=t.COLOR_NAMES=void 0;var i=(e,t)=>{if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return((e,t)=>{var r=[],i=!0,o=!1,s=void 0;try{for(var a,n=e[Symbol.iterator]();!(i=(a=n.next()).done)&&(r.push(a.value),!t||r.length!==t);i=!0);}catch(e){o=!0,s=e}finally{try{!i&&n.return&&n.return()}finally{if(o)throw s}}return r})(e,t);throw new TypeError("Invalid attempt to destructure non-iterable instance")},o=(e=>e&&e.__esModule?e:{default:e})(r(0));function s(e){if(Array.isArray(e)){for(var t=0,r=Array(e.length);e.length>t;t++)r[t]=e[t];return r}return Array.from(e)}var a={aliceblue:"#F0F8FF",antiquewhite:"#FAEBD7",aqua:"#00FFFF",aquamarine:"#7FFFD4",azure:"#F0FFFF",beige:"#F5F5DC",bisque:"#FFE4C4",black:"#000000",blanchedalmond:"#FFEBCD",blue:"#0000FF",blueviolet:"#8A2BE2",brown:"#A52A2A",burlywood:"#DEB887",cadetblue:"#5F9EA0",chartreuse:"#7FFF00",chocolate:"#D2691E",coral:"#FF7F50",cornflowerblue:"#6495ED",cornsilk:"#FFF8DC",crimson:"#DC143C",cyan:"#00FFFF",darkblue:"#00008B",darkcyan:"#008B8B",darkgoldenrod:"#B8860B",darkgray:"#A9A9A9",darkgrey:"#A9A9A9",darkgreen:"#006400",darkkhaki:"#BDB76B",darkmagenta:"#8B008B",darkolivegreen:"#556B2F",darkorange:"#FF8C00",darkorchid:"#9932CC",darkred:"#8B0000",darksalmon:"#E9967A",darkseagreen:"#8FBC8F",darkslateblue:"#483D8B",darkslategray:"#2F4F4F",darkslategrey:"#2F4F4F",darkturquoise:"#00CED1",darkviolet:"#9400D3",deeppink:"#FF1493",deepskyblue:"#00BFFF",dimgray:"#696969",dimgrey:"#696969",dodgerblue:"#1E90FF",firebrick:"#B22222",floralwhite:"#FFFAF0",forestgreen:"#228B22",fuchsia:"#FF00FF",gainsboro:"#DCDCDC",ghostwhite:"#F8F8FF",gold:"#FFD700",goldenrod:"#DAA520",gray:"#808080",grey:"#808080",green:"#008000",greenyellow:"#ADFF2F",honeydew:"#F0FFF0",hotpink:"#FF69B4","indianred ":"#CD5C5C","indigo ":"#4B0082",ivory:"#FFFFF0",khaki:"#F0E68C",lavender:"#E6E6FA",lavenderblush:"#FFF0F5",lawngreen:"#7CFC00",lemonchiffon:"#FFFACD",lightblue:"#ADD8E6",lightcoral:"#F08080",lightcyan:"#E0FFFF",lightgoldenrodyellow:"#FAFAD2",lightgray:"#D3D3D3",lightgrey:"#D3D3D3",lightgreen:"#90EE90",lightpink:"#FFB6C1",lightsalmon:"#FFA07A",lightseagreen:"#20B2AA",lightskyblue:"#87CEFA",lightslategray:"#778899",lightslategrey:"#778899",lightsteelblue:"#B0C4DE",lightyellow:"#FFFFE0",lime:"#00FF00",limegreen:"#32CD32",linen:"#FAF0E6",magenta:"#FF00FF",maroon:"#800000",mediumaquamarine:"#66CDAA",mediumblue:"#0000CD",mediumorchid:"#BA55D3",mediumpurple:"#9370DB",mediumseagreen:"#3CB371",mediumslateblue:"#7B68EE",mediumspringgreen:"#00FA9A",mediumturquoise:"#48D1CC",mediumvioletred:"#C71585",midnightblue:"#191970",mintcream:"#F5FFFA",mistyrose:"#FFE4E1",moccasin:"#FFE4B5",navajowhite:"#FFDEAD",navy:"#000080",oldlace:"#FDF5E6",olive:"#808000",olivedrab:"#6B8E23",orange:"#FFA500",orangered:"#FF4500",orchid:"#DA70D6",palegoldenrod:"#EEE8AA",palegreen:"#98FB98",paleturquoise:"#AFEEEE",palevioletred:"#DB7093",papayawhip:"#FFEFD5",peachpuff:"#FFDAB9",peru:"#CD853F",pink:"#FFC0CB",plum:"#DDA0DD",powderblue:"#B0E0E6",purple:"#800080",rebeccapurple:"#663399",red:"#FF0000",rosybrown:"#BC8F8F",royalblue:"#4169E1",saddlebrown:"#8B4513",salmon:"#FA8072",sandybrown:"#F4A460",seagreen:"#2E8B57",seashell:"#FFF5EE",sienna:"#A0522D",silver:"#C0C0C0",skyblue:"#87CEEB",slateblue:"#6A5ACD",slategray:"#708090",slategrey:"#708090",snow:"#FFFAFA",springgreen:"#00FF7F",steelblue:"#4682B4",tan:"#D2B48C",teal:"#008080",thistle:"#D8BFD8",tomato:"#FF6347",turquoise:"#40E0D0",violet:"#EE82EE",wheat:"#F5DEB3",white:"#FFFFFF",whitesmoke:"#F5F5F5",yellow:"#FFFF00",yellowgreen:"#9ACD32"};function n(e,t,r){return isNaN(e=+e)||t>e?t:e>r?r:e}function l(e,t){return null==e?t:e}function h(e,t,r){var i=[n(e,0,255),n(t,0,255),n(r,0,255)];return"#"+("000000"+((e=i[0])<<16|(t=i[1])<<8|(r=i[2])).toString(16)).slice(-6)}function c(e,t,r){var i=void 0,o=void 0,s=void 0,a=[n(e,0,360)/360,n(t,0,100)/100,n(r,0,100)/100];if(e=a[0],r=a[2],0==(t=a[1]))i=o=s=r;else{var l=(e,t,r)=>(0>r&&(r+=1),r>1&&(r-=1),1/6>r?e+6*(t-e)*r:.5>r?t:2/3>r?e+(t-e)*(2/3-r)*6:e),h=.5>r?r*(1+t):r+t-r*t,c=2*r-h;i=l(c,h,e+1/3),o=l(c,h,e),s=l(c,h,e-1/3)}return[255*i,255*o,255*s].map(Math.round)}function p(e,t,r){var i=[n(e,0,255)/255,n(t,0,255)/255,n(r,0,255)/255],o=Math.max(e=i[0],t=i[1],r=i[2]),s=Math.min(e,t,r),a=void 0,l=void 0,h=(o+s)/2;if(o==s)a=l=0;else{var c=o-s;switch(l=h>.5?c/(2-o-s):c/(o+s),o){case e:a=(t-r)/c+(r>t?6:0);break;case t:a=(r-e)/c+2;break;case r:a=(e-t)/c+4}a/=6}return[360*a,100*l,100*h].map(Math.round)}function u(e,t,r){return e<<16|t<<8|r}function d(e){if(e){var t=/^\s*#?((([0-9A-F])([0-9A-F])([0-9A-F]))|(([0-9A-F]{2})([0-9A-F]{2})([0-9A-F]{2})))\s*$/i.exec(a[(""+e).toLowerCase()]||e)||[],r=i(t,10),o=r[3],s=r[4],n=r[5],l=r[7],h=r[8],c=r[9];if(void 0!==o)return[parseInt(o+o,16),parseInt(s+s,16),parseInt(n+n,16)];if(void 0!==l)return[parseInt(l,16),parseInt(h,16),parseInt(c,16)]}}function g(e){if(e){var t=/^\s*#?((([0-9A-F])([0-9A-F])([0-9A-F])([0-9A-F])?)|(([0-9A-F]{2})([0-9A-F]{2})([0-9A-F]{2})([0-9A-F]{2})?))\s*$/i.exec(a[(""+e).toLowerCase()]||e)||[],r=i(t,12),o=r[3],s=r[4],n=r[5],l=r[6],h=r[8],c=r[9],p=r[10],u=r[11];if(void 0!==o)return[parseInt(o+o,16),parseInt(s+s,16),parseInt(n+n,16),l?+(parseInt(l+l,16)/255).toFixed(2):1];if(void 0!==h)return[parseInt(h,16),parseInt(c,16),parseInt(p,16),u?+(parseInt(u,16)/255).toFixed(2):1]}}function b(e){if(e){var t=/^rgb\((\d+)[\s,](\d+)[\s,](\d+)\)/i.exec(e)||[],r=i(t,4),o=r[2],s=r[3];return r[0]?[n(r[1],0,255),n(o,0,255),n(s,0,255)]:void 0}}function v(e){if(e){var t=/^rgba?\((\d+)\s*[\s,]\s*(\d+)\s*[\s,]\s*(\d+)(\s*[\s,]\s*(\d*(.\d+)?))?\)/i.exec(e)||[],r=i(t,6),o=r[2],s=r[3],a=r[5];return r[0]?[n(r[1],0,255),n(o,0,255),n(s,0,255),n(l(a,1),0,1)]:void 0}}function f(e){if(Array.isArray(e))return[n(e[0],0,255),n(e[1],0,255),n(e[2],0,255),n(l(e[3],1),0,1)];var t=g(e)||v(e);return t&&3===t.length&&t.push(1),t}function m(e){if(e){var t=/^hsl\((\d+)[\s,](\d+)[\s,](\d+)\)/i.exec(e)||[],r=i(t,4),o=r[2],s=r[3];return r[0]?[n(r[1],0,360),n(o,0,100),n(s,0,100)]:void 0}}function A(e){if(e){var t=/^hsla?\((\d+)\s*[\s,]\s*(\d+)\s*[\s,]\s*(\d+)(\s*[\s,]\s*(\d*(.\d+)?))?\)/i.exec(e)||[],r=i(t,6),o=r[2],s=r[3],a=r[5];return r[0]?[n(r[1],0,255),n(o,0,255),n(s,0,255),n(l(a,1),0,1)]:void 0}}function y(e){if(Array.isArray(e))return[n(e[0],0,360),n(e[1],0,100),n(e[2],0,100),n(l(e[3],1),0,1)];var t=A(e);return t&&3===t.length&&t.push(1),t}function k(e,t){switch(t){case"rgb":default:return e.slice(0,3);case"rgbcss":return"rgb("+e[0]+", "+e[1]+", "+e[2]+")";case"rgbcss4":return"rgb("+e[0]+", "+e[1]+", "+e[2]+", "+e[3]+")";case"rgba":return e;case"rgbacss":return"rgba("+e[0]+", "+e[1]+", "+e[2]+", "+e[3]+")";case"hsl":return p.apply(void 0,s(e));case"hslcss":return"hsl("+(e=p.apply(void 0,s(e)))[0]+", "+e[1]+", "+e[2]+")";case"hslcss4":var r=p.apply(void 0,s(e));return"hsl("+r[0]+", "+r[1]+", "+r[2]+", "+e[3]+")";case"hsla":return[].concat(s(p.apply(void 0,s(e))),[e[3]]);case"hslacss":var i=p.apply(void 0,s(e));return"hsla("+i[0]+", "+i[1]+", "+i[2]+", "+e[3]+")";case"hex":return h.apply(void 0,s(e));case"hexcss4":return h.apply(void 0,s(e))+("00"+parseInt(255*e[3]).toString(16)).slice(-2);case"int":return u.apply(void 0,s(e))}}t.COLOR_NAMES=a,t.PALETTE_MATERIAL_500=["#F44336","#E91E63","#E91E63","#9C27B0","#9C27B0","#673AB7","#673AB7","#3F51B5","#3F51B5","#2196F3","#2196F3","#03A9F4","#03A9F4","#00BCD4","#00BCD4","#009688","#009688","#4CAF50","#4CAF50","#8BC34A","#8BC34A","#CDDC39","#CDDC39","#FFEB3B","#FFEB3B","#FFC107","#FFC107","#FF9800","#FF9800","#FF5722","#FF5722","#795548","#795548","#9E9E9E","#9E9E9E","#607D8B","#607D8B"],t.PALETTE_MATERIAL_CHROME=["#f44336","#e91e63","#9c27b0","#673ab7","#3f51b5","#2196f3","#03a9f4","#00bcd4","#009688","#4caf50","#8bc34a","#cddc39","#ffeb3b","#ffc107","#ff9800","#ff5722","#795548","#9e9e9e","#607d8b"],t.rgbToHex=h,t.hslToRgb=c,t.rgbToHsl=p,t.rgbToHsv=(e,t,r)=>{var i,o=[n(e,0,255)/255,n(t,0,255)/255,n(r,0,255)/255],s=Math.max(e=o[0],t=o[1],r=o[2]),a=Math.min(e,t,r),l=void 0,h=s,c=s-a;if(i=0===s?0:c/s,s==a)l=0;else{switch(s){case e:l=(t-r)/c+(r>t?6:0);break;case t:l=(r-e)/c+2;break;case r:l=(e-t)/c+4}l/=6}return[l,i,h]},t.rgbToInt=u,t.intToRgb=e=>[e>>16&255,e>>8&255,255&e],t.cssColorToRgb=d,t.cssColorToRgba=g,t.cssRgbToRgb=b,t.cssRgbaToRgba=v,t.parseColorToRgb=e=>Array.isArray(e)?e=[n(e[0],0,255),n(e[1],0,255),n(e[2],0,255)]:d(e)||b(e),t.parseColorToRgba=f,t.cssHslToHsl=m,t.cssHslaToHsla=A,t.parseColorToHsl=e=>Array.isArray(e)?e=[n(e[0],0,360),n(e[1],0,100),n(e[2],0,100)]:m(e),t.parseColorToHsla=y,t.parseColor=(e,t)=>{if(t=t||"rgb",null!=e){var r=void 0;if((r=f(e))||(r=y(e))&&(r=[].concat(s(c.apply(void 0,s(r))),[r[3]])))return(0,o.default)(t)?["rgb","rgbcss","rgbcss4","rgba","rgbacss","hsl","hslcss","hslcss4","hsla","hslacss","hex","hexcss4","int"].reduce(((e,t)=>(e[t]=k(r,t),e)),t||{}):k(r,(""+t).toLowerCase())}},t.getLuminance=(e,t,r)=>.2126*(e=.03928>(e/=255)?e/12.92:Math.pow((e+.055)/1.055,2.4))+.7152*(t=.03928>(t/=255)?t/12.92:Math.pow((t+.055)/1.055,2.4))+.0722*(.03928>(r/=255)?r/12.92:Math.pow((r+.055)/1.055,2.4)),t.limit=n,t.ensureArray=e=>e?Array.from(e):[],t.nvl=l},(e,t,r)=>{"use strict";e.exports=e=>null!=e&&"object"==typeof e&&!1===Array.isArray(e)},(e,t)=>{e.exports='<div class="a-color-picker-row a-color-picker-stack a-color-picker-row-top"> <canvas class="a-color-picker-sl a-color-picker-transparent"></canvas> <div class=a-color-picker-dot></div> </div> <div class=a-color-picker-row> <div class="a-color-picker-stack a-color-picker-transparent a-color-picker-circle"> <div class=a-color-picker-preview> <input class=a-color-picker-clipbaord type=text> </div> </div> <div class=a-color-picker-column> <div class="a-color-picker-cell a-color-picker-stack"> <canvas class=a-color-picker-h></canvas> <div class=a-color-picker-dot></div> </div> <div class="a-color-picker-cell a-color-picker-alpha a-color-picker-stack" show-on-alpha> <canvas class="a-color-picker-a a-color-picker-transparent"></canvas> <div class=a-color-picker-dot></div> </div> </div> </div> <div class="a-color-picker-row a-color-picker-hsl" show-on-hsl> <label>H</label> <input nameref=H type=number maxlength=3 min=0 max=360 value=0> <label>S</label> <input nameref=S type=number maxlength=3 min=0 max=100 value=0> <label>L</label> <input nameref=L type=number maxlength=3 min=0 max=100 value=0> </div> <div class="a-color-picker-row a-color-picker-rgb" show-on-rgb> <label>R</label> <input nameref=R type=number maxlength=3 min=0 max=255 value=0> <label>G</label> <input nameref=G type=number maxlength=3 min=0 max=255 value=0> <label>B</label> <input nameref=B type=number maxlength=3 min=0 max=255 value=0> </div> <div class="a-color-picker-row a-color-picker-rgbhex a-color-picker-single-input" show-on-single-input> <label>HEX</label> <input nameref=RGBHEX type=text select-on-focus> </div> <div class="a-color-picker-row a-color-picker-palette"></div>'},(e,t,r)=>{var i=r(6);e.exports="string"==typeof i?i:""+i},(e,t,r)=>{(e.exports=r(7)(!1)).push([e.i,"/*!\n * a-color-picker\n * https://github.com/narsenico/a-color-picker\n *\n * Copyright (c) 2017-2018, Gianfranco Caldi.\n * Released under the MIT License.\n */.a-color-picker{background-color:#fff;padding:0;display:inline-flex;flex-direction:column;user-select:none;width:232px;font:400 10px Helvetica,Arial,sans-serif;border-radius:3px;box-shadow:0 0 0 1px rgba(0,0,0,.05),0 2px 4px rgba(0,0,0,.25)}.a-color-picker,.a-color-picker-row,.a-color-picker input{box-sizing:border-box}.a-color-picker-row{padding:15px;display:flex;flex-direction:row;align-items:center;justify-content:space-between;user-select:none}.a-color-picker-row-top{padding:0}.a-color-picker-row:not(:first-child){border-top:1px solid #f5f5f5}.a-color-picker-column{display:flex;flex-direction:column}.a-color-picker-cell{flex:1 1 auto;margin-bottom:4px}.a-color-picker-cell:last-child{margin-bottom:0}.a-color-picker-stack{position:relative}.a-color-picker-dot{position:absolute;width:14px;height:14px;top:0;left:0;background:#fff;pointer-events:none;border-radius:50px;z-index:1000;box-shadow:0 1px 2px rgba(0,0,0,.75)}.a-color-picker-a,.a-color-picker-h,.a-color-picker-sl{cursor:cell}.a-color-picker-a+.a-color-picker-dot,.a-color-picker-h+.a-color-picker-dot{top:-2px}.a-color-picker-a,.a-color-picker-h{border-radius:2px}.a-color-picker-preview{box-sizing:border-box;width:30px;height:30px;user-select:none;border-radius:15px}.a-color-picker-circle{border-radius:50px;border:1px solid #eee}.a-color-picker-hsl,.a-color-picker-rgb,.a-color-picker-single-input{justify-content:space-evenly}.a-color-picker-hsl>label,.a-color-picker-rgb>label,.a-color-picker-single-input>label{padding:0 8px;flex:0 0 auto;color:#969696}.a-color-picker-hsl>input,.a-color-picker-rgb>input,.a-color-picker-single-input>input{text-align:center;padding:2px 0;width:0;flex:1 1 auto;border:1px solid #e0e0e0;line-height:20px}.a-color-picker-hsl>input::-webkit-inner-spin-button,.a-color-picker-rgb>input::-webkit-inner-spin-button,.a-color-picker-single-input>input::-webkit-inner-spin-button{-webkit-appearance:none;margin:0}.a-color-picker-hsl>input:focus,.a-color-picker-rgb>input:focus,.a-color-picker-single-input>input:focus{border-color:#04a9f4;outline:none}.a-color-picker-transparent{background-image:linear-gradient(-45deg,#cdcdcd 25%,transparent 0),linear-gradient(45deg,#cdcdcd 25%,transparent 0),linear-gradient(-45deg,transparent 75%,#cdcdcd 0),linear-gradient(45deg,transparent 75%,#cdcdcd 0);background-size:11px 11px;background-position:0 0,0 -5.5px,-5.5px 5.5px,5.5px 0}.a-color-picker-sl{border-radius:3px 3px 0 0}.a-color-picker.hide-alpha [show-on-alpha],.a-color-picker.hide-hsl [show-on-hsl],.a-color-picker.hide-rgb [show-on-rgb],.a-color-picker.hide-single-input [show-on-single-input]{display:none}.a-color-picker-clipbaord{width:100%;height:100%;opacity:0;cursor:pointer}.a-color-picker-palette{flex-flow:wrap;flex-direction:row;justify-content:flex-start;padding:10px}.a-color-picker-palette-color{width:15px;height:15px;flex:0 1 15px;margin:3px;box-sizing:border-box;cursor:pointer;border-radius:3px;box-shadow:inset 0 0 0 1px rgba(0,0,0,.1)}.a-color-picker-palette-add{text-align:center;line-height:13px;color:#607d8b}.a-color-picker.hidden{display:none}",""])},function(e,t){e.exports=function(e){var t=[];return t.toString=function(){return this.map((t=>{var r=((e,t)=>{var r=e[1]||"",i=e[3];if(!i)return r;if(t&&"function"==typeof btoa){var o=(e=>"/*# sourceMappingURL=data:application/json;charset=utf-8;base64,"+btoa(unescape(encodeURIComponent(JSON.stringify(e))))+" */")(i),s=i.sources.map((e=>"/*# sourceURL="+i.sourceRoot+e+" */"));return[r].concat(s).concat([o]).join("\n")}return""+r})(t,e);return t[2]?"@media "+t[2]+"{"+r+"}":r})).join("")},t.i=function(e,r){"string"==typeof e&&(e=[[null,e,""]]);for(var i={},o=0;this.length>o;o++){var s=this[o][0];"number"==typeof s&&(i[s]=!0)}for(o=0;e.length>o;o++){var a=e[o];"number"==typeof a[0]&&i[a[0]]||(r&&!a[2]?a[2]=r:r&&(a[2]="("+a[2]+") and ("+r+")"),t.push(a))}},t}}])},202(e,t,r){"use strict";r.r(t),r.d(t,{colorPicker:()=>h});var i=r(39),o=r(56),s=r(4),a=r(203),n=r(36),l=r(1);class h extends o.S{constructor(){super(...arguments),this.requires=["license"],this.hasStyle=!l.Jodit.fatMode}afterInit(e){e.e.on("afterGenerateColorPicker",this.onAfterGenerateColorPicker)}onAfterGenerateColorPicker(e,t,r,i){s.Dom.detach(t);const o=new a.T(this.j,r);o.value=i||"#000",t.appendChild(o.container)}beforeDestruct(e){e.e.off("afterGenerateColorPicker",this.onAfterGenerateColorPicker)}}(0,i.gn)([n.autobind],h.prototype,"onAfterGenerateColorPicker",null),l.Jodit.plugins.add("color-picker",h)},203(e,t,r){"use strict";r.d(t,{T:()=>h});var i=r(39),o=r(27),s=r(36),a=r(10),n=r(204),l=r(4);let h=class extends o.u3{constructor(e,t){super(e);const r=new o.GI(e);this.trigger.onAction((()=>{t(this.value),r.close()})),r.setMod("padding",!1).setMod("max-height",!1);const i=this.j.create.div(this.getFullElName("picker")),s=n.createPicker(i,{paletteEditable:!0,showAlpha:!0,palette:"PALETTE_MATERIAL_CHROME"}).on("change",((e,t)=>{this.isFocused||(this.value=n.parseColor(t||"","hex"))}));this.j.e.on(this,"change",(()=>{n.parseColor(this.value,"hex")!==s.color&&(s.color=this.value)})),r.setContent(i),this.j.e.on(this.nativeInput,"click",(()=>{r.parentElement=this,this.jodit instanceof l.Dialog&&r.setZIndex(this.jodit.getZIndex()+1),r.open((()=>(0,a.position)(this.container)))}))}className(){return"ColorInput"}createContainer(e){const t=super.createContainer(e);return this.trigger=(0,o.zx)(this.j,"ok"),t.appendChild(this.trigger.container),this.trigger.container.classList.add(this.getFullElName("trigger")),t}setMod(e,t,r=this.container){return"slim"===e&&t&&this.nativeInput.setAttribute("readonly","true"),super.setMod(e,t,r)}onChangeSelfValue(){this.nativeInput.style.backgroundColor=this.value}};(0,i.gn)([(0,s.watch)(":change")],h.prototype,"onChangeSelfValue",null),h=(0,i.gn)([s.component],h)}},e=>{"use strict";e(e.s=202)}])}));
((e,t)=>{if("object"==typeof exports&&"object"==typeof module)module.exports=t();else if("function"==typeof define&&define.amd)define([],t);else{var r=t();for(var i in r)("object"==typeof exports?exports:e)[i]=r[i]}})(self,(function(){return(self.webpackChunkjodit_pro=self.webpackChunkjodit_pro||[]).push([[652],{204(e){"undefined"!=typeof self&&self,e.exports=(e=>{var t={};function r(i){if(t[i])return t[i].exports;var o=t[i]={i,l:!1,exports:{}};return e[i].call(o.exports,o,o.exports,r),o.l=!0,o.exports}return r.m=e,r.c=t,r.d=(e,t,i)=>{r.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:i})},r.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},r.t=(e,t)=>{if(1&t&&(e=r(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var i=Object.create(null);if(r.r(i),Object.defineProperty(i,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var o in e)r.d(i,o,(t=>e[t]).bind(null,o));return i},r.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return r.d(t,"a",t),t},r.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),r.p="",r(r.s=1)})([(e,t,r)=>{"use strict";var i=r(3);function o(e){return!0===i(e)&&"[object Object]"===Object.prototype.toString.call(e)}e.exports=e=>{var t,r;return!1!==o(e)&&"function"==typeof(t=e.constructor)&&!1!==o(r=t.prototype)&&!1!==r.hasOwnProperty("isPrototypeOf")}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.VERSION=t.PALETTE_MATERIAL_CHROME=t.PALETTE_MATERIAL_500=t.COLOR_NAMES=t.getLuminance=t.intToRgb=t.rgbToInt=t.rgbToHsv=t.rgbToHsl=t.hslToRgb=t.rgbToHex=t.parseColor=t.parseColorToHsla=t.parseColorToHsl=t.parseColorToRgba=t.parseColorToRgb=t.from=t.createPicker=void 0;var i=(()=>{function e(e,t){for(var r=0;t.length>r;r++){var i=t[r];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,i.key,i)}}return(t,r,i)=>(r&&e(t.prototype,r),i&&e(t,i),t)})(),o=(e,t)=>{if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return((e,t)=>{var r=[],i=!0,o=!1,s=void 0;try{for(var a,n=e[Symbol.iterator]();!(i=(a=n.next()).done)&&(r.push(a.value),!t||r.length!==t);i=!0);}catch(e){o=!0,s=e}finally{try{!i&&n.return&&n.return()}finally{if(o)throw s}}return r})(e,t);throw new TypeError("Invalid attempt to destructure non-iterable instance")},s=r(2),a=l(r(0)),n=l(r(4));function l(e){return e&&e.__esModule?e:{default:e}}function h(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function c(e){if(Array.isArray(e)){for(var t=0,r=Array(e.length);e.length>t;t++)r[t]=e[t];return r}return Array.from(e)}var p="undefined"!=typeof window&&window.navigator.userAgent.indexOf("Edge")>-1,u="undefined"!=typeof window&&window.navigator.userAgent.indexOf("rv:")>-1,d={id:null,attachTo:"body",showHSL:!0,showRGB:!0,showHEX:!0,showAlpha:!1,color:"#ff0000",palette:null,paletteEditable:!1,useAlphaInPalette:"auto",slBarSize:[232,150],hueBarSize:[150,11],alphaBarSize:[150,11]},g="COLOR",b="RGBA_USER",v="HSLA_USER";function f(e,t,r){return e?e instanceof HTMLElement?e:e instanceof NodeList?e[0]:"string"==typeof e?document.querySelector(e):e.jquery?e.get(0):r?t:null:t}function m(e){var t=e.getContext("2d"),r=+e.width,i=+e.height,a=t.createLinearGradient(1,1,1,i-1);return a.addColorStop(0,"white"),a.addColorStop(1,"black"),{setHue(e){var o=t.createLinearGradient(1,0,r-1,0);o.addColorStop(0,"hsla("+e+", 100%, 50%, 0)"),o.addColorStop(1,"hsla("+e+", 100%, 50%, 1)"),t.fillStyle=a,t.fillRect(0,0,r,i),t.fillStyle=o,t.globalCompositeOperation="multiply",t.fillRect(0,0,r,i),t.globalCompositeOperation="source-over"},grabColor:(e,r)=>t.getImageData(e,r,1,1).data,findColor(e,t,a){var n=(0,s.rgbToHsv)(e,t,a),l=o(n,3);return[l[1]*r,i-l[2]*i]}}}function A(e,t,r){return null===e?t:/^\s*$/.test(e)?r:!!/true|yes|1/i.test(e)||!/false|no|0/i.test(e)&&t}function y(e,t,r){if(null===e)return t;if(/^\s*$/.test(e))return r;var i=e.split(",").map(Number);return 2===i.length&&i[0]&&i[1]?i:t}var k=function(){function e(t,r){if(h(this,e),r?(t=f(t),this.options=Object.assign({},d,r)):t&&(0,a.default)(t)?(this.options=Object.assign({},d,t),t=f(this.options.attachTo)):(this.options=Object.assign({},d),t=f((0,s.nvl)(t,this.options.attachTo))),!t)throw Error("Container not found: "+this.options.attachTo);!function(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"acp-";if(t.hasAttribute(r+"show-hsl")&&(e.showHSL=A(t.getAttribute(r+"show-hsl"),d.showHSL,!0)),t.hasAttribute(r+"show-rgb")&&(e.showRGB=A(t.getAttribute(r+"show-rgb"),d.showRGB,!0)),t.hasAttribute(r+"show-hex")&&(e.showHEX=A(t.getAttribute(r+"show-hex"),d.showHEX,!0)),t.hasAttribute(r+"show-alpha")&&(e.showAlpha=A(t.getAttribute(r+"show-alpha"),d.showAlpha,!0)),t.hasAttribute(r+"palette-editable")&&(e.paletteEditable=A(t.getAttribute(r+"palette-editable"),d.paletteEditable,!0)),t.hasAttribute(r+"sl-bar-size")&&(e.slBarSize=y(t.getAttribute(r+"sl-bar-size"),d.slBarSize,[232,150])),t.hasAttribute(r+"hue-bar-size")&&(e.hueBarSize=y(t.getAttribute(r+"hue-bar-size"),d.hueBarSize,[150,11]),e.alphaBarSize=e.hueBarSize),t.hasAttribute(r+"palette")){var i=t.getAttribute(r+"palette");switch(i){case"PALETTE_MATERIAL_500":e.palette=s.PALETTE_MATERIAL_500;break;case"PALETTE_MATERIAL_CHROME":case"":e.palette=s.PALETTE_MATERIAL_CHROME;break;default:e.palette=i.split(/[;|]/)}}t.hasAttribute(r+"color")&&(e.color=t.getAttribute(r+"color"))}(this.options,t),this.H=0,this.S=0,this.L=0,this.R=0,this.G=0,this.B=0,this.A=1,this.palette={},this.element=document.createElement("div"),this.options.id&&(this.element.id=this.options.id),this.element.className="a-color-picker",this.element.innerHTML=n.default,t.appendChild(this.element);var i=this.element.querySelector(".a-color-picker-h");this.setupHueCanvas(i),this.hueBarHelper=m(i),this.huePointer=this.element.querySelector(".a-color-picker-h+.a-color-picker-dot");var o=this.element.querySelector(".a-color-picker-sl");this.setupSlCanvas(o),this.slBarHelper=m(o),this.slPointer=this.element.querySelector(".a-color-picker-sl+.a-color-picker-dot"),this.preview=this.element.querySelector(".a-color-picker-preview"),this.setupClipboard(this.preview.querySelector(".a-color-picker-clipbaord")),this.options.showHSL?(this.setupInput(this.inputH=this.element.querySelector(".a-color-picker-hsl>input[nameref=H]")),this.setupInput(this.inputS=this.element.querySelector(".a-color-picker-hsl>input[nameref=S]")),this.setupInput(this.inputL=this.element.querySelector(".a-color-picker-hsl>input[nameref=L]"))):this.element.querySelector(".a-color-picker-hsl").remove(),this.options.showRGB?(this.setupInput(this.inputR=this.element.querySelector(".a-color-picker-rgb>input[nameref=R]")),this.setupInput(this.inputG=this.element.querySelector(".a-color-picker-rgb>input[nameref=G]")),this.setupInput(this.inputB=this.element.querySelector(".a-color-picker-rgb>input[nameref=B]"))):this.element.querySelector(".a-color-picker-rgb").remove(),this.options.showHEX?this.setupInput(this.inputRGBHEX=this.element.querySelector("input[nameref=RGBHEX]")):this.element.querySelector(".a-color-picker-rgbhex").remove(),this.options.paletteEditable||this.options.palette&&this.options.palette.length>0?this.setPalette(this.paletteRow=this.element.querySelector(".a-color-picker-palette")):(this.paletteRow=this.element.querySelector(".a-color-picker-palette"),this.paletteRow.remove()),this.options.showAlpha?(this.setupAlphaCanvas(this.element.querySelector(".a-color-picker-a")),this.alphaPointer=this.element.querySelector(".a-color-picker-a+.a-color-picker-dot")):this.element.querySelector(".a-color-picker-alpha").remove(),this.element.style.width=this.options.slBarSize[0]+"px",this.onValueChanged(g,this.options.color)}return i(e,[{key:"setupHueCanvas",value(e){var t=this;e.width=this.options.hueBarSize[0],e.height=this.options.hueBarSize[1];for(var r=e.getContext("2d"),i=r.createLinearGradient(0,0,this.options.hueBarSize[0],0),o=0;1>=o;o+=1/360)i.addColorStop(o,"hsl("+360*o+", 100%, 50%)");r.fillStyle=i,r.fillRect(0,0,this.options.hueBarSize[0],this.options.hueBarSize[1]);var a=r=>{var i=(0,s.limit)(r.clientX-e.getBoundingClientRect().left,0,t.options.hueBarSize[0]),o=Math.round(360*i/t.options.hueBarSize[0]);t.huePointer.style.left=i-7+"px",t.onValueChanged("H",o)},n=function e(){document.removeEventListener("mousemove",a),document.removeEventListener("mouseup",e)};e.addEventListener("mousedown",(e=>{a(e),document.addEventListener("mousemove",a),document.addEventListener("mouseup",n)}))}},{key:"setupSlCanvas",value(e){var t=this;e.width=this.options.slBarSize[0],e.height=this.options.slBarSize[1];var r=r=>{var i=(0,s.limit)(r.clientX-e.getBoundingClientRect().left,0,t.options.slBarSize[0]-1),o=(0,s.limit)(r.clientY-e.getBoundingClientRect().top,0,t.options.slBarSize[1]-1),a=t.slBarHelper.grabColor(i,o);t.slPointer.style.left=i-7+"px",t.slPointer.style.top=o-7+"px",t.onValueChanged("RGB",a)},i=function e(){document.removeEventListener("mousemove",r),document.removeEventListener("mouseup",e)};e.addEventListener("mousedown",(e=>{r(e),document.addEventListener("mousemove",r),document.addEventListener("mouseup",i)}))}},{key:"setupAlphaCanvas",value(e){var t=this;e.width=this.options.alphaBarSize[0],e.height=this.options.alphaBarSize[1];var r=e.getContext("2d"),i=r.createLinearGradient(0,0,e.width-1,0);i.addColorStop(0,"hsla(0, 0%, 50%, 0)"),i.addColorStop(1,"hsla(0, 0%, 50%, 1)"),r.fillStyle=i,r.fillRect(0,0,this.options.alphaBarSize[0],this.options.alphaBarSize[1]);var o=r=>{var i=(0,s.limit)(r.clientX-e.getBoundingClientRect().left,0,t.options.alphaBarSize[0]),o=+(i/t.options.alphaBarSize[0]).toFixed(2);t.alphaPointer.style.left=i-7+"px",t.onValueChanged("ALPHA",o)},a=function e(){document.removeEventListener("mousemove",o),document.removeEventListener("mouseup",e)};e.addEventListener("mousedown",(e=>{o(e),document.addEventListener("mousemove",o),document.addEventListener("mouseup",a)}))}},{key:"setupInput",value(e){var t=this,r=+e.min,i=+e.max,o=e.getAttribute("nameref");e.hasAttribute("select-on-focus")&&e.addEventListener("focus",(()=>{e.select()})),"text"===e.type?e.addEventListener("change",(()=>{t.onValueChanged(o,e.value)})):((p||u)&&e.addEventListener("keydown",(a=>{"Up"===a.key?(e.value=(0,s.limit)(+e.value+1,r,i),t.onValueChanged(o,e.value),a.returnValue=!1):"Down"===a.key&&(e.value=(0,s.limit)(+e.value-1,r,i),t.onValueChanged(o,e.value),a.returnValue=!1)})),e.addEventListener("change",(()=>{t.onValueChanged(o,(0,s.limit)(+e.value,r,i))})))}},{key:"setupClipboard",value(e){var t=this;e.title="click to copy",e.addEventListener("click",(()=>{e.value=(0,s.parseColor)([t.R,t.G,t.B,t.A],"hexcss4"),e.select(),document.execCommand("copy")}))}},{key:"setPalette",value(e){var t=this,r="auto"===this.options.useAlphaInPalette?this.options.showAlpha:this.options.useAlphaInPalette,i=null;switch(this.options.palette){case"PALETTE_MATERIAL_500":i=s.PALETTE_MATERIAL_500;break;case"PALETTE_MATERIAL_CHROME":i=s.PALETTE_MATERIAL_CHROME;break;default:i=(0,s.ensureArray)(this.options.palette)}if(this.options.paletteEditable||i.length>0){var o=(r,i,o)=>{var s=e.querySelector('.a-color-picker-palette-color[data-color="'+r+'"]')||document.createElement("div");s.className="a-color-picker-palette-color",s.style.backgroundColor=r,s.setAttribute("data-color",r),s.title=r,e.insertBefore(s,i),t.palette[r]=!0,o&&t.onPaletteColorAdd(r)},a=(r,i)=>{r?(e.removeChild(r),t.palette[r.getAttribute("data-color")]=!1,i&&t.onPaletteColorRemove(r.getAttribute("data-color"))):(e.querySelectorAll(".a-color-picker-palette-color[data-color]").forEach((t=>{e.removeChild(t)})),Object.keys(t.palette).forEach((e=>{t.palette[e]=!1})),i&&t.onPaletteColorRemove())};if(i.map((e=>(0,s.parseColor)(e,r?"rgbcss4":"hex"))).filter((e=>!!e)).forEach((e=>o(e))),this.options.paletteEditable){var n=document.createElement("div");n.className="a-color-picker-palette-color a-color-picker-palette-add",n.innerHTML="+",e.appendChild(n),e.addEventListener("click",(e=>{/a-color-picker-palette-add/.test(e.target.className)?e.shiftKey?a(null,!0):o(r?(0,s.parseColor)([t.R,t.G,t.B,t.A],"rgbcss4"):(0,s.rgbToHex)(t.R,t.G,t.B),e.target,!0):/a-color-picker-palette-color/.test(e.target.className)&&(e.shiftKey?a(e.target,!0):t.onValueChanged(g,e.target.getAttribute("data-color")))}))}else e.addEventListener("click",(e=>{/a-color-picker-palette-color/.test(e.target.className)&&t.onValueChanged(g,e.target.getAttribute("data-color"))}))}else e.style.display="none"}},{key:"updatePalette",value(e){this.paletteRow.innerHTML="",this.palette={},this.paletteRow.parentElement||this.element.appendChild(this.paletteRow),this.options.palette=e,this.setPalette(this.paletteRow)}},{key:"onValueChanged",value(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{silent:!1};switch(e){case"H":this.H=t;var i=(0,s.hslToRgb)(this.H,this.S,this.L),a=o(i,3);this.R=a[0],this.G=a[1],this.B=a[2],this.slBarHelper.setHue(t),this.updatePointerH(this.H),this.updateInputHSL(this.H,this.S,this.L),this.updateInputRGB(this.R,this.G,this.B),this.updateInputRGBHEX(this.R,this.G,this.B);break;case"S":this.S=t;var n=(0,s.hslToRgb)(this.H,this.S,this.L),l=o(n,3);this.R=l[0],this.G=l[1],this.B=l[2],this.updatePointerSL(this.H,this.S,this.L),this.updateInputHSL(this.H,this.S,this.L),this.updateInputRGB(this.R,this.G,this.B),this.updateInputRGBHEX(this.R,this.G,this.B);break;case"L":this.L=t;var h=(0,s.hslToRgb)(this.H,this.S,this.L),c=o(h,3);this.R=c[0],this.G=c[1],this.B=c[2],this.updatePointerSL(this.H,this.S,this.L),this.updateInputHSL(this.H,this.S,this.L),this.updateInputRGB(this.R,this.G,this.B),this.updateInputRGBHEX(this.R,this.G,this.B);break;case"R":this.R=t;var p=(0,s.rgbToHsl)(this.R,this.G,this.B),u=o(p,3);this.H=u[0],this.S=u[1],this.L=u[2],this.slBarHelper.setHue(this.H),this.updatePointerH(this.H),this.updatePointerSL(this.H,this.S,this.L),this.updateInputHSL(this.H,this.S,this.L),this.updateInputRGBHEX(this.R,this.G,this.B);break;case"G":this.G=t;var d=(0,s.rgbToHsl)(this.R,this.G,this.B),f=o(d,3);this.H=f[0],this.S=f[1],this.L=f[2],this.slBarHelper.setHue(this.H),this.updatePointerH(this.H),this.updatePointerSL(this.H,this.S,this.L),this.updateInputHSL(this.H,this.S,this.L),this.updateInputRGBHEX(this.R,this.G,this.B);break;case"B":this.B=t;var m=(0,s.rgbToHsl)(this.R,this.G,this.B),A=o(m,3);this.H=A[0],this.S=A[1],this.L=A[2],this.slBarHelper.setHue(this.H),this.updatePointerH(this.H),this.updatePointerSL(this.H,this.S,this.L),this.updateInputHSL(this.H,this.S,this.L),this.updateInputRGBHEX(this.R,this.G,this.B);break;case"RGB":var y=o(t,3);this.R=y[0],this.G=y[1],this.B=y[2];var k=(0,s.rgbToHsl)(this.R,this.G,this.B),F=o(k,3);this.H=F[0],this.S=F[1],this.L=F[2],this.updateInputHSL(this.H,this.S,this.L),this.updateInputRGB(this.R,this.G,this.B),this.updateInputRGBHEX(this.R,this.G,this.B);break;case b:var E=o(t,4);this.R=E[0],this.G=E[1],this.B=E[2],this.A=E[3];var C=(0,s.rgbToHsl)(this.R,this.G,this.B),H=o(C,3);this.H=H[0],this.S=H[1],this.L=H[2],this.slBarHelper.setHue(this.H),this.updatePointerH(this.H),this.updatePointerSL(this.H,this.S,this.L),this.updateInputHSL(this.H,this.S,this.L),this.updateInputRGB(this.R,this.G,this.B),this.updateInputRGBHEX(this.R,this.G,this.B),this.updatePointerA(this.A);break;case v:var B=o(t,4);this.H=B[0],this.S=B[1],this.L=B[2],this.A=B[3];var R=(0,s.hslToRgb)(this.H,this.S,this.L),S=o(R,3);this.R=S[0],this.G=S[1],this.B=S[2],this.slBarHelper.setHue(this.H),this.updatePointerH(this.H),this.updatePointerSL(this.H,this.S,this.L),this.updateInputHSL(this.H,this.S,this.L),this.updateInputRGB(this.R,this.G,this.B),this.updateInputRGBHEX(this.R,this.G,this.B),this.updatePointerA(this.A);break;case"RGBHEX":var L=(0,s.cssColorToRgb)(t)||[this.R,this.G,this.B],w=o(L,3);this.R=w[0],this.G=w[1],this.B=w[2];var x=(0,s.rgbToHsl)(this.R,this.G,this.B),T=o(x,3);this.H=T[0],this.S=T[1],this.L=T[2],this.slBarHelper.setHue(this.H),this.updatePointerH(this.H),this.updatePointerSL(this.H,this.S,this.L),this.updateInputHSL(this.H,this.S,this.L),this.updateInputRGB(this.R,this.G,this.B);break;case g:var I=(0,s.parseColor)(t,"rgba")||[0,0,0,1],G=o(I,4);this.R=G[0],this.G=G[1],this.B=G[2],this.A=G[3];var P=(0,s.rgbToHsl)(this.R,this.G,this.B),D=o(P,3);this.H=D[0],this.S=D[1],this.L=D[2],this.slBarHelper.setHue(this.H),this.updatePointerH(this.H),this.updatePointerSL(this.H,this.S,this.L),this.updateInputHSL(this.H,this.S,this.L),this.updateInputRGB(this.R,this.G,this.B),this.updateInputRGBHEX(this.R,this.G,this.B),this.updatePointerA(this.A);break;case"ALPHA":this.A=t}this.preview.style.backgroundColor=1===this.A?"rgb("+this.R+","+this.G+","+this.B+")":"rgba("+this.R+","+this.G+","+this.B+","+this.A+")",r&&r.silent||this.onchange&&this.onchange(this.preview.style.backgroundColor)}},{key:"onPaletteColorAdd",value(e){this.oncoloradd&&this.oncoloradd(e)}},{key:"onPaletteColorRemove",value(e){this.oncolorremove&&this.oncolorremove(e)}},{key:"updateInputHSL",value(e,t,r){this.options.showHSL&&(this.inputH.value=e,this.inputS.value=t,this.inputL.value=r)}},{key:"updateInputRGB",value(e,t,r){this.options.showRGB&&(this.inputR.value=e,this.inputG.value=t,this.inputB.value=r)}},{key:"updateInputRGBHEX",value(e,t,r){this.options.showHEX&&(this.inputRGBHEX.value=(0,s.rgbToHex)(e,t,r))}},{key:"updatePointerH",value(e){this.huePointer.style.left=this.options.hueBarSize[0]*e/360-7+"px"}},{key:"updatePointerSL",value(e,t,r){var i=(0,s.hslToRgb)(e,t,r),a=o(i,3),n=this.slBarHelper.findColor(a[0],a[1],a[2]),l=o(n,2),h=l[0],c=l[1];h>=0&&(this.slPointer.style.left=h-7+"px",this.slPointer.style.top=c-7+"px")}},{key:"updatePointerA",value(e){this.options.showAlpha&&(this.alphaPointer.style.left=this.options.alphaBarSize[0]*e-7+"px")}}]),e}(),F=function(){function e(t){h(this,e),this.name=t,this.listeners=[]}return i(e,[{key:"on",value(e){e&&this.listeners.push(e)}},{key:"off",value(e){this.listeners=e?this.listeners.filter((t=>t!==e)):[]}},{key:"emit",value(e,t){for(var r=this.listeners.slice(0),i=0;r.length>i;i++)r[i].apply(t,e)}}]),e}();function E(e,t){var r=new k(e,t),i={change:new F("change"),coloradd:new F("coloradd"),colorremove:new F("colorremove")},a=!0,n={},l={get element(){return r.element},get rgb(){return[r.R,r.G,r.B]},set rgb(e){var t=o(e,3),i=t[0],a=t[1],n=t[2],l=[(0,s.limit)(i,0,255),(0,s.limit)(a,0,255),(0,s.limit)(n,0,255)];r.onValueChanged(b,[i=l[0],a=l[1],n=l[2],1])},get hsl(){return[r.H,r.S,r.L]},set hsl(e){var t=o(e,3),i=t[0],a=t[1],n=t[2],l=[(0,s.limit)(i,0,360),(0,s.limit)(a,0,100),(0,s.limit)(n,0,100)];r.onValueChanged(v,[i=l[0],a=l[1],n=l[2],1])},get rgbhex(){return this.all.hex},get rgba(){return[r.R,r.G,r.B,r.A]},set rgba(e){var t=o(e,4),i=t[0],a=t[1],n=t[2],l=t[3],h=[(0,s.limit)(i,0,255),(0,s.limit)(a,0,255),(0,s.limit)(n,0,255),(0,s.limit)(l,0,1)];r.onValueChanged(b,[i=h[0],a=h[1],n=h[2],l=h[3]])},get hsla(){return[r.H,r.S,r.L,r.A]},set hsla(e){var t=o(e,4),i=t[0],a=t[1],n=t[2],l=t[3],h=[(0,s.limit)(i,0,360),(0,s.limit)(a,0,100),(0,s.limit)(n,0,100),(0,s.limit)(l,0,1)];r.onValueChanged(v,[i=h[0],a=h[1],n=h[2],l=h[3]])},get color(){return""+this.all},set color(e){r.onValueChanged(g,e)},setColor(e){r.onValueChanged(g,e,{silent:arguments.length>1&&void 0!==arguments[1]&&arguments[1]})},get all(){if(a){var e=[r.R,r.G,r.B,r.A],t=1>r.A?"rgba("+r.R+","+r.G+","+r.B+","+r.A+")":s.rgbToHex.apply(void 0,e);(n=(0,s.parseColor)(e,n)).toString=()=>t,a=!1}return Object.assign({},n)},get onchange(){return i.change&&i.change.listeners[0]},set onchange(e){this.off("change").on("change",e)},get oncoloradd(){return i.coloradd&&i.coloradd.listeners[0]},set oncoloradd(e){this.off("coloradd").on("coloradd",e)},get oncolorremove(){return i.colorremove&&i.colorremove.listeners[0]},set oncolorremove(e){this.off("colorremove").on("colorremove",e)},get palette(){return Object.keys(r.palette).filter((e=>r.palette[e]))},set palette(e){r.updatePalette(e)},show(){r.element.classList.remove("hidden")},hide(){r.element.classList.add("hidden")},toggle(){r.element.classList.toggle("hidden")},on(e,t){return e&&i[e]&&i[e].on(t),this},off(e,t){return e&&i[e]&&i[e].off(t),this},destroy(){i.change.off(),i.coloradd.off(),i.colorremove.off(),r.element.remove(),i=null,r=null}};return r.onchange=function(){for(var e=arguments.length,t=Array(e),r=0;e>r;r++)t[r]=arguments[r];a=!0,i.change.emit([l].concat(t),l)},r.oncoloradd=function(){for(var e=arguments.length,t=Array(e),r=0;e>r;r++)t[r]=arguments[r];i.coloradd.emit([l].concat(t),l)},r.oncolorremove=function(){for(var e=arguments.length,t=Array(e),r=0;e>r;r++)t[r]=arguments[r];i.colorremove.emit([l].concat(t),l)},r.element.ctrl=l,l}if("undefined"!=typeof window&&!document.querySelector('head>style[data-source="a-color-picker"]')){var C=""+r(5),H=document.createElement("style");H.setAttribute("type","text/css"),H.setAttribute("data-source","a-color-picker"),H.innerHTML=C,document.querySelector("head").appendChild(H)}t.createPicker=E,t.from=function(e,t){var r=(e=>e?Array.isArray(e)?e:e instanceof HTMLElement?[e]:e instanceof NodeList?[].concat(c(e)):"string"==typeof e?[].concat(c(document.querySelectorAll(e))):e.jquery?e.get():[]:[])(e).map(((e,r)=>{var i=E(e,t);return i.index=r,i}));return r.on=function(e,t){return r.forEach((r=>r.on(e,t))),this},r.off=function(e){return r.forEach((t=>t.off(e))),this},r},t.parseColorToRgb=s.parseColorToRgb,t.parseColorToRgba=s.parseColorToRgba,t.parseColorToHsl=s.parseColorToHsl,t.parseColorToHsla=s.parseColorToHsla,t.parseColor=s.parseColor,t.rgbToHex=s.rgbToHex,t.hslToRgb=s.hslToRgb,t.rgbToHsl=s.rgbToHsl,t.rgbToHsv=s.rgbToHsv,t.rgbToInt=s.rgbToInt,t.intToRgb=s.intToRgb,t.getLuminance=s.getLuminance,t.COLOR_NAMES=s.COLOR_NAMES,t.PALETTE_MATERIAL_500=s.PALETTE_MATERIAL_500,t.PALETTE_MATERIAL_CHROME=s.PALETTE_MATERIAL_CHROME,t.VERSION="1.2.1"},(e,t,r)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.nvl=t.ensureArray=t.limit=t.getLuminance=t.parseColor=t.parseColorToHsla=t.parseColorToHsl=t.cssHslaToHsla=t.cssHslToHsl=t.parseColorToRgba=t.parseColorToRgb=t.cssRgbaToRgba=t.cssRgbToRgb=t.cssColorToRgba=t.cssColorToRgb=t.intToRgb=t.rgbToInt=t.rgbToHsv=t.rgbToHsl=t.hslToRgb=t.rgbToHex=t.PALETTE_MATERIAL_CHROME=t.PALETTE_MATERIAL_500=t.COLOR_NAMES=void 0;var i=(e,t)=>{if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return((e,t)=>{var r=[],i=!0,o=!1,s=void 0;try{for(var a,n=e[Symbol.iterator]();!(i=(a=n.next()).done)&&(r.push(a.value),!t||r.length!==t);i=!0);}catch(e){o=!0,s=e}finally{try{!i&&n.return&&n.return()}finally{if(o)throw s}}return r})(e,t);throw new TypeError("Invalid attempt to destructure non-iterable instance")},o=(e=>e&&e.__esModule?e:{default:e})(r(0));function s(e){if(Array.isArray(e)){for(var t=0,r=Array(e.length);e.length>t;t++)r[t]=e[t];return r}return Array.from(e)}var a={aliceblue:"#F0F8FF",antiquewhite:"#FAEBD7",aqua:"#00FFFF",aquamarine:"#7FFFD4",azure:"#F0FFFF",beige:"#F5F5DC",bisque:"#FFE4C4",black:"#000000",blanchedalmond:"#FFEBCD",blue:"#0000FF",blueviolet:"#8A2BE2",brown:"#A52A2A",burlywood:"#DEB887",cadetblue:"#5F9EA0",chartreuse:"#7FFF00",chocolate:"#D2691E",coral:"#FF7F50",cornflowerblue:"#6495ED",cornsilk:"#FFF8DC",crimson:"#DC143C",cyan:"#00FFFF",darkblue:"#00008B",darkcyan:"#008B8B",darkgoldenrod:"#B8860B",darkgray:"#A9A9A9",darkgrey:"#A9A9A9",darkgreen:"#006400",darkkhaki:"#BDB76B",darkmagenta:"#8B008B",darkolivegreen:"#556B2F",darkorange:"#FF8C00",darkorchid:"#9932CC",darkred:"#8B0000",darksalmon:"#E9967A",darkseagreen:"#8FBC8F",darkslateblue:"#483D8B",darkslategray:"#2F4F4F",darkslategrey:"#2F4F4F",darkturquoise:"#00CED1",darkviolet:"#9400D3",deeppink:"#FF1493",deepskyblue:"#00BFFF",dimgray:"#696969",dimgrey:"#696969",dodgerblue:"#1E90FF",firebrick:"#B22222",floralwhite:"#FFFAF0",forestgreen:"#228B22",fuchsia:"#FF00FF",gainsboro:"#DCDCDC",ghostwhite:"#F8F8FF",gold:"#FFD700",goldenrod:"#DAA520",gray:"#808080",grey:"#808080",green:"#008000",greenyellow:"#ADFF2F",honeydew:"#F0FFF0",hotpink:"#FF69B4","indianred ":"#CD5C5C","indigo ":"#4B0082",ivory:"#FFFFF0",khaki:"#F0E68C",lavender:"#E6E6FA",lavenderblush:"#FFF0F5",lawngreen:"#7CFC00",lemonchiffon:"#FFFACD",lightblue:"#ADD8E6",lightcoral:"#F08080",lightcyan:"#E0FFFF",lightgoldenrodyellow:"#FAFAD2",lightgray:"#D3D3D3",lightgrey:"#D3D3D3",lightgreen:"#90EE90",lightpink:"#FFB6C1",lightsalmon:"#FFA07A",lightseagreen:"#20B2AA",lightskyblue:"#87CEFA",lightslategray:"#778899",lightslategrey:"#778899",lightsteelblue:"#B0C4DE",lightyellow:"#FFFFE0",lime:"#00FF00",limegreen:"#32CD32",linen:"#FAF0E6",magenta:"#FF00FF",maroon:"#800000",mediumaquamarine:"#66CDAA",mediumblue:"#0000CD",mediumorchid:"#BA55D3",mediumpurple:"#9370DB",mediumseagreen:"#3CB371",mediumslateblue:"#7B68EE",mediumspringgreen:"#00FA9A",mediumturquoise:"#48D1CC",mediumvioletred:"#C71585",midnightblue:"#191970",mintcream:"#F5FFFA",mistyrose:"#FFE4E1",moccasin:"#FFE4B5",navajowhite:"#FFDEAD",navy:"#000080",oldlace:"#FDF5E6",olive:"#808000",olivedrab:"#6B8E23",orange:"#FFA500",orangered:"#FF4500",orchid:"#DA70D6",palegoldenrod:"#EEE8AA",palegreen:"#98FB98",paleturquoise:"#AFEEEE",palevioletred:"#DB7093",papayawhip:"#FFEFD5",peachpuff:"#FFDAB9",peru:"#CD853F",pink:"#FFC0CB",plum:"#DDA0DD",powderblue:"#B0E0E6",purple:"#800080",rebeccapurple:"#663399",red:"#FF0000",rosybrown:"#BC8F8F",royalblue:"#4169E1",saddlebrown:"#8B4513",salmon:"#FA8072",sandybrown:"#F4A460",seagreen:"#2E8B57",seashell:"#FFF5EE",sienna:"#A0522D",silver:"#C0C0C0",skyblue:"#87CEEB",slateblue:"#6A5ACD",slategray:"#708090",slategrey:"#708090",snow:"#FFFAFA",springgreen:"#00FF7F",steelblue:"#4682B4",tan:"#D2B48C",teal:"#008080",thistle:"#D8BFD8",tomato:"#FF6347",turquoise:"#40E0D0",violet:"#EE82EE",wheat:"#F5DEB3",white:"#FFFFFF",whitesmoke:"#F5F5F5",yellow:"#FFFF00",yellowgreen:"#9ACD32"};function n(e,t,r){return isNaN(e=+e)||t>e?t:e>r?r:e}function l(e,t){return null==e?t:e}function h(e,t,r){var i=[n(e,0,255),n(t,0,255),n(r,0,255)];return"#"+("000000"+((e=i[0])<<16|(t=i[1])<<8|(r=i[2])).toString(16)).slice(-6)}function c(e,t,r){var i=void 0,o=void 0,s=void 0,a=[n(e,0,360)/360,n(t,0,100)/100,n(r,0,100)/100];if(e=a[0],r=a[2],0==(t=a[1]))i=o=s=r;else{var l=(e,t,r)=>(0>r&&(r+=1),r>1&&(r-=1),1/6>r?e+6*(t-e)*r:.5>r?t:2/3>r?e+(t-e)*(2/3-r)*6:e),h=.5>r?r*(1+t):r+t-r*t,c=2*r-h;i=l(c,h,e+1/3),o=l(c,h,e),s=l(c,h,e-1/3)}return[255*i,255*o,255*s].map(Math.round)}function p(e,t,r){var i=[n(e,0,255)/255,n(t,0,255)/255,n(r,0,255)/255],o=Math.max(e=i[0],t=i[1],r=i[2]),s=Math.min(e,t,r),a=void 0,l=void 0,h=(o+s)/2;if(o==s)a=l=0;else{var c=o-s;switch(l=h>.5?c/(2-o-s):c/(o+s),o){case e:a=(t-r)/c+(r>t?6:0);break;case t:a=(r-e)/c+2;break;case r:a=(e-t)/c+4}a/=6}return[360*a,100*l,100*h].map(Math.round)}function u(e,t,r){return e<<16|t<<8|r}function d(e){if(e){var t=/^\s*#?((([0-9A-F])([0-9A-F])([0-9A-F]))|(([0-9A-F]{2})([0-9A-F]{2})([0-9A-F]{2})))\s*$/i.exec(a[(""+e).toLowerCase()]||e)||[],r=i(t,10),o=r[3],s=r[4],n=r[5],l=r[7],h=r[8],c=r[9];if(void 0!==o)return[parseInt(o+o,16),parseInt(s+s,16),parseInt(n+n,16)];if(void 0!==l)return[parseInt(l,16),parseInt(h,16),parseInt(c,16)]}}function g(e){if(e){var t=/^\s*#?((([0-9A-F])([0-9A-F])([0-9A-F])([0-9A-F])?)|(([0-9A-F]{2})([0-9A-F]{2})([0-9A-F]{2})([0-9A-F]{2})?))\s*$/i.exec(a[(""+e).toLowerCase()]||e)||[],r=i(t,12),o=r[3],s=r[4],n=r[5],l=r[6],h=r[8],c=r[9],p=r[10],u=r[11];if(void 0!==o)return[parseInt(o+o,16),parseInt(s+s,16),parseInt(n+n,16),l?+(parseInt(l+l,16)/255).toFixed(2):1];if(void 0!==h)return[parseInt(h,16),parseInt(c,16),parseInt(p,16),u?+(parseInt(u,16)/255).toFixed(2):1]}}function b(e){if(e){var t=/^rgb\((\d+)[\s,](\d+)[\s,](\d+)\)/i.exec(e)||[],r=i(t,4),o=r[2],s=r[3];return r[0]?[n(r[1],0,255),n(o,0,255),n(s,0,255)]:void 0}}function v(e){if(e){var t=/^rgba?\((\d+)\s*[\s,]\s*(\d+)\s*[\s,]\s*(\d+)(\s*[\s,]\s*(\d*(.\d+)?))?\)/i.exec(e)||[],r=i(t,6),o=r[2],s=r[3],a=r[5];return r[0]?[n(r[1],0,255),n(o,0,255),n(s,0,255),n(l(a,1),0,1)]:void 0}}function f(e){if(Array.isArray(e))return[n(e[0],0,255),n(e[1],0,255),n(e[2],0,255),n(l(e[3],1),0,1)];var t=g(e)||v(e);return t&&3===t.length&&t.push(1),t}function m(e){if(e){var t=/^hsl\((\d+)[\s,](\d+)[\s,](\d+)\)/i.exec(e)||[],r=i(t,4),o=r[2],s=r[3];return r[0]?[n(r[1],0,360),n(o,0,100),n(s,0,100)]:void 0}}function A(e){if(e){var t=/^hsla?\((\d+)\s*[\s,]\s*(\d+)\s*[\s,]\s*(\d+)(\s*[\s,]\s*(\d*(.\d+)?))?\)/i.exec(e)||[],r=i(t,6),o=r[2],s=r[3],a=r[5];return r[0]?[n(r[1],0,255),n(o,0,255),n(s,0,255),n(l(a,1),0,1)]:void 0}}function y(e){if(Array.isArray(e))return[n(e[0],0,360),n(e[1],0,100),n(e[2],0,100),n(l(e[3],1),0,1)];var t=A(e);return t&&3===t.length&&t.push(1),t}function k(e,t){switch(t){case"rgb":default:return e.slice(0,3);case"rgbcss":return"rgb("+e[0]+", "+e[1]+", "+e[2]+")";case"rgbcss4":return"rgb("+e[0]+", "+e[1]+", "+e[2]+", "+e[3]+")";case"rgba":return e;case"rgbacss":return"rgba("+e[0]+", "+e[1]+", "+e[2]+", "+e[3]+")";case"hsl":return p.apply(void 0,s(e));case"hslcss":return"hsl("+(e=p.apply(void 0,s(e)))[0]+", "+e[1]+", "+e[2]+")";case"hslcss4":var r=p.apply(void 0,s(e));return"hsl("+r[0]+", "+r[1]+", "+r[2]+", "+e[3]+")";case"hsla":return[].concat(s(p.apply(void 0,s(e))),[e[3]]);case"hslacss":var i=p.apply(void 0,s(e));return"hsla("+i[0]+", "+i[1]+", "+i[2]+", "+e[3]+")";case"hex":return h.apply(void 0,s(e));case"hexcss4":return h.apply(void 0,s(e))+("00"+parseInt(255*e[3]).toString(16)).slice(-2);case"int":return u.apply(void 0,s(e))}}t.COLOR_NAMES=a,t.PALETTE_MATERIAL_500=["#F44336","#E91E63","#E91E63","#9C27B0","#9C27B0","#673AB7","#673AB7","#3F51B5","#3F51B5","#2196F3","#2196F3","#03A9F4","#03A9F4","#00BCD4","#00BCD4","#009688","#009688","#4CAF50","#4CAF50","#8BC34A","#8BC34A","#CDDC39","#CDDC39","#FFEB3B","#FFEB3B","#FFC107","#FFC107","#FF9800","#FF9800","#FF5722","#FF5722","#795548","#795548","#9E9E9E","#9E9E9E","#607D8B","#607D8B"],t.PALETTE_MATERIAL_CHROME=["#f44336","#e91e63","#9c27b0","#673ab7","#3f51b5","#2196f3","#03a9f4","#00bcd4","#009688","#4caf50","#8bc34a","#cddc39","#ffeb3b","#ffc107","#ff9800","#ff5722","#795548","#9e9e9e","#607d8b"],t.rgbToHex=h,t.hslToRgb=c,t.rgbToHsl=p,t.rgbToHsv=(e,t,r)=>{var i,o=[n(e,0,255)/255,n(t,0,255)/255,n(r,0,255)/255],s=Math.max(e=o[0],t=o[1],r=o[2]),a=Math.min(e,t,r),l=void 0,h=s,c=s-a;if(i=0===s?0:c/s,s==a)l=0;else{switch(s){case e:l=(t-r)/c+(r>t?6:0);break;case t:l=(r-e)/c+2;break;case r:l=(e-t)/c+4}l/=6}return[l,i,h]},t.rgbToInt=u,t.intToRgb=e=>[e>>16&255,e>>8&255,255&e],t.cssColorToRgb=d,t.cssColorToRgba=g,t.cssRgbToRgb=b,t.cssRgbaToRgba=v,t.parseColorToRgb=e=>Array.isArray(e)?e=[n(e[0],0,255),n(e[1],0,255),n(e[2],0,255)]:d(e)||b(e),t.parseColorToRgba=f,t.cssHslToHsl=m,t.cssHslaToHsla=A,t.parseColorToHsl=e=>Array.isArray(e)?e=[n(e[0],0,360),n(e[1],0,100),n(e[2],0,100)]:m(e),t.parseColorToHsla=y,t.parseColor=(e,t)=>{if(t=t||"rgb",null!=e){var r=void 0;if((r=f(e))||(r=y(e))&&(r=[].concat(s(c.apply(void 0,s(r))),[r[3]])))return(0,o.default)(t)?["rgb","rgbcss","rgbcss4","rgba","rgbacss","hsl","hslcss","hslcss4","hsla","hslacss","hex","hexcss4","int"].reduce(((e,t)=>(e[t]=k(r,t),e)),t||{}):k(r,(""+t).toLowerCase())}},t.getLuminance=(e,t,r)=>.2126*(e=.03928>(e/=255)?e/12.92:Math.pow((e+.055)/1.055,2.4))+.7152*(t=.03928>(t/=255)?t/12.92:Math.pow((t+.055)/1.055,2.4))+.0722*(.03928>(r/=255)?r/12.92:Math.pow((r+.055)/1.055,2.4)),t.limit=n,t.ensureArray=e=>e?Array.from(e):[],t.nvl=l},(e,t,r)=>{"use strict";e.exports=e=>null!=e&&"object"==typeof e&&!1===Array.isArray(e)},(e,t)=>{e.exports='<div class="a-color-picker-row a-color-picker-stack a-color-picker-row-top"> <canvas class="a-color-picker-sl a-color-picker-transparent"></canvas> <div class=a-color-picker-dot></div> </div> <div class=a-color-picker-row> <div class="a-color-picker-stack a-color-picker-transparent a-color-picker-circle"> <div class=a-color-picker-preview> <input class=a-color-picker-clipbaord type=text> </div> </div> <div class=a-color-picker-column> <div class="a-color-picker-cell a-color-picker-stack"> <canvas class=a-color-picker-h></canvas> <div class=a-color-picker-dot></div> </div> <div class="a-color-picker-cell a-color-picker-alpha a-color-picker-stack" show-on-alpha> <canvas class="a-color-picker-a a-color-picker-transparent"></canvas> <div class=a-color-picker-dot></div> </div> </div> </div> <div class="a-color-picker-row a-color-picker-hsl" show-on-hsl> <label>H</label> <input nameref=H type=number maxlength=3 min=0 max=360 value=0> <label>S</label> <input nameref=S type=number maxlength=3 min=0 max=100 value=0> <label>L</label> <input nameref=L type=number maxlength=3 min=0 max=100 value=0> </div> <div class="a-color-picker-row a-color-picker-rgb" show-on-rgb> <label>R</label> <input nameref=R type=number maxlength=3 min=0 max=255 value=0> <label>G</label> <input nameref=G type=number maxlength=3 min=0 max=255 value=0> <label>B</label> <input nameref=B type=number maxlength=3 min=0 max=255 value=0> </div> <div class="a-color-picker-row a-color-picker-rgbhex a-color-picker-single-input" show-on-single-input> <label>HEX</label> <input nameref=RGBHEX type=text select-on-focus> </div> <div class="a-color-picker-row a-color-picker-palette"></div>'},(e,t,r)=>{var i=r(6);e.exports="string"==typeof i?i:""+i},(e,t,r)=>{(e.exports=r(7)(!1)).push([e.i,"/*!\n * a-color-picker\n * https://github.com/narsenico/a-color-picker\n *\n * Copyright (c) 2017-2018, Gianfranco Caldi.\n * Released under the MIT License.\n */.a-color-picker{background-color:#fff;padding:0;display:inline-flex;flex-direction:column;user-select:none;width:232px;font:400 10px Helvetica,Arial,sans-serif;border-radius:3px;box-shadow:0 0 0 1px rgba(0,0,0,.05),0 2px 4px rgba(0,0,0,.25)}.a-color-picker,.a-color-picker-row,.a-color-picker input{box-sizing:border-box}.a-color-picker-row{padding:15px;display:flex;flex-direction:row;align-items:center;justify-content:space-between;user-select:none}.a-color-picker-row-top{padding:0}.a-color-picker-row:not(:first-child){border-top:1px solid #f5f5f5}.a-color-picker-column{display:flex;flex-direction:column}.a-color-picker-cell{flex:1 1 auto;margin-bottom:4px}.a-color-picker-cell:last-child{margin-bottom:0}.a-color-picker-stack{position:relative}.a-color-picker-dot{position:absolute;width:14px;height:14px;top:0;left:0;background:#fff;pointer-events:none;border-radius:50px;z-index:1000;box-shadow:0 1px 2px rgba(0,0,0,.75)}.a-color-picker-a,.a-color-picker-h,.a-color-picker-sl{cursor:cell}.a-color-picker-a+.a-color-picker-dot,.a-color-picker-h+.a-color-picker-dot{top:-2px}.a-color-picker-a,.a-color-picker-h{border-radius:2px}.a-color-picker-preview{box-sizing:border-box;width:30px;height:30px;user-select:none;border-radius:15px}.a-color-picker-circle{border-radius:50px;border:1px solid #eee}.a-color-picker-hsl,.a-color-picker-rgb,.a-color-picker-single-input{justify-content:space-evenly}.a-color-picker-hsl>label,.a-color-picker-rgb>label,.a-color-picker-single-input>label{padding:0 8px;flex:0 0 auto;color:#969696}.a-color-picker-hsl>input,.a-color-picker-rgb>input,.a-color-picker-single-input>input{text-align:center;padding:2px 0;width:0;flex:1 1 auto;border:1px solid #e0e0e0;line-height:20px}.a-color-picker-hsl>input::-webkit-inner-spin-button,.a-color-picker-rgb>input::-webkit-inner-spin-button,.a-color-picker-single-input>input::-webkit-inner-spin-button{-webkit-appearance:none;margin:0}.a-color-picker-hsl>input:focus,.a-color-picker-rgb>input:focus,.a-color-picker-single-input>input:focus{border-color:#04a9f4;outline:none}.a-color-picker-transparent{background-image:linear-gradient(-45deg,#cdcdcd 25%,transparent 0),linear-gradient(45deg,#cdcdcd 25%,transparent 0),linear-gradient(-45deg,transparent 75%,#cdcdcd 0),linear-gradient(45deg,transparent 75%,#cdcdcd 0);background-size:11px 11px;background-position:0 0,0 -5.5px,-5.5px 5.5px,5.5px 0}.a-color-picker-sl{border-radius:3px 3px 0 0}.a-color-picker.hide-alpha [show-on-alpha],.a-color-picker.hide-hsl [show-on-hsl],.a-color-picker.hide-rgb [show-on-rgb],.a-color-picker.hide-single-input [show-on-single-input]{display:none}.a-color-picker-clipbaord{width:100%;height:100%;opacity:0;cursor:pointer}.a-color-picker-palette{flex-flow:wrap;flex-direction:row;justify-content:flex-start;padding:10px}.a-color-picker-palette-color{width:15px;height:15px;flex:0 1 15px;margin:3px;box-sizing:border-box;cursor:pointer;border-radius:3px;box-shadow:inset 0 0 0 1px rgba(0,0,0,.1)}.a-color-picker-palette-add{text-align:center;line-height:13px;color:#607d8b}.a-color-picker.hidden{display:none}",""])},function(e,t){e.exports=function(e){var t=[];return t.toString=function(){return this.map((t=>{var r=((e,t)=>{var r=e[1]||"",i=e[3];if(!i)return r;if(t&&"function"==typeof btoa){var o=(e=>"/*# sourceMappingURL=data:application/json;charset=utf-8;base64,"+btoa(unescape(encodeURIComponent(JSON.stringify(e))))+" */")(i),s=i.sources.map((e=>"/*# sourceURL="+i.sourceRoot+e+" */"));return[r].concat(s).concat([o]).join("\n")}return""+r})(t,e);return t[2]?"@media "+t[2]+"{"+r+"}":r})).join("")},t.i=function(e,r){"string"==typeof e&&(e=[[null,e,""]]);for(var i={},o=0;this.length>o;o++){var s=this[o][0];"number"==typeof s&&(i[s]=!0)}for(o=0;e.length>o;o++){var a=e[o];"number"==typeof a[0]&&i[a[0]]||(r&&!a[2]?a[2]=r:r&&(a[2]="("+a[2]+") and ("+r+")"),t.push(a))}},t}}])},202(e,t,r){"use strict";r.r(t),r.d(t,{colorPicker:()=>h});var i=r(39),o=r(56),s=r(4),a=r(203),n=r(36),l=r(1);class h extends o.S{constructor(){super(...arguments),this.requires=["license"],this.hasStyle=!l.Jodit.fatMode}afterInit(e){e.e.on("afterGenerateColorPicker",this.onAfterGenerateColorPicker)}onAfterGenerateColorPicker(e,t,r,i){s.Dom.detach(t);const o=new a.T(this.j,r);o.value=i||"#000",t.appendChild(o.container)}beforeDestruct(e){e.e.off("afterGenerateColorPicker",this.onAfterGenerateColorPicker)}}(0,i.gn)([n.autobind],h.prototype,"onAfterGenerateColorPicker",null),l.Jodit.plugins.add("color-picker",h)},203(e,t,r){"use strict";r.d(t,{T:()=>h});var i=r(39),o=r(27),s=r(36),a=r(10),n=r(204),l=r(4);let h=class extends o.u3{constructor(e,t){super(e);const r=new o.GI(e);this.trigger.onAction((()=>{t(this.value),r.close()})),r.setMod("padding",!1).setMod("max-height",!1);const i=this.j.create.div(this.getFullElName("picker")),s=n.createPicker(i,{paletteEditable:!0,showAlpha:!0,palette:"PALETTE_MATERIAL_CHROME"}).on("change",((e,t)=>{this.isFocused||(this.value=n.parseColor(t||"","hex"))}));this.j.e.on(this,"change",(()=>{n.parseColor(this.value,"hex")!==s.color&&(s.color=this.value)})),r.setContent(i),this.j.e.on(this.nativeInput,"click",(()=>{r.parentElement=this,this.jodit instanceof l.Dialog&&r.setZIndex(this.jodit.getZIndex()+1),r.open((()=>(0,a.position)(this.container)))}))}className(){return"ColorInput"}createContainer(e){const t=super.createContainer(e);return this.trigger=(0,o.zx)(this.j,"ok"),t.appendChild(this.trigger.container),this.trigger.container.classList.add(this.getFullElName("trigger")),t}setMod(e,t,r=this.container){return"slim"===e&&t&&this.nativeInput.setAttribute("readonly","true"),super.setMod(e,t,r)}onChangeSelfValue(){this.nativeInput.style.backgroundColor=this.value}};(0,i.gn)([(0,s.watch)(":change")],h.prototype,"onChangeSelfValue",null),h=(0,i.gn)([s.component],h)}},e=>{"use strict";return e(e.s=202)}])}));
/*!
* jodit-pro - PRO Version of Jodit Editor
* Author: Chupurnov Valeriy <chupurnov@gmail.com>
* Version: v1.0.45
* Version: v1.0.46
* Url: https://xdsoft.net/jodit/pro/

@@ -10,2 +10,2 @@ * License(s): SEE LICENSE IN LICENSE.md

!function(e,t){if("object"==typeof exports&&"object"==typeof module)module.exports=t();else if("function"==typeof define&&define.amd)define([],t);else{var o=t();for(var n in o)("object"==typeof exports?exports:e)[n]=o[n]}}(self,(function(){return(self.webpackChunkjodit_pro=self.webpackChunkjodit_pro||[]).push([[524],{435:e=>{e.exports='<svg viewBox="0 0 512 512" xmlns="http://www.w3.org/2000/svg"> <path d="M365.4,59.628c60.56,0,109.6,49.03,109.6,109.47c0,109.47-109.6,171.8-219.06,281.271 C146.47,340.898,37,278.568,37,169.099c0-60.44,49.04-109.47,109.47-109.47c54.73,0,82.1,27.37,109.47,82.1 C283.3,86.999,310.67,59.628,365.4,59.628z"/> </svg>'},436:e=>{e.exports='<svg viewBox="0 0 32 32" xmlns="http://www.w3.org/2000/svg"> <path d="M28.7,16.3l-12-13c-0.4-0.4-1.1-0.4-1.5,0l-12,13C3,16.6,2.9,17,3.1,17.4C3.2,17.8,3.6,18,4,18h3v10c0,0.6,0.4,1,1,1h16 c0.6,0,1-0.4,1-1V18h3c0.4,0,0.8-0.2,0.9-0.6C29.1,17,29,16.6,28.7,16.3z"/> </svg>'},433:(e,t,o)=>{"use strict";o.r(t)},461:(e,t,o)=>{"use strict";o.r(t)},468:(e,t,o)=>{"use strict";o.r(t)},442:(e,t,o)=>{"use strict";o.r(t)},476:(e,t,o)=>{"use strict";o.r(t)},446:(e,t,o)=>{"use strict";o.r(t)},438:(e,t,o)=>{"use strict";o.r(t)},465:(e,t,o)=>{"use strict";o.r(t)},470:(e,t,o)=>{"use strict";o.r(t)},453:(e,t,o)=>{"use strict";o.r(t)},449:(e,t,o)=>{"use strict";o.r(t)},457:(e,t,o)=>{"use strict";o.r(t)},455:(e,t,o)=>{"use strict";o.r(t)},463:(e,t,o)=>{"use strict";o.r(t)},459:(e,t,o)=>{"use strict";o.r(t)},440:(e,t,o)=>{"use strict";o.r(t)},451:(e,t,o)=>{"use strict";o.r(t)},444:(e,t,o)=>{"use strict";o.r(t)},432:(e,t,o)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.FileBrowserPro=void 0;var n=o(1);o(433),o(434);var r=o(14),i=o(166),s=o(437),a=o(23),c=o(103),l=o(13),u=o(466),h=o(467),d=o(199),p=o(12),f=o(469),v=o(193),m=o(471),g=o(472),y=o(473),w=o(474),_=o(2),I=o(430),b=o(475),S=function(e){function t(t){var o=e.call(this,a.ConfigProto(Object.assign(t||{},{resizable:!0,draggable:!0,toolbarButtons:(null==t?void 0:t.buttons)||p.Config.defaultOptions.filebrowser.buttons,buttons:_.Jodit.atom(["filebrowser.settings","fullsize","dialog.close"])}),p.Config.defaultOptions.filebrowser))||this;return o.dataProvider=v.makeDataProvider(o,o.options),o.state=r.ObserveObject.create({onSelectCallBack:null,theme:"default",showSideBar:!0,showFavorites:!0,showSettings:!1,showPreview:!1,withFolders:!0,foldersPosition:"bottom",info:"",metaInfo:null,currentPath:"",currentSource:"",currentBaseUrl:"",history:[],historyIndex:0,tree:[],activeElements:[],favorites:[],progress:0,lastSelectedIndex:0,elements:[],messages:[],sources:[],view:"tiles",tileSize:"default",sortBy:"name-asc",filterWord:"",onlyImages:!1},["state"]),o.persistent=new m.PersistentStore(o,o.state),o.stateManager=new u.StateManager(o.state),o.historyManager=new g.HistoryManager(o,o.state),o.contextMenuManager=new y.ContextMenuManager(o),o.header=new h.UIBrowserHeader(o,o.options,o.stateManager),o.panel=new s.UIBrowserPanel(o,o.stateManager),o.progressbar=new f.UIProgress(o,o.stateManager.state),o.offset=0,o.countInOneChunk=20,o.stopLoadingParts=!1,I.license.make(o),!o.persistent.theme&&o.options.theme&&(o.persistent.theme=o.options.theme),o.panel.append(o.progressbar),o.toolbar.setMod("mode","header"),o.setSize(Math.min(o.options.width,screen.width),Math.min(o.options.height,screen.height)).setHeader(o.header),o.onResizeWindow(),o.initUploader(),o.onChangeTheme(),o.fullFillOptions(),o.dataProvider.onProgress((function(e){0===e&&(e=30),o.state.progress=e})),o.e.on("beforeClose",o.removeGlobalListeners),o.e.fire("afterInit"),_.Jodit.prototype.afterInitHook.call(o),o}return n.__extends(t,e),t.prototype.className=function(){return"FileBrowserPro"},t.prototype.lock=function(t){return void 0===t&&(t="any"),this.container.classList.add("jodit_disabled"),e.prototype.lock.call(this,t)},t.prototype.unlock=function(){return this.container.classList.remove("jodit_disabled"),e.prototype.unlock.call(this)},t.prototype.status=function(e,t){var o=this;void 0===t&&(t=!(e instanceof Error)),Error;var n={message:a.isString(e)?e:e.message,type:t?"success":"error"};this.stateManager.addMessage(n),this.async.setTimeout((function(){o.stateManager.removeMessage(n)}),this.options.howLongShowMsg)},t.prototype.addDisclaimer=function(e){this.dialog.appendChild(e)},t.prototype.onResizeWindow=function(){a.css(this.dialog,{maxWidth:screen.width,minHeight:Math.min(this.options.height,screen.height),minWidth:Math.min(this.options.width,screen.width)})},t.prototype.open=function(t,o){return n.__awaiter(this,void 0,Promise,(function(){return n.__generator(this,(function(n){return this.state.onlyImages=Boolean(o),this.prepareOpening(t),e.prototype.open.call(this,this.panel.container),[2,this.onUpdateFileBrowser()]}))}))},t.prototype.onChangeTheme=function(){this.setMod("theme",this.state.theme),this.header.setMod("theme",this.state.theme),this.panel.setMod("theme",this.state.theme),this.options.theme=this.state.theme},t.prototype.onToggleSettings=function(){this.state.showSettings=!this.state.showSettings},t.prototype.onUpdateFileBrowser=function(){return n.__awaiter(this,void 0,Promise,(function(){return n.__generator(this,(function(e){switch(e.label){case 0:return this.state.activeElements=[],this.panel.setMod("loading",!0),[4,Promise.all([this.loadFolders(),this.loadItems()])];case 1:return e.sent(),this.panel.setMod("loading",!1),this.historyManager.updateHistory(),[2]}}))}))},t.prototype.loadFolders=function(){return n.__awaiter(this,void 0,Promise,(function(){var e,t,o,r,i;return n.__generator(this,(function(n){switch(n.label){case 0:if(!this.isOpened)return[2];t=(e=this.state).currentPath,o=e.currentSource,this.historyManager.push(),n.label=1;case 1:return n.trys.push([1,3,,4]),this.uploader.setPath(t),this.uploader.setSource(o),[4,this.dataProvider.tree(t,o)];case 2:return r=n.sent(),this.stateManager.fillSources(r,t),this.historyManager.updateHistory(),this.state.sources=r,[3,4];case 3:return i=n.sent(),this.status(i),[3,4];case 4:return[2]}}))}))},t.prototype.loadItems=function(){return n.__awaiter(this,void 0,Promise,(function(){var e,t;return n.__generator(this,(function(o){switch(o.label){case 0:if(!this.isOpened)return[2];o.label=1;case 1:return o.trys.push([1,6,,7]),this.offset=0,this.stopLoadingParts=!1,e=this.state,[4,this.loadPartItems()];case 2:e.elements=o.sent(),this.stopLoadingParts=this.countInOneChunk>this.state.elements.length,o.label=3;case 3:return this.stopLoadingParts||this.state.elements.length>this.panel.countInColumn*this.panel.countInRow?[3,5]:[4,this.loadItemsChunk()];case 4:return o.sent(),[3,3];case 5:return this.historyManager.updateHistory(),[3,7];case 6:return t=o.sent(),this.status(t),[3,7];case 7:return[2]}}))}))},t.prototype.loadItemsChunk=function(){return n.__awaiter(this,void 0,Promise,(function(){var e,t;return n.__generator(this,(function(o){switch(o.label){case 0:if(this.stopLoadingParts)return[2];o.label=1;case 1:return o.trys.push([1,3,,4]),this.offset+=this.countInOneChunk,[4,this.loadPartItems()];case 2:return e=o.sent(),this.stopLoadingParts=this.countInOneChunk>e.length,e.length&&(this.state.elements=this.state.elements.concat(e)),[3,4];case 3:return t=o.sent(),this.status(t),[3,4];case 4:return[2]}}))}))},t.prototype.prepareOpening=function(e){var t=this;this.registerGlobalListeners(),e&&(this.state.onSelectCallBack=function(o){t.close(),e(o)}),this.persistent.syncWithState()},t.prototype.registerGlobalListeners=function(){this.e.on(this.ow,"keydown",this.onKeyPress)},t.prototype.onKeyPress=function(e){var t=this.od.activeElement;if(this.state.activeElements.length&&t&&r.Dom.isOrContains(this.panel.items.container,t)){var o=this.state.elements;switch(e.key){case l.KEY_ENTER:return this.onChooseItems();case l.KEY_DELETE:return this.onFileRemove();case l.KEY_RIGHT:case l.KEY_LEFT:case l.KEY_DOWN:case l.KEY_UP:var n=e.key===l.KEY_RIGHT||e.key===l.KEY_DOWN,i=this.state.lastSelectedIndex,s=void 0;if([l.KEY_RIGHT,l.KEY_LEFT].includes(e.key))s=n?o[i+1]?i+1:0:o[i-1]?i-1:o.length-1;else{var a=this.panel.countInRow;s=Math.round(((i+1)/a+(n?1:-1))*a-1)}return o[s]&&this.stateManager.addActive(o[s],e.shiftKey),!1}}},t.prototype.removeGlobalListeners=function(){this.e.off(this.ow,"keydown",this.onKeyPress)},t.prototype.onFileRemove=function(){var e=this;this.state.activeElements.length&&r.Confirm(this.i18n("Are you sure?"),"",(function(t){if(t){var o=[];e.state.activeElements.forEach((function(t){e.stateManager.isFavorite(t)&&e.stateManager.toggleFavorite(t),o.push(e.deleteFile(t.file||t.name||"",t.sourceName))})),e.state.activeElements=[],Promise.all(o).then((function(){return e.loadItems()}))}})).bindDestruct(this)},t.prototype.onFileEdit=function(){if(1===this.state.activeElements.length){var e=this.state.activeElements[0];d.openImageEditor.call(this,e.fileURL,e.file||"",e.path,e.sourceName,void 0,this.status)}},t.prototype.onFolderRename=function(e){var t=this;r.Prompt(this.i18n("Enter new name"),this.i18n("Rename"),(function(o){if(!a.isValidName(o)||o===e.name)return t.status(t.i18n("Enter new name")),!1;t.dataProvider.folderRename(w.parentPath(e.path),e.name,o,e.sourceName).then((function(n){t.state.activeElements=[],t.status(n,!0),t.state.currentPath=w.parentPath(e.path)+"/"+o,t.state.currentSource=e.sourceName,t.loadFolders()})).catch(t.status)}),this.i18n("type name"),e.name).bindDestruct(this)},t.prototype.onFolderRemove=function(e){var t=this;r.Confirm(this.i18n("Are you sure?"),this.i18n("Delete"),(function(o){o&&t.dataProvider.folderRemove(w.parentPath(e.path),e.name,e.sourceName).then((function(o){t.status(o,!0),t.state.currentPath=w.parentPath(e.path),t.state.currentSource=e.sourceName,t.loadFolders()})).catch(t.status)})).bindDestruct(this)},t.prototype.onFolderCreate=function(e){var t=this;r.Prompt(this.i18n("Enter Directory name"),this.i18n("Create directory"),(function(o){var n=e.path||"/";t.dataProvider.createFolder(o,e.path||"/",e.sourceName).then((function(){t.state.currentSource===e.sourceName&&t.state.currentPath===n?t.onUpdateFileBrowser():(t.state.currentSource=e.sourceName,t.state.currentPath=n)}),t.status)}),this.i18n("type name")).bindDestruct(this)},t.prototype.onFileRename=function(e){var t=this,o=e.file||e.name||"";1===this.state.activeElements.length&&o&&r.Prompt(this.i18n("Enter new name"),this.i18n("Rename"),(function(e){if(!a.isValidName(e))return t.status(t.i18n("Enter new name")),!1;t.dataProvider.fileRename(t.state.currentPath,o,e,t.state.currentSource).then((function(e){t.state.activeElements=[],t.status(e,!0),t.loadItems()})).catch(t.status)}),this.i18n("type name"),o).bindDestruct(this)},t.prototype.onChooseItems=function(){var e=this.stateManager.state.activeElements;if(e.length){if("folder"===e[0].type)return this.state.currentPath=this.state.currentPath+"/"+e[0].name,void(this.state.currentSource=e[0].sourceName);this.state.onSelectCallBack?this.stateManager.callSelectHandler():this.onOpenLightBox(e[0])}},t.prototype.onOpenLightBox=function(e){b.UILightBox.open(this,e,this.state.elements)},t.prototype.deleteFile=function(e,t){var o=this;return this.dataProvider.fileRemove(this.state.currentPath,e,t).then((function(t){o.status(t||o.i18n('File "%s" was deleted',e),!0)})).catch(this.status)},t.prototype.initUploader=function(){var e=this,t=this,o=a.ConfigProto(t.o.uploader||{},p.Config.defaultOptions.uploader),n=function(){return e.loadItems()};t.uploader=t.getInstance("Uploader",o),t.uploader.bind(t.panel.container,n,t.status),t.e.on("bindUploader.filebrowser",(function(e){t.uploader.bind(e,n,t.status)}))},t.prototype.destruct=function(){this.removeGlobalListeners(),this.header.destruct(),this.panel.destruct(),e.prototype.destruct.call(this)},t.prototype.fullFillOptions=function(){var e=this;["getLocalFileByUrl","crop","resize","create","fileMove","folderMove","fileRename","folderRename","fileRemove","folderRemove","folder","items","permissions"].forEach((function(t){null!=e.options[t]&&(e.options[t]=a.ConfigProto(e.options[t],e.o.ajax))}))},t.prototype.loadPartItems=function(){return this.dataProvider.items(this.state.currentPath,this.state.currentSource,{offset:this.offset,limit:this.countInOneChunk,sortBy:this.state.sortBy,withFolders:this.state.withFolders,foldersPosition:this.state.foldersPosition,onlyImages:this.state.onlyImages,filterWord:this.state.filterWord})},n.__decorate([c.autobind],t.prototype,"status",null),n.__decorate([c.watch(":resize",window)],t.prototype,"onResizeWindow",null),n.__decorate([c.watch("state.theme")],t.prototype,"onChangeTheme",null),n.__decorate([c.watch(":toggleSettings.filebrowser")],t.prototype,"onToggleSettings",null),n.__decorate([c.watch(":update.filebrowser")],t.prototype,"onUpdateFileBrowser",null),n.__decorate([c.watch(["state.currentPath","state.currentSource"]),c.debounce((function(e){return{timeout:e.defaultTimeout,promisify:!0}}))],t.prototype,"loadFolders",null),n.__decorate([c.watch(["state.currentPath","state.currentSource","state.sortBy","state.onlyImages","state.foldersPosition","state.filterWord"]),c.debounce((function(e){return{timeout:e.defaultTimeout,promisify:!0}}))],t.prototype,"loadItems",null),n.__decorate([c.debounce((function(e){return{timeout:e.defaultTimeout,promisify:!0}}))],t.prototype,"loadItemsChunk",null),n.__decorate([c.autobind],t.prototype,"onKeyPress",null),n.__decorate([c.autobind],t.prototype,"removeGlobalListeners",null),n.__decorate([c.watch(":fileRemove.filebrowser")],t.prototype,"onFileRemove",null),n.__decorate([c.watch(":edit.filebrowser")],t.prototype,"onFileEdit",null),n.__decorate([c.watch(":folderRename.filebrowser")],t.prototype,"onFolderRename",null),n.__decorate([c.watch(":folderRemove.filebrowser")],t.prototype,"onFolderRemove",null),n.__decorate([c.watch(":folderCreate.filebrowser")],t.prototype,"onFolderCreate",null),n.__decorate([c.watch(":fileRename.filebrowser")],t.prototype,"onFileRename",null),n.__decorate([c.watch(":select.filebrowser")],t.prototype,"onChooseItems",null),n.__decorate([c.watch(":openLightBox.filebrowser")],t.prototype,"onOpenLightBox",null),n.__decorate([c.component],t)}(i.Dialog);t.FileBrowserPro=S,_.Jodit.modules.FileBrowserPro=S},477:(e,t,o)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=o(12);o(34).extendLang(o(478));var r=n.Config.prototype.controls.filebrowser;r.settings={icon:"settings",exec:function(e){e.e.fire("toggleSettings.filebrowser")}},r.home={icon:"home",exec:function(e){e.e.fire("goHome.filebrowser")}},r.preview={icon:"eye",exec:function(e){e.e.fire("togglePreview.filebrowser")}},r.next={icon:"angle-right",isDisabled:function(e){if(!e.state)return!0;var t=e.state,o=t.history;return!o||!o.length||t.historyIndex===o.length-1},exec:function(e){e.e.fire("next.filebrowser")}},r.previous={icon:"angle-left",isDisabled:function(e){if(!e.state)return!0;var t=e.state,o=t.history;return!o||!o.length||0===t.historyIndex},exec:function(e){e.e.fire("previous.filebrowser")}},Object.assign(n.Config.prototype.filebrowser,{buttons:["filebrowser.home","filebrowser.previous","filebrowser.next","|","filebrowser.upload","filebrowser.remove","filebrowser.update","filebrowser.select","filebrowser.edit","|","filebrowser.preview","about"],sort:!1,pixelOffsetLoadNewChunk:200,width:750,height:400,previewOfficeURL:"https://view.officeapps.live.com/op/view.aspx?src="})},431:(e,t,o)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.finder=void 0;var n=o(1),r=o(187),i=o(432),s=o(2);o(477);var a=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.requires=["license"],t.hasStyle=!s.Jodit.fatMode,t}return n.__extends(t,e),t.prototype.afterInit=function(e){var t=this;e.e.on("getInstanceFileBrowser",(function(e){return t.__instance||(t.__instance=new i.FileBrowserPro(e)),t.__instance}))},t.prototype.beforeDestruct=function(e){var t;e.e.off("getInstanceFileBrowser"),null===(t=this.__instance)||void 0===t||t.destruct()},t}(r.Plugin);t.finder=a,s.Jodit.plugins.add("finder",a)},473:(e,t,o)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ContextMenuManager=void 0;var n=o(1),r=o(193),i=o(31),s=o(103),a=o(199),c=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return n.__extends(t,e),t.prototype.className=function(){return"ContextMenuManager"},t.prototype.onFolderContext=function(e,t){return this.buildContextItemMenu(this.getFolderContextActions(e),t),!1},t.prototype.onItemContext=function(e,t,o){return this.buildContextItemMenu(this.getItemContextActions(e),o),!1},t.prototype.onSourceContext=function(e,t){return this.buildContextItemMenu(this.getSourceContextActions(e),t),!1},t.prototype.buildContextItemMenu=function(e,t){if(this.j.o.contextMenu){var o=r.makeContextMenu(this.j).setMod("theme",this.j.state.theme);o.show(t.clientX,t.clientY,e.filter((function(e){return e&&!1!==e.enabled}))),this.j.e.on(this.j,"afterClose",(function(){o.isOpened&&o.close()}))}},t.prototype.getItemContextActions=function(e){var t=this;if(this.j.stateManager.isActive(e)||this.j.stateManager.addActive(e,this.j.state.activeElements.length>1),"folder"===e.type)return this.getFolderContextActions({type:"directory",children:[],name:e.name||"",path:e.path,sourceName:e.sourceName});var o=this.j.options,n=this.j.dataProvider,r=1===this.j.state.activeElements.length;return[{icon:"pencil",title:"Edit",enabled:Boolean(e.isImage)&&o.editImage&&r&&(n.canI("ImageResize")||n.canI("ImageCrop")),exec:function(){a.openImageEditor.call(t.j,e.imageURL,e.name||"",t.j.state.currentPath,t.j.state.currentSource)}},{icon:"italic",title:"Rename",enabled:n.canI("FileRename")&&r,exec:function(){return t.j.e.fire("fileRename.filebrowser",e)}},{icon:"bin",title:"Delete",enabled:n.canI("FileRemove"),exec:function(){return t.j.e.fire("fileRemove.filebrowser",e)}},{icon:"eye",title:"Preview",enabled:Boolean(e.isImage)&&o.preview&&r,exec:function(){return t.j.e.fire("openLightBox.filebrowser",e)}},{icon:"upload",title:"Download",exec:function(){e.fileURL&&t.j.ow.open(e.fileURL)}}]},t.prototype.getFolderContextActions=function(e){var t=this,o=this.j.dataProvider;return[{icon:"pencil",title:"Rename",exec:function(){t.j.e.fire("folderRename.filebrowser",e)},enabled:o.canI("FolderRename")},{icon:"bin",title:"Delete",exec:function(){t.j.e.fire("folderRemove.filebrowser",e)},enabled:o.canI("FolderRemove")},{icon:"plus",title:"Add folder",exec:function(){t.j.e.fire("folderCreate.filebrowser",e)},enabled:o.canI("FolderCreate")}]},t.prototype.getSourceContextActions=function(e){var t=this;return[{icon:"plus",title:"Create folder",exec:function(){t.j.e.fire("folderCreate.filebrowser",e)}}]},n.__decorate([s.watch(":contextmenuFolder.filebrowser")],t.prototype,"onFolderContext",null),n.__decorate([s.watch(":contextmenuItem.filebrowser")],t.prototype,"onItemContext",null),n.__decorate([s.watch(":contextmenuSource.filebrowser")],t.prototype,"onSourceContext",null),n.__decorate([s.component],t)}(i.ViewComponent);t.ContextMenuManager=c},474:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.parentPath=void 0,t.parentPath=function(e){var t=e.split("/").filter((function(e){return e.length}));return t.pop(),t.join("/")||"/"}},472:(e,t,o)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.HistoryManager=void 0;var n=o(1),r=o(23),i=o(31),s=o(103),a=function(e){function t(t,o){var n=e.call(this,t)||this;return n.state=o,n}return n.__extends(t,e),t.prototype.className=function(){return"HistoryManager"},t.prototype.updateHistory=function(){this.state.history[this.state.historyIndex]={currentSource:this.state.currentSource,currentPath:this.state.currentPath,tree:r.fastClone(this.state.tree),elements:this.state.elements}},t.prototype.updateState=function(){var e=this.state.history[this.state.historyIndex],t=e.tree,o=e.currentSource,n=e.currentPath;this.state.elements=e.elements,this.state.tree=t,this.state.currentSource=o,this.state.currentPath=n,this.j.e.fire("changeSelection")},t.prototype.push=function(){var e=n.__spreadArray([],this.state.history),t=this.state.historyIndex,o=e[t];o&&o.currentSource===this.state.currentSource&&o.currentPath===this.state.currentPath||(e.length-1!==t&&(e=e.slice(0,t)),e.push({tree:[],elements:[],currentPath:this.state.currentPath,currentSource:this.state.currentSource}),o&&(t+=1),this.state.historyIndex=t,this.state.history=e,this.updateHistory(),this.j.e.fire("changeSelection"))},t.prototype.onNext=function(){this.state.history.length-1>this.state.historyIndex&&(this.state.historyIndex+=1,this.updateState())},t.prototype.onPrevious=function(){this.state.historyIndex>0&&(this.state.historyIndex-=1,this.updateState())},t.prototype.onHome=function(){this.state.currentSource="",this.state.currentPath="",this.j.e.fire("update.filebrowser")},n.__decorate([s.watch(":next.filebrowser")],t.prototype,"onNext",null),n.__decorate([s.watch(":previous.filebrowser")],t.prototype,"onPrevious",null),n.__decorate([s.watch(":goHome.filebrowser")],t.prototype,"onHome",null),n.__decorate([s.component],t)}(i.ViewComponent);t.HistoryManager=a},471:(e,t,o)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.PersistentStore=void 0;var n=o(1),r=o(31),i=o(103),s=o(195),a=function(e){function t(t,o){var n=e.call(this,t)||this;return n.state=o,n.sortBy="changed-desc",n.view="tiles",n.foldersPosition="top",n.tileSize="default",n.favorites=[],n.showSideBar=!0,n.showPreview=!1,n.showFavorites=!0,n}return n.__extends(t,e),t.prototype.className=function(){return"PersistentStore"},t.prototype.onChangeThemeSetField=function(){this.theme=this.state.theme},t.prototype.onChangeView=function(){this.view=this.state.view},t.prototype.onChangeSortBy=function(){this.sortBy=this.state.sortBy},t.prototype.onChangeTileSize=function(){this.tileSize=this.state.tileSize},t.prototype.onChangeFavorites=function(){this.favorites=this.state.favorites},t.prototype.onChangeShowSideBar=function(){this.showSideBar=this.state.showSideBar},t.prototype.onChangeShowPreview=function(){this.showPreview=this.state.showPreview},t.prototype.onChangeShowFavorites=function(){this.showFavorites=this.state.showFavorites},t.prototype.onChangeFoldersPosition=function(){this.foldersPosition=this.state.foldersPosition},t.prototype.syncWithState=function(){this.state.tileSize=this.tileSize,this.state.favorites=this.favorites.map((function(e){return e instanceof s.FileBrowserItem?e:s.FileBrowserItem.create(e)})),this.state.view=this.view,this.state.theme=this.theme,this.state.showSideBar=this.showSideBar,this.state.showPreview=this.showPreview,this.state.showFavorites=this.showFavorites,this.state.sortBy=this.sortBy,this.state.foldersPosition=this.foldersPosition},n.__decorate([i.persistent],t.prototype,"theme",void 0),n.__decorate([i.persistent],t.prototype,"sortBy",void 0),n.__decorate([i.persistent],t.prototype,"view",void 0),n.__decorate([i.persistent],t.prototype,"foldersPosition",void 0),n.__decorate([i.persistent],t.prototype,"tileSize",void 0),n.__decorate([i.persistent],t.prototype,"favorites",void 0),n.__decorate([i.persistent],t.prototype,"showSideBar",void 0),n.__decorate([i.persistent],t.prototype,"showPreview",void 0),n.__decorate([i.persistent],t.prototype,"showFavorites",void 0),n.__decorate([i.watch("state.theme")],t.prototype,"onChangeThemeSetField",null),n.__decorate([i.watch("state.view")],t.prototype,"onChangeView",null),n.__decorate([i.watch("state.sortBy")],t.prototype,"onChangeSortBy",null),n.__decorate([i.watch("state.tileSize")],t.prototype,"onChangeTileSize",null),n.__decorate([i.watch("state.favorites")],t.prototype,"onChangeFavorites",null),n.__decorate([i.watch("state.showSideBar")],t.prototype,"onChangeShowSideBar",null),n.__decorate([i.watch("state.showPreview")],t.prototype,"onChangeShowPreview",null),n.__decorate([i.watch("state.showFavorites")],t.prototype,"onChangeShowFavorites",null),n.__decorate([i.watch("state.foldersPosition")],t.prototype,"onChangeFoldersPosition",null),n.__decorate([i.component],t)}(r.ViewComponent);t.PersistentStore=a},466:(e,t,o)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.StateManager=void 0;var n=o(1),r=o(103),i=function(){function e(e){this.state=e}return e.prototype.getIndex=function(e,t){return void 0===t&&(t=this.state.elements),t.findIndex((function(t){return t.uniqueHashKey===e.uniqueHashKey}))},e.prototype.isActive=function(e){return Boolean(this.state.activeElements.find((function(t){return t.uniqueHashKey===e.uniqueHashKey})))},e.prototype.isFavorite=function(e){return Boolean(this.state.favorites.find((function(t){return t.uniqueHashKey===e.uniqueHashKey})))},e.prototype.addActive=function(e,t){var o;this.state.metaInfo=e,this.state.info=null!==(o=e.file)&&void 0!==o?o:"",this.state.lastSelectedIndex=this.getIndex(e),this.state.activeElements=t?n.__spreadArray(n.__spreadArray([],this.state.activeElements),[e]):[e]},e.prototype.callSelectHandler=function(){var e,t=this.state.activeElements;null===(e=this.state.onSelectCallBack)||void 0===e||e.call(this,{baseurl:"",files:t.map((function(e){return e.fileURL})),isImages:t.map((function(e){return Boolean(e.isImage)}))})},e.prototype.setFilter=function(e){this.state.filterWord=e},e.prototype.addMessage=function(e){var t,o=this.state.messages;(null===(t=o[o.length-1])||void 0===t?void 0:t.message)!==e.message&&(this.state.messages=n.__spreadArray(n.__spreadArray([],o),[e]))},e.prototype.removeMessage=function(e){var t=this.state.messages.indexOf(e);if(-1!==t){var o=n.__spreadArray([],this.state.messages);o.splice(t,1),this.state.messages=o}},e.prototype.toggleFavorite=function(e){var t=this.getIndex(e,this.state.favorites),o=n.__spreadArray([],this.state.favorites);-1===t?o.push(e):o.splice(t,1),this.state.favorites=o},e.prototype.fillSources=function(e,t){var o=this,n=function(e){return e.filter((function(e){return"."!==e&&".."!==e}))};if(this.state.tree.length&&t){var r=function(e,t){var o;return null!==(o=e.find((function(e){return e.name===t})))&&void 0!==o?o:null};this.removeActive(this.state.tree),e.forEach((function(e){var i=r(o.state.tree,e.name);if(i){i.isActive=!0;var s=t.split("/").reduce((function(e,t){return e&&r(e.children,t)}),i);s&&(s.isActive=!0,s.children=n(e.folders).map((function(o){return{type:"directory",name:o,path:t+"/"+o,sourceName:e.name,children:[]}})))}}))}else this.state.tree=e.map((function(e){return{type:"source",name:e.name,title:e.title,sourceName:e.name,path:"/",children:n(e.folders).map((function(t){return{type:"directory",name:t,path:t,sourceName:e.name,children:[]}}))}}))},e.prototype.removeActive=function(e){var t=this;e.forEach((function(e){e.isActive=!1,t.removeActive(e.children)}))},Object.defineProperty(e.prototype,"isFavoriteItems",{get:function(){return this.state.favorites===this.state.elements},enumerable:!1,configurable:!0}),n.__decorate([r.autobind],e.prototype,"getIndex",null),n.__decorate([r.autobind],e.prototype,"isActive",null),n.__decorate([r.autobind],e.prototype,"isFavorite",null),e}();t.StateManager=i},478:(e,t,o)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ru=void 0;var n=o(479);t.ru=n},434:(e,t,o)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=o(79),r=o(435),i=o(436);n.Icon.set("heart",String(r)),n.Icon.set("home",String(i))},460:(e,t,o)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.UIBrowserFolder=void 0;var n=o(1);o(461);var r=o(79),i=o(103),s=function(e){function t(t,o){var n=e.call(this,t)||this;return n.item=o,n.syncMod=!0,n.getElm("name").innerText=o.name,t.e.on(n.container,"click",(function(){return n.getMod("active")||n.setMod("loading",!0),t.e.fire("openFolder",o)})).on(n.container,"contextmenu",(function(e){return t.e.fire("contextmenuFolder.filebrowser",o,e)})),n}return n.__extends(t,e),t.prototype.className=function(){return"UIBrowserFolder"},t.prototype.render=function(){return'<div>\n\t\t\t<div class="&__icon">\n\t\t\t\t<div class=\'&__loader\'></div>\n\t\t\t\t<div class="&__icon-wrapper">\n\t\t\t\t\t*folder*\n\t\t\t\t</div>\n\t\t\t</div>\n\t\t\t<div class="&__name"></div>\n\t\t\t<div class="&__arrow">*angle-right*</div>\n\t\t</div>'},n.__decorate([i.component],t)}(r.UIElement);t.UIBrowserFolder=s},467:(e,t,o)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.UIBrowserHeader=void 0;var n=o(1);o(468);var r=o(79),i=o(103),s=o(176),a=function(e){function t(t,o,n){var i,a=e.call(this,t)||this;return a.options=o,a.stateManager=n,a.syncMod=!0,a.toolbar=s.makeCollection(a.j),a.filter=new r.UIInput(a.j,{icon:"search",placeholder:"Filter",clearButton:!0,onChange:function(e){a.stateManager.setFilter(e)}}),a.append(a.toolbar).append(a.filter),a.filter.container.classList.add(a.getFullElName("filter")),a.toolbar.setMod("mode","header").build(null!==(i=a.options.toolbarButtons)&&void 0!==i?i:[]),a}return n.__extends(t,e),t.prototype.className=function(){return"UIBrowserHeader"},n.__decorate([i.component],t)}(r.UIGroup);t.UIBrowserHeader=a},441:(e,t,o)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.UIBrowserItem=void 0;var n=o(1);o(442);var r=o(79),i=o(103),s=o(195),a=o(14),c=o(23),l=function(e){function t(t,o){var n=e.call(this,t)||this;return n.item=s.FileBrowserItem.create(o),t.e.on(n.container,"click contextmenu dblclick",(function(e){return t.e.fire(e.type+"Item.filebrowser",n.item,c.ctrlKey(e)||e.shiftKey,e),!1})),n}return n.__extends(t,e),t.prototype.className=function(){return"UIBrowserItem"},t.prototype.render=function(){return"<div tabindex='-1'>\n\t\t\t<div class='&__image'></div>\n\t\t\t<div class='&__info'></div>\n\t\t\t<div class='&__heart'>*heart*</div>\n\t\t</div>"},t.prototype.onClickFavorite=function(){var e=this;return this.bubble((function(t){e.jodit.e.fire(t,"toggleFavoriteItem",e.item)})),!1},t.prototype.onAction=function(e){return this.jodit.e.fire(e.type+"Item.filebrowser",this.item,c.ctrlKey(e)||e.shiftKey,e),!1},t.prototype.update=function(){var t;c.css(this.getElm("image"),"backgroundImage","url("+this.item.imageURL+")"),this.setMod("is-file",!1===this.item.isImage).setMod("type",null!==(t=this.item.type)&&void 0!==t?t:"file").setElementValue("name",this.item.file).setElementValue("time",this.item.time).setElementValue("filesize",this.item.size),c.attr(this.container,"title",this.item.file+" "+this.item.time+" "+this.item.size),e.prototype.update.call(this)},t.prototype.setElementValue=function(e,t){var o=this.getFullElName(e),n=this.getElm(e);if(!t)return n&&a.Dom.safeRemove(n),this;if(!n){var r=this.getElm("info");n=this.j.create.div(o),r.appendChild(n)}return n.innerText=t,this},n.__decorate([i.watch("heart:click")],t.prototype,"onClickFavorite",null),n.__decorate([i.watch(["container:click","container:contextmenu","container:dblclick"])],t.prototype,"onAction",null),n.__decorate([i.component],t)}(r.UIElement);t.UIBrowserItem=l},475:(e,t,o)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.UILightBox=void 0;var n=o(1);o(476);var r=o(14),i=o(103),s=o(23),a=o(13),c=function(e){function t(t,o,n){var i=e.call(this,t)||this;i.current=o,i.elements=n,i.dialog=new r.Dialog;var s=i.dialog;return s.setMod("theme",t.state.theme).toolbar.setMod("mode","header"),s.open(i),i.elements=i.elements.filter((function(e){return e.isImage})),s.e.on(s,"afterClose",(function(){i.destruct()})),i.addGlobalListeners(),i.onChangeCurrent(),s.toolbar.build([{icon:"check",exec:function(){t.stateManager.addActive(i.current,!1),t.e.fire("select.filebrowser"),s.close()}},"dialog.close"]),i}var o;return n.__extends(t,e),o=t,t.prototype.className=function(){return"UILightBox"},t.prototype.render=function(){return"<div>\n\t\t\t<div class='&__previous'>*angle-left*</div>\n\t\t\t<div class='&__preview'></div>\n\t\t\t<div class='&__loader'></div>\n\t\t\t<div class='&__next'>*angle-right*</div>\n\t\t</div>"},t.prototype.onChangeCurrent=function(){return n.__awaiter(this,void 0,Promise,(function(){var e,t,o,i;return n.__generator(this,(function(n){switch(n.label){case 0:return e=this.current,this.setMod("loading",!0),t=this.getElm("preview"),r.Dom.detach(t),s.css(t,{backgroundImage:null}),e.isImage?[4,s.loadImage(e.fileURL,this.j)]:[3,2];case 1:return o=n.sent(),this.dialog.setPosition(),s.css(t,{width:Math.min(this.jodit.ow.innerWidth,o.naturalWidth),height:Math.min(this.jodit.ow.innerHeight-100,o.naturalHeight),backgroundImage:"url("+o.src+")"}),[3,4];case 2:return[4,this.makeIframe(e.fileURL)];case 3:i=n.sent(),t.appendChild(i),n.label=4;case 4:return this.dialog.setSize(),this.dialog.setPosition(),this.setMod("loading",!1),[2]}}))}))},t.prototype.makeIframe=function(e){var t=this.j.c.element("iframe");return t.classList.add(this.getFullElName("office-iframe")),t.src=/\.pdf/.test(e)?e:this.j.o.previewOfficeURL+encodeURIComponent(e),t},t.prototype.onPreviousClick=function(){var e=this.j.stateManager.getIndex(this.current,this.elements);e>0?e-=1:e=this.elements.length-1,this.current=this.elements[e]},t.prototype.onNextClick=function(){var e=this.j.stateManager.getIndex(this.current,this.elements);this.elements.length-1>e?e+=1:e=0,this.current=this.elements[e]},t.open=function(e,t,n){return new o(e,t,n)},t.prototype.addGlobalListeners=function(){this.j.e.on(this.j.od,"keydown",this.onKeyPress)},t.prototype.onKeyPress=function(e){if(e.key===a.KEY_LEFT||e.key===a.KEY_RIGHT||e.key===a.KEY_SPACE)return e.key===a.KEY_LEFT?this.onPreviousClick():this.onNextClick(),!1},t.prototype.removeGlobalListeners=function(){this.j.e.off(this.j.od,"keydown",this.onKeyPress)},t.prototype.destruct=function(){return this.removeGlobalListeners(),this.dialog.destruct(),e.prototype.destruct.call(this)},n.__decorate([i.watch("current")],t.prototype,"onChangeCurrent",null),n.__decorate([i.watch("previous:click")],t.prototype,"onPreviousClick",null),n.__decorate([i.watch("next:click")],t.prototype,"onNextClick",null),n.__decorate([i.autobind],t.prototype,"onKeyPress",null),o=n.__decorate([i.component],t)}(r.UIElement);t.UILightBox=c},447:(e,t,o)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.UIBrowserMessage=void 0;var n=o(1),r=o(79),i=o(103),s=o(23),a=function(e){function t(t,o){var n=e.call(this,t)||this;return n.container.innerText=s.isString(o)?o:o.message,n}return n.__extends(t,e),t.prototype.className=function(){return"UIBrowserMessage"},n.__decorate([i.component],t)}(r.UIElement);t.UIBrowserMessage=a},445:(e,t,o)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.UIBrowserMessages=void 0;var n=o(1);o(446);var r=o(79),i=o(103),s=o(447),a=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return n.__extends(t,e),t.prototype.className=function(){return"UIBrowserMessages"},t.prototype.build=function(e){var t=this;this.clear(),e.forEach((function(e){var o=new s.UIBrowserMessage(t.jodit,e.message);o.setMod("type",e.type),t.append(o)}))},n.__decorate([i.component],t)}(r.UIGroup);t.UIBrowserMessages=a},437:(e,t,o)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.UIBrowserPanel=void 0;var n=o(1);o(438);var r=o(79),i=o(439),s=o(445),a=o(103),c=o(448),l=o(452),u=o(23),h=o(454),d=o(462),p=o(464),f=function(e){function t(t,o){var n=e.call(this,t)||this;return n.stateManager=o,n.syncMod=!0,n.sources=new h.UIBrowserSources(n.j),n.sidebar=new c.UISidebar(n.jodit,[n.sources],n.stateManager.state),n.preview=new p.UIPreview(n.jodit,n.stateManager.state),n.statusbar=new d.UIBrowserStatusBar(n.j),n.items=new i.UIVirtualScroll(n.j,n.stateManager),n.settings=new l.UIBrowserSettings(n.jodit,n.stateManager.state),n.messages=new s.UIBrowserMessages(n.j),n.state=o.state,n.append(n.sidebar,"content"),n.append(n.items,"content"),n.append(n.messages,"footer"),n.append(n.settings,"content"),n.append(n.preview,"content"),n.append(n.statusbar,"footer"),n.onChangeElements(),n.onChangeSources(),n.onChangeView(),n.onChangeTileSize(),n.onChangeShowFavorites(),n.onChangeMessages(),n.onChangeActiveElements(),n.onChangeFavorites(),n.onChangeShowSideBar(),n.onChangeShowSettings(),n.onChangeShowPreview(),n.onChangeTheme(),n}return n.__extends(t,e),t.prototype.className=function(){return"UIBrowserPanel"},Object.defineProperty(t.prototype,"countInRow",{get:function(){if("list"===this.state.view)return 1;var e=this.items.elements[0].container,t=u.css(e,"marginLeft");return Math.floor(this.items.container.offsetWidth/(e.offsetWidth+(u.isNumber(t)?t:0)))},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"countInColumn",{get:function(){var e=this.items.elements[0].container,t=u.css(e,"marginTop");return Math.floor(this.items.container.offsetHeight/(e.offsetHeight+(u.isNumber(t)?t:0)))},enumerable:!1,configurable:!0}),t.prototype.render=function(){return"<div>\n\t\t\t<div class='&__content'></div>\n\t\t\t<div class='&__footer'></div>\n\t\t</div>"},t.prototype.onChangeTheme=function(){this.setMod("theme",this.stateManager.state.theme)},t.prototype.onChangeElements=function(){this.items.build(this.stateManager.state.elements)},t.prototype.onChangeActiveElements=function(){var e=this;this.state.activeElements.length||(this.state.info="",this.state.metaInfo=null),this.items.elements.forEach((function(t){t.setMod("active",Boolean(e.stateManager.isActive(t.item)))})),this.j.e.fire("changeSelection")},t.prototype.onChangeFavorites=function(){var e=this;this.items.elements.forEach((function(t){t.setMod("favorite",Boolean(e.stateManager.isFavorite(t.item)))}))},t.prototype.onChangeSources=function(){this.sources.build(this.stateManager.state.tree)},t.prototype.onChangeLastSelectedIndex=function(){var e,t=null===(e=this.items.elements[this.stateManager.state.lastSelectedIndex])||void 0===e?void 0:e.container;t&&(u.scrollIntoViewIfNeeded(t,this.items.container,this.j.od),t.focus())},t.prototype.onChangeInfo=function(){this.statusbar.value(this.state.info,"center")},t.prototype.onChangePathOrSource=function(){this.statusbar.value(this.state.currentPath?this.state.currentPath+" ("+this.state.currentSource+")":this.i18n("Home"),"left")},t.prototype.onChangeShowSettings=function(){this.settings.setMod("hidden",!this.stateManager.state.showSettings)},t.prototype.onChangeShowPreview=function(){this.preview.setMod("hidden",!this.stateManager.state.showPreview)},t.prototype.onChangeShowSideBar=function(){this.sidebar.setMod("hidden",!this.stateManager.state.showSideBar)},t.prototype.onChangeView=function(){this.items.setMod("view",this.stateManager.state.view)},t.prototype.onChangeTileSize=function(){this.items.setMod("size",this.stateManager.state.tileSize)},t.prototype.onChangeShowFavorites=function(){this.sidebar.setMod("show-favorites",this.stateManager.state.showFavorites),this.items.setMod("show-favorites",this.stateManager.state.showFavorites)},t.prototype.onChangeMessages=function(){this.messages.build(this.stateManager.state.messages)},t.prototype.onItemDblClick=function(){return this.j.e.fire("select.filebrowser"),!1},t.prototype.onItemClick=function(e,t){this.stateManager.addActive(e,t)},t.prototype.onTogglePreview=function(){return this.state.showPreview=!this.state.showPreview,!1},t.prototype.onToggleFavoriteItem=function(e){this.stateManager.toggleFavorite(e)},t.prototype.onFolderClick=function(e){this.stateManager.state.currentSource=e.sourceName,this.stateManager.state.currentPath=e.path||"/"},n.__decorate([a.watch("state.theme")],t.prototype,"onChangeTheme",null),n.__decorate([a.watch("state.elements")],t.prototype,"onChangeElements",null),n.__decorate([a.watch("state.activeElements")],t.prototype,"onChangeActiveElements",null),n.__decorate([a.watch(["state.favorites","state.elements"])],t.prototype,"onChangeFavorites",null),n.__decorate([a.watch("state.sources")],t.prototype,"onChangeSources",null),n.__decorate([a.watch("state.lastSelectedIndex")],t.prototype,"onChangeLastSelectedIndex",null),n.__decorate([a.watch("state.info")],t.prototype,"onChangeInfo",null),n.__decorate([a.watch(["state.currentPath","state.currentSource"])],t.prototype,"onChangePathOrSource",null),n.__decorate([a.watch("state.showSettings")],t.prototype,"onChangeShowSettings",null),n.__decorate([a.watch("state.showPreview")],t.prototype,"onChangeShowPreview",null),n.__decorate([a.watch("state.showSideBar")],t.prototype,"onChangeShowSideBar",null),n.__decorate([a.watch("state.view")],t.prototype,"onChangeView",null),n.__decorate([a.watch("state.tileSize")],t.prototype,"onChangeTileSize",null),n.__decorate([a.watch("state.showFavorites")],t.prototype,"onChangeShowFavorites",null),n.__decorate([a.watch("state.messages")],t.prototype,"onChangeMessages",null),n.__decorate([a.watch(":dblclickItem.filebrowser")],t.prototype,"onItemDblClick",null),n.__decorate([a.watch(":clickItem.filebrowser")],t.prototype,"onItemClick",null),n.__decorate([a.watch(":togglePreview.filebrowser")],t.prototype,"onTogglePreview",null),n.__decorate([a.watch(":toggleFavoriteItem")],t.prototype,"onToggleFavoriteItem",null),n.__decorate([a.watch(":openFolder")],t.prototype,"onFolderClick",null),n.__decorate([a.component],t)}(r.UIGroup);t.UIBrowserPanel=f},464:(e,t,o)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.UIPreview=void 0;var n=o(1);o(465);var r=o(79),i=o(103),s=o(450),a=o(23),c=o(36),l=o(441),u=function(e){function t(t,o){var n=e.call(this,t)||this;return n.state=o,n.lastLoadPromise=null,n.onChangeMetaInfo(),n}return n.__extends(t,e),t.prototype.className=function(){return"UIPreview"},t.prototype.addResize=function(){s.UIResize.remove(this),s.UIResize.install(this,screen.width>450?"left":"top")},t.prototype.render=function(){return'<div>\n\t\t\t\t<div class="&__image"></div>\n\t\t\t\t<div class="&__info"></div>\n\t\t\t\t<div class="&__loader"></div>\n\t\t\t\t<div class="&__empty-message">~Select image~</div>\n\t\t\t</div>'},t.prototype.setMod=function(t,o){return e.prototype.setMod.call(this,t,o),"hidden"===t&&!1===o&&this.onChangeMetaInfo(),this},t.prototype.onChangeMetaInfo=function(){var e,t,o=this;if(!this.getMod("hidden")){var n=this.state.metaInfo;this.setMod("empty",!n),c.Dom.detach(this.getElm("info")),a.css(this.getElm("image"),{backgroundImage:null}),n&&(this.setMod("is-file",!1===n.isImage).setMod("type",null!==(e=n.type)&&void 0!==e?e:"file"),l.UIBrowserItem.prototype.setElementValue.call(this,"name",n.file),l.UIBrowserItem.prototype.setElementValue.call(this,"time",n.time),l.UIBrowserItem.prototype.setElementValue.call(this,"filesize",n.size),this.setMod("loading",!0),null===(t=this.lastLoadPromise)||void 0===t||t.rejectCallback(),this.lastLoadPromise=a.loadImage(n.isImage?n.fileURL:n.imageURL,this.j),this.lastLoadPromise.then((function(e){e&&a.css(o.getElm("image"),{backgroundImage:"url("+e.src+")"})})).finally((function(){o.setMod("loading",!1)})).catch((function(){})))}},n.__decorate([i.hook("ready"),i.watch(":resize",window),i.debounce()],t.prototype,"addResize",null),n.__decorate([i.watch("state.metaInfo")],t.prototype,"onChangeMetaInfo",null),n.__decorate([i.component],t)}(r.UIGroup);t.UIPreview=u},469:(e,t,o)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.UIProgress=void 0;var n=o(1);o(470);var r=o(79),i=o(103),s=function(e){function t(t,o){var n=e.call(this,t)||this;return n.state=o,n.onProgress(),n}return n.__extends(t,e),t.prototype.className=function(){return"UIProgress"},t.prototype.onProgress=function(){this.state.progress?this.show():this.hide(),this.progress(this.state.progress)},t.prototype.hide=function(){return this.setMod("hidden",!0),this},t.prototype.progress=function(e){var t=this;return this.container.style.width=e.toFixed(2)+"%",98>e||this.j.async.setTimeout((function(){t.hide()}),{label:"progress",timeout:300}),this},t.prototype.show=function(){return this.setMod("hidden",!1),this},n.__decorate([i.watch("state.progress")],t.prototype,"onProgress",null),n.__decorate([i.component],t)}(r.ProgressBar);t.UIProgress=s},452:(e,t,o)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.UIBrowserSettings=void 0;var n=o(1);o(453);var r=o(79),i=o(103),s=function(e){function t(t,o){var n=e.call(this,t)||this;return n.state=o,t.e.on(n.getElm("close"),"click",(function(){n.state.showSettings=!1})),n}return n.__extends(t,e),t.prototype.className=function(){return"UIBrowserSettings"},t.prototype.render=function(){return'<div>\n\t\t\t<div class="'+this.getFullElName("close")+'">'+r.Icon.get("cancel")+'</div>\n\t\t\t<div class="'+this.getFullElName("title")+'">'+this.j.i18n("Settings")+'</div>\n\t\t\t<div class="'+this.getFullElName("options")+'"></div>\n\t\t</div>'},t.prototype.appendChildToContainer=function(e){this.getElm("options").appendChild(e)},t.prototype.setMod=function(t,o){return"hidden"===t&&!1===o&&this.generateSettings(),e.prototype.setMod.call(this,t,o)},t.prototype.onChangeView=function(){var e=this.getElm("tile-size");e&&(e.style.display="tiles"===this.state.view?"block":"none")},t.prototype.generateSettings=function(){var e=this;this.clear();var t=this.j;this.append([new r.UIButtonGroup(t,{label:"Theme",name:"theme",value:this.state.theme,radio:!0,options:[{value:"default",text:"Light"},{value:"dark",text:"Dark"}],onChange:function(t){e.state.theme=t[0].value}}),new r.UIButtonGroup(t,{label:"Show favorites",name:"showFavorites",value:this.state.showFavorites,radio:!0,options:[{value:!0,text:"Show"},{value:!1,text:"Hide"}],onChange:function(t){e.state.showFavorites=t[0].value}}),new r.UIButtonGroup(t,{label:"View",name:"view",value:this.state.view,radio:!0,options:[{value:"tiles",text:"Tiles"},{value:"list",text:"List"},{value:"compact",text:"Compact"}],onChange:function(t){e.state.view=t[0].value}}),new r.UIButtonGroup(t,{label:"Folders position",name:"foldersPosition",value:this.state.foldersPosition,radio:!0,options:[{value:"top",text:"Top"},{value:"bottom",text:"Bottom"},{value:"default",text:"Default"}],onChange:function(t){e.state.foldersPosition=t[0].value}}),new r.UISelect(t,{label:"Sort by",name:"sort-by",value:this.state.sortBy,options:[{value:"changed-asc",text:t.i18n("Sort by changed")+"(⬆)"},{value:"changed-desc",text:t.i18n("Sort by changed")+"(⬇)"},{value:"name-asc",text:t.i18n("Sort by name")+"(⬆)"},{value:"name-desc",text:t.i18n("Sort by name")+"(⬇)"},{value:"size-asc",text:t.i18n("Sort by size")+"(⬆)"},{value:"size-desc",text:t.i18n("Sort by size")+"(⬇)"}],onChange:function(t){e.state.sortBy=t}}),new r.UISelect(t,{label:"Tile size",name:"tile-size",value:this.state.tileSize,options:[{value:"xsmall",text:"Extra small"},{value:"small",text:"Small"},{value:"default",text:"Default"},{value:"large",text:"Large"},{value:"xlarge",text:"Extra large"}],onChange:function(t){e.state.tileSize=t}})]),this.onChangeView()},n.__decorate([i.watch("state.view")],t.prototype,"onChangeView",null),n.__decorate([i.component],t)}(r.UIGroup);t.UIBrowserSettings=s},448:(e,t,o)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.UISidebar=void 0;var n=o(1);o(449);var r=o(79),i=o(103),s=o(450),a=function(e){function t(t,o,n){var r=e.call(this,t,o)||this;return r.state=n,r.onChangeFavorites(),r}return n.__extends(t,e),t.prototype.className=function(){return"UISidebar"},t.prototype.render=function(){return"<div>\n\t\t\t<div class='&__hide-btn'>*angle-left*</div>\n\t\t\t<div class='&__favorites'>*heart* ~Favorites~</div>\n\t\t\t<div class='&__box'></div>\n\t\t</div>"},t.prototype.appendChildToContainer=function(e){this.getElm("box").appendChild(e)},t.prototype.addResize=function(){s.UIResize.remove(this),s.UIResize.install(this,screen.width>450?"right":"bottom")},t.prototype.onChangeFavorites=function(){this.setMod("has-favorites",Boolean(this.state.favorites.length))},t.prototype.onClickHideButton=function(){return this.state.showSideBar=!this.state.showSideBar,!1},t.prototype.onClickFavorites=function(){return this.state.elements=this.state.favorites,!1},n.__decorate([i.hook("ready"),i.watch(":resize",window),i.debounce()],t.prototype,"addResize",null),n.__decorate([i.watch("state.favorites")],t.prototype,"onChangeFavorites",null),n.__decorate([i.watch("hide-btn:click")],t.prototype,"onClickHideButton",null),n.__decorate([i.watch("favorites:click")],t.prototype,"onClickFavorites",null),n.__decorate([i.component],t)}(r.UIGroup);t.UISidebar=a},456:(e,t,o)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.UIBrowserSource=void 0;var n=o(1);o(457);var r=o(79),i=o(103),s=o(458),a=function(e){function t(t,o){var n=e.call(this,t,o)||this;return n.data=o,n.tree=new s.UITree(n.j,n.data.children),n.syncMod=!0,n.getElm("name").innerText=o.title||o.name,n.getElm("tree").appendChild(n.tree.container),t.e.on(n.container,"contextmenu",(function(e){return t.e.fire("contextmenuSource.filebrowser",o,e)})),n}return n.__extends(t,e),t.prototype.className=function(){return"UIBrowserSource"},t.prototype.render=function(){return'<div>\n\t\t\t<div class="&__name"></div>\n\t\t\t<div class="&__tree"></div>\n\t\t</div>'},n.__decorate([i.component],t)}(r.UIElement);t.UIBrowserSource=a},454:(e,t,o)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.UIBrowserSources=void 0;var n=o(1);o(455);var r=o(79),i=o(103),s=o(456),a=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.syncMod=!0,t}return n.__extends(t,e),t.prototype.className=function(){return"UIBrowserSources"},t.prototype.build=function(e){var t=this;this.clear(),e.forEach((function(e){t.append(new s.UIBrowserSource(t.jodit,e))}))},n.__decorate([i.component],t)}(r.UIGroup);t.UIBrowserSources=a},462:(e,t,o)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.UIBrowserStatusBar=void 0;var n=o(1);o(463);var r=o(79),i=o(103),s=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return n.__extends(t,e),t.prototype.className=function(){return"UIBrowserStatusBar"},t.prototype.render=function(){return"<div>\n\t\t\t<div class='&__slot-left'></div>\n\t\t\t<div class='&__slot-center'></div>\n\t\t\t<div class='&__slot-right'></div>\n\t\t</div>"},t.prototype.value=function(e,t){return void 0===t&&(t="left"),this.getElm("slot-"+t).innerText=e,this},n.__decorate([i.component],t)}(r.UIElement);t.UIBrowserStatusBar=s},458:(e,t,o)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.UITree=void 0;var n=o(1);o(459);var r=o(79),i=o(103),s=o(460),a=function(e){function t(t,o){var n=e.call(this,t)||this;return n.syncMod=!0,n.build(o),n}var o;return n.__extends(t,e),o=t,t.prototype.className=function(){return"UITree"},t.prototype.build=function(e){var t=this;this.clear(),e.forEach((function(e){var n=new s.UIBrowserFolder(t.jodit,e);t.append(n),e.isActive&&n.setMod("active",!0),e.children.length&&t.append(new o(t.jodit,e.children))}))},o=n.__decorate([i.component],t)}(r.UIGroup);t.UITree=a},439:(e,t,o)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.UIVirtualScroll=void 0;var n=o(1);o(440);var r=o(79),i=o(103),s=o(441),a=o(195),c=o(443),l=o(23),u=function(e){function t(t,o){var n=e.call(this,t)||this;return n.stateManager=o,n.syncMod=!0,n.addItemsSelector(),n}var o;return n.__extends(t,e),o=t,t.prototype.className=function(){return"UIVirtualScroll"},t.prototype.render=function(){return"<div>\n\t\t\t\t<div class=\"&__empty-message\">~There are no files~</div>\n\t\t\t\t<div class='&__loader'></div>\n\t\t\t\t<div class='&__drag-area'>~Drop image~</div>\n\t\t\t</div>"},t.prototype.build=function(e){var t=this,o=this.elements.findIndex((function(t,o){return!e[o]||t.item.uniqueHashKey!==a.FileBrowserItem.create(e[o]).uniqueHashKey}));if(o>-1){for(var n=o;this.elements.length>n;n+=1)this.elements[n].destruct();this.elements.length=o}e.slice(o>-1?o:this.elements.length).forEach((function(e){var o=new s.UIBrowserItem(t.jodit,e);Object.keys(t.mods).forEach((function(e){o.setMod(e,t.mods[e])})),t.append(o)})),this.setMod("empty",!this.elements.length)},t.prototype.onScrollLoadChunk=function(){!this.stateManager.isFavoriteItems&&this.j.o.pixelOffsetLoadNewChunk>this.container.scrollHeight-(this.container.scrollTop+this.container.offsetHeight)&&this.j.loadItemsChunk()},t.prototype.onDragOver=function(e){e.preventDefault(),this.setMod("dragover",!0)},t.prototype.onDragLeave=function(e){e.preventDefault(),this.setMod("dragover",!1)},t.prototype.addItemsSelector=function(){c.UISelectItems.install(this)},t.intersectRect=function(e,t){return!(t.left>e.left+e.width||e.left>t.left+t.width||t.top>e.top+e.height||e.top>t.top+t.height)},t.prototype.onSelectItems=function(e){var t=[];this.elements.forEach((function(n){var r=l.position(n.container);o.intersectRect(r,e)&&t.push(n.item)})),this.stateManager.state.activeElements=t},n.__decorate([i.watch(":afterResize"),i.watch(":resize"),i.watch("container:scroll"),i.throttle()],t.prototype,"onScrollLoadChunk",null),n.__decorate([i.watch("container:dragover")],t.prototype,"onDragOver",null),n.__decorate([i.watch(["container:dragleave","container:drop"])],t.prototype,"onDragLeave",null),o=n.__decorate([i.component],t)}(r.UIGroup);t.UIVirtualScroll=u},450:(e,t,o)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.UIResize=void 0,o(451);var n=o(23),r=o(36),i=function(){function e(){}return e.remove=function(e){n.css(e.container,{width:null,height:null}),e.container.classList.remove("jodit-ui-resize"),r.Dom.safeRemove(e.container.querySelector(".jodit-ui-resize__handle"))},e.install=function(e,t){e.container.classList.add("jodit-ui-resize"),"static"===n.css(e.container,"position")&&n.css(e.container,"position","relative");var o=e.j.c.div("jodit-ui-resize__handle");o.classList.add("jodit-ui-resize__handle_type_"+t),e.container.appendChild(o),e.j.e.on(o,"mousedown touchstart",this.onStartResize.bind(this,e,t))},e.onStartResize=function(e,t,o){var n=e.j.async.throttle(this.onResize.bind(this,e,{x:o.clientX,y:o.clientY,w:e.container.offsetWidth,h:e.container.offsetHeight,direction:t}),e.j.defaultTimeout/10);e.j.lock(),e.j.e.on(e.j.ow,"mousemove touchmove",n).one(e.j.ow,"mouseup touchend",this.onEndResize.bind(this,e,n))},e.onResize=function(e,t,o){var r=["left","right"].includes(t.direction),i=e.container.parentElement;i&&n.css(e.container,r?"width":"height",100*(r?(t.w+(o.clientX-t.x)*("right"===t.direction?1:-1))/i.offsetWidth:(t.h+(o.clientY-t.y)*("top"===t.direction?1:-1))/i.offsetHeight)+"%")},e.onEndResize=function(e,t,o){e.j.e.off(e.j.ow,"mousemove touchmove",t),e.j.unlock()},e}();t.UIResize=i},443:(e,t,o)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.UISelectItems=void 0,o(444);var n=o(36),r=o(23),i=function(){function e(){}return e.remove=function(e){n.Dom.safeRemove(e.container.querySelector(".jodit-ui-select-items")),e.j.e.off(e.container,"mousedown.uiselectitems touchstart.uiselectitems")},e.install=function(e){var t=e.j.c.div("jodit-ui-select-items");e.j.e.on(e.container,"mousedown.uiselectitems touchstart.uiselectitems",this.onStartSelect.bind(this,e,t))},e.onStartSelect=function(e,t,o){if(o.target===e.container){r.css(t,{width:0,height:0}),e.container.appendChild(t);var n={x:o.clientX,y:o.clientY,w:e.container.offsetWidth,h:e.container.offsetHeight},i=e.j.async.throttle(this.onSelect.bind(this,e,t,n),e.j.defaultTimeout/10);e.j.lock(),e.j.e.on(e.j.ow,"mousemove touchmove",i).one(e.j.ow,"mouseup touchend",this.onEndSelect.bind(this,e,t,i)),e.onSelectItems({left:n.x,top:n.y,width:0,height:0})}},e.onSelect=function(e,t,o,n){var i={left:o.x>n.clientX?n.clientX:o.x,top:o.y>n.clientY?n.clientY:o.y,width:Math.abs(o.x-n.clientX),height:Math.abs(o.y-n.clientY)};r.css(t,i),e.onSelectItems(i)},e.onEndSelect=function(e,t,o,r){n.Dom.safeRemove(t),e.j.e.off(e.j.ow,"mousemove touchmove",o),e.j.unlock()},e}();t.UISelectItems=i},479:e=>{e.exports={Favorites:"Избранное",Settings:"Настройки",Light:"Светлая",Dark:"Темная",Theme:"Тема",Show:"Показать",Hide:"Скрыть","Show favorites":"Показывать избранное",Tiles:"Плитка",List:"Список",Compact:"Компактный",View:"Отображение","Folders position":"Позиция папок","Sort by":"Сортировать по","Extra small":"Очень маленькие",Small:"Маленькие",Large:"Большие","Extra large":"Очень большие","Tile size":"Размер плитки"}}},e=>{"use strict";e(e.s=431)}])}));
!function(e,t){if("object"==typeof exports&&"object"==typeof module)module.exports=t();else if("function"==typeof define&&define.amd)define([],t);else{var o=t();for(var n in o)("object"==typeof exports?exports:e)[n]=o[n]}}(self,(function(){return(self.webpackChunkjodit_pro=self.webpackChunkjodit_pro||[]).push([[524],{435:e=>{e.exports='<svg viewBox="0 0 512 512" xmlns="http://www.w3.org/2000/svg"> <path d="M365.4,59.628c60.56,0,109.6,49.03,109.6,109.47c0,109.47-109.6,171.8-219.06,281.271 C146.47,340.898,37,278.568,37,169.099c0-60.44,49.04-109.47,109.47-109.47c54.73,0,82.1,27.37,109.47,82.1 C283.3,86.999,310.67,59.628,365.4,59.628z"/> </svg>'},436:e=>{e.exports='<svg viewBox="0 0 32 32" xmlns="http://www.w3.org/2000/svg"> <path d="M28.7,16.3l-12-13c-0.4-0.4-1.1-0.4-1.5,0l-12,13C3,16.6,2.9,17,3.1,17.4C3.2,17.8,3.6,18,4,18h3v10c0,0.6,0.4,1,1,1h16 c0.6,0,1-0.4,1-1V18h3c0.4,0,0.8-0.2,0.9-0.6C29.1,17,29,16.6,28.7,16.3z"/> </svg>'},433:(e,t,o)=>{"use strict";o.r(t)},461:(e,t,o)=>{"use strict";o.r(t)},468:(e,t,o)=>{"use strict";o.r(t)},442:(e,t,o)=>{"use strict";o.r(t)},476:(e,t,o)=>{"use strict";o.r(t)},446:(e,t,o)=>{"use strict";o.r(t)},438:(e,t,o)=>{"use strict";o.r(t)},465:(e,t,o)=>{"use strict";o.r(t)},470:(e,t,o)=>{"use strict";o.r(t)},453:(e,t,o)=>{"use strict";o.r(t)},449:(e,t,o)=>{"use strict";o.r(t)},457:(e,t,o)=>{"use strict";o.r(t)},455:(e,t,o)=>{"use strict";o.r(t)},463:(e,t,o)=>{"use strict";o.r(t)},459:(e,t,o)=>{"use strict";o.r(t)},440:(e,t,o)=>{"use strict";o.r(t)},451:(e,t,o)=>{"use strict";o.r(t)},444:(e,t,o)=>{"use strict";o.r(t)},432:(e,t,o)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.FileBrowserPro=void 0;var n=o(1);o(433),o(434);var r=o(14),i=o(166),s=o(437),a=o(23),c=o(103),l=o(13),u=o(466),h=o(467),d=o(199),p=o(12),f=o(469),v=o(193),m=o(471),g=o(472),y=o(473),w=o(474),_=o(2),I=o(430),b=o(475),S=function(e){function t(t){var o=e.call(this,a.ConfigProto(Object.assign(t||{},{resizable:!0,draggable:!0,toolbarButtons:(null==t?void 0:t.buttons)||p.Config.defaultOptions.filebrowser.buttons,buttons:_.Jodit.atom(["filebrowser.settings","fullsize","dialog.close"])}),p.Config.defaultOptions.filebrowser))||this;return o.dataProvider=v.makeDataProvider(o,o.options),o.state=r.ObserveObject.create({onSelectCallBack:null,theme:"default",showSideBar:!0,showFavorites:!0,showSettings:!1,showPreview:!1,withFolders:!0,foldersPosition:"bottom",info:"",metaInfo:null,currentPath:"",currentSource:"",currentBaseUrl:"",history:[],historyIndex:0,tree:[],activeElements:[],favorites:[],progress:0,lastSelectedIndex:0,elements:[],messages:[],sources:[],view:"tiles",tileSize:"default",sortBy:"name-asc",filterWord:"",onlyImages:!1},["state"]),o.persistent=new m.PersistentStore(o,o.state),o.stateManager=new u.StateManager(o.state),o.historyManager=new g.HistoryManager(o,o.state),o.contextMenuManager=new y.ContextMenuManager(o),o.header=new h.UIBrowserHeader(o,o.options,o.stateManager),o.panel=new s.UIBrowserPanel(o,o.stateManager),o.progressbar=new f.UIProgress(o,o.stateManager.state),o.offset=0,o.countInOneChunk=20,o.stopLoadingParts=!1,I.license.make(o),!o.persistent.theme&&o.options.theme&&(o.persistent.theme=o.options.theme),o.panel.append(o.progressbar),o.toolbar.setMod("mode","header"),o.setSize(Math.min(o.options.width,screen.width),Math.min(o.options.height,screen.height)).setHeader(o.header),o.onResizeWindow(),o.initUploader(),o.onChangeTheme(),o.fullFillOptions(),o.dataProvider.onProgress((function(e){0===e&&(e=30),o.state.progress=e})),o.e.on("beforeClose",o.removeGlobalListeners),o.e.fire("afterInit"),_.Jodit.prototype.afterInitHook.call(o),o}return n.__extends(t,e),t.prototype.className=function(){return"FileBrowserPro"},t.prototype.lock=function(t){return void 0===t&&(t="any"),this.container.classList.add("jodit_disabled"),e.prototype.lock.call(this,t)},t.prototype.unlock=function(){return this.container.classList.remove("jodit_disabled"),e.prototype.unlock.call(this)},t.prototype.status=function(e,t){var o=this;void 0===t&&(t=!(e instanceof Error)),Error;var n={message:a.isString(e)?e:e.message,type:t?"success":"error"};this.stateManager.addMessage(n),this.async.setTimeout((function(){o.stateManager.removeMessage(n)}),this.options.howLongShowMsg)},t.prototype.addDisclaimer=function(e){this.dialog.appendChild(e)},t.prototype.onResizeWindow=function(){a.css(this.dialog,{maxWidth:screen.width,minHeight:Math.min(this.options.height,screen.height),minWidth:Math.min(this.options.width,screen.width)})},t.prototype.open=function(t,o){return void 0===t&&(t=this.o.defaultCallback),n.__awaiter(this,void 0,Promise,(function(){return n.__generator(this,(function(n){return this.state.onlyImages=Boolean(o),this.prepareOpening(t),e.prototype.open.call(this,this.panel.container),[2,this.onUpdateFileBrowser()]}))}))},t.prototype.onChangeTheme=function(){this.setMod("theme",this.state.theme),this.header.setMod("theme",this.state.theme),this.panel.setMod("theme",this.state.theme),this.options.theme=this.state.theme},t.prototype.onToggleSettings=function(){this.state.showSettings=!this.state.showSettings},t.prototype.onUpdateFileBrowser=function(){return n.__awaiter(this,void 0,Promise,(function(){return n.__generator(this,(function(e){switch(e.label){case 0:return this.state.activeElements=[],this.panel.setMod("loading",!0),[4,Promise.all([this.loadFolders(),this.loadItems()])];case 1:return e.sent(),this.panel.setMod("loading",!1),this.historyManager.updateHistory(),[2]}}))}))},t.prototype.loadFolders=function(){return n.__awaiter(this,void 0,Promise,(function(){var e,t,o,r,i;return n.__generator(this,(function(n){switch(n.label){case 0:if(!this.isOpened)return[2];t=(e=this.state).currentPath,o=e.currentSource,this.historyManager.push(),n.label=1;case 1:return n.trys.push([1,3,,4]),this.uploader.setPath(t),this.uploader.setSource(o),[4,this.dataProvider.tree(t,o)];case 2:return r=n.sent(),this.stateManager.fillSources(r,t),this.historyManager.updateHistory(),this.state.sources=r,[3,4];case 3:return i=n.sent(),this.status(i),[3,4];case 4:return[2]}}))}))},t.prototype.loadItems=function(){return n.__awaiter(this,void 0,Promise,(function(){var e,t;return n.__generator(this,(function(o){switch(o.label){case 0:if(!this.isOpened)return[2];o.label=1;case 1:return o.trys.push([1,6,,7]),this.offset=0,this.stopLoadingParts=!1,e=this.state,[4,this.loadPartItems()];case 2:e.elements=o.sent(),this.stopLoadingParts=this.countInOneChunk>this.state.elements.length,o.label=3;case 3:return this.stopLoadingParts||this.state.elements.length>this.panel.countInColumn*this.panel.countInRow?[3,5]:[4,this.loadItemsChunk()];case 4:return o.sent(),[3,3];case 5:return this.historyManager.updateHistory(),[3,7];case 6:return t=o.sent(),this.status(t),[3,7];case 7:return[2]}}))}))},t.prototype.loadItemsChunk=function(){return n.__awaiter(this,void 0,Promise,(function(){var e,t;return n.__generator(this,(function(o){switch(o.label){case 0:if(this.stopLoadingParts)return[2];o.label=1;case 1:return o.trys.push([1,3,,4]),this.offset+=this.countInOneChunk,[4,this.loadPartItems()];case 2:return e=o.sent(),this.stopLoadingParts=this.countInOneChunk>e.length,e.length&&(this.state.elements=this.state.elements.concat(e)),[3,4];case 3:return t=o.sent(),this.status(t),[3,4];case 4:return[2]}}))}))},t.prototype.prepareOpening=function(e){var t=this;this.registerGlobalListeners(),e&&(this.state.onSelectCallBack=function(o){t.close(),e(o)}),this.persistent.syncWithState()},t.prototype.registerGlobalListeners=function(){this.e.on(this.ow,"keydown",this.onKeyPress)},t.prototype.onKeyPress=function(e){var t=this.od.activeElement;if(this.state.activeElements.length&&t&&r.Dom.isOrContains(this.panel.items.container,t)){var o=this.state.elements;switch(e.key){case l.KEY_ENTER:return this.onChooseItems();case l.KEY_DELETE:return this.onFileRemove();case l.KEY_RIGHT:case l.KEY_LEFT:case l.KEY_DOWN:case l.KEY_UP:var n=e.key===l.KEY_RIGHT||e.key===l.KEY_DOWN,i=this.state.lastSelectedIndex,s=void 0;if([l.KEY_RIGHT,l.KEY_LEFT].includes(e.key))s=n?o[i+1]?i+1:0:o[i-1]?i-1:o.length-1;else{var a=this.panel.countInRow;s=Math.round(((i+1)/a+(n?1:-1))*a-1)}return o[s]&&this.stateManager.addActive(o[s],e.shiftKey),!1}}},t.prototype.removeGlobalListeners=function(){this.e.off(this.ow,"keydown",this.onKeyPress)},t.prototype.onFileRemove=function(){var e=this;this.state.activeElements.length&&r.Confirm(this.i18n("Are you sure?"),"",(function(t){if(t){var o=[];e.state.activeElements.forEach((function(t){e.stateManager.isFavorite(t)&&e.stateManager.toggleFavorite(t),o.push(e.deleteFile(t.file||t.name||"",t.sourceName))})),e.state.activeElements=[],Promise.all(o).then((function(){return e.loadItems()}))}})).bindDestruct(this)},t.prototype.onFileEdit=function(){if(1===this.state.activeElements.length){var e=this.state.activeElements[0];d.openImageEditor.call(this,e.fileURL,e.file||"",e.path,e.sourceName,void 0,this.status)}},t.prototype.onFolderRename=function(e){var t=this;r.Prompt(this.i18n("Enter new name"),this.i18n("Rename"),(function(o){if(!a.isValidName(o)||o===e.name)return t.status(t.i18n("Enter new name")),!1;t.dataProvider.folderRename(w.parentPath(e.path),e.name,o,e.sourceName).then((function(n){t.state.activeElements=[],t.status(n,!0),t.state.currentPath=w.parentPath(e.path)+"/"+o,t.state.currentSource=e.sourceName,t.loadFolders()})).catch(t.status)}),this.i18n("type name"),e.name).bindDestruct(this)},t.prototype.onFolderRemove=function(e){var t=this;r.Confirm(this.i18n("Are you sure?"),this.i18n("Delete"),(function(o){o&&t.dataProvider.folderRemove(w.parentPath(e.path),e.name,e.sourceName).then((function(o){t.status(o,!0),t.state.currentPath=w.parentPath(e.path),t.state.currentSource=e.sourceName,t.loadFolders()})).catch(t.status)})).bindDestruct(this)},t.prototype.onFolderCreate=function(e){var t=this;r.Prompt(this.i18n("Enter Directory name"),this.i18n("Create directory"),(function(o){var n=e.path||"/";t.dataProvider.createFolder(o,e.path||"/",e.sourceName).then((function(){t.state.currentSource===e.sourceName&&t.state.currentPath===n?t.onUpdateFileBrowser():(t.state.currentSource=e.sourceName,t.state.currentPath=n)}),t.status)}),this.i18n("type name")).bindDestruct(this)},t.prototype.onFileRename=function(e){var t=this,o=e.file||e.name||"";1===this.state.activeElements.length&&o&&r.Prompt(this.i18n("Enter new name"),this.i18n("Rename"),(function(e){if(!a.isValidName(e))return t.status(t.i18n("Enter new name")),!1;t.dataProvider.fileRename(t.state.currentPath,o,e,t.state.currentSource).then((function(e){t.state.activeElements=[],t.status(e,!0),t.loadItems()})).catch(t.status)}),this.i18n("type name"),o).bindDestruct(this)},t.prototype.onChooseItems=function(){var e=this.stateManager.state.activeElements;if(e.length){if("folder"===e[0].type)return this.state.currentPath=this.state.currentPath+"/"+e[0].name,void(this.state.currentSource=e[0].sourceName);this.state.onSelectCallBack?this.stateManager.callSelectHandler():this.onOpenLightBox(e[0])}},t.prototype.onOpenLightBox=function(e){b.UILightBox.open(this,e,this.state.elements)},t.prototype.deleteFile=function(e,t){var o=this;return this.dataProvider.fileRemove(this.state.currentPath,e,t).then((function(t){o.status(t||o.i18n('File "%s" was deleted',e),!0)})).catch(this.status)},t.prototype.initUploader=function(){var e=this,t=this,o=a.ConfigProto(t.o.uploader||{},p.Config.defaultOptions.uploader),n=function(){return e.loadItems()};t.uploader=t.getInstance("Uploader",o),t.uploader.bind(t.panel.container,n,t.status),t.e.on("bindUploader.filebrowser",(function(e){t.uploader.bind(e,n,t.status)}))},t.prototype.destruct=function(){this.removeGlobalListeners(),this.header.destruct(),this.panel.destruct(),e.prototype.destruct.call(this)},t.prototype.fullFillOptions=function(){var e=this;["getLocalFileByUrl","crop","resize","create","fileMove","folderMove","fileRename","folderRename","fileRemove","folderRemove","folder","items","permissions"].forEach((function(t){null!=e.options[t]&&(e.options[t]=a.ConfigProto(e.options[t],e.o.ajax))}))},t.prototype.loadPartItems=function(){return this.dataProvider.items(this.state.currentPath,this.state.currentSource,{offset:this.offset,limit:this.countInOneChunk,sortBy:this.state.sortBy,withFolders:this.state.withFolders,foldersPosition:this.state.foldersPosition,onlyImages:this.state.onlyImages,filterWord:this.state.filterWord})},n.__decorate([c.autobind],t.prototype,"status",null),n.__decorate([c.watch(":resize",window)],t.prototype,"onResizeWindow",null),n.__decorate([c.watch("state.theme")],t.prototype,"onChangeTheme",null),n.__decorate([c.watch(":toggleSettings.filebrowser")],t.prototype,"onToggleSettings",null),n.__decorate([c.watch(":update.filebrowser")],t.prototype,"onUpdateFileBrowser",null),n.__decorate([c.watch(["state.currentPath","state.currentSource"]),c.debounce((function(e){return{timeout:e.defaultTimeout,promisify:!0}}))],t.prototype,"loadFolders",null),n.__decorate([c.watch(["state.currentPath","state.currentSource","state.sortBy","state.onlyImages","state.foldersPosition","state.filterWord"]),c.debounce((function(e){return{timeout:e.defaultTimeout,promisify:!0}}))],t.prototype,"loadItems",null),n.__decorate([c.debounce((function(e){return{timeout:e.defaultTimeout,promisify:!0}}))],t.prototype,"loadItemsChunk",null),n.__decorate([c.autobind],t.prototype,"onKeyPress",null),n.__decorate([c.autobind],t.prototype,"removeGlobalListeners",null),n.__decorate([c.watch(":fileRemove.filebrowser")],t.prototype,"onFileRemove",null),n.__decorate([c.watch(":edit.filebrowser")],t.prototype,"onFileEdit",null),n.__decorate([c.watch(":folderRename.filebrowser")],t.prototype,"onFolderRename",null),n.__decorate([c.watch(":folderRemove.filebrowser")],t.prototype,"onFolderRemove",null),n.__decorate([c.watch(":folderCreate.filebrowser")],t.prototype,"onFolderCreate",null),n.__decorate([c.watch(":fileRename.filebrowser")],t.prototype,"onFileRename",null),n.__decorate([c.watch(":select.filebrowser")],t.prototype,"onChooseItems",null),n.__decorate([c.watch(":openLightBox.filebrowser")],t.prototype,"onOpenLightBox",null),n.__decorate([c.component],t)}(i.Dialog);t.FileBrowserPro=S,_.Jodit.modules.FileBrowserPro=S},477:(e,t,o)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=o(12);o(34).extendLang(o(478));var r=n.Config.prototype.controls.filebrowser;r.settings={icon:"settings",exec:function(e){e.e.fire("toggleSettings.filebrowser")}},r.home={icon:"home",exec:function(e){e.e.fire("goHome.filebrowser")}},r.preview={icon:"eye",exec:function(e){e.e.fire("togglePreview.filebrowser")}},r.next={icon:"angle-right",isDisabled:function(e){if(!e.state)return!0;var t=e.state,o=t.history;return!o||!o.length||t.historyIndex===o.length-1},exec:function(e){e.e.fire("next.filebrowser")}},r.previous={icon:"angle-left",isDisabled:function(e){if(!e.state)return!0;var t=e.state,o=t.history;return!o||!o.length||0===t.historyIndex},exec:function(e){e.e.fire("previous.filebrowser")}},Object.assign(n.Config.prototype.filebrowser,{buttons:["filebrowser.home","filebrowser.previous","filebrowser.next","|","filebrowser.upload","filebrowser.remove","filebrowser.update","filebrowser.select","filebrowser.edit","|","filebrowser.preview","about"],sort:!1,pixelOffsetLoadNewChunk:200,width:750,height:400,previewOfficeURL:"https://view.officeapps.live.com/op/view.aspx?src="})},431:(e,t,o)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.finder=void 0;var n=o(1),r=o(187),i=o(432),s=o(2);o(477);var a=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.requires=["license"],t.hasStyle=!s.Jodit.fatMode,t}return n.__extends(t,e),t.prototype.afterInit=function(e){var t=this;e.e.on("getInstanceFileBrowser",(function(e){return t.__instance||(t.__instance=new i.FileBrowserPro(e)),t.__instance}))},t.prototype.beforeDestruct=function(e){var t;e.e.off("getInstanceFileBrowser"),null===(t=this.__instance)||void 0===t||t.destruct()},t}(r.Plugin);t.finder=a,s.Jodit.plugins.add("finder",a)},473:(e,t,o)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ContextMenuManager=void 0;var n=o(1),r=o(193),i=o(31),s=o(103),a=o(199),c=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return n.__extends(t,e),t.prototype.className=function(){return"ContextMenuManager"},t.prototype.onFolderContext=function(e,t){return this.buildContextItemMenu(this.getFolderContextActions(e),t),!1},t.prototype.onItemContext=function(e,t,o){return this.buildContextItemMenu(this.getItemContextActions(e),o),!1},t.prototype.onSourceContext=function(e,t){return this.buildContextItemMenu(this.getSourceContextActions(e),t),!1},t.prototype.buildContextItemMenu=function(e,t){if(this.j.o.contextMenu){var o=r.makeContextMenu(this.j).setMod("theme",this.j.state.theme);o.show(t.clientX,t.clientY,e.filter((function(e){return e&&!1!==e.enabled}))),this.j.e.on(this.j,"afterClose",(function(){o.isOpened&&o.close()}))}},t.prototype.getItemContextActions=function(e){var t=this;if(this.j.stateManager.isActive(e)||this.j.stateManager.addActive(e,this.j.state.activeElements.length>1),"folder"===e.type)return this.getFolderContextActions({type:"directory",children:[],name:e.name||"",path:e.path,sourceName:e.sourceName});var o=this.j.options,n=this.j.dataProvider,r=1===this.j.state.activeElements.length;return[{icon:"pencil",title:"Edit",enabled:Boolean(e.isImage)&&o.editImage&&r&&(n.canI("ImageResize")||n.canI("ImageCrop")),exec:function(){a.openImageEditor.call(t.j,e.imageURL,e.name||"",t.j.state.currentPath,t.j.state.currentSource)}},{icon:"italic",title:"Rename",enabled:n.canI("FileRename")&&r,exec:function(){return t.j.e.fire("fileRename.filebrowser",e)}},{icon:"bin",title:"Delete",enabled:n.canI("FileRemove"),exec:function(){return t.j.e.fire("fileRemove.filebrowser",e)}},{icon:"eye",title:"Preview",enabled:Boolean(e.isImage)&&o.preview&&r,exec:function(){return t.j.e.fire("openLightBox.filebrowser",e)}},{icon:"upload",title:"Download",exec:function(){e.fileURL&&t.j.ow.open(e.fileURL)}}]},t.prototype.getFolderContextActions=function(e){var t=this,o=this.j.dataProvider;return[{icon:"pencil",title:"Rename",exec:function(){t.j.e.fire("folderRename.filebrowser",e)},enabled:o.canI("FolderRename")},{icon:"bin",title:"Delete",exec:function(){t.j.e.fire("folderRemove.filebrowser",e)},enabled:o.canI("FolderRemove")},{icon:"plus",title:"Add folder",exec:function(){t.j.e.fire("folderCreate.filebrowser",e)},enabled:o.canI("FolderCreate")}]},t.prototype.getSourceContextActions=function(e){var t=this;return[{icon:"plus",title:"Create folder",exec:function(){t.j.e.fire("folderCreate.filebrowser",e)}}]},n.__decorate([s.watch(":contextmenuFolder.filebrowser")],t.prototype,"onFolderContext",null),n.__decorate([s.watch(":contextmenuItem.filebrowser")],t.prototype,"onItemContext",null),n.__decorate([s.watch(":contextmenuSource.filebrowser")],t.prototype,"onSourceContext",null),n.__decorate([s.component],t)}(i.ViewComponent);t.ContextMenuManager=c},474:(e,t)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.parentPath=void 0,t.parentPath=function(e){var t=e.split("/").filter((function(e){return e.length}));return t.pop(),t.join("/")||"/"}},472:(e,t,o)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.HistoryManager=void 0;var n=o(1),r=o(23),i=o(31),s=o(103),a=function(e){function t(t,o){var n=e.call(this,t)||this;return n.state=o,n}return n.__extends(t,e),t.prototype.className=function(){return"HistoryManager"},t.prototype.updateHistory=function(){this.state.history[this.state.historyIndex]={currentSource:this.state.currentSource,currentPath:this.state.currentPath,tree:r.fastClone(this.state.tree),elements:this.state.elements}},t.prototype.updateState=function(){var e=this.state.history[this.state.historyIndex],t=e.tree,o=e.currentSource,n=e.currentPath;this.state.elements=e.elements,this.state.tree=t,this.state.currentSource=o,this.state.currentPath=n,this.j.e.fire("changeSelection")},t.prototype.push=function(){var e=n.__spreadArray([],this.state.history),t=this.state.historyIndex,o=e[t];o&&o.currentSource===this.state.currentSource&&o.currentPath===this.state.currentPath||(e.length-1!==t&&(e=e.slice(0,t)),e.push({tree:[],elements:[],currentPath:this.state.currentPath,currentSource:this.state.currentSource}),o&&(t+=1),this.state.historyIndex=t,this.state.history=e,this.updateHistory(),this.j.e.fire("changeSelection"))},t.prototype.onNext=function(){this.state.history.length-1>this.state.historyIndex&&(this.state.historyIndex+=1,this.updateState())},t.prototype.onPrevious=function(){this.state.historyIndex>0&&(this.state.historyIndex-=1,this.updateState())},t.prototype.onHome=function(){this.state.currentSource="",this.state.currentPath="",this.j.e.fire("update.filebrowser")},n.__decorate([s.watch(":next.filebrowser")],t.prototype,"onNext",null),n.__decorate([s.watch(":previous.filebrowser")],t.prototype,"onPrevious",null),n.__decorate([s.watch(":goHome.filebrowser")],t.prototype,"onHome",null),n.__decorate([s.component],t)}(i.ViewComponent);t.HistoryManager=a},471:(e,t,o)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.PersistentStore=void 0;var n=o(1),r=o(31),i=o(103),s=o(195),a=function(e){function t(t,o){var n=e.call(this,t)||this;return n.state=o,n.sortBy="changed-desc",n.view="tiles",n.foldersPosition="top",n.tileSize="default",n.favorites=[],n.showSideBar=!0,n.showPreview=!1,n.showFavorites=!0,n}return n.__extends(t,e),t.prototype.className=function(){return"PersistentStore"},t.prototype.onChangeThemeSetField=function(){this.theme=this.state.theme},t.prototype.onChangeView=function(){this.view=this.state.view},t.prototype.onChangeSortBy=function(){this.sortBy=this.state.sortBy},t.prototype.onChangeTileSize=function(){this.tileSize=this.state.tileSize},t.prototype.onChangeFavorites=function(){this.favorites=this.state.favorites},t.prototype.onChangeShowSideBar=function(){this.showSideBar=this.state.showSideBar},t.prototype.onChangeShowPreview=function(){this.showPreview=this.state.showPreview},t.prototype.onChangeShowFavorites=function(){this.showFavorites=this.state.showFavorites},t.prototype.onChangeFoldersPosition=function(){this.foldersPosition=this.state.foldersPosition},t.prototype.syncWithState=function(){this.state.tileSize=this.tileSize,this.state.favorites=this.favorites.map((function(e){return e instanceof s.FileBrowserItem?e:s.FileBrowserItem.create(e)})),this.state.view=this.view,this.state.theme=this.theme,this.state.showSideBar=this.showSideBar,this.state.showPreview=this.showPreview,this.state.showFavorites=this.showFavorites,this.state.sortBy=this.sortBy,this.state.foldersPosition=this.foldersPosition},n.__decorate([i.persistent],t.prototype,"theme",void 0),n.__decorate([i.persistent],t.prototype,"sortBy",void 0),n.__decorate([i.persistent],t.prototype,"view",void 0),n.__decorate([i.persistent],t.prototype,"foldersPosition",void 0),n.__decorate([i.persistent],t.prototype,"tileSize",void 0),n.__decorate([i.persistent],t.prototype,"favorites",void 0),n.__decorate([i.persistent],t.prototype,"showSideBar",void 0),n.__decorate([i.persistent],t.prototype,"showPreview",void 0),n.__decorate([i.persistent],t.prototype,"showFavorites",void 0),n.__decorate([i.watch("state.theme")],t.prototype,"onChangeThemeSetField",null),n.__decorate([i.watch("state.view")],t.prototype,"onChangeView",null),n.__decorate([i.watch("state.sortBy")],t.prototype,"onChangeSortBy",null),n.__decorate([i.watch("state.tileSize")],t.prototype,"onChangeTileSize",null),n.__decorate([i.watch("state.favorites")],t.prototype,"onChangeFavorites",null),n.__decorate([i.watch("state.showSideBar")],t.prototype,"onChangeShowSideBar",null),n.__decorate([i.watch("state.showPreview")],t.prototype,"onChangeShowPreview",null),n.__decorate([i.watch("state.showFavorites")],t.prototype,"onChangeShowFavorites",null),n.__decorate([i.watch("state.foldersPosition")],t.prototype,"onChangeFoldersPosition",null),n.__decorate([i.component],t)}(r.ViewComponent);t.PersistentStore=a},466:(e,t,o)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.StateManager=void 0;var n=o(1),r=o(103),i=function(){function e(e){this.state=e}return e.prototype.getIndex=function(e,t){return void 0===t&&(t=this.state.elements),t.findIndex((function(t){return t.uniqueHashKey===e.uniqueHashKey}))},e.prototype.isActive=function(e){return Boolean(this.state.activeElements.find((function(t){return t.uniqueHashKey===e.uniqueHashKey})))},e.prototype.isFavorite=function(e){return Boolean(this.state.favorites.find((function(t){return t.uniqueHashKey===e.uniqueHashKey})))},e.prototype.addActive=function(e,t){var o;this.state.metaInfo=e,this.state.info=null!==(o=e.file)&&void 0!==o?o:"",this.state.lastSelectedIndex=this.getIndex(e),this.state.activeElements=t?n.__spreadArray(n.__spreadArray([],this.state.activeElements),[e]):[e]},e.prototype.callSelectHandler=function(){var e,t=this.state.activeElements;null===(e=this.state.onSelectCallBack)||void 0===e||e.call(this,{baseurl:"",files:t.map((function(e){return e.fileURL})),isImages:t.map((function(e){return Boolean(e.isImage)}))})},e.prototype.setFilter=function(e){this.state.filterWord=e},e.prototype.addMessage=function(e){var t,o=this.state.messages;(null===(t=o[o.length-1])||void 0===t?void 0:t.message)!==e.message&&(this.state.messages=n.__spreadArray(n.__spreadArray([],o),[e]))},e.prototype.removeMessage=function(e){var t=this.state.messages.indexOf(e);if(-1!==t){var o=n.__spreadArray([],this.state.messages);o.splice(t,1),this.state.messages=o}},e.prototype.toggleFavorite=function(e){var t=this.getIndex(e,this.state.favorites),o=n.__spreadArray([],this.state.favorites);-1===t?o.push(e):o.splice(t,1),this.state.favorites=o},e.prototype.fillSources=function(e,t){var o=this,n=function(e){return e.filter((function(e){return"."!==e&&".."!==e}))};if(this.state.tree.length&&t){var r=function(e,t){var o;return null!==(o=e.find((function(e){return e.name===t})))&&void 0!==o?o:null};this.removeActive(this.state.tree),e.forEach((function(e){var i=r(o.state.tree,e.name);if(i){i.isActive=!0;var s=t.split("/").reduce((function(e,t){return e&&r(e.children,t)}),i);s&&(s.isActive=!0,s.children=n(e.folders).map((function(o){return{type:"directory",name:o,path:t+"/"+o,sourceName:e.name,children:[]}})))}}))}else this.state.tree=e.map((function(e){return{type:"source",name:e.name,title:e.title,sourceName:e.name,path:"/",children:n(e.folders).map((function(t){return{type:"directory",name:t,path:t,sourceName:e.name,children:[]}}))}}))},e.prototype.removeActive=function(e){var t=this;e.forEach((function(e){e.isActive=!1,t.removeActive(e.children)}))},Object.defineProperty(e.prototype,"isFavoriteItems",{get:function(){return this.state.favorites===this.state.elements},enumerable:!1,configurable:!0}),n.__decorate([r.autobind],e.prototype,"getIndex",null),n.__decorate([r.autobind],e.prototype,"isActive",null),n.__decorate([r.autobind],e.prototype,"isFavorite",null),e}();t.StateManager=i},478:(e,t,o)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.ru=void 0;var n=o(479);t.ru=n},434:(e,t,o)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=o(79),r=o(435),i=o(436);n.Icon.set("heart",String(r)),n.Icon.set("home",String(i))},460:(e,t,o)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.UIBrowserFolder=void 0;var n=o(1);o(461);var r=o(79),i=o(103),s=function(e){function t(t,o){var n=e.call(this,t)||this;return n.item=o,n.syncMod=!0,n.getElm("name").innerText=o.name,t.e.on(n.container,"click",(function(){return n.getMod("active")||n.setMod("loading",!0),t.e.fire("openFolder",o)})).on(n.container,"contextmenu",(function(e){return t.e.fire("contextmenuFolder.filebrowser",o,e)})),n}return n.__extends(t,e),t.prototype.className=function(){return"UIBrowserFolder"},t.prototype.render=function(){return'<div>\n\t\t\t<div class="&__icon">\n\t\t\t\t<div class=\'&__loader\'></div>\n\t\t\t\t<div class="&__icon-wrapper">\n\t\t\t\t\t*folder*\n\t\t\t\t</div>\n\t\t\t</div>\n\t\t\t<div class="&__name"></div>\n\t\t\t<div class="&__arrow">*angle-right*</div>\n\t\t</div>'},n.__decorate([i.component],t)}(r.UIElement);t.UIBrowserFolder=s},467:(e,t,o)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.UIBrowserHeader=void 0;var n=o(1);o(468);var r=o(79),i=o(103),s=o(176),a=function(e){function t(t,o,n){var i,a=e.call(this,t)||this;return a.options=o,a.stateManager=n,a.syncMod=!0,a.toolbar=s.makeCollection(a.j),a.filter=new r.UIInput(a.j,{icon:"search",placeholder:"Filter",clearButton:!0,onChange:function(e){a.stateManager.setFilter(e)}}),a.append(a.toolbar).append(a.filter),a.filter.container.classList.add(a.getFullElName("filter")),a.toolbar.setMod("mode","header").build(null!==(i=a.options.toolbarButtons)&&void 0!==i?i:[]),a}return n.__extends(t,e),t.prototype.className=function(){return"UIBrowserHeader"},n.__decorate([i.component],t)}(r.UIGroup);t.UIBrowserHeader=a},441:(e,t,o)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.UIBrowserItem=void 0;var n=o(1);o(442);var r=o(79),i=o(103),s=o(195),a=o(14),c=o(23),l=function(e){function t(t,o){var n=e.call(this,t)||this;return n.item=s.FileBrowserItem.create(o),t.e.on(n.container,"click contextmenu dblclick",(function(e){return t.e.fire(e.type+"Item.filebrowser",n.item,c.ctrlKey(e)||e.shiftKey,e),!1})),n}return n.__extends(t,e),t.prototype.className=function(){return"UIBrowserItem"},t.prototype.render=function(){return"<div tabindex='-1'>\n\t\t\t<div class='&__image'></div>\n\t\t\t<div class='&__info'></div>\n\t\t\t<div class='&__heart'>*heart*</div>\n\t\t</div>"},t.prototype.onClickFavorite=function(){var e=this;return this.bubble((function(t){e.jodit.e.fire(t,"toggleFavoriteItem",e.item)})),!1},t.prototype.onAction=function(e){return this.jodit.e.fire(e.type+"Item.filebrowser",this.item,c.ctrlKey(e)||e.shiftKey,e),!1},t.prototype.update=function(){var t;c.css(this.getElm("image"),"backgroundImage","url("+this.item.imageURL+")"),this.setMod("is-file",!1===this.item.isImage).setMod("type",null!==(t=this.item.type)&&void 0!==t?t:"file").setElementValue("name",this.item.file).setElementValue("time",this.item.time).setElementValue("filesize",this.item.size),c.attr(this.container,"title",this.item.file+" "+this.item.time+" "+this.item.size),e.prototype.update.call(this)},t.prototype.setElementValue=function(e,t){var o=this.getFullElName(e),n=this.getElm(e);if(!t)return n&&a.Dom.safeRemove(n),this;if(!n){var r=this.getElm("info");n=this.j.create.div(o),r.appendChild(n)}return n.innerText=t,this},n.__decorate([i.watch("heart:click")],t.prototype,"onClickFavorite",null),n.__decorate([i.watch(["container:click","container:contextmenu","container:dblclick"])],t.prototype,"onAction",null),n.__decorate([i.component],t)}(r.UIElement);t.UIBrowserItem=l},475:(e,t,o)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.UILightBox=void 0;var n=o(1);o(476);var r=o(14),i=o(103),s=o(23),a=o(13),c=function(e){function t(t,o,n){var i=e.call(this,t)||this;i.current=o,i.elements=n,i.dialog=new r.Dialog;var s=i.dialog;return s.setMod("theme",t.state.theme).toolbar.setMod("mode","header"),s.open(i),i.elements=i.elements.filter((function(e){return e.isImage})),s.e.on(s,"afterClose",(function(){i.destruct()})),i.addGlobalListeners(),i.onChangeCurrent(),s.toolbar.build([{icon:"check",exec:function(){t.stateManager.addActive(i.current,!1),t.e.fire("select.filebrowser"),s.close()}},"dialog.close"]),i}var o;return n.__extends(t,e),o=t,t.prototype.className=function(){return"UILightBox"},t.prototype.render=function(){return"<div>\n\t\t\t<div class='&__previous'>*angle-left*</div>\n\t\t\t<div class='&__preview'></div>\n\t\t\t<div class='&__loader'></div>\n\t\t\t<div class='&__next'>*angle-right*</div>\n\t\t</div>"},t.prototype.onChangeCurrent=function(){return n.__awaiter(this,void 0,Promise,(function(){var e,t,o,i;return n.__generator(this,(function(n){switch(n.label){case 0:return e=this.current,this.setMod("loading",!0),t=this.getElm("preview"),r.Dom.detach(t),s.css(t,{backgroundImage:null}),e.isImage?[4,s.loadImage(e.fileURL,this.j)]:[3,2];case 1:return o=n.sent(),this.dialog.setPosition(),s.css(t,{width:Math.min(this.jodit.ow.innerWidth,o.naturalWidth),height:Math.min(this.jodit.ow.innerHeight-100,o.naturalHeight),backgroundImage:"url("+o.src+")"}),[3,4];case 2:return[4,this.makeIframe(e.fileURL)];case 3:i=n.sent(),t.appendChild(i),n.label=4;case 4:return this.dialog.setSize(),this.dialog.setPosition(),this.setMod("loading",!1),[2]}}))}))},t.prototype.makeIframe=function(e){var t=this.j.c.element("iframe");return t.classList.add(this.getFullElName("office-iframe")),t.src=/\.pdf/.test(e)?e:this.j.o.previewOfficeURL+encodeURIComponent(e),t},t.prototype.onPreviousClick=function(){var e=this.j.stateManager.getIndex(this.current,this.elements);e>0?e-=1:e=this.elements.length-1,this.current=this.elements[e]},t.prototype.onNextClick=function(){var e=this.j.stateManager.getIndex(this.current,this.elements);this.elements.length-1>e?e+=1:e=0,this.current=this.elements[e]},t.open=function(e,t,n){return new o(e,t,n)},t.prototype.addGlobalListeners=function(){this.j.e.on(this.j.od,"keydown",this.onKeyPress)},t.prototype.onKeyPress=function(e){if(e.key===a.KEY_LEFT||e.key===a.KEY_RIGHT||e.key===a.KEY_SPACE)return e.key===a.KEY_LEFT?this.onPreviousClick():this.onNextClick(),!1},t.prototype.removeGlobalListeners=function(){this.j.e.off(this.j.od,"keydown",this.onKeyPress)},t.prototype.destruct=function(){return this.removeGlobalListeners(),this.dialog.destruct(),e.prototype.destruct.call(this)},n.__decorate([i.watch("current")],t.prototype,"onChangeCurrent",null),n.__decorate([i.watch("previous:click")],t.prototype,"onPreviousClick",null),n.__decorate([i.watch("next:click")],t.prototype,"onNextClick",null),n.__decorate([i.autobind],t.prototype,"onKeyPress",null),o=n.__decorate([i.component],t)}(r.UIElement);t.UILightBox=c},447:(e,t,o)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.UIBrowserMessage=void 0;var n=o(1),r=o(79),i=o(103),s=o(23),a=function(e){function t(t,o){var n=e.call(this,t)||this;return n.container.innerText=s.isString(o)?o:o.message,n}return n.__extends(t,e),t.prototype.className=function(){return"UIBrowserMessage"},n.__decorate([i.component],t)}(r.UIElement);t.UIBrowserMessage=a},445:(e,t,o)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.UIBrowserMessages=void 0;var n=o(1);o(446);var r=o(79),i=o(103),s=o(447),a=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return n.__extends(t,e),t.prototype.className=function(){return"UIBrowserMessages"},t.prototype.build=function(e){var t=this;this.clear(),e.forEach((function(e){var o=new s.UIBrowserMessage(t.jodit,e.message);o.setMod("type",e.type),t.append(o)}))},n.__decorate([i.component],t)}(r.UIGroup);t.UIBrowserMessages=a},437:(e,t,o)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.UIBrowserPanel=void 0;var n=o(1);o(438);var r=o(79),i=o(439),s=o(445),a=o(103),c=o(448),l=o(452),u=o(23),h=o(454),d=o(462),p=o(464),f=function(e){function t(t,o){var n=e.call(this,t)||this;return n.stateManager=o,n.syncMod=!0,n.sources=new h.UIBrowserSources(n.j),n.sidebar=new c.UISidebar(n.jodit,[n.sources],n.stateManager.state),n.preview=new p.UIPreview(n.jodit,n.stateManager.state),n.statusbar=new d.UIBrowserStatusBar(n.j),n.items=new i.UIVirtualScroll(n.j,n.stateManager),n.settings=new l.UIBrowserSettings(n.jodit,n.stateManager.state),n.messages=new s.UIBrowserMessages(n.j),n.state=o.state,n.append(n.sidebar,"content"),n.append(n.items,"content"),n.append(n.messages,"footer"),n.append(n.settings,"content"),n.append(n.preview,"content"),n.append(n.statusbar,"footer"),n.onChangeElements(),n.onChangeSources(),n.onChangeView(),n.onChangeTileSize(),n.onChangeShowFavorites(),n.onChangeMessages(),n.onChangeActiveElements(),n.onChangeFavorites(),n.onChangeShowSideBar(),n.onChangeShowSettings(),n.onChangeShowPreview(),n.onChangeTheme(),n}return n.__extends(t,e),t.prototype.className=function(){return"UIBrowserPanel"},Object.defineProperty(t.prototype,"countInRow",{get:function(){if("list"===this.state.view)return 1;var e=this.items.elements[0].container,t=u.css(e,"marginLeft");return Math.floor(this.items.container.offsetWidth/(e.offsetWidth+(u.isNumber(t)?t:0)))},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"countInColumn",{get:function(){var e=this.items.elements[0].container,t=u.css(e,"marginTop");return Math.floor(this.items.container.offsetHeight/(e.offsetHeight+(u.isNumber(t)?t:0)))},enumerable:!1,configurable:!0}),t.prototype.render=function(){return"<div>\n\t\t\t<div class='&__content'></div>\n\t\t\t<div class='&__footer'></div>\n\t\t</div>"},t.prototype.onChangeTheme=function(){this.setMod("theme",this.stateManager.state.theme)},t.prototype.onChangeElements=function(){this.items.build(this.stateManager.state.elements)},t.prototype.onChangeActiveElements=function(){var e=this;this.state.activeElements.length||(this.state.info="",this.state.metaInfo=null),this.items.elements.forEach((function(t){t.setMod("active",Boolean(e.stateManager.isActive(t.item)))})),this.j.e.fire("changeSelection")},t.prototype.onChangeFavorites=function(){var e=this;this.items.elements.forEach((function(t){t.setMod("favorite",Boolean(e.stateManager.isFavorite(t.item)))}))},t.prototype.onChangeSources=function(){this.sources.build(this.stateManager.state.tree)},t.prototype.onChangeLastSelectedIndex=function(){var e,t=null===(e=this.items.elements[this.stateManager.state.lastSelectedIndex])||void 0===e?void 0:e.container;t&&(u.scrollIntoViewIfNeeded(t,this.items.container,this.j.od),t.focus())},t.prototype.onChangeInfo=function(){this.statusbar.value(this.state.info,"center")},t.prototype.onChangePathOrSource=function(){this.statusbar.value(this.state.currentPath?this.state.currentPath+" ("+this.state.currentSource+")":this.i18n("Home"),"left")},t.prototype.onChangeShowSettings=function(){this.settings.setMod("hidden",!this.stateManager.state.showSettings)},t.prototype.onChangeShowPreview=function(){this.preview.setMod("hidden",!this.stateManager.state.showPreview)},t.prototype.onChangeShowSideBar=function(){this.sidebar.setMod("hidden",!this.stateManager.state.showSideBar)},t.prototype.onChangeView=function(){this.items.setMod("view",this.stateManager.state.view)},t.prototype.onChangeTileSize=function(){this.items.setMod("size",this.stateManager.state.tileSize)},t.prototype.onChangeShowFavorites=function(){this.sidebar.setMod("show-favorites",this.stateManager.state.showFavorites),this.items.setMod("show-favorites",this.stateManager.state.showFavorites)},t.prototype.onChangeMessages=function(){this.messages.build(this.stateManager.state.messages)},t.prototype.onItemDblClick=function(){return this.j.e.fire("select.filebrowser"),!1},t.prototype.onItemClick=function(e,t){this.stateManager.addActive(e,t)},t.prototype.onTogglePreview=function(){return this.state.showPreview=!this.state.showPreview,!1},t.prototype.onToggleFavoriteItem=function(e){this.stateManager.toggleFavorite(e)},t.prototype.onFolderClick=function(e){this.stateManager.state.currentSource=e.sourceName,this.stateManager.state.currentPath=e.path||"/"},n.__decorate([a.watch("state.theme")],t.prototype,"onChangeTheme",null),n.__decorate([a.watch("state.elements")],t.prototype,"onChangeElements",null),n.__decorate([a.watch("state.activeElements")],t.prototype,"onChangeActiveElements",null),n.__decorate([a.watch(["state.favorites","state.elements"])],t.prototype,"onChangeFavorites",null),n.__decorate([a.watch("state.sources")],t.prototype,"onChangeSources",null),n.__decorate([a.watch("state.lastSelectedIndex")],t.prototype,"onChangeLastSelectedIndex",null),n.__decorate([a.watch("state.info")],t.prototype,"onChangeInfo",null),n.__decorate([a.watch(["state.currentPath","state.currentSource"])],t.prototype,"onChangePathOrSource",null),n.__decorate([a.watch("state.showSettings")],t.prototype,"onChangeShowSettings",null),n.__decorate([a.watch("state.showPreview")],t.prototype,"onChangeShowPreview",null),n.__decorate([a.watch("state.showSideBar")],t.prototype,"onChangeShowSideBar",null),n.__decorate([a.watch("state.view")],t.prototype,"onChangeView",null),n.__decorate([a.watch("state.tileSize")],t.prototype,"onChangeTileSize",null),n.__decorate([a.watch("state.showFavorites")],t.prototype,"onChangeShowFavorites",null),n.__decorate([a.watch("state.messages")],t.prototype,"onChangeMessages",null),n.__decorate([a.watch(":dblclickItem.filebrowser")],t.prototype,"onItemDblClick",null),n.__decorate([a.watch(":clickItem.filebrowser")],t.prototype,"onItemClick",null),n.__decorate([a.watch(":togglePreview.filebrowser")],t.prototype,"onTogglePreview",null),n.__decorate([a.watch(":toggleFavoriteItem")],t.prototype,"onToggleFavoriteItem",null),n.__decorate([a.watch(":openFolder")],t.prototype,"onFolderClick",null),n.__decorate([a.component],t)}(r.UIGroup);t.UIBrowserPanel=f},464:(e,t,o)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.UIPreview=void 0;var n=o(1);o(465);var r=o(79),i=o(103),s=o(450),a=o(23),c=o(36),l=o(441),u=function(e){function t(t,o){var n=e.call(this,t)||this;return n.state=o,n.lastLoadPromise=null,n.onChangeMetaInfo(),n}return n.__extends(t,e),t.prototype.className=function(){return"UIPreview"},t.prototype.addResize=function(){s.UIResize.remove(this),s.UIResize.install(this,screen.width>450?"left":"top")},t.prototype.render=function(){return'<div>\n\t\t\t\t<div class="&__image"></div>\n\t\t\t\t<div class="&__info"></div>\n\t\t\t\t<div class="&__loader"></div>\n\t\t\t\t<div class="&__empty-message">~Select image~</div>\n\t\t\t</div>'},t.prototype.setMod=function(t,o){return e.prototype.setMod.call(this,t,o),"hidden"===t&&!1===o&&this.onChangeMetaInfo(),this},t.prototype.onChangeMetaInfo=function(){var e,t,o=this;if(!this.getMod("hidden")){var n=this.state.metaInfo;this.setMod("empty",!n),c.Dom.detach(this.getElm("info")),a.css(this.getElm("image"),{backgroundImage:null}),n&&(this.setMod("is-file",!1===n.isImage).setMod("type",null!==(e=n.type)&&void 0!==e?e:"file"),l.UIBrowserItem.prototype.setElementValue.call(this,"name",n.file),l.UIBrowserItem.prototype.setElementValue.call(this,"time",n.time),l.UIBrowserItem.prototype.setElementValue.call(this,"filesize",n.size),this.setMod("loading",!0),null===(t=this.lastLoadPromise)||void 0===t||t.rejectCallback(),this.lastLoadPromise=a.loadImage(n.isImage?n.fileURL:n.imageURL,this.j),this.lastLoadPromise.then((function(e){e&&a.css(o.getElm("image"),{backgroundImage:"url("+e.src+")"})})).finally((function(){o.setMod("loading",!1)})).catch((function(){})))}},n.__decorate([i.hook("ready"),i.watch(":resize",window),i.debounce()],t.prototype,"addResize",null),n.__decorate([i.watch("state.metaInfo")],t.prototype,"onChangeMetaInfo",null),n.__decorate([i.component],t)}(r.UIGroup);t.UIPreview=u},469:(e,t,o)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.UIProgress=void 0;var n=o(1);o(470);var r=o(79),i=o(103),s=function(e){function t(t,o){var n=e.call(this,t)||this;return n.state=o,n.onProgress(),n}return n.__extends(t,e),t.prototype.className=function(){return"UIProgress"},t.prototype.onProgress=function(){this.state.progress?this.show():this.hide(),this.progress(this.state.progress)},t.prototype.hide=function(){return this.setMod("hidden",!0),this},t.prototype.progress=function(e){var t=this;return this.container.style.width=e.toFixed(2)+"%",98>e||this.j.async.setTimeout((function(){t.hide()}),{label:"progress",timeout:300}),this},t.prototype.show=function(){return this.setMod("hidden",!1),this},n.__decorate([i.watch("state.progress")],t.prototype,"onProgress",null),n.__decorate([i.component],t)}(r.ProgressBar);t.UIProgress=s},452:(e,t,o)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.UIBrowserSettings=void 0;var n=o(1);o(453);var r=o(79),i=o(103),s=function(e){function t(t,o){var n=e.call(this,t)||this;return n.state=o,t.e.on(n.getElm("close"),"click",(function(){n.state.showSettings=!1})),n}return n.__extends(t,e),t.prototype.className=function(){return"UIBrowserSettings"},t.prototype.render=function(){return'<div>\n\t\t\t<div class="'+this.getFullElName("close")+'">'+r.Icon.get("cancel")+'</div>\n\t\t\t<div class="'+this.getFullElName("title")+'">'+this.j.i18n("Settings")+'</div>\n\t\t\t<div class="'+this.getFullElName("options")+'"></div>\n\t\t</div>'},t.prototype.appendChildToContainer=function(e){this.getElm("options").appendChild(e)},t.prototype.setMod=function(t,o){return"hidden"===t&&!1===o&&this.generateSettings(),e.prototype.setMod.call(this,t,o)},t.prototype.onChangeView=function(){var e=this.getElm("tile-size");e&&(e.style.display="tiles"===this.state.view?"block":"none")},t.prototype.generateSettings=function(){var e=this;this.clear();var t=this.j;this.append([new r.UIButtonGroup(t,{label:"Theme",name:"theme",value:this.state.theme,radio:!0,options:[{value:"default",text:"Light"},{value:"dark",text:"Dark"}],onChange:function(t){e.state.theme=t[0].value}}),new r.UIButtonGroup(t,{label:"Show favorites",name:"showFavorites",value:this.state.showFavorites,radio:!0,options:[{value:!0,text:"Show"},{value:!1,text:"Hide"}],onChange:function(t){e.state.showFavorites=t[0].value}}),new r.UIButtonGroup(t,{label:"View",name:"view",value:this.state.view,radio:!0,options:[{value:"tiles",text:"Tiles"},{value:"list",text:"List"},{value:"compact",text:"Compact"}],onChange:function(t){e.state.view=t[0].value}}),new r.UIButtonGroup(t,{label:"Folders position",name:"foldersPosition",value:this.state.foldersPosition,radio:!0,options:[{value:"top",text:"Top"},{value:"bottom",text:"Bottom"},{value:"default",text:"Default"}],onChange:function(t){e.state.foldersPosition=t[0].value}}),new r.UISelect(t,{label:"Sort by",name:"sort-by",value:this.state.sortBy,options:[{value:"changed-asc",text:t.i18n("Sort by changed")+"(⬆)"},{value:"changed-desc",text:t.i18n("Sort by changed")+"(⬇)"},{value:"name-asc",text:t.i18n("Sort by name")+"(⬆)"},{value:"name-desc",text:t.i18n("Sort by name")+"(⬇)"},{value:"size-asc",text:t.i18n("Sort by size")+"(⬆)"},{value:"size-desc",text:t.i18n("Sort by size")+"(⬇)"}],onChange:function(t){e.state.sortBy=t}}),new r.UISelect(t,{label:"Tile size",name:"tile-size",value:this.state.tileSize,options:[{value:"xsmall",text:"Extra small"},{value:"small",text:"Small"},{value:"default",text:"Default"},{value:"large",text:"Large"},{value:"xlarge",text:"Extra large"}],onChange:function(t){e.state.tileSize=t}})]),this.onChangeView()},n.__decorate([i.watch("state.view")],t.prototype,"onChangeView",null),n.__decorate([i.component],t)}(r.UIGroup);t.UIBrowserSettings=s},448:(e,t,o)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.UISidebar=void 0;var n=o(1);o(449);var r=o(79),i=o(103),s=o(450),a=function(e){function t(t,o,n){var r=e.call(this,t,o)||this;return r.state=n,r.onChangeFavorites(),r}return n.__extends(t,e),t.prototype.className=function(){return"UISidebar"},t.prototype.render=function(){return"<div>\n\t\t\t<div class='&__hide-btn'>*angle-left*</div>\n\t\t\t<div class='&__favorites'>*heart* ~Favorites~</div>\n\t\t\t<div class='&__box'></div>\n\t\t</div>"},t.prototype.appendChildToContainer=function(e){this.getElm("box").appendChild(e)},t.prototype.addResize=function(){s.UIResize.remove(this),s.UIResize.install(this,screen.width>450?"right":"bottom")},t.prototype.onChangeFavorites=function(){this.setMod("has-favorites",Boolean(this.state.favorites.length))},t.prototype.onClickHideButton=function(){return this.state.showSideBar=!this.state.showSideBar,!1},t.prototype.onClickFavorites=function(){return this.state.elements=this.state.favorites,!1},n.__decorate([i.hook("ready"),i.watch(":resize",window),i.debounce()],t.prototype,"addResize",null),n.__decorate([i.watch("state.favorites")],t.prototype,"onChangeFavorites",null),n.__decorate([i.watch("hide-btn:click")],t.prototype,"onClickHideButton",null),n.__decorate([i.watch("favorites:click")],t.prototype,"onClickFavorites",null),n.__decorate([i.component],t)}(r.UIGroup);t.UISidebar=a},456:(e,t,o)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.UIBrowserSource=void 0;var n=o(1);o(457);var r=o(79),i=o(103),s=o(458),a=function(e){function t(t,o){var n=e.call(this,t,o)||this;return n.data=o,n.tree=new s.UITree(n.j,n.data.children),n.syncMod=!0,n.getElm("name").innerText=o.title||o.name,n.getElm("tree").appendChild(n.tree.container),t.e.on(n.container,"contextmenu",(function(e){return t.e.fire("contextmenuSource.filebrowser",o,e)})),n}return n.__extends(t,e),t.prototype.className=function(){return"UIBrowserSource"},t.prototype.render=function(){return'<div>\n\t\t\t<div class="&__name"></div>\n\t\t\t<div class="&__tree"></div>\n\t\t</div>'},n.__decorate([i.component],t)}(r.UIElement);t.UIBrowserSource=a},454:(e,t,o)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.UIBrowserSources=void 0;var n=o(1);o(455);var r=o(79),i=o(103),s=o(456),a=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.syncMod=!0,t}return n.__extends(t,e),t.prototype.className=function(){return"UIBrowserSources"},t.prototype.build=function(e){var t=this;this.clear(),e.forEach((function(e){t.append(new s.UIBrowserSource(t.jodit,e))}))},n.__decorate([i.component],t)}(r.UIGroup);t.UIBrowserSources=a},462:(e,t,o)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.UIBrowserStatusBar=void 0;var n=o(1);o(463);var r=o(79),i=o(103),s=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return n.__extends(t,e),t.prototype.className=function(){return"UIBrowserStatusBar"},t.prototype.render=function(){return"<div>\n\t\t\t<div class='&__slot-left'></div>\n\t\t\t<div class='&__slot-center'></div>\n\t\t\t<div class='&__slot-right'></div>\n\t\t</div>"},t.prototype.value=function(e,t){return void 0===t&&(t="left"),this.getElm("slot-"+t).innerText=e,this},n.__decorate([i.component],t)}(r.UIElement);t.UIBrowserStatusBar=s},458:(e,t,o)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.UITree=void 0;var n=o(1);o(459);var r=o(79),i=o(103),s=o(460),a=function(e){function t(t,o){var n=e.call(this,t)||this;return n.syncMod=!0,n.build(o),n}var o;return n.__extends(t,e),o=t,t.prototype.className=function(){return"UITree"},t.prototype.build=function(e){var t=this;this.clear(),e.forEach((function(e){var n=new s.UIBrowserFolder(t.jodit,e);t.append(n),e.isActive&&n.setMod("active",!0),e.children.length&&t.append(new o(t.jodit,e.children))}))},o=n.__decorate([i.component],t)}(r.UIGroup);t.UITree=a},439:(e,t,o)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.UIVirtualScroll=void 0;var n=o(1);o(440);var r=o(79),i=o(103),s=o(441),a=o(195),c=o(443),l=o(23),u=function(e){function t(t,o){var n=e.call(this,t)||this;return n.stateManager=o,n.syncMod=!0,n.addItemsSelector(),n}var o;return n.__extends(t,e),o=t,t.prototype.className=function(){return"UIVirtualScroll"},t.prototype.render=function(){return"<div>\n\t\t\t\t<div class=\"&__empty-message\">~There are no files~</div>\n\t\t\t\t<div class='&__loader'></div>\n\t\t\t\t<div class='&__drag-area'>~Drop image~</div>\n\t\t\t</div>"},t.prototype.build=function(e){var t=this,o=this.elements.findIndex((function(t,o){return!e[o]||t.item.uniqueHashKey!==a.FileBrowserItem.create(e[o]).uniqueHashKey}));if(o>-1){for(var n=o;this.elements.length>n;n+=1)this.elements[n].destruct();this.elements.length=o}e.slice(o>-1?o:this.elements.length).forEach((function(e){var o=new s.UIBrowserItem(t.jodit,e);Object.keys(t.mods).forEach((function(e){o.setMod(e,t.mods[e])})),t.append(o)})),this.setMod("empty",!this.elements.length)},t.prototype.onScrollLoadChunk=function(){!this.stateManager.isFavoriteItems&&this.j.o.pixelOffsetLoadNewChunk>this.container.scrollHeight-(this.container.scrollTop+this.container.offsetHeight)&&this.j.loadItemsChunk()},t.prototype.onDragOver=function(e){e.preventDefault(),this.setMod("dragover",!0)},t.prototype.onDragLeave=function(e){e.preventDefault(),this.setMod("dragover",!1)},t.prototype.addItemsSelector=function(){c.UISelectItems.install(this)},t.intersectRect=function(e,t){return!(t.left>e.left+e.width||e.left>t.left+t.width||t.top>e.top+e.height||e.top>t.top+t.height)},t.prototype.onSelectItems=function(e){var t=[];this.elements.forEach((function(n){var r=l.position(n.container);o.intersectRect(r,e)&&t.push(n.item)})),this.stateManager.state.activeElements=t},n.__decorate([i.watch(":afterResize"),i.watch(":resize"),i.watch("container:scroll"),i.throttle()],t.prototype,"onScrollLoadChunk",null),n.__decorate([i.watch("container:dragover")],t.prototype,"onDragOver",null),n.__decorate([i.watch(["container:dragleave","container:drop"])],t.prototype,"onDragLeave",null),o=n.__decorate([i.component],t)}(r.UIGroup);t.UIVirtualScroll=u},450:(e,t,o)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.UIResize=void 0,o(451);var n=o(23),r=o(36),i=function(){function e(){}return e.remove=function(e){n.css(e.container,{width:null,height:null}),e.container.classList.remove("jodit-ui-resize"),r.Dom.safeRemove(e.container.querySelector(".jodit-ui-resize__handle"))},e.install=function(e,t){e.container.classList.add("jodit-ui-resize"),"static"===n.css(e.container,"position")&&n.css(e.container,"position","relative");var o=e.j.c.div("jodit-ui-resize__handle");o.classList.add("jodit-ui-resize__handle_type_"+t),e.container.appendChild(o),e.j.e.on(o,"mousedown touchstart",this.onStartResize.bind(this,e,t))},e.onStartResize=function(e,t,o){var n=e.j.async.throttle(this.onResize.bind(this,e,{x:o.clientX,y:o.clientY,w:e.container.offsetWidth,h:e.container.offsetHeight,direction:t}),e.j.defaultTimeout/10);e.j.lock(),e.j.e.on(e.j.ow,"mousemove touchmove",n).one(e.j.ow,"mouseup touchend",this.onEndResize.bind(this,e,n))},e.onResize=function(e,t,o){var r=["left","right"].includes(t.direction),i=e.container.parentElement;i&&n.css(e.container,r?"width":"height",100*(r?(t.w+(o.clientX-t.x)*("right"===t.direction?1:-1))/i.offsetWidth:(t.h+(o.clientY-t.y)*("top"===t.direction?1:-1))/i.offsetHeight)+"%")},e.onEndResize=function(e,t,o){e.j.e.off(e.j.ow,"mousemove touchmove",t),e.j.unlock()},e}();t.UIResize=i},443:(e,t,o)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.UISelectItems=void 0,o(444);var n=o(36),r=o(23),i=function(){function e(){}return e.remove=function(e){n.Dom.safeRemove(e.container.querySelector(".jodit-ui-select-items")),e.j.e.off(e.container,"mousedown.uiselectitems touchstart.uiselectitems")},e.install=function(e){var t=e.j.c.div("jodit-ui-select-items");e.j.e.on(e.container,"mousedown.uiselectitems touchstart.uiselectitems",this.onStartSelect.bind(this,e,t))},e.onStartSelect=function(e,t,o){if(o.target===e.container){r.css(t,{width:0,height:0}),e.container.appendChild(t);var n={x:o.clientX,y:o.clientY,w:e.container.offsetWidth,h:e.container.offsetHeight},i=e.j.async.throttle(this.onSelect.bind(this,e,t,n),e.j.defaultTimeout/10);e.j.lock(),e.j.e.on(e.j.ow,"mousemove touchmove",i).one(e.j.ow,"mouseup touchend",this.onEndSelect.bind(this,e,t,i)),e.onSelectItems({left:n.x,top:n.y,width:0,height:0})}},e.onSelect=function(e,t,o,n){var i={left:o.x>n.clientX?n.clientX:o.x,top:o.y>n.clientY?n.clientY:o.y,width:Math.abs(o.x-n.clientX),height:Math.abs(o.y-n.clientY)};r.css(t,i),e.onSelectItems(i)},e.onEndSelect=function(e,t,o,r){n.Dom.safeRemove(t),e.j.e.off(e.j.ow,"mousemove touchmove",o),e.j.unlock()},e}();t.UISelectItems=i},479:e=>{e.exports={Favorites:"Избранное",Settings:"Настройки",Light:"Светлая",Dark:"Темная",Theme:"Тема",Show:"Показать",Hide:"Скрыть","Show favorites":"Показывать избранное",Tiles:"Плитка",List:"Список",Compact:"Компактный",View:"Отображение","Folders position":"Позиция папок","Sort by":"Сортировать по","Extra small":"Очень маленькие",Small:"Маленькие",Large:"Большие","Extra large":"Очень большие","Tile size":"Размер плитки"}}},e=>{"use strict";return e(e.s=431)}])}));
/*!
* jodit-pro - PRO Version of Jodit Editor
* Author: Chupurnov Valeriy <chupurnov@gmail.com>
* Version: v1.0.45
* Version: v1.0.46
* Url: https://xdsoft.net/jodit/pro/

@@ -10,2 +10,2 @@ * License(s): SEE LICENSE IN LICENSE.md

((t,e)=>{if("object"==typeof exports&&"object"==typeof module)module.exports=e();else if("function"==typeof define&&define.amd)define([],e);else{var s=e();for(var i in s)("object"==typeof exports?exports:t)[i]=s[i]}})(self,(function(){return(self.webpackChunkjodit_pro=self.webpackChunkjodit_pro||[]).push([[524],{169(t){t.exports='<svg viewBox="0 0 512 512" xmlns="http://www.w3.org/2000/svg"> <path d="M365.4,59.628c60.56,0,109.6,49.03,109.6,109.47c0,109.47-109.6,171.8-219.06,281.271 C146.47,340.898,37,278.568,37,169.099c0-60.44,49.04-109.47,109.47-109.47c54.73,0,82.1,27.37,109.47,82.1 C283.3,86.999,310.67,59.628,365.4,59.628z"/> </svg>'},170(t){t.exports='<svg viewBox="0 0 32 32" xmlns="http://www.w3.org/2000/svg"> <path d="M28.7,16.3l-12-13c-0.4-0.4-1.1-0.4-1.5,0l-12,13C3,16.6,2.9,17,3.1,17.4C3.2,17.8,3.6,18,4,18h3v10c0,0.6,0.4,1,1,1h16 c0.6,0,1-0.4,1-1V18h3c0.4,0,0.8-0.2,0.9-0.6C29.1,17,29,16.6,28.7,16.3z"/> </svg>'},168(t,e,s){"use strict";s.r(e),s.d(e,{finder:()=>$});var i=s(56),n=s(39),o=s(27),a=s(169),r=s(170);o.JO.set("heart",a+""),o.JO.set("home",r+"");var h=s(4),l=s(47),c=s(36),d=s(59),u=s(10);let m=class extends o.u1{constructor(t,e){super(t),this.item=d.Z.create(e),t.e.on(this.container,"click contextmenu dblclick",(e=>(t.e.fire(e.type+"Item.filebrowser",this.item,(0,u.ctrlKey)(e)||e.shiftKey,e),!1)))}className(){return"UIBrowserItem"}render(){return"<div tabindex='-1'>\n\t\t\t<div class='&__image'></div>\n\t\t\t<div class='&__info'></div>\n\t\t\t<div class='&__heart'>*heart*</div>\n\t\t</div>"}onClickFavorite(){return this.bubble((t=>{this.jodit.e.fire(t,"toggleFavoriteItem",this.item)})),!1}onAction(t){return this.jodit.e.fire(t.type+"Item.filebrowser",this.item,(0,u.ctrlKey)(t)||t.shiftKey,t),!1}update(){var t;(0,u.css)(this.getElm("image"),"backgroundImage",`url(${this.item.imageURL})`),this.setMod("is-file",!1===this.item.isImage).setMod("type",null!==(t=this.item.type)&&void 0!==t?t:"file").setElementValue("name",this.item.file).setElementValue("time",this.item.time).setElementValue("filesize",this.item.size),(0,u.attr)(this.container,"title",`${this.item.file} ${this.item.time} ${this.item.size}`),super.update()}setElementValue(t,e){const s=this.getFullElName(t);let i=this.getElm(t);if(!e)return i&&h.Dom.safeRemove(i),this;if(!i){const t=this.getElm("info");i=this.j.create.div(s),t.appendChild(i)}return i.innerText=e,this}};(0,n.gn)([(0,c.watch)("heart:click")],m.prototype,"onClickFavorite",null),(0,n.gn)([(0,c.watch)(["container:click","container:contextmenu","container:dblclick"])],m.prototype,"onAction",null),m=(0,n.gn)([c.component],m);var g,p=s(16);let v=g=class extends o.qe{constructor(t,e){super(t),this.stateManager=e,this.syncMod=!0,this.addItemsSelector()}className(){return"UIVirtualScroll"}render(){return"<div>\n\t\t\t\t<div class=\"&__empty-message\">~There are no files~</div>\n\t\t\t\t<div class='&__loader'></div>\n\t\t\t\t<div class='&__drag-area'>~Drop image~</div>\n\t\t\t</div>"}build(t){const e=this.elements.findIndex(((e,s)=>!t[s]||e.item.uniqueHashKey!==d.Z.create(t[s]).uniqueHashKey));if(e>-1){for(let t=e;this.elements.length>t;t+=1)this.elements[t].destruct();this.elements.length=e}t.slice(e>-1?e:this.elements.length).forEach((t=>{const e=new m(this.jodit,t);Object.keys(this.mods).forEach((t=>{e.setMod(t,this.mods[t])})),this.append(e)})),this.setMod("empty",!this.elements.length)}onScrollLoadChunk(){!this.stateManager.isFavoriteItems&&this.j.o.pixelOffsetLoadNewChunk>this.container.scrollHeight-(this.container.scrollTop+this.container.offsetHeight)&&this.j.loadItemsChunk()}onDragOver(t){t.preventDefault(),this.setMod("dragover",!0)}onDragLeave(t){t.preventDefault(),this.setMod("dragover",!1)}addItemsSelector(){(class{static remove(t){p.i.safeRemove(t.container.querySelector(".jodit-ui-select-items")),t.j.e.off(t.container,"mousedown.uiselectitems touchstart.uiselectitems")}static install(t){const e=t.j.c.div("jodit-ui-select-items");t.j.e.on(t.container,"mousedown.uiselectitems touchstart.uiselectitems",this.onStartSelect.bind(this,t,e))}static onStartSelect(t,e,s){if(s.target!==t.container)return;(0,u.css)(e,{width:0,height:0}),t.container.appendChild(e);const i={x:s.clientX,y:s.clientY,w:t.container.offsetWidth,h:t.container.offsetHeight},n=t.j.async.throttle(this.onSelect.bind(this,t,e,i),t.j.defaultTimeout/10);t.j.lock(),t.j.e.on(t.j.ow,"mousemove touchmove",n).one(t.j.ow,"mouseup touchend",this.onEndSelect.bind(this,t,e,n)),t.onSelectItems({left:i.x,top:i.y,width:0,height:0})}static onSelect(t,e,s,i){const n={left:s.x>i.clientX?i.clientX:s.x,top:s.y>i.clientY?i.clientY:s.y,width:Math.abs(s.x-i.clientX),height:Math.abs(s.y-i.clientY)};(0,u.css)(e,n),t.onSelectItems(n)}static onEndSelect(t,e,s,i){p.i.safeRemove(e),t.j.e.off(t.j.ow,"mousemove touchmove",s),t.j.unlock()}}).install(this)}static intersectRect(t,e){return!(e.left>t.left+t.width||t.left>e.left+e.width||e.top>t.top+t.height||t.top>e.top+e.height)}onSelectItems(t){const e=[];this.elements.forEach((s=>{const i=(0,u.position)(s.container);g.intersectRect(i,t)&&e.push(s.item)})),this.stateManager.state.activeElements=e}};(0,n.gn)([(0,c.watch)(":afterResize"),(0,c.watch)(":resize"),(0,c.watch)("container:scroll"),(0,c.throttle)()],v.prototype,"onScrollLoadChunk",null),(0,n.gn)([(0,c.watch)("container:dragover")],v.prototype,"onDragOver",null),(0,n.gn)([(0,c.watch)(["container:dragleave","container:drop"])],v.prototype,"onDragLeave",null),v=g=(0,n.gn)([c.component],v);let f=class extends o.u1{className(){return"UIBrowserMessage"}constructor(t,e){super(t),this.container.innerText=(0,u.isString)(e)?e:e.message}};f=(0,n.gn)([c.component],f);let w=class extends o.qe{className(){return"UIBrowserMessages"}build(t){this.clear(),t.forEach((t=>{const e=new f(this.jodit,t.message);e.setMod("type",t.type),this.append(e)}))}};w=(0,n.gn)([c.component],w);class y{static remove(t){(0,u.css)(t.container,{width:null,height:null}),t.container.classList.remove("jodit-ui-resize"),p.i.safeRemove(t.container.querySelector(".jodit-ui-resize__handle"))}static install(t,e){t.container.classList.add("jodit-ui-resize"),"static"===(0,u.css)(t.container,"position")&&(0,u.css)(t.container,"position","relative");const s=t.j.c.div("jodit-ui-resize__handle");s.classList.add("jodit-ui-resize__handle_type_"+e),t.container.appendChild(s),t.j.e.on(s,"mousedown touchstart",this.onStartResize.bind(this,t,e))}static onStartResize(t,e,s){const i=t.j.async.throttle(this.onResize.bind(this,t,{x:s.clientX,y:s.clientY,w:t.container.offsetWidth,h:t.container.offsetHeight,direction:e}),t.j.defaultTimeout/10);t.j.lock(),t.j.e.on(t.j.ow,"mousemove touchmove",i).one(t.j.ow,"mouseup touchend",this.onEndResize.bind(this,t,i))}static onResize(t,e,s){const i=["left","right"].includes(e.direction),n=t.container.parentElement;if(!n)return;let o=0;o=i?(e.w+(s.clientX-e.x)*("right"===e.direction?1:-1))/n.offsetWidth:(e.h+(s.clientY-e.y)*("top"===e.direction?1:-1))/n.offsetHeight,(0,u.css)(t.container,i?"width":"height",100*o+"%")}static onEndResize(t,e,s){t.j.e.off(t.j.ow,"mousemove touchmove",e),t.j.unlock()}}let b=class extends o.qe{constructor(t,e,s){super(t,e),this.state=s,this.onChangeFavorites()}className(){return"UISidebar"}render(){return"<div>\n\t\t\t<div class='&__hide-btn'>*angle-left*</div>\n\t\t\t<div class='&__favorites'>*heart* ~Favorites~</div>\n\t\t\t<div class='&__box'></div>\n\t\t</div>"}appendChildToContainer(t){this.getElm("box").appendChild(t)}addResize(){y.remove(this),y.install(this,screen.width>450?"right":"bottom")}onChangeFavorites(){this.setMod("has-favorites",!!this.state.favorites.length)}onClickHideButton(){return this.state.showSideBar=!this.state.showSideBar,!1}onClickFavorites(){return this.state.elements=this.state.favorites,!1}};(0,n.gn)([(0,c.hook)("ready"),(0,c.watch)(":resize",window),(0,c.debounce)()],b.prototype,"addResize",null),(0,n.gn)([(0,c.watch)("state.favorites")],b.prototype,"onChangeFavorites",null),(0,n.gn)([(0,c.watch)("hide-btn:click")],b.prototype,"onClickHideButton",null),(0,n.gn)([(0,c.watch)("favorites:click")],b.prototype,"onClickFavorites",null),b=(0,n.gn)([c.component],b);let C=class extends o.qe{constructor(t,e){super(t),this.state=e,t.e.on(this.getElm("close"),"click",(()=>{this.state.showSettings=!1}))}className(){return"UIBrowserSettings"}render(){return`<div>\n\t\t\t<div class="${this.getFullElName("close")}">${o.JO.get("cancel")}</div>\n\t\t\t<div class="${this.getFullElName("title")}">${this.j.i18n("Settings")}</div>\n\t\t\t<div class="${this.getFullElName("options")}"></div>\n\t\t</div>`}appendChildToContainer(t){this.getElm("options").appendChild(t)}setMod(t,e){return"hidden"===t&&!1===e&&this.generateSettings(),super.setMod(t,e)}onChangeView(){const t=this.getElm("tile-size");t&&(t.style.display="tiles"===this.state.view?"block":"none")}generateSettings(){this.clear();const{j:t}=this;this.append([new o.BO(t,{label:"Theme",name:"theme",value:this.state.theme,radio:!0,options:[{value:"default",text:"Light"},{value:"dark",text:"Dark"}],onChange:t=>{this.state.theme=t[0].value}}),new o.BO(t,{label:"Show favorites",name:"showFavorites",value:this.state.showFavorites,radio:!0,options:[{value:!0,text:"Show"},{value:!1,text:"Hide"}],onChange:t=>{this.state.showFavorites=t[0].value}}),new o.BO(t,{label:"View",name:"view",value:this.state.view,radio:!0,options:[{value:"tiles",text:"Tiles"},{value:"list",text:"List"},{value:"compact",text:"Compact"}],onChange:t=>{this.state.view=t[0].value}}),new o.BO(t,{label:"Folders position",name:"foldersPosition",value:this.state.foldersPosition,radio:!0,options:[{value:"top",text:"Top"},{value:"bottom",text:"Bottom"},{value:"default",text:"Default"}],onChange:t=>{this.state.foldersPosition=t[0].value}}),new o.Cj(t,{label:"Sort by",name:"sort-by",value:this.state.sortBy,options:[{value:"changed-asc",text:t.i18n("Sort by changed")+"(⬆)"},{value:"changed-desc",text:t.i18n("Sort by changed")+"(⬇)"},{value:"name-asc",text:t.i18n("Sort by name")+"(⬆)"},{value:"name-desc",text:t.i18n("Sort by name")+"(⬇)"},{value:"size-asc",text:t.i18n("Sort by size")+"(⬆)"},{value:"size-desc",text:t.i18n("Sort by size")+"(⬇)"}],onChange:t=>{this.state.sortBy=t}}),new o.Cj(t,{label:"Tile size",name:"tile-size",value:this.state.tileSize,options:[{value:"xsmall",text:"Extra small"},{value:"small",text:"Small"},{value:"default",text:"Default"},{value:"large",text:"Large"},{value:"xlarge",text:"Extra large"}],onChange:t=>{this.state.tileSize=t}})]),this.onChangeView()}};(0,n.gn)([(0,c.watch)("state.view")],C.prototype,"onChangeView",null),C=(0,n.gn)([c.component],C);let S=class extends o.u1{constructor(t,e){super(t),this.item=e,this.syncMod=!0,this.getElm("name").innerText=e.name,t.e.on(this.container,"click",(()=>(this.getMod("active")||this.setMod("loading",!0),t.e.fire("openFolder",e)))).on(this.container,"contextmenu",(s=>t.e.fire("contextmenuFolder.filebrowser",e,s)))}className(){return"UIBrowserFolder"}render(){return'<div>\n\t\t\t<div class="&__icon">\n\t\t\t\t<div class=\'&__loader\'></div>\n\t\t\t\t<div class="&__icon-wrapper">\n\t\t\t\t\t*folder*\n\t\t\t\t</div>\n\t\t\t</div>\n\t\t\t<div class="&__name"></div>\n\t\t\t<div class="&__arrow">*angle-right*</div>\n\t\t</div>'}};var x;S=(0,n.gn)([c.component],S);let I=x=class extends o.qe{constructor(t,e){super(t),this.syncMod=!0,this.build(e)}className(){return"UITree"}build(t){this.clear(),t.forEach((t=>{const e=new S(this.jodit,t);this.append(e),t.isActive&&e.setMod("active",!0),t.children.length&&this.append(new x(this.jodit,t.children))}))}};I=x=(0,n.gn)([c.component],I);let M=class extends o.u1{constructor(t,e){super(t,e),this.data=e,this.tree=new I(this.j,this.data.children),this.syncMod=!0,this.getElm("name").innerText=e.title||e.name,this.getElm("tree").appendChild(this.tree.container),t.e.on(this.container,"contextmenu",(s=>t.e.fire("contextmenuSource.filebrowser",e,s)))}className(){return"UIBrowserSource"}render(){return'<div>\n\t\t\t<div class="&__name"></div>\n\t\t\t<div class="&__tree"></div>\n\t\t</div>'}};M=(0,n.gn)([c.component],M);let P=class extends o.qe{constructor(){super(...arguments),this.syncMod=!0}className(){return"UIBrowserSources"}build(t){this.clear(),t.forEach((t=>{this.append(new M(this.jodit,t))}))}};P=(0,n.gn)([c.component],P);let F=class extends o.u1{className(){return"UIBrowserStatusBar"}render(){return"<div>\n\t\t\t<div class='&__slot-left'></div>\n\t\t\t<div class='&__slot-center'></div>\n\t\t\t<div class='&__slot-right'></div>\n\t\t</div>"}value(t,e="left"){return this.getElm("slot-"+e).innerText=t,this}};F=(0,n.gn)([c.component],F);let E=class extends o.qe{constructor(t,e){super(t),this.state=e,this.lastLoadPromise=null,this.onChangeMetaInfo()}className(){return"UIPreview"}addResize(){y.remove(this),y.install(this,screen.width>450?"left":"top")}render(){return'<div>\n\t\t\t\t<div class="&__image"></div>\n\t\t\t\t<div class="&__info"></div>\n\t\t\t\t<div class="&__loader"></div>\n\t\t\t\t<div class="&__empty-message">~Select image~</div>\n\t\t\t</div>'}setMod(t,e){return super.setMod(t,e),"hidden"===t&&!1===e&&this.onChangeMetaInfo(),this}onChangeMetaInfo(){var t,e;if(this.getMod("hidden"))return;const{metaInfo:s}=this.state;this.setMod("empty",!s),p.i.detach(this.getElm("info")),(0,u.css)(this.getElm("image"),{backgroundImage:null}),s&&(this.setMod("is-file",!1===s.isImage).setMod("type",null!==(t=s.type)&&void 0!==t?t:"file"),m.prototype.setElementValue.call(this,"name",s.file),m.prototype.setElementValue.call(this,"time",s.time),m.prototype.setElementValue.call(this,"filesize",s.size),this.setMod("loading",!0),null===(e=this.lastLoadPromise)||void 0===e||e.rejectCallback(),this.lastLoadPromise=(0,u.loadImage)(s.isImage?s.fileURL:s.imageURL,this.j),this.lastLoadPromise.then((t=>{t&&(0,u.css)(this.getElm("image"),{backgroundImage:`url(${t.src})`})})).finally((()=>{this.setMod("loading",!1)})).catch((()=>{})))}};(0,n.gn)([(0,c.hook)("ready"),(0,c.watch)(":resize",window),(0,c.debounce)()],E.prototype,"addResize",null),(0,n.gn)([(0,c.watch)("state.metaInfo")],E.prototype,"onChangeMetaInfo",null),E=(0,n.gn)([c.component],E);let j=class extends o.qe{constructor(t,e){super(t),this.stateManager=e,this.syncMod=!0,this.sources=new P(this.j),this.sidebar=new b(this.jodit,[this.sources],this.stateManager.state),this.preview=new E(this.jodit,this.stateManager.state),this.statusbar=new F(this.j),this.items=new v(this.j,this.stateManager),this.settings=new C(this.jodit,this.stateManager.state),this.messages=new w(this.j),this.state=e.state,this.append(this.sidebar,"content"),this.append(this.items,"content"),this.append(this.messages,"footer"),this.append(this.settings,"content"),this.append(this.preview,"content"),this.append(this.statusbar,"footer"),this.onChangeElements(),this.onChangeSources(),this.onChangeView(),this.onChangeTileSize(),this.onChangeShowFavorites(),this.onChangeMessages(),this.onChangeActiveElements(),this.onChangeFavorites(),this.onChangeShowSideBar(),this.onChangeShowSettings(),this.onChangeShowPreview(),this.onChangeTheme()}className(){return"UIBrowserPanel"}get countInRow(){if("list"===this.state.view)return 1;const{container:t}=this.items.elements[0],e=(0,u.css)(t,"marginLeft");return Math.floor(this.items.container.offsetWidth/(t.offsetWidth+((0,u.isNumber)(e)?e:0)))}get countInColumn(){const{container:t}=this.items.elements[0],e=(0,u.css)(t,"marginTop");return Math.floor(this.items.container.offsetHeight/(t.offsetHeight+((0,u.isNumber)(e)?e:0)))}render(){return"<div>\n\t\t\t<div class='&__content'></div>\n\t\t\t<div class='&__footer'></div>\n\t\t</div>"}onChangeTheme(){this.setMod("theme",this.stateManager.state.theme)}onChangeElements(){this.items.build(this.stateManager.state.elements)}onChangeActiveElements(){this.state.activeElements.length||(this.state.info="",this.state.metaInfo=null),this.items.elements.forEach((t=>{t.setMod("active",!!this.stateManager.isActive(t.item))})),this.j.e.fire("changeSelection")}onChangeFavorites(){this.items.elements.forEach((t=>{t.setMod("favorite",!!this.stateManager.isFavorite(t.item))}))}onChangeSources(){this.sources.build(this.stateManager.state.tree)}onChangeLastSelectedIndex(){var t;const e=null===(t=this.items.elements[this.stateManager.state.lastSelectedIndex])||void 0===t?void 0:t.container;e&&((0,u.scrollIntoViewIfNeeded)(e,this.items.container,this.j.od),e.focus())}onChangeInfo(){this.statusbar.value(this.state.info,"center")}onChangePathOrSource(){this.statusbar.value(this.state.currentPath?`${this.state.currentPath} (${this.state.currentSource})`:this.i18n("Home"),"left")}onChangeShowSettings(){this.settings.setMod("hidden",!this.stateManager.state.showSettings)}onChangeShowPreview(){this.preview.setMod("hidden",!this.stateManager.state.showPreview)}onChangeShowSideBar(){this.sidebar.setMod("hidden",!this.stateManager.state.showSideBar)}onChangeView(){this.items.setMod("view",this.stateManager.state.view)}onChangeTileSize(){this.items.setMod("size",this.stateManager.state.tileSize)}onChangeShowFavorites(){this.sidebar.setMod("show-favorites",this.stateManager.state.showFavorites),this.items.setMod("show-favorites",this.stateManager.state.showFavorites)}onChangeMessages(){this.messages.build(this.stateManager.state.messages)}onItemDblClick(){return this.j.e.fire("select.filebrowser"),!1}onItemClick(t,e){this.stateManager.addActive(t,e)}onTogglePreview(){return this.state.showPreview=!this.state.showPreview,!1}onToggleFavoriteItem(t){this.stateManager.toggleFavorite(t)}onFolderClick(t){this.stateManager.state.currentSource=t.sourceName,this.stateManager.state.currentPath=t.path||"/"}};(0,n.gn)([(0,c.watch)("state.theme")],j.prototype,"onChangeTheme",null),(0,n.gn)([(0,c.watch)("state.elements")],j.prototype,"onChangeElements",null),(0,n.gn)([(0,c.watch)("state.activeElements")],j.prototype,"onChangeActiveElements",null),(0,n.gn)([(0,c.watch)(["state.favorites","state.elements"])],j.prototype,"onChangeFavorites",null),(0,n.gn)([(0,c.watch)("state.sources")],j.prototype,"onChangeSources",null),(0,n.gn)([(0,c.watch)("state.lastSelectedIndex")],j.prototype,"onChangeLastSelectedIndex",null),(0,n.gn)([(0,c.watch)("state.info")],j.prototype,"onChangeInfo",null),(0,n.gn)([(0,c.watch)(["state.currentPath","state.currentSource"])],j.prototype,"onChangePathOrSource",null),(0,n.gn)([(0,c.watch)("state.showSettings")],j.prototype,"onChangeShowSettings",null),(0,n.gn)([(0,c.watch)("state.showPreview")],j.prototype,"onChangeShowPreview",null),(0,n.gn)([(0,c.watch)("state.showSideBar")],j.prototype,"onChangeShowSideBar",null),(0,n.gn)([(0,c.watch)("state.view")],j.prototype,"onChangeView",null),(0,n.gn)([(0,c.watch)("state.tileSize")],j.prototype,"onChangeTileSize",null),(0,n.gn)([(0,c.watch)("state.showFavorites")],j.prototype,"onChangeShowFavorites",null),(0,n.gn)([(0,c.watch)("state.messages")],j.prototype,"onChangeMessages",null),(0,n.gn)([(0,c.watch)(":dblclickItem.filebrowser")],j.prototype,"onItemDblClick",null),(0,n.gn)([(0,c.watch)(":clickItem.filebrowser")],j.prototype,"onItemClick",null),(0,n.gn)([(0,c.watch)(":togglePreview.filebrowser")],j.prototype,"onTogglePreview",null),(0,n.gn)([(0,c.watch)(":toggleFavoriteItem")],j.prototype,"onToggleFavoriteItem",null),(0,n.gn)([(0,c.watch)(":openFolder")],j.prototype,"onFolderClick",null),j=(0,n.gn)([c.component],j);var _=s(3);class k{constructor(t){this.state=t}getIndex(t,e=this.state.elements){return e.findIndex((e=>e.uniqueHashKey===t.uniqueHashKey))}isActive(t){return!!this.state.activeElements.find((e=>e.uniqueHashKey===t.uniqueHashKey))}isFavorite(t){return!!this.state.favorites.find((e=>e.uniqueHashKey===t.uniqueHashKey))}addActive(t,e){var s;this.state.metaInfo=t,this.state.info=null!==(s=t.file)&&void 0!==s?s:"",this.state.lastSelectedIndex=this.getIndex(t),this.state.activeElements=e?[...this.state.activeElements,t]:[t]}callSelectHandler(){var t;const e=this.state.activeElements;null===(t=this.state.onSelectCallBack)||void 0===t||t.call(this,{baseurl:"",files:e.map((t=>t.fileURL)),isImages:e.map((t=>!!t.isImage))})}setFilter(t){this.state.filterWord=t}addMessage(t){var e;const s=this.state.messages;(null===(e=s[s.length-1])||void 0===e?void 0:e.message)!==t.message&&(this.state.messages=[...s,t])}removeMessage(t){const e=this.state.messages.indexOf(t);if(-1!==e){const t=[...this.state.messages];t.splice(e,1),this.state.messages=t}}toggleFavorite(t){const e=this.getIndex(t,this.state.favorites),s=[...this.state.favorites];-1===e?s.push(t):s.splice(e,1),this.state.favorites=s}fillSources(t,e){const s=t=>t.filter((t=>"."!==t&&".."!==t));if(this.state.tree.length&&e){const i=(t,e)=>{var s;return null!==(s=t.find((t=>t.name===e)))&&void 0!==s?s:null};this.removeActive(this.state.tree),t.forEach((t=>{const n=i(this.state.tree,t.name);if(n){n.isActive=!0;const o=e.split("/").reduce(((t,e)=>t&&i(t.children,e)),n);o&&(o.isActive=!0,o.children=s(t.folders).map((s=>({type:"directory",name:s,path:e+"/"+s,sourceName:t.name,children:[]}))))}}))}else this.state.tree=t.map((t=>({type:"source",name:t.name,title:t.title,sourceName:t.name,path:"/",children:s(t.folders).map((e=>({type:"directory",name:e,path:e,sourceName:t.name,children:[]})))})))}removeActive(t){t.forEach((t=>{t.isActive=!1,this.removeActive(t.children)}))}get isFavoriteItems(){return this.state.favorites===this.state.elements}}(0,n.gn)([c.autobind],k.prototype,"getIndex",null),(0,n.gn)([c.autobind],k.prototype,"isActive",null),(0,n.gn)([c.autobind],k.prototype,"isFavorite",null);var R=s(51);let B=class extends o.qe{constructor(t,e,s){var i;super(t),this.options=e,this.stateManager=s,this.syncMod=!0,this.toolbar=(0,R.R)(this.j),this.filter=new o.u3(this.j,{icon:"search",placeholder:"Filter",clearButton:!0,onChange:t=>{this.stateManager.setFilter(t)}}),this.append(this.toolbar).append(this.filter),this.filter.container.classList.add(this.getFullElName("filter")),this.toolbar.setMod("mode","header").build(null!==(i=this.options.toolbarButtons)&&void 0!==i?i:[])}className(){return"UIBrowserHeader"}};B=(0,n.gn)([c.component],B);var L=s(60),z=s(2);let N=class extends o.ko{constructor(t,e){super(t),this.state=e,this.onProgress()}className(){return"UIProgress"}onProgress(){this.state.progress?this.show():this.hide(),this.progress(this.state.progress)}hide(){return this.setMod("hidden",!0),this}progress(t){return this.container.style.width=t.toFixed(2)+"%",98>t||this.j.async.setTimeout((()=>{this.hide()}),{label:"progress",timeout:300}),this}show(){return this.setMod("hidden",!1),this}};(0,n.gn)([(0,c.watch)("state.progress")],N.prototype,"onProgress",null),N=(0,n.gn)([c.component],N);var T=s(57),H=s(13);let O=class extends H.Hr{constructor(t,e){super(t),this.state=e,this.sortBy="changed-desc",this.view="tiles",this.foldersPosition="top",this.tileSize="default",this.favorites=[],this.showSideBar=!0,this.showPreview=!1,this.showFavorites=!0}className(){return"PersistentStore"}onChangeThemeSetField(){this.theme=this.state.theme}onChangeView(){this.view=this.state.view}onChangeSortBy(){this.sortBy=this.state.sortBy}onChangeTileSize(){this.tileSize=this.state.tileSize}onChangeFavorites(){this.favorites=this.state.favorites}onChangeShowSideBar(){this.showSideBar=this.state.showSideBar}onChangeShowPreview(){this.showPreview=this.state.showPreview}onChangeShowFavorites(){this.showFavorites=this.state.showFavorites}onChangeFoldersPosition(){this.foldersPosition=this.state.foldersPosition}syncWithState(){this.state.tileSize=this.tileSize,this.state.favorites=this.favorites.map((t=>t instanceof d.Z?t:d.Z.create(t))),this.state.view=this.view,this.state.theme=this.theme,this.state.showSideBar=this.showSideBar,this.state.showPreview=this.showPreview,this.state.showFavorites=this.showFavorites,this.state.sortBy=this.sortBy,this.state.foldersPosition=this.foldersPosition}};(0,n.gn)([c.persistent],O.prototype,"theme",void 0),(0,n.gn)([c.persistent],O.prototype,"sortBy",void 0),(0,n.gn)([c.persistent],O.prototype,"view",void 0),(0,n.gn)([c.persistent],O.prototype,"foldersPosition",void 0),(0,n.gn)([c.persistent],O.prototype,"tileSize",void 0),(0,n.gn)([c.persistent],O.prototype,"favorites",void 0),(0,n.gn)([c.persistent],O.prototype,"showSideBar",void 0),(0,n.gn)([c.persistent],O.prototype,"showPreview",void 0),(0,n.gn)([c.persistent],O.prototype,"showFavorites",void 0),(0,n.gn)([(0,c.watch)("state.theme")],O.prototype,"onChangeThemeSetField",null),(0,n.gn)([(0,c.watch)("state.view")],O.prototype,"onChangeView",null),(0,n.gn)([(0,c.watch)("state.sortBy")],O.prototype,"onChangeSortBy",null),(0,n.gn)([(0,c.watch)("state.tileSize")],O.prototype,"onChangeTileSize",null),(0,n.gn)([(0,c.watch)("state.favorites")],O.prototype,"onChangeFavorites",null),(0,n.gn)([(0,c.watch)("state.showSideBar")],O.prototype,"onChangeShowSideBar",null),(0,n.gn)([(0,c.watch)("state.showPreview")],O.prototype,"onChangeShowPreview",null),(0,n.gn)([(0,c.watch)("state.showFavorites")],O.prototype,"onChangeShowFavorites",null),(0,n.gn)([(0,c.watch)("state.foldersPosition")],O.prototype,"onChangeFoldersPosition",null),O=(0,n.gn)([c.component],O);let U=class extends H.Hr{constructor(t,e){super(t),this.state=e}className(){return"HistoryManager"}updateHistory(){this.state.history[this.state.historyIndex]={currentSource:this.state.currentSource,currentPath:this.state.currentPath,tree:(0,u.fastClone)(this.state.tree),elements:this.state.elements}}updateState(){const{tree:t,elements:e,currentSource:s,currentPath:i}=this.state.history[this.state.historyIndex];this.state.elements=e,this.state.tree=t,this.state.currentSource=s,this.state.currentPath=i,this.j.e.fire("changeSelection")}push(){let t=[...this.state.history],{historyIndex:e}=this.state;const s=t[e];s&&s.currentSource===this.state.currentSource&&s.currentPath===this.state.currentPath||(t.length-1!==e&&(t=t.slice(0,e)),t.push({tree:[],elements:[],currentPath:this.state.currentPath,currentSource:this.state.currentSource}),s&&(e+=1),this.state.historyIndex=e,this.state.history=t,this.updateHistory(),this.j.e.fire("changeSelection"))}onNext(){this.state.history.length-1>this.state.historyIndex&&(this.state.historyIndex+=1,this.updateState())}onPrevious(){this.state.historyIndex>0&&(this.state.historyIndex-=1,this.updateState())}onHome(){this.state.currentSource="",this.state.currentPath="",this.j.e.fire("update.filebrowser")}};(0,n.gn)([(0,c.watch)(":next.filebrowser")],U.prototype,"onNext",null),(0,n.gn)([(0,c.watch)(":previous.filebrowser")],U.prototype,"onPrevious",null),(0,n.gn)([(0,c.watch)(":goHome.filebrowser")],U.prototype,"onHome",null),U=(0,n.gn)([c.component],U);let D=class extends H.Hr{className(){return"ContextMenuManager"}onFolderContext(t,e){return this.buildContextItemMenu(this.getFolderContextActions(t),e),!1}onItemContext(t,e,s){return this.buildContextItemMenu(this.getItemContextActions(t),s),!1}onSourceContext(t,e){return this.buildContextItemMenu(this.getSourceContextActions(t),e),!1}buildContextItemMenu(t,e){if(!this.j.o.contextMenu)return;const s=(0,T.L)(this.j).setMod("theme",this.j.state.theme);s.show(e.clientX,e.clientY,t.filter((t=>t&&!1!==t.enabled))),this.j.e.on(this.j,"afterClose",(()=>{s.isOpened&&s.close()}))}getItemContextActions(t){if(this.j.stateManager.isActive(t)||this.j.stateManager.addActive(t,this.j.state.activeElements.length>1),"folder"===t.type)return this.getFolderContextActions({type:"directory",children:[],name:t.name||"",path:t.path,sourceName:t.sourceName});const e=this.j.options,s=this.j.dataProvider,i=1===this.j.state.activeElements.length;return[{icon:"pencil",title:"Edit",enabled:!!t.isImage&&e.editImage&&i&&(s.canI("ImageResize")||s.canI("ImageCrop")),exec:()=>{L.r.call(this.j,t.imageURL,t.name||"",this.j.state.currentPath,this.j.state.currentSource)}},{icon:"italic",title:"Rename",enabled:s.canI("FileRename")&&i,exec:()=>this.j.e.fire("fileRename.filebrowser",t)},{icon:"bin",title:"Delete",enabled:s.canI("FileRemove"),exec:()=>this.j.e.fire("fileRemove.filebrowser",t)},{icon:"eye",title:"Preview",enabled:!!t.isImage&&e.preview&&i,exec:()=>this.j.e.fire("openLightBox.filebrowser",t)},{icon:"upload",title:"Download",exec:()=>{t.fileURL&&this.j.ow.open(t.fileURL)}}]}getFolderContextActions(t){const e=this.j.dataProvider;return[{icon:"pencil",title:"Rename",exec:()=>{this.j.e.fire("folderRename.filebrowser",t)},enabled:e.canI("FolderRename")},{icon:"bin",title:"Delete",exec:()=>{this.j.e.fire("folderRemove.filebrowser",t)},enabled:e.canI("FolderRemove")},{icon:"plus",title:"Add folder",exec:()=>{this.j.e.fire("folderCreate.filebrowser",t)},enabled:e.canI("FolderCreate")}]}getSourceContextActions(t){return[{icon:"plus",title:"Create folder",exec:()=>{this.j.e.fire("folderCreate.filebrowser",t)}}]}};(0,n.gn)([(0,c.watch)(":contextmenuFolder.filebrowser")],D.prototype,"onFolderContext",null),(0,n.gn)([(0,c.watch)(":contextmenuItem.filebrowser")],D.prototype,"onItemContext",null),(0,n.gn)([(0,c.watch)(":contextmenuSource.filebrowser")],D.prototype,"onSourceContext",null),D=(0,n.gn)([c.component],D);const K=t=>{const e=t.split("/").filter((t=>t.length));return e.pop(),e.join("/")||"/"};var A,V=s(1),q=s(167);let W=A=class extends h.UIElement{constructor(t,e,s){super(t),this.current=e,this.elements=s,this.dialog=new h.Dialog;const{dialog:i}=this;i.setMod("theme",t.state.theme).toolbar.setMod("mode","header"),i.open(this),this.elements=this.elements.filter((t=>t.isImage)),i.e.on(i,"afterClose",(()=>{this.destruct()})),this.addGlobalListeners(),this.onChangeCurrent(),i.toolbar.build([{icon:"check",exec:()=>{t.stateManager.addActive(this.current,!1),t.e.fire("select.filebrowser"),i.close()}},"dialog.close"])}className(){return"UILightBox"}render(){return"<div>\n\t\t\t<div class='&__previous'>*angle-left*</div>\n\t\t\t<div class='&__preview'></div>\n\t\t\t<div class='&__loader'></div>\n\t\t\t<div class='&__next'>*angle-right*</div>\n\t\t</div>"}async onChangeCurrent(){const{current:t}=this;this.setMod("loading",!0);const e=this.getElm("preview");if(h.Dom.detach(e),(0,u.css)(e,{backgroundImage:null}),t.isImage){const s=await(0,u.loadImage)(t.fileURL,this.j);this.dialog.setPosition(),(0,u.css)(e,{width:Math.min(this.jodit.ow.innerWidth,s.naturalWidth),height:Math.min(this.jodit.ow.innerHeight-100,s.naturalHeight),backgroundImage:`url(${s.src})`})}else{const s=await this.makeIframe(t.fileURL);e.appendChild(s)}this.dialog.setSize(),this.dialog.setPosition(),this.setMod("loading",!1)}makeIframe(t){const e=this.j.c.element("iframe");return e.classList.add(this.getFullElName("office-iframe")),e.src=/\.pdf/.test(t)?t:this.j.o.previewOfficeURL+encodeURIComponent(t),e}onPreviousClick(){const{current:t}=this;let e=this.j.stateManager.getIndex(t,this.elements);e>0?e-=1:e=this.elements.length-1,this.current=this.elements[e]}onNextClick(){const{current:t}=this;let e=this.j.stateManager.getIndex(t,this.elements);this.elements.length-1>e?e+=1:e=0,this.current=this.elements[e]}static open(t,e,s){return new A(t,e,s)}addGlobalListeners(){this.j.e.on(this.j.od,"keydown",this.onKeyPress)}onKeyPress(t){if(t.key===_.KEY_LEFT||t.key===_.KEY_RIGHT||t.key===_.KEY_SPACE)return t.key===_.KEY_LEFT?this.onPreviousClick():this.onNextClick(),!1}removeGlobalListeners(){this.j.e.off(this.j.od,"keydown",this.onKeyPress)}destruct(){return this.removeGlobalListeners(),this.dialog.destruct(),super.destruct()}};(0,n.gn)([(0,c.watch)("current")],W.prototype,"onChangeCurrent",null),(0,n.gn)([(0,c.watch)("previous:click")],W.prototype,"onPreviousClick",null),(0,n.gn)([(0,c.watch)("next:click")],W.prototype,"onNextClick",null),(0,n.gn)([c.autobind],W.prototype,"onKeyPress",null),W=A=(0,n.gn)([c.component],W);let Y=class extends l.Vq{constructor(t){super((0,u.ConfigProto)(Object.assign(t||{},{resizable:!0,draggable:!0,toolbarButtons:(null==t?void 0:t.buttons)||z.D.defaultOptions.filebrowser.buttons,buttons:V.Jodit.atom(["filebrowser.settings","fullsize","dialog.close"])}),z.D.defaultOptions.filebrowser)),this.dataProvider=(0,T.S)(this,this.options),this.state=h.ObserveObject.create({onSelectCallBack:null,theme:"default",showSideBar:!0,showFavorites:!0,showSettings:!1,showPreview:!1,withFolders:!0,foldersPosition:"bottom",info:"",metaInfo:null,currentPath:"",currentSource:"",currentBaseUrl:"",history:[],historyIndex:0,tree:[],activeElements:[],favorites:[],progress:0,lastSelectedIndex:0,elements:[],messages:[],sources:[],view:"tiles",tileSize:"default",sortBy:"name-asc",filterWord:"",onlyImages:!1},["state"]),this.persistent=new O(this,this.state),this.stateManager=new k(this.state),this.historyManager=new U(this,this.state),this.contextMenuManager=new D(this),this.header=new B(this,this.options,this.stateManager),this.panel=new j(this,this.stateManager),this.progressbar=new N(this,this.stateManager.state),this.offset=0,this.countInOneChunk=20,this.stopLoadingParts=!1,q.V.make(this),!this.persistent.theme&&this.options.theme&&(this.persistent.theme=this.options.theme),this.panel.append(this.progressbar),this.toolbar.setMod("mode","header"),this.setSize(Math.min(this.options.width,screen.width),Math.min(this.options.height,screen.height)).setHeader(this.header),this.onResizeWindow(),this.initUploader(),this.onChangeTheme(),this.fullFillOptions(),this.dataProvider.onProgress((t=>{0===t&&(t=30),this.state.progress=t})),this.e.on("beforeClose",this.removeGlobalListeners),this.e.fire("afterInit"),V.Jodit.prototype.afterInitHook.call(this)}className(){return"FileBrowserPro"}lock(t="any"){return this.container.classList.add("jodit_disabled"),super.lock(t)}unlock(){return this.container.classList.remove("jodit_disabled"),super.unlock()}status(t,e=!(t instanceof Error)){const s={message:(0,u.isString)(t)?t:t.message,type:e?"success":"error"};this.stateManager.addMessage(s),this.async.setTimeout((()=>{this.stateManager.removeMessage(s)}),this.options.howLongShowMsg)}addDisclaimer(t){this.dialog.appendChild(t)}onResizeWindow(){(0,u.css)(this.dialog,{maxWidth:screen.width,minHeight:Math.min(this.options.height,screen.height),minWidth:Math.min(this.options.width,screen.width)})}async open(t,e){return this.state.onlyImages=!!e,this.prepareOpening(t),super.open(this.panel.container),this.onUpdateFileBrowser()}onChangeTheme(){this.setMod("theme",this.state.theme),this.header.setMod("theme",this.state.theme),this.panel.setMod("theme",this.state.theme),this.options.theme=this.state.theme}onToggleSettings(){this.state.showSettings=!this.state.showSettings}async onUpdateFileBrowser(){this.state.activeElements=[],this.panel.setMod("loading",!0),await Promise.all([this.loadFolders(),this.loadItems()]),this.panel.setMod("loading",!1),this.historyManager.updateHistory()}async loadFolders(){if(!this.isOpened)return;const{currentPath:t,currentSource:e}=this.state;this.historyManager.push();try{this.uploader.setPath(t),this.uploader.setSource(e);const s=await this.dataProvider.tree(t,e);this.stateManager.fillSources(s,t),this.historyManager.updateHistory(),this.state.sources=s}catch(t){this.status(t)}}async loadItems(){if(this.isOpened)try{for(this.offset=0,this.stopLoadingParts=!1,this.state.elements=await this.loadPartItems(),this.stopLoadingParts=this.countInOneChunk>this.state.elements.length;!this.stopLoadingParts&&this.panel.countInColumn*this.panel.countInRow>=this.state.elements.length;)await this.loadItemsChunk();this.historyManager.updateHistory()}catch(t){this.status(t)}}async loadItemsChunk(){if(!this.stopLoadingParts)try{this.offset+=this.countInOneChunk;const t=await this.loadPartItems();this.stopLoadingParts=this.countInOneChunk>t.length,t.length&&(this.state.elements=this.state.elements.concat(t))}catch(t){this.status(t)}}prepareOpening(t){this.registerGlobalListeners(),t&&(this.state.onSelectCallBack=e=>{this.close(),t(e)}),this.persistent.syncWithState()}registerGlobalListeners(){this.e.on(this.ow,"keydown",this.onKeyPress)}onKeyPress(t){const{activeElement:e}=this.od;if(!this.state.activeElements.length||!e||!h.Dom.isOrContains(this.panel.items.container,e))return;const s=this.state.elements;switch(t.key){case _.KEY_ENTER:return this.onChooseItems();case _.KEY_DELETE:return this.onFileRemove();case _.KEY_RIGHT:case _.KEY_LEFT:case _.KEY_DOWN:case _.KEY_UP:{const e=t.key===_.KEY_RIGHT||t.key===_.KEY_DOWN,i=this.state.lastSelectedIndex;let n;if([_.KEY_RIGHT,_.KEY_LEFT].includes(t.key))n=e?s[i+1]?i+1:0:s[i-1]?i-1:s.length-1;else{const{countInRow:t}=this.panel;n=Math.round(((i+1)/t+(e?1:-1))*t-1)}return s[n]&&this.stateManager.addActive(s[n],t.shiftKey),!1}}}removeGlobalListeners(){this.e.off(this.ow,"keydown",this.onKeyPress)}onFileRemove(){this.state.activeElements.length&&(0,h.Confirm)(this.i18n("Are you sure?"),"",(t=>{if(t){const t=[];this.state.activeElements.forEach((e=>{this.stateManager.isFavorite(e)&&this.stateManager.toggleFavorite(e),t.push(this.deleteFile(e.file||e.name||"",e.sourceName))})),this.state.activeElements=[],Promise.all(t).then((()=>this.loadItems()))}})).bindDestruct(this)}onFileEdit(){if(1===this.state.activeElements.length){const[t]=this.state.activeElements;L.r.call(this,t.fileURL,t.file||"",t.path,t.sourceName,void 0,this.status)}}onFolderRename(t){(0,h.Prompt)(this.i18n("Enter new name"),this.i18n("Rename"),(e=>{if(!(0,u.isValidName)(e)||e===t.name)return this.status(this.i18n("Enter new name")),!1;this.dataProvider.folderRename(K(t.path),t.name,e,t.sourceName).then((s=>{this.state.activeElements=[],this.status(s,!0),this.state.currentPath=K(t.path)+"/"+e,this.state.currentSource=t.sourceName,this.loadFolders()})).catch(this.status)}),this.i18n("type name"),t.name).bindDestruct(this)}onFolderRemove(t){(0,h.Confirm)(this.i18n("Are you sure?"),this.i18n("Delete"),(e=>{e&&this.dataProvider.folderRemove(K(t.path),t.name,t.sourceName).then((e=>{this.status(e,!0),this.state.currentPath=K(t.path),this.state.currentSource=t.sourceName,this.loadFolders()})).catch(this.status)})).bindDestruct(this)}onFolderCreate(t){(0,h.Prompt)(this.i18n("Enter Directory name"),this.i18n("Create directory"),(e=>{const s=t.path||"/";this.dataProvider.createFolder(e,t.path||"/",t.sourceName).then((()=>{this.state.currentSource===t.sourceName&&this.state.currentPath===s?this.onUpdateFileBrowser():(this.state.currentSource=t.sourceName,this.state.currentPath=s)}),this.status)}),this.i18n("type name")).bindDestruct(this)}onFileRename(t){const e=t.file||t.name||"";1===this.state.activeElements.length&&e&&(0,h.Prompt)(this.i18n("Enter new name"),this.i18n("Rename"),(t=>{if(!(0,u.isValidName)(t))return this.status(this.i18n("Enter new name")),!1;this.dataProvider.fileRename(this.state.currentPath,e,t,this.state.currentSource).then((t=>{this.state.activeElements=[],this.status(t,!0),this.loadItems()})).catch(this.status)}),this.i18n("type name"),e).bindDestruct(this)}onChooseItems(){const t=this.stateManager.state.activeElements;if(t.length){if("folder"===t[0].type)return this.state.currentPath=this.state.currentPath+"/"+t[0].name,void(this.state.currentSource=t[0].sourceName);this.state.onSelectCallBack?this.stateManager.callSelectHandler():this.onOpenLightBox(t[0])}}onOpenLightBox(t){W.open(this,t,this.state.elements)}deleteFile(t,e){return this.dataProvider.fileRemove(this.state.currentPath,t,e).then((e=>{this.status(e||this.i18n('File "%s" was deleted',t),!0)})).catch(this.status)}initUploader(){const t=this,e=(0,u.ConfigProto)(t.o.uploader||{},z.D.defaultOptions.uploader),s=()=>this.loadItems();t.uploader=t.getInstance("Uploader",e),t.uploader.bind(t.panel.container,s,t.status),t.e.on("bindUploader.filebrowser",(e=>{t.uploader.bind(e,s,t.status)}))}destruct(){this.removeGlobalListeners(),this.header.destruct(),this.panel.destruct(),super.destruct()}fullFillOptions(){["getLocalFileByUrl","crop","resize","create","fileMove","folderMove","fileRename","folderRename","fileRemove","folderRemove","folder","items","permissions"].forEach((t=>{null!=this.options[t]&&(this.options[t]=(0,u.ConfigProto)(this.options[t],this.o.ajax))}))}loadPartItems(){return this.dataProvider.items(this.state.currentPath,this.state.currentSource,{offset:this.offset,limit:this.countInOneChunk,sortBy:this.state.sortBy,withFolders:this.state.withFolders,foldersPosition:this.state.foldersPosition,onlyImages:this.state.onlyImages,filterWord:this.state.filterWord})}};(0,n.gn)([c.autobind],Y.prototype,"status",null),(0,n.gn)([(0,c.watch)(":resize",window)],Y.prototype,"onResizeWindow",null),(0,n.gn)([(0,c.watch)("state.theme")],Y.prototype,"onChangeTheme",null),(0,n.gn)([(0,c.watch)(":toggleSettings.filebrowser")],Y.prototype,"onToggleSettings",null),(0,n.gn)([(0,c.watch)(":update.filebrowser")],Y.prototype,"onUpdateFileBrowser",null),(0,n.gn)([(0,c.watch)(["state.currentPath","state.currentSource"]),(0,c.debounce)((t=>({timeout:t.defaultTimeout,promisify:!0})))],Y.prototype,"loadFolders",null),(0,n.gn)([(0,c.watch)(["state.currentPath","state.currentSource","state.sortBy","state.onlyImages","state.foldersPosition","state.filterWord"]),(0,c.debounce)((t=>({timeout:t.defaultTimeout,promisify:!0})))],Y.prototype,"loadItems",null),(0,n.gn)([(0,c.debounce)((t=>({timeout:t.defaultTimeout,promisify:!0})))],Y.prototype,"loadItemsChunk",null),(0,n.gn)([c.autobind],Y.prototype,"onKeyPress",null),(0,n.gn)([c.autobind],Y.prototype,"removeGlobalListeners",null),(0,n.gn)([(0,c.watch)(":fileRemove.filebrowser")],Y.prototype,"onFileRemove",null),(0,n.gn)([(0,c.watch)(":edit.filebrowser")],Y.prototype,"onFileEdit",null),(0,n.gn)([(0,c.watch)(":folderRename.filebrowser")],Y.prototype,"onFolderRename",null),(0,n.gn)([(0,c.watch)(":folderRemove.filebrowser")],Y.prototype,"onFolderRemove",null),(0,n.gn)([(0,c.watch)(":folderCreate.filebrowser")],Y.prototype,"onFolderCreate",null),(0,n.gn)([(0,c.watch)(":fileRename.filebrowser")],Y.prototype,"onFileRename",null),(0,n.gn)([(0,c.watch)(":select.filebrowser")],Y.prototype,"onChooseItems",null),(0,n.gn)([(0,c.watch)(":openLightBox.filebrowser")],Y.prototype,"onOpenLightBox",null),Y=(0,n.gn)([c.component],Y),V.Jodit.modules.FileBrowserPro=Y,(0,s(14).xl)(s(171));const G=z.D.prototype.controls.filebrowser;G.settings={icon:"settings",exec(t){t.e.fire("toggleSettings.filebrowser")}},G.home={icon:"home",exec(t){t.e.fire("goHome.filebrowser")}},G.preview={icon:"eye",exec(t){t.e.fire("togglePreview.filebrowser")}},G.next={icon:"angle-right",isDisabled(t){if(!t.state)return!0;const{history:e,historyIndex:s}=t.state;return!e||!e.length||s===e.length-1},exec(t){t.e.fire("next.filebrowser")}},G.previous={icon:"angle-left",isDisabled(t){if(!t.state)return!0;const{history:e,historyIndex:s}=t.state;return!e||!e.length||0===s},exec(t){t.e.fire("previous.filebrowser")}},Object.assign(z.D.prototype.filebrowser,{buttons:["filebrowser.home","filebrowser.previous","filebrowser.next","|","filebrowser.upload","filebrowser.remove","filebrowser.update","filebrowser.select","filebrowser.edit","|","filebrowser.preview","about"],sort:!1,pixelOffsetLoadNewChunk:200,width:750,height:400,previewOfficeURL:"https://view.officeapps.live.com/op/view.aspx?src="});class $ extends i.S{constructor(){super(...arguments),this.requires=["license"],this.hasStyle=!V.Jodit.fatMode}afterInit(t){t.e.on("getInstanceFileBrowser",(t=>(this.__instance||(this.__instance=new Y(t)),this.__instance)))}beforeDestruct(t){var e;t.e.off("getInstanceFileBrowser"),null===(e=this.__instance)||void 0===e||e.destruct()}}V.Jodit.plugins.add("finder",$)},171(t,e,s){"use strict";s.r(e),s.d(e,{ru:()=>i});const i=s(172)},172(t){t.exports={Favorites:"Избранное",Settings:"Настройки",Light:"Светлая",Dark:"Темная",Theme:"Тема",Show:"Показать",Hide:"Скрыть","Show favorites":"Показывать избранное",Tiles:"Плитка",List:"Список",Compact:"Компактный",View:"Отображение","Folders position":"Позиция папок","Sort by":"Сортировать по","Extra small":"Очень маленькие",Small:"Маленькие",Large:"Большие","Extra large":"Очень большие","Tile size":"Размер плитки"}}},t=>{"use strict";t(t.s=168)}])}));
((t,e)=>{if("object"==typeof exports&&"object"==typeof module)module.exports=e();else if("function"==typeof define&&define.amd)define([],e);else{var s=e();for(var i in s)("object"==typeof exports?exports:t)[i]=s[i]}})(self,(function(){return(self.webpackChunkjodit_pro=self.webpackChunkjodit_pro||[]).push([[524],{169(t){t.exports='<svg viewBox="0 0 512 512" xmlns="http://www.w3.org/2000/svg"> <path d="M365.4,59.628c60.56,0,109.6,49.03,109.6,109.47c0,109.47-109.6,171.8-219.06,281.271 C146.47,340.898,37,278.568,37,169.099c0-60.44,49.04-109.47,109.47-109.47c54.73,0,82.1,27.37,109.47,82.1 C283.3,86.999,310.67,59.628,365.4,59.628z"/> </svg>'},170(t){t.exports='<svg viewBox="0 0 32 32" xmlns="http://www.w3.org/2000/svg"> <path d="M28.7,16.3l-12-13c-0.4-0.4-1.1-0.4-1.5,0l-12,13C3,16.6,2.9,17,3.1,17.4C3.2,17.8,3.6,18,4,18h3v10c0,0.6,0.4,1,1,1h16 c0.6,0,1-0.4,1-1V18h3c0.4,0,0.8-0.2,0.9-0.6C29.1,17,29,16.6,28.7,16.3z"/> </svg>'},168(t,e,s){"use strict";s.r(e),s.d(e,{finder:()=>$});var i=s(56),n=s(39),o=s(27),a=s(169),r=s(170);o.JO.set("heart",a+""),o.JO.set("home",r+"");var h=s(4),l=s(47),c=s(36),d=s(59),u=s(10);let m=class extends o.u1{constructor(t,e){super(t),this.item=d.Z.create(e),t.e.on(this.container,"click contextmenu dblclick",(e=>(t.e.fire(e.type+"Item.filebrowser",this.item,(0,u.ctrlKey)(e)||e.shiftKey,e),!1)))}className(){return"UIBrowserItem"}render(){return"<div tabindex='-1'>\n\t\t\t<div class='&__image'></div>\n\t\t\t<div class='&__info'></div>\n\t\t\t<div class='&__heart'>*heart*</div>\n\t\t</div>"}onClickFavorite(){return this.bubble((t=>{this.jodit.e.fire(t,"toggleFavoriteItem",this.item)})),!1}onAction(t){return this.jodit.e.fire(t.type+"Item.filebrowser",this.item,(0,u.ctrlKey)(t)||t.shiftKey,t),!1}update(){var t;(0,u.css)(this.getElm("image"),"backgroundImage",`url(${this.item.imageURL})`),this.setMod("is-file",!1===this.item.isImage).setMod("type",null!==(t=this.item.type)&&void 0!==t?t:"file").setElementValue("name",this.item.file).setElementValue("time",this.item.time).setElementValue("filesize",this.item.size),(0,u.attr)(this.container,"title",`${this.item.file} ${this.item.time} ${this.item.size}`),super.update()}setElementValue(t,e){const s=this.getFullElName(t);let i=this.getElm(t);if(!e)return i&&h.Dom.safeRemove(i),this;if(!i){const t=this.getElm("info");i=this.j.create.div(s),t.appendChild(i)}return i.innerText=e,this}};(0,n.gn)([(0,c.watch)("heart:click")],m.prototype,"onClickFavorite",null),(0,n.gn)([(0,c.watch)(["container:click","container:contextmenu","container:dblclick"])],m.prototype,"onAction",null),m=(0,n.gn)([c.component],m);var g,p=s(16);let v=g=class extends o.qe{constructor(t,e){super(t),this.stateManager=e,this.syncMod=!0,this.addItemsSelector()}className(){return"UIVirtualScroll"}render(){return"<div>\n\t\t\t\t<div class=\"&__empty-message\">~There are no files~</div>\n\t\t\t\t<div class='&__loader'></div>\n\t\t\t\t<div class='&__drag-area'>~Drop image~</div>\n\t\t\t</div>"}build(t){const e=this.elements.findIndex(((e,s)=>!t[s]||e.item.uniqueHashKey!==d.Z.create(t[s]).uniqueHashKey));if(e>-1){for(let t=e;this.elements.length>t;t+=1)this.elements[t].destruct();this.elements.length=e}t.slice(e>-1?e:this.elements.length).forEach((t=>{const e=new m(this.jodit,t);Object.keys(this.mods).forEach((t=>{e.setMod(t,this.mods[t])})),this.append(e)})),this.setMod("empty",!this.elements.length)}onScrollLoadChunk(){!this.stateManager.isFavoriteItems&&this.j.o.pixelOffsetLoadNewChunk>this.container.scrollHeight-(this.container.scrollTop+this.container.offsetHeight)&&this.j.loadItemsChunk()}onDragOver(t){t.preventDefault(),this.setMod("dragover",!0)}onDragLeave(t){t.preventDefault(),this.setMod("dragover",!1)}addItemsSelector(){(class{static remove(t){p.i.safeRemove(t.container.querySelector(".jodit-ui-select-items")),t.j.e.off(t.container,"mousedown.uiselectitems touchstart.uiselectitems")}static install(t){const e=t.j.c.div("jodit-ui-select-items");t.j.e.on(t.container,"mousedown.uiselectitems touchstart.uiselectitems",this.onStartSelect.bind(this,t,e))}static onStartSelect(t,e,s){if(s.target!==t.container)return;(0,u.css)(e,{width:0,height:0}),t.container.appendChild(e);const i={x:s.clientX,y:s.clientY,w:t.container.offsetWidth,h:t.container.offsetHeight},n=t.j.async.throttle(this.onSelect.bind(this,t,e,i),t.j.defaultTimeout/10);t.j.lock(),t.j.e.on(t.j.ow,"mousemove touchmove",n).one(t.j.ow,"mouseup touchend",this.onEndSelect.bind(this,t,e,n)),t.onSelectItems({left:i.x,top:i.y,width:0,height:0})}static onSelect(t,e,s,i){const n={left:s.x>i.clientX?i.clientX:s.x,top:s.y>i.clientY?i.clientY:s.y,width:Math.abs(s.x-i.clientX),height:Math.abs(s.y-i.clientY)};(0,u.css)(e,n),t.onSelectItems(n)}static onEndSelect(t,e,s,i){p.i.safeRemove(e),t.j.e.off(t.j.ow,"mousemove touchmove",s),t.j.unlock()}}).install(this)}static intersectRect(t,e){return!(e.left>t.left+t.width||t.left>e.left+e.width||e.top>t.top+t.height||t.top>e.top+e.height)}onSelectItems(t){const e=[];this.elements.forEach((s=>{const i=(0,u.position)(s.container);g.intersectRect(i,t)&&e.push(s.item)})),this.stateManager.state.activeElements=e}};(0,n.gn)([(0,c.watch)(":afterResize"),(0,c.watch)(":resize"),(0,c.watch)("container:scroll"),(0,c.throttle)()],v.prototype,"onScrollLoadChunk",null),(0,n.gn)([(0,c.watch)("container:dragover")],v.prototype,"onDragOver",null),(0,n.gn)([(0,c.watch)(["container:dragleave","container:drop"])],v.prototype,"onDragLeave",null),v=g=(0,n.gn)([c.component],v);let f=class extends o.u1{className(){return"UIBrowserMessage"}constructor(t,e){super(t),this.container.innerText=(0,u.isString)(e)?e:e.message}};f=(0,n.gn)([c.component],f);let w=class extends o.qe{className(){return"UIBrowserMessages"}build(t){this.clear(),t.forEach((t=>{const e=new f(this.jodit,t.message);e.setMod("type",t.type),this.append(e)}))}};w=(0,n.gn)([c.component],w);class y{static remove(t){(0,u.css)(t.container,{width:null,height:null}),t.container.classList.remove("jodit-ui-resize"),p.i.safeRemove(t.container.querySelector(".jodit-ui-resize__handle"))}static install(t,e){t.container.classList.add("jodit-ui-resize"),"static"===(0,u.css)(t.container,"position")&&(0,u.css)(t.container,"position","relative");const s=t.j.c.div("jodit-ui-resize__handle");s.classList.add("jodit-ui-resize__handle_type_"+e),t.container.appendChild(s),t.j.e.on(s,"mousedown touchstart",this.onStartResize.bind(this,t,e))}static onStartResize(t,e,s){const i=t.j.async.throttle(this.onResize.bind(this,t,{x:s.clientX,y:s.clientY,w:t.container.offsetWidth,h:t.container.offsetHeight,direction:e}),t.j.defaultTimeout/10);t.j.lock(),t.j.e.on(t.j.ow,"mousemove touchmove",i).one(t.j.ow,"mouseup touchend",this.onEndResize.bind(this,t,i))}static onResize(t,e,s){const i=["left","right"].includes(e.direction),n=t.container.parentElement;if(!n)return;let o=0;o=i?(e.w+(s.clientX-e.x)*("right"===e.direction?1:-1))/n.offsetWidth:(e.h+(s.clientY-e.y)*("top"===e.direction?1:-1))/n.offsetHeight,(0,u.css)(t.container,i?"width":"height",100*o+"%")}static onEndResize(t,e,s){t.j.e.off(t.j.ow,"mousemove touchmove",e),t.j.unlock()}}let b=class extends o.qe{constructor(t,e,s){super(t,e),this.state=s,this.onChangeFavorites()}className(){return"UISidebar"}render(){return"<div>\n\t\t\t<div class='&__hide-btn'>*angle-left*</div>\n\t\t\t<div class='&__favorites'>*heart* ~Favorites~</div>\n\t\t\t<div class='&__box'></div>\n\t\t</div>"}appendChildToContainer(t){this.getElm("box").appendChild(t)}addResize(){y.remove(this),y.install(this,screen.width>450?"right":"bottom")}onChangeFavorites(){this.setMod("has-favorites",!!this.state.favorites.length)}onClickHideButton(){return this.state.showSideBar=!this.state.showSideBar,!1}onClickFavorites(){return this.state.elements=this.state.favorites,!1}};(0,n.gn)([(0,c.hook)("ready"),(0,c.watch)(":resize",window),(0,c.debounce)()],b.prototype,"addResize",null),(0,n.gn)([(0,c.watch)("state.favorites")],b.prototype,"onChangeFavorites",null),(0,n.gn)([(0,c.watch)("hide-btn:click")],b.prototype,"onClickHideButton",null),(0,n.gn)([(0,c.watch)("favorites:click")],b.prototype,"onClickFavorites",null),b=(0,n.gn)([c.component],b);let C=class extends o.qe{constructor(t,e){super(t),this.state=e,t.e.on(this.getElm("close"),"click",(()=>{this.state.showSettings=!1}))}className(){return"UIBrowserSettings"}render(){return`<div>\n\t\t\t<div class="${this.getFullElName("close")}">${o.JO.get("cancel")}</div>\n\t\t\t<div class="${this.getFullElName("title")}">${this.j.i18n("Settings")}</div>\n\t\t\t<div class="${this.getFullElName("options")}"></div>\n\t\t</div>`}appendChildToContainer(t){this.getElm("options").appendChild(t)}setMod(t,e){return"hidden"===t&&!1===e&&this.generateSettings(),super.setMod(t,e)}onChangeView(){const t=this.getElm("tile-size");t&&(t.style.display="tiles"===this.state.view?"block":"none")}generateSettings(){this.clear();const{j:t}=this;this.append([new o.BO(t,{label:"Theme",name:"theme",value:this.state.theme,radio:!0,options:[{value:"default",text:"Light"},{value:"dark",text:"Dark"}],onChange:t=>{this.state.theme=t[0].value}}),new o.BO(t,{label:"Show favorites",name:"showFavorites",value:this.state.showFavorites,radio:!0,options:[{value:!0,text:"Show"},{value:!1,text:"Hide"}],onChange:t=>{this.state.showFavorites=t[0].value}}),new o.BO(t,{label:"View",name:"view",value:this.state.view,radio:!0,options:[{value:"tiles",text:"Tiles"},{value:"list",text:"List"},{value:"compact",text:"Compact"}],onChange:t=>{this.state.view=t[0].value}}),new o.BO(t,{label:"Folders position",name:"foldersPosition",value:this.state.foldersPosition,radio:!0,options:[{value:"top",text:"Top"},{value:"bottom",text:"Bottom"},{value:"default",text:"Default"}],onChange:t=>{this.state.foldersPosition=t[0].value}}),new o.Cj(t,{label:"Sort by",name:"sort-by",value:this.state.sortBy,options:[{value:"changed-asc",text:t.i18n("Sort by changed")+"(⬆)"},{value:"changed-desc",text:t.i18n("Sort by changed")+"(⬇)"},{value:"name-asc",text:t.i18n("Sort by name")+"(⬆)"},{value:"name-desc",text:t.i18n("Sort by name")+"(⬇)"},{value:"size-asc",text:t.i18n("Sort by size")+"(⬆)"},{value:"size-desc",text:t.i18n("Sort by size")+"(⬇)"}],onChange:t=>{this.state.sortBy=t}}),new o.Cj(t,{label:"Tile size",name:"tile-size",value:this.state.tileSize,options:[{value:"xsmall",text:"Extra small"},{value:"small",text:"Small"},{value:"default",text:"Default"},{value:"large",text:"Large"},{value:"xlarge",text:"Extra large"}],onChange:t=>{this.state.tileSize=t}})]),this.onChangeView()}};(0,n.gn)([(0,c.watch)("state.view")],C.prototype,"onChangeView",null),C=(0,n.gn)([c.component],C);let S=class extends o.u1{constructor(t,e){super(t),this.item=e,this.syncMod=!0,this.getElm("name").innerText=e.name,t.e.on(this.container,"click",(()=>(this.getMod("active")||this.setMod("loading",!0),t.e.fire("openFolder",e)))).on(this.container,"contextmenu",(s=>t.e.fire("contextmenuFolder.filebrowser",e,s)))}className(){return"UIBrowserFolder"}render(){return'<div>\n\t\t\t<div class="&__icon">\n\t\t\t\t<div class=\'&__loader\'></div>\n\t\t\t\t<div class="&__icon-wrapper">\n\t\t\t\t\t*folder*\n\t\t\t\t</div>\n\t\t\t</div>\n\t\t\t<div class="&__name"></div>\n\t\t\t<div class="&__arrow">*angle-right*</div>\n\t\t</div>'}};var x;S=(0,n.gn)([c.component],S);let I=x=class extends o.qe{constructor(t,e){super(t),this.syncMod=!0,this.build(e)}className(){return"UITree"}build(t){this.clear(),t.forEach((t=>{const e=new S(this.jodit,t);this.append(e),t.isActive&&e.setMod("active",!0),t.children.length&&this.append(new x(this.jodit,t.children))}))}};I=x=(0,n.gn)([c.component],I);let M=class extends o.u1{constructor(t,e){super(t,e),this.data=e,this.tree=new I(this.j,this.data.children),this.syncMod=!0,this.getElm("name").innerText=e.title||e.name,this.getElm("tree").appendChild(this.tree.container),t.e.on(this.container,"contextmenu",(s=>t.e.fire("contextmenuSource.filebrowser",e,s)))}className(){return"UIBrowserSource"}render(){return'<div>\n\t\t\t<div class="&__name"></div>\n\t\t\t<div class="&__tree"></div>\n\t\t</div>'}};M=(0,n.gn)([c.component],M);let P=class extends o.qe{constructor(){super(...arguments),this.syncMod=!0}className(){return"UIBrowserSources"}build(t){this.clear(),t.forEach((t=>{this.append(new M(this.jodit,t))}))}};P=(0,n.gn)([c.component],P);let F=class extends o.u1{className(){return"UIBrowserStatusBar"}render(){return"<div>\n\t\t\t<div class='&__slot-left'></div>\n\t\t\t<div class='&__slot-center'></div>\n\t\t\t<div class='&__slot-right'></div>\n\t\t</div>"}value(t,e="left"){return this.getElm("slot-"+e).innerText=t,this}};F=(0,n.gn)([c.component],F);let E=class extends o.qe{constructor(t,e){super(t),this.state=e,this.lastLoadPromise=null,this.onChangeMetaInfo()}className(){return"UIPreview"}addResize(){y.remove(this),y.install(this,screen.width>450?"left":"top")}render(){return'<div>\n\t\t\t\t<div class="&__image"></div>\n\t\t\t\t<div class="&__info"></div>\n\t\t\t\t<div class="&__loader"></div>\n\t\t\t\t<div class="&__empty-message">~Select image~</div>\n\t\t\t</div>'}setMod(t,e){return super.setMod(t,e),"hidden"===t&&!1===e&&this.onChangeMetaInfo(),this}onChangeMetaInfo(){var t,e;if(this.getMod("hidden"))return;const{metaInfo:s}=this.state;this.setMod("empty",!s),p.i.detach(this.getElm("info")),(0,u.css)(this.getElm("image"),{backgroundImage:null}),s&&(this.setMod("is-file",!1===s.isImage).setMod("type",null!==(t=s.type)&&void 0!==t?t:"file"),m.prototype.setElementValue.call(this,"name",s.file),m.prototype.setElementValue.call(this,"time",s.time),m.prototype.setElementValue.call(this,"filesize",s.size),this.setMod("loading",!0),null===(e=this.lastLoadPromise)||void 0===e||e.rejectCallback(),this.lastLoadPromise=(0,u.loadImage)(s.isImage?s.fileURL:s.imageURL,this.j),this.lastLoadPromise.then((t=>{t&&(0,u.css)(this.getElm("image"),{backgroundImage:`url(${t.src})`})})).finally((()=>{this.setMod("loading",!1)})).catch((()=>{})))}};(0,n.gn)([(0,c.hook)("ready"),(0,c.watch)(":resize",window),(0,c.debounce)()],E.prototype,"addResize",null),(0,n.gn)([(0,c.watch)("state.metaInfo")],E.prototype,"onChangeMetaInfo",null),E=(0,n.gn)([c.component],E);let j=class extends o.qe{constructor(t,e){super(t),this.stateManager=e,this.syncMod=!0,this.sources=new P(this.j),this.sidebar=new b(this.jodit,[this.sources],this.stateManager.state),this.preview=new E(this.jodit,this.stateManager.state),this.statusbar=new F(this.j),this.items=new v(this.j,this.stateManager),this.settings=new C(this.jodit,this.stateManager.state),this.messages=new w(this.j),this.state=e.state,this.append(this.sidebar,"content"),this.append(this.items,"content"),this.append(this.messages,"footer"),this.append(this.settings,"content"),this.append(this.preview,"content"),this.append(this.statusbar,"footer"),this.onChangeElements(),this.onChangeSources(),this.onChangeView(),this.onChangeTileSize(),this.onChangeShowFavorites(),this.onChangeMessages(),this.onChangeActiveElements(),this.onChangeFavorites(),this.onChangeShowSideBar(),this.onChangeShowSettings(),this.onChangeShowPreview(),this.onChangeTheme()}className(){return"UIBrowserPanel"}get countInRow(){if("list"===this.state.view)return 1;const{container:t}=this.items.elements[0],e=(0,u.css)(t,"marginLeft");return Math.floor(this.items.container.offsetWidth/(t.offsetWidth+((0,u.isNumber)(e)?e:0)))}get countInColumn(){const{container:t}=this.items.elements[0],e=(0,u.css)(t,"marginTop");return Math.floor(this.items.container.offsetHeight/(t.offsetHeight+((0,u.isNumber)(e)?e:0)))}render(){return"<div>\n\t\t\t<div class='&__content'></div>\n\t\t\t<div class='&__footer'></div>\n\t\t</div>"}onChangeTheme(){this.setMod("theme",this.stateManager.state.theme)}onChangeElements(){this.items.build(this.stateManager.state.elements)}onChangeActiveElements(){this.state.activeElements.length||(this.state.info="",this.state.metaInfo=null),this.items.elements.forEach((t=>{t.setMod("active",!!this.stateManager.isActive(t.item))})),this.j.e.fire("changeSelection")}onChangeFavorites(){this.items.elements.forEach((t=>{t.setMod("favorite",!!this.stateManager.isFavorite(t.item))}))}onChangeSources(){this.sources.build(this.stateManager.state.tree)}onChangeLastSelectedIndex(){var t;const e=null===(t=this.items.elements[this.stateManager.state.lastSelectedIndex])||void 0===t?void 0:t.container;e&&((0,u.scrollIntoViewIfNeeded)(e,this.items.container,this.j.od),e.focus())}onChangeInfo(){this.statusbar.value(this.state.info,"center")}onChangePathOrSource(){this.statusbar.value(this.state.currentPath?`${this.state.currentPath} (${this.state.currentSource})`:this.i18n("Home"),"left")}onChangeShowSettings(){this.settings.setMod("hidden",!this.stateManager.state.showSettings)}onChangeShowPreview(){this.preview.setMod("hidden",!this.stateManager.state.showPreview)}onChangeShowSideBar(){this.sidebar.setMod("hidden",!this.stateManager.state.showSideBar)}onChangeView(){this.items.setMod("view",this.stateManager.state.view)}onChangeTileSize(){this.items.setMod("size",this.stateManager.state.tileSize)}onChangeShowFavorites(){this.sidebar.setMod("show-favorites",this.stateManager.state.showFavorites),this.items.setMod("show-favorites",this.stateManager.state.showFavorites)}onChangeMessages(){this.messages.build(this.stateManager.state.messages)}onItemDblClick(){return this.j.e.fire("select.filebrowser"),!1}onItemClick(t,e){this.stateManager.addActive(t,e)}onTogglePreview(){return this.state.showPreview=!this.state.showPreview,!1}onToggleFavoriteItem(t){this.stateManager.toggleFavorite(t)}onFolderClick(t){this.stateManager.state.currentSource=t.sourceName,this.stateManager.state.currentPath=t.path||"/"}};(0,n.gn)([(0,c.watch)("state.theme")],j.prototype,"onChangeTheme",null),(0,n.gn)([(0,c.watch)("state.elements")],j.prototype,"onChangeElements",null),(0,n.gn)([(0,c.watch)("state.activeElements")],j.prototype,"onChangeActiveElements",null),(0,n.gn)([(0,c.watch)(["state.favorites","state.elements"])],j.prototype,"onChangeFavorites",null),(0,n.gn)([(0,c.watch)("state.sources")],j.prototype,"onChangeSources",null),(0,n.gn)([(0,c.watch)("state.lastSelectedIndex")],j.prototype,"onChangeLastSelectedIndex",null),(0,n.gn)([(0,c.watch)("state.info")],j.prototype,"onChangeInfo",null),(0,n.gn)([(0,c.watch)(["state.currentPath","state.currentSource"])],j.prototype,"onChangePathOrSource",null),(0,n.gn)([(0,c.watch)("state.showSettings")],j.prototype,"onChangeShowSettings",null),(0,n.gn)([(0,c.watch)("state.showPreview")],j.prototype,"onChangeShowPreview",null),(0,n.gn)([(0,c.watch)("state.showSideBar")],j.prototype,"onChangeShowSideBar",null),(0,n.gn)([(0,c.watch)("state.view")],j.prototype,"onChangeView",null),(0,n.gn)([(0,c.watch)("state.tileSize")],j.prototype,"onChangeTileSize",null),(0,n.gn)([(0,c.watch)("state.showFavorites")],j.prototype,"onChangeShowFavorites",null),(0,n.gn)([(0,c.watch)("state.messages")],j.prototype,"onChangeMessages",null),(0,n.gn)([(0,c.watch)(":dblclickItem.filebrowser")],j.prototype,"onItemDblClick",null),(0,n.gn)([(0,c.watch)(":clickItem.filebrowser")],j.prototype,"onItemClick",null),(0,n.gn)([(0,c.watch)(":togglePreview.filebrowser")],j.prototype,"onTogglePreview",null),(0,n.gn)([(0,c.watch)(":toggleFavoriteItem")],j.prototype,"onToggleFavoriteItem",null),(0,n.gn)([(0,c.watch)(":openFolder")],j.prototype,"onFolderClick",null),j=(0,n.gn)([c.component],j);var k=s(3);class _{constructor(t){this.state=t}getIndex(t,e=this.state.elements){return e.findIndex((e=>e.uniqueHashKey===t.uniqueHashKey))}isActive(t){return!!this.state.activeElements.find((e=>e.uniqueHashKey===t.uniqueHashKey))}isFavorite(t){return!!this.state.favorites.find((e=>e.uniqueHashKey===t.uniqueHashKey))}addActive(t,e){var s;this.state.metaInfo=t,this.state.info=null!==(s=t.file)&&void 0!==s?s:"",this.state.lastSelectedIndex=this.getIndex(t),this.state.activeElements=e?[...this.state.activeElements,t]:[t]}callSelectHandler(){var t;const e=this.state.activeElements;null===(t=this.state.onSelectCallBack)||void 0===t||t.call(this,{baseurl:"",files:e.map((t=>t.fileURL)),isImages:e.map((t=>!!t.isImage))})}setFilter(t){this.state.filterWord=t}addMessage(t){var e;const s=this.state.messages;(null===(e=s[s.length-1])||void 0===e?void 0:e.message)!==t.message&&(this.state.messages=[...s,t])}removeMessage(t){const e=this.state.messages.indexOf(t);if(-1!==e){const t=[...this.state.messages];t.splice(e,1),this.state.messages=t}}toggleFavorite(t){const e=this.getIndex(t,this.state.favorites),s=[...this.state.favorites];-1===e?s.push(t):s.splice(e,1),this.state.favorites=s}fillSources(t,e){const s=t=>t.filter((t=>"."!==t&&".."!==t));if(this.state.tree.length&&e){const i=(t,e)=>{var s;return null!==(s=t.find((t=>t.name===e)))&&void 0!==s?s:null};this.removeActive(this.state.tree),t.forEach((t=>{const n=i(this.state.tree,t.name);if(n){n.isActive=!0;const o=e.split("/").reduce(((t,e)=>t&&i(t.children,e)),n);o&&(o.isActive=!0,o.children=s(t.folders).map((s=>({type:"directory",name:s,path:e+"/"+s,sourceName:t.name,children:[]}))))}}))}else this.state.tree=t.map((t=>({type:"source",name:t.name,title:t.title,sourceName:t.name,path:"/",children:s(t.folders).map((e=>({type:"directory",name:e,path:e,sourceName:t.name,children:[]})))})))}removeActive(t){t.forEach((t=>{t.isActive=!1,this.removeActive(t.children)}))}get isFavoriteItems(){return this.state.favorites===this.state.elements}}(0,n.gn)([c.autobind],_.prototype,"getIndex",null),(0,n.gn)([c.autobind],_.prototype,"isActive",null),(0,n.gn)([c.autobind],_.prototype,"isFavorite",null);var R=s(51);let B=class extends o.qe{constructor(t,e,s){var i;super(t),this.options=e,this.stateManager=s,this.syncMod=!0,this.toolbar=(0,R.R)(this.j),this.filter=new o.u3(this.j,{icon:"search",placeholder:"Filter",clearButton:!0,onChange:t=>{this.stateManager.setFilter(t)}}),this.append(this.toolbar).append(this.filter),this.filter.container.classList.add(this.getFullElName("filter")),this.toolbar.setMod("mode","header").build(null!==(i=this.options.toolbarButtons)&&void 0!==i?i:[])}className(){return"UIBrowserHeader"}};B=(0,n.gn)([c.component],B);var L=s(60),z=s(2);let N=class extends o.ko{constructor(t,e){super(t),this.state=e,this.onProgress()}className(){return"UIProgress"}onProgress(){this.state.progress?this.show():this.hide(),this.progress(this.state.progress)}hide(){return this.setMod("hidden",!0),this}progress(t){return this.container.style.width=t.toFixed(2)+"%",98>t||this.j.async.setTimeout((()=>{this.hide()}),{label:"progress",timeout:300}),this}show(){return this.setMod("hidden",!1),this}};(0,n.gn)([(0,c.watch)("state.progress")],N.prototype,"onProgress",null),N=(0,n.gn)([c.component],N);var T=s(57),H=s(13);let O=class extends H.Hr{constructor(t,e){super(t),this.state=e,this.sortBy="changed-desc",this.view="tiles",this.foldersPosition="top",this.tileSize="default",this.favorites=[],this.showSideBar=!0,this.showPreview=!1,this.showFavorites=!0}className(){return"PersistentStore"}onChangeThemeSetField(){this.theme=this.state.theme}onChangeView(){this.view=this.state.view}onChangeSortBy(){this.sortBy=this.state.sortBy}onChangeTileSize(){this.tileSize=this.state.tileSize}onChangeFavorites(){this.favorites=this.state.favorites}onChangeShowSideBar(){this.showSideBar=this.state.showSideBar}onChangeShowPreview(){this.showPreview=this.state.showPreview}onChangeShowFavorites(){this.showFavorites=this.state.showFavorites}onChangeFoldersPosition(){this.foldersPosition=this.state.foldersPosition}syncWithState(){this.state.tileSize=this.tileSize,this.state.favorites=this.favorites.map((t=>t instanceof d.Z?t:d.Z.create(t))),this.state.view=this.view,this.state.theme=this.theme,this.state.showSideBar=this.showSideBar,this.state.showPreview=this.showPreview,this.state.showFavorites=this.showFavorites,this.state.sortBy=this.sortBy,this.state.foldersPosition=this.foldersPosition}};(0,n.gn)([c.persistent],O.prototype,"theme",void 0),(0,n.gn)([c.persistent],O.prototype,"sortBy",void 0),(0,n.gn)([c.persistent],O.prototype,"view",void 0),(0,n.gn)([c.persistent],O.prototype,"foldersPosition",void 0),(0,n.gn)([c.persistent],O.prototype,"tileSize",void 0),(0,n.gn)([c.persistent],O.prototype,"favorites",void 0),(0,n.gn)([c.persistent],O.prototype,"showSideBar",void 0),(0,n.gn)([c.persistent],O.prototype,"showPreview",void 0),(0,n.gn)([c.persistent],O.prototype,"showFavorites",void 0),(0,n.gn)([(0,c.watch)("state.theme")],O.prototype,"onChangeThemeSetField",null),(0,n.gn)([(0,c.watch)("state.view")],O.prototype,"onChangeView",null),(0,n.gn)([(0,c.watch)("state.sortBy")],O.prototype,"onChangeSortBy",null),(0,n.gn)([(0,c.watch)("state.tileSize")],O.prototype,"onChangeTileSize",null),(0,n.gn)([(0,c.watch)("state.favorites")],O.prototype,"onChangeFavorites",null),(0,n.gn)([(0,c.watch)("state.showSideBar")],O.prototype,"onChangeShowSideBar",null),(0,n.gn)([(0,c.watch)("state.showPreview")],O.prototype,"onChangeShowPreview",null),(0,n.gn)([(0,c.watch)("state.showFavorites")],O.prototype,"onChangeShowFavorites",null),(0,n.gn)([(0,c.watch)("state.foldersPosition")],O.prototype,"onChangeFoldersPosition",null),O=(0,n.gn)([c.component],O);let U=class extends H.Hr{constructor(t,e){super(t),this.state=e}className(){return"HistoryManager"}updateHistory(){this.state.history[this.state.historyIndex]={currentSource:this.state.currentSource,currentPath:this.state.currentPath,tree:(0,u.fastClone)(this.state.tree),elements:this.state.elements}}updateState(){const{tree:t,elements:e,currentSource:s,currentPath:i}=this.state.history[this.state.historyIndex];this.state.elements=e,this.state.tree=t,this.state.currentSource=s,this.state.currentPath=i,this.j.e.fire("changeSelection")}push(){let t=[...this.state.history],{historyIndex:e}=this.state;const s=t[e];s&&s.currentSource===this.state.currentSource&&s.currentPath===this.state.currentPath||(t.length-1!==e&&(t=t.slice(0,e)),t.push({tree:[],elements:[],currentPath:this.state.currentPath,currentSource:this.state.currentSource}),s&&(e+=1),this.state.historyIndex=e,this.state.history=t,this.updateHistory(),this.j.e.fire("changeSelection"))}onNext(){this.state.history.length-1>this.state.historyIndex&&(this.state.historyIndex+=1,this.updateState())}onPrevious(){this.state.historyIndex>0&&(this.state.historyIndex-=1,this.updateState())}onHome(){this.state.currentSource="",this.state.currentPath="",this.j.e.fire("update.filebrowser")}};(0,n.gn)([(0,c.watch)(":next.filebrowser")],U.prototype,"onNext",null),(0,n.gn)([(0,c.watch)(":previous.filebrowser")],U.prototype,"onPrevious",null),(0,n.gn)([(0,c.watch)(":goHome.filebrowser")],U.prototype,"onHome",null),U=(0,n.gn)([c.component],U);let D=class extends H.Hr{className(){return"ContextMenuManager"}onFolderContext(t,e){return this.buildContextItemMenu(this.getFolderContextActions(t),e),!1}onItemContext(t,e,s){return this.buildContextItemMenu(this.getItemContextActions(t),s),!1}onSourceContext(t,e){return this.buildContextItemMenu(this.getSourceContextActions(t),e),!1}buildContextItemMenu(t,e){if(!this.j.o.contextMenu)return;const s=(0,T.L)(this.j).setMod("theme",this.j.state.theme);s.show(e.clientX,e.clientY,t.filter((t=>t&&!1!==t.enabled))),this.j.e.on(this.j,"afterClose",(()=>{s.isOpened&&s.close()}))}getItemContextActions(t){if(this.j.stateManager.isActive(t)||this.j.stateManager.addActive(t,this.j.state.activeElements.length>1),"folder"===t.type)return this.getFolderContextActions({type:"directory",children:[],name:t.name||"",path:t.path,sourceName:t.sourceName});const e=this.j.options,s=this.j.dataProvider,i=1===this.j.state.activeElements.length;return[{icon:"pencil",title:"Edit",enabled:!!t.isImage&&e.editImage&&i&&(s.canI("ImageResize")||s.canI("ImageCrop")),exec:()=>{L.r.call(this.j,t.imageURL,t.name||"",this.j.state.currentPath,this.j.state.currentSource)}},{icon:"italic",title:"Rename",enabled:s.canI("FileRename")&&i,exec:()=>this.j.e.fire("fileRename.filebrowser",t)},{icon:"bin",title:"Delete",enabled:s.canI("FileRemove"),exec:()=>this.j.e.fire("fileRemove.filebrowser",t)},{icon:"eye",title:"Preview",enabled:!!t.isImage&&e.preview&&i,exec:()=>this.j.e.fire("openLightBox.filebrowser",t)},{icon:"upload",title:"Download",exec:()=>{t.fileURL&&this.j.ow.open(t.fileURL)}}]}getFolderContextActions(t){const e=this.j.dataProvider;return[{icon:"pencil",title:"Rename",exec:()=>{this.j.e.fire("folderRename.filebrowser",t)},enabled:e.canI("FolderRename")},{icon:"bin",title:"Delete",exec:()=>{this.j.e.fire("folderRemove.filebrowser",t)},enabled:e.canI("FolderRemove")},{icon:"plus",title:"Add folder",exec:()=>{this.j.e.fire("folderCreate.filebrowser",t)},enabled:e.canI("FolderCreate")}]}getSourceContextActions(t){return[{icon:"plus",title:"Create folder",exec:()=>{this.j.e.fire("folderCreate.filebrowser",t)}}]}};(0,n.gn)([(0,c.watch)(":contextmenuFolder.filebrowser")],D.prototype,"onFolderContext",null),(0,n.gn)([(0,c.watch)(":contextmenuItem.filebrowser")],D.prototype,"onItemContext",null),(0,n.gn)([(0,c.watch)(":contextmenuSource.filebrowser")],D.prototype,"onSourceContext",null),D=(0,n.gn)([c.component],D);const K=t=>{const e=t.split("/").filter((t=>t.length));return e.pop(),e.join("/")||"/"};var A,V=s(1),q=s(167);let W=A=class extends h.UIElement{constructor(t,e,s){super(t),this.current=e,this.elements=s,this.dialog=new h.Dialog;const{dialog:i}=this;i.setMod("theme",t.state.theme).toolbar.setMod("mode","header"),i.open(this),this.elements=this.elements.filter((t=>t.isImage)),i.e.on(i,"afterClose",(()=>{this.destruct()})),this.addGlobalListeners(),this.onChangeCurrent(),i.toolbar.build([{icon:"check",exec:()=>{t.stateManager.addActive(this.current,!1),t.e.fire("select.filebrowser"),i.close()}},"dialog.close"])}className(){return"UILightBox"}render(){return"<div>\n\t\t\t<div class='&__previous'>*angle-left*</div>\n\t\t\t<div class='&__preview'></div>\n\t\t\t<div class='&__loader'></div>\n\t\t\t<div class='&__next'>*angle-right*</div>\n\t\t</div>"}async onChangeCurrent(){const{current:t}=this;this.setMod("loading",!0);const e=this.getElm("preview");if(h.Dom.detach(e),(0,u.css)(e,{backgroundImage:null}),t.isImage){const s=await(0,u.loadImage)(t.fileURL,this.j);this.dialog.setPosition(),(0,u.css)(e,{width:Math.min(this.jodit.ow.innerWidth,s.naturalWidth),height:Math.min(this.jodit.ow.innerHeight-100,s.naturalHeight),backgroundImage:`url(${s.src})`})}else{const s=await this.makeIframe(t.fileURL);e.appendChild(s)}this.dialog.setSize(),this.dialog.setPosition(),this.setMod("loading",!1)}makeIframe(t){const e=this.j.c.element("iframe");return e.classList.add(this.getFullElName("office-iframe")),e.src=/\.pdf/.test(t)?t:this.j.o.previewOfficeURL+encodeURIComponent(t),e}onPreviousClick(){const{current:t}=this;let e=this.j.stateManager.getIndex(t,this.elements);e>0?e-=1:e=this.elements.length-1,this.current=this.elements[e]}onNextClick(){const{current:t}=this;let e=this.j.stateManager.getIndex(t,this.elements);this.elements.length-1>e?e+=1:e=0,this.current=this.elements[e]}static open(t,e,s){return new A(t,e,s)}addGlobalListeners(){this.j.e.on(this.j.od,"keydown",this.onKeyPress)}onKeyPress(t){if(t.key===k.KEY_LEFT||t.key===k.KEY_RIGHT||t.key===k.KEY_SPACE)return t.key===k.KEY_LEFT?this.onPreviousClick():this.onNextClick(),!1}removeGlobalListeners(){this.j.e.off(this.j.od,"keydown",this.onKeyPress)}destruct(){return this.removeGlobalListeners(),this.dialog.destruct(),super.destruct()}};(0,n.gn)([(0,c.watch)("current")],W.prototype,"onChangeCurrent",null),(0,n.gn)([(0,c.watch)("previous:click")],W.prototype,"onPreviousClick",null),(0,n.gn)([(0,c.watch)("next:click")],W.prototype,"onNextClick",null),(0,n.gn)([c.autobind],W.prototype,"onKeyPress",null),W=A=(0,n.gn)([c.component],W);let Y=class extends l.Vq{constructor(t){super((0,u.ConfigProto)(Object.assign(t||{},{resizable:!0,draggable:!0,toolbarButtons:(null==t?void 0:t.buttons)||z.D.defaultOptions.filebrowser.buttons,buttons:V.Jodit.atom(["filebrowser.settings","fullsize","dialog.close"])}),z.D.defaultOptions.filebrowser)),this.dataProvider=(0,T.S)(this,this.options),this.state=h.ObserveObject.create({onSelectCallBack:null,theme:"default",showSideBar:!0,showFavorites:!0,showSettings:!1,showPreview:!1,withFolders:!0,foldersPosition:"bottom",info:"",metaInfo:null,currentPath:"",currentSource:"",currentBaseUrl:"",history:[],historyIndex:0,tree:[],activeElements:[],favorites:[],progress:0,lastSelectedIndex:0,elements:[],messages:[],sources:[],view:"tiles",tileSize:"default",sortBy:"name-asc",filterWord:"",onlyImages:!1},["state"]),this.persistent=new O(this,this.state),this.stateManager=new _(this.state),this.historyManager=new U(this,this.state),this.contextMenuManager=new D(this),this.header=new B(this,this.options,this.stateManager),this.panel=new j(this,this.stateManager),this.progressbar=new N(this,this.stateManager.state),this.offset=0,this.countInOneChunk=20,this.stopLoadingParts=!1,q.V.make(this),!this.persistent.theme&&this.options.theme&&(this.persistent.theme=this.options.theme),this.panel.append(this.progressbar),this.toolbar.setMod("mode","header"),this.setSize(Math.min(this.options.width,screen.width),Math.min(this.options.height,screen.height)).setHeader(this.header),this.onResizeWindow(),this.initUploader(),this.onChangeTheme(),this.fullFillOptions(),this.dataProvider.onProgress((t=>{0===t&&(t=30),this.state.progress=t})),this.e.on("beforeClose",this.removeGlobalListeners),this.e.fire("afterInit"),V.Jodit.prototype.afterInitHook.call(this)}className(){return"FileBrowserPro"}lock(t="any"){return this.container.classList.add("jodit_disabled"),super.lock(t)}unlock(){return this.container.classList.remove("jodit_disabled"),super.unlock()}status(t,e=!(t instanceof Error)){const s={message:(0,u.isString)(t)?t:t.message,type:e?"success":"error"};this.stateManager.addMessage(s),this.async.setTimeout((()=>{this.stateManager.removeMessage(s)}),this.options.howLongShowMsg)}addDisclaimer(t){this.dialog.appendChild(t)}onResizeWindow(){(0,u.css)(this.dialog,{maxWidth:screen.width,minHeight:Math.min(this.options.height,screen.height),minWidth:Math.min(this.options.width,screen.width)})}async open(t=this.o.defaultCallback,e){return this.state.onlyImages=!!e,this.prepareOpening(t),super.open(this.panel.container),this.onUpdateFileBrowser()}onChangeTheme(){this.setMod("theme",this.state.theme),this.header.setMod("theme",this.state.theme),this.panel.setMod("theme",this.state.theme),this.options.theme=this.state.theme}onToggleSettings(){this.state.showSettings=!this.state.showSettings}async onUpdateFileBrowser(){this.state.activeElements=[],this.panel.setMod("loading",!0),await Promise.all([this.loadFolders(),this.loadItems()]),this.panel.setMod("loading",!1),this.historyManager.updateHistory()}async loadFolders(){if(!this.isOpened)return;const{currentPath:t,currentSource:e}=this.state;this.historyManager.push();try{this.uploader.setPath(t),this.uploader.setSource(e);const s=await this.dataProvider.tree(t,e);this.stateManager.fillSources(s,t),this.historyManager.updateHistory(),this.state.sources=s}catch(t){this.status(t)}}async loadItems(){if(this.isOpened)try{for(this.offset=0,this.stopLoadingParts=!1,this.state.elements=await this.loadPartItems(),this.stopLoadingParts=this.countInOneChunk>this.state.elements.length;!this.stopLoadingParts&&this.panel.countInColumn*this.panel.countInRow>=this.state.elements.length;)await this.loadItemsChunk();this.historyManager.updateHistory()}catch(t){this.status(t)}}async loadItemsChunk(){if(!this.stopLoadingParts)try{this.offset+=this.countInOneChunk;const t=await this.loadPartItems();this.stopLoadingParts=this.countInOneChunk>t.length,t.length&&(this.state.elements=this.state.elements.concat(t))}catch(t){this.status(t)}}prepareOpening(t){this.registerGlobalListeners(),t&&(this.state.onSelectCallBack=e=>{this.close(),t(e)}),this.persistent.syncWithState()}registerGlobalListeners(){this.e.on(this.ow,"keydown",this.onKeyPress)}onKeyPress(t){const{activeElement:e}=this.od;if(!this.state.activeElements.length||!e||!h.Dom.isOrContains(this.panel.items.container,e))return;const s=this.state.elements;switch(t.key){case k.KEY_ENTER:return this.onChooseItems();case k.KEY_DELETE:return this.onFileRemove();case k.KEY_RIGHT:case k.KEY_LEFT:case k.KEY_DOWN:case k.KEY_UP:{const e=t.key===k.KEY_RIGHT||t.key===k.KEY_DOWN,i=this.state.lastSelectedIndex;let n;if([k.KEY_RIGHT,k.KEY_LEFT].includes(t.key))n=e?s[i+1]?i+1:0:s[i-1]?i-1:s.length-1;else{const{countInRow:t}=this.panel;n=Math.round(((i+1)/t+(e?1:-1))*t-1)}return s[n]&&this.stateManager.addActive(s[n],t.shiftKey),!1}}}removeGlobalListeners(){this.e.off(this.ow,"keydown",this.onKeyPress)}onFileRemove(){this.state.activeElements.length&&(0,h.Confirm)(this.i18n("Are you sure?"),"",(t=>{if(t){const t=[];this.state.activeElements.forEach((e=>{this.stateManager.isFavorite(e)&&this.stateManager.toggleFavorite(e),t.push(this.deleteFile(e.file||e.name||"",e.sourceName))})),this.state.activeElements=[],Promise.all(t).then((()=>this.loadItems()))}})).bindDestruct(this)}onFileEdit(){if(1===this.state.activeElements.length){const[t]=this.state.activeElements;L.r.call(this,t.fileURL,t.file||"",t.path,t.sourceName,void 0,this.status)}}onFolderRename(t){(0,h.Prompt)(this.i18n("Enter new name"),this.i18n("Rename"),(e=>{if(!(0,u.isValidName)(e)||e===t.name)return this.status(this.i18n("Enter new name")),!1;this.dataProvider.folderRename(K(t.path),t.name,e,t.sourceName).then((s=>{this.state.activeElements=[],this.status(s,!0),this.state.currentPath=K(t.path)+"/"+e,this.state.currentSource=t.sourceName,this.loadFolders()})).catch(this.status)}),this.i18n("type name"),t.name).bindDestruct(this)}onFolderRemove(t){(0,h.Confirm)(this.i18n("Are you sure?"),this.i18n("Delete"),(e=>{e&&this.dataProvider.folderRemove(K(t.path),t.name,t.sourceName).then((e=>{this.status(e,!0),this.state.currentPath=K(t.path),this.state.currentSource=t.sourceName,this.loadFolders()})).catch(this.status)})).bindDestruct(this)}onFolderCreate(t){(0,h.Prompt)(this.i18n("Enter Directory name"),this.i18n("Create directory"),(e=>{const s=t.path||"/";this.dataProvider.createFolder(e,t.path||"/",t.sourceName).then((()=>{this.state.currentSource===t.sourceName&&this.state.currentPath===s?this.onUpdateFileBrowser():(this.state.currentSource=t.sourceName,this.state.currentPath=s)}),this.status)}),this.i18n("type name")).bindDestruct(this)}onFileRename(t){const e=t.file||t.name||"";1===this.state.activeElements.length&&e&&(0,h.Prompt)(this.i18n("Enter new name"),this.i18n("Rename"),(t=>{if(!(0,u.isValidName)(t))return this.status(this.i18n("Enter new name")),!1;this.dataProvider.fileRename(this.state.currentPath,e,t,this.state.currentSource).then((t=>{this.state.activeElements=[],this.status(t,!0),this.loadItems()})).catch(this.status)}),this.i18n("type name"),e).bindDestruct(this)}onChooseItems(){const t=this.stateManager.state.activeElements;if(t.length){if("folder"===t[0].type)return this.state.currentPath=this.state.currentPath+"/"+t[0].name,void(this.state.currentSource=t[0].sourceName);this.state.onSelectCallBack?this.stateManager.callSelectHandler():this.onOpenLightBox(t[0])}}onOpenLightBox(t){W.open(this,t,this.state.elements)}deleteFile(t,e){return this.dataProvider.fileRemove(this.state.currentPath,t,e).then((e=>{this.status(e||this.i18n('File "%s" was deleted',t),!0)})).catch(this.status)}initUploader(){const t=this,e=(0,u.ConfigProto)(t.o.uploader||{},z.D.defaultOptions.uploader),s=()=>this.loadItems();t.uploader=t.getInstance("Uploader",e),t.uploader.bind(t.panel.container,s,t.status),t.e.on("bindUploader.filebrowser",(e=>{t.uploader.bind(e,s,t.status)}))}destruct(){this.removeGlobalListeners(),this.header.destruct(),this.panel.destruct(),super.destruct()}fullFillOptions(){["getLocalFileByUrl","crop","resize","create","fileMove","folderMove","fileRename","folderRename","fileRemove","folderRemove","folder","items","permissions"].forEach((t=>{null!=this.options[t]&&(this.options[t]=(0,u.ConfigProto)(this.options[t],this.o.ajax))}))}loadPartItems(){return this.dataProvider.items(this.state.currentPath,this.state.currentSource,{offset:this.offset,limit:this.countInOneChunk,sortBy:this.state.sortBy,withFolders:this.state.withFolders,foldersPosition:this.state.foldersPosition,onlyImages:this.state.onlyImages,filterWord:this.state.filterWord})}};(0,n.gn)([c.autobind],Y.prototype,"status",null),(0,n.gn)([(0,c.watch)(":resize",window)],Y.prototype,"onResizeWindow",null),(0,n.gn)([(0,c.watch)("state.theme")],Y.prototype,"onChangeTheme",null),(0,n.gn)([(0,c.watch)(":toggleSettings.filebrowser")],Y.prototype,"onToggleSettings",null),(0,n.gn)([(0,c.watch)(":update.filebrowser")],Y.prototype,"onUpdateFileBrowser",null),(0,n.gn)([(0,c.watch)(["state.currentPath","state.currentSource"]),(0,c.debounce)((t=>({timeout:t.defaultTimeout,promisify:!0})))],Y.prototype,"loadFolders",null),(0,n.gn)([(0,c.watch)(["state.currentPath","state.currentSource","state.sortBy","state.onlyImages","state.foldersPosition","state.filterWord"]),(0,c.debounce)((t=>({timeout:t.defaultTimeout,promisify:!0})))],Y.prototype,"loadItems",null),(0,n.gn)([(0,c.debounce)((t=>({timeout:t.defaultTimeout,promisify:!0})))],Y.prototype,"loadItemsChunk",null),(0,n.gn)([c.autobind],Y.prototype,"onKeyPress",null),(0,n.gn)([c.autobind],Y.prototype,"removeGlobalListeners",null),(0,n.gn)([(0,c.watch)(":fileRemove.filebrowser")],Y.prototype,"onFileRemove",null),(0,n.gn)([(0,c.watch)(":edit.filebrowser")],Y.prototype,"onFileEdit",null),(0,n.gn)([(0,c.watch)(":folderRename.filebrowser")],Y.prototype,"onFolderRename",null),(0,n.gn)([(0,c.watch)(":folderRemove.filebrowser")],Y.prototype,"onFolderRemove",null),(0,n.gn)([(0,c.watch)(":folderCreate.filebrowser")],Y.prototype,"onFolderCreate",null),(0,n.gn)([(0,c.watch)(":fileRename.filebrowser")],Y.prototype,"onFileRename",null),(0,n.gn)([(0,c.watch)(":select.filebrowser")],Y.prototype,"onChooseItems",null),(0,n.gn)([(0,c.watch)(":openLightBox.filebrowser")],Y.prototype,"onOpenLightBox",null),Y=(0,n.gn)([c.component],Y),V.Jodit.modules.FileBrowserPro=Y,(0,s(14).xl)(s(171));const G=z.D.prototype.controls.filebrowser;G.settings={icon:"settings",exec(t){t.e.fire("toggleSettings.filebrowser")}},G.home={icon:"home",exec(t){t.e.fire("goHome.filebrowser")}},G.preview={icon:"eye",exec(t){t.e.fire("togglePreview.filebrowser")}},G.next={icon:"angle-right",isDisabled(t){if(!t.state)return!0;const{history:e,historyIndex:s}=t.state;return!e||!e.length||s===e.length-1},exec(t){t.e.fire("next.filebrowser")}},G.previous={icon:"angle-left",isDisabled(t){if(!t.state)return!0;const{history:e,historyIndex:s}=t.state;return!e||!e.length||0===s},exec(t){t.e.fire("previous.filebrowser")}},Object.assign(z.D.prototype.filebrowser,{buttons:["filebrowser.home","filebrowser.previous","filebrowser.next","|","filebrowser.upload","filebrowser.remove","filebrowser.update","filebrowser.select","filebrowser.edit","|","filebrowser.preview","about"],sort:!1,pixelOffsetLoadNewChunk:200,width:750,height:400,previewOfficeURL:"https://view.officeapps.live.com/op/view.aspx?src="});class $ extends i.S{constructor(){super(...arguments),this.requires=["license"],this.hasStyle=!V.Jodit.fatMode}afterInit(t){t.e.on("getInstanceFileBrowser",(t=>(this.__instance||(this.__instance=new Y(t)),this.__instance)))}beforeDestruct(t){var e;t.e.off("getInstanceFileBrowser"),null===(e=this.__instance)||void 0===e||e.destruct()}}V.Jodit.plugins.add("finder",$)},171(t,e,s){"use strict";s.r(e),s.d(e,{ru:()=>i});const i=s(172)},172(t){t.exports={Favorites:"Избранное",Settings:"Настройки",Light:"Светлая",Dark:"Темная",Theme:"Тема",Show:"Показать",Hide:"Скрыть","Show favorites":"Показывать избранное",Tiles:"Плитка",List:"Список",Compact:"Компактный",View:"Отображение","Folders position":"Позиция папок","Sort by":"Сортировать по","Extra small":"Очень маленькие",Small:"Маленькие",Large:"Большие","Extra large":"Очень большие","Tile size":"Размер плитки"}}},t=>{"use strict";return t(t.s=168)}])}));
/*!
* jodit-pro - PRO Version of Jodit Editor
* Author: Chupurnov Valeriy <chupurnov@gmail.com>
* Version: v1.0.45
* Version: v1.0.46
* Url: https://xdsoft.net/jodit/pro/

@@ -10,2 +10,2 @@ * License(s): SEE LICENSE IN LICENSE.md

!function(e,o){if("object"==typeof exports&&"object"==typeof module)module.exports=o();else if("function"==typeof define&&define.amd)define([],o);else{var t=o();for(var n in t)("object"==typeof exports?exports:e)[n]=t[n]}}(self,(function(){return(self.webpackChunkjodit_pro=self.webpackChunkjodit_pro||[]).push([[799],{527:e=>{e.exports='<svg width="11" height="15" viewBox="0 0 11 15" fill="none" xmlns="http://www.w3.org/2000/svg"> <path d="M10.925 7.122V14H9.747L9.462 13.164C9.044 13.4933 8.55 13.7467 7.98 13.924C7.42267 14.1013 6.82733 14.19 6.194 14.19C5.054 14.19 4.066 13.9177 3.23 13.373C2.394 12.8157 1.75433 12.024 1.311 10.998C0.867667 9.972 0.646 8.756 0.646 7.35C0.646 5.96933 0.880333 4.766 1.349 3.74C1.83033 2.714 2.50167 1.92233 3.363 1.365C4.237 0.794999 5.25667 0.509999 6.422 0.509999C7.41 0.509999 8.284 0.693666 9.044 1.061C9.804 1.42833 10.3613 1.935 10.716 2.581L9.747 3.55C9.41767 3.03067 8.968 2.638 8.398 2.372C7.84067 2.09333 7.18833 1.954 6.441 1.954C5.17433 1.954 4.18633 2.429 3.477 3.379C2.76767 4.329 2.413 5.65267 2.413 7.35C2.413 9.07267 2.755 10.4153 3.439 11.378C4.13567 12.3407 5.10467 12.822 6.346 12.822C6.92867 12.822 7.46067 12.7397 7.942 12.575C8.436 12.4103 8.854 12.1697 9.196 11.853V8.414H6.023V7.122H10.925Z" fill="black"/> </svg>'},526:(e,o,t)=>{"use strict";Object.defineProperty(o,"__esModule",{value:!0}),o.googleSearch=void 0;var n=t(1),r=t(187),i=t(12),s=t(23),l=t(305),c=t(2);i.Config.prototype.controls.google={tooltip:"Google search",icon:t(527),isDisabled:function(e){return l.isEditorEmpty(e.editor)},command:"startSearch"};var p=function(e){function o(){var o=null!==e&&e.apply(this,arguments)||this;return o.requires=["license"],o.buttons=[{name:"google",group:"search"}],o}return n.__extends(o,e),o.prototype.afterInit=function(e){e.registerCommand("startSearch",{exec:function(){var o,t,n,r,i=e.s;if(r=i.isCollapsed()?null===(t=null===(o=i.current())||void 0===o?void 0:o.parentElement)||void 0===t?void 0:t.innerText:null===(n=i.sel)||void 0===n?void 0:n.toString()){var l="https://www.google.com/search?q="+encodeURIComponent(s.trim(r));window.open(l,"_blank")}}})},o.prototype.beforeDestruct=function(e){},o}(r.Plugin);o.googleSearch=p,c.Jodit.plugins.add("google-search",p)}},e=>{"use strict";e(e.s=526)}])}));
!function(e,o){if("object"==typeof exports&&"object"==typeof module)module.exports=o();else if("function"==typeof define&&define.amd)define([],o);else{var t=o();for(var n in t)("object"==typeof exports?exports:e)[n]=t[n]}}(self,(function(){return(self.webpackChunkjodit_pro=self.webpackChunkjodit_pro||[]).push([[799],{527:e=>{e.exports='<svg width="11" height="15" viewBox="0 0 11 15" fill="none" xmlns="http://www.w3.org/2000/svg"> <path d="M10.925 7.122V14H9.747L9.462 13.164C9.044 13.4933 8.55 13.7467 7.98 13.924C7.42267 14.1013 6.82733 14.19 6.194 14.19C5.054 14.19 4.066 13.9177 3.23 13.373C2.394 12.8157 1.75433 12.024 1.311 10.998C0.867667 9.972 0.646 8.756 0.646 7.35C0.646 5.96933 0.880333 4.766 1.349 3.74C1.83033 2.714 2.50167 1.92233 3.363 1.365C4.237 0.794999 5.25667 0.509999 6.422 0.509999C7.41 0.509999 8.284 0.693666 9.044 1.061C9.804 1.42833 10.3613 1.935 10.716 2.581L9.747 3.55C9.41767 3.03067 8.968 2.638 8.398 2.372C7.84067 2.09333 7.18833 1.954 6.441 1.954C5.17433 1.954 4.18633 2.429 3.477 3.379C2.76767 4.329 2.413 5.65267 2.413 7.35C2.413 9.07267 2.755 10.4153 3.439 11.378C4.13567 12.3407 5.10467 12.822 6.346 12.822C6.92867 12.822 7.46067 12.7397 7.942 12.575C8.436 12.4103 8.854 12.1697 9.196 11.853V8.414H6.023V7.122H10.925Z" fill="black"/> </svg>'},526:(e,o,t)=>{"use strict";Object.defineProperty(o,"__esModule",{value:!0}),o.googleSearch=void 0;var n=t(1),r=t(187),i=t(12),s=t(23),l=t(305),c=t(2);i.Config.prototype.controls.google={tooltip:"Google search",icon:t(527),isDisabled:function(e){return l.isEditorEmpty(e.editor)},command:"startSearch"};var p=function(e){function o(){var o=null!==e&&e.apply(this,arguments)||this;return o.requires=["license"],o.buttons=[{name:"google",group:"search"}],o}return n.__extends(o,e),o.prototype.afterInit=function(e){e.registerCommand("startSearch",{exec:function(){var o,t,n,r,i=e.s;if(r=i.isCollapsed()?null===(t=null===(o=i.current())||void 0===o?void 0:o.parentElement)||void 0===t?void 0:t.innerText:null===(n=i.sel)||void 0===n?void 0:n.toString()){var l="https://www.google.com/search?q="+encodeURIComponent(s.trim(r));window.open(l,"_blank")}}})},o.prototype.beforeDestruct=function(e){},o}(r.Plugin);o.googleSearch=p,c.Jodit.plugins.add("google-search",p)}},e=>{"use strict";return e(e.s=526)}])}));
/*!
* jodit-pro - PRO Version of Jodit Editor
* Author: Chupurnov Valeriy <chupurnov@gmail.com>
* Version: v1.0.45
* Version: v1.0.46
* Url: https://xdsoft.net/jodit/pro/

@@ -10,2 +10,2 @@ * License(s): SEE LICENSE IN LICENSE.md

((e,o)=>{if("object"==typeof exports&&"object"==typeof module)module.exports=o();else if("function"==typeof define&&define.amd)define([],o);else{var t=o();for(var s in t)("object"==typeof exports?exports:e)[s]=t[s]}})(self,(function(){return(self.webpackChunkjodit_pro=self.webpackChunkjodit_pro||[]).push([[799],{206(e){e.exports='<svg width="11" height="15" viewBox="0 0 11 15" fill="none" xmlns="http://www.w3.org/2000/svg"> <path d="M10.925 7.122V14H9.747L9.462 13.164C9.044 13.4933 8.55 13.7467 7.98 13.924C7.42267 14.1013 6.82733 14.19 6.194 14.19C5.054 14.19 4.066 13.9177 3.23 13.373C2.394 12.8157 1.75433 12.024 1.311 10.998C0.867667 9.972 0.646 8.756 0.646 7.35C0.646 5.96933 0.880333 4.766 1.349 3.74C1.83033 2.714 2.50167 1.92233 3.363 1.365C4.237 0.794999 5.25667 0.509999 6.422 0.509999C7.41 0.509999 8.284 0.693666 9.044 1.061C9.804 1.42833 10.3613 1.935 10.716 2.581L9.747 3.55C9.41767 3.03067 8.968 2.638 8.398 2.372C7.84067 2.09333 7.18833 1.954 6.441 1.954C5.17433 1.954 4.18633 2.429 3.477 3.379C2.76767 4.329 2.413 5.65267 2.413 7.35C2.413 9.07267 2.755 10.4153 3.439 11.378C4.13567 12.3407 5.10467 12.822 6.346 12.822C6.92867 12.822 7.46067 12.7397 7.942 12.575C8.436 12.4103 8.854 12.1697 9.196 11.853V8.414H6.023V7.122H10.925Z" fill="black"/> </svg>'},205(e,o,t){"use strict";t.r(o),t.d(o,{googleSearch:()=>c});var s=t(56),r=t(2),n=t(10),i=t(85),l=t(1);r.D.prototype.controls.google={tooltip:"Google search",icon:t(206),isDisabled(e){return(0,i.u)(e.editor)},command:"startSearch"};class c extends s.S{constructor(){super(...arguments),this.requires=["license"],this.buttons=[{name:"google",group:"search"}]}afterInit(e){e.registerCommand("startSearch",{exec(){var o,t,s;let r;const{s:i}=e;if(r=i.isCollapsed()?null===(t=null===(o=i.current())||void 0===o?void 0:o.parentElement)||void 0===t?void 0:t.innerText:null===(s=i.sel)||void 0===s?void 0:""+s,r){const e="https://www.google.com/search?q="+encodeURIComponent((0,n.trim)(r));window.open(e,"_blank")}}})}beforeDestruct(e){}}l.Jodit.plugins.add("google-search",c)}},e=>{"use strict";e(e.s=205)}])}));
((e,o)=>{if("object"==typeof exports&&"object"==typeof module)module.exports=o();else if("function"==typeof define&&define.amd)define([],o);else{var t=o();for(var r in t)("object"==typeof exports?exports:e)[r]=t[r]}})(self,(function(){return(self.webpackChunkjodit_pro=self.webpackChunkjodit_pro||[]).push([[799],{206(e){e.exports='<svg width="11" height="15" viewBox="0 0 11 15" fill="none" xmlns="http://www.w3.org/2000/svg"> <path d="M10.925 7.122V14H9.747L9.462 13.164C9.044 13.4933 8.55 13.7467 7.98 13.924C7.42267 14.1013 6.82733 14.19 6.194 14.19C5.054 14.19 4.066 13.9177 3.23 13.373C2.394 12.8157 1.75433 12.024 1.311 10.998C0.867667 9.972 0.646 8.756 0.646 7.35C0.646 5.96933 0.880333 4.766 1.349 3.74C1.83033 2.714 2.50167 1.92233 3.363 1.365C4.237 0.794999 5.25667 0.509999 6.422 0.509999C7.41 0.509999 8.284 0.693666 9.044 1.061C9.804 1.42833 10.3613 1.935 10.716 2.581L9.747 3.55C9.41767 3.03067 8.968 2.638 8.398 2.372C7.84067 2.09333 7.18833 1.954 6.441 1.954C5.17433 1.954 4.18633 2.429 3.477 3.379C2.76767 4.329 2.413 5.65267 2.413 7.35C2.413 9.07267 2.755 10.4153 3.439 11.378C4.13567 12.3407 5.10467 12.822 6.346 12.822C6.92867 12.822 7.46067 12.7397 7.942 12.575C8.436 12.4103 8.854 12.1697 9.196 11.853V8.414H6.023V7.122H10.925Z" fill="black"/> </svg>'},205(e,o,t){"use strict";t.r(o),t.d(o,{googleSearch:()=>c});var r=t(56),s=t(2),n=t(10),i=t(85),l=t(1);s.D.prototype.controls.google={tooltip:"Google search",icon:t(206),isDisabled(e){return(0,i.u)(e.editor)},command:"startSearch"};class c extends r.S{constructor(){super(...arguments),this.requires=["license"],this.buttons=[{name:"google",group:"search"}]}afterInit(e){e.registerCommand("startSearch",{exec(){var o,t,r;let s;const{s:i}=e;if(s=i.isCollapsed()?null===(t=null===(o=i.current())||void 0===o?void 0:o.parentElement)||void 0===t?void 0:t.innerText:null===(r=i.sel)||void 0===r?void 0:""+r,s){const e="https://www.google.com/search?q="+encodeURIComponent((0,n.trim)(s));window.open(e,"_blank")}}})}beforeDestruct(e){}}l.Jodit.plugins.add("google-search",c)}},e=>{"use strict";return e(e.s=205)}])}));
/*!
* jodit-pro - PRO Version of Jodit Editor
* Author: Chupurnov Valeriy <chupurnov@gmail.com>
* Version: v1.0.45
* Version: v1.0.46
* Url: https://xdsoft.net/jodit/pro/

@@ -10,2 +10,2 @@ * License(s): SEE LICENSE IN LICENSE.md

!function(t,e){if("object"==typeof exports&&"object"==typeof module)module.exports=e();else if("function"==typeof define&&define.amd)define([],e);else{var o=e();for(var s in o)("object"==typeof exports?exports:t)[s]=o[s]}}(self,(function(){return(self.webpackChunkjodit_pro=self.webpackChunkjodit_pro||[]).push([[283],{543:t=>{t.exports='<svg viewBox="0 0 20 20" xmlns="http://www.w3.org/2000/svg"> <path d="M0 6c0-1.1.9-2 2-2h16a2 2 0 0 1 2 2v8a2 2 0 0 1-2 2H2a2 2 0 0 1-2-2V6zm2 0v2h2V6H2zm1 3v2h2V9H3zm-1 3v2h2v-2H2zm3 0v2h10v-2H5zm11 0v2h2v-2h-2zM6 9v2h2V9H6zm3 0v2h2V9H9zm3 0v2h2V9h-2zm3 0v2h2V9h-2zM5 6v2h2V6H5zm3 0v2h2V6H8zm3 0v2h2V6h-2zm3 0v2h4V6h-4z"/> </svg>'},537:t=>{t.exports='<?xml version="1.0" ?><svg viewBox="0 0 20 20" xmlns="http://www.w3.org/2000/svg"><path d="M0 10l7-7h13v14H7l-7-7zm14.41 0l2.13-2.12-1.42-1.42L13 8.6l-2.12-2.13-1.42 1.42L11.6 10l-2.13 2.12 1.42 1.42L13 11.4l2.12 2.13 1.42-1.42L14.4 10z"/></svg>'},539:t=>{t.exports='<svg viewBox="0 0 30 29" xmlns="http://www.w3.org/2000/svg"> <path d="M15 0.5L30 15.2625H22V24H8V15.2625H0L15 0.5Z"/> <rect x="8" y="26" width="14" height="3"/> </svg>'},540:t=>{t.exports='<svg xmlns=\'http://www.w3.org/2000/svg\' viewBox="0 0 24 24" > <circle cy="12" cx="12" r="2.2"/> <circle cy="12" cx="5" r="2.2"/> <circle cy="12" cx="19" r="2.2"/> </svg>'},538:t=>{t.exports='<svg viewBox="0 0 30 29" xmlns="http://www.w3.org/2000/svg"> <path d="M15 0.5L30 15.2625H22V29H8V15.2625H0L15 0.5Z"/> </svg>'},541:t=>{t.exports='<svg viewBox="0 0 48 48" xmlns="http://www.w3.org/2000/svg"> <path d="M23.17 14.83l7.17 7.17h-28.34v4h28.34l-7.17 7.17 2.83 2.83 12-12-12-12-2.83 2.83zm16.83-2.83v24h4v-24h-4z"/> </svg>'},536:(t,e,o)=>{"use strict";o.r(e)},542:(t,e,o)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});var s=o(12);s.Config.prototype.keyboard={defaultLayoutSet:"en",showLayoutSwitcher:!0,extraKeyGroup:"other",extraKeyButtons:[],delayKeyRepeat:350,periodKeyRepeat:100,layoutList:{en:{title:"English",keys:[["` ~ ±","1 ! §","2 @","3 #","4 $","5 %","6 ^","7 &","8 *","9 (","0 )","- _","= +","Backspace"],["Tab","q Q","w W","e E","r R","t T","y Y","u U","i I","o O","p P","[ {","] }","\\ |"],["Caps","a A","s S","d D","f F","g G","h H","j J","k K","l L","; :","' \"","Enter"],["Shift","z Z","x X","c C","v V","b B","n N","m M",", <",". >","/ ?","Shift"],["Options","Space","Options"]]},es:{title:"Español",keys:[["º ` ~","1 ! §","2 @","3 #","4 $","5 %","6 ^","7 &","8 *","9 (","0 )","- _ |","¡ = +","Backspace"],["Tab","q Q","w W","e E","r R","t T","y Y","u U","i I","o O","p P","[ {","] }","ç Ç \\"],["Caps","a A","s S","d D","f F","g G","h H","j J","k K","l L","ñ Ñ ; :","' \"","Enter"],["Shift","z Z","x X","c C","v V","b B","n N","m M",", <",". >","/ ?","Shift"],["Options","Space","Options"]]},de:{title:"Deutsch",keys:[["` ~ ±","1 ! §","2 @","3 #","4 $","5 %","6 ^","7 &","8 * :","9 ( {","0 ) }","- _","= +","Backspace"],["Tab","q Q","w W","e E","r R","t T","z Z","u U","i I","o O","p P","ü Ü [","] }","\\ |"],["Caps","a A","s S","d D","f F","g G","h H","j J","k K","l L","ö Ö ;","ä Ä ' \"","Enter"],["Shift","y Y","x X","c C","v V","b B","n N","m M",", <",". >","/ ?","Shift"],["Options","Space","Options"]]},ru:{title:"Русский",keys:[["` ~ ±","1 ! §",'2 @ "',"3 # :","4 $ <","5 % >","6 ^","7 &","8 *","9 (","0 )","- _","= +","Backspace"],["Tab","й Й","ц Ц","у У","к К","е Е","н Н","г Г","ш Ш","щ Щ","з З","х Х [","ъ ] {","\\ | }"],["Caps","ф Ф","ы Ы","в В","а А","п П","р Р","о О","л Л","д Д","ж Ж ;","э Э '","Enter"],["Shift","я Я","ч Ч","с С","м М","и И","т Т","ь Ь","б Б ,","ю Ю .","/ ?","Shift"],["Options","Space","Options"]]},tr:{title:"Türkçe",keys:[['" é` ~',"1 ! §",'2 @ "',"3 # :","4 $ <","5 % >","6 ^ ±","7 &","8 *","9 ( {","0 ) }","- _ [","= + ]","Backspace"],["Tab","q Q","w W","e E","r R","t T","y Y","u U","ı I","o O","p P","ğ Ğ","ü Ü",", \\ |"],["Caps","a A","s S","d D","f F","g G","h H","j J","k K","l L","ş Ş","i̇ İ","Enter"],["Shift","z Z","x X","c C","v V","b B","n N","m M","ö Ö <","ç Ç >",". / ?","Shift"],["Options","Space","Options"]]},iw:{title:"Hebrew",keys:[["` ~ ±","1 ! §","2 @","3 #","4 $","5 %","6 ^","7 &","8 *","9 (","0 )","- _","= +","Backspace"],["Tab","/ q Q","' w W","ק e E","ר r R","א t T","ט y Y","ו u U","ן i I","ם o O","פ p P","[ {","] }","\\ |"],["Caps","ש a A","ד s S","ג d D","כ f F","ע g G","י h H","ח j J","ל k K","ך l L","ף ; :","' \"","Enter"],["Shift","ז z Z","ס x X","ב c C","ה v V","נ b B","מ n N","צ m M",", <",". >","/ ?","Shift"],["Options","Space","Options"]]},tata:{title:"Tata",keys:[["һ Һ` ~","1 ! §",'2 @ "',"3 # :","4 $ <","5 % >","6 ^ ±","7 &","8 *","9 ( {","0 )","- _","= +","Backspace"],["Tab","й Й","ө Ө","у У","к К","е Е","н Н","г Г","ш Ш","ә Ә","з З","х Х [","ү Ү ]","\\ | }"],["Caps","ф Ф","ы Ы","в В","а А","п П","р Р","о О","л Л","д Д","ң Ң ;","э Э '","Enter"],["Shift","я Я","ч Ч","с С","м М","и И","т Т","җ Җ","б Б ,","ю Ю .","ґ Ґ /","Shift"],["Options","Space","Options"]]}},layoutSwitchList:["en","es","de","ru","tr","iw","tata"],keySize:32,layout:[[1,1,1,1,1,1,1,1,1,1,1,1,1,2],[1.5,1,1,1,1,1,1,1,1,1,1,1,1,1.5],[1.8,1,1,1,1,1,1,1,1,1,1,1,2.2],[2.5,1,1,1,1,1,1,1,1,1,1,2.5],[3.5,9,3.5]]},s.Config.prototype.controls.keyboard={tooltip:"Keyboard",icon:o(543),isActive:function(t){return Boolean(t.e.fire("isKeyboardOpened"))},command:"toggleKeyboard"},s.Config.prototype.controls.extraKeyboardButtons={}},534:(t,e,o)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.keyboard=void 0;var s=o(1),r=o(187),a=o(2),i=o(535),n=o(103);o(542);var p=o(14),c=o(79),h=o(38),u=o(12),y=function(t){function e(e){var o=t.call(this,e)||this;o.hasStyle=!a.Jodit.fatMode,o.requires=["license"],o.buttons=[{group:"insert",name:"keyboard"}];var s=e.o.keyboard,r=s.extraKeyButtons,i=s.extraKeyGroup;return r.length&&r.forEach((function(t,o){var s=h.isString(t)?t:t.key,r=h.isString(t)||!t.hotkeys?["ctrl+"+(o+1)]:t.hotkeys;e.registerButton({name:"extraKeyboardButtons."+s,group:i}),u.Config.defaultOptions.controls.extraKeyboardButtons[s]={name:s,tooltip:s,args:[s],hotkeys:r,command:"insertChar"}})),o}return s.__extends(e,t),e.prototype.afterInit=function(t){var e=this;t.registerCommand("toggleKeyboard",this.toggleKeyboard).registerCommand("insertChar",this.insertChar),t.e.on("isKeyboardOpened",(function(){var t;return null===(t=e.__keyboard)||void 0===t?void 0:t.isOpened}))},e.prototype.insertChar=function(t,e,o){this.j.s.insertNode(this.j.createInside.text(o))},e.prototype.toggleKeyboard=function(){if(!this.__keyboard){this.__keyboard=new p.Dialog({toolbarButtonSize:"tiny"});var t=new i.UIKeyboard(this.j);this.__keyboard.setMod("slim",!0).setContent(t);var e=this.j.o.keyboard,o=e.layoutList;if(e.showLayoutSwitcher){var s=new c.UISelect(this.__keyboard,{value:t.state.currentLayout,options:e.layoutSwitchList.map((function(t){var e,s;return{text:null!==(s=null===(e=o[t])||void 0===e?void 0:e.title)&&void 0!==s?s:t,value:t}})),onChange:function(e){t.state.currentLayout=e}});s.setMod("size","tiny").setMod("width","auto").setMod("variant","outline"),this.__keyboard.setHeader(s)}}this.__keyboard.isOpened?this.__keyboard.close():this.__keyboard.open()},e.prototype.beforeDestruct=function(t){var e;null===(e=this.__keyboard)||void 0===e||e.destruct()},s.__decorate([n.autobind],e.prototype,"insertChar",null),s.__decorate([n.autobind],e.prototype,"toggleKeyboard",null),e}(r.Plugin);e.keyboard=y,a.Jodit.plugins.add("keyboard",y)},535:(t,e,o)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.UIKeyboard=void 0;var s=o(1);o(536);var r=o(79),a=o(103),i=o(24),n=o(13),p=o(112),c=function(t){function e(e){var o=t.call(this,e)||this;return o.state={caps:!1,shift:!1,options:!1,currentLayout:o.j.o.keyboard.defaultLayoutSet},o._keys=o.getElms("key"),o.pressed=!1,o.reKeyDownTimeout=0,o.onStateChange(),o}var c;return s.__extends(e,t),c=e,e.prototype.className=function(){return"UIKeyboard"},e.prototype.render=function(){var t=this.j.options.keyboard,e=t.layout,o=t.keySize,s=e.length;return"<div>"+function(){for(var t=[],r=0;s>r;r+=1){for(var a=[],i=0;e[r].length>i;i+=1)a.push('<div style="width:'+o*e[r][i]+"px;height:"+o+'px;" class="&__key"></div>');t.push("<div class='&__row'>"+a.join("\n")+"</div>")}return t.join("\n")}()+"</div>"},e.prototype.onStateChange=function(){for(var t=this.state,e=t.options,o=t.shift,s=t.caps,r=this.j.o.keyboard.layoutList[t.currentLayout].keys,a=0,i=0;r.length>i;i+=1)for(var n=0;r[i].length>n;n+=1){var p=r[i][n].split(" "),h=p[0];o&&(h=p[1]),!o&&s&&p[1]&&c.isLetter(p[0])&&(h=p[1]),e&&(h=p[2]),this.setKeyValue(a,null!=h?h:p[0]),a+=1}},e.isLetter=function(t){return t.toLowerCase()!==t.toUpperCase()},e.prototype.setKeyValue=function(t,e){var o=this._keys[t];if(o){var s=!1,r=this.state,a=r.options,n=r.shift,p=r.caps;switch(e){case"Caps":s=p;break;case"Options":s=a;break;case"Shift":s=n}o.innerHTML=c.decorate(e),o.classList.toggle(this.getFullElName("key","active",!0),s),i.attr(o,"-key",e)}},e.prototype.onKeyUp=function(){this.pressed&&this.stopPress()},e.prototype.onReady=function(){this.j.e.on(this.getElms("key"),"mouseenter",this.stopPress)},e.prototype.stopPress=function(){var t=this;this.pressed&&(this.pressed=!1,this.j.async.clearTimeout(this.reKeyDownTimeout),this._keys.forEach((function(e){e.classList.remove(t.getFullElName("key","pressed",!0))})))},e.prototype.onKeyDown=function(t,e){var o=this;void 0===e&&(e=0);var s=t.target;if(!s||!s.classList.contains(this.getFullElName("key")))return!1;this.pressed=!0,s.classList.add(this.getFullElName("key","pressed",!0));var r=i.attr(s,"-key");switch(r){case"Caps":this.state.caps=!this.state.caps;break;case"Shift":this.state.shift=!this.state.shift;break;case"Options":this.state.options=!this.state.options;break;case"Enter":case"Backspace":this.j.e.fire("keydown",{key:r,preventDefault:function(){}});break;case"Space":case"Tab":this.j.s.insertNode(this.j.createInside.text(n.NBSP_SPACE));break;default:this.state.shift&&(this.state.shift=!1),r&&this.j.s.insertNode(this.j.createInside.text(r))}var a=this.j.o.keyboard,p=a.periodKeyRepeat;return this.reKeyDownTimeout=this.j.async.setTimeout((function(){return o.onKeyDown(t,p)}),e||a.delayKeyRepeat),!1},e.decorate=function(t){switch(t){case"Space":return"";case"Enter":return r.Icon.get("enter");case"Backspace":return o(537);case"Shift":return o(538);case"Caps":return o(539);case"Options":return o(540);case"Tab":return o(541);default:return t}},s.__decorate([a.watch(["state.currentLayout","state.options","state.shift","state.caps"])],e.prototype,"onStateChange",null),s.__decorate([a.watch(["ow:mouseup"])],e.prototype,"onKeyUp",null),s.__decorate([a.hook("ready")],e.prototype,"onReady",null),s.__decorate([p.default],e.prototype,"stopPress",null),s.__decorate([a.watch(["container:mousedown"],["container:touchstart"])],e.prototype,"onKeyDown",null),c=s.__decorate([a.component],e)}(r.UIElement);e.UIKeyboard=c}},t=>{"use strict";t(t.s=534)}])}));
!function(t,e){if("object"==typeof exports&&"object"==typeof module)module.exports=e();else if("function"==typeof define&&define.amd)define([],e);else{var o=e();for(var s in o)("object"==typeof exports?exports:t)[s]=o[s]}}(self,(function(){return(self.webpackChunkjodit_pro=self.webpackChunkjodit_pro||[]).push([[283],{543:t=>{t.exports='<svg viewBox="0 0 20 20" xmlns="http://www.w3.org/2000/svg"> <path d="M0 6c0-1.1.9-2 2-2h16a2 2 0 0 1 2 2v8a2 2 0 0 1-2 2H2a2 2 0 0 1-2-2V6zm2 0v2h2V6H2zm1 3v2h2V9H3zm-1 3v2h2v-2H2zm3 0v2h10v-2H5zm11 0v2h2v-2h-2zM6 9v2h2V9H6zm3 0v2h2V9H9zm3 0v2h2V9h-2zm3 0v2h2V9h-2zM5 6v2h2V6H5zm3 0v2h2V6H8zm3 0v2h2V6h-2zm3 0v2h4V6h-4z"/> </svg>'},537:t=>{t.exports='<?xml version="1.0" ?><svg viewBox="0 0 20 20" xmlns="http://www.w3.org/2000/svg"><path d="M0 10l7-7h13v14H7l-7-7zm14.41 0l2.13-2.12-1.42-1.42L13 8.6l-2.12-2.13-1.42 1.42L11.6 10l-2.13 2.12 1.42 1.42L13 11.4l2.12 2.13 1.42-1.42L14.4 10z"/></svg>'},539:t=>{t.exports='<svg viewBox="0 0 30 29" xmlns="http://www.w3.org/2000/svg"> <path d="M15 0.5L30 15.2625H22V24H8V15.2625H0L15 0.5Z"/> <rect x="8" y="26" width="14" height="3"/> </svg>'},540:t=>{t.exports='<svg xmlns=\'http://www.w3.org/2000/svg\' viewBox="0 0 24 24" > <circle cy="12" cx="12" r="2.2"/> <circle cy="12" cx="5" r="2.2"/> <circle cy="12" cx="19" r="2.2"/> </svg>'},538:t=>{t.exports='<svg viewBox="0 0 30 29" xmlns="http://www.w3.org/2000/svg"> <path d="M15 0.5L30 15.2625H22V29H8V15.2625H0L15 0.5Z"/> </svg>'},541:t=>{t.exports='<svg viewBox="0 0 48 48" xmlns="http://www.w3.org/2000/svg"> <path d="M23.17 14.83l7.17 7.17h-28.34v4h28.34l-7.17 7.17 2.83 2.83 12-12-12-12-2.83 2.83zm16.83-2.83v24h4v-24h-4z"/> </svg>'},536:(t,e,o)=>{"use strict";o.r(e)},542:(t,e,o)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0});var s=o(12);s.Config.prototype.keyboard={defaultLayoutSet:"en",showLayoutSwitcher:!0,extraKeyGroup:"other",extraKeyButtons:[],delayKeyRepeat:350,periodKeyRepeat:100,layoutList:{en:{title:"English",keys:[["` ~ ±","1 ! §","2 @","3 #","4 $","5 %","6 ^","7 &","8 *","9 (","0 )","- _","= +","Backspace"],["Tab","q Q","w W","e E","r R","t T","y Y","u U","i I","o O","p P","[ {","] }","\\ |"],["Caps","a A","s S","d D","f F","g G","h H","j J","k K","l L","; :","' \"","Enter"],["Shift","z Z","x X","c C","v V","b B","n N","m M",", <",". >","/ ?","Shift"],["Options","Space","Options"]]},es:{title:"Español",keys:[["º ` ~","1 ! §","2 @","3 #","4 $","5 %","6 ^","7 &","8 *","9 (","0 )","- _ |","¡ = +","Backspace"],["Tab","q Q","w W","e E","r R","t T","y Y","u U","i I","o O","p P","[ {","] }","ç Ç \\"],["Caps","a A","s S","d D","f F","g G","h H","j J","k K","l L","ñ Ñ ; :","' \"","Enter"],["Shift","z Z","x X","c C","v V","b B","n N","m M",", <",". >","/ ?","Shift"],["Options","Space","Options"]]},de:{title:"Deutsch",keys:[["` ~ ±","1 ! §","2 @","3 #","4 $","5 %","6 ^","7 &","8 * :","9 ( {","0 ) }","- _","= +","Backspace"],["Tab","q Q","w W","e E","r R","t T","z Z","u U","i I","o O","p P","ü Ü [","] }","\\ |"],["Caps","a A","s S","d D","f F","g G","h H","j J","k K","l L","ö Ö ;","ä Ä ' \"","Enter"],["Shift","y Y","x X","c C","v V","b B","n N","m M",", <",". >","/ ?","Shift"],["Options","Space","Options"]]},ru:{title:"Русский",keys:[["` ~ ±","1 ! §",'2 @ "',"3 # :","4 $ <","5 % >","6 ^","7 &","8 *","9 (","0 )","- _","= +","Backspace"],["Tab","й Й","ц Ц","у У","к К","е Е","н Н","г Г","ш Ш","щ Щ","з З","х Х [","ъ ] {","\\ | }"],["Caps","ф Ф","ы Ы","в В","а А","п П","р Р","о О","л Л","д Д","ж Ж ;","э Э '","Enter"],["Shift","я Я","ч Ч","с С","м М","и И","т Т","ь Ь","б Б ,","ю Ю .","/ ?","Shift"],["Options","Space","Options"]]},tr:{title:"Türkçe",keys:[['" é` ~',"1 ! §",'2 @ "',"3 # :","4 $ <","5 % >","6 ^ ±","7 &","8 *","9 ( {","0 ) }","- _ [","= + ]","Backspace"],["Tab","q Q","w W","e E","r R","t T","y Y","u U","ı I","o O","p P","ğ Ğ","ü Ü",", \\ |"],["Caps","a A","s S","d D","f F","g G","h H","j J","k K","l L","ş Ş","i̇ İ","Enter"],["Shift","z Z","x X","c C","v V","b B","n N","m M","ö Ö <","ç Ç >",". / ?","Shift"],["Options","Space","Options"]]},iw:{title:"Hebrew",keys:[["` ~ ±","1 ! §","2 @","3 #","4 $","5 %","6 ^","7 &","8 *","9 (","0 )","- _","= +","Backspace"],["Tab","/ q Q","' w W","ק e E","ר r R","א t T","ט y Y","ו u U","ן i I","ם o O","פ p P","[ {","] }","\\ |"],["Caps","ש a A","ד s S","ג d D","כ f F","ע g G","י h H","ח j J","ל k K","ך l L","ף ; :","' \"","Enter"],["Shift","ז z Z","ס x X","ב c C","ה v V","נ b B","מ n N","צ m M",", <",". >","/ ?","Shift"],["Options","Space","Options"]]},tata:{title:"Tata",keys:[["һ Һ` ~","1 ! §",'2 @ "',"3 # :","4 $ <","5 % >","6 ^ ±","7 &","8 *","9 ( {","0 )","- _","= +","Backspace"],["Tab","й Й","ө Ө","у У","к К","е Е","н Н","г Г","ш Ш","ә Ә","з З","х Х [","ү Ү ]","\\ | }"],["Caps","ф Ф","ы Ы","в В","а А","п П","р Р","о О","л Л","д Д","ң Ң ;","э Э '","Enter"],["Shift","я Я","ч Ч","с С","м М","и И","т Т","җ Җ","б Б ,","ю Ю .","ґ Ґ /","Shift"],["Options","Space","Options"]]}},layoutSwitchList:["en","es","de","ru","tr","iw","tata"],keySize:32,layout:[[1,1,1,1,1,1,1,1,1,1,1,1,1,2],[1.5,1,1,1,1,1,1,1,1,1,1,1,1,1.5],[1.8,1,1,1,1,1,1,1,1,1,1,1,2.2],[2.5,1,1,1,1,1,1,1,1,1,1,2.5],[3.5,9,3.5]]},s.Config.prototype.controls.keyboard={tooltip:"Keyboard",icon:o(543),isActive:function(t){return Boolean(t.e.fire("isKeyboardOpened"))},command:"toggleKeyboard"},s.Config.prototype.controls.extraKeyboardButtons={}},534:(t,e,o)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.keyboard=void 0;var s=o(1),r=o(187),a=o(2),i=o(535),n=o(103);o(542);var p=o(14),c=o(79),h=o(38),u=o(12),y=function(t){function e(e){var o=t.call(this,e)||this;o.hasStyle=!a.Jodit.fatMode,o.requires=["license"],o.buttons=[{group:"insert",name:"keyboard"}];var s=e.o.keyboard,r=s.extraKeyButtons,i=s.extraKeyGroup;return r.length&&r.forEach((function(t,o){var s=h.isString(t)?t:t.key,r=h.isString(t)||!t.hotkeys?["ctrl+"+(o+1)]:t.hotkeys;e.registerButton({name:"extraKeyboardButtons."+s,group:i}),u.Config.defaultOptions.controls.extraKeyboardButtons[s]={name:s,tooltip:s,args:[s],hotkeys:r,command:"insertChar"}})),o}return s.__extends(e,t),e.prototype.afterInit=function(t){var e=this;t.registerCommand("toggleKeyboard",this.toggleKeyboard).registerCommand("insertChar",this.insertChar),t.e.on("isKeyboardOpened",(function(){var t;return null===(t=e.__keyboard)||void 0===t?void 0:t.isOpened}))},e.prototype.insertChar=function(t,e,o){this.j.s.insertNode(this.j.createInside.text(o))},e.prototype.toggleKeyboard=function(){if(!this.__keyboard){this.__keyboard=new p.Dialog({toolbarButtonSize:"tiny"});var t=new i.UIKeyboard(this.j);this.__keyboard.setMod("slim",!0).setContent(t);var e=this.j.o.keyboard,o=e.layoutList;if(e.showLayoutSwitcher){var s=new c.UISelect(this.__keyboard,{value:t.state.currentLayout,options:e.layoutSwitchList.map((function(t){var e,s;return{text:null!==(s=null===(e=o[t])||void 0===e?void 0:e.title)&&void 0!==s?s:t,value:t}})),onChange:function(e){t.state.currentLayout=e}});s.setMod("size","tiny").setMod("width","auto").setMod("variant","outline"),this.__keyboard.setHeader(s)}}this.__keyboard.isOpened?this.__keyboard.close():this.__keyboard.open()},e.prototype.beforeDestruct=function(t){var e;null===(e=this.__keyboard)||void 0===e||e.destruct()},s.__decorate([n.autobind],e.prototype,"insertChar",null),s.__decorate([n.autobind],e.prototype,"toggleKeyboard",null),e}(r.Plugin);e.keyboard=y,a.Jodit.plugins.add("keyboard",y)},535:(t,e,o)=>{"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.UIKeyboard=void 0;var s=o(1);o(536);var r=o(79),a=o(103),i=o(24),n=o(13),p=o(112),c=function(t){function e(e){var o=t.call(this,e)||this;return o.state={caps:!1,shift:!1,options:!1,currentLayout:o.j.o.keyboard.defaultLayoutSet},o._keys=o.getElms("key"),o.pressed=!1,o.reKeyDownTimeout=0,o.onStateChange(),o}var c;return s.__extends(e,t),c=e,e.prototype.className=function(){return"UIKeyboard"},e.prototype.render=function(){var t=this.j.options.keyboard,e=t.layout,o=t.keySize,s=e.length;return"<div>"+function(){for(var t=[],r=0;s>r;r+=1){for(var a=[],i=0;e[r].length>i;i+=1)a.push('<div style="width:'+o*e[r][i]+"px;height:"+o+'px;" class="&__key"></div>');t.push("<div class='&__row'>"+a.join("\n")+"</div>")}return t.join("\n")}()+"</div>"},e.prototype.onStateChange=function(){for(var t=this.state,e=t.options,o=t.shift,s=t.caps,r=this.j.o.keyboard.layoutList[t.currentLayout].keys,a=0,i=0;r.length>i;i+=1)for(var n=0;r[i].length>n;n+=1){var p=r[i][n].split(" "),h=p[0];o&&(h=p[1]),!o&&s&&p[1]&&c.isLetter(p[0])&&(h=p[1]),e&&(h=p[2]),this.setKeyValue(a,null!=h?h:p[0]),a+=1}},e.isLetter=function(t){return t.toLowerCase()!==t.toUpperCase()},e.prototype.setKeyValue=function(t,e){var o=this._keys[t];if(o){var s=!1,r=this.state,a=r.options,n=r.shift,p=r.caps;switch(e){case"Caps":s=p;break;case"Options":s=a;break;case"Shift":s=n}o.innerHTML=c.decorate(e),o.classList.toggle(this.getFullElName("key","active",!0),s),i.attr(o,"-key",e)}},e.prototype.onKeyUp=function(){this.pressed&&this.stopPress()},e.prototype.onReady=function(){this.j.e.on(this.getElms("key"),"mouseenter",this.stopPress)},e.prototype.stopPress=function(){var t=this;this.pressed&&(this.pressed=!1,this.j.async.clearTimeout(this.reKeyDownTimeout),this._keys.forEach((function(e){e.classList.remove(t.getFullElName("key","pressed",!0))})))},e.prototype.onKeyDown=function(t,e){var o=this;void 0===e&&(e=0);var s=t.target;if(!s||!s.classList.contains(this.getFullElName("key")))return!1;this.pressed=!0,s.classList.add(this.getFullElName("key","pressed",!0));var r=i.attr(s,"-key");switch(r){case"Caps":this.state.caps=!this.state.caps;break;case"Shift":this.state.shift=!this.state.shift;break;case"Options":this.state.options=!this.state.options;break;case"Enter":case"Backspace":this.j.e.fire("keydown",{key:r,preventDefault:function(){}});break;case"Space":case"Tab":this.j.s.insertNode(this.j.createInside.text(n.NBSP_SPACE));break;default:this.state.shift&&(this.state.shift=!1),r&&this.j.s.insertNode(this.j.createInside.text(r))}var a=this.j.o.keyboard,p=a.periodKeyRepeat;return this.reKeyDownTimeout=this.j.async.setTimeout((function(){return o.onKeyDown(t,p)}),e||a.delayKeyRepeat),!1},e.decorate=function(t){switch(t){case"Space":return"";case"Enter":return r.Icon.get("enter");case"Backspace":return o(537);case"Shift":return o(538);case"Caps":return o(539);case"Options":return o(540);case"Tab":return o(541);default:return t}},s.__decorate([a.watch(["state.currentLayout","state.options","state.shift","state.caps"])],e.prototype,"onStateChange",null),s.__decorate([a.watch(["ow:mouseup"])],e.prototype,"onKeyUp",null),s.__decorate([a.hook("ready")],e.prototype,"onReady",null),s.__decorate([p.default],e.prototype,"stopPress",null),s.__decorate([a.watch(["container:mousedown"],["container:touchstart"])],e.prototype,"onKeyDown",null),c=s.__decorate([a.component],e)}(r.UIElement);e.UIKeyboard=c}},t=>{"use strict";return t(t.s=534)}])}));
/*!
* jodit-pro - PRO Version of Jodit Editor
* Author: Chupurnov Valeriy <chupurnov@gmail.com>
* Version: v1.0.45
* Version: v1.0.46
* Url: https://xdsoft.net/jodit/pro/

@@ -10,2 +10,2 @@ * License(s): SEE LICENSE IN LICENSE.md

((t,e)=>{if("object"==typeof exports&&"object"==typeof module)module.exports=e();else if("function"==typeof define&&define.amd)define([],e);else{var s=e();for(var o in s)("object"==typeof exports?exports:t)[o]=s[o]}})(self,(function(){return(self.webpackChunkjodit_pro=self.webpackChunkjodit_pro||[]).push([[283],{217(t){t.exports='<svg viewBox="0 0 20 20" xmlns="http://www.w3.org/2000/svg"> <path d="M0 6c0-1.1.9-2 2-2h16a2 2 0 0 1 2 2v8a2 2 0 0 1-2 2H2a2 2 0 0 1-2-2V6zm2 0v2h2V6H2zm1 3v2h2V9H3zm-1 3v2h2v-2H2zm3 0v2h10v-2H5zm11 0v2h2v-2h-2zM6 9v2h2V9H6zm3 0v2h2V9H9zm3 0v2h2V9h-2zm3 0v2h2V9h-2zM5 6v2h2V6H5zm3 0v2h2V6H8zm3 0v2h2V6h-2zm3 0v2h4V6h-4z"/> </svg>'},212(t){t.exports='<?xml version="1.0" ?><svg viewBox="0 0 20 20" xmlns="http://www.w3.org/2000/svg"><path d="M0 10l7-7h13v14H7l-7-7zm14.41 0l2.13-2.12-1.42-1.42L13 8.6l-2.12-2.13-1.42 1.42L11.6 10l-2.13 2.12 1.42 1.42L13 11.4l2.12 2.13 1.42-1.42L14.4 10z"/></svg>'},214(t){t.exports='<svg viewBox="0 0 30 29" xmlns="http://www.w3.org/2000/svg"> <path d="M15 0.5L30 15.2625H22V24H8V15.2625H0L15 0.5Z"/> <rect x="8" y="26" width="14" height="3"/> </svg>'},215(t){t.exports='<svg xmlns=\'http://www.w3.org/2000/svg\' viewBox="0 0 24 24" > <circle cy="12" cx="12" r="2.2"/> <circle cy="12" cx="5" r="2.2"/> <circle cy="12" cx="19" r="2.2"/> </svg>'},213(t){t.exports='<svg viewBox="0 0 30 29" xmlns="http://www.w3.org/2000/svg"> <path d="M15 0.5L30 15.2625H22V29H8V15.2625H0L15 0.5Z"/> </svg>'},216(t){t.exports='<svg viewBox="0 0 48 48" xmlns="http://www.w3.org/2000/svg"> <path d="M23.17 14.83l7.17 7.17h-28.34v4h28.34l-7.17 7.17 2.83 2.83 12-12-12-12-2.83 2.83zm16.83-2.83v24h4v-24h-4z"/> </svg>'},211(t,e,s){"use strict";s.r(e),s.d(e,{keyboard:()=>g});var o,a=s(39),r=s(56),i=s(1),n=s(27),h=s(36),p=s(11),c=s(3),l=s(37);let y=o=class extends n.u1{constructor(t){super(t),this.state={caps:!1,shift:!1,options:!1,currentLayout:this.j.o.keyboard.defaultLayoutSet},this._keys=this.getElms("key"),this.pressed=!1,this.reKeyDownTimeout=0,this.onStateChange()}className(){return"UIKeyboard"}render(){const{layout:t,keySize:e}=this.j.options.keyboard,s=t.length;return`<div>${(()=>{const o=[];for(let a=0;s>a;a+=1){const s=[];for(let o=0;t[a].length>o;o+=1)s.push(`<div style="width:${e*t[a][o]}px;height:${e}px;" class="&__key"></div>`);o.push(`<div class='&__row'>${s.join("\n")}</div>`)}return o.join("\n")})()}</div>`}onStateChange(){const{currentLayout:t,options:e,shift:s,caps:a}=this.state,{keys:r}=this.j.o.keyboard.layoutList[t];let i=0;for(let t=0;r.length>t;t+=1)for(let n=0;r[t].length>n;n+=1){const h=r[t][n].split(" ");let p=h[0];s&&(p=h[1]),!s&&a&&h[1]&&o.isLetter(h[0])&&(p=h[1]),e&&(p=h[2]),this.setKeyValue(i,null!=p?p:h[0]),i+=1}}static isLetter(t){return t.toLowerCase()!==t.toUpperCase()}setKeyValue(t,e){const s=this._keys[t];if(!s)return;let a=!1;const{options:r,shift:i,caps:n}=this.state;switch(e){case"Caps":a=n;break;case"Options":a=r;break;case"Shift":a=i}s.innerHTML=o.decorate(e),s.classList.toggle(this.getFullElName("key","active",!0),a),(0,p.Lj)(s,"-key",e)}onKeyUp(){this.pressed&&this.stopPress()}onReady(){this.j.e.on(this.getElms("key"),"mouseenter",this.stopPress)}stopPress(){this.pressed&&(this.pressed=!1,this.j.async.clearTimeout(this.reKeyDownTimeout),this._keys.forEach((t=>{t.classList.remove(this.getFullElName("key","pressed",!0))})))}onKeyDown(t,e=0){const s=t.target;if(!s||!s.classList.contains(this.getFullElName("key")))return!1;this.pressed=!0,s.classList.add(this.getFullElName("key","pressed",!0));const o=(0,p.Lj)(s,"-key");switch(o){case"Caps":this.state.caps=!this.state.caps;break;case"Shift":this.state.shift=!this.state.shift;break;case"Options":this.state.options=!this.state.options;break;case"Enter":case"Backspace":this.j.e.fire("keydown",{key:o,preventDefault(){}});break;case"Space":case"Tab":this.j.s.insertNode(this.j.createInside.text(c.NBSP_SPACE));break;default:this.state.shift&&(this.state.shift=!1),o&&this.j.s.insertNode(this.j.createInside.text(o))}const{periodKeyRepeat:a,delayKeyRepeat:r}=this.j.o.keyboard;return this.reKeyDownTimeout=this.j.async.setTimeout((()=>this.onKeyDown(t,a)),e||r),!1}static decorate(t){switch(t){case"Space":return"";case"Enter":return n.JO.get("enter");case"Backspace":return s(212);case"Shift":return s(213);case"Caps":return s(214);case"Options":return s(215);case"Tab":return s(216);default:return t}}};(0,a.gn)([(0,h.watch)(["state.currentLayout","state.options","state.shift","state.caps"])],y.prototype,"onStateChange",null),(0,a.gn)([(0,h.watch)(["ow:mouseup"])],y.prototype,"onKeyUp",null),(0,a.gn)([(0,h.hook)("ready")],y.prototype,"onReady",null),(0,a.gn)([l.ZP],y.prototype,"stopPress",null),(0,a.gn)([(0,h.watch)(["container:mousedown"],["container:touchstart"])],y.prototype,"onKeyDown",null),y=o=(0,a.gn)([h.component],y);var d=s(2);d.D.prototype.keyboard={defaultLayoutSet:"en",showLayoutSwitcher:!0,extraKeyGroup:"other",extraKeyButtons:[],delayKeyRepeat:350,periodKeyRepeat:100,layoutList:{en:{title:"English",keys:[["` ~ ±","1 ! §","2 @","3 #","4 $","5 %","6 ^","7 &","8 *","9 (","0 )","- _","= +","Backspace"],["Tab","q Q","w W","e E","r R","t T","y Y","u U","i I","o O","p P","[ {","] }","\\ |"],["Caps","a A","s S","d D","f F","g G","h H","j J","k K","l L","; :","' \"","Enter"],["Shift","z Z","x X","c C","v V","b B","n N","m M",", <",". >","/ ?","Shift"],["Options","Space","Options"]]},es:{title:"Español",keys:[["º ` ~","1 ! §","2 @","3 #","4 $","5 %","6 ^","7 &","8 *","9 (","0 )","- _ |","¡ = +","Backspace"],["Tab","q Q","w W","e E","r R","t T","y Y","u U","i I","o O","p P","[ {","] }","ç Ç \\"],["Caps","a A","s S","d D","f F","g G","h H","j J","k K","l L","ñ Ñ ; :","' \"","Enter"],["Shift","z Z","x X","c C","v V","b B","n N","m M",", <",". >","/ ?","Shift"],["Options","Space","Options"]]},de:{title:"Deutsch",keys:[["` ~ ±","1 ! §","2 @","3 #","4 $","5 %","6 ^","7 &","8 * :","9 ( {","0 ) }","- _","= +","Backspace"],["Tab","q Q","w W","e E","r R","t T","z Z","u U","i I","o O","p P","ü Ü [","] }","\\ |"],["Caps","a A","s S","d D","f F","g G","h H","j J","k K","l L","ö Ö ;","ä Ä ' \"","Enter"],["Shift","y Y","x X","c C","v V","b B","n N","m M",", <",". >","/ ?","Shift"],["Options","Space","Options"]]},ru:{title:"Русский",keys:[["` ~ ±","1 ! §",'2 @ "',"3 # :","4 $ <","5 % >","6 ^","7 &","8 *","9 (","0 )","- _","= +","Backspace"],["Tab","й Й","ц Ц","у У","к К","е Е","н Н","г Г","ш Ш","щ Щ","з З","х Х [","ъ ] {","\\ | }"],["Caps","ф Ф","ы Ы","в В","а А","п П","р Р","о О","л Л","д Д","ж Ж ;","э Э '","Enter"],["Shift","я Я","ч Ч","с С","м М","и И","т Т","ь Ь","б Б ,","ю Ю .","/ ?","Shift"],["Options","Space","Options"]]},tr:{title:"Türkçe",keys:[['" é` ~',"1 ! §",'2 @ "',"3 # :","4 $ <","5 % >","6 ^ ±","7 &","8 *","9 ( {","0 ) }","- _ [","= + ]","Backspace"],["Tab","q Q","w W","e E","r R","t T","y Y","u U","ı I","o O","p P","ğ Ğ","ü Ü",", \\ |"],["Caps","a A","s S","d D","f F","g G","h H","j J","k K","l L","ş Ş","i̇ İ","Enter"],["Shift","z Z","x X","c C","v V","b B","n N","m M","ö Ö <","ç Ç >",". / ?","Shift"],["Options","Space","Options"]]},iw:{title:"Hebrew",keys:[["` ~ ±","1 ! §","2 @","3 #","4 $","5 %","6 ^","7 &","8 *","9 (","0 )","- _","= +","Backspace"],["Tab","/ q Q","' w W","ק e E","ר r R","א t T","ט y Y","ו u U","ן i I","ם o O","פ p P","[ {","] }","\\ |"],["Caps","ש a A","ד s S","ג d D","כ f F","ע g G","י h H","ח j J","ל k K","ך l L","ף ; :","' \"","Enter"],["Shift","ז z Z","ס x X","ב c C","ה v V","נ b B","מ n N","צ m M",", <",". >","/ ?","Shift"],["Options","Space","Options"]]},tata:{title:"Tata",keys:[["һ Һ` ~","1 ! §",'2 @ "',"3 # :","4 $ <","5 % >","6 ^ ±","7 &","8 *","9 ( {","0 )","- _","= +","Backspace"],["Tab","й Й","ө Ө","у У","к К","е Е","н Н","г Г","ш Ш","ә Ә","з З","х Х [","ү Ү ]","\\ | }"],["Caps","ф Ф","ы Ы","в В","а А","п П","р Р","о О","л Л","д Д","ң Ң ;","э Э '","Enter"],["Shift","я Я","ч Ч","с С","м М","и И","т Т","җ Җ","б Б ,","ю Ю .","ґ Ґ /","Shift"],["Options","Space","Options"]]}},layoutSwitchList:["en","es","de","ru","tr","iw","tata"],keySize:32,layout:[[1,1,1,1,1,1,1,1,1,1,1,1,1,2],[1.5,1,1,1,1,1,1,1,1,1,1,1,1,1.5],[1.8,1,1,1,1,1,1,1,1,1,1,1,2.2],[2.5,1,1,1,1,1,1,1,1,1,1,2.5],[3.5,9,3.5]]},d.D.prototype.controls.keyboard={tooltip:"Keyboard",icon:s(217),isActive(t){return!!t.e.fire("isKeyboardOpened")},command:"toggleKeyboard"},d.D.prototype.controls.extraKeyboardButtons={};var u=s(4),v=s(17);class g extends r.S{constructor(t){super(t),this.hasStyle=!i.Jodit.fatMode,this.requires=["license"],this.buttons=[{group:"insert",name:"keyboard"}];const{extraKeyButtons:e,extraKeyGroup:s}=t.o.keyboard;e.length&&e.forEach(((e,o)=>{const a=(0,v.HD)(e)?e:e.key,r=(0,v.HD)(e)||!e.hotkeys?["ctrl+"+(o+1)]:e.hotkeys;t.registerButton({name:"extraKeyboardButtons."+a,group:s});const{extraKeyboardButtons:i}=d.D.defaultOptions.controls;i[a]={name:a,tooltip:a,args:[a],hotkeys:r,command:"insertChar"}}))}afterInit(t){t.registerCommand("toggleKeyboard",this.toggleKeyboard).registerCommand("insertChar",this.insertChar),t.e.on("isKeyboardOpened",(()=>{var t;return null===(t=this.__keyboard)||void 0===t?void 0:t.isOpened}))}insertChar(t,e,s){this.j.s.insertNode(this.j.createInside.text(s))}toggleKeyboard(){if(!this.__keyboard){this.__keyboard=new u.Dialog({toolbarButtonSize:"tiny"});const t=new y(this.j);this.__keyboard.setMod("slim",!0).setContent(t);const{showLayoutSwitcher:e,layoutSwitchList:s,layoutList:o}=this.j.o.keyboard;if(e){const e=new n.Cj(this.__keyboard,{value:t.state.currentLayout,options:s.map((t=>{var e,s;return{text:null!==(s=null===(e=o[t])||void 0===e?void 0:e.title)&&void 0!==s?s:t,value:t}})),onChange(e){t.state.currentLayout=e}});e.setMod("size","tiny").setMod("width","auto").setMod("variant","outline"),this.__keyboard.setHeader(e)}}this.__keyboard.isOpened?this.__keyboard.close():this.__keyboard.open()}beforeDestruct(t){var e;null===(e=this.__keyboard)||void 0===e||e.destruct()}}(0,a.gn)([h.autobind],g.prototype,"insertChar",null),(0,a.gn)([h.autobind],g.prototype,"toggleKeyboard",null),i.Jodit.plugins.add("keyboard",g)}},t=>{"use strict";t(t.s=211)}])}));
((t,e)=>{if("object"==typeof exports&&"object"==typeof module)module.exports=e();else if("function"==typeof define&&define.amd)define([],e);else{var s=e();for(var o in s)("object"==typeof exports?exports:t)[o]=s[o]}})(self,(function(){return(self.webpackChunkjodit_pro=self.webpackChunkjodit_pro||[]).push([[283],{217(t){t.exports='<svg viewBox="0 0 20 20" xmlns="http://www.w3.org/2000/svg"> <path d="M0 6c0-1.1.9-2 2-2h16a2 2 0 0 1 2 2v8a2 2 0 0 1-2 2H2a2 2 0 0 1-2-2V6zm2 0v2h2V6H2zm1 3v2h2V9H3zm-1 3v2h2v-2H2zm3 0v2h10v-2H5zm11 0v2h2v-2h-2zM6 9v2h2V9H6zm3 0v2h2V9H9zm3 0v2h2V9h-2zm3 0v2h2V9h-2zM5 6v2h2V6H5zm3 0v2h2V6H8zm3 0v2h2V6h-2zm3 0v2h4V6h-4z"/> </svg>'},212(t){t.exports='<?xml version="1.0" ?><svg viewBox="0 0 20 20" xmlns="http://www.w3.org/2000/svg"><path d="M0 10l7-7h13v14H7l-7-7zm14.41 0l2.13-2.12-1.42-1.42L13 8.6l-2.12-2.13-1.42 1.42L11.6 10l-2.13 2.12 1.42 1.42L13 11.4l2.12 2.13 1.42-1.42L14.4 10z"/></svg>'},214(t){t.exports='<svg viewBox="0 0 30 29" xmlns="http://www.w3.org/2000/svg"> <path d="M15 0.5L30 15.2625H22V24H8V15.2625H0L15 0.5Z"/> <rect x="8" y="26" width="14" height="3"/> </svg>'},215(t){t.exports='<svg xmlns=\'http://www.w3.org/2000/svg\' viewBox="0 0 24 24" > <circle cy="12" cx="12" r="2.2"/> <circle cy="12" cx="5" r="2.2"/> <circle cy="12" cx="19" r="2.2"/> </svg>'},213(t){t.exports='<svg viewBox="0 0 30 29" xmlns="http://www.w3.org/2000/svg"> <path d="M15 0.5L30 15.2625H22V29H8V15.2625H0L15 0.5Z"/> </svg>'},216(t){t.exports='<svg viewBox="0 0 48 48" xmlns="http://www.w3.org/2000/svg"> <path d="M23.17 14.83l7.17 7.17h-28.34v4h28.34l-7.17 7.17 2.83 2.83 12-12-12-12-2.83 2.83zm16.83-2.83v24h4v-24h-4z"/> </svg>'},211(t,e,s){"use strict";s.r(e),s.d(e,{keyboard:()=>g});var o,a=s(39),r=s(56),i=s(1),n=s(27),h=s(36),p=s(11),c=s(3),l=s(37);let y=o=class extends n.u1{constructor(t){super(t),this.state={caps:!1,shift:!1,options:!1,currentLayout:this.j.o.keyboard.defaultLayoutSet},this._keys=this.getElms("key"),this.pressed=!1,this.reKeyDownTimeout=0,this.onStateChange()}className(){return"UIKeyboard"}render(){const{layout:t,keySize:e}=this.j.options.keyboard,s=t.length;return`<div>${(()=>{const o=[];for(let a=0;s>a;a+=1){const s=[];for(let o=0;t[a].length>o;o+=1)s.push(`<div style="width:${e*t[a][o]}px;height:${e}px;" class="&__key"></div>`);o.push(`<div class='&__row'>${s.join("\n")}</div>`)}return o.join("\n")})()}</div>`}onStateChange(){const{currentLayout:t,options:e,shift:s,caps:a}=this.state,{keys:r}=this.j.o.keyboard.layoutList[t];let i=0;for(let t=0;r.length>t;t+=1)for(let n=0;r[t].length>n;n+=1){const h=r[t][n].split(" ");let p=h[0];s&&(p=h[1]),!s&&a&&h[1]&&o.isLetter(h[0])&&(p=h[1]),e&&(p=h[2]),this.setKeyValue(i,null!=p?p:h[0]),i+=1}}static isLetter(t){return t.toLowerCase()!==t.toUpperCase()}setKeyValue(t,e){const s=this._keys[t];if(!s)return;let a=!1;const{options:r,shift:i,caps:n}=this.state;switch(e){case"Caps":a=n;break;case"Options":a=r;break;case"Shift":a=i}s.innerHTML=o.decorate(e),s.classList.toggle(this.getFullElName("key","active",!0),a),(0,p.Lj)(s,"-key",e)}onKeyUp(){this.pressed&&this.stopPress()}onReady(){this.j.e.on(this.getElms("key"),"mouseenter",this.stopPress)}stopPress(){this.pressed&&(this.pressed=!1,this.j.async.clearTimeout(this.reKeyDownTimeout),this._keys.forEach((t=>{t.classList.remove(this.getFullElName("key","pressed",!0))})))}onKeyDown(t,e=0){const s=t.target;if(!s||!s.classList.contains(this.getFullElName("key")))return!1;this.pressed=!0,s.classList.add(this.getFullElName("key","pressed",!0));const o=(0,p.Lj)(s,"-key");switch(o){case"Caps":this.state.caps=!this.state.caps;break;case"Shift":this.state.shift=!this.state.shift;break;case"Options":this.state.options=!this.state.options;break;case"Enter":case"Backspace":this.j.e.fire("keydown",{key:o,preventDefault(){}});break;case"Space":case"Tab":this.j.s.insertNode(this.j.createInside.text(c.NBSP_SPACE));break;default:this.state.shift&&(this.state.shift=!1),o&&this.j.s.insertNode(this.j.createInside.text(o))}const{periodKeyRepeat:a,delayKeyRepeat:r}=this.j.o.keyboard;return this.reKeyDownTimeout=this.j.async.setTimeout((()=>this.onKeyDown(t,a)),e||r),!1}static decorate(t){switch(t){case"Space":return"";case"Enter":return n.JO.get("enter");case"Backspace":return s(212);case"Shift":return s(213);case"Caps":return s(214);case"Options":return s(215);case"Tab":return s(216);default:return t}}};(0,a.gn)([(0,h.watch)(["state.currentLayout","state.options","state.shift","state.caps"])],y.prototype,"onStateChange",null),(0,a.gn)([(0,h.watch)(["ow:mouseup"])],y.prototype,"onKeyUp",null),(0,a.gn)([(0,h.hook)("ready")],y.prototype,"onReady",null),(0,a.gn)([l.ZP],y.prototype,"stopPress",null),(0,a.gn)([(0,h.watch)(["container:mousedown"],["container:touchstart"])],y.prototype,"onKeyDown",null),y=o=(0,a.gn)([h.component],y);var d=s(2);d.D.prototype.keyboard={defaultLayoutSet:"en",showLayoutSwitcher:!0,extraKeyGroup:"other",extraKeyButtons:[],delayKeyRepeat:350,periodKeyRepeat:100,layoutList:{en:{title:"English",keys:[["` ~ ±","1 ! §","2 @","3 #","4 $","5 %","6 ^","7 &","8 *","9 (","0 )","- _","= +","Backspace"],["Tab","q Q","w W","e E","r R","t T","y Y","u U","i I","o O","p P","[ {","] }","\\ |"],["Caps","a A","s S","d D","f F","g G","h H","j J","k K","l L","; :","' \"","Enter"],["Shift","z Z","x X","c C","v V","b B","n N","m M",", <",". >","/ ?","Shift"],["Options","Space","Options"]]},es:{title:"Español",keys:[["º ` ~","1 ! §","2 @","3 #","4 $","5 %","6 ^","7 &","8 *","9 (","0 )","- _ |","¡ = +","Backspace"],["Tab","q Q","w W","e E","r R","t T","y Y","u U","i I","o O","p P","[ {","] }","ç Ç \\"],["Caps","a A","s S","d D","f F","g G","h H","j J","k K","l L","ñ Ñ ; :","' \"","Enter"],["Shift","z Z","x X","c C","v V","b B","n N","m M",", <",". >","/ ?","Shift"],["Options","Space","Options"]]},de:{title:"Deutsch",keys:[["` ~ ±","1 ! §","2 @","3 #","4 $","5 %","6 ^","7 &","8 * :","9 ( {","0 ) }","- _","= +","Backspace"],["Tab","q Q","w W","e E","r R","t T","z Z","u U","i I","o O","p P","ü Ü [","] }","\\ |"],["Caps","a A","s S","d D","f F","g G","h H","j J","k K","l L","ö Ö ;","ä Ä ' \"","Enter"],["Shift","y Y","x X","c C","v V","b B","n N","m M",", <",". >","/ ?","Shift"],["Options","Space","Options"]]},ru:{title:"Русский",keys:[["` ~ ±","1 ! §",'2 @ "',"3 # :","4 $ <","5 % >","6 ^","7 &","8 *","9 (","0 )","- _","= +","Backspace"],["Tab","й Й","ц Ц","у У","к К","е Е","н Н","г Г","ш Ш","щ Щ","з З","х Х [","ъ ] {","\\ | }"],["Caps","ф Ф","ы Ы","в В","а А","п П","р Р","о О","л Л","д Д","ж Ж ;","э Э '","Enter"],["Shift","я Я","ч Ч","с С","м М","и И","т Т","ь Ь","б Б ,","ю Ю .","/ ?","Shift"],["Options","Space","Options"]]},tr:{title:"Türkçe",keys:[['" é` ~',"1 ! §",'2 @ "',"3 # :","4 $ <","5 % >","6 ^ ±","7 &","8 *","9 ( {","0 ) }","- _ [","= + ]","Backspace"],["Tab","q Q","w W","e E","r R","t T","y Y","u U","ı I","o O","p P","ğ Ğ","ü Ü",", \\ |"],["Caps","a A","s S","d D","f F","g G","h H","j J","k K","l L","ş Ş","i̇ İ","Enter"],["Shift","z Z","x X","c C","v V","b B","n N","m M","ö Ö <","ç Ç >",". / ?","Shift"],["Options","Space","Options"]]},iw:{title:"Hebrew",keys:[["` ~ ±","1 ! §","2 @","3 #","4 $","5 %","6 ^","7 &","8 *","9 (","0 )","- _","= +","Backspace"],["Tab","/ q Q","' w W","ק e E","ר r R","א t T","ט y Y","ו u U","ן i I","ם o O","פ p P","[ {","] }","\\ |"],["Caps","ש a A","ד s S","ג d D","כ f F","ע g G","י h H","ח j J","ל k K","ך l L","ף ; :","' \"","Enter"],["Shift","ז z Z","ס x X","ב c C","ה v V","נ b B","מ n N","צ m M",", <",". >","/ ?","Shift"],["Options","Space","Options"]]},tata:{title:"Tata",keys:[["һ Һ` ~","1 ! §",'2 @ "',"3 # :","4 $ <","5 % >","6 ^ ±","7 &","8 *","9 ( {","0 )","- _","= +","Backspace"],["Tab","й Й","ө Ө","у У","к К","е Е","н Н","г Г","ш Ш","ә Ә","з З","х Х [","ү Ү ]","\\ | }"],["Caps","ф Ф","ы Ы","в В","а А","п П","р Р","о О","л Л","д Д","ң Ң ;","э Э '","Enter"],["Shift","я Я","ч Ч","с С","м М","и И","т Т","җ Җ","б Б ,","ю Ю .","ґ Ґ /","Shift"],["Options","Space","Options"]]}},layoutSwitchList:["en","es","de","ru","tr","iw","tata"],keySize:32,layout:[[1,1,1,1,1,1,1,1,1,1,1,1,1,2],[1.5,1,1,1,1,1,1,1,1,1,1,1,1,1.5],[1.8,1,1,1,1,1,1,1,1,1,1,1,2.2],[2.5,1,1,1,1,1,1,1,1,1,1,2.5],[3.5,9,3.5]]},d.D.prototype.controls.keyboard={tooltip:"Keyboard",icon:s(217),isActive(t){return!!t.e.fire("isKeyboardOpened")},command:"toggleKeyboard"},d.D.prototype.controls.extraKeyboardButtons={};var u=s(4),v=s(17);class g extends r.S{constructor(t){super(t),this.hasStyle=!i.Jodit.fatMode,this.requires=["license"],this.buttons=[{group:"insert",name:"keyboard"}];const{extraKeyButtons:e,extraKeyGroup:s}=t.o.keyboard;e.length&&e.forEach(((e,o)=>{const a=(0,v.HD)(e)?e:e.key,r=(0,v.HD)(e)||!e.hotkeys?["ctrl+"+(o+1)]:e.hotkeys;t.registerButton({name:"extraKeyboardButtons."+a,group:s});const{extraKeyboardButtons:i}=d.D.defaultOptions.controls;i[a]={name:a,tooltip:a,args:[a],hotkeys:r,command:"insertChar"}}))}afterInit(t){t.registerCommand("toggleKeyboard",this.toggleKeyboard).registerCommand("insertChar",this.insertChar),t.e.on("isKeyboardOpened",(()=>{var t;return null===(t=this.__keyboard)||void 0===t?void 0:t.isOpened}))}insertChar(t,e,s){this.j.s.insertNode(this.j.createInside.text(s))}toggleKeyboard(){if(!this.__keyboard){this.__keyboard=new u.Dialog({toolbarButtonSize:"tiny"});const t=new y(this.j);this.__keyboard.setMod("slim",!0).setContent(t);const{showLayoutSwitcher:e,layoutSwitchList:s,layoutList:o}=this.j.o.keyboard;if(e){const e=new n.Cj(this.__keyboard,{value:t.state.currentLayout,options:s.map((t=>{var e,s;return{text:null!==(s=null===(e=o[t])||void 0===e?void 0:e.title)&&void 0!==s?s:t,value:t}})),onChange(e){t.state.currentLayout=e}});e.setMod("size","tiny").setMod("width","auto").setMod("variant","outline"),this.__keyboard.setHeader(e)}}this.__keyboard.isOpened?this.__keyboard.close():this.__keyboard.open()}beforeDestruct(t){var e;null===(e=this.__keyboard)||void 0===e||e.destruct()}}(0,a.gn)([h.autobind],g.prototype,"insertChar",null),(0,a.gn)([h.autobind],g.prototype,"toggleKeyboard",null),i.Jodit.plugins.add("keyboard",g)}},t=>{"use strict";return t(t.s=211)}])}));
/*!
* jodit-pro - PRO Version of Jodit Editor
* Author: Chupurnov Valeriy <chupurnov@gmail.com>
* Version: v1.0.45
* Version: v1.0.46
* Url: https://xdsoft.net/jodit/pro/

@@ -10,2 +10,2 @@ * License(s): SEE LICENSE IN LICENSE.md

!function(e,t){if("object"==typeof exports&&"object"==typeof module)module.exports=t();else if("function"==typeof define&&define.amd)define([],t);else{var o=t();for(var s in o)("object"==typeof exports?exports:e)[s]=o[s]}}(self,(function(){return(self.webpackChunkjodit_pro=self.webpackChunkjodit_pro||[]).push([[535],{533:e=>{e.exports='<svg viewBox="0 0 24 24" xml:space="preserve" xmlns="http://www.w3.org/2000/svg"> <path d="M2.5244141,23.5h18.9511719c0.4140625,0,0.75-0.3359375,0.75-0.75V4.9208984 c0-0.1992188-0.0795898-0.390625-0.2207031-0.53125L18.3198242,0.71875C18.1791992,0.5786133,17.9887695,0.5,17.7905273,0.5 H2.5244141c-0.4140625,0-0.75,0.3359375-0.75,0.75v21.5C1.7744141,23.1640625,2.1103516,23.5,2.5244141,23.5z M20.7128296,5.2197266 h-2.6986694V2.531189L20.7128296,5.2197266z M3.2744141,2h13.2397461v3.9697266c0,0.4140625,0.3359375,0.75,0.75,0.75h3.4614258V22 H3.2744141V2z" fill="#1D1D1D"/> <path d="M8.75,10.25h1.75c0.4140625,0,0.75-0.3359375,0.75-0.75s-0.3359375-0.75-0.75-0.75H8 c-0.4140625,0-0.75,0.3359375-0.75,0.75v2.75H6c-0.4140625,0-0.75,0.3359375-0.75,0.75S5.5859375,13.75,6,13.75h1.25v2.75 c0,0.4140625,0.3359375,0.75,0.75,0.75h2.5c0.4140625,0,0.75-0.3359375,0.75-0.75s-0.3359375-0.75-0.75-0.75H8.75V10.25z" fill="#1D1D1D"/> <path d="M18.5,12.25h-1.25V9.5c0-0.4140625-0.3359375-0.75-0.75-0.75H14c-0.4140625,0-0.75,0.3359375-0.75,0.75 s0.3359375,0.75,0.75,0.75h1.75v5.5H14c-0.4140625,0-0.75,0.3359375-0.75,0.75s0.3359375,0.75,0.75,0.75h2.5 c0.4140625,0,0.75-0.3359375,0.75-0.75v-2.75h1.25c0.4140625,0,0.75-0.3359375,0.75-0.75S18.9140625,12.25,18.5,12.25z" fill="#1D1D1D"/></svg>'},532:(e,t,o)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),o(12).Config.prototype.controls.pasteCode={icon:o(533),tooltip:"Paste code",command:"pasteCode"}},531:(e,t,o)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.pasteCode=void 0;var s=o(1);o(532);var n=o(187),r=o(166),i=o(79),c=o(103),a=o(23),d=o(2),p=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.requires=["license"],t.buttons=[{name:"pasteCode",group:"clipboard"}],t}return s.__extends(t,e),t.prototype.afterInit=function(e){e.registerCommand("pasteCode",this.openCodeEditDialog)},t.prototype.openCodeEditDialog=function(){var e=this.j,t=new i.UIForm(e,[new i.UIBlock(e,[new i.UITextArea(e,{name:"code",required:!0})],{mod:"padding"})]),o=a.refs(t).code;e.async.requestIdleCallback((function(){o.focus()}));var s=e.s.save();r.Confirm("","Paste as code",(function(n){if(n)return!!t.validate()&&(e.s.restore(s),void e.s.insertHTML(o.value));e.s.restore(s)})).setContent(t.container)},t.prototype.beforeDestruct=function(e){},s.__decorate([c.autobind],t.prototype,"openCodeEditDialog",null),t}(n.Plugin);t.pasteCode=p,d.Jodit.plugins.add("paste-code",p)}},e=>{"use strict";e(e.s=531)}])}));
!function(e,t){if("object"==typeof exports&&"object"==typeof module)module.exports=t();else if("function"==typeof define&&define.amd)define([],t);else{var o=t();for(var s in o)("object"==typeof exports?exports:e)[s]=o[s]}}(self,(function(){return(self.webpackChunkjodit_pro=self.webpackChunkjodit_pro||[]).push([[535],{533:e=>{e.exports='<svg viewBox="0 0 24 24" xml:space="preserve" xmlns="http://www.w3.org/2000/svg"> <path d="M2.5244141,23.5h18.9511719c0.4140625,0,0.75-0.3359375,0.75-0.75V4.9208984 c0-0.1992188-0.0795898-0.390625-0.2207031-0.53125L18.3198242,0.71875C18.1791992,0.5786133,17.9887695,0.5,17.7905273,0.5 H2.5244141c-0.4140625,0-0.75,0.3359375-0.75,0.75v21.5C1.7744141,23.1640625,2.1103516,23.5,2.5244141,23.5z M20.7128296,5.2197266 h-2.6986694V2.531189L20.7128296,5.2197266z M3.2744141,2h13.2397461v3.9697266c0,0.4140625,0.3359375,0.75,0.75,0.75h3.4614258V22 H3.2744141V2z" fill="#1D1D1D"/> <path d="M8.75,10.25h1.75c0.4140625,0,0.75-0.3359375,0.75-0.75s-0.3359375-0.75-0.75-0.75H8 c-0.4140625,0-0.75,0.3359375-0.75,0.75v2.75H6c-0.4140625,0-0.75,0.3359375-0.75,0.75S5.5859375,13.75,6,13.75h1.25v2.75 c0,0.4140625,0.3359375,0.75,0.75,0.75h2.5c0.4140625,0,0.75-0.3359375,0.75-0.75s-0.3359375-0.75-0.75-0.75H8.75V10.25z" fill="#1D1D1D"/> <path d="M18.5,12.25h-1.25V9.5c0-0.4140625-0.3359375-0.75-0.75-0.75H14c-0.4140625,0-0.75,0.3359375-0.75,0.75 s0.3359375,0.75,0.75,0.75h1.75v5.5H14c-0.4140625,0-0.75,0.3359375-0.75,0.75s0.3359375,0.75,0.75,0.75h2.5 c0.4140625,0,0.75-0.3359375,0.75-0.75v-2.75h1.25c0.4140625,0,0.75-0.3359375,0.75-0.75S18.9140625,12.25,18.5,12.25z" fill="#1D1D1D"/></svg>'},532:(e,t,o)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),o(12).Config.prototype.controls.pasteCode={icon:o(533),tooltip:"Paste code",command:"pasteCode"}},531:(e,t,o)=>{"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.pasteCode=void 0;var s=o(1);o(532);var n=o(187),r=o(166),i=o(79),c=o(103),a=o(23),d=o(2),p=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.requires=["license"],t.buttons=[{name:"pasteCode",group:"clipboard"}],t}return s.__extends(t,e),t.prototype.afterInit=function(e){e.registerCommand("pasteCode",this.openCodeEditDialog)},t.prototype.openCodeEditDialog=function(){var e=this.j,t=new i.UIForm(e,[new i.UIBlock(e,[new i.UITextArea(e,{name:"code",required:!0})],{mod:"padding"})]),o=a.refs(t).code;e.async.requestIdleCallback((function(){o.focus()}));var s=e.s.save();r.Confirm("","Paste as code",(function(n){if(n)return!!t.validate()&&(e.s.restore(s),void e.s.insertHTML(o.value));e.s.restore(s)})).setContent(t.container)},t.prototype.beforeDestruct=function(e){},s.__decorate([c.autobind],t.prototype,"openCodeEditDialog",null),t}(n.Plugin);t.pasteCode=p,d.Jodit.plugins.add("paste-code",p)}},e=>{"use strict";return e(e.s=531)}])}));
/*!
* jodit-pro - PRO Version of Jodit Editor
* Author: Chupurnov Valeriy <chupurnov@gmail.com>
* Version: v1.0.45
* Version: v1.0.46
* Url: https://xdsoft.net/jodit/pro/

@@ -10,2 +10,2 @@ * License(s): SEE LICENSE IN LICENSE.md

((e,t)=>{if("object"==typeof exports&&"object"==typeof module)module.exports=t();else if("function"==typeof define&&define.amd)define([],t);else{var o=t();for(var s in o)("object"==typeof exports?exports:e)[s]=o[s]}})(self,(function(){return(self.webpackChunkjodit_pro=self.webpackChunkjodit_pro||[]).push([[535],{210(e){e.exports='<svg viewBox="0 0 24 24" xml:space="preserve" xmlns="http://www.w3.org/2000/svg"> <path d="M2.5244141,23.5h18.9511719c0.4140625,0,0.75-0.3359375,0.75-0.75V4.9208984 c0-0.1992188-0.0795898-0.390625-0.2207031-0.53125L18.3198242,0.71875C18.1791992,0.5786133,17.9887695,0.5,17.7905273,0.5 H2.5244141c-0.4140625,0-0.75,0.3359375-0.75,0.75v21.5C1.7744141,23.1640625,2.1103516,23.5,2.5244141,23.5z M20.7128296,5.2197266 h-2.6986694V2.531189L20.7128296,5.2197266z M3.2744141,2h13.2397461v3.9697266c0,0.4140625,0.3359375,0.75,0.75,0.75h3.4614258V22 H3.2744141V2z" fill="#1D1D1D"/> <path d="M8.75,10.25h1.75c0.4140625,0,0.75-0.3359375,0.75-0.75s-0.3359375-0.75-0.75-0.75H8 c-0.4140625,0-0.75,0.3359375-0.75,0.75v2.75H6c-0.4140625,0-0.75,0.3359375-0.75,0.75S5.5859375,13.75,6,13.75h1.25v2.75 c0,0.4140625,0.3359375,0.75,0.75,0.75h2.5c0.4140625,0,0.75-0.3359375,0.75-0.75s-0.3359375-0.75-0.75-0.75H8.75V10.25z" fill="#1D1D1D"/> <path d="M18.5,12.25h-1.25V9.5c0-0.4140625-0.3359375-0.75-0.75-0.75H14c-0.4140625,0-0.75,0.3359375-0.75,0.75 s0.3359375,0.75,0.75,0.75h1.75v5.5H14c-0.4140625,0-0.75,0.3359375-0.75,0.75s0.3359375,0.75,0.75,0.75h2.5 c0.4140625,0,0.75-0.3359375,0.75-0.75v-2.75h1.25c0.4140625,0,0.75-0.3359375,0.75-0.75S18.9140625,12.25,18.5,12.25z" fill="#1D1D1D"/></svg>'},209(e,t,o){"use strict";o.r(t),o.d(t,{pasteCode:()=>p});var s=o(39);o(2).D.prototype.controls.pasteCode={icon:o(210),tooltip:"Paste code",command:"pasteCode"};var r=o(56),c=o(47),d=o(27),i=o(36),n=o(10),a=o(1);class p extends r.S{constructor(){super(...arguments),this.requires=["license"],this.buttons=[{name:"pasteCode",group:"clipboard"}]}afterInit(e){e.registerCommand("pasteCode",this.openCodeEditDialog)}openCodeEditDialog(){const e=this.j,t=new d.x4(e,[new d.eC(e,[new d.GJ(e,{name:"code",required:!0})],{mod:"padding"})]),{code:o}=(0,n.refs)(t);e.async.requestIdleCallback((()=>{o.focus()}));const s=e.s.save();(0,c.I4)("","Paste as code",(r=>{if(r)return!!t.validate()&&(e.s.restore(s),void e.s.insertHTML(o.value));e.s.restore(s)})).setContent(t.container)}beforeDestruct(e){}}(0,s.gn)([i.autobind],p.prototype,"openCodeEditDialog",null),a.Jodit.plugins.add("paste-code",p)}},e=>{"use strict";e(e.s=209)}])}));
((e,t)=>{if("object"==typeof exports&&"object"==typeof module)module.exports=t();else if("function"==typeof define&&define.amd)define([],t);else{var o=t();for(var s in o)("object"==typeof exports?exports:e)[s]=o[s]}})(self,(function(){return(self.webpackChunkjodit_pro=self.webpackChunkjodit_pro||[]).push([[535],{210(e){e.exports='<svg viewBox="0 0 24 24" xml:space="preserve" xmlns="http://www.w3.org/2000/svg"> <path d="M2.5244141,23.5h18.9511719c0.4140625,0,0.75-0.3359375,0.75-0.75V4.9208984 c0-0.1992188-0.0795898-0.390625-0.2207031-0.53125L18.3198242,0.71875C18.1791992,0.5786133,17.9887695,0.5,17.7905273,0.5 H2.5244141c-0.4140625,0-0.75,0.3359375-0.75,0.75v21.5C1.7744141,23.1640625,2.1103516,23.5,2.5244141,23.5z M20.7128296,5.2197266 h-2.6986694V2.531189L20.7128296,5.2197266z M3.2744141,2h13.2397461v3.9697266c0,0.4140625,0.3359375,0.75,0.75,0.75h3.4614258V22 H3.2744141V2z" fill="#1D1D1D"/> <path d="M8.75,10.25h1.75c0.4140625,0,0.75-0.3359375,0.75-0.75s-0.3359375-0.75-0.75-0.75H8 c-0.4140625,0-0.75,0.3359375-0.75,0.75v2.75H6c-0.4140625,0-0.75,0.3359375-0.75,0.75S5.5859375,13.75,6,13.75h1.25v2.75 c0,0.4140625,0.3359375,0.75,0.75,0.75h2.5c0.4140625,0,0.75-0.3359375,0.75-0.75s-0.3359375-0.75-0.75-0.75H8.75V10.25z" fill="#1D1D1D"/> <path d="M18.5,12.25h-1.25V9.5c0-0.4140625-0.3359375-0.75-0.75-0.75H14c-0.4140625,0-0.75,0.3359375-0.75,0.75 s0.3359375,0.75,0.75,0.75h1.75v5.5H14c-0.4140625,0-0.75,0.3359375-0.75,0.75s0.3359375,0.75,0.75,0.75h2.5 c0.4140625,0,0.75-0.3359375,0.75-0.75v-2.75h1.25c0.4140625,0,0.75-0.3359375,0.75-0.75S18.9140625,12.25,18.5,12.25z" fill="#1D1D1D"/></svg>'},209(e,t,o){"use strict";o.r(t),o.d(t,{pasteCode:()=>p});var s=o(39);o(2).D.prototype.controls.pasteCode={icon:o(210),tooltip:"Paste code",command:"pasteCode"};var r=o(56),c=o(47),n=o(27),d=o(36),i=o(10),a=o(1);class p extends r.S{constructor(){super(...arguments),this.requires=["license"],this.buttons=[{name:"pasteCode",group:"clipboard"}]}afterInit(e){e.registerCommand("pasteCode",this.openCodeEditDialog)}openCodeEditDialog(){const e=this.j,t=new n.x4(e,[new n.eC(e,[new n.GJ(e,{name:"code",required:!0})],{mod:"padding"})]),{code:o}=(0,i.refs)(t);e.async.requestIdleCallback((()=>{o.focus()}));const s=e.s.save();(0,c.I4)("","Paste as code",(r=>{if(r)return!!t.validate()&&(e.s.restore(s),void e.s.insertHTML(o.value));e.s.restore(s)})).setContent(t.container)}beforeDestruct(e){}}(0,s.gn)([d.autobind],p.prototype,"openCodeEditDialog",null),a.Jodit.plugins.add("paste-code",p)}},e=>{"use strict";return e(e.s=209)}])}));
/*!
* jodit-pro - PRO Version of Jodit Editor
* Author: Chupurnov Valeriy <chupurnov@gmail.com>
* Version: v1.0.45
* Version: v1.0.46
* Url: https://xdsoft.net/jodit/pro/

@@ -10,2 +10,2 @@ * License(s): SEE LICENSE IN LICENSE.md

!function(t,o){if("object"==typeof exports&&"object"==typeof module)module.exports=o();else if("function"==typeof define&&define.amd)define([],o);else{var e=o();for(var s in e)("object"==typeof exports?exports:t)[s]=e[s]}}(self,(function(){return(self.webpackChunkjodit_pro=self.webpackChunkjodit_pro||[]).push([[876],{502:t=>{t.exports='<svg viewBox="0 0 1792 1792" xmlns="http://www.w3.org/2000/svg"> <g> <rect rx="10" height="1620" width="1620" y="79.646973" x="80" stroke-width="100" stroke-dasharray="8% 10%" fill="none"/> <path d="m1333.992706,381.692384l0,52.982419q0,21.04781 -12.98052,44.272981t-29.820114,23.22517q-35.082487,0 -37.889085,0.725787q-18.242893,4.354719 -22.452791,22.499384q-2.104949,7.983652 -2.104949,46.45034l0,836.106125q0,18.144664 -12.629695,31.208822t-30.170938,13.064158l-75.778171,0q-17.541243,0 -30.170938,-13.064158t-12.629695,-31.208822l0,-884.008038l-100.335911,0l0,884.008038q0,18.144664 -12.27887,31.208822t-30.521763,13.064158l-75.778171,0q-18.242893,0 -30.521763,-13.064158t-12.27887,-31.208822l0,-359.990137q-103.14251,-8.709439 -171.904184,-42.821407q-88.407866,-42.095621 -134.716748,-129.915795q-44.905583,-84.917028 -44.905583,-187.978721q0,-120.48057 61.745176,-207.574958q61.745176,-85.642815 146.644794,-115.400064q77.88312,-26.854103 292.587937,-26.854103l336.090221,0q17.541243,0 30.170938,13.064158t12.629695,31.208822z"/> </g> </svg>'},481:(t,o,e)=>{"use strict";Object.defineProperty(o,"__esModule",{value:!0});var s=e(12);s.Config.prototype.showBlocks={enable:!1,color:"#ccc",tagList:["html","body","div","span","applet","object","iframe","h1","h2","h3","h4","h5","h6","p","blockquote","pre","a","abbr","acronym","address","big","cite","code","del","dfn","em","img","ins","kbd","q","s","samp","small","strike","strong","sub","sup","tt","var","b","u","i","center","dl","dt","dd","fieldset","form","label","legend","caption","th","td","li","ol","ul","article","aside","canvas","details","embed","figure","figcaption","footer","header","hgroup","menu","nav","output","ruby","section","summary","time","mark","audio","video"]},s.Config.prototype.controls.showBlocks={isActive:function(t){return Boolean(t.e.fire("showBlocksEnabled"))},tooltip:"Show Blocks",command:"toggleShowBlocks"}},482:(t,o,e)=>{"use strict";Object.defineProperty(o,"__esModule",{value:!0}),o.zh_tw=o.zh_cn=o.tr=o.ru=o.pt_br=o.pl=o.nl=o.ko=o.ja=o.it=o.id=o.hu=o.he=o.fr=o.fa=o.es=o.de=o.cs_cz=o.ar=void 0;var s=e(483);o.ar=s;var r=e(484);o.cs_cz=r;var l=e(485);o.de=l;var i=e(486);o.es=i;var a=e(487);o.fa=a;var n=e(488);o.fr=n;var c=e(489);o.he=c;var h=e(490);o.hu=h;var p=e(491);o.id=p;var d=e(492);o.it=d;var u=e(493);o.ja=u;var k=e(494);o.ko=k;var f=e(495);o.nl=f;var b=e(496);o.pl=b;var w=e(497);o.pt_br=w;var g=e(498);o.ru=g;var v=e(499);o.tr=v;var B=e(500);o.zh_cn=B;var x=e(501);o.zh_tw=x},480:(t,o,e)=>{"use strict";Object.defineProperty(o,"__esModule",{value:!0}),o.showBlocks=void 0;var s=e(1);e(481);var r=e(187),l=e(14),i=e(79),a=e(34),n=e(103),c=e(2),h=function(t){function o(o){var s=t.call(this,o)||this;return s.requires=["license"],s.buttons=[{name:"showBlocks",group:"state"}],s.isEnabled=!1,a.extendLang(e(482)),i.Icon.set("showBlocks",e(502)),s}return s.__extends(o,t),o.prototype.enable=function(){var t=this;this.isEnabled=!0;var o=this.j.o.iframe?"body":".jodit-wysiwyg",e=this.j.o.showBlocks,s=e.color;this.style.innerHTML=e.tagList.map((function(e){return o+" "+e+"{\n\t\t\t\t\toutline: 1px dashed "+s+';\n\t\t\t\t\tbackground-image: url("data:image/svg+xml;utf8,'+escape('<svg xmlns="http://www.w3.org/2000/svg" width="50px"><text dominant-baseline="hanging" text-anchor="end" style="fill: '+s+';font: 10px sans-serif" x="50px" y="0">'+e+"</text></svg>")+'");\n\t\t\t\t\tbackground-position: top 2px '+("rtl"===t.j.o.direction?"left":"right")+" 4px;\n\t\t\t\t\tbackground-repeat: no-repeat;\n\t\t\t\t\tposition: relative;\n\t\t\t\t}"})).join("")},o.prototype.disable=function(){this.isEnabled=!1,this.style.innerHTML=""},o.prototype.toggle=function(){this.isEnabled?this.disable():this.enable(),this.j.e.fire("updateToolbar")},o.prototype.afterInit=function(t){var e=this;this.style=a.getContainer(t,o,"style",!0),t.e.on("showBlocksEnabled",(function(){return e.isEnabled})),t.registerCommand("enableShowBlocks",this.enable).registerCommand("disableShowBlocks",this.disable).registerCommand("toggleShowBlocks",this.toggle),this.j.o.showBlocks.enable&&this.enable()},o.prototype.beforeDestruct=function(t){this.disable(),l.Dom.safeRemove(this.style)},s.__decorate([n.autobind],o.prototype,"enable",null),s.__decorate([n.autobind],o.prototype,"disable",null),s.__decorate([n.autobind],o.prototype,"toggle",null),o}(r.Plugin);o.showBlocks=h,c.Jodit.plugins.add("show-blocks",h)},483:t=>{t.exports={"Show Blocks":"تظهر كتل"}},484:t=>{t.exports={"Show Blocks":"Ukázat Bloky"}},485:t=>{t.exports={"Show Blocks":"Zeigen Blöcke"}},486:t=>{t.exports={"Show Blocks":"Mostrar Bloques"}},487:t=>{t.exports={"Show Blocks":"نشان می دهد بلوک"}},488:t=>{t.exports={"Show Blocks":"Afficher Les Blocs"}},489:t=>{t.exports={"Show Blocks":"תראה רחובות"}},490:t=>{t.exports={"Show Blocks":"Mutasd Meg Blokkok"}},491:t=>{t.exports={"Show Blocks":"Menunjukkan Blok"}},492:t=>{t.exports={"Show Blocks":"Visualizza Blocchi"}},493:t=>{t.exports={"Show Blocks":"ショーのブロック"}},494:t=>{t.exports={"Show Blocks":"쇼 블록"}},495:t=>{t.exports={"Show Blocks":"Toon Blokken"}},496:t=>{t.exports={"Show Blocks":"Pokaż Bloki"}},497:t=>{t.exports={"Show Blocks":"Mostrar Blocos"}},498:t=>{t.exports={"Show Blocks":"Показать Блоки"}},499:t=>{t.exports={"Show Blocks":"Haritayı Blokları"}},500:t=>{t.exports={"Show Blocks":"显示块"}},501:t=>{t.exports={"Show Blocks":"แสดงช่วงตึก"}}},t=>{"use strict";t(t.s=480)}])}));
!function(t,o){if("object"==typeof exports&&"object"==typeof module)module.exports=o();else if("function"==typeof define&&define.amd)define([],o);else{var e=o();for(var s in e)("object"==typeof exports?exports:t)[s]=e[s]}}(self,(function(){return(self.webpackChunkjodit_pro=self.webpackChunkjodit_pro||[]).push([[876],{502:t=>{t.exports='<svg viewBox="0 0 1792 1792" xmlns="http://www.w3.org/2000/svg"> <g> <rect rx="10" height="1620" width="1620" y="79.646973" x="80" stroke-width="100" stroke-dasharray="8% 10%" fill="none"/> <path d="m1333.992706,381.692384l0,52.982419q0,21.04781 -12.98052,44.272981t-29.820114,23.22517q-35.082487,0 -37.889085,0.725787q-18.242893,4.354719 -22.452791,22.499384q-2.104949,7.983652 -2.104949,46.45034l0,836.106125q0,18.144664 -12.629695,31.208822t-30.170938,13.064158l-75.778171,0q-17.541243,0 -30.170938,-13.064158t-12.629695,-31.208822l0,-884.008038l-100.335911,0l0,884.008038q0,18.144664 -12.27887,31.208822t-30.521763,13.064158l-75.778171,0q-18.242893,0 -30.521763,-13.064158t-12.27887,-31.208822l0,-359.990137q-103.14251,-8.709439 -171.904184,-42.821407q-88.407866,-42.095621 -134.716748,-129.915795q-44.905583,-84.917028 -44.905583,-187.978721q0,-120.48057 61.745176,-207.574958q61.745176,-85.642815 146.644794,-115.400064q77.88312,-26.854103 292.587937,-26.854103l336.090221,0q17.541243,0 30.170938,13.064158t12.629695,31.208822z"/> </g> </svg>'},481:(t,o,e)=>{"use strict";Object.defineProperty(o,"__esModule",{value:!0});var s=e(12);s.Config.prototype.showBlocks={enable:!1,color:"#ccc",tagList:["html","body","div","span","applet","object","iframe","h1","h2","h3","h4","h5","h6","p","blockquote","pre","a","abbr","acronym","address","big","cite","code","del","dfn","em","img","ins","kbd","q","s","samp","small","strike","strong","sub","sup","tt","var","b","u","i","center","dl","dt","dd","fieldset","form","label","legend","caption","th","td","li","ol","ul","article","aside","canvas","details","embed","figure","figcaption","footer","header","hgroup","menu","nav","output","ruby","section","summary","time","mark","audio","video"]},s.Config.prototype.controls.showBlocks={isActive:function(t){return Boolean(t.e.fire("showBlocksEnabled"))},tooltip:"Show Blocks",command:"toggleShowBlocks"}},482:(t,o,e)=>{"use strict";Object.defineProperty(o,"__esModule",{value:!0}),o.zh_tw=o.zh_cn=o.tr=o.ru=o.pt_br=o.pl=o.nl=o.ko=o.ja=o.it=o.id=o.hu=o.he=o.fr=o.fa=o.es=o.de=o.cs_cz=o.ar=void 0;var s=e(483);o.ar=s;var r=e(484);o.cs_cz=r;var l=e(485);o.de=l;var i=e(486);o.es=i;var a=e(487);o.fa=a;var n=e(488);o.fr=n;var c=e(489);o.he=c;var h=e(490);o.hu=h;var p=e(491);o.id=p;var d=e(492);o.it=d;var u=e(493);o.ja=u;var k=e(494);o.ko=k;var f=e(495);o.nl=f;var b=e(496);o.pl=b;var w=e(497);o.pt_br=w;var g=e(498);o.ru=g;var v=e(499);o.tr=v;var B=e(500);o.zh_cn=B;var x=e(501);o.zh_tw=x},480:(t,o,e)=>{"use strict";Object.defineProperty(o,"__esModule",{value:!0}),o.showBlocks=void 0;var s=e(1);e(481);var r=e(187),l=e(14),i=e(79),a=e(34),n=e(103),c=e(2),h=function(t){function o(o){var s=t.call(this,o)||this;return s.requires=["license"],s.buttons=[{name:"showBlocks",group:"state"}],s.isEnabled=!1,a.extendLang(e(482)),i.Icon.set("showBlocks",e(502)),s}return s.__extends(o,t),o.prototype.enable=function(){var t=this;this.isEnabled=!0;var o=this.j.o.iframe?"body":".jodit-wysiwyg",e=this.j.o.showBlocks,s=e.color;this.style.innerHTML=e.tagList.map((function(e){return o+" "+e+"{\n\t\t\t\t\toutline: 1px dashed "+s+';\n\t\t\t\t\tbackground-image: url("data:image/svg+xml;utf8,'+escape('<svg xmlns="http://www.w3.org/2000/svg" width="50px"><text dominant-baseline="hanging" text-anchor="end" style="fill: '+s+';font: 10px sans-serif" x="50px" y="0">'+e+"</text></svg>")+'");\n\t\t\t\t\tbackground-position: top 2px '+("rtl"===t.j.o.direction?"left":"right")+" 4px;\n\t\t\t\t\tbackground-repeat: no-repeat;\n\t\t\t\t\tposition: relative;\n\t\t\t\t}"})).join("")},o.prototype.disable=function(){this.isEnabled=!1,this.style.innerHTML=""},o.prototype.toggle=function(){this.isEnabled?this.disable():this.enable(),this.j.e.fire("updateToolbar")},o.prototype.afterInit=function(t){var e=this;this.style=a.getContainer(t,o,"style",!0),t.e.on("showBlocksEnabled",(function(){return e.isEnabled})),t.registerCommand("enableShowBlocks",this.enable).registerCommand("disableShowBlocks",this.disable).registerCommand("toggleShowBlocks",this.toggle),this.j.o.showBlocks.enable&&this.enable()},o.prototype.beforeDestruct=function(t){this.disable(),l.Dom.safeRemove(this.style)},s.__decorate([n.autobind],o.prototype,"enable",null),s.__decorate([n.autobind],o.prototype,"disable",null),s.__decorate([n.autobind],o.prototype,"toggle",null),o}(r.Plugin);o.showBlocks=h,c.Jodit.plugins.add("show-blocks",h)},483:t=>{t.exports={"Show Blocks":"تظهر كتل"}},484:t=>{t.exports={"Show Blocks":"Ukázat Bloky"}},485:t=>{t.exports={"Show Blocks":"Zeigen Blöcke"}},486:t=>{t.exports={"Show Blocks":"Mostrar Bloques"}},487:t=>{t.exports={"Show Blocks":"نشان می دهد بلوک"}},488:t=>{t.exports={"Show Blocks":"Afficher Les Blocs"}},489:t=>{t.exports={"Show Blocks":"תראה רחובות"}},490:t=>{t.exports={"Show Blocks":"Mutasd Meg Blokkok"}},491:t=>{t.exports={"Show Blocks":"Menunjukkan Blok"}},492:t=>{t.exports={"Show Blocks":"Visualizza Blocchi"}},493:t=>{t.exports={"Show Blocks":"ショーのブロック"}},494:t=>{t.exports={"Show Blocks":"쇼 블록"}},495:t=>{t.exports={"Show Blocks":"Toon Blokken"}},496:t=>{t.exports={"Show Blocks":"Pokaż Bloki"}},497:t=>{t.exports={"Show Blocks":"Mostrar Blocos"}},498:t=>{t.exports={"Show Blocks":"Показать Блоки"}},499:t=>{t.exports={"Show Blocks":"Haritayı Blokları"}},500:t=>{t.exports={"Show Blocks":"显示块"}},501:t=>{t.exports={"Show Blocks":"แสดงช่วงตึก"}}},t=>{"use strict";return t(t.s=480)}])}));
/*!
* jodit-pro - PRO Version of Jodit Editor
* Author: Chupurnov Valeriy <chupurnov@gmail.com>
* Version: v1.0.45
* Version: v1.0.46
* Url: https://xdsoft.net/jodit/pro/

@@ -10,2 +10,2 @@ * License(s): SEE LICENSE IN LICENSE.md

((t,o)=>{if("object"==typeof exports&&"object"==typeof module)module.exports=o();else if("function"==typeof define&&define.amd)define([],o);else{var e=o();for(var s in e)("object"==typeof exports?exports:t)[s]=e[s]}})(self,(function(){return(self.webpackChunkjodit_pro=self.webpackChunkjodit_pro||[]).push([[876],{194(t){t.exports='<svg viewBox="0 0 1792 1792" xmlns="http://www.w3.org/2000/svg"> <g> <rect rx="10" height="1620" width="1620" y="79.646973" x="80" stroke-width="100" stroke-dasharray="8% 10%" fill="none"/> <path d="m1333.992706,381.692384l0,52.982419q0,21.04781 -12.98052,44.272981t-29.820114,23.22517q-35.082487,0 -37.889085,0.725787q-18.242893,4.354719 -22.452791,22.499384q-2.104949,7.983652 -2.104949,46.45034l0,836.106125q0,18.144664 -12.629695,31.208822t-30.170938,13.064158l-75.778171,0q-17.541243,0 -30.170938,-13.064158t-12.629695,-31.208822l0,-884.008038l-100.335911,0l0,884.008038q0,18.144664 -12.27887,31.208822t-30.521763,13.064158l-75.778171,0q-18.242893,0 -30.521763,-13.064158t-12.27887,-31.208822l0,-359.990137q-103.14251,-8.709439 -171.904184,-42.821407q-88.407866,-42.095621 -134.716748,-129.915795q-44.905583,-84.917028 -44.905583,-187.978721q0,-120.48057 61.745176,-207.574958q61.745176,-85.642815 146.644794,-115.400064q77.88312,-26.854103 292.587937,-26.854103l336.090221,0q17.541243,0 30.170938,13.064158t12.629695,31.208822z"/> </g> </svg>'},174(t,o,e){"use strict";e.r(o),e.d(o,{ar:()=>s,cs_cz:()=>l,de:()=>i,es:()=>r,fa:()=>a,fr:()=>n,he:()=>h,hu:()=>c,id:()=>p,it:()=>d,ja:()=>k,ko:()=>u,nl:()=>b,pl:()=>w,pt_br:()=>g,ru:()=>B,tr:()=>x,zh_cn:()=>f,zh_tw:()=>m});const s=e(175),l=e(176),i=e(177),r=e(178),a=e(179),n=e(180),h=e(181),c=e(182),p=e(183),d=e(184),k=e(185),u=e(186),b=e(187),w=e(188),g=e(189),B=e(190),x=e(191),f=e(192),m=e(193)},173(t,o,e){"use strict";e.r(o),e.d(o,{showBlocks:()=>p});var s=e(39),l=e(2);l.D.prototype.showBlocks={enable:!1,color:"#ccc",tagList:["html","body","div","span","applet","object","iframe","h1","h2","h3","h4","h5","h6","p","blockquote","pre","a","abbr","acronym","address","big","cite","code","del","dfn","em","img","ins","kbd","q","s","samp","small","strike","strong","sub","sup","tt","var","b","u","i","center","dl","dt","dd","fieldset","form","label","legend","caption","th","td","li","ol","ul","article","aside","canvas","details","embed","figure","figcaption","footer","header","hgroup","menu","nav","output","ruby","section","summary","time","mark","audio","video"]},l.D.prototype.controls.showBlocks={isActive(t){return!!t.e.fire("showBlocksEnabled")},tooltip:"Show Blocks",command:"toggleShowBlocks"};var i=e(56),r=e(4),a=e(27),n=e(14),h=e(36),c=e(1);class p extends i.S{constructor(t){super(t),this.requires=["license"],this.buttons=[{name:"showBlocks",group:"state"}],this.isEnabled=!1,(0,n.xl)(e(174)),a.JO.set("showBlocks",e(194))}enable(){this.isEnabled=!0;const t=this.j.o.iframe?"body":".jodit-wysiwyg",{tagList:o,color:e}=this.j.o.showBlocks;this.style.innerHTML=o.map((o=>{return`${t} ${o}{\n\t\t\t\t\toutline: 1px dashed ${e};\n\t\t\t\t\tbackground-image: url("${s='<svg xmlns="http://www.w3.org/2000/svg" width="50px"><text dominant-baseline="hanging" text-anchor="end" style="fill: '+e+';font: 10px sans-serif" x="50px" y="0">'+o+"</text></svg>","data:image/svg+xml;utf8,"+escape(s)}");\n\t\t\t\t\tbackground-position: top 2px ${"rtl"===this.j.o.direction?"left":"right"} 4px;\n\t\t\t\t\tbackground-repeat: no-repeat;\n\t\t\t\t\tposition: relative;\n\t\t\t\t}`;var s})).join("")}disable(){this.isEnabled=!1,this.style.innerHTML=""}toggle(){this.isEnabled?this.disable():this.enable(),this.j.e.fire("updateToolbar")}afterInit(t){this.style=(0,n.ZO)(t,p,"style",!0),t.e.on("showBlocksEnabled",(()=>this.isEnabled)),t.registerCommand("enableShowBlocks",this.enable).registerCommand("disableShowBlocks",this.disable).registerCommand("toggleShowBlocks",this.toggle),this.j.o.showBlocks.enable&&this.enable()}beforeDestruct(t){this.disable(),r.Dom.safeRemove(this.style)}}(0,s.gn)([h.autobind],p.prototype,"enable",null),(0,s.gn)([h.autobind],p.prototype,"disable",null),(0,s.gn)([h.autobind],p.prototype,"toggle",null),c.Jodit.plugins.add("show-blocks",p)},175(t){t.exports={"Show Blocks":"تظهر كتل"}},176(t){t.exports={"Show Blocks":"Ukázat Bloky"}},177(t){t.exports={"Show Blocks":"Zeigen Blöcke"}},178(t){t.exports={"Show Blocks":"Mostrar Bloques"}},179(t){t.exports={"Show Blocks":"نشان می دهد بلوک"}},180(t){t.exports={"Show Blocks":"Afficher Les Blocs"}},181(t){t.exports={"Show Blocks":"תראה רחובות"}},182(t){t.exports={"Show Blocks":"Mutasd Meg Blokkok"}},183(t){t.exports={"Show Blocks":"Menunjukkan Blok"}},184(t){t.exports={"Show Blocks":"Visualizza Blocchi"}},185(t){t.exports={"Show Blocks":"ショーのブロック"}},186(t){t.exports={"Show Blocks":"쇼 블록"}},187(t){t.exports={"Show Blocks":"Toon Blokken"}},188(t){t.exports={"Show Blocks":"Pokaż Bloki"}},189(t){t.exports={"Show Blocks":"Mostrar Blocos"}},190(t){t.exports={"Show Blocks":"Показать Блоки"}},191(t){t.exports={"Show Blocks":"Haritayı Blokları"}},192(t){t.exports={"Show Blocks":"显示块"}},193(t){t.exports={"Show Blocks":"แสดงช่วงตึก"}}},t=>{"use strict";t(t.s=173)}])}));
((t,o)=>{if("object"==typeof exports&&"object"==typeof module)module.exports=o();else if("function"==typeof define&&define.amd)define([],o);else{var e=o();for(var s in e)("object"==typeof exports?exports:t)[s]=e[s]}})(self,(function(){return(self.webpackChunkjodit_pro=self.webpackChunkjodit_pro||[]).push([[876],{194(t){t.exports='<svg viewBox="0 0 1792 1792" xmlns="http://www.w3.org/2000/svg"> <g> <rect rx="10" height="1620" width="1620" y="79.646973" x="80" stroke-width="100" stroke-dasharray="8% 10%" fill="none"/> <path d="m1333.992706,381.692384l0,52.982419q0,21.04781 -12.98052,44.272981t-29.820114,23.22517q-35.082487,0 -37.889085,0.725787q-18.242893,4.354719 -22.452791,22.499384q-2.104949,7.983652 -2.104949,46.45034l0,836.106125q0,18.144664 -12.629695,31.208822t-30.170938,13.064158l-75.778171,0q-17.541243,0 -30.170938,-13.064158t-12.629695,-31.208822l0,-884.008038l-100.335911,0l0,884.008038q0,18.144664 -12.27887,31.208822t-30.521763,13.064158l-75.778171,0q-18.242893,0 -30.521763,-13.064158t-12.27887,-31.208822l0,-359.990137q-103.14251,-8.709439 -171.904184,-42.821407q-88.407866,-42.095621 -134.716748,-129.915795q-44.905583,-84.917028 -44.905583,-187.978721q0,-120.48057 61.745176,-207.574958q61.745176,-85.642815 146.644794,-115.400064q77.88312,-26.854103 292.587937,-26.854103l336.090221,0q17.541243,0 30.170938,13.064158t12.629695,31.208822z"/> </g> </svg>'},174(t,o,e){"use strict";e.r(o),e.d(o,{ar:()=>s,cs_cz:()=>l,de:()=>r,es:()=>i,fa:()=>a,fr:()=>n,he:()=>h,hu:()=>c,id:()=>p,it:()=>d,ja:()=>k,ko:()=>u,nl:()=>b,pl:()=>w,pt_br:()=>g,ru:()=>B,tr:()=>x,zh_cn:()=>f,zh_tw:()=>m});const s=e(175),l=e(176),r=e(177),i=e(178),a=e(179),n=e(180),h=e(181),c=e(182),p=e(183),d=e(184),k=e(185),u=e(186),b=e(187),w=e(188),g=e(189),B=e(190),x=e(191),f=e(192),m=e(193)},173(t,o,e){"use strict";e.r(o),e.d(o,{showBlocks:()=>p});var s=e(39),l=e(2);l.D.prototype.showBlocks={enable:!1,color:"#ccc",tagList:["html","body","div","span","applet","object","iframe","h1","h2","h3","h4","h5","h6","p","blockquote","pre","a","abbr","acronym","address","big","cite","code","del","dfn","em","img","ins","kbd","q","s","samp","small","strike","strong","sub","sup","tt","var","b","u","i","center","dl","dt","dd","fieldset","form","label","legend","caption","th","td","li","ol","ul","article","aside","canvas","details","embed","figure","figcaption","footer","header","hgroup","menu","nav","output","ruby","section","summary","time","mark","audio","video"]},l.D.prototype.controls.showBlocks={isActive(t){return!!t.e.fire("showBlocksEnabled")},tooltip:"Show Blocks",command:"toggleShowBlocks"};var r=e(56),i=e(4),a=e(27),n=e(14),h=e(36),c=e(1);class p extends r.S{constructor(t){super(t),this.requires=["license"],this.buttons=[{name:"showBlocks",group:"state"}],this.isEnabled=!1,(0,n.xl)(e(174)),a.JO.set("showBlocks",e(194))}enable(){this.isEnabled=!0;const t=this.j.o.iframe?"body":".jodit-wysiwyg",{tagList:o,color:e}=this.j.o.showBlocks;this.style.innerHTML=o.map((o=>{return`${t} ${o}{\n\t\t\t\t\toutline: 1px dashed ${e};\n\t\t\t\t\tbackground-image: url("${s='<svg xmlns="http://www.w3.org/2000/svg" width="50px"><text dominant-baseline="hanging" text-anchor="end" style="fill: '+e+';font: 10px sans-serif" x="50px" y="0">'+o+"</text></svg>","data:image/svg+xml;utf8,"+escape(s)}");\n\t\t\t\t\tbackground-position: top 2px ${"rtl"===this.j.o.direction?"left":"right"} 4px;\n\t\t\t\t\tbackground-repeat: no-repeat;\n\t\t\t\t\tposition: relative;\n\t\t\t\t}`;var s})).join("")}disable(){this.isEnabled=!1,this.style.innerHTML=""}toggle(){this.isEnabled?this.disable():this.enable(),this.j.e.fire("updateToolbar")}afterInit(t){this.style=(0,n.ZO)(t,p,"style",!0),t.e.on("showBlocksEnabled",(()=>this.isEnabled)),t.registerCommand("enableShowBlocks",this.enable).registerCommand("disableShowBlocks",this.disable).registerCommand("toggleShowBlocks",this.toggle),this.j.o.showBlocks.enable&&this.enable()}beforeDestruct(t){this.disable(),i.Dom.safeRemove(this.style)}}(0,s.gn)([h.autobind],p.prototype,"enable",null),(0,s.gn)([h.autobind],p.prototype,"disable",null),(0,s.gn)([h.autobind],p.prototype,"toggle",null),c.Jodit.plugins.add("show-blocks",p)},175(t){t.exports={"Show Blocks":"تظهر كتل"}},176(t){t.exports={"Show Blocks":"Ukázat Bloky"}},177(t){t.exports={"Show Blocks":"Zeigen Blöcke"}},178(t){t.exports={"Show Blocks":"Mostrar Bloques"}},179(t){t.exports={"Show Blocks":"نشان می دهد بلوک"}},180(t){t.exports={"Show Blocks":"Afficher Les Blocs"}},181(t){t.exports={"Show Blocks":"תראה רחובות"}},182(t){t.exports={"Show Blocks":"Mutasd Meg Blokkok"}},183(t){t.exports={"Show Blocks":"Menunjukkan Blok"}},184(t){t.exports={"Show Blocks":"Visualizza Blocchi"}},185(t){t.exports={"Show Blocks":"ショーのブロック"}},186(t){t.exports={"Show Blocks":"쇼 블록"}},187(t){t.exports={"Show Blocks":"Toon Blokken"}},188(t){t.exports={"Show Blocks":"Pokaż Bloki"}},189(t){t.exports={"Show Blocks":"Mostrar Blocos"}},190(t){t.exports={"Show Blocks":"Показать Блоки"}},191(t){t.exports={"Show Blocks":"Haritayı Blokları"}},192(t){t.exports={"Show Blocks":"显示块"}},193(t){t.exports={"Show Blocks":"แสดงช่วงตึก"}}},t=>{"use strict";return t(t.s=173)}])}));
{
"name": "jodit-pro",
"version": "1.0.45",
"version": "1.0.46",
"author": "Chupurnov Valeriy <chupurnov@gmail.com>",

@@ -5,0 +5,0 @@ "homepage": "https://xdsoft.net/jodit/pro/",

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc