{"version":3,"file":"ckeditor.js","sources":["webpack://ClassicEditor/ckeditor.js"],"sourcesContent":["/*!\n * @license Copyright (c) 2003-2021, CKSource - Frederico Knabben. All rights reserved.\n * For licensing, see LICENSE.md.\n */\n(function(t){const e=t[\"ko\"]=t[\"ko\"]||{};e.dictionary=Object.assign(e.dictionary||{},{\"%0 of %1\":\"0% / %1\",\"Align cell text to the bottom\":\"\",\"Align cell text to the center\":\"\",\"Align cell text to the left\":\"\",\"Align cell text to the middle\":\"\",\"Align cell text to the right\":\"\",\"Align cell text to the top\":\"\",\"Align center\":\"가운데 정렬\",\"Align left\":\"왼쪽 정렬\",\"Align right\":\"오른쪽 정렬\",\"Align table to the left\":\"\",\"Align table to the right\":\"\",Alignment:\"\",Aquamarine:\"연한 청록색\",Background:\"\",Big:\"큰\",Black:\"검은색\",\"Block quote\":\"인용 단락\",Blue:\"파랑색\",\"Blue marker\":\"파란색 마커\",Bold:\"굵게\",Border:\"\",\"Bulleted List\":\"불릿 목록\",\"Bulleted list styles toolbar\":\"\",Cancel:\"취소\",\"Cell properties\":\"\",\"Center table\":\"\",\"Centered image\":\"가운데 정렬\",\"Change image text alternative\":\"대체 문구 변경\",\"Character categories\":\"\",\"Characters: %0\":\"문자 수: %0\",\"Choose heading\":\"제목 선택\",Circle:\"\",Code:\"코드\",Color:\"\",\"Color picker\":\"\",Column:\"\",\"Copyright sign\":\"\",Dashed:\"\",Decimal:\"\",\"Decimal with leading zero\":\"\",\"Decrease indent\":\"들여쓰기 줄이기\",Default:\"기본\",\"Delete column\":\"\",\"Delete row\":\"\",\"Dim grey\":\"진한 회색\",Dimensions:\"\",Disc:\"\",\"Document colors\":\"문서 색깔들\",Dotted:\"\",Double:\"\",\"Double dagger\":\"\",\"Double exclamation mark\":\"\",\"Double low-9 quotation mark\":\"\",\"Double question mark\":\"\",Downloadable:\"다운로드 가능\",\"Dropdown toolbar\":\"드롭다운 툴바\",\"Edit block\":\"편집 영역\",\"Edit link\":\"링크 편집\",\"Editor toolbar\":\"에디터 툴바\",\"Exclamation question mark\":\"\",\"Font Background Color\":\"글자 배경 색깔\",\"Font Color\":\"글자 색깔\",\"Font Family\":\"글꼴 집합\",\"Font Size\":\"글자 크기\",\"Full size image\":\"꽉 찬 크기\",Green:\"초록색\",\"Green marker\":\"초록색 마커\",\"Green pen\":\"초록색 펜\",Grey:\"회색\",Groove:\"\",\"Header column\":\"\",\"Header row\":\"\",Heading:\"제목\",\"Heading 1\":\"제목 1\",\"Heading 2\":\"제목 2\",\"Heading 3\":\"제목 3\",\"Heading 4\":\"제목 4\",\"Heading 5\":\"제목 5\",\"Heading 6\":\"제목 6\",Height:\"\",Highlight:\"강조\",\"Horizontal ellipsis\":\"\",\"Horizontal line\":\"수평선\",\"Horizontal text alignment toolbar\":\"\",Huge:\"매우 큰\",\"Image resize list\":\"사진 크기 목록\",\"Image toolbar\":\"사진 툴바\",\"image widget\":\"사진 위젯\",\"Increase indent\":\"들여쓰기 늘리기\",Insert:\"\",\"Insert code block\":\"코드 블럭 삽입\",\"Insert column left\":\"\",\"Insert column right\":\"\",\"Insert image\":\"사진 삽입\",\"Insert image via URL\":\"\",\"Insert media\":\"미디어 삽입\",\"Insert paragraph after block\":\"\",\"Insert paragraph before block\":\"\",\"Insert row above\":\"\",\"Insert row below\":\"\",\"Insert table\":\"테이블 삽입\",Inset:\"\",\"Inverted exclamation mark\":\"\",\"Inverted question mark\":\"\",Italic:\"기울임꼴\",Justify:\"양쪽 정렬\",\"Justify cell text\":\"\",\"Left aligned image\":\"왼쪽 정렬\",\"Left double quotation mark\":\"\",\"Left single quotation mark\":\"\",\"Left-pointing double angle quotation mark\":\"\",\"Light blue\":\"연한 파랑색\",\"Light green\":\"밝은 초록색\",\"Light grey\":\"밝은 회색\",Link:\"링크\",\"Link image\":\"사진 링크\",\"Link URL\":\"링크 주소\",\"Lower-latin\":\"\",\"Lower–roman\":\"\",\"Media toolbar\":\"미디어 툴바\",\"Media URL\":\"미디어 URL\",\"media widget\":\"미디어 위젯\",\"Merge cell down\":\"\",\"Merge cell left\":\"\",\"Merge cell right\":\"\",\"Merge cell up\":\"\",\"Merge cells\":\"\",Next:\"다음\",None:\"\",\"Numbered List\":\"번호 목록\",\"Numbered list styles toolbar\":\"\",\"Open in a new tab\":\"새 탭에서 열기\",\"Open link in new tab\":\"새 탭에서 링크 열기\",Orange:\"주황색\",Original:\"원본\",Outset:\"\",Padding:\"\",\"Page break\":\"페이지 나누기\",Paragraph:\"문단\",\"Paragraph sign\":\"\",\"Paste the media URL in the input.\":\"미디어의 URL을 입력해주세요.\",\"Per mille sign\":\"\",\"Per ten thousand sign\":\"\",\"Pink marker\":\"분홍색 마커\",\"Plain text\":\"평문\",Previous:\"이전\",Purple:\"보라색\",\"Question exclamation mark\":\"\",Red:\"빨간색\",\"Red pen\":\"빨간색 펜\",Redo:\"다시 실행\",\"Registered sign\":\"\",\"Remove color\":\"색깔 제거\",\"Remove Format\":\"서식 지우기\",\"Remove highlight\":\"강조 제거\",\"Resize image\":\"사진 크기 조절\",\"Resize image to %0\":\"사진의 크기를 %0으로 조절\",\"Resize image to the original size\":\"사진을 원래 크기로 돌려놓기\",\"Reversed paragraph sign\":\"\",\"Rich Text Editor\":\"리치 텍스트 편집기\",\"Rich Text Editor, %0\":\"리치 텍스트 편집기, %0\",Ridge:\"\",\"Right aligned image\":\"오른쪽 정렬\",\"Right double quotation mark\":\"\",\"Right single quotation mark\":\"\",\"Right-pointing double angle quotation mark\":\"\",Row:\"\",Save:\"저장\",\"Section sign\":\"\",\"Select all\":\"전체 선택\",\"Select column\":\"\",\"Select row\":\"\",\"Show more items\":\"더보기\",\"Side image\":\"본문 옆에 배치\",\"Single left-pointing angle quotation mark\":\"\",\"Single low-9 quotation mark\":\"\",\"Single right-pointing angle quotation mark\":\"\",Small:\"작은\",Solid:\"\",\"Special characters\":\"특수 문자\",\"Split cell horizontally\":\"\",\"Split cell vertically\":\"\",Square:\"\",Style:\"\",\"Table alignment toolbar\":\"\",\"Table cell text alignment\":\"\",\"Table properties\":\"\",\"Table toolbar\":\"\",\"Text alignment\":\"텍스트 정렬\",\"Text alignment toolbar\":\"텍스트 정렬 툴바\",\"Text alternative\":\"대체 문구\",\"Text highlight toolbar\":\"글자 강조 툴바\",'The color is invalid. Try \"#FF0000\" or \"rgb(255,0,0)\" or \"red\".':\"\",\"The URL must not be empty.\":\"URL이 비어있을 수 없습니다.\",'The value is invalid. Try \"10px\" or \"2em\" or simply \"2\".':\"\",\"This link has no URL\":\"이 링크에는 URL이 없습니다.\",\"This media URL is not supported.\":\"이 미디어 URL은 지원되지 않습니다.\",Tiny:\"매우 작은\",\"Tip: Paste the URL into the content to embed faster.\":\"팁: URL을 붙여넣기하면 더 빨리 삽입할 수 있습니다.\",\"To-do List\":\"확인 목록\",\"Toggle the circle list style\":\"\",\"Toggle the decimal list style\":\"\",\"Toggle the decimal with leading zero list style\":\"\",\"Toggle the disc list style\":\"\",\"Toggle the lower–latin list style\":\"\",\"Toggle the lower–roman list style\":\"\",\"Toggle the square list style\":\"\",\"Toggle the upper–latin list style\":\"\",\"Toggle the upper–roman list style\":\"\",\"Trade mark sign\":\"\",Turquoise:\"청록색\",\"Two dot leader\":\"\",Underline:\"밑줄\",Undo:\"실행 취소\",Unlink:\"링크 삭제\",Update:\"\",\"Update image URL\":\"\",\"Upload failed\":\"업로드 실패\",\"Upload in progress\":\"업로드 진행 중\",\"Upper-latin\":\"\",\"Upper-roman\":\"\",\"Vertical text alignment toolbar\":\"\",White:\"흰색\",\"Widget toolbar\":\"위젯 툴바\",Width:\"\",\"Words: %0\":\"단어 수: %0\",Yellow:\"노랑색\",\"Yellow marker\":\"노란색 마커\"});e.getPluralForm=function(t){return 0}})(window.CKEDITOR_TRANSLATIONS||(window.CKEDITOR_TRANSLATIONS={}));(function t(e,n){if(typeof exports===\"object\"&&typeof module===\"object\")module.exports=n();else if(typeof define===\"function\"&&define.amd)define([],n);else if(typeof exports===\"object\")exports[\"ClassicEditor\"]=n();else e[\"ClassicEditor\"]=n()})(window,(function(){return function(t){var e={};function n(o){if(e[o]){return e[o].exports}var i=e[o]={i:o,l:false,exports:{}};t[o].call(i.exports,i,i.exports,n);i.l=true;return i.exports}n.m=t;n.c=e;n.d=function(t,e,o){if(!n.o(t,e)){Object.defineProperty(t,e,{enumerable:true,get:o})}};n.r=function(t){if(typeof Symbol!==\"undefined\"&&Symbol.toStringTag){Object.defineProperty(t,Symbol.toStringTag,{value:\"Module\"})}Object.defineProperty(t,\"__esModule\",{value:true})};n.t=function(t,e){if(e&1)t=n(t);if(e&8)return t;if(e&4&&typeof t===\"object\"&&t&&t.__esModule)return t;var o=Object.create(null);n.r(o);Object.defineProperty(o,\"default\",{enumerable:true,value:t});if(e&2&&typeof t!=\"string\")for(var i in t)n.d(o,i,function(e){return t[e]}.bind(null,i));return o};n.n=function(t){var e=t&&t.__esModule?function e(){return t[\"default\"]}:function e(){return t};n.d(e,\"a\",e);return e};n.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)};n.p=\"\";return n(n.s=84)}([function(t,e,n){\"use strict\";n.d(e,\"a\",(function(){return i}));n.d(e,\"b\",(function(){return r}));const o=\"https://ckeditor.com/docs/ckeditor5/latest/framework/guides/support/error-codes.html\";class i extends Error{constructor(t,e,n){const o=`${t}${n?` ${JSON.stringify(n)}`:\"\"}${a(t)}`;super(o);this.name=\"CKEditorError\";this.context=e;this.data=n}is(t){return t===\"CKEditorError\"}static rethrowUnexpectedError(t,e){if(t.is&&t.is(\"CKEditorError\")){throw t}const n=new i(t.message,e);n.stack=t.stack;throw n}}function r(t,e){console.warn(...c(t,e))}function s(t,e){console.error(...c(t,e))}function a(t){return`\\nRead more: ${o}#error-${t}`}function c(t,e){const n=a(t);return e?[t,e,n]:[t,n]}},function(t,e,n){\"use strict\";var o=function t(){var e;return function t(){if(typeof e===\"undefined\"){e=Boolean(window&&document&&document.all&&!window.atob)}return e}}();var i=function t(){var e={};return function t(n){if(typeof e[n]===\"undefined\"){var o=document.querySelector(n);if(window.HTMLIFrameElement&&o instanceof window.HTMLIFrameElement){try{o=o.contentDocument.head}catch(t){o=null}}e[n]=o}return e[n]}}();var r=[];function s(t){var e=-1;for(var n=0;n0){if(++e>=Wt){return arguments[0]}}else{e=0}return t.apply(undefined,arguments)}}var Yt=qt;var $t=Yt(Ut);var Qt=$t;function Jt(t,e){return Qt(Ft(t,e,zt),t+\"\")}var Zt=Jt;var Xt=9007199254740991;function te(t){return typeof t==\"number\"&&t>-1&&t%1==0&&t<=Xt}var ee=te;function ne(t){return t!=null&&ee(t.length)&&!Z(t)}var oe=ne;var ie=9007199254740991;var re=/^(?:0|[1-9]\\d*)$/;function se(t,e){var n=typeof t;e=e==null?ie:e;return!!e&&(n==\"number\"||n!=\"symbol\"&&re.test(t))&&(t>-1&&t%1==0&&t
\").replace(/\\r?\\n/g,\"
\").replace(/^\\s/,\" \").replace(/\\s$/,\" \").replace(/\\s\\s/g,\" \");if(t.includes(\"
\")||t.includes(\"
\")){t=`
${t}
`}return t}function $v(t){return t.replace(/(\\s+)<\\/span>/g,((t,e)=>{if(e.length==1){return\" \"}return e}))}const Qv=[\"figcaption\",\"li\"];function Jv(t){let e=\"\";if(t.is(\"$text\")||t.is(\"$textProxy\")){e=t.data}else if(t.is(\"element\",\"img\")&&t.hasAttribute(\"alt\")){e=t.getAttribute(\"alt\")}else if(t.is(\"element\",\"br\")){e=\"\\n\"}else{let n=null;for(const o of t.getChildren()){const t=Jv(o);if(n&&(n.is(\"containerElement\")||o.is(\"containerElement\"))){if(Qv.includes(n.name)||Qv.includes(o.name)){e+=\"\\n\"}else{e+=\"\\n\\n\"}}e+=t;n=o}}return e}class Zv extends Hn{static get pluginName(){return\"ClipboardPipeline\"}init(){const t=this.editor;const e=t.editing.view;e.addObserver(Kv);this._setupPasteDrop();this._setupCopyCut()}_setupPasteDrop(){const t=this.editor;const e=t.model;const n=t.editing.view;const o=n.document;this.listenTo(o,\"clipboardInput\",(e=>{if(t.isReadOnly){e.stop()}}),{priority:\"highest\"});this.listenTo(o,\"clipboardInput\",((t,e)=>{const o=e.dataTransfer;let i=e.content||\"\";if(!i){if(o.getData(\"text/html\")){i=$v(o.getData(\"text/html\"))}else if(o.getData(\"text/plain\")){i=Yv(o.getData(\"text/plain\"))}i=this.editor.data.htmlProcessor.toView(i)}const s=new r(this,\"inputTransformation\");this.fire(s,{content:i,dataTransfer:o,targetRanges:e.targetRanges,method:e.method});if(s.stop.called){t.stop()}n.scrollToTheSelection()}),{priority:\"low\"});this.listenTo(this,\"inputTransformation\",((t,n)=>{if(n.content.isEmpty){return}const o=this.editor.data;const i=o.toModel(n.content,\"$clipboardHolder\");if(i.childCount==0){return}t.stop();e.change((()=>{this.fire(\"contentInsertion\",{content:i,method:n.method,dataTransfer:n.dataTransfer,targetRanges:n.targetRanges})}))}),{priority:\"low\"});this.listenTo(this,\"contentInsertion\",((t,n)=>{n.resultRange=e.insertContent(n.content)}),{priority:\"low\"})}_setupCopyCut(){const t=this.editor;const e=t.model.document;const n=t.editing.view;const o=n.document;function i(n,i){const r=i.dataTransfer;i.preventDefault();const s=t.data.toView(t.model.getSelectedContent(e.selection));o.fire(\"clipboardOutput\",{dataTransfer:r,content:s,method:n.name})}this.listenTo(o,\"copy\",i,{priority:\"low\"});this.listenTo(o,\"cut\",((e,n)=>{if(t.isReadOnly){n.preventDefault()}else{i(e,n)}}),{priority:\"low\"});this.listenTo(o,\"clipboardOutput\",((n,o)=>{if(!o.content.isEmpty){o.dataTransfer.setData(\"text/html\",this.editor.data.htmlProcessor.toData(o.content));o.dataTransfer.setData(\"text/plain\",Jv(o.content))}if(o.method==\"cut\"){t.model.deleteContent(e.selection)}}),{priority:\"low\"})}}function*Xv(t,e){for(const n of e){if(n&&t.getAttributeProperties(n[0]).copyOnEnter){yield n}}}class ty extends Wn{execute(){const t=this.editor.model;const e=t.document;t.change((n=>{ey(this.editor.model,n,e.selection,t.schema);this.fire(\"afterExecute\",{writer:n})}))}}function ey(t,e,n,o){const i=n.isCollapsed;const r=n.getFirstRange();const s=r.start.parent;const a=r.end.parent;if(o.isLimit(s)||o.isLimit(a)){if(!i&&s==a){t.deleteContent(n)}return}if(i){const t=Xv(e.model.schema,n.getAttributes());ny(e,r.start);e.setSelectionAttribute(t)}else{const o=!(r.start.isAtStart&&r.end.isAtEnd);const i=s==a;t.deleteContent(n,{leaveUnmerged:o});if(o){if(i){ny(e,n.focus)}else{e.setSelection(a,0)}}}}function ny(t,e){t.split(e);t.setSelection(e.parent.nextSibling,0)}class oy extends vu{constructor(t){super(t);const e=this.document;e.on(\"keydown\",((t,n)=>{if(this.isEnabled&&n.keyCode==td.enter){const o=new Dl(e,\"enter\",e.selection.getFirstRange());e.fire(o,new yh(e,n.domEvent,{isSoft:n.shiftKey}));if(o.stop.called){t.stop()}}}))}observe(){}}class iy extends Hn{static get pluginName(){return\"Enter\"}init(){const t=this.editor;const e=t.editing.view;const n=e.document;e.addObserver(oy);t.commands.add(\"enter\",new ty(t));this.listenTo(n,\"enter\",((n,o)=>{o.preventDefault();if(o.isSoft){return}t.execute(\"enter\");e.scrollToTheSelection()}),{priority:\"low\"})}}class ry{constructor(t,e=20){this.model=t;this.size=0;this.limit=e;this.isLocked=false;this._changeCallback=(t,e)=>{if(e.type!=\"transparent\"&&e!==this._batch){this._reset(true)}};this._selectionChangeCallback=()=>{this._reset()};this.model.document.on(\"change\",this._changeCallback);this.model.document.selection.on(\"change:range\",this._selectionChangeCallback);this.model.document.selection.on(\"change:attribute\",this._selectionChangeCallback)}get batch(){if(!this._batch){this._batch=this.model.createBatch()}return this._batch}input(t){this.size+=t;if(this.size>=this.limit){this._reset(true)}}lock(){this.isLocked=true}unlock(){this.isLocked=false}destroy(){this.model.document.off(\"change\",this._changeCallback);this.model.document.selection.off(\"change:range\",this._selectionChangeCallback);this.model.document.selection.off(\"change:attribute\",this._selectionChangeCallback)}_reset(t){if(!this.isLocked||t){this._batch=null;this.size=0}}}class sy extends Wn{constructor(t,e){super(t);this.direction=e;this._buffer=new ry(t.model,t.config.get(\"typing.undoStep\"))}get buffer(){return this._buffer}execute(t={}){const e=this.editor.model;const n=e.document;e.enqueueChange(this._buffer.batch,(o=>{this._buffer.lock();const i=o.createSelection(t.selection||n.selection);const r=t.sequence||1;const s=i.isCollapsed;if(i.isCollapsed){e.modifySelection(i,{direction:this.direction,unit:t.unit})}if(this._shouldEntireContentBeReplacedWithParagraph(r)){this._replaceEntireContentWithParagraph(o);return}if(this._shouldReplaceFirstBlockWithParagraph(i,r)){this.editor.execute(\"paragraph\",{selection:i});return}if(i.isCollapsed){return}let a=0;i.getFirstRange().getMinimalFlatRanges().forEach((t=>{a+=yl(t.getWalker({singleCharacters:true,ignoreElementEnd:true,shallow:true}))}));e.deleteContent(i,{doNotResetEntireContent:s,direction:this.direction});this._buffer.input(a);o.setSelection(i);this._buffer.unlock()}))}_shouldEntireContentBeReplacedWithParagraph(t){if(t>1){return false}const e=this.editor.model;const n=e.document;const o=n.selection;const i=e.schema.getLimitElement(o);const r=o.isCollapsed&&o.containsEntireContent(i);if(!r){return false}if(!e.schema.checkChild(i,\"paragraph\")){return false}const s=i.getChild(0);if(s&&s.name===\"paragraph\"){return false}return true}_replaceEntireContentWithParagraph(t){const e=this.editor.model;const n=e.document;const o=n.selection;const i=e.schema.getLimitElement(o);const r=t.createElement(\"paragraph\");t.remove(t.createRangeIn(i));t.insert(r,i);t.setSelection(r,0)}_shouldReplaceFirstBlockWithParagraph(t,e){const n=this.editor.model;if(e>1||this.direction!=\"backward\"){return false}if(!t.isCollapsed){return false}const o=t.getFirstPosition();const i=n.schema.getLimitElement(o);const r=i.getChild(0);if(o.parent!=r){return false}if(!t.containsEntireContent(r)){return false}if(!n.schema.checkChild(i,\"paragraph\")){return false}if(r.name==\"paragraph\"){return false}return true}}class ay extends vu{constructor(t){super(t);const e=t.document;let n=0;e.on(\"keyup\",((t,e)=>{if(e.keyCode==td.delete||e.keyCode==td.backspace){n=0}}));e.on(\"keydown\",((t,e)=>{const i={};if(e.keyCode==td.delete){i.direction=\"forward\";i.unit=\"character\"}else if(e.keyCode==td.backspace){i.direction=\"backward\";i.unit=\"codePoint\"}else{return}const r=Gl.isMac?e.altKey:e.ctrlKey;i.unit=r?\"word\":i.unit;i.sequence=++n;o(t,e.domEvent,i)}));if(Gl.isAndroid){e.on(\"beforeinput\",((e,n)=>{if(n.domEvent.inputType!=\"deleteContentBackward\"){return}const i={unit:\"codepoint\",direction:\"backward\",sequence:1};const r=n.domTarget.ownerDocument.defaultView.getSelection();if(r.anchorNode==r.focusNode&&r.anchorOffset+1!=r.focusOffset){i.selectionToRemove=t.domConverter.domSelectionToView(r)}o(e,n.domEvent,i)}))}function o(t,n,o){const i=new Dl(e,\"delete\",e.selection.getFirstRange());e.fire(i,new yh(e,n,o));if(i.stop.called){t.stop()}}}observe(){}}class cy extends Hn{static get pluginName(){return\"Delete\"}init(){const t=this.editor;const e=t.editing.view;const n=e.document;e.addObserver(ay);const o=new sy(t,\"forward\");t.commands.add(\"deleteForward\",o);t.commands.add(\"forwardDelete\",o);t.commands.add(\"delete\",new sy(t,\"backward\"));this.listenTo(n,\"delete\",((n,o)=>{const i={unit:o.unit,sequence:o.sequence};if(o.selectionToRemove){const e=t.model.createSelection();const n=[];for(const e of o.selectionToRemove.getRanges()){n.push(t.editing.mapper.toModelRange(e))}e.setTo(n);i.selection=e}t.execute(o.direction==\"forward\"?\"deleteForward\":\"delete\",i);o.preventDefault();e.scrollToTheSelection()}),{priority:\"low\"});if(Gl.isAndroid){let t=null;this.listenTo(n,\"delete\",((e,n)=>{const o=n.domTarget.ownerDocument.defaultView.getSelection();t={anchorNode:o.anchorNode,anchorOffset:o.anchorOffset,focusNode:o.focusNode,focusOffset:o.focusOffset}}),{priority:\"lowest\"});this.listenTo(n,\"keyup\",((e,n)=>{if(t){const e=n.domTarget.ownerDocument.defaultView.getSelection();e.collapse(t.anchorNode,t.anchorOffset);e.extend(t.focusNode,t.focusOffset);t=null}}))}}}class ly{constructor(){this._stack=[]}add(t,e){const n=this._stack;const o=n[0];this._insertDescriptor(t);const i=n[0];if(o!==i&&!dy(o,i)){this.fire(\"change:top\",{oldDescriptor:o,newDescriptor:i,writer:e})}}remove(t,e){const n=this._stack;const o=n[0];this._removeDescriptor(t);const i=n[0];if(o!==i&&!dy(o,i)){this.fire(\"change:top\",{oldDescriptor:o,newDescriptor:i,writer:e})}}_insertDescriptor(t){const e=this._stack;const n=e.findIndex((e=>e.id===t.id));if(dy(t,e[n])){return}if(n>-1){e.splice(n,1)}let o=0;while(e[o]&&uy(e[o],t)){o++}e.splice(o,0,t)}_removeDescriptor(t){const e=this._stack;const n=e.findIndex((e=>e.id===t));if(n>-1){e.splice(n,1)}}}Vn(ly,f);function dy(t,e){return t&&e&&t.priority==e.priority&&hy(t.classes)==hy(e.classes)}function uy(t,e){if(t.priority>e.priority){return true}else if(t.priority