@ckeditor/ckeditor5-footnotes 0.0.0-nightly-20251102.0 → 0.0.0-nightly-20251103.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/build/footnotes.js +1 -1
- package/dist/index.js +1 -1
- package/package.json +9 -9
- package/src/footnotesediting.js +1 -1
package/build/footnotes.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* @license Copyright (c) 2003-2025, CKSource Holding sp. z o.o. All rights reserved.
|
|
3
3
|
* For licensing, see LICENSE.md.
|
|
4
|
-
*/(()=>{var t={14:(t,e,n)=>{"use strict";n.d(e,{A:()=>a});var o=n(453),i=n.n(o),s=n(374),r=n.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-content .footnote-content ul{list-style-type:disc}.ck-content .footnote-content ul ul{list-style-type:circle}.ck-content .footnote-content ul ul ul,.ck-content .footnote-content ul ul ul ul{list-style-type:square}.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,n){var o=function(t){if(void 0===e[t]){var n=document.querySelector(t);if(window.HTMLIFrameElement&&n instanceof window.HTMLIFrameElement)try{n=n.contentDocument.head}catch(t){n=null}e[t]=n}return e[t]}(t);if(!o)throw new Error("Couldn't find a style target. This probably means that the value for the 'insert' parameter is invalid.");o.appendChild(n)}},311:(t,e,n)=>{t.exports=n(237)("./src/ui.js")},331:(t,e,n)=>{t.exports=n(237)("./src/clipboard.js")},355:(t,e,n)=>{t.exports=n(237)("./src/icons.js")},374:t=>{"use strict";t.exports=function(t){var e=[];return e.toString=function(){return this.map(function(e){var n="",o=void 0!==e[5];return e[4]&&(n+="@supports (".concat(e[4],") {")),e[2]&&(n+="@media ".concat(e[2]," {")),o&&(n+="@layer".concat(e[5].length>0?" ".concat(e[5]):""," {")),n+=t(e),o&&(n+="}"),e[2]&&(n+="}"),e[4]&&(n+="}"),n}).join("")},e.i=function(t,n,o,i,s){"string"==typeof t&&(t=[[null,t,void 0]]);var r={};if(o)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]);o&&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),n&&(u[2]?(u[1]="@media ".concat(u[2]," {").concat(u[1],"}"),u[2]=n):u[2]=n),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(n){t.setAttribute(n,e[n])})}},450:t=>{"use strict";var e=[];function n(t){for(var n=-1,o=0;o<e.length;o++)if(e[o].identifier===t){n=o;break}return n}function o(t,o){for(var s={},r=[],a=0;a<t.length;a++){var c=t[a],l=o.base?c[0]+o.base:c[0],u=s[l]||0,f="".concat(l," ").concat(u);s[l]=u+1;var d=n(f),p={css:c[1],media:c[2],sourceMap:c[3],supports:c[4],layer:c[5]};if(-1!==d)e[d].references++,e[d].updater(p);else{var h=i(p,o);o.byIndex=a,e.splice(a,0,{identifier:f,updater:h,references:1})}r.push(f)}return r}function i(t,e){var n=e.domAPI(e);n.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;n.update(t=e)}else n.remove()}}t.exports=function(t,i){var s=o(t=t||[],i=i||{});return function(t){t=t||[];for(var r=0;r<s.length;r++){var a=n(s[r]);e[a].references--}for(var c=o(t,i),l=0;l<s.length;l++){var u=n(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,n)=>{t.exports=n(237)("./src/utils.js")},774:t=>{"use strict";var e,n=(e=[],function(t,n){return e[t]=n,e.filter(Boolean).join("\n")});function o(t,e,o,i){var s;if(o)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=n(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++,n=i.singleton||(i.singleton=t.insertStyleElement(t));return{update:function(t){o(n,e,!1,t)},remove:function(t){o(n,e,!0,t)}}}},782:(t,e,n)=>{t.exports=n(237)("./src/core.js")},783:(t,e,n)=>{t.exports=n(237)("./src/engine.js")},901:(t,e,n)=>{t.exports=n(237)("./src/widget.js")},945:(t,e,n)=>{"use strict";n.d(e,{A:()=>a});var o=n(453),i=n.n(o),s=n(374),r=n.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 n(o){var i=e[o];if(void 0!==i)return i.exports;var s=e[o]={id:o,exports:{}};return t[o](s,s.exports,n),s.exports}n.n=t=>{var e=t&&t.__esModule?()=>t.default:()=>t;return n.d(e,{a:e}),e},n.d=(t,e)=>{for(var o in e)n.o(e,o)&&!n.o(t,o)&&Object.defineProperty(t,o,{enumerable:!0,get:e[o]})},n.o=(t,e)=>Object.prototype.hasOwnProperty.call(t,e),n.r=t=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})};var o={};(()=>{"use strict";n.r(o),n.d(o,{Footnotes:()=>Z,FootnotesClipboard:()=>D,FootnotesEditing:()=>v,FootnotesProperties:()=>Et,FootnotesPropertiesEditing:()=>pt,FootnotesPropertiesUI:()=>kt,FootnotesStartCommand:()=>ut,FootnotesStyleCommand:()=>st,FootnotesTracker:()=>f,FootnotesUI:()=>q,InsertFootnoteCommand:()=>b});var t=n(782),e=n(901),i=n(584),s=n(783);function r(){const t=["getElementKey","getChanges","692643WJCgnE","$graveyard","from","getItems","7154376HJnAZV","_model","3591087YPkyTt","add","elementName","rootName","2309255JGTnhb","attributes","1388212AGsqWL","18TTTbIG","insert","$text","2CXpNqy","reset","values","clear","has","push","slice","type","_getElementKey","remove","_trackedElements","4129854DcpLll","3434120mKukkW","8RabSPP","root","delete","length","position","get","createRangeOn","set","element","nodeAfter","_elementName","flat","name"];return(r=function(){return t})()}function a(t,e){const n=r();return(a=function(t,e){return n[t-=357]})(t,e)}const c=a;!function(t){const e=a,n=t();for(;;)try{if(730622===-parseInt(e(363))/1+parseInt(e(379))/2*(parseInt(e(369))/3)+-parseInt(e(392))/4*(-parseInt(e(373))/5)+-parseInt(e(390))/6+parseInt(e(375))/7+-parseInt(e(367))/8+-parseInt(e(376))/9*(-parseInt(e(391))/10))break;n.push(n.shift())}catch(t){n.push(n.shift())}}(r);class l{[c(368)];[c(358)];[c(387)];[c(389)]=new Map;constructor(t,e){const n=c;this[n(368)]=t,this[n(358)]=e[n(371)],this[n(387)]=e[n(361)]}[c(380)](){const t=c;this[t(389)][t(382)]()}[c(362)](t){const e=c,n=new Set,o=new Map;for(const i of t){if(e(377)===i[e(386)]&&e(378)!==i[e(360)]&&i[e(396)][e(357)]){const t=this[e(368)][e(398)](i[e(396)][e(357)]);for(const n of t[e(366)]()){if(!n.is(e(400),this[e(358)]))continue;const t=this[e(387)](n);o[e(383)](t)||o[e(399)](t,[]),o[e(397)](t)[e(384)](n)}}if(e(388)===i[e(386)]&&i[e(360)]===this[e(358)]){const t=this[e(387)]({getAttribute:t=>i[e(374)][e(397)](t)});n[e(370)](t)}}for(const[t,o]of this[e(389)])e(364)===o[e(393)][e(372)]&&n[e(370)](t);for(const t of n)this[e(389)][e(394)](t);for(const[t,n]of o)this[e(389)][e(399)](t,n[n[e(395)]-1]);const i=new Set;for(const[t,s]of o)n[e(383)](t)&&(i[e(370)](s[0]),s[e(395)]>1?o[e(399)](t,s[e(385)](1)):o[e(394)](t),n[e(394)](t));return{removed:Array[e(365)](n),inserted:Array[e(365)](o[e(381)]())[e(359)](),moved:Array[e(365)](i)}}}const u=d;!function(t){const e=d,n=t();for(;;)try{if(194312===parseInt(e(192))/1+-parseInt(e(155))/2*(parseInt(e(182))/3)+-parseInt(e(173))/4*(parseInt(e(244))/5)+parseInt(e(236))/6*(parseInt(e(200))/7)+parseInt(e(193))/8*(parseInt(e(186))/9)+parseInt(e(156))/10*(-parseInt(e(157))/11)+-parseInt(e(163))/12*(-parseInt(e(215))/13))break;n.push(n.shift())}catch(t){n.push(n.shift())}}(p);class f extends t.Plugin{[u(202)]=[];[u(188)]=null;[u(203)]=null;[u(196)];[u(237)];[u(241)];static get[u(201)](){return u(213)}static get[u(161)](){return!0}static get[u(191)](){return!0}constructor(t){const e=u;super(t),this[e(196)]=new l(this[e(209)][e(190)],{elementName:e(175),getElementKey:()=>e(167)}),this[e(237)]=new l(this[e(209)][e(190)],{elementName:e(229),getElementKey:t=>t[e(214)](e(242))}),this[e(241)]=new l(this[e(209)][e(190)],{elementName:e(176),getElementKey:t=>t[e(214)](e(242))})}[u(224)](){const t=u,{editor:e}=this,{model:n,data:o}=e;n[t(185)][t(181)](e=>{const o=t,i=n[o(185)][o(243)][o(183)]();let s=!1;return this[o(147)](e,i)&&(s=!0),this[o(234)](e,i)&&(s=!0),this[o(223)](e,i)&&(s=!0),this[o(178)](e)&&(s=!0),this[o(144)](e)&&(s=!0),this[o(205)](e)&&(s=!0),s}),this[t(174)](n[t(185)],t(158),()=>{const e=t;n[e(227)]({isUndoable:!1},t=>{this[e(246)](t)})},{priority:t(159)}),this[t(174)](o,t(228),()=>{const e=t;this[e(202)]=[],this[e(196)][e(206)](),this[e(237)][e(206)](),this[e(241)][e(206)]()},{priority:t(189)})}[u(225)](){return this[u(188)]}[u(169)](t){const e=u;return this[e(202)][e(166)](e=>e.id===t)||null}[u(204)](){const t=u;return Array[t(195)](this[t(202)])}[u(247)](){return this[u(203)]}[u(146)](t){this[u(203)]=t}[u(207)](t,e=0){const n=u;let o=!1;for(let i=e;i<this[n(202)][n(154)];i++)this[n(198)](t,i)&&(o=!0);return o}[u(197)](t,e){const n=u,o=t[n(240)](n(175),{});return t[n(211)](o,e),this[n(188)]=o,o}[u(246)](t){const e=u;if(!this[e(202)][e(154)]||this[e(188)])return;const n=this[e(202)][0][e(152)][e(231)],o=this[e(197)](t,n);for(const n of this[e(202)])n[e(180)][e(150)]||t[e(216)](n[e(180)],o,e(184));this[e(207)](t)}[u(147)](t,e){const n=u;let o=!1;const{inserted:i,removed:s,moved:r}=this[n(196)][n(183)](e);if(r[n(154)]&&(this[n(188)]=r[0]),i[n(154)])if(i[n(154)]>1||this[n(188)]&&i[n(210)](t=>t!==this[n(188)])){const e=t[n(240)](n(175),{}),s=[];this[n(188)]&&s[n(221)](this[n(188)]),s[n(221)](...i),t[n(216)](e,s[0],n(149));for(const o of s)t[n(177)](t[n(222)](o),t[n(245)](e,n(184))),t[n(217)](o);this[n(188)]=e,this[n(207)](t),o=!0}else this[n(188)]=i[0];if(s[n(154)]&&n(220)===this[n(188)]?.[n(231)][n(212)]){for(const e of this[n(202)])t[n(217)](e[n(152)]),o=!0;this[n(202)]=[],this[n(188)]=null}return o}[u(234)](t,e){const n=u;let o=!1;const i=this[n(209)][n(187)][n(153)](n(162)),{inserted:s,moved:r}=this[n(241)][n(183)](e);for(const e of[...r,...s]){const s=e[n(214)](n(242)),r=this[n(169)](s);r&&(r[n(180)]=e),h(t,i,e)&&(o=!0)}return o}[u(223)](t,e){const n=u;let o=!1;const{removed:i,inserted:s,moved:r}=this[n(237)][n(183)](e);for(const e of i)this[n(239)](t,e)&&(o=!0);for(const e of s)this[n(168)](t,e)&&(o=!0);for(const e of r)this[n(238)](t,e)&&(o=!0);return o}[u(144)](t){const e=u;if(!this[e(188)])return!1;let n=!1;if(this[e(188)][e(148)]!==this[e(202)][e(154)]){const o=[];for(const t of this[e(188)][e(171)]()){const i=t[e(214)](e(242));this[e(169)](i)||(o[e(218)](t),n=!0)}for(const n of o)t[e(217)](n)}const o=new Set,i=[];for(const t of this[e(188)][e(171)]()){const s=t[e(214)](e(242));o[e(164)](s)?(i[e(218)](t),n=!0):o[e(219)](s)}for(const n of i)t[e(217)](n);return this[e(188)][e(148)]||(t[e(217)](this[e(188)]),this[e(188)]=null,n=!0),n}[u(168)](t,e){const n=u;if(this[n(202)][n(166)](t=>t[n(152)]===e))return!1;let o=!1;const i=e[n(214)](n(242)),s=this[n(202)][n(151)](t=>t.id===i);-1!==s&&(t[n(217)](this[n(202)][s][n(152)]),this[n(202)][n(145)](s,1),o=!0);let r=this[n(188)]?function(t,e){const o=n;for(const n of t[o(171)]())if(n[o(214)](o(242))===e)return n;return null}(this[n(188)],i):null;r||(r=t[n(240)](n(176),{footnoteId:i}),this[n(188)]&&(t[n(216)](r,this[n(188)],n(184)),o=!0));const a={id:i,reference:e,definition:r},c=m(this[n(209)][n(190)],this[n(202)],e);this[n(202)][n(145)](c,0,a);let l=c;return-1!==s&&(l=Math[n(194)](c,s)),this[n(207)](t,l)&&(o=!0),o}[u(239)](t,e){const n=u,o=this[n(202)][n(151)](t=>t.id===e);if(-1===o)return!1;let i=!1;const s=this[n(202)][o];return n(220)!==s[n(180)][n(231)][n(212)]&&(t[n(217)](s[n(180)]),i=!0),this[n(202)][n(145)](o,1),this[n(207)](t,o)&&(i=!0),i}[u(238)](t,e){const n=u,o=e[n(214)](n(242)),i=this[n(202)][n(151)](t=>t.id===o),s=this[n(202)][i];let r=!1;s[n(152)]=e,this[n(202)][n(145)](i,1);const a=m(this[n(209)][n(190)],this[n(202)],e);return this[n(202)][n(145)](a,0,s),this[n(207)](t,Math[n(194)](i,a))&&(r=!0),r}[u(198)](t,e){const n=u;if(!this[n(188)])return!1;const o=this[n(202)][e];let i;return i=this[n(203)]?this[n(203)]({footnote:o,container:this[n(188)],digits:String(this[n(202)][n(154)])[n(154)],value:e+1}):String(e+1),o[n(152)][n(214)](n(232))!=i&&(t[n(170)](n(232),i,o[n(152)]),!0)}[u(205)](t){const e=u;if(!this[e(188)]||this[e(202)][e(154)]<2)return!1;if(function(t,n){const o=e;if(t[o(154)]!==n[o(154)])return!1;for(let e=0;e<t[o(154)];e++)if(t[e]!==n[e])return!1;return!0}(this[e(202)][e(160)](t=>t.id),Array[e(195)](this[e(188)][e(171)]())[e(160)](t=>t[e(214)](e(242)))))return!1;let n=!1;for(let o=0;o<this[e(202)][e(154)];o++){const i=this[e(202)][o],s=t[e(235)](i[e(180)]),r=t[e(245)](this[e(188)],o);s[e(165)](r)||(t[e(177)](t[e(233)](i[e(180)]),r),n=!0)}return n}[u(178)](t){const e=u;if(!this[e(202)][e(154)])return!1;const{model:n}=this[e(209)];let o=!1;for(let i=0;i<this[e(202)][e(154)]-1;i++){const s=this[e(202)][i],r=this[e(202)][i+1],a=n[e(235)](s[e(152)]),c=n[e(235)](r[e(152)]);e(226)===a[e(179)](c)&&(this[e(238)](t,s[e(152)]),i=-1,o=!0)}return o}}function d(t,e){const n=p();return(d=function(t,e){return n[t-=144]})(t,e)}function p(){const t=["createPositionBefore","33240tSMOMG","_footnoteRefsTracker","_handleMovedFootnoteReference","_handleRemoveFootnoteReferenceById","createElement","_footnoteDefsTracker","footnoteId","differ","353315jHoZAg","createPositionAt","_ensureFootnotesDefinitionsContainerExists","getFootnotesFormatter","_handleFootnotesDefinitionsObjectSync","splice","setFootnoteFormatter","_handleFootnotesDefinitionsObjectChanges","childCount","before","parent","findIndex","reference","get","length","214NiugWL","10BOeymQ","1722655OliCjf","change:data","low","map","isOfficialPlugin","footnotes.multiBlock","59808thasXU","has","isEqual","find","singleton","_handleInsertedFootnoteReference","getFootnote","setAttribute","getChildren","paragraph","8rbBgCB","listenTo","footnotesDefinitions","footnoteDefinition","move","_ensureFootnotesReferencesHaveProperOrder","compareWith","definition","registerPostFixer","10239rWWfYd","getChanges","end","document","27wlWhUE","config","_footnotesDefinitions","high","model","isPremiumPlugin","198461kkPUGk","126904aJwWne","min","from","_footnoteDefsContainerTracker","_insertEmptyFootnotesDefinitionsContainer","_updateFootnoteRefCounter","footnoteInlineContent","42lYYmRF","pluginName","_footnotes","_footnoteFormatter","getFootnotes","_sortFootnoteDefinitions","reset","_updateFootnotesCounters","getRootNames","editor","some","append","rootName","FootnotesTracker","getAttribute","1508xuCHey","insert","remove","unshift","add","$graveyard","push","createRangeIn","_handleFootnoteReferencesChanges","init","getFootnotesDefinitionsObjectElement","after","enqueueChange","set","footnoteRef","indexOf","root","footnoteCounter","createRangeOn","_handleFootnoteDefinitionsChanges"];return(p=function(){return t})()}function h(t,e,n){const o=u;if(n[o(148)])return!1;const i=o(e?172:199);return t[o(216)](t[o(240)](i),n),!0}function m(t,e,n){const o=u;if(0===e[o(154)])return 0;const i=t[o(235)](n);for(let n=0;n<e[o(154)];n++){const s=e[n],r=t[o(235)](s[o(152)]);if(o(149)===i[o(179)](r))return n}const s=n[o(231)];let r=-1;for(let t=e[o(154)]-1;t>=0;t--)if(e[t][o(152)][o(231)]===s){r=t;break}if(-1!==r)return r+1;const a=t[o(185)][o(208)](),c=a[o(230)](s[o(212)]),l=a[c+1];if(l)for(let t=0;t<e[o(154)];t++)if(e[t][o(152)][o(231)][o(212)]===l)return t;return e[o(154)]}const g=y;function w(){const t=["model","length","293652Nmeenp","get","insert-footnote-command-executed-with-invalid-id","string","editor","document","7lfhyzL","_getPositionToInsertFootnote","isObject","execute","getFirstRange","getItems","selection","checkChild","end","19920wPfupR","isEnabled","_moveSelectionToFootnoteDefinition","1134ymvITt","1106700YGUslL","75376lKtZrR","plugins","test","refresh","12KhhpbN","change","59397sUDaiC","FootnotesEditing","1882952wauUit","footnoteId","footnoteRef","isBlock","insertObject","76438JgQjLA","createElement"];return(w=function(){return t})()}function y(t,e){const n=w();return(y=function(t,e){return n[t-=356]})(t,e)}!function(t){const e=y,n=t();for(;;)try{if(126821===parseInt(e(364))/1+-parseInt(e(392))/2*(parseInt(e(357))/3)+-parseInt(e(388))/4+parseInt(e(387))/5+-parseInt(e(368))/6+-parseInt(e(374))/7*(parseInt(e(359))/8)+parseInt(e(386))/9*(parseInt(e(383))/10))break;n.push(n.shift())}catch(t){n.push(n.shift())}}(w);class b extends t.Command{[g(391)](){const t=g,e=this[t(372)][t(366)][t(373)][t(380)],n=this[t(375)](e);this[t(384)]=!!n}[g(377)](t){const e=g,{editor:n}=this,{model:o}=n,{selection:s}=o[e(373)],r=this[e(375)](s);if(!r)return;const a=n[e(389)][e(369)](e(358)),c=t?.[e(360)]??(0,i.uid)();!function(t){const n=e;return n(371)==typeof t&&t[n(367)]>0&&!/\s/[n(390)](t)&&!/^\d/[n(390)](t)}(c)?(0,i.logWarning)(e(370)):(o[e(356)](t=>{const n=e,i=t[n(365)](n(361),{footnoteId:c});o[n(363)](i,r,null)}),a[e(385)](c))}[g(375)](t){const e=g,{model:n}=this[e(372)],{schema:o}=n,i=t[e(378)]();for(const t of i[e(379)]())if(o[e(362)](t)||o[e(376)](t))return null;const s=i[e(382)];return o[e(381)](s,e(361))?s:null}}class v extends t.Plugin{static get pluginName(){return"FootnotesEditing"}static get requires(){return[f]}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]),n=window[m([68,97,116,101])][m([110,111,119])](),o=t[m([101,100,105,116,111,114])],s=new(window[m([80,114,111,109,105,115,101])])(t=>{o[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=o[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;o[m([109,111,100,101,108])][m([111,110])](m([97,112,112,108,121,79,112,101,114,97,116,105,111,110]),(n,o)=>{o[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(),n[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 n(t){for(let n=0;n<t[m([108,101,110,103,116,104])];n++){const o=t[m([99,104,97,114,67,111,100,101,65,116])](n);e=(e<<5)+e+o,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,o])=>{n(e),t(o)}):n(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 p(t){return t[m([115,112,108,105,116])]("")[m([114,101,118,101,114,115,101])]()[m([106,111,105,110])]("")}function h(){}function m(t){return t.map(t=>String.fromCharCode(t)).join("")}!function(t){const n=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 n=m([117]);for(let o=0;o<t[m([108,101,110,103,116,104])];o+=2){let i=window[m([112,97,114,115,101,73,110,116])](t[m([115,117,98,115,116,114,105,110,103])](o,o+2));i>=e[m([108,101,110,103,116,104])]&&(i-=e[m([108,101,110,103,116,104])]),n+=e[i]}return n}();o[n]=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,o[m([109,111,100,101,108])][m([99,104,97,110,103,101])]=h,o[m([109,111,100,101,108])][m([101,110,113,117,101,117,101,67,104,97,110,103,101])]=h,o[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,h=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&&n()?e:null;function n(){const t=e[m([106,116,105])],n=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),o={...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 o[m([118,99])],f(o)==n}}}(),t?(t[m([117,115,97,103,101,69,110,100,112,111,105,110,116])]&&(h=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(),o[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 h(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(o){a(o)[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(n-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)),o=p(d(window[m([77,97,116,104])][m([99,101,105,108])](n/i)));window[m([108,111,99,97,108,83,116,111,114,97,103,101])][m([115,101,116,73,116,101,109])](e,o)}function r(){const e=m([108,108,99,116,45])+d(f(t)),n=window[m([108,111,99,97,108,83,116,111,114,97,103,101])][m([103,101,116,73,116,101,109])](e);return n?window[m([112,97,114,115,101,73,110,116])](p(n),16)*i:null}function a(t){return new(window[m([80,114,111,109,105,115,101])])((e,n)=>{t[m([116,104,101,110])](e,n),window[m([115,101,116,84,105,109,101,111,117,116])](n,12e4)})}}o[m([111,110])](m([95,115,101,110,100,85,115,97,103,101,82,101,113,117,101,115,116]),(e,n)=>{if(n[0]!=t)return c(m([85,115,97,103,101,76,105,109,105,116]));n[1]={...n[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])}),o[m([111,110])](m([95,115,101,110,100,85,115,97,103,101,82,101,113,117,101,115,116]),t=>{h(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 o[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(){o[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 o=a[m([115,112,108,105,116])](m([46])),[i,s,r]=o;return e(i),await n(i,s,r),t}catch{return!1}function e(e){const n=l(e);n&&n[m([97,108,103])]==m([69,83,50,53,54])||(t=!1)}async function n(e,n,o){const i=window[m([85,105,110,116,56,65,114,114,97,121])][m([102,114,111,109])](u(o),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])+n),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])])?n/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:n}=new URL(window[m([108,111,99,97,116,105,111,110])].href);if(e[m([105,110,99,108,117,100,101,115])](n))return!0;const o=n[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])]<=o[m([108,101,110,103,116,104])])[m([109,97,112])](t=>Array(o[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=>o[m([101,118,101,114,121])]((e,n)=>t[n]===e||t[n]===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&&h?new(window[m([80,114,111,109,105,115,101])])((t,n)=>{e[m([116,104,101,110])](t,n),h[m([116,104,101,110])](e=>{e!=m([86,97,108,105,100])&&t(e)},n)}):e||h||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:n,model:o}=this.editor,i=e.get(f).getFootnote(t);return!!i&&(o.change(t=>{t.setSelection(t.createPositionAt(i.definition,"end"))}),n.view.scrollToTheSelection(),!0)}_moveSelectionToFootnoteReference(t){const{plugins:e,editing:n,model:o}=this.editor,i=e.get(f).getFootnote(t);return!!i&&(o.change(t=>{t.setSelection(i.reference,"on")}),n.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:n,editing:o}=t,{t:i}=t.locale;n.for("upcast").elementToElement({view:{name:"sup",classes:"footnote"},model:(t,{writer:e,consumable:n})=>{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;n.consume(i,{name:!0,attributes:["href"]});for(const{item:t}of o.view.createRangeIn(i))t.is("$textProxy")?n.consume(t.textNode,{name:!0}):t.is("element")&&n.consume(t,{name:!0});return e.createElement("footnoteRef",{footnoteId:r})}}),n.for("dataDowncast").elementToElement({model:{name:"footnoteRef",attributes:["footnoteId","footnoteCounter"]},view:(t,{writer:e})=>E(t,e)}),n.for("editingDowncast").elementToElement({model:{name:"footnoteRef",attributes:["footnoteId","footnoteCounter"]},view:(t,{writer:n})=>{const o=t.getAttribute("footnoteCounter");return(0,e.toWidget)(E(t,n),n,{label:i("Footnote %0. Press ENTER to jump to footnote definition.",o)})}})}_defineDefinitionsConverters(){const{editor:t}=this,{t:n}=t.locale,{conversion:o}=t;o.for("upcast").elementToElement({view:{name:"div",classes:"footnotes"},model:"footnotesDefinitions"}),o.for("upcast").add(t=>{t.on("element:ol",(t,e,n)=>{const o=e.viewItem;if(!o.hasClass("footnotes-list")||!e.modelCursor.parent?.is("element","footnotesDefinitions"))return;if(!n.consumable.consume(o,{name:!0,classes:"footnotes-list"}))return;const{modelRange:i,modelCursor:s}=n.convertChildren(e.viewItem,e.modelCursor);e.modelRange=i,e.modelCursor=s}),t.on("element:hr",(t,e,n)=>{const o=e.viewItem;o.hasClass("footnotes-divider")&&e.modelCursor.parent?.is("element","footnotesDefinitions")&&n.consumable.consume(o,{name:!0,classes:"footnotes-divider"})})}),o.for("dataDowncast").elementToStructure({model:"footnotesDefinitions",view:(t,{writer:e})=>x(e)}),o.for("editingDowncast").elementToStructure({model:"footnotesDefinitions",view:(t,{writer:o})=>{const i=x(o,{"data-footnotes-list-label":n("Footnotes")}),s=(0,e.toWidget)(i,o,{hasSelectionHandle:!0,label:n("Footnotes")});return o.setCustomProperty("footnotesDefinitions",!0,s),s}})}_defineDefinitionConverters(){const{editor:t}=this,{conversion:e,locale:n}=t,o=t.config.get("footnotes.multiBlock");e.for("upcast").add(t=>{t.on("element:li",(t,e,n)=>{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(!n.consumable.test(i,{name:!0,attributes:"id",classes:"footnote-definition"}))return;const r=n.writer.createElement("footnoteDefinition",{footnoteId:i.getAttribute("id")});if(!n.safeInsert(r,e.modelCursor))return;n.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")&&(n.consumable.consume(t,{name:!0,classes:"footnote-backlink",attributes:"href"}),n.consumable.consume(t,{name:!0,classes:"footnote-content"}));if(a)if(o)n.convertChildren(a,r);else{const t=n.writer.createElement("footnoteInlineContent");n.writer.insert(t,r),n.convertChildren(a,t)}n.updateConversionResult(r,e)})}),e.for("dataDowncast").elementToStructure({model:{name:"footnoteDefinition",attributes:["footnoteId"]},view:(t,{writer:e})=>P(t,e,n,{dataPipeline:!0})}),e.for("editingDowncast").elementToStructure({model:{name:"footnoteDefinition",attributes:["footnoteId"]},view:(t,{writer:e})=>P(t,e,n)})}_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 n=t.document.differ,o=new Set;for(const t of n.getChanges()){const e="attribute"==t.type?t.range.start.parent:t.position.parent;e.is("element","footnoteDefinition")&&o.add(e)}for(const t of o.values()){const n=Array.from(t.getChildren()).filter(t=>C(t,e.mapper));for(const t of n)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 n=e.createContainerElement("span");return e.setCustomProperty("dataPipeline:transparentRendering",!0,n),n}}))}_defineKeyboardHandlers(){const{editor:t}=this,{editing:n,t:o}=t,i=t.model.document.selection;t.keystrokes.set("CTRL+Shift+D","insertFootnote"),t.accessibility.addKeystrokeInfos({keystrokes:[{label:o("Insert footnote"),keystroke:"Ctrl+Shift+D"}]}),this.listenTo(n.view.document,"enter",(t,e)=>{const n=function(t){const e=t.getSelectedElement();return e?.is("element","footnoteRef")?e:null}(i);if(n){const o=n.getAttribute("footnoteId");this._moveSelectionToFootnoteDefinition(o),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 n=!1;this.listenTo(e.view.document,"pointerdown",(t,o)=>{const{target:i}=o,s=e.view.document.selection;n=!!(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:o}=e;if(!o.is("element","a"))return;if(o.parent?.is("element","sup")&&o.parent.hasClass("footnote")&&!n)return void e.preventDefault();let i=o.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:n})=>{if(!k(e))return null;if(!t)return n.createContainerElement("span",{class:"ck-footnote-bogus-paragraph"});const o=n.createContainerElement("p");return n.setCustomProperty("dataPipeline:transparentRendering",!0,o),o}}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 n=e.toViewElement(t);return!!n&&k(t)!==n.is("element","span")}function F(t){return(0,e.isWidget)(t)&&t.is("containerElement")&&!!t.getCustomProperty("footnotesDefinitions")}function x(t,e={}){const n=t.createEmptyElement("hr",{class:"footnotes-divider"}),o=t.createContainerElement("ol",{class:"footnotes-list"},t.createSlot());return t.createContainerElement("div",{class:"footnotes",...e},[n,o])}function E(t,e){const n=t.getAttribute("footnoteId"),o=t.getAttribute("footnoteCounter"),i=e.createUIElement("a",{href:"#"+n},function(t){const e=this.toDomElement(t);return e.textContent=o,e}),s=e.createContainerElement("sup",{id:"ref-"+n,class:"footnote"},[i]);return s.getFillerOffset=()=>null,s}function P(t,n,o,{dataPipeline:i}={}){const{t:s}=o,r=t.getAttribute("footnoteId"),a=n.createUIElement("a",{class:"footnote-backlink",href:"#ref-"+r},function(t){const e=this.toDomElement(t);return e.innerText="^",e}),c=i?n.createContainerElement("div",{class:"footnote-content"}):(0,e.toWidgetEditable)(n.createEditableElement("div",{class:"footnote-content"}),n,{label:s("Footnote content.")});return n.insert(n.createPositionAt(c,0),n.createSlot()),n.createContainerElement("li",{class:"footnote-definition",id:r},[a,c])}var S=n(331);function L(){const t=["footnoteRef","change","application/ckeditor5-footnotes","init","250YPraqM","add","pluginName","toModel","dataTransfer","definition","getFootnote","create","setAttribute","_insertEmptyFootnotesDefinitionsContainer","method","_defineClipboardIntegration","selection","reduce","push","getFootnotesDefinitionsObjectElement","177133RbLFBy","toView","insert","entries","541509IeKKyu","drop","1788708GElHLs","getData","find","content","setData","append","7QXIGJe","isOfficialPlugin","footnoteDefinition","sourceEditorId","from","createElement","isPremiumPlugin","footnoteId","18ZFpxkE","getAttribute","toData","2lzvIsp","htmlProcessor","footnotesDefinitions","outputTransformation","root","createRangeIn","length","getFootnotes","get","parse","stringify","element","clipboardInput","remove","document","_handleCopyFootnotesDefinitions","editing","data","editor","end","3180528pKhVDC","contentInsertion","getFirstRange","FootnotesClipboard","5sGLTqu","1308780MmnkBY","1135388vvRbay","requires","_handlePasteFootnotesDefinitions","listenTo","17490648GMgCou"];return(L=function(){return t})()}const _=A;function A(t,e){const n=L();return(A=function(t,e){return n[t-=352]})(t,e)}!function(t){const e=A,n=t();for(;;)try{if(707097===parseInt(e(395))/1*(parseInt(e(414))/2)+-parseInt(e(397))/3+-parseInt(e(366))/4*(-parseInt(e(364))/5)+-parseInt(e(365))/6*(-parseInt(e(403))/7)+parseInt(e(360))/8*(-parseInt(e(411))/9)+-parseInt(e(375))/10*(parseInt(e(391))/11)+parseInt(e(370))/12)break;n.push(n.shift())}catch(t){n.push(n.shift())}}(L);class D extends t.Plugin{static get[_(377)](){return _(363)}static get[_(367)](){return[v,S.ClipboardPipeline]}static get[_(404)](){return!0}static get[_(409)](){return!0}[_(374)](){this[_(386)]()}[_(386)](){const t=_;this[t(355)](),this[t(368)]()}[_(355)](){const t=_,{editor:e}=this,{plugins:n,model:o}=e,i=n[t(422)](S.ClipboardPipeline),s=n[t(422)](f);this[t(369)](i,t(417),(n,i)=>{const r=t,a=function(t,e){const n=A,o=new Set;for(const{item:i}of t[n(419)](e))i.is(n(425),n(371))&&o[n(376)](i[n(412)](n(410)));return Array[n(407)](o)}(o,i[r(400)]);if(!a[r(420)])return;const c=s[r(421)](),l=a[r(388)]((t,n)=>{const o=r,i=c[o(399)](t=>t.id===n);if(i){const n=e[o(357)][o(392)](i[o(380)],{isClipboardPipeline:!0}),s=e[o(357)][o(415)][o(413)](n);t[i.id]=s}return t},Object[r(382)](null));i[r(379)][r(401)](r(373),JSON[r(424)](l))})}[_(368)](){const t=_,{editor:e}=this,{model:n,plugins:o}=e,{view:s}=e[t(356)],r=o[t(422)](S.ClipboardPipeline),a=o[t(422)](f);let c=null;this[t(369)](s[t(354)],t(352),(e,n)=>{const o=t,i=n[o(379)][o(398)](o(373));c=i?JSON[o(423)](i):null}),this[t(369)](r,t(361),(o,s)=>{const r=t;if(!c)return;const l=s[r(406)]===this[r(358)].id;l&&r(396)===s[r(385)]||n[r(372)](t=>{const o=r;!function(t,e){const n=A,o=[];for(const{item:i}of t[n(419)](e))i.is(n(425),n(416))&&o[n(389)](i);for(const e of o)t[n(353)](e)}(t,s[o(400)]);let u=a[o(390)]();if(!u){const e=n[o(354)][o(387)][o(362)]()[o(418)];u=a[o(384)](t,e)}const f=function(t,e,n){const s=o,r=Object[s(382)](null);for(const{item:o}of t[s(419)](e))if(o.is(s(425),s(371))){const e=o[s(412)](s(410));if(!n(e))continue;r[e]||(r[e]=(0,i.uid)()),t[s(383)](s(410),r[e],o)}return r}(t,s[o(400)],t=>!l||null!==a[o(381)](t));for(const[n,i]of Object[o(394)](c)){const s=f[n]||n,r=t[o(408)](o(405),{footnoteId:s}),a=e[o(357)][o(415)][o(392)](i),c=e[o(357)][o(378)](a,r);t[o(402)](c,r),t[o(393)](r,u,o(359))}c=null})})}}var T=n(311),V=n(355),O=n(450),N=n.n(O),R=n(774),K=n.n(R),M=n(265),j=n.n(M),B=n(410),W=n.n(B),H=n(238),U=n.n(H),z=n(14),G={attributes:{"data-cke":!0}};G.setAttributes=W(),G.insert=j().bind(null,"head"),G.domAPI=K(),G.insertStyleElement=U();N()(z.A,G);z.A&&z.A.locals&&z.A.locals;class q 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",J(t,T.ButtonView)),e.add("menuBar:insertFootnote",J(t,T.MenuBarMenuListItemButtonView)),this.licenseKey=this.editor.config.get("licenseKey");const n=this.editor;this._licenseKeyCheckInterval=setInterval(()=>{let t;for(const e in n){const o=e,i=n[o];if("footnotesLicenseKeyValid"==i||"footnotesLicenseKeyInvalid"==i||"footnotesLicenseKeyExpired"==i||"footnotesLicenseKeyDomainLimit"==i||"footnotesLicenseKeyNotAllowed"==i||"footnotesLicenseKeyEvaluationLimit"==i||"footnotesLicenseKeyTrialLimit"==i||"footnotesLicenseKeyUsageLimit"==i){delete n[o],t=i,clearInterval(this._licenseKeyCheckInterval),this._licenseKeyCheckInterval=void 0;break}}"footnotesLicenseKeyInvalid"==t&&n._showLicenseError("invalid"),"footnotesLicenseKeyExpired"==t&&n._showLicenseError("expired"),"footnotesLicenseKeyDomainLimit"==t&&n._showLicenseError("domainLimit"),"footnotesLicenseKeyNotAllowed"==t&&n._showLicenseError("featureNotAllowed","Footnotes"),"footnotesLicenseKeyEvaluationLimit"==t&&n._showLicenseError("evaluationLimit"),"footnotesLicenseKeyTrialLimit"==t&&n._showLicenseError("trialLimit"),"footnotesLicenseKeyUsageLimit"==t&&n._showLicenseError("usageLimit")},1e3)}destroy(){super.destroy(),this._licenseKeyCheckInterval&&clearInterval(this._licenseKeyCheckInterval)}}function J(t,e){const n=t.commands.get("insertFootnote");return o=>{const{t:i}=o,s=new e(o),r=s instanceof T.MenuBarMenuListItemButtonView;return s.bind("isEnabled").to(n,"isEnabled"),s.set({label:i(r?"Footnote":"Insert footnote"),icon:V.IconFootnote,tooltip:!0}),s.on("execute",()=>{n.execute(),t.editing.view.focus()}),s}}function X(){var t=["66100980Bzjsap","194IWhyjQ","1240670fvjPmo","15178FXocBZ","isOfficialPlugin","pluginName","isPremiumPlugin","8qrgUMO","16596738WZYvGZ","16FTgFDa","2179608ektjCy","1335900EfBXfL","4795098ypJpqB","Footnotes","requires"];return(X=function(){return t})()}var Y=Q;function Q(t,e){var n=X();return(Q=function(t,e){return n[t-=384]})(t,e)}!function(t){for(var e=Q,n=t();;)try{if(923568===parseInt(e(394))/1*(-parseInt(e(396))/2)+-parseInt(e(388))/3+parseInt(e(385))/4*(-parseInt(e(395))/5)+parseInt(e(389))/6+parseInt(e(390))/7*(-parseInt(e(387))/8)+-parseInt(e(386))/9+parseInt(e(393))/10)break;n.push(n.shift())}catch(t){n.push(n.shift())}}(X);class Z extends t.Plugin{static get[Y(398)](){return Y(391)}static get[Y(392)](){return[v,D,q]}static get[Y(397)](){return!0}static get[Y(384)](){return!0}}const $=tt;function tt(t,e){const n=nt();return(tt=function(t,e){return n[t-=312]})(t,e)}!function(t){const e=tt,n=t();for(;;)try{if(905200===parseInt(e(314))/1*(-parseInt(e(316))/2)+-parseInt(e(320))/3*(-parseInt(e(327))/4)+parseInt(e(313))/5+-parseInt(e(326))/6*(-parseInt(e(328))/7)+parseInt(e(323))/8+-parseInt(e(329))/9+-parseInt(e(312))/10)break;n.push(n.shift())}catch(t){n.push(n.shift())}}(nt);const et=[$(324),$(322),$(317),$(315),$(325),$(321),$(319),$(318)];function nt(){const t=["47812900OSYHGh","8963865JGRJoK","1BBfiMu","upper-latin","563924JfNyNl","lower-latin","upper-roman","lower-roman","123NhNyOa","upper-alpha","decimal-leading-zero","12208232ONvRnW","decimal","lower-alpha","3972AXRhae","122756fzBFJK","14777kACtLJ","54729jQRLuX"];return(nt=function(){return t})()}function ot(t,e){const n=rt();return(ot=function(t,e){return n[t-=103]})(t,e)}const it=ot;!function(t){const e=ot,n=t();for(;;)try{if(338038===-parseInt(e(112))/1*(-parseInt(e(120))/2)+parseInt(e(124))/3*(parseInt(e(116))/4)+parseInt(e(117))/5+-parseInt(e(108))/6*(parseInt(e(110))/7)+parseInt(e(107))/8*(parseInt(e(104))/9)+parseInt(e(127))/10*(parseInt(e(114))/11)+parseInt(e(113))/12*(-parseInt(e(111))/13))break;n.push(n.shift())}catch(t){n.push(n.shift())}}(rt);class st extends t.Command{[it(115)](){const t=it,{editor:e}=this,n=e[t(128)][t(103)](f)[t(119)]();this[t(129)]=!!n,this[t(106)]=n?.[t(121)](t(109))??null}[it(125)]({value:t}){const e=it,{editor:n}=this,o=n[e(128)][e(103)](f),i=o[e(119)]();i&&et[e(105)](t)&&n[e(126)][e(123)](n=>{const s=e;n[s(118)](s(109),t,i),o[s(122)](n)})}}function rt(){const t=["setAttribute","getFootnotesDefinitionsObjectElement","1762zrTWxb","getAttribute","_updateFootnotesCounters","change","3LrysiA","execute","model","80AIJCtp","plugins","isEnabled","get","9inFGLB","includes","value","2101352hxKkGk","48666gRhubM","footnotesListStyle","483uwWDhL","5306717mAxXLU","181zCtGpq","24ZyOvLy","547492jwxlDq","refresh","2286784sHXgvZ","1610565kCVGdu"];return(rt=function(){return t})()}const at=lt;function ct(){const t=["997232OPIQwJ","model","refresh","value","execute","isInteger","setAttribute","9123kVUDjB","8370187QDuCGI","plugins","2733564dpFPxh","change","getFootnotesDefinitionsObjectElement","2186822ezPzYG","isEnabled","_updateFootnotesCounters","30FeiMzu","6sCtjil","getAttribute","footnotesListStart","20856LOPMIP","25UgJMMC","190068imFpwz","576dskTHt","get"];return(ct=function(){return t})()}function lt(t,e){const n=ct();return(lt=function(t,e){return n[t-=100]})(t,e)}!function(t){const e=lt,n=t();for(;;)try{if(748855===parseInt(e(111))/1+parseInt(e(104))/2+parseInt(e(114))/3+parseInt(e(101))/4*(-parseInt(e(100))/5)+-parseInt(e(121))/6*(parseInt(e(112))/7)+-parseInt(e(124))/8*(-parseInt(e(102))/9)+-parseInt(e(120))/10*(-parseInt(e(117))/11))break;n.push(n.shift())}catch(t){n.push(n.shift())}}(ct);class ut extends t.Command{[at(106)](){const t=at,{editor:e}=this,n=e[t(113)][t(103)](f)[t(116)]();this[t(118)]=!!n,this[t(107)]=n?.[t(122)](t(123))??null}[at(108)]({value:t}){const e=at,{editor:n}=this,o=n[e(113)][e(103)](f),i=o[e(116)]();i&&Number[e(109)](t)&&n[e(105)][e(115)](n=>{const s=e;n[s(110)](s(123),t,i),o[s(119)](n)})}}function ft(t,e){const n=yt();return(ft=function(t,e){return n[t-=107]})(t,e)}const dt=ft;!function(t){const e=ft,n=t();for(;;)try{if(988352===parseInt(e(130))/1*(-parseInt(e(207))/2)+parseInt(e(182))/3+-parseInt(e(189))/4+parseInt(e(194))/5*(-parseInt(e(164))/6)+parseInt(e(204))/7+parseInt(e(153))/8*(parseInt(e(198))/9)+parseInt(e(183))/10)break;n.push(n.shift())}catch(t){n.push(n.shift())}}(yt);class pt extends t.Plugin{static get[dt(126)](){return dt(150)}static get[dt(172)](){return[v,f]}static get[dt(166)](){return!0}static get[dt(114)](){return!0}[dt(157)](){const t=dt,{editor:e}=this;e[t(169)][t(127)](t(196),t(136)),e[t(169)][t(127)](t(132),1),e[t(167)][t(181)](t(191),new st(e)),e[t(167)][t(181)](t(162),new ut(e)),this[t(158)](),this[t(145)](),this[t(177)](),this[t(175)]()}[dt(158)](){const t=dt,{editor:e}=this,{schema:n}=e[t(174)];n[t(193)](t(188),{allowAttributes:[t(197),t(165)]})}[dt(145)](){const t=dt,{editor:e}=this,{conversion:n,model:o}=e,{schema:i}=o;n[t(163)](t(179))[t(181)](e=>{const n=t;e.on(n(141),(t,e,o)=>{const s=n,r=e[s(187)],a=e[s(168)]?.[s(178)];r[s(116)](s(121))&&a?.is(s(195),s(188))&&(function(t,e,n,o){const i=s;if(!o[i(115)](e,i(165)))return;let r=1;const a=n[i(122)][i(152)](t,{attributes:i(201)});if(a){const e=Number[i(111)](t[i(200)](i(201)),10);Number[i(203)](e)||(r=e)}!a&&e[i(147)](i(165))||n[i(112)][i(173)](i(165),r,e)}(r,a,o,i),function(t,e,n,o){const i=s;if(!o[i(115)](e,i(197)))return;let r=i(136),a=!1;if(n[i(122)][i(152)](t,{attributes:i(113)})){const e={1:i(136),a:i(154),A:i(160),i:i(176),I:i(148)}[t[i(200)](i(113))];e&&(r=e),a=!0}n[i(122)][i(152)](t,{styles:i(119)})&&(r=t[i(159)](i(119)),a=!0),!a&&e[i(147)](i(197))||n[i(112)][i(173)](i(197),r,e)}(r,a,o,i))})}),n[t(163)](t(144))[t(181)](e=>{const n=t;e.on(n(133),(t,e,o)=>{const i=n;if(!o[i(122)][i(152)](e[i(124)],t[i(120)]))return;const s=ht(e[i(124)],o[i(170)]),{attributeNewValue:r}=e;null==r||1===r?o[i(112)][i(131)](i(201),s):o[i(112)][i(173)](i(201),String(r),s)}),e.on(n(206),(t,e,o)=>{const i=n;if(!o[i(122)][i(152)](e[i(124)],t[i(120)]))return;const s=ht(e[i(124)],o[i(170)]),{attributeNewValue:r}=e;r&&i(136)!==r?o[i(112)][i(143)](i(119),r,s):o[i(112)][i(125)](i(119),s)})})}[dt(175)](){const t=dt,{editor:e}=this,{model:n}=e,o=e[t(134)][t(156)](f),i=this[t(140)](),s=this[t(139)]();n[t(184)][t(205)](e=>{const r=t,a=n[r(184)][r(107)][r(129)]();let c=!1;for(const t of a){if(r(151)!==t[r(113)]||r(146)===t[r(120)])continue;const o=n[r(180)](t[r(155)][r(142)]);for(const t of o[r(128)]())t.is(r(195),r(188))&&(!t[r(147)](r(165))&&n[r(138)][r(115)](t,r(165))&&(e[r(173)](r(165),s,t),c=!0),!t[r(147)](r(197))&&n[r(138)][r(115)](t,r(197))&&(e[r(173)](r(197),i,t),c=!0))}return c&&o[r(161)](e),c})}[dt(177)](){const t=dt,{editor:e}=this;e[t(134)][t(156)](f)[t(118)](e=>this[t(199)](e))}[dt(140)](){const t=dt;return this[t(108)][t(169)][t(156)](t(196))}[dt(139)](){const t=dt;return this[t(108)][t(169)][t(156)](t(132))}[dt(199)]({container:t,value:e,digits:n}){const o=dt,i=t[o(200)](o(197)),s=t[o(200)](o(165)),r=Math[o(117)](e)+(s??1)-1;switch(i){case o(110):return function(t,e){const n=o;return String(t)[n(137)](e,"0")}(r,Math[o(186)](2,n));case o(154):case o(109):return mt(r,!1);case o(160):case o(192):return mt(r,!0);case o(176):return wt(r,!1);case o(148):return wt(r,!0);default:return String(r)}}}function ht(t,e){const n=dt,o=e[n(135)](t);return Array[n(149)](o[n(190)]())[n(202)](t=>t.is(n(195),"ol")&&t[n(116)](n(121)))}function mt(t,e){const n=dt;let o="",i=t;for(;i>0;){const t=(i-1)%26;o=String[n(185)](97+t)+o,i=Math[n(117)]((i-1)/26)}return e?o[n(171)]():o}const gt=[{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 wt(t,e){const n=dt;let o="",i=t;for(const{value:t,numeral:e}of gt)for(;i>=t;)o+=e,i-=t;return e?o:o[n(123)]()}function yt(){const t=["_updateFootnotesCounters","footnotesStart","for","2966982eGorjt","footnotesListStart","isOfficialPlugin","commands","modelCursor","config","mapper","toUpperCase","requires","setAttribute","model","_definePostfixer","lower-roman","_defineFormatter","parent","upcast","createRangeOn","add","1101243qMLkOc","9845080NXcPgd","document","fromCharCode","max","viewItem","footnotesDefinitions","249632kSJIct","getChildren","footnotesStyle","upper-latin","extend","10quEYBW","element","footnotes.footnotesProperties.defaultListStyle","footnotesListStyle","9UaYfGM","_formatFootnoteListValue","getAttribute","start","find","isNaN","7643706yAeQSo","registerPostFixer","attribute:footnotesListStyle:footnotesDefinitions","3234vmpvoH","differ","editor","lower-latin","decimal-leading-zero","parseInt","writer","type","isPremiumPlugin","checkAttribute","hasClass","floor","setFootnoteFormatter","list-style-type","name","footnotes-list","consumable","toLowerCase","item","removeStyle","pluginName","define","getItems","getChanges","917ErqQcF","removeAttribute","footnotes.footnotesProperties.defaultStartIndex","attribute:footnotesListStart:footnotesDefinitions","plugins","toViewElement","decimal","padStart","schema","_getDefaultStartIndex","_getDefaultListStyle","element:ol","nodeAfter","setStyle","downcast","_defineConverters","$text","hasAttribute","upper-roman","from","FootnotesPropertiesEditing","insert","consume","8631968GLikEL","lower-alpha","position","get","init","_defineSchema","getStyle","upper-alpha"];return(yt=function(){return t})()}class bt extends T.View{children;stylesView=null;additionalProperties=null;startIndexFieldView=null;focusTracker=new i.FocusTracker;keystrokes=new i.KeystrokeHandler;focusables=new T.ViewCollection;focusCycler;constructor(t,{styleButtonViews:e,styleGridAriaLabel:n}){super(t),this.focusCycler=new T.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,n),[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,T.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 n=new T.View(this.locale);return n.children=n.createCollection(),n.children.addMany(t),n.setTemplate({tag:"div",attributes:{"aria-label":e,class:["ck","ck-footnotes-definitions-styles-list"]},children:n.children}),n.children.delegate("execute").to(this),n.focus=function(){for(const t of this.children)if(t instanceof T.ButtonView&&t.isOn)return void t.focus();this.children.first.focus()},n.focusTracker=new i.FocusTracker,n.keystrokes=new i.KeystrokeHandler,n.render(),n.keystrokes.listenTo(n.element),this.children.add(n),n}_appendAdditionalPropertiesCollapsibleView(){const{t}=this.locale,e=this._createStartIndexPropertyView(),n=[e],o=new T.CollapsibleView(this.locale,n);return o.set({label:t("Footnotes properties"),isCollapsed:!0}),o.buttonView.bind("isEnabled").toMany(n,"isEnabled",(...t)=>t.some(t=>t)),o.buttonView.on("change:isEnabled",(t,e,n)=>{n||(o.isCollapsed=!0)}),this.children.add(o),[e,o]}_createStartIndexPropertyView(){const{t}=this.locale,e=new T.LabeledFieldView(this.locale,T.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 n=e.fieldView.element,o=n.valueAsNumber;Number.isNaN(o)?e.errorText=t("Invalid footnotes start index value."):n.checkValidity()?this.fire("footnotesListStart",{startIndex:o}):e.errorText=t(o<0?"Footnotes start index must be greater than 0.":"Footnotes start index is too large.")}),e}}var vt=n(945),It={attributes:{"data-cke":!0}};It.setAttributes=W(),It.insert=j().bind(null,"head"),It.domAPI=K(),It.insertStyleElement=U();N()(vt.A,It);vt.A&&vt.A.locals&&vt.A.locals;class kt extends t.Plugin{static get pluginName(){return"FootnotesPropertiesUI"}static get requires(){return[T.ContextualBalloon,e.WidgetToolbarRepository]}static get isOfficialPlugin(){return!0}static get isPremiumPlugin(){return!0}init(){const{editor:t}=this,{componentFactory:e}=t.ui;var n;t.config.define("footnotes.footnotesProperties.toolbar",["footnotesStyle"]),e.add("footnotesStyle",(n=t,t=>{const{t:e}=t,o=n.commands.get("footnotesStyle"),i=(0,T.createDropdown)(t),{buttonView:s}=i;return i.class="ck-footnotes-styles-dropdown",i.bind("isEnabled").to(o,"isEnabled"),s.set({label:e("Footnotes style"),icon:V.IconFootnote,tooltip:!0}),i.once("change:isOpen",()=>{const t=function({editor:t,dropdownView:e}){const{t:n}=t.locale,o=n("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:V.IconListStyleDecimal},{label:e("Toggle the decimal with leading zero footnotes style"),tooltip:e("Decimal footnotes with leading zero"),style:"decimal-leading-zero",icon:V.IconListStyleDecimalLeadingZero},{label:e("Toggle the lower–roman footnotes style"),tooltip:e("Lower–roman footnotes"),style:"lower-roman",icon:V.IconListStyleLowerRoman},{label:e("Toggle the upper–roman footnotes style"),tooltip:e("Upper-roman footnotes"),style:"upper-roman",icon:V.IconListStyleUpperRoman},{label:e("Toggle the lower–latin footnotes style"),tooltip:e("Lower-latin footnotes"),style:"lower-latin",icon:V.IconListStyleLowerLatin},{label:e("Toggle the upper–latin footnotes style"),tooltip:e("Upper-latin footnotes"),style:"upper-latin",icon:V.IconListStyleUpperLatin}].map(function(t){const e=t.locale;return({label:n,icon:o,tooltip:i,style:s})=>{const r=t.commands.get("footnotesStyle"),a=new T.ButtonView(e);return a.set({label:n,icon:o,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 bt(t.locale,{styleGridAriaLabel:o,styleButtonViews:i});return s.delegate("execute").to(e),s.on("footnotesListStart",(e,n)=>{t.execute("footnotesStart",{value:n.startIndex})}),s}({editor:n,dropdownView:i});i.panelView.children.add(t)}),i}))}afterInit(){const{editor:t}=this,{t:n}=t.locale,o=t.plugins.get(e.WidgetToolbarRepository),{defaultPositions:i}=T.BalloonPanelView;o.register("footnotesDefinitions",{ariaLabel:n("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 Ct=xt;function Ft(){var t=["11382160fQJjVk","1576280ATzsgW","85qcJZAZ","5062748efImma","3HaOTsO","9987502QqLyPD","pluginName","FootnotesProperties","isOfficialPlugin","requires","1152FFwlji","98244eokYBy","isPremiumPlugin","80176JVSBXk","23162ROramW"];return(Ft=function(){return t})()}function xt(t,e){var n=Ft();return(xt=function(t,e){return n[t-=150]})(t,e)}!function(t){for(var e=xt,n=t();;)try{if(804385===parseInt(e(163))/1+parseInt(e(150))/2+-parseInt(e(153))/3*(-parseInt(e(152))/4)+parseInt(e(151))/5*(-parseInt(e(160))/6)+parseInt(e(154))/7+-parseInt(e(162))/8*(parseInt(e(159))/9)+-parseInt(e(164))/10)break;n.push(n.shift())}catch(t){n.push(n.shift())}}(Ft);class Et extends t.Plugin{static get[Ct(155)](){return Ct(156)}static get[Ct(158)](){return[pt,kt]}static get[Ct(157)](){return!0}static get[Ct(161)](){return!0}}function Pt(){var t=["390590uJMbHN","1143498VWcrDb","817267yTspHo","6767109uTILeX","7voykNY","2976135EkSEQk","4763364TwTtlW","10678200wHHoaB","108QXYgXR"];return(Pt=function(){return t})()}function St(t,e){var n=Pt();return(St=function(t,e){return n[t-=365]})(t,e)}!function(t){for(var e=St,n=t();;)try{if(869972===parseInt(e(372))/1+-parseInt(e(371))/2+parseInt(e(366))/3+-parseInt(e(367))/4+-parseInt(e(370))/5*(-parseInt(e(369))/6)+parseInt(e(365))/7*(-parseInt(e(368))/8)+parseInt(e(373))/9)break;n.push(n.shift())}catch(t){n.push(n.shift())}}(Pt)})(),(window.CKEditor5=window.CKEditor5||{}).footnotes=o})();
|
|
4
|
+
*/(()=>{var t={14:(t,e,n)=>{"use strict";n.d(e,{A:()=>a});var o=n(453),i=n.n(o),s=n(374),r=n.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-content .footnote-content ul{list-style-type:disc}.ck-content .footnote-content ul ul{list-style-type:circle}.ck-content .footnote-content ul ul ul,.ck-content .footnote-content ul ul ul ul{list-style-type:square}.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,n){var o=function(t){if(void 0===e[t]){var n=document.querySelector(t);if(window.HTMLIFrameElement&&n instanceof window.HTMLIFrameElement)try{n=n.contentDocument.head}catch(t){n=null}e[t]=n}return e[t]}(t);if(!o)throw new Error("Couldn't find a style target. This probably means that the value for the 'insert' parameter is invalid.");o.appendChild(n)}},311:(t,e,n)=>{t.exports=n(237)("./src/ui.js")},331:(t,e,n)=>{t.exports=n(237)("./src/clipboard.js")},355:(t,e,n)=>{t.exports=n(237)("./src/icons.js")},374:t=>{"use strict";t.exports=function(t){var e=[];return e.toString=function(){return this.map(function(e){var n="",o=void 0!==e[5];return e[4]&&(n+="@supports (".concat(e[4],") {")),e[2]&&(n+="@media ".concat(e[2]," {")),o&&(n+="@layer".concat(e[5].length>0?" ".concat(e[5]):""," {")),n+=t(e),o&&(n+="}"),e[2]&&(n+="}"),e[4]&&(n+="}"),n}).join("")},e.i=function(t,n,o,i,s){"string"==typeof t&&(t=[[null,t,void 0]]);var r={};if(o)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]);o&&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),n&&(u[2]?(u[1]="@media ".concat(u[2]," {").concat(u[1],"}"),u[2]=n):u[2]=n),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(n){t.setAttribute(n,e[n])})}},450:t=>{"use strict";var e=[];function n(t){for(var n=-1,o=0;o<e.length;o++)if(e[o].identifier===t){n=o;break}return n}function o(t,o){for(var s={},r=[],a=0;a<t.length;a++){var c=t[a],l=o.base?c[0]+o.base:c[0],u=s[l]||0,f="".concat(l," ").concat(u);s[l]=u+1;var d=n(f),p={css:c[1],media:c[2],sourceMap:c[3],supports:c[4],layer:c[5]};if(-1!==d)e[d].references++,e[d].updater(p);else{var h=i(p,o);o.byIndex=a,e.splice(a,0,{identifier:f,updater:h,references:1})}r.push(f)}return r}function i(t,e){var n=e.domAPI(e);n.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;n.update(t=e)}else n.remove()}}t.exports=function(t,i){var s=o(t=t||[],i=i||{});return function(t){t=t||[];for(var r=0;r<s.length;r++){var a=n(s[r]);e[a].references--}for(var c=o(t,i),l=0;l<s.length;l++){var u=n(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,n)=>{t.exports=n(237)("./src/utils.js")},774:t=>{"use strict";var e,n=(e=[],function(t,n){return e[t]=n,e.filter(Boolean).join("\n")});function o(t,e,o,i){var s;if(o)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=n(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++,n=i.singleton||(i.singleton=t.insertStyleElement(t));return{update:function(t){o(n,e,!1,t)},remove:function(t){o(n,e,!0,t)}}}},782:(t,e,n)=>{t.exports=n(237)("./src/core.js")},783:(t,e,n)=>{t.exports=n(237)("./src/engine.js")},901:(t,e,n)=>{t.exports=n(237)("./src/widget.js")},945:(t,e,n)=>{"use strict";n.d(e,{A:()=>a});var o=n(453),i=n.n(o),s=n(374),r=n.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 n(o){var i=e[o];if(void 0!==i)return i.exports;var s=e[o]={id:o,exports:{}};return t[o](s,s.exports,n),s.exports}n.n=t=>{var e=t&&t.__esModule?()=>t.default:()=>t;return n.d(e,{a:e}),e},n.d=(t,e)=>{for(var o in e)n.o(e,o)&&!n.o(t,o)&&Object.defineProperty(t,o,{enumerable:!0,get:e[o]})},n.o=(t,e)=>Object.prototype.hasOwnProperty.call(t,e),n.r=t=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})};var o={};(()=>{"use strict";n.r(o),n.d(o,{Footnotes:()=>Z,FootnotesClipboard:()=>D,FootnotesEditing:()=>v,FootnotesProperties:()=>Et,FootnotesPropertiesEditing:()=>pt,FootnotesPropertiesUI:()=>kt,FootnotesStartCommand:()=>ut,FootnotesStyleCommand:()=>st,FootnotesTracker:()=>f,FootnotesUI:()=>q,InsertFootnoteCommand:()=>b});var t=n(782),e=n(901),i=n(584),s=n(783);function r(){const t=["getElementKey","getChanges","692643WJCgnE","$graveyard","from","getItems","7154376HJnAZV","_model","3591087YPkyTt","add","elementName","rootName","2309255JGTnhb","attributes","1388212AGsqWL","18TTTbIG","insert","$text","2CXpNqy","reset","values","clear","has","push","slice","type","_getElementKey","remove","_trackedElements","4129854DcpLll","3434120mKukkW","8RabSPP","root","delete","length","position","get","createRangeOn","set","element","nodeAfter","_elementName","flat","name"];return(r=function(){return t})()}function a(t,e){const n=r();return(a=function(t,e){return n[t-=357]})(t,e)}const c=a;!function(t){const e=a,n=t();for(;;)try{if(730622===-parseInt(e(363))/1+parseInt(e(379))/2*(parseInt(e(369))/3)+-parseInt(e(392))/4*(-parseInt(e(373))/5)+-parseInt(e(390))/6+parseInt(e(375))/7+-parseInt(e(367))/8+-parseInt(e(376))/9*(-parseInt(e(391))/10))break;n.push(n.shift())}catch(t){n.push(n.shift())}}(r);class l{[c(368)];[c(358)];[c(387)];[c(389)]=new Map;constructor(t,e){const n=c;this[n(368)]=t,this[n(358)]=e[n(371)],this[n(387)]=e[n(361)]}[c(380)](){const t=c;this[t(389)][t(382)]()}[c(362)](t){const e=c,n=new Set,o=new Map;for(const i of t){if(e(377)===i[e(386)]&&e(378)!==i[e(360)]&&i[e(396)][e(357)]){const t=this[e(368)][e(398)](i[e(396)][e(357)]);for(const n of t[e(366)]()){if(!n.is(e(400),this[e(358)]))continue;const t=this[e(387)](n);o[e(383)](t)||o[e(399)](t,[]),o[e(397)](t)[e(384)](n)}}if(e(388)===i[e(386)]&&i[e(360)]===this[e(358)]){const t=this[e(387)]({getAttribute:t=>i[e(374)][e(397)](t)});n[e(370)](t)}}for(const[t,o]of this[e(389)])e(364)===o[e(393)][e(372)]&&n[e(370)](t);for(const t of n)this[e(389)][e(394)](t);for(const[t,n]of o)this[e(389)][e(399)](t,n[n[e(395)]-1]);const i=new Set;for(const[t,s]of o)n[e(383)](t)&&(i[e(370)](s[0]),s[e(395)]>1?o[e(399)](t,s[e(385)](1)):o[e(394)](t),n[e(394)](t));return{removed:Array[e(365)](n),inserted:Array[e(365)](o[e(381)]())[e(359)](),moved:Array[e(365)](i)}}}const u=d;!function(t){const e=d,n=t();for(;;)try{if(194312===parseInt(e(192))/1+-parseInt(e(155))/2*(parseInt(e(182))/3)+-parseInt(e(173))/4*(parseInt(e(244))/5)+parseInt(e(236))/6*(parseInt(e(200))/7)+parseInt(e(193))/8*(parseInt(e(186))/9)+parseInt(e(156))/10*(-parseInt(e(157))/11)+-parseInt(e(163))/12*(-parseInt(e(215))/13))break;n.push(n.shift())}catch(t){n.push(n.shift())}}(p);class f extends t.Plugin{[u(202)]=[];[u(188)]=null;[u(203)]=null;[u(196)];[u(237)];[u(241)];static get[u(201)](){return u(213)}static get[u(161)](){return!0}static get[u(191)](){return!0}constructor(t){const e=u;super(t),this[e(196)]=new l(this[e(209)][e(190)],{elementName:e(175),getElementKey:()=>e(167)}),this[e(237)]=new l(this[e(209)][e(190)],{elementName:e(229),getElementKey:t=>t[e(214)](e(242))}),this[e(241)]=new l(this[e(209)][e(190)],{elementName:e(176),getElementKey:t=>t[e(214)](e(242))})}[u(224)](){const t=u,{editor:e}=this,{model:n,data:o}=e;n[t(185)][t(181)](e=>{const o=t,i=n[o(185)][o(243)][o(183)]();let s=!1;return this[o(147)](e,i)&&(s=!0),this[o(234)](e,i)&&(s=!0),this[o(223)](e,i)&&(s=!0),this[o(178)](e)&&(s=!0),this[o(144)](e)&&(s=!0),this[o(205)](e)&&(s=!0),s}),this[t(174)](n[t(185)],t(158),()=>{const e=t;n[e(227)]({isUndoable:!1},t=>{this[e(246)](t)})},{priority:t(159)}),this[t(174)](o,t(228),()=>{const e=t;this[e(202)]=[],this[e(196)][e(206)](),this[e(237)][e(206)](),this[e(241)][e(206)]()},{priority:t(189)})}[u(225)](){return this[u(188)]}[u(169)](t){const e=u;return this[e(202)][e(166)](e=>e.id===t)||null}[u(204)](){const t=u;return Array[t(195)](this[t(202)])}[u(247)](){return this[u(203)]}[u(146)](t){this[u(203)]=t}[u(207)](t,e=0){const n=u;let o=!1;for(let i=e;i<this[n(202)][n(154)];i++)this[n(198)](t,i)&&(o=!0);return o}[u(197)](t,e){const n=u,o=t[n(240)](n(175),{});return t[n(211)](o,e),this[n(188)]=o,o}[u(246)](t){const e=u;if(!this[e(202)][e(154)]||this[e(188)])return;const n=this[e(202)][0][e(152)][e(231)],o=this[e(197)](t,n);for(const n of this[e(202)])n[e(180)][e(150)]||t[e(216)](n[e(180)],o,e(184));this[e(207)](t)}[u(147)](t,e){const n=u;let o=!1;const{inserted:i,removed:s,moved:r}=this[n(196)][n(183)](e);if(r[n(154)]&&(this[n(188)]=r[0]),i[n(154)])if(i[n(154)]>1||this[n(188)]&&i[n(210)](t=>t!==this[n(188)])){const e=t[n(240)](n(175),{}),s=[];this[n(188)]&&s[n(221)](this[n(188)]),s[n(221)](...i),t[n(216)](e,s[0],n(149));for(const o of s)t[n(177)](t[n(222)](o),t[n(245)](e,n(184))),t[n(217)](o);this[n(188)]=e,this[n(207)](t),o=!0}else this[n(188)]=i[0];if(s[n(154)]&&n(220)===this[n(188)]?.[n(231)][n(212)]){for(const e of this[n(202)])t[n(217)](e[n(152)]),o=!0;this[n(202)]=[],this[n(188)]=null}return o}[u(234)](t,e){const n=u;let o=!1;const i=this[n(209)][n(187)][n(153)](n(162)),{inserted:s,moved:r}=this[n(241)][n(183)](e);for(const e of[...r,...s]){const s=e[n(214)](n(242)),r=this[n(169)](s);r&&(r[n(180)]=e),h(t,i,e)&&(o=!0)}return o}[u(223)](t,e){const n=u;let o=!1;const{removed:i,inserted:s,moved:r}=this[n(237)][n(183)](e);for(const e of i)this[n(239)](t,e)&&(o=!0);for(const e of s)this[n(168)](t,e)&&(o=!0);for(const e of r)this[n(238)](t,e)&&(o=!0);return o}[u(144)](t){const e=u;if(!this[e(188)])return!1;let n=!1;if(this[e(188)][e(148)]!==this[e(202)][e(154)]){const o=[];for(const t of this[e(188)][e(171)]()){const i=t[e(214)](e(242));this[e(169)](i)||(o[e(218)](t),n=!0)}for(const n of o)t[e(217)](n)}const o=new Set,i=[];for(const t of this[e(188)][e(171)]()){const s=t[e(214)](e(242));o[e(164)](s)?(i[e(218)](t),n=!0):o[e(219)](s)}for(const n of i)t[e(217)](n);return this[e(188)][e(148)]||(t[e(217)](this[e(188)]),this[e(188)]=null,n=!0),n}[u(168)](t,e){const n=u;if(this[n(202)][n(166)](t=>t[n(152)]===e))return!1;let o=!1;const i=e[n(214)](n(242)),s=this[n(202)][n(151)](t=>t.id===i);-1!==s&&(t[n(217)](this[n(202)][s][n(152)]),this[n(202)][n(145)](s,1),o=!0);let r=this[n(188)]?function(t,e){const o=n;for(const n of t[o(171)]())if(n[o(214)](o(242))===e)return n;return null}(this[n(188)],i):null;r||(r=t[n(240)](n(176),{footnoteId:i}),this[n(188)]&&(t[n(216)](r,this[n(188)],n(184)),o=!0));const a={id:i,reference:e,definition:r},c=m(this[n(209)][n(190)],this[n(202)],e);this[n(202)][n(145)](c,0,a);let l=c;return-1!==s&&(l=Math[n(194)](c,s)),this[n(207)](t,l)&&(o=!0),o}[u(239)](t,e){const n=u,o=this[n(202)][n(151)](t=>t.id===e);if(-1===o)return!1;let i=!1;const s=this[n(202)][o];return n(220)!==s[n(180)][n(231)][n(212)]&&(t[n(217)](s[n(180)]),i=!0),this[n(202)][n(145)](o,1),this[n(207)](t,o)&&(i=!0),i}[u(238)](t,e){const n=u,o=e[n(214)](n(242)),i=this[n(202)][n(151)](t=>t.id===o),s=this[n(202)][i];let r=!1;s[n(152)]=e,this[n(202)][n(145)](i,1);const a=m(this[n(209)][n(190)],this[n(202)],e);return this[n(202)][n(145)](a,0,s),this[n(207)](t,Math[n(194)](i,a))&&(r=!0),r}[u(198)](t,e){const n=u;if(!this[n(188)])return!1;const o=this[n(202)][e];let i;return i=this[n(203)]?this[n(203)]({footnote:o,container:this[n(188)],digits:String(this[n(202)][n(154)])[n(154)],value:e+1}):String(e+1),o[n(152)][n(214)](n(232))!=i&&(t[n(170)](n(232),i,o[n(152)]),!0)}[u(205)](t){const e=u;if(!this[e(188)]||this[e(202)][e(154)]<2)return!1;if(function(t,n){const o=e;if(t[o(154)]!==n[o(154)])return!1;for(let e=0;e<t[o(154)];e++)if(t[e]!==n[e])return!1;return!0}(this[e(202)][e(160)](t=>t.id),Array[e(195)](this[e(188)][e(171)]())[e(160)](t=>t[e(214)](e(242)))))return!1;let n=!1;for(let o=0;o<this[e(202)][e(154)];o++){const i=this[e(202)][o],s=t[e(235)](i[e(180)]),r=t[e(245)](this[e(188)],o);s[e(165)](r)||(t[e(177)](t[e(233)](i[e(180)]),r),n=!0)}return n}[u(178)](t){const e=u;if(!this[e(202)][e(154)])return!1;const{model:n}=this[e(209)];let o=!1;for(let i=0;i<this[e(202)][e(154)]-1;i++){const s=this[e(202)][i],r=this[e(202)][i+1],a=n[e(235)](s[e(152)]),c=n[e(235)](r[e(152)]);e(226)===a[e(179)](c)&&(this[e(238)](t,s[e(152)]),i=-1,o=!0)}return o}}function d(t,e){const n=p();return(d=function(t,e){return n[t-=144]})(t,e)}function p(){const t=["createPositionBefore","33240tSMOMG","_footnoteRefsTracker","_handleMovedFootnoteReference","_handleRemoveFootnoteReferenceById","createElement","_footnoteDefsTracker","footnoteId","differ","353315jHoZAg","createPositionAt","_ensureFootnotesDefinitionsContainerExists","getFootnotesFormatter","_handleFootnotesDefinitionsObjectSync","splice","setFootnoteFormatter","_handleFootnotesDefinitionsObjectChanges","childCount","before","parent","findIndex","reference","get","length","214NiugWL","10BOeymQ","1722655OliCjf","change:data","low","map","isOfficialPlugin","footnotes.multiBlock","59808thasXU","has","isEqual","find","singleton","_handleInsertedFootnoteReference","getFootnote","setAttribute","getChildren","paragraph","8rbBgCB","listenTo","footnotesDefinitions","footnoteDefinition","move","_ensureFootnotesReferencesHaveProperOrder","compareWith","definition","registerPostFixer","10239rWWfYd","getChanges","end","document","27wlWhUE","config","_footnotesDefinitions","high","model","isPremiumPlugin","198461kkPUGk","126904aJwWne","min","from","_footnoteDefsContainerTracker","_insertEmptyFootnotesDefinitionsContainer","_updateFootnoteRefCounter","footnoteInlineContent","42lYYmRF","pluginName","_footnotes","_footnoteFormatter","getFootnotes","_sortFootnoteDefinitions","reset","_updateFootnotesCounters","getRootNames","editor","some","append","rootName","FootnotesTracker","getAttribute","1508xuCHey","insert","remove","unshift","add","$graveyard","push","createRangeIn","_handleFootnoteReferencesChanges","init","getFootnotesDefinitionsObjectElement","after","enqueueChange","set","footnoteRef","indexOf","root","footnoteCounter","createRangeOn","_handleFootnoteDefinitionsChanges"];return(p=function(){return t})()}function h(t,e,n){const o=u;if(n[o(148)])return!1;const i=o(e?172:199);return t[o(216)](t[o(240)](i),n),!0}function m(t,e,n){const o=u;if(0===e[o(154)])return 0;const i=t[o(235)](n);for(let n=0;n<e[o(154)];n++){const s=e[n],r=t[o(235)](s[o(152)]);if(o(149)===i[o(179)](r))return n}const s=n[o(231)];let r=-1;for(let t=e[o(154)]-1;t>=0;t--)if(e[t][o(152)][o(231)]===s){r=t;break}if(-1!==r)return r+1;const a=t[o(185)][o(208)](),c=a[o(230)](s[o(212)]),l=a[c+1];if(l)for(let t=0;t<e[o(154)];t++)if(e[t][o(152)][o(231)][o(212)]===l)return t;return e[o(154)]}const g=y;function w(){const t=["model","length","293652Nmeenp","get","insert-footnote-command-executed-with-invalid-id","string","editor","document","7lfhyzL","_getPositionToInsertFootnote","isObject","execute","getFirstRange","getItems","selection","checkChild","end","19920wPfupR","isEnabled","_moveSelectionToFootnoteDefinition","1134ymvITt","1106700YGUslL","75376lKtZrR","plugins","test","refresh","12KhhpbN","change","59397sUDaiC","FootnotesEditing","1882952wauUit","footnoteId","footnoteRef","isBlock","insertObject","76438JgQjLA","createElement"];return(w=function(){return t})()}function y(t,e){const n=w();return(y=function(t,e){return n[t-=356]})(t,e)}!function(t){const e=y,n=t();for(;;)try{if(126821===parseInt(e(364))/1+-parseInt(e(392))/2*(parseInt(e(357))/3)+-parseInt(e(388))/4+parseInt(e(387))/5+-parseInt(e(368))/6+-parseInt(e(374))/7*(parseInt(e(359))/8)+parseInt(e(386))/9*(parseInt(e(383))/10))break;n.push(n.shift())}catch(t){n.push(n.shift())}}(w);class b extends t.Command{[g(391)](){const t=g,e=this[t(372)][t(366)][t(373)][t(380)],n=this[t(375)](e);this[t(384)]=!!n}[g(377)](t){const e=g,{editor:n}=this,{model:o}=n,{selection:s}=o[e(373)],r=this[e(375)](s);if(!r)return;const a=n[e(389)][e(369)](e(358)),c=t?.[e(360)]??(0,i.uid)();!function(t){const n=e;return n(371)==typeof t&&t[n(367)]>0&&!/\s/[n(390)](t)&&!/^\d/[n(390)](t)}(c)?(0,i.logWarning)(e(370)):(o[e(356)](t=>{const n=e,i=t[n(365)](n(361),{footnoteId:c});o[n(363)](i,r,null)}),a[e(385)](c))}[g(375)](t){const e=g,{model:n}=this[e(372)],{schema:o}=n,i=t[e(378)]();for(const t of i[e(379)]())if(o[e(362)](t)||o[e(376)](t))return null;const s=i[e(382)];return o[e(381)](s,e(361))?s:null}}class v extends t.Plugin{static get pluginName(){return"FootnotesEditing"}static get requires(){return[f]}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]),n=window[m([68,97,116,101])][m([110,111,119])](),o=t[m([101,100,105,116,111,114])],s=new(window[m([80,114,111,109,105,115,101])])(t=>{o[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=o[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;o[m([109,111,100,101,108])][m([111,110])](m([97,112,112,108,121,79,112,101,114,97,116,105,111,110]),(n,o)=>{o[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(),n[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 n(t){for(let n=0;n<t[m([108,101,110,103,116,104])];n++){const o=t[m([99,104,97,114,67,111,100,101,65,116])](n);e=(e<<5)+e+o,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,o])=>{n(e),t(o)}):n(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 p(t){return t[m([115,112,108,105,116])]("")[m([114,101,118,101,114,115,101])]()[m([106,111,105,110])]("")}function h(){}function m(t){return t.map(t=>String.fromCharCode(t)).join("")}!function(t){const n=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 n=m([117]);for(let o=0;o<t[m([108,101,110,103,116,104])];o+=2){let i=window[m([112,97,114,115,101,73,110,116])](t[m([115,117,98,115,116,114,105,110,103])](o,o+2));i>=e[m([108,101,110,103,116,104])]&&(i-=e[m([108,101,110,103,116,104])]),n+=e[i]}return n}();o[n]=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,o[m([109,111,100,101,108])][m([99,104,97,110,103,101])]=h,o[m([109,111,100,101,108])][m([101,110,113,117,101,117,101,67,104,97,110,103,101])]=h,o[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,h=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&&n()?e:null;function n(){const t=e[m([106,116,105])],n=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),o={...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 o[m([118,99])],f(o)==n}}}(),t?(t[m([117,115,97,103,101,69,110,100,112,111,105,110,116])]&&(h=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(),o[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 h(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(o){a(o)[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(n-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)),o=p(d(window[m([77,97,116,104])][m([99,101,105,108])](n/i)));window[m([108,111,99,97,108,83,116,111,114,97,103,101])][m([115,101,116,73,116,101,109])](e,o)}function r(){const e=m([108,108,99,116,45])+d(f(t)),n=window[m([108,111,99,97,108,83,116,111,114,97,103,101])][m([103,101,116,73,116,101,109])](e);return n?window[m([112,97,114,115,101,73,110,116])](p(n),16)*i:null}function a(t){return new(window[m([80,114,111,109,105,115,101])])((e,n)=>{t[m([116,104,101,110])](e,n),window[m([115,101,116,84,105,109,101,111,117,116])](n,12e4)})}}o[m([111,110])](m([95,115,101,110,100,85,115,97,103,101,82,101,113,117,101,115,116]),(e,n)=>{if(n[0]!=t)return c(m([85,115,97,103,101,76,105,109,105,116]));n[1]={...n[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])}),o[m([111,110])](m([95,115,101,110,100,85,115,97,103,101,82,101,113,117,101,115,116]),t=>{h(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 o[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(){o[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 o=a[m([115,112,108,105,116])](m([46])),[i,s,r]=o;return e(i),await n(i,s,r),t}catch{return!1}function e(e){const n=l(e);n&&n[m([97,108,103])]==m([69,83,50,53,54])||(t=!1)}async function n(e,n,o){const i=window[m([85,105,110,116,56,65,114,114,97,121])][m([102,114,111,109])](u(o),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])+n),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])])?n/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:n}=new URL(window[m([108,111,99,97,116,105,111,110])].href);if(e[m([105,110,99,108,117,100,101,115])](n))return!0;const o=n[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])]<=o[m([108,101,110,103,116,104])])[m([109,97,112])](t=>Array(o[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=>o[m([101,118,101,114,121])]((e,n)=>t[n]===e||t[n]===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&&h?new(window[m([80,114,111,109,105,115,101])])((t,n)=>{e[m([116,104,101,110])](t,n),h[m([116,104,101,110])](e=>{e!=m([86,97,108,105,100])&&t(e)},n)}):e||h||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:n,model:o}=this.editor,i=e.get(f).getFootnote(t);return!!i&&(o.change(t=>{t.setSelection(t.createPositionAt(i.definition,"end"))}),n.view.scrollToTheSelection(),!0)}_moveSelectionToFootnoteReference(t){const{plugins:e,editing:n,model:o}=this.editor,i=e.get(f).getFootnote(t);return!!i&&(o.change(t=>{t.setSelection(i.reference,"on")}),n.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:n,editing:o}=t,{t:i}=t.locale;n.for("upcast").elementToElement({view:{name:"sup",classes:"footnote"},model:(t,{writer:e,consumable:n})=>{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;n.consume(i,{name:!0,attributes:["href"]});for(const{item:t}of o.view.createRangeIn(i))t.is("$textProxy")?n.consume(t.textNode,{name:!0}):t.is("element")&&n.consume(t,{name:!0});return e.createElement("footnoteRef",{footnoteId:r})}}),n.for("dataDowncast").elementToElement({model:{name:"footnoteRef",attributes:["footnoteId","footnoteCounter"]},view:(t,{writer:e})=>E(t,e)}),n.for("editingDowncast").elementToElement({model:{name:"footnoteRef",attributes:["footnoteId","footnoteCounter"]},view:(t,{writer:n})=>{const o=t.getAttribute("footnoteCounter");return(0,e.toWidget)(E(t,n),n,{label:i("Footnote %0. Press ENTER to jump to footnote definition.",o)})}})}_defineDefinitionsConverters(){const{editor:t}=this,{t:n}=t.locale,{conversion:o}=t;o.for("upcast").elementToElement({view:{name:"div",classes:"footnotes"},model:"footnotesDefinitions"}),o.for("upcast").add(t=>{t.on("element:ol",(t,e,n)=>{const o=e.viewItem;if(!o.hasClass("footnotes-list")||!e.modelCursor.parent?.is("element","footnotesDefinitions"))return;if(!n.consumable.consume(o,{name:!0,classes:"footnotes-list"}))return;const{modelRange:i,modelCursor:s}=n.convertChildren(e.viewItem,e.modelCursor);e.modelRange=i,e.modelCursor=s}),t.on("element:hr",(t,e,n)=>{const o=e.viewItem;o.hasClass("footnotes-divider")&&e.modelCursor.parent?.is("element","footnotesDefinitions")&&n.consumable.consume(o,{name:!0,classes:"footnotes-divider"})})}),o.for("dataDowncast").elementToStructure({model:"footnotesDefinitions",view:(t,{writer:e})=>x(e)}),o.for("editingDowncast").elementToStructure({model:"footnotesDefinitions",view:(t,{writer:o})=>{const i=x(o,{"data-footnotes-list-label":n("Footnotes")}),s=(0,e.toWidget)(i,o,{hasSelectionHandle:!0,label:n("Footnotes")});return o.setCustomProperty("footnotesDefinitions",!0,s),s}})}_defineDefinitionConverters(){const{editor:t}=this,{conversion:e,locale:n}=t,o=t.config.get("footnotes.multiBlock");e.for("upcast").add(t=>{t.on("element:li",(t,e,n)=>{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(!n.consumable.test(i,{name:!0,attributes:"id",classes:"footnote-definition"}))return;const r=n.writer.createElement("footnoteDefinition",{footnoteId:i.getAttribute("id")});if(!n.safeInsert(r,e.modelCursor))return;n.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")&&(n.consumable.consume(t,{name:!0,classes:"footnote-backlink",attributes:"href"}),n.consumable.consume(t,{name:!0,classes:"footnote-content"}));if(a)if(o)n.convertChildren(a,r);else{const t=n.writer.createElement("footnoteInlineContent");n.writer.insert(t,r),n.convertChildren(a,t)}n.updateConversionResult(r,e)})}),e.for("dataDowncast").elementToStructure({model:{name:"footnoteDefinition",attributes:["footnoteId"]},view:(t,{writer:e})=>P(t,e,n,{dataPipeline:!0})}),e.for("editingDowncast").elementToStructure({model:{name:"footnoteDefinition",attributes:["footnoteId"]},view:(t,{writer:e})=>P(t,e,n)})}_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 n=t.document.differ,o=new Set;for(const t of n.getChanges()){const e="attribute"==t.type?t.range.start.parent:t.position.parent;e.is("element","footnoteDefinition")&&o.add(e)}for(const t of o.values()){const n=Array.from(t.getChildren()).filter(t=>C(t,e.mapper));for(const t of n)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 n=e.createContainerElement("span");return e.setCustomProperty("dataPipeline:transparentRendering",!0,n),n}}))}_defineKeyboardHandlers(){const{editor:t}=this,{editing:n,t:o}=t,i=t.model.document.selection;t.keystrokes.set("CTRL+Shift+D","insertFootnote"),t.accessibility.addKeystrokeInfos({keystrokes:[{label:o("Insert footnote"),keystroke:"Ctrl+Shift+D"}]}),this.listenTo(n.view.document,"enter",(t,e)=>{const n=function(t){const e=t.getSelectedElement();return e?.is("element","footnoteRef")?e:null}(i);if(n){const o=n.getAttribute("footnoteId");this._moveSelectionToFootnoteDefinition(o),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 n=!1;this.listenTo(e.view.document,"pointerdown",(t,o)=>{const{target:i}=o,s=e.view.document.selection;n=!!(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:o}=e;if(!o.is("element","a"))return;if(o.parent?.is("element","sup")&&o.parent.hasClass("footnote")&&!n)return void e.preventDefault();let i=o.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:n})=>{if(!k(e))return null;if(!t)return n.createContainerElement("span",{class:"ck-footnote-bogus-paragraph"});const o=n.createContainerElement("p");return n.setCustomProperty("dataPipeline:transparentRendering",!0,o),o}}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 n=e.toViewElement(t);return!!n&&k(t)!==n.is("element","span")}function F(t){return(0,e.isWidget)(t)&&t.is("containerElement")&&!!t.getCustomProperty("footnotesDefinitions")}function x(t,e={}){const n=t.createEmptyElement("hr",{class:"footnotes-divider"}),o=t.createContainerElement("ol",{class:"footnotes-list"},t.createSlot());return t.createContainerElement("div",{class:"footnotes",...e},[n,o])}function E(t,e){const n=t.getAttribute("footnoteId"),o=t.getAttribute("footnoteCounter"),i=e.createUIElement("a",{href:"#"+n},function(t){const e=this.toDomElement(t);return e.textContent=o,e}),s=e.createContainerElement("sup",{id:"ref-"+n,class:"footnote"},[i]);return s.getFillerOffset=()=>null,s}function P(t,n,o,{dataPipeline:i}={}){const{t:s}=o,r=t.getAttribute("footnoteId"),a=n.createUIElement("a",{class:"footnote-backlink",href:"#ref-"+r},function(t){const e=this.toDomElement(t);return e.innerText="^",e}),c=i?n.createContainerElement("div",{class:"footnote-content"}):(0,e.toWidgetEditable)(n.createEditableElement("div",{class:"footnote-content"}),n,{label:s("Footnote content.")});return n.insert(n.createPositionAt(c,0),n.createSlot()),n.createContainerElement("li",{class:"footnote-definition",id:r},[a,c])}var S=n(331);function L(){const t=["footnoteRef","change","application/ckeditor5-footnotes","init","250YPraqM","add","pluginName","toModel","dataTransfer","definition","getFootnote","create","setAttribute","_insertEmptyFootnotesDefinitionsContainer","method","_defineClipboardIntegration","selection","reduce","push","getFootnotesDefinitionsObjectElement","177133RbLFBy","toView","insert","entries","541509IeKKyu","drop","1788708GElHLs","getData","find","content","setData","append","7QXIGJe","isOfficialPlugin","footnoteDefinition","sourceEditorId","from","createElement","isPremiumPlugin","footnoteId","18ZFpxkE","getAttribute","toData","2lzvIsp","htmlProcessor","footnotesDefinitions","outputTransformation","root","createRangeIn","length","getFootnotes","get","parse","stringify","element","clipboardInput","remove","document","_handleCopyFootnotesDefinitions","editing","data","editor","end","3180528pKhVDC","contentInsertion","getFirstRange","FootnotesClipboard","5sGLTqu","1308780MmnkBY","1135388vvRbay","requires","_handlePasteFootnotesDefinitions","listenTo","17490648GMgCou"];return(L=function(){return t})()}const _=A;function A(t,e){const n=L();return(A=function(t,e){return n[t-=352]})(t,e)}!function(t){const e=A,n=t();for(;;)try{if(707097===parseInt(e(395))/1*(parseInt(e(414))/2)+-parseInt(e(397))/3+-parseInt(e(366))/4*(-parseInt(e(364))/5)+-parseInt(e(365))/6*(-parseInt(e(403))/7)+parseInt(e(360))/8*(-parseInt(e(411))/9)+-parseInt(e(375))/10*(parseInt(e(391))/11)+parseInt(e(370))/12)break;n.push(n.shift())}catch(t){n.push(n.shift())}}(L);class D extends t.Plugin{static get[_(377)](){return _(363)}static get[_(367)](){return[v,S.ClipboardPipeline]}static get[_(404)](){return!0}static get[_(409)](){return!0}[_(374)](){this[_(386)]()}[_(386)](){const t=_;this[t(355)](),this[t(368)]()}[_(355)](){const t=_,{editor:e}=this,{plugins:n,model:o}=e,i=n[t(422)](S.ClipboardPipeline),s=n[t(422)](f);this[t(369)](i,t(417),(n,i)=>{const r=t,a=function(t,e){const n=A,o=new Set;for(const{item:i}of t[n(419)](e))i.is(n(425),n(371))&&o[n(376)](i[n(412)](n(410)));return Array[n(407)](o)}(o,i[r(400)]);if(!a[r(420)])return;const c=s[r(421)](),l=a[r(388)]((t,n)=>{const o=r,i=c[o(399)](t=>t.id===n);if(i){const n=e[o(357)][o(392)](i[o(380)],{isClipboardPipeline:!0}),s=e[o(357)][o(415)][o(413)](n);t[i.id]=s}return t},Object[r(382)](null));i[r(379)][r(401)](r(373),JSON[r(424)](l))})}[_(368)](){const t=_,{editor:e}=this,{model:n,plugins:o}=e,{view:s}=e[t(356)],r=o[t(422)](S.ClipboardPipeline),a=o[t(422)](f);let c=null;this[t(369)](s[t(354)],t(352),(e,n)=>{const o=t,i=n[o(379)][o(398)](o(373));c=i?JSON[o(423)](i):null}),this[t(369)](r,t(361),(o,s)=>{const r=t;if(!c)return;const l=s[r(406)]===this[r(358)].id;l&&r(396)===s[r(385)]||n[r(372)](t=>{const o=r;!function(t,e){const n=A,o=[];for(const{item:i}of t[n(419)](e))i.is(n(425),n(416))&&o[n(389)](i);for(const e of o)t[n(353)](e)}(t,s[o(400)]);let u=a[o(390)]();if(!u){const e=n[o(354)][o(387)][o(362)]()[o(418)];u=a[o(384)](t,e)}const f=function(t,e,n){const s=o,r=Object[s(382)](null);for(const{item:o}of t[s(419)](e))if(o.is(s(425),s(371))){const e=o[s(412)](s(410));if(!n(e))continue;r[e]||(r[e]=(0,i.uid)()),t[s(383)](s(410),r[e],o)}return r}(t,s[o(400)],t=>!l||null!==a[o(381)](t));for(const[n,i]of Object[o(394)](c)){const s=f[n]||n,r=t[o(408)](o(405),{footnoteId:s}),a=e[o(357)][o(415)][o(392)](i),c=e[o(357)][o(378)](a,r);t[o(402)](c,r),t[o(393)](r,u,o(359))}c=null})})}}var T=n(311),V=n(355),O=n(450),N=n.n(O),R=n(774),K=n.n(R),M=n(265),j=n.n(M),B=n(410),W=n.n(B),H=n(238),U=n.n(H),z=n(14),G={attributes:{"data-cke":!0}};G.setAttributes=W(),G.insert=j().bind(null,"head"),G.domAPI=K(),G.insertStyleElement=U();N()(z.A,G);z.A&&z.A.locals&&z.A.locals;class q 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",J(t,T.ButtonView)),e.add("menuBar:insertFootnote",J(t,T.MenuBarMenuListItemButtonView)),this.licenseKey=this.editor.config.get("licenseKey");const n=this.editor;this._licenseKeyCheckInterval=setInterval(()=>{let t;for(const e in n){const o=e,i=n[o];if("footnotesLicenseKeyValid"==i||"footnotesLicenseKeyInvalid"==i||"footnotesLicenseKeyExpired"==i||"footnotesLicenseKeyDomainLimit"==i||"footnotesLicenseKeyNotAllowed"==i||"footnotesLicenseKeyEvaluationLimit"==i||"footnotesLicenseKeyTrialLimit"==i||"footnotesLicenseKeyUsageLimit"==i){delete n[o],t=i,clearInterval(this._licenseKeyCheckInterval),this._licenseKeyCheckInterval=void 0;break}}"footnotesLicenseKeyInvalid"==t&&n._showLicenseError("invalid"),"footnotesLicenseKeyExpired"==t&&n._showLicenseError("expired"),"footnotesLicenseKeyDomainLimit"==t&&n._showLicenseError("domainLimit"),"footnotesLicenseKeyNotAllowed"==t&&n._showLicenseError("featureNotAllowed","Footnotes"),"footnotesLicenseKeyEvaluationLimit"==t&&n._showLicenseError("evaluationLimit"),"footnotesLicenseKeyTrialLimit"==t&&n._showLicenseError("trialLimit"),"footnotesLicenseKeyUsageLimit"==t&&n._showLicenseError("usageLimit")},1e3)}destroy(){super.destroy(),this._licenseKeyCheckInterval&&clearInterval(this._licenseKeyCheckInterval)}}function J(t,e){const n=t.commands.get("insertFootnote");return o=>{const{t:i}=o,s=new e(o),r=s instanceof T.MenuBarMenuListItemButtonView;return s.bind("isEnabled").to(n,"isEnabled"),s.set({label:i(r?"Footnote":"Insert footnote"),icon:V.IconFootnote,tooltip:!0}),s.on("execute",()=>{n.execute(),t.editing.view.focus()}),s}}function X(){var t=["66100980Bzjsap","194IWhyjQ","1240670fvjPmo","15178FXocBZ","isOfficialPlugin","pluginName","isPremiumPlugin","8qrgUMO","16596738WZYvGZ","16FTgFDa","2179608ektjCy","1335900EfBXfL","4795098ypJpqB","Footnotes","requires"];return(X=function(){return t})()}var Y=Q;function Q(t,e){var n=X();return(Q=function(t,e){return n[t-=384]})(t,e)}!function(t){for(var e=Q,n=t();;)try{if(923568===parseInt(e(394))/1*(-parseInt(e(396))/2)+-parseInt(e(388))/3+parseInt(e(385))/4*(-parseInt(e(395))/5)+parseInt(e(389))/6+parseInt(e(390))/7*(-parseInt(e(387))/8)+-parseInt(e(386))/9+parseInt(e(393))/10)break;n.push(n.shift())}catch(t){n.push(n.shift())}}(X);class Z extends t.Plugin{static get[Y(398)](){return Y(391)}static get[Y(392)](){return[v,D,q]}static get[Y(397)](){return!0}static get[Y(384)](){return!0}}const $=tt;function tt(t,e){const n=nt();return(tt=function(t,e){return n[t-=312]})(t,e)}!function(t){const e=tt,n=t();for(;;)try{if(905200===parseInt(e(314))/1*(-parseInt(e(316))/2)+-parseInt(e(320))/3*(-parseInt(e(327))/4)+parseInt(e(313))/5+-parseInt(e(326))/6*(-parseInt(e(328))/7)+parseInt(e(323))/8+-parseInt(e(329))/9+-parseInt(e(312))/10)break;n.push(n.shift())}catch(t){n.push(n.shift())}}(nt);const et=[$(324),$(322),$(317),$(315),$(325),$(321),$(319),$(318)];function nt(){const t=["47812900OSYHGh","8963865JGRJoK","1BBfiMu","upper-latin","563924JfNyNl","lower-latin","upper-roman","lower-roman","123NhNyOa","upper-alpha","decimal-leading-zero","12208232ONvRnW","decimal","lower-alpha","3972AXRhae","122756fzBFJK","14777kACtLJ","54729jQRLuX"];return(nt=function(){return t})()}function ot(t,e){const n=rt();return(ot=function(t,e){return n[t-=103]})(t,e)}const it=ot;!function(t){const e=ot,n=t();for(;;)try{if(338038===-parseInt(e(112))/1*(-parseInt(e(120))/2)+parseInt(e(124))/3*(parseInt(e(116))/4)+parseInt(e(117))/5+-parseInt(e(108))/6*(parseInt(e(110))/7)+parseInt(e(107))/8*(parseInt(e(104))/9)+parseInt(e(127))/10*(parseInt(e(114))/11)+parseInt(e(113))/12*(-parseInt(e(111))/13))break;n.push(n.shift())}catch(t){n.push(n.shift())}}(rt);class st extends t.Command{[it(115)](){const t=it,{editor:e}=this,n=e[t(128)][t(103)](f)[t(119)]();this[t(129)]=!!n,this[t(106)]=n?.[t(121)](t(109))??null}[it(125)]({value:t}){const e=it,{editor:n}=this,o=n[e(128)][e(103)](f),i=o[e(119)]();i&&et[e(105)](t)&&n[e(126)][e(123)](n=>{const s=e;n[s(118)](s(109),t,i),o[s(122)](n)})}}function rt(){const t=["setAttribute","getFootnotesDefinitionsObjectElement","1762zrTWxb","getAttribute","_updateFootnotesCounters","change","3LrysiA","execute","model","80AIJCtp","plugins","isEnabled","get","9inFGLB","includes","value","2101352hxKkGk","48666gRhubM","footnotesListStyle","483uwWDhL","5306717mAxXLU","181zCtGpq","24ZyOvLy","547492jwxlDq","refresh","2286784sHXgvZ","1610565kCVGdu"];return(rt=function(){return t})()}const at=lt;function ct(){const t=["997232OPIQwJ","model","refresh","value","execute","isInteger","setAttribute","9123kVUDjB","8370187QDuCGI","plugins","2733564dpFPxh","change","getFootnotesDefinitionsObjectElement","2186822ezPzYG","isEnabled","_updateFootnotesCounters","30FeiMzu","6sCtjil","getAttribute","footnotesListStart","20856LOPMIP","25UgJMMC","190068imFpwz","576dskTHt","get"];return(ct=function(){return t})()}function lt(t,e){const n=ct();return(lt=function(t,e){return n[t-=100]})(t,e)}!function(t){const e=lt,n=t();for(;;)try{if(748855===parseInt(e(111))/1+parseInt(e(104))/2+parseInt(e(114))/3+parseInt(e(101))/4*(-parseInt(e(100))/5)+-parseInt(e(121))/6*(parseInt(e(112))/7)+-parseInt(e(124))/8*(-parseInt(e(102))/9)+-parseInt(e(120))/10*(-parseInt(e(117))/11))break;n.push(n.shift())}catch(t){n.push(n.shift())}}(ct);class ut extends t.Command{[at(106)](){const t=at,{editor:e}=this,n=e[t(113)][t(103)](f)[t(116)]();this[t(118)]=!!n,this[t(107)]=n?.[t(122)](t(123))??null}[at(108)]({value:t}){const e=at,{editor:n}=this,o=n[e(113)][e(103)](f),i=o[e(116)]();i&&Number[e(109)](t)&&n[e(105)][e(115)](n=>{const s=e;n[s(110)](s(123),t,i),o[s(119)](n)})}}function ft(t,e){const n=yt();return(ft=function(t,e){return n[t-=107]})(t,e)}const dt=ft;!function(t){const e=ft,n=t();for(;;)try{if(988352===parseInt(e(130))/1*(-parseInt(e(207))/2)+parseInt(e(182))/3+-parseInt(e(189))/4+parseInt(e(194))/5*(-parseInt(e(164))/6)+parseInt(e(204))/7+parseInt(e(153))/8*(parseInt(e(198))/9)+parseInt(e(183))/10)break;n.push(n.shift())}catch(t){n.push(n.shift())}}(yt);class pt extends t.Plugin{static get[dt(126)](){return dt(150)}static get[dt(172)](){return[v,f]}static get[dt(166)](){return!0}static get[dt(114)](){return!0}[dt(157)](){const t=dt,{editor:e}=this;e[t(169)][t(127)](t(196),t(136)),e[t(169)][t(127)](t(132),1),e[t(167)][t(181)](t(191),new st(e)),e[t(167)][t(181)](t(162),new ut(e)),this[t(158)](),this[t(145)](),this[t(177)](),this[t(175)]()}[dt(158)](){const t=dt,{editor:e}=this,{schema:n}=e[t(174)];n[t(193)](t(188),{allowAttributes:[t(197),t(165)]})}[dt(145)](){const t=dt,{editor:e}=this,{conversion:n,model:o}=e,{schema:i}=o;n[t(163)](t(179))[t(181)](e=>{const n=t;e.on(n(141),(t,e,o)=>{const s=n,r=e[s(187)],a=e[s(168)]?.[s(178)];r[s(116)](s(121))&&a?.is(s(195),s(188))&&(function(t,e,n,o){const i=s;if(!o[i(115)](e,i(165)))return;let r=1;const a=n[i(122)][i(152)](t,{attributes:i(201)});if(a){const e=Number[i(111)](t[i(200)](i(201)),10);Number[i(203)](e)||(r=e)}!a&&e[i(147)](i(165))||n[i(112)][i(173)](i(165),r,e)}(r,a,o,i),function(t,e,n,o){const i=s;if(!o[i(115)](e,i(197)))return;let r=i(136),a=!1;if(n[i(122)][i(152)](t,{attributes:i(113)})){const e={1:i(136),a:i(154),A:i(160),i:i(176),I:i(148)}[t[i(200)](i(113))];e&&(r=e),a=!0}n[i(122)][i(152)](t,{styles:i(119)})&&(r=t[i(159)](i(119)),a=!0),!a&&e[i(147)](i(197))||n[i(112)][i(173)](i(197),r,e)}(r,a,o,i))})}),n[t(163)](t(144))[t(181)](e=>{const n=t;e.on(n(133),(t,e,o)=>{const i=n;if(!o[i(122)][i(152)](e[i(124)],t[i(120)]))return;const s=ht(e[i(124)],o[i(170)]),{attributeNewValue:r}=e;null==r||1===r?o[i(112)][i(131)](i(201),s):o[i(112)][i(173)](i(201),String(r),s)}),e.on(n(206),(t,e,o)=>{const i=n;if(!o[i(122)][i(152)](e[i(124)],t[i(120)]))return;const s=ht(e[i(124)],o[i(170)]),{attributeNewValue:r}=e;r&&i(136)!==r?o[i(112)][i(143)](i(119),r,s):o[i(112)][i(125)](i(119),s)})})}[dt(175)](){const t=dt,{editor:e}=this,{model:n}=e,o=e[t(134)][t(156)](f),i=this[t(140)](),s=this[t(139)]();n[t(184)][t(205)](e=>{const r=t,a=n[r(184)][r(107)][r(129)]();let c=!1;for(const t of a){if(r(151)!==t[r(113)]||r(146)===t[r(120)])continue;const o=n[r(180)](t[r(155)][r(142)]);for(const t of o[r(128)]())t.is(r(195),r(188))&&(!t[r(147)](r(165))&&n[r(138)][r(115)](t,r(165))&&(e[r(173)](r(165),s,t),c=!0),!t[r(147)](r(197))&&n[r(138)][r(115)](t,r(197))&&(e[r(173)](r(197),i,t),c=!0))}return c&&o[r(161)](e),c})}[dt(177)](){const t=dt,{editor:e}=this;e[t(134)][t(156)](f)[t(118)](e=>this[t(199)](e))}[dt(140)](){const t=dt;return this[t(108)][t(169)][t(156)](t(196))}[dt(139)](){const t=dt;return this[t(108)][t(169)][t(156)](t(132))}[dt(199)]({container:t,value:e,digits:n}){const o=dt,i=t[o(200)](o(197)),s=t[o(200)](o(165)),r=Math[o(117)](e)+(s??1)-1;switch(i){case o(110):return function(t,e){const n=o;return String(t)[n(137)](e,"0")}(r,Math[o(186)](2,n));case o(154):case o(109):return mt(r,!1);case o(160):case o(192):return mt(r,!0);case o(176):return wt(r,!1);case o(148):return wt(r,!0);default:return String(r)}}}function ht(t,e){const n=dt,o=e[n(135)](t);return Array[n(149)](o[n(190)]())[n(202)](t=>t.is(n(195),"ol")&&t[n(116)](n(121)))}function mt(t,e){const n=dt;let o="",i=t;for(;i>0;){const t=(i-1)%26;o=String[n(185)](97+t)+o,i=Math[n(117)]((i-1)/26)}return e?o[n(171)]():o}const gt=[{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 wt(t,e){const n=dt;let o="",i=t;for(const{value:t,numeral:e}of gt)for(;i>=t;)o+=e,i-=t;return e?o:o[n(123)]()}function yt(){const t=["_updateFootnotesCounters","footnotesStart","for","2966982eGorjt","footnotesListStart","isOfficialPlugin","commands","modelCursor","config","mapper","toUpperCase","requires","setAttribute","model","_definePostfixer","lower-roman","_defineFormatter","parent","upcast","createRangeOn","add","1101243qMLkOc","9845080NXcPgd","document","fromCharCode","max","viewItem","footnotesDefinitions","249632kSJIct","getChildren","footnotesStyle","upper-latin","extend","10quEYBW","element","footnotes.footnotesProperties.defaultListStyle","footnotesListStyle","9UaYfGM","_formatFootnoteListValue","getAttribute","start","find","isNaN","7643706yAeQSo","registerPostFixer","attribute:footnotesListStyle:footnotesDefinitions","3234vmpvoH","differ","editor","lower-latin","decimal-leading-zero","parseInt","writer","type","isPremiumPlugin","checkAttribute","hasClass","floor","setFootnoteFormatter","list-style-type","name","footnotes-list","consumable","toLowerCase","item","removeStyle","pluginName","define","getItems","getChanges","917ErqQcF","removeAttribute","footnotes.footnotesProperties.defaultStartIndex","attribute:footnotesListStart:footnotesDefinitions","plugins","toViewElement","decimal","padStart","schema","_getDefaultStartIndex","_getDefaultListStyle","element:ol","nodeAfter","setStyle","downcast","_defineConverters","$text","hasAttribute","upper-roman","from","FootnotesPropertiesEditing","insert","consume","8631968GLikEL","lower-alpha","position","get","init","_defineSchema","getStyle","upper-alpha"];return(yt=function(){return t})()}class bt extends T.View{children;stylesView=null;additionalProperties=null;startIndexFieldView=null;focusTracker=new i.FocusTracker;keystrokes=new i.KeystrokeHandler;focusables=new T.ViewCollection;focusCycler;constructor(t,{styleButtonViews:e,styleGridAriaLabel:n}){super(t),this.focusCycler=new T.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,n),[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,T.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 n=new T.View(this.locale);return n.children=n.createCollection(),n.children.addMany(t),n.setTemplate({tag:"div",attributes:{"aria-label":e,class:["ck","ck-footnotes-definitions-styles-list"]},children:n.children}),n.children.delegate("execute").to(this),n.focus=function(){for(const t of this.children)if(t instanceof T.ButtonView&&t.isOn)return void t.focus();this.children.first.focus()},n.focusTracker=new i.FocusTracker,n.keystrokes=new i.KeystrokeHandler,n.render(),n.keystrokes.listenTo(n.element),this.children.add(n),n}_appendAdditionalPropertiesCollapsibleView(){const{t}=this.locale,e=this._createStartIndexPropertyView(),n=[e],o=new T.CollapsibleView(this.locale,n);return o.set({label:t("Footnotes properties"),isCollapsed:!0}),o.buttonView.bind("isEnabled").toMany(n,"isEnabled",(...t)=>t.some(t=>t)),o.buttonView.on("change:isEnabled",(t,e,n)=>{n||(o.isCollapsed=!0)}),this.children.add(o),[e,o]}_createStartIndexPropertyView(){const{t}=this.locale,e=new T.LabeledFieldView(this.locale,T.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 n=e.fieldView.element,o=n.valueAsNumber;Number.isNaN(o)?e.errorText=t("Invalid footnotes start index value."):n.checkValidity()?this.fire("footnotesListStart",{startIndex:o}):e.errorText=t(o<0?"Footnotes start index must be greater than 0.":"Footnotes start index is too large.")}),e}}var vt=n(945),It={attributes:{"data-cke":!0}};It.setAttributes=W(),It.insert=j().bind(null,"head"),It.domAPI=K(),It.insertStyleElement=U();N()(vt.A,It);vt.A&&vt.A.locals&&vt.A.locals;class kt extends t.Plugin{static get pluginName(){return"FootnotesPropertiesUI"}static get requires(){return[T.ContextualBalloon,e.WidgetToolbarRepository]}static get isOfficialPlugin(){return!0}static get isPremiumPlugin(){return!0}init(){const{editor:t}=this,{componentFactory:e}=t.ui;var n;t.config.define("footnotes.footnotesProperties.toolbar",["footnotesStyle"]),e.add("footnotesStyle",(n=t,t=>{const{t:e}=t,o=n.commands.get("footnotesStyle"),i=(0,T.createDropdown)(t),{buttonView:s}=i;return i.class="ck-footnotes-styles-dropdown",i.bind("isEnabled").to(o,"isEnabled"),s.set({label:e("Footnotes style"),icon:V.IconFootnote,tooltip:!0}),i.once("change:isOpen",()=>{const t=function({editor:t,dropdownView:e}){const{t:n}=t.locale,o=n("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:V.IconListStyleDecimal},{label:e("Toggle the decimal with leading zero footnotes style"),tooltip:e("Decimal footnotes with leading zero"),style:"decimal-leading-zero",icon:V.IconListStyleDecimalLeadingZero},{label:e("Toggle the lower–roman footnotes style"),tooltip:e("Lower–roman footnotes"),style:"lower-roman",icon:V.IconListStyleLowerRoman},{label:e("Toggle the upper–roman footnotes style"),tooltip:e("Upper-roman footnotes"),style:"upper-roman",icon:V.IconListStyleUpperRoman},{label:e("Toggle the lower–latin footnotes style"),tooltip:e("Lower-latin footnotes"),style:"lower-latin",icon:V.IconListStyleLowerLatin},{label:e("Toggle the upper–latin footnotes style"),tooltip:e("Upper-latin footnotes"),style:"upper-latin",icon:V.IconListStyleUpperLatin}].map(function(t){const e=t.locale;return({label:n,icon:o,tooltip:i,style:s})=>{const r=t.commands.get("footnotesStyle"),a=new T.ButtonView(e);return a.set({label:n,icon:o,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 bt(t.locale,{styleGridAriaLabel:o,styleButtonViews:i});return s.delegate("execute").to(e),s.on("footnotesListStart",(e,n)=>{t.execute("footnotesStart",{value:n.startIndex})}),s}({editor:n,dropdownView:i});i.panelView.children.add(t)}),i}))}afterInit(){const{editor:t}=this,{t:n}=t.locale,o=t.plugins.get(e.WidgetToolbarRepository),{defaultPositions:i}=T.BalloonPanelView;o.register("footnotesDefinitions",{ariaLabel:n("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 Ct=xt;function Ft(){var t=["11382160fQJjVk","1576280ATzsgW","85qcJZAZ","5062748efImma","3HaOTsO","9987502QqLyPD","pluginName","FootnotesProperties","isOfficialPlugin","requires","1152FFwlji","98244eokYBy","isPremiumPlugin","80176JVSBXk","23162ROramW"];return(Ft=function(){return t})()}function xt(t,e){var n=Ft();return(xt=function(t,e){return n[t-=150]})(t,e)}!function(t){for(var e=xt,n=t();;)try{if(804385===parseInt(e(163))/1+parseInt(e(150))/2+-parseInt(e(153))/3*(-parseInt(e(152))/4)+parseInt(e(151))/5*(-parseInt(e(160))/6)+parseInt(e(154))/7+-parseInt(e(162))/8*(parseInt(e(159))/9)+-parseInt(e(164))/10)break;n.push(n.shift())}catch(t){n.push(n.shift())}}(Ft);class Et extends t.Plugin{static get[Ct(155)](){return Ct(156)}static get[Ct(158)](){return[pt,kt]}static get[Ct(157)](){return!0}static get[Ct(161)](){return!0}}function Pt(){var t=["390590uJMbHN","1143498VWcrDb","817267yTspHo","6767109uTILeX","7voykNY","2976135EkSEQk","4763364TwTtlW","10678200wHHoaB","108QXYgXR"];return(Pt=function(){return t})()}function St(t,e){var n=Pt();return(St=function(t,e){return n[t-=365]})(t,e)}!function(t){for(var e=St,n=t();;)try{if(869972===parseInt(e(372))/1+-parseInt(e(371))/2+parseInt(e(366))/3+-parseInt(e(367))/4+-parseInt(e(370))/5*(-parseInt(e(369))/6)+parseInt(e(365))/7*(-parseInt(e(368))/8)+parseInt(e(373))/9)break;n.push(n.shift())}catch(t){n.push(n.shift())}}(Pt)})(),(window.CKEditor5=window.CKEditor5||{}).footnotes=o})();
|
package/dist/index.js
CHANGED
|
@@ -20,4 +20,4 @@
|
|
|
20
20
|
*
|
|
21
21
|
*
|
|
22
22
|
*/
|
|
23
|
-
import{Plugin as _0x455464,Command as _0x55ead5}from'@ckeditor/ckeditor5-core/dist/index.js';import{toWidget as _0x1a1d9c,isWidget as _0x1899ef,toWidgetEditable as _0xad70b7,WidgetToolbarRepository as _0x4ed730}from'@ckeditor/ckeditor5-widget/dist/index.js';import{uid as _0x193af1,logWarning as _0x506bf5,FocusTracker as et,KeystrokeHandler as ot,global as rt}from'@ckeditor/ckeditor5-utils/dist/index.js';import{PointerObserver as _0x1e3809,ClickObserver as _0x4bd884}from'@ckeditor/ckeditor5-engine/dist/index.js';import{ClipboardPipeline as _0x5e02c7}from'@ckeditor/ckeditor5-clipboard/dist/index.js';import{MenuBarMenuListItemButtonView as _0x2f467e,ButtonView as _0x3fc837,View as _0x16ec18,ViewCollection as _0x24d7eb,FocusCycler as _0x3fac62,addKeyboardHandlingForGrid as _0x30afc3,CollapsibleView as tt,LabeledFieldView as st,createLabeledInputNumber as it,ContextualBalloon as _0x58e7ed,BalloonPanelView as _0x4f2f53,createDropdown as _0x25312a}from'@ckeditor/ckeditor5-ui/dist/index.js';import{IconFootnote as _0x28343b,IconListStyleDecimal as _0x2fe3d9,IconListStyleDecimalLeadingZero as _0xfa77b3,IconListStyleLowerRoman as _0x56fe8c,IconListStyleUpperRoman as _0x2c3adb,IconListStyleLowerLatin as _0x20b999,IconListStyleUpperLatin as _0x4c7353}from'@ckeditor/ckeditor5-icons/dist/index.js';class F{['_model'];['_elementName'];['_getElementKey'];['_trackedElements']=new Map();constructor(_0x5dd4a4,_0x3e2910){this['_model']=_0x5dd4a4,this['_elementName']=_0x3e2910['elementName'],this['_getElementKey']=_0x3e2910['getElementKey'];}['reset'](){this['_trackedElements']['clear']();}['getChanges'](_0x1db99d){const _0x88cd2=new Set(),_0xdef548=new Map();for(const _0x315e9a of _0x1db99d){if('insert'===_0x315e9a['type']&&'$text'!==_0x315e9a['name']&&_0x315e9a['position']['nodeAfter']){const _0x382697=this['_model']['createRangeOn'](_0x315e9a['position']['nodeAfter']);for(const _0x4f55dd of _0x382697['getItems']()){if(!_0x4f55dd['is']('element',this['_elementName']))continue;const _0x444606=this['_getElementKey'](_0x4f55dd);_0xdef548['has'](_0x444606)||_0xdef548['set'](_0x444606,[]),_0xdef548['get'](_0x444606)['push'](_0x4f55dd);}}if('remove'===_0x315e9a['type']&&_0x315e9a['name']===this['_elementName']){const _0x4d2b7b=this['_getElementKey']({'getAttribute':_0xd6a87b=>_0x315e9a['attributes']['get'](_0xd6a87b)});_0x88cd2['add'](_0x4d2b7b);}}for(const [_0x3e8905,_0x5a9055]of this['_trackedElements'])'$graveyard'===_0x5a9055['root']['rootName']&&_0x88cd2['add'](_0x3e8905);for(const _0x9cf9a7 of _0x88cd2)this['_trackedElements']['delete'](_0x9cf9a7);for(const [_0x37ba7d,_0x17f5f6]of _0xdef548)this['_trackedElements']['set'](_0x37ba7d,_0x17f5f6[_0x17f5f6['length']-0x1]);const _0x57f870=new Set();for(const [_0x23b706,_0x4e0109]of _0xdef548)_0x88cd2['has'](_0x23b706)&&(_0x57f870['add'](_0x4e0109[0x0]),_0x4e0109['length']>0x1?_0xdef548['set'](_0x23b706,_0x4e0109['slice'](0x1)):_0xdef548['delete'](_0x23b706),_0x88cd2['delete'](_0x23b706));return{'removed':Array['from'](_0x88cd2),'inserted':Array['from'](_0xdef548['values']())['flat'](),'moved':Array['from'](_0x57f870)};}}class c extends _0x455464{['_footnotes']=[];['_footnotesDefinitions']=null;['_footnoteFormatter']=null;['_footnoteDefsContainerTracker'];['_footnoteRefsTracker'];['_footnoteDefsTracker'];static get['pluginName'](){return'FootnotesTracker';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x17b1e5){super(_0x17b1e5),this['_footnoteDefsContainerTracker']=new F(this['editor']['model'],{'elementName':'footnotesDefinitions','getElementKey':()=>'singleton'}),this['_footnoteRefsTracker']=new F(this['editor']['model'],{'elementName':'footnoteRef','getElementKey':_0x5767a5=>_0x5767a5['getAttribute']('footnoteId')}),this['_footnoteDefsTracker']=new F(this['editor']['model'],{'elementName':'footnoteDefinition','getElementKey':_0x32ea99=>_0x32ea99['getAttribute']('footnoteId')});}['init'](){const {editor:_0x436c20}=this,{model:_0x33ef80,data:_0x2c789f}=_0x436c20;_0x33ef80['document']['registerPostFixer'](_0x583b63=>{const _0x5be11a=_0x33ef80['document']['differ']['getChanges']();let _0x15fad8=!0x1;return this['_handleFootnotesDefinitionsObjectChanges'](_0x583b63,_0x5be11a)&&(_0x15fad8=!0x0),this['_handleFootnoteDefinitionsChanges'](_0x583b63,_0x5be11a)&&(_0x15fad8=!0x0),this['_handleFootnoteReferencesChanges'](_0x583b63,_0x5be11a)&&(_0x15fad8=!0x0),this['_ensureFootnotesReferencesHaveProperOrder'](_0x583b63)&&(_0x15fad8=!0x0),this['_handleFootnotesDefinitionsObjectSync'](_0x583b63)&&(_0x15fad8=!0x0),this['_sortFootnoteDefinitions'](_0x583b63)&&(_0x15fad8=!0x0),_0x15fad8;}),this['listenTo'](_0x33ef80['document'],'change:data',()=>{_0x33ef80['enqueueChange']({'isUndoable':!0x1},_0x129e01=>{this['_ensureFootnotesDefinitionsContainerExists'](_0x129e01);});},{'priority':'low'}),this['listenTo'](_0x2c789f,'set',()=>{this['_footnotes']=[],this['_footnoteDefsContainerTracker']['reset'](),this['_footnoteRefsTracker']['reset'](),this['_footnoteDefsTracker']['reset']();},{'priority':'high'});}['getFootnotesDefinitionsObjectElement'](){return this['_footnotesDefinitions'];}['getFootnote'](_0x1fd8bd){return this['_footnotes']['find'](_0xc6803a=>_0xc6803a['id']===_0x1fd8bd)||null;}['getFootnotes'](){return Array['from'](this['_footnotes']);}['getFootnotesFormatter'](){return this['_footnoteFormatter'];}['setFootnoteFormatter'](_0x13e601){this['_footnoteFormatter']=_0x13e601;}['_updateFootnotesCounters'](_0x3bb88b,_0x382192=0x0){let _0x2fd6ba=!0x1;for(let _0x1c3a4e=_0x382192;_0x1c3a4e<this['_footnotes']['length'];_0x1c3a4e++)this['_updateFootnoteRefCounter'](_0x3bb88b,_0x1c3a4e)&&(_0x2fd6ba=!0x0);return _0x2fd6ba;}['_insertEmptyFootnotesDefinitionsContainer'](_0x346c96,_0x129499){const _0x16d616=_0x346c96['createElement']('footnotesDefinitions',{});return _0x346c96['append'](_0x16d616,_0x129499),this['_footnotesDefinitions']=_0x16d616,_0x16d616;}['_ensureFootnotesDefinitionsContainerExists'](_0x4759e7){if(!this['_footnotes']['length']||this['_footnotesDefinitions'])return;const _0x654630=this['_footnotes'][0x0]['reference']['root'],_0x3f31a6=this['_insertEmptyFootnotesDefinitionsContainer'](_0x4759e7,_0x654630);for(const _0x71eca3 of this['_footnotes'])_0x71eca3['definition']['parent']||_0x4759e7['insert'](_0x71eca3['definition'],_0x3f31a6,'end');this['_updateFootnotesCounters'](_0x4759e7);}['_handleFootnotesDefinitionsObjectChanges'](_0x565c86,_0x395871){let _0x4d12d6=!0x1;const {inserted:_0x6e078,removed:_0x590d81,moved:_0x1393fe}=this['_footnoteDefsContainerTracker']['getChanges'](_0x395871);if(_0x1393fe['length']&&(this['_footnotesDefinitions']=_0x1393fe[0x0]),_0x6e078['length']){if(_0x6e078['length']>0x1||this['_footnotesDefinitions']&&_0x6e078['some'](_0x54c72c=>_0x54c72c!==this['_footnotesDefinitions'])){const _0x2f931c=_0x565c86['createElement']('footnotesDefinitions',{}),_0x17a397=[];this['_footnotesDefinitions']&&_0x17a397['push'](this['_footnotesDefinitions']),_0x17a397['push'](..._0x6e078),_0x565c86['insert'](_0x2f931c,_0x17a397[0x0],'before');for(const _0x558056 of _0x17a397)_0x565c86['move'](_0x565c86['createRangeIn'](_0x558056),_0x565c86['createPositionAt'](_0x2f931c,'end')),_0x565c86['remove'](_0x558056);this['_footnotesDefinitions']=_0x2f931c,this['_updateFootnotesCounters'](_0x565c86),_0x4d12d6=!0x0;}else this['_footnotesDefinitions']=_0x6e078[0x0];}if(_0x590d81['length']&&'$graveyard'===this['_footnotesDefinitions']?.['root']['rootName']){for(const _0x327c70 of this['_footnotes'])_0x565c86['remove'](_0x327c70['reference']),_0x4d12d6=!0x0;this['_footnotes']=[],this['_footnotesDefinitions']=null;}return _0x4d12d6;}['_handleFootnoteDefinitionsChanges'](_0x3fc42e,_0x1fc074){let _0x52bb66=!0x1;const _0x549dd4=this['editor']['config']['get']('footnotes.multiBlock'),{inserted:_0x39a799,moved:_0x4ab14a}=this['_footnoteDefsTracker']['getChanges'](_0x1fc074);for(const _0x4228ca of[..._0x4ab14a,..._0x39a799]){const _0x3827e0=_0x4228ca['getAttribute']('footnoteId'),_0x1322d4=this['getFootnote'](_0x3827e0);_0x1322d4&&(_0x1322d4['definition']=_0x4228ca),_(_0x3fc42e,_0x549dd4,_0x4228ca)&&(_0x52bb66=!0x0);}return _0x52bb66;}['_handleFootnoteReferencesChanges'](_0x2f41bc,_0x526471){let _0x4e8448=!0x1;const {removed:_0x15b4c6,inserted:_0x2cc714,moved:_0x400387}=this['_footnoteRefsTracker']['getChanges'](_0x526471);for(const _0x13ea99 of _0x15b4c6)this['_handleRemoveFootnoteReferenceById'](_0x2f41bc,_0x13ea99)&&(_0x4e8448=!0x0);for(const _0x4e7d2c of _0x2cc714)this['_handleInsertedFootnoteReference'](_0x2f41bc,_0x4e7d2c)&&(_0x4e8448=!0x0);for(const _0x422650 of _0x400387)this['_handleMovedFootnoteReference'](_0x2f41bc,_0x422650)&&(_0x4e8448=!0x0);return _0x4e8448;}['_handleFootnotesDefinitionsObjectSync'](_0x9bce22){if(!this['_footnotesDefinitions'])return!0x1;let _0x2966d0=!0x1;if(this['_footnotesDefinitions']['childCount']!==this['_footnotes']['length']){const _0x2b247c=[];for(const _0x5c5880 of this['_footnotesDefinitions']['getChildren']()){const _0x23d3ea=_0x5c5880['getAttribute']('footnoteId');this['getFootnote'](_0x23d3ea)||(_0x2b247c['unshift'](_0x5c5880),_0x2966d0=!0x0);}for(const _0x3edcc1 of _0x2b247c)_0x9bce22['remove'](_0x3edcc1);}const _0x377b21=new Set(),_0x400c7d=[];for(const _0x21ac01 of this['_footnotesDefinitions']['getChildren']()){const _0x964e62=_0x21ac01['getAttribute']('footnoteId');_0x377b21['has'](_0x964e62)?(_0x400c7d['unshift'](_0x21ac01),_0x2966d0=!0x0):_0x377b21['add'](_0x964e62);}for(const _0x1f1b72 of _0x400c7d)_0x9bce22['remove'](_0x1f1b72);return this['_footnotesDefinitions']['childCount']||(_0x9bce22['remove'](this['_footnotesDefinitions']),this['_footnotesDefinitions']=null,_0x2966d0=!0x0),_0x2966d0;}['_handleInsertedFootnoteReference'](_0x267005,_0x18be13){if(this['_footnotes']['find'](_0x340f5f=>_0x340f5f['reference']===_0x18be13))return!0x1;let _0x7879d=!0x1;const _0x30ea7f=_0x18be13['getAttribute']('footnoteId'),_0x4688ab=this['_footnotes']['findIndex'](_0x5bb9fc=>_0x5bb9fc['id']===_0x30ea7f);-0x1!==_0x4688ab&&(_0x267005['remove'](this['_footnotes'][_0x4688ab]['reference']),this['_footnotes']['splice'](_0x4688ab,0x1),_0x7879d=!0x0);let _0x533164=this['_footnotesDefinitions']?function(_0x269cb8,_0x3777b7){for(const _0x2f5855 of _0x269cb8['getChildren']())if(_0x2f5855['getAttribute']('footnoteId')===_0x3777b7)return _0x2f5855;return null;}(this['_footnotesDefinitions'],_0x30ea7f):null;_0x533164||(_0x533164=_0x267005['createElement']('footnoteDefinition',{'footnoteId':_0x30ea7f}),this['_footnotesDefinitions']&&(_0x267005['insert'](_0x533164,this['_footnotesDefinitions'],'end'),_0x7879d=!0x0));const _0x52c95c={'id':_0x30ea7f,'reference':_0x18be13,'definition':_0x533164},_0x5ac1e7=I(this['editor']['model'],this['_footnotes'],_0x18be13);this['_footnotes']['splice'](_0x5ac1e7,0x0,_0x52c95c);let _0x286eaf=_0x5ac1e7;return-0x1!==_0x4688ab&&(_0x286eaf=Math['min'](_0x5ac1e7,_0x4688ab)),this['_updateFootnotesCounters'](_0x267005,_0x286eaf)&&(_0x7879d=!0x0),_0x7879d;}['_handleRemoveFootnoteReferenceById'](_0x1d4eb3,_0x3e03b3){const _0x4644b7=this['_footnotes']['findIndex'](_0x355138=>_0x355138['id']===_0x3e03b3);if(-0x1===_0x4644b7)return!0x1;let _0x4ea80d=!0x1;const _0x2ddc28=this['_footnotes'][_0x4644b7];return'$graveyard'!==_0x2ddc28['definition']['root']['rootName']&&(_0x1d4eb3['remove'](_0x2ddc28['definition']),_0x4ea80d=!0x0),this['_footnotes']['splice'](_0x4644b7,0x1),this['_updateFootnotesCounters'](_0x1d4eb3,_0x4644b7)&&(_0x4ea80d=!0x0),_0x4ea80d;}['_handleMovedFootnoteReference'](_0xc3dbdb,_0x26a63d){const _0x532f84=_0x26a63d['getAttribute']('footnoteId'),_0x472125=this['_footnotes']['findIndex'](_0x809d26=>_0x809d26['id']===_0x532f84),_0x1cb466=this['_footnotes'][_0x472125];let _0x55117b=!0x1;_0x1cb466['reference']=_0x26a63d,this['_footnotes']['splice'](_0x472125,0x1);const _0x2b626e=I(this['editor']['model'],this['_footnotes'],_0x26a63d);return this['_footnotes']['splice'](_0x2b626e,0x0,_0x1cb466),this['_updateFootnotesCounters'](_0xc3dbdb,Math['min'](_0x472125,_0x2b626e))&&(_0x55117b=!0x0),_0x55117b;}['_updateFootnoteRefCounter'](_0x489b83,_0x3e54ad){if(!this['_footnotesDefinitions'])return!0x1;const _0x2c4878=this['_footnotes'][_0x3e54ad];let _0x19bc36;return _0x19bc36=this['_footnoteFormatter']?this['_footnoteFormatter']({'footnote':_0x2c4878,'container':this['_footnotesDefinitions'],'digits':String(this['_footnotes']['length'])['length'],'value':_0x3e54ad+0x1}):String(_0x3e54ad+0x1),_0x2c4878['reference']['getAttribute']('footnoteCounter')!=_0x19bc36&&(_0x489b83['setAttribute']('footnoteCounter',_0x19bc36,_0x2c4878['reference']),!0x0);}['_sortFootnoteDefinitions'](_0x276d80){if(!this['_footnotesDefinitions']||this['_footnotes']['length']<0x2)return!0x1;if(function(_0x17c380,_0x4f6ae5){if(_0x17c380['length']!==_0x4f6ae5['length'])return!0x1;for(let _0x1c2d1b=0x0;_0x1c2d1b<_0x17c380['length'];_0x1c2d1b++)if(_0x17c380[_0x1c2d1b]!==_0x4f6ae5[_0x1c2d1b])return!0x1;return!0x0;}(this['_footnotes']['map'](_0x465d1b=>_0x465d1b['id']),Array['from'](this['_footnotesDefinitions']['getChildren']())['map'](_0x6f709d=>_0x6f709d['getAttribute']('footnoteId'))))return!0x1;let _0x17b944=!0x1;for(let _0x1176cd=0x0;_0x1176cd<this['_footnotes']['length'];_0x1176cd++){const _0x447806=this['_footnotes'][_0x1176cd],_0x2712a4=_0x276d80['createPositionBefore'](_0x447806['definition']),_0x501571=_0x276d80['createPositionAt'](this['_footnotesDefinitions'],_0x1176cd);_0x2712a4['isEqual'](_0x501571)||(_0x276d80['move'](_0x276d80['createRangeOn'](_0x447806['definition']),_0x501571),_0x17b944=!0x0);}return _0x17b944;}['_ensureFootnotesReferencesHaveProperOrder'](_0x3c6a3b){if(!this['_footnotes']['length'])return!0x1;const {model:_0x3047f1}=this['editor'];let _0x285310=!0x1;for(let _0x12c04f=0x0;_0x12c04f<this['_footnotes']['length']-0x1;_0x12c04f++){const _0x4312a2=this['_footnotes'][_0x12c04f],_0x1b0e36=this['_footnotes'][_0x12c04f+0x1],_0x4654f0=_0x3047f1['createPositionBefore'](_0x4312a2['reference']),_0x35bd41=_0x3047f1['createPositionBefore'](_0x1b0e36['reference']);'after'===_0x4654f0['compareWith'](_0x35bd41)&&(this['_handleMovedFootnoteReference'](_0x3c6a3b,_0x4312a2['reference']),_0x12c04f=-0x1,_0x285310=!0x0);}return _0x285310;}}function _(_0x2d0e18,_0x4705cb,_0x2f5c93){if(_0x2f5c93['childCount'])return!0x1;const _0x230218=_0x4705cb?'paragraph':'footnoteInlineContent';return _0x2d0e18['insert'](_0x2d0e18['createElement'](_0x230218),_0x2f5c93),!0x0;}function I(_0x14ffda,_0x3a9904,_0x182b6f){if(0x0===_0x3a9904['length'])return 0x0;const _0x325abd=_0x14ffda['createPositionBefore'](_0x182b6f);for(let _0x1c54fa=0x0;_0x1c54fa<_0x3a9904['length'];_0x1c54fa++){const _0x490519=_0x3a9904[_0x1c54fa],_0x3a8aa4=_0x14ffda['createPositionBefore'](_0x490519['reference']);if('before'===_0x325abd['compareWith'](_0x3a8aa4))return _0x1c54fa;}const _0x55bf47=_0x182b6f['root'];let _0x5ee60f=-0x1;for(let _0x1d4d51=_0x3a9904['length']-0x1;_0x1d4d51>=0x0;_0x1d4d51--)if(_0x3a9904[_0x1d4d51]['reference']['root']===_0x55bf47){_0x5ee60f=_0x1d4d51;break;}if(-0x1!==_0x5ee60f)return _0x5ee60f+0x1;const _0x14d759=_0x14ffda['document']['getRootNames'](),_0x1cb8c0=_0x14d759['indexOf'](_0x55bf47['rootName']),_0x20a3bf=_0x14d759[_0x1cb8c0+0x1];if(_0x20a3bf){for(let _0x232a25=0x0;_0x232a25<_0x3a9904['length'];_0x232a25++)if(_0x3a9904[_0x232a25]['reference']['root']['rootName']===_0x20a3bf)return _0x232a25;}return _0x3a9904['length'];}class w extends _0x55ead5{['refresh'](){const _0x1903b2=this['editor']['model']['document']['selection'],_0xf9d889=this['_getPositionToInsertFootnote'](_0x1903b2);this['isEnabled']=!!_0xf9d889;}['execute'](_0x59ffed){const {editor:_0x6dd101}=this,{model:_0x5e0c86}=_0x6dd101,{selection:_0x427f7d}=_0x5e0c86['document'],_0x2eae69=this['_getPositionToInsertFootnote'](_0x427f7d);if(!_0x2eae69)return;const _0x119c74=_0x6dd101['plugins']['get']('FootnotesEditing'),_0x5b3f14=_0x59ffed?.['footnoteId']??_0x193af1();!function(_0x345a0f){return'string'==typeof _0x345a0f&&_0x345a0f['length']>0x0&&!/\s/['test'](_0x345a0f)&&!/^\d/['test'](_0x345a0f);}(_0x5b3f14)?_0x506bf5('insert-footnote-command-executed-with-invalid-id'):(_0x5e0c86['change'](_0x339efd=>{const _0x792f17=_0x339efd['createElement']('footnoteRef',{'footnoteId':_0x5b3f14});_0x5e0c86['insertObject'](_0x792f17,_0x2eae69,null);}),_0x119c74['_moveSelectionToFootnoteDefinition'](_0x5b3f14));}['_getPositionToInsertFootnote'](_0x29d70a){const {model:_0x42b94c}=this['editor'],{schema:_0x22d32d}=_0x42b94c,_0x850313=_0x29d70a['getFirstRange']();for(const _0xa88d15 of _0x850313['getItems']())if(_0x22d32d['isBlock'](_0xa88d15)||_0x22d32d['isObject'](_0xa88d15))return null;const _0xc4b61=_0x850313['end'];return _0x22d32d['checkChild'](_0xc4b61,'footnoteRef')?_0xc4b61:null;}}class r extends _0x455464{static get['pluginName'](){return'FootnotesEditing';}static get['requires'](){return[c];}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['init'](){const {editor:_0x32259d}=this;_0x32259d['config']['define']('footnotes.multiBlock',!0x0),_0x32259d['commands']['add']('insertFootnote',new w(_0x32259d)),this['_defineSchema'](),this['_defineRefsConverters'](),this['_defineDefinitionsConverters'](),this['_defineDefinitionConverters'](),this['_defineBogusParagraphConverters'](),this['_defineKeyboardHandlers'](),this['_defineClickHandlers']();}['afterInit'](){!async function(_0x59df0a){const _0x20b26b=_0x49da89([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]),_0x2596a1=0x47a28506,_0x4af3f4=0x47a5f2f6^_0x2596a1,_0x38c8d2=window[_0x49da89([0x44,0x61,0x74,0x65])][_0x49da89([0x6e,0x6f,0x77])](),_0x537bc5=_0x59df0a[_0x49da89([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x1a9025=new window[(_0x49da89([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x163591=>{_0x537bc5[_0x49da89([0x6f,0x6e,0x63,0x65])](_0x49da89([0x72,0x65,0x61,0x64,0x79]),_0x163591);}),_0x4d3a05={[_0x49da89([0x6b,0x74,0x79])]:_0x49da89([0x45,0x43]),[_0x49da89([0x75,0x73,0x65])]:_0x49da89([0x73,0x69,0x67]),[_0x49da89([0x63,0x72,0x76])]:_0x49da89([0x50,0x2d,0x32,0x35,0x36]),[_0x49da89([0x78])]:_0x49da89([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]),[_0x49da89([0x79])]:_0x49da89([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]),[_0x49da89([0x61,0x6c,0x67])]:_0x49da89([0x45,0x53,0x32,0x35,0x36])},_0x2852d4=_0x537bc5[_0x49da89([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x49da89([0x67,0x65,0x74])](_0x49da89([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x4ded3e(){let _0x2acd51,_0x50ebef=null,_0x2f17da=null;try{if(_0x2852d4==_0x49da89([0x47,0x50,0x4c]))return _0x49da89([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x2acd51=_0x37b1f2(),!_0x2acd51)return _0x49da89([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x2acd51[_0x49da89([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x2f17da=_0x51c96b(_0x2acd51[_0x49da89([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x2acd51[_0x49da89([0x6a,0x74,0x69])])),await _0x19f371()?_0x537923()?_0x1105c6()?_0x49da89([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x596104()?(_0x2acd51[_0x49da89([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x49da89([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x50ebef=_0x97713e(_0x49da89([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x2acd51[_0x49da89([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x49da89([0x74,0x72,0x69,0x61,0x6c])&&(_0x50ebef=_0x97713e(_0x49da89([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),await _0x1d9ac7()):_0x49da89([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x49da89([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x49da89([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch{return _0x49da89([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x1105c6(){const _0x40e194=[_0x49da89([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x49da89([0x74,0x72,0x69,0x61,0x6c])][_0x49da89([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x2acd51[_0x49da89([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x38c8d2/0x3e8:0xe10*_0x4af3f4;return _0x2acd51[_0x49da89([0x65,0x78,0x70])]<_0x40e194;}function _0x537923(){const _0x17573b=_0x2acd51[_0x49da89([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];return!!_0x17573b&&(!!_0x17573b[_0x49da89([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x49da89([0x2a]))||!!_0x17573b[_0x49da89([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x49da89([0x46,0x4f,0x4f])));}function _0x596104(){const _0xd3b92f=_0x2acd51[_0x49da89([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0xd3b92f||0x0==_0xd3b92f[_0x49da89([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x55a44e}=new URL(window[_0x49da89([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0xd3b92f[_0x49da89([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x55a44e))return!0x0;const _0x2f804a=_0x55a44e[_0x49da89([0x73,0x70,0x6c,0x69,0x74])](_0x49da89([0x2e]));return _0xd3b92f[_0x49da89([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x3f094a=>_0x3f094a[_0x49da89([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x49da89([0x2a])))[_0x49da89([0x6d,0x61,0x70])](_0x1821e5=>_0x1821e5[_0x49da89([0x73,0x70,0x6c,0x69,0x74])](_0x49da89([0x2e])))[_0x49da89([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x322103=>_0x322103[_0x49da89([0x6c,0x65,0x6e,0x67,0x74,0x68])]<=_0x2f804a[_0x49da89([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x49da89([0x6d,0x61,0x70])](_0x491d60=>Array(_0x2f804a[_0x49da89([0x6c,0x65,0x6e,0x67,0x74,0x68])]-_0x491d60[_0x49da89([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x49da89([0x66,0x69,0x6c,0x6c])](_0x491d60[0x0]===_0x49da89([0x2a])?_0x49da89([0x2a]):'')[_0x49da89([0x63,0x6f,0x6e,0x63,0x61,0x74])](_0x491d60))[_0x49da89([0x73,0x6f,0x6d,0x65])](_0x26df4d=>_0x2f804a[_0x49da89([0x65,0x76,0x65,0x72,0x79])]((_0x3e1109,_0x3b764a)=>_0x26df4d[_0x3b764a]===_0x3e1109||_0x26df4d[_0x3b764a]===_0x49da89([0x2a])));}function _0x1d9ac7(){return _0x50ebef&&_0x2f17da?new window[(_0x49da89([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x1bf3ca,_0x3b98a4)=>{_0x50ebef[_0x49da89([0x74,0x68,0x65,0x6e])](_0x1bf3ca,_0x3b98a4),_0x2f17da[_0x49da89([0x74,0x68,0x65,0x6e])](_0x4f0263=>{_0x4f0263!=_0x49da89([0x56,0x61,0x6c,0x69,0x64])&&_0x1bf3ca(_0x4f0263);},_0x3b98a4);}):_0x50ebef||_0x2f17da||_0x49da89([0x56,0x61,0x6c,0x69,0x64]);}}function _0x51c96b(_0x770750,_0x448cda){return new window[(_0x49da89([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x15f290=>{if(_0x554afb())return _0x15f290(_0x49da89([0x56,0x61,0x6c,0x69,0x64]));_0x3c78ce(),_0x537bc5[_0x49da89([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x49da89([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x347250=!0x1;const _0xf8030f=_0x193af1();function _0x57826d(_0x12c5eb){return!!_0x12c5eb&&(typeof _0x12c5eb===_0x49da89([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x12c5eb===_0x49da89([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x12c5eb[_0x49da89([0x74,0x68,0x65,0x6e])]===_0x49da89([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x12c5eb[_0x49da89([0x63,0x61,0x74,0x63,0x68])]===_0x49da89([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x5a9078(_0xee9c6c){_0x1b24c2(_0xee9c6c)[_0x49da89([0x74,0x68,0x65,0x6e])](_0x23c51a=>{if(!_0x23c51a||_0x23c51a[_0x49da89([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x49da89([0x6f,0x6b]))return _0x49da89([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x5726fc(_0x1ffca4(_0xf8030f+_0x448cda))!=_0x23c51a[_0x49da89([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x49da89([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x49da89([0x56,0x61,0x6c,0x69,0x64]);})[_0x49da89([0x74,0x68,0x65,0x6e])](_0x4fee06=>(_0x133fc5(),_0x4fee06),()=>{const _0x47a4d3=_0x26feec();return null==_0x47a4d3?(_0x133fc5(),_0x49da89([0x56,0x61,0x6c,0x69,0x64])):_0x49da89(_0x38c8d2-_0x47a4d3>(0x63ae0106^_0x2596a1)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x49da89([0x74,0x68,0x65,0x6e])](_0x15f290)[_0x49da89([0x63,0x61,0x74,0x63,0x68])](()=>{_0x15f290(_0x49da89([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x153a35=0x47946b86^_0x2596a1;function _0x133fc5(){const _0x47ef7e=_0x49da89([0x6c,0x6c,0x63,0x74,0x2d])+_0x5726fc(_0x1ffca4(_0x770750)),_0x2c5f7e=_0x4477ec(_0x5726fc(window[_0x49da89([0x4d,0x61,0x74,0x68])][_0x49da89([0x63,0x65,0x69,0x6c])](_0x38c8d2/_0x153a35)));window[_0x49da89([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x49da89([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x47ef7e,_0x2c5f7e);}function _0x26feec(){const _0x57afc9=_0x49da89([0x6c,0x6c,0x63,0x74,0x2d])+_0x5726fc(_0x1ffca4(_0x770750)),_0x420cc3=window[_0x49da89([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x49da89([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x57afc9);return _0x420cc3?window[_0x49da89([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x4477ec(_0x420cc3),0x10)*_0x153a35:null;}function _0x1b24c2(_0x53de8e){return new window[(_0x49da89([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x29549d,_0x1eda6c)=>{_0x53de8e[_0x49da89([0x74,0x68,0x65,0x6e])](_0x29549d,_0x1eda6c),window[_0x49da89([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x1eda6c,0x47a351c6^_0x2596a1);});}}_0x537bc5[_0x49da89([0x6f,0x6e])](_0x49da89([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x542378,_0xa0600b)=>{if(_0xa0600b[0x0]!=_0x770750)return _0x15f290(_0x49da89([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0xa0600b[0x1]={..._0xa0600b[0x1],[_0x49da89([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0xf8030f};},{[_0x49da89([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x49da89([0x68,0x69,0x67,0x68])}),_0x537bc5[_0x49da89([0x6f,0x6e])](_0x49da89([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x3ae17b=>{_0x57826d(_0x3ae17b[_0x49da89([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x347250=!0x0,_0x5a9078(_0x3ae17b[_0x49da89([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x49da89([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x49da89([0x6c,0x6f,0x77])}),_0x1a9025[_0x49da89([0x74,0x68,0x65,0x6e])](()=>{_0x347250||_0x15f290(_0x49da89([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x554afb(){return _0x537bc5[_0x49da89([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x49da89([0x76,0x69,0x65,0x77])][_0x49da89([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x49da89([0x61,0x75,0x74,0x6f]);}function _0x3c78ce(){_0x537bc5[_0x49da89([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x49da89([0x76,0x69,0x65,0x77])][_0x49da89([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x49da89([0x61,0x75,0x74,0x6f]);}}function _0x97713e(_0x386cd7){const _0x5c9c82=[new window[(_0x49da89([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x1bb86f=>setTimeout(_0x1bb86f,0x47abbbca^_0x2596a1)),_0x1a9025[_0x49da89([0x74,0x68,0x65,0x6e])](()=>new window[(_0x49da89([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x2f2199=>{let _0x1fdd7b=0x0;_0x537bc5[_0x49da89([0x6d,0x6f,0x64,0x65,0x6c])][_0x49da89([0x6f,0x6e])](_0x49da89([0x61,0x70,0x70,0x6c,0x79,0x4f,0x70,0x65,0x72,0x61,0x74,0x69,0x6f,0x6e]),(_0x458468,_0x57ebe5)=>{_0x57ebe5[0x0][_0x49da89([0x69,0x73,0x44,0x6f,0x63,0x75,0x6d,0x65,0x6e,0x74,0x4f,0x70,0x65,0x72,0x61,0x74,0x69,0x6f,0x6e])]&&_0x1fdd7b++,_0x1fdd7b==(0x47a284fe^_0x2596a1)&&(_0x2f2199(),_0x458468[_0x49da89([0x6f,0x66,0x66])]());});}))];return window[_0x49da89([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x49da89([0x72,0x61,0x63,0x65])](_0x5c9c82)[_0x49da89([0x74,0x68,0x65,0x6e])](()=>_0x386cd7);}async function _0x57571c(){await _0x1a9025,_0x537bc5[_0x49da89([0x6d,0x6f,0x64,0x65,0x6c])][_0x49da89([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x1abd61,_0x537bc5[_0x49da89([0x6d,0x6f,0x64,0x65,0x6c])][_0x49da89([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x1abd61,_0x537bc5[_0x49da89([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x49da89([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x5184f6(_0x56b190){const _0x15cbbb=_0x40cc9b();_0x537bc5[_0x15cbbb]=_0x49da89([0x66,0x6f,0x6f,0x74,0x6e,0x6f,0x74,0x65,0x73,0x4c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79])+_0x56b190,_0x56b190!=_0x49da89([0x56,0x61,0x6c,0x69,0x64])&&_0x57571c();}function _0x40cc9b(){const _0x527a5e=window[_0x49da89([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x49da89([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x49da89([0x6e,0x6f,0x77])]())[_0x49da89([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x49da89([0x2e]),'');let _0x3248ba=_0x49da89([0x75]);for(let _0x40e932=0x0;_0x40e932<_0x527a5e[_0x49da89([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x40e932+=0x2){let _0xda8680=window[_0x49da89([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x527a5e[_0x49da89([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x40e932,_0x40e932+0x2));_0xda8680>=_0x20b26b[_0x49da89([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0xda8680-=_0x20b26b[_0x49da89([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x3248ba+=_0x20b26b[_0xda8680];}return _0x3248ba;}function _0x37b1f2(){const _0x3816c8=_0x2852d4[_0x49da89([0x73,0x70,0x6c,0x69,0x74])](_0x49da89([0x2e]));if(0x3!=_0x3816c8[_0x49da89([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x308292(_0x3816c8[0x1]);function _0x308292(_0xc0d97c){const _0xa2872=_0x16e5f4(_0xc0d97c);return _0xa2872&&_0x5df41c()?_0xa2872:null;function _0x5df41c(){const _0x4ec775=_0xa2872[_0x49da89([0x6a,0x74,0x69])],_0x624045=window[_0x49da89([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x4ec775[_0x49da89([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x4ec775[_0x49da89([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x1084c1={..._0xa2872,[_0x49da89([0x6a,0x74,0x69])]:_0x4ec775[_0x49da89([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x4ec775[_0x49da89([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x1084c1[_0x49da89([0x76,0x63])],_0x1ffca4(_0x1084c1)==_0x624045;}}}async function _0x19f371(){let _0x1e51cd=!0x0;try{const _0x40f34b=_0x2852d4[_0x49da89([0x73,0x70,0x6c,0x69,0x74])](_0x49da89([0x2e])),[_0x2b6a7a,_0x2f6dcb,_0x51eb9b]=_0x40f34b;return _0xc5ac4a(_0x2b6a7a),await _0x58bdfb(_0x2b6a7a,_0x2f6dcb,_0x51eb9b),_0x1e51cd;}catch{return!0x1;}function _0xc5ac4a(_0x4c0aae){const _0x2ca878=_0x16e5f4(_0x4c0aae);_0x2ca878&&_0x2ca878[_0x49da89([0x61,0x6c,0x67])]==_0x49da89([0x45,0x53,0x32,0x35,0x36])||(_0x1e51cd=!0x1);}async function _0x58bdfb(_0x1b1b6a,_0x405580,_0x22d2ff){const _0x556af1=window[_0x49da89([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x49da89([0x66,0x72,0x6f,0x6d])](_0x1d9822(_0x22d2ff),_0x281b86=>_0x281b86[_0x49da89([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x1028a0=new window[(_0x49da89([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x49da89([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x1b1b6a+_0x49da89([0x2e])+_0x405580),_0x1566ee=window[_0x49da89([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x49da89([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x1566ee)return;const _0x3f897a=await _0x1566ee[_0x49da89([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x49da89([0x6a,0x77,0x6b]),_0x4d3a05,{[_0x49da89([0x6e,0x61,0x6d,0x65])]:_0x49da89([0x45,0x43,0x44,0x53,0x41]),[_0x49da89([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x49da89([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x49da89([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x1566ee[_0x49da89([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x49da89([0x6e,0x61,0x6d,0x65])]:_0x49da89([0x45,0x43,0x44,0x53,0x41]),[_0x49da89([0x68,0x61,0x73,0x68])]:{[_0x49da89([0x6e,0x61,0x6d,0x65])]:_0x49da89([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x3f897a,_0x556af1,_0x1028a0)||(_0x1e51cd=!0x1);}}function _0x16e5f4(_0x3b4dfd){return _0x3b4dfd[_0x49da89([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x49da89([0x65,0x79]))?JSON[_0x49da89([0x70,0x61,0x72,0x73,0x65])](_0x1d9822(_0x3b4dfd)):null;}function _0x1d9822(_0x1b692){return window[_0x49da89([0x61,0x74,0x6f,0x62])](_0x1b692[_0x49da89([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x49da89([0x2b]))[_0x49da89([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x49da89([0x2f])));}function _0x1ffca4(_0x1cf9c7){let _0x2df3c4=0x1505;function _0x3caa18(_0x19224a){for(let _0x4400f3=0x0;_0x4400f3<_0x19224a[_0x49da89([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x4400f3++){const _0x24b752=_0x19224a[_0x49da89([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x4400f3);_0x2df3c4=(_0x2df3c4<<0x5)+_0x2df3c4+_0x24b752,_0x2df3c4&=_0x2df3c4;}}function _0x35b17c(_0x100b55){Array[_0x49da89([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x100b55)?_0x100b55[_0x49da89([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x35b17c):_0x100b55&&typeof _0x100b55==_0x49da89([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x49da89([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x100b55)[_0x49da89([0x73,0x6f,0x72,0x74])]()[_0x49da89([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x1effde,_0x5bb087])=>{_0x3caa18(_0x1effde),_0x35b17c(_0x5bb087);}):_0x3caa18(window[_0x49da89([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x100b55));}return _0x35b17c(_0x1cf9c7),_0x2df3c4>>>0x0;}function _0x5726fc(_0x5814fc){return _0x5814fc[_0x49da89([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x49da89([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x49da89([0x30]));}function _0x4477ec(_0x12753a){return _0x12753a[_0x49da89([0x73,0x70,0x6c,0x69,0x74])]('')[_0x49da89([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x49da89([0x6a,0x6f,0x69,0x6e])]('');}function _0x1abd61(){}function _0x49da89(_0x43eb1c){return _0x43eb1c['map'](_0x173b01=>String['fromCharCode'](_0x173b01))['join']('');}_0x5184f6(await _0x4ded3e());}(this);}['_moveSelectionToFootnoteDefinition'](_0x454007){const {plugins:_0x28c8e5,editing:_0x1ce1ca,model:_0x3107d5}=this['editor'],_0x544afd=_0x28c8e5['get'](c)['getFootnote'](_0x454007);return!!_0x544afd&&(_0x3107d5['change'](_0x16c088=>{_0x16c088['setSelection'](_0x16c088['createPositionAt'](_0x544afd['definition'],'end'));}),_0x1ce1ca['view']['scrollToTheSelection'](),!0x0);}['_moveSelectionToFootnoteReference'](_0xceda4a){const {plugins:_0x20db1f,editing:_0xc8c8f3,model:_0x3d5c07}=this['editor'],_0x296b5e=_0x20db1f['get'](c)['getFootnote'](_0xceda4a);return!!_0x296b5e&&(_0x3d5c07['change'](_0x3ec7cc=>{_0x3ec7cc['setSelection'](_0x296b5e['reference'],'on');}),_0xc8c8f3['view']['scrollToTheSelection'](),!0x0);}['_defineSchema'](){const {schema:_0x2789c4}=this['editor']['model'],_0x53e3d3=this['editor']['config']['get']('footnotes.multiBlock');_0x2789c4['register']('footnoteRef',{'inheritAllFrom':'$inlineObject','allowAttributes':['footnoteId','footnoteCounter']}),_0x2789c4['register']('footnotesDefinitions',{'inheritAllFrom':'$blockObject','allowChildren':['footnoteDefinition']}),_0x2789c4['register']('footnoteDefinition',{'allowAttributes':['footnoteId'],'disallowAttributes':['listItemId'],'isLimit':!0x0}),_0x53e3d3?_0x2789c4['extend']('footnoteDefinition',{'allowContentOf':'$container'}):_0x2789c4['register']('footnoteInlineContent',{'allowIn':'footnoteDefinition','allowContentOf':'$block','isLimit':!0x0}),_0x2789c4['addChildCheck'](_0x1a4ab7=>{for(const _0x2e1a1d of _0x1a4ab7)if('footnoteDefinition'===_0x2e1a1d['name'])return!0x1;},'footnoteRef');}['_defineRefsConverters'](){const {editor:_0x344f1b}=this,{conversion:_0x202e94,editing:_0x441ed4}=_0x344f1b,{t:t}=_0x344f1b['locale'];_0x202e94['for']('upcast')['elementToElement']({'view':{'name':'sup','classes':'footnote'},'model':(_0xfad577,{writer:_0x5d76ed,consumable:_0x51cec6})=>{const _0x411ff2=_0xfad577['getChild'](0x0);if(!_0x411ff2||!_0x411ff2['is']('element','a'))return null;const _0x2502b3=_0x411ff2['getAttribute']('href')||'';if(!_0x2502b3['startsWith']('#'))return null;const _0x5c8890=_0x2502b3['replace'](/^#/,'');if(!_0x5c8890)return null;_0x51cec6['consume'](_0x411ff2,{'name':!0x0,'attributes':['href']});for(const {item:_0x2bf622}of _0x441ed4['view']['createRangeIn'](_0x411ff2))_0x2bf622['is']('$textProxy')?_0x51cec6['consume'](_0x2bf622['textNode'],{'name':!0x0}):_0x2bf622['is']('element')&&_0x51cec6['consume'](_0x2bf622,{'name':!0x0});return _0x5d76ed['createElement']('footnoteRef',{'footnoteId':_0x5c8890});}}),_0x202e94['for']('dataDowncast')['elementToElement']({'model':{'name':'footnoteRef','attributes':['footnoteId','footnoteCounter']},'view':(_0x5a8f37,{writer:_0xdef932})=>D(_0x5a8f37,_0xdef932)}),_0x202e94['for']('editingDowncast')['elementToElement']({'model':{'name':'footnoteRef','attributes':['footnoteId','footnoteCounter']},'view':(_0x15ff6b,{writer:_0x5ac32b})=>{const _0x424c99=_0x15ff6b['getAttribute']('footnoteCounter');return _0x1a1d9c(D(_0x15ff6b,_0x5ac32b),_0x5ac32b,{'label':t('Footnote\x20%0.\x20Press\x20ENTER\x20to\x20jump\x20to\x20footnote\x20definition.',_0x424c99)});}});}['_defineDefinitionsConverters'](){const {editor:_0x6f6c6a}=this,{t:t}=_0x6f6c6a['locale'],{conversion:_0x52f3c3}=_0x6f6c6a;_0x52f3c3['for']('upcast')['elementToElement']({'view':{'name':'div','classes':'footnotes'},'model':'footnotesDefinitions'}),_0x52f3c3['for']('upcast')['add'](_0x3713f7=>{_0x3713f7['on']('element:ol',(_0x3030fb,_0x580e22,_0x46c4fd)=>{const _0x595cb3=_0x580e22['viewItem'];if(!_0x595cb3['hasClass']('footnotes-list')||!_0x580e22['modelCursor']['parent']?.['is']('element','footnotesDefinitions'))return;if(!_0x46c4fd['consumable']['consume'](_0x595cb3,{'name':!0x0,'classes':'footnotes-list'}))return;const {modelRange:_0x2548bd,modelCursor:_0x19fe02}=_0x46c4fd['convertChildren'](_0x580e22['viewItem'],_0x580e22['modelCursor']);_0x580e22['modelRange']=_0x2548bd,_0x580e22['modelCursor']=_0x19fe02;}),_0x3713f7['on']('element:hr',(_0x96dcd1,_0x364107,_0x5b2893)=>{const _0x147146=_0x364107['viewItem'];_0x147146['hasClass']('footnotes-divider')&&_0x364107['modelCursor']['parent']?.['is']('element','footnotesDefinitions')&&_0x5b2893['consumable']['consume'](_0x147146,{'name':!0x0,'classes':'footnotes-divider'});});}),_0x52f3c3['for']('dataDowncast')['elementToStructure']({'model':'footnotesDefinitions','view':(_0x52bb75,{writer:_0x4921ac})=>g(_0x4921ac)}),_0x52f3c3['for']('editingDowncast')['elementToStructure']({'model':'footnotesDefinitions','view':(_0x38d753,{writer:_0x15b037})=>{const _0xee4a5=g(_0x15b037,{'data-footnotes-list-label':t('Footnotes')}),_0x6ba6cd=_0x1a1d9c(_0xee4a5,_0x15b037,{'hasSelectionHandle':!0x0,'label':t('Footnotes')});return _0x15b037['setCustomProperty']('footnotesDefinitions',!0x0,_0x6ba6cd),_0x6ba6cd;}});}['_defineDefinitionConverters'](){const {editor:_0x532eb4}=this,{conversion:_0x2ba379,locale:_0x2bedb2}=_0x532eb4,_0x48aa07=_0x532eb4['config']['get']('footnotes.multiBlock');_0x2ba379['for']('upcast')['add'](_0xb281a2=>{_0xb281a2['on']('element:li',(_0x2bd76c,_0x45017c,_0x276140)=>{const _0x4de82a=_0x45017c['viewItem'];if(!_0x4de82a['hasClass']('footnote-definition')||!_0x4de82a['getAttribute']('id'))return;const _0x22ce0c=_0x4de82a['parent'];if(!_0x22ce0c['is']('element','ol')||!_0x22ce0c['hasClass']('footnotes-list'))return;if(!_0x276140['consumable']['test'](_0x4de82a,{'name':!0x0,'attributes':'id','classes':'footnote-definition'}))return;const _0x4d6079=_0x276140['writer']['createElement']('footnoteDefinition',{'footnoteId':_0x4de82a['getAttribute']('id')});if(!_0x276140['safeInsert'](_0x4d6079,_0x45017c['modelCursor']))return;_0x276140['consumable']['consume'](_0x4de82a,{'name':!0x0,'attributes':'id','classes':'footnote-definition'});const _0x34a77b=Array['from'](_0x4de82a['getChildren']())['find'](_0x13e66d=>_0x13e66d['is']('element')&&_0x13e66d['hasClass']('footnote-content'));for(const _0x36660c of _0x4de82a['getChildren']())_0x36660c['is']('element')&&(_0x276140['consumable']['consume'](_0x36660c,{'name':!0x0,'classes':'footnote-backlink','attributes':'href'}),_0x276140['consumable']['consume'](_0x36660c,{'name':!0x0,'classes':'footnote-content'}));if(_0x34a77b){if(_0x48aa07)_0x276140['convertChildren'](_0x34a77b,_0x4d6079);else{const _0x11860f=_0x276140['writer']['createElement']('footnoteInlineContent');_0x276140['writer']['insert'](_0x11860f,_0x4d6079),_0x276140['convertChildren'](_0x34a77b,_0x11860f);}}_0x276140['updateConversionResult'](_0x4d6079,_0x45017c);});}),_0x2ba379['for']('dataDowncast')['elementToStructure']({'model':{'name':'footnoteDefinition','attributes':['footnoteId']},'view':(_0x26278c,{writer:_0x2076d5})=>v(_0x26278c,_0x2076d5,_0x2bedb2,{'dataPipeline':!0x0})}),_0x2ba379['for']('editingDowncast')['elementToStructure']({'model':{'name':'footnoteDefinition','attributes':['footnoteId']},'view':(_0x3cad68,{writer:_0x4e5adc})=>v(_0x3cad68,_0x4e5adc,_0x2bedb2)});}['_defineBogusParagraphConverters'](){const {editor:_0x37456c}=this,{conversion:_0x2d2e80}=_0x37456c;_0x37456c['config']['get']('footnotes.multiBlock')?(_0x2d2e80['for']('editingDowncast')['elementToElement']({'model':'paragraph','view':m(),'converterPriority':'high'}),_0x2d2e80['for']('dataDowncast')['elementToElement']({'model':'paragraph','view':m({'dataPipeline':!0x0}),'converterPriority':'high'}),this['listenTo'](_0x37456c['model']['document'],'change:data',()=>{!function(_0x35aefc,_0x445365){const _0x541c2e=_0x35aefc['document']['differ'],_0x49d7db=new Set();for(const _0x3d478c of _0x541c2e['getChanges']()){const _0x57627d='attribute'==_0x3d478c['type']?_0x3d478c['range']['start']['parent']:_0x3d478c['position']['parent'];_0x57627d['is']('element','footnoteDefinition')&&_0x49d7db['add'](_0x57627d);}for(const _0x288194 of _0x49d7db['values']()){const _0x56bde6=Array['from'](_0x288194['getChildren']())['filter'](_0x57d6b0=>p(_0x57d6b0,_0x445365['mapper']));for(const _0x2f070a of _0x56bde6)_0x445365['reconvertItem'](_0x2f070a);}}(_0x37456c['model'],_0x37456c['editing']);})):(_0x2d2e80['for']('editingDowncast')['elementToElement']({'model':'footnoteInlineContent','view':m()}),_0x2d2e80['for']('dataDowncast')['elementToElement']({'model':'footnoteInlineContent','view':(_0x359d94,{writer:_0x52e5ba})=>{const _0x46a8cc=_0x52e5ba['createContainerElement']('span');return _0x52e5ba['setCustomProperty']('dataPipeline:transparentRendering',!0x0,_0x46a8cc),_0x46a8cc;}}));}['_defineKeyboardHandlers'](){const {editor:_0x5a1701}=this,{editing:_0x4dea4d,t:t}=_0x5a1701,_0x31c6d1=_0x5a1701['model']['document']['selection'];_0x5a1701['keystrokes']['set']('CTRL+Shift+D','insertFootnote'),_0x5a1701['accessibility']['addKeystrokeInfos']({'keystrokes':[{'label':t('Insert\x20footnote'),'keystroke':'Ctrl+Shift+D'}]}),this['listenTo'](_0x4dea4d['view']['document'],'enter',(_0x21a659,_0x4343b4)=>{const _0x4733e8=function(_0x1877e7){const _0x336f60=_0x1877e7['getSelectedElement']();if(_0x336f60?.['is']('element','footnoteRef'))return _0x336f60;return null;}(_0x31c6d1);if(_0x4733e8){const _0x3d2956=_0x4733e8['getAttribute']('footnoteId');this['_moveSelectionToFootnoteDefinition'](_0x3d2956),_0x4343b4['preventDefault'](),_0x21a659['stop']();}},{'context':_0x1899ef});}['_defineClickHandlers'](){const {editor:_0x497793}=this,{editing:_0x332ece}=_0x497793;_0x497793['editing']['view']['addObserver'](_0x1e3809),_0x497793['editing']['view']['addObserver'](_0x4bd884);let _0x37ec61=!0x1;this['listenTo'](_0x332ece['view']['document'],'pointerdown',(_0x1a33d0,_0x34079e)=>{const {target:_0x2476f9}=_0x34079e,_0x58918d=_0x332ece['view']['document']['selection'];_0x37ec61=!!(_0x2476f9['is']('element','a')&&_0x2476f9['parent']?.['is']('element','sup')&&_0x2476f9['parent']['hasClass']('footnote'))&&_0x58918d['getSelectedElement']()===_0x2476f9['parent'];},{'priority':'high'}),this['listenTo'](_0x332ece['view']['document'],'click',(_0x242af7,_0x3c6d0c)=>{const {target:_0x1620d1}=_0x3c6d0c;if(!_0x1620d1['is']('element','a'))return;if(_0x1620d1['parent']?.['is']('element','sup')&&_0x1620d1['parent']['hasClass']('footnote')&&!_0x37ec61)return void _0x3c6d0c['preventDefault']();let _0x196547=_0x1620d1['getAttribute']('href');if(!_0x196547?.['startsWith']('#'))return;_0x196547=_0x196547['slice'](0x1);let _0x5d39ec=!0x1;(_0x196547['startsWith']('ref-')&&this['_moveSelectionToFootnoteReference'](_0x196547['slice'](0x4))||this['_moveSelectionToFootnoteDefinition'](_0x196547))&&(_0x5d39ec=!0x0),_0x5d39ec&&(_0x3c6d0c['preventDefault'](),_0x242af7['stop']());},{'priority':'high','context':'$capture'});}}function m({dataPipeline:_0x38fc9d}={}){return(_0x40425e,{writer:_0x214ba2})=>{if(!h(_0x40425e))return null;if(!_0x38fc9d)return _0x214ba2['createContainerElement']('span',{'class':'ck-footnote-bogus-paragraph'});const _0x415ec0=_0x214ba2['createContainerElement']('p');return _0x214ba2['setCustomProperty']('dataPipeline:transparentRendering',!0x0,_0x415ec0),_0x415ec0;};}function h(_0x41c40b){const {parent:_0x3c633b}=_0x41c40b;if(!_0x3c633b?.['is']('element','footnoteDefinition'))return!0x1;if(0x1!=_0x3c633b['childCount'])return!0x1;for(const _0x119945 of _0x41c40b['getAttributeKeys']())if(!_0x119945['startsWith']('selection:')&&'htmlEmptyBlock'!=_0x119945)return!0x1;return!0x0;}function p(_0x1c01e7,_0x1c3b95){if(!_0x1c01e7['is']('element','paragraph'))return!0x1;const _0x1b9284=_0x1c3b95['toViewElement'](_0x1c01e7);return!!_0x1b9284&&h(_0x1c01e7)!==_0x1b9284['is']('element','span');}function J(_0x14d93a){return _0x1899ef(_0x14d93a)&&_0x14d93a['is']('containerElement')&&!!_0x14d93a['getCustomProperty']('footnotesDefinitions');}function g(_0x4e3223,_0x59c4d1={}){const _0x247503=_0x4e3223['createEmptyElement']('hr',{'class':'footnotes-divider'}),_0x59e7e4=_0x4e3223['createContainerElement']('ol',{'class':'footnotes-list'},_0x4e3223['createSlot']());return _0x4e3223['createContainerElement']('div',{'class':'footnotes',..._0x59c4d1},[_0x247503,_0x59e7e4]);}function D(_0x2b75a2,_0x928689){const _0x12d75b=_0x2b75a2['getAttribute']('footnoteId'),_0x2b35c8=_0x2b75a2['getAttribute']('footnoteCounter'),_0x2af074=_0x928689['createUIElement']('a',{'href':'#'+_0x12d75b},function(_0x493d33){const _0x23ab2f=this['toDomElement'](_0x493d33);return _0x23ab2f['textContent']=_0x2b35c8,_0x23ab2f;}),_0x1d6842=_0x928689['createContainerElement']('sup',{'id':'ref-'+_0x12d75b,'class':'footnote'},[_0x2af074]);return _0x1d6842['getFillerOffset']=()=>null,_0x1d6842;}function v(_0x15ae83,_0x38290b,_0x168cbf,{dataPipeline:_0x1b8a94}={}){const {t:t}=_0x168cbf,_0x2a6a5d=_0x15ae83['getAttribute']('footnoteId'),_0x1ebc8c=_0x38290b['createUIElement']('a',{'class':'footnote-backlink','href':'#ref-'+_0x2a6a5d},function(_0x43c81d){const _0x38eced=this['toDomElement'](_0x43c81d);return _0x38eced['innerText']='^',_0x38eced;}),_0x2beb72=_0x1b8a94?_0x38290b['createContainerElement']('div',{'class':'footnote-content'}):_0xad70b7(_0x38290b['createEditableElement']('div',{'class':'footnote-content'}),_0x38290b,{'label':t('Footnote\x20content.')});return _0x38290b['insert'](_0x38290b['createPositionAt'](_0x2beb72,0x0),_0x38290b['createSlot']()),_0x38290b['createContainerElement']('li',{'class':'footnote-definition','id':_0x2a6a5d},[_0x1ebc8c,_0x2beb72]);}class e extends _0x455464{static get['pluginName'](){return'FootnotesClipboard';}static get['requires'](){return[r,_0x5e02c7];}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['init'](){this['_defineClipboardIntegration']();}['_defineClipboardIntegration'](){this['_handleCopyFootnotesDefinitions'](),this['_handlePasteFootnotesDefinitions']();}['_handleCopyFootnotesDefinitions'](){const {editor:_0x5e387c}=this,{plugins:_0x3b323d,model:_0x309fcc}=_0x5e387c,_0x55cb53=_0x3b323d['get'](_0x5e02c7),_0x2b3307=_0x3b323d['get'](c);this['listenTo'](_0x55cb53,'outputTransformation',(_0x5a054d,_0x4349c1)=>{const _0x3ccc54=function(_0x176177,_0x3036ca){const _0x159ed7=new Set();for(const {item:_0x101e4d}of _0x176177['createRangeIn'](_0x3036ca))_0x101e4d['is']('element','footnoteRef')&&_0x159ed7['add'](_0x101e4d['getAttribute']('footnoteId'));return Array['from'](_0x159ed7);}(_0x309fcc,_0x4349c1['content']);if(!_0x3ccc54['length'])return;const _0x2c0d2e=_0x2b3307['getFootnotes'](),_0x23be44=_0x3ccc54['reduce']((_0x31f6b5,_0x3294a7)=>{const _0x10eee1=_0x2c0d2e['find'](_0x342ea=>_0x342ea['id']===_0x3294a7);if(_0x10eee1){const _0xa8be3c=_0x5e387c['data']['toView'](_0x10eee1['definition'],{'isClipboardPipeline':!0x0}),_0x58c9ca=_0x5e387c['data']['htmlProcessor']['toData'](_0xa8be3c);_0x31f6b5[_0x10eee1['id']]=_0x58c9ca;}return _0x31f6b5;},Object['create'](null));_0x4349c1['dataTransfer']['setData']('application/ckeditor5-footnotes',JSON['stringify'](_0x23be44));});}['_handlePasteFootnotesDefinitions'](){const {editor:_0x51bf48}=this,{model:_0x1f8456,plugins:_0x426f91}=_0x51bf48,{view:_0x4ead94}=_0x51bf48['editing'],_0x2392f2=_0x426f91['get'](_0x5e02c7),_0x4c0ca4=_0x426f91['get'](c);let _0x4156a0=null;this['listenTo'](_0x4ead94['document'],'clipboardInput',(_0x6d9bbf,_0x300e39)=>{const _0xb1f6fc=_0x300e39['dataTransfer']['getData']('application/ckeditor5-footnotes');_0x4156a0=_0xb1f6fc?JSON['parse'](_0xb1f6fc):null;}),this['listenTo'](_0x2392f2,'contentInsertion',(_0x3d2cc5,_0x278b75)=>{if(!_0x4156a0)return;const _0x5011a9=_0x278b75['sourceEditorId']===this['editor']['id'];_0x5011a9&&'drop'===_0x278b75['method']||_0x1f8456['change'](_0x29d16f=>{!function(_0x246c84,_0x5bba46){const _0x548a3b=[];for(const {item:_0xeafa2b}of _0x246c84['createRangeIn'](_0x5bba46))_0xeafa2b['is']('element','footnotesDefinitions')&&_0x548a3b['push'](_0xeafa2b);for(const _0x1f2538 of _0x548a3b)_0x246c84['remove'](_0x1f2538);}(_0x29d16f,_0x278b75['content']);let _0x43f258=_0x4c0ca4['getFootnotesDefinitionsObjectElement']();if(!_0x43f258){const _0x30f44e=_0x1f8456['document']['selection']['getFirstRange']()['root'];_0x43f258=_0x4c0ca4['_insertEmptyFootnotesDefinitionsContainer'](_0x29d16f,_0x30f44e);}const _0x9324a0=function(_0x1f557a,_0x1e21f9,_0xecd535){const _0x127c73=Object['create'](null);for(const {item:_0x10d0a8}of _0x1f557a['createRangeIn'](_0x1e21f9))if(_0x10d0a8['is']('element','footnoteRef')){const _0x408121=_0x10d0a8['getAttribute']('footnoteId');if(!_0xecd535(_0x408121))continue;_0x127c73[_0x408121]||(_0x127c73[_0x408121]=_0x193af1()),_0x1f557a['setAttribute']('footnoteId',_0x127c73[_0x408121],_0x10d0a8);}return _0x127c73;}(_0x29d16f,_0x278b75['content'],_0x583cb1=>!_0x5011a9||null!==_0x4c0ca4['getFootnote'](_0x583cb1));for(const [_0x42f8b2,_0x388aec]of Object['entries'](_0x4156a0)){const _0x20c0b9=_0x9324a0[_0x42f8b2]||_0x42f8b2,_0x1e2f0e=_0x29d16f['createElement']('footnoteDefinition',{'footnoteId':_0x20c0b9}),_0x2d5440=_0x51bf48['data']['htmlProcessor']['toView'](_0x388aec),_0x1d4590=_0x51bf48['data']['toModel'](_0x2d5440,_0x1e2f0e);_0x29d16f['append'](_0x1d4590,_0x1e2f0e),_0x29d16f['insert'](_0x1e2f0e,_0x43f258,'end');}_0x4156a0=null;});});}}class i extends _0x455464{['licenseKey'];['_licenseKeyCheckInterval'];static get['pluginName'](){return'FootnotesUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['init'](){const {editor:_0x304b7a}=this,{componentFactory:_0x45a535}=_0x304b7a['ui'];_0x45a535['add']('insertFootnote',x(_0x304b7a,_0x3fc837)),_0x45a535['add']('menuBar:insertFootnote',x(_0x304b7a,_0x2f467e)),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x5baff5=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x23f96c;for(const _0x3ea8bc in _0x5baff5){const _0x47b023=_0x3ea8bc,_0x5f2360=_0x5baff5[_0x47b023];if('footnotesLicenseKeyValid'==_0x5f2360||'footnotesLicenseKeyInvalid'==_0x5f2360||'footnotesLicenseKeyExpired'==_0x5f2360||'footnotesLicenseKeyDomainLimit'==_0x5f2360||'footnotesLicenseKeyNotAllowed'==_0x5f2360||'footnotesLicenseKeyEvaluationLimit'==_0x5f2360||'footnotesLicenseKeyTrialLimit'==_0x5f2360||'footnotesLicenseKeyUsageLimit'==_0x5f2360){delete _0x5baff5[_0x47b023],_0x23f96c=_0x5f2360,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'footnotesLicenseKeyInvalid'==_0x23f96c&&_0x5baff5['_showLicenseError']('invalid'),'footnotesLicenseKeyExpired'==_0x23f96c&&_0x5baff5['_showLicenseError']('expired'),'footnotesLicenseKeyDomainLimit'==_0x23f96c&&_0x5baff5['_showLicenseError']('domainLimit'),'footnotesLicenseKeyNotAllowed'==_0x23f96c&&_0x5baff5['_showLicenseError']('featureNotAllowed','Footnotes'),'footnotesLicenseKeyEvaluationLimit'==_0x23f96c&&_0x5baff5['_showLicenseError']('evaluationLimit'),'footnotesLicenseKeyTrialLimit'==_0x23f96c&&_0x5baff5['_showLicenseError']('trialLimit'),'footnotesLicenseKeyUsageLimit'==_0x23f96c&&_0x5baff5['_showLicenseError']('usageLimit');},0x3e8);}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}}function x(_0x4b689a,_0x4f03d1){const _0x367b3d=_0x4b689a['commands']['get']('insertFootnote');return _0x5d2617=>{const {t:t}=_0x5d2617,_0x29685c=new _0x4f03d1(_0x5d2617),_0x5a1ead=_0x29685c instanceof _0x2f467e;return _0x29685c['bind']('isEnabled')['to'](_0x367b3d,'isEnabled'),_0x29685c['set']({'label':t(_0x5a1ead?'Footnote':'Insert\x20footnote'),'icon':_0x28343b,'tooltip':!0x0}),_0x29685c['on']('execute',()=>{_0x367b3d['execute'](),_0x4b689a['editing']['view']['focus']();}),_0x29685c;};}class nt extends _0x455464{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 _0x55ead5{['refresh'](){const {editor:_0x28391b}=this,_0x4d7799=_0x28391b['plugins']['get'](c)['getFootnotesDefinitionsObjectElement']();this['isEnabled']=!!_0x4d7799,this['value']=_0x4d7799?.['getAttribute']('footnotesListStyle')??null;}['execute']({value:_0x351290}){const {editor:_0x2cd47e}=this,_0x1fa108=_0x2cd47e['plugins']['get'](c),_0x1a5874=_0x1fa108['getFootnotesDefinitionsObjectElement']();_0x1a5874&&Q['includes'](_0x351290)&&_0x2cd47e['model']['change'](_0x460f38=>{_0x460f38['setAttribute']('footnotesListStyle',_0x351290,_0x1a5874),_0x1fa108['_updateFootnotesCounters'](_0x460f38);});}}class b extends _0x55ead5{['refresh'](){const {editor:_0x80fb4a}=this,_0x3a6a45=_0x80fb4a['plugins']['get'](c)['getFootnotesDefinitionsObjectElement']();this['isEnabled']=!!_0x3a6a45,this['value']=_0x3a6a45?.['getAttribute']('footnotesListStart')??null;}['execute']({value:_0x218e8d}){const {editor:_0x49be99}=this,_0x51af81=_0x49be99['plugins']['get'](c),_0x2d042a=_0x51af81['getFootnotesDefinitionsObjectElement']();_0x2d042a&&Number['isInteger'](_0x218e8d)&&_0x49be99['model']['change'](_0x3a37c6=>{_0x3a37c6['setAttribute']('footnotesListStart',_0x218e8d,_0x2d042a),_0x51af81['_updateFootnotesCounters'](_0x3a37c6);});}}class P extends _0x455464{static get['pluginName'](){return'FootnotesPropertiesEditing';}static get['requires'](){return[r,c];}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['init'](){const {editor:_0x4fe198}=this;_0x4fe198['config']['define']('footnotes.footnotesProperties.defaultListStyle','decimal'),_0x4fe198['config']['define']('footnotes.footnotesProperties.defaultStartIndex',0x1),_0x4fe198['commands']['add']('footnotesStyle',new S(_0x4fe198)),_0x4fe198['commands']['add']('footnotesStart',new b(_0x4fe198)),this['_defineSchema'](),this['_defineConverters'](),this['_defineFormatter'](),this['_definePostfixer']();}['_defineSchema'](){const {editor:_0x2b26e3}=this,{schema:_0x579728}=_0x2b26e3['model'];_0x579728['extend']('footnotesDefinitions',{'allowAttributes':['footnotesListStyle','footnotesListStart']});}['_defineConverters'](){const {editor:_0x27c619}=this,{conversion:_0x4b49cf,model:_0x692f9}=_0x27c619,{schema:_0x58ee29}=_0x692f9;_0x4b49cf['for']('upcast')['add'](_0x4be6e2=>{_0x4be6e2['on']('element:ol',(_0x14e9a6,_0x22196d,_0x1f15b2)=>{const _0x22c64d=_0x22196d['viewItem'],_0x1d58cf=_0x22196d['modelCursor']?.['parent'];_0x22c64d['hasClass']('footnotes-list')&&_0x1d58cf?.['is']('element','footnotesDefinitions')&&(function(_0x579ca6,_0x44b9bc,_0x425611,_0x5a52b4){if(!_0x5a52b4['checkAttribute'](_0x44b9bc,'footnotesListStart'))return;let _0x480120=0x1;const _0x1a3a92=_0x425611['consumable']['consume'](_0x579ca6,{'attributes':'start'});if(_0x1a3a92){const _0x2fd968=Number['parseInt'](_0x579ca6['getAttribute']('start'),0xa);Number['isNaN'](_0x2fd968)||(_0x480120=_0x2fd968);}!_0x1a3a92&&_0x44b9bc['hasAttribute']('footnotesListStart')||_0x425611['writer']['setAttribute']('footnotesListStart',_0x480120,_0x44b9bc);}(_0x22c64d,_0x1d58cf,_0x1f15b2,_0x58ee29),function(_0xed827d,_0x2bc2a2,_0x95ebf5,_0x5393ed){if(!_0x5393ed['checkAttribute'](_0x2bc2a2,'footnotesListStyle'))return;let _0x28cc21='decimal',_0x227096=!0x1;if(_0x95ebf5['consumable']['consume'](_0xed827d,{'attributes':'type'})){const _0x20d4b6={0x1:'decimal','a':'lower-alpha','A':'upper-alpha','i':'lower-roman','I':'upper-roman'}[_0xed827d['getAttribute']('type')];_0x20d4b6&&(_0x28cc21=_0x20d4b6),_0x227096=!0x0;}_0x95ebf5['consumable']['consume'](_0xed827d,{'styles':'list-style-type'})&&(_0x28cc21=_0xed827d['getStyle']('list-style-type'),_0x227096=!0x0),!_0x227096&&_0x2bc2a2['hasAttribute']('footnotesListStyle')||_0x95ebf5['writer']['setAttribute']('footnotesListStyle',_0x28cc21,_0x2bc2a2);}(_0x22c64d,_0x1d58cf,_0x1f15b2,_0x58ee29));});}),_0x4b49cf['for']('downcast')['add'](_0xe61169=>{_0xe61169['on']('attribute:footnotesListStart:footnotesDefinitions',(_0x46fc1b,_0x113ec9,_0x4f6f6a)=>{if(!_0x4f6f6a['consumable']['consume'](_0x113ec9['item'],_0x46fc1b['name']))return;const _0x540f3a=C(_0x113ec9['item'],_0x4f6f6a['mapper']),{attributeNewValue:_0x383735}=_0x113ec9;null==_0x383735||0x1===_0x383735?_0x4f6f6a['writer']['removeAttribute']('start',_0x540f3a):_0x4f6f6a['writer']['setAttribute']('start',String(_0x383735),_0x540f3a);}),_0xe61169['on']('attribute:footnotesListStyle:footnotesDefinitions',(_0x26baae,_0x5cf4a1,_0x19ba4f)=>{if(!_0x19ba4f['consumable']['consume'](_0x5cf4a1['item'],_0x26baae['name']))return;const _0x451274=C(_0x5cf4a1['item'],_0x19ba4f['mapper']),{attributeNewValue:_0x2ba1b6}=_0x5cf4a1;_0x2ba1b6&&'decimal'!==_0x2ba1b6?_0x19ba4f['writer']['setStyle']('list-style-type',_0x2ba1b6,_0x451274):_0x19ba4f['writer']['removeStyle']('list-style-type',_0x451274);});});}['_definePostfixer'](){const {editor:_0x1575c4}=this,{model:_0x197d0a}=_0x1575c4,_0x12a6e6=_0x1575c4['plugins']['get'](c),_0x1c7537=this['_getDefaultListStyle'](),_0x313969=this['_getDefaultStartIndex']();_0x197d0a['document']['registerPostFixer'](_0x20af3f=>{const _0x43c4d3=_0x197d0a['document']['differ']['getChanges']();let _0x5280af=!0x1;for(const _0x6d43df of _0x43c4d3){if('insert'!==_0x6d43df['type']||'$text'===_0x6d43df['name'])continue;const _0xef2448=_0x197d0a['createRangeOn'](_0x6d43df['position']['nodeAfter']);for(const _0x13b21c of _0xef2448['getItems']())_0x13b21c['is']('element','footnotesDefinitions')&&(!_0x13b21c['hasAttribute']('footnotesListStart')&&_0x197d0a['schema']['checkAttribute'](_0x13b21c,'footnotesListStart')&&(_0x20af3f['setAttribute']('footnotesListStart',_0x313969,_0x13b21c),_0x5280af=!0x0),!_0x13b21c['hasAttribute']('footnotesListStyle')&&_0x197d0a['schema']['checkAttribute'](_0x13b21c,'footnotesListStyle')&&(_0x20af3f['setAttribute']('footnotesListStyle',_0x1c7537,_0x13b21c),_0x5280af=!0x0));}return _0x5280af&&_0x12a6e6['_updateFootnotesCounters'](_0x20af3f),_0x5280af;});}['_defineFormatter'](){const {editor:_0x39d07a}=this;_0x39d07a['plugins']['get'](c)['setFootnoteFormatter'](_0x464f48=>this['_formatFootnoteListValue'](_0x464f48));}['_getDefaultListStyle'](){return this['editor']['config']['get']('footnotes.footnotesProperties.defaultListStyle');}['_getDefaultStartIndex'](){return this['editor']['config']['get']('footnotes.footnotesProperties.defaultStartIndex');}['_formatFootnoteListValue']({container:_0xd58840,value:_0x4abde3,digits:_0x3b80d6}){const _0x5c50a6=_0xd58840['getAttribute']('footnotesListStyle'),_0x54607a=_0xd58840['getAttribute']('footnotesListStart'),_0x437a89=Math['floor'](_0x4abde3)+(_0x54607a??0x1)-0x1;switch(_0x5c50a6){case'decimal-leading-zero':return function(_0xae279e,_0x4b7602){return String(_0xae279e)['padStart'](_0x4b7602,'0');}(_0x437a89,Math['max'](0x2,_0x3b80d6));case'lower-alpha':case'lower-latin':return M(_0x437a89,!0x1);case'upper-alpha':case'upper-latin':return M(_0x437a89,!0x0);case'lower-roman':return V(_0x437a89,!0x1);case'upper-roman':return V(_0x437a89,!0x0);default:return String(_0x437a89);}}}function C(_0x215d72,_0x47b5e4){const _0x4dce3f=_0x47b5e4['toViewElement'](_0x215d72);return Array['from'](_0x4dce3f['getChildren']())['find'](_0x50ca23=>_0x50ca23['is']('element','ol')&&_0x50ca23['hasClass']('footnotes-list'));}function M(_0xef0c92,_0xee38bd){let _0x325a0b='',_0x526a42=_0xef0c92;for(;_0x526a42>0x0;){const _0x2ce340=(_0x526a42-0x1)%0x1a;_0x325a0b=String['fromCharCode'](0x61+_0x2ce340)+_0x325a0b,_0x526a42=Math['floor']((_0x526a42-0x1)/0x1a);}return _0xee38bd?_0x325a0b['toUpperCase']():_0x325a0b;}const N=[{'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 V(_0x1bfbd3,_0x33354f){let _0x4c153f='',_0x3d774a=_0x1bfbd3;for(const {value:_0x430577,numeral:_0x3d4a15}of N)for(;_0x3d774a>=_0x430577;)_0x4c153f+=_0x3d4a15,_0x3d774a-=_0x430577;return _0x33354f?_0x4c153f:_0x4c153f['toLowerCase']();}class H extends _0x16ec18{['children'];['stylesView']=null;['additionalProperties']=null;['startIndexFieldView']=null;['focusTracker']=new et();['keystrokes']=new ot();['focusables']=new _0x24d7eb();['focusCycler'];constructor(_0x4c7092,{styleButtonViews:_0xef1a59,styleGridAriaLabel:_0x21fb29}){super(_0x4c7092),(this['focusCycler']=new _0x3fac62({'focusables':this['focusables'],'focusTracker':this['focusTracker'],'keystrokeHandler':this['keystrokes'],'actions':{'focusPrevious':'shift\x20+\x20tab','focusNext':'tab'}}),this['children']=this['createCollection'](),this['stylesView']=this['_appendStylesView'](_0xef1a59,_0x21fb29),[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 _0x429a4b of this['stylesView']['children'])this['stylesView']['focusTracker']['add'](_0x429a4b['element']);_0x30afc3({'keystrokeHandler':this['stylesView']['keystrokes'],'focusTracker':this['stylesView']['focusTracker'],'gridItems':this['stylesView']['children'],'numberOfColumns':()=>rt['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 _0x4449f4=_0x3596ba=>_0x3596ba['stopPropagation']();this['keystrokes']['set']('arrowright',_0x4449f4),this['keystrokes']['set']('arrowleft',_0x4449f4),this['keystrokes']['set']('arrowup',_0x4449f4),this['keystrokes']['set']('arrowdown',_0x4449f4);}this['keystrokes']['listenTo'](this['element']);}['focus'](){this['focusCycler']['focusFirst']();}['focusLast'](){this['focusCycler']['focusLast']();}['destroy'](){super['destroy'](),this['focusTracker']['destroy'](),this['keystrokes']['destroy']();}['_appendStylesView'](_0x56cd93,_0x1709c0){const _0x4a92ca=new _0x16ec18(this['locale']);return _0x4a92ca['children']=_0x4a92ca['createCollection'](),_0x4a92ca['children']['addMany'](_0x56cd93),_0x4a92ca['setTemplate']({'tag':'div','attributes':{'aria-label':_0x1709c0,'class':['ck','ck-footnotes-definitions-styles-list']},'children':_0x4a92ca['children']}),_0x4a92ca['children']['delegate']('execute')['to'](this),_0x4a92ca['focus']=function(){for(const _0x4355d2 of this['children'])if(_0x4355d2 instanceof _0x3fc837&&_0x4355d2['isOn'])return void _0x4355d2['focus']();this['children']['first']['focus']();},_0x4a92ca['focusTracker']=new et(),_0x4a92ca['keystrokes']=new ot(),_0x4a92ca['render'](),_0x4a92ca['keystrokes']['listenTo'](_0x4a92ca['element']),this['children']['add'](_0x4a92ca),_0x4a92ca;}['_appendAdditionalPropertiesCollapsibleView'](){const {t:t}=this['locale'],_0x534590=this['_createStartIndexPropertyView'](),_0x2f7342=[_0x534590],_0x17c40c=new tt(this['locale'],_0x2f7342);return _0x17c40c['set']({'label':t('Footnotes\x20properties'),'isCollapsed':!0x0}),_0x17c40c['buttonView']['bind']('isEnabled')['toMany'](_0x2f7342,'isEnabled',(..._0x42dc93)=>_0x42dc93['some'](_0x322d2f=>_0x322d2f)),_0x17c40c['buttonView']['on']('change:isEnabled',(_0xcc252b,_0x21917a,_0x58068d)=>{_0x58068d||(_0x17c40c['isCollapsed']=!0x0);}),this['children']['add'](_0x17c40c),[_0x534590,_0x17c40c];}['_createStartIndexPropertyView'](){const {t:t}=this['locale'],_0x2abef5=new st(this['locale'],it);return _0x2abef5['set']({'label':t('Footnotes\x20start\x20at'),'class':'ck-footnotes-definitions-properties__start-index'}),_0x2abef5['fieldView']['set']({'min':0x0,'max':Math['pow'](0x2,0x1e),'step':0x1,'value':0x1,'inputMode':'numeric'}),_0x2abef5['fieldView']['on']('input',()=>{const _0x24e592=_0x2abef5['fieldView']['element'],_0x2c3fb2=_0x24e592['valueAsNumber'];Number['isNaN'](_0x2c3fb2)?_0x2abef5['errorText']=t('Invalid\x20footnotes\x20start\x20index\x20value.'):_0x24e592['checkValidity']()?this['fire']('footnotesListStart',{'startIndex':_0x2c3fb2}):_0x2abef5['errorText']=t(_0x2c3fb2<0x0?'Footnotes\x20start\x20index\x20must\x20be\x20greater\x20than\x200.':'Footnotes\x20start\x20index\x20is\x20too\x20large.');}),_0x2abef5;}}class j extends _0x455464{static get['pluginName'](){return'FootnotesPropertiesUI';}static get['requires'](){return[_0x58e7ed,_0x4ed730];}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['init'](){const {editor:_0x4d446b}=this,{componentFactory:_0x3bc900}=_0x4d446b['ui'];_0x4d446b['config']['define']('footnotes.footnotesProperties.toolbar',['footnotesStyle']),_0x3bc900['add']('footnotesStyle',function(_0x419c56){return _0x36ad7e=>{const {t:t}=_0x36ad7e,_0x16061b=_0x419c56['commands']['get']('footnotesStyle'),_0x8aae44=_0x25312a(_0x36ad7e),{buttonView:_0x1c791d}=_0x8aae44;return _0x8aae44['class']='ck-footnotes-styles-dropdown',_0x8aae44['bind']('isEnabled')['to'](_0x16061b,'isEnabled'),_0x1c791d['set']({'label':t('Footnotes\x20style'),'icon':_0x28343b,'tooltip':!0x0}),_0x8aae44['once']('change:isOpen',()=>{const _0x521300=function({editor:_0x1cfc8b,dropdownView:_0x584dee}){const {t:t}=_0x1cfc8b['locale'],_0x11dd0c=t('Footnotes\x20definitions\x20styles'),_0x3f746c=function(_0x40f0fb){const t=_0x40f0fb['locale']['t'],_0x43130e=[{'label':t('Toggle\x20the\x20decimal\x20footnotes\x20style'),'tooltip':t('Decimal\x20footnotes'),'style':'decimal','icon':_0x2fe3d9},{'label':t('Toggle\x20the\x20decimal\x20with\x20leading\x20zero\x20footnotes\x20style'),'tooltip':t('Decimal\x20footnotes\x20with\x20leading\x20zero'),'style':'decimal-leading-zero','icon':_0xfa77b3},{'label':t('Toggle\x20the\x20lower–roman\x20footnotes\x20style'),'tooltip':t('Lower–roman\x20footnotes'),'style':'lower-roman','icon':_0x56fe8c},{'label':t('Toggle\x20the\x20upper–roman\x20footnotes\x20style'),'tooltip':t('Upper-roman\x20footnotes'),'style':'upper-roman','icon':_0x2c3adb},{'label':t('Toggle\x20the\x20lower–latin\x20footnotes\x20style'),'tooltip':t('Lower-latin\x20footnotes'),'style':'lower-latin','icon':_0x20b999},{'label':t('Toggle\x20the\x20upper–latin\x20footnotes\x20style'),'tooltip':t('Upper-latin\x20footnotes'),'style':'upper-latin','icon':_0x4c7353}];return _0x43130e['map'](function(_0x3fd3bb){const _0x554a4f=_0x3fd3bb['locale'];return({label:_0x1f5843,icon:_0xd99f13,tooltip:_0x4ffd21,style:_0x5d782e})=>{const _0x43ee67=_0x3fd3bb['commands']['get']('footnotesStyle'),_0x3430cf=new _0x3fc837(_0x554a4f);return _0x3430cf['set']({'label':_0x1f5843,'icon':_0xd99f13,'tooltip':_0x4ffd21}),_0x3430cf['bind']('isOn')['to'](_0x43ee67,'value',_0x350320=>_0x350320===_0x5d782e),_0x3430cf['bind']('isEnabled')['to'](_0x43ee67,'isEnabled'),_0x3430cf['on']('execute',()=>{_0x3fd3bb['execute']('footnotesStyle',{'value':_0x5d782e}),_0x3fd3bb['editing']['view']['focus']();}),_0x3430cf;};}(_0x40f0fb));}(_0x1cfc8b),_0x297d1c=new H(_0x1cfc8b['locale'],{'styleGridAriaLabel':_0x11dd0c,'styleButtonViews':_0x3f746c});return _0x297d1c['delegate']('execute')['to'](_0x584dee),_0x297d1c['on']('footnotesListStart',(_0x591b4c,_0x1c785b)=>{_0x1cfc8b['execute']('footnotesStart',{'value':_0x1c785b['startIndex']});}),_0x297d1c;}({'editor':_0x419c56,'dropdownView':_0x8aae44});_0x8aae44['panelView']['children']['add'](_0x521300);}),_0x8aae44;};}(_0x4d446b));}['afterInit'](){const {editor:_0x2051ab}=this,{t:t}=_0x2051ab['locale'],_0x2c83e6=_0x2051ab['plugins']['get'](_0x4ed730),{defaultPositions:_0x4b465c}=_0x4f2f53;_0x2c83e6['register']('footnotesDefinitions',{'ariaLabel':t('Footnotes\x20definitions\x20toolbar'),'items':_0x2051ab['config']['get']('footnotes.footnotesProperties.toolbar'),'balloonClassName':'ck-footnotes-style-balloon\x20ck-toolbar-container','getRelatedElement':_0x2a04f6=>{let _0x51a85d=_0x2a04f6['getFirstPosition']()?.['parent'];return _0x51a85d?.['is']('$text')&&(_0x51a85d=_0x51a85d['parent']),_0x51a85d?.['is']('element')?_0x51a85d['findAncestor'](J):null;},'positions':[_0x4b465c['southArrowNorth'],_0x4b465c['southArrowNorthMiddleWest'],_0x4b465c['southArrowNorthMiddleEast'],_0x4b465c['southArrowNorthWest'],_0x4b465c['southArrowNorthEast'],_0x4b465c['northArrowSouth'],_0x4b465c['northArrowSouthMiddleWest'],_0x4b465c['northArrowSouthMiddleEast'],_0x4b465c['northArrowSouthWest'],_0x4b465c['northArrowSouthEast'],_0x4b465c['viewportStickyNorth']]});}}class lt extends _0x455464{static get['pluginName'](){return'FootnotesProperties';}static get['requires'](){return[P,j];}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}}export{nt as Footnotes,e as FootnotesClipboard,r as FootnotesEditing,lt as FootnotesProperties,P as FootnotesPropertiesEditing,j as FootnotesPropertiesUI,b as FootnotesStartCommand,S as FootnotesStyleCommand,c as FootnotesTracker,i as FootnotesUI,w as InsertFootnoteCommand};
|
|
23
|
+
import{Plugin as _0x581f59,Command as _0x1a23cd}from'@ckeditor/ckeditor5-core/dist/index.js';import{toWidget as _0x10baaf,isWidget as _0x46acc9,toWidgetEditable as _0xe86660,WidgetToolbarRepository as _0x16f6bf}from'@ckeditor/ckeditor5-widget/dist/index.js';import{uid as _0x3b0ffc,logWarning as _0x1672ef,FocusTracker as et,KeystrokeHandler as ot,global as rt}from'@ckeditor/ckeditor5-utils/dist/index.js';import{PointerObserver as _0x3c43fc,ClickObserver as _0x4144eb}from'@ckeditor/ckeditor5-engine/dist/index.js';import{ClipboardPipeline as _0x139329}from'@ckeditor/ckeditor5-clipboard/dist/index.js';import{MenuBarMenuListItemButtonView as _0x53bd40,ButtonView as _0x11dc3b,View as _0x1cdf56,ViewCollection as _0x312a0c,FocusCycler as _0x59bf31,addKeyboardHandlingForGrid as _0xcf4ad2,CollapsibleView as tt,LabeledFieldView as st,createLabeledInputNumber as it,ContextualBalloon as _0x310f8a,BalloonPanelView as _0x2a82e4,createDropdown as _0x3d8114}from'@ckeditor/ckeditor5-ui/dist/index.js';import{IconFootnote as _0x18c523,IconListStyleDecimal as _0x237bc8,IconListStyleDecimalLeadingZero as _0x50f5af,IconListStyleLowerRoman as _0x23bace,IconListStyleUpperRoman as _0x195e78,IconListStyleLowerLatin as _0x548fdc,IconListStyleUpperLatin as _0x50454f}from'@ckeditor/ckeditor5-icons/dist/index.js';class F{['_model'];['_elementName'];['_getElementKey'];['_trackedElements']=new Map();constructor(_0x564f81,_0x3e82e7){this['_model']=_0x564f81,this['_elementName']=_0x3e82e7['elementName'],this['_getElementKey']=_0x3e82e7['getElementKey'];}['reset'](){this['_trackedElements']['clear']();}['getChanges'](_0x59d587){const _0x4e29fd=new Set(),_0x27130d=new Map();for(const _0x1954c3 of _0x59d587){if('insert'===_0x1954c3['type']&&'$text'!==_0x1954c3['name']&&_0x1954c3['position']['nodeAfter']){const _0x5318d6=this['_model']['createRangeOn'](_0x1954c3['position']['nodeAfter']);for(const _0x1d0fe8 of _0x5318d6['getItems']()){if(!_0x1d0fe8['is']('element',this['_elementName']))continue;const _0x159c6e=this['_getElementKey'](_0x1d0fe8);_0x27130d['has'](_0x159c6e)||_0x27130d['set'](_0x159c6e,[]),_0x27130d['get'](_0x159c6e)['push'](_0x1d0fe8);}}if('remove'===_0x1954c3['type']&&_0x1954c3['name']===this['_elementName']){const _0x380036=this['_getElementKey']({'getAttribute':_0x2ecea7=>_0x1954c3['attributes']['get'](_0x2ecea7)});_0x4e29fd['add'](_0x380036);}}for(const [_0x46c403,_0x280cfe]of this['_trackedElements'])'$graveyard'===_0x280cfe['root']['rootName']&&_0x4e29fd['add'](_0x46c403);for(const _0x5d7df2 of _0x4e29fd)this['_trackedElements']['delete'](_0x5d7df2);for(const [_0x5d8d68,_0x53abee]of _0x27130d)this['_trackedElements']['set'](_0x5d8d68,_0x53abee[_0x53abee['length']-0x1]);const _0x31014d=new Set();for(const [_0x29ae2d,_0x5ab94e]of _0x27130d)_0x4e29fd['has'](_0x29ae2d)&&(_0x31014d['add'](_0x5ab94e[0x0]),_0x5ab94e['length']>0x1?_0x27130d['set'](_0x29ae2d,_0x5ab94e['slice'](0x1)):_0x27130d['delete'](_0x29ae2d),_0x4e29fd['delete'](_0x29ae2d));return{'removed':Array['from'](_0x4e29fd),'inserted':Array['from'](_0x27130d['values']())['flat'](),'moved':Array['from'](_0x31014d)};}}class c extends _0x581f59{['_footnotes']=[];['_footnotesDefinitions']=null;['_footnoteFormatter']=null;['_footnoteDefsContainerTracker'];['_footnoteRefsTracker'];['_footnoteDefsTracker'];static get['pluginName'](){return'FootnotesTracker';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x10ad0f){super(_0x10ad0f),this['_footnoteDefsContainerTracker']=new F(this['editor']['model'],{'elementName':'footnotesDefinitions','getElementKey':()=>'singleton'}),this['_footnoteRefsTracker']=new F(this['editor']['model'],{'elementName':'footnoteRef','getElementKey':_0x46b6ae=>_0x46b6ae['getAttribute']('footnoteId')}),this['_footnoteDefsTracker']=new F(this['editor']['model'],{'elementName':'footnoteDefinition','getElementKey':_0x56c58a=>_0x56c58a['getAttribute']('footnoteId')});}['init'](){const {editor:_0x1285c1}=this,{model:_0x216bc5,data:_0x4bab24}=_0x1285c1;_0x216bc5['document']['registerPostFixer'](_0x1ba614=>{const _0x56944b=_0x216bc5['document']['differ']['getChanges']();let _0x19053e=!0x1;return this['_handleFootnotesDefinitionsObjectChanges'](_0x1ba614,_0x56944b)&&(_0x19053e=!0x0),this['_handleFootnoteDefinitionsChanges'](_0x1ba614,_0x56944b)&&(_0x19053e=!0x0),this['_handleFootnoteReferencesChanges'](_0x1ba614,_0x56944b)&&(_0x19053e=!0x0),this['_ensureFootnotesReferencesHaveProperOrder'](_0x1ba614)&&(_0x19053e=!0x0),this['_handleFootnotesDefinitionsObjectSync'](_0x1ba614)&&(_0x19053e=!0x0),this['_sortFootnoteDefinitions'](_0x1ba614)&&(_0x19053e=!0x0),_0x19053e;}),this['listenTo'](_0x216bc5['document'],'change:data',()=>{_0x216bc5['enqueueChange']({'isUndoable':!0x1},_0x4f460b=>{this['_ensureFootnotesDefinitionsContainerExists'](_0x4f460b);});},{'priority':'low'}),this['listenTo'](_0x4bab24,'set',()=>{this['_footnotes']=[],this['_footnoteDefsContainerTracker']['reset'](),this['_footnoteRefsTracker']['reset'](),this['_footnoteDefsTracker']['reset']();},{'priority':'high'});}['getFootnotesDefinitionsObjectElement'](){return this['_footnotesDefinitions'];}['getFootnote'](_0x5a1fa3){return this['_footnotes']['find'](_0x41bddd=>_0x41bddd['id']===_0x5a1fa3)||null;}['getFootnotes'](){return Array['from'](this['_footnotes']);}['getFootnotesFormatter'](){return this['_footnoteFormatter'];}['setFootnoteFormatter'](_0x95085){this['_footnoteFormatter']=_0x95085;}['_updateFootnotesCounters'](_0x2617fd,_0x44cf3d=0x0){let _0x42f89f=!0x1;for(let _0x1fb402=_0x44cf3d;_0x1fb402<this['_footnotes']['length'];_0x1fb402++)this['_updateFootnoteRefCounter'](_0x2617fd,_0x1fb402)&&(_0x42f89f=!0x0);return _0x42f89f;}['_insertEmptyFootnotesDefinitionsContainer'](_0x28699a,_0x1af2e3){const _0x2c62a4=_0x28699a['createElement']('footnotesDefinitions',{});return _0x28699a['append'](_0x2c62a4,_0x1af2e3),this['_footnotesDefinitions']=_0x2c62a4,_0x2c62a4;}['_ensureFootnotesDefinitionsContainerExists'](_0xaa4e88){if(!this['_footnotes']['length']||this['_footnotesDefinitions'])return;const _0x450f66=this['_footnotes'][0x0]['reference']['root'],_0x5b8fae=this['_insertEmptyFootnotesDefinitionsContainer'](_0xaa4e88,_0x450f66);for(const _0x255123 of this['_footnotes'])_0x255123['definition']['parent']||_0xaa4e88['insert'](_0x255123['definition'],_0x5b8fae,'end');this['_updateFootnotesCounters'](_0xaa4e88);}['_handleFootnotesDefinitionsObjectChanges'](_0x2f553e,_0x28070a){let _0x55455b=!0x1;const {inserted:_0x30611f,removed:_0x3695ab,moved:_0x25eb4e}=this['_footnoteDefsContainerTracker']['getChanges'](_0x28070a);if(_0x25eb4e['length']&&(this['_footnotesDefinitions']=_0x25eb4e[0x0]),_0x30611f['length']){if(_0x30611f['length']>0x1||this['_footnotesDefinitions']&&_0x30611f['some'](_0x43f2a6=>_0x43f2a6!==this['_footnotesDefinitions'])){const _0x294c06=_0x2f553e['createElement']('footnotesDefinitions',{}),_0x59d905=[];this['_footnotesDefinitions']&&_0x59d905['push'](this['_footnotesDefinitions']),_0x59d905['push'](..._0x30611f),_0x2f553e['insert'](_0x294c06,_0x59d905[0x0],'before');for(const _0x10d72c of _0x59d905)_0x2f553e['move'](_0x2f553e['createRangeIn'](_0x10d72c),_0x2f553e['createPositionAt'](_0x294c06,'end')),_0x2f553e['remove'](_0x10d72c);this['_footnotesDefinitions']=_0x294c06,this['_updateFootnotesCounters'](_0x2f553e),_0x55455b=!0x0;}else this['_footnotesDefinitions']=_0x30611f[0x0];}if(_0x3695ab['length']&&'$graveyard'===this['_footnotesDefinitions']?.['root']['rootName']){for(const _0x35a8c6 of this['_footnotes'])_0x2f553e['remove'](_0x35a8c6['reference']),_0x55455b=!0x0;this['_footnotes']=[],this['_footnotesDefinitions']=null;}return _0x55455b;}['_handleFootnoteDefinitionsChanges'](_0x9a32fb,_0x436231){let _0xe8cdc8=!0x1;const _0x1966fd=this['editor']['config']['get']('footnotes.multiBlock'),{inserted:_0x1f71d4,moved:_0x541273}=this['_footnoteDefsTracker']['getChanges'](_0x436231);for(const _0x95b796 of[..._0x541273,..._0x1f71d4]){const _0x42d8b6=_0x95b796['getAttribute']('footnoteId'),_0x46418f=this['getFootnote'](_0x42d8b6);_0x46418f&&(_0x46418f['definition']=_0x95b796),_(_0x9a32fb,_0x1966fd,_0x95b796)&&(_0xe8cdc8=!0x0);}return _0xe8cdc8;}['_handleFootnoteReferencesChanges'](_0x194bdf,_0x195010){let _0x16061f=!0x1;const {removed:_0x4b3601,inserted:_0x51a7f9,moved:_0x2854df}=this['_footnoteRefsTracker']['getChanges'](_0x195010);for(const _0x1f1aba of _0x4b3601)this['_handleRemoveFootnoteReferenceById'](_0x194bdf,_0x1f1aba)&&(_0x16061f=!0x0);for(const _0x5a6443 of _0x51a7f9)this['_handleInsertedFootnoteReference'](_0x194bdf,_0x5a6443)&&(_0x16061f=!0x0);for(const _0x528621 of _0x2854df)this['_handleMovedFootnoteReference'](_0x194bdf,_0x528621)&&(_0x16061f=!0x0);return _0x16061f;}['_handleFootnotesDefinitionsObjectSync'](_0x1ae768){if(!this['_footnotesDefinitions'])return!0x1;let _0x24518a=!0x1;if(this['_footnotesDefinitions']['childCount']!==this['_footnotes']['length']){const _0x57bbb8=[];for(const _0x73ca7e of this['_footnotesDefinitions']['getChildren']()){const _0x338da6=_0x73ca7e['getAttribute']('footnoteId');this['getFootnote'](_0x338da6)||(_0x57bbb8['unshift'](_0x73ca7e),_0x24518a=!0x0);}for(const _0x2af9fe of _0x57bbb8)_0x1ae768['remove'](_0x2af9fe);}const _0x276f1d=new Set(),_0x4d0a69=[];for(const _0x4929e3 of this['_footnotesDefinitions']['getChildren']()){const _0x59e7d0=_0x4929e3['getAttribute']('footnoteId');_0x276f1d['has'](_0x59e7d0)?(_0x4d0a69['unshift'](_0x4929e3),_0x24518a=!0x0):_0x276f1d['add'](_0x59e7d0);}for(const _0x434171 of _0x4d0a69)_0x1ae768['remove'](_0x434171);return this['_footnotesDefinitions']['childCount']||(_0x1ae768['remove'](this['_footnotesDefinitions']),this['_footnotesDefinitions']=null,_0x24518a=!0x0),_0x24518a;}['_handleInsertedFootnoteReference'](_0x2d073d,_0x317b02){if(this['_footnotes']['find'](_0x150e08=>_0x150e08['reference']===_0x317b02))return!0x1;let _0x3ce981=!0x1;const _0x14acab=_0x317b02['getAttribute']('footnoteId'),_0xf200ad=this['_footnotes']['findIndex'](_0x404e30=>_0x404e30['id']===_0x14acab);-0x1!==_0xf200ad&&(_0x2d073d['remove'](this['_footnotes'][_0xf200ad]['reference']),this['_footnotes']['splice'](_0xf200ad,0x1),_0x3ce981=!0x0);let _0x46a6d5=this['_footnotesDefinitions']?function(_0x1e77a0,_0x4b0cf0){for(const _0x15b7ac of _0x1e77a0['getChildren']())if(_0x15b7ac['getAttribute']('footnoteId')===_0x4b0cf0)return _0x15b7ac;return null;}(this['_footnotesDefinitions'],_0x14acab):null;_0x46a6d5||(_0x46a6d5=_0x2d073d['createElement']('footnoteDefinition',{'footnoteId':_0x14acab}),this['_footnotesDefinitions']&&(_0x2d073d['insert'](_0x46a6d5,this['_footnotesDefinitions'],'end'),_0x3ce981=!0x0));const _0xd01024={'id':_0x14acab,'reference':_0x317b02,'definition':_0x46a6d5},_0x4690f5=I(this['editor']['model'],this['_footnotes'],_0x317b02);this['_footnotes']['splice'](_0x4690f5,0x0,_0xd01024);let _0x34ebc1=_0x4690f5;return-0x1!==_0xf200ad&&(_0x34ebc1=Math['min'](_0x4690f5,_0xf200ad)),this['_updateFootnotesCounters'](_0x2d073d,_0x34ebc1)&&(_0x3ce981=!0x0),_0x3ce981;}['_handleRemoveFootnoteReferenceById'](_0x638127,_0x39048b){const _0x1708a3=this['_footnotes']['findIndex'](_0x1d09dd=>_0x1d09dd['id']===_0x39048b);if(-0x1===_0x1708a3)return!0x1;let _0x50e9c0=!0x1;const _0x295393=this['_footnotes'][_0x1708a3];return'$graveyard'!==_0x295393['definition']['root']['rootName']&&(_0x638127['remove'](_0x295393['definition']),_0x50e9c0=!0x0),this['_footnotes']['splice'](_0x1708a3,0x1),this['_updateFootnotesCounters'](_0x638127,_0x1708a3)&&(_0x50e9c0=!0x0),_0x50e9c0;}['_handleMovedFootnoteReference'](_0x243a1a,_0x5b4086){const _0x53a602=_0x5b4086['getAttribute']('footnoteId'),_0x3bbab2=this['_footnotes']['findIndex'](_0x3bc6b7=>_0x3bc6b7['id']===_0x53a602),_0x3ad7e8=this['_footnotes'][_0x3bbab2];let _0x407ee4=!0x1;_0x3ad7e8['reference']=_0x5b4086,this['_footnotes']['splice'](_0x3bbab2,0x1);const _0x502643=I(this['editor']['model'],this['_footnotes'],_0x5b4086);return this['_footnotes']['splice'](_0x502643,0x0,_0x3ad7e8),this['_updateFootnotesCounters'](_0x243a1a,Math['min'](_0x3bbab2,_0x502643))&&(_0x407ee4=!0x0),_0x407ee4;}['_updateFootnoteRefCounter'](_0xf0fe92,_0x16509e){if(!this['_footnotesDefinitions'])return!0x1;const _0x4de081=this['_footnotes'][_0x16509e];let _0x455c59;return _0x455c59=this['_footnoteFormatter']?this['_footnoteFormatter']({'footnote':_0x4de081,'container':this['_footnotesDefinitions'],'digits':String(this['_footnotes']['length'])['length'],'value':_0x16509e+0x1}):String(_0x16509e+0x1),_0x4de081['reference']['getAttribute']('footnoteCounter')!=_0x455c59&&(_0xf0fe92['setAttribute']('footnoteCounter',_0x455c59,_0x4de081['reference']),!0x0);}['_sortFootnoteDefinitions'](_0x4f78ca){if(!this['_footnotesDefinitions']||this['_footnotes']['length']<0x2)return!0x1;if(function(_0xef4b56,_0x21cf9e){if(_0xef4b56['length']!==_0x21cf9e['length'])return!0x1;for(let _0x92ddbc=0x0;_0x92ddbc<_0xef4b56['length'];_0x92ddbc++)if(_0xef4b56[_0x92ddbc]!==_0x21cf9e[_0x92ddbc])return!0x1;return!0x0;}(this['_footnotes']['map'](_0x329bd2=>_0x329bd2['id']),Array['from'](this['_footnotesDefinitions']['getChildren']())['map'](_0x4e75a4=>_0x4e75a4['getAttribute']('footnoteId'))))return!0x1;let _0x171d09=!0x1;for(let _0x71c1fe=0x0;_0x71c1fe<this['_footnotes']['length'];_0x71c1fe++){const _0x5bb4c8=this['_footnotes'][_0x71c1fe],_0x1bfbef=_0x4f78ca['createPositionBefore'](_0x5bb4c8['definition']),_0x382fc2=_0x4f78ca['createPositionAt'](this['_footnotesDefinitions'],_0x71c1fe);_0x1bfbef['isEqual'](_0x382fc2)||(_0x4f78ca['move'](_0x4f78ca['createRangeOn'](_0x5bb4c8['definition']),_0x382fc2),_0x171d09=!0x0);}return _0x171d09;}['_ensureFootnotesReferencesHaveProperOrder'](_0xc6e337){if(!this['_footnotes']['length'])return!0x1;const {model:_0x4708b4}=this['editor'];let _0x438ec6=!0x1;for(let _0x461ac2=0x0;_0x461ac2<this['_footnotes']['length']-0x1;_0x461ac2++){const _0x4269bc=this['_footnotes'][_0x461ac2],_0x17df0a=this['_footnotes'][_0x461ac2+0x1],_0xe9113e=_0x4708b4['createPositionBefore'](_0x4269bc['reference']),_0x20e9be=_0x4708b4['createPositionBefore'](_0x17df0a['reference']);'after'===_0xe9113e['compareWith'](_0x20e9be)&&(this['_handleMovedFootnoteReference'](_0xc6e337,_0x4269bc['reference']),_0x461ac2=-0x1,_0x438ec6=!0x0);}return _0x438ec6;}}function _(_0x272993,_0x538f89,_0x1b52af){if(_0x1b52af['childCount'])return!0x1;const _0x43d0cb=_0x538f89?'paragraph':'footnoteInlineContent';return _0x272993['insert'](_0x272993['createElement'](_0x43d0cb),_0x1b52af),!0x0;}function I(_0x1c5e12,_0x35cd9f,_0x3d3aa1){if(0x0===_0x35cd9f['length'])return 0x0;const _0x8773ed=_0x1c5e12['createPositionBefore'](_0x3d3aa1);for(let _0x506cbe=0x0;_0x506cbe<_0x35cd9f['length'];_0x506cbe++){const _0x2e9a9c=_0x35cd9f[_0x506cbe],_0x4de97b=_0x1c5e12['createPositionBefore'](_0x2e9a9c['reference']);if('before'===_0x8773ed['compareWith'](_0x4de97b))return _0x506cbe;}const _0x29d4b8=_0x3d3aa1['root'];let _0x37d728=-0x1;for(let _0x528516=_0x35cd9f['length']-0x1;_0x528516>=0x0;_0x528516--)if(_0x35cd9f[_0x528516]['reference']['root']===_0x29d4b8){_0x37d728=_0x528516;break;}if(-0x1!==_0x37d728)return _0x37d728+0x1;const _0x540caf=_0x1c5e12['document']['getRootNames'](),_0x54518b=_0x540caf['indexOf'](_0x29d4b8['rootName']),_0x58dd66=_0x540caf[_0x54518b+0x1];if(_0x58dd66){for(let _0x40ab74=0x0;_0x40ab74<_0x35cd9f['length'];_0x40ab74++)if(_0x35cd9f[_0x40ab74]['reference']['root']['rootName']===_0x58dd66)return _0x40ab74;}return _0x35cd9f['length'];}class w extends _0x1a23cd{['refresh'](){const _0x267ea4=this['editor']['model']['document']['selection'],_0x2b2820=this['_getPositionToInsertFootnote'](_0x267ea4);this['isEnabled']=!!_0x2b2820;}['execute'](_0x40f754){const {editor:_0x27286a}=this,{model:_0x128c26}=_0x27286a,{selection:_0x667b3b}=_0x128c26['document'],_0x397ff2=this['_getPositionToInsertFootnote'](_0x667b3b);if(!_0x397ff2)return;const _0x23390c=_0x27286a['plugins']['get']('FootnotesEditing'),_0x1d381c=_0x40f754?.['footnoteId']??_0x3b0ffc();!function(_0x4ce491){return'string'==typeof _0x4ce491&&_0x4ce491['length']>0x0&&!/\s/['test'](_0x4ce491)&&!/^\d/['test'](_0x4ce491);}(_0x1d381c)?_0x1672ef('insert-footnote-command-executed-with-invalid-id'):(_0x128c26['change'](_0xf1dc6c=>{const _0x5cc81e=_0xf1dc6c['createElement']('footnoteRef',{'footnoteId':_0x1d381c});_0x128c26['insertObject'](_0x5cc81e,_0x397ff2,null);}),_0x23390c['_moveSelectionToFootnoteDefinition'](_0x1d381c));}['_getPositionToInsertFootnote'](_0x5e0dc8){const {model:_0x43a8ac}=this['editor'],{schema:_0xdf4066}=_0x43a8ac,_0x4489f0=_0x5e0dc8['getFirstRange']();for(const _0x26fb14 of _0x4489f0['getItems']())if(_0xdf4066['isBlock'](_0x26fb14)||_0xdf4066['isObject'](_0x26fb14))return null;const _0x5f4165=_0x4489f0['end'];return _0xdf4066['checkChild'](_0x5f4165,'footnoteRef')?_0x5f4165:null;}}class r extends _0x581f59{static get['pluginName'](){return'FootnotesEditing';}static get['requires'](){return[c];}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['init'](){const {editor:_0x274453}=this;_0x274453['config']['define']('footnotes.multiBlock',!0x0),_0x274453['commands']['add']('insertFootnote',new w(_0x274453)),this['_defineSchema'](),this['_defineRefsConverters'](),this['_defineDefinitionsConverters'](),this['_defineDefinitionConverters'](),this['_defineBogusParagraphConverters'](),this['_defineKeyboardHandlers'](),this['_defineClickHandlers']();}['afterInit'](){!async function(_0x791041){const _0x2ee0fd=_0x58e709([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]),_0x158923=0x47a28506,_0x44a894=0x47a5fd0e^_0x158923,_0x4d4425=window[_0x58e709([0x44,0x61,0x74,0x65])][_0x58e709([0x6e,0x6f,0x77])](),_0x5bca00=_0x791041[_0x58e709([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x4203ab=new window[(_0x58e709([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x19e29c=>{_0x5bca00[_0x58e709([0x6f,0x6e,0x63,0x65])](_0x58e709([0x72,0x65,0x61,0x64,0x79]),_0x19e29c);}),_0xf4c30c={[_0x58e709([0x6b,0x74,0x79])]:_0x58e709([0x45,0x43]),[_0x58e709([0x75,0x73,0x65])]:_0x58e709([0x73,0x69,0x67]),[_0x58e709([0x63,0x72,0x76])]:_0x58e709([0x50,0x2d,0x32,0x35,0x36]),[_0x58e709([0x78])]:_0x58e709([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]),[_0x58e709([0x79])]:_0x58e709([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]),[_0x58e709([0x61,0x6c,0x67])]:_0x58e709([0x45,0x53,0x32,0x35,0x36])},_0x19ad20=_0x5bca00[_0x58e709([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x58e709([0x67,0x65,0x74])](_0x58e709([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x18e666(){let _0x2b65de,_0x59c347=null,_0xc8c25c=null;try{if(_0x19ad20==_0x58e709([0x47,0x50,0x4c]))return _0x58e709([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x2b65de=_0x1bc04d(),!_0x2b65de)return _0x58e709([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x2b65de[_0x58e709([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0xc8c25c=_0x26949a(_0x2b65de[_0x58e709([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x2b65de[_0x58e709([0x6a,0x74,0x69])])),await _0x1c1115()?_0x39bf32()?_0x257814()?_0x58e709([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x236d02()?(_0x2b65de[_0x58e709([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x58e709([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x59c347=_0x20905f(_0x58e709([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x2b65de[_0x58e709([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x58e709([0x74,0x72,0x69,0x61,0x6c])&&(_0x59c347=_0x20905f(_0x58e709([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),await _0x553ab1()):_0x58e709([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x58e709([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x58e709([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch{return _0x58e709([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x257814(){const _0x303f85=[_0x58e709([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x58e709([0x74,0x72,0x69,0x61,0x6c])][_0x58e709([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x2b65de[_0x58e709([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x4d4425/0x3e8:0xe10*_0x44a894;return _0x2b65de[_0x58e709([0x65,0x78,0x70])]<_0x303f85;}function _0x39bf32(){const _0x181d18=_0x2b65de[_0x58e709([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];return!!_0x181d18&&(!!_0x181d18[_0x58e709([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x58e709([0x2a]))||!!_0x181d18[_0x58e709([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x58e709([0x46,0x4f,0x4f])));}function _0x236d02(){const _0x45b4e1=_0x2b65de[_0x58e709([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x45b4e1||0x0==_0x45b4e1[_0x58e709([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x2d4b32}=new URL(window[_0x58e709([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x45b4e1[_0x58e709([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x2d4b32))return!0x0;const _0x4a01a6=_0x2d4b32[_0x58e709([0x73,0x70,0x6c,0x69,0x74])](_0x58e709([0x2e]));return _0x45b4e1[_0x58e709([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x1e19d6=>_0x1e19d6[_0x58e709([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x58e709([0x2a])))[_0x58e709([0x6d,0x61,0x70])](_0x4aff0b=>_0x4aff0b[_0x58e709([0x73,0x70,0x6c,0x69,0x74])](_0x58e709([0x2e])))[_0x58e709([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x131f0c=>_0x131f0c[_0x58e709([0x6c,0x65,0x6e,0x67,0x74,0x68])]<=_0x4a01a6[_0x58e709([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x58e709([0x6d,0x61,0x70])](_0x4411be=>Array(_0x4a01a6[_0x58e709([0x6c,0x65,0x6e,0x67,0x74,0x68])]-_0x4411be[_0x58e709([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x58e709([0x66,0x69,0x6c,0x6c])](_0x4411be[0x0]===_0x58e709([0x2a])?_0x58e709([0x2a]):'')[_0x58e709([0x63,0x6f,0x6e,0x63,0x61,0x74])](_0x4411be))[_0x58e709([0x73,0x6f,0x6d,0x65])](_0x13adbf=>_0x4a01a6[_0x58e709([0x65,0x76,0x65,0x72,0x79])]((_0x4a7d11,_0x55b9a4)=>_0x13adbf[_0x55b9a4]===_0x4a7d11||_0x13adbf[_0x55b9a4]===_0x58e709([0x2a])));}function _0x553ab1(){return _0x59c347&&_0xc8c25c?new window[(_0x58e709([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x5308e8,_0x392c4d)=>{_0x59c347[_0x58e709([0x74,0x68,0x65,0x6e])](_0x5308e8,_0x392c4d),_0xc8c25c[_0x58e709([0x74,0x68,0x65,0x6e])](_0x49f129=>{_0x49f129!=_0x58e709([0x56,0x61,0x6c,0x69,0x64])&&_0x5308e8(_0x49f129);},_0x392c4d);}):_0x59c347||_0xc8c25c||_0x58e709([0x56,0x61,0x6c,0x69,0x64]);}}function _0x26949a(_0x55c3a5,_0xcdabb3){return new window[(_0x58e709([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x4ff512=>{if(_0x2aa258())return _0x4ff512(_0x58e709([0x56,0x61,0x6c,0x69,0x64]));_0x41e5c5(),_0x5bca00[_0x58e709([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x58e709([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x497278=!0x1;const _0x14ee79=_0x3b0ffc();function _0x1a60a1(_0x530917){return!!_0x530917&&(typeof _0x530917===_0x58e709([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x530917===_0x58e709([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x530917[_0x58e709([0x74,0x68,0x65,0x6e])]===_0x58e709([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x530917[_0x58e709([0x63,0x61,0x74,0x63,0x68])]===_0x58e709([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x45a0ce(_0x5d2da7){_0x398e94(_0x5d2da7)[_0x58e709([0x74,0x68,0x65,0x6e])](_0x2ae1f3=>{if(!_0x2ae1f3||_0x2ae1f3[_0x58e709([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x58e709([0x6f,0x6b]))return _0x58e709([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x19bd1f(_0x248353(_0x14ee79+_0xcdabb3))!=_0x2ae1f3[_0x58e709([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x58e709([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x58e709([0x56,0x61,0x6c,0x69,0x64]);})[_0x58e709([0x74,0x68,0x65,0x6e])](_0x59aa11=>(_0x244159(),_0x59aa11),()=>{const _0x2acbc3=_0x3e41b0();return null==_0x2acbc3?(_0x244159(),_0x58e709([0x56,0x61,0x6c,0x69,0x64])):_0x58e709(_0x4d4425-_0x2acbc3>(0x63ae0106^_0x158923)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x58e709([0x74,0x68,0x65,0x6e])](_0x4ff512)[_0x58e709([0x63,0x61,0x74,0x63,0x68])](()=>{_0x4ff512(_0x58e709([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x5609a9=0x47946b86^_0x158923;function _0x244159(){const _0x3d8295=_0x58e709([0x6c,0x6c,0x63,0x74,0x2d])+_0x19bd1f(_0x248353(_0x55c3a5)),_0x239cdf=_0x175bab(_0x19bd1f(window[_0x58e709([0x4d,0x61,0x74,0x68])][_0x58e709([0x63,0x65,0x69,0x6c])](_0x4d4425/_0x5609a9)));window[_0x58e709([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x58e709([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x3d8295,_0x239cdf);}function _0x3e41b0(){const _0x3223e2=_0x58e709([0x6c,0x6c,0x63,0x74,0x2d])+_0x19bd1f(_0x248353(_0x55c3a5)),_0x344637=window[_0x58e709([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x58e709([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x3223e2);return _0x344637?window[_0x58e709([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x175bab(_0x344637),0x10)*_0x5609a9:null;}function _0x398e94(_0x3c9fdc){return new window[(_0x58e709([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x3ee49f,_0x3e2e68)=>{_0x3c9fdc[_0x58e709([0x74,0x68,0x65,0x6e])](_0x3ee49f,_0x3e2e68),window[_0x58e709([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x3e2e68,0x47a351c6^_0x158923);});}}_0x5bca00[_0x58e709([0x6f,0x6e])](_0x58e709([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0xb682,_0x5cc434)=>{if(_0x5cc434[0x0]!=_0x55c3a5)return _0x4ff512(_0x58e709([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x5cc434[0x1]={..._0x5cc434[0x1],[_0x58e709([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x14ee79};},{[_0x58e709([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x58e709([0x68,0x69,0x67,0x68])}),_0x5bca00[_0x58e709([0x6f,0x6e])](_0x58e709([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x3ac025=>{_0x1a60a1(_0x3ac025[_0x58e709([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x497278=!0x0,_0x45a0ce(_0x3ac025[_0x58e709([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x58e709([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x58e709([0x6c,0x6f,0x77])}),_0x4203ab[_0x58e709([0x74,0x68,0x65,0x6e])](()=>{_0x497278||_0x4ff512(_0x58e709([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x2aa258(){return _0x5bca00[_0x58e709([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x58e709([0x76,0x69,0x65,0x77])][_0x58e709([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x58e709([0x61,0x75,0x74,0x6f]);}function _0x41e5c5(){_0x5bca00[_0x58e709([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x58e709([0x76,0x69,0x65,0x77])][_0x58e709([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x58e709([0x61,0x75,0x74,0x6f]);}}function _0x20905f(_0x56e2dd){const _0x562e67=[new window[(_0x58e709([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x24715f=>setTimeout(_0x24715f,0x47abbbca^_0x158923)),_0x4203ab[_0x58e709([0x74,0x68,0x65,0x6e])](()=>new window[(_0x58e709([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0xc25fdd=>{let _0x2634f4=0x0;_0x5bca00[_0x58e709([0x6d,0x6f,0x64,0x65,0x6c])][_0x58e709([0x6f,0x6e])](_0x58e709([0x61,0x70,0x70,0x6c,0x79,0x4f,0x70,0x65,0x72,0x61,0x74,0x69,0x6f,0x6e]),(_0xf07dd7,_0x36e65a)=>{_0x36e65a[0x0][_0x58e709([0x69,0x73,0x44,0x6f,0x63,0x75,0x6d,0x65,0x6e,0x74,0x4f,0x70,0x65,0x72,0x61,0x74,0x69,0x6f,0x6e])]&&_0x2634f4++,_0x2634f4==(0x47a284fe^_0x158923)&&(_0xc25fdd(),_0xf07dd7[_0x58e709([0x6f,0x66,0x66])]());});}))];return window[_0x58e709([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x58e709([0x72,0x61,0x63,0x65])](_0x562e67)[_0x58e709([0x74,0x68,0x65,0x6e])](()=>_0x56e2dd);}async function _0x3a5e50(){await _0x4203ab,_0x5bca00[_0x58e709([0x6d,0x6f,0x64,0x65,0x6c])][_0x58e709([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x2ae972,_0x5bca00[_0x58e709([0x6d,0x6f,0x64,0x65,0x6c])][_0x58e709([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x2ae972,_0x5bca00[_0x58e709([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x58e709([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x402cbc(_0x5da89c){const _0x552b6b=_0x1ece04();_0x5bca00[_0x552b6b]=_0x58e709([0x66,0x6f,0x6f,0x74,0x6e,0x6f,0x74,0x65,0x73,0x4c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79])+_0x5da89c,_0x5da89c!=_0x58e709([0x56,0x61,0x6c,0x69,0x64])&&_0x3a5e50();}function _0x1ece04(){const _0xeae59a=window[_0x58e709([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x58e709([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x58e709([0x6e,0x6f,0x77])]())[_0x58e709([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x58e709([0x2e]),'');let _0x3e6200=_0x58e709([0x75]);for(let _0x223212=0x0;_0x223212<_0xeae59a[_0x58e709([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x223212+=0x2){let _0x5577cb=window[_0x58e709([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0xeae59a[_0x58e709([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x223212,_0x223212+0x2));_0x5577cb>=_0x2ee0fd[_0x58e709([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x5577cb-=_0x2ee0fd[_0x58e709([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x3e6200+=_0x2ee0fd[_0x5577cb];}return _0x3e6200;}function _0x1bc04d(){const _0x34e1a1=_0x19ad20[_0x58e709([0x73,0x70,0x6c,0x69,0x74])](_0x58e709([0x2e]));if(0x3!=_0x34e1a1[_0x58e709([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x5f4d0e(_0x34e1a1[0x1]);function _0x5f4d0e(_0x1a7bdd){const _0x48458a=_0x362b97(_0x1a7bdd);return _0x48458a&&_0x169c7a()?_0x48458a:null;function _0x169c7a(){const _0x237d26=_0x48458a[_0x58e709([0x6a,0x74,0x69])],_0x34bf76=window[_0x58e709([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x237d26[_0x58e709([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x237d26[_0x58e709([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0xc35060={..._0x48458a,[_0x58e709([0x6a,0x74,0x69])]:_0x237d26[_0x58e709([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x237d26[_0x58e709([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0xc35060[_0x58e709([0x76,0x63])],_0x248353(_0xc35060)==_0x34bf76;}}}async function _0x1c1115(){let _0x573958=!0x0;try{const _0x43c6c5=_0x19ad20[_0x58e709([0x73,0x70,0x6c,0x69,0x74])](_0x58e709([0x2e])),[_0x4ef351,_0x2b822c,_0x56d4dd]=_0x43c6c5;return _0x34d851(_0x4ef351),await _0x566ce0(_0x4ef351,_0x2b822c,_0x56d4dd),_0x573958;}catch{return!0x1;}function _0x34d851(_0xcc356f){const _0x6cf6ad=_0x362b97(_0xcc356f);_0x6cf6ad&&_0x6cf6ad[_0x58e709([0x61,0x6c,0x67])]==_0x58e709([0x45,0x53,0x32,0x35,0x36])||(_0x573958=!0x1);}async function _0x566ce0(_0x2cd7aa,_0x3f54e7,_0x3f0e6d){const _0x2a977c=window[_0x58e709([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x58e709([0x66,0x72,0x6f,0x6d])](_0x1fb728(_0x3f0e6d),_0x42a709=>_0x42a709[_0x58e709([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x141e9c=new window[(_0x58e709([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x58e709([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x2cd7aa+_0x58e709([0x2e])+_0x3f54e7),_0x4151f2=window[_0x58e709([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x58e709([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x4151f2)return;const _0x20b532=await _0x4151f2[_0x58e709([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x58e709([0x6a,0x77,0x6b]),_0xf4c30c,{[_0x58e709([0x6e,0x61,0x6d,0x65])]:_0x58e709([0x45,0x43,0x44,0x53,0x41]),[_0x58e709([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x58e709([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x58e709([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x4151f2[_0x58e709([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x58e709([0x6e,0x61,0x6d,0x65])]:_0x58e709([0x45,0x43,0x44,0x53,0x41]),[_0x58e709([0x68,0x61,0x73,0x68])]:{[_0x58e709([0x6e,0x61,0x6d,0x65])]:_0x58e709([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x20b532,_0x2a977c,_0x141e9c)||(_0x573958=!0x1);}}function _0x362b97(_0x452be5){return _0x452be5[_0x58e709([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x58e709([0x65,0x79]))?JSON[_0x58e709([0x70,0x61,0x72,0x73,0x65])](_0x1fb728(_0x452be5)):null;}function _0x1fb728(_0xc9868d){return window[_0x58e709([0x61,0x74,0x6f,0x62])](_0xc9868d[_0x58e709([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x58e709([0x2b]))[_0x58e709([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x58e709([0x2f])));}function _0x248353(_0x1bf303){let _0xa1dafd=0x1505;function _0x13f665(_0x3439db){for(let _0x2fd35b=0x0;_0x2fd35b<_0x3439db[_0x58e709([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x2fd35b++){const _0x4e9954=_0x3439db[_0x58e709([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x2fd35b);_0xa1dafd=(_0xa1dafd<<0x5)+_0xa1dafd+_0x4e9954,_0xa1dafd&=_0xa1dafd;}}function _0x5e5cf3(_0x2c83f1){Array[_0x58e709([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x2c83f1)?_0x2c83f1[_0x58e709([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x5e5cf3):_0x2c83f1&&typeof _0x2c83f1==_0x58e709([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x58e709([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x2c83f1)[_0x58e709([0x73,0x6f,0x72,0x74])]()[_0x58e709([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x3337c1,_0x2b0ef7])=>{_0x13f665(_0x3337c1),_0x5e5cf3(_0x2b0ef7);}):_0x13f665(window[_0x58e709([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x2c83f1));}return _0x5e5cf3(_0x1bf303),_0xa1dafd>>>0x0;}function _0x19bd1f(_0x4fc8d0){return _0x4fc8d0[_0x58e709([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x58e709([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x58e709([0x30]));}function _0x175bab(_0x152dbd){return _0x152dbd[_0x58e709([0x73,0x70,0x6c,0x69,0x74])]('')[_0x58e709([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x58e709([0x6a,0x6f,0x69,0x6e])]('');}function _0x2ae972(){}function _0x58e709(_0x1ac701){return _0x1ac701['map'](_0x4ad5af=>String['fromCharCode'](_0x4ad5af))['join']('');}_0x402cbc(await _0x18e666());}(this);}['_moveSelectionToFootnoteDefinition'](_0x3fd70c){const {plugins:_0xb515dc,editing:_0x46f6ea,model:_0x339803}=this['editor'],_0x1fe42f=_0xb515dc['get'](c)['getFootnote'](_0x3fd70c);return!!_0x1fe42f&&(_0x339803['change'](_0x182a00=>{_0x182a00['setSelection'](_0x182a00['createPositionAt'](_0x1fe42f['definition'],'end'));}),_0x46f6ea['view']['scrollToTheSelection'](),!0x0);}['_moveSelectionToFootnoteReference'](_0x1d4a3e){const {plugins:_0x4f4c59,editing:_0xc04bb4,model:_0x5d7c20}=this['editor'],_0x54102e=_0x4f4c59['get'](c)['getFootnote'](_0x1d4a3e);return!!_0x54102e&&(_0x5d7c20['change'](_0x2e6aef=>{_0x2e6aef['setSelection'](_0x54102e['reference'],'on');}),_0xc04bb4['view']['scrollToTheSelection'](),!0x0);}['_defineSchema'](){const {schema:_0x23c341}=this['editor']['model'],_0xe5348b=this['editor']['config']['get']('footnotes.multiBlock');_0x23c341['register']('footnoteRef',{'inheritAllFrom':'$inlineObject','allowAttributes':['footnoteId','footnoteCounter']}),_0x23c341['register']('footnotesDefinitions',{'inheritAllFrom':'$blockObject','allowChildren':['footnoteDefinition']}),_0x23c341['register']('footnoteDefinition',{'allowAttributes':['footnoteId'],'disallowAttributes':['listItemId'],'isLimit':!0x0}),_0xe5348b?_0x23c341['extend']('footnoteDefinition',{'allowContentOf':'$container'}):_0x23c341['register']('footnoteInlineContent',{'allowIn':'footnoteDefinition','allowContentOf':'$block','isLimit':!0x0}),_0x23c341['addChildCheck'](_0x39301f=>{for(const _0x269a46 of _0x39301f)if('footnoteDefinition'===_0x269a46['name'])return!0x1;},'footnoteRef');}['_defineRefsConverters'](){const {editor:_0x52656a}=this,{conversion:_0x408fc4,editing:_0x169415}=_0x52656a,{t:t}=_0x52656a['locale'];_0x408fc4['for']('upcast')['elementToElement']({'view':{'name':'sup','classes':'footnote'},'model':(_0x4fbf4d,{writer:_0xb4f83c,consumable:_0x37d8c1})=>{const _0x2f6d61=_0x4fbf4d['getChild'](0x0);if(!_0x2f6d61||!_0x2f6d61['is']('element','a'))return null;const _0x4ac098=_0x2f6d61['getAttribute']('href')||'';if(!_0x4ac098['startsWith']('#'))return null;const _0xe18f97=_0x4ac098['replace'](/^#/,'');if(!_0xe18f97)return null;_0x37d8c1['consume'](_0x2f6d61,{'name':!0x0,'attributes':['href']});for(const {item:_0x56c7f8}of _0x169415['view']['createRangeIn'](_0x2f6d61))_0x56c7f8['is']('$textProxy')?_0x37d8c1['consume'](_0x56c7f8['textNode'],{'name':!0x0}):_0x56c7f8['is']('element')&&_0x37d8c1['consume'](_0x56c7f8,{'name':!0x0});return _0xb4f83c['createElement']('footnoteRef',{'footnoteId':_0xe18f97});}}),_0x408fc4['for']('dataDowncast')['elementToElement']({'model':{'name':'footnoteRef','attributes':['footnoteId','footnoteCounter']},'view':(_0x4fda52,{writer:_0x30f5f6})=>D(_0x4fda52,_0x30f5f6)}),_0x408fc4['for']('editingDowncast')['elementToElement']({'model':{'name':'footnoteRef','attributes':['footnoteId','footnoteCounter']},'view':(_0x201781,{writer:_0x5cde31})=>{const _0x34535b=_0x201781['getAttribute']('footnoteCounter');return _0x10baaf(D(_0x201781,_0x5cde31),_0x5cde31,{'label':t('Footnote\x20%0.\x20Press\x20ENTER\x20to\x20jump\x20to\x20footnote\x20definition.',_0x34535b)});}});}['_defineDefinitionsConverters'](){const {editor:_0x5be382}=this,{t:t}=_0x5be382['locale'],{conversion:_0x5a22bd}=_0x5be382;_0x5a22bd['for']('upcast')['elementToElement']({'view':{'name':'div','classes':'footnotes'},'model':'footnotesDefinitions'}),_0x5a22bd['for']('upcast')['add'](_0x49a13c=>{_0x49a13c['on']('element:ol',(_0x2338cf,_0xc5be67,_0xcdeefe)=>{const _0xcfaa4d=_0xc5be67['viewItem'];if(!_0xcfaa4d['hasClass']('footnotes-list')||!_0xc5be67['modelCursor']['parent']?.['is']('element','footnotesDefinitions'))return;if(!_0xcdeefe['consumable']['consume'](_0xcfaa4d,{'name':!0x0,'classes':'footnotes-list'}))return;const {modelRange:_0x23080f,modelCursor:_0x4836af}=_0xcdeefe['convertChildren'](_0xc5be67['viewItem'],_0xc5be67['modelCursor']);_0xc5be67['modelRange']=_0x23080f,_0xc5be67['modelCursor']=_0x4836af;}),_0x49a13c['on']('element:hr',(_0x34efad,_0x599531,_0x18cdab)=>{const _0x4f4185=_0x599531['viewItem'];_0x4f4185['hasClass']('footnotes-divider')&&_0x599531['modelCursor']['parent']?.['is']('element','footnotesDefinitions')&&_0x18cdab['consumable']['consume'](_0x4f4185,{'name':!0x0,'classes':'footnotes-divider'});});}),_0x5a22bd['for']('dataDowncast')['elementToStructure']({'model':'footnotesDefinitions','view':(_0x48eb1d,{writer:_0x1d37e0})=>g(_0x1d37e0)}),_0x5a22bd['for']('editingDowncast')['elementToStructure']({'model':'footnotesDefinitions','view':(_0x564318,{writer:_0x3a9aae})=>{const _0x15b4e6=g(_0x3a9aae,{'data-footnotes-list-label':t('Footnotes')}),_0x507373=_0x10baaf(_0x15b4e6,_0x3a9aae,{'hasSelectionHandle':!0x0,'label':t('Footnotes')});return _0x3a9aae['setCustomProperty']('footnotesDefinitions',!0x0,_0x507373),_0x507373;}});}['_defineDefinitionConverters'](){const {editor:_0x151c33}=this,{conversion:_0x4a1c23,locale:_0xbd485b}=_0x151c33,_0x2be8f9=_0x151c33['config']['get']('footnotes.multiBlock');_0x4a1c23['for']('upcast')['add'](_0x4d2bae=>{_0x4d2bae['on']('element:li',(_0xc30899,_0x4d1cbe,_0x1a51d8)=>{const _0x539ada=_0x4d1cbe['viewItem'];if(!_0x539ada['hasClass']('footnote-definition')||!_0x539ada['getAttribute']('id'))return;const _0x42d9c2=_0x539ada['parent'];if(!_0x42d9c2['is']('element','ol')||!_0x42d9c2['hasClass']('footnotes-list'))return;if(!_0x1a51d8['consumable']['test'](_0x539ada,{'name':!0x0,'attributes':'id','classes':'footnote-definition'}))return;const _0x20f9eb=_0x1a51d8['writer']['createElement']('footnoteDefinition',{'footnoteId':_0x539ada['getAttribute']('id')});if(!_0x1a51d8['safeInsert'](_0x20f9eb,_0x4d1cbe['modelCursor']))return;_0x1a51d8['consumable']['consume'](_0x539ada,{'name':!0x0,'attributes':'id','classes':'footnote-definition'});const _0x3839d7=Array['from'](_0x539ada['getChildren']())['find'](_0x26d167=>_0x26d167['is']('element')&&_0x26d167['hasClass']('footnote-content'));for(const _0xaa22ea of _0x539ada['getChildren']())_0xaa22ea['is']('element')&&(_0x1a51d8['consumable']['consume'](_0xaa22ea,{'name':!0x0,'classes':'footnote-backlink','attributes':'href'}),_0x1a51d8['consumable']['consume'](_0xaa22ea,{'name':!0x0,'classes':'footnote-content'}));if(_0x3839d7){if(_0x2be8f9)_0x1a51d8['convertChildren'](_0x3839d7,_0x20f9eb);else{const _0x52b21f=_0x1a51d8['writer']['createElement']('footnoteInlineContent');_0x1a51d8['writer']['insert'](_0x52b21f,_0x20f9eb),_0x1a51d8['convertChildren'](_0x3839d7,_0x52b21f);}}_0x1a51d8['updateConversionResult'](_0x20f9eb,_0x4d1cbe);});}),_0x4a1c23['for']('dataDowncast')['elementToStructure']({'model':{'name':'footnoteDefinition','attributes':['footnoteId']},'view':(_0x50323f,{writer:_0x3e93f7})=>v(_0x50323f,_0x3e93f7,_0xbd485b,{'dataPipeline':!0x0})}),_0x4a1c23['for']('editingDowncast')['elementToStructure']({'model':{'name':'footnoteDefinition','attributes':['footnoteId']},'view':(_0x5be47d,{writer:_0x324038})=>v(_0x5be47d,_0x324038,_0xbd485b)});}['_defineBogusParagraphConverters'](){const {editor:_0x31f3e4}=this,{conversion:_0x1aa4a}=_0x31f3e4;_0x31f3e4['config']['get']('footnotes.multiBlock')?(_0x1aa4a['for']('editingDowncast')['elementToElement']({'model':'paragraph','view':m(),'converterPriority':'high'}),_0x1aa4a['for']('dataDowncast')['elementToElement']({'model':'paragraph','view':m({'dataPipeline':!0x0}),'converterPriority':'high'}),this['listenTo'](_0x31f3e4['model']['document'],'change:data',()=>{!function(_0x2ff6ff,_0x26c68b){const _0x4ad18a=_0x2ff6ff['document']['differ'],_0x121e6b=new Set();for(const _0x1c6fc7 of _0x4ad18a['getChanges']()){const _0x1ed2da='attribute'==_0x1c6fc7['type']?_0x1c6fc7['range']['start']['parent']:_0x1c6fc7['position']['parent'];_0x1ed2da['is']('element','footnoteDefinition')&&_0x121e6b['add'](_0x1ed2da);}for(const _0x422d0b of _0x121e6b['values']()){const _0x47886d=Array['from'](_0x422d0b['getChildren']())['filter'](_0x20ce8e=>p(_0x20ce8e,_0x26c68b['mapper']));for(const _0x238b9f of _0x47886d)_0x26c68b['reconvertItem'](_0x238b9f);}}(_0x31f3e4['model'],_0x31f3e4['editing']);})):(_0x1aa4a['for']('editingDowncast')['elementToElement']({'model':'footnoteInlineContent','view':m()}),_0x1aa4a['for']('dataDowncast')['elementToElement']({'model':'footnoteInlineContent','view':(_0x1d7e5f,{writer:_0x573809})=>{const _0x4942ce=_0x573809['createContainerElement']('span');return _0x573809['setCustomProperty']('dataPipeline:transparentRendering',!0x0,_0x4942ce),_0x4942ce;}}));}['_defineKeyboardHandlers'](){const {editor:_0xfad60}=this,{editing:_0x12f94f,t:t}=_0xfad60,_0x175376=_0xfad60['model']['document']['selection'];_0xfad60['keystrokes']['set']('CTRL+Shift+D','insertFootnote'),_0xfad60['accessibility']['addKeystrokeInfos']({'keystrokes':[{'label':t('Insert\x20footnote'),'keystroke':'Ctrl+Shift+D'}]}),this['listenTo'](_0x12f94f['view']['document'],'enter',(_0x2d47b3,_0x2a6c9a)=>{const _0x47bd9a=function(_0x3539e4){const _0x1f8286=_0x3539e4['getSelectedElement']();if(_0x1f8286?.['is']('element','footnoteRef'))return _0x1f8286;return null;}(_0x175376);if(_0x47bd9a){const _0x2165f3=_0x47bd9a['getAttribute']('footnoteId');this['_moveSelectionToFootnoteDefinition'](_0x2165f3),_0x2a6c9a['preventDefault'](),_0x2d47b3['stop']();}},{'context':_0x46acc9});}['_defineClickHandlers'](){const {editor:_0x1ab5d3}=this,{editing:_0x4de2c0}=_0x1ab5d3;_0x1ab5d3['editing']['view']['addObserver'](_0x3c43fc),_0x1ab5d3['editing']['view']['addObserver'](_0x4144eb);let _0x3b3cec=!0x1;this['listenTo'](_0x4de2c0['view']['document'],'pointerdown',(_0x4c8167,_0x7d2ad4)=>{const {target:_0x18ba44}=_0x7d2ad4,_0x570b5d=_0x4de2c0['view']['document']['selection'];_0x3b3cec=!!(_0x18ba44['is']('element','a')&&_0x18ba44['parent']?.['is']('element','sup')&&_0x18ba44['parent']['hasClass']('footnote'))&&_0x570b5d['getSelectedElement']()===_0x18ba44['parent'];},{'priority':'high'}),this['listenTo'](_0x4de2c0['view']['document'],'click',(_0x26b928,_0x5c7edf)=>{const {target:_0x160c8c}=_0x5c7edf;if(!_0x160c8c['is']('element','a'))return;if(_0x160c8c['parent']?.['is']('element','sup')&&_0x160c8c['parent']['hasClass']('footnote')&&!_0x3b3cec)return void _0x5c7edf['preventDefault']();let _0x48455f=_0x160c8c['getAttribute']('href');if(!_0x48455f?.['startsWith']('#'))return;_0x48455f=_0x48455f['slice'](0x1);let _0x370857=!0x1;(_0x48455f['startsWith']('ref-')&&this['_moveSelectionToFootnoteReference'](_0x48455f['slice'](0x4))||this['_moveSelectionToFootnoteDefinition'](_0x48455f))&&(_0x370857=!0x0),_0x370857&&(_0x5c7edf['preventDefault'](),_0x26b928['stop']());},{'priority':'high','context':'$capture'});}}function m({dataPipeline:_0x7f7d30}={}){return(_0x9b6048,{writer:_0x30679e})=>{if(!h(_0x9b6048))return null;if(!_0x7f7d30)return _0x30679e['createContainerElement']('span',{'class':'ck-footnote-bogus-paragraph'});const _0x3a0e93=_0x30679e['createContainerElement']('p');return _0x30679e['setCustomProperty']('dataPipeline:transparentRendering',!0x0,_0x3a0e93),_0x3a0e93;};}function h(_0x28b83a){const {parent:_0x48742b}=_0x28b83a;if(!_0x48742b?.['is']('element','footnoteDefinition'))return!0x1;if(0x1!=_0x48742b['childCount'])return!0x1;for(const _0x459049 of _0x28b83a['getAttributeKeys']())if(!_0x459049['startsWith']('selection:')&&'htmlEmptyBlock'!=_0x459049)return!0x1;return!0x0;}function p(_0x2ae508,_0x2da218){if(!_0x2ae508['is']('element','paragraph'))return!0x1;const _0x4bfb86=_0x2da218['toViewElement'](_0x2ae508);return!!_0x4bfb86&&h(_0x2ae508)!==_0x4bfb86['is']('element','span');}function J(_0x42aa55){return _0x46acc9(_0x42aa55)&&_0x42aa55['is']('containerElement')&&!!_0x42aa55['getCustomProperty']('footnotesDefinitions');}function g(_0x41444e,_0x252947={}){const _0x22dec9=_0x41444e['createEmptyElement']('hr',{'class':'footnotes-divider'}),_0x3d619f=_0x41444e['createContainerElement']('ol',{'class':'footnotes-list'},_0x41444e['createSlot']());return _0x41444e['createContainerElement']('div',{'class':'footnotes',..._0x252947},[_0x22dec9,_0x3d619f]);}function D(_0x1dd3b6,_0x179f4b){const _0x24ebab=_0x1dd3b6['getAttribute']('footnoteId'),_0x29b014=_0x1dd3b6['getAttribute']('footnoteCounter'),_0x3de973=_0x179f4b['createUIElement']('a',{'href':'#'+_0x24ebab},function(_0x489100){const _0x283c2a=this['toDomElement'](_0x489100);return _0x283c2a['textContent']=_0x29b014,_0x283c2a;}),_0xf579a5=_0x179f4b['createContainerElement']('sup',{'id':'ref-'+_0x24ebab,'class':'footnote'},[_0x3de973]);return _0xf579a5['getFillerOffset']=()=>null,_0xf579a5;}function v(_0x36d852,_0x587db1,_0xb23297,{dataPipeline:_0x25d629}={}){const {t:t}=_0xb23297,_0x4a98c8=_0x36d852['getAttribute']('footnoteId'),_0x2b57e8=_0x587db1['createUIElement']('a',{'class':'footnote-backlink','href':'#ref-'+_0x4a98c8},function(_0x3a7a09){const _0x57485d=this['toDomElement'](_0x3a7a09);return _0x57485d['innerText']='^',_0x57485d;}),_0x13320d=_0x25d629?_0x587db1['createContainerElement']('div',{'class':'footnote-content'}):_0xe86660(_0x587db1['createEditableElement']('div',{'class':'footnote-content'}),_0x587db1,{'label':t('Footnote\x20content.')});return _0x587db1['insert'](_0x587db1['createPositionAt'](_0x13320d,0x0),_0x587db1['createSlot']()),_0x587db1['createContainerElement']('li',{'class':'footnote-definition','id':_0x4a98c8},[_0x2b57e8,_0x13320d]);}class e extends _0x581f59{static get['pluginName'](){return'FootnotesClipboard';}static get['requires'](){return[r,_0x139329];}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['init'](){this['_defineClipboardIntegration']();}['_defineClipboardIntegration'](){this['_handleCopyFootnotesDefinitions'](),this['_handlePasteFootnotesDefinitions']();}['_handleCopyFootnotesDefinitions'](){const {editor:_0x2ffdec}=this,{plugins:_0x38b767,model:_0x6a56f1}=_0x2ffdec,_0x4281ac=_0x38b767['get'](_0x139329),_0x3d9f52=_0x38b767['get'](c);this['listenTo'](_0x4281ac,'outputTransformation',(_0x23191d,_0x534696)=>{const _0x7009c7=function(_0x18ae9e,_0x2392ef){const _0x5db43a=new Set();for(const {item:_0x5e63bd}of _0x18ae9e['createRangeIn'](_0x2392ef))_0x5e63bd['is']('element','footnoteRef')&&_0x5db43a['add'](_0x5e63bd['getAttribute']('footnoteId'));return Array['from'](_0x5db43a);}(_0x6a56f1,_0x534696['content']);if(!_0x7009c7['length'])return;const _0x4e6149=_0x3d9f52['getFootnotes'](),_0x1b31e6=_0x7009c7['reduce']((_0x15afd2,_0x5828a5)=>{const _0x5265d1=_0x4e6149['find'](_0x722a46=>_0x722a46['id']===_0x5828a5);if(_0x5265d1){const _0x12bbe7=_0x2ffdec['data']['toView'](_0x5265d1['definition'],{'isClipboardPipeline':!0x0}),_0x4d7c2f=_0x2ffdec['data']['htmlProcessor']['toData'](_0x12bbe7);_0x15afd2[_0x5265d1['id']]=_0x4d7c2f;}return _0x15afd2;},Object['create'](null));_0x534696['dataTransfer']['setData']('application/ckeditor5-footnotes',JSON['stringify'](_0x1b31e6));});}['_handlePasteFootnotesDefinitions'](){const {editor:_0x9de04f}=this,{model:_0x56b676,plugins:_0x5924ac}=_0x9de04f,{view:_0xe78245}=_0x9de04f['editing'],_0x4b44e8=_0x5924ac['get'](_0x139329),_0x622a69=_0x5924ac['get'](c);let _0x563e5f=null;this['listenTo'](_0xe78245['document'],'clipboardInput',(_0x2cb548,_0x216df9)=>{const _0x2cad8b=_0x216df9['dataTransfer']['getData']('application/ckeditor5-footnotes');_0x563e5f=_0x2cad8b?JSON['parse'](_0x2cad8b):null;}),this['listenTo'](_0x4b44e8,'contentInsertion',(_0x268a82,_0x168930)=>{if(!_0x563e5f)return;const _0x4d5f0d=_0x168930['sourceEditorId']===this['editor']['id'];_0x4d5f0d&&'drop'===_0x168930['method']||_0x56b676['change'](_0x2c3ecb=>{!function(_0x5512db,_0x3f18c6){const _0x5c0ceb=[];for(const {item:_0x3cacc4}of _0x5512db['createRangeIn'](_0x3f18c6))_0x3cacc4['is']('element','footnotesDefinitions')&&_0x5c0ceb['push'](_0x3cacc4);for(const _0x1ce744 of _0x5c0ceb)_0x5512db['remove'](_0x1ce744);}(_0x2c3ecb,_0x168930['content']);let _0x19e027=_0x622a69['getFootnotesDefinitionsObjectElement']();if(!_0x19e027){const _0x374246=_0x56b676['document']['selection']['getFirstRange']()['root'];_0x19e027=_0x622a69['_insertEmptyFootnotesDefinitionsContainer'](_0x2c3ecb,_0x374246);}const _0x22a19b=function(_0x2799bb,_0x34aa78,_0x4dd2e1){const _0x1c38a6=Object['create'](null);for(const {item:_0x7505b2}of _0x2799bb['createRangeIn'](_0x34aa78))if(_0x7505b2['is']('element','footnoteRef')){const _0x58a8cd=_0x7505b2['getAttribute']('footnoteId');if(!_0x4dd2e1(_0x58a8cd))continue;_0x1c38a6[_0x58a8cd]||(_0x1c38a6[_0x58a8cd]=_0x3b0ffc()),_0x2799bb['setAttribute']('footnoteId',_0x1c38a6[_0x58a8cd],_0x7505b2);}return _0x1c38a6;}(_0x2c3ecb,_0x168930['content'],_0x2b1516=>!_0x4d5f0d||null!==_0x622a69['getFootnote'](_0x2b1516));for(const [_0x574bba,_0x5e01dc]of Object['entries'](_0x563e5f)){const _0x51eeff=_0x22a19b[_0x574bba]||_0x574bba,_0x6d8bcd=_0x2c3ecb['createElement']('footnoteDefinition',{'footnoteId':_0x51eeff}),_0x58b816=_0x9de04f['data']['htmlProcessor']['toView'](_0x5e01dc),_0x10db20=_0x9de04f['data']['toModel'](_0x58b816,_0x6d8bcd);_0x2c3ecb['append'](_0x10db20,_0x6d8bcd),_0x2c3ecb['insert'](_0x6d8bcd,_0x19e027,'end');}_0x563e5f=null;});});}}class i extends _0x581f59{['licenseKey'];['_licenseKeyCheckInterval'];static get['pluginName'](){return'FootnotesUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['init'](){const {editor:_0x42b6bf}=this,{componentFactory:_0x5eed92}=_0x42b6bf['ui'];_0x5eed92['add']('insertFootnote',x(_0x42b6bf,_0x11dc3b)),_0x5eed92['add']('menuBar:insertFootnote',x(_0x42b6bf,_0x53bd40)),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x5cac20=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x484d24;for(const _0x1a4ea3 in _0x5cac20){const _0x3f7b2d=_0x1a4ea3,_0x50b704=_0x5cac20[_0x3f7b2d];if('footnotesLicenseKeyValid'==_0x50b704||'footnotesLicenseKeyInvalid'==_0x50b704||'footnotesLicenseKeyExpired'==_0x50b704||'footnotesLicenseKeyDomainLimit'==_0x50b704||'footnotesLicenseKeyNotAllowed'==_0x50b704||'footnotesLicenseKeyEvaluationLimit'==_0x50b704||'footnotesLicenseKeyTrialLimit'==_0x50b704||'footnotesLicenseKeyUsageLimit'==_0x50b704){delete _0x5cac20[_0x3f7b2d],_0x484d24=_0x50b704,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'footnotesLicenseKeyInvalid'==_0x484d24&&_0x5cac20['_showLicenseError']('invalid'),'footnotesLicenseKeyExpired'==_0x484d24&&_0x5cac20['_showLicenseError']('expired'),'footnotesLicenseKeyDomainLimit'==_0x484d24&&_0x5cac20['_showLicenseError']('domainLimit'),'footnotesLicenseKeyNotAllowed'==_0x484d24&&_0x5cac20['_showLicenseError']('featureNotAllowed','Footnotes'),'footnotesLicenseKeyEvaluationLimit'==_0x484d24&&_0x5cac20['_showLicenseError']('evaluationLimit'),'footnotesLicenseKeyTrialLimit'==_0x484d24&&_0x5cac20['_showLicenseError']('trialLimit'),'footnotesLicenseKeyUsageLimit'==_0x484d24&&_0x5cac20['_showLicenseError']('usageLimit');},0x3e8);}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}}function x(_0x1ea2e4,_0x45b13d){const _0x5524c2=_0x1ea2e4['commands']['get']('insertFootnote');return _0x3bf0e2=>{const {t:t}=_0x3bf0e2,_0x2b5700=new _0x45b13d(_0x3bf0e2),_0x31c6fd=_0x2b5700 instanceof _0x53bd40;return _0x2b5700['bind']('isEnabled')['to'](_0x5524c2,'isEnabled'),_0x2b5700['set']({'label':t(_0x31c6fd?'Footnote':'Insert\x20footnote'),'icon':_0x18c523,'tooltip':!0x0}),_0x2b5700['on']('execute',()=>{_0x5524c2['execute'](),_0x1ea2e4['editing']['view']['focus']();}),_0x2b5700;};}class nt extends _0x581f59{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 _0x1a23cd{['refresh'](){const {editor:_0x36866e}=this,_0x380345=_0x36866e['plugins']['get'](c)['getFootnotesDefinitionsObjectElement']();this['isEnabled']=!!_0x380345,this['value']=_0x380345?.['getAttribute']('footnotesListStyle')??null;}['execute']({value:_0x52e5d7}){const {editor:_0x5d6016}=this,_0x365730=_0x5d6016['plugins']['get'](c),_0x3acac0=_0x365730['getFootnotesDefinitionsObjectElement']();_0x3acac0&&Q['includes'](_0x52e5d7)&&_0x5d6016['model']['change'](_0x853594=>{_0x853594['setAttribute']('footnotesListStyle',_0x52e5d7,_0x3acac0),_0x365730['_updateFootnotesCounters'](_0x853594);});}}class b extends _0x1a23cd{['refresh'](){const {editor:_0x32d58b}=this,_0x2c2bb0=_0x32d58b['plugins']['get'](c)['getFootnotesDefinitionsObjectElement']();this['isEnabled']=!!_0x2c2bb0,this['value']=_0x2c2bb0?.['getAttribute']('footnotesListStart')??null;}['execute']({value:_0x22e052}){const {editor:_0x3c4734}=this,_0x198ab5=_0x3c4734['plugins']['get'](c),_0x306f6c=_0x198ab5['getFootnotesDefinitionsObjectElement']();_0x306f6c&&Number['isInteger'](_0x22e052)&&_0x3c4734['model']['change'](_0x2d3819=>{_0x2d3819['setAttribute']('footnotesListStart',_0x22e052,_0x306f6c),_0x198ab5['_updateFootnotesCounters'](_0x2d3819);});}}class P extends _0x581f59{static get['pluginName'](){return'FootnotesPropertiesEditing';}static get['requires'](){return[r,c];}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['init'](){const {editor:_0x39d876}=this;_0x39d876['config']['define']('footnotes.footnotesProperties.defaultListStyle','decimal'),_0x39d876['config']['define']('footnotes.footnotesProperties.defaultStartIndex',0x1),_0x39d876['commands']['add']('footnotesStyle',new S(_0x39d876)),_0x39d876['commands']['add']('footnotesStart',new b(_0x39d876)),this['_defineSchema'](),this['_defineConverters'](),this['_defineFormatter'](),this['_definePostfixer']();}['_defineSchema'](){const {editor:_0x1c4525}=this,{schema:_0x43908e}=_0x1c4525['model'];_0x43908e['extend']('footnotesDefinitions',{'allowAttributes':['footnotesListStyle','footnotesListStart']});}['_defineConverters'](){const {editor:_0x4c304f}=this,{conversion:_0x24991f,model:_0xdad85a}=_0x4c304f,{schema:_0x32630b}=_0xdad85a;_0x24991f['for']('upcast')['add'](_0x317d6f=>{_0x317d6f['on']('element:ol',(_0x1af7c9,_0x42d10d,_0x3747ac)=>{const _0x33b0d5=_0x42d10d['viewItem'],_0x2e4900=_0x42d10d['modelCursor']?.['parent'];_0x33b0d5['hasClass']('footnotes-list')&&_0x2e4900?.['is']('element','footnotesDefinitions')&&(function(_0x5f5d0d,_0x4cb605,_0x4e2de1,_0x2a2ab5){if(!_0x2a2ab5['checkAttribute'](_0x4cb605,'footnotesListStart'))return;let _0x55651a=0x1;const _0x53044f=_0x4e2de1['consumable']['consume'](_0x5f5d0d,{'attributes':'start'});if(_0x53044f){const _0x49c143=Number['parseInt'](_0x5f5d0d['getAttribute']('start'),0xa);Number['isNaN'](_0x49c143)||(_0x55651a=_0x49c143);}!_0x53044f&&_0x4cb605['hasAttribute']('footnotesListStart')||_0x4e2de1['writer']['setAttribute']('footnotesListStart',_0x55651a,_0x4cb605);}(_0x33b0d5,_0x2e4900,_0x3747ac,_0x32630b),function(_0x18f3f3,_0x2af9e4,_0x44ee38,_0x5a6ba7){if(!_0x5a6ba7['checkAttribute'](_0x2af9e4,'footnotesListStyle'))return;let _0x49f2e2='decimal',_0x3a9917=!0x1;if(_0x44ee38['consumable']['consume'](_0x18f3f3,{'attributes':'type'})){const _0x78c65d={0x1:'decimal','a':'lower-alpha','A':'upper-alpha','i':'lower-roman','I':'upper-roman'}[_0x18f3f3['getAttribute']('type')];_0x78c65d&&(_0x49f2e2=_0x78c65d),_0x3a9917=!0x0;}_0x44ee38['consumable']['consume'](_0x18f3f3,{'styles':'list-style-type'})&&(_0x49f2e2=_0x18f3f3['getStyle']('list-style-type'),_0x3a9917=!0x0),!_0x3a9917&&_0x2af9e4['hasAttribute']('footnotesListStyle')||_0x44ee38['writer']['setAttribute']('footnotesListStyle',_0x49f2e2,_0x2af9e4);}(_0x33b0d5,_0x2e4900,_0x3747ac,_0x32630b));});}),_0x24991f['for']('downcast')['add'](_0x19b61b=>{_0x19b61b['on']('attribute:footnotesListStart:footnotesDefinitions',(_0x8d61b0,_0x2ff83f,_0x1fb387)=>{if(!_0x1fb387['consumable']['consume'](_0x2ff83f['item'],_0x8d61b0['name']))return;const _0x261b52=C(_0x2ff83f['item'],_0x1fb387['mapper']),{attributeNewValue:_0x235a16}=_0x2ff83f;null==_0x235a16||0x1===_0x235a16?_0x1fb387['writer']['removeAttribute']('start',_0x261b52):_0x1fb387['writer']['setAttribute']('start',String(_0x235a16),_0x261b52);}),_0x19b61b['on']('attribute:footnotesListStyle:footnotesDefinitions',(_0x5db3a8,_0x548bd7,_0x405b49)=>{if(!_0x405b49['consumable']['consume'](_0x548bd7['item'],_0x5db3a8['name']))return;const _0x2ca7c5=C(_0x548bd7['item'],_0x405b49['mapper']),{attributeNewValue:_0x3def8c}=_0x548bd7;_0x3def8c&&'decimal'!==_0x3def8c?_0x405b49['writer']['setStyle']('list-style-type',_0x3def8c,_0x2ca7c5):_0x405b49['writer']['removeStyle']('list-style-type',_0x2ca7c5);});});}['_definePostfixer'](){const {editor:_0x2eaea4}=this,{model:_0x314df6}=_0x2eaea4,_0x209a0e=_0x2eaea4['plugins']['get'](c),_0x1f18a3=this['_getDefaultListStyle'](),_0xf787ab=this['_getDefaultStartIndex']();_0x314df6['document']['registerPostFixer'](_0x5ec5aa=>{const _0x51b1c3=_0x314df6['document']['differ']['getChanges']();let _0x2f9ce0=!0x1;for(const _0xc16a23 of _0x51b1c3){if('insert'!==_0xc16a23['type']||'$text'===_0xc16a23['name'])continue;const _0x117dc7=_0x314df6['createRangeOn'](_0xc16a23['position']['nodeAfter']);for(const _0x2b1419 of _0x117dc7['getItems']())_0x2b1419['is']('element','footnotesDefinitions')&&(!_0x2b1419['hasAttribute']('footnotesListStart')&&_0x314df6['schema']['checkAttribute'](_0x2b1419,'footnotesListStart')&&(_0x5ec5aa['setAttribute']('footnotesListStart',_0xf787ab,_0x2b1419),_0x2f9ce0=!0x0),!_0x2b1419['hasAttribute']('footnotesListStyle')&&_0x314df6['schema']['checkAttribute'](_0x2b1419,'footnotesListStyle')&&(_0x5ec5aa['setAttribute']('footnotesListStyle',_0x1f18a3,_0x2b1419),_0x2f9ce0=!0x0));}return _0x2f9ce0&&_0x209a0e['_updateFootnotesCounters'](_0x5ec5aa),_0x2f9ce0;});}['_defineFormatter'](){const {editor:_0x2c6699}=this;_0x2c6699['plugins']['get'](c)['setFootnoteFormatter'](_0x2c9389=>this['_formatFootnoteListValue'](_0x2c9389));}['_getDefaultListStyle'](){return this['editor']['config']['get']('footnotes.footnotesProperties.defaultListStyle');}['_getDefaultStartIndex'](){return this['editor']['config']['get']('footnotes.footnotesProperties.defaultStartIndex');}['_formatFootnoteListValue']({container:_0x3417f2,value:_0x2b5d15,digits:_0x49eea0}){const _0x4b91e9=_0x3417f2['getAttribute']('footnotesListStyle'),_0x427ff5=_0x3417f2['getAttribute']('footnotesListStart'),_0xa74a2f=Math['floor'](_0x2b5d15)+(_0x427ff5??0x1)-0x1;switch(_0x4b91e9){case'decimal-leading-zero':return function(_0x17c8a9,_0x30c720){return String(_0x17c8a9)['padStart'](_0x30c720,'0');}(_0xa74a2f,Math['max'](0x2,_0x49eea0));case'lower-alpha':case'lower-latin':return M(_0xa74a2f,!0x1);case'upper-alpha':case'upper-latin':return M(_0xa74a2f,!0x0);case'lower-roman':return V(_0xa74a2f,!0x1);case'upper-roman':return V(_0xa74a2f,!0x0);default:return String(_0xa74a2f);}}}function C(_0x4a5147,_0x2a9f3c){const _0x3ee9ac=_0x2a9f3c['toViewElement'](_0x4a5147);return Array['from'](_0x3ee9ac['getChildren']())['find'](_0x1ac217=>_0x1ac217['is']('element','ol')&&_0x1ac217['hasClass']('footnotes-list'));}function M(_0x2a734f,_0x569393){let _0x7ef04e='',_0x2bada1=_0x2a734f;for(;_0x2bada1>0x0;){const _0x595fb0=(_0x2bada1-0x1)%0x1a;_0x7ef04e=String['fromCharCode'](0x61+_0x595fb0)+_0x7ef04e,_0x2bada1=Math['floor']((_0x2bada1-0x1)/0x1a);}return _0x569393?_0x7ef04e['toUpperCase']():_0x7ef04e;}const N=[{'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 V(_0x288de8,_0x49c235){let _0x3685a7='',_0x40f686=_0x288de8;for(const {value:_0x56d76c,numeral:_0x2c5287}of N)for(;_0x40f686>=_0x56d76c;)_0x3685a7+=_0x2c5287,_0x40f686-=_0x56d76c;return _0x49c235?_0x3685a7:_0x3685a7['toLowerCase']();}class H extends _0x1cdf56{['children'];['stylesView']=null;['additionalProperties']=null;['startIndexFieldView']=null;['focusTracker']=new et();['keystrokes']=new ot();['focusables']=new _0x312a0c();['focusCycler'];constructor(_0x5ecd8b,{styleButtonViews:_0x527cc4,styleGridAriaLabel:_0x4a9c3b}){super(_0x5ecd8b),(this['focusCycler']=new _0x59bf31({'focusables':this['focusables'],'focusTracker':this['focusTracker'],'keystrokeHandler':this['keystrokes'],'actions':{'focusPrevious':'shift\x20+\x20tab','focusNext':'tab'}}),this['children']=this['createCollection'](),this['stylesView']=this['_appendStylesView'](_0x527cc4,_0x4a9c3b),[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 _0x3199c9 of this['stylesView']['children'])this['stylesView']['focusTracker']['add'](_0x3199c9['element']);_0xcf4ad2({'keystrokeHandler':this['stylesView']['keystrokes'],'focusTracker':this['stylesView']['focusTracker'],'gridItems':this['stylesView']['children'],'numberOfColumns':()=>rt['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 _0x27d882=_0x366ffa=>_0x366ffa['stopPropagation']();this['keystrokes']['set']('arrowright',_0x27d882),this['keystrokes']['set']('arrowleft',_0x27d882),this['keystrokes']['set']('arrowup',_0x27d882),this['keystrokes']['set']('arrowdown',_0x27d882);}this['keystrokes']['listenTo'](this['element']);}['focus'](){this['focusCycler']['focusFirst']();}['focusLast'](){this['focusCycler']['focusLast']();}['destroy'](){super['destroy'](),this['focusTracker']['destroy'](),this['keystrokes']['destroy']();}['_appendStylesView'](_0x5dec99,_0x28d4d6){const _0x444083=new _0x1cdf56(this['locale']);return _0x444083['children']=_0x444083['createCollection'](),_0x444083['children']['addMany'](_0x5dec99),_0x444083['setTemplate']({'tag':'div','attributes':{'aria-label':_0x28d4d6,'class':['ck','ck-footnotes-definitions-styles-list']},'children':_0x444083['children']}),_0x444083['children']['delegate']('execute')['to'](this),_0x444083['focus']=function(){for(const _0x482cfb of this['children'])if(_0x482cfb instanceof _0x11dc3b&&_0x482cfb['isOn'])return void _0x482cfb['focus']();this['children']['first']['focus']();},_0x444083['focusTracker']=new et(),_0x444083['keystrokes']=new ot(),_0x444083['render'](),_0x444083['keystrokes']['listenTo'](_0x444083['element']),this['children']['add'](_0x444083),_0x444083;}['_appendAdditionalPropertiesCollapsibleView'](){const {t:t}=this['locale'],_0x55ccaf=this['_createStartIndexPropertyView'](),_0x1cbe6a=[_0x55ccaf],_0x233877=new tt(this['locale'],_0x1cbe6a);return _0x233877['set']({'label':t('Footnotes\x20properties'),'isCollapsed':!0x0}),_0x233877['buttonView']['bind']('isEnabled')['toMany'](_0x1cbe6a,'isEnabled',(..._0xd2dd79)=>_0xd2dd79['some'](_0x272539=>_0x272539)),_0x233877['buttonView']['on']('change:isEnabled',(_0x5d1669,_0x254360,_0x4ac4bd)=>{_0x4ac4bd||(_0x233877['isCollapsed']=!0x0);}),this['children']['add'](_0x233877),[_0x55ccaf,_0x233877];}['_createStartIndexPropertyView'](){const {t:t}=this['locale'],_0x4d4067=new st(this['locale'],it);return _0x4d4067['set']({'label':t('Footnotes\x20start\x20at'),'class':'ck-footnotes-definitions-properties__start-index'}),_0x4d4067['fieldView']['set']({'min':0x0,'max':Math['pow'](0x2,0x1e),'step':0x1,'value':0x1,'inputMode':'numeric'}),_0x4d4067['fieldView']['on']('input',()=>{const _0x3ffe4e=_0x4d4067['fieldView']['element'],_0x3365ab=_0x3ffe4e['valueAsNumber'];Number['isNaN'](_0x3365ab)?_0x4d4067['errorText']=t('Invalid\x20footnotes\x20start\x20index\x20value.'):_0x3ffe4e['checkValidity']()?this['fire']('footnotesListStart',{'startIndex':_0x3365ab}):_0x4d4067['errorText']=t(_0x3365ab<0x0?'Footnotes\x20start\x20index\x20must\x20be\x20greater\x20than\x200.':'Footnotes\x20start\x20index\x20is\x20too\x20large.');}),_0x4d4067;}}class j extends _0x581f59{static get['pluginName'](){return'FootnotesPropertiesUI';}static get['requires'](){return[_0x310f8a,_0x16f6bf];}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['init'](){const {editor:_0x52920a}=this,{componentFactory:_0x337e14}=_0x52920a['ui'];_0x52920a['config']['define']('footnotes.footnotesProperties.toolbar',['footnotesStyle']),_0x337e14['add']('footnotesStyle',function(_0x4d9dd0){return _0x468189=>{const {t:t}=_0x468189,_0x2500f0=_0x4d9dd0['commands']['get']('footnotesStyle'),_0x31e704=_0x3d8114(_0x468189),{buttonView:_0x5b7acd}=_0x31e704;return _0x31e704['class']='ck-footnotes-styles-dropdown',_0x31e704['bind']('isEnabled')['to'](_0x2500f0,'isEnabled'),_0x5b7acd['set']({'label':t('Footnotes\x20style'),'icon':_0x18c523,'tooltip':!0x0}),_0x31e704['once']('change:isOpen',()=>{const _0x22318b=function({editor:_0x7f4192,dropdownView:_0x1f993a}){const {t:t}=_0x7f4192['locale'],_0x23825b=t('Footnotes\x20definitions\x20styles'),_0x1ea336=function(_0x12162a){const t=_0x12162a['locale']['t'],_0x1c0189=[{'label':t('Toggle\x20the\x20decimal\x20footnotes\x20style'),'tooltip':t('Decimal\x20footnotes'),'style':'decimal','icon':_0x237bc8},{'label':t('Toggle\x20the\x20decimal\x20with\x20leading\x20zero\x20footnotes\x20style'),'tooltip':t('Decimal\x20footnotes\x20with\x20leading\x20zero'),'style':'decimal-leading-zero','icon':_0x50f5af},{'label':t('Toggle\x20the\x20lower–roman\x20footnotes\x20style'),'tooltip':t('Lower–roman\x20footnotes'),'style':'lower-roman','icon':_0x23bace},{'label':t('Toggle\x20the\x20upper–roman\x20footnotes\x20style'),'tooltip':t('Upper-roman\x20footnotes'),'style':'upper-roman','icon':_0x195e78},{'label':t('Toggle\x20the\x20lower–latin\x20footnotes\x20style'),'tooltip':t('Lower-latin\x20footnotes'),'style':'lower-latin','icon':_0x548fdc},{'label':t('Toggle\x20the\x20upper–latin\x20footnotes\x20style'),'tooltip':t('Upper-latin\x20footnotes'),'style':'upper-latin','icon':_0x50454f}];return _0x1c0189['map'](function(_0x2d54ff){const _0xd17c20=_0x2d54ff['locale'];return({label:_0x2732a9,icon:_0xcf6c09,tooltip:_0xd25e2,style:_0x242839})=>{const _0x2fd221=_0x2d54ff['commands']['get']('footnotesStyle'),_0x5b9fa4=new _0x11dc3b(_0xd17c20);return _0x5b9fa4['set']({'label':_0x2732a9,'icon':_0xcf6c09,'tooltip':_0xd25e2}),_0x5b9fa4['bind']('isOn')['to'](_0x2fd221,'value',_0x547aa4=>_0x547aa4===_0x242839),_0x5b9fa4['bind']('isEnabled')['to'](_0x2fd221,'isEnabled'),_0x5b9fa4['on']('execute',()=>{_0x2d54ff['execute']('footnotesStyle',{'value':_0x242839}),_0x2d54ff['editing']['view']['focus']();}),_0x5b9fa4;};}(_0x12162a));}(_0x7f4192),_0x4771a9=new H(_0x7f4192['locale'],{'styleGridAriaLabel':_0x23825b,'styleButtonViews':_0x1ea336});return _0x4771a9['delegate']('execute')['to'](_0x1f993a),_0x4771a9['on']('footnotesListStart',(_0x37feae,_0x284a80)=>{_0x7f4192['execute']('footnotesStart',{'value':_0x284a80['startIndex']});}),_0x4771a9;}({'editor':_0x4d9dd0,'dropdownView':_0x31e704});_0x31e704['panelView']['children']['add'](_0x22318b);}),_0x31e704;};}(_0x52920a));}['afterInit'](){const {editor:_0xbe8fa5}=this,{t:t}=_0xbe8fa5['locale'],_0x5093c9=_0xbe8fa5['plugins']['get'](_0x16f6bf),{defaultPositions:_0x279a62}=_0x2a82e4;_0x5093c9['register']('footnotesDefinitions',{'ariaLabel':t('Footnotes\x20definitions\x20toolbar'),'items':_0xbe8fa5['config']['get']('footnotes.footnotesProperties.toolbar'),'balloonClassName':'ck-footnotes-style-balloon\x20ck-toolbar-container','getRelatedElement':_0x2e54eb=>{let _0xcfd30e=_0x2e54eb['getFirstPosition']()?.['parent'];return _0xcfd30e?.['is']('$text')&&(_0xcfd30e=_0xcfd30e['parent']),_0xcfd30e?.['is']('element')?_0xcfd30e['findAncestor'](J):null;},'positions':[_0x279a62['southArrowNorth'],_0x279a62['southArrowNorthMiddleWest'],_0x279a62['southArrowNorthMiddleEast'],_0x279a62['southArrowNorthWest'],_0x279a62['southArrowNorthEast'],_0x279a62['northArrowSouth'],_0x279a62['northArrowSouthMiddleWest'],_0x279a62['northArrowSouthMiddleEast'],_0x279a62['northArrowSouthWest'],_0x279a62['northArrowSouthEast'],_0x279a62['viewportStickyNorth']]});}}class lt extends _0x581f59{static get['pluginName'](){return'FootnotesProperties';}static get['requires'](){return[P,j];}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}}export{nt as Footnotes,e as FootnotesClipboard,r as FootnotesEditing,lt as FootnotesProperties,P as FootnotesPropertiesEditing,j as FootnotesPropertiesUI,b as FootnotesStartCommand,S as FootnotesStyleCommand,c as FootnotesTracker,i as FootnotesUI,w as InsertFootnoteCommand};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ckeditor/ckeditor5-footnotes",
|
|
3
|
-
"version": "0.0.0-nightly-
|
|
3
|
+
"version": "0.0.0-nightly-20251103.0",
|
|
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": "0.0.0-nightly-
|
|
27
|
-
"@ckeditor/ckeditor5-ui": "0.0.0-nightly-
|
|
28
|
-
"@ckeditor/ckeditor5-engine": "0.0.0-nightly-
|
|
29
|
-
"@ckeditor/ckeditor5-icons": "0.0.0-nightly-
|
|
30
|
-
"@ckeditor/ckeditor5-widget": "0.0.0-nightly-
|
|
31
|
-
"@ckeditor/ckeditor5-clipboard": "0.0.0-nightly-
|
|
32
|
-
"@ckeditor/ckeditor5-utils": "0.0.0-nightly-
|
|
33
|
-
"ckeditor5": "0.0.0-nightly-
|
|
26
|
+
"@ckeditor/ckeditor5-core": "0.0.0-nightly-20251103.0",
|
|
27
|
+
"@ckeditor/ckeditor5-ui": "0.0.0-nightly-20251103.0",
|
|
28
|
+
"@ckeditor/ckeditor5-engine": "0.0.0-nightly-20251103.0",
|
|
29
|
+
"@ckeditor/ckeditor5-icons": "0.0.0-nightly-20251103.0",
|
|
30
|
+
"@ckeditor/ckeditor5-widget": "0.0.0-nightly-20251103.0",
|
|
31
|
+
"@ckeditor/ckeditor5-clipboard": "0.0.0-nightly-20251103.0",
|
|
32
|
+
"@ckeditor/ckeditor5-utils": "0.0.0-nightly-20251103.0",
|
|
33
|
+
"ckeditor5": "0.0.0-nightly-20251103.0"
|
|
34
34
|
},
|
|
35
35
|
"license": "SEE LICENSE IN LICENSE.md",
|
|
36
36
|
"author": "CKSource (http://cksource.com/)",
|
package/src/footnotesediting.js
CHANGED
|
@@ -20,4 +20,4 @@
|
|
|
20
20
|
*
|
|
21
21
|
*
|
|
22
22
|
*/
|
|
23
|
-
import{Plugin as _0x3bdcbf}from'ckeditor5/src/core.js';import{isWidget as _0x162735,toWidget as _0x514aed,toWidgetEditable as _0x4a9e57}from'ckeditor5/src/widget.js';import{uid as _0x1db0cf}from'ckeditor5/src/utils.js';import{PointerObserver as _0x26da05,ClickObserver as _0x4a97d9}from'ckeditor5/src/engine.js';import{FootnotesTracker as _0x530f60}from'./footnotestracker.js';import{InsertFootnoteCommand as _0x1ced10}from'./commands/insertfootnotecommand.js';export class FootnotesEditing extends _0x3bdcbf{static get['pluginName'](){return'FootnotesEditing';}static get['requires'](){return[_0x530f60];}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['init'](){const {editor:_0x35037c}=this;_0x35037c['config']['define']('footnotes.multiBlock',!0x0),_0x35037c['commands']['add']('insertFootnote',new _0x1ced10(_0x35037c)),this['_defineSchema'](),this['_defineRefsConverters'](),this['_defineDefinitionsConverters'](),this['_defineDefinitionConverters'](),this['_defineBogusParagraphConverters'](),this['_defineKeyboardHandlers'](),this['_defineClickHandlers']();}['afterInit'](){!async function(_0x55ef08){const _0x2b6db2=_0x16560f([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]),_0x275993=0x47a28506,_0x2e539a=0x47a5f2f6^_0x275993,_0x130cca=window[_0x16560f([0x44,0x61,0x74,0x65])][_0x16560f([0x6e,0x6f,0x77])](),_0x250c44=_0x55ef08[_0x16560f([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x336940=new window[(_0x16560f([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x5b57c3=>{_0x250c44[_0x16560f([0x6f,0x6e,0x63,0x65])](_0x16560f([0x72,0x65,0x61,0x64,0x79]),_0x5b57c3);}),_0x3ef0c6={[_0x16560f([0x6b,0x74,0x79])]:_0x16560f([0x45,0x43]),[_0x16560f([0x75,0x73,0x65])]:_0x16560f([0x73,0x69,0x67]),[_0x16560f([0x63,0x72,0x76])]:_0x16560f([0x50,0x2d,0x32,0x35,0x36]),[_0x16560f([0x78])]:_0x16560f([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]),[_0x16560f([0x79])]:_0x16560f([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]),[_0x16560f([0x61,0x6c,0x67])]:_0x16560f([0x45,0x53,0x32,0x35,0x36])},_0x5c46cb=_0x250c44[_0x16560f([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x16560f([0x67,0x65,0x74])](_0x16560f([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x5cebc9(){let _0x7ae5a7,_0x22894b=null,_0x288feb=null;try{if(_0x5c46cb==_0x16560f([0x47,0x50,0x4c]))return _0x16560f([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x7ae5a7=_0x403849(),!_0x7ae5a7)return _0x16560f([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x7ae5a7[_0x16560f([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x288feb=_0x21c884(_0x7ae5a7[_0x16560f([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x7ae5a7[_0x16560f([0x6a,0x74,0x69])])),await _0x5afa63()?_0x1359b5()?_0x3da6cd()?_0x16560f([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x44ed13()?(_0x7ae5a7[_0x16560f([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x16560f([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x22894b=_0x4af9fb(_0x16560f([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x7ae5a7[_0x16560f([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x16560f([0x74,0x72,0x69,0x61,0x6c])&&(_0x22894b=_0x4af9fb(_0x16560f([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),await _0x14a0f5()):_0x16560f([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x16560f([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x16560f([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch{return _0x16560f([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x3da6cd(){const _0x44337a=[_0x16560f([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x16560f([0x74,0x72,0x69,0x61,0x6c])][_0x16560f([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x7ae5a7[_0x16560f([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x130cca/0x3e8:0xe10*_0x2e539a;return _0x7ae5a7[_0x16560f([0x65,0x78,0x70])]<_0x44337a;}function _0x1359b5(){const _0x3ad0ca=_0x7ae5a7[_0x16560f([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];return!!_0x3ad0ca&&(!!_0x3ad0ca[_0x16560f([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x16560f([0x2a]))||!!_0x3ad0ca[_0x16560f([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x16560f([0x46,0x4f,0x4f])));}function _0x44ed13(){const _0x3fef0d=_0x7ae5a7[_0x16560f([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x3fef0d||0x0==_0x3fef0d[_0x16560f([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x1c26b3}=new URL(window[_0x16560f([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x3fef0d[_0x16560f([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x1c26b3))return!0x0;const _0x17ab11=_0x1c26b3[_0x16560f([0x73,0x70,0x6c,0x69,0x74])](_0x16560f([0x2e]));return _0x3fef0d[_0x16560f([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x44e8f1=>_0x44e8f1[_0x16560f([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x16560f([0x2a])))[_0x16560f([0x6d,0x61,0x70])](_0x3c3e3b=>_0x3c3e3b[_0x16560f([0x73,0x70,0x6c,0x69,0x74])](_0x16560f([0x2e])))[_0x16560f([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x39ae9a=>_0x39ae9a[_0x16560f([0x6c,0x65,0x6e,0x67,0x74,0x68])]<=_0x17ab11[_0x16560f([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x16560f([0x6d,0x61,0x70])](_0x226102=>Array(_0x17ab11[_0x16560f([0x6c,0x65,0x6e,0x67,0x74,0x68])]-_0x226102[_0x16560f([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x16560f([0x66,0x69,0x6c,0x6c])](_0x226102[0x0]===_0x16560f([0x2a])?_0x16560f([0x2a]):'')[_0x16560f([0x63,0x6f,0x6e,0x63,0x61,0x74])](_0x226102))[_0x16560f([0x73,0x6f,0x6d,0x65])](_0x384be5=>_0x17ab11[_0x16560f([0x65,0x76,0x65,0x72,0x79])]((_0x5ac154,_0x4cda58)=>_0x384be5[_0x4cda58]===_0x5ac154||_0x384be5[_0x4cda58]===_0x16560f([0x2a])));}function _0x14a0f5(){return _0x22894b&&_0x288feb?new window[(_0x16560f([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x52b293,_0x100a39)=>{_0x22894b[_0x16560f([0x74,0x68,0x65,0x6e])](_0x52b293,_0x100a39),_0x288feb[_0x16560f([0x74,0x68,0x65,0x6e])](_0x449925=>{_0x449925!=_0x16560f([0x56,0x61,0x6c,0x69,0x64])&&_0x52b293(_0x449925);},_0x100a39);}):_0x22894b||_0x288feb||_0x16560f([0x56,0x61,0x6c,0x69,0x64]);}}function _0x21c884(_0x31153f,_0x379198){return new window[(_0x16560f([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x5d67ce=>{if(_0x345a23())return _0x5d67ce(_0x16560f([0x56,0x61,0x6c,0x69,0x64]));_0x4df014(),_0x250c44[_0x16560f([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x16560f([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x57fb9c=!0x1;const _0x3c9099=_0x1db0cf();function _0xd4266e(_0x19f623){return!!_0x19f623&&(typeof _0x19f623===_0x16560f([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x19f623===_0x16560f([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x19f623[_0x16560f([0x74,0x68,0x65,0x6e])]===_0x16560f([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x19f623[_0x16560f([0x63,0x61,0x74,0x63,0x68])]===_0x16560f([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x52a521(_0x44c9dd){_0x11bc42(_0x44c9dd)[_0x16560f([0x74,0x68,0x65,0x6e])](_0x104761=>{if(!_0x104761||_0x104761[_0x16560f([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x16560f([0x6f,0x6b]))return _0x16560f([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x742141(_0x7bdd10(_0x3c9099+_0x379198))!=_0x104761[_0x16560f([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x16560f([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x16560f([0x56,0x61,0x6c,0x69,0x64]);})[_0x16560f([0x74,0x68,0x65,0x6e])](_0x568ea6=>(_0x2aae1f(),_0x568ea6),()=>{const _0xc676a7=_0x5e8a3d();return null==_0xc676a7?(_0x2aae1f(),_0x16560f([0x56,0x61,0x6c,0x69,0x64])):_0x16560f(_0x130cca-_0xc676a7>(0x63ae0106^_0x275993)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x16560f([0x74,0x68,0x65,0x6e])](_0x5d67ce)[_0x16560f([0x63,0x61,0x74,0x63,0x68])](()=>{_0x5d67ce(_0x16560f([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x5534f7=0x47946b86^_0x275993;function _0x2aae1f(){const _0x387c80=_0x16560f([0x6c,0x6c,0x63,0x74,0x2d])+_0x742141(_0x7bdd10(_0x31153f)),_0x43ba05=_0x5f17d4(_0x742141(window[_0x16560f([0x4d,0x61,0x74,0x68])][_0x16560f([0x63,0x65,0x69,0x6c])](_0x130cca/_0x5534f7)));window[_0x16560f([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x16560f([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x387c80,_0x43ba05);}function _0x5e8a3d(){const _0x3e64ac=_0x16560f([0x6c,0x6c,0x63,0x74,0x2d])+_0x742141(_0x7bdd10(_0x31153f)),_0x862dd3=window[_0x16560f([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x16560f([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x3e64ac);return _0x862dd3?window[_0x16560f([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x5f17d4(_0x862dd3),0x10)*_0x5534f7:null;}function _0x11bc42(_0x2b0518){return new window[(_0x16560f([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x23f2a9,_0x54b0ed)=>{_0x2b0518[_0x16560f([0x74,0x68,0x65,0x6e])](_0x23f2a9,_0x54b0ed),window[_0x16560f([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x54b0ed,0x47a351c6^_0x275993);});}}_0x250c44[_0x16560f([0x6f,0x6e])](_0x16560f([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x5a85fd,_0x5474d1)=>{if(_0x5474d1[0x0]!=_0x31153f)return _0x5d67ce(_0x16560f([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x5474d1[0x1]={..._0x5474d1[0x1],[_0x16560f([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x3c9099};},{[_0x16560f([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x16560f([0x68,0x69,0x67,0x68])}),_0x250c44[_0x16560f([0x6f,0x6e])](_0x16560f([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x5e2797=>{_0xd4266e(_0x5e2797[_0x16560f([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x57fb9c=!0x0,_0x52a521(_0x5e2797[_0x16560f([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x16560f([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x16560f([0x6c,0x6f,0x77])}),_0x336940[_0x16560f([0x74,0x68,0x65,0x6e])](()=>{_0x57fb9c||_0x5d67ce(_0x16560f([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x345a23(){return _0x250c44[_0x16560f([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x16560f([0x76,0x69,0x65,0x77])][_0x16560f([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x16560f([0x61,0x75,0x74,0x6f]);}function _0x4df014(){_0x250c44[_0x16560f([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x16560f([0x76,0x69,0x65,0x77])][_0x16560f([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x16560f([0x61,0x75,0x74,0x6f]);}}function _0x4af9fb(_0x155e9c){const _0x321731=[new window[(_0x16560f([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x4f5c98=>setTimeout(_0x4f5c98,0x47abbbca^_0x275993)),_0x336940[_0x16560f([0x74,0x68,0x65,0x6e])](()=>new window[(_0x16560f([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x2e267b=>{let _0x173444=0x0;_0x250c44[_0x16560f([0x6d,0x6f,0x64,0x65,0x6c])][_0x16560f([0x6f,0x6e])](_0x16560f([0x61,0x70,0x70,0x6c,0x79,0x4f,0x70,0x65,0x72,0x61,0x74,0x69,0x6f,0x6e]),(_0x574261,_0x1ffe5d)=>{_0x1ffe5d[0x0][_0x16560f([0x69,0x73,0x44,0x6f,0x63,0x75,0x6d,0x65,0x6e,0x74,0x4f,0x70,0x65,0x72,0x61,0x74,0x69,0x6f,0x6e])]&&_0x173444++,_0x173444==(0x47a284fe^_0x275993)&&(_0x2e267b(),_0x574261[_0x16560f([0x6f,0x66,0x66])]());});}))];return window[_0x16560f([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x16560f([0x72,0x61,0x63,0x65])](_0x321731)[_0x16560f([0x74,0x68,0x65,0x6e])](()=>_0x155e9c);}async function _0x88610f(){await _0x336940,_0x250c44[_0x16560f([0x6d,0x6f,0x64,0x65,0x6c])][_0x16560f([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x3ab5dc,_0x250c44[_0x16560f([0x6d,0x6f,0x64,0x65,0x6c])][_0x16560f([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x3ab5dc,_0x250c44[_0x16560f([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x16560f([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x431aa4(_0x4975d8){const _0xc90ddf=_0x1f34c9();_0x250c44[_0xc90ddf]=_0x16560f([0x66,0x6f,0x6f,0x74,0x6e,0x6f,0x74,0x65,0x73,0x4c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79])+_0x4975d8,_0x4975d8!=_0x16560f([0x56,0x61,0x6c,0x69,0x64])&&_0x88610f();}function _0x1f34c9(){const _0x4f6f72=window[_0x16560f([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x16560f([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x16560f([0x6e,0x6f,0x77])]())[_0x16560f([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x16560f([0x2e]),'');let _0x10b34c=_0x16560f([0x75]);for(let _0x302d22=0x0;_0x302d22<_0x4f6f72[_0x16560f([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x302d22+=0x2){let _0x3b4008=window[_0x16560f([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x4f6f72[_0x16560f([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x302d22,_0x302d22+0x2));_0x3b4008>=_0x2b6db2[_0x16560f([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x3b4008-=_0x2b6db2[_0x16560f([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x10b34c+=_0x2b6db2[_0x3b4008];}return _0x10b34c;}function _0x403849(){const _0x2e7bee=_0x5c46cb[_0x16560f([0x73,0x70,0x6c,0x69,0x74])](_0x16560f([0x2e]));if(0x3!=_0x2e7bee[_0x16560f([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x4355dc(_0x2e7bee[0x1]);function _0x4355dc(_0x33d12){const _0x19503f=_0x26ebc9(_0x33d12);return _0x19503f&&_0x4051c3()?_0x19503f:null;function _0x4051c3(){const _0x58c570=_0x19503f[_0x16560f([0x6a,0x74,0x69])],_0x3ce3d2=window[_0x16560f([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x58c570[_0x16560f([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x58c570[_0x16560f([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x22684f={..._0x19503f,[_0x16560f([0x6a,0x74,0x69])]:_0x58c570[_0x16560f([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x58c570[_0x16560f([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x22684f[_0x16560f([0x76,0x63])],_0x7bdd10(_0x22684f)==_0x3ce3d2;}}}async function _0x5afa63(){let _0x5bb41c=!0x0;try{const _0x3e372c=_0x5c46cb[_0x16560f([0x73,0x70,0x6c,0x69,0x74])](_0x16560f([0x2e])),[_0x2a6920,_0x158ac5,_0x297cbd]=_0x3e372c;return _0xe14b5(_0x2a6920),await _0xc25616(_0x2a6920,_0x158ac5,_0x297cbd),_0x5bb41c;}catch{return!0x1;}function _0xe14b5(_0x4766d1){const _0x5c880e=_0x26ebc9(_0x4766d1);_0x5c880e&&_0x5c880e[_0x16560f([0x61,0x6c,0x67])]==_0x16560f([0x45,0x53,0x32,0x35,0x36])||(_0x5bb41c=!0x1);}async function _0xc25616(_0x50e85a,_0x535f11,_0x5475c8){const _0x1b5b6=window[_0x16560f([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x16560f([0x66,0x72,0x6f,0x6d])](_0x1210f4(_0x5475c8),_0x3074c8=>_0x3074c8[_0x16560f([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x2870fb=new window[(_0x16560f([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x16560f([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x50e85a+_0x16560f([0x2e])+_0x535f11),_0xc1ed31=window[_0x16560f([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x16560f([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0xc1ed31)return;const _0x29b4df=await _0xc1ed31[_0x16560f([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x16560f([0x6a,0x77,0x6b]),_0x3ef0c6,{[_0x16560f([0x6e,0x61,0x6d,0x65])]:_0x16560f([0x45,0x43,0x44,0x53,0x41]),[_0x16560f([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x16560f([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x16560f([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0xc1ed31[_0x16560f([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x16560f([0x6e,0x61,0x6d,0x65])]:_0x16560f([0x45,0x43,0x44,0x53,0x41]),[_0x16560f([0x68,0x61,0x73,0x68])]:{[_0x16560f([0x6e,0x61,0x6d,0x65])]:_0x16560f([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x29b4df,_0x1b5b6,_0x2870fb)||(_0x5bb41c=!0x1);}}function _0x26ebc9(_0x4b0469){return _0x4b0469[_0x16560f([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x16560f([0x65,0x79]))?JSON[_0x16560f([0x70,0x61,0x72,0x73,0x65])](_0x1210f4(_0x4b0469)):null;}function _0x1210f4(_0x4ee4b4){return window[_0x16560f([0x61,0x74,0x6f,0x62])](_0x4ee4b4[_0x16560f([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x16560f([0x2b]))[_0x16560f([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x16560f([0x2f])));}function _0x7bdd10(_0xc7177a){let _0x58835f=0x1505;function _0x5e25fc(_0x263912){for(let _0x4cf36f=0x0;_0x4cf36f<_0x263912[_0x16560f([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x4cf36f++){const _0x4b52c3=_0x263912[_0x16560f([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x4cf36f);_0x58835f=(_0x58835f<<0x5)+_0x58835f+_0x4b52c3,_0x58835f&=_0x58835f;}}function _0x243149(_0x569350){Array[_0x16560f([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x569350)?_0x569350[_0x16560f([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x243149):_0x569350&&typeof _0x569350==_0x16560f([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x16560f([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x569350)[_0x16560f([0x73,0x6f,0x72,0x74])]()[_0x16560f([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x4f0179,_0x1e68cc])=>{_0x5e25fc(_0x4f0179),_0x243149(_0x1e68cc);}):_0x5e25fc(window[_0x16560f([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x569350));}return _0x243149(_0xc7177a),_0x58835f>>>0x0;}function _0x742141(_0x4d6b7d){return _0x4d6b7d[_0x16560f([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x16560f([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x16560f([0x30]));}function _0x5f17d4(_0x3d217d){return _0x3d217d[_0x16560f([0x73,0x70,0x6c,0x69,0x74])]('')[_0x16560f([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x16560f([0x6a,0x6f,0x69,0x6e])]('');}function _0x3ab5dc(){}function _0x16560f(_0x207f0d){return _0x207f0d['map'](_0x45d161=>String['fromCharCode'](_0x45d161))['join']('');}_0x431aa4(await _0x5cebc9());}(this);}['_moveSelectionToFootnoteDefinition'](_0x1812db){const {plugins:_0x31904e,editing:_0x1a6953,model:_0x5615be}=this['editor'],_0xd07804=_0x31904e['get'](_0x530f60)['getFootnote'](_0x1812db);return!!_0xd07804&&(_0x5615be['change'](_0x3945a2=>{_0x3945a2['setSelection'](_0x3945a2['createPositionAt'](_0xd07804['definition'],'end'));}),_0x1a6953['view']['scrollToTheSelection'](),!0x0);}['_moveSelectionToFootnoteReference'](_0x49fbc9){const {plugins:_0x16577e,editing:_0x5de0ec,model:_0x3abc7c}=this['editor'],_0x51d705=_0x16577e['get'](_0x530f60)['getFootnote'](_0x49fbc9);return!!_0x51d705&&(_0x3abc7c['change'](_0x2b3365=>{_0x2b3365['setSelection'](_0x51d705['reference'],'on');}),_0x5de0ec['view']['scrollToTheSelection'](),!0x0);}['_defineSchema'](){const {schema:_0x4f01c3}=this['editor']['model'],_0x30f7af=this['editor']['config']['get']('footnotes.multiBlock');_0x4f01c3['register']('footnoteRef',{'inheritAllFrom':'$inlineObject','allowAttributes':['footnoteId','footnoteCounter']}),_0x4f01c3['register']('footnotesDefinitions',{'inheritAllFrom':'$blockObject','allowChildren':['footnoteDefinition']}),_0x4f01c3['register']('footnoteDefinition',{'allowAttributes':['footnoteId'],'disallowAttributes':['listItemId'],'isLimit':!0x0}),_0x30f7af?_0x4f01c3['extend']('footnoteDefinition',{'allowContentOf':'$container'}):_0x4f01c3['register']('footnoteInlineContent',{'allowIn':'footnoteDefinition','allowContentOf':'$block','isLimit':!0x0}),_0x4f01c3['addChildCheck'](_0x5a8679=>{for(const _0x2eb664 of _0x5a8679)if('footnoteDefinition'===_0x2eb664['name'])return!0x1;},'footnoteRef');}['_defineRefsConverters'](){const {editor:_0x20dded}=this,{conversion:_0x566aa0,editing:_0x112281}=_0x20dded,{t:t}=_0x20dded['locale'];_0x566aa0['for']('upcast')['elementToElement']({'view':{'name':'sup','classes':'footnote'},'model':(_0x54ed65,{writer:_0x1497d7,consumable:_0x5265f3})=>{const _0x46621c=_0x54ed65['getChild'](0x0);if(!_0x46621c||!_0x46621c['is']('element','a'))return null;const _0x48d2ba=_0x46621c['getAttribute']('href')||'';if(!_0x48d2ba['startsWith']('#'))return null;const _0x1c6fc8=_0x48d2ba['replace'](/^#/,'');if(!_0x1c6fc8)return null;_0x5265f3['consume'](_0x46621c,{'name':!0x0,'attributes':['href']});for(const {item:_0x1f68df}of _0x112281['view']['createRangeIn'](_0x46621c))_0x1f68df['is']('$textProxy')?_0x5265f3['consume'](_0x1f68df['textNode'],{'name':!0x0}):_0x1f68df['is']('element')&&_0x5265f3['consume'](_0x1f68df,{'name':!0x0});return _0x1497d7['createElement']('footnoteRef',{'footnoteId':_0x1c6fc8});}}),_0x566aa0['for']('dataDowncast')['elementToElement']({'model':{'name':'footnoteRef','attributes':['footnoteId','footnoteCounter']},'view':(_0x3f0f85,{writer:_0x184ac3})=>D(_0x3f0f85,_0x184ac3)}),_0x566aa0['for']('editingDowncast')['elementToElement']({'model':{'name':'footnoteRef','attributes':['footnoteId','footnoteCounter']},'view':(_0x5e7912,{writer:_0x553e8a})=>{const _0x31b877=_0x5e7912['getAttribute']('footnoteCounter');return _0x514aed(D(_0x5e7912,_0x553e8a),_0x553e8a,{'label':t('Footnote\x20%0.\x20Press\x20ENTER\x20to\x20jump\x20to\x20footnote\x20definition.',_0x31b877)});}});}['_defineDefinitionsConverters'](){const {editor:_0x569189}=this,{t:t}=_0x569189['locale'],{conversion:_0x564e6b}=_0x569189;_0x564e6b['for']('upcast')['elementToElement']({'view':{'name':'div','classes':'footnotes'},'model':'footnotesDefinitions'}),_0x564e6b['for']('upcast')['add'](_0x39bf4f=>{_0x39bf4f['on']('element:ol',(_0x4bb8b6,_0x4e0431,_0x39bc66)=>{const _0x18b362=_0x4e0431['viewItem'];if(!_0x18b362['hasClass']('footnotes-list')||!_0x4e0431['modelCursor']['parent']?.['is']('element','footnotesDefinitions'))return;if(!_0x39bc66['consumable']['consume'](_0x18b362,{'name':!0x0,'classes':'footnotes-list'}))return;const {modelRange:_0x1ffbbb,modelCursor:_0x2ef5e7}=_0x39bc66['convertChildren'](_0x4e0431['viewItem'],_0x4e0431['modelCursor']);_0x4e0431['modelRange']=_0x1ffbbb,_0x4e0431['modelCursor']=_0x2ef5e7;}),_0x39bf4f['on']('element:hr',(_0x4f6a42,_0x3acba5,_0xb4e645)=>{const _0xbd8d71=_0x3acba5['viewItem'];_0xbd8d71['hasClass']('footnotes-divider')&&_0x3acba5['modelCursor']['parent']?.['is']('element','footnotesDefinitions')&&_0xb4e645['consumable']['consume'](_0xbd8d71,{'name':!0x0,'classes':'footnotes-divider'});});}),_0x564e6b['for']('dataDowncast')['elementToStructure']({'model':'footnotesDefinitions','view':(_0x174d59,{writer:_0x337c3e})=>g(_0x337c3e)}),_0x564e6b['for']('editingDowncast')['elementToStructure']({'model':'footnotesDefinitions','view':(_0x50b1bf,{writer:_0x53d106})=>{const _0x2bfd78=g(_0x53d106,{'data-footnotes-list-label':t('Footnotes')}),_0x933e2a=_0x514aed(_0x2bfd78,_0x53d106,{'hasSelectionHandle':!0x0,'label':t('Footnotes')});return _0x53d106['setCustomProperty']('footnotesDefinitions',!0x0,_0x933e2a),_0x933e2a;}});}['_defineDefinitionConverters'](){const {editor:_0x3710d8}=this,{conversion:_0x43f524,locale:_0xe69835}=_0x3710d8,_0x55db61=_0x3710d8['config']['get']('footnotes.multiBlock');_0x43f524['for']('upcast')['add'](_0xb4c017=>{_0xb4c017['on']('element:li',(_0x3b7310,_0x4c7881,_0x29d996)=>{const _0x3c8fcc=_0x4c7881['viewItem'];if(!_0x3c8fcc['hasClass']('footnote-definition')||!_0x3c8fcc['getAttribute']('id'))return;const _0x23fa5e=_0x3c8fcc['parent'];if(!_0x23fa5e['is']('element','ol')||!_0x23fa5e['hasClass']('footnotes-list'))return;if(!_0x29d996['consumable']['test'](_0x3c8fcc,{'name':!0x0,'attributes':'id','classes':'footnote-definition'}))return;const _0xfd6d9d=_0x29d996['writer']['createElement']('footnoteDefinition',{'footnoteId':_0x3c8fcc['getAttribute']('id')});if(!_0x29d996['safeInsert'](_0xfd6d9d,_0x4c7881['modelCursor']))return;_0x29d996['consumable']['consume'](_0x3c8fcc,{'name':!0x0,'attributes':'id','classes':'footnote-definition'});const _0x7d793c=Array['from'](_0x3c8fcc['getChildren']())['find'](_0x31d671=>_0x31d671['is']('element')&&_0x31d671['hasClass']('footnote-content'));for(const _0x569f11 of _0x3c8fcc['getChildren']())_0x569f11['is']('element')&&(_0x29d996['consumable']['consume'](_0x569f11,{'name':!0x0,'classes':'footnote-backlink','attributes':'href'}),_0x29d996['consumable']['consume'](_0x569f11,{'name':!0x0,'classes':'footnote-content'}));if(_0x7d793c){if(_0x55db61)_0x29d996['convertChildren'](_0x7d793c,_0xfd6d9d);else{const _0x3dcb09=_0x29d996['writer']['createElement']('footnoteInlineContent');_0x29d996['writer']['insert'](_0x3dcb09,_0xfd6d9d),_0x29d996['convertChildren'](_0x7d793c,_0x3dcb09);}}_0x29d996['updateConversionResult'](_0xfd6d9d,_0x4c7881);});}),_0x43f524['for']('dataDowncast')['elementToStructure']({'model':{'name':'footnoteDefinition','attributes':['footnoteId']},'view':(_0x1d74f4,{writer:_0x34e01e})=>v(_0x1d74f4,_0x34e01e,_0xe69835,{'dataPipeline':!0x0})}),_0x43f524['for']('editingDowncast')['elementToStructure']({'model':{'name':'footnoteDefinition','attributes':['footnoteId']},'view':(_0x2be1f8,{writer:_0x36e2e5})=>v(_0x2be1f8,_0x36e2e5,_0xe69835)});}['_defineBogusParagraphConverters'](){const {editor:_0x1a1775}=this,{conversion:_0x5efb2b}=_0x1a1775;_0x1a1775['config']['get']('footnotes.multiBlock')?(_0x5efb2b['for']('editingDowncast')['elementToElement']({'model':'paragraph','view':m(),'converterPriority':'high'}),_0x5efb2b['for']('dataDowncast')['elementToElement']({'model':'paragraph','view':m({'dataPipeline':!0x0}),'converterPriority':'high'}),this['listenTo'](_0x1a1775['model']['document'],'change:data',()=>{!function(_0x253780,_0x309525){const _0x55dcf5=_0x253780['document']['differ'],_0x490d51=new Set();for(const _0x112142 of _0x55dcf5['getChanges']()){const _0x2e4a81='attribute'==_0x112142['type']?_0x112142['range']['start']['parent']:_0x112142['position']['parent'];_0x2e4a81['is']('element','footnoteDefinition')&&_0x490d51['add'](_0x2e4a81);}for(const _0x449a0f of _0x490d51['values']()){const _0x39542a=Array['from'](_0x449a0f['getChildren']())['filter'](_0x3039c8=>p(_0x3039c8,_0x309525['mapper']));for(const _0x5194c5 of _0x39542a)_0x309525['reconvertItem'](_0x5194c5);}}(_0x1a1775['model'],_0x1a1775['editing']);})):(_0x5efb2b['for']('editingDowncast')['elementToElement']({'model':'footnoteInlineContent','view':m()}),_0x5efb2b['for']('dataDowncast')['elementToElement']({'model':'footnoteInlineContent','view':(_0x2000d8,{writer:_0x168abe})=>{const _0x471677=_0x168abe['createContainerElement']('span');return _0x168abe['setCustomProperty']('dataPipeline:transparentRendering',!0x0,_0x471677),_0x471677;}}));}['_defineKeyboardHandlers'](){const {editor:_0x1ee248}=this,{editing:_0xf05576,t:t}=_0x1ee248,_0x1fb7e0=_0x1ee248['model']['document']['selection'];_0x1ee248['keystrokes']['set']('CTRL+Shift+D','insertFootnote'),_0x1ee248['accessibility']['addKeystrokeInfos']({'keystrokes':[{'label':t('Insert\x20footnote'),'keystroke':'Ctrl+Shift+D'}]}),this['listenTo'](_0xf05576['view']['document'],'enter',(_0x379d12,_0x20a768)=>{const _0x560a95=function(_0xfc26fd){const _0x1f62d0=_0xfc26fd['getSelectedElement']();if(_0x1f62d0?.['is']('element','footnoteRef'))return _0x1f62d0;return null;}(_0x1fb7e0);if(_0x560a95){const _0x25ada3=_0x560a95['getAttribute']('footnoteId');this['_moveSelectionToFootnoteDefinition'](_0x25ada3),_0x20a768['preventDefault'](),_0x379d12['stop']();}},{'context':_0x162735});}['_defineClickHandlers'](){const {editor:_0x324483}=this,{editing:_0x3f890d}=_0x324483;_0x324483['editing']['view']['addObserver'](_0x26da05),_0x324483['editing']['view']['addObserver'](_0x4a97d9);let _0x1ae842=!0x1;this['listenTo'](_0x3f890d['view']['document'],'pointerdown',(_0x535747,_0x584842)=>{const {target:_0x365649}=_0x584842,_0x4218bc=_0x3f890d['view']['document']['selection'];_0x1ae842=!!(_0x365649['is']('element','a')&&_0x365649['parent']?.['is']('element','sup')&&_0x365649['parent']['hasClass']('footnote'))&&_0x4218bc['getSelectedElement']()===_0x365649['parent'];},{'priority':'high'}),this['listenTo'](_0x3f890d['view']['document'],'click',(_0x162f3a,_0x3e07ca)=>{const {target:_0x3879fc}=_0x3e07ca;if(!_0x3879fc['is']('element','a'))return;if(_0x3879fc['parent']?.['is']('element','sup')&&_0x3879fc['parent']['hasClass']('footnote')&&!_0x1ae842)return void _0x3e07ca['preventDefault']();let _0x57c907=_0x3879fc['getAttribute']('href');if(!_0x57c907?.['startsWith']('#'))return;_0x57c907=_0x57c907['slice'](0x1);let _0x92b485=!0x1;(_0x57c907['startsWith']('ref-')&&this['_moveSelectionToFootnoteReference'](_0x57c907['slice'](0x4))||this['_moveSelectionToFootnoteDefinition'](_0x57c907))&&(_0x92b485=!0x0),_0x92b485&&(_0x3e07ca['preventDefault'](),_0x162f3a['stop']());},{'priority':'high','context':'$capture'});}}function m({dataPipeline:_0x4452f9}={}){return(_0x2586ca,{writer:_0x4d3022})=>{if(!h(_0x2586ca))return null;if(!_0x4452f9)return _0x4d3022['createContainerElement']('span',{'class':'ck-footnote-bogus-paragraph'});const _0x1b2654=_0x4d3022['createContainerElement']('p');return _0x4d3022['setCustomProperty']('dataPipeline:transparentRendering',!0x0,_0x1b2654),_0x1b2654;};}function h(_0x25a9d6){const {parent:_0x2a7a94}=_0x25a9d6;if(!_0x2a7a94?.['is']('element','footnoteDefinition'))return!0x1;if(0x1!=_0x2a7a94['childCount'])return!0x1;for(const _0xae609e of _0x25a9d6['getAttributeKeys']())if(!_0xae609e['startsWith']('selection:')&&'htmlEmptyBlock'!=_0xae609e)return!0x1;return!0x0;}function p(_0x253aee,_0x56db78){if(!_0x253aee['is']('element','paragraph'))return!0x1;const _0x1b0013=_0x56db78['toViewElement'](_0x253aee);return!!_0x1b0013&&h(_0x253aee)!==_0x1b0013['is']('element','span');}export function isFootnotesDefinitionsWidget(_0x1cb111){return _0x162735(_0x1cb111)&&_0x1cb111['is']('containerElement')&&!!_0x1cb111['getCustomProperty']('footnotesDefinitions');}function g(_0x100ec9,_0x1dd386={}){const _0xb9449a=_0x100ec9['createEmptyElement']('hr',{'class':'footnotes-divider'}),_0x555d25=_0x100ec9['createContainerElement']('ol',{'class':'footnotes-list'},_0x100ec9['createSlot']());return _0x100ec9['createContainerElement']('div',{'class':'footnotes',..._0x1dd386},[_0xb9449a,_0x555d25]);}function D(_0x1c1778,_0x5f34da){const _0x2d0007=_0x1c1778['getAttribute']('footnoteId'),_0x17ac57=_0x1c1778['getAttribute']('footnoteCounter'),_0xa46dc8=_0x5f34da['createUIElement']('a',{'href':'#'+_0x2d0007},function(_0x4ffe54){const _0x452219=this['toDomElement'](_0x4ffe54);return _0x452219['textContent']=_0x17ac57,_0x452219;}),_0x2c4bb9=_0x5f34da['createContainerElement']('sup',{'id':'ref-'+_0x2d0007,'class':'footnote'},[_0xa46dc8]);return _0x2c4bb9['getFillerOffset']=()=>null,_0x2c4bb9;}function v(_0x10cd54,_0x420a49,_0x40a0af,{dataPipeline:_0x2c44e0}={}){const {t:t}=_0x40a0af,_0x1b31ce=_0x10cd54['getAttribute']('footnoteId'),_0x31599c=_0x420a49['createUIElement']('a',{'class':'footnote-backlink','href':'#ref-'+_0x1b31ce},function(_0xaeb26d){const _0x27a55c=this['toDomElement'](_0xaeb26d);return _0x27a55c['innerText']='^',_0x27a55c;}),_0x23f433=_0x2c44e0?_0x420a49['createContainerElement']('div',{'class':'footnote-content'}):_0x4a9e57(_0x420a49['createEditableElement']('div',{'class':'footnote-content'}),_0x420a49,{'label':t('Footnote\x20content.')});return _0x420a49['insert'](_0x420a49['createPositionAt'](_0x23f433,0x0),_0x420a49['createSlot']()),_0x420a49['createContainerElement']('li',{'class':'footnote-definition','id':_0x1b31ce},[_0x31599c,_0x23f433]);}
|
|
23
|
+
import{Plugin as _0x370733}from'ckeditor5/src/core.js';import{isWidget as _0x5c6ff7,toWidget as _0x3697f5,toWidgetEditable as _0x1a7095}from'ckeditor5/src/widget.js';import{uid as _0x22f426}from'ckeditor5/src/utils.js';import{PointerObserver as _0x5d03b0,ClickObserver as _0x57c99f}from'ckeditor5/src/engine.js';import{FootnotesTracker as _0x1ff412}from'./footnotestracker.js';import{InsertFootnoteCommand as _0x4f9786}from'./commands/insertfootnotecommand.js';export class FootnotesEditing extends _0x370733{static get['pluginName'](){return'FootnotesEditing';}static get['requires'](){return[_0x1ff412];}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['init'](){const {editor:_0x52857c}=this;_0x52857c['config']['define']('footnotes.multiBlock',!0x0),_0x52857c['commands']['add']('insertFootnote',new _0x4f9786(_0x52857c)),this['_defineSchema'](),this['_defineRefsConverters'](),this['_defineDefinitionsConverters'](),this['_defineDefinitionConverters'](),this['_defineBogusParagraphConverters'](),this['_defineKeyboardHandlers'](),this['_defineClickHandlers']();}['afterInit'](){!async function(_0x3c1f3e){const _0xf94c80=_0x324158([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]),_0x214046=0x47a28506,_0x37cd01=0x47a5fd0e^_0x214046,_0x190135=window[_0x324158([0x44,0x61,0x74,0x65])][_0x324158([0x6e,0x6f,0x77])](),_0x120a4d=_0x3c1f3e[_0x324158([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x91afac=new window[(_0x324158([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x4d59a6=>{_0x120a4d[_0x324158([0x6f,0x6e,0x63,0x65])](_0x324158([0x72,0x65,0x61,0x64,0x79]),_0x4d59a6);}),_0x22d629={[_0x324158([0x6b,0x74,0x79])]:_0x324158([0x45,0x43]),[_0x324158([0x75,0x73,0x65])]:_0x324158([0x73,0x69,0x67]),[_0x324158([0x63,0x72,0x76])]:_0x324158([0x50,0x2d,0x32,0x35,0x36]),[_0x324158([0x78])]:_0x324158([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]),[_0x324158([0x79])]:_0x324158([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]),[_0x324158([0x61,0x6c,0x67])]:_0x324158([0x45,0x53,0x32,0x35,0x36])},_0x34922f=_0x120a4d[_0x324158([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x324158([0x67,0x65,0x74])](_0x324158([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x54ec6f(){let _0x1c764,_0x37856d=null,_0x4d375f=null;try{if(_0x34922f==_0x324158([0x47,0x50,0x4c]))return _0x324158([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x1c764=_0x1f0f99(),!_0x1c764)return _0x324158([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x1c764[_0x324158([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x4d375f=_0x24cf12(_0x1c764[_0x324158([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x1c764[_0x324158([0x6a,0x74,0x69])])),await _0xd91870()?_0x45bd1b()?_0x596615()?_0x324158([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x3caef7()?(_0x1c764[_0x324158([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x324158([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x37856d=_0x22bd9d(_0x324158([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x1c764[_0x324158([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x324158([0x74,0x72,0x69,0x61,0x6c])&&(_0x37856d=_0x22bd9d(_0x324158([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),await _0x3fed44()):_0x324158([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x324158([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x324158([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch{return _0x324158([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x596615(){const _0x3b1ae6=[_0x324158([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x324158([0x74,0x72,0x69,0x61,0x6c])][_0x324158([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x1c764[_0x324158([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x190135/0x3e8:0xe10*_0x37cd01;return _0x1c764[_0x324158([0x65,0x78,0x70])]<_0x3b1ae6;}function _0x45bd1b(){const _0x461dfa=_0x1c764[_0x324158([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];return!!_0x461dfa&&(!!_0x461dfa[_0x324158([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x324158([0x2a]))||!!_0x461dfa[_0x324158([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x324158([0x46,0x4f,0x4f])));}function _0x3caef7(){const _0x5e916f=_0x1c764[_0x324158([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x5e916f||0x0==_0x5e916f[_0x324158([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x8a10e7}=new URL(window[_0x324158([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x5e916f[_0x324158([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x8a10e7))return!0x0;const _0x45c6a9=_0x8a10e7[_0x324158([0x73,0x70,0x6c,0x69,0x74])](_0x324158([0x2e]));return _0x5e916f[_0x324158([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x244cd1=>_0x244cd1[_0x324158([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x324158([0x2a])))[_0x324158([0x6d,0x61,0x70])](_0x5e7ee9=>_0x5e7ee9[_0x324158([0x73,0x70,0x6c,0x69,0x74])](_0x324158([0x2e])))[_0x324158([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x2acdfb=>_0x2acdfb[_0x324158([0x6c,0x65,0x6e,0x67,0x74,0x68])]<=_0x45c6a9[_0x324158([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x324158([0x6d,0x61,0x70])](_0x1e8962=>Array(_0x45c6a9[_0x324158([0x6c,0x65,0x6e,0x67,0x74,0x68])]-_0x1e8962[_0x324158([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x324158([0x66,0x69,0x6c,0x6c])](_0x1e8962[0x0]===_0x324158([0x2a])?_0x324158([0x2a]):'')[_0x324158([0x63,0x6f,0x6e,0x63,0x61,0x74])](_0x1e8962))[_0x324158([0x73,0x6f,0x6d,0x65])](_0x394964=>_0x45c6a9[_0x324158([0x65,0x76,0x65,0x72,0x79])]((_0x29959a,_0x2eae3b)=>_0x394964[_0x2eae3b]===_0x29959a||_0x394964[_0x2eae3b]===_0x324158([0x2a])));}function _0x3fed44(){return _0x37856d&&_0x4d375f?new window[(_0x324158([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x4cff37,_0x4b675f)=>{_0x37856d[_0x324158([0x74,0x68,0x65,0x6e])](_0x4cff37,_0x4b675f),_0x4d375f[_0x324158([0x74,0x68,0x65,0x6e])](_0x327b9a=>{_0x327b9a!=_0x324158([0x56,0x61,0x6c,0x69,0x64])&&_0x4cff37(_0x327b9a);},_0x4b675f);}):_0x37856d||_0x4d375f||_0x324158([0x56,0x61,0x6c,0x69,0x64]);}}function _0x24cf12(_0x2f3656,_0x22a0e5){return new window[(_0x324158([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x255203=>{if(_0xfcb2ef())return _0x255203(_0x324158([0x56,0x61,0x6c,0x69,0x64]));_0x3418ca(),_0x120a4d[_0x324158([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x324158([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x31064f=!0x1;const _0x5ba893=_0x22f426();function _0x115f9b(_0x8bd8ac){return!!_0x8bd8ac&&(typeof _0x8bd8ac===_0x324158([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x8bd8ac===_0x324158([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x8bd8ac[_0x324158([0x74,0x68,0x65,0x6e])]===_0x324158([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x8bd8ac[_0x324158([0x63,0x61,0x74,0x63,0x68])]===_0x324158([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x4f5031(_0x32bd3c){_0x5e83f5(_0x32bd3c)[_0x324158([0x74,0x68,0x65,0x6e])](_0x26fecd=>{if(!_0x26fecd||_0x26fecd[_0x324158([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x324158([0x6f,0x6b]))return _0x324158([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x3c826f(_0x53beaa(_0x5ba893+_0x22a0e5))!=_0x26fecd[_0x324158([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x324158([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x324158([0x56,0x61,0x6c,0x69,0x64]);})[_0x324158([0x74,0x68,0x65,0x6e])](_0x56d1e6=>(_0x50733f(),_0x56d1e6),()=>{const _0xcca71=_0x4624a0();return null==_0xcca71?(_0x50733f(),_0x324158([0x56,0x61,0x6c,0x69,0x64])):_0x324158(_0x190135-_0xcca71>(0x63ae0106^_0x214046)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x324158([0x74,0x68,0x65,0x6e])](_0x255203)[_0x324158([0x63,0x61,0x74,0x63,0x68])](()=>{_0x255203(_0x324158([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x13e105=0x47946b86^_0x214046;function _0x50733f(){const _0x825598=_0x324158([0x6c,0x6c,0x63,0x74,0x2d])+_0x3c826f(_0x53beaa(_0x2f3656)),_0x24acb4=_0x4ffd7c(_0x3c826f(window[_0x324158([0x4d,0x61,0x74,0x68])][_0x324158([0x63,0x65,0x69,0x6c])](_0x190135/_0x13e105)));window[_0x324158([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x324158([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x825598,_0x24acb4);}function _0x4624a0(){const _0x4cd0c7=_0x324158([0x6c,0x6c,0x63,0x74,0x2d])+_0x3c826f(_0x53beaa(_0x2f3656)),_0x2fefb6=window[_0x324158([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x324158([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x4cd0c7);return _0x2fefb6?window[_0x324158([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x4ffd7c(_0x2fefb6),0x10)*_0x13e105:null;}function _0x5e83f5(_0x861e12){return new window[(_0x324158([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x212d0d,_0x5288be)=>{_0x861e12[_0x324158([0x74,0x68,0x65,0x6e])](_0x212d0d,_0x5288be),window[_0x324158([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x5288be,0x47a351c6^_0x214046);});}}_0x120a4d[_0x324158([0x6f,0x6e])](_0x324158([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x1fcbef,_0x357019)=>{if(_0x357019[0x0]!=_0x2f3656)return _0x255203(_0x324158([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x357019[0x1]={..._0x357019[0x1],[_0x324158([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x5ba893};},{[_0x324158([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x324158([0x68,0x69,0x67,0x68])}),_0x120a4d[_0x324158([0x6f,0x6e])](_0x324158([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x23e353=>{_0x115f9b(_0x23e353[_0x324158([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x31064f=!0x0,_0x4f5031(_0x23e353[_0x324158([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x324158([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x324158([0x6c,0x6f,0x77])}),_0x91afac[_0x324158([0x74,0x68,0x65,0x6e])](()=>{_0x31064f||_0x255203(_0x324158([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0xfcb2ef(){return _0x120a4d[_0x324158([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x324158([0x76,0x69,0x65,0x77])][_0x324158([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x324158([0x61,0x75,0x74,0x6f]);}function _0x3418ca(){_0x120a4d[_0x324158([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x324158([0x76,0x69,0x65,0x77])][_0x324158([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x324158([0x61,0x75,0x74,0x6f]);}}function _0x22bd9d(_0x3bd85f){const _0x47d5e1=[new window[(_0x324158([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x893830=>setTimeout(_0x893830,0x47abbbca^_0x214046)),_0x91afac[_0x324158([0x74,0x68,0x65,0x6e])](()=>new window[(_0x324158([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x53baa9=>{let _0x34b422=0x0;_0x120a4d[_0x324158([0x6d,0x6f,0x64,0x65,0x6c])][_0x324158([0x6f,0x6e])](_0x324158([0x61,0x70,0x70,0x6c,0x79,0x4f,0x70,0x65,0x72,0x61,0x74,0x69,0x6f,0x6e]),(_0x46630a,_0xf39e81)=>{_0xf39e81[0x0][_0x324158([0x69,0x73,0x44,0x6f,0x63,0x75,0x6d,0x65,0x6e,0x74,0x4f,0x70,0x65,0x72,0x61,0x74,0x69,0x6f,0x6e])]&&_0x34b422++,_0x34b422==(0x47a284fe^_0x214046)&&(_0x53baa9(),_0x46630a[_0x324158([0x6f,0x66,0x66])]());});}))];return window[_0x324158([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x324158([0x72,0x61,0x63,0x65])](_0x47d5e1)[_0x324158([0x74,0x68,0x65,0x6e])](()=>_0x3bd85f);}async function _0x58ca8d(){await _0x91afac,_0x120a4d[_0x324158([0x6d,0x6f,0x64,0x65,0x6c])][_0x324158([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x1fd96a,_0x120a4d[_0x324158([0x6d,0x6f,0x64,0x65,0x6c])][_0x324158([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x1fd96a,_0x120a4d[_0x324158([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x324158([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x31188f(_0x1235cf){const _0x490f3b=_0x288f6c();_0x120a4d[_0x490f3b]=_0x324158([0x66,0x6f,0x6f,0x74,0x6e,0x6f,0x74,0x65,0x73,0x4c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79])+_0x1235cf,_0x1235cf!=_0x324158([0x56,0x61,0x6c,0x69,0x64])&&_0x58ca8d();}function _0x288f6c(){const _0x47728a=window[_0x324158([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x324158([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x324158([0x6e,0x6f,0x77])]())[_0x324158([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x324158([0x2e]),'');let _0x3d231e=_0x324158([0x75]);for(let _0x5b7108=0x0;_0x5b7108<_0x47728a[_0x324158([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x5b7108+=0x2){let _0xda896a=window[_0x324158([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x47728a[_0x324158([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x5b7108,_0x5b7108+0x2));_0xda896a>=_0xf94c80[_0x324158([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0xda896a-=_0xf94c80[_0x324158([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x3d231e+=_0xf94c80[_0xda896a];}return _0x3d231e;}function _0x1f0f99(){const _0x58f5fa=_0x34922f[_0x324158([0x73,0x70,0x6c,0x69,0x74])](_0x324158([0x2e]));if(0x3!=_0x58f5fa[_0x324158([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x1d4ccc(_0x58f5fa[0x1]);function _0x1d4ccc(_0x3f2fb2){const _0x411dbf=_0x1afef1(_0x3f2fb2);return _0x411dbf&&_0x1d9fdd()?_0x411dbf:null;function _0x1d9fdd(){const _0xed0174=_0x411dbf[_0x324158([0x6a,0x74,0x69])],_0x39b342=window[_0x324158([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0xed0174[_0x324158([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0xed0174[_0x324158([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x358a24={..._0x411dbf,[_0x324158([0x6a,0x74,0x69])]:_0xed0174[_0x324158([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0xed0174[_0x324158([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x358a24[_0x324158([0x76,0x63])],_0x53beaa(_0x358a24)==_0x39b342;}}}async function _0xd91870(){let _0x538edd=!0x0;try{const _0x1b36d7=_0x34922f[_0x324158([0x73,0x70,0x6c,0x69,0x74])](_0x324158([0x2e])),[_0x263d47,_0x5b6815,_0x483610]=_0x1b36d7;return _0x145594(_0x263d47),await _0x9b3b55(_0x263d47,_0x5b6815,_0x483610),_0x538edd;}catch{return!0x1;}function _0x145594(_0x3a2f22){const _0x2c4bb0=_0x1afef1(_0x3a2f22);_0x2c4bb0&&_0x2c4bb0[_0x324158([0x61,0x6c,0x67])]==_0x324158([0x45,0x53,0x32,0x35,0x36])||(_0x538edd=!0x1);}async function _0x9b3b55(_0x2058e6,_0x3f61d1,_0x2d2a6f){const _0x2b3c9b=window[_0x324158([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x324158([0x66,0x72,0x6f,0x6d])](_0x200935(_0x2d2a6f),_0x1a7161=>_0x1a7161[_0x324158([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x338680=new window[(_0x324158([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x324158([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x2058e6+_0x324158([0x2e])+_0x3f61d1),_0x5a7848=window[_0x324158([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x324158([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x5a7848)return;const _0x54185d=await _0x5a7848[_0x324158([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x324158([0x6a,0x77,0x6b]),_0x22d629,{[_0x324158([0x6e,0x61,0x6d,0x65])]:_0x324158([0x45,0x43,0x44,0x53,0x41]),[_0x324158([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x324158([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x324158([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x5a7848[_0x324158([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x324158([0x6e,0x61,0x6d,0x65])]:_0x324158([0x45,0x43,0x44,0x53,0x41]),[_0x324158([0x68,0x61,0x73,0x68])]:{[_0x324158([0x6e,0x61,0x6d,0x65])]:_0x324158([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x54185d,_0x2b3c9b,_0x338680)||(_0x538edd=!0x1);}}function _0x1afef1(_0x36a001){return _0x36a001[_0x324158([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x324158([0x65,0x79]))?JSON[_0x324158([0x70,0x61,0x72,0x73,0x65])](_0x200935(_0x36a001)):null;}function _0x200935(_0x1771d2){return window[_0x324158([0x61,0x74,0x6f,0x62])](_0x1771d2[_0x324158([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x324158([0x2b]))[_0x324158([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x324158([0x2f])));}function _0x53beaa(_0x29cede){let _0x107d0b=0x1505;function _0x1aeb08(_0x1e8b7a){for(let _0x19dd85=0x0;_0x19dd85<_0x1e8b7a[_0x324158([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x19dd85++){const _0x4e9e1e=_0x1e8b7a[_0x324158([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x19dd85);_0x107d0b=(_0x107d0b<<0x5)+_0x107d0b+_0x4e9e1e,_0x107d0b&=_0x107d0b;}}function _0x31302c(_0x1b6b78){Array[_0x324158([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x1b6b78)?_0x1b6b78[_0x324158([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x31302c):_0x1b6b78&&typeof _0x1b6b78==_0x324158([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x324158([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x1b6b78)[_0x324158([0x73,0x6f,0x72,0x74])]()[_0x324158([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x35d077,_0x3e7c87])=>{_0x1aeb08(_0x35d077),_0x31302c(_0x3e7c87);}):_0x1aeb08(window[_0x324158([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x1b6b78));}return _0x31302c(_0x29cede),_0x107d0b>>>0x0;}function _0x3c826f(_0x52bcd2){return _0x52bcd2[_0x324158([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x324158([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x324158([0x30]));}function _0x4ffd7c(_0x35767f){return _0x35767f[_0x324158([0x73,0x70,0x6c,0x69,0x74])]('')[_0x324158([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x324158([0x6a,0x6f,0x69,0x6e])]('');}function _0x1fd96a(){}function _0x324158(_0x1fbbbb){return _0x1fbbbb['map'](_0x5713cb=>String['fromCharCode'](_0x5713cb))['join']('');}_0x31188f(await _0x54ec6f());}(this);}['_moveSelectionToFootnoteDefinition'](_0x5e230a){const {plugins:_0x3eaf96,editing:_0xd601c0,model:_0x534226}=this['editor'],_0x29d150=_0x3eaf96['get'](_0x1ff412)['getFootnote'](_0x5e230a);return!!_0x29d150&&(_0x534226['change'](_0x15b3e5=>{_0x15b3e5['setSelection'](_0x15b3e5['createPositionAt'](_0x29d150['definition'],'end'));}),_0xd601c0['view']['scrollToTheSelection'](),!0x0);}['_moveSelectionToFootnoteReference'](_0x256da2){const {plugins:_0x471ad4,editing:_0x29eea2,model:_0x2cc4b5}=this['editor'],_0x265305=_0x471ad4['get'](_0x1ff412)['getFootnote'](_0x256da2);return!!_0x265305&&(_0x2cc4b5['change'](_0x2b3895=>{_0x2b3895['setSelection'](_0x265305['reference'],'on');}),_0x29eea2['view']['scrollToTheSelection'](),!0x0);}['_defineSchema'](){const {schema:_0xe3cb75}=this['editor']['model'],_0x49f29a=this['editor']['config']['get']('footnotes.multiBlock');_0xe3cb75['register']('footnoteRef',{'inheritAllFrom':'$inlineObject','allowAttributes':['footnoteId','footnoteCounter']}),_0xe3cb75['register']('footnotesDefinitions',{'inheritAllFrom':'$blockObject','allowChildren':['footnoteDefinition']}),_0xe3cb75['register']('footnoteDefinition',{'allowAttributes':['footnoteId'],'disallowAttributes':['listItemId'],'isLimit':!0x0}),_0x49f29a?_0xe3cb75['extend']('footnoteDefinition',{'allowContentOf':'$container'}):_0xe3cb75['register']('footnoteInlineContent',{'allowIn':'footnoteDefinition','allowContentOf':'$block','isLimit':!0x0}),_0xe3cb75['addChildCheck'](_0x30f137=>{for(const _0x55c22f of _0x30f137)if('footnoteDefinition'===_0x55c22f['name'])return!0x1;},'footnoteRef');}['_defineRefsConverters'](){const {editor:_0x56fce3}=this,{conversion:_0x53e5b0,editing:_0x556448}=_0x56fce3,{t:t}=_0x56fce3['locale'];_0x53e5b0['for']('upcast')['elementToElement']({'view':{'name':'sup','classes':'footnote'},'model':(_0x414311,{writer:_0x4160ca,consumable:_0x3dcdd4})=>{const _0x39cbe9=_0x414311['getChild'](0x0);if(!_0x39cbe9||!_0x39cbe9['is']('element','a'))return null;const _0x3a3246=_0x39cbe9['getAttribute']('href')||'';if(!_0x3a3246['startsWith']('#'))return null;const _0x27efff=_0x3a3246['replace'](/^#/,'');if(!_0x27efff)return null;_0x3dcdd4['consume'](_0x39cbe9,{'name':!0x0,'attributes':['href']});for(const {item:_0x1a39f5}of _0x556448['view']['createRangeIn'](_0x39cbe9))_0x1a39f5['is']('$textProxy')?_0x3dcdd4['consume'](_0x1a39f5['textNode'],{'name':!0x0}):_0x1a39f5['is']('element')&&_0x3dcdd4['consume'](_0x1a39f5,{'name':!0x0});return _0x4160ca['createElement']('footnoteRef',{'footnoteId':_0x27efff});}}),_0x53e5b0['for']('dataDowncast')['elementToElement']({'model':{'name':'footnoteRef','attributes':['footnoteId','footnoteCounter']},'view':(_0x356de5,{writer:_0x43ec04})=>D(_0x356de5,_0x43ec04)}),_0x53e5b0['for']('editingDowncast')['elementToElement']({'model':{'name':'footnoteRef','attributes':['footnoteId','footnoteCounter']},'view':(_0x33dd0d,{writer:_0x8b60fe})=>{const _0x42cf36=_0x33dd0d['getAttribute']('footnoteCounter');return _0x3697f5(D(_0x33dd0d,_0x8b60fe),_0x8b60fe,{'label':t('Footnote\x20%0.\x20Press\x20ENTER\x20to\x20jump\x20to\x20footnote\x20definition.',_0x42cf36)});}});}['_defineDefinitionsConverters'](){const {editor:_0x21bf98}=this,{t:t}=_0x21bf98['locale'],{conversion:_0x41e369}=_0x21bf98;_0x41e369['for']('upcast')['elementToElement']({'view':{'name':'div','classes':'footnotes'},'model':'footnotesDefinitions'}),_0x41e369['for']('upcast')['add'](_0x77ad2d=>{_0x77ad2d['on']('element:ol',(_0x3bab9a,_0x23bd4c,_0x1e0c0b)=>{const _0x4c05df=_0x23bd4c['viewItem'];if(!_0x4c05df['hasClass']('footnotes-list')||!_0x23bd4c['modelCursor']['parent']?.['is']('element','footnotesDefinitions'))return;if(!_0x1e0c0b['consumable']['consume'](_0x4c05df,{'name':!0x0,'classes':'footnotes-list'}))return;const {modelRange:_0x29e142,modelCursor:_0x518976}=_0x1e0c0b['convertChildren'](_0x23bd4c['viewItem'],_0x23bd4c['modelCursor']);_0x23bd4c['modelRange']=_0x29e142,_0x23bd4c['modelCursor']=_0x518976;}),_0x77ad2d['on']('element:hr',(_0x1c486d,_0x28c14d,_0x3bac76)=>{const _0x4c0108=_0x28c14d['viewItem'];_0x4c0108['hasClass']('footnotes-divider')&&_0x28c14d['modelCursor']['parent']?.['is']('element','footnotesDefinitions')&&_0x3bac76['consumable']['consume'](_0x4c0108,{'name':!0x0,'classes':'footnotes-divider'});});}),_0x41e369['for']('dataDowncast')['elementToStructure']({'model':'footnotesDefinitions','view':(_0x500c63,{writer:_0x3d2664})=>g(_0x3d2664)}),_0x41e369['for']('editingDowncast')['elementToStructure']({'model':'footnotesDefinitions','view':(_0x109639,{writer:_0x2dad7d})=>{const _0x2c2827=g(_0x2dad7d,{'data-footnotes-list-label':t('Footnotes')}),_0x2bf673=_0x3697f5(_0x2c2827,_0x2dad7d,{'hasSelectionHandle':!0x0,'label':t('Footnotes')});return _0x2dad7d['setCustomProperty']('footnotesDefinitions',!0x0,_0x2bf673),_0x2bf673;}});}['_defineDefinitionConverters'](){const {editor:_0x417427}=this,{conversion:_0x2c84b0,locale:_0x4bc9cc}=_0x417427,_0x45ebb7=_0x417427['config']['get']('footnotes.multiBlock');_0x2c84b0['for']('upcast')['add'](_0x40ef1b=>{_0x40ef1b['on']('element:li',(_0x47def6,_0x2cf723,_0x489ddf)=>{const _0x65398a=_0x2cf723['viewItem'];if(!_0x65398a['hasClass']('footnote-definition')||!_0x65398a['getAttribute']('id'))return;const _0x2e7abf=_0x65398a['parent'];if(!_0x2e7abf['is']('element','ol')||!_0x2e7abf['hasClass']('footnotes-list'))return;if(!_0x489ddf['consumable']['test'](_0x65398a,{'name':!0x0,'attributes':'id','classes':'footnote-definition'}))return;const _0x5b8a49=_0x489ddf['writer']['createElement']('footnoteDefinition',{'footnoteId':_0x65398a['getAttribute']('id')});if(!_0x489ddf['safeInsert'](_0x5b8a49,_0x2cf723['modelCursor']))return;_0x489ddf['consumable']['consume'](_0x65398a,{'name':!0x0,'attributes':'id','classes':'footnote-definition'});const _0x34974a=Array['from'](_0x65398a['getChildren']())['find'](_0x3f230f=>_0x3f230f['is']('element')&&_0x3f230f['hasClass']('footnote-content'));for(const _0x14749f of _0x65398a['getChildren']())_0x14749f['is']('element')&&(_0x489ddf['consumable']['consume'](_0x14749f,{'name':!0x0,'classes':'footnote-backlink','attributes':'href'}),_0x489ddf['consumable']['consume'](_0x14749f,{'name':!0x0,'classes':'footnote-content'}));if(_0x34974a){if(_0x45ebb7)_0x489ddf['convertChildren'](_0x34974a,_0x5b8a49);else{const _0x173fd0=_0x489ddf['writer']['createElement']('footnoteInlineContent');_0x489ddf['writer']['insert'](_0x173fd0,_0x5b8a49),_0x489ddf['convertChildren'](_0x34974a,_0x173fd0);}}_0x489ddf['updateConversionResult'](_0x5b8a49,_0x2cf723);});}),_0x2c84b0['for']('dataDowncast')['elementToStructure']({'model':{'name':'footnoteDefinition','attributes':['footnoteId']},'view':(_0x57527e,{writer:_0x500a75})=>v(_0x57527e,_0x500a75,_0x4bc9cc,{'dataPipeline':!0x0})}),_0x2c84b0['for']('editingDowncast')['elementToStructure']({'model':{'name':'footnoteDefinition','attributes':['footnoteId']},'view':(_0x3e8e22,{writer:_0x54a4c4})=>v(_0x3e8e22,_0x54a4c4,_0x4bc9cc)});}['_defineBogusParagraphConverters'](){const {editor:_0x2adfd8}=this,{conversion:_0x4aaf0f}=_0x2adfd8;_0x2adfd8['config']['get']('footnotes.multiBlock')?(_0x4aaf0f['for']('editingDowncast')['elementToElement']({'model':'paragraph','view':m(),'converterPriority':'high'}),_0x4aaf0f['for']('dataDowncast')['elementToElement']({'model':'paragraph','view':m({'dataPipeline':!0x0}),'converterPriority':'high'}),this['listenTo'](_0x2adfd8['model']['document'],'change:data',()=>{!function(_0x2d7afb,_0x4565f3){const _0x3727de=_0x2d7afb['document']['differ'],_0xd4995b=new Set();for(const _0x72287d of _0x3727de['getChanges']()){const _0x58af88='attribute'==_0x72287d['type']?_0x72287d['range']['start']['parent']:_0x72287d['position']['parent'];_0x58af88['is']('element','footnoteDefinition')&&_0xd4995b['add'](_0x58af88);}for(const _0xc1cc58 of _0xd4995b['values']()){const _0x348eed=Array['from'](_0xc1cc58['getChildren']())['filter'](_0x59573a=>p(_0x59573a,_0x4565f3['mapper']));for(const _0x480b87 of _0x348eed)_0x4565f3['reconvertItem'](_0x480b87);}}(_0x2adfd8['model'],_0x2adfd8['editing']);})):(_0x4aaf0f['for']('editingDowncast')['elementToElement']({'model':'footnoteInlineContent','view':m()}),_0x4aaf0f['for']('dataDowncast')['elementToElement']({'model':'footnoteInlineContent','view':(_0xd44651,{writer:_0x59bb5a})=>{const _0x12ff14=_0x59bb5a['createContainerElement']('span');return _0x59bb5a['setCustomProperty']('dataPipeline:transparentRendering',!0x0,_0x12ff14),_0x12ff14;}}));}['_defineKeyboardHandlers'](){const {editor:_0x419770}=this,{editing:_0x1de057,t:t}=_0x419770,_0x4c89f6=_0x419770['model']['document']['selection'];_0x419770['keystrokes']['set']('CTRL+Shift+D','insertFootnote'),_0x419770['accessibility']['addKeystrokeInfos']({'keystrokes':[{'label':t('Insert\x20footnote'),'keystroke':'Ctrl+Shift+D'}]}),this['listenTo'](_0x1de057['view']['document'],'enter',(_0x1bb257,_0x421946)=>{const _0x18c71b=function(_0x257cc8){const _0x3e0d62=_0x257cc8['getSelectedElement']();if(_0x3e0d62?.['is']('element','footnoteRef'))return _0x3e0d62;return null;}(_0x4c89f6);if(_0x18c71b){const _0x475cc7=_0x18c71b['getAttribute']('footnoteId');this['_moveSelectionToFootnoteDefinition'](_0x475cc7),_0x421946['preventDefault'](),_0x1bb257['stop']();}},{'context':_0x5c6ff7});}['_defineClickHandlers'](){const {editor:_0x2ffb99}=this,{editing:_0x3de9b4}=_0x2ffb99;_0x2ffb99['editing']['view']['addObserver'](_0x5d03b0),_0x2ffb99['editing']['view']['addObserver'](_0x57c99f);let _0x1812cb=!0x1;this['listenTo'](_0x3de9b4['view']['document'],'pointerdown',(_0x4ea6f6,_0x41b841)=>{const {target:_0x38722e}=_0x41b841,_0x42fde1=_0x3de9b4['view']['document']['selection'];_0x1812cb=!!(_0x38722e['is']('element','a')&&_0x38722e['parent']?.['is']('element','sup')&&_0x38722e['parent']['hasClass']('footnote'))&&_0x42fde1['getSelectedElement']()===_0x38722e['parent'];},{'priority':'high'}),this['listenTo'](_0x3de9b4['view']['document'],'click',(_0x1cb8f4,_0x124b94)=>{const {target:_0x5b3936}=_0x124b94;if(!_0x5b3936['is']('element','a'))return;if(_0x5b3936['parent']?.['is']('element','sup')&&_0x5b3936['parent']['hasClass']('footnote')&&!_0x1812cb)return void _0x124b94['preventDefault']();let _0x59b916=_0x5b3936['getAttribute']('href');if(!_0x59b916?.['startsWith']('#'))return;_0x59b916=_0x59b916['slice'](0x1);let _0x584286=!0x1;(_0x59b916['startsWith']('ref-')&&this['_moveSelectionToFootnoteReference'](_0x59b916['slice'](0x4))||this['_moveSelectionToFootnoteDefinition'](_0x59b916))&&(_0x584286=!0x0),_0x584286&&(_0x124b94['preventDefault'](),_0x1cb8f4['stop']());},{'priority':'high','context':'$capture'});}}function m({dataPipeline:_0x1725b8}={}){return(_0xe02696,{writer:_0x5ba04d})=>{if(!h(_0xe02696))return null;if(!_0x1725b8)return _0x5ba04d['createContainerElement']('span',{'class':'ck-footnote-bogus-paragraph'});const _0x48f464=_0x5ba04d['createContainerElement']('p');return _0x5ba04d['setCustomProperty']('dataPipeline:transparentRendering',!0x0,_0x48f464),_0x48f464;};}function h(_0x14698b){const {parent:_0x11d79a}=_0x14698b;if(!_0x11d79a?.['is']('element','footnoteDefinition'))return!0x1;if(0x1!=_0x11d79a['childCount'])return!0x1;for(const _0x33a8ee of _0x14698b['getAttributeKeys']())if(!_0x33a8ee['startsWith']('selection:')&&'htmlEmptyBlock'!=_0x33a8ee)return!0x1;return!0x0;}function p(_0x2ac117,_0x477164){if(!_0x2ac117['is']('element','paragraph'))return!0x1;const _0x6cd3f5=_0x477164['toViewElement'](_0x2ac117);return!!_0x6cd3f5&&h(_0x2ac117)!==_0x6cd3f5['is']('element','span');}export function isFootnotesDefinitionsWidget(_0x5d2043){return _0x5c6ff7(_0x5d2043)&&_0x5d2043['is']('containerElement')&&!!_0x5d2043['getCustomProperty']('footnotesDefinitions');}function g(_0x18c810,_0x17a200={}){const _0x7a547c=_0x18c810['createEmptyElement']('hr',{'class':'footnotes-divider'}),_0x55240b=_0x18c810['createContainerElement']('ol',{'class':'footnotes-list'},_0x18c810['createSlot']());return _0x18c810['createContainerElement']('div',{'class':'footnotes',..._0x17a200},[_0x7a547c,_0x55240b]);}function D(_0x3cb16f,_0x2cb27b){const _0x156ba4=_0x3cb16f['getAttribute']('footnoteId'),_0x22fdbd=_0x3cb16f['getAttribute']('footnoteCounter'),_0x5e04f8=_0x2cb27b['createUIElement']('a',{'href':'#'+_0x156ba4},function(_0xc8c7b6){const _0xd7cb58=this['toDomElement'](_0xc8c7b6);return _0xd7cb58['textContent']=_0x22fdbd,_0xd7cb58;}),_0x24243f=_0x2cb27b['createContainerElement']('sup',{'id':'ref-'+_0x156ba4,'class':'footnote'},[_0x5e04f8]);return _0x24243f['getFillerOffset']=()=>null,_0x24243f;}function v(_0x5d250e,_0xd2e345,_0xb24bbe,{dataPipeline:_0x24cbd0}={}){const {t:t}=_0xb24bbe,_0x788011=_0x5d250e['getAttribute']('footnoteId'),_0x1961f3=_0xd2e345['createUIElement']('a',{'class':'footnote-backlink','href':'#ref-'+_0x788011},function(_0x1c110a){const _0x274f18=this['toDomElement'](_0x1c110a);return _0x274f18['innerText']='^',_0x274f18;}),_0x2b7544=_0x24cbd0?_0xd2e345['createContainerElement']('div',{'class':'footnote-content'}):_0x1a7095(_0xd2e345['createEditableElement']('div',{'class':'footnote-content'}),_0xd2e345,{'label':t('Footnote\x20content.')});return _0xd2e345['insert'](_0xd2e345['createPositionAt'](_0x2b7544,0x0),_0xd2e345['createSlot']()),_0xd2e345['createContainerElement']('li',{'class':'footnote-definition','id':_0x788011},[_0x1961f3,_0x2b7544]);}
|