@ebl-vue/editor-full 2.31.9 → 2.31.11

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.mjs CHANGED
@@ -1,21 +1,28 @@
1
- (function(){"use strict";try{if(typeof document!="undefined"){var e=document.createElement("style");e.appendChild(document.createTextNode(':root{--color-border: #EFF0F1}.ebl-editor{cursor:text;font-size:16px;font-weight:400;background-color:#fff}@media (min-width: 1050px){.ce-block__content,.ce-toolbar__content{max-width:700px}}.ce-toolbar,.ce-inline-toolbar{z-index:1000}.ce-toolbar__plus{border:1px solid #EFF0F1}.ce-toolbar .ce-popover__items{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-orient:horizontal;-webkit-box-direction:normal;-ms-flex-direction:row;flex-direction:row;-ms-flex-wrap:wrap;flex-wrap:wrap}.ce-toolbar .ce-popover__items .ce-popover-item{position:relative}.ce-toolbar .ce-popover__items .ce-popover-item__title{display:none}.ce-toolbar .ce-popover-item-html,.ce-toolbar .ce-popover-item-separator,.ce-toolbar .ce-popover-item[data-item-name=convert-to]{width:100%}.ce-toolbar .ce-popover-item[data-item-name=convert-to] .ce-popover-item__title{display:block}.ce-inline-toolbar .ce-popover__items{display:-webkit-box!important;display:-ms-flexbox!important;display:flex!important}.ce-inline-toolbar .ce-popover__items{-webkit-box-orient:horizontal;-webkit-box-direction:normal;-ms-flex-direction:row;flex-direction:row;-ms-flex-wrap:wrap;flex-wrap:wrap}.ce-inline-toolbar .ce-popover__items .ce-popover-item__title{display:none}.ce-block--drop-target .ce-block__content:before{content:"";position:absolute;top:50%;left:-20px;margin-top:-1px;height:8px;width:8px;border:solid #a0a0a0;border-width:1px 1px 0 0;-webkit-transform-origin:right;transform-origin:right;-webkit-transform:rotate(45deg);transform:rotate(45deg)}.ce-block--drop-target .ce-block__content:after{background:none}.ce-header{padding:.6em 0 3px;margin:0;line-height:1.25em;outline:none}.ce-header p,.ce-header div{padding:0!important;margin:0!important}.ce-tune-alignment--right{text-align:right}.ce-tune-alignment--center{text-align:center}.ce-tune-alignment--left{text-align:left}.ce-paragraph{line-height:1.6em;outline:none}.ce-block:only-of-type .ce-paragraph[data-placeholder-active]:empty:before,.ce-block:only-of-type .ce-paragraph[data-placeholder-active][data-empty=true]:before{content:attr(data-placeholder-active)}.ce-paragraph p:first-of-type{margin-top:0}.ce-paragraph p:last-of-type{margin-bottom:0}.ce-editorjs-x-shiki{border-radius:10px;display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-orient:vertical;-webkit-box-direction:normal;-ms-flex-direction:column;flex-direction:column;margin:10px 0}.ce-editorjs-x-shiki__code{position:relative;float:left;min-width:100%;overflow-x:auto}.ce-editorjs-x-shiki__selector{display:-webkit-box;display:-ms-flexbox;display:flex;gap:15px;-webkit-box-pack:justify;-ms-flex-pack:justify;justify-content:space-between;z-index:12;border-bottom-style:solid;border-color:#9ca3af0d;border-bottom-width:1px;padding:8px}.ce-editorjs-x-shiki__selector-language,.ce-editorjs-x-shiki__selector-theme{font-size:13px;font-family:inherit}.ce-editorjs-x-shiki__selector-language{width:90px}.ce-editorjs-x-shiki__selector select{border:none;outline:none}.ce-editorjs-x-shiki__span{position:relative;z-index:0;padding:20px;margin:0;white-space:pre;font-size:13px;font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace}.ce-editorjs-x-shiki__textarea{white-space:pre;overflow:hidden;background-color:transparent;position:absolute;padding:20px;inset:0;color:transparent;z-index:0;font-size:13px;caret-color:#999;resize:none;border:none;font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace}.ce-editorjs-x-shiki__copy{width:24px;height:24px;cursor:pointer;position:relative;margin-right:0}.ce-editorjs-x-shiki__copy_tip{font-size:12px;width:60px;margin-left:-20px;background-color:#0c0c0c;color:#ececec;text-align:center;border-radius:6px;padding:5px 10px;position:absolute;z-index:1;top:125%;-webkit-transition:opacity .3s;transition:opacity .3s;visibility:hidden;opacity:0}.ce-editorjs-x-shiki__copy_tip:after{content:"";position:absolute;bottom:100%;left:50%;margin-left:-5px;border-width:5px;border-style:solid;border-color:transparent transparent #0c0c0c transparent}.ce-editorjs-x-shiki__copy_tip.visible{visibility:visible;opacity:1}.cdx-quote{overflow:hidden;margin:0;-webkit-box-sizing:border-box;box-sizing:border-box;word-wrap:break-word;word-break:break-all}.cdx-quote blockquote{margin:0}.cdx-block-quote{border:solid #acacac;border-width:0 0 0 3px;-webkit-box-shadow:none;box-shadow:none;color:#666;line-height:1.6em;padding:1px 0 0 12px;text-align:left}.ce-delimiter__line__wrapper{height:24px;display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-align:center;-ms-flex-align:center;align-items:center;-webkit-box-pack:center;-ms-flex-pack:center;justify-content:center}.ce-delimiter__line{-webkit-box-flex:1;-ms-flex:1;flex:1;height:2px;background-color:#eff0f1}.cdx-list{margin:0;padding:0;outline:none;display:grid;counter-reset:item;grid-gap:var(--spacing-s);padding:var(--spacing-xs);--spacing-s: 8px;--spacing-xs: 6px;--list-counter-type: numeric;--radius-border: 5px;--checkbox-background: #fff;--color-border: #C9C9C9;--color-bg-checked: #369FFF;--line-height: 1.45em;--color-bg-checked-hover: #0059AB;--color-tick: #fff;--size-checkbox: 1.2em}.cdx-list ol{padding-left:0}.cdx-list__item{line-height:var(--line-height);display:grid;grid-template-columns:auto 1fr;grid-template-rows:auto auto;grid-template-areas:"checkbox content" ". child"}.cdx-list__item-children{display:grid;grid-area:child;grid-gap:var(--spacing-s);padding-top:var(--spacing-s)}.cdx-list__item [contenteditable]{outline:none}.cdx-list__item-content{word-break:break-word;white-space:pre-wrap;grid-area:content;padding-left:var(--spacing-s)}.cdx-list__item:before{counter-increment:item;white-space:nowrap}.cdx-list-ordered .cdx-list__item:before{content:counters(item,".",var(--list-counter-type)) "."}.cdx-list-ordered{counter-reset:item}.cdx-list-unordered{padding-left:0}.cdx-list-unordered .cdx-list__item:before{content:"•"}.cdx-list-checklist .cdx-list__item:before{content:""}.cdx-list__settings .cdx-settings-button{width:50%}.cdx-list__checkbox{padding-top:calc((var(--line-height) - var(--size-checkbox)) / 2);grid-area:checkbox;width:var(--size-checkbox);height:var(--size-checkbox);display:-webkit-box;display:-ms-flexbox;display:flex;cursor:pointer}.cdx-list__checkbox svg{opacity:0;height:var(--size-checkbox);width:var(--size-checkbox);left:-1px;top:-1px;position:absolute}@media (hover: hover){.cdx-list__checkbox:not(.cdx-list__checkbox--no-hover):hover .cdx-list__checkbox-check svg{opacity:1}}.cdx-list__checkbox--checked{line-height:var(--line-height)}@media (hover: hover){.cdx-list__checkbox--checked:not(.cdx-list__checkbox--checked--no-hover):hover .cdx-checklist__checkbox-check{background:var(--color-bg-checked-hover);border-color:var(--color-bg-checked-hover)}}.cdx-list__checkbox--checked .cdx-list__checkbox-check{background:var(--color-bg-checked);border-color:var(--color-bg-checked)}.cdx-list__checkbox--checked .cdx-list__checkbox-check svg{opacity:1}.cdx-list__checkbox--checked .cdx-list__checkbox-check svg path{stroke:var(--color-tick)}.cdx-list__checkbox--checked .cdx-list__checkbox-check:before{opacity:0;visibility:visible;-webkit-transform:scale(2.5);transform:scale(2.5)}.cdx-list__checkbox-check{cursor:pointer;display:inline-block;position:relative;margin:0 auto;width:var(--size-checkbox);height:var(--size-checkbox);-webkit-box-sizing:border-box;box-sizing:border-box;border-radius:var(--radius-border);border:1px solid var(--color-border);background:var(--checkbox-background)}.cdx-list__checkbox-check:before{content:"";position:absolute;inset:0;border-radius:100%;background-color:var(--color-bg-checked);visibility:hidden;pointer-events:none;-webkit-transform:scale(1);transform:scale(1);-webkit-transition:opacity .4s,-webkit-transform .4s ease-out;transition:opacity .4s,-webkit-transform .4s ease-out;transition:transform .4s ease-out,opacity .4s;transition:transform .4s ease-out,opacity .4s,-webkit-transform .4s ease-out}.cdx-list__checkbox-check--disabled{pointer-events:none}.cdx-list-start-with-field{background:#f8f8f8;border:1px solid rgba(226,226,229,.2);border-radius:6px;padding:2px;display:grid;grid-template-columns:auto auto 1fr;grid-template-rows:auto}.cdx-list-start-with-field--invalid{background:#ffeced;border:1px solid #E13F3F}.cdx-list-start-with-field--invalid .cdx-list-start-with-field__input{color:#e13f3f}.cdx-list-start-with-field__input{font-size:14px;outline:none;font-weight:500;font-family:inherit;border:0;background:transparent;margin:0;padding:0;line-height:22px;min-width:calc(100% - var(--toolbox-buttons-size) - var(--icon-margin-right))}.cdx-list-start-with-field__input::-webkit-input-placeholder{color:var(--grayText);font-weight:500}.cdx-list-start-with-field__input::-moz-placeholder{color:var(--grayText);font-weight:500}.cdx-list-start-with-field__input:-ms-input-placeholder{color:var(--grayText);font-weight:500}.cdx-list-start-with-field__input::-ms-input-placeholder{color:var(--grayText);font-weight:500}.cdx-list-start-with-field__input::placeholder{color:var(--grayText);font-weight:500}.cdx-alert{position:relative;padding:10px;border-radius:5px;margin-bottom:10px}.cdx-alert-primary{background-color:#ebf8ff;border:1px solid #4299e1;color:#2b6cb0}.cdx-alert-secondary{background-color:#f7fafc;border:1px solid #cbd5e0;color:#222731}.cdx-alert-info{background-color:#e6fdff;border:1px solid #4cd4ce;color:#00727c}.cdx-alert-success{background-color:#f0fff4;border:1px solid #68d391;color:#2f855a}.cdx-alert-warning{background-color:#fffaf0;border:1px solid #ed8936;color:#c05621}.cdx-alert-danger{background-color:#fff5f5;border:1px solid #fc8181;color:#c53030}.cdx-alert-light{background-color:#fff;border:1px solid #edf2f7;color:#1a202c}.cdx-alert-dark{background-color:#2d3748;border:1px solid #1a202c;color:#d3d3d3}.cdx-alert-align-left{text-align:left}.cdx-alert-align-center{text-align:center}.cdx-alert-align-right{text-align:right}.cdx-alert__message{outline:none}.cdx-alert [contentEditable=true][data-placeholder]:before{position:absolute;content:attr(data-placeholder);color:#707684;font-weight:400;opacity:0}.cdx-alert [contentEditable=true][data-placeholder]:empty:before{opacity:1}.cdx-alert [contentEditable=true][data-placeholder]:empty:focus:before{opacity:0}.ce-popover__item[data-item-name=alert-primary] .ce-popover__item-icon svg #background{fill:#ebf8ff;stroke:#4299e1}.ce-popover__item[data-item-name=alert-primary] .ce-popover__item-icon svg #content{fill:#2b6cb0}.ce-popover__item[data-item-name=alert-secondary] .ce-popover__item-icon svg #background{fill:#f7fafc;stroke:#cbd5e0}.ce-popover__item[data-item-name=alert-secondary] .ce-popover__item-icon svg #content{fill:#222731}.ce-popover__item[data-item-name=alert-info] .ce-popover__item-icon svg #background{fill:#e6fdff;stroke:#4cd4ce}.ce-popover__item[data-item-name=alert-info] .ce-popover__item-icon svg #content{fill:#00727c}.ce-popover__item[data-item-name=alert-success] .ce-popover__item-icon svg #background{fill:#f0fff4;stroke:#68d391}.ce-popover__item[data-item-name=alert-success] .ce-popover__item-icon svg #content{fill:#2f855a}.ce-popover__item[data-item-name=alert-warning] .ce-popover__item-icon svg #background{fill:#fffaf0;stroke:#ed8936}.ce-popover__item[data-item-name=alert-warning] .ce-popover__item-icon svg #content{fill:#c05621}.ce-popover__item[data-item-name=alert-danger] .ce-popover__item-icon svg #background{fill:#fff5f5;stroke:#fc8181}.ce-popover__item[data-item-name=alert-danger] .ce-popover__item-icon svg #content{fill:#c53030}.ce-popover__item[data-item-name=alert-light] .ce-popover__item-icon svg #background{fill:#fff;stroke:#edf2f7}.ce-popover__item[data-item-name=alert-light] .ce-popover__item-icon svg #content{fill:#1a202c}.ce-popover__item[data-item-name=alert-dark] .ce-popover__item-icon svg #background{fill:#2d3748;stroke:#1a202c}.ce-popover__item[data-item-name=alert-dark] .ce-popover__item-icon svg #content{fill:#d3d3d3}.cdx-alert_setting__icon_wrapper{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-orient:horizontal;-webkit-box-direction:normal;-ms-flex-direction:row;flex-direction:row;-ms-flex-wrap:wrap;flex-wrap:wrap;gap:10px}.cdx-alert_setting__icon_wrapper_align{margin-top:10px}.cdx-alert_setting__icon{display:inline-block;width:24px;height:24px;text-align:center;line-height:24px;cursor:pointer}.cdx-alert_setting__icon_active{opacity:.3}.ce-popover-indent-item{cursor:default!important}.ce-popover-indent-item{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-align:center;-ms-flex-align:center;align-items:center;padding:3px}.ce-popover-indent-item[version^="2.26"]{gap:10px}.ce-popover-indent-item:hover{background-color:transparent!important}.ce-popover-indent-item .ce-popover-item__icon{width:26px;height:26px;cursor:pointer;will-change:background-color,color;transition:.3s background-color,.3s color;padding:0;border-width:0px;color:#000;background-color:#fff;border-radius:5px;-webkit-border-radius:5px;-moz-border-radius:5px;-ms-border-radius:5px;-o-border-radius:5px;-webkit-transition:.3s background-color,.3s color;-moz-transition:.3s background-color,.3s color;-ms-transition:.3s background-color,.3s color;-o-transition:.3s background-color,.3s color}.ce-popover-indent-item .ce-popover-item--disabled{color:#707684;opacity:.3;cursor:default}.ce-popover-indent-item .ce-popover-item__icon:focus{outline:none}.ce-popover-indent-item[version^="2.26"]:hover .ce-popover-item__icon,.ce-popover-indent-item[version^="2.27"]:hover .ce-popover-item__icon,.ce-popover-indent-item[version^="2.28"]:hover .ce-popover-item__icon,.ce-popover-indent-item[version^="2.29"]:hover .ce-popover-item__icon,.ce-popover-indent-item[version^="2.26"] .ce-popover-item__icon,.ce-popover-indent-item[version^="2.27"] .ce-popover-item__icon,.ce-popover-indent-item[version^="2.28"] .ce-popover-item__icon,.ce-popover-indent-item[version^="2.29"] .ce-popover-item__icon{box-shadow:0 0 0 1px #c9c9cc7a!important;-webkit-box-shadow:0 0 0 1px rgba(201,201,204,.48)!important}.ce-popover-indent-item[version^="2.26"] .ce-popover-item__icon:hover,.ce-popover-indent-item[version^="2.27"] .ce-popover-item__icon:hover,.ce-popover-indent-item[version^="2.28"] .ce-popover-item__icon:hover,.ce-popover-indent-item[version^="2.29"] .ce-popover-item__icon:hover{background-color:#eff2f5}.ce-highlight-indent{display:inline-block;height:1.6em;top:50%;position:absolute;transform:translateY(-50%);-webkit-transform:translate(0px,-50%);-moz-transform:translate(0px,-50%);-ms-transform:translate(0px,-50%);-o-transform:translate(0px,-50%)}.ce-popover-indent-item[version^="2.3"] .ce-popover-item__title{margin-left:4px}.cdx-marker{background:#f5eb6f4a;padding:3px 0}.ce-popover--inline .ce-popover--nested .ce-popover__container{width:-webkit-min-content!important;width:-moz-min-content!important;width:min-content!important;min-width:0!important;min-width:initial!important}.ce-popover--inline .ce-popover--nested .ce-popover__items{width:-webkit-max-content;width:-moz-max-content;width:max-content}.editorjs__color-selector-container{display:grid;grid-gap:10px;padding:4px}.editorjs__color-selector__container-item{width:30px;height:30px;display:block;cursor:pointer;border-radius:100%;-webkit-transition:-webkit-transform .2s ease;transition:-webkit-transform .2s ease;transition:transform .2s ease;transition:transform .2s ease,-webkit-transform .2s ease}.editorjs__color-selector__container-item:hover{-webkit-transform:scale(1.1);transform:scale(1.1)}.cdx-underline{-webkit-text-decoration:underline;text-decoration:underline}.inline-code{background:#faeff0c7;color:#b44437;padding:3px 4px;border-radius:5px;margin:0 1px;font-family:inherit;font-size:.86em;font-weight:500;letter-spacing:.3px}.tc-wrap{--color-background: #f9f9fb;--color-text-secondary: #7b7e89;--color-border: #e8e8eb;--cell-size: 34px;--toolbox-icon-size: 18px;--toolbox-padding: 6px;--toolbox-aiming-field-size: calc(var(--toolbox-icon-size) + var(--toolbox-padding)*2);--col-width: 100px 100px 100px;position:relative;height:100%;margin-top:var(--toolbox-icon-size);-webkit-box-sizing:border-box;box-sizing:border-box;display:inline-grid;z-index:0}.tc-wrap svg{vertical-align:top}@media print{.tc-wrap{border-left-color:var(--color-border);border-left-style:solid;border-left-width:1px}}@media print{.tc-wrap .tc-row:after{display:none}}.tc-table{position:relative;width:100%;height:100%;display:grid;font-size:14px;border-top:1px solid var(--color-border);border-left:1px solid var(--color-border);line-height:1.4;overflow-x:auto}.tc-table:after{width:calc(var(--cell-size));height:100%;left:calc(var(--cell-size)*-1);top:0}.tc-table:after,.tc-table:before{position:absolute;content:""}.tc-table:before{width:100%;height:var(--toolbox-aiming-field-size);top:calc(var(--toolbox-aiming-field-size)*-1);left:0}.tc-table--heading .tc-row:first-child{font-weight:600;border-bottom:2px solid var(--color-border);position:sticky;top:0;z-index:2;background:var(--color-background)}.tc-table--heading .tc-row:first-child [contenteditable]:empty:before{content:attr(heading);color:var(--color-text-secondary)}.tc-table--heading .tc-row:first-child:after{bottom:-2px;border-bottom:2px solid var(--color-border)}.tc-add-column,.tc-add-row{display:-webkit-box;display:-ms-flexbox;display:flex;color:var(--color-text-secondary)}@media print{.tc-add{display:none}}.tc-add-column{display:grid;border-top:1px solid var(--color-border);grid-auto-rows:var(--cell-size);-webkit-box-align:center;-ms-flex-align:center;align-items:center;justify-items:center}.tc-add-column svg{padding:5px;position:sticky;top:0;background-color:var(--color-background)}.tc-add-column--disabled{visibility:hidden}@media print{.tc-add-column{display:none}}.tc-add-row{height:var(--cell-size);-webkit-box-align:center;-ms-flex-align:center;align-items:center;padding-left:4px;position:relative}.tc-add-row--disabled{display:none}.tc-add-row:before{content:"";position:absolute;right:calc(var(--cell-size)*-1);width:var(--cell-size);height:100%}@media print{.tc-add-row{display:none}}.tc-add-column,.tc-add-row{-webkit-transition:0s;transition:0s;cursor:pointer;will-change:background-color}.tc-add-column:hover,.tc-add-row:hover{-webkit-transition:background-color .1s ease;transition:background-color .1s ease;background-color:var(--color-background)}.tc-add-row{margin-top:1px}.tc-add-row:hover:before{-webkit-transition:.1s;transition:.1s;background-color:var(--color-background)}.tc-row{display:grid;grid-template-columns:var(--col-width);position:relative;border-bottom:1px solid var(--color-border)}.tc-row--selected{background:var(--color-background)}.tc-row--selected:after{background:var(--color-background)}.tc-cell{border-right:1px solid var(--color-border);padding:6px 12px;overflow:hidden;outline:none;line-break:normal}.tc-cell--selected{background:var(--color-background)}.tc-wrap--readonly .tc-row:after{display:none}.tc-toolbox{--toolbox-padding: 6px;--popover-margin: 30px;--toggler-click-zone-size: 30px;--toggler-dots-color: #7b7e89;--toggler-dots-color-hovered: #1d202b;position:absolute;cursor:pointer;z-index:1;opacity:0;-webkit-transition:opacity .1s;transition:opacity .1s;will-change:left,opacity}.tc-toolbox--column{top:calc(var(--toggler-click-zone-size)*-1);-webkit-transform:translate(calc(var(--toggler-click-zone-size)*-1/2));transform:translate(calc(var(--toggler-click-zone-size)*-1/2));will-change:left,opacity}.tc-toolbox--row{left:calc(var(--popover-margin)*-1);-webkit-transform:translateY(calc(var(--toggler-click-zone-size)*-1/2));transform:translateY(calc(var(--toggler-click-zone-size)*-1/2));margin-top:-1px;will-change:top,opacity}.tc-toolbox--showed{opacity:1}.tc-toolbox .tc-popover{position:absolute;top:0;left:var(--popover-margin)}.tc-toolbox__toggler{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-align:center;-ms-flex-align:center;align-items:center;-webkit-box-pack:center;-ms-flex-pack:center;justify-content:center;width:var(--toggler-click-zone-size);height:var(--toggler-click-zone-size);color:var(--toggler-dots-color);opacity:0;-webkit-transition:opacity .15s ease;transition:opacity .15s ease;will-change:opacity}.tc-toolbox__toggler:hover{color:var(--toggler-dots-color-hovered)}.tc-toolbox__toggler svg{fill:currentColor}.tc-wrap:hover .tc-toolbox__toggler{opacity:1}.tc-settings .cdx-settings-button{width:50%;margin:0}.tc-popover{--color-border: #eaeaea;--color-background: #fff;--color-background-hover: rgba(232, 232, 235, .49);--color-background-confirm: #e24a4a;--color-background-confirm-hover: #d54040;--color-text-confirm: #fff;background:var(--color-background);border:1px solid var(--color-border);-webkit-box-shadow:0 3px 15px -3px rgba(13,20,33,.12941);box-shadow:0 3px 15px -3px #0d142121;border-radius:6px;padding:6px;display:none;will-change:opacity,transform}.tc-popover--opened{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-animation:menuShowing .1s cubic-bezier(.215,.61,.355,1) forwards;animation:menuShowing .1s cubic-bezier(.215,.61,.355,1) forwards}.tc-popover__item{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-align:center;-ms-flex-align:center;align-items:center;padding:2px 14px 2px 2px;border-radius:5px;cursor:pointer;white-space:nowrap;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.tc-popover__item:hover{background:var(--color-background-hover)}.tc-popover__item:not(:last-of-type){margin-bottom:2px}.tc-popover__item-icon{display:-webkit-inline-box;display:-ms-inline-flexbox;display:inline-flex;width:26px;height:26px;-webkit-box-align:center;-ms-flex-align:center;align-items:center;-webkit-box-pack:center;-ms-flex-pack:center;justify-content:center;background:var(--color-background);border-radius:5px;border:1px solid var(--color-border);margin-right:8px}.tc-popover__item-label{line-height:22px;font-size:14px;font-weight:500}.tc-popover__item--confirm{background:var(--color-background-confirm);color:var(--color-text-confirm)}.tc-popover__item--confirm:hover{background-color:var(--color-background-confirm-hover)}.tc-popover__item--confirm .tc-popover__item-icon{background:var(--color-background-confirm);border-color:#0000001a}.tc-popover__item--confirm .tc-popover__item-icon svg{-webkit-transition:-webkit-transform .2s ease-in;transition:-webkit-transform .2s ease-in;transition:transform .2s ease-in;transition:transform .2s ease-in,-webkit-transform .2s ease-in;-webkit-transform:rotate(90deg) scale(1.2);transform:rotate(90deg) scale(1.2)}.tc-popover__item--hidden{display:none}@-webkit-keyframes menuShowing{0%{opacity:0;-webkit-transform:translateY(-8px) scale(.9);transform:translateY(-8px) scale(.9)}70%{opacity:1;-webkit-transform:translateY(2px);transform:translateY(2px)}to{-webkit-transform:translateY(0);transform:translateY(0)}}@keyframes menuShowing{0%{opacity:0;-webkit-transform:translateY(-8px) scale(.9);transform:translateY(-8px) scale(.9)}70%{opacity:1;-webkit-transform:translateY(2px);transform:translateY(2px)}to{-webkit-transform:translateY(0);transform:translateY(0)}}.cell-resizable{cursor:col-resize}.image-tool{--bg-color: #cdd1e0;--front-color: #388ae5;--border-color: #e8e8eb;display:inline-block}.image-tool__image{border-radius:3px;overflow:hidden;margin-bottom:10px;padding-bottom:0;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;pointer-events:none}.image-tool__image-picture{max-width:100%;vertical-align:bottom;display:inline-block;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;pointer-events:none}.image-tool__image-preloader{width:50px;height:50px;border-radius:50%;background-size:cover;margin:auto;position:relative;background-color:var(--bg-color);background-position:center center}.image-tool__image-preloader:after{content:"";position:absolute;z-index:3;width:60px;height:60px;border-radius:50%;border:2px solid var(--bg-color);border-top-color:var(--front-color);left:50%;top:50%;margin-top:-30px;margin-left:-30px;-webkit-animation:image-preloader-spin 2s infinite linear;animation:image-preloader-spin 2s infinite linear;-webkit-box-sizing:border-box;box-sizing:border-box}.image-tool__caption{visibility:hidden;position:absolute;bottom:0;left:0;margin-bottom:10px}.image-tool__caption[contentEditable=true][data-placeholder]:before{position:absolute!important}.image-tool__caption[contentEditable=true][data-placeholder]:before{content:attr(data-placeholder);color:#707684;font-weight:400;display:none}.image-tool__caption[contentEditable=true][data-placeholder]:empty:before{display:block}.image-tool__caption[contentEditable=true][data-placeholder]:empty:focus:before{display:none}.image-tool--empty .image-tool__image,.image-tool--empty .image-tool__image-preloader{display:none}.image-tool--empty .image-tool__caption,.image-tool--uploading .image-tool__caption{visibility:hidden!important}.image-tool .cdx-button{display:none;-webkit-box-align:center;-ms-flex-align:center;align-items:center;-webkit-box-pack:center;-ms-flex-pack:center;justify-content:center}.image-tool .cdx-button svg{height:auto;margin:0 6px 0 0}.image-tool--filled .cdx-button,.image-tool--filled .image-tool__image-preloader{display:none}.image-tool--uploading .image-tool__image{min-height:200px;display:-webkit-box;display:-ms-flexbox;display:flex;border:1px solid var(--border-color);background-color:#fff}.image-tool--uploading .image-tool__image-picture,.image-tool--uploading .cdx-button{display:none}.image-tool--withBorder .image-tool__image{border:1px solid var(--border-color)}.image-tool--withBackground .image-tool__image{padding:15px;background:var(--bg-color)}.image-tool--withBackground .image-tool__image-picture{max-width:60%;margin:0 auto}.image-tool--stretched .image-tool__image-picture{width:100%}.image-tool--caption .image-tool__caption{visibility:visible}.image-tool--caption{padding-bottom:50px}@-webkit-keyframes image-preloader-spin{0%{-webkit-transform:rotate(0);transform:rotate(0)}to{-webkit-transform:rotate(360deg);transform:rotate(360deg)}}@keyframes image-preloader-spin{0%{-webkit-transform:rotate(0);transform:rotate(0)}to{-webkit-transform:rotate(360deg);transform:rotate(360deg)}}.cdx-image-tool-tune--floatLeft .cdx-block,.cdx-image-tool-tune--center .cdx-block,.cdx-image-tool-tune--floatRight .cdx-block,.cdx-image-tool-tune--floatLeft .image-tool__image,.cdx-image-tool-tune--center .image-tool__image,.cdx-image-tool-tune--floatRight .image-tool__image{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-orient:vertical;-webkit-box-direction:normal;-ms-flex-direction:column;flex-direction:column;-webkit-box-align:center;-ms-flex-align:center;align-items:center}:root{--primary: #2492F5;--primary-content: #E9F4FE}.cdx-settings-button--active{background:#e9f4fe;color:#2492f5}.cdx-settings-button:hover{background:#e9f4fe}.cdx-image-tool-tune--center{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-pack:center;-ms-flex-pack:center;justify-content:center}@media all and (min-width: 470px){.codex-editor:not(.read-only) .cdx-image-tool-tune--floatLeft.ce-block__content,.codex-editor:not(.read-only) .cdx-image-tool-tune--floatRight.ce-block__content{min-height:20px}.cdx-image-tool-tune--floatLeft.ce-block__content .image-tool__image,.cdx-image-tool-tune--floatRight.ce-block__content .image-tool__image{margin-top:40px}.cdx-image-tool-tune--floatLeft.ce-block__content .image-tool__image{margin-left:20px}.cdx-image-tool-tune--floatRight.ce-block__content .image-tool__image{margin-right:20px}.cdx-image-tool-tune--floatLeft.ce-block__content .cdx-input,.cdx-image-tool-tune--floatRight.ce-block__content .cdx-input{width:calc(100% - 20px)}.cdx-image-tool-tune--floatLeft.ce-block__content .cdx-input{margin-left:20px}.cdx-image-tool-tune--floatRight.ce-block__content .cdx-input{margin-right:20px}.cdx-image-tool-tune--floatLeft .cdx-block{float:left;margin-right:10px}.cdx-image-tool-tune--floatRight .cdx-block{float:right;margin-left:10px}.cdx-image-tool-tune--sizeSmall .cdx-block{max-width:25%!important}.cdx-image-tool-tune--sizeMiddle .cdx-block{max-width:50%!important}.cdx-image-tool-tune--sizeLarge .cdx-block{max-width:75%!important}}.cdx-image-tool-tune--sizeLarge img,.cdx-image-tool-tune--sizeSmall img,.cdx-image-tool-tune--sizeMiddle img{-o-object-fit:cover;object-fit:cover;max-width:100%}.codex-editor.read-only .cdx-input.image-tool__caption:empty,.read-only>.codex-editor .cdx-input.image-tool__caption:empty{display:none}.cdx-image-tool-tune--resize .cdx-block{position:relative;overflow:visible}.cdx-image-tool-tune--resize .cdx-block .resizable{display:none}.cdx-image-tool-tune--resize .image-tool__image-picture{width:100%!important}.cdx-image-tool-tune--resize .cdx-block:hover .resizable{display:block}.cdx-image-tool-tune--resize .cdx-block .resizable .resizers .resizer{width:8px;height:8px;border-radius:50%;background:#e9f4fe;border:3px solid #2492F5;position:absolute}.cdx-image-tool-tune--resize .cdx-block .resizable .resizers .resizer.top-left{left:-8px;top:2px;cursor:nwse-resize}.cdx-image-tool-tune--resize .cdx-block .resizable .resizers .resizer.top-right{right:-8px;top:1px;cursor:nesw-resize}.cdx-image-tool-tune--resize .cdx-block .resizable .resizers .resizer.bottom-left{left:-9px;bottom:10px;cursor:nesw-resize}.cdx-image-tool-tune--resize .cdx-block .resizable .resizers .resizer.bottom-right{right:-9px;bottom:10px;cursor:nwse-resize}.cdx-image-tool-tune--crop:hover,.cdx-image-tool-tune--crop.isCropping,.cdx-image-tool-tune--resize:hover{z-index:2}.cdx-image-tool-tune--crop .image-tool__image{position:relative}.cdx-image-tool-tune--crop .isCropping .image-tool__image{min-height:600px;min-width:100%}.cdx-image-tool-tune--crop .image-tool__image .crop-btn,.cdx-image-tool-tune--crop .image-tool__image .crop-save{position:absolute;top:0;left:0;padding:7px;background:#2492f5;color:#e9f4fe;text-align:center;line-height:20px;cursor:pointer;display:none}.cdx-image-tool-tune--crop .image-tool__image:hover .crop-btn,.cdx-image-tool-tune--crop .image-tool__image:hover .crop-save{display:block}.cdx-image-tool-tune--crop .image-tool__image img.isCropped{position:absolute;min-width:0;min-width:initial;max-width:none;max-width:initial;min-height:0;min-height:initial;max-height:none;max-height:initial}.cdx-image-tool-tune--crop .cdx-block.image-tool.isCropping{min-width:0!important;min-width:initial!important;max-width:none!important;max-width:initial!important;min-height:0!important;min-height:initial!important;max-height:none!important;max-height:initial!important}.image-tool__caption{background-color:#fff}.image-tool{position:relative;z-index:1}.cdx-image-tool-tune{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-pack:start;-ms-flex-pack:start;justify-content:flex-start;gap:4px;width:100%}')),document.head.appendChild(e)}}catch(o){console.error("vite-plugin-css-injected-by-js",o)}})();
2
- import { defineComponent as Nt, inject as zt, onMounted as Ft, toRaw as Pt, onUnmounted as Wt, createElementBlock as $t, openBlock as qt } from "vue";
1
+ (function(){"use strict";try{if(typeof document!="undefined"){var e=document.createElement("style");e.appendChild(document.createTextNode(':root{--color-border: #EFF0F1}.ebl-editor{cursor:text;font-size:16px;font-weight:400;background-color:#fff}@media (min-width: 1050px){.ce-block__content,.ce-toolbar__content{max-width:700px}}.ce-toolbar,.ce-inline-toolbar{z-index:1000}.ce-toolbar__plus{border:1px solid #EFF0F1}.ce-toolbar .ce-popover__items{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-orient:horizontal;-webkit-box-direction:normal;-ms-flex-direction:row;flex-direction:row;-ms-flex-wrap:wrap;flex-wrap:wrap}.ce-toolbar .ce-popover__items .ce-popover-item{position:relative}.ce-toolbar .ce-popover__items .ce-popover-item__title{display:none}.ce-toolbar .ce-popover-item-html,.ce-toolbar .ce-popover-item-separator,.ce-toolbar .ce-popover-item[data-item-name=convert-to]{width:100%}.ce-toolbar .ce-popover-item[data-item-name=convert-to] .ce-popover-item__title{display:block}.ce-inline-toolbar .ce-popover__items{display:-webkit-box!important;display:-ms-flexbox!important;display:flex!important}.ce-inline-toolbar .ce-popover__items{-webkit-box-orient:horizontal;-webkit-box-direction:normal;-ms-flex-direction:row;flex-direction:row;-ms-flex-wrap:wrap;flex-wrap:wrap}.ce-inline-toolbar .ce-popover__items .ce-popover-item__title{display:none}.ce-block--drop-target .ce-block__content:before{content:"";position:absolute;top:50%;left:-20px;margin-top:-1px;height:8px;width:8px;border:solid #a0a0a0;border-width:1px 1px 0 0;-webkit-transform-origin:right;transform-origin:right;-webkit-transform:rotate(45deg);transform:rotate(45deg)}.ce-block--drop-target .ce-block__content:after{background:none}.ce-header{padding:.6em 0 3px;margin:0;line-height:1.25em;outline:none}.ce-header p,.ce-header div{padding:0!important;margin:0!important}.ce-tune-alignment--right{text-align:right}.ce-tune-alignment--center{text-align:center}.ce-tune-alignment--left{text-align:left}.ce-paragraph{line-height:1.6em;outline:none}.ce-block:only-of-type .ce-paragraph[data-placeholder-active]:empty:before,.ce-block:only-of-type .ce-paragraph[data-placeholder-active][data-empty=true]:before{content:attr(data-placeholder-active)}.ce-paragraph p:first-of-type{margin-top:0}.ce-paragraph p:last-of-type{margin-bottom:0}.ce-editorjs-x-shiki{border-radius:10px;display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-orient:vertical;-webkit-box-direction:normal;-ms-flex-direction:column;flex-direction:column;margin:10px 0}.ce-editorjs-x-shiki__code{position:relative;float:left;min-width:100%;overflow-x:auto}.ce-editorjs-x-shiki__selector{display:-webkit-box;display:-ms-flexbox;display:flex;gap:15px;-webkit-box-pack:justify;-ms-flex-pack:justify;justify-content:space-between;z-index:12;border-bottom-style:solid;border-color:#9ca3af0d;border-bottom-width:1px;padding:8px}.ce-editorjs-x-shiki__selector-language,.ce-editorjs-x-shiki__selector-theme{font-size:13px;font-family:inherit}.ce-editorjs-x-shiki__selector-language{width:90px}.ce-editorjs-x-shiki__selector select{border:none;outline:none}.ce-editorjs-x-shiki__span{position:relative;z-index:0;padding:20px 20px 20px 55px;margin:0;white-space:pre;font-size:13px;font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace}.ce-editorjs-x-shiki__textarea{white-space:pre;overflow:hidden;background-color:transparent;position:absolute;padding:20px 20px 20px 55px;inset:0;color:transparent;z-index:0;font-size:13px;caret-color:#999;resize:none;border:none;font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace}.ce-editorjs-x-shiki__copy{width:24px;height:24px;cursor:pointer;position:relative;margin-right:0}.ce-editorjs-x-shiki__copy_tip{font-size:12px;width:60px;margin-left:-20px;background-color:#0c0c0c;color:#ececec;text-align:center;border-radius:6px;padding:5px 10px;position:absolute;z-index:1;top:125%;-webkit-transition:opacity .3s;transition:opacity .3s;visibility:hidden;opacity:0}.ce-editorjs-x-shiki__copy_tip:after{content:"";position:absolute;bottom:100%;left:50%;margin-left:-5px;border-width:5px;border-style:solid;border-color:transparent transparent #0c0c0c transparent}.ce-editorjs-x-shiki__copy_tip.visible{visibility:visible;opacity:1}.ce-editorjs-x-shiki__span.shiki .line:before{content:attr(data-line);width:40px;display:inline-block;text-align:right;color:#888;position:absolute;left:0}.cdx-quote{overflow:hidden;margin:0;-webkit-box-sizing:border-box;box-sizing:border-box;word-wrap:break-word;word-break:break-all}.cdx-quote blockquote{margin:0}.cdx-block-quote{border:solid #acacac;border-width:0 0 0 3px;-webkit-box-shadow:none;box-shadow:none;color:#666;line-height:1.6em;padding:1px 0 0 12px;text-align:left}.ce-delimiter__line__wrapper{height:24px;display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-align:center;-ms-flex-align:center;align-items:center;-webkit-box-pack:center;-ms-flex-pack:center;justify-content:center}.ce-delimiter__line{-webkit-box-flex:1;-ms-flex:1;flex:1;height:2px;background-color:#eff0f1}.cdx-list{margin:0;padding:0;outline:none;display:grid;counter-reset:item;grid-gap:var(--spacing-s);padding:var(--spacing-xs);--spacing-s: 8px;--spacing-xs: 6px;--list-counter-type: numeric;--radius-border: 5px;--checkbox-background: #fff;--color-border: #C9C9C9;--color-bg-checked: #369FFF;--line-height: 1.45em;--color-bg-checked-hover: #0059AB;--color-tick: #fff;--size-checkbox: 1.2em}.cdx-list ol{padding-left:0}.cdx-list__item{line-height:var(--line-height);display:grid;grid-template-columns:auto 1fr;grid-template-rows:auto auto;grid-template-areas:"checkbox content" ". child"}.cdx-list__item-children{display:grid;grid-area:child;grid-gap:var(--spacing-s);padding-top:var(--spacing-s)}.cdx-list__item [contenteditable]{outline:none}.cdx-list__item-content{word-break:break-word;white-space:pre-wrap;grid-area:content;padding-left:var(--spacing-s)}.cdx-list__item:before{counter-increment:item;white-space:nowrap}.cdx-list-ordered .cdx-list__item:before{content:counters(item,".",var(--list-counter-type)) "."}.cdx-list-ordered{counter-reset:item}.cdx-list-unordered{padding-left:0}.cdx-list-unordered .cdx-list__item:before{content:"•"}.cdx-list-checklist .cdx-list__item:before{content:""}.cdx-list__settings .cdx-settings-button{width:50%}.cdx-list__checkbox{padding-top:calc((var(--line-height) - var(--size-checkbox)) / 2);grid-area:checkbox;width:var(--size-checkbox);height:var(--size-checkbox);display:-webkit-box;display:-ms-flexbox;display:flex;cursor:pointer}.cdx-list__checkbox svg{opacity:0;height:var(--size-checkbox);width:var(--size-checkbox);left:-1px;top:-1px;position:absolute}@media (hover: hover){.cdx-list__checkbox:not(.cdx-list__checkbox--no-hover):hover .cdx-list__checkbox-check svg{opacity:1}}.cdx-list__checkbox--checked{line-height:var(--line-height)}@media (hover: hover){.cdx-list__checkbox--checked:not(.cdx-list__checkbox--checked--no-hover):hover .cdx-checklist__checkbox-check{background:var(--color-bg-checked-hover);border-color:var(--color-bg-checked-hover)}}.cdx-list__checkbox--checked .cdx-list__checkbox-check{background:var(--color-bg-checked);border-color:var(--color-bg-checked)}.cdx-list__checkbox--checked .cdx-list__checkbox-check svg{opacity:1}.cdx-list__checkbox--checked .cdx-list__checkbox-check svg path{stroke:var(--color-tick)}.cdx-list__checkbox--checked .cdx-list__checkbox-check:before{opacity:0;visibility:visible;-webkit-transform:scale(2.5);transform:scale(2.5)}.cdx-list__checkbox-check{cursor:pointer;display:inline-block;position:relative;margin:0 auto;width:var(--size-checkbox);height:var(--size-checkbox);-webkit-box-sizing:border-box;box-sizing:border-box;border-radius:var(--radius-border);border:1px solid var(--color-border);background:var(--checkbox-background)}.cdx-list__checkbox-check:before{content:"";position:absolute;inset:0;border-radius:100%;background-color:var(--color-bg-checked);visibility:hidden;pointer-events:none;-webkit-transform:scale(1);transform:scale(1);-webkit-transition:opacity .4s,-webkit-transform .4s ease-out;transition:opacity .4s,-webkit-transform .4s ease-out;transition:transform .4s ease-out,opacity .4s;transition:transform .4s ease-out,opacity .4s,-webkit-transform .4s ease-out}.cdx-list__checkbox-check--disabled{pointer-events:none}.cdx-list-start-with-field{background:#F8F8F8;border:1px solid rgba(226,226,229,.2);border-radius:6px;padding:2px;display:grid;grid-template-columns:auto auto 1fr;grid-template-rows:auto}.cdx-list-start-with-field--invalid{background:#FFECED;border:1px solid #E13F3F}.cdx-list-start-with-field--invalid .cdx-list-start-with-field__input{color:#e13f3f}.cdx-list-start-with-field__input{font-size:14px;outline:none;font-weight:500;font-family:inherit;border:0;background:transparent;margin:0;padding:0;line-height:22px;min-width:calc(100% - var(--toolbox-buttons-size) - var(--icon-margin-right))}.cdx-list-start-with-field__input::-webkit-input-placeholder{color:var(--grayText);font-weight:500}.cdx-list-start-with-field__input::-moz-placeholder{color:var(--grayText);font-weight:500}.cdx-list-start-with-field__input:-ms-input-placeholder{color:var(--grayText);font-weight:500}.cdx-list-start-with-field__input::-ms-input-placeholder{color:var(--grayText);font-weight:500}.cdx-list-start-with-field__input::placeholder{color:var(--grayText);font-weight:500}.cdx-alert{position:relative;padding:10px;border-radius:5px;margin-bottom:10px}.cdx-alert-primary{background-color:#ebf8ff;border:1px solid #4299e1;color:#2b6cb0}.cdx-alert-secondary{background-color:#f7fafc;border:1px solid #cbd5e0;color:#222731}.cdx-alert-info{background-color:#e6fdff;border:1px solid #4cd4ce;color:#00727c}.cdx-alert-success{background-color:#f0fff4;border:1px solid #68d391;color:#2f855a}.cdx-alert-warning{background-color:#fffaf0;border:1px solid #ed8936;color:#c05621}.cdx-alert-danger{background-color:#fff5f5;border:1px solid #fc8181;color:#c53030}.cdx-alert-light{background-color:#fff;border:1px solid #edf2f7;color:#1a202c}.cdx-alert-dark{background-color:#2d3748;border:1px solid #1a202c;color:#d3d3d3}.cdx-alert-align-left{text-align:left}.cdx-alert-align-center{text-align:center}.cdx-alert-align-right{text-align:right}.cdx-alert__message{outline:none}.cdx-alert [contentEditable=true][data-placeholder]:before{position:absolute;content:attr(data-placeholder);color:#707684;font-weight:400;opacity:0}.cdx-alert [contentEditable=true][data-placeholder]:empty:before{opacity:1}.cdx-alert [contentEditable=true][data-placeholder]:empty:focus:before{opacity:0}.ce-popover__item[data-item-name=alert-primary] .ce-popover__item-icon svg #background{fill:#ebf8ff;stroke:#4299e1}.ce-popover__item[data-item-name=alert-primary] .ce-popover__item-icon svg #content{fill:#2b6cb0}.ce-popover__item[data-item-name=alert-secondary] .ce-popover__item-icon svg #background{fill:#f7fafc;stroke:#cbd5e0}.ce-popover__item[data-item-name=alert-secondary] .ce-popover__item-icon svg #content{fill:#222731}.ce-popover__item[data-item-name=alert-info] .ce-popover__item-icon svg #background{fill:#e6fdff;stroke:#4cd4ce}.ce-popover__item[data-item-name=alert-info] .ce-popover__item-icon svg #content{fill:#00727c}.ce-popover__item[data-item-name=alert-success] .ce-popover__item-icon svg #background{fill:#f0fff4;stroke:#68d391}.ce-popover__item[data-item-name=alert-success] .ce-popover__item-icon svg #content{fill:#2f855a}.ce-popover__item[data-item-name=alert-warning] .ce-popover__item-icon svg #background{fill:#fffaf0;stroke:#ed8936}.ce-popover__item[data-item-name=alert-warning] .ce-popover__item-icon svg #content{fill:#c05621}.ce-popover__item[data-item-name=alert-danger] .ce-popover__item-icon svg #background{fill:#fff5f5;stroke:#fc8181}.ce-popover__item[data-item-name=alert-danger] .ce-popover__item-icon svg #content{fill:#c53030}.ce-popover__item[data-item-name=alert-light] .ce-popover__item-icon svg #background{fill:#fff;stroke:#edf2f7}.ce-popover__item[data-item-name=alert-light] .ce-popover__item-icon svg #content{fill:#1a202c}.ce-popover__item[data-item-name=alert-dark] .ce-popover__item-icon svg #background{fill:#2d3748;stroke:#1a202c}.ce-popover__item[data-item-name=alert-dark] .ce-popover__item-icon svg #content{fill:#d3d3d3}.cdx-alert_setting__icon_wrapper{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-orient:horizontal;-webkit-box-direction:normal;-ms-flex-direction:row;flex-direction:row;-ms-flex-wrap:wrap;flex-wrap:wrap;gap:10px}.cdx-alert_setting__icon_wrapper_align{margin-top:10px}.cdx-alert_setting__icon{display:inline-block;width:24px;height:24px;text-align:center;line-height:24px;cursor:pointer}.cdx-alert_setting__icon_active{opacity:.3}.ce-popover-indent-item{cursor:default!important}.ce-popover-indent-item{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-align:center;-ms-flex-align:center;align-items:center;padding:3px}.ce-popover-indent-item[version^="2.26"]{gap:10px}.ce-popover-indent-item:hover{background-color:transparent!important}.ce-popover-indent-item .ce-popover-item__icon{width:26px;height:26px;cursor:pointer;will-change:background-color,color;transition:.3s background-color,.3s color;padding:0;border-width:0px;color:#000;background-color:#fff;border-radius:5px;-webkit-border-radius:5px;-moz-border-radius:5px;-ms-border-radius:5px;-o-border-radius:5px;-webkit-transition:.3s background-color,.3s color;-moz-transition:.3s background-color,.3s color;-ms-transition:.3s background-color,.3s color;-o-transition:.3s background-color,.3s color}.ce-popover-indent-item .ce-popover-item--disabled{color:#707684;opacity:.3;cursor:default}.ce-popover-indent-item .ce-popover-item__icon:focus{outline:none}.ce-popover-indent-item[version^="2.26"]:hover .ce-popover-item__icon,.ce-popover-indent-item[version^="2.27"]:hover .ce-popover-item__icon,.ce-popover-indent-item[version^="2.28"]:hover .ce-popover-item__icon,.ce-popover-indent-item[version^="2.29"]:hover .ce-popover-item__icon,.ce-popover-indent-item[version^="2.26"] .ce-popover-item__icon,.ce-popover-indent-item[version^="2.27"] .ce-popover-item__icon,.ce-popover-indent-item[version^="2.28"] .ce-popover-item__icon,.ce-popover-indent-item[version^="2.29"] .ce-popover-item__icon{box-shadow:0 0 0 1px #c9c9cc7a!important;-webkit-box-shadow:0 0 0 1px rgba(201,201,204,.48)!important}.ce-popover-indent-item[version^="2.26"] .ce-popover-item__icon:hover,.ce-popover-indent-item[version^="2.27"] .ce-popover-item__icon:hover,.ce-popover-indent-item[version^="2.28"] .ce-popover-item__icon:hover,.ce-popover-indent-item[version^="2.29"] .ce-popover-item__icon:hover{background-color:#eff2f5}.ce-highlight-indent{display:inline-block;height:1.6em;top:50%;position:absolute;transform:translateY(-50%);-webkit-transform:translate(0px,-50%);-moz-transform:translate(0px,-50%);-ms-transform:translate(0px,-50%);-o-transform:translate(0px,-50%)}.ce-popover-indent-item[version^="2.3"] .ce-popover-item__title{margin-left:4px}.cdx-marker{background:rgba(245,235,111,.29);padding:3px 0}.ce-popover--inline .ce-popover--nested .ce-popover__container{width:-webkit-min-content!important;width:-moz-min-content!important;width:min-content!important;min-width:0!important;min-width:initial!important}.ce-popover--inline .ce-popover--nested .ce-popover__items{width:-webkit-max-content;width:-moz-max-content;width:max-content}.editorjs__color-selector-container{display:grid;grid-gap:10px;padding:4px}.editorjs__color-selector__container-item{width:30px;height:30px;display:block;cursor:pointer;border-radius:100%;-webkit-transition:-webkit-transform .2s ease;transition:-webkit-transform .2s ease;transition:transform .2s ease;transition:transform .2s ease,-webkit-transform .2s ease}.editorjs__color-selector__container-item:hover{-webkit-transform:scale(1.1);transform:scale(1.1)}.cdx-underline{-webkit-text-decoration:underline;text-decoration:underline}.inline-code{background:rgba(250,239,240,.78);color:#b44437;padding:3px 4px;border-radius:5px;margin:0 1px;font-family:inherit;font-size:.86em;font-weight:500;letter-spacing:.3px}.tc-wrap{--color-background: #f9f9fb;--color-text-secondary: #7b7e89;--color-border: #e8e8eb;--cell-size: 34px;--toolbox-icon-size: 18px;--toolbox-padding: 6px;--toolbox-aiming-field-size: calc(var(--toolbox-icon-size) + var(--toolbox-padding)*2);--col-width: 100px 100px 100px;position:relative;height:100%;margin-top:var(--toolbox-icon-size);-webkit-box-sizing:border-box;box-sizing:border-box;display:inline-grid;z-index:0}.tc-wrap svg{vertical-align:top}@media print{.tc-wrap{border-left-color:var(--color-border);border-left-style:solid;border-left-width:1px}}@media print{.tc-wrap .tc-row:after{display:none}}.tc-table{position:relative;width:100%;height:100%;display:grid;font-size:14px;border-top:1px solid var(--color-border);border-left:1px solid var(--color-border);line-height:1.4;overflow-x:auto}.tc-table:after{width:calc(var(--cell-size));height:100%;left:calc(var(--cell-size)*-1);top:0}.tc-table:after,.tc-table:before{position:absolute;content:""}.tc-table:before{width:100%;height:var(--toolbox-aiming-field-size);top:calc(var(--toolbox-aiming-field-size)*-1);left:0}.tc-table--heading .tc-row:first-child{font-weight:600;border-bottom:2px solid var(--color-border);position:sticky;top:0;z-index:2;background:var(--color-background)}.tc-table--heading .tc-row:first-child [contenteditable]:empty:before{content:attr(heading);color:var(--color-text-secondary)}.tc-table--heading .tc-row:first-child:after{bottom:-2px;border-bottom:2px solid var(--color-border)}.tc-add-column,.tc-add-row{display:-webkit-box;display:-ms-flexbox;display:flex;color:var(--color-text-secondary)}@media print{.tc-add{display:none}}.tc-add-column{display:grid;border-top:1px solid var(--color-border);grid-auto-rows:var(--cell-size);-webkit-box-align:center;-ms-flex-align:center;align-items:center;justify-items:center}.tc-add-column svg{padding:5px;position:sticky;top:0;background-color:var(--color-background)}.tc-add-column--disabled{visibility:hidden}@media print{.tc-add-column{display:none}}.tc-add-row{height:var(--cell-size);-webkit-box-align:center;-ms-flex-align:center;align-items:center;padding-left:4px;position:relative}.tc-add-row--disabled{display:none}.tc-add-row:before{content:"";position:absolute;right:calc(var(--cell-size)*-1);width:var(--cell-size);height:100%}@media print{.tc-add-row{display:none}}.tc-add-column,.tc-add-row{-webkit-transition:0s;transition:0s;cursor:pointer;will-change:background-color}.tc-add-column:hover,.tc-add-row:hover{-webkit-transition:background-color .1s ease;transition:background-color .1s ease;background-color:var(--color-background)}.tc-add-row{margin-top:1px}.tc-add-row:hover:before{-webkit-transition:.1s;transition:.1s;background-color:var(--color-background)}.tc-row{display:grid;grid-template-columns:var(--col-width);position:relative;border-bottom:1px solid var(--color-border)}.tc-row--selected{background:var(--color-background)}.tc-row--selected:after{background:var(--color-background)}.tc-cell{border-right:1px solid var(--color-border);padding:6px 12px;overflow:hidden;outline:none;line-break:normal}.tc-cell--selected{background:var(--color-background)}.tc-wrap--readonly .tc-row:after{display:none}.tc-toolbox{--toolbox-padding: 6px;--popover-margin: 30px;--toggler-click-zone-size: 30px;--toggler-dots-color: #7b7e89;--toggler-dots-color-hovered: #1d202b;position:absolute;cursor:pointer;z-index:1;opacity:0;-webkit-transition:opacity .1s;transition:opacity .1s;will-change:left,opacity}.tc-toolbox--column{top:calc(var(--toggler-click-zone-size)*-1);-webkit-transform:translate(calc(var(--toggler-click-zone-size)*-1/2));transform:translate(calc(var(--toggler-click-zone-size)*-1/2));will-change:left,opacity}.tc-toolbox--row{left:calc(var(--popover-margin)*-1);-webkit-transform:translateY(calc(var(--toggler-click-zone-size)*-1/2));transform:translateY(calc(var(--toggler-click-zone-size)*-1/2));margin-top:-1px;will-change:top,opacity}.tc-toolbox--showed{opacity:1}.tc-toolbox .tc-popover{position:absolute;top:0;left:var(--popover-margin)}.tc-toolbox__toggler{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-align:center;-ms-flex-align:center;align-items:center;-webkit-box-pack:center;-ms-flex-pack:center;justify-content:center;width:var(--toggler-click-zone-size);height:var(--toggler-click-zone-size);color:var(--toggler-dots-color);opacity:0;-webkit-transition:opacity .15s ease;transition:opacity .15s ease;will-change:opacity}.tc-toolbox__toggler:hover{color:var(--toggler-dots-color-hovered)}.tc-toolbox__toggler svg{fill:currentColor}.tc-wrap:hover .tc-toolbox__toggler{opacity:1}.tc-settings .cdx-settings-button{width:50%;margin:0}.tc-popover{--color-border: #eaeaea;--color-background: #fff;--color-background-hover: rgba(232, 232, 235, .49);--color-background-confirm: #e24a4a;--color-background-confirm-hover: #d54040;--color-text-confirm: #fff;background:var(--color-background);border:1px solid var(--color-border);-webkit-box-shadow:0 3px 15px -3px rgba(13,20,33,.12941);box-shadow:0 3px 15px -3px #0d142121;border-radius:6px;padding:6px;display:none;will-change:opacity,transform}.tc-popover--opened{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-animation:menuShowing .1s cubic-bezier(.215,.61,.355,1) forwards;animation:menuShowing .1s cubic-bezier(.215,.61,.355,1) forwards}.tc-popover__item{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-align:center;-ms-flex-align:center;align-items:center;padding:2px 14px 2px 2px;border-radius:5px;cursor:pointer;white-space:nowrap;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none}.tc-popover__item:hover{background:var(--color-background-hover)}.tc-popover__item:not(:last-of-type){margin-bottom:2px}.tc-popover__item-icon{display:-webkit-inline-box;display:-ms-inline-flexbox;display:inline-flex;width:26px;height:26px;-webkit-box-align:center;-ms-flex-align:center;align-items:center;-webkit-box-pack:center;-ms-flex-pack:center;justify-content:center;background:var(--color-background);border-radius:5px;border:1px solid var(--color-border);margin-right:8px}.tc-popover__item-label{line-height:22px;font-size:14px;font-weight:500}.tc-popover__item--confirm{background:var(--color-background-confirm);color:var(--color-text-confirm)}.tc-popover__item--confirm:hover{background-color:var(--color-background-confirm-hover)}.tc-popover__item--confirm .tc-popover__item-icon{background:var(--color-background-confirm);border-color:#0000001a}.tc-popover__item--confirm .tc-popover__item-icon svg{-webkit-transition:-webkit-transform .2s ease-in;transition:-webkit-transform .2s ease-in;transition:transform .2s ease-in;transition:transform .2s ease-in,-webkit-transform .2s ease-in;-webkit-transform:rotate(90deg) scale(1.2);transform:rotate(90deg) scale(1.2)}.tc-popover__item--hidden{display:none}@-webkit-keyframes menuShowing{0%{opacity:0;-webkit-transform:translateY(-8px) scale(.9);transform:translateY(-8px) scale(.9)}70%{opacity:1;-webkit-transform:translateY(2px);transform:translateY(2px)}to{-webkit-transform:translateY(0);transform:translateY(0)}}@keyframes menuShowing{0%{opacity:0;-webkit-transform:translateY(-8px) scale(.9);transform:translateY(-8px) scale(.9)}70%{opacity:1;-webkit-transform:translateY(2px);transform:translateY(2px)}to{-webkit-transform:translateY(0);transform:translateY(0)}}.cell-resizable{cursor:col-resize}.image-tool{--bg-color: #cdd1e0;--front-color: #388ae5;--border-color: #e8e8eb;display:inline-block}.image-tool__image{border-radius:3px;overflow:hidden;margin-bottom:10px;padding-bottom:0;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;pointer-events:none}.image-tool__image-picture{max-width:100%;vertical-align:bottom;display:inline-block;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;pointer-events:none}.image-tool__image-preloader{width:50px;height:50px;border-radius:50%;background-size:cover;margin:auto;position:relative;background-color:var(--bg-color);background-position:center center}.image-tool__image-preloader:after{content:"";position:absolute;z-index:3;width:60px;height:60px;border-radius:50%;border:2px solid var(--bg-color);border-top-color:var(--front-color);left:50%;top:50%;margin-top:-30px;margin-left:-30px;-webkit-animation:image-preloader-spin 2s infinite linear;animation:image-preloader-spin 2s infinite linear;-webkit-box-sizing:border-box;box-sizing:border-box}.image-tool__caption{visibility:hidden;position:absolute;bottom:0;left:0;margin-bottom:10px}.image-tool__caption[contentEditable=true][data-placeholder]:before{position:absolute!important}.image-tool__caption[contentEditable=true][data-placeholder]:before{content:attr(data-placeholder);color:#707684;font-weight:400;display:none}.image-tool__caption[contentEditable=true][data-placeholder]:empty:before{display:block}.image-tool__caption[contentEditable=true][data-placeholder]:empty:focus:before{display:none}.image-tool--empty .image-tool__image,.image-tool--empty .image-tool__image-preloader{display:none}.image-tool--empty .image-tool__caption,.image-tool--uploading .image-tool__caption{visibility:hidden!important}.image-tool .cdx-button{display:none;-webkit-box-align:center;-ms-flex-align:center;align-items:center;-webkit-box-pack:center;-ms-flex-pack:center;justify-content:center}.image-tool .cdx-button svg{height:auto;margin:0 6px 0 0}.image-tool--filled .cdx-button,.image-tool--filled .image-tool__image-preloader{display:none}.image-tool--uploading .image-tool__image{min-height:200px;display:-webkit-box;display:-ms-flexbox;display:flex;border:1px solid var(--border-color);background-color:#fff}.image-tool--uploading .image-tool__image-picture,.image-tool--uploading .cdx-button{display:none}.image-tool--withBorder .image-tool__image{border:1px solid var(--border-color)}.image-tool--withBackground .image-tool__image{padding:15px;background:var(--bg-color)}.image-tool--withBackground .image-tool__image-picture{max-width:60%;margin:0 auto}.image-tool--stretched .image-tool__image-picture{width:100%}.image-tool--caption .image-tool__caption{visibility:visible}.image-tool--caption{padding-bottom:50px}@-webkit-keyframes image-preloader-spin{0%{-webkit-transform:rotate(0);transform:rotate(0)}to{-webkit-transform:rotate(360deg);transform:rotate(360deg)}}@keyframes image-preloader-spin{0%{-webkit-transform:rotate(0);transform:rotate(0)}to{-webkit-transform:rotate(360deg);transform:rotate(360deg)}}.cdx-image-tool-tune--floatLeft .cdx-block,.cdx-image-tool-tune--center .cdx-block,.cdx-image-tool-tune--floatRight .cdx-block,.cdx-image-tool-tune--floatLeft .image-tool__image,.cdx-image-tool-tune--center .image-tool__image,.cdx-image-tool-tune--floatRight .image-tool__image{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-orient:vertical;-webkit-box-direction:normal;-ms-flex-direction:column;flex-direction:column;-webkit-box-align:center;-ms-flex-align:center;align-items:center}:root{--primary: #2492F5;--primary-content: #E9F4FE}.cdx-settings-button--active{background:#E9F4FE;color:#2492f5}.cdx-settings-button:hover{background:#E9F4FE}.cdx-image-tool-tune--center{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-pack:center;-ms-flex-pack:center;justify-content:center}@media all and (min-width: 470px){.codex-editor:not(.read-only) .cdx-image-tool-tune--floatLeft.ce-block__content,.codex-editor:not(.read-only) .cdx-image-tool-tune--floatRight.ce-block__content{min-height:20px}.cdx-image-tool-tune--floatLeft.ce-block__content .image-tool__image,.cdx-image-tool-tune--floatRight.ce-block__content .image-tool__image{margin-top:40px}.cdx-image-tool-tune--floatLeft.ce-block__content .image-tool__image{margin-left:20px}.cdx-image-tool-tune--floatRight.ce-block__content .image-tool__image{margin-right:20px}.cdx-image-tool-tune--floatLeft.ce-block__content .cdx-input,.cdx-image-tool-tune--floatRight.ce-block__content .cdx-input{width:calc(100% - 20px)}.cdx-image-tool-tune--floatLeft.ce-block__content .cdx-input{margin-left:20px}.cdx-image-tool-tune--floatRight.ce-block__content .cdx-input{margin-right:20px}.cdx-image-tool-tune--floatLeft .cdx-block{float:left;margin-right:10px}.cdx-image-tool-tune--floatRight .cdx-block{float:right;margin-left:10px}.cdx-image-tool-tune--sizeSmall .cdx-block{max-width:25%!important}.cdx-image-tool-tune--sizeMiddle .cdx-block{max-width:50%!important}.cdx-image-tool-tune--sizeLarge .cdx-block{max-width:75%!important}}.cdx-image-tool-tune--sizeLarge img,.cdx-image-tool-tune--sizeSmall img,.cdx-image-tool-tune--sizeMiddle img{-o-object-fit:cover;object-fit:cover;max-width:100%}.codex-editor.read-only .cdx-input.image-tool__caption:empty,.read-only>.codex-editor .cdx-input.image-tool__caption:empty{display:none}.cdx-image-tool-tune--resize .cdx-block{position:relative;overflow:visible}.cdx-image-tool-tune--resize .cdx-block .resizable{display:none}.cdx-image-tool-tune--resize .image-tool__image-picture{width:100%!important}.cdx-image-tool-tune--resize .cdx-block:hover .resizable{display:block}.cdx-image-tool-tune--resize .cdx-block .resizable .resizers .resizer{width:8px;height:8px;border-radius:50%;background:#E9F4FE;border:3px solid #2492F5;position:absolute}.cdx-image-tool-tune--resize .cdx-block .resizable .resizers .resizer.top-left{left:-8px;top:2px;cursor:nwse-resize}.cdx-image-tool-tune--resize .cdx-block .resizable .resizers .resizer.top-right{right:-8px;top:1px;cursor:nesw-resize}.cdx-image-tool-tune--resize .cdx-block .resizable .resizers .resizer.bottom-left{left:-9px;bottom:10px;cursor:nesw-resize}.cdx-image-tool-tune--resize .cdx-block .resizable .resizers .resizer.bottom-right{right:-9px;bottom:10px;cursor:nwse-resize}.cdx-image-tool-tune--crop:hover,.cdx-image-tool-tune--crop.isCropping,.cdx-image-tool-tune--resize:hover{z-index:2}.cdx-image-tool-tune--crop .image-tool__image{position:relative}.cdx-image-tool-tune--crop .isCropping .image-tool__image{min-height:600px;min-width:100%}.cdx-image-tool-tune--crop .image-tool__image .crop-btn,.cdx-image-tool-tune--crop .image-tool__image .crop-save{position:absolute;top:0;left:0;padding:7px;background:#2492F5;color:#e9f4fe;text-align:center;line-height:20px;cursor:pointer;display:none}.cdx-image-tool-tune--crop .image-tool__image:hover .crop-btn,.cdx-image-tool-tune--crop .image-tool__image:hover .crop-save{display:block}.cdx-image-tool-tune--crop .image-tool__image img.isCropped{position:absolute;min-width:0;min-width:initial;max-width:none;max-width:initial;min-height:0;min-height:initial;max-height:none;max-height:initial}.cdx-image-tool-tune--crop .cdx-block.image-tool.isCropping{min-width:0!important;min-width:initial!important;max-width:none!important;max-width:initial!important;min-height:0!important;min-height:initial!important;max-height:none!important;max-height:initial!important}.image-tool__caption{background-color:#fff}.image-tool{position:relative;z-index:1}.cdx-image-tool-tune{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-pack:start;-ms-flex-pack:start;justify-content:flex-start;gap:4px;width:100%}')),document.head.appendChild(e)}}catch(o){console.error("vite-plugin-css-injected-by-js",o)}})();
2
+ import { defineComponent as Nt, inject as zt, onMounted as Ft, toRaw as Pt, onUnmounted as Wt, openBlock as $t, createElementBlock as jt } from "vue";
3
3
  import Ut from "@ebl-vue/editorjs";
