@ckeditor/ckeditor5-html-support 36.0.1 → 37.0.0-alpha.1
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/README.md +2 -2
- package/build/html-support.js +1 -1
- package/ckeditor5-metadata.json +2 -2
- package/package.json +42 -36
- package/src/augmentation.d.ts +33 -0
- package/src/augmentation.js +5 -0
- package/src/conversionutils.d.ts +42 -0
- package/src/conversionutils.js +57 -77
- package/src/converters.d.ts +56 -0
- package/src/converters.js +104 -156
- package/src/datafilter.d.ts +250 -0
- package/src/datafilter.js +566 -782
- package/src/dataschema.d.ts +169 -0
- package/src/dataschema.js +143 -229
- package/src/fullpage.d.ts +21 -0
- package/src/fullpage.js +65 -86
- package/src/generalhtmlsupport.d.ts +88 -0
- package/src/generalhtmlsupport.js +244 -327
- package/src/generalhtmlsupportconfig.d.ts +67 -0
- package/src/generalhtmlsupportconfig.js +5 -0
- package/src/htmlcomment.d.ts +72 -0
- package/src/htmlcomment.js +175 -239
- package/src/htmlpagedataprocessor.d.ts +22 -0
- package/src/htmlpagedataprocessor.js +53 -76
- package/src/index.d.ts +25 -0
- package/src/index.js +1 -2
- package/src/integrations/codeblock.d.ts +22 -0
- package/src/integrations/codeblock.js +87 -115
- package/src/integrations/customelement.d.ts +25 -0
- package/src/integrations/customelement.js +127 -160
- package/src/integrations/documentlist.d.ts +26 -0
- package/src/integrations/documentlist.js +154 -191
- package/src/integrations/dualcontent.d.ts +44 -0
- package/src/integrations/dualcontent.js +92 -128
- package/src/integrations/heading.d.ts +25 -0
- package/src/integrations/heading.js +41 -54
- package/src/integrations/image.d.ts +25 -0
- package/src/integrations/image.js +154 -212
- package/src/integrations/integrationutils.d.ts +15 -0
- package/src/integrations/integrationutils.js +21 -0
- package/src/integrations/mediaembed.d.ts +25 -0
- package/src/integrations/mediaembed.js +101 -147
- package/src/integrations/script.d.ts +25 -0
- package/src/integrations/script.js +45 -67
- package/src/integrations/style.d.ts +25 -0
- package/src/integrations/style.js +45 -67
- package/src/integrations/table.d.ts +22 -0
- package/src/integrations/table.js +113 -160
- package/src/schemadefinitions.d.ts +13 -0
- package/src/schemadefinitions.js +846 -835
package/README.md
CHANGED
|
@@ -10,11 +10,11 @@ This package implements the General HTML Support feature for CKEditor 5. It allo
|
|
|
10
10
|
|
|
11
11
|
## Demo
|
|
12
12
|
|
|
13
|
-
Check out the demo in the [General HTML Support feature guide](https://ckeditor.com/docs/ckeditor5/latest/features/general-html-support.html#demo).
|
|
13
|
+
Check out the demo in the [General HTML Support feature guide](https://ckeditor.com/docs/ckeditor5/latest/features/html/general-html-support.html#demo).
|
|
14
14
|
|
|
15
15
|
## Documentation
|
|
16
16
|
|
|
17
|
-
See the [`@ckeditor/ckeditor5-html-support` package](https://ckeditor.com/docs/ckeditor5/latest/api/html-support.html) page as well as the [General HTML Support feature](https://ckeditor.com/docs/ckeditor5/latest/features/general-html-support.html) guide in [CKEditor 5 documentation](https://ckeditor.com/docs/ckeditor5/latest/).
|
|
17
|
+
See the [`@ckeditor/ckeditor5-html-support` package](https://ckeditor.com/docs/ckeditor5/latest/api/html-support.html) page as well as the [General HTML Support feature](https://ckeditor.com/docs/ckeditor5/latest/features/html/general-html-support.html) guide in [CKEditor 5 documentation](https://ckeditor.com/docs/ckeditor5/latest/).
|
|
18
18
|
|
|
19
19
|
## License
|
|
20
20
|
|
package/build/html-support.js
CHANGED
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
/*!
|
|
3
3
|
* @license Copyright (c) 2003-2023, CKSource Holding sp. z o.o. All rights reserved.
|
|
4
4
|
* For licensing, see LICENSE.md.
|
|
5
|
-
*/(()=>{var t={142:(t,e,r)=>{"use strict";r.d(e,{Z:()=>i});var o=r(609),n=r.n(o)()((function(t){return t[1]}));n.push([t.id,":root{--ck-html-object-embed-unfocused-outline-width:1px}.ck-widget.html-object-embed{background-color:var(--ck-color-base-foreground);font-size:var(--ck-font-size-base);min-width:calc(76px + var(--ck-spacing-standard));padding:var(--ck-spacing-small);padding-top:calc(var(--ck-font-size-tiny) + var(--ck-spacing-large))}.ck-widget.html-object-embed:not(.ck-widget_selected):not(:hover){outline:var(--ck-html-object-embed-unfocused-outline-width) dashed var(--ck-color-widget-blurred-border)}.ck-widget.html-object-embed:before{background:#999;border-radius:0 0 var(--ck-border-radius) var(--ck-border-radius);color:var(--ck-color-base-background);content:attr(data-html-object-embed-label);font-family:var(--ck-font-face);font-size:var(--ck-font-size-tiny);font-style:normal;font-weight:400;left:var(--ck-spacing-standard);padding:calc(var(--ck-spacing-tiny) + var(--ck-html-object-embed-unfocused-outline-width)) var(--ck-spacing-small) var(--ck-spacing-tiny);position:absolute;top:0;transition:background var(--ck-widget-handler-animation-duration) var(--ck-widget-handler-animation-curve)}.ck-widget.html-object-embed .ck-widget__type-around .ck-widget__type-around__button.ck-widget__type-around__button_before{margin-left:50px}.ck-widget.html-object-embed .html-object-embed__content{pointer-events:none}div.ck-widget.html-object-embed{margin:1em auto}span.ck-widget.html-object-embed{display:inline-block}",""]);const i=n},609:t=>{"use strict";t.exports=function(t){var e=[];return e.toString=function(){return this.map((function(e){var r=t(e);return e[2]?"@media ".concat(e[2]," {").concat(r,"}"):r})).join("")},e.i=function(t,r,o){"string"==typeof t&&(t=[[null,t,""]]);var n={};if(o)for(var i=0;i<this.length;i++){var s=this[i][0];null!=s&&(n[s]=!0)}for(var l=0;l<t.length;l++){var c=[].concat(t[l]);o&&n[c[0]]||(r&&(c[2]?c[2]="".concat(r," and ").concat(c[2]):c[2]=r),e.push(c))}},e}},62:(t,e,r)=>{"use strict";var o,n=function(){return void 0===o&&(o=Boolean(window&&document&&document.all&&!window.atob)),o},i=function(){var t={};return function(e){if(void 0===t[e]){var r=document.querySelector(e);if(window.HTMLIFrameElement&&r instanceof window.HTMLIFrameElement)try{r=r.contentDocument.head}catch(t){r=null}t[e]=r}return t[e]}}(),s=[];function l(t){for(var e=-1,r=0;r<s.length;r++)if(s[r].identifier===t){e=r;break}return e}function c(t,e){for(var r={},o=[],n=0;n<t.length;n++){var i=t[n],c=e.base?i[0]+e.base:i[0],a=r[c]||0,u="".concat(c," ").concat(a);r[c]=a+1;var m=l(u),d={css:i[1],media:i[2],sourceMap:i[3]};-1!==m?(s[m].references++,s[m].updater(d)):s.push({identifier:u,updater:p(d,e),references:1}),o.push(u)}return o}function a(t){var e=document.createElement("style"),o=t.attributes||{};if(void 0===o.nonce){var n=r.nc;n&&(o.nonce=n)}if(Object.keys(o).forEach((function(t){e.setAttribute(t,o[t])})),"function"==typeof t.insert)t.insert(e);else{var s=i(t.insert||"head");if(!s)throw new Error("Couldn't find a style target. This probably means that the value for the 'insert' parameter is invalid.");s.appendChild(e)}return e}var u,m=(u=[],function(t,e){return u[t]=e,u.filter(Boolean).join("\n")});function d(t,e,r,o){var n=r?"":o.media?"@media ".concat(o.media," {").concat(o.css,"}"):o.css;if(t.styleSheet)t.styleSheet.cssText=m(e,n);else{var i=document.createTextNode(n),s=t.childNodes;s[e]&&t.removeChild(s[e]),s.length?t.insertBefore(i,s[e]):t.appendChild(i)}}function h(t,e,r){var o=r.css,n=r.media,i=r.sourceMap;if(n?t.setAttribute("media",n):t.removeAttribute("media"),i&&"undefined"!=typeof btoa&&(o+="\n/*# sourceMappingURL=data:application/json;base64,".concat(btoa(unescape(encodeURIComponent(JSON.stringify(i))))," */")),t.styleSheet)t.styleSheet.cssText=o;else{for(;t.firstChild;)t.removeChild(t.firstChild);t.appendChild(document.createTextNode(o))}}var f=null,b=0;function p(t,e){var r,o,n;if(e.singleton){var i=b++;r=f||(f=a(e)),o=d.bind(null,r,i,!1),n=d.bind(null,r,i,!0)}else r=a(e),o=h.bind(null,r,e),n=function(){!function(t){if(null===t.parentNode)return!1;t.parentNode.removeChild(t)}(r)};return o(t),function(e){if(e){if(e.css===t.css&&e.media===t.media&&e.sourceMap===t.sourceMap)return;o(t=e)}else n()}}t.exports=function(t,e){(e=e||{}).singleton||"boolean"==typeof e.singleton||(e.singleton=n());var r=c(t=t||[],e);return function(t){if(t=t||[],"[object Array]"===Object.prototype.toString.call(t)){for(var o=0;o<r.length;o++){var n=l(r[o]);s[n].references--}for(var i=c(t,e),a=0;a<r.length;a++){var u=l(r[a]);0===s[u].references&&(s[u].updater(),s.splice(u,1))}r=i}}}},704:(t,e,r)=>{t.exports=r(79)("./src/core.js")},492:(t,e,r)=>{t.exports=r(79)("./src/engine.js")},209:(t,e,r)=>{t.exports=r(79)("./src/utils.js")},995:(t,e,r)=>{t.exports=r(79)("./src/widget.js")},79:t=>{"use strict";t.exports=CKEditor5.dll}},e={};function r(o){var n=e[o];if(void 0!==n)return n.exports;var i=e[o]={id:o,exports:{}};return t[o](i,i.exports,r),i.exports}r.n=t=>{var e=t&&t.__esModule?()=>t.default:()=>t;return r.d(e,{a:e}),e},r.d=(t,e)=>{for(var o in e)r.o(e,o)&&!r.o(t,o)&&Object.defineProperty(t,o,{enumerable:!0,get:e[o]})},r.o=(t,e)=>Object.prototype.hasOwnProperty.call(t,e),r.r=t=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},r.nc=void 0;var o={};(()=>{"use strict";r.r(o),r.d(o,{DataFilter:()=>nn,DataSchema:()=>or,FullPage:()=>fi,GeneralHtmlSupport:()=>ai,HtmlComment:()=>di,HtmlPageDataProcessor:()=>hi});var t=r(704),e=r(209);const n=[{model:"codeBlock",view:"pre"},{model:"paragraph",view:"p"},{model:"blockQuote",view:"blockquote"},{model:"listItem",view:"li"},{model:"pageBreak",view:"div"},{model:"rawHtml",view:"div"},{model:"table",view:"table"},{model:"tableRow",view:"tr"},{model:"tableCell",view:"td"},{model:"tableCell",view:"th"},{model:"caption",view:"caption"},{model:"caption",view:"figcaption"},{model:"imageBlock",view:"img"},{model:"imageInline",view:"img"},{model:"htmlP",view:"p",modelSchema:{inheritAllFrom:"$block"}},{model:"htmlBlockquote",view:"blockquote",modelSchema:{inheritAllFrom:"$container"}},{model:"htmlTable",view:"table",modelSchema:{allowWhere:"$block",isBlock:!0}},{model:"htmlTbody",view:"tbody",modelSchema:{allowIn:"htmlTable",isBlock:!1}},{model:"htmlThead",view:"thead",modelSchema:{allowIn:"htmlTable",isBlock:!1}},{model:"htmlTfoot",view:"tfoot",modelSchema:{allowIn:"htmlTable",isBlock:!1}},{model:"htmlCaption",view:"caption",modelSchema:{allowIn:"htmlTable",allowChildren:"$text",isBlock:!1}},{model:"htmlColgroup",view:"colgroup",modelSchema:{allowIn:"htmlTable",allowChildren:"col",isBlock:!1}},{model:"htmlCol",view:"col",modelSchema:{allowIn:"htmlColgroup",isBlock:!1}},{model:"htmlTr",view:"tr",modelSchema:{allowIn:["htmlTable","htmlThead","htmlTbody"],isLimit:!0}},{model:"htmlTd",view:"td",modelSchema:{allowIn:"htmlTr",allowContentOf:"$container",isLimit:!0,isBlock:!1}},{model:"htmlTh",view:"th",modelSchema:{allowIn:"htmlTr",allowContentOf:"$container",isLimit:!0,isBlock:!1}},{model:"htmlFigure",view:"figure",modelSchema:{inheritAllFrom:"$container",isBlock:!1}},{model:"htmlFigcaption",view:"figcaption",modelSchema:{allowIn:"htmlFigure",allowChildren:"$text",isBlock:!1}},{model:"htmlAddress",view:"address",modelSchema:{inheritAllFrom:"$container",isBlock:!1}},{model:"htmlAside",view:"aside",modelSchema:{inheritAllFrom:"$container",isBlock:!1}},{model:"htmlMain",view:"main",modelSchema:{inheritAllFrom:"$container",isBlock:!1}},{model:"htmlDetails",view:"details",modelSchema:{inheritAllFrom:"$container",isBlock:!1}},{model:"htmlSummary",view:"summary",modelSchema:{allowChildren:"$text",allowIn:"htmlDetails",isBlock:!1}},{model:"htmlDiv",view:"div",paragraphLikeModel:"htmlDivParagraph",modelSchema:{inheritAllFrom:"$container"}},{model:"htmlFieldset",view:"fieldset",modelSchema:{inheritAllFrom:"$container",isBlock:!1}},{model:"htmlLegend",view:"legend",modelSchema:{allowIn:"htmlFieldset",allowChildren:"$text"}},{model:"htmlHeader",view:"header",modelSchema:{inheritAllFrom:"$container",isBlock:!1}},{model:"htmlFooter",view:"footer",modelSchema:{inheritAllFrom:"$container",isBlock:!1}},{model:"htmlForm",view:"form",modelSchema:{inheritAllFrom:"$container",isBlock:!0}},{model:"htmlHgroup",view:"hgroup",modelSchema:{allowChildren:["htmlH1","htmlH2","htmlH3","htmlH4","htmlH5","htmlH6"],isBlock:!1}},{model:"htmlH1",view:"h1",modelSchema:{inheritAllFrom:"$block"}},{model:"htmlH2",view:"h2",modelSchema:{inheritAllFrom:"$block"}},{model:"htmlH3",view:"h3",modelSchema:{inheritAllFrom:"$block"}},{model:"htmlH4",view:"h4",modelSchema:{inheritAllFrom:"$block"}},{model:"htmlH5",view:"h5",modelSchema:{inheritAllFrom:"$block"}},{model:"htmlH6",view:"h6",modelSchema:{inheritAllFrom:"$block"}},{model:"$htmlList",modelSchema:{allowWhere:"$container",allowChildren:["$htmlList","htmlLi"],isBlock:!1}},{model:"htmlDir",view:"dir",modelSchema:{inheritAllFrom:"$htmlList"}},{model:"htmlMenu",view:"menu",modelSchema:{inheritAllFrom:"$htmlList"}},{model:"htmlUl",view:"ul",modelSchema:{inheritAllFrom:"$htmlList"}},{model:"htmlOl",view:"ol",modelSchema:{inheritAllFrom:"$htmlList"}},{model:"htmlLi",view:"li",modelSchema:{allowIn:"$htmlList",allowChildren:"$text",isBlock:!1}},{model:"htmlPre",view:"pre",modelSchema:{inheritAllFrom:"$block"}},{model:"htmlArticle",view:"article",modelSchema:{inheritAllFrom:"$container",isBlock:!1}},{model:"htmlSection",view:"section",modelSchema:{inheritAllFrom:"$container",isBlock:!1}},{model:"htmlNav",view:"nav",modelSchema:{inheritAllFrom:"$container",isBlock:!1}},{model:"htmlDl",view:"dl",modelSchema:{allowWhere:"$container",allowChildren:["htmlDt","htmlDd"],isBlock:!1}},{model:"htmlDt",view:"dt",modelSchema:{allowChildren:"$block",isBlock:!1}},{model:"htmlDd",view:"dd",modelSchema:{allowChildren:"$block",isBlock:!1}},{model:"htmlCenter",view:"center",modelSchema:{inheritAllFrom:"$container",isBlock:!1}}],i=[{model:"htmlAcronym",view:"acronym",attributeProperties:{copyOnEnter:!0}},{model:"htmlTt",view:"tt",attributeProperties:{copyOnEnter:!0}},{model:"htmlFont",view:"font",attributeProperties:{copyOnEnter:!0}},{model:"htmlTime",view:"time",attributeProperties:{copyOnEnter:!0}},{model:"htmlVar",view:"var",attributeProperties:{copyOnEnter:!0}},{model:"htmlBig",view:"big",attributeProperties:{copyOnEnter:!0}},{model:"htmlSmall",view:"small",attributeProperties:{copyOnEnter:!0}},{model:"htmlSamp",view:"samp",attributeProperties:{copyOnEnter:!0}},{model:"htmlQ",view:"q",attributeProperties:{copyOnEnter:!0}},{model:"htmlOutput",view:"output",attributeProperties:{copyOnEnter:!0}},{model:"htmlKbd",view:"kbd",attributeProperties:{copyOnEnter:!0}},{model:"htmlBdi",view:"bdi",attributeProperties:{copyOnEnter:!0}},{model:"htmlBdo",view:"bdo",attributeProperties:{copyOnEnter:!0}},{model:"htmlAbbr",view:"abbr",attributeProperties:{copyOnEnter:!0}},{model:"htmlA",view:"a",priority:5,coupledAttribute:"linkHref",attributeProperties:{copyOnEnter:!0}},{model:"htmlStrong",view:"strong",coupledAttribute:"bold",attributeProperties:{copyOnEnter:!0,isFormatting:!0}},{model:"htmlB",view:"b",coupledAttribute:"bold",attributeProperties:{copyOnEnter:!0,isFormatting:!0}},{model:"htmlI",view:"i",coupledAttribute:"italic",attributeProperties:{copyOnEnter:!0,isFormatting:!0}},{model:"htmlEm",view:"em",coupledAttribute:"italic",attributeProperties:{copyOnEnter:!0,isFormatting:!0}},{model:"htmlS",view:"s",coupledAttribute:"strikethrough",attributeProperties:{copyOnEnter:!0,isFormatting:!0}},{model:"htmlDel",view:"del",coupledAttribute:"strikethrough",attributeProperties:{copyOnEnter:!0}},{model:"htmlIns",view:"ins",attributeProperties:{copyOnEnter:!0}},{model:"htmlU",view:"u",coupledAttribute:"underline",attributeProperties:{copyOnEnter:!0,isFormatting:!0}},{model:"htmlSub",view:"sub",coupledAttribute:"subscript",attributeProperties:{copyOnEnter:!0,isFormatting:!0}},{model:"htmlSup",view:"sup",coupledAttribute:"superscript",attributeProperties:{copyOnEnter:!0,isFormatting:!0}},{model:"htmlCode",view:"code",coupledAttribute:"code",attributeProperties:{copyOnEnter:!0,isFormatting:!0}},{model:"htmlMark",view:"mark",attributeProperties:{copyOnEnter:!0}},{model:"htmlSpan",view:"span",attributeProperties:{copyOnEnter:!0}},{model:"htmlCite",view:"cite",attributeProperties:{copyOnEnter:!0}},{model:"htmlLabel",view:"label",attributeProperties:{copyOnEnter:!0}},{model:"htmlDfn",view:"dfn",attributeProperties:{copyOnEnter:!0}},{model:"htmlObject",view:"object",isObject:!0,modelSchema:{inheritAllFrom:"$inlineObject"}},{model:"htmlIframe",view:"iframe",isObject:!0,modelSchema:{inheritAllFrom:"$inlineObject"}},{model:"htmlInput",view:"input",isObject:!0,modelSchema:{inheritAllFrom:"$inlineObject"}},{model:"htmlButton",view:"button",isObject:!0,modelSchema:{inheritAllFrom:"$inlineObject"}},{model:"htmlTextarea",view:"textarea",isObject:!0,modelSchema:{inheritAllFrom:"$inlineObject"}},{model:"htmlSelect",view:"select",isObject:!0,modelSchema:{inheritAllFrom:"$inlineObject"}},{model:"htmlVideo",view:"video",isObject:!0,modelSchema:{inheritAllFrom:"$inlineObject"}},{model:"htmlEmbed",view:"embed",isObject:!0,modelSchema:{inheritAllFrom:"$inlineObject"}},{model:"htmlOembed",view:"oembed",isObject:!0,modelSchema:{inheritAllFrom:"$inlineObject"}},{model:"htmlAudio",view:"audio",isObject:!0,modelSchema:{inheritAllFrom:"$inlineObject"}},{model:"htmlImg",view:"img",isObject:!0,modelSchema:{inheritAllFrom:"$inlineObject"}},{model:"htmlCanvas",view:"canvas",isObject:!0,modelSchema:{inheritAllFrom:"$inlineObject"}},{model:"htmlMeter",view:"meter",isObject:!0,modelSchema:{inheritAllFrom:"$inlineObject"}},{model:"htmlProgress",view:"progress",isObject:!0,modelSchema:{inheritAllFrom:"$inlineObject"}},{model:"htmlScript",view:"script",modelSchema:{allowWhere:["$text","$block"],isInline:!0}},{model:"htmlStyle",view:"style",modelSchema:{allowWhere:["$text","$block"],isInline:!0}},{model:"htmlCustomElement",view:"$customElement",modelSchema:{allowWhere:["$text","$block"],isInline:!0}}];const s=function(){this.__data__=[],this.size=0};const l=function(t,e){return t===e||t!=t&&e!=e};const c=function(t,e){for(var r=t.length;r--;)if(l(t[r][0],e))return r;return-1};var a=Array.prototype.splice;const u=function(t){var e=this.__data__,r=c(e,t);return!(r<0)&&(r==e.length-1?e.pop():a.call(e,r,1),--this.size,!0)};const m=function(t){var e=this.__data__,r=c(e,t);return r<0?void 0:e[r][1]};const d=function(t){return c(this.__data__,t)>-1};const h=function(t,e){var r=this.__data__,o=c(r,t);return o<0?(++this.size,r.push([t,e])):r[o][1]=e,this};function f(t){var e=-1,r=null==t?0:t.length;for(this.clear();++e<r;){var o=t[e];this.set(o[0],o[1])}}f.prototype.clear=s,f.prototype.delete=u,f.prototype.get=m,f.prototype.has=d,f.prototype.set=h;const b=f;const p=function(){this.__data__=new b,this.size=0};const g=function(t){var e=this.__data__,r=e.delete(t);return this.size=e.size,r};const v=function(t){return this.__data__.get(t)};const w=function(t){return this.__data__.has(t)};const y="object"==typeof global&&global&&global.Object===Object&&global;var A="object"==typeof self&&self&&self.Object===Object&&self;const j=y||A||Function("return this")();const _=j.Symbol;var S=Object.prototype,E=S.hasOwnProperty,k=S.toString,O=_?_.toStringTag:void 0;const C=function(t){var e=E.call(t,O),r=t[O];try{t[O]=void 0;var o=!0}catch(t){}var n=k.call(t);return o&&(e?t[O]=r:delete t[O]),n};var $=Object.prototype.toString;const P=function(t){return $.call(t)};var F="[object Null]",x="[object Undefined]",I=_?_.toStringTag:void 0;const T=function(t){return null==t?void 0===t?x:F:I&&I in Object(t)?C(t):P(t)};const B=function(t){var e=typeof t;return null!=t&&("object"==e||"function"==e)};var D="[object AsyncFunction]",R="[object Function]",M="[object GeneratorFunction]",L="[object Proxy]";const N=function(t){if(!B(t))return!1;var e=T(t);return e==R||e==M||e==D||e==L};const V=j["__core-js_shared__"];var H,z=(H=/[^.]+$/.exec(V&&V.keys&&V.keys.IE_PROTO||""))?"Symbol(src)_1."+H:"";const U=function(t){return!!z&&z in t};var W=Function.prototype.toString;const q=function(t){if(null!=t){try{return W.call(t)}catch(t){}try{return t+""}catch(t){}}return""};var G=/^\[object .+?Constructor\]$/,K=Function.prototype,X=Object.prototype,Z=K.toString,Q=X.hasOwnProperty,J=RegExp("^"+Z.call(Q).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");const Y=function(t){return!(!B(t)||U(t))&&(N(t)?J:G).test(q(t))};const tt=function(t,e){return null==t?void 0:t[e]};const et=function(t,e){var r=tt(t,e);return Y(r)?r:void 0};const rt=et(j,"Map");const ot=et(Object,"create");const nt=function(){this.__data__=ot?ot(null):{},this.size=0};const it=function(t){var e=this.has(t)&&delete this.__data__[t];return this.size-=e?1:0,e};var st="__lodash_hash_undefined__",lt=Object.prototype.hasOwnProperty;const ct=function(t){var e=this.__data__;if(ot){var r=e[t];return r===st?void 0:r}return lt.call(e,t)?e[t]:void 0};var at=Object.prototype.hasOwnProperty;const ut=function(t){var e=this.__data__;return ot?void 0!==e[t]:at.call(e,t)};var mt="__lodash_hash_undefined__";const dt=function(t,e){var r=this.__data__;return this.size+=this.has(t)?0:1,r[t]=ot&&void 0===e?mt:e,this};function ht(t){var e=-1,r=null==t?0:t.length;for(this.clear();++e<r;){var o=t[e];this.set(o[0],o[1])}}ht.prototype.clear=nt,ht.prototype.delete=it,ht.prototype.get=ct,ht.prototype.has=ut,ht.prototype.set=dt;const ft=ht;const bt=function(){this.size=0,this.__data__={hash:new ft,map:new(rt||b),string:new ft}};const pt=function(t){var e=typeof t;return"string"==e||"number"==e||"symbol"==e||"boolean"==e?"__proto__"!==t:null===t};const gt=function(t,e){var r=t.__data__;return pt(e)?r["string"==typeof e?"string":"hash"]:r.map};const vt=function(t){var e=gt(this,t).delete(t);return this.size-=e?1:0,e};const wt=function(t){return gt(this,t).get(t)};const yt=function(t){return gt(this,t).has(t)};const At=function(t,e){var r=gt(this,t),o=r.size;return r.set(t,e),this.size+=r.size==o?0:1,this};function jt(t){var e=-1,r=null==t?0:t.length;for(this.clear();++e<r;){var o=t[e];this.set(o[0],o[1])}}jt.prototype.clear=bt,jt.prototype.delete=vt,jt.prototype.get=wt,jt.prototype.has=yt,jt.prototype.set=At;const _t=jt;var St=200;const Et=function(t,e){var r=this.__data__;if(r instanceof b){var o=r.__data__;if(!rt||o.length<St-1)return o.push([t,e]),this.size=++r.size,this;r=this.__data__=new _t(o)}return r.set(t,e),this.size=r.size,this};function kt(t){var e=this.__data__=new b(t);this.size=e.size}kt.prototype.clear=p,kt.prototype.delete=g,kt.prototype.get=v,kt.prototype.has=w,kt.prototype.set=Et;const Ot=kt;const Ct=function(){try{var t=et(Object,"defineProperty");return t({},"",{}),t}catch(t){}}();const $t=function(t,e,r){"__proto__"==e&&Ct?Ct(t,e,{configurable:!0,enumerable:!0,value:r,writable:!0}):t[e]=r};const Pt=function(t,e,r){(void 0!==r&&!l(t[e],r)||void 0===r&&!(e in t))&&$t(t,e,r)};const Ft=function(t){return function(e,r,o){for(var n=-1,i=Object(e),s=o(e),l=s.length;l--;){var c=s[t?l:++n];if(!1===r(i[c],c,i))break}return e}}();var xt="object"==typeof exports&&exports&&!exports.nodeType&&exports,It=xt&&"object"==typeof module&&module&&!module.nodeType&&module,Tt=It&&It.exports===xt?j.Buffer:void 0,Bt=Tt?Tt.allocUnsafe:void 0;const Dt=function(t,e){if(e)return t.slice();var r=t.length,o=Bt?Bt(r):new t.constructor(r);return t.copy(o),o};const Rt=j.Uint8Array;const Mt=function(t){var e=new t.constructor(t.byteLength);return new Rt(e).set(new Rt(t)),e};const Lt=function(t,e){var r=e?Mt(t.buffer):t.buffer;return new t.constructor(r,t.byteOffset,t.length)};const Nt=function(t,e){var r=-1,o=t.length;for(e||(e=Array(o));++r<o;)e[r]=t[r];return e};var Vt=Object.create;const Ht=function(){function t(){}return function(e){if(!B(e))return{};if(Vt)return Vt(e);t.prototype=e;var r=new t;return t.prototype=void 0,r}}();const zt=function(t,e){return function(r){return t(e(r))}};const Ut=zt(Object.getPrototypeOf,Object);var Wt=Object.prototype;const qt=function(t){var e=t&&t.constructor;return t===("function"==typeof e&&e.prototype||Wt)};const Gt=function(t){return"function"!=typeof t.constructor||qt(t)?{}:Ht(Ut(t))};const Kt=function(t){return null!=t&&"object"==typeof t};var Xt="[object Arguments]";const Zt=function(t){return Kt(t)&&T(t)==Xt};var Qt=Object.prototype,Jt=Qt.hasOwnProperty,Yt=Qt.propertyIsEnumerable;const te=Zt(function(){return arguments}())?Zt:function(t){return Kt(t)&&Jt.call(t,"callee")&&!Yt.call(t,"callee")};const ee=Array.isArray;var re=9007199254740991;const oe=function(t){return"number"==typeof t&&t>-1&&t%1==0&&t<=re};const ne=function(t){return null!=t&&oe(t.length)&&!N(t)};const ie=function(t){return Kt(t)&&ne(t)};const se=function(){return!1};var le="object"==typeof exports&&exports&&!exports.nodeType&&exports,ce=le&&"object"==typeof module&&module&&!module.nodeType&&module,ae=ce&&ce.exports===le?j.Buffer:void 0;const ue=(ae?ae.isBuffer:void 0)||se;var me="[object Object]",de=Function.prototype,he=Object.prototype,fe=de.toString,be=he.hasOwnProperty,pe=fe.call(Object);const ge=function(t){if(!Kt(t)||T(t)!=me)return!1;var e=Ut(t);if(null===e)return!0;var r=be.call(e,"constructor")&&e.constructor;return"function"==typeof r&&r instanceof r&&fe.call(r)==pe};var ve={};ve["[object Float32Array]"]=ve["[object Float64Array]"]=ve["[object Int8Array]"]=ve["[object Int16Array]"]=ve["[object Int32Array]"]=ve["[object Uint8Array]"]=ve["[object Uint8ClampedArray]"]=ve["[object Uint16Array]"]=ve["[object Uint32Array]"]=!0,ve["[object Arguments]"]=ve["[object Array]"]=ve["[object ArrayBuffer]"]=ve["[object Boolean]"]=ve["[object DataView]"]=ve["[object Date]"]=ve["[object Error]"]=ve["[object Function]"]=ve["[object Map]"]=ve["[object Number]"]=ve["[object Object]"]=ve["[object RegExp]"]=ve["[object Set]"]=ve["[object String]"]=ve["[object WeakMap]"]=!1;const we=function(t){return Kt(t)&&oe(t.length)&&!!ve[T(t)]};const ye=function(t){return function(e){return t(e)}};var Ae="object"==typeof exports&&exports&&!exports.nodeType&&exports,je=Ae&&"object"==typeof module&&module&&!module.nodeType&&module,_e=je&&je.exports===Ae&&y.process;const Se=function(){try{var t=je&&je.require&&je.require("util").types;return t||_e&&_e.binding&&_e.binding("util")}catch(t){}}();var Ee=Se&&Se.isTypedArray;const ke=Ee?ye(Ee):we;const Oe=function(t,e){if(("constructor"!==e||"function"!=typeof t[e])&&"__proto__"!=e)return t[e]};var Ce=Object.prototype.hasOwnProperty;const $e=function(t,e,r){var o=t[e];Ce.call(t,e)&&l(o,r)&&(void 0!==r||e in t)||$t(t,e,r)};const Pe=function(t,e,r,o){var n=!r;r||(r={});for(var i=-1,s=e.length;++i<s;){var l=e[i],c=o?o(r[l],t[l],l,r,t):void 0;void 0===c&&(c=t[l]),n?$t(r,l,c):$e(r,l,c)}return r};const Fe=function(t,e){for(var r=-1,o=Array(t);++r<t;)o[r]=e(r);return o};var xe=9007199254740991,Ie=/^(?:0|[1-9]\d*)$/;const Te=function(t,e){var r=typeof t;return!!(e=null==e?xe:e)&&("number"==r||"symbol"!=r&&Ie.test(t))&&t>-1&&t%1==0&&t<e};var Be=Object.prototype.hasOwnProperty;const De=function(t,e){var r=ee(t),o=!r&&te(t),n=!r&&!o&&ue(t),i=!r&&!o&&!n&&ke(t),s=r||o||n||i,l=s?Fe(t.length,String):[],c=l.length;for(var a in t)!e&&!Be.call(t,a)||s&&("length"==a||n&&("offset"==a||"parent"==a)||i&&("buffer"==a||"byteLength"==a||"byteOffset"==a)||Te(a,c))||l.push(a);return l};const Re=function(t){var e=[];if(null!=t)for(var r in Object(t))e.push(r);return e};var Me=Object.prototype.hasOwnProperty;const Le=function(t){if(!B(t))return Re(t);var e=qt(t),r=[];for(var o in t)("constructor"!=o||!e&&Me.call(t,o))&&r.push(o);return r};const Ne=function(t){return ne(t)?De(t,!0):Le(t)};const Ve=function(t){return Pe(t,Ne(t))};const He=function(t,e,r,o,n,i,s){var l=Oe(t,r),c=Oe(e,r),a=s.get(c);if(a)Pt(t,r,a);else{var u=i?i(l,c,r+"",t,e,s):void 0,m=void 0===u;if(m){var d=ee(c),h=!d&&ue(c),f=!d&&!h&&ke(c);u=c,d||h||f?ee(l)?u=l:ie(l)?u=Nt(l):h?(m=!1,u=Dt(c,!0)):f?(m=!1,u=Lt(c,!0)):u=[]:ge(c)||te(c)?(u=l,te(l)?u=Ve(l):B(l)&&!N(l)||(u=Gt(c))):m=!1}m&&(s.set(c,u),n(u,c,o,i,s),s.delete(c)),Pt(t,r,u)}};const ze=function t(e,r,o,n,i){e!==r&&Ft(r,(function(s,l){if(i||(i=new Ot),B(s))He(e,r,l,o,t,n,i);else{var c=n?n(Oe(e,l),s,l+"",e,r,i):void 0;void 0===c&&(c=s),Pt(e,l,c)}}),Ne)};const Ue=function(t){return t};const We=function(t,e,r){switch(r.length){case 0:return t.call(e);case 1:return t.call(e,r[0]);case 2:return t.call(e,r[0],r[1]);case 3:return t.call(e,r[0],r[1],r[2])}return t.apply(e,r)};var qe=Math.max;const Ge=function(t,e,r){return e=qe(void 0===e?t.length-1:e,0),function(){for(var o=arguments,n=-1,i=qe(o.length-e,0),s=Array(i);++n<i;)s[n]=o[e+n];n=-1;for(var l=Array(e+1);++n<e;)l[n]=o[n];return l[e]=r(s),We(t,this,l)}};const Ke=function(t){return function(){return t}};const Xe=Ct?function(t,e){return Ct(t,"toString",{configurable:!0,enumerable:!1,value:Ke(e),writable:!0})}:Ue;var Ze=800,Qe=16,Je=Date.now;const Ye=function(t){var e=0,r=0;return function(){var o=Je(),n=Qe-(o-r);if(r=o,n>0){if(++e>=Ze)return arguments[0]}else e=0;return t.apply(void 0,arguments)}}(Xe);const tr=function(t,e){return Ye(Ge(t,e,Ue),t+"")};const er=function(t,e,r){if(!B(r))return!1;var o=typeof e;return!!("number"==o?ne(r)&&Te(e,r.length):"string"==o&&e in r)&&l(r[e],t)};const rr=function(t){return tr((function(e,r){var o=-1,n=r.length,i=n>1?r[n-1]:void 0,s=n>2?r[2]:void 0;for(i=t.length>3&&"function"==typeof i?(n--,i):void 0,s&&er(r[0],r[1],s)&&(i=n<3?void 0:i,n=1),e=Object(e);++o<n;){var l=r[o];l&&t(e,l,o,i)}return e}))}((function(t,e,r,o){ze(t,e,r,o)}));class or extends t.Plugin{constructor(t){super(t),this._definitions=new Map}static get pluginName(){return"DataSchema"}init(){for(const t of n)this.registerBlockElement(t);for(const t of i)this.registerInlineElement(t)}registerBlockElement(t){this._definitions.set(t.model,{...t,isBlock:!0})}registerInlineElement(t){this._definitions.set(t.model,{...t,isInline:!0})}extendBlockElement(t){this._extendDefinition({...t,isBlock:!0})}extendInlineElement(t){this._extendDefinition({...t,isInline:!0})}getDefinitionsForView(t,e){const r=new Set;for(const o of this._getMatchingViewDefinitions(t)){if(e)for(const t of this._getReferences(o.model))r.add(t);r.add(o)}return r}_getMatchingViewDefinitions(t){return Array.from(this._definitions.values()).filter((e=>e.view&&function(t,e){if("string"==typeof t)return t===e;if(t instanceof RegExp)return t.test(e);return!1}(t,e.view)))}*_getReferences(t){const{modelSchema:r}=this._definitions.get(t);if(!r)return;const o=["inheritAllFrom","inheritTypesFrom","allowWhere","allowContentOf","allowAttributesOf"];for(const n of o)for(const o of(0,e.toArray)(r[n]||[])){const e=this._definitions.get(o);o!==t&&e&&(yield*this._getReferences(e.model),yield e)}}_extendDefinition(t){const e=this._definitions.get(t.model),r=rr({},e,t,((t,e)=>Array.isArray(t)?t.concat(e):void 0));this._definitions.set(t.model,r)}}var nr=r(492),ir=r(995);const sr=function(t,e){for(var r=-1,o=null==t?0:t.length;++r<o&&!1!==e(t[r],r,t););return t};const lr=zt(Object.keys,Object);var cr=Object.prototype.hasOwnProperty;const ar=function(t){if(!qt(t))return lr(t);var e=[];for(var r in Object(t))cr.call(t,r)&&"constructor"!=r&&e.push(r);return e};const ur=function(t){return ne(t)?De(t):ar(t)};const mr=function(t,e){return t&&Pe(e,ur(e),t)};const dr=function(t,e){return t&&Pe(e,Ne(e),t)};const hr=function(t,e){for(var r=-1,o=null==t?0:t.length,n=0,i=[];++r<o;){var s=t[r];e(s,r,t)&&(i[n++]=s)}return i};const fr=function(){return[]};var br=Object.prototype.propertyIsEnumerable,pr=Object.getOwnPropertySymbols;const gr=pr?function(t){return null==t?[]:(t=Object(t),hr(pr(t),(function(e){return br.call(t,e)})))}:fr;const vr=function(t,e){return Pe(t,gr(t),e)};const wr=function(t,e){for(var r=-1,o=e.length,n=t.length;++r<o;)t[n+r]=e[r];return t};const yr=Object.getOwnPropertySymbols?function(t){for(var e=[];t;)wr(e,gr(t)),t=Ut(t);return e}:fr;const Ar=function(t,e){return Pe(t,yr(t),e)};const jr=function(t,e,r){var o=e(t);return ee(t)?o:wr(o,r(t))};const _r=function(t){return jr(t,ur,gr)};const Sr=function(t){return jr(t,Ne,yr)};const Er=et(j,"DataView");const kr=et(j,"Promise");const Or=et(j,"Set");const Cr=et(j,"WeakMap");var $r="[object Map]",Pr="[object Promise]",Fr="[object Set]",xr="[object WeakMap]",Ir="[object DataView]",Tr=q(Er),Br=q(rt),Dr=q(kr),Rr=q(Or),Mr=q(Cr),Lr=T;(Er&&Lr(new Er(new ArrayBuffer(1)))!=Ir||rt&&Lr(new rt)!=$r||kr&&Lr(kr.resolve())!=Pr||Or&&Lr(new Or)!=Fr||Cr&&Lr(new Cr)!=xr)&&(Lr=function(t){var e=T(t),r="[object Object]"==e?t.constructor:void 0,o=r?q(r):"";if(o)switch(o){case Tr:return Ir;case Br:return $r;case Dr:return Pr;case Rr:return Fr;case Mr:return xr}return e});const Nr=Lr;var Vr=Object.prototype.hasOwnProperty;const Hr=function(t){var e=t.length,r=new t.constructor(e);return e&&"string"==typeof t[0]&&Vr.call(t,"index")&&(r.index=t.index,r.input=t.input),r};const zr=function(t,e){var r=e?Mt(t.buffer):t.buffer;return new t.constructor(r,t.byteOffset,t.byteLength)};var Ur=/\w*$/;const Wr=function(t){var e=new t.constructor(t.source,Ur.exec(t));return e.lastIndex=t.lastIndex,e};var qr=_?_.prototype:void 0,Gr=qr?qr.valueOf:void 0;const Kr=function(t){return Gr?Object(Gr.call(t)):{}};var Xr="[object Boolean]",Zr="[object Date]",Qr="[object Map]",Jr="[object Number]",Yr="[object RegExp]",to="[object Set]",eo="[object String]",ro="[object Symbol]",oo="[object ArrayBuffer]",no="[object DataView]",io="[object Float32Array]",so="[object Float64Array]",lo="[object Int8Array]",co="[object Int16Array]",ao="[object Int32Array]",uo="[object Uint8Array]",mo="[object Uint8ClampedArray]",ho="[object Uint16Array]",fo="[object Uint32Array]";const bo=function(t,e,r){var o=t.constructor;switch(e){case oo:return Mt(t);case Xr:case Zr:return new o(+t);case no:return zr(t,r);case io:case so:case lo:case co:case ao:case uo:case mo:case ho:case fo:return Lt(t,r);case Qr:return new o;case Jr:case eo:return new o(t);case Yr:return Wr(t);case to:return new o;case ro:return Kr(t)}};var po="[object Map]";const go=function(t){return Kt(t)&&Nr(t)==po};var vo=Se&&Se.isMap;const wo=vo?ye(vo):go;var yo="[object Set]";const Ao=function(t){return Kt(t)&&Nr(t)==yo};var jo=Se&&Se.isSet;const _o=jo?ye(jo):Ao;var So=1,Eo=2,ko=4,Oo="[object Arguments]",Co="[object Function]",$o="[object GeneratorFunction]",Po="[object Object]",Fo={};Fo[Oo]=Fo["[object Array]"]=Fo["[object ArrayBuffer]"]=Fo["[object DataView]"]=Fo["[object Boolean]"]=Fo["[object Date]"]=Fo["[object Float32Array]"]=Fo["[object Float64Array]"]=Fo["[object Int8Array]"]=Fo["[object Int16Array]"]=Fo["[object Int32Array]"]=Fo["[object Map]"]=Fo["[object Number]"]=Fo[Po]=Fo["[object RegExp]"]=Fo["[object Set]"]=Fo["[object String]"]=Fo["[object Symbol]"]=Fo["[object Uint8Array]"]=Fo["[object Uint8ClampedArray]"]=Fo["[object Uint16Array]"]=Fo["[object Uint32Array]"]=!0,Fo["[object Error]"]=Fo[Co]=Fo["[object WeakMap]"]=!1;const xo=function t(e,r,o,n,i,s){var l,c=r&So,a=r&Eo,u=r&ko;if(o&&(l=i?o(e,n,i,s):o(e)),void 0!==l)return l;if(!B(e))return e;var m=ee(e);if(m){if(l=Hr(e),!c)return Nt(e,l)}else{var d=Nr(e),h=d==Co||d==$o;if(ue(e))return Dt(e,c);if(d==Po||d==Oo||h&&!i){if(l=a||h?{}:Gt(e),!c)return a?Ar(e,dr(l,e)):vr(e,mr(l,e))}else{if(!Fo[d])return i?e:{};l=bo(e,d,c)}}s||(s=new Ot);var f=s.get(e);if(f)return f;s.set(e,l),_o(e)?e.forEach((function(n){l.add(t(n,r,o,n,e,s))})):wo(e)&&e.forEach((function(n,i){l.set(i,t(n,r,o,i,e,s))}));var b=m?void 0:(u?a?Sr:_r:a?Ne:ur)(e);return sr(b||e,(function(n,i){b&&(n=e[i=n]),$e(l,i,t(n,r,o,i,e,s))})),l};var Io=1,To=4;const Bo=function(t){return xo(t,Io|To)};function Do(t,e,r,o){e&&function(t,e,r){if(e.attributes)for(const[o]of Object.entries(e.attributes))t.removeAttribute(o,r);if(e.styles)for(const o of Object.keys(e.styles))t.removeStyle(o,r);e.classes&&t.removeClass(e.classes,r)}(t,e,o),r&&Ro(t,r,o)}function Ro(t,e,r){if(e.attributes)for(const[o,n]of Object.entries(e.attributes))t.setAttribute(o,n,r);e.styles&&t.setStyle(e.styles,r),e.classes&&t.addClass(e.classes,r)}function Mo(t,e){const r=Bo(t);for(const o in e)Array.isArray(e[o])?r[o]=Array.from(new Set([...t[o]||[],...e[o]])):r[o]={...t[o],...e[o]};return r}function Lo({model:t}){return(e,r)=>r.writer.createElement(t,{htmlContent:e.getCustomProperty("$rawContent")})}function No(t,{view:e,isInline:r}){const o=t.t;return(t,{writer:n})=>{const i=o("HTML object"),s=Vo(e,t,n),l=t.getAttribute("htmlAttributes");n.addClass("html-object-embed__content",s),l&&Ro(n,l,s);const c=n.createContainerElement(r?"span":"div",{class:"html-object-embed","data-html-object-embed-label":i},s);return(0,ir.toWidget)(c,n,{widgetLabel:i})}}function Vo(t,e,r){return r.createRawElement(t,null,((t,r)=>{r.setContentOf(t,e.getAttribute("htmlContent"))}))}function Ho({priority:t,view:e}){return(r,o)=>{if(!r)return;const{writer:n}=o,i=n.createAttributeElement(e,null,{priority:t});return Ro(n,r,i),i}}function zo({view:t},e){return r=>{r.on(`element:${t}`,((t,r,o)=>{if(!r.modelRange||r.modelRange.isCollapsed)return;const n=e.processViewAttributes(r.viewItem,o);n&&o.writer.setAttribute("htmlAttributes",n,r.modelRange)}),{priority:"low"})}}function Uo({model:t}){return e=>{e.on(`attribute:htmlAttributes:${t}`,((t,e,r)=>{if(!r.consumable.consume(e.item,t.name))return;const{attributeOldValue:o,attributeNewValue:n}=e;Do(r.writer,o,n,r.mapper.toViewElement(e.item))}))}}const Wo=function(t,e){for(var r=-1,o=null==t?0:t.length,n=Array(o);++r<o;)n[r]=e(t[r],r,t);return n};const qo=function(t,e,r,o){for(var n=t.length,i=r+(o?1:-1);o?i--:++i<n;)if(e(t[i],i,t))return i;return-1};const Go=function(t){return t!=t};const Ko=function(t,e,r){for(var o=r-1,n=t.length;++o<n;)if(t[o]===e)return o;return-1};const Xo=function(t,e,r){return e==e?Ko(t,e,r):qo(t,Go,r)};const Zo=function(t,e,r,o){for(var n=r-1,i=t.length;++n<i;)if(o(t[n],e))return n;return-1};var Qo=Array.prototype.splice;const Jo=function(t,e,r,o){var n=o?Zo:Xo,i=-1,s=e.length,l=t;for(t===e&&(e=Nt(e)),r&&(l=Wo(t,ye(r)));++i<s;)for(var c=0,a=e[i],u=r?r(a):a;(c=n(l,u,c,o))>-1;)l!==t&&Qo.call(l,c,1),Qo.call(t,c,1);return t};const Yo=tr((function(t,e){return t&&t.length&&e&&e.length?Jo(t,e):t}));var tn=r(62),en=r.n(tn),rn=r(142),on={injectType:"singletonStyleTag",attributes:{"data-cke":!0},insert:"head",singleton:!0};en()(rn.Z,on);rn.Z.locals;class nn extends t.Plugin{constructor(t){super(t),this._dataSchema=t.plugins.get("DataSchema"),this._allowedAttributes=new nr.Matcher,this._disallowedAttributes=new nr.Matcher,this._allowedElements=new Set,this._disallowedElements=new Set,this._dataInitialized=!1,this._coupledAttributes=null,this._registerElementsAfterInit(),this._registerElementHandlers(),this._registerModelPostFixer()}static get pluginName(){return"DataFilter"}static get requires(){return[or,ir.Widget]}loadAllowedConfig(t){for(const e of t){const t=e.name||/[\s\S]+/,r=un(e);this.allowElement(t),r.forEach((t=>this.allowAttributes(t)))}}loadDisallowedConfig(t){for(const e of t){const t=e.name||/[\s\S]+/,r=un(e);0==r.length?this.disallowElement(t):r.forEach((t=>this.disallowAttributes(t)))}}allowElement(t){for(const r of this._dataSchema.getDefinitionsForView(t,!0))this._allowedElements.has(r)||(this._allowedElements.add(r),this._dataInitialized&&this.editor.data.once("set",(()=>{this._fireRegisterEvent(r)}),{priority:e.priorities.get("highest")+1}),this._coupledAttributes=null)}disallowElement(t){for(const e of this._dataSchema.getDefinitionsForView(t,!1))this._disallowedElements.add(e.view)}allowAttributes(t){this._allowedAttributes.add(t)}disallowAttributes(t){this._disallowedAttributes.add(t)}processViewAttributes(t,e){return sn(t,e,this._disallowedAttributes),sn(t,e,this._allowedAttributes)}_registerElementsAfterInit(){this.editor.data.on("init",(()=>{this._dataInitialized=!0;for(const t of this._allowedElements)this._fireRegisterEvent(t)}),{priority:e.priorities.get("highest")+1})}_registerElementHandlers(){this.on("register",((t,r)=>{const o=this.editor.model.schema;if(r.isObject&&!o.isRegistered(r.model))this._registerObjectElement(r);else if(r.isBlock)this._registerBlockElement(r);else{if(!r.isInline)throw new e.CKEditorError("data-filter-invalid-definition",null,r);this._registerInlineElement(r)}t.stop()}),{priority:"lowest"})}_registerModelPostFixer(){const t=this.editor.model;t.document.registerPostFixer((e=>{const r=t.document.differ.getChanges();let o=!1;const n=this._getCoupledAttributesMap();for(const t of r){if("attribute"!=t.type||null!==t.attributeNewValue)continue;const r=n.get(t.attributeKey);if(r)for(const{item:n}of t.range.getWalker({shallow:!0}))for(const t of r)n.hasAttribute(t)&&(e.removeAttribute(t,n),o=!0)}return o}))}_getCoupledAttributesMap(){if(this._coupledAttributes)return this._coupledAttributes;this._coupledAttributes=new Map;for(const t of this._allowedElements)if(t.coupledAttribute&&t.model){const e=this._coupledAttributes.get(t.coupledAttribute);e?e.push(t.model):this._coupledAttributes.set(t.coupledAttribute,[t.model])}}_fireRegisterEvent(t){t.view&&this._disallowedElements.has(t.view)||this.fire(t.view?`register:${t.view}`:"register",t)}_registerObjectElement(t){const r=this.editor,o=r.model.schema,n=r.conversion,{view:i,model:s}=t;o.register(s,t.modelSchema),i&&(o.extend(t.model,{allowAttributes:["htmlAttributes","htmlContent"]}),r.data.registerRawContentMatcher({name:i}),n.for("upcast").elementToElement({view:i,model:Lo(t),converterPriority:e.priorities.get("low")+1}),n.for("upcast").add(zo(t,this)),n.for("editingDowncast").elementToStructure({model:{name:s,attributes:["htmlAttributes"]},view:No(r,t)}),n.for("dataDowncast").elementToElement({model:s,view:(t,{writer:e})=>Vo(i,t,e)}),n.for("dataDowncast").add(Uo(t)))}_registerBlockElement(t){const r=this.editor,o=r.model.schema,n=r.conversion,{view:i,model:s}=t;if(!o.isRegistered(t.model)){if(o.register(t.model,t.modelSchema),!i)return;n.for("upcast").elementToElement({model:s,view:i,converterPriority:e.priorities.get("low")+1}),n.for("downcast").elementToElement({model:s,view:i})}i&&(o.extend(t.model,{allowAttributes:"htmlAttributes"}),n.for("upcast").add(zo(t,this)),n.for("downcast").add(Uo(t)))}_registerInlineElement(t){const e=this.editor,r=e.model.schema,o=e.conversion,n=t.model;r.extend("$text",{allowAttributes:n}),t.attributeProperties&&r.setAttributeProperties(n,t.attributeProperties),o.for("upcast").add(function({view:t,model:e},r){return o=>{o.on(`element:${t}`,((t,o,n)=>{let i=r.processViewAttributes(o.viewItem,n);if(i||n.consumable.test(o.viewItem,{name:!0})){i=i||{},n.consumable.consume(o.viewItem,{name:!0}),o.modelRange||(o=Object.assign(o,n.convertChildren(o.viewItem,o.modelCursor)));for(const t of o.modelRange.getItems())if(n.schema.checkAttribute(t,e)){const r=Mo(i,t.getAttribute(e)||{});n.writer.setAttribute(e,r,t)}}}),{priority:"low"})}}(t,this)),o.for("downcast").attributeToElement({model:n,view:Ho(t)})}}function sn(t,e,r){const o=function(t,{consumable:e},r){const o=r.matchAll(t)||[],n=[];for(const r of o)ln(e,t,r),delete r.match.name,e.consume(t,r.match),n.push(r);return n}(t,e,r),{attributes:n,styles:i,classes:s}=function(t){const e={attributes:new Set,classes:new Set,styles:new Set};for(const r of t)for(const t in e){(r.match[t]||[]).forEach((r=>e[t].add(r)))}return e}(o),l={};if(n.size)for(const t of n)mn(t)||n.delete(t);return n.size&&(l.attributes=cn(n,(e=>t.getAttribute(e)))),i.size&&(l.styles=cn(i,(e=>t.getStyle(e)))),s.size&&(l.classes=Array.from(s)),Object.keys(l).length?l:null}function ln(t,e,r){for(const o of["attributes","classes","styles"]){const n=r.match[o];if(n)for(const r of Array.from(n))t.test(e,{[o]:[r]})||Yo(n,r)}}function cn(t,e){const r={};for(const o of t){void 0!==e(o)&&(r[o]=e(o))}return r}function an(t,e){const{name:r}=t;return ge(t[e])?Object.entries(t[e]).map((([t,o])=>({name:r,[e]:{[t]:o}}))):Array.isArray(t[e])?t[e].map((t=>({name:r,[e]:[t]}))):[t]}function un(t){const{name:e,attributes:r,classes:o,styles:n}=t,i=[];return r&&i.push(...an({name:e,attributes:r},"attributes")),o&&i.push(...an({name:e,classes:o},"classes")),n&&i.push(...an({name:e,styles:n},"styles")),i}function mn(t){try{document.createAttribute(t)}catch(t){return!1}return!0}class dn extends t.Plugin{static get requires(){return[nn]}static get pluginName(){return"CodeBlockElementSupport"}init(){if(!this.editor.plugins.has("CodeBlockEditing"))return;const t=this.editor.plugins.get(nn);t.on("register:pre",((e,r)=>{if("codeBlock"!==r.model)return;const o=this.editor,n=o.model.schema,i=o.conversion;n.extend("codeBlock",{allowAttributes:["htmlAttributes","htmlContentAttributes"]}),i.for("upcast").add(function(t){return e=>{e.on("element:code",((e,r,o)=>{const n=r.viewItem,i=n.parent;function s(e,n){const i=t.processViewAttributes(e,o);i&&o.writer.setAttribute(n,i,r.modelRange)}i&&i.is("element","pre")&&(s(i,"htmlAttributes"),s(n,"htmlContentAttributes"))}),{priority:"low"})}}(t)),i.for("downcast").add((t=>{t.on("attribute:htmlAttributes:codeBlock",((t,e,r)=>{if(!r.consumable.consume(e.item,t.name))return;const{attributeOldValue:o,attributeNewValue:n}=e,i=r.mapper.toViewElement(e.item).parent;Do(r.writer,o,n,i)})),t.on("attribute:htmlContentAttributes:codeBlock",((t,e,r)=>{if(!r.consumable.consume(e.item,t.name))return;const{attributeOldValue:o,attributeNewValue:n}=e,i=r.mapper.toViewElement(e.item);Do(r.writer,o,n,i)}))})),e.stop()}))}}class hn extends t.Plugin{static get requires(){return[nn]}static get pluginName(){return"DualContentModelElementSupport"}init(){this.editor.plugins.get(nn).on("register",((t,r)=>{const o=this.editor,n=o.model.schema,i=o.conversion;if(!r.paragraphLikeModel)return;if(n.isRegistered(r.model)||n.isRegistered(r.paragraphLikeModel))return;const s={model:r.paragraphLikeModel,view:r.view};n.register(r.model,r.modelSchema),n.register(s.model,{inheritAllFrom:"$block"}),i.for("upcast").elementToElement({view:r.view,model:(t,{writer:e})=>this._hasBlockContent(t)?e.createElement(r.model):e.createElement(s.model),converterPriority:e.priorities.get("low")+1}),i.for("downcast").elementToElement({view:r.view,model:r.model}),this._addAttributeConversion(r),i.for("downcast").elementToElement({view:s.view,model:s.model}),this._addAttributeConversion(s),t.stop()}))}_hasBlockContent(t){const e=this.editor.editing.view,r=e.domConverter.blockElements;for(const o of e.createRangeIn(t).getItems())if(o.is("element")&&r.includes(o.name))return!0;return!1}_addAttributeConversion(t){const e=this.editor,r=e.conversion,o=e.plugins.get(nn);e.model.schema.extend(t.model,{allowAttributes:"htmlAttributes"}),r.for("upcast").add(zo(t,o)),r.for("downcast").add(Uo(t))}}class fn extends t.Plugin{static get requires(){return[or]}static get pluginName(){return"HeadingElementSupport"}init(){const t=this.editor;if(!t.plugins.has("HeadingEditing"))return;const e=t.plugins.get(or),r=t.config.get("heading.options"),o=[];for(const t of r)"model"in t&&"view"in t&&(e.registerBlockElement({view:t.view,model:t.model}),o.push(t.model));e.extendBlockElement({model:"htmlHgroup",modelSchema:{allowChildren:o}})}}class bn extends t.Plugin{static get requires(){return[nn]}static get pluginName(){return"ImageElementSupport"}init(){const t=this.editor;if(!t.plugins.has("ImageInlineEditing")&&!t.plugins.has("ImageBlockEditing"))return;const e=t.model.schema,r=t.conversion,o=t.plugins.get(nn);o.on("register:figure",(()=>{r.for("upcast").add(function(t){return e=>{e.on("element:figure",((e,r,o)=>{const n=r.viewItem;if(!r.modelRange||!n.hasClass("image"))return;const i=t.processViewAttributes(n,o);i&&o.writer.setAttribute("htmlFigureAttributes",i,r.modelRange)}),{priority:"low"})}}(o))})),o.on("register:img",((t,n)=>{"imageBlock"!==n.model&&"imageInline"!==n.model||(e.isRegistered("imageBlock")&&e.extend("imageBlock",{allowAttributes:["htmlAttributes","htmlFigureAttributes","htmlLinkAttributes"]}),e.isRegistered("imageInline")&&e.extend("imageInline",{allowAttributes:["htmlA","htmlAttributes"]}),r.for("upcast").add(function(t){return e=>{e.on("element:img",((e,r,o)=>{if(!r.modelRange)return;const n=r.viewItem,i=n.parent;function s(e,n){const i=t.processViewAttributes(e,o);i&&o.writer.setAttribute(n,i,r.modelRange)}function l(t){r.modelRange&&r.modelRange.getContainedElement().is("element","imageBlock")&&s(t,"htmlLinkAttributes")}s(n,"htmlAttributes"),i.is("element","a")&&l(i)}),{priority:"low"})}}(o)),r.for("downcast").add((t=>{function e(e){t.on(`attribute:${e}:imageInline`,((t,e,r)=>{if(!r.consumable.consume(e.item,t.name))return;const{attributeOldValue:o,attributeNewValue:n}=e,i=r.mapper.toViewElement(e.item);Do(r.writer,o,n,i)}),{priority:"low"})}function r(e,r){t.on(`attribute:${r}:imageBlock`,((t,r,o)=>{if(!o.consumable.test(r.item,t.name))return;const{attributeOldValue:n,attributeNewValue:i}=r,s=o.mapper.toViewElement(r.item),l=pn(o.writer,s,e);l&&(Do(o.writer,n,i,l),o.consumable.consume(r.item,t.name))}),{priority:"low"}),"a"===e&&t.on("attribute:linkHref:imageBlock",((t,e,r)=>{if(!r.consumable.consume(e.item,"attribute:htmlLinkAttributes:imageBlock"))return;const o=r.mapper.toViewElement(e.item),n=pn(r.writer,o,"a");Ro(r.writer,e.item.getAttribute("htmlLinkAttributes"),n)}),{priority:"low"})}e("htmlAttributes"),r("img","htmlAttributes"),r("figure","htmlFigureAttributes"),r("a","htmlLinkAttributes")})),t.stop())}))}}function pn(t,e,r){const o=t.createRangeOn(e);for(const{item:t}of o.getWalker())if(t.is("element",r))return t}class gn extends t.Plugin{static get requires(){return[nn]}static get pluginName(){return"MediaEmbedElementSupport"}init(){const t=this.editor;if(!t.plugins.has("MediaEmbed")||t.config.get("mediaEmbed.previewsInData"))return;const e=t.model.schema,r=t.conversion,o=this.editor.plugins.get(nn),n=this.editor.plugins.get(or),i=t.config.get("mediaEmbed.elementName");n.registerBlockElement({model:"media",view:i}),o.on("register:figure",(()=>{r.for("upcast").add(function(t){return e=>{e.on("element:figure",((e,r,o)=>{const n=r.viewItem;if(!r.modelRange||!n.hasClass("media"))return;const i=t.processViewAttributes(n,o);i&&o.writer.setAttribute("htmlFigureAttributes",i,r.modelRange)}),{priority:"low"})}}(o))})),o.on(`register:${i}`,((t,n)=>{"media"===n.model&&(e.extend("media",{allowAttributes:["htmlAttributes","htmlFigureAttributes"]}),r.for("upcast").add(function(t,e){return t=>{t.on(`element:${e}`,r,{priority:"low"})};function r(e,r,o){function n(e,n){const i=t.processViewAttributes(e,o);i&&o.writer.setAttribute(n,i,r.modelRange)}n(r.viewItem,"htmlAttributes")}}(o,i)),r.for("dataDowncast").add(function(t){return e=>{function r(t,r){e.on(`attribute:${r}:media`,((e,r,o)=>{if(!o.consumable.consume(r.item,e.name))return;const{attributeOldValue:n,attributeNewValue:i}=r,s=o.mapper.toViewElement(r.item),l=function(t,e,r){const o=t.createRangeOn(e);for(const{item:t}of o.getWalker())if(t.is("element",r))return t}(o.writer,s,t);Do(o.writer,n,i,l)}))}r(t,"htmlAttributes"),r("figure","htmlFigureAttributes")}}(i)),t.stop())}))}}class vn extends t.Plugin{static get requires(){return[nn]}static get pluginName(){return"ScriptElementSupport"}init(){const t=this.editor.plugins.get(nn);t.on("register:script",((e,r)=>{const o=this.editor,n=o.model.schema,i=o.conversion;n.register("htmlScript",r.modelSchema),n.extend("htmlScript",{allowAttributes:["htmlAttributes","htmlContent"],isContent:!0}),o.data.registerRawContentMatcher({name:"script"}),i.for("upcast").elementToElement({view:"script",model:Lo(r)}),i.for("upcast").add(zo(r,t)),i.for("downcast").elementToElement({model:"htmlScript",view:(t,{writer:e})=>Vo("script",t,e)}),i.for("downcast").add(Uo(r)),e.stop()}))}}class wn extends t.Plugin{static get requires(){return[nn]}static get pluginName(){return"TableElementSupport"}init(){const t=this.editor;if(!t.plugins.has("TableEditing"))return;const e=t.model.schema,r=t.conversion,o=t.plugins.get(nn);o.on("register:figure",(()=>{r.for("upcast").add(function(t){return e=>{e.on("element:figure",((e,r,o)=>{const n=r.viewItem;if(!r.modelRange||!n.hasClass("table"))return;const i=t.processViewAttributes(n,o);i&&o.writer.setAttribute("htmlFigureAttributes",i,r.modelRange)}),{priority:"low"})}}(o))})),o.on("register:table",((t,n)=>{"table"===n.model&&(e.extend("table",{allowAttributes:["htmlAttributes","htmlFigureAttributes","htmlTheadAttributes","htmlTbodyAttributes"]}),r.for("upcast").add(function(t){return e=>{e.on("element:table",((e,r,o)=>{const n=r.viewItem;i(n,"htmlAttributes");for(const t of n.getChildren())t.is("element","thead")&&i(t,"htmlTheadAttributes"),t.is("element","tbody")&&i(t,"htmlTbodyAttributes");function i(e,n){const i=t.processViewAttributes(e,o);i&&o.writer.setAttribute(n,i,r.modelRange)}}),{priority:"low"})}}(o)),r.for("downcast").add((t=>{function e(e,r){t.on(`attribute:${r}:table`,((t,r,o)=>{if(!o.consumable.consume(r.item,t.name))return;const n=o.mapper.toViewElement(r.item),i=function(t,e,r){const o=t.createRangeOn(e);for(const{item:t}of o.getWalker())if(t.is("element",r))return t}(o.writer,n,e);Ro(o.writer,r.attributeNewValue,i)}))}e("table","htmlAttributes"),e("figure","htmlFigureAttributes"),e("thead","htmlTheadAttributes"),e("tbody","htmlTbodyAttributes")})),t.stop())}))}}class yn extends t.Plugin{static get requires(){return[nn]}static get pluginName(){return"StyleElementSupport"}init(){const t=this.editor.plugins.get(nn);t.on("register:style",((e,r)=>{const o=this.editor,n=o.model.schema,i=o.conversion;n.register("htmlStyle",r.modelSchema),n.extend("htmlStyle",{allowAttributes:["htmlAttributes","htmlContent"],isContent:!0}),o.data.registerRawContentMatcher({name:"style"}),i.for("upcast").elementToElement({view:"style",model:Lo(r)}),i.for("upcast").add(zo(r,t)),i.for("downcast").elementToElement({model:"htmlStyle",view:(t,{writer:e})=>Vo("style",t,e)}),i.for("downcast").add(Uo(r)),e.stop()}))}}var An="__lodash_hash_undefined__";const jn=function(t){return this.__data__.set(t,An),this};const _n=function(t){return this.__data__.has(t)};function Sn(t){var e=-1,r=null==t?0:t.length;for(this.__data__=new _t;++e<r;)this.add(t[e])}Sn.prototype.add=Sn.prototype.push=jn,Sn.prototype.has=_n;const En=Sn;const kn=function(t,e){for(var r=-1,o=null==t?0:t.length;++r<o;)if(e(t[r],r,t))return!0;return!1};const On=function(t,e){return t.has(e)};var Cn=1,$n=2;const Pn=function(t,e,r,o,n,i){var s=r&Cn,l=t.length,c=e.length;if(l!=c&&!(s&&c>l))return!1;var a=i.get(t),u=i.get(e);if(a&&u)return a==e&&u==t;var m=-1,d=!0,h=r&$n?new En:void 0;for(i.set(t,e),i.set(e,t);++m<l;){var f=t[m],b=e[m];if(o)var p=s?o(b,f,m,e,t,i):o(f,b,m,t,e,i);if(void 0!==p){if(p)continue;d=!1;break}if(h){if(!kn(e,(function(t,e){if(!On(h,e)&&(f===t||n(f,t,r,o,i)))return h.push(e)}))){d=!1;break}}else if(f!==b&&!n(f,b,r,o,i)){d=!1;break}}return i.delete(t),i.delete(e),d};const Fn=function(t){var e=-1,r=Array(t.size);return t.forEach((function(t,o){r[++e]=[o,t]})),r};const xn=function(t){var e=-1,r=Array(t.size);return t.forEach((function(t){r[++e]=t})),r};var In=1,Tn=2,Bn="[object Boolean]",Dn="[object Date]",Rn="[object Error]",Mn="[object Map]",Ln="[object Number]",Nn="[object RegExp]",Vn="[object Set]",Hn="[object String]",zn="[object Symbol]",Un="[object ArrayBuffer]",Wn="[object DataView]",qn=_?_.prototype:void 0,Gn=qn?qn.valueOf:void 0;const Kn=function(t,e,r,o,n,i,s){switch(r){case Wn:if(t.byteLength!=e.byteLength||t.byteOffset!=e.byteOffset)return!1;t=t.buffer,e=e.buffer;case Un:return!(t.byteLength!=e.byteLength||!i(new Rt(t),new Rt(e)));case Bn:case Dn:case Ln:return l(+t,+e);case Rn:return t.name==e.name&&t.message==e.message;case Nn:case Hn:return t==e+"";case Mn:var c=Fn;case Vn:var a=o&In;if(c||(c=xn),t.size!=e.size&&!a)return!1;var u=s.get(t);if(u)return u==e;o|=Tn,s.set(t,e);var m=Pn(c(t),c(e),o,n,i,s);return s.delete(t),m;case zn:if(Gn)return Gn.call(t)==Gn.call(e)}return!1};var Xn=1,Zn=Object.prototype.hasOwnProperty;const Qn=function(t,e,r,o,n,i){var s=r&Xn,l=_r(t),c=l.length;if(c!=_r(e).length&&!s)return!1;for(var a=c;a--;){var u=l[a];if(!(s?u in e:Zn.call(e,u)))return!1}var m=i.get(t),d=i.get(e);if(m&&d)return m==e&&d==t;var h=!0;i.set(t,e),i.set(e,t);for(var f=s;++a<c;){var b=t[u=l[a]],p=e[u];if(o)var g=s?o(p,b,u,e,t,i):o(b,p,u,t,e,i);if(!(void 0===g?b===p||n(b,p,r,o,i):g)){h=!1;break}f||(f="constructor"==u)}if(h&&!f){var v=t.constructor,w=e.constructor;v==w||!("constructor"in t)||!("constructor"in e)||"function"==typeof v&&v instanceof v&&"function"==typeof w&&w instanceof w||(h=!1)}return i.delete(t),i.delete(e),h};var Jn=1,Yn="[object Arguments]",ti="[object Array]",ei="[object Object]",ri=Object.prototype.hasOwnProperty;const oi=function(t,e,r,o,n,i){var s=ee(t),l=ee(e),c=s?ti:Nr(t),a=l?ti:Nr(e),u=(c=c==Yn?ei:c)==ei,m=(a=a==Yn?ei:a)==ei,d=c==a;if(d&&ue(t)){if(!ue(e))return!1;s=!0,u=!1}if(d&&!u)return i||(i=new Ot),s||ke(t)?Pn(t,e,r,o,n,i):Kn(t,e,c,r,o,n,i);if(!(r&Jn)){var h=u&&ri.call(t,"__wrapped__"),f=m&&ri.call(e,"__wrapped__");if(h||f){var b=h?t.value():t,p=f?e.value():e;return i||(i=new Ot),n(b,p,r,o,i)}}return!!d&&(i||(i=new Ot),Qn(t,e,r,o,n,i))};const ni=function t(e,r,o,n,i){return e===r||(null==e||null==r||!Kt(e)&&!Kt(r)?e!=e&&r!=r:oi(e,r,o,n,t,i))};const ii=function(t,e){return ni(t,e)};class si extends t.Plugin{static get requires(){return[nn]}static get pluginName(){return"DocumentListElementSupport"}init(){const t=this.editor;if(!t.plugins.has("DocumentListEditing"))return;const e=t.model.schema,r=t.conversion,o=t.plugins.get(nn),n=t.plugins.get("DocumentListEditing");n.registerDowncastStrategy({scope:"item",attributeName:"htmlLiAttributes",setAttributeOnDowncast(t,e,r){Ro(t,e,r)}}),n.registerDowncastStrategy({scope:"list",attributeName:"htmlListAttributes",setAttributeOnDowncast(t,e,r){Ro(t,e,r)}}),o.on("register",((t,n)=>{["ul","ol","li"].includes(n.view)&&(t.stop(),e.checkAttribute("$block","htmlListAttributes")||(e.extend("$block",{allowAttributes:["htmlListAttributes","htmlLiAttributes"]}),e.extend("$blockObject",{allowAttributes:["htmlListAttributes","htmlLiAttributes"]}),e.extend("$container",{allowAttributes:["htmlListAttributes","htmlLiAttributes"]}),r.for("upcast").add((t=>{t.on("element:ul",li("htmlListAttributes",o),{priority:"low"}),t.on("element:ol",li("htmlListAttributes",o),{priority:"low"}),t.on("element:li",li("htmlLiAttributes",o),{priority:"low"})}))))})),n.on("postFixer",((t,{listNodes:e,writer:r})=>{const o=[];for(const{node:n,previous:i}of e){if(!i)continue;const e=n.getAttribute("listIndent"),s=i.getAttribute("listIndent");let l=null;if(e>s?o[s]=i:e<s?(l=o[e],o.length=e):l=i,l){if(l.getAttribute("listType")==n.getAttribute("listType")){const e=l.getAttribute("htmlListAttributes");ii(n.getAttribute("htmlListAttributes"),e)||(r.setAttribute("htmlListAttributes",e,n),t.return=!0)}if(l.getAttribute("listItemId")==n.getAttribute("listItemId")){const e=l.getAttribute("htmlLiAttributes");ii(n.getAttribute("htmlLiAttributes"),e)||(r.setAttribute("htmlLiAttributes",e,n),t.return=!0)}}}}))}afterInit(){const t=this.editor;t.commands.get("indentList")&&this.listenTo(t.commands.get("indentList"),"afterExecute",((e,r)=>{t.model.change((t=>{for(const e of r)t.setAttribute("htmlListAttributes",{},e)}))}))}}function li(t,e){return(r,o,n)=>{const i=o.viewItem;o.modelRange||Object.assign(o,n.convertChildren(o.viewItem,o.modelCursor));const s=e.processViewAttributes(i,n);for(const e of o.modelRange.getItems({shallow:!0}))e.hasAttribute("listItemId")&&(e.hasAttribute(t)||n.writer.setAttribute(t,s||{},e))}}class ci extends t.Plugin{static get requires(){return[nn,or]}static get pluginName(){return"CustomElementSupport"}init(){const t=this.editor.plugins.get(nn),e=this.editor.plugins.get(or);t.on("register:$customElement",((r,o)=>{r.stop();const n=this.editor,i=n.model.schema,s=n.conversion,l=n.editing.view.domConverter.unsafeElements,c=n.data.htmlProcessor.domConverter.preElements;i.register(o.model,o.modelSchema),i.extend(o.model,{allowAttributes:["htmlElementName","htmlAttributes","htmlContent"],isContent:!0}),s.for("upcast").elementToElement({view:/.*/,model:(r,i)=>{if("$comment"==r.name)return;if(!function(t){try{document.createElement(t)}catch(t){return!1}return!0}(r.name))return;if(e.getDefinitionsForView(r.name).size)return;l.includes(r.name)||l.push(r.name),c.includes(r.name)||c.push(r.name);const s=i.writer.createElement(o.model,{htmlElementName:r.name}),a=t.processViewAttributes(r,i);a&&i.writer.setAttribute("htmlAttributes",a,s);const u=new nr.UpcastWriter(r.document).createDocumentFragment(r),m=n.data.processor.toData(u);i.writer.setAttribute("htmlContent",m,s);for(const{item:t}of n.editing.view.createRangeIn(r))i.consumable.consume(t,{name:!0});return s},converterPriority:"low"}),s.for("editingDowncast").elementToElement({model:{name:o.model,attributes:["htmlElementName","htmlAttributes","htmlContent"]},view:(t,{writer:e})=>{const r=t.getAttribute("htmlElementName"),o=e.createRawElement(r);return t.hasAttribute("htmlAttributes")&&Ro(e,t.getAttribute("htmlAttributes"),o),o}}),s.for("dataDowncast").elementToElement({model:{name:o.model,attributes:["htmlElementName","htmlAttributes","htmlContent"]},view:(t,{writer:e})=>{const r=t.getAttribute("htmlElementName"),o=t.getAttribute("htmlContent"),n=e.createRawElement(r,null,((t,e)=>{e.setContentOf(t,o);const r=t.firstChild;for(r.remove();r.firstChild;)t.appendChild(r.firstChild)}));return t.hasAttribute("htmlAttributes")&&Ro(e,t.getAttribute("htmlAttributes"),n),n}})}))}}class ai extends t.Plugin{static get pluginName(){return"GeneralHtmlSupport"}static get requires(){return[nn,dn,hn,fn,bn,gn,vn,wn,yn,si,ci]}init(){const t=this.editor,e=t.plugins.get(nn);e.loadAllowedConfig(t.config.get("htmlSupport.allow")||[]),e.loadDisallowedConfig(t.config.get("htmlSupport.disallow")||[])}getGhsAttributeNameForElement(t){const e=this.editor.plugins.get("DataSchema"),r=Array.from(e.getDefinitionsForView(t,!1));return r&&r.length&&r[0].isInline&&!r[0].isObject?r[0].model:"htmlAttributes"}addModelHtmlClass(t,r,o){const n=this.editor.model,i=this.getGhsAttributeNameForElement(t);n.change((t=>{for(const s of ui(n,o,i))mi(t,s,i,"classes",(t=>{for(const o of(0,e.toArray)(r))t.add(o)}))}))}removeModelHtmlClass(t,r,o){const n=this.editor.model,i=this.getGhsAttributeNameForElement(t);n.change((t=>{for(const s of ui(n,o,i))mi(t,s,i,"classes",(t=>{for(const o of(0,e.toArray)(r))t.delete(o)}))}))}setModelHtmlAttributes(t,e,r){const o=this.editor.model,n=this.getGhsAttributeNameForElement(t);o.change((t=>{for(const i of ui(o,r,n))mi(t,i,n,"attributes",(t=>{for(const[r,o]of Object.entries(e))t.set(r,o)}))}))}removeModelHtmlAttributes(t,r,o){const n=this.editor.model,i=this.getGhsAttributeNameForElement(t);n.change((t=>{for(const s of ui(n,o,i))mi(t,s,i,"attributes",(t=>{for(const o of(0,e.toArray)(r))t.delete(o)}))}))}setModelHtmlStyles(t,e,r){const o=this.editor.model,n=this.getGhsAttributeNameForElement(t);o.change((t=>{for(const i of ui(o,r,n))mi(t,i,n,"styles",(t=>{for(const[r,o]of Object.entries(e))t.set(r,o)}))}))}removeModelHtmlStyles(t,r,o){const n=this.editor.model,i=this.getGhsAttributeNameForElement(t);n.change((t=>{for(const s of ui(n,o,i))mi(t,s,i,"styles",(t=>{for(const o of(0,e.toArray)(r))t.delete(o)}))}))}}function*ui(t,e,r){if(e.is("documentSelection")&&e.isCollapsed)t.schema.checkAttributeInSelection(e,r)&&(yield e);else for(const o of function(t,e,r){return e.is("node")||e.is("$text")||e.is("$textProxy")?t.schema.checkAttribute(e,r)?[t.createRangeOn(e)]:[]:t.schema.getValidRanges(t.createSelection(e).getRanges(),r)}(t,e,r))yield*o.getItems({shallow:!0})}function mi(t,e,r,o,n){const i=e.getAttribute(r),s={};for(const t of["attributes","styles","classes"])if(t!=o)i&&i[t]&&(s[t]=i[t]);else{const e="classes"==t?new Set(i&&i[t]||[]):new Map(Object.entries(i&&i[t]||{}));n(e),e.size&&(s[t]="classes"==t?Array.from(e):Object.fromEntries(e))}Object.keys(s).length?e.is("documentSelection")?t.setSelectionAttribute(r,s):t.setAttribute(r,s,e):i&&(e.is("documentSelection")?t.removeSelectionAttribute(r):t.removeAttribute(r,e))}class di extends t.Plugin{static get pluginName(){return"HtmlComment"}init(){const t=this.editor;t.data.processor.skipComments=!1,t.model.schema.addAttributeCheck(((t,e)=>{if(t.endsWith("$root")&&e.startsWith("$comment"))return!0})),t.conversion.for("upcast").elementToMarker({view:"$comment",model:(t,{writer:r})=>{const o=this.editor.model.document.getRoot(),n=t.getCustomProperty("$rawContent"),i=`$comment:${(0,e.uid)()}`;return r.setAttribute(i,n,o),i}}),t.conversion.for("dataDowncast").markerToElement({model:"$comment",view:(t,{writer:e})=>{const r=this.editor.model.document.getRoot(),o=t.markerName,n=r.getAttribute(o),i=e.createUIElement("$comment");return e.setCustomProperty("$rawContent",n,i),i}}),t.model.document.registerPostFixer((e=>{const r=t.model.document.getRoot(),o=t.model.document.differ.getChangedMarkers().filter((t=>t.name.startsWith("$comment"))).filter((t=>{const e=t.data.newRange;return e&&"$graveyard"===e.root.rootName}));if(0===o.length)return!1;for(const t of o)e.removeMarker(t.name),e.removeAttribute(t.name,r);return!0})),t.data.on("set",(()=>{for(const e of t.model.markers.getMarkersGroup("$comment"))this.removeHtmlComment(e.name)}),{priority:"high"}),t.model.on("deleteContent",((e,[r])=>{for(const e of r.getRanges()){const r=t.model.schema.getLimitElement(e),o=t.model.createPositionAt(r,0),n=t.model.createPositionAt(r,"end");let i;i=o.isTouching(e.start)&&n.isTouching(e.end)?this.getHtmlCommentsInRange(t.model.createRange(o,n)):this.getHtmlCommentsInRange(e,{skipBoundaries:!0});for(const t of i)this.removeHtmlComment(t)}}),{priority:"high"})}createHtmlComment(t,r){const o=(0,e.uid)(),n=this.editor.model,i=n.document.getRoot(),s=`$comment:${o}`;return n.change((e=>{const o=e.createRange(t);return e.addMarker(s,{usingOperation:!0,affectsData:!0,range:o}),e.setAttribute(s,r,i),s}))}removeHtmlComment(t){const e=this.editor,r=e.model.document.getRoot(),o=e.model.markers.get(t);return!!o&&(e.model.change((e=>{e.removeMarker(o),e.removeAttribute(t,r)})),!0)}getHtmlCommentData(t){const e=this.editor,r=e.model.markers.get(t),o=e.model.document.getRoot();return r?{content:o.getAttribute(t),position:r.getStart()}:null}getHtmlCommentsInRange(t,{skipBoundaries:e=!1}={}){const r=!e;return Array.from(this.editor.model.markers.getMarkersGroup("$comment")).filter((e=>function(t,e){const o=t.getRange().start;return(o.isAfter(e.start)||r&&o.isEqual(e.start))&&(o.isBefore(e.end)||r&&o.isEqual(e.end))}(e,t))).map((t=>t.name))}}class hi extends nr.HtmlDataProcessor{toView(t){if(!t.match(/<(?:html|body|head|meta)(?:\s[^>]*)?>/i))return super.toView(t);let e="",r="";t=(t=t.replace(/<!DOCTYPE[^>]*>/i,(t=>(e=t,"")))).replace(/<\?xml\s[^?]*\?>/i,(t=>(r=t,"")));const o=this._toDom(t),n=this.domConverter.domToView(o,{skipComments:this.skipComments}),i=new nr.UpcastWriter(n.document);return i.setCustomProperty("$fullPageDocument",o.ownerDocument.documentElement.outerHTML,n),e&&i.setCustomProperty("$fullPageDocType",e,n),r&&i.setCustomProperty("$fullPageXmlDeclaration",r,n),n}toData(t){let e=super.toData(t);const r=t.getCustomProperty("$fullPageDocument"),o=t.getCustomProperty("$fullPageDocType"),n=t.getCustomProperty("$fullPageXmlDeclaration");return r&&(e=r.replace(/<\/body\s*>/,e+"$&"),o&&(e=o+"\n"+e),n&&(e=n+"\n"+e)),e}}class fi extends t.Plugin{static get pluginName(){return"FullPage"}init(){const t=this.editor,e=["$fullPageDocument","$fullPageDocType","$fullPageXmlDeclaration"];t.data.processor=new hi(t.data.viewDocument),t.model.schema.extend("$root",{allowAttributes:e}),t.data.on("toModel",((r,[o])=>{const n=t.model.document.getRoot();t.model.change((t=>{for(const r of e){const e=o.getCustomProperty(r);e&&t.setAttribute(r,e,n)}}))}),{priority:"low"}),t.data.on("toView",((t,[r])=>{if(!r.is("rootElement"))return;const o=r,n=t.return;if(!o.hasAttribute("$fullPageDocument"))return;const i=new nr.UpcastWriter(n.document);for(const t of e){const e=o.getAttribute(t);e&&i.setCustomProperty(t,e,n)}}),{priority:"low"}),t.data.on("set",(()=>{const r=t.model.document.getRoot();t.model.change((t=>{for(const o of e)r.hasAttribute(o)&&t.removeAttribute(o,r)}))}),{priority:"high"}),t.data.on("get",((t,e)=>{e[0]||(e[0]={}),e[0].trim=!1}),{priority:"high"})}}})(),(window.CKEditor5=window.CKEditor5||{}).htmlSupport=o})();
|
|
5
|
+
*/(()=>{var t={142:(t,e,r)=>{"use strict";r.d(e,{Z:()=>i});var o=r(609),n=r.n(o)()((function(t){return t[1]}));n.push([t.id,":root{--ck-html-object-embed-unfocused-outline-width:1px}.ck-widget.html-object-embed{background-color:var(--ck-color-base-foreground);font-size:var(--ck-font-size-base);min-width:calc(76px + var(--ck-spacing-standard));padding:var(--ck-spacing-small);padding-top:calc(var(--ck-font-size-tiny) + var(--ck-spacing-large))}.ck-widget.html-object-embed:not(.ck-widget_selected):not(:hover){outline:var(--ck-html-object-embed-unfocused-outline-width) dashed var(--ck-color-widget-blurred-border)}.ck-widget.html-object-embed:before{background:#999;border-radius:0 0 var(--ck-border-radius) var(--ck-border-radius);color:var(--ck-color-base-background);content:attr(data-html-object-embed-label);font-family:var(--ck-font-face);font-size:var(--ck-font-size-tiny);font-style:normal;font-weight:400;left:var(--ck-spacing-standard);padding:calc(var(--ck-spacing-tiny) + var(--ck-html-object-embed-unfocused-outline-width)) var(--ck-spacing-small) var(--ck-spacing-tiny);position:absolute;top:0;transition:background var(--ck-widget-handler-animation-duration) var(--ck-widget-handler-animation-curve)}.ck-widget.html-object-embed .ck-widget__type-around .ck-widget__type-around__button.ck-widget__type-around__button_before{margin-left:50px}.ck-widget.html-object-embed .html-object-embed__content{pointer-events:none}div.ck-widget.html-object-embed{margin:1em auto}span.ck-widget.html-object-embed{display:inline-block}",""]);const i=n},609:t=>{"use strict";t.exports=function(t){var e=[];return e.toString=function(){return this.map((function(e){var r=t(e);return e[2]?"@media ".concat(e[2]," {").concat(r,"}"):r})).join("")},e.i=function(t,r,o){"string"==typeof t&&(t=[[null,t,""]]);var n={};if(o)for(var i=0;i<this.length;i++){var l=this[i][0];null!=l&&(n[l]=!0)}for(var s=0;s<t.length;s++){var c=[].concat(t[s]);o&&n[c[0]]||(r&&(c[2]?c[2]="".concat(r," and ").concat(c[2]):c[2]=r),e.push(c))}},e}},62:(t,e,r)=>{"use strict";var o,n=function(){return void 0===o&&(o=Boolean(window&&document&&document.all&&!window.atob)),o},i=function(){var t={};return function(e){if(void 0===t[e]){var r=document.querySelector(e);if(window.HTMLIFrameElement&&r instanceof window.HTMLIFrameElement)try{r=r.contentDocument.head}catch(t){r=null}t[e]=r}return t[e]}}(),l=[];function s(t){for(var e=-1,r=0;r<l.length;r++)if(l[r].identifier===t){e=r;break}return e}function c(t,e){for(var r={},o=[],n=0;n<t.length;n++){var i=t[n],c=e.base?i[0]+e.base:i[0],a=r[c]||0,u="".concat(c," ").concat(a);r[c]=a+1;var m=s(u),d={css:i[1],media:i[2],sourceMap:i[3]};-1!==m?(l[m].references++,l[m].updater(d)):l.push({identifier:u,updater:p(d,e),references:1}),o.push(u)}return o}function a(t){var e=document.createElement("style"),o=t.attributes||{};if(void 0===o.nonce){var n=r.nc;n&&(o.nonce=n)}if(Object.keys(o).forEach((function(t){e.setAttribute(t,o[t])})),"function"==typeof t.insert)t.insert(e);else{var l=i(t.insert||"head");if(!l)throw new Error("Couldn't find a style target. This probably means that the value for the 'insert' parameter is invalid.");l.appendChild(e)}return e}var u,m=(u=[],function(t,e){return u[t]=e,u.filter(Boolean).join("\n")});function d(t,e,r,o){var n=r?"":o.media?"@media ".concat(o.media," {").concat(o.css,"}"):o.css;if(t.styleSheet)t.styleSheet.cssText=m(e,n);else{var i=document.createTextNode(n),l=t.childNodes;l[e]&&t.removeChild(l[e]),l.length?t.insertBefore(i,l[e]):t.appendChild(i)}}function h(t,e,r){var o=r.css,n=r.media,i=r.sourceMap;if(n?t.setAttribute("media",n):t.removeAttribute("media"),i&&"undefined"!=typeof btoa&&(o+="\n/*# sourceMappingURL=data:application/json;base64,".concat(btoa(unescape(encodeURIComponent(JSON.stringify(i))))," */")),t.styleSheet)t.styleSheet.cssText=o;else{for(;t.firstChild;)t.removeChild(t.firstChild);t.appendChild(document.createTextNode(o))}}var f=null,b=0;function p(t,e){var r,o,n;if(e.singleton){var i=b++;r=f||(f=a(e)),o=d.bind(null,r,i,!1),n=d.bind(null,r,i,!0)}else r=a(e),o=h.bind(null,r,e),n=function(){!function(t){if(null===t.parentNode)return!1;t.parentNode.removeChild(t)}(r)};return o(t),function(e){if(e){if(e.css===t.css&&e.media===t.media&&e.sourceMap===t.sourceMap)return;o(t=e)}else n()}}t.exports=function(t,e){(e=e||{}).singleton||"boolean"==typeof e.singleton||(e.singleton=n());var r=c(t=t||[],e);return function(t){if(t=t||[],"[object Array]"===Object.prototype.toString.call(t)){for(var o=0;o<r.length;o++){var n=s(r[o]);l[n].references--}for(var i=c(t,e),a=0;a<r.length;a++){var u=s(r[a]);0===l[u].references&&(l[u].updater(),l.splice(u,1))}r=i}}}},704:(t,e,r)=>{t.exports=r(79)("./src/core.js")},105:(t,e,r)=>{t.exports=r(79)("./src/engine.js")},209:(t,e,r)=>{t.exports=r(79)("./src/utils.js")},995:(t,e,r)=>{t.exports=r(79)("./src/widget.js")},79:t=>{"use strict";t.exports=CKEditor5.dll}},e={};function r(o){var n=e[o];if(void 0!==n)return n.exports;var i=e[o]={id:o,exports:{}};return t[o](i,i.exports,r),i.exports}r.n=t=>{var e=t&&t.__esModule?()=>t.default:()=>t;return r.d(e,{a:e}),e},r.d=(t,e)=>{for(var o in e)r.o(e,o)&&!r.o(t,o)&&Object.defineProperty(t,o,{enumerable:!0,get:e[o]})},r.o=(t,e)=>Object.prototype.hasOwnProperty.call(t,e),r.r=t=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},r.nc=void 0;var o={};(()=>{"use strict";r.r(o),r.d(o,{DataFilter:()=>nn,DataSchema:()=>Uo,FullPage:()=>fi,GeneralHtmlSupport:()=>ai,HtmlComment:()=>di,HtmlPageDataProcessor:()=>hi});var t=r(704),e=r(209),n=r(105),i=r(995);const l=function(){this.__data__=[],this.size=0};const s=function(t,e){return t===e||t!=t&&e!=e};const c=function(t,e){for(var r=t.length;r--;)if(s(t[r][0],e))return r;return-1};var a=Array.prototype.splice;const u=function(t){var e=this.__data__,r=c(e,t);return!(r<0)&&(r==e.length-1?e.pop():a.call(e,r,1),--this.size,!0)};const m=function(t){var e=this.__data__,r=c(e,t);return r<0?void 0:e[r][1]};const d=function(t){return c(this.__data__,t)>-1};const h=function(t,e){var r=this.__data__,o=c(r,t);return o<0?(++this.size,r.push([t,e])):r[o][1]=e,this};function f(t){var e=-1,r=null==t?0:t.length;for(this.clear();++e<r;){var o=t[e];this.set(o[0],o[1])}}f.prototype.clear=l,f.prototype.delete=u,f.prototype.get=m,f.prototype.has=d,f.prototype.set=h;const b=f;const p=function(){this.__data__=new b,this.size=0};const g=function(t){var e=this.__data__,r=e.delete(t);return this.size=e.size,r};const v=function(t){return this.__data__.get(t)};const w=function(t){return this.__data__.has(t)};const y="object"==typeof global&&global&&global.Object===Object&&global;var A="object"==typeof self&&self&&self.Object===Object&&self;const j=y||A||Function("return this")();const _=j.Symbol;var S=Object.prototype,E=S.hasOwnProperty,k=S.toString,O=_?_.toStringTag:void 0;const C=function(t){var e=E.call(t,O),r=t[O];try{t[O]=void 0;var o=!0}catch(t){}var n=k.call(t);return o&&(e?t[O]=r:delete t[O]),n};var $=Object.prototype.toString;const P=function(t){return $.call(t)};var F="[object Null]",x="[object Undefined]",I=_?_.toStringTag:void 0;const D=function(t){return null==t?void 0===t?x:F:I&&I in Object(t)?C(t):P(t)};const T=function(t){var e=typeof t;return null!=t&&("object"==e||"function"==e)};var B="[object AsyncFunction]",R="[object Function]",M="[object GeneratorFunction]",L="[object Proxy]";const N=function(t){if(!T(t))return!1;var e=D(t);return e==R||e==M||e==B||e==L};const V=j["__core-js_shared__"];var H,z=(H=/[^.]+$/.exec(V&&V.keys&&V.keys.IE_PROTO||""))?"Symbol(src)_1."+H:"";const U=function(t){return!!z&&z in t};var q=Function.prototype.toString;const W=function(t){if(null!=t){try{return q.call(t)}catch(t){}try{return t+""}catch(t){}}return""};var G=/^\[object .+?Constructor\]$/,K=Function.prototype,X=Object.prototype,Z=K.toString,Q=X.hasOwnProperty,J=RegExp("^"+Z.call(Q).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");const Y=function(t){return!(!T(t)||U(t))&&(N(t)?J:G).test(W(t))};const tt=function(t,e){return null==t?void 0:t[e]};const et=function(t,e){var r=tt(t,e);return Y(r)?r:void 0};const rt=et(j,"Map");const ot=et(Object,"create");const nt=function(){this.__data__=ot?ot(null):{},this.size=0};const it=function(t){var e=this.has(t)&&delete this.__data__[t];return this.size-=e?1:0,e};var lt="__lodash_hash_undefined__",st=Object.prototype.hasOwnProperty;const ct=function(t){var e=this.__data__;if(ot){var r=e[t];return r===lt?void 0:r}return st.call(e,t)?e[t]:void 0};var at=Object.prototype.hasOwnProperty;const ut=function(t){var e=this.__data__;return ot?void 0!==e[t]:at.call(e,t)};var mt="__lodash_hash_undefined__";const dt=function(t,e){var r=this.__data__;return this.size+=this.has(t)?0:1,r[t]=ot&&void 0===e?mt:e,this};function ht(t){var e=-1,r=null==t?0:t.length;for(this.clear();++e<r;){var o=t[e];this.set(o[0],o[1])}}ht.prototype.clear=nt,ht.prototype.delete=it,ht.prototype.get=ct,ht.prototype.has=ut,ht.prototype.set=dt;const ft=ht;const bt=function(){this.size=0,this.__data__={hash:new ft,map:new(rt||b),string:new ft}};const pt=function(t){var e=typeof t;return"string"==e||"number"==e||"symbol"==e||"boolean"==e?"__proto__"!==t:null===t};const gt=function(t,e){var r=t.__data__;return pt(e)?r["string"==typeof e?"string":"hash"]:r.map};const vt=function(t){var e=gt(this,t).delete(t);return this.size-=e?1:0,e};const wt=function(t){return gt(this,t).get(t)};const yt=function(t){return gt(this,t).has(t)};const At=function(t,e){var r=gt(this,t),o=r.size;return r.set(t,e),this.size+=r.size==o?0:1,this};function jt(t){var e=-1,r=null==t?0:t.length;for(this.clear();++e<r;){var o=t[e];this.set(o[0],o[1])}}jt.prototype.clear=bt,jt.prototype.delete=vt,jt.prototype.get=wt,jt.prototype.has=yt,jt.prototype.set=At;const _t=jt;var St=200;const Et=function(t,e){var r=this.__data__;if(r instanceof b){var o=r.__data__;if(!rt||o.length<St-1)return o.push([t,e]),this.size=++r.size,this;r=this.__data__=new _t(o)}return r.set(t,e),this.size=r.size,this};function kt(t){var e=this.__data__=new b(t);this.size=e.size}kt.prototype.clear=p,kt.prototype.delete=g,kt.prototype.get=v,kt.prototype.has=w,kt.prototype.set=Et;const Ot=kt;const Ct=function(t,e){for(var r=-1,o=null==t?0:t.length;++r<o&&!1!==e(t[r],r,t););return t};const $t=function(){try{var t=et(Object,"defineProperty");return t({},"",{}),t}catch(t){}}();const Pt=function(t,e,r){"__proto__"==e&&$t?$t(t,e,{configurable:!0,enumerable:!0,value:r,writable:!0}):t[e]=r};var Ft=Object.prototype.hasOwnProperty;const xt=function(t,e,r){var o=t[e];Ft.call(t,e)&&s(o,r)&&(void 0!==r||e in t)||Pt(t,e,r)};const It=function(t,e,r,o){var n=!r;r||(r={});for(var i=-1,l=e.length;++i<l;){var s=e[i],c=o?o(r[s],t[s],s,r,t):void 0;void 0===c&&(c=t[s]),n?Pt(r,s,c):xt(r,s,c)}return r};const Dt=function(t,e){for(var r=-1,o=Array(t);++r<t;)o[r]=e(r);return o};const Tt=function(t){return null!=t&&"object"==typeof t};var Bt="[object Arguments]";const Rt=function(t){return Tt(t)&&D(t)==Bt};var Mt=Object.prototype,Lt=Mt.hasOwnProperty,Nt=Mt.propertyIsEnumerable;const Vt=Rt(function(){return arguments}())?Rt:function(t){return Tt(t)&&Lt.call(t,"callee")&&!Nt.call(t,"callee")};const Ht=Array.isArray;const zt=function(){return!1};var Ut="object"==typeof exports&&exports&&!exports.nodeType&&exports,qt=Ut&&"object"==typeof module&&module&&!module.nodeType&&module,Wt=qt&&qt.exports===Ut?j.Buffer:void 0;const Gt=(Wt?Wt.isBuffer:void 0)||zt;var Kt=9007199254740991,Xt=/^(?:0|[1-9]\d*)$/;const Zt=function(t,e){var r=typeof t;return!!(e=null==e?Kt:e)&&("number"==r||"symbol"!=r&&Xt.test(t))&&t>-1&&t%1==0&&t<e};var Qt=9007199254740991;const Jt=function(t){return"number"==typeof t&&t>-1&&t%1==0&&t<=Qt};var Yt={};Yt["[object Float32Array]"]=Yt["[object Float64Array]"]=Yt["[object Int8Array]"]=Yt["[object Int16Array]"]=Yt["[object Int32Array]"]=Yt["[object Uint8Array]"]=Yt["[object Uint8ClampedArray]"]=Yt["[object Uint16Array]"]=Yt["[object Uint32Array]"]=!0,Yt["[object Arguments]"]=Yt["[object Array]"]=Yt["[object ArrayBuffer]"]=Yt["[object Boolean]"]=Yt["[object DataView]"]=Yt["[object Date]"]=Yt["[object Error]"]=Yt["[object Function]"]=Yt["[object Map]"]=Yt["[object Number]"]=Yt["[object Object]"]=Yt["[object RegExp]"]=Yt["[object Set]"]=Yt["[object String]"]=Yt["[object WeakMap]"]=!1;const te=function(t){return Tt(t)&&Jt(t.length)&&!!Yt[D(t)]};const ee=function(t){return function(e){return t(e)}};var re="object"==typeof exports&&exports&&!exports.nodeType&&exports,oe=re&&"object"==typeof module&&module&&!module.nodeType&&module,ne=oe&&oe.exports===re&&y.process;const ie=function(){try{var t=oe&&oe.require&&oe.require("util").types;return t||ne&&ne.binding&&ne.binding("util")}catch(t){}}();var le=ie&&ie.isTypedArray;const se=le?ee(le):te;var ce=Object.prototype.hasOwnProperty;const ae=function(t,e){var r=Ht(t),o=!r&&Vt(t),n=!r&&!o&&Gt(t),i=!r&&!o&&!n&&se(t),l=r||o||n||i,s=l?Dt(t.length,String):[],c=s.length;for(var a in t)!e&&!ce.call(t,a)||l&&("length"==a||n&&("offset"==a||"parent"==a)||i&&("buffer"==a||"byteLength"==a||"byteOffset"==a)||Zt(a,c))||s.push(a);return s};var ue=Object.prototype;const me=function(t){var e=t&&t.constructor;return t===("function"==typeof e&&e.prototype||ue)};const de=function(t,e){return function(r){return t(e(r))}};const he=de(Object.keys,Object);var fe=Object.prototype.hasOwnProperty;const be=function(t){if(!me(t))return he(t);var e=[];for(var r in Object(t))fe.call(t,r)&&"constructor"!=r&&e.push(r);return e};const pe=function(t){return null!=t&&Jt(t.length)&&!N(t)};const ge=function(t){return pe(t)?ae(t):be(t)};const ve=function(t,e){return t&&It(e,ge(e),t)};const we=function(t){var e=[];if(null!=t)for(var r in Object(t))e.push(r);return e};var ye=Object.prototype.hasOwnProperty;const Ae=function(t){if(!T(t))return we(t);var e=me(t),r=[];for(var o in t)("constructor"!=o||!e&&ye.call(t,o))&&r.push(o);return r};const je=function(t){return pe(t)?ae(t,!0):Ae(t)};const _e=function(t,e){return t&&It(e,je(e),t)};var Se="object"==typeof exports&&exports&&!exports.nodeType&&exports,Ee=Se&&"object"==typeof module&&module&&!module.nodeType&&module,ke=Ee&&Ee.exports===Se?j.Buffer:void 0,Oe=ke?ke.allocUnsafe:void 0;const Ce=function(t,e){if(e)return t.slice();var r=t.length,o=Oe?Oe(r):new t.constructor(r);return t.copy(o),o};const $e=function(t,e){var r=-1,o=t.length;for(e||(e=Array(o));++r<o;)e[r]=t[r];return e};const Pe=function(t,e){for(var r=-1,o=null==t?0:t.length,n=0,i=[];++r<o;){var l=t[r];e(l,r,t)&&(i[n++]=l)}return i};const Fe=function(){return[]};var xe=Object.prototype.propertyIsEnumerable,Ie=Object.getOwnPropertySymbols;const De=Ie?function(t){return null==t?[]:(t=Object(t),Pe(Ie(t),(function(e){return xe.call(t,e)})))}:Fe;const Te=function(t,e){return It(t,De(t),e)};const Be=function(t,e){for(var r=-1,o=e.length,n=t.length;++r<o;)t[n+r]=e[r];return t};const Re=de(Object.getPrototypeOf,Object);const Me=Object.getOwnPropertySymbols?function(t){for(var e=[];t;)Be(e,De(t)),t=Re(t);return e}:Fe;const Le=function(t,e){return It(t,Me(t),e)};const Ne=function(t,e,r){var o=e(t);return Ht(t)?o:Be(o,r(t))};const Ve=function(t){return Ne(t,ge,De)};const He=function(t){return Ne(t,je,Me)};const ze=et(j,"DataView");const Ue=et(j,"Promise");const qe=et(j,"Set");const We=et(j,"WeakMap");var Ge="[object Map]",Ke="[object Promise]",Xe="[object Set]",Ze="[object WeakMap]",Qe="[object DataView]",Je=W(ze),Ye=W(rt),tr=W(Ue),er=W(qe),rr=W(We),or=D;(ze&&or(new ze(new ArrayBuffer(1)))!=Qe||rt&&or(new rt)!=Ge||Ue&&or(Ue.resolve())!=Ke||qe&&or(new qe)!=Xe||We&&or(new We)!=Ze)&&(or=function(t){var e=D(t),r="[object Object]"==e?t.constructor:void 0,o=r?W(r):"";if(o)switch(o){case Je:return Qe;case Ye:return Ge;case tr:return Ke;case er:return Xe;case rr:return Ze}return e});const nr=or;var ir=Object.prototype.hasOwnProperty;const lr=function(t){var e=t.length,r=new t.constructor(e);return e&&"string"==typeof t[0]&&ir.call(t,"index")&&(r.index=t.index,r.input=t.input),r};const sr=j.Uint8Array;const cr=function(t){var e=new t.constructor(t.byteLength);return new sr(e).set(new sr(t)),e};const ar=function(t,e){var r=e?cr(t.buffer):t.buffer;return new t.constructor(r,t.byteOffset,t.byteLength)};var ur=/\w*$/;const mr=function(t){var e=new t.constructor(t.source,ur.exec(t));return e.lastIndex=t.lastIndex,e};var dr=_?_.prototype:void 0,hr=dr?dr.valueOf:void 0;const fr=function(t){return hr?Object(hr.call(t)):{}};const br=function(t,e){var r=e?cr(t.buffer):t.buffer;return new t.constructor(r,t.byteOffset,t.length)};var pr="[object Boolean]",gr="[object Date]",vr="[object Map]",wr="[object Number]",yr="[object RegExp]",Ar="[object Set]",jr="[object String]",_r="[object Symbol]",Sr="[object ArrayBuffer]",Er="[object DataView]",kr="[object Float32Array]",Or="[object Float64Array]",Cr="[object Int8Array]",$r="[object Int16Array]",Pr="[object Int32Array]",Fr="[object Uint8Array]",xr="[object Uint8ClampedArray]",Ir="[object Uint16Array]",Dr="[object Uint32Array]";const Tr=function(t,e,r){var o=t.constructor;switch(e){case Sr:return cr(t);case pr:case gr:return new o(+t);case Er:return ar(t,r);case kr:case Or:case Cr:case $r:case Pr:case Fr:case xr:case Ir:case Dr:return br(t,r);case vr:return new o;case wr:case jr:return new o(t);case yr:return mr(t);case Ar:return new o;case _r:return fr(t)}};var Br=Object.create;const Rr=function(){function t(){}return function(e){if(!T(e))return{};if(Br)return Br(e);t.prototype=e;var r=new t;return t.prototype=void 0,r}}();const Mr=function(t){return"function"!=typeof t.constructor||me(t)?{}:Rr(Re(t))};var Lr="[object Map]";const Nr=function(t){return Tt(t)&&nr(t)==Lr};var Vr=ie&&ie.isMap;const Hr=Vr?ee(Vr):Nr;var zr="[object Set]";const Ur=function(t){return Tt(t)&&nr(t)==zr};var qr=ie&&ie.isSet;const Wr=qr?ee(qr):Ur;var Gr=1,Kr=2,Xr=4,Zr="[object Arguments]",Qr="[object Function]",Jr="[object GeneratorFunction]",Yr="[object Object]",to={};to[Zr]=to["[object Array]"]=to["[object ArrayBuffer]"]=to["[object DataView]"]=to["[object Boolean]"]=to["[object Date]"]=to["[object Float32Array]"]=to["[object Float64Array]"]=to["[object Int8Array]"]=to["[object Int16Array]"]=to["[object Int32Array]"]=to["[object Map]"]=to["[object Number]"]=to[Yr]=to["[object RegExp]"]=to["[object Set]"]=to["[object String]"]=to["[object Symbol]"]=to["[object Uint8Array]"]=to["[object Uint8ClampedArray]"]=to["[object Uint16Array]"]=to["[object Uint32Array]"]=!0,to["[object Error]"]=to[Qr]=to["[object WeakMap]"]=!1;const eo=function t(e,r,o,n,i,l){var s,c=r&Gr,a=r&Kr,u=r&Xr;if(o&&(s=i?o(e,n,i,l):o(e)),void 0!==s)return s;if(!T(e))return e;var m=Ht(e);if(m){if(s=lr(e),!c)return $e(e,s)}else{var d=nr(e),h=d==Qr||d==Jr;if(Gt(e))return Ce(e,c);if(d==Yr||d==Zr||h&&!i){if(s=a||h?{}:Mr(e),!c)return a?Le(e,_e(s,e)):Te(e,ve(s,e))}else{if(!to[d])return i?e:{};s=Tr(e,d,c)}}l||(l=new Ot);var f=l.get(e);if(f)return f;l.set(e,s),Wr(e)?e.forEach((function(n){s.add(t(n,r,o,n,e,l))})):Hr(e)&&e.forEach((function(n,i){s.set(i,t(n,r,o,i,e,l))}));var b=m?void 0:(u?a?He:Ve:a?je:ge)(e);return Ct(b||e,(function(n,i){b&&(n=e[i=n]),xt(s,i,t(n,r,o,i,e,l))})),s};var ro=1,oo=4;const no=function(t){return eo(t,ro|oo)};function io(t,e,r,o){e&&function(t,e,r){if(e.attributes)for(const[o]of Object.entries(e.attributes))t.removeAttribute(o,r);if(e.styles)for(const o of Object.keys(e.styles))t.removeStyle(o,r);e.classes&&t.removeClass(e.classes,r)}(t,e,o),r&&lo(t,r,o)}function lo(t,e,r){if(e.attributes)for(const[o,n]of Object.entries(e.attributes))t.setAttribute(o,n,r);e.styles&&t.setStyle(e.styles,r),e.classes&&t.addClass(e.classes,r)}function so(t,e){const r=no(t);let o="attributes";for(o in e)r[o]="classes"==o?Array.from(new Set([...t[o]||[],...e[o]])):{...t[o],...e[o]};return r}function co({model:t}){return(e,r)=>r.writer.createElement(t,{htmlContent:e.getCustomProperty("$rawContent")})}function ao(t,{view:e,isInline:r}){const o=t.t;return(t,{writer:n})=>{const l=o("HTML object"),s=uo(e,t,n),c=t.getAttribute("htmlAttributes");n.addClass("html-object-embed__content",s),c&&lo(n,c,s);const a=n.createContainerElement(r?"span":"div",{class:"html-object-embed","data-html-object-embed-label":l},s);return(0,i.toWidget)(a,n,{label:l})}}function uo(t,e,r){return r.createRawElement(t,null,((t,r)=>{r.setContentOf(t,e.getAttribute("htmlContent"))}))}function mo({priority:t,view:e}){return(r,o)=>{if(!r)return;const{writer:n}=o,i=n.createAttributeElement(e,null,{priority:t});return lo(n,r,i),i}}function ho({view:t},e){return r=>{r.on(`element:${t}`,((t,r,o)=>{if(!r.modelRange||r.modelRange.isCollapsed)return;const n=e.processViewAttributes(r.viewItem,o);n&&o.writer.setAttribute("htmlAttributes",n,r.modelRange)}),{priority:"low"})}}function fo({model:t}){return e=>{e.on(`attribute:htmlAttributes:${t}`,((t,e,r)=>{if(!r.consumable.consume(e.item,t.name))return;const{attributeOldValue:o,attributeNewValue:n}=e;io(r.writer,o,n,r.mapper.toViewElement(e.item))}))}}const bo=[{model:"codeBlock",view:"pre"},{model:"paragraph",view:"p"},{model:"blockQuote",view:"blockquote"},{model:"listItem",view:"li"},{model:"pageBreak",view:"div"},{model:"rawHtml",view:"div"},{model:"table",view:"table"},{model:"tableRow",view:"tr"},{model:"tableCell",view:"td"},{model:"tableCell",view:"th"},{model:"tableColumnGroup",view:"colgroup"},{model:"tableColumn",view:"col"},{model:"caption",view:"caption"},{model:"caption",view:"figcaption"},{model:"imageBlock",view:"img"},{model:"imageInline",view:"img"},{model:"htmlP",view:"p",modelSchema:{inheritAllFrom:"$block"}},{model:"htmlBlockquote",view:"blockquote",modelSchema:{inheritAllFrom:"$container"}},{model:"htmlTable",view:"table",modelSchema:{allowWhere:"$block",isBlock:!0}},{model:"htmlTbody",view:"tbody",modelSchema:{allowIn:"htmlTable",isBlock:!1}},{model:"htmlThead",view:"thead",modelSchema:{allowIn:"htmlTable",isBlock:!1}},{model:"htmlTfoot",view:"tfoot",modelSchema:{allowIn:"htmlTable",isBlock:!1}},{model:"htmlCaption",view:"caption",modelSchema:{allowIn:"htmlTable",allowChildren:"$text",isBlock:!1}},{model:"htmlColgroup",view:"colgroup",modelSchema:{allowIn:"htmlTable",allowChildren:"col",isBlock:!1}},{model:"htmlCol",view:"col",modelSchema:{allowIn:"htmlColgroup",isBlock:!1}},{model:"htmlTr",view:"tr",modelSchema:{allowIn:["htmlTable","htmlThead","htmlTbody"],isLimit:!0}},{model:"htmlTd",view:"td",modelSchema:{allowIn:"htmlTr",allowContentOf:"$container",isLimit:!0,isBlock:!1}},{model:"htmlTh",view:"th",modelSchema:{allowIn:"htmlTr",allowContentOf:"$container",isLimit:!0,isBlock:!1}},{model:"htmlFigure",view:"figure",modelSchema:{inheritAllFrom:"$container",isBlock:!1}},{model:"htmlFigcaption",view:"figcaption",modelSchema:{allowIn:"htmlFigure",allowChildren:"$text",isBlock:!1}},{model:"htmlAddress",view:"address",modelSchema:{inheritAllFrom:"$container",isBlock:!1}},{model:"htmlAside",view:"aside",modelSchema:{inheritAllFrom:"$container",isBlock:!1}},{model:"htmlMain",view:"main",modelSchema:{inheritAllFrom:"$container",isBlock:!1}},{model:"htmlDetails",view:"details",modelSchema:{inheritAllFrom:"$container",isBlock:!1}},{model:"htmlSummary",view:"summary",modelSchema:{allowChildren:"$text",allowIn:"htmlDetails",isBlock:!1}},{model:"htmlDiv",view:"div",paragraphLikeModel:"htmlDivParagraph",modelSchema:{inheritAllFrom:"$container"}},{model:"htmlFieldset",view:"fieldset",modelSchema:{inheritAllFrom:"$container",isBlock:!1}},{model:"htmlLegend",view:"legend",modelSchema:{allowIn:"htmlFieldset",allowChildren:"$text"}},{model:"htmlHeader",view:"header",modelSchema:{inheritAllFrom:"$container",isBlock:!1}},{model:"htmlFooter",view:"footer",modelSchema:{inheritAllFrom:"$container",isBlock:!1}},{model:"htmlForm",view:"form",modelSchema:{inheritAllFrom:"$container",isBlock:!0}},{model:"htmlHgroup",view:"hgroup",modelSchema:{allowChildren:["htmlH1","htmlH2","htmlH3","htmlH4","htmlH5","htmlH6"],isBlock:!1}},{model:"htmlH1",view:"h1",modelSchema:{inheritAllFrom:"$block"}},{model:"htmlH2",view:"h2",modelSchema:{inheritAllFrom:"$block"}},{model:"htmlH3",view:"h3",modelSchema:{inheritAllFrom:"$block"}},{model:"htmlH4",view:"h4",modelSchema:{inheritAllFrom:"$block"}},{model:"htmlH5",view:"h5",modelSchema:{inheritAllFrom:"$block"}},{model:"htmlH6",view:"h6",modelSchema:{inheritAllFrom:"$block"}},{model:"$htmlList",modelSchema:{allowWhere:"$container",allowChildren:["$htmlList","htmlLi"],isBlock:!1}},{model:"htmlDir",view:"dir",modelSchema:{inheritAllFrom:"$htmlList"}},{model:"htmlMenu",view:"menu",modelSchema:{inheritAllFrom:"$htmlList"}},{model:"htmlUl",view:"ul",modelSchema:{inheritAllFrom:"$htmlList"}},{model:"htmlOl",view:"ol",modelSchema:{inheritAllFrom:"$htmlList"}},{model:"htmlLi",view:"li",modelSchema:{allowIn:"$htmlList",allowChildren:"$text",isBlock:!1}},{model:"htmlPre",view:"pre",modelSchema:{inheritAllFrom:"$block"}},{model:"htmlArticle",view:"article",modelSchema:{inheritAllFrom:"$container",isBlock:!1}},{model:"htmlSection",view:"section",modelSchema:{inheritAllFrom:"$container",isBlock:!1}},{model:"htmlNav",view:"nav",modelSchema:{inheritAllFrom:"$container",isBlock:!1}},{model:"htmlDivDl",view:"div",modelSchema:{allowChildren:["htmlDt","htmlDd"],allowIn:"htmlDl"}},{model:"htmlDl",view:"dl",modelSchema:{allowWhere:"$container",allowChildren:["htmlDt","htmlDd","htmlDivDl"],isBlock:!1}},{model:"htmlDt",view:"dt",modelSchema:{allowChildren:"$block",isBlock:!1}},{model:"htmlDd",view:"dd",modelSchema:{allowChildren:"$block",isBlock:!1}},{model:"htmlCenter",view:"center",modelSchema:{inheritAllFrom:"$container",isBlock:!1}}],po=[{model:"htmlAcronym",view:"acronym",attributeProperties:{copyOnEnter:!0}},{model:"htmlTt",view:"tt",attributeProperties:{copyOnEnter:!0}},{model:"htmlFont",view:"font",attributeProperties:{copyOnEnter:!0}},{model:"htmlTime",view:"time",attributeProperties:{copyOnEnter:!0}},{model:"htmlVar",view:"var",attributeProperties:{copyOnEnter:!0}},{model:"htmlBig",view:"big",attributeProperties:{copyOnEnter:!0}},{model:"htmlSmall",view:"small",attributeProperties:{copyOnEnter:!0}},{model:"htmlSamp",view:"samp",attributeProperties:{copyOnEnter:!0}},{model:"htmlQ",view:"q",attributeProperties:{copyOnEnter:!0}},{model:"htmlOutput",view:"output",attributeProperties:{copyOnEnter:!0}},{model:"htmlKbd",view:"kbd",attributeProperties:{copyOnEnter:!0}},{model:"htmlBdi",view:"bdi",attributeProperties:{copyOnEnter:!0}},{model:"htmlBdo",view:"bdo",attributeProperties:{copyOnEnter:!0}},{model:"htmlAbbr",view:"abbr",attributeProperties:{copyOnEnter:!0}},{model:"htmlA",view:"a",priority:5,coupledAttribute:"linkHref",attributeProperties:{copyOnEnter:!0}},{model:"htmlStrong",view:"strong",coupledAttribute:"bold",attributeProperties:{copyOnEnter:!0,isFormatting:!0}},{model:"htmlB",view:"b",coupledAttribute:"bold",attributeProperties:{copyOnEnter:!0,isFormatting:!0}},{model:"htmlI",view:"i",coupledAttribute:"italic",attributeProperties:{copyOnEnter:!0,isFormatting:!0}},{model:"htmlEm",view:"em",coupledAttribute:"italic",attributeProperties:{copyOnEnter:!0,isFormatting:!0}},{model:"htmlS",view:"s",coupledAttribute:"strikethrough",attributeProperties:{copyOnEnter:!0,isFormatting:!0}},{model:"htmlDel",view:"del",coupledAttribute:"strikethrough",attributeProperties:{copyOnEnter:!0}},{model:"htmlIns",view:"ins",attributeProperties:{copyOnEnter:!0}},{model:"htmlU",view:"u",coupledAttribute:"underline",attributeProperties:{copyOnEnter:!0,isFormatting:!0}},{model:"htmlSub",view:"sub",coupledAttribute:"subscript",attributeProperties:{copyOnEnter:!0,isFormatting:!0}},{model:"htmlSup",view:"sup",coupledAttribute:"superscript",attributeProperties:{copyOnEnter:!0,isFormatting:!0}},{model:"htmlCode",view:"code",coupledAttribute:"code",attributeProperties:{copyOnEnter:!0,isFormatting:!0}},{model:"htmlMark",view:"mark",attributeProperties:{copyOnEnter:!0}},{model:"htmlSpan",view:"span",attributeProperties:{copyOnEnter:!0}},{model:"htmlCite",view:"cite",attributeProperties:{copyOnEnter:!0}},{model:"htmlLabel",view:"label",attributeProperties:{copyOnEnter:!0}},{model:"htmlDfn",view:"dfn",attributeProperties:{copyOnEnter:!0}},{model:"htmlObject",view:"object",isObject:!0,modelSchema:{inheritAllFrom:"$inlineObject"}},{model:"htmlIframe",view:"iframe",isObject:!0,modelSchema:{inheritAllFrom:"$inlineObject"}},{model:"htmlInput",view:"input",isObject:!0,modelSchema:{inheritAllFrom:"$inlineObject"}},{model:"htmlButton",view:"button",isObject:!0,modelSchema:{inheritAllFrom:"$inlineObject"}},{model:"htmlTextarea",view:"textarea",isObject:!0,modelSchema:{inheritAllFrom:"$inlineObject"}},{model:"htmlSelect",view:"select",isObject:!0,modelSchema:{inheritAllFrom:"$inlineObject"}},{model:"htmlVideo",view:"video",isObject:!0,modelSchema:{inheritAllFrom:"$inlineObject"}},{model:"htmlEmbed",view:"embed",isObject:!0,modelSchema:{inheritAllFrom:"$inlineObject"}},{model:"htmlOembed",view:"oembed",isObject:!0,modelSchema:{inheritAllFrom:"$inlineObject"}},{model:"htmlAudio",view:"audio",isObject:!0,modelSchema:{inheritAllFrom:"$inlineObject"}},{model:"htmlImg",view:"img",isObject:!0,modelSchema:{inheritAllFrom:"$inlineObject"}},{model:"htmlCanvas",view:"canvas",isObject:!0,modelSchema:{inheritAllFrom:"$inlineObject"}},{model:"htmlMeter",view:"meter",isObject:!0,modelSchema:{inheritAllFrom:"$inlineObject"}},{model:"htmlProgress",view:"progress",isObject:!0,modelSchema:{inheritAllFrom:"$inlineObject"}},{model:"htmlScript",view:"script",modelSchema:{allowWhere:["$text","$block"],isInline:!0}},{model:"htmlStyle",view:"style",modelSchema:{allowWhere:["$text","$block"],isInline:!0}},{model:"htmlCustomElement",view:"$customElement",modelSchema:{allowWhere:["$text","$block"],isInline:!0}}];const go=function(t,e,r){(void 0!==r&&!s(t[e],r)||void 0===r&&!(e in t))&&Pt(t,e,r)};const vo=function(t){return function(e,r,o){for(var n=-1,i=Object(e),l=o(e),s=l.length;s--;){var c=l[t?s:++n];if(!1===r(i[c],c,i))break}return e}}();const wo=function(t){return Tt(t)&&pe(t)};var yo="[object Object]",Ao=Function.prototype,jo=Object.prototype,_o=Ao.toString,So=jo.hasOwnProperty,Eo=_o.call(Object);const ko=function(t){if(!Tt(t)||D(t)!=yo)return!1;var e=Re(t);if(null===e)return!0;var r=So.call(e,"constructor")&&e.constructor;return"function"==typeof r&&r instanceof r&&_o.call(r)==Eo};const Oo=function(t,e){if(("constructor"!==e||"function"!=typeof t[e])&&"__proto__"!=e)return t[e]};const Co=function(t){return It(t,je(t))};const $o=function(t,e,r,o,n,i,l){var s=Oo(t,r),c=Oo(e,r),a=l.get(c);if(a)go(t,r,a);else{var u=i?i(s,c,r+"",t,e,l):void 0,m=void 0===u;if(m){var d=Ht(c),h=!d&&Gt(c),f=!d&&!h&&se(c);u=c,d||h||f?Ht(s)?u=s:wo(s)?u=$e(s):h?(m=!1,u=Ce(c,!0)):f?(m=!1,u=br(c,!0)):u=[]:ko(c)||Vt(c)?(u=s,Vt(s)?u=Co(s):T(s)&&!N(s)||(u=Mr(c))):m=!1}m&&(l.set(c,u),n(u,c,o,i,l),l.delete(c)),go(t,r,u)}};const Po=function t(e,r,o,n,i){e!==r&&vo(r,(function(l,s){if(i||(i=new Ot),T(l))$o(e,r,s,o,t,n,i);else{var c=n?n(Oo(e,s),l,s+"",e,r,i):void 0;void 0===c&&(c=l),go(e,s,c)}}),je)};const Fo=function(t){return t};const xo=function(t,e,r){switch(r.length){case 0:return t.call(e);case 1:return t.call(e,r[0]);case 2:return t.call(e,r[0],r[1]);case 3:return t.call(e,r[0],r[1],r[2])}return t.apply(e,r)};var Io=Math.max;const Do=function(t,e,r){return e=Io(void 0===e?t.length-1:e,0),function(){for(var o=arguments,n=-1,i=Io(o.length-e,0),l=Array(i);++n<i;)l[n]=o[e+n];n=-1;for(var s=Array(e+1);++n<e;)s[n]=o[n];return s[e]=r(l),xo(t,this,s)}};const To=function(t){return function(){return t}};const Bo=$t?function(t,e){return $t(t,"toString",{configurable:!0,enumerable:!1,value:To(e),writable:!0})}:Fo;var Ro=800,Mo=16,Lo=Date.now;const No=function(t){var e=0,r=0;return function(){var o=Lo(),n=Mo-(o-r);if(r=o,n>0){if(++e>=Ro)return arguments[0]}else e=0;return t.apply(void 0,arguments)}}(Bo);const Vo=function(t,e){return No(Do(t,e,Fo),t+"")};const Ho=function(t,e,r){if(!T(r))return!1;var o=typeof e;return!!("number"==o?pe(r)&&Zt(e,r.length):"string"==o&&e in r)&&s(r[e],t)};const zo=function(t){return Vo((function(e,r){var o=-1,n=r.length,i=n>1?r[n-1]:void 0,l=n>2?r[2]:void 0;for(i=t.length>3&&"function"==typeof i?(n--,i):void 0,l&&Ho(r[0],r[1],l)&&(i=n<3?void 0:i,n=1),e=Object(e);++o<n;){var s=r[o];s&&t(e,s,o,i)}return e}))}((function(t,e,r,o){Po(t,e,r,o)}));class Uo extends t.Plugin{constructor(t){super(t),this._definitions=new Map}static get pluginName(){return"DataSchema"}init(){for(const t of bo)this.registerBlockElement(t);for(const t of po)this.registerInlineElement(t)}registerBlockElement(t){this._definitions.set(t.model,{...t,isBlock:!0})}registerInlineElement(t){this._definitions.set(t.model,{...t,isInline:!0})}extendBlockElement(t){this._extendDefinition({...t,isBlock:!0})}extendInlineElement(t){this._extendDefinition({...t,isInline:!0})}getDefinitionsForView(t,e=!1){const r=new Set;for(const o of this._getMatchingViewDefinitions(t)){if(e)for(const t of this._getReferences(o.model))r.add(t);r.add(o)}return r}_getMatchingViewDefinitions(t){return Array.from(this._definitions.values()).filter((e=>e.view&&function(t,e){if("string"==typeof t)return t===e;if(t instanceof RegExp)return t.test(e);return!1}(t,e.view)))}*_getReferences(t){const{modelSchema:r}=this._definitions.get(t);if(!r)return;const o=["inheritAllFrom","inheritTypesFrom","allowWhere","allowContentOf","allowAttributesOf"];for(const n of o)for(const o of(0,e.toArray)(r[n]||[])){const e=this._definitions.get(o);o!==t&&e&&(yield*this._getReferences(e.model),yield e)}}_extendDefinition(t){const e=this._definitions.get(t.model),r=zo({},e,t,((t,e)=>Array.isArray(t)?t.concat(e):void 0));this._definitions.set(t.model,r)}}const qo=function(t,e){for(var r=-1,o=null==t?0:t.length,n=Array(o);++r<o;)n[r]=e(t[r],r,t);return n};const Wo=function(t,e,r,o){for(var n=t.length,i=r+(o?1:-1);o?i--:++i<n;)if(e(t[i],i,t))return i;return-1};const Go=function(t){return t!=t};const Ko=function(t,e,r){for(var o=r-1,n=t.length;++o<n;)if(t[o]===e)return o;return-1};const Xo=function(t,e,r){return e==e?Ko(t,e,r):Wo(t,Go,r)};const Zo=function(t,e,r,o){for(var n=r-1,i=t.length;++n<i;)if(o(t[n],e))return n;return-1};var Qo=Array.prototype.splice;const Jo=function(t,e,r,o){var n=o?Zo:Xo,i=-1,l=e.length,s=t;for(t===e&&(e=$e(e)),r&&(s=qo(t,ee(r)));++i<l;)for(var c=0,a=e[i],u=r?r(a):a;(c=n(s,u,c,o))>-1;)s!==t&&Qo.call(s,c,1),Qo.call(t,c,1);return t};const Yo=Vo((function(t,e){return t&&t.length&&e&&e.length?Jo(t,e):t}));var tn=r(62),en=r.n(tn),rn=r(142),on={injectType:"singletonStyleTag",attributes:{"data-cke":!0},insert:"head",singleton:!0};en()(rn.Z,on);rn.Z.locals;class nn extends t.Plugin{constructor(t){super(t),this._dataSchema=t.plugins.get("DataSchema"),this._allowedAttributes=new n.Matcher,this._disallowedAttributes=new n.Matcher,this._allowedElements=new Set,this._disallowedElements=new Set,this._dataInitialized=!1,this._coupledAttributes=null,this._registerElementsAfterInit(),this._registerElementHandlers(),this._registerModelPostFixer()}static get pluginName(){return"DataFilter"}static get requires(){return[Uo,i.Widget]}loadAllowedConfig(t){for(const e of t){const t=e.name||/[\s\S]+/,r=un(e);this.allowElement(t),r.forEach((t=>this.allowAttributes(t)))}}loadDisallowedConfig(t){for(const e of t){const t=e.name||/[\s\S]+/,r=un(e);0==r.length?this.disallowElement(t):r.forEach((t=>this.disallowAttributes(t)))}}allowElement(t){for(const r of this._dataSchema.getDefinitionsForView(t,!0))this._allowedElements.has(r)||(this._allowedElements.add(r),this._dataInitialized&&this.editor.data.once("set",(()=>{this._fireRegisterEvent(r)}),{priority:e.priorities.get("highest")+1}),this._coupledAttributes=null)}disallowElement(t){for(const e of this._dataSchema.getDefinitionsForView(t,!1))this._disallowedElements.add(e.view)}allowAttributes(t){this._allowedAttributes.add(t)}disallowAttributes(t){this._disallowedAttributes.add(t)}processViewAttributes(t,e){return ln(t,e,this._disallowedAttributes),ln(t,e,this._allowedAttributes)}_registerElementsAfterInit(){this.editor.data.on("init",(()=>{this._dataInitialized=!0;for(const t of this._allowedElements)this._fireRegisterEvent(t)}),{priority:e.priorities.get("highest")+1})}_registerElementHandlers(){this.on("register",((t,r)=>{const o=this.editor.model.schema;if(r.isObject&&!o.isRegistered(r.model))this._registerObjectElement(r);else if(r.isBlock)this._registerBlockElement(r);else{if(!r.isInline)throw new e.CKEditorError("data-filter-invalid-definition",null,r);this._registerInlineElement(r)}t.stop()}),{priority:"lowest"})}_registerModelPostFixer(){const t=this.editor.model;t.document.registerPostFixer((e=>{const r=t.document.differ.getChanges();let o=!1;const n=this._getCoupledAttributesMap();for(const t of r){if("attribute"!=t.type||null!==t.attributeNewValue)continue;const r=n.get(t.attributeKey);if(r)for(const{item:n}of t.range.getWalker({shallow:!0}))for(const t of r)n.hasAttribute(t)&&(e.removeAttribute(t,n),o=!0)}return o}))}_getCoupledAttributesMap(){if(this._coupledAttributes)return this._coupledAttributes;this._coupledAttributes=new Map;for(const t of this._allowedElements)if(t.coupledAttribute&&t.model){const e=this._coupledAttributes.get(t.coupledAttribute);e?e.push(t.model):this._coupledAttributes.set(t.coupledAttribute,[t.model])}return this._coupledAttributes}_fireRegisterEvent(t){t.view&&this._disallowedElements.has(t.view)||this.fire(t.view?`register:${t.view}`:"register",t)}_registerObjectElement(t){const r=this.editor,o=r.model.schema,n=r.conversion,{view:i,model:l}=t;o.register(l,t.modelSchema),i&&(o.extend(t.model,{allowAttributes:["htmlAttributes","htmlContent"]}),r.data.registerRawContentMatcher({name:i}),n.for("upcast").elementToElement({view:i,model:co(t),converterPriority:e.priorities.get("low")+1}),n.for("upcast").add(ho(t,this)),n.for("editingDowncast").elementToStructure({model:{name:l,attributes:["htmlAttributes"]},view:ao(r,t)}),n.for("dataDowncast").elementToElement({model:l,view:(t,{writer:e})=>uo(i,t,e)}),n.for("dataDowncast").add(fo(t)))}_registerBlockElement(t){const r=this.editor,o=r.model.schema,n=r.conversion,{view:i,model:l}=t;if(!o.isRegistered(t.model)){if(o.register(t.model,t.modelSchema),!i)return;n.for("upcast").elementToElement({model:l,view:i,converterPriority:e.priorities.get("low")+1}),n.for("downcast").elementToElement({model:l,view:i})}i&&(o.extend(t.model,{allowAttributes:"htmlAttributes"}),n.for("upcast").add(ho(t,this)),n.for("downcast").add(fo(t)))}_registerInlineElement(t){const e=this.editor,r=e.model.schema,o=e.conversion,n=t.model;r.extend("$text",{allowAttributes:n}),t.attributeProperties&&r.setAttributeProperties(n,t.attributeProperties),o.for("upcast").add(function({view:t,model:e},r){return o=>{o.on(`element:${t}`,((t,o,n)=>{let i=r.processViewAttributes(o.viewItem,n);if(i||n.consumable.test(o.viewItem,{name:!0})){i=i||{},n.consumable.consume(o.viewItem,{name:!0}),o.modelRange||(o=Object.assign(o,n.convertChildren(o.viewItem,o.modelCursor)));for(const t of o.modelRange.getItems())if(n.schema.checkAttribute(t,e)){const r=so(i,t.getAttribute(e)||{});n.writer.setAttribute(e,r,t)}}}),{priority:"low"})}}(t,this)),o.for("downcast").attributeToElement({model:n,view:mo(t)})}}function ln(t,e,r){const o=function(t,{consumable:e},r){const o=r.matchAll(t)||[],n=[];for(const r of o)sn(e,t,r),delete r.match.name,e.consume(t,r.match),n.push(r);return n}(t,e,r),{attributes:n,styles:i,classes:l}=function(t){const e={attributes:new Set,classes:new Set,styles:new Set};for(const r of t)for(const t in e){(r.match[t]||[]).forEach((r=>e[t].add(r)))}return e}(o),s={};if(n.size)for(const t of n)mn(t)||n.delete(t);return n.size&&(s.attributes=cn(n,(e=>t.getAttribute(e)))),i.size&&(s.styles=cn(i,(e=>t.getStyle(e)))),l.size&&(s.classes=Array.from(l)),Object.keys(s).length?s:null}function sn(t,e,r){for(const o of["attributes","classes","styles"]){const n=r.match[o];if(n)for(const r of Array.from(n))t.test(e,{[o]:[r]})||Yo(n,r)}}function cn(t,e){const r={};for(const o of t){void 0!==e(o)&&(r[o]=e(o))}return r}function an(t,e){const{name:r}=t,o=t[e];return ko(o)?Object.entries(o).map((([t,o])=>({name:r,[e]:{[t]:o}}))):Array.isArray(o)?o.map((t=>({name:r,[e]:[t]}))):[t]}function un(t){const{name:e,attributes:r,classes:o,styles:n}=t,i=[];return r&&i.push(...an({name:e,attributes:r},"attributes")),o&&i.push(...an({name:e,classes:o},"classes")),n&&i.push(...an({name:e,styles:n},"styles")),i}function mn(t){try{document.createAttribute(t)}catch(t){return!1}return!0}class dn extends t.Plugin{static get requires(){return[nn]}static get pluginName(){return"CodeBlockElementSupport"}init(){if(!this.editor.plugins.has("CodeBlockEditing"))return;const t=this.editor.plugins.get(nn);t.on("register:pre",((e,r)=>{if("codeBlock"!==r.model)return;const o=this.editor,n=o.model.schema,i=o.conversion;n.extend("codeBlock",{allowAttributes:["htmlAttributes","htmlContentAttributes"]}),i.for("upcast").add(function(t){return e=>{e.on("element:code",((e,r,o)=>{const n=r.viewItem,i=n.parent;function l(e,n){const i=t.processViewAttributes(e,o);i&&o.writer.setAttribute(n,i,r.modelRange)}i&&i.is("element","pre")&&(l(i,"htmlAttributes"),l(n,"htmlContentAttributes"))}),{priority:"low"})}}(t)),i.for("downcast").add((t=>{t.on("attribute:htmlAttributes:codeBlock",((t,e,r)=>{if(!r.consumable.consume(e.item,t.name))return;const{attributeOldValue:o,attributeNewValue:n}=e,i=r.mapper.toViewElement(e.item).parent;io(r.writer,o,n,i)})),t.on("attribute:htmlContentAttributes:codeBlock",((t,e,r)=>{if(!r.consumable.consume(e.item,t.name))return;const{attributeOldValue:o,attributeNewValue:n}=e,i=r.mapper.toViewElement(e.item);io(r.writer,o,n,i)}))})),e.stop()}))}}class hn extends t.Plugin{static get requires(){return[nn]}static get pluginName(){return"DualContentModelElementSupport"}init(){this.editor.plugins.get(nn).on("register",((t,r)=>{const o=r,n=this.editor,i=n.model.schema,l=n.conversion;if(!o.paragraphLikeModel)return;if(i.isRegistered(o.model)||i.isRegistered(o.paragraphLikeModel))return;const s={model:o.paragraphLikeModel,view:o.view};i.register(o.model,o.modelSchema),i.register(s.model,{inheritAllFrom:"$block"}),l.for("upcast").elementToElement({view:o.view,model:(t,{writer:e})=>this._hasBlockContent(t)?e.createElement(o.model):e.createElement(s.model),converterPriority:e.priorities.get("low")+.5}),l.for("downcast").elementToElement({view:o.view,model:o.model}),this._addAttributeConversion(o),l.for("downcast").elementToElement({view:s.view,model:s.model}),this._addAttributeConversion(s),t.stop()}))}_hasBlockContent(t){const e=this.editor.editing.view,r=e.domConverter.blockElements;for(const o of e.createRangeIn(t).getItems())if(o.is("element")&&r.includes(o.name))return!0;return!1}_addAttributeConversion(t){const e=this.editor,r=e.conversion,o=e.plugins.get(nn);e.model.schema.extend(t.model,{allowAttributes:"htmlAttributes"}),r.for("upcast").add(ho(t,o)),r.for("downcast").add(fo(t))}}class fn extends t.Plugin{static get requires(){return[Uo]}static get pluginName(){return"HeadingElementSupport"}init(){const t=this.editor;if(!t.plugins.has("HeadingEditing"))return;const e=t.plugins.get(Uo),r=t.config.get("heading.options"),o=[];for(const t of r)"model"in t&&"view"in t&&(e.registerBlockElement({view:t.view,model:t.model}),o.push(t.model));e.extendBlockElement({model:"htmlHgroup",modelSchema:{allowChildren:o}})}}function bn(t,e,r){const o=t.createRangeOn(e);for(const{item:t}of o.getWalker())if(t.is("element",r))return t}class pn extends t.Plugin{static get requires(){return[nn]}static get pluginName(){return"ImageElementSupport"}init(){const t=this.editor;if(!t.plugins.has("ImageInlineEditing")&&!t.plugins.has("ImageBlockEditing"))return;const e=t.model.schema,r=t.conversion,o=t.plugins.get(nn);o.on("register:figure",(()=>{r.for("upcast").add(function(t){return e=>{e.on("element:figure",((e,r,o)=>{const n=r.viewItem;if(!r.modelRange||!n.hasClass("image"))return;const i=t.processViewAttributes(n,o);i&&o.writer.setAttribute("htmlFigureAttributes",i,r.modelRange)}),{priority:"low"})}}(o))})),o.on("register:img",((t,n)=>{"imageBlock"!==n.model&&"imageInline"!==n.model||(e.isRegistered("imageBlock")&&e.extend("imageBlock",{allowAttributes:["htmlAttributes","htmlFigureAttributes","htmlLinkAttributes"]}),e.isRegistered("imageInline")&&e.extend("imageInline",{allowAttributes:["htmlA","htmlAttributes"]}),r.for("upcast").add(function(t){return e=>{e.on("element:img",((e,r,o)=>{if(!r.modelRange)return;const n=r.viewItem,i=n.parent;function l(e,n){const i=t.processViewAttributes(e,o);i&&o.writer.setAttribute(n,i,r.modelRange)}function s(t){r.modelRange&&r.modelRange.getContainedElement().is("element","imageBlock")&&l(t,"htmlLinkAttributes")}l(n,"htmlAttributes"),i.is("element","a")&&s(i)}),{priority:"low"})}}(o)),r.for("downcast").add((t=>{function e(e){t.on(`attribute:${e}:imageInline`,((t,e,r)=>{if(!r.consumable.consume(e.item,t.name))return;const{attributeOldValue:o,attributeNewValue:n}=e,i=r.mapper.toViewElement(e.item);io(r.writer,o,n,i)}),{priority:"low"})}function r(e,r){t.on(`attribute:${r}:imageBlock`,((t,r,o)=>{if(!o.consumable.test(r.item,t.name))return;const{attributeOldValue:n,attributeNewValue:i}=r,l=o.mapper.toViewElement(r.item),s=bn(o.writer,l,e);s&&(io(o.writer,n,i,s),o.consumable.consume(r.item,t.name))}),{priority:"low"}),"a"===e&&t.on("attribute:linkHref:imageBlock",((t,e,r)=>{if(!r.consumable.consume(e.item,"attribute:htmlLinkAttributes:imageBlock"))return;const o=r.mapper.toViewElement(e.item),n=bn(r.writer,o,"a");lo(r.writer,e.item.getAttribute("htmlLinkAttributes"),n)}),{priority:"low"})}e("htmlAttributes"),r("img","htmlAttributes"),r("figure","htmlFigureAttributes"),r("a","htmlLinkAttributes")})),t.stop())}))}}class gn extends t.Plugin{static get requires(){return[nn]}static get pluginName(){return"MediaEmbedElementSupport"}init(){const t=this.editor;if(!t.plugins.has("MediaEmbed")||t.config.get("mediaEmbed.previewsInData"))return;const e=t.model.schema,r=t.conversion,o=this.editor.plugins.get(nn),n=this.editor.plugins.get(Uo),i=t.config.get("mediaEmbed.elementName");n.registerBlockElement({model:"media",view:i}),o.on("register:figure",(()=>{r.for("upcast").add(function(t){return e=>{e.on("element:figure",((e,r,o)=>{const n=r.viewItem;if(!r.modelRange||!n.hasClass("media"))return;const i=t.processViewAttributes(n,o);i&&o.writer.setAttribute("htmlFigureAttributes",i,r.modelRange)}),{priority:"low"})}}(o))})),o.on(`register:${i}`,((t,n)=>{"media"===n.model&&(e.extend("media",{allowAttributes:["htmlAttributes","htmlFigureAttributes"]}),r.for("upcast").add(function(t,e){const r=(e,r,o)=>{function n(e,n){const i=t.processViewAttributes(e,o);i&&o.writer.setAttribute(n,i,r.modelRange)}n(r.viewItem,"htmlAttributes")};return t=>{t.on(`element:${e}`,r,{priority:"low"})}}(o,i)),r.for("dataDowncast").add(function(t){return e=>{function r(t,r){e.on(`attribute:${r}:media`,((e,r,o)=>{if(!o.consumable.consume(r.item,e.name))return;const{attributeOldValue:n,attributeNewValue:i}=r,l=o.mapper.toViewElement(r.item),s=bn(o.writer,l,t);io(o.writer,n,i,s)}))}r(t,"htmlAttributes"),r("figure","htmlFigureAttributes")}}(i)),t.stop())}))}}class vn extends t.Plugin{static get requires(){return[nn]}static get pluginName(){return"ScriptElementSupport"}init(){const t=this.editor.plugins.get(nn);t.on("register:script",((e,r)=>{const o=this.editor,n=o.model.schema,i=o.conversion;n.register("htmlScript",r.modelSchema),n.extend("htmlScript",{allowAttributes:["htmlAttributes","htmlContent"],isContent:!0}),o.data.registerRawContentMatcher({name:"script"}),i.for("upcast").elementToElement({view:"script",model:co(r)}),i.for("upcast").add(ho(r,t)),i.for("downcast").elementToElement({model:"htmlScript",view:(t,{writer:e})=>uo("script",t,e)}),i.for("downcast").add(fo(r)),e.stop()}))}}class wn extends t.Plugin{static get requires(){return[nn]}static get pluginName(){return"TableElementSupport"}init(){const t=this.editor;if(!t.plugins.has("TableEditing"))return;const e=t.model.schema,r=t.conversion,o=t.plugins.get(nn);o.on("register:figure",(()=>{r.for("upcast").add(function(t){return e=>{e.on("element:figure",((e,r,o)=>{const n=r.viewItem;if(!r.modelRange||!n.hasClass("table"))return;const i=t.processViewAttributes(n,o);i&&o.writer.setAttribute("htmlFigureAttributes",i,r.modelRange)}),{priority:"low"})}}(o))})),o.on("register:table",((t,n)=>{"table"===n.model&&(e.extend("table",{allowAttributes:["htmlAttributes","htmlFigureAttributes","htmlTheadAttributes","htmlTbodyAttributes"]}),r.for("upcast").add(function(t){return e=>{e.on("element:table",((e,r,o)=>{const n=r.viewItem;i(n,"htmlAttributes");for(const t of n.getChildren())t.is("element","thead")&&i(t,"htmlTheadAttributes"),t.is("element","tbody")&&i(t,"htmlTbodyAttributes");function i(e,n){const i=t.processViewAttributes(e,o);i&&o.writer.setAttribute(n,i,r.modelRange)}}),{priority:"low"})}}(o)),r.for("downcast").add((t=>{function e(e,r){t.on(`attribute:${r}:table`,((t,r,o)=>{if(!o.consumable.consume(r.item,t.name))return;const n=o.mapper.toViewElement(r.item),i=bn(o.writer,n,e);lo(o.writer,r.attributeNewValue,i)}))}e("table","htmlAttributes"),e("figure","htmlFigureAttributes"),e("thead","htmlTheadAttributes"),e("tbody","htmlTbodyAttributes")})),t.stop())}))}}class yn extends t.Plugin{static get requires(){return[nn]}static get pluginName(){return"StyleElementSupport"}init(){const t=this.editor.plugins.get(nn);t.on("register:style",((e,r)=>{const o=this.editor,n=o.model.schema,i=o.conversion;n.register("htmlStyle",r.modelSchema),n.extend("htmlStyle",{allowAttributes:["htmlAttributes","htmlContent"],isContent:!0}),o.data.registerRawContentMatcher({name:"style"}),i.for("upcast").elementToElement({view:"style",model:co(r)}),i.for("upcast").add(ho(r,t)),i.for("downcast").elementToElement({model:"htmlStyle",view:(t,{writer:e})=>uo("style",t,e)}),i.for("downcast").add(fo(r)),e.stop()}))}}var An="__lodash_hash_undefined__";const jn=function(t){return this.__data__.set(t,An),this};const _n=function(t){return this.__data__.has(t)};function Sn(t){var e=-1,r=null==t?0:t.length;for(this.__data__=new _t;++e<r;)this.add(t[e])}Sn.prototype.add=Sn.prototype.push=jn,Sn.prototype.has=_n;const En=Sn;const kn=function(t,e){for(var r=-1,o=null==t?0:t.length;++r<o;)if(e(t[r],r,t))return!0;return!1};const On=function(t,e){return t.has(e)};var Cn=1,$n=2;const Pn=function(t,e,r,o,n,i){var l=r&Cn,s=t.length,c=e.length;if(s!=c&&!(l&&c>s))return!1;var a=i.get(t),u=i.get(e);if(a&&u)return a==e&&u==t;var m=-1,d=!0,h=r&$n?new En:void 0;for(i.set(t,e),i.set(e,t);++m<s;){var f=t[m],b=e[m];if(o)var p=l?o(b,f,m,e,t,i):o(f,b,m,t,e,i);if(void 0!==p){if(p)continue;d=!1;break}if(h){if(!kn(e,(function(t,e){if(!On(h,e)&&(f===t||n(f,t,r,o,i)))return h.push(e)}))){d=!1;break}}else if(f!==b&&!n(f,b,r,o,i)){d=!1;break}}return i.delete(t),i.delete(e),d};const Fn=function(t){var e=-1,r=Array(t.size);return t.forEach((function(t,o){r[++e]=[o,t]})),r};const xn=function(t){var e=-1,r=Array(t.size);return t.forEach((function(t){r[++e]=t})),r};var In=1,Dn=2,Tn="[object Boolean]",Bn="[object Date]",Rn="[object Error]",Mn="[object Map]",Ln="[object Number]",Nn="[object RegExp]",Vn="[object Set]",Hn="[object String]",zn="[object Symbol]",Un="[object ArrayBuffer]",qn="[object DataView]",Wn=_?_.prototype:void 0,Gn=Wn?Wn.valueOf:void 0;const Kn=function(t,e,r,o,n,i,l){switch(r){case qn:if(t.byteLength!=e.byteLength||t.byteOffset!=e.byteOffset)return!1;t=t.buffer,e=e.buffer;case Un:return!(t.byteLength!=e.byteLength||!i(new sr(t),new sr(e)));case Tn:case Bn:case Ln:return s(+t,+e);case Rn:return t.name==e.name&&t.message==e.message;case Nn:case Hn:return t==e+"";case Mn:var c=Fn;case Vn:var a=o&In;if(c||(c=xn),t.size!=e.size&&!a)return!1;var u=l.get(t);if(u)return u==e;o|=Dn,l.set(t,e);var m=Pn(c(t),c(e),o,n,i,l);return l.delete(t),m;case zn:if(Gn)return Gn.call(t)==Gn.call(e)}return!1};var Xn=1,Zn=Object.prototype.hasOwnProperty;const Qn=function(t,e,r,o,n,i){var l=r&Xn,s=Ve(t),c=s.length;if(c!=Ve(e).length&&!l)return!1;for(var a=c;a--;){var u=s[a];if(!(l?u in e:Zn.call(e,u)))return!1}var m=i.get(t),d=i.get(e);if(m&&d)return m==e&&d==t;var h=!0;i.set(t,e),i.set(e,t);for(var f=l;++a<c;){var b=t[u=s[a]],p=e[u];if(o)var g=l?o(p,b,u,e,t,i):o(b,p,u,t,e,i);if(!(void 0===g?b===p||n(b,p,r,o,i):g)){h=!1;break}f||(f="constructor"==u)}if(h&&!f){var v=t.constructor,w=e.constructor;v==w||!("constructor"in t)||!("constructor"in e)||"function"==typeof v&&v instanceof v&&"function"==typeof w&&w instanceof w||(h=!1)}return i.delete(t),i.delete(e),h};var Jn=1,Yn="[object Arguments]",ti="[object Array]",ei="[object Object]",ri=Object.prototype.hasOwnProperty;const oi=function(t,e,r,o,n,i){var l=Ht(t),s=Ht(e),c=l?ti:nr(t),a=s?ti:nr(e),u=(c=c==Yn?ei:c)==ei,m=(a=a==Yn?ei:a)==ei,d=c==a;if(d&&Gt(t)){if(!Gt(e))return!1;l=!0,u=!1}if(d&&!u)return i||(i=new Ot),l||se(t)?Pn(t,e,r,o,n,i):Kn(t,e,c,r,o,n,i);if(!(r&Jn)){var h=u&&ri.call(t,"__wrapped__"),f=m&&ri.call(e,"__wrapped__");if(h||f){var b=h?t.value():t,p=f?e.value():e;return i||(i=new Ot),n(b,p,r,o,i)}}return!!d&&(i||(i=new Ot),Qn(t,e,r,o,n,i))};const ni=function t(e,r,o,n,i){return e===r||(null==e||null==r||!Tt(e)&&!Tt(r)?e!=e&&r!=r:oi(e,r,o,n,t,i))};const ii=function(t,e){return ni(t,e)};class li extends t.Plugin{static get requires(){return[nn]}static get pluginName(){return"DocumentListElementSupport"}init(){const t=this.editor;if(!t.plugins.has("DocumentListEditing"))return;const e=t.model.schema,r=t.conversion,o=t.plugins.get(nn),n=t.plugins.get("DocumentListEditing");n.registerDowncastStrategy({scope:"item",attributeName:"htmlLiAttributes",setAttributeOnDowncast(t,e,r){lo(t,e,r)}}),n.registerDowncastStrategy({scope:"list",attributeName:"htmlListAttributes",setAttributeOnDowncast(t,e,r){lo(t,e,r)}}),o.on("register",((t,n)=>{["ul","ol","li"].includes(n.view)&&(t.stop(),e.checkAttribute("$block","htmlListAttributes")||(e.extend("$block",{allowAttributes:["htmlListAttributes","htmlLiAttributes"]}),e.extend("$blockObject",{allowAttributes:["htmlListAttributes","htmlLiAttributes"]}),e.extend("$container",{allowAttributes:["htmlListAttributes","htmlLiAttributes"]}),r.for("upcast").add((t=>{t.on("element:ul",si("htmlListAttributes",o),{priority:"low"}),t.on("element:ol",si("htmlListAttributes",o),{priority:"low"}),t.on("element:li",si("htmlLiAttributes",o),{priority:"low"})}))))})),n.on("postFixer",((t,{listNodes:e,writer:r})=>{const o=[];for(const{node:n,previous:i}of e){if(!i)continue;const e=n.getAttribute("listIndent"),l=i.getAttribute("listIndent");let s=null;if(e>l?o[l]=i:e<l?(s=o[e],o.length=e):s=i,s){if(s.getAttribute("listType")==n.getAttribute("listType")){const e=s.getAttribute("htmlListAttributes");ii(n.getAttribute("htmlListAttributes"),e)||(r.setAttribute("htmlListAttributes",e,n),t.return=!0)}if(s.getAttribute("listItemId")==n.getAttribute("listItemId")){const e=s.getAttribute("htmlLiAttributes");ii(n.getAttribute("htmlLiAttributes"),e)||(r.setAttribute("htmlLiAttributes",e,n),t.return=!0)}}}}))}afterInit(){const t=this.editor;if(!t.commands.get("indentList"))return;const e=t.commands.get("indentList");this.listenTo(e,"afterExecute",((e,r)=>{t.model.change((t=>{for(const e of r)t.setAttribute("htmlListAttributes",{},e)}))}))}}function si(t,e){return(r,o,n)=>{const i=o.viewItem;o.modelRange||Object.assign(o,n.convertChildren(o.viewItem,o.modelCursor));const l=e.processViewAttributes(i,n);for(const e of o.modelRange.getItems({shallow:!0}))e.hasAttribute("listItemId")&&(e.hasAttribute(t)||n.writer.setAttribute(t,l||{},e))}}class ci extends t.Plugin{static get requires(){return[nn,Uo]}static get pluginName(){return"CustomElementSupport"}init(){const t=this.editor.plugins.get(nn),e=this.editor.plugins.get(Uo);t.on("register:$customElement",((r,o)=>{r.stop();const i=this.editor,l=i.model.schema,s=i.conversion,c=i.editing.view.domConverter.unsafeElements,a=i.data.htmlProcessor.domConverter.preElements;l.register(o.model,o.modelSchema),l.extend(o.model,{allowAttributes:["htmlElementName","htmlAttributes","htmlContent"],isContent:!0}),s.for("upcast").elementToElement({view:/.*/,model:(r,l)=>{if("$comment"==r.name)return null;if(!function(t){try{document.createElement(t)}catch(t){return!1}return!0}(r.name))return null;if(e.getDefinitionsForView(r.name).size)return null;c.includes(r.name)||c.push(r.name),a.includes(r.name)||a.push(r.name);const s=l.writer.createElement(o.model,{htmlElementName:r.name}),u=t.processViewAttributes(r,l);u&&l.writer.setAttribute("htmlAttributes",u,s);const m=new n.UpcastWriter(r.document).createDocumentFragment(r),d=i.data.processor.toData(m);l.writer.setAttribute("htmlContent",d,s);for(const{item:t}of i.editing.view.createRangeIn(r))l.consumable.consume(t,{name:!0});return s},converterPriority:"low"}),s.for("editingDowncast").elementToElement({model:{name:o.model,attributes:["htmlElementName","htmlAttributes","htmlContent"]},view:(t,{writer:e})=>{const r=t.getAttribute("htmlElementName"),o=e.createRawElement(r);return t.hasAttribute("htmlAttributes")&&lo(e,t.getAttribute("htmlAttributes"),o),o}}),s.for("dataDowncast").elementToElement({model:{name:o.model,attributes:["htmlElementName","htmlAttributes","htmlContent"]},view:(t,{writer:e})=>{const r=t.getAttribute("htmlElementName"),o=t.getAttribute("htmlContent"),n=e.createRawElement(r,null,((t,e)=>{e.setContentOf(t,o);const r=t.firstChild;for(r.remove();r.firstChild;)t.appendChild(r.firstChild)}));return t.hasAttribute("htmlAttributes")&&lo(e,t.getAttribute("htmlAttributes"),n),n}})}))}}class ai extends t.Plugin{static get pluginName(){return"GeneralHtmlSupport"}static get requires(){return[nn,dn,hn,fn,pn,gn,vn,wn,yn,li,ci]}init(){const t=this.editor,e=t.plugins.get(nn);e.loadAllowedConfig(t.config.get("htmlSupport.allow")||[]),e.loadDisallowedConfig(t.config.get("htmlSupport.disallow")||[])}getGhsAttributeNameForElement(t){const e=this.editor.plugins.get("DataSchema"),r=Array.from(e.getDefinitionsForView(t,!1));return r&&r.length&&r[0].isInline&&!r[0].isObject?r[0].model:"htmlAttributes"}addModelHtmlClass(t,r,o){const n=this.editor.model,i=this.getGhsAttributeNameForElement(t);n.change((t=>{for(const l of ui(n,o,i))mi(t,l,i,"classes",(t=>{for(const o of(0,e.toArray)(r))t.add(o)}))}))}removeModelHtmlClass(t,r,o){const n=this.editor.model,i=this.getGhsAttributeNameForElement(t);n.change((t=>{for(const l of ui(n,o,i))mi(t,l,i,"classes",(t=>{for(const o of(0,e.toArray)(r))t.delete(o)}))}))}setModelHtmlAttributes(t,e,r){const o=this.editor.model,n=this.getGhsAttributeNameForElement(t);o.change((t=>{for(const i of ui(o,r,n))mi(t,i,n,"attributes",(t=>{for(const[r,o]of Object.entries(e))t.set(r,o)}))}))}removeModelHtmlAttributes(t,r,o){const n=this.editor.model,i=this.getGhsAttributeNameForElement(t);n.change((t=>{for(const l of ui(n,o,i))mi(t,l,i,"attributes",(t=>{for(const o of(0,e.toArray)(r))t.delete(o)}))}))}setModelHtmlStyles(t,e,r){const o=this.editor.model,n=this.getGhsAttributeNameForElement(t);o.change((t=>{for(const i of ui(o,r,n))mi(t,i,n,"styles",(t=>{for(const[r,o]of Object.entries(e))t.set(r,o)}))}))}removeModelHtmlStyles(t,r,o){const n=this.editor.model,i=this.getGhsAttributeNameForElement(t);n.change((t=>{for(const l of ui(n,o,i))mi(t,l,i,"styles",(t=>{for(const o of(0,e.toArray)(r))t.delete(o)}))}))}}function*ui(t,e,r){if(e.is("documentSelection")&&e.isCollapsed)t.schema.checkAttributeInSelection(e,r)&&(yield e);else for(const o of function(t,e,r){return e.is("node")||e.is("$text")||e.is("$textProxy")?t.schema.checkAttribute(e,r)?[t.createRangeOn(e)]:[]:t.schema.getValidRanges(t.createSelection(e).getRanges(),r)}(t,e,r))yield*o.getItems({shallow:!0})}function mi(t,e,r,o,n){const i=e.getAttribute(r),l={};for(const t of["attributes","styles","classes"]){if(t!=o){i&&i[t]&&(l[t]=i[t]);continue}if("classes"==o){const e=new Set(i&&i.classes||[]);n(e),e.size&&(l[t]=Array.from(e));continue}const e=new Map(Object.entries(i&&i[t]||{}));n(e),e.size&&(l[t]=Object.fromEntries(e))}Object.keys(l).length?e.is("documentSelection")?t.setSelectionAttribute(r,l):t.setAttribute(r,l,e):i&&(e.is("documentSelection")?t.removeSelectionAttribute(r):t.removeAttribute(r,e))}class di extends t.Plugin{static get pluginName(){return"HtmlComment"}init(){const t=this.editor;t.data.processor.skipComments=!1,t.model.schema.addAttributeCheck(((t,e)=>{if(t.endsWith("$root")&&e.startsWith("$comment"))return!0})),t.conversion.for("upcast").elementToMarker({view:"$comment",model:(t,{writer:r})=>{const o=this.editor.model.document.getRoot(),n=t.getCustomProperty("$rawContent"),i=`$comment:${(0,e.uid)()}`;return r.setAttribute(i,n,o),i}}),t.conversion.for("dataDowncast").markerToElement({model:"$comment",view:(t,{writer:e})=>{const r=this.editor.model.document.getRoot(),o=t.markerName,n=r.getAttribute(o),i=e.createUIElement("$comment");return e.setCustomProperty("$rawContent",n,i),i}}),t.model.document.registerPostFixer((e=>{const r=t.model.document.getRoot(),o=t.model.document.differ.getChangedMarkers().filter((t=>t.name.startsWith("$comment"))).filter((t=>{const e=t.data.newRange;return e&&"$graveyard"===e.root.rootName}));if(0===o.length)return!1;for(const t of o)e.removeMarker(t.name),e.removeAttribute(t.name,r);return!0})),t.data.on("set",(()=>{for(const e of t.model.markers.getMarkersGroup("$comment"))this.removeHtmlComment(e.name)}),{priority:"high"}),t.model.on("deleteContent",((e,[r])=>{for(const e of r.getRanges()){const r=t.model.schema.getLimitElement(e),o=t.model.createPositionAt(r,0),n=t.model.createPositionAt(r,"end");let i;i=o.isTouching(e.start)&&n.isTouching(e.end)?this.getHtmlCommentsInRange(t.model.createRange(o,n)):this.getHtmlCommentsInRange(e,{skipBoundaries:!0});for(const t of i)this.removeHtmlComment(t)}}),{priority:"high"})}createHtmlComment(t,r){const o=(0,e.uid)(),n=this.editor.model,i=n.document.getRoot(),l=`$comment:${o}`;return n.change((e=>{const o=e.createRange(t);return e.addMarker(l,{usingOperation:!0,affectsData:!0,range:o}),e.setAttribute(l,r,i),l}))}removeHtmlComment(t){const e=this.editor,r=e.model.document.getRoot(),o=e.model.markers.get(t);return!!o&&(e.model.change((e=>{e.removeMarker(o),e.removeAttribute(t,r)})),!0)}getHtmlCommentData(t){const e=this.editor,r=e.model.markers.get(t),o=e.model.document.getRoot();return r?{content:o.getAttribute(t),position:r.getStart()}:null}getHtmlCommentsInRange(t,{skipBoundaries:e=!1}={}){const r=!e;return Array.from(this.editor.model.markers.getMarkersGroup("$comment")).filter((e=>function(t,e){const o=t.getRange().start;return(o.isAfter(e.start)||r&&o.isEqual(e.start))&&(o.isBefore(e.end)||r&&o.isEqual(e.end))}(e,t))).map((t=>t.name))}}class hi extends n.HtmlDataProcessor{toView(t){if(!t.match(/<(?:html|body|head|meta)(?:\s[^>]*)?>/i))return super.toView(t);let e="",r="";t=(t=t.replace(/<!DOCTYPE[^>]*>/i,(t=>(e=t,"")))).replace(/<\?xml\s[^?]*\?>/i,(t=>(r=t,"")));const o=this._toDom(t),i=this.domConverter.domToView(o,{skipComments:this.skipComments}),l=new n.UpcastWriter(i.document);return l.setCustomProperty("$fullPageDocument",o.ownerDocument.documentElement.outerHTML,i),e&&l.setCustomProperty("$fullPageDocType",e,i),r&&l.setCustomProperty("$fullPageXmlDeclaration",r,i),i}toData(t){let e=super.toData(t);const r=t.getCustomProperty("$fullPageDocument"),o=t.getCustomProperty("$fullPageDocType"),n=t.getCustomProperty("$fullPageXmlDeclaration");return r&&(e=r.replace(/<\/body\s*>/,e+"$&"),o&&(e=o+"\n"+e),n&&(e=n+"\n"+e)),e}}class fi extends t.Plugin{static get pluginName(){return"FullPage"}init(){const t=this.editor,e=["$fullPageDocument","$fullPageDocType","$fullPageXmlDeclaration"];t.data.processor=new hi(t.data.viewDocument),t.model.schema.extend("$root",{allowAttributes:e}),t.data.on("toModel",((r,[o])=>{const n=t.model.document.getRoot();t.model.change((t=>{for(const r of e){const e=o.getCustomProperty(r);e&&t.setAttribute(r,e,n)}}))}),{priority:"low"}),t.data.on("toView",((t,[r])=>{if(!r.is("rootElement"))return;const o=r,i=t.return;if(!o.hasAttribute("$fullPageDocument"))return;const l=new n.UpcastWriter(i.document);for(const t of e){const e=o.getAttribute(t);e&&l.setCustomProperty(t,e,i)}}),{priority:"low"}),t.data.on("set",(()=>{const r=t.model.document.getRoot();t.model.change((t=>{for(const o of e)r.hasAttribute(o)&&t.removeAttribute(o,r)}))}),{priority:"high"}),t.data.on("get",((t,e)=>{e[0]||(e[0]={}),e[0].trim=!1}),{priority:"high"})}}})(),(window.CKEditor5=window.CKEditor5||{}).htmlSupport=o})();
|
package/ckeditor5-metadata.json
CHANGED
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
"name": "General HTML Support",
|
|
5
5
|
"className": "GeneralHtmlSupport",
|
|
6
6
|
"description": "Allows enabling unsupported HTML features at low cost.",
|
|
7
|
-
"docs": "features/general-html-support.html",
|
|
7
|
+
"docs": "features/html/general-html-support.html",
|
|
8
8
|
"path": "src/generalhtmlsupport.js",
|
|
9
9
|
"htmlOutput": [
|
|
10
10
|
{
|
|
@@ -41,7 +41,7 @@
|
|
|
41
41
|
"name": "HTML comment",
|
|
42
42
|
"className": "HtmlComment",
|
|
43
43
|
"description": "Preserves the HTML comments in the editor data.",
|
|
44
|
-
"docs": "features/
|
|
44
|
+
"docs": "features/html/html-comments.html",
|
|
45
45
|
"path": "src/htmlcomment.js",
|
|
46
46
|
"htmlOutput": [
|
|
47
47
|
{
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ckeditor/ckeditor5-html-support",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "37.0.0-alpha.1",
|
|
4
4
|
"description": "HTML Support feature for CKEditor 5.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"ckeditor",
|
|
@@ -16,41 +16,43 @@
|
|
|
16
16
|
],
|
|
17
17
|
"main": "src/index.js",
|
|
18
18
|
"dependencies": {
|
|
19
|
-
"ckeditor5": "^
|
|
19
|
+
"ckeditor5": "^37.0.0-alpha.1",
|
|
20
20
|
"lodash-es": "^4.17.15"
|
|
21
21
|
},
|
|
22
22
|
"devDependencies": {
|
|
23
|
-
"@ckeditor/ckeditor5-alignment": "^
|
|
24
|
-
"@ckeditor/ckeditor5-basic-styles": "^
|
|
25
|
-
"@ckeditor/ckeditor5-block-quote": "^
|
|
26
|
-
"@ckeditor/ckeditor5-clipboard": "^
|
|
27
|
-
"@ckeditor/ckeditor5-cloud-services": "^
|
|
28
|
-
"@ckeditor/ckeditor5-code-block": "^
|
|
29
|
-
"@ckeditor/ckeditor5-core": "^
|
|
30
|
-
"@ckeditor/ckeditor5-dev-utils": "^
|
|
31
|
-
"@ckeditor/ckeditor5-easy-image": "^
|
|
32
|
-
"@ckeditor/ckeditor5-editor-classic": "^
|
|
33
|
-
"@ckeditor/ckeditor5-engine": "^
|
|
34
|
-
"@ckeditor/ckeditor5-enter": "^
|
|
35
|
-
"@ckeditor/ckeditor5-essentials": "^
|
|
36
|
-
"@ckeditor/ckeditor5-font": "^
|
|
37
|
-
"@ckeditor/ckeditor5-heading": "^
|
|
38
|
-
"@ckeditor/ckeditor5-highlight": "^
|
|
39
|
-
"@ckeditor/ckeditor5-horizontal-line": "^
|
|
40
|
-
"@ckeditor/ckeditor5-html-embed": "^
|
|
41
|
-
"@ckeditor/ckeditor5-image": "^
|
|
42
|
-
"@ckeditor/ckeditor5-indent": "^
|
|
43
|
-
"@ckeditor/ckeditor5-link": "^
|
|
44
|
-
"@ckeditor/ckeditor5-list": "^
|
|
45
|
-
"@ckeditor/ckeditor5-media-embed": "^
|
|
46
|
-
"@ckeditor/ckeditor5-page-break": "^
|
|
47
|
-
"@ckeditor/ckeditor5-paragraph": "^
|
|
48
|
-
"@ckeditor/ckeditor5-paste-from-office": "^
|
|
49
|
-
"@ckeditor/ckeditor5-remove-format": "^
|
|
50
|
-
"@ckeditor/ckeditor5-source-editing": "^
|
|
51
|
-
"@ckeditor/ckeditor5-table": "^
|
|
52
|
-
"@ckeditor/ckeditor5-theme-lark": "^
|
|
53
|
-
"@ckeditor/ckeditor5-utils": "^
|
|
23
|
+
"@ckeditor/ckeditor5-alignment": "^37.0.0-alpha.1",
|
|
24
|
+
"@ckeditor/ckeditor5-basic-styles": "^37.0.0-alpha.1",
|
|
25
|
+
"@ckeditor/ckeditor5-block-quote": "^37.0.0-alpha.1",
|
|
26
|
+
"@ckeditor/ckeditor5-clipboard": "^37.0.0-alpha.1",
|
|
27
|
+
"@ckeditor/ckeditor5-cloud-services": "^37.0.0-alpha.1",
|
|
28
|
+
"@ckeditor/ckeditor5-code-block": "^37.0.0-alpha.1",
|
|
29
|
+
"@ckeditor/ckeditor5-core": "^37.0.0-alpha.1",
|
|
30
|
+
"@ckeditor/ckeditor5-dev-utils": "^35.0.0",
|
|
31
|
+
"@ckeditor/ckeditor5-easy-image": "^37.0.0-alpha.1",
|
|
32
|
+
"@ckeditor/ckeditor5-editor-classic": "^37.0.0-alpha.1",
|
|
33
|
+
"@ckeditor/ckeditor5-engine": "^37.0.0-alpha.1",
|
|
34
|
+
"@ckeditor/ckeditor5-enter": "^37.0.0-alpha.1",
|
|
35
|
+
"@ckeditor/ckeditor5-essentials": "^37.0.0-alpha.1",
|
|
36
|
+
"@ckeditor/ckeditor5-font": "^37.0.0-alpha.1",
|
|
37
|
+
"@ckeditor/ckeditor5-heading": "^37.0.0-alpha.1",
|
|
38
|
+
"@ckeditor/ckeditor5-highlight": "^37.0.0-alpha.1",
|
|
39
|
+
"@ckeditor/ckeditor5-horizontal-line": "^37.0.0-alpha.1",
|
|
40
|
+
"@ckeditor/ckeditor5-html-embed": "^37.0.0-alpha.1",
|
|
41
|
+
"@ckeditor/ckeditor5-image": "^37.0.0-alpha.1",
|
|
42
|
+
"@ckeditor/ckeditor5-indent": "^37.0.0-alpha.1",
|
|
43
|
+
"@ckeditor/ckeditor5-link": "^37.0.0-alpha.1",
|
|
44
|
+
"@ckeditor/ckeditor5-list": "^37.0.0-alpha.1",
|
|
45
|
+
"@ckeditor/ckeditor5-media-embed": "^37.0.0-alpha.1",
|
|
46
|
+
"@ckeditor/ckeditor5-page-break": "^37.0.0-alpha.1",
|
|
47
|
+
"@ckeditor/ckeditor5-paragraph": "^37.0.0-alpha.1",
|
|
48
|
+
"@ckeditor/ckeditor5-paste-from-office": "^37.0.0-alpha.1",
|
|
49
|
+
"@ckeditor/ckeditor5-remove-format": "^37.0.0-alpha.1",
|
|
50
|
+
"@ckeditor/ckeditor5-source-editing": "^37.0.0-alpha.1",
|
|
51
|
+
"@ckeditor/ckeditor5-table": "^37.0.0-alpha.1",
|
|
52
|
+
"@ckeditor/ckeditor5-theme-lark": "^37.0.0-alpha.1",
|
|
53
|
+
"@ckeditor/ckeditor5-utils": "^37.0.0-alpha.1",
|
|
54
|
+
"@ckeditor/ckeditor5-widget": "^37.0.0-alpha.1",
|
|
55
|
+
"typescript": "^4.8.4",
|
|
54
56
|
"webpack": "^5.58.1",
|
|
55
57
|
"webpack-cli": "^4.9.0"
|
|
56
58
|
},
|
|
@@ -69,13 +71,17 @@
|
|
|
69
71
|
},
|
|
70
72
|
"files": [
|
|
71
73
|
"lang",
|
|
72
|
-
"src",
|
|
74
|
+
"src/**/*.js",
|
|
75
|
+
"src/**/*.d.ts",
|
|
73
76
|
"theme",
|
|
74
77
|
"build",
|
|
75
78
|
"ckeditor5-metadata.json",
|
|
76
79
|
"CHANGELOG.md"
|
|
77
80
|
],
|
|
78
81
|
"scripts": {
|
|
79
|
-
"dll:build": "webpack"
|
|
80
|
-
|
|
82
|
+
"dll:build": "webpack",
|
|
83
|
+
"build": "tsc -p ./tsconfig.json",
|
|
84
|
+
"postversion": "npm run build"
|
|
85
|
+
},
|
|
86
|
+
"types": "src/index.d.ts"
|
|
81
87
|
}
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license Copyright (c) 2003-2023, CKSource Holding sp. z o.o. All rights reserved.
|
|
3
|
+
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
|
|
4
|
+
*/
|
|
5
|
+
import type { GeneralHtmlSupport, DataFilter, DataSchema, GeneralHtmlSupportConfig, CodeBlockElementSupport, CustomElementSupport, DocumentListElementSupport, DualContentModelElementSupport, HeadingElementSupport, ImageElementSupport, MediaEmbedElementSupport, ScriptElementSupport, StyleElementSupport, TableElementSupport, HtmlComment, FullPage } from './index';
|
|
6
|
+
declare module '@ckeditor/ckeditor5-core' {
|
|
7
|
+
interface EditorConfig {
|
|
8
|
+
/**
|
|
9
|
+
* The configuration of the General HTML Support feature.
|
|
10
|
+
* Introduced by the {@link module:html-support/generalhtmlsupport~GeneralHtmlSupport} feature.
|
|
11
|
+
*
|
|
12
|
+
* Read more in {@link module:html-support/generalhtmlsupportconfig~GeneralHtmlSupportConfig}.
|
|
13
|
+
*/
|
|
14
|
+
htmlSupport?: GeneralHtmlSupportConfig;
|
|
15
|
+
}
|
|
16
|
+
interface PluginsMap {
|
|
17
|
+
[GeneralHtmlSupport.pluginName]: GeneralHtmlSupport;
|
|
18
|
+
[DataFilter.pluginName]: DataFilter;
|
|
19
|
+
[DataSchema.pluginName]: DataSchema;
|
|
20
|
+
[CodeBlockElementSupport.pluginName]: CodeBlockElementSupport;
|
|
21
|
+
[CustomElementSupport.pluginName]: CustomElementSupport;
|
|
22
|
+
[DocumentListElementSupport.pluginName]: DocumentListElementSupport;
|
|
23
|
+
[DualContentModelElementSupport.pluginName]: DualContentModelElementSupport;
|
|
24
|
+
[HeadingElementSupport.pluginName]: HeadingElementSupport;
|
|
25
|
+
[ImageElementSupport.pluginName]: ImageElementSupport;
|
|
26
|
+
[MediaEmbedElementSupport.pluginName]: MediaEmbedElementSupport;
|
|
27
|
+
[ScriptElementSupport.pluginName]: ScriptElementSupport;
|
|
28
|
+
[StyleElementSupport.pluginName]: StyleElementSupport;
|
|
29
|
+
[TableElementSupport.pluginName]: TableElementSupport;
|
|
30
|
+
[HtmlComment.pluginName]: HtmlComment;
|
|
31
|
+
[FullPage.pluginName]: FullPage;
|
|
32
|
+
}
|
|
33
|
+
}
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license Copyright (c) 2003-2023, CKSource Holding sp. z o.o. All rights reserved.
|
|
3
|
+
* For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
|
|
4
|
+
*/
|
|
5
|
+
/**
|
|
6
|
+
* @module html-support/conversionutils
|
|
7
|
+
*/
|
|
8
|
+
import type { DowncastWriter, ViewElement } from 'ckeditor5/src/engine';
|
|
9
|
+
export interface GHSViewAttributes {
|
|
10
|
+
attributes?: Record<string, unknown>;
|
|
11
|
+
classes?: Array<string>;
|
|
12
|
+
styles?: Record<string, string>;
|
|
13
|
+
}
|
|
14
|
+
/**
|
|
15
|
+
* Helper function for the downcast converter. Updates attributes on the given view element.
|
|
16
|
+
*
|
|
17
|
+
* @param writer The view writer.
|
|
18
|
+
* @param oldViewAttributes The previous GHS attribute value.
|
|
19
|
+
* @param newViewAttributes The current GHS attribute value.
|
|
20
|
+
* @param viewElement The view element to update.
|
|
21
|
+
*/
|
|
22
|
+
export declare function updateViewAttributes(writer: DowncastWriter, oldViewAttributes: GHSViewAttributes, newViewAttributes: GHSViewAttributes, viewElement: ViewElement): void;
|
|
23
|
+
/**
|
|
24
|
+
* Helper function for the downcast converter. Sets attributes on the given view element.
|
|
25
|
+
*
|
|
26
|
+
* @param writer The view writer.
|
|
27
|
+
* @param viewAttributes The GHS attribute value.
|
|
28
|
+
* @param viewElement The view element to update.
|
|
29
|
+
*/
|
|
30
|
+
export declare function setViewAttributes(writer: DowncastWriter, viewAttributes: GHSViewAttributes, viewElement: ViewElement): void;
|
|
31
|
+
/**
|
|
32
|
+
* Helper function for the downcast converter. Removes attributes on the given view element.
|
|
33
|
+
*
|
|
34
|
+
* @param writer The view writer.
|
|
35
|
+
* @param viewAttributes The GHS attribute value.
|
|
36
|
+
* @param viewElement The view element to update.
|
|
37
|
+
*/
|
|
38
|
+
export declare function removeViewAttributes(writer: DowncastWriter, viewAttributes: GHSViewAttributes, viewElement: ViewElement): void;
|
|
39
|
+
/**
|
|
40
|
+
* Merges view element attribute objects.
|
|
41
|
+
*/
|
|
42
|
+
export declare function mergeViewElementAttributes(target: GHSViewAttributes, source: GHSViewAttributes): GHSViewAttributes;
|