@ckeditor/ckeditor5-footnotes 47.2.0-alpha.4 → 47.2.0-alpha.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -2,4 +2,4 @@
2
2
  /*!
3
3
  * @license Copyright (c) 2003-2025, CKSource Holding sp. z o.o. All rights reserved.
4
4
  * For licensing, see LICENSE.md.
5
- */(()=>{var t={14:(t,e,o)=>{"use strict";o.d(e,{A:()=>a});var n=o(453),i=o.n(n),s=o(374),r=o.n(s)()(i());r.push([t.id,":root{--ck-content-footnotes-list-background-color:none;--ck-content-footnotes-list-separator-color:#000;--ck-content-footnote-font-size:var(--ck-content-font-size-small);--ck-footnotes-widget-label-background-color:#757575}.ck-content .footnote{margin-inline-end:.2em}.ck-content .footnotes{background-color:var(--ck-content-footnotes-list-background-color);font-size:var(--ck-content-footnote-font-size);margin:.9em 0 1.5em;position:relative}.ck-content .footnotes-divider{background:none;border:none;border-top:1px solid var(--ck-content-footnotes-list-separator-color);height:1px;margin:0 0 1em;width:min(30%,350px)}[dir=rtl] .ck-content .footnotes-divider{margin-left:auto;margin-right:0}.ck-content .footnotes-list{margin:0;padding-inline-start:3em}.ck-content .footnote-backlink{display:inline-block;margin-inline-end:1ch;user-select:none;vertical-align:top;width:auto}.ck-content .footnote-content{display:inline-block;padding:0 4px;vertical-align:top;width:calc(100% - 2em)}.ck-content .footnote-content>p:first-of-type{margin-top:0}.ck-content .footnote-content>p:last-of-type{margin-bottom:0}.ck-content .footnote-content ol{list-style-type:decimal}.ck-content .footnote-content ol ol{list-style-type:lower-latin}.ck-content .footnote-content ol ol ol{list-style-type:lower-roman}.ck-content .footnote-content ol ol ol ol{list-style-type:upper-latin}.ck-content .footnote-content ol ol ol ol ol{list-style-type:upper-roman}.ck.ck-editor__editable .footnotes.ck-widget{display:flow-root;margin:.9em 0 .85em;position:relative}.ck.ck-editor__editable .footnotes.ck-widget:not(:hover):not(.ck-widget_selected){outline:1px solid var(--ck-color-base-border)}.ck.ck-editor__editable .footnotes.ck-widget[data-footnotes-list-label]:after{background-color:var(--ck-footnotes-widget-label-background-color);color:#fff;content:attr(data-footnotes-list-label);font-family:var(--ck-font-face);font-size:10px;line-height:16px;padding:var(--ck-spacing-tiny) var(--ck-spacing-medium);position:absolute;right:10px;top:-1px;white-space:nowrap}[dir=rtl] .ck.ck-editor__editable .footnotes.ck-widget[data-footnotes-list-label]:after{left:10px;right:auto}.ck.ck-editor__editable .footnotes-divider{margin-top:0}.ck.ck-editor__editable .footnotes-list{margin-bottom:.65em;margin-top:0}",""]);const a=r},237:t=>{"use strict";t.exports=CKEditor5.dll},238:t=>{"use strict";t.exports=function(t){var e=document.createElement("style");return t.setAttributes(e,t.attributes),t.insert(e,t.options),e}},265:t=>{"use strict";var e={};t.exports=function(t,o){var n=function(t){if(void 0===e[t]){var o=document.querySelector(t);if(window.HTMLIFrameElement&&o instanceof window.HTMLIFrameElement)try{o=o.contentDocument.head}catch(t){o=null}e[t]=o}return e[t]}(t);if(!n)throw new Error("Couldn't find a style target. This probably means that the value for the 'insert' parameter is invalid.");n.appendChild(o)}},311:(t,e,o)=>{t.exports=o(237)("./src/ui.js")},331:(t,e,o)=>{t.exports=o(237)("./src/clipboard.js")},355:(t,e,o)=>{t.exports=o(237)("./src/icons.js")},374:t=>{"use strict";t.exports=function(t){var e=[];return e.toString=function(){return this.map(function(e){var o="",n=void 0!==e[5];return e[4]&&(o+="@supports (".concat(e[4],") {")),e[2]&&(o+="@media ".concat(e[2]," {")),n&&(o+="@layer".concat(e[5].length>0?" ".concat(e[5]):""," {")),o+=t(e),n&&(o+="}"),e[2]&&(o+="}"),e[4]&&(o+="}"),o}).join("")},e.i=function(t,o,n,i,s){"string"==typeof t&&(t=[[null,t,void 0]]);var r={};if(n)for(var a=0;a<this.length;a++){var c=this[a][0];null!=c&&(r[c]=!0)}for(var l=0;l<t.length;l++){var u=[].concat(t[l]);n&&r[u[0]]||(void 0!==s&&(void 0===u[5]||(u[1]="@layer".concat(u[5].length>0?" ".concat(u[5]):""," {").concat(u[1],"}")),u[5]=s),o&&(u[2]?(u[1]="@media ".concat(u[2]," {").concat(u[1],"}"),u[2]=o):u[2]=o),i&&(u[4]?(u[1]="@supports (".concat(u[4],") {").concat(u[1],"}"),u[4]=i):u[4]="".concat(i)),e.push(u))}},e}},410:t=>{"use strict";t.exports=function(t,e){Object.keys(e).forEach(function(o){t.setAttribute(o,e[o])})}},450:t=>{"use strict";var e=[];function o(t){for(var o=-1,n=0;n<e.length;n++)if(e[n].identifier===t){o=n;break}return o}function n(t,n){for(var s={},r=[],a=0;a<t.length;a++){var c=t[a],l=n.base?c[0]+n.base:c[0],u=s[l]||0,f="".concat(l," ").concat(u);s[l]=u+1;var d=o(f),h={css:c[1],media:c[2],sourceMap:c[3],supports:c[4],layer:c[5]};if(-1!==d)e[d].references++,e[d].updater(h);else{var p=i(h,n);n.byIndex=a,e.splice(a,0,{identifier:f,updater:p,references:1})}r.push(f)}return r}function i(t,e){var o=e.domAPI(e);o.update(t);return function(e){if(e){if(e.css===t.css&&e.media===t.media&&e.sourceMap===t.sourceMap&&e.supports===t.supports&&e.layer===t.layer)return;o.update(t=e)}else o.remove()}}t.exports=function(t,i){var s=n(t=t||[],i=i||{});return function(t){t=t||[];for(var r=0;r<s.length;r++){var a=o(s[r]);e[a].references--}for(var c=n(t,i),l=0;l<s.length;l++){var u=o(s[l]);0===e[u].references&&(e[u].updater(),e.splice(u,1))}s=c}}},453:t=>{"use strict";t.exports=function(t){return t[1]}},584:(t,e,o)=>{t.exports=o(237)("./src/utils.js")},774:t=>{"use strict";var e,o=(e=[],function(t,o){return e[t]=o,e.filter(Boolean).join("\n")});function n(t,e,n,i){var s;if(n)s="";else{s="",i.supports&&(s+="@supports (".concat(i.supports,") {")),i.media&&(s+="@media ".concat(i.media," {"));var r=void 0!==i.layer;r&&(s+="@layer".concat(i.layer.length>0?" ".concat(i.layer):""," {")),s+=i.css,r&&(s+="}"),i.media&&(s+="}"),i.supports&&(s+="}")}if(t.styleSheet)t.styleSheet.cssText=o(e,s);else{var a=document.createTextNode(s),c=t.childNodes;c[e]&&t.removeChild(c[e]),c.length?t.insertBefore(a,c[e]):t.appendChild(a)}}var i={singleton:null,singletonCounter:0};t.exports=function(t){if("undefined"==typeof document)return{update:function(){},remove:function(){}};var e=i.singletonCounter++,o=i.singleton||(i.singleton=t.insertStyleElement(t));return{update:function(t){n(o,e,!1,t)},remove:function(t){n(o,e,!0,t)}}}},782:(t,e,o)=>{t.exports=o(237)("./src/core.js")},783:(t,e,o)=>{t.exports=o(237)("./src/engine.js")},901:(t,e,o)=>{t.exports=o(237)("./src/widget.js")},945:(t,e,o)=>{"use strict";o.d(e,{A:()=>a});var n=o(453),i=o.n(n),s=o(374),r=o.n(s)()(i());r.push([t.id,":root{--ck-footnotes-styles-list-style-button-size:44px}.ck.ck-footnotes-definitions-properties>.ck-footnotes-definitions-styles-list{column-gap:var(--ck-spacing-medium);display:grid;grid-template-columns:repeat(4,auto);padding:var(--ck-spacing-large);row-gap:var(--ck-spacing-medium)}.ck.ck-footnotes-definitions-properties>.ck-footnotes-definitions-styles-list .ck-button{box-sizing:content-box;margin:0;padding:0}.ck.ck-footnotes-definitions-properties>.ck-footnotes-definitions-styles-list .ck-button,.ck.ck-footnotes-definitions-properties>.ck-footnotes-definitions-styles-list .ck-button .ck-icon{height:var(--ck-footnotes-styles-list-style-button-size);width:var(--ck-footnotes-styles-list-style-button-size)}.ck.ck-footnotes-definitions-properties>.ck-collapsible{border-top:1px solid var(--ck-color-base-border)}.ck.ck-footnotes-definitions-properties>.ck-collapsible .ck-footnotes-definitions-properties__start-index .ck-input{min-width:100%}",""]);const a=r}},e={};function o(n){var i=e[n];if(void 0!==i)return i.exports;var s=e[n]={id:n,exports:{}};return t[n](s,s.exports,o),s.exports}o.n=t=>{var e=t&&t.__esModule?()=>t.default:()=>t;return o.d(e,{a:e}),e},o.d=(t,e)=>{for(var n in e)o.o(e,n)&&!o.o(t,n)&&Object.defineProperty(t,n,{enumerable:!0,get:e[n]})},o.o=(t,e)=>Object.prototype.hasOwnProperty.call(t,e),o.r=t=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})};var n={};(()=>{"use strict";o.r(n),o.d(n,{Footnotes:()=>Q,FootnotesClipboard:()=>_,FootnotesEditing:()=>v,FootnotesProperties:()=>Pt,FootnotesPropertiesEditing:()=>mt,FootnotesPropertiesUI:()=>Ct,FootnotesStartCommand:()=>ft,FootnotesStyleCommand:()=>at,FootnotesTracker:()=>h,FootnotesUI:()=>Y,InsertFootnoteCommand:()=>b});var t=o(782),e=o(901),i=o(584),s=o(783);function r(){const t=["delete","createRangeOn","push","_model","clear","flat","2374920Duyiku","attributes","add","_getElementKey","nodeAfter","getChanges","1748817sStsfU","element","$graveyard","rootName","1Mxrevv","slice","9yeIroA","reset","type","from","position","set","getElementKey","710902bCyzqc","17305BtTzFL","values","_elementName","626260uvRIhI","4089127azncwM","4ZmCrYE","13090jtrVcx","$text","getItems","_trackedElements","name","insert","length","6JyQxjG","remove","has","4044eoVAtZ","root","elementName","get"];return(r=function(){return t})()}function a(t,e){const o=r();return(a=function(t,e){return o[t-=271]})(t,e)}const c=a;!function(t){const e=a,o=t();for(;;)try{if(318595===parseInt(e(305))/1*(parseInt(e(314))/2)+-parseInt(e(301))/3+parseInt(e(274))/4*(parseInt(e(315))/5)+-parseInt(e(282))/6*(-parseInt(e(273))/7)+-parseInt(e(295))/8*(-parseInt(e(307))/9)+parseInt(e(272))/10+parseInt(e(275))/11*(-parseInt(e(285))/12))break;o.push(o.shift())}catch(t){o.push(o.shift())}}(r);class l{[c(292)];[c(271)];[c(298)];[c(278)]=new Map;constructor(t,e){const o=c;this[o(292)]=t,this[o(271)]=e[o(287)],this[o(298)]=e[o(313)]}[c(308)](){const t=c;this[t(278)][t(293)]()}[c(300)](t){const e=c,o=new Set,n=new Map;for(const i of t){if(e(280)===i[e(309)]&&e(276)!==i[e(279)]&&i[e(311)][e(299)]){const t=this[e(292)][e(290)](i[e(311)][e(299)]);for(const o of t[e(277)]()){if(!o.is(e(302),this[e(271)]))continue;const t=this[e(298)](o);n[e(284)](t)||n[e(312)](t,[]),n[e(288)](t)[e(291)](o)}}if(e(283)===i[e(309)]&&i[e(279)]===this[e(271)]){const t=this[e(298)]({getAttribute:t=>i[e(296)][e(288)](t)});o[e(297)](t)}}for(const[t,n]of this[e(278)])e(303)===n[e(286)][e(304)]&&o[e(297)](t);for(const t of o)this[e(278)][e(289)](t);for(const[t,o]of n)this[e(278)][e(312)](t,o[o[e(281)]-1]);const i=new Set;for(const[t,s]of n)o[e(284)](t)&&(i[e(297)](s[0]),s[e(281)]>1?n[e(312)](t,s[e(306)](1)):n[e(289)](t),o[e(289)](t));return{removed:Array[e(310)](o),inserted:Array[e(310)](n[e(316)]())[e(294)](),moved:Array[e(310)](i)}}}const u=d;function f(){const t=["init","setFootnoteFormatter","remove","22YhaBOF","getFootnotesDefinitionsObjectElement","createElement","_ensureFootnotesReferencesHaveProperOrder","_updateFootnoteRefCounter","_sortFootnoteDefinitions","min","createRangeOn","_footnoteDefsContainerTracker","add","getChildren","indexOf","registerPostFixer","_handleFootnoteDefinitionsChanges","77xMDuhs","compareWith","enqueueChange","6502528HNVEFl","differ","rootName","from","_updateFootnotesCounters","move","footnoteCounter","footnoteId","_handleFootnotesDefinitionsObjectSync","high","$graveyard","low","footnotesDefinitions","pluginName","isOfficialPlugin","has","append","map","_handleFootnotesDefinitionsObjectChanges","childCount","_ensureFootnotesDefinitionsContainerExists","editor","footnoteRef","find","getAttribute","footnoteInlineContent","splice","definition","paragraph","parent","_handleMovedFootnoteReference","getChanges","unshift","listenTo","isPremiumPlugin","getFootnotesFormatter","length","singleton","setAttribute","model","_footnoteRefsTracker","99icGCil","_footnotes","FootnotesTracker","change:data","168495DMtoXo","_footnotesDefinitions","reset","_footnoteDefsTracker","isEqual","config","some","reference","document","push","_handleRemoveFootnoteReferenceById","4CtxCza","insert","getRootNames","createRangeIn","footnotes.multiBlock","197148VPUSYD","end","root","_footnoteFormatter","after","_handleFootnoteReferencesChanges","671170anbjdx","footnoteDefinition","1496265uvPwyt","findIndex","12221979VFBuNQ","createPositionAt","_handleInsertedFootnoteReference","before","set","getFootnote","get","_insertEmptyFootnotesDefinitionsContainer","createPositionBefore","getFootnotes","497230DeiNMB"];return(f=function(){return t})()}function d(t,e){const o=f();return(d=function(t,e){return o[t-=345]})(t,e)}!function(t){const e=d,o=t();for(;;)try{if(496454===-parseInt(e(387))/1+-parseInt(e(391))/2*(-parseInt(e(351))/3)+parseInt(e(362))/4*(-parseInt(e(375))/5)+-parseInt(e(367))/6*(parseInt(e(405))/7)+-parseInt(e(408))/8+-parseInt(e(347))/9*(-parseInt(e(373))/10)+parseInt(e(377))/11)break;o.push(o.shift())}catch(t){o.push(o.shift())}}(f);class h extends t.Plugin{[u(348)]=[];[u(352)]=null;[u(370)]=null;[u(399)];[u(346)];[u(354)];static get[u(421)](){return u(349)}static get[u(422)](){return!0}static get[u(442)](){return!0}constructor(t){const e=u;super(t),this[e(399)]=new l(this[e(429)][e(345)],{elementName:e(420),getElementKey:()=>e(445)}),this[e(346)]=new l(this[e(429)][e(345)],{elementName:e(430),getElementKey:t=>t[e(432)](e(415))}),this[e(354)]=new l(this[e(429)][e(345)],{elementName:e(374),getElementKey:t=>t[e(432)](e(415))})}[u(388)](){const t=u,{editor:e}=this,{model:o,data:n}=e;o[t(359)][t(403)](e=>{const n=t,i=o[n(359)][n(409)][n(439)]();let s=!1;return this[n(426)](e,i)&&(s=!0),this[n(404)](e,i)&&(s=!0),this[n(372)](e,i)&&(s=!0),this[n(394)](e)&&(s=!0),this[n(416)](e)&&(s=!0),this[n(396)](e)&&(s=!0),s}),this[t(441)](o[t(359)],t(350),()=>{const e=t;o[e(407)]({isUndoable:!1},t=>{this[e(428)](t)})},{priority:t(419)}),this[t(441)](n,t(381),()=>{const e=t;this[e(348)]=[],this[e(399)][e(353)](),this[e(346)][e(353)](),this[e(354)][e(353)]()},{priority:t(417)})}[u(392)](){return this[u(352)]}[u(382)](t){const e=u;return this[e(348)][e(431)](e=>e.id===t)||null}[u(386)](){const t=u;return Array[t(411)](this[t(348)])}[u(443)](){return this[u(370)]}[u(389)](t){this[u(370)]=t}[u(412)](t,e=0){const o=u;let n=!1;for(let i=e;i<this[o(348)][o(444)];i++)this[o(395)](t,i)&&(n=!0);return n}[u(384)](t,e){const o=u,n=t[o(393)](o(420),{});return t[o(424)](n,e),this[o(352)]=n,n}[u(428)](t){const e=u;if(!this[e(348)][e(444)]||this[e(352)])return;const o=this[e(348)][0][e(358)][e(369)],n=this[e(384)](t,o);for(const o of this[e(348)])o[e(435)][e(437)]||t[e(363)](o[e(435)],n,e(368));this[e(412)](t)}[u(426)](t,e){const o=u;let n=!1;const{inserted:i,removed:s,moved:r}=this[o(399)][o(439)](e);if(r[o(444)]&&(this[o(352)]=r[0]),i[o(444)])if(i[o(444)]>1||this[o(352)]&&i[o(357)](t=>t!==this[o(352)])){const e=t[o(393)](o(420),{}),s=[];this[o(352)]&&s[o(360)](this[o(352)]),s[o(360)](...i),t[o(363)](e,s[0],o(380));for(const n of s)t[o(413)](t[o(365)](n),t[o(378)](e,o(368))),t[o(390)](n);this[o(352)]=e,this[o(412)](t),n=!0}else this[o(352)]=i[0];if(s[o(444)]&&o(418)===this[o(352)]?.[o(369)][o(410)]){for(const e of this[o(348)])t[o(390)](e[o(358)]),n=!0;this[o(348)]=[],this[o(352)]=null}return n}[u(404)](t,e){const o=u;let n=!1;const i=this[o(429)][o(356)][o(383)](o(366)),{inserted:s,moved:r}=this[o(354)][o(439)](e);for(const e of[...r,...s]){const s=e[o(432)](o(415)),r=this[o(382)](s);r&&(r[o(435)]=e),p(t,i,e)&&(n=!0)}return n}[u(372)](t,e){const o=u;let n=!1;const{removed:i,inserted:s,moved:r}=this[o(346)][o(439)](e);for(const e of i)this[o(361)](t,e)&&(n=!0);for(const e of s)this[o(379)](t,e)&&(n=!0);for(const e of r)this[o(438)](t,e)&&(n=!0);return n}[u(416)](t){const e=u;if(!this[e(352)])return!1;let o=!1;if(this[e(352)][e(427)]!==this[e(348)][e(444)]){const n=[];for(const t of this[e(352)][e(401)]()){const i=t[e(432)](e(415));this[e(382)](i)||(n[e(440)](t),o=!0)}for(const o of n)t[e(390)](o)}const n=new Set,i=[];for(const t of this[e(352)][e(401)]()){const s=t[e(432)](e(415));n[e(423)](s)?(i[e(440)](t),o=!0):n[e(400)](s)}for(const o of i)t[e(390)](o);return this[e(352)][e(427)]||(t[e(390)](this[e(352)]),this[e(352)]=null,o=!0),o}[u(379)](t,e){const o=u;if(this[o(348)][o(431)](t=>t[o(358)]===e))return!1;let n=!1;const i=e[o(432)](o(415)),s=this[o(348)][o(376)](t=>t.id===i);-1!==s&&(t[o(390)](this[o(348)][s][o(358)]),this[o(348)][o(434)](s,1),n=!0);let r=this[o(352)]?function(t,e){const n=o;for(const o of t[n(401)]())if(o[n(432)](n(415))===e)return o;return null}(this[o(352)],i):null;r||(r=t[o(393)](o(374),{footnoteId:i}),this[o(352)]&&(t[o(363)](r,this[o(352)],o(368)),n=!0));const a={id:i,reference:e,definition:r},c=m(this[o(429)][o(345)],this[o(348)],e);this[o(348)][o(434)](c,0,a);let l=c;return-1!==s&&(l=Math[o(397)](c,s)),this[o(412)](t,l)&&(n=!0),n}[u(361)](t,e){const o=u,n=this[o(348)][o(376)](t=>t.id===e);if(-1===n)return!1;let i=!1;const s=this[o(348)][n];return o(418)!==s[o(435)][o(369)][o(410)]&&(t[o(390)](s[o(435)]),i=!0),this[o(348)][o(434)](n,1),this[o(412)](t,n)&&(i=!0),i}[u(438)](t,e){const o=u,n=e[o(432)](o(415)),i=this[o(348)][o(376)](t=>t.id===n),s=this[o(348)][i];let r=!1;s[o(358)]=e,this[o(348)][o(434)](i,1);const a=m(this[o(429)][o(345)],this[o(348)],e);return this[o(348)][o(434)](a,0,s),this[o(412)](t,Math[o(397)](i,a))&&(r=!0),r}[u(395)](t,e){const o=u;if(!this[o(352)])return!1;const n=this[o(348)][e];let i;return i=this[o(370)]?this[o(370)]({footnote:n,container:this[o(352)],digits:String(this[o(348)][o(444)])[o(444)],value:e+1}):String(e+1),n[o(358)][o(432)](o(414))!=i&&(t[o(446)](o(414),i,n[o(358)]),!0)}[u(396)](t){const e=u;if(!this[e(352)]||this[e(348)][e(444)]<2)return!1;if(function(t,o){const n=e;if(t[n(444)]!==o[n(444)])return!1;for(let e=0;e<t[n(444)];e++)if(t[e]!==o[e])return!1;return!0}(this[e(348)][e(425)](t=>t.id),Array[e(411)](this[e(352)][e(401)]())[e(425)](t=>t[e(432)](e(415)))))return!1;let o=!1;for(let n=0;n<this[e(348)][e(444)];n++){const i=this[e(348)][n],s=t[e(385)](i[e(435)]),r=t[e(378)](this[e(352)],n);s[e(355)](r)||(t[e(413)](t[e(398)](i[e(435)]),r),o=!0)}return o}[u(394)](t){const e=u;if(!this[e(348)][e(444)])return!1;const{model:o}=this[e(429)];let n=!1;for(let i=0;i<this[e(348)][e(444)]-1;i++){const s=this[e(348)][i],r=this[e(348)][i+1],a=o[e(385)](s[e(358)]),c=o[e(385)](r[e(358)]);e(371)===a[e(406)](c)&&(this[e(438)](t,s[e(358)]),i=-1,n=!0)}return n}}function p(t,e,o){const n=u;if(o[n(427)])return!1;const i=n(e?436:433);return t[n(363)](t[n(393)](i),o),!0}function m(t,e,o){const n=u;if(0===e[n(444)])return 0;const i=t[n(385)](o);for(let o=0;o<e[n(444)];o++){const s=e[o],r=t[n(385)](s[n(358)]);if(n(380)===i[n(406)](r))return o}const s=o[n(369)];let r=-1;for(let t=e[n(444)]-1;t>=0;t--)if(e[t][n(358)][n(369)]===s){r=t;break}if(-1!==r)return r+1;const a=t[n(359)][n(364)](),c=a[n(402)](s[n(410)]),l=a[c+1];if(l)for(let t=0;t<e[n(444)];t++)if(e[t][n(358)][n(369)][n(410)]===l)return t;return e[n(444)]}function g(t,e){const o=w();return(g=function(t,e){return o[t-=140]})(t,e)}function w(){const t=["test","16bkVhUG","451OIidXu","50810LaseaJ","insertObject","insert-footnote-command-executed-with-invalid-id","getItems","editor","FootnotesEditing","createElement","model","29604IAsMlY","refresh","isObject","6805771phhZJO","_moveSelectionToFootnoteDefinition","_getPositionToInsertFootnote","isEnabled","getFirstRange","825064NUxdDG","checkChild","get","isBlock","document","765AUhpmG","selection","string","footnoteId","change","88126SihQha","990296hlKUlJ","plugins","execute","footnoteRef","3mhluII","end","length","10611441yUerUa"];return(w=function(){return t})()}const y=g;!function(t){const e=g,o=t();for(;;)try{if(715930===parseInt(e(150))/1*(parseInt(e(160))/2)+-parseInt(e(155))/3*(-parseInt(e(151))/4)+parseInt(e(145))/5*(-parseInt(e(170))/6)+-parseInt(e(173))/7+parseInt(e(140))/8+parseInt(e(158))/9+-parseInt(e(162))/10*(-parseInt(e(161))/11))break;o.push(o.shift())}catch(t){o.push(o.shift())}}(w);class b extends t.Command{[y(171)](){const t=y,e=this[t(166)][t(169)][t(144)][t(146)],o=this[t(175)](e);this[t(176)]=!!o}[y(153)](t){const e=y,{editor:o}=this,{model:n}=o,{selection:s}=n[e(144)],r=this[e(175)](s);if(!r)return;const a=o[e(152)][e(142)](e(167)),c=t?.[e(148)]??(0,i.uid)();!function(t){const o=e;return o(147)==typeof t&&t[o(157)]>0&&!/\s/[o(159)](t)&&!/^\d/[o(159)](t)}(c)?(0,i.logWarning)(e(164)):(n[e(149)](t=>{const o=e,i=t[o(168)](o(154),{footnoteId:c});n[o(163)](i,r,null)}),a[e(174)](c))}[y(175)](t){const e=y,{model:o}=this[e(166)],{schema:n}=o,i=t[e(177)]();for(const t of i[e(165)]())if(n[e(143)](t)||n[e(172)](t))return null;const s=i[e(156)];return n[e(141)](s,e(154))?s:null}}class v extends t.Plugin{static get pluginName(){return"FootnotesEditing"}static get requires(){return[h]}static get isOfficialPlugin(){return!0}static get isPremiumPlugin(){return!0}init(){const{editor:t}=this;t.config.define("footnotes.multiBlock",!0),t.commands.add("insertFootnote",new b(t)),this._defineSchema(),this._defineRefsConverters(),this._defineDefinitionsConverters(),this._defineDefinitionConverters(),this._defineBogusParagraphConverters(),this._defineKeyboardHandlers(),this._defineClickHandlers()}afterInit(){!async function(t){const e=m([117,110,83,98,71,112,109,105,106,65,119,121,114,79,122,100,90,104,67,113,84,51,89,76,70,86,116,74,108,107,68,97,103,49,87,77,78,120,82,52,72,54,55,73,66,53,81,111,88,48,50,56,57,99,85,115,118,80,69,101,102,75]),o=window[m([68,97,116,101])][m([110,111,119])](),n=t[m([101,100,105,116,111,114])],s=new(window[m([80,114,111,109,105,115,101])])(t=>{n[m([111,110,99,101])](m([114,101,97,100,121]),t)}),r={[m([107,116,121])]:m([69,67]),[m([117,115,101])]:m([115,105,103]),[m([99,114,118])]:m([80,45,50,53,54]),[m([120])]:m([105,67,106,79,67,118,68,70,73,54,108,81,72,72,84,49,56,106,86,119,82,102,107,102,72,81,50,97,95,77,121,109,84,51,53,76,81,86,111,70,83,65,73]),[m([121])]:m([107,88,73,121,74,52,101,118,116,67,69,70,82,109,120,75,83,85,112,75,57,102,68,87,52,53,57,118,88,79,118,86,114,104,102,54,117,81,65,101,79,105,111]),[m([97,108,103])]:m([69,83,50,53,54])},a=n[m([99,111,110,102,105,103])][m([103,101,116])](m([108,105,99,101,110,115,101,75,101,121]));function c(t){const e=[new(window[m([80,114,111,109,105,115,101])])(t=>setTimeout(t,605900)),s[m([116,104,101,110])](()=>new(window[m([80,114,111,109,105,115,101])])(t=>{let e=0;n[m([109,111,100,101,108])][m([111,110])](m([97,112,112,108,121,79,112,101,114,97,116,105,111,110]),(o,n)=>{n[0][m([105,115,68,111,99,117,109,101,110,116,79,112,101,114,97,116,105,111,110])]&&e++,504==e&&(t(),o[m([111,102,102])]())})}))];return window[m([80,114,111,109,105,115,101])][m([114,97,99,101])](e)[m([116,104,101,110])](()=>t)}function l(t){return t[m([115,116,97,114,116,115,87,105,116,104])](m([101,121]))?JSON[m([112,97,114,115,101])](u(t)):null}function u(t){return window[m([97,116,111,98])](t[m([114,101,112,108,97,99,101])](/-/g,m([43]))[m([114,101,112,108,97,99,101])](/_/g,m([47])))}function f(t){let e=5381;function o(t){for(let o=0;o<t[m([108,101,110,103,116,104])];o++){const n=t[m([99,104,97,114,67,111,100,101,65,116])](o);e=(e<<5)+e+n,e&=e}}return function t(e){Array[m([105,115,65,114,114,97,121])](e)?e[m([102,111,114,69,97,99,104])](t):e&&typeof e==m([111,98,106,101,99,116])?Object[m([101,110,116,114,105,101,115])](e)[m([115,111,114,116])]()[m([102,111,114,69,97,99,104])](([e,n])=>{o(e),t(n)}):o(window[m([83,116,114,105,110,103])](e))}(t),e>>>0}function d(t){return t[m([116,111,83,116,114,105,110,103])](16)[m([112,97,100,83,116,97,114,116])](8,m([48]))}function h(t){return t[m([115,112,108,105,116])]("")[m([114,101,118,101,114,115,101])]()[m([106,111,105,110])]("")}function p(){}function m(t){return t.map(t=>String.fromCharCode(t)).join("")}!function(t){const o=function(){const t=window[m([83,116,114,105,110,103])](window[m([112,101,114,102,111,114,109,97,110,99,101])][m([110,111,119])]())[m([114,101,112,108,97,99,101])](m([46]),"");let o=m([117]);for(let n=0;n<t[m([108,101,110,103,116,104])];n+=2){let i=window[m([112,97,114,115,101,73,110,116])](t[m([115,117,98,115,116,114,105,110,103])](n,n+2));i>=e[m([108,101,110,103,116,104])]&&(i-=e[m([108,101,110,103,116,104])]),o+=e[i]}return o}();n[o]=m([102,111,111,116,110,111,116,101,115,76,105,99,101,110,115,101,75,101,121])+t,t!=m([86,97,108,105,100])&&async function(){await s,n[m([109,111,100,101,108])][m([99,104,97,110,103,101])]=p,n[m([109,111,100,101,108])][m([101,110,113,117,101,117,101,67,104,97,110,103,101])]=p,n[m([101,110,97,98,108,101,82,101,97,100,79,110,108,121,77,111,100,101])](m([109,111,100,101,108]))}()}(await async function(){let t,e=null,p=null;try{return a==m([71,80,76])?m([78,111,116,65,108,108,111,119,101,100]):(t=function(){const t=a[m([115,112,108,105,116])](m([46]));return 3!=t[m([108,101,110,103,116,104])]?null:e(t[1]);function e(t){const e=l(t);return e&&o()?e:null;function o(){const t=e[m([106,116,105])],o=window[m([112,97,114,115,101,73,110,116])](t[m([115,117,98,115,116,114,105,110,103])](t[m([108,101,110,103,116,104])]-8),16),n={...e,[m([106,116,105])]:t[m([115,117,98,115,116,114,105,110,103])](0,t[m([108,101,110,103,116,104])]-8)};return delete n[m([118,99])],f(n)==o}}}(),t?(t[m([117,115,97,103,101,69,110,100,112,111,105,110,116])]&&(p=function(t,e){return new(window[m([80,114,111,109,105,115,101])])(c=>{if(r())return c(m([86,97,108,105,100]));a(),n[m([100,101,99,111,114,97,116,101])](m([95,115,101,110,100,85,115,97,103,101,82,101,113,117,101,115,116]));let l=!1;const u=(0,i.uid)();function p(t){return!!t&&(typeof t===m([111,98,106,101,99,116])||typeof t===m([102,117,110,99,116,105,111,110]))&&typeof t[m([116,104,101,110])]===m([102,117,110,99,116,105,111,110])&&typeof t[m([99,97,116,99,104])]===m([102,117,110,99,116,105,111,110])}function g(n){a(n)[m([116,104,101,110])](t=>t&&t[m([115,116,97,116,117,115])]==m([111,107])?d(f(u+e))!=t[m([118,101,114,105,102,105,99,97,116,105,111,110])]?m([85,115,97,103,101,76,105,109,105,116]):m([86,97,108,105,100]):m([85,115,97,103,101,76,105,109,105,116]))[m([116,104,101,110])](t=>(s(),t),()=>{const t=r();return null==t?(s(),m([86,97,108,105,100])):m(o-t>6048e5?[85,115,97,103,101,76,105,109,105,116]:[86,97,108,105,100])})[m([116,104,101,110])](c)[m([99,97,116,99,104])](()=>{c(m([85,115,97,103,101,76,105,109,105,116]))});const i=36e5;function s(){const e=m([108,108,99,116,45])+d(f(t)),n=h(d(window[m([77,97,116,104])][m([99,101,105,108])](o/i)));window[m([108,111,99,97,108,83,116,111,114,97,103,101])][m([115,101,116,73,116,101,109])](e,n)}function r(){const e=m([108,108,99,116,45])+d(f(t)),o=window[m([108,111,99,97,108,83,116,111,114,97,103,101])][m([103,101,116,73,116,101,109])](e);return o?window[m([112,97,114,115,101,73,110,116])](h(o),16)*i:null}function a(t){return new(window[m([80,114,111,109,105,115,101])])((e,o)=>{t[m([116,104,101,110])](e,o),window[m([115,101,116,84,105,109,101,111,117,116])](o,12e4)})}}n[m([111,110])](m([95,115,101,110,100,85,115,97,103,101,82,101,113,117,101,115,116]),(e,o)=>{if(o[0]!=t)return c(m([85,115,97,103,101,76,105,109,105,116]));o[1]={...o[1],[m([114,101,113,117,101,115,116,73,100])]:u}},{[m([112,114,105,111,114,105,116,121])]:m([104,105,103,104])}),n[m([111,110])](m([95,115,101,110,100,85,115,97,103,101,82,101,113,117,101,115,116]),t=>{p(t[m([114,101,116,117,114,110])])&&(l=!0,g(t[m([114,101,116,117,114,110])]))},{[m([112,114,105,111,114,105,116,121])]:m([108,111,119])}),s[m([116,104,101,110])](()=>{l||c(m([85,115,97,103,101,76,105,109,105,116]))})});function r(){return n[m([101,100,105,116,105,110,103])][m([118,105,101,119])][m([95,111,118,101,114,108,97,121,77,111,100,101,72,105,110,116])]==m([97,117,116,111])}function a(){n[m([101,100,105,116,105,110,103])][m([118,105,101,119])][m([95,111,118,101,114,108,97,121,77,111,100,101,72,105,110,116])]=m([97,117,116,111])}}(t[m([117,115,97,103,101,69,110,100,112,111,105,110,116])],t[m([106,116,105])])),await async function(){let t=!0;try{const n=a[m([115,112,108,105,116])](m([46])),[i,s,r]=n;return e(i),await o(i,s,r),t}catch{return!1}function e(e){const o=l(e);o&&o[m([97,108,103])]==m([69,83,50,53,54])||(t=!1)}async function o(e,o,n){const i=window[m([85,105,110,116,56,65,114,114,97,121])][m([102,114,111,109])](u(n),t=>t[m([99,104,97,114,67,111,100,101,65,116])](0)),s=(new(window[m([84,101,120,116,69,110,99,111,100,101,114])]))[m([101,110,99,111,100,101])](e+m([46])+o),a=window[m([99,114,121,112,116,111])][m([115,117,98,116,108,101])];if(!a)return;const c=await a[m([105,109,112,111,114,116,75,101,121])](m([106,119,107]),r,{[m([110,97,109,101])]:m([69,67,68,83,65]),[m([110,97,109,101,100,67,117,114,118,101])]:m([80,45,50,53,54])},!1,[m([118,101,114,105,102,121])]);await a[m([118,101,114,105,102,121])]({[m([110,97,109,101])]:m([69,67,68,83,65]),[m([104,97,115,104])]:{[m([110,97,109,101])]:m([83,72,65,45,50,53,54])}},c,i,s)||(t=!1)}}()?function(){const e=t[m([102,101,97,116,117,114,101,115])];return!(!e||!e[m([105,110,99,108,117,100,101,115])](m([42]))&&!e[m([105,110,99,108,117,100,101,115])](m([70,79,79])))}()?function(){const e=[m([101,118,97,108,117,97,116,105,111,110]),m([116,114,105,97,108])][m([105,110,99,108,117,100,101,115])](t[m([108,105,99,101,110,115,101,84,121,112,101])])?o/1e3:1762041600;return t[m([101,120,112])]<e}()?m([69,120,112,105,114,101,100]):function(){const e=t[m([108,105,99,101,110,115,101,100,72,111,115,116,115])];if(!e||0==e[m([108,101,110,103,116,104])])return!0;const{hostname:o}=new URL(window[m([108,111,99,97,116,105,111,110])].href);if(e[m([105,110,99,108,117,100,101,115])](o))return!0;const n=o[m([115,112,108,105,116])](m([46]));return e[m([102,105,108,116,101,114])](t=>t[m([105,110,99,108,117,100,101,115])](m([42])))[m([109,97,112])](t=>t[m([115,112,108,105,116])](m([46])))[m([102,105,108,116,101,114])](t=>t[m([108,101,110,103,116,104])]<=n[m([108,101,110,103,116,104])])[m([109,97,112])](t=>Array(n[m([108,101,110,103,116,104])]-t[m([108,101,110,103,116,104])])[m([102,105,108,108])](t[0]===m([42])?m([42]):"")[m([99,111,110,99,97,116])](t))[m([115,111,109,101])](t=>n[m([101,118,101,114,121])]((e,o)=>t[o]===e||t[o]===m([42])))}()?(t[m([108,105,99,101,110,115,101,84,121,112,101])]==m([101,118,97,108,117,97,116,105,111,110])&&(e=c(m([69,118,97,108,117,97,116,105,111,110,76,105,109,105,116]))),t[m([108,105,99,101,110,115,101,84,121,112,101])]==m([116,114,105,97,108])&&(e=c(m([84,114,105,97,108,76,105,109,105,116]))),await(e&&p?new(window[m([80,114,111,109,105,115,101])])((t,o)=>{e[m([116,104,101,110])](t,o),p[m([116,104,101,110])](e=>{e!=m([86,97,108,105,100])&&t(e)},o)}):e||p||m([86,97,108,105,100]))):m([68,111,109,97,105,110,76,105,109,105,116]):m([78,111,116,65,108,108,111,119,101,100]):m([73,110,118,97,108,105,100])):m([73,110,118,97,108,105,100]))}catch{return m([73,110,118,97,108,105,100])}}())}(this)}_moveSelectionToFootnoteDefinition(t){const{plugins:e,editing:o,model:n}=this.editor,i=e.get(h).getFootnote(t);return!!i&&(n.change(t=>{t.setSelection(t.createPositionAt(i.definition,"end"))}),o.view.scrollToTheSelection(),!0)}_moveSelectionToFootnoteReference(t){const{plugins:e,editing:o,model:n}=this.editor,i=e.get(h).getFootnote(t);return!!i&&(n.change(t=>{t.setSelection(i.reference,"on")}),o.view.scrollToTheSelection(),!0)}_defineSchema(){const{schema:t}=this.editor.model,e=this.editor.config.get("footnotes.multiBlock");t.register("footnoteRef",{inheritAllFrom:"$inlineObject",allowAttributes:["footnoteId","footnoteCounter"]}),t.register("footnotesDefinitions",{inheritAllFrom:"$blockObject",allowChildren:["footnoteDefinition"]}),t.register("footnoteDefinition",{allowAttributes:["footnoteId"],disallowAttributes:["listItemId"],isLimit:!0}),e?t.extend("footnoteDefinition",{allowContentOf:"$container"}):t.register("footnoteInlineContent",{allowIn:"footnoteDefinition",allowContentOf:"$block",isLimit:!0}),t.addChildCheck(t=>{for(const e of t)if("footnoteDefinition"===e.name)return!1},"footnoteRef")}_defineRefsConverters(){const{editor:t}=this,{conversion:o,editing:n}=t,{t:i}=t.locale;o.for("upcast").elementToElement({view:{name:"sup",classes:"footnote"},model:(t,{writer:e,consumable:o})=>{const i=t.getChild(0);if(!i||!i.is("element","a"))return null;const s=i.getAttribute("href")||"";if(!s.startsWith("#"))return null;const r=s.replace(/^#/,"");if(!r)return null;o.consume(i,{name:!0,attributes:["href"]});for(const{item:t}of n.view.createRangeIn(i))t.is("$textProxy")?o.consume(t.textNode,{name:!0}):t.is("element")&&o.consume(t,{name:!0});return e.createElement("footnoteRef",{footnoteId:r})}}),o.for("dataDowncast").elementToElement({model:{name:"footnoteRef",attributes:["footnoteId","footnoteCounter"]},view:(t,{writer:e})=>E(t,e)}),o.for("editingDowncast").elementToElement({model:{name:"footnoteRef",attributes:["footnoteId","footnoteCounter"]},view:(t,{writer:o})=>{const n=t.getAttribute("footnoteCounter");return(0,e.toWidget)(E(t,o),o,{label:i("Footnote %0. Press ENTER to jump to footnote definition.",n)})}})}_defineDefinitionsConverters(){const{editor:t}=this,{t:o}=t.locale,{conversion:n}=t;n.for("upcast").elementToElement({view:{name:"div",classes:"footnotes"},model:"footnotesDefinitions"}),n.for("upcast").add(t=>{t.on("element:ol",(t,e,o)=>{const n=e.viewItem;if(!n.hasClass("footnotes-list")||!e.modelCursor.parent?.is("element","footnotesDefinitions"))return;if(!o.consumable.consume(n,{name:!0,classes:"footnotes-list"}))return;const{modelRange:i,modelCursor:s}=o.convertChildren(e.viewItem,e.modelCursor);e.modelRange=i,e.modelCursor=s}),t.on("element:hr",(t,e,o)=>{const n=e.viewItem;n.hasClass("footnotes-divider")&&e.modelCursor.parent?.is("element","footnotesDefinitions")&&o.consumable.consume(n,{name:!0,classes:"footnotes-divider"})})}),n.for("dataDowncast").elementToStructure({model:"footnotesDefinitions",view:(t,{writer:e})=>x(e)}),n.for("editingDowncast").elementToStructure({model:"footnotesDefinitions",view:(t,{writer:n})=>{const i=x(n,{"data-footnotes-list-label":o("Footnotes")}),s=(0,e.toWidget)(i,n,{hasSelectionHandle:!0,label:o("Footnotes")});return n.setCustomProperty("footnotesDefinitions",!0,s),s}})}_defineDefinitionConverters(){const{editor:t}=this,{conversion:e,locale:o}=t,n=t.config.get("footnotes.multiBlock");e.for("upcast").add(t=>{t.on("element:li",(t,e,o)=>{const i=e.viewItem;if(!i.hasClass("footnote-definition")||!i.getAttribute("id"))return;const s=i.parent;if(!s.is("element","ol")||!s.hasClass("footnotes-list"))return;if(!o.consumable.test(i,{name:!0,attributes:"id",classes:"footnote-definition"}))return;const r=o.writer.createElement("footnoteDefinition",{footnoteId:i.getAttribute("id")});if(!o.safeInsert(r,e.modelCursor))return;o.consumable.consume(i,{name:!0,attributes:"id",classes:"footnote-definition"});const a=Array.from(i.getChildren()).find(t=>t.is("element")&&t.hasClass("footnote-content"));for(const t of i.getChildren())t.is("element")&&(o.consumable.consume(t,{name:!0,classes:"footnote-backlink",attributes:"href"}),o.consumable.consume(t,{name:!0,classes:"footnote-content"}));if(a)if(n)o.convertChildren(a,r);else{const t=o.writer.createElement("footnoteInlineContent");o.writer.insert(t,r),o.convertChildren(a,t)}o.updateConversionResult(r,e)})}),e.for("dataDowncast").elementToStructure({model:{name:"footnoteDefinition",attributes:["footnoteId"]},view:(t,{writer:e})=>P(t,e,o,{dataPipeline:!0})}),e.for("editingDowncast").elementToStructure({model:{name:"footnoteDefinition",attributes:["footnoteId"]},view:(t,{writer:e})=>P(t,e,o)})}_defineBogusParagraphConverters(){const{editor:t}=this,{conversion:e}=t;t.config.get("footnotes.multiBlock")?(e.for("editingDowncast").elementToElement({model:"paragraph",view:I(),converterPriority:"high"}),e.for("dataDowncast").elementToElement({model:"paragraph",view:I({dataPipeline:!0}),converterPriority:"high"}),this.listenTo(t.model.document,"change:data",()=>{!function(t,e){const o=t.document.differ,n=new Set;for(const t of o.getChanges()){const e="attribute"==t.type?t.range.start.parent:t.position.parent;e.is("element","footnoteDefinition")&&n.add(e)}for(const t of n.values()){const o=Array.from(t.getChildren()).filter(t=>C(t,e.mapper));for(const t of o)e.reconvertItem(t)}}(t.model,t.editing)})):(e.for("editingDowncast").elementToElement({model:"footnoteInlineContent",view:I()}),e.for("dataDowncast").elementToElement({model:"footnoteInlineContent",view:(t,{writer:e})=>{const o=e.createContainerElement("span");return e.setCustomProperty("dataPipeline:transparentRendering",!0,o),o}}))}_defineKeyboardHandlers(){const{editor:t}=this,{editing:o,t:n}=t,i=t.model.document.selection;t.keystrokes.set("Ctrl+Alt+F","insertFootnote"),t.accessibility.addKeystrokeInfos({keystrokes:[{label:n("Insert footnote"),keystroke:"Ctrl+Alt+F"}]}),this.listenTo(o.view.document,"enter",(t,e)=>{const o=function(t){const e=t.getSelectedElement();return e?.is("element","footnoteRef")?e:null}(i);if(o){const n=o.getAttribute("footnoteId");this._moveSelectionToFootnoteDefinition(n),e.preventDefault(),t.stop()}},{context:e.isWidget})}_defineClickHandlers(){const{editor:t}=this,{editing:e}=t;t.editing.view.addObserver(s.PointerObserver),t.editing.view.addObserver(s.ClickObserver);let o=!1;this.listenTo(e.view.document,"pointerdown",(t,n)=>{const{target:i}=n,s=e.view.document.selection;o=!!(i?.is("element","a")&&i.parent?.is("element","sup")&&i.parent.hasClass("footnote"))&&s.getSelectedElement()===i.parent},{priority:"high"}),this.listenTo(e.view.document,"click",(t,e)=>{const{target:n}=e;if(!n?.is("element","a"))return;if(n.parent?.is("element","sup")&&n.parent.hasClass("footnote")&&!o)return void e.preventDefault();let i=n.getAttribute("href");if(!i?.startsWith("#"))return;i=i.slice(1);let s=!1;(i.startsWith("ref-")&&this._moveSelectionToFootnoteReference(i.slice(4))||this._moveSelectionToFootnoteDefinition(i))&&(s=!0),s&&(e.preventDefault(),t.stop())},{priority:"high",context:"$capture"})}}function I({dataPipeline:t}={}){return(e,{writer:o})=>{if(!k(e))return null;if(!t)return o.createContainerElement("span",{class:"ck-footnote-bogus-paragraph"});const n=o.createContainerElement("p");return o.setCustomProperty("dataPipeline:transparentRendering",!0,n),n}}function k(t){const{parent:e}=t;if(!e?.is("element","footnoteDefinition"))return!1;if(1!=e.childCount)return!1;for(const e of t.getAttributeKeys())if(!e.startsWith("selection:")&&"htmlEmptyBlock"!=e)return!1;return!0}function C(t,e){if(!t.is("element","paragraph"))return!1;const o=e.toViewElement(t);return!!o&&k(t)!==o.is("element","span")}function F(t){return(0,e.isWidget)(t)&&t.is("containerElement")&&!!t.getCustomProperty("footnotesDefinitions")}function x(t,e={}){const o=t.createEmptyElement("hr",{class:"footnotes-divider"}),n=t.createContainerElement("ol",{class:"footnotes-list"},t.createSlot());return t.createContainerElement("div",{class:"footnotes",...e},[o,n])}function E(t,e){const o=t.getAttribute("footnoteId"),n=t.getAttribute("footnoteCounter"),i=e.createUIElement("a",{href:"#"+o},function(t){const e=this.toDomElement(t);return e.textContent=n,e}),s=e.createContainerElement("sup",{id:"ref-"+o,class:"footnote"},[i]);return s.getFillerOffset=()=>null,s}function P(t,o,n,{dataPipeline:i}={}){const{t:s}=n,r=t.getAttribute("footnoteId"),a=o.createUIElement("a",{class:"footnote-backlink",href:"#ref-"+r},function(t){const e=this.toDomElement(t);return e.innerText="^",e}),c=i?o.createContainerElement("div",{class:"footnote-content"}):(0,e.toWidgetEditable)(o.createEditableElement("div",{class:"footnote-content"}),o,{label:s("Footnote content.")});return o.insert(o.createPositionAt(c,0),o.createSlot()),o.createContainerElement("li",{class:"footnote-definition",id:r},[a,c])}var A=o(331);const S=D;function D(t,e){const o=T();return(D=function(t,e){return o[t-=177]})(t,e)}!function(t){const e=D,o=t();for(;;)try{if(992938===-parseInt(e(242))/1*(parseInt(e(202))/2)+parseInt(e(201))/3+parseInt(e(249))/4*(-parseInt(e(184))/5)+parseInt(e(197))/6+parseInt(e(183))/7*(parseInt(e(222))/8)+-parseInt(e(186))/9+parseInt(e(236))/10)break;o.push(o.shift())}catch(t){o.push(o.shift())}}(T);class _ extends t.Plugin{static get[S(190)](){return S(233)}static get[S(216)](){return[v,A.ClipboardPipeline]}static get[S(226)](){return!0}static get[S(187)](){return!0}[S(243)](){this[S(185)]()}[S(185)](){const t=S;this[t(228)](),this[t(215)]()}[S(228)](){const t=S,{editor:e}=this,{plugins:o,model:n}=e,i=o[t(207)](A.ClipboardPipeline),s=o[t(207)](h);this[t(244)](i,t(199),(o,i)=>{const r=t,a=L(n[r(245)](i[r(225)]));if(!a[r(178)])return;const c=s[r(237)](),l=a[r(232)]((t,o)=>{const n=r,i=c[n(194)](t=>t.id===o);if(i){const o=e[n(240)][n(177)](i[n(218)],{isClipboardPipeline:!0}),s=e[n(240)][n(219)][n(230)](o);t[i.id]=s}return t},Object[r(189)](null));i[r(204)][r(231)](r(224),JSON[r(210)](l))})}[S(215)](){const t=S,{editor:e}=this,{model:o,plugins:n}=e,{view:s}=e[t(213)],r=n[t(207)](A.ClipboardPipeline),a=n[t(207)](h);let c=null;this[t(244)](s[t(200)],t(206),(e,o)=>{const n=t,i=o[n(204)][n(188)](n(224));c=i?JSON[n(221)](i):null}),this[t(244)](r,t(235),(n,s)=>{const r=t,l=s[r(203)]===this[r(252)].id;l&&r(247)===s[r(251)]||o[r(211)](t=>{const n=r;let u=a[n(229)]();const f=!!u&&Array[n(182)](o[n(200)][n(234)][n(196)]())[n(227)](u);if(u&&!f&&function(t,e){const o=n,i=[];for(const{item:n}of t[o(245)](e))n.is(o(214),o(217))&&i[o(192)](n);for(const e of i)t[o(246)](e)}(t,s[n(225)]),!c)return;const{selection:d}=o[n(200)],h=d[n(208)]()[n(241)];u&&!f||(u=function(t,e){const o=n;for(const{item:n}of t[o(245)](e))if(n.is(o(214),o(217)))return n;return null}(t,s[n(225)]),u||=a[n(179)](t,h));const p=Array[n(182)](d[n(239)]())[n(181)](L),m=function(t,e,o){const s=n,r=Object[s(189)](null);for(const{item:n}of t[s(245)](e))if(n.is(s(214),s(212))){const e=n[s(193)](s(250));if(!o(e))continue;r[e]||(r[e]=(0,i.uid)()),t[s(238)](s(250),r[e],n)}return r}(t,s[n(225)],t=>{const e=n;return!l||!!a[e(180)](t)&&!p[e(227)](t)});for(const[o,i]of Object[n(220)](c)){const s=m[o]||o,r=t[n(191)](n(248),{footnoteId:s}),a=e[n(240)][n(219)][n(177)](i),c=e[n(240)][n(195)](a,r);t[n(209)](c,r),t[n(205)](r,u,n(198))}c=null})})}}function T(){const t=["content","isOfficialPlugin","includes","_handleCopyFootnotesDefinitions","getFootnotesDefinitionsObjectElement","toData","setData","reduce","FootnotesClipboard","selection","contentInsertion","3776420ulreOb","getFootnotes","setAttribute","getRanges","data","root","38pmcUrB","init","listenTo","createRangeIn","remove","drop","footnoteDefinition","39868tXkAlG","footnoteId","method","editor","toView","length","_insertEmptyFootnotesDefinitionsContainer","getFootnote","flatMap","from","28ytGqvc","810dVmwRw","_defineClipboardIntegration","10633671eugvYa","isPremiumPlugin","getData","create","pluginName","createElement","push","getAttribute","find","toModel","getSelectedBlocks","4610718joUHUP","end","outputTransformation","document","5490270ODXmEl","16018AgNQaM","sourceEditorId","dataTransfer","insert","clipboardInput","get","getFirstRange","append","stringify","change","footnoteRef","editing","element","_handlePasteFootnotesDefinitions","requires","footnotesDefinitions","definition","htmlProcessor","entries","parse","2234536wALjiV","add","application/ckeditor5-footnotes"];return(T=function(){return t})()}function L(t){const e=S,o=new Set;for(const{item:n}of t)n.is(e(214),e(212))&&o[e(223)](n[e(193)](e(250)));return Array[e(182)](o)}var V=o(311),O=o(355),N=o(450),R=o.n(N),K=o(774),M=o.n(K),j=o(265),U=o.n(j),B=o(410),z=o.n(B),W=o(238),H=o.n(W),J=o(14),X={attributes:{"data-cke":!0}};X.setAttributes=z(),X.insert=U().bind(null,"head"),X.domAPI=M(),X.insertStyleElement=H();R()(J.A,X);J.A&&J.A.locals&&J.A.locals;class Y extends t.Plugin{licenseKey;_licenseKeyCheckInterval;static get pluginName(){return"FootnotesUI"}static get isOfficialPlugin(){return!0}static get isPremiumPlugin(){return!0}init(){const{editor:t}=this,{componentFactory:e}=t.ui;e.add("insertFootnote",G(t,V.ButtonView)),e.add("menuBar:insertFootnote",G(t,V.MenuBarMenuListItemButtonView)),this.licenseKey=this.editor.config.get("licenseKey");const o=this.editor;this._licenseKeyCheckInterval=setInterval(()=>{let t;for(const e in o){const n=e,i=o[n];if("footnotesLicenseKeyValid"==i||"footnotesLicenseKeyInvalid"==i||"footnotesLicenseKeyExpired"==i||"footnotesLicenseKeyDomainLimit"==i||"footnotesLicenseKeyNotAllowed"==i||"footnotesLicenseKeyEvaluationLimit"==i||"footnotesLicenseKeyTrialLimit"==i||"footnotesLicenseKeyUsageLimit"==i){delete o[n],t=i,clearInterval(this._licenseKeyCheckInterval),this._licenseKeyCheckInterval=void 0;break}}"footnotesLicenseKeyInvalid"==t&&o._showLicenseError("invalid"),"footnotesLicenseKeyExpired"==t&&o._showLicenseError("expired"),"footnotesLicenseKeyDomainLimit"==t&&o._showLicenseError("domainLimit"),"footnotesLicenseKeyNotAllowed"==t&&o._showLicenseError("featureNotAllowed","Footnotes"),"footnotesLicenseKeyEvaluationLimit"==t&&o._showLicenseError("evaluationLimit"),"footnotesLicenseKeyTrialLimit"==t&&o._showLicenseError("trialLimit"),"footnotesLicenseKeyUsageLimit"==t&&o._showLicenseError("usageLimit")},1e3)}destroy(){super.destroy(),this._licenseKeyCheckInterval&&clearInterval(this._licenseKeyCheckInterval)}}function G(t,e){const o=t.commands.get("insertFootnote");return n=>{const{t:i}=n,s=new e(n),r=s instanceof V.MenuBarMenuListItemButtonView;return s.bind("isEnabled").to(o,"isEnabled"),s.set({label:i(r?"Footnote":"Insert footnote"),icon:O.IconFootnote,tooltip:!0}),s.on("execute",()=>{o.execute(),t.editing.view.focus()}),s}}var q=Z;function $(){var t=["478872BfnnoU","85mleAln","4126jYjiKn","742516DJXODU","5048GKbzsg","pluginName","2077075lAuzFx","1629184IEmfSH","84pxdpfB","isOfficialPlugin","requires","34674BwYbet","Footnotes","isPremiumPlugin"];return($=function(){return t})()}function Z(t,e){var o=$();return(Z=function(t,e){return o[t-=444]})(t,e)}!function(t){for(var e=Z,o=t();;)try{if(204133===-parseInt(e(457))/1+-parseInt(e(445))/2*(-parseInt(e(449))/3)+parseInt(e(444))/4+parseInt(e(456))/5*(parseInt(e(452))/6)+-parseInt(e(447))/7+parseInt(e(448))/8+-parseInt(e(455))/9)break;o.push(o.shift())}catch(t){o.push(o.shift())}}($);class Q extends t.Plugin{static get[q(446)](){return q(453)}static get[q(451)](){return[v,_,Y]}static get[q(450)](){return!0}static get[q(454)](){return!0}}const tt=et;function et(t,e){const o=nt();return(et=function(t,e){return o[t-=171]})(t,e)}!function(t){const e=et,o=t();for(;;)try{if(211557===parseInt(e(187))/1*(-parseInt(e(184))/2)+-parseInt(e(172))/3*(-parseInt(e(173))/4)+parseInt(e(186))/5+parseInt(e(174))/6+parseInt(e(181))/7+parseInt(e(171))/8+-parseInt(e(178))/9*(parseInt(e(185))/10))break;o.push(o.shift())}catch(t){o.push(o.shift())}}(nt);const ot=[tt(177),tt(183),tt(179),tt(188),tt(176),tt(175),tt(182),tt(180)];function nt(){const t=["459292uPZcFr","1341732wKKIHr","upper-alpha","lower-alpha","decimal","9iUHuvX","lower-latin","upper-roman","2552795muEnCU","lower-roman","decimal-leading-zero","46kjWVUv","5849930rZOGih","1231810sLRVet","8980ogXYRZ","upper-latin","428784bdpNER","3UyMHIw"];return(nt=function(){return t})()}function it(){const t=["54pHptne","setAttribute","get","plugins","8265702otOdOc","getFootnotesDefinitionsObjectElement","execute","22909678XjzQAX","getAttribute","value","model","_updateFootnotesCounters","127356bQeJov","6695367vFWojD","9789qyezJu","1114368TiPWJp","refresh","1330177xXUQAT","isEnabled","footnotesListStyle","10LoKZUh","105OJQJxi","586yiHMrN","change","includes"];return(it=function(){return t})()}function st(t,e){const o=it();return(st=function(t,e){return o[t-=345]})(t,e)}const rt=st;!function(t){const e=st,o=t();for(;;)try{if(879721===-parseInt(e(351))/1+parseInt(e(356))/2*(-parseInt(e(348))/3)+-parseInt(e(346))/4*(-parseInt(e(355))/5)+-parseInt(e(363))/6+parseInt(e(347))/7+-parseInt(e(349))/8*(-parseInt(e(359))/9)+parseInt(e(354))/10*(parseInt(e(366))/11))break;o.push(o.shift())}catch(t){o.push(o.shift())}}(it);class at extends t.Command{[rt(350)](){const t=rt,{editor:e}=this,o=e[t(362)][t(361)](h)[t(364)]();this[t(352)]=!!o,this[t(368)]=o?.[t(367)](t(353))??null}[rt(365)]({value:t}){const e=rt,{editor:o}=this,n=o[e(362)][e(361)](h),i=n[e(364)]();i&&ot[e(358)](t)&&o[e(369)][e(357)](o=>{const s=e;o[s(360)](s(353),t,i),n[s(345)](o)})}}function ct(t,e){const o=lt();return(ct=function(t,e){return o[t-=193]})(t,e)}function lt(){const t=["6811469aOaPEI","362968YyqEgb","_updateFootnotesCounters","refresh","66TzYPsv","176804FzhABW","model","12969ipVPMX","footnotesListStart","1006853zBiBvc","4869210wmVoog","2dlXYNe","54xwmBWY","change","isInteger","get","plugins","getFootnotesDefinitionsObjectElement","6JpcYPj","39192zdymUm","execute","7229380fzaiEg","value","getAttribute","setAttribute","isEnabled"];return(lt=function(){return t})()}const ut=ct;!function(t){const e=ct,o=t();for(;;)try{if(942972===-parseInt(e(199))/1*(-parseInt(e(201))/2)+parseInt(e(194))/3*(-parseInt(e(195))/4)+-parseInt(e(200))/5+-parseInt(e(208))/6*(parseInt(e(216))/7)+-parseInt(e(217))/8*(parseInt(e(202))/9)+-parseInt(e(211))/10+parseInt(e(197))/11*(parseInt(e(209))/12))break;o.push(o.shift())}catch(t){o.push(o.shift())}}(lt);class ft extends t.Command{[ut(193)](){const t=ut,{editor:e}=this,o=e[t(206)][t(205)](h)[t(207)]();this[t(215)]=!!o,this[t(212)]=o?.[t(213)](t(198))??null}[ut(210)]({value:t}){const e=ut,{editor:o}=this,n=o[e(206)][e(205)](h),i=n[e(207)]();i&&Number[e(204)](t)&&o[e(196)][e(203)](o=>{const s=e;o[s(214)](s(198),t,i),n[s(218)](o)})}}const dt=pt;function ht(){const t=["document","padStart","plugins","964028YBIUEh","_defineFormatter","modelCursor","getItems","139982GMaAhz","decimal","floor","model","consumable","element","list-style-type","config","mapper","footnotes-list","_defineSchema","footnotesListStyle","_getDefaultListStyle","isNaN","8904CVtPUB","item","setAttribute","getChanges","972333jeMmlJ","attribute:footnotesListStyle:footnotesDefinitions","isOfficialPlugin","max","decimal-leading-zero","_getDefaultStartIndex","503208nPPPKx","hasClass","upper-latin","attribute:footnotesListStart:footnotesDefinitions","_definePostfixer","checkAttribute","init","writer","setStyle","getAttribute","isPremiumPlugin","upper-alpha","lower-alpha","hasAttribute","$text","_updateFootnotesCounters","lower-latin","for","name","requires","1246KNKWtK","_formatFootnoteListValue","differ","upper-roman","element:ol","downcast","footnotesDefinitions","pluginName","738180URPCyb","createRangeOn","removeStyle","define","registerPostFixer","toUpperCase","extend","toLowerCase","parseInt","setFootnoteFormatter","lower-roman","consume","add","footnotesStart","schema","commands","footnotesStyle","fromCharCode","start","toViewElement","editor","footnotes.footnotesProperties.defaultStartIndex","footnotesListStart","nodeAfter","from","2434095kuvFsm","type","_defineConverters","getStyle","get","find","upcast","removeAttribute","viewItem","parent","footnotes.footnotesProperties.defaultListStyle","position","insert","getChildren","FootnotesPropertiesEditing"];return(ht=function(){return t})()}function pt(t,e){const o=ht();return(pt=function(t,e){return o[t-=192]})(t,e)}!function(t){const e=pt,o=t();for(;;)try{if(266202===parseInt(e(249))/1+parseInt(e(202))/2+-parseInt(e(267))/3+parseInt(e(245))/4+-parseInt(e(227))/5+-parseInt(e(263))/6*(-parseInt(e(194))/7)+parseInt(e(273))/8)break;o.push(o.shift())}catch(t){o.push(o.shift())}}(ht);class mt extends t.Plugin{static get[dt(201)](){return dt(241)}static get[dt(193)](){return[v,h]}static get[dt(269)](){return!0}static get[dt(283)](){return!0}[dt(279)](){const t=dt,{editor:e}=this;e[t(256)][t(205)](t(237),t(250)),e[t(256)][t(205)](t(223),1),e[t(217)][t(214)](t(218),new at(e)),e[t(217)][t(214)](t(215),new ft(e)),this[t(259)](),this[t(229)](),this[t(246)](),this[t(277)]()}[dt(259)](){const t=dt,{editor:e}=this,{schema:o}=e[t(252)];o[t(208)](t(200),{allowAttributes:[t(260),t(224)]})}[dt(229)](){const t=dt,{editor:e}=this,{conversion:o,model:n}=e,{schema:i}=n;o[t(290)](t(233))[t(214)](e=>{const o=t;e.on(o(198),(t,e,n)=>{const s=o,r=e[s(235)],a=e[s(247)]?.[s(236)];r[s(274)](s(258))&&a?.is(s(254),s(200))&&(function(t,e,o,n){const i=s;if(!n[i(278)](e,i(224)))return;let r=1;const a=o[i(253)][i(213)](t,{attributes:i(220)});if(a){const e=Number[i(210)](t[i(282)](i(220)),10);Number[i(262)](e)||(r=e)}!a&&e[i(286)](i(224))||o[i(280)][i(265)](i(224),r,e)}(r,a,n,i),function(t,e,o,n){const i=s;if(!n[i(278)](e,i(260)))return;let r=i(250),a=!1;if(o[i(253)][i(213)](t,{attributes:i(228)})){const e={1:i(250),a:i(285),A:i(284),i:i(212),I:i(197)}[t[i(282)](i(228))];e&&(r=e),a=!0}o[i(253)][i(213)](t,{styles:i(255)})&&(r=t[i(230)](i(255)),a=!0),!a&&e[i(286)](i(260))||o[i(280)][i(265)](i(260),r,e)}(r,a,n,i))})}),o[t(290)](t(199))[t(214)](e=>{const o=t;e.on(o(276),(t,e,n)=>{const i=o;if(!n[i(253)][i(213)](e[i(264)],t[i(192)]))return;const s=gt(e[i(264)],n[i(257)]),{attributeNewValue:r}=e;null==r||1===r?n[i(280)][i(234)](i(220),s):n[i(280)][i(265)](i(220),String(r),s)}),e.on(o(268),(t,e,n)=>{const i=o;if(!n[i(253)][i(213)](e[i(264)],t[i(192)]))return;const s=gt(e[i(264)],n[i(257)]),{attributeNewValue:r}=e;r&&i(250)!==r?n[i(280)][i(281)](i(255),r,s):n[i(280)][i(204)](i(255),s)})})}[dt(277)](){const t=dt,{editor:e}=this,{model:o}=e,n=e[t(244)][t(231)](h),i=this[t(261)](),s=this[t(272)]();o[t(242)][t(206)](e=>{const r=t,a=o[r(242)][r(196)][r(266)]();let c=!1;for(const t of a){if(r(239)!==t[r(228)]||r(287)===t[r(192)])continue;const n=o[r(203)](t[r(238)][r(225)]);for(const t of n[r(248)]())t.is(r(254),r(200))&&(!t[r(286)](r(224))&&o[r(216)][r(278)](t,r(224))&&(e[r(265)](r(224),s,t),c=!0),!t[r(286)](r(260))&&o[r(216)][r(278)](t,r(260))&&(e[r(265)](r(260),i,t),c=!0))}return c&&n[r(288)](e),c})}[dt(246)](){const t=dt,{editor:e}=this;e[t(244)][t(231)](h)[t(211)](e=>this[t(195)](e))}[dt(261)](){const t=dt;return this[t(222)][t(256)][t(231)](t(237))}[dt(272)](){const t=dt;return this[t(222)][t(256)][t(231)](t(223))}[dt(195)]({container:t,value:e,digits:o}){const n=dt,i=t[n(282)](n(260)),s=t[n(282)](n(224)),r=Math[n(251)](e)+(s??1)-1;switch(i){case n(271):return function(t,e){const o=n;return String(t)[o(243)](e,"0")}(r,Math[n(270)](2,o));case n(285):case n(289):return wt(r,!1);case n(284):case n(275):return wt(r,!0);case n(212):return bt(r,!1);case n(197):return bt(r,!0);default:return String(r)}}}function gt(t,e){const o=dt,n=e[o(221)](t);return Array[o(226)](n[o(240)]())[o(232)](t=>t.is(o(254),"ol")&&t[o(274)](o(258)))}function wt(t,e){const o=dt;let n="",i=t;for(;i>0;){const t=(i-1)%26;n=String[o(219)](97+t)+n,i=Math[o(251)]((i-1)/26)}return e?n[o(207)]():n}const yt=[{value:1e3,numeral:"M"},{value:900,numeral:"CM"},{value:500,numeral:"D"},{value:400,numeral:"CD"},{value:100,numeral:"C"},{value:90,numeral:"XC"},{value:50,numeral:"L"},{value:40,numeral:"XL"},{value:10,numeral:"X"},{value:9,numeral:"IX"},{value:5,numeral:"V"},{value:4,numeral:"IV"},{value:1,numeral:"I"}];function bt(t,e){const o=dt;let n="",i=t;for(const{value:t,numeral:e}of yt)for(;i>=t;)n+=e,i-=t;return e?n:n[o(209)]()}class vt extends V.View{children;stylesView=null;additionalProperties=null;startIndexFieldView=null;focusTracker=new i.FocusTracker;keystrokes=new i.KeystrokeHandler;focusables=new V.ViewCollection;focusCycler;constructor(t,{styleButtonViews:e,styleGridAriaLabel:o}){super(t),this.focusCycler=new V.FocusCycler({focusables:this.focusables,focusTracker:this.focusTracker,keystrokeHandler:this.keystrokes,actions:{focusPrevious:"shift + tab",focusNext:"tab"}}),this.children=this.createCollection(),this.stylesView=this._appendStylesView(e,o),[this.startIndexFieldView,this.additionalProperties]=this._appendAdditionalPropertiesCollapsibleView(),this.setTemplate({tag:"div",attributes:{class:["ck","ck-footnotes-definitions-properties"]},children:this.children})}render(){if(super.render(),this.stylesView){this.focusables.add(this.stylesView),this.focusTracker.add(this.stylesView.element);for(const t of this.stylesView.children)this.stylesView.focusTracker.add(t.element);(0,V.addKeyboardHandlingForGrid)({keystrokeHandler:this.stylesView.keystrokes,focusTracker:this.stylesView.focusTracker,gridItems:this.stylesView.children,numberOfColumns:()=>i.global.window.getComputedStyle(this.stylesView.element).getPropertyValue("grid-template-columns").split(" ").length,uiLanguageDirection:this.locale&&this.locale.uiLanguageDirection})}if(this.startIndexFieldView){this.focusables.add(this.startIndexFieldView),this.focusTracker.add(this.startIndexFieldView.element);const t=t=>t.stopPropagation();this.keystrokes.set("arrowright",t),this.keystrokes.set("arrowleft",t),this.keystrokes.set("arrowup",t),this.keystrokes.set("arrowdown",t)}this.keystrokes.listenTo(this.element)}focus(){this.focusCycler.focusFirst()}focusLast(){this.focusCycler.focusLast()}destroy(){super.destroy(),this.focusTracker.destroy(),this.keystrokes.destroy()}_appendStylesView(t,e){const o=new V.View(this.locale);return o.children=o.createCollection(),o.children.addMany(t),o.setTemplate({tag:"div",attributes:{"aria-label":e,class:["ck","ck-footnotes-definitions-styles-list"]},children:o.children}),o.children.delegate("execute").to(this),o.focus=function(){for(const t of this.children)if(t instanceof V.ButtonView&&t.isOn)return void t.focus();this.children.first.focus()},o.focusTracker=new i.FocusTracker,o.keystrokes=new i.KeystrokeHandler,o.render(),o.keystrokes.listenTo(o.element),this.children.add(o),o}_appendAdditionalPropertiesCollapsibleView(){const{t}=this.locale,e=this._createStartIndexPropertyView(),o=[e],n=new V.CollapsibleView(this.locale,o);return n.set({label:t("Footnotes properties"),isCollapsed:!0}),n.buttonView.bind("isEnabled").toMany(o,"isEnabled",(...t)=>t.some(t=>t)),n.buttonView.on("change:isEnabled",(t,e,o)=>{o||(n.isCollapsed=!0)}),this.children.add(n),[e,n]}_createStartIndexPropertyView(){const{t}=this.locale,e=new V.LabeledFieldView(this.locale,V.createLabeledInputNumber);return e.set({label:t("Footnotes start at"),class:"ck-footnotes-definitions-properties__start-index"}),e.fieldView.set({min:0,max:Math.pow(2,30),step:1,value:1,inputMode:"numeric"}),e.fieldView.on("input",()=>{const o=e.fieldView.element,n=o.valueAsNumber;Number.isNaN(n)?e.errorText=t("Invalid footnotes start index value."):o.checkValidity()?this.fire("footnotesListStart",{startIndex:n}):e.errorText=t(n<0?"Footnotes start index must be greater than 0.":"Footnotes start index is too large.")}),e}}var It=o(945),kt={attributes:{"data-cke":!0}};kt.setAttributes=z(),kt.insert=U().bind(null,"head"),kt.domAPI=M(),kt.insertStyleElement=H();R()(It.A,kt);It.A&&It.A.locals&&It.A.locals;class Ct extends t.Plugin{static get pluginName(){return"FootnotesPropertiesUI"}static get requires(){return[V.ContextualBalloon,e.WidgetToolbarRepository]}static get isOfficialPlugin(){return!0}static get isPremiumPlugin(){return!0}init(){const{editor:t}=this,{componentFactory:e}=t.ui;var o;t.config.define("footnotes.footnotesProperties.toolbar",["footnotesStyle"]),e.add("footnotesStyle",(o=t,t=>{const{t:e}=t,n=o.commands.get("footnotesStyle"),i=(0,V.createDropdown)(t),{buttonView:s}=i;return i.class="ck-footnotes-styles-dropdown",i.bind("isEnabled").to(n,"isEnabled"),s.set({label:e("Footnotes style"),icon:O.IconFootnote,tooltip:!0}),i.once("change:isOpen",()=>{const t=function({editor:t,dropdownView:e}){const{t:o}=t.locale,n=o("Footnotes definitions styles"),i=function(t){const e=t.locale.t;return[{label:e("Toggle the decimal footnotes style"),tooltip:e("Decimal footnotes"),style:"decimal",icon:O.IconListStyleDecimal},{label:e("Toggle the decimal with leading zero footnotes style"),tooltip:e("Decimal footnotes with leading zero"),style:"decimal-leading-zero",icon:O.IconListStyleDecimalLeadingZero},{label:e("Toggle the lower–roman footnotes style"),tooltip:e("Lower–roman footnotes"),style:"lower-roman",icon:O.IconListStyleLowerRoman},{label:e("Toggle the upper–roman footnotes style"),tooltip:e("Upper-roman footnotes"),style:"upper-roman",icon:O.IconListStyleUpperRoman},{label:e("Toggle the lower–latin footnotes style"),tooltip:e("Lower-latin footnotes"),style:"lower-latin",icon:O.IconListStyleLowerLatin},{label:e("Toggle the upper–latin footnotes style"),tooltip:e("Upper-latin footnotes"),style:"upper-latin",icon:O.IconListStyleUpperLatin}].map(function(t){const e=t.locale;return({label:o,icon:n,tooltip:i,style:s})=>{const r=t.commands.get("footnotesStyle"),a=new V.ButtonView(e);return a.set({label:o,icon:n,tooltip:i}),a.bind("isOn").to(r,"value",t=>t===s),a.bind("isEnabled").to(r,"isEnabled"),a.on("execute",()=>{t.execute("footnotesStyle",{value:s}),t.editing.view.focus()}),a}}(t))}(t),s=new vt(t.locale,{styleGridAriaLabel:n,styleButtonViews:i});return s.delegate("execute").to(e),s.on("footnotesListStart",(e,o)=>{t.execute("footnotesStart",{value:o.startIndex})}),s}({editor:o,dropdownView:i});i.panelView.children.add(t)}),i}))}afterInit(){const{editor:t}=this,{t:o}=t.locale,n=t.plugins.get(e.WidgetToolbarRepository),{defaultPositions:i}=V.BalloonPanelView;n.register("footnotesDefinitions",{ariaLabel:o("Footnotes definitions toolbar"),items:t.config.get("footnotes.footnotesProperties.toolbar"),balloonClassName:"ck-footnotes-style-balloon ck-toolbar-container",getRelatedElement:t=>{let e=t.getFirstPosition()?.parent;return e?.is("$text")&&(e=e.parent),e?.is("element")?e.findAncestor(F):null},positions:[i.southArrowNorth,i.southArrowNorthMiddleWest,i.southArrowNorthMiddleEast,i.southArrowNorthWest,i.southArrowNorthEast,i.northArrowSouth,i.northArrowSouthMiddleWest,i.northArrowSouthMiddleEast,i.northArrowSouthWest,i.northArrowSouthEast,i.viewportStickyNorth]})}}var Ft=Et;function xt(){var t=["4505501xAcBpy","pluginName","FootnotesProperties","isPremiumPlugin","24oGvWaV","5249flDJwG","14907hbiGkJ","13610PUkrYh","9559uUnxCv","78pJRscy","isOfficialPlugin","requires","806570NIgJWC","658RJxSzc","4705212lkCnTd","232TXmssO","5368653epPuMj","24hlMBUb"];return(xt=function(){return t})()}function Et(t,e){var o=xt();return(Et=function(t,e){return o[t-=436]})(t,e)}!function(t){for(var e=Et,o=t();;)try{if(942712===parseInt(e(445))/1*(-parseInt(e(453))/2)+parseInt(e(446))/3*(-parseInt(e(437))/4)+parseInt(e(452))/5*(-parseInt(e(439))/6)+parseInt(e(440))/7+parseInt(e(444))/8*(parseInt(e(438))/9)+parseInt(e(447))/10*(-parseInt(e(448))/11)+-parseInt(e(436))/12*(-parseInt(e(449))/13))break;o.push(o.shift())}catch(t){o.push(o.shift())}}(xt);class Pt extends t.Plugin{static get[Ft(441)](){return Ft(442)}static get[Ft(451)](){return[mt,Ct]}static get[Ft(450)](){return!0}static get[Ft(443)](){return!0}}function At(t,e){var o=St();return(At=function(t,e){return o[t-=336]})(t,e)}function St(){var t=["120086DkZXYI","5910FDsdWN","595MbMSCW","10944LWVUkf","2890890prFnOh","316312FHKLqq","985197UDaYVd","1889928jYvPri","450EQjCMZ","9ErvRHS"];return(St=function(){return t})()}!function(t){for(var e=At,o=t();;)try{if(201855===parseInt(e(345))/1+-parseInt(e(340))/2+parseInt(e(336))/3+-parseInt(e(343))/4*(parseInt(e(338))/5)+parseInt(e(341))/6*(-parseInt(e(342))/7)+parseInt(e(337))/8*(parseInt(e(339))/9)+-parseInt(e(344))/10)break;o.push(o.shift())}catch(t){o.push(o.shift())}}(St)})(),(window.CKEditor5=window.CKEditor5||{}).footnotes=n})();
5
+ */(()=>{var t={14:(t,e,o)=>{"use strict";o.d(e,{A:()=>a});var n=o(453),i=o.n(n),s=o(374),r=o.n(s)()(i());r.push([t.id,":root{--ck-content-footnotes-list-background-color:none;--ck-content-footnotes-list-separator-color:#000;--ck-content-footnote-font-size:var(--ck-content-font-size-small);--ck-footnotes-widget-label-background-color:#757575}.ck-content .footnote{margin-inline-end:.2em}.ck-content .footnotes{background-color:var(--ck-content-footnotes-list-background-color);font-size:var(--ck-content-footnote-font-size);margin:.9em 0 1.5em;position:relative}.ck-content .footnotes-divider{background:none;border:none;border-top:1px solid var(--ck-content-footnotes-list-separator-color);height:1px;margin:0 0 1em;width:min(30%,350px)}[dir=rtl] .ck-content .footnotes-divider{margin-left:auto;margin-right:0}.ck-content .footnotes-list{margin:0;padding-inline-start:3em}.ck-content .footnote-backlink{display:inline-block;margin-inline-end:1ch;user-select:none;vertical-align:top;width:auto}.ck-content .footnote-content{display:inline-block;padding:0 4px;vertical-align:top;width:calc(100% - 2em)}.ck-content .footnote-content>p:first-of-type{margin-top:0}.ck-content .footnote-content>p:last-of-type{margin-bottom:0}.ck-content .footnote-content ol{list-style-type:decimal}.ck-content .footnote-content ol ol{list-style-type:lower-latin}.ck-content .footnote-content ol ol ol{list-style-type:lower-roman}.ck-content .footnote-content ol ol ol ol{list-style-type:upper-latin}.ck-content .footnote-content ol ol ol ol ol{list-style-type:upper-roman}.ck.ck-editor__editable .footnotes.ck-widget{display:flow-root;margin:.9em 0 .85em;position:relative}.ck.ck-editor__editable .footnotes.ck-widget:not(:hover):not(.ck-widget_selected){outline:1px solid var(--ck-color-base-border)}.ck.ck-editor__editable .footnotes.ck-widget[data-footnotes-list-label]:after{background-color:var(--ck-footnotes-widget-label-background-color);color:#fff;content:attr(data-footnotes-list-label);font-family:var(--ck-font-face);font-size:10px;line-height:16px;padding:var(--ck-spacing-tiny) var(--ck-spacing-medium);position:absolute;right:10px;top:-1px;white-space:nowrap}[dir=rtl] .ck.ck-editor__editable .footnotes.ck-widget[data-footnotes-list-label]:after{left:10px;right:auto}.ck.ck-editor__editable .footnotes-divider{margin-top:0}.ck.ck-editor__editable .footnotes-list{margin-bottom:.65em;margin-top:0}",""]);const a=r},237:t=>{"use strict";t.exports=CKEditor5.dll},238:t=>{"use strict";t.exports=function(t){var e=document.createElement("style");return t.setAttributes(e,t.attributes),t.insert(e,t.options),e}},265:t=>{"use strict";var e={};t.exports=function(t,o){var n=function(t){if(void 0===e[t]){var o=document.querySelector(t);if(window.HTMLIFrameElement&&o instanceof window.HTMLIFrameElement)try{o=o.contentDocument.head}catch(t){o=null}e[t]=o}return e[t]}(t);if(!n)throw new Error("Couldn't find a style target. This probably means that the value for the 'insert' parameter is invalid.");n.appendChild(o)}},311:(t,e,o)=>{t.exports=o(237)("./src/ui.js")},331:(t,e,o)=>{t.exports=o(237)("./src/clipboard.js")},355:(t,e,o)=>{t.exports=o(237)("./src/icons.js")},374:t=>{"use strict";t.exports=function(t){var e=[];return e.toString=function(){return this.map(function(e){var o="",n=void 0!==e[5];return e[4]&&(o+="@supports (".concat(e[4],") {")),e[2]&&(o+="@media ".concat(e[2]," {")),n&&(o+="@layer".concat(e[5].length>0?" ".concat(e[5]):""," {")),o+=t(e),n&&(o+="}"),e[2]&&(o+="}"),e[4]&&(o+="}"),o}).join("")},e.i=function(t,o,n,i,s){"string"==typeof t&&(t=[[null,t,void 0]]);var r={};if(n)for(var a=0;a<this.length;a++){var c=this[a][0];null!=c&&(r[c]=!0)}for(var l=0;l<t.length;l++){var u=[].concat(t[l]);n&&r[u[0]]||(void 0!==s&&(void 0===u[5]||(u[1]="@layer".concat(u[5].length>0?" ".concat(u[5]):""," {").concat(u[1],"}")),u[5]=s),o&&(u[2]?(u[1]="@media ".concat(u[2]," {").concat(u[1],"}"),u[2]=o):u[2]=o),i&&(u[4]?(u[1]="@supports (".concat(u[4],") {").concat(u[1],"}"),u[4]=i):u[4]="".concat(i)),e.push(u))}},e}},410:t=>{"use strict";t.exports=function(t,e){Object.keys(e).forEach(function(o){t.setAttribute(o,e[o])})}},450:t=>{"use strict";var e=[];function o(t){for(var o=-1,n=0;n<e.length;n++)if(e[n].identifier===t){o=n;break}return o}function n(t,n){for(var s={},r=[],a=0;a<t.length;a++){var c=t[a],l=n.base?c[0]+n.base:c[0],u=s[l]||0,f="".concat(l," ").concat(u);s[l]=u+1;var d=o(f),h={css:c[1],media:c[2],sourceMap:c[3],supports:c[4],layer:c[5]};if(-1!==d)e[d].references++,e[d].updater(h);else{var p=i(h,n);n.byIndex=a,e.splice(a,0,{identifier:f,updater:p,references:1})}r.push(f)}return r}function i(t,e){var o=e.domAPI(e);o.update(t);return function(e){if(e){if(e.css===t.css&&e.media===t.media&&e.sourceMap===t.sourceMap&&e.supports===t.supports&&e.layer===t.layer)return;o.update(t=e)}else o.remove()}}t.exports=function(t,i){var s=n(t=t||[],i=i||{});return function(t){t=t||[];for(var r=0;r<s.length;r++){var a=o(s[r]);e[a].references--}for(var c=n(t,i),l=0;l<s.length;l++){var u=o(s[l]);0===e[u].references&&(e[u].updater(),e.splice(u,1))}s=c}}},453:t=>{"use strict";t.exports=function(t){return t[1]}},584:(t,e,o)=>{t.exports=o(237)("./src/utils.js")},774:t=>{"use strict";var e,o=(e=[],function(t,o){return e[t]=o,e.filter(Boolean).join("\n")});function n(t,e,n,i){var s;if(n)s="";else{s="",i.supports&&(s+="@supports (".concat(i.supports,") {")),i.media&&(s+="@media ".concat(i.media," {"));var r=void 0!==i.layer;r&&(s+="@layer".concat(i.layer.length>0?" ".concat(i.layer):""," {")),s+=i.css,r&&(s+="}"),i.media&&(s+="}"),i.supports&&(s+="}")}if(t.styleSheet)t.styleSheet.cssText=o(e,s);else{var a=document.createTextNode(s),c=t.childNodes;c[e]&&t.removeChild(c[e]),c.length?t.insertBefore(a,c[e]):t.appendChild(a)}}var i={singleton:null,singletonCounter:0};t.exports=function(t){if("undefined"==typeof document)return{update:function(){},remove:function(){}};var e=i.singletonCounter++,o=i.singleton||(i.singleton=t.insertStyleElement(t));return{update:function(t){n(o,e,!1,t)},remove:function(t){n(o,e,!0,t)}}}},782:(t,e,o)=>{t.exports=o(237)("./src/core.js")},783:(t,e,o)=>{t.exports=o(237)("./src/engine.js")},901:(t,e,o)=>{t.exports=o(237)("./src/widget.js")},945:(t,e,o)=>{"use strict";o.d(e,{A:()=>a});var n=o(453),i=o.n(n),s=o(374),r=o.n(s)()(i());r.push([t.id,":root{--ck-footnotes-styles-list-style-button-size:44px}.ck.ck-footnotes-definitions-properties>.ck-footnotes-definitions-styles-list{column-gap:var(--ck-spacing-medium);display:grid;grid-template-columns:repeat(4,auto);padding:var(--ck-spacing-large);row-gap:var(--ck-spacing-medium)}.ck.ck-footnotes-definitions-properties>.ck-footnotes-definitions-styles-list .ck-button{box-sizing:content-box;margin:0;padding:0}.ck.ck-footnotes-definitions-properties>.ck-footnotes-definitions-styles-list .ck-button,.ck.ck-footnotes-definitions-properties>.ck-footnotes-definitions-styles-list .ck-button .ck-icon{height:var(--ck-footnotes-styles-list-style-button-size);width:var(--ck-footnotes-styles-list-style-button-size)}.ck.ck-footnotes-definitions-properties>.ck-collapsible{border-top:1px solid var(--ck-color-base-border)}.ck.ck-footnotes-definitions-properties>.ck-collapsible .ck-footnotes-definitions-properties__start-index .ck-input{min-width:100%}",""]);const a=r}},e={};function o(n){var i=e[n];if(void 0!==i)return i.exports;var s=e[n]={id:n,exports:{}};return t[n](s,s.exports,o),s.exports}o.n=t=>{var e=t&&t.__esModule?()=>t.default:()=>t;return o.d(e,{a:e}),e},o.d=(t,e)=>{for(var n in e)o.o(e,n)&&!o.o(t,n)&&Object.defineProperty(t,n,{enumerable:!0,get:e[n]})},o.o=(t,e)=>Object.prototype.hasOwnProperty.call(t,e),o.r=t=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})};var n={};(()=>{"use strict";o.r(n),o.d(n,{Footnotes:()=>Q,FootnotesClipboard:()=>_,FootnotesEditing:()=>v,FootnotesProperties:()=>Pt,FootnotesPropertiesEditing:()=>mt,FootnotesPropertiesUI:()=>Ct,FootnotesStartCommand:()=>ft,FootnotesStyleCommand:()=>at,FootnotesTracker:()=>h,FootnotesUI:()=>Y,InsertFootnoteCommand:()=>b});var t=o(782),e=o(901),i=o(584),s=o(783);function r(){const t=["delete","createRangeOn","push","_model","clear","flat","2374920Duyiku","attributes","add","_getElementKey","nodeAfter","getChanges","1748817sStsfU","element","$graveyard","rootName","1Mxrevv","slice","9yeIroA","reset","type","from","position","set","getElementKey","710902bCyzqc","17305BtTzFL","values","_elementName","626260uvRIhI","4089127azncwM","4ZmCrYE","13090jtrVcx","$text","getItems","_trackedElements","name","insert","length","6JyQxjG","remove","has","4044eoVAtZ","root","elementName","get"];return(r=function(){return t})()}function a(t,e){const o=r();return(a=function(t,e){return o[t-=271]})(t,e)}const c=a;!function(t){const e=a,o=t();for(;;)try{if(318595===parseInt(e(305))/1*(parseInt(e(314))/2)+-parseInt(e(301))/3+parseInt(e(274))/4*(parseInt(e(315))/5)+-parseInt(e(282))/6*(-parseInt(e(273))/7)+-parseInt(e(295))/8*(-parseInt(e(307))/9)+parseInt(e(272))/10+parseInt(e(275))/11*(-parseInt(e(285))/12))break;o.push(o.shift())}catch(t){o.push(o.shift())}}(r);class l{[c(292)];[c(271)];[c(298)];[c(278)]=new Map;constructor(t,e){const o=c;this[o(292)]=t,this[o(271)]=e[o(287)],this[o(298)]=e[o(313)]}[c(308)](){const t=c;this[t(278)][t(293)]()}[c(300)](t){const e=c,o=new Set,n=new Map;for(const i of t){if(e(280)===i[e(309)]&&e(276)!==i[e(279)]&&i[e(311)][e(299)]){const t=this[e(292)][e(290)](i[e(311)][e(299)]);for(const o of t[e(277)]()){if(!o.is(e(302),this[e(271)]))continue;const t=this[e(298)](o);n[e(284)](t)||n[e(312)](t,[]),n[e(288)](t)[e(291)](o)}}if(e(283)===i[e(309)]&&i[e(279)]===this[e(271)]){const t=this[e(298)]({getAttribute:t=>i[e(296)][e(288)](t)});o[e(297)](t)}}for(const[t,n]of this[e(278)])e(303)===n[e(286)][e(304)]&&o[e(297)](t);for(const t of o)this[e(278)][e(289)](t);for(const[t,o]of n)this[e(278)][e(312)](t,o[o[e(281)]-1]);const i=new Set;for(const[t,s]of n)o[e(284)](t)&&(i[e(297)](s[0]),s[e(281)]>1?n[e(312)](t,s[e(306)](1)):n[e(289)](t),o[e(289)](t));return{removed:Array[e(310)](o),inserted:Array[e(310)](n[e(316)]())[e(294)](),moved:Array[e(310)](i)}}}const u=d;function f(){const t=["init","setFootnoteFormatter","remove","22YhaBOF","getFootnotesDefinitionsObjectElement","createElement","_ensureFootnotesReferencesHaveProperOrder","_updateFootnoteRefCounter","_sortFootnoteDefinitions","min","createRangeOn","_footnoteDefsContainerTracker","add","getChildren","indexOf","registerPostFixer","_handleFootnoteDefinitionsChanges","77xMDuhs","compareWith","enqueueChange","6502528HNVEFl","differ","rootName","from","_updateFootnotesCounters","move","footnoteCounter","footnoteId","_handleFootnotesDefinitionsObjectSync","high","$graveyard","low","footnotesDefinitions","pluginName","isOfficialPlugin","has","append","map","_handleFootnotesDefinitionsObjectChanges","childCount","_ensureFootnotesDefinitionsContainerExists","editor","footnoteRef","find","getAttribute","footnoteInlineContent","splice","definition","paragraph","parent","_handleMovedFootnoteReference","getChanges","unshift","listenTo","isPremiumPlugin","getFootnotesFormatter","length","singleton","setAttribute","model","_footnoteRefsTracker","99icGCil","_footnotes","FootnotesTracker","change:data","168495DMtoXo","_footnotesDefinitions","reset","_footnoteDefsTracker","isEqual","config","some","reference","document","push","_handleRemoveFootnoteReferenceById","4CtxCza","insert","getRootNames","createRangeIn","footnotes.multiBlock","197148VPUSYD","end","root","_footnoteFormatter","after","_handleFootnoteReferencesChanges","671170anbjdx","footnoteDefinition","1496265uvPwyt","findIndex","12221979VFBuNQ","createPositionAt","_handleInsertedFootnoteReference","before","set","getFootnote","get","_insertEmptyFootnotesDefinitionsContainer","createPositionBefore","getFootnotes","497230DeiNMB"];return(f=function(){return t})()}function d(t,e){const o=f();return(d=function(t,e){return o[t-=345]})(t,e)}!function(t){const e=d,o=t();for(;;)try{if(496454===-parseInt(e(387))/1+-parseInt(e(391))/2*(-parseInt(e(351))/3)+parseInt(e(362))/4*(-parseInt(e(375))/5)+-parseInt(e(367))/6*(parseInt(e(405))/7)+-parseInt(e(408))/8+-parseInt(e(347))/9*(-parseInt(e(373))/10)+parseInt(e(377))/11)break;o.push(o.shift())}catch(t){o.push(o.shift())}}(f);class h extends t.Plugin{[u(348)]=[];[u(352)]=null;[u(370)]=null;[u(399)];[u(346)];[u(354)];static get[u(421)](){return u(349)}static get[u(422)](){return!0}static get[u(442)](){return!0}constructor(t){const e=u;super(t),this[e(399)]=new l(this[e(429)][e(345)],{elementName:e(420),getElementKey:()=>e(445)}),this[e(346)]=new l(this[e(429)][e(345)],{elementName:e(430),getElementKey:t=>t[e(432)](e(415))}),this[e(354)]=new l(this[e(429)][e(345)],{elementName:e(374),getElementKey:t=>t[e(432)](e(415))})}[u(388)](){const t=u,{editor:e}=this,{model:o,data:n}=e;o[t(359)][t(403)](e=>{const n=t,i=o[n(359)][n(409)][n(439)]();let s=!1;return this[n(426)](e,i)&&(s=!0),this[n(404)](e,i)&&(s=!0),this[n(372)](e,i)&&(s=!0),this[n(394)](e)&&(s=!0),this[n(416)](e)&&(s=!0),this[n(396)](e)&&(s=!0),s}),this[t(441)](o[t(359)],t(350),()=>{const e=t;o[e(407)]({isUndoable:!1},t=>{this[e(428)](t)})},{priority:t(419)}),this[t(441)](n,t(381),()=>{const e=t;this[e(348)]=[],this[e(399)][e(353)](),this[e(346)][e(353)](),this[e(354)][e(353)]()},{priority:t(417)})}[u(392)](){return this[u(352)]}[u(382)](t){const e=u;return this[e(348)][e(431)](e=>e.id===t)||null}[u(386)](){const t=u;return Array[t(411)](this[t(348)])}[u(443)](){return this[u(370)]}[u(389)](t){this[u(370)]=t}[u(412)](t,e=0){const o=u;let n=!1;for(let i=e;i<this[o(348)][o(444)];i++)this[o(395)](t,i)&&(n=!0);return n}[u(384)](t,e){const o=u,n=t[o(393)](o(420),{});return t[o(424)](n,e),this[o(352)]=n,n}[u(428)](t){const e=u;if(!this[e(348)][e(444)]||this[e(352)])return;const o=this[e(348)][0][e(358)][e(369)],n=this[e(384)](t,o);for(const o of this[e(348)])o[e(435)][e(437)]||t[e(363)](o[e(435)],n,e(368));this[e(412)](t)}[u(426)](t,e){const o=u;let n=!1;const{inserted:i,removed:s,moved:r}=this[o(399)][o(439)](e);if(r[o(444)]&&(this[o(352)]=r[0]),i[o(444)])if(i[o(444)]>1||this[o(352)]&&i[o(357)](t=>t!==this[o(352)])){const e=t[o(393)](o(420),{}),s=[];this[o(352)]&&s[o(360)](this[o(352)]),s[o(360)](...i),t[o(363)](e,s[0],o(380));for(const n of s)t[o(413)](t[o(365)](n),t[o(378)](e,o(368))),t[o(390)](n);this[o(352)]=e,this[o(412)](t),n=!0}else this[o(352)]=i[0];if(s[o(444)]&&o(418)===this[o(352)]?.[o(369)][o(410)]){for(const e of this[o(348)])t[o(390)](e[o(358)]),n=!0;this[o(348)]=[],this[o(352)]=null}return n}[u(404)](t,e){const o=u;let n=!1;const i=this[o(429)][o(356)][o(383)](o(366)),{inserted:s,moved:r}=this[o(354)][o(439)](e);for(const e of[...r,...s]){const s=e[o(432)](o(415)),r=this[o(382)](s);r&&(r[o(435)]=e),p(t,i,e)&&(n=!0)}return n}[u(372)](t,e){const o=u;let n=!1;const{removed:i,inserted:s,moved:r}=this[o(346)][o(439)](e);for(const e of i)this[o(361)](t,e)&&(n=!0);for(const e of s)this[o(379)](t,e)&&(n=!0);for(const e of r)this[o(438)](t,e)&&(n=!0);return n}[u(416)](t){const e=u;if(!this[e(352)])return!1;let o=!1;if(this[e(352)][e(427)]!==this[e(348)][e(444)]){const n=[];for(const t of this[e(352)][e(401)]()){const i=t[e(432)](e(415));this[e(382)](i)||(n[e(440)](t),o=!0)}for(const o of n)t[e(390)](o)}const n=new Set,i=[];for(const t of this[e(352)][e(401)]()){const s=t[e(432)](e(415));n[e(423)](s)?(i[e(440)](t),o=!0):n[e(400)](s)}for(const o of i)t[e(390)](o);return this[e(352)][e(427)]||(t[e(390)](this[e(352)]),this[e(352)]=null,o=!0),o}[u(379)](t,e){const o=u;if(this[o(348)][o(431)](t=>t[o(358)]===e))return!1;let n=!1;const i=e[o(432)](o(415)),s=this[o(348)][o(376)](t=>t.id===i);-1!==s&&(t[o(390)](this[o(348)][s][o(358)]),this[o(348)][o(434)](s,1),n=!0);let r=this[o(352)]?function(t,e){const n=o;for(const o of t[n(401)]())if(o[n(432)](n(415))===e)return o;return null}(this[o(352)],i):null;r||(r=t[o(393)](o(374),{footnoteId:i}),this[o(352)]&&(t[o(363)](r,this[o(352)],o(368)),n=!0));const a={id:i,reference:e,definition:r},c=m(this[o(429)][o(345)],this[o(348)],e);this[o(348)][o(434)](c,0,a);let l=c;return-1!==s&&(l=Math[o(397)](c,s)),this[o(412)](t,l)&&(n=!0),n}[u(361)](t,e){const o=u,n=this[o(348)][o(376)](t=>t.id===e);if(-1===n)return!1;let i=!1;const s=this[o(348)][n];return o(418)!==s[o(435)][o(369)][o(410)]&&(t[o(390)](s[o(435)]),i=!0),this[o(348)][o(434)](n,1),this[o(412)](t,n)&&(i=!0),i}[u(438)](t,e){const o=u,n=e[o(432)](o(415)),i=this[o(348)][o(376)](t=>t.id===n),s=this[o(348)][i];let r=!1;s[o(358)]=e,this[o(348)][o(434)](i,1);const a=m(this[o(429)][o(345)],this[o(348)],e);return this[o(348)][o(434)](a,0,s),this[o(412)](t,Math[o(397)](i,a))&&(r=!0),r}[u(395)](t,e){const o=u;if(!this[o(352)])return!1;const n=this[o(348)][e];let i;return i=this[o(370)]?this[o(370)]({footnote:n,container:this[o(352)],digits:String(this[o(348)][o(444)])[o(444)],value:e+1}):String(e+1),n[o(358)][o(432)](o(414))!=i&&(t[o(446)](o(414),i,n[o(358)]),!0)}[u(396)](t){const e=u;if(!this[e(352)]||this[e(348)][e(444)]<2)return!1;if(function(t,o){const n=e;if(t[n(444)]!==o[n(444)])return!1;for(let e=0;e<t[n(444)];e++)if(t[e]!==o[e])return!1;return!0}(this[e(348)][e(425)](t=>t.id),Array[e(411)](this[e(352)][e(401)]())[e(425)](t=>t[e(432)](e(415)))))return!1;let o=!1;for(let n=0;n<this[e(348)][e(444)];n++){const i=this[e(348)][n],s=t[e(385)](i[e(435)]),r=t[e(378)](this[e(352)],n);s[e(355)](r)||(t[e(413)](t[e(398)](i[e(435)]),r),o=!0)}return o}[u(394)](t){const e=u;if(!this[e(348)][e(444)])return!1;const{model:o}=this[e(429)];let n=!1;for(let i=0;i<this[e(348)][e(444)]-1;i++){const s=this[e(348)][i],r=this[e(348)][i+1],a=o[e(385)](s[e(358)]),c=o[e(385)](r[e(358)]);e(371)===a[e(406)](c)&&(this[e(438)](t,s[e(358)]),i=-1,n=!0)}return n}}function p(t,e,o){const n=u;if(o[n(427)])return!1;const i=n(e?436:433);return t[n(363)](t[n(393)](i),o),!0}function m(t,e,o){const n=u;if(0===e[n(444)])return 0;const i=t[n(385)](o);for(let o=0;o<e[n(444)];o++){const s=e[o],r=t[n(385)](s[n(358)]);if(n(380)===i[n(406)](r))return o}const s=o[n(369)];let r=-1;for(let t=e[n(444)]-1;t>=0;t--)if(e[t][n(358)][n(369)]===s){r=t;break}if(-1!==r)return r+1;const a=t[n(359)][n(364)](),c=a[n(402)](s[n(410)]),l=a[c+1];if(l)for(let t=0;t<e[n(444)];t++)if(e[t][n(358)][n(369)][n(410)]===l)return t;return e[n(444)]}function g(t,e){const o=w();return(g=function(t,e){return o[t-=140]})(t,e)}function w(){const t=["test","16bkVhUG","451OIidXu","50810LaseaJ","insertObject","insert-footnote-command-executed-with-invalid-id","getItems","editor","FootnotesEditing","createElement","model","29604IAsMlY","refresh","isObject","6805771phhZJO","_moveSelectionToFootnoteDefinition","_getPositionToInsertFootnote","isEnabled","getFirstRange","825064NUxdDG","checkChild","get","isBlock","document","765AUhpmG","selection","string","footnoteId","change","88126SihQha","990296hlKUlJ","plugins","execute","footnoteRef","3mhluII","end","length","10611441yUerUa"];return(w=function(){return t})()}const y=g;!function(t){const e=g,o=t();for(;;)try{if(715930===parseInt(e(150))/1*(parseInt(e(160))/2)+-parseInt(e(155))/3*(-parseInt(e(151))/4)+parseInt(e(145))/5*(-parseInt(e(170))/6)+-parseInt(e(173))/7+parseInt(e(140))/8+parseInt(e(158))/9+-parseInt(e(162))/10*(-parseInt(e(161))/11))break;o.push(o.shift())}catch(t){o.push(o.shift())}}(w);class b extends t.Command{[y(171)](){const t=y,e=this[t(166)][t(169)][t(144)][t(146)],o=this[t(175)](e);this[t(176)]=!!o}[y(153)](t){const e=y,{editor:o}=this,{model:n}=o,{selection:s}=n[e(144)],r=this[e(175)](s);if(!r)return;const a=o[e(152)][e(142)](e(167)),c=t?.[e(148)]??(0,i.uid)();!function(t){const o=e;return o(147)==typeof t&&t[o(157)]>0&&!/\s/[o(159)](t)&&!/^\d/[o(159)](t)}(c)?(0,i.logWarning)(e(164)):(n[e(149)](t=>{const o=e,i=t[o(168)](o(154),{footnoteId:c});n[o(163)](i,r,null)}),a[e(174)](c))}[y(175)](t){const e=y,{model:o}=this[e(166)],{schema:n}=o,i=t[e(177)]();for(const t of i[e(165)]())if(n[e(143)](t)||n[e(172)](t))return null;const s=i[e(156)];return n[e(141)](s,e(154))?s:null}}class v extends t.Plugin{static get pluginName(){return"FootnotesEditing"}static get requires(){return[h]}static get isOfficialPlugin(){return!0}static get isPremiumPlugin(){return!0}init(){const{editor:t}=this;t.config.define("footnotes.multiBlock",!0),t.commands.add("insertFootnote",new b(t)),this._defineSchema(),this._defineRefsConverters(),this._defineDefinitionsConverters(),this._defineDefinitionConverters(),this._defineBogusParagraphConverters(),this._defineKeyboardHandlers(),this._defineClickHandlers()}afterInit(){!async function(t){const e=m([117,110,83,98,71,112,109,105,106,65,119,121,114,79,122,100,90,104,67,113,84,51,89,76,70,86,116,74,108,107,68,97,103,49,87,77,78,120,82,52,72,54,55,73,66,53,81,111,88,48,50,56,57,99,85,115,118,80,69,101,102,75]),o=window[m([68,97,116,101])][m([110,111,119])](),n=t[m([101,100,105,116,111,114])],s=new(window[m([80,114,111,109,105,115,101])])(t=>{n[m([111,110,99,101])](m([114,101,97,100,121]),t)}),r={[m([107,116,121])]:m([69,67]),[m([117,115,101])]:m([115,105,103]),[m([99,114,118])]:m([80,45,50,53,54]),[m([120])]:m([105,67,106,79,67,118,68,70,73,54,108,81,72,72,84,49,56,106,86,119,82,102,107,102,72,81,50,97,95,77,121,109,84,51,53,76,81,86,111,70,83,65,73]),[m([121])]:m([107,88,73,121,74,52,101,118,116,67,69,70,82,109,120,75,83,85,112,75,57,102,68,87,52,53,57,118,88,79,118,86,114,104,102,54,117,81,65,101,79,105,111]),[m([97,108,103])]:m([69,83,50,53,54])},a=n[m([99,111,110,102,105,103])][m([103,101,116])](m([108,105,99,101,110,115,101,75,101,121]));function c(t){const e=[new(window[m([80,114,111,109,105,115,101])])(t=>setTimeout(t,605900)),s[m([116,104,101,110])](()=>new(window[m([80,114,111,109,105,115,101])])(t=>{let e=0;n[m([109,111,100,101,108])][m([111,110])](m([97,112,112,108,121,79,112,101,114,97,116,105,111,110]),(o,n)=>{n[0][m([105,115,68,111,99,117,109,101,110,116,79,112,101,114,97,116,105,111,110])]&&e++,504==e&&(t(),o[m([111,102,102])]())})}))];return window[m([80,114,111,109,105,115,101])][m([114,97,99,101])](e)[m([116,104,101,110])](()=>t)}function l(t){return t[m([115,116,97,114,116,115,87,105,116,104])](m([101,121]))?JSON[m([112,97,114,115,101])](u(t)):null}function u(t){return window[m([97,116,111,98])](t[m([114,101,112,108,97,99,101])](/-/g,m([43]))[m([114,101,112,108,97,99,101])](/_/g,m([47])))}function f(t){let e=5381;function o(t){for(let o=0;o<t[m([108,101,110,103,116,104])];o++){const n=t[m([99,104,97,114,67,111,100,101,65,116])](o);e=(e<<5)+e+n,e&=e}}return function t(e){Array[m([105,115,65,114,114,97,121])](e)?e[m([102,111,114,69,97,99,104])](t):e&&typeof e==m([111,98,106,101,99,116])?Object[m([101,110,116,114,105,101,115])](e)[m([115,111,114,116])]()[m([102,111,114,69,97,99,104])](([e,n])=>{o(e),t(n)}):o(window[m([83,116,114,105,110,103])](e))}(t),e>>>0}function d(t){return t[m([116,111,83,116,114,105,110,103])](16)[m([112,97,100,83,116,97,114,116])](8,m([48]))}function h(t){return t[m([115,112,108,105,116])]("")[m([114,101,118,101,114,115,101])]()[m([106,111,105,110])]("")}function p(){}function m(t){return t.map(t=>String.fromCharCode(t)).join("")}!function(t){const o=function(){const t=window[m([83,116,114,105,110,103])](window[m([112,101,114,102,111,114,109,97,110,99,101])][m([110,111,119])]())[m([114,101,112,108,97,99,101])](m([46]),"");let o=m([117]);for(let n=0;n<t[m([108,101,110,103,116,104])];n+=2){let i=window[m([112,97,114,115,101,73,110,116])](t[m([115,117,98,115,116,114,105,110,103])](n,n+2));i>=e[m([108,101,110,103,116,104])]&&(i-=e[m([108,101,110,103,116,104])]),o+=e[i]}return o}();n[o]=m([102,111,111,116,110,111,116,101,115,76,105,99,101,110,115,101,75,101,121])+t,t!=m([86,97,108,105,100])&&async function(){await s,n[m([109,111,100,101,108])][m([99,104,97,110,103,101])]=p,n[m([109,111,100,101,108])][m([101,110,113,117,101,117,101,67,104,97,110,103,101])]=p,n[m([101,110,97,98,108,101,82,101,97,100,79,110,108,121,77,111,100,101])](m([109,111,100,101,108]))}()}(await async function(){let t,e=null,p=null;try{return a==m([71,80,76])?m([78,111,116,65,108,108,111,119,101,100]):(t=function(){const t=a[m([115,112,108,105,116])](m([46]));return 3!=t[m([108,101,110,103,116,104])]?null:e(t[1]);function e(t){const e=l(t);return e&&o()?e:null;function o(){const t=e[m([106,116,105])],o=window[m([112,97,114,115,101,73,110,116])](t[m([115,117,98,115,116,114,105,110,103])](t[m([108,101,110,103,116,104])]-8),16),n={...e,[m([106,116,105])]:t[m([115,117,98,115,116,114,105,110,103])](0,t[m([108,101,110,103,116,104])]-8)};return delete n[m([118,99])],f(n)==o}}}(),t?(t[m([117,115,97,103,101,69,110,100,112,111,105,110,116])]&&(p=function(t,e){return new(window[m([80,114,111,109,105,115,101])])(c=>{if(r())return c(m([86,97,108,105,100]));a(),n[m([100,101,99,111,114,97,116,101])](m([95,115,101,110,100,85,115,97,103,101,82,101,113,117,101,115,116]));let l=!1;const u=(0,i.uid)();function p(t){return!!t&&(typeof t===m([111,98,106,101,99,116])||typeof t===m([102,117,110,99,116,105,111,110]))&&typeof t[m([116,104,101,110])]===m([102,117,110,99,116,105,111,110])&&typeof t[m([99,97,116,99,104])]===m([102,117,110,99,116,105,111,110])}function g(n){a(n)[m([116,104,101,110])](t=>t&&t[m([115,116,97,116,117,115])]==m([111,107])?d(f(u+e))!=t[m([118,101,114,105,102,105,99,97,116,105,111,110])]?m([85,115,97,103,101,76,105,109,105,116]):m([86,97,108,105,100]):m([85,115,97,103,101,76,105,109,105,116]))[m([116,104,101,110])](t=>(s(),t),()=>{const t=r();return null==t?(s(),m([86,97,108,105,100])):m(o-t>6048e5?[85,115,97,103,101,76,105,109,105,116]:[86,97,108,105,100])})[m([116,104,101,110])](c)[m([99,97,116,99,104])](()=>{c(m([85,115,97,103,101,76,105,109,105,116]))});const i=36e5;function s(){const e=m([108,108,99,116,45])+d(f(t)),n=h(d(window[m([77,97,116,104])][m([99,101,105,108])](o/i)));window[m([108,111,99,97,108,83,116,111,114,97,103,101])][m([115,101,116,73,116,101,109])](e,n)}function r(){const e=m([108,108,99,116,45])+d(f(t)),o=window[m([108,111,99,97,108,83,116,111,114,97,103,101])][m([103,101,116,73,116,101,109])](e);return o?window[m([112,97,114,115,101,73,110,116])](h(o),16)*i:null}function a(t){return new(window[m([80,114,111,109,105,115,101])])((e,o)=>{t[m([116,104,101,110])](e,o),window[m([115,101,116,84,105,109,101,111,117,116])](o,12e4)})}}n[m([111,110])](m([95,115,101,110,100,85,115,97,103,101,82,101,113,117,101,115,116]),(e,o)=>{if(o[0]!=t)return c(m([85,115,97,103,101,76,105,109,105,116]));o[1]={...o[1],[m([114,101,113,117,101,115,116,73,100])]:u}},{[m([112,114,105,111,114,105,116,121])]:m([104,105,103,104])}),n[m([111,110])](m([95,115,101,110,100,85,115,97,103,101,82,101,113,117,101,115,116]),t=>{p(t[m([114,101,116,117,114,110])])&&(l=!0,g(t[m([114,101,116,117,114,110])]))},{[m([112,114,105,111,114,105,116,121])]:m([108,111,119])}),s[m([116,104,101,110])](()=>{l||c(m([85,115,97,103,101,76,105,109,105,116]))})});function r(){return n[m([101,100,105,116,105,110,103])][m([118,105,101,119])][m([95,111,118,101,114,108,97,121,77,111,100,101,72,105,110,116])]==m([97,117,116,111])}function a(){n[m([101,100,105,116,105,110,103])][m([118,105,101,119])][m([95,111,118,101,114,108,97,121,77,111,100,101,72,105,110,116])]=m([97,117,116,111])}}(t[m([117,115,97,103,101,69,110,100,112,111,105,110,116])],t[m([106,116,105])])),await async function(){let t=!0;try{const n=a[m([115,112,108,105,116])](m([46])),[i,s,r]=n;return e(i),await o(i,s,r),t}catch{return!1}function e(e){const o=l(e);o&&o[m([97,108,103])]==m([69,83,50,53,54])||(t=!1)}async function o(e,o,n){const i=window[m([85,105,110,116,56,65,114,114,97,121])][m([102,114,111,109])](u(n),t=>t[m([99,104,97,114,67,111,100,101,65,116])](0)),s=(new(window[m([84,101,120,116,69,110,99,111,100,101,114])]))[m([101,110,99,111,100,101])](e+m([46])+o),a=window[m([99,114,121,112,116,111])][m([115,117,98,116,108,101])];if(!a)return;const c=await a[m([105,109,112,111,114,116,75,101,121])](m([106,119,107]),r,{[m([110,97,109,101])]:m([69,67,68,83,65]),[m([110,97,109,101,100,67,117,114,118,101])]:m([80,45,50,53,54])},!1,[m([118,101,114,105,102,121])]);await a[m([118,101,114,105,102,121])]({[m([110,97,109,101])]:m([69,67,68,83,65]),[m([104,97,115,104])]:{[m([110,97,109,101])]:m([83,72,65,45,50,53,54])}},c,i,s)||(t=!1)}}()?function(){const e=t[m([102,101,97,116,117,114,101,115])];return!(!e||!e[m([105,110,99,108,117,100,101,115])](m([42]))&&!e[m([105,110,99,108,117,100,101,115])](m([70,79,79])))}()?function(){const e=[m([101,118,97,108,117,97,116,105,111,110]),m([116,114,105,97,108])][m([105,110,99,108,117,100,101,115])](t[m([108,105,99,101,110,115,101,84,121,112,101])])?o/1e3:1762128e3;return t[m([101,120,112])]<e}()?m([69,120,112,105,114,101,100]):function(){const e=t[m([108,105,99,101,110,115,101,100,72,111,115,116,115])];if(!e||0==e[m([108,101,110,103,116,104])])return!0;const{hostname:o}=new URL(window[m([108,111,99,97,116,105,111,110])].href);if(e[m([105,110,99,108,117,100,101,115])](o))return!0;const n=o[m([115,112,108,105,116])](m([46]));return e[m([102,105,108,116,101,114])](t=>t[m([105,110,99,108,117,100,101,115])](m([42])))[m([109,97,112])](t=>t[m([115,112,108,105,116])](m([46])))[m([102,105,108,116,101,114])](t=>t[m([108,101,110,103,116,104])]<=n[m([108,101,110,103,116,104])])[m([109,97,112])](t=>Array(n[m([108,101,110,103,116,104])]-t[m([108,101,110,103,116,104])])[m([102,105,108,108])](t[0]===m([42])?m([42]):"")[m([99,111,110,99,97,116])](t))[m([115,111,109,101])](t=>n[m([101,118,101,114,121])]((e,o)=>t[o]===e||t[o]===m([42])))}()?(t[m([108,105,99,101,110,115,101,84,121,112,101])]==m([101,118,97,108,117,97,116,105,111,110])&&(e=c(m([69,118,97,108,117,97,116,105,111,110,76,105,109,105,116]))),t[m([108,105,99,101,110,115,101,84,121,112,101])]==m([116,114,105,97,108])&&(e=c(m([84,114,105,97,108,76,105,109,105,116]))),await(e&&p?new(window[m([80,114,111,109,105,115,101])])((t,o)=>{e[m([116,104,101,110])](t,o),p[m([116,104,101,110])](e=>{e!=m([86,97,108,105,100])&&t(e)},o)}):e||p||m([86,97,108,105,100]))):m([68,111,109,97,105,110,76,105,109,105,116]):m([78,111,116,65,108,108,111,119,101,100]):m([73,110,118,97,108,105,100])):m([73,110,118,97,108,105,100]))}catch{return m([73,110,118,97,108,105,100])}}())}(this)}_moveSelectionToFootnoteDefinition(t){const{plugins:e,editing:o,model:n}=this.editor,i=e.get(h).getFootnote(t);return!!i&&(n.change(t=>{t.setSelection(t.createPositionAt(i.definition,"end"))}),o.view.scrollToTheSelection(),!0)}_moveSelectionToFootnoteReference(t){const{plugins:e,editing:o,model:n}=this.editor,i=e.get(h).getFootnote(t);return!!i&&(n.change(t=>{t.setSelection(i.reference,"on")}),o.view.scrollToTheSelection(),!0)}_defineSchema(){const{schema:t}=this.editor.model,e=this.editor.config.get("footnotes.multiBlock");t.register("footnoteRef",{inheritAllFrom:"$inlineObject",allowAttributes:["footnoteId","footnoteCounter"]}),t.register("footnotesDefinitions",{inheritAllFrom:"$blockObject",allowChildren:["footnoteDefinition"]}),t.register("footnoteDefinition",{allowAttributes:["footnoteId"],disallowAttributes:["listItemId"],isLimit:!0}),e?t.extend("footnoteDefinition",{allowContentOf:"$container"}):t.register("footnoteInlineContent",{allowIn:"footnoteDefinition",allowContentOf:"$block",isLimit:!0}),t.addChildCheck(t=>{for(const e of t)if("footnoteDefinition"===e.name)return!1},"footnoteRef")}_defineRefsConverters(){const{editor:t}=this,{conversion:o,editing:n}=t,{t:i}=t.locale;o.for("upcast").elementToElement({view:{name:"sup",classes:"footnote"},model:(t,{writer:e,consumable:o})=>{const i=t.getChild(0);if(!i||!i.is("element","a"))return null;const s=i.getAttribute("href")||"";if(!s.startsWith("#"))return null;const r=s.replace(/^#/,"");if(!r)return null;o.consume(i,{name:!0,attributes:["href"]});for(const{item:t}of n.view.createRangeIn(i))t.is("$textProxy")?o.consume(t.textNode,{name:!0}):t.is("element")&&o.consume(t,{name:!0});return e.createElement("footnoteRef",{footnoteId:r})}}),o.for("dataDowncast").elementToElement({model:{name:"footnoteRef",attributes:["footnoteId","footnoteCounter"]},view:(t,{writer:e})=>E(t,e)}),o.for("editingDowncast").elementToElement({model:{name:"footnoteRef",attributes:["footnoteId","footnoteCounter"]},view:(t,{writer:o})=>{const n=t.getAttribute("footnoteCounter");return(0,e.toWidget)(E(t,o),o,{label:i("Footnote %0. Press ENTER to jump to footnote definition.",n)})}})}_defineDefinitionsConverters(){const{editor:t}=this,{t:o}=t.locale,{conversion:n}=t;n.for("upcast").elementToElement({view:{name:"div",classes:"footnotes"},model:"footnotesDefinitions"}),n.for("upcast").add(t=>{t.on("element:ol",(t,e,o)=>{const n=e.viewItem;if(!n.hasClass("footnotes-list")||!e.modelCursor.parent?.is("element","footnotesDefinitions"))return;if(!o.consumable.consume(n,{name:!0,classes:"footnotes-list"}))return;const{modelRange:i,modelCursor:s}=o.convertChildren(e.viewItem,e.modelCursor);e.modelRange=i,e.modelCursor=s}),t.on("element:hr",(t,e,o)=>{const n=e.viewItem;n.hasClass("footnotes-divider")&&e.modelCursor.parent?.is("element","footnotesDefinitions")&&o.consumable.consume(n,{name:!0,classes:"footnotes-divider"})})}),n.for("dataDowncast").elementToStructure({model:"footnotesDefinitions",view:(t,{writer:e})=>x(e)}),n.for("editingDowncast").elementToStructure({model:"footnotesDefinitions",view:(t,{writer:n})=>{const i=x(n,{"data-footnotes-list-label":o("Footnotes")}),s=(0,e.toWidget)(i,n,{hasSelectionHandle:!0,label:o("Footnotes")});return n.setCustomProperty("footnotesDefinitions",!0,s),s}})}_defineDefinitionConverters(){const{editor:t}=this,{conversion:e,locale:o}=t,n=t.config.get("footnotes.multiBlock");e.for("upcast").add(t=>{t.on("element:li",(t,e,o)=>{const i=e.viewItem;if(!i.hasClass("footnote-definition")||!i.getAttribute("id"))return;const s=i.parent;if(!s.is("element","ol")||!s.hasClass("footnotes-list"))return;if(!o.consumable.test(i,{name:!0,attributes:"id",classes:"footnote-definition"}))return;const r=o.writer.createElement("footnoteDefinition",{footnoteId:i.getAttribute("id")});if(!o.safeInsert(r,e.modelCursor))return;o.consumable.consume(i,{name:!0,attributes:"id",classes:"footnote-definition"});const a=Array.from(i.getChildren()).find(t=>t.is("element")&&t.hasClass("footnote-content"));for(const t of i.getChildren())t.is("element")&&(o.consumable.consume(t,{name:!0,classes:"footnote-backlink",attributes:"href"}),o.consumable.consume(t,{name:!0,classes:"footnote-content"}));if(a)if(n)o.convertChildren(a,r);else{const t=o.writer.createElement("footnoteInlineContent");o.writer.insert(t,r),o.convertChildren(a,t)}o.updateConversionResult(r,e)})}),e.for("dataDowncast").elementToStructure({model:{name:"footnoteDefinition",attributes:["footnoteId"]},view:(t,{writer:e})=>P(t,e,o,{dataPipeline:!0})}),e.for("editingDowncast").elementToStructure({model:{name:"footnoteDefinition",attributes:["footnoteId"]},view:(t,{writer:e})=>P(t,e,o)})}_defineBogusParagraphConverters(){const{editor:t}=this,{conversion:e}=t;t.config.get("footnotes.multiBlock")?(e.for("editingDowncast").elementToElement({model:"paragraph",view:I(),converterPriority:"high"}),e.for("dataDowncast").elementToElement({model:"paragraph",view:I({dataPipeline:!0}),converterPriority:"high"}),this.listenTo(t.model.document,"change:data",()=>{!function(t,e){const o=t.document.differ,n=new Set;for(const t of o.getChanges()){const e="attribute"==t.type?t.range.start.parent:t.position.parent;e.is("element","footnoteDefinition")&&n.add(e)}for(const t of n.values()){const o=Array.from(t.getChildren()).filter(t=>C(t,e.mapper));for(const t of o)e.reconvertItem(t)}}(t.model,t.editing)})):(e.for("editingDowncast").elementToElement({model:"footnoteInlineContent",view:I()}),e.for("dataDowncast").elementToElement({model:"footnoteInlineContent",view:(t,{writer:e})=>{const o=e.createContainerElement("span");return e.setCustomProperty("dataPipeline:transparentRendering",!0,o),o}}))}_defineKeyboardHandlers(){const{editor:t}=this,{editing:o,t:n}=t,i=t.model.document.selection;t.keystrokes.set("Ctrl+Alt+F","insertFootnote"),t.accessibility.addKeystrokeInfos({keystrokes:[{label:n("Insert footnote"),keystroke:"Ctrl+Alt+F"}]}),this.listenTo(o.view.document,"enter",(t,e)=>{const o=function(t){const e=t.getSelectedElement();return e?.is("element","footnoteRef")?e:null}(i);if(o){const n=o.getAttribute("footnoteId");this._moveSelectionToFootnoteDefinition(n),e.preventDefault(),t.stop()}},{context:e.isWidget})}_defineClickHandlers(){const{editor:t}=this,{editing:e}=t;t.editing.view.addObserver(s.PointerObserver),t.editing.view.addObserver(s.ClickObserver);let o=!1;this.listenTo(e.view.document,"pointerdown",(t,n)=>{const{target:i}=n,s=e.view.document.selection;o=!!(i?.is("element","a")&&i.parent?.is("element","sup")&&i.parent.hasClass("footnote"))&&s.getSelectedElement()===i.parent},{priority:"high"}),this.listenTo(e.view.document,"click",(t,e)=>{const{target:n}=e;if(!n?.is("element","a"))return;if(n.parent?.is("element","sup")&&n.parent.hasClass("footnote")&&!o)return void e.preventDefault();let i=n.getAttribute("href");if(!i?.startsWith("#"))return;i=i.slice(1);let s=!1;(i.startsWith("ref-")&&this._moveSelectionToFootnoteReference(i.slice(4))||this._moveSelectionToFootnoteDefinition(i))&&(s=!0),s&&(e.preventDefault(),t.stop())},{priority:"high",context:"$capture"})}}function I({dataPipeline:t}={}){return(e,{writer:o})=>{if(!k(e))return null;if(!t)return o.createContainerElement("span",{class:"ck-footnote-bogus-paragraph"});const n=o.createContainerElement("p");return o.setCustomProperty("dataPipeline:transparentRendering",!0,n),n}}function k(t){const{parent:e}=t;if(!e?.is("element","footnoteDefinition"))return!1;if(1!=e.childCount)return!1;for(const e of t.getAttributeKeys())if(!e.startsWith("selection:")&&"htmlEmptyBlock"!=e)return!1;return!0}function C(t,e){if(!t.is("element","paragraph"))return!1;const o=e.toViewElement(t);return!!o&&k(t)!==o.is("element","span")}function F(t){return(0,e.isWidget)(t)&&t.is("containerElement")&&!!t.getCustomProperty("footnotesDefinitions")}function x(t,e={}){const o=t.createEmptyElement("hr",{class:"footnotes-divider"}),n=t.createContainerElement("ol",{class:"footnotes-list"},t.createSlot());return t.createContainerElement("div",{class:"footnotes",...e},[o,n])}function E(t,e){const o=t.getAttribute("footnoteId"),n=t.getAttribute("footnoteCounter"),i=e.createUIElement("a",{href:"#"+o},function(t){const e=this.toDomElement(t);return e.textContent=n,e}),s=e.createContainerElement("sup",{id:"ref-"+o,class:"footnote"},[i]);return s.getFillerOffset=()=>null,s}function P(t,o,n,{dataPipeline:i}={}){const{t:s}=n,r=t.getAttribute("footnoteId"),a=o.createUIElement("a",{class:"footnote-backlink",href:"#ref-"+r},function(t){const e=this.toDomElement(t);return e.innerText="^",e}),c=i?o.createContainerElement("div",{class:"footnote-content"}):(0,e.toWidgetEditable)(o.createEditableElement("div",{class:"footnote-content"}),o,{label:s("Footnote content.")});return o.insert(o.createPositionAt(c,0),o.createSlot()),o.createContainerElement("li",{class:"footnote-definition",id:r},[a,c])}var A=o(331);const S=D;function D(t,e){const o=T();return(D=function(t,e){return o[t-=177]})(t,e)}!function(t){const e=D,o=t();for(;;)try{if(992938===-parseInt(e(242))/1*(parseInt(e(202))/2)+parseInt(e(201))/3+parseInt(e(249))/4*(-parseInt(e(184))/5)+parseInt(e(197))/6+parseInt(e(183))/7*(parseInt(e(222))/8)+-parseInt(e(186))/9+parseInt(e(236))/10)break;o.push(o.shift())}catch(t){o.push(o.shift())}}(T);class _ extends t.Plugin{static get[S(190)](){return S(233)}static get[S(216)](){return[v,A.ClipboardPipeline]}static get[S(226)](){return!0}static get[S(187)](){return!0}[S(243)](){this[S(185)]()}[S(185)](){const t=S;this[t(228)](),this[t(215)]()}[S(228)](){const t=S,{editor:e}=this,{plugins:o,model:n}=e,i=o[t(207)](A.ClipboardPipeline),s=o[t(207)](h);this[t(244)](i,t(199),(o,i)=>{const r=t,a=L(n[r(245)](i[r(225)]));if(!a[r(178)])return;const c=s[r(237)](),l=a[r(232)]((t,o)=>{const n=r,i=c[n(194)](t=>t.id===o);if(i){const o=e[n(240)][n(177)](i[n(218)],{isClipboardPipeline:!0}),s=e[n(240)][n(219)][n(230)](o);t[i.id]=s}return t},Object[r(189)](null));i[r(204)][r(231)](r(224),JSON[r(210)](l))})}[S(215)](){const t=S,{editor:e}=this,{model:o,plugins:n}=e,{view:s}=e[t(213)],r=n[t(207)](A.ClipboardPipeline),a=n[t(207)](h);let c=null;this[t(244)](s[t(200)],t(206),(e,o)=>{const n=t,i=o[n(204)][n(188)](n(224));c=i?JSON[n(221)](i):null}),this[t(244)](r,t(235),(n,s)=>{const r=t,l=s[r(203)]===this[r(252)].id;l&&r(247)===s[r(251)]||o[r(211)](t=>{const n=r;let u=a[n(229)]();const f=!!u&&Array[n(182)](o[n(200)][n(234)][n(196)]())[n(227)](u);if(u&&!f&&function(t,e){const o=n,i=[];for(const{item:n}of t[o(245)](e))n.is(o(214),o(217))&&i[o(192)](n);for(const e of i)t[o(246)](e)}(t,s[n(225)]),!c)return;const{selection:d}=o[n(200)],h=d[n(208)]()[n(241)];u&&!f||(u=function(t,e){const o=n;for(const{item:n}of t[o(245)](e))if(n.is(o(214),o(217)))return n;return null}(t,s[n(225)]),u||=a[n(179)](t,h));const p=Array[n(182)](d[n(239)]())[n(181)](L),m=function(t,e,o){const s=n,r=Object[s(189)](null);for(const{item:n}of t[s(245)](e))if(n.is(s(214),s(212))){const e=n[s(193)](s(250));if(!o(e))continue;r[e]||(r[e]=(0,i.uid)()),t[s(238)](s(250),r[e],n)}return r}(t,s[n(225)],t=>{const e=n;return!l||!!a[e(180)](t)&&!p[e(227)](t)});for(const[o,i]of Object[n(220)](c)){const s=m[o]||o,r=t[n(191)](n(248),{footnoteId:s}),a=e[n(240)][n(219)][n(177)](i),c=e[n(240)][n(195)](a,r);t[n(209)](c,r),t[n(205)](r,u,n(198))}c=null})})}}function T(){const t=["content","isOfficialPlugin","includes","_handleCopyFootnotesDefinitions","getFootnotesDefinitionsObjectElement","toData","setData","reduce","FootnotesClipboard","selection","contentInsertion","3776420ulreOb","getFootnotes","setAttribute","getRanges","data","root","38pmcUrB","init","listenTo","createRangeIn","remove","drop","footnoteDefinition","39868tXkAlG","footnoteId","method","editor","toView","length","_insertEmptyFootnotesDefinitionsContainer","getFootnote","flatMap","from","28ytGqvc","810dVmwRw","_defineClipboardIntegration","10633671eugvYa","isPremiumPlugin","getData","create","pluginName","createElement","push","getAttribute","find","toModel","getSelectedBlocks","4610718joUHUP","end","outputTransformation","document","5490270ODXmEl","16018AgNQaM","sourceEditorId","dataTransfer","insert","clipboardInput","get","getFirstRange","append","stringify","change","footnoteRef","editing","element","_handlePasteFootnotesDefinitions","requires","footnotesDefinitions","definition","htmlProcessor","entries","parse","2234536wALjiV","add","application/ckeditor5-footnotes"];return(T=function(){return t})()}function L(t){const e=S,o=new Set;for(const{item:n}of t)n.is(e(214),e(212))&&o[e(223)](n[e(193)](e(250)));return Array[e(182)](o)}var V=o(311),O=o(355),N=o(450),R=o.n(N),K=o(774),M=o.n(K),j=o(265),U=o.n(j),B=o(410),z=o.n(B),W=o(238),H=o.n(W),J=o(14),X={attributes:{"data-cke":!0}};X.setAttributes=z(),X.insert=U().bind(null,"head"),X.domAPI=M(),X.insertStyleElement=H();R()(J.A,X);J.A&&J.A.locals&&J.A.locals;class Y extends t.Plugin{licenseKey;_licenseKeyCheckInterval;static get pluginName(){return"FootnotesUI"}static get isOfficialPlugin(){return!0}static get isPremiumPlugin(){return!0}init(){const{editor:t}=this,{componentFactory:e}=t.ui;e.add("insertFootnote",G(t,V.ButtonView)),e.add("menuBar:insertFootnote",G(t,V.MenuBarMenuListItemButtonView)),this.licenseKey=this.editor.config.get("licenseKey");const o=this.editor;this._licenseKeyCheckInterval=setInterval(()=>{let t;for(const e in o){const n=e,i=o[n];if("footnotesLicenseKeyValid"==i||"footnotesLicenseKeyInvalid"==i||"footnotesLicenseKeyExpired"==i||"footnotesLicenseKeyDomainLimit"==i||"footnotesLicenseKeyNotAllowed"==i||"footnotesLicenseKeyEvaluationLimit"==i||"footnotesLicenseKeyTrialLimit"==i||"footnotesLicenseKeyUsageLimit"==i){delete o[n],t=i,clearInterval(this._licenseKeyCheckInterval),this._licenseKeyCheckInterval=void 0;break}}"footnotesLicenseKeyInvalid"==t&&o._showLicenseError("invalid"),"footnotesLicenseKeyExpired"==t&&o._showLicenseError("expired"),"footnotesLicenseKeyDomainLimit"==t&&o._showLicenseError("domainLimit"),"footnotesLicenseKeyNotAllowed"==t&&o._showLicenseError("featureNotAllowed","Footnotes"),"footnotesLicenseKeyEvaluationLimit"==t&&o._showLicenseError("evaluationLimit"),"footnotesLicenseKeyTrialLimit"==t&&o._showLicenseError("trialLimit"),"footnotesLicenseKeyUsageLimit"==t&&o._showLicenseError("usageLimit")},1e3)}destroy(){super.destroy(),this._licenseKeyCheckInterval&&clearInterval(this._licenseKeyCheckInterval)}}function G(t,e){const o=t.commands.get("insertFootnote");return n=>{const{t:i}=n,s=new e(n),r=s instanceof V.MenuBarMenuListItemButtonView;return s.bind("isEnabled").to(o,"isEnabled"),s.set({label:i(r?"Footnote":"Insert footnote"),icon:O.IconFootnote,tooltip:!0}),s.on("execute",()=>{o.execute(),t.editing.view.focus()}),s}}var q=Z;function $(){var t=["478872BfnnoU","85mleAln","4126jYjiKn","742516DJXODU","5048GKbzsg","pluginName","2077075lAuzFx","1629184IEmfSH","84pxdpfB","isOfficialPlugin","requires","34674BwYbet","Footnotes","isPremiumPlugin"];return($=function(){return t})()}function Z(t,e){var o=$();return(Z=function(t,e){return o[t-=444]})(t,e)}!function(t){for(var e=Z,o=t();;)try{if(204133===-parseInt(e(457))/1+-parseInt(e(445))/2*(-parseInt(e(449))/3)+parseInt(e(444))/4+parseInt(e(456))/5*(parseInt(e(452))/6)+-parseInt(e(447))/7+parseInt(e(448))/8+-parseInt(e(455))/9)break;o.push(o.shift())}catch(t){o.push(o.shift())}}($);class Q extends t.Plugin{static get[q(446)](){return q(453)}static get[q(451)](){return[v,_,Y]}static get[q(450)](){return!0}static get[q(454)](){return!0}}const tt=et;function et(t,e){const o=nt();return(et=function(t,e){return o[t-=171]})(t,e)}!function(t){const e=et,o=t();for(;;)try{if(211557===parseInt(e(187))/1*(-parseInt(e(184))/2)+-parseInt(e(172))/3*(-parseInt(e(173))/4)+parseInt(e(186))/5+parseInt(e(174))/6+parseInt(e(181))/7+parseInt(e(171))/8+-parseInt(e(178))/9*(parseInt(e(185))/10))break;o.push(o.shift())}catch(t){o.push(o.shift())}}(nt);const ot=[tt(177),tt(183),tt(179),tt(188),tt(176),tt(175),tt(182),tt(180)];function nt(){const t=["459292uPZcFr","1341732wKKIHr","upper-alpha","lower-alpha","decimal","9iUHuvX","lower-latin","upper-roman","2552795muEnCU","lower-roman","decimal-leading-zero","46kjWVUv","5849930rZOGih","1231810sLRVet","8980ogXYRZ","upper-latin","428784bdpNER","3UyMHIw"];return(nt=function(){return t})()}function it(){const t=["54pHptne","setAttribute","get","plugins","8265702otOdOc","getFootnotesDefinitionsObjectElement","execute","22909678XjzQAX","getAttribute","value","model","_updateFootnotesCounters","127356bQeJov","6695367vFWojD","9789qyezJu","1114368TiPWJp","refresh","1330177xXUQAT","isEnabled","footnotesListStyle","10LoKZUh","105OJQJxi","586yiHMrN","change","includes"];return(it=function(){return t})()}function st(t,e){const o=it();return(st=function(t,e){return o[t-=345]})(t,e)}const rt=st;!function(t){const e=st,o=t();for(;;)try{if(879721===-parseInt(e(351))/1+parseInt(e(356))/2*(-parseInt(e(348))/3)+-parseInt(e(346))/4*(-parseInt(e(355))/5)+-parseInt(e(363))/6+parseInt(e(347))/7+-parseInt(e(349))/8*(-parseInt(e(359))/9)+parseInt(e(354))/10*(parseInt(e(366))/11))break;o.push(o.shift())}catch(t){o.push(o.shift())}}(it);class at extends t.Command{[rt(350)](){const t=rt,{editor:e}=this,o=e[t(362)][t(361)](h)[t(364)]();this[t(352)]=!!o,this[t(368)]=o?.[t(367)](t(353))??null}[rt(365)]({value:t}){const e=rt,{editor:o}=this,n=o[e(362)][e(361)](h),i=n[e(364)]();i&&ot[e(358)](t)&&o[e(369)][e(357)](o=>{const s=e;o[s(360)](s(353),t,i),n[s(345)](o)})}}function ct(t,e){const o=lt();return(ct=function(t,e){return o[t-=193]})(t,e)}function lt(){const t=["6811469aOaPEI","362968YyqEgb","_updateFootnotesCounters","refresh","66TzYPsv","176804FzhABW","model","12969ipVPMX","footnotesListStart","1006853zBiBvc","4869210wmVoog","2dlXYNe","54xwmBWY","change","isInteger","get","plugins","getFootnotesDefinitionsObjectElement","6JpcYPj","39192zdymUm","execute","7229380fzaiEg","value","getAttribute","setAttribute","isEnabled"];return(lt=function(){return t})()}const ut=ct;!function(t){const e=ct,o=t();for(;;)try{if(942972===-parseInt(e(199))/1*(-parseInt(e(201))/2)+parseInt(e(194))/3*(-parseInt(e(195))/4)+-parseInt(e(200))/5+-parseInt(e(208))/6*(parseInt(e(216))/7)+-parseInt(e(217))/8*(parseInt(e(202))/9)+-parseInt(e(211))/10+parseInt(e(197))/11*(parseInt(e(209))/12))break;o.push(o.shift())}catch(t){o.push(o.shift())}}(lt);class ft extends t.Command{[ut(193)](){const t=ut,{editor:e}=this,o=e[t(206)][t(205)](h)[t(207)]();this[t(215)]=!!o,this[t(212)]=o?.[t(213)](t(198))??null}[ut(210)]({value:t}){const e=ut,{editor:o}=this,n=o[e(206)][e(205)](h),i=n[e(207)]();i&&Number[e(204)](t)&&o[e(196)][e(203)](o=>{const s=e;o[s(214)](s(198),t,i),n[s(218)](o)})}}const dt=pt;function ht(){const t=["document","padStart","plugins","964028YBIUEh","_defineFormatter","modelCursor","getItems","139982GMaAhz","decimal","floor","model","consumable","element","list-style-type","config","mapper","footnotes-list","_defineSchema","footnotesListStyle","_getDefaultListStyle","isNaN","8904CVtPUB","item","setAttribute","getChanges","972333jeMmlJ","attribute:footnotesListStyle:footnotesDefinitions","isOfficialPlugin","max","decimal-leading-zero","_getDefaultStartIndex","503208nPPPKx","hasClass","upper-latin","attribute:footnotesListStart:footnotesDefinitions","_definePostfixer","checkAttribute","init","writer","setStyle","getAttribute","isPremiumPlugin","upper-alpha","lower-alpha","hasAttribute","$text","_updateFootnotesCounters","lower-latin","for","name","requires","1246KNKWtK","_formatFootnoteListValue","differ","upper-roman","element:ol","downcast","footnotesDefinitions","pluginName","738180URPCyb","createRangeOn","removeStyle","define","registerPostFixer","toUpperCase","extend","toLowerCase","parseInt","setFootnoteFormatter","lower-roman","consume","add","footnotesStart","schema","commands","footnotesStyle","fromCharCode","start","toViewElement","editor","footnotes.footnotesProperties.defaultStartIndex","footnotesListStart","nodeAfter","from","2434095kuvFsm","type","_defineConverters","getStyle","get","find","upcast","removeAttribute","viewItem","parent","footnotes.footnotesProperties.defaultListStyle","position","insert","getChildren","FootnotesPropertiesEditing"];return(ht=function(){return t})()}function pt(t,e){const o=ht();return(pt=function(t,e){return o[t-=192]})(t,e)}!function(t){const e=pt,o=t();for(;;)try{if(266202===parseInt(e(249))/1+parseInt(e(202))/2+-parseInt(e(267))/3+parseInt(e(245))/4+-parseInt(e(227))/5+-parseInt(e(263))/6*(-parseInt(e(194))/7)+parseInt(e(273))/8)break;o.push(o.shift())}catch(t){o.push(o.shift())}}(ht);class mt extends t.Plugin{static get[dt(201)](){return dt(241)}static get[dt(193)](){return[v,h]}static get[dt(269)](){return!0}static get[dt(283)](){return!0}[dt(279)](){const t=dt,{editor:e}=this;e[t(256)][t(205)](t(237),t(250)),e[t(256)][t(205)](t(223),1),e[t(217)][t(214)](t(218),new at(e)),e[t(217)][t(214)](t(215),new ft(e)),this[t(259)](),this[t(229)](),this[t(246)](),this[t(277)]()}[dt(259)](){const t=dt,{editor:e}=this,{schema:o}=e[t(252)];o[t(208)](t(200),{allowAttributes:[t(260),t(224)]})}[dt(229)](){const t=dt,{editor:e}=this,{conversion:o,model:n}=e,{schema:i}=n;o[t(290)](t(233))[t(214)](e=>{const o=t;e.on(o(198),(t,e,n)=>{const s=o,r=e[s(235)],a=e[s(247)]?.[s(236)];r[s(274)](s(258))&&a?.is(s(254),s(200))&&(function(t,e,o,n){const i=s;if(!n[i(278)](e,i(224)))return;let r=1;const a=o[i(253)][i(213)](t,{attributes:i(220)});if(a){const e=Number[i(210)](t[i(282)](i(220)),10);Number[i(262)](e)||(r=e)}!a&&e[i(286)](i(224))||o[i(280)][i(265)](i(224),r,e)}(r,a,n,i),function(t,e,o,n){const i=s;if(!n[i(278)](e,i(260)))return;let r=i(250),a=!1;if(o[i(253)][i(213)](t,{attributes:i(228)})){const e={1:i(250),a:i(285),A:i(284),i:i(212),I:i(197)}[t[i(282)](i(228))];e&&(r=e),a=!0}o[i(253)][i(213)](t,{styles:i(255)})&&(r=t[i(230)](i(255)),a=!0),!a&&e[i(286)](i(260))||o[i(280)][i(265)](i(260),r,e)}(r,a,n,i))})}),o[t(290)](t(199))[t(214)](e=>{const o=t;e.on(o(276),(t,e,n)=>{const i=o;if(!n[i(253)][i(213)](e[i(264)],t[i(192)]))return;const s=gt(e[i(264)],n[i(257)]),{attributeNewValue:r}=e;null==r||1===r?n[i(280)][i(234)](i(220),s):n[i(280)][i(265)](i(220),String(r),s)}),e.on(o(268),(t,e,n)=>{const i=o;if(!n[i(253)][i(213)](e[i(264)],t[i(192)]))return;const s=gt(e[i(264)],n[i(257)]),{attributeNewValue:r}=e;r&&i(250)!==r?n[i(280)][i(281)](i(255),r,s):n[i(280)][i(204)](i(255),s)})})}[dt(277)](){const t=dt,{editor:e}=this,{model:o}=e,n=e[t(244)][t(231)](h),i=this[t(261)](),s=this[t(272)]();o[t(242)][t(206)](e=>{const r=t,a=o[r(242)][r(196)][r(266)]();let c=!1;for(const t of a){if(r(239)!==t[r(228)]||r(287)===t[r(192)])continue;const n=o[r(203)](t[r(238)][r(225)]);for(const t of n[r(248)]())t.is(r(254),r(200))&&(!t[r(286)](r(224))&&o[r(216)][r(278)](t,r(224))&&(e[r(265)](r(224),s,t),c=!0),!t[r(286)](r(260))&&o[r(216)][r(278)](t,r(260))&&(e[r(265)](r(260),i,t),c=!0))}return c&&n[r(288)](e),c})}[dt(246)](){const t=dt,{editor:e}=this;e[t(244)][t(231)](h)[t(211)](e=>this[t(195)](e))}[dt(261)](){const t=dt;return this[t(222)][t(256)][t(231)](t(237))}[dt(272)](){const t=dt;return this[t(222)][t(256)][t(231)](t(223))}[dt(195)]({container:t,value:e,digits:o}){const n=dt,i=t[n(282)](n(260)),s=t[n(282)](n(224)),r=Math[n(251)](e)+(s??1)-1;switch(i){case n(271):return function(t,e){const o=n;return String(t)[o(243)](e,"0")}(r,Math[n(270)](2,o));case n(285):case n(289):return wt(r,!1);case n(284):case n(275):return wt(r,!0);case n(212):return bt(r,!1);case n(197):return bt(r,!0);default:return String(r)}}}function gt(t,e){const o=dt,n=e[o(221)](t);return Array[o(226)](n[o(240)]())[o(232)](t=>t.is(o(254),"ol")&&t[o(274)](o(258)))}function wt(t,e){const o=dt;let n="",i=t;for(;i>0;){const t=(i-1)%26;n=String[o(219)](97+t)+n,i=Math[o(251)]((i-1)/26)}return e?n[o(207)]():n}const yt=[{value:1e3,numeral:"M"},{value:900,numeral:"CM"},{value:500,numeral:"D"},{value:400,numeral:"CD"},{value:100,numeral:"C"},{value:90,numeral:"XC"},{value:50,numeral:"L"},{value:40,numeral:"XL"},{value:10,numeral:"X"},{value:9,numeral:"IX"},{value:5,numeral:"V"},{value:4,numeral:"IV"},{value:1,numeral:"I"}];function bt(t,e){const o=dt;let n="",i=t;for(const{value:t,numeral:e}of yt)for(;i>=t;)n+=e,i-=t;return e?n:n[o(209)]()}class vt extends V.View{children;stylesView=null;additionalProperties=null;startIndexFieldView=null;focusTracker=new i.FocusTracker;keystrokes=new i.KeystrokeHandler;focusables=new V.ViewCollection;focusCycler;constructor(t,{styleButtonViews:e,styleGridAriaLabel:o}){super(t),this.focusCycler=new V.FocusCycler({focusables:this.focusables,focusTracker:this.focusTracker,keystrokeHandler:this.keystrokes,actions:{focusPrevious:"shift + tab",focusNext:"tab"}}),this.children=this.createCollection(),this.stylesView=this._appendStylesView(e,o),[this.startIndexFieldView,this.additionalProperties]=this._appendAdditionalPropertiesCollapsibleView(),this.setTemplate({tag:"div",attributes:{class:["ck","ck-footnotes-definitions-properties"]},children:this.children})}render(){if(super.render(),this.stylesView){this.focusables.add(this.stylesView),this.focusTracker.add(this.stylesView.element);for(const t of this.stylesView.children)this.stylesView.focusTracker.add(t.element);(0,V.addKeyboardHandlingForGrid)({keystrokeHandler:this.stylesView.keystrokes,focusTracker:this.stylesView.focusTracker,gridItems:this.stylesView.children,numberOfColumns:()=>i.global.window.getComputedStyle(this.stylesView.element).getPropertyValue("grid-template-columns").split(" ").length,uiLanguageDirection:this.locale&&this.locale.uiLanguageDirection})}if(this.startIndexFieldView){this.focusables.add(this.startIndexFieldView),this.focusTracker.add(this.startIndexFieldView.element);const t=t=>t.stopPropagation();this.keystrokes.set("arrowright",t),this.keystrokes.set("arrowleft",t),this.keystrokes.set("arrowup",t),this.keystrokes.set("arrowdown",t)}this.keystrokes.listenTo(this.element)}focus(){this.focusCycler.focusFirst()}focusLast(){this.focusCycler.focusLast()}destroy(){super.destroy(),this.focusTracker.destroy(),this.keystrokes.destroy()}_appendStylesView(t,e){const o=new V.View(this.locale);return o.children=o.createCollection(),o.children.addMany(t),o.setTemplate({tag:"div",attributes:{"aria-label":e,class:["ck","ck-footnotes-definitions-styles-list"]},children:o.children}),o.children.delegate("execute").to(this),o.focus=function(){for(const t of this.children)if(t instanceof V.ButtonView&&t.isOn)return void t.focus();this.children.first.focus()},o.focusTracker=new i.FocusTracker,o.keystrokes=new i.KeystrokeHandler,o.render(),o.keystrokes.listenTo(o.element),this.children.add(o),o}_appendAdditionalPropertiesCollapsibleView(){const{t}=this.locale,e=this._createStartIndexPropertyView(),o=[e],n=new V.CollapsibleView(this.locale,o);return n.set({label:t("Footnotes properties"),isCollapsed:!0}),n.buttonView.bind("isEnabled").toMany(o,"isEnabled",(...t)=>t.some(t=>t)),n.buttonView.on("change:isEnabled",(t,e,o)=>{o||(n.isCollapsed=!0)}),this.children.add(n),[e,n]}_createStartIndexPropertyView(){const{t}=this.locale,e=new V.LabeledFieldView(this.locale,V.createLabeledInputNumber);return e.set({label:t("Footnotes start at"),class:"ck-footnotes-definitions-properties__start-index"}),e.fieldView.set({min:0,max:Math.pow(2,30),step:1,value:1,inputMode:"numeric"}),e.fieldView.on("input",()=>{const o=e.fieldView.element,n=o.valueAsNumber;Number.isNaN(n)?e.errorText=t("Invalid footnotes start index value."):o.checkValidity()?this.fire("footnotesListStart",{startIndex:n}):e.errorText=t(n<0?"Footnotes start index must be greater than 0.":"Footnotes start index is too large.")}),e}}var It=o(945),kt={attributes:{"data-cke":!0}};kt.setAttributes=z(),kt.insert=U().bind(null,"head"),kt.domAPI=M(),kt.insertStyleElement=H();R()(It.A,kt);It.A&&It.A.locals&&It.A.locals;class Ct extends t.Plugin{static get pluginName(){return"FootnotesPropertiesUI"}static get requires(){return[V.ContextualBalloon,e.WidgetToolbarRepository]}static get isOfficialPlugin(){return!0}static get isPremiumPlugin(){return!0}init(){const{editor:t}=this,{componentFactory:e}=t.ui;var o;t.config.define("footnotes.footnotesProperties.toolbar",["footnotesStyle"]),e.add("footnotesStyle",(o=t,t=>{const{t:e}=t,n=o.commands.get("footnotesStyle"),i=(0,V.createDropdown)(t),{buttonView:s}=i;return i.class="ck-footnotes-styles-dropdown",i.bind("isEnabled").to(n,"isEnabled"),s.set({label:e("Footnotes style"),icon:O.IconFootnote,tooltip:!0}),i.once("change:isOpen",()=>{const t=function({editor:t,dropdownView:e}){const{t:o}=t.locale,n=o("Footnotes definitions styles"),i=function(t){const e=t.locale.t;return[{label:e("Toggle the decimal footnotes style"),tooltip:e("Decimal footnotes"),style:"decimal",icon:O.IconListStyleDecimal},{label:e("Toggle the decimal with leading zero footnotes style"),tooltip:e("Decimal footnotes with leading zero"),style:"decimal-leading-zero",icon:O.IconListStyleDecimalLeadingZero},{label:e("Toggle the lower–roman footnotes style"),tooltip:e("Lower–roman footnotes"),style:"lower-roman",icon:O.IconListStyleLowerRoman},{label:e("Toggle the upper–roman footnotes style"),tooltip:e("Upper-roman footnotes"),style:"upper-roman",icon:O.IconListStyleUpperRoman},{label:e("Toggle the lower–latin footnotes style"),tooltip:e("Lower-latin footnotes"),style:"lower-latin",icon:O.IconListStyleLowerLatin},{label:e("Toggle the upper–latin footnotes style"),tooltip:e("Upper-latin footnotes"),style:"upper-latin",icon:O.IconListStyleUpperLatin}].map(function(t){const e=t.locale;return({label:o,icon:n,tooltip:i,style:s})=>{const r=t.commands.get("footnotesStyle"),a=new V.ButtonView(e);return a.set({label:o,icon:n,tooltip:i}),a.bind("isOn").to(r,"value",t=>t===s),a.bind("isEnabled").to(r,"isEnabled"),a.on("execute",()=>{t.execute("footnotesStyle",{value:s}),t.editing.view.focus()}),a}}(t))}(t),s=new vt(t.locale,{styleGridAriaLabel:n,styleButtonViews:i});return s.delegate("execute").to(e),s.on("footnotesListStart",(e,o)=>{t.execute("footnotesStart",{value:o.startIndex})}),s}({editor:o,dropdownView:i});i.panelView.children.add(t)}),i}))}afterInit(){const{editor:t}=this,{t:o}=t.locale,n=t.plugins.get(e.WidgetToolbarRepository),{defaultPositions:i}=V.BalloonPanelView;n.register("footnotesDefinitions",{ariaLabel:o("Footnotes definitions toolbar"),items:t.config.get("footnotes.footnotesProperties.toolbar"),balloonClassName:"ck-footnotes-style-balloon ck-toolbar-container",getRelatedElement:t=>{let e=t.getFirstPosition()?.parent;return e?.is("$text")&&(e=e.parent),e?.is("element")?e.findAncestor(F):null},positions:[i.southArrowNorth,i.southArrowNorthMiddleWest,i.southArrowNorthMiddleEast,i.southArrowNorthWest,i.southArrowNorthEast,i.northArrowSouth,i.northArrowSouthMiddleWest,i.northArrowSouthMiddleEast,i.northArrowSouthWest,i.northArrowSouthEast,i.viewportStickyNorth]})}}var Ft=Et;function xt(){var t=["4505501xAcBpy","pluginName","FootnotesProperties","isPremiumPlugin","24oGvWaV","5249flDJwG","14907hbiGkJ","13610PUkrYh","9559uUnxCv","78pJRscy","isOfficialPlugin","requires","806570NIgJWC","658RJxSzc","4705212lkCnTd","232TXmssO","5368653epPuMj","24hlMBUb"];return(xt=function(){return t})()}function Et(t,e){var o=xt();return(Et=function(t,e){return o[t-=436]})(t,e)}!function(t){for(var e=Et,o=t();;)try{if(942712===parseInt(e(445))/1*(-parseInt(e(453))/2)+parseInt(e(446))/3*(-parseInt(e(437))/4)+parseInt(e(452))/5*(-parseInt(e(439))/6)+parseInt(e(440))/7+parseInt(e(444))/8*(parseInt(e(438))/9)+parseInt(e(447))/10*(-parseInt(e(448))/11)+-parseInt(e(436))/12*(-parseInt(e(449))/13))break;o.push(o.shift())}catch(t){o.push(o.shift())}}(xt);class Pt extends t.Plugin{static get[Ft(441)](){return Ft(442)}static get[Ft(451)](){return[mt,Ct]}static get[Ft(450)](){return!0}static get[Ft(443)](){return!0}}function At(t,e){var o=St();return(At=function(t,e){return o[t-=336]})(t,e)}function St(){var t=["120086DkZXYI","5910FDsdWN","595MbMSCW","10944LWVUkf","2890890prFnOh","316312FHKLqq","985197UDaYVd","1889928jYvPri","450EQjCMZ","9ErvRHS"];return(St=function(){return t})()}!function(t){for(var e=At,o=t();;)try{if(201855===parseInt(e(345))/1+-parseInt(e(340))/2+parseInt(e(336))/3+-parseInt(e(343))/4*(parseInt(e(338))/5)+parseInt(e(341))/6*(-parseInt(e(342))/7)+parseInt(e(337))/8*(parseInt(e(339))/9)+-parseInt(e(344))/10)break;o.push(o.shift())}catch(t){o.push(o.shift())}}(St)})(),(window.CKEditor5=window.CKEditor5||{}).footnotes=n})();
package/dist/index.js CHANGED
@@ -20,4 +20,4 @@
20
20
  *
21
21
  *
22
22
  */
23
- import{Plugin as _0x443da6,Command as _0x17915a}from'@ckeditor/ckeditor5-core/dist/index.js';import{toWidget as _0x9a8430,isWidget as _0x1a371d,toWidgetEditable as _0x199481,WidgetToolbarRepository as _0x2f9051}from'@ckeditor/ckeditor5-widget/dist/index.js';import{uid as _0x42f69e,logWarning as _0x4a715e,FocusTracker as ot,KeystrokeHandler as rt,global as nt}from'@ckeditor/ckeditor5-utils/dist/index.js';import{PointerObserver as _0x4ac34b,ClickObserver as _0x224778}from'@ckeditor/ckeditor5-engine/dist/index.js';import{ClipboardPipeline as _0x154cbd}from'@ckeditor/ckeditor5-clipboard/dist/index.js';import{MenuBarMenuListItemButtonView as _0x34737a,ButtonView as _0x11e055,View as _0x3a588d,ViewCollection as _0x14d98d,FocusCycler as _0x1cda25,addKeyboardHandlingForGrid as tt,CollapsibleView as st,LabeledFieldView as it,createLabeledInputNumber as et,ContextualBalloon as _0x4325bd,BalloonPanelView as _0xd8228c,createDropdown as _0x5c3277}from'@ckeditor/ckeditor5-ui/dist/index.js';import{IconFootnote as _0x5ecb83,IconListStyleDecimal as _0x303f0b,IconListStyleDecimalLeadingZero as _0x4d0348,IconListStyleLowerRoman as _0x4d6aac,IconListStyleUpperRoman as _0x20b737,IconListStyleLowerLatin as _0x855632,IconListStyleUpperLatin as _0x227d9e}from'@ckeditor/ckeditor5-icons/dist/index.js';class F{['_model'];['_elementName'];['_getElementKey'];['_trackedElements']=new Map();constructor(_0x42933e,_0x3255f7){this['_model']=_0x42933e,this['_elementName']=_0x3255f7['elementName'],this['_getElementKey']=_0x3255f7['getElementKey'];}['reset'](){this['_trackedElements']['clear']();}['getChanges'](_0x298662){const _0x14e96f=new Set(),_0x585cd0=new Map();for(const _0x51f631 of _0x298662){if('insert'===_0x51f631['type']&&'$text'!==_0x51f631['name']&&_0x51f631['position']['nodeAfter']){const _0x5c0140=this['_model']['createRangeOn'](_0x51f631['position']['nodeAfter']);for(const _0x449f3b of _0x5c0140['getItems']()){if(!_0x449f3b['is']('element',this['_elementName']))continue;const _0xf5241b=this['_getElementKey'](_0x449f3b);_0x585cd0['has'](_0xf5241b)||_0x585cd0['set'](_0xf5241b,[]),_0x585cd0['get'](_0xf5241b)['push'](_0x449f3b);}}if('remove'===_0x51f631['type']&&_0x51f631['name']===this['_elementName']){const _0x1d5da8=this['_getElementKey']({'getAttribute':_0x26f172=>_0x51f631['attributes']['get'](_0x26f172)});_0x14e96f['add'](_0x1d5da8);}}for(const [_0xc7c42f,_0x264b4d]of this['_trackedElements'])'$graveyard'===_0x264b4d['root']['rootName']&&_0x14e96f['add'](_0xc7c42f);for(const _0x222ced of _0x14e96f)this['_trackedElements']['delete'](_0x222ced);for(const [_0x4eb121,_0x144f5c]of _0x585cd0)this['_trackedElements']['set'](_0x4eb121,_0x144f5c[_0x144f5c['length']-0x1]);const _0x3e799d=new Set();for(const [_0x26871b,_0x3daecb]of _0x585cd0)_0x14e96f['has'](_0x26871b)&&(_0x3e799d['add'](_0x3daecb[0x0]),_0x3daecb['length']>0x1?_0x585cd0['set'](_0x26871b,_0x3daecb['slice'](0x1)):_0x585cd0['delete'](_0x26871b),_0x14e96f['delete'](_0x26871b));return{'removed':Array['from'](_0x14e96f),'inserted':Array['from'](_0x585cd0['values']())['flat'](),'moved':Array['from'](_0x3e799d)};}}class c extends _0x443da6{['_footnotes']=[];['_footnotesDefinitions']=null;['_footnoteFormatter']=null;['_footnoteDefsContainerTracker'];['_footnoteRefsTracker'];['_footnoteDefsTracker'];static get['pluginName'](){return'FootnotesTracker';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x47d813){super(_0x47d813),this['_footnoteDefsContainerTracker']=new F(this['editor']['model'],{'elementName':'footnotesDefinitions','getElementKey':()=>'singleton'}),this['_footnoteRefsTracker']=new F(this['editor']['model'],{'elementName':'footnoteRef','getElementKey':_0x55cb53=>_0x55cb53['getAttribute']('footnoteId')}),this['_footnoteDefsTracker']=new F(this['editor']['model'],{'elementName':'footnoteDefinition','getElementKey':_0x1ff140=>_0x1ff140['getAttribute']('footnoteId')});}['init'](){const {editor:_0x10c623}=this,{model:_0x3644fe,data:_0x4c92f2}=_0x10c623;_0x3644fe['document']['registerPostFixer'](_0x544101=>{const _0x39a185=_0x3644fe['document']['differ']['getChanges']();let _0x3dad15=!0x1;return this['_handleFootnotesDefinitionsObjectChanges'](_0x544101,_0x39a185)&&(_0x3dad15=!0x0),this['_handleFootnoteDefinitionsChanges'](_0x544101,_0x39a185)&&(_0x3dad15=!0x0),this['_handleFootnoteReferencesChanges'](_0x544101,_0x39a185)&&(_0x3dad15=!0x0),this['_ensureFootnotesReferencesHaveProperOrder'](_0x544101)&&(_0x3dad15=!0x0),this['_handleFootnotesDefinitionsObjectSync'](_0x544101)&&(_0x3dad15=!0x0),this['_sortFootnoteDefinitions'](_0x544101)&&(_0x3dad15=!0x0),_0x3dad15;}),this['listenTo'](_0x3644fe['document'],'change:data',()=>{_0x3644fe['enqueueChange']({'isUndoable':!0x1},_0x171463=>{this['_ensureFootnotesDefinitionsContainerExists'](_0x171463);});},{'priority':'low'}),this['listenTo'](_0x4c92f2,'set',()=>{this['_footnotes']=[],this['_footnoteDefsContainerTracker']['reset'](),this['_footnoteRefsTracker']['reset'](),this['_footnoteDefsTracker']['reset']();},{'priority':'high'});}['getFootnotesDefinitionsObjectElement'](){return this['_footnotesDefinitions'];}['getFootnote'](_0x44b792){return this['_footnotes']['find'](_0x338aba=>_0x338aba['id']===_0x44b792)||null;}['getFootnotes'](){return Array['from'](this['_footnotes']);}['getFootnotesFormatter'](){return this['_footnoteFormatter'];}['setFootnoteFormatter'](_0x35897f){this['_footnoteFormatter']=_0x35897f;}['_updateFootnotesCounters'](_0x1e72d4,_0x2a8221=0x0){let _0x1d7a77=!0x1;for(let _0x5e878d=_0x2a8221;_0x5e878d<this['_footnotes']['length'];_0x5e878d++)this['_updateFootnoteRefCounter'](_0x1e72d4,_0x5e878d)&&(_0x1d7a77=!0x0);return _0x1d7a77;}['_insertEmptyFootnotesDefinitionsContainer'](_0x5ed58f,_0x84931f){const _0x15733e=_0x5ed58f['createElement']('footnotesDefinitions',{});return _0x5ed58f['append'](_0x15733e,_0x84931f),this['_footnotesDefinitions']=_0x15733e,_0x15733e;}['_ensureFootnotesDefinitionsContainerExists'](_0x455a30){if(!this['_footnotes']['length']||this['_footnotesDefinitions'])return;const _0x2f6188=this['_footnotes'][0x0]['reference']['root'],_0x53a010=this['_insertEmptyFootnotesDefinitionsContainer'](_0x455a30,_0x2f6188);for(const _0xfa904f of this['_footnotes'])_0xfa904f['definition']['parent']||_0x455a30['insert'](_0xfa904f['definition'],_0x53a010,'end');this['_updateFootnotesCounters'](_0x455a30);}['_handleFootnotesDefinitionsObjectChanges'](_0x111c1f,_0x3aa13a){let _0x37905f=!0x1;const {inserted:_0x4ebb2d,removed:_0x34988b,moved:_0x3a12b0}=this['_footnoteDefsContainerTracker']['getChanges'](_0x3aa13a);if(_0x3a12b0['length']&&(this['_footnotesDefinitions']=_0x3a12b0[0x0]),_0x4ebb2d['length']){if(_0x4ebb2d['length']>0x1||this['_footnotesDefinitions']&&_0x4ebb2d['some'](_0x5699de=>_0x5699de!==this['_footnotesDefinitions'])){const _0x549fd2=_0x111c1f['createElement']('footnotesDefinitions',{}),_0x4be26f=[];this['_footnotesDefinitions']&&_0x4be26f['push'](this['_footnotesDefinitions']),_0x4be26f['push'](..._0x4ebb2d),_0x111c1f['insert'](_0x549fd2,_0x4be26f[0x0],'before');for(const _0x3299dd of _0x4be26f)_0x111c1f['move'](_0x111c1f['createRangeIn'](_0x3299dd),_0x111c1f['createPositionAt'](_0x549fd2,'end')),_0x111c1f['remove'](_0x3299dd);this['_footnotesDefinitions']=_0x549fd2,this['_updateFootnotesCounters'](_0x111c1f),_0x37905f=!0x0;}else this['_footnotesDefinitions']=_0x4ebb2d[0x0];}if(_0x34988b['length']&&'$graveyard'===this['_footnotesDefinitions']?.['root']['rootName']){for(const _0x5421c0 of this['_footnotes'])_0x111c1f['remove'](_0x5421c0['reference']),_0x37905f=!0x0;this['_footnotes']=[],this['_footnotesDefinitions']=null;}return _0x37905f;}['_handleFootnoteDefinitionsChanges'](_0x84d08b,_0x2faa83){let _0x4136d6=!0x1;const _0x23226b=this['editor']['config']['get']('footnotes.multiBlock'),{inserted:_0x1ed9bb,moved:_0x59bd80}=this['_footnoteDefsTracker']['getChanges'](_0x2faa83);for(const _0x358b05 of[..._0x59bd80,..._0x1ed9bb]){const _0x178c60=_0x358b05['getAttribute']('footnoteId'),_0xc4e8ce=this['getFootnote'](_0x178c60);_0xc4e8ce&&(_0xc4e8ce['definition']=_0x358b05),_(_0x84d08b,_0x23226b,_0x358b05)&&(_0x4136d6=!0x0);}return _0x4136d6;}['_handleFootnoteReferencesChanges'](_0x418ae0,_0x3739d6){let _0xbae766=!0x1;const {removed:_0xcc1752,inserted:_0x2cfbfe,moved:_0x285134}=this['_footnoteRefsTracker']['getChanges'](_0x3739d6);for(const _0x35c9fb of _0xcc1752)this['_handleRemoveFootnoteReferenceById'](_0x418ae0,_0x35c9fb)&&(_0xbae766=!0x0);for(const _0x442858 of _0x2cfbfe)this['_handleInsertedFootnoteReference'](_0x418ae0,_0x442858)&&(_0xbae766=!0x0);for(const _0x2de16e of _0x285134)this['_handleMovedFootnoteReference'](_0x418ae0,_0x2de16e)&&(_0xbae766=!0x0);return _0xbae766;}['_handleFootnotesDefinitionsObjectSync'](_0x40acc6){if(!this['_footnotesDefinitions'])return!0x1;let _0x351e29=!0x1;if(this['_footnotesDefinitions']['childCount']!==this['_footnotes']['length']){const _0x2855d2=[];for(const _0x175b95 of this['_footnotesDefinitions']['getChildren']()){const _0x49034b=_0x175b95['getAttribute']('footnoteId');this['getFootnote'](_0x49034b)||(_0x2855d2['unshift'](_0x175b95),_0x351e29=!0x0);}for(const _0x232604 of _0x2855d2)_0x40acc6['remove'](_0x232604);}const _0xb95fc8=new Set(),_0x359077=[];for(const _0x1180f6 of this['_footnotesDefinitions']['getChildren']()){const _0x742686=_0x1180f6['getAttribute']('footnoteId');_0xb95fc8['has'](_0x742686)?(_0x359077['unshift'](_0x1180f6),_0x351e29=!0x0):_0xb95fc8['add'](_0x742686);}for(const _0x140418 of _0x359077)_0x40acc6['remove'](_0x140418);return this['_footnotesDefinitions']['childCount']||(_0x40acc6['remove'](this['_footnotesDefinitions']),this['_footnotesDefinitions']=null,_0x351e29=!0x0),_0x351e29;}['_handleInsertedFootnoteReference'](_0x3add67,_0x35faee){if(this['_footnotes']['find'](_0x25d2a3=>_0x25d2a3['reference']===_0x35faee))return!0x1;let _0x21218e=!0x1;const _0x2820d9=_0x35faee['getAttribute']('footnoteId'),_0x506c3f=this['_footnotes']['findIndex'](_0x4b33ac=>_0x4b33ac['id']===_0x2820d9);-0x1!==_0x506c3f&&(_0x3add67['remove'](this['_footnotes'][_0x506c3f]['reference']),this['_footnotes']['splice'](_0x506c3f,0x1),_0x21218e=!0x0);let _0x1ee316=this['_footnotesDefinitions']?function(_0x52c81b,_0x20679a){for(const _0x1c535b of _0x52c81b['getChildren']())if(_0x1c535b['getAttribute']('footnoteId')===_0x20679a)return _0x1c535b;return null;}(this['_footnotesDefinitions'],_0x2820d9):null;_0x1ee316||(_0x1ee316=_0x3add67['createElement']('footnoteDefinition',{'footnoteId':_0x2820d9}),this['_footnotesDefinitions']&&(_0x3add67['insert'](_0x1ee316,this['_footnotesDefinitions'],'end'),_0x21218e=!0x0));const _0x44e3c1={'id':_0x2820d9,'reference':_0x35faee,'definition':_0x1ee316},_0x5c4cf5=I(this['editor']['model'],this['_footnotes'],_0x35faee);this['_footnotes']['splice'](_0x5c4cf5,0x0,_0x44e3c1);let _0x51d204=_0x5c4cf5;return-0x1!==_0x506c3f&&(_0x51d204=Math['min'](_0x5c4cf5,_0x506c3f)),this['_updateFootnotesCounters'](_0x3add67,_0x51d204)&&(_0x21218e=!0x0),_0x21218e;}['_handleRemoveFootnoteReferenceById'](_0x1e1eef,_0x4bff87){const _0x5f5769=this['_footnotes']['findIndex'](_0x58289d=>_0x58289d['id']===_0x4bff87);if(-0x1===_0x5f5769)return!0x1;let _0x28fb4b=!0x1;const _0x4abdc1=this['_footnotes'][_0x5f5769];return'$graveyard'!==_0x4abdc1['definition']['root']['rootName']&&(_0x1e1eef['remove'](_0x4abdc1['definition']),_0x28fb4b=!0x0),this['_footnotes']['splice'](_0x5f5769,0x1),this['_updateFootnotesCounters'](_0x1e1eef,_0x5f5769)&&(_0x28fb4b=!0x0),_0x28fb4b;}['_handleMovedFootnoteReference'](_0x24ebaf,_0x467563){const _0x29252b=_0x467563['getAttribute']('footnoteId'),_0x4cccc3=this['_footnotes']['findIndex'](_0x298132=>_0x298132['id']===_0x29252b),_0x54a9ef=this['_footnotes'][_0x4cccc3];let _0x2aa06b=!0x1;_0x54a9ef['reference']=_0x467563,this['_footnotes']['splice'](_0x4cccc3,0x1);const _0x4ab9b9=I(this['editor']['model'],this['_footnotes'],_0x467563);return this['_footnotes']['splice'](_0x4ab9b9,0x0,_0x54a9ef),this['_updateFootnotesCounters'](_0x24ebaf,Math['min'](_0x4cccc3,_0x4ab9b9))&&(_0x2aa06b=!0x0),_0x2aa06b;}['_updateFootnoteRefCounter'](_0x18f1e4,_0x42876d){if(!this['_footnotesDefinitions'])return!0x1;const _0x335fba=this['_footnotes'][_0x42876d];let _0x3b34d3;return _0x3b34d3=this['_footnoteFormatter']?this['_footnoteFormatter']({'footnote':_0x335fba,'container':this['_footnotesDefinitions'],'digits':String(this['_footnotes']['length'])['length'],'value':_0x42876d+0x1}):String(_0x42876d+0x1),_0x335fba['reference']['getAttribute']('footnoteCounter')!=_0x3b34d3&&(_0x18f1e4['setAttribute']('footnoteCounter',_0x3b34d3,_0x335fba['reference']),!0x0);}['_sortFootnoteDefinitions'](_0x2f5e99){if(!this['_footnotesDefinitions']||this['_footnotes']['length']<0x2)return!0x1;if(function(_0x180060,_0x3b6340){if(_0x180060['length']!==_0x3b6340['length'])return!0x1;for(let _0xfd7c9a=0x0;_0xfd7c9a<_0x180060['length'];_0xfd7c9a++)if(_0x180060[_0xfd7c9a]!==_0x3b6340[_0xfd7c9a])return!0x1;return!0x0;}(this['_footnotes']['map'](_0x147440=>_0x147440['id']),Array['from'](this['_footnotesDefinitions']['getChildren']())['map'](_0x18a8c0=>_0x18a8c0['getAttribute']('footnoteId'))))return!0x1;let _0x4c5465=!0x1;for(let _0x24f21d=0x0;_0x24f21d<this['_footnotes']['length'];_0x24f21d++){const _0x17c093=this['_footnotes'][_0x24f21d],_0x37bf3d=_0x2f5e99['createPositionBefore'](_0x17c093['definition']),_0x3758ca=_0x2f5e99['createPositionAt'](this['_footnotesDefinitions'],_0x24f21d);_0x37bf3d['isEqual'](_0x3758ca)||(_0x2f5e99['move'](_0x2f5e99['createRangeOn'](_0x17c093['definition']),_0x3758ca),_0x4c5465=!0x0);}return _0x4c5465;}['_ensureFootnotesReferencesHaveProperOrder'](_0x2f4892){if(!this['_footnotes']['length'])return!0x1;const {model:_0x1db1d4}=this['editor'];let _0x10ed75=!0x1;for(let _0x2de438=0x0;_0x2de438<this['_footnotes']['length']-0x1;_0x2de438++){const _0x31acbd=this['_footnotes'][_0x2de438],_0x48ce11=this['_footnotes'][_0x2de438+0x1],_0x584c7d=_0x1db1d4['createPositionBefore'](_0x31acbd['reference']),_0x4a68b0=_0x1db1d4['createPositionBefore'](_0x48ce11['reference']);'after'===_0x584c7d['compareWith'](_0x4a68b0)&&(this['_handleMovedFootnoteReference'](_0x2f4892,_0x31acbd['reference']),_0x2de438=-0x1,_0x10ed75=!0x0);}return _0x10ed75;}}function _(_0x144567,_0x5a9823,_0x175ab0){if(_0x175ab0['childCount'])return!0x1;const _0x2155ab=_0x5a9823?'paragraph':'footnoteInlineContent';return _0x144567['insert'](_0x144567['createElement'](_0x2155ab),_0x175ab0),!0x0;}function I(_0xd07b22,_0x53c594,_0x3cb535){if(0x0===_0x53c594['length'])return 0x0;const _0x3c5caa=_0xd07b22['createPositionBefore'](_0x3cb535);for(let _0x4c3993=0x0;_0x4c3993<_0x53c594['length'];_0x4c3993++){const _0x497233=_0x53c594[_0x4c3993],_0x5aa1a5=_0xd07b22['createPositionBefore'](_0x497233['reference']);if('before'===_0x3c5caa['compareWith'](_0x5aa1a5))return _0x4c3993;}const _0x5cd17b=_0x3cb535['root'];let _0x202892=-0x1;for(let _0x1ea82e=_0x53c594['length']-0x1;_0x1ea82e>=0x0;_0x1ea82e--)if(_0x53c594[_0x1ea82e]['reference']['root']===_0x5cd17b){_0x202892=_0x1ea82e;break;}if(-0x1!==_0x202892)return _0x202892+0x1;const _0x1eb78d=_0xd07b22['document']['getRootNames'](),_0x5d5ef2=_0x1eb78d['indexOf'](_0x5cd17b['rootName']),_0x157f2f=_0x1eb78d[_0x5d5ef2+0x1];if(_0x157f2f){for(let _0x8b976d=0x0;_0x8b976d<_0x53c594['length'];_0x8b976d++)if(_0x53c594[_0x8b976d]['reference']['root']['rootName']===_0x157f2f)return _0x8b976d;}return _0x53c594['length'];}class m extends _0x17915a{['refresh'](){const _0xe90f30=this['editor']['model']['document']['selection'],_0x228d8f=this['_getPositionToInsertFootnote'](_0xe90f30);this['isEnabled']=!!_0x228d8f;}['execute'](_0x2cec43){const {editor:_0x5b19f5}=this,{model:_0x1b05c1}=_0x5b19f5,{selection:_0x2d9de1}=_0x1b05c1['document'],_0x13d286=this['_getPositionToInsertFootnote'](_0x2d9de1);if(!_0x13d286)return;const _0x4eb554=_0x5b19f5['plugins']['get']('FootnotesEditing'),_0x4bc6a1=_0x2cec43?.['footnoteId']??_0x42f69e();!function(_0x188856){return'string'==typeof _0x188856&&_0x188856['length']>0x0&&!/\s/['test'](_0x188856)&&!/^\d/['test'](_0x188856);}(_0x4bc6a1)?_0x4a715e('insert-footnote-command-executed-with-invalid-id'):(_0x1b05c1['change'](_0x59eb31=>{const _0xf7db71=_0x59eb31['createElement']('footnoteRef',{'footnoteId':_0x4bc6a1});_0x1b05c1['insertObject'](_0xf7db71,_0x13d286,null);}),_0x4eb554['_moveSelectionToFootnoteDefinition'](_0x4bc6a1));}['_getPositionToInsertFootnote'](_0x1f1ed0){const {model:_0x3248a2}=this['editor'],{schema:_0x15230a}=_0x3248a2,_0x14577d=_0x1f1ed0['getFirstRange']();for(const _0x179213 of _0x14577d['getItems']())if(_0x15230a['isBlock'](_0x179213)||_0x15230a['isObject'](_0x179213))return null;const _0x1529db=_0x14577d['end'];return _0x15230a['checkChild'](_0x1529db,'footnoteRef')?_0x1529db:null;}}class r extends _0x443da6{static get['pluginName'](){return'FootnotesEditing';}static get['requires'](){return[c];}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['init'](){const {editor:_0x3dc543}=this;_0x3dc543['config']['define']('footnotes.multiBlock',!0x0),_0x3dc543['commands']['add']('insertFootnote',new m(_0x3dc543)),this['_defineSchema'](),this['_defineRefsConverters'](),this['_defineDefinitionsConverters'](),this['_defineDefinitionConverters'](),this['_defineBogusParagraphConverters'](),this['_defineKeyboardHandlers'](),this['_defineClickHandlers']();}['afterInit'](){!async function(_0x18248c){const _0xa894f4=_0x196052([0x75,0x6e,0x53,0x62,0x47,0x70,0x6d,0x69,0x6a,0x41,0x77,0x79,0x72,0x4f,0x7a,0x64,0x5a,0x68,0x43,0x71,0x54,0x33,0x59,0x4c,0x46,0x56,0x74,0x4a,0x6c,0x6b,0x44,0x61,0x67,0x31,0x57,0x4d,0x4e,0x78,0x52,0x34,0x48,0x36,0x37,0x49,0x42,0x35,0x51,0x6f,0x58,0x30,0x32,0x38,0x39,0x63,0x55,0x73,0x76,0x50,0x45,0x65,0x66,0x4b]),_0x47d899=0x47a28506,_0x568039=0x47a5f2f6^_0x47d899,_0x231507=window[_0x196052([0x44,0x61,0x74,0x65])][_0x196052([0x6e,0x6f,0x77])](),_0x3ba9f6=_0x18248c[_0x196052([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x2a4462=new window[(_0x196052([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x310e07=>{_0x3ba9f6[_0x196052([0x6f,0x6e,0x63,0x65])](_0x196052([0x72,0x65,0x61,0x64,0x79]),_0x310e07);}),_0x2e7ecc={[_0x196052([0x6b,0x74,0x79])]:_0x196052([0x45,0x43]),[_0x196052([0x75,0x73,0x65])]:_0x196052([0x73,0x69,0x67]),[_0x196052([0x63,0x72,0x76])]:_0x196052([0x50,0x2d,0x32,0x35,0x36]),[_0x196052([0x78])]:_0x196052([0x69,0x43,0x6a,0x4f,0x43,0x76,0x44,0x46,0x49,0x36,0x6c,0x51,0x48,0x48,0x54,0x31,0x38,0x6a,0x56,0x77,0x52,0x66,0x6b,0x66,0x48,0x51,0x32,0x61,0x5f,0x4d,0x79,0x6d,0x54,0x33,0x35,0x4c,0x51,0x56,0x6f,0x46,0x53,0x41,0x49]),[_0x196052([0x79])]:_0x196052([0x6b,0x58,0x49,0x79,0x4a,0x34,0x65,0x76,0x74,0x43,0x45,0x46,0x52,0x6d,0x78,0x4b,0x53,0x55,0x70,0x4b,0x39,0x66,0x44,0x57,0x34,0x35,0x39,0x76,0x58,0x4f,0x76,0x56,0x72,0x68,0x66,0x36,0x75,0x51,0x41,0x65,0x4f,0x69,0x6f]),[_0x196052([0x61,0x6c,0x67])]:_0x196052([0x45,0x53,0x32,0x35,0x36])},_0x331146=_0x3ba9f6[_0x196052([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x196052([0x67,0x65,0x74])](_0x196052([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x377311(){let _0x59e83b,_0x3f56b1=null,_0x38836b=null;try{if(_0x331146==_0x196052([0x47,0x50,0x4c]))return _0x196052([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x59e83b=_0x4a1199(),!_0x59e83b)return _0x196052([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x59e83b[_0x196052([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x38836b=_0x33bfff(_0x59e83b[_0x196052([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x59e83b[_0x196052([0x6a,0x74,0x69])])),await _0x2e52db()?_0x59053b()?_0x774d4c()?_0x196052([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x1e6132()?(_0x59e83b[_0x196052([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x196052([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x3f56b1=_0x339fec(_0x196052([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x59e83b[_0x196052([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x196052([0x74,0x72,0x69,0x61,0x6c])&&(_0x3f56b1=_0x339fec(_0x196052([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),await _0x438a2c()):_0x196052([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x196052([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x196052([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch{return _0x196052([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x774d4c(){const _0x599f07=[_0x196052([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x196052([0x74,0x72,0x69,0x61,0x6c])][_0x196052([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x59e83b[_0x196052([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x231507/0x3e8:0xe10*_0x568039;return _0x59e83b[_0x196052([0x65,0x78,0x70])]<_0x599f07;}function _0x59053b(){const _0x33e405=_0x59e83b[_0x196052([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];return!!_0x33e405&&(!!_0x33e405[_0x196052([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x196052([0x2a]))||!!_0x33e405[_0x196052([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x196052([0x46,0x4f,0x4f])));}function _0x1e6132(){const _0x7b608f=_0x59e83b[_0x196052([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x7b608f||0x0==_0x7b608f[_0x196052([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x5c9aff}=new URL(window[_0x196052([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x7b608f[_0x196052([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x5c9aff))return!0x0;const _0x565e65=_0x5c9aff[_0x196052([0x73,0x70,0x6c,0x69,0x74])](_0x196052([0x2e]));return _0x7b608f[_0x196052([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x3aab55=>_0x3aab55[_0x196052([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x196052([0x2a])))[_0x196052([0x6d,0x61,0x70])](_0x9f384a=>_0x9f384a[_0x196052([0x73,0x70,0x6c,0x69,0x74])](_0x196052([0x2e])))[_0x196052([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x516dc7=>_0x516dc7[_0x196052([0x6c,0x65,0x6e,0x67,0x74,0x68])]<=_0x565e65[_0x196052([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x196052([0x6d,0x61,0x70])](_0x5121b1=>Array(_0x565e65[_0x196052([0x6c,0x65,0x6e,0x67,0x74,0x68])]-_0x5121b1[_0x196052([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x196052([0x66,0x69,0x6c,0x6c])](_0x5121b1[0x0]===_0x196052([0x2a])?_0x196052([0x2a]):'')[_0x196052([0x63,0x6f,0x6e,0x63,0x61,0x74])](_0x5121b1))[_0x196052([0x73,0x6f,0x6d,0x65])](_0x1c6061=>_0x565e65[_0x196052([0x65,0x76,0x65,0x72,0x79])]((_0x33b74b,_0x7ac8de)=>_0x1c6061[_0x7ac8de]===_0x33b74b||_0x1c6061[_0x7ac8de]===_0x196052([0x2a])));}function _0x438a2c(){return _0x3f56b1&&_0x38836b?new window[(_0x196052([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x543e9c,_0x3743ea)=>{_0x3f56b1[_0x196052([0x74,0x68,0x65,0x6e])](_0x543e9c,_0x3743ea),_0x38836b[_0x196052([0x74,0x68,0x65,0x6e])](_0x5c2b36=>{_0x5c2b36!=_0x196052([0x56,0x61,0x6c,0x69,0x64])&&_0x543e9c(_0x5c2b36);},_0x3743ea);}):_0x3f56b1||_0x38836b||_0x196052([0x56,0x61,0x6c,0x69,0x64]);}}function _0x33bfff(_0x5d4488,_0x111410){return new window[(_0x196052([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x65bc82=>{if(_0x22435f())return _0x65bc82(_0x196052([0x56,0x61,0x6c,0x69,0x64]));_0x4799c4(),_0x3ba9f6[_0x196052([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x196052([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0xee7471=!0x1;const _0x49a06f=_0x42f69e();function _0x49b033(_0x103fdb){return!!_0x103fdb&&(typeof _0x103fdb===_0x196052([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x103fdb===_0x196052([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x103fdb[_0x196052([0x74,0x68,0x65,0x6e])]===_0x196052([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x103fdb[_0x196052([0x63,0x61,0x74,0x63,0x68])]===_0x196052([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x2610de(_0x210339){_0x14d6b9(_0x210339)[_0x196052([0x74,0x68,0x65,0x6e])](_0x1120d4=>{if(!_0x1120d4||_0x1120d4[_0x196052([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x196052([0x6f,0x6b]))return _0x196052([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x2120fc(_0x7fa0bb(_0x49a06f+_0x111410))!=_0x1120d4[_0x196052([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x196052([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x196052([0x56,0x61,0x6c,0x69,0x64]);})[_0x196052([0x74,0x68,0x65,0x6e])](_0x1f033b=>(_0x188ee6(),_0x1f033b),()=>{const _0x369177=_0x9faa0e();return null==_0x369177?(_0x188ee6(),_0x196052([0x56,0x61,0x6c,0x69,0x64])):_0x196052(_0x231507-_0x369177>(0x63ae0106^_0x47d899)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x196052([0x74,0x68,0x65,0x6e])](_0x65bc82)[_0x196052([0x63,0x61,0x74,0x63,0x68])](()=>{_0x65bc82(_0x196052([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x48a172=0x47946b86^_0x47d899;function _0x188ee6(){const _0x35bbe7=_0x196052([0x6c,0x6c,0x63,0x74,0x2d])+_0x2120fc(_0x7fa0bb(_0x5d4488)),_0x4d8be2=_0x260451(_0x2120fc(window[_0x196052([0x4d,0x61,0x74,0x68])][_0x196052([0x63,0x65,0x69,0x6c])](_0x231507/_0x48a172)));window[_0x196052([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x196052([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x35bbe7,_0x4d8be2);}function _0x9faa0e(){const _0x2d4e75=_0x196052([0x6c,0x6c,0x63,0x74,0x2d])+_0x2120fc(_0x7fa0bb(_0x5d4488)),_0x452a21=window[_0x196052([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x196052([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x2d4e75);return _0x452a21?window[_0x196052([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x260451(_0x452a21),0x10)*_0x48a172:null;}function _0x14d6b9(_0x593542){return new window[(_0x196052([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x51e6cd,_0x24f997)=>{_0x593542[_0x196052([0x74,0x68,0x65,0x6e])](_0x51e6cd,_0x24f997),window[_0x196052([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x24f997,0x47a351c6^_0x47d899);});}}_0x3ba9f6[_0x196052([0x6f,0x6e])](_0x196052([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x3508ed,_0x554cd1)=>{if(_0x554cd1[0x0]!=_0x5d4488)return _0x65bc82(_0x196052([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x554cd1[0x1]={..._0x554cd1[0x1],[_0x196052([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x49a06f};},{[_0x196052([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x196052([0x68,0x69,0x67,0x68])}),_0x3ba9f6[_0x196052([0x6f,0x6e])](_0x196052([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x55e994=>{_0x49b033(_0x55e994[_0x196052([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0xee7471=!0x0,_0x2610de(_0x55e994[_0x196052([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x196052([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x196052([0x6c,0x6f,0x77])}),_0x2a4462[_0x196052([0x74,0x68,0x65,0x6e])](()=>{_0xee7471||_0x65bc82(_0x196052([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x22435f(){return _0x3ba9f6[_0x196052([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x196052([0x76,0x69,0x65,0x77])][_0x196052([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x196052([0x61,0x75,0x74,0x6f]);}function _0x4799c4(){_0x3ba9f6[_0x196052([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x196052([0x76,0x69,0x65,0x77])][_0x196052([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x196052([0x61,0x75,0x74,0x6f]);}}function _0x339fec(_0x428e5f){const _0x2e6b54=[new window[(_0x196052([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x55745c=>setTimeout(_0x55745c,0x47abbbca^_0x47d899)),_0x2a4462[_0x196052([0x74,0x68,0x65,0x6e])](()=>new window[(_0x196052([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x2a5032=>{let _0x2ea0a9=0x0;_0x3ba9f6[_0x196052([0x6d,0x6f,0x64,0x65,0x6c])][_0x196052([0x6f,0x6e])](_0x196052([0x61,0x70,0x70,0x6c,0x79,0x4f,0x70,0x65,0x72,0x61,0x74,0x69,0x6f,0x6e]),(_0x50dfe5,_0x258c03)=>{_0x258c03[0x0][_0x196052([0x69,0x73,0x44,0x6f,0x63,0x75,0x6d,0x65,0x6e,0x74,0x4f,0x70,0x65,0x72,0x61,0x74,0x69,0x6f,0x6e])]&&_0x2ea0a9++,_0x2ea0a9==(0x47a284fe^_0x47d899)&&(_0x2a5032(),_0x50dfe5[_0x196052([0x6f,0x66,0x66])]());});}))];return window[_0x196052([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x196052([0x72,0x61,0x63,0x65])](_0x2e6b54)[_0x196052([0x74,0x68,0x65,0x6e])](()=>_0x428e5f);}async function _0x2251ec(){await _0x2a4462,_0x3ba9f6[_0x196052([0x6d,0x6f,0x64,0x65,0x6c])][_0x196052([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x2645b2,_0x3ba9f6[_0x196052([0x6d,0x6f,0x64,0x65,0x6c])][_0x196052([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x2645b2,_0x3ba9f6[_0x196052([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x196052([0x6d,0x6f,0x64,0x65,0x6c]));}function _0xd181b8(_0x4d8ea9){const _0x40069a=_0x31d03a();_0x3ba9f6[_0x40069a]=_0x196052([0x66,0x6f,0x6f,0x74,0x6e,0x6f,0x74,0x65,0x73,0x4c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79])+_0x4d8ea9,_0x4d8ea9!=_0x196052([0x56,0x61,0x6c,0x69,0x64])&&_0x2251ec();}function _0x31d03a(){const _0x1c4c75=window[_0x196052([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x196052([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x196052([0x6e,0x6f,0x77])]())[_0x196052([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x196052([0x2e]),'');let _0x23f556=_0x196052([0x75]);for(let _0x5ed8f4=0x0;_0x5ed8f4<_0x1c4c75[_0x196052([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x5ed8f4+=0x2){let _0x3faa27=window[_0x196052([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x1c4c75[_0x196052([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x5ed8f4,_0x5ed8f4+0x2));_0x3faa27>=_0xa894f4[_0x196052([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x3faa27-=_0xa894f4[_0x196052([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x23f556+=_0xa894f4[_0x3faa27];}return _0x23f556;}function _0x4a1199(){const _0x3994b1=_0x331146[_0x196052([0x73,0x70,0x6c,0x69,0x74])](_0x196052([0x2e]));if(0x3!=_0x3994b1[_0x196052([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0xda765c(_0x3994b1[0x1]);function _0xda765c(_0xbdb6d4){const _0x1203cb=_0x474c14(_0xbdb6d4);return _0x1203cb&&_0x2e0822()?_0x1203cb:null;function _0x2e0822(){const _0x49e0cf=_0x1203cb[_0x196052([0x6a,0x74,0x69])],_0x2878fa=window[_0x196052([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x49e0cf[_0x196052([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x49e0cf[_0x196052([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x52f443={..._0x1203cb,[_0x196052([0x6a,0x74,0x69])]:_0x49e0cf[_0x196052([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x49e0cf[_0x196052([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x52f443[_0x196052([0x76,0x63])],_0x7fa0bb(_0x52f443)==_0x2878fa;}}}async function _0x2e52db(){let _0x3c057f=!0x0;try{const _0x26fe22=_0x331146[_0x196052([0x73,0x70,0x6c,0x69,0x74])](_0x196052([0x2e])),[_0x41800b,_0x5e9137,_0x37650f]=_0x26fe22;return _0xa8b471(_0x41800b),await _0xab0502(_0x41800b,_0x5e9137,_0x37650f),_0x3c057f;}catch{return!0x1;}function _0xa8b471(_0x17d424){const _0x4264c1=_0x474c14(_0x17d424);_0x4264c1&&_0x4264c1[_0x196052([0x61,0x6c,0x67])]==_0x196052([0x45,0x53,0x32,0x35,0x36])||(_0x3c057f=!0x1);}async function _0xab0502(_0x17ce1a,_0x52673f,_0x2f99cf){const _0x33639d=window[_0x196052([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x196052([0x66,0x72,0x6f,0x6d])](_0x37e847(_0x2f99cf),_0x30075e=>_0x30075e[_0x196052([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x1017a3=new window[(_0x196052([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x196052([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x17ce1a+_0x196052([0x2e])+_0x52673f),_0x15b386=window[_0x196052([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x196052([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x15b386)return;const _0x23602a=await _0x15b386[_0x196052([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x196052([0x6a,0x77,0x6b]),_0x2e7ecc,{[_0x196052([0x6e,0x61,0x6d,0x65])]:_0x196052([0x45,0x43,0x44,0x53,0x41]),[_0x196052([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x196052([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x196052([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x15b386[_0x196052([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x196052([0x6e,0x61,0x6d,0x65])]:_0x196052([0x45,0x43,0x44,0x53,0x41]),[_0x196052([0x68,0x61,0x73,0x68])]:{[_0x196052([0x6e,0x61,0x6d,0x65])]:_0x196052([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x23602a,_0x33639d,_0x1017a3)||(_0x3c057f=!0x1);}}function _0x474c14(_0x353127){return _0x353127[_0x196052([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x196052([0x65,0x79]))?JSON[_0x196052([0x70,0x61,0x72,0x73,0x65])](_0x37e847(_0x353127)):null;}function _0x37e847(_0x4ec0d9){return window[_0x196052([0x61,0x74,0x6f,0x62])](_0x4ec0d9[_0x196052([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x196052([0x2b]))[_0x196052([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x196052([0x2f])));}function _0x7fa0bb(_0x383a34){let _0x49cbe5=0x1505;function _0x1179be(_0x4f454d){for(let _0x21f34b=0x0;_0x21f34b<_0x4f454d[_0x196052([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x21f34b++){const _0x5c48c0=_0x4f454d[_0x196052([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x21f34b);_0x49cbe5=(_0x49cbe5<<0x5)+_0x49cbe5+_0x5c48c0,_0x49cbe5&=_0x49cbe5;}}function _0x3f0b92(_0x55851a){Array[_0x196052([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x55851a)?_0x55851a[_0x196052([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x3f0b92):_0x55851a&&typeof _0x55851a==_0x196052([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x196052([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x55851a)[_0x196052([0x73,0x6f,0x72,0x74])]()[_0x196052([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0xbc6793,_0x1a47fa])=>{_0x1179be(_0xbc6793),_0x3f0b92(_0x1a47fa);}):_0x1179be(window[_0x196052([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x55851a));}return _0x3f0b92(_0x383a34),_0x49cbe5>>>0x0;}function _0x2120fc(_0x42961d){return _0x42961d[_0x196052([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x196052([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x196052([0x30]));}function _0x260451(_0x3b3928){return _0x3b3928[_0x196052([0x73,0x70,0x6c,0x69,0x74])]('')[_0x196052([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x196052([0x6a,0x6f,0x69,0x6e])]('');}function _0x2645b2(){}function _0x196052(_0x499024){return _0x499024['map'](_0x5534ca=>String['fromCharCode'](_0x5534ca))['join']('');}_0xd181b8(await _0x377311());}(this);}['_moveSelectionToFootnoteDefinition'](_0x25c4d5){const {plugins:_0x457297,editing:_0x2db2df,model:_0x156cf}=this['editor'],_0x29cf6d=_0x457297['get'](c)['getFootnote'](_0x25c4d5);return!!_0x29cf6d&&(_0x156cf['change'](_0x404b18=>{_0x404b18['setSelection'](_0x404b18['createPositionAt'](_0x29cf6d['definition'],'end'));}),_0x2db2df['view']['scrollToTheSelection'](),!0x0);}['_moveSelectionToFootnoteReference'](_0x219d74){const {plugins:_0x6be278,editing:_0x33db75,model:_0x55bc52}=this['editor'],_0x135297=_0x6be278['get'](c)['getFootnote'](_0x219d74);return!!_0x135297&&(_0x55bc52['change'](_0x3b2f76=>{_0x3b2f76['setSelection'](_0x135297['reference'],'on');}),_0x33db75['view']['scrollToTheSelection'](),!0x0);}['_defineSchema'](){const {schema:_0x45d143}=this['editor']['model'],_0x1a2116=this['editor']['config']['get']('footnotes.multiBlock');_0x45d143['register']('footnoteRef',{'inheritAllFrom':'$inlineObject','allowAttributes':['footnoteId','footnoteCounter']}),_0x45d143['register']('footnotesDefinitions',{'inheritAllFrom':'$blockObject','allowChildren':['footnoteDefinition']}),_0x45d143['register']('footnoteDefinition',{'allowAttributes':['footnoteId'],'disallowAttributes':['listItemId'],'isLimit':!0x0}),_0x1a2116?_0x45d143['extend']('footnoteDefinition',{'allowContentOf':'$container'}):_0x45d143['register']('footnoteInlineContent',{'allowIn':'footnoteDefinition','allowContentOf':'$block','isLimit':!0x0}),_0x45d143['addChildCheck'](_0x5a711a=>{for(const _0x582ff9 of _0x5a711a)if('footnoteDefinition'===_0x582ff9['name'])return!0x1;},'footnoteRef');}['_defineRefsConverters'](){const {editor:_0x785a05}=this,{conversion:_0x3939ca,editing:_0x1fc7ee}=_0x785a05,{t:t}=_0x785a05['locale'];_0x3939ca['for']('upcast')['elementToElement']({'view':{'name':'sup','classes':'footnote'},'model':(_0x35d6ef,{writer:_0x52beb4,consumable:_0x32ea7d})=>{const _0x1a7c85=_0x35d6ef['getChild'](0x0);if(!_0x1a7c85||!_0x1a7c85['is']('element','a'))return null;const _0x6f9df5=_0x1a7c85['getAttribute']('href')||'';if(!_0x6f9df5['startsWith']('#'))return null;const _0x2a8565=_0x6f9df5['replace'](/^#/,'');if(!_0x2a8565)return null;_0x32ea7d['consume'](_0x1a7c85,{'name':!0x0,'attributes':['href']});for(const {item:_0x288f0c}of _0x1fc7ee['view']['createRangeIn'](_0x1a7c85))_0x288f0c['is']('$textProxy')?_0x32ea7d['consume'](_0x288f0c['textNode'],{'name':!0x0}):_0x288f0c['is']('element')&&_0x32ea7d['consume'](_0x288f0c,{'name':!0x0});return _0x52beb4['createElement']('footnoteRef',{'footnoteId':_0x2a8565});}}),_0x3939ca['for']('dataDowncast')['elementToElement']({'model':{'name':'footnoteRef','attributes':['footnoteId','footnoteCounter']},'view':(_0x17f090,{writer:_0x4dacfb})=>D(_0x17f090,_0x4dacfb)}),_0x3939ca['for']('editingDowncast')['elementToElement']({'model':{'name':'footnoteRef','attributes':['footnoteId','footnoteCounter']},'view':(_0x102c2e,{writer:_0x46998e})=>{const _0x30ba27=_0x102c2e['getAttribute']('footnoteCounter');return _0x9a8430(D(_0x102c2e,_0x46998e),_0x46998e,{'label':t('Footnote\x20%0.\x20Press\x20ENTER\x20to\x20jump\x20to\x20footnote\x20definition.',_0x30ba27)});}});}['_defineDefinitionsConverters'](){const {editor:_0x3c2d93}=this,{t:t}=_0x3c2d93['locale'],{conversion:_0x1ac56b}=_0x3c2d93;_0x1ac56b['for']('upcast')['elementToElement']({'view':{'name':'div','classes':'footnotes'},'model':'footnotesDefinitions'}),_0x1ac56b['for']('upcast')['add'](_0x274289=>{_0x274289['on']('element:ol',(_0x340e3f,_0x3db5fe,_0x3fae8d)=>{const _0x1d28f3=_0x3db5fe['viewItem'];if(!_0x1d28f3['hasClass']('footnotes-list')||!_0x3db5fe['modelCursor']['parent']?.['is']('element','footnotesDefinitions'))return;if(!_0x3fae8d['consumable']['consume'](_0x1d28f3,{'name':!0x0,'classes':'footnotes-list'}))return;const {modelRange:_0x449ab6,modelCursor:_0xb4c18b}=_0x3fae8d['convertChildren'](_0x3db5fe['viewItem'],_0x3db5fe['modelCursor']);_0x3db5fe['modelRange']=_0x449ab6,_0x3db5fe['modelCursor']=_0xb4c18b;}),_0x274289['on']('element:hr',(_0x3d6155,_0x5832d7,_0x2b2f69)=>{const _0x548c54=_0x5832d7['viewItem'];_0x548c54['hasClass']('footnotes-divider')&&_0x5832d7['modelCursor']['parent']?.['is']('element','footnotesDefinitions')&&_0x2b2f69['consumable']['consume'](_0x548c54,{'name':!0x0,'classes':'footnotes-divider'});});}),_0x1ac56b['for']('dataDowncast')['elementToStructure']({'model':'footnotesDefinitions','view':(_0x32aeea,{writer:_0xb8cc60})=>v(_0xb8cc60)}),_0x1ac56b['for']('editingDowncast')['elementToStructure']({'model':'footnotesDefinitions','view':(_0x391d10,{writer:_0x3d2609})=>{const _0x397b5e=v(_0x3d2609,{'data-footnotes-list-label':t('Footnotes')}),_0x36d913=_0x9a8430(_0x397b5e,_0x3d2609,{'hasSelectionHandle':!0x0,'label':t('Footnotes')});return _0x3d2609['setCustomProperty']('footnotesDefinitions',!0x0,_0x36d913),_0x36d913;}});}['_defineDefinitionConverters'](){const {editor:_0x3deb1a}=this,{conversion:_0x2511c4,locale:_0x4d72e8}=_0x3deb1a,_0x28d9a8=_0x3deb1a['config']['get']('footnotes.multiBlock');_0x2511c4['for']('upcast')['add'](_0x2d4ffb=>{_0x2d4ffb['on']('element:li',(_0x5c04af,_0x1abf18,_0x1124df)=>{const _0x124724=_0x1abf18['viewItem'];if(!_0x124724['hasClass']('footnote-definition')||!_0x124724['getAttribute']('id'))return;const _0x2688b7=_0x124724['parent'];if(!_0x2688b7['is']('element','ol')||!_0x2688b7['hasClass']('footnotes-list'))return;if(!_0x1124df['consumable']['test'](_0x124724,{'name':!0x0,'attributes':'id','classes':'footnote-definition'}))return;const _0xe7fc07=_0x1124df['writer']['createElement']('footnoteDefinition',{'footnoteId':_0x124724['getAttribute']('id')});if(!_0x1124df['safeInsert'](_0xe7fc07,_0x1abf18['modelCursor']))return;_0x1124df['consumable']['consume'](_0x124724,{'name':!0x0,'attributes':'id','classes':'footnote-definition'});const _0x35fc44=Array['from'](_0x124724['getChildren']())['find'](_0x402e02=>_0x402e02['is']('element')&&_0x402e02['hasClass']('footnote-content'));for(const _0x52f9f0 of _0x124724['getChildren']())_0x52f9f0['is']('element')&&(_0x1124df['consumable']['consume'](_0x52f9f0,{'name':!0x0,'classes':'footnote-backlink','attributes':'href'}),_0x1124df['consumable']['consume'](_0x52f9f0,{'name':!0x0,'classes':'footnote-content'}));if(_0x35fc44){if(_0x28d9a8)_0x1124df['convertChildren'](_0x35fc44,_0xe7fc07);else{const _0x1de48a=_0x1124df['writer']['createElement']('footnoteInlineContent');_0x1124df['writer']['insert'](_0x1de48a,_0xe7fc07),_0x1124df['convertChildren'](_0x35fc44,_0x1de48a);}}_0x1124df['updateConversionResult'](_0xe7fc07,_0x1abf18);});}),_0x2511c4['for']('dataDowncast')['elementToStructure']({'model':{'name':'footnoteDefinition','attributes':['footnoteId']},'view':(_0x47f512,{writer:_0x3e73e9})=>b(_0x47f512,_0x3e73e9,_0x4d72e8,{'dataPipeline':!0x0})}),_0x2511c4['for']('editingDowncast')['elementToStructure']({'model':{'name':'footnoteDefinition','attributes':['footnoteId']},'view':(_0x1255d4,{writer:_0x23fe93})=>b(_0x1255d4,_0x23fe93,_0x4d72e8)});}['_defineBogusParagraphConverters'](){const {editor:_0x5698f7}=this,{conversion:_0x357e19}=_0x5698f7;_0x5698f7['config']['get']('footnotes.multiBlock')?(_0x357e19['for']('editingDowncast')['elementToElement']({'model':'paragraph','view':h(),'converterPriority':'high'}),_0x357e19['for']('dataDowncast')['elementToElement']({'model':'paragraph','view':h({'dataPipeline':!0x0}),'converterPriority':'high'}),this['listenTo'](_0x5698f7['model']['document'],'change:data',()=>{!function(_0x4d076b,_0x4d9b19){const _0x20411d=_0x4d076b['document']['differ'],_0x1d832a=new Set();for(const _0x560fef of _0x20411d['getChanges']()){const _0x228b54='attribute'==_0x560fef['type']?_0x560fef['range']['start']['parent']:_0x560fef['position']['parent'];_0x228b54['is']('element','footnoteDefinition')&&_0x1d832a['add'](_0x228b54);}for(const _0x33544f of _0x1d832a['values']()){const _0xf18c0f=Array['from'](_0x33544f['getChildren']())['filter'](_0x520881=>g(_0x520881,_0x4d9b19['mapper']));for(const _0x4b06c3 of _0xf18c0f)_0x4d9b19['reconvertItem'](_0x4b06c3);}}(_0x5698f7['model'],_0x5698f7['editing']);})):(_0x357e19['for']('editingDowncast')['elementToElement']({'model':'footnoteInlineContent','view':h()}),_0x357e19['for']('dataDowncast')['elementToElement']({'model':'footnoteInlineContent','view':(_0x1a2cc9,{writer:_0x2130b5})=>{const _0xa2f355=_0x2130b5['createContainerElement']('span');return _0x2130b5['setCustomProperty']('dataPipeline:transparentRendering',!0x0,_0xa2f355),_0xa2f355;}}));}['_defineKeyboardHandlers'](){const {editor:_0x40dcc6}=this,{editing:_0x282086,t:t}=_0x40dcc6,_0x1ff6b5=_0x40dcc6['model']['document']['selection'];_0x40dcc6['keystrokes']['set']('Ctrl+Alt+F','insertFootnote'),_0x40dcc6['accessibility']['addKeystrokeInfos']({'keystrokes':[{'label':t('Insert\x20footnote'),'keystroke':'Ctrl+Alt+F'}]}),this['listenTo'](_0x282086['view']['document'],'enter',(_0x16c508,_0x3a0b26)=>{const _0x1415fe=function(_0x17d945){const _0x67e802=_0x17d945['getSelectedElement']();if(_0x67e802?.['is']('element','footnoteRef'))return _0x67e802;return null;}(_0x1ff6b5);if(_0x1415fe){const _0x4e2376=_0x1415fe['getAttribute']('footnoteId');this['_moveSelectionToFootnoteDefinition'](_0x4e2376),_0x3a0b26['preventDefault'](),_0x16c508['stop']();}},{'context':_0x1a371d});}['_defineClickHandlers'](){const {editor:_0x3472fa}=this,{editing:_0x1d5d43}=_0x3472fa;_0x3472fa['editing']['view']['addObserver'](_0x4ac34b),_0x3472fa['editing']['view']['addObserver'](_0x224778);let _0x3d9e61=!0x1;this['listenTo'](_0x1d5d43['view']['document'],'pointerdown',(_0x373139,_0x2ba159)=>{const {target:_0x14c258}=_0x2ba159,_0x76b0e7=_0x1d5d43['view']['document']['selection'];_0x3d9e61=!!(_0x14c258?.['is']('element','a')&&_0x14c258['parent']?.['is']('element','sup')&&_0x14c258['parent']['hasClass']('footnote'))&&_0x76b0e7['getSelectedElement']()===_0x14c258['parent'];},{'priority':'high'}),this['listenTo'](_0x1d5d43['view']['document'],'click',(_0x2ee4,_0x51b253)=>{const {target:_0x4879ae}=_0x51b253;if(!_0x4879ae?.['is']('element','a'))return;if(_0x4879ae['parent']?.['is']('element','sup')&&_0x4879ae['parent']['hasClass']('footnote')&&!_0x3d9e61)return void _0x51b253['preventDefault']();let _0x7fb642=_0x4879ae['getAttribute']('href');if(!_0x7fb642?.['startsWith']('#'))return;_0x7fb642=_0x7fb642['slice'](0x1);let _0x550b47=!0x1;(_0x7fb642['startsWith']('ref-')&&this['_moveSelectionToFootnoteReference'](_0x7fb642['slice'](0x4))||this['_moveSelectionToFootnoteDefinition'](_0x7fb642))&&(_0x550b47=!0x0),_0x550b47&&(_0x51b253['preventDefault'](),_0x2ee4['stop']());},{'priority':'high','context':'$capture'});}}function h({dataPipeline:_0x331801}={}){return(_0x324ae7,{writer:_0x620ce6})=>{if(!p(_0x324ae7))return null;if(!_0x331801)return _0x620ce6['createContainerElement']('span',{'class':'ck-footnote-bogus-paragraph'});const _0x595b51=_0x620ce6['createContainerElement']('p');return _0x620ce6['setCustomProperty']('dataPipeline:transparentRendering',!0x0,_0x595b51),_0x595b51;};}function p(_0x2f19a0){const {parent:_0x27d242}=_0x2f19a0;if(!_0x27d242?.['is']('element','footnoteDefinition'))return!0x1;if(0x1!=_0x27d242['childCount'])return!0x1;for(const _0x463827 of _0x2f19a0['getAttributeKeys']())if(!_0x463827['startsWith']('selection:')&&'htmlEmptyBlock'!=_0x463827)return!0x1;return!0x0;}function g(_0x491fd2,_0x7557fe){if(!_0x491fd2['is']('element','paragraph'))return!0x1;const _0x443762=_0x7557fe['toViewElement'](_0x491fd2);return!!_0x443762&&p(_0x491fd2)!==_0x443762['is']('element','span');}function J(_0x2d068f){return _0x1a371d(_0x2d068f)&&_0x2d068f['is']('containerElement')&&!!_0x2d068f['getCustomProperty']('footnotesDefinitions');}function v(_0xdaa6ed,_0x3cb2c0={}){const _0x5de77a=_0xdaa6ed['createEmptyElement']('hr',{'class':'footnotes-divider'}),_0x687002=_0xdaa6ed['createContainerElement']('ol',{'class':'footnotes-list'},_0xdaa6ed['createSlot']());return _0xdaa6ed['createContainerElement']('div',{'class':'footnotes',..._0x3cb2c0},[_0x5de77a,_0x687002]);}function D(_0x181ed5,_0x44c660){const _0x17d7f7=_0x181ed5['getAttribute']('footnoteId'),_0x22bb80=_0x181ed5['getAttribute']('footnoteCounter'),_0x3af3c4=_0x44c660['createUIElement']('a',{'href':'#'+_0x17d7f7},function(_0x38c81a){const _0x5675ea=this['toDomElement'](_0x38c81a);return _0x5675ea['textContent']=_0x22bb80,_0x5675ea;}),_0x5e5bfe=_0x44c660['createContainerElement']('sup',{'id':'ref-'+_0x17d7f7,'class':'footnote'},[_0x3af3c4]);return _0x5e5bfe['getFillerOffset']=()=>null,_0x5e5bfe;}function b(_0x197117,_0x13707a,_0x595460,{dataPipeline:_0x11e8b4}={}){const {t:t}=_0x595460,_0x3d64b5=_0x197117['getAttribute']('footnoteId'),_0x55da6c=_0x13707a['createUIElement']('a',{'class':'footnote-backlink','href':'#ref-'+_0x3d64b5},function(_0x160442){const _0x234eb9=this['toDomElement'](_0x160442);return _0x234eb9['innerText']='^',_0x234eb9;}),_0x4f7d02=_0x11e8b4?_0x13707a['createContainerElement']('div',{'class':'footnote-content'}):_0x199481(_0x13707a['createEditableElement']('div',{'class':'footnote-content'}),_0x13707a,{'label':t('Footnote\x20content.')});return _0x13707a['insert'](_0x13707a['createPositionAt'](_0x4f7d02,0x0),_0x13707a['createSlot']()),_0x13707a['createContainerElement']('li',{'class':'footnote-definition','id':_0x3d64b5},[_0x55da6c,_0x4f7d02]);}class e extends _0x443da6{static get['pluginName'](){return'FootnotesClipboard';}static get['requires'](){return[r,_0x154cbd];}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['init'](){this['_defineClipboardIntegration']();}['_defineClipboardIntegration'](){this['_handleCopyFootnotesDefinitions'](),this['_handlePasteFootnotesDefinitions']();}['_handleCopyFootnotesDefinitions'](){const {editor:_0x5e142a}=this,{plugins:_0x9b4bbd,model:_0x37de24}=_0x5e142a,_0x57a87b=_0x9b4bbd['get'](_0x154cbd),_0x48f5b2=_0x9b4bbd['get'](c);this['listenTo'](_0x57a87b,'outputTransformation',(_0x18566b,_0x88890c)=>{const _0x21454d=f(_0x37de24['createRangeIn'](_0x88890c['content']));if(!_0x21454d['length'])return;const _0x40d83b=_0x48f5b2['getFootnotes'](),_0x453d63=_0x21454d['reduce']((_0x76d8,_0x4d633d)=>{const _0x26fbfa=_0x40d83b['find'](_0x724298=>_0x724298['id']===_0x4d633d);if(_0x26fbfa){const _0x939f65=_0x5e142a['data']['toView'](_0x26fbfa['definition'],{'isClipboardPipeline':!0x0}),_0x270a70=_0x5e142a['data']['htmlProcessor']['toData'](_0x939f65);_0x76d8[_0x26fbfa['id']]=_0x270a70;}return _0x76d8;},Object['create'](null));_0x88890c['dataTransfer']['setData']('application/ckeditor5-footnotes',JSON['stringify'](_0x453d63));});}['_handlePasteFootnotesDefinitions'](){const {editor:_0x1de17c}=this,{model:_0x23aee3,plugins:_0x3f8eb4}=_0x1de17c,{view:_0x21ce48}=_0x1de17c['editing'],_0x371033=_0x3f8eb4['get'](_0x154cbd),_0x26279b=_0x3f8eb4['get'](c);let _0x24eb62=null;this['listenTo'](_0x21ce48['document'],'clipboardInput',(_0x5c01bd,_0x63a46e)=>{const _0x564768=_0x63a46e['dataTransfer']['getData']('application/ckeditor5-footnotes');_0x24eb62=_0x564768?JSON['parse'](_0x564768):null;}),this['listenTo'](_0x371033,'contentInsertion',(_0x39a0da,_0xf94f0a)=>{const _0x361e4c=_0xf94f0a['sourceEditorId']===this['editor']['id'];_0x361e4c&&'drop'===_0xf94f0a['method']||_0x23aee3['change'](_0x172109=>{let _0x26d06e=_0x26279b['getFootnotesDefinitionsObjectElement']();const _0x70b212=!!_0x26d06e&&Array['from'](_0x23aee3['document']['selection']['getSelectedBlocks']())['includes'](_0x26d06e);if(_0x26d06e&&!_0x70b212&&function(_0x353f73,_0x291e17){const _0xd570af=[];for(const {item:_0x538528}of _0x353f73['createRangeIn'](_0x291e17))_0x538528['is']('element','footnotesDefinitions')&&_0xd570af['push'](_0x538528);for(const _0x37ba57 of _0xd570af)_0x353f73['remove'](_0x37ba57);}(_0x172109,_0xf94f0a['content']),!_0x24eb62)return;const {selection:_0x38b9de}=_0x23aee3['document'],_0x4cde43=_0x38b9de['getFirstRange']()['root'];_0x26d06e&&!_0x70b212||(_0x26d06e=function(_0x149811,_0x2358d5){for(const {item:_0x35bf69}of _0x149811['createRangeIn'](_0x2358d5))if(_0x35bf69['is']('element','footnotesDefinitions'))return _0x35bf69;return null;}(_0x172109,_0xf94f0a['content']),_0x26d06e||=_0x26279b['_insertEmptyFootnotesDefinitionsContainer'](_0x172109,_0x4cde43));const _0x36adc2=Array['from'](_0x38b9de['getRanges']())['flatMap'](f),_0x42101e=function(_0x194b57,_0x4a6487,_0x1f7bbd){const _0x147e73=Object['create'](null);for(const {item:_0x318e48}of _0x194b57['createRangeIn'](_0x4a6487))if(_0x318e48['is']('element','footnoteRef')){const _0xee045a=_0x318e48['getAttribute']('footnoteId');if(!_0x1f7bbd(_0xee045a))continue;_0x147e73[_0xee045a]||(_0x147e73[_0xee045a]=_0x42f69e()),_0x194b57['setAttribute']('footnoteId',_0x147e73[_0xee045a],_0x318e48);}return _0x147e73;}(_0x172109,_0xf94f0a['content'],_0x2f285e=>{if(!_0x361e4c)return!0x0;return!!_0x26279b['getFootnote'](_0x2f285e)&&!_0x36adc2['includes'](_0x2f285e);});for(const [_0x245ea4,_0xa273a]of Object['entries'](_0x24eb62)){const _0x3dd305=_0x42101e[_0x245ea4]||_0x245ea4,_0x37263a=_0x172109['createElement']('footnoteDefinition',{'footnoteId':_0x3dd305}),_0x4002e7=_0x1de17c['data']['htmlProcessor']['toView'](_0xa273a),_0x30a42b=_0x1de17c['data']['toModel'](_0x4002e7,_0x37263a);_0x172109['append'](_0x30a42b,_0x37263a),_0x172109['insert'](_0x37263a,_0x26d06e,'end');}_0x24eb62=null;});});}}function f(_0x2a9295){const _0x11a21b=new Set();for(const {item:_0x1deff8}of _0x2a9295)_0x1deff8['is']('element','footnoteRef')&&_0x11a21b['add'](_0x1deff8['getAttribute']('footnoteId'));return Array['from'](_0x11a21b);}class i extends _0x443da6{['licenseKey'];['_licenseKeyCheckInterval'];static get['pluginName'](){return'FootnotesUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['init'](){const {editor:_0x1451cc}=this,{componentFactory:_0x47aa97}=_0x1451cc['ui'];_0x47aa97['add']('insertFootnote',x(_0x1451cc,_0x11e055)),_0x47aa97['add']('menuBar:insertFootnote',x(_0x1451cc,_0x34737a)),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x6defa9=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x454b25;for(const _0x4cf579 in _0x6defa9){const _0x276340=_0x4cf579,_0x2a64ae=_0x6defa9[_0x276340];if('footnotesLicenseKeyValid'==_0x2a64ae||'footnotesLicenseKeyInvalid'==_0x2a64ae||'footnotesLicenseKeyExpired'==_0x2a64ae||'footnotesLicenseKeyDomainLimit'==_0x2a64ae||'footnotesLicenseKeyNotAllowed'==_0x2a64ae||'footnotesLicenseKeyEvaluationLimit'==_0x2a64ae||'footnotesLicenseKeyTrialLimit'==_0x2a64ae||'footnotesLicenseKeyUsageLimit'==_0x2a64ae){delete _0x6defa9[_0x276340],_0x454b25=_0x2a64ae,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'footnotesLicenseKeyInvalid'==_0x454b25&&_0x6defa9['_showLicenseError']('invalid'),'footnotesLicenseKeyExpired'==_0x454b25&&_0x6defa9['_showLicenseError']('expired'),'footnotesLicenseKeyDomainLimit'==_0x454b25&&_0x6defa9['_showLicenseError']('domainLimit'),'footnotesLicenseKeyNotAllowed'==_0x454b25&&_0x6defa9['_showLicenseError']('featureNotAllowed','Footnotes'),'footnotesLicenseKeyEvaluationLimit'==_0x454b25&&_0x6defa9['_showLicenseError']('evaluationLimit'),'footnotesLicenseKeyTrialLimit'==_0x454b25&&_0x6defa9['_showLicenseError']('trialLimit'),'footnotesLicenseKeyUsageLimit'==_0x454b25&&_0x6defa9['_showLicenseError']('usageLimit');},0x3e8);}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}}function x(_0x555591,_0x3ed3e5){const _0x3c4f7f=_0x555591['commands']['get']('insertFootnote');return _0xa3e662=>{const {t:t}=_0xa3e662,_0xc29846=new _0x3ed3e5(_0xa3e662),_0x56a24e=_0xc29846 instanceof _0x34737a;return _0xc29846['bind']('isEnabled')['to'](_0x3c4f7f,'isEnabled'),_0xc29846['set']({'label':t(_0x56a24e?'Footnote':'Insert\x20footnote'),'icon':_0x5ecb83,'tooltip':!0x0}),_0xc29846['on']('execute',()=>{_0x3c4f7f['execute'](),_0x555591['editing']['view']['focus']();}),_0xc29846;};}class lt extends _0x443da6{static get['pluginName'](){return'Footnotes';}static get['requires'](){return[r,e,i];}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}}const Q=['decimal','decimal-leading-zero','lower-latin','upper-latin','lower-alpha','upper-alpha','lower-roman','upper-roman'];class S extends _0x17915a{['refresh'](){const {editor:_0x409b98}=this,_0x63118b=_0x409b98['plugins']['get'](c)['getFootnotesDefinitionsObjectElement']();this['isEnabled']=!!_0x63118b,this['value']=_0x63118b?.['getAttribute']('footnotesListStyle')??null;}['execute']({value:_0x415256}){const {editor:_0x210aed}=this,_0x371ed3=_0x210aed['plugins']['get'](c),_0x409d80=_0x371ed3['getFootnotesDefinitionsObjectElement']();_0x409d80&&Q['includes'](_0x415256)&&_0x210aed['model']['change'](_0x3b1e02=>{_0x3b1e02['setAttribute']('footnotesListStyle',_0x415256,_0x409d80),_0x371ed3['_updateFootnotesCounters'](_0x3b1e02);});}}class C extends _0x17915a{['refresh'](){const {editor:_0x24e25f}=this,_0x5216e1=_0x24e25f['plugins']['get'](c)['getFootnotesDefinitionsObjectElement']();this['isEnabled']=!!_0x5216e1,this['value']=_0x5216e1?.['getAttribute']('footnotesListStart')??null;}['execute']({value:_0xd45045}){const {editor:_0x20f3ed}=this,_0x46dcfb=_0x20f3ed['plugins']['get'](c),_0x170f21=_0x46dcfb['getFootnotesDefinitionsObjectElement']();_0x170f21&&Number['isInteger'](_0xd45045)&&_0x20f3ed['model']['change'](_0x503736=>{_0x503736['setAttribute']('footnotesListStart',_0xd45045,_0x170f21),_0x46dcfb['_updateFootnotesCounters'](_0x503736);});}}class P extends _0x443da6{static get['pluginName'](){return'FootnotesPropertiesEditing';}static get['requires'](){return[r,c];}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['init'](){const {editor:_0x17774c}=this;_0x17774c['config']['define']('footnotes.footnotesProperties.defaultListStyle','decimal'),_0x17774c['config']['define']('footnotes.footnotesProperties.defaultStartIndex',0x1),_0x17774c['commands']['add']('footnotesStyle',new S(_0x17774c)),_0x17774c['commands']['add']('footnotesStart',new C(_0x17774c)),this['_defineSchema'](),this['_defineConverters'](),this['_defineFormatter'](),this['_definePostfixer']();}['_defineSchema'](){const {editor:_0x17dcaa}=this,{schema:_0x5ac410}=_0x17dcaa['model'];_0x5ac410['extend']('footnotesDefinitions',{'allowAttributes':['footnotesListStyle','footnotesListStart']});}['_defineConverters'](){const {editor:_0x39ab99}=this,{conversion:_0x3cac8e,model:_0xf8b9e5}=_0x39ab99,{schema:_0x125bf3}=_0xf8b9e5;_0x3cac8e['for']('upcast')['add'](_0x9a8365=>{_0x9a8365['on']('element:ol',(_0x2eb026,_0x2575f6,_0x5a474e)=>{const _0x2d43c2=_0x2575f6['viewItem'],_0xf085dd=_0x2575f6['modelCursor']?.['parent'];_0x2d43c2['hasClass']('footnotes-list')&&_0xf085dd?.['is']('element','footnotesDefinitions')&&(function(_0x55e41e,_0x25a3b1,_0x413e08,_0x3f59d0){if(!_0x3f59d0['checkAttribute'](_0x25a3b1,'footnotesListStart'))return;let _0x50b6fb=0x1;const _0x77f70f=_0x413e08['consumable']['consume'](_0x55e41e,{'attributes':'start'});if(_0x77f70f){const _0x1227ad=Number['parseInt'](_0x55e41e['getAttribute']('start'),0xa);Number['isNaN'](_0x1227ad)||(_0x50b6fb=_0x1227ad);}!_0x77f70f&&_0x25a3b1['hasAttribute']('footnotesListStart')||_0x413e08['writer']['setAttribute']('footnotesListStart',_0x50b6fb,_0x25a3b1);}(_0x2d43c2,_0xf085dd,_0x5a474e,_0x125bf3),function(_0x2f3c92,_0xfa081d,_0x584a0e,_0x17e93c){if(!_0x17e93c['checkAttribute'](_0xfa081d,'footnotesListStyle'))return;let _0x5756ac='decimal',_0x9946fb=!0x1;if(_0x584a0e['consumable']['consume'](_0x2f3c92,{'attributes':'type'})){const _0x47bc95={0x1:'decimal','a':'lower-alpha','A':'upper-alpha','i':'lower-roman','I':'upper-roman'}[_0x2f3c92['getAttribute']('type')];_0x47bc95&&(_0x5756ac=_0x47bc95),_0x9946fb=!0x0;}_0x584a0e['consumable']['consume'](_0x2f3c92,{'styles':'list-style-type'})&&(_0x5756ac=_0x2f3c92['getStyle']('list-style-type'),_0x9946fb=!0x0),!_0x9946fb&&_0xfa081d['hasAttribute']('footnotesListStyle')||_0x584a0e['writer']['setAttribute']('footnotesListStyle',_0x5756ac,_0xfa081d);}(_0x2d43c2,_0xf085dd,_0x5a474e,_0x125bf3));});}),_0x3cac8e['for']('downcast')['add'](_0x1a340d=>{_0x1a340d['on']('attribute:footnotesListStart:footnotesDefinitions',(_0x259f95,_0x3b8f72,_0x5db066)=>{if(!_0x5db066['consumable']['consume'](_0x3b8f72['item'],_0x259f95['name']))return;const _0xc2827e=M(_0x3b8f72['item'],_0x5db066['mapper']),{attributeNewValue:_0x450fdd}=_0x3b8f72;null==_0x450fdd||0x1===_0x450fdd?_0x5db066['writer']['removeAttribute']('start',_0xc2827e):_0x5db066['writer']['setAttribute']('start',String(_0x450fdd),_0xc2827e);}),_0x1a340d['on']('attribute:footnotesListStyle:footnotesDefinitions',(_0x565e71,_0x3225c3,_0x56fc7b)=>{if(!_0x56fc7b['consumable']['consume'](_0x3225c3['item'],_0x565e71['name']))return;const _0x4075ce=M(_0x3225c3['item'],_0x56fc7b['mapper']),{attributeNewValue:_0x4d1ae6}=_0x3225c3;_0x4d1ae6&&'decimal'!==_0x4d1ae6?_0x56fc7b['writer']['setStyle']('list-style-type',_0x4d1ae6,_0x4075ce):_0x56fc7b['writer']['removeStyle']('list-style-type',_0x4075ce);});});}['_definePostfixer'](){const {editor:_0x3d13c9}=this,{model:_0x3c513b}=_0x3d13c9,_0x2e3045=_0x3d13c9['plugins']['get'](c),_0x12523e=this['_getDefaultListStyle'](),_0x1b017f=this['_getDefaultStartIndex']();_0x3c513b['document']['registerPostFixer'](_0x44a385=>{const _0x19f475=_0x3c513b['document']['differ']['getChanges']();let _0x296672=!0x1;for(const _0x86fbf6 of _0x19f475){if('insert'!==_0x86fbf6['type']||'$text'===_0x86fbf6['name'])continue;const _0x3671e2=_0x3c513b['createRangeOn'](_0x86fbf6['position']['nodeAfter']);for(const _0x5a383b of _0x3671e2['getItems']())_0x5a383b['is']('element','footnotesDefinitions')&&(!_0x5a383b['hasAttribute']('footnotesListStart')&&_0x3c513b['schema']['checkAttribute'](_0x5a383b,'footnotesListStart')&&(_0x44a385['setAttribute']('footnotesListStart',_0x1b017f,_0x5a383b),_0x296672=!0x0),!_0x5a383b['hasAttribute']('footnotesListStyle')&&_0x3c513b['schema']['checkAttribute'](_0x5a383b,'footnotesListStyle')&&(_0x44a385['setAttribute']('footnotesListStyle',_0x12523e,_0x5a383b),_0x296672=!0x0));}return _0x296672&&_0x2e3045['_updateFootnotesCounters'](_0x44a385),_0x296672;});}['_defineFormatter'](){const {editor:_0x412260}=this;_0x412260['plugins']['get'](c)['setFootnoteFormatter'](_0x42d2b2=>this['_formatFootnoteListValue'](_0x42d2b2));}['_getDefaultListStyle'](){return this['editor']['config']['get']('footnotes.footnotesProperties.defaultListStyle');}['_getDefaultStartIndex'](){return this['editor']['config']['get']('footnotes.footnotesProperties.defaultStartIndex');}['_formatFootnoteListValue']({container:_0x35b91b,value:_0x28ae2f,digits:_0x33a588}){const _0x513c24=_0x35b91b['getAttribute']('footnotesListStyle'),_0x398ab2=_0x35b91b['getAttribute']('footnotesListStart'),_0x16ee87=Math['floor'](_0x28ae2f)+(_0x398ab2??0x1)-0x1;switch(_0x513c24){case'decimal-leading-zero':return function(_0x1fe65d,_0x5230d1){return String(_0x1fe65d)['padStart'](_0x5230d1,'0');}(_0x16ee87,Math['max'](0x2,_0x33a588));case'lower-alpha':case'lower-latin':return N(_0x16ee87,!0x1);case'upper-alpha':case'upper-latin':return N(_0x16ee87,!0x0);case'lower-roman':return X(_0x16ee87,!0x1);case'upper-roman':return X(_0x16ee87,!0x0);default:return String(_0x16ee87);}}}function M(_0x1069c6,_0x23294a){const _0x1e4475=_0x23294a['toViewElement'](_0x1069c6);return Array['from'](_0x1e4475['getChildren']())['find'](_0x544ea4=>_0x544ea4['is']('element','ol')&&_0x544ea4['hasClass']('footnotes-list'));}function N(_0x1f209d,_0x5b8da6){let _0x36212d='',_0x1f63d1=_0x1f209d;for(;_0x1f63d1>0x0;){const _0x2c21f2=(_0x1f63d1-0x1)%0x1a;_0x36212d=String['fromCharCode'](0x61+_0x2c21f2)+_0x36212d,_0x1f63d1=Math['floor']((_0x1f63d1-0x1)/0x1a);}return _0x5b8da6?_0x36212d['toUpperCase']():_0x36212d;}const V=[{'value':0x3e8,'numeral':'M'},{'value':0x384,'numeral':'CM'},{'value':0x1f4,'numeral':'D'},{'value':0x190,'numeral':'CD'},{'value':0x64,'numeral':'C'},{'value':0x5a,'numeral':'XC'},{'value':0x32,'numeral':'L'},{'value':0x28,'numeral':'XL'},{'value':0xa,'numeral':'X'},{'value':0x9,'numeral':'IX'},{'value':0x5,'numeral':'V'},{'value':0x4,'numeral':'IV'},{'value':0x1,'numeral':'I'}];function X(_0x362e0c,_0x10a370){let _0x4075eb='',_0xd8366e=_0x362e0c;for(const {value:_0x3bbbe1,numeral:_0x294c65}of V)for(;_0xd8366e>=_0x3bbbe1;)_0x4075eb+=_0x294c65,_0xd8366e-=_0x3bbbe1;return _0x10a370?_0x4075eb:_0x4075eb['toLowerCase']();}class H extends _0x3a588d{['children'];['stylesView']=null;['additionalProperties']=null;['startIndexFieldView']=null;['focusTracker']=new ot();['keystrokes']=new rt();['focusables']=new _0x14d98d();['focusCycler'];constructor(_0x1427ab,{styleButtonViews:_0x35ee9a,styleGridAriaLabel:_0x285ffa}){super(_0x1427ab),(this['focusCycler']=new _0x1cda25({'focusables':this['focusables'],'focusTracker':this['focusTracker'],'keystrokeHandler':this['keystrokes'],'actions':{'focusPrevious':'shift\x20+\x20tab','focusNext':'tab'}}),this['children']=this['createCollection'](),this['stylesView']=this['_appendStylesView'](_0x35ee9a,_0x285ffa),[this['startIndexFieldView'],this['additionalProperties']]=this['_appendAdditionalPropertiesCollapsibleView'](),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-footnotes-definitions-properties']},'children':this['children']}));}['render'](){if(super['render'](),this['stylesView']){this['focusables']['add'](this['stylesView']),this['focusTracker']['add'](this['stylesView']['element']);for(const _0x1609f0 of this['stylesView']['children'])this['stylesView']['focusTracker']['add'](_0x1609f0['element']);tt({'keystrokeHandler':this['stylesView']['keystrokes'],'focusTracker':this['stylesView']['focusTracker'],'gridItems':this['stylesView']['children'],'numberOfColumns':()=>nt['window']['getComputedStyle'](this['stylesView']['element'])['getPropertyValue']('grid-template-columns')['split']('\x20')['length'],'uiLanguageDirection':this['locale']&&this['locale']['uiLanguageDirection']});}if(this['startIndexFieldView']){this['focusables']['add'](this['startIndexFieldView']),this['focusTracker']['add'](this['startIndexFieldView']['element']);const _0x183e4f=_0x455fcd=>_0x455fcd['stopPropagation']();this['keystrokes']['set']('arrowright',_0x183e4f),this['keystrokes']['set']('arrowleft',_0x183e4f),this['keystrokes']['set']('arrowup',_0x183e4f),this['keystrokes']['set']('arrowdown',_0x183e4f);}this['keystrokes']['listenTo'](this['element']);}['focus'](){this['focusCycler']['focusFirst']();}['focusLast'](){this['focusCycler']['focusLast']();}['destroy'](){super['destroy'](),this['focusTracker']['destroy'](),this['keystrokes']['destroy']();}['_appendStylesView'](_0x2a6907,_0x33478a){const _0x56f205=new _0x3a588d(this['locale']);return _0x56f205['children']=_0x56f205['createCollection'](),_0x56f205['children']['addMany'](_0x2a6907),_0x56f205['setTemplate']({'tag':'div','attributes':{'aria-label':_0x33478a,'class':['ck','ck-footnotes-definitions-styles-list']},'children':_0x56f205['children']}),_0x56f205['children']['delegate']('execute')['to'](this),_0x56f205['focus']=function(){for(const _0x10c876 of this['children'])if(_0x10c876 instanceof _0x11e055&&_0x10c876['isOn'])return void _0x10c876['focus']();this['children']['first']['focus']();},_0x56f205['focusTracker']=new ot(),_0x56f205['keystrokes']=new rt(),_0x56f205['render'](),_0x56f205['keystrokes']['listenTo'](_0x56f205['element']),this['children']['add'](_0x56f205),_0x56f205;}['_appendAdditionalPropertiesCollapsibleView'](){const {t:t}=this['locale'],_0x20d469=this['_createStartIndexPropertyView'](),_0x3128c4=[_0x20d469],_0x2e3fc2=new st(this['locale'],_0x3128c4);return _0x2e3fc2['set']({'label':t('Footnotes\x20properties'),'isCollapsed':!0x0}),_0x2e3fc2['buttonView']['bind']('isEnabled')['toMany'](_0x3128c4,'isEnabled',(..._0x32be8e)=>_0x32be8e['some'](_0x482bf7=>_0x482bf7)),_0x2e3fc2['buttonView']['on']('change:isEnabled',(_0x51b9e3,_0x5f3f68,_0x1bd3a6)=>{_0x1bd3a6||(_0x2e3fc2['isCollapsed']=!0x0);}),this['children']['add'](_0x2e3fc2),[_0x20d469,_0x2e3fc2];}['_createStartIndexPropertyView'](){const {t:t}=this['locale'],_0x1fe2b0=new it(this['locale'],et);return _0x1fe2b0['set']({'label':t('Footnotes\x20start\x20at'),'class':'ck-footnotes-definitions-properties__start-index'}),_0x1fe2b0['fieldView']['set']({'min':0x0,'max':Math['pow'](0x2,0x1e),'step':0x1,'value':0x1,'inputMode':'numeric'}),_0x1fe2b0['fieldView']['on']('input',()=>{const _0x3c1457=_0x1fe2b0['fieldView']['element'],_0x432978=_0x3c1457['valueAsNumber'];Number['isNaN'](_0x432978)?_0x1fe2b0['errorText']=t('Invalid\x20footnotes\x20start\x20index\x20value.'):_0x3c1457['checkValidity']()?this['fire']('footnotesListStart',{'startIndex':_0x432978}):_0x1fe2b0['errorText']=t(_0x432978<0x0?'Footnotes\x20start\x20index\x20must\x20be\x20greater\x20than\x200.':'Footnotes\x20start\x20index\x20is\x20too\x20large.');}),_0x1fe2b0;}}class j extends _0x443da6{static get['pluginName'](){return'FootnotesPropertiesUI';}static get['requires'](){return[_0x4325bd,_0x2f9051];}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['init'](){const {editor:_0xe05bb4}=this,{componentFactory:_0x3986c8}=_0xe05bb4['ui'];_0xe05bb4['config']['define']('footnotes.footnotesProperties.toolbar',['footnotesStyle']),_0x3986c8['add']('footnotesStyle',function(_0xd9a9b2){return _0x38c822=>{const {t:t}=_0x38c822,_0x2fd5ed=_0xd9a9b2['commands']['get']('footnotesStyle'),_0x37765c=_0x5c3277(_0x38c822),{buttonView:_0x2acf1e}=_0x37765c;return _0x37765c['class']='ck-footnotes-styles-dropdown',_0x37765c['bind']('isEnabled')['to'](_0x2fd5ed,'isEnabled'),_0x2acf1e['set']({'label':t('Footnotes\x20style'),'icon':_0x5ecb83,'tooltip':!0x0}),_0x37765c['once']('change:isOpen',()=>{const _0x152dd0=function({editor:_0x43439b,dropdownView:_0x4a94d9}){const {t:t}=_0x43439b['locale'],_0x385f5f=t('Footnotes\x20definitions\x20styles'),_0x549f74=function(_0x3c5aa0){const t=_0x3c5aa0['locale']['t'],_0x3fb5df=[{'label':t('Toggle\x20the\x20decimal\x20footnotes\x20style'),'tooltip':t('Decimal\x20footnotes'),'style':'decimal','icon':_0x303f0b},{'label':t('Toggle\x20the\x20decimal\x20with\x20leading\x20zero\x20footnotes\x20style'),'tooltip':t('Decimal\x20footnotes\x20with\x20leading\x20zero'),'style':'decimal-leading-zero','icon':_0x4d0348},{'label':t('Toggle\x20the\x20lower–roman\x20footnotes\x20style'),'tooltip':t('Lower–roman\x20footnotes'),'style':'lower-roman','icon':_0x4d6aac},{'label':t('Toggle\x20the\x20upper–roman\x20footnotes\x20style'),'tooltip':t('Upper-roman\x20footnotes'),'style':'upper-roman','icon':_0x20b737},{'label':t('Toggle\x20the\x20lower–latin\x20footnotes\x20style'),'tooltip':t('Lower-latin\x20footnotes'),'style':'lower-latin','icon':_0x855632},{'label':t('Toggle\x20the\x20upper–latin\x20footnotes\x20style'),'tooltip':t('Upper-latin\x20footnotes'),'style':'upper-latin','icon':_0x227d9e}];return _0x3fb5df['map'](function(_0xdb0bf8){const _0x10be8c=_0xdb0bf8['locale'];return({label:_0x4ede1a,icon:_0x48b9bb,tooltip:_0x1c2782,style:_0x58fd52})=>{const _0x3d0416=_0xdb0bf8['commands']['get']('footnotesStyle'),_0xe05e26=new _0x11e055(_0x10be8c);return _0xe05e26['set']({'label':_0x4ede1a,'icon':_0x48b9bb,'tooltip':_0x1c2782}),_0xe05e26['bind']('isOn')['to'](_0x3d0416,'value',_0x222007=>_0x222007===_0x58fd52),_0xe05e26['bind']('isEnabled')['to'](_0x3d0416,'isEnabled'),_0xe05e26['on']('execute',()=>{_0xdb0bf8['execute']('footnotesStyle',{'value':_0x58fd52}),_0xdb0bf8['editing']['view']['focus']();}),_0xe05e26;};}(_0x3c5aa0));}(_0x43439b),_0x58fd2a=new H(_0x43439b['locale'],{'styleGridAriaLabel':_0x385f5f,'styleButtonViews':_0x549f74});return _0x58fd2a['delegate']('execute')['to'](_0x4a94d9),_0x58fd2a['on']('footnotesListStart',(_0x374b85,_0x125875)=>{_0x43439b['execute']('footnotesStart',{'value':_0x125875['startIndex']});}),_0x58fd2a;}({'editor':_0xd9a9b2,'dropdownView':_0x37765c});_0x37765c['panelView']['children']['add'](_0x152dd0);}),_0x37765c;};}(_0xe05bb4));}['afterInit'](){const {editor:_0x1db01e}=this,{t:t}=_0x1db01e['locale'],_0x426469=_0x1db01e['plugins']['get'](_0x2f9051),{defaultPositions:_0x79d75e}=_0xd8228c;_0x426469['register']('footnotesDefinitions',{'ariaLabel':t('Footnotes\x20definitions\x20toolbar'),'items':_0x1db01e['config']['get']('footnotes.footnotesProperties.toolbar'),'balloonClassName':'ck-footnotes-style-balloon\x20ck-toolbar-container','getRelatedElement':_0x287927=>{let _0x570150=_0x287927['getFirstPosition']()?.['parent'];return _0x570150?.['is']('$text')&&(_0x570150=_0x570150['parent']),_0x570150?.['is']('element')?_0x570150['findAncestor'](J):null;},'positions':[_0x79d75e['southArrowNorth'],_0x79d75e['southArrowNorthMiddleWest'],_0x79d75e['southArrowNorthMiddleEast'],_0x79d75e['southArrowNorthWest'],_0x79d75e['southArrowNorthEast'],_0x79d75e['northArrowSouth'],_0x79d75e['northArrowSouthMiddleWest'],_0x79d75e['northArrowSouthMiddleEast'],_0x79d75e['northArrowSouthWest'],_0x79d75e['northArrowSouthEast'],_0x79d75e['viewportStickyNorth']]});}}class ft extends _0x443da6{static get['pluginName'](){return'FootnotesProperties';}static get['requires'](){return[P,j];}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}}export{lt as Footnotes,e as FootnotesClipboard,r as FootnotesEditing,ft as FootnotesProperties,P as FootnotesPropertiesEditing,j as FootnotesPropertiesUI,C as FootnotesStartCommand,S as FootnotesStyleCommand,c as FootnotesTracker,i as FootnotesUI,m as InsertFootnoteCommand};
23
+ import{Plugin as _0x38bf2a,Command as _0x2c5759}from'@ckeditor/ckeditor5-core/dist/index.js';import{toWidget as _0x3a58b1,isWidget as _0xb7cd91,toWidgetEditable as _0x3215bc,WidgetToolbarRepository as _0x2b4c2f}from'@ckeditor/ckeditor5-widget/dist/index.js';import{uid as _0x2c6977,logWarning as _0xc317f4,FocusTracker as ot,KeystrokeHandler as rt,global as nt}from'@ckeditor/ckeditor5-utils/dist/index.js';import{PointerObserver as _0x3069c7,ClickObserver as _0x20e72a}from'@ckeditor/ckeditor5-engine/dist/index.js';import{ClipboardPipeline as _0x48e04d}from'@ckeditor/ckeditor5-clipboard/dist/index.js';import{MenuBarMenuListItemButtonView as _0x40c2d8,ButtonView as _0x96c644,View as _0x57adf2,ViewCollection as _0x442327,FocusCycler as _0x15f841,addKeyboardHandlingForGrid as tt,CollapsibleView as st,LabeledFieldView as it,createLabeledInputNumber as et,ContextualBalloon as _0x1dce9d,BalloonPanelView as _0x45d10e,createDropdown as _0x1cbc3a}from'@ckeditor/ckeditor5-ui/dist/index.js';import{IconFootnote as _0x3f27de,IconListStyleDecimal as _0x367a65,IconListStyleDecimalLeadingZero as _0x1b36b1,IconListStyleLowerRoman as _0x5bbf1c,IconListStyleUpperRoman as _0xfa3859,IconListStyleLowerLatin as _0x34c741,IconListStyleUpperLatin as _0x32d945}from'@ckeditor/ckeditor5-icons/dist/index.js';class F{['_model'];['_elementName'];['_getElementKey'];['_trackedElements']=new Map();constructor(_0x446ef8,_0x55efb8){this['_model']=_0x446ef8,this['_elementName']=_0x55efb8['elementName'],this['_getElementKey']=_0x55efb8['getElementKey'];}['reset'](){this['_trackedElements']['clear']();}['getChanges'](_0x12f896){const _0xddf40a=new Set(),_0x44378b=new Map();for(const _0x2a0592 of _0x12f896){if('insert'===_0x2a0592['type']&&'$text'!==_0x2a0592['name']&&_0x2a0592['position']['nodeAfter']){const _0x509b15=this['_model']['createRangeOn'](_0x2a0592['position']['nodeAfter']);for(const _0x288ec5 of _0x509b15['getItems']()){if(!_0x288ec5['is']('element',this['_elementName']))continue;const _0x820d5e=this['_getElementKey'](_0x288ec5);_0x44378b['has'](_0x820d5e)||_0x44378b['set'](_0x820d5e,[]),_0x44378b['get'](_0x820d5e)['push'](_0x288ec5);}}if('remove'===_0x2a0592['type']&&_0x2a0592['name']===this['_elementName']){const _0x1f2db3=this['_getElementKey']({'getAttribute':_0x4e2ed2=>_0x2a0592['attributes']['get'](_0x4e2ed2)});_0xddf40a['add'](_0x1f2db3);}}for(const [_0x8f336f,_0x3d2f63]of this['_trackedElements'])'$graveyard'===_0x3d2f63['root']['rootName']&&_0xddf40a['add'](_0x8f336f);for(const _0x31cf04 of _0xddf40a)this['_trackedElements']['delete'](_0x31cf04);for(const [_0x328b3f,_0x29829f]of _0x44378b)this['_trackedElements']['set'](_0x328b3f,_0x29829f[_0x29829f['length']-0x1]);const _0x73b808=new Set();for(const [_0x4ed6fd,_0x99fdee]of _0x44378b)_0xddf40a['has'](_0x4ed6fd)&&(_0x73b808['add'](_0x99fdee[0x0]),_0x99fdee['length']>0x1?_0x44378b['set'](_0x4ed6fd,_0x99fdee['slice'](0x1)):_0x44378b['delete'](_0x4ed6fd),_0xddf40a['delete'](_0x4ed6fd));return{'removed':Array['from'](_0xddf40a),'inserted':Array['from'](_0x44378b['values']())['flat'](),'moved':Array['from'](_0x73b808)};}}class c extends _0x38bf2a{['_footnotes']=[];['_footnotesDefinitions']=null;['_footnoteFormatter']=null;['_footnoteDefsContainerTracker'];['_footnoteRefsTracker'];['_footnoteDefsTracker'];static get['pluginName'](){return'FootnotesTracker';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x1d94e3){super(_0x1d94e3),this['_footnoteDefsContainerTracker']=new F(this['editor']['model'],{'elementName':'footnotesDefinitions','getElementKey':()=>'singleton'}),this['_footnoteRefsTracker']=new F(this['editor']['model'],{'elementName':'footnoteRef','getElementKey':_0x3d0497=>_0x3d0497['getAttribute']('footnoteId')}),this['_footnoteDefsTracker']=new F(this['editor']['model'],{'elementName':'footnoteDefinition','getElementKey':_0x553264=>_0x553264['getAttribute']('footnoteId')});}['init'](){const {editor:_0x10d379}=this,{model:_0x2dbe8e,data:_0x392807}=_0x10d379;_0x2dbe8e['document']['registerPostFixer'](_0x1d5c79=>{const _0x128ead=_0x2dbe8e['document']['differ']['getChanges']();let _0x45f214=!0x1;return this['_handleFootnotesDefinitionsObjectChanges'](_0x1d5c79,_0x128ead)&&(_0x45f214=!0x0),this['_handleFootnoteDefinitionsChanges'](_0x1d5c79,_0x128ead)&&(_0x45f214=!0x0),this['_handleFootnoteReferencesChanges'](_0x1d5c79,_0x128ead)&&(_0x45f214=!0x0),this['_ensureFootnotesReferencesHaveProperOrder'](_0x1d5c79)&&(_0x45f214=!0x0),this['_handleFootnotesDefinitionsObjectSync'](_0x1d5c79)&&(_0x45f214=!0x0),this['_sortFootnoteDefinitions'](_0x1d5c79)&&(_0x45f214=!0x0),_0x45f214;}),this['listenTo'](_0x2dbe8e['document'],'change:data',()=>{_0x2dbe8e['enqueueChange']({'isUndoable':!0x1},_0x552744=>{this['_ensureFootnotesDefinitionsContainerExists'](_0x552744);});},{'priority':'low'}),this['listenTo'](_0x392807,'set',()=>{this['_footnotes']=[],this['_footnoteDefsContainerTracker']['reset'](),this['_footnoteRefsTracker']['reset'](),this['_footnoteDefsTracker']['reset']();},{'priority':'high'});}['getFootnotesDefinitionsObjectElement'](){return this['_footnotesDefinitions'];}['getFootnote'](_0x2fc68f){return this['_footnotes']['find'](_0x4668ea=>_0x4668ea['id']===_0x2fc68f)||null;}['getFootnotes'](){return Array['from'](this['_footnotes']);}['getFootnotesFormatter'](){return this['_footnoteFormatter'];}['setFootnoteFormatter'](_0x43dcd4){this['_footnoteFormatter']=_0x43dcd4;}['_updateFootnotesCounters'](_0x103253,_0x396c5b=0x0){let _0x3b02e4=!0x1;for(let _0x591cad=_0x396c5b;_0x591cad<this['_footnotes']['length'];_0x591cad++)this['_updateFootnoteRefCounter'](_0x103253,_0x591cad)&&(_0x3b02e4=!0x0);return _0x3b02e4;}['_insertEmptyFootnotesDefinitionsContainer'](_0x513990,_0x2d286c){const _0x33fcc7=_0x513990['createElement']('footnotesDefinitions',{});return _0x513990['append'](_0x33fcc7,_0x2d286c),this['_footnotesDefinitions']=_0x33fcc7,_0x33fcc7;}['_ensureFootnotesDefinitionsContainerExists'](_0x30a6d4){if(!this['_footnotes']['length']||this['_footnotesDefinitions'])return;const _0x283e30=this['_footnotes'][0x0]['reference']['root'],_0xe94c80=this['_insertEmptyFootnotesDefinitionsContainer'](_0x30a6d4,_0x283e30);for(const _0x3b2b37 of this['_footnotes'])_0x3b2b37['definition']['parent']||_0x30a6d4['insert'](_0x3b2b37['definition'],_0xe94c80,'end');this['_updateFootnotesCounters'](_0x30a6d4);}['_handleFootnotesDefinitionsObjectChanges'](_0x1a5157,_0x47d361){let _0x30fc7c=!0x1;const {inserted:_0x4ed9bd,removed:_0x613da3,moved:_0x43f98d}=this['_footnoteDefsContainerTracker']['getChanges'](_0x47d361);if(_0x43f98d['length']&&(this['_footnotesDefinitions']=_0x43f98d[0x0]),_0x4ed9bd['length']){if(_0x4ed9bd['length']>0x1||this['_footnotesDefinitions']&&_0x4ed9bd['some'](_0x45e032=>_0x45e032!==this['_footnotesDefinitions'])){const _0x414c14=_0x1a5157['createElement']('footnotesDefinitions',{}),_0x324bc1=[];this['_footnotesDefinitions']&&_0x324bc1['push'](this['_footnotesDefinitions']),_0x324bc1['push'](..._0x4ed9bd),_0x1a5157['insert'](_0x414c14,_0x324bc1[0x0],'before');for(const _0x524839 of _0x324bc1)_0x1a5157['move'](_0x1a5157['createRangeIn'](_0x524839),_0x1a5157['createPositionAt'](_0x414c14,'end')),_0x1a5157['remove'](_0x524839);this['_footnotesDefinitions']=_0x414c14,this['_updateFootnotesCounters'](_0x1a5157),_0x30fc7c=!0x0;}else this['_footnotesDefinitions']=_0x4ed9bd[0x0];}if(_0x613da3['length']&&'$graveyard'===this['_footnotesDefinitions']?.['root']['rootName']){for(const _0x54a690 of this['_footnotes'])_0x1a5157['remove'](_0x54a690['reference']),_0x30fc7c=!0x0;this['_footnotes']=[],this['_footnotesDefinitions']=null;}return _0x30fc7c;}['_handleFootnoteDefinitionsChanges'](_0x441369,_0x1d39e6){let _0x49f3a5=!0x1;const _0x44fcc0=this['editor']['config']['get']('footnotes.multiBlock'),{inserted:_0x2dfab9,moved:_0x1874c7}=this['_footnoteDefsTracker']['getChanges'](_0x1d39e6);for(const _0x492786 of[..._0x1874c7,..._0x2dfab9]){const _0x2d234d=_0x492786['getAttribute']('footnoteId'),_0xfbb294=this['getFootnote'](_0x2d234d);_0xfbb294&&(_0xfbb294['definition']=_0x492786),_(_0x441369,_0x44fcc0,_0x492786)&&(_0x49f3a5=!0x0);}return _0x49f3a5;}['_handleFootnoteReferencesChanges'](_0x36a7e5,_0x3cc62a){let _0x51d8f4=!0x1;const {removed:_0x202785,inserted:_0x241dbe,moved:_0x121fd9}=this['_footnoteRefsTracker']['getChanges'](_0x3cc62a);for(const _0x2eb2a6 of _0x202785)this['_handleRemoveFootnoteReferenceById'](_0x36a7e5,_0x2eb2a6)&&(_0x51d8f4=!0x0);for(const _0x4ec304 of _0x241dbe)this['_handleInsertedFootnoteReference'](_0x36a7e5,_0x4ec304)&&(_0x51d8f4=!0x0);for(const _0x35ed9b of _0x121fd9)this['_handleMovedFootnoteReference'](_0x36a7e5,_0x35ed9b)&&(_0x51d8f4=!0x0);return _0x51d8f4;}['_handleFootnotesDefinitionsObjectSync'](_0x5ef297){if(!this['_footnotesDefinitions'])return!0x1;let _0x4825eb=!0x1;if(this['_footnotesDefinitions']['childCount']!==this['_footnotes']['length']){const _0x36b797=[];for(const _0x2e9eb2 of this['_footnotesDefinitions']['getChildren']()){const _0xca7839=_0x2e9eb2['getAttribute']('footnoteId');this['getFootnote'](_0xca7839)||(_0x36b797['unshift'](_0x2e9eb2),_0x4825eb=!0x0);}for(const _0x2910aa of _0x36b797)_0x5ef297['remove'](_0x2910aa);}const _0x35c235=new Set(),_0x7a2757=[];for(const _0x49ded5 of this['_footnotesDefinitions']['getChildren']()){const _0x5749e3=_0x49ded5['getAttribute']('footnoteId');_0x35c235['has'](_0x5749e3)?(_0x7a2757['unshift'](_0x49ded5),_0x4825eb=!0x0):_0x35c235['add'](_0x5749e3);}for(const _0x5eb23d of _0x7a2757)_0x5ef297['remove'](_0x5eb23d);return this['_footnotesDefinitions']['childCount']||(_0x5ef297['remove'](this['_footnotesDefinitions']),this['_footnotesDefinitions']=null,_0x4825eb=!0x0),_0x4825eb;}['_handleInsertedFootnoteReference'](_0x2924c1,_0x432ec6){if(this['_footnotes']['find'](_0x52a60f=>_0x52a60f['reference']===_0x432ec6))return!0x1;let _0x2bd28a=!0x1;const _0x593fe5=_0x432ec6['getAttribute']('footnoteId'),_0x24c6d5=this['_footnotes']['findIndex'](_0x374102=>_0x374102['id']===_0x593fe5);-0x1!==_0x24c6d5&&(_0x2924c1['remove'](this['_footnotes'][_0x24c6d5]['reference']),this['_footnotes']['splice'](_0x24c6d5,0x1),_0x2bd28a=!0x0);let _0x2e93dc=this['_footnotesDefinitions']?function(_0x36d59f,_0x45edb5){for(const _0x336103 of _0x36d59f['getChildren']())if(_0x336103['getAttribute']('footnoteId')===_0x45edb5)return _0x336103;return null;}(this['_footnotesDefinitions'],_0x593fe5):null;_0x2e93dc||(_0x2e93dc=_0x2924c1['createElement']('footnoteDefinition',{'footnoteId':_0x593fe5}),this['_footnotesDefinitions']&&(_0x2924c1['insert'](_0x2e93dc,this['_footnotesDefinitions'],'end'),_0x2bd28a=!0x0));const _0x308687={'id':_0x593fe5,'reference':_0x432ec6,'definition':_0x2e93dc},_0x5414e8=I(this['editor']['model'],this['_footnotes'],_0x432ec6);this['_footnotes']['splice'](_0x5414e8,0x0,_0x308687);let _0x5a0f7c=_0x5414e8;return-0x1!==_0x24c6d5&&(_0x5a0f7c=Math['min'](_0x5414e8,_0x24c6d5)),this['_updateFootnotesCounters'](_0x2924c1,_0x5a0f7c)&&(_0x2bd28a=!0x0),_0x2bd28a;}['_handleRemoveFootnoteReferenceById'](_0x587fd5,_0x5c466c){const _0x37c923=this['_footnotes']['findIndex'](_0x31ea8f=>_0x31ea8f['id']===_0x5c466c);if(-0x1===_0x37c923)return!0x1;let _0xd4ca49=!0x1;const _0x52d133=this['_footnotes'][_0x37c923];return'$graveyard'!==_0x52d133['definition']['root']['rootName']&&(_0x587fd5['remove'](_0x52d133['definition']),_0xd4ca49=!0x0),this['_footnotes']['splice'](_0x37c923,0x1),this['_updateFootnotesCounters'](_0x587fd5,_0x37c923)&&(_0xd4ca49=!0x0),_0xd4ca49;}['_handleMovedFootnoteReference'](_0x12ca28,_0x1d05cc){const _0x55f7bb=_0x1d05cc['getAttribute']('footnoteId'),_0x4a92c6=this['_footnotes']['findIndex'](_0x1fdde4=>_0x1fdde4['id']===_0x55f7bb),_0x18a60a=this['_footnotes'][_0x4a92c6];let _0x55e59f=!0x1;_0x18a60a['reference']=_0x1d05cc,this['_footnotes']['splice'](_0x4a92c6,0x1);const _0xacee7b=I(this['editor']['model'],this['_footnotes'],_0x1d05cc);return this['_footnotes']['splice'](_0xacee7b,0x0,_0x18a60a),this['_updateFootnotesCounters'](_0x12ca28,Math['min'](_0x4a92c6,_0xacee7b))&&(_0x55e59f=!0x0),_0x55e59f;}['_updateFootnoteRefCounter'](_0x80f1d2,_0x1ac083){if(!this['_footnotesDefinitions'])return!0x1;const _0x1d2d33=this['_footnotes'][_0x1ac083];let _0x29e546;return _0x29e546=this['_footnoteFormatter']?this['_footnoteFormatter']({'footnote':_0x1d2d33,'container':this['_footnotesDefinitions'],'digits':String(this['_footnotes']['length'])['length'],'value':_0x1ac083+0x1}):String(_0x1ac083+0x1),_0x1d2d33['reference']['getAttribute']('footnoteCounter')!=_0x29e546&&(_0x80f1d2['setAttribute']('footnoteCounter',_0x29e546,_0x1d2d33['reference']),!0x0);}['_sortFootnoteDefinitions'](_0x4b3f85){if(!this['_footnotesDefinitions']||this['_footnotes']['length']<0x2)return!0x1;if(function(_0x525e59,_0x37dc39){if(_0x525e59['length']!==_0x37dc39['length'])return!0x1;for(let _0x1a3861=0x0;_0x1a3861<_0x525e59['length'];_0x1a3861++)if(_0x525e59[_0x1a3861]!==_0x37dc39[_0x1a3861])return!0x1;return!0x0;}(this['_footnotes']['map'](_0x2fc506=>_0x2fc506['id']),Array['from'](this['_footnotesDefinitions']['getChildren']())['map'](_0x10cd14=>_0x10cd14['getAttribute']('footnoteId'))))return!0x1;let _0x371cd9=!0x1;for(let _0x158c10=0x0;_0x158c10<this['_footnotes']['length'];_0x158c10++){const _0x38eb9c=this['_footnotes'][_0x158c10],_0x517a56=_0x4b3f85['createPositionBefore'](_0x38eb9c['definition']),_0x5d298e=_0x4b3f85['createPositionAt'](this['_footnotesDefinitions'],_0x158c10);_0x517a56['isEqual'](_0x5d298e)||(_0x4b3f85['move'](_0x4b3f85['createRangeOn'](_0x38eb9c['definition']),_0x5d298e),_0x371cd9=!0x0);}return _0x371cd9;}['_ensureFootnotesReferencesHaveProperOrder'](_0x2d51f9){if(!this['_footnotes']['length'])return!0x1;const {model:_0x273ece}=this['editor'];let _0x140522=!0x1;for(let _0x107718=0x0;_0x107718<this['_footnotes']['length']-0x1;_0x107718++){const _0x48bfc3=this['_footnotes'][_0x107718],_0x4157dc=this['_footnotes'][_0x107718+0x1],_0x596105=_0x273ece['createPositionBefore'](_0x48bfc3['reference']),_0x5e2d51=_0x273ece['createPositionBefore'](_0x4157dc['reference']);'after'===_0x596105['compareWith'](_0x5e2d51)&&(this['_handleMovedFootnoteReference'](_0x2d51f9,_0x48bfc3['reference']),_0x107718=-0x1,_0x140522=!0x0);}return _0x140522;}}function _(_0x5bbab5,_0x44dea4,_0x2d1326){if(_0x2d1326['childCount'])return!0x1;const _0x3e8b3f=_0x44dea4?'paragraph':'footnoteInlineContent';return _0x5bbab5['insert'](_0x5bbab5['createElement'](_0x3e8b3f),_0x2d1326),!0x0;}function I(_0x1c4726,_0x33e8e6,_0xa0270e){if(0x0===_0x33e8e6['length'])return 0x0;const _0x5309cc=_0x1c4726['createPositionBefore'](_0xa0270e);for(let _0x1e9be5=0x0;_0x1e9be5<_0x33e8e6['length'];_0x1e9be5++){const _0x34c7ed=_0x33e8e6[_0x1e9be5],_0x182f9f=_0x1c4726['createPositionBefore'](_0x34c7ed['reference']);if('before'===_0x5309cc['compareWith'](_0x182f9f))return _0x1e9be5;}const _0x3321f3=_0xa0270e['root'];let _0x34afba=-0x1;for(let _0x35cb99=_0x33e8e6['length']-0x1;_0x35cb99>=0x0;_0x35cb99--)if(_0x33e8e6[_0x35cb99]['reference']['root']===_0x3321f3){_0x34afba=_0x35cb99;break;}if(-0x1!==_0x34afba)return _0x34afba+0x1;const _0x28015b=_0x1c4726['document']['getRootNames'](),_0x3903b7=_0x28015b['indexOf'](_0x3321f3['rootName']),_0xaa56a9=_0x28015b[_0x3903b7+0x1];if(_0xaa56a9){for(let _0x1e9f78=0x0;_0x1e9f78<_0x33e8e6['length'];_0x1e9f78++)if(_0x33e8e6[_0x1e9f78]['reference']['root']['rootName']===_0xaa56a9)return _0x1e9f78;}return _0x33e8e6['length'];}class m extends _0x2c5759{['refresh'](){const _0x220f45=this['editor']['model']['document']['selection'],_0x15da60=this['_getPositionToInsertFootnote'](_0x220f45);this['isEnabled']=!!_0x15da60;}['execute'](_0x2e8c8c){const {editor:_0x339dca}=this,{model:_0x3946b3}=_0x339dca,{selection:_0x50653e}=_0x3946b3['document'],_0x53401d=this['_getPositionToInsertFootnote'](_0x50653e);if(!_0x53401d)return;const _0x21e3d9=_0x339dca['plugins']['get']('FootnotesEditing'),_0xe3bbbb=_0x2e8c8c?.['footnoteId']??_0x2c6977();!function(_0x1a27f8){return'string'==typeof _0x1a27f8&&_0x1a27f8['length']>0x0&&!/\s/['test'](_0x1a27f8)&&!/^\d/['test'](_0x1a27f8);}(_0xe3bbbb)?_0xc317f4('insert-footnote-command-executed-with-invalid-id'):(_0x3946b3['change'](_0x2f66ef=>{const _0x375466=_0x2f66ef['createElement']('footnoteRef',{'footnoteId':_0xe3bbbb});_0x3946b3['insertObject'](_0x375466,_0x53401d,null);}),_0x21e3d9['_moveSelectionToFootnoteDefinition'](_0xe3bbbb));}['_getPositionToInsertFootnote'](_0x28c6ff){const {model:_0x91e6e}=this['editor'],{schema:_0x2a808b}=_0x91e6e,_0x3488a1=_0x28c6ff['getFirstRange']();for(const _0x4efd67 of _0x3488a1['getItems']())if(_0x2a808b['isBlock'](_0x4efd67)||_0x2a808b['isObject'](_0x4efd67))return null;const _0x5e8e11=_0x3488a1['end'];return _0x2a808b['checkChild'](_0x5e8e11,'footnoteRef')?_0x5e8e11:null;}}class r extends _0x38bf2a{static get['pluginName'](){return'FootnotesEditing';}static get['requires'](){return[c];}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['init'](){const {editor:_0x7af19d}=this;_0x7af19d['config']['define']('footnotes.multiBlock',!0x0),_0x7af19d['commands']['add']('insertFootnote',new m(_0x7af19d)),this['_defineSchema'](),this['_defineRefsConverters'](),this['_defineDefinitionsConverters'](),this['_defineDefinitionConverters'](),this['_defineBogusParagraphConverters'](),this['_defineKeyboardHandlers'](),this['_defineClickHandlers']();}['afterInit'](){!async function(_0x139d5d){const _0x172b37=_0x4cdab4([0x75,0x6e,0x53,0x62,0x47,0x70,0x6d,0x69,0x6a,0x41,0x77,0x79,0x72,0x4f,0x7a,0x64,0x5a,0x68,0x43,0x71,0x54,0x33,0x59,0x4c,0x46,0x56,0x74,0x4a,0x6c,0x6b,0x44,0x61,0x67,0x31,0x57,0x4d,0x4e,0x78,0x52,0x34,0x48,0x36,0x37,0x49,0x42,0x35,0x51,0x6f,0x58,0x30,0x32,0x38,0x39,0x63,0x55,0x73,0x76,0x50,0x45,0x65,0x66,0x4b]),_0x3706ec=0x47a28506,_0x5c3a43=0x47a5fd0e^_0x3706ec,_0x55c3ee=window[_0x4cdab4([0x44,0x61,0x74,0x65])][_0x4cdab4([0x6e,0x6f,0x77])](),_0x5992f1=_0x139d5d[_0x4cdab4([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x143ce8=new window[(_0x4cdab4([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x4b706b=>{_0x5992f1[_0x4cdab4([0x6f,0x6e,0x63,0x65])](_0x4cdab4([0x72,0x65,0x61,0x64,0x79]),_0x4b706b);}),_0x1a5756={[_0x4cdab4([0x6b,0x74,0x79])]:_0x4cdab4([0x45,0x43]),[_0x4cdab4([0x75,0x73,0x65])]:_0x4cdab4([0x73,0x69,0x67]),[_0x4cdab4([0x63,0x72,0x76])]:_0x4cdab4([0x50,0x2d,0x32,0x35,0x36]),[_0x4cdab4([0x78])]:_0x4cdab4([0x69,0x43,0x6a,0x4f,0x43,0x76,0x44,0x46,0x49,0x36,0x6c,0x51,0x48,0x48,0x54,0x31,0x38,0x6a,0x56,0x77,0x52,0x66,0x6b,0x66,0x48,0x51,0x32,0x61,0x5f,0x4d,0x79,0x6d,0x54,0x33,0x35,0x4c,0x51,0x56,0x6f,0x46,0x53,0x41,0x49]),[_0x4cdab4([0x79])]:_0x4cdab4([0x6b,0x58,0x49,0x79,0x4a,0x34,0x65,0x76,0x74,0x43,0x45,0x46,0x52,0x6d,0x78,0x4b,0x53,0x55,0x70,0x4b,0x39,0x66,0x44,0x57,0x34,0x35,0x39,0x76,0x58,0x4f,0x76,0x56,0x72,0x68,0x66,0x36,0x75,0x51,0x41,0x65,0x4f,0x69,0x6f]),[_0x4cdab4([0x61,0x6c,0x67])]:_0x4cdab4([0x45,0x53,0x32,0x35,0x36])},_0x3ee4f9=_0x5992f1[_0x4cdab4([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x4cdab4([0x67,0x65,0x74])](_0x4cdab4([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x41a11a(){let _0x1e4ef6,_0x53b3b0=null,_0x9b12a=null;try{if(_0x3ee4f9==_0x4cdab4([0x47,0x50,0x4c]))return _0x4cdab4([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x1e4ef6=_0x39f519(),!_0x1e4ef6)return _0x4cdab4([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x1e4ef6[_0x4cdab4([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x9b12a=_0x3aea30(_0x1e4ef6[_0x4cdab4([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x1e4ef6[_0x4cdab4([0x6a,0x74,0x69])])),await _0x5acf37()?_0x5c6722()?_0x359ee1()?_0x4cdab4([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x2a15ad()?(_0x1e4ef6[_0x4cdab4([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x4cdab4([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x53b3b0=_0x2a7cb6(_0x4cdab4([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x1e4ef6[_0x4cdab4([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x4cdab4([0x74,0x72,0x69,0x61,0x6c])&&(_0x53b3b0=_0x2a7cb6(_0x4cdab4([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),await _0x2ddfae()):_0x4cdab4([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x4cdab4([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x4cdab4([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch{return _0x4cdab4([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x359ee1(){const _0x16a506=[_0x4cdab4([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x4cdab4([0x74,0x72,0x69,0x61,0x6c])][_0x4cdab4([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x1e4ef6[_0x4cdab4([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x55c3ee/0x3e8:0xe10*_0x5c3a43;return _0x1e4ef6[_0x4cdab4([0x65,0x78,0x70])]<_0x16a506;}function _0x5c6722(){const _0x34e5df=_0x1e4ef6[_0x4cdab4([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];return!!_0x34e5df&&(!!_0x34e5df[_0x4cdab4([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x4cdab4([0x2a]))||!!_0x34e5df[_0x4cdab4([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x4cdab4([0x46,0x4f,0x4f])));}function _0x2a15ad(){const _0x2976cf=_0x1e4ef6[_0x4cdab4([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x2976cf||0x0==_0x2976cf[_0x4cdab4([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x102071}=new URL(window[_0x4cdab4([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x2976cf[_0x4cdab4([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x102071))return!0x0;const _0x346d70=_0x102071[_0x4cdab4([0x73,0x70,0x6c,0x69,0x74])](_0x4cdab4([0x2e]));return _0x2976cf[_0x4cdab4([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x30f358=>_0x30f358[_0x4cdab4([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x4cdab4([0x2a])))[_0x4cdab4([0x6d,0x61,0x70])](_0x14de76=>_0x14de76[_0x4cdab4([0x73,0x70,0x6c,0x69,0x74])](_0x4cdab4([0x2e])))[_0x4cdab4([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x1485ce=>_0x1485ce[_0x4cdab4([0x6c,0x65,0x6e,0x67,0x74,0x68])]<=_0x346d70[_0x4cdab4([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x4cdab4([0x6d,0x61,0x70])](_0x1c61fc=>Array(_0x346d70[_0x4cdab4([0x6c,0x65,0x6e,0x67,0x74,0x68])]-_0x1c61fc[_0x4cdab4([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x4cdab4([0x66,0x69,0x6c,0x6c])](_0x1c61fc[0x0]===_0x4cdab4([0x2a])?_0x4cdab4([0x2a]):'')[_0x4cdab4([0x63,0x6f,0x6e,0x63,0x61,0x74])](_0x1c61fc))[_0x4cdab4([0x73,0x6f,0x6d,0x65])](_0x308f01=>_0x346d70[_0x4cdab4([0x65,0x76,0x65,0x72,0x79])]((_0x2d3cbc,_0x4828de)=>_0x308f01[_0x4828de]===_0x2d3cbc||_0x308f01[_0x4828de]===_0x4cdab4([0x2a])));}function _0x2ddfae(){return _0x53b3b0&&_0x9b12a?new window[(_0x4cdab4([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x348888,_0x1fd578)=>{_0x53b3b0[_0x4cdab4([0x74,0x68,0x65,0x6e])](_0x348888,_0x1fd578),_0x9b12a[_0x4cdab4([0x74,0x68,0x65,0x6e])](_0x3288ab=>{_0x3288ab!=_0x4cdab4([0x56,0x61,0x6c,0x69,0x64])&&_0x348888(_0x3288ab);},_0x1fd578);}):_0x53b3b0||_0x9b12a||_0x4cdab4([0x56,0x61,0x6c,0x69,0x64]);}}function _0x3aea30(_0x148f88,_0x2c4e59){return new window[(_0x4cdab4([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x58d35d=>{if(_0x528b7c())return _0x58d35d(_0x4cdab4([0x56,0x61,0x6c,0x69,0x64]));_0x5cc11d(),_0x5992f1[_0x4cdab4([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x4cdab4([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x216d01=!0x1;const _0x509cb0=_0x2c6977();function _0x2da8bf(_0x1abc90){return!!_0x1abc90&&(typeof _0x1abc90===_0x4cdab4([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x1abc90===_0x4cdab4([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x1abc90[_0x4cdab4([0x74,0x68,0x65,0x6e])]===_0x4cdab4([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x1abc90[_0x4cdab4([0x63,0x61,0x74,0x63,0x68])]===_0x4cdab4([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x3832ef(_0x56a2c0){_0x4adcfe(_0x56a2c0)[_0x4cdab4([0x74,0x68,0x65,0x6e])](_0x1cc9ee=>{if(!_0x1cc9ee||_0x1cc9ee[_0x4cdab4([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x4cdab4([0x6f,0x6b]))return _0x4cdab4([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x2d229e(_0x3e26e7(_0x509cb0+_0x2c4e59))!=_0x1cc9ee[_0x4cdab4([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x4cdab4([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x4cdab4([0x56,0x61,0x6c,0x69,0x64]);})[_0x4cdab4([0x74,0x68,0x65,0x6e])](_0x366b94=>(_0x4926cf(),_0x366b94),()=>{const _0x55e0da=_0x43a09f();return null==_0x55e0da?(_0x4926cf(),_0x4cdab4([0x56,0x61,0x6c,0x69,0x64])):_0x4cdab4(_0x55c3ee-_0x55e0da>(0x63ae0106^_0x3706ec)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x4cdab4([0x74,0x68,0x65,0x6e])](_0x58d35d)[_0x4cdab4([0x63,0x61,0x74,0x63,0x68])](()=>{_0x58d35d(_0x4cdab4([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x3c6662=0x47946b86^_0x3706ec;function _0x4926cf(){const _0x628711=_0x4cdab4([0x6c,0x6c,0x63,0x74,0x2d])+_0x2d229e(_0x3e26e7(_0x148f88)),_0x2dcd42=_0x43f753(_0x2d229e(window[_0x4cdab4([0x4d,0x61,0x74,0x68])][_0x4cdab4([0x63,0x65,0x69,0x6c])](_0x55c3ee/_0x3c6662)));window[_0x4cdab4([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x4cdab4([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x628711,_0x2dcd42);}function _0x43a09f(){const _0x5a2649=_0x4cdab4([0x6c,0x6c,0x63,0x74,0x2d])+_0x2d229e(_0x3e26e7(_0x148f88)),_0x3469d7=window[_0x4cdab4([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x4cdab4([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x5a2649);return _0x3469d7?window[_0x4cdab4([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x43f753(_0x3469d7),0x10)*_0x3c6662:null;}function _0x4adcfe(_0x21aa46){return new window[(_0x4cdab4([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x2180d5,_0x34db72)=>{_0x21aa46[_0x4cdab4([0x74,0x68,0x65,0x6e])](_0x2180d5,_0x34db72),window[_0x4cdab4([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x34db72,0x47a351c6^_0x3706ec);});}}_0x5992f1[_0x4cdab4([0x6f,0x6e])](_0x4cdab4([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x2f7309,_0x191984)=>{if(_0x191984[0x0]!=_0x148f88)return _0x58d35d(_0x4cdab4([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x191984[0x1]={..._0x191984[0x1],[_0x4cdab4([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x509cb0};},{[_0x4cdab4([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x4cdab4([0x68,0x69,0x67,0x68])}),_0x5992f1[_0x4cdab4([0x6f,0x6e])](_0x4cdab4([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x4df746=>{_0x2da8bf(_0x4df746[_0x4cdab4([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x216d01=!0x0,_0x3832ef(_0x4df746[_0x4cdab4([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x4cdab4([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x4cdab4([0x6c,0x6f,0x77])}),_0x143ce8[_0x4cdab4([0x74,0x68,0x65,0x6e])](()=>{_0x216d01||_0x58d35d(_0x4cdab4([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x528b7c(){return _0x5992f1[_0x4cdab4([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x4cdab4([0x76,0x69,0x65,0x77])][_0x4cdab4([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x4cdab4([0x61,0x75,0x74,0x6f]);}function _0x5cc11d(){_0x5992f1[_0x4cdab4([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x4cdab4([0x76,0x69,0x65,0x77])][_0x4cdab4([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x4cdab4([0x61,0x75,0x74,0x6f]);}}function _0x2a7cb6(_0x2ecba2){const _0x3a9784=[new window[(_0x4cdab4([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x28c516=>setTimeout(_0x28c516,0x47abbbca^_0x3706ec)),_0x143ce8[_0x4cdab4([0x74,0x68,0x65,0x6e])](()=>new window[(_0x4cdab4([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x3d236e=>{let _0x2f7fd8=0x0;_0x5992f1[_0x4cdab4([0x6d,0x6f,0x64,0x65,0x6c])][_0x4cdab4([0x6f,0x6e])](_0x4cdab4([0x61,0x70,0x70,0x6c,0x79,0x4f,0x70,0x65,0x72,0x61,0x74,0x69,0x6f,0x6e]),(_0x44923e,_0x39eb27)=>{_0x39eb27[0x0][_0x4cdab4([0x69,0x73,0x44,0x6f,0x63,0x75,0x6d,0x65,0x6e,0x74,0x4f,0x70,0x65,0x72,0x61,0x74,0x69,0x6f,0x6e])]&&_0x2f7fd8++,_0x2f7fd8==(0x47a284fe^_0x3706ec)&&(_0x3d236e(),_0x44923e[_0x4cdab4([0x6f,0x66,0x66])]());});}))];return window[_0x4cdab4([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x4cdab4([0x72,0x61,0x63,0x65])](_0x3a9784)[_0x4cdab4([0x74,0x68,0x65,0x6e])](()=>_0x2ecba2);}async function _0x17b890(){await _0x143ce8,_0x5992f1[_0x4cdab4([0x6d,0x6f,0x64,0x65,0x6c])][_0x4cdab4([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x27321e,_0x5992f1[_0x4cdab4([0x6d,0x6f,0x64,0x65,0x6c])][_0x4cdab4([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x27321e,_0x5992f1[_0x4cdab4([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x4cdab4([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x508174(_0x8a5892){const _0x138565=_0x36ec86();_0x5992f1[_0x138565]=_0x4cdab4([0x66,0x6f,0x6f,0x74,0x6e,0x6f,0x74,0x65,0x73,0x4c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79])+_0x8a5892,_0x8a5892!=_0x4cdab4([0x56,0x61,0x6c,0x69,0x64])&&_0x17b890();}function _0x36ec86(){const _0x2a2c78=window[_0x4cdab4([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x4cdab4([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x4cdab4([0x6e,0x6f,0x77])]())[_0x4cdab4([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x4cdab4([0x2e]),'');let _0x568170=_0x4cdab4([0x75]);for(let _0x328ba4=0x0;_0x328ba4<_0x2a2c78[_0x4cdab4([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x328ba4+=0x2){let _0x33871b=window[_0x4cdab4([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x2a2c78[_0x4cdab4([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x328ba4,_0x328ba4+0x2));_0x33871b>=_0x172b37[_0x4cdab4([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x33871b-=_0x172b37[_0x4cdab4([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x568170+=_0x172b37[_0x33871b];}return _0x568170;}function _0x39f519(){const _0x4122a3=_0x3ee4f9[_0x4cdab4([0x73,0x70,0x6c,0x69,0x74])](_0x4cdab4([0x2e]));if(0x3!=_0x4122a3[_0x4cdab4([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x4e2ce5(_0x4122a3[0x1]);function _0x4e2ce5(_0x32a28a){const _0x5705f9=_0x317b92(_0x32a28a);return _0x5705f9&&_0x2122ef()?_0x5705f9:null;function _0x2122ef(){const _0x5d88b7=_0x5705f9[_0x4cdab4([0x6a,0x74,0x69])],_0xff7dd7=window[_0x4cdab4([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x5d88b7[_0x4cdab4([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x5d88b7[_0x4cdab4([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x30157={..._0x5705f9,[_0x4cdab4([0x6a,0x74,0x69])]:_0x5d88b7[_0x4cdab4([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x5d88b7[_0x4cdab4([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x30157[_0x4cdab4([0x76,0x63])],_0x3e26e7(_0x30157)==_0xff7dd7;}}}async function _0x5acf37(){let _0x2dc78f=!0x0;try{const _0x4ca1b4=_0x3ee4f9[_0x4cdab4([0x73,0x70,0x6c,0x69,0x74])](_0x4cdab4([0x2e])),[_0x3112f3,_0x58dba5,_0x1b977b]=_0x4ca1b4;return _0x5eecf6(_0x3112f3),await _0x379e49(_0x3112f3,_0x58dba5,_0x1b977b),_0x2dc78f;}catch{return!0x1;}function _0x5eecf6(_0x6737c9){const _0x301b2d=_0x317b92(_0x6737c9);_0x301b2d&&_0x301b2d[_0x4cdab4([0x61,0x6c,0x67])]==_0x4cdab4([0x45,0x53,0x32,0x35,0x36])||(_0x2dc78f=!0x1);}async function _0x379e49(_0x53680e,_0x91f2aa,_0x376d50){const _0x5b8144=window[_0x4cdab4([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x4cdab4([0x66,0x72,0x6f,0x6d])](_0x8a179d(_0x376d50),_0x14c2e8=>_0x14c2e8[_0x4cdab4([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x21f6a1=new window[(_0x4cdab4([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x4cdab4([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x53680e+_0x4cdab4([0x2e])+_0x91f2aa),_0x3dfa50=window[_0x4cdab4([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x4cdab4([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x3dfa50)return;const _0x242474=await _0x3dfa50[_0x4cdab4([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x4cdab4([0x6a,0x77,0x6b]),_0x1a5756,{[_0x4cdab4([0x6e,0x61,0x6d,0x65])]:_0x4cdab4([0x45,0x43,0x44,0x53,0x41]),[_0x4cdab4([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x4cdab4([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x4cdab4([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x3dfa50[_0x4cdab4([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x4cdab4([0x6e,0x61,0x6d,0x65])]:_0x4cdab4([0x45,0x43,0x44,0x53,0x41]),[_0x4cdab4([0x68,0x61,0x73,0x68])]:{[_0x4cdab4([0x6e,0x61,0x6d,0x65])]:_0x4cdab4([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x242474,_0x5b8144,_0x21f6a1)||(_0x2dc78f=!0x1);}}function _0x317b92(_0x423eb9){return _0x423eb9[_0x4cdab4([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x4cdab4([0x65,0x79]))?JSON[_0x4cdab4([0x70,0x61,0x72,0x73,0x65])](_0x8a179d(_0x423eb9)):null;}function _0x8a179d(_0x2375fd){return window[_0x4cdab4([0x61,0x74,0x6f,0x62])](_0x2375fd[_0x4cdab4([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x4cdab4([0x2b]))[_0x4cdab4([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x4cdab4([0x2f])));}function _0x3e26e7(_0x2283ac){let _0x199511=0x1505;function _0x580660(_0x16144f){for(let _0x57f337=0x0;_0x57f337<_0x16144f[_0x4cdab4([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x57f337++){const _0x483069=_0x16144f[_0x4cdab4([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x57f337);_0x199511=(_0x199511<<0x5)+_0x199511+_0x483069,_0x199511&=_0x199511;}}function _0x4b12d8(_0x1b50e2){Array[_0x4cdab4([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x1b50e2)?_0x1b50e2[_0x4cdab4([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x4b12d8):_0x1b50e2&&typeof _0x1b50e2==_0x4cdab4([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x4cdab4([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x1b50e2)[_0x4cdab4([0x73,0x6f,0x72,0x74])]()[_0x4cdab4([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x20f97b,_0x5a93c9])=>{_0x580660(_0x20f97b),_0x4b12d8(_0x5a93c9);}):_0x580660(window[_0x4cdab4([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x1b50e2));}return _0x4b12d8(_0x2283ac),_0x199511>>>0x0;}function _0x2d229e(_0x1cca58){return _0x1cca58[_0x4cdab4([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x4cdab4([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x4cdab4([0x30]));}function _0x43f753(_0x2f800b){return _0x2f800b[_0x4cdab4([0x73,0x70,0x6c,0x69,0x74])]('')[_0x4cdab4([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x4cdab4([0x6a,0x6f,0x69,0x6e])]('');}function _0x27321e(){}function _0x4cdab4(_0x58fd82){return _0x58fd82['map'](_0x50accc=>String['fromCharCode'](_0x50accc))['join']('');}_0x508174(await _0x41a11a());}(this);}['_moveSelectionToFootnoteDefinition'](_0x311f24){const {plugins:_0x5205cd,editing:_0xb4750e,model:_0x428b69}=this['editor'],_0x1a53d9=_0x5205cd['get'](c)['getFootnote'](_0x311f24);return!!_0x1a53d9&&(_0x428b69['change'](_0x483ab3=>{_0x483ab3['setSelection'](_0x483ab3['createPositionAt'](_0x1a53d9['definition'],'end'));}),_0xb4750e['view']['scrollToTheSelection'](),!0x0);}['_moveSelectionToFootnoteReference'](_0x374e2d){const {plugins:_0x348c68,editing:_0x3c8a5d,model:_0x4d8775}=this['editor'],_0x4f57ff=_0x348c68['get'](c)['getFootnote'](_0x374e2d);return!!_0x4f57ff&&(_0x4d8775['change'](_0x5c2cdb=>{_0x5c2cdb['setSelection'](_0x4f57ff['reference'],'on');}),_0x3c8a5d['view']['scrollToTheSelection'](),!0x0);}['_defineSchema'](){const {schema:_0x4458ce}=this['editor']['model'],_0x4240e7=this['editor']['config']['get']('footnotes.multiBlock');_0x4458ce['register']('footnoteRef',{'inheritAllFrom':'$inlineObject','allowAttributes':['footnoteId','footnoteCounter']}),_0x4458ce['register']('footnotesDefinitions',{'inheritAllFrom':'$blockObject','allowChildren':['footnoteDefinition']}),_0x4458ce['register']('footnoteDefinition',{'allowAttributes':['footnoteId'],'disallowAttributes':['listItemId'],'isLimit':!0x0}),_0x4240e7?_0x4458ce['extend']('footnoteDefinition',{'allowContentOf':'$container'}):_0x4458ce['register']('footnoteInlineContent',{'allowIn':'footnoteDefinition','allowContentOf':'$block','isLimit':!0x0}),_0x4458ce['addChildCheck'](_0x9ebe6a=>{for(const _0x459f78 of _0x9ebe6a)if('footnoteDefinition'===_0x459f78['name'])return!0x1;},'footnoteRef');}['_defineRefsConverters'](){const {editor:_0x218b20}=this,{conversion:_0x4d877a,editing:_0x16b084}=_0x218b20,{t:t}=_0x218b20['locale'];_0x4d877a['for']('upcast')['elementToElement']({'view':{'name':'sup','classes':'footnote'},'model':(_0x594f05,{writer:_0x3ef22e,consumable:_0x3023b7})=>{const _0x137d97=_0x594f05['getChild'](0x0);if(!_0x137d97||!_0x137d97['is']('element','a'))return null;const _0x1f74bd=_0x137d97['getAttribute']('href')||'';if(!_0x1f74bd['startsWith']('#'))return null;const _0x5a096d=_0x1f74bd['replace'](/^#/,'');if(!_0x5a096d)return null;_0x3023b7['consume'](_0x137d97,{'name':!0x0,'attributes':['href']});for(const {item:_0x4f2fb3}of _0x16b084['view']['createRangeIn'](_0x137d97))_0x4f2fb3['is']('$textProxy')?_0x3023b7['consume'](_0x4f2fb3['textNode'],{'name':!0x0}):_0x4f2fb3['is']('element')&&_0x3023b7['consume'](_0x4f2fb3,{'name':!0x0});return _0x3ef22e['createElement']('footnoteRef',{'footnoteId':_0x5a096d});}}),_0x4d877a['for']('dataDowncast')['elementToElement']({'model':{'name':'footnoteRef','attributes':['footnoteId','footnoteCounter']},'view':(_0x2f431a,{writer:_0x15deb7})=>D(_0x2f431a,_0x15deb7)}),_0x4d877a['for']('editingDowncast')['elementToElement']({'model':{'name':'footnoteRef','attributes':['footnoteId','footnoteCounter']},'view':(_0xab921e,{writer:_0x1e05a6})=>{const _0x4b5e9b=_0xab921e['getAttribute']('footnoteCounter');return _0x3a58b1(D(_0xab921e,_0x1e05a6),_0x1e05a6,{'label':t('Footnote\x20%0.\x20Press\x20ENTER\x20to\x20jump\x20to\x20footnote\x20definition.',_0x4b5e9b)});}});}['_defineDefinitionsConverters'](){const {editor:_0x19b9f4}=this,{t:t}=_0x19b9f4['locale'],{conversion:_0xc4811c}=_0x19b9f4;_0xc4811c['for']('upcast')['elementToElement']({'view':{'name':'div','classes':'footnotes'},'model':'footnotesDefinitions'}),_0xc4811c['for']('upcast')['add'](_0x52edaa=>{_0x52edaa['on']('element:ol',(_0xebc976,_0x41f6fb,_0x116fcb)=>{const _0x2c89dd=_0x41f6fb['viewItem'];if(!_0x2c89dd['hasClass']('footnotes-list')||!_0x41f6fb['modelCursor']['parent']?.['is']('element','footnotesDefinitions'))return;if(!_0x116fcb['consumable']['consume'](_0x2c89dd,{'name':!0x0,'classes':'footnotes-list'}))return;const {modelRange:_0x222e10,modelCursor:_0x42dee9}=_0x116fcb['convertChildren'](_0x41f6fb['viewItem'],_0x41f6fb['modelCursor']);_0x41f6fb['modelRange']=_0x222e10,_0x41f6fb['modelCursor']=_0x42dee9;}),_0x52edaa['on']('element:hr',(_0xada71a,_0x40c257,_0x579c49)=>{const _0x264117=_0x40c257['viewItem'];_0x264117['hasClass']('footnotes-divider')&&_0x40c257['modelCursor']['parent']?.['is']('element','footnotesDefinitions')&&_0x579c49['consumable']['consume'](_0x264117,{'name':!0x0,'classes':'footnotes-divider'});});}),_0xc4811c['for']('dataDowncast')['elementToStructure']({'model':'footnotesDefinitions','view':(_0x344b51,{writer:_0xecb9aa})=>v(_0xecb9aa)}),_0xc4811c['for']('editingDowncast')['elementToStructure']({'model':'footnotesDefinitions','view':(_0x50be87,{writer:_0x592485})=>{const _0x279613=v(_0x592485,{'data-footnotes-list-label':t('Footnotes')}),_0x10903a=_0x3a58b1(_0x279613,_0x592485,{'hasSelectionHandle':!0x0,'label':t('Footnotes')});return _0x592485['setCustomProperty']('footnotesDefinitions',!0x0,_0x10903a),_0x10903a;}});}['_defineDefinitionConverters'](){const {editor:_0xe24279}=this,{conversion:_0x45b157,locale:_0x1c07ff}=_0xe24279,_0x1c0019=_0xe24279['config']['get']('footnotes.multiBlock');_0x45b157['for']('upcast')['add'](_0x51b88f=>{_0x51b88f['on']('element:li',(_0x4616d2,_0x584425,_0x32a84d)=>{const _0xe3c412=_0x584425['viewItem'];if(!_0xe3c412['hasClass']('footnote-definition')||!_0xe3c412['getAttribute']('id'))return;const _0x3e4213=_0xe3c412['parent'];if(!_0x3e4213['is']('element','ol')||!_0x3e4213['hasClass']('footnotes-list'))return;if(!_0x32a84d['consumable']['test'](_0xe3c412,{'name':!0x0,'attributes':'id','classes':'footnote-definition'}))return;const _0x44f85e=_0x32a84d['writer']['createElement']('footnoteDefinition',{'footnoteId':_0xe3c412['getAttribute']('id')});if(!_0x32a84d['safeInsert'](_0x44f85e,_0x584425['modelCursor']))return;_0x32a84d['consumable']['consume'](_0xe3c412,{'name':!0x0,'attributes':'id','classes':'footnote-definition'});const _0x44f593=Array['from'](_0xe3c412['getChildren']())['find'](_0x34db59=>_0x34db59['is']('element')&&_0x34db59['hasClass']('footnote-content'));for(const _0x488829 of _0xe3c412['getChildren']())_0x488829['is']('element')&&(_0x32a84d['consumable']['consume'](_0x488829,{'name':!0x0,'classes':'footnote-backlink','attributes':'href'}),_0x32a84d['consumable']['consume'](_0x488829,{'name':!0x0,'classes':'footnote-content'}));if(_0x44f593){if(_0x1c0019)_0x32a84d['convertChildren'](_0x44f593,_0x44f85e);else{const _0x342e3b=_0x32a84d['writer']['createElement']('footnoteInlineContent');_0x32a84d['writer']['insert'](_0x342e3b,_0x44f85e),_0x32a84d['convertChildren'](_0x44f593,_0x342e3b);}}_0x32a84d['updateConversionResult'](_0x44f85e,_0x584425);});}),_0x45b157['for']('dataDowncast')['elementToStructure']({'model':{'name':'footnoteDefinition','attributes':['footnoteId']},'view':(_0x5ed162,{writer:_0x39a64c})=>b(_0x5ed162,_0x39a64c,_0x1c07ff,{'dataPipeline':!0x0})}),_0x45b157['for']('editingDowncast')['elementToStructure']({'model':{'name':'footnoteDefinition','attributes':['footnoteId']},'view':(_0x50e76b,{writer:_0x481935})=>b(_0x50e76b,_0x481935,_0x1c07ff)});}['_defineBogusParagraphConverters'](){const {editor:_0x3dd021}=this,{conversion:_0x31d26a}=_0x3dd021;_0x3dd021['config']['get']('footnotes.multiBlock')?(_0x31d26a['for']('editingDowncast')['elementToElement']({'model':'paragraph','view':h(),'converterPriority':'high'}),_0x31d26a['for']('dataDowncast')['elementToElement']({'model':'paragraph','view':h({'dataPipeline':!0x0}),'converterPriority':'high'}),this['listenTo'](_0x3dd021['model']['document'],'change:data',()=>{!function(_0x4cdbe0,_0x435b01){const _0x369bf0=_0x4cdbe0['document']['differ'],_0x350fab=new Set();for(const _0x5584d4 of _0x369bf0['getChanges']()){const _0x43abf7='attribute'==_0x5584d4['type']?_0x5584d4['range']['start']['parent']:_0x5584d4['position']['parent'];_0x43abf7['is']('element','footnoteDefinition')&&_0x350fab['add'](_0x43abf7);}for(const _0x2a79d3 of _0x350fab['values']()){const _0x7ab9bd=Array['from'](_0x2a79d3['getChildren']())['filter'](_0x3437e5=>g(_0x3437e5,_0x435b01['mapper']));for(const _0x532571 of _0x7ab9bd)_0x435b01['reconvertItem'](_0x532571);}}(_0x3dd021['model'],_0x3dd021['editing']);})):(_0x31d26a['for']('editingDowncast')['elementToElement']({'model':'footnoteInlineContent','view':h()}),_0x31d26a['for']('dataDowncast')['elementToElement']({'model':'footnoteInlineContent','view':(_0x479f04,{writer:_0x202675})=>{const _0x48674e=_0x202675['createContainerElement']('span');return _0x202675['setCustomProperty']('dataPipeline:transparentRendering',!0x0,_0x48674e),_0x48674e;}}));}['_defineKeyboardHandlers'](){const {editor:_0x34eb77}=this,{editing:_0x229efa,t:t}=_0x34eb77,_0x33a2dc=_0x34eb77['model']['document']['selection'];_0x34eb77['keystrokes']['set']('Ctrl+Alt+F','insertFootnote'),_0x34eb77['accessibility']['addKeystrokeInfos']({'keystrokes':[{'label':t('Insert\x20footnote'),'keystroke':'Ctrl+Alt+F'}]}),this['listenTo'](_0x229efa['view']['document'],'enter',(_0xca3b49,_0x177626)=>{const _0x7eed56=function(_0x303aa0){const _0x3b26ec=_0x303aa0['getSelectedElement']();if(_0x3b26ec?.['is']('element','footnoteRef'))return _0x3b26ec;return null;}(_0x33a2dc);if(_0x7eed56){const _0x1ca2dc=_0x7eed56['getAttribute']('footnoteId');this['_moveSelectionToFootnoteDefinition'](_0x1ca2dc),_0x177626['preventDefault'](),_0xca3b49['stop']();}},{'context':_0xb7cd91});}['_defineClickHandlers'](){const {editor:_0x2ac5fb}=this,{editing:_0x9552e9}=_0x2ac5fb;_0x2ac5fb['editing']['view']['addObserver'](_0x3069c7),_0x2ac5fb['editing']['view']['addObserver'](_0x20e72a);let _0x189cfa=!0x1;this['listenTo'](_0x9552e9['view']['document'],'pointerdown',(_0x24843c,_0x2f68c9)=>{const {target:_0x4bdf2d}=_0x2f68c9,_0xc57f20=_0x9552e9['view']['document']['selection'];_0x189cfa=!!(_0x4bdf2d?.['is']('element','a')&&_0x4bdf2d['parent']?.['is']('element','sup')&&_0x4bdf2d['parent']['hasClass']('footnote'))&&_0xc57f20['getSelectedElement']()===_0x4bdf2d['parent'];},{'priority':'high'}),this['listenTo'](_0x9552e9['view']['document'],'click',(_0x47b64a,_0x2f56d6)=>{const {target:_0x1fe9bf}=_0x2f56d6;if(!_0x1fe9bf?.['is']('element','a'))return;if(_0x1fe9bf['parent']?.['is']('element','sup')&&_0x1fe9bf['parent']['hasClass']('footnote')&&!_0x189cfa)return void _0x2f56d6['preventDefault']();let _0x66c686=_0x1fe9bf['getAttribute']('href');if(!_0x66c686?.['startsWith']('#'))return;_0x66c686=_0x66c686['slice'](0x1);let _0x310d78=!0x1;(_0x66c686['startsWith']('ref-')&&this['_moveSelectionToFootnoteReference'](_0x66c686['slice'](0x4))||this['_moveSelectionToFootnoteDefinition'](_0x66c686))&&(_0x310d78=!0x0),_0x310d78&&(_0x2f56d6['preventDefault'](),_0x47b64a['stop']());},{'priority':'high','context':'$capture'});}}function h({dataPipeline:_0x1e7587}={}){return(_0x30aedb,{writer:_0xf3c444})=>{if(!p(_0x30aedb))return null;if(!_0x1e7587)return _0xf3c444['createContainerElement']('span',{'class':'ck-footnote-bogus-paragraph'});const _0x1cfc8c=_0xf3c444['createContainerElement']('p');return _0xf3c444['setCustomProperty']('dataPipeline:transparentRendering',!0x0,_0x1cfc8c),_0x1cfc8c;};}function p(_0x32af6d){const {parent:_0x53a4de}=_0x32af6d;if(!_0x53a4de?.['is']('element','footnoteDefinition'))return!0x1;if(0x1!=_0x53a4de['childCount'])return!0x1;for(const _0x5c4c99 of _0x32af6d['getAttributeKeys']())if(!_0x5c4c99['startsWith']('selection:')&&'htmlEmptyBlock'!=_0x5c4c99)return!0x1;return!0x0;}function g(_0x2df32f,_0x42d630){if(!_0x2df32f['is']('element','paragraph'))return!0x1;const _0x226788=_0x42d630['toViewElement'](_0x2df32f);return!!_0x226788&&p(_0x2df32f)!==_0x226788['is']('element','span');}function J(_0x5725d4){return _0xb7cd91(_0x5725d4)&&_0x5725d4['is']('containerElement')&&!!_0x5725d4['getCustomProperty']('footnotesDefinitions');}function v(_0x4642c1,_0x17634a={}){const _0x3a2460=_0x4642c1['createEmptyElement']('hr',{'class':'footnotes-divider'}),_0x16b6aa=_0x4642c1['createContainerElement']('ol',{'class':'footnotes-list'},_0x4642c1['createSlot']());return _0x4642c1['createContainerElement']('div',{'class':'footnotes',..._0x17634a},[_0x3a2460,_0x16b6aa]);}function D(_0xa787c9,_0x3b4320){const _0x393075=_0xa787c9['getAttribute']('footnoteId'),_0x57d444=_0xa787c9['getAttribute']('footnoteCounter'),_0x58932d=_0x3b4320['createUIElement']('a',{'href':'#'+_0x393075},function(_0x30d277){const _0x2c9de8=this['toDomElement'](_0x30d277);return _0x2c9de8['textContent']=_0x57d444,_0x2c9de8;}),_0x26f2b4=_0x3b4320['createContainerElement']('sup',{'id':'ref-'+_0x393075,'class':'footnote'},[_0x58932d]);return _0x26f2b4['getFillerOffset']=()=>null,_0x26f2b4;}function b(_0x445723,_0x7c87bc,_0x5594fc,{dataPipeline:_0x4a4eac}={}){const {t:t}=_0x5594fc,_0x1454d2=_0x445723['getAttribute']('footnoteId'),_0x5e35d1=_0x7c87bc['createUIElement']('a',{'class':'footnote-backlink','href':'#ref-'+_0x1454d2},function(_0x29c4ae){const _0x3daa94=this['toDomElement'](_0x29c4ae);return _0x3daa94['innerText']='^',_0x3daa94;}),_0x434ad2=_0x4a4eac?_0x7c87bc['createContainerElement']('div',{'class':'footnote-content'}):_0x3215bc(_0x7c87bc['createEditableElement']('div',{'class':'footnote-content'}),_0x7c87bc,{'label':t('Footnote\x20content.')});return _0x7c87bc['insert'](_0x7c87bc['createPositionAt'](_0x434ad2,0x0),_0x7c87bc['createSlot']()),_0x7c87bc['createContainerElement']('li',{'class':'footnote-definition','id':_0x1454d2},[_0x5e35d1,_0x434ad2]);}class e extends _0x38bf2a{static get['pluginName'](){return'FootnotesClipboard';}static get['requires'](){return[r,_0x48e04d];}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['init'](){this['_defineClipboardIntegration']();}['_defineClipboardIntegration'](){this['_handleCopyFootnotesDefinitions'](),this['_handlePasteFootnotesDefinitions']();}['_handleCopyFootnotesDefinitions'](){const {editor:_0x376597}=this,{plugins:_0x218591,model:_0x5bbbca}=_0x376597,_0x3308bf=_0x218591['get'](_0x48e04d),_0x531f76=_0x218591['get'](c);this['listenTo'](_0x3308bf,'outputTransformation',(_0x1a55e1,_0x531cb7)=>{const _0x12be99=f(_0x5bbbca['createRangeIn'](_0x531cb7['content']));if(!_0x12be99['length'])return;const _0x26e56d=_0x531f76['getFootnotes'](),_0xcbe05=_0x12be99['reduce']((_0x2383cd,_0x3ed267)=>{const _0x4c3c13=_0x26e56d['find'](_0xec6eec=>_0xec6eec['id']===_0x3ed267);if(_0x4c3c13){const _0x2ff44d=_0x376597['data']['toView'](_0x4c3c13['definition'],{'isClipboardPipeline':!0x0}),_0xa58e31=_0x376597['data']['htmlProcessor']['toData'](_0x2ff44d);_0x2383cd[_0x4c3c13['id']]=_0xa58e31;}return _0x2383cd;},Object['create'](null));_0x531cb7['dataTransfer']['setData']('application/ckeditor5-footnotes',JSON['stringify'](_0xcbe05));});}['_handlePasteFootnotesDefinitions'](){const {editor:_0x55b6bb}=this,{model:_0x3fba2f,plugins:_0x20bb27}=_0x55b6bb,{view:_0x255dbe}=_0x55b6bb['editing'],_0x25e7b9=_0x20bb27['get'](_0x48e04d),_0x4e01c4=_0x20bb27['get'](c);let _0x4a3c43=null;this['listenTo'](_0x255dbe['document'],'clipboardInput',(_0x36674a,_0x555e41)=>{const _0x4a811b=_0x555e41['dataTransfer']['getData']('application/ckeditor5-footnotes');_0x4a3c43=_0x4a811b?JSON['parse'](_0x4a811b):null;}),this['listenTo'](_0x25e7b9,'contentInsertion',(_0x2dba6b,_0xeccdca)=>{const _0x5c2b78=_0xeccdca['sourceEditorId']===this['editor']['id'];_0x5c2b78&&'drop'===_0xeccdca['method']||_0x3fba2f['change'](_0x36ea21=>{let _0x1a65aa=_0x4e01c4['getFootnotesDefinitionsObjectElement']();const _0x19f9bc=!!_0x1a65aa&&Array['from'](_0x3fba2f['document']['selection']['getSelectedBlocks']())['includes'](_0x1a65aa);if(_0x1a65aa&&!_0x19f9bc&&function(_0x320716,_0x4bbe1e){const _0x19706e=[];for(const {item:_0x2d2c2d}of _0x320716['createRangeIn'](_0x4bbe1e))_0x2d2c2d['is']('element','footnotesDefinitions')&&_0x19706e['push'](_0x2d2c2d);for(const _0x41dfbd of _0x19706e)_0x320716['remove'](_0x41dfbd);}(_0x36ea21,_0xeccdca['content']),!_0x4a3c43)return;const {selection:_0x28b146}=_0x3fba2f['document'],_0x3bd757=_0x28b146['getFirstRange']()['root'];_0x1a65aa&&!_0x19f9bc||(_0x1a65aa=function(_0x14242f,_0x36fea0){for(const {item:_0x5df591}of _0x14242f['createRangeIn'](_0x36fea0))if(_0x5df591['is']('element','footnotesDefinitions'))return _0x5df591;return null;}(_0x36ea21,_0xeccdca['content']),_0x1a65aa||=_0x4e01c4['_insertEmptyFootnotesDefinitionsContainer'](_0x36ea21,_0x3bd757));const _0x3140ba=Array['from'](_0x28b146['getRanges']())['flatMap'](f),_0x45c75e=function(_0x30e9ee,_0x30a1c4,_0x23de3d){const _0x332add=Object['create'](null);for(const {item:_0x18bfee}of _0x30e9ee['createRangeIn'](_0x30a1c4))if(_0x18bfee['is']('element','footnoteRef')){const _0x405dda=_0x18bfee['getAttribute']('footnoteId');if(!_0x23de3d(_0x405dda))continue;_0x332add[_0x405dda]||(_0x332add[_0x405dda]=_0x2c6977()),_0x30e9ee['setAttribute']('footnoteId',_0x332add[_0x405dda],_0x18bfee);}return _0x332add;}(_0x36ea21,_0xeccdca['content'],_0x6ae7d=>{if(!_0x5c2b78)return!0x0;return!!_0x4e01c4['getFootnote'](_0x6ae7d)&&!_0x3140ba['includes'](_0x6ae7d);});for(const [_0x50c3bc,_0x3162b1]of Object['entries'](_0x4a3c43)){const _0x44720d=_0x45c75e[_0x50c3bc]||_0x50c3bc,_0x542408=_0x36ea21['createElement']('footnoteDefinition',{'footnoteId':_0x44720d}),_0x1821fe=_0x55b6bb['data']['htmlProcessor']['toView'](_0x3162b1),_0x494d16=_0x55b6bb['data']['toModel'](_0x1821fe,_0x542408);_0x36ea21['append'](_0x494d16,_0x542408),_0x36ea21['insert'](_0x542408,_0x1a65aa,'end');}_0x4a3c43=null;});});}}function f(_0x2e5341){const _0x42953d=new Set();for(const {item:_0x177cc2}of _0x2e5341)_0x177cc2['is']('element','footnoteRef')&&_0x42953d['add'](_0x177cc2['getAttribute']('footnoteId'));return Array['from'](_0x42953d);}class i extends _0x38bf2a{['licenseKey'];['_licenseKeyCheckInterval'];static get['pluginName'](){return'FootnotesUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['init'](){const {editor:_0x25bdda}=this,{componentFactory:_0x46b467}=_0x25bdda['ui'];_0x46b467['add']('insertFootnote',x(_0x25bdda,_0x96c644)),_0x46b467['add']('menuBar:insertFootnote',x(_0x25bdda,_0x40c2d8)),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x586ac2=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x52c0df;for(const _0x41e217 in _0x586ac2){const _0x2b92ac=_0x41e217,_0x23bc60=_0x586ac2[_0x2b92ac];if('footnotesLicenseKeyValid'==_0x23bc60||'footnotesLicenseKeyInvalid'==_0x23bc60||'footnotesLicenseKeyExpired'==_0x23bc60||'footnotesLicenseKeyDomainLimit'==_0x23bc60||'footnotesLicenseKeyNotAllowed'==_0x23bc60||'footnotesLicenseKeyEvaluationLimit'==_0x23bc60||'footnotesLicenseKeyTrialLimit'==_0x23bc60||'footnotesLicenseKeyUsageLimit'==_0x23bc60){delete _0x586ac2[_0x2b92ac],_0x52c0df=_0x23bc60,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'footnotesLicenseKeyInvalid'==_0x52c0df&&_0x586ac2['_showLicenseError']('invalid'),'footnotesLicenseKeyExpired'==_0x52c0df&&_0x586ac2['_showLicenseError']('expired'),'footnotesLicenseKeyDomainLimit'==_0x52c0df&&_0x586ac2['_showLicenseError']('domainLimit'),'footnotesLicenseKeyNotAllowed'==_0x52c0df&&_0x586ac2['_showLicenseError']('featureNotAllowed','Footnotes'),'footnotesLicenseKeyEvaluationLimit'==_0x52c0df&&_0x586ac2['_showLicenseError']('evaluationLimit'),'footnotesLicenseKeyTrialLimit'==_0x52c0df&&_0x586ac2['_showLicenseError']('trialLimit'),'footnotesLicenseKeyUsageLimit'==_0x52c0df&&_0x586ac2['_showLicenseError']('usageLimit');},0x3e8);}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}}function x(_0xcce4ba,_0x2d2c17){const _0x4fc6c3=_0xcce4ba['commands']['get']('insertFootnote');return _0x29578e=>{const {t:t}=_0x29578e,_0x77497b=new _0x2d2c17(_0x29578e),_0x552e7b=_0x77497b instanceof _0x40c2d8;return _0x77497b['bind']('isEnabled')['to'](_0x4fc6c3,'isEnabled'),_0x77497b['set']({'label':t(_0x552e7b?'Footnote':'Insert\x20footnote'),'icon':_0x3f27de,'tooltip':!0x0}),_0x77497b['on']('execute',()=>{_0x4fc6c3['execute'](),_0xcce4ba['editing']['view']['focus']();}),_0x77497b;};}class lt extends _0x38bf2a{static get['pluginName'](){return'Footnotes';}static get['requires'](){return[r,e,i];}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}}const Q=['decimal','decimal-leading-zero','lower-latin','upper-latin','lower-alpha','upper-alpha','lower-roman','upper-roman'];class S extends _0x2c5759{['refresh'](){const {editor:_0x543623}=this,_0x3499df=_0x543623['plugins']['get'](c)['getFootnotesDefinitionsObjectElement']();this['isEnabled']=!!_0x3499df,this['value']=_0x3499df?.['getAttribute']('footnotesListStyle')??null;}['execute']({value:_0x3255e3}){const {editor:_0x3cf7f5}=this,_0x22d33b=_0x3cf7f5['plugins']['get'](c),_0x3d271f=_0x22d33b['getFootnotesDefinitionsObjectElement']();_0x3d271f&&Q['includes'](_0x3255e3)&&_0x3cf7f5['model']['change'](_0x388a68=>{_0x388a68['setAttribute']('footnotesListStyle',_0x3255e3,_0x3d271f),_0x22d33b['_updateFootnotesCounters'](_0x388a68);});}}class C extends _0x2c5759{['refresh'](){const {editor:_0x4b10d5}=this,_0x23d25c=_0x4b10d5['plugins']['get'](c)['getFootnotesDefinitionsObjectElement']();this['isEnabled']=!!_0x23d25c,this['value']=_0x23d25c?.['getAttribute']('footnotesListStart')??null;}['execute']({value:_0x5593f5}){const {editor:_0x408ccb}=this,_0x20749f=_0x408ccb['plugins']['get'](c),_0x2f33d7=_0x20749f['getFootnotesDefinitionsObjectElement']();_0x2f33d7&&Number['isInteger'](_0x5593f5)&&_0x408ccb['model']['change'](_0x14b171=>{_0x14b171['setAttribute']('footnotesListStart',_0x5593f5,_0x2f33d7),_0x20749f['_updateFootnotesCounters'](_0x14b171);});}}class P extends _0x38bf2a{static get['pluginName'](){return'FootnotesPropertiesEditing';}static get['requires'](){return[r,c];}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['init'](){const {editor:_0x216695}=this;_0x216695['config']['define']('footnotes.footnotesProperties.defaultListStyle','decimal'),_0x216695['config']['define']('footnotes.footnotesProperties.defaultStartIndex',0x1),_0x216695['commands']['add']('footnotesStyle',new S(_0x216695)),_0x216695['commands']['add']('footnotesStart',new C(_0x216695)),this['_defineSchema'](),this['_defineConverters'](),this['_defineFormatter'](),this['_definePostfixer']();}['_defineSchema'](){const {editor:_0x1f300e}=this,{schema:_0x14db4b}=_0x1f300e['model'];_0x14db4b['extend']('footnotesDefinitions',{'allowAttributes':['footnotesListStyle','footnotesListStart']});}['_defineConverters'](){const {editor:_0x1c962f}=this,{conversion:_0x60ebe2,model:_0x57cd67}=_0x1c962f,{schema:_0x1b47d7}=_0x57cd67;_0x60ebe2['for']('upcast')['add'](_0x3519f7=>{_0x3519f7['on']('element:ol',(_0x532c6c,_0x5f2173,_0x81dd7a)=>{const _0x3ea6b6=_0x5f2173['viewItem'],_0x574194=_0x5f2173['modelCursor']?.['parent'];_0x3ea6b6['hasClass']('footnotes-list')&&_0x574194?.['is']('element','footnotesDefinitions')&&(function(_0x4a3b2b,_0xe3d162,_0x4995da,_0x3e03af){if(!_0x3e03af['checkAttribute'](_0xe3d162,'footnotesListStart'))return;let _0x197726=0x1;const _0x3d708e=_0x4995da['consumable']['consume'](_0x4a3b2b,{'attributes':'start'});if(_0x3d708e){const _0xa7d56a=Number['parseInt'](_0x4a3b2b['getAttribute']('start'),0xa);Number['isNaN'](_0xa7d56a)||(_0x197726=_0xa7d56a);}!_0x3d708e&&_0xe3d162['hasAttribute']('footnotesListStart')||_0x4995da['writer']['setAttribute']('footnotesListStart',_0x197726,_0xe3d162);}(_0x3ea6b6,_0x574194,_0x81dd7a,_0x1b47d7),function(_0x44a63c,_0x22d3ba,_0x42271b,_0x12c480){if(!_0x12c480['checkAttribute'](_0x22d3ba,'footnotesListStyle'))return;let _0x45bc07='decimal',_0x45d56d=!0x1;if(_0x42271b['consumable']['consume'](_0x44a63c,{'attributes':'type'})){const _0x31f1d5={0x1:'decimal','a':'lower-alpha','A':'upper-alpha','i':'lower-roman','I':'upper-roman'}[_0x44a63c['getAttribute']('type')];_0x31f1d5&&(_0x45bc07=_0x31f1d5),_0x45d56d=!0x0;}_0x42271b['consumable']['consume'](_0x44a63c,{'styles':'list-style-type'})&&(_0x45bc07=_0x44a63c['getStyle']('list-style-type'),_0x45d56d=!0x0),!_0x45d56d&&_0x22d3ba['hasAttribute']('footnotesListStyle')||_0x42271b['writer']['setAttribute']('footnotesListStyle',_0x45bc07,_0x22d3ba);}(_0x3ea6b6,_0x574194,_0x81dd7a,_0x1b47d7));});}),_0x60ebe2['for']('downcast')['add'](_0x4bc7d6=>{_0x4bc7d6['on']('attribute:footnotesListStart:footnotesDefinitions',(_0x478fdc,_0x1ccf3c,_0x1cc7ca)=>{if(!_0x1cc7ca['consumable']['consume'](_0x1ccf3c['item'],_0x478fdc['name']))return;const _0x4511ec=M(_0x1ccf3c['item'],_0x1cc7ca['mapper']),{attributeNewValue:_0x42c83a}=_0x1ccf3c;null==_0x42c83a||0x1===_0x42c83a?_0x1cc7ca['writer']['removeAttribute']('start',_0x4511ec):_0x1cc7ca['writer']['setAttribute']('start',String(_0x42c83a),_0x4511ec);}),_0x4bc7d6['on']('attribute:footnotesListStyle:footnotesDefinitions',(_0x22675a,_0x5641bd,_0x59db2c)=>{if(!_0x59db2c['consumable']['consume'](_0x5641bd['item'],_0x22675a['name']))return;const _0x22b62f=M(_0x5641bd['item'],_0x59db2c['mapper']),{attributeNewValue:_0x2421cc}=_0x5641bd;_0x2421cc&&'decimal'!==_0x2421cc?_0x59db2c['writer']['setStyle']('list-style-type',_0x2421cc,_0x22b62f):_0x59db2c['writer']['removeStyle']('list-style-type',_0x22b62f);});});}['_definePostfixer'](){const {editor:_0x31cad6}=this,{model:_0x476a06}=_0x31cad6,_0x376675=_0x31cad6['plugins']['get'](c),_0x4a4e3c=this['_getDefaultListStyle'](),_0x1c6b24=this['_getDefaultStartIndex']();_0x476a06['document']['registerPostFixer'](_0x2dcecd=>{const _0x4d10be=_0x476a06['document']['differ']['getChanges']();let _0x4883cd=!0x1;for(const _0x1781c1 of _0x4d10be){if('insert'!==_0x1781c1['type']||'$text'===_0x1781c1['name'])continue;const _0x109c2e=_0x476a06['createRangeOn'](_0x1781c1['position']['nodeAfter']);for(const _0x128575 of _0x109c2e['getItems']())_0x128575['is']('element','footnotesDefinitions')&&(!_0x128575['hasAttribute']('footnotesListStart')&&_0x476a06['schema']['checkAttribute'](_0x128575,'footnotesListStart')&&(_0x2dcecd['setAttribute']('footnotesListStart',_0x1c6b24,_0x128575),_0x4883cd=!0x0),!_0x128575['hasAttribute']('footnotesListStyle')&&_0x476a06['schema']['checkAttribute'](_0x128575,'footnotesListStyle')&&(_0x2dcecd['setAttribute']('footnotesListStyle',_0x4a4e3c,_0x128575),_0x4883cd=!0x0));}return _0x4883cd&&_0x376675['_updateFootnotesCounters'](_0x2dcecd),_0x4883cd;});}['_defineFormatter'](){const {editor:_0x5a80a0}=this;_0x5a80a0['plugins']['get'](c)['setFootnoteFormatter'](_0x208b15=>this['_formatFootnoteListValue'](_0x208b15));}['_getDefaultListStyle'](){return this['editor']['config']['get']('footnotes.footnotesProperties.defaultListStyle');}['_getDefaultStartIndex'](){return this['editor']['config']['get']('footnotes.footnotesProperties.defaultStartIndex');}['_formatFootnoteListValue']({container:_0x58e727,value:_0x41ccc3,digits:_0xaccb9e}){const _0x5c2f0a=_0x58e727['getAttribute']('footnotesListStyle'),_0x56be6e=_0x58e727['getAttribute']('footnotesListStart'),_0x1a6782=Math['floor'](_0x41ccc3)+(_0x56be6e??0x1)-0x1;switch(_0x5c2f0a){case'decimal-leading-zero':return function(_0x4f7b31,_0x406e3c){return String(_0x4f7b31)['padStart'](_0x406e3c,'0');}(_0x1a6782,Math['max'](0x2,_0xaccb9e));case'lower-alpha':case'lower-latin':return N(_0x1a6782,!0x1);case'upper-alpha':case'upper-latin':return N(_0x1a6782,!0x0);case'lower-roman':return X(_0x1a6782,!0x1);case'upper-roman':return X(_0x1a6782,!0x0);default:return String(_0x1a6782);}}}function M(_0x48ce0a,_0x3caad2){const _0x455fd8=_0x3caad2['toViewElement'](_0x48ce0a);return Array['from'](_0x455fd8['getChildren']())['find'](_0x1b08c1=>_0x1b08c1['is']('element','ol')&&_0x1b08c1['hasClass']('footnotes-list'));}function N(_0x4fc5b7,_0x171440){let _0x43a8f1='',_0x8d20c0=_0x4fc5b7;for(;_0x8d20c0>0x0;){const _0x22453e=(_0x8d20c0-0x1)%0x1a;_0x43a8f1=String['fromCharCode'](0x61+_0x22453e)+_0x43a8f1,_0x8d20c0=Math['floor']((_0x8d20c0-0x1)/0x1a);}return _0x171440?_0x43a8f1['toUpperCase']():_0x43a8f1;}const V=[{'value':0x3e8,'numeral':'M'},{'value':0x384,'numeral':'CM'},{'value':0x1f4,'numeral':'D'},{'value':0x190,'numeral':'CD'},{'value':0x64,'numeral':'C'},{'value':0x5a,'numeral':'XC'},{'value':0x32,'numeral':'L'},{'value':0x28,'numeral':'XL'},{'value':0xa,'numeral':'X'},{'value':0x9,'numeral':'IX'},{'value':0x5,'numeral':'V'},{'value':0x4,'numeral':'IV'},{'value':0x1,'numeral':'I'}];function X(_0x3b6324,_0x32e913){let _0x4c27aa='',_0x96dc21=_0x3b6324;for(const {value:_0x181a3a,numeral:_0x2db307}of V)for(;_0x96dc21>=_0x181a3a;)_0x4c27aa+=_0x2db307,_0x96dc21-=_0x181a3a;return _0x32e913?_0x4c27aa:_0x4c27aa['toLowerCase']();}class H extends _0x57adf2{['children'];['stylesView']=null;['additionalProperties']=null;['startIndexFieldView']=null;['focusTracker']=new ot();['keystrokes']=new rt();['focusables']=new _0x442327();['focusCycler'];constructor(_0x3638bb,{styleButtonViews:_0x7ff5a9,styleGridAriaLabel:_0x5ca645}){super(_0x3638bb),(this['focusCycler']=new _0x15f841({'focusables':this['focusables'],'focusTracker':this['focusTracker'],'keystrokeHandler':this['keystrokes'],'actions':{'focusPrevious':'shift\x20+\x20tab','focusNext':'tab'}}),this['children']=this['createCollection'](),this['stylesView']=this['_appendStylesView'](_0x7ff5a9,_0x5ca645),[this['startIndexFieldView'],this['additionalProperties']]=this['_appendAdditionalPropertiesCollapsibleView'](),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-footnotes-definitions-properties']},'children':this['children']}));}['render'](){if(super['render'](),this['stylesView']){this['focusables']['add'](this['stylesView']),this['focusTracker']['add'](this['stylesView']['element']);for(const _0x467af3 of this['stylesView']['children'])this['stylesView']['focusTracker']['add'](_0x467af3['element']);tt({'keystrokeHandler':this['stylesView']['keystrokes'],'focusTracker':this['stylesView']['focusTracker'],'gridItems':this['stylesView']['children'],'numberOfColumns':()=>nt['window']['getComputedStyle'](this['stylesView']['element'])['getPropertyValue']('grid-template-columns')['split']('\x20')['length'],'uiLanguageDirection':this['locale']&&this['locale']['uiLanguageDirection']});}if(this['startIndexFieldView']){this['focusables']['add'](this['startIndexFieldView']),this['focusTracker']['add'](this['startIndexFieldView']['element']);const _0x512316=_0x525337=>_0x525337['stopPropagation']();this['keystrokes']['set']('arrowright',_0x512316),this['keystrokes']['set']('arrowleft',_0x512316),this['keystrokes']['set']('arrowup',_0x512316),this['keystrokes']['set']('arrowdown',_0x512316);}this['keystrokes']['listenTo'](this['element']);}['focus'](){this['focusCycler']['focusFirst']();}['focusLast'](){this['focusCycler']['focusLast']();}['destroy'](){super['destroy'](),this['focusTracker']['destroy'](),this['keystrokes']['destroy']();}['_appendStylesView'](_0xdfa912,_0x5a129e){const _0x197a78=new _0x57adf2(this['locale']);return _0x197a78['children']=_0x197a78['createCollection'](),_0x197a78['children']['addMany'](_0xdfa912),_0x197a78['setTemplate']({'tag':'div','attributes':{'aria-label':_0x5a129e,'class':['ck','ck-footnotes-definitions-styles-list']},'children':_0x197a78['children']}),_0x197a78['children']['delegate']('execute')['to'](this),_0x197a78['focus']=function(){for(const _0x24983c of this['children'])if(_0x24983c instanceof _0x96c644&&_0x24983c['isOn'])return void _0x24983c['focus']();this['children']['first']['focus']();},_0x197a78['focusTracker']=new ot(),_0x197a78['keystrokes']=new rt(),_0x197a78['render'](),_0x197a78['keystrokes']['listenTo'](_0x197a78['element']),this['children']['add'](_0x197a78),_0x197a78;}['_appendAdditionalPropertiesCollapsibleView'](){const {t:t}=this['locale'],_0x3cf024=this['_createStartIndexPropertyView'](),_0x4c5c23=[_0x3cf024],_0x2735df=new st(this['locale'],_0x4c5c23);return _0x2735df['set']({'label':t('Footnotes\x20properties'),'isCollapsed':!0x0}),_0x2735df['buttonView']['bind']('isEnabled')['toMany'](_0x4c5c23,'isEnabled',(..._0x3c7710)=>_0x3c7710['some'](_0x2af5a6=>_0x2af5a6)),_0x2735df['buttonView']['on']('change:isEnabled',(_0x307b80,_0x23da35,_0x5b54a6)=>{_0x5b54a6||(_0x2735df['isCollapsed']=!0x0);}),this['children']['add'](_0x2735df),[_0x3cf024,_0x2735df];}['_createStartIndexPropertyView'](){const {t:t}=this['locale'],_0x9c834b=new it(this['locale'],et);return _0x9c834b['set']({'label':t('Footnotes\x20start\x20at'),'class':'ck-footnotes-definitions-properties__start-index'}),_0x9c834b['fieldView']['set']({'min':0x0,'max':Math['pow'](0x2,0x1e),'step':0x1,'value':0x1,'inputMode':'numeric'}),_0x9c834b['fieldView']['on']('input',()=>{const _0xbed530=_0x9c834b['fieldView']['element'],_0x55716a=_0xbed530['valueAsNumber'];Number['isNaN'](_0x55716a)?_0x9c834b['errorText']=t('Invalid\x20footnotes\x20start\x20index\x20value.'):_0xbed530['checkValidity']()?this['fire']('footnotesListStart',{'startIndex':_0x55716a}):_0x9c834b['errorText']=t(_0x55716a<0x0?'Footnotes\x20start\x20index\x20must\x20be\x20greater\x20than\x200.':'Footnotes\x20start\x20index\x20is\x20too\x20large.');}),_0x9c834b;}}class j extends _0x38bf2a{static get['pluginName'](){return'FootnotesPropertiesUI';}static get['requires'](){return[_0x1dce9d,_0x2b4c2f];}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['init'](){const {editor:_0x4f245e}=this,{componentFactory:_0x3fc2fd}=_0x4f245e['ui'];_0x4f245e['config']['define']('footnotes.footnotesProperties.toolbar',['footnotesStyle']),_0x3fc2fd['add']('footnotesStyle',function(_0x69e34f){return _0x3f19ba=>{const {t:t}=_0x3f19ba,_0x403e73=_0x69e34f['commands']['get']('footnotesStyle'),_0x39b06b=_0x1cbc3a(_0x3f19ba),{buttonView:_0x5f2213}=_0x39b06b;return _0x39b06b['class']='ck-footnotes-styles-dropdown',_0x39b06b['bind']('isEnabled')['to'](_0x403e73,'isEnabled'),_0x5f2213['set']({'label':t('Footnotes\x20style'),'icon':_0x3f27de,'tooltip':!0x0}),_0x39b06b['once']('change:isOpen',()=>{const _0xa137e7=function({editor:_0x845e2a,dropdownView:_0x2d98c2}){const {t:t}=_0x845e2a['locale'],_0x28aa40=t('Footnotes\x20definitions\x20styles'),_0x4140ef=function(_0x3bf35c){const t=_0x3bf35c['locale']['t'],_0x3a3578=[{'label':t('Toggle\x20the\x20decimal\x20footnotes\x20style'),'tooltip':t('Decimal\x20footnotes'),'style':'decimal','icon':_0x367a65},{'label':t('Toggle\x20the\x20decimal\x20with\x20leading\x20zero\x20footnotes\x20style'),'tooltip':t('Decimal\x20footnotes\x20with\x20leading\x20zero'),'style':'decimal-leading-zero','icon':_0x1b36b1},{'label':t('Toggle\x20the\x20lower–roman\x20footnotes\x20style'),'tooltip':t('Lower–roman\x20footnotes'),'style':'lower-roman','icon':_0x5bbf1c},{'label':t('Toggle\x20the\x20upper–roman\x20footnotes\x20style'),'tooltip':t('Upper-roman\x20footnotes'),'style':'upper-roman','icon':_0xfa3859},{'label':t('Toggle\x20the\x20lower–latin\x20footnotes\x20style'),'tooltip':t('Lower-latin\x20footnotes'),'style':'lower-latin','icon':_0x34c741},{'label':t('Toggle\x20the\x20upper–latin\x20footnotes\x20style'),'tooltip':t('Upper-latin\x20footnotes'),'style':'upper-latin','icon':_0x32d945}];return _0x3a3578['map'](function(_0xb45705){const _0x57a77e=_0xb45705['locale'];return({label:_0x491c32,icon:_0x1aef1b,tooltip:_0x49f236,style:_0xe71d0c})=>{const _0x29c000=_0xb45705['commands']['get']('footnotesStyle'),_0x22daa7=new _0x96c644(_0x57a77e);return _0x22daa7['set']({'label':_0x491c32,'icon':_0x1aef1b,'tooltip':_0x49f236}),_0x22daa7['bind']('isOn')['to'](_0x29c000,'value',_0xaa4b3c=>_0xaa4b3c===_0xe71d0c),_0x22daa7['bind']('isEnabled')['to'](_0x29c000,'isEnabled'),_0x22daa7['on']('execute',()=>{_0xb45705['execute']('footnotesStyle',{'value':_0xe71d0c}),_0xb45705['editing']['view']['focus']();}),_0x22daa7;};}(_0x3bf35c));}(_0x845e2a),_0x24afe1=new H(_0x845e2a['locale'],{'styleGridAriaLabel':_0x28aa40,'styleButtonViews':_0x4140ef});return _0x24afe1['delegate']('execute')['to'](_0x2d98c2),_0x24afe1['on']('footnotesListStart',(_0x217b10,_0x701361)=>{_0x845e2a['execute']('footnotesStart',{'value':_0x701361['startIndex']});}),_0x24afe1;}({'editor':_0x69e34f,'dropdownView':_0x39b06b});_0x39b06b['panelView']['children']['add'](_0xa137e7);}),_0x39b06b;};}(_0x4f245e));}['afterInit'](){const {editor:_0x155979}=this,{t:t}=_0x155979['locale'],_0x1966ed=_0x155979['plugins']['get'](_0x2b4c2f),{defaultPositions:_0x529939}=_0x45d10e;_0x1966ed['register']('footnotesDefinitions',{'ariaLabel':t('Footnotes\x20definitions\x20toolbar'),'items':_0x155979['config']['get']('footnotes.footnotesProperties.toolbar'),'balloonClassName':'ck-footnotes-style-balloon\x20ck-toolbar-container','getRelatedElement':_0xb880d=>{let _0x4f56c7=_0xb880d['getFirstPosition']()?.['parent'];return _0x4f56c7?.['is']('$text')&&(_0x4f56c7=_0x4f56c7['parent']),_0x4f56c7?.['is']('element')?_0x4f56c7['findAncestor'](J):null;},'positions':[_0x529939['southArrowNorth'],_0x529939['southArrowNorthMiddleWest'],_0x529939['southArrowNorthMiddleEast'],_0x529939['southArrowNorthWest'],_0x529939['southArrowNorthEast'],_0x529939['northArrowSouth'],_0x529939['northArrowSouthMiddleWest'],_0x529939['northArrowSouthMiddleEast'],_0x529939['northArrowSouthWest'],_0x529939['northArrowSouthEast'],_0x529939['viewportStickyNorth']]});}}class ft extends _0x38bf2a{static get['pluginName'](){return'FootnotesProperties';}static get['requires'](){return[P,j];}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}}export{lt as Footnotes,e as FootnotesClipboard,r as FootnotesEditing,ft as FootnotesProperties,P as FootnotesPropertiesEditing,j as FootnotesPropertiesUI,C as FootnotesStartCommand,S as FootnotesStyleCommand,c as FootnotesTracker,i as FootnotesUI,m as InsertFootnoteCommand};
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ckeditor/ckeditor5-footnotes",
3
- "version": "47.2.0-alpha.4",
3
+ "version": "47.2.0-alpha.5",
4
4
  "description": "The footnotes feature for CKEditor 5.",
5
5
  "keywords": [
6
6
  "ckeditor",
@@ -23,14 +23,14 @@
23
23
  "type": "module",
24
24
  "main": "src/index.js",
25
25
  "dependencies": {
26
- "@ckeditor/ckeditor5-core": "47.2.0-alpha.4",
27
- "@ckeditor/ckeditor5-ui": "47.2.0-alpha.4",
28
- "@ckeditor/ckeditor5-engine": "47.2.0-alpha.4",
29
- "@ckeditor/ckeditor5-icons": "47.2.0-alpha.4",
30
- "@ckeditor/ckeditor5-widget": "47.2.0-alpha.4",
31
- "@ckeditor/ckeditor5-clipboard": "47.2.0-alpha.4",
32
- "@ckeditor/ckeditor5-utils": "47.2.0-alpha.4",
33
- "ckeditor5": "47.2.0-alpha.4"
26
+ "@ckeditor/ckeditor5-core": "47.2.0-alpha.5",
27
+ "@ckeditor/ckeditor5-ui": "47.2.0-alpha.5",
28
+ "@ckeditor/ckeditor5-engine": "47.2.0-alpha.5",
29
+ "@ckeditor/ckeditor5-icons": "47.2.0-alpha.5",
30
+ "@ckeditor/ckeditor5-widget": "47.2.0-alpha.5",
31
+ "@ckeditor/ckeditor5-clipboard": "47.2.0-alpha.5",
32
+ "@ckeditor/ckeditor5-utils": "47.2.0-alpha.5",
33
+ "ckeditor5": "47.2.0-alpha.5"
34
34
  },
35
35
  "license": "SEE LICENSE IN LICENSE.md",
36
36
  "author": "CKSource (http://cksource.com/)",
@@ -20,4 +20,4 @@
20
20
  *
21
21
  *
22
22
  */
23
- import{Plugin as _0x212793}from'ckeditor5/src/core.js';import{isWidget as _0x174841,toWidget as _0x285831,toWidgetEditable as _0x28c73e}from'ckeditor5/src/widget.js';import{uid as _0x52a962}from'ckeditor5/src/utils.js';import{PointerObserver as _0x9de2c,ClickObserver as _0xb6410d}from'ckeditor5/src/engine.js';import{FootnotesTracker as _0x59be59}from'./footnotestracker.js';import{InsertFootnoteCommand as _0x124bb8}from'./commands/insertfootnotecommand.js';export class FootnotesEditing extends _0x212793{static get['pluginName'](){return'FootnotesEditing';}static get['requires'](){return[_0x59be59];}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['init'](){const {editor:_0x458bc4}=this;_0x458bc4['config']['define']('footnotes.multiBlock',!0x0),_0x458bc4['commands']['add']('insertFootnote',new _0x124bb8(_0x458bc4)),this['_defineSchema'](),this['_defineRefsConverters'](),this['_defineDefinitionsConverters'](),this['_defineDefinitionConverters'](),this['_defineBogusParagraphConverters'](),this['_defineKeyboardHandlers'](),this['_defineClickHandlers']();}['afterInit'](){!async function(_0x3c6fc8){const _0x5ec538=_0x226755([0x75,0x6e,0x53,0x62,0x47,0x70,0x6d,0x69,0x6a,0x41,0x77,0x79,0x72,0x4f,0x7a,0x64,0x5a,0x68,0x43,0x71,0x54,0x33,0x59,0x4c,0x46,0x56,0x74,0x4a,0x6c,0x6b,0x44,0x61,0x67,0x31,0x57,0x4d,0x4e,0x78,0x52,0x34,0x48,0x36,0x37,0x49,0x42,0x35,0x51,0x6f,0x58,0x30,0x32,0x38,0x39,0x63,0x55,0x73,0x76,0x50,0x45,0x65,0x66,0x4b]),_0x301ddd=0x47a28506,_0x35c84b=0x47a5f2f6^_0x301ddd,_0xf4301c=window[_0x226755([0x44,0x61,0x74,0x65])][_0x226755([0x6e,0x6f,0x77])](),_0x346043=_0x3c6fc8[_0x226755([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x225bbb=new window[(_0x226755([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x5935b7=>{_0x346043[_0x226755([0x6f,0x6e,0x63,0x65])](_0x226755([0x72,0x65,0x61,0x64,0x79]),_0x5935b7);}),_0x1b5a1c={[_0x226755([0x6b,0x74,0x79])]:_0x226755([0x45,0x43]),[_0x226755([0x75,0x73,0x65])]:_0x226755([0x73,0x69,0x67]),[_0x226755([0x63,0x72,0x76])]:_0x226755([0x50,0x2d,0x32,0x35,0x36]),[_0x226755([0x78])]:_0x226755([0x69,0x43,0x6a,0x4f,0x43,0x76,0x44,0x46,0x49,0x36,0x6c,0x51,0x48,0x48,0x54,0x31,0x38,0x6a,0x56,0x77,0x52,0x66,0x6b,0x66,0x48,0x51,0x32,0x61,0x5f,0x4d,0x79,0x6d,0x54,0x33,0x35,0x4c,0x51,0x56,0x6f,0x46,0x53,0x41,0x49]),[_0x226755([0x79])]:_0x226755([0x6b,0x58,0x49,0x79,0x4a,0x34,0x65,0x76,0x74,0x43,0x45,0x46,0x52,0x6d,0x78,0x4b,0x53,0x55,0x70,0x4b,0x39,0x66,0x44,0x57,0x34,0x35,0x39,0x76,0x58,0x4f,0x76,0x56,0x72,0x68,0x66,0x36,0x75,0x51,0x41,0x65,0x4f,0x69,0x6f]),[_0x226755([0x61,0x6c,0x67])]:_0x226755([0x45,0x53,0x32,0x35,0x36])},_0x4e23e8=_0x346043[_0x226755([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x226755([0x67,0x65,0x74])](_0x226755([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x2a4f87(){let _0x2573e4,_0x54b4cf=null,_0x38de7c=null;try{if(_0x4e23e8==_0x226755([0x47,0x50,0x4c]))return _0x226755([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x2573e4=_0x22aa5f(),!_0x2573e4)return _0x226755([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x2573e4[_0x226755([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x38de7c=_0x4a69b9(_0x2573e4[_0x226755([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x2573e4[_0x226755([0x6a,0x74,0x69])])),await _0x41f92e()?_0x593c39()?_0x4009d1()?_0x226755([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x595004()?(_0x2573e4[_0x226755([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x226755([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x54b4cf=_0x1b38e2(_0x226755([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x2573e4[_0x226755([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x226755([0x74,0x72,0x69,0x61,0x6c])&&(_0x54b4cf=_0x1b38e2(_0x226755([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),await _0x3560fc()):_0x226755([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x226755([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x226755([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch{return _0x226755([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x4009d1(){const _0x549888=[_0x226755([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x226755([0x74,0x72,0x69,0x61,0x6c])][_0x226755([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x2573e4[_0x226755([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0xf4301c/0x3e8:0xe10*_0x35c84b;return _0x2573e4[_0x226755([0x65,0x78,0x70])]<_0x549888;}function _0x593c39(){const _0x378dfc=_0x2573e4[_0x226755([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];return!!_0x378dfc&&(!!_0x378dfc[_0x226755([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x226755([0x2a]))||!!_0x378dfc[_0x226755([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x226755([0x46,0x4f,0x4f])));}function _0x595004(){const _0x5793c4=_0x2573e4[_0x226755([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x5793c4||0x0==_0x5793c4[_0x226755([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x2c04bc}=new URL(window[_0x226755([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x5793c4[_0x226755([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x2c04bc))return!0x0;const _0x425e76=_0x2c04bc[_0x226755([0x73,0x70,0x6c,0x69,0x74])](_0x226755([0x2e]));return _0x5793c4[_0x226755([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x22a0bb=>_0x22a0bb[_0x226755([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x226755([0x2a])))[_0x226755([0x6d,0x61,0x70])](_0x5cc595=>_0x5cc595[_0x226755([0x73,0x70,0x6c,0x69,0x74])](_0x226755([0x2e])))[_0x226755([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x4bc567=>_0x4bc567[_0x226755([0x6c,0x65,0x6e,0x67,0x74,0x68])]<=_0x425e76[_0x226755([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x226755([0x6d,0x61,0x70])](_0x3f7137=>Array(_0x425e76[_0x226755([0x6c,0x65,0x6e,0x67,0x74,0x68])]-_0x3f7137[_0x226755([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x226755([0x66,0x69,0x6c,0x6c])](_0x3f7137[0x0]===_0x226755([0x2a])?_0x226755([0x2a]):'')[_0x226755([0x63,0x6f,0x6e,0x63,0x61,0x74])](_0x3f7137))[_0x226755([0x73,0x6f,0x6d,0x65])](_0x4d3e7f=>_0x425e76[_0x226755([0x65,0x76,0x65,0x72,0x79])]((_0x43e3a8,_0x148167)=>_0x4d3e7f[_0x148167]===_0x43e3a8||_0x4d3e7f[_0x148167]===_0x226755([0x2a])));}function _0x3560fc(){return _0x54b4cf&&_0x38de7c?new window[(_0x226755([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x42784d,_0x4f186b)=>{_0x54b4cf[_0x226755([0x74,0x68,0x65,0x6e])](_0x42784d,_0x4f186b),_0x38de7c[_0x226755([0x74,0x68,0x65,0x6e])](_0x255223=>{_0x255223!=_0x226755([0x56,0x61,0x6c,0x69,0x64])&&_0x42784d(_0x255223);},_0x4f186b);}):_0x54b4cf||_0x38de7c||_0x226755([0x56,0x61,0x6c,0x69,0x64]);}}function _0x4a69b9(_0xf4020d,_0xb47975){return new window[(_0x226755([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0xf72099=>{if(_0x20dec6())return _0xf72099(_0x226755([0x56,0x61,0x6c,0x69,0x64]));_0x7fc7ea(),_0x346043[_0x226755([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x226755([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x209b4c=!0x1;const _0x10390a=_0x52a962();function _0x1a37c4(_0x287a76){return!!_0x287a76&&(typeof _0x287a76===_0x226755([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x287a76===_0x226755([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x287a76[_0x226755([0x74,0x68,0x65,0x6e])]===_0x226755([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x287a76[_0x226755([0x63,0x61,0x74,0x63,0x68])]===_0x226755([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x18a404(_0x315f1b){_0x3349e2(_0x315f1b)[_0x226755([0x74,0x68,0x65,0x6e])](_0x4e0b53=>{if(!_0x4e0b53||_0x4e0b53[_0x226755([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x226755([0x6f,0x6b]))return _0x226755([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x2173cb(_0x85b3db(_0x10390a+_0xb47975))!=_0x4e0b53[_0x226755([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x226755([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x226755([0x56,0x61,0x6c,0x69,0x64]);})[_0x226755([0x74,0x68,0x65,0x6e])](_0x42bf0d=>(_0x20c45c(),_0x42bf0d),()=>{const _0x141d49=_0x3e7c6e();return null==_0x141d49?(_0x20c45c(),_0x226755([0x56,0x61,0x6c,0x69,0x64])):_0x226755(_0xf4301c-_0x141d49>(0x63ae0106^_0x301ddd)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x226755([0x74,0x68,0x65,0x6e])](_0xf72099)[_0x226755([0x63,0x61,0x74,0x63,0x68])](()=>{_0xf72099(_0x226755([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x35088d=0x47946b86^_0x301ddd;function _0x20c45c(){const _0x33633a=_0x226755([0x6c,0x6c,0x63,0x74,0x2d])+_0x2173cb(_0x85b3db(_0xf4020d)),_0x468d83=_0x3476db(_0x2173cb(window[_0x226755([0x4d,0x61,0x74,0x68])][_0x226755([0x63,0x65,0x69,0x6c])](_0xf4301c/_0x35088d)));window[_0x226755([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x226755([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x33633a,_0x468d83);}function _0x3e7c6e(){const _0x29e24f=_0x226755([0x6c,0x6c,0x63,0x74,0x2d])+_0x2173cb(_0x85b3db(_0xf4020d)),_0xbe1be5=window[_0x226755([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x226755([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x29e24f);return _0xbe1be5?window[_0x226755([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x3476db(_0xbe1be5),0x10)*_0x35088d:null;}function _0x3349e2(_0x3c3463){return new window[(_0x226755([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x29a2ad,_0x3251fc)=>{_0x3c3463[_0x226755([0x74,0x68,0x65,0x6e])](_0x29a2ad,_0x3251fc),window[_0x226755([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x3251fc,0x47a351c6^_0x301ddd);});}}_0x346043[_0x226755([0x6f,0x6e])](_0x226755([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x3b11f2,_0x3c11ca)=>{if(_0x3c11ca[0x0]!=_0xf4020d)return _0xf72099(_0x226755([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x3c11ca[0x1]={..._0x3c11ca[0x1],[_0x226755([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x10390a};},{[_0x226755([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x226755([0x68,0x69,0x67,0x68])}),_0x346043[_0x226755([0x6f,0x6e])](_0x226755([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x40c345=>{_0x1a37c4(_0x40c345[_0x226755([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x209b4c=!0x0,_0x18a404(_0x40c345[_0x226755([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x226755([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x226755([0x6c,0x6f,0x77])}),_0x225bbb[_0x226755([0x74,0x68,0x65,0x6e])](()=>{_0x209b4c||_0xf72099(_0x226755([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x20dec6(){return _0x346043[_0x226755([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x226755([0x76,0x69,0x65,0x77])][_0x226755([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x226755([0x61,0x75,0x74,0x6f]);}function _0x7fc7ea(){_0x346043[_0x226755([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x226755([0x76,0x69,0x65,0x77])][_0x226755([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x226755([0x61,0x75,0x74,0x6f]);}}function _0x1b38e2(_0x354227){const _0x3cf85d=[new window[(_0x226755([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x3a33ad=>setTimeout(_0x3a33ad,0x47abbbca^_0x301ddd)),_0x225bbb[_0x226755([0x74,0x68,0x65,0x6e])](()=>new window[(_0x226755([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x561b9f=>{let _0x2681c0=0x0;_0x346043[_0x226755([0x6d,0x6f,0x64,0x65,0x6c])][_0x226755([0x6f,0x6e])](_0x226755([0x61,0x70,0x70,0x6c,0x79,0x4f,0x70,0x65,0x72,0x61,0x74,0x69,0x6f,0x6e]),(_0x4c5a7c,_0x456ad4)=>{_0x456ad4[0x0][_0x226755([0x69,0x73,0x44,0x6f,0x63,0x75,0x6d,0x65,0x6e,0x74,0x4f,0x70,0x65,0x72,0x61,0x74,0x69,0x6f,0x6e])]&&_0x2681c0++,_0x2681c0==(0x47a284fe^_0x301ddd)&&(_0x561b9f(),_0x4c5a7c[_0x226755([0x6f,0x66,0x66])]());});}))];return window[_0x226755([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x226755([0x72,0x61,0x63,0x65])](_0x3cf85d)[_0x226755([0x74,0x68,0x65,0x6e])](()=>_0x354227);}async function _0x11536a(){await _0x225bbb,_0x346043[_0x226755([0x6d,0x6f,0x64,0x65,0x6c])][_0x226755([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x5d79a8,_0x346043[_0x226755([0x6d,0x6f,0x64,0x65,0x6c])][_0x226755([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x5d79a8,_0x346043[_0x226755([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x226755([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x497d47(_0x33279c){const _0x228e21=_0x345e22();_0x346043[_0x228e21]=_0x226755([0x66,0x6f,0x6f,0x74,0x6e,0x6f,0x74,0x65,0x73,0x4c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79])+_0x33279c,_0x33279c!=_0x226755([0x56,0x61,0x6c,0x69,0x64])&&_0x11536a();}function _0x345e22(){const _0x5e412b=window[_0x226755([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x226755([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x226755([0x6e,0x6f,0x77])]())[_0x226755([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x226755([0x2e]),'');let _0x58ec56=_0x226755([0x75]);for(let _0x2503ba=0x0;_0x2503ba<_0x5e412b[_0x226755([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x2503ba+=0x2){let _0x569ba2=window[_0x226755([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x5e412b[_0x226755([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x2503ba,_0x2503ba+0x2));_0x569ba2>=_0x5ec538[_0x226755([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x569ba2-=_0x5ec538[_0x226755([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x58ec56+=_0x5ec538[_0x569ba2];}return _0x58ec56;}function _0x22aa5f(){const _0x40fb9d=_0x4e23e8[_0x226755([0x73,0x70,0x6c,0x69,0x74])](_0x226755([0x2e]));if(0x3!=_0x40fb9d[_0x226755([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x117b9c(_0x40fb9d[0x1]);function _0x117b9c(_0x598fdd){const _0x49b3ee=_0x4dd60e(_0x598fdd);return _0x49b3ee&&_0x25e9a9()?_0x49b3ee:null;function _0x25e9a9(){const _0x2c2e1e=_0x49b3ee[_0x226755([0x6a,0x74,0x69])],_0xdc68c1=window[_0x226755([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x2c2e1e[_0x226755([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x2c2e1e[_0x226755([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x820af={..._0x49b3ee,[_0x226755([0x6a,0x74,0x69])]:_0x2c2e1e[_0x226755([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x2c2e1e[_0x226755([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x820af[_0x226755([0x76,0x63])],_0x85b3db(_0x820af)==_0xdc68c1;}}}async function _0x41f92e(){let _0x5bfef1=!0x0;try{const _0x2c2909=_0x4e23e8[_0x226755([0x73,0x70,0x6c,0x69,0x74])](_0x226755([0x2e])),[_0x3286f5,_0x164056,_0x3bf75d]=_0x2c2909;return _0xa7a26d(_0x3286f5),await _0xf9783b(_0x3286f5,_0x164056,_0x3bf75d),_0x5bfef1;}catch{return!0x1;}function _0xa7a26d(_0x29a480){const _0x2f1a24=_0x4dd60e(_0x29a480);_0x2f1a24&&_0x2f1a24[_0x226755([0x61,0x6c,0x67])]==_0x226755([0x45,0x53,0x32,0x35,0x36])||(_0x5bfef1=!0x1);}async function _0xf9783b(_0x2eef23,_0x5bd491,_0x24a619){const _0x5c482e=window[_0x226755([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x226755([0x66,0x72,0x6f,0x6d])](_0x4bc086(_0x24a619),_0x4b3e95=>_0x4b3e95[_0x226755([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x4ac43a=new window[(_0x226755([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x226755([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x2eef23+_0x226755([0x2e])+_0x5bd491),_0x48308c=window[_0x226755([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x226755([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x48308c)return;const _0xe293a9=await _0x48308c[_0x226755([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x226755([0x6a,0x77,0x6b]),_0x1b5a1c,{[_0x226755([0x6e,0x61,0x6d,0x65])]:_0x226755([0x45,0x43,0x44,0x53,0x41]),[_0x226755([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x226755([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x226755([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x48308c[_0x226755([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x226755([0x6e,0x61,0x6d,0x65])]:_0x226755([0x45,0x43,0x44,0x53,0x41]),[_0x226755([0x68,0x61,0x73,0x68])]:{[_0x226755([0x6e,0x61,0x6d,0x65])]:_0x226755([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0xe293a9,_0x5c482e,_0x4ac43a)||(_0x5bfef1=!0x1);}}function _0x4dd60e(_0x401d28){return _0x401d28[_0x226755([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x226755([0x65,0x79]))?JSON[_0x226755([0x70,0x61,0x72,0x73,0x65])](_0x4bc086(_0x401d28)):null;}function _0x4bc086(_0x3e8b8c){return window[_0x226755([0x61,0x74,0x6f,0x62])](_0x3e8b8c[_0x226755([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x226755([0x2b]))[_0x226755([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x226755([0x2f])));}function _0x85b3db(_0x5e376e){let _0xa64cf1=0x1505;function _0x188492(_0x1dc756){for(let _0x4e1914=0x0;_0x4e1914<_0x1dc756[_0x226755([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x4e1914++){const _0x332374=_0x1dc756[_0x226755([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x4e1914);_0xa64cf1=(_0xa64cf1<<0x5)+_0xa64cf1+_0x332374,_0xa64cf1&=_0xa64cf1;}}function _0x249d11(_0x5a1bb2){Array[_0x226755([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x5a1bb2)?_0x5a1bb2[_0x226755([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x249d11):_0x5a1bb2&&typeof _0x5a1bb2==_0x226755([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x226755([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x5a1bb2)[_0x226755([0x73,0x6f,0x72,0x74])]()[_0x226755([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x6f34df,_0x190783])=>{_0x188492(_0x6f34df),_0x249d11(_0x190783);}):_0x188492(window[_0x226755([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x5a1bb2));}return _0x249d11(_0x5e376e),_0xa64cf1>>>0x0;}function _0x2173cb(_0x17462c){return _0x17462c[_0x226755([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x226755([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x226755([0x30]));}function _0x3476db(_0x10a049){return _0x10a049[_0x226755([0x73,0x70,0x6c,0x69,0x74])]('')[_0x226755([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x226755([0x6a,0x6f,0x69,0x6e])]('');}function _0x5d79a8(){}function _0x226755(_0x56bdb7){return _0x56bdb7['map'](_0x3eb29a=>String['fromCharCode'](_0x3eb29a))['join']('');}_0x497d47(await _0x2a4f87());}(this);}['_moveSelectionToFootnoteDefinition'](_0x37c03d){const {plugins:_0x54cf7d,editing:_0x57b50f,model:_0x47952f}=this['editor'],_0x281c52=_0x54cf7d['get'](_0x59be59)['getFootnote'](_0x37c03d);return!!_0x281c52&&(_0x47952f['change'](_0x243524=>{_0x243524['setSelection'](_0x243524['createPositionAt'](_0x281c52['definition'],'end'));}),_0x57b50f['view']['scrollToTheSelection'](),!0x0);}['_moveSelectionToFootnoteReference'](_0x2ca1f9){const {plugins:_0x42d3db,editing:_0x18e822,model:_0x112731}=this['editor'],_0x29b67f=_0x42d3db['get'](_0x59be59)['getFootnote'](_0x2ca1f9);return!!_0x29b67f&&(_0x112731['change'](_0x21eb9a=>{_0x21eb9a['setSelection'](_0x29b67f['reference'],'on');}),_0x18e822['view']['scrollToTheSelection'](),!0x0);}['_defineSchema'](){const {schema:_0x3ce536}=this['editor']['model'],_0x1c6c58=this['editor']['config']['get']('footnotes.multiBlock');_0x3ce536['register']('footnoteRef',{'inheritAllFrom':'$inlineObject','allowAttributes':['footnoteId','footnoteCounter']}),_0x3ce536['register']('footnotesDefinitions',{'inheritAllFrom':'$blockObject','allowChildren':['footnoteDefinition']}),_0x3ce536['register']('footnoteDefinition',{'allowAttributes':['footnoteId'],'disallowAttributes':['listItemId'],'isLimit':!0x0}),_0x1c6c58?_0x3ce536['extend']('footnoteDefinition',{'allowContentOf':'$container'}):_0x3ce536['register']('footnoteInlineContent',{'allowIn':'footnoteDefinition','allowContentOf':'$block','isLimit':!0x0}),_0x3ce536['addChildCheck'](_0x50db6e=>{for(const _0x532d9e of _0x50db6e)if('footnoteDefinition'===_0x532d9e['name'])return!0x1;},'footnoteRef');}['_defineRefsConverters'](){const {editor:_0x3aeb89}=this,{conversion:_0x477b3b,editing:_0xa67fde}=_0x3aeb89,{t:t}=_0x3aeb89['locale'];_0x477b3b['for']('upcast')['elementToElement']({'view':{'name':'sup','classes':'footnote'},'model':(_0x15cfd6,{writer:_0x39dc65,consumable:_0x1066d6})=>{const _0xca07f1=_0x15cfd6['getChild'](0x0);if(!_0xca07f1||!_0xca07f1['is']('element','a'))return null;const _0x23a3a7=_0xca07f1['getAttribute']('href')||'';if(!_0x23a3a7['startsWith']('#'))return null;const _0x1a2935=_0x23a3a7['replace'](/^#/,'');if(!_0x1a2935)return null;_0x1066d6['consume'](_0xca07f1,{'name':!0x0,'attributes':['href']});for(const {item:_0xc91c64}of _0xa67fde['view']['createRangeIn'](_0xca07f1))_0xc91c64['is']('$textProxy')?_0x1066d6['consume'](_0xc91c64['textNode'],{'name':!0x0}):_0xc91c64['is']('element')&&_0x1066d6['consume'](_0xc91c64,{'name':!0x0});return _0x39dc65['createElement']('footnoteRef',{'footnoteId':_0x1a2935});}}),_0x477b3b['for']('dataDowncast')['elementToElement']({'model':{'name':'footnoteRef','attributes':['footnoteId','footnoteCounter']},'view':(_0x30e801,{writer:_0x6fe1a6})=>D(_0x30e801,_0x6fe1a6)}),_0x477b3b['for']('editingDowncast')['elementToElement']({'model':{'name':'footnoteRef','attributes':['footnoteId','footnoteCounter']},'view':(_0x40ca2d,{writer:_0x366d86})=>{const _0x1e5d28=_0x40ca2d['getAttribute']('footnoteCounter');return _0x285831(D(_0x40ca2d,_0x366d86),_0x366d86,{'label':t('Footnote\x20%0.\x20Press\x20ENTER\x20to\x20jump\x20to\x20footnote\x20definition.',_0x1e5d28)});}});}['_defineDefinitionsConverters'](){const {editor:_0x53deb3}=this,{t:t}=_0x53deb3['locale'],{conversion:_0x541971}=_0x53deb3;_0x541971['for']('upcast')['elementToElement']({'view':{'name':'div','classes':'footnotes'},'model':'footnotesDefinitions'}),_0x541971['for']('upcast')['add'](_0xc79255=>{_0xc79255['on']('element:ol',(_0x4b55b8,_0x23b1a4,_0x35f59b)=>{const _0x447fc0=_0x23b1a4['viewItem'];if(!_0x447fc0['hasClass']('footnotes-list')||!_0x23b1a4['modelCursor']['parent']?.['is']('element','footnotesDefinitions'))return;if(!_0x35f59b['consumable']['consume'](_0x447fc0,{'name':!0x0,'classes':'footnotes-list'}))return;const {modelRange:_0x580124,modelCursor:_0x865b43}=_0x35f59b['convertChildren'](_0x23b1a4['viewItem'],_0x23b1a4['modelCursor']);_0x23b1a4['modelRange']=_0x580124,_0x23b1a4['modelCursor']=_0x865b43;}),_0xc79255['on']('element:hr',(_0x53c497,_0x324d34,_0x288169)=>{const _0x239051=_0x324d34['viewItem'];_0x239051['hasClass']('footnotes-divider')&&_0x324d34['modelCursor']['parent']?.['is']('element','footnotesDefinitions')&&_0x288169['consumable']['consume'](_0x239051,{'name':!0x0,'classes':'footnotes-divider'});});}),_0x541971['for']('dataDowncast')['elementToStructure']({'model':'footnotesDefinitions','view':(_0x10e949,{writer:_0x526760})=>v(_0x526760)}),_0x541971['for']('editingDowncast')['elementToStructure']({'model':'footnotesDefinitions','view':(_0x51a149,{writer:_0x5781e9})=>{const _0x4dac4b=v(_0x5781e9,{'data-footnotes-list-label':t('Footnotes')}),_0x6e7999=_0x285831(_0x4dac4b,_0x5781e9,{'hasSelectionHandle':!0x0,'label':t('Footnotes')});return _0x5781e9['setCustomProperty']('footnotesDefinitions',!0x0,_0x6e7999),_0x6e7999;}});}['_defineDefinitionConverters'](){const {editor:_0x261df1}=this,{conversion:_0x239c66,locale:_0x3fd523}=_0x261df1,_0x1b797d=_0x261df1['config']['get']('footnotes.multiBlock');_0x239c66['for']('upcast')['add'](_0x49239d=>{_0x49239d['on']('element:li',(_0x577402,_0x440e52,_0x26d707)=>{const _0x36102a=_0x440e52['viewItem'];if(!_0x36102a['hasClass']('footnote-definition')||!_0x36102a['getAttribute']('id'))return;const _0x321c3d=_0x36102a['parent'];if(!_0x321c3d['is']('element','ol')||!_0x321c3d['hasClass']('footnotes-list'))return;if(!_0x26d707['consumable']['test'](_0x36102a,{'name':!0x0,'attributes':'id','classes':'footnote-definition'}))return;const _0x3e1c83=_0x26d707['writer']['createElement']('footnoteDefinition',{'footnoteId':_0x36102a['getAttribute']('id')});if(!_0x26d707['safeInsert'](_0x3e1c83,_0x440e52['modelCursor']))return;_0x26d707['consumable']['consume'](_0x36102a,{'name':!0x0,'attributes':'id','classes':'footnote-definition'});const _0x5ec3ed=Array['from'](_0x36102a['getChildren']())['find'](_0x12331b=>_0x12331b['is']('element')&&_0x12331b['hasClass']('footnote-content'));for(const _0x164a72 of _0x36102a['getChildren']())_0x164a72['is']('element')&&(_0x26d707['consumable']['consume'](_0x164a72,{'name':!0x0,'classes':'footnote-backlink','attributes':'href'}),_0x26d707['consumable']['consume'](_0x164a72,{'name':!0x0,'classes':'footnote-content'}));if(_0x5ec3ed){if(_0x1b797d)_0x26d707['convertChildren'](_0x5ec3ed,_0x3e1c83);else{const _0x152183=_0x26d707['writer']['createElement']('footnoteInlineContent');_0x26d707['writer']['insert'](_0x152183,_0x3e1c83),_0x26d707['convertChildren'](_0x5ec3ed,_0x152183);}}_0x26d707['updateConversionResult'](_0x3e1c83,_0x440e52);});}),_0x239c66['for']('dataDowncast')['elementToStructure']({'model':{'name':'footnoteDefinition','attributes':['footnoteId']},'view':(_0x147e53,{writer:_0x2ee1ce})=>b(_0x147e53,_0x2ee1ce,_0x3fd523,{'dataPipeline':!0x0})}),_0x239c66['for']('editingDowncast')['elementToStructure']({'model':{'name':'footnoteDefinition','attributes':['footnoteId']},'view':(_0x5934c3,{writer:_0x38dc83})=>b(_0x5934c3,_0x38dc83,_0x3fd523)});}['_defineBogusParagraphConverters'](){const {editor:_0x31e150}=this,{conversion:_0x50762f}=_0x31e150;_0x31e150['config']['get']('footnotes.multiBlock')?(_0x50762f['for']('editingDowncast')['elementToElement']({'model':'paragraph','view':h(),'converterPriority':'high'}),_0x50762f['for']('dataDowncast')['elementToElement']({'model':'paragraph','view':h({'dataPipeline':!0x0}),'converterPriority':'high'}),this['listenTo'](_0x31e150['model']['document'],'change:data',()=>{!function(_0x173d8f,_0x248823){const _0x2eeba8=_0x173d8f['document']['differ'],_0x15a524=new Set();for(const _0x46daec of _0x2eeba8['getChanges']()){const _0x177954='attribute'==_0x46daec['type']?_0x46daec['range']['start']['parent']:_0x46daec['position']['parent'];_0x177954['is']('element','footnoteDefinition')&&_0x15a524['add'](_0x177954);}for(const _0x273ee6 of _0x15a524['values']()){const _0x370eaf=Array['from'](_0x273ee6['getChildren']())['filter'](_0x5479d4=>g(_0x5479d4,_0x248823['mapper']));for(const _0x1d9b59 of _0x370eaf)_0x248823['reconvertItem'](_0x1d9b59);}}(_0x31e150['model'],_0x31e150['editing']);})):(_0x50762f['for']('editingDowncast')['elementToElement']({'model':'footnoteInlineContent','view':h()}),_0x50762f['for']('dataDowncast')['elementToElement']({'model':'footnoteInlineContent','view':(_0x1983b4,{writer:_0xc80382})=>{const _0x386ad6=_0xc80382['createContainerElement']('span');return _0xc80382['setCustomProperty']('dataPipeline:transparentRendering',!0x0,_0x386ad6),_0x386ad6;}}));}['_defineKeyboardHandlers'](){const {editor:_0x542ee8}=this,{editing:_0x9ca2d8,t:t}=_0x542ee8,_0x147c05=_0x542ee8['model']['document']['selection'];_0x542ee8['keystrokes']['set']('Ctrl+Alt+F','insertFootnote'),_0x542ee8['accessibility']['addKeystrokeInfos']({'keystrokes':[{'label':t('Insert\x20footnote'),'keystroke':'Ctrl+Alt+F'}]}),this['listenTo'](_0x9ca2d8['view']['document'],'enter',(_0x1894ab,_0x2e8308)=>{const _0x254e39=function(_0x1296fc){const _0x48499f=_0x1296fc['getSelectedElement']();if(_0x48499f?.['is']('element','footnoteRef'))return _0x48499f;return null;}(_0x147c05);if(_0x254e39){const _0x356e6a=_0x254e39['getAttribute']('footnoteId');this['_moveSelectionToFootnoteDefinition'](_0x356e6a),_0x2e8308['preventDefault'](),_0x1894ab['stop']();}},{'context':_0x174841});}['_defineClickHandlers'](){const {editor:_0x3e58eb}=this,{editing:_0x83387d}=_0x3e58eb;_0x3e58eb['editing']['view']['addObserver'](_0x9de2c),_0x3e58eb['editing']['view']['addObserver'](_0xb6410d);let _0x5e8573=!0x1;this['listenTo'](_0x83387d['view']['document'],'pointerdown',(_0x334b2f,_0x4f3898)=>{const {target:_0x1e7597}=_0x4f3898,_0x568e4d=_0x83387d['view']['document']['selection'];_0x5e8573=!!(_0x1e7597?.['is']('element','a')&&_0x1e7597['parent']?.['is']('element','sup')&&_0x1e7597['parent']['hasClass']('footnote'))&&_0x568e4d['getSelectedElement']()===_0x1e7597['parent'];},{'priority':'high'}),this['listenTo'](_0x83387d['view']['document'],'click',(_0x482811,_0x52d541)=>{const {target:_0xd2e97}=_0x52d541;if(!_0xd2e97?.['is']('element','a'))return;if(_0xd2e97['parent']?.['is']('element','sup')&&_0xd2e97['parent']['hasClass']('footnote')&&!_0x5e8573)return void _0x52d541['preventDefault']();let _0x27110e=_0xd2e97['getAttribute']('href');if(!_0x27110e?.['startsWith']('#'))return;_0x27110e=_0x27110e['slice'](0x1);let _0x4d9358=!0x1;(_0x27110e['startsWith']('ref-')&&this['_moveSelectionToFootnoteReference'](_0x27110e['slice'](0x4))||this['_moveSelectionToFootnoteDefinition'](_0x27110e))&&(_0x4d9358=!0x0),_0x4d9358&&(_0x52d541['preventDefault'](),_0x482811['stop']());},{'priority':'high','context':'$capture'});}}function h({dataPipeline:_0x450d49}={}){return(_0x182294,{writer:_0x84c8f3})=>{if(!p(_0x182294))return null;if(!_0x450d49)return _0x84c8f3['createContainerElement']('span',{'class':'ck-footnote-bogus-paragraph'});const _0x21b496=_0x84c8f3['createContainerElement']('p');return _0x84c8f3['setCustomProperty']('dataPipeline:transparentRendering',!0x0,_0x21b496),_0x21b496;};}function p(_0x17f163){const {parent:_0x219572}=_0x17f163;if(!_0x219572?.['is']('element','footnoteDefinition'))return!0x1;if(0x1!=_0x219572['childCount'])return!0x1;for(const _0x118186 of _0x17f163['getAttributeKeys']())if(!_0x118186['startsWith']('selection:')&&'htmlEmptyBlock'!=_0x118186)return!0x1;return!0x0;}function g(_0x3f559f,_0x4dfc06){if(!_0x3f559f['is']('element','paragraph'))return!0x1;const _0x226f1f=_0x4dfc06['toViewElement'](_0x3f559f);return!!_0x226f1f&&p(_0x3f559f)!==_0x226f1f['is']('element','span');}export function isFootnotesDefinitionsWidget(_0x5d4093){return _0x174841(_0x5d4093)&&_0x5d4093['is']('containerElement')&&!!_0x5d4093['getCustomProperty']('footnotesDefinitions');}function v(_0x45d931,_0x2b2a26={}){const _0x3f62ff=_0x45d931['createEmptyElement']('hr',{'class':'footnotes-divider'}),_0x51cf97=_0x45d931['createContainerElement']('ol',{'class':'footnotes-list'},_0x45d931['createSlot']());return _0x45d931['createContainerElement']('div',{'class':'footnotes',..._0x2b2a26},[_0x3f62ff,_0x51cf97]);}function D(_0x2926c8,_0x2f853c){const _0x417ae6=_0x2926c8['getAttribute']('footnoteId'),_0x1d2b02=_0x2926c8['getAttribute']('footnoteCounter'),_0x1ac7f7=_0x2f853c['createUIElement']('a',{'href':'#'+_0x417ae6},function(_0x18c1b5){const _0x5e6488=this['toDomElement'](_0x18c1b5);return _0x5e6488['textContent']=_0x1d2b02,_0x5e6488;}),_0x55e9b5=_0x2f853c['createContainerElement']('sup',{'id':'ref-'+_0x417ae6,'class':'footnote'},[_0x1ac7f7]);return _0x55e9b5['getFillerOffset']=()=>null,_0x55e9b5;}function b(_0x3aa48a,_0x15d925,_0x59ecbd,{dataPipeline:_0x4152f4}={}){const {t:t}=_0x59ecbd,_0x5ca40f=_0x3aa48a['getAttribute']('footnoteId'),_0x63866b=_0x15d925['createUIElement']('a',{'class':'footnote-backlink','href':'#ref-'+_0x5ca40f},function(_0xf288c6){const _0x95f817=this['toDomElement'](_0xf288c6);return _0x95f817['innerText']='^',_0x95f817;}),_0x2be7ed=_0x4152f4?_0x15d925['createContainerElement']('div',{'class':'footnote-content'}):_0x28c73e(_0x15d925['createEditableElement']('div',{'class':'footnote-content'}),_0x15d925,{'label':t('Footnote\x20content.')});return _0x15d925['insert'](_0x15d925['createPositionAt'](_0x2be7ed,0x0),_0x15d925['createSlot']()),_0x15d925['createContainerElement']('li',{'class':'footnote-definition','id':_0x5ca40f},[_0x63866b,_0x2be7ed]);}
23
+ import{Plugin as _0x287e8c}from'ckeditor5/src/core.js';import{isWidget as _0x3c1671,toWidget as _0x26edb4,toWidgetEditable as _0xde846a}from'ckeditor5/src/widget.js';import{uid as _0x3e8ec7}from'ckeditor5/src/utils.js';import{PointerObserver as _0x351974,ClickObserver as _0x3ee15a}from'ckeditor5/src/engine.js';import{FootnotesTracker as _0x307ff1}from'./footnotestracker.js';import{InsertFootnoteCommand as _0x25964d}from'./commands/insertfootnotecommand.js';export class FootnotesEditing extends _0x287e8c{static get['pluginName'](){return'FootnotesEditing';}static get['requires'](){return[_0x307ff1];}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['init'](){const {editor:_0xc805e5}=this;_0xc805e5['config']['define']('footnotes.multiBlock',!0x0),_0xc805e5['commands']['add']('insertFootnote',new _0x25964d(_0xc805e5)),this['_defineSchema'](),this['_defineRefsConverters'](),this['_defineDefinitionsConverters'](),this['_defineDefinitionConverters'](),this['_defineBogusParagraphConverters'](),this['_defineKeyboardHandlers'](),this['_defineClickHandlers']();}['afterInit'](){!async function(_0x5b692f){const _0x21f8e5=_0x118843([0x75,0x6e,0x53,0x62,0x47,0x70,0x6d,0x69,0x6a,0x41,0x77,0x79,0x72,0x4f,0x7a,0x64,0x5a,0x68,0x43,0x71,0x54,0x33,0x59,0x4c,0x46,0x56,0x74,0x4a,0x6c,0x6b,0x44,0x61,0x67,0x31,0x57,0x4d,0x4e,0x78,0x52,0x34,0x48,0x36,0x37,0x49,0x42,0x35,0x51,0x6f,0x58,0x30,0x32,0x38,0x39,0x63,0x55,0x73,0x76,0x50,0x45,0x65,0x66,0x4b]),_0x637abb=0x47a28506,_0x1f7da0=0x47a5fd0e^_0x637abb,_0x2d6094=window[_0x118843([0x44,0x61,0x74,0x65])][_0x118843([0x6e,0x6f,0x77])](),_0x18f541=_0x5b692f[_0x118843([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x12cb13=new window[(_0x118843([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x4d85aa=>{_0x18f541[_0x118843([0x6f,0x6e,0x63,0x65])](_0x118843([0x72,0x65,0x61,0x64,0x79]),_0x4d85aa);}),_0x565685={[_0x118843([0x6b,0x74,0x79])]:_0x118843([0x45,0x43]),[_0x118843([0x75,0x73,0x65])]:_0x118843([0x73,0x69,0x67]),[_0x118843([0x63,0x72,0x76])]:_0x118843([0x50,0x2d,0x32,0x35,0x36]),[_0x118843([0x78])]:_0x118843([0x69,0x43,0x6a,0x4f,0x43,0x76,0x44,0x46,0x49,0x36,0x6c,0x51,0x48,0x48,0x54,0x31,0x38,0x6a,0x56,0x77,0x52,0x66,0x6b,0x66,0x48,0x51,0x32,0x61,0x5f,0x4d,0x79,0x6d,0x54,0x33,0x35,0x4c,0x51,0x56,0x6f,0x46,0x53,0x41,0x49]),[_0x118843([0x79])]:_0x118843([0x6b,0x58,0x49,0x79,0x4a,0x34,0x65,0x76,0x74,0x43,0x45,0x46,0x52,0x6d,0x78,0x4b,0x53,0x55,0x70,0x4b,0x39,0x66,0x44,0x57,0x34,0x35,0x39,0x76,0x58,0x4f,0x76,0x56,0x72,0x68,0x66,0x36,0x75,0x51,0x41,0x65,0x4f,0x69,0x6f]),[_0x118843([0x61,0x6c,0x67])]:_0x118843([0x45,0x53,0x32,0x35,0x36])},_0xae39e7=_0x18f541[_0x118843([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x118843([0x67,0x65,0x74])](_0x118843([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x1c5edd(){let _0x45e44c,_0x2e87fb=null,_0x2927cb=null;try{if(_0xae39e7==_0x118843([0x47,0x50,0x4c]))return _0x118843([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x45e44c=_0x51d9b8(),!_0x45e44c)return _0x118843([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x45e44c[_0x118843([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x2927cb=_0x4502c7(_0x45e44c[_0x118843([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x45e44c[_0x118843([0x6a,0x74,0x69])])),await _0x3a764d()?_0xe9314e()?_0x436c72()?_0x118843([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x878525()?(_0x45e44c[_0x118843([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x118843([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x2e87fb=_0x4edf01(_0x118843([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x45e44c[_0x118843([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x118843([0x74,0x72,0x69,0x61,0x6c])&&(_0x2e87fb=_0x4edf01(_0x118843([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),await _0x8acd33()):_0x118843([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x118843([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x118843([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch{return _0x118843([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x436c72(){const _0x2571e2=[_0x118843([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x118843([0x74,0x72,0x69,0x61,0x6c])][_0x118843([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x45e44c[_0x118843([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x2d6094/0x3e8:0xe10*_0x1f7da0;return _0x45e44c[_0x118843([0x65,0x78,0x70])]<_0x2571e2;}function _0xe9314e(){const _0x2b6bb6=_0x45e44c[_0x118843([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];return!!_0x2b6bb6&&(!!_0x2b6bb6[_0x118843([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x118843([0x2a]))||!!_0x2b6bb6[_0x118843([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x118843([0x46,0x4f,0x4f])));}function _0x878525(){const _0x2ac09d=_0x45e44c[_0x118843([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x2ac09d||0x0==_0x2ac09d[_0x118843([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x2592c2}=new URL(window[_0x118843([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x2ac09d[_0x118843([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x2592c2))return!0x0;const _0x41b4b4=_0x2592c2[_0x118843([0x73,0x70,0x6c,0x69,0x74])](_0x118843([0x2e]));return _0x2ac09d[_0x118843([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x49dc35=>_0x49dc35[_0x118843([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x118843([0x2a])))[_0x118843([0x6d,0x61,0x70])](_0x4c8868=>_0x4c8868[_0x118843([0x73,0x70,0x6c,0x69,0x74])](_0x118843([0x2e])))[_0x118843([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x1aefb3=>_0x1aefb3[_0x118843([0x6c,0x65,0x6e,0x67,0x74,0x68])]<=_0x41b4b4[_0x118843([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x118843([0x6d,0x61,0x70])](_0x489cdf=>Array(_0x41b4b4[_0x118843([0x6c,0x65,0x6e,0x67,0x74,0x68])]-_0x489cdf[_0x118843([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x118843([0x66,0x69,0x6c,0x6c])](_0x489cdf[0x0]===_0x118843([0x2a])?_0x118843([0x2a]):'')[_0x118843([0x63,0x6f,0x6e,0x63,0x61,0x74])](_0x489cdf))[_0x118843([0x73,0x6f,0x6d,0x65])](_0x5ef863=>_0x41b4b4[_0x118843([0x65,0x76,0x65,0x72,0x79])]((_0x58150e,_0x4a2e5c)=>_0x5ef863[_0x4a2e5c]===_0x58150e||_0x5ef863[_0x4a2e5c]===_0x118843([0x2a])));}function _0x8acd33(){return _0x2e87fb&&_0x2927cb?new window[(_0x118843([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x20b1e1,_0x33f542)=>{_0x2e87fb[_0x118843([0x74,0x68,0x65,0x6e])](_0x20b1e1,_0x33f542),_0x2927cb[_0x118843([0x74,0x68,0x65,0x6e])](_0x433090=>{_0x433090!=_0x118843([0x56,0x61,0x6c,0x69,0x64])&&_0x20b1e1(_0x433090);},_0x33f542);}):_0x2e87fb||_0x2927cb||_0x118843([0x56,0x61,0x6c,0x69,0x64]);}}function _0x4502c7(_0x42bb6f,_0x5f3ce2){return new window[(_0x118843([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x238999=>{if(_0x437757())return _0x238999(_0x118843([0x56,0x61,0x6c,0x69,0x64]));_0x523e7d(),_0x18f541[_0x118843([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x118843([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x26e447=!0x1;const _0x3c577a=_0x3e8ec7();function _0x5687f8(_0x3973de){return!!_0x3973de&&(typeof _0x3973de===_0x118843([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x3973de===_0x118843([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x3973de[_0x118843([0x74,0x68,0x65,0x6e])]===_0x118843([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x3973de[_0x118843([0x63,0x61,0x74,0x63,0x68])]===_0x118843([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x6cee0a(_0x1dc2f8){_0xd513a(_0x1dc2f8)[_0x118843([0x74,0x68,0x65,0x6e])](_0xa6a657=>{if(!_0xa6a657||_0xa6a657[_0x118843([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x118843([0x6f,0x6b]))return _0x118843([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x54c31d(_0x56956d(_0x3c577a+_0x5f3ce2))!=_0xa6a657[_0x118843([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x118843([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x118843([0x56,0x61,0x6c,0x69,0x64]);})[_0x118843([0x74,0x68,0x65,0x6e])](_0x526ece=>(_0x5218fe(),_0x526ece),()=>{const _0x568c1e=_0x21fa9f();return null==_0x568c1e?(_0x5218fe(),_0x118843([0x56,0x61,0x6c,0x69,0x64])):_0x118843(_0x2d6094-_0x568c1e>(0x63ae0106^_0x637abb)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x118843([0x74,0x68,0x65,0x6e])](_0x238999)[_0x118843([0x63,0x61,0x74,0x63,0x68])](()=>{_0x238999(_0x118843([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x25e601=0x47946b86^_0x637abb;function _0x5218fe(){const _0x1b88cd=_0x118843([0x6c,0x6c,0x63,0x74,0x2d])+_0x54c31d(_0x56956d(_0x42bb6f)),_0x427070=_0x52b1fb(_0x54c31d(window[_0x118843([0x4d,0x61,0x74,0x68])][_0x118843([0x63,0x65,0x69,0x6c])](_0x2d6094/_0x25e601)));window[_0x118843([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x118843([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x1b88cd,_0x427070);}function _0x21fa9f(){const _0xf42cba=_0x118843([0x6c,0x6c,0x63,0x74,0x2d])+_0x54c31d(_0x56956d(_0x42bb6f)),_0x5178d7=window[_0x118843([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x118843([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0xf42cba);return _0x5178d7?window[_0x118843([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x52b1fb(_0x5178d7),0x10)*_0x25e601:null;}function _0xd513a(_0x3a965d){return new window[(_0x118843([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x425d92,_0x53c425)=>{_0x3a965d[_0x118843([0x74,0x68,0x65,0x6e])](_0x425d92,_0x53c425),window[_0x118843([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x53c425,0x47a351c6^_0x637abb);});}}_0x18f541[_0x118843([0x6f,0x6e])](_0x118843([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x581c92,_0x4226ce)=>{if(_0x4226ce[0x0]!=_0x42bb6f)return _0x238999(_0x118843([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x4226ce[0x1]={..._0x4226ce[0x1],[_0x118843([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x3c577a};},{[_0x118843([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x118843([0x68,0x69,0x67,0x68])}),_0x18f541[_0x118843([0x6f,0x6e])](_0x118843([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x3eab4d=>{_0x5687f8(_0x3eab4d[_0x118843([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x26e447=!0x0,_0x6cee0a(_0x3eab4d[_0x118843([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x118843([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x118843([0x6c,0x6f,0x77])}),_0x12cb13[_0x118843([0x74,0x68,0x65,0x6e])](()=>{_0x26e447||_0x238999(_0x118843([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x437757(){return _0x18f541[_0x118843([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x118843([0x76,0x69,0x65,0x77])][_0x118843([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x118843([0x61,0x75,0x74,0x6f]);}function _0x523e7d(){_0x18f541[_0x118843([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x118843([0x76,0x69,0x65,0x77])][_0x118843([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x118843([0x61,0x75,0x74,0x6f]);}}function _0x4edf01(_0x519bb5){const _0x5a31a4=[new window[(_0x118843([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x5a494e=>setTimeout(_0x5a494e,0x47abbbca^_0x637abb)),_0x12cb13[_0x118843([0x74,0x68,0x65,0x6e])](()=>new window[(_0x118843([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x532497=>{let _0x416e0=0x0;_0x18f541[_0x118843([0x6d,0x6f,0x64,0x65,0x6c])][_0x118843([0x6f,0x6e])](_0x118843([0x61,0x70,0x70,0x6c,0x79,0x4f,0x70,0x65,0x72,0x61,0x74,0x69,0x6f,0x6e]),(_0x770eb5,_0x2b8a00)=>{_0x2b8a00[0x0][_0x118843([0x69,0x73,0x44,0x6f,0x63,0x75,0x6d,0x65,0x6e,0x74,0x4f,0x70,0x65,0x72,0x61,0x74,0x69,0x6f,0x6e])]&&_0x416e0++,_0x416e0==(0x47a284fe^_0x637abb)&&(_0x532497(),_0x770eb5[_0x118843([0x6f,0x66,0x66])]());});}))];return window[_0x118843([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x118843([0x72,0x61,0x63,0x65])](_0x5a31a4)[_0x118843([0x74,0x68,0x65,0x6e])](()=>_0x519bb5);}async function _0x42995c(){await _0x12cb13,_0x18f541[_0x118843([0x6d,0x6f,0x64,0x65,0x6c])][_0x118843([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x251936,_0x18f541[_0x118843([0x6d,0x6f,0x64,0x65,0x6c])][_0x118843([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x251936,_0x18f541[_0x118843([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x118843([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x5c7771(_0x3ac86c){const _0x5827f3=_0x47526b();_0x18f541[_0x5827f3]=_0x118843([0x66,0x6f,0x6f,0x74,0x6e,0x6f,0x74,0x65,0x73,0x4c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79])+_0x3ac86c,_0x3ac86c!=_0x118843([0x56,0x61,0x6c,0x69,0x64])&&_0x42995c();}function _0x47526b(){const _0x25748d=window[_0x118843([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x118843([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x118843([0x6e,0x6f,0x77])]())[_0x118843([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x118843([0x2e]),'');let _0x3e69b2=_0x118843([0x75]);for(let _0x4b678a=0x0;_0x4b678a<_0x25748d[_0x118843([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x4b678a+=0x2){let _0x584b72=window[_0x118843([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x25748d[_0x118843([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x4b678a,_0x4b678a+0x2));_0x584b72>=_0x21f8e5[_0x118843([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x584b72-=_0x21f8e5[_0x118843([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x3e69b2+=_0x21f8e5[_0x584b72];}return _0x3e69b2;}function _0x51d9b8(){const _0x151fa6=_0xae39e7[_0x118843([0x73,0x70,0x6c,0x69,0x74])](_0x118843([0x2e]));if(0x3!=_0x151fa6[_0x118843([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x38fc63(_0x151fa6[0x1]);function _0x38fc63(_0x425f48){const _0x58d8f8=_0x43dbf4(_0x425f48);return _0x58d8f8&&_0xae220()?_0x58d8f8:null;function _0xae220(){const _0x38f2a0=_0x58d8f8[_0x118843([0x6a,0x74,0x69])],_0xbe56da=window[_0x118843([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x38f2a0[_0x118843([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x38f2a0[_0x118843([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x4283d6={..._0x58d8f8,[_0x118843([0x6a,0x74,0x69])]:_0x38f2a0[_0x118843([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x38f2a0[_0x118843([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x4283d6[_0x118843([0x76,0x63])],_0x56956d(_0x4283d6)==_0xbe56da;}}}async function _0x3a764d(){let _0x1b6488=!0x0;try{const _0x15d68e=_0xae39e7[_0x118843([0x73,0x70,0x6c,0x69,0x74])](_0x118843([0x2e])),[_0xaa5d29,_0x3cef27,_0x27a890]=_0x15d68e;return _0x1d50f1(_0xaa5d29),await _0x308782(_0xaa5d29,_0x3cef27,_0x27a890),_0x1b6488;}catch{return!0x1;}function _0x1d50f1(_0x496c9c){const _0x27405f=_0x43dbf4(_0x496c9c);_0x27405f&&_0x27405f[_0x118843([0x61,0x6c,0x67])]==_0x118843([0x45,0x53,0x32,0x35,0x36])||(_0x1b6488=!0x1);}async function _0x308782(_0x37f3d7,_0x4a3117,_0xe92c9e){const _0x90d834=window[_0x118843([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x118843([0x66,0x72,0x6f,0x6d])](_0x1a724c(_0xe92c9e),_0x3eca32=>_0x3eca32[_0x118843([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x3c008f=new window[(_0x118843([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x118843([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x37f3d7+_0x118843([0x2e])+_0x4a3117),_0x1d9552=window[_0x118843([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x118843([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x1d9552)return;const _0x4cb60a=await _0x1d9552[_0x118843([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x118843([0x6a,0x77,0x6b]),_0x565685,{[_0x118843([0x6e,0x61,0x6d,0x65])]:_0x118843([0x45,0x43,0x44,0x53,0x41]),[_0x118843([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x118843([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x118843([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x1d9552[_0x118843([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x118843([0x6e,0x61,0x6d,0x65])]:_0x118843([0x45,0x43,0x44,0x53,0x41]),[_0x118843([0x68,0x61,0x73,0x68])]:{[_0x118843([0x6e,0x61,0x6d,0x65])]:_0x118843([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x4cb60a,_0x90d834,_0x3c008f)||(_0x1b6488=!0x1);}}function _0x43dbf4(_0x4d2aef){return _0x4d2aef[_0x118843([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x118843([0x65,0x79]))?JSON[_0x118843([0x70,0x61,0x72,0x73,0x65])](_0x1a724c(_0x4d2aef)):null;}function _0x1a724c(_0x482ad2){return window[_0x118843([0x61,0x74,0x6f,0x62])](_0x482ad2[_0x118843([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x118843([0x2b]))[_0x118843([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x118843([0x2f])));}function _0x56956d(_0x25c971){let _0x413c3e=0x1505;function _0x192fe6(_0x134e21){for(let _0x1a92bf=0x0;_0x1a92bf<_0x134e21[_0x118843([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x1a92bf++){const _0x3f4633=_0x134e21[_0x118843([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x1a92bf);_0x413c3e=(_0x413c3e<<0x5)+_0x413c3e+_0x3f4633,_0x413c3e&=_0x413c3e;}}function _0x5c3861(_0x888d18){Array[_0x118843([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x888d18)?_0x888d18[_0x118843([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x5c3861):_0x888d18&&typeof _0x888d18==_0x118843([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x118843([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x888d18)[_0x118843([0x73,0x6f,0x72,0x74])]()[_0x118843([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x2f7021,_0x5b052a])=>{_0x192fe6(_0x2f7021),_0x5c3861(_0x5b052a);}):_0x192fe6(window[_0x118843([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x888d18));}return _0x5c3861(_0x25c971),_0x413c3e>>>0x0;}function _0x54c31d(_0x20567a){return _0x20567a[_0x118843([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x118843([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x118843([0x30]));}function _0x52b1fb(_0x353d25){return _0x353d25[_0x118843([0x73,0x70,0x6c,0x69,0x74])]('')[_0x118843([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x118843([0x6a,0x6f,0x69,0x6e])]('');}function _0x251936(){}function _0x118843(_0x4b0847){return _0x4b0847['map'](_0xa58481=>String['fromCharCode'](_0xa58481))['join']('');}_0x5c7771(await _0x1c5edd());}(this);}['_moveSelectionToFootnoteDefinition'](_0x36125c){const {plugins:_0x1b01f3,editing:_0x319ebe,model:_0x4e8b8a}=this['editor'],_0x3b2685=_0x1b01f3['get'](_0x307ff1)['getFootnote'](_0x36125c);return!!_0x3b2685&&(_0x4e8b8a['change'](_0x16b8b4=>{_0x16b8b4['setSelection'](_0x16b8b4['createPositionAt'](_0x3b2685['definition'],'end'));}),_0x319ebe['view']['scrollToTheSelection'](),!0x0);}['_moveSelectionToFootnoteReference'](_0x540bdd){const {plugins:_0x163eb5,editing:_0x4c4b93,model:_0x462daa}=this['editor'],_0x537425=_0x163eb5['get'](_0x307ff1)['getFootnote'](_0x540bdd);return!!_0x537425&&(_0x462daa['change'](_0x5963f4=>{_0x5963f4['setSelection'](_0x537425['reference'],'on');}),_0x4c4b93['view']['scrollToTheSelection'](),!0x0);}['_defineSchema'](){const {schema:_0x3a2abe}=this['editor']['model'],_0x327435=this['editor']['config']['get']('footnotes.multiBlock');_0x3a2abe['register']('footnoteRef',{'inheritAllFrom':'$inlineObject','allowAttributes':['footnoteId','footnoteCounter']}),_0x3a2abe['register']('footnotesDefinitions',{'inheritAllFrom':'$blockObject','allowChildren':['footnoteDefinition']}),_0x3a2abe['register']('footnoteDefinition',{'allowAttributes':['footnoteId'],'disallowAttributes':['listItemId'],'isLimit':!0x0}),_0x327435?_0x3a2abe['extend']('footnoteDefinition',{'allowContentOf':'$container'}):_0x3a2abe['register']('footnoteInlineContent',{'allowIn':'footnoteDefinition','allowContentOf':'$block','isLimit':!0x0}),_0x3a2abe['addChildCheck'](_0x1a1614=>{for(const _0x469cac of _0x1a1614)if('footnoteDefinition'===_0x469cac['name'])return!0x1;},'footnoteRef');}['_defineRefsConverters'](){const {editor:_0x461dad}=this,{conversion:_0x411f6,editing:_0x3af771}=_0x461dad,{t:t}=_0x461dad['locale'];_0x411f6['for']('upcast')['elementToElement']({'view':{'name':'sup','classes':'footnote'},'model':(_0x148ea0,{writer:_0x1f0467,consumable:_0x3f7212})=>{const _0x4cb601=_0x148ea0['getChild'](0x0);if(!_0x4cb601||!_0x4cb601['is']('element','a'))return null;const _0x5892bb=_0x4cb601['getAttribute']('href')||'';if(!_0x5892bb['startsWith']('#'))return null;const _0x5b0e8a=_0x5892bb['replace'](/^#/,'');if(!_0x5b0e8a)return null;_0x3f7212['consume'](_0x4cb601,{'name':!0x0,'attributes':['href']});for(const {item:_0x2d5f48}of _0x3af771['view']['createRangeIn'](_0x4cb601))_0x2d5f48['is']('$textProxy')?_0x3f7212['consume'](_0x2d5f48['textNode'],{'name':!0x0}):_0x2d5f48['is']('element')&&_0x3f7212['consume'](_0x2d5f48,{'name':!0x0});return _0x1f0467['createElement']('footnoteRef',{'footnoteId':_0x5b0e8a});}}),_0x411f6['for']('dataDowncast')['elementToElement']({'model':{'name':'footnoteRef','attributes':['footnoteId','footnoteCounter']},'view':(_0x397331,{writer:_0x3ce3e1})=>D(_0x397331,_0x3ce3e1)}),_0x411f6['for']('editingDowncast')['elementToElement']({'model':{'name':'footnoteRef','attributes':['footnoteId','footnoteCounter']},'view':(_0x267479,{writer:_0x28aa42})=>{const _0x169c36=_0x267479['getAttribute']('footnoteCounter');return _0x26edb4(D(_0x267479,_0x28aa42),_0x28aa42,{'label':t('Footnote\x20%0.\x20Press\x20ENTER\x20to\x20jump\x20to\x20footnote\x20definition.',_0x169c36)});}});}['_defineDefinitionsConverters'](){const {editor:_0x1fc079}=this,{t:t}=_0x1fc079['locale'],{conversion:_0x6fbebf}=_0x1fc079;_0x6fbebf['for']('upcast')['elementToElement']({'view':{'name':'div','classes':'footnotes'},'model':'footnotesDefinitions'}),_0x6fbebf['for']('upcast')['add'](_0x18538c=>{_0x18538c['on']('element:ol',(_0x37120b,_0x5913c4,_0xd91da7)=>{const _0x16742c=_0x5913c4['viewItem'];if(!_0x16742c['hasClass']('footnotes-list')||!_0x5913c4['modelCursor']['parent']?.['is']('element','footnotesDefinitions'))return;if(!_0xd91da7['consumable']['consume'](_0x16742c,{'name':!0x0,'classes':'footnotes-list'}))return;const {modelRange:_0x410abe,modelCursor:_0xa963b4}=_0xd91da7['convertChildren'](_0x5913c4['viewItem'],_0x5913c4['modelCursor']);_0x5913c4['modelRange']=_0x410abe,_0x5913c4['modelCursor']=_0xa963b4;}),_0x18538c['on']('element:hr',(_0x177f15,_0x222b09,_0x4645a4)=>{const _0x12ab73=_0x222b09['viewItem'];_0x12ab73['hasClass']('footnotes-divider')&&_0x222b09['modelCursor']['parent']?.['is']('element','footnotesDefinitions')&&_0x4645a4['consumable']['consume'](_0x12ab73,{'name':!0x0,'classes':'footnotes-divider'});});}),_0x6fbebf['for']('dataDowncast')['elementToStructure']({'model':'footnotesDefinitions','view':(_0x2c342d,{writer:_0x72dacc})=>v(_0x72dacc)}),_0x6fbebf['for']('editingDowncast')['elementToStructure']({'model':'footnotesDefinitions','view':(_0x2e44d9,{writer:_0x547d55})=>{const _0x5ddc80=v(_0x547d55,{'data-footnotes-list-label':t('Footnotes')}),_0x43f8d9=_0x26edb4(_0x5ddc80,_0x547d55,{'hasSelectionHandle':!0x0,'label':t('Footnotes')});return _0x547d55['setCustomProperty']('footnotesDefinitions',!0x0,_0x43f8d9),_0x43f8d9;}});}['_defineDefinitionConverters'](){const {editor:_0x805b85}=this,{conversion:_0x1fab12,locale:_0x4a4cfc}=_0x805b85,_0x500f1c=_0x805b85['config']['get']('footnotes.multiBlock');_0x1fab12['for']('upcast')['add'](_0xd360e=>{_0xd360e['on']('element:li',(_0x33c55f,_0x576a73,_0x30bdf5)=>{const _0x2510bc=_0x576a73['viewItem'];if(!_0x2510bc['hasClass']('footnote-definition')||!_0x2510bc['getAttribute']('id'))return;const _0x33a2e3=_0x2510bc['parent'];if(!_0x33a2e3['is']('element','ol')||!_0x33a2e3['hasClass']('footnotes-list'))return;if(!_0x30bdf5['consumable']['test'](_0x2510bc,{'name':!0x0,'attributes':'id','classes':'footnote-definition'}))return;const _0x3a0cbf=_0x30bdf5['writer']['createElement']('footnoteDefinition',{'footnoteId':_0x2510bc['getAttribute']('id')});if(!_0x30bdf5['safeInsert'](_0x3a0cbf,_0x576a73['modelCursor']))return;_0x30bdf5['consumable']['consume'](_0x2510bc,{'name':!0x0,'attributes':'id','classes':'footnote-definition'});const _0x1e103d=Array['from'](_0x2510bc['getChildren']())['find'](_0x4a27e9=>_0x4a27e9['is']('element')&&_0x4a27e9['hasClass']('footnote-content'));for(const _0x153d53 of _0x2510bc['getChildren']())_0x153d53['is']('element')&&(_0x30bdf5['consumable']['consume'](_0x153d53,{'name':!0x0,'classes':'footnote-backlink','attributes':'href'}),_0x30bdf5['consumable']['consume'](_0x153d53,{'name':!0x0,'classes':'footnote-content'}));if(_0x1e103d){if(_0x500f1c)_0x30bdf5['convertChildren'](_0x1e103d,_0x3a0cbf);else{const _0x1bfc08=_0x30bdf5['writer']['createElement']('footnoteInlineContent');_0x30bdf5['writer']['insert'](_0x1bfc08,_0x3a0cbf),_0x30bdf5['convertChildren'](_0x1e103d,_0x1bfc08);}}_0x30bdf5['updateConversionResult'](_0x3a0cbf,_0x576a73);});}),_0x1fab12['for']('dataDowncast')['elementToStructure']({'model':{'name':'footnoteDefinition','attributes':['footnoteId']},'view':(_0x32d501,{writer:_0x2499f8})=>b(_0x32d501,_0x2499f8,_0x4a4cfc,{'dataPipeline':!0x0})}),_0x1fab12['for']('editingDowncast')['elementToStructure']({'model':{'name':'footnoteDefinition','attributes':['footnoteId']},'view':(_0x4e026e,{writer:_0xa1ad72})=>b(_0x4e026e,_0xa1ad72,_0x4a4cfc)});}['_defineBogusParagraphConverters'](){const {editor:_0x553cc6}=this,{conversion:_0x267b5d}=_0x553cc6;_0x553cc6['config']['get']('footnotes.multiBlock')?(_0x267b5d['for']('editingDowncast')['elementToElement']({'model':'paragraph','view':h(),'converterPriority':'high'}),_0x267b5d['for']('dataDowncast')['elementToElement']({'model':'paragraph','view':h({'dataPipeline':!0x0}),'converterPriority':'high'}),this['listenTo'](_0x553cc6['model']['document'],'change:data',()=>{!function(_0x21bdf7,_0x5b8e72){const _0x3fa5a9=_0x21bdf7['document']['differ'],_0x145177=new Set();for(const _0x48ceb3 of _0x3fa5a9['getChanges']()){const _0x1e9d7e='attribute'==_0x48ceb3['type']?_0x48ceb3['range']['start']['parent']:_0x48ceb3['position']['parent'];_0x1e9d7e['is']('element','footnoteDefinition')&&_0x145177['add'](_0x1e9d7e);}for(const _0x458996 of _0x145177['values']()){const _0x313255=Array['from'](_0x458996['getChildren']())['filter'](_0x285407=>g(_0x285407,_0x5b8e72['mapper']));for(const _0x46b3f8 of _0x313255)_0x5b8e72['reconvertItem'](_0x46b3f8);}}(_0x553cc6['model'],_0x553cc6['editing']);})):(_0x267b5d['for']('editingDowncast')['elementToElement']({'model':'footnoteInlineContent','view':h()}),_0x267b5d['for']('dataDowncast')['elementToElement']({'model':'footnoteInlineContent','view':(_0x412e98,{writer:_0x456181})=>{const _0x27fb8b=_0x456181['createContainerElement']('span');return _0x456181['setCustomProperty']('dataPipeline:transparentRendering',!0x0,_0x27fb8b),_0x27fb8b;}}));}['_defineKeyboardHandlers'](){const {editor:_0xa160fd}=this,{editing:_0x2ce21c,t:t}=_0xa160fd,_0x18250c=_0xa160fd['model']['document']['selection'];_0xa160fd['keystrokes']['set']('Ctrl+Alt+F','insertFootnote'),_0xa160fd['accessibility']['addKeystrokeInfos']({'keystrokes':[{'label':t('Insert\x20footnote'),'keystroke':'Ctrl+Alt+F'}]}),this['listenTo'](_0x2ce21c['view']['document'],'enter',(_0x2cf33f,_0x3b5fec)=>{const _0x36c1e6=function(_0x5ddd61){const _0x21f83e=_0x5ddd61['getSelectedElement']();if(_0x21f83e?.['is']('element','footnoteRef'))return _0x21f83e;return null;}(_0x18250c);if(_0x36c1e6){const _0x3ce939=_0x36c1e6['getAttribute']('footnoteId');this['_moveSelectionToFootnoteDefinition'](_0x3ce939),_0x3b5fec['preventDefault'](),_0x2cf33f['stop']();}},{'context':_0x3c1671});}['_defineClickHandlers'](){const {editor:_0x32c05f}=this,{editing:_0x18d06f}=_0x32c05f;_0x32c05f['editing']['view']['addObserver'](_0x351974),_0x32c05f['editing']['view']['addObserver'](_0x3ee15a);let _0x302e64=!0x1;this['listenTo'](_0x18d06f['view']['document'],'pointerdown',(_0xfe077,_0x1a56fc)=>{const {target:_0x3829bf}=_0x1a56fc,_0x39b964=_0x18d06f['view']['document']['selection'];_0x302e64=!!(_0x3829bf?.['is']('element','a')&&_0x3829bf['parent']?.['is']('element','sup')&&_0x3829bf['parent']['hasClass']('footnote'))&&_0x39b964['getSelectedElement']()===_0x3829bf['parent'];},{'priority':'high'}),this['listenTo'](_0x18d06f['view']['document'],'click',(_0x529d5f,_0x261629)=>{const {target:_0x313651}=_0x261629;if(!_0x313651?.['is']('element','a'))return;if(_0x313651['parent']?.['is']('element','sup')&&_0x313651['parent']['hasClass']('footnote')&&!_0x302e64)return void _0x261629['preventDefault']();let _0x456083=_0x313651['getAttribute']('href');if(!_0x456083?.['startsWith']('#'))return;_0x456083=_0x456083['slice'](0x1);let _0x117c0b=!0x1;(_0x456083['startsWith']('ref-')&&this['_moveSelectionToFootnoteReference'](_0x456083['slice'](0x4))||this['_moveSelectionToFootnoteDefinition'](_0x456083))&&(_0x117c0b=!0x0),_0x117c0b&&(_0x261629['preventDefault'](),_0x529d5f['stop']());},{'priority':'high','context':'$capture'});}}function h({dataPipeline:_0x98b63b}={}){return(_0x27f962,{writer:_0x23262c})=>{if(!p(_0x27f962))return null;if(!_0x98b63b)return _0x23262c['createContainerElement']('span',{'class':'ck-footnote-bogus-paragraph'});const _0x396437=_0x23262c['createContainerElement']('p');return _0x23262c['setCustomProperty']('dataPipeline:transparentRendering',!0x0,_0x396437),_0x396437;};}function p(_0x2c94c8){const {parent:_0x479225}=_0x2c94c8;if(!_0x479225?.['is']('element','footnoteDefinition'))return!0x1;if(0x1!=_0x479225['childCount'])return!0x1;for(const _0x589dd9 of _0x2c94c8['getAttributeKeys']())if(!_0x589dd9['startsWith']('selection:')&&'htmlEmptyBlock'!=_0x589dd9)return!0x1;return!0x0;}function g(_0x594f5a,_0x238258){if(!_0x594f5a['is']('element','paragraph'))return!0x1;const _0xbe7699=_0x238258['toViewElement'](_0x594f5a);return!!_0xbe7699&&p(_0x594f5a)!==_0xbe7699['is']('element','span');}export function isFootnotesDefinitionsWidget(_0xba09f5){return _0x3c1671(_0xba09f5)&&_0xba09f5['is']('containerElement')&&!!_0xba09f5['getCustomProperty']('footnotesDefinitions');}function v(_0x5f5b25,_0xef6986={}){const _0x9b5733=_0x5f5b25['createEmptyElement']('hr',{'class':'footnotes-divider'}),_0x58dbf9=_0x5f5b25['createContainerElement']('ol',{'class':'footnotes-list'},_0x5f5b25['createSlot']());return _0x5f5b25['createContainerElement']('div',{'class':'footnotes',..._0xef6986},[_0x9b5733,_0x58dbf9]);}function D(_0x3e99ef,_0x1a1112){const _0x587b0e=_0x3e99ef['getAttribute']('footnoteId'),_0x19d4b1=_0x3e99ef['getAttribute']('footnoteCounter'),_0x23c547=_0x1a1112['createUIElement']('a',{'href':'#'+_0x587b0e},function(_0x15684a){const _0x30f96e=this['toDomElement'](_0x15684a);return _0x30f96e['textContent']=_0x19d4b1,_0x30f96e;}),_0x308474=_0x1a1112['createContainerElement']('sup',{'id':'ref-'+_0x587b0e,'class':'footnote'},[_0x23c547]);return _0x308474['getFillerOffset']=()=>null,_0x308474;}function b(_0x44a902,_0x79fb0d,_0x2f24d1,{dataPipeline:_0x4ad34c}={}){const {t:t}=_0x2f24d1,_0x7f1d1e=_0x44a902['getAttribute']('footnoteId'),_0x447130=_0x79fb0d['createUIElement']('a',{'class':'footnote-backlink','href':'#ref-'+_0x7f1d1e},function(_0x1ed698){const _0x2c9f74=this['toDomElement'](_0x1ed698);return _0x2c9f74['innerText']='^',_0x2c9f74;}),_0xdc0067=_0x4ad34c?_0x79fb0d['createContainerElement']('div',{'class':'footnote-content'}):_0xde846a(_0x79fb0d['createEditableElement']('div',{'class':'footnote-content'}),_0x79fb0d,{'label':t('Footnote\x20content.')});return _0x79fb0d['insert'](_0x79fb0d['createPositionAt'](_0xdc0067,0x0),_0x79fb0d['createSlot']()),_0x79fb0d['createContainerElement']('li',{'class':'footnote-definition','id':_0x7f1d1e},[_0x447130,_0xdc0067]);}