UNPKG

@ckeditor/ckeditor5-track-changes

Version:

CKEditor 5 track changes plugin.

24 lines • 319 kB
/* * Copyright (c) 2003-2025, CKSource Holding sp. z o.o. All rights reserved. * * * * * +---------------------------------------------------------------------------------+ * | | * | Hello stranger! | * | | * | | * | What you're currently looking at is the source code of a legally protected, | * | proprietary software. Any attempts to deobfuscate / disassemble this code | * | are forbidden and will result in legal consequences. | * | | * | | * +---------------------------------------------------------------------------------+ * * * * */ import{Command as _0x2a6841,Plugin as _0x145e1e,PendingActions as _0x5aa78c}from'@ckeditor/ckeditor5-core/dist/index.js';import{CKEditorError as _0x23f610,ObservableMixin as _0x48291f,uid as _0xdf79fb,priorities as _0x4266f3,insertToPriorityArray as _0x3dfa7f,toArray as _0x57c294,logWarning as _0x2174f1,getEnvKeystrokeText as _0x1a3183,FocusTracker as _0x3b0299,KeystrokeHandler as _0x2075d1,Collection as _0x303b8b}from'@ckeditor/ckeditor5-utils/dist/index.js';import{IconCheck as _0x2825d1,IconCancel as _0x187575,IconTrackChanges as _0x52450a}from'@ckeditor/ckeditor5-icons/dist/index.js';import{normalizeColorOptions as _0x553222,View as _0x5ef96c,ViewCollection as _0x578fc8,FocusCycler as _0x559fa8,ViewModel as _0x2d86d1,createDropdown as _0x407968,SplitButtonView as _0x5019a0,addListToDropdown as _0x200f5c,MenuBarMenuView as _0x307a6f,MenuBarMenuListView as _0x46ea1e,ListSeparatorView as _0x48255e,MenuBarMenuListItemView as _0x5caa27,MenuBarMenuListItemButtonView as _0x4cb07a,BodyCollection as _0x10d846,Dialog as _0x2f67f8}from'@ckeditor/ckeditor5-ui/dist/index.js';import{Users as _0x52a7a7,hashObject as _0x2e8bbb,surroundingMarkersDetector as _0x56b228,FOCUS_ANNOTATION_KEYSTROKE as _0xc83a4,AriaDescriptionView as _0xb6480,setupThreadKeyboardNavigation as _0x883de9,trimHtml as _0x1e5bab,UserView as _0x177539,LateFocusButtonView as _0x4b6595,getDateTimeFormatter as _0x54e688,getAllMarkersDomElementsSorted as _0x30a813,sanitizeEditorConfig as _0x2e1fd9}from'ckeditor5-collaboration/dist/index.js';import{Element as _0x2110b5,LiveRange as _0x1d9e5c,LivePosition as _0x4b854b,DowncastWriter as _0x2d16d3}from'@ckeditor/ckeditor5-engine/dist/index.js';import{setHighlightHandling as _0x3d3279,toWidget as _0x919928}from'@ckeditor/ckeditor5-widget/dist/index.js';import{cloneDeep as _0x33d9d0,set as _0x403a7b,isEqual as _0x32e373,unset as _0x4ce9b6,omit as Ft}from'es-toolkit/compat';import{Delete as _0x2e4424,Input as tr}from'@ckeditor/ckeditor5-typing/dist/index.js';import{Enter as _0x4aab6}from'@ckeditor/ckeditor5-enter/dist/index.js';import{ClipboardPipeline as _0x1b6ef3}from'@ckeditor/ckeditor5-clipboard/dist/index.js';class B extends _0x2a6841{['_enabledCommands'];constructor(_0x3b2a31,_0x1461ab){super(_0x3b2a31),this['_enabledCommands']=_0x1461ab,this['value']=!0x1,this['refresh'](),this['_isEnabledBasedOnSelection']=!0x1;}['refresh'](){this['isEnabled']=!0x0;}['execute'](){this['value']=!this['value'],this['value']?this['_disableUnsupportedCommands']():this['_enableCommands']();}['_disableUnsupportedCommands'](){for(const _0x14d12f of this['editor']['commands']['commands']())_0x14d12f['affectsData']&&!this['_enabledCommands']['has'](_0x14d12f)&&_0x14d12f['forceDisabled']('TrackChangesCommand');}['_enableCommands'](){for(const _0x19b40b of this['editor']['commands']['commands']())_0x19b40b['affectsData']&&!this['_enabledCommands']['has'](_0x19b40b)&&_0x19b40b['clearForceDisabled']('TrackChangesCommand');}}class x extends _0x2a6841{['_suggestions'];constructor(_0x204631,_0x5432a9){super(_0x204631),this['_suggestions']=_0x5432a9,this['refresh'](),this['_isEnabledBasedOnSelection']=!0x1;}['refresh'](){this['isEnabled']=!0x0;}['execute'](_0x106b9d){const _0x44613a=this['_suggestions']['get'](_0x106b9d);if(!_0x44613a)throw new _0x23f610('track-changes-accept-suggestion-not-found',this);const _0x350f9d=_0x44613a['getRanges']();this['editor']['model']['canEditAt'](_0x350f9d)&&this['editor']['plugins']['get']('TrackChangesEditing')['acceptSuggestion'](_0x44613a);}}class O extends _0x2a6841{['_suggestions'];constructor(_0xf19873,_0x314260){super(_0xf19873),this['_suggestions']=_0x314260,this['refresh'](),this['_isEnabledBasedOnSelection']=!0x1;}['refresh'](){this['isEnabled']=!0x0;}['execute'](_0x5a7ddc){const _0x4e212c=this['_suggestions']['get'](_0x5a7ddc);if(!_0x4e212c)throw new _0x23f610('track-changes-discard-suggestion-not-found',this);const _0x2a6495=_0x4e212c['getRanges']();this['editor']['model']['canEditAt'](_0x2a6495)&&this['editor']['plugins']['get']('TrackChangesEditing')['discardSuggestion'](_0x4e212c);}}function ls(_0x279ebe,_0x43af78){let _0xdba5fc='';return _0xdba5fc+=_0x279ebe['split']('*')['map']((_0x2958e2,_0x14289a)=>_0x14289a%0x2!=0x0?'<span\x20class=\x22ck-suggestion-type\x22>'+nn(_0x2958e2)+'</span>':nn(_0x2958e2))['join'](''),_0x43af78&&(_0xdba5fc+='<span\x20class=\x22ck-suggestion-color\x22\x20style=\x22background-color:\x20'+_0x43af78['value']+'\x22\x20title=\x22'+_0x43af78['title']+'\x22></span>'),_0xdba5fc;}function nn(_0x3d8fb5){const _0x2723aa=document['createElement']('span');return _0x2723aa['innerText']=_0x3d8fb5,_0x2723aa['innerHTML'];}function ts(_0x5322af){return _0x5322af['sort']((_0x19abd4,_0x10b141)=>'deletion'==_0x19abd4['type']&&'deletion'!=_0x10b141['type']?-0x1:'deletion'!=_0x19abd4['type']&&'deletion'==_0x10b141['type']?0x1:0x0);}function to(_0x178087,_0x1f3b3c){let _0x1b7d0f,_0x17de5b=0x0;const _0x3b9a03=[],_0x1924b3=_0x1f3b3c['schema'];for(;_0x17de5b<_0x178087['length'];){const _0x3dac20=_0x178087[_0x17de5b],_0x837e59=_0x178087[_0x17de5b+0x1];_0x1b7d0f||(_0x1b7d0f=_0x1f3b3c['createPositionBefore'](_0x3dac20)),on(_0x1f3b3c,_0x3dac20,_0x837e59)||(_0x3b9a03['push'](_0x1f3b3c['createRange'](_0x1b7d0f,_0x1924b3['isObject'](_0x3dac20)?_0x1f3b3c['createPositionAfter'](_0x3dac20):_0x1f3b3c['createPositionAt'](_0x3dac20,'end'))),_0x1b7d0f=null),_0x17de5b++;}return _0x3b9a03;}function on(_0x509a5a,_0x2098d4,_0x5a5bf4){if(!_0x5a5bf4)return!0x1;const _0x3f2977=_0x509a5a['createPositionAfter'](_0x2098d4),_0x48491d=_0x509a5a['createPositionBefore'](_0x5a5bf4);return _0x3f2977['isTouching'](_0x48491d);}function rs(_0x56a047,_0x41ec96,_0x201094){for(;_0x201094['length'];){const _0x4ae312=_0x201094['splice'](0x0,0x64);_0x56a047['change'](()=>{for(const _0x1c6876 of _0x4ae312)_0x1c6876['isInContent']&&_0x41ec96['execute'](_0x1c6876['id']);});}}class R extends _0x2a6841{['_command'];['_suggestions'];constructor(_0x3b742d,_0x1bd00f,_0x5acf5a){super(_0x3b742d),this['_command']=_0x1bd00f,this['_suggestions']=_0x5acf5a,this['refresh'](),this['_isEnabledBasedOnSelection']=!0x1;}['refresh'](){const _0xf07714=Array['from'](this['_suggestions']['values']())['some'](_0x25a12b=>_0x25a12b['isInContent']);this['isEnabled']=this['_command']['isEnabled']&&_0xf07714;}['execute'](){const _0x24be4a=ts(Array['from'](this['_suggestions']['values']()));for(const _0x36cb31 of _0x24be4a){const _0x3fac0b=_0x36cb31['getRanges']();if(!this['editor']['model']['canEditAt'](_0x3fac0b))return;}rs(this['editor']['model'],this['_command'],_0x24be4a);}}class E extends _0x2a6841{['_command'];['_suggestions'];['_selectedSuggestions'];constructor(_0x2e924a,_0x11e4c9,_0xcf592e){super(_0x2e924a),this['_command']=_0x11e4c9,this['_suggestions']=_0xcf592e,this['_selectedSuggestions']=new Set(),this['refresh'](),this['_isEnabledBasedOnSelection']=!0x1;}['refresh'](){const _0x5bfc02=this['editor']['model']['document']['selection'],_0x6deffe=Array['from'](this['_suggestions']['values']());this['_selectedSuggestions']=function(_0x56a2a7,_0x2f7945){const _0x480beb=Array['from'](_0x56a2a7['getRanges']()),_0x5b8fc5=new Set();for(const _0x35ffb0 of _0x2f7945)if(_0x35ffb0['isInContent']){for(const _0x13ae54 of _0x480beb)for(const _0x3cd204 of _0x35ffb0['getRanges']())(_0x13ae54['isIntersecting'](_0x3cd204)||_0x56a2a7['isCollapsed']&&!_0x35ffb0['isMultiRange']&&_0x35ffb0['next']&&_0x3cd204['end']['isTouching'](_0x13ae54['start']))&&_0x5b8fc5['add'](_0x35ffb0);}return _0x5b8fc5;}(_0x5bfc02,_0x6deffe),this['isEnabled']=this['_command']['isEnabled']&&!!this['_selectedSuggestions']['size'];}['execute'](){const _0x181755=ts(Array['from'](this['_selectedSuggestions']));for(const _0x44d4ba of _0x181755){const _0x33f1ee=_0x44d4ba['getRanges']();if(!this['editor']['model']['canEditAt'](_0x33f1ee))return;}rs(this['editor']['model'],this['_command'],_0x181755);}}class o extends/* #__PURE__ -- @preserve */ _0x48291f(){['id'];['type'];['subType'];['author'];['creator'];['isExternal'];['data'];['createdAt'];['_originalSuggestionId'];['_isDataLoaded']=!0x1;['_model'];['_onAccept'];['_onDiscard'];['_onAttributesChange'];['_markerNames'];constructor(_0x199da8,_0x840993){super(),this['id']=_0x840993['id'],this['type']=_0x840993['type'],this['subType']=_0x840993['subType']||null,this['author']=_0x840993['author'],this['creator']=_0x840993['creator']||_0x840993['author'],this['isExternal']=Boolean(_0x840993['attributes']&&_0x840993['attributes']['@external']),this['data']=null,this['_originalSuggestionId']=_0x840993['originalSuggestionId']||null,this['_model']=_0x199da8,this['_onAccept']=_0x840993['onAccept'],this['_onDiscard']=_0x840993['onDiscard'],this['_onAttributesChange']=_0x840993['onAttributesChange'],this['_markerNames']=new Set(),this['createdAt']=null,this['set']('authoredAt',null),this['set']('attributes',_0x840993['attributes']||{}),this['set']('previous',null),this['set']('next',null),this['set']('commentThread',null),this['set']('_saved',!0x1),this['decorate']('accept'),this['decorate']('discard');}get['head'](){let _0x10e5e2=this;for(;_0x10e5e2['previous'];)_0x10e5e2=_0x10e5e2['previous'];return _0x10e5e2;}get['hasComments'](){return!!this['commentThread']&&this['commentThread']['length']>0x0;}get['isMultiRange'](){if(0x0==this['_markerNames']['size'])return!0x1;return 0x6==Array['from'](this['_markerNames'])[0x0]['split'](':')['length'];}get['isInContent'](){return null!==this['getFirstMarker']();}['addMarkerName'](_0xf73f2){this['_markerNames']['add'](_0xf73f2);}['getMarkerNames'](){return Array['from'](this['_markerNames']);}['getMarkers'](){return this['getMarkerNames']()['map'](_0xf1fce=>this['_model']['markers']['get'](_0xf1fce))['filter'](_0x5b03d2=>_0x5b03d2);}['getFirstMarker'](){return this['getMarkers']()[0x0]||null;}['removeMarkers'](){this['_model']['change'](_0x4b4abd=>{for(const _0x3d56f5 of this['getMarkers']())_0x4b4abd['removeMarker'](_0x3d56f5);}),this['_markerNames']['clear']();}['removeMarker'](_0x3bab82){this['_model']['change'](_0x5f124d=>{_0x5f124d['removeMarker'](_0x3bab82);}),this['_markerNames']['delete'](_0x3bab82);}['addRange'](_0x2f364f){const _0x20dc5d='suggestion:'+this['type']+':'+this['subType']+':'+this['id']+':'+this['creator']['id']+':'+o['getMultiRangeId']();this['addMarkerName'](_0x20dc5d),this['_model']['change'](_0x24faf8=>{_0x24faf8['addMarker'](_0x20dc5d,{'range':_0x2f364f,'usingOperation':!0x0,'affectsData':!0x0});});}['isIntersectingWithRange'](_0x1b1d47){for(const _0x1480b8 of this['getRanges']())if(_0x1480b8['isIntersecting'](_0x1b1d47))return!0x0;return!0x1;}['getRanges'](){return this['getMarkers']()['map'](_0x1e1127=>_0x1e1127['getRange']());}['getItems'](){return this['getRanges']()['reduce']((_0x4fc627,_0x3090a5)=>[..._0x4fc627,..._0x3090a5['getItems']()],[]);}['getFirstRange'](){return this['getFirstMarker']()?.['getRange']()||null;}['getContainedElement'](){const _0x251172=this['getRanges']();if(0x1!=_0x251172['length'])return null;const _0x575673=_0x251172[0x0],_0x57d9d2=_0x575673['start']['nodeAfter'],_0x5d8af6=_0x575673['end']['nodeBefore'];return _0x57d9d2 instanceof _0x2110b5?_0x57d9d2!=_0x5d8af6?null:_0x57d9d2:null;}['accept'](){this['_onAccept'](this['getRanges'](),this['data'],this['attributes']),this['removeMarkers']();}['discard'](){this['_onDiscard'](this['getRanges'](),this['data'],this['attributes']),this['removeMarkers']();}['getAllAdjacentSuggestions'](){const _0x49bbb9=[];let _0x39220e=this['head'];for(;_0x39220e;)_0x49bbb9['push'](_0x39220e),_0x39220e=_0x39220e['next'];return _0x49bbb9;}['setAttribute'](_0x1266ec,_0x516b86){const _0x4cdae0=_0x33d9d0(this['attributes']);_0x403a7b(_0x4cdae0,_0x1266ec,_0x516b86),_0x32e373(_0x4cdae0,this['attributes'])||(this['attributes']=_0x4cdae0,this['_onAttributesChange'](_0x4cdae0));}['removeAttribute'](_0x583164){const _0x378007=_0x33d9d0(this['attributes']);_0x4ce9b6(_0x378007,_0x583164),_0x32e373(_0x378007,this['attributes'])||(this['attributes']=_0x378007,this['_onAttributesChange'](this['attributes']));}['toJSON'](){return{'id':this['id'],'type':this['subType']?this['type']+':'+this['subType']:this['type'],'authorId':this['creator']['id'],'createdAt':this['createdAt'],'hasComments':this['hasComments'],'data':this['data'],'attributes':this['attributes']};}static['getMultiRangeId'](){return _0xdf79fb()['substr'](0x1,0x5);}}function c(_0x5216e6,_0x531b99,_0x47b56b){const _0x3697c2=_0x5216e6['t'],t=_0x5216e6['t'];switch(_0x531b99){case'Track\x20changes':return t('Track\x20changes');case'Accept\x20suggestion':return t('Accept\x20suggestion');case'Discard\x20suggestion':return t('Discard\x20suggestion');case'Accept\x20all\x20suggestions':return t('Accept\x20all\x20suggestions');case'Accept\x20all\x20selected\x20suggestions':return t('Accept\x20all\x20selected\x20suggestions');case'Discard\x20all\x20suggestions':return t('Discard\x20all\x20suggestions');case'Discard\x20all\x20selected\x20suggestions':return t('Discard\x20all\x20selected\x20suggestions');case'Preview\x20final\x20content':return t('Preview\x20final\x20content');case'Final\x20content\x20preview':return t('Final\x20content\x20preview');case'*Reset\x20font\x20size*':return t('*Reset\x20font\x20size*');case'*Reset\x20font\x20family*':return t('*Reset\x20font\x20family*');case'*Reset\x20font\x20color*':return t('*Reset\x20font\x20color*');case'*Reset\x20font\x20background\x20color*':return t('*Reset\x20font\x20background\x20color*');case'*Remove\x20image\x20text\x20alternative*':return t('*Remove\x20image\x20text\x20alternative*');case'*Reset\x20image\x20width*':return t('*Reset\x20image\x20width*');case'*Remove\x20link*':return t('*Remove\x20link*');case'*Check\x20item*':return t('*Check\x20item*');case'*Uncheck\x20item*':return t('*Uncheck\x20item*');case'*Remove\x20all\x20formatting*':return t('*Remove\x20all\x20formatting*');case'*Replace\x20table\x20cells*':return t('*Replace\x20table\x20cells*');case'*Merge\x20cells*':return t('*Merge\x20cells*');case'*Split\x20cell:*\x20vertically':return t('*Split\x20cell:*\x20vertically');case'*Split\x20cell:*\x20horizontally':return t('*Split\x20cell:*\x20horizontally');case'*Indent:*\x20%0':return t('*Indent:*\x20%0',_0x47b56b);case'*Outdent:*\x20%0':return t('*Outdent:*\x20%0',_0x47b56b);case'*Change\x20to:*\x20%0':return t('*Change\x20to:*\x20%0',_0x47b56b);case'*Insert:*\x20%0':return t('*Insert:*\x20%0',_0x47b56b);case'*Format:*\x20%0':return t('*Format:*\x20%0',_0x47b56b);case'*Format:*\x20change\x20table\x20properties':return t('*Format:*\x20change\x20table\x20properties');case'*Format:*\x20change\x20table\x20cell\x20properties':return t('*Format:*\x20change\x20table\x20cell\x20properties');case'*Format:*\x20insert\x20into\x20%0':return t('*Format:*\x20insert\x20into\x20%0',_0x47b56b);case'*Format:*\x20remove\x20from\x20%0':return t('*Format:*\x20remove\x20from\x20%0',_0x47b56b);case'*Replace\x20image*':return t('*Replace\x20image*');case'*Format:*\x20resize\x20table':return t('*Format:*\x20resize\x20table');case'*Format:*\x20set\x20order\x20to\x20reversed':return t('*Format:*\x20set\x20order\x20to\x20reversed');case'*Format:*\x20set\x20order\x20to\x20regular':return t('*Format:*\x20set\x20order\x20to\x20regular');case'*Format:*\x20set\x20start\x20index\x20to\x20%0':return t('*Format:*\x20set\x20start\x20index\x20to\x20%0',_0x47b56b);case'*Change\x20%0\x20content*':return t('*Change\x20%0\x20content*',_0x47b56b);case'*Remove:*\x20%0':return t('*Remove:*\x20%0',_0x47b56b);case'*Merge:*\x20%0':return t('*Merge:*\x20%0',_0x47b56b);case'*Split:*\x20%0':return t('*Split:*\x20%0',_0x47b56b);case'*Remove\x20format:*\x20%0':return t('*Remove\x20format:*\x20%0',_0x47b56b);case'*Set\x20bookmark:*\x20%0':return t('*Set\x20bookmark:*\x20%0',_0x47b56b);case'*Set\x20font\x20size:*\x20%0':return t('*Set\x20font\x20size:*\x20%0',_0x47b56b);case'*Set\x20font\x20family:*\x20%0':return t('*Set\x20font\x20family:*\x20%0',_0x47b56b);case'*Set\x20format\x20to:*\x20%0':return t('*Set\x20format\x20to:*\x20%0',_0x47b56b);case'*Set\x20font\x20color:*\x20%0':return t('*Set\x20font\x20color:*\x20%0',_0x47b56b);case'*Set\x20font\x20background\x20color:*\x20%0':return t('*Set\x20font\x20background\x20color:*\x20%0',_0x47b56b);case'*Set\x20format:*\x20%0':return t('*Set\x20format:*\x20%0',_0x47b56b);case'*Set\x20image\x20text\x20alternative:*\x20%0':return t('*Set\x20image\x20text\x20alternative:*\x20%0',_0x47b56b);case'*Set\x20image\x20width:*\x20%0':return t('*Set\x20image\x20width:*\x20%0',_0x47b56b);case'*Set\x20link:*\x20%0':return t('*Set\x20link:*\x20%0',_0x47b56b);case'*Set\x20highlight:*\x20%0':return t('*Set\x20highlight:*\x20%0',_0x47b56b);case'*Set\x20table\x20type:*\x20%0':return t('*Set\x20table\x20type:*\x20%0',_0x47b56b);case'*Remove\x20highlight*':return t('*Remove\x20highlight*');case'FORMAT_HIGHLIGHT':return t({'string':'highlight','id':'FORMAT_HIGHLIGHT'});case'FORMAT_RESTRICTED_ENABLED':return t({'string':'*Enable\x20in\x20restricted\x20editing\x20mode*','id':'FORMAT_RESTRICTED_ENABLED'});case'FORMAT_RESTRICTED_DISABLED':return t({'string':'*Disable\x20in\x20restricted\x20editing\x20mode*','id':'FORMAT_RESTRICTED_DISABLED'});case'ELEMENT_TABLE':return t({'string':'table','plural':'%0\x20tables','id':'ELEMENT_TABLE'},_0x47b56b);case'ELEMENT_CONTENT_TABLE':return t({'string':'content\x20table','plural':'%0\x20content\x20tables','id':'ELEMENT_CONTENT_TABLE'},_0x47b56b);case'ELEMENT_LAYOUT_TABLE':return t({'string':'layout\x20table','plural':'%0\x20layout\x20tables','id':'ELEMENT_LAYOUT_TABLE'},_0x47b56b);case'ELEMENT_PARAGRAPH':return t({'string':'paragraph','plural':'%0\x20paragraphs','id':'ELEMENT_PARAGRAPH'},_0x47b56b);case'ELEMENT_PAGE_BREAK':return t({'string':'page\x20break','plural':'%0\x20page\x20breaks','id':'ELEMENT_PAGE_BREAK'},_0x47b56b);case'ELEMENT_MEDIA':return t({'string':'media\x20item','plural':'%0\x20media\x20items','id':'ELEMENT_MEDIA'},_0x47b56b);case'ELEMENT_IMAGE':return t({'string':'image','plural':'%0\x20images','id':'ELEMENT_IMAGE'},_0x47b56b);case'ELEMENT_INLINE_IMAGE':return t({'string':'image','plural':'%0\x20images','id':'ELEMENT_INLINE_IMAGE'},_0x47b56b);case'FORMAT_SIDE_IMAGE':return t({'string':'side\x20image','id':'FORMAT_SIDE_IMAGE'});case'ELEMENT_CAPTION':return t({'string':'caption','id':'ELEMENT_CAPTION'});case'ELEMENT_HORIZONTAL_LINE':return t({'string':'horizontal\x20line','plural':'%0\x20horizontal\x20lines','id':'ELEMENT_HORIZONTAL_LINE'},_0x47b56b);case'ELEMENT_HTML_EMBED':return t({'string':'HTML\x20embed','plural':'%0\x20HTML\x20embeds','id':'ELEMENT_HTML_EMBED'},_0x47b56b);case'ELEMENT_HEADING':return t({'string':'heading\x20(level\x20%1)','plural':'%0\x20headings\x20(level\x20%1)','id':'ELEMENT_HEADING'},_0x47b56b);case'ELEMENT_HEADING_CUSTOM':return t({'string':'heading\x20(%1)','plural':'%0\x20headings\x20(%1)','id':'ELEMENT_HEADING_CUSTOM'},_0x47b56b);case'ELEMENT_LIST_ITEM':return t({'string':'list\x20item','plural':'%0\x20list\x20items','id':'ELEMENT_LIST_ITEM'},_0x47b56b);case'ELEMENT_DEFAULT_LIST_DEFAULT':return t({'string':'default\x20list\x20style','id':'ELEMENT_DEFAULT_LIST_DEFAULT'});case'ELEMENT_BULLETED_LIST':return t({'string':'bulleted\x20list','id':'ELEMENT_BULLETED_LIST'});case'ELEMENT_BULLETED_LIST_DEFAULT':return t({'string':'bulleted\x20list\x20(default)','id':'ELEMENT_BULLETED_LIST_DEFAULT'});case'ELEMENT_BULLETED_LIST_CIRCLE':return t({'string':'bulleted\x20list\x20(circle)','id':'ELEMENT_BULLETED_LIST_CIRCLE'});case'ELEMENT_BULLETED_LIST_DISC':return t({'string':'bulleted\x20list\x20(disc)','id':'ELEMENT_BULLETED_LIST_DISC'});case'ELEMENT_BULLETED_LIST_SQUARE':return t({'string':'bulleted\x20list\x20(square)','id':'ELEMENT_BULLETED_LIST_SQUARE'});case'ELEMENT_NUMBERED_LIST_DEFAULT':return t({'string':'numbered\x20list\x20(default)','id':'ELEMENT_NUMBERED_LIST_DEFAULT'});case'ELEMENT_NUMBERED_LIST':return t({'string':'numbered\x20list','id':'ELEMENT_NUMBERED_LIST'});case'ELEMENT_NUMBERED_LIST_DECIMAL':return t({'string':'numbered\x20list\x20(decimal)','id':'ELEMENT_NUMBERED_LIST_DECIMAL'});case'ELEMENT_NUMBERED_LIST_DECIMAL_LEADING_ZERO':return t({'string':'numbered\x20list\x20(decimal\x20with\x20leading\x20zero)','id':'ELEMENT_NUMBERED_LIST_DECIMAL_LEADING_ZERO'});case'ELEMENT_NUMBERED_LIST_LOWER_LATIN':return t({'string':'numbered\x20list\x20(lower-latin)','id':'ELEMENT_NUMBERED_LIST_LOWER_LATIN'});case'ELEMENT_NUMBERED_LIST_LOWER_ROMAN':return t({'string':'numbered\x20list\x20(lower-roman)','id':'ELEMENT_NUMBERED_LIST_LOWER_ROMAN'});case'ELEMENT_NUMBERED_LIST_UPPER_LATIN':return t({'string':'numbered\x20list\x20(upper-latin)','id':'ELEMENT_NUMBERED_LIST_UPPER_LATIN'});case'ELEMENT_NUMBERED_LIST_UPPER_ROMAN':return t({'string':'numbered\x20list\x20(upper-roman)','id':'ELEMENT_NUMBERED_LIST_UPPER_ROMAN'});case'ELEMENT_TODO_LIST':return t({'string':'to-do\x20list','id':'ELEMENT_TODO_LIST'});case'ELEMENT_MULTI_LEVEL_LIST':return t({'string':'multi-level\x20list','id':'ELEMENT_MULTI_LEVEL_LIST'});case'REPLACE_TEXT':return t({'string':'*Replace:*\x20%0\x20*with*\x20%1','id':'REPLACE_TEXT'},_0x47b56b);case'ELEMENT_SPACE':return t({'string':'space','plural':'%0\x20spaces','id':'ELEMENT_SPACE'},_0x47b56b);case'FORMAT_ALIGNMENT':return t({'string':'alignment','id':'FORMAT_ALIGNMENT'});case'FORMAT_ALIGN_TO_LEFT':return t({'string':'align\x20to\x20left','id':'FORMAT_ALIGN_TO_LEFT'});case'FORMAT_ALIGN_TO_RIGHT':return t({'string':'align\x20to\x20right','id':'FORMAT_ALIGN_TO_RIGHT'});case'FORMAT_ALIGN_TO_CENTER':return t({'string':'align\x20to\x20center','id':'FORMAT_ALIGN_TO_CENTER'});case'FORMAT_JUSTIFY_TEXT':return t({'string':'justify','id':'FORMAT_JUSTIFY_TEXT'});case'FORMAT_BOLD':return t({'string':'bold','id':'FORMAT_BOLD'});case'FORMAT_ITALIC':return t({'string':'italic','id':'FORMAT_ITALIC'});case'FORMAT_UNDERLINE':return t({'string':'underline','id':'FORMAT_UNDERLINE'});case'FORMAT_CODE':return t({'string':'code','id':'FORMAT_CODE'});case'FORMAT_STRIKETHROUGH':return t({'string':'strikethrough','id':'FORMAT_STRIKETHROUGH'});case'FORMAT_SUBSCRIPT':return t({'string':'subscript','id':'FORMAT_SUBSCRIPT'});case'FORMAT_SUPERSCRIPT':return t({'string':'superscript','id':'FORMAT_SUPERSCRIPT'});case'ELEMENT_BLOCK_QUOTE':return t({'string':'block\x20quote','id':'ELEMENT_BLOCK_QUOTE'});case'ELEMENT_CODE_BLOCK':return t({'string':'code\x20block','plural':'%0\x20code\x20blocks','id':'ELEMENT_CODE_BLOCK'},_0x47b56b);case'FORMAT_HEADER_COLUMN':return t({'string':'header\x20column','id':'FORMAT_HEADER_COLUMN'});case'FORMAT_REGULAR_COLUMN':return t({'string':'regular\x20column','id':'FORMAT_REGULAR_COLUMN'});case'FORMAT_HEADER_ROW':return t({'string':'header\x20row','id':'FORMAT_HEADER_ROW'});case'FORMAT_REGULAR_ROW':return t({'string':'regular\x20row','id':'FORMAT_REGULAR_ROW'});case'FORMAT_INDENT':return t({'string':'indent','id':'FORMAT_INDENT'});case'FORMAT_LIST_REVERSED':return t({'string':'list\x20reversed','id':'FORMAT_LIST_REVERSED'});case'FORMAT_LIST_START':return t({'string':'list\x20start','id':'FORMAT_LIST_START'});case'FORMAT_FONT_SIZE':return t({'string':'font\x20size','id':'FORMAT_FONT_SIZE'});case'FORMAT_FONT_FAMILY':return t({'string':'font\x20family','id':'FORMAT_FONT_FAMILY'});case'FORMAT_FONT_COLOR':return t({'string':'font\x20color','id':'FORMAT_FONT_COLOR'});case'FORMAT_FONT_BACKGROUND':return t({'string':'font\x20background\x20color','id':'FORMAT_FONT_BACKGROUND'});case'FORMAT_IMAGE_SIZE':return t({'string':'image\x20size','id':'FORMAT_IMAGE_SIZE'});case'FORMAT_STYLE':return t({'string':'style','id':'FORMAT_STYLE'});case'PENDING_ACTION_SUGGESTION':return t({'string':'Unsaved\x20change\x20in\x20suggestion.','id':'PENDING_ACTION_SUGGESTION'});case'ELEMENT_TABLE_WITH_TEXT':return t({'string':'table\x20*with\x20text*\x20%0','id':'ELEMENT_TABLE_WITH_TEXT'},_0x47b56b);case'ELEMENT_TABLE_ROW':return t({'string':'table\x20row','plural':'%0\x20table\x20rows','id':'ELEMENT_TABLE_ROW'},_0x47b56b);case'ELEMENT_TABLE_ROW_WITH_TEXT':return t({'string':'table\x20row\x20*with\x20text*\x20%1','plural':'%0\x20table\x20rows\x20*with\x20text*\x20%1','id':'ELEMENT_TABLE_ROW_WITH_TEXT'},_0x47b56b);case'ELEMENT_TABLE_COLUMN':return t({'string':'table\x20column','plural':'%0\x20table\x20columns','id':'ELEMENT_TABLE_COLUMN'},_0x47b56b);case'ELEMENT_TABLE_COLUMN_WITH_TEXT':return t({'string':'table\x20column\x20*with\x20text*\x20%1','plural':'%0\x20table\x20columns\x20*with\x20text*\x20%1','id':'ELEMENT_TABLE_COLUMN_WITH_TEXT'},_0x47b56b);case'ELEMENT_TABLE_OF_CONTENTS':return t({'string':'table\x20of\x20contents','plural':'%0\x20tables\x20of\x20contents','id':'ELEMENT_TABLE_OF_CONTENTS'},_0x47b56b);case'ELEMENT_LINE_BREAK':return t({'id':'ELEMENT_LINE_BREAK','string':'line\x20break','plural':'%0\x20line\x20breaks'},_0x47b56b);case'ELEMENT_TITLE':return t({'id':'ELEMENT_TITLE','string':'title'});case'ELEMENT_MERGE_FIELD':return t({'id':'ELEMENT_MERGE_FIELD','string':'merge\x20field','plural':'%0\x20merge\x20fields'},_0x47b56b);case'ELEMENT_BOOKMARK':return t({'id':'ELEMENT_BOOKMARK','string':'bookmark','plural':'%0\x20bookmarks'},_0x47b56b);case'EXTERNAL_SUGGESTION':return t({'id':'EXTERNAL_SUGGESTION','string':'This\x20suggestion\x20comes\x20from\x20an\x20external\x20source.'});case'EXTERNAL_IMPORT_WORD_SUGGESTION':return t({'string':'This\x20suggestion\x20comes\x20from\x20an\x20imported\x20Word\x20file.','id':'EXTERNAL_IMPORT_WORD_SUGGESTION'});case'EXTERNAL_AVATAR':return _0x3697c2({'string':'Displayed\x20author\x20name\x20comes\x20from\x20external\x20source\x20(added\x20by\x20%0)','id':'EXTERNAL_AVATAR'},_0x47b56b);case'EXTERNAL_IMPORT_WORD_AVATAR':return _0x3697c2({'string':'Displayed\x20author\x20name\x20comes\x20from\x20a\x20Word\x20document\x20imported\x20by\x20%0','id':'EXTERNAL_IMPORT_WORD_AVATAR'},_0x47b56b);case'ENTER_INSERTION_SUGGESTION_ANNOUNCEMENT':return t({'string':'Entering\x20insertion\x20suggestion.\x20Press\x20%0\x20to\x20go\x20to\x20the\x20discussion.','id':'ENTER_INSERTION_SUGGESTION_ANNOUNCEMENT'},_0x47b56b);case'LEAVE_INSERTION_SUGGESTION_ANNOUNCEMENT':return t({'string':'Leaving\x20insertion\x20suggestion.','id':'LEAVE_INSERTION_SUGGESTION_ANNOUNCEMENT'});case'ENTER_DELETION_SUGGESTION_ANNOUNCEMENT':return t({'string':'Entering\x20deletion\x20suggestion.\x20Press\x20%0\x20to\x20go\x20to\x20the\x20discussion.','id':'ENTER_DELETION_SUGGESTION_ANNOUNCEMENT'},_0x47b56b);case'LEAVE_DELETION_SUGGESTION_ANNOUNCEMENT':return t({'string':'Leaving\x20deletion\x20suggestion.','id':'LEAVE_DELETION_SUGGESTION_ANNOUNCEMENT'});case'ENTER_FORMATTING_SUGGESTION_ANNOUNCEMENT':return t({'string':'Entering\x20formatting\x20suggestion.\x20Press\x20%0\x20to\x20go\x20to\x20the\x20discussion.','id':'ENTER_FORMATTING_SUGGESTION_ANNOUNCEMENT'},_0x47b56b);case'LEAVE_FORMATTING_SUGGESTION_ANNOUNCEMENT':return t({'string':'Leaving\x20formatting\x20suggestion.','id':'LEAVE_FORMATTING_SUGGESTION_ANNOUNCEMENT'});case'SUGGESTION_THREAD_ARIA_LABEL':return t({'string':'Suggestion\x20by\x20%1.\x20Created\x20on\x20%2.\x20%0\x20reply.\x20%3','plural':'Suggestion\x20by\x20%1.\x20Created\x20on\x20%2.\x20%0\x20replies.\x20%3','id':'SUGGESTION_THREAD_ARIA_LABEL'},_0x47b56b);case'SUGGESTION_THREAD_DESCRIPTION':return t({'string':'Press\x20Enter\x20for\x20more\x20options.\x20Press\x20Escape\x20to\x20exit.','id':'SUGGESTION_THREAD_DESCRIPTION'});default:return _0x531b99;}}class f{['_customCallbacks'];['_itemLabels'];['_itemLabelsCallbacks'];['_attributeLabels'];['_schema'];['_locale'];constructor(_0x2dbdd6,_0x22a705){this['_customCallbacks']=[],this['_itemLabels']=new Map(),this['_itemLabelsCallbacks']=[],this['_attributeLabels']=new Map(),this['_schema']=_0x2dbdd6,this['_locale']=_0x22a705;}['getDescriptions'](_0x23895e){const _0x2dc34c=[],_0x6af93b=new Set(),_0x44b9c=new Set();for(let _0x4a80d5=0x0;_0x4a80d5<_0x23895e['length'];_0x4a80d5++){const _0xcbb3b9=_0x23895e[_0x4a80d5];if(!_0xcbb3b9['isInContent'])continue;const _0x2d3993=this['_handleCustomCallbackDescription'](_0xcbb3b9);if(_0x2d3993){if(null!=_0xcbb3b9['subType']){if(_0x6af93b['has'](_0xcbb3b9['subType']))continue;_0x6af93b['add'](_0xcbb3b9['subType']);}_0x2dc34c['push'](_0x2d3993);}else{if('attribute'==_0xcbb3b9['type']){const _0x38c880=_0xcbb3b9['data']['key'];if(_0x44b9c['has'](_0x38c880))continue;_0x44b9c['add'](_0xcbb3b9['data']['key']),_0x38c880==u?this['_handleRenameSuggestionDescription'](_0x2dc34c,_0xcbb3b9):this['_handleAttributeSuggestionDescription'](_0x2dc34c,_0xcbb3b9);continue;}'insertion'!=_0xcbb3b9['type']&&'deletion'!=_0xcbb3b9['type']||this['_handleInsertRemoveSuggestionDescription'](_0x2dc34c,_0xcbb3b9,_0x23895e[_0x4a80d5+0x1]);}}return this['_resolveDescriptionItems'](_0x2dc34c);}['registerDescriptionCallback'](_0xbaff42){this['_customCallbacks']['push'](_0xbaff42);}['registerElementLabel'](_0x2e5de9,_0x3d6904,_0x4eb9ca=_0x4266f3['normal']){'function'==typeof _0x2e5de9?_0x3dfa7f(this['_itemLabelsCallbacks'],{'matchingCallback':_0x2e5de9,'label':_0x3d6904,'priority':_0x4eb9ca}):this['_itemLabels']['set'](_0x2e5de9,_0x3d6904);}['registerAttributeLabel'](_0x2f0abd,_0x7e089c){this['_attributeLabels']['set'](_0x2f0abd,_0x7e089c);}['getItemLabel'](_0x288be0,_0x664a72=0x1){let _0x233cac;for(const _0x261ad3 of this['_itemLabelsCallbacks'])if(_0x261ad3['matchingCallback'](_0x288be0)){_0x233cac=_0x261ad3['label'];break;}return _0x233cac||(_0x233cac=this['_itemLabels']['get'](_0x288be0['name'])),_0x233cac?_0x233cac(_0x664a72):0x1!==_0x664a72?_0x664a72+'\x20'+_0x288be0['name']+'s':''+_0x288be0['name'];}['_addDescriptionItems'](_0xfc9202,_0x5ba8d2){const _0x4f84e6=_0x5ba8d2['getFirstRange']()['getWalker'](),_0x311369='insertion'==_0x5ba8d2['type']?'add':'remove';for(const _0x35f5e3 of _0x4f84e6){const _0x4bf7f1=_0x35f5e3['item'],_0x3adadf=_0xfc9202[_0xfc9202['length']-0x1];if(_0x4bf7f1['is']('$textProxy'))_0x3adadf&&_0x3adadf['type']['indexOf']('Container')>-0x1&&_0xfc9202['pop'](),_0x3adadf&&'text'==_0x3adadf['type']?_0x3adadf[_0x311369]+=_0x4bf7f1['data']:_0xfc9202['push']({'type':'text','add':'add'==_0x311369?_0x4bf7f1['data']:'','remove':'remove'==_0x311369?_0x4bf7f1['data']:''});else{if(this['_schema']['isObject'](_0x4bf7f1)){const _0x57f179=_0x4bf7f1;if(_0x3adadf&&_0x3adadf['type']['indexOf']('Container')>-0x1&&_0xfc9202['pop'](),'elementEnd'==_0x35f5e3['type'])continue;_0x3adadf&&_0x3adadf['type']==_0x311369+'Object'&&_0x3adadf['element']['name']==_0x57f179['name']?_0x3adadf['quantity']++:_0xfc9202['push']({'type':_0x311369+'Object','element':_0x57f179,'quantity':0x1}),_0x4f84e6['skip'](_0x13d903=>!('elementEnd'==_0x13d903['type']&&_0x13d903['item']==_0x4bf7f1));}else{if(this['_schema']['checkChild'](_0x4bf7f1,'$text')||_0x4bf7f1['is']('element','softBreak')){const _0x336731=_0x4bf7f1;if('add'==_0x311369&&'elementStart'==_0x35f5e3['type']||'remove'==_0x311369&&'elementEnd'==_0x35f5e3['type'])continue;if(_0x3adadf&&-0x1==_0x3adadf['type']['indexOf']('Container')){'text'==_0x3adadf['type']&&(_0x3adadf[_0x311369]+='\x0a');continue;}let _0x41790e;if(_0x41790e='add'==_0x311369?_0x336731['nextSibling']&&!this['_schema']['isObject'](_0x336731['nextSibling'])?_0x336731['nextSibling']:null:_0x336731['previousSibling']&&!this['_schema']['isObject'](_0x336731['previousSibling'])?_0x336731['previousSibling']:null,_0x336731['isEmpty']||_0x41790e&&_0x41790e['isEmpty']){const _0x1c65cb=_0x41790e&&_0x41790e['isEmpty']?_0x41790e:_0x336731;_0x3adadf&&_0x3adadf['type']==_0x311369+'EmptyContainer'&&_0x3adadf['element']['name']==_0x1c65cb['name']?_0x3adadf['quantity']++:_0xfc9202['push']({'type':_0x311369+'EmptyContainer','element':_0x1c65cb,'quantity':0x1});}else _0xfc9202['push']({'type':_0x311369+'Container','element':_0x336731});}}}}}['_resolveDescriptionItems'](_0x5b9926){const _0x4d1212=this['_locale'],_0xa20285=[],_0x54de15=[],_0x36276b=[];for(const _0x1fe43b of _0x5b9926)switch(_0x1fe43b['type']){case'text':if(_0x1fe43b['add']=_0x1fe43b['add']['replace'](/(\S)\u000A+(\S)/g,'$1\x20$2')['replace'](/\u000A/g,''),_0x1fe43b['remove']=_0x1fe43b['remove']['replace'](/(\S)\u000A+(\S)/g,'$1\x20$2')['replace'](/\u000A/g,''),''!=_0x1fe43b['add']&&''!=_0x1fe43b['remove']){_0xa20285['push']({'type':'replace','content':c(_0x4d1212,'REPLACE_TEXT',['\x22'+_0x1fe43b['remove']+'\x22','\x22'+_0x1fe43b['add']+'\x22'])});continue;}if(null!=_0x1fe43b['add']['match'](/^ +$/)){_0xa20285['push']({'type':'insertion','content':c(_0x4d1212,'*Insert:*\x20%0',c(_0x4d1212,'ELEMENT_SPACE',_0x1fe43b['add']['length']))});continue;}if(null!=_0x1fe43b['remove']['match'](/^ +$/)){_0xa20285['push']({'type':'deletion','content':c(_0x4d1212,'*Remove:*\x20%0',c(_0x4d1212,'ELEMENT_SPACE',_0x1fe43b['remove']['length']))});continue;}if(''!=_0x1fe43b['add']){_0xa20285['push']({'type':'insertion','content':c(_0x4d1212,'*Insert:*\x20%0','\x22'+_0x1fe43b['add']+'\x22')});continue;}_0xa20285['push']({'type':'deletion','content':c(_0x4d1212,'*Remove:*\x20%0','\x22'+_0x1fe43b['remove']+'\x22')});continue;case'addEmptyContainer':case'addObject':_0xa20285['push']({'type':'insertion','content':c(_0x4d1212,'*Insert:*\x20%0',this['getItemLabel'](_0x1fe43b['element'],_0x1fe43b['quantity']))});continue;case'removeEmptyContainer':case'removeObject':_0xa20285['push']({'type':'deletion','content':c(_0x4d1212,'*Remove:*\x20%0',this['getItemLabel'](_0x1fe43b['element'],_0x1fe43b['quantity']))});continue;case'addContainer':_0xa20285['push']({'type':'insertion','content':c(_0x4d1212,'*Split:*\x20%0',this['getItemLabel'](_0x1fe43b['element'],_0x1fe43b['quantity']))});continue;case'removeContainer':_0xa20285['push']({'type':'deletion','content':c(_0x4d1212,'*Merge:*\x20%0',this['getItemLabel'](_0x1fe43b['element'],_0x1fe43b['quantity']))});continue;case'addFormat':_0x54de15['push'](_0x1fe43b['key']);continue;case'removeFormat':_0x36276b['push'](_0x1fe43b['key']);continue;default:_0xa20285['push'](_0x1fe43b);}if(_0x54de15['length']){const _0x34e6e8=_0x54de15['map'](_0x151429=>this['_attributeLabels']['has'](_0x151429)?this['_attributeLabels']['get'](_0x151429):_0x151429)['join'](',\x20');_0xa20285['push']({'type':'format','content':c(this['_locale'],'*Set\x20format:*\x20%0',_0x34e6e8)});}if(_0x36276b['length']){const _0x42ae35=_0x36276b['map'](_0x3aecab=>this['_attributeLabels']['has'](_0x3aecab)?this['_attributeLabels']['get'](_0x3aecab):_0x3aecab)['join'](',\x20');_0xa20285['push']({'type':'format','content':c(this['_locale'],'*Remove\x20format:*\x20%0',_0x42ae35)});}return _0xa20285;}['_handleCustomCallbackDescription'](_0x5086f6){for(const _0x5064d6 of this['_customCallbacks']){const _0x33635a=_0x5064d6(_0x5086f6);if(_0x33635a&&'type'in _0x33635a)return _0x33635a;}}['_handleAttributeSuggestionDescription'](_0x432501,_0x1ff82e){const _0x5dfb3b=_0x1ff82e['data'],_0x447071=void 0x0===_0x5dfb3b['newValue']?'removeFormat':'addFormat';_0x432501['push']({'type':_0x447071,'key':_0x5dfb3b['key']});}['_handleRenameSuggestionDescription'](_0x349987,_0x31de07){_0x349987['push']({'type':'format','content':c(this['_locale'],'*Change\x20to:*\x20%0',this['getItemLabel'](_0x31de07['getFirstRange']()['start']['nodeAfter'],0x1))});}['_handleInsertRemoveSuggestionDescription'](_0x5d3088,_0x171e15,_0x170b13){if(this['_addDescriptionItems'](_0x5d3088,_0x171e15),_0x170b13&&_0x170b13['getFirstRange']()&&!_0x171e15['getFirstRange']()['end']['isEqual'](_0x170b13['getFirstRange']()['start'])){const _0x2a37de=_0x5d3088[_0x5d3088['length']-0x1],_0x1226ef='insertion'==_0x171e15['type']?'add':'remove';_0x2a37de&&'text'==_0x2a37de['type']&&(_0x2a37de[_0x1226ef]+='\x0a');}}}class U extends _0x145e1e{['afterInit'](){const _0x28d680=this['editor'],_0x2d1f02=_0x28d680['plugins']['get']('TrackChangesEditing');_0x28d680['commands']['get']('showAIAssistant')&&_0x2d1f02['enableCommand']('showAIAssistant');}}class V extends _0x145e1e{['afterInit'](){const _0x9809cd=this['editor'],_0x39896a=_0x9809cd['locale'];if(!_0x9809cd['plugins']['has']('AlignmentEditing'))return;const _0x3da3a0=_0x9809cd['plugins']['get']('TrackChangesEditing');_0x3da3a0['enableDefaultAttributesIntegration']('alignment'),_0x3da3a0['registerBlockAttribute']('alignment'),_0x3da3a0['descriptionFactory']['registerAttributeLabel']('alignment',c(_0x39896a,'FORMAT_ALIGNMENT')),this['_registerLegacyDescription']();}['_registerLegacyDescription'](){const _0x2dbe63=this['editor'],_0x2bda93=_0x2dbe63['locale'];_0x2dbe63['plugins']['get']('TrackChangesEditing')['descriptionFactory']['registerDescriptionCallback'](_0x1c7135=>{if('formatBlock'!=_0x1c7135['type'])return;const {data:_0x21fa1f}=_0x1c7135;if(_0x21fa1f&&'alignment'==_0x21fa1f['commandName']){const _0x44d544=_0x21fa1f['commandParams'][0x0]['value'];return{'type':'format','content':c(_0x2bda93,'*Format:*\x20%0',function(_0x3e6768){switch(_0x3e6768){case'left':return c(_0x2bda93,'FORMAT_ALIGN_TO_LEFT');case'right':return c(_0x2bda93,'FORMAT_ALIGN_TO_RIGHT');case'center':return c(_0x2bda93,'FORMAT_ALIGN_TO_CENTER');case'justify':return c(_0x2bda93,'FORMAT_JUSTIFY_TEXT');}}(_0x44d544))};}});}}const ti=['BoldEditing','ItalicEditing','UnderlineEditing','CodeEditing','StrikethroughEditing','SubscriptEditing','SuperscriptEditing'];class F extends _0x145e1e{['afterInit'](){const _0x3091de=this['editor'],_0x2dd653=_0x3091de['plugins']['get']('TrackChangesEditing'),_0x109f10=_0x3091de['locale'];for(const _0x49c65c of ti){if(!_0x3091de['plugins']['has'](_0x49c65c))continue;const _0x3fc071=_0x49c65c['slice'](0x0,-0x7)['toLowerCase'](),_0x270f8f='FORMAT_'+_0x3fc071['toUpperCase']();_0x2dd653['enableDefaultAttributesIntegration'](_0x3fc071),_0x2dd653['registerInlineAttribute'](_0x3fc071),_0x2dd653['descriptionFactory']['registerAttributeLabel'](_0x3fc071,c(_0x109f10,_0x270f8f));}this['_registerLegacyDescription']();}['_registerLegacyDescription'](){const _0x374f79=this['editor'],_0x20e9bc=_0x374f79['locale'],_0x1fc185=_0x374f79['plugins']['get']('TrackChangesEditing');function _0x5cb757(_0x445f1e,_0x256786){_0x1fc185['descriptionFactory']['registerDescriptionCallback'](_0x3df2af=>{if('formatInline'!=_0x3df2af['type'])return;const {data:_0x598a81}=_0x3df2af;return _0x598a81&&_0x598a81['commandName']===_0x445f1e?_0x598a81['commandParams'][0x0]['forceValue']?{'type':'format','content':c(_0x20e9bc,'*Format:*\x20%0',_0x256786)}:{'type':'format','content':c(_0x20e9bc,'*Remove\x20format:*\x20%0',_0x256786)}:void 0x0;});}_0x5cb757('bold',c(_0x20e9bc,'FORMAT_BOLD')),_0x5cb757('italic',c(_0x20e9bc,'FORMAT_ITALIC')),_0x5cb757('underline',c(_0x20e9bc,'FORMAT_UNDERLINE')),_0x5cb757('code',c(_0x20e9bc,'FORMAT_CODE')),_0x5cb757('strikethrough',c(_0x20e9bc,'FORMAT_STRIKETHROUGH')),_0x5cb757('subscript',c(_0x20e9bc,'FORMAT_SUBSCRIPT')),_0x5cb757('superscript',c(_0x20e9bc,'FORMAT_SUPERSCRIPT'));}}class G extends _0x145e1e{['afterInit'](){const _0x4b72d1=this['editor'],_0x4f8299=_0x4b72d1['locale'];if(!_0x4b72d1['plugins']['has']('BlockQuoteEditing'))return;const _0x4bc3ea=_0x4b72d1['plugins']['get']('TrackChangesEditing'),_0x5d97e9=this['editor']['commands']['get']('blockQuote');_0x4bc3ea['enableCommand']('blockQuote',(_0x24fcf9,_0x4da956={})=>{const _0x206363=this['editor']['model']['document']['selection'],_0x1dca6a=_0x4da956&&void 0x0!==_0x4da956['forceValue']?_0x4da956['forceValue']:!_0x5d97e9['value'];let _0x2ad71c=[];if(_0x1dca6a){const _0x1323bb=Array['from'](_0x206363['getSelectedBlocks']())['filter'](_0x5e6768=>oo(_0x5e6768)||function(_0x4fb6ff,_0x54b782){const _0x435fd6=_0x54b782['checkChild'](_0x4fb6ff['parent'],'blockQuote'),_0x17ba66=_0x54b782['checkChild'](['$root','blockQuote'],_0x4fb6ff);return _0x435fd6&&_0x17ba66;}(_0x5e6768,this['editor']['model']['schema']));_0x2ad71c=to(_0x1323bb,_0x4b72d1['model']);}else{const _0x3ec4ff=Array['from'](_0x206363['getSelectedBlocks']())['filter'](_0x1e78bf=>oo(_0x1e78bf));_0x2ad71c=to(_0x3ec4ff,_0x4b72d1['model']);}_0x4b72d1['model']['change'](()=>{for(const _0x31ad3b of _0x2ad71c)_0x4bc3ea['markBlockFormat'](_0x31ad3b,{'commandName':'blockQuote','commandParams':[{'forceValue':_0x1dca6a}]});});}),_0x4bc3ea['descriptionFactory']['registerDescriptionCallback'](_0x445f71=>{const {data:_0x52cbe0}=_0x445f71;if(_0x52cbe0&&'blockQuote'==_0x52cbe0['commandName']){const _0x1f8ee4=c(_0x4f8299,'ELEMENT_BLOCK_QUOTE');return _0x52cbe0['commandParams'][0x0]['forceValue']?{'type':'format','content':c(_0x4f8299,'*Set\x20format:*\x20%0',_0x1f8ee4)}:{'type':'format','content':c(_0x4f8299,'*Remove\x20format:*\x20%0',_0x1f8ee4)};}});}}function oo(_0x26de39){return'blockQuote'==_0x26de39['parent']['name'];}class L extends _0x145e1e{['afterInit'](){const _0x11598e=this['editor'],_0x22aee0=_0x11598e['locale'],_0x30b08b=_0x11598e['plugins']['get']('TrackChangesEditing');_0x11598e['plugins']['has']('BookmarkEditing')&&(_0x30b08b['enableCommand']('insertBookmark'),_0x30b08b['enableDefaultAttributesIntegration']('updateBookmark'),_0x30b08b['registerBlockAttribute']('bookmarkId'),_0x30b08b['descriptionFactory']['registerDescriptionCallback'](_0x4e4e63=>{if('insertion'!=_0x4e4e63['type']&&'deletion'!=_0x4e4e63['type']&&'attribute'!=_0x4e4e63['type'])return;const _0xde3f36=_0x4e4e63['getContainedElement']();if(null==_0xde3f36)return;if(!_0xde3f36['is']('element','bookmark'))return;const _0x576202=_0xde3f36['getAttribute']('bookmarkId');if('insertion'==_0x4e4e63['type'])return{'type':'insertion','content':c(_0x22aee0,'*Insert:*\x20%0','\x22'+_0x576202+'\x22\x20'+c(_0x22aee0,'ELEMENT_BOOKMARK'))};if('deletion'==_0x4e4e63['type'])return{'type':'deletion','content':c(_0x22aee0,'*Remove:*\x20%0','\x22'+_0x576202+'\x22\x20'+c(_0x22aee0,'ELEMENT_BOOKMARK'))};const {data:_0x317a44}=_0x4e4e63;if(!_0x317a44||'bookmarkId'!=_0x317a44['key'])return;return{'type':'format','content':c(_0x22aee0,'*Set\x20bookmark:*\x20%0','\x22'+_0x317a44['newValue']+'\x22')};}));}}class J extends _0x145e1e{['afterInit'](){const _0x40822b=this['editor'];_0x40822b['plugins']['has']('CaseChange')&&(_0x40822b['plugins']['get']('TrackChangesEditing')['enableCommand']('changeCaseUpper'),_0x40822b['plugins']['get']('TrackChangesEditing')['enableCommand']('changeCaseLower'),_0x40822b['plugins']['get']('TrackChangesEditing')['enableCommand']('changeCaseTitle'));}}class K extends _0x145e1e{['afterInit'](){const _0x31638a=this['editor'];_0x31638a['commands']['get']('ckbox')&&_0x31638a['plugins']['get']('TrackChangesEditing')['enableCommand']('ckbox');}}class H extends _0x145e1e{['afterInit'](){const _0x437b09=this['editor'];if(!_0x437b09['plugins']['has']('CodeBlock'))return;const _0x387ef8=_0x437b09['plugins']['get']('TrackChangesEditing'),_0x583abc=_0x437b09['locale'],_0x29ca0a=_0x437b09['config']['get']('codeBlock')['languages'],_0x212ff3=_0x437b09['commands']['get']('codeBlock');_0x387ef8['enableCommand']('indentCodeBlock'),_0x387ef8['enableCommand']('outdentCodeBlock'),_0x387ef8['enableCommand']('codeBlock',(_0x4f7e63,_0x19c9cb={})=>{const _0x5e994f=_0x437b09['model'],_0x36618d=_0x437b09['model']['document']['selection'],_0x56d1dc=_0x19c9cb&&void 0x0!==_0x19c9cb['forceValue']?_0x19c9cb['forceValue']:!_0x212ff3['value'];let _0x24aa25;_0x19c9cb['language']||(_0x19c9cb['language']=_0x29ca0a[0x0]['language']),_0x24aa25=_0x56d1dc?Array['from'](_0x36618d['getSelectedBlocks']())['filter'](_0x56fbfd=>eo(_0x56fbfd)||function(_0xe3f248,_0x38b034){if(_0xe3f248['is']('rootElement')||_0x38b034['isLimit'](_0xe3f248))return!0x1;return _0x38b034['checkChild'](_0xe3f248['parent'],'codeBlock');}(_0x56fbfd,_0x5e994f['schema'])):Array['from'](_0x36618d['getSelectedBlocks']())['filter'](_0x39120f=>eo(_0x39120f));const _0x4e555c=to(_0x24aa25,_0x5e994f);_0x5e994f['change'](()=>{for(const _0x26e90b of _0x4e555c)_0x387ef8['markBlockFormat'](_0x26e90b,{'commandName':'codeBlock','commandParams':[{..._0x19c9cb,'forceValue':_0x56d1dc}],'formatGroupId':'blockName'});});}),(_0x387ef8['descriptionFactory']['registerElementLabel']('codeBlock',_0x5f05a7=>c(_0x583abc,'ELEMENT_CODE_BLOCK',_0x5f05a7)),_0x387ef8['descriptionFactory']['registerDescriptionCallback'](_0x18cdef=>{if('formatBlock'!=_0x18cdef['type'])return;const _0x1daf03=_0x583abc['t'],{data:_0x304359}=_0x18cdef;if(!_0x304359||'codeBlock'!=_0x304359['commandName'])return;const _0xc7ca92=_0x304359['commandParams'][0x0]['language'],_0x5b61fa=_0x1daf03(_0x29ca0a['find'](_0x5a68b1=>_0x5a68b1['language']===_0xc7ca92)['label'])['toLowerCase']();return _0x304359['commandParams'][0x0]['forceValue']?{'type':'format','content':c(_0x583abc,'*Set\x20format:*\x20%0',c(_0x583abc,'ELEMENT_CODE_BLOCK',0x1)+'\x20('+_0x5b61fa+')')}:{'type':'format','content':c(_0x583abc,'*Remove\x20format:*\x20%0',c(_0x583abc,'ELEMENT_CODE_BLOCK',0x1))};}));}}function eo(_0x161d3a){return'codeBlock'==_0x161d3a['name'];}class q extends _0x145e1e{['afterInit'](){const _0x37068c=this['editor'];if(!_0x37068c['plugins']['has']('CommentsEditing'))return;_0x37068c['plugins']['get']('TrackChangesEditing')['enableCommand']('addCommentThread');}}function io(_0x82909c,_0x4181cb,_0xf9ea3f){const _0x75ae91=[];for(const _0xc85ece of _0x4181cb['getItems']())_0xc85ece['hasAttribute'](_0x82909c)&&_0x75ae91['push'](_0xf9ea3f['createRangeOn'](_0xc85ece));return _0x75ae91;}function Fe(_0x408224,_0x5469ea,{showActiveMarker:_0x1dab78=!0x0}={}){const _0x1bc7c8=_0x408224['plugins']['get']('TrackChangesEditing');return(_0x3bfbfc,_0x1a9d45,_0x666673)=>{if(!_0x666673['consumable']['test'](_0x1a9d45['markerRange'],_0x3bfbfc['name']))return;const _0x4f8201=_0x1a9d45['markerRange']['getWalker'](),_0x1c6f1c=_0x1a9d45['markerRange']['start'],_0x8506d5=_0x408224['model']['schema'];let _0x4d1076=null,_0x3b2b6f=null,_0x2996d7=!0x1,_0x1031ec=!0x1;for(const _0x346be6 of _0x4f8201){const _0x56bc53=_0x346be6['item'];_0x2996d7=_0x2996d7||_0x8506d5['isContent'](_0x56bc53);const _0x3d8395=_0x666673['mapper']['toViewElement'](_0x56bc53);if(_0x3d8395&&_0x3d8395['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x346be6['type']&&(_0x8506d5['isBlock'](_0x56bc53)&&!_0x8506d5['isLimit'](_0x56bc53)&&(_0x56bc53['nextSibling']||_0x1c6f1c['isAtEnd']?_0x4d1076&&_0x4d1076['parent']==_0x56bc53||(_0x4d1076=_0x56bc53,_0x17df64(_0x346be6['previousPosition']),_0x1031ec=!0x0):_0x3b2b6f=_0x3b2b6f||_0x346be6['previousPosition']));}function _0x17df64(_0x357b18){const {id:_0x192266,authorId:_0x4b708c}=_0x1bc7c8['_splitMarkerName'](_0x1a9d45['markerName']),_0x1e96c6=_0x666673['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x5469ea,'data-suggestion':_0x192266,'data-author-id':_0x4b708c}),_0x34cd95=_0x666673['mapper']['toViewPosition'](_0x357b18);_0x1dab78&&_0x1bc7c8['activeMarkers']['includes'](_0x1a9d45['markerName'])&&_0x666673['writer']['addClass']('ck-suggestion-marker--active',_0x1e96c6),_0x666673['writer']['insert'](_0x34cd95,_0x1e96c6),_0x666673['mapper']['bindElementToMarker'](_0x1e96c6,_0x1a9d45['markerName']);}_0x2996d7||_0x1031ec||!_0x3b2b6f||_0x17df64(_0x3b2b6f);};}class z extends _0x145e1e{static get['requires'](){return[_0x2e4424];}['init'](){const _0x147a39=this['editor'],_0x2177d6=_0x147a39['plugins']['get']('TrackChangesEditing');_0x2177d6['enableCommand']('delete');const _0x36e9ee=_0x147a39['commands']['get']('deleteForward');_0x2177d6['enableCommand']('deleteForward',(_0x578eb2,_0x5de039={})=>{const _0x4d9f26=_0x147a39['model']['createSelection'](_0x147a39['model']['document']['selection']);_0x4d9f26['isCollapsed']&&_0x147a39['model']['modifySelection'](_0x4d9f26,{'direction':'forward','unit':_0x5de039['unit']});const _0x3e5da8=_0x4d9f26['getFirstRange'](),_0xc4d3f5=_0x1d9e5c['fromRange'](_0x3e5da8);let _0x4c8c18;_0x578eb2(_0x5de039),_0x4c8c18='$graveyard'==_0xc4d3f5['root']['rootName']?_0x147a39['model']['createRange'](_0x3e5da8['start']):_0x147a39['model']['createRange'](_0xc4d3f5['start'],_0xc4d3f5['end']),_0xc4d3f5['detach'](),_0x147a39['model']['enqueueChange'](_0x36e9ee['buffer']['batch'],_0x4eb534=>{_0x36e9ee['buffer']['lock'](),_0x4eb534['setSelection'](_0x4eb534['createRange'](_0x4c8c18['end'])),_0x36e9ee['buffer']['unlock']();});}),_0x147a39['editing']['downcastDispatcher']['on']('addMarker:suggestion:deletion',Fe(_0x147a39,'merge'),{'priority':'high'}),_0x147a39['data']['downcastDispatcher']['on']('addMarker:suggestion:deletion',(_0x1492ca,_0x9c71c7,_0x252838)=>{_0x252838['options']['showSuggestionHighlights']&&Fe(_0x147a39,'merge',{'showActiveMarker':!0x1})['bind'](this)(_0x1492ca,_0x9c71c7,_0x252838);},{'priority':'high'}),_0x147a39['editing']['downcastDispatcher']['on']('removeMarker:suggestion:deletion',(_0x295f66,_0x24f761,_0x69619e)=>{const _0x59d51d=_0x69619e['mapper']['markerNameToElements'](_0x24f761['markerName']);if(_0x59d51d){for(const _0x2d3ec3 of _0x59d51d)_0x2d3ec3['is']('uiElement')&&(_0x69619e['mapper']['unbindElementFromMarkerName'](_0x2d3ec3,_0x24f761['markerName']),_0x69619e['writer']['remove'](_0x2d3ec3));}},{'priority':'high'});}}class W extends _0x145e1e{['afterInit'](){const _0x4b3525=this['editor'];if(!_0x4b3525['plugins']['has']('ListEditing'))return;const _0x1f607b=_0x4b3525['locale'],_0x229b4c=_0x4b3525['plugins']['get']('TrackChanges