@ebl-vue/editor-full 2.31.53 → 2.31.54
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 +320 -308
- package/package.json +1 -1
package/dist/index.mjs
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
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;height:100%;overflow:auto;position:relative;padding-top:15px}.ebl-editor.outline{padding-right:280px}.ebl-editor.outline .codex-editor{-webkit-box-flex:1;-ms-flex:1;flex:1}@media (max-width:1240px){.ebl-outline{display:none}.ebl-editor.outline{padding-right:0}}@media (min-width:1240px){.ebl-editor.readonly .ce-block__content{max-width:100%;padding-left:100px;padding-right:100px}}.ce-toolbar,.ce-inline-toolbar{z-index:1000}.ce-toolbar__plus{border:1px solid #EFF0F1}.ce-toolbar .ce-popover__items,.ce-popover-clone .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,.ce-popover-clone .ce-popover__items .ce-popover-item{position:relative}.ce-toolbar .ce-popover__items .ce-popover-item__title,.ce-popover-clone .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],.ce-popover-clone .ce-popover-item-html,.ce-popover-clone .ce-popover-item-separator,.ce-popover-clone .ce-popover-item[data-item-name=convert-to]{width:100%}.ce-toolbar .ce-popover-item-html[data-item-name=list-setting],.ce-popover-clone .ce-popover-item-html[data-item-name=list-setting]{width:auto;overflow:hidden}.ce-toolbar .ce-popover-item-html[data-item-name=list-setting-start-with],.ce-popover-clone .ce-popover-item-html[data-item-name=list-setting-start-with]{border-radius:6px;padding:3px}.ce-toolbar .ce-popover-item-html[data-item-name=list-setting-start-with]:hover,.ce-popover-clone .ce-popover-item-html[data-item-name=list-setting-start-with]:hover{background-color:#f8f8f8}.ce-toolbar .ce-popover-item[data-item-name=convert-to] .ce-popover-item__title,.ce-popover-clone .ce-popover-item[data-item-name=convert-to] .ce-popover-item__title{display:block}.ce-toolbar .ce-popover-item[data-item-name=add-below],.ce-popover-clone .ce-popover-item[data-item-name=add-below]{width:100%}.ce-toolbar .ce-popover-item[data-item-name=add-below] .ce-popover-item__title,.ce-popover-clone .ce-popover-item[data-item-name=add-below] .ce-popover-item__title{display:block}.ce-toolbar .ce-popover-item[data-item-name=list-setting],.ce-popover-clone .ce-popover-item[data-item-name=list-setting]{width:100%}.ce-toolbar .ce-popover-item[data-item-name=list-setting] .ce-popover-item__title,.ce-popover-clone .ce-popover-item[data-item-name=list-setting] .ce-popover-item__title{display:block}.ce-popover--inline .ce-popover-item-html{padding:0 2px}.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}.ebl-editor ::-webkit-scrollbar{width:6px;height:6px}.ebl-editor ::-webkit-scrollbar-track{background:#f1f1f1;border-radius:1px}.ebl-editor ::-webkit-scrollbar-thumb{background:silver;border-radius:10px;border:1px solid #fff}.ebl-editor ::-webkit-scrollbar-thumb:hover{background:#555}.cdx-notifies{left:50%!important}.cdx-notifies{-webkit-transform:translateX(-50%);transform:translate(-50%);top:50%;-webkit-transform:translate(-50%,-50%);transform:translate(-50%,-50%)}.ebl-er-doc-outline-item{padding:7px 24px;cursor:pointer;white-space:normal;word-wrap:break-word}.ebl-er-doc-outline-item:hover{background-color:#f6f6f6}.ebl-er-doc-outline-item.selected{background-color:#ebebeb}.ebl-outline .level_1{padding-left:24px}.ebl-outline .level_2{padding-left:42px}.ebl-outline .level_3{padding-left:60px}.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)}.cel-inline-bold{font-weight:700}.cel-inline-strikethrough{-webkit-text-decoration:line-through;text-decoration:line-through}.cel-inline-italic{font-style:italic}.cel-inline-code{margin-left:2px;margin-right:2px;background-color:#f5f6f7;border:1px solid #dee0e3;border-color:#dee0e3;border-width:1px 0;border-radius:4px;padding:1px 5px 1px 4px}.cel-inline-underline{-webkit-text-decoration:underline;text-decoration:underline}.cel-inline-mark{background-color:#ff0;padding:2px}.cel-inline-link-input-wrap{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-orient:horizontal;-webkit-box-direction:normal;-ms-flex-direction:row;flex-direction:row;gap:5px}.cel-inline-link-input{-webkit-box-flex:1;-ms-flex:1;flex:1;background:#f8f8f8;border:1px solid rgba(226,226,229,.2);border-radius:6px;padding:4px 8px;font-size:14px;line-height:22px;outline:none;margin:0;width:100%;-webkit-box-sizing:border-box;box-sizing:border-box;font-weight:500;font-family:inherit}.cel-inline-link-input-btn{width:50px;border-radius:5px;background-color:#161c27;color:#fff;border:none;cursor:pointer}.cel-inline-link-input-btn.disabled{opacity:.4;cursor:not-allowed}.cel-fake-background{background-color:#a8d6ff}.editorjs__color-selector__input{width:1px;height:1px;opacity:0}.editorjs__color-selector__container-item-none{background-color:transparent;border:1px solid #e6e6e6;position:relative}.editorjs__color-selector__container-item-none:before{content:"";position:absolute;top:50%;left:50%;width:1px;height:35px;background-color:#e6e6e6;-webkit-transform:translate(-50%,-50%) rotate(45deg);transform:translate(-50%,-50%) rotate(45deg)}.cel-inline-gray-text{color:#646a73}.cel-inline-pink-text{color:#d83931}.cel-inline-orange-text{color:#de7802}.cel-inline-yellow-text{color:#dc9b04}.cel-inline-green-text{color:#2ea121}.cel-inline-blue-text{color:#245bdb}.cel-inline-purple-text{color:#6425d0}.ebl-er-doc{font-family:var(--font-family);font-size:16px;font-weight:400;-webkit-box-sizing:border-box;box-sizing:border-box}.ebl-er-header{height:var(--ebl-er-header-height);-webkit-box-sizing:border-box;box-sizing:border-box;position:sticky;top:0;z-index:10}.ebl-er-footer{height:var(--ebl-er-footer-height);-webkit-box-sizing:border-box;box-sizing:border-box}.ebl-er-container{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-orient:horizontal;-webkit-box-direction:normal;-ms-flex-direction:row;flex-direction:row;min-height:calc(100vh - var(--ebl-er-header-height))}.ebl-er-doc-menu{width:var(--ebl-er-doc-menu-width);-webkit-box-sizing:border-box;box-sizing:border-box;-ms-flex-negative:0;flex-shrink:0;height:calc(100vh - var(--ebl-er-header-height));position:sticky;top:var(--ebl-er-header-height)}.ebl-er-doc-menu-content{-webkit-box-sizing:border-box;box-sizing:border-box}.ebl-er-doc-content{-webkit-box-sizing:border-box;box-sizing:border-box;display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-orient:horizontal;-webkit-box-direction:normal;-ms-flex-direction:row;flex-direction:row;max-width:calc(100% - var(--ebl-er-doc-menu-width));-webkit-box-flex:1;-ms-flex-positive:1;flex-grow:1}.ebl-er-doc-content-container{-webkit-box-sizing:border-box;box-sizing:border-box;-webkit-box-flex:1;-ms-flex:1;flex:1;padding:0 50px 50px;width:100%;overflow-x:hidden;white-space:normal;word-wrap:break-word}.ebl-er-doc-content-inner-wrap{margin:0 auto}.ebl-er-doc-content-inner .ce-block{width:100%}.ebl-er-doc-outline{width:280px;-webkit-box-sizing:border-box;box-sizing:border-box;height:calc(100vh - var(--ebl-er-header-height));position:sticky;top:var(--ebl-er-header-height);overflow:auto;padding:12px}.ebl-er-doc-pre-next{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-pack:justify;-ms-flex-pack:justify;justify-content:space-between;-webkit-box-align:center;-ms-flex-align:center;align-items:center;padding:33px 0}@media (max-width:960px){.ebl-er-doc-outline{display:none}}.ebl-er-doc ::-webkit-scrollbar{width:6px;height:6px}.ebl-er-doc ::-webkit-scrollbar-track{background:#f1f1f1;border-radius:1px}.ebl-er-doc ::-webkit-scrollbar-thumb{background:silver;border-radius:10px;border:1px solid #fff}.ebl-er-doc ::-webkit-scrollbar-thumb:hover{background:#555}.ce-el-link-wrapper{position:absolute;z-index:1000;width:auto;max-width:300px;height:46px;padding:6px 20px;border:1px solid #eff0f1;border-radius:6px;background-color:#fff;display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-orient:horizontal;-webkit-box-direction:normal;-ms-flex-direction:row;flex-direction:row}.ce-el-link-input{border:1px solid rgba(226,226,229,.2);border-radius:6px;padding:4px 8px;background-color:#f8f8f8;font-size:12px;line-height:22px;margin:0;-webkit-box-flex:1;-ms-flex:1;flex:1;width:260px}.ce-el-link-input.ce-el-link__noedit{display:none}.ce-el-link-btn-wrap{width:50px;display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-orient:horizontal;-webkit-box-direction:normal;-ms-flex-direction:row;flex-direction:row}.ce-el-link-btn{width:50px;background-color:#161c27;color:#fff;border-radius:6px;margin-left:5px;display:block}.ce-el-link-btn.ce-el-link__noedit{display:none}.ce-el-link-icon-btn{width:24px;-webkit-box-align:center;-ms-flex-align:center;align-items:center;-webkit-box-pack:center;-ms-flex-pack:center;justify-content:center;margin-left:5px;cursor:pointer;display:none}.ce-el-link-icon-btn.ce-el-link__noedit{display:-webkit-box;display:-ms-flexbox;display:flex}.ce-el-link-input-text{padding-right:20px;display:none}.ce-el-link-input-text.ce-el-link__noedit{display:block}.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:15px 0 3px;margin:0;line-height:1.25;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:2!important}.ce-paragraph{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;border:2px solid transparent;position:relative}.ce-editorjs-x-shiki.editable:hover{border:2px solid #C0C0C0}.ce-editorjs-x-shiki__lang{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-pack:justify;-ms-flex-pack:justify;justify-content:space-between;padding:8px}.ce-editorjs-x-shiki__code{position:relative;float:left;min-width:100%;overflow:hidden;height:auto;min-height:60px}.ce-editorjs-x-shiki__code__dragHandler{position:absolute;left:50%;-webkit-transform:translateX(-50%);transform:translate(-50%);bottom:-5px;cursor:ns-resize;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;height:8px;width:60px;background-color:silver;border-radius:5px;display:none}.ce-editorjs-x-shiki:hover .ce-editorjs-x-shiki__code__dragHandler{display:block}.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;border-bottom-style:solid;border-color:#9ca3af0d;border-bottom-width:1px;padding:0 8px 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__span code{font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,monospace}.ce-editorjs-x-shiki__textarea{all:unset;white-space:pre;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__textarea::-moz-selection{background-color:#083ca9;color:#fff}.ce-editorjs-x-shiki__textarea::selection{background-color:#083ca9;color:#fff}.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}.ce-editorjs-x-shiki__code ::-webkit-scrollbar{width:8px;height:8px}.ce-editorjs-x-shiki__code ::-webkit-scrollbar-track{background:#22272e;border-radius:1px}.ce-editorjs-x-shiki__code ::-webkit-scrollbar-thumb{background:silver;border-radius:10px;border:2px solid #22272e}.ce-editorjs-x-shiki__code ::-webkit-scrollbar-thumb:hover{background:#555}.ce-block--selected .ce-editorjs-x-shiki{outline:2px solid #4299e1}.ce-block--selected .ce-editorjs-x-shiki,.ce-block--selected .ce-editorjs-x-shiki__selector-language,.ce-block--selected .ce-editorjs-x-shiki__span{background-color:#e1f2ff!important}.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}.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{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-orient:horizontal;-webkit-box-direction:normal;-ms-flex-direction:row;flex-direction:row;overflow:hidden;-webkit-box-align:center;-ms-flex-align:center;align-items:center}.cdx-list-start-with-field--invalid{background:#ffeced;border:1px solid #E13F3F}.cdx-list-start-with-field:hover{background-color:#f8f8f8}.cdx-list-start-with-field--invalid .cdx-list-start-with-field__input{color:#e13f3f}.cdx-list-start-with-field__startlabel{width:70px;font-size:14px}.cdx-list-start-with-field__input-wrapper{-webkit-box-flex:1;-ms-flex:1;flex:1;overflow:hidden}.cdx-list-start-with-field__input{font-size:14px;outline:none;font-weight:500;font-family:inherit;border:0;background:transparent;margin:0;line-height:22px;-webkit-box-flex:1;-ms-flex:1;flex:1;border:1px solid rgba(226,226,229,1);border-radius:6px;padding:0 10px;width:50px;text-align:center}.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;margin-top: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-block--selected .cdx-alert{outline:2px solid #4299e1}.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}.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:150px;height:150px;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{width:100%}.image-tool--uploading .resizable{display:none!important}.image-tool--uploading .image-tool__image{min-height:200px;display:-webkit-box;display:-ms-flexbox;display:flex;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{-webkit-box-sizing:border-box;box-sizing:border-box;width:14px;height:14px;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
2
|
import { defineComponent as xn, inject as Rn, onMounted as Nn, toRaw as Mt, onUnmounted as An, watch as _n, createElementBlock as Mn, openBlock as On } from "vue";
|
|
3
3
|
import In from "@ebl-vue/editorjs";
|
|
4
|
-
import { isCaretAtStartOfInput as
|
|
4
|
+
import { isCaretAtStartOfInput as wn, focus as Hn, getCaretNodeAndOffset as Bn } from "@editorjs/caret";
|
|
5
5
|
import { bundledLanguagesInfo as Dn, codeToHtml as Pn } from "shiki";
|
|
6
6
|
import * as Tt from "@editorjs/dom";
|
|
7
7
|
import { make as Re, isEmpty as $t } from "@editorjs/dom";
|
|
@@ -39,11 +39,11 @@ function Wn() {
|
|
|
39
39
|
} : function(p, x) {
|
|
40
40
|
for (var L = 0, F = p.length; L < F; ++L) x(p[L], L);
|
|
41
41
|
} }, q = { version: "1.3.2", initialized: !1, isBrowser: de, supported: !0, util: fe, features: {}, modules: ie, config: { alertOnFail: !1, alertOnWarn: !1, preferTextRange: !1, autoInitialize: typeof rangyAutoInitialize == e || rangyAutoInitialize } };
|
|
42
|
-
function
|
|
42
|
+
function we(p) {
|
|
43
43
|
typeof console != e && c(console, "log");
|
|
44
44
|
}
|
|
45
45
|
function $e(p, x) {
|
|
46
|
-
de && x ? alert(p) :
|
|
46
|
+
de && x ? alert(p) : we();
|
|
47
47
|
}
|
|
48
48
|
function Ae(p) {
|
|
49
49
|
q.initialized = !0, q.supported = !1, $e("Rangy is not supported in this environment. Reason: " + p, q.config.alertOnFail);
|
|
@@ -94,7 +94,7 @@ function Wn() {
|
|
|
94
94
|
for (var K = 0, ue = Be.length; K < ue; ++K) try {
|
|
95
95
|
Be[K](q);
|
|
96
96
|
} catch (r) {
|
|
97
|
-
"" + Ye(r),
|
|
97
|
+
"" + Ye(r), we();
|
|
98
98
|
}
|
|
99
99
|
} else Ae("Neither Range nor TextRange are available");
|
|
100
100
|
else Ae("No body element found");
|
|
@@ -122,7 +122,7 @@ function Wn() {
|
|
|
122
122
|
try {
|
|
123
123
|
L(q, J), J.supported = !0;
|
|
124
124
|
} catch (ee) {
|
|
125
|
-
Ye(ee),
|
|
125
|
+
Ye(ee), we(), ee.stack && we(ee.stack);
|
|
126
126
|
}
|
|
127
127
|
}
|
|
128
128
|
});
|
|
@@ -185,7 +185,7 @@ function Wn() {
|
|
|
185
185
|
}
|
|
186
186
|
return !1;
|
|
187
187
|
}
|
|
188
|
-
function
|
|
188
|
+
function w(d, S, D) {
|
|
189
189
|
for (var $, ne = D ? d : d.parentNode; ne; ) {
|
|
190
190
|
if (($ = ne.parentNode) === S) return ne;
|
|
191
191
|
ne = $;
|
|
@@ -296,7 +296,7 @@ function Wn() {
|
|
|
296
296
|
}
|
|
297
297
|
}, getCommonAncestor: h, isAncestorOf: u, isOrIsAncestorOf: function(d, S) {
|
|
298
298
|
return u(d, S, !0);
|
|
299
|
-
}, getClosestAncestorIn:
|
|
299
|
+
}, getClosestAncestorIn: w, isCharacterDataNode: T, isTextOrCommentNode: function(d) {
|
|
300
300
|
if (!d) return !1;
|
|
301
301
|
var S = d.nodeType;
|
|
302
302
|
return S == 3 || S == 8;
|
|
@@ -316,16 +316,16 @@ function Wn() {
|
|
|
316
316
|
for (var S; S = d.parentNode; ) d = S;
|
|
317
317
|
return d;
|
|
318
318
|
}, comparePoints: function(d, S, D, $) {
|
|
319
|
-
var ne, ge, Me, Ce,
|
|
319
|
+
var ne, ge, Me, Ce, ye;
|
|
320
320
|
if (d == D) return S === $ ? 0 : S < $ ? -1 : 1;
|
|
321
|
-
if (ne =
|
|
322
|
-
if (ne =
|
|
321
|
+
if (ne = w(D, d, !0)) return S <= r(ne) ? -1 : 1;
|
|
322
|
+
if (ne = w(d, D, !0)) return r(ne) < $ ? -1 : 1;
|
|
323
323
|
if (!(ge = h(d, D))) throw new Error("comparePoints error: nodes have no common ancestor");
|
|
324
|
-
if ((Me = d === ge ? ge :
|
|
325
|
-
for (
|
|
326
|
-
if (
|
|
327
|
-
if (
|
|
328
|
-
|
|
324
|
+
if ((Me = d === ge ? ge : w(d, ge, !0)) === (Ce = D === ge ? ge : w(D, ge, !0))) throw x.createError("comparePoints got to case 4 and childA and childB are the same!");
|
|
325
|
+
for (ye = ge.firstChild; ye; ) {
|
|
326
|
+
if (ye === Me) return -1;
|
|
327
|
+
if (ye === Ce) return 1;
|
|
328
|
+
ye = ye.nextSibling;
|
|
329
329
|
}
|
|
330
330
|
}, isBrokenNode: Y, inspectNode: Z, getComputedStyleProperty: I, createTestElement: function(d, S, D) {
|
|
331
331
|
var $ = J(d), ne = d.createElement("div");
|
|
@@ -341,7 +341,7 @@ function Wn() {
|
|
|
341
341
|
return new ce(d);
|
|
342
342
|
}, DomPosition: te }, p.DOMException = he;
|
|
343
343
|
}), q.createCoreModule("DomRange", ["DomUtil"], function(p, x) {
|
|
344
|
-
var L = p.dom, F = p.util, J = L.DomPosition, ee = p.DOMException, K = L.isCharacterDataNode, ue = L.getNodeIndex, r = L.isOrIsAncestorOf, h = L.getDocument, u = L.comparePoints,
|
|
344
|
+
var L = p.dom, F = p.util, J = L.DomPosition, ee = p.DOMException, K = L.isCharacterDataNode, ue = L.getNodeIndex, r = L.isOrIsAncestorOf, h = L.getDocument, u = L.comparePoints, w = L.splitDataNode, T = L.getClosestAncestorIn, O = L.getNodeLength, z = L.arrayContains, v = L.getRootContainer, P = p.features.crashyTextNodes, W = L.removeNode;
|
|
345
345
|
function I(o, f) {
|
|
346
346
|
return o.nodeType != 3 && (r(o, f.startContainer) || r(o, f.endContainer));
|
|
347
347
|
}
|
|
@@ -356,7 +356,7 @@ function Wn() {
|
|
|
356
356
|
}
|
|
357
357
|
function ce(o, f, i) {
|
|
358
358
|
var l = o.nodeType == 11 ? o.firstChild : o;
|
|
359
|
-
return K(f) ? i == f.length ? L.insertAfter(o, f) : f.parentNode.insertBefore(o, i == 0 ? f :
|
|
359
|
+
return K(f) ? i == f.length ? L.insertAfter(o, f) : f.parentNode.insertBefore(o, i == 0 ? f : w(f, i)) : i >= f.childNodes.length ? f.appendChild(o) : f.insertBefore(o, f.childNodes[i]), l;
|
|
360
360
|
}
|
|
361
361
|
function te(o, f, i) {
|
|
362
362
|
if (pe(o), pe(f), U(f) != U(o)) throw new ee("WRONG_DOCUMENT_ERR");
|
|
@@ -371,10 +371,10 @@ function Wn() {
|
|
|
371
371
|
return m;
|
|
372
372
|
}
|
|
373
373
|
function d(o, f, i) {
|
|
374
|
-
var l, m, k,
|
|
374
|
+
var l, m, k, y;
|
|
375
375
|
for (i = i || { stop: !1 }; k = o.next(); ) if (o.isPartiallySelectedSubtree()) {
|
|
376
376
|
if (f(k) === !1) return void (i.stop = !0);
|
|
377
|
-
if (d(
|
|
377
|
+
if (d(y = o.getSubtreeIterator(), f, i), y.detach(), i.stop) return;
|
|
378
378
|
} else for (l = L.createIterator(k); m = l.next(); ) if (f(m) === !1) return void (i.stop = !0);
|
|
379
379
|
}
|
|
380
380
|
function S(o) {
|
|
@@ -421,7 +421,7 @@ function Wn() {
|
|
|
421
421
|
}, detach: function() {
|
|
422
422
|
this.range = this._current = this._next = this._first = this._last = this.sc = this.so = this.ec = this.eo = null;
|
|
423
423
|
} };
|
|
424
|
-
var ge = [1, 3, 4, 5, 7, 8, 10], Me = [2, 9, 11], Ce = [1, 3, 4, 5, 7, 8, 10, 11],
|
|
424
|
+
var ge = [1, 3, 4, 5, 7, 8, 10], Me = [2, 9, 11], Ce = [1, 3, 4, 5, 7, 8, 10, 11], ye = [1, 3, 4, 5, 7, 8];
|
|
425
425
|
function Ne(o) {
|
|
426
426
|
return function(f, i) {
|
|
427
427
|
for (var l, m = i ? f : f.parentNode; m; ) {
|
|
@@ -431,7 +431,7 @@ function Wn() {
|
|
|
431
431
|
return null;
|
|
432
432
|
};
|
|
433
433
|
}
|
|
434
|
-
var Ie = Ne([9, 11]), Xe = Ne([5, 6, 10, 12]), Pe = Ne([6, 10, 12]),
|
|
434
|
+
var Ie = Ne([9, 11]), Xe = Ne([5, 6, 10, 12]), Pe = Ne([6, 10, 12]), nt = Ne([1]);
|
|
435
435
|
function be(o, f) {
|
|
436
436
|
if (Pe(o, f)) throw new ee("INVALID_NODE_TYPE_ERR");
|
|
437
437
|
}
|
|
@@ -441,7 +441,7 @@ function Wn() {
|
|
|
441
441
|
function je(o, f) {
|
|
442
442
|
if (f < 0 || f > (K(o) ? o.length : o.childNodes.length)) throw new ee("INDEX_SIZE_ERR");
|
|
443
443
|
}
|
|
444
|
-
function
|
|
444
|
+
function it(o, f) {
|
|
445
445
|
if (Ie(o, !0) !== Ie(f, !0)) throw new ee("WRONG_DOCUMENT_ERR");
|
|
446
446
|
}
|
|
447
447
|
function ze(o) {
|
|
@@ -476,83 +476,83 @@ function Wn() {
|
|
|
476
476
|
};
|
|
477
477
|
function dt(o, f) {
|
|
478
478
|
pe(o);
|
|
479
|
-
var i = o.startContainer, l = o.startOffset, m = o.endContainer, k = o.endOffset,
|
|
480
|
-
K(m) && k > 0 && k < m.length &&
|
|
479
|
+
var i = o.startContainer, l = o.startOffset, m = o.endContainer, k = o.endOffset, y = i === m;
|
|
480
|
+
K(m) && k > 0 && k < m.length && w(m, k, f), K(i) && l > 0 && l < i.length && (i = w(i, l, f), y ? (k -= l, m = i) : m == i.parentNode && k >= ue(i) && k++, l = 0), o.setStartAndEnd(i, l, m, k);
|
|
481
481
|
}
|
|
482
|
-
function
|
|
482
|
+
function st(o) {
|
|
483
483
|
pe(o);
|
|
484
484
|
var f = o.commonAncestorContainer.parentNode.cloneNode(!1);
|
|
485
485
|
return f.appendChild(o.cloneContents()), f.innerHTML;
|
|
486
486
|
}
|
|
487
487
|
var se = ["startContainer", "startOffset", "endContainer", "endOffset", "collapsed", "commonAncestorContainer"];
|
|
488
|
-
function
|
|
488
|
+
function yt(o) {
|
|
489
489
|
o.START_TO_START = 0, o.START_TO_END = 1, o.END_TO_END = 2, o.END_TO_START = 3, o.NODE_BEFORE = 0, o.NODE_AFTER = 1, o.NODE_BEFORE_AND_AFTER = 2, o.NODE_INSIDE = 3;
|
|
490
490
|
}
|
|
491
|
-
function
|
|
492
|
-
|
|
491
|
+
function wt(o) {
|
|
492
|
+
yt(o), yt(o.prototype);
|
|
493
493
|
}
|
|
494
494
|
function Qe(o, f) {
|
|
495
495
|
return function() {
|
|
496
496
|
pe(this);
|
|
497
|
-
var i, l = this.startContainer, m = this.startOffset, k = this.commonAncestorContainer,
|
|
498
|
-
l !== k && (l = (i = Z(T(l, k, !0))).node, m = i.offset), d(
|
|
499
|
-
var N = o(
|
|
500
|
-
return
|
|
497
|
+
var i, l = this.startContainer, m = this.startOffset, k = this.commonAncestorContainer, y = new ne(this, !0);
|
|
498
|
+
l !== k && (l = (i = Z(T(l, k, !0))).node, m = i.offset), d(y, ze), y.reset();
|
|
499
|
+
var N = o(y);
|
|
500
|
+
return y.detach(), f(this, l, m, l, m), N;
|
|
501
501
|
};
|
|
502
502
|
}
|
|
503
503
|
function kt(o, f) {
|
|
504
|
-
function i(
|
|
504
|
+
function i(y, N) {
|
|
505
505
|
return function(X) {
|
|
506
506
|
Ee(X, ge), Ee(v(X), Me);
|
|
507
|
-
var j = (
|
|
507
|
+
var j = (y ? Y : Z)(X);
|
|
508
508
|
(N ? l : m)(this, j.node, j.offset);
|
|
509
509
|
};
|
|
510
510
|
}
|
|
511
|
-
function l(
|
|
512
|
-
var j =
|
|
513
|
-
N ===
|
|
511
|
+
function l(y, N, X) {
|
|
512
|
+
var j = y.endContainer, oe = y.endOffset;
|
|
513
|
+
N === y.startContainer && X === y.startOffset || (v(N) == v(j) && u(N, X, j, oe) != 1 || (j = N, oe = X), f(y, N, X, j, oe));
|
|
514
514
|
}
|
|
515
|
-
function m(
|
|
516
|
-
var j =
|
|
517
|
-
N ===
|
|
515
|
+
function m(y, N, X) {
|
|
516
|
+
var j = y.startContainer, oe = y.startOffset;
|
|
517
|
+
N === y.endContainer && X === y.endOffset || (v(N) == v(j) && u(N, X, j, oe) != -1 || (j = N, oe = X), f(y, j, oe, N, X));
|
|
518
518
|
}
|
|
519
519
|
var k = function() {
|
|
520
520
|
};
|
|
521
|
-
k.prototype = p.rangePrototype, o.prototype = new k(), F.extend(o.prototype, { setStart: function(
|
|
522
|
-
be(
|
|
523
|
-
}, setEnd: function(
|
|
524
|
-
be(
|
|
521
|
+
k.prototype = p.rangePrototype, o.prototype = new k(), F.extend(o.prototype, { setStart: function(y, N) {
|
|
522
|
+
be(y, !0), je(y, N), l(this, y, N);
|
|
523
|
+
}, setEnd: function(y, N) {
|
|
524
|
+
be(y, !0), je(y, N), m(this, y, N);
|
|
525
525
|
}, setStartAndEnd: function() {
|
|
526
|
-
var
|
|
527
|
-
switch (
|
|
526
|
+
var y = arguments, N = y[0], X = y[1], j = N, oe = X;
|
|
527
|
+
switch (y.length) {
|
|
528
528
|
case 3:
|
|
529
|
-
oe =
|
|
529
|
+
oe = y[2];
|
|
530
530
|
break;
|
|
531
531
|
case 4:
|
|
532
|
-
j =
|
|
532
|
+
j = y[2], oe = y[3];
|
|
533
533
|
}
|
|
534
534
|
be(N, !0), je(N, X), be(j, !0), je(j, oe), f(this, N, X, j, oe);
|
|
535
|
-
}, setBoundary: function(
|
|
536
|
-
this["set" + (X ? "Start" : "End")](
|
|
537
|
-
}, setStartBefore: i(!0, !0), setStartAfter: i(!1, !0), setEndBefore: i(!0, !1), setEndAfter: i(!1, !1), collapse: function(
|
|
538
|
-
pe(this),
|
|
539
|
-
}, selectNodeContents: function(
|
|
540
|
-
be(
|
|
541
|
-
}, selectNode: function(
|
|
542
|
-
be(
|
|
543
|
-
var N = Y(
|
|
535
|
+
}, setBoundary: function(y, N, X) {
|
|
536
|
+
this["set" + (X ? "Start" : "End")](y, N);
|
|
537
|
+
}, setStartBefore: i(!0, !0), setStartAfter: i(!1, !0), setEndBefore: i(!0, !1), setEndAfter: i(!1, !1), collapse: function(y) {
|
|
538
|
+
pe(this), y ? f(this, this.startContainer, this.startOffset, this.startContainer, this.startOffset) : f(this, this.endContainer, this.endOffset, this.endContainer, this.endOffset);
|
|
539
|
+
}, selectNodeContents: function(y) {
|
|
540
|
+
be(y, !0), f(this, y, 0, y, O(y));
|
|
541
|
+
}, selectNode: function(y) {
|
|
542
|
+
be(y, !1), Ee(y, ge);
|
|
543
|
+
var N = Y(y), X = Z(y);
|
|
544
544
|
f(this, N.node, N.offset, X.node, X.offset);
|
|
545
545
|
}, extractContents: Qe(D, f), deleteContents: Qe(S, f), canSurroundContents: function() {
|
|
546
546
|
pe(this), ze(this.startContainer), ze(this.endContainer);
|
|
547
|
-
var
|
|
548
|
-
return
|
|
547
|
+
var y = new ne(this, !0), N = y._first && I(y._first, this) || y._last && I(y._last, this);
|
|
548
|
+
return y.detach(), !N;
|
|
549
549
|
}, splitBoundaries: function() {
|
|
550
550
|
dt(this);
|
|
551
|
-
}, splitBoundariesPreservingPositions: function(
|
|
552
|
-
dt(this,
|
|
551
|
+
}, splitBoundariesPreservingPositions: function(y) {
|
|
552
|
+
dt(this, y);
|
|
553
553
|
}, normalizeBoundaries: function() {
|
|
554
554
|
pe(this);
|
|
555
|
-
var
|
|
555
|
+
var y, N = this.startContainer, X = this.startOffset, j = this.endContainer, oe = this.endOffset, Je = function(Le) {
|
|
556
556
|
var We = Le.nextSibling;
|
|
557
557
|
We && We.nodeType == Le.nodeType && (j = Le, oe = Le.length, Le.appendData(We.data), W(We));
|
|
558
558
|
}, ht = function(Le) {
|
|
@@ -567,7 +567,7 @@ function Wn() {
|
|
|
567
567
|
}
|
|
568
568
|
}
|
|
569
569
|
}, Nt = !0;
|
|
570
|
-
if (K(j)) oe == j.length ? Je(j) : oe == 0 && (
|
|
570
|
+
if (K(j)) oe == j.length ? Je(j) : oe == 0 && (y = j.previousSibling) && y.nodeType == j.nodeType && (oe = y.length, N == j && (Nt = !1), y.appendData(j.data), W(j), j = y);
|
|
571
571
|
else {
|
|
572
572
|
if (oe > 0) {
|
|
573
573
|
var At = j.childNodes[oe - 1];
|
|
@@ -576,18 +576,18 @@ function Wn() {
|
|
|
576
576
|
Nt = !this.collapsed;
|
|
577
577
|
}
|
|
578
578
|
if (Nt) {
|
|
579
|
-
if (K(N)) X == 0 ? ht(N) : X == N.length && (
|
|
579
|
+
if (K(N)) X == 0 ? ht(N) : X == N.length && (y = N.nextSibling) && y.nodeType == N.nodeType && (j == y && (j = N, oe += N.length), N.appendData(y.data), W(y));
|
|
580
580
|
else if (X < N.childNodes.length) {
|
|
581
581
|
var _t = N.childNodes[X];
|
|
582
582
|
_t && K(_t) && ht(_t);
|
|
583
583
|
}
|
|
584
584
|
} else N = j, X = oe;
|
|
585
585
|
f(this, N, X, j, oe);
|
|
586
|
-
}, collapseToPoint: function(
|
|
587
|
-
be(
|
|
586
|
+
}, collapseToPoint: function(y, N) {
|
|
587
|
+
be(y, !0), je(y, N), this.setStartAndEnd(y, N);
|
|
588
588
|
}, parentElement: function() {
|
|
589
|
-
return pe(this), this.commonAncestorContainer ?
|
|
590
|
-
} }),
|
|
589
|
+
return pe(this), this.commonAncestorContainer ? nt(this.commonAncestorContainer, !0) : null;
|
|
590
|
+
} }), wt(o);
|
|
591
591
|
}
|
|
592
592
|
function Ze(o, f, i, l, m) {
|
|
593
593
|
o.startContainer = f, o.startOffset = i, o.endContainer = l, o.endOffset = m, o.document = L.getDocument(f), function(k) {
|
|
@@ -599,9 +599,9 @@ function Wn() {
|
|
|
599
599
|
}
|
|
600
600
|
F.extend(p.rangePrototype, { compareBoundaryPoints: function(o, f) {
|
|
601
601
|
var i, l, m, k;
|
|
602
|
-
pe(this),
|
|
603
|
-
var
|
|
604
|
-
return i = this[
|
|
602
|
+
pe(this), it(this.startContainer, f.startContainer);
|
|
603
|
+
var y = o == 3 || o == 0 ? "start" : "end", N = o == 1 || o == 0 ? "start" : "end";
|
|
604
|
+
return i = this[y + "Container"], l = this[y + "Offset"], m = f[N + "Container"], k = f[N + "Offset"], u(i, l, m, k);
|
|
605
605
|
}, insertNode: function(o) {
|
|
606
606
|
if (pe(this), Ee(o, Ce), ze(this.startContainer), r(o, this.startContainer)) throw new ee("HIERARCHY_REQUEST_ERR");
|
|
607
607
|
var f = ce(o, this.startContainer, this.startOffset);
|
|
@@ -617,7 +617,7 @@ function Wn() {
|
|
|
617
617
|
var o = new ne(this, !0), f = o._first && I(o._first, this) || o._last && I(o._last, this);
|
|
618
618
|
return o.detach(), !f;
|
|
619
619
|
}, surroundContents: function(o) {
|
|
620
|
-
if (Ee(o,
|
|
620
|
+
if (Ee(o, ye), !this.canSurroundContents()) throw new ee("INVALID_STATE_ERR");
|
|
621
621
|
var f = this.extractContents();
|
|
622
622
|
if (o.hasChildNodes()) for (; o.lastChild; ) o.removeChild(o.lastChild);
|
|
623
623
|
ce(o, this.startContainer, this.startOffset), o.appendChild(f), this.selectNode(o);
|
|
@@ -640,9 +640,9 @@ function Wn() {
|
|
|
640
640
|
var l = this.comparePoint(f, i), m = this.comparePoint(f, i + 1);
|
|
641
641
|
return l < 0 ? m > 0 ? 2 : 0 : m > 0 ? 1 : 3;
|
|
642
642
|
}, comparePoint: function(o, f) {
|
|
643
|
-
return pe(this), ft(o, "HIERARCHY_REQUEST_ERR"),
|
|
643
|
+
return pe(this), ft(o, "HIERARCHY_REQUEST_ERR"), it(o, this.startContainer), u(o, f, this.startContainer, this.startOffset) < 0 ? -1 : u(o, f, this.endContainer, this.endOffset) > 0 ? 1 : 0;
|
|
644
644
|
}, createContextualFragment: Ct, toHtml: function() {
|
|
645
|
-
return
|
|
645
|
+
return st(this);
|
|
646
646
|
}, intersectsNode: function(o, f) {
|
|
647
647
|
if (pe(this), v(o) != v(this.startContainer)) return !1;
|
|
648
648
|
var i = o.parentNode, l = ue(o);
|
|
@@ -650,7 +650,7 @@ function Wn() {
|
|
|
650
650
|
var m = u(i, l, this.endContainer, this.endOffset), k = u(i, l + 1, this.startContainer, this.startOffset);
|
|
651
651
|
return f ? m <= 0 && k >= 0 : m < 0 && k > 0;
|
|
652
652
|
}, isPointInRange: function(o, f) {
|
|
653
|
-
return pe(this), ft(o, "HIERARCHY_REQUEST_ERR"),
|
|
653
|
+
return pe(this), ft(o, "HIERARCHY_REQUEST_ERR"), it(o, this.startContainer), u(o, f, this.startContainer, this.startOffset) >= 0 && u(o, f, this.endContainer, this.endOffset) <= 0;
|
|
654
654
|
}, intersectsRange: function(o) {
|
|
655
655
|
return te(this, o, !1);
|
|
656
656
|
}, intersectsOrTouchesRange: function(o) {
|
|
@@ -686,11 +686,11 @@ function Wn() {
|
|
|
686
686
|
return this.containsNodeContents(o);
|
|
687
687
|
}, getNodes: function(o, f) {
|
|
688
688
|
return pe(this), function(i, l, m) {
|
|
689
|
-
var k,
|
|
690
|
-
|
|
689
|
+
var k, y = !(!l || !l.length), N = !!m;
|
|
690
|
+
y && (k = new RegExp("^(" + l.join("|") + ")$"));
|
|
691
691
|
var X = [];
|
|
692
692
|
return d(new ne(i, !1), function(j) {
|
|
693
|
-
if ((!
|
|
693
|
+
if ((!y || k.test(j.nodeType)) && (!N || m(j))) {
|
|
694
694
|
var oe = i.startContainer;
|
|
695
695
|
if (j != oe || !K(oe) || i.startOffset != oe.length) {
|
|
696
696
|
var Je = i.endContainer;
|
|
@@ -713,8 +713,8 @@ function Wn() {
|
|
|
713
713
|
}, moveToBookmark: function(o) {
|
|
714
714
|
var f = o.containerNode, i = 0;
|
|
715
715
|
this.setStart(f, 0), this.collapse(!0);
|
|
716
|
-
for (var l, m, k,
|
|
717
|
-
else for (k = (
|
|
716
|
+
for (var l, m, k, y, N = [f], X = !1, j = !1; !j && (l = N.pop()); ) if (l.nodeType == 3) m = i + l.length, !X && o.start >= i && o.start <= m && (this.setStart(l, o.start - i), X = !0), X && o.end >= i && o.end <= m && (this.setEnd(l, o.end - i), j = !0), i = m;
|
|
717
|
+
else for (k = (y = l.childNodes).length; k--; ) N.push(y[k]);
|
|
718
718
|
}, getName: function() {
|
|
719
719
|
return "DomRange";
|
|
720
720
|
}, equals: function(o) {
|
|
@@ -724,7 +724,7 @@ function Wn() {
|
|
|
724
724
|
}, inspect: function() {
|
|
725
725
|
return $(this);
|
|
726
726
|
}, detach: function() {
|
|
727
|
-
} }), kt(Ve, Ze), F.extend(Ve, { rangeProperties: se, RangeIterator: ne, copyComparisonConstants:
|
|
727
|
+
} }), kt(Ve, Ze), F.extend(Ve, { rangeProperties: se, RangeIterator: ne, copyComparisonConstants: wt, createPrototypeRange: kt, inspect: $, toHtml: st, getRangeDocument: U, rangesEqual: function(o, f) {
|
|
728
728
|
return o.startContainer === f.startContainer && o.startOffset === f.startOffset && o.endContainer === f.endContainer && o.endOffset === f.endOffset;
|
|
729
729
|
} }), p.DomRange = Ve;
|
|
730
730
|
}), q.createCoreModule("WrappedRange", ["DomRange"], function(p, x) {
|
|
@@ -821,7 +821,7 @@ function Wn() {
|
|
|
821
821
|
return (d = h(d, x, "createNativeRange")).createRange();
|
|
822
822
|
};
|
|
823
823
|
}(), p.features.implementsTextRange) {
|
|
824
|
-
var
|
|
824
|
+
var w = function(v, P, W, I, U) {
|
|
825
825
|
var Y = v.duplicate();
|
|
826
826
|
Y.collapse(W);
|
|
827
827
|
var Z = Y.parentElement();
|
|
@@ -831,12 +831,12 @@ function Wn() {
|
|
|
831
831
|
}
|
|
832
832
|
var te = J.getDocument(Z).createElement("span");
|
|
833
833
|
te.parentNode && J.removeNode(te);
|
|
834
|
-
for (var he, d, S, D, $, ne = W ? "StartToStart" : "StartToEnd", ge = U && U.containerElement == Z ? U.nodeIndex : 0, Me = Z.childNodes.length, Ce = Me,
|
|
834
|
+
for (var he, d, S, D, $, ne = W ? "StartToStart" : "StartToEnd", ge = U && U.containerElement == Z ? U.nodeIndex : 0, Me = Z.childNodes.length, Ce = Me, ye = Ce; ye == Me ? Z.appendChild(te) : Z.insertBefore(te, Z.childNodes[ye]), Y.moveToElementText(te), (he = Y.compareEndPoints(ne, v)) != 0 && ge != Ce; ) {
|
|
835
835
|
if (he == -1) {
|
|
836
836
|
if (Ce == ge + 1) break;
|
|
837
|
-
ge =
|
|
838
|
-
} else Ce = Ce == ge + 1 ? ge :
|
|
839
|
-
|
|
837
|
+
ge = ye;
|
|
838
|
+
} else Ce = Ce == ge + 1 ? ge : ye;
|
|
839
|
+
ye = Math.floor((ge + Ce) / 2), Z.removeChild(te);
|
|
840
840
|
}
|
|
841
841
|
if ($ = te.nextSibling, he == -1 && $ && u($)) {
|
|
842
842
|
var Ne;
|
|
@@ -846,7 +846,7 @@ function Wn() {
|
|
|
846
846
|
} else Ne = Y.text.length;
|
|
847
847
|
D = new K($, Ne);
|
|
848
848
|
} else d = (I || !W) && te.previousSibling, D = (S = (I || W) && te.nextSibling) && u(S) ? new K(S, 0) : d && u(d) ? new K(d, d.data.length) : new K(Z, J.getNodeIndex(te));
|
|
849
|
-
return J.removeNode(te), { boundaryPosition: D, nodeInfo: { nodeIndex:
|
|
849
|
+
return J.removeNode(te), { boundaryPosition: D, nodeInfo: { nodeIndex: ye, containerElement: Z } };
|
|
850
850
|
}, T = function(v, P) {
|
|
851
851
|
var W, I, U, Y, Z = v.offset, ce = J.getDocument(v.node), te = r(ce).createTextRange(), he = u(v.node);
|
|
852
852
|
return he ? I = (W = v.node).parentNode : (W = Z < (Y = v.node.childNodes).length ? Y[Z] : null, I = v.node), (U = ce.createElement("span")).innerHTML = "&#feff;", W ? I.insertBefore(U, W) : I.appendChild(U), te.moveToElementText(U), te.collapse(!P), I.removeChild(U), he && te[P ? "moveStart" : "moveEnd"]("character", Z), te;
|
|
@@ -862,7 +862,7 @@ function Wn() {
|
|
|
862
862
|
var he = ce.parentElement(), d = te == he ? te : J.getCommonAncestor(te, he);
|
|
863
863
|
return d == Z ? d : J.getCommonAncestor(Z, d);
|
|
864
864
|
}(this.textRange);
|
|
865
|
-
(I = this.textRange).compareEndPoints("StartToEnd", I) == 0 ? P = v =
|
|
865
|
+
(I = this.textRange).compareEndPoints("StartToEnd", I) == 0 ? P = v = w(this.textRange, U, !0, !0).boundaryPosition : (v = (W = w(this.textRange, U, !0, !1)).boundaryPosition, P = w(this.textRange, U, !1, !1, W.nodeInfo).boundaryPosition), this.setStart(v.node, v.offset), this.setEnd(P.node, P.offset);
|
|
866
866
|
}, F.prototype.getName = function() {
|
|
867
867
|
return "WrappedTextRange";
|
|
868
868
|
}, ue.copyComparisonConstants(F);
|
|
@@ -892,7 +892,7 @@ function Wn() {
|
|
|
892
892
|
});
|
|
893
893
|
}), q.createCoreModule("WrappedSelection", ["DomRange", "WrappedRange"], function(p, x) {
|
|
894
894
|
p.config.checkSelectionRanges = !0;
|
|
895
|
-
var L, F, J = "boolean", ee = "number", K = p.dom, ue = p.util, r = ue.isHostMethod, h = p.DomRange, u = p.WrappedRange,
|
|
895
|
+
var L, F, J = "boolean", ee = "number", K = p.dom, ue = p.util, r = ue.isHostMethod, h = p.DomRange, u = p.WrappedRange, w = p.DOMException, T = K.DomPosition, O = p.features, z = "Control", v = K.getDocument, P = K.getBody, W = h.rangesEqual;
|
|
896
896
|
function I(i) {
|
|
897
897
|
return typeof i == "string" ? /^backward(s)?$/i.test(i) : !!i;
|
|
898
898
|
}
|
|
@@ -938,16 +938,16 @@ function Wn() {
|
|
|
938
938
|
O.selectionHasSetBaseAndExtent = ge;
|
|
939
939
|
var Me = typeof d.rangeCount == ee;
|
|
940
940
|
O.selectionHasRangeCount = Me;
|
|
941
|
-
var Ce = !1,
|
|
941
|
+
var Ce = !1, ye = !0, Ne = ne ? function(i, l) {
|
|
942
942
|
var m = h.getRangeDocument(l), k = p.createRange(m);
|
|
943
943
|
k.collapseToPoint(l.endContainer, l.endOffset), i.addRange(je(k)), i.extend(l.startContainer, l.startOffset);
|
|
944
944
|
} : null;
|
|
945
945
|
ue.areHostMethods(d, ["addRange", "getRangeAt", "removeAllRanges"]) && typeof d.rangeCount == ee && O.implementsDomRange && function() {
|
|
946
946
|
var i = window.getSelection();
|
|
947
947
|
if (i) {
|
|
948
|
-
for (var l = i.rangeCount, m = l > 1, k = [],
|
|
948
|
+
for (var l = i.rangeCount, m = l > 1, k = [], y = Z(i), N = 0; N < l; ++N) k[N] = i.getRangeAt(N);
|
|
949
949
|
var X = K.createTestElement(document, "", !1), j = X.appendChild(document.createTextNode(" ")), oe = document.createRange();
|
|
950
|
-
if (oe.setStart(j, 1), oe.collapse(!0), i.removeAllRanges(), i.addRange(oe),
|
|
950
|
+
if (oe.setStart(j, 1), oe.collapse(!0), i.removeAllRanges(), i.addRange(oe), ye = i.rangeCount == 1, i.removeAllRanges(), !m) {
|
|
951
951
|
var Je = window.navigator.appVersion.match(/Chrome\/(.*?) /);
|
|
952
952
|
if (Je && parseInt(Je[1]) >= 36) Ce = !1;
|
|
953
953
|
else {
|
|
@@ -955,13 +955,13 @@ function Wn() {
|
|
|
955
955
|
oe.setStart(j, 0), ht.setEnd(j, 3), ht.setStart(j, 2), i.addRange(oe), i.addRange(ht), Ce = i.rangeCount == 2;
|
|
956
956
|
}
|
|
957
957
|
}
|
|
958
|
-
for (K.removeNode(X), i.removeAllRanges(), N = 0; N < l; ++N) N == 0 &&
|
|
958
|
+
for (K.removeNode(X), i.removeAllRanges(), N = 0; N < l; ++N) N == 0 && y ? Ne ? Ne(i, k[N]) : (p.warn("Rangy initialization: original selection was backwards but selection has been restored forwards because the browser does not support Selection.extend"), i.addRange(k[N])) : i.addRange(k[N]);
|
|
959
959
|
}
|
|
960
|
-
}(), O.selectionSupportsMultipleRanges = Ce, O.collapsedNonEditableSelectionsSupported =
|
|
960
|
+
}(), O.selectionSupportsMultipleRanges = Ce, O.collapsedNonEditableSelectionsSupported = ye;
|
|
961
961
|
var Ie, Xe, Pe = !1;
|
|
962
|
-
function
|
|
963
|
-
var k = m ? "end" : "start",
|
|
964
|
-
i.anchorNode = l[k + "Container"], i.anchorOffset = l[k + "Offset"], i.focusNode = l[
|
|
962
|
+
function nt(i, l, m) {
|
|
963
|
+
var k = m ? "end" : "start", y = m ? "start" : "end";
|
|
964
|
+
i.anchorNode = l[k + "Container"], i.anchorOffset = l[k + "Offset"], i.focusNode = l[y + "Container"], i.focusOffset = l[y + "Offset"];
|
|
965
965
|
}
|
|
966
966
|
function be(i) {
|
|
967
967
|
i.anchorNode = i.focusNode = null, i.anchorOffset = i.focusOffset = 0, i.rangeCount = 0, i.isCollapsed = !0, i._ranges.length = 0, Ee(i);
|
|
@@ -973,11 +973,11 @@ function Wn() {
|
|
|
973
973
|
var l;
|
|
974
974
|
return i instanceof h ? ((l = p.createNativeRange(i.getDocument())).setEnd(i.endContainer, i.endOffset), l.setStart(i.startContainer, i.startOffset)) : i instanceof u ? l = i.nativeRange : O.implementsDomRange && i instanceof K.getWindow(i.startContainer).Range && (l = i), l;
|
|
975
975
|
}
|
|
976
|
-
function
|
|
976
|
+
function it(i) {
|
|
977
977
|
var l = i.getNodes();
|
|
978
978
|
if (!function(m) {
|
|
979
979
|
if (!m.length || m[0].nodeType != 1) return !1;
|
|
980
|
-
for (var k = 1,
|
|
980
|
+
for (var k = 1, y = m.length; k < y; ++k) if (!K.isAncestorOf(m[0], m[k])) return !1;
|
|
981
981
|
return !0;
|
|
982
982
|
}(l)) throw x.createError("getSingleElementFromRange: range " + i.inspect() + " did not consist of a single element");
|
|
983
983
|
return l[0];
|
|
@@ -987,7 +987,7 @@ function Wn() {
|
|
|
987
987
|
}
|
|
988
988
|
function ft(i, l) {
|
|
989
989
|
var m = new u(l);
|
|
990
|
-
i._ranges = [m],
|
|
990
|
+
i._ranges = [m], nt(i, m, !1), i.rangeCount = 1, i.isCollapsed = m.collapsed, Ee(i);
|
|
991
991
|
}
|
|
992
992
|
function Ge(i) {
|
|
993
993
|
if (i._ranges.length = 0, i.docSelection.type == "None") be(i);
|
|
@@ -996,13 +996,13 @@ function Wn() {
|
|
|
996
996
|
if (ze(l)) ft(i, l);
|
|
997
997
|
else {
|
|
998
998
|
i.rangeCount = l.length;
|
|
999
|
-
for (var m, k = v(l.item(0)),
|
|
1000
|
-
i.isCollapsed = i.rangeCount == 1 && i._ranges[0].collapsed,
|
|
999
|
+
for (var m, k = v(l.item(0)), y = 0; y < i.rangeCount; ++y) (m = p.createRange(k)).selectNode(l.item(y)), i._ranges.push(m);
|
|
1000
|
+
i.isCollapsed = i.rangeCount == 1 && i._ranges[0].collapsed, nt(i, i._ranges[i.rangeCount - 1], !1), Ee(i);
|
|
1001
1001
|
}
|
|
1002
1002
|
}
|
|
1003
1003
|
}
|
|
1004
1004
|
function mt(i, l) {
|
|
1005
|
-
for (var m = i.docSelection.createRange(), k =
|
|
1005
|
+
for (var m = i.docSelection.createRange(), k = it(l), y = v(m.item(0)), N = P(y).createControlRange(), X = 0, j = m.length; X < j; ++X) N.add(m.item(X));
|
|
1006
1006
|
try {
|
|
1007
1007
|
N.add(k);
|
|
1008
1008
|
} catch (oe) {
|
|
@@ -1032,8 +1032,8 @@ function Wn() {
|
|
|
1032
1032
|
}), pe.prototype = p.selectionPrototype;
|
|
1033
1033
|
var qe = [];
|
|
1034
1034
|
function Ct(i, l) {
|
|
1035
|
-
for (var m, k,
|
|
1036
|
-
else if (m.win == i) return l == "delete" ? (qe.splice(
|
|
1035
|
+
for (var m, k, y = qe.length; y--; ) if (k = (m = qe[y]).selection, l == "deleteAll") vt(k);
|
|
1036
|
+
else if (m.win == i) return l == "delete" ? (qe.splice(y, 1), !0) : k;
|
|
1037
1037
|
return l == "deleteAll" && (qe.length = 0), null;
|
|
1038
1038
|
}
|
|
1039
1039
|
var dt = function(i) {
|
|
@@ -1042,28 +1042,28 @@ function Wn() {
|
|
|
1042
1042
|
return l ? (l.nativeSelection = m, l.docSelection = k, l.refresh()) : (l = new pe(m, k, i), qe.push({ win: i, selection: l })), l;
|
|
1043
1043
|
};
|
|
1044
1044
|
p.getSelection = dt, ue.createAliasForDeprecatedMethod(p, "getIframeSelection", "getSelection");
|
|
1045
|
-
var
|
|
1046
|
-
function
|
|
1047
|
-
for (var m, k = v(l[0].startContainer),
|
|
1048
|
-
m =
|
|
1045
|
+
var st, se = pe.prototype;
|
|
1046
|
+
function yt(i, l) {
|
|
1047
|
+
for (var m, k = v(l[0].startContainer), y = P(k).createControlRange(), N = 0, X = l.length; N < X; ++N) {
|
|
1048
|
+
m = it(l[N]);
|
|
1049
1049
|
try {
|
|
1050
|
-
|
|
1050
|
+
y.add(m);
|
|
1051
1051
|
} catch (j) {
|
|
1052
1052
|
throw x.createError("setRanges(): Element within one of the specified Ranges could not be added to control selection (does it have layout?)");
|
|
1053
1053
|
}
|
|
1054
1054
|
}
|
|
1055
|
-
|
|
1055
|
+
y.select(), Ge(i);
|
|
1056
1056
|
}
|
|
1057
1057
|
if (!he && $ && ue.areHostMethods(d, ["removeAllRanges", "addRange"])) {
|
|
1058
1058
|
se.removeAllRanges = function() {
|
|
1059
1059
|
this.nativeSelection.removeAllRanges(), be(this);
|
|
1060
1060
|
};
|
|
1061
|
-
var
|
|
1061
|
+
var wt = function(i, l) {
|
|
1062
1062
|
Ne(i.nativeSelection, l), i.refresh();
|
|
1063
1063
|
};
|
|
1064
1064
|
se.addRange = Me ? function(i, l) {
|
|
1065
1065
|
if (Pe && te && this.docSelection.type == z) mt(this, i);
|
|
1066
|
-
else if (I(l) && ne)
|
|
1066
|
+
else if (I(l) && ne) wt(this, i);
|
|
1067
1067
|
else {
|
|
1068
1068
|
var m;
|
|
1069
1069
|
Ce ? m = this.rangeCount : (this.removeAllRanges(), m = 0);
|
|
@@ -1074,16 +1074,16 @@ function Wn() {
|
|
|
1074
1074
|
}
|
|
1075
1075
|
if (this.rangeCount = this.nativeSelection.rangeCount, this.rangeCount == m + 1) {
|
|
1076
1076
|
if (p.config.checkSelectionRanges) {
|
|
1077
|
-
var
|
|
1078
|
-
|
|
1077
|
+
var y = Xe(this.nativeSelection, this.rangeCount - 1);
|
|
1078
|
+
y && !W(y, i) && (i = new u(y));
|
|
1079
1079
|
}
|
|
1080
|
-
this._ranges[this.rangeCount - 1] = i,
|
|
1080
|
+
this._ranges[this.rangeCount - 1] = i, nt(this, i, Qe(this.nativeSelection)), this.isCollapsed = F(this), Ee(this);
|
|
1081
1081
|
} else this.refresh();
|
|
1082
1082
|
}
|
|
1083
1083
|
} : function(i, l) {
|
|
1084
|
-
I(l) && ne ?
|
|
1084
|
+
I(l) && ne ? wt(this, i) : (this.nativeSelection.addRange(je(i)), this.refresh());
|
|
1085
1085
|
}, se.setRanges = function(i) {
|
|
1086
|
-
if (Pe && te && i.length > 1)
|
|
1086
|
+
if (Pe && te && i.length > 1) yt(this, i);
|
|
1087
1087
|
else {
|
|
1088
1088
|
this.removeAllRanges();
|
|
1089
1089
|
for (var l = 0, m = i.length; l < m; ++l) this.addRange(i[l]);
|
|
@@ -1106,57 +1106,57 @@ function Wn() {
|
|
|
1106
1106
|
}
|
|
1107
1107
|
be(this);
|
|
1108
1108
|
}, se.addRange = function(i) {
|
|
1109
|
-
this.docSelection.type == z ? mt(this, i) : (p.WrappedTextRange.rangeToTextRange(i).select(), this._ranges[0] = i, this.rangeCount = 1, this.isCollapsed = this._ranges[0].collapsed,
|
|
1109
|
+
this.docSelection.type == z ? mt(this, i) : (p.WrappedTextRange.rangeToTextRange(i).select(), this._ranges[0] = i, this.rangeCount = 1, this.isCollapsed = this._ranges[0].collapsed, nt(this, i, !1), Ee(this));
|
|
1110
1110
|
}, se.setRanges = function(i) {
|
|
1111
1111
|
this.removeAllRanges();
|
|
1112
1112
|
var l = i.length;
|
|
1113
|
-
l > 1 ?
|
|
1113
|
+
l > 1 ? yt(this, i) : l && this.addRange(i[0]);
|
|
1114
1114
|
};
|
|
1115
1115
|
}
|
|
1116
1116
|
if (se.getRangeAt = function(i) {
|
|
1117
|
-
if (i < 0 || i >= this.rangeCount) throw new
|
|
1117
|
+
if (i < 0 || i >= this.rangeCount) throw new w("INDEX_SIZE_ERR");
|
|
1118
1118
|
return this._ranges[i].cloneRange();
|
|
1119
|
-
}, he)
|
|
1119
|
+
}, he) st = function(i) {
|
|
1120
1120
|
var l;
|
|
1121
1121
|
p.isSelectionValid(i.win) ? l = i.docSelection.createRange() : (l = P(i.win.document).createTextRange()).collapse(!0), i.docSelection.type == z ? Ge(i) : ze(l) ? ft(i, l) : be(i);
|
|
1122
1122
|
};
|
|
1123
|
-
else if (r(d, "getRangeAt") && typeof d.rangeCount == ee)
|
|
1123
|
+
else if (r(d, "getRangeAt") && typeof d.rangeCount == ee) st = function(i) {
|
|
1124
1124
|
if (Pe && te && i.docSelection.type == z) Ge(i);
|
|
1125
1125
|
else if (i._ranges.length = i.rangeCount = i.nativeSelection.rangeCount, i.rangeCount) {
|
|
1126
1126
|
for (var l = 0, m = i.rangeCount; l < m; ++l) i._ranges[l] = new p.WrappedRange(i.nativeSelection.getRangeAt(l));
|
|
1127
|
-
|
|
1127
|
+
nt(i, i._ranges[i.rangeCount - 1], Qe(i.nativeSelection)), i.isCollapsed = F(i), Ee(i);
|
|
1128
1128
|
} else be(i);
|
|
1129
1129
|
};
|
|
1130
1130
|
else {
|
|
1131
1131
|
if (!$ || typeof d.isCollapsed != J || typeof S.collapsed != J || !O.implementsDomRange) return x.fail("No means of obtaining a Range or TextRange from the user's selection was found"), !1;
|
|
1132
|
-
|
|
1132
|
+
st = function(i) {
|
|
1133
1133
|
var l, m = i.nativeSelection;
|
|
1134
1134
|
m.anchorNode ? (l = Xe(m, 0), i._ranges = [l], i.rangeCount = 1, function(k) {
|
|
1135
|
-
var
|
|
1136
|
-
k.anchorNode =
|
|
1135
|
+
var y = k.nativeSelection;
|
|
1136
|
+
k.anchorNode = y.anchorNode, k.anchorOffset = y.anchorOffset, k.focusNode = y.focusNode, k.focusOffset = y.focusOffset;
|
|
1137
1137
|
}(i), i.isCollapsed = F(i), Ee(i)) : be(i);
|
|
1138
1138
|
};
|
|
1139
1139
|
}
|
|
1140
1140
|
se.refresh = function(i) {
|
|
1141
1141
|
var l = i ? this._ranges.slice(0) : null, m = this.anchorNode, k = this.anchorOffset;
|
|
1142
|
-
if (
|
|
1143
|
-
var
|
|
1144
|
-
if (
|
|
1145
|
-
for (;
|
|
1142
|
+
if (st(this), i) {
|
|
1143
|
+
var y = l.length;
|
|
1144
|
+
if (y != this._ranges.length || this.anchorNode != m || this.anchorOffset != k) return !0;
|
|
1145
|
+
for (; y--; ) if (!W(l[y], this._ranges[y])) return !0;
|
|
1146
1146
|
return !1;
|
|
1147
1147
|
}
|
|
1148
1148
|
};
|
|
1149
1149
|
var Qe, kt = function(i, l) {
|
|
1150
1150
|
var m = i.getAllRanges();
|
|
1151
1151
|
i.removeAllRanges();
|
|
1152
|
-
for (var k = 0,
|
|
1152
|
+
for (var k = 0, y = m.length; k < y; ++k) W(l, m[k]) || i.addRange(m[k]);
|
|
1153
1153
|
i.rangeCount || be(i);
|
|
1154
1154
|
};
|
|
1155
1155
|
function Ze(i, l) {
|
|
1156
|
-
if (i.win.document != v(l)) throw new
|
|
1156
|
+
if (i.win.document != v(l)) throw new w("WRONG_DOCUMENT_ERR");
|
|
1157
1157
|
}
|
|
1158
1158
|
function Ve(i, l) {
|
|
1159
|
-
if (l < 0 || l > (K.isCharacterDataNode(i) ? i.length : i.childNodes.length)) throw new
|
|
1159
|
+
if (l < 0 || l > (K.isCharacterDataNode(i) ? i.length : i.childNodes.length)) throw new w("INDEX_SIZE_ERR");
|
|
1160
1160
|
}
|
|
1161
1161
|
function o(i) {
|
|
1162
1162
|
return function(l, m) {
|
|
@@ -1165,14 +1165,14 @@ function Wn() {
|
|
|
1165
1165
|
};
|
|
1166
1166
|
}
|
|
1167
1167
|
function f(i) {
|
|
1168
|
-
var l = [], m = new T(i.anchorNode, i.anchorOffset), k = new T(i.focusNode, i.focusOffset),
|
|
1168
|
+
var l = [], m = new T(i.anchorNode, i.anchorOffset), k = new T(i.focusNode, i.focusOffset), y = typeof i.getName == "function" ? i.getName() : "Selection";
|
|
1169
1169
|
if (i.rangeCount !== void 0) for (var N = 0, X = i.rangeCount; N < X; ++N) l[N] = h.inspect(i.getRangeAt(N));
|
|
1170
|
-
return "[" +
|
|
1170
|
+
return "[" + y + "(Ranges: " + l.join(", ") + ")(anchor: " + m.inspect() + ", focus: " + k.inspect() + "]";
|
|
1171
1171
|
}
|
|
1172
1172
|
se.removeRange = Pe && te ? function(i) {
|
|
1173
1173
|
if (this.docSelection.type == z) {
|
|
1174
|
-
for (var l = this.docSelection.createRange(), m =
|
|
1175
|
-
|
|
1174
|
+
for (var l = this.docSelection.createRange(), m = it(i), k = v(l.item(0)), y = P(k).createControlRange(), N = !1, X = 0, j = l.length; X < j; ++X) l.item(X) !== m || N ? y.add(l.item(X)) : N = !0;
|
|
1175
|
+
y.select(), Ge(this);
|
|
1176
1176
|
} else kt(this, i);
|
|
1177
1177
|
} : function(i) {
|
|
1178
1178
|
kt(this, i);
|
|
@@ -1188,11 +1188,11 @@ function Wn() {
|
|
|
1188
1188
|
var m = p.createRange(i);
|
|
1189
1189
|
m.collapseToPoint(i, l), this.setSingleRange(m), this.isCollapsed = !0;
|
|
1190
1190
|
}, se.collapseToStart = function() {
|
|
1191
|
-
if (!this.rangeCount) throw new
|
|
1191
|
+
if (!this.rangeCount) throw new w("INVALID_STATE_ERR");
|
|
1192
1192
|
var i = this._ranges[0];
|
|
1193
1193
|
this.collapse(i.startContainer, i.startOffset);
|
|
1194
1194
|
}, se.collapseToEnd = function() {
|
|
1195
|
-
if (!this.rangeCount) throw new
|
|
1195
|
+
if (!this.rangeCount) throw new w("INVALID_STATE_ERR");
|
|
1196
1196
|
var i = this._ranges[this.rangeCount - 1];
|
|
1197
1197
|
this.collapse(i.endContainer, i.endOffset);
|
|
1198
1198
|
}, se.selectAllChildren = function(i) {
|
|
@@ -1203,8 +1203,8 @@ function Wn() {
|
|
|
1203
1203
|
this.nativeSelection.setBaseAndExtent(i, l, m, k), this.refresh();
|
|
1204
1204
|
} : ne && (se.setBaseAndExtent = function(i, l, m, k) {
|
|
1205
1205
|
Ve(i, l), Ve(m, k), Ze(this, i), Ze(this, m);
|
|
1206
|
-
var
|
|
1207
|
-
N ?
|
|
1206
|
+
var y = p.createRange(node), N = K.comparePoints(i, l, m, k) == -1;
|
|
1207
|
+
N ? y.setStartAndEnd(m, k, i, l) : y.setStartAndEnd(i, l, m, k), this.setSingleRange(y, N);
|
|
1208
1208
|
}), se.deleteFromDocument = function() {
|
|
1209
1209
|
if (Pe && te && this.docSelection.type == z) {
|
|
1210
1210
|
for (var i, l = this.docSelection.createRange(); l.length; ) i = l.item(0), l.remove(i), K.removeNode(i);
|
|
@@ -1213,8 +1213,8 @@ function Wn() {
|
|
|
1213
1213
|
var m = this.getAllRanges();
|
|
1214
1214
|
if (m.length) {
|
|
1215
1215
|
this.removeAllRanges();
|
|
1216
|
-
for (var k = 0,
|
|
1217
|
-
this.addRange(m[
|
|
1216
|
+
for (var k = 0, y = m.length; k < y; ++k) m[k].deleteContents();
|
|
1217
|
+
this.addRange(m[y - 1]);
|
|
1218
1218
|
}
|
|
1219
1219
|
}
|
|
1220
1220
|
}, se.eachRange = function(i, l) {
|
|
@@ -1245,7 +1245,7 @@ function Wn() {
|
|
|
1245
1245
|
}, se.getBookmark = function(i) {
|
|
1246
1246
|
return { backward: this.isBackward(), rangeBookmarks: this.callMethodOnEachRange("getBookmark", [i]) };
|
|
1247
1247
|
}, se.moveToBookmark = function(i) {
|
|
1248
|
-
for (var l, m, k = [],
|
|
1248
|
+
for (var l, m, k = [], y = 0; l = i.rangeBookmarks[y++]; ) (m = p.createRange(this.win)).moveToBookmark(l), k.push(m);
|
|
1249
1249
|
i.backward ? this.setSingleRange(k[0], "backward") : this.setRanges(k);
|
|
1250
1250
|
}, se.saveRanges = function() {
|
|
1251
1251
|
return { backward: this.isBackward(), ranges: this.callMethodOnEachRange("cloneRange") };
|
|
@@ -1304,19 +1304,19 @@ function Fn(_) {
|
|
|
1304
1304
|
function R(r, h) {
|
|
1305
1305
|
if (typeof r.classList == "object") r.classList.add(h);
|
|
1306
1306
|
else {
|
|
1307
|
-
var u = typeof r.className == "string",
|
|
1308
|
-
|
|
1307
|
+
var u = typeof r.className == "string", w = u ? r.className : r.getAttribute("class");
|
|
1308
|
+
w ? M(w, h) || (w += " " + h) : w = h, u ? r.className = w : r.setAttribute("class", w);
|
|
1309
1309
|
}
|
|
1310
1310
|
}
|
|
1311
1311
|
var H = /* @__PURE__ */ function() {
|
|
1312
|
-
function r(h, u,
|
|
1313
|
-
return u &&
|
|
1312
|
+
function r(h, u, w) {
|
|
1313
|
+
return u && w ? " " : "";
|
|
1314
1314
|
}
|
|
1315
1315
|
return function(h, u) {
|
|
1316
1316
|
if (typeof h.classList == "object") h.classList.remove(u);
|
|
1317
1317
|
else {
|
|
1318
|
-
var
|
|
1319
|
-
T = T.replace(new RegExp("(^|\\s)" + u + "(\\s|$)"), r),
|
|
1318
|
+
var w = typeof h.className == "string", T = w ? h.className : h.getAttribute("class");
|
|
1319
|
+
T = T.replace(new RegExp("(^|\\s)" + u + "(\\s|$)"), r), w ? h.className = T : h.setAttribute("class", T);
|
|
1320
1320
|
}
|
|
1321
1321
|
};
|
|
1322
1322
|
}();
|
|
@@ -1333,47 +1333,47 @@ function Fn(_) {
|
|
|
1333
1333
|
return ie(r) == ie(h);
|
|
1334
1334
|
}
|
|
1335
1335
|
function fe(r, h) {
|
|
1336
|
-
for (var u = h.split(/\s+/),
|
|
1336
|
+
for (var u = h.split(/\s+/), w = 0, T = u.length; w < T; ++w) if (!A(r, b(u[w]))) return !1;
|
|
1337
1337
|
return !0;
|
|
1338
1338
|
}
|
|
1339
|
-
function q(r, h, u,
|
|
1339
|
+
function q(r, h, u, w) {
|
|
1340
1340
|
u == -1 && (u = h.childNodes.length);
|
|
1341
1341
|
var T = r.parentNode, O = n.getNodeIndex(r);
|
|
1342
|
-
g(
|
|
1342
|
+
g(w, function(z) {
|
|
1343
1343
|
(function(v, P, W, I, U) {
|
|
1344
1344
|
var Y = v.node, Z = v.offset, ce = Y, te = Z;
|
|
1345
1345
|
Y == I && Z > U && ++te, Y != P || Z != W && Z != W + 1 || (ce = I, te += U - W), Y == P && Z > W + 1 && --te, v.node = ce, v.offset = te;
|
|
1346
1346
|
})(z, T, O, h, u);
|
|
1347
1347
|
}), h.childNodes.length == u ? h.appendChild(r) : h.insertBefore(r, h.childNodes[u]);
|
|
1348
1348
|
}
|
|
1349
|
-
function
|
|
1350
|
-
var u = r.parentNode,
|
|
1349
|
+
function we(r, h) {
|
|
1350
|
+
var u = r.parentNode, w = n.getNodeIndex(r);
|
|
1351
1351
|
g(h, function(T) {
|
|
1352
1352
|
(function(O, z, v) {
|
|
1353
1353
|
O.node == z && O.offset > v && --O.offset;
|
|
1354
|
-
})(T, u,
|
|
1354
|
+
})(T, u, w);
|
|
1355
1355
|
}), n.removeNode(r);
|
|
1356
1356
|
}
|
|
1357
1357
|
function $e(r, h) {
|
|
1358
|
-
return function(u,
|
|
1359
|
-
for (var v, P = []; v = u.firstChild; ) q(v,
|
|
1360
|
-
return
|
|
1358
|
+
return function(u, w, T, O, z) {
|
|
1359
|
+
for (var v, P = []; v = u.firstChild; ) q(v, w, T++, z), P.push(v);
|
|
1360
|
+
return we(u, z), P;
|
|
1361
1361
|
}(r, r.parentNode, n.getNodeIndex(r), 0, h);
|
|
1362
1362
|
}
|
|
1363
1363
|
function Ae(r, h) {
|
|
1364
1364
|
var u = r.cloneRange();
|
|
1365
1365
|
u.selectNodeContents(h);
|
|
1366
|
-
var
|
|
1367
|
-
return (
|
|
1366
|
+
var w = u.intersection(r);
|
|
1367
|
+
return (w ? w.toString() : "") != "";
|
|
1368
1368
|
}
|
|
1369
1369
|
function Be(r) {
|
|
1370
|
-
for (var h, u = r.getNodes([3]),
|
|
1370
|
+
for (var h, u = r.getNodes([3]), w = 0; (h = u[w]) && !Ae(r, h); ) ++w;
|
|
1371
1371
|
for (var T = u.length - 1; (h = u[T]) && !Ae(r, h); ) --T;
|
|
1372
|
-
return u.slice(
|
|
1372
|
+
return u.slice(w, T + 1);
|
|
1373
1373
|
}
|
|
1374
1374
|
function Ye(r, h) {
|
|
1375
1375
|
if (r.attributes.length != h.attributes.length) return !1;
|
|
1376
|
-
for (var u,
|
|
1376
|
+
for (var u, w, T, O = 0, z = r.attributes.length; O < z; ++O) if ((T = (u = r.attributes[O]).name) != "class" && (u === null != ((w = h.attributes.getNamedItem(T)) === null) || u.specified != w.specified || u.specified && u.nodeValue !== w.nodeValue))
|
|
1377
1377
|
return !1;
|
|
1378
1378
|
return !0;
|
|
1379
1379
|
}
|
|
@@ -1395,14 +1395,14 @@ function Fn(_) {
|
|
|
1395
1395
|
}
|
|
1396
1396
|
var ae = /[^\r\n\t\f \u200B]/;
|
|
1397
1397
|
function le(r) {
|
|
1398
|
-
var h, u,
|
|
1399
|
-
for (h = 0; u = r[h++]; )
|
|
1400
|
-
return
|
|
1398
|
+
var h, u, w = [];
|
|
1399
|
+
for (h = 0; u = r[h++]; ) w.push(new s(u.startContainer, u.startOffset), new s(u.endContainer, u.endOffset));
|
|
1400
|
+
return w;
|
|
1401
1401
|
}
|
|
1402
1402
|
function ve(r, h) {
|
|
1403
|
-
for (var u,
|
|
1403
|
+
for (var u, w, T, O = 0, z = r.length; O < z; ++O) u = r[O], w = h[2 * O], T = h[2 * O + 1], u.setStartAndEnd(w.node, w.offset, T.node, T.offset);
|
|
1404
1404
|
}
|
|
1405
|
-
function p(r, h, u,
|
|
1405
|
+
function p(r, h, u, w) {
|
|
1406
1406
|
var T, O, z = u == 0;
|
|
1407
1407
|
if (n.isAncestorOf(h, r)) return r;
|
|
1408
1408
|
if (n.isCharacterDataNode(h)) {
|
|
@@ -1418,23 +1418,23 @@ function Fn(_) {
|
|
|
1418
1418
|
return n.isCharacterDataNode(U) ? Y == 0 ? !!U.previousSibling : Y != U.length || !!U.nextSibling : Y > 0 && Y < U.childNodes.length;
|
|
1419
1419
|
}(h, u)) {
|
|
1420
1420
|
T = h.cloneNode(!1), O = h.parentNode, T.id && T.removeAttribute("id");
|
|
1421
|
-
for (var P, W = 0; P = h.childNodes[u]; ) q(P, T, W++,
|
|
1422
|
-
return q(T, O, n.getNodeIndex(h) + 1,
|
|
1421
|
+
for (var P, W = 0; P = h.childNodes[u]; ) q(P, T, W++, w);
|
|
1422
|
+
return q(T, O, n.getNodeIndex(h) + 1, w), h == r ? T : p(r, O, n.getNodeIndex(T), w);
|
|
1423
1423
|
}
|
|
1424
1424
|
if (r != h) {
|
|
1425
1425
|
T = h.parentNode;
|
|
1426
1426
|
var I = n.getNodeIndex(h);
|
|
1427
|
-
return z || I++, p(r, T, I,
|
|
1427
|
+
return z || I++, p(r, T, I, w);
|
|
1428
1428
|
}
|
|
1429
1429
|
return r;
|
|
1430
1430
|
}
|
|
1431
1431
|
function x(r) {
|
|
1432
1432
|
var h = r ? "nextSibling" : "previousSibling";
|
|
1433
|
-
return function(u,
|
|
1433
|
+
return function(u, w) {
|
|
1434
1434
|
var T, O, z = u.parentNode, v = u[h];
|
|
1435
1435
|
if (v) {
|
|
1436
1436
|
if (v && v.nodeType == 3) return v;
|
|
1437
|
-
} else if (
|
|
1437
|
+
} else if (w && (v = z[h]) && v.nodeType == 1 && (O = v, (T = z).namespaceURI == O.namespaceURI && T.tagName.toLowerCase() == O.tagName.toLowerCase() && de(T, O) && Ye(T, O) && Oe(T, "display") == "inline" && Oe(O, "display") == "inline")) {
|
|
1438
1438
|
var P = v[r ? "firstChild" : "lastChild"];
|
|
1439
1439
|
if (P && P.nodeType == 3) return P;
|
|
1440
1440
|
}
|
|
@@ -1450,10 +1450,10 @@ function Fn(_) {
|
|
|
1450
1450
|
J.prototype = { doMerge: function(r) {
|
|
1451
1451
|
var h = this.textNodes, u = h[0];
|
|
1452
1452
|
if (h.length > 1) {
|
|
1453
|
-
var
|
|
1453
|
+
var w, T = n.getNodeIndex(u), O = [], z = 0;
|
|
1454
1454
|
g(h, function(v, P) {
|
|
1455
|
-
|
|
1456
|
-
W.node == v && (W.node = u, W.offset += z), W.node ==
|
|
1455
|
+
w = v.parentNode, P > 0 && (w.removeChild(v), w.hasChildNodes() || n.removeNode(w), r && g(r, function(W) {
|
|
1456
|
+
W.node == v && (W.node = u, W.offset += z), W.node == w && W.offset > T && (--W.offset, W.offset == T + 1 && P < h.length - 1 && (W.node = u, W.offset = z));
|
|
1457
1457
|
})), O[P] = v.data, z += v.data.length;
|
|
1458
1458
|
}), u.data = O.join("");
|
|
1459
1459
|
}
|
|
@@ -1469,14 +1469,14 @@ function Fn(_) {
|
|
|
1469
1469
|
} };
|
|
1470
1470
|
var ee = ["elementTagName", "ignoreWhiteSpace", "applyToEditableOnly", "useExistingElements", "removeEmptyElements", "onElementCreate"], K = {};
|
|
1471
1471
|
function ue(r, h, u) {
|
|
1472
|
-
var
|
|
1472
|
+
var w, T, O, z, v = this;
|
|
1473
1473
|
v.cssClass = v.className = r;
|
|
1474
1474
|
var P = null, W = {};
|
|
1475
1475
|
if (typeof h == "object" && h !== null) {
|
|
1476
1476
|
for (h.elementTagName !== void 0 && (h.elementTagName = h.elementTagName.toLowerCase()), u = h.tagNames, P = h.elementProperties, W = h.elementAttributes, T = 0; z = ee[T++]; ) h.hasOwnProperty(z) && (v[z] = h[z]);
|
|
1477
|
-
|
|
1478
|
-
} else
|
|
1479
|
-
v.normalize =
|
|
1477
|
+
w = h.normalize;
|
|
1478
|
+
} else w = h;
|
|
1479
|
+
v.normalize = w === void 0 || w, v.attrExceptions = [];
|
|
1480
1480
|
var I = document.createElement(v.elementTagName);
|
|
1481
1481
|
v.elementProperties = v.copyPropertiesToElement(P, I, !0), E(W, function(Y, Z) {
|
|
1482
1482
|
v.attrExceptions.push(Y), W[Y] = "" + Z;
|
|
@@ -1487,10 +1487,10 @@ function Fn(_) {
|
|
|
1487
1487
|
else v.tagNames = [v.elementTagName];
|
|
1488
1488
|
}
|
|
1489
1489
|
ue.prototype = { elementTagName: "span", elementProperties: {}, elementAttributes: {}, ignoreWhiteSpace: !0, applyToEditableOnly: !1, useExistingElements: !0, removeEmptyElements: !0, onElementCreate: null, copyPropertiesToElement: function(r, h, u) {
|
|
1490
|
-
var
|
|
1490
|
+
var w, T, O, z, v, P, W = {};
|
|
1491
1491
|
for (var I in r) if (r.hasOwnProperty(I)) if (z = r[I], v = h[I], I == "className") R(h, z), R(h, this.className), h[I] = G(h[I]), u && (W[I] = z);
|
|
1492
1492
|
else if (I == "style") {
|
|
1493
|
-
for (
|
|
1493
|
+
for (w in T = v, u && (W[I] = O = {}), r[I]) r[I].hasOwnProperty(w) && (T[w] = z[w], u && (O[w] = T[w]));
|
|
1494
1494
|
this.attrExceptions.push(I);
|
|
1495
1495
|
} else h[I] = z, u && (W[I] = h[I], P = K.hasOwnProperty(I) ? K[I] : I, this.attrExceptions.push(P));
|
|
1496
1496
|
return u ? W : "";
|
|
@@ -1527,12 +1527,12 @@ function Fn(_) {
|
|
|
1527
1527
|
}
|
|
1528
1528
|
return Q(h.previousSibling) || Q(h.nextSibling);
|
|
1529
1529
|
}(r);
|
|
1530
|
-
}, postApply: function(r, h, u,
|
|
1530
|
+
}, postApply: function(r, h, u, w) {
|
|
1531
1531
|
var T, O, z = r[0], v = r[r.length - 1], P = [], W = z, I = v, U = 0, Y = v.length;
|
|
1532
1532
|
g(r, function(he) {
|
|
1533
|
-
(O = L(he, !
|
|
1533
|
+
(O = L(he, !w)) ? (T || (T = new J(O), P.push(T)), T.textNodes.push(he), he === z && (W = T.textNodes[0], U = W.length), he === v && (I = T.textNodes[0], Y = T.getLength())) : T = null;
|
|
1534
1534
|
});
|
|
1535
|
-
var Z = F(v, !
|
|
1535
|
+
var Z = F(v, !w);
|
|
1536
1536
|
if (Z && (T || (T = new J(v), P.push(T)), T.textNodes.push(Z)), P.length) {
|
|
1537
1537
|
for (var ce = 0, te = P.length; ce < te; ++ce) P[ce].doMerge(u);
|
|
1538
1538
|
h.setStartAndEnd(W, U, I, Y);
|
|
@@ -1542,15 +1542,15 @@ function Fn(_) {
|
|
|
1542
1542
|
return this.copyPropertiesToElement(this.elementProperties, u, !1), this.copyAttributesToElement(this.elementAttributes, u), R(u, this.className), this.onElementCreate && this.onElementCreate(u, this), u;
|
|
1543
1543
|
}, elementHasProperties: function(r, h) {
|
|
1544
1544
|
var u = this;
|
|
1545
|
-
return E(h, function(
|
|
1546
|
-
if (
|
|
1545
|
+
return E(h, function(w, T) {
|
|
1546
|
+
if (w == "className") return fe(r, T);
|
|
1547
1547
|
if (typeof T == "object") {
|
|
1548
|
-
if (!u.elementHasProperties(r[
|
|
1549
|
-
} else if (r[
|
|
1548
|
+
if (!u.elementHasProperties(r[w], T)) return !1;
|
|
1549
|
+
} else if (r[w] !== T) return !1;
|
|
1550
1550
|
});
|
|
1551
1551
|
}, elementHasAttributes: function(r, h) {
|
|
1552
|
-
return E(h, function(u,
|
|
1553
|
-
if (r.getAttribute(u) !==
|
|
1552
|
+
return E(h, function(u, w) {
|
|
1553
|
+
if (r.getAttribute(u) !== w) return !1;
|
|
1554
1554
|
});
|
|
1555
1555
|
}, applyToTextNode: function(r, h) {
|
|
1556
1556
|
if (function(O) {
|
|
@@ -1560,8 +1560,8 @@ function Fn(_) {
|
|
|
1560
1560
|
var u = r.parentNode;
|
|
1561
1561
|
if (u.childNodes.length == 1 && this.useExistingElements && this.appliesToElement(u) && this.elementHasProperties(u, this.elementProperties) && this.elementHasAttributes(u, this.elementAttributes)) R(u, this.className);
|
|
1562
1562
|
else {
|
|
1563
|
-
var
|
|
1564
|
-
|
|
1563
|
+
var w = r.parentNode, T = this.createContainer(w);
|
|
1564
|
+
w.insertBefore(T, r), T.appendChild(r);
|
|
1565
1565
|
}
|
|
1566
1566
|
}
|
|
1567
1567
|
}, isRemovable: function(r) {
|
|
@@ -1572,31 +1572,31 @@ function Fn(_) {
|
|
|
1572
1572
|
}, removeEmptyContainers: function(r) {
|
|
1573
1573
|
var h = this, u = r.getNodes([1], function(O) {
|
|
1574
1574
|
return h.isEmptyContainer(O);
|
|
1575
|
-
}),
|
|
1575
|
+
}), w = [r], T = le(w);
|
|
1576
1576
|
g(u, function(O) {
|
|
1577
|
-
|
|
1578
|
-
}), ve(
|
|
1579
|
-
}, undoToTextNode: function(r, h, u,
|
|
1577
|
+
we(O, T);
|
|
1578
|
+
}), ve(w, T);
|
|
1579
|
+
}, undoToTextNode: function(r, h, u, w) {
|
|
1580
1580
|
if (!h.containsNode(u)) {
|
|
1581
1581
|
var T = h.cloneRange();
|
|
1582
|
-
T.selectNode(u), T.isPointInRange(h.endContainer, h.endOffset) && (p(u, h.endContainer, h.endOffset,
|
|
1582
|
+
T.selectNode(u), T.isPointInRange(h.endContainer, h.endOffset) && (p(u, h.endContainer, h.endOffset, w), h.setEndAfter(u)), T.isPointInRange(h.startContainer, h.startOffset) && (u = p(u, h.startContainer, h.startOffset, w));
|
|
1583
1583
|
}
|
|
1584
|
-
this.isRemovable(u) ? $e(u,
|
|
1584
|
+
this.isRemovable(u) ? $e(u, w) : H(u, this.className);
|
|
1585
1585
|
}, splitAncestorWithClass: function(r, h, u) {
|
|
1586
|
-
var
|
|
1587
|
-
|
|
1586
|
+
var w = this.getSelfOrAncestorWithClass(r);
|
|
1587
|
+
w && p(w, r, h, u);
|
|
1588
1588
|
}, undoToAncestor: function(r, h) {
|
|
1589
1589
|
this.isRemovable(r) ? $e(r, h) : H(r, this.className);
|
|
1590
1590
|
}, applyToRange: function(r, h) {
|
|
1591
|
-
var u = this,
|
|
1592
|
-
r.splitBoundariesPreservingPositions(
|
|
1591
|
+
var u = this, w = le((h = h || []) || []);
|
|
1592
|
+
r.splitBoundariesPreservingPositions(w), u.removeEmptyElements && u.removeEmptyContainers(r);
|
|
1593
1593
|
var T = Be(r);
|
|
1594
1594
|
if (T.length) {
|
|
1595
1595
|
g(T, function(v) {
|
|
1596
|
-
u.isIgnorableWhiteSpaceNode(v) || u.getSelfOrAncestorWithClass(v) || !u.isModifiable(v) || u.applyToTextNode(v,
|
|
1596
|
+
u.isIgnorableWhiteSpaceNode(v) || u.getSelfOrAncestorWithClass(v) || !u.isModifiable(v) || u.applyToTextNode(v, w);
|
|
1597
1597
|
});
|
|
1598
1598
|
var O = T[T.length - 1];
|
|
1599
|
-
r.setStartAndEnd(T[0], 0, O, O.length), u.normalize && u.postApply(T, r,
|
|
1599
|
+
r.setStartAndEnd(T[0], 0, O, O.length), u.normalize && u.postApply(T, r, w, !1), ve(h, w);
|
|
1600
1600
|
}
|
|
1601
1601
|
var z = u.getEmptyElements(r);
|
|
1602
1602
|
g(z, function(v) {
|
|
@@ -1609,13 +1609,13 @@ function Fn(_) {
|
|
|
1609
1609
|
var h = e.getSelection(r);
|
|
1610
1610
|
h.setRanges(this.applyToRanges(h.getAllRanges()));
|
|
1611
1611
|
}, undoToRange: function(r, h) {
|
|
1612
|
-
var u = this,
|
|
1613
|
-
r.splitBoundariesPreservingPositions(
|
|
1612
|
+
var u = this, w = le(h = h || []);
|
|
1613
|
+
r.splitBoundariesPreservingPositions(w), u.removeEmptyElements && u.removeEmptyContainers(r, w);
|
|
1614
1614
|
var T, O, z = Be(r), v = z[z.length - 1];
|
|
1615
1615
|
if (z.length) {
|
|
1616
|
-
u.splitAncestorWithClass(r.endContainer, r.endOffset,
|
|
1617
|
-
for (var P = 0, W = z.length; P < W; ++P) T = z[P], (O = u.getSelfOrAncestorWithClass(T)) && u.isModifiable(T) && u.undoToAncestor(O,
|
|
1618
|
-
r.setStartAndEnd(z[0], 0, v, v.length), u.normalize && u.postApply(z, r,
|
|
1616
|
+
u.splitAncestorWithClass(r.endContainer, r.endOffset, w), u.splitAncestorWithClass(r.startContainer, r.startOffset, w);
|
|
1617
|
+
for (var P = 0, W = z.length; P < W; ++P) T = z[P], (O = u.getSelfOrAncestorWithClass(T)) && u.isModifiable(T) && u.undoToAncestor(O, w);
|
|
1618
|
+
r.setStartAndEnd(z[0], 0, v, v.length), u.normalize && u.postApply(z, r, w, !0), ve(h, w);
|
|
1619
1619
|
}
|
|
1620
1620
|
var I = u.getEmptyElements(r);
|
|
1621
1621
|
g(I, function(U) {
|
|
@@ -1631,7 +1631,7 @@ function Fn(_) {
|
|
|
1631
1631
|
if (r.collapsed || r.toString() == "") return !!this.getSelfOrAncestorWithClass(r.commonAncestorContainer);
|
|
1632
1632
|
var h = r.getNodes([3]);
|
|
1633
1633
|
if (h.length) {
|
|
1634
|
-
for (var u,
|
|
1634
|
+
for (var u, w = 0; u = h[w++]; ) if (!this.isIgnorableWhiteSpaceNode(u) && Ae(r, u) && this.isModifiable(u) && !this.getSelfOrAncestorWithClass(u)) return !1;
|
|
1635
1635
|
}
|
|
1636
1636
|
return !0;
|
|
1637
1637
|
}, findEffectiveTextNodes: function(r) {
|
|
@@ -1650,13 +1650,13 @@ function Fn(_) {
|
|
|
1650
1650
|
this.isAppliedToSelection(r) ? this.undoToSelection(r) : this.applyToSelection(r);
|
|
1651
1651
|
}, getElementsWithClassIntersectingRange: function(r) {
|
|
1652
1652
|
var h = [], u = this;
|
|
1653
|
-
return r.getNodes([3], function(
|
|
1654
|
-
var T = u.getSelfOrAncestorWithClass(
|
|
1653
|
+
return r.getNodes([3], function(w) {
|
|
1654
|
+
var T = u.getSelfOrAncestorWithClass(w);
|
|
1655
1655
|
T && !a(h, T) && h.push(T);
|
|
1656
1656
|
}), h;
|
|
1657
1657
|
}, detach: function() {
|
|
1658
1658
|
} }, ue.util = { hasClass: A, addClass: R, removeClass: H, getClass: B, hasSameClasses: de, hasAllClasses: fe, replaceWithOwnChildren: $e, elementsHaveSameNonClassAttributes: Ye, elementHasNonClassAttributes: function(r, h) {
|
|
1659
|
-
for (var u,
|
|
1659
|
+
for (var u, w = 0, T = r.attributes.length; w < T; ++w) if (u = r.attributes[w].name, (!h || !a(h, u)) && r.attributes[w].specified && u != "class") return !0;
|
|
1660
1660
|
return !1;
|
|
1661
1661
|
}, splitNodeAt: p, isEditableElement: _e, isEditingHost: De, isEditable: V }, e.CssClassApplier = e.ClassApplier = ue, e.createClassApplier = function(r, h, u) {
|
|
1662
1662
|
return new ue(r, h, u);
|
|
@@ -1806,7 +1806,7 @@ class jn {
|
|
|
1806
1806
|
var n;
|
|
1807
1807
|
(n = this.holder) == null || n.querySelectorAll(".cdx-alert__message,.cdx-block-quote,.ce-editorjs-x-shiki__textarea").forEach((s) => {
|
|
1808
1808
|
s.getAttribute("data-block-backspace") !== "true" && (s.addEventListener("keydown", (a) => {
|
|
1809
|
-
if (a.code === "Backspace" &&
|
|
1809
|
+
if (a.code === "Backspace" && wn(s)) {
|
|
1810
1810
|
a.preventDefault(), a.stopPropagation();
|
|
1811
1811
|
const c = this.editor.blockManager.currentBlock;
|
|
1812
1812
|
this.blockSelection.selectBlock(c);
|
|
@@ -2683,7 +2683,7 @@ class Ue {
|
|
|
2683
2683
|
return {};
|
|
2684
2684
|
}
|
|
2685
2685
|
}
|
|
2686
|
-
function
|
|
2686
|
+
function rt(_) {
|
|
2687
2687
|
return _.nodeType === Node.ELEMENT_NODE;
|
|
2688
2688
|
}
|
|
2689
2689
|
class me {
|
|
@@ -2743,12 +2743,12 @@ function Ke(_, e = !0) {
|
|
|
2743
2743
|
let t = _;
|
|
2744
2744
|
return _.classList.contains(ke.item) && (t = _.querySelector(`.${ke.itemChildren}`)), t === null ? [] : e ? Array.from(t.querySelectorAll(`:scope > .${ke.item}`)) : Array.from(t.querySelectorAll(`.${ke.item}`));
|
|
2745
2745
|
}
|
|
2746
|
-
function
|
|
2746
|
+
function lt(_) {
|
|
2747
2747
|
return _.querySelector(`.${ke.itemChildren}`);
|
|
2748
2748
|
}
|
|
2749
2749
|
function It(_) {
|
|
2750
2750
|
let e = _;
|
|
2751
|
-
_.classList.contains(ke.item) && (e =
|
|
2751
|
+
_.classList.contains(ke.item) && (e = lt(_)), e !== null && Ke(e).length === 0 && e.remove();
|
|
2752
2752
|
}
|
|
2753
2753
|
function Ft(_) {
|
|
2754
2754
|
return _.querySelector(`.${ke.itemContent}`);
|
|
@@ -2762,13 +2762,13 @@ class Ht {
|
|
|
2762
2762
|
const e = window.getSelection();
|
|
2763
2763
|
if (!e) return null;
|
|
2764
2764
|
let t = e.anchorNode;
|
|
2765
|
-
return t ? (
|
|
2765
|
+
return t ? (rt(t) || (t = t.parentNode), t && rt(t) ? t.closest(`.${ke.item}`) : null) : null;
|
|
2766
2766
|
}
|
|
2767
2767
|
get currentItemLevel() {
|
|
2768
2768
|
const e = this.currentItem;
|
|
2769
2769
|
if (e === null) return null;
|
|
2770
2770
|
let t = e.parentNode, n = 0;
|
|
2771
|
-
for (; t !== null && t !== this.listWrapper; )
|
|
2771
|
+
for (; t !== null && t !== this.listWrapper; ) rt(t) && t.classList.contains(ke.item) && (n += 1), t = t.parentNode;
|
|
2772
2772
|
return n + 1;
|
|
2773
2773
|
}
|
|
2774
2774
|
constructor({ data: e, config: t, api: n, readOnly: s, block: a }, c) {
|
|
@@ -2790,7 +2790,7 @@ class Ht {
|
|
|
2790
2790
|
}
|
|
2791
2791
|
save(e) {
|
|
2792
2792
|
const t = e != null ? e : this.listWrapper, n = (c) => Ke(c).map((g) => {
|
|
2793
|
-
const C =
|
|
2793
|
+
const C = lt(g);
|
|
2794
2794
|
return { content: this.renderer.getItemContent(g), meta: this.renderer.getItemMeta(g), items: C ? n(C) : [] };
|
|
2795
2795
|
}), s = t ? n(t) : [];
|
|
2796
2796
|
let a = { style: this.data.style, meta: {}, items: s };
|
|
@@ -2804,7 +2804,7 @@ class Ht {
|
|
|
2804
2804
|
if (n === null || s === null || (s.insertAdjacentHTML("beforeend", e.items[0].content), this.listWrapper === void 0)) return;
|
|
2805
2805
|
const a = Ke(this.listWrapper);
|
|
2806
2806
|
if (a.length === 0) return;
|
|
2807
|
-
let c =
|
|
2807
|
+
let c = lt(a[a.length - 1]);
|
|
2808
2808
|
const g = e.items.shift();
|
|
2809
2809
|
g !== void 0 && (g.items.length !== 0 && (c === null && (c = this.renderer.renderWrapper(!1)), this.appendItems(g.items, c)), e.items.length > 0 && this.appendItems(e.items, this.listWrapper));
|
|
2810
2810
|
}
|
|
@@ -2853,16 +2853,16 @@ class Ht {
|
|
|
2853
2853
|
backspace(e) {
|
|
2854
2854
|
var n;
|
|
2855
2855
|
const t = this.currentItem;
|
|
2856
|
-
t !== null &&
|
|
2856
|
+
t !== null && wn(t) && ((n = window.getSelection()) == null ? void 0 : n.isCollapsed) !== !1 && (e.stopPropagation(), t.parentNode !== this.listWrapper || t.previousElementSibling !== null ? (e.preventDefault(), this.mergeItemWithPrevious(t)) : this.convertFirstItemToDefaultBlock());
|
|
2857
2857
|
}
|
|
2858
2858
|
shiftTab(e) {
|
|
2859
2859
|
e.stopPropagation(), e.preventDefault(), this.currentItem !== null && this.unshiftItem(this.currentItem);
|
|
2860
2860
|
}
|
|
2861
2861
|
unshiftItem(e) {
|
|
2862
|
-
if (!e.parentNode || !
|
|
2862
|
+
if (!e.parentNode || !rt(e.parentNode)) return;
|
|
2863
2863
|
const t = e.parentNode.closest(`.${ke.item}`);
|
|
2864
2864
|
if (!t) return;
|
|
2865
|
-
let n =
|
|
2865
|
+
let n = lt(e);
|
|
2866
2866
|
if (e.parentElement === null) return;
|
|
2867
2867
|
const s = Ot(e);
|
|
2868
2868
|
s !== null && (n === null && (n = this.renderer.renderWrapper(!1)), s.forEach((a) => {
|
|
@@ -2894,9 +2894,9 @@ class Ht {
|
|
|
2894
2894
|
mergeItemWithPrevious(e) {
|
|
2895
2895
|
var M;
|
|
2896
2896
|
const t = e.previousElementSibling, n = e.parentNode;
|
|
2897
|
-
if (n === null || !
|
|
2897
|
+
if (n === null || !rt(n)) return;
|
|
2898
2898
|
const s = n.closest(`.${ke.item}`);
|
|
2899
|
-
if (!t && !s || t && !
|
|
2899
|
+
if (!t && !s || t && !rt(t)) return;
|
|
2900
2900
|
let a;
|
|
2901
2901
|
if (t) {
|
|
2902
2902
|
const A = Ke(t, !1);
|
|
@@ -2910,12 +2910,12 @@ class Ht {
|
|
|
2910
2910
|
g.insertAdjacentHTML("beforeend", c);
|
|
2911
2911
|
const C = Ke(e);
|
|
2912
2912
|
if (C.length === 0) return e.remove(), void It(a);
|
|
2913
|
-
const E = t || s, b = (M =
|
|
2913
|
+
const E = t || s, b = (M = lt(E)) != null ? M : this.renderer.renderWrapper(!1);
|
|
2914
2914
|
t ? C.forEach((A) => {
|
|
2915
2915
|
b.appendChild(A);
|
|
2916
2916
|
}) : C.forEach((A) => {
|
|
2917
2917
|
b.prepend(A);
|
|
2918
|
-
}),
|
|
2918
|
+
}), lt(E) === null && a.appendChild(b), e.remove();
|
|
2919
2919
|
}
|
|
2920
2920
|
addTab(e) {
|
|
2921
2921
|
var a;
|
|
@@ -2927,8 +2927,8 @@ class Ht {
|
|
|
2927
2927
|
if (c !== null && c === this.config.maxLevel) return;
|
|
2928
2928
|
}
|
|
2929
2929
|
const n = t.previousSibling;
|
|
2930
|
-
if (n === null || !
|
|
2931
|
-
const s =
|
|
2930
|
+
if (n === null || !rt(n)) return;
|
|
2931
|
+
const s = lt(n);
|
|
2932
2932
|
if (s)
|
|
2933
2933
|
s.appendChild(t), Ke(t).forEach((c) => {
|
|
2934
2934
|
s.appendChild(c);
|
|
@@ -3298,7 +3298,7 @@ class ei {
|
|
|
3298
3298
|
return n.push(s), n;
|
|
3299
3299
|
}
|
|
3300
3300
|
setEventListeners() {
|
|
3301
|
-
const { holder: e } = this, { shortcuts: t } = this.config, { undo: n, redo: s } = t, a = n.map((R) => R.replace(/ /g, "").split("+")), c = s.map((R) => R.replace(/ /g, "").split("+")), g = a.map((R) => this.parseKeys(R)), C = c.map((R) => this.parseKeys(R)), E = (R, H) => H.reduce((B, G) => B || ((ie, de) => de.length === 3 && ie[de[0]] && ie[de[1]] && ie.key.toLowerCase() === de[2])(R, G), !1), b = (R, H, B) => !(!((G, ie) => ie.reduce((de, fe) => de || ((q,
|
|
3301
|
+
const { holder: e } = this, { shortcuts: t } = this.config, { undo: n, redo: s } = t, a = n.map((R) => R.replace(/ /g, "").split("+")), c = s.map((R) => R.replace(/ /g, "").split("+")), g = a.map((R) => this.parseKeys(R)), C = c.map((R) => this.parseKeys(R)), E = (R, H) => H.reduce((B, G) => B || ((ie, de) => de.length === 3 && ie[de[0]] && ie[de[1]] && ie.key.toLowerCase() === de[2])(R, G), !1), b = (R, H, B) => !(!((G, ie) => ie.reduce((de, fe) => de || ((q, we) => we.length === 2 && q[we[0]] && q.key.toLowerCase() === we[1])(G, fe), !1))(R, H) || E(R, B)) || !!E(R, H), M = (R) => {
|
|
3302
3302
|
b(R, g, C) && (R.preventDefault(), this.undo());
|
|
3303
3303
|
}, A = (R) => {
|
|
3304
3304
|
b(R, C, g) && (R.preventDefault(), this.redo());
|
|
@@ -3791,7 +3791,7 @@ class tt {
|
|
|
3791
3791
|
(e = this.popover) == null || e.close(), this.wrapper.classList.remove(tt.CSS.toolboxShowed);
|
|
3792
3792
|
}
|
|
3793
3793
|
}
|
|
3794
|
-
const gn = "tc-wrap", ti = "tc-wrap--readonly", fn = "tc-table",
|
|
3794
|
+
const gn = "tc-wrap", ti = "tc-wrap--readonly", fn = "tc-table", ot = "tc-row", mn = "tc-table--heading", Dt = "tc-row--selected", at = "tc-cell", Pt = "tc-cell--selected", zt = "tc-add-row", vn = "tc-add-row--disabled", Wt = "tc-add-column", Cn = "tc-add-column--disabled";
|
|
3795
3795
|
class ni {
|
|
3796
3796
|
constructor(e, t, n, s) {
|
|
3797
3797
|
this.minCellWidhth = 50, this.defaultCellWidth = 100, this.handleDocumentMousedown = (a) => {
|
|
@@ -3824,8 +3824,8 @@ class ni {
|
|
|
3824
3824
|
}
|
|
3825
3825
|
getCellInCol(e) {
|
|
3826
3826
|
const t = [];
|
|
3827
|
-
return this.table.querySelectorAll(`.${
|
|
3828
|
-
const s = n.querySelector(`.${
|
|
3827
|
+
return this.table.querySelectorAll(`.${ot}`).forEach((n) => {
|
|
3828
|
+
const s = n.querySelector(`.${at}:nth-child(${e})`);
|
|
3829
3829
|
s && t.push(s);
|
|
3830
3830
|
}), t;
|
|
3831
3831
|
}
|
|
@@ -3859,16 +3859,16 @@ class ni {
|
|
|
3859
3859
|
this.focusedCell.row !== this.numberOfRows ? (this.focusedCell.row += 1, this.focusCell()) : (this.addRow(), this.focusedCell.row += 1, this.focusCell(), this.updateToolboxesPosition(0, 0));
|
|
3860
3860
|
}
|
|
3861
3861
|
getCell(e, t) {
|
|
3862
|
-
return this.table.querySelectorAll(`.${
|
|
3862
|
+
return this.table.querySelectorAll(`.${ot}:nth-child(${e}) .${at}`)[t - 1];
|
|
3863
3863
|
}
|
|
3864
3864
|
getRow(e) {
|
|
3865
|
-
return this.table.querySelector(`.${
|
|
3865
|
+
return this.table.querySelector(`.${ot}:nth-child(${e})`);
|
|
3866
3866
|
}
|
|
3867
3867
|
getRowByCell(e) {
|
|
3868
3868
|
return e.parentElement;
|
|
3869
3869
|
}
|
|
3870
3870
|
getRowFirstCell(e) {
|
|
3871
|
-
return e.querySelector(`.${
|
|
3871
|
+
return e.querySelector(`.${at}:first-child`);
|
|
3872
3872
|
}
|
|
3873
3873
|
setCellContent(e, t, n) {
|
|
3874
3874
|
this.getCell(e, t).innerHTML = n;
|
|
@@ -3889,7 +3889,7 @@ class ni {
|
|
|
3889
3889
|
(a = this.config) != null && a.maxcols && this.numberOfColumns > this.config.maxcols - 1 && s && s.classList.add(Cn), this.addHeadingAttrToFirstRow(), this.colWidthArr.splice(e - 1, 0, this.defaultCellWidth);
|
|
3890
3890
|
}
|
|
3891
3891
|
addRow(e = -1, t = !1) {
|
|
3892
|
-
let n, s = He("div",
|
|
3892
|
+
let n, s = He("div", ot);
|
|
3893
3893
|
this.tunes.withHeadings && this.removeHeadingAttrFromFirstRow();
|
|
3894
3894
|
let a = this.numberOfColumns;
|
|
3895
3895
|
if (this.config && this.config.maxrows && this.numberOfRows >= this.config.maxrows) return;
|
|
@@ -3941,13 +3941,13 @@ class ni {
|
|
|
3941
3941
|
}
|
|
3942
3942
|
}
|
|
3943
3943
|
createCell() {
|
|
3944
|
-
return He("div",
|
|
3944
|
+
return He("div", at, { contentEditable: !this.readOnly });
|
|
3945
3945
|
}
|
|
3946
3946
|
get numberOfRows() {
|
|
3947
3947
|
return this.table.childElementCount;
|
|
3948
3948
|
}
|
|
3949
3949
|
get numberOfColumns() {
|
|
3950
|
-
return this.numberOfRows ? this.table.querySelectorAll(`.${
|
|
3950
|
+
return this.numberOfRows ? this.table.querySelectorAll(`.${ot}:first-child .${at}`).length : 0;
|
|
3951
3951
|
}
|
|
3952
3952
|
get isColumnMenuShowing() {
|
|
3953
3953
|
return this.selectedColumn !== 0;
|
|
@@ -3974,7 +3974,7 @@ class ni {
|
|
|
3974
3974
|
}
|
|
3975
3975
|
focusInTableListener(e) {
|
|
3976
3976
|
const t = e.target, n = this.getRowByCell(t);
|
|
3977
|
-
n && (this.focusedCell = { row: Array.from(this.table.querySelectorAll(`.${
|
|
3977
|
+
n && (this.focusedCell = { row: Array.from(this.table.querySelectorAll(`.${ot}`)).indexOf(n) + 1, column: Array.from(n.querySelectorAll(`.${at}`)).indexOf(t) + 1 });
|
|
3978
3978
|
}
|
|
3979
3979
|
hideToolboxes() {
|
|
3980
3980
|
this.hideRowToolbox(), this.hideColumnToolbox(), this.updateToolboxesPosition();
|
|
@@ -4078,7 +4078,7 @@ class ni {
|
|
|
4078
4078
|
getData() {
|
|
4079
4079
|
const e = [];
|
|
4080
4080
|
for (let t = 1; t <= this.numberOfRows; t++) {
|
|
4081
|
-
const n = this.table.querySelector(`.${
|
|
4081
|
+
const n = this.table.querySelector(`.${ot}:nth-child(${t})`), s = Array.from(n.querySelectorAll(`.${at}`));
|
|
4082
4082
|
s.every((a) => !a.textContent.trim()) || e.push(s.map((a) => a.innerHTML));
|
|
4083
4083
|
}
|
|
4084
4084
|
return e;
|
|
@@ -4194,8 +4194,8 @@ class ri {
|
|
|
4194
4194
|
let fe = document.createElement("INPUT");
|
|
4195
4195
|
fe.type = "file", B.multiple && fe.setAttribute("multiple", "multiple"), B.accept && fe.setAttribute("accept", B.accept), fe.style.display = "none", document.body.appendChild(fe), fe.addEventListener("change", (q) => {
|
|
4196
4196
|
G = !1;
|
|
4197
|
-
const
|
|
4198
|
-
ie(
|
|
4197
|
+
const we = q.target.files;
|
|
4198
|
+
ie(we), document.body.removeChild(fe);
|
|
4199
4199
|
}, !1), window.addEventListener("focus", () => {
|
|
4200
4200
|
setTimeout(() => {
|
|
4201
4201
|
G && ie([]);
|
|
@@ -4532,13 +4532,13 @@ class oi {
|
|
|
4532
4532
|
this.setTune(e);
|
|
4533
4533
|
}
|
|
4534
4534
|
}
|
|
4535
|
-
class
|
|
4535
|
+
class ct {
|
|
4536
4536
|
constructor(e, t) {
|
|
4537
4537
|
this.styleTypeClass = { bold: "cel-inline-bold", italic: "cel-inline-italic", code: "cel-inline-code", underline: "cel-inline-underline", color: "cel-inline-color", mark: "cel-inline-mark", link: "cel-inline-link", strikethrough: "cel-inline-strikethrough" }, this.saveSel = null, this.type = e, this.tag = e == "link" ? "A" : "SPAN", this.rangy = t;
|
|
4538
4538
|
const n = t.modules.ClassApplier;
|
|
4539
4539
|
if (t.supported && n && n.supported) {
|
|
4540
4540
|
const s = { elementTagName: this.tag, ignoreWhiteSpace: !0, applyToEditableOnly: !0, tagNames: [this.tag], normalize: !0, useExistingElements: !0 };
|
|
4541
|
-
this.applier = t.createClassApplier(this.styleTypeClass[this.type], s);
|
|
4541
|
+
this.applier = t.createClassApplier(this.styleTypeClass[this.type], s), this.fakeBackgroundApplier = t.createClassApplier("cel-fake-background", { elementTagName: "span", tagNames: ["span"], normalize: !1, useExistingElements: !1 });
|
|
4542
4542
|
}
|
|
4543
4543
|
}
|
|
4544
4544
|
surround() {
|
|
@@ -4552,10 +4552,7 @@ class nt {
|
|
|
4552
4552
|
}
|
|
4553
4553
|
fakeBackground(e = !1) {
|
|
4554
4554
|
const t = this.rangy.modules.ClassApplier;
|
|
4555
|
-
|
|
4556
|
-
const n = { elementTagName: "span", tagNames: ["span"], normalize: !1, useExistingElements: !1 }, s = this.rangy.createClassApplier("cel-fake-background", n);
|
|
4557
|
-
e ? s.undoToSelection() : s.applyToSelection();
|
|
4558
|
-
}
|
|
4555
|
+
this.rangy.supported && t && t.supported && (e ? this.fakeBackgroundApplier.undoToSelection() : this.fakeBackgroundApplier.applyToSelection());
|
|
4559
4556
|
}
|
|
4560
4557
|
wrapByPropertys(e) {
|
|
4561
4558
|
const t = this.rangy.modules.ClassApplier;
|
|
@@ -4571,28 +4568,6 @@ class nt {
|
|
|
4571
4568
|
this.rangy.createClassApplier(this.styleTypeClass[this.type], n).undoToSelection();
|
|
4572
4569
|
}
|
|
4573
4570
|
}
|
|
4574
|
-
wrapColor(e, t) {
|
|
4575
|
-
const n = this.rangy.modules.ClassApplier;
|
|
4576
|
-
if (this.rangy.supported && n && n.supported) {
|
|
4577
|
-
const s = { elementTagName: this.tag, ignoreWhiteSpace: !0, applyToEditableOnly: !0, tagNames: [this.tag], normalize: !0, useExistingElements: !1 };
|
|
4578
|
-
this.rangy.createClassApplier(e, s).applyToSelection();
|
|
4579
|
-
}
|
|
4580
|
-
}
|
|
4581
|
-
unWrapColorAll(e) {
|
|
4582
|
-
const t = { elementTagName: this.tag, ignoreWhiteSpace: !0, applyToEditableOnly: !0, tagNames: [this.tag], normalize: !0, useExistingElements: !1 };
|
|
4583
|
-
for (let [n, s] of Object.entries(e))
|
|
4584
|
-
n !== "none" && this.rangy.createClassApplier(s, t).undoToSelection();
|
|
4585
|
-
}
|
|
4586
|
-
findStateColor(e) {
|
|
4587
|
-
let t = "";
|
|
4588
|
-
const n = { elementTagName: this.tag, ignoreWhiteSpace: !0, applyToEditableOnly: !0, tagNames: [this.tag], normalize: !0, useExistingElements: !1 };
|
|
4589
|
-
for (let [s, a] of Object.entries(e))
|
|
4590
|
-
if (this.rangy.createClassApplier(a, n).isAppliedToSelection()) {
|
|
4591
|
-
t = a;
|
|
4592
|
-
break;
|
|
4593
|
-
}
|
|
4594
|
-
return t;
|
|
4595
|
-
}
|
|
4596
4571
|
checkState() {
|
|
4597
4572
|
return this.applier.isAppliedToSelection();
|
|
4598
4573
|
}
|
|
@@ -4613,7 +4588,7 @@ class nt {
|
|
|
4613
4588
|
}
|
|
4614
4589
|
class ai {
|
|
4615
4590
|
constructor({ api: e, config: t }) {
|
|
4616
|
-
this.api = e, this.button = null, this.iconClasses = { base: this.api.styles.inlineToolButton, active: this.api.styles.inlineToolButtonActive }, this.inlineToolUtils = new
|
|
4591
|
+
this.api = e, this.button = null, this.iconClasses = { base: this.api.styles.inlineToolButton, active: this.api.styles.inlineToolButtonActive }, this.inlineToolUtils = new ct("bold", t.rangy);
|
|
4617
4592
|
}
|
|
4618
4593
|
static get isInline() {
|
|
4619
4594
|
return !0;
|
|
@@ -4638,7 +4613,7 @@ class ai {
|
|
|
4638
4613
|
}
|
|
4639
4614
|
class li {
|
|
4640
4615
|
constructor({ api: e, config: t }) {
|
|
4641
|
-
this.api = e, this.button = null, this.iconClasses = { base: this.api.styles.inlineToolButton, active: this.api.styles.inlineToolButtonActive }, this.inlineToolUtils = new
|
|
4616
|
+
this.api = e, this.button = null, this.iconClasses = { base: this.api.styles.inlineToolButton, active: this.api.styles.inlineToolButtonActive }, this.inlineToolUtils = new ct("strikethrough", t.rangy);
|
|
4642
4617
|
}
|
|
4643
4618
|
static get isInline() {
|
|
4644
4619
|
return !0;
|
|
@@ -4663,7 +4638,7 @@ class li {
|
|
|
4663
4638
|
}
|
|
4664
4639
|
class ci {
|
|
4665
4640
|
constructor({ api: e, config: t }) {
|
|
4666
|
-
this.api = e, this.button = null, this.iconClasses = { base: this.api.styles.inlineToolButton, active: this.api.styles.inlineToolButtonActive }, this.inlineToolUtils = new
|
|
4641
|
+
this.api = e, this.button = null, this.iconClasses = { base: this.api.styles.inlineToolButton, active: this.api.styles.inlineToolButtonActive }, this.inlineToolUtils = new ct("italic", t.rangy);
|
|
4667
4642
|
}
|
|
4668
4643
|
static get isInline() {
|
|
4669
4644
|
return !0;
|
|
@@ -4688,7 +4663,7 @@ class ci {
|
|
|
4688
4663
|
}
|
|
4689
4664
|
class di {
|
|
4690
4665
|
constructor({ api: e, config: t }) {
|
|
4691
|
-
this.api = e, this.button = null, this.iconClasses = { base: this.api.styles.inlineToolButton, active: this.api.styles.inlineToolButtonActive }, this.inlineToolUtils = new
|
|
4666
|
+
this.api = e, this.button = null, this.iconClasses = { base: this.api.styles.inlineToolButton, active: this.api.styles.inlineToolButtonActive }, this.inlineToolUtils = new ct("code", t.rangy);
|
|
4692
4667
|
}
|
|
4693
4668
|
static get isInline() {
|
|
4694
4669
|
return !0;
|
|
@@ -4713,7 +4688,7 @@ class di {
|
|
|
4713
4688
|
}
|
|
4714
4689
|
class hi {
|
|
4715
4690
|
constructor({ api: e, config: t }) {
|
|
4716
|
-
this.api = e, this.button = null, this.iconClasses = { base: this.api.styles.inlineToolButton, active: this.api.styles.inlineToolButtonActive }, this.inlineToolUtils = new
|
|
4691
|
+
this.api = e, this.button = null, this.iconClasses = { base: this.api.styles.inlineToolButton, active: this.api.styles.inlineToolButtonActive }, this.inlineToolUtils = new ct("underline", t.rangy);
|
|
4717
4692
|
}
|
|
4718
4693
|
static get isInline() {
|
|
4719
4694
|
return !0;
|
|
@@ -4738,7 +4713,7 @@ class hi {
|
|
|
4738
4713
|
}
|
|
4739
4714
|
class ui {
|
|
4740
4715
|
constructor({ api: e, config: t }) {
|
|
4741
|
-
this.api = e, this.button = null, this.iconClasses = { base: this.api.styles.inlineToolButton, active: this.api.styles.inlineToolButtonActive }, this.inlineToolUtils = new
|
|
4716
|
+
this.api = e, this.button = null, this.iconClasses = { base: this.api.styles.inlineToolButton, active: this.api.styles.inlineToolButtonActive }, this.inlineToolUtils = new ct("mark", t.rangy);
|
|
4742
4717
|
}
|
|
4743
4718
|
static get isInline() {
|
|
4744
4719
|
return !0;
|
|
@@ -4760,7 +4735,7 @@ class ui {
|
|
|
4760
4735
|
}
|
|
4761
4736
|
class pi {
|
|
4762
4737
|
constructor({ api: e, config: t }) {
|
|
4763
|
-
this.input = null, this.okbtn = null, this.ENTER_KEY = 13, this.inputOpened = !1, this.isFakeBackgroundEnabled = !1, this.api = e, this.button = null, this.i18n = e.i18n, this.rangy = t.rangy, this.iconClasses = { base: this.api.styles.inlineToolButton, active: this.api.styles.inlineToolButtonActive }, this.inlineToolUtils = new
|
|
4738
|
+
this.input = null, this.okbtn = null, this.ENTER_KEY = 13, this.inputOpened = !1, this.isFakeBackgroundEnabled = !1, this.api = e, this.button = null, this.i18n = e.i18n, this.rangy = t.rangy, this.iconClasses = { base: this.api.styles.inlineToolButton, active: this.api.styles.inlineToolButtonActive }, this.inlineToolUtils = new ct("link", t.rangy);
|
|
4764
4739
|
}
|
|
4765
4740
|
static get isInline() {
|
|
4766
4741
|
return !0;
|
|
@@ -4835,44 +4810,81 @@ class pi {
|
|
|
4835
4810
|
}
|
|
4836
4811
|
class gi {
|
|
4837
4812
|
constructor({ api: e, config: t }) {
|
|
4838
|
-
this.colors = { none: "inherit", "#646a73": "cel-inline-gray-text", "#d83931": "cel-inline-pink-text", "#de7802": "cel-inline-orange-text", "#dc9b04": "cel-inline-yellow-text", "#2ea121": "cel-inline-green-text", "#245bdb": "cel-inline-blue-text", "#6425d0": "cel-inline-purple-text" }, this.columns = 4, this.
|
|
4813
|
+
this.colors = { none: "inherit", "#646a73": "cel-inline-gray-text", "#d83931": "cel-inline-pink-text", "#de7802": "cel-inline-orange-text", "#dc9b04": "cel-inline-yellow-text", "#2ea121": "cel-inline-green-text", "#245bdb": "cel-inline-blue-text", "#6425d0": "cel-inline-purple-text" }, this.columns = 4, this.hidenInput = null, this.saveSel = null, this.colorOpened = !1, this.api = e, this.button = null, this.iconClasses = { base: this.api.styles.inlineToolButton, active: this.api.styles.inlineToolButtonActive }, t.colors && (this.colors = t.colors), t.columns && (this.columns = t.columns), this.rangy = t.rangy;
|
|
4839
4814
|
}
|
|
4840
4815
|
static get isInline() {
|
|
4841
4816
|
return !0;
|
|
4842
4817
|
}
|
|
4843
4818
|
render() {
|
|
4844
|
-
return this.button = document.createElement("button"), this.button.setAttribute("type", "button"), this.button.classList.add(this.iconClasses.base), this.button.innerHTML = '<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.24296 11.4075C5.23167 10.6253 5.52446 9.8395 6.12132 9.24264L9.65686 5.70711C10.0474 5.31658 10.6809 5.31693 11.0714 5.70745L16.0205 10.6565C16.2268 10.8629 16.3243 11.1371 16.3126 11.4075M5.24296 11.4075C5.25382 12.1607 5.54661 12.9106 6.12132 13.4853L8 15.364M5.24296 11.4075H11.9565M16.3126 11.4075C16.3022 11.6487 16.205 11.8869 16.0208 12.0711L12.4853 15.6066C11.3137 16.7782 9.41421 16.7782 8.24264 15.6066L8 15.364M16.3126 11.4075H11.9565M8 15.364L11.9565 11.4075"/><path stroke="currentColor" stroke-width="2" d="M20 17.4615C20 18.3112 19.3284 19 18.5 19C17.6716 19 17 18.3112 17 17.4615C17 16.6119 17.9 15.6154 18.5 15C19.1 15.6154 20 16.6119 20 17.4615Z"/></svg>', this.button
|
|
4845
|
-
e.preventDefault();
|
|
4846
|
-
}), this.button;
|
|
4819
|
+
return this.button = document.createElement("button"), this.button.setAttribute("type", "button"), this.button.classList.add(this.iconClasses.base), this.button.innerHTML = '<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.24296 11.4075C5.23167 10.6253 5.52446 9.8395 6.12132 9.24264L9.65686 5.70711C10.0474 5.31658 10.6809 5.31693 11.0714 5.70745L16.0205 10.6565C16.2268 10.8629 16.3243 11.1371 16.3126 11.4075M5.24296 11.4075C5.25382 12.1607 5.54661 12.9106 6.12132 13.4853L8 15.364M5.24296 11.4075H11.9565M16.3126 11.4075C16.3022 11.6487 16.205 11.8869 16.0208 12.0711L12.4853 15.6066C11.3137 16.7782 9.41421 16.7782 8.24264 15.6066L8 15.364M16.3126 11.4075H11.9565M8 15.364L11.9565 11.4075"/><path stroke="currentColor" stroke-width="2" d="M20 17.4615C20 18.3112 19.3284 19 18.5 19C17.6716 19 17 18.3112 17 17.4615C17 16.6119 17.9 15.6154 18.5 15C19.1 15.6154 20 16.6119 20 17.4615Z"/></svg>', this.button;
|
|
4847
4820
|
}
|
|
4848
4821
|
renderActions() {
|
|
4849
4822
|
const e = document.createElement("div");
|
|
4850
|
-
|
|
4851
|
-
|
|
4852
|
-
|
|
4853
|
-
|
|
4854
|
-
this.
|
|
4855
|
-
|
|
4856
|
-
|
|
4857
|
-
|
|
4858
|
-
|
|
4859
|
-
|
|
4860
|
-
|
|
4861
|
-
|
|
4823
|
+
if (!this.findStateColor()) {
|
|
4824
|
+
e.classList.add("editorjs__color-selector-container"), e.style.gridTemplateColumns = `repeat(${this.columns}, 1fr)`;
|
|
4825
|
+
for (let [t, n] of Object.entries(this.colors)) {
|
|
4826
|
+
const s = document.createElement("div");
|
|
4827
|
+
this.api.tooltip.onHover(s, this.api.i18n.t(t)), s.classList.add("editorjs__color-selector__container-item"), s.style.backgroundColor = t, t == "none" && s.classList.add("editorjs__color-selector__container-item-none"), s.onclick = (a) => {
|
|
4828
|
+
var c = this.rangy.modules.SaveRestore;
|
|
4829
|
+
this.rangy.supported && c && c.supported && this.saveSel && this.rangy.restoreSelection(this.saveSel), this.unWrapColorAll(), a.currentTarget.classList.contains("editorjs__color-selector__container-item-none") || this.wrapColor(n);
|
|
4830
|
+
}, e.append(s);
|
|
4831
|
+
}
|
|
4832
|
+
e.addEventListener("click", (t) => {
|
|
4833
|
+
t.stopPropagation(), t.preventDefault();
|
|
4834
|
+
}), this.hidenInput = document.createElement("input"), this.hidenInput.style.opacity = "0", this.hidenInput.style.width = "0px", this.hidenInput.style.height = "0px", e.append(this.hidenInput);
|
|
4835
|
+
}
|
|
4836
|
+
return e;
|
|
4862
4837
|
}
|
|
4863
4838
|
surround(e) {
|
|
4864
|
-
|
|
4839
|
+
if (this.findStateColor()) this.unWrapColorAll();
|
|
4840
|
+
else if (!this.colorOpened) {
|
|
4841
|
+
var t = this.rangy.modules.SaveRestore;
|
|
4842
|
+
this.rangy.supported && t && t.supported && (this.saveSel = this.rangy.saveSelection()), this.openActions();
|
|
4843
|
+
}
|
|
4844
|
+
}
|
|
4845
|
+
openActions() {
|
|
4846
|
+
var e;
|
|
4847
|
+
(e = this.hidenInput) == null || e.focus(), this.colorOpened = !0;
|
|
4865
4848
|
}
|
|
4866
4849
|
checkState() {
|
|
4867
4850
|
var n;
|
|
4868
|
-
|
|
4869
|
-
const e = this.inlineToolUtils.findStateColor(this.colors);
|
|
4851
|
+
const e = this.findStateColor();
|
|
4870
4852
|
let t = !1;
|
|
4871
|
-
return e && e !== "" && (t = !0), (n = this.button) == null || n.classList.toggle(this.iconClasses.active, t),
|
|
4853
|
+
return e && e !== "" && (t = !0), (n = this.button) == null || n.classList.toggle(this.iconClasses.active, t), t;
|
|
4872
4854
|
}
|
|
4873
4855
|
static get sanitize() {
|
|
4874
4856
|
return { span: { class: !0, style: !0 } };
|
|
4875
4857
|
}
|
|
4858
|
+
unWrapColorAll() {
|
|
4859
|
+
const e = { elementTagName: "span", ignoreWhiteSpace: !0, applyToEditableOnly: !0, tagNames: ["span"], normalize: !0, useExistingElements: !1 };
|
|
4860
|
+
for (let [t, n] of Object.entries(this.colors))
|
|
4861
|
+
t !== "none" && this.rangy.createClassApplier(n, e).undoToSelection();
|
|
4862
|
+
}
|
|
4863
|
+
wrapColor(e) {
|
|
4864
|
+
const t = this.rangy.modules.ClassApplier;
|
|
4865
|
+
if (this.rangy.supported && t && t.supported) {
|
|
4866
|
+
const n = { elementTagName: "span", ignoreWhiteSpace: !0, applyToEditableOnly: !0, tagNames: ["span"], normalize: !0, useExistingElements: !1 };
|
|
4867
|
+
this.rangy.createClassApplier(e, n).applyToSelection();
|
|
4868
|
+
}
|
|
4869
|
+
}
|
|
4870
|
+
findStateColor() {
|
|
4871
|
+
let e = "";
|
|
4872
|
+
const t = { elementTagName: "span", ignoreWhiteSpace: !0, applyToEditableOnly: !0, tagNames: ["span"], normalize: !0, useExistingElements: !1 };
|
|
4873
|
+
for (let [n] of Object.entries(this.colors))
|
|
4874
|
+
if (this.rangy.createClassApplier(n, t).isAppliedToSelection()) {
|
|
4875
|
+
e = n;
|
|
4876
|
+
break;
|
|
4877
|
+
}
|
|
4878
|
+
return e;
|
|
4879
|
+
}
|
|
4880
|
+
closeActions() {
|
|
4881
|
+
if (!this.colorOpened) return;
|
|
4882
|
+
const e = this.rangy.saveSelection();
|
|
4883
|
+
this.colorOpened = !1, this.rangy.restoreSelection(e), this.rangy.getSelection().removeAllRanges();
|
|
4884
|
+
}
|
|
4885
|
+
clear() {
|
|
4886
|
+
this.closeActions();
|
|
4887
|
+
}
|
|
4876
4888
|
}
|
|
4877
4889
|
const fi = { class: "ebl-editor", id: "holder" }, mi = xn({ name: "EblEditor", inheritAttrs: !1, __name: "Editor", props: { readOnly: { type: Boolean, default: !1 }, placeholder: { default: "Enter something" }, data: { default: () => ({ blocks: [] }) }, locale: { default: {} }, tokenInfo: { default: { token: "", tokenName: "Authorization", tokenPrefix: "Bearer" } } }, emits: ["onReady", "onChange"], setup(_, { expose: e, emit: t }) {
|
|
4878
4890
|
let n = Wn();
|
|
@@ -4882,7 +4894,7 @@ const fi = { class: "ebl-editor", id: "holder" }, mi = xn({ name: "EblEditor", i
|
|
|
4882
4894
|
function q(V, re) {
|
|
4883
4895
|
return (re || document).getElementById(V);
|
|
4884
4896
|
}
|
|
4885
|
-
function
|
|
4897
|
+
function we(V, re) {
|
|
4886
4898
|
var Q, ae = "selectionBoundary_" + +/* @__PURE__ */ new Date() + "_" + ("" + Math.random()).slice(2), le = ie.getDocument(V.startContainer), ve = V.cloneRange();
|
|
4887
4899
|
return ve.collapse(re), (Q = le.createElement("span")).id = ae, Q.style.lineHeight = "0", Q.style.display = "none", Q.className = "rangySelectionBoundary", Q.appendChild(le.createTextNode("\uFEFF")), ve.insertNode(Q), Q;
|
|
4888
4900
|
}
|
|
@@ -4895,7 +4907,7 @@ const fi = { class: "ebl-editor", id: "holder" }, mi = xn({ name: "EblEditor", i
|
|
|
4895
4907
|
}
|
|
4896
4908
|
function Be(V, re) {
|
|
4897
4909
|
var Q, ae = B.DomRange.getRangeDocument(V), le = V.toString(), ve = fe(re);
|
|
4898
|
-
return V.collapsed ? { document: ae, markerId: (Q =
|
|
4910
|
+
return V.collapsed ? { document: ae, markerId: (Q = we(V, !1)).id, collapsed: !0 } : (Q = we(V, !1), { document: ae, startMarkerId: we(V, !0).id, endMarkerId: Q.id, collapsed: !1, backward: ve, toString: function() {
|
|
4899
4911
|
return "original text: '" + le + "', new text: '" + V.toString() + "'";
|
|
4900
4912
|
} });
|
|
4901
4913
|
}
|
|
@@ -4978,13 +4990,13 @@ const fi = { class: "ebl-editor", id: "holder" }, mi = xn({ name: "EblEditor", i
|
|
|
4978
4990
|
C.save().then((G) => H(G));
|
|
4979
4991
|
});
|
|
4980
4992
|
} }), (H, B) => (On(), Mn("div", fi));
|
|
4981
|
-
} }),
|
|
4993
|
+
} }), yn = [mi];
|
|
4982
4994
|
let Tn = [];
|
|
4983
|
-
for (let _ in
|
|
4984
|
-
const e = zn(
|
|
4995
|
+
for (let _ in yn) {
|
|
4996
|
+
const e = zn(yn[_]);
|
|
4985
4997
|
Tn.push(e);
|
|
4986
4998
|
}
|
|
4987
|
-
const Si = { messages: { ui: { blockTunes: { toggler: { "Click to tune": "可拖拽和点击" } }, toolbar: { toolbox: { Add: "添加", Filter: "过滤", "Nothing found": "无内容" }, popover: { Filter: "过滤", "Nothing found": "无内容" } }, popover: { Filter: "筛选", "Nothing found": "未找到任何内容", "Convert to": "转化为", "Add below": "在下方插入" } }, toolNames: { Text: "段落", H1: "一级标题", H2: "二级标题", H3: "三级标题", H4: "四级标题", H5: "五级标题", H6: "六级标题", "Ordered List": "有序列表", "Unordered List": "无序列表", Checklist: "任务列表", Quote: "引用", Code: "代码块", Delimiter: "分割线", Link: "链接", LinkTool: "链接", Bold: "加粗", BoldTool: "粗体", Italic: "倾斜", ItalicTool: "斜体", Alert: "高亮块", indent: "缩进", Marker: "文本高亮", Color: "文本颜色", Underline: "下划线", InlineCode: "行内代码", Table: "表格", Image: "图片", Strikethrough: "删除线" }, 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: "突出显示" }, linkTool: { "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: "已复制", "Unable to copy": "复制失败" }, 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": "右对齐", "Type here...": "输入内容" }, Color: { "#646a73": "灰色", "#d83931": "红色", "#de7802": "橙色", "#dc9b04": "黄色", "#2ea121": "绿色", "#245bdb": "蓝色", "#6425d0": "紫色", none: "恢复默认" } }, 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": "向左缩进" } } } }, En = /* @__PURE__ */ ((_ = []) => ({ version: "2.31.
|
|
4999
|
+
const Si = { messages: { ui: { blockTunes: { toggler: { "Click to tune": "可拖拽和点击" } }, toolbar: { toolbox: { Add: "添加", Filter: "过滤", "Nothing found": "无内容" }, popover: { Filter: "过滤", "Nothing found": "无内容" } }, popover: { Filter: "筛选", "Nothing found": "未找到任何内容", "Convert to": "转化为", "Add below": "在下方插入" } }, toolNames: { Text: "段落", H1: "一级标题", H2: "二级标题", H3: "三级标题", H4: "四级标题", H5: "五级标题", H6: "六级标题", "Ordered List": "有序列表", "Unordered List": "无序列表", Checklist: "任务列表", Quote: "引用", Code: "代码块", Delimiter: "分割线", Link: "链接", LinkTool: "链接", Bold: "加粗", BoldTool: "粗体", Italic: "倾斜", ItalicTool: "斜体", Alert: "高亮块", indent: "缩进", Marker: "文本高亮", Color: "文本颜色", Underline: "下划线", InlineCode: "行内代码", Table: "表格", Image: "图片", Strikethrough: "删除线" }, 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: "突出显示" }, linkTool: { "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: "已复制", "Unable to copy": "复制失败" }, 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": "右对齐", "Type here...": "输入内容" }, Color: { "#646a73": "灰色", "#d83931": "红色", "#de7802": "橙色", "#dc9b04": "黄色", "#2ea121": "绿色", "#245bdb": "蓝色", "#6425d0": "紫色", none: "恢复默认" } }, 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": "向左缩进" } } } }, En = /* @__PURE__ */ ((_ = []) => ({ version: "2.31.54", install: (e, t) => {
|
|
4988
5000
|
e[Kt] || (e[Kt] = !0, _.forEach((n) => e.use(n)), e.provide("EblEditorSettings", t));
|
|
4989
5001
|
} }))(Tn), Ti = En.install, Ei = En.version;
|
|
4990
5002
|
export {
|