4
- import { bundledLanguagesInfo as jt, codeToHtml as Vt } from "shiki";
5
- import { make as S, isEmpty as rt } from "@editorjs/dom";
4
+ import { bundledLanguagesInfo as qt, codeToHtml as Vt } from "shiki";
5
+ import { make as y, isEmpty as nt } from "@editorjs/dom";
6
6
  import { focus as Kt, isCaretAtStartOfInput as Yt, getCaretNodeAndOffset as Gt, getContenteditableSlice as Jt } from "@editorjs/caret";
7
- import lt from "vanilla-caret-js";
7
+ import at from "vanilla-caret-js";
8
8
  import U from "axios";
9
- const dt = Symbol("INSTALLED_KEY"), Xt = (h, t) => (h.install = (e) => {
10
- for (const i of [h, ...Object.values({})]) e.component(i.name, i);
11
- }, h);
9
+ const lt = Symbol("INSTALLED_KEY"), Xt = (h, t) => {
10
+ if (h.install = (e) => {
11
+ for (const i of [h, ...Object.values(t != null ? t : {})])
12
+ e.component(i.name, i);
13
+ }, t)
14
+ for (const [e, i] of Object.entries(t))
15
+ h[e] = i;
16
+ return h;
17
+ };
12
18
  class Qt {
13
19
  constructor(t, e, i, s) {
14
20
  const { blocks: n, toolbar: r } = i;
15
21
  this.toolbar = r, this.borderStyle = s || "1px dashed #aaa", this.api = n, this.holder = document.getElementById(t), this.readOnly = e, this.startBlock = null, this.endBlock = null, this.setDragListener(), this.setDropListener();
16
22
  }
17
23
  setElementCursor(t) {
18
- if (!t) return;
24
+ if (!t)
25
+ return;
19
26
  const e = document.createRange(), i = window.getSelection();
20
27
  e.setStart(t.childNodes[0], 0), e.collapse(!0), i == null || i.removeAllRanges(), i == null || i.addRange(e), t.focus();
21
28
  }
@@ -43,7 +50,8 @@ class Qt {
43
50
  setBorderBlocks(t, e) {
44
51
  Object.values(t).forEach((i) => {
45
52
  const s = i.querySelector(".ce-block__content");
46
- if (i !== e) s == null || s.style.removeProperty("border-top"), s == null || s.style.removeProperty("border-bottom");
53
+ if (i !== e)
54
+ s == null || s.style.removeProperty("border-top"), s == null || s.style.removeProperty("border-bottom");
47
55
  else {
48
56
  const n = Object.keys(t).find((r) => t[Number(r)] === e);
49
57
  n && Number(n) > this.startBlock ? s.style.borderBottom = this.borderStyle : s.style.borderTop = this.borderStyle;
@@ -79,7 +87,7 @@ class Qt {
79
87
  this.isTheOnlyBlock() || this.api.move(this.endBlock, this.startBlock);
80
88
  }
81
89
  }
82
- const ht = '<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" fill="none" viewBox="0 0 24 24"><path stroke="currentColor" stroke-linecap="round" stroke-width="2" d="M6 7L6 12M6 17L6 12M6 12L12 12M12 7V12M12 17L12 12"/><path stroke="currentColor" stroke-linecap="round" stroke-width="2" d="M19 17V10.2135C19 10.1287 18.9011 10.0824 18.836 10.1367L16 12.5"/></svg>', ct = '<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" fill="none" viewBox="0 0 24 24"><path stroke="currentColor" stroke-linecap="round" stroke-width="2" d="M6 7L6 12M6 17L6 12M6 12L12 12M12 7V12M12 17L12 12"/><path stroke="currentColor" stroke-linecap="round" stroke-width="2" d="M16 11C16 10 19 9.5 19 12C19 13.9771 16.0684 13.9997 16.0012 16.8981C15.9999 16.9533 16.0448 17 16.1 17L19.3 17"/></svg>', pt = '<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" fill="none" viewBox="0 0 24 24"><path stroke="currentColor" stroke-linecap="round" stroke-width="2" d="M6 7L6 12M6 17L6 12M6 12L12 12M12 7V12M12 17L12 12"/><path stroke="currentColor" stroke-linecap="round" stroke-width="2" d="M16 11C16 10.5 16.8323 10 17.6 10C18.3677 10 19.5 10.311 19.5 11.5C19.5 12.5315 18.7474 12.9022 18.548 12.9823C18.5378 12.9864 18.5395 13.0047 18.5503 13.0063C18.8115 13.0456 20 13.3065 20 14.8C20 16 19.5 17 17.8 17C17.8 17 16 17 16 16.3"/></svg>', ut = '<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" fill="none" viewBox="0 0 24 24"><path stroke="currentColor" stroke-linecap="round" stroke-width="2" d="M6 7L6 12M6 17L6 12M6 12L12 12M12 7V12M12 17L12 12"/><path stroke="currentColor" stroke-linecap="round" stroke-width="2" d="M18 10L15.2834 14.8511C15.246 14.9178 15.294 15 15.3704 15C16.8489 15 18.7561 15 20.2 15M19 17C19 15.7187 19 14.8813 19 13.6"/></svg>', gt = '<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" fill="none" viewBox="0 0 24 24"><path stroke="currentColor" stroke-linecap="round" stroke-width="2" d="M6 7L6 12M6 17L6 12M6 12L12 12M12 7V12M12 17L12 12"/><path stroke="currentColor" stroke-linecap="round" stroke-width="2" d="M16 15.9C16 15.9 16.3768 17 17.8 17C19.5 17 20 15.6199 20 14.7C20 12.7323 17.6745 12.0486 16.1635 12.9894C16.094 13.0327 16 12.9846 16 12.9027V10.1C16 10.0448 16.0448 10 16.1 10H19.8"/></svg>', mt = '<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" fill="none" viewBox="0 0 24 24"><path stroke="currentColor" stroke-linecap="round" stroke-width="2" d="M6 7L6 12M6 17L6 12M6 12L12 12M12 7V12M12 17L12 12"/><path stroke="currentColor" stroke-linecap="round" stroke-width="2" d="M19.5 10C16.5 10.5 16 13.3285 16 15M16 15V15C16 16.1046 16.8954 17 18 17H18.3246C19.3251 17 20.3191 16.3492 20.2522 15.3509C20.0612 12.4958 16 12.6611 16 15Z"/></svg>', It = '<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" fill="none" viewBox="0 0 24 24"><path stroke="currentColor" stroke-linecap="round" stroke-width="2" d="M18 7L6 7"/><path stroke="currentColor" stroke-linecap="round" stroke-width="2" d="M18 17H6"/><path stroke="currentColor" stroke-linecap="round" stroke-width="2" d="M16 12L8 12"/></svg>', Ht = '<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" fill="none" viewBox="0 0 24 24"><path stroke="currentColor" stroke-linecap="round" stroke-width="2" d="M17 7L5 7"/><path stroke="currentColor" stroke-linecap="round" stroke-width="2" d="M17 17H5"/><path stroke="currentColor" stroke-linecap="round" stroke-width="2" d="M13 12L5 12"/></svg>', Bt = '<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" fill="none" viewBox="0 0 24 24"><path stroke="currentColor" stroke-linecap="round" stroke-width="2" d="M19 7L7 7"/><path stroke="currentColor" stroke-linecap="round" stroke-width="2" d="M19 17H7"/><path stroke="currentColor" stroke-linecap="round" stroke-width="2" d="M19 12L11 12"/></svg>', ft = '<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" fill="none" viewBox="0 0 24 24"><path stroke="currentColor" stroke-linecap="round" stroke-width="2" d="M8 8L12 12M12 12L16 16M12 12L16 8M12 12L8 16"/></svg>', Ct = '<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" fill="none" viewBox="0 0 24 24"><path stroke="currentColor" stroke-width="2" d="M11.3535 9.31802L12.7678 7.90381C13.5488 7.12276 14.8151 7.12276 15.5962 7.90381C16.3772 8.68486 16.3772 9.95119 15.5962 10.7322L14.182 12.1464M11.3535 9.31802L7.96729 12.7043C7.40889 13.2627 7.02826 13.9739 6.87339 14.7482L6.69798 15.6253C6.55803 16.325 7.17495 16.942 7.87467 16.802L8.75175 16.6266C9.52612 16.4717 10.2373 16.0911 10.7957 15.5327L14.182 12.1464M11.3535 9.31802L14.182 12.1464"/><line x1="15" x2="19" y1="17" y2="17" stroke="currentColor" stroke-linecap="round" stroke-width="2"/></svg>', At = '<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" fill="none" viewBox="0 0 24 24"><rect width="14" height="14" x="5" y="5" stroke="currentColor" stroke-width="2" rx="4"/><path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M5.13968 15.32L8.69058 11.5661C9.02934 11.2036 9.48873 11 9.96774 11C10.4467 11 10.9061 11.2036 11.2449 11.5661L15.3871 16M13.5806 14.0664L15.0132 12.533C15.3519 12.1705 15.8113 11.9668 16.2903 11.9668C16.7693 11.9668 17.2287 12.1705 17.5675 12.533L18.841 13.9634"/><path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M13.7778 9.33331H13.7867"/></svg>', Ot = '<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" fill="none" viewBox="0 0 24 24"><path stroke="currentColor" stroke-linecap="round" stroke-width="2" d="M8 9V7.2C8 7.08954 8.08954 7 8.2 7L12 7M16 9V7.2C16 7.08954 15.9105 7 15.8 7L12 7M12 7L12 17M12 17H10M12 17H14"/></svg>', vt = '<svg t="1763708081701" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="2604" width="24" height="24"><path d="M469.3330000000001 725.333H896V640H469.3330000000001v85.333zM128 512l170.667 170.667V341.3330000000001L128 512z m0 384h768v-85.333H128V896z m0-768v85.333h768V128H128z m341.333 256H896v-85.333H469.3330000000001V384z m0 170.667H896v-85.334H469.3330000000001v85.334z" p-id="2605" fill="#000000"></path></svg>', kt = '<svg t="1763708124227" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="2788" width="24" height="24"><path d="M128 896h768v-85.333H128V896z m0-554.667v341.334L298.667 512 128 341.333z m341.333 384H896V640H469.333v85.333zM128 128v85.333h768V128H128z m341.333 256H896v-85.333H469.333V384z m0 170.667H896v-85.334H469.333v85.334z" p-id="2789" fill="#000000"></path></svg>';
90
+ const dt = '<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" fill="none" viewBox="0 0 24 24"><path stroke="currentColor" stroke-linecap="round" stroke-width="2" d="M6 7L6 12M6 17L6 12M6 12L12 12M12 7V12M12 17L12 12"/><path stroke="currentColor" stroke-linecap="round" stroke-width="2" d="M19 17V10.2135C19 10.1287 18.9011 10.0824 18.836 10.1367L16 12.5"/></svg>', ht = '<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" fill="none" viewBox="0 0 24 24"><path stroke="currentColor" stroke-linecap="round" stroke-width="2" d="M6 7L6 12M6 17L6 12M6 12L12 12M12 7V12M12 17L12 12"/><path stroke="currentColor" stroke-linecap="round" stroke-width="2" d="M16 11C16 10 19 9.5 19 12C19 13.9771 16.0684 13.9997 16.0012 16.8981C15.9999 16.9533 16.0448 17 16.1 17L19.3 17"/></svg>', ct = '<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" fill="none" viewBox="0 0 24 24"><path stroke="currentColor" stroke-linecap="round" stroke-width="2" d="M6 7L6 12M6 17L6 12M6 12L12 12M12 7V12M12 17L12 12"/><path stroke="currentColor" stroke-linecap="round" stroke-width="2" d="M16 11C16 10.5 16.8323 10 17.6 10C18.3677 10 19.5 10.311 19.5 11.5C19.5 12.5315 18.7474 12.9022 18.548 12.9823C18.5378 12.9864 18.5395 13.0047 18.5503 13.0063C18.8115 13.0456 20 13.3065 20 14.8C20 16 19.5 17 17.8 17C17.8 17 16 17 16 16.3"/></svg>', pt = '<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" fill="none" viewBox="0 0 24 24"><path stroke="currentColor" stroke-linecap="round" stroke-width="2" d="M6 7L6 12M6 17L6 12M6 12L12 12M12 7V12M12 17L12 12"/><path stroke="currentColor" stroke-linecap="round" stroke-width="2" d="M18 10L15.2834 14.8511C15.246 14.9178 15.294 15 15.3704 15C16.8489 15 18.7561 15 20.2 15M19 17C19 15.7187 19 14.8813 19 13.6"/></svg>', ut = '<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" fill="none" viewBox="0 0 24 24"><path stroke="currentColor" stroke-linecap="round" stroke-width="2" d="M6 7L6 12M6 17L6 12M6 12L12 12M12 7V12M12 17L12 12"/><path stroke="currentColor" stroke-linecap="round" stroke-width="2" d="M16 15.9C16 15.9 16.3768 17 17.8 17C19.5 17 20 15.6199 20 14.7C20 12.7323 17.6745 12.0486 16.1635 12.9894C16.094 13.0327 16 12.9846 16 12.9027V10.1C16 10.0448 16.0448 10 16.1 10H19.8"/></svg>', gt = '<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" fill="none" viewBox="0 0 24 24"><path stroke="currentColor" stroke-linecap="round" stroke-width="2" d="M6 7L6 12M6 17L6 12M6 12L12 12M12 7V12M12 17L12 12"/><path stroke="currentColor" stroke-linecap="round" stroke-width="2" d="M19.5 10C16.5 10.5 16 13.3285 16 15M16 15V15C16 16.1046 16.8954 17 18 17H18.3246C19.3251 17 20.3191 16.3492 20.2522 15.3509C20.0612 12.4958 16 12.6611 16 15Z"/></svg>', _t = '<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" fill="none" viewBox="0 0 24 24"><path stroke="currentColor" stroke-linecap="round" stroke-width="2" d="M18 7L6 7"/><path stroke="currentColor" stroke-linecap="round" stroke-width="2" d="M18 17H6"/><path stroke="currentColor" stroke-linecap="round" stroke-width="2" d="M16 12L8 12"/></svg>', It = '<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" fill="none" viewBox="0 0 24 24"><path stroke="currentColor" stroke-linecap="round" stroke-width="2" d="M17 7L5 7"/><path stroke="currentColor" stroke-linecap="round" stroke-width="2" d="M17 17H5"/><path stroke="currentColor" stroke-linecap="round" stroke-width="2" d="M13 12L5 12"/></svg>', Ht = '<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" fill="none" viewBox="0 0 24 24"><path stroke="currentColor" stroke-linecap="round" stroke-width="2" d="M19 7L7 7"/><path stroke="currentColor" stroke-linecap="round" stroke-width="2" d="M19 17H7"/><path stroke="currentColor" stroke-linecap="round" stroke-width="2" d="M19 12L11 12"/></svg>', mt = '<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" fill="none" viewBox="0 0 24 24"><path stroke="currentColor" stroke-linecap="round" stroke-width="2" d="M8 8L12 12M12 12L16 16M12 12L16 8M12 12L8 16"/></svg>', ft = '<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" fill="none" viewBox="0 0 24 24"><path stroke="currentColor" stroke-width="2" d="M11.3535 9.31802L12.7678 7.90381C13.5488 7.12276 14.8151 7.12276 15.5962 7.90381C16.3772 8.68486 16.3772 9.95119 15.5962 10.7322L14.182 12.1464M11.3535 9.31802L7.96729 12.7043C7.40889 13.2627 7.02826 13.9739 6.87339 14.7482L6.69798 15.6253C6.55803 16.325 7.17495 16.942 7.87467 16.802L8.75175 16.6266C9.52612 16.4717 10.2373 16.0911 10.7957 15.5327L14.182 12.1464M11.3535 9.31802L14.182 12.1464"/><line x1="15" x2="19" y1="17" y2="17" stroke="currentColor" stroke-linecap="round" stroke-width="2"/></svg>', Bt = '<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" fill="none" viewBox="0 0 24 24"><rect width="14" height="14" x="5" y="5" stroke="currentColor" stroke-width="2" rx="4"/><path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M5.13968 15.32L8.69058 11.5661C9.02934 11.2036 9.48873 11 9.96774 11C10.4467 11 10.9061 11.2036 11.2449 11.5661L15.3871 16M13.5806 14.0664L15.0132 12.533C15.3519 12.1705 15.8113 11.9668 16.2903 11.9668C16.7693 11.9668 17.2287 12.1705 17.5675 12.533L18.841 13.9634"/><path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M13.7778 9.33331H13.7867"/></svg>', At = '<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" fill="none" viewBox="0 0 24 24"><path stroke="currentColor" stroke-linecap="round" stroke-width="2" d="M8 9V7.2C8 7.08954 8.08954 7 8.2 7L12 7M16 9V7.2C16 7.08954 15.9105 7 15.8 7L12 7M12 7L12 17M12 17H10M12 17H14"/></svg>', Ct = '<svg t="1763708081701" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="2604" width="24" height="24"><path d="M469.3330000000001 725.333H896V640H469.3330000000001v85.333zM128 512l170.667 170.667V341.3330000000001L128 512z m0 384h768v-85.333H128V896z m0-768v85.333h768V128H128z m341.333 256H896v-85.333H469.3330000000001V384z m0 170.667H896v-85.334H469.3330000000001v85.334z" p-id="2605" fill="#000000"></path></svg>', vt = '<svg t="1763708124227" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="2788" width="24" height="24"><path d="M128 896h768v-85.333H128V896z m0-554.667v341.334L298.667 512 128 341.333z m341.333 384H896V640H469.333v85.333zM128 128v85.333h768V128H128z m341.333 256H896v-85.333H469.333V384z m0 170.667H896v-85.334H469.333v85.334z" p-id="2789" fill="#000000"></path></svg>';
83
91
  class Zt {
84
92
  constructor({ data: t, config: e, api: i, readOnly: s }) {
85
93
  this.api = i, this.readOnly = s, this._settings = { placeholder: "H1" }, this._data = this.normalizeData(t), this._element = this.getTag();
@@ -148,7 +156,7 @@ class Zt {
148
156
  t.dataset.placeholder = this.api.i18n.t(this._settings.placeholder || "");
149
157
  }
150
158
  get defaultLevel() {
151
- return { number: 1, tag: "H1", svg: ht };
159
+ return { number: 1, tag: "H1", svg: dt };
152
160
  }
153
161
  onPaste(t) {
154
162
  const e = t.detail;
@@ -161,7 +169,7 @@ class Zt {
161
169
  return { tags: ["H1"] };
162
170
  }
163
171
  static get toolbox() {
164
- return { icon: ht, title: "H1" };
172
+ return { icon: dt, title: "H1" };
165
173
  }
166
174
  }
167
175
  class te {
@@ -232,7 +240,7 @@ class te {
232
240
  t.dataset.placeholder = this.api.i18n.t(this._settings.placeholder || "");
233
241
  }
234
242
  get defaultLevel() {
235
- return { number: 2, tag: "H2", svg: ct };
243
+ return { number: 2, tag: "H2", svg: ht };
236
244
  }
237
245
  onPaste(t) {
238
246
  const e = t.detail;
@@ -245,7 +253,7 @@ class te {
245
253
  return { tags: ["H2"] };
246
254
  }
247
255
  static get toolbox() {
248
- return { icon: ct, title: "H2" };
256
+ return { icon: ht, title: "H2" };
249
257
  }
250
258
  }
251
259
  class ee {
@@ -316,7 +324,7 @@ class ee {
316
324
  t.dataset.placeholder = this.api.i18n.t(this._settings.placeholder || "");
317
325
  }
318
326
  get defaultLevel() {
319
- return { number: 3, tag: "H3", svg: pt };
327
+ return { number: 3, tag: "H3", svg: ct };
320
328
  }
321
329
  onPaste(t) {
322
330
  const e = t.detail;
@@ -329,7 +337,7 @@ class ee {
329
337
  return { tags: ["H3"] };
330
338
  }
331
339
  static get toolbox() {
332
- return { icon: pt, title: "H3" };
340
+ return { icon: ct, title: "H3" };
333
341
  }
334
342
  }
335
343
  class ie {
@@ -400,7 +408,7 @@ class ie {
400
408
  t.dataset.placeholder = this.api.i18n.t(this._settings.placeholder || "");
401
409
  }
402
410
  get defaultLevel() {
403
- return { number: 4, tag: "H4", svg: ut };
411
+ return { number: 4, tag: "H4", svg: pt };
404
412
  }
405
413
  onPaste(t) {
406
414
  const e = t.detail;
@@ -413,7 +421,7 @@ class ie {
413
421
  return { tags: ["H4"] };
414
422
  }
415
423
  static get toolbox() {
416
- return { icon: ut, title: "H4" };
424
+ return { icon: pt, title: "H4" };
417
425
  }
418
426
  }
419
427
  class se {
@@ -484,7 +492,7 @@ class se {
484
492
  t.dataset.placeholder = this.api.i18n.t(this._settings.placeholder || "");
485
493
  }
486
494
  get defaultLevel() {
487
- return { number: 5, tag: "H5", svg: gt };
495
+ return { number: 5, tag: "H5", svg: ut };
488
496
  }
489
497
  onPaste(t) {
490
498
  const e = t.detail;
@@ -497,7 +505,7 @@ class se {
497
505
  return { tags: ["H5"] };
498
506
  }
499
507
  static get toolbox() {
500
- return { icon: gt, title: "H5" };
508
+ return { icon: ut, title: "H5" };
501
509
  }
502
510
  }
503
511
  class ne {
@@ -568,7 +576,7 @@ class ne {
568
576
  t.dataset.placeholder = this.api.i18n.t(this._settings.placeholder || "");
569
577
  }
570
578
  get defaultLevel() {
571
- return { number: 6, tag: "H6", svg: mt };
579
+ return { number: 6, tag: "H6", svg: gt };
572
580
  }
573
581
  onPaste(t) {
574
582
  const e = t.detail;
@@ -581,10 +589,10 @@ class ne {
581
589
  return { tags: ["H6"] };
582
590
  }
583
591
  static get toolbox() {
584
- return { icon: mt, title: "H6" };
592
+ return { icon: gt, title: "H6" };
585
593
  }
586
594
  }
587
- class ot {
595
+ class rt {
588
596
  static get DEFAULT_ALIGNMENT() {
589
597
  return "left";
590
598
  }
@@ -593,10 +601,10 @@ class ot {
593
601
  }
594
602
  getAlignment() {
595
603
  var t, e;
596
- return (t = this.settings) != null && t.blocks && this.settings.blocks.hasOwnProperty(this.block.name) ? this.settings.blocks[this.block.name] : (e = this.settings) != null && e.default ? this.settings.default : ot.DEFAULT_ALIGNMENT;
604
+ return (t = this.settings) != null && t.blocks && this.settings.blocks.hasOwnProperty(this.block.name) ? this.settings.blocks[this.block.name] : (e = this.settings) != null && e.default ? this.settings.default : rt.DEFAULT_ALIGNMENT;
597
605
  }
598
606
  constructor({ api: t, data: e, config: i, block: s }) {
599
- this.api = t, this.block = s, this.settings = i, this.data = e || { alignment: this.getAlignment() }, this.alignmentSettings = [{ name: "left", icon: Ht }, { name: "center", icon: It }, { name: "right", icon: Bt }], this._CSS = { alignment: { left: "ce-tune-alignment--left", center: "ce-tune-alignment--center", right: "ce-tune-alignment--right" } };
607
+ this.api = t, this.block = s, this.settings = i, this.data = e || { alignment: this.getAlignment() }, this.alignmentSettings = [{ name: "left", icon: It }, { name: "center", icon: _t }, { name: "right", icon: Ht }], this._CSS = { alignment: { left: "ce-tune-alignment--left", center: "ce-tune-alignment--center", right: "ce-tune-alignment--right" } };
600
608
  }
601
609
  wrap(t) {
602
610
  return this.wrapper = document.createElement("div"), this.wrapper.classList.toggle(this._CSS.alignment[this.data.alignment]), this.wrapper.append(t), this.wrapper;
@@ -621,16 +629,17 @@ class ot {
621
629
  return this.data;
622
630
  }
623
631
  }
624
- class at {
632
+ class ot {
625
633
  static get DEFAULT_PLACEHOLDER() {
626
634
  return "";
627
635
  }
628
636
  constructor({ data: t, config: e, api: i, readOnly: s }) {
629
637
  var n;
630
- this.api = i, this.readOnly = s, this._CSS = { block: this.api.styles.block, wrapper: "ce-paragraph" }, this.readOnly || (this.onKeyUp = this.onKeyUp.bind(this)), this._placeholder = e.placeholder ? e.placeholder : at.DEFAULT_PLACEHOLDER, this._data = t != null ? t : {}, this._element = null, this._preserveBlank = (n = e.preserveBlank) != null ? n : !1;
638
+ this.api = i, this.readOnly = s, this._CSS = { block: this.api.styles.block, wrapper: "ce-paragraph" }, this.readOnly || (this.onKeyUp = this.onKeyUp.bind(this)), this._placeholder = e.placeholder ? e.placeholder : ot.DEFAULT_PLACEHOLDER, this._data = t != null ? t : {}, this._element = null, this._preserveBlank = (n = e.preserveBlank) != null ? n : !1;
631
639
  }
632
640
  onKeyUp(t) {
633
- if (t.code !== "Backspace" && t.code !== "Delete" || !this._element) return;
641
+ if (t.code !== "Backspace" && t.code !== "Delete" || !this._element)
642
+ return;
634
643
  const { textContent: e } = this._element;
635
644
  e === "" && (this._element.innerHTML = "");
636
645
  }
@@ -642,7 +651,8 @@ class at {
642
651
  return this._element = this.drawView(), this._element;
643
652
  }
644
653
  merge(t) {
645
- if (!this._element) return;
654
+ if (!this._element)
655
+ return;
646
656
  this._data.text += t.text;
647
657
  const e = function(i) {
648
658
  const s = document.createElement("div");
@@ -677,13 +687,13 @@ class at {
677
687
  return { tags: ["P"] };
678
688
  }
679
689
  static get toolbox() {
680
- return { icon: Ot, title: "Text" };
690
+ return { icon: At, title: "Text" };
681
691
  }
682
692
  }
683
- class q {
693
+ class j {
684
694
  constructor({ data: t, config: e, api: i, readOnly: s }) {
685
695
  var n;
686
- this._selectorLanguage = "", this._selectorTheme = "", this.api = i, this.readOnly = s, this.placeholder = this.api.i18n.t(e.placeholder || q.DEFAULT_PLACEHOLDER), this._selectorLanguage = t.lang || e.lang || q.DEFAULT_LANGUAGE, this._selectorTheme = t.theme || e.theme || q.DEFAULT_THEME, this.CSS = { baseClass: this.api.styles.block, input: this.api.styles.input, wrapper: "ce-editorjs-x-shiki", textarea: "ce-editorjs-x-shiki__textarea", span: "ce-editorjs-x-shiki__span", selectorLanguage: "ce-editorjs-x-shiki__selector-language", selectorTheme: "ce-editorjs-x-shiki__selector-theme" }, this.nodes = { holder: null, textarea: null }, this.data = { code: (n = t.code) != null ? n : "", lang: this._selectorLanguage, theme: this._selectorTheme }, this.nodes.holder = this.drawView();
696
+ this._selectorLanguage = "", this._selectorTheme = "", this.api = i, this.readOnly = s, this.placeholder = this.api.i18n.t(e.placeholder || j.DEFAULT_PLACEHOLDER), this._selectorLanguage = t.lang || e.lang || j.DEFAULT_LANGUAGE, this._selectorTheme = t.theme || e.theme || j.DEFAULT_THEME, this.CSS = { baseClass: this.api.styles.block, input: this.api.styles.input, wrapper: "ce-editorjs-x-shiki", textarea: "ce-editorjs-x-shiki__textarea", span: "ce-editorjs-x-shiki__span", selectorLanguage: "ce-editorjs-x-shiki__selector-language", selectorTheme: "ce-editorjs-x-shiki__selector-theme" }, this.nodes = { holder: null, textarea: null }, this.data = { code: (n = t.code) != null ? n : "", lang: this._selectorLanguage, theme: this._selectorTheme }, this.nodes.holder = this.drawView();
687
697
  }
688
698
  static get isReadOnlySupported() {
689
699
  return !0;
@@ -736,18 +746,21 @@ class q {
736
746
  const a = function(d, l) {
737
747
  let c = "";
738
748
  for (; c !== `
739
- ` && l > 0; ) l -= 1, c = d.substr(l, 1);
749
+ ` && l > 0; )
750
+ l -= 1, c = d.substr(l, 1);
740
751
  return c === `
741
752
  ` && (l += 1), l;
742
753
  }(n, s);
743
- if (n.substr(a, 2) !== r) return;
754
+ if (n.substr(a, 2) !== r)
755
+ return;
744
756
  e.value = n.substring(0, a) + n.substring(a + 2), o = s - 2;
745
- } else o = s + 2, e.value = n.substring(0, s) + r + n.substring(s);
757
+ } else
758
+ o = s + 2, e.value = n.substring(0, s) + r + n.substring(s);
746
759
  e.setSelectionRange(o, o);
747
760
  }
748
761
  drawView() {
749
762
  const t = document.createElement("div"), e = document.createElement("div"), i = document.createElement("div"), s = document.createElement("div"), n = document.createElement("div"), r = document.createElement("div"), o = document.createElement("select"), a = document.createElement("select"), d = document.createElement("span"), l = document.createElement("textarea");
750
- return t.classList.add(this.CSS.baseClass, this.CSS.wrapper), e.classList.add("ce-editorjs-x-shiki__code"), i.classList.add("ce-editorjs-x-shiki__selector"), s.classList.add("ce-editorjs-x-shiki__lang"), n.classList.add("ce-editorjs-x-shiki__copy"), r.classList.add("ce-editorjs-x-shiki__copy_tip"), o.classList.add(this.CSS.selectorLanguage), l.classList.add(this.CSS.textarea, this.CSS.input), s.innerHTML = this.data.lang, n.innerHTML = '<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" fill="none" viewBox="0 0 24 24"><path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M17.25 8.5H10.25C9.2835 8.5 8.5 9.2835 8.5 10.25V17.25C8.5 18.2165 9.2835 19 10.25 19H17.25C18.2165 19 19 18.2165 19 17.25V10.25C19 9.2835 18.2165 8.5 17.25 8.5Z"/><path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M15.5 8.5V6.75C15.5 6.28587 15.3156 5.84075 14.9874 5.51256C14.6592 5.18437 14.2141 5 13.75 5H6.75C6.28587 5 5.84075 5.18437 5.51256 5.51256C5.18437 5.84075 5 6.28587 5 6.75V13.75C5 14.2141 5.18437 14.6592 5.51256 14.9874C5.84075 15.3156 6.28587 15.5 6.75 15.5H8.5"/><path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M12 12L15.5 12"/><path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M12 15.5L15.5 15.5"/></svg>', r.innerText = this.api.i18n.t("Copied"), jt.forEach((c) => {
763
+ return t.classList.add(this.CSS.baseClass, this.CSS.wrapper), e.classList.add("ce-editorjs-x-shiki__code"), i.classList.add("ce-editorjs-x-shiki__selector"), s.classList.add("ce-editorjs-x-shiki__lang"), n.classList.add("ce-editorjs-x-shiki__copy"), r.classList.add("ce-editorjs-x-shiki__copy_tip"), o.classList.add(this.CSS.selectorLanguage), l.classList.add(this.CSS.textarea, this.CSS.input), s.innerHTML = this.data.lang, n.innerHTML = '<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" fill="none" viewBox="0 0 24 24"><path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M17.25 8.5H10.25C9.2835 8.5 8.5 9.2835 8.5 10.25V17.25C8.5 18.2165 9.2835 19 10.25 19H17.25C18.2165 19 19 18.2165 19 17.25V10.25C19 9.2835 18.2165 8.5 17.25 8.5Z"/><path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M15.5 8.5V6.75C15.5 6.28587 15.3156 5.84075 14.9874 5.51256C14.6592 5.18437 14.2141 5 13.75 5H6.75C6.28587 5 5.84075 5.18437 5.51256 5.51256C5.18437 5.84075 5 6.28587 5 6.75V13.75C5 14.2141 5.18437 14.6592 5.51256 14.9874C5.84075 15.3156 6.28587 15.5 6.75 15.5H8.5"/><path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M12 12L15.5 12"/><path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M12 15.5L15.5 15.5"/></svg>', r.innerText = this.api.i18n.t("Copied"), qt.forEach((c) => {
751
764
  const p = document.createElement("option");
752
765
  p.value = c.id, p.text = c.name, o.appendChild(p);
753
766
  }), o.value = this.data.lang, l.value = this.data.code, l.placeholder = this.placeholder, l.spellcheck = !1, l.autocomplete = "off", l.autocapitalize = "off", this.readOnly && (l.disabled = !0), e.appendChild(d), e.appendChild(l), this.readOnly ? i.appendChild(s) : i.appendChild(o), n.appendChild(r), i.appendChild(n), t.appendChild(i), t.appendChild(e), this.runShiki().then(({ html: c, preStyle: p }) => {
@@ -780,6 +793,8 @@ class q {
780
793
  `, pre(e) {
781
794
  var i;
782
795
  this.addClassToHast(e, "ce-editorjs-x-shiki__span"), t = ((i = e.properties) == null ? void 0 : i.style) || "";
796
+ }, line(e, i) {
797
+ e.properties = e.properties || {}, e.properties["data-line"] = i;
783
798
  } }] }), preStyle: t };
784
799
  }
785
800
  copyCode(t, e) {
@@ -823,8 +838,8 @@ class re {
823
838
  return { baseClass: this.api.styles.block, wrapper: "cdx-quote", text: "cdx-quote__text", input: this.api.styles.input };
824
839
  }
825
840
  render() {
826
- const t = S("div", [this._CSS.baseClass, this._CSS.wrapper]);
827
- return this._quoteElement = S("blockquote", [this._CSS.input, this._CSS.text, "cdx-block-quote"], { contentEditable: !this.readOnly, innerHTML: this._data.text }), this._quoteElement.addEventListener("keydown", (e) => this.handleKeydown(e)), t.appendChild(this._quoteElement), t;
841
+ const t = y("div", [this._CSS.baseClass, this._CSS.wrapper]);
842
+ return this._quoteElement = y("blockquote", [this._CSS.input, this._CSS.text, "cdx-block-quote"], { contentEditable: !this.readOnly, innerHTML: this._data.text }), this._quoteElement.addEventListener("keydown", (e) => this.handleKeydown(e)), t.appendChild(this._quoteElement), t;
828
843
  }
829
844
  get currentItem() {
830
845
  let t = window.getSelection().anchorNode;
@@ -881,25 +896,25 @@ class oe {
881
896
  this.data = {};
882
897
  }
883
898
  }
884
- const x = "cdx-list", k = { wrapper: x, item: `${x}__item`, itemContent: `${x}__item-content`, itemChildren: `${x}__item-children` };
899
+ const L = "cdx-list", k = { wrapper: L, item: `${L}__item`, itemContent: `${L}__item-content`, itemChildren: `${L}__item-children` };
885
900
  class E {
886
901
  static get CSS() {
887
- return { ...k, orderedList: `${x}-ordered` };
902
+ return { ...k, orderedList: `${L}-ordered` };
888
903
  }
889
904
  constructor(t, e) {
890
905
  this.config = e, this.readOnly = t;
891
906
  }
892
907
  renderWrapper(t) {
893
908
  let e;
894
- return e = S("ol", t === !0 ? [E.CSS.wrapper, E.CSS.orderedList] : [E.CSS.orderedList, E.CSS.itemChildren]), e;
909
+ return e = y("ol", t === !0 ? [E.CSS.wrapper, E.CSS.orderedList] : [E.CSS.orderedList, E.CSS.itemChildren]), e;
895
910
  }
896
911
  renderItem(t, e) {
897
- const i = S("li", E.CSS.item), s = S("div", E.CSS.itemContent, { innerHTML: t, contentEditable: (!this.readOnly).toString() });
912
+ const i = y("li", E.CSS.item), s = y("div", E.CSS.itemContent, { innerHTML: t, contentEditable: (!this.readOnly).toString() });
898
913
  return i.appendChild(s), i;
899
914
  }
900
915
  getItemContent(t) {
901
916
  const e = t.querySelector(`.${E.CSS.itemContent}`);
902
- return e ? rt(e) ? "" : e.innerHTML : "";
917
+ return e ? nt(e) ? "" : e.innerHTML : "";
903
918
  }
904
919
  getItemMeta() {
905
920
  return {};
@@ -910,22 +925,22 @@ class E {
910
925
  }
911
926
  class M {
912
927
  static get CSS() {
913
- return { ...k, unorderedList: `${x}-unordered` };
928
+ return { ...k, unorderedList: `${L}-unordered` };
914
929
  }
915
930
  constructor(t, e) {
916
931
  this.config = e, this.readOnly = t;
917
932
  }
918
933
  renderWrapper(t) {
919
934
  let e;
920
- return e = S("ul", t === !0 ? [M.CSS.wrapper, M.CSS.unorderedList] : [M.CSS.unorderedList, M.CSS.itemChildren]), e;
935
+ return e = y("ul", t === !0 ? [M.CSS.wrapper, M.CSS.unorderedList] : [M.CSS.unorderedList, M.CSS.itemChildren]), e;
921
936
  }
922
937
  renderItem(t, e) {
923
- const i = S("li", M.CSS.item), s = S("div", M.CSS.itemContent, { innerHTML: t, contentEditable: (!this.readOnly).toString() });
938
+ const i = y("li", M.CSS.item), s = y("div", M.CSS.itemContent, { innerHTML: t, contentEditable: (!this.readOnly).toString() });
924
939
  return i.appendChild(s), i;
925
940
  }
926
941
  getItemContent(t) {
927
942
  const e = t.querySelector(`.${M.CSS.itemContent}`);
928
- return e ? rt(e) ? "" : e.innerHTML : "";
943
+ return e ? nt(e) ? "" : e.innerHTML : "";
929
944
  }
930
945
  getItemMeta() {
931
946
  return {};
@@ -939,28 +954,28 @@ function R(h) {
939
954
  }
940
955
  class C {
941
956
  static get CSS() {
942
- return { ...k, checklist: `${x}-checklist`, itemChecked: `${x}__checkbox--checked`, noHover: `${x}__checkbox--no-hover`, checkbox: `${x}__checkbox-check`, checkboxContainer: `${x}__checkbox`, checkboxCheckDisabled: `${x}__checkbox-check--disabled` };
957
+ return { ...k, checklist: `${L}-checklist`, itemChecked: `${L}__checkbox--checked`, noHover: `${L}__checkbox--no-hover`, checkbox: `${L}__checkbox-check`, checkboxContainer: `${L}__checkbox`, checkboxCheckDisabled: `${L}__checkbox-check--disabled` };
943
958
  }
944
959
  constructor(t, e) {
945
960
  this.config = e, this.readOnly = t;
946
961
  }
947
962
  renderWrapper(t) {
948
963
  let e;
949
- return t === !0 ? (e = S("ul", [C.CSS.wrapper, C.CSS.checklist]), e.addEventListener("click", (i) => {
964
+ return t === !0 ? (e = y("ul", [C.CSS.wrapper, C.CSS.checklist]), e.addEventListener("click", (i) => {
950
965
  const s = i.target;
951
966
  if (s) {
952
967
  const n = s.closest(`.${C.CSS.checkboxContainer}`);
953
968
  n && n.contains(s) && this.toggleCheckbox(n);
954
969
  }
955
- })) : e = S("ul", [C.CSS.checklist, C.CSS.itemChildren]), e;
970
+ })) : e = y("ul", [C.CSS.checklist, C.CSS.itemChildren]), e;
956
971
  }
957
972
  renderItem(t, e) {
958
- const i = S("li", [C.CSS.item, C.CSS.item]), s = S("div", C.CSS.itemContent, { innerHTML: t, contentEditable: (!this.readOnly).toString() }), n = S("span", C.CSS.checkbox), r = S("div", C.CSS.checkboxContainer);
973
+ const i = y("li", [C.CSS.item, C.CSS.item]), s = y("div", C.CSS.itemContent, { innerHTML: t, contentEditable: (!this.readOnly).toString() }), n = y("span", C.CSS.checkbox), r = y("div", C.CSS.checkboxContainer);
959
974
  return e.checked === !0 && r.classList.add(C.CSS.itemChecked), this.readOnly && r.classList.add(C.CSS.checkboxCheckDisabled), n.innerHTML = '<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" fill="none" viewBox="0 0 24 24"><path stroke="currentColor" stroke-linecap="round" stroke-width="2" d="M7 12L10.4884 15.8372C10.5677 15.9245 10.705 15.9245 10.7844 15.8372L17 9"/></svg>', r.appendChild(n), i.appendChild(r), i.appendChild(s), i;
960
975
  }
961
976
  getItemContent(t) {
962
977
  const e = t.querySelector(`.${C.CSS.itemContent}`);
963
- return e ? rt(e) ? "" : e.innerHTML : "";
978
+ return e ? nt(e) ? "" : e.innerHTML : "";
964
979
  }
965
980
  getItemMeta(t) {
966
981
  const e = t.querySelector(`.${C.CSS.checkboxContainer}`);
@@ -976,7 +991,7 @@ class C {
976
991
  t.classList.remove(C.CSS.noHover);
977
992
  }
978
993
  }
979
- function G(h, t = "after") {
994
+ function J(h, t = "after") {
980
995
  const e = [];
981
996
  let i;
982
997
  function s(n) {
@@ -987,7 +1002,8 @@ function G(h, t = "after") {
987
1002
  return n.previousElementSibling;
988
1003
  }
989
1004
  }
990
- for (i = s(h); i !== null; ) e.push(i), i = s(i);
1005
+ for (i = s(h); i !== null; )
1006
+ e.push(i), i = s(i);
991
1007
  return e.length !== 0 ? e : null;
992
1008
  }
993
1009
  function I(h, t = !0) {
@@ -997,29 +1013,32 @@ function I(h, t = !0) {
997
1013
  function A(h) {
998
1014
  return h.querySelector(`.${k.itemChildren}`);
999
1015
  }
1000
- function J(h) {
1016
+ function X(h) {
1001
1017
  let t = h;
1002
1018
  h.classList.contains(k.item) && (t = A(h)), t !== null && I(t).length === 0 && t.remove();
1003
1019
  }
1004
- function j(h) {
1020
+ function q(h) {
1005
1021
  return h.querySelector(`.${k.itemContent}`);
1006
1022
  }
1007
- function F(h, t = !0) {
1008
- const e = j(h);
1023
+ function z(h, t = !0) {
1024
+ const e = q(h);
1009
1025
  e && Kt(e, t);
1010
1026
  }
1011
- class X {
1027
+ class Q {
1012
1028
  get currentItem() {
1013
1029
  const t = window.getSelection();
1014
- if (!t) return null;
1030
+ if (!t)
1031
+ return null;
1015
1032
  let e = t.anchorNode;
1016
1033
  return e ? (R(e) || (e = e.parentNode), e && R(e) ? e.closest(`.${k.item}`) : null) : null;
1017
1034
  }
1018
1035
  get currentItemLevel() {
1019
1036
  const t = this.currentItem;
1020
- if (t === null) return null;
1037
+ if (t === null)
1038
+ return null;
1021
1039
  let e = t.parentNode, i = 0;
1022
- for (; e !== null && e !== this.listWrapper; ) R(e) && e.classList.contains(k.item) && (i += 1), e = e.parentNode;
1040
+ for (; e !== null && e !== this.listWrapper; )
1041
+ R(e) && e.classList.contains(k.item) && (i += 1), e = e.parentNode;
1023
1042
  return i + 1;
1024
1043
  }
1025
1044
  constructor({ data: t, config: e, api: i, readOnly: s, block: n }, r) {
@@ -1051,10 +1070,12 @@ class X {
1051
1070
  return { tags: ["OL", "UL", "LI"] };
1052
1071
  }
1053
1072
  merge(t) {
1054
- const e = this.block.holder.querySelectorAll(`.${k.item}`), i = e[e.length - 1], s = j(i);
1055
- if (i === null || s === null || (s.insertAdjacentHTML("beforeend", t.items[0].content), this.listWrapper === void 0)) return;
1073
+ const e = this.block.holder.querySelectorAll(`.${k.item}`), i = e[e.length - 1], s = q(i);
1074
+ if (i === null || s === null || (s.insertAdjacentHTML("beforeend", t.items[0].content), this.listWrapper === void 0))
1075
+ return;
1056
1076
  const n = I(this.listWrapper);
1057
- if (n.length === 0) return;
1077
+ if (n.length === 0)
1078
+ return;
1058
1079
  let r = A(n[n.length - 1]);
1059
1080
  const o = t.items.shift();
1060
1081
  o !== void 0 && (o.items.length !== 0 && (r === null && (r = this.renderer.renderWrapper(!1)), this.appendItems(o.items, r)), t.items.length > 0 && this.appendItems(t.items, this.listWrapper));
@@ -1094,11 +1115,13 @@ class X {
1094
1115
  enterPressed(t) {
1095
1116
  var o;
1096
1117
  const e = this.currentItem;
1097
- if (t.stopPropagation(), t.preventDefault(), t.isComposing || e === null) return;
1118
+ if (t.stopPropagation(), t.preventDefault(), t.isComposing || e === null)
1119
+ return;
1098
1120
  const i = ((o = this.renderer) == null ? void 0 : o.getItemContent(e).trim().length) === 0, s = e.parentNode === this.listWrapper, n = e.previousElementSibling === null, r = this.api.blocks.getCurrentBlockIndex();
1099
- if (s && i) return e.nextElementSibling !== null || function(a) {
1100
- return a.querySelector(`.${k.itemChildren}`) !== null;
1101
- }(e) ? void this.splitList(e) : void (n ? this.convertItemToDefaultBlock(r, !0) : this.convertItemToDefaultBlock());
1121
+ if (s && i)
1122
+ return e.nextElementSibling !== null || function(a) {
1123
+ return a.querySelector(`.${k.itemChildren}`) !== null;
1124
+ }(e) ? void this.splitList(e) : void (n ? this.convertItemToDefaultBlock(r, !0) : this.convertItemToDefaultBlock());
1102
1125
  i ? this.unshiftItem(e) : this.splitItem(e);
1103
1126
  }
1104
1127
  backspace(t) {
@@ -1110,25 +1133,30 @@ class X {
1110
1133
  t.stopPropagation(), t.preventDefault(), this.currentItem !== null && this.unshiftItem(this.currentItem);
1111
1134
  }
1112
1135
  unshiftItem(t) {
1113
- if (!t.parentNode || !R(t.parentNode)) return;
1136
+ if (!t.parentNode || !R(t.parentNode))
1137
+ return;
1114
1138
  const e = t.parentNode.closest(`.${k.item}`);
1115
- if (!e) return;
1139
+ if (!e)
1140
+ return;
1116
1141
  let i = A(t);
1117
- if (t.parentElement === null) return;
1118
- const s = G(t);
1142
+ if (t.parentElement === null)
1143
+ return;
1144
+ const s = J(t);
1119
1145
  s !== null && (i === null && (i = this.renderer.renderWrapper(!1)), s.forEach((n) => {
1120
1146
  i.appendChild(n);
1121
- }), t.appendChild(i)), e.after(t), F(t, !1), J(e);
1147
+ }), t.appendChild(i)), e.after(t), z(t, !1), X(e);
1122
1148
  }
1123
1149
  splitList(t) {
1124
1150
  const e = I(t), i = this.block, s = this.api.blocks.getCurrentBlockIndex();
1125
1151
  if (e.length !== 0) {
1126
1152
  const a = e[0];
1127
- this.unshiftItem(a), F(t, !1);
1153
+ this.unshiftItem(a), z(t, !1);
1128
1154
  }
1129
- if (t.previousElementSibling === null && t.parentNode === this.listWrapper) return void this.convertItemToDefaultBlock(s);
1130
- const n = G(t);
1131
- if (n === null) return;
1155
+ if (t.previousElementSibling === null && t.parentNode === this.listWrapper)
1156
+ return void this.convertItemToDefaultBlock(s);
1157
+ const n = J(t);
1158
+ if (n === null)
1159
+ return;
1132
1160
  const r = this.renderer.renderWrapper(!0);
1133
1161
  n.forEach((a) => {
1134
1162
  r.appendChild(a);
@@ -1138,32 +1166,39 @@ class X {
1138
1166
  }
1139
1167
  splitItem(t) {
1140
1168
  const [e, i] = Gt();
1141
- if (e === null) return;
1142
- const s = j(t);
1169
+ if (e === null)
1170
+ return;
1171
+ const s = q(t);
1143
1172
  let n;
1144
1173
  n = s === null ? "" : Jt(s, e, i, "right", !0);
1145
1174
  const r = A(t), o = this.renderItem(n);
1146
- t == null || t.after(o), r && o.appendChild(r), F(o);
1175
+ t == null || t.after(o), r && o.appendChild(r), z(o);
1147
1176
  }
1148
1177
  mergeItemWithPrevious(t) {
1149
1178
  var c;
1150
1179
  const e = t.previousElementSibling, i = t.parentNode;
1151
- if (i === null || !R(i)) return;
1180
+ if (i === null || !R(i))
1181
+ return;
1152
1182
  const s = i.closest(`.${k.item}`);
1153
- if (!e && !s || e && !R(e)) return;
1183
+ if (!e && !s || e && !R(e))
1184
+ return;
1154
1185
  let n;
1155
1186
  if (e) {
1156
1187
  const p = I(e, !1);
1157
1188
  n = p.length !== 0 && p.length !== 0 ? p[p.length - 1] : e;
1158
- } else n = s;
1189
+ } else
1190
+ n = s;
1159
1191
  const r = this.renderer.getItemContent(t);
1160
- if (!n) return;
1161
- F(n, !1);
1162
- const o = j(n);
1163
- if (o === null) return;
1192
+ if (!n)
1193
+ return;
1194
+ z(n, !1);
1195
+ const o = q(n);
1196
+ if (o === null)
1197
+ return;
1164
1198
  o.insertAdjacentHTML("beforeend", r);
1165
1199
  const a = I(t);
1166
- if (a.length === 0) return t.remove(), void J(n);
1200
+ if (a.length === 0)
1201
+ return t.remove(), void X(n);
1167
1202
  const d = e || s, l = (c = A(d)) != null ? c : this.renderer.renderWrapper(!1);
1168
1203
  e ? a.forEach((p) => {
1169
1204
  l.appendChild(p);
@@ -1175,13 +1210,16 @@ class X {
1175
1210
  var n;
1176
1211
  t.stopPropagation(), t.preventDefault();
1177
1212
  const e = this.currentItem;
1178
- if (!e) return;
1213
+ if (!e)
1214
+ return;
1179
1215
  if (((n = this.config) == null ? void 0 : n.maxLevel) !== void 0) {
1180
1216
  const r = this.currentItemLevel;
1181
- if (r !== null && r === this.config.maxLevel) return;
1217
+ if (r !== null && r === this.config.maxLevel)
1218
+ return;
1182
1219
  }
1183
1220
  const i = e.previousSibling;
1184
- if (i === null || !R(i)) return;
1221
+ if (i === null || !R(i))
1222
+ return;
1185
1223
  const s = A(i);
1186
1224
  if (s)
1187
1225
  s.appendChild(e), I(e).forEach((r) => {
@@ -1193,7 +1231,7 @@ class X {
1193
1231
  r.appendChild(o);
1194
1232
  }), i.appendChild(r);
1195
1233
  }
1196
- J(e), F(e, !1);
1234
+ X(e), z(e, !1);
1197
1235
  }
1198
1236
  convertItemToDefaultBlock(t, e) {
1199
1237
  let i;
@@ -1202,13 +1240,14 @@ class X {
1202
1240
  }
1203
1241
  convertFirstItemToDefaultBlock() {
1204
1242
  const t = this.currentItem;
1205
- if (t === null) return;
1243
+ if (t === null)
1244
+ return;
1206
1245
  const e = I(t);
1207
1246
  if (e.length !== 0) {
1208
1247
  const r = e[0];
1209
- this.unshiftItem(r), F(t);
1248
+ this.unshiftItem(r), z(t);
1210
1249
  }
1211
- const i = G(t), s = this.api.blocks.getCurrentBlockIndex(), n = i === null;
1250
+ const i = J(t), s = this.api.blocks.getCurrentBlockIndex(), n = i === null;
1212
1251
  this.convertItemToDefaultBlock(s, n);
1213
1252
  }
1214
1253
  renderItem(t, e) {
@@ -1231,7 +1270,7 @@ class X {
1231
1270
  }
1232
1271
  }
1233
1272
  const ae = /* @__PURE__ */ new Map([["Numeric", "numeric"], ["Lower Roman", "lower-roman"], ["Upper Roman", "upper-roman"], ["Lower Alpha", "lower-alpha"], ["Upper Alpha", "upper-alpha"]]);
1234
- class K {
1273
+ class Y {
1235
1274
  static get isReadOnlySupported() {
1236
1275
  return !0;
1237
1276
  }
@@ -1245,7 +1284,7 @@ class K {
1245
1284
  return { tags: ["OL", "UL", "LI"] };
1246
1285
  }
1247
1286
  static get conversionConfig() {
1248
- return { export: (t) => K.joinRecursive(t), import: (t, e) => ({ meta: {}, items: [{ content: t, meta: {}, items: [] }], style: (e == null ? void 0 : e.defaultStyle) !== void 0 ? e.defaultStyle : "unordered" }) };
1287
+ return { export: (t) => Y.joinRecursive(t), import: (t, e) => ({ meta: {}, items: [{ content: t, meta: {}, items: [] }], style: (e == null ? void 0 : e.defaultStyle) !== void 0 ? e.defaultStyle : "unordered" }) };
1249
1288
  }
1250
1289
  get listStyle() {
1251
1290
  return this.data.style || this.defaultListStyle;
@@ -1276,7 +1315,7 @@ class K {
1276
1315
  }(t) : r, this.listStyle === "ordered" && this.data.meta.counterType === void 0 && (this.data.meta.counterType = "numeric"), this.changeTabulatorByStyle();
1277
1316
  }
1278
1317
  static joinRecursive(t) {
1279
- return t.items.map((e) => `${e.content} ${K.joinRecursive(e)}`).join("");
1318
+ return t.items.map((e) => `${e.content} ${Y.joinRecursive(e)}`).join("");
1280
1319
  }
1281
1320
  render() {
1282
1321
  return this.listElement = this.list.render(), this.listElement;
@@ -1305,13 +1344,13 @@ class K {
1305
1344
  changeTabulatorByStyle() {
1306
1345
  switch (this.listStyle) {
1307
1346
  case "ordered":
1308
- this.list = new X({ data: this.data, readOnly: this.readOnly, api: this.api, config: this.config, block: this.block }, new E(this.readOnly, this.config));
1347
+ this.list = new Q({ data: this.data, readOnly: this.readOnly, api: this.api, config: this.config, block: this.block }, new E(this.readOnly, this.config));
1309
1348
  break;
1310
1349
  case "unordered":
1311
- this.list = new X({ data: this.data, readOnly: this.readOnly, api: this.api, config: this.config, block: this.block }, new M(this.readOnly, this.config));
1350
+ this.list = new Q({ data: this.data, readOnly: this.readOnly, api: this.api, config: this.config, block: this.block }, new M(this.readOnly, this.config));
1312
1351
  break;
1313
1352
  case "checklist":
1314
- this.list = new X({ data: this.data, readOnly: this.readOnly, api: this.api, config: this.config, block: this.block }, new C(this.readOnly, this.config));
1353
+ this.list = new Q({ data: this.data, readOnly: this.readOnly, api: this.api, config: this.config, block: this.block }, new C(this.readOnly, this.config));
1315
1354
  }
1316
1355
  }
1317
1356
  }
@@ -1366,7 +1405,8 @@ class de {
1366
1405
  return !0;
1367
1406
  }
1368
1407
  truncate(t, e) {
1369
- for (; t.length > e; ) t.shift();
1408
+ for (; t.length > e; )
1409
+ t.shift();
1370
1410
  }
1371
1411
  initialize(t) {
1372
1412
  const e = "blocks" in t ? t.blocks : t, i = { index: e.length - 1, state: e };
@@ -1398,13 +1438,14 @@ class de {
1398
1438
  }
1399
1439
  getCaretIndex(t) {
1400
1440
  const e = this.holder.getElementsByClassName("ce-block__content");
1401
- return new lt(e[t].firstChild).getPos();
1441
+ return new at(e[t].firstChild).getPos();
1402
1442
  }
1403
1443
  insertDeletedBlock(t, e, i) {
1404
- for (let s = 0; s < t.length; s += 1) if (!e[s] || t[s].id !== e[s].id) {
1405
- this.blocks.insert(t[s].type, t[s].data, {}, s, !0), this.caret.setToBlock(i, "end");
1406
- break;
1407
- }
1444
+ for (let s = 0; s < t.length; s += 1)
1445
+ if (!e[s] || t[s].id !== e[s].id) {
1446
+ this.blocks.insert(t[s].type, t[s].data, {}, s, !0), this.caret.setToBlock(i, "end");
1447
+ break;
1448
+ }
1408
1449
  }
1409
1450
  blockWasDropped(t, e) {
1410
1451
  return t.length === e.length && t.some((i, s) => i.id !== e[s].id);
@@ -1429,11 +1470,16 @@ class de {
1429
1470
  const { state: s, caretIndex: n } = this.stack[this.position];
1430
1471
  this.onUpdate();
1431
1472
  const r = this.blocks.getBlocksCount();
1432
- if (s[i] || (i -= 1, this.stack[this.position].index = i), this.blockWasDeleted(s, e)) this.insertDeletedBlock(s, e, i);
1433
- else if (this.contentWasCopied(s, e, i)) await this.blocks.render({ blocks: s }), this.caret.setToBlock(i, "end");
1434
- else if (i < t && this.blockWasSkipped(s, e)) await this.blocks.delete(t), this.caret.setToBlock(i, "end");
1435
- else if (r > s.length) await this.blocks.render({ blocks: s }), this.setCaretIndex(i, n);
1436
- else if (this.blockWasDropped(s, e)) await this.blocks.render({ blocks: s }), this.caret.setToBlock(i, "end");
1473
+ if (s[i] || (i -= 1, this.stack[this.position].index = i), this.blockWasDeleted(s, e))
1474
+ this.insertDeletedBlock(s, e, i);
1475
+ else if (this.contentWasCopied(s, e, i))
1476
+ await this.blocks.render({ blocks: s }), this.caret.setToBlock(i, "end");
1477
+ else if (i < t && this.blockWasSkipped(s, e))
1478
+ await this.blocks.delete(t), this.caret.setToBlock(i, "end");
1479
+ else if (r > s.length)
1480
+ await this.blocks.render({ blocks: s }), this.setCaretIndex(i, n);
1481
+ else if (this.blockWasDropped(s, e))
1482
+ await this.blocks.render({ blocks: s }), this.caret.setToBlock(i, "end");
1437
1483
  else if (this.contentChangedInNoFocusBlock(i, t)) {
1438
1484
  const { id: a } = this.blocks.getBlockByIndex(t);
1439
1485
  await this.blocks.update(a, s[t].data), this.setCaretIndex(i, n);
@@ -1444,15 +1490,17 @@ class de {
1444
1490
  }
1445
1491
  setCaretIndex(t, e) {
1446
1492
  if (e && e !== -1) {
1447
- const i = this.holder.getElementsByClassName("ce-block__content"), s = new lt(i[t].firstChild);
1493
+ const i = this.holder.getElementsByClassName("ce-block__content"), s = new at(i[t].firstChild);
1448
1494
  setTimeout(() => s.setPos(e), 50);
1449
- } else this.caret.setToBlock(t, "end");
1495
+ } else
1496
+ this.caret.setToBlock(t, "end");
1450
1497
  }
1451
1498
  async insertBlock(t, e) {
1452
1499
  await this.blocks.insert(t[e].type, t[e].data, {}, e, !0);
1453
1500
  }
1454
1501
  async insertSkippedBlocks(t, e, i) {
1455
- for (let s = t.length; s < e.length; s += 1) this.insertBlock(e, s);
1502
+ for (let s = t.length; s < e.length; s += 1)
1503
+ this.insertBlock(e, s);
1456
1504
  JSON.stringify(t[i - 1]) !== JSON.stringify(e[i - 1]) && await this.updateModifiedBlock(e, i);
1457
1505
  }
1458
1506
  async updateModifiedBlock(t, e) {
@@ -1482,7 +1530,7 @@ class de {
1482
1530
  return i.push(s), i;
1483
1531
  }
1484
1532
  setEventListeners() {
1485
- const { holder: t } = this, { shortcuts: e } = this.config, { undo: i, redo: s } = e, n = i.map((u) => u.replace(/ /g, "").split("+")), r = s.map((u) => u.replace(/ /g, "").split("+")), o = n.map((u) => this.parseKeys(u)), a = r.map((u) => this.parseKeys(u)), d = (u, g) => g.reduce((m, f) => m || ((v, L) => L.length === 3 && v[L[0]] && v[L[1]] && v.key.toLowerCase() === L[2])(u, f), !1), l = (u, g, m) => !(!((f, v) => v.reduce((L, w) => L || ((_, B) => B.length === 2 && _[B[0]] && _.key.toLowerCase() === B[1])(f, w), !1))(u, g) || d(u, m)) || !!d(u, g), c = (u) => {
1533
+ const { holder: t } = this, { shortcuts: e } = this.config, { undo: i, redo: s } = e, n = i.map((u) => u.replace(/ /g, "").split("+")), r = s.map((u) => u.replace(/ /g, "").split("+")), o = n.map((u) => this.parseKeys(u)), a = r.map((u) => this.parseKeys(u)), d = (u, g) => g.reduce((m, f) => m || ((v, S) => S.length === 3 && v[S[0]] && v[S[1]] && v.key.toLowerCase() === S[2])(u, f), !1), l = (u, g, m) => !(!((f, v) => v.reduce((S, w) => S || ((_, B) => B.length === 2 && _[B[0]] && _.key.toLowerCase() === B[1])(f, w), !1))(u, g) || d(u, m)) || !!d(u, g), c = (u) => {
1486
1534
  l(u, o, a) && (u.preventDefault(), this.undo());
1487
1535
  }, p = (u) => {
1488
1536
  l(u, a, o) && (u.preventDefault(), this.redo());
@@ -1573,7 +1621,7 @@ class H {
1573
1621
  });
1574
1622
  }), H.ALIGN_TYPES.map((s) => {
1575
1623
  let n;
1576
- return s === "left" && (n = document.createElement("div"), n.classList.add("cdx-alert_setting__icon"), n.innerHTML = Ht), s === "right" && (n = document.createElement("div"), n.classList.add("cdx-alert_setting__icon"), n.innerHTML = Bt), s === "center" && (n = document.createElement("div"), n.classList.add("cdx-alert_setting__icon"), n.innerHTML = It), n == null || n.setAttribute("data-align", s), this.api.tooltip.onHover(n, this.api.i18n.t(`align-${s}`), { placement: "top" }), i.appendChild(n), n;
1624
+ return s === "left" && (n = document.createElement("div"), n.classList.add("cdx-alert_setting__icon"), n.innerHTML = It), s === "right" && (n = document.createElement("div"), n.classList.add("cdx-alert_setting__icon"), n.innerHTML = Ht), s === "center" && (n = document.createElement("div"), n.classList.add("cdx-alert_setting__icon"), n.innerHTML = _t), n == null || n.setAttribute("data-align", s), this.api.tooltip.onHover(n, this.api.i18n.t(`align-${s}`), { placement: "top" }), i.appendChild(n), n;
1577
1625
  }).forEach((s, n, r) => {
1578
1626
  const o = s.getAttribute("data-align") || "";
1579
1627
  s.addEventListener("click", () => {
@@ -1606,7 +1654,8 @@ class H {
1606
1654
  _make(t, e, i = {}) {
1607
1655
  let s = document.createElement(t);
1608
1656
  Array.isArray(e) ? s.classList.add(...e) : e && s.classList.add(e);
1609
- for (let n in i) s.setAttribute(n, i[n]);
1657
+ for (let n in i)
1658
+ s.setAttribute(n, i[n]);
1610
1659
  return s;
1611
1660
  }
1612
1661
  onPaste(t) {
@@ -1620,7 +1669,7 @@ class H {
1620
1669
  return { message: !0, type: !1, alignType: !1 };
1621
1670
  }
1622
1671
  }
1623
- const wt = { orientation: !1 }, b = class b {
1672
+ const kt = { orientation: !1 }, V = class x {
1624
1673
  constructor({ api: t, data: e, config: i, block: s, ...n }) {
1625
1674
  var o, a, d, l, c, p;
1626
1675
  this.wrapper = document.createElement("div"), this.DEFAULT_INDENT_KEY = "Tab", this.lastResizeTimeout = null, this.cachedMaxWidthForContent = null, this.api = t, this.block = s, !i && "settings" in n && (i = (o = n.settings) != null ? o : {}), this.config = { indentSize: 24, maxIndent: 8, minIndent: 0, multiblock: !1, autoIndent: !1, tuneName: null, orientation: "horizontal", customBlockIndentLimits: {}, handleShortcut: void 0, direction: "ltr", directionChangeHandler: null, version: "2.30", ...i != null ? i : {} }, this.changeConfigBasedOnVersionIfNeeded(), (a = this.config) != null && a.directionChangeHandler && this.config.directionChangeHandler(this.alignmentChangeListener.bind(this));
@@ -1643,11 +1692,13 @@ const wt = { orientation: !1 }, b = class b {
1643
1692
  const t = () => {
1644
1693
  if (this.data.indentLevel == this.maxIndent) {
1645
1694
  const a = this.getTuneButton("indent");
1646
- if (a == null || a.classList.add(this.CSS.disabledItem), !a) return !0;
1695
+ if (a == null || a.classList.add(this.CSS.disabledItem), !a)
1696
+ return !0;
1647
1697
  }
1648
1698
  if (this.data.indentLevel == this.minIndent) {
1649
1699
  const a = this.getTuneButton("unindent");
1650
- if (a == null || a.classList.add(this.CSS.disabledItem), !a) return !0;
1700
+ if (a == null || a.classList.add(this.CSS.disabledItem), !a)
1701
+ return !0;
1651
1702
  }
1652
1703
  };
1653
1704
  if (queueMicrotask(() => {
@@ -1656,22 +1707,22 @@ const wt = { orientation: !1 }, b = class b {
1656
1707
  const a = `${this.TuneNames.indentLeft}-${(r = this.block) == null ? void 0 : r.id}`, d = `${this.TuneNames.indentRight}-${(o = this.block) == null ? void 0 : o.id}`;
1657
1708
  return [{ title: this.rightText, hint: { title: this.api.i18n.t(this.rightText) }, onActivate: (l, c) => {
1658
1709
  this.handleIndentRight(), l.title = this.rightText;
1659
- }, icon: kt, name: d }, { title: this.leftText, hint: { title: this.api.i18n.t(this.leftText) }, onActivate: (l, c) => {
1710
+ }, icon: vt, name: d }, { title: this.leftText, hint: { title: this.api.i18n.t(this.leftText) }, onActivate: (l, c) => {
1660
1711
  this.handleIndentLeft(), l.title = this.leftText;
1661
- }, icon: vt, name: a }];
1712
+ }, icon: Ct, name: a }];
1662
1713
  }
1663
1714
  const e = `
1664
1715
  <div class="${this.CSS.popoverItem} ${this.CSS.customPopoverItem}" data-item-name='indent' version=${this.config.version}>
1665
- <button type="button" class="${this.CSS.popoverItemIcon}" data-${this.TuneNames.indentLeft}>${vt}</button>
1716
+ <button type="button" class="${this.CSS.popoverItemIcon}" data-${this.TuneNames.indentLeft}>${Ct}</button>
1666
1717
  <span class="${this.CSS.popoverItemTitle}">${this.api.sanitizer.clean(this.api.i18n.t("Indent"), {})}</span>
1667
- <button type="button" class="${this.CSS.popoverItemIcon}" data-${this.TuneNames.indentRight} style="margin-left:10px;">${kt}</button>
1718
+ <button type="button" class="${this.CSS.popoverItemIcon}" data-${this.TuneNames.indentRight} style="margin-left:10px;">${vt}</button>
1668
1719
  </div>
1669
1720
  `, i = this.createElementFromTemplate(e), s = i.querySelector(`[data-${this.TuneNames.indentRight}]`), n = i.querySelector(`[data-${this.TuneNames.indentLeft}]`);
1670
1721
  return s && (s.addEventListener("click", () => this.handleIndentRight()), this.api.tooltip.onHover(s, this.api.i18n.t("Indent right"), { placement: "top" })), n && (n.addEventListener("click", () => this.handleIndentLeft()), this.api.tooltip.onHover(n, this.api.i18n.t("Indent left"), { placement: "top" })), i;
1671
1722
  }
1672
1723
  wrap(t) {
1673
1724
  var i, s, n, r, o;
1674
- this.wrapper.appendChild(t), this.wrapper.setAttribute(b.DATA_WRAPPER_NAME, "");
1725
+ this.wrapper.appendChild(t), this.wrapper.setAttribute(x.DATA_WRAPPER_NAME, "");
1675
1726
  let e = !!this.config.highlightIndent;
1676
1727
  if ((i = this.config.highlightIndent) != null && i.tuneNames && !this.config.highlightIndent.tuneNames.includes((n = (s = this.block) == null ? void 0 : s.name) != null ? n : "") && (e = !1), e) {
1677
1728
  const a = this.createElementFromTemplate(`
@@ -1717,22 +1768,29 @@ const wt = { orientation: !1 }, b = class b {
1717
1768
  }
1718
1769
  get shouldApplyAutoIndent() {
1719
1770
  var s;
1720
- if (!this.config.autoIndent) return !1;
1721
- if (typeof this.config.autoIndent == "boolean") return this.config.autoIndent;
1771
+ if (!this.config.autoIndent)
1772
+ return !1;
1773
+ if (typeof this.config.autoIndent == "boolean")
1774
+ return this.config.autoIndent;
1722
1775
  const t = this.api.blocks.getCurrentBlockIndex();
1723
- if (t < 0) return !1;
1776
+ if (t < 0)
1777
+ return !1;
1724
1778
  const e = this.api.blocks.getBlockByIndex(t);
1725
- if (!e) return !1;
1779
+ if (!e)
1780
+ return !1;
1726
1781
  const i = e.name;
1727
1782
  return !((s = this.config.autoIndent.tuneNames) != null && s.length) || this.config.autoIndent.tuneNames.includes(i);
1728
1783
  }
1729
1784
  handlePropagationForKeyEvent(t) {
1730
1785
  var r, o, a;
1731
- if (!((r = this.block) != null && r.id) || this.config.handleShortcut === !1) return null;
1786
+ if (!((r = this.block) != null && r.id) || this.config.handleShortcut === !1)
1787
+ return null;
1732
1788
  const e = t.key == this.DEFAULT_INDENT_KEY, i = typeof this.config.handleShortcut == "function";
1733
- if (!i && !e) return null;
1789
+ if (!i && !e)
1790
+ return null;
1734
1791
  const s = (a = (o = this.config).handleShortcut) == null ? void 0 : a.call(o, t, this.block.id);
1735
- if (!s && i) return null;
1792
+ if (!s && i)
1793
+ return null;
1736
1794
  let n;
1737
1795
  switch (s) {
1738
1796
  case "indent":
@@ -1742,26 +1800,32 @@ const wt = { orientation: !1 }, b = class b {
1742
1800
  n = !1;
1743
1801
  break;
1744
1802
  default:
1745
- if (!e) return null;
1803
+ if (!e)
1804
+ return null;
1746
1805
  n = !t.shiftKey;
1747
1806
  }
1748
1807
  return t.stopPropagation(), t.preventDefault(), { isIndent: n };
1749
1808
  }
1750
1809
  onKeyDown(t) {
1751
1810
  var n, r, o;
1752
- if (!((n = this.block) != null && n.id)) return;
1811
+ if (!((n = this.block) != null && n.id))
1812
+ return;
1753
1813
  const e = this.handlePropagationForKeyEvent(t);
1754
- if (!e) return;
1814
+ if (!e)
1815
+ return;
1755
1816
  const { isIndent: i } = e;
1756
1817
  this.api.inlineToolbar.close();
1757
1818
  const s = this.getGlobalSelectedBlocks();
1758
- if (!this.config.multiblock || s.length < 2) return i ? this.indentBlock() : this.unIndentBlock(), void ((o = (r = this.block).dispatchChange) == null ? void 0 : o.call(r));
1819
+ if (!this.config.multiblock || s.length < 2)
1820
+ return i ? this.indentBlock() : this.unIndentBlock(), void ((o = (r = this.block).dispatchChange) == null ? void 0 : o.call(r));
1759
1821
  this.config.tuneName && s.forEach(async (a) => {
1760
1822
  var p, u, g, m;
1761
1823
  const d = await a.save();
1762
- if (!d || !("tunes" in d) || typeof d.tunes != "object" || !d.tunes) return;
1824
+ if (!d || !("tunes" in d) || typeof d.tunes != "object" || !d.tunes)
1825
+ return;
1763
1826
  const l = d.tunes[(p = this.config.tuneName) != null ? p : ""];
1764
- if (!l) return;
1827
+ if (!l)
1828
+ return;
1765
1829
  l.indentLevel = i ? Math.min(this.config.maxIndent, ((u = l.indentLevel) != null ? u : 0) + 1) : Math.max(0, ((g = l.indentLevel) != null ? g : 0) - 1), (m = a.dispatchChange) == null || m.call(a);
1766
1830
  const c = this.getWrapperBlockById(a.id);
1767
1831
  c instanceof HTMLElement && this.applyStylesToWrapper(c, l.indentLevel);
@@ -1784,8 +1848,9 @@ const wt = { orientation: !1 }, b = class b {
1784
1848
  autoIndentBlock() {
1785
1849
  var r, o;
1786
1850
  const t = this.api.blocks.getBlockIndex(this.block.id), e = this.api.blocks.getBlockByIndex(t - 1);
1787
- if (!e) return;
1788
- const i = (o = (r = e.holder) == null ? void 0 : r.querySelector(`[${b.DATA_WRAPPER_NAME}]`)) == null ? void 0 : o.getAttribute(b.DATA_INDENT_LEVEL), s = Number(i != null ? i : 0), n = Math.min(Math.max(s, this.minIndent), this.maxIndent);
1851
+ if (!e)
1852
+ return;
1853
+ const i = (o = (r = e.holder) == null ? void 0 : r.querySelector(`[${x.DATA_WRAPPER_NAME}]`)) == null ? void 0 : o.getAttribute(x.DATA_INDENT_LEVEL), s = Number(i != null ? i : 0), n = Math.min(Math.max(s, this.minIndent), this.maxIndent);
1789
1854
  this.data.indentLevel = n, this.applyStylesToWrapper(this.wrapper, this.data.indentLevel);
1790
1855
  }
1791
1856
  toggleDisableStateForButtons() {
@@ -1804,27 +1869,29 @@ const wt = { orientation: !1 }, b = class b {
1804
1869
  var e;
1805
1870
  return (e = this.getTuneByName(t)) == null ? void 0 : e.querySelector(`.${this.CSS.popoverItemTitle}`);
1806
1871
  }
1807
- applyStylesToWrapper(t, e = parseInt(t.getAttribute(b.DATA_INDENT_LEVEL) || "0")) {
1872
+ applyStylesToWrapper(t, e = parseInt(t.getAttribute(x.DATA_INDENT_LEVEL) || "0")) {
1808
1873
  const i = e * this.config.indentSize;
1809
- t.setAttribute(b.DATA_INDENT_LEVEL, e.toString());
1874
+ t.setAttribute(x.DATA_INDENT_LEVEL, e.toString());
1810
1875
  const s = t.querySelector(`.${this.EditorCSS.content}`), n = this.getBlockForWrapper(t) || document.querySelector(`.${this.EditorCSS.redactor}`);
1811
- if (!(s instanceof HTMLElement && n)) return;
1876
+ if (!(s instanceof HTMLElement && n))
1877
+ return;
1812
1878
  const r = n.getBoundingClientRect().width;
1813
- if (r === 0) return void queueMicrotask(() => this.applyStylesToWrapper.bind(this)(t, e));
1879
+ if (r === 0)
1880
+ return void queueMicrotask(() => this.applyStylesToWrapper.bind(this)(t, e));
1814
1881
  const o = (r - this.maxWidthForContent(t)) / 2, a = Math.max(0, Math.min(o, i)), d = 2 * a + "px", l = `${a}px`;
1815
1882
  this.isDirectionInverted ? (t.style.paddingLeft = "0px", t.style.paddingRight = d) : (t.style.paddingLeft = d, t.style.paddingRight = "0px");
1816
1883
  const c = t.querySelector(`.${this.CSS.highlightIndent}`);
1817
1884
  c instanceof HTMLElement && (this.isDirectionInverted ? (c.style.width = l, c.style.left = "100%", c.style.right = "") : (c.style.width = l, c.style.left = "", c.style.right = "100%"));
1818
1885
  }
1819
1886
  onFocus(t) {
1820
- t.target instanceof HTMLElement && this.wrapper.contains(t.target) && this.wrapper.setAttribute(b.DATA_FOCUSED, "");
1887
+ t.target instanceof HTMLElement && this.wrapper.contains(t.target) && this.wrapper.setAttribute(x.DATA_FOCUSED, "");
1821
1888
  }
1822
1889
  onBlur(t) {
1823
- t.target instanceof HTMLElement && this.wrapper.contains(t.target) && this.wrapper.removeAttribute(b.DATA_FOCUSED);
1890
+ t.target instanceof HTMLElement && this.wrapper.contains(t.target) && this.wrapper.removeAttribute(x.DATA_FOCUSED);
1824
1891
  }
1825
1892
  onResize(t) {
1826
1893
  this.lastResizeTimeout && clearTimeout(this.lastResizeTimeout), this.lastResizeTimeout = setTimeout(() => {
1827
- document.querySelectorAll(`[${b.DATA_WRAPPER_NAME}]`).forEach((e) => {
1894
+ document.querySelectorAll(`[${x.DATA_WRAPPER_NAME}]`).forEach((e) => {
1828
1895
  e instanceof HTMLElement && this.applyStylesToWrapper(e);
1829
1896
  });
1830
1897
  }, 500);
@@ -1834,13 +1901,14 @@ const wt = { orientation: !1 }, b = class b {
1834
1901
  }
1835
1902
  getWrapperBlockById(t) {
1836
1903
  var i, s, n;
1837
- const e = `.${this.EditorCSS.block}[data-id="${t}"] [${b.DATA_WRAPPER_NAME}]`;
1838
- return (n = (s = document.querySelector(e)) != null ? s : (i = this.api.blocks.getById(t)) == null ? void 0 : i.holder.querySelector(`[${b.DATA_WRAPPER_NAME}]`)) != null ? n : null;
1904
+ const e = `.${this.EditorCSS.block}[data-id="${t}"] [${x.DATA_WRAPPER_NAME}]`;
1905
+ return (n = (s = document.querySelector(e)) != null ? s : (i = this.api.blocks.getById(t)) == null ? void 0 : i.holder.querySelector(`[${x.DATA_WRAPPER_NAME}]`)) != null ? n : null;
1839
1906
  }
1840
1907
  getBlockForWrapper(t) {
1841
1908
  let e = t;
1842
1909
  for (; !e.classList.contains(this.EditorCSS.block); ) {
1843
- if (!e.parentElement || e instanceof HTMLHtmlElement) return null;
1910
+ if (!e.parentElement || e instanceof HTMLHtmlElement)
1911
+ return null;
1844
1912
  e = e.parentElement;
1845
1913
  }
1846
1914
  return e;
@@ -1858,22 +1926,23 @@ const wt = { orientation: !1 }, b = class b {
1858
1926
  return new DOMParser().parseFromString(t, "text/html").body.firstChild;
1859
1927
  }
1860
1928
  changeConfigBasedOnVersionIfNeeded() {
1861
- this.config.version && this.config.version < "2.27" && this.config.orientation === "vertical" && (this.config.orientation = "horizontal", wt.orientation, wt.orientation = !0);
1929
+ this.config.version && this.config.version < "2.27" && this.config.orientation === "vertical" && (this.config.orientation = "horizontal", kt.orientation, kt.orientation = !0);
1862
1930
  }
1863
1931
  maxWidthForContent(t) {
1864
1932
  const e = t.querySelector(`.${this.EditorCSS.content}`);
1865
1933
  if (e instanceof HTMLElement) {
1866
1934
  const { maxWidth: i } = window.getComputedStyle(e);
1867
- if (i) return this.cachedMaxWidthForContent = parseInt(i), this.cachedMaxWidthForContent;
1935
+ if (i)
1936
+ return this.cachedMaxWidthForContent = parseInt(i), this.cachedMaxWidthForContent;
1868
1937
  }
1869
1938
  return this.cachedMaxWidthForContent !== null || (this.cachedMaxWidthForContent = 650), this.cachedMaxWidthForContent;
1870
1939
  }
1871
1940
  };
1872
- b.DATA_WRAPPER_NAME = "data-block-indent-wrapper", b.DATA_FOCUSED = "data-focused", b.DATA_INDENT_LEVEL = "data-indent-level";
1873
- let st = b;
1874
- class W {
1941
+ V.DATA_WRAPPER_NAME = "data-block-indent-wrapper", V.DATA_FOCUSED = "data-focused", V.DATA_INDENT_LEVEL = "data-indent-level";
1942
+ let he = V;
1943
+ class P {
1875
1944
  static get toolboxIcon() {
1876
- return Ct;
1945
+ return ft;
1877
1946
  }
1878
1947
  static get CSS() {
1879
1948
  return "cdx-marker";
@@ -1888,13 +1957,14 @@ class W {
1888
1957
  return this.button = document.createElement("button"), this.button.setAttribute("type", "button"), this.button.classList.add(this.iconClasses.base), this.button.innerHTML = this.toolboxIcon, this.button;
1889
1958
  }
1890
1959
  surround(t) {
1891
- if (!t) return;
1892
- let e = this.api.selection.findParentTag(this.tag, W.CSS);
1960
+ if (!t)
1961
+ return;
1962
+ let e = this.api.selection.findParentTag(this.tag, P.CSS);
1893
1963
  e ? this.unwrap(e) : this.wrap(t);
1894
1964
  }
1895
1965
  wrap(t) {
1896
1966
  let e = document.createElement(this.tag);
1897
- e.classList.add(W.CSS), e.appendChild(t.extractContents()), t.insertNode(e), this.api.selection.expandToTag(e);
1967
+ e.classList.add(P.CSS), e.appendChild(t.extractContents()), t.insertNode(e), this.api.selection.expandToTag(e);
1898
1968
  }
1899
1969
  unwrap(t) {
1900
1970
  var n;
@@ -1904,17 +1974,17 @@ class W {
1904
1974
  }
1905
1975
  checkState() {
1906
1976
  var e;
1907
- const t = this.api.selection.findParentTag(this.tag, W.CSS);
1977
+ const t = this.api.selection.findParentTag(this.tag, P.CSS);
1908
1978
  (e = this.button) == null || e.classList.toggle(this.iconClasses.active, !!t);
1909
1979
  }
1910
1980
  get toolboxIcon() {
1911
- return Ct;
1981
+ return ft;
1912
1982
  }
1913
1983
  static get sanitize() {
1914
- return { mark: { class: W.CSS } };
1984
+ return { mark: { class: P.CSS } };
1915
1985
  }
1916
1986
  }
1917
- class he {
1987
+ class ce {
1918
1988
  constructor(t) {
1919
1989
  this.tag = "SPAN", this.class = "cdx-text-color", this.defaultColor = "#2644FF", this.lastRange = null, this.colors = ["#182a4e", "#0055cc", "#1f6a83", "#206e4e", "#e56910", "#ae2e24", "#5e4db2", "#758195", "#1e7afd", "#2998bd", "#23a06b", "#fea363", "#c9372c", "#8270db"], this.columns = 7;
1920
1990
  const { api: e, config: i } = t;
@@ -1936,7 +2006,8 @@ class he {
1936
2006
  this.lastRange = t;
1937
2007
  }
1938
2008
  wrapAndColor(t, e) {
1939
- if (!t) return;
2009
+ if (!t)
2010
+ return;
1940
2011
  const i = t.extractContents(), s = document.createElement(this.tag);
1941
2012
  s.classList.add(this.class), s.appendChild(i), s.style.color = e, s.innerHTML = s.textContent || "", t.insertNode(s), this.api.selection.expandToTag(s);
1942
2013
  }
@@ -1953,11 +2024,11 @@ class he {
1953
2024
  return { span: { style: { color: !0 } } };
1954
2025
  }
1955
2026
  }
1956
- class ce extends he {
2027
+ class pe extends ce {
1957
2028
  static get sanitize() {
1958
2029
  }
1959
2030
  }
1960
- const z = class z {
2031
+ const Ot = class $ {
1961
2032
  constructor(t) {
1962
2033
  this.tag = "U", this.api = t.api, this.iconClasses = { base: this.api.styles.inlineToolButton, active: this.api.styles.inlineToolButtonActive };
1963
2034
  }
@@ -1968,39 +2039,42 @@ const z = class z {
1968
2039
  return this.button = document.createElement("button"), this.button.type = "button", this.button.classList.add(this.iconClasses.base), this.button.innerHTML = this.toolboxIcon, this.button;
1969
2040
  }
1970
2041
  surround(t) {
1971
- if (!t) return;
1972
- const e = this.api.selection.findParentTag(this.tag, z.CSS);
2042
+ if (!t)
2043
+ return;
2044
+ const e = this.api.selection.findParentTag(this.tag, $.CSS);
1973
2045
  e ? this.unwrap(e) : this.wrap(t);
1974
2046
  }
1975
2047
  wrap(t) {
1976
2048
  const e = document.createElement(this.tag);
1977
- e.classList.add(z.CSS), e.appendChild(t.extractContents()), t.insertNode(e), this.api.selection.expandToTag(e);
2049
+ e.classList.add($.CSS), e.appendChild(t.extractContents()), t.insertNode(e), this.api.selection.expandToTag(e);
1978
2050
  }
1979
2051
  unwrap(t) {
1980
2052
  var n;
1981
2053
  this.api.selection.expandToTag(t);
1982
2054
  const e = window.getSelection();
1983
- if (!e) return;
2055
+ if (!e)
2056
+ return;
1984
2057
  const i = e.getRangeAt(0);
1985
- if (!i) return;
2058
+ if (!i)
2059
+ return;
1986
2060
  const s = i.extractContents();
1987
2061
  s && ((n = t.parentNode) == null || n.removeChild(t), i.insertNode(s), e.removeAllRanges(), e.addRange(i));
1988
2062
  }
1989
2063
  checkState() {
1990
2064
  var e;
1991
- const t = this.api.selection.findParentTag(this.tag, z.CSS);
2065
+ const t = this.api.selection.findParentTag(this.tag, $.CSS);
1992
2066
  return (e = this.button) == null || e.classList.toggle(this.iconClasses.active, !!t), !!t;
1993
2067
  }
1994
2068
  get toolboxIcon() {
1995
2069
  return '<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" fill="none" viewBox="0 0 24 24"><path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M9 7.5V11.5C9 12.2956 9.31607 13.0587 9.87868 13.6213C10.4413 14.1839 11.2044 14.5 12 14.5C12.7956 14.5 13.5587 14.1839 14.1213 13.6213C14.6839 13.0587 15 12.2956 15 11.5V7.5"/><path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M7.71429 18H16.2857"/></svg>';
1996
2070
  }
1997
2071
  static get sanitize() {
1998
- return { u: { class: z.CSS } };
2072
+ return { u: { class: $.CSS } };
1999
2073
  }
2000
2074
  };
2001
- z.isInline = !0;
2002
- let nt = z;
2003
- class $ {
2075
+ Ot.isInline = !0;
2076
+ let ue = Ot;
2077
+ class W {
2004
2078
  constructor({ api: t }) {
2005
2079
  this.tag = "CODE", this.api = t, this.button = null, this.iconClasses = { base: this.api.styles.inlineToolButton, active: this.api.styles.inlineToolButtonActive };
2006
2080
  }
@@ -2015,56 +2089,59 @@ class $ {
2015
2089
  }
2016
2090
  surround(t) {
2017
2091
  var i;
2018
- if (!t) return;
2019
- let e = this.api.selection.findParentTag(this.tag, $.CSS);
2092
+ if (!t)
2093
+ return;
2094
+ let e = this.api.selection.findParentTag(this.tag, W.CSS);
2020
2095
  e ? this.unwrap(e) : (i = t.commonAncestorContainer.parentElement) != null && i.querySelector(this.tag) || this.wrap(t);
2021
2096
  }
2022
2097
  wrap(t) {
2023
2098
  let e = document.createElement(this.tag);
2024
- e.classList.add($.CSS), e.appendChild(t.extractContents()), t.insertNode(e), this.api.selection.expandToTag(e);
2099
+ e.classList.add(W.CSS), e.appendChild(t.extractContents()), t.insertNode(e), this.api.selection.expandToTag(e);
2025
2100
  }
2026
2101
  unwrap(t) {
2027
2102
  var n;
2028
2103
  this.api.selection.expandToTag(t);
2029
2104
  const e = window.getSelection();
2030
- if (!e) return;
2105
+ if (!e)
2106
+ return;
2031
2107
  const i = e.getRangeAt(0), s = i.extractContents();
2032
2108
  (n = t.parentNode) == null || n.removeChild(t), i.insertNode(s), e.removeAllRanges(), e.addRange(i);
2033
2109
  }
2034
2110
  checkState() {
2035
- const t = this.api.selection.findParentTag(this.tag, $.CSS);
2111
+ const t = this.api.selection.findParentTag(this.tag, W.CSS);
2036
2112
  return this.button && this.button.classList.toggle(this.iconClasses.active, !!t), !!t;
2037
2113
  }
2038
2114
  get toolboxIcon() {
2039
2115
  return '<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" fill="none" viewBox="0 0 24 24"><path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M9 8L5 12L9 16"/><path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M15 8L19 12L15 16"/></svg>';
2040
2116
  }
2041
2117
  static get sanitize() {
2042
- return { code: { class: $.CSS } };
2118
+ return { code: { class: W.CSS } };
2043
2119
  }
2044
2120
  }
2045
2121
  function T(h, t, e = {}) {
2046
2122
  const i = document.createElement(h);
2047
2123
  Array.isArray(t) ? i.classList.add(...t) : t && i.classList.add(t);
2048
- for (const s in e) Object.prototype.hasOwnProperty.call(e, s) && (i[s] = e[s]);
2124
+ for (const s in e)
2125
+ Object.prototype.hasOwnProperty.call(e, s) && (i[s] = e[s]);
2049
2126
  return i;
2050
2127
  }
2051
- function bt(h) {
2128
+ function wt(h) {
2052
2129
  const t = h.getBoundingClientRect();
2053
2130
  return { y1: Math.floor(t.top + window.pageYOffset), x1: Math.floor(t.left + window.pageXOffset), x2: Math.floor(t.right + window.pageXOffset), y2: Math.floor(t.bottom + window.pageYOffset) };
2054
2131
  }
2055
- function Q(h, t) {
2056
- const e = bt(h), i = bt(t);
2132
+ function Z(h, t) {
2133
+ const e = wt(h), i = wt(t);
2057
2134
  return { fromTopBorder: i.y1 - e.y1, fromLeftBorder: i.x1 - e.x1, fromRightBorder: e.x2 - i.x2, fromBottomBorder: e.y2 - i.y2 };
2058
2135
  }
2059
- function yt(h, t) {
2136
+ function bt(h, t) {
2060
2137
  var e;
2061
2138
  return (e = t == null ? void 0 : t.parentNode) == null ? void 0 : e.insertBefore(h, t);
2062
2139
  }
2063
- function St(h, t = !0) {
2140
+ function yt(h, t = !0) {
2064
2141
  const e = document.createRange(), i = window.getSelection();
2065
2142
  e.selectNodeContents(h), e.collapse(t), i == null || i.removeAllRanges(), i == null || i.addRange(e);
2066
2143
  }
2067
- class y {
2144
+ class b {
2068
2145
  constructor({ items: t }) {
2069
2146
  this.items = t, this.wrapper = void 0, this.itemEls = [];
2070
2147
  }
@@ -2072,44 +2149,46 @@ class y {
2072
2149
  return { popover: "tc-popover", popoverOpened: "tc-popover--opened", item: "tc-popover__item", itemHidden: "tc-popover__item--hidden", itemConfirmState: "tc-popover__item--confirm", itemIcon: "tc-popover__item-icon", itemLabel: "tc-popover__item-label" };
2073
2150
  }
2074
2151
  render() {
2075
- return this.wrapper = T("div", y.CSS.popover), this.items.forEach((t, e) => {
2152
+ return this.wrapper = T("div", b.CSS.popover), this.items.forEach((t, e) => {
2076
2153
  var r;
2077
- const i = T("div", y.CSS.item), s = T("div", y.CSS.itemIcon, { innerHTML: t.icon }), n = T("div", y.CSS.itemLabel, { textContent: t.label });
2154
+ const i = T("div", b.CSS.item), s = T("div", b.CSS.itemIcon, { innerHTML: t.icon }), n = T("div", b.CSS.itemLabel, { textContent: t.label });
2078
2155
  i.dataset.index = e + "", i.appendChild(s), i.appendChild(n), (r = this.wrapper) == null || r.appendChild(i), this.itemEls.push(i);
2079
2156
  }), this.wrapper.addEventListener("click", (t) => {
2080
2157
  this.popoverClicked(t);
2081
2158
  }), this.wrapper;
2082
2159
  }
2083
2160
  popoverClicked(t) {
2084
- const e = t.target.closest(`.${y.CSS.item}`);
2085
- if (!e) return;
2161
+ const e = t.target.closest(`.${b.CSS.item}`);
2162
+ if (!e)
2163
+ return;
2086
2164
  const i = e.dataset.index;
2087
- if (!i) return;
2165
+ if (!i)
2166
+ return;
2088
2167
  const s = this.items[parseInt(i)];
2089
2168
  !s.confirmationRequired || this.hasConfirmationState(e) ? s.onClick() : this.setConfirmationState(e);
2090
2169
  }
2091
2170
  setConfirmationState(t) {
2092
- t.classList.add(y.CSS.itemConfirmState);
2171
+ t.classList.add(b.CSS.itemConfirmState);
2093
2172
  }
2094
2173
  clearConfirmationState(t) {
2095
- t.classList.remove(y.CSS.itemConfirmState);
2174
+ t.classList.remove(b.CSS.itemConfirmState);
2096
2175
  }
2097
2176
  hasConfirmationState(t) {
2098
- return t.classList.contains(y.CSS.itemConfirmState);
2177
+ return t.classList.contains(b.CSS.itemConfirmState);
2099
2178
  }
2100
2179
  get opened() {
2101
2180
  var t;
2102
- return ((t = this.wrapper) == null ? void 0 : t.classList.contains(y.CSS.popoverOpened)) || !1;
2181
+ return ((t = this.wrapper) == null ? void 0 : t.classList.contains(b.CSS.popoverOpened)) || !1;
2103
2182
  }
2104
2183
  open() {
2105
2184
  var t;
2106
2185
  this.items.forEach((e, i) => {
2107
- typeof e.hideIf == "function" && this.itemEls[i].classList.toggle(y.CSS.itemHidden, e.hideIf());
2108
- }), (t = this.wrapper) == null || t.classList.add(y.CSS.popoverOpened);
2186
+ typeof e.hideIf == "function" && this.itemEls[i].classList.toggle(b.CSS.itemHidden, e.hideIf());
2187
+ }), (t = this.wrapper) == null || t.classList.add(b.CSS.popoverOpened);
2109
2188
  }
2110
2189
  close() {
2111
2190
  var t;
2112
- (t = this.wrapper) == null || t.classList.remove(y.CSS.popoverOpened), this.itemEls.forEach((e) => {
2191
+ (t = this.wrapper) == null || t.classList.remove(b.CSS.popoverOpened), this.itemEls.forEach((e) => {
2113
2192
  this.clearConfirmationState(e);
2114
2193
  });
2115
2194
  }
@@ -2137,7 +2216,7 @@ class O {
2137
2216
  }), t;
2138
2217
  }
2139
2218
  createPopover() {
2140
- return this.popover = new y({ items: this.items }), this.popover.render();
2219
+ return this.popover = new b({ items: this.items }), this.popover.render();
2141
2220
  }
2142
2221
  togglerClicked() {
2143
2222
  var t, e;
@@ -2154,22 +2233,23 @@ class O {
2154
2233
  (t = this.popover) == null || t.close(), this.wrapper.classList.remove(O.CSS.toolboxShowed);
2155
2234
  }
2156
2235
  }
2157
- const Lt = "tc-wrap", pe = "tc-wrap--readonly", xt = "tc-table", D = "tc-row", Tt = "tc-table--heading", Z = "tc-row--selected", N = "tc-cell", tt = "tc-cell--selected", et = "tc-add-row", Et = "tc-add-row--disabled", it = "tc-add-column", Mt = "tc-add-column--disabled";
2158
- class ue {
2236
+ const St = "tc-wrap", ge = "tc-wrap--readonly", Lt = "tc-table", D = "tc-row", xt = "tc-table--heading", tt = "tc-row--selected", N = "tc-cell", et = "tc-cell--selected", it = "tc-add-row", Tt = "tc-add-row--disabled", st = "tc-add-column", Et = "tc-add-column--disabled";
2237
+ class me {
2159
2238
  constructor(t, e, i, s) {
2160
2239
  this.minCellWidhth = 50, this.defaultCellWidth = 100, this.handleDocumentMousedown = (n) => {
2161
2240
  this.wrapper.contains(n.target) && n.target.classList.contains("cell-resizable") && (n.preventDefault(), this.isDragging = !0, this.table.classList.add("table-resizing"), document.addEventListener("mousemove", this.handleDocumentMousemove), document.addEventListener("mouseup", this.handleDocumentMouseup), this.draggingColumn = this.hoveredColumn, this.startWidth = this.colWidthArr[this.draggingColumn - 1], this.mouseStartX = n.clientX);
2162
2241
  }, this.handleDocumentMousemove = (n) => {
2163
- if (!this.isDragging) return;
2242
+ if (!this.isDragging)
2243
+ return;
2164
2244
  const r = n.clientX - this.mouseStartX, o = Math.max(this.startWidth + r, this.minCellWidhth);
2165
2245
  this.colWidthArr[this.draggingColumn - 1] = o, this.updateColWidth();
2166
2246
  }, this.handleDocumentMouseup = () => {
2167
2247
  this.updateToolboxesPosition(), this.isDragging = !1, this.table.classList.remove("table-resizing"), document.removeEventListener("mousemove", this.handleDocumentMousemove), document.removeEventListener("mouseup", this.handleDocumentMouseup);
2168
2248
  }, this.readOnly = t, this.api = e, this.data = i, this.config = s, this.wrapper = null, this.table = null, this.hoveredCell = null, this.isDragging = !1, this.draggingColumn = 0, this.startWidth = 0, this.mouseStartX = 0, this.colWidthArr = [], this.focusedCell = { row: 0, col: 0 }, this.toolboxColumn = this.createColumnToolbox(), this.toolboxRow = this.createRowToolbox(), this.createTableWrapper(), this.hoveredRow = 0, this.hoveredColumn = 0, this.selectedRow = 0, this.selectedColumn = 0, this.tunes = { withHeadings: !1 }, this.resize(), this.data.colWidth.length > 0 && (this.colWidthArr = this.data.colWidth), this.updateColWidth(), this.fill(), this.focusedCell = { row: 0, column: 0 }, this.documentClicked = (n) => {
2169
2249
  let r = n.target;
2170
- const o = r.closest(`.${xt}`) !== null, a = r.closest(`.${Lt}`) === null;
2250
+ const o = r.closest(`.${Lt}`) !== null, a = r.closest(`.${St}`) === null;
2171
2251
  (o || a) && this.hideToolboxes();
2172
- const d = r.closest(`.${et}`), l = r.closest(`.${it}`);
2252
+ const d = r.closest(`.${it}`), l = r.closest(`.${st}`);
2173
2253
  d && d.parentNode === this.wrapper ? (this.addRow(void 0, !0), this.hideToolboxes()) : l && l.parentNode === this.wrapper && (this.addColumn(void 0, !0), this.hideToolboxes());
2174
2254
  }, this.readOnly || this.bindEvents();
2175
2255
  }
@@ -2177,11 +2257,12 @@ class ue {
2177
2257
  return this.wrapper;
2178
2258
  }
2179
2259
  bindEvents() {
2180
- document.addEventListener("click", this.documentClicked), document.addEventListener("mousedown", (t) => this.handleDocumentMousedown(t)), this.table.addEventListener("mousemove", /* @__PURE__ */ function(t, e) {
2260
+ document.addEventListener("click", this.documentClicked), document.addEventListener("mousedown", (t) => this.handleDocumentMousedown(t)), this.table.addEventListener("mousemove", function(t, e) {
2181
2261
  let i = 0;
2182
2262
  return function(...s) {
2183
2263
  const n = (/* @__PURE__ */ new Date()).getTime();
2184
- if (!(n - i < t)) return i = n, e(...s);
2264
+ if (!(n - i < t))
2265
+ return i = n, e(...s);
2185
2266
  };
2186
2267
  }(150, (t) => this.onMouseMoveInTable(t)), { passive: !0 }), this.table.onkeypress = (t) => this.onKeyPressListener(t), this.table.addEventListener("keydown", (t) => this.onKeyDownListener(t)), this.table.addEventListener("focusin", (t) => this.focusInTableListener(t));
2187
2268
  }
@@ -2197,7 +2278,7 @@ class ue {
2197
2278
  this.addColumn(this.selectedColumn, !0), this.hideToolboxes(), this.updateColWidth();
2198
2279
  } }, { label: this.api.i18n.t("Add column to right"), icon: '<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" fill="none" viewBox="0 0 24 24"><path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M9.13333 14.9167L12.4667 18.25M12.4667 18.25L15.8 14.9167M12.4667 18.25L12.4667 10.0833C12.4667 9.19928 12.1155 8.35143 11.4904 7.72631C10.8652 7.10119 10.0174 6.75 9.13333 6.75"/></svg>', hideIf: () => this.numberOfColumns === this.config.maxcols, onClick: () => {
2199
2280
  this.addColumn(this.selectedColumn + 1, !0), this.hideToolboxes(), this.updateColWidth();
2200
- } }, { label: this.api.i18n.t("Delete column"), icon: ft, hideIf: () => this.numberOfColumns === 1, confirmationRequired: !0, onClick: () => {
2281
+ } }, { label: this.api.i18n.t("Delete column"), icon: mt, hideIf: () => this.numberOfColumns === 1, confirmationRequired: !0, onClick: () => {
2201
2282
  this.deleteColumn(this.selectedColumn), this.hideToolboxes(), this.updateColWidth();
2202
2283
  } }], onOpen: () => {
2203
2284
  this.selectColumn(this.hoveredColumn), this.hideRowToolbox();
@@ -2210,7 +2291,7 @@ class ue {
2210
2291
  this.addRow(this.selectedRow, !0), this.hideToolboxes();
2211
2292
  } }, { label: this.api.i18n.t("Add row below"), icon: '<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" fill="none" viewBox="0 0 24 24"><path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M14.8833 9.16666L18.2167 12.5M18.2167 12.5L14.8833 15.8333M18.2167 12.5H10.05C9.16594 12.5 8.31809 12.1488 7.69297 11.5237C7.06785 10.8986 6.71666 10.0507 6.71666 9.16666"/></svg>', hideIf: () => this.numberOfRows === this.config.maxrows, onClick: () => {
2212
2293
  this.addRow(this.selectedRow + 1, !0), this.hideToolboxes();
2213
- } }, { label: this.api.i18n.t("Delete row"), icon: ft, hideIf: () => this.numberOfRows === 1, confirmationRequired: !0, onClick: () => {
2294
+ } }, { label: this.api.i18n.t("Delete row"), icon: mt, hideIf: () => this.numberOfRows === 1, confirmationRequired: !0, onClick: () => {
2214
2295
  this.deleteRow(this.selectedRow), this.hideToolboxes();
2215
2296
  } }], onOpen: () => {
2216
2297
  this.selectRow(this.hoveredRow), this.hideColumnToolbox();
@@ -2239,45 +2320,48 @@ class ue {
2239
2320
  addColumn(t = -1, e = !1) {
2240
2321
  var n;
2241
2322
  let i = this.numberOfColumns;
2242
- if (this.config && this.config.maxcols && this.numberOfColumns >= this.config.maxcols) return;
2323
+ if (this.config && this.config.maxcols && this.numberOfColumns >= this.config.maxcols)
2324
+ return;
2243
2325
  for (let r = 1; r <= this.numberOfRows; r++) {
2244
2326
  let o;
2245
2327
  const a = this.createCell();
2246
- if (t > 0 && t <= i ? (o = this.getCell(r, t), yt(a, o)) : o = this.getRow(r).appendChild(a), r === 1) {
2328
+ if (t > 0 && t <= i ? (o = this.getCell(r, t), bt(a, o)) : o = this.getRow(r).appendChild(a), r === 1) {
2247
2329
  const d = this.getCell(r, t > 0 ? t : i + 1);
2248
- d && e && St(d);
2330
+ d && e && yt(d);
2249
2331
  }
2250
2332
  }
2251
- const s = this.wrapper.querySelector(`.${it}`);
2252
- (n = this.config) != null && n.maxcols && this.numberOfColumns > this.config.maxcols - 1 && s && s.classList.add(Mt), this.addHeadingAttrToFirstRow(), this.colWidthArr.splice(t - 1, 0, this.defaultCellWidth);
2333
+ const s = this.wrapper.querySelector(`.${st}`);
2334
+ (n = this.config) != null && n.maxcols && this.numberOfColumns > this.config.maxcols - 1 && s && s.classList.add(Et), this.addHeadingAttrToFirstRow(), this.colWidthArr.splice(t - 1, 0, this.defaultCellWidth);
2253
2335
  }
2254
2336
  addRow(t = -1, e = !1) {
2255
2337
  let i, s = T("div", D);
2256
2338
  this.tunes.withHeadings && this.removeHeadingAttrFromFirstRow();
2257
2339
  let n = this.numberOfColumns;
2258
- if (this.config && this.config.maxrows && this.numberOfRows >= this.config.maxrows) return;
2259
- t > 0 && t <= this.numberOfRows ? i = yt(s, this.getRow(t)) : i = this.table.appendChild(s), this.fillRow(i, n), this.tunes.withHeadings && this.addHeadingAttrToFirstRow();
2340
+ if (this.config && this.config.maxrows && this.numberOfRows >= this.config.maxrows)
2341
+ return;
2342
+ t > 0 && t <= this.numberOfRows ? i = bt(s, this.getRow(t)) : i = this.table.appendChild(s), this.fillRow(i, n), this.tunes.withHeadings && this.addHeadingAttrToFirstRow();
2260
2343
  const r = this.getRowFirstCell(i);
2261
- r && e && St(r);
2262
- const o = this.wrapper.querySelector(`.${et}`);
2263
- return this.config && this.config.maxrows && this.numberOfRows >= this.config.maxrows && o && o.classList.add(Et), i;
2344
+ r && e && yt(r);
2345
+ const o = this.wrapper.querySelector(`.${it}`);
2346
+ return this.config && this.config.maxrows && this.numberOfRows >= this.config.maxrows && o && o.classList.add(Tt), i;
2264
2347
  }
2265
2348
  deleteColumn(t) {
2266
2349
  for (let i = 1; i <= this.numberOfRows; i++) {
2267
2350
  const s = this.getCell(i, t);
2268
- if (!s) return;
2351
+ if (!s)
2352
+ return;
2269
2353
  s.remove();
2270
2354
  }
2271
- const e = this.wrapper.querySelector(`.${it}`);
2272
- e && e.classList.remove(Mt), this.colWidthArr.splice(t - 1, 1);
2355
+ const e = this.wrapper.querySelector(`.${st}`);
2356
+ e && e.classList.remove(Et), this.colWidthArr.splice(t - 1, 1);
2273
2357
  }
2274
2358
  deleteRow(t) {
2275
2359
  this.getRow(t).remove();
2276
- const e = this.wrapper.querySelector(`.${et}`);
2277
- e && e.classList.remove(Et), this.addHeadingAttrToFirstRow();
2360
+ const e = this.wrapper.querySelector(`.${it}`);
2361
+ e && e.classList.remove(Tt), this.addHeadingAttrToFirstRow();
2278
2362
  }
2279
2363
  createTableWrapper() {
2280
- this.wrapper = T("div", Lt), this.table = T("div", xt), this.readOnly && this.wrapper.classList.add(pe), this.wrapper.appendChild(this.toolboxRow.element), this.wrapper.appendChild(this.toolboxColumn.element), this.wrapper.appendChild(this.table);
2364
+ this.wrapper = T("div", St), this.table = T("div", Lt), this.readOnly && this.wrapper.classList.add(ge), this.wrapper.appendChild(this.toolboxRow.element), this.wrapper.appendChild(this.toolboxColumn.element), this.wrapper.appendChild(this.table);
2281
2365
  }
2282
2366
  computeInitialSize() {
2283
2367
  const t = this.data && this.data.content, e = Array.isArray(t), i = !!e && t.length, s = e ? t.length : void 0, n = i ? t[0].length : void 0, r = Number.parseInt(this.config && this.config.rows), o = Number.parseInt(this.config && this.config.cols), a = !isNaN(r) && r > 0 ? r : void 0, d = !isNaN(o) && o > 0 ? o : void 0;
@@ -2285,17 +2369,24 @@ class ue {
2285
2369
  }
2286
2370
  resize() {
2287
2371
  const { rows: t, cols: e } = this.computeInitialSize();
2288
- for (let i = 0; i < t; i++) this.addRow();
2289
- for (let i = 0; i < e; i++) this.addColumn();
2372
+ for (let i = 0; i < t; i++)
2373
+ this.addRow();
2374
+ for (let i = 0; i < e; i++)
2375
+ this.addColumn();
2290
2376
  }
2291
2377
  updateColWidth() {
2292
2378
  let t = "";
2293
- if (this.colWidthArr && this.colWidthArr.length > 0) for (let e = 0; e < this.colWidthArr.length; e++) t += " " + this.colWidthArr[e] + "px";
2379
+ if (this.colWidthArr && this.colWidthArr.length > 0)
2380
+ for (let e = 0; e < this.colWidthArr.length; e++)
2381
+ t += " " + this.colWidthArr[e] + "px";
2294
2382
  t && this.wrapper.style.setProperty("--col-width", t);
2295
2383
  }
2296
2384
  fill() {
2297
2385
  const t = this.data;
2298
- if (t && t.content) for (let e = 0; e < t.content.length; e++) for (let i = 0; i < t.content[e].length; i++) this.setCellContent(e + 1, i + 1, t.content[e][i]);
2386
+ if (t && t.content)
2387
+ for (let e = 0; e < t.content.length; e++)
2388
+ for (let i = 0; i < t.content[e].length; i++)
2389
+ this.setCellContent(e + 1, i + 1, t.content[e][i]);
2299
2390
  }
2300
2391
  fillRow(t, e) {
2301
2392
  for (let i = 1; i <= e; i++) {
@@ -2327,7 +2418,8 @@ class ue {
2327
2418
  }
2328
2419
  onKeyPressListener(t) {
2329
2420
  if (t.key === "Enter") {
2330
- if (t.shiftKey) return !0;
2421
+ if (t.shiftKey)
2422
+ return !0;
2331
2423
  this.moveCursorToNextRow();
2332
2424
  }
2333
2425
  return t.key !== "Enter";
@@ -2357,12 +2449,12 @@ class ue {
2357
2449
  }
2358
2450
  updateToolboxesPosition(t = this.hoveredRow, e = this.hoveredColumn) {
2359
2451
  this.isColumnMenuShowing || e > 0 && e <= this.numberOfColumns && this.toolboxColumn.show(() => ({ left: `calc((100% - var(--cell-size)) / (${this.numberOfColumns} * 2) * (1 + (${e} - 1) * 2))` })), this.isRowMenuShowing || t > 0 && t <= this.numberOfRows && this.toolboxRow.show(() => {
2360
- const i = this.getRow(t), { fromTopBorder: s } = Q(this.table, i), { height: n } = i.getBoundingClientRect();
2452
+ const i = this.getRow(t), { fromTopBorder: s } = Z(this.table, i), { height: n } = i.getBoundingClientRect();
2361
2453
  return { top: `${Math.ceil(s + n / 2)}px` };
2362
2454
  });
2363
2455
  }
2364
2456
  setHeadingsSetting(t) {
2365
- this.tunes.withHeadings = t, t ? (this.table.classList.add(Tt), this.addHeadingAttrToFirstRow()) : (this.table.classList.remove(Tt), this.removeHeadingAttrFromFirstRow());
2457
+ this.tunes.withHeadings = t, t ? (this.table.classList.add(xt), this.addHeadingAttrToFirstRow()) : (this.table.classList.remove(xt), this.removeHeadingAttrFromFirstRow());
2366
2458
  }
2367
2459
  addHeadingAttrToFirstRow() {
2368
2460
  for (let t = 1; t <= this.numberOfColumns; t++) {
@@ -2378,32 +2470,34 @@ class ue {
2378
2470
  }
2379
2471
  selectRow(t) {
2380
2472
  const e = this.getRow(t);
2381
- e && (this.selectedRow = t, e.classList.add(Z));
2473
+ e && (this.selectedRow = t, e.classList.add(tt));
2382
2474
  }
2383
2475
  unselectRow() {
2384
- if (this.selectedRow <= 0) return;
2385
- const t = this.table.querySelector(`.${Z}`);
2386
- t && t.classList.remove(Z), this.selectedRow = 0;
2476
+ if (this.selectedRow <= 0)
2477
+ return;
2478
+ const t = this.table.querySelector(`.${tt}`);
2479
+ t && t.classList.remove(tt), this.selectedRow = 0;
2387
2480
  }
2388
2481
  selectColumn(t) {
2389
2482
  for (let e = 1; e <= this.numberOfRows; e++) {
2390
2483
  const i = this.getCell(e, t);
2391
- i && i.classList.add(tt);
2484
+ i && i.classList.add(et);
2392
2485
  }
2393
2486
  this.selectedColumn = t;
2394
2487
  }
2395
2488
  unselectColumn() {
2396
- if (this.selectedColumn <= 0) return;
2397
- let t = this.table.querySelectorAll(`.${tt}`);
2489
+ if (this.selectedColumn <= 0)
2490
+ return;
2491
+ let t = this.table.querySelectorAll(`.${et}`);
2398
2492
  Array.from(t).forEach((e) => {
2399
- e.classList.remove(tt);
2493
+ e.classList.remove(et);
2400
2494
  }), this.selectedColumn = 0;
2401
2495
  }
2402
2496
  getHoveredCell(t) {
2403
2497
  let e = this.hoveredRow, i = this.hoveredColumn;
2404
2498
  const { width: s, height: n, x: r, y: o } = function(p, u) {
2405
- const g = p.getBoundingClientRect(), { width: m, height: f, x: v, y: L } = g, { clientX: w, clientY: _ } = u;
2406
- return { width: m, height: f, x: w - v, y: _ - L };
2499
+ const g = p.getBoundingClientRect(), { width: m, height: f, x: v, y: S } = g, { clientX: w, clientY: _ } = u;
2500
+ return { width: m, height: f, x: w - v, y: _ - S };
2407
2501
  }(this.table, t);
2408
2502
  if (r >= 0) {
2409
2503
  const p = ({ fromLeftBorder: g }) => r < g, u = ({ fromRightBorder: g }) => r > s - g;
@@ -2417,17 +2511,19 @@ class ue {
2417
2511
  return { row: a, column: d, deltaXCell: l, deltaYCell: c };
2418
2512
  }
2419
2513
  getMousePositionRelateToCell(t, e, i, s) {
2420
- const n = this.getCell(t, e), { fromTopBorder: r, fromLeftBorder: o } = Q(this.table, n);
2514
+ const n = this.getCell(t, e), { fromTopBorder: r, fromLeftBorder: o } = Z(this.table, n);
2421
2515
  return { deltaXCell: i - o, deltaYCell: s - r };
2422
2516
  }
2423
2517
  binSearch(t, e, i, s) {
2424
2518
  let n, r = 0, o = t + 1, a = 0;
2425
2519
  for (; r < o - 1 && a < 10; ) {
2426
2520
  n = Math.ceil((r + o) / 2);
2427
- const d = e(n), l = Q(this.table, d);
2428
- if (i(l)) o = n;
2521
+ const d = e(n), l = Z(this.table, d);
2522
+ if (i(l))
2523
+ o = n;
2429
2524
  else {
2430
- if (!s(l)) break;
2525
+ if (!s(l))
2526
+ break;
2431
2527
  r = n;
2432
2528
  }
2433
2529
  a++;
@@ -2446,7 +2542,7 @@ class ue {
2446
2542
  document.removeEventListener("click", this.documentClicked);
2447
2543
  }
2448
2544
  }
2449
- class ge {
2545
+ class fe {
2450
2546
  static get isReadOnlySupported() {
2451
2547
  return !0;
2452
2548
  }
@@ -2460,7 +2556,7 @@ class ge {
2460
2556
  return { icon: '<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" fill="none" viewBox="0 0 24 24"><path stroke="currentColor" stroke-width="2" d="M10 5V18.5"/><path stroke="currentColor" stroke-width="2" d="M5 10H19"/><rect width="14" height="14" x="5" y="5" stroke="currentColor" stroke-width="2" rx="4"/></svg>', title: "Table" };
2461
2557
  }
2462
2558
  render() {
2463
- return this.table = new ue(this.readOnly, this.api, this.data, this.config), this.container = T("div", this.api.styles.block), this.container.appendChild(this.table.getWrapper()), this.table.setHeadingsSetting(this.data.withHeadings), this.container;
2559
+ return this.table = new me(this.readOnly, this.api, this.data, this.config), this.container = T("div", this.api.styles.block), this.container.appendChild(this.table.getWrapper()), this.table.setHeadingsSetting(this.data.withHeadings), this.container;
2464
2560
  }
2465
2561
  renderSettings() {
2466
2562
  return [{ label: this.api.i18n.t("With headings"), icon: '<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" fill="none" viewBox="0 0 24 24"><path stroke="currentColor" stroke-width="2" d="M5 10H19"/><rect width="14" height="14" x="5" y="5" stroke="currentColor" stroke-width="2" rx="4"/></svg>', isActive: this.data.withHeadings, closeOnActivate: !0, toggle: !0, hint: { title: this.api.i18n.t("With headings") }, onActivate: () => {
@@ -2490,16 +2586,17 @@ class ge {
2490
2586
  }
2491
2587
  }
2492
2588
  }
2493
- function P(h, t = null, e = {}) {
2589
+ function F(h, t = null, e = {}) {
2494
2590
  const i = document.createElement(h);
2495
2591
  Array.isArray(t) ? i.classList.add(...t) : t !== null && i.classList.add(t);
2496
- for (const s in e) e.hasOwnProperty(s) && (i[s] = e[s]);
2592
+ for (const s in e)
2593
+ e.hasOwnProperty(s) && (i[s] = e[s]);
2497
2594
  return i;
2498
2595
  }
2499
- var V = ((h) => (h.Empty = "empty", h.Uploading = "uploading", h.Filled = "filled", h))(V || {});
2500
- class me {
2596
+ var K = ((h) => (h.Empty = "empty", h.Uploading = "uploading", h.Filled = "filled", h))(K || {});
2597
+ class Ce {
2501
2598
  constructor({ api: t, config: e, onSelectFile: i, readOnly: s }) {
2502
- this.api = t, this.config = e, this.onSelectFile = i, this.readOnly = s, this.nodes = { wrapper: P("div", [this.CSS.baseClass, this.CSS.wrapper]), imageContainer: P("div", [this.CSS.imageContainer]), fileButton: this.createFileButton(), imageEl: void 0, imagePreloader: P("div", this.CSS.imagePreloader), caption: P("div", [this.CSS.input, this.CSS.caption], { contentEditable: !this.readOnly }) }, this.nodes.caption.dataset.placeholder = this.config.captionPlaceholder, this.nodes.imageContainer.appendChild(this.nodes.imagePreloader), this.nodes.wrapper.appendChild(this.nodes.imageContainer), this.nodes.wrapper.appendChild(this.nodes.caption), this.nodes.wrapper.appendChild(this.nodes.fileButton);
2599
+ this.api = t, this.config = e, this.onSelectFile = i, this.readOnly = s, this.nodes = { wrapper: F("div", [this.CSS.baseClass, this.CSS.wrapper]), imageContainer: F("div", [this.CSS.imageContainer]), fileButton: this.createFileButton(), imageEl: void 0, imagePreloader: F("div", this.CSS.imagePreloader), caption: F("div", [this.CSS.input, this.CSS.caption], { contentEditable: !this.readOnly }) }, this.nodes.caption.dataset.placeholder = this.config.captionPlaceholder, this.nodes.imageContainer.appendChild(this.nodes.imagePreloader), this.nodes.wrapper.appendChild(this.nodes.imageContainer), this.nodes.wrapper.appendChild(this.nodes.caption), this.nodes.wrapper.appendChild(this.nodes.fileButton);
2503
2600
  }
2504
2601
  applyTune(t, e) {
2505
2602
  this.nodes.wrapper.classList.toggle(`${this.CSS.wrapper}--${t}`, e);
@@ -2516,7 +2613,7 @@ class me {
2516
2613
  fillImage(t) {
2517
2614
  const e = /\.mp4$/.test(t) ? "VIDEO" : "IMG", i = { src: t };
2518
2615
  let s = "load";
2519
- e === "VIDEO" && (i.autoplay = !0, i.loop = !0, i.muted = !0, i.playsinline = !0, s = "loadeddata"), this.nodes.imageEl = P(e, this.CSS.imageEl, i), this.nodes.imageEl.addEventListener(s, () => {
2616
+ e === "VIDEO" && (i.autoplay = !0, i.loop = !0, i.muted = !0, i.playsinline = !0, s = "loadeddata"), this.nodes.imageEl = F(e, this.CSS.imageEl, i), this.nodes.imageEl.addEventListener(s, () => {
2520
2617
  this.toggleStatus("filled"), this.nodes.imagePreloader !== void 0 && (this.nodes.imagePreloader.style.backgroundImage = "");
2521
2618
  }), this.nodes.imageContainer.appendChild(this.nodes.imageEl);
2522
2619
  }
@@ -2524,23 +2621,24 @@ class me {
2524
2621
  this.nodes.caption !== void 0 && (this.nodes.caption.innerHTML = t);
2525
2622
  }
2526
2623
  toggleStatus(t) {
2527
- for (const e in V) if (Object.prototype.hasOwnProperty.call(V, e)) {
2528
- const i = V[e];
2529
- this.nodes.wrapper.classList.toggle(`${this.CSS.wrapper}--${i}`, i === t);
2530
- }
2624
+ for (const e in K)
2625
+ if (Object.prototype.hasOwnProperty.call(K, e)) {
2626
+ const i = K[e];
2627
+ this.nodes.wrapper.classList.toggle(`${this.CSS.wrapper}--${i}`, i === t);
2628
+ }
2531
2629
  }
2532
2630
  get CSS() {
2533
2631
  return { baseClass: this.api.styles.block, loading: this.api.styles.loader, input: this.api.styles.input, button: this.api.styles.button, wrapper: "image-tool", imageContainer: "image-tool__image", imagePreloader: "image-tool__image-preloader", imageEl: "image-tool__image-picture", caption: "image-tool__caption" };
2534
2632
  }
2535
2633
  createFileButton() {
2536
2634
  var e;
2537
- const t = P("div", [this.CSS.button]);
2538
- return t.innerHTML = (e = this.config.buttonContent) != null ? e : `${At} ${this.api.i18n.t("Select an Image")}`, t.addEventListener("click", () => {
2635
+ const t = F("div", [this.CSS.button]);
2636
+ return t.innerHTML = (e = this.config.buttonContent) != null ? e : `${Bt} ${this.api.i18n.t("Select an Image")}`, t.addEventListener("click", () => {
2539
2637
  this.onSelectFile();
2540
2638
  }), t;
2541
2639
  }
2542
2640
  }
2543
- class fe {
2641
+ class ve {
2544
2642
  constructor({ config: t, onUpload: e, onError: i }) {
2545
2643
  this.config = t, this.onUpload = e, this.onError = i;
2546
2644
  }
@@ -2549,7 +2647,7 @@ class fe {
2549
2647
  let i = "", s = "";
2550
2648
  const n = await function(m = {}) {
2551
2649
  let f = !0;
2552
- return new Promise((v, L) => {
2650
+ return new Promise((v, S) => {
2553
2651
  let w = document.createElement("INPUT");
2554
2652
  w.type = "file", m.multiple && w.setAttribute("multiple", "multiple"), m.accept && w.setAttribute("accept", m.accept), w.style.display = "none", document.body.appendChild(w), w.addEventListener("change", (_) => {
2555
2653
  f = !1;
@@ -2562,7 +2660,8 @@ class fe {
2562
2660
  }, { once: !0 }), w.click();
2563
2661
  });
2564
2662
  }({ accept: (g = this.config.types) != null ? g : "image/*" });
2565
- if (!(n && n.length > 0)) return void e();
2663
+ if (!(n && n.length > 0))
2664
+ return void e();
2566
2665
  (function(m) {
2567
2666
  const f = new FileReader();
2568
2667
  f.readAsDataURL(m), f.onload = (v) => {
@@ -2571,7 +2670,8 @@ class fe {
2571
2670
  })(n[0]);
2572
2671
  const r = n[0], o = this.config.types.split(",");
2573
2672
  let a = r.name.lastIndexOf("."), d = r.name.slice(a);
2574
- if (!o.includes(d.toLowerCase())) return void this.onError("文件类型不支持");
2673
+ if (!o.includes(d.toLowerCase()))
2674
+ return void this.onError("文件类型不支持");
2575
2675
  let l = {};
2576
2676
  if (this.config.userStore) {
2577
2677
  const m = this.config.userStore.token, f = this.config.userStore.tokenName, v = this.config.userStore.tokenPrefix;
@@ -2579,9 +2679,11 @@ class fe {
2579
2679
  }
2580
2680
  l["Content-Type"] = "application/json";
2581
2681
  const c = U.create({ timeout: 18e5, headers: l }), p = await c.post(this.config.endpoints.byFile, { fileName: r.name, contentType: r.type });
2582
- if (p.status !== 200) return void this.onError(p.statusText);
2682
+ if (p.status !== 200)
2683
+ return void this.onError(p.statusText);
2583
2684
  const u = p.data;
2584
- if (!u.success) return void this.onError(u.message);
2685
+ if (!u.success)
2686
+ return void this.onError(u.message);
2585
2687
  i = u.data.cdn, s = u.data.objectKey, U.create({ timeout: 18e5, headers: { "Content-Type": r.type } }).put(u.data.presignedUrl, r).then((m) => {
2586
2688
  m.status === 200 && (m = { success: 1, file: { url: i + s } }), this.onUpload(m);
2587
2689
  }).catch((m) => {
@@ -2595,7 +2697,8 @@ class fe {
2595
2697
  s && n && (i[n] = r + " " + s);
2596
2698
  }
2597
2699
  e = U.create({ timeout: 18e5, headers: i }).post(this.config.endpoints.byUrl, { url: t, accept: ".jpg,.jpeg,.gif,.png,.webp" }), e.then((s) => {
2598
- if (s.status !== 200 || s.data.success === !1) return void this.onError(s.data.message);
2700
+ if (s.status !== 200 || s.data.success === !1)
2701
+ return void this.onError(s.data.message);
2599
2702
  let n = { success: 1, file: { url: s.data.data.cdn + s.data.data.objectKey } };
2600
2703
  this.onUpload(n);
2601
2704
  }).catch((s) => {
@@ -2605,7 +2708,8 @@ class fe {
2605
2708
  async uploadByFile(t, { onPreview: e }) {
2606
2709
  const i = this.config.types.split(",");
2607
2710
  let s = t.name.lastIndexOf("."), n = t.name.slice(s);
2608
- if (!i.includes(n.toLowerCase())) return void this.onError("文件类型不支持");
2711
+ if (!i.includes(n.toLowerCase()))
2712
+ return void this.onError("文件类型不支持");
2609
2713
  let r = {};
2610
2714
  if (this.config.userStore) {
2611
2715
  const p = this.config.userStore.token, u = this.config.userStore.tokenName, g = this.config.userStore.tokenPrefix;
@@ -2614,9 +2718,11 @@ class fe {
2614
2718
  const o = U.create({ timeout: 18e5, headers: r });
2615
2719
  r["Content-Type"] = "application/json";
2616
2720
  const a = await o.post(this.config.endpoints.byFile, { fileName: t.name, contentType: t.type });
2617
- if (a.status !== 200) return void this.onError(a.statusText);
2721
+ if (a.status !== 200)
2722
+ return void this.onError(a.statusText);
2618
2723
  const d = a.data;
2619
- if (!d.success) return void this.onError(d.message);
2724
+ if (!d.success)
2725
+ return void this.onError(d.message);
2620
2726
  let l = d.data.cdn, c = d.data.objectKey;
2621
2727
  r["Content-Type"] = t.type, o.put(d.data.presignedUrl, t).then((p) => {
2622
2728
  p.status === 200 && (p = { success: 1, file: { url: l + c } }), this.onUpload(p);
@@ -2625,10 +2731,10 @@ class fe {
2625
2731
  });
2626
2732
  }
2627
2733
  }
2628
- class Y {
2734
+ class G {
2629
2735
  constructor({ data: t, config: e, api: i, readOnly: s, block: n }) {
2630
2736
  var r;
2631
- this.isCaptionEnabled = null, this.api = i, this.block = n, this.userStore = e == null ? void 0 : e.userStore, this.config = { endpoints: e.endpoints, additionalRequestData: e.additionalRequestData, additionalRequestHeaders: e.additionalRequestHeaders, field: e.field, types: e.types, captionPlaceholder: this.api.i18n.t((r = e.captionPlaceholder) != null ? r : "Caption"), buttonContent: e.buttonContent, uploader: e.uploader, actions: e.actions, features: e.features || {}, userStore: e.userStore }, this.uploader = new fe({ config: this.config, onUpload: (o) => this.onUpload(o), onError: (o) => this.uploadingFailed(o) }), this.ui = new me({ api: i, config: this.config, onSelectFile: () => {
2737
+ this.isCaptionEnabled = null, this.api = i, this.block = n, this.userStore = e == null ? void 0 : e.userStore, this.config = { endpoints: e.endpoints, additionalRequestData: e.additionalRequestData, additionalRequestHeaders: e.additionalRequestHeaders, field: e.field, types: e.types, captionPlaceholder: this.api.i18n.t((r = e.captionPlaceholder) != null ? r : "Caption"), buttonContent: e.buttonContent, uploader: e.uploader, actions: e.actions, features: e.features || {}, userStore: e.userStore }, this.uploader = new ve({ config: this.config, onUpload: (o) => this.onUpload(o), onError: (o) => this.uploadingFailed(o) }), this.ui = new Ce({ api: i, config: this.config, onSelectFile: () => {
2632
2738
  this.uploader.uploadSelectedFile({ onPreview: (o) => {
2633
2739
  this.ui.showPreloader(o);
2634
2740
  }, noSelectedFile: () => {
@@ -2646,7 +2752,7 @@ class Y {
2646
2752
  return !0;
2647
2753
  }
2648
2754
  static get toolbox() {
2649
- return { icon: At, title: "Image" };
2755
+ return { icon: Bt, title: "Image" };
2650
2756
  }
2651
2757
  static get tunes() {
2652
2758
  return [{ name: "withBorder", icon: '<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" fill="none" viewBox="0 0 24 24"><path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M18.9919 9.5H19.0015"/><path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M14.5 5H14.5096"/><path stroke="currentColor" stroke-linecap="round" stroke-width="2" d="M14.625 5H15C17.2091 5 19 6.79086 19 9V9.375"/><path stroke="currentColor" stroke-width="2" d="M9.375 5L9 5C6.79086 5 5 6.79086 5 9V9.375"/><path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M9.3725 5H9.38207"/><path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M5 9.5H5.00957"/><path stroke="currentColor" stroke-width="2" d="M9.375 19H9C6.79086 19 5 17.2091 5 15V14.625"/><path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M9.3725 19H9.38207"/><path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M5 14.55H5.00957"/><path stroke="currentColor" stroke-linecap="round" stroke-width="2" d="M16 13V16M16 19V16M19 16H16M16 16H13"/></svg>', title: "With border", toggle: !0 }, { name: "stretched", icon: '<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" fill="none" viewBox="0 0 24 24"><path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M17 9L20 12L17 15"/><path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M14 12H20"/><path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M7 9L4 12L7 15"/><path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M4 12H10"/></svg>', title: "Stretch image", toggle: !0 }, { name: "withBackground", icon: '<svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" fill="none" viewBox="0 0 24 24"><path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M11 19V19C9.13623 19 8.20435 19 7.46927 18.6955C6.48915 18.2895 5.71046 17.5108 5.30448 16.5307C5 15.7956 5 14.8638 5 13V12C5 9.19108 5 7.78661 5.67412 6.77772C5.96596 6.34096 6.34096 5.96596 6.77772 5.67412C7.78661 5 9.19108 5 12 5H13.5C14.8956 5 15.5933 5 16.1611 5.17224C17.4395 5.56004 18.44 6.56046 18.8278 7.83886C19 8.40666 19 9.10444 19 10.5V10.5"/><path stroke="currentColor" stroke-linecap="round" stroke-width="2" d="M16 13V16M16 19V16M19 16H16M16 16H13"/><path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M6.5 17.5L17.5 6.5"/><path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M18.9919 10.5H19.0015"/><path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M10.9919 19H11.0015"/><path stroke="currentColor" stroke-linecap="round" stroke-linejoin="round" stroke-width="2" d="M5 13L13 5"/></svg>', title: "With background", toggle: !0 }];
@@ -2664,8 +2770,8 @@ class Y {
2664
2770
  }
2665
2771
  renderSettings() {
2666
2772
  var n;
2667
- const t = Y.tunes.concat(this.config.actions || []), e = { border: "withBorder", background: "withBackground", stretch: "stretched", caption: "caption" };
2668
- ((n = this.config.features) == null ? void 0 : n.caption) === "optional" && t.push({ name: "caption", icon: Ot, title: "With caption", toggle: !0 });
2773
+ const t = G.tunes.concat(this.config.actions || []), e = { border: "withBorder", background: "withBackground", stretch: "stretched", caption: "caption" };
2774
+ ((n = this.config.features) == null ? void 0 : n.caption) === "optional" && t.push({ name: "caption", icon: At, title: "With caption", toggle: !0 });
2669
2775
  const i = t.filter((r) => {
2670
2776
  var a, d;
2671
2777
  const o = Object.keys(e).find((l) => e[l] === r.name);
@@ -2676,7 +2782,8 @@ class Y {
2676
2782
  return r.name === "caption" && (o = (a = this.isCaptionEnabled) != null ? a : o), o;
2677
2783
  };
2678
2784
  return i.map((r) => ({ icon: r.icon, label: this.api.i18n.t(r.title), name: r.name, toggle: r.toggle, isActive: s(r), onActivate: () => {
2679
- if (typeof r.action == "function") return void r.action(r.name);
2785
+ if (typeof r.action == "function")
2786
+ return void r.action(r.name);
2680
2787
  let o = !s(r);
2681
2788
  r.name === "caption" && (this.isCaptionEnabled = !this.isCaptionEnabled, o = this.isCaptionEnabled), this.tuneToggled(r.name, o);
2682
2789
  } }));
@@ -2708,7 +2815,7 @@ class Y {
2708
2815
  }
2709
2816
  set data(t) {
2710
2817
  var e;
2711
- this.image = t.file, this._data.caption = t.caption || "", this.ui.fillCaption(this._data.caption), Y.tunes.forEach(({ name: i }) => {
2818
+ this.image = t.file, this._data.caption = t.caption || "", this.ui.fillCaption(this._data.caption), G.tunes.forEach(({ name: i }) => {
2712
2819
  const s = t[i] !== void 0 && (t[i] === !0 || t[i] === "true");
2713
2820
  this.setTune(i, s);
2714
2821
  }), (t.caption || ((e = this.config.features) == null ? void 0 : e.caption) === !0) && this.setTune("caption", !0);
@@ -2744,10 +2851,10 @@ class Y {
2744
2851
  this.ui.showPreloader(t), this.uploader.uploadByUrl(t);
2745
2852
  }
2746
2853
  }
2747
- class Ce {
2854
+ class ke {
2748
2855
  constructor({ api: t, data: e, config: i, block: s }) {
2749
- var n, r, o, a, d, l, c, p, u, g, m, f, v, L, w, _, B;
2750
- this.settings = [], this.api = t, this.block = s, this.data = { floatLeft: (n = e == null ? void 0 : e.floatLeft) != null ? n : !1, floatRight: (r = e == null ? void 0 : e.floatRight) != null ? r : !1, center: (o = e == null ? void 0 : e.center) != null ? o : !1, sizeSmall: (a = e == null ? void 0 : e.sizeSmall) != null ? a : !1, sizeMiddle: (d = e == null ? void 0 : e.sizeMiddle) != null ? d : !1, sizeLarge: (l = e == null ? void 0 : e.sizeLarge) != null ? l : !1, resize: (p = (c = e == null ? void 0 : e.resize) != null ? c : i == null ? void 0 : i.resize) != null ? p : !1, resizeSize: (u = e == null ? void 0 : e.resizeSize) != null ? u : 0, crop: (m = (g = e == null ? void 0 : e.crop) != null ? g : i == null ? void 0 : i.crop) != null ? m : !1, cropperFrameHeight: (f = e == null ? void 0 : e.cropperFrameHeight) != null ? f : 0, cropperFrameWidth: (v = e == null ? void 0 : e.cropperFrameWidth) != null ? v : 0, cropperFrameLeft: (L = e == null ? void 0 : e.cropperFrameLeft) != null ? L : 0, cropperFrameTop: (w = e == null ? void 0 : e.cropperFrameTop) != null ? w : 0, cropperImageHeight: (_ = e == null ? void 0 : e.cropperImageHeight) != null ? _ : 0, cropperImageWidth: (B = e == null ? void 0 : e.cropperImageWidth) != null ? B : 0, cropperInterface: void 0 }, this.wrapper = void 0, this.buttons = [], this.styles = { settingsButton: "cdx-settings-button", settingsButtonActive: "cdx-settings-button--active", settingsButtonModifier: "", settingsButtonModifierActive: "" };
2856
+ var n, r, o, a, d, l, c, p, u, g, m, f, v, S, w, _, B;
2857
+ this.settings = [], this.api = t, this.block = s, this.data = { floatLeft: (n = e == null ? void 0 : e.floatLeft) != null ? n : !1, floatRight: (r = e == null ? void 0 : e.floatRight) != null ? r : !1, center: (o = e == null ? void 0 : e.center) != null ? o : !1, sizeSmall: (a = e == null ? void 0 : e.sizeSmall) != null ? a : !1, sizeMiddle: (d = e == null ? void 0 : e.sizeMiddle) != null ? d : !1, sizeLarge: (l = e == null ? void 0 : e.sizeLarge) != null ? l : !1, resize: (p = (c = e == null ? void 0 : e.resize) != null ? c : i == null ? void 0 : i.resize) != null ? p : !1, resizeSize: (u = e == null ? void 0 : e.resizeSize) != null ? u : 0, crop: (m = (g = e == null ? void 0 : e.crop) != null ? g : i == null ? void 0 : i.crop) != null ? m : !1, cropperFrameHeight: (f = e == null ? void 0 : e.cropperFrameHeight) != null ? f : 0, cropperFrameWidth: (v = e == null ? void 0 : e.cropperFrameWidth) != null ? v : 0, cropperFrameLeft: (S = e == null ? void 0 : e.cropperFrameLeft) != null ? S : 0, cropperFrameTop: (w = e == null ? void 0 : e.cropperFrameTop) != null ? w : 0, cropperImageHeight: (_ = e == null ? void 0 : e.cropperImageHeight) != null ? _ : 0, cropperImageWidth: (B = e == null ? void 0 : e.cropperImageWidth) != null ? B : 0, cropperInterface: void 0 }, this.wrapper = void 0, this.buttons = [], this.styles = { settingsButton: "cdx-settings-button", settingsButtonActive: "cdx-settings-button--active", settingsButtonModifier: "", settingsButtonModifierActive: "" };
2751
2858
  }
2752
2859
  static get isTune() {
2753
2860
  return !0;
@@ -2807,14 +2914,16 @@ class Ce {
2807
2914
  this.data.floatLeft ? t.classList.add(this.CSS.isFloatLeft) : t.classList.remove(this.CSS.isFloatLeft), this.data.floatRight ? t.classList.add(this.CSS.isFloatRight) : t.classList.remove(this.CSS.isFloatRight), this.data.center ? t.classList.add(this.CSS.isCenter) : t.classList.remove(this.CSS.isCenter), this.data.sizeSmall ? t.classList.add(this.CSS.isSizeSmall) : t.classList.remove(this.CSS.isSizeSmall), this.data.sizeMiddle ? t.classList.add(this.CSS.isSizeMiddle) : t.classList.remove(this.CSS.isSizeMiddle), this.data.sizeLarge ? t.classList.add(this.CSS.isSizeLarge) : t.classList.remove(this.CSS.isSizeLarge), this.data.resize ? (t.classList.add(this.CSS.isResize), this.data.resizeSize > 0 && (t.getElementsByClassName("cdx-block")[0].style.width = this.data.resizeSize + "px"), this.resize(t)) : (t.classList.remove(this.CSS.isResize), this.unresize(t)), this.data.crop ? (t.classList.add(this.CSS.isCrop), this.crop(t), this.data.cropperFrameHeight > 0 && this.data.cropperFrameWidth > 0 && this.applyCrop(t)) : (t.classList.remove(this.CSS.isCrop), this.uncrop(t));
2808
2915
  }
2809
2916
  crop(t) {
2810
- if (this.api.readOnly.isEnabled) return;
2917
+ if (this.api.readOnly.isEnabled)
2918
+ return;
2811
2919
  const e = t.getElementsByClassName("image-tool__image")[0], i = document.createElement("div");
2812
2920
  i.classList.add("crop-btn", "btn-crop-action"), i.innerHTML = this.api.i18n.t("Crop"), i.addEventListener("click", () => {
2813
2921
  e.removeChild(i), this.appendCrop(t);
2814
2922
  }), e.appendChild(i);
2815
2923
  }
2816
2924
  appendCrop(t) {
2817
- if (this.api.readOnly.isEnabled) return;
2925
+ if (this.api.readOnly.isEnabled)
2926
+ return;
2818
2927
  this.uncrop(t);
2819
2928
  const e = t.getElementsByClassName("cdx-block")[0], i = e.getElementsByTagName("img")[0];
2820
2929
  e.classList.add("isCropping"), this.data.cropperInterface = new Cropper(i);
@@ -2836,7 +2945,8 @@ class Ce {
2836
2945
  const a = t.getElementsByClassName("btn-crop-action")[0];
2837
2946
  a && r.removeChild(a);
2838
2947
  }
2839
- if (this.data.cropperInterface && (this.data.cropperInterface.destroy(), this.data.cropperInterface = void 0), this.api.readOnly.isEnabled) return;
2948
+ if (this.data.cropperInterface && (this.data.cropperInterface.destroy(), this.data.cropperInterface = void 0), this.api.readOnly.isEnabled)
2949
+ return;
2840
2950
  const i = document.createElement("div");
2841
2951
  i.classList.add("crop-btn", "btn-crop-action"), i.innerHTML = this.api.i18n.t("Crop");
2842
2952
  const s = t.getElementsByClassName("image-tool__image")[0];
@@ -2845,7 +2955,8 @@ class Ce {
2845
2955
  }), s.appendChild(i)), t.classList.remove("isCropping"), this.block.dispatchChange();
2846
2956
  }
2847
2957
  uncrop(t) {
2848
- if (this.api.readOnly.isEnabled) return;
2958
+ if (this.api.readOnly.isEnabled)
2959
+ return;
2849
2960
  const e = t.getElementsByClassName("image-tool__image")[0], i = t.getElementsByClassName("btn-crop-action")[0];
2850
2961
  i && e && e.removeChild(i);
2851
2962
  const s = t.getElementsByClassName("btn-crop-action")[0];
@@ -2863,7 +2974,8 @@ class Ce {
2863
2974
  t.classList.remove("isCropping"), this.data.cropperInterface && (this.data.cropperInterface.destroy(), this.data.cropperInterface = void 0), this.data.cropperFrameHeight = 0, this.data.cropperFrameWidth = 0, this.data.cropperFrameLeft = 0, this.data.cropperFrameTop = 0, this.data.cropperImageHeight = 0, this.data.cropperImageWidth = 0;
2864
2975
  }
2865
2976
  resize(t) {
2866
- if (this.api.readOnly.isEnabled) return;
2977
+ if (this.api.readOnly.isEnabled)
2978
+ return;
2867
2979
  const e = document.createElement("div");
2868
2980
  e.classList.add("resizable");
2869
2981
  const i = document.createElement("div");
@@ -2948,7 +3060,7 @@ class Ce {
2948
3060
  this.setTune(t);
2949
3061
  }
2950
3062
  }
2951
- const ve = { class: "ebl-editor", id: "holder" }, ke = Nt({ name: "EblEditor", inheritAttrs: !1, __name: "Editor", props: { readOnly: { type: Boolean, default: !1 }, placeholder: { default: "Enter something" }, data: { default: () => ({ blocks: [] }) }, locale: { default: {} }, userStore: {} }, emits: ["onReady", "onChange"], setup(h, { expose: t, emit: e }) {
3063
+ const we = { class: "ebl-editor", id: "holder" }, be = Nt({ name: "EblEditor", inheritAttrs: !1, __name: "Editor", props: { readOnly: { type: Boolean, default: !1 }, placeholder: { default: "Enter something" }, data: { default: () => ({ blocks: [] }) }, locale: { default: {} }, userStore: {} }, emits: ["onReady", "onChange"], setup(h, { expose: t, emit: e }) {
2952
3064
  const i = zt("EblEditorSettings");
2953
3065
  let s = e;
2954
3066
  const n = h;
@@ -2956,7 +3068,7 @@ const ve = { class: "ebl-editor", id: "holder" }, ke = Nt({ name: "EblEditor", i
2956
3068
  const o = ["indent", "blockAlignment"];
2957
3069
  return Ft(() => {
2958
3070
  const a = Pt(n.data);
2959
- r = new Ut({ holder: "holder", autofocus: !0, defaultBlock: "paragraph", placeholder: n.placeholder, tunes: o, tools: { inlineCode: $, underline: nt, Color: { class: ce }, marker: { class: W }, indent: { class: st }, alert: { class: H, inlineToolbar: !0 }, List: { class: K, inlineToolbar: !0, config: { defaultStyle: "unordered" } }, h1: { class: Zt, inlineToolbar: !0 }, h2: { class: te, inlineToolbar: !0 }, h3: { class: ee, inlineToolbar: !0 }, h4: { class: ie, inlineToolbar: !0 }, h5: { class: se, inlineToolbar: !0 }, h6: { class: ne, inlineToolbar: !0 }, paragraph: { class: at, inlineToolbar: !0 }, blockAlignment: { class: ot, inlineToolbar: !0 }, code: { class: q, config: { lang: "javascript", theme: "github-dark-dimmed" } }, quote: { class: re, inlineToolbar: !0 }, delimiter: oe, table: { class: ge, inlineToolbar: !0, config: { rows: 2, cols: 3 } }, image: { class: Y, inlineToolbar: !0, tunes: o.concat(["imageResize"]), config: { types: ".png,.jpeg,.jpg,.gif,.webp", userStore: n.userStore, endpoints: { byFile: i == null ? void 0 : i.fileUploadEndpoint, byUrl: i == null ? void 0 : i.urlUploadEndpoint }, features: { caption: !1, stretch: !1, border: !1, background: !1 } } }, imageResize: { class: Ce, config: { resize: !0, crop: !1 } } }, data: a, readOnly: n.readOnly, i18n: n.locale, onChange: (d, l) => {
3071
+ r = new Ut({ minHeight: 100, holder: "holder", autofocus: !0, defaultBlock: "paragraph", placeholder: n.placeholder, tunes: o, tools: { inlineCode: W, underline: ue, Color: { class: pe }, marker: { class: P }, indent: { class: he }, alert: { class: H, inlineToolbar: !0 }, List: { class: Y, inlineToolbar: !0, config: { defaultStyle: "unordered" } }, h1: { class: Zt, inlineToolbar: !0 }, h2: { class: te, inlineToolbar: !0 }, h3: { class: ee, inlineToolbar: !0 }, h4: { class: ie, inlineToolbar: !0 }, h5: { class: se, inlineToolbar: !0 }, h6: { class: ne, inlineToolbar: !0 }, paragraph: { class: ot, inlineToolbar: !0 }, blockAlignment: { class: rt, inlineToolbar: !0 }, code: { class: j, config: { lang: "javascript", theme: "github-dark-dimmed" } }, quote: { class: re, inlineToolbar: !0 }, delimiter: oe, table: { class: fe, inlineToolbar: !0, config: { rows: 2, cols: 3 } }, image: { class: G, inlineToolbar: !0, tunes: o.concat(["imageResize"]), config: { types: ".png,.jpeg,.jpg,.gif,.webp", userStore: n.userStore, endpoints: { byFile: i == null ? void 0 : i.fileUploadEndpoint, byUrl: i == null ? void 0 : i.urlUploadEndpoint }, features: { caption: !1, stretch: !1, border: !1, background: !1 } } }, imageResize: { class: ke, config: { resize: !0, crop: !1 } } }, data: a, readOnly: n.readOnly, i18n: n.locale, onChange: (d, l) => {
2960
3072
  s("onChange", d, l);
2961
3073
  }, onReady: () => {
2962
3074
  new Qt("holder", n.readOnly, r, "1px solid #999"), new de({ editor: r, config: { debounceTimer: 200, maxLength: 100 }, onUpdate: () => {
@@ -2966,29 +3078,31 @@ const ve = { class: "ebl-editor", id: "holder" }, ke = Nt({ name: "EblEditor", i
2966
3078
  r !== null && (r.destroy(), r = null);
2967
3079
  }), t({ validate: function() {
2968
3080
  return new Promise((a, d) => {
2969
- if (r === null) return a(!1);
3081
+ if (r === null)
3082
+ return a(!1);
2970
3083
  r.save().then((l) => l.blocks.length > 0 ? a(!0) : a(!1));
2971
3084
  });
2972
3085
  }, getData: function() {
2973
3086
  return new Promise((a, d) => {
2974
- if (r === null) return a(null);
3087
+ if (r === null)
3088
+ return a(null);
2975
3089
  r.save().then((l) => a(l));
2976
3090
  });
2977
- } }), (a, d) => (qt(), $t("div", ve));
2978
- } }), _t = [ke];
3091
+ } }), (a, d) => ($t(), jt("div", we));
3092
+ } }), Mt = [be];
2979
3093
  let Rt = [];
2980
- for (let h in _t) {
2981
- const t = Xt(_t[h]);
3094
+ for (let h in Mt) {
3095
+ const t = Xt(Mt[h]);
2982
3096
  Rt.push(t);
2983
3097
  }
2984
- const Ee = { messages: { ui: { blockTunes: { toggler: { "Click to tune": "可拖拽和点击" } }, toolbar: { toolbox: { Add: "添加", Filter: "过滤", "Nothing found": "无内容" }, popover: { Filter: "过滤", "Nothing found": "无内容" } }, popover: { Filter: "筛选", "Nothing found": "未找到任何内容", "Convert to": "转化为" } }, toolNames: { Text: "段落", H1: "一级标题", H2: "二级标题", H3: "三级标题", H4: "四级标题", H5: "五级标题", H6: "六级标题", "Ordered List": "有序列表", "Unordered List": "无序列表", Checklist: "任务列表", Quote: "引用", Code: "代码块", Delimiter: "分割线", Link: "链接", Bold: "加粗", Italic: "倾斜", Alert: "高亮块", indent: "缩进", Marker: "突出显示", Color: "文本颜色", Underline: "下划线", InlineCode: "行内代码", Table: "表格", Image: "图片" }, tools: { image: { "Couldn’t upload image. Please try another.": "上传图片失败,请稍后重试。" }, table: { "Add row above": "在下面插入行", "Add row below": "在下面插入行", "Delete row": "删除行", "Add column to left": "在左边插入列", "Add column to right": "在右边插入列", "Delete column": "删除列", "With headings": "使用标题行", "Without headings": "不使用标题行" }, marker: { Marker: "突出显示" }, link: { "Add a link": "添加链接", Save: "保存", "Pasted link is not valid.": "链接地址无效" }, List: { Unordered: "无序", Ordered: "有序", Checklist: "任务列表", "Counter type": "计数器类型", Numeric: "阿拉伯数字", "Lower Roman": "小写罗马数字", "Upper Roman": "大写罗马数字", "Lower Alpha": "小写字母", "Upper Alpha": "大写字母", "Start with": "从" }, paragraph: { "Enter something": "请输入内容" }, stub: { "The block can not be displayed correctly.": "该模块不能放置在这里" }, code: { "Enter your code": "输入代码", Copied: "已复制" }, convertTo: { "Convert to": "转化为" }, alert: { "alert-primary": "主要样式", "alert-secondary": "次要样式", "alert-info": "信息", "alert-success": "成功", "alert-warning": "警告", "alert-danger": "危险", "alert-light": "浅色", "alert-dark": "深色", "align-left": "左对齐", "align-center": "居中", "align-right": "右对齐" } }, blockTunes: { delete: { Delete: "删除", "Click to delete": "点击删除" }, moveUp: { "Move up": "向上移" }, moveDown: { "Move down": "向下移" }, filter: { Filter: "过滤" }, blockAlignment: { "left align": "左对齐", "center align": "居中对齐", "right align": "右对齐", "justify align": "两端对齐" }, indent: { "Indent right": "向右缩进", "Indent left": "向左缩进" } } } }, Dt = /* @__PURE__ */ ((h = []) => ({ version: "2.31.9", install: (t, e) => {
2985
- t[dt] || (t[dt] = !0, h.forEach((i) => t.use(i)), t.provide("EblEditorSettings", e));
2986
- } }))(Rt), Me = Dt.install, _e = Dt.version;
3098
+ const _e = { messages: { ui: { blockTunes: { toggler: { "Click to tune": "可拖拽和点击" } }, toolbar: { toolbox: { Add: "添加", Filter: "过滤", "Nothing found": "无内容" }, popover: { Filter: "过滤", "Nothing found": "无内容" } }, popover: { Filter: "筛选", "Nothing found": "未找到任何内容", "Convert to": "转化为" } }, toolNames: { Text: "段落", H1: "一级标题", H2: "二级标题", H3: "三级标题", H4: "四级标题", H5: "五级标题", H6: "六级标题", "Ordered List": "有序列表", "Unordered List": "无序列表", Checklist: "任务列表", Quote: "引用", Code: "代码块", Delimiter: "分割线", Link: "链接", Bold: "加粗", Italic: "倾斜", Alert: "高亮块", indent: "缩进", Marker: "突出显示", Color: "文本颜色", Underline: "下划线", InlineCode: "行内代码", Table: "表格", Image: "图片" }, tools: { image: { "Couldn’t upload image. Please try another.": "上传图片失败,请稍后重试。" }, table: { "Add row above": "在下面插入行", "Add row below": "在下面插入行", "Delete row": "删除行", "Add column to left": "在左边插入列", "Add column to right": "在右边插入列", "Delete column": "删除列", "With headings": "使用标题行", "Without headings": "不使用标题行" }, marker: { Marker: "突出显示" }, link: { "Add a link": "添加链接", Save: "保存", "Pasted link is not valid.": "链接地址无效" }, List: { Unordered: "无序", Ordered: "有序", Checklist: "任务列表", "Counter type": "计数器类型", Numeric: "阿拉伯数字", "Lower Roman": "小写罗马数字", "Upper Roman": "大写罗马数字", "Lower Alpha": "小写字母", "Upper Alpha": "大写字母", "Start with": "从" }, paragraph: { "Enter something": "请输入内容" }, stub: { "The block can not be displayed correctly.": "该模块不能放置在这里" }, code: { "Enter your code": "输入代码", Copied: "已复制" }, convertTo: { "Convert to": "转化为" }, alert: { "alert-primary": "主要样式", "alert-secondary": "次要样式", "alert-info": "信息", "alert-success": "成功", "alert-warning": "警告", "alert-danger": "危险", "alert-light": "浅色", "alert-dark": "深色", "align-left": "左对齐", "align-center": "居中", "align-right": "右对齐" } }, blockTunes: { delete: { Delete: "删除", "Click to delete": "点击删除" }, moveUp: { "Move up": "向上移" }, moveDown: { "Move down": "向下移" }, filter: { Filter: "过滤" }, blockAlignment: { "left align": "左对齐", "center align": "居中对齐", "right align": "右对齐", "justify align": "两端对齐" }, indent: { "Indent right": "向右缩进", "Indent left": "向左缩进" } } } }, Dt = ((h = []) => ({ version: "2.31.11", install: (t, e) => {
3099
+ t[lt] || (t[lt] = !0, h.forEach((i) => t.use(i)), t.provide("EblEditorSettings", e));
3100
+ } }))(Rt), Ie = Dt.install, He = Dt.version;
2987
3101
  export {
2988
- ke as EblEditor,
3102
+ be as EblEditor,
2989
3103
  Dt as default,
2990
- Me as install,
2991
- _e as version,
2992
- Ee as zhCn
3104
+ Ie as install,
3105
+ He as version,
3106
+ _e as zhCn
2993
3107
  };
2994
3108
  //# sourceMappingURL=index.mjs.map