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

@ckeditor/ckeditor5-html-support

Package Overview
Dependencies
Maintainers
1
Versions
669
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@ckeditor/ckeditor5-html-support - npm Package Compare versions

Comparing version 30.0.0 to 31.0.0

build/translations/pl.js

2

build/html-support.js

@@ -5,2 +5,2 @@ /*!

*/
!function(e){const t=e.en=e.en||{};t.dictionary=Object.assign(t.dictionary||{},{"HTML object":"HTML object"})}(window.CKEDITOR_TRANSLATIONS||(window.CKEDITOR_TRANSLATIONS={})),window.CKEditor5=window.CKEditor5||{},window.CKEditor5.htmlSupport=function(e){var t={};function r(o){if(t[o])return t[o].exports;var n=t[o]={i:o,l:!1,exports:{}};return e[o].call(n.exports,n,n.exports,r),n.l=!0,n.exports}return r.m=e,r.c=t,r.d=function(e,t,o){r.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:o})},r.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},r.t=function(e,t){if(1&t&&(e=r(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var o=Object.create(null);if(r.r(o),Object.defineProperty(o,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var n in e)r.d(o,n,function(t){return e[t]}.bind(null,n));return o},r.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return r.d(t,"a",t),t},r.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},r.p="",r(r.s=17)}([function(e,t,r){"use strict";var o=r(6),n="object"==typeof self&&self&&self.Object===Object&&self,i=o.a||n||Function("return this")();t.a=i},function(e,t,r){e.exports=r(4)("./src/core.js")},function(e,t,r){e.exports=r(4)("./src/utils.js")},function(e,t,r){"use strict";(function(e){var o=r(6),n="object"==typeof exports&&exports&&!exports.nodeType&&exports,i=n&&"object"==typeof e&&e&&!e.nodeType&&e,l=i&&i.exports===n&&o.a.process,a=function(){try{var e=i&&i.require&&i.require("util").types;return e||l&&l.binding&&l.binding("util")}catch(e){}}();t.a=a}).call(this,r(8)(e))},function(e,t){e.exports=CKEditor5.dll},function(e,t,r){e.exports=r(4)("./src/widget.js")},function(e,t,r){"use strict";(function(e){var r="object"==typeof e&&e&&e.Object===Object&&e;t.a=r}).call(this,r(13))},function(e,t,r){"use strict";(function(e){var o=r(0),n=r(10),i="object"==typeof exports&&exports&&!exports.nodeType&&exports,l=i&&"object"==typeof e&&e&&!e.nodeType&&e,a=l&&l.exports===i?o.a.Buffer:void 0,c=(a?a.isBuffer:void 0)||n.a;t.a=c}).call(this,r(8)(e))},function(e,t){e.exports=function(e){if(!e.webpackPolyfill){var t=Object.create(e);t.children||(t.children=[]),Object.defineProperty(t,"loaded",{enumerable:!0,get:function(){return t.l}}),Object.defineProperty(t,"id",{enumerable:!0,get:function(){return t.i}}),Object.defineProperty(t,"exports",{enumerable:!0}),t.webpackPolyfill=1}return t}},function(e,t,r){e.exports=r(4)("./src/engine.js")},function(e,t,r){"use strict";t.a=function(){return!1}},function(e,t,r){"use strict";(function(e){var o=r(0),n="object"==typeof exports&&exports&&!exports.nodeType&&exports,i=n&&"object"==typeof e&&e&&!e.nodeType&&e,l=i&&i.exports===n?o.a.Buffer:void 0,a=l?l.allocUnsafe:void 0;t.a=function(e,t){if(t)return e.slice();var r=e.length,o=a?a(r):new e.constructor(r);return e.copy(o),o}}).call(this,r(8)(e))},,function(e,t){var r;r=function(){return this}();try{r=r||new Function("return this")()}catch(e){"object"==typeof window&&(r=window)}e.exports=r},function(e,t,r){var o=r(15),n=r(16);"string"==typeof(n=n.__esModule?n.default:n)&&(n=[[e.i,n,""]]);var i={injectType:"singletonStyleTag",attributes:{"data-cke":!0},insert:"head",singleton:!0};o(n,i);e.exports=n.locals||{}},function(e,t,r){"use strict";var o,n=function(){return void 0===o&&(o=Boolean(window&&document&&document.all&&!window.atob)),o},i=function(){var e={};return function(t){if(void 0===e[t]){var r=document.querySelector(t);if(window.HTMLIFrameElement&&r instanceof window.HTMLIFrameElement)try{r=r.contentDocument.head}catch(e){r=null}e[t]=r}return e[t]}}(),l=[];function a(e){for(var t=-1,r=0;r<l.length;r++)if(l[r].identifier===e){t=r;break}return t}function c(e,t){for(var r={},o=[],n=0;n<e.length;n++){var i=e[n],c=t.base?i[0]+t.base:i[0],s=r[c]||0,m="".concat(c," ").concat(s);r[c]=s+1;var u=a(m),d={css:i[1],media:i[2],sourceMap:i[3]};-1!==u?(l[u].references++,l[u].updater(d)):l.push({identifier:m,updater:p(d,t),references:1}),o.push(m)}return o}function s(e){var t=document.createElement("style"),o=e.attributes||{};if(void 0===o.nonce){var n=r.nc;n&&(o.nonce=n)}if(Object.keys(o).forEach((function(e){t.setAttribute(e,o[e])})),"function"==typeof e.insert)e.insert(t);else{var l=i(e.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(t)}return t}var m,u=(m=[],function(e,t){return m[e]=t,m.filter(Boolean).join("\n")});function d(e,t,r,o){var n=r?"":o.media?"@media ".concat(o.media," {").concat(o.css,"}"):o.css;if(e.styleSheet)e.styleSheet.cssText=u(t,n);else{var i=document.createTextNode(n),l=e.childNodes;l[t]&&e.removeChild(l[t]),l.length?e.insertBefore(i,l[t]):e.appendChild(i)}}function h(e,t,r){var o=r.css,n=r.media,i=r.sourceMap;if(n?e.setAttribute("media",n):e.removeAttribute("media"),i&&"undefined"!=typeof btoa&&(o+="\n/*# sourceMappingURL=data:application/json;base64,".concat(btoa(unescape(encodeURIComponent(JSON.stringify(i))))," */")),e.styleSheet)e.styleSheet.cssText=o;else{for(;e.firstChild;)e.removeChild(e.firstChild);e.appendChild(document.createTextNode(o))}}var f=null,b=0;function p(e,t){var r,o,n;if(t.singleton){var i=b++;r=f||(f=s(t)),o=d.bind(null,r,i,!1),n=d.bind(null,r,i,!0)}else r=s(t),o=h.bind(null,r,t),n=function(){!function(e){if(null===e.parentNode)return!1;e.parentNode.removeChild(e)}(r)};return o(e),function(t){if(t){if(t.css===e.css&&t.media===e.media&&t.sourceMap===e.sourceMap)return;o(e=t)}else n()}}e.exports=function(e,t){(t=t||{}).singleton||"boolean"==typeof t.singleton||(t.singleton=n());var r=c(e=e||[],t);return function(e){if(e=e||[],"[object Array]"===Object.prototype.toString.call(e)){for(var o=0;o<r.length;o++){var n=a(r[o]);l[n].references--}for(var i=c(e,t),s=0;s<r.length;s++){var m=a(r[s]);0===l[m].references&&(l[m].updater(),l.splice(m,1))}r=i}}}},function(e,t){e.exports=":root{--ck-html-object-embed-unfocused-outline-width:1px}.ck-widget.html-object-embed{font-size:var(--ck-font-size-base);background-color:var(--ck-color-base-foreground);padding:var(--ck-spacing-small);padding-top:calc(var(--ck-font-size-tiny) + var(--ck-spacing-large));min-width:calc(76px + var(--ck-spacing-standard))}.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{font-weight:400;font-style:normal;position:absolute;content:attr(data-html-object-embed-label);top:0;left:var(--ck-spacing-standard);background:#999;transition:background var(--ck-widget-handler-animation-duration) var(--ck-widget-handler-animation-curve);padding:calc(var(--ck-spacing-tiny) + var(--ck-html-object-embed-unfocused-outline-width)) var(--ck-spacing-small) var(--ck-spacing-tiny);border-radius:0 0 var(--ck-border-radius) var(--ck-border-radius);color:var(--ck-color-base-background);font-size:var(--ck-font-size-tiny);font-family:var(--ck-font-face)}.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}"},function(e,t,r){"use strict";r.r(t),r.d(t,"GeneralHtmlSupport",(function(){return Kr})),r.d(t,"DataFilter",(function(){return Br})),r.d(t,"DataSchema",(function(){return a})),r.d(t,"HtmlComment",(function(){return Gr}));var o=r(1),n=r(2),i=[{model:"heading1",view:"h2"},{model:"heading2",view:"h3"},{model:"heading3",view:"h4"},{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:"$htmlSection",modelSchema:{allowChildren:"$block",allowIn:["$root","$htmlSection"],isBlock:!0}},{model:"htmlP",view:"p",modelSchema:{inheritAllFrom:"$block"}},{model:"htmlBlockquote",view:"blockquote",modelSchema:{inheritAllFrom:"$htmlSection"}},{model:"htmlTable",view:"table",modelSchema:{allowIn:["$htmlSection","$root"],isBlock:!0}},{model:"htmlTbody",view:"tbody",modelSchema:{allowIn:"htmlTable",isBlock:!0}},{model:"htmlThead",view:"thead",modelSchema:{allowIn:"htmlTable",isBlock:!0}},{model:"htmlTfoot",view:"tfoot",modelSchema:{allowIn:"htmlTable",isBlock:!0}},{model:"htmlCaption",view:"caption",modelSchema:{allowIn:"htmlTable",allowChildren:"$text",isBlock:!0}},{model:"htmlTr",view:"tr",modelSchema:{allowIn:["htmlTable","htmlThead","htmlTbody"],isBlock:!0}},{model:"htmlTd",view:"td",modelSchema:{allowIn:"htmlTr",allowChildren:["$block","$htmlSection"],isBlock:!0}},{model:"htmlTh",view:"th",modelSchema:{allowIn:"htmlTr",allowChildren:["$block","$htmlSection"],isBlock:!0}},{model:"htmlFigure",view:"figure",modelSchema:{inheritAllFrom:"$htmlSection",isBlock:!0}},{model:"htmlFigcaption",view:"figcaption",modelSchema:{allowIn:"htmlFigure",allowChildren:"$text",isBlock:!0}},{model:"htmlAddress",view:"address",modelSchema:{inheritAllFrom:"$htmlSection"}},{model:"htmlAside",view:"aside",modelSchema:{inheritAllFrom:"$htmlSection"}},{model:"htmlMain",view:"main",modelSchema:{inheritAllFrom:"$htmlSection"}},{model:"htmlDetails",view:"details",modelSchema:{inheritAllFrom:"$htmlSection"}},{model:"htmlSummary",view:"summary",modelSchema:{allowChildren:"$text",allowIn:"htmlDetails",isBlock:!0}},{model:"htmlDiv",view:"div",paragraphLikeModel:"htmlDivParagraph",modelSchema:{inheritAllFrom:"$htmlSection"}},{model:"htmlFieldset",view:"fieldset",modelSchema:{inheritAllFrom:"$htmlSection"}},{model:"htmlLegend",view:"legend",modelSchema:{allowIn:"htmlFieldset",allowChildren:"$text"}},{model:"htmlHeader",view:"header",modelSchema:{inheritAllFrom:"$htmlSection"}},{model:"htmlFooter",view:"footer",modelSchema:{inheritAllFrom:"$htmlSection"}},{model:"htmlForm",view:"form",modelSchema:{inheritAllFrom:"$htmlSection"}},{model:"htmlHgroup",view:"hgroup",modelSchema:{allowChildren:["htmlHeading1","htmlHeading2","htmlHeading3","htmlHeading4","htmlHeading5","htmlHeading6","heading1","heading2","heading3"],isBlock:!0}},{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:"$htmlSection",allowChildren:["$htmlList","htmlLi"],isBlock:!0}},{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:!0}},{model:"htmlPre",view:"pre",modelSchema:{inheritAllFrom:"$block"}},{model:"htmlArticle",view:"article",modelSchema:{inheritAllFrom:"$htmlSection"}},{model:"htmlSection",view:"section",modelSchema:{inheritAllFrom:"$htmlSection"}},{model:"htmlNav",view:"nav",modelSchema:{inheritAllFrom:"$htmlSection"}},{model:"htmlDl",view:"dl",modelSchema:{allowIn:["$htmlSection","$root"],allowChildren:["htmlDt","htmlDd"],isBlock:!0}},{model:"htmlDt",view:"dt",modelSchema:{allowChildren:"$block",isBlock:!0}},{model:"htmlDd",view:"dd",modelSchema:{allowChildren:"$block",isBlock:!0}},{model:"htmlCenter",view:"center",modelSchema:{inheritAllFrom:"$htmlSection"}},{model:"$htmlObjectBlock",isObject:!0,modelSchema:{isObject:!0,isBlock:!0,allowWhere:"$block"}}],l=[{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,attributeProperties:{copyOnEnter:!0}},{model:"htmlStrong",view:"strong",attributeProperties:{copyOnEnter:!0}},{model:"htmlB",view:"b",attributeProperties:{copyOnEnter:!0}},{model:"htmlI",view:"i",attributeProperties:{copyOnEnter:!0}},{model:"htmlEm",view:"em",attributeProperties:{copyOnEnter:!0}},{model:"htmlS",view:"s",attributeProperties:{copyOnEnter:!0}},{model:"htmlDel",view:"del",attributeProperties:{copyOnEnter:!0}},{model:"htmlIns",view:"ins",attributeProperties:{copyOnEnter:!0}},{model:"htmlU",view:"u",attributeProperties:{copyOnEnter:!0}},{model:"htmlSub",view:"sub",attributeProperties:{copyOnEnter:!0}},{model:"htmlSup",view:"sup",attributeProperties:{copyOnEnter:!0}},{model:"htmlCode",view:"code",attributeProperties:{copyOnEnter:!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:"$htmlObjectInline",isObject:!0,modelSchema:{isObject:!0,isInline:!0,allowWhere:"$text",allowAttributesOf:"$text"}},{model:"htmlObject",view:"object",isObject:!0,modelSchema:{inheritAllFrom:"$htmlObjectInline"}},{model:"htmlIframe",view:"iframe",isObject:!0,modelSchema:{inheritAllFrom:"$htmlObjectInline"}},{model:"htmlInput",view:"input",isObject:!0,modelSchema:{inheritAllFrom:"$htmlObjectInline"}},{model:"htmlButton",view:"button",isObject:!0,modelSchema:{inheritAllFrom:"$htmlObjectInline"}},{model:"htmlTextarea",view:"textarea",isObject:!0,modelSchema:{inheritAllFrom:"$htmlObjectInline"}},{model:"htmlSelect",view:"select",isObject:!0,modelSchema:{inheritAllFrom:"$htmlObjectInline"}},{model:"htmlVideo",view:"video",isObject:!0,modelSchema:{inheritAllFrom:"$htmlObjectInline"}},{model:"htmlEmbed",view:"embed",isObject:!0,modelSchema:{inheritAllFrom:"$htmlObjectInline"}},{model:"htmlOembed",view:"oembed",isObject:!0,modelSchema:{inheritAllFrom:"$htmlObjectInline"}},{model:"htmlAudio",view:"audio",isObject:!0,modelSchema:{inheritAllFrom:"$htmlObjectInline"}},{model:"htmlImg",view:"img",isObject:!0,modelSchema:{inheritAllFrom:"$htmlObjectInline"}},{model:"htmlCanvas",view:"canvas",isObject:!0,modelSchema:{inheritAllFrom:"$htmlObjectInline"}},{model:"htmlMeter",view:"meter",isObject:!0,modelSchema:{inheritAllFrom:"$htmlObjectInline"}},{model:"htmlProgress",view:"progress",isObject:!0,modelSchema:{inheritAllFrom:"$htmlObjectInline"}}];class a extends o.Plugin{constructor(e){super(e),this._definitions=new Map}static get pluginName(){return"DataSchema"}init(){for(const e of i)this.registerBlockElement(e);for(const e of l)this.registerInlineElement(e)}registerBlockElement(e){this._definitions.set(e.model,{...e,isBlock:!0})}registerInlineElement(e){this._definitions.set(e.model,{...e,isInline:!0})}getDefinitionsForView(e,t){const r=new Set;for(const o of this._getMatchingViewDefinitions(e)){if(t)for(const e of this._getReferences(o.model))r.add(e);r.add(o)}return r}_getMatchingViewDefinitions(e){return Array.from(this._definitions.values()).filter(t=>t.view&&function(e,t){if("string"==typeof e)return e===t;if(e instanceof RegExp)return e.test(t);return!1}(e,t.view))}*_getReferences(e){const{modelSchema:t}=this._definitions.get(e);if(!t)return;const r=["inheritAllFrom","inheritTypesFrom","allowWhere","allowContentOf","allowAttributesOf"];for(const o of r)for(const r of Object(n.toArray)(t[o]||[])){const t=this._definitions.get(r);r!==e&&t&&(yield*this._getReferences(t.model),yield t)}}}var c=r(9),s=r(5);var m=function(){this.__data__=[],this.size=0};var u=function(e,t){return e===t||e!=e&&t!=t};var d=function(e,t){for(var r=e.length;r--;)if(u(e[r][0],t))return r;return-1},h=Array.prototype.splice;var f=function(e){var t=this.__data__,r=d(t,e);return!(r<0)&&(r==t.length-1?t.pop():h.call(t,r,1),--this.size,!0)};var b=function(e){var t=this.__data__,r=d(t,e);return r<0?void 0:t[r][1]};var p=function(e){return d(this.__data__,e)>-1};var v=function(e,t){var r=this.__data__,o=d(r,e);return o<0?(++this.size,r.push([e,t])):r[o][1]=t,this};function g(e){var t=-1,r=null==e?0:e.length;for(this.clear();++t<r;){var o=e[t];this.set(o[0],o[1])}}g.prototype.clear=m,g.prototype.delete=f,g.prototype.get=b,g.prototype.has=p,g.prototype.set=v;var w=g;var y=function(){this.__data__=new w,this.size=0};var j=function(e){var t=this.__data__,r=t.delete(e);return this.size=t.size,r};var A=function(e){return this.__data__.get(e)};var _=function(e){return this.__data__.has(e)},O=r(0),S=O.a.Symbol,k=Object.prototype,E=k.hasOwnProperty,$=k.toString,C=S?S.toStringTag:void 0;var I=function(e){var t=E.call(e,C),r=e[C];try{e[C]=void 0;var o=!0}catch(e){}var n=$.call(e);return o&&(t?e[C]=r:delete e[C]),n},P=Object.prototype.toString;var F=function(e){return P.call(e)},x=S?S.toStringTag:void 0;var T=function(e){return null==e?void 0===e?"[object Undefined]":"[object Null]":x&&x in Object(e)?I(e):F(e)};var B=function(e){var t=typeof e;return null!=e&&("object"==t||"function"==t)};var R,M=function(e){if(!B(e))return!1;var t=T(e);return"[object Function]"==t||"[object GeneratorFunction]"==t||"[object AsyncFunction]"==t||"[object Proxy]"==t},D=O.a["__core-js_shared__"],H=(R=/[^.]+$/.exec(D&&D.keys&&D.keys.IE_PROTO||""))?"Symbol(src)_1."+R:"";var L=function(e){return!!H&&H in e},z=Function.prototype.toString;var N=function(e){if(null!=e){try{return z.call(e)}catch(e){}try{return e+""}catch(e){}}return""},V=/^\[object .+?Constructor\]$/,U=Function.prototype,W=Object.prototype,q=U.toString,K=W.hasOwnProperty,G=RegExp("^"+q.call(K).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");var Q=function(e){return!(!B(e)||L(e))&&(M(e)?G:V).test(N(e))};var J=function(e,t){return null==e?void 0:e[t]};var X=function(e,t){var r=J(e,t);return Q(r)?r:void 0},Y=X(O.a,"Map"),Z=X(Object,"create");var ee=function(){this.__data__=Z?Z(null):{},this.size=0};var te=function(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t},re=Object.prototype.hasOwnProperty;var oe=function(e){var t=this.__data__;if(Z){var r=t[e];return"__lodash_hash_undefined__"===r?void 0:r}return re.call(t,e)?t[e]:void 0},ne=Object.prototype.hasOwnProperty;var ie=function(e){var t=this.__data__;return Z?void 0!==t[e]:ne.call(t,e)};var le=function(e,t){var r=this.__data__;return this.size+=this.has(e)?0:1,r[e]=Z&&void 0===t?"__lodash_hash_undefined__":t,this};function ae(e){var t=-1,r=null==e?0:e.length;for(this.clear();++t<r;){var o=e[t];this.set(o[0],o[1])}}ae.prototype.clear=ee,ae.prototype.delete=te,ae.prototype.get=oe,ae.prototype.has=ie,ae.prototype.set=le;var ce=ae;var se=function(){this.size=0,this.__data__={hash:new ce,map:new(Y||w),string:new ce}};var me=function(e){var t=typeof e;return"string"==t||"number"==t||"symbol"==t||"boolean"==t?"__proto__"!==e:null===e};var ue=function(e,t){var r=e.__data__;return me(t)?r["string"==typeof t?"string":"hash"]:r.map};var de=function(e){var t=ue(this,e).delete(e);return this.size-=t?1:0,t};var he=function(e){return ue(this,e).get(e)};var fe=function(e){return ue(this,e).has(e)};var be=function(e,t){var r=ue(this,e),o=r.size;return r.set(e,t),this.size+=r.size==o?0:1,this};function pe(e){var t=-1,r=null==e?0:e.length;for(this.clear();++t<r;){var o=e[t];this.set(o[0],o[1])}}pe.prototype.clear=se,pe.prototype.delete=de,pe.prototype.get=he,pe.prototype.has=fe,pe.prototype.set=be;var ve=pe;var ge=function(e,t){var r=this.__data__;if(r instanceof w){var o=r.__data__;if(!Y||o.length<199)return o.push([e,t]),this.size=++r.size,this;r=this.__data__=new ve(o)}return r.set(e,t),this.size=r.size,this};function we(e){var t=this.__data__=new w(e);this.size=t.size}we.prototype.clear=y,we.prototype.delete=j,we.prototype.get=A,we.prototype.has=_,we.prototype.set=ge;var ye=we;var je=function(e,t){for(var r=-1,o=null==e?0:e.length;++r<o&&!1!==t(e[r],r,e););return e},Ae=function(){try{var e=X(Object,"defineProperty");return e({},"",{}),e}catch(e){}}();var _e=function(e,t,r){"__proto__"==t&&Ae?Ae(e,t,{configurable:!0,enumerable:!0,value:r,writable:!0}):e[t]=r},Oe=Object.prototype.hasOwnProperty;var Se=function(e,t,r){var o=e[t];Oe.call(e,t)&&u(o,r)&&(void 0!==r||t in e)||_e(e,t,r)};var ke=function(e,t,r,o){var n=!r;r||(r={});for(var i=-1,l=t.length;++i<l;){var a=t[i],c=o?o(r[a],e[a],a,r,e):void 0;void 0===c&&(c=e[a]),n?_e(r,a,c):Se(r,a,c)}return r};var Ee=function(e,t){for(var r=-1,o=Array(e);++r<e;)o[r]=t(r);return o};var $e=function(e){return null!=e&&"object"==typeof e};var Ce=function(e){return $e(e)&&"[object Arguments]"==T(e)},Ie=Object.prototype,Pe=Ie.hasOwnProperty,Fe=Ie.propertyIsEnumerable,xe=Ce(function(){return arguments}())?Ce:function(e){return $e(e)&&Pe.call(e,"callee")&&!Fe.call(e,"callee")},Te=Array.isArray,Be=r(7),Re=/^(?:0|[1-9]\d*)$/;var Me=function(e,t){var r=typeof e;return!!(t=null==t?9007199254740991:t)&&("number"==r||"symbol"!=r&&Re.test(e))&&e>-1&&e%1==0&&e<t};var De=function(e){return"number"==typeof e&&e>-1&&e%1==0&&e<=9007199254740991},He={};He["[object Float32Array]"]=He["[object Float64Array]"]=He["[object Int8Array]"]=He["[object Int16Array]"]=He["[object Int32Array]"]=He["[object Uint8Array]"]=He["[object Uint8ClampedArray]"]=He["[object Uint16Array]"]=He["[object Uint32Array]"]=!0,He["[object Arguments]"]=He["[object Array]"]=He["[object ArrayBuffer]"]=He["[object Boolean]"]=He["[object DataView]"]=He["[object Date]"]=He["[object Error]"]=He["[object Function]"]=He["[object Map]"]=He["[object Number]"]=He["[object Object]"]=He["[object RegExp]"]=He["[object Set]"]=He["[object String]"]=He["[object WeakMap]"]=!1;var Le=function(e){return $e(e)&&De(e.length)&&!!He[T(e)]};var ze=function(e){return function(t){return e(t)}},Ne=r(3),Ve=Ne.a&&Ne.a.isTypedArray,Ue=Ve?ze(Ve):Le,We=Object.prototype.hasOwnProperty;var qe=function(e,t){var r=Te(e),o=!r&&xe(e),n=!r&&!o&&Object(Be.a)(e),i=!r&&!o&&!n&&Ue(e),l=r||o||n||i,a=l?Ee(e.length,String):[],c=a.length;for(var s in e)!t&&!We.call(e,s)||l&&("length"==s||n&&("offset"==s||"parent"==s)||i&&("buffer"==s||"byteLength"==s||"byteOffset"==s)||Me(s,c))||a.push(s);return a},Ke=Object.prototype;var Ge=function(e){var t=e&&e.constructor;return e===("function"==typeof t&&t.prototype||Ke)};var Qe=function(e,t){return function(r){return e(t(r))}},Je=Qe(Object.keys,Object),Xe=Object.prototype.hasOwnProperty;var Ye=function(e){if(!Ge(e))return Je(e);var t=[];for(var r in Object(e))Xe.call(e,r)&&"constructor"!=r&&t.push(r);return t};var Ze=function(e){return null!=e&&De(e.length)&&!M(e)};var et=function(e){return Ze(e)?qe(e):Ye(e)};var tt=function(e,t){return e&&ke(t,et(t),e)};var rt=function(e){var t=[];if(null!=e)for(var r in Object(e))t.push(r);return t},ot=Object.prototype.hasOwnProperty;var nt=function(e){if(!B(e))return rt(e);var t=Ge(e),r=[];for(var o in e)("constructor"!=o||!t&&ot.call(e,o))&&r.push(o);return r};var it=function(e){return Ze(e)?qe(e,!0):nt(e)};var lt=function(e,t){return e&&ke(t,it(t),e)},at=r(11);var ct=function(e,t){var r=-1,o=e.length;for(t||(t=Array(o));++r<o;)t[r]=e[r];return t};var st=function(e,t){for(var r=-1,o=null==e?0:e.length,n=0,i=[];++r<o;){var l=e[r];t(l,r,e)&&(i[n++]=l)}return i};var mt=function(){return[]},ut=Object.prototype.propertyIsEnumerable,dt=Object.getOwnPropertySymbols,ht=dt?function(e){return null==e?[]:(e=Object(e),st(dt(e),(function(t){return ut.call(e,t)})))}:mt;var ft=function(e,t){return ke(e,ht(e),t)};var bt=function(e,t){for(var r=-1,o=t.length,n=e.length;++r<o;)e[n+r]=t[r];return e},pt=Qe(Object.getPrototypeOf,Object),vt=Object.getOwnPropertySymbols?function(e){for(var t=[];e;)bt(t,ht(e)),e=pt(e);return t}:mt;var gt=function(e,t){return ke(e,vt(e),t)};var wt=function(e,t,r){var o=t(e);return Te(e)?o:bt(o,r(e))};var yt=function(e){return wt(e,et,ht)};var jt=function(e){return wt(e,it,vt)},At=X(O.a,"DataView"),_t=X(O.a,"Promise"),Ot=X(O.a,"Set"),St=X(O.a,"WeakMap"),kt=N(At),Et=N(Y),$t=N(_t),Ct=N(Ot),It=N(St),Pt=T;(At&&"[object DataView]"!=Pt(new At(new ArrayBuffer(1)))||Y&&"[object Map]"!=Pt(new Y)||_t&&"[object Promise]"!=Pt(_t.resolve())||Ot&&"[object Set]"!=Pt(new Ot)||St&&"[object WeakMap]"!=Pt(new St))&&(Pt=function(e){var t=T(e),r="[object Object]"==t?e.constructor:void 0,o=r?N(r):"";if(o)switch(o){case kt:return"[object DataView]";case Et:return"[object Map]";case $t:return"[object Promise]";case Ct:return"[object Set]";case It:return"[object WeakMap]"}return t});var Ft=Pt,xt=Object.prototype.hasOwnProperty;var Tt=function(e){var t=e.length,r=new e.constructor(t);return t&&"string"==typeof e[0]&&xt.call(e,"index")&&(r.index=e.index,r.input=e.input),r},Bt=O.a.Uint8Array;var Rt=function(e){var t=new e.constructor(e.byteLength);return new Bt(t).set(new Bt(e)),t};var Mt=function(e,t){var r=t?Rt(e.buffer):e.buffer;return new e.constructor(r,e.byteOffset,e.byteLength)},Dt=/\w*$/;var Ht=function(e){var t=new e.constructor(e.source,Dt.exec(e));return t.lastIndex=e.lastIndex,t},Lt=S?S.prototype:void 0,zt=Lt?Lt.valueOf:void 0;var Nt=function(e){return zt?Object(zt.call(e)):{}};var Vt=function(e,t){var r=t?Rt(e.buffer):e.buffer;return new e.constructor(r,e.byteOffset,e.length)};var Ut=function(e,t,r){var o=e.constructor;switch(t){case"[object ArrayBuffer]":return Rt(e);case"[object Boolean]":case"[object Date]":return new o(+e);case"[object DataView]":return Mt(e,r);case"[object Float32Array]":case"[object Float64Array]":case"[object Int8Array]":case"[object Int16Array]":case"[object Int32Array]":case"[object Uint8Array]":case"[object Uint8ClampedArray]":case"[object Uint16Array]":case"[object Uint32Array]":return Vt(e,r);case"[object Map]":return new o;case"[object Number]":case"[object String]":return new o(e);case"[object RegExp]":return Ht(e);case"[object Set]":return new o;case"[object Symbol]":return Nt(e)}},Wt=Object.create,qt=function(){function e(){}return function(t){if(!B(t))return{};if(Wt)return Wt(t);e.prototype=t;var r=new e;return e.prototype=void 0,r}}();var Kt=function(e){return"function"!=typeof e.constructor||Ge(e)?{}:qt(pt(e))};var Gt=function(e){return $e(e)&&"[object Map]"==Ft(e)},Qt=Ne.a&&Ne.a.isMap,Jt=Qt?ze(Qt):Gt;var Xt=function(e){return $e(e)&&"[object Set]"==Ft(e)},Yt=Ne.a&&Ne.a.isSet,Zt=Yt?ze(Yt):Xt,er={};er["[object Arguments]"]=er["[object Array]"]=er["[object ArrayBuffer]"]=er["[object DataView]"]=er["[object Boolean]"]=er["[object Date]"]=er["[object Float32Array]"]=er["[object Float64Array]"]=er["[object Int8Array]"]=er["[object Int16Array]"]=er["[object Int32Array]"]=er["[object Map]"]=er["[object Number]"]=er["[object Object]"]=er["[object RegExp]"]=er["[object Set]"]=er["[object String]"]=er["[object Symbol]"]=er["[object Uint8Array]"]=er["[object Uint8ClampedArray]"]=er["[object Uint16Array]"]=er["[object Uint32Array]"]=!0,er["[object Error]"]=er["[object Function]"]=er["[object WeakMap]"]=!1;var tr=function e(t,r,o,n,i,l){var a,c=1&r,s=2&r,m=4&r;if(o&&(a=i?o(t,n,i,l):o(t)),void 0!==a)return a;if(!B(t))return t;var u=Te(t);if(u){if(a=Tt(t),!c)return ct(t,a)}else{var d=Ft(t),h="[object Function]"==d||"[object GeneratorFunction]"==d;if(Object(Be.a)(t))return Object(at.a)(t,c);if("[object Object]"==d||"[object Arguments]"==d||h&&!i){if(a=s||h?{}:Kt(t),!c)return s?gt(t,lt(a,t)):ft(t,tt(a,t))}else{if(!er[d])return i?t:{};a=Ut(t,d,c)}}l||(l=new ye);var f=l.get(t);if(f)return f;l.set(t,a),Zt(t)?t.forEach((function(n){a.add(e(n,r,o,n,t,l))})):Jt(t)&&t.forEach((function(n,i){a.set(i,e(n,r,o,i,t,l))}));var b=u?void 0:(m?s?jt:yt:s?it:et)(t);return je(b||t,(function(n,i){b&&(n=t[i=n]),Se(a,i,e(n,r,o,i,t,l))})),a};var rr=function(e){return tr(e,5)};function or(e,t,r){if(t.attributes)for(const[o,n]of Object.entries(t.attributes))e.setAttribute(o,n,r);t.styles&&e.setStyle(t.styles,r),t.classes&&e.addClass(t.classes,r)}function nr(e,t){const r=rr(e);for(const o in t)Array.isArray(t[o])?r[o]=Array.from(new Set([...e[o],...t[o]])):r[o]={...e[o],...t[o]};return r}function ir({model:e}){return(t,r)=>r.writer.createElement(e,{htmlContent:t.getCustomProperty("$rawContent")})}function lr(e,{view:t,isInline:r}){const o=e.t;return(e,{writer:n,consumable:i})=>{const l=o("HTML object"),a=n.createContainerElement(r?"span":"div",{class:"html-object-embed","data-html-object-embed-label":l},{isAllowedInsideAttributeElement:r}),c=ar(t,e,n);n.addClass("html-object-embed__content",c);const m=e.getAttribute("htmlAttributes");return m&&i.consume(e,"attribute:htmlAttributes:"+e.name)&&or(n,m,c),n.insert(n.createPositionAt(a,0),c),Object(s.toWidget)(a,n,{widgetLabel:l})}}function ar(e,t,r){return r.createRawElement(e,null,(function(e){e.innerHTML=t.getAttribute("htmlContent")}))}function cr({priority:e,view:t}){return(r,o)=>{if(!r)return;const{writer:n}=o,i=n.createAttributeElement(t,null,{priority:e});return or(n,r,i),i}}function sr({view:e},t){return r=>{r.on("element:"+e,(e,r,o)=>{if(!r.modelRange)return;const n=t._consumeAllowedAttributes(r.viewItem,o);n&&o.writer.setAttribute("htmlAttributes",n,r.modelRange)},{priority:"low"})}}function mr({model:e}){return t=>{t.on("attribute:htmlAttributes:"+e,(e,t,r)=>{const o=t.attributeNewValue;if(!r.consumable.consume(t.item,e.name))return;or(r.writer,o,r.mapper.toViewElement(t.item))})}}var ur=function(e){return e};var dr=function(e,t,r){switch(r.length){case 0:return e.call(t);case 1:return e.call(t,r[0]);case 2:return e.call(t,r[0],r[1]);case 3:return e.call(t,r[0],r[1],r[2])}return e.apply(t,r)},hr=Math.max;var fr=function(e,t,r){return t=hr(void 0===t?e.length-1:t,0),function(){for(var o=arguments,n=-1,i=hr(o.length-t,0),l=Array(i);++n<i;)l[n]=o[t+n];n=-1;for(var a=Array(t+1);++n<t;)a[n]=o[n];return a[t]=r(l),dr(e,this,a)}};var br=function(e){return function(){return e}},pr=Ae?function(e,t){return Ae(e,"toString",{configurable:!0,enumerable:!1,value:br(t),writable:!0})}:ur,vr=Date.now;var gr=function(e){var t=0,r=0;return function(){var o=vr(),n=16-(o-r);if(r=o,n>0){if(++t>=800)return arguments[0]}else t=0;return e.apply(void 0,arguments)}}(pr);var wr=function(e,t){return gr(fr(e,t,ur),e+"")};var yr=function(e,t){for(var r=-1,o=null==e?0:e.length,n=Array(o);++r<o;)n[r]=t(e[r],r,e);return n};var jr=function(e,t,r,o){for(var n=e.length,i=r+(o?1:-1);o?i--:++i<n;)if(t(e[i],i,e))return i;return-1};var Ar=function(e){return e!=e};var _r=function(e,t,r){for(var o=r-1,n=e.length;++o<n;)if(e[o]===t)return o;return-1};var Or=function(e,t,r){return t==t?_r(e,t,r):jr(e,Ar,r)};var Sr=function(e,t,r,o){for(var n=r-1,i=e.length;++n<i;)if(o(e[n],t))return n;return-1},kr=Array.prototype.splice;var Er=function(e,t,r,o){var n=o?Sr:Or,i=-1,l=t.length,a=e;for(e===t&&(t=ct(t)),r&&(a=yr(e,ze(r)));++i<l;)for(var c=0,s=t[i],m=r?r(s):s;(c=n(a,m,c,o))>-1;)a!==e&&kr.call(a,c,1),kr.call(e,c,1);return e};var $r=wr((function(e,t){return e&&e.length&&t&&t.length?Er(e,t):e})),Cr=Function.prototype,Ir=Object.prototype,Pr=Cr.toString,Fr=Ir.hasOwnProperty,xr=Pr.call(Object);var Tr=function(e){if(!$e(e)||"[object Object]"!=T(e))return!1;var t=pt(e);if(null===t)return!0;var r=Fr.call(t,"constructor")&&t.constructor;return"function"==typeof r&&r instanceof r&&Pr.call(r)==xr};r(14);class Br extends o.Plugin{constructor(e){super(e),this._dataSchema=e.plugins.get("DataSchema"),this._allowedAttributes=new c.Matcher,this._disallowedAttributes=new c.Matcher,this._allowedElements=new Set,this._dataInitialized=!1,this._registerElementsAfterInit(),this._registerElementHandlers()}static get pluginName(){return"DataFilter"}static get requires(){return[a,s.Widget]}loadAllowedConfig(e){this._loadConfig(e,e=>this.allowAttributes(e))}loadDisallowedConfig(e){this._loadConfig(e,e=>this.disallowAttributes(e))}allowElement(e){for(const t of this._dataSchema.getDefinitionsForView(e,!0))this._allowedElements.has(t)||(this._allowedElements.add(t),this._dataInitialized&&this._fireRegisterEvent(t))}allowAttributes(e){this._allowedAttributes.add(e)}disallowAttributes(e){this._disallowedAttributes.add(e)}_loadConfig(e,t){for(const r of e){const e=r.name||/[\s\S]+/;this.allowElement(e),Lr(r).forEach(t)}}_consumeAllowedAttributes(e,t){return Rr(e,t,this._disallowedAttributes),Rr(e,t,this._allowedAttributes)}_registerElementsAfterInit(){this.editor.data.on("init",()=>{this._dataInitialized=!0;for(const e of this._allowedElements)this._fireRegisterEvent(e)},{priority:n.priorities.get("high")+1})}_registerElementHandlers(){this.on("register",(e,t)=>{const r=this.editor.model.schema;if(t.isObject&&!r.isRegistered(t.model))this._registerObjectElement(t);else if(t.isBlock)this._registerBlockElement(t);else{if(!t.isInline)throw new n.CKEditorError("data-filter-invalid-definition",null,t);this._registerInlineElement(t)}e.stop()},{priority:"lowest"})}_fireRegisterEvent(e){this.fire(e.view?"register:"+e.view:"register",e)}_registerObjectElement(e){const t=this.editor,r=t.model.schema,o=t.conversion,{view:i,model:l}=e;r.register(l,e.modelSchema),i&&(r.extend(e.model,{allowAttributes:["htmlAttributes","htmlContent"]}),t.data.registerRawContentMatcher({name:i}),o.for("upcast").elementToElement({view:i,model:ir(e),converterPriority:n.priorities.get("low")+1}),o.for("upcast").add(sr(e,this)),o.for("editingDowncast").elementToElement({model:l,view:lr(t,e)}),o.for("dataDowncast").elementToElement({model:l,view:(e,{writer:t})=>ar(i,e,t)}),o.for("dataDowncast").add(mr(e)))}_registerBlockElement(e){const t=this.editor,r=t.model.schema,o=t.conversion,{view:i,model:l}=e;if(!r.isRegistered(e.model)){if(r.register(e.model,e.modelSchema),!i)return;o.for("upcast").elementToElement({model:l,view:i,converterPriority:n.priorities.get("low")+1}),o.for("downcast").elementToElement({model:l,view:i})}i&&(r.extend(e.model,{allowAttributes:"htmlAttributes"}),o.for("upcast").add(sr(e,this)),o.for("downcast").add(mr(e)))}_registerInlineElement(e){const t=this.editor,r=t.model.schema,o=t.conversion,n=e.model;r.extend("$text",{allowAttributes:n}),e.attributeProperties&&r.setAttributeProperties(n,e.attributeProperties),o.for("upcast").add(function({view:e,model:t},r){return o=>{o.on("element:"+e,(e,o,n)=>{const i=r._consumeAllowedAttributes(o.viewItem,n);o.modelRange||(o=Object.assign(o,n.convertChildren(o.viewItem,o.modelCursor)));for(const e of o.modelRange.getItems())if(n.schema.checkAttribute(e,t)){const r=nr(i||{},e.getAttribute(t)||{});n.writer.setAttribute(t,r,e)}},{priority:"low"})}}(e,this)),o.for("downcast").attributeToElement({model:n,view:cr(e)})}}function Rr(e,t,r){const o=function(e,{consumable:t},r){const o=r.matchAll(e)||[],n=[];for(const r of o)Mr(t,e,r),delete r.match.name,t.consume(e,r.match)&&n.push(r);return n}(e,t,r),{attributes:n,styles:i,classes:l}=function(e){const t={attributes:new Set,classes:new Set,styles:new Set};for(const r of e)for(const e in t){(r.match[e]||[]).forEach(r=>t[e].add(r))}return t}(o),a={};return n.size&&(a.attributes=Dr(n,t=>e.getAttribute(t))),i.size&&(a.styles=Dr(i,t=>e.getStyle(t))),l.size&&(a.classes=Array.from(l)),Object.keys(a).length?a:null}function Mr(e,t,r){for(const o of["attributes","classes","styles"]){const n=r.match[o];if(n)for(const r of n)e.test(t,{[o]:[r]})||$r(n,r)}}function Dr(e,t){const r={};for(const o of e){void 0!==t(o)&&(r[o]=t(o))}return r}function Hr(e,t){const{name:r}=e;return Tr(e[t])?Object.entries(e[t]).map(([e,o])=>({name:r,[t]:{[e]:o}})):Array.isArray(e[t])?e[t].map(e=>({name:r,[t]:[e]})):[e]}function Lr(e){const{name:t,attributes:r,classes:o,styles:n}=e,i=[];return r&&i.push(...Hr({name:t,attributes:r},"attributes")),o&&i.push(...Hr({name:t,classes:o},"classes")),n&&i.push(...Hr({name:t,styles:n},"styles")),i}class zr extends o.Plugin{static get requires(){return[Br]}init(){if(!this.editor.plugins.has("CodeBlockEditing"))return;const e=this.editor.plugins.get(Br);e.on("register:pre",(t,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(e){return t=>{t.on("element:code",(t,r,o)=>{const n=r.viewItem,i=n.parent;function l(t,n){const i=e._consumeAllowedAttributes(t,o);i&&o.writer.setAttribute(n,i,r.modelRange)}i&&i.is("element","pre")&&(l(i,"htmlAttributes"),l(n,"htmlContentAttributes"))},{priority:"low"})}}(e)),i.for("downcast").add(e=>{e.on("attribute:htmlAttributes:codeBlock",(e,t,r)=>{if(!r.consumable.consume(t.item,e.name))return;const o=r.mapper.toViewElement(t.item).parent;or(r.writer,t.attributeNewValue,o)}),e.on("attribute:htmlContentAttributes:codeBlock",(e,t,r)=>{if(!r.consumable.consume(t.item,e.name))return;const o=r.mapper.toViewElement(t.item);or(r.writer,t.attributeNewValue,o)})}),t.stop()})}}class Nr extends o.Plugin{static get requires(){return[Br]}init(){this.editor.plugins.get(Br).on("register",(e,t)=>{const r=this.editor,o=r.model.schema,i=r.conversion;if(!t.paragraphLikeModel)return;if(o.isRegistered(t.model)||o.isRegistered(t.paragraphLikeModel))return;const l={model:t.paragraphLikeModel,view:t.view};o.register(t.model,t.modelSchema),o.register(l.model,{inheritAllFrom:"$block"}),i.for("upcast").elementToElement({view:t.view,model:(e,{writer:r})=>this._hasBlockContent(e)?r.createElement(t.model):r.createElement(l.model),converterPriority:n.priorities.get("low")+1}),i.for("downcast").elementToElement({view:t.view,model:t.model}),this._addAttributeConversion(t),i.for("downcast").elementToElement({view:l.view,model:l.model}),this._addAttributeConversion(l),e.stop()})}_hasBlockContent(e){const t=this.editor.editing.view.domConverter.blockElements;return Array.from(e.getChildren()).some(e=>t.includes(e.name))}_addAttributeConversion(e){const t=this.editor,r=t.conversion,o=t.plugins.get(Br);t.model.schema.extend(e.model,{allowAttributes:"htmlAttributes"}),r.for("upcast").add(sr(e,o)),r.for("downcast").add(mr(e))}}class Vr extends o.Plugin{static get requires(){return[Br]}init(){const e=this.editor;if(!e.plugins.has("ImageInlineEditing")&&!e.plugins.has("ImageBlockEditing"))return;const t=e.model.schema,r=e.conversion,o=e.plugins.get(Br);o.on("register:img",(e,n)=>{"imageBlock"!==n.model&&"imageInline"!==n.model||(t.isRegistered("imageBlock")&&t.extend("imageBlock",{allowAttributes:["htmlAttributes","htmlFigureAttributes","htmlLinkAttributes"]}),t.isRegistered("imageInline")&&t.extend("imageInline",{allowAttributes:["htmlA","htmlAttributes"]}),r.for("upcast").add(function(e){return t=>{t.on("element:img",(t,r,o)=>{const n=r.viewItem,i=n.parent;function l(t,n){const i=e._consumeAllowedAttributes(t,o);i&&o.writer.setAttribute(n,i,r.modelRange)}l(n,"htmlAttributes"),i.is("element","figure")?l(i,"htmlFigureAttributes"):i.is("element","a")&&function(e){r.modelRange&&r.modelRange.getContainedElement().is("element","imageBlock")&&l(e,"htmlLinkAttributes");e.parent.is("element","figure")&&l(e.parent,"htmlFigureAttributes")}(i)},{priority:"low"})}}(o)),r.for("downcast").add(e=>{var t;function r(t,r){e.on(`attribute:${r}:imageBlock`,(e,r,o)=>{if(!o.consumable.consume(r.item,e.name))return;const n=o.mapper.toViewElement(r.item),i=Ur(o.writer,n,t);or(o.writer,r.attributeNewValue,i)},{priority:"low"})}t="htmlAttributes",e.on(`attribute:${t}:imageInline`,(e,t,r)=>{if(!r.consumable.consume(t.item,e.name))return;const o=r.mapper.toViewElement(t.item);or(r.writer,t.attributeNewValue,o)},{priority:"low"}),r("img","htmlAttributes"),r("figure","htmlFigureAttributes"),e.on("attribute:linkHref:imageBlock",(e,t,r)=>{if(!r.consumable.consume(t.item,"attribute:htmlLinkAttributes:imageBlock"))return;const o=r.mapper.toViewElement(t.item),n=Ur(r.writer,o,"a");or(r.writer,t.item.getAttribute("htmlLinkAttributes"),n)},{priority:"low"})}),e.stop())})}}function Ur(e,t,r){const o=e.createRangeOn(t);for(const{item:e}of o.getWalker())if(e.is("element",r))return e}class Wr extends o.Plugin{static get requires(){return[Br]}init(){const e=this.editor;if(!e.plugins.has("MediaEmbed")||e.config.get("mediaEmbed.previewsInData"))return;const t=e.model.schema,r=e.conversion,o=this.editor.plugins.get(Br),n=this.editor.plugins.get(a),i=e.config.get("mediaEmbed.elementName");n.registerBlockElement({model:"media",view:i}),o.on("register:"+i,(e,n)=>{"media"===n.model&&(t.extend("media",{allowAttributes:["htmlAttributes","htmlFigureAttributes"]}),r.for("upcast").add(function(e,t){return e=>{e.on("element:"+t,r)};function r(t,r,o){const n=r.viewItem,i=n.parent;function l(t,n){const i=e._consumeAllowedAttributes(t,o);i&&o.writer.setAttribute(n,i,r.modelRange)}l(n,"htmlAttributes"),i.is("element","figure")&&i.hasClass("media")&&l(i,"htmlFigureAttributes")}}(o,i)),r.for("dataDowncast").add(function(e){return t=>{function r(e,r){t.on(`attribute:${r}:media`,(t,r,o)=>{if(!o.consumable.consume(r.item,t.name))return;const n=o.mapper.toViewElement(r.item),i=function(e,t,r){const o=e.createRangeOn(t);for(const{item:e}of o.getWalker())if(e.is("element",r))return e}(o.writer,n,e);or(o.writer,r.attributeNewValue,i)})}r(e,"htmlAttributes"),r("figure","htmlFigureAttributes")}}(i)),e.stop())})}}class qr extends o.Plugin{static get requires(){return[Br]}init(){const e=this.editor;if(!e.plugins.has("TableEditing"))return;const t=e.model.schema,r=e.conversion,o=e.plugins.get(Br);o.on("register:table",(e,n)=>{"table"===n.model&&(t.extend("table",{allowAttributes:["htmlAttributes","htmlFigureAttributes","htmlTheadAttributes","htmlTbodyAttributes"]}),r.for("upcast").add(function(e){return t=>{t.on("element:table",(t,r,o)=>{const n=r.viewItem;l(n,"htmlAttributes");const i=n.parent;i.is("element","figure")&&l(i,"htmlFigureAttributes");for(const e of n.getChildren())e.is("element","thead")&&l(e,"htmlTheadAttributes"),e.is("element","tbody")&&l(e,"htmlTbodyAttributes");function l(t,n){const i=e._consumeAllowedAttributes(t,o);i&&o.writer.setAttribute(n,i,r.modelRange)}},{priority:"low"})}}(o)),r.for("downcast").add(e=>{function t(t,r){e.on(`attribute:${r}:table`,(e,r,o)=>{if(!o.consumable.consume(r.item,e.name))return;const n=o.mapper.toViewElement(r.item),i=function(e,t,r){const o=e.createRangeOn(t);for(const{item:e}of o.getWalker())if(e.is("element",r))return e}(o.writer,n,t);or(o.writer,r.attributeNewValue,i)})}t("table","htmlAttributes"),t("figure","htmlFigureAttributes"),t("thead","htmlTheadAttributes"),t("tbody","htmlTbodyAttributes")}),e.stop())})}}class Kr extends o.Plugin{static get pluginName(){return"GeneralHtmlSupport"}static get requires(){return[Br,zr,Nr,Vr,Wr,qr]}init(){const e=this.editor,t=e.plugins.get(Br);t.loadAllowedConfig(e.config.get("htmlSupport.allow")||[]),t.loadDisallowedConfig(e.config.get("htmlSupport.disallow")||[])}}class Gr extends o.Plugin{static get pluginName(){return"HtmlComment"}init(){const e=this.editor;e.model.schema.addAttributeCheck((e,t)=>{if(e.endsWith("$root")&&t.startsWith("$comment"))return!0}),e.conversion.for("upcast").elementToMarker({view:"$comment",model:(e,{writer:t})=>{const r=this.editor.model.document.getRoot(),o=e.getCustomProperty("$rawContent"),i="$comment:"+Object(n.uid)();return t.setAttribute(i,o,r),i}}),e.conversion.for("dataDowncast").markerToElement({model:"$comment",view:(e,{writer:t})=>{const r=this.editor.model.document.getRoot(),o=e.markerName,n=r.getAttribute(o),i=t.createUIElement("$comment");return t.setCustomProperty("$rawContent",n,i),i}}),e.model.document.registerPostFixer(t=>{const r=e.model.document.getRoot(),o=e.model.document.differ.getChangedMarkers().filter(e=>e.name.startsWith("$comment")).filter(e=>{const t=e.data.newRange;return t&&"$graveyard"===t.root.rootName});if(0===o.length)return!1;for(const e of o)t.removeMarker(e.name),t.removeAttribute(e.name,r);return!0}),e.data.on("set",()=>{for(const t of e.model.markers.getMarkersGroup("$comment"))this.removeHtmlComment(t.name)},{priority:"high"}),e.model.on("deleteContent",(t,[r])=>{for(const t of r.getRanges()){const r=e.model.schema.getLimitElement(t),o=e.model.createPositionAt(r,0),n=e.model.createPositionAt(r,"end");let i;i=o.isTouching(t.start)&&n.isTouching(t.end)?this.getHtmlCommentsInRange(e.model.createRange(o,n)):this.getHtmlCommentsInRange(t,{skipBoundaries:!0});for(const e of i)this.removeHtmlComment(e)}},{priority:"high"})}createHtmlComment(e,t){const r=Object(n.uid)(),o=this.editor.model,i=o.document.getRoot(),l="$comment:"+r;return o.change(r=>{const o=r.createRange(e);return r.addMarker(l,{usingOperation:!0,affectsData:!0,range:o}),r.setAttribute(l,t,i),l})}removeHtmlComment(e){const t=this.editor,r=t.model.document.getRoot(),o=t.model.markers.get(e);return!!o&&(t.model.change(t=>{t.removeMarker(o),t.removeAttribute(e,r)}),!0)}getHtmlCommentData(e){const t=this.editor,r=t.model.markers.get(e),o=t.model.document.getRoot();return r?{content:o.getAttribute(e),position:r.getStart()}:null}getHtmlCommentsInRange(e,{skipBoundaries:t=!1}={}){const r=!t;return Array.from(this.editor.model.markers.getMarkersGroup("$comment")).filter(t=>function(e,t){const o=e.getRange().start;return(o.isAfter(t.start)||r&&o.isEqual(t.start))&&(o.isBefore(t.end)||r&&o.isEqual(t.end))}(t,e)).map(e=>e.name)}}}]);
!function(e){const t=e.en=e.en||{};t.dictionary=Object.assign(t.dictionary||{},{"HTML object":"HTML object"})}(window.CKEDITOR_TRANSLATIONS||(window.CKEDITOR_TRANSLATIONS={})),window.CKEditor5=window.CKEditor5||{},window.CKEditor5.htmlSupport=function(e){var t={};function r(n){if(t[n])return t[n].exports;var o=t[n]={i:n,l:!1,exports:{}};return e[n].call(o.exports,o,o.exports,r),o.l=!0,o.exports}return r.m=e,r.c=t,r.d=function(e,t,n){r.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:n})},r.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},r.t=function(e,t){if(1&t&&(e=r(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var n=Object.create(null);if(r.r(n),Object.defineProperty(n,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var o in e)r.d(n,o,function(t){return e[t]}.bind(null,o));return n},r.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return r.d(t,"a",t),t},r.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},r.p="",r(r.s=17)}([function(e,t,r){e.exports=r(5)("./src/core.js")},function(e,t,r){"use strict";var n=r(6),o="object"==typeof self&&self&&self.Object===Object&&self,i=n.a||o||Function("return this")();t.a=i},function(e,t,r){e.exports=r(5)("./src/utils.js")},function(e,t,r){"use strict";(function(e){var n=r(6),o="object"==typeof exports&&exports&&!exports.nodeType&&exports,i=o&&"object"==typeof e&&e&&!e.nodeType&&e,l=i&&i.exports===o&&n.a.process,a=function(){try{var e=i&&i.require&&i.require("util").types;return e||l&&l.binding&&l.binding("util")}catch(e){}}();t.a=a}).call(this,r(9)(e))},function(e,t,r){"use strict";(function(e){var n=r(1),o=r(12),i="object"==typeof exports&&exports&&!exports.nodeType&&exports,l=i&&"object"==typeof e&&e&&!e.nodeType&&e,a=l&&l.exports===i?n.a.Buffer:void 0,c=(a?a.isBuffer:void 0)||o.a;t.a=c}).call(this,r(9)(e))},function(e,t){e.exports=CKEditor5.dll},function(e,t,r){"use strict";(function(e){var r="object"==typeof e&&e&&e.Object===Object&&e;t.a=r}).call(this,r(13))},function(e,t,r){"use strict";(function(e){var n=r(1),o="object"==typeof exports&&exports&&!exports.nodeType&&exports,i=o&&"object"==typeof e&&e&&!e.nodeType&&e,l=i&&i.exports===o?n.a.Buffer:void 0,a=l?l.allocUnsafe:void 0;t.a=function(e,t){if(t)return e.slice();var r=e.length,n=a?a(r):new e.constructor(r);return e.copy(n),n}}).call(this,r(9)(e))},function(e,t,r){e.exports=r(5)("./src/widget.js")},function(e,t){e.exports=function(e){if(!e.webpackPolyfill){var t=Object.create(e);t.children||(t.children=[]),Object.defineProperty(t,"loaded",{enumerable:!0,get:function(){return t.l}}),Object.defineProperty(t,"id",{enumerable:!0,get:function(){return t.i}}),Object.defineProperty(t,"exports",{enumerable:!0}),t.webpackPolyfill=1}return t}},function(e,t,r){e.exports=r(5)("./src/engine.js")},,function(e,t,r){"use strict";t.a=function(){return!1}},function(e,t){var r;r=function(){return this}();try{r=r||new Function("return this")()}catch(e){"object"==typeof window&&(r=window)}e.exports=r},function(e,t,r){var n=r(15),o=r(16);"string"==typeof(o=o.__esModule?o.default:o)&&(o=[[e.i,o,""]]);var i={injectType:"singletonStyleTag",attributes:{"data-cke":!0},insert:"head",singleton:!0};n(o,i);e.exports=o.locals||{}},function(e,t,r){"use strict";var n,o=function(){return void 0===n&&(n=Boolean(window&&document&&document.all&&!window.atob)),n},i=function(){var e={};return function(t){if(void 0===e[t]){var r=document.querySelector(t);if(window.HTMLIFrameElement&&r instanceof window.HTMLIFrameElement)try{r=r.contentDocument.head}catch(e){r=null}e[t]=r}return e[t]}}(),l=[];function a(e){for(var t=-1,r=0;r<l.length;r++)if(l[r].identifier===e){t=r;break}return t}function c(e,t){for(var r={},n=[],o=0;o<e.length;o++){var i=e[o],c=t.base?i[0]+t.base:i[0],s=r[c]||0,m="".concat(c," ").concat(s);r[c]=s+1;var u=a(m),d={css:i[1],media:i[2],sourceMap:i[3]};-1!==u?(l[u].references++,l[u].updater(d)):l.push({identifier:m,updater:p(d,t),references:1}),n.push(m)}return n}function s(e){var t=document.createElement("style"),n=e.attributes||{};if(void 0===n.nonce){var o=r.nc;o&&(n.nonce=o)}if(Object.keys(n).forEach((function(e){t.setAttribute(e,n[e])})),"function"==typeof e.insert)e.insert(t);else{var l=i(e.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(t)}return t}var m,u=(m=[],function(e,t){return m[e]=t,m.filter(Boolean).join("\n")});function d(e,t,r,n){var o=r?"":n.media?"@media ".concat(n.media," {").concat(n.css,"}"):n.css;if(e.styleSheet)e.styleSheet.cssText=u(t,o);else{var i=document.createTextNode(o),l=e.childNodes;l[t]&&e.removeChild(l[t]),l.length?e.insertBefore(i,l[t]):e.appendChild(i)}}function h(e,t,r){var n=r.css,o=r.media,i=r.sourceMap;if(o?e.setAttribute("media",o):e.removeAttribute("media"),i&&"undefined"!=typeof btoa&&(n+="\n/*# sourceMappingURL=data:application/json;base64,".concat(btoa(unescape(encodeURIComponent(JSON.stringify(i))))," */")),e.styleSheet)e.styleSheet.cssText=n;else{for(;e.firstChild;)e.removeChild(e.firstChild);e.appendChild(document.createTextNode(n))}}var f=null,b=0;function p(e,t){var r,n,o;if(t.singleton){var i=b++;r=f||(f=s(t)),n=d.bind(null,r,i,!1),o=d.bind(null,r,i,!0)}else r=s(t),n=h.bind(null,r,t),o=function(){!function(e){if(null===e.parentNode)return!1;e.parentNode.removeChild(e)}(r)};return n(e),function(t){if(t){if(t.css===e.css&&t.media===e.media&&t.sourceMap===e.sourceMap)return;n(e=t)}else o()}}e.exports=function(e,t){(t=t||{}).singleton||"boolean"==typeof t.singleton||(t.singleton=o());var r=c(e=e||[],t);return function(e){if(e=e||[],"[object Array]"===Object.prototype.toString.call(e)){for(var n=0;n<r.length;n++){var o=a(r[n]);l[o].references--}for(var i=c(e,t),s=0;s<r.length;s++){var m=a(r[s]);0===l[m].references&&(l[m].updater(),l.splice(m,1))}r=i}}}},function(e,t){e.exports=":root{--ck-html-object-embed-unfocused-outline-width:1px}.ck-widget.html-object-embed{font-size:var(--ck-font-size-base);background-color:var(--ck-color-base-foreground);padding:var(--ck-spacing-small);padding-top:calc(var(--ck-font-size-tiny) + var(--ck-spacing-large));min-width:calc(76px + var(--ck-spacing-standard))}.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{font-weight:400;font-style:normal;position:absolute;content:attr(data-html-object-embed-label);top:0;left:var(--ck-spacing-standard);background:#999;transition:background var(--ck-widget-handler-animation-duration) var(--ck-widget-handler-animation-curve);padding:calc(var(--ck-spacing-tiny) + var(--ck-html-object-embed-unfocused-outline-width)) var(--ck-spacing-small) var(--ck-spacing-tiny);border-radius:0 0 var(--ck-border-radius) var(--ck-border-radius);color:var(--ck-color-base-background);font-size:var(--ck-font-size-tiny);font-family:var(--ck-font-face)}.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}"},function(e,t,r){"use strict";r.r(t),r.d(t,"GeneralHtmlSupport",(function(){return nn})),r.d(t,"DataFilter",(function(){return Ur})),r.d(t,"DataSchema",(function(){return It})),r.d(t,"HtmlComment",(function(){return on}));var n=r(0),o=r(2),i=[{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:"$htmlSection",modelSchema:{allowChildren:"$block",allowIn:["$root","$htmlSection"],isBlock:!0}},{model:"htmlP",view:"p",modelSchema:{inheritAllFrom:"$block"}},{model:"htmlBlockquote",view:"blockquote",modelSchema:{inheritAllFrom:"$htmlSection"}},{model:"htmlTable",view:"table",modelSchema:{allowIn:["$htmlSection","$root"],isBlock:!0}},{model:"htmlTbody",view:"tbody",modelSchema:{allowIn:"htmlTable",isBlock:!0}},{model:"htmlThead",view:"thead",modelSchema:{allowIn:"htmlTable",isBlock:!0}},{model:"htmlTfoot",view:"tfoot",modelSchema:{allowIn:"htmlTable",isBlock:!0}},{model:"htmlCaption",view:"caption",modelSchema:{allowIn:"htmlTable",allowChildren:"$text",isBlock:!0}},{model:"htmlTr",view:"tr",modelSchema:{allowIn:["htmlTable","htmlThead","htmlTbody"],isBlock:!0}},{model:"htmlTd",view:"td",modelSchema:{allowIn:"htmlTr",allowChildren:["$block","$htmlSection"],isBlock:!0}},{model:"htmlTh",view:"th",modelSchema:{allowIn:"htmlTr",allowChildren:["$block","$htmlSection"],isBlock:!0}},{model:"htmlFigure",view:"figure",modelSchema:{inheritAllFrom:"$htmlSection",isBlock:!0}},{model:"htmlFigcaption",view:"figcaption",modelSchema:{allowIn:"htmlFigure",allowChildren:"$text",isBlock:!0}},{model:"htmlAddress",view:"address",modelSchema:{inheritAllFrom:"$htmlSection"}},{model:"htmlAside",view:"aside",modelSchema:{inheritAllFrom:"$htmlSection"}},{model:"htmlMain",view:"main",modelSchema:{inheritAllFrom:"$htmlSection"}},{model:"htmlDetails",view:"details",modelSchema:{inheritAllFrom:"$htmlSection"}},{model:"htmlSummary",view:"summary",modelSchema:{allowChildren:"$text",allowIn:"htmlDetails",isBlock:!0}},{model:"htmlDiv",view:"div",paragraphLikeModel:"htmlDivParagraph",modelSchema:{inheritAllFrom:"$htmlSection"}},{model:"htmlFieldset",view:"fieldset",modelSchema:{inheritAllFrom:"$htmlSection"}},{model:"htmlLegend",view:"legend",modelSchema:{allowIn:"htmlFieldset",allowChildren:"$text"}},{model:"htmlHeader",view:"header",modelSchema:{inheritAllFrom:"$htmlSection"}},{model:"htmlFooter",view:"footer",modelSchema:{inheritAllFrom:"$htmlSection"}},{model:"htmlForm",view:"form",modelSchema:{inheritAllFrom:"$htmlSection"}},{model:"htmlHgroup",view:"hgroup",modelSchema:{allowChildren:["htmlH1","htmlH2","htmlH3","htmlH4","htmlH5","htmlH6"],isBlock:!0}},{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:"$htmlSection",allowChildren:["$htmlList","htmlLi"],isBlock:!0}},{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:!0}},{model:"htmlPre",view:"pre",modelSchema:{inheritAllFrom:"$block"}},{model:"htmlArticle",view:"article",modelSchema:{inheritAllFrom:"$htmlSection"}},{model:"htmlSection",view:"section",modelSchema:{inheritAllFrom:"$htmlSection"}},{model:"htmlNav",view:"nav",modelSchema:{inheritAllFrom:"$htmlSection"}},{model:"htmlDl",view:"dl",modelSchema:{allowIn:["$htmlSection","$root"],allowChildren:["htmlDt","htmlDd"],isBlock:!0}},{model:"htmlDt",view:"dt",modelSchema:{allowChildren:"$block",isBlock:!0}},{model:"htmlDd",view:"dd",modelSchema:{allowChildren:"$block",isBlock:!0}},{model:"htmlCenter",view:"center",modelSchema:{inheritAllFrom:"$htmlSection"}},{model:"$htmlObjectBlock",isObject:!0,modelSchema:{isObject:!0,isBlock:!0,allowWhere:"$block"}}],l=[{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,attributeProperties:{copyOnEnter:!0}},{model:"htmlStrong",view:"strong",attributeProperties:{copyOnEnter:!0}},{model:"htmlB",view:"b",attributeProperties:{copyOnEnter:!0}},{model:"htmlI",view:"i",attributeProperties:{copyOnEnter:!0}},{model:"htmlEm",view:"em",attributeProperties:{copyOnEnter:!0}},{model:"htmlS",view:"s",attributeProperties:{copyOnEnter:!0}},{model:"htmlDel",view:"del",attributeProperties:{copyOnEnter:!0}},{model:"htmlIns",view:"ins",attributeProperties:{copyOnEnter:!0}},{model:"htmlU",view:"u",attributeProperties:{copyOnEnter:!0}},{model:"htmlSub",view:"sub",attributeProperties:{copyOnEnter:!0}},{model:"htmlSup",view:"sup",attributeProperties:{copyOnEnter:!0}},{model:"htmlCode",view:"code",attributeProperties:{copyOnEnter:!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:"$htmlObjectInline",isObject:!0,modelSchema:{isObject:!0,isInline:!0,allowWhere:"$text",allowAttributesOf:"$text"}},{model:"htmlObject",view:"object",isObject:!0,modelSchema:{inheritAllFrom:"$htmlObjectInline"}},{model:"htmlIframe",view:"iframe",isObject:!0,modelSchema:{inheritAllFrom:"$htmlObjectInline"}},{model:"htmlInput",view:"input",isObject:!0,modelSchema:{inheritAllFrom:"$htmlObjectInline"}},{model:"htmlButton",view:"button",isObject:!0,modelSchema:{inheritAllFrom:"$htmlObjectInline"}},{model:"htmlTextarea",view:"textarea",isObject:!0,modelSchema:{inheritAllFrom:"$htmlObjectInline"}},{model:"htmlSelect",view:"select",isObject:!0,modelSchema:{inheritAllFrom:"$htmlObjectInline"}},{model:"htmlVideo",view:"video",isObject:!0,modelSchema:{inheritAllFrom:"$htmlObjectInline"}},{model:"htmlEmbed",view:"embed",isObject:!0,modelSchema:{inheritAllFrom:"$htmlObjectInline"}},{model:"htmlOembed",view:"oembed",isObject:!0,modelSchema:{inheritAllFrom:"$htmlObjectInline"}},{model:"htmlAudio",view:"audio",isObject:!0,modelSchema:{inheritAllFrom:"$htmlObjectInline"}},{model:"htmlImg",view:"img",isObject:!0,modelSchema:{inheritAllFrom:"$htmlObjectInline"}},{model:"htmlCanvas",view:"canvas",isObject:!0,modelSchema:{inheritAllFrom:"$htmlObjectInline"}},{model:"htmlMeter",view:"meter",isObject:!0,modelSchema:{inheritAllFrom:"$htmlObjectInline"}},{model:"htmlProgress",view:"progress",isObject:!0,modelSchema:{inheritAllFrom:"$htmlObjectInline"}}];var a=function(){this.__data__=[],this.size=0};var c=function(e,t){return e===t||e!=e&&t!=t};var s=function(e,t){for(var r=e.length;r--;)if(c(e[r][0],t))return r;return-1},m=Array.prototype.splice;var u=function(e){var t=this.__data__,r=s(t,e);return!(r<0)&&(r==t.length-1?t.pop():m.call(t,r,1),--this.size,!0)};var d=function(e){var t=this.__data__,r=s(t,e);return r<0?void 0:t[r][1]};var h=function(e){return s(this.__data__,e)>-1};var f=function(e,t){var r=this.__data__,n=s(r,e);return n<0?(++this.size,r.push([e,t])):r[n][1]=t,this};function b(e){var t=-1,r=null==e?0:e.length;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}b.prototype.clear=a,b.prototype.delete=u,b.prototype.get=d,b.prototype.has=h,b.prototype.set=f;var p=b;var v=function(){this.__data__=new p,this.size=0};var g=function(e){var t=this.__data__,r=t.delete(e);return this.size=t.size,r};var w=function(e){return this.__data__.get(e)};var y=function(e){return this.__data__.has(e)},j=r(1),A=j.a.Symbol,_=Object.prototype,O=_.hasOwnProperty,S=_.toString,k=A?A.toStringTag:void 0;var E=function(e){var t=O.call(e,k),r=e[k];try{e[k]=void 0;var n=!0}catch(e){}var o=S.call(e);return n&&(t?e[k]=r:delete e[k]),o},$=Object.prototype.toString;var C=function(e){return $.call(e)},I=A?A.toStringTag:void 0;var P=function(e){return null==e?void 0===e?"[object Undefined]":"[object Null]":I&&I in Object(e)?E(e):C(e)};var x=function(e){var t=typeof e;return null!=e&&("object"==t||"function"==t)};var F,B=function(e){if(!x(e))return!1;var t=P(e);return"[object Function]"==t||"[object GeneratorFunction]"==t||"[object AsyncFunction]"==t||"[object Proxy]"==t},T=j.a["__core-js_shared__"],R=(F=/[^.]+$/.exec(T&&T.keys&&T.keys.IE_PROTO||""))?"Symbol(src)_1."+F:"";var M=function(e){return!!R&&R in e},D=Function.prototype.toString;var H=function(e){if(null!=e){try{return D.call(e)}catch(e){}try{return e+""}catch(e){}}return""},L=/^\[object .+?Constructor\]$/,z=Function.prototype,N=Object.prototype,V=z.toString,U=N.hasOwnProperty,q=RegExp("^"+V.call(U).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");var W=function(e){return!(!x(e)||M(e))&&(B(e)?q:L).test(H(e))};var K=function(e,t){return null==e?void 0:e[t]};var G=function(e,t){var r=K(e,t);return W(r)?r:void 0},Q=G(j.a,"Map"),J=G(Object,"create");var X=function(){this.__data__=J?J(null):{},this.size=0};var Y=function(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t},Z=Object.prototype.hasOwnProperty;var ee=function(e){var t=this.__data__;if(J){var r=t[e];return"__lodash_hash_undefined__"===r?void 0:r}return Z.call(t,e)?t[e]:void 0},te=Object.prototype.hasOwnProperty;var re=function(e){var t=this.__data__;return J?void 0!==t[e]:te.call(t,e)};var ne=function(e,t){var r=this.__data__;return this.size+=this.has(e)?0:1,r[e]=J&&void 0===t?"__lodash_hash_undefined__":t,this};function oe(e){var t=-1,r=null==e?0:e.length;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}oe.prototype.clear=X,oe.prototype.delete=Y,oe.prototype.get=ee,oe.prototype.has=re,oe.prototype.set=ne;var ie=oe;var le=function(){this.size=0,this.__data__={hash:new ie,map:new(Q||p),string:new ie}};var ae=function(e){var t=typeof e;return"string"==t||"number"==t||"symbol"==t||"boolean"==t?"__proto__"!==e:null===e};var ce=function(e,t){var r=e.__data__;return ae(t)?r["string"==typeof t?"string":"hash"]:r.map};var se=function(e){var t=ce(this,e).delete(e);return this.size-=t?1:0,t};var me=function(e){return ce(this,e).get(e)};var ue=function(e){return ce(this,e).has(e)};var de=function(e,t){var r=ce(this,e),n=r.size;return r.set(e,t),this.size+=r.size==n?0:1,this};function he(e){var t=-1,r=null==e?0:e.length;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}he.prototype.clear=le,he.prototype.delete=se,he.prototype.get=me,he.prototype.has=ue,he.prototype.set=de;var fe=he;var be=function(e,t){var r=this.__data__;if(r instanceof p){var n=r.__data__;if(!Q||n.length<199)return n.push([e,t]),this.size=++r.size,this;r=this.__data__=new fe(n)}return r.set(e,t),this.size=r.size,this};function pe(e){var t=this.__data__=new p(e);this.size=t.size}pe.prototype.clear=v,pe.prototype.delete=g,pe.prototype.get=w,pe.prototype.has=y,pe.prototype.set=be;var ve=pe,ge=function(){try{var e=G(Object,"defineProperty");return e({},"",{}),e}catch(e){}}();var we=function(e,t,r){"__proto__"==t&&ge?ge(e,t,{configurable:!0,enumerable:!0,value:r,writable:!0}):e[t]=r};var ye=function(e,t,r){(void 0!==r&&!c(e[t],r)||void 0===r&&!(t in e))&&we(e,t,r)};var je=function(e){return function(t,r,n){for(var o=-1,i=Object(t),l=n(t),a=l.length;a--;){var c=l[e?a:++o];if(!1===r(i[c],c,i))break}return t}}(),Ae=r(7),_e=j.a.Uint8Array;var Oe=function(e){var t=new e.constructor(e.byteLength);return new _e(t).set(new _e(e)),t};var Se=function(e,t){var r=t?Oe(e.buffer):e.buffer;return new e.constructor(r,e.byteOffset,e.length)};var ke=function(e,t){var r=-1,n=e.length;for(t||(t=Array(n));++r<n;)t[r]=e[r];return t},Ee=Object.create,$e=function(){function e(){}return function(t){if(!x(t))return{};if(Ee)return Ee(t);e.prototype=t;var r=new e;return e.prototype=void 0,r}}();var Ce=function(e,t){return function(r){return e(t(r))}},Ie=Ce(Object.getPrototypeOf,Object),Pe=Object.prototype;var xe=function(e){var t=e&&e.constructor;return e===("function"==typeof t&&t.prototype||Pe)};var Fe=function(e){return"function"!=typeof e.constructor||xe(e)?{}:$e(Ie(e))};var Be=function(e){return null!=e&&"object"==typeof e};var Te=function(e){return Be(e)&&"[object Arguments]"==P(e)},Re=Object.prototype,Me=Re.hasOwnProperty,De=Re.propertyIsEnumerable,He=Te(function(){return arguments}())?Te:function(e){return Be(e)&&Me.call(e,"callee")&&!De.call(e,"callee")},Le=Array.isArray;var ze=function(e){return"number"==typeof e&&e>-1&&e%1==0&&e<=9007199254740991};var Ne=function(e){return null!=e&&ze(e.length)&&!B(e)};var Ve=function(e){return Be(e)&&Ne(e)},Ue=r(4),qe=Function.prototype,We=Object.prototype,Ke=qe.toString,Ge=We.hasOwnProperty,Qe=Ke.call(Object);var Je=function(e){if(!Be(e)||"[object Object]"!=P(e))return!1;var t=Ie(e);if(null===t)return!0;var r=Ge.call(t,"constructor")&&t.constructor;return"function"==typeof r&&r instanceof r&&Ke.call(r)==Qe},Xe={};Xe["[object Float32Array]"]=Xe["[object Float64Array]"]=Xe["[object Int8Array]"]=Xe["[object Int16Array]"]=Xe["[object Int32Array]"]=Xe["[object Uint8Array]"]=Xe["[object Uint8ClampedArray]"]=Xe["[object Uint16Array]"]=Xe["[object Uint32Array]"]=!0,Xe["[object Arguments]"]=Xe["[object Array]"]=Xe["[object ArrayBuffer]"]=Xe["[object Boolean]"]=Xe["[object DataView]"]=Xe["[object Date]"]=Xe["[object Error]"]=Xe["[object Function]"]=Xe["[object Map]"]=Xe["[object Number]"]=Xe["[object Object]"]=Xe["[object RegExp]"]=Xe["[object Set]"]=Xe["[object String]"]=Xe["[object WeakMap]"]=!1;var Ye=function(e){return Be(e)&&ze(e.length)&&!!Xe[P(e)]};var Ze=function(e){return function(t){return e(t)}},et=r(3),tt=et.a&&et.a.isTypedArray,rt=tt?Ze(tt):Ye;var nt=function(e,t){if(("constructor"!==t||"function"!=typeof e[t])&&"__proto__"!=t)return e[t]},ot=Object.prototype.hasOwnProperty;var it=function(e,t,r){var n=e[t];ot.call(e,t)&&c(n,r)&&(void 0!==r||t in e)||we(e,t,r)};var lt=function(e,t,r,n){var o=!r;r||(r={});for(var i=-1,l=t.length;++i<l;){var a=t[i],c=n?n(r[a],e[a],a,r,e):void 0;void 0===c&&(c=e[a]),o?we(r,a,c):it(r,a,c)}return r};var at=function(e,t){for(var r=-1,n=Array(e);++r<e;)n[r]=t(r);return n},ct=/^(?:0|[1-9]\d*)$/;var st=function(e,t){var r=typeof e;return!!(t=null==t?9007199254740991:t)&&("number"==r||"symbol"!=r&&ct.test(e))&&e>-1&&e%1==0&&e<t},mt=Object.prototype.hasOwnProperty;var ut=function(e,t){var r=Le(e),n=!r&&He(e),o=!r&&!n&&Object(Ue.a)(e),i=!r&&!n&&!o&&rt(e),l=r||n||o||i,a=l?at(e.length,String):[],c=a.length;for(var s in e)!t&&!mt.call(e,s)||l&&("length"==s||o&&("offset"==s||"parent"==s)||i&&("buffer"==s||"byteLength"==s||"byteOffset"==s)||st(s,c))||a.push(s);return a};var dt=function(e){var t=[];if(null!=e)for(var r in Object(e))t.push(r);return t},ht=Object.prototype.hasOwnProperty;var ft=function(e){if(!x(e))return dt(e);var t=xe(e),r=[];for(var n in e)("constructor"!=n||!t&&ht.call(e,n))&&r.push(n);return r};var bt=function(e){return Ne(e)?ut(e,!0):ft(e)};var pt=function(e){return lt(e,bt(e))};var vt=function(e,t,r,n,o,i,l){var a=nt(e,r),c=nt(t,r),s=l.get(c);if(s)ye(e,r,s);else{var m=i?i(a,c,r+"",e,t,l):void 0,u=void 0===m;if(u){var d=Le(c),h=!d&&Object(Ue.a)(c),f=!d&&!h&&rt(c);m=c,d||h||f?Le(a)?m=a:Ve(a)?m=ke(a):h?(u=!1,m=Object(Ae.a)(c,!0)):f?(u=!1,m=Se(c,!0)):m=[]:Je(c)||He(c)?(m=a,He(a)?m=pt(a):x(a)&&!B(a)||(m=Fe(c))):u=!1}u&&(l.set(c,m),o(m,c,n,i,l),l.delete(c)),ye(e,r,m)}};var gt=function e(t,r,n,o,i){t!==r&&je(r,(function(l,a){if(i||(i=new ve),x(l))vt(t,r,a,n,e,o,i);else{var c=o?o(nt(t,a),l,a+"",t,r,i):void 0;void 0===c&&(c=l),ye(t,a,c)}}),bt)};var wt=function(e){return e};var yt=function(e,t,r){switch(r.length){case 0:return e.call(t);case 1:return e.call(t,r[0]);case 2:return e.call(t,r[0],r[1]);case 3:return e.call(t,r[0],r[1],r[2])}return e.apply(t,r)},jt=Math.max;var At=function(e,t,r){return t=jt(void 0===t?e.length-1:t,0),function(){for(var n=arguments,o=-1,i=jt(n.length-t,0),l=Array(i);++o<i;)l[o]=n[t+o];o=-1;for(var a=Array(t+1);++o<t;)a[o]=n[o];return a[t]=r(l),yt(e,this,a)}};var _t=function(e){return function(){return e}},Ot=ge?function(e,t){return ge(e,"toString",{configurable:!0,enumerable:!1,value:_t(t),writable:!0})}:wt,St=Date.now;var kt=function(e){var t=0,r=0;return function(){var n=St(),o=16-(n-r);if(r=n,o>0){if(++t>=800)return arguments[0]}else t=0;return e.apply(void 0,arguments)}}(Ot);var Et=function(e,t){return kt(At(e,t,wt),e+"")};var $t=function(e,t,r){if(!x(r))return!1;var n=typeof t;return!!("number"==n?Ne(r)&&st(t,r.length):"string"==n&&t in r)&&c(r[t],e)};var Ct=function(e){return Et((function(t,r){var n=-1,o=r.length,i=o>1?r[o-1]:void 0,l=o>2?r[2]:void 0;for(i=e.length>3&&"function"==typeof i?(o--,i):void 0,l&&$t(r[0],r[1],l)&&(i=o<3?void 0:i,o=1),t=Object(t);++n<o;){var a=r[n];a&&e(t,a,n,i)}return t}))}((function(e,t,r,n){gt(e,t,r,n)}));class It extends n.Plugin{constructor(e){super(e),this._definitions=new Map}static get pluginName(){return"DataSchema"}init(){for(const e of i)this.registerBlockElement(e);for(const e of l)this.registerInlineElement(e)}registerBlockElement(e){this._definitions.set(e.model,{...e,isBlock:!0})}registerInlineElement(e){this._definitions.set(e.model,{...e,isInline:!0})}extendBlockElement(e){this._extendDefinition({...e,isBlock:!0})}extendInlineElement(e){this._extendDefinition({...e,isInline:!0})}getDefinitionsForView(e,t){const r=new Set;for(const n of this._getMatchingViewDefinitions(e)){if(t)for(const e of this._getReferences(n.model))r.add(e);r.add(n)}return r}_getMatchingViewDefinitions(e){return Array.from(this._definitions.values()).filter(t=>t.view&&function(e,t){if("string"==typeof e)return e===t;if(e instanceof RegExp)return e.test(t);return!1}(e,t.view))}*_getReferences(e){const{modelSchema:t}=this._definitions.get(e);if(!t)return;const r=["inheritAllFrom","inheritTypesFrom","allowWhere","allowContentOf","allowAttributesOf"];for(const n of r)for(const r of Object(o.toArray)(t[n]||[])){const t=this._definitions.get(r);r!==e&&t&&(yield*this._getReferences(t.model),yield t)}}_extendDefinition(e){const t=this._definitions.get(e.model),r=Ct({},t,e,(e,t)=>Array.isArray(e)?e.concat(t):void 0);this._definitions.set(e.model,r)}}var Pt=r(10),xt=r(8);var Ft=function(e,t){for(var r=-1,n=null==e?0:e.length;++r<n&&!1!==t(e[r],r,e););return e},Bt=Ce(Object.keys,Object),Tt=Object.prototype.hasOwnProperty;var Rt=function(e){if(!xe(e))return Bt(e);var t=[];for(var r in Object(e))Tt.call(e,r)&&"constructor"!=r&&t.push(r);return t};var Mt=function(e){return Ne(e)?ut(e):Rt(e)};var Dt=function(e,t){return e&&lt(t,Mt(t),e)};var Ht=function(e,t){return e&&lt(t,bt(t),e)};var Lt=function(e,t){for(var r=-1,n=null==e?0:e.length,o=0,i=[];++r<n;){var l=e[r];t(l,r,e)&&(i[o++]=l)}return i};var zt=function(){return[]},Nt=Object.prototype.propertyIsEnumerable,Vt=Object.getOwnPropertySymbols,Ut=Vt?function(e){return null==e?[]:(e=Object(e),Lt(Vt(e),(function(t){return Nt.call(e,t)})))}:zt;var qt=function(e,t){return lt(e,Ut(e),t)};var Wt=function(e,t){for(var r=-1,n=t.length,o=e.length;++r<n;)e[o+r]=t[r];return e},Kt=Object.getOwnPropertySymbols?function(e){for(var t=[];e;)Wt(t,Ut(e)),e=Ie(e);return t}:zt;var Gt=function(e,t){return lt(e,Kt(e),t)};var Qt=function(e,t,r){var n=t(e);return Le(e)?n:Wt(n,r(e))};var Jt=function(e){return Qt(e,Mt,Ut)};var Xt=function(e){return Qt(e,bt,Kt)},Yt=G(j.a,"DataView"),Zt=G(j.a,"Promise"),er=G(j.a,"Set"),tr=G(j.a,"WeakMap"),rr=H(Yt),nr=H(Q),or=H(Zt),ir=H(er),lr=H(tr),ar=P;(Yt&&"[object DataView]"!=ar(new Yt(new ArrayBuffer(1)))||Q&&"[object Map]"!=ar(new Q)||Zt&&"[object Promise]"!=ar(Zt.resolve())||er&&"[object Set]"!=ar(new er)||tr&&"[object WeakMap]"!=ar(new tr))&&(ar=function(e){var t=P(e),r="[object Object]"==t?e.constructor:void 0,n=r?H(r):"";if(n)switch(n){case rr:return"[object DataView]";case nr:return"[object Map]";case or:return"[object Promise]";case ir:return"[object Set]";case lr:return"[object WeakMap]"}return t});var cr=ar,sr=Object.prototype.hasOwnProperty;var mr=function(e){var t=e.length,r=new e.constructor(t);return t&&"string"==typeof e[0]&&sr.call(e,"index")&&(r.index=e.index,r.input=e.input),r};var ur=function(e,t){var r=t?Oe(e.buffer):e.buffer;return new e.constructor(r,e.byteOffset,e.byteLength)},dr=/\w*$/;var hr=function(e){var t=new e.constructor(e.source,dr.exec(e));return t.lastIndex=e.lastIndex,t},fr=A?A.prototype:void 0,br=fr?fr.valueOf:void 0;var pr=function(e){return br?Object(br.call(e)):{}};var vr=function(e,t,r){var n=e.constructor;switch(t){case"[object ArrayBuffer]":return Oe(e);case"[object Boolean]":case"[object Date]":return new n(+e);case"[object DataView]":return ur(e,r);case"[object Float32Array]":case"[object Float64Array]":case"[object Int8Array]":case"[object Int16Array]":case"[object Int32Array]":case"[object Uint8Array]":case"[object Uint8ClampedArray]":case"[object Uint16Array]":case"[object Uint32Array]":return Se(e,r);case"[object Map]":return new n;case"[object Number]":case"[object String]":return new n(e);case"[object RegExp]":return hr(e);case"[object Set]":return new n;case"[object Symbol]":return pr(e)}};var gr=function(e){return Be(e)&&"[object Map]"==cr(e)},wr=et.a&&et.a.isMap,yr=wr?Ze(wr):gr;var jr=function(e){return Be(e)&&"[object Set]"==cr(e)},Ar=et.a&&et.a.isSet,_r=Ar?Ze(Ar):jr,Or={};Or["[object Arguments]"]=Or["[object Array]"]=Or["[object ArrayBuffer]"]=Or["[object DataView]"]=Or["[object Boolean]"]=Or["[object Date]"]=Or["[object Float32Array]"]=Or["[object Float64Array]"]=Or["[object Int8Array]"]=Or["[object Int16Array]"]=Or["[object Int32Array]"]=Or["[object Map]"]=Or["[object Number]"]=Or["[object Object]"]=Or["[object RegExp]"]=Or["[object Set]"]=Or["[object String]"]=Or["[object Symbol]"]=Or["[object Uint8Array]"]=Or["[object Uint8ClampedArray]"]=Or["[object Uint16Array]"]=Or["[object Uint32Array]"]=!0,Or["[object Error]"]=Or["[object Function]"]=Or["[object WeakMap]"]=!1;var Sr=function e(t,r,n,o,i,l){var a,c=1&r,s=2&r,m=4&r;if(n&&(a=i?n(t,o,i,l):n(t)),void 0!==a)return a;if(!x(t))return t;var u=Le(t);if(u){if(a=mr(t),!c)return ke(t,a)}else{var d=cr(t),h="[object Function]"==d||"[object GeneratorFunction]"==d;if(Object(Ue.a)(t))return Object(Ae.a)(t,c);if("[object Object]"==d||"[object Arguments]"==d||h&&!i){if(a=s||h?{}:Fe(t),!c)return s?Gt(t,Ht(a,t)):qt(t,Dt(a,t))}else{if(!Or[d])return i?t:{};a=vr(t,d,c)}}l||(l=new ve);var f=l.get(t);if(f)return f;l.set(t,a),_r(t)?t.forEach((function(o){a.add(e(o,r,n,o,t,l))})):yr(t)&&t.forEach((function(o,i){a.set(i,e(o,r,n,i,t,l))}));var b=u?void 0:(m?s?Xt:Jt:s?bt:Mt)(t);return Ft(b||t,(function(o,i){b&&(o=t[i=o]),it(a,i,e(o,r,n,i,t,l))})),a};var kr=function(e){return Sr(e,5)};function Er(e,t,r){if(t.attributes)for(const[n,o]of Object.entries(t.attributes))e.setAttribute(n,o,r);t.styles&&e.setStyle(t.styles,r),t.classes&&e.addClass(t.classes,r)}function $r(e,t){const r=kr(e);for(const n in t)Array.isArray(t[n])?r[n]=Array.from(new Set([...e[n],...t[n]])):r[n]={...e[n],...t[n]};return r}function Cr({model:e}){return(t,r)=>r.writer.createElement(e,{htmlContent:t.getCustomProperty("$rawContent")})}function Ir(e,{view:t,isInline:r}){const n=e.t;return(e,{writer:o,consumable:i})=>{const l=n("HTML object"),a=o.createContainerElement(r?"span":"div",{class:"html-object-embed","data-html-object-embed-label":l},{isAllowedInsideAttributeElement:r}),c=Pr(t,e,o);o.addClass("html-object-embed__content",c);const s=e.getAttribute("htmlAttributes");return s&&i.consume(e,"attribute:htmlAttributes:"+e.name)&&Er(o,s,c),o.insert(o.createPositionAt(a,0),c),Object(xt.toWidget)(a,o,{widgetLabel:l})}}function Pr(e,t,r){return r.createRawElement(e,null,(e,r)=>{r.setContentOf(e,t.getAttribute("htmlContent"))})}function xr({priority:e,view:t}){return(r,n)=>{if(!r)return;const{writer:o}=n,i=o.createAttributeElement(t,null,{priority:e});return Er(o,r,i),i}}function Fr({view:e},t){return r=>{r.on("element:"+e,(e,r,n)=>{if(!r.modelRange)return;const o=t._consumeAllowedAttributes(r.viewItem,n);o&&n.writer.setAttribute("htmlAttributes",o,r.modelRange)},{priority:"low"})}}function Br({model:e}){return t=>{t.on("attribute:htmlAttributes:"+e,(e,t,r)=>{const n=t.attributeNewValue;if(!r.consumable.consume(t.item,e.name))return;Er(r.writer,n,r.mapper.toViewElement(t.item))})}}var Tr=function(e,t){for(var r=-1,n=null==e?0:e.length,o=Array(n);++r<n;)o[r]=t(e[r],r,e);return o};var Rr=function(e,t,r,n){for(var o=e.length,i=r+(n?1:-1);n?i--:++i<o;)if(t(e[i],i,e))return i;return-1};var Mr=function(e){return e!=e};var Dr=function(e,t,r){for(var n=r-1,o=e.length;++n<o;)if(e[n]===t)return n;return-1};var Hr=function(e,t,r){return t==t?Dr(e,t,r):Rr(e,Mr,r)};var Lr=function(e,t,r,n){for(var o=r-1,i=e.length;++o<i;)if(n(e[o],t))return o;return-1},zr=Array.prototype.splice;var Nr=function(e,t,r,n){var o=n?Lr:Hr,i=-1,l=t.length,a=e;for(e===t&&(t=ke(t)),r&&(a=Tr(e,Ze(r)));++i<l;)for(var c=0,s=t[i],m=r?r(s):s;(c=o(a,m,c,n))>-1;)a!==e&&zr.call(a,c,1),zr.call(e,c,1);return e};var Vr=Et((function(e,t){return e&&e.length&&t&&t.length?Nr(e,t):e}));r(14);class Ur extends n.Plugin{constructor(e){super(e),this._dataSchema=e.plugins.get("DataSchema"),this._allowedAttributes=new Pt.Matcher,this._disallowedAttributes=new Pt.Matcher,this._allowedElements=new Set,this._dataInitialized=!1,this._registerElementsAfterInit(),this._registerElementHandlers()}static get pluginName(){return"DataFilter"}static get requires(){return[It,xt.Widget]}loadAllowedConfig(e){this._loadConfig(e,e=>this.allowAttributes(e))}loadDisallowedConfig(e){this._loadConfig(e,e=>this.disallowAttributes(e))}allowElement(e){for(const t of this._dataSchema.getDefinitionsForView(e,!0))this._allowedElements.has(t)||(this._allowedElements.add(t),this._dataInitialized&&this._fireRegisterEvent(t))}allowAttributes(e){this._allowedAttributes.add(e)}disallowAttributes(e){this._disallowedAttributes.add(e)}_loadConfig(e,t){for(const r of e){const e=r.name||/[\s\S]+/;this.allowElement(e),Qr(r).forEach(t)}}_consumeAllowedAttributes(e,t){return qr(e,t,this._disallowedAttributes),qr(e,t,this._allowedAttributes)}_registerElementsAfterInit(){this.editor.data.on("init",()=>{this._dataInitialized=!0;for(const e of this._allowedElements)this._fireRegisterEvent(e)},{priority:o.priorities.get("high")+1})}_registerElementHandlers(){this.on("register",(e,t)=>{const r=this.editor.model.schema;if(t.isObject&&!r.isRegistered(t.model))this._registerObjectElement(t);else if(t.isBlock)this._registerBlockElement(t);else{if(!t.isInline)throw new o.CKEditorError("data-filter-invalid-definition",null,t);this._registerInlineElement(t)}e.stop()},{priority:"lowest"})}_fireRegisterEvent(e){this.fire(e.view?"register:"+e.view:"register",e)}_registerObjectElement(e){const t=this.editor,r=t.model.schema,n=t.conversion,{view:i,model:l}=e;r.register(l,e.modelSchema),i&&(r.extend(e.model,{allowAttributes:["htmlAttributes","htmlContent"]}),t.data.registerRawContentMatcher({name:i}),n.for("upcast").elementToElement({view:i,model:Cr(e),converterPriority:o.priorities.get("low")+1}),n.for("upcast").add(Fr(e,this)),n.for("editingDowncast").elementToElement({model:l,view:Ir(t,e)}),n.for("dataDowncast").elementToElement({model:l,view:(e,{writer:t})=>Pr(i,e,t)}),n.for("dataDowncast").add(Br(e)))}_registerBlockElement(e){const t=this.editor,r=t.model.schema,n=t.conversion,{view:i,model:l}=e;if(!r.isRegistered(e.model)){if(r.register(e.model,e.modelSchema),!i)return;n.for("upcast").elementToElement({model:l,view:i,converterPriority:o.priorities.get("low")+1}),n.for("downcast").elementToElement({model:l,view:i})}i&&(r.extend(e.model,{allowAttributes:"htmlAttributes"}),n.for("upcast").add(Fr(e,this)),n.for("downcast").add(Br(e)))}_registerInlineElement(e){const t=this.editor,r=t.model.schema,n=t.conversion,o=e.model;r.extend("$text",{allowAttributes:o}),e.attributeProperties&&r.setAttributeProperties(o,e.attributeProperties),n.for("upcast").add(function({view:e,model:t},r){return n=>{n.on("element:"+e,(e,n,o)=>{const i=r._consumeAllowedAttributes(n.viewItem,o);n.modelRange||(n=Object.assign(n,o.convertChildren(n.viewItem,n.modelCursor)));for(const e of n.modelRange.getItems())if(o.schema.checkAttribute(e,t)){const r=$r(i||{},e.getAttribute(t)||{});o.writer.setAttribute(t,r,e)}},{priority:"low"})}}(e,this)),n.for("downcast").attributeToElement({model:o,view:xr(e)})}}function qr(e,t,r){const n=function(e,{consumable:t},r){const n=r.matchAll(e)||[],o=[];for(const r of n)Wr(t,e,r),delete r.match.name,t.consume(e,r.match)&&o.push(r);return o}(e,t,r),{attributes:o,styles:i,classes:l}=function(e){const t={attributes:new Set,classes:new Set,styles:new Set};for(const r of e)for(const e in t){(r.match[e]||[]).forEach(r=>t[e].add(r))}return t}(n),a={};return o.size&&(a.attributes=Kr(o,t=>e.getAttribute(t))),i.size&&(a.styles=Kr(i,t=>e.getStyle(t))),l.size&&(a.classes=Array.from(l)),Object.keys(a).length?a:null}function Wr(e,t,r){for(const n of["attributes","classes","styles"]){const o=r.match[n];if(o)for(const r of o)e.test(t,{[n]:[r]})||Vr(o,r)}}function Kr(e,t){const r={};for(const n of e){void 0!==t(n)&&(r[n]=t(n))}return r}function Gr(e,t){const{name:r}=e;return Je(e[t])?Object.entries(e[t]).map(([e,n])=>({name:r,[t]:{[e]:n}})):Array.isArray(e[t])?e[t].map(e=>({name:r,[t]:[e]})):[e]}function Qr(e){const{name:t,attributes:r,classes:n,styles:o}=e,i=[];return r&&i.push(...Gr({name:t,attributes:r},"attributes")),n&&i.push(...Gr({name:t,classes:n},"classes")),o&&i.push(...Gr({name:t,styles:o},"styles")),i}class Jr extends n.Plugin{static get requires(){return[Ur]}init(){if(!this.editor.plugins.has("CodeBlockEditing"))return;const e=this.editor.plugins.get(Ur);e.on("register:pre",(t,r)=>{if("codeBlock"!==r.model)return;const n=this.editor,o=n.model.schema,i=n.conversion;o.extend("codeBlock",{allowAttributes:["htmlAttributes","htmlContentAttributes"]}),i.for("upcast").add(function(e){return t=>{t.on("element:code",(t,r,n)=>{const o=r.viewItem,i=o.parent;function l(t,o){const i=e._consumeAllowedAttributes(t,n);i&&n.writer.setAttribute(o,i,r.modelRange)}i&&i.is("element","pre")&&(l(i,"htmlAttributes"),l(o,"htmlContentAttributes"))},{priority:"low"})}}(e)),i.for("downcast").add(e=>{e.on("attribute:htmlAttributes:codeBlock",(e,t,r)=>{if(!r.consumable.consume(t.item,e.name))return;const n=r.mapper.toViewElement(t.item).parent;Er(r.writer,t.attributeNewValue,n)}),e.on("attribute:htmlContentAttributes:codeBlock",(e,t,r)=>{if(!r.consumable.consume(t.item,e.name))return;const n=r.mapper.toViewElement(t.item);Er(r.writer,t.attributeNewValue,n)})}),t.stop()})}}class Xr extends n.Plugin{static get requires(){return[Ur]}init(){this.editor.plugins.get(Ur).on("register",(e,t)=>{const r=this.editor,n=r.model.schema,i=r.conversion;if(!t.paragraphLikeModel)return;if(n.isRegistered(t.model)||n.isRegistered(t.paragraphLikeModel))return;const l={model:t.paragraphLikeModel,view:t.view};n.register(t.model,t.modelSchema),n.register(l.model,{inheritAllFrom:"$block"}),i.for("upcast").elementToElement({view:t.view,model:(e,{writer:r})=>this._hasBlockContent(e)?r.createElement(t.model):r.createElement(l.model),converterPriority:o.priorities.get("low")+1}),i.for("downcast").elementToElement({view:t.view,model:t.model}),this._addAttributeConversion(t),i.for("downcast").elementToElement({view:l.view,model:l.model}),this._addAttributeConversion(l),e.stop()})}_hasBlockContent(e){const t=this.editor.editing.view.domConverter.blockElements;return Array.from(e.getChildren()).some(e=>t.includes(e.name))}_addAttributeConversion(e){const t=this.editor,r=t.conversion,n=t.plugins.get(Ur);t.model.schema.extend(e.model,{allowAttributes:"htmlAttributes"}),r.for("upcast").add(Fr(e,n)),r.for("downcast").add(Br(e))}}class Yr extends n.Plugin{static get requires(){return[It]}init(){const e=this.editor;if(!e.plugins.has("HeadingEditing"))return;const t=e.plugins.get(It),r=e.config.get("heading.options"),n=[];for(const e of r)"model"in e&&"view"in e&&(t.registerBlockElement({view:e.view,model:e.model}),n.push(e.model));t.extendBlockElement({model:"htmlHgroup",modelSchema:{allowChildren:n}})}}class Zr extends n.Plugin{static get requires(){return[Ur]}init(){const e=this.editor;if(!e.plugins.has("ImageInlineEditing")&&!e.plugins.has("ImageBlockEditing"))return;const t=e.model.schema,r=e.conversion,n=e.plugins.get(Ur);n.on("register:img",(e,o)=>{"imageBlock"!==o.model&&"imageInline"!==o.model||(t.isRegistered("imageBlock")&&t.extend("imageBlock",{allowAttributes:["htmlAttributes","htmlFigureAttributes","htmlLinkAttributes"]}),t.isRegistered("imageInline")&&t.extend("imageInline",{allowAttributes:["htmlA","htmlAttributes"]}),r.for("upcast").add(function(e){return t=>{t.on("element:img",(t,r,n)=>{const o=r.viewItem,i=o.parent;function l(t,o){const i=e._consumeAllowedAttributes(t,n);i&&n.writer.setAttribute(o,i,r.modelRange)}l(o,"htmlAttributes"),i.is("element","figure")?l(i,"htmlFigureAttributes"):i.is("element","a")&&function(e){r.modelRange&&r.modelRange.getContainedElement().is("element","imageBlock")&&l(e,"htmlLinkAttributes");e.parent.is("element","figure")&&l(e.parent,"htmlFigureAttributes")}(i)},{priority:"low"})}}(n)),r.for("downcast").add(e=>{var t;function r(t,r){e.on(`attribute:${r}:imageBlock`,(e,r,n)=>{if(!n.consumable.consume(r.item,e.name))return;const o=n.mapper.toViewElement(r.item),i=en(n.writer,o,t);Er(n.writer,r.attributeNewValue,i)},{priority:"low"})}t="htmlAttributes",e.on(`attribute:${t}:imageInline`,(e,t,r)=>{if(!r.consumable.consume(t.item,e.name))return;const n=r.mapper.toViewElement(t.item);Er(r.writer,t.attributeNewValue,n)},{priority:"low"}),r("img","htmlAttributes"),r("figure","htmlFigureAttributes"),e.on("attribute:linkHref:imageBlock",(e,t,r)=>{if(!r.consumable.consume(t.item,"attribute:htmlLinkAttributes:imageBlock"))return;const n=r.mapper.toViewElement(t.item),o=en(r.writer,n,"a");Er(r.writer,t.item.getAttribute("htmlLinkAttributes"),o)},{priority:"low"})}),e.stop())})}}function en(e,t,r){const n=e.createRangeOn(t);for(const{item:e}of n.getWalker())if(e.is("element",r))return e}class tn extends n.Plugin{static get requires(){return[Ur]}init(){const e=this.editor;if(!e.plugins.has("MediaEmbed")||e.config.get("mediaEmbed.previewsInData"))return;const t=e.model.schema,r=e.conversion,n=this.editor.plugins.get(Ur),o=this.editor.plugins.get(It),i=e.config.get("mediaEmbed.elementName");o.registerBlockElement({model:"media",view:i}),n.on("register:"+i,(e,o)=>{"media"===o.model&&(t.extend("media",{allowAttributes:["htmlAttributes","htmlFigureAttributes"]}),r.for("upcast").add(function(e,t){return e=>{e.on("element:"+t,r)};function r(t,r,n){const o=r.viewItem,i=o.parent;function l(t,o){const i=e._consumeAllowedAttributes(t,n);i&&n.writer.setAttribute(o,i,r.modelRange)}l(o,"htmlAttributes"),i.is("element","figure")&&i.hasClass("media")&&l(i,"htmlFigureAttributes")}}(n,i)),r.for("dataDowncast").add(function(e){return t=>{function r(e,r){t.on(`attribute:${r}:media`,(t,r,n)=>{if(!n.consumable.consume(r.item,t.name))return;const o=n.mapper.toViewElement(r.item),i=function(e,t,r){const n=e.createRangeOn(t);for(const{item:e}of n.getWalker())if(e.is("element",r))return e}(n.writer,o,e);Er(n.writer,r.attributeNewValue,i)})}r(e,"htmlAttributes"),r("figure","htmlFigureAttributes")}}(i)),e.stop())})}}class rn extends n.Plugin{static get requires(){return[Ur]}init(){const e=this.editor;if(!e.plugins.has("TableEditing"))return;const t=e.model.schema,r=e.conversion,n=e.plugins.get(Ur);n.on("register:table",(e,o)=>{"table"===o.model&&(t.extend("table",{allowAttributes:["htmlAttributes","htmlFigureAttributes","htmlTheadAttributes","htmlTbodyAttributes"]}),r.for("upcast").add(function(e){return t=>{t.on("element:table",(t,r,n)=>{const o=r.viewItem;l(o,"htmlAttributes");const i=o.parent;i.is("element","figure")&&l(i,"htmlFigureAttributes");for(const e of o.getChildren())e.is("element","thead")&&l(e,"htmlTheadAttributes"),e.is("element","tbody")&&l(e,"htmlTbodyAttributes");function l(t,o){const i=e._consumeAllowedAttributes(t,n);i&&n.writer.setAttribute(o,i,r.modelRange)}},{priority:"low"})}}(n)),r.for("downcast").add(e=>{function t(t,r){e.on(`attribute:${r}:table`,(e,r,n)=>{if(!n.consumable.consume(r.item,e.name))return;const o=n.mapper.toViewElement(r.item),i=function(e,t,r){const n=e.createRangeOn(t);for(const{item:e}of n.getWalker())if(e.is("element",r))return e}(n.writer,o,t);Er(n.writer,r.attributeNewValue,i)})}t("table","htmlAttributes"),t("figure","htmlFigureAttributes"),t("thead","htmlTheadAttributes"),t("tbody","htmlTbodyAttributes")}),e.stop())})}}class nn extends n.Plugin{static get pluginName(){return"GeneralHtmlSupport"}static get requires(){return[Ur,Jr,Xr,Yr,Zr,tn,rn]}init(){const e=this.editor,t=e.plugins.get(Ur);t.loadAllowedConfig(e.config.get("htmlSupport.allow")||[]),t.loadDisallowedConfig(e.config.get("htmlSupport.disallow")||[])}}class on extends n.Plugin{static get pluginName(){return"HtmlComment"}init(){const e=this.editor;e.model.schema.addAttributeCheck((e,t)=>{if(e.endsWith("$root")&&t.startsWith("$comment"))return!0}),e.conversion.for("upcast").elementToMarker({view:"$comment",model:(e,{writer:t})=>{const r=this.editor.model.document.getRoot(),n=e.getCustomProperty("$rawContent"),i="$comment:"+Object(o.uid)();return t.setAttribute(i,n,r),i}}),e.conversion.for("dataDowncast").markerToElement({model:"$comment",view:(e,{writer:t})=>{const r=this.editor.model.document.getRoot(),n=e.markerName,o=r.getAttribute(n),i=t.createUIElement("$comment");return t.setCustomProperty("$rawContent",o,i),i}}),e.model.document.registerPostFixer(t=>{const r=e.model.document.getRoot(),n=e.model.document.differ.getChangedMarkers().filter(e=>e.name.startsWith("$comment")).filter(e=>{const t=e.data.newRange;return t&&"$graveyard"===t.root.rootName});if(0===n.length)return!1;for(const e of n)t.removeMarker(e.name),t.removeAttribute(e.name,r);return!0}),e.data.on("set",()=>{for(const t of e.model.markers.getMarkersGroup("$comment"))this.removeHtmlComment(t.name)},{priority:"high"}),e.model.on("deleteContent",(t,[r])=>{for(const t of r.getRanges()){const r=e.model.schema.getLimitElement(t),n=e.model.createPositionAt(r,0),o=e.model.createPositionAt(r,"end");let i;i=n.isTouching(t.start)&&o.isTouching(t.end)?this.getHtmlCommentsInRange(e.model.createRange(n,o)):this.getHtmlCommentsInRange(t,{skipBoundaries:!0});for(const e of i)this.removeHtmlComment(e)}},{priority:"high"})}createHtmlComment(e,t){const r=Object(o.uid)(),n=this.editor.model,i=n.document.getRoot(),l="$comment:"+r;return n.change(r=>{const n=r.createRange(e);return r.addMarker(l,{usingOperation:!0,affectsData:!0,range:n}),r.setAttribute(l,t,i),l})}removeHtmlComment(e){const t=this.editor,r=t.model.document.getRoot(),n=t.model.markers.get(e);return!!n&&(t.model.change(t=>{t.removeMarker(n),t.removeAttribute(e,r)}),!0)}getHtmlCommentData(e){const t=this.editor,r=t.model.markers.get(e),n=t.model.document.getRoot();return r?{content:n.getAttribute(e),position:r.getStart()}:null}getHtmlCommentsInRange(e,{skipBoundaries:t=!1}={}){const r=!t;return Array.from(this.editor.model.markers.getMarkersGroup("$comment")).filter(t=>function(e,t){const n=e.getRange().start;return(n.isAfter(t.start)||r&&n.isEqual(t.start))&&(n.isBefore(t.end)||r&&n.isEqual(t.end))}(t,e)).map(e=>e.name)}}}]);
{
"name": "@ckeditor/ckeditor5-html-support",
"version": "30.0.0",
"version": "31.0.0",
"description": "HTML Support feature for CKEditor 5.",

@@ -19,35 +19,35 @@ "keywords": [

"dependencies": {
"ckeditor5": "^30.0.0",
"ckeditor5": "^31.0.0",
"lodash-es": "^4.17.15"
},
"devDependencies": {
"@ckeditor/ckeditor5-alignment": "^30.0.0",
"@ckeditor/ckeditor5-basic-styles": "^30.0.0",
"@ckeditor/ckeditor5-block-quote": "^30.0.0",
"@ckeditor/ckeditor5-cloud-services": "^30.0.0",
"@ckeditor/ckeditor5-code-block": "^30.0.0",
"@ckeditor/ckeditor5-core": "^30.0.0",
"@ckeditor/ckeditor5-alignment": "^31.0.0",
"@ckeditor/ckeditor5-basic-styles": "^31.0.0",
"@ckeditor/ckeditor5-block-quote": "^31.0.0",
"@ckeditor/ckeditor5-cloud-services": "^31.0.0",
"@ckeditor/ckeditor5-code-block": "^31.0.0",
"@ckeditor/ckeditor5-core": "^31.0.0",
"@ckeditor/ckeditor5-dev-utils": "^25.4.0",
"@ckeditor/ckeditor5-easy-image": "^30.0.0",
"@ckeditor/ckeditor5-editor-classic": "^30.0.0",
"@ckeditor/ckeditor5-engine": "^30.0.0",
"@ckeditor/ckeditor5-enter": "^30.0.0",
"@ckeditor/ckeditor5-essentials": "^30.0.0",
"@ckeditor/ckeditor5-font": "^30.0.0",
"@ckeditor/ckeditor5-heading": "^30.0.0",
"@ckeditor/ckeditor5-highlight": "^30.0.0",
"@ckeditor/ckeditor5-horizontal-line": "^30.0.0",
"@ckeditor/ckeditor5-html-embed": "^30.0.0",
"@ckeditor/ckeditor5-image": "^30.0.0",
"@ckeditor/ckeditor5-indent": "^30.0.0",
"@ckeditor/ckeditor5-link": "^30.0.0",
"@ckeditor/ckeditor5-list": "^30.0.0",
"@ckeditor/ckeditor5-media-embed": "^30.0.0",
"@ckeditor/ckeditor5-page-break": "^30.0.0",
"@ckeditor/ckeditor5-paragraph": "^30.0.0",
"@ckeditor/ckeditor5-paste-from-office": "^30.0.0",
"@ckeditor/ckeditor5-source-editing": "^30.0.0",
"@ckeditor/ckeditor5-table": "^30.0.0",
"@ckeditor/ckeditor5-theme-lark": "^30.0.0",
"@ckeditor/ckeditor5-utils": "^30.0.0",
"@ckeditor/ckeditor5-easy-image": "^31.0.0",
"@ckeditor/ckeditor5-editor-classic": "^31.0.0",
"@ckeditor/ckeditor5-engine": "^31.0.0",
"@ckeditor/ckeditor5-enter": "^31.0.0",
"@ckeditor/ckeditor5-essentials": "^31.0.0",
"@ckeditor/ckeditor5-font": "^31.0.0",
"@ckeditor/ckeditor5-heading": "^31.0.0",
"@ckeditor/ckeditor5-highlight": "^31.0.0",
"@ckeditor/ckeditor5-horizontal-line": "^31.0.0",
"@ckeditor/ckeditor5-html-embed": "^31.0.0",
"@ckeditor/ckeditor5-image": "^31.0.0",
"@ckeditor/ckeditor5-indent": "^31.0.0",
"@ckeditor/ckeditor5-link": "^31.0.0",
"@ckeditor/ckeditor5-list": "^31.0.0",
"@ckeditor/ckeditor5-media-embed": "^31.0.0",
"@ckeditor/ckeditor5-page-break": "^31.0.0",
"@ckeditor/ckeditor5-paragraph": "^31.0.0",
"@ckeditor/ckeditor5-paste-from-office": "^31.0.0",
"@ckeditor/ckeditor5-source-editing": "^31.0.0",
"@ckeditor/ckeditor5-table": "^31.0.0",
"@ckeditor/ckeditor5-theme-lark": "^31.0.0",
"@ckeditor/ckeditor5-utils": "^31.0.0",
"webpack": "^4.43.0",

@@ -54,0 +54,0 @@ "webpack-cli": "^3.3.11"

@@ -75,4 +75,4 @@ /**

export function createObjectView( viewName, modelElement, writer ) {
return writer.createRawElement( viewName, null, function( domElement ) {
domElement.innerHTML = modelElement.getAttribute( 'htmlContent' );
return writer.createRawElement( viewName, null, ( domElement, domConverter ) => {
domConverter.setContentOf( domElement, modelElement.getAttribute( 'htmlContent' ) );
} );

@@ -79,0 +79,0 @@ }

@@ -13,2 +13,3 @@ /**

import defaultConfig from './schemadefinitions';
import { mergeWith } from 'lodash-es';

@@ -98,2 +99,26 @@ /**

/**
* Updates schema definition describing block element with new properties.
*
* Creates new scheme if it doesn't exist.
* Array properties are concatenated with original values.
*
* @param {module:html-support/dataschema~DataSchemaBlockElementDefinition} definition Definition update.
*/
extendBlockElement( definition ) {
this._extendDefinition( { ...definition, isBlock: true } );
}
/**
* Updates schema definition describing inline element with new properties.
*
* Creates new scheme if it doesn't exist.
* Array properties are concatenated with original values.
*
* @param {module:html-support/dataschema~DataSchemaInlineElementDefinition} definition Definition update.
*/
extendInlineElement( definition ) {
this._extendDefinition( { ...definition, isInline: true } );
}
/**
* Returns all definitions matching the given view name.

@@ -160,2 +185,21 @@ *

}
/**
* Updates schema definition with new properties.
*
* Creates new scheme if it doesn't exist.
* Array properties are concatenated with original values.
*
* @private
* @param {module:html-support/dataschema~DataSchemaDefinition} definition Definition update.
*/
_extendDefinition( definition ) {
const currentDefinition = this._definitions.get( definition.model );
const mergedDefinition = mergeWith( {}, currentDefinition, definition, ( target, source ) => {
return Array.isArray( target ) ? target.concat( source ) : undefined;
} );
this._definitions.set( definition.model, mergedDefinition );
}
}

@@ -209,3 +253,3 @@

* @property {module:engine/model/schema~AttributeProperties} [attributeProperties] Additional metadata describing the model attribute.
* @property {Boolean} isInline Indicates that the definition descibes inline element.
* @property {Boolean} isInline Indicates that the definition describes inline element.
* @property {Number} [priority] Element priority. Decides in what order elements are wrapped by

@@ -212,0 +256,0 @@ * {@link module:engine/view/downcastwriter~DowncastWriter}.

@@ -15,2 +15,3 @@ /**

import DualContentModelElementSupport from './integrations/dualcontent';
import HeadingElementSupport from './integrations/heading';
import ImageElementSupport from './integrations/image';

@@ -44,2 +45,3 @@ import MediaEmbedElementSupport from './integrations/mediaembed';

DualContentModelElementSupport,
HeadingElementSupport,
ImageElementSupport,

@@ -46,0 +48,0 @@ MediaEmbedElementSupport,

@@ -55,14 +55,2 @@ /**

{
model: 'heading1',
view: 'h2'
},
{
model: 'heading2',
view: 'h3'
},
{
model: 'heading3',
view: 'h4'
},
{
model: 'codeBlock',

@@ -330,11 +318,8 @@ view: 'pre'

allowChildren: [
'htmlHeading1',
'htmlHeading2',
'htmlHeading3',
'htmlHeading4',
'htmlHeading5',
'htmlHeading6',
'heading1',
'heading2',
'heading3'
'htmlH1',
'htmlH2',
'htmlH3',
'htmlH4',
'htmlH5',
'htmlH6'
],

@@ -341,0 +326,0 @@ isBlock: true

SocketSocket SOC 2 Logo

Product

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

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc