@ckeditor/ckeditor5-footnotes 0.0.0-internal-20251210.0 → 0.0.0-internal-20251211.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.
Files changed (164) hide show
  1. package/build/footnotes.js +1 -1
  2. package/dist/index.js +1 -1
  3. package/dist/translations/af.js +1 -1
  4. package/dist/translations/af.umd.js +1 -1
  5. package/dist/translations/ar.js +1 -1
  6. package/dist/translations/ar.umd.js +1 -1
  7. package/dist/translations/ast.js +1 -1
  8. package/dist/translations/ast.umd.js +1 -1
  9. package/dist/translations/az.js +1 -1
  10. package/dist/translations/az.umd.js +1 -1
  11. package/dist/translations/be.js +1 -1
  12. package/dist/translations/be.umd.js +1 -1
  13. package/dist/translations/bg.js +1 -1
  14. package/dist/translations/bg.umd.js +1 -1
  15. package/dist/translations/bn.js +1 -1
  16. package/dist/translations/bn.umd.js +1 -1
  17. package/dist/translations/bs.js +1 -1
  18. package/dist/translations/bs.umd.js +1 -1
  19. package/dist/translations/ca.js +1 -1
  20. package/dist/translations/ca.umd.js +1 -1
  21. package/dist/translations/cs.js +1 -1
  22. package/dist/translations/cs.umd.js +1 -1
  23. package/dist/translations/da.js +1 -1
  24. package/dist/translations/da.umd.js +1 -1
  25. package/dist/translations/de-ch.js +1 -1
  26. package/dist/translations/de-ch.umd.js +1 -1
  27. package/dist/translations/de.js +1 -1
  28. package/dist/translations/de.umd.js +1 -1
  29. package/dist/translations/el.js +1 -1
  30. package/dist/translations/el.umd.js +1 -1
  31. package/dist/translations/en-au.js +1 -1
  32. package/dist/translations/en-au.umd.js +1 -1
  33. package/dist/translations/en-gb.js +1 -1
  34. package/dist/translations/en-gb.umd.js +1 -1
  35. package/dist/translations/en.js +1 -1
  36. package/dist/translations/en.umd.js +1 -1
  37. package/dist/translations/eo.js +1 -1
  38. package/dist/translations/eo.umd.js +1 -1
  39. package/dist/translations/es-co.js +1 -1
  40. package/dist/translations/es-co.umd.js +1 -1
  41. package/dist/translations/es.js +1 -1
  42. package/dist/translations/es.umd.js +1 -1
  43. package/dist/translations/et.js +1 -1
  44. package/dist/translations/et.umd.js +1 -1
  45. package/dist/translations/eu.js +1 -1
  46. package/dist/translations/eu.umd.js +1 -1
  47. package/dist/translations/fa.js +1 -1
  48. package/dist/translations/fa.umd.js +1 -1
  49. package/dist/translations/fi.js +1 -1
  50. package/dist/translations/fi.umd.js +1 -1
  51. package/dist/translations/fr.js +1 -1
  52. package/dist/translations/fr.umd.js +1 -1
  53. package/dist/translations/gl.js +1 -1
  54. package/dist/translations/gl.umd.js +1 -1
  55. package/dist/translations/gu.js +1 -1
  56. package/dist/translations/gu.umd.js +1 -1
  57. package/dist/translations/he.js +1 -1
  58. package/dist/translations/he.umd.js +1 -1
  59. package/dist/translations/hi.js +1 -1
  60. package/dist/translations/hi.umd.js +1 -1
  61. package/dist/translations/hr.js +1 -1
  62. package/dist/translations/hr.umd.js +1 -1
  63. package/dist/translations/hu.js +1 -1
  64. package/dist/translations/hu.umd.js +1 -1
  65. package/dist/translations/hy.js +1 -1
  66. package/dist/translations/hy.umd.js +1 -1
  67. package/dist/translations/id.js +1 -1
  68. package/dist/translations/id.umd.js +1 -1
  69. package/dist/translations/it.js +1 -1
  70. package/dist/translations/it.umd.js +1 -1
  71. package/dist/translations/ja.js +1 -1
  72. package/dist/translations/ja.umd.js +1 -1
  73. package/dist/translations/jv.js +1 -1
  74. package/dist/translations/jv.umd.js +1 -1
  75. package/dist/translations/kk.js +1 -1
  76. package/dist/translations/kk.umd.js +1 -1
  77. package/dist/translations/km.js +1 -1
  78. package/dist/translations/km.umd.js +1 -1
  79. package/dist/translations/kn.js +1 -1
  80. package/dist/translations/kn.umd.js +1 -1
  81. package/dist/translations/ko.js +1 -1
  82. package/dist/translations/ko.umd.js +1 -1
  83. package/dist/translations/ku.js +1 -1
  84. package/dist/translations/ku.umd.js +1 -1
  85. package/dist/translations/lt.js +1 -1
  86. package/dist/translations/lt.umd.js +1 -1
  87. package/dist/translations/lv.js +1 -1
  88. package/dist/translations/lv.umd.js +1 -1
  89. package/dist/translations/ms.js +1 -1
  90. package/dist/translations/ms.umd.js +1 -1
  91. package/dist/translations/nb.js +1 -1
  92. package/dist/translations/nb.umd.js +1 -1
  93. package/dist/translations/ne.js +1 -1
  94. package/dist/translations/ne.umd.js +1 -1
  95. package/dist/translations/nl.js +1 -1
  96. package/dist/translations/nl.umd.js +1 -1
  97. package/dist/translations/no.js +1 -1
  98. package/dist/translations/no.umd.js +1 -1
  99. package/dist/translations/oc.js +1 -1
  100. package/dist/translations/oc.umd.js +1 -1
  101. package/dist/translations/pl.js +1 -1
  102. package/dist/translations/pl.umd.js +1 -1
  103. package/dist/translations/pt-br.js +1 -1
  104. package/dist/translations/pt-br.umd.js +1 -1
  105. package/dist/translations/pt.js +1 -1
  106. package/dist/translations/pt.umd.js +1 -1
  107. package/dist/translations/ro.js +1 -1
  108. package/dist/translations/ro.umd.js +1 -1
  109. package/dist/translations/ru.js +1 -1
  110. package/dist/translations/ru.umd.js +1 -1
  111. package/dist/translations/si.js +1 -1
  112. package/dist/translations/si.umd.js +1 -1
  113. package/dist/translations/sk.js +1 -1
  114. package/dist/translations/sk.umd.js +1 -1
  115. package/dist/translations/sl.js +1 -1
  116. package/dist/translations/sl.umd.js +1 -1
  117. package/dist/translations/sq.js +1 -1
  118. package/dist/translations/sq.umd.js +1 -1
  119. package/dist/translations/sr-latn.js +1 -1
  120. package/dist/translations/sr-latn.umd.js +1 -1
  121. package/dist/translations/sr.js +1 -1
  122. package/dist/translations/sr.umd.js +1 -1
  123. package/dist/translations/sv.js +1 -1
  124. package/dist/translations/sv.umd.js +1 -1
  125. package/dist/translations/th.js +1 -1
  126. package/dist/translations/th.umd.js +1 -1
  127. package/dist/translations/ti.js +1 -1
  128. package/dist/translations/ti.umd.js +1 -1
  129. package/dist/translations/tk.js +1 -1
  130. package/dist/translations/tk.umd.js +1 -1
  131. package/dist/translations/tr.js +1 -1
  132. package/dist/translations/tr.umd.js +1 -1
  133. package/dist/translations/tt.js +1 -1
  134. package/dist/translations/tt.umd.js +1 -1
  135. package/dist/translations/ug.js +1 -1
  136. package/dist/translations/ug.umd.js +1 -1
  137. package/dist/translations/uk.js +1 -1
  138. package/dist/translations/uk.umd.js +1 -1
  139. package/dist/translations/ur.js +1 -1
  140. package/dist/translations/ur.umd.js +1 -1
  141. package/dist/translations/uz.js +1 -1
  142. package/dist/translations/uz.umd.js +1 -1
  143. package/dist/translations/vi.js +1 -1
  144. package/dist/translations/vi.umd.js +1 -1
  145. package/dist/translations/zh-cn.js +1 -1
  146. package/dist/translations/zh-cn.umd.js +1 -1
  147. package/dist/translations/zh.js +1 -1
  148. package/dist/translations/zh.umd.js +1 -1
  149. package/package.json +9 -9
  150. package/src/commands/insertfootnotecommand.js +1 -1
  151. package/src/footnotes.js +1 -1
  152. package/src/footnotesclipboard.js +1 -1
  153. package/src/footnotesediting.js +1 -1
  154. package/src/footnotesproperties/commands/footnotesstartcommand.js +1 -1
  155. package/src/footnotesproperties/commands/footnotesstylecommand.js +1 -1
  156. package/src/footnotesproperties/footnotespropertiesconfig.js +1 -1
  157. package/src/footnotesproperties/footnotespropertiesediting.js +1 -1
  158. package/src/footnotesproperties/footnotespropertiesui.js +1 -1
  159. package/src/footnotesproperties/ui/footnotesdefinitionspropertiesview.js +1 -1
  160. package/src/footnotesproperties.js +1 -1
  161. package/src/footnotestracker.js +1 -1
  162. package/src/footnotesui.js +1 -1
  163. package/src/index.js +1 -1
  164. package/src/modelelementtracker.js +1 -1
@@ -2,4 +2,4 @@
2
2
  /*!
3
3
  * @license Copyright (c) 2003-2025, CKSource Holding sp. z o.o. All rights reserved.
4
4
  * For licensing, see LICENSE.md.
5
- */(()=>{var t={102:t=>{"use strict";var e={};t.exports=function(t,o){var n=function(t){if(void 0===e[t]){var o=document.querySelector(t);if(window.HTMLIFrameElement&&o instanceof window.HTMLIFrameElement)try{o=o.contentDocument.head}catch(t){o=null}e[t]=o}return e[t]}(t);if(!n)throw new Error("Couldn't find a style target. This probably means that the value for the 'insert' parameter is invalid.");n.appendChild(o)}},106:t=>{"use strict";t.exports=function(t){return t[1]}},123:t=>{"use strict";t.exports=function(t,e){Object.keys(e).forEach(function(o){t.setAttribute(o,e[o])})}},237:t=>{"use strict";t.exports=CKEditor5.dll},291:(t,e,o)=>{"use strict";o.d(e,{A:()=>a});var n=o(106),i=o.n(n),s=o(779),r=o.n(s)()(i());r.push([t.id,":root{--ck-footnotes-styles-list-style-button-size:44px}.ck.ck-footnotes-definitions-properties>.ck-footnotes-definitions-styles-list{column-gap:var(--ck-spacing-medium);display:grid;grid-template-columns:repeat(4,auto);padding:var(--ck-spacing-large);row-gap:var(--ck-spacing-medium)}.ck.ck-footnotes-definitions-properties>.ck-footnotes-definitions-styles-list .ck-button{box-sizing:content-box;margin:0;padding:0}.ck.ck-footnotes-definitions-properties>.ck-footnotes-definitions-styles-list .ck-button,.ck.ck-footnotes-definitions-properties>.ck-footnotes-definitions-styles-list .ck-button .ck-icon{height:var(--ck-footnotes-styles-list-style-button-size);width:var(--ck-footnotes-styles-list-style-button-size)}.ck.ck-footnotes-definitions-properties>.ck-collapsible{border-top:1px solid var(--ck-color-base-border)}.ck.ck-footnotes-definitions-properties>.ck-collapsible .ck-footnotes-definitions-properties__start-index .ck-input{min-width:100%}",""]);const a=r},297:t=>{"use strict";var e,o=(e=[],function(t,o){return e[t]=o,e.filter(Boolean).join("\n")});function n(t,e,n,i){var s;if(n)s="";else{s="",i.supports&&(s+="@supports (".concat(i.supports,") {")),i.media&&(s+="@media ".concat(i.media," {"));var r=void 0!==i.layer;r&&(s+="@layer".concat(i.layer.length>0?" ".concat(i.layer):""," {")),s+=i.css,r&&(s+="}"),i.media&&(s+="}"),i.supports&&(s+="}")}if(t.styleSheet)t.styleSheet.cssText=o(e,s);else{var a=document.createTextNode(s),c=t.childNodes;c[e]&&t.removeChild(c[e]),c.length?t.insertBefore(a,c[e]):t.appendChild(a)}}var i={singleton:null,singletonCounter:0};t.exports=function(t){if("undefined"==typeof document)return{update:function(){},remove:function(){}};var e=i.singletonCounter++,o=i.singleton||(i.singleton=t.insertStyleElement(t));return{update:function(t){n(o,e,!1,t)},remove:function(t){n(o,e,!0,t)}}}},311:(t,e,o)=>{t.exports=o(237)("./src/ui.js")},331:(t,e,o)=>{t.exports=o(237)("./src/clipboard.js")},355:(t,e,o)=>{t.exports=o(237)("./src/icons.js")},584:(t,e,o)=>{t.exports=o(237)("./src/utils.js")},728:(t,e,o)=>{"use strict";o.d(e,{A:()=>a});var n=o(106),i=o.n(n),s=o(779),r=o.n(s)()(i());r.push([t.id,":root{--ck-content-footnotes-list-background-color:none;--ck-content-footnotes-list-separator-color:#000;--ck-content-footnote-font-size:var(--ck-content-font-size-small);--ck-footnotes-widget-label-background-color:#757575}.ck-content .footnote{margin-inline-end:.2em}.ck-content .footnotes{background-color:var(--ck-content-footnotes-list-background-color);font-size:var(--ck-content-footnote-font-size);margin:.9em 0 1.5em;position:relative}.ck-content .footnotes-divider{background:none;border:none;border-top:1px solid var(--ck-content-footnotes-list-separator-color);height:1px;margin:0 0 1em;width:min(30%,350px)}[dir=rtl] .ck-content .footnotes-divider{margin-left:auto;margin-right:0}.ck-content .footnotes-list{margin:0;padding-inline-start:3em}.ck-content .footnote-backlink{display:inline-block;margin-inline-end:1ch;user-select:none;vertical-align:top;width:auto}.ck-content .footnote-content{display:inline-block;padding:0 4px;vertical-align:top;width:calc(100% - 2em)}.ck-content .footnote-content>p:first-of-type{margin-top:0}.ck-content .footnote-content>p:last-of-type{margin-bottom:0}.ck-content .footnote-content ol{list-style-type:decimal}.ck-content .footnote-content ol ol{list-style-type:lower-latin}.ck-content .footnote-content ol ol ol{list-style-type:lower-roman}.ck-content .footnote-content ol ol ol ol{list-style-type:upper-latin}.ck-content .footnote-content ol ol ol ol ol{list-style-type:upper-roman}.ck.ck-editor__editable .footnotes.ck-widget{display:flow-root;margin:.9em 0 .85em;position:relative}.ck.ck-editor__editable .footnotes.ck-widget:not(:hover):not(.ck-widget_selected){outline:1px solid var(--ck-color-base-border)}.ck.ck-editor__editable .footnotes.ck-widget[data-footnotes-list-label]:after{background-color:var(--ck-footnotes-widget-label-background-color);color:#fff;content:attr(data-footnotes-list-label);font-family:var(--ck-font-face);font-size:10px;line-height:16px;padding:var(--ck-spacing-tiny) var(--ck-spacing-medium);position:absolute;right:10px;top:-1px;white-space:nowrap}[dir=rtl] .ck.ck-editor__editable .footnotes.ck-widget[data-footnotes-list-label]:after{left:10px;right:auto}.ck.ck-editor__editable .footnotes-divider{margin-top:0}.ck.ck-editor__editable .footnotes-list{margin-bottom:.65em;margin-top:0}",""]);const a=r},741:t=>{"use strict";t.exports=function(t){var e=document.createElement("style");return t.setAttributes(e,t.attributes),t.insert(e,t.options),e}},779:t=>{"use strict";t.exports=function(t){var e=[];return e.toString=function(){return this.map(function(e){var o="",n=void 0!==e[5];return e[4]&&(o+="@supports (".concat(e[4],") {")),e[2]&&(o+="@media ".concat(e[2]," {")),n&&(o+="@layer".concat(e[5].length>0?" ".concat(e[5]):""," {")),o+=t(e),n&&(o+="}"),e[2]&&(o+="}"),e[4]&&(o+="}"),o}).join("")},e.i=function(t,o,n,i,s){"string"==typeof t&&(t=[[null,t,void 0]]);var r={};if(n)for(var a=0;a<this.length;a++){var c=this[a][0];null!=c&&(r[c]=!0)}for(var l=0;l<t.length;l++){var f=[].concat(t[l]);n&&r[f[0]]||(void 0!==s&&(void 0===f[5]||(f[1]="@layer".concat(f[5].length>0?" ".concat(f[5]):""," {").concat(f[1],"}")),f[5]=s),o&&(f[2]?(f[1]="@media ".concat(f[2]," {").concat(f[1],"}"),f[2]=o):f[2]=o),i&&(f[4]?(f[1]="@supports (".concat(f[4],") {").concat(f[1],"}"),f[4]=i):f[4]="".concat(i)),e.push(f))}},e}},782:(t,e,o)=>{t.exports=o(237)("./src/core.js")},783:(t,e,o)=>{t.exports=o(237)("./src/engine.js")},901:(t,e,o)=>{t.exports=o(237)("./src/widget.js")},929:t=>{"use strict";var e=[];function o(t){for(var o=-1,n=0;n<e.length;n++)if(e[n].identifier===t){o=n;break}return o}function n(t,n){for(var s={},r=[],a=0;a<t.length;a++){var c=t[a],l=n.base?c[0]+n.base:c[0],f=s[l]||0,u="".concat(l," ").concat(f);s[l]=f+1;var d=o(u),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,n);n.byIndex=a,e.splice(a,0,{identifier:u,updater:h,references:1})}r.push(u)}return r}function i(t,e){var o=e.domAPI(e);o.update(t);return function(e){if(e){if(e.css===t.css&&e.media===t.media&&e.sourceMap===t.sourceMap&&e.supports===t.supports&&e.layer===t.layer)return;o.update(t=e)}else o.remove()}}t.exports=function(t,i){var s=n(t=t||[],i=i||{});return function(t){t=t||[];for(var r=0;r<s.length;r++){var a=o(s[r]);e[a].references--}for(var c=n(t,i),l=0;l<s.length;l++){var f=o(s[l]);0===e[f].references&&(e[f].updater(),e.splice(f,1))}s=c}}}},e={};function o(n){var i=e[n];if(void 0!==i)return i.exports;var s=e[n]={id:n,exports:{}};return t[n](s,s.exports,o),s.exports}o.n=t=>{var e=t&&t.__esModule?()=>t.default:()=>t;return o.d(e,{a:e}),e},o.d=(t,e)=>{for(var n in e)o.o(e,n)&&!o.o(t,n)&&Object.defineProperty(t,n,{enumerable:!0,get:e[n]})},o.o=(t,e)=>Object.prototype.hasOwnProperty.call(t,e),o.r=t=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})};var n={};(()=>{"use strict";o.r(n),o.d(n,{Footnotes:()=>G,FootnotesClipboard:()=>D,FootnotesEditing:()=>v,FootnotesProperties:()=>Et,FootnotesPropertiesEditing:()=>mt,FootnotesPropertiesUI:()=>Ct,FootnotesStartCommand:()=>ut,FootnotesStyleCommand:()=>at,FootnotesTracker:()=>d,FootnotesUI:()=>J,InsertFootnoteCommand:()=>b});var t=o(782),e=o(901),i=o(584),s=o(783);const r=c;!function(t){const e=c,o=t();for(;;)try{if(565892===-parseInt(e(153))/1+parseInt(e(156))/2*(-parseInt(e(137))/3)+-parseInt(e(128))/4*(-parseInt(e(142))/5)+-parseInt(e(126))/6*(parseInt(e(146))/7)+parseInt(e(151))/8+parseInt(e(130))/9*(parseInt(e(122))/10)+-parseInt(e(113))/11*(-parseInt(e(131))/12))break;o.push(o.shift())}catch(t){o.push(o.shift())}}(l);class a{[r(157)];[r(155)];[r(154)];[r(145)]=new Map;constructor(t,e){const o=r;this[o(157)]=t,this[o(155)]=e[o(119)],this[o(154)]=e[o(133)]}[r(135)](){const t=r;this[t(145)][t(138)]()}[r(144)](t){const e=r,o=new Set,n=new Map;for(const i of t){if(e(118)===i[e(125)]&&e(112)!==i[e(147)]&&i[e(117)][e(124)]){const t=this[e(157)][e(140)](i[e(117)][e(124)]);for(const o of t[e(123)]()){if(!o.is(e(150),this[e(155)]))continue;const t=this[e(154)](o);n[e(141)](t)||n[e(114)](t,[]),n[e(143)](t)[e(149)](o)}}if(e(127)===i[e(125)]&&i[e(147)]===this[e(155)]){const t=this[e(154)]({getAttribute:t=>i[e(116)][e(143)](t)});o[e(139)](t)}}for(const[t,n]of this[e(145)])e(129)===n[e(115)][e(120)]&&o[e(139)](t);for(const t of o)this[e(145)][e(152)](t);for(const[t,o]of n)this[e(145)][e(114)](t,o[o[e(148)]-1]);const i=new Set;for(const[t,s]of n)o[e(141)](t)&&(i[e(139)](s[0]),s[e(148)]>1?n[e(114)](t,s[e(136)](1)):n[e(152)](t),o[e(152)](t));return{removed:Array[e(132)](o),inserted:Array[e(132)](n[e(121)]())[e(134)](),moved:Array[e(132)](i)}}}function c(t,e){const o=l();return(c=function(t,e){return o[t-=112]})(t,e)}function l(){const t=["2090782iswEko","_model","$text","1133fAYrwA","set","root","attributes","position","insert","elementName","rootName","values","580lDprkO","getItems","nodeAfter","type","6AzbqPk","remove","956VffSAq","$graveyard","86571WvwdBL","131088XFgyuJ","from","getElementKey","flat","reset","slice","3nMjWEI","clear","add","createRangeOn","has","6680AwHTcq","get","getChanges","_trackedElements","1231363eAKqRI","name","length","push","element","5901776ekXCBT","delete","952908cJRASn","_getElementKey","_elementName"];return(l=function(){return t})()}const f=h;function u(){const t=["getRootNames","min","getFootnotesFormatter","some","document","isEqual","unshift","_footnoteDefsContainerTracker","differ","2538348EzNvuk","root","_footnoteFormatter","registerPostFixer","indexOf","setAttribute","model","getFootnotes","footnotes.multiBlock","findIndex","$graveyard","footnotesDefinitions","isPremiumPlugin","7XswcMR","move","from","footnoteDefinition","_updateFootnoteRefCounter","compareWith","reference","editor","createRangeOn","createElement","createPositionAt","_ensureFootnotesDefinitionsContainerExists","_handleFootnoteDefinitionsChanges","config","_updateFootnotesCounters","childCount","createRangeIn","parent","351AKNlkM","footnoteId","reset","footnoteRef","set","high","append","9315531eMijdq","FootnotesTracker","add","10wfOCXQ","_sortFootnoteDefinitions","_insertEmptyFootnotesDefinitionsContainer","getChildren","isOfficialPlugin","get","createPositionBefore","find","low","before","_handleInsertedFootnoteReference","_ensureFootnotesReferencesHaveProperOrder","singleton","footnoteInlineContent","getAttribute","setFootnoteFormatter","_footnoteDefsTracker","_handleFootnoteReferencesChanges","change:data","262931aalmMg","has","enqueueChange","init","getFootnote","33nbcusK","length","rootName","remove","splice","after","definition","32268OuKvqJ","pluginName","paragraph","getFootnotesDefinitionsObjectElement","13621136yUlgfD","push","insert","_handleMovedFootnoteReference","_footnotesDefinitions","footnoteCounter","172130jnaijg","_handleRemoveFootnoteReferenceById","map","end","6896190NtQrMt","getChanges","listenTo","_handleFootnotesDefinitionsObjectChanges","_handleFootnotesDefinitionsObjectSync","_footnotes","_footnoteRefsTracker"];return(u=function(){return t})()}!function(t){const e=h,o=t();for(;;)try{if(866578===-parseInt(e(301))/1*(parseInt(e(282))/2)+-parseInt(e(272))/3*(parseInt(e(313))/4)+-parseInt(e(323))/5+parseInt(e(241))/6+parseInt(e(254))/7*(parseInt(e(317))/8)+-parseInt(e(279))/9+parseInt(e(327))/10*(parseInt(e(306))/11))break;o.push(o.shift())}catch(t){o.push(o.shift())}}(u);class d extends t.Plugin{[f(332)]=[];[f(321)]=null;[f(243)]=null;[f(239)];[f(333)];[f(298)];static get[f(314)](){return f(280)}static get[f(286)](){return!0}static get[f(253)](){return!0}constructor(t){const e=f;super(t),this[e(239)]=new a(this[e(261)][e(247)],{elementName:e(252),getElementKey:()=>e(294)}),this[e(333)]=new a(this[e(261)][e(247)],{elementName:e(275),getElementKey:t=>t[e(296)](e(273))}),this[e(298)]=new a(this[e(261)][e(247)],{elementName:e(257),getElementKey:t=>t[e(296)](e(273))})}[f(304)](){const t=f,{editor:e}=this,{model:o,data:n}=e;o[t(236)][t(244)](e=>{const n=t,i=o[n(236)][n(240)][n(328)]();let s=!1;return this[n(330)](e,i)&&(s=!0),this[n(266)](e,i)&&(s=!0),this[n(299)](e,i)&&(s=!0),this[n(293)](e)&&(s=!0),this[n(331)](e)&&(s=!0),this[n(283)](e)&&(s=!0),s}),this[t(329)](o[t(236)],t(300),()=>{const e=t;o[e(303)]({isUndoable:!1},t=>{this[e(265)](t)})},{priority:t(290)}),this[t(329)](n,t(276),()=>{const e=t;this[e(332)]=[],this[e(239)][e(274)](),this[e(333)][e(274)](),this[e(298)][e(274)]()},{priority:t(277)})}[f(316)](){return this[f(321)]}[f(305)](t){const e=f;return this[e(332)][e(289)](e=>e.id===t)||null}[f(248)](){const t=f;return Array[t(256)](this[t(332)])}[f(336)](){return this[f(243)]}[f(297)](t){this[f(243)]=t}[f(268)](t,e=0){const o=f;let n=!1;for(let i=e;i<this[o(332)][o(307)];i++)this[o(258)](t,i)&&(n=!0);return n}[f(284)](t,e){const o=f,n=t[o(263)](o(252),{});return t[o(278)](n,e),this[o(321)]=n,n}[f(265)](t){const e=f;if(!this[e(332)][e(307)]||this[e(321)])return;const o=this[e(332)][0][e(260)][e(242)],n=this[e(284)](t,o);for(const o of this[e(332)])o[e(312)][e(271)]||t[e(319)](o[e(312)],n,e(326));this[e(268)](t)}[f(330)](t,e){const o=f;let n=!1;const{inserted:i,removed:s,moved:r}=this[o(239)][o(328)](e);if(r[o(307)]&&(this[o(321)]=r[0]),i[o(307)])if(i[o(307)]>1||this[o(321)]&&i[o(337)](t=>t!==this[o(321)])){const e=t[o(263)](o(252),{}),s=[];this[o(321)]&&s[o(318)](this[o(321)]),s[o(318)](...i),t[o(319)](e,s[0],o(291));for(const n of s)t[o(255)](t[o(270)](n),t[o(264)](e,o(326))),t[o(309)](n);this[o(321)]=e,this[o(268)](t),n=!0}else this[o(321)]=i[0];if(s[o(307)]&&o(251)===this[o(321)]?.[o(242)][o(308)]){for(const e of this[o(332)])t[o(309)](e[o(260)]),n=!0;this[o(332)]=[],this[o(321)]=null}return n}[f(266)](t,e){const o=f;let n=!1;const i=this[o(261)][o(267)][o(287)](o(249)),{inserted:s,moved:r}=this[o(298)][o(328)](e);for(const e of[...r,...s]){const s=e[o(296)](o(273)),r=this[o(305)](s);r&&(r[o(312)]=e),p(t,i,e)&&(n=!0)}return n}[f(299)](t,e){const o=f;let n=!1;const{removed:i,inserted:s,moved:r}=this[o(333)][o(328)](e);for(const e of i)this[o(324)](t,e)&&(n=!0);for(const e of s)this[o(292)](t,e)&&(n=!0);for(const e of r)this[o(320)](t,e)&&(n=!0);return n}[f(331)](t){const e=f;if(!this[e(321)])return!1;let o=!1;if(this[e(321)][e(269)]!==this[e(332)][e(307)]){const n=[];for(const t of this[e(321)][e(285)]()){const i=t[e(296)](e(273));this[e(305)](i)||(n[e(238)](t),o=!0)}for(const o of n)t[e(309)](o)}const n=new Set,i=[];for(const t of this[e(321)][e(285)]()){const s=t[e(296)](e(273));n[e(302)](s)?(i[e(238)](t),o=!0):n[e(281)](s)}for(const o of i)t[e(309)](o);return this[e(321)][e(269)]||(t[e(309)](this[e(321)]),this[e(321)]=null,o=!0),o}[f(292)](t,e){const o=f;if(this[o(332)][o(289)](t=>t[o(260)]===e))return!1;let n=!1;const i=e[o(296)](o(273)),s=this[o(332)][o(250)](t=>t.id===i);-1!==s&&(t[o(309)](this[o(332)][s][o(260)]),this[o(332)][o(310)](s,1),n=!0);let r=this[o(321)]?function(t,e){const n=o;for(const o of t[n(285)]())if(o[n(296)](n(273))===e)return o;return null}(this[o(321)],i):null;r||(r=t[o(263)](o(257),{footnoteId:i}),this[o(321)]&&(t[o(319)](r,this[o(321)],o(326)),n=!0));const a={id:i,reference:e,definition:r},c=m(this[o(261)][o(247)],this[o(332)],e);this[o(332)][o(310)](c,0,a);let l=c;return-1!==s&&(l=Math[o(335)](c,s)),this[o(268)](t,l)&&(n=!0),n}[f(324)](t,e){const o=f,n=this[o(332)][o(250)](t=>t.id===e);if(-1===n)return!1;let i=!1;const s=this[o(332)][n];return o(251)!==s[o(312)][o(242)][o(308)]&&(t[o(309)](s[o(312)]),i=!0),this[o(332)][o(310)](n,1),this[o(268)](t,n)&&(i=!0),i}[f(320)](t,e){const o=f,n=e[o(296)](o(273)),i=this[o(332)][o(250)](t=>t.id===n),s=this[o(332)][i];let r=!1;s[o(260)]=e,this[o(332)][o(310)](i,1);const a=m(this[o(261)][o(247)],this[o(332)],e);return this[o(332)][o(310)](a,0,s),this[o(268)](t,Math[o(335)](i,a))&&(r=!0),r}[f(258)](t,e){const o=f;if(!this[o(321)])return!1;const n=this[o(332)][e];let i;return i=this[o(243)]?this[o(243)]({footnote:n,container:this[o(321)],digits:String(this[o(332)][o(307)])[o(307)],value:e+1}):String(e+1),n[o(260)][o(296)](o(322))!=i&&(t[o(246)](o(322),i,n[o(260)]),!0)}[f(283)](t){const e=f;if(!this[e(321)]||this[e(332)][e(307)]<2)return!1;if(function(t,o){const n=e;if(t[n(307)]!==o[n(307)])return!1;for(let e=0;e<t[n(307)];e++)if(t[e]!==o[e])return!1;return!0}(this[e(332)][e(325)](t=>t.id),Array[e(256)](this[e(321)][e(285)]())[e(325)](t=>t[e(296)](e(273)))))return!1;let o=!1;for(let n=0;n<this[e(332)][e(307)];n++){const i=this[e(332)][n],s=t[e(288)](i[e(312)]),r=t[e(264)](this[e(321)],n);s[e(237)](r)||(t[e(255)](t[e(262)](i[e(312)]),r),o=!0)}return o}[f(293)](t){const e=f;if(!this[e(332)][e(307)])return!1;const{model:o}=this[e(261)];let n=!1;for(let i=0;i<this[e(332)][e(307)]-1;i++){const s=this[e(332)][i],r=this[e(332)][i+1],a=o[e(288)](s[e(260)]),c=o[e(288)](r[e(260)]);e(311)===a[e(259)](c)&&(this[e(320)](t,s[e(260)]),i=-1,n=!0)}return n}}function p(t,e,o){const n=f;if(o[n(269)])return!1;const i=n(e?315:295);return t[n(319)](t[n(263)](i),o),!0}function h(t,e){const o=u();return(h=function(t,e){return o[t-=236]})(t,e)}function m(t,e,o){const n=f;if(0===e[n(307)])return 0;const i=t[n(288)](o);for(let o=0;o<e[n(307)];o++){const s=e[o],r=t[n(288)](s[n(260)]);if(n(291)===i[n(259)](r))return o}const s=o[n(242)];let r=-1;for(let t=e[n(307)]-1;t>=0;t--)if(e[t][n(260)][n(242)]===s){r=t;break}if(-1!==r)return r+1;const a=t[n(236)][n(334)](),c=a[n(245)](s[n(308)]),l=a[c+1];if(l)for(let t=0;t<e[n(307)];t++)if(e[t][n(260)][n(242)][n(308)]===l)return t;return e[n(307)]}const g=w;function w(t,e){const o=y();return(w=function(t,e){return o[t-=266]})(t,e)}function y(){const t=["checkChild","4219605qIpdSV","20foOJvv","insert-footnote-command-executed-with-invalid-id","footnoteRef","186672SZIhTO","5399UdgEfL","5671540lXdsiu","_getPositionToInsertFootnote","length","140493DSYgeL","insertObject","refresh","isEnabled","string","test","FootnotesEditing","48zyRuRt","isObject","560XBbpRL","34552yekHae","selection","get","createElement","983210WDSpDx","change","editor","_moveSelectionToFootnoteDefinition","execute","document","model","end","getFirstRange","plugins","getItems","footnoteId","isBlock"];return(y=function(){return t})()}!function(t){const e=w,o=t();for(;;)try{if(320654===-parseInt(e(279))/1*(parseInt(e(290))/2)+parseInt(e(283))/3*(parseInt(e(275))/4)+-parseInt(e(297))/5+-parseInt(e(278))/6+parseInt(e(292))/7*(parseInt(e(293))/8)+-parseInt(e(274))/9+parseInt(e(280))/10)break;o.push(o.shift())}catch(t){o.push(o.shift())}}(y);class b extends t.Command{[g(285)](){const t=g,e=this[t(299)][t(266)][t(302)][t(294)],o=this[t(281)](e);this[t(286)]=!!o}[g(301)](t){const e=g,{editor:o}=this,{model:n}=o,{selection:s}=n[e(302)],r=this[e(281)](s);if(!r)return;const a=o[e(269)][e(295)](e(289)),c=t?.[e(271)]??(0,i.uid)();!function(t){const o=e;return o(287)==typeof t&&t[o(282)]>0&&!/\s/[o(288)](t)&&!/^\d/[o(288)](t)}(c)?(0,i.logWarning)(e(276)):(n[e(298)](t=>{const o=e,i=t[o(296)](o(277),{footnoteId:c});n[o(284)](i,r,null)}),a[e(300)](c))}[g(281)](t){const e=g,{model:o}=this[e(299)],{schema:n}=o,i=t[e(268)]();for(const t of i[e(270)]())if(n[e(272)](t)||n[e(291)](t))return null;const s=i[e(267)];return n[e(273)](s,e(277))?s:null}}class v extends t.Plugin{static get pluginName(){return"FootnotesEditing"}static get requires(){return[d]}static get isOfficialPlugin(){return!0}static get isPremiumPlugin(){return!0}init(){const{editor:t}=this;t.config.define("footnotes.multiBlock",!0),t.commands.add("insertFootnote",new b(t)),this._defineSchema(),this._defineRefsConverters(),this._defineDefinitionsConverters(),this._defineDefinitionConverters(),this._defineBogusParagraphConverters(),this._defineKeyboardHandlers(),this._defineClickHandlers()}afterInit(){!async function(t){const e=m([117,110,83,98,71,112,109,105,106,65,119,121,114,79,122,100,90,104,67,113,84,51,89,76,70,86,116,74,108,107,68,97,103,49,87,77,78,120,82,52,72,54,55,73,66,53,81,111,88,48,50,56,57,99,85,115,118,80,69,101,102,75]),o=window[m([68,97,116,101])][m([110,111,119])](),n=t[m([101,100,105,116,111,114])],s=new(window[m([80,114,111,109,105,115,101])])(t=>{n[m([111,110,99,101])](m([114,101,97,100,121]),t)}),r={[m([107,116,121])]:m([69,67]),[m([117,115,101])]:m([115,105,103]),[m([99,114,118])]:m([80,45,50,53,54]),[m([120])]:m([105,67,106,79,67,118,68,70,73,54,108,81,72,72,84,49,56,106,86,119,82,102,107,102,72,81,50,97,95,77,121,109,84,51,53,76,81,86,111,70,83,65,73]),[m([121])]:m([107,88,73,121,74,52,101,118,116,67,69,70,82,109,120,75,83,85,112,75,57,102,68,87,52,53,57,118,88,79,118,86,114,104,102,54,117,81,65,101,79,105,111]),[m([97,108,103])]:m([69,83,50,53,54])},a=n[m([99,111,110,102,105,103])][m([103,101,116])](m([108,105,99,101,110,115,101,75,101,121]));function c(t){const e=[new(window[m([80,114,111,109,105,115,101])])(t=>setTimeout(t,605900)),s[m([116,104,101,110])](()=>new(window[m([80,114,111,109,105,115,101])])(t=>{let e=0;n[m([109,111,100,101,108])][m([111,110])](m([97,112,112,108,121,79,112,101,114,97,116,105,111,110]),(o,n)=>{n[0][m([105,115,68,111,99,117,109,101,110,116,79,112,101,114,97,116,105,111,110])]&&e++,504==e&&(t(),o[m([111,102,102])]())})}))];return window[m([80,114,111,109,105,115,101])][m([114,97,99,101])](e)[m([116,104,101,110])](()=>t)}function l(t){return t[m([115,116,97,114,116,115,87,105,116,104])](m([101,121]))?JSON[m([112,97,114,115,101])](f(t)):null}function f(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 u(t){let e=5381;function o(t){for(let o=0;o<t[m([108,101,110,103,116,104])];o++){const n=t[m([99,104,97,114,67,111,100,101,65,116])](o);e=(e<<5)+e+n,e&=e}}return function t(e){Array[m([105,115,65,114,114,97,121])](e)?e[m([102,111,114,69,97,99,104])](t):e&&typeof e==m([111,98,106,101,99,116])?Object[m([101,110,116,114,105,101,115])](e)[m([115,111,114,116])]()[m([102,111,114,69,97,99,104])](([e,n])=>{o(e),t(n)}):o(window[m([83,116,114,105,110,103])](e))}(t),e>>>0}function d(t){return t[m([116,111,83,116,114,105,110,103])](16)[m([112,97,100,83,116,97,114,116])](8,m([48]))}function 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 o=function(){const t=window[m([83,116,114,105,110,103])](window[m([112,101,114,102,111,114,109,97,110,99,101])][m([110,111,119])]())[m([114,101,112,108,97,99,101])](m([46]),"");let o=m([117]);for(let n=0;n<t[m([108,101,110,103,116,104])];n+=2){let i=window[m([112,97,114,115,101,73,110,116])](t[m([115,117,98,115,116,114,105,110,103])](n,n+2));i>=e[m([108,101,110,103,116,104])]&&(i-=e[m([108,101,110,103,116,104])]),o+=e[i]}return o}();n[o]=m([102,111,111,116,110,111,116,101,115,76,105,99,101,110,115,101,75,101,121])+t,t!=m([86,97,108,105,100])&&async function(){await s,n[m([109,111,100,101,108])][m([99,104,97,110,103,101])]=h,n[m([109,111,100,101,108])][m([101,110,113,117,101,117,101,67,104,97,110,103,101])]=h,n[m([101,110,97,98,108,101,82,101,97,100,79,110,108,121,77,111,100,101])](m([109,111,100,101,108]))}()}(await async function(){let t,e=null,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&&o()?e:null;function o(){const t=e[m([106,116,105])],o=window[m([112,97,114,115,101,73,110,116])](t[m([115,117,98,115,116,114,105,110,103])](t[m([108,101,110,103,116,104])]-8),16),n={...e,[m([106,116,105])]:t[m([115,117,98,115,116,114,105,110,103])](0,t[m([108,101,110,103,116,104])]-8)};return delete n[m([118,99])],u(n)==o}}}(),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(),n[m([100,101,99,111,114,97,116,101])](m([95,115,101,110,100,85,115,97,103,101,82,101,113,117,101,115,116]));let l=!1;const f=(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(n){a(n)[m([116,104,101,110])](t=>t&&t[m([115,116,97,116,117,115])]==m([111,107])?d(u(f+e))!=t[m([118,101,114,105,102,105,99,97,116,105,111,110])]?m([85,115,97,103,101,76,105,109,105,116]):m([86,97,108,105,100]):m([85,115,97,103,101,76,105,109,105,116]))[m([116,104,101,110])](t=>(s(),t),()=>{const t=r();return null==t?(s(),m([86,97,108,105,100])):m(o-t>6048e5?[85,115,97,103,101,76,105,109,105,116]:[86,97,108,105,100])})[m([116,104,101,110])](c)[m([99,97,116,99,104])](()=>{c(m([85,115,97,103,101,76,105,109,105,116]))});const i=36e5;function s(){const e=m([108,108,99,116,45])+d(u(t)),n=p(d(window[m([77,97,116,104])][m([99,101,105,108])](o/i)));window[m([108,111,99,97,108,83,116,111,114,97,103,101])][m([115,101,116,73,116,101,109])](e,n)}function r(){const e=m([108,108,99,116,45])+d(u(t)),o=window[m([108,111,99,97,108,83,116,111,114,97,103,101])][m([103,101,116,73,116,101,109])](e);return o?window[m([112,97,114,115,101,73,110,116])](p(o),16)*i:null}function a(t){return new(window[m([80,114,111,109,105,115,101])])((e,o)=>{t[m([116,104,101,110])](e,o),window[m([115,101,116,84,105,109,101,111,117,116])](o,12e4)})}}n[m([111,110])](m([95,115,101,110,100,85,115,97,103,101,82,101,113,117,101,115,116]),(e,o)=>{if(o[0]!=t)return c(m([85,115,97,103,101,76,105,109,105,116]));o[1]={...o[1],[m([114,101,113,117,101,115,116,73,100])]:f}},{[m([112,114,105,111,114,105,116,121])]:m([104,105,103,104])}),n[m([111,110])](m([95,115,101,110,100,85,115,97,103,101,82,101,113,117,101,115,116]),t=>{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 n[m([101,100,105,116,105,110,103])][m([118,105,101,119])][m([95,111,118,101,114,108,97,121,77,111,100,101,72,105,110,116])]==m([97,117,116,111])}function a(){n[m([101,100,105,116,105,110,103])][m([118,105,101,119])][m([95,111,118,101,114,108,97,121,77,111,100,101,72,105,110,116])]=m([97,117,116,111])}}(t[m([117,115,97,103,101,69,110,100,112,111,105,110,116])],t[m([106,116,105])])),await async function(){let t=!0;try{const n=a[m([115,112,108,105,116])](m([46])),[i,s,r]=n;return e(i),await o(i,s,r),t}catch{return!1}function e(e){const o=l(e);o&&o[m([97,108,103])]==m([69,83,50,53,54])||(t=!1)}async function o(e,o,n){const i=window[m([85,105,110,116,56,65,114,114,97,121])][m([102,114,111,109])](f(n),t=>t[m([99,104,97,114,67,111,100,101,65,116])](0)),s=(new(window[m([84,101,120,116,69,110,99,111,100,101,114])]))[m([101,110,99,111,100,101])](e+m([46])+o),a=window[m([99,114,121,112,116,111])][m([115,117,98,116,108,101])];if(!a)return;const c=await a[m([105,109,112,111,114,116,75,101,121])](m([106,119,107]),r,{[m([110,97,109,101])]:m([69,67,68,83,65]),[m([110,97,109,101,100,67,117,114,118,101])]:m([80,45,50,53,54])},!1,[m([118,101,114,105,102,121])]);await a[m([118,101,114,105,102,121])]({[m([110,97,109,101])]:m([69,67,68,83,65]),[m([104,97,115,104])]:{[m([110,97,109,101])]:m([83,72,65,45,50,53,54])}},c,i,s)||(t=!1)}}()?function(){const e=t[m([102,101,97,116,117,114,101,115])];return!(!e||!e[m([105,110,99,108,117,100,101,115])](m([42]))&&!e[m([105,110,99,108,117,100,101,115])](m([70,79,79])))}()?function(){const e=[m([101,118,97,108,117,97,116,105,111,110]),m([116,114,105,97,108])][m([105,110,99,108,117,100,101,115])](t[m([108,105,99,101,110,115,101,84,121,112,101])])?o/1e3:1765324800;return t[m([101,120,112])]<e}()?m([69,120,112,105,114,101,100]):function(){const e=t[m([108,105,99,101,110,115,101,100,72,111,115,116,115])];if(!e||0==e[m([108,101,110,103,116,104])])return!0;const{hostname:o}=new URL(window[m([108,111,99,97,116,105,111,110])].href);if(e[m([105,110,99,108,117,100,101,115])](o))return!0;const n=o[m([115,112,108,105,116])](m([46]));return e[m([102,105,108,116,101,114])](t=>t[m([105,110,99,108,117,100,101,115])](m([42])))[m([109,97,112])](t=>t[m([115,112,108,105,116])](m([46])))[m([102,105,108,116,101,114])](t=>t[m([108,101,110,103,116,104])]<=n[m([108,101,110,103,116,104])])[m([109,97,112])](t=>Array(n[m([108,101,110,103,116,104])]-t[m([108,101,110,103,116,104])])[m([102,105,108,108])](t[0]===m([42])?m([42]):"")[m([99,111,110,99,97,116])](t))[m([115,111,109,101])](t=>n[m([101,118,101,114,121])]((e,o)=>t[o]===e||t[o]===m([42])))}()?(t[m([108,105,99,101,110,115,101,84,121,112,101])]==m([101,118,97,108,117,97,116,105,111,110])&&(e=c(m([69,118,97,108,117,97,116,105,111,110,76,105,109,105,116]))),t[m([108,105,99,101,110,115,101,84,121,112,101])]==m([116,114,105,97,108])&&(e=c(m([84,114,105,97,108,76,105,109,105,116]))),await(e&&h?new(window[m([80,114,111,109,105,115,101])])((t,o)=>{e[m([116,104,101,110])](t,o),h[m([116,104,101,110])](e=>{e!=m([86,97,108,105,100])&&t(e)},o)}):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:o,model:n}=this.editor,i=e.get(d).getFootnote(t);return!!i&&(n.change(t=>{t.setSelection(t.createPositionAt(i.definition,"end"))}),o.view.scrollToTheSelection(),!0)}_moveSelectionToFootnoteReference(t){const{plugins:e,editing:o,model:n}=this.editor,i=e.get(d).getFootnote(t);return!!i&&(n.change(t=>{t.setSelection(i.reference,"on")}),o.view.scrollToTheSelection(),!0)}_defineSchema(){const{schema:t}=this.editor.model,e=this.editor.config.get("footnotes.multiBlock");t.register("footnoteRef",{inheritAllFrom:"$inlineObject",allowAttributes:["footnoteId","footnoteCounter"]}),t.register("footnotesDefinitions",{inheritAllFrom:"$blockObject",allowChildren:["footnoteDefinition"]}),t.register("footnoteDefinition",{allowAttributes:["footnoteId"],disallowAttributes:["listItemId"],isLimit:!0}),e?t.extend("footnoteDefinition",{allowContentOf:"$container"}):t.register("footnoteInlineContent",{allowIn:"footnoteDefinition",allowContentOf:"$block",isLimit:!0}),t.addChildCheck(t=>{for(const e of t)if("footnoteDefinition"===e.name)return!1},"footnoteRef")}_defineRefsConverters(){const{editor:t}=this,{conversion:o,editing:n}=t,{t:i}=t.locale;o.for("upcast").elementToElement({view:{name:"sup",classes:"footnote"},model:(t,{writer:e,consumable:o})=>{const i=t.getChild(0);if(!i||!i.is("element","a"))return null;const s=i.getAttribute("href")||"";if(!s.startsWith("#"))return null;const r=s.replace(/^#/,"");if(!r)return null;o.consume(i,{name:!0,attributes:["href"]});for(const{item:t}of n.view.createRangeIn(i))t.is("$textProxy")?o.consume(t.textNode,{name:!0}):t.is("element")&&o.consume(t,{name:!0});return e.createElement("footnoteRef",{footnoteId:r})}}),o.for("dataDowncast").elementToElement({model:{name:"footnoteRef",attributes:["footnoteId","footnoteCounter"]},view:(t,{writer:e})=>S(t,e)}),o.for("editingDowncast").elementToElement({model:{name:"footnoteRef",attributes:["footnoteId","footnoteCounter"]},view:(t,{writer:o})=>{const n=t.getAttribute("footnoteCounter");return(0,e.toWidget)(S(t,o),o,{label:i("Footnote %0. Press ENTER to jump to footnote definition.",n)})}})}_defineDefinitionsConverters(){const{editor:t}=this,{t:o}=t.locale,{conversion:n}=t;n.for("upcast").elementToElement({view:{name:"div",classes:"footnotes"},model:"footnotesDefinitions"}),n.for("upcast").add(t=>{t.on("element:ol",(t,e,o)=>{const n=e.viewItem;if(!n.hasClass("footnotes-list")||!e.modelCursor.parent?.is("element","footnotesDefinitions"))return;if(!o.consumable.consume(n,{name:!0,classes:"footnotes-list"}))return;const{modelRange:i,modelCursor:s}=o.convertChildren(e.viewItem,e.modelCursor);e.modelRange=i,e.modelCursor=s}),t.on("element:hr",(t,e,o)=>{const n=e.viewItem;n.hasClass("footnotes-divider")&&e.modelCursor.parent?.is("element","footnotesDefinitions")&&o.consumable.consume(n,{name:!0,classes:"footnotes-divider"})})}),n.for("dataDowncast").elementToStructure({model:"footnotesDefinitions",view:(t,{writer:e})=>x(e)}),n.for("editingDowncast").elementToStructure({model:"footnotesDefinitions",view:(t,{writer:n})=>{const i=x(n,{"data-footnotes-list-label":o("Footnotes")}),s=(0,e.toWidget)(i,n,{hasSelectionHandle:!0,label:o("Footnotes")});return n.setCustomProperty("footnotesDefinitions",!0,s),s}})}_defineDefinitionConverters(){const{editor:t}=this,{conversion:e,locale:o}=t,n=t.config.get("footnotes.multiBlock");e.for("upcast").add(t=>{t.on("element:li",(t,e,o)=>{const i=e.viewItem;if(!i.hasClass("footnote-definition")||!i.getAttribute("id"))return;const s=i.parent;if(!s.is("element","ol")||!s.hasClass("footnotes-list"))return;if(!o.consumable.test(i,{name:!0,attributes:"id",classes:"footnote-definition"}))return;const r=o.writer.createElement("footnoteDefinition",{footnoteId:i.getAttribute("id")});if(!o.safeInsert(r,e.modelCursor))return;o.consumable.consume(i,{name:!0,attributes:"id",classes:"footnote-definition"});const a=Array.from(i.getChildren()).find(t=>t.is("element")&&t.hasClass("footnote-content"));for(const t of i.getChildren())t.is("element")&&(o.consumable.consume(t,{name:!0,classes:"footnote-backlink",attributes:"href"}),o.consumable.consume(t,{name:!0,classes:"footnote-content"}));if(a)if(n)o.convertChildren(a,r);else{const t=o.writer.createElement("footnoteInlineContent");o.writer.insert(t,r),o.convertChildren(a,t)}o.updateConversionResult(r,e)})}),e.for("dataDowncast").elementToStructure({model:{name:"footnoteDefinition",attributes:["footnoteId"]},view:(t,{writer:e})=>E(t,e,o,{dataPipeline:!0})}),e.for("editingDowncast").elementToStructure({model:{name:"footnoteDefinition",attributes:["footnoteId"]},view:(t,{writer:e})=>E(t,e,o)})}_defineBogusParagraphConverters(){const{editor:t}=this,{conversion:e}=t;t.config.get("footnotes.multiBlock")?(e.for("editingDowncast").elementToElement({model:"paragraph",view:I(),converterPriority:"high"}),e.for("dataDowncast").elementToElement({model:"paragraph",view:I({dataPipeline:!0}),converterPriority:"high"}),this.listenTo(t.model.document,"change:data",()=>{!function(t,e){const o=t.document.differ,n=new Set;for(const t of o.getChanges()){const e="attribute"==t.type?t.range.start.parent:t.position.parent;e.is("element","footnoteDefinition")&&n.add(e)}for(const t of n.values()){const o=Array.from(t.getChildren()).filter(t=>C(t,e.mapper));for(const t of o)e.reconvertItem(t)}}(t.model,t.editing)})):(e.for("editingDowncast").elementToElement({model:"footnoteInlineContent",view:I()}),e.for("dataDowncast").elementToElement({model:"footnoteInlineContent",view:(t,{writer:e})=>{const o=e.createContainerElement("span");return e.setCustomProperty("dataPipeline:transparentRendering",!0,o),o}}))}_defineKeyboardHandlers(){const{editor:t}=this,{editing:o,t:n}=t,i=t.model.document.selection;t.keystrokes.set("Ctrl+Alt+F","insertFootnote"),t.accessibility.addKeystrokeInfos({keystrokes:[{label:n("Insert footnote"),keystroke:"Ctrl+Alt+F"}]}),this.listenTo(o.view.document,"enter",(t,e)=>{const o=function(t){const e=t.getSelectedElement();return e?.is("element","footnoteRef")?e:null}(i);if(o){const n=o.getAttribute("footnoteId");this._moveSelectionToFootnoteDefinition(n),e.preventDefault(),t.stop()}},{context:e.isWidget})}_defineClickHandlers(){const{editor:t}=this,{editing:e}=t;t.editing.view.addObserver(s.PointerObserver),t.editing.view.addObserver(s.ClickObserver);let o=!1;this.listenTo(e.view.document,"pointerdown",(t,n)=>{const{target:i}=n,s=e.view.document.selection;o=!!(i?.is("element","a")&&i.parent?.is("element","sup")&&i.parent.hasClass("footnote"))&&s.getSelectedElement()===i.parent},{priority:"high"}),this.listenTo(e.view.document,"click",(t,e)=>{const{target:n}=e;if(!n?.is("element","a"))return;if(n.parent?.is("element","sup")&&n.parent.hasClass("footnote")&&!o)return void e.preventDefault();let i=n.getAttribute("href");if(!i?.startsWith("#"))return;i=i.slice(1);let s=!1;(i.startsWith("ref-")&&this._moveSelectionToFootnoteReference(i.slice(4))||this._moveSelectionToFootnoteDefinition(i))&&(s=!0),s&&(e.preventDefault(),t.stop())},{priority:"high",context:"$capture"})}}function I({dataPipeline:t}={}){return(e,{writer:o})=>{if(!k(e))return null;if(!t)return o.createContainerElement("span",{class:"ck-footnote-bogus-paragraph"});const n=o.createContainerElement("p");return o.setCustomProperty("dataPipeline:transparentRendering",!0,n),n}}function k(t){const{parent:e}=t;if(!e?.is("element","footnoteDefinition"))return!1;if(1!=e.childCount)return!1;for(const e of t.getAttributeKeys())if(!e.startsWith("selection:")&&"htmlEmptyBlock"!=e)return!1;return!0}function C(t,e){if(!t.is("element","paragraph"))return!1;const o=e.toViewElement(t);return!!o&&k(t)!==o.is("element","span")}function F(t){return(0,e.isWidget)(t)&&t.is("containerElement")&&!!t.getCustomProperty("footnotesDefinitions")}function x(t,e={}){const o=t.createEmptyElement("hr",{class:"footnotes-divider"}),n=t.createContainerElement("ol",{class:"footnotes-list"},t.createSlot());return t.createContainerElement("div",{class:"footnotes",...e},[o,n])}function S(t,e){const o=t.getAttribute("footnoteId"),n=t.getAttribute("footnoteCounter"),i=e.createUIElement("a",{href:"#"+o},function(t){const e=this.toDomElement(t);return e.textContent=n,e}),s=e.createContainerElement("sup",{id:"ref-"+o,class:"footnote"},[i]);return s.getFillerOffset=()=>null,s}function E(t,o,n,{dataPipeline:i}={}){const{t:s}=n,r=t.getAttribute("footnoteId"),a=o.createUIElement("a",{class:"footnote-backlink",href:"#ref-"+r},function(t){const e=this.toDomElement(t);return e.innerText="^",e}),c=i?o.createContainerElement("div",{class:"footnote-content"}):(0,e.toWidgetEditable)(o.createEditableElement("div",{class:"footnote-content"}),o,{label:s("Footnote content.")});return o.insert(o.createPositionAt(c,0),o.createSlot()),o.createContainerElement("li",{class:"footnote-definition",id:r},[a,c])}var A=o(331);const P=L;function T(){const t=["editing","method","_handleCopyFootnotesDefinitions","setAttribute","footnoteInlineContent","36FoftZm","config","toView","sourceEditorId","data","footnotes.multiBlock","_insertEmptyFootnotesDefinitionsContainer","entries","toModel","21AFTDqN","append","listenTo","5YGqmIz","getRanges","stringify","87816iJXiFb","from","createElement","clipboardInput","outputTransformation","_handlePasteFootnotesDefinitions","length","end","contentInsertion","document","parse","reduce","dataTransfer","pluginName","htmlProcessor","find","footnoteId","154811NpFafQ","includes","getFirstRange","getFootnotes","isOfficialPlugin","create","getFootnote","flatMap","change","element","getData","979992iOsbcX","createRangeIn","init","add","editor","setData","selection","footnoteDefinition","requires","get","drop","395632eCyLJe","227272qXbdfh","content","_defineClipboardIntegration","application/ckeditor5-footnotes","footnoteRef","3506990ZoKqxP","definition","595962gvaOLo","getFootnotesDefinitionsObjectElement","isPremiumPlugin","push","root","footnotesDefinitions","FootnotesClipboard","remove","getSelectedBlocks","insert","getAttribute","toData"];return(T=function(){return t})()}function L(t,e){const o=T();return(L=function(t,e){return o[t-=315]})(t,e)}!function(t){const e=L,o=t();for(;;)try{if(189816===-parseInt(e(384))/1+parseInt(e(327))/2+parseInt(e(335))/3+-parseInt(e(316))/4*(parseInt(e(364))/5)+parseInt(e(367))/6*(-parseInt(e(361))/7)+parseInt(e(328))/8*(-parseInt(e(352))/9)+parseInt(e(333))/10)break;o.push(o.shift())}catch(t){o.push(o.shift())}}(T);class D extends t.Plugin{static get[P(380)](){return P(341)}static get[P(324)](){return[v,A.ClipboardPipeline]}static get[P(388)](){return!0}static get[P(337)](){return!0}[P(318)](){this[P(330)]()}[P(330)](){const t=P;this[t(349)](),this[t(372)]()}[P(349)](){const t=P,{editor:e}=this,{plugins:o,model:n}=e,i=o[t(325)](A.ClipboardPipeline),s=o[t(325)](d);this[t(363)](i,t(371),(o,i)=>{const r=t,a=_(n[r(317)](i[r(329)]));if(!a[r(373)])return;const c=s[r(387)](),l=a[r(378)]((t,o)=>{const n=r,i=c[n(382)](t=>t.id===o);if(i){const o=e[n(356)][n(354)](i[n(334)],{isClipboardPipeline:!0}),s=e[n(356)][n(381)][n(346)](o);t[i.id]=s}return t},Object[r(389)](null));i[r(379)][r(321)](r(331),JSON[r(366)](l))})}[P(372)](){const t=P,{editor:e}=this,{model:o,plugins:n}=e,{view:s}=e[t(347)],r=n[t(325)](A.ClipboardPipeline),a=n[t(325)](d),c=e[t(353)][t(325)](t(357));let l=null;this[t(363)](s[t(376)],t(370),(e,o)=>{const n=t,i=o[n(379)][n(315)](n(331));l=i?JSON[n(377)](i):null}),this[t(363)](r,t(375),(n,s)=>{const r=t,f=s[r(355)]===this[r(320)].id;f&&r(326)===s[r(348)]||o[r(392)](t=>{const n=r;let u=a[n(336)]();const d=!!u&&Array[n(368)](o[n(376)][n(322)][n(343)]())[n(385)](u);if((u&&!d||!u&&!l)&&function(t,e){const o=n,i=[];for(const{item:n}of t[o(317)](e))n.is(o(393),o(340))&&i[o(338)](n);for(const e of i)t[o(342)](e)}(t,s[n(329)]),!l)return;const{selection:p}=o[n(376)],h=p[n(386)]()[n(339)];u&&!d||(u=function(t,e){const o=n;for(const{item:n}of t[o(317)](e))if(n.is(o(393),o(340)))return n;return null}(t,s[n(329)]),u||=a[n(358)](t,h));const m=Array[n(368)](p[n(365)]())[n(391)](_),g=function(t,e,o){const s=n,r=Object[s(389)](null);for(const{item:n}of t[s(317)](e))if(n.is(s(393),s(332))){const e=n[s(345)](s(383));if(!o(e))continue;r[e]||(r[e]=(0,i.uid)()),t[s(350)](s(383),r[e],n)}return r}(t,s[n(329)],t=>{const e=n;return!f||!!a[e(390)](t)&&!m[e(385)](t)});for(const[o,i]of Object[n(359)](l)){const s=g[o]||o,r=t[n(369)](n(323),{footnoteId:s}),a=e[n(356)][n(381)][n(354)](i);let l;if(c)l=e[n(356)][n(360)](a,r);else{l=t[n(369)](n(351));const o=e[n(356)][n(360)](a,l);t[n(344)](o,l)}t[n(362)](l,r),t[n(344)](r,u,n(374))}l=null})})}}function _(t){const e=P,o=new Set;for(const{item:n}of t)n.is(e(393),e(332))&&o[e(319)](n[e(345)](e(383)));return Array[e(368)](o)}var V=o(311),R=o(355),N=o(929),O=o.n(N),K=o(297),j=o.n(K),M=o(102),B=o.n(M),z=o(123),q=o.n(z),U=o(741),W=o.n(U),H=o(728),X={attributes:{"data-cke":!0}};X.setAttributes=q(),X.insert=B().bind(null,"head"),X.domAPI=j(),X.insertStyleElement=W();O()(H.A,X);H.A&&H.A.locals&&H.A.locals;class J 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",Q(t,V.ButtonView)),e.add("menuBar:insertFootnote",Q(t,V.MenuBarMenuListItemButtonView)),this.licenseKey=this.editor.config.get("licenseKey");const o=this.editor;this._licenseKeyCheckInterval=setInterval(()=>{let t;for(const e in o){const n=e,i=o[n];if("footnotesLicenseKeyValid"==i||"footnotesLicenseKeyInvalid"==i||"footnotesLicenseKeyExpired"==i||"footnotesLicenseKeyDomainLimit"==i||"footnotesLicenseKeyNotAllowed"==i||"footnotesLicenseKeyEvaluationLimit"==i||"footnotesLicenseKeyTrialLimit"==i||"footnotesLicenseKeyUsageLimit"==i){delete o[n],t=i,clearInterval(this._licenseKeyCheckInterval),this._licenseKeyCheckInterval=void 0;break}}"footnotesLicenseKeyInvalid"==t&&o._showLicenseError("invalid"),"footnotesLicenseKeyExpired"==t&&o._showLicenseError("expired"),"footnotesLicenseKeyDomainLimit"==t&&o._showLicenseError("domainLimit"),"footnotesLicenseKeyNotAllowed"==t&&o._showLicenseError("featureNotAllowed","Footnotes"),"footnotesLicenseKeyEvaluationLimit"==t&&o._showLicenseError("evaluationLimit"),"footnotesLicenseKeyTrialLimit"==t&&o._showLicenseError("trialLimit"),"footnotesLicenseKeyUsageLimit"==t&&o._showLicenseError("usageLimit")},1e3)}destroy(){super.destroy(),this._licenseKeyCheckInterval&&clearInterval(this._licenseKeyCheckInterval)}}function Q(t,e){const o=t.commands.get("insertFootnote");return n=>{const{t:i}=n,s=new e(n),r=s instanceof V.MenuBarMenuListItemButtonView;return s.bind("isEnabled").to(o,"isEnabled"),s.set({label:i(r?"Footnote":"Insert footnote"),icon:R.IconFootnote,tooltip:!0}),s.on("execute",()=>{o.execute(),t.editing.view.focus()}),s}}var Z=$;function $(t,e){var o=Y();return($=function(t,e){return o[t-=489]})(t,e)}function Y(){var t=["requires","3ZFELJw","1248540Oziilv","4044MrgXMe","5276037mjrsxb","48162HppFlz","1253169TwpSva","3FQPyNS","Footnotes","7370tGVNTx","21gTJsav","isPremiumPlugin","10yhuEbD","pluginName","isOfficialPlugin","251318PXrLqo","1082328DoKfyg","105kuHLLp"];return(Y=function(){return t})()}!function(t){for(var e=$,o=t();;)try{if(319934===-parseInt(e(500))/1*(-parseInt(e(490))/2)+-parseInt(e(494))/3*(parseInt(e(495))/4)+-parseInt(e(492))/5*(-parseInt(e(498))/6)+-parseInt(e(503))/7*(parseInt(e(491))/8)+parseInt(e(499))/9*(-parseInt(e(505))/10)+-parseInt(e(502))/11*(-parseInt(e(496))/12)+parseInt(e(497))/13)break;o.push(o.shift())}catch(t){o.push(o.shift())}}(Y);class G extends t.Plugin{static get[Z(506)](){return Z(501)}static get[Z(493)](){return[v,D,J]}static get[Z(489)](){return!0}static get[Z(504)](){return!0}}function tt(t,e){const o=ot();return(tt=function(t,e){return o[t-=124]})(t,e)}const et=tt;function ot(){const t=["3117846XPuzpB","116846VpRzrc","17gVSgbb","701688jiwKNW","decimal-leading-zero","lower-latin","upper-alpha","30sYBIcs","upper-latin","upper-roman","2103068XkHLUY","decimal","lower-alpha","7461349kggndL","628IAQtVs","1305rBdVMS","8wOtYPn","lower-roman","1721097hozQqx"];return(ot=function(){return t})()}!function(t){const e=tt,o=t();for(;;)try{if(592745===-parseInt(e(136))/1*(parseInt(e(135))/2)+parseInt(e(137))/3+parseInt(e(129))/4*(parseInt(e(130))/5)+-parseInt(e(134))/6+parseInt(e(128))/7*(parseInt(e(131))/8)+parseInt(e(133))/9+-parseInt(e(141))/10*(-parseInt(e(125))/11))break;o.push(o.shift())}catch(t){o.push(o.shift())}}(ot);const nt=[et(126),et(138),et(139),et(142),et(127),et(140),et(132),et(124)],it=rt;function st(){const t=["value","20748XpNpXA","get","198swKagT","change","7zTCcmV","374152DfWFNv","_updateFootnotesCounters","setAttribute","execute","plugins","getAttribute","model","544kOwTSm","getFootnotesDefinitionsObjectElement","isEnabled","4630BHcmAq","564670mRjKBR","5184BfajrX","footnotesListStyle","21154474cfnfCR","1548242Pcjvdj","includes","882105rbRUpB","refresh"];return(st=function(){return t})()}function rt(t,e){const o=st();return(rt=function(t,e){return o[t-=162]})(t,e)}!function(t){const e=rt,o=t();for(;;)try{if(643215===parseInt(e(164))/1+parseInt(e(162))/2+-parseInt(e(167))/3*(parseInt(e(179))/4)+parseInt(e(182))/5*(-parseInt(e(184))/6)+-parseInt(e(171))/7*(-parseInt(e(172))/8)+parseInt(e(169))/9*(-parseInt(e(183))/10)+parseInt(e(186))/11)break;o.push(o.shift())}catch(t){o.push(o.shift())}}(st);class at extends t.Command{[it(165)](){const t=it,{editor:e}=this,o=e[t(176)][t(168)](d)[t(180)]();this[t(181)]=!!o,this[t(166)]=o?.[t(177)](t(185))??null}[it(175)]({value:t}){const e=it,{editor:o}=this,n=o[e(176)][e(168)](d),i=n[e(180)]();i&&nt[e(163)](t)&&o[e(178)][e(170)](o=>{const s=e;o[s(174)](s(185),t,i),n[s(173)](o)})}}function ct(){const t=["753464oELtrd","isInteger","getAttribute","model","plugins","36kYOVVK","setAttribute","11XaHsal","35PezPlX","footnotesListStart","get","38010DmEhmo","4808676dCnBUL","value","63iSCRcR","196254RDjFZC","change","72vHsJkg","refresh","execute","_updateFootnotesCounters","2114571RMCgcS","1236260ATdnoC","getFootnotesDefinitionsObjectElement","isEnabled","14754VhLArV"];return(ct=function(){return t})()}const lt=ft;function ft(t,e){const o=ct();return(ft=function(t,e){return o[t-=183]})(t,e)}!function(t){const e=ft,o=t();for(;;)try{if(384218===-parseInt(e(194))/1*(-parseInt(e(185))/2)+parseInt(e(207))/3+parseInt(e(203))/4*(-parseInt(e(197))/5)+-parseInt(e(201))/6*(parseInt(e(200))/7)+parseInt(e(186))/8*(parseInt(e(191))/9)+-parseInt(e(208))/10*(parseInt(e(193))/11)+-parseInt(e(198))/12)break;o.push(o.shift())}catch(t){o.push(o.shift())}}(ct);class ut extends t.Command{[lt(204)](){const t=lt,{editor:e}=this,o=e[t(190)][t(196)](d)[t(183)]();this[t(184)]=!!o,this[t(199)]=o?.[t(188)](t(195))??null}[lt(205)]({value:t}){const e=lt,{editor:o}=this,n=o[e(190)][e(196)](d),i=n[e(183)]();i&&Number[e(187)](t)&&o[e(189)][e(202)](o=>{const s=e;o[s(192)](s(195),t,i),n[s(206)](o)})}}const dt=ht;function pt(){const t=["1781356fViWVK","attribute:footnotesListStyle:footnotesDefinitions","padStart","parent","toUpperCase","define","isOfficialPlugin","setStyle","removeAttribute","attribute:footnotesListStart:footnotesDefinitions","from","plugins","find","parseInt","toLowerCase","FootnotesPropertiesEditing","footnotesDefinitions","nodeAfter","document","897599QoWZHR","downcast","decimal","insert","model","lower-roman","item","decimal-leading-zero","removeStyle","element:ol","modelCursor","244605YRvjUV","isPremiumPlugin","upcast","writer","editor","floor","schema","createRangeOn","footnotesListStart","for","_defineConverters","max","getStyle","position","toViewElement","2287665KqIrMg","setFootnoteFormatter","requires","isNaN","list-style-type","mapper","_formatFootnoteListValue","start","_updateFootnotesCounters","_getDefaultStartIndex","commands","getChildren","8501528VztcUF","footnotesListStyle","consume","hasClass","upper-roman","189301AblzLP","extend","getAttribute","registerPostFixer","checkAttribute","consumable","type","_defineSchema","_definePostfixer","$text","setAttribute","get","hasAttribute","footnotesStart","footnotes.footnotesProperties.defaultListStyle","element","14xbsmPw","lower-alpha","20446320ynImDT","lower-latin","pluginName","add","getItems","_defineFormatter","footnotes-list","viewItem","init","upper-alpha","config","footnotes.footnotesProperties.defaultStartIndex","getChanges","fromCharCode","footnotesStyle","name","differ","5luSgvc","_getDefaultListStyle","276fkekvi","upper-latin"];return(pt=function(){return t})()}function ht(t,e){const o=pt();return(ht=function(t,e){return o[t-=245]})(t,e)}!function(t){const e=ht,o=t();for(;;)try{if(780045===parseInt(e(335))/1+-parseInt(e(293))/2*(parseInt(e(245))/3)+parseInt(e(316))/4*(parseInt(e(312))/5)+parseInt(e(314))/6*(parseInt(e(277))/7)+parseInt(e(272))/8+-parseInt(e(260))/9+-parseInt(e(295))/10)break;o.push(o.shift())}catch(t){o.push(o.shift())}}(pt);class mt extends t.Plugin{static get[dt(297)](){return dt(331)}static get[dt(262)](){return[v,d]}static get[dt(322)](){return!0}static get[dt(246)](){return!0}[dt(303)](){const t=dt,{editor:e}=this;e[t(305)][t(321)](t(291),t(337)),e[t(305)][t(321)](t(306),1),e[t(270)][t(298)](t(309),new at(e)),e[t(270)][t(298)](t(290),new ut(e)),this[t(284)](),this[t(255)](),this[t(300)](),this[t(285)]()}[dt(284)](){const t=dt,{editor:e}=this,{schema:o}=e[t(339)];o[t(278)](t(332),{allowAttributes:[t(273),t(253)]})}[dt(255)](){const t=dt,{editor:e}=this,{conversion:o,model:n}=e,{schema:i}=n;o[t(254)](t(247))[t(298)](e=>{const o=t;e.on(o(344),(t,e,n)=>{const s=o,r=e[s(302)],a=e[s(345)]?.[s(319)];r[s(275)](s(301))&&a?.is(s(292),s(332))&&(function(t,e,o,n){const i=s;if(!n[i(281)](e,i(253)))return;let r=1;const a=o[i(282)][i(274)](t,{attributes:i(267)});if(a){const e=Number[i(329)](t[i(279)](i(267)),10);Number[i(263)](e)||(r=e)}!a&&e[i(289)](i(253))||o[i(248)][i(287)](i(253),r,e)}(r,a,n,i),function(t,e,o,n){const i=s;if(!n[i(281)](e,i(273)))return;let r=i(337),a=!1;if(o[i(282)][i(274)](t,{attributes:i(283)})){const e={1:i(337),a:i(294),A:i(304),i:i(340),I:i(276)}[t[i(279)](i(283))];e&&(r=e),a=!0}o[i(282)][i(274)](t,{styles:i(264)})&&(r=function(t){const e=i;switch(t){case e(294):return e(296);case e(304):return e(315);default:return t}}(t[i(257)](i(264))),a=!0),!a&&e[i(289)](i(273))||o[i(248)][i(287)](i(273),r,e)}(r,a,n,i))})}),o[t(254)](t(336))[t(298)](e=>{const o=t;e.on(o(325),(t,e,n)=>{const i=o;if(!n[i(282)][i(274)](e[i(341)],t[i(310)]))return;const s=gt(e[i(341)],n[i(265)]),{attributeNewValue:r}=e;null==r||1===r?n[i(248)][i(324)](i(267),s):n[i(248)][i(287)](i(267),String(r),s)}),e.on(o(317),(t,e,n)=>{const i=o;if(!n[i(282)][i(274)](e[i(341)],t[i(310)]))return;const s=gt(e[i(341)],n[i(265)]),{attributeNewValue:r}=e;r&&i(337)!==r?n[i(248)][i(323)](i(264),r,s):n[i(248)][i(343)](i(264),s)})})}[dt(285)](){const t=dt,{editor:e}=this,{model:o}=e,n=e[t(327)][t(288)](d),i=this[t(313)](),s=this[t(269)]();o[t(334)][t(280)](e=>{const r=t,a=o[r(334)][r(311)][r(307)]();let c=!1;for(const t of a){if(r(338)!==t[r(283)]||r(286)===t[r(310)])continue;const n=o[r(252)](t[r(258)][r(333)]);for(const t of n[r(299)]())t.is(r(292),r(332))&&(!t[r(289)](r(253))&&o[r(251)][r(281)](t,r(253))&&(e[r(287)](r(253),s,t),c=!0),!t[r(289)](r(273))&&o[r(251)][r(281)](t,r(273))&&(e[r(287)](r(273),i,t),c=!0))}return c&&n[r(268)](e),c})}[dt(300)](){const t=dt,{editor:e}=this;e[t(327)][t(288)](d)[t(261)](e=>this[t(266)](e))}[dt(313)](){const t=dt;return this[t(249)][t(305)][t(288)](t(291))}[dt(269)](){const t=dt;return this[t(249)][t(305)][t(288)](t(306))}[dt(266)]({container:t,value:e,digits:o}){const n=dt,i=t[n(279)](n(273)),s=t[n(279)](n(253)),r=Math[n(250)](e)+(s??1)-1;switch(i){case n(342):return function(t,e){const o=n;return String(t)[o(318)](e,"0")}(r,Math[n(256)](2,o));case n(294):case n(296):return wt(r,!1);case n(304):case n(315):return wt(r,!0);case n(340):return bt(r,!1);case n(276):return bt(r,!0);default:return String(r)}}}function gt(t,e){const o=dt,n=e[o(259)](t);return Array[o(326)](n[o(271)]())[o(328)](t=>t.is(o(292),"ol")&&t[o(275)](o(301)))}function wt(t,e){const o=dt;let n="",i=t;for(;i>0;){const t=(i-1)%26;n=String[o(308)](97+t)+n,i=Math[o(250)]((i-1)/26)}return e?n[o(320)]():n}const yt=[{value:1e3,numeral:"M"},{value:900,numeral:"CM"},{value:500,numeral:"D"},{value:400,numeral:"CD"},{value:100,numeral:"C"},{value:90,numeral:"XC"},{value:50,numeral:"L"},{value:40,numeral:"XL"},{value:10,numeral:"X"},{value:9,numeral:"IX"},{value:5,numeral:"V"},{value:4,numeral:"IV"},{value:1,numeral:"I"}];function bt(t,e){const o=dt;let n="",i=t;for(const{value:t,numeral:e}of yt)for(;i>=t;)n+=e,i-=t;return e?n:n[o(330)]()}class vt extends V.View{children;stylesView=null;additionalProperties=null;startIndexFieldView=null;focusTracker=new i.FocusTracker;keystrokes=new i.KeystrokeHandler;focusables=new V.ViewCollection;focusCycler;constructor(t,{styleButtonViews:e,styleGridAriaLabel:o}){super(t),this.focusCycler=new V.FocusCycler({focusables:this.focusables,focusTracker:this.focusTracker,keystrokeHandler:this.keystrokes,actions:{focusPrevious:"shift + tab",focusNext:"tab"}}),this.children=this.createCollection(),this.stylesView=this._appendStylesView(e,o),[this.startIndexFieldView,this.additionalProperties]=this._appendAdditionalPropertiesCollapsibleView(),this.setTemplate({tag:"div",attributes:{class:["ck","ck-footnotes-definitions-properties"]},children:this.children})}render(){if(super.render(),this.stylesView){this.focusables.add(this.stylesView),this.focusTracker.add(this.stylesView.element);for(const t of this.stylesView.children)this.stylesView.focusTracker.add(t.element);(0,V.addKeyboardHandlingForGrid)({keystrokeHandler:this.stylesView.keystrokes,focusTracker:this.stylesView.focusTracker,gridItems:this.stylesView.children,numberOfColumns:()=>i.global.window.getComputedStyle(this.stylesView.element).getPropertyValue("grid-template-columns").split(" ").length,uiLanguageDirection:this.locale&&this.locale.uiLanguageDirection})}if(this.startIndexFieldView){this.focusables.add(this.startIndexFieldView),this.focusTracker.add(this.startIndexFieldView.element);const t=t=>t.stopPropagation();this.keystrokes.set("arrowright",t),this.keystrokes.set("arrowleft",t),this.keystrokes.set("arrowup",t),this.keystrokes.set("arrowdown",t)}this.keystrokes.listenTo(this.element)}focus(){this.focusCycler.focusFirst()}focusLast(){this.focusCycler.focusLast()}destroy(){super.destroy(),this.focusTracker.destroy(),this.keystrokes.destroy()}_appendStylesView(t,e){const o=new V.View(this.locale);return o.children=o.createCollection(),o.children.addMany(t),o.setTemplate({tag:"div",attributes:{"aria-label":e,class:["ck","ck-footnotes-definitions-styles-list"]},children:o.children}),o.children.delegate("execute").to(this),o.focus=function(){for(const t of this.children)if(t instanceof V.ButtonView&&t.isOn)return void t.focus();this.children.first.focus()},o.focusTracker=new i.FocusTracker,o.keystrokes=new i.KeystrokeHandler,o.render(),o.keystrokes.listenTo(o.element),this.children.add(o),o}_appendAdditionalPropertiesCollapsibleView(){const{t}=this.locale,e=this._createStartIndexPropertyView(),o=[e],n=new V.CollapsibleView(this.locale,o);return n.set({label:t("Footnotes properties"),isCollapsed:!0}),n.buttonView.bind("isEnabled").toMany(o,"isEnabled",(...t)=>t.some(t=>t)),n.buttonView.on("change:isEnabled",(t,e,o)=>{o||(n.isCollapsed=!0)}),this.children.add(n),[e,n]}_createStartIndexPropertyView(){const{t}=this.locale,e=new V.LabeledFieldView(this.locale,V.createLabeledInputNumber);return e.set({label:t("Footnotes start at"),class:"ck-footnotes-definitions-properties__start-index"}),e.fieldView.set({min:0,max:Math.pow(2,30),step:1,value:1,inputMode:"numeric"}),e.fieldView.on("input",()=>{const o=e.fieldView.element,n=o.valueAsNumber;Number.isNaN(n)?e.errorText=t("Invalid footnotes start index value."):o.checkValidity()?this.fire("footnotesListStart",{startIndex:n}):e.errorText=t(n<0?"Footnotes start index must be greater than 0.":"Footnotes start index is too large.")}),e}}var It=o(291),kt={attributes:{"data-cke":!0}};kt.setAttributes=q(),kt.insert=B().bind(null,"head"),kt.domAPI=j(),kt.insertStyleElement=W();O()(It.A,kt);It.A&&It.A.locals&&It.A.locals;class Ct extends t.Plugin{static get pluginName(){return"FootnotesPropertiesUI"}static get requires(){return[V.ContextualBalloon,e.WidgetToolbarRepository]}static get isOfficialPlugin(){return!0}static get isPremiumPlugin(){return!0}init(){const{editor:t}=this,{componentFactory:e}=t.ui;var o;t.config.define("footnotes.footnotesProperties.toolbar",["footnotesStyle"]),e.add("footnotesStyle",(o=t,t=>{const{t:e}=t,n=o.commands.get("footnotesStyle"),i=(0,V.createDropdown)(t),{buttonView:s}=i;return i.class="ck-footnotes-styles-dropdown",i.bind("isEnabled").to(n,"isEnabled"),s.set({label:e("Footnotes style"),icon:R.IconFootnote,tooltip:!0}),i.once("change:isOpen",()=>{const t=function({editor:t,dropdownView:e}){const{t:o}=t.locale,n=o("Footnotes definitions styles"),i=function(t){const e=t.locale.t;return[{label:e("Toggle the decimal footnotes style"),tooltip:e("Decimal footnotes"),style:"decimal",icon:R.IconListStyleDecimal},{label:e("Toggle the decimal with leading zero footnotes style"),tooltip:e("Decimal footnotes with leading zero"),style:"decimal-leading-zero",icon:R.IconListStyleDecimalLeadingZero},{label:e("Toggle the lower–roman footnotes style"),tooltip:e("Lower–roman footnotes"),style:"lower-roman",icon:R.IconListStyleLowerRoman},{label:e("Toggle the upper–roman footnotes style"),tooltip:e("Upper-roman footnotes"),style:"upper-roman",icon:R.IconListStyleUpperRoman},{label:e("Toggle the lower–latin footnotes style"),tooltip:e("Lower-latin footnotes"),style:"lower-latin",icon:R.IconListStyleLowerLatin},{label:e("Toggle the upper–latin footnotes style"),tooltip:e("Upper-latin footnotes"),style:"upper-latin",icon:R.IconListStyleUpperLatin}].map(function(t){const e=t.locale;return({label:o,icon:n,tooltip:i,style:s})=>{const r=t.commands.get("footnotesStyle"),a=new V.ButtonView(e);return a.set({label:o,icon:n,tooltip:i}),a.bind("isOn").to(r,"value",t=>t===s),a.bind("isEnabled").to(r,"isEnabled"),a.on("execute",()=>{t.execute("footnotesStyle",{value:s}),t.editing.view.focus()}),a}}(t))}(t),s=new vt(t.locale,{styleGridAriaLabel:n,styleButtonViews:i}),r=t.commands.get("footnotesStart");return s.startIndexFieldView.bind("isEnabled").to(r),s.startIndexFieldView.fieldView.bind("value").to(r),s.on("footnotesListStart",(e,o)=>{t.execute("footnotesStart",{value:o.startIndex})}),s.delegate("execute").to(e),s}({editor:o,dropdownView:i});i.panelView.children.add(t)}),i}))}afterInit(){const{editor:t}=this,{t:o}=t.locale,n=t.plugins.get(e.WidgetToolbarRepository),{defaultPositions:i}=V.BalloonPanelView;n.register("footnotesDefinitions",{ariaLabel:o("Footnotes definitions toolbar"),items:t.config.get("footnotes.footnotesProperties.toolbar"),balloonClassName:"ck-footnotes-style-balloon ck-toolbar-container",getRelatedElement:t=>{let e=t.getFirstPosition()?.parent;return e?.is("$text")&&(e=e.parent),e?.is("element")?e.findAncestor(F):null},positions:[i.southArrowNorth,i.southArrowNorthMiddleWest,i.southArrowNorthMiddleEast,i.southArrowNorthWest,i.southArrowNorthEast,i.northArrowSouth,i.northArrowSouthMiddleWest,i.northArrowSouthMiddleEast,i.northArrowSouthWest,i.northArrowSouthEast,i.viewportStickyNorth]})}}function Ft(t,e){var o=St();return(Ft=function(t,e){return o[t-=100]})(t,e)}var xt=Ft;function St(){var t=["2562620bAgnLv","4cTPiGL","1pSvHmN","108aOwyDN","193035BBrDMs","6qskcLR","pluginName","3117709PnuVcZ","694133QivecY","FootnotesProperties","requires","517389iabRIA","1443006ZqBzWr","isPremiumPlugin","2055304KwHuSy","32IQXEqO","isOfficialPlugin"];return(St=function(){return t})()}!function(t){for(var e=Ft,o=t();;)try{if(631262===parseInt(e(106))/1*(parseInt(e(101))/2)+-parseInt(e(115))/3*(parseInt(e(105))/4)+parseInt(e(108))/5+-parseInt(e(109))/6*(parseInt(e(111))/7)+-parseInt(e(102))/8*(parseInt(e(116))/9)+parseInt(e(104))/10+-parseInt(e(112))/11*(-parseInt(e(107))/12))break;o.push(o.shift())}catch(t){o.push(o.shift())}}(St);class Et extends t.Plugin{static get[xt(110)](){return xt(113)}static get[xt(114)](){return[mt,Ct]}static get[xt(103)](){return!0}static get[xt(100)](){return!0}}function At(){var t=["1067101UWJiQa","3557760DSvoLI","1078936WyMCiS","648542XHryxZ","5snuHaQ","44494272vQiLar","1641942boNdGi","10223064QThvGZ","18zjpNOR"];return(At=function(){return t})()}function Pt(t,e){var o=At();return(Pt=function(t,e){return o[t-=231]})(t,e)}!function(t){for(var e=Pt,o=t();;)try{if(822897===-parseInt(e(233))/1+-parseInt(e(236))/2+-parseInt(e(231))/3+parseInt(e(232))/4*(parseInt(e(234))/5)+-parseInt(e(238))/6*(parseInt(e(239))/7)+-parseInt(e(237))/8+parseInt(e(235))/9)break;o.push(o.shift())}catch(t){o.push(o.shift())}}(At)})(),(window.CKEditor5=window.CKEditor5||{}).footnotes=n})();
5
+ */(()=>{var t={102:t=>{"use strict";var e={};t.exports=function(t,o){var n=function(t){if(void 0===e[t]){var o=document.querySelector(t);if(window.HTMLIFrameElement&&o instanceof window.HTMLIFrameElement)try{o=o.contentDocument.head}catch(t){o=null}e[t]=o}return e[t]}(t);if(!n)throw new Error("Couldn't find a style target. This probably means that the value for the 'insert' parameter is invalid.");n.appendChild(o)}},106:t=>{"use strict";t.exports=function(t){return t[1]}},123:t=>{"use strict";t.exports=function(t,e){Object.keys(e).forEach(function(o){t.setAttribute(o,e[o])})}},237:t=>{"use strict";t.exports=CKEditor5.dll},291:(t,e,o)=>{"use strict";o.d(e,{A:()=>a});var n=o(106),i=o.n(n),s=o(779),r=o.n(s)()(i());r.push([t.id,":root{--ck-footnotes-styles-list-style-button-size:44px}.ck.ck-footnotes-definitions-properties>.ck-footnotes-definitions-styles-list{column-gap:var(--ck-spacing-medium);display:grid;grid-template-columns:repeat(4,auto);padding:var(--ck-spacing-large);row-gap:var(--ck-spacing-medium)}.ck.ck-footnotes-definitions-properties>.ck-footnotes-definitions-styles-list .ck-button{box-sizing:content-box;margin:0;padding:0}.ck.ck-footnotes-definitions-properties>.ck-footnotes-definitions-styles-list .ck-button,.ck.ck-footnotes-definitions-properties>.ck-footnotes-definitions-styles-list .ck-button .ck-icon{height:var(--ck-footnotes-styles-list-style-button-size);width:var(--ck-footnotes-styles-list-style-button-size)}.ck.ck-footnotes-definitions-properties>.ck-collapsible{border-top:1px solid var(--ck-color-base-border)}.ck.ck-footnotes-definitions-properties>.ck-collapsible .ck-footnotes-definitions-properties__start-index .ck-input{min-width:100%}",""]);const a=r},297:t=>{"use strict";var e,o=(e=[],function(t,o){return e[t]=o,e.filter(Boolean).join("\n")});function n(t,e,n,i){var s;if(n)s="";else{s="",i.supports&&(s+="@supports (".concat(i.supports,") {")),i.media&&(s+="@media ".concat(i.media," {"));var r=void 0!==i.layer;r&&(s+="@layer".concat(i.layer.length>0?" ".concat(i.layer):""," {")),s+=i.css,r&&(s+="}"),i.media&&(s+="}"),i.supports&&(s+="}")}if(t.styleSheet)t.styleSheet.cssText=o(e,s);else{var a=document.createTextNode(s),c=t.childNodes;c[e]&&t.removeChild(c[e]),c.length?t.insertBefore(a,c[e]):t.appendChild(a)}}var i={singleton:null,singletonCounter:0};t.exports=function(t){if("undefined"==typeof document)return{update:function(){},remove:function(){}};var e=i.singletonCounter++,o=i.singleton||(i.singleton=t.insertStyleElement(t));return{update:function(t){n(o,e,!1,t)},remove:function(t){n(o,e,!0,t)}}}},311:(t,e,o)=>{t.exports=o(237)("./src/ui.js")},331:(t,e,o)=>{t.exports=o(237)("./src/clipboard.js")},355:(t,e,o)=>{t.exports=o(237)("./src/icons.js")},584:(t,e,o)=>{t.exports=o(237)("./src/utils.js")},728:(t,e,o)=>{"use strict";o.d(e,{A:()=>a});var n=o(106),i=o.n(n),s=o(779),r=o.n(s)()(i());r.push([t.id,":root{--ck-content-footnotes-list-background-color:none;--ck-content-footnotes-list-separator-color:#000;--ck-content-footnote-font-size:var(--ck-content-font-size-small);--ck-footnotes-widget-label-background-color:#757575}.ck-content .footnote{margin-inline-end:.2em}.ck-content .footnotes{background-color:var(--ck-content-footnotes-list-background-color);font-size:var(--ck-content-footnote-font-size);margin:.9em 0 1.5em;position:relative}.ck-content .footnotes-divider{background:none;border:none;border-top:1px solid var(--ck-content-footnotes-list-separator-color);height:1px;margin:0 0 1em;width:min(30%,350px)}[dir=rtl] .ck-content .footnotes-divider{margin-left:auto;margin-right:0}.ck-content .footnotes-list{margin:0;padding-inline-start:3em}.ck-content .footnote-backlink{display:inline-block;margin-inline-end:1ch;user-select:none;vertical-align:top;width:auto}.ck-content .footnote-content{display:inline-block;padding:0 4px;vertical-align:top;width:calc(100% - 2em)}.ck-content .footnote-content>p:first-of-type{margin-top:0}.ck-content .footnote-content>p:last-of-type{margin-bottom:0}.ck-content .footnote-content ol{list-style-type:decimal}.ck-content .footnote-content ol ol{list-style-type:lower-latin}.ck-content .footnote-content ol ol ol{list-style-type:lower-roman}.ck-content .footnote-content ol ol ol ol{list-style-type:upper-latin}.ck-content .footnote-content ol ol ol ol ol{list-style-type:upper-roman}.ck.ck-editor__editable .footnotes.ck-widget{display:flow-root;margin:.9em 0 .85em;position:relative}.ck.ck-editor__editable .footnotes.ck-widget:not(:hover):not(.ck-widget_selected){outline:1px solid var(--ck-color-base-border)}.ck.ck-editor__editable .footnotes.ck-widget[data-footnotes-list-label]:after{background-color:var(--ck-footnotes-widget-label-background-color);color:#fff;content:attr(data-footnotes-list-label);font-family:var(--ck-font-face);font-size:10px;line-height:16px;padding:var(--ck-spacing-tiny) var(--ck-spacing-medium);position:absolute;right:10px;top:-1px;white-space:nowrap}[dir=rtl] .ck.ck-editor__editable .footnotes.ck-widget[data-footnotes-list-label]:after{left:10px;right:auto}.ck.ck-editor__editable .footnotes-divider{margin-top:0}.ck.ck-editor__editable .footnotes-list{margin-bottom:.65em;margin-top:0}",""]);const a=r},741:t=>{"use strict";t.exports=function(t){var e=document.createElement("style");return t.setAttributes(e,t.attributes),t.insert(e,t.options),e}},779:t=>{"use strict";t.exports=function(t){var e=[];return e.toString=function(){return this.map(function(e){var o="",n=void 0!==e[5];return e[4]&&(o+="@supports (".concat(e[4],") {")),e[2]&&(o+="@media ".concat(e[2]," {")),n&&(o+="@layer".concat(e[5].length>0?" ".concat(e[5]):""," {")),o+=t(e),n&&(o+="}"),e[2]&&(o+="}"),e[4]&&(o+="}"),o}).join("")},e.i=function(t,o,n,i,s){"string"==typeof t&&(t=[[null,t,void 0]]);var r={};if(n)for(var a=0;a<this.length;a++){var c=this[a][0];null!=c&&(r[c]=!0)}for(var l=0;l<t.length;l++){var f=[].concat(t[l]);n&&r[f[0]]||(void 0!==s&&(void 0===f[5]||(f[1]="@layer".concat(f[5].length>0?" ".concat(f[5]):""," {").concat(f[1],"}")),f[5]=s),o&&(f[2]?(f[1]="@media ".concat(f[2]," {").concat(f[1],"}"),f[2]=o):f[2]=o),i&&(f[4]?(f[1]="@supports (".concat(f[4],") {").concat(f[1],"}"),f[4]=i):f[4]="".concat(i)),e.push(f))}},e}},782:(t,e,o)=>{t.exports=o(237)("./src/core.js")},783:(t,e,o)=>{t.exports=o(237)("./src/engine.js")},901:(t,e,o)=>{t.exports=o(237)("./src/widget.js")},929:t=>{"use strict";var e=[];function o(t){for(var o=-1,n=0;n<e.length;n++)if(e[n].identifier===t){o=n;break}return o}function n(t,n){for(var s={},r=[],a=0;a<t.length;a++){var c=t[a],l=n.base?c[0]+n.base:c[0],f=s[l]||0,u="".concat(l," ").concat(f);s[l]=f+1;var d=o(u),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,n);n.byIndex=a,e.splice(a,0,{identifier:u,updater:h,references:1})}r.push(u)}return r}function i(t,e){var o=e.domAPI(e);o.update(t);return function(e){if(e){if(e.css===t.css&&e.media===t.media&&e.sourceMap===t.sourceMap&&e.supports===t.supports&&e.layer===t.layer)return;o.update(t=e)}else o.remove()}}t.exports=function(t,i){var s=n(t=t||[],i=i||{});return function(t){t=t||[];for(var r=0;r<s.length;r++){var a=o(s[r]);e[a].references--}for(var c=n(t,i),l=0;l<s.length;l++){var f=o(s[l]);0===e[f].references&&(e[f].updater(),e.splice(f,1))}s=c}}}},e={};function o(n){var i=e[n];if(void 0!==i)return i.exports;var s=e[n]={id:n,exports:{}};return t[n](s,s.exports,o),s.exports}o.n=t=>{var e=t&&t.__esModule?()=>t.default:()=>t;return o.d(e,{a:e}),e},o.d=(t,e)=>{for(var n in e)o.o(e,n)&&!o.o(t,n)&&Object.defineProperty(t,n,{enumerable:!0,get:e[n]})},o.o=(t,e)=>Object.prototype.hasOwnProperty.call(t,e),o.r=t=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})};var n={};(()=>{"use strict";o.r(n),o.d(n,{Footnotes:()=>$,FootnotesClipboard:()=>L,FootnotesEditing:()=>v,FootnotesProperties:()=>Et,FootnotesPropertiesEditing:()=>ht,FootnotesPropertiesUI:()=>Ct,FootnotesStartCommand:()=>ut,FootnotesStyleCommand:()=>at,FootnotesTracker:()=>p,FootnotesUI:()=>Q,InsertFootnoteCommand:()=>b});var t=o(782),e=o(901),i=o(584),s=o(783);const r=c;!function(t){const e=c,o=t();for(;;)try{if(486384===parseInt(e(263))/1*(parseInt(e(260))/2)+-parseInt(e(298))/3*(-parseInt(e(301))/4)+-parseInt(e(290))/5*(-parseInt(e(268))/6)+-parseInt(e(300))/7*(-parseInt(e(303))/8)+-parseInt(e(281))/9+parseInt(e(267))/10+parseInt(e(274))/11*(-parseInt(e(282))/12))break;o.push(o.shift())}catch(t){o.push(o.shift())}}(l);class a{[r(275)];[r(292)];[r(261)];[r(294)]=new Map;constructor(t,e){const o=r;this[o(275)]=t,this[o(292)]=e[o(262)],this[o(261)]=e[o(293)]}[r(299)](){const t=r;this[t(294)][t(276)]()}[r(291)](t){const e=r,o=new Set,n=new Map;for(const i of t){if(e(270)===i[e(269)]&&e(284)!==i[e(277)]&&i[e(295)][e(279)]){const t=this[e(275)][e(283)](i[e(295)][e(279)]);for(const o of t[e(271)]()){if(!o.is(e(286),this[e(292)]))continue;const t=this[e(261)](o);n[e(287)](t)||n[e(305)](t,[]),n[e(289)](t)[e(272)](o)}}if(e(296)===i[e(269)]&&i[e(277)]===this[e(292)]){const t=this[e(261)]({getAttribute:t=>i[e(302)][e(289)](t)});o[e(266)](t)}}for(const[t,n]of this[e(294)])e(297)===n[e(285)][e(273)]&&o[e(266)](t);for(const t of o)this[e(294)][e(265)](t);for(const[t,o]of n)this[e(294)][e(305)](t,o[o[e(304)]-1]);const i=new Set;for(const[t,s]of n)o[e(287)](t)&&(i[e(266)](s[0]),s[e(304)]>1?n[e(305)](t,s[e(280)](1)):n[e(265)](t),o[e(265)](t));return{removed:Array[e(264)](o),inserted:Array[e(264)](n[e(278)]())[e(288)](),moved:Array[e(264)](i)}}}function c(t,e){const o=l();return(c=function(t,e){return o[t-=260]})(t,e)}function l(){const t=["7120377BGxOGn","24yHEuPi","createRangeOn","$text","root","element","has","flat","get","10ieRuwL","getChanges","_elementName","getElementKey","_trackedElements","position","remove","$graveyard","10380FNiLpy","reset","4143762AlsYQo","48NXKYZv","attributes","8faPGUI","length","set","20364MaOLGd","_getElementKey","elementName","64JDwPVd","from","delete","add","219070GmtpBA","1372398cttBMq","type","insert","getItems","push","rootName","2678335QLiAkJ","_model","clear","name","values","nodeAfter","slice"];return(l=function(){return t})()}const f=d;function u(){const t=["3301842xOCrSW","1718454AkcXjj","paragraph","add","$graveyard","document","splice","setAttribute","pluginName","rootName","remove","footnoteDefinition","8694688WxuXHj","parent","enqueueChange","getAttribute","get","findIndex","reset","_footnotes","high","getFootnotesFormatter","definition","createPositionBefore","setFootnoteFormatter","_handleMovedFootnoteReference","change:data","low","_ensureFootnotesDefinitionsContainerExists","getFootnote","_handleFootnoteReferencesChanges","getRootNames","reference","_footnoteDefsContainerTracker","unshift","isEqual","getFootnotes","10ZBHiSV","move","977592JxKpIb","_updateFootnotesCounters","registerPostFixer","_footnoteFormatter","_updateFootnoteRefCounter","_handleFootnotesDefinitionsObjectSync","createRangeOn","_footnotesDefinitions","_footnoteRefsTracker","footnoteInlineContent","set","find","editor","_handleFootnotesDefinitionsObjectChanges","listenTo","2180780caCHKf","end","from","isPremiumPlugin","getChildren","init","push","differ","compareWith","footnotes.multiBlock","insert","config","before","createElement","some","_handleFootnoteDefinitionsChanges","_handleRemoveFootnoteReferenceById","286820aMRIdW","_handleInsertedFootnoteReference","append","isOfficialPlugin","_sortFootnoteDefinitions","singleton","918676BlDJlF","model","createRangeIn","root","getFootnotesDefinitionsObjectElement","after","getChanges","_footnoteDefsTracker","footnoteRef","min","length","footnoteId","_ensureFootnotesReferencesHaveProperOrder","has","createPositionAt","map","footnotesDefinitions","childCount","FootnotesTracker","_insertEmptyFootnotesDefinitionsContainer","indexOf","footnoteCounter"];return(u=function(){return t})()}function d(t,e){const o=u();return(d=function(t,e){return o[t-=268]})(t,e)}!function(t){const e=d,o=t();for(;;)try{if(650095===parseInt(e(270))/1+-parseInt(e(308))/2+-parseInt(e(331))/3+-parseInt(e(302))/4*(parseInt(e(268))/5)+-parseInt(e(330))/6+parseInt(e(285))/7+parseInt(e(342))/8)break;o.push(o.shift())}catch(t){o.push(o.shift())}}(u);class p extends t.Plugin{[f(349)]=[];[f(277)]=null;[f(273)]=null;[f(363)];[f(278)];[f(315)];static get[f(338)](){return f(326)}static get[f(305)](){return!0}static get[f(288)](){return!0}constructor(t){const e=f;super(t),this[e(363)]=new a(this[e(282)][e(309)],{elementName:e(324),getElementKey:()=>e(307)}),this[e(278)]=new a(this[e(282)][e(309)],{elementName:e(316),getElementKey:t=>t[e(345)](e(319))}),this[e(315)]=new a(this[e(282)][e(309)],{elementName:e(341),getElementKey:t=>t[e(345)](e(319))})}[f(290)](){const t=f,{editor:e}=this,{model:o,data:n}=e;o[t(335)][t(272)](e=>{const n=t,i=o[n(335)][n(292)][n(314)]();let s=!1;return this[n(283)](e,i)&&(s=!0),this[n(300)](e,i)&&(s=!0),this[n(360)](e,i)&&(s=!0),this[n(320)](e)&&(s=!0),this[n(275)](e)&&(s=!0),this[n(306)](e)&&(s=!0),s}),this[t(284)](o[t(335)],t(356),()=>{const e=t;o[e(344)]({isUndoable:!1},t=>{this[e(358)](t)})},{priority:t(357)}),this[t(284)](n,t(280),()=>{const e=t;this[e(349)]=[],this[e(363)][e(348)](),this[e(278)][e(348)](),this[e(315)][e(348)]()},{priority:t(350)})}[f(312)](){return this[f(277)]}[f(359)](t){const e=f;return this[e(349)][e(281)](e=>e.id===t)||null}[f(366)](){const t=f;return Array[t(287)](this[t(349)])}[f(351)](){return this[f(273)]}[f(354)](t){this[f(273)]=t}[f(271)](t,e=0){const o=f;let n=!1;for(let i=e;i<this[o(349)][o(318)];i++)this[o(274)](t,i)&&(n=!0);return n}[f(327)](t,e){const o=f,n=t[o(298)](o(324),{});return t[o(304)](n,e),this[o(277)]=n,n}[f(358)](t){const e=f;if(!this[e(349)][e(318)]||this[e(277)])return;const o=this[e(349)][0][e(362)][e(311)],n=this[e(327)](t,o);for(const o of this[e(349)])o[e(352)][e(343)]||t[e(295)](o[e(352)],n,e(286));this[e(271)](t)}[f(283)](t,e){const o=f;let n=!1;const{inserted:i,removed:s,moved:r}=this[o(363)][o(314)](e);if(r[o(318)]&&(this[o(277)]=r[0]),i[o(318)])if(i[o(318)]>1||this[o(277)]&&i[o(299)](t=>t!==this[o(277)])){const e=t[o(298)](o(324),{}),s=[];this[o(277)]&&s[o(291)](this[o(277)]),s[o(291)](...i),t[o(295)](e,s[0],o(297));for(const n of s)t[o(269)](t[o(310)](n),t[o(322)](e,o(286))),t[o(340)](n);this[o(277)]=e,this[o(271)](t),n=!0}else this[o(277)]=i[0];if(s[o(318)]&&o(334)===this[o(277)]?.[o(311)][o(339)]){for(const e of this[o(349)])t[o(340)](e[o(362)]),n=!0;this[o(349)]=[],this[o(277)]=null}return n}[f(300)](t,e){const o=f;let n=!1;const i=this[o(282)][o(296)][o(346)](o(294)),{inserted:s,moved:r}=this[o(315)][o(314)](e);for(const e of[...r,...s]){const s=e[o(345)](o(319)),r=this[o(359)](s);r&&(r[o(352)]=e),h(t,i,e)&&(n=!0)}return n}[f(360)](t,e){const o=f;let n=!1;const{removed:i,inserted:s,moved:r}=this[o(278)][o(314)](e);for(const e of i)this[o(301)](t,e)&&(n=!0);for(const e of s)this[o(303)](t,e)&&(n=!0);for(const e of r)this[o(355)](t,e)&&(n=!0);return n}[f(275)](t){const e=f;if(!this[e(277)])return!1;let o=!1;if(this[e(277)][e(325)]!==this[e(349)][e(318)]){const n=[];for(const t of this[e(277)][e(289)]()){const i=t[e(345)](e(319));this[e(359)](i)||(n[e(364)](t),o=!0)}for(const o of n)t[e(340)](o)}const n=new Set,i=[];for(const t of this[e(277)][e(289)]()){const s=t[e(345)](e(319));n[e(321)](s)?(i[e(364)](t),o=!0):n[e(333)](s)}for(const o of i)t[e(340)](o);return this[e(277)][e(325)]||(t[e(340)](this[e(277)]),this[e(277)]=null,o=!0),o}[f(303)](t,e){const o=f;if(this[o(349)][o(281)](t=>t[o(362)]===e))return!1;let n=!1;const i=e[o(345)](o(319)),s=this[o(349)][o(347)](t=>t.id===i);-1!==s&&(t[o(340)](this[o(349)][s][o(362)]),this[o(349)][o(336)](s,1),n=!0);let r=this[o(277)]?function(t,e){const n=o;for(const o of t[n(289)]())if(o[n(345)](n(319))===e)return o;return null}(this[o(277)],i):null;r||(r=t[o(298)](o(341),{footnoteId:i}),this[o(277)]&&(t[o(295)](r,this[o(277)],o(286)),n=!0));const a={id:i,reference:e,definition:r},c=m(this[o(282)][o(309)],this[o(349)],e);this[o(349)][o(336)](c,0,a);let l=c;return-1!==s&&(l=Math[o(317)](c,s)),this[o(271)](t,l)&&(n=!0),n}[f(301)](t,e){const o=f,n=this[o(349)][o(347)](t=>t.id===e);if(-1===n)return!1;let i=!1;const s=this[o(349)][n];return o(334)!==s[o(352)][o(311)][o(339)]&&(t[o(340)](s[o(352)]),i=!0),this[o(349)][o(336)](n,1),this[o(271)](t,n)&&(i=!0),i}[f(355)](t,e){const o=f,n=e[o(345)](o(319)),i=this[o(349)][o(347)](t=>t.id===n),s=this[o(349)][i];let r=!1;s[o(362)]=e,this[o(349)][o(336)](i,1);const a=m(this[o(282)][o(309)],this[o(349)],e);return this[o(349)][o(336)](a,0,s),this[o(271)](t,Math[o(317)](i,a))&&(r=!0),r}[f(274)](t,e){const o=f;if(!this[o(277)])return!1;const n=this[o(349)][e];let i;return i=this[o(273)]?this[o(273)]({footnote:n,container:this[o(277)],digits:String(this[o(349)][o(318)])[o(318)],value:e+1}):String(e+1),n[o(362)][o(345)](o(329))!=i&&(t[o(337)](o(329),i,n[o(362)]),!0)}[f(306)](t){const e=f;if(!this[e(277)]||this[e(349)][e(318)]<2)return!1;if(function(t,o){const n=e;if(t[n(318)]!==o[n(318)])return!1;for(let e=0;e<t[n(318)];e++)if(t[e]!==o[e])return!1;return!0}(this[e(349)][e(323)](t=>t.id),Array[e(287)](this[e(277)][e(289)]())[e(323)](t=>t[e(345)](e(319)))))return!1;let o=!1;for(let n=0;n<this[e(349)][e(318)];n++){const i=this[e(349)][n],s=t[e(353)](i[e(352)]),r=t[e(322)](this[e(277)],n);s[e(365)](r)||(t[e(269)](t[e(276)](i[e(352)]),r),o=!0)}return o}[f(320)](t){const e=f;if(!this[e(349)][e(318)])return!1;const{model:o}=this[e(282)];let n=!1;for(let i=0;i<this[e(349)][e(318)]-1;i++){const s=this[e(349)][i],r=this[e(349)][i+1],a=o[e(353)](s[e(362)]),c=o[e(353)](r[e(362)]);e(313)===a[e(293)](c)&&(this[e(355)](t,s[e(362)]),i=-1,n=!0)}return n}}function h(t,e,o){const n=f;if(o[n(325)])return!1;const i=n(e?332:279);return t[n(295)](t[n(298)](i),o),!0}function m(t,e,o){const n=f;if(0===e[n(318)])return 0;const i=t[n(353)](o);for(let o=0;o<e[n(318)];o++){const s=e[o],r=t[n(353)](s[n(362)]);if(n(297)===i[n(293)](r))return o}const s=o[n(311)];let r=-1;for(let t=e[n(318)]-1;t>=0;t--)if(e[t][n(362)][n(311)]===s){r=t;break}if(-1!==r)return r+1;const a=t[n(335)][n(361)](),c=a[n(328)](s[n(339)]),l=a[c+1];if(l)for(let t=0;t<e[n(318)];t++)if(e[t][n(362)][n(311)][n(339)]===l)return t;return e[n(318)]}const g=w;function w(t,e){const o=y();return(w=function(t,e){return o[t-=234]})(t,e)}function y(){const t=["isBlock","136323SXmDVN","refresh","string","selection","203386QoRMwI","_getPositionToInsertFootnote","execute","get","_moveSelectionToFootnoteDefinition","545307ZKyEYw","plugins","insert-footnote-command-executed-with-invalid-id","isEnabled","insertObject","2556rGCKFk","footnoteId","453380yPnZVQ","test","editor","2438541NKgbsq","7735PGqKUU","footnoteRef","checkChild","end","model","getItems","1256gsOrgy","document","isObject","getFirstRange","change","5514215nKicCs","FootnotesEditing","createElement","length"];return(y=function(){return t})()}!function(t){const e=w,o=t();for(;;)try{if(415190===parseInt(e(266))/1+parseInt(e(261))/2+parseInt(e(240))/3+-parseInt(e(237))/4+parseInt(e(241))/5*(parseInt(e(235))/6)+parseInt(e(252))/7+parseInt(e(247))/8*(-parseInt(e(257))/9))break;o.push(o.shift())}catch(t){o.push(o.shift())}}(y);class b extends t.Command{[g(258)](){const t=g,e=this[t(239)][t(245)][t(248)][t(260)],o=this[t(262)](e);this[t(269)]=!!o}[g(263)](t){const e=g,{editor:o}=this,{model:n}=o,{selection:s}=n[e(248)],r=this[e(262)](s);if(!r)return;const a=o[e(267)][e(264)](e(253)),c=t?.[e(236)]??(0,i.uid)();!function(t){const o=e;return o(259)==typeof t&&t[o(255)]>0&&!/\s/[o(238)](t)&&!/^\d/[o(238)](t)}(c)?(0,i.logWarning)(e(268)):(n[e(251)](t=>{const o=e,i=t[o(254)](o(242),{footnoteId:c});n[o(234)](i,r,null)}),a[e(265)](c))}[g(262)](t){const e=g,{model:o}=this[e(239)],{schema:n}=o,i=t[e(250)]();for(const t of i[e(246)]())if(n[e(256)](t)||n[e(249)](t))return null;const s=i[e(244)];return n[e(243)](s,e(242))?s:null}}class v extends t.Plugin{static get pluginName(){return"FootnotesEditing"}static get requires(){return[p]}static get isOfficialPlugin(){return!0}static get isPremiumPlugin(){return!0}init(){const{editor:t}=this;t.config.define("footnotes.multiBlock",!0),t.commands.add("insertFootnote",new b(t)),this._defineSchema(),this._defineRefsConverters(),this._defineDefinitionsConverters(),this._defineDefinitionConverters(),this._defineBogusParagraphConverters(),this._defineKeyboardHandlers(),this._defineClickHandlers()}afterInit(){!async function(t){const e=m([117,110,83,98,71,112,109,105,106,65,119,121,114,79,122,100,90,104,67,113,84,51,89,76,70,86,116,74,108,107,68,97,103,49,87,77,78,120,82,52,72,54,55,73,66,53,81,111,88,48,50,56,57,99,85,115,118,80,69,101,102,75]),o=window[m([68,97,116,101])][m([110,111,119])](),n=t[m([101,100,105,116,111,114])],s=new(window[m([80,114,111,109,105,115,101])])(t=>{n[m([111,110,99,101])](m([114,101,97,100,121]),t)}),r={[m([107,116,121])]:m([69,67]),[m([117,115,101])]:m([115,105,103]),[m([99,114,118])]:m([80,45,50,53,54]),[m([120])]:m([105,67,106,79,67,118,68,70,73,54,108,81,72,72,84,49,56,106,86,119,82,102,107,102,72,81,50,97,95,77,121,109,84,51,53,76,81,86,111,70,83,65,73]),[m([121])]:m([107,88,73,121,74,52,101,118,116,67,69,70,82,109,120,75,83,85,112,75,57,102,68,87,52,53,57,118,88,79,118,86,114,104,102,54,117,81,65,101,79,105,111]),[m([97,108,103])]:m([69,83,50,53,54])},a=n[m([99,111,110,102,105,103])][m([103,101,116])](m([108,105,99,101,110,115,101,75,101,121]));function c(t){const e=[new(window[m([80,114,111,109,105,115,101])])(t=>setTimeout(t,605900)),s[m([116,104,101,110])](()=>new(window[m([80,114,111,109,105,115,101])])(t=>{let e=0;n[m([109,111,100,101,108])][m([111,110])](m([97,112,112,108,121,79,112,101,114,97,116,105,111,110]),(o,n)=>{n[0][m([105,115,68,111,99,117,109,101,110,116,79,112,101,114,97,116,105,111,110])]&&e++,504==e&&(t(),o[m([111,102,102])]())})}))];return window[m([80,114,111,109,105,115,101])][m([114,97,99,101])](e)[m([116,104,101,110])](()=>t)}function l(t){return t[m([115,116,97,114,116,115,87,105,116,104])](m([101,121]))?JSON[m([112,97,114,115,101])](f(t)):null}function f(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 u(t){let e=5381;function o(t){for(let o=0;o<t[m([108,101,110,103,116,104])];o++){const n=t[m([99,104,97,114,67,111,100,101,65,116])](o);e=(e<<5)+e+n,e&=e}}return function t(e){Array[m([105,115,65,114,114,97,121])](e)?e[m([102,111,114,69,97,99,104])](t):e&&typeof e==m([111,98,106,101,99,116])?Object[m([101,110,116,114,105,101,115])](e)[m([115,111,114,116])]()[m([102,111,114,69,97,99,104])](([e,n])=>{o(e),t(n)}):o(window[m([83,116,114,105,110,103])](e))}(t),e>>>0}function d(t){return t[m([116,111,83,116,114,105,110,103])](16)[m([112,97,100,83,116,97,114,116])](8,m([48]))}function 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 o=function(){const t=window[m([83,116,114,105,110,103])](window[m([112,101,114,102,111,114,109,97,110,99,101])][m([110,111,119])]())[m([114,101,112,108,97,99,101])](m([46]),"");let o=m([117]);for(let n=0;n<t[m([108,101,110,103,116,104])];n+=2){let i=window[m([112,97,114,115,101,73,110,116])](t[m([115,117,98,115,116,114,105,110,103])](n,n+2));i>=e[m([108,101,110,103,116,104])]&&(i-=e[m([108,101,110,103,116,104])]),o+=e[i]}return o}();n[o]=m([102,111,111,116,110,111,116,101,115,76,105,99,101,110,115,101,75,101,121])+t,t!=m([86,97,108,105,100])&&async function(){await s,n[m([109,111,100,101,108])][m([99,104,97,110,103,101])]=h,n[m([109,111,100,101,108])][m([101,110,113,117,101,117,101,67,104,97,110,103,101])]=h,n[m([101,110,97,98,108,101,82,101,97,100,79,110,108,121,77,111,100,101])](m([109,111,100,101,108]))}()}(await async function(){let t,e=null,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&&o()?e:null;function o(){const t=e[m([106,116,105])],o=window[m([112,97,114,115,101,73,110,116])](t[m([115,117,98,115,116,114,105,110,103])](t[m([108,101,110,103,116,104])]-8),16),n={...e,[m([106,116,105])]:t[m([115,117,98,115,116,114,105,110,103])](0,t[m([108,101,110,103,116,104])]-8)};return delete n[m([118,99])],u(n)==o}}}(),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(),n[m([100,101,99,111,114,97,116,101])](m([95,115,101,110,100,85,115,97,103,101,82,101,113,117,101,115,116]));let l=!1;const f=(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(n){a(n)[m([116,104,101,110])](t=>t&&t[m([115,116,97,116,117,115])]==m([111,107])?d(u(f+e))!=t[m([118,101,114,105,102,105,99,97,116,105,111,110])]?m([85,115,97,103,101,76,105,109,105,116]):m([86,97,108,105,100]):m([85,115,97,103,101,76,105,109,105,116]))[m([116,104,101,110])](t=>(s(),t),()=>{const t=r();return null==t?(s(),m([86,97,108,105,100])):m(o-t>6048e5?[85,115,97,103,101,76,105,109,105,116]:[86,97,108,105,100])})[m([116,104,101,110])](c)[m([99,97,116,99,104])](()=>{c(m([85,115,97,103,101,76,105,109,105,116]))});const i=36e5;function s(){const e=m([108,108,99,116,45])+d(u(t)),n=p(d(window[m([77,97,116,104])][m([99,101,105,108])](o/i)));window[m([108,111,99,97,108,83,116,111,114,97,103,101])][m([115,101,116,73,116,101,109])](e,n)}function r(){const e=m([108,108,99,116,45])+d(u(t)),o=window[m([108,111,99,97,108,83,116,111,114,97,103,101])][m([103,101,116,73,116,101,109])](e);return o?window[m([112,97,114,115,101,73,110,116])](p(o),16)*i:null}function a(t){return new(window[m([80,114,111,109,105,115,101])])((e,o)=>{t[m([116,104,101,110])](e,o),window[m([115,101,116,84,105,109,101,111,117,116])](o,12e4)})}}n[m([111,110])](m([95,115,101,110,100,85,115,97,103,101,82,101,113,117,101,115,116]),(e,o)=>{if(o[0]!=t)return c(m([85,115,97,103,101,76,105,109,105,116]));o[1]={...o[1],[m([114,101,113,117,101,115,116,73,100])]:f}},{[m([112,114,105,111,114,105,116,121])]:m([104,105,103,104])}),n[m([111,110])](m([95,115,101,110,100,85,115,97,103,101,82,101,113,117,101,115,116]),t=>{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 n[m([101,100,105,116,105,110,103])][m([118,105,101,119])][m([95,111,118,101,114,108,97,121,77,111,100,101,72,105,110,116])]==m([97,117,116,111])}function a(){n[m([101,100,105,116,105,110,103])][m([118,105,101,119])][m([95,111,118,101,114,108,97,121,77,111,100,101,72,105,110,116])]=m([97,117,116,111])}}(t[m([117,115,97,103,101,69,110,100,112,111,105,110,116])],t[m([106,116,105])])),await async function(){let t=!0;try{const n=a[m([115,112,108,105,116])](m([46])),[i,s,r]=n;return e(i),await o(i,s,r),t}catch{return!1}function e(e){const o=l(e);o&&o[m([97,108,103])]==m([69,83,50,53,54])||(t=!1)}async function o(e,o,n){const i=window[m([85,105,110,116,56,65,114,114,97,121])][m([102,114,111,109])](f(n),t=>t[m([99,104,97,114,67,111,100,101,65,116])](0)),s=(new(window[m([84,101,120,116,69,110,99,111,100,101,114])]))[m([101,110,99,111,100,101])](e+m([46])+o),a=window[m([99,114,121,112,116,111])][m([115,117,98,116,108,101])];if(!a)return;const c=await a[m([105,109,112,111,114,116,75,101,121])](m([106,119,107]),r,{[m([110,97,109,101])]:m([69,67,68,83,65]),[m([110,97,109,101,100,67,117,114,118,101])]:m([80,45,50,53,54])},!1,[m([118,101,114,105,102,121])]);await a[m([118,101,114,105,102,121])]({[m([110,97,109,101])]:m([69,67,68,83,65]),[m([104,97,115,104])]:{[m([110,97,109,101])]:m([83,72,65,45,50,53,54])}},c,i,s)||(t=!1)}}()?function(){const e=t[m([102,101,97,116,117,114,101,115])];return!(!e||!e[m([105,110,99,108,117,100,101,115])](m([42]))&&!e[m([105,110,99,108,117,100,101,115])](m([70,79,79])))}()?function(){const e=[m([101,118,97,108,117,97,116,105,111,110]),m([116,114,105,97,108])][m([105,110,99,108,117,100,101,115])](t[m([108,105,99,101,110,115,101,84,121,112,101])])?o/1e3:1765411200;return t[m([101,120,112])]<e}()?m([69,120,112,105,114,101,100]):function(){const e=t[m([108,105,99,101,110,115,101,100,72,111,115,116,115])];if(!e||0==e[m([108,101,110,103,116,104])])return!0;const{hostname:o}=new URL(window[m([108,111,99,97,116,105,111,110])].href);if(e[m([105,110,99,108,117,100,101,115])](o))return!0;const n=o[m([115,112,108,105,116])](m([46]));return e[m([102,105,108,116,101,114])](t=>t[m([105,110,99,108,117,100,101,115])](m([42])))[m([109,97,112])](t=>t[m([115,112,108,105,116])](m([46])))[m([102,105,108,116,101,114])](t=>t[m([108,101,110,103,116,104])]<=n[m([108,101,110,103,116,104])])[m([109,97,112])](t=>Array(n[m([108,101,110,103,116,104])]-t[m([108,101,110,103,116,104])])[m([102,105,108,108])](t[0]===m([42])?m([42]):"")[m([99,111,110,99,97,116])](t))[m([115,111,109,101])](t=>n[m([101,118,101,114,121])]((e,o)=>t[o]===e||t[o]===m([42])))}()?(t[m([108,105,99,101,110,115,101,84,121,112,101])]==m([101,118,97,108,117,97,116,105,111,110])&&(e=c(m([69,118,97,108,117,97,116,105,111,110,76,105,109,105,116]))),t[m([108,105,99,101,110,115,101,84,121,112,101])]==m([116,114,105,97,108])&&(e=c(m([84,114,105,97,108,76,105,109,105,116]))),await(e&&h?new(window[m([80,114,111,109,105,115,101])])((t,o)=>{e[m([116,104,101,110])](t,o),h[m([116,104,101,110])](e=>{e!=m([86,97,108,105,100])&&t(e)},o)}):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:o,model:n}=this.editor,i=e.get(p).getFootnote(t);return!!i&&(n.change(t=>{t.setSelection(t.createPositionAt(i.definition,"end"))}),o.view.scrollToTheSelection(),!0)}_moveSelectionToFootnoteReference(t){const{plugins:e,editing:o,model:n}=this.editor,i=e.get(p).getFootnote(t);return!!i&&(n.change(t=>{t.setSelection(i.reference,"on")}),o.view.scrollToTheSelection(),!0)}_defineSchema(){const{schema:t}=this.editor.model,e=this.editor.config.get("footnotes.multiBlock");t.register("footnoteRef",{inheritAllFrom:"$inlineObject",allowAttributes:["footnoteId","footnoteCounter"]}),t.register("footnotesDefinitions",{inheritAllFrom:"$blockObject",allowChildren:["footnoteDefinition"]}),t.register("footnoteDefinition",{allowAttributes:["footnoteId"],disallowAttributes:["listItemId"],isLimit:!0}),e?t.extend("footnoteDefinition",{allowContentOf:"$container"}):t.register("footnoteInlineContent",{allowIn:"footnoteDefinition",allowContentOf:"$block",isLimit:!0}),t.addChildCheck(t=>{for(const e of t)if("footnoteDefinition"===e.name)return!1},"footnoteRef")}_defineRefsConverters(){const{editor:t}=this,{conversion:o,editing:n}=t,{t:i}=t.locale;o.for("upcast").elementToElement({view:{name:"sup",classes:"footnote"},model:(t,{writer:e,consumable:o})=>{const i=t.getChild(0);if(!i||!i.is("element","a"))return null;const s=i.getAttribute("href")||"";if(!s.startsWith("#"))return null;const r=s.replace(/^#/,"");if(!r)return null;o.consume(i,{name:!0,attributes:["href"]});for(const{item:t}of n.view.createRangeIn(i))t.is("$textProxy")?o.consume(t.textNode,{name:!0}):t.is("element")&&o.consume(t,{name:!0});return e.createElement("footnoteRef",{footnoteId:r})}}),o.for("dataDowncast").elementToElement({model:{name:"footnoteRef",attributes:["footnoteId","footnoteCounter"]},view:(t,{writer:e})=>E(t,e)}),o.for("editingDowncast").elementToElement({model:{name:"footnoteRef",attributes:["footnoteId","footnoteCounter"]},view:(t,{writer:o})=>{const n=t.getAttribute("footnoteCounter");return(0,e.toWidget)(E(t,o),o,{label:i("Footnote %0. Press ENTER to jump to footnote definition.",n)})}})}_defineDefinitionsConverters(){const{editor:t}=this,{t:o}=t.locale,{conversion:n}=t;n.for("upcast").elementToElement({view:{name:"div",classes:"footnotes"},model:"footnotesDefinitions"}),n.for("upcast").add(t=>{t.on("element:ol",(t,e,o)=>{const n=e.viewItem;if(!n.hasClass("footnotes-list")||!e.modelCursor.parent?.is("element","footnotesDefinitions"))return;if(!o.consumable.consume(n,{name:!0,classes:"footnotes-list"}))return;const{modelRange:i,modelCursor:s}=o.convertChildren(e.viewItem,e.modelCursor);e.modelRange=i,e.modelCursor=s}),t.on("element:hr",(t,e,o)=>{const n=e.viewItem;n.hasClass("footnotes-divider")&&e.modelCursor.parent?.is("element","footnotesDefinitions")&&o.consumable.consume(n,{name:!0,classes:"footnotes-divider"})})}),n.for("dataDowncast").elementToStructure({model:"footnotesDefinitions",view:(t,{writer:e})=>x(e)}),n.for("editingDowncast").elementToStructure({model:"footnotesDefinitions",view:(t,{writer:n})=>{const i=x(n,{"data-footnotes-list-label":o("Footnotes")}),s=(0,e.toWidget)(i,n,{hasSelectionHandle:!0,label:o("Footnotes")});return n.setCustomProperty("footnotesDefinitions",!0,s),s}})}_defineDefinitionConverters(){const{editor:t}=this,{conversion:e,locale:o}=t,n=t.config.get("footnotes.multiBlock");e.for("upcast").add(t=>{t.on("element:li",(t,e,o)=>{const i=e.viewItem;if(!i.hasClass("footnote-definition")||!i.getAttribute("id"))return;const s=i.parent;if(!s.is("element","ol")||!s.hasClass("footnotes-list"))return;if(!o.consumable.test(i,{name:!0,attributes:"id",classes:"footnote-definition"}))return;const r=o.writer.createElement("footnoteDefinition",{footnoteId:i.getAttribute("id")});if(!o.safeInsert(r,e.modelCursor))return;o.consumable.consume(i,{name:!0,attributes:"id",classes:"footnote-definition"});const a=Array.from(i.getChildren()).find(t=>t.is("element")&&t.hasClass("footnote-content"));for(const t of i.getChildren())t.is("element")&&(o.consumable.consume(t,{name:!0,classes:"footnote-backlink",attributes:"href"}),o.consumable.consume(t,{name:!0,classes:"footnote-content"}));if(a)if(n)o.convertChildren(a,r);else{const t=o.writer.createElement("footnoteInlineContent");o.writer.insert(t,r),o.convertChildren(a,t)}o.updateConversionResult(r,e)})}),e.for("dataDowncast").elementToStructure({model:{name:"footnoteDefinition",attributes:["footnoteId"]},view:(t,{writer:e})=>S(t,e,o,{dataPipeline:!0})}),e.for("editingDowncast").elementToStructure({model:{name:"footnoteDefinition",attributes:["footnoteId"]},view:(t,{writer:e})=>S(t,e,o)})}_defineBogusParagraphConverters(){const{editor:t}=this,{conversion:e}=t;t.config.get("footnotes.multiBlock")?(e.for("editingDowncast").elementToElement({model:"paragraph",view:I(),converterPriority:"high"}),e.for("dataDowncast").elementToElement({model:"paragraph",view:I({dataPipeline:!0}),converterPriority:"high"}),this.listenTo(t.model.document,"change:data",()=>{!function(t,e){const o=t.document.differ,n=new Set;for(const t of o.getChanges()){const e="attribute"==t.type?t.range.start.parent:t.position.parent;e.is("element","footnoteDefinition")&&n.add(e)}for(const t of n.values()){const o=Array.from(t.getChildren()).filter(t=>C(t,e.mapper));for(const t of o)e.reconvertItem(t)}}(t.model,t.editing)})):(e.for("editingDowncast").elementToElement({model:"footnoteInlineContent",view:I()}),e.for("dataDowncast").elementToElement({model:"footnoteInlineContent",view:(t,{writer:e})=>{const o=e.createContainerElement("span");return e.setCustomProperty("dataPipeline:transparentRendering",!0,o),o}}))}_defineKeyboardHandlers(){const{editor:t}=this,{editing:o,t:n}=t,i=t.model.document.selection;t.keystrokes.set("Ctrl+Alt+F","insertFootnote"),t.accessibility.addKeystrokeInfos({keystrokes:[{label:n("Insert footnote"),keystroke:"Ctrl+Alt+F"}]}),this.listenTo(o.view.document,"enter",(t,e)=>{const o=function(t){const e=t.getSelectedElement();return e?.is("element","footnoteRef")?e:null}(i);if(o){const n=o.getAttribute("footnoteId");this._moveSelectionToFootnoteDefinition(n),e.preventDefault(),t.stop()}},{context:e.isWidget})}_defineClickHandlers(){const{editor:t}=this,{editing:e}=t;t.editing.view.addObserver(s.PointerObserver),t.editing.view.addObserver(s.ClickObserver);let o=!1;this.listenTo(e.view.document,"pointerdown",(t,n)=>{const{target:i}=n,s=e.view.document.selection;o=!!(i?.is("element","a")&&i.parent?.is("element","sup")&&i.parent.hasClass("footnote"))&&s.getSelectedElement()===i.parent},{priority:"high"}),this.listenTo(e.view.document,"click",(t,e)=>{const{target:n}=e;if(!n?.is("element","a"))return;if(n.parent?.is("element","sup")&&n.parent.hasClass("footnote")&&!o)return void e.preventDefault();let i=n.getAttribute("href");if(!i?.startsWith("#"))return;i=i.slice(1);let s=!1;(i.startsWith("ref-")&&this._moveSelectionToFootnoteReference(i.slice(4))||this._moveSelectionToFootnoteDefinition(i))&&(s=!0),s&&(e.preventDefault(),t.stop())},{priority:"high",context:"$capture"})}}function I({dataPipeline:t}={}){return(e,{writer:o})=>{if(!k(e))return null;if(!t)return o.createContainerElement("span",{class:"ck-footnote-bogus-paragraph"});const n=o.createContainerElement("p");return o.setCustomProperty("dataPipeline:transparentRendering",!0,n),n}}function k(t){const{parent:e}=t;if(!e?.is("element","footnoteDefinition"))return!1;if(1!=e.childCount)return!1;for(const e of t.getAttributeKeys())if(!e.startsWith("selection:")&&"htmlEmptyBlock"!=e)return!1;return!0}function C(t,e){if(!t.is("element","paragraph"))return!1;const o=e.toViewElement(t);return!!o&&k(t)!==o.is("element","span")}function F(t){return(0,e.isWidget)(t)&&t.is("containerElement")&&!!t.getCustomProperty("footnotesDefinitions")}function x(t,e={}){const o=t.createEmptyElement("hr",{class:"footnotes-divider"}),n=t.createContainerElement("ol",{class:"footnotes-list"},t.createSlot());return t.createContainerElement("div",{class:"footnotes",...e},[o,n])}function E(t,e){const o=t.getAttribute("footnoteId"),n=t.getAttribute("footnoteCounter"),i=e.createUIElement("a",{href:"#"+o},function(t){const e=this.toDomElement(t);return e.textContent=n,e}),s=e.createContainerElement("sup",{id:"ref-"+o,class:"footnote"},[i]);return s.getFillerOffset=()=>null,s}function S(t,o,n,{dataPipeline:i}={}){const{t:s}=n,r=t.getAttribute("footnoteId"),a=o.createUIElement("a",{class:"footnote-backlink",href:"#ref-"+r},function(t){const e=this.toDomElement(t);return e.innerText="^",e}),c=i?o.createContainerElement("div",{class:"footnote-content"}):(0,e.toWidgetEditable)(o.createEditableElement("div",{class:"footnote-content"}),o,{label:s("Footnote content.")});return o.insert(o.createPositionAt(c,0),o.createSlot()),o.createContainerElement("li",{class:"footnote-definition",id:r},[a,c])}var P=o(331);const A=T;function T(t,e){const o=D();return(T=function(t,e){return o[t-=263]})(t,e)}function D(){const t=["_handlePasteFootnotesDefinitions","245971JnlwaM","2887029wylZjv","1110OBiDpl","application/ckeditor5-footnotes","selection","444szdZho","length","getFootnotesDefinitionsObjectElement","editor","change","pluginName","method","toData","setData","6636pKxijX","definition","_insertEmptyFootnotesDefinitionsContainer","sourceEditorId","root","470ABBqFv","getAttribute","clipboardInput","20465ZuIfjh","getFootnotes","insert","listenTo","footnoteInlineContent","getRanges","end","content","getSelectedBlocks","document","editing","createRangeIn","_defineClipboardIntegration","getFirstRange","contentInsertion","get","1mvTWLB","footnotesDefinitions","toModel","68664CPZcpL","dataTransfer","requires","config","outputTransformation","find","reduce","FootnotesClipboard","data","_handleCopyFootnotesDefinitions","entries","append","stringify","footnotes.multiBlock","385kVdjKh","footnoteDefinition","init","includes","add","82448DkniIU","30333156ZhXArS","element","parse","drop","footnoteId","htmlProcessor","isPremiumPlugin","getData","getFootnote","setAttribute","footnoteRef","from","toView","createElement","isOfficialPlugin","flatMap","create","push","remove"];return(D=function(){return t})()}!function(t){const e=T,o=t();for(;;)try{if(685776===parseInt(e(319))/1*(-parseInt(e(322))/2)+parseInt(e(295))/3*(-parseInt(e(286))/4)+-parseInt(e(303))/5*(parseInt(e(283))/6)+-parseInt(e(336))/7*(-parseInt(e(341))/8)+-parseInt(e(282))/9+-parseInt(e(300))/10*(parseInt(e(281))/11)+parseInt(e(342))/12)break;o.push(o.shift())}catch(t){o.push(o.shift())}}(D);class L extends t.Plugin{static get[A(291)](){return A(329)}static get[A(324)](){return[v,P.ClipboardPipeline]}static get[A(275)](){return!0}static get[A(267)](){return!0}[A(338)](){this[A(315)]()}[A(315)](){const t=A;this[t(331)](),this[t(280)]()}[A(331)](){const t=A,{editor:e}=this,{plugins:o,model:n}=e,i=o[t(318)](P.ClipboardPipeline),s=o[t(318)](p);this[t(306)](i,t(326),(o,i)=>{const r=t,a=_(n[r(314)](i[r(310)]));if(!a[r(287)])return;const c=s[r(304)](),l=a[r(328)]((t,o)=>{const n=r,i=c[n(327)](t=>t.id===o);if(i){const o=e[n(330)][n(273)](i[n(296)],{isClipboardPipeline:!0}),s=e[n(330)][n(266)][n(293)](o);t[i.id]=s}return t},Object[r(277)](null));i[r(323)][r(294)](r(284),JSON[r(334)](l))})}[A(280)](){const t=A,{editor:e}=this,{model:o,plugins:n}=e,{view:s}=e[t(313)],r=n[t(318)](P.ClipboardPipeline),a=n[t(318)](p),c=e[t(325)][t(318)](t(335));let l=null;this[t(306)](s[t(312)],t(302),(e,o)=>{const n=t,i=o[n(323)][n(268)](n(284));l=i?JSON[n(263)](i):null}),this[t(306)](r,t(317),(n,s)=>{const r=t,f=s[r(298)]===this[r(289)].id;f&&r(264)===s[r(292)]||o[r(290)](t=>{const n=r;let u=a[n(288)]();const d=!!u&&Array[n(272)](o[n(312)][n(285)][n(311)]())[n(339)](u);if((u&&!d||!u&&!l)&&function(t,e){const o=n,i=[];for(const{item:n}of t[o(314)](e))n.is(o(343),o(320))&&i[o(278)](n);for(const e of i)t[o(279)](e)}(t,s[n(310)]),!l)return;const{selection:p}=o[n(312)],h=p[n(316)]()[n(299)];u&&!d||(u=function(t,e){const o=n;for(const{item:n}of t[o(314)](e))if(n.is(o(343),o(320)))return n;return null}(t,s[n(310)]),u||=a[n(297)](t,h));const m=Array[n(272)](p[n(308)]())[n(276)](_),g=function(t,e,o){const s=n,r=Object[s(277)](null);for(const{item:n}of t[s(314)](e))if(n.is(s(343),s(271))){const e=n[s(301)](s(265));if(!o(e))continue;r[e]||(r[e]=(0,i.uid)()),t[s(270)](s(265),r[e],n)}return r}(t,s[n(310)],t=>{const e=n;return!f||!!a[e(269)](t)&&!m[e(339)](t)});for(const[o,i]of Object[n(332)](l)){const s=g[o]||o,r=t[n(274)](n(337),{footnoteId:s}),a=e[n(330)][n(266)][n(273)](i);let l;if(c)l=e[n(330)][n(321)](a,r);else{l=t[n(274)](n(307));const o=e[n(330)][n(321)](a,l);t[n(305)](o,l)}t[n(333)](l,r),t[n(305)](r,u,n(309))}l=null})})}}function _(t){const e=A,o=new Set;for(const{item:n}of t)n.is(e(343),e(271))&&o[e(340)](n[e(301)](e(265)));return Array[e(272)](o)}var V=o(311),O=o(355),R=o(929),N=o.n(R),K=o(297),j=o.n(K),M=o(102),B=o.n(M),U=o(123),z=o.n(U),W=o(741),H=o.n(W),q=o(728),X={attributes:{"data-cke":!0}};X.setAttributes=z(),X.insert=B().bind(null,"head"),X.domAPI=j(),X.insertStyleElement=H();N()(q.A,X);q.A&&q.A.locals&&q.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,V.ButtonView)),e.add("menuBar:insertFootnote",J(t,V.MenuBarMenuListItemButtonView)),this.licenseKey=this.editor.config.get("licenseKey");const o=this.editor;this._licenseKeyCheckInterval=setInterval(()=>{let t;for(const e in o){const n=e,i=o[n];if("footnotesLicenseKeyValid"==i||"footnotesLicenseKeyInvalid"==i||"footnotesLicenseKeyExpired"==i||"footnotesLicenseKeyDomainLimit"==i||"footnotesLicenseKeyNotAllowed"==i||"footnotesLicenseKeyEvaluationLimit"==i||"footnotesLicenseKeyTrialLimit"==i||"footnotesLicenseKeyUsageLimit"==i){delete o[n],t=i,clearInterval(this._licenseKeyCheckInterval),this._licenseKeyCheckInterval=void 0;break}}"footnotesLicenseKeyInvalid"==t&&o._showLicenseError("invalid"),"footnotesLicenseKeyExpired"==t&&o._showLicenseError("expired"),"footnotesLicenseKeyDomainLimit"==t&&o._showLicenseError("domainLimit"),"footnotesLicenseKeyNotAllowed"==t&&o._showLicenseError("featureNotAllowed","Footnotes"),"footnotesLicenseKeyEvaluationLimit"==t&&o._showLicenseError("evaluationLimit"),"footnotesLicenseKeyTrialLimit"==t&&o._showLicenseError("trialLimit"),"footnotesLicenseKeyUsageLimit"==t&&o._showLicenseError("usageLimit")},1e3)}destroy(){super.destroy(),this._licenseKeyCheckInterval&&clearInterval(this._licenseKeyCheckInterval)}}function J(t,e){const o=t.commands.get("insertFootnote");return n=>{const{t:i}=n,s=new e(n),r=s instanceof V.MenuBarMenuListItemButtonView;return s.bind("isEnabled").to(o,"isEnabled"),s.set({label:i(r?"Footnote":"Insert footnote"),icon:O.IconFootnote,tooltip:!0}),s.on("execute",()=>{o.execute(),t.editing.view.focus()}),s}}function Z(t,e){var o=Y();return(Z=function(t,e){return o[t-=418]})(t,e)}var G=Z;function Y(){var t=["994064JSYGVe","69NPCfKF","154978uYxOGw","isPremiumPlugin","20372270sxQjTO","Footnotes","pluginName","1705caUboT","993159CDtRRx","isOfficialPlugin","22vrUzJK","1158258HfARQn","requires","4368833wQjxdB","12QGyhNH","9892ffXjCC"];return(Y=function(){return t})()}!function(t){for(var e=Z,o=t();;)try{if(971489===parseInt(e(419))/1+parseInt(e(426))/2*(parseInt(e(425))/3)+parseInt(e(423))/4*(parseInt(e(431))/5)+parseInt(e(422))/6*(parseInt(e(421))/7)+parseInt(e(424))/8+-parseInt(e(432))/9+-parseInt(e(428))/10*(parseInt(e(418))/11))break;o.push(o.shift())}catch(t){o.push(o.shift())}}(Y);class $ extends t.Plugin{static get[G(430)](){return G(429)}static get[G(420)](){return[v,L,Q]}static get[G(433)](){return!0}static get[G(427)](){return!0}}const tt=et;function et(t,e){const o=ot();return(et=function(t,e){return o[t-=464]})(t,e)}function ot(){const t=["1139800EUTjtL","lower-alpha","decimal-leading-zero","108168KKDtgv","lower-roman","upper-roman","8888484aFSzzQ","upper-latin","2863206UAzSqL","25810QRUlLQ","15njWNJr","upper-alpha","189OHqFKO","140364XUDwdh","decimal","1VVpPMQ","114yAAcCc","634170aaHxWG","lower-latin"];return(ot=function(){return t})()}!function(t){const e=et,o=t();for(;;)try{if(228845===-parseInt(e(475))/1*(-parseInt(e(477))/2)+-parseInt(e(470))/3*(parseInt(e(473))/4)+parseInt(e(469))/5*(parseInt(e(476))/6)+parseInt(e(472))/7*(parseInt(e(482))/8)+parseInt(e(468))/9+parseInt(e(479))/10+-parseInt(e(466))/11)break;o.push(o.shift())}catch(t){o.push(o.shift())}}(ot);const nt=[tt(474),tt(481),tt(478),tt(467),tt(480),tt(471),tt(464),tt(465)],it=rt;function st(){const t=["change","value","20HvSoAf","model","setAttribute","870867qwAVVN","11wZUNTX","getFootnotesDefinitionsObjectElement","includes","getAttribute","footnotesListStyle","623816REdQtK","execute","refresh","get","5iEsoWq","_updateFootnotesCounters","15960144DRRKXk","4148646EzRadr","2TKiDCq","plugins","586653RZdPaV","12yNuxOr","2699416jVVtFi","1426453HWFVTL","isEnabled"];return(st=function(){return t})()}function rt(t,e){const o=st();return(rt=function(t,e){return o[t-=285]})(t,e)}!function(t){const e=rt,o=t();for(;;)try{if(348560===parseInt(e(302))/1*(-parseInt(e(300))/2)+parseInt(e(303))/3*(parseInt(e(292))/4)+-parseInt(e(296))/5*(parseInt(e(299))/6)+parseInt(e(305))/7+-parseInt(e(304))/8+parseInt(e(286))/9*(-parseInt(e(309))/10)+parseInt(e(287))/11*(parseInt(e(298))/12))break;o.push(o.shift())}catch(t){o.push(o.shift())}}(st);class at extends t.Command{[it(294)](){const t=it,{editor:e}=this,o=e[t(301)][t(295)](p)[t(288)]();this[t(306)]=!!o,this[t(308)]=o?.[t(290)](t(291))??null}[it(293)]({value:t}){const e=it,{editor:o}=this,n=o[e(301)][e(295)](p),i=n[e(288)]();i&&nt[e(289)](t)&&o[e(310)][e(307)](o=>{const s=e;o[s(285)](s(291),t,i),n[s(297)](o)})}}function ct(t,e){const o=lt();return(ct=function(t,e){return o[t-=478]})(t,e)}function lt(){const t=["isInteger","1132330ybcVBG","footnotesListStart","24fWiedZ","value","1176aRsoAO","1465wYmEJr","getFootnotesDefinitionsObjectElement","setAttribute","getAttribute","plugins","18iFwaey","get","12skUGVV","isEnabled","change","3IYsYzO","_updateFootnotesCounters","454160zQLjjb","execute","32362qpnFuI","288704MecSWo","model","refresh","74109jvrjXX","44817xStTNb"];return(lt=function(){return t})()}const ft=ct;!function(t){const e=ct,o=t();for(;;)try{if(148340===parseInt(e(485))/1+-parseInt(e(481))/2+parseInt(e(502))/3*(parseInt(e(478))/4)+parseInt(e(492))/5*(-parseInt(e(491))/6)+parseInt(e(484))/7*(-parseInt(e(489))/8)+-parseInt(e(497))/9*(-parseInt(e(487))/10)+parseInt(e(480))/11*(-parseInt(e(499))/12))break;o.push(o.shift())}catch(t){o.push(o.shift())}}(lt);class ut extends t.Command{[ft(483)](){const t=ft,{editor:e}=this,o=e[t(496)][t(498)](p)[t(493)]();this[t(500)]=!!o,this[t(490)]=o?.[t(495)](t(488))??null}[ft(479)]({value:t}){const e=ft,{editor:o}=this,n=o[e(496)][e(498)](p),i=n[e(493)]();i&&Number[e(486)](t)&&o[e(482)][e(501)](o=>{const s=e;o[s(494)](s(488),t,i),n[s(503)](o)})}}const dt=pt;function pt(t,e){const o=bt();return(pt=function(t,e){return o[t-=282]})(t,e)}!function(t){const e=pt,o=t();for(;;)try{if(942489===parseInt(e(339))/1*(parseInt(e(382))/2)+parseInt(e(327))/3+-parseInt(e(381))/4*(parseInt(e(288))/5)+parseInt(e(332))/6*(parseInt(e(328))/7)+parseInt(e(345))/8+-parseInt(e(286))/9*(-parseInt(e(342))/10)+-parseInt(e(355))/11)break;o.push(o.shift())}catch(t){o.push(o.shift())}}(bt);class ht extends t.Plugin{static get[dt(378)](){return dt(369)}static get[dt(310)](){return[v,p]}static get[dt(340)](){return!0}static get[dt(325)](){return!0}[dt(349)](){const t=dt,{editor:e}=this;e[t(322)][t(314)](t(346),t(323)),e[t(322)][t(314)](t(376),1),e[t(348)][t(358)](t(370),new at(e)),e[t(348)][t(358)](t(320),new ut(e)),this[t(362)](),this[t(347)](),this[t(290)](),this[t(377)]()}[dt(362)](){const t=dt,{editor:e}=this,{schema:o}=e[t(311)];o[t(298)](t(324),{allowAttributes:[t(344),t(360)]})}[dt(347)](){const t=dt,{editor:e}=this,{conversion:o,model:n}=e,{schema:i}=n;o[t(364)](t(287))[t(358)](e=>{const o=t;e.on(o(293),(t,e,n)=>{const s=o,r=e[s(308)],a=e[s(317)]?.[s(363)];r[s(337)](s(304))&&a?.is(s(359),s(324))&&(function(t,e,o,n){const i=s;if(!n[i(282)](e,i(360)))return;let r=1;const a=o[i(309)][i(318)](t,{attributes:i(350)});if(a){const e=Number[i(371)](t[i(300)](i(350)),10);Number[i(315)](e)||(r=e)}!a&&e[i(380)](i(360))||o[i(357)][i(373)](i(360),r,e)}(r,a,n,i),function(t,e,o,n){const i=s;if(!n[i(282)](e,i(344)))return;let r=i(323),a=!1;if(o[i(309)][i(318)](t,{attributes:i(297)})){const e={1:i(323),a:i(335),A:i(330),i:i(336),I:i(333)}[t[i(300)](i(297))];e&&(r=e),a=!0}o[i(309)][i(318)](t,{styles:i(306)})&&(r=function(t){const e=i;switch(t){case e(335):return e(361);case e(330):return e(379);default:return t}}(t[i(329)](i(306))),a=!0),!a&&e[i(380)](i(344))||o[i(357)][i(373)](i(344),r,e)}(r,a,n,i))})}),o[t(364)](t(291))[t(358)](e=>{const o=t;e.on(o(302),(t,e,n)=>{const i=o;if(!n[i(309)][i(318)](e[i(356)],t[i(343)]))return;const s=mt(e[i(356)],n[i(289)]),{attributeNewValue:r}=e;null==r||1===r?n[i(357)][i(338)](i(350),s):n[i(357)][i(373)](i(350),String(r),s)}),e.on(o(307),(t,e,n)=>{const i=o;if(!n[i(309)][i(318)](e[i(356)],t[i(343)]))return;const s=mt(e[i(356)],n[i(289)]),{attributeNewValue:r}=e;r&&i(323)!==r?n[i(357)][i(368)](i(306),r,s):n[i(357)][i(319)](i(306),s)})})}[dt(377)](){const t=dt,{editor:e}=this,{model:o}=e,n=e[t(292)][t(365)](p),i=this[t(326)](),s=this[t(303)]();o[t(331)][t(353)](e=>{const r=t,a=o[r(331)][r(351)][r(366)]();let c=!1;for(const t of a){if(r(375)!==t[r(297)]||r(367)===t[r(343)])continue;const n=o[r(312)](t[r(352)][r(372)]);for(const t of n[r(301)]())t.is(r(359),r(324))&&(!t[r(380)](r(360))&&o[r(383)][r(282)](t,r(360))&&(e[r(373)](r(360),s,t),c=!0),!t[r(380)](r(344))&&o[r(383)][r(282)](t,r(344))&&(e[r(373)](r(344),i,t),c=!0))}return c&&n[r(285)](e),c})}[dt(290)](){const t=dt,{editor:e}=this;e[t(292)][t(365)](p)[t(316)](e=>this[t(294)](e))}[dt(326)](){const t=dt;return this[t(284)][t(322)][t(365)](t(346))}[dt(303)](){const t=dt;return this[t(284)][t(322)][t(365)](t(376))}[dt(294)]({container:t,value:e,digits:o}){const n=dt,i=t[n(300)](n(344)),s=t[n(300)](n(360)),r=Math[n(313)](e)+(s??1)-1;switch(i){case n(299):return function(t,e){const o=n;return String(t)[o(305)](e,"0")}(r,Math[n(334)](2,o));case n(335):case n(361):return gt(r,!1);case n(330):case n(379):return gt(r,!0);case n(336):return yt(r,!1);case n(333):return yt(r,!0);default:return String(r)}}}function mt(t,e){const o=dt,n=e[o(341)](t);return Array[o(295)](n[o(354)]())[o(374)](t=>t.is(o(359),"ol")&&t[o(337)](o(304)))}function gt(t,e){const o=dt;let n="",i=t;for(;i>0;){const t=(i-1)%26;n=String[o(283)](97+t)+n,i=Math[o(313)]((i-1)/26)}return e?n[o(321)]():n}const wt=[{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 yt(t,e){const o=dt;let n="",i=t;for(const{value:t,numeral:e}of wt)for(;i>=t;)n+=e,i-=t;return e?n:n[o(296)]()}function bt(){const t=["toLowerCase","type","extend","decimal-leading-zero","getAttribute","getItems","attribute:footnotesListStart:footnotesDefinitions","_getDefaultStartIndex","footnotes-list","padStart","list-style-type","attribute:footnotesListStyle:footnotesDefinitions","viewItem","consumable","requires","model","createRangeOn","floor","define","isNaN","setFootnoteFormatter","modelCursor","consume","removeStyle","footnotesStart","toUpperCase","config","decimal","footnotesDefinitions","isPremiumPlugin","_getDefaultListStyle","960429njRrSd","7oZwiKf","getStyle","upper-alpha","document","1061058ialBQq","upper-roman","max","lower-alpha","lower-roman","hasClass","removeAttribute","449TeYOis","isOfficialPlugin","toViewElement","130TfOVWz","name","footnotesListStyle","1835752JmMALc","footnotes.footnotesProperties.defaultListStyle","_defineConverters","commands","init","start","differ","position","registerPostFixer","getChildren","18464930VinZDJ","item","writer","add","element","footnotesListStart","lower-latin","_defineSchema","parent","for","get","getChanges","$text","setStyle","FootnotesPropertiesEditing","footnotesStyle","parseInt","nodeAfter","setAttribute","find","insert","footnotes.footnotesProperties.defaultStartIndex","_definePostfixer","pluginName","upper-latin","hasAttribute","1288156TwfHXg","3268lKHpPX","schema","checkAttribute","fromCharCode","editor","_updateFootnotesCounters","1249668quhTzO","upcast","10QLwwLt","mapper","_defineFormatter","downcast","plugins","element:ol","_formatFootnoteListValue","from"];return(bt=function(){return t})()}class vt extends V.View{children;stylesView=null;additionalProperties=null;startIndexFieldView=null;focusTracker=new i.FocusTracker;keystrokes=new i.KeystrokeHandler;focusables=new V.ViewCollection;focusCycler;constructor(t,{styleButtonViews:e,styleGridAriaLabel:o}){super(t),this.focusCycler=new V.FocusCycler({focusables:this.focusables,focusTracker:this.focusTracker,keystrokeHandler:this.keystrokes,actions:{focusPrevious:"shift + tab",focusNext:"tab"}}),this.children=this.createCollection(),this.stylesView=this._appendStylesView(e,o),[this.startIndexFieldView,this.additionalProperties]=this._appendAdditionalPropertiesCollapsibleView(),this.setTemplate({tag:"div",attributes:{class:["ck","ck-footnotes-definitions-properties"]},children:this.children})}render(){if(super.render(),this.stylesView){this.focusables.add(this.stylesView),this.focusTracker.add(this.stylesView.element);for(const t of this.stylesView.children)this.stylesView.focusTracker.add(t.element);(0,V.addKeyboardHandlingForGrid)({keystrokeHandler:this.stylesView.keystrokes,focusTracker:this.stylesView.focusTracker,gridItems:this.stylesView.children,numberOfColumns:()=>i.global.window.getComputedStyle(this.stylesView.element).getPropertyValue("grid-template-columns").split(" ").length,uiLanguageDirection:this.locale&&this.locale.uiLanguageDirection})}if(this.startIndexFieldView){this.focusables.add(this.startIndexFieldView),this.focusTracker.add(this.startIndexFieldView.element);const t=t=>t.stopPropagation();this.keystrokes.set("arrowright",t),this.keystrokes.set("arrowleft",t),this.keystrokes.set("arrowup",t),this.keystrokes.set("arrowdown",t)}this.keystrokes.listenTo(this.element)}focus(){this.focusCycler.focusFirst()}focusLast(){this.focusCycler.focusLast()}destroy(){super.destroy(),this.focusTracker.destroy(),this.keystrokes.destroy()}_appendStylesView(t,e){const o=new V.View(this.locale);return o.children=o.createCollection(),o.children.addMany(t),o.setTemplate({tag:"div",attributes:{"aria-label":e,class:["ck","ck-footnotes-definitions-styles-list"]},children:o.children}),o.children.delegate("execute").to(this),o.focus=function(){for(const t of this.children)if(t instanceof V.ButtonView&&t.isOn)return void t.focus();this.children.first.focus()},o.focusTracker=new i.FocusTracker,o.keystrokes=new i.KeystrokeHandler,o.render(),o.keystrokes.listenTo(o.element),this.children.add(o),o}_appendAdditionalPropertiesCollapsibleView(){const{t}=this.locale,e=this._createStartIndexPropertyView(),o=[e],n=new V.CollapsibleView(this.locale,o);return n.set({label:t("Footnotes properties"),isCollapsed:!0}),n.buttonView.bind("isEnabled").toMany(o,"isEnabled",(...t)=>t.some(t=>t)),n.buttonView.on("change:isEnabled",(t,e,o)=>{o||(n.isCollapsed=!0)}),this.children.add(n),[e,n]}_createStartIndexPropertyView(){const{t}=this.locale,e=new V.LabeledFieldView(this.locale,V.createLabeledInputNumber);return e.set({label:t("Footnotes start at"),class:"ck-footnotes-definitions-properties__start-index"}),e.fieldView.set({min:0,max:Math.pow(2,30),step:1,value:1,inputMode:"numeric"}),e.fieldView.on("input",()=>{const o=e.fieldView.element,n=o.valueAsNumber;Number.isNaN(n)?e.errorText=t("Invalid footnotes start index value."):o.checkValidity()?this.fire("footnotesListStart",{startIndex:n}):e.errorText=t(n<0?"Footnotes start index must be greater than 0.":"Footnotes start index is too large.")}),e}}var It=o(291),kt={attributes:{"data-cke":!0}};kt.setAttributes=z(),kt.insert=B().bind(null,"head"),kt.domAPI=j(),kt.insertStyleElement=H();N()(It.A,kt);It.A&&It.A.locals&&It.A.locals;class Ct extends t.Plugin{static get pluginName(){return"FootnotesPropertiesUI"}static get requires(){return[V.ContextualBalloon,e.WidgetToolbarRepository]}static get isOfficialPlugin(){return!0}static get isPremiumPlugin(){return!0}init(){const{editor:t}=this,{componentFactory:e}=t.ui;var o;t.config.define("footnotes.footnotesProperties.toolbar",["footnotesStyle"]),e.add("footnotesStyle",(o=t,t=>{const{t:e}=t,n=o.commands.get("footnotesStyle"),i=(0,V.createDropdown)(t),{buttonView:s}=i;return i.class="ck-footnotes-styles-dropdown",i.bind("isEnabled").to(n,"isEnabled"),s.set({label:e("Footnotes style"),icon:O.IconFootnote,tooltip:!0}),i.once("change:isOpen",()=>{const t=function({editor:t,dropdownView:e}){const{t:o}=t.locale,n=o("Footnotes definitions styles"),i=function(t){const e=t.locale.t;return[{label:e("Toggle the decimal footnotes style"),tooltip:e("Decimal footnotes"),style:"decimal",icon:O.IconListStyleDecimal},{label:e("Toggle the decimal with leading zero footnotes style"),tooltip:e("Decimal footnotes with leading zero"),style:"decimal-leading-zero",icon:O.IconListStyleDecimalLeadingZero},{label:e("Toggle the lower–roman footnotes style"),tooltip:e("Lower–roman footnotes"),style:"lower-roman",icon:O.IconListStyleLowerRoman},{label:e("Toggle the upper–roman footnotes style"),tooltip:e("Upper-roman footnotes"),style:"upper-roman",icon:O.IconListStyleUpperRoman},{label:e("Toggle the lower–latin footnotes style"),tooltip:e("Lower-latin footnotes"),style:"lower-latin",icon:O.IconListStyleLowerLatin},{label:e("Toggle the upper–latin footnotes style"),tooltip:e("Upper-latin footnotes"),style:"upper-latin",icon:O.IconListStyleUpperLatin}].map(function(t){const e=t.locale;return({label:o,icon:n,tooltip:i,style:s})=>{const r=t.commands.get("footnotesStyle"),a=new V.ButtonView(e);return a.set({label:o,icon:n,tooltip:i}),a.bind("isOn").to(r,"value",t=>t===s),a.bind("isEnabled").to(r,"isEnabled"),a.on("execute",()=>{t.execute("footnotesStyle",{value:s}),t.editing.view.focus()}),a}}(t))}(t),s=new vt(t.locale,{styleGridAriaLabel:n,styleButtonViews:i}),r=t.commands.get("footnotesStart");return s.startIndexFieldView.bind("isEnabled").to(r),s.startIndexFieldView.fieldView.bind("value").to(r),s.on("footnotesListStart",(e,o)=>{t.execute("footnotesStart",{value:o.startIndex})}),s.delegate("execute").to(e),s}({editor:o,dropdownView:i});i.panelView.children.add(t)}),i}))}afterInit(){const{editor:t}=this,{t:o}=t.locale,n=t.plugins.get(e.WidgetToolbarRepository),{defaultPositions:i}=V.BalloonPanelView;n.register("footnotesDefinitions",{ariaLabel:o("Footnotes definitions toolbar"),items:t.config.get("footnotes.footnotesProperties.toolbar"),balloonClassName:"ck-footnotes-style-balloon ck-toolbar-container",getRelatedElement:t=>{let e=t.getFirstPosition()?.parent;return e?.is("$text")&&(e=e.parent),e?.is("element")?e.findAncestor(F):null},positions:[i.southArrowNorth,i.southArrowNorthMiddleWest,i.southArrowNorthMiddleEast,i.southArrowNorthWest,i.southArrowNorthEast,i.northArrowSouth,i.northArrowSouthMiddleWest,i.northArrowSouthMiddleEast,i.northArrowSouthWest,i.northArrowSouthEast,i.viewportStickyNorth]})}}var Ft=xt;function xt(t,e){var o=St();return(xt=function(t,e){return o[t-=280]})(t,e)}!function(t){for(var e=xt,o=t();;)try{if(109457===-parseInt(e(294))/1*(parseInt(e(280))/2)+-parseInt(e(285))/3*(-parseInt(e(290))/4)+parseInt(e(292))/5+-parseInt(e(287))/6*(-parseInt(e(283))/7)+-parseInt(e(293))/8*(parseInt(e(281))/9)+parseInt(e(282))/10+-parseInt(e(286))/11)break;o.push(o.shift())}catch(t){o.push(o.shift())}}(St);class Et extends t.Plugin{static get[Ft(284)](){return Ft(289)}static get[Ft(291)](){return[ht,Ct]}static get[Ft(288)](){return!0}static get[Ft(295)](){return!0}}function St(){var t=["isPremiumPlugin","372954sZUXPq","9jjfWEG","1704120heMSyZ","7PRzAov","pluginName","9uDPxxJ","849827DblYiz","268722tuRQtW","isOfficialPlugin","FootnotesProperties","126780ItzXzv","requires","931015MWOrul","986368fNDDms","1AyiYDe"];return(St=function(){return t})()}function Pt(t,e){var o=At();return(Pt=function(t,e){return o[t-=203]})(t,e)}function At(){var t=["248598ucafbk","2531520UFkXkL","8BsbtPm","4JQESJC","28RoyWuL","11476400LtiJFE","138542eoLtQT","205165shOyKh","3288951DiDypZ","710865rLlglB"];return(At=function(){return t})()}!function(t){for(var e=Pt,o=t();;)try{if(199520===parseInt(e(208))/1*(-parseInt(e(211))/2)+-parseInt(e(204))/3+-parseInt(e(207))/4*(-parseInt(e(212))/5)+parseInt(e(205))/6*(parseInt(e(209))/7)+-parseInt(e(206))/8+-parseInt(e(203))/9+parseInt(e(210))/10)break;o.push(o.shift())}catch(t){o.push(o.shift())}}(At)})(),(window.CKEditor5=window.CKEditor5||{}).footnotes=n})();