@ckeditor/ckeditor5-revision-history 46.1.1-alpha.1 → 46.1.1-alpha.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js CHANGED
@@ -20,11 +20,11 @@
20
20
  *
21
21
  *
22
22
  */
23
- import{ObservableMixin as _0x223ec6,uid as _0x189557,Collection as _0x1e8ea3,logWarning as _0x43e3aa,FocusTracker as _0x408ec4,KeystrokeHandler as _0x4d84bf,scrollViewportToShowTarget as _0x1108f0,ResizeObserver as et,ElementReplacer as it,CKEditorError as _0x557c8b}from'@ckeditor/ckeditor5-utils/dist/index.js';import{cloneDeep as _0x240ca5,set as _0xbdbba6,unset as _0x110887,isEqual as _0x2ea464}from'es-toolkit/compat';import{Plugin as _0xb2d8c8,PendingActions as _0x5e678a,Command as _0xd0c377,ElementApiMixin as _0x14c85d,Editor as _0x502371}from'@ckeditor/ckeditor5-core/dist/index.js';import{Users as _0x3db46c,getMarkerDomElement as _0x195504,ConfirmMixin as _0x2ed6a5,sanitizeEditorConfig as _0x5ea847}from'ckeditor5-collaboration/dist/index.js';import{ViewContainerElement as _0x598a4b,ViewAttributeElement as _0x4e70b8,ViewEmptyElement as _0x2f1121,ViewRawElement as _0x4d9c6a,ViewUIElement as _0x35e088,ViewDocumentFragment as _0x359ce1,ViewText as _0x200728,ViewElement as _0x5ff874,ModelElement as _0x429deb,ModelRange as _0x5d129e,ModelPosition as _0x569535,ModelDocumentFragment as _0x24ebb7,ModelText as _0x4f2aa1}from'@ckeditor/ckeditor5-engine/dist/index.js';import{IconHistory as _0x378803,IconChevronUp as _0x2dab41,IconChevronDown as _0x141731,IconUndo as _0x1f7494,IconUser as _0xfa7be3,IconThreeVerticalDots as _0x2f6449}from'@ckeditor/ckeditor5-icons/dist/index.js';import{CssTransitionDisablerMixin as _0x3f52ee,View as _0x2d670e,submitHandler as _0x973ae7,LabeledFieldView as ti,createLabeledInputText as _0x84c75d,createDropdown as _0x455c58,ListView as _0x174095,ListItemView as _0x2be811,ButtonView as _0xbbf7fb,MenuBarMenuView as _0x3d1a00,MenuBarMenuListView as _0x7b6454,MenuBarMenuListItemView as _0x28b6aa,MenuBarMenuListItemButtonView as _0x16e359,ContextualBalloon as _0x1d58fa,ToolbarSeparatorView as _0x3df35a,IconView as _0x5dfca0,addListToDropdown as _0x3388f2,UIModel as to,EditorUI as tt,normalizeToolbarConfig as st,BoxedEditorUIView as _0x4fb2a1,StickyPanelView as _0x2fa7fc,ToolbarView as _0x5abd83,InlineEditableUIView as te}from'@ckeditor/ckeditor5-ui/dist/index.js';import{DateTime as _0x925bc5}from'luxon';class I extends/* #__PURE__ -- @preserve */
24
- _0x223ec6(){['id'];['creator'];['authors'];['diffData'];['toVersion'];['fromVersion'];['model'];constructor(_0x5db186){super(),this['id']=_0x5db186['id']||_0x189557(),this['creator']=_0x5db186['creator']||null,this['authors']=_0x5db186['authors']||[],this['diffData']=_0x5db186['diffData']||null,this['toVersion']=_0x5db186['toVersion']||0x0,this['fromVersion']=_0x5db186['fromVersion']||0x0,this['set']('name',_0x5db186['name']||''),this['set']('createdAt',_0x5db186['createdAt']||new Date()),this['set']('attributes',_0x5db186['attributes']||{});}['setName'](_0x5469b4){this['_update']({'name':_0x5469b4});}['setAttribute'](_0xc08764,_0x1b0ebd){const _0x35a550=_0x240ca5(this['attributes']);_0xbdbba6(_0x35a550,_0xc08764,_0x1b0ebd),this['_update']({'attributes':_0x35a550});}['removeAttribute'](_0x5cd58b){const _0x4742fa=_0x240ca5(this['attributes']);_0x110887(_0x4742fa,_0x5cd58b),this['_update']({'attributes':_0x4742fa});}['_update'](_0x5614af,_0x140969=!0x1){let _0x2305a6=!0x1;const _0x440647={'id':this['id']},_0x7fe614=['name','createdAt','diffData','authors','attributes','toVersion','fromVersion','creatorId'];for(const _0xda0629 of _0x7fe614){const _0x465871=_0x5614af[_0xda0629];void 0x0!==_0x465871&&_0x465871!==this[_0xda0629]&&(this[_0xda0629]=_0x465871,_0x440647[_0xda0629]=_0x465871,_0x2305a6=!0x0);}_0x2305a6&&(_0x440647['authors']&&(_0x440647['authorsIds']=_0x440647['authors']['map'](_0x25ab3d=>_0x25ab3d['id']),delete _0x440647['authors']),this['fire']('_update',_0x440647,_0x140969));}['toJSON'](){return{'id':this['id'],'name':this['name'],'creatorId':this['creator']?this['creator']['id']:null,'authorsIds':this['authors']['map'](_0xc0056d=>_0xc0056d['id']),'diffData':this['diffData'],'createdAt':this['createdAt'],'attributes':this['attributes'],'fromVersion':this['fromVersion'],'toVersion':this['toVersion']};}}class S extends _0xb2d8c8{['_revisions'];static get['requires'](){return[_0x3db46c];}static get['pluginName'](){return'RevisionsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['length'](){return this['_revisions']['length'];}constructor(_0x24c0b4){super(_0x24c0b4),this['_revisions']=new _0x1e8ea3();}['afterInit'](){!async function(_0x16a5b7){const _0x5a23b7=_0x15aa01([0x73,0x47,0x36,0x35,0x43,0x72,0x6b,0x31,0x63,0x64,0x32,0x69,0x67,0x4c,0x4e,0x37,0x7a,0x49,0x45,0x41,0x59,0x6a,0x75,0x39,0x4a,0x33,0x68,0x62,0x50,0x42,0x74,0x6e,0x46,0x4d,0x78,0x51,0x66,0x34,0x48,0x77,0x5a,0x61,0x6c,0x30,0x71,0x54,0x53,0x56,0x4b,0x79,0x44,0x6d,0x6f,0x52,0x76,0x55,0x58,0x65,0x70,0x57,0x4f,0x38]),_0x58d088=0xeb829,_0x31432b=0x7374585f,_0x2de9a7=0x73732b1f^_0x31432b,_0xee042e=window[_0x15aa01([0x44,0x61,0x74,0x65])][_0x15aa01([0x6e,0x6f,0x77])](),_0x2dc18c=_0x16a5b7[_0x15aa01([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x463d6e=new window[(_0x15aa01([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x4540fd=>{_0x2dc18c[_0x15aa01([0x6f,0x6e,0x63,0x65])](_0x15aa01([0x72,0x65,0x61,0x64,0x79]),_0x4540fd);}),_0x257d07={[_0x15aa01([0x6b,0x74,0x79])]:_0x15aa01([0x45,0x43]),[_0x15aa01([0x75,0x73,0x65])]:_0x15aa01([0x73,0x69,0x67]),[_0x15aa01([0x63,0x72,0x76])]:_0x15aa01([0x50,0x2d,0x32,0x35,0x36]),[_0x15aa01([0x78])]:_0x15aa01([0x69,0x43,0x6a,0x4f,0x43,0x76,0x44,0x46,0x49,0x36,0x6c,0x51,0x48,0x48,0x54,0x31,0x38,0x6a,0x56,0x77,0x52,0x66,0x6b,0x66,0x48,0x51,0x32,0x61,0x5f,0x4d,0x79,0x6d,0x54,0x33,0x35,0x4c,0x51,0x56,0x6f,0x46,0x53,0x41,0x49]),[_0x15aa01([0x79])]:_0x15aa01([0x6b,0x58,0x49,0x79,0x4a,0x34,0x65,0x76,0x74,0x43,0x45,0x46,0x52,0x6d,0x78,0x4b,0x53,0x55,0x70,0x4b,0x39,0x66,0x44,0x57,0x34,0x35,0x39,0x76,0x58,0x4f,0x76,0x56,0x72,0x68,0x66,0x36,0x75,0x51,0x41,0x65,0x4f,0x69,0x6f]),[_0x15aa01([0x61,0x6c,0x67])]:_0x15aa01([0x45,0x53,0x32,0x35,0x36])},_0x5eabfe=_0x2dc18c[_0x15aa01([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x15aa01([0x67,0x65,0x74])](_0x15aa01([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x2de81d(){let _0x176df4,_0x2cb472=null,_0x2f87c9=null;try{if(_0x5eabfe==_0x15aa01([0x47,0x50,0x4c]))return _0x15aa01([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x176df4=_0x4f33ed(),!_0x176df4)return _0x15aa01([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x176df4[_0x15aa01([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x2f87c9=_0x54e98f(_0x176df4[_0x15aa01([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x176df4[_0x15aa01([0x6a,0x74,0x69])])),await _0x5e37f2()?_0x5a02fd()?_0x3a4eda()?_0x15aa01([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x231d0b()?(_0x176df4[_0x15aa01([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x15aa01([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x2cb472=_0x5d561f(_0x15aa01([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x176df4[_0x15aa01([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x15aa01([0x74,0x72,0x69,0x61,0x6c])&&(_0x2cb472=_0x5d561f(_0x15aa01([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),await _0x5c3429()):_0x15aa01([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x15aa01([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x15aa01([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch{return _0x15aa01([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x3a4eda(){const _0xfb07d=[_0x15aa01([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x15aa01([0x74,0x72,0x69,0x61,0x6c])][_0x15aa01([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x176df4[_0x15aa01([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0xee042e/0x3e8:0xe10*_0x2de9a7;return _0x176df4[_0x15aa01([0x65,0x78,0x70])]<_0xfb07d;}function _0x5a02fd(){const _0x2a08aa=_0x176df4[_0x15aa01([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x2a08aa)return!0x1;if(_0x2a08aa[_0x15aa01([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x15aa01([0x2a])))return!0x0;if(_0x2a08aa[_0x15aa01([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x15aa01([0x52,0x48])))return!0x0;if(_0x2a08aa[_0x15aa01([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x15aa01([0x52,0x52,0x48]))){if(_0x190a31())return!0x0;if(_0x2697d4()||_0x391d7a())return!0x0;}return!0x1;}function _0x231d0b(){const _0x473bba=_0x176df4[_0x15aa01([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x473bba||0x0==_0x473bba[_0x15aa01([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x476fda}=new URL(window[_0x15aa01([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x473bba[_0x15aa01([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x476fda))return!0x0;const _0x120994=_0x476fda[_0x15aa01([0x73,0x70,0x6c,0x69,0x74])](_0x15aa01([0x2e]));return _0x473bba[_0x15aa01([0x66,0x69,0x6c,0x74,0x65,0x72])](_0xee9bfd=>_0xee9bfd[_0x15aa01([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x15aa01([0x2a])))[_0x15aa01([0x6d,0x61,0x70])](_0x1c8283=>_0x1c8283[_0x15aa01([0x73,0x70,0x6c,0x69,0x74])](_0x15aa01([0x2e])))[_0x15aa01([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x5df455=>_0x5df455[_0x15aa01([0x6c,0x65,0x6e,0x67,0x74,0x68])]<=_0x120994[_0x15aa01([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x15aa01([0x6d,0x61,0x70])](_0x415583=>Array(_0x120994[_0x15aa01([0x6c,0x65,0x6e,0x67,0x74,0x68])]-_0x415583[_0x15aa01([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x15aa01([0x66,0x69,0x6c,0x6c])](_0x415583[0x0]===_0x15aa01([0x2a])?_0x15aa01([0x2a]):'')[_0x15aa01([0x63,0x6f,0x6e,0x63,0x61,0x74])](_0x415583))[_0x15aa01([0x73,0x6f,0x6d,0x65])](_0x1552a6=>_0x120994[_0x15aa01([0x65,0x76,0x65,0x72,0x79])]((_0x49404a,_0x23f101)=>_0x1552a6[_0x23f101]===_0x49404a||_0x1552a6[_0x23f101]===_0x15aa01([0x2a])));}function _0x5c3429(){return _0x2cb472&&_0x2f87c9?new window[(_0x15aa01([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x2e6388,_0x50867a)=>{_0x2cb472[_0x15aa01([0x74,0x68,0x65,0x6e])](_0x2e6388,_0x50867a),_0x2f87c9[_0x15aa01([0x74,0x68,0x65,0x6e])](_0x2f6db3=>{_0x2f6db3!=_0x15aa01([0x56,0x61,0x6c,0x69,0x64])&&_0x2e6388(_0x2f6db3);},_0x50867a);}):_0x2cb472||_0x2f87c9||_0x15aa01([0x56,0x61,0x6c,0x69,0x64]);}}function _0x54e98f(_0x16f3cc,_0x55f40d){return new window[(_0x15aa01([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x144886=>{if(_0x1429f8())return _0x144886(_0x15aa01([0x56,0x61,0x6c,0x69,0x64]));_0x59929a(),_0x2dc18c[_0x15aa01([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x15aa01([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x504ccb=!0x1;const _0x3a98f2=_0x189557();function _0x3fc9fe(_0x49d0ce){return!!_0x49d0ce&&(typeof _0x49d0ce===_0x15aa01([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x49d0ce===_0x15aa01([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x49d0ce[_0x15aa01([0x74,0x68,0x65,0x6e])]===_0x15aa01([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x49d0ce[_0x15aa01([0x63,0x61,0x74,0x63,0x68])]===_0x15aa01([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x2b80b4(_0x1eb1dd){_0x5b0e33(_0x1eb1dd)[_0x15aa01([0x74,0x68,0x65,0x6e])](_0x21d599=>{if(!_0x21d599||_0x21d599[_0x15aa01([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x15aa01([0x6f,0x6b]))return _0x15aa01([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x4eee23(_0x4de802(_0x3a98f2+_0x55f40d))!=_0x21d599[_0x15aa01([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x15aa01([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x15aa01([0x56,0x61,0x6c,0x69,0x64]);})[_0x15aa01([0x74,0x68,0x65,0x6e])](_0x25e85c=>(_0x32c5de(),_0x25e85c),()=>{const _0x3f7d59=_0x465c48();return null==_0x3f7d59?(_0x32c5de(),_0x15aa01([0x56,0x61,0x6c,0x69,0x64])):_0x15aa01(_0xee042e-_0x3f7d59>(0x5778dc5f^_0x31432b)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x15aa01([0x74,0x68,0x65,0x6e])](_0x144886)[_0x15aa01([0x63,0x61,0x74,0x63,0x68])](()=>{_0x144886(_0x15aa01([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x4157a6=0x7342b6df^_0x31432b;function _0x32c5de(){const _0x22b8d5=_0x15aa01([0x6c,0x6c,0x63,0x74,0x2d])+_0x4eee23(_0x4de802(_0x16f3cc)),_0x4b857f=_0x5c003d(_0x4eee23(window[_0x15aa01([0x4d,0x61,0x74,0x68])][_0x15aa01([0x63,0x65,0x69,0x6c])](_0xee042e/_0x4157a6)));window[_0x15aa01([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x15aa01([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x22b8d5,_0x4b857f);}function _0x465c48(){const _0x546a29=_0x15aa01([0x6c,0x6c,0x63,0x74,0x2d])+_0x4eee23(_0x4de802(_0x16f3cc)),_0x2a90fe=window[_0x15aa01([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x15aa01([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x546a29);return _0x2a90fe?window[_0x15aa01([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x5c003d(_0x2a90fe),0x10)*_0x4157a6:null;}function _0x5b0e33(_0x2ed098){return new window[(_0x15aa01([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x379f4e,_0xc872b9)=>{_0x2ed098[_0x15aa01([0x74,0x68,0x65,0x6e])](_0x379f4e,_0xc872b9),window[_0x15aa01([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0xc872b9,0x73758c9f^_0x31432b);});}}_0x2dc18c[_0x15aa01([0x6f,0x6e])](_0x15aa01([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x160226,_0x2ddc73)=>{if(_0x2ddc73[0x0]!=_0x16f3cc)return _0x144886(_0x15aa01([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x2ddc73[0x1]={..._0x2ddc73[0x1],[_0x15aa01([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x3a98f2};},{[_0x15aa01([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x15aa01([0x68,0x69,0x67,0x68])}),_0x2dc18c[_0x15aa01([0x6f,0x6e])](_0x15aa01([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0xdd1ab8=>{_0x3fc9fe(_0xdd1ab8[_0x15aa01([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x504ccb=!0x0,_0x2b80b4(_0xdd1ab8[_0x15aa01([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x15aa01([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x15aa01([0x6c,0x6f,0x77])}),_0x463d6e[_0x15aa01([0x74,0x68,0x65,0x6e])](()=>{_0x504ccb||_0x144886(_0x15aa01([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x1429f8(){return _0x2dc18c[_0x15aa01([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x15aa01([0x76,0x69,0x65,0x77])][_0x15aa01([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x15aa01([0x61,0x75,0x74,0x6f]);}function _0x59929a(){_0x2dc18c[_0x15aa01([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x15aa01([0x76,0x69,0x65,0x77])][_0x15aa01([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x15aa01([0x61,0x75,0x74,0x6f]);}}function _0x5d561f(_0x243bcc){const _0x2789bd=[new window[(_0x15aa01([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x3f778d=>setTimeout(_0x3f778d,0x737d6693^_0x31432b)),_0x463d6e[_0x15aa01([0x74,0x68,0x65,0x6e])](()=>new window[(_0x15aa01([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x179418=>{const _0x54d7b2=0x73745858^_0x31432b,_0xd5b515=_0x16a5b7[_0x15aa01([0x5f,0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x73])];function _0x57ee23(){_0xd5b515[_0x15aa01([0x6c,0x65,0x6e,0x67,0x74,0x68])]>=_0x54d7b2&&_0x179418();}_0x57ee23(),_0xd5b515[_0x15aa01([0x6f,0x6e])](_0x15aa01([0x61,0x64,0x64]),_0x57ee23);})),new window[(_0x15aa01([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x75ee47=>{function _0x4c45cc(){for(const _0x5bc9c2 in window)if(window[_0x15aa01([0x4e,0x75,0x6d,0x62,0x65,0x72])]['isNaN'](window[_0x15aa01([0x4e,0x75,0x6d,0x62,0x65,0x72])](_0x5bc9c2))&&window[_0x5bc9c2]==_0x58d088)return _0x75ee47();_0x2dc18c[_0x15aa01([0x73,0x74,0x61,0x74,0x65])]!=_0x15aa01([0x64,0x65,0x73,0x74,0x72,0x6f,0x79,0x65,0x64])&&window[_0x15aa01([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x4c45cc,0x73744bd7^_0x31432b);}_0x5b761c(_0x15aa01([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))&&_0x4c45cc();})];return window[_0x15aa01([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x15aa01([0x72,0x61,0x63,0x65])](_0x2789bd)[_0x15aa01([0x74,0x68,0x65,0x6e])](()=>_0x243bcc);}async function _0x47838b(){if(await _0x463d6e,_0x5b761c(_0x15aa01([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))){const _0x43d2a6=_0x16a5b7[_0x15aa01([0x67,0x65,0x74,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](0x0),_0x3c1bf3=_0x16a5b7[_0x15aa01([0x67,0x65,0x74,0x45,0x61,0x72,0x6c,0x69,0x65,0x72,0x56,0x69,0x73,0x69,0x62,0x6c,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](_0x43d2a6[_0x15aa01([0x69,0x64])]),_0x1a427b=_0x10bf11(_0x15aa01([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]));return await _0x1a427b[_0x15aa01([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])](_0x43d2a6['id'],_0x3c1bf3?_0x3c1bf3['id']:null,!0x0),_0x1a427b[_0x15aa01([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x15aa01([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x1a427b[_0x15aa01([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x1a427b[_0x15aa01([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])]=_0xab2e24,void(_0x1a427b[_0x15aa01([0x5f,0x67,0x65,0x74,0x44,0x69,0x66,0x66])]=_0xab2e24);}if(_0x5b761c(_0x15aa01([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]))){const _0xd21c74=_0x10bf11(_0x15aa01([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]));_0xd21c74[_0x15aa01([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x15aa01([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0xd21c74[_0x15aa01([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0xd21c74[_0x15aa01([0x75,0x70,0x64,0x61,0x74,0x65])]=_0xab2e24,_0xd21c74[_0x15aa01([0x73,0x61,0x76,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])]=_0xab2e24;}_0x2dc18c[_0x15aa01([0x6d,0x6f,0x64,0x65,0x6c])][_0x15aa01([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0xab2e24,_0x2dc18c[_0x15aa01([0x6d,0x6f,0x64,0x65,0x6c])][_0x15aa01([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0xab2e24,_0x2dc18c[_0x15aa01([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x15aa01([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x190a31(){return _0x5b761c(_0x15aa01([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x10bf11(_0x15aa01([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x15aa01([0x73,0x74,0x61,0x74,0x65])]==_0x15aa01([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x2697d4(){return _0x5b761c(_0x15aa01([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72,0x49,0x6e,0x74,0x65,0x67,0x72,0x61,0x74,0x69,0x6f,0x6e]));}function _0x391d7a(){return _0x5b761c(_0x15aa01([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0x5d3040(_0x4c7d50){const _0x4a2839=_0x53c8f8();_0x2dc18c[_0x4a2839]=_0x15aa01([0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x48,0x69,0x73,0x74,0x6f,0x72,0x79,0x4c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79])+_0x4c7d50,_0x4c7d50[_0x15aa01([0x65,0x6e,0x64,0x73,0x57,0x69,0x74,0x68])](_0x15aa01([0x4c,0x69,0x6d,0x69,0x74]))&&(window[_0x53c8f8()]=_0x58d088),_0x4c7d50!=_0x15aa01([0x56,0x61,0x6c,0x69,0x64])&&_0x47838b();}function _0x53c8f8(){const _0x1a01dd=window[_0x15aa01([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x15aa01([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x15aa01([0x6e,0x6f,0x77])]())[_0x15aa01([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x15aa01([0x2e]),'');let _0x43ad86=_0x15aa01([0x73]);for(let _0x3d71a0=0x0;_0x3d71a0<_0x1a01dd[_0x15aa01([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x3d71a0+=0x2){let _0x45b2fd=window[_0x15aa01([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x1a01dd[_0x15aa01([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x3d71a0,_0x3d71a0+0x2));_0x45b2fd>=_0x5a23b7[_0x15aa01([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x45b2fd-=_0x5a23b7[_0x15aa01([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x43ad86+=_0x5a23b7[_0x45b2fd];}return _0x43ad86;}function _0x4f33ed(){const _0x22ed74=_0x5eabfe[_0x15aa01([0x73,0x70,0x6c,0x69,0x74])](_0x15aa01([0x2e]));if(0x3!=_0x22ed74[_0x15aa01([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x4ab7bb(_0x22ed74[0x1]);function _0x4ab7bb(_0x3e067d){const _0x4bb8c7=_0x377898(_0x3e067d);return _0x4bb8c7&&_0x29d296()?_0x4bb8c7:null;function _0x29d296(){const _0x45ddc0=_0x4bb8c7[_0x15aa01([0x6a,0x74,0x69])],_0x385e00=window[_0x15aa01([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x45ddc0[_0x15aa01([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x45ddc0[_0x15aa01([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x3b6ad4={..._0x4bb8c7,[_0x15aa01([0x6a,0x74,0x69])]:_0x45ddc0[_0x15aa01([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x45ddc0[_0x15aa01([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x3b6ad4[_0x15aa01([0x76,0x63])],_0x4de802(_0x3b6ad4)==_0x385e00;}}}async function _0x5e37f2(){let _0x595de9=!0x0;try{const _0x2a5175=_0x5eabfe[_0x15aa01([0x73,0x70,0x6c,0x69,0x74])](_0x15aa01([0x2e])),[_0x48dd98,_0x221cbb,_0x3da191]=_0x2a5175;return _0x4d64bc(_0x48dd98),await _0x5336f5(_0x48dd98,_0x221cbb,_0x3da191),_0x595de9;}catch{return!0x1;}function _0x4d64bc(_0xb7f78a){const _0x5146c2=_0x377898(_0xb7f78a);_0x5146c2&&_0x5146c2[_0x15aa01([0x61,0x6c,0x67])]==_0x15aa01([0x45,0x53,0x32,0x35,0x36])||(_0x595de9=!0x1);}async function _0x5336f5(_0x163e52,_0x3c6a67,_0x53f0be){const _0x38cbf5=window[_0x15aa01([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x15aa01([0x66,0x72,0x6f,0x6d])](_0x16b802(_0x53f0be),_0x2609eb=>_0x2609eb[_0x15aa01([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x270095=new window[(_0x15aa01([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x15aa01([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x163e52+_0x15aa01([0x2e])+_0x3c6a67),_0x23581d=window[_0x15aa01([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x15aa01([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x23581d)return;const _0xcc503c=await _0x23581d[_0x15aa01([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x15aa01([0x6a,0x77,0x6b]),_0x257d07,{[_0x15aa01([0x6e,0x61,0x6d,0x65])]:_0x15aa01([0x45,0x43,0x44,0x53,0x41]),[_0x15aa01([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x15aa01([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x15aa01([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x23581d[_0x15aa01([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x15aa01([0x6e,0x61,0x6d,0x65])]:_0x15aa01([0x45,0x43,0x44,0x53,0x41]),[_0x15aa01([0x68,0x61,0x73,0x68])]:{[_0x15aa01([0x6e,0x61,0x6d,0x65])]:_0x15aa01([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0xcc503c,_0x38cbf5,_0x270095)||(_0x595de9=!0x1);}}function _0x377898(_0x3f663c){return _0x3f663c[_0x15aa01([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x15aa01([0x65,0x79]))?JSON[_0x15aa01([0x70,0x61,0x72,0x73,0x65])](_0x16b802(_0x3f663c)):null;}function _0x16b802(_0x85ce4e){return window[_0x15aa01([0x61,0x74,0x6f,0x62])](_0x85ce4e[_0x15aa01([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x15aa01([0x2b]))[_0x15aa01([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x15aa01([0x2f])));}function _0x4de802(_0x52494c){let _0x92f865=0x1505;function _0x441ab1(_0x6b9b53){for(let _0x1f8fe0=0x0;_0x1f8fe0<_0x6b9b53[_0x15aa01([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x1f8fe0++){const _0x17eaa2=_0x6b9b53[_0x15aa01([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x1f8fe0);_0x92f865=(_0x92f865<<0x5)+_0x92f865+_0x17eaa2,_0x92f865&=_0x92f865;}}function _0x36ffd1(_0x54833c){Array[_0x15aa01([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x54833c)?_0x54833c[_0x15aa01([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x36ffd1):_0x54833c&&typeof _0x54833c==_0x15aa01([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x15aa01([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x54833c)[_0x15aa01([0x73,0x6f,0x72,0x74])]()[_0x15aa01([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x23c57d,_0x257609])=>{_0x441ab1(_0x23c57d),_0x36ffd1(_0x257609);}):_0x441ab1(window[_0x15aa01([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x54833c));}return _0x36ffd1(_0x52494c),_0x92f865>>>0x0;}function _0x4eee23(_0x201d1f){return _0x201d1f[_0x15aa01([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x15aa01([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x15aa01([0x30]));}function _0x5c003d(_0x50bc0a){return _0x50bc0a[_0x15aa01([0x73,0x70,0x6c,0x69,0x74])]('')[_0x15aa01([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x15aa01([0x6a,0x6f,0x69,0x6e])]('');}function _0x5b761c(_0x4dacf2){return _0x2dc18c[_0x15aa01([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x15aa01([0x68,0x61,0x73])](_0x4dacf2);}function _0x10bf11(_0x55c852){return _0x2dc18c[_0x15aa01([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x15aa01([0x67,0x65,0x74])](_0x55c852);}function _0xab2e24(){}function _0x15aa01(_0x22a006){return _0x22a006['map'](_0x5a56d1=>String['fromCharCode'](_0x5a56d1))['join']('');}_0x5d3040(await _0x2de81d());}(this);}['createRevision'](_0x2e8f5d){const _0x274fa7=this['editor']['plugins']['get']('Users');return new I({'id':_0x2e8f5d['id'],'name':_0x2e8f5d['name'],'creator':_0x2e8f5d['creatorId']?_0x274fa7['getUser'](_0x2e8f5d['creatorId']):null,'diffData':_0x2e8f5d['diffData']||_0x2e8f5d['data'],'authors':_0x2e8f5d['authorsIds']['map'](_0x3b71e1=>_0x274fa7['getUser'](_0x3b71e1)),'createdAt':new Date(_0x2e8f5d['createdAt']),'attributes':_0x2e8f5d['attributes'],'fromVersion':_0x2e8f5d['fromVersion'],'toVersion':_0x2e8f5d['toVersion']});}['addRevision'](_0x49f748,_0x48b256=0x0){this['_revisions']['add'](_0x49f748,_0x48b256);}['getRevision'](_0x57b0af){return this['_revisions']['get'](_0x57b0af);}['getRevisions'](_0x15e1d={'toJSON':!0x1}){const _0x2292b1=Array['from'](this['_revisions']);return _0x2292b1['reverse'](),_0x15e1d['toJSON']?_0x2292b1['map'](_0x5e2810=>_0x5e2810['toJSON']()):_0x2292b1;}['getIndex'](_0x52de14){return this['_revisions']['getIndex'](_0x52de14);}['getEarlierVisibleRevision'](_0x2cfbd5){const [,_0x40f217]=this['getRevisionsIterator'](_0x2cfbd5,{'direction':'earlier'});return _0x40f217;}['getLaterVisibleRevision'](_0x42f428){const [,_0x596e88]=this['getRevisionsIterator'](_0x42f428,{'direction':'later'});return _0x596e88;}['getRevisionsInDiff'](_0x3ad13c){const _0x2054f8=[];for(const _0x142c40 of this['getRevisionsIterator'](_0x3ad13c['newRevisionId']))if(_0x2054f8['push'](_0x142c40),_0x142c40['id']===_0x3ad13c['oldRevisionId'])break;return _0x2054f8;}*['getRevisionsIterator'](_0x3ece0a,{direction:_0x4696bc='earlier',filter:_0x39df70=()=>!0x0}={}){const _0xf5050a='earlier'===_0x4696bc?0x1:-0x1;let _0x146837=this['_revisions']['get'](_0x3ece0a),_0x4e4091=this['getIndex'](_0x146837);for(yield _0x146837;_0x146837;){if(_0x4e4091+=_0xf5050a,_0x146837=this['getRevision'](_0x4e4091),!_0x146837)return;_0x39df70(_0x146837)&&(yield _0x146837);}}}class $ extends _0xb2d8c8{static get['pluginName'](){return'RevisionHistoryUtils';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['_viewClassToTypeChar']=new Map([[_0x598a4b,'c'],[_0x4e70b8,'a'],[_0x2f1121,'e'],[_0x4d9c6a,'r'],[_0x35e088,'u']]);['_typeCharToViewClass']=new Map([['c',_0x598a4b],['a',_0x4e70b8],['e',_0x2f1121],['r',_0x4d9c6a],['u',_0x35e088]]);async['loadRevisionData'](_0x29d992,_0x32dfab){if(_0x29d992['diffData']||!_0x32dfab)return;const _0x3fb069=this['editor']['config']['get']('collaboration.channelId'),_0x41688b=await _0x32dfab['getRevision']({'channelId':_0x3fb069,'revisionId':_0x29d992['id']});_0x29d992['diffData']=_0x41688b['diffData'];}['getRevisionDocumentData'](_0x1e5490){const _0x5a339e={};for(const _0x6cc2e2 in _0x1e5490['diffData']){if(_0x1e5490['diffData'][_0x6cc2e2]['attachChange']&&!_0x1e5490['diffData'][_0x6cc2e2]['attachChange']['isAttached'])continue;const _0x1ed33a=this['_removeRevisionMarkers'](JSON['parse'](_0x1e5490['diffData'][_0x6cc2e2]['insertions'])),_0x23e674=this['editor']['editing']['view']['document'],_0x59d08e=new _0x359ce1(_0x23e674,_0x1ed33a['map'](_0x266d23=>this['_getViewFromDiffObj'](_0x266d23,!0x1)));this['editor']['data']['processor']['useFillerType']('marked'),_0x5a339e[_0x6cc2e2]=this['editor']['data']['processor']['toData'](_0x59d08e),this['editor']['data']['processor']['useFillerType']('default');}return _0x5a339e;}['getRevisionRootsAttributes'](_0x3935fe){const _0x5cbd4c={};for(const _0x4cf27d in _0x3935fe['diffData'])_0x3935fe['diffData'][_0x4cf27d]['attachChange']&&!_0x3935fe['diffData'][_0x4cf27d]['attachChange']['isAttached']||(_0x5cbd4c[_0x4cf27d]=_0x3935fe['diffData'][_0x4cf27d]['attributesAfter']||{});return _0x5cbd4c;}['_getTypeCharForViewElement'](_0x23e889){return this['_viewClassToTypeChar']['get'](_0x23e889['constructor']);}['_getViewFromDiffObj'](_0x36760e,_0x2b409e){const _0x21e937=this['editor']['editing']['view']['document'];if('string'==typeof _0x36760e)return new _0x200728(_0x21e937,_0x36760e);{let _0x191d38,_0x48eff3;_0x48eff3='u'==_0x36760e['type']||'r'==_0x36760e['type']?[]:_0x36760e['children']['map'](_0x28823d=>this['_getViewFromDiffObj'](_0x28823d,_0x2b409e));const _0x4c8a10=this['_typeCharToViewClass']['get'](_0x36760e['type'])||_0x5ff874,_0x4ff097=this['editor']['data']['htmlProcessor']['domConverter'];if(_0x191d38=new _0x4c8a10(_0x21e937,_0x36760e['name'],_0x36760e['attributes'],_0x48eff3),'u'==_0x36760e['type']&&_0x36760e['children'][0x0]){const _0x404f63=_0x36760e['children'][0x0];if(_0x191d38['render']=function(_0x508aa8){const _0x25146f=_0x508aa8['createElement']('div');return _0x25146f['innerHTML']=_0x404f63,_0x25146f['childNodes'][0x0];},_0x2b409e){const _0x330940=new _0x359ce1(_0x21e937);_0x330940['_appendChild'](_0x191d38);const _0x2bfdb7=Array['from'](_0x4ff097['viewChildrenToDom'](_0x330940,{'bind':!0x1})),_0x209002=_0x4ff097['domDocument']['createElement']('div');_0x209002['append'](..._0x2bfdb7),_0x191d38=Array['from'](_0x4ff097['domChildrenToView'](_0x209002))[0x0];}}else{if('r'==_0x36760e['type']&&_0x36760e['children'][0x0]){const _0x51fc80=_0x36760e['children'][0x0];if(_0x191d38['render']=function(_0x4cfcb0){_0x4cfcb0['innerHTML']=_0x51fc80;},_0x2b409e){const _0x58df21=new _0x359ce1(_0x21e937);_0x58df21['_appendChild'](_0x191d38);const _0xb52e2e=Array['from'](_0x4ff097['viewChildrenToDom'](_0x58df21,{'bind':!0x1})),_0x54da20=_0x4ff097['domDocument']['createElement']('div');_0x54da20['append'](..._0xb52e2e);const _0x38d378=Array['from'](_0x4ff097['domChildrenToView'](_0x54da20));_0x38d378['length']>0x1?_0x191d38['_appendChild'](_0x38d378):_0x191d38=_0x38d378[0x0];}}}if(_0x36760e['customProperties']){for(const [_0x41ef8f,_0x3e63a8]of _0x36760e['customProperties'])_0x191d38['_setCustomProperty'](_0x41ef8f,_0x3e63a8);}const _0x13b4e6=void 0x0===_0x36760e['fillerOffset']?null:_0x36760e['fillerOffset'];return null!==_0x13b4e6&&(_0x191d38['getFillerOffset']=()=>_0x13b4e6),_0x191d38;}}['_makeModelFromViewString'](_0x16b5cf){const _0x289538=JSON['parse'](_0x16b5cf),_0x4de3b2=this['editor']['editing']['view']['document'],_0x352b58=new _0x359ce1(_0x4de3b2,_0x289538['map'](_0x48e69d=>this['_getViewFromDiffObj'](_0x48e69d,!0x0)));return this['editor']['data']['toModel'](_0x352b58);}['_removeRevisionMarkers'](_0x37c3e0){return(_0x37c3e0=_0x37c3e0['filter'](_0x5c323c=>!_0x5c323c['name']||'revision-start'!==_0x5c323c['name']&&'revision-end'!==_0x5c323c['name']))['forEach'](_0x51cb12=>{'string'!=typeof _0x51cb12&&(_0x51cb12['children']=this['_removeRevisionMarkers'](_0x51cb12['children']),_0x51cb12['attributes']=_0x51cb12['attributes']['filter'](_0x3fe49e=>!_0x3fe49e[0x0]['startsWith']('data-revision-')));}),_0x37c3e0;}}function R(_0x5eb506,_0x102030,_0x5cc5bb){const t=_0x5eb506['t'];switch(_0x102030){case'Revision\x20history':return t('Revision\x20history');case'Open\x20revision\x20history':return t('Open\x20revision\x20history');case'Restored':return t('Restored');case'Empty\x20document':return t('Empty\x20document');case'Initial\x20revision':return t('Initial\x20revision');case'Suggested\x20by':return t('Suggested\x20by');case'Added\x20by':return t('Added\x20by');case'Removed\x20by':return t('Removed\x20by');case'Show\x20more\x20items':return t('Show\x20more\x20items');case'Compare\x20against\x20selected':return t('Compare\x20against\x20selected');case'Name\x20this\x20revision':return t('Name\x20this\x20revision');case'Restore\x20this\x20revision':return t('Restore\x20this\x20revision');case'Back\x20to\x20editing':return t('Back\x20to\x20editing');case'Loading...':return t('Loading...');case'No\x20changes':return t('No\x20changes');case'NUMBER_OF_CHANGES':return t({'string':'%0\x20change','plural':'%0\x20changes','id':'NUMBER_OF_CHANGES'},_0x5cc5bb);case'X_OF_Y_CHANGES':return t({'string':'%0\x20of\x20%1','id':'X_OF_Y_CHANGES'},_0x5cc5bb);case'Show\x20previous\x20change':return t('Show\x20previous\x20change');case'Show\x20next\x20change':return t('Show\x20next\x20change');case'EDIT_X_OF_Y_REVISIONS':return t({'string':'Edit','id':'EDIT_X_OF_Y_REVISIONS'});case'Total':return t('Total');case'Revision\x20creator':return t('Revision\x20creator');case'Revision\x20author':return t('Revision\x20author');case'Revision\x20name':return t('Revision\x20name');case'Save\x20current\x20revision':return t('Save\x20current\x20revision');case'Accept':return t('Accept');case'Save':return t('Save');case'Cancel':return t('Cancel');case'Name\x20of\x20the\x20revision':return t('Name\x20of\x20the\x20revision');case'optional':return t('optional');case'PENDING_ACTION_REVISION_HISTORY':return t({'string':'Unsaved\x20change\x20in\x20revision\x20history.','id':'PENDING_ACTION_REVISION_HISTORY'});case'The\x20revision\x20name\x20cannot\x20be\x20empty.':return t('The\x20revision\x20name\x20cannot\x20be\x20empty.');case'Enter\x20the\x20revision\x20name':return t('Enter\x20the\x20revision\x20name');default:return'';}}class h extends _0xb2d8c8{['licenseKey'];['_licenseKeyCheckInterval'];['currentRevision']=null;['repository'];['adapter']=null;['_revisionDataBuilder'];['_source'];['_initialRevisionId'];['_bufferedUpdates'];['_utils'];['_pendingAction'];['_continueCurrentRevision'];['_startingVersion'];['_loadedStateData'];static get['pluginName'](){return'RevisionTracker';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[_0x3db46c,S,$,_0x5e678a];}constructor(_0x19ac2c){super(_0x19ac2c),this['repository']=this['editor']['plugins']['get']('RevisionsRepository'),this['_utils']=this['editor']['plugins']['get']('RevisionHistoryUtils'),this['_revisionDataBuilder']=new E(this['editor']),this['_initialRevisionId']=this['editor']['config']['get']('collaboration.channelId')||'initial',this['_bufferedUpdates']=new Map(),this['_loadedStateData']=null;const _0x148b61=_0x189557();this['_source']={'history':this['editor']['model']['document']['history'],'getLatestVersion':()=>Promise['resolve'](this['editor']['model']['document']['version']),'getCurrentRevisionId':()=>_0x148b61},this['set']('isReady',!0x1),this['set']('isEnabled',!0x0),this['set']('_isPendingUpdate',!0x1),this['editor']['config']['define']('revisionHistory.resumeUnsavedRevision',!0x0),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'});}['init'](){this['_setConversion'](),this['editor']['data']['on']('ready',()=>{const _0x3bdd69=this['repository']['getRevision'](0x0),_0x419ff7=_0x3bdd69&&null===_0x3bdd69['creator']?_0x3bdd69:null;if(this['_continueCurrentRevision']=!!_0x419ff7&&this['editor']['config']['get']('revisionHistory.resumeUnsavedRevision'),this['editor']['plugins']['has']('RealTimeCollaborationClient')){const _0xad3f37=this['_source']['getCurrentRevisionId'](),_0x4c56cb=this['repository']['getRevision'](_0xad3f37);if(_0x4c56cb)this['_startingVersion']=_0x4c56cb['fromVersion'],this['_continueCurrentRevision']=!0x1;else{const _0x434b39=this['_source']['history']['_operations']['find'](_0x19d8d9=>!_0x19d8d9['_isInit']),_0xedb424=_0x434b39?_0x434b39['baseVersion']:this['_source']['history']['version'];_0x3bdd69?(_0x3bdd69['toVersion']<_0xedb424&&_0x3bdd69['_update']({'toVersion':_0xedb424}),this['_continueCurrentRevision']?(this['_source']['getCurrentRevisionId']=()=>_0x419ff7['id'],this['_startingVersion']=_0x419ff7['fromVersion']):(this['_startingVersion']=_0x3bdd69['toVersion'],this['_continueCurrentRevision']=!0x1)):(this['_startingVersion']=_0xedb424,this['_continueCurrentRevision']=!0x1);}}else _0x419ff7&&(this['editor']['model']['document']['history']['version']=Math['max'](_0x419ff7['toVersion'],this['editor']['model']['document']['history']['version']),_0x419ff7['fromVersion']===_0x419ff7['toVersion']?(0x0!==_0x419ff7['fromVersion']&&(this['_source']['getCurrentRevisionId']=()=>_0x419ff7['id']),this['_continueCurrentRevision']=!0x1):this['_continueCurrentRevision']&&(this['_source']['getCurrentRevisionId']=()=>_0x419ff7['id'],this['_startingVersion']=_0x419ff7['fromVersion'])),this['_continueCurrentRevision']||(this['_startingVersion']=this['editor']['model']['document']['version']);this['_revisionDataBuilder']['init'](this['_source']['history']),this['_createInitialRevision'](this['_startingVersion']),this['_createCurrentRevision'](this['_startingVersion']),this['adapter']&&this['sendBufferedUpdates']();}),this['bind']('isReady')['to'](this,'_isPendingUpdate',_0x4f3822=>!_0x4f3822),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x3e91ab=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x39dae5;for(const _0x50ba55 in _0x3e91ab){const _0x58fcab=_0x50ba55,_0x274c7a=_0x3e91ab[_0x58fcab];if('revisionHistoryLicenseKeyValid'==_0x274c7a||'revisionHistoryLicenseKeyInvalid'==_0x274c7a||'revisionHistoryLicenseKeyExpired'==_0x274c7a||'revisionHistoryLicenseKeyDomainLimit'==_0x274c7a||'revisionHistoryLicenseKeyNotAllowed'==_0x274c7a||'revisionHistoryLicenseKeyEvaluationLimit'==_0x274c7a||'revisionHistoryLicenseKeyTrialLimit'==_0x274c7a||'revisionHistoryLicenseKeyUsageLimit'==_0x274c7a){delete _0x3e91ab[_0x58fcab],_0x39dae5=_0x274c7a,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'revisionHistoryLicenseKeyInvalid'==_0x39dae5&&_0x3e91ab['_showLicenseError']('invalid'),'revisionHistoryLicenseKeyExpired'==_0x39dae5&&_0x3e91ab['_showLicenseError']('expired'),'revisionHistoryLicenseKeyDomainLimit'==_0x39dae5&&_0x3e91ab['_showLicenseError']('domainLimit'),'revisionHistoryLicenseKeyNotAllowed'==_0x39dae5&&_0x3e91ab['_showLicenseError']('featureNotAllowed','RevisionHistory'),'revisionHistoryLicenseKeyEvaluationLimit'==_0x39dae5&&_0x3e91ab['_showLicenseError']('evaluationLimit'),'revisionHistoryLicenseKeyTrialLimit'==_0x39dae5&&_0x3e91ab['_showLicenseError']('trialLimit'),'revisionHistoryLicenseKeyUsageLimit'==_0x39dae5&&_0x3e91ab['_showLicenseError']('usageLimit');},0x3e8);}async['afterInit'](){if(this['repository']['length']>0x0){const _0x58b81d=this['repository']['getRevision'](0x0),_0x526b3a=await this['getRevisionDocumentData'](_0x58b81d),_0x1dc829=await this['getRevisionRootsAttributes'](_0x58b81d);this['_replaceEditorDataWithRevisionData'](_0x526b3a,_0x1dc829);}}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['setSource'](_0x190947){this['_source']=_0x190947;}async['update'](){const _0x477793=await this['_source']['getLatestVersion']();if(_0x477793>this['currentRevision']['toVersion']){await this['_loadState']();const _0x5a0d38=this['buildRevisionData']({'revision':this['currentRevision'],'to':_0x477793});_0x5a0d38['authors']=_0x5a0d38['authorsIds']['map'](_0x1cd77a=>this['editor']['plugins']['get']('Users')['getUser'](_0x1cd77a)),this['currentRevision']['_update'](_0x5a0d38);}}async['saveRevision'](_0xc41ab1={},_0x363bb6=null){const _0x258a6e=[];await this['_loadState'](),this['_continueCurrentRevision']=!0x1,_0x363bb6>this['currentRevision']['toVersion']&&(_0x363bb6=null),null===_0x363bb6&&(_0x363bb6=await this['_source']['getLatestVersion']());const _0x4f0409=this['_getFromVersion'](_0x363bb6),_0x7ae4b7=this['buildRevisionData']({'from':_0x4f0409,'to':_0x363bb6});if(this['currentRevision']['toVersion']<_0x363bb6){const _0xd84102=this['buildRevisionData']({'revision':this['currentRevision'],'from':_0x363bb6,'to':_0x363bb6});_0xd84102['authors']=[],_0xd84102['authorsIds']=[],_0xd84102['id']=this['currentRevision']['id'],this['currentRevision']['_update'](_0xd84102,!0x0),delete _0xd84102['authors'],_0x258a6e['push'](_0xd84102);}_0xc41ab1['creatorId']=this['editor']['plugins']['get']('Users')['me']['id'],_0xc41ab1['name']=_0xc41ab1['name']||null,_0xc41ab1['id']=_0xc41ab1['id']||_0x189557(),_0xc41ab1={..._0xc41ab1,..._0x7ae4b7};const _0x134f68=this['addRevisionData'](_0xc41ab1);_0x258a6e['push'](_0xc41ab1);const _0x537f5c=this['repository']['getIndex'](_0x134f68);if(0x0!==_0x537f5c){const _0xab677d=this['repository']['getRevision'](_0x537f5c-0x1);if(_0xab677d['fromVersion']!==_0x363bb6){const _0x195da7=this['_revisionDataBuilder']['getData'](_0x363bb6,_0xab677d['toVersion']),_0x185785={'id':_0xab677d['id'],'diffData':_0x195da7['diffData'],'authorsIds':_0x195da7['authorsIds'],'authors':_0x195da7['authorsIds']['map'](_0x170945=>this['editor']['plugins']['get']('Users')['getUser'](_0x170945)),'fromVersion':_0x363bb6};_0xab677d===this['currentRevision']&&(_0x185785['createdAt']=new Date(_0xc41ab1['createdAt']['getTime']()+0xa)),_0xab677d['_update'](_0x185785,!0x0),delete _0x185785['authors'],_0x258a6e['push'](_0x185785);}}if(this['adapter']){for(const _0x565ee8 of _0x258a6e)this['_bufferUpdate'](_0x565ee8['id'],_0x565ee8,!0x0);this['sendBufferedUpdates']();}return _0x134f68;}['addRevisionData'](_0x50dcfb){const _0x14bc01=this['repository']['createRevision'](_0x50dcfb);return this['adapter']&&_0x14bc01['on']('_update',(_0x559d72,_0x3b62ba,_0xdf54ad)=>{_0xdf54ad||(this['_bufferUpdate'](_0x3b62ba['id'],_0x3b62ba,!0x0),this['sendBufferedUpdates']());}),this['repository']['addRevision'](_0x14bc01,this['_findInsertionIndex'](_0x14bc01)),_0x14bc01;}async['getRevisionDocumentData'](_0xd7578f){return await this['_utils']['loadRevisionData'](_0xd7578f,this['adapter']),this['_utils']['getRevisionDocumentData'](_0xd7578f);}async['getRevisionRootsAttributes'](_0x3df232){return await this['_utils']['loadRevisionData'](_0x3df232,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x3df232);}['sendBufferedUpdates'](){if(0x0===this['_bufferedUpdates']['size'])return;if(this['_isPendingUpdate'])return;let _0x15b25f=Array['from'](this['_bufferedUpdates']['values']());this['_bufferedUpdates']['clear']();for(let _0x506957=0x0;_0x506957<_0x15b25f['length'];_0x506957++){const _0x12287f=_0x15b25f[_0x506957];let _0x1919b8=!0x1;for(const _0x2eb179 of Object['keys'](_0x12287f))void 0x0===_0x12287f[_0x2eb179]?delete _0x12287f[_0x2eb179]:'id'!==_0x2eb179&&(_0x1919b8=!0x0);_0x1919b8||(_0x15b25f[_0x506957]=null);}if(_0x15b25f=_0x15b25f['filter'](_0x320c44=>null!==_0x320c44),!_0x15b25f['length'])return;for(let _0xa67f1b=0x0;_0xa67f1b<_0x15b25f['length'];_0xa67f1b++){const _0xb51a1c=_0x15b25f[_0xa67f1b];void 0x0!==_0xb51a1c['fromVersion']&&void 0x0===_0xb51a1c['toVersion']&&(_0xb51a1c['toVersion']=this['repository']['getRevision'](_0xb51a1c['id'])['toVersion']),void 0x0!==_0xb51a1c['toVersion']&&void 0x0===_0xb51a1c['fromVersion']&&(_0xb51a1c['fromVersion']=this['repository']['getRevision'](_0xb51a1c['id'])['fromVersion']);}const _0x574c7b=this['editor']['config']['get']('collaboration.channelId');this['_isPendingUpdate']=!0x0,this['_addPendingAction'](),this['adapter']['updateRevisions'](_0x15b25f,_0x574c7b)['finally'](()=>{this['_isPendingUpdate']=!0x1;})['then'](_0x594632=>{if(_0x594632){for(const _0x3da5f6 of _0x594632)this['setRevisionData']({'id':_0x3da5f6['id'],'createdAt':_0x3da5f6['createdAt']});}this['_removePendingAction'](),this['sendBufferedUpdates']();});}['buildRevisionData']({revision:_0x49270e=null,from:_0x4eeb61=null,to:_0x8d02a=null}){_0x4eeb61=null!==_0x4eeb61?_0x4eeb61:_0x49270e['fromVersion'],_0x8d02a=null!==_0x8d02a?_0x8d02a:_0x49270e['toVersion'];const _0x5c16f7=this['_revisionDataBuilder']['getData'](_0x4eeb61,_0x8d02a),_0x581e36={'diffData':_0x5c16f7['diffData'],'authorsIds':_0x5c16f7['authorsIds'],'fromVersion':_0x4eeb61,'toVersion':_0x8d02a};if(!_0x49270e||_0x8d02a!==_0x49270e['toVersion']){const _0x383f00=_0x8d02a-0x1,_0x6a8799=this['_source']['history']['getOperation'](_0x383f00);_0x581e36['createdAt']=_0x6a8799&&_0x6a8799['createdAt']||new Date();}if(this['_loadedStateData']&&_0x4eeb61===this['_loadedStateData']['fromVersion']){for(const _0x1fdd20 of this['_loadedStateData']['authors'])_0x581e36['authorsIds']['includes'](_0x1fdd20['id'])||_0x581e36['authorsIds']['push'](_0x1fdd20['id']);}return _0x581e36;}['_bufferUpdate'](_0x3f54c7,_0x334725,_0x6f524b){if(this['_bufferedUpdates']['has'](_0x3f54c7)){const _0x351cd1=this['_bufferedUpdates']['get'](_0x3f54c7);_0x334725=_0x6f524b?{..._0x351cd1,..._0x334725}:{..._0x334725,..._0x351cd1};}this['_bufferedUpdates']['set'](_0x3f54c7,_0x334725);}['setRevisionData'](_0x323552){const _0x4a84e8=this['repository']['getRevision'](_0x323552['id']);if(_0x323552['createdAt']&&(_0x323552['createdAt']=new Date(_0x323552['createdAt'])),_0x323552['authorsIds']){const _0x2452a8=this['editor']['plugins']['get']('Users');_0x323552['authors']=_0x323552['authorsIds']['map'](_0x44e9e7=>_0x2452a8['getUser'](_0x44e9e7));}_0x4a84e8['_update'](_0x323552,!0x0);}['_createInitialRevision'](_0x2ad848){const _0x258bcd=this['repository']['getRevision'](this['repository']['length']-0x1);if(_0x258bcd)this['_initialRevisionId']=_0x258bcd['id'];else{const _0x5e4ee7=!this['editor']['model']['document']['roots']['find'](_0x4af4b2=>this['editor']['model']['hasContent'](_0x4af4b2)),_0x23535b=this['editor']['plugins']['get']('Users')['me']['id'],_0x4b9d9f=R(this['editor']['locale'],_0x5e4ee7?'Empty\x20document':'Initial\x20revision');this['_makeRevision']({'from':_0x2ad848,'to':_0x2ad848,'id':this['_initialRevisionId'],'name':_0x4b9d9f,'creatorId':_0x23535b});}}['_createCurrentRevision'](_0x266f8f){const _0x13fb53=this['_source']['getCurrentRevisionId']();this['currentRevision']=this['repository']['getRevision'](_0x13fb53),this['currentRevision']||(this['currentRevision']=this['_makeRevision']({'from':_0x266f8f,'to':_0x266f8f,'id':_0x13fb53,'name':'','creatorId':null}));}async['_loadState'](){this['_continueCurrentRevision']&&!this['_loadedStateData']&&(await this['_utils']['loadRevisionData'](this['currentRevision'],this['adapter']),this['_revisionDataBuilder']['loadState'](this['currentRevision']),this['_loadedStateData']={'fromVersion':this['currentRevision']['fromVersion'],'authors':this['currentRevision']['authors']['slice']()});}['_replaceEditorDataWithRevisionData'](_0x79300,_0xf93cb1){let _0x46ecbb=this['editor']['config']['get']('initialData'),_0x249d7f=this['editor']['config']['get']('rootsAttributes');if(void 0x0===_0x46ecbb){_0x46ecbb={};for(const _0x235f04 of this['editor']['model']['document']['getRootNames']())_0x46ecbb[_0x235f04]='';}if('string'==typeof _0x46ecbb&&(_0x46ecbb={'main':_0x46ecbb}),void 0x0===_0x249d7f){_0x249d7f={};for(const _0x3473f2 of this['editor']['model']['document']['getRootNames']())_0x249d7f[_0x3473f2]={};}let _0x316dee=!0x1;const _0x5a557d=Object['keys'](_0x46ecbb),_0x8bbc3e=Object['keys'](_0x79300);for(const _0x403ead of _0x5a557d){if(_0x46ecbb[_0x403ead]!==_0x79300[_0x403ead]&&''!==_0x46ecbb[_0x403ead]['trim']()){_0x316dee=!0x0;break;}if(!_0x2ea464(_0x249d7f[_0x403ead],_0xf93cb1[_0x403ead])&&Object['keys'](_0x249d7f[_0x403ead])['length']>0x0){_0x316dee=!0x0;break;}}_0x316dee||(_0x316dee=_0x8bbc3e['some'](_0x4b7d1a=>!this['editor']['model']['document']['getRoot'](_0x4b7d1a))),_0x316dee&&_0x43e3aa('editor-initial-data-replaced-with-revision-data',{'editorData':_0x46ecbb,'editorRootsAttributes':_0x249d7f,'revisionData':_0x79300,'revisionRootsAttributes':_0xf93cb1}),this['editor']['config']['set']('initialData',_0x79300),this['editor']['config']['set']('rootsAttributes',_0xf93cb1);}['_addPendingAction'](){if(!this['_pendingAction']){const _0x3dfdab=this['editor']['plugins']['get']('PendingActions');this['_pendingAction']=_0x3dfdab['add'](R(this['editor']['locale'],'PENDING_ACTION_REVISION_HISTORY'));}}['_removePendingAction'](){this['_pendingAction']&&(this['editor']['plugins']['get']('PendingActions')['remove'](this['_pendingAction']),this['_pendingAction']=null);}['_findInsertionIndex'](_0x2ae3b0){const _0x3f22e9=this['repository']['getRevisions']();_0x3f22e9['reverse']();let _0x56fe34=0x0;for(;_0x56fe34<_0x3f22e9['length'];){const _0x338b99=_0x3f22e9[_0x56fe34];if(_0x338b99===this['currentRevision']){_0x56fe34++;continue;}if(_0x338b99['id']===this['_initialRevisionId'])break;const _0x562583=_0x2ae3b0['toVersion']-_0x338b99['toVersion']||_0x2ae3b0['fromVersion']-_0x338b99['fromVersion'];if(_0x562583>0x0)break;if(_0x562583<0x0)_0x56fe34++;else{if(!_0x2ae3b0['creator']&&_0x338b99['creator'])break;if(_0x338b99['creator']||!_0x2ae3b0['creator']){if(_0x2ae3b0['createdAt']>_0x338b99['createdAt'])break;_0x56fe34++;}else _0x56fe34++;}}return _0x56fe34;}['_getFromVersion'](_0xb8161a){const _0x3cfdbe=this['repository']['getRevisions']();_0x3cfdbe['reverse'](),_0x3cfdbe['shift']();const _0x184f46=_0x3cfdbe['find'](_0x18388f=>_0x18388f['toVersion']<=_0xb8161a)['toVersion'];return _0x184f46<this['_startingVersion']?this['_startingVersion']:_0x184f46;}['_makeRevision']({name:_0x140f09,from:_0x47fd84,to:_0x3d1397,creatorId:_0x599ae7,id:_0x4c76eb}){const _0x164fe9=this['buildRevisionData']({'from':_0x47fd84,'to':_0x3d1397});_0x164fe9['name']=_0x140f09,_0x164fe9['creatorId']=_0x599ae7,_0x164fe9['id']=_0x4c76eb;const _0x104cf4=this['addRevisionData'](_0x164fe9);return this['adapter']&&this['_bufferUpdate'](_0x164fe9['id'],_0x164fe9,!0x0),_0x104cf4;}['_setConversion'](){this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'});}}class E{['editor'];['source'];['_savedMetaData'];['_lastFrom'];['_lastTo'];['_markers'];['_diffRoots'];['_diffRootsAttributes'];['_baseRoots'];['_baseRootsAttributes'];['_idsRoots'];['_baseIdsRoots'];['_touched'];['_touchedMarkers'];['_touchedRoots'];['_revisionId'];['_startingRevisionId'];constructor(_0x1463e5){this['editor']=_0x1463e5,this['_savedMetaData']=new Map(),this['_lastFrom']=-0x1,this['_lastTo']=-0x1,this['_markers']=new Map(),this['_diffRoots']=new Map(),this['_diffRootsAttributes']=new Map(),this['_baseRoots']=new Map(),this['_baseRootsAttributes']=new Map(),this['_idsRoots']=new Map(),this['_baseIdsRoots']=new Map(),this['_touched']=new Map(),this['_touchedMarkers']=new Map(),this['_touchedRoots']=new Map(),this['_revisionId']=0x1;}['init'](_0x5bb749){this['source']=_0x5bb749;const _0x5d94dc=new Map(),_0x4ecccd=new Map(),_0x150f21=this['editor']['model']['document']['roots']['map'](_0x2f42df=>_0x2f42df['rootName']);for(const _0x4ad82e of _0x150f21){const _0x5b337c=this['editor']['model']['document']['getRoot'](_0x4ad82e),_0x3ad238=x(_0x5b337c);_0x5d94dc['set'](_0x4ad82e,_0x3ad238),_0x4ecccd['set'](_0x4ad82e,Object['fromEntries'](_0x5b337c['getAttributes']()));}const _0x5a6b2a=Array['from'](this['editor']['model']['markers'])['map'](_0x9af257=>[_0x9af257['name'],_0x9af257['getRange']()]),_0x485c70=this['source']['version'];this['_saveMetaData'](_0x485c70,_0x5d94dc,_0x5a6b2a,_0x4ecccd),this['_startingRevisionId']=this['_revisionId'];const _0x51b5c0=new Map(),_0x4feb37=new Map();for(const _0x225763 of _0x150f21){const _0x31a7f2=N(_0x225763);_0x51b5c0['set'](_0x225763,_0x31a7f2),_0x4feb37['set'](_0x225763,{});}this['_saveMetaData'](Number['NEGATIVE_INFINITY'],_0x51b5c0,[],_0x4feb37);}['getData'](_0x771818,_0x1c31a7){if(this['_lastFrom']===_0x771818&&this['_lastTo']<=_0x1c31a7)this['_savedMetaData']['size']>0x1&&this['_removeMetaData'](this['_lastTo']),this['_applyOperations'](this['_lastTo'],_0x1c31a7,!0x0);else{if(!this['_savedMetaData']['has'](_0x771818)){const _0x44ead7=this['_getPreviousFrom'](_0x771818);this['_calculateMetaData'](_0x44ead7,_0x771818,!0x1);}this['_calculateMetaData'](_0x771818,_0x1c31a7,!0x0);}return this['_lastFrom']=_0x771818,this['_lastTo']=_0x1c31a7,this['_getState']();}['loadState'](_0x39529b){const _0x5894d9=this['editor']['plugins']['get']('RevisionHistoryUtils');this['_reset'](),this['_lastFrom']=_0x39529b['fromVersion'],this['_lastTo']=_0x39529b['toVersion'];for(const _0x2ae60e in _0x39529b['diffData']){const _0x32fb9c=_0x39529b['diffData'][_0x2ae60e]['attachChange'],_0x4b6803=_0x240ca5(_0x39529b['diffData'][_0x2ae60e]['attributesBefore'])||{},_0x2eae9b=_0x5894d9['_makeModelFromViewString'](_0x39529b['diffData'][_0x2ae60e]['deletions']);_0x2eae9b['rootName']=_0x2ae60e,_0x2eae9b['_isAttached']=!_0x32fb9c||!_0x32fb9c['isAttached'],_0x2eae9b['isAttached']=()=>_0x2eae9b['_isAttached'],this['_baseRoots']['set'](_0x2ae60e,_0x2eae9b),this['_baseRootsAttributes']['set'](_0x2ae60e,_0x4b6803),_0x32fb9c&&this['_touchedRoots']['set'](_0x2ae60e,_0x32fb9c);const _0x452ebd=this['_makeIdsRoot'](_0x2eae9b);this['_baseIdsRoots']['set'](_0x2ae60e,_0x452ebd);for(const [_0x24f54a,_0x5eb7ff]of _0x2eae9b['markers']){if(!_0x24f54a['startsWith']('revision:'))continue;const _0x595a12=_0x24f54a['split'](':')[0x2];for(const _0x1f5790 of _0x5eb7ff['getWalker']({'singleCharacters':!0x0})){const _0x4f9b59=this['_getVidAttributeName'](_0x1f5790),_0x1a8461='elementEnd'==_0x1f5790['type']?_0x1f5790['previousPosition']['path']['slice'](0x0,-0x1):_0x1f5790['previousPosition']['path'],_0x5b52fa=_0x452ebd['getNodeByPath'](_0x1a8461)['getAttribute'](_0x4f9b59);this['_touched']['set'](_0x5b52fa,{'userId':_0x595a12});}}}this['_startingRevisionId']=this['_revisionId'];const _0xaee37a=[...Array(this['_revisionId'])['keys']()]['slice'](0x1)['filter'](_0x554b36=>!this['_touched']['has'](_0x554b36));let _0x3e5e16=0x0;const _0x2de089=new Map();for(const _0x897a36 in _0x39529b['diffData']){const _0x180dcc=_0x39529b['diffData'][_0x897a36]['attachChange'],_0x395c3b=_0x240ca5(_0x39529b['diffData'][_0x897a36]['attributesAfter'])||{},_0x427c25=_0x5894d9['_makeModelFromViewString'](_0x39529b['diffData'][_0x897a36]['insertions']);_0x427c25['rootName']=_0x897a36,_0x427c25['_isAttached']=!_0x180dcc||_0x180dcc['isAttached'],_0x427c25['isAttached']=()=>_0x427c25['_isAttached'],this['_diffRoots']['set'](_0x897a36,_0x427c25),this['_diffRootsAttributes']['set'](_0x897a36,_0x395c3b);const _0x1fe5cf=this['_makeIdsRoot'](_0x427c25,Number['NEGATIVE_INFINITY']);this['_idsRoots']['set'](_0x897a36,_0x1fe5cf),_0x2de089['set'](_0x897a36,_0x427c25['isAttached']()?_0x395c3b:{});for(const [_0x31b7ea,_0xbdb094]of _0x427c25['markers']){if(!_0x31b7ea['startsWith']('revision:'))continue;const _0x22a2e5=_0x31b7ea['split'](':')[0x2];for(const _0x1ac844 of _0xbdb094['getWalker']({'singleCharacters':!0x0})){const _0x134cfb=this['_getVidAttributeName'](_0x1ac844),_0x213128=this['_revisionId']++,_0xa3e41d='elementEnd'==_0x1ac844['type']?_0x1ac844['previousPosition']['path']['slice'](0x0,-0x1):_0x1ac844['previousPosition']['path'];_0x1fe5cf['getNodeByPath'](_0xa3e41d)['_setAttribute'](_0x134cfb,_0x213128),this['_touched']['set'](_0x213128,{'userId':_0x22a2e5});}}for(const _0x2b73fd of this['editor']['model']['createRangeIn'](_0x427c25)['getWalker']({'singleCharacters':!0x0})){const _0x24c715=this['_getVidAttributeName'](_0x2b73fd),_0x4dcb05='elementEnd'==_0x2b73fd['type']?_0x2b73fd['previousPosition']['path']['slice'](0x0,-0x1):_0x2b73fd['previousPosition']['path'],_0x36d38c=_0x1fe5cf['getNodeByPath'](_0x4dcb05);_0x36d38c['getAttribute'](_0x24c715)>0x0||_0x36d38c['_setAttribute'](_0x24c715,_0xaee37a[_0x3e5e16++]);}for(const [_0x1c2119,_0x1a1c74]of _0x427c25['markers'])_0x1c2119['startsWith']('revision:')||this['_markers']['set'](_0x1c2119,_0x1a1c74);}const _0x5bc978=N('$graveyard');this['_baseRoots']['set']('$graveyard',_0x5bc978),this['_baseIdsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x5bc978,0x1));const _0xe6bc74=N('$graveyard');this['_diffRoots']['set']('$graveyard',_0xe6bc74),this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0xe6bc74,0x1));const _0x5d3e71=Array['from'](this['_diffRoots'])['map'](([_0x19df89,_0x15fed3])=>[_0x19df89,x(_0x15fed3)]);this['_saveMetaData'](this['_lastTo'],_0x5d3e71,this['_markers'],_0x2de089);}['reInit'](){this['_reset'](),this['_lastFrom']=-0x1,this['_lastTo']=-0x1,this['_savedMetaData']['clear'](),this['init'](this['source']);}['_saveMetaData'](_0x16bd3f,_0x27e88e,_0x15343e,_0xa46ff8){const _0x250dff=new Map(_0x27e88e),_0x789e7e=new Map(_0x240ca5(_0xa46ff8)),_0x499805=new Map();for(const [_0x3bdf98,_0x3ecbba]of _0x15343e)_0x499805['set'](_0x3bdf98,{'start':_0x3ecbba['start']['clone'](),'end':_0x3ecbba['end']['clone'](),'rootName':_0x3ecbba['root']['rootName']});this['_savedMetaData']['set'](_0x16bd3f,{'roots':_0x250dff,'markers':_0x499805,'rootsAttributes':_0x789e7e});}['_removeMetaData'](_0x3dbd3b){this['_savedMetaData']['delete'](_0x3dbd3b);}['_reset'](){this['_touched']['clear'](),this['_touchedMarkers']['clear'](),this['_touchedRoots']['clear'](),this['_diffRoots']['clear'](),this['_diffRootsAttributes']['clear'](),this['_baseRoots']['clear'](),this['_baseRootsAttributes']['clear'](),this['_idsRoots']['clear'](),this['_baseIdsRoots']['clear'](),this['_markers']['clear'](),this['_revisionId']=0x1,this['_startingRevisionId']=this['_revisionId'];}['_makeIdsRoot'](_0x31cc68,_0x5cbfa1=null){let _0x2c7c8b=null;_0x31cc68['is']('documentFragment')||(_0x2c7c8b=new _0x429deb(_0x31cc68['name'],{'vid_start':null===_0x5cbfa1?this['_revisionId']++:_0x5cbfa1++}));const _0x323f04=[];for(const _0x4431c0 of _0x31cc68['getChildren']())if(_0x4431c0['is']('element')){_0x323f04['push'](this['_makeIdsRoot'](_0x4431c0,_0x5cbfa1));const _0xae4578=_0x323f04[_0x323f04['length']-0x1];null!==_0x5cbfa1&&(_0x5cbfa1=_0xae4578['is']('element','$text')?_0xae4578['getAttribute']('vid')+0x1:_0xae4578['getAttribute']('vid_end')+0x1);}else{for(let _0x4badae=0x0;_0x4badae<_0x4431c0['offsetSize'];_0x4badae++)_0x323f04['push'](new _0x429deb('$text',{'vid':null===_0x5cbfa1?this['_revisionId']++:_0x5cbfa1++}));}if(_0x31cc68['is']('documentFragment')){const _0x5c572f=N(_0x31cc68['rootName']);return _0x5c572f['_insertChild'](0x0,_0x323f04),_0x5c572f;}return _0x2c7c8b['_setAttribute']('vid_end',null===_0x5cbfa1?this['_revisionId']++:_0x5cbfa1++),_0x2c7c8b['_insertChild'](0x0,_0x323f04),_0x2c7c8b;}['_calculateMetaData'](_0x4014b7,_0x4ceb16,_0x439bf3){this['_reset']();const {roots:_0x5a2b12,markers:_0x911f39,rootsAttributes:_0x219c0f}=this['_savedMetaData']['get'](_0x4014b7);this['_baseRoots']=new Map(_0x5a2b12),this['_baseRootsAttributes']=new Map(_0x240ca5(_0x219c0f));for(const [_0x42d25f,_0x799095]of this['_baseRoots'])if('$graveyard'!==_0x42d25f&&(this['_diffRoots']['set'](_0x42d25f,x(_0x799095)),this['_diffRootsAttributes']=new Map(_0x240ca5(_0x219c0f)),_0x439bf3)){const _0x553541=this['_revisionId'];this['_idsRoots']['set'](_0x42d25f,this['_makeIdsRoot'](_0x799095)),this['_baseIdsRoots']['set'](_0x42d25f,this['_makeIdsRoot'](_0x799095,_0x553541));}this['_startingRevisionId']=this['_revisionId'],this['_diffRoots']['set']('$graveyard',x(this['_baseRoots']['get']('$graveyard'))),_0x439bf3&&this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](this['_baseRoots']['get']('$graveyard')));for(const [_0x27867a,_0x796357]of _0x911f39){const _0x45338f=this['_baseRoots']['get'](_0x796357['rootName']),_0x5c5159=this['_diffRoots']['get'](_0x796357['rootName']),_0x2528c4=new _0x5d129e(this['_fixPosition'](_0x796357['start'],_0x45338f),this['_fixPosition'](_0x796357['end'],_0x45338f)),_0x420d39=this['_fixRange'](_0x2528c4,_0x5c5159);_0x45338f['markers']['set'](_0x27867a,_0x2528c4),this['_markers']['set'](_0x27867a,_0x420d39);}this['_applyOperations'](_0x4014b7,_0x4ceb16,_0x439bf3);}['_applyOperations'](_0x212971,_0x65ecc6,_0x1d1ade){for(const _0x3f5593 of this['source']['getOperations'](_0x212971,_0x65ecc6))this['_handleOperation'](_0x3f5593,_0x1d1ade);for(const _0x46a526 of this['_diffRoots']['values']())_0x46a526['markers']['clear']();for(const [_0x3d56a5,_0x5f16f1]of this['_markers']){this['_diffRoots']['get'](_0x5f16f1['root']['rootName'])['markers']['set'](_0x3d56a5,_0x5f16f1['clone']());}const _0x13781a=new Map(),_0x183eef=new Map();for(const [_0xc868ef,_0x4af6d2]of this['_diffRoots'])_0x13781a['set'](_0xc868ef,x(_0x4af6d2)),_0x183eef['set'](_0xc868ef,this['_diffRootsAttributes']['get'](_0xc868ef));this['_saveMetaData'](_0x65ecc6,_0x13781a,this['_markers'],_0x183eef);}['_getPreviousFrom'](_0x226b70){const _0x3eb6eb=Array['from'](this['_savedMetaData']['keys']());_0x3eb6eb['sort']((_0x3907b5,_0x449b35)=>_0x3907b5-_0x449b35),_0x3eb6eb['reverse']();for(const _0x565c04 of _0x3eb6eb)if(_0x565c04<_0x226b70)return _0x565c04;return Number['NEGATIVE_INFINITY'];}['_copyMarkers'](_0x1fde7d,_0x25c720){const _0x463ba0=Array['from'](_0x25c720['markers'])['map'](([_0x10adf2,_0x45e6a3])=>[_0x10adf2,this['_fixRange'](_0x45e6a3,_0x1fde7d)]);_0x1fde7d['markers']=new Map(_0x463ba0);}['_transformMarkers'](_0xc963eb){for(const _0x47f794 of this['_markers']['values']()){const _0xe75640=_0x47f794['getTransformedByOperation'](_0xc963eb),_0x78eed6=_0x5d129e['_createFromRanges'](_0xe75640);_0x47f794['start']=_0x78eed6['start'],_0x47f794['end']=_0x78eed6['end'];}}['_handleOperation'](_0x4a1b27,_0x159042){if('addRoot'!=_0x4a1b27['type']&&'detachRoot'!=_0x4a1b27['type']){if('insert'==_0x4a1b27['type']){const _0x517bd6=_0x4a1b27['position']['root']['rootName'];this['_diffRoots']['has'](_0x517bd6)||(this['_diffRoots']['set'](_0x517bd6,N(_0x517bd6,!0x0)),this['_diffRootsAttributes']['set'](_0x517bd6,{}),_0x159042&&this['_idsRoots']['set'](_0x517bd6,N(_0x517bd6,!0x0)));}else{if('addRootAttribute'==_0x4a1b27['type']||'removeRootAttribute'==_0x4a1b27['type']||'changeRootAttribute'==_0x4a1b27['type'])return void this['_handleRootAttributeOperation'](_0x4a1b27);'marker'==_0x4a1b27['type']&&this['_handleMarkerOperation'](_0x4a1b27);}if('marker'!==_0x4a1b27['type']){const _0x3f6e59=this['_cloneOperation'](_0x4a1b27,this['_diffRoots']);_0x3f6e59['_execute'](),this['_transformMarkers'](_0x3f6e59);}if(_0x159042)switch(_0x4a1b27['type']){case'insert':this['_handleInsertOperation'](_0x4a1b27);break;case'move':case'remove':case'reinsert':this['_handleMoveOperation'](_0x4a1b27);break;case'merge':this['_handleMergeOperation'](_0x4a1b27);break;case'split':this['_handleSplitOperation'](_0x4a1b27);}}else this['_handleRootOperation'](_0x4a1b27,_0x159042);}['_cloneOperation'](_0x3d1985,_0x59ea2a){const _0x3374fe=_0x3d1985['clone']();return _0x3374fe['_authorId']=_0x3d1985['_authorId'],this['_fixOperation'](_0x3374fe,_0x59ea2a),_0x3374fe;}['_getBaseVids'](_0x9f261f){return _0x9f261f['map'](_0x1421c6=>{const _0xc70dcd=this['_getVidAttributeName'](_0x1421c6);return Number(_0x1421c6['item']['getAttribute'](_0xc70dcd));});}['_generateTape'](_0x8a4d8f,_0x1fae98){if(_0x8a4d8f['is']('element','$text'))_0x1fae98['push']({'item':_0x8a4d8f,'type':'text'});else{_0x8a4d8f['is']('element')&&_0x1fae98['push']({'item':_0x8a4d8f,'type':'elementStart'});for(const _0x283539 of _0x8a4d8f['getChildren']())this['_generateTape'](_0x283539,_0x1fae98);_0x8a4d8f['is']('element')&&_0x1fae98['push']({'item':_0x8a4d8f,'type':'elementEnd'});}return _0x1fae98;}['_getState'](){const _0x3f1367=new Map(this['_touched']),_0x536f13=new Map(_0x3f1367),_0x3c80dd=new Map(),_0x5371d0={'insertions':{},'deletions':{}},_0x107cce={'insertions':{},'deletions':{}},_0x5d715b=new Map(),_0x51c616=new Set([...this['_baseRoots']['keys'](),...this['_diffRoots']['keys']()]);_0x51c616['delete']('$graveyard');for(const _0x30ce46 of _0x51c616){const _0x377f15=this['_diffRoots']['get'](_0x30ce46)||N(_0x30ce46,!0x1),_0x386e36=this['_baseRoots']['get'](_0x30ce46)||N(_0x30ce46,!0x1);_0x377f15['isAttached']()||_0x386e36['isAttached']()?(_0x5371d0['insertions'][_0x30ce46]=x(_0x377f15),_0x5371d0['deletions'][_0x30ce46]=x(_0x386e36),this['_copyMarkers'](_0x5371d0['deletions'][_0x30ce46],_0x386e36),this['_copyMarkers'](_0x5371d0['insertions'][_0x30ce46],_0x377f15),_0x107cce['insertions'][_0x30ce46]=this['_generateTape'](this['_idsRoots']['get'](_0x30ce46),[]),_0x107cce['deletions'][_0x30ce46]=this['_generateTape'](this['_baseIdsRoots']['get'](_0x30ce46)||N(_0x30ce46,!0x1),[])):_0x51c616['delete'](_0x30ce46);}for(const _0x327600 of _0x51c616){const _0x4d22cc=_0x107cce['insertions'][_0x327600];for(const _0x565a86 of _0x4d22cc){const _0xe167f5=this['_getVidAttributeName'](_0x565a86),_0x5dafc2=_0x565a86['item']['getAttribute'](_0xe167f5);_0x536f13['delete'](_0x5dafc2),_0x5dafc2>=this['_startingRevisionId']&&_0x3c80dd['set'](_0x5dafc2,_0x3f1367['get'](_0x5dafc2));}}for(const _0x3de0d8 of _0x51c616){const _0x8b0978=_0x107cce['insertions'][_0x3de0d8],_0x29e024=this['_getBaseVids'](_0x107cce['deletions'][_0x3de0d8]);let _0x1644c5=0x0;for(const _0x29bec2 of _0x8b0978){const _0x3f76e8=this['_getVidAttributeName'](_0x29bec2),_0x3d8b2b=_0x29bec2['item']['getAttribute'](_0x3f76e8);if(!_0x3c80dd['has'](_0x3d8b2b)&&!_0x5d715b['has'](_0x3d8b2b)){if(_0x536f13['has'](_0x3d8b2b))_0x1644c5++;else{if(_0x3d8b2b!=_0x29e024[_0x1644c5]){const _0x54e8c2=_0x3f1367['get'](_0x3d8b2b)||_0x3f1367['get'](_0x29e024[_0x1644c5]);for(;_0x3d8b2b!=_0x29e024[_0x1644c5];)_0x536f13['has'](_0x29e024[_0x1644c5])||(_0x5d715b['set'](_0x29e024[_0x1644c5],_0x54e8c2),_0x3f1367['set'](_0x29e024[_0x1644c5],_0x54e8c2)),_0x1644c5++;}_0x1644c5++;}}}}for(const _0x4be90a of _0x51c616){const _0x549d93=_0x107cce['insertions'][_0x4be90a];for(const _0x364231 of _0x549d93){const _0x4e1c3e=this['_getVidAttributeName'](_0x364231),_0x507555=_0x364231['item']['getAttribute'](_0x4e1c3e);if(_0x5d715b['has'](_0x507555)){const _0x491558=_0x5d715b['get'](_0x507555);_0x536f13['has'](_0x507555)||_0x536f13['set'](_0x507555,{..._0x491558}),_0x3c80dd['set'](_0x507555,{..._0x491558});}}}for(const _0xe2e6fe of _0x536f13['keys']())_0xe2e6fe>=this['_startingRevisionId']&&_0x536f13['delete'](_0xe2e6fe);const _0x1ce849=new Map();for(const _0x4ab2c7 of _0x51c616){let _0x5c4c97=_0x107cce['insertions'][_0x4ab2c7];for(const _0xb62435 of _0x5c4c97)if(_0xb62435['item']['is']('element','tableCell')){const _0x14d861=this['_getVidAttributeName'](_0xb62435),_0x51e33d=_0xb62435['item']['getAttribute'](_0x14d861);if(_0x3c80dd['has'](_0x51e33d)){const _0x2f1bbb=_0xb62435['item']['parent']['parent']['getAttribute']('vid_start'),_0x41532b=_0x1ce849['get'](_0x2f1bbb)||new Set();_0x41532b['add'](_0x3c80dd['get'](_0x51e33d)['userId']),_0x1ce849['set'](_0x2f1bbb,_0x41532b);}}_0x5c4c97=_0x107cce['deletions'][_0x4ab2c7];for(const _0x47bf38 of _0x5c4c97)if(_0x47bf38['item']['is']('element','tableCell')){const _0x3e1fea=this['_getVidAttributeName'](_0x47bf38),_0x34c5c1=_0x47bf38['item']['getAttribute'](_0x3e1fea);if(_0x536f13['has'](_0x34c5c1)){const _0x433678=_0x47bf38['item']['parent']['parent']['getAttribute']('vid_start'),_0x1ac488=_0x1ce849['get'](_0x433678)||new Set();_0x1ac488['add'](_0x536f13['get'](_0x34c5c1)['userId']),_0x1ce849['set'](_0x433678,_0x1ac488);}}for(const _0x706f1 of _0x1ce849['keys']())(_0x3c80dd['has'](_0x706f1)||_0x536f13['has'](_0x706f1))&&_0x1ce849['delete'](_0x706f1);}for(const _0x278217 of _0x51c616){const _0x3dae1c=_0x107cce['insertions'][_0x278217];let _0x4f758f=null,_0x30a904=null;for(const _0x1b9e52 of _0x3dae1c){const _0x4dd45c=this['_getVidAttributeName'](_0x1b9e52),_0x15c36c=_0x1b9e52['item']['getAttribute'](_0x4dd45c),_0x2afcbc=_0x1ce849['get'](_0x15c36c);_0x2afcbc&&'elementStart'==_0x1b9e52['type']&&(_0x4f758f=Array['from'](_0x2afcbc)[0x0],_0x30a904=_0x1b9e52['item']['getAttribute']('vid_end')),_0x4f758f&&(_0x536f13['set'](_0x15c36c,{'userId':_0x4f758f}),_0x3c80dd['set'](_0x15c36c,{'userId':_0x4f758f})),_0x15c36c==_0x30a904&&(_0x4f758f=null,_0x30a904=null);}}const _0x3237c={},_0x1a40e3=new Set();for(const _0x4e7094 of _0x51c616){const _0x6f33e3=_0x5371d0['deletions'][_0x4e7094],_0xf6a8e2=_0x5371d0['insertions'][_0x4e7094];for(const {userId:_0x9fe85c}of this['_touchedMarkers']['values']())null!==_0x9fe85c&&_0x1a40e3['add'](_0x9fe85c);for(const {userId:_0x2f08d1}of this['_touchedRoots']['values']())null!==_0x2f08d1&&_0x1a40e3['add'](_0x2f08d1);this['_markChanges'](_0xf6a8e2,_0x107cce['insertions'][_0x4e7094],_0x3c80dd,'insertion',_0x1a40e3),this['_markChanges'](_0x6f33e3,_0x107cce['deletions'][_0x4e7094],_0x536f13,'deletion',_0x1a40e3),_0x3237c[_0x4e7094]={'insertions':this['_prepareViewToSave'](_0xf6a8e2),'deletions':this['_prepareViewToSave'](_0x6f33e3),'attachChange':this['_touchedRoots']['get'](_0x4e7094)||null,'attributesBefore':_0x240ca5(this['_baseRootsAttributes']['get'](_0x4e7094))||{},'attributesAfter':_0x240ca5(this['_diffRootsAttributes']['get'](_0x4e7094))};}return{'diffData':_0x3237c,'authorsIds':Array['from'](_0x1a40e3)};}['_processRootBeforeSave'](_0x150e6b){for(const [,_0x598441]of _0x150e6b['markers']){const _0xa0cd71=_0x598441['start']['getAncestors']()['filter'](_0x16e923=>'tableCell'==_0x16e923['name']);for(const _0x2cf1a5 of _0xa0cd71)0x1==_0x2cf1a5['childCount']&&_0x2cf1a5['getChild'](0x0)['is']('element','paragraph')&&_0x2cf1a5['getChild'](0x0)['_setAttribute']('keepParagraph',!0x0);}}['_prepareViewToSave'](_0x1654ab){this['_processRootBeforeSave'](_0x1654ab);const _0x5c93cc=this['editor']['data']['toView'](_0x1654ab,{}),_0x5100b0=Array['from'](_0x5c93cc['getChildren']())['map'](_0x9daa70=>this['_getViewJson'](_0x9daa70));return JSON['stringify'](_0x5100b0);}['_getViewJson'](_0x2ed4c0){if(_0x2ed4c0['is']('$text'))return _0x2ed4c0['data'];{const _0x20195c=this['editor']['plugins']['get']('RevisionHistoryUtils'),_0x4a0c55=_0x2ed4c0,_0x36f178=this['editor']['data']['htmlProcessor']['domConverter'],_0x316f08={'type':_0x20195c['_getTypeCharForViewElement'](_0x4a0c55),'name':_0x4a0c55['name'],'attributes':Array['from'](_0x4a0c55['getAttributes']()),'children':Array['from'](_0x4a0c55['getChildren']())['map'](_0x17d07c=>this['_getViewJson'](_0x17d07c))};if(_0x2ed4c0['is']('uiElement')&&'$comment'!=_0x2ed4c0['name']){const _0x4e254e=_0x2ed4c0['render'](_0x36f178['domDocument'],_0x36f178);_0x316f08['children']['push'](_0x4e254e['outerHTML']);}else{if(_0x2ed4c0['is']('rawElement')){const _0x512148=_0x36f178['domDocument']['createElement'](_0x4a0c55['name']);_0x2ed4c0['render'](_0x512148,_0x36f178),_0x316f08['children']['push'](_0x512148['innerHTML']);}}const _0x1ca131=Array['from'](_0x4a0c55['getCustomProperties']());_0x1ca131['length']>0x0&&(_0x316f08['customProperties']=_0x1ca131);const _0x22bdf3=_0x4a0c55['getFillerOffset']();return null!==_0x22bdf3&&(_0x316f08['fillerOffset']=_0x22bdf3),_0x316f08;}}['_markChanges'](_0x13abb6,_0x444749,_0x23b830,_0x640deb,_0x2db6ff){let _0x3224c0=null,_0x470154=null,_0x34ab0a=0x0;const _0x250e84=this['editor']['model'];for(let _0x699022=0x0;_0x699022<_0x444749['length'];_0x699022++){const _0x795d69=this['_getVidAttributeName'](_0x444749[_0x699022]),_0x2e9335=_0x444749[_0x699022]['item']['getAttribute'](_0x795d69),_0x11bcc7=_0x23b830['get'](_0x2e9335),_0x5be963=_0x699022==_0x444749['length']-0x1;(!_0x3224c0&&_0x11bcc7&&(_0x3224c0=_0x11bcc7,_0x470154=_0x444749[_0x699022]),_0x3224c0&&(!_0x11bcc7||_0x11bcc7['userId']!=_0x3224c0['userId']))&&(_0xc3ac46(_0x11bcc7,P(_0x470154,_0x13abb6,_0x250e84),P(_0x444749[_0x699022],_0x13abb6,_0x250e84)),_0x3224c0=_0x11bcc7||null,_0x470154=_0x11bcc7?_0x444749[_0x699022]:null),_0x3224c0&&_0x5be963&&_0xc3ac46(_0x11bcc7,P(_0x470154,_0x13abb6,_0x250e84),V(_0x444749[_0x699022],_0x13abb6,_0x250e84));}function _0xc3ac46(_0x112f4d,_0x1129d1,_0x562d2c){const _0x249ab1=_0x3224c0['userId'],_0xa38404='revision:'+_0x640deb+':'+_0x249ab1+':'+_0x34ab0a++,_0x433533=_0x250e84['createRange'](_0x1129d1,_0x562d2c);_0x13abb6['markers']['set'](_0xa38404,_0x433533),null!==_0x249ab1&&_0x2db6ff['add'](_0x249ab1);}}['_getVidAttributeName'](_0x152dcd){switch(_0x152dcd['type']){case'elementStart':return'vid_start';case'elementEnd':return'vid_end';default:return'vid';}}['_fixOperation'](_0x38ed19,_0x147f10){_0x38ed19['baseVersion']=null;for(const _0xc06862 in _0x38ed19){const _0x84aaa=_0x38ed19[_0xc06862];if(_0x84aaa instanceof _0x569535){const _0x5738f3=_0x147f10['get'](_0x84aaa['root']['rootName']);_0x38ed19[_0xc06862]=this['_fixPosition'](_0x84aaa,_0x5738f3);}if(_0x84aaa instanceof _0x5d129e){const _0x5523f6=_0x147f10['get'](_0x84aaa['root']['rootName']);_0x38ed19[_0xc06862]=this['_fixRange'](_0x84aaa,_0x5523f6);}'root'===_0xc06862&&(_0x38ed19['root']=_0x147f10['get'](_0x38ed19['root']['rootName']));}}['_fixRange'](_0x83a7dc,_0x26602c){return this['editor']['model']['createRange'](this['_fixPosition'](_0x83a7dc['start'],_0x26602c),this['_fixPosition'](_0x83a7dc['end'],_0x26602c));}['_fixPosition'](_0x3b3cef,_0x42fd6b){return this['editor']['model']['createPositionFromPath'](_0x42fd6b,_0x3b3cef['path'],_0x3b3cef['stickiness']);}['_handleInsertOperation'](_0x219246){const _0x121abc=this['_idsRoots']['get'](_0x219246['position']['root']['rootName']),_0x1e09f5=this['_fixPosition'](_0x219246['position'],_0x121abc),_0x402175=null===_0x219246['_authorId']?null:_0x219246['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x16eef9=_0x1e09f5['parent'],_0x1130aa=this['_revisionId'],_0x3d0edf=[];for(const _0x169b58 of _0x219246['nodes'])if(_0x169b58['is']('element'))_0x3d0edf['push'](this['_makeIdsRoot'](_0x169b58));else{for(let _0x1d43aa=0x0;_0x1d43aa<_0x169b58['offsetSize'];_0x1d43aa++)_0x3d0edf['push'](new _0x429deb('$text',{'vid':this['_revisionId']++}));}const _0x20cddf=this['_revisionId'];for(let _0x3641ca=_0x1130aa;_0x3641ca<_0x20cddf;_0x3641ca++)this['_touched']['set'](_0x3641ca,{'userId':_0x402175});_0x16eef9['_insertChild'](_0x1e09f5['offset'],_0x3d0edf);}['_handleMoveOperation'](_0x45d48a){(_0x45d48a=this['_cloneOperation'](_0x45d48a,this['_idsRoots']))['_execute']();const _0x153ac3=null===_0x45d48a['_authorId']?null:_0x45d48a['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x3189e0=_0x45d48a['getMovedRangeStart'](),_0x3699f8=_0x3189e0['parent'],_0xfc3790=_0x3189e0['offset'];!function _0xa56eae(_0x54fa1c,_0x3deee4,_0x54cc2c,_0x377e15){for(let _0x2d885f=_0x54cc2c;_0x2d885f<_0x377e15;_0x2d885f++){const _0x149319=_0x3deee4['getChild'](_0x2d885f);_0x149319['is']('element','$text')?_0x54fa1c['set'](_0x149319['getAttribute']('vid'),{'userId':_0x153ac3}):(_0x54fa1c['set'](_0x149319['getAttribute']('vid_start'),{'userId':_0x153ac3}),_0xa56eae(_0x54fa1c,_0x149319,0x0,_0x149319['childCount']),_0x54fa1c['set'](_0x149319['getAttribute']('vid_end'),{'userId':_0x153ac3}));}}(this['_touched'],_0x3699f8,_0xfc3790,_0xfc3790+_0x45d48a['howMany']);}['_handleMergeOperation'](_0x3c96d2){const _0x2c6993=null===(_0x3c96d2=this['_cloneOperation'](_0x3c96d2,this['_idsRoots']))['_authorId']?null:_0x3c96d2['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x57396f=_0x3c96d2['targetPosition']['parent'],_0xc907c6=_0x3c96d2['sourcePosition']['parent'],_0xe914dd=_0x57396f['getAttribute']('vid_end'),_0x2408ae=_0xc907c6['getAttribute']('vid_start');_0x57396f['_setAttribute']('vid_end',_0xc907c6['getAttribute']('vid_end')),_0xc907c6['_setAttribute']('vid_end',_0xe914dd),this['_touched']['set'](_0x2408ae,{'userId':_0x2c6993}),this['_touched']['set'](_0xe914dd,{'userId':_0x2c6993}),_0x3c96d2['_execute']();}['_handleSplitOperation'](_0x428f99){const _0x2b115c=null===(_0x428f99=this['_cloneOperation'](_0x428f99,this['_idsRoots']))['_authorId']?null:_0x428f99['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x47955f=_0x428f99['graveyardPosition'],_0x44a7e1=_0x428f99['splitPosition']['parent'];_0x428f99['_execute']();const _0x4eb6c1=_0x44a7e1['getAttribute']('vid_end'),_0xdd7676=_0x428f99['insertionPosition']['nodeAfter'];if(_0x47955f){const _0x336cba=_0xdd7676['getAttribute']('vid_end'),_0x2eb9bf=_0x44a7e1['getAttribute']('vid_end');_0x44a7e1['_setAttribute']('vid_end',_0x336cba),_0xdd7676['_setAttribute']('vid_end',_0x2eb9bf),this['_touched']['set'](_0x44a7e1['getAttribute']('vid_end'),{'userId':_0x2b115c}),this['_touched']['set'](_0xdd7676['getAttribute']('vid_start'),{'userId':_0x2b115c});}else{const _0x34bc7d=this['_revisionId']++,_0x22d8b4=this['_revisionId']++;_0x44a7e1['_setAttribute']('vid_end',_0x34bc7d),_0xdd7676['_setAttribute']('vid_start',_0x22d8b4),_0xdd7676['_setAttribute']('vid_end',_0x4eb6c1),this['_touched']['set'](_0x34bc7d,{'userId':_0x2b115c}),this['_touched']['set'](_0x22d8b4,{'userId':_0x2b115c});}}['_handleMarkerOperation'](_0x1a38a5){if(!_0x1a38a5['affectsData'])return;const _0x3cad68=(_0x1a38a5=this['_cloneOperation'](_0x1a38a5,this['_diffRoots']))['oldRange']?_0x1a38a5['oldRange']['root']:null,_0x130321=_0x1a38a5['newRange']?_0x1a38a5['newRange']['root']:null;_0x3cad68&&this['_markers']['delete'](_0x1a38a5['name']),_0x130321&&this['_markers']['set'](_0x1a38a5['name'],_0x1a38a5['newRange']['clone']());const _0x34e90e=null===_0x1a38a5['_authorId']?null:_0x1a38a5['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x34adc8=_0x1a38a5['name'];if(!this['_touchedMarkers']['has'](_0x34adc8))return void this['_touchedMarkers']['set'](_0x34adc8,{'range':_0x1a38a5['oldRange'],'userId':_0x34e90e});const _0x14f4de=this['_touchedMarkers']['get'](_0x34adc8),_0x222426=_0x14f4de['range'],_0x3293a9=_0x1a38a5['newRange'];null==_0x222426&&null==_0x3293a9||_0x222426&&_0x3293a9&&_0x222426['isEqual'](_0x3293a9)?this['_touchedMarkers']['delete'](_0x1a38a5['name']):_0x14f4de['userId']=_0x34e90e;}['_handleRootOperation'](_0x47719c,_0x3053eb){this['_diffRoots']['has'](_0x47719c['rootName'])?this['_diffRoots']['get'](_0x47719c['rootName'])['_isAttached']=_0x47719c['isAdd']:(this['_diffRoots']['set'](_0x47719c['rootName'],N(_0x47719c['rootName'],!0x0)),this['_diffRootsAttributes']['set'](_0x47719c['rootName'],{}),_0x3053eb&&this['_idsRoots']['set'](_0x47719c['rootName'],N(_0x47719c['rootName'],!0x0)));const _0x4c623b=null===_0x47719c['_authorId']?null:_0x47719c['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x505a9f=this['_touchedRoots']['get'](_0x47719c['rootName']);_0x505a9f&&_0x505a9f['userId']===_0x4c623b?this['_touchedRoots']['delete'](_0x47719c['rootName']):this['_touchedRoots']['set'](_0x47719c['rootName'],{'userId':_0x4c623b,'isAttached':_0x47719c['isAdd']});}['_handleRootAttributeOperation'](_0x13e1f4){const _0x34acfc=this['_diffRootsAttributes']['get'](_0x13e1f4['root']['rootName']);null===_0x13e1f4['newValue']?delete _0x34acfc[_0x13e1f4['key']]:_0x34acfc[_0x13e1f4['key']]=_0x13e1f4['newValue'];}}function x(_0x5230e6){const _0x1383f0=N(_0x5230e6['rootName'],_0x5230e6['isAttached']());for(const _0x5a13b5 of _0x5230e6['getChildren']()){const _0x49ade1=_0x5a13b5['_clone'](!0x0);_0x1383f0['_appendChild'](_0x49ade1);}return _0x1383f0;}function N(_0x5aadc6,_0x1ed642=!0x0){const _0x545f46=new _0x24ebb7();return _0x545f46['rootName']=_0x5aadc6,_0x545f46['_isAttached']=_0x1ed642,_0x545f46['isAttached']=()=>_0x545f46['_isAttached'],_0x545f46;}function P(_0x1d0139,_0x57faaf,_0x24d486){const _0x39915d='elementEnd'==_0x1d0139['type']?_0x24d486['createPositionAt'](_0x1d0139['item'],'end'):_0x24d486['createPositionBefore'](_0x1d0139['item']);return _0x24d486['createPositionFromPath'](_0x57faaf,_0x39915d['path'],_0x39915d['stickiness']);}function V(_0x3da172,_0x2a53db,_0xbfd8e7){const _0x3bb3d9='elementStart'==_0x3da172['type']?_0xbfd8e7['createPositionAt'](_0x3da172['item'],0x0):_0xbfd8e7['createPositionAfter'](_0x3da172['item']);return _0xbfd8e7['createPositionFromPath'](_0x2a53db,_0x3bb3d9['path'],_0x3bb3d9['stickiness']);}class he extends/* #__PURE__ -- @preserve */
25
- _0x3f52ee(_0x2d670e){['focusTracker'];['keystrokes'];['revisionNameInputView'];constructor(_0x1e25ef,_0x56a017){super(_0x1e25ef),this['focusTracker']=new _0x408ec4(),this['keystrokes']=new _0x4d84bf(),this['set']('revisionNameInputValue',''),this['revisionNameInputView']=this['_createRevisionNameInput'](_0x56a017),this['setTemplate']({'tag':'form','attributes':{'class':['ck','ck-revision-history-save-revision-form','ck-responsive-form'],'tabindex':'-1'},'children':[this['revisionNameInputView']]}),this['initializeCssTransitionDisablerMixin']();}['render'](){super['render'](),_0x973ae7({'view':this}),this['focusTracker']['add'](this['revisionNameInputView']['element']),this['keystrokes']['listenTo'](this['element']);const _0x4492ca=_0x14e777=>_0x14e777['stopPropagation']();this['keystrokes']['set']('arrowright',_0x4492ca),this['keystrokes']['set']('arrowleft',_0x4492ca),this['keystrokes']['set']('arrowup',_0x4492ca),this['keystrokes']['set']('arrowdown',_0x4492ca);}['focus'](){this['revisionNameInputView']['focus']();}get['revisionName'](){return this['revisionNameInputView']['fieldView']['element']['value']['trim']();}set['revisionName'](_0x4aff17){this['revisionNameInputView']['fieldView']['element']['value']=_0x4aff17['trim']();}['reset'](){this['revisionNameInputView']['fieldView']['element']['value']='',this['revisionNameInputView']['errorText']=null;}['_createRevisionNameInput'](_0x2332bd){const _0x57dc78=new ti(this['locale'],_0x84c75d),_0x1b6ac8=_0x57dc78['fieldView'];_0x1b6ac8['extendTemplate']({'attributes':{'maxlength':'220'}});let _0x2b2e9b=R(this['locale'],'Name\x20of\x20the\x20revision');return!_0x2332bd&&(_0x2b2e9b+='\x20('+R(this['locale'],'optional')+')'),(_0x57dc78['label']=_0x2b2e9b,_0x1b6ac8['on']('input',()=>{this['revisionNameInputValue']=_0x1b6ac8['element']['value']['trim']();}),_0x57dc78);}}class v extends _0xb2d8c8{static get['pluginName'](){return'RevisionHistoryUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[h];}['_saveRevisionFormView'];['init'](){const _0x3e79a8=this['editor'],_0x577ef5=_0x3e79a8['plugins']['get']('RevisionTracker');_0x3e79a8['ui']['componentFactory']['add']('revisionHistory',_0xb0500a=>{const _0xb3663a=_0x455c58(_0xb0500a),_0x1551eb=_0xb3663a['panelView']['children'],_0x4ce1ff=new _0x174095(_0xb0500a),_0x47460e=new _0x2be811(_0xb0500a),_0x5bb4f4=new _0xbbf7fb(_0xb0500a),_0x3b6636=new _0x2be811(_0xb0500a),_0x4b7181=new _0xbbf7fb(_0xb0500a);return _0xb3663a['bind']('isEnabled')['to'](_0x577ef5,'isReady',_0x577ef5,'isEnabled',_0x3e79a8,'isReadOnly',(_0x30035f,_0x510999,_0x5bcb7c)=>_0x30035f&&_0x510999&&!_0x5bcb7c),_0xb3663a['buttonView']['set']({'icon':_0x378803,'label':R(_0xb0500a,'Revision\x20history'),'tooltip':!0x0}),_0x5bb4f4['set']({'label':R(_0xb0500a,'Save\x20current\x20revision'),'withText':!0x0,'role':'menuitem'}),_0x5bb4f4['bind']('isEnabled')['to'](_0x577ef5,'isReady',_0x577ef5,'isEnabled',_0x3e79a8,'isReadOnly',(_0x13c6f7,_0x336e6e,_0x2bbf07)=>_0x13c6f7&&_0x336e6e&&!_0x2bbf07),_0x5bb4f4['on']('execute',()=>this['_showDialog']()),_0x4b7181['set']({'label':R(_0xb0500a,'Open\x20revision\x20history'),'withText':!0x0,'role':'menuitem'}),_0x4b7181['bind']('isEnabled')['to'](_0x577ef5,'isReady',_0x3e79a8,'isReadOnly',(_0x5a6935,_0x2a7e6)=>_0x5a6935&&!_0x2a7e6),_0x4b7181['on']('execute',()=>{_0x3e79a8['config']['get']('revisionHistory')['showRevisionViewerCallback'](),_0xb3663a['isOpen']=!0x1,_0x3e79a8['editing']['view']['focus']();}),_0x47460e['children']['add'](_0x5bb4f4),_0x3b6636['children']['add'](_0x4b7181),_0x4ce1ff['role']='menu',_0x4ce1ff['items']['addMany']([_0x47460e,_0x3b6636]),_0x1551eb['add'](_0x4ce1ff),_0xb3663a;}),_0x3e79a8['ui']['componentFactory']['add']('menuBar:revisionHistory',()=>this['_registerMenuComponent']());}['_registerMenuComponent'](){const _0x1235e9=this['editor'],_0x596a5c=_0x1235e9['locale'],_0x24ac8a=new _0x3d1a00(_0x596a5c),_0x2101d1=new _0x7b6454(_0x596a5c);_0x24ac8a['buttonView']['set']({'icon':_0x378803,'label':R(_0x596a5c,'Revision\x20history')});const _0x3d7c01=new _0x28b6aa(_0x596a5c,_0x24ac8a),_0x39ec48=new _0x16e359(_0x596a5c);_0x39ec48['set']({'label':R(_0x596a5c,'Save\x20current\x20revision')}),_0x39ec48['delegate']('execute')['to'](_0x24ac8a),_0x39ec48['on']('execute',()=>{this['_showDialog']();}),_0x3d7c01['children']['add'](_0x39ec48),_0x2101d1['items']['add'](_0x3d7c01);const _0x110aa5=new _0x28b6aa(_0x596a5c,_0x24ac8a),_0x12eb57=new _0x16e359(_0x596a5c);return _0x12eb57['set']({'label':R(_0x596a5c,'Open\x20revision\x20history')}),_0x12eb57['delegate']('execute')['to'](_0x24ac8a),_0x12eb57['on']('execute',()=>{_0x1235e9['config']['get']('revisionHistory')['showRevisionViewerCallback']();}),_0x110aa5['children']['add'](_0x12eb57),_0x2101d1['items']['add'](_0x110aa5),_0x24ac8a['panelView']['children']['add'](_0x2101d1),_0x24ac8a;}['_showDialog'](){const _0x1afd9c=this['editor'],_0x4046d2=_0x1afd9c['locale'],_0x3b1724=_0x1afd9c['plugins']['get']('Dialog'),_0x3c1f6d=_0x1afd9c['plugins']['get']('RevisionTracker');function _0x108d6c(_0x172c94){_0x1afd9c['config']['get']('revisionHistory.requireRevisionName')&&''===_0x172c94['revisionName']?_0x172c94['revisionNameInputView']['errorText']=R(_0x4046d2,'The\x20revision\x20name\x20cannot\x20be\x20empty.'):(_0x1afd9c['plugins']['get'](h)['saveRevision']({'name':_0x172c94['revisionName']}),_0x3b1724['hide']());}this['_saveRevisionFormView']||(this['_createSaveRevisionFormView'](),this['_saveRevisionFormView']['on']('submit',()=>_0x108d6c(this['_saveRevisionFormView']))),this['_saveRevisionFormView']['reset'](),_0x3b1724['show']({'id':'revisionSave','title':R(_0x4046d2,'Save\x20current\x20revision'),'isModal':!0x0,'content':this['_saveRevisionFormView'],'actionButtons':[{'label':R(_0x1afd9c['locale'],'Cancel'),'withText':!0x0,'onExecute':()=>_0x3b1724['hide']()},{'label':R(_0x1afd9c['locale'],'Accept'),'class':'ck-button-action','withText':!0x0,'onCreate'(_0x33881b){_0x33881b['bind']('isEnabled')['to'](_0x3c1f6d,'isReady',_0x3c1f6d,'isEnabled',_0x1afd9c,'isReadOnly',(_0x175928,_0x7425d9,_0x375cf6)=>_0x175928&&_0x7425d9&&!_0x375cf6);},'onExecute':()=>_0x108d6c(this['_saveRevisionFormView'])}]});}['_createSaveRevisionFormView'](){const _0x31e8da=this['editor'],_0x564bd2=_0x31e8da['locale'];this['_saveRevisionFormView']=new he(_0x564bd2,_0x31e8da['config']['get']('revisionHistory.requireRevisionName')),this['_saveRevisionFormView']['render']();}}class z extends _0x2d670e{['changeId'];['_model'];constructor(_0x5448b2,_0x50a22e){super(_0x5448b2),this['_model']=_0x50a22e,this['changeId']=_0x50a22e['id'];const _0x29b87f=this['bindTemplate'],_0x35fadd=R(_0x5448b2,_0x50a22e['data']['isSuggestion']?'Suggested\x20by':'add'==_0x50a22e['type']?'Added\x20by':'Removed\x20by');this['set']('type',_0x50a22e['type']),this['setTemplate']({'tag':'div','attributes':{'class':['ck-annotation','ck-revision-change',_0x29b87f['to']('type',_0x414f21=>'ck-revision-change__'+_0x414f21)],'tabindex':-0x1},'children':[{'tag':'span','children':[{'tag':'span','attributes':{'class':['ck-revision-change__label']},'children':[{'text':_0x35fadd}]},{'text':'\x20'+_0x50a22e['author']['name']}]}]});}['focus'](){this['element']['focus']();}}class G extends/* #__PURE__ -- @preserve */
26
- _0x223ec6(){['id'];['author'];['type'];['data'];['rootName'];constructor(_0x292777){super(),this['id']=_0x292777['id']||_0x189557(),this['author']=_0x292777['author'],this['type']=_0x292777['type'],this['data']=_0x292777['data']||{},this['rootName']=_0x292777['rootName'],this['set']('createdAt',_0x292777['createdAt']);}['toJSON'](){return{'id':this['id'],'authorId':this['author']['id'],'type':this['type'],'data':this['data'],'createdAt':this['createdAt']};}}class J{['newRevisionId'];['oldRevisionId'];['changes'];constructor(_0x4a2a0e,_0x4170a2){this['newRevisionId']=_0x4a2a0e,this['oldRevisionId']=_0x4170a2,this['changes']=new _0x1e8ea3();}['_setChanges'](_0xcf9c67){for(const _0x30c447 of _0xcf9c67)this['changes']['add'](_0x30c447);}}class l extends _0xb2d8c8{['repository'];['adapter']=null;['_utils'];['_activeViewTarget'];['_changeView'];['_changeIdToChange'];['_balloon'];static get['pluginName'](){return'RevisionViewer';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[_0x3db46c,_0x1d58fa,S,$];}constructor(_0x4cac16){super(_0x4cac16),this['repository']=this['editor']['plugins']['get']('RevisionsRepository'),this['_utils']=this['editor']['plugins']['get']('RevisionHistoryUtils'),this['set']('activeChange',null),this['set']('activeView',null),this['_activeViewTarget']=null,this['set']('diff',null),this['set']('isReady',!0x1),this['set']('isEnabled',!0x0),this['on']('change:isEnabled',(_0x31b029,_0x12a6e9,_0xce3a1a)=>{this['activeChange']=null,this['activeView']=null,this['editor']['editing']['view']['change'](_0x4c22e6=>{for(const _0x5569cf of this['editor']['editing']['view']['document']['roots'])_0xce3a1a?_0x4c22e6['removeClass']('ck-editor__editable__overlay',_0x5569cf):_0x4c22e6['addClass']('ck-editor__editable__overlay',_0x5569cf);});}),this['bind']('isNavigationMode')['to'](this,'activeChange',_0x3eedbc=>null!==_0x3eedbc),this['bind']('currentChangeNumber')['to'](this,'isReady',this,'diff',this,'activeChange',(_0x53a879,_0x439e07,_0x514d80)=>_0x53a879&&_0x514d80?_0x439e07['changes']['getIndex'](_0x514d80):0x0),this['bind']('numberOfChanges')['to'](this,'isReady',this,'diff',(_0x30a370,_0x516336)=>_0x30a370?_0x516336['changes']['length']:0x0),this['_changeView']=null,this['_changeIdToChange']=new Map(),this['_balloon']=this['editor']['plugins']['get'](_0x1d58fa);}['init'](){const _0x369bc9=this['editor'],_0xe41bd6=new ot(_0x369bc9,{'direction':'backward'}),_0x1c8d2d=new ot(_0x369bc9,{'direction':'forward'});(_0x369bc9['commands']['add']('showPreviousChange',_0xe41bd6),_0x369bc9['commands']['add']('showNextChange',_0x1c8d2d),_0x369bc9['commands']['add']('restoreRevision',new nt(_0x369bc9)),this['on']('change:numberOfChanges',()=>{_0xe41bd6['refresh'](),_0x1c8d2d['refresh']();}),this['_setConversion'](),this['_initInteractions'](),_0x369bc9['enableReadOnlyMode']('revision-viewer'),_0x369bc9['plugins']['has']('WidgetToolbarRepository'))&&_0x369bc9['plugins']['get']('WidgetToolbarRepository')['forceDisabled']('revision-viewer');}async['getRevisionDocumentData'](_0x8d9e5){return await this['_utils']['loadRevisionData'](_0x8d9e5,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x8d9e5);}async['getRevisionRootsAttributes'](_0x38abac){return await this['_utils']['loadRevisionData'](_0x38abac,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x38abac);}async['compare'](_0x5b2f27,_0x1f1fc8,_0x5aa419=!0x1){if(!this['isEnabled'])return;const _0x4929d2=this['diff'],_0x32dbdb=this['repository'],_0x25b546='string'==typeof _0x5b2f27?_0x32dbdb['getRevision'](_0x5b2f27):_0x5b2f27,_0x2e192f='string'==typeof _0x1f1fc8?_0x32dbdb['getRevision'](_0x1f1fc8):_0x1f1fc8,_0x38fed0=_0x25b546['id'],_0x42a897=_0x2e192f?_0x2e192f['id']:null;if(!_0x5aa419&&this['diff']&&this['diff']['newRevisionId']===_0x38fed0&&this['diff']['oldRevisionId']===_0x42a897)return Promise['resolve']();this['isReady']=!0x1,this['activeView']=null,this['activeChange']=null,this['diff']=new J(_0x38fed0,_0x42a897);const _0x1fbf78=this['_getRevisionsRange'](_0x25b546,_0x2e192f,!0x0)['map'](_0x219bdf=>this['_utils']['loadRevisionData'](_0x219bdf,this['adapter']));return _0x1fbf78['push'](new Promise(_0x59ea0f=>{setTimeout(_0x59ea0f,0x14);})),Promise['all'](_0x1fbf78)['then'](()=>{if(!this['isEnabled'])return;this['_cleanUp']();const _0x16dcd2=this['_getDiff'](_0x38fed0,_0x42a897);for(const _0x3d996a of _0x16dcd2['changes'])this['_changeIdToChange']['set'](_0x3d996a['id'],_0x3d996a);this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x184877=>{for(const _0x21c8a4 of this['editor']['model']['document']['getRootNames']())_0x184877['detachRoot'](_0x21c8a4);for(const _0x1138d0 of Object['keys'](_0x16dcd2['model'])){const _0x537279=_0x184877['addRoot'](_0x1138d0);for(const _0x18c7f8 of Object['keys'](_0x16dcd2['attributes'][_0x1138d0]))_0x184877['setAttribute'](_0x18c7f8,_0x16dcd2['attributes'][_0x1138d0][_0x18c7f8],_0x537279);_0x184877['insert'](_0x16dcd2['model'][_0x1138d0],_0x537279,0x0);}}),this['diff']['_setChanges'](this['_sortAndFilterDiffChanges'](_0x16dcd2['changes'])),this['isReady']=!0x0;})['catch'](_0x2267cf=>{console['error'](_0x2267cf),this['_cleanUp'](),_0x4929d2&&(this['diff']=_0x4929d2),this['isReady']=!0x0;});}['addRevisionData'](_0x11df98,_0x1d45c2){const _0x1e95a5=this['repository']['createRevision'](_0x11df98);return _0x1e95a5['on']('_update',(_0x13de27,_0x115e05,_0x1dbfc2)=>_0x1d45c2(_0x115e05,_0x1dbfc2,_0x1e95a5)),this['repository']['addRevision'](_0x1e95a5),_0x1e95a5;}['_cleanUp'](){this['activeChange']=null,this['_cleanMarkers'](),this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=null,this['_changeIdToChange']['clear'](),this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x3a0129=>{for(const _0x42781c of this['editor']['model']['document']['getRootNames']())_0x3a0129['detachRoot'](_0x42781c);});}['_sortAndFilterDiffChanges'](_0x2bc1aa){const _0x4a8ae4=[],_0x4962c6=new Map();for(const _0x3d6eca of this['editor']['model']['document']['getRootNames']()){const _0x809eb0=this['editor']['editing']['view']['getDomRoot'](_0x3d6eca);if(!_0x809eb0)continue;const _0x2357b1=_0x809eb0['getClientRects']()['item'](0x0);_0x2357b1&&(_0x4a8ae4['push'](_0x3d6eca),_0x4962c6['set'](_0x3d6eca,_0x2357b1));}return _0x4a8ae4['sort']((_0x3ec8a,_0x288419)=>{const _0x109cf2=_0x4962c6['get'](_0x3ec8a),_0x1970f3=_0x4962c6['get'](_0x288419);return _0x109cf2['y']-_0x1970f3['y']||_0x109cf2['x']-_0x1970f3['x'];}),(_0x2bc1aa=_0x2bc1aa['filter'](_0x38064f=>_0x4a8ae4['includes'](_0x38064f['rootName'])))['sort']((_0x1209f8,_0x20ad2b)=>_0x4a8ae4['indexOf'](_0x1209f8['rootName'])-_0x4a8ae4['indexOf'](_0x20ad2b['rootName'])),_0x2bc1aa;}['_makeTape'](_0xe699eb){const _0x513b8e=Array['from'](_0xe699eb['markers'])['filter'](([_0x114429,_0x1c04ec])=>_0x114429['startsWith']('revision:')&&!_0x1c04ec['isCollapsed']),_0x4560c2=Array['from'](this['editor']['model']['createRangeIn'](_0xe699eb)['getWalker']({'singleCharacters':!0x0}));if(0x0!=_0x513b8e['length'])for(const _0x541891 of _0x4560c2){const [_0x116a44,_0x46b80f]=_0x513b8e[0x0],[,_0x2391d1,_0x13ca4e]=_0x116a44['split'](':');if(_0x46b80f['end']['isEqual'](_0x541891['nextPosition'])&&_0x513b8e['shift'](),(_0x541891['previousPosition']['isEqual'](_0x46b80f['start'])||_0x541891['previousPosition']['isAfter'](_0x46b80f['start']))&&('insertion'==_0x2391d1?_0x541891['isAdded']={'userId':_0x13ca4e}:'deletion'==_0x2391d1&&(_0x541891['isRemoved']={'userId':_0x13ca4e})),0x0==_0x513b8e['length'])break;}return _0x4560c2;}['_refreshStartEndIndex'](_0xc4d246){const _0x3374dc=new Map();for(let _0x200875=0x0;_0x200875<_0xc4d246['length'];_0x200875++)'text'===_0xc4d246[_0x200875]['type']?(_0xc4d246[_0x200875]['item']['startIndex']=_0x200875,_0xc4d246[_0x200875]['item']['endIndex']=_0x200875):('elementStart'===_0xc4d246[_0x200875]['type']?_0xc4d246[_0x200875]['item']['startIndex']=_0x200875:'elementEnd'===_0xc4d246[_0x200875]['type']&&(_0xc4d246[_0x200875]['item']['endIndex']=_0x200875),_0x3374dc['set'](_0xc4d246[_0x200875]['id'],_0x200875));for(const _0x228c8e of _0x3374dc['values']())'elementStart'===_0xc4d246[_0x228c8e]['type']?_0xc4d246[_0x228c8e]['item']['endIndex']=_0x3374dc['get'](_0xc4d246[_0x228c8e]['pairId']):'elementEnd'===_0xc4d246[_0x228c8e]['type']&&(_0xc4d246[_0x228c8e]['item']['startIndex']=_0x3374dc['get'](_0xc4d246[_0x228c8e]['pairId']));}['_processTape'](_0x38d196){for(let _0x51e6d0=0x0;_0x51e6d0<_0x38d196['length'];_0x51e6d0++){if('elementStart'===_0x38d196[_0x51e6d0]['type'])_0x38d196[_0x51e6d0]['item']['startIndex']=_0x51e6d0;else{if('elementEnd'===_0x38d196[_0x51e6d0]['type']){_0x38d196[_0x51e6d0]['item']['endIndex']=_0x51e6d0;const _0x33b638=_0x38d196[_0x51e6d0]['item']['startIndex'];_0x38d196[_0x33b638]['pairId']=_0x38d196[_0x51e6d0]['id'],_0x38d196[_0x51e6d0]['pairId']=_0x38d196[_0x33b638]['id'];}else _0x38d196[_0x51e6d0]['item']['startIndex']=_0x51e6d0,_0x38d196[_0x51e6d0]['item']['endIndex']=_0x51e6d0,_0x38d196[_0x51e6d0]['pairId']=null;}_0x38d196[_0x51e6d0]['markersStart']||(_0x38d196[_0x51e6d0]['markersStart']=[],_0x38d196[_0x51e6d0]['markersEnd']=[]);}}['_markInsertions'](_0xb12ab3,_0x101cc3){const _0x46d23d=_0xb12ab3['filter'](_0x5743bb=>!_0x5743bb['isAdded']);for(let _0x479eda=0x0;_0x479eda<_0x101cc3['length'];_0x479eda++)_0x101cc3[_0x479eda]['isAdded']&&(_0x46d23d[_0x479eda]['isAdded']=_0x101cc3[_0x479eda]['isAdded']);}['_getDiff'](_0x553270,_0x32de30=null){const _0x54a364=this['repository']['getRevision'](_0x553270),_0x573d94=_0x32de30?this['repository']['getRevision'](_0x32de30):null,_0x540739=this['_getRevisionsRange'](_0x54a364,_0x573d94),_0x39d99a=_0x540739[_0x540739['length']-0x1],_0x2e6919=new Map(),_0x34d168={'model':{},'attributes':{},'changes':[]},_0x49c6db=new Set(),_0xc783e5=new Map();for(let _0x17739d=_0x540739['length']-0x1;_0x17739d>=0x0;_0x17739d--){const _0x545a23=_0x540739[_0x17739d];for(const _0x4b9e41 of Object['keys'](_0x545a23['diffData']))if(_0x545a23['diffData'][_0x4b9e41]['attachChange']){const _0x32731d=_0x545a23['diffData'][_0x4b9e41]['attachChange'];_0x32731d['isAttached']?(_0x49c6db['add'](_0x4b9e41),_0xc783e5['has'](_0x4b9e41)&&_0xc783e5['get'](_0x4b9e41)['userId']==_0x32731d['userId']?_0xc783e5['delete'](_0x4b9e41):_0xc783e5['set'](_0x4b9e41,_0x32731d)):_0xc783e5['has'](_0x4b9e41)?(_0x49c6db['delete'](_0x4b9e41),_0xc783e5['delete'](_0x4b9e41)):(_0x49c6db['add'](_0x4b9e41),_0xc783e5['set'](_0x4b9e41,_0x32731d));}else _0x49c6db['add'](_0x4b9e41);}for(const _0x1ebfbc of _0x49c6db){const _0x14bdba=_0xc783e5['has'](_0x1ebfbc)&&!_0xc783e5['get'](_0x1ebfbc)['isAttached'];let _0x81c503=_0x14bdba?_0x540739['length']-0x1:0x0;const _0x5339a3=_0x14bdba?-0x1:0x1;for(;_0x540739[_0x81c503];){const _0x5e0693=_0x540739[_0x81c503];if(_0x5e0693['diffData'][_0x1ebfbc]){const _0x1806ae=_0x14bdba?_0x5e0693['diffData'][_0x1ebfbc]['attributesBefore']:_0x5e0693['diffData'][_0x1ebfbc]['attributesAfter'];_0x34d168['attributes'][_0x1ebfbc]=_0x1806ae?_0x240ca5(_0x1806ae):{};break;}_0x81c503+=_0x5339a3;}}for(const _0x7c6cb5 of _0x540739){_0x7c6cb5['model']={};for(const _0x273193 of _0x7c6cb5['authors'])_0x2e6919['set'](_0x273193['id'],_0x273193);for(const _0x1760e7 of _0x49c6db){const _0x34c605=_0x7c6cb5['diffData'][_0x1760e7]?_0x7c6cb5['diffData'][_0x1760e7]['insertions']:'[]',_0x3b5f1f=_0x7c6cb5['diffData'][_0x1760e7]?_0x7c6cb5['diffData'][_0x1760e7]['deletions']:'[]';_0x7c6cb5['model'][_0x1760e7]={'insertions':this['_utils']['_makeModelFromViewString'](_0x34c605),'deletions':this['_utils']['_makeModelFromViewString'](_0x3b5f1f)};}}for(const _0x382c1e of _0x49c6db){let _0x3c9e5d=null,_0x823816=0x0;const _0x471afa=new Map(Array['from'](_0x54a364['model'][_0x382c1e]['insertions']['markers'])['filter'](([_0x488210])=>!_0x488210['startsWith']('revision:')));let _0x354a13=0x0;for(const _0xa8d2bc of _0x540739){const _0x9329cb=this['_makeTape'](_0xa8d2bc['model'][_0x382c1e]['insertions']);_0xa8d2bc==_0x54a364?(_0x3c9e5d=_0x9329cb,_0x823816=_0x3c9e5d['length'],_0x3c9e5d['forEach'](_0x575842=>{_0x575842['id']=_0x354a13++;}),this['_processTape'](_0x3c9e5d)):this['_markInsertions'](_0x3c9e5d,_0x9329cb);const _0x16c0a7=_0x3c9e5d['filter'](_0x58d0e6=>!_0x58d0e6['isAdded'])['map'](_0x306386=>_0x306386['id']);let _0x3a927e=0x0;const _0xc3e55b=this['_makeTape'](_0xa8d2bc['model'][_0x382c1e]['deletions']);_0xc3e55b['forEach'](_0x9ffe11=>{_0x9ffe11['isRemoved']?_0x9ffe11['id']=_0x823816++:_0x9ffe11['id']=_0x16c0a7[_0x3a927e++];}),this['_processTape'](_0xc3e55b),this['_setDistance'](_0x3c9e5d,'isAdded'),this['_setDistance'](_0xc3e55b,'isRemoved'),_0xa8d2bc==_0x54a364&&this['_markMarkers'](_0x3c9e5d,_0x471afa),_0x3c9e5d=this['_joinTapes'](_0x3c9e5d,_0xc3e55b),this['_refreshStartEndIndex'](_0x3c9e5d),this['_setDistance'](_0x3c9e5d,'isRemoved');}_0x3c9e5d=_0x3c9e5d['filter'](_0xd556a1=>!(_0xd556a1['isAdded']&&_0xd556a1['isRemoved']));const _0x5a3cd2=new Map(_0x39d99a['model'][_0x382c1e]['deletions']['markers']),_0x165752=new Set(_0x471afa['keys']());for(const _0x1ae718 of _0x5a3cd2['keys']())_0x165752['delete'](_0x1ae718);this['_markSuggestions'](_0x3c9e5d,_0x165752),this['_fixObsoleteTags'](_0x3c9e5d),_0x3c9e5d=this['_removeMissingPairs'](_0x3c9e5d),_0x3c9e5d=this['_markMismatchedRemovedTags'](_0x3c9e5d),_0x3c9e5d=this['_removeUnsupportedChanges'](_0x3c9e5d);const {root:_0x411d13,changes:_0x336652}=this['_makeModelFromTape'](_0x3c9e5d,_0x2e6919,_0x382c1e);_0x34d168['model'][_0x382c1e]=_0x411d13;const _0x386046=_0xc783e5['get'](_0x382c1e);if(_0x386046){const _0x2bec62=_0x2e6919['get'](_0x386046['userId']),_0x499d77=new G({'author':_0x2bec62,'type':_0x386046['isAttached']?'add':'remove','data':{'isOnRoot':!0x0},'createdAt':new Date(),'rootName':_0x382c1e});_0x336652['unshift'](_0x499d77),_0x34d168['attributes'][_0x382c1e]['revisionHistoryAttachChange']=_0x499d77['id'];}_0x34d168['changes']=_0x34d168['changes']['concat'](_0x336652);}return _0x34d168;}['_markMarkers'](_0x21d51f,_0x57f1cb){for(let _0x42d0fd=0x0;_0x42d0fd<_0x21d51f['length'];_0x42d0fd++)for(const [_0x1aac00,_0x4ac2ba]of _0x57f1cb)!_0x4ac2ba['isCollapsed']&&_0x4ac2ba['start']['isEqual'](_0x21d51f[_0x42d0fd]['previousPosition'])&&_0x21d51f[_0x42d0fd]['markersStart']['push'](_0x1aac00),_0x4ac2ba['end']['isEqual'](_0x21d51f[_0x42d0fd]['nextPosition'])&&_0x21d51f[_0x42d0fd]['markersEnd']['push'](_0x1aac00);}['_joinTapes'](_0xe349df,_0xb527e2){let _0x174b66=[],_0xc91e4d=0x0,_0x4bbae9=0x0;for(;_0xc91e4d<_0xe349df['length']||_0x4bbae9<_0xb527e2['length'];){const _0x147435=_0xe349df[_0xc91e4d]||{},_0x27289f=_0xb527e2[_0x4bbae9]||{};if(_0x147435['id']==_0x27289f['id'])_0xc91e4d++,_0x4bbae9++,_0x174b66['push'](_0x147435);else{if(_0x27289f['isRemoved']&&_0x147435['isAdded']){const {commonTape:_0x3f0d52,iEnd:_0x1c2f6c,jEnd:_0x172e79}=this['_threeWayMerge'](_0xe349df,_0xc91e4d,_0xb527e2,_0x4bbae9);_0x174b66=_0x174b66['concat'](_0x3f0d52),_0xc91e4d=_0x1c2f6c,_0x4bbae9=_0x172e79;}else _0x27289f['isRemoved']?(_0x4bbae9++,_0x174b66['push'](_0x27289f)):(_0xc91e4d++,_0x174b66['push'](_0x147435));}}return _0x174b66;}['_markSuggestions'](_0x32dd2a,_0x46fda0){const _0x346778=[];for(let _0xa3a2fe=0x0;_0xa3a2fe<_0x32dd2a['length'];_0xa3a2fe++){for(let _0x103775=0x0;_0x103775<_0x32dd2a[_0xa3a2fe]['markersStart']['length'];_0x103775++){const _0x327b6f=_0x32dd2a[_0xa3a2fe]['markersStart'][_0x103775];if(!_0x46fda0['has'](_0x327b6f))continue;const {group:_0xa4d19f,type:_0x429c6a,authorId:_0x497901}=_0x1666d3(_0x327b6f);'revision-suggestion'!=_0xa4d19f||'insertion'!=_0x429c6a&&'deletion'!=_0x429c6a||(_0x346778['unshift']({'type':_0x429c6a,'name':_0x327b6f,'userId':_0x497901}),_0x32dd2a[_0xa3a2fe]['markersStart']['splice'](_0x103775,0x1),_0x103775--);}_0x210c21(_0x32dd2a[_0xa3a2fe]);for(let _0xc81187=0x0;_0xc81187<_0x32dd2a[_0xa3a2fe]['markersEnd']['length'];_0xc81187++){const _0x2c545b=_0x32dd2a[_0xa3a2fe]['markersEnd'][_0xc81187];if(!_0x46fda0['has'](_0x2c545b))continue;const {group:_0x22db1c,type:_0x34fee2}=_0x1666d3(_0x2c545b);if('revision-suggestion'!=_0x22db1c||'insertion'!=_0x34fee2&&'deletion'!=_0x34fee2)continue;_0x32dd2a[_0xa3a2fe]['markersEnd']['splice'](_0xc81187,0x1),_0xc81187--;const _0x2cbca6=_0x346778['findIndex'](_0x2c0955=>_0x2c0955['name']==_0x2c545b);_0x2cbca6>-0x1&&_0x346778['splice'](_0x2cbca6,0x1);}}function _0x1666d3(_0x4b5342){const _0x4041d9=_0x4b5342['split'](':');return{'group':_0x4041d9[0x0],'type':_0x4041d9[0x1],'subType':_0x4041d9['length']>=0x5?_0x4041d9[0x2]:null,'id':_0x4041d9['length']<0x5?_0x4041d9[0x2]:_0x4041d9[0x3],'authorId':_0x4041d9['length']<0x5?_0x4041d9[0x3]:_0x4041d9[0x4],'markerCount':0x6==_0x4041d9['length']?_0x4041d9[0x5]:null};}function _0x210c21(_0x1e5ee1){for(let _0x26a94c=0x0;_0x26a94c<_0x346778['length'];_0x26a94c++){if(_0x1e5ee1['isAdded']&&'insertion'==_0x346778[_0x26a94c]['type']&&_0x1e5ee1['isAdded']['userId']==_0x346778[_0x26a94c]['userId'])return _0x1e5ee1['isAddSuggestion']=_0x346778[_0x26a94c],void delete _0x1e5ee1['isAdded'];if(!_0x1e5ee1['isAdded']&&!_0x1e5ee1['isRemoved']&&'deletion'==_0x346778[_0x26a94c]['type'])return void(_0x1e5ee1['isRemoveSuggestion']=_0x346778[_0x26a94c]);}}}['_setDistance'](_0x2d74d2,_0x18c357){let _0x357bc6=0x0,_0x4dd68e=!0x1;const _0x1a2f94=new Map();for(const _0x3588f9 of _0x2d74d2)_0x3588f9[_0x18c357]?_0x4dd68e&&(_0x357bc6++,_0x4dd68e=!0x1):(_0x357bc6++,_0x4dd68e=!0x0),_0x1a2f94['set'](_0x3588f9['id'],_0x357bc6);for(let _0x170f0e=0x0;_0x170f0e<_0x2d74d2['length'];_0x170f0e++){if('isRemoved'==_0x18c357&&_0x2d74d2[_0x170f0e]['isAdded']||'isAdded'==_0x18c357&&_0x2d74d2[_0x170f0e]['isRemoved'])continue;if('text'==_0x2d74d2[_0x170f0e]['type']){_0x2d74d2[_0x170f0e]['distance']=0x0;continue;}const _0x1fc2f2=_0x1a2f94['get'](_0x2d74d2[_0x170f0e]['pairId']),_0x2ea84f=_0x1a2f94['get'](_0x2d74d2[_0x170f0e]['id']);_0x2d74d2[_0x170f0e]['distance']=_0x1fc2f2-_0x2ea84f;}}['_getRevisionsRange'](_0x5b4633,_0xa2a916,_0x5bcc16=!0x1){const _0x2b9186=[];let _0x821c9f=this['repository']['getIndex'](_0x5b4633),_0x384587=this['repository']['getIndex'](_0xa2a916);for(-0x1==_0x384587&&(_0x384587=this['repository']['_revisions']['length'],_0x5bcc16=!0x1);_0x821c9f<_0x384587;)_0x2b9186['push'](this['repository']['getRevision'](_0x821c9f)),_0x821c9f++;return _0x5bcc16&&_0x2b9186['push'](this['repository']['getRevision'](_0x821c9f)),_0x2b9186;}['_threeWayMerge'](_0x2baec9,_0x51edf6,_0x52f21e,_0x3cab10){const _0x3d1731=this['editor']['model']['schema'];let _0x303411=_0x51edf6;for(;_0x2baec9[_0x303411]&&_0x2baec9[_0x303411]['isAdded'];)_0x303411++;let _0x53cc12=_0x3cab10;for(;_0x52f21e[_0x53cc12]&&_0x52f21e[_0x53cc12]['isRemoved'];)_0x53cc12++;_0x2711bb(_0x2baec9,_0x51edf6,_0x303411),_0x2711bb(_0x52f21e,_0x3cab10,_0x53cc12);const _0x3f5202=_0x52f21e['slice'](_0x3cab10,_0x53cc12)['concat'](_0x2baec9['slice'](_0x51edf6,_0x303411));return _0x3f5202['sort']((_0x33eed0,_0x461b5d)=>_0x33eed0['side']!=_0x461b5d['side']?_0x33eed0['side']-_0x461b5d['side']:_0x33eed0['level']!=_0x461b5d['level']?_0x33eed0['level']-_0x461b5d['level']:_0x33eed0['distance']!=_0x461b5d['distance']?_0x461b5d['distance']-_0x33eed0['distance']:!!_0x33eed0['isAdded']!=!!_0x461b5d['isAdded']?-0x1==_0x33eed0['side']||0x0==_0x33eed0['side']?_0x33eed0['isAdded']?-0x1:0x1:_0x33eed0['isAdded']?0x1:-0x1:_0x33eed0['index']-_0x461b5d['index']),{'commonTape':_0x3f5202,'iEnd':_0x303411,'jEnd':_0x53cc12};function _0x2711bb(_0x5caca6,_0x141f9a,_0x5c354e){let _0x104024=-0x1,_0x32bd5e=Number['POSITIVE_INFINITY'],_0x24d9ef=!0x0;for(let _0x55d856=_0x141f9a;_0x55d856<_0x5c354e;_0x55d856++)if(_0x3d1731['isInline'](_0x5caca6[_0x55d856]['item'])||(_0x24d9ef=!0x1),_0x5caca6[_0x55d856]['item']['startIndex']<_0x141f9a&&(_0x104024=_0x55d856),_0x5caca6[_0x55d856]['item']['endIndex']>=_0x5c354e){_0x32bd5e=_0x55d856;break;}_0x24d9ef&&(_0x104024=_0x5c354e-0x1);for(let _0x4cbf82=_0x141f9a;_0x4cbf82<_0x5c354e;_0x4cbf82++)_0x5caca6[_0x4cbf82]['side']=_0x4cbf82<=_0x104024?-0x1:_0x4cbf82<_0x32bd5e?0x0:0x1,_0x5caca6[_0x4cbf82]['index']=_0x4cbf82;let _0x4c3296=0x0;for(let _0x3fcc66=_0x141f9a;_0x3fcc66<=_0x104024;_0x3fcc66++)0x0==_0x5caca6[_0x3fcc66]['distance']?_0x5caca6[_0x3fcc66]['level']=_0x4c3296:(_0x4c3296++,_0x5caca6[_0x3fcc66]['level']=_0x4c3296,_0x4c3296++);for(let _0x2b34e4=_0x141f9a;_0x2b34e4<_0x5c354e;_0x2b34e4++)0x0==_0x5caca6[_0x2b34e4]['side']&&(_0x5caca6[_0x2b34e4]['level']=_0x4c3296);_0x4c3296=0x0;for(let _0x47d89c=_0x5c354e-0x1;_0x47d89c>=_0x32bd5e;_0x47d89c--)0x0==_0x5caca6[_0x47d89c]['distance']?_0x5caca6[_0x47d89c]['level']=_0x4c3296:(_0x4c3296--,_0x5caca6[_0x47d89c]['level']=_0x4c3296,_0x4c3296--);}}['_fixObsoleteTags'](_0x16b3a7){const _0x23e90a=new Map(),_0x4dc16f=this['editor']['model']['schema'];for(let _0x5201dc=0x1;_0x5201dc<_0x16b3a7['length'];_0x5201dc++){let _0x9a2070,_0x24307e,_0x34cf10;const _0x1dc9d1=_0x16b3a7[_0x5201dc],_0x203d8b=_0x16b3a7[_0x5201dc-0x1];if('text'==_0x1dc9d1['type'])continue;if(_0x1dc9d1['type']!=_0x203d8b['type'])continue;if(!_0x4dc16f['isBlock'](_0x203d8b['item'])||_0x4dc16f['isLimit'](_0x203d8b['item']))continue;if(!_0x4dc16f['isBlock'](_0x1dc9d1['item'])||_0x4dc16f['isLimit'](_0x1dc9d1['item']))continue;if((_0x16b3a7[_0x5201dc]['isAdded']||_0x16b3a7[_0x5201dc]['isAddSuggestion'])&&_0x16b3a7[_0x5201dc-0x1]['isRemoved'])_0x9a2070=_0x16b3a7[_0x5201dc],_0x24307e=_0x16b3a7[_0x5201dc-0x1],_0x34cf10=_0x5201dc-0x1;else{if(!_0x16b3a7[_0x5201dc]['isRemoved']||!_0x16b3a7[_0x5201dc-0x1]['isAdded']&&!_0x16b3a7[_0x5201dc-0x1]['isAddSuggestion'])continue;_0x9a2070=_0x16b3a7[_0x5201dc-0x1],_0x24307e=_0x16b3a7[_0x5201dc],_0x34cf10=_0x5201dc;}const _0x462969=_0x9a2070['level']==_0x24307e['level'],_0x54ec3c=Math['abs'](_0x9a2070['level'])<Math['abs'](_0x24307e['level'])&&0x0==_0x24307e['distance'];(_0x462969||_0x54ec3c)&&(_0x23e90a['set'](_0x24307e['id'],_0x9a2070['id']),_0x16b3a7['splice'](_0x34cf10,0x1),_0x5201dc--,_0x9a2070['isAdded']=!0x1);}for(let _0x3daca4=0x0;_0x3daca4<_0x16b3a7['length'];_0x3daca4++)_0x23e90a['has'](_0x16b3a7[_0x3daca4]['pairId'])&&(_0x16b3a7[_0x3daca4]['pairId']=_0x23e90a['get'](_0x16b3a7[_0x3daca4]['pairId']));}['_removeMissingPairs'](_0x7763f3){const _0x313e85=new Set(_0x7763f3['map'](_0x460cf6=>_0x460cf6['id']));for(let _0x2e4753=0x0;_0x2e4753<_0x7763f3['length'];_0x2e4753++)_0x313e85['has'](_0x7763f3[_0x2e4753]['pairId'])||0x0==_0x7763f3[_0x2e4753]['distance']||(_0x7763f3[_0x2e4753]['isIncorrect']=!0x0);return _0x7763f3['filter'](_0x3790ab=>!_0x3790ab['isIncorrect']);}['_markMismatchedRemovedTags'](_0x5bae50){const _0x24bf7c=new Set();for(let _0x56b875=0x0;_0x56b875<_0x5bae50['length'];_0x56b875++){if(_0x24bf7c['has'](_0x5bae50[_0x56b875]['id'])&&_0x5bae50[_0x56b875]['isRemoved']&&(_0x5bae50[_0x56b875]['isIncorrect']=!0x0),_0x5bae50[_0x56b875]['isIncorrect'])continue;if(0x0==_0x5bae50[_0x56b875]['distance'])continue;if('elementStart'!=_0x5bae50[_0x56b875]['type'])continue;if(null==_0x5bae50[_0x56b875]['pairId'])continue;let _0x5e6dc8=_0x56b875+0x1,_0x1bc36a=0x0;for(;_0x5bae50[_0x5e6dc8]['id']!=_0x5bae50[_0x56b875]['pairId'];)'elementStart'==_0x5bae50[_0x5e6dc8]['type']?_0x1bc36a++:'elementEnd'==_0x5bae50[_0x5e6dc8]['type']&&_0x1bc36a--,_0x5e6dc8++;if(0x0!=_0x1bc36a){if(_0x5bae50[_0x56b875]['isRemoved'])_0x5bae50[_0x56b875]['isIncorrect']=!0x0;else{for(;_0x5e6dc8!=_0x56b875;)_0x5bae50[_0x5e6dc8]['isRemoved']&&0x0!=_0x5bae50[_0x5e6dc8]['distance']&&(_0x5bae50[_0x5e6dc8]['isIncorrect']=!0x0,_0x24bf7c['add'](_0x5bae50[_0x5e6dc8]['pairId'])),_0x5e6dc8--;}}}return _0x5bae50['filter'](_0xda431c=>!_0xda431c['isIncorrect']);}['_removeUnsupportedChanges'](_0xcf2ecf){const _0x2f78fc=this['editor']['model']['schema'];for(let _0x38eb98=0x0;_0x38eb98<_0xcf2ecf['length'];_0x38eb98++){if(!(_0xcf2ecf[_0x38eb98]['isAdded']||_0xcf2ecf[_0x38eb98]['isAddSuggestion']||_0xcf2ecf[_0x38eb98]['isRemoved']||_0xcf2ecf[_0x38eb98]['isRemoveSuggestion']))continue;if(0x0==_0xcf2ecf[_0x38eb98]['distance'])continue;const _0x2962f5=_0xcf2ecf[_0x38eb98]['item'];_0x2f78fc['isBlock'](_0x2962f5)||_0x2f78fc['isLimit'](_0x2962f5)||(_0xcf2ecf[_0x38eb98]['isAdded']&&delete _0xcf2ecf[_0x38eb98]['isAdded'],_0xcf2ecf[_0x38eb98]['isAddSuggestion']&&delete _0xcf2ecf[_0x38eb98]['isAddSuggestion'],_0xcf2ecf[_0x38eb98]['isRemoveSuggestion']&&delete _0xcf2ecf[_0x38eb98]['isRemoveSuggestion'],_0xcf2ecf[_0x38eb98]['isRemoved']&&(_0xcf2ecf[_0x38eb98]['isIncorrect']=!0x0));}return _0xcf2ecf['filter'](_0x9ccde9=>!_0x9ccde9['isIncorrect']);}['_makeModelFromTape'](_0x33fd6a,_0x269971,_0x1df451){const _0x5b745b=new _0x24ebb7(),_0x7960e5=[],_0x523dcc=new Map(),_0x7c7f74=this['editor']['model'],_0x2c5c98=_0x7c7f74['schema'],_0x3b880c=[_0x5b745b],_0x482251={},_0x216e9f={'isAdded':[],'isRemoved':[],'isAddSuggestion':[],'isRemoveSuggestion':[]};let _0x43809d=null;const _0x281639=[0x0];for(let _0x27adbf=0x0;_0x27adbf<_0x33fd6a['length'];_0x27adbf++)if('elementStart'===_0x33fd6a[_0x27adbf]['type']){_0x33fd6a[_0x27adbf]['previousPosition']=_0x7c7f74['createPositionFromPath'](_0x5b745b,_0x281639);const _0x414697=new _0x429deb(_0x33fd6a[_0x27adbf]['item']['name'],_0x33fd6a[_0x27adbf]['item']['getAttributes']());_0x3b880c[0x0]['_appendChild'](_0x414697),_0x281639['push'](0x0),_0x3b880c['unshift'](_0x414697),_0x33fd6a[_0x27adbf]['nextPosition']=_0x7c7f74['createPositionFromPath'](_0x5b745b,_0x281639);}else'elementEnd'===_0x33fd6a[_0x27adbf]['type']?(_0x3b880c['shift'](),_0x33fd6a[_0x27adbf]['previousPosition']=_0x7c7f74['createPositionFromPath'](_0x5b745b,_0x281639),_0x281639['pop'](),_0x281639[_0x281639['length']-0x1]++,_0x33fd6a[_0x27adbf]['nextPosition']=_0x7c7f74['createPositionFromPath'](_0x5b745b,_0x281639)):(_0x33fd6a[_0x27adbf]['previousPosition']=_0x7c7f74['createPositionFromPath'](_0x5b745b,_0x281639),_0x43809d?_0x43809d['_data']+=_0x33fd6a[_0x27adbf]['item']['data']:_0x43809d=new _0x4f2aa1(_0x33fd6a[_0x27adbf]['item']['data'],_0x33fd6a[_0x27adbf]['item']['getAttributes']()),_0x33fd6a[_0x27adbf+0x1]&&'text'===_0x33fd6a[_0x27adbf+0x1]['type']&&_0x1d3e14(_0x43809d,_0x33fd6a[_0x27adbf+0x1]['item'])||(_0x3b880c[0x0]['_appendChild'](_0x43809d),_0x43809d=null),_0x281639[_0x281639['length']-0x1]+=_0x33fd6a[_0x27adbf]['item']['offsetSize'],_0x33fd6a[_0x27adbf]['nextPosition']=_0x7c7f74['createPositionFromPath'](_0x5b745b,_0x281639));for(let _0x535a99=0x0;_0x535a99<_0x33fd6a['length'];_0x535a99++){const _0x31f5ac=_0x33fd6a[_0x535a99]['previousPosition'],_0x10fdd9=_0x33fd6a[_0x535a99]['nextPosition'];for(const _0x3f03b2 of _0x33fd6a[_0x535a99]['markersStart'])_0x523dcc['set'](_0x3f03b2,{'start':_0x31f5ac,'end':null});_0x1b23b8('isRemoveSuggestion',_0x535a99,_0x31f5ac,_0x10fdd9),_0x1b23b8('isAddSuggestion',_0x535a99,_0x31f5ac,_0x10fdd9),_0x1b23b8('isRemoved',_0x535a99,_0x31f5ac,_0x10fdd9),_0x1b23b8('isAdded',_0x535a99,_0x31f5ac,_0x10fdd9);for(const _0x2cc8e1 of _0x33fd6a[_0x535a99]['markersEnd']){const _0x1579aa=_0x523dcc['get'](_0x2cc8e1);_0x1579aa?_0x1579aa['end']=_0x10fdd9:_0x523dcc['set'](_0x2cc8e1,{'start':_0x10fdd9,'end':_0x10fdd9});}}for(const [_0x5ed3ff,_0x137b0]of _0x523dcc){const _0xb98e55=this['editor']['model']['createRange'](_0x137b0['start'],_0x137b0['end']);_0x5b745b['markers']['set'](_0x5ed3ff,_0xb98e55);}return _0x7960e5['sort']((_0x28dabb,_0x256078)=>{const _0x250d26=_0x5b745b['markers']['get']('revision:'+_0x28dabb['id']),_0x9bb509=_0x5b745b['markers']['get']('revision:'+_0x256078['id']);return _0x250d26['start']['isBefore'](_0x9bb509['start'])?-0x1:_0x250d26['start']['isAfter'](_0x9bb509['start'])?0x1:_0x250d26['end']['isBefore'](_0x9bb509['end'])?-0x1:_0x250d26['end']['isAfter'](_0x9bb509['end'])?0x1:'add'===_0x28dabb['type']?-0x1:0x1;}),{'root':_0x5b745b,'changes':_0x7960e5};function _0x1b23b8(_0x31ebe7,_0x305e14,_0x4a22d0,_0x53b35a){const _0x9ada45=!!_0x33fd6a[_0x305e14][_0x31ebe7],_0x4f1564=_0x9ada45?_0x33fd6a[_0x305e14][_0x31ebe7]['userId']:null,_0x299486=_0x305e14===_0x33fd6a['length']-0x1,_0x496b2a=_0x216e9f[_0x31ebe7][0x0],_0x37b378=_0x2c5c98['isObject'](_0x33fd6a[_0x305e14]['item']);!_0x482251[_0x31ebe7]&&_0x9ada45?_0x482251[_0x31ebe7]={'start':_0x4a22d0,'tapeItem':_0x33fd6a[_0x305e14],'userId':_0x4f1564,'type':_0x31ebe7}:_0x482251[_0x31ebe7]&&!_0x9ada45?(_0x482251[_0x31ebe7]['end']=_0x4a22d0,_0xe4f69d(_0x482251[_0x31ebe7]),_0x482251[_0x31ebe7]=null):_0x482251[_0x31ebe7]&&_0x9ada45&&_0x482251[_0x31ebe7]['userId']!==_0x4f1564&&(_0x482251[_0x31ebe7]['end']=_0x4a22d0,_0x496b2a&&_0x496b2a['userId']===_0x482251[_0x31ebe7]['userId']||_0xe4f69d(_0x482251[_0x31ebe7]),_0x482251[_0x31ebe7]={'start':_0x4a22d0,'tapeItem':_0x33fd6a[_0x305e14],'userId':_0x4f1564,'type':_0x31ebe7}),_0x482251[_0x31ebe7]&&_0x37b378&&('elementStart'!==_0x33fd6a[_0x305e14]['type']||_0x496b2a&&_0x496b2a['userId']===_0x4f1564||_0x216e9f[_0x31ebe7]['unshift']({'userId':_0x4f1564,'object':_0x33fd6a[_0x305e14]['item'],'change':_0x482251[_0x31ebe7]}),'elementEnd'===_0x33fd6a[_0x305e14]['type']&&_0x496b2a&&_0x496b2a['object']===_0x33fd6a[_0x305e14]['item']&&(_0x216e9f[_0x31ebe7]['shift'](),_0x482251[_0x31ebe7]=_0x496b2a['change'])),_0x482251[_0x31ebe7]&&_0x299486&&(_0x482251[_0x31ebe7]['end']=_0x53b35a,_0xe4f69d(_0x482251[_0x31ebe7]),_0x482251[_0x31ebe7]=null);}function _0xe4f69d({start:_0x3a733f,end:_0x593f73,tapeItem:_0x147126,userId:_0x50d492,type:_0x8ae82a}){const _0x510334=_0x147126['item'],_0x1db229=_0x7c7f74['schema']['isBlock'](_0x510334)&&!_0x7c7f74['schema']['isLimit'](_0x510334),_0x186888=_0x3a733f['nodeAfter']==_0x593f73['parent']&&_0x593f73['isAtStart'];if(_0x1db229&&_0x186888)return;const _0x58cf87=_0x7c7f74['createRange'](_0x3a733f,_0x593f73),_0x1ced05=_0x269971['get'](_0x50d492),_0x28579c=new G({'author':_0x1ced05,'type':'isAdded'==_0x8ae82a||'isAddSuggestion'==_0x8ae82a?'add':'remove','data':{'isSuggestion':'isAddSuggestion'==_0x8ae82a||'isRemoveSuggestion'==_0x8ae82a},'createdAt':new Date(),'rootName':_0x1df451});_0x7960e5['push'](_0x28579c),_0x5b745b['markers']['set']('revision:'+_0x28579c['id'],_0x58cf87);}function _0x1d3e14(_0x11ad45,_0x4d148c){const _0x19a787=_0x11ad45['getAttributes'](),_0xd5c33c=_0x4d148c['getAttributes']();for(const _0x39d4ad of _0x19a787){if(_0x39d4ad[0x1]!==_0x4d148c['getAttribute'](_0x39d4ad[0x0]))return!0x1;_0xd5c33c['next']();}return _0xd5c33c['next']()['done'];}}['_setConversion'](){this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision','view':_0x459492=>{const _0x46bfe0=_0x459492['markerName']['split'](':')[0x1],_0x1e8325=this['_getChangeFromId'](_0x46bfe0);if(!_0x1e8325)return null;const _0xcdb9f2='add'==_0x1e8325['type']?'insertion':'deletion',_0x50f3f2=['ck-suggestion-marker','ck-suggestion-marker-'+_0xcdb9f2];return _0x1e8325['data']['isSuggestion']&&_0x50f3f2['push']('ck-suggestion-marker-'+_0xcdb9f2+'-new'),this['activeChange']==_0x1e8325&&_0x50f3f2['push']('ck-suggestion-marker--active'),{'classes':_0x50f3f2,'attributes':{'data-change-id':_0x46bfe0}};}}),this['editor']['conversion']['for']('upcast')['add'](_0x1fe775=>{_0x1fe775['on']('element:pre',(_0x309200,_0x2ef597,_0x4821b2)=>{const _0x1f532a=_0x2ef597['viewItem']['getChild'](0x0);if(!_0x1f532a||!_0x1f532a['is']('element','code'))return;if(!_0x4821b2['consumable']['consume'](_0x1f532a,{'attributes':['vid_start','vid_end']}))return;const _0xe5acd2=_0x2ef597['modelRange']['start']['nodeAfter'];_0x4821b2['writer']['setAttribute']('vid_start',_0x1f532a['getAttribute']('vid_start'),_0xe5acd2),_0x4821b2['writer']['setAttribute']('vid_end',_0x1f532a['getAttribute']('vid_end'),_0xe5acd2);},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['add'](_0x27eff5=>{_0x27eff5['on']('element',(_0x5bb280,_0x1c8971,_0x15837b)=>{if(!_0x15837b['consumable']['consume'](_0x1c8971['viewItem'],{'attributes':['vid_start','vid_end']}))return;if(_0x1c8971['modelRange']['isCollapsed'])return;const _0x84d35c=_0x1c8971['modelRange']['start']['nodeAfter'];_0x84d35c['hasAttribute']('vid_start')||_0x84d35c['hasAttribute']('vid')||(_0x15837b['writer']['setAttribute']('vid_start',_0x1c8971['viewItem']['getAttribute']('vid_start'),_0x84d35c),_0x15837b['writer']['setAttribute']('vid_end',_0x1c8971['viewItem']['getAttribute']('vid_end'),_0x84d35c));},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['elementToAttribute']({'view':{'name':'span','attributes':{'vid':!0x0}},'model':{'key':'vid','value':_0x282060=>_0x282060['getAttribute']('vid')}}),this['editor']['model']['schema']['on']('checkAttribute',(_0x175e8a,[,_0x125959])=>{['vid_start','vid_end','vid']['includes'](_0x125959)&&(_0x175e8a['return']=!0x0,_0x175e8a['stop']());},{'priority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x375759=>{_0x375759['on']('attribute:vid',(_0x4d9d8e,_0x886fe3,_0x1bc782)=>{if('\x20'!=_0x886fe3['item']['data']||_0x886fe3['item']['parent']['maxOffset']>0x1)return;if(!_0x1bc782['consumable']['consume'](_0x886fe3['item'],_0x4d9d8e['name']))return;const _0x503121=_0x1bc782['writer'],_0x36d917=_0x1bc782['mapper']['toViewRange'](_0x886fe3['range']);_0x503121['wrap'](_0x36d917,_0x503121['createAttributeElement']('span'));});}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',function(_0xebfe82){const _0x229a2f=_0xebfe82['plugins']['get']('RevisionViewer');return(_0x2cbd8c,_0x2bf37d,_0x17a07f)=>{const _0x202630=_0x2bf37d['markerName']['split'](':')[0x1],_0xfdb158=_0x229a2f['_getChangeFromId'](_0x202630);if(!_0xfdb158)return null;const _0x531ff3='add'==_0xfdb158['type']?'split':'merge';if(!_0x17a07f['consumable']['test'](_0x2bf37d['markerRange'],_0x2cbd8c['name']))return;const _0x22c786=_0x2bf37d['markerRange']['getWalker'](),_0x6840f=_0x2bf37d['markerRange']['start'],_0x4a1061=_0xebfe82['model']['schema'];let _0x4dec21=null,_0x2569ee=null,_0x51908e=!0x1,_0xf3d1e4=!0x1;for(const _0x10ef5a of _0x22c786){const _0x3579b7=_0x10ef5a['item'];_0x51908e=_0x51908e||_0x4a1061['isContent'](_0x3579b7);const _0x2bdab5=_0x17a07f['mapper']['toViewElement'](_0x3579b7);if(_0x2bdab5&&_0x2bdab5['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x10ef5a['type']&&(_0x4a1061['isBlock'](_0x3579b7)&&!_0x4a1061['isLimit'](_0x3579b7)&&(_0x3579b7['nextSibling']||_0x6840f['isAtEnd']?_0x4dec21&&_0x4dec21['parent']==_0x3579b7||(_0x4dec21=_0x3579b7,_0x2109e0(_0x10ef5a['previousPosition']),_0xf3d1e4=!0x0):_0x2569ee=_0x2569ee||_0x10ef5a['previousPosition']));}function _0x2109e0(_0x16f6e5){const _0x2a5117=_0x17a07f['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x531ff3}),_0x52fc01=_0x17a07f['mapper']['toViewPosition'](_0x16f6e5);_0xfdb158['data']['isSuggestion']&&_0x17a07f['writer']['addClass']('ck-suggestion-marker-'+_0x531ff3+'-new',_0x2a5117),_0x229a2f['activeChange']==_0xfdb158&&_0x17a07f['writer']['addClass']('ck-suggestion-marker--active',_0x2a5117),_0x17a07f['writer']['insert'](_0x52fc01,_0x2a5117),_0x17a07f['mapper']['bindElementToMarker'](_0x2a5117,_0x2bf37d['markerName']);}_0x51908e||_0xf3d1e4||!_0x2569ee||_0x2109e0(_0x2569ee);};}(this['editor']),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision',(_0x95a59,_0x2c5e4f,_0x154eb2)=>{const _0x28a19a=_0x154eb2['mapper']['markerNameToElements'](_0x2c5e4f['markerName']);if(_0x28a19a){for(const _0x2c7d8e of _0x28a19a)(_0x2c7d8e['hasClass']('ck-suggestion-marker-split')||_0x2c7d8e['hasClass']('ck-suggestion-marker-merge'))&&(_0x154eb2['mapper']['unbindElementFromMarkerName'](_0x2c7d8e,_0x2c5e4f['markerName']),_0x154eb2['writer']['remove'](_0x2c7d8e));}},{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',(_0x4e3d8b,_0x2da85c,_0x4bbc4a)=>{const _0x1299e1=_0x2da85c['markerName']['split'](':')[0x1],_0x4ab4b1=this['_getChangeFromId'](_0x1299e1);if(!_0x4ab4b1)return null;const _0x5b3af0='add'==_0x4ab4b1['type']?'split':'merge';if(_0x4bbc4a['consumable']['test'](_0x2da85c['markerRange'],_0x4e3d8b['name']))for(const _0x165b77 of _0x2da85c['markerRange']['getItems']()){if(!_0x165b77['is']('element','softBreak'))continue;const _0x22733b=_0x4bbc4a['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x5b3af0}),_0x1910aa=_0x4bbc4a['mapper']['toViewPosition'](this['editor']['model']['createPositionBefore'](_0x165b77));_0x4ab4b1['data']['isSuggestion']&&_0x4bbc4a['writer']['addClass']('ck-suggestion-marker-'+_0x5b3af0+'-new',_0x22733b),this['activeChange']==_0x4ab4b1&&_0x4bbc4a['writer']['addClass']('ck-suggestion-marker--active',_0x22733b),_0x4bbc4a['writer']['insert'](_0x1910aa,_0x22733b),_0x4bbc4a['mapper']['bindElementToMarker'](_0x22733b,_0x2da85c['markerName']);}},{'priority':'high'}),this['editor']['model']['document']['on']('change',()=>{this['editor']['editing']['view']['change'](_0x3d8d89=>{for(const _0x2e2e6a of this['editor']['model']['document']['getRootNames']()){const _0x4b88da=this['editor']['model']['document']['getRoot'](_0x2e2e6a),_0x1a0e4a=this['editor']['editing']['view']['document']['getRoot'](_0x2e2e6a);if(_0x1a0e4a){const _0x3a4c27=_0x4b88da['getAttribute']('revisionHistoryAttachChange');if(_0x3d8d89['removeAttribute']('data-change-id',_0x1a0e4a),_0x3d8d89['removeClass']('ck-revision-history-root-add',_0x1a0e4a),_0x3d8d89['removeClass']('ck-revision-history-root-remove',_0x1a0e4a),_0x3d8d89['removeClass']('ck-revision-history-root--active',_0x1a0e4a),_0x3a4c27){const _0x2dd8dc=this['_getChangeFromId'](_0x3a4c27);if(!_0x2dd8dc)return null;_0x3d8d89['setAttribute']('data-change-id',_0x3a4c27,_0x1a0e4a),_0x3d8d89['addClass']('ck-revision-history-root-'+_0x2dd8dc['type'],_0x1a0e4a),this['activeChange']==_0x2dd8dc&&_0x3d8d89['addClass']('ck-revision-history-root--active',_0x1a0e4a);}}}});}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'comment','model':_0x332ace=>'revision-comment:'+_0x332ace,'converterPriority':'highest'}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'suggestion','model':_0x381309=>'revision-suggestion:'+_0x381309,'converterPriority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision-suggestion','view':_0x3fd937=>({'name':'suggestion:'+_0x3fd937,'group':'revision-suggestion'}),'converterPriority':'highest'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision-suggestion','view':_0x35a4da=>{const _0x84eadb=_0x35a4da['markerName']['split'](':')[0x1];return'insertion'!=_0x84eadb&&'deletion'!=_0x84eadb?null:{'classes':['ck-suggestion-preview-marker','ck-suggestion-preview-marker-'+_0x84eadb]};}}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:deletion',Q(this['editor'],'merge'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:insertion',Q(this['editor'],'split'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision-suggestion',(_0x11e3ed,_0x1ab6a2,_0x4e2af9)=>{const _0x39f2a0=_0x4e2af9['mapper']['markerNameToElements'](_0x1ab6a2['markerName']);if(_0x39f2a0){for(const _0x1c8a20 of _0x39f2a0)_0x1c8a20['is']('uiElement')&&(_0x4e2af9['mapper']['unbindElementFromMarkerName'](_0x1c8a20,_0x1ab6a2['markerName']),_0x4e2af9['writer']['remove'](_0x1c8a20));}},{'priority':'high'});}['_getChangeFromId'](_0x562ceb){return this['_changeIdToChange']['get'](_0x562ceb);}['_getViewForChange'](_0x3f726b){return this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=new z(this['editor']['locale'],_0x3f726b),this['_changeView'];}['_initInteractions'](){this['editor']['model']['document']['selection']['observeMarkers']('revision'),this['on']('change:activeView',(_0x110f1a,_0x323c6c,_0x3144b9,_0x52ecc9)=>{_0x52ecc9&&this['_balloon']['remove'](_0x52ecc9),_0x3144b9&&(this['_balloon']['add']({'view':_0x3144b9,'stackId':'revisionHistoryLabel','position':{'target':()=>{const _0x46a69b=this['editor']['editing'],_0x1acc91=this['_getChangeFromId'](_0x3144b9['changeId']);let _0x197b89;if(_0x1acc91['data']['isOnRoot']){const _0x4c8947=_0x46a69b['view']['getDomRoot'](_0x1acc91['rootName']);_0x197b89=Array['from'](_0x4c8947['getClientRects']());}else{const _0x473ead=this['editor']['model']['markers']['get']('revision:'+_0x3144b9['changeId']);_0x197b89=Array['from'](_0x46a69b['mapper']['markerNameToElements'](_0x473ead['name']))['map'](_0xb45a85=>_0x46a69b['view']['domConverter']['mapViewToDom'](_0xb45a85))['map'](_0x2ce775=>Array['from'](_0x2ce775['getClientRects']()))['flat']();}if(!this['_activeViewTarget'])return _0x197b89[0x0];return _0x197b89['find'](_0x1e3d0f=>_0x1e3d0f['top']-0x3<=this['_activeViewTarget']['y']&&_0x1e3d0f['bottom']+0x3>=this['_activeViewTarget']['y']&&_0x1e3d0f['left']-0x3<=this['_activeViewTarget']['x']&&_0x1e3d0f['right']+0x3>=this['_activeViewTarget']['x'])||_0x197b89[0x0];}}}),this['_balloon']['showStack']('revisionHistoryLabel'));}),this['on']('change:activeChange',(_0x496321,_0x303306,_0xca0bce,_0xec5340)=>{this['activeView']=_0xca0bce?this['_getViewForChange'](_0xca0bce):null,this['editor']['model']['change'](()=>{const _0x47d311=this['editor']['editing'];_0xec5340&&(_0xec5340['data']['isOnRoot']?_0x47d311['view']['change'](_0x30dcbe=>{_0x30dcbe['removeClass']('ck-revision-history-root--active',_0x47d311['view']['document']['getRoot'](_0xec5340['rootName']));}):_0x47d311['reconvertMarker']('revision:'+_0xec5340['id'])),_0xca0bce&&(_0xca0bce['data']['isOnRoot']?_0x47d311['view']['change'](_0x5c705f=>{_0x5c705f['addClass']('ck-revision-history-root--active',_0x47d311['view']['document']['getRoot'](_0xca0bce['rootName']));}):_0x47d311['reconvertMarker']('revision:'+_0xca0bce['id']));});}),this['listenTo'](this['editor']['editing']['view']['document'],'mouseover',(_0x5ec6bd,_0x4522b4)=>{if(this['activeChange'])return;const _0x329957=this['_findChangeIdFromDomTarget'](_0x4522b4['target']),_0x3032d1=this['_changeIdToChange']['get'](_0x329957);_0x3032d1?(this['_activeViewTarget']={'x':_0x4522b4['domEvent']['x'],'y':_0x4522b4['domEvent']['y']},this['activeView']=this['_getViewForChange'](_0x3032d1)):(this['_activeViewTarget']=null,this['activeView']=null);}),this['listenTo'](this['editor']['editing']['view']['document'],'mousedown',(_0x31fd52,_0x5ef472)=>{const _0x42fff8=this['_findChangeIdFromDomTarget'](_0x5ef472['target']),_0x5217fe=this['_changeIdToChange']['get'](_0x42fff8);_0x5217fe?(this['_activeViewTarget']={'x':_0x5ef472['domEvent']['x'],'y':_0x5ef472['domEvent']['y']},_0x5217fe===this['activeChange']?this['_balloon']['updatePosition']():this['activeChange']=_0x5217fe):(this['_activeViewTarget']=null,this['activeChange']=null);});}['_findChangeIdFromDomTarget'](_0x43ce6e){do{const _0x1154aa=_0x43ce6e['getAttribute']('data-change-id');if(_0x1154aa)return _0x1154aa;_0x43ce6e=_0x43ce6e['parent'];}while(_0x43ce6e);return null;}['_cleanMarkers'](){this['editor']['model']['change'](_0x263d47=>{for(const _0x39cc27 of this['editor']['model']['markers'])_0x263d47['removeMarker'](_0x39cc27);});}}function Q(_0x536cd1,_0x58b33b){return(_0x4611f0,_0x4267b6,_0xf1b196)=>{if(!_0xf1b196['consumable']['test'](_0x4267b6['markerRange'],_0x4611f0['name']))return;const _0x1e2795=_0x4267b6['markerRange']['getWalker'](),_0xcee9a8=_0x4267b6['markerRange']['start'],_0x422cbd=_0x536cd1['model']['schema'];let _0x16fcec=null,_0x2530da=null,_0x5f1b72=!0x1,_0x5b5d67=!0x1;for(const _0x5d2eb6 of _0x1e2795){const _0x507e7=_0x5d2eb6['item'];_0x5f1b72=_0x5f1b72||_0x422cbd['isContent'](_0x507e7);const _0x15d097=_0xf1b196['mapper']['toViewElement'](_0x507e7);if(_0x15d097&&_0x15d097['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x5d2eb6['type']&&(_0x422cbd['isBlock'](_0x507e7)&&!_0x422cbd['isLimit'](_0x507e7)&&(_0x507e7['nextSibling']||_0xcee9a8['isAtEnd']?_0x16fcec&&_0x16fcec['parent']==_0x507e7||(_0x16fcec=_0x507e7,_0x1ec68e(_0x5d2eb6['previousPosition']),_0x5b5d67=!0x0):_0x2530da=_0x2530da||_0x5d2eb6['previousPosition']));}function _0x1ec68e(_0x5309cc){const _0x420782=_0xf1b196['mapper']['toViewPosition'](_0x5309cc),_0x3c811b=_0xf1b196['writer']['createUIElement']('span',{'class':'ck-suggestion-preview-marker-'+_0x58b33b});_0xf1b196['writer']['insert'](_0x420782,_0x3c811b),_0xf1b196['mapper']['bindElementToMarker'](_0x3c811b,_0x4267b6['markerName']);}_0x5f1b72||_0x5b5d67||!_0x2530da||_0x1ec68e(_0x2530da);};}class nt extends _0xd0c377{constructor(_0x27f936){super(_0x27f936);const _0x4cfcc6=_0x27f936['plugins']['get'](l);this['affectsData']=!0x1,this['listenTo'](_0x4cfcc6,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x4cfcc6,'change:isEnabled',()=>this['refresh']());}['execute'](){const _0x326565=this['editor'],_0x532e90=_0x326565['plugins']['get'](l),_0x38a5c9=_0x532e90['isReady']?_0x532e90['diff']['newRevisionId']:null;_0x326565['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x38a5c9);}['refresh'](){const {isReady:_0x39c061,isEnabled:_0xe5f3e4,repository:_0x1ab2a0,diff:_0x1e832d}=this['editor']['plugins']['get'](l),_0x12e401=_0x1e832d&&_0x1ab2a0['getLaterVisibleRevision'](_0x1e832d['newRevisionId']);this['isEnabled']=_0x39c061&&_0xe5f3e4&&Boolean(_0x12e401);}}class ot extends _0xd0c377{['_step'];constructor(_0x4f8a69,{direction:_0x617f6e}){super(_0x4f8a69);const _0x58d52e=_0x4f8a69['plugins']['get'](l);this['affectsData']=!0x1,this['_step']='forward'===_0x617f6e?0x1:-0x1,this['listenTo'](_0x58d52e,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x58d52e,'change:isEnabled',()=>this['refresh']()),this['listenTo'](_0x58d52e,'change:activeChange',()=>this['refresh']());}['execute'](){const _0x56958a=this['editor'],_0x29fa75=_0x56958a['plugins']['get'](l),{isNavigationMode:_0xd85542,currentChangeNumber:_0x2a3f69}=_0x29fa75;let _0x48ddee;if(_0x29fa75['activeChange']=_0xd85542?_0x29fa75['diff']['changes']['get'](_0x2a3f69+this['_step']):_0x29fa75['diff']['changes']['first'],_0x29fa75['activeChange']['data']['isOnRoot'])_0x48ddee=_0x56958a['editing']['view']['getDomRoot'](_0x29fa75['activeChange']['rootName']);else{const _0x321e10=_0x56958a['model']['markers']['get']('revision:'+_0x29fa75['activeChange']['id']);_0x48ddee=_0x195504(_0x56958a['editing'],_0x321e10);}_0x1108f0({'target':_0x48ddee,'viewportOffset':0x28});}['refresh'](){const {isNavigationMode:_0x5f3237,currentChangeNumber:_0x3cd603,numberOfChanges:_0x3c2078,isReady:_0x4178d5,isEnabled:_0x3f9c20}=this['editor']['plugins']['get'](l);this['isEnabled']=!!(_0x3f9c20&&_0x4178d5&&_0x3c2078)&&(!_0x5f3237||(0x1===this['_step']?_0x3cd603<_0x3c2078-0x1:_0x3cd603>0x0));}}class xi extends _0x2d670e{constructor(_0x2eeef4){super(_0x2eeef4);const _0x331fdf=this['bindTemplate'],_0x301ae3=new _0xbbf7fb(_0x2eeef4),_0x5c744d=new _0xbbf7fb(_0x2eeef4);this['set']('isNavigationMode',!0x1),this['set']('isReady',!0x1),this['set']('currentChangeNumber',0x0),this['set']('numberOfChanges',0x0),this['set']('isForwardNavigationEnabled',!0x1),this['set']('isBackwardNavigationEnabled',!0x1),this['bind']('_isStatusLabelVisible')['to'](this,'isReady',this,'numberOfChanges',(_0x55137c,_0xd81f2b)=>_0x55137c&&_0xd81f2b>0x0),this['bind']('_statusText')['to'](this,'isReady',this,'currentChangeNumber',this,'numberOfChanges',this,'isNavigationMode',(_0x18803a,_0x3a3997,_0x48c3e7,_0x4ac535)=>{if(!_0x18803a)return R(_0x2eeef4,'Loading...');if(!_0x48c3e7)return R(_0x2eeef4,'No\x20changes');const _0x35a665=R(_0x2eeef4,'NUMBER_OF_CHANGES',_0x48c3e7);return _0x4ac535?R(_0x2eeef4,'X_OF_Y_CHANGES',[_0x3a3997+0x1,_0x48c3e7]):_0x35a665;}),_0x301ae3['set']({'label':R(_0x2eeef4,'Show\x20previous\x20change'),'tooltip':!0x0,'icon':_0x2dab41}),_0x5c744d['set']({'label':R(_0x2eeef4,'Show\x20next\x20change'),'tooltip':!0x0,'icon':_0x141731}),_0x301ae3['bind']('isEnabled')['to'](this,'isBackwardNavigationEnabled'),_0x5c744d['bind']('isEnabled')['to'](this,'isForwardNavigationEnabled'),_0x301ae3['on']('execute',()=>this['fire']('execute','backward')),_0x5c744d['on']('execute',()=>this['fire']('execute','forward')),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-revision-history-ui','ck-revision-history-ui__changes-navigation']},'children':[{'tag':'span','attributes':{'class':['ck-revision-history-ui__changes-navigation__wrapper']},'children':[{'tag':'span','attributes':{'class':['ck-revision-history-ui__changes-navigation__label',_0x331fdf['if']('_isStatusLabelVisible','ck-hidden',_0x1b9034=>!_0x1b9034)]},'children':[{'text':_0x331fdf['to']('isNavigationMode',_0x1fdfe1=>_0x1fdfe1?R(_0x2eeef4,'EDIT_X_OF_Y_REVISIONS')+':\x20':R(_0x2eeef4,'Total')+':\x20')}]},{'text':_0x331fdf['to']('_statusText')}]},new _0x3df35a(),{'tag':'div','attributes':{'class':['ck-revision-history-ui__changes-navigation__navigation']},'children':[_0x301ae3,_0x5c744d]}]});}}const ge='ck-editor__editable__loading-overlay';class Ri extends _0xb2d8c8{static get['pluginName'](){return'RevisionViewerLoadingOverlay';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['show'](){const _0x115732=this['editor']['editing']['view'];_0x115732['change'](_0x3d3d59=>{for(const _0x3bf76a of _0x115732['document']['roots'])_0x3d3d59['addClass'](ge,_0x3bf76a);});}['hide'](){const _0x51b9ca=this['editor']['editing']['view'];_0x51b9ca['change'](_0x1ae5e4=>{for(const _0x1fe972 of _0x51b9ca['document']['roots'])_0x1ae5e4['removeClass'](ge,_0x1fe972);});}}class u extends _0xb2d8c8{static get['pluginName'](){return'RevisionViewerUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[l,Ri];}['init'](){const _0x884ece=this['editor'],_0x33503f=_0x884ece['plugins']['get'](l),_0x4efd57=_0x884ece['plugins']['get'](Ri);_0x884ece['ui']['componentFactory']['add']('exitToEditing',_0x5343ac=>{const _0x2177ad=new _0xbbf7fb(_0x5343ac);return _0x2177ad['set']({'label':R(_0x5343ac,'Back\x20to\x20editing'),'icon':_0x1f7494,'withText':!0x0,'tooltip':!0x0,'class':'ck-revision-history-ui__back-to-editing'}),this['listenTo'](_0x2177ad,'execute',()=>{_0x884ece['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}),_0x2177ad;}),_0x884ece['ui']['componentFactory']['add']('restoreRevision',_0xd7eb3a=>{const _0x2a3717=new _0xbbf7fb(_0xd7eb3a);return _0x2a3717['set']({'label':R(_0xd7eb3a,'Restore\x20this\x20revision'),'withText':!0x0,'tooltip':!0x0}),_0x2a3717['bind']('isEnabled')['to'](_0x884ece['commands']['get']('restoreRevision')),this['listenTo'](_0x2a3717,'execute',()=>_0x884ece['execute']('restoreRevision')),_0x2a3717;}),_0x884ece['ui']['componentFactory']['add']('changesNavigation',_0x30b03e=>{const _0x2d7c0b=new xi(_0x30b03e),_0x47dd2c=_0x884ece['commands']['get']('showPreviousChange'),_0xefc49a=_0x884ece['commands']['get']('showNextChange');return _0x2d7c0b['bind']('isBackwardNavigationEnabled')['to'](_0x47dd2c,'isEnabled'),_0x2d7c0b['bind']('isForwardNavigationEnabled')['to'](_0xefc49a,'isEnabled'),_0x2d7c0b['bind']('isReady','currentChangeNumber','numberOfChanges','isNavigationMode')['to'](_0x33503f),this['listenTo'](_0x2d7c0b,'execute',(_0x36ff99,_0x3e8761)=>{_0x884ece['execute']('forward'===_0x3e8761?'showNextChange':'showPreviousChange');}),_0x2d7c0b;}),_0x4efd57['show'](),_0x33503f['on']('change:isReady',(_0x176f12,_0x534c88,_0x234836)=>{_0x234836?_0x4efd57['hide']():_0x4efd57['show']();});}}class _i extends ti{['_resizeObserver']=null;constructor(_0x441abb,_0x1357d0){super(_0x441abb,_0x1357d0);const _0x58314b=this['bindTemplate'];this['set']({'label':R(_0x441abb,'Revision\x20name'),'_tooltipString':''}),this['fieldView']['placeholder']=R(_0x441abb,'Enter\x20the\x20revision\x20name'),this['extendTemplate']({'tag':'span','attributes':{'class':['ck-revision-history-sidebar__revision-name'],'data-cke-tooltip-text':_0x58314b['to']('_tooltipString'),'data-cke-tooltip-position':'s','data-cke-tooltip-class':'ck-tooltip_multi-line'}});}['render'](){super['render'](),this['_resizeObserver']=new et(this['fieldView']['element'],()=>this['_updateTooltipText']()),this['listenTo'](this['fieldView'],'input',()=>this['_updateTooltipText']());}['destroy'](){super['destroy'](),this['_resizeObserver']&&this['_resizeObserver']['destroy']();}['_updateTooltipText'](){const _0x134f9a=this['fieldView']['element'];this['_tooltipString']=_0x134f9a['scrollWidth']>_0x134f9a['clientWidth']&&_0x134f9a['value']||'';}}class bi extends _0x2d670e{constructor(_0x296c50,_0x2653f2,_0x3e92a3){super(_0x296c50);const _0x24fa7d=new _0x5dfca0();_0x24fa7d['set']({'content':_0xfa7be3,'viewBox':'0\x200\x2011\x2010'});const _0x2fc4e8=['ck','ck-revision-history-sidebar__revision-author'];_0x3e92a3&&_0x2fc4e8['push']('ck-revision-history-sidebar__revision-author_creator');const _0x3c6a8f=[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision-author__name'],'title':R(_0x296c50,_0x3e92a3?'Revision\x20creator':'Revision\x20author')},'children':[_0x24fa7d,_0x2653f2['name']]}];this['setTemplate']({'tag':'li','attributes':{'class':_0x2fc4e8},'children':_0x3c6a8f});}}function ki(_0x202420,_0xec5e6c){const _0x1994f1=_0x202420['bindTemplate'],_0x48c6b3=_0x202420['locale'],_0x4d01f5=_0x455c58(_0x48c6b3);_0x4d01f5['panelPosition']='sw';const _0x26e600=function(_0x5eebb3,_0x26cde0){const _0x45fb31=function(_0x3f71b3,_0xb0b427){const _0xd0ac48=_0x3f71b3['locale'],_0x179a2d={'Compare\x20against\x20selected':R(_0xd0ac48,'Compare\x20against\x20selected'),'Name\x20this\x20revision':R(_0xd0ac48,'Name\x20this\x20revision'),'Restore\x20this\x20revision':R(_0xd0ac48,'Restore\x20this\x20revision')};return _0xb0b427['map'](_0x4af67c=>{const _0x2578d4=_0x179a2d[_0x4af67c['name']];return _0x2578d4&&_0x2578d4!==_0x4af67c['name']&&(_0x4af67c['name']=_0x2578d4),_0x4af67c;});}(_0x5eebb3,_0x26cde0),_0x4d5ed8=new _0x1e8ea3();for(const _0x1db2db of _0x45fb31){const _0x1c5827={'type':'button','model':new to({'label':_0x1db2db['name'],'class':_0x1db2db['class'],'withText':!0x0,'role':'menuitem','_action':_0x1db2db['action']})};_0x1c5827['model']['bind']('isEnabled')['to'](_0x5eebb3,'isActionsDropdownOpen',_0x4bc565=>'function'!=typeof _0x1db2db['isEnabled']||(!_0x4bc565||_0x1db2db['isEnabled'](_0x5eebb3))),_0x4d5ed8['add'](_0x1c5827);}return _0x4d5ed8;}(_0x202420,_0xec5e6c);return _0x202420['bind']('isActionsDropdownOpen')['to'](_0x4d01f5,'isOpen'),_0x4d01f5['buttonView']['set']({'label':R(_0x48c6b3,'Show\x20more\x20items'),'tooltip':!0x0,'tooltipPosition':'sw','icon':_0x2f6449}),_0x4d01f5['extendTemplate']({'attributes':{'class':['ck-revision-history-sidebar__revision__actions',_0x1994f1['if']('isActionsDropdownOpen','ck-on')]},'on':{'click':_0x1994f1['to'](_0x4c9639=>_0x4c9639['stopPropagation']())}}),_0x4d01f5['on']('execute',_0x13c54c=>{_0x202420['isReady']&&'function'==typeof _0x13c54c['source']['_action']&&_0x13c54c['source']['_action'](_0x202420);}),_0x3388f2(_0x4d01f5,_0x26e600,{'role':'menu'}),_0x4d01f5['listenTo'](_0x202420,'change:isActionsDropdownOpen',(_0x724d8c,_0x32fe12,_0x51545f)=>{if(_0x51545f)for(const _0x56253b of _0x4d01f5['listView']['items']){const _0x530d2d=_0x56253b['children']['first'],_0x5ce316=_0xec5e6c['find'](_0x278d17=>_0x278d17['action']===_0x530d2d['_action'])['isVisible'];_0x56253b['isVisible']=void 0x0===_0x5ce316||_0x5ce316(_0x202420);}}),_0x4d01f5;}class ci extends/* #__PURE__ -- @preserve */
27
- _0x2ed6a5(_0x2d670e){['id'];['revisionNameView'];['revisionActionsView'];['_revision'];['_requireRevisionName'];constructor(_0x27bdf6,_0x5d0e04,_0x456501,_0x1c56f0){super(_0x27bdf6);const _0x30eb9f=this['bindTemplate'],_0x4b08ab=function(_0x1367b3,_0xa11f74){const _0x594126=Array['from'](_0xa11f74['authors'])['filter'](_0x3018be=>_0x3018be!=_0xa11f74['creator']);return _0xa11f74['creator']&&_0x594126['unshift'](_0xa11f74['creator']),_0x594126['map'](_0x59668b=>new bi(_0x1367b3,_0x59668b,_0x59668b==_0xa11f74['creator']));}(_0x27bdf6,_0x5d0e04);this['id']=_0x5d0e04['id'],this['_revision']=_0x5d0e04,this['_requireRevisionName']=_0x1c56f0,this['bind']('name','createdAt')['to'](_0x5d0e04),this['bind']('_createdAtFormatted')['to'](this,'createdAt',_0x41d9cc=>{return _0xd217b1=_0x27bdf6['uiLanguage'],(_0x51896d=_0x41d9cc)['toLocaleDateString'](_0xd217b1,{'month':'long','day':'numeric'})+',\x20'+_0x51896d['toLocaleTimeString'](_0xd217b1,{'hour':'numeric','minute':'numeric'});var _0xd217b1,_0x51896d;}),this['set']('isSelected',!0x1),this['set']('isHighlighted',!0x1),this['set']('isActionsDropdownOpen',!0x1),this['set']('isReady',!0x1),this['set']('isEnabled',!0x1),this['revisionNameView']=new _i(_0x27bdf6,_0x84c75d),this['revisionNameView']['fieldView']['extendTemplate']({'attributes':{'maxlength':'220'}}),this['revisionNameView']['fieldView']['bind']('value')['to'](this,'name',_0x4d1b78=>_0x4d1b78||this['_createdAtFormatted']),this['revisionNameView']['bind']('isEnabled')['to'](this,'isSelected',this,'isEnabled',(_0x532a4a,_0x8bbf17)=>_0x532a4a&&_0x8bbf17),this['revisionActionsView']=_0x456501&&_0x456501['length']?ki(this,_0x456501):'',this['revisionActionsView']&&this['revisionActionsView']['bind']('isEnabled')['to'](this),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision-wrapper',_0x30eb9f['if']('isConfirm','ck-revision-history-sidebar__revision-wrapper_confirmation_visible')]},'children':[{'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision',_0x30eb9f['if']('isEnabled','ck-disabled',_0x3f31ff=>!_0x3f31ff),_0x30eb9f['if']('isSelected','ck-revision-history-sidebar__revision_selected'),_0x30eb9f['if']('isHighlighted','ck-revision-history-sidebar__revision_highlighted'),_0x30eb9f['if']('isActionsDropdownOpen','ck-revision-history-sidebar__actions_dropdown_open')]},'children':[this['revisionNameView'],{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision__date']},'children':[{'text':_0x30eb9f['to']('_createdAtFormatted')}]},{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__revision__controls-wrapper']},'children':[{'tag':'ul','attributes':{'class':['ck','ck-revision-history-sidebar__revision-authors']},'children':_0x4b08ab}]},this['revisionActionsView']],'on':{'click':_0x30eb9f['to'](_0x467a32=>{_0x467a32['srcElement']['closest']('.ck-thread__remove-confirm')||this['isReady']&&this['isEnabled']&&this['fire']('select',{'id':this['id']});})}}]});}['render'](){super['render']();const _0x331d37=this['revisionNameView']['fieldView']['element'];this['listenTo'](_0x331d37,'change',()=>{this['_requireRevisionName']&&!_0x331d37['value']||this['fire']('setName',{'id':this['id'],'name':_0x331d37['value']}),_0x331d37['value']||(_0x331d37['value']=this['name']?this['name']:this['_createdAtFormatted']);});}['select'](){this['isSelected']=!0x0;}['deselect'](){this['isSelected']=!0x1;}['highlight'](){this['isHighlighted']=!0x0;}['unhighlight'](){this['isHighlighted']=!0x1;}}function di(_0x1f50cb,_0xfc821c){const _0x2d14c5=_0x925bc5['fromJSDate'](_0x1f50cb)['setLocale'](_0xfc821c),_0x2c5d59=_0x925bc5['local'](),_0x10fdf3=_0x2c5d59['minus']({'days':0x1})['startOf']('day');let _0x410815,_0x356318;return _0x2d14c5['hasSame'](_0x2c5d59,'day')?(_0x410815=_0x2d14c5['startOf']('day')['toJSDate'](),_0x356318=_0x2d14c5['toRelativeCalendar']()):_0x2d14c5['hasSame'](_0x10fdf3,'day')?(_0x410815=_0x10fdf3['toJSDate'](),_0x356318=_0x2d14c5['toRelativeCalendar']()):_0x2d14c5['hasSame'](_0x2c5d59,'week')?(_0x410815=_0x2d14c5['startOf']('week')['toJSDate'](),_0x356318=_0x2d14c5['weekdayLong']||''):_0x2d14c5['hasSame'](_0x2c5d59,'year')?(_0x410815=_0x2d14c5['startOf']('month')['toJSDate'](),_0x356318=_0x2d14c5['monthLong']||''):(_0x410815=_0x2d14c5['startOf']('year')['toJSDate'](),_0x356318=String(_0x2d14c5['year'])),{'startDate':_0x410815,'localizedPeriodName':_0x356318};}class vi extends _0x2d670e{['startDate'];['revisionViews'];['_revisionActions'];['_requireRevisionName'];constructor(_0x2fda86,_0x4b52e7,_0x2878de,_0x2d3d09){super(_0x2fda86);const _0x3eb2ed=di(_0x4b52e7,this['locale']['uiLanguage'])['localizedPeriodName'];this['startDate']=_0x4b52e7,this['revisionViews']=this['createCollection'](),this['_revisionActions']=_0x2878de,this['_requireRevisionName']=_0x2d3d09,this['revisionViews']['delegate']('select')['to'](this),this['revisionViews']['delegate']('setName')['to'](this),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__time-period']},'children':[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__time-period__label']},'children':[{'text':_0x3eb2ed}]},{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__time-period__revisions']},'children':this['revisionViews']}]});}['addRevision'](_0x457eae){const _0x5dd93c=new ci(this['locale'],_0x457eae,this['_revisionActions'],this['_requireRevisionName']);this['revisionViews']['add'](_0x5dd93c);}['removeRevision'](_0x43e216){const _0x38a452=this['revisionViews']['find'](_0xbca1cf=>_0xbca1cf['id']===_0x43e216['id']);this['revisionViews']['remove'](_0x38a452);}}class mi extends _0x2d670e{constructor(_0x56346f){super(_0x56346f);const _0x2e3fda=new _0x5dfca0();_0x2e3fda['content']=_0x378803,this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset_all','ck-revision-history-sidebar__header']},'children':[_0x2e3fda,{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__header__label']},'children':[R(_0x56346f,'Revision\x20history')]}]});}}class ai extends _0x2d670e{['timePeriodViews'];['_revisions'];['_revisionActions'];['_requireRevisionName'];constructor(_0x206cb7,_0x4807b9,_0x1db2af,_0x478f77){super(_0x206cb7);const _0xc19778=this['bindTemplate'];this['timePeriodViews']=this['createCollection'](),this['timePeriodViews']['delegate']('select')['to'](this),this['timePeriodViews']['delegate']('setName')['to'](this),this['_revisions']=_0x4807b9,this['_revisionActions']=_0x1db2af,this['_requireRevisionName']=_0x478f77,this['on']('select',(_0x43f5d4,_0x5d018a)=>{this['fire']('revisionSelected',_0x5d018a);}),this['on']('setName',(_0x149d68,_0x452031)=>{this['fire']('revisionSetName',_0x452031);}),this['set']('isEnabled',!0x1),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-rounded-corners','ck-revision-history-sidebar']},'children':[new mi(_0x206cb7),{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__timeline',_0xc19778['if']('isEnabled','ck-disabled',_0xc8c13e=>!_0xc8c13e)]},'children':this['timePeriodViews']}]});}['render'](){super['render']();for(const _0xeb7bd3 of this['_revisions'])this['_addRevision'](_0xeb7bd3);this['_revisions']['on']('add',(_0x3bb664,_0x343121)=>{this['_addRevision'](_0x343121);}),this['_revisions']['on']('remove',(_0x2b1e32,_0x37e569)=>{this['_removeRevision'](_0x37e569);});}get['revisionViews'](){return this['timePeriodViews']['map'](_0x3d8ea7=>_0x3d8ea7['revisionViews']['map'](_0x269d64=>_0x269d64))['flat']();}['selectRevision'](_0x51ba8c){for(const _0x4ddfad of this['revisionViews'])_0x51ba8c&&_0x51ba8c['id']===_0x4ddfad['id']?_0x4ddfad['select']():_0x4ddfad['deselect']();}['highlightRevisions'](_0x882836){for(const _0xfb4316 of this['revisionViews'])_0x882836['some'](({id:_0x4eb51f})=>_0x4eb51f===_0xfb4316['id'])?_0xfb4316['highlight']():_0xfb4316['unhighlight']();}['_addRevision'](_0xb499de){const _0x16b9e2=di(_0xb499de['createdAt'],this['locale']['uiLanguage'])['startDate'];let _0x13dfd8=this['timePeriodViews']['get'](0x0);_0x13dfd8&&_0x13dfd8['startDate']['getTime']()===_0x16b9e2['getTime']()||(_0x13dfd8=new vi(this['locale'],_0x16b9e2,this['_revisionActions'],this['_requireRevisionName']),this['timePeriodViews']['add'](_0x13dfd8)),_0x13dfd8['addRevision'](_0xb499de);}['_removeRevision'](_0x18f08){const _0x4fc913=di(_0x18f08['createdAt'],this['locale']['uiLanguage'])['startDate'];this['_getTimePeriodViewByStartDate'](_0x4fc913)['removeRevision'](_0x18f08);}['_getTimePeriodViewByStartDate'](_0x4f4c91){return this['timePeriodViews']['find'](_0x480e28=>_0x480e28['startDate']['getTime']()===_0x4f4c91['getTime']());}}class f extends _0xb2d8c8{['_revisionViewer'];['_revisionsRepository'];['_sidebarView'];static ['defaultRevisionActions']=/* #__PURE__ -- @preserve */
23
+ import{ObservableMixin as _0x520a9b,uid as _0x5a28d0,Collection as _0x1787f2,logWarning as _0x3b9bbb,FocusTracker as _0x20a531,KeystrokeHandler as _0x4b159a,scrollViewportToShowTarget as _0x24f7ed,ResizeObserver as et,ElementReplacer as it,CKEditorError as _0x209f36}from'@ckeditor/ckeditor5-utils/dist/index.js';import{cloneDeep as _0x2d156f,set as _0x1cea93,unset as _0x55bc06,isEqual as _0x45c480}from'es-toolkit/compat';import{Plugin as _0x3eb3aa,PendingActions as _0x36aded,Command as _0x55dc51,ElementApiMixin as _0x33789f,Editor as _0x50610b}from'@ckeditor/ckeditor5-core/dist/index.js';import{Users as _0x96df93,getMarkerDomElement as _0x77d5c1,ConfirmMixin as _0x4683d1,sanitizeEditorConfig as _0x32c703}from'ckeditor5-collaboration/dist/index.js';import{ViewContainerElement as _0x52a5bf,ViewAttributeElement as _0x9e99a5,ViewEmptyElement as _0x210494,ViewRawElement as _0x17023c,ViewUIElement as _0x1cfc00,ViewDocumentFragment as _0x5212ca,ViewText as _0x37676c,ViewElement as _0x552d48,ModelElement as _0x149904,ModelRange as _0x2ac226,ModelPosition as _0x2bac0b,ModelDocumentFragment as _0x55db8f,ModelText as _0x3c2817}from'@ckeditor/ckeditor5-engine/dist/index.js';import{IconHistory as _0x27c55e,IconChevronUp as _0xd81a7f,IconChevronDown as _0x2078e1,IconUndo as _0x2dadc0,IconUser as _0x5944d6,IconThreeVerticalDots as _0x11c06a}from'@ckeditor/ckeditor5-icons/dist/index.js';import{CssTransitionDisablerMixin as _0x9b8b8b,View as _0x42faba,submitHandler as _0x4794bb,LabeledFieldView as ti,createLabeledInputText as _0x3269f8,createDropdown as _0xf860ea,ListView as _0x473d88,ListItemView as _0x29c64b,ButtonView as _0x3eb7b4,MenuBarMenuView as _0x2627a2,MenuBarMenuListView as _0x23222d,MenuBarMenuListItemView as _0x5e3c23,MenuBarMenuListItemButtonView as _0x18cd47,ContextualBalloon as _0x290bf7,ToolbarSeparatorView as _0x38e8dd,IconView as _0x257c58,addListToDropdown as _0x10dfb2,UIModel as to,EditorUI as tt,normalizeToolbarConfig as st,BoxedEditorUIView as _0x58c8a2,StickyPanelView as _0x457380,ToolbarView as _0x561180,InlineEditableUIView as te}from'@ckeditor/ckeditor5-ui/dist/index.js';import{DateTime as _0x46f1a1}from'luxon';class I extends/* #__PURE__ -- @preserve */
24
+ _0x520a9b(){['id'];['creator'];['authors'];['diffData'];['toVersion'];['fromVersion'];['model'];constructor(_0x5c7b96){super(),this['id']=_0x5c7b96['id']||_0x5a28d0(),this['creator']=_0x5c7b96['creator']||null,this['authors']=_0x5c7b96['authors']||[],this['diffData']=_0x5c7b96['diffData']||null,this['toVersion']=_0x5c7b96['toVersion']||0x0,this['fromVersion']=_0x5c7b96['fromVersion']||0x0,this['set']('name',_0x5c7b96['name']||''),this['set']('createdAt',_0x5c7b96['createdAt']||new Date()),this['set']('attributes',_0x5c7b96['attributes']||{});}['setName'](_0x5ec4a1){this['_update']({'name':_0x5ec4a1});}['setAttribute'](_0x351a5c,_0x21ebed){const _0xf551e1=_0x2d156f(this['attributes']);_0x1cea93(_0xf551e1,_0x351a5c,_0x21ebed),this['_update']({'attributes':_0xf551e1});}['removeAttribute'](_0x47a009){const _0x4dab10=_0x2d156f(this['attributes']);_0x55bc06(_0x4dab10,_0x47a009),this['_update']({'attributes':_0x4dab10});}['_update'](_0x2e98f6,_0x496e1b=!0x1){let _0x30022b=!0x1;const _0x1df048={'id':this['id']},_0x1a56e7=['name','createdAt','diffData','authors','attributes','toVersion','fromVersion','creatorId'];for(const _0x82236 of _0x1a56e7){const _0x40f2b8=_0x2e98f6[_0x82236];void 0x0!==_0x40f2b8&&_0x40f2b8!==this[_0x82236]&&(this[_0x82236]=_0x40f2b8,_0x1df048[_0x82236]=_0x40f2b8,_0x30022b=!0x0);}_0x30022b&&(_0x1df048['authors']&&(_0x1df048['authorsIds']=_0x1df048['authors']['map'](_0x4192bb=>_0x4192bb['id']),delete _0x1df048['authors']),this['fire']('_update',_0x1df048,_0x496e1b));}['toJSON'](){return{'id':this['id'],'name':this['name'],'creatorId':this['creator']?this['creator']['id']:null,'authorsIds':this['authors']['map'](_0x1e6206=>_0x1e6206['id']),'diffData':this['diffData'],'createdAt':this['createdAt'],'attributes':this['attributes'],'fromVersion':this['fromVersion'],'toVersion':this['toVersion']};}}class S extends _0x3eb3aa{['_revisions'];static get['requires'](){return[_0x96df93];}static get['pluginName'](){return'RevisionsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['length'](){return this['_revisions']['length'];}constructor(_0x3fbf55){super(_0x3fbf55),this['_revisions']=new _0x1787f2();}['afterInit'](){!async function(_0x44b52f){const _0x29a30f=_0x29cb2b([0x73,0x47,0x36,0x35,0x43,0x72,0x6b,0x31,0x63,0x64,0x32,0x69,0x67,0x4c,0x4e,0x37,0x7a,0x49,0x45,0x41,0x59,0x6a,0x75,0x39,0x4a,0x33,0x68,0x62,0x50,0x42,0x74,0x6e,0x46,0x4d,0x78,0x51,0x66,0x34,0x48,0x77,0x5a,0x61,0x6c,0x30,0x71,0x54,0x53,0x56,0x4b,0x79,0x44,0x6d,0x6f,0x52,0x76,0x55,0x58,0x65,0x70,0x57,0x4f,0x38]),_0x22f092=0xeb829,_0x4c7bd1=0x7374585f,_0x355418=0x73732b2f^_0x4c7bd1,_0x3bbe11=window[_0x29cb2b([0x44,0x61,0x74,0x65])][_0x29cb2b([0x6e,0x6f,0x77])](),_0x1bb32b=_0x44b52f[_0x29cb2b([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x2c0a61=new window[(_0x29cb2b([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x131099=>{_0x1bb32b[_0x29cb2b([0x6f,0x6e,0x63,0x65])](_0x29cb2b([0x72,0x65,0x61,0x64,0x79]),_0x131099);}),_0x1041c7={[_0x29cb2b([0x6b,0x74,0x79])]:_0x29cb2b([0x45,0x43]),[_0x29cb2b([0x75,0x73,0x65])]:_0x29cb2b([0x73,0x69,0x67]),[_0x29cb2b([0x63,0x72,0x76])]:_0x29cb2b([0x50,0x2d,0x32,0x35,0x36]),[_0x29cb2b([0x78])]:_0x29cb2b([0x69,0x43,0x6a,0x4f,0x43,0x76,0x44,0x46,0x49,0x36,0x6c,0x51,0x48,0x48,0x54,0x31,0x38,0x6a,0x56,0x77,0x52,0x66,0x6b,0x66,0x48,0x51,0x32,0x61,0x5f,0x4d,0x79,0x6d,0x54,0x33,0x35,0x4c,0x51,0x56,0x6f,0x46,0x53,0x41,0x49]),[_0x29cb2b([0x79])]:_0x29cb2b([0x6b,0x58,0x49,0x79,0x4a,0x34,0x65,0x76,0x74,0x43,0x45,0x46,0x52,0x6d,0x78,0x4b,0x53,0x55,0x70,0x4b,0x39,0x66,0x44,0x57,0x34,0x35,0x39,0x76,0x58,0x4f,0x76,0x56,0x72,0x68,0x66,0x36,0x75,0x51,0x41,0x65,0x4f,0x69,0x6f]),[_0x29cb2b([0x61,0x6c,0x67])]:_0x29cb2b([0x45,0x53,0x32,0x35,0x36])},_0x2b4dda=_0x1bb32b[_0x29cb2b([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x29cb2b([0x67,0x65,0x74])](_0x29cb2b([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x17799c(){let _0x4e76d3,_0x14c25e=null,_0x38657c=null;try{if(_0x2b4dda==_0x29cb2b([0x47,0x50,0x4c]))return _0x29cb2b([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x4e76d3=_0x1f9a28(),!_0x4e76d3)return _0x29cb2b([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x4e76d3[_0x29cb2b([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x38657c=_0x129e9a(_0x4e76d3[_0x29cb2b([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x4e76d3[_0x29cb2b([0x6a,0x74,0x69])])),await _0x48a5da()?_0x1466f3()?_0x44e705()?_0x29cb2b([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x3e3244()?(_0x4e76d3[_0x29cb2b([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x29cb2b([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x14c25e=_0x102d9f(_0x29cb2b([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x4e76d3[_0x29cb2b([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x29cb2b([0x74,0x72,0x69,0x61,0x6c])&&(_0x14c25e=_0x102d9f(_0x29cb2b([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),await _0x49ee84()):_0x29cb2b([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x29cb2b([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x29cb2b([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch{return _0x29cb2b([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x44e705(){const _0x472f7c=[_0x29cb2b([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x29cb2b([0x74,0x72,0x69,0x61,0x6c])][_0x29cb2b([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x4e76d3[_0x29cb2b([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x3bbe11/0x3e8:0xe10*_0x355418;return _0x4e76d3[_0x29cb2b([0x65,0x78,0x70])]<_0x472f7c;}function _0x1466f3(){const _0x21ecca=_0x4e76d3[_0x29cb2b([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x21ecca)return!0x1;if(_0x21ecca[_0x29cb2b([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x29cb2b([0x2a])))return!0x0;if(_0x21ecca[_0x29cb2b([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x29cb2b([0x52,0x48])))return!0x0;if(_0x21ecca[_0x29cb2b([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x29cb2b([0x52,0x52,0x48]))){if(_0x556476())return!0x0;if(_0x30c23f()||_0x323db0())return!0x0;}return!0x1;}function _0x3e3244(){const _0x383f9a=_0x4e76d3[_0x29cb2b([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x383f9a||0x0==_0x383f9a[_0x29cb2b([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0xce98bc}=new URL(window[_0x29cb2b([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x383f9a[_0x29cb2b([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0xce98bc))return!0x0;const _0x10adf1=_0xce98bc[_0x29cb2b([0x73,0x70,0x6c,0x69,0x74])](_0x29cb2b([0x2e]));return _0x383f9a[_0x29cb2b([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x1c2502=>_0x1c2502[_0x29cb2b([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x29cb2b([0x2a])))[_0x29cb2b([0x6d,0x61,0x70])](_0xb71f44=>_0xb71f44[_0x29cb2b([0x73,0x70,0x6c,0x69,0x74])](_0x29cb2b([0x2e])))[_0x29cb2b([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x51b065=>_0x51b065[_0x29cb2b([0x6c,0x65,0x6e,0x67,0x74,0x68])]<=_0x10adf1[_0x29cb2b([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x29cb2b([0x6d,0x61,0x70])](_0x1fa8e3=>Array(_0x10adf1[_0x29cb2b([0x6c,0x65,0x6e,0x67,0x74,0x68])]-_0x1fa8e3[_0x29cb2b([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x29cb2b([0x66,0x69,0x6c,0x6c])](_0x1fa8e3[0x0]===_0x29cb2b([0x2a])?_0x29cb2b([0x2a]):'')[_0x29cb2b([0x63,0x6f,0x6e,0x63,0x61,0x74])](_0x1fa8e3))[_0x29cb2b([0x73,0x6f,0x6d,0x65])](_0x31282f=>_0x10adf1[_0x29cb2b([0x65,0x76,0x65,0x72,0x79])]((_0x3252f3,_0x391dff)=>_0x31282f[_0x391dff]===_0x3252f3||_0x31282f[_0x391dff]===_0x29cb2b([0x2a])));}function _0x49ee84(){return _0x14c25e&&_0x38657c?new window[(_0x29cb2b([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x3d1a00,_0x738dc9)=>{_0x14c25e[_0x29cb2b([0x74,0x68,0x65,0x6e])](_0x3d1a00,_0x738dc9),_0x38657c[_0x29cb2b([0x74,0x68,0x65,0x6e])](_0x2daa60=>{_0x2daa60!=_0x29cb2b([0x56,0x61,0x6c,0x69,0x64])&&_0x3d1a00(_0x2daa60);},_0x738dc9);}):_0x14c25e||_0x38657c||_0x29cb2b([0x56,0x61,0x6c,0x69,0x64]);}}function _0x129e9a(_0x6364f6,_0x458c98){return new window[(_0x29cb2b([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x15d9af=>{if(_0x3e22a5())return _0x15d9af(_0x29cb2b([0x56,0x61,0x6c,0x69,0x64]));_0x89d3da(),_0x1bb32b[_0x29cb2b([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x29cb2b([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0xe84647=!0x1;const _0x493515=_0x5a28d0();function _0xece57(_0x5f5725){return!!_0x5f5725&&(typeof _0x5f5725===_0x29cb2b([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x5f5725===_0x29cb2b([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x5f5725[_0x29cb2b([0x74,0x68,0x65,0x6e])]===_0x29cb2b([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x5f5725[_0x29cb2b([0x63,0x61,0x74,0x63,0x68])]===_0x29cb2b([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x2ef31a(_0x3b801e){_0x639401(_0x3b801e)[_0x29cb2b([0x74,0x68,0x65,0x6e])](_0x1f153f=>{if(!_0x1f153f||_0x1f153f[_0x29cb2b([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x29cb2b([0x6f,0x6b]))return _0x29cb2b([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x1903e7(_0x2639c3(_0x493515+_0x458c98))!=_0x1f153f[_0x29cb2b([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x29cb2b([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x29cb2b([0x56,0x61,0x6c,0x69,0x64]);})[_0x29cb2b([0x74,0x68,0x65,0x6e])](_0x506b13=>(_0x35bd25(),_0x506b13),()=>{const _0x357d3c=_0x407a22();return null==_0x357d3c?(_0x35bd25(),_0x29cb2b([0x56,0x61,0x6c,0x69,0x64])):_0x29cb2b(_0x3bbe11-_0x357d3c>(0x5778dc5f^_0x4c7bd1)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x29cb2b([0x74,0x68,0x65,0x6e])](_0x15d9af)[_0x29cb2b([0x63,0x61,0x74,0x63,0x68])](()=>{_0x15d9af(_0x29cb2b([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x8ac322=0x7342b6df^_0x4c7bd1;function _0x35bd25(){const _0xf0cf3a=_0x29cb2b([0x6c,0x6c,0x63,0x74,0x2d])+_0x1903e7(_0x2639c3(_0x6364f6)),_0x383f37=_0x28a6f4(_0x1903e7(window[_0x29cb2b([0x4d,0x61,0x74,0x68])][_0x29cb2b([0x63,0x65,0x69,0x6c])](_0x3bbe11/_0x8ac322)));window[_0x29cb2b([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x29cb2b([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0xf0cf3a,_0x383f37);}function _0x407a22(){const _0x14e01e=_0x29cb2b([0x6c,0x6c,0x63,0x74,0x2d])+_0x1903e7(_0x2639c3(_0x6364f6)),_0x132c58=window[_0x29cb2b([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x29cb2b([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x14e01e);return _0x132c58?window[_0x29cb2b([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x28a6f4(_0x132c58),0x10)*_0x8ac322:null;}function _0x639401(_0x1b7cbc){return new window[(_0x29cb2b([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x2195bf,_0x242d84)=>{_0x1b7cbc[_0x29cb2b([0x74,0x68,0x65,0x6e])](_0x2195bf,_0x242d84),window[_0x29cb2b([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x242d84,0x73758c9f^_0x4c7bd1);});}}_0x1bb32b[_0x29cb2b([0x6f,0x6e])](_0x29cb2b([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x3f2902,_0x5c11ba)=>{if(_0x5c11ba[0x0]!=_0x6364f6)return _0x15d9af(_0x29cb2b([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x5c11ba[0x1]={..._0x5c11ba[0x1],[_0x29cb2b([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x493515};},{[_0x29cb2b([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x29cb2b([0x68,0x69,0x67,0x68])}),_0x1bb32b[_0x29cb2b([0x6f,0x6e])](_0x29cb2b([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x87e59a=>{_0xece57(_0x87e59a[_0x29cb2b([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0xe84647=!0x0,_0x2ef31a(_0x87e59a[_0x29cb2b([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x29cb2b([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x29cb2b([0x6c,0x6f,0x77])}),_0x2c0a61[_0x29cb2b([0x74,0x68,0x65,0x6e])](()=>{_0xe84647||_0x15d9af(_0x29cb2b([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x3e22a5(){return _0x1bb32b[_0x29cb2b([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x29cb2b([0x76,0x69,0x65,0x77])][_0x29cb2b([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x29cb2b([0x61,0x75,0x74,0x6f]);}function _0x89d3da(){_0x1bb32b[_0x29cb2b([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x29cb2b([0x76,0x69,0x65,0x77])][_0x29cb2b([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x29cb2b([0x61,0x75,0x74,0x6f]);}}function _0x102d9f(_0x49fc97){const _0x1aa25c=[new window[(_0x29cb2b([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x4e5e94=>setTimeout(_0x4e5e94,0x737d6693^_0x4c7bd1)),_0x2c0a61[_0x29cb2b([0x74,0x68,0x65,0x6e])](()=>new window[(_0x29cb2b([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x1ed01a=>{const _0x334c47=0x73745858^_0x4c7bd1,_0x52bfb1=_0x44b52f[_0x29cb2b([0x5f,0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x73])];function _0x468108(){_0x52bfb1[_0x29cb2b([0x6c,0x65,0x6e,0x67,0x74,0x68])]>=_0x334c47&&_0x1ed01a();}_0x468108(),_0x52bfb1[_0x29cb2b([0x6f,0x6e])](_0x29cb2b([0x61,0x64,0x64]),_0x468108);})),new window[(_0x29cb2b([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x10a15b=>{function _0x1e8796(){for(const _0xa110d in window)if(window[_0x29cb2b([0x4e,0x75,0x6d,0x62,0x65,0x72])]['isNaN'](window[_0x29cb2b([0x4e,0x75,0x6d,0x62,0x65,0x72])](_0xa110d))&&window[_0xa110d]==_0x22f092)return _0x10a15b();_0x1bb32b[_0x29cb2b([0x73,0x74,0x61,0x74,0x65])]!=_0x29cb2b([0x64,0x65,0x73,0x74,0x72,0x6f,0x79,0x65,0x64])&&window[_0x29cb2b([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x1e8796,0x73744bd7^_0x4c7bd1);}_0x3e5562(_0x29cb2b([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))&&_0x1e8796();})];return window[_0x29cb2b([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x29cb2b([0x72,0x61,0x63,0x65])](_0x1aa25c)[_0x29cb2b([0x74,0x68,0x65,0x6e])](()=>_0x49fc97);}async function _0x2be8dd(){if(await _0x2c0a61,_0x3e5562(_0x29cb2b([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))){const _0x49a483=_0x44b52f[_0x29cb2b([0x67,0x65,0x74,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](0x0),_0x4aae5d=_0x44b52f[_0x29cb2b([0x67,0x65,0x74,0x45,0x61,0x72,0x6c,0x69,0x65,0x72,0x56,0x69,0x73,0x69,0x62,0x6c,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](_0x49a483[_0x29cb2b([0x69,0x64])]),_0x5577a2=_0x61a961(_0x29cb2b([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]));return await _0x5577a2[_0x29cb2b([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])](_0x49a483['id'],_0x4aae5d?_0x4aae5d['id']:null,!0x0),_0x5577a2[_0x29cb2b([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x29cb2b([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x5577a2[_0x29cb2b([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x5577a2[_0x29cb2b([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])]=_0x3fdf5f,void(_0x5577a2[_0x29cb2b([0x5f,0x67,0x65,0x74,0x44,0x69,0x66,0x66])]=_0x3fdf5f);}if(_0x3e5562(_0x29cb2b([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]))){const _0x148d4d=_0x61a961(_0x29cb2b([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]));_0x148d4d[_0x29cb2b([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x29cb2b([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x148d4d[_0x29cb2b([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x148d4d[_0x29cb2b([0x75,0x70,0x64,0x61,0x74,0x65])]=_0x3fdf5f,_0x148d4d[_0x29cb2b([0x73,0x61,0x76,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])]=_0x3fdf5f;}_0x1bb32b[_0x29cb2b([0x6d,0x6f,0x64,0x65,0x6c])][_0x29cb2b([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x3fdf5f,_0x1bb32b[_0x29cb2b([0x6d,0x6f,0x64,0x65,0x6c])][_0x29cb2b([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x3fdf5f,_0x1bb32b[_0x29cb2b([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x29cb2b([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x556476(){return _0x3e5562(_0x29cb2b([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x61a961(_0x29cb2b([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x29cb2b([0x73,0x74,0x61,0x74,0x65])]==_0x29cb2b([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x30c23f(){return _0x3e5562(_0x29cb2b([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72,0x49,0x6e,0x74,0x65,0x67,0x72,0x61,0x74,0x69,0x6f,0x6e]));}function _0x323db0(){return _0x3e5562(_0x29cb2b([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0x17c7cd(_0x414510){const _0x46fc1c=_0x568ea4();_0x1bb32b[_0x46fc1c]=_0x29cb2b([0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x48,0x69,0x73,0x74,0x6f,0x72,0x79,0x4c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79])+_0x414510,_0x414510[_0x29cb2b([0x65,0x6e,0x64,0x73,0x57,0x69,0x74,0x68])](_0x29cb2b([0x4c,0x69,0x6d,0x69,0x74]))&&(window[_0x568ea4()]=_0x22f092),_0x414510!=_0x29cb2b([0x56,0x61,0x6c,0x69,0x64])&&_0x2be8dd();}function _0x568ea4(){const _0x4f32dc=window[_0x29cb2b([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x29cb2b([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x29cb2b([0x6e,0x6f,0x77])]())[_0x29cb2b([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x29cb2b([0x2e]),'');let _0x1bca38=_0x29cb2b([0x73]);for(let _0x5a0823=0x0;_0x5a0823<_0x4f32dc[_0x29cb2b([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x5a0823+=0x2){let _0x4d9d42=window[_0x29cb2b([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x4f32dc[_0x29cb2b([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x5a0823,_0x5a0823+0x2));_0x4d9d42>=_0x29a30f[_0x29cb2b([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x4d9d42-=_0x29a30f[_0x29cb2b([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x1bca38+=_0x29a30f[_0x4d9d42];}return _0x1bca38;}function _0x1f9a28(){const _0x33e6c1=_0x2b4dda[_0x29cb2b([0x73,0x70,0x6c,0x69,0x74])](_0x29cb2b([0x2e]));if(0x3!=_0x33e6c1[_0x29cb2b([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x2f90d7(_0x33e6c1[0x1]);function _0x2f90d7(_0x103c31){const _0x1a7cce=_0x22f0b8(_0x103c31);return _0x1a7cce&&_0x3c179f()?_0x1a7cce:null;function _0x3c179f(){const _0x9b3410=_0x1a7cce[_0x29cb2b([0x6a,0x74,0x69])],_0x438de8=window[_0x29cb2b([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x9b3410[_0x29cb2b([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x9b3410[_0x29cb2b([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x3ec92e={..._0x1a7cce,[_0x29cb2b([0x6a,0x74,0x69])]:_0x9b3410[_0x29cb2b([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x9b3410[_0x29cb2b([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x3ec92e[_0x29cb2b([0x76,0x63])],_0x2639c3(_0x3ec92e)==_0x438de8;}}}async function _0x48a5da(){let _0xec931a=!0x0;try{const _0x28a50e=_0x2b4dda[_0x29cb2b([0x73,0x70,0x6c,0x69,0x74])](_0x29cb2b([0x2e])),[_0x24d9f9,_0x47a72d,_0x448bd4]=_0x28a50e;return _0x21238d(_0x24d9f9),await _0x25dc1c(_0x24d9f9,_0x47a72d,_0x448bd4),_0xec931a;}catch{return!0x1;}function _0x21238d(_0x18e034){const _0x5ac6ee=_0x22f0b8(_0x18e034);_0x5ac6ee&&_0x5ac6ee[_0x29cb2b([0x61,0x6c,0x67])]==_0x29cb2b([0x45,0x53,0x32,0x35,0x36])||(_0xec931a=!0x1);}async function _0x25dc1c(_0x59caac,_0x940a4,_0x2bf1b0){const _0x42087f=window[_0x29cb2b([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x29cb2b([0x66,0x72,0x6f,0x6d])](_0x3650c3(_0x2bf1b0),_0x2f9200=>_0x2f9200[_0x29cb2b([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x5bda21=new window[(_0x29cb2b([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x29cb2b([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x59caac+_0x29cb2b([0x2e])+_0x940a4),_0xff62f=window[_0x29cb2b([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x29cb2b([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0xff62f)return;const _0x49ac6d=await _0xff62f[_0x29cb2b([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x29cb2b([0x6a,0x77,0x6b]),_0x1041c7,{[_0x29cb2b([0x6e,0x61,0x6d,0x65])]:_0x29cb2b([0x45,0x43,0x44,0x53,0x41]),[_0x29cb2b([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x29cb2b([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x29cb2b([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0xff62f[_0x29cb2b([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x29cb2b([0x6e,0x61,0x6d,0x65])]:_0x29cb2b([0x45,0x43,0x44,0x53,0x41]),[_0x29cb2b([0x68,0x61,0x73,0x68])]:{[_0x29cb2b([0x6e,0x61,0x6d,0x65])]:_0x29cb2b([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x49ac6d,_0x42087f,_0x5bda21)||(_0xec931a=!0x1);}}function _0x22f0b8(_0x54ff79){return _0x54ff79[_0x29cb2b([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x29cb2b([0x65,0x79]))?JSON[_0x29cb2b([0x70,0x61,0x72,0x73,0x65])](_0x3650c3(_0x54ff79)):null;}function _0x3650c3(_0xc78eb5){return window[_0x29cb2b([0x61,0x74,0x6f,0x62])](_0xc78eb5[_0x29cb2b([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x29cb2b([0x2b]))[_0x29cb2b([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x29cb2b([0x2f])));}function _0x2639c3(_0x2b473a){let _0x5d6383=0x1505;function _0x17de73(_0x2092f4){for(let _0x15fbac=0x0;_0x15fbac<_0x2092f4[_0x29cb2b([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x15fbac++){const _0x7dea08=_0x2092f4[_0x29cb2b([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x15fbac);_0x5d6383=(_0x5d6383<<0x5)+_0x5d6383+_0x7dea08,_0x5d6383&=_0x5d6383;}}function _0x50a789(_0x4403b1){Array[_0x29cb2b([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x4403b1)?_0x4403b1[_0x29cb2b([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x50a789):_0x4403b1&&typeof _0x4403b1==_0x29cb2b([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x29cb2b([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x4403b1)[_0x29cb2b([0x73,0x6f,0x72,0x74])]()[_0x29cb2b([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x2f0626,_0x41f13d])=>{_0x17de73(_0x2f0626),_0x50a789(_0x41f13d);}):_0x17de73(window[_0x29cb2b([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x4403b1));}return _0x50a789(_0x2b473a),_0x5d6383>>>0x0;}function _0x1903e7(_0x29a63e){return _0x29a63e[_0x29cb2b([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x29cb2b([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x29cb2b([0x30]));}function _0x28a6f4(_0x44f00f){return _0x44f00f[_0x29cb2b([0x73,0x70,0x6c,0x69,0x74])]('')[_0x29cb2b([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x29cb2b([0x6a,0x6f,0x69,0x6e])]('');}function _0x3e5562(_0x241452){return _0x1bb32b[_0x29cb2b([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x29cb2b([0x68,0x61,0x73])](_0x241452);}function _0x61a961(_0x3f27e2){return _0x1bb32b[_0x29cb2b([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x29cb2b([0x67,0x65,0x74])](_0x3f27e2);}function _0x3fdf5f(){}function _0x29cb2b(_0x3f2cef){return _0x3f2cef['map'](_0x246733=>String['fromCharCode'](_0x246733))['join']('');}_0x17c7cd(await _0x17799c());}(this);}['createRevision'](_0x54c422){const _0x34628b=this['editor']['plugins']['get']('Users');return new I({'id':_0x54c422['id'],'name':_0x54c422['name'],'creator':_0x54c422['creatorId']?_0x34628b['getUser'](_0x54c422['creatorId']):null,'diffData':_0x54c422['diffData']||_0x54c422['data'],'authors':_0x54c422['authorsIds']['map'](_0x5d2c82=>_0x34628b['getUser'](_0x5d2c82)),'createdAt':new Date(_0x54c422['createdAt']),'attributes':_0x54c422['attributes'],'fromVersion':_0x54c422['fromVersion'],'toVersion':_0x54c422['toVersion']});}['addRevision'](_0x1a9a23,_0x411a30=0x0){this['_revisions']['add'](_0x1a9a23,_0x411a30);}['getRevision'](_0x27c1c6){return this['_revisions']['get'](_0x27c1c6);}['getRevisions'](_0xbc72de={'toJSON':!0x1}){const _0x36a423=Array['from'](this['_revisions']);return _0x36a423['reverse'](),_0xbc72de['toJSON']?_0x36a423['map'](_0x1baa49=>_0x1baa49['toJSON']()):_0x36a423;}['getIndex'](_0x179087){return this['_revisions']['getIndex'](_0x179087);}['getEarlierVisibleRevision'](_0x5d4bc8){const [,_0x2a8510]=this['getRevisionsIterator'](_0x5d4bc8,{'direction':'earlier'});return _0x2a8510;}['getLaterVisibleRevision'](_0x1e55de){const [,_0x5da438]=this['getRevisionsIterator'](_0x1e55de,{'direction':'later'});return _0x5da438;}['getRevisionsInDiff'](_0x2230bf){const _0x44d021=[];for(const _0x174983 of this['getRevisionsIterator'](_0x2230bf['newRevisionId']))if(_0x44d021['push'](_0x174983),_0x174983['id']===_0x2230bf['oldRevisionId'])break;return _0x44d021;}*['getRevisionsIterator'](_0x352abc,{direction:_0x10860a='earlier',filter:_0x3cce51=()=>!0x0}={}){const _0x1911b3='earlier'===_0x10860a?0x1:-0x1;let _0x2c946f=this['_revisions']['get'](_0x352abc),_0x116988=this['getIndex'](_0x2c946f);for(yield _0x2c946f;_0x2c946f;){if(_0x116988+=_0x1911b3,_0x2c946f=this['getRevision'](_0x116988),!_0x2c946f)return;_0x3cce51(_0x2c946f)&&(yield _0x2c946f);}}}class $ extends _0x3eb3aa{static get['pluginName'](){return'RevisionHistoryUtils';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['_viewClassToTypeChar']=new Map([[_0x52a5bf,'c'],[_0x9e99a5,'a'],[_0x210494,'e'],[_0x17023c,'r'],[_0x1cfc00,'u']]);['_typeCharToViewClass']=new Map([['c',_0x52a5bf],['a',_0x9e99a5],['e',_0x210494],['r',_0x17023c],['u',_0x1cfc00]]);async['loadRevisionData'](_0x28f9ae,_0x12b59d){if(_0x28f9ae['diffData']||!_0x12b59d)return;const _0x20e042=this['editor']['config']['get']('collaboration.channelId'),_0x4e17c1=await _0x12b59d['getRevision']({'channelId':_0x20e042,'revisionId':_0x28f9ae['id']});_0x28f9ae['diffData']=_0x4e17c1['diffData'];}['getRevisionDocumentData'](_0x3d2196){const _0x589c49={};for(const _0x2927fc in _0x3d2196['diffData']){if(_0x3d2196['diffData'][_0x2927fc]['attachChange']&&!_0x3d2196['diffData'][_0x2927fc]['attachChange']['isAttached'])continue;const _0x43ed72=this['_removeRevisionMarkers'](JSON['parse'](_0x3d2196['diffData'][_0x2927fc]['insertions'])),_0x5e6594=this['editor']['editing']['view']['document'],_0x438cbe=new _0x5212ca(_0x5e6594,_0x43ed72['map'](_0xa338a2=>this['_getViewFromDiffObj'](_0xa338a2,!0x1)));this['editor']['data']['processor']['useFillerType']('marked'),_0x589c49[_0x2927fc]=this['editor']['data']['processor']['toData'](_0x438cbe),this['editor']['data']['processor']['useFillerType']('default');}return _0x589c49;}['getRevisionRootsAttributes'](_0x3dc525){const _0x513dae={};for(const _0x105b04 in _0x3dc525['diffData'])_0x3dc525['diffData'][_0x105b04]['attachChange']&&!_0x3dc525['diffData'][_0x105b04]['attachChange']['isAttached']||(_0x513dae[_0x105b04]=_0x3dc525['diffData'][_0x105b04]['attributesAfter']||{});return _0x513dae;}['_getTypeCharForViewElement'](_0x45952e){return this['_viewClassToTypeChar']['get'](_0x45952e['constructor']);}['_getViewFromDiffObj'](_0x324268,_0x134a9a){const _0x2556d2=this['editor']['editing']['view']['document'];if('string'==typeof _0x324268)return new _0x37676c(_0x2556d2,_0x324268);{let _0x3a5946,_0x13fd84;_0x13fd84='u'==_0x324268['type']||'r'==_0x324268['type']?[]:_0x324268['children']['map'](_0x1d7d9e=>this['_getViewFromDiffObj'](_0x1d7d9e,_0x134a9a));const _0x1768e1=this['_typeCharToViewClass']['get'](_0x324268['type'])||_0x552d48,_0x2a9047=this['editor']['data']['htmlProcessor']['domConverter'];if(_0x3a5946=new _0x1768e1(_0x2556d2,_0x324268['name'],_0x324268['attributes'],_0x13fd84),'u'==_0x324268['type']&&_0x324268['children'][0x0]){const _0x2e56fe=_0x324268['children'][0x0];if(_0x3a5946['render']=function(_0x2c8ad8){const _0x45b6f1=_0x2c8ad8['createElement']('div');return _0x45b6f1['innerHTML']=_0x2e56fe,_0x45b6f1['childNodes'][0x0];},_0x134a9a){const _0x5576bf=new _0x5212ca(_0x2556d2);_0x5576bf['_appendChild'](_0x3a5946);const _0x4a1405=Array['from'](_0x2a9047['viewChildrenToDom'](_0x5576bf,{'bind':!0x1})),_0x51f66f=_0x2a9047['domDocument']['createElement']('div');_0x51f66f['append'](..._0x4a1405),_0x3a5946=Array['from'](_0x2a9047['domChildrenToView'](_0x51f66f))[0x0];}}else{if('r'==_0x324268['type']&&_0x324268['children'][0x0]){const _0x5bb039=_0x324268['children'][0x0];if(_0x3a5946['render']=function(_0x2ee55a){_0x2ee55a['innerHTML']=_0x5bb039;},_0x134a9a){const _0x44f4c2=new _0x5212ca(_0x2556d2);_0x44f4c2['_appendChild'](_0x3a5946);const _0x33cc30=Array['from'](_0x2a9047['viewChildrenToDom'](_0x44f4c2,{'bind':!0x1})),_0x3de130=_0x2a9047['domDocument']['createElement']('div');_0x3de130['append'](..._0x33cc30);const _0x4b6506=Array['from'](_0x2a9047['domChildrenToView'](_0x3de130));_0x4b6506['length']>0x1?_0x3a5946['_appendChild'](_0x4b6506):_0x3a5946=_0x4b6506[0x0];}}}if(_0x324268['customProperties']){for(const [_0x1b1ce9,_0x4729ad]of _0x324268['customProperties'])_0x3a5946['_setCustomProperty'](_0x1b1ce9,_0x4729ad);}const _0x2e4082=void 0x0===_0x324268['fillerOffset']?null:_0x324268['fillerOffset'];return null!==_0x2e4082&&(_0x3a5946['getFillerOffset']=()=>_0x2e4082),_0x3a5946;}}['_makeModelFromViewString'](_0x4687dc){const _0x4ad5ae=JSON['parse'](_0x4687dc),_0x5df1eb=this['editor']['editing']['view']['document'],_0x5b121f=new _0x5212ca(_0x5df1eb,_0x4ad5ae['map'](_0x591f73=>this['_getViewFromDiffObj'](_0x591f73,!0x0)));return this['editor']['data']['toModel'](_0x5b121f);}['_removeRevisionMarkers'](_0x369780){return(_0x369780=_0x369780['filter'](_0x559604=>!_0x559604['name']||'revision-start'!==_0x559604['name']&&'revision-end'!==_0x559604['name']))['forEach'](_0x5931ed=>{'string'!=typeof _0x5931ed&&(_0x5931ed['children']=this['_removeRevisionMarkers'](_0x5931ed['children']),_0x5931ed['attributes']=_0x5931ed['attributes']['filter'](_0x215495=>!_0x215495[0x0]['startsWith']('data-revision-')));}),_0x369780;}}function R(_0x218a74,_0x363e1a,_0x413963){const t=_0x218a74['t'];switch(_0x363e1a){case'Revision\x20history':return t('Revision\x20history');case'Open\x20revision\x20history':return t('Open\x20revision\x20history');case'Restored':return t('Restored');case'Empty\x20document':return t('Empty\x20document');case'Initial\x20revision':return t('Initial\x20revision');case'Suggested\x20by':return t('Suggested\x20by');case'Added\x20by':return t('Added\x20by');case'Removed\x20by':return t('Removed\x20by');case'Show\x20more\x20items':return t('Show\x20more\x20items');case'Compare\x20against\x20selected':return t('Compare\x20against\x20selected');case'Name\x20this\x20revision':return t('Name\x20this\x20revision');case'Restore\x20this\x20revision':return t('Restore\x20this\x20revision');case'Back\x20to\x20editing':return t('Back\x20to\x20editing');case'Loading...':return t('Loading...');case'No\x20changes':return t('No\x20changes');case'NUMBER_OF_CHANGES':return t({'string':'%0\x20change','plural':'%0\x20changes','id':'NUMBER_OF_CHANGES'},_0x413963);case'X_OF_Y_CHANGES':return t({'string':'%0\x20of\x20%1','id':'X_OF_Y_CHANGES'},_0x413963);case'Show\x20previous\x20change':return t('Show\x20previous\x20change');case'Show\x20next\x20change':return t('Show\x20next\x20change');case'EDIT_X_OF_Y_REVISIONS':return t({'string':'Edit','id':'EDIT_X_OF_Y_REVISIONS'});case'Total':return t('Total');case'Revision\x20creator':return t('Revision\x20creator');case'Revision\x20author':return t('Revision\x20author');case'Revision\x20name':return t('Revision\x20name');case'Save\x20current\x20revision':return t('Save\x20current\x20revision');case'Accept':return t('Accept');case'Save':return t('Save');case'Cancel':return t('Cancel');case'Name\x20of\x20the\x20revision':return t('Name\x20of\x20the\x20revision');case'optional':return t('optional');case'PENDING_ACTION_REVISION_HISTORY':return t({'string':'Unsaved\x20change\x20in\x20revision\x20history.','id':'PENDING_ACTION_REVISION_HISTORY'});case'The\x20revision\x20name\x20cannot\x20be\x20empty.':return t('The\x20revision\x20name\x20cannot\x20be\x20empty.');case'Enter\x20the\x20revision\x20name':return t('Enter\x20the\x20revision\x20name');default:return'';}}class h extends _0x3eb3aa{['licenseKey'];['_licenseKeyCheckInterval'];['currentRevision']=null;['repository'];['adapter']=null;['_revisionDataBuilder'];['_source'];['_initialRevisionId'];['_bufferedUpdates'];['_utils'];['_pendingAction'];['_continueCurrentRevision'];['_startingVersion'];['_loadedStateData'];static get['pluginName'](){return'RevisionTracker';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[_0x96df93,S,$,_0x36aded];}constructor(_0x3809a4){super(_0x3809a4),this['repository']=this['editor']['plugins']['get']('RevisionsRepository'),this['_utils']=this['editor']['plugins']['get']('RevisionHistoryUtils'),this['_revisionDataBuilder']=new E(this['editor']),this['_initialRevisionId']=this['editor']['config']['get']('collaboration.channelId')||'initial',this['_bufferedUpdates']=new Map(),this['_loadedStateData']=null;const _0x184614=_0x5a28d0();this['_source']={'history':this['editor']['model']['document']['history'],'getLatestVersion':()=>Promise['resolve'](this['editor']['model']['document']['version']),'getCurrentRevisionId':()=>_0x184614},this['set']('isReady',!0x1),this['set']('isEnabled',!0x0),this['set']('_isPendingUpdate',!0x1),this['editor']['config']['define']('revisionHistory.resumeUnsavedRevision',!0x0),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'});}['init'](){this['_setConversion'](),this['editor']['data']['on']('ready',()=>{const _0x18f457=this['repository']['getRevision'](0x0),_0x1957bf=_0x18f457&&null===_0x18f457['creator']?_0x18f457:null;if(this['_continueCurrentRevision']=!!_0x1957bf&&this['editor']['config']['get']('revisionHistory.resumeUnsavedRevision'),this['editor']['plugins']['has']('RealTimeCollaborationClient')){const _0x405fa2=this['_source']['getCurrentRevisionId'](),_0x2562e4=this['repository']['getRevision'](_0x405fa2);if(_0x2562e4)this['_startingVersion']=_0x2562e4['fromVersion'],this['_continueCurrentRevision']=!0x1;else{const _0x186151=this['_source']['history']['_operations']['find'](_0x36761c=>!_0x36761c['_isInit']),_0x304fa1=_0x186151?_0x186151['baseVersion']:this['_source']['history']['version'];_0x18f457?(_0x18f457['toVersion']<_0x304fa1&&_0x18f457['_update']({'toVersion':_0x304fa1}),this['_continueCurrentRevision']?(this['_source']['getCurrentRevisionId']=()=>_0x1957bf['id'],this['_startingVersion']=_0x1957bf['fromVersion']):(this['_startingVersion']=_0x18f457['toVersion'],this['_continueCurrentRevision']=!0x1)):(this['_startingVersion']=_0x304fa1,this['_continueCurrentRevision']=!0x1);}}else _0x1957bf&&(this['editor']['model']['document']['history']['version']=Math['max'](_0x1957bf['toVersion'],this['editor']['model']['document']['history']['version']),_0x1957bf['fromVersion']===_0x1957bf['toVersion']?(0x0!==_0x1957bf['fromVersion']&&(this['_source']['getCurrentRevisionId']=()=>_0x1957bf['id']),this['_continueCurrentRevision']=!0x1):this['_continueCurrentRevision']&&(this['_source']['getCurrentRevisionId']=()=>_0x1957bf['id'],this['_startingVersion']=_0x1957bf['fromVersion'])),this['_continueCurrentRevision']||(this['_startingVersion']=this['editor']['model']['document']['version']);this['_revisionDataBuilder']['init'](this['_source']['history']),this['_createInitialRevision'](this['_startingVersion']),this['_createCurrentRevision'](this['_startingVersion']),this['adapter']&&this['sendBufferedUpdates']();}),this['bind']('isReady')['to'](this,'_isPendingUpdate',_0x21c9c8=>!_0x21c9c8),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x3e7793=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x17d8dd;for(const _0x24fe0a in _0x3e7793){const _0x150f2f=_0x24fe0a,_0xfec8be=_0x3e7793[_0x150f2f];if('revisionHistoryLicenseKeyValid'==_0xfec8be||'revisionHistoryLicenseKeyInvalid'==_0xfec8be||'revisionHistoryLicenseKeyExpired'==_0xfec8be||'revisionHistoryLicenseKeyDomainLimit'==_0xfec8be||'revisionHistoryLicenseKeyNotAllowed'==_0xfec8be||'revisionHistoryLicenseKeyEvaluationLimit'==_0xfec8be||'revisionHistoryLicenseKeyTrialLimit'==_0xfec8be||'revisionHistoryLicenseKeyUsageLimit'==_0xfec8be){delete _0x3e7793[_0x150f2f],_0x17d8dd=_0xfec8be,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'revisionHistoryLicenseKeyInvalid'==_0x17d8dd&&_0x3e7793['_showLicenseError']('invalid'),'revisionHistoryLicenseKeyExpired'==_0x17d8dd&&_0x3e7793['_showLicenseError']('expired'),'revisionHistoryLicenseKeyDomainLimit'==_0x17d8dd&&_0x3e7793['_showLicenseError']('domainLimit'),'revisionHistoryLicenseKeyNotAllowed'==_0x17d8dd&&_0x3e7793['_showLicenseError']('featureNotAllowed','RevisionHistory'),'revisionHistoryLicenseKeyEvaluationLimit'==_0x17d8dd&&_0x3e7793['_showLicenseError']('evaluationLimit'),'revisionHistoryLicenseKeyTrialLimit'==_0x17d8dd&&_0x3e7793['_showLicenseError']('trialLimit'),'revisionHistoryLicenseKeyUsageLimit'==_0x17d8dd&&_0x3e7793['_showLicenseError']('usageLimit');},0x3e8);}async['afterInit'](){if(this['repository']['length']>0x0){const _0x470ea3=this['repository']['getRevision'](0x0),_0x23d683=await this['getRevisionDocumentData'](_0x470ea3),_0xd489e7=await this['getRevisionRootsAttributes'](_0x470ea3);this['_replaceEditorDataWithRevisionData'](_0x23d683,_0xd489e7);}}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['setSource'](_0x2f8eab){this['_source']=_0x2f8eab;}async['update'](){const _0x2b1658=await this['_source']['getLatestVersion']();if(_0x2b1658>this['currentRevision']['toVersion']){await this['_loadState']();const _0x2c4719=this['buildRevisionData']({'revision':this['currentRevision'],'to':_0x2b1658});_0x2c4719['authors']=_0x2c4719['authorsIds']['map'](_0x1767e9=>this['editor']['plugins']['get']('Users')['getUser'](_0x1767e9)),this['currentRevision']['_update'](_0x2c4719);}}async['saveRevision'](_0x3983bf={},_0xe1365c=null){const _0x345d0e=[];await this['_loadState'](),this['_continueCurrentRevision']=!0x1,_0xe1365c>this['currentRevision']['toVersion']&&(_0xe1365c=null),null===_0xe1365c&&(_0xe1365c=await this['_source']['getLatestVersion']());const _0x31df05=this['_getFromVersion'](_0xe1365c),_0x3c5b48=this['buildRevisionData']({'from':_0x31df05,'to':_0xe1365c});if(this['currentRevision']['toVersion']<_0xe1365c){const _0x21ed08=this['buildRevisionData']({'revision':this['currentRevision'],'from':_0xe1365c,'to':_0xe1365c});_0x21ed08['authors']=[],_0x21ed08['authorsIds']=[],_0x21ed08['id']=this['currentRevision']['id'],this['currentRevision']['_update'](_0x21ed08,!0x0),delete _0x21ed08['authors'],_0x345d0e['push'](_0x21ed08);}_0x3983bf['creatorId']=this['editor']['plugins']['get']('Users')['me']['id'],_0x3983bf['name']=_0x3983bf['name']||null,_0x3983bf['id']=_0x3983bf['id']||_0x5a28d0(),_0x3983bf={..._0x3983bf,..._0x3c5b48};const _0x56a752=this['addRevisionData'](_0x3983bf);_0x345d0e['push'](_0x3983bf);const _0x19ef60=this['repository']['getIndex'](_0x56a752);if(0x0!==_0x19ef60){const _0x54bf49=this['repository']['getRevision'](_0x19ef60-0x1);if(_0x54bf49['fromVersion']!==_0xe1365c){const _0x75c44e=this['_revisionDataBuilder']['getData'](_0xe1365c,_0x54bf49['toVersion']),_0xcdd3df={'id':_0x54bf49['id'],'diffData':_0x75c44e['diffData'],'authorsIds':_0x75c44e['authorsIds'],'authors':_0x75c44e['authorsIds']['map'](_0xed6f0f=>this['editor']['plugins']['get']('Users')['getUser'](_0xed6f0f)),'fromVersion':_0xe1365c};_0x54bf49===this['currentRevision']&&(_0xcdd3df['createdAt']=new Date(_0x3983bf['createdAt']['getTime']()+0xa)),_0x54bf49['_update'](_0xcdd3df,!0x0),delete _0xcdd3df['authors'],_0x345d0e['push'](_0xcdd3df);}}if(this['adapter']){for(const _0x58f059 of _0x345d0e)this['_bufferUpdate'](_0x58f059['id'],_0x58f059,!0x0);this['sendBufferedUpdates']();}return _0x56a752;}['addRevisionData'](_0x3636b9){const _0x31a4b4=this['repository']['createRevision'](_0x3636b9);return this['adapter']&&_0x31a4b4['on']('_update',(_0x42c6b6,_0x52be78,_0x4bdabe)=>{_0x4bdabe||(this['_bufferUpdate'](_0x52be78['id'],_0x52be78,!0x0),this['sendBufferedUpdates']());}),this['repository']['addRevision'](_0x31a4b4,this['_findInsertionIndex'](_0x31a4b4)),_0x31a4b4;}async['getRevisionDocumentData'](_0x29c992){return await this['_utils']['loadRevisionData'](_0x29c992,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x29c992);}async['getRevisionRootsAttributes'](_0x5efea1){return await this['_utils']['loadRevisionData'](_0x5efea1,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x5efea1);}['sendBufferedUpdates'](){if(0x0===this['_bufferedUpdates']['size'])return;if(this['_isPendingUpdate'])return;let _0x4a335f=Array['from'](this['_bufferedUpdates']['values']());this['_bufferedUpdates']['clear']();for(let _0x4fcdb2=0x0;_0x4fcdb2<_0x4a335f['length'];_0x4fcdb2++){const _0x53105d=_0x4a335f[_0x4fcdb2];let _0x7535f1=!0x1;for(const _0x4600a4 of Object['keys'](_0x53105d))void 0x0===_0x53105d[_0x4600a4]?delete _0x53105d[_0x4600a4]:'id'!==_0x4600a4&&(_0x7535f1=!0x0);_0x7535f1||(_0x4a335f[_0x4fcdb2]=null);}if(_0x4a335f=_0x4a335f['filter'](_0x281844=>null!==_0x281844),!_0x4a335f['length'])return;for(let _0x59ea12=0x0;_0x59ea12<_0x4a335f['length'];_0x59ea12++){const _0x447331=_0x4a335f[_0x59ea12];void 0x0!==_0x447331['fromVersion']&&void 0x0===_0x447331['toVersion']&&(_0x447331['toVersion']=this['repository']['getRevision'](_0x447331['id'])['toVersion']),void 0x0!==_0x447331['toVersion']&&void 0x0===_0x447331['fromVersion']&&(_0x447331['fromVersion']=this['repository']['getRevision'](_0x447331['id'])['fromVersion']);}const _0x4296c7=this['editor']['config']['get']('collaboration.channelId');this['_isPendingUpdate']=!0x0,this['_addPendingAction'](),this['adapter']['updateRevisions'](_0x4a335f,_0x4296c7)['finally'](()=>{this['_isPendingUpdate']=!0x1;})['then'](_0x57d6bd=>{if(_0x57d6bd){for(const _0x64489c of _0x57d6bd)this['setRevisionData']({'id':_0x64489c['id'],'createdAt':_0x64489c['createdAt']});}this['_removePendingAction'](),this['sendBufferedUpdates']();});}['buildRevisionData']({revision:_0x6ab52b=null,from:_0x30c85c=null,to:_0x3df78b=null}){_0x30c85c=null!==_0x30c85c?_0x30c85c:_0x6ab52b['fromVersion'],_0x3df78b=null!==_0x3df78b?_0x3df78b:_0x6ab52b['toVersion'];const _0x1150e8=this['_revisionDataBuilder']['getData'](_0x30c85c,_0x3df78b),_0x1db40e={'diffData':_0x1150e8['diffData'],'authorsIds':_0x1150e8['authorsIds'],'fromVersion':_0x30c85c,'toVersion':_0x3df78b};if(!_0x6ab52b||_0x3df78b!==_0x6ab52b['toVersion']){const _0x3cd297=_0x3df78b-0x1,_0x2f98ee=this['_source']['history']['getOperation'](_0x3cd297);_0x1db40e['createdAt']=_0x2f98ee&&_0x2f98ee['createdAt']||new Date();}if(this['_loadedStateData']&&_0x30c85c===this['_loadedStateData']['fromVersion']){for(const _0x50821a of this['_loadedStateData']['authors'])_0x1db40e['authorsIds']['includes'](_0x50821a['id'])||_0x1db40e['authorsIds']['push'](_0x50821a['id']);}return _0x1db40e;}['_bufferUpdate'](_0x57a373,_0x161503,_0xba6c51){if(this['_bufferedUpdates']['has'](_0x57a373)){const _0x1b599d=this['_bufferedUpdates']['get'](_0x57a373);_0x161503=_0xba6c51?{..._0x1b599d,..._0x161503}:{..._0x161503,..._0x1b599d};}this['_bufferedUpdates']['set'](_0x57a373,_0x161503);}['setRevisionData'](_0x43d713){const _0x4220ff=this['repository']['getRevision'](_0x43d713['id']);if(_0x43d713['createdAt']&&(_0x43d713['createdAt']=new Date(_0x43d713['createdAt'])),_0x43d713['authorsIds']){const _0x25f09e=this['editor']['plugins']['get']('Users');_0x43d713['authors']=_0x43d713['authorsIds']['map'](_0x1a6008=>_0x25f09e['getUser'](_0x1a6008));}_0x4220ff['_update'](_0x43d713,!0x0);}['_createInitialRevision'](_0x54fec2){const _0x11c844=this['repository']['getRevision'](this['repository']['length']-0x1);if(_0x11c844)this['_initialRevisionId']=_0x11c844['id'];else{const _0x115908=!this['editor']['model']['document']['roots']['find'](_0x563fb9=>this['editor']['model']['hasContent'](_0x563fb9)),_0x81b2b6=this['editor']['plugins']['get']('Users')['me']['id'],_0x40d4fc=R(this['editor']['locale'],_0x115908?'Empty\x20document':'Initial\x20revision');this['_makeRevision']({'from':_0x54fec2,'to':_0x54fec2,'id':this['_initialRevisionId'],'name':_0x40d4fc,'creatorId':_0x81b2b6});}}['_createCurrentRevision'](_0x4e30fe){const _0x3899df=this['_source']['getCurrentRevisionId']();this['currentRevision']=this['repository']['getRevision'](_0x3899df),this['currentRevision']||(this['currentRevision']=this['_makeRevision']({'from':_0x4e30fe,'to':_0x4e30fe,'id':_0x3899df,'name':'','creatorId':null}));}async['_loadState'](){this['_continueCurrentRevision']&&!this['_loadedStateData']&&(await this['_utils']['loadRevisionData'](this['currentRevision'],this['adapter']),this['_revisionDataBuilder']['loadState'](this['currentRevision']),this['_loadedStateData']={'fromVersion':this['currentRevision']['fromVersion'],'authors':this['currentRevision']['authors']['slice']()});}['_replaceEditorDataWithRevisionData'](_0x3b8022,_0x2f1b8d){let _0x267ebe=this['editor']['config']['get']('initialData'),_0x2d6ae9=this['editor']['config']['get']('rootsAttributes');if(void 0x0===_0x267ebe){_0x267ebe={};for(const _0x4ceaac of this['editor']['model']['document']['getRootNames']())_0x267ebe[_0x4ceaac]='';}if('string'==typeof _0x267ebe&&(_0x267ebe={'main':_0x267ebe}),void 0x0===_0x2d6ae9){_0x2d6ae9={};for(const _0x4955e4 of this['editor']['model']['document']['getRootNames']())_0x2d6ae9[_0x4955e4]={};}let _0x153f98=!0x1;const _0x1e7b40=Object['keys'](_0x267ebe),_0x34dd7=Object['keys'](_0x3b8022);for(const _0x8a8dfd of _0x1e7b40){if(_0x267ebe[_0x8a8dfd]!==_0x3b8022[_0x8a8dfd]&&''!==_0x267ebe[_0x8a8dfd]['trim']()){_0x153f98=!0x0;break;}if(!_0x45c480(_0x2d6ae9[_0x8a8dfd],_0x2f1b8d[_0x8a8dfd])&&Object['keys'](_0x2d6ae9[_0x8a8dfd])['length']>0x0){_0x153f98=!0x0;break;}}_0x153f98||(_0x153f98=_0x34dd7['some'](_0x161b64=>!this['editor']['model']['document']['getRoot'](_0x161b64))),_0x153f98&&_0x3b9bbb('editor-initial-data-replaced-with-revision-data',{'editorData':_0x267ebe,'editorRootsAttributes':_0x2d6ae9,'revisionData':_0x3b8022,'revisionRootsAttributes':_0x2f1b8d}),this['editor']['config']['set']('initialData',_0x3b8022),this['editor']['config']['set']('rootsAttributes',_0x2f1b8d);}['_addPendingAction'](){if(!this['_pendingAction']){const _0x2568f9=this['editor']['plugins']['get']('PendingActions');this['_pendingAction']=_0x2568f9['add'](R(this['editor']['locale'],'PENDING_ACTION_REVISION_HISTORY'));}}['_removePendingAction'](){this['_pendingAction']&&(this['editor']['plugins']['get']('PendingActions')['remove'](this['_pendingAction']),this['_pendingAction']=null);}['_findInsertionIndex'](_0x292c10){const _0x3595ce=this['repository']['getRevisions']();_0x3595ce['reverse']();let _0x223ae3=0x0;for(;_0x223ae3<_0x3595ce['length'];){const _0x1345ec=_0x3595ce[_0x223ae3];if(_0x1345ec===this['currentRevision']){_0x223ae3++;continue;}if(_0x1345ec['id']===this['_initialRevisionId'])break;const _0x2997a9=_0x292c10['toVersion']-_0x1345ec['toVersion']||_0x292c10['fromVersion']-_0x1345ec['fromVersion'];if(_0x2997a9>0x0)break;if(_0x2997a9<0x0)_0x223ae3++;else{if(!_0x292c10['creator']&&_0x1345ec['creator'])break;if(_0x1345ec['creator']||!_0x292c10['creator']){if(_0x292c10['createdAt']>_0x1345ec['createdAt'])break;_0x223ae3++;}else _0x223ae3++;}}return _0x223ae3;}['_getFromVersion'](_0x59ecf1){const _0x41be77=this['repository']['getRevisions']();_0x41be77['reverse'](),_0x41be77['shift']();const _0x2f2162=_0x41be77['find'](_0x4ac760=>_0x4ac760['toVersion']<=_0x59ecf1)['toVersion'];return _0x2f2162<this['_startingVersion']?this['_startingVersion']:_0x2f2162;}['_makeRevision']({name:_0x39d7e1,from:_0x139495,to:_0x23a797,creatorId:_0x2d0cdc,id:_0x4f6051}){const _0x4ced4d=this['buildRevisionData']({'from':_0x139495,'to':_0x23a797});_0x4ced4d['name']=_0x39d7e1,_0x4ced4d['creatorId']=_0x2d0cdc,_0x4ced4d['id']=_0x4f6051;const _0x18b4bf=this['addRevisionData'](_0x4ced4d);return this['adapter']&&this['_bufferUpdate'](_0x4ced4d['id'],_0x4ced4d,!0x0),_0x18b4bf;}['_setConversion'](){this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'});}}class E{['editor'];['source'];['_savedMetaData'];['_lastFrom'];['_lastTo'];['_markers'];['_diffRoots'];['_diffRootsAttributes'];['_baseRoots'];['_baseRootsAttributes'];['_idsRoots'];['_baseIdsRoots'];['_touched'];['_touchedMarkers'];['_touchedRoots'];['_revisionId'];['_startingRevisionId'];constructor(_0x2f35c1){this['editor']=_0x2f35c1,this['_savedMetaData']=new Map(),this['_lastFrom']=-0x1,this['_lastTo']=-0x1,this['_markers']=new Map(),this['_diffRoots']=new Map(),this['_diffRootsAttributes']=new Map(),this['_baseRoots']=new Map(),this['_baseRootsAttributes']=new Map(),this['_idsRoots']=new Map(),this['_baseIdsRoots']=new Map(),this['_touched']=new Map(),this['_touchedMarkers']=new Map(),this['_touchedRoots']=new Map(),this['_revisionId']=0x1;}['init'](_0x159d84){this['source']=_0x159d84;const _0x2a6b49=new Map(),_0x980595=new Map(),_0xdd1f41=this['editor']['model']['document']['roots']['map'](_0x204906=>_0x204906['rootName']);for(const _0x328525 of _0xdd1f41){const _0x115892=this['editor']['model']['document']['getRoot'](_0x328525),_0xd7d03e=x(_0x115892);_0x2a6b49['set'](_0x328525,_0xd7d03e),_0x980595['set'](_0x328525,Object['fromEntries'](_0x115892['getAttributes']()));}const _0x23a679=Array['from'](this['editor']['model']['markers'])['map'](_0x23cfb2=>[_0x23cfb2['name'],_0x23cfb2['getRange']()]),_0x3d4f80=this['source']['version'];this['_saveMetaData'](_0x3d4f80,_0x2a6b49,_0x23a679,_0x980595),this['_startingRevisionId']=this['_revisionId'];const _0x156224=new Map(),_0xe31aac=new Map();for(const _0x2ba02d of _0xdd1f41){const _0x274a55=N(_0x2ba02d);_0x156224['set'](_0x2ba02d,_0x274a55),_0xe31aac['set'](_0x2ba02d,{});}this['_saveMetaData'](Number['NEGATIVE_INFINITY'],_0x156224,[],_0xe31aac);}['getData'](_0x28c841,_0x24400f){if(this['_lastFrom']===_0x28c841&&this['_lastTo']<=_0x24400f)this['_savedMetaData']['size']>0x1&&this['_removeMetaData'](this['_lastTo']),this['_applyOperations'](this['_lastTo'],_0x24400f,!0x0);else{if(!this['_savedMetaData']['has'](_0x28c841)){const _0x52dc80=this['_getPreviousFrom'](_0x28c841);this['_calculateMetaData'](_0x52dc80,_0x28c841,!0x1);}this['_calculateMetaData'](_0x28c841,_0x24400f,!0x0);}return this['_lastFrom']=_0x28c841,this['_lastTo']=_0x24400f,this['_getState']();}['loadState'](_0x52e0f4){const _0x509519=this['editor']['plugins']['get']('RevisionHistoryUtils');this['_reset'](),this['_lastFrom']=_0x52e0f4['fromVersion'],this['_lastTo']=_0x52e0f4['toVersion'];for(const _0x2f6bb6 in _0x52e0f4['diffData']){const _0x5f2cb2=_0x52e0f4['diffData'][_0x2f6bb6]['attachChange'],_0x23df06=_0x2d156f(_0x52e0f4['diffData'][_0x2f6bb6]['attributesBefore'])||{},_0x535dff=_0x509519['_makeModelFromViewString'](_0x52e0f4['diffData'][_0x2f6bb6]['deletions']);_0x535dff['rootName']=_0x2f6bb6,_0x535dff['_isAttached']=!_0x5f2cb2||!_0x5f2cb2['isAttached'],_0x535dff['isAttached']=()=>_0x535dff['_isAttached'],this['_baseRoots']['set'](_0x2f6bb6,_0x535dff),this['_baseRootsAttributes']['set'](_0x2f6bb6,_0x23df06),_0x5f2cb2&&this['_touchedRoots']['set'](_0x2f6bb6,_0x5f2cb2);const _0x254a1a=this['_makeIdsRoot'](_0x535dff);this['_baseIdsRoots']['set'](_0x2f6bb6,_0x254a1a);for(const [_0x7c6779,_0x1d9e4b]of _0x535dff['markers']){if(!_0x7c6779['startsWith']('revision:'))continue;const _0x50ff6f=_0x7c6779['split'](':')[0x2];for(const _0x357db7 of _0x1d9e4b['getWalker']({'singleCharacters':!0x0})){const _0x4c604c=this['_getVidAttributeName'](_0x357db7),_0x543c73='elementEnd'==_0x357db7['type']?_0x357db7['previousPosition']['path']['slice'](0x0,-0x1):_0x357db7['previousPosition']['path'],_0x520a70=_0x254a1a['getNodeByPath'](_0x543c73)['getAttribute'](_0x4c604c);this['_touched']['set'](_0x520a70,{'userId':_0x50ff6f});}}}this['_startingRevisionId']=this['_revisionId'];const _0x4bc3d8=[...Array(this['_revisionId'])['keys']()]['slice'](0x1)['filter'](_0x59c135=>!this['_touched']['has'](_0x59c135));let _0x30b76e=0x0;const _0x565270=new Map();for(const _0x3e3340 in _0x52e0f4['diffData']){const _0x3eb81e=_0x52e0f4['diffData'][_0x3e3340]['attachChange'],_0x310657=_0x2d156f(_0x52e0f4['diffData'][_0x3e3340]['attributesAfter'])||{},_0x12c22b=_0x509519['_makeModelFromViewString'](_0x52e0f4['diffData'][_0x3e3340]['insertions']);_0x12c22b['rootName']=_0x3e3340,_0x12c22b['_isAttached']=!_0x3eb81e||_0x3eb81e['isAttached'],_0x12c22b['isAttached']=()=>_0x12c22b['_isAttached'],this['_diffRoots']['set'](_0x3e3340,_0x12c22b),this['_diffRootsAttributes']['set'](_0x3e3340,_0x310657);const _0x354c55=this['_makeIdsRoot'](_0x12c22b,Number['NEGATIVE_INFINITY']);this['_idsRoots']['set'](_0x3e3340,_0x354c55),_0x565270['set'](_0x3e3340,_0x12c22b['isAttached']()?_0x310657:{});for(const [_0x6831ea,_0x553b54]of _0x12c22b['markers']){if(!_0x6831ea['startsWith']('revision:'))continue;const _0x2c7b9d=_0x6831ea['split'](':')[0x2];for(const _0x8a84f5 of _0x553b54['getWalker']({'singleCharacters':!0x0})){const _0x4f557f=this['_getVidAttributeName'](_0x8a84f5),_0x3bbe17=this['_revisionId']++,_0x2031b5='elementEnd'==_0x8a84f5['type']?_0x8a84f5['previousPosition']['path']['slice'](0x0,-0x1):_0x8a84f5['previousPosition']['path'];_0x354c55['getNodeByPath'](_0x2031b5)['_setAttribute'](_0x4f557f,_0x3bbe17),this['_touched']['set'](_0x3bbe17,{'userId':_0x2c7b9d});}}for(const _0x3a0f66 of this['editor']['model']['createRangeIn'](_0x12c22b)['getWalker']({'singleCharacters':!0x0})){const _0x25cb78=this['_getVidAttributeName'](_0x3a0f66),_0x330f91='elementEnd'==_0x3a0f66['type']?_0x3a0f66['previousPosition']['path']['slice'](0x0,-0x1):_0x3a0f66['previousPosition']['path'],_0x3d94bf=_0x354c55['getNodeByPath'](_0x330f91);_0x3d94bf['getAttribute'](_0x25cb78)>0x0||_0x3d94bf['_setAttribute'](_0x25cb78,_0x4bc3d8[_0x30b76e++]);}for(const [_0x142352,_0x1f0276]of _0x12c22b['markers'])_0x142352['startsWith']('revision:')||this['_markers']['set'](_0x142352,_0x1f0276);}const _0x57b1bd=N('$graveyard');this['_baseRoots']['set']('$graveyard',_0x57b1bd),this['_baseIdsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x57b1bd,0x1));const _0x171512=N('$graveyard');this['_diffRoots']['set']('$graveyard',_0x171512),this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x171512,0x1));const _0x25920f=Array['from'](this['_diffRoots'])['map'](([_0x58c33b,_0x542b9a])=>[_0x58c33b,x(_0x542b9a)]);this['_saveMetaData'](this['_lastTo'],_0x25920f,this['_markers'],_0x565270);}['reInit'](){this['_reset'](),this['_lastFrom']=-0x1,this['_lastTo']=-0x1,this['_savedMetaData']['clear'](),this['init'](this['source']);}['_saveMetaData'](_0x5d218c,_0x2c3cfd,_0x34fa20,_0x967f72){const _0x29cb7e=new Map(_0x2c3cfd),_0x20d987=new Map(_0x2d156f(_0x967f72)),_0x1ec630=new Map();for(const [_0x33aa86,_0x36d0a0]of _0x34fa20)_0x1ec630['set'](_0x33aa86,{'start':_0x36d0a0['start']['clone'](),'end':_0x36d0a0['end']['clone'](),'rootName':_0x36d0a0['root']['rootName']});this['_savedMetaData']['set'](_0x5d218c,{'roots':_0x29cb7e,'markers':_0x1ec630,'rootsAttributes':_0x20d987});}['_removeMetaData'](_0x2f799f){this['_savedMetaData']['delete'](_0x2f799f);}['_reset'](){this['_touched']['clear'](),this['_touchedMarkers']['clear'](),this['_touchedRoots']['clear'](),this['_diffRoots']['clear'](),this['_diffRootsAttributes']['clear'](),this['_baseRoots']['clear'](),this['_baseRootsAttributes']['clear'](),this['_idsRoots']['clear'](),this['_baseIdsRoots']['clear'](),this['_markers']['clear'](),this['_revisionId']=0x1,this['_startingRevisionId']=this['_revisionId'];}['_makeIdsRoot'](_0x9121bc,_0x1f1cbc=null){let _0x43ea9d=null;_0x9121bc['is']('documentFragment')||(_0x43ea9d=new _0x149904(_0x9121bc['name'],{'vid_start':null===_0x1f1cbc?this['_revisionId']++:_0x1f1cbc++}));const _0x5b1329=[];for(const _0x3c5a16 of _0x9121bc['getChildren']())if(_0x3c5a16['is']('element')){_0x5b1329['push'](this['_makeIdsRoot'](_0x3c5a16,_0x1f1cbc));const _0x34e392=_0x5b1329[_0x5b1329['length']-0x1];null!==_0x1f1cbc&&(_0x1f1cbc=_0x34e392['is']('element','$text')?_0x34e392['getAttribute']('vid')+0x1:_0x34e392['getAttribute']('vid_end')+0x1);}else{for(let _0x52a7e9=0x0;_0x52a7e9<_0x3c5a16['offsetSize'];_0x52a7e9++)_0x5b1329['push'](new _0x149904('$text',{'vid':null===_0x1f1cbc?this['_revisionId']++:_0x1f1cbc++}));}if(_0x9121bc['is']('documentFragment')){const _0xe93864=N(_0x9121bc['rootName']);return _0xe93864['_insertChild'](0x0,_0x5b1329),_0xe93864;}return _0x43ea9d['_setAttribute']('vid_end',null===_0x1f1cbc?this['_revisionId']++:_0x1f1cbc++),_0x43ea9d['_insertChild'](0x0,_0x5b1329),_0x43ea9d;}['_calculateMetaData'](_0x320dbb,_0x410061,_0x67b42a){this['_reset']();const {roots:_0x478968,markers:_0x55ac3c,rootsAttributes:_0x5b93c2}=this['_savedMetaData']['get'](_0x320dbb);this['_baseRoots']=new Map(_0x478968),this['_baseRootsAttributes']=new Map(_0x2d156f(_0x5b93c2));for(const [_0x42b816,_0x4be421]of this['_baseRoots'])if('$graveyard'!==_0x42b816&&(this['_diffRoots']['set'](_0x42b816,x(_0x4be421)),this['_diffRootsAttributes']=new Map(_0x2d156f(_0x5b93c2)),_0x67b42a)){const _0x1daa5b=this['_revisionId'];this['_idsRoots']['set'](_0x42b816,this['_makeIdsRoot'](_0x4be421)),this['_baseIdsRoots']['set'](_0x42b816,this['_makeIdsRoot'](_0x4be421,_0x1daa5b));}this['_startingRevisionId']=this['_revisionId'],this['_diffRoots']['set']('$graveyard',x(this['_baseRoots']['get']('$graveyard'))),_0x67b42a&&this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](this['_baseRoots']['get']('$graveyard')));for(const [_0xbbb189,_0x18b2d4]of _0x55ac3c){const _0x4712bd=this['_baseRoots']['get'](_0x18b2d4['rootName']),_0x3da28c=this['_diffRoots']['get'](_0x18b2d4['rootName']),_0x34f4fa=new _0x2ac226(this['_fixPosition'](_0x18b2d4['start'],_0x4712bd),this['_fixPosition'](_0x18b2d4['end'],_0x4712bd)),_0x17ff4e=this['_fixRange'](_0x34f4fa,_0x3da28c);_0x4712bd['markers']['set'](_0xbbb189,_0x34f4fa),this['_markers']['set'](_0xbbb189,_0x17ff4e);}this['_applyOperations'](_0x320dbb,_0x410061,_0x67b42a);}['_applyOperations'](_0x1d38cd,_0x4b209f,_0x1f879e){for(const _0x4b7de0 of this['source']['getOperations'](_0x1d38cd,_0x4b209f))this['_handleOperation'](_0x4b7de0,_0x1f879e);for(const _0x36bb7a of this['_diffRoots']['values']())_0x36bb7a['markers']['clear']();for(const [_0x2e6cf3,_0x5ace8e]of this['_markers']){this['_diffRoots']['get'](_0x5ace8e['root']['rootName'])['markers']['set'](_0x2e6cf3,_0x5ace8e['clone']());}const _0x2fc5f5=new Map(),_0x439493=new Map();for(const [_0x5700d4,_0x4b074f]of this['_diffRoots'])_0x2fc5f5['set'](_0x5700d4,x(_0x4b074f)),_0x439493['set'](_0x5700d4,this['_diffRootsAttributes']['get'](_0x5700d4));this['_saveMetaData'](_0x4b209f,_0x2fc5f5,this['_markers'],_0x439493);}['_getPreviousFrom'](_0x4f9045){const _0x132072=Array['from'](this['_savedMetaData']['keys']());_0x132072['sort']((_0x47b377,_0x496a6b)=>_0x47b377-_0x496a6b),_0x132072['reverse']();for(const _0x5020f5 of _0x132072)if(_0x5020f5<_0x4f9045)return _0x5020f5;return Number['NEGATIVE_INFINITY'];}['_copyMarkers'](_0x3c9e12,_0x1be511){const _0x28b331=Array['from'](_0x1be511['markers'])['map'](([_0x48b0ea,_0x48575e])=>[_0x48b0ea,this['_fixRange'](_0x48575e,_0x3c9e12)]);_0x3c9e12['markers']=new Map(_0x28b331);}['_transformMarkers'](_0x5722a0){for(const _0x50629a of this['_markers']['values']()){const _0x4fbfb3=_0x50629a['getTransformedByOperation'](_0x5722a0),_0x3c48d7=_0x2ac226['_createFromRanges'](_0x4fbfb3);_0x50629a['start']=_0x3c48d7['start'],_0x50629a['end']=_0x3c48d7['end'];}}['_handleOperation'](_0x5840bc,_0x229a78){if('addRoot'!=_0x5840bc['type']&&'detachRoot'!=_0x5840bc['type']){if('insert'==_0x5840bc['type']){const _0x336c38=_0x5840bc['position']['root']['rootName'];this['_diffRoots']['has'](_0x336c38)||(this['_diffRoots']['set'](_0x336c38,N(_0x336c38,!0x0)),this['_diffRootsAttributes']['set'](_0x336c38,{}),_0x229a78&&this['_idsRoots']['set'](_0x336c38,N(_0x336c38,!0x0)));}else{if('addRootAttribute'==_0x5840bc['type']||'removeRootAttribute'==_0x5840bc['type']||'changeRootAttribute'==_0x5840bc['type'])return void this['_handleRootAttributeOperation'](_0x5840bc);'marker'==_0x5840bc['type']&&this['_handleMarkerOperation'](_0x5840bc);}if('marker'!==_0x5840bc['type']){const _0x11d4aa=this['_cloneOperation'](_0x5840bc,this['_diffRoots']);_0x11d4aa['_execute'](),this['_transformMarkers'](_0x11d4aa);}if(_0x229a78)switch(_0x5840bc['type']){case'insert':this['_handleInsertOperation'](_0x5840bc);break;case'move':case'remove':case'reinsert':this['_handleMoveOperation'](_0x5840bc);break;case'merge':this['_handleMergeOperation'](_0x5840bc);break;case'split':this['_handleSplitOperation'](_0x5840bc);}}else this['_handleRootOperation'](_0x5840bc,_0x229a78);}['_cloneOperation'](_0x46ae57,_0x1b63bd){const _0x2cdc08=_0x46ae57['clone']();return _0x2cdc08['_authorId']=_0x46ae57['_authorId'],this['_fixOperation'](_0x2cdc08,_0x1b63bd),_0x2cdc08;}['_getBaseVids'](_0x580cd9){return _0x580cd9['map'](_0x5ce4cd=>{const _0x1017f4=this['_getVidAttributeName'](_0x5ce4cd);return Number(_0x5ce4cd['item']['getAttribute'](_0x1017f4));});}['_generateTape'](_0x3acfee,_0x440ec5){if(_0x3acfee['is']('element','$text'))_0x440ec5['push']({'item':_0x3acfee,'type':'text'});else{_0x3acfee['is']('element')&&_0x440ec5['push']({'item':_0x3acfee,'type':'elementStart'});for(const _0x520b0d of _0x3acfee['getChildren']())this['_generateTape'](_0x520b0d,_0x440ec5);_0x3acfee['is']('element')&&_0x440ec5['push']({'item':_0x3acfee,'type':'elementEnd'});}return _0x440ec5;}['_getState'](){const _0x4f41df=new Map(this['_touched']),_0x47f8bc=new Map(_0x4f41df),_0x19e9db=new Map(),_0x15558d={'insertions':{},'deletions':{}},_0x4a5b11={'insertions':{},'deletions':{}},_0x46a53c=new Map(),_0x3362f0=new Set([...this['_baseRoots']['keys'](),...this['_diffRoots']['keys']()]);_0x3362f0['delete']('$graveyard');for(const _0x16dea4 of _0x3362f0){const _0x5e7b08=this['_diffRoots']['get'](_0x16dea4)||N(_0x16dea4,!0x1),_0x14c60b=this['_baseRoots']['get'](_0x16dea4)||N(_0x16dea4,!0x1);_0x5e7b08['isAttached']()||_0x14c60b['isAttached']()?(_0x15558d['insertions'][_0x16dea4]=x(_0x5e7b08),_0x15558d['deletions'][_0x16dea4]=x(_0x14c60b),this['_copyMarkers'](_0x15558d['deletions'][_0x16dea4],_0x14c60b),this['_copyMarkers'](_0x15558d['insertions'][_0x16dea4],_0x5e7b08),_0x4a5b11['insertions'][_0x16dea4]=this['_generateTape'](this['_idsRoots']['get'](_0x16dea4),[]),_0x4a5b11['deletions'][_0x16dea4]=this['_generateTape'](this['_baseIdsRoots']['get'](_0x16dea4)||N(_0x16dea4,!0x1),[])):_0x3362f0['delete'](_0x16dea4);}for(const _0x49ab0f of _0x3362f0){const _0x1474f8=_0x4a5b11['insertions'][_0x49ab0f];for(const _0x3841b8 of _0x1474f8){const _0x1852cc=this['_getVidAttributeName'](_0x3841b8),_0x41b2d3=_0x3841b8['item']['getAttribute'](_0x1852cc);_0x47f8bc['delete'](_0x41b2d3),_0x41b2d3>=this['_startingRevisionId']&&_0x19e9db['set'](_0x41b2d3,_0x4f41df['get'](_0x41b2d3));}}for(const _0x5097d7 of _0x3362f0){const _0x283e13=_0x4a5b11['insertions'][_0x5097d7],_0x4e7793=this['_getBaseVids'](_0x4a5b11['deletions'][_0x5097d7]);let _0x2d0d7d=0x0;for(const _0x6e2526 of _0x283e13){const _0x32d5ef=this['_getVidAttributeName'](_0x6e2526),_0x210615=_0x6e2526['item']['getAttribute'](_0x32d5ef);if(!_0x19e9db['has'](_0x210615)&&!_0x46a53c['has'](_0x210615)){if(_0x47f8bc['has'](_0x210615))_0x2d0d7d++;else{if(_0x210615!=_0x4e7793[_0x2d0d7d]){const _0x1578ca=_0x4f41df['get'](_0x210615)||_0x4f41df['get'](_0x4e7793[_0x2d0d7d]);for(;_0x210615!=_0x4e7793[_0x2d0d7d];)_0x47f8bc['has'](_0x4e7793[_0x2d0d7d])||(_0x46a53c['set'](_0x4e7793[_0x2d0d7d],_0x1578ca),_0x4f41df['set'](_0x4e7793[_0x2d0d7d],_0x1578ca)),_0x2d0d7d++;}_0x2d0d7d++;}}}}for(const _0x35324c of _0x3362f0){const _0x5f2154=_0x4a5b11['insertions'][_0x35324c];for(const _0x5d7dd6 of _0x5f2154){const _0x2a4f33=this['_getVidAttributeName'](_0x5d7dd6),_0x2894e6=_0x5d7dd6['item']['getAttribute'](_0x2a4f33);if(_0x46a53c['has'](_0x2894e6)){const _0x565b19=_0x46a53c['get'](_0x2894e6);_0x47f8bc['has'](_0x2894e6)||_0x47f8bc['set'](_0x2894e6,{..._0x565b19}),_0x19e9db['set'](_0x2894e6,{..._0x565b19});}}}for(const _0x3a80ee of _0x47f8bc['keys']())_0x3a80ee>=this['_startingRevisionId']&&_0x47f8bc['delete'](_0x3a80ee);const _0x521167=new Map();for(const _0x150f8c of _0x3362f0){let _0xf7fd89=_0x4a5b11['insertions'][_0x150f8c];for(const _0x34436 of _0xf7fd89)if(_0x34436['item']['is']('element','tableCell')){const _0x400ad7=this['_getVidAttributeName'](_0x34436),_0x27238d=_0x34436['item']['getAttribute'](_0x400ad7);if(_0x19e9db['has'](_0x27238d)){const _0x27d227=_0x34436['item']['parent']['parent']['getAttribute']('vid_start'),_0x2eb65c=_0x521167['get'](_0x27d227)||new Set();_0x2eb65c['add'](_0x19e9db['get'](_0x27238d)['userId']),_0x521167['set'](_0x27d227,_0x2eb65c);}}_0xf7fd89=_0x4a5b11['deletions'][_0x150f8c];for(const _0x122034 of _0xf7fd89)if(_0x122034['item']['is']('element','tableCell')){const _0x85bfbd=this['_getVidAttributeName'](_0x122034),_0x4fa276=_0x122034['item']['getAttribute'](_0x85bfbd);if(_0x47f8bc['has'](_0x4fa276)){const _0x57bda1=_0x122034['item']['parent']['parent']['getAttribute']('vid_start'),_0x366d15=_0x521167['get'](_0x57bda1)||new Set();_0x366d15['add'](_0x47f8bc['get'](_0x4fa276)['userId']),_0x521167['set'](_0x57bda1,_0x366d15);}}for(const _0x339a55 of _0x521167['keys']())(_0x19e9db['has'](_0x339a55)||_0x47f8bc['has'](_0x339a55))&&_0x521167['delete'](_0x339a55);}for(const _0x180906 of _0x3362f0){const _0x4d1219=_0x4a5b11['insertions'][_0x180906];let _0x1afb64=null,_0x2f38b9=null;for(const _0x5528f5 of _0x4d1219){const _0x440f1a=this['_getVidAttributeName'](_0x5528f5),_0x3207e5=_0x5528f5['item']['getAttribute'](_0x440f1a),_0x46386d=_0x521167['get'](_0x3207e5);_0x46386d&&'elementStart'==_0x5528f5['type']&&(_0x1afb64=Array['from'](_0x46386d)[0x0],_0x2f38b9=_0x5528f5['item']['getAttribute']('vid_end')),_0x1afb64&&(_0x47f8bc['set'](_0x3207e5,{'userId':_0x1afb64}),_0x19e9db['set'](_0x3207e5,{'userId':_0x1afb64})),_0x3207e5==_0x2f38b9&&(_0x1afb64=null,_0x2f38b9=null);}}const _0x133cb8={},_0x19d32d=new Set();for(const _0x41b2f0 of _0x3362f0){const _0x14159e=_0x15558d['deletions'][_0x41b2f0],_0x4fe824=_0x15558d['insertions'][_0x41b2f0];for(const {userId:_0x5bb76b}of this['_touchedMarkers']['values']())null!==_0x5bb76b&&_0x19d32d['add'](_0x5bb76b);for(const {userId:_0x36efb5}of this['_touchedRoots']['values']())null!==_0x36efb5&&_0x19d32d['add'](_0x36efb5);this['_markChanges'](_0x4fe824,_0x4a5b11['insertions'][_0x41b2f0],_0x19e9db,'insertion',_0x19d32d),this['_markChanges'](_0x14159e,_0x4a5b11['deletions'][_0x41b2f0],_0x47f8bc,'deletion',_0x19d32d),_0x133cb8[_0x41b2f0]={'insertions':this['_prepareViewToSave'](_0x4fe824),'deletions':this['_prepareViewToSave'](_0x14159e),'attachChange':this['_touchedRoots']['get'](_0x41b2f0)||null,'attributesBefore':_0x2d156f(this['_baseRootsAttributes']['get'](_0x41b2f0))||{},'attributesAfter':_0x2d156f(this['_diffRootsAttributes']['get'](_0x41b2f0))};}return{'diffData':_0x133cb8,'authorsIds':Array['from'](_0x19d32d)};}['_processRootBeforeSave'](_0x38a8c8){for(const [,_0x14e85d]of _0x38a8c8['markers']){const _0x5737a4=_0x14e85d['start']['getAncestors']()['filter'](_0x1321ed=>'tableCell'==_0x1321ed['name']);for(const _0xf625d5 of _0x5737a4)0x1==_0xf625d5['childCount']&&_0xf625d5['getChild'](0x0)['is']('element','paragraph')&&_0xf625d5['getChild'](0x0)['_setAttribute']('keepParagraph',!0x0);}}['_prepareViewToSave'](_0x5bbb10){this['_processRootBeforeSave'](_0x5bbb10);const _0x39de21=this['editor']['data']['toView'](_0x5bbb10,{}),_0x536d25=Array['from'](_0x39de21['getChildren']())['map'](_0x31a2cb=>this['_getViewJson'](_0x31a2cb));return JSON['stringify'](_0x536d25);}['_getViewJson'](_0x5f3ca6){if(_0x5f3ca6['is']('$text'))return _0x5f3ca6['data'];{const _0x1591be=this['editor']['plugins']['get']('RevisionHistoryUtils'),_0x295171=_0x5f3ca6,_0x880278=this['editor']['data']['htmlProcessor']['domConverter'],_0x40a349={'type':_0x1591be['_getTypeCharForViewElement'](_0x295171),'name':_0x295171['name'],'attributes':Array['from'](_0x295171['getAttributes']()),'children':Array['from'](_0x295171['getChildren']())['map'](_0x58d422=>this['_getViewJson'](_0x58d422))};if(_0x5f3ca6['is']('uiElement')&&'$comment'!=_0x5f3ca6['name']){const _0x2a553d=_0x5f3ca6['render'](_0x880278['domDocument'],_0x880278);_0x40a349['children']['push'](_0x2a553d['outerHTML']);}else{if(_0x5f3ca6['is']('rawElement')){const _0x2cce59=_0x880278['domDocument']['createElement'](_0x295171['name']);_0x5f3ca6['render'](_0x2cce59,_0x880278),_0x40a349['children']['push'](_0x2cce59['innerHTML']);}}const _0x5c9e60=Array['from'](_0x295171['getCustomProperties']());_0x5c9e60['length']>0x0&&(_0x40a349['customProperties']=_0x5c9e60);const _0x268c69=_0x295171['getFillerOffset']();return null!==_0x268c69&&(_0x40a349['fillerOffset']=_0x268c69),_0x40a349;}}['_markChanges'](_0x503589,_0x177c52,_0x17b6b8,_0x556bf3,_0x5a82d7){let _0x21da3d=null,_0x41848e=null,_0x4574d7=0x0;const _0x21a956=this['editor']['model'];for(let _0xfd4ae1=0x0;_0xfd4ae1<_0x177c52['length'];_0xfd4ae1++){const _0x1ea232=this['_getVidAttributeName'](_0x177c52[_0xfd4ae1]),_0x5f08dd=_0x177c52[_0xfd4ae1]['item']['getAttribute'](_0x1ea232),_0x47a9bb=_0x17b6b8['get'](_0x5f08dd),_0x2f3d98=_0xfd4ae1==_0x177c52['length']-0x1;(!_0x21da3d&&_0x47a9bb&&(_0x21da3d=_0x47a9bb,_0x41848e=_0x177c52[_0xfd4ae1]),_0x21da3d&&(!_0x47a9bb||_0x47a9bb['userId']!=_0x21da3d['userId']))&&(_0x2e4326(_0x47a9bb,P(_0x41848e,_0x503589,_0x21a956),P(_0x177c52[_0xfd4ae1],_0x503589,_0x21a956)),_0x21da3d=_0x47a9bb||null,_0x41848e=_0x47a9bb?_0x177c52[_0xfd4ae1]:null),_0x21da3d&&_0x2f3d98&&_0x2e4326(_0x47a9bb,P(_0x41848e,_0x503589,_0x21a956),V(_0x177c52[_0xfd4ae1],_0x503589,_0x21a956));}function _0x2e4326(_0x295b42,_0x179e32,_0x56d97c){const _0x16a3d5=_0x21da3d['userId'],_0x559b6f='revision:'+_0x556bf3+':'+_0x16a3d5+':'+_0x4574d7++,_0x3dcb50=_0x21a956['createRange'](_0x179e32,_0x56d97c);_0x503589['markers']['set'](_0x559b6f,_0x3dcb50),null!==_0x16a3d5&&_0x5a82d7['add'](_0x16a3d5);}}['_getVidAttributeName'](_0xb2c15){switch(_0xb2c15['type']){case'elementStart':return'vid_start';case'elementEnd':return'vid_end';default:return'vid';}}['_fixOperation'](_0x568bf8,_0x56fa63){_0x568bf8['baseVersion']=null;for(const _0x22980b in _0x568bf8){const _0x5aa999=_0x568bf8[_0x22980b];if(_0x5aa999 instanceof _0x2bac0b){const _0x262593=_0x56fa63['get'](_0x5aa999['root']['rootName']);_0x568bf8[_0x22980b]=this['_fixPosition'](_0x5aa999,_0x262593);}if(_0x5aa999 instanceof _0x2ac226){const _0x4fb803=_0x56fa63['get'](_0x5aa999['root']['rootName']);_0x568bf8[_0x22980b]=this['_fixRange'](_0x5aa999,_0x4fb803);}'root'===_0x22980b&&(_0x568bf8['root']=_0x56fa63['get'](_0x568bf8['root']['rootName']));}}['_fixRange'](_0xf0d8bc,_0x45f9e0){return this['editor']['model']['createRange'](this['_fixPosition'](_0xf0d8bc['start'],_0x45f9e0),this['_fixPosition'](_0xf0d8bc['end'],_0x45f9e0));}['_fixPosition'](_0x2f9614,_0x15522e){return this['editor']['model']['createPositionFromPath'](_0x15522e,_0x2f9614['path'],_0x2f9614['stickiness']);}['_handleInsertOperation'](_0xedc9b0){const _0x3bad40=this['_idsRoots']['get'](_0xedc9b0['position']['root']['rootName']),_0x30ad0a=this['_fixPosition'](_0xedc9b0['position'],_0x3bad40),_0x22aa3c=null===_0xedc9b0['_authorId']?null:_0xedc9b0['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x2444f0=_0x30ad0a['parent'],_0x3d31d1=this['_revisionId'],_0x2dfcf4=[];for(const _0x55da0b of _0xedc9b0['nodes'])if(_0x55da0b['is']('element'))_0x2dfcf4['push'](this['_makeIdsRoot'](_0x55da0b));else{for(let _0x53b323=0x0;_0x53b323<_0x55da0b['offsetSize'];_0x53b323++)_0x2dfcf4['push'](new _0x149904('$text',{'vid':this['_revisionId']++}));}const _0x1b52b9=this['_revisionId'];for(let _0x3bedf7=_0x3d31d1;_0x3bedf7<_0x1b52b9;_0x3bedf7++)this['_touched']['set'](_0x3bedf7,{'userId':_0x22aa3c});_0x2444f0['_insertChild'](_0x30ad0a['offset'],_0x2dfcf4);}['_handleMoveOperation'](_0x351b8){(_0x351b8=this['_cloneOperation'](_0x351b8,this['_idsRoots']))['_execute']();const _0x51ece2=null===_0x351b8['_authorId']?null:_0x351b8['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x15ec6c=_0x351b8['getMovedRangeStart'](),_0x15b4a7=_0x15ec6c['parent'],_0x58b355=_0x15ec6c['offset'];!function _0x1311f2(_0x4731ac,_0x5569b4,_0x11467a,_0x1f7d74){for(let _0x5a17d8=_0x11467a;_0x5a17d8<_0x1f7d74;_0x5a17d8++){const _0x122307=_0x5569b4['getChild'](_0x5a17d8);_0x122307['is']('element','$text')?_0x4731ac['set'](_0x122307['getAttribute']('vid'),{'userId':_0x51ece2}):(_0x4731ac['set'](_0x122307['getAttribute']('vid_start'),{'userId':_0x51ece2}),_0x1311f2(_0x4731ac,_0x122307,0x0,_0x122307['childCount']),_0x4731ac['set'](_0x122307['getAttribute']('vid_end'),{'userId':_0x51ece2}));}}(this['_touched'],_0x15b4a7,_0x58b355,_0x58b355+_0x351b8['howMany']);}['_handleMergeOperation'](_0x168138){const _0x5f4914=null===(_0x168138=this['_cloneOperation'](_0x168138,this['_idsRoots']))['_authorId']?null:_0x168138['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x1e6329=_0x168138['targetPosition']['parent'],_0x365f1e=_0x168138['sourcePosition']['parent'],_0x12cf6c=_0x1e6329['getAttribute']('vid_end'),_0x3a05cb=_0x365f1e['getAttribute']('vid_start');_0x1e6329['_setAttribute']('vid_end',_0x365f1e['getAttribute']('vid_end')),_0x365f1e['_setAttribute']('vid_end',_0x12cf6c),this['_touched']['set'](_0x3a05cb,{'userId':_0x5f4914}),this['_touched']['set'](_0x12cf6c,{'userId':_0x5f4914}),_0x168138['_execute']();}['_handleSplitOperation'](_0x2b056e){const _0x18aa5a=null===(_0x2b056e=this['_cloneOperation'](_0x2b056e,this['_idsRoots']))['_authorId']?null:_0x2b056e['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x21b150=_0x2b056e['graveyardPosition'],_0x194a2d=_0x2b056e['splitPosition']['parent'];_0x2b056e['_execute']();const _0x62873d=_0x194a2d['getAttribute']('vid_end'),_0x40075f=_0x2b056e['insertionPosition']['nodeAfter'];if(_0x21b150){const _0xbc1637=_0x40075f['getAttribute']('vid_end'),_0x4c91d7=_0x194a2d['getAttribute']('vid_end');_0x194a2d['_setAttribute']('vid_end',_0xbc1637),_0x40075f['_setAttribute']('vid_end',_0x4c91d7),this['_touched']['set'](_0x194a2d['getAttribute']('vid_end'),{'userId':_0x18aa5a}),this['_touched']['set'](_0x40075f['getAttribute']('vid_start'),{'userId':_0x18aa5a});}else{const _0x45605b=this['_revisionId']++,_0x452f55=this['_revisionId']++;_0x194a2d['_setAttribute']('vid_end',_0x45605b),_0x40075f['_setAttribute']('vid_start',_0x452f55),_0x40075f['_setAttribute']('vid_end',_0x62873d),this['_touched']['set'](_0x45605b,{'userId':_0x18aa5a}),this['_touched']['set'](_0x452f55,{'userId':_0x18aa5a});}}['_handleMarkerOperation'](_0x521d86){if(!_0x521d86['affectsData'])return;const _0x2c0924=(_0x521d86=this['_cloneOperation'](_0x521d86,this['_diffRoots']))['oldRange']?_0x521d86['oldRange']['root']:null,_0x5c51c2=_0x521d86['newRange']?_0x521d86['newRange']['root']:null;_0x2c0924&&this['_markers']['delete'](_0x521d86['name']),_0x5c51c2&&this['_markers']['set'](_0x521d86['name'],_0x521d86['newRange']['clone']());const _0x55ba69=null===_0x521d86['_authorId']?null:_0x521d86['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x10049a=_0x521d86['name'];if(!this['_touchedMarkers']['has'](_0x10049a))return void this['_touchedMarkers']['set'](_0x10049a,{'range':_0x521d86['oldRange'],'userId':_0x55ba69});const _0xa74d81=this['_touchedMarkers']['get'](_0x10049a),_0x5b2f86=_0xa74d81['range'],_0x26e10b=_0x521d86['newRange'];null==_0x5b2f86&&null==_0x26e10b||_0x5b2f86&&_0x26e10b&&_0x5b2f86['isEqual'](_0x26e10b)?this['_touchedMarkers']['delete'](_0x521d86['name']):_0xa74d81['userId']=_0x55ba69;}['_handleRootOperation'](_0x435e6e,_0x1db06e){this['_diffRoots']['has'](_0x435e6e['rootName'])?this['_diffRoots']['get'](_0x435e6e['rootName'])['_isAttached']=_0x435e6e['isAdd']:(this['_diffRoots']['set'](_0x435e6e['rootName'],N(_0x435e6e['rootName'],!0x0)),this['_diffRootsAttributes']['set'](_0x435e6e['rootName'],{}),_0x1db06e&&this['_idsRoots']['set'](_0x435e6e['rootName'],N(_0x435e6e['rootName'],!0x0)));const _0x328724=null===_0x435e6e['_authorId']?null:_0x435e6e['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x376021=this['_touchedRoots']['get'](_0x435e6e['rootName']);_0x376021&&_0x376021['userId']===_0x328724?this['_touchedRoots']['delete'](_0x435e6e['rootName']):this['_touchedRoots']['set'](_0x435e6e['rootName'],{'userId':_0x328724,'isAttached':_0x435e6e['isAdd']});}['_handleRootAttributeOperation'](_0x46b483){const _0x53bb57=this['_diffRootsAttributes']['get'](_0x46b483['root']['rootName']);null===_0x46b483['newValue']?delete _0x53bb57[_0x46b483['key']]:_0x53bb57[_0x46b483['key']]=_0x46b483['newValue'];}}function x(_0xa5cd8e){const _0x1e9fa7=N(_0xa5cd8e['rootName'],_0xa5cd8e['isAttached']());for(const _0xec71e6 of _0xa5cd8e['getChildren']()){const _0x5cd7bc=_0xec71e6['_clone'](!0x0);_0x1e9fa7['_appendChild'](_0x5cd7bc);}return _0x1e9fa7;}function N(_0x464917,_0x3c5ac3=!0x0){const _0x45035c=new _0x55db8f();return _0x45035c['rootName']=_0x464917,_0x45035c['_isAttached']=_0x3c5ac3,_0x45035c['isAttached']=()=>_0x45035c['_isAttached'],_0x45035c;}function P(_0x36cedd,_0x132ba5,_0x29c4b8){const _0x1479c8='elementEnd'==_0x36cedd['type']?_0x29c4b8['createPositionAt'](_0x36cedd['item'],'end'):_0x29c4b8['createPositionBefore'](_0x36cedd['item']);return _0x29c4b8['createPositionFromPath'](_0x132ba5,_0x1479c8['path'],_0x1479c8['stickiness']);}function V(_0x45916b,_0x292bea,_0x14261b){const _0x18c2ec='elementStart'==_0x45916b['type']?_0x14261b['createPositionAt'](_0x45916b['item'],0x0):_0x14261b['createPositionAfter'](_0x45916b['item']);return _0x14261b['createPositionFromPath'](_0x292bea,_0x18c2ec['path'],_0x18c2ec['stickiness']);}class he extends/* #__PURE__ -- @preserve */
25
+ _0x9b8b8b(_0x42faba){['focusTracker'];['keystrokes'];['revisionNameInputView'];constructor(_0x13b1e7,_0x4a9a5e){super(_0x13b1e7),this['focusTracker']=new _0x20a531(),this['keystrokes']=new _0x4b159a(),this['set']('revisionNameInputValue',''),this['revisionNameInputView']=this['_createRevisionNameInput'](_0x4a9a5e),this['setTemplate']({'tag':'form','attributes':{'class':['ck','ck-revision-history-save-revision-form','ck-responsive-form'],'tabindex':'-1'},'children':[this['revisionNameInputView']]}),this['initializeCssTransitionDisablerMixin']();}['render'](){super['render'](),_0x4794bb({'view':this}),this['focusTracker']['add'](this['revisionNameInputView']['element']),this['keystrokes']['listenTo'](this['element']);const _0x587eea=_0x3eb052=>_0x3eb052['stopPropagation']();this['keystrokes']['set']('arrowright',_0x587eea),this['keystrokes']['set']('arrowleft',_0x587eea),this['keystrokes']['set']('arrowup',_0x587eea),this['keystrokes']['set']('arrowdown',_0x587eea);}['focus'](){this['revisionNameInputView']['focus']();}get['revisionName'](){return this['revisionNameInputView']['fieldView']['element']['value']['trim']();}set['revisionName'](_0x2508f2){this['revisionNameInputView']['fieldView']['element']['value']=_0x2508f2['trim']();}['reset'](){this['revisionNameInputView']['fieldView']['element']['value']='',this['revisionNameInputView']['errorText']=null;}['_createRevisionNameInput'](_0xd1f500){const _0x2b1e19=new ti(this['locale'],_0x3269f8),_0x5f36a0=_0x2b1e19['fieldView'];_0x5f36a0['extendTemplate']({'attributes':{'maxlength':'220'}});let _0x5b7f3a=R(this['locale'],'Name\x20of\x20the\x20revision');return!_0xd1f500&&(_0x5b7f3a+='\x20('+R(this['locale'],'optional')+')'),(_0x2b1e19['label']=_0x5b7f3a,_0x5f36a0['on']('input',()=>{this['revisionNameInputValue']=_0x5f36a0['element']['value']['trim']();}),_0x2b1e19);}}class v extends _0x3eb3aa{static get['pluginName'](){return'RevisionHistoryUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[h];}['_saveRevisionFormView'];['init'](){const _0x1d39d0=this['editor'],_0x3ab78f=_0x1d39d0['plugins']['get']('RevisionTracker');_0x1d39d0['ui']['componentFactory']['add']('revisionHistory',_0x2720b6=>{const _0x4d8f45=_0xf860ea(_0x2720b6),_0x5aa469=_0x4d8f45['panelView']['children'],_0x547257=new _0x473d88(_0x2720b6),_0x49a2e9=new _0x29c64b(_0x2720b6),_0x4e1782=new _0x3eb7b4(_0x2720b6),_0x6b38e8=new _0x29c64b(_0x2720b6),_0x3d80ed=new _0x3eb7b4(_0x2720b6);return _0x4d8f45['bind']('isEnabled')['to'](_0x3ab78f,'isReady',_0x3ab78f,'isEnabled',_0x1d39d0,'isReadOnly',(_0x51b11b,_0x1b85c9,_0x41adfc)=>_0x51b11b&&_0x1b85c9&&!_0x41adfc),_0x4d8f45['buttonView']['set']({'icon':_0x27c55e,'label':R(_0x2720b6,'Revision\x20history'),'tooltip':!0x0}),_0x4e1782['set']({'label':R(_0x2720b6,'Save\x20current\x20revision'),'withText':!0x0,'role':'menuitem'}),_0x4e1782['bind']('isEnabled')['to'](_0x3ab78f,'isReady',_0x3ab78f,'isEnabled',_0x1d39d0,'isReadOnly',(_0x5f3596,_0x279d4b,_0x5735ac)=>_0x5f3596&&_0x279d4b&&!_0x5735ac),_0x4e1782['on']('execute',()=>this['_showDialog']()),_0x3d80ed['set']({'label':R(_0x2720b6,'Open\x20revision\x20history'),'withText':!0x0,'role':'menuitem'}),_0x3d80ed['bind']('isEnabled')['to'](_0x3ab78f,'isReady',_0x1d39d0,'isReadOnly',(_0x5a39f5,_0xb40cf8)=>_0x5a39f5&&!_0xb40cf8),_0x3d80ed['on']('execute',()=>{_0x1d39d0['config']['get']('revisionHistory')['showRevisionViewerCallback'](),_0x4d8f45['isOpen']=!0x1,_0x1d39d0['editing']['view']['focus']();}),_0x49a2e9['children']['add'](_0x4e1782),_0x6b38e8['children']['add'](_0x3d80ed),_0x547257['role']='menu',_0x547257['items']['addMany']([_0x49a2e9,_0x6b38e8]),_0x5aa469['add'](_0x547257),_0x4d8f45;}),_0x1d39d0['ui']['componentFactory']['add']('menuBar:revisionHistory',()=>this['_registerMenuComponent']());}['_registerMenuComponent'](){const _0x376e9f=this['editor'],_0x3f9c22=_0x376e9f['locale'],_0x3a29db=new _0x2627a2(_0x3f9c22),_0x486a35=new _0x23222d(_0x3f9c22);_0x3a29db['buttonView']['set']({'icon':_0x27c55e,'label':R(_0x3f9c22,'Revision\x20history')});const _0x1a94ff=new _0x5e3c23(_0x3f9c22,_0x3a29db),_0x4f1c57=new _0x18cd47(_0x3f9c22);_0x4f1c57['set']({'label':R(_0x3f9c22,'Save\x20current\x20revision')}),_0x4f1c57['delegate']('execute')['to'](_0x3a29db),_0x4f1c57['on']('execute',()=>{this['_showDialog']();}),_0x1a94ff['children']['add'](_0x4f1c57),_0x486a35['items']['add'](_0x1a94ff);const _0x4c9439=new _0x5e3c23(_0x3f9c22,_0x3a29db),_0x269a8f=new _0x18cd47(_0x3f9c22);return _0x269a8f['set']({'label':R(_0x3f9c22,'Open\x20revision\x20history')}),_0x269a8f['delegate']('execute')['to'](_0x3a29db),_0x269a8f['on']('execute',()=>{_0x376e9f['config']['get']('revisionHistory')['showRevisionViewerCallback']();}),_0x4c9439['children']['add'](_0x269a8f),_0x486a35['items']['add'](_0x4c9439),_0x3a29db['panelView']['children']['add'](_0x486a35),_0x3a29db;}['_showDialog'](){const _0x1fb934=this['editor'],_0x60813e=_0x1fb934['locale'],_0x97e2d2=_0x1fb934['plugins']['get']('Dialog'),_0x5f252d=_0x1fb934['plugins']['get']('RevisionTracker');function _0x3521e4(_0x1f00c5){_0x1fb934['config']['get']('revisionHistory.requireRevisionName')&&''===_0x1f00c5['revisionName']?_0x1f00c5['revisionNameInputView']['errorText']=R(_0x60813e,'The\x20revision\x20name\x20cannot\x20be\x20empty.'):(_0x1fb934['plugins']['get'](h)['saveRevision']({'name':_0x1f00c5['revisionName']}),_0x97e2d2['hide']());}this['_saveRevisionFormView']||(this['_createSaveRevisionFormView'](),this['_saveRevisionFormView']['on']('submit',()=>_0x3521e4(this['_saveRevisionFormView']))),this['_saveRevisionFormView']['reset'](),_0x97e2d2['show']({'id':'revisionSave','title':R(_0x60813e,'Save\x20current\x20revision'),'isModal':!0x0,'content':this['_saveRevisionFormView'],'actionButtons':[{'label':R(_0x1fb934['locale'],'Cancel'),'withText':!0x0,'onExecute':()=>_0x97e2d2['hide']()},{'label':R(_0x1fb934['locale'],'Accept'),'class':'ck-button-action','withText':!0x0,'onCreate'(_0x52d57a){_0x52d57a['bind']('isEnabled')['to'](_0x5f252d,'isReady',_0x5f252d,'isEnabled',_0x1fb934,'isReadOnly',(_0x200f6d,_0x55642d,_0x30dc09)=>_0x200f6d&&_0x55642d&&!_0x30dc09);},'onExecute':()=>_0x3521e4(this['_saveRevisionFormView'])}]});}['_createSaveRevisionFormView'](){const _0x453429=this['editor'],_0x28741d=_0x453429['locale'];this['_saveRevisionFormView']=new he(_0x28741d,_0x453429['config']['get']('revisionHistory.requireRevisionName')),this['_saveRevisionFormView']['render']();}}class z extends _0x42faba{['changeId'];['_model'];constructor(_0x2ba861,_0xee9bb3){super(_0x2ba861),this['_model']=_0xee9bb3,this['changeId']=_0xee9bb3['id'];const _0x12e791=this['bindTemplate'],_0x582e44=R(_0x2ba861,_0xee9bb3['data']['isSuggestion']?'Suggested\x20by':'add'==_0xee9bb3['type']?'Added\x20by':'Removed\x20by');this['set']('type',_0xee9bb3['type']),this['setTemplate']({'tag':'div','attributes':{'class':['ck-annotation','ck-revision-change',_0x12e791['to']('type',_0x25f6af=>'ck-revision-change__'+_0x25f6af)],'tabindex':-0x1},'children':[{'tag':'span','children':[{'tag':'span','attributes':{'class':['ck-revision-change__label']},'children':[{'text':_0x582e44}]},{'text':'\x20'+_0xee9bb3['author']['name']}]}]});}['focus'](){this['element']['focus']();}}class G extends/* #__PURE__ -- @preserve */
26
+ _0x520a9b(){['id'];['author'];['type'];['data'];['rootName'];constructor(_0x118a0c){super(),this['id']=_0x118a0c['id']||_0x5a28d0(),this['author']=_0x118a0c['author'],this['type']=_0x118a0c['type'],this['data']=_0x118a0c['data']||{},this['rootName']=_0x118a0c['rootName'],this['set']('createdAt',_0x118a0c['createdAt']);}['toJSON'](){return{'id':this['id'],'authorId':this['author']['id'],'type':this['type'],'data':this['data'],'createdAt':this['createdAt']};}}class J{['newRevisionId'];['oldRevisionId'];['changes'];constructor(_0x223230,_0x1955d0){this['newRevisionId']=_0x223230,this['oldRevisionId']=_0x1955d0,this['changes']=new _0x1787f2();}['_setChanges'](_0x48b3ec){for(const _0x370dd7 of _0x48b3ec)this['changes']['add'](_0x370dd7);}}class l extends _0x3eb3aa{['repository'];['adapter']=null;['_utils'];['_activeViewTarget'];['_changeView'];['_changeIdToChange'];['_balloon'];static get['pluginName'](){return'RevisionViewer';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[_0x96df93,_0x290bf7,S,$];}constructor(_0x428e4f){super(_0x428e4f),this['repository']=this['editor']['plugins']['get']('RevisionsRepository'),this['_utils']=this['editor']['plugins']['get']('RevisionHistoryUtils'),this['set']('activeChange',null),this['set']('activeView',null),this['_activeViewTarget']=null,this['set']('diff',null),this['set']('isReady',!0x1),this['set']('isEnabled',!0x0),this['on']('change:isEnabled',(_0x51da77,_0x2207d8,_0x5de4a1)=>{this['activeChange']=null,this['activeView']=null,this['editor']['editing']['view']['change'](_0x2e1b24=>{for(const _0x6f61a1 of this['editor']['editing']['view']['document']['roots'])_0x5de4a1?_0x2e1b24['removeClass']('ck-editor__editable__overlay',_0x6f61a1):_0x2e1b24['addClass']('ck-editor__editable__overlay',_0x6f61a1);});}),this['bind']('isNavigationMode')['to'](this,'activeChange',_0xabc912=>null!==_0xabc912),this['bind']('currentChangeNumber')['to'](this,'isReady',this,'diff',this,'activeChange',(_0x31554a,_0x5064f8,_0x19dc0d)=>_0x31554a&&_0x19dc0d?_0x5064f8['changes']['getIndex'](_0x19dc0d):0x0),this['bind']('numberOfChanges')['to'](this,'isReady',this,'diff',(_0x269548,_0x4ceb21)=>_0x269548?_0x4ceb21['changes']['length']:0x0),this['_changeView']=null,this['_changeIdToChange']=new Map(),this['_balloon']=this['editor']['plugins']['get'](_0x290bf7);}['init'](){const _0x517cff=this['editor'],_0x3344f2=new ot(_0x517cff,{'direction':'backward'}),_0x21efbf=new ot(_0x517cff,{'direction':'forward'});(_0x517cff['commands']['add']('showPreviousChange',_0x3344f2),_0x517cff['commands']['add']('showNextChange',_0x21efbf),_0x517cff['commands']['add']('restoreRevision',new nt(_0x517cff)),this['on']('change:numberOfChanges',()=>{_0x3344f2['refresh'](),_0x21efbf['refresh']();}),this['_setConversion'](),this['_initInteractions'](),_0x517cff['enableReadOnlyMode']('revision-viewer'),_0x517cff['plugins']['has']('WidgetToolbarRepository'))&&_0x517cff['plugins']['get']('WidgetToolbarRepository')['forceDisabled']('revision-viewer');}async['getRevisionDocumentData'](_0x5f6ae){return await this['_utils']['loadRevisionData'](_0x5f6ae,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x5f6ae);}async['getRevisionRootsAttributes'](_0x40f982){return await this['_utils']['loadRevisionData'](_0x40f982,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x40f982);}async['compare'](_0x46532b,_0x3225b1,_0x1fe5f7=!0x1){if(!this['isEnabled'])return;const _0x230166=this['diff'],_0xeac9c2=this['repository'],_0x1013c3='string'==typeof _0x46532b?_0xeac9c2['getRevision'](_0x46532b):_0x46532b,_0x4257e8='string'==typeof _0x3225b1?_0xeac9c2['getRevision'](_0x3225b1):_0x3225b1,_0x380ad1=_0x1013c3['id'],_0x42b58f=_0x4257e8?_0x4257e8['id']:null;if(!_0x1fe5f7&&this['diff']&&this['diff']['newRevisionId']===_0x380ad1&&this['diff']['oldRevisionId']===_0x42b58f)return Promise['resolve']();this['isReady']=!0x1,this['activeView']=null,this['activeChange']=null,this['diff']=new J(_0x380ad1,_0x42b58f);const _0x1f3069=this['_getRevisionsRange'](_0x1013c3,_0x4257e8,!0x0)['map'](_0x4e0967=>this['_utils']['loadRevisionData'](_0x4e0967,this['adapter']));return _0x1f3069['push'](new Promise(_0x96eac7=>{setTimeout(_0x96eac7,0x14);})),Promise['all'](_0x1f3069)['then'](()=>{if(!this['isEnabled'])return;this['_cleanUp']();const _0x2f2fa3=this['_getDiff'](_0x380ad1,_0x42b58f);for(const _0x2bd384 of _0x2f2fa3['changes'])this['_changeIdToChange']['set'](_0x2bd384['id'],_0x2bd384);this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x45e2b9=>{for(const _0x189a70 of this['editor']['model']['document']['getRootNames']())_0x45e2b9['detachRoot'](_0x189a70);for(const _0x5ee4f0 of Object['keys'](_0x2f2fa3['model'])){const _0x31eed5=_0x45e2b9['addRoot'](_0x5ee4f0);for(const _0x5c7d94 of Object['keys'](_0x2f2fa3['attributes'][_0x5ee4f0]))_0x45e2b9['setAttribute'](_0x5c7d94,_0x2f2fa3['attributes'][_0x5ee4f0][_0x5c7d94],_0x31eed5);_0x45e2b9['insert'](_0x2f2fa3['model'][_0x5ee4f0],_0x31eed5,0x0);}}),this['diff']['_setChanges'](this['_sortAndFilterDiffChanges'](_0x2f2fa3['changes'])),this['isReady']=!0x0;})['catch'](_0x2e44dc=>{console['error'](_0x2e44dc),this['_cleanUp'](),_0x230166&&(this['diff']=_0x230166),this['isReady']=!0x0;});}['addRevisionData'](_0x25d844,_0x18c850){const _0x544af4=this['repository']['createRevision'](_0x25d844);return _0x544af4['on']('_update',(_0x31ac9d,_0x3a5f38,_0x1059d5)=>_0x18c850(_0x3a5f38,_0x1059d5,_0x544af4)),this['repository']['addRevision'](_0x544af4),_0x544af4;}['_cleanUp'](){this['activeChange']=null,this['_cleanMarkers'](),this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=null,this['_changeIdToChange']['clear'](),this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x443114=>{for(const _0x55cfc3 of this['editor']['model']['document']['getRootNames']())_0x443114['detachRoot'](_0x55cfc3);});}['_sortAndFilterDiffChanges'](_0xacdcd8){const _0xfbc928=[],_0x809f1f=new Map();for(const _0x23fc3e of this['editor']['model']['document']['getRootNames']()){const _0x1b7a8c=this['editor']['editing']['view']['getDomRoot'](_0x23fc3e);if(!_0x1b7a8c)continue;const _0x4b912b=_0x1b7a8c['getClientRects']()['item'](0x0);_0x4b912b&&(_0xfbc928['push'](_0x23fc3e),_0x809f1f['set'](_0x23fc3e,_0x4b912b));}return _0xfbc928['sort']((_0x38dbc9,_0x32dcba)=>{const _0x16e2e4=_0x809f1f['get'](_0x38dbc9),_0x347440=_0x809f1f['get'](_0x32dcba);return _0x16e2e4['y']-_0x347440['y']||_0x16e2e4['x']-_0x347440['x'];}),(_0xacdcd8=_0xacdcd8['filter'](_0x521e9d=>_0xfbc928['includes'](_0x521e9d['rootName'])))['sort']((_0x297af6,_0x4d8a8f)=>_0xfbc928['indexOf'](_0x297af6['rootName'])-_0xfbc928['indexOf'](_0x4d8a8f['rootName'])),_0xacdcd8;}['_makeTape'](_0x5de3e1){const _0x308b01=Array['from'](_0x5de3e1['markers'])['filter'](([_0x3c434a,_0x39be1b])=>_0x3c434a['startsWith']('revision:')&&!_0x39be1b['isCollapsed']),_0x33bed1=Array['from'](this['editor']['model']['createRangeIn'](_0x5de3e1)['getWalker']({'singleCharacters':!0x0}));if(0x0!=_0x308b01['length'])for(const _0xc815b5 of _0x33bed1){const [_0x5667de,_0x23fc75]=_0x308b01[0x0],[,_0x1ec8f2,_0x53e3c4]=_0x5667de['split'](':');if(_0x23fc75['end']['isEqual'](_0xc815b5['nextPosition'])&&_0x308b01['shift'](),(_0xc815b5['previousPosition']['isEqual'](_0x23fc75['start'])||_0xc815b5['previousPosition']['isAfter'](_0x23fc75['start']))&&('insertion'==_0x1ec8f2?_0xc815b5['isAdded']={'userId':_0x53e3c4}:'deletion'==_0x1ec8f2&&(_0xc815b5['isRemoved']={'userId':_0x53e3c4})),0x0==_0x308b01['length'])break;}return _0x33bed1;}['_refreshStartEndIndex'](_0xde839f){const _0x184205=new Map();for(let _0x1c7a33=0x0;_0x1c7a33<_0xde839f['length'];_0x1c7a33++)'text'===_0xde839f[_0x1c7a33]['type']?(_0xde839f[_0x1c7a33]['item']['startIndex']=_0x1c7a33,_0xde839f[_0x1c7a33]['item']['endIndex']=_0x1c7a33):('elementStart'===_0xde839f[_0x1c7a33]['type']?_0xde839f[_0x1c7a33]['item']['startIndex']=_0x1c7a33:'elementEnd'===_0xde839f[_0x1c7a33]['type']&&(_0xde839f[_0x1c7a33]['item']['endIndex']=_0x1c7a33),_0x184205['set'](_0xde839f[_0x1c7a33]['id'],_0x1c7a33));for(const _0x29bd46 of _0x184205['values']())'elementStart'===_0xde839f[_0x29bd46]['type']?_0xde839f[_0x29bd46]['item']['endIndex']=_0x184205['get'](_0xde839f[_0x29bd46]['pairId']):'elementEnd'===_0xde839f[_0x29bd46]['type']&&(_0xde839f[_0x29bd46]['item']['startIndex']=_0x184205['get'](_0xde839f[_0x29bd46]['pairId']));}['_processTape'](_0x5e7869){for(let _0x48d480=0x0;_0x48d480<_0x5e7869['length'];_0x48d480++){if('elementStart'===_0x5e7869[_0x48d480]['type'])_0x5e7869[_0x48d480]['item']['startIndex']=_0x48d480;else{if('elementEnd'===_0x5e7869[_0x48d480]['type']){_0x5e7869[_0x48d480]['item']['endIndex']=_0x48d480;const _0x597aff=_0x5e7869[_0x48d480]['item']['startIndex'];_0x5e7869[_0x597aff]['pairId']=_0x5e7869[_0x48d480]['id'],_0x5e7869[_0x48d480]['pairId']=_0x5e7869[_0x597aff]['id'];}else _0x5e7869[_0x48d480]['item']['startIndex']=_0x48d480,_0x5e7869[_0x48d480]['item']['endIndex']=_0x48d480,_0x5e7869[_0x48d480]['pairId']=null;}_0x5e7869[_0x48d480]['markersStart']||(_0x5e7869[_0x48d480]['markersStart']=[],_0x5e7869[_0x48d480]['markersEnd']=[]);}}['_markInsertions'](_0xae29d1,_0x502a7a){const _0x312a83=_0xae29d1['filter'](_0x4c2170=>!_0x4c2170['isAdded']);for(let _0x3cf21a=0x0;_0x3cf21a<_0x502a7a['length'];_0x3cf21a++)_0x502a7a[_0x3cf21a]['isAdded']&&(_0x312a83[_0x3cf21a]['isAdded']=_0x502a7a[_0x3cf21a]['isAdded']);}['_getDiff'](_0xc9fc4b,_0x599387=null){const _0x1a7883=this['repository']['getRevision'](_0xc9fc4b),_0x1d4d7e=_0x599387?this['repository']['getRevision'](_0x599387):null,_0x2eb449=this['_getRevisionsRange'](_0x1a7883,_0x1d4d7e),_0x31d802=_0x2eb449[_0x2eb449['length']-0x1],_0x324e4c=new Map(),_0x10f0e6={'model':{},'attributes':{},'changes':[]},_0x2062f5=new Set(),_0x2454c2=new Map();for(let _0x18ba97=_0x2eb449['length']-0x1;_0x18ba97>=0x0;_0x18ba97--){const _0x4e6019=_0x2eb449[_0x18ba97];for(const _0x146a5c of Object['keys'](_0x4e6019['diffData']))if(_0x4e6019['diffData'][_0x146a5c]['attachChange']){const _0x568e17=_0x4e6019['diffData'][_0x146a5c]['attachChange'];_0x568e17['isAttached']?(_0x2062f5['add'](_0x146a5c),_0x2454c2['has'](_0x146a5c)&&_0x2454c2['get'](_0x146a5c)['userId']==_0x568e17['userId']?_0x2454c2['delete'](_0x146a5c):_0x2454c2['set'](_0x146a5c,_0x568e17)):_0x2454c2['has'](_0x146a5c)?(_0x2062f5['delete'](_0x146a5c),_0x2454c2['delete'](_0x146a5c)):(_0x2062f5['add'](_0x146a5c),_0x2454c2['set'](_0x146a5c,_0x568e17));}else _0x2062f5['add'](_0x146a5c);}for(const _0x387488 of _0x2062f5){const _0x443c7a=_0x2454c2['has'](_0x387488)&&!_0x2454c2['get'](_0x387488)['isAttached'];let _0x1fce59=_0x443c7a?_0x2eb449['length']-0x1:0x0;const _0x2a18b8=_0x443c7a?-0x1:0x1;for(;_0x2eb449[_0x1fce59];){const _0x3ff20f=_0x2eb449[_0x1fce59];if(_0x3ff20f['diffData'][_0x387488]){const _0x3e4a82=_0x443c7a?_0x3ff20f['diffData'][_0x387488]['attributesBefore']:_0x3ff20f['diffData'][_0x387488]['attributesAfter'];_0x10f0e6['attributes'][_0x387488]=_0x3e4a82?_0x2d156f(_0x3e4a82):{};break;}_0x1fce59+=_0x2a18b8;}}for(const _0x4689b4 of _0x2eb449){_0x4689b4['model']={};for(const _0x432b0c of _0x4689b4['authors'])_0x324e4c['set'](_0x432b0c['id'],_0x432b0c);for(const _0x32ba5e of _0x2062f5){const _0x26386d=_0x4689b4['diffData'][_0x32ba5e]?_0x4689b4['diffData'][_0x32ba5e]['insertions']:'[]',_0x5e491d=_0x4689b4['diffData'][_0x32ba5e]?_0x4689b4['diffData'][_0x32ba5e]['deletions']:'[]';_0x4689b4['model'][_0x32ba5e]={'insertions':this['_utils']['_makeModelFromViewString'](_0x26386d),'deletions':this['_utils']['_makeModelFromViewString'](_0x5e491d)};}}for(const _0x28c9cf of _0x2062f5){let _0x2c4ebe=null,_0x3f5a67=0x0;const _0x24f56e=new Map(Array['from'](_0x1a7883['model'][_0x28c9cf]['insertions']['markers'])['filter'](([_0x32dd54])=>!_0x32dd54['startsWith']('revision:')));let _0xcec361=0x0;for(const _0x356688 of _0x2eb449){const _0x3fe5e9=this['_makeTape'](_0x356688['model'][_0x28c9cf]['insertions']);_0x356688==_0x1a7883?(_0x2c4ebe=_0x3fe5e9,_0x3f5a67=_0x2c4ebe['length'],_0x2c4ebe['forEach'](_0x2a65f4=>{_0x2a65f4['id']=_0xcec361++;}),this['_processTape'](_0x2c4ebe)):this['_markInsertions'](_0x2c4ebe,_0x3fe5e9);const _0x399a3b=_0x2c4ebe['filter'](_0x275bf0=>!_0x275bf0['isAdded'])['map'](_0x2e98e4=>_0x2e98e4['id']);let _0x170c33=0x0;const _0x319561=this['_makeTape'](_0x356688['model'][_0x28c9cf]['deletions']);_0x319561['forEach'](_0x51c304=>{_0x51c304['isRemoved']?_0x51c304['id']=_0x3f5a67++:_0x51c304['id']=_0x399a3b[_0x170c33++];}),this['_processTape'](_0x319561),this['_setDistance'](_0x2c4ebe,'isAdded'),this['_setDistance'](_0x319561,'isRemoved'),_0x356688==_0x1a7883&&this['_markMarkers'](_0x2c4ebe,_0x24f56e),_0x2c4ebe=this['_joinTapes'](_0x2c4ebe,_0x319561),this['_refreshStartEndIndex'](_0x2c4ebe),this['_setDistance'](_0x2c4ebe,'isRemoved');}_0x2c4ebe=_0x2c4ebe['filter'](_0x32ec29=>!(_0x32ec29['isAdded']&&_0x32ec29['isRemoved']));const _0x53549a=new Map(_0x31d802['model'][_0x28c9cf]['deletions']['markers']),_0x2c82b4=new Set(_0x24f56e['keys']());for(const _0xf6239 of _0x53549a['keys']())_0x2c82b4['delete'](_0xf6239);this['_markSuggestions'](_0x2c4ebe,_0x2c82b4),this['_fixObsoleteTags'](_0x2c4ebe),_0x2c4ebe=this['_removeMissingPairs'](_0x2c4ebe),_0x2c4ebe=this['_markMismatchedRemovedTags'](_0x2c4ebe),_0x2c4ebe=this['_removeUnsupportedChanges'](_0x2c4ebe);const {root:_0x316362,changes:_0x1115ab}=this['_makeModelFromTape'](_0x2c4ebe,_0x324e4c,_0x28c9cf);_0x10f0e6['model'][_0x28c9cf]=_0x316362;const _0xe7e659=_0x2454c2['get'](_0x28c9cf);if(_0xe7e659){const _0x4e06b5=_0x324e4c['get'](_0xe7e659['userId']),_0x4105cd=new G({'author':_0x4e06b5,'type':_0xe7e659['isAttached']?'add':'remove','data':{'isOnRoot':!0x0},'createdAt':new Date(),'rootName':_0x28c9cf});_0x1115ab['unshift'](_0x4105cd),_0x10f0e6['attributes'][_0x28c9cf]['revisionHistoryAttachChange']=_0x4105cd['id'];}_0x10f0e6['changes']=_0x10f0e6['changes']['concat'](_0x1115ab);}return _0x10f0e6;}['_markMarkers'](_0x4083c7,_0x5c8c04){for(let _0x904a4f=0x0;_0x904a4f<_0x4083c7['length'];_0x904a4f++)for(const [_0x5d6e35,_0x3d1a7b]of _0x5c8c04)!_0x3d1a7b['isCollapsed']&&_0x3d1a7b['start']['isEqual'](_0x4083c7[_0x904a4f]['previousPosition'])&&_0x4083c7[_0x904a4f]['markersStart']['push'](_0x5d6e35),_0x3d1a7b['end']['isEqual'](_0x4083c7[_0x904a4f]['nextPosition'])&&_0x4083c7[_0x904a4f]['markersEnd']['push'](_0x5d6e35);}['_joinTapes'](_0x2221c6,_0x46ebd3){let _0x4cb2f7=[],_0x94ab86=0x0,_0x81fec3=0x0;for(;_0x94ab86<_0x2221c6['length']||_0x81fec3<_0x46ebd3['length'];){const _0x500ad6=_0x2221c6[_0x94ab86]||{},_0x3c6a49=_0x46ebd3[_0x81fec3]||{};if(_0x500ad6['id']==_0x3c6a49['id'])_0x94ab86++,_0x81fec3++,_0x4cb2f7['push'](_0x500ad6);else{if(_0x3c6a49['isRemoved']&&_0x500ad6['isAdded']){const {commonTape:_0x17ef7c,iEnd:_0x2925a9,jEnd:_0x5b563f}=this['_threeWayMerge'](_0x2221c6,_0x94ab86,_0x46ebd3,_0x81fec3);_0x4cb2f7=_0x4cb2f7['concat'](_0x17ef7c),_0x94ab86=_0x2925a9,_0x81fec3=_0x5b563f;}else _0x3c6a49['isRemoved']?(_0x81fec3++,_0x4cb2f7['push'](_0x3c6a49)):(_0x94ab86++,_0x4cb2f7['push'](_0x500ad6));}}return _0x4cb2f7;}['_markSuggestions'](_0x2bd6af,_0x5d9959){const _0x25bc9a=[];for(let _0x4de84a=0x0;_0x4de84a<_0x2bd6af['length'];_0x4de84a++){for(let _0x2d28c9=0x0;_0x2d28c9<_0x2bd6af[_0x4de84a]['markersStart']['length'];_0x2d28c9++){const _0x3622d4=_0x2bd6af[_0x4de84a]['markersStart'][_0x2d28c9];if(!_0x5d9959['has'](_0x3622d4))continue;const {group:_0x3e8df2,type:_0x37dfea,authorId:_0x4f9b28}=_0xd68005(_0x3622d4);'revision-suggestion'!=_0x3e8df2||'insertion'!=_0x37dfea&&'deletion'!=_0x37dfea||(_0x25bc9a['unshift']({'type':_0x37dfea,'name':_0x3622d4,'userId':_0x4f9b28}),_0x2bd6af[_0x4de84a]['markersStart']['splice'](_0x2d28c9,0x1),_0x2d28c9--);}_0x33a1ea(_0x2bd6af[_0x4de84a]);for(let _0x40f188=0x0;_0x40f188<_0x2bd6af[_0x4de84a]['markersEnd']['length'];_0x40f188++){const _0x15cc93=_0x2bd6af[_0x4de84a]['markersEnd'][_0x40f188];if(!_0x5d9959['has'](_0x15cc93))continue;const {group:_0x15f023,type:_0x22491e}=_0xd68005(_0x15cc93);if('revision-suggestion'!=_0x15f023||'insertion'!=_0x22491e&&'deletion'!=_0x22491e)continue;_0x2bd6af[_0x4de84a]['markersEnd']['splice'](_0x40f188,0x1),_0x40f188--;const _0x23adc4=_0x25bc9a['findIndex'](_0x3b7725=>_0x3b7725['name']==_0x15cc93);_0x23adc4>-0x1&&_0x25bc9a['splice'](_0x23adc4,0x1);}}function _0xd68005(_0x4ac402){const _0x5d4b9c=_0x4ac402['split'](':');return{'group':_0x5d4b9c[0x0],'type':_0x5d4b9c[0x1],'subType':_0x5d4b9c['length']>=0x5?_0x5d4b9c[0x2]:null,'id':_0x5d4b9c['length']<0x5?_0x5d4b9c[0x2]:_0x5d4b9c[0x3],'authorId':_0x5d4b9c['length']<0x5?_0x5d4b9c[0x3]:_0x5d4b9c[0x4],'markerCount':0x6==_0x5d4b9c['length']?_0x5d4b9c[0x5]:null};}function _0x33a1ea(_0x588b41){for(let _0x465f5a=0x0;_0x465f5a<_0x25bc9a['length'];_0x465f5a++){if(_0x588b41['isAdded']&&'insertion'==_0x25bc9a[_0x465f5a]['type']&&_0x588b41['isAdded']['userId']==_0x25bc9a[_0x465f5a]['userId'])return _0x588b41['isAddSuggestion']=_0x25bc9a[_0x465f5a],void delete _0x588b41['isAdded'];if(!_0x588b41['isAdded']&&!_0x588b41['isRemoved']&&'deletion'==_0x25bc9a[_0x465f5a]['type'])return void(_0x588b41['isRemoveSuggestion']=_0x25bc9a[_0x465f5a]);}}}['_setDistance'](_0x78c97b,_0x530e05){let _0x23d91d=0x0,_0x5b548d=!0x1;const _0x538528=new Map();for(const _0x5ab40f of _0x78c97b)_0x5ab40f[_0x530e05]?_0x5b548d&&(_0x23d91d++,_0x5b548d=!0x1):(_0x23d91d++,_0x5b548d=!0x0),_0x538528['set'](_0x5ab40f['id'],_0x23d91d);for(let _0x45247c=0x0;_0x45247c<_0x78c97b['length'];_0x45247c++){if('isRemoved'==_0x530e05&&_0x78c97b[_0x45247c]['isAdded']||'isAdded'==_0x530e05&&_0x78c97b[_0x45247c]['isRemoved'])continue;if('text'==_0x78c97b[_0x45247c]['type']){_0x78c97b[_0x45247c]['distance']=0x0;continue;}const _0x4b526e=_0x538528['get'](_0x78c97b[_0x45247c]['pairId']),_0x94a839=_0x538528['get'](_0x78c97b[_0x45247c]['id']);_0x78c97b[_0x45247c]['distance']=_0x4b526e-_0x94a839;}}['_getRevisionsRange'](_0x115fc2,_0x2dfed3,_0x5d29d5=!0x1){const _0x1f052a=[];let _0x58774d=this['repository']['getIndex'](_0x115fc2),_0x1a503b=this['repository']['getIndex'](_0x2dfed3);for(-0x1==_0x1a503b&&(_0x1a503b=this['repository']['_revisions']['length'],_0x5d29d5=!0x1);_0x58774d<_0x1a503b;)_0x1f052a['push'](this['repository']['getRevision'](_0x58774d)),_0x58774d++;return _0x5d29d5&&_0x1f052a['push'](this['repository']['getRevision'](_0x58774d)),_0x1f052a;}['_threeWayMerge'](_0x2b8566,_0x4f8de0,_0x16ce06,_0x2accff){const _0x18c1a4=this['editor']['model']['schema'];let _0x44df44=_0x4f8de0;for(;_0x2b8566[_0x44df44]&&_0x2b8566[_0x44df44]['isAdded'];)_0x44df44++;let _0x218907=_0x2accff;for(;_0x16ce06[_0x218907]&&_0x16ce06[_0x218907]['isRemoved'];)_0x218907++;_0x4b8c8b(_0x2b8566,_0x4f8de0,_0x44df44),_0x4b8c8b(_0x16ce06,_0x2accff,_0x218907);const _0x558780=_0x16ce06['slice'](_0x2accff,_0x218907)['concat'](_0x2b8566['slice'](_0x4f8de0,_0x44df44));return _0x558780['sort']((_0x1af8c8,_0x2b836b)=>_0x1af8c8['side']!=_0x2b836b['side']?_0x1af8c8['side']-_0x2b836b['side']:_0x1af8c8['level']!=_0x2b836b['level']?_0x1af8c8['level']-_0x2b836b['level']:_0x1af8c8['distance']!=_0x2b836b['distance']?_0x2b836b['distance']-_0x1af8c8['distance']:!!_0x1af8c8['isAdded']!=!!_0x2b836b['isAdded']?-0x1==_0x1af8c8['side']||0x0==_0x1af8c8['side']?_0x1af8c8['isAdded']?-0x1:0x1:_0x1af8c8['isAdded']?0x1:-0x1:_0x1af8c8['index']-_0x2b836b['index']),{'commonTape':_0x558780,'iEnd':_0x44df44,'jEnd':_0x218907};function _0x4b8c8b(_0x544393,_0x38d104,_0x20da25){let _0x3cecfe=-0x1,_0x39ccd0=Number['POSITIVE_INFINITY'],_0xbb6909=!0x0;for(let _0x357ff2=_0x38d104;_0x357ff2<_0x20da25;_0x357ff2++)if(_0x18c1a4['isInline'](_0x544393[_0x357ff2]['item'])||(_0xbb6909=!0x1),_0x544393[_0x357ff2]['item']['startIndex']<_0x38d104&&(_0x3cecfe=_0x357ff2),_0x544393[_0x357ff2]['item']['endIndex']>=_0x20da25){_0x39ccd0=_0x357ff2;break;}_0xbb6909&&(_0x3cecfe=_0x20da25-0x1);for(let _0x2d12f9=_0x38d104;_0x2d12f9<_0x20da25;_0x2d12f9++)_0x544393[_0x2d12f9]['side']=_0x2d12f9<=_0x3cecfe?-0x1:_0x2d12f9<_0x39ccd0?0x0:0x1,_0x544393[_0x2d12f9]['index']=_0x2d12f9;let _0x3ce7b6=0x0;for(let _0x276356=_0x38d104;_0x276356<=_0x3cecfe;_0x276356++)0x0==_0x544393[_0x276356]['distance']?_0x544393[_0x276356]['level']=_0x3ce7b6:(_0x3ce7b6++,_0x544393[_0x276356]['level']=_0x3ce7b6,_0x3ce7b6++);for(let _0x5e9c81=_0x38d104;_0x5e9c81<_0x20da25;_0x5e9c81++)0x0==_0x544393[_0x5e9c81]['side']&&(_0x544393[_0x5e9c81]['level']=_0x3ce7b6);_0x3ce7b6=0x0;for(let _0x3b707f=_0x20da25-0x1;_0x3b707f>=_0x39ccd0;_0x3b707f--)0x0==_0x544393[_0x3b707f]['distance']?_0x544393[_0x3b707f]['level']=_0x3ce7b6:(_0x3ce7b6--,_0x544393[_0x3b707f]['level']=_0x3ce7b6,_0x3ce7b6--);}}['_fixObsoleteTags'](_0x4e418d){const _0x4f1706=new Map(),_0x2dd36a=this['editor']['model']['schema'];for(let _0x3fc59c=0x1;_0x3fc59c<_0x4e418d['length'];_0x3fc59c++){let _0x122b21,_0x371247,_0x40c37a;const _0x4f8a93=_0x4e418d[_0x3fc59c],_0x50e8c6=_0x4e418d[_0x3fc59c-0x1];if('text'==_0x4f8a93['type'])continue;if(_0x4f8a93['type']!=_0x50e8c6['type'])continue;if(!_0x2dd36a['isBlock'](_0x50e8c6['item'])||_0x2dd36a['isLimit'](_0x50e8c6['item']))continue;if(!_0x2dd36a['isBlock'](_0x4f8a93['item'])||_0x2dd36a['isLimit'](_0x4f8a93['item']))continue;if((_0x4e418d[_0x3fc59c]['isAdded']||_0x4e418d[_0x3fc59c]['isAddSuggestion'])&&_0x4e418d[_0x3fc59c-0x1]['isRemoved'])_0x122b21=_0x4e418d[_0x3fc59c],_0x371247=_0x4e418d[_0x3fc59c-0x1],_0x40c37a=_0x3fc59c-0x1;else{if(!_0x4e418d[_0x3fc59c]['isRemoved']||!_0x4e418d[_0x3fc59c-0x1]['isAdded']&&!_0x4e418d[_0x3fc59c-0x1]['isAddSuggestion'])continue;_0x122b21=_0x4e418d[_0x3fc59c-0x1],_0x371247=_0x4e418d[_0x3fc59c],_0x40c37a=_0x3fc59c;}const _0x1c4ada=_0x122b21['level']==_0x371247['level'],_0x40bdba=Math['abs'](_0x122b21['level'])<Math['abs'](_0x371247['level'])&&0x0==_0x371247['distance'];(_0x1c4ada||_0x40bdba)&&(_0x4f1706['set'](_0x371247['id'],_0x122b21['id']),_0x4e418d['splice'](_0x40c37a,0x1),_0x3fc59c--,_0x122b21['isAdded']=!0x1);}for(let _0x2ae966=0x0;_0x2ae966<_0x4e418d['length'];_0x2ae966++)_0x4f1706['has'](_0x4e418d[_0x2ae966]['pairId'])&&(_0x4e418d[_0x2ae966]['pairId']=_0x4f1706['get'](_0x4e418d[_0x2ae966]['pairId']));}['_removeMissingPairs'](_0x5c7ff0){const _0x38e305=new Set(_0x5c7ff0['map'](_0x6ca577=>_0x6ca577['id']));for(let _0x48f509=0x0;_0x48f509<_0x5c7ff0['length'];_0x48f509++)_0x38e305['has'](_0x5c7ff0[_0x48f509]['pairId'])||0x0==_0x5c7ff0[_0x48f509]['distance']||(_0x5c7ff0[_0x48f509]['isIncorrect']=!0x0);return _0x5c7ff0['filter'](_0x4d505d=>!_0x4d505d['isIncorrect']);}['_markMismatchedRemovedTags'](_0x32cde7){const _0x4709c1=new Set();for(let _0x1602e5=0x0;_0x1602e5<_0x32cde7['length'];_0x1602e5++){if(_0x4709c1['has'](_0x32cde7[_0x1602e5]['id'])&&_0x32cde7[_0x1602e5]['isRemoved']&&(_0x32cde7[_0x1602e5]['isIncorrect']=!0x0),_0x32cde7[_0x1602e5]['isIncorrect'])continue;if(0x0==_0x32cde7[_0x1602e5]['distance'])continue;if('elementStart'!=_0x32cde7[_0x1602e5]['type'])continue;if(null==_0x32cde7[_0x1602e5]['pairId'])continue;let _0xd4854b=_0x1602e5+0x1,_0x33a54d=0x0;for(;_0x32cde7[_0xd4854b]['id']!=_0x32cde7[_0x1602e5]['pairId'];)'elementStart'==_0x32cde7[_0xd4854b]['type']?_0x33a54d++:'elementEnd'==_0x32cde7[_0xd4854b]['type']&&_0x33a54d--,_0xd4854b++;if(0x0!=_0x33a54d){if(_0x32cde7[_0x1602e5]['isRemoved'])_0x32cde7[_0x1602e5]['isIncorrect']=!0x0;else{for(;_0xd4854b!=_0x1602e5;)_0x32cde7[_0xd4854b]['isRemoved']&&0x0!=_0x32cde7[_0xd4854b]['distance']&&(_0x32cde7[_0xd4854b]['isIncorrect']=!0x0,_0x4709c1['add'](_0x32cde7[_0xd4854b]['pairId'])),_0xd4854b--;}}}return _0x32cde7['filter'](_0x4b6587=>!_0x4b6587['isIncorrect']);}['_removeUnsupportedChanges'](_0x381435){const _0x50ca25=this['editor']['model']['schema'];for(let _0x31a0c3=0x0;_0x31a0c3<_0x381435['length'];_0x31a0c3++){if(!(_0x381435[_0x31a0c3]['isAdded']||_0x381435[_0x31a0c3]['isAddSuggestion']||_0x381435[_0x31a0c3]['isRemoved']||_0x381435[_0x31a0c3]['isRemoveSuggestion']))continue;if(0x0==_0x381435[_0x31a0c3]['distance'])continue;const _0x2842ca=_0x381435[_0x31a0c3]['item'];_0x50ca25['isBlock'](_0x2842ca)||_0x50ca25['isLimit'](_0x2842ca)||(_0x381435[_0x31a0c3]['isAdded']&&delete _0x381435[_0x31a0c3]['isAdded'],_0x381435[_0x31a0c3]['isAddSuggestion']&&delete _0x381435[_0x31a0c3]['isAddSuggestion'],_0x381435[_0x31a0c3]['isRemoveSuggestion']&&delete _0x381435[_0x31a0c3]['isRemoveSuggestion'],_0x381435[_0x31a0c3]['isRemoved']&&(_0x381435[_0x31a0c3]['isIncorrect']=!0x0));}return _0x381435['filter'](_0x3ef357=>!_0x3ef357['isIncorrect']);}['_makeModelFromTape'](_0x40bb64,_0x2ef287,_0x582200){const _0x356e85=new _0x55db8f(),_0x1d2a1d=[],_0x13fc2d=new Map(),_0xeae6db=this['editor']['model'],_0x306f14=_0xeae6db['schema'],_0x5b1276=[_0x356e85],_0x5eec6a={},_0x519c4c={'isAdded':[],'isRemoved':[],'isAddSuggestion':[],'isRemoveSuggestion':[]};let _0x5c7018=null;const _0x4d1a68=[0x0];for(let _0xe0549=0x0;_0xe0549<_0x40bb64['length'];_0xe0549++)if('elementStart'===_0x40bb64[_0xe0549]['type']){_0x40bb64[_0xe0549]['previousPosition']=_0xeae6db['createPositionFromPath'](_0x356e85,_0x4d1a68);const _0x32928f=new _0x149904(_0x40bb64[_0xe0549]['item']['name'],_0x40bb64[_0xe0549]['item']['getAttributes']());_0x5b1276[0x0]['_appendChild'](_0x32928f),_0x4d1a68['push'](0x0),_0x5b1276['unshift'](_0x32928f),_0x40bb64[_0xe0549]['nextPosition']=_0xeae6db['createPositionFromPath'](_0x356e85,_0x4d1a68);}else'elementEnd'===_0x40bb64[_0xe0549]['type']?(_0x5b1276['shift'](),_0x40bb64[_0xe0549]['previousPosition']=_0xeae6db['createPositionFromPath'](_0x356e85,_0x4d1a68),_0x4d1a68['pop'](),_0x4d1a68[_0x4d1a68['length']-0x1]++,_0x40bb64[_0xe0549]['nextPosition']=_0xeae6db['createPositionFromPath'](_0x356e85,_0x4d1a68)):(_0x40bb64[_0xe0549]['previousPosition']=_0xeae6db['createPositionFromPath'](_0x356e85,_0x4d1a68),_0x5c7018?_0x5c7018['_data']+=_0x40bb64[_0xe0549]['item']['data']:_0x5c7018=new _0x3c2817(_0x40bb64[_0xe0549]['item']['data'],_0x40bb64[_0xe0549]['item']['getAttributes']()),_0x40bb64[_0xe0549+0x1]&&'text'===_0x40bb64[_0xe0549+0x1]['type']&&_0x9f197f(_0x5c7018,_0x40bb64[_0xe0549+0x1]['item'])||(_0x5b1276[0x0]['_appendChild'](_0x5c7018),_0x5c7018=null),_0x4d1a68[_0x4d1a68['length']-0x1]+=_0x40bb64[_0xe0549]['item']['offsetSize'],_0x40bb64[_0xe0549]['nextPosition']=_0xeae6db['createPositionFromPath'](_0x356e85,_0x4d1a68));for(let _0x10c0b0=0x0;_0x10c0b0<_0x40bb64['length'];_0x10c0b0++){const _0x1a5f84=_0x40bb64[_0x10c0b0]['previousPosition'],_0x4cebdc=_0x40bb64[_0x10c0b0]['nextPosition'];for(const _0x4195b2 of _0x40bb64[_0x10c0b0]['markersStart'])_0x13fc2d['set'](_0x4195b2,{'start':_0x1a5f84,'end':null});_0x6b108('isRemoveSuggestion',_0x10c0b0,_0x1a5f84,_0x4cebdc),_0x6b108('isAddSuggestion',_0x10c0b0,_0x1a5f84,_0x4cebdc),_0x6b108('isRemoved',_0x10c0b0,_0x1a5f84,_0x4cebdc),_0x6b108('isAdded',_0x10c0b0,_0x1a5f84,_0x4cebdc);for(const _0x41efd7 of _0x40bb64[_0x10c0b0]['markersEnd']){const _0x1884f2=_0x13fc2d['get'](_0x41efd7);_0x1884f2?_0x1884f2['end']=_0x4cebdc:_0x13fc2d['set'](_0x41efd7,{'start':_0x4cebdc,'end':_0x4cebdc});}}for(const [_0x355abf,_0x4aafae]of _0x13fc2d){const _0x4bc6de=this['editor']['model']['createRange'](_0x4aafae['start'],_0x4aafae['end']);_0x356e85['markers']['set'](_0x355abf,_0x4bc6de);}return _0x1d2a1d['sort']((_0x151f52,_0x7a2092)=>{const _0x4186c1=_0x356e85['markers']['get']('revision:'+_0x151f52['id']),_0x1caf17=_0x356e85['markers']['get']('revision:'+_0x7a2092['id']);return _0x4186c1['start']['isBefore'](_0x1caf17['start'])?-0x1:_0x4186c1['start']['isAfter'](_0x1caf17['start'])?0x1:_0x4186c1['end']['isBefore'](_0x1caf17['end'])?-0x1:_0x4186c1['end']['isAfter'](_0x1caf17['end'])?0x1:'add'===_0x151f52['type']?-0x1:0x1;}),{'root':_0x356e85,'changes':_0x1d2a1d};function _0x6b108(_0x85fc78,_0x1fb648,_0x55b536,_0x3922e4){const _0x1d90ec=!!_0x40bb64[_0x1fb648][_0x85fc78],_0x37d181=_0x1d90ec?_0x40bb64[_0x1fb648][_0x85fc78]['userId']:null,_0x2b66a6=_0x1fb648===_0x40bb64['length']-0x1,_0x291a21=_0x519c4c[_0x85fc78][0x0],_0x573e09=_0x306f14['isObject'](_0x40bb64[_0x1fb648]['item']);!_0x5eec6a[_0x85fc78]&&_0x1d90ec?_0x5eec6a[_0x85fc78]={'start':_0x55b536,'tapeItem':_0x40bb64[_0x1fb648],'userId':_0x37d181,'type':_0x85fc78}:_0x5eec6a[_0x85fc78]&&!_0x1d90ec?(_0x5eec6a[_0x85fc78]['end']=_0x55b536,_0x1b8573(_0x5eec6a[_0x85fc78]),_0x5eec6a[_0x85fc78]=null):_0x5eec6a[_0x85fc78]&&_0x1d90ec&&_0x5eec6a[_0x85fc78]['userId']!==_0x37d181&&(_0x5eec6a[_0x85fc78]['end']=_0x55b536,_0x291a21&&_0x291a21['userId']===_0x5eec6a[_0x85fc78]['userId']||_0x1b8573(_0x5eec6a[_0x85fc78]),_0x5eec6a[_0x85fc78]={'start':_0x55b536,'tapeItem':_0x40bb64[_0x1fb648],'userId':_0x37d181,'type':_0x85fc78}),_0x5eec6a[_0x85fc78]&&_0x573e09&&('elementStart'!==_0x40bb64[_0x1fb648]['type']||_0x291a21&&_0x291a21['userId']===_0x37d181||_0x519c4c[_0x85fc78]['unshift']({'userId':_0x37d181,'object':_0x40bb64[_0x1fb648]['item'],'change':_0x5eec6a[_0x85fc78]}),'elementEnd'===_0x40bb64[_0x1fb648]['type']&&_0x291a21&&_0x291a21['object']===_0x40bb64[_0x1fb648]['item']&&(_0x519c4c[_0x85fc78]['shift'](),_0x5eec6a[_0x85fc78]=_0x291a21['change'])),_0x5eec6a[_0x85fc78]&&_0x2b66a6&&(_0x5eec6a[_0x85fc78]['end']=_0x3922e4,_0x1b8573(_0x5eec6a[_0x85fc78]),_0x5eec6a[_0x85fc78]=null);}function _0x1b8573({start:_0x5a088c,end:_0x5b7c54,tapeItem:_0x38b363,userId:_0x277c10,type:_0x5c0e84}){const _0x257f3b=_0x38b363['item'],_0x22b3c3=_0xeae6db['schema']['isBlock'](_0x257f3b)&&!_0xeae6db['schema']['isLimit'](_0x257f3b),_0x37575f=_0x5a088c['nodeAfter']==_0x5b7c54['parent']&&_0x5b7c54['isAtStart'];if(_0x22b3c3&&_0x37575f)return;const _0x4ff670=_0xeae6db['createRange'](_0x5a088c,_0x5b7c54),_0x1ab5cc=_0x2ef287['get'](_0x277c10),_0x440c44=new G({'author':_0x1ab5cc,'type':'isAdded'==_0x5c0e84||'isAddSuggestion'==_0x5c0e84?'add':'remove','data':{'isSuggestion':'isAddSuggestion'==_0x5c0e84||'isRemoveSuggestion'==_0x5c0e84},'createdAt':new Date(),'rootName':_0x582200});_0x1d2a1d['push'](_0x440c44),_0x356e85['markers']['set']('revision:'+_0x440c44['id'],_0x4ff670);}function _0x9f197f(_0x30f039,_0x415f59){const _0x10ddd3=_0x30f039['getAttributes'](),_0x2a5035=_0x415f59['getAttributes']();for(const _0xfda501 of _0x10ddd3){if(_0xfda501[0x1]!==_0x415f59['getAttribute'](_0xfda501[0x0]))return!0x1;_0x2a5035['next']();}return _0x2a5035['next']()['done'];}}['_setConversion'](){this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision','view':_0x3ed27d=>{const _0x586de3=_0x3ed27d['markerName']['split'](':')[0x1],_0x489d6b=this['_getChangeFromId'](_0x586de3);if(!_0x489d6b)return null;const _0xb2b7='add'==_0x489d6b['type']?'insertion':'deletion',_0x392688=['ck-suggestion-marker','ck-suggestion-marker-'+_0xb2b7];return _0x489d6b['data']['isSuggestion']&&_0x392688['push']('ck-suggestion-marker-'+_0xb2b7+'-new'),this['activeChange']==_0x489d6b&&_0x392688['push']('ck-suggestion-marker--active'),{'classes':_0x392688,'attributes':{'data-change-id':_0x586de3}};}}),this['editor']['conversion']['for']('upcast')['add'](_0x44eb7a=>{_0x44eb7a['on']('element:pre',(_0xf8d0e8,_0x187e3c,_0x5c19ae)=>{const _0x293257=_0x187e3c['viewItem']['getChild'](0x0);if(!_0x293257||!_0x293257['is']('element','code'))return;if(!_0x5c19ae['consumable']['consume'](_0x293257,{'attributes':['vid_start','vid_end']}))return;const _0x1869d9=_0x187e3c['modelRange']['start']['nodeAfter'];_0x5c19ae['writer']['setAttribute']('vid_start',_0x293257['getAttribute']('vid_start'),_0x1869d9),_0x5c19ae['writer']['setAttribute']('vid_end',_0x293257['getAttribute']('vid_end'),_0x1869d9);},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['add'](_0x5a7a97=>{_0x5a7a97['on']('element',(_0x4e4a7c,_0x4fbebf,_0x2862eb)=>{if(!_0x2862eb['consumable']['consume'](_0x4fbebf['viewItem'],{'attributes':['vid_start','vid_end']}))return;if(_0x4fbebf['modelRange']['isCollapsed'])return;const _0x5234d0=_0x4fbebf['modelRange']['start']['nodeAfter'];_0x5234d0['hasAttribute']('vid_start')||_0x5234d0['hasAttribute']('vid')||(_0x2862eb['writer']['setAttribute']('vid_start',_0x4fbebf['viewItem']['getAttribute']('vid_start'),_0x5234d0),_0x2862eb['writer']['setAttribute']('vid_end',_0x4fbebf['viewItem']['getAttribute']('vid_end'),_0x5234d0));},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['elementToAttribute']({'view':{'name':'span','attributes':{'vid':!0x0}},'model':{'key':'vid','value':_0x2717c3=>_0x2717c3['getAttribute']('vid')}}),this['editor']['model']['schema']['on']('checkAttribute',(_0x2e825b,[,_0x19e4f8])=>{['vid_start','vid_end','vid']['includes'](_0x19e4f8)&&(_0x2e825b['return']=!0x0,_0x2e825b['stop']());},{'priority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x44ad58=>{_0x44ad58['on']('attribute:vid',(_0x1c7997,_0x3c72b9,_0x41610f)=>{if('\x20'!=_0x3c72b9['item']['data']||_0x3c72b9['item']['parent']['maxOffset']>0x1)return;if(!_0x41610f['consumable']['consume'](_0x3c72b9['item'],_0x1c7997['name']))return;const _0x56e037=_0x41610f['writer'],_0x21e9ba=_0x41610f['mapper']['toViewRange'](_0x3c72b9['range']);_0x56e037['wrap'](_0x21e9ba,_0x56e037['createAttributeElement']('span'));});}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',function(_0x4bb10c){const _0x2ae8cc=_0x4bb10c['plugins']['get']('RevisionViewer');return(_0x4807cb,_0x2e0eaa,_0xccd891)=>{const _0x45a0f0=_0x2e0eaa['markerName']['split'](':')[0x1],_0x3adc57=_0x2ae8cc['_getChangeFromId'](_0x45a0f0);if(!_0x3adc57)return null;const _0x4e2ca2='add'==_0x3adc57['type']?'split':'merge';if(!_0xccd891['consumable']['test'](_0x2e0eaa['markerRange'],_0x4807cb['name']))return;const _0x1f0a6b=_0x2e0eaa['markerRange']['getWalker'](),_0x2234b3=_0x2e0eaa['markerRange']['start'],_0x471800=_0x4bb10c['model']['schema'];let _0x3f0c16=null,_0x1d0f00=null,_0x2ad5e3=!0x1,_0x1858b5=!0x1;for(const _0x1f540f of _0x1f0a6b){const _0x3a701a=_0x1f540f['item'];_0x2ad5e3=_0x2ad5e3||_0x471800['isContent'](_0x3a701a);const _0x4f8345=_0xccd891['mapper']['toViewElement'](_0x3a701a);if(_0x4f8345&&_0x4f8345['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x1f540f['type']&&(_0x471800['isBlock'](_0x3a701a)&&!_0x471800['isLimit'](_0x3a701a)&&(_0x3a701a['nextSibling']||_0x2234b3['isAtEnd']?_0x3f0c16&&_0x3f0c16['parent']==_0x3a701a||(_0x3f0c16=_0x3a701a,_0x4c279c(_0x1f540f['previousPosition']),_0x1858b5=!0x0):_0x1d0f00=_0x1d0f00||_0x1f540f['previousPosition']));}function _0x4c279c(_0x2ea9a1){const _0x372b8d=_0xccd891['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x4e2ca2}),_0x47d41b=_0xccd891['mapper']['toViewPosition'](_0x2ea9a1);_0x3adc57['data']['isSuggestion']&&_0xccd891['writer']['addClass']('ck-suggestion-marker-'+_0x4e2ca2+'-new',_0x372b8d),_0x2ae8cc['activeChange']==_0x3adc57&&_0xccd891['writer']['addClass']('ck-suggestion-marker--active',_0x372b8d),_0xccd891['writer']['insert'](_0x47d41b,_0x372b8d),_0xccd891['mapper']['bindElementToMarker'](_0x372b8d,_0x2e0eaa['markerName']);}_0x2ad5e3||_0x1858b5||!_0x1d0f00||_0x4c279c(_0x1d0f00);};}(this['editor']),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision',(_0x54625a,_0x4e7063,_0x11afcf)=>{const _0x5a0f25=_0x11afcf['mapper']['markerNameToElements'](_0x4e7063['markerName']);if(_0x5a0f25){for(const _0x2adc02 of _0x5a0f25)(_0x2adc02['hasClass']('ck-suggestion-marker-split')||_0x2adc02['hasClass']('ck-suggestion-marker-merge'))&&(_0x11afcf['mapper']['unbindElementFromMarkerName'](_0x2adc02,_0x4e7063['markerName']),_0x11afcf['writer']['remove'](_0x2adc02));}},{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',(_0x25f1b3,_0x5db260,_0x2d6887)=>{const _0x21b813=_0x5db260['markerName']['split'](':')[0x1],_0x5abdf8=this['_getChangeFromId'](_0x21b813);if(!_0x5abdf8)return null;const _0x4d1728='add'==_0x5abdf8['type']?'split':'merge';if(_0x2d6887['consumable']['test'](_0x5db260['markerRange'],_0x25f1b3['name']))for(const _0x559970 of _0x5db260['markerRange']['getItems']()){if(!_0x559970['is']('element','softBreak'))continue;const _0x2431ed=_0x2d6887['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x4d1728}),_0x1896a8=_0x2d6887['mapper']['toViewPosition'](this['editor']['model']['createPositionBefore'](_0x559970));_0x5abdf8['data']['isSuggestion']&&_0x2d6887['writer']['addClass']('ck-suggestion-marker-'+_0x4d1728+'-new',_0x2431ed),this['activeChange']==_0x5abdf8&&_0x2d6887['writer']['addClass']('ck-suggestion-marker--active',_0x2431ed),_0x2d6887['writer']['insert'](_0x1896a8,_0x2431ed),_0x2d6887['mapper']['bindElementToMarker'](_0x2431ed,_0x5db260['markerName']);}},{'priority':'high'}),this['editor']['model']['document']['on']('change',()=>{this['editor']['editing']['view']['change'](_0x4fe2be=>{for(const _0xa7d0f7 of this['editor']['model']['document']['getRootNames']()){const _0x46a2b7=this['editor']['model']['document']['getRoot'](_0xa7d0f7),_0x9cb2fa=this['editor']['editing']['view']['document']['getRoot'](_0xa7d0f7);if(_0x9cb2fa){const _0x51460d=_0x46a2b7['getAttribute']('revisionHistoryAttachChange');if(_0x4fe2be['removeAttribute']('data-change-id',_0x9cb2fa),_0x4fe2be['removeClass']('ck-revision-history-root-add',_0x9cb2fa),_0x4fe2be['removeClass']('ck-revision-history-root-remove',_0x9cb2fa),_0x4fe2be['removeClass']('ck-revision-history-root--active',_0x9cb2fa),_0x51460d){const _0x5e0f07=this['_getChangeFromId'](_0x51460d);if(!_0x5e0f07)return null;_0x4fe2be['setAttribute']('data-change-id',_0x51460d,_0x9cb2fa),_0x4fe2be['addClass']('ck-revision-history-root-'+_0x5e0f07['type'],_0x9cb2fa),this['activeChange']==_0x5e0f07&&_0x4fe2be['addClass']('ck-revision-history-root--active',_0x9cb2fa);}}}});}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'comment','model':_0x1e4d7c=>'revision-comment:'+_0x1e4d7c,'converterPriority':'highest'}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'suggestion','model':_0x347b4d=>'revision-suggestion:'+_0x347b4d,'converterPriority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision-suggestion','view':_0x29a605=>({'name':'suggestion:'+_0x29a605,'group':'revision-suggestion'}),'converterPriority':'highest'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision-suggestion','view':_0x393f3d=>{const _0x1cc47a=_0x393f3d['markerName']['split'](':')[0x1];return'insertion'!=_0x1cc47a&&'deletion'!=_0x1cc47a?null:{'classes':['ck-suggestion-preview-marker','ck-suggestion-preview-marker-'+_0x1cc47a]};}}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:deletion',Q(this['editor'],'merge'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:insertion',Q(this['editor'],'split'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision-suggestion',(_0xc44dac,_0x2b5a0e,_0x1dc2fe)=>{const _0x493649=_0x1dc2fe['mapper']['markerNameToElements'](_0x2b5a0e['markerName']);if(_0x493649){for(const _0x99779c of _0x493649)_0x99779c['is']('uiElement')&&(_0x1dc2fe['mapper']['unbindElementFromMarkerName'](_0x99779c,_0x2b5a0e['markerName']),_0x1dc2fe['writer']['remove'](_0x99779c));}},{'priority':'high'});}['_getChangeFromId'](_0x2a1a3a){return this['_changeIdToChange']['get'](_0x2a1a3a);}['_getViewForChange'](_0x15ef22){return this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=new z(this['editor']['locale'],_0x15ef22),this['_changeView'];}['_initInteractions'](){this['editor']['model']['document']['selection']['observeMarkers']('revision'),this['on']('change:activeView',(_0x1df6dd,_0x4e7396,_0x1e33a8,_0x3d18c9)=>{_0x3d18c9&&this['_balloon']['remove'](_0x3d18c9),_0x1e33a8&&(this['_balloon']['add']({'view':_0x1e33a8,'stackId':'revisionHistoryLabel','position':{'target':()=>{const _0x216ceb=this['editor']['editing'],_0x4f16d0=this['_getChangeFromId'](_0x1e33a8['changeId']);let _0x1e24fd;if(_0x4f16d0['data']['isOnRoot']){const _0x3c6012=_0x216ceb['view']['getDomRoot'](_0x4f16d0['rootName']);_0x1e24fd=Array['from'](_0x3c6012['getClientRects']());}else{const _0x13f665=this['editor']['model']['markers']['get']('revision:'+_0x1e33a8['changeId']);_0x1e24fd=Array['from'](_0x216ceb['mapper']['markerNameToElements'](_0x13f665['name']))['map'](_0xbd6eb0=>_0x216ceb['view']['domConverter']['mapViewToDom'](_0xbd6eb0))['map'](_0x62e9be=>Array['from'](_0x62e9be['getClientRects']()))['flat']();}if(!this['_activeViewTarget'])return _0x1e24fd[0x0];return _0x1e24fd['find'](_0x3d5ce7=>_0x3d5ce7['top']-0x3<=this['_activeViewTarget']['y']&&_0x3d5ce7['bottom']+0x3>=this['_activeViewTarget']['y']&&_0x3d5ce7['left']-0x3<=this['_activeViewTarget']['x']&&_0x3d5ce7['right']+0x3>=this['_activeViewTarget']['x'])||_0x1e24fd[0x0];}}}),this['_balloon']['showStack']('revisionHistoryLabel'));}),this['on']('change:activeChange',(_0xb581a0,_0x5bb4f6,_0x21650f,_0x8a12f2)=>{this['activeView']=_0x21650f?this['_getViewForChange'](_0x21650f):null,this['editor']['model']['change'](()=>{const _0x4cb9c1=this['editor']['editing'];_0x8a12f2&&(_0x8a12f2['data']['isOnRoot']?_0x4cb9c1['view']['change'](_0x4e7d4d=>{_0x4e7d4d['removeClass']('ck-revision-history-root--active',_0x4cb9c1['view']['document']['getRoot'](_0x8a12f2['rootName']));}):_0x4cb9c1['reconvertMarker']('revision:'+_0x8a12f2['id'])),_0x21650f&&(_0x21650f['data']['isOnRoot']?_0x4cb9c1['view']['change'](_0x1bedb7=>{_0x1bedb7['addClass']('ck-revision-history-root--active',_0x4cb9c1['view']['document']['getRoot'](_0x21650f['rootName']));}):_0x4cb9c1['reconvertMarker']('revision:'+_0x21650f['id']));});}),this['listenTo'](this['editor']['editing']['view']['document'],'mouseover',(_0x17db57,_0x47dc16)=>{if(this['activeChange'])return;const _0x51dac6=this['_findChangeIdFromDomTarget'](_0x47dc16['target']),_0x477a8a=this['_changeIdToChange']['get'](_0x51dac6);_0x477a8a?(this['_activeViewTarget']={'x':_0x47dc16['domEvent']['x'],'y':_0x47dc16['domEvent']['y']},this['activeView']=this['_getViewForChange'](_0x477a8a)):(this['_activeViewTarget']=null,this['activeView']=null);}),this['listenTo'](this['editor']['editing']['view']['document'],'mousedown',(_0x5c6ee2,_0x4f4363)=>{const _0x4dcada=this['_findChangeIdFromDomTarget'](_0x4f4363['target']),_0x41242c=this['_changeIdToChange']['get'](_0x4dcada);_0x41242c?(this['_activeViewTarget']={'x':_0x4f4363['domEvent']['x'],'y':_0x4f4363['domEvent']['y']},_0x41242c===this['activeChange']?this['_balloon']['updatePosition']():this['activeChange']=_0x41242c):(this['_activeViewTarget']=null,this['activeChange']=null);});}['_findChangeIdFromDomTarget'](_0x46b96d){do{const _0x737fb7=_0x46b96d['getAttribute']('data-change-id');if(_0x737fb7)return _0x737fb7;_0x46b96d=_0x46b96d['parent'];}while(_0x46b96d);return null;}['_cleanMarkers'](){this['editor']['model']['change'](_0x3352a8=>{for(const _0x4f91ea of this['editor']['model']['markers'])_0x3352a8['removeMarker'](_0x4f91ea);});}}function Q(_0x3e25bc,_0x59ca06){return(_0x3864c6,_0x8fc7cd,_0x6b8bbf)=>{if(!_0x6b8bbf['consumable']['test'](_0x8fc7cd['markerRange'],_0x3864c6['name']))return;const _0x473bf6=_0x8fc7cd['markerRange']['getWalker'](),_0x24732e=_0x8fc7cd['markerRange']['start'],_0xb0cc1e=_0x3e25bc['model']['schema'];let _0xf6d6a0=null,_0xa03102=null,_0x4e3b3f=!0x1,_0x2aeea9=!0x1;for(const _0x1b2fc7 of _0x473bf6){const _0x15157d=_0x1b2fc7['item'];_0x4e3b3f=_0x4e3b3f||_0xb0cc1e['isContent'](_0x15157d);const _0xa6634c=_0x6b8bbf['mapper']['toViewElement'](_0x15157d);if(_0xa6634c&&_0xa6634c['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x1b2fc7['type']&&(_0xb0cc1e['isBlock'](_0x15157d)&&!_0xb0cc1e['isLimit'](_0x15157d)&&(_0x15157d['nextSibling']||_0x24732e['isAtEnd']?_0xf6d6a0&&_0xf6d6a0['parent']==_0x15157d||(_0xf6d6a0=_0x15157d,_0x35574e(_0x1b2fc7['previousPosition']),_0x2aeea9=!0x0):_0xa03102=_0xa03102||_0x1b2fc7['previousPosition']));}function _0x35574e(_0x21068c){const _0x2c08c3=_0x6b8bbf['mapper']['toViewPosition'](_0x21068c),_0x18afb8=_0x6b8bbf['writer']['createUIElement']('span',{'class':'ck-suggestion-preview-marker-'+_0x59ca06});_0x6b8bbf['writer']['insert'](_0x2c08c3,_0x18afb8),_0x6b8bbf['mapper']['bindElementToMarker'](_0x18afb8,_0x8fc7cd['markerName']);}_0x4e3b3f||_0x2aeea9||!_0xa03102||_0x35574e(_0xa03102);};}class nt extends _0x55dc51{constructor(_0x103ab7){super(_0x103ab7);const _0x1f6f55=_0x103ab7['plugins']['get'](l);this['affectsData']=!0x1,this['listenTo'](_0x1f6f55,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x1f6f55,'change:isEnabled',()=>this['refresh']());}['execute'](){const _0x47e512=this['editor'],_0x47ce78=_0x47e512['plugins']['get'](l),_0x131bd7=_0x47ce78['isReady']?_0x47ce78['diff']['newRevisionId']:null;_0x47e512['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x131bd7);}['refresh'](){const {isReady:_0x1d89b6,isEnabled:_0x301b93,repository:_0x588fa4,diff:_0x565b01}=this['editor']['plugins']['get'](l),_0x43cc97=_0x565b01&&_0x588fa4['getLaterVisibleRevision'](_0x565b01['newRevisionId']);this['isEnabled']=_0x1d89b6&&_0x301b93&&Boolean(_0x43cc97);}}class ot extends _0x55dc51{['_step'];constructor(_0x42022d,{direction:_0x581113}){super(_0x42022d);const _0x51a891=_0x42022d['plugins']['get'](l);this['affectsData']=!0x1,this['_step']='forward'===_0x581113?0x1:-0x1,this['listenTo'](_0x51a891,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x51a891,'change:isEnabled',()=>this['refresh']()),this['listenTo'](_0x51a891,'change:activeChange',()=>this['refresh']());}['execute'](){const _0x12b391=this['editor'],_0x340d39=_0x12b391['plugins']['get'](l),{isNavigationMode:_0x18bef7,currentChangeNumber:_0x464f6b}=_0x340d39;let _0x3e158b;if(_0x340d39['activeChange']=_0x18bef7?_0x340d39['diff']['changes']['get'](_0x464f6b+this['_step']):_0x340d39['diff']['changes']['first'],_0x340d39['activeChange']['data']['isOnRoot'])_0x3e158b=_0x12b391['editing']['view']['getDomRoot'](_0x340d39['activeChange']['rootName']);else{const _0x13823b=_0x12b391['model']['markers']['get']('revision:'+_0x340d39['activeChange']['id']);_0x3e158b=_0x77d5c1(_0x12b391['editing'],_0x13823b);}_0x24f7ed({'target':_0x3e158b,'viewportOffset':0x28});}['refresh'](){const {isNavigationMode:_0x4c53a7,currentChangeNumber:_0x71a573,numberOfChanges:_0x5d5cec,isReady:_0x950105,isEnabled:_0x4ad8b6}=this['editor']['plugins']['get'](l);this['isEnabled']=!!(_0x4ad8b6&&_0x950105&&_0x5d5cec)&&(!_0x4c53a7||(0x1===this['_step']?_0x71a573<_0x5d5cec-0x1:_0x71a573>0x0));}}class Ri extends _0x42faba{constructor(_0xd1b97c){super(_0xd1b97c);const _0x2ca14b=this['bindTemplate'],_0x28a67c=new _0x3eb7b4(_0xd1b97c),_0x2183e8=new _0x3eb7b4(_0xd1b97c);this['set']('isNavigationMode',!0x1),this['set']('isReady',!0x1),this['set']('currentChangeNumber',0x0),this['set']('numberOfChanges',0x0),this['set']('isForwardNavigationEnabled',!0x1),this['set']('isBackwardNavigationEnabled',!0x1),this['bind']('_isStatusLabelVisible')['to'](this,'isReady',this,'numberOfChanges',(_0x1902f3,_0x1b58f7)=>_0x1902f3&&_0x1b58f7>0x0),this['bind']('_statusText')['to'](this,'isReady',this,'currentChangeNumber',this,'numberOfChanges',this,'isNavigationMode',(_0x4b7f77,_0x3a9328,_0x4925e5,_0x32a90e)=>{if(!_0x4b7f77)return R(_0xd1b97c,'Loading...');if(!_0x4925e5)return R(_0xd1b97c,'No\x20changes');const _0x2b0186=R(_0xd1b97c,'NUMBER_OF_CHANGES',_0x4925e5);return _0x32a90e?R(_0xd1b97c,'X_OF_Y_CHANGES',[_0x3a9328+0x1,_0x4925e5]):_0x2b0186;}),_0x28a67c['set']({'label':R(_0xd1b97c,'Show\x20previous\x20change'),'tooltip':!0x0,'icon':_0xd81a7f}),_0x2183e8['set']({'label':R(_0xd1b97c,'Show\x20next\x20change'),'tooltip':!0x0,'icon':_0x2078e1}),_0x28a67c['bind']('isEnabled')['to'](this,'isBackwardNavigationEnabled'),_0x2183e8['bind']('isEnabled')['to'](this,'isForwardNavigationEnabled'),_0x28a67c['on']('execute',()=>this['fire']('execute','backward')),_0x2183e8['on']('execute',()=>this['fire']('execute','forward')),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-revision-history-ui','ck-revision-history-ui__changes-navigation']},'children':[{'tag':'span','attributes':{'class':['ck-revision-history-ui__changes-navigation__wrapper']},'children':[{'tag':'span','attributes':{'class':['ck-revision-history-ui__changes-navigation__label',_0x2ca14b['if']('_isStatusLabelVisible','ck-hidden',_0x29742d=>!_0x29742d)]},'children':[{'text':_0x2ca14b['to']('isNavigationMode',_0x12aa0d=>_0x12aa0d?R(_0xd1b97c,'EDIT_X_OF_Y_REVISIONS')+':\x20':R(_0xd1b97c,'Total')+':\x20')}]},{'text':_0x2ca14b['to']('_statusText')}]},new _0x38e8dd(),{'tag':'div','attributes':{'class':['ck-revision-history-ui__changes-navigation__navigation']},'children':[_0x28a67c,_0x2183e8]}]});}}const ge='ck-editor__editable__loading-overlay';class ji extends _0x3eb3aa{static get['pluginName'](){return'RevisionViewerLoadingOverlay';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['show'](){const _0x526c11=this['editor']['editing']['view'];_0x526c11['change'](_0x4e709e=>{for(const _0x308145 of _0x526c11['document']['roots'])_0x4e709e['addClass'](ge,_0x308145);});}['hide'](){const _0x140c41=this['editor']['editing']['view'];_0x140c41['change'](_0x14913c=>{for(const _0x3ed44f of _0x140c41['document']['roots'])_0x14913c['removeClass'](ge,_0x3ed44f);});}}class u extends _0x3eb3aa{static get['pluginName'](){return'RevisionViewerUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[l,ji];}['init'](){const _0xdfd873=this['editor'],_0x3c1cd2=_0xdfd873['plugins']['get'](l),_0x454029=_0xdfd873['plugins']['get'](ji);_0xdfd873['ui']['componentFactory']['add']('exitToEditing',_0x272748=>{const _0x4d6fd3=new _0x3eb7b4(_0x272748);return _0x4d6fd3['set']({'label':R(_0x272748,'Back\x20to\x20editing'),'icon':_0x2dadc0,'withText':!0x0,'tooltip':!0x0,'class':'ck-revision-history-ui__back-to-editing'}),this['listenTo'](_0x4d6fd3,'execute',()=>{_0xdfd873['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}),_0x4d6fd3;}),_0xdfd873['ui']['componentFactory']['add']('restoreRevision',_0x224e5c=>{const _0x7633c7=new _0x3eb7b4(_0x224e5c);return _0x7633c7['set']({'label':R(_0x224e5c,'Restore\x20this\x20revision'),'withText':!0x0,'tooltip':!0x0}),_0x7633c7['bind']('isEnabled')['to'](_0xdfd873['commands']['get']('restoreRevision')),this['listenTo'](_0x7633c7,'execute',()=>_0xdfd873['execute']('restoreRevision')),_0x7633c7;}),_0xdfd873['ui']['componentFactory']['add']('changesNavigation',_0x430b8c=>{const _0x28a118=new Ri(_0x430b8c),_0x45adc6=_0xdfd873['commands']['get']('showPreviousChange'),_0xb90221=_0xdfd873['commands']['get']('showNextChange');return _0x28a118['bind']('isBackwardNavigationEnabled')['to'](_0x45adc6,'isEnabled'),_0x28a118['bind']('isForwardNavigationEnabled')['to'](_0xb90221,'isEnabled'),_0x28a118['bind']('isReady','currentChangeNumber','numberOfChanges','isNavigationMode')['to'](_0x3c1cd2),this['listenTo'](_0x28a118,'execute',(_0x35fa48,_0x22656a)=>{_0xdfd873['execute']('forward'===_0x22656a?'showNextChange':'showPreviousChange');}),_0x28a118;}),_0x454029['show'](),_0x3c1cd2['on']('change:isReady',(_0x359ac3,_0x1f4bef,_0x39afb0)=>{_0x39afb0?_0x454029['hide']():_0x454029['show']();});}}class li extends ti{['_resizeObserver']=null;constructor(_0x1f3a4c,_0x35287e){super(_0x1f3a4c,_0x35287e);const _0x101256=this['bindTemplate'];this['set']({'label':R(_0x1f3a4c,'Revision\x20name'),'_tooltipString':''}),this['fieldView']['placeholder']=R(_0x1f3a4c,'Enter\x20the\x20revision\x20name'),this['extendTemplate']({'tag':'span','attributes':{'class':['ck-revision-history-sidebar__revision-name'],'data-cke-tooltip-text':_0x101256['to']('_tooltipString'),'data-cke-tooltip-position':'s','data-cke-tooltip-class':'ck-tooltip_multi-line'}});}['render'](){super['render'](),this['_resizeObserver']=new et(this['fieldView']['element'],()=>this['_updateTooltipText']()),this['listenTo'](this['fieldView'],'input',()=>this['_updateTooltipText']());}['destroy'](){super['destroy'](),this['_resizeObserver']&&this['_resizeObserver']['destroy']();}['_updateTooltipText'](){const _0x29dccf=this['fieldView']['element'];this['_tooltipString']=_0x29dccf['scrollWidth']>_0x29dccf['clientWidth']&&_0x29dccf['value']||'';}}class vi extends _0x42faba{constructor(_0x3ecc21,_0x39d3b9,_0x44edb7){super(_0x3ecc21);const _0x4eb6f7=new _0x257c58();_0x4eb6f7['set']({'content':_0x5944d6,'viewBox':'0\x200\x2011\x2010'});const _0x26a6e3=['ck','ck-revision-history-sidebar__revision-author'];_0x44edb7&&_0x26a6e3['push']('ck-revision-history-sidebar__revision-author_creator');const _0x1bd184=[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision-author__name'],'title':R(_0x3ecc21,_0x44edb7?'Revision\x20creator':'Revision\x20author')},'children':[_0x4eb6f7,_0x39d3b9['name']]}];this['setTemplate']({'tag':'li','attributes':{'class':_0x26a6e3},'children':_0x1bd184});}}function mi(_0x2acd0c,_0x47a03e){const _0x535dd0=_0x2acd0c['bindTemplate'],_0x524f6c=_0x2acd0c['locale'],_0x25e14e=_0xf860ea(_0x524f6c);_0x25e14e['panelPosition']='sw';const _0x3d1a27=function(_0xf69b2e,_0xc6fbc8){const _0x5e887b=function(_0xed61c0,_0x2b8eb5){const _0x1d2762=_0xed61c0['locale'],_0x154857={'Compare\x20against\x20selected':R(_0x1d2762,'Compare\x20against\x20selected'),'Name\x20this\x20revision':R(_0x1d2762,'Name\x20this\x20revision'),'Restore\x20this\x20revision':R(_0x1d2762,'Restore\x20this\x20revision')};return _0x2b8eb5['map'](_0x328952=>{const _0x2d23c4=_0x154857[_0x328952['name']];return _0x2d23c4&&_0x2d23c4!==_0x328952['name']&&(_0x328952['name']=_0x2d23c4),_0x328952;});}(_0xf69b2e,_0xc6fbc8),_0x420327=new _0x1787f2();for(const _0x3a0e2d of _0x5e887b){const _0x42f525={'type':'button','model':new to({'label':_0x3a0e2d['name'],'class':_0x3a0e2d['class'],'withText':!0x0,'role':'menuitem','_action':_0x3a0e2d['action']})};_0x42f525['model']['bind']('isEnabled')['to'](_0xf69b2e,'isActionsDropdownOpen',_0x2d1e6e=>'function'!=typeof _0x3a0e2d['isEnabled']||(!_0x2d1e6e||_0x3a0e2d['isEnabled'](_0xf69b2e))),_0x420327['add'](_0x42f525);}return _0x420327;}(_0x2acd0c,_0x47a03e);return _0x2acd0c['bind']('isActionsDropdownOpen')['to'](_0x25e14e,'isOpen'),_0x25e14e['buttonView']['set']({'label':R(_0x524f6c,'Show\x20more\x20items'),'tooltip':!0x0,'tooltipPosition':'sw','icon':_0x11c06a}),_0x25e14e['extendTemplate']({'attributes':{'class':['ck-revision-history-sidebar__revision__actions',_0x535dd0['if']('isActionsDropdownOpen','ck-on')]},'on':{'click':_0x535dd0['to'](_0x188e45=>_0x188e45['stopPropagation']())}}),_0x25e14e['on']('execute',_0x250d53=>{_0x2acd0c['isReady']&&'function'==typeof _0x250d53['source']['_action']&&_0x250d53['source']['_action'](_0x2acd0c);}),_0x10dfb2(_0x25e14e,_0x3d1a27,{'role':'menu'}),_0x25e14e['listenTo'](_0x2acd0c,'change:isActionsDropdownOpen',(_0xd2c7b3,_0x2bf45f,_0x57e2b9)=>{if(_0x57e2b9)for(const _0x3ab38a of _0x25e14e['listView']['items']){const _0x5a8d1e=_0x3ab38a['children']['first'],_0x13fada=_0x47a03e['find'](_0x5262b0=>_0x5262b0['action']===_0x5a8d1e['_action'])['isVisible'];_0x3ab38a['isVisible']=void 0x0===_0x13fada||_0x13fada(_0x2acd0c);}}),_0x25e14e;}class pi extends/* #__PURE__ -- @preserve */
27
+ _0x4683d1(_0x42faba){['id'];['revisionNameView'];['revisionActionsView'];['_revision'];['_requireRevisionName'];constructor(_0x2b32a1,_0x53ee77,_0x4135b8,_0x5b0eb6){super(_0x2b32a1);const _0x510eb3=this['bindTemplate'],_0x5b5278=function(_0x548848,_0x2a28ca){const _0x3c2256=Array['from'](_0x2a28ca['authors'])['filter'](_0x22b4a8=>_0x22b4a8!=_0x2a28ca['creator']);return _0x2a28ca['creator']&&_0x3c2256['unshift'](_0x2a28ca['creator']),_0x3c2256['map'](_0x1ac4f2=>new vi(_0x548848,_0x1ac4f2,_0x1ac4f2==_0x2a28ca['creator']));}(_0x2b32a1,_0x53ee77);this['id']=_0x53ee77['id'],this['_revision']=_0x53ee77,this['_requireRevisionName']=_0x5b0eb6,this['bind']('name','createdAt')['to'](_0x53ee77),this['bind']('_createdAtFormatted')['to'](this,'createdAt',_0x1bd3ba=>{return _0x90145e=_0x2b32a1['uiLanguage'],(_0x59d1fe=_0x1bd3ba)['toLocaleDateString'](_0x90145e,{'month':'long','day':'numeric'})+',\x20'+_0x59d1fe['toLocaleTimeString'](_0x90145e,{'hour':'numeric','minute':'numeric'});var _0x90145e,_0x59d1fe;}),this['set']('isSelected',!0x1),this['set']('isHighlighted',!0x1),this['set']('isActionsDropdownOpen',!0x1),this['set']('isReady',!0x1),this['set']('isEnabled',!0x1),this['revisionNameView']=new li(_0x2b32a1,_0x3269f8),this['revisionNameView']['fieldView']['extendTemplate']({'attributes':{'maxlength':'220'}}),this['revisionNameView']['fieldView']['bind']('value')['to'](this,'name',_0x40ba3d=>_0x40ba3d||this['_createdAtFormatted']),this['revisionNameView']['bind']('isEnabled')['to'](this,'isSelected',this,'isEnabled',(_0x2ab823,_0x544689)=>_0x2ab823&&_0x544689),this['revisionActionsView']=_0x4135b8&&_0x4135b8['length']?mi(this,_0x4135b8):'',this['revisionActionsView']&&this['revisionActionsView']['bind']('isEnabled')['to'](this),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision-wrapper',_0x510eb3['if']('isConfirm','ck-revision-history-sidebar__revision-wrapper_confirmation_visible')]},'children':[{'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision',_0x510eb3['if']('isEnabled','ck-disabled',_0x58aef2=>!_0x58aef2),_0x510eb3['if']('isSelected','ck-revision-history-sidebar__revision_selected'),_0x510eb3['if']('isHighlighted','ck-revision-history-sidebar__revision_highlighted'),_0x510eb3['if']('isActionsDropdownOpen','ck-revision-history-sidebar__actions_dropdown_open')]},'children':[this['revisionNameView'],{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision__date']},'children':[{'text':_0x510eb3['to']('_createdAtFormatted')}]},{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__revision__controls-wrapper']},'children':[{'tag':'ul','attributes':{'class':['ck','ck-revision-history-sidebar__revision-authors']},'children':_0x5b5278}]},this['revisionActionsView']],'on':{'click':_0x510eb3['to'](_0x33dddd=>{_0x33dddd['srcElement']['closest']('.ck-thread__remove-confirm')||this['isReady']&&this['isEnabled']&&this['fire']('select',{'id':this['id']});})}}]});}['render'](){super['render']();const _0x3e7347=this['revisionNameView']['fieldView']['element'];this['listenTo'](_0x3e7347,'change',()=>{this['_requireRevisionName']&&!_0x3e7347['value']||this['fire']('setName',{'id':this['id'],'name':_0x3e7347['value']}),_0x3e7347['value']||(_0x3e7347['value']=this['name']?this['name']:this['_createdAtFormatted']);});}['select'](){this['isSelected']=!0x0;}['deselect'](){this['isSelected']=!0x1;}['highlight'](){this['isHighlighted']=!0x0;}['unhighlight'](){this['isHighlighted']=!0x1;}}function bi(_0x576706,_0x4abe9d){const _0x7818=_0x46f1a1['fromJSDate'](_0x576706)['setLocale'](_0x4abe9d),_0x5c3e2f=_0x46f1a1['local'](),_0x54340c=_0x5c3e2f['minus']({'days':0x1})['startOf']('day');let _0x4b0a5e,_0x2c9000;return _0x7818['hasSame'](_0x5c3e2f,'day')?(_0x4b0a5e=_0x7818['startOf']('day')['toJSDate'](),_0x2c9000=_0x7818['toRelativeCalendar']()):_0x7818['hasSame'](_0x54340c,'day')?(_0x4b0a5e=_0x54340c['toJSDate'](),_0x2c9000=_0x7818['toRelativeCalendar']()):_0x7818['hasSame'](_0x5c3e2f,'week')?(_0x4b0a5e=_0x7818['startOf']('week')['toJSDate'](),_0x2c9000=_0x7818['weekdayLong']||''):_0x7818['hasSame'](_0x5c3e2f,'year')?(_0x4b0a5e=_0x7818['startOf']('month')['toJSDate'](),_0x2c9000=_0x7818['monthLong']||''):(_0x4b0a5e=_0x7818['startOf']('year')['toJSDate'](),_0x2c9000=String(_0x7818['year'])),{'startDate':_0x4b0a5e,'localizedPeriodName':_0x2c9000};}class fi extends _0x42faba{['startDate'];['revisionViews'];['_revisionActions'];['_requireRevisionName'];constructor(_0xda426b,_0x5cf659,_0x567d2f,_0x516c39){super(_0xda426b);const _0x491ba8=bi(_0x5cf659,this['locale']['uiLanguage'])['localizedPeriodName'];this['startDate']=_0x5cf659,this['revisionViews']=this['createCollection'](),this['_revisionActions']=_0x567d2f,this['_requireRevisionName']=_0x516c39,this['revisionViews']['delegate']('select')['to'](this),this['revisionViews']['delegate']('setName')['to'](this),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__time-period']},'children':[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__time-period__label']},'children':[{'text':_0x491ba8}]},{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__time-period__revisions']},'children':this['revisionViews']}]});}['addRevision'](_0x1af922){const _0x57d225=new pi(this['locale'],_0x1af922,this['_revisionActions'],this['_requireRevisionName']);this['revisionViews']['add'](_0x57d225);}['removeRevision'](_0xc098f5){const _0x4744fa=this['revisionViews']['find'](_0x4e7833=>_0x4e7833['id']===_0xc098f5['id']);this['revisionViews']['remove'](_0x4744fa);}}class ki extends _0x42faba{constructor(_0x45d105){super(_0x45d105);const _0x47b1bf=new _0x257c58();_0x47b1bf['content']=_0x27c55e,this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset_all','ck-revision-history-sidebar__header']},'children':[_0x47b1bf,{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__header__label']},'children':[R(_0x45d105,'Revision\x20history')]}]});}}class ui extends _0x42faba{['timePeriodViews'];['_revisions'];['_revisionActions'];['_requireRevisionName'];constructor(_0x1c5648,_0x389fcf,_0x292f68,_0x27532f){super(_0x1c5648);const _0x9f1c74=this['bindTemplate'];this['timePeriodViews']=this['createCollection'](),this['timePeriodViews']['delegate']('select')['to'](this),this['timePeriodViews']['delegate']('setName')['to'](this),this['_revisions']=_0x389fcf,this['_revisionActions']=_0x292f68,this['_requireRevisionName']=_0x27532f,this['on']('select',(_0x1d3b25,_0x8f34a4)=>{this['fire']('revisionSelected',_0x8f34a4);}),this['on']('setName',(_0x381795,_0xb6a021)=>{this['fire']('revisionSetName',_0xb6a021);}),this['set']('isEnabled',!0x1),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-rounded-corners','ck-revision-history-sidebar']},'children':[new ki(_0x1c5648),{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__timeline',_0x9f1c74['if']('isEnabled','ck-disabled',_0xcfc22b=>!_0xcfc22b)]},'children':this['timePeriodViews']}]});}['render'](){super['render']();for(const _0x5cde7b of this['_revisions'])this['_addRevision'](_0x5cde7b);this['_revisions']['on']('add',(_0x4721fd,_0x2254ac)=>{this['_addRevision'](_0x2254ac);}),this['_revisions']['on']('remove',(_0x384475,_0x43920f)=>{this['_removeRevision'](_0x43920f);});}get['revisionViews'](){return this['timePeriodViews']['map'](_0x1fce18=>_0x1fce18['revisionViews']['map'](_0x3df9cf=>_0x3df9cf))['flat']();}['selectRevision'](_0x490a0f){for(const _0x2d0bef of this['revisionViews'])_0x490a0f&&_0x490a0f['id']===_0x2d0bef['id']?_0x2d0bef['select']():_0x2d0bef['deselect']();}['highlightRevisions'](_0x1a3b55){for(const _0x33f983 of this['revisionViews'])_0x1a3b55['some'](({id:_0x3a581e})=>_0x3a581e===_0x33f983['id'])?_0x33f983['highlight']():_0x33f983['unhighlight']();}['_addRevision'](_0xa68177){const _0x38c9b6=bi(_0xa68177['createdAt'],this['locale']['uiLanguage'])['startDate'];let _0x30da50=this['timePeriodViews']['get'](0x0);_0x30da50&&_0x30da50['startDate']['getTime']()===_0x38c9b6['getTime']()||(_0x30da50=new fi(this['locale'],_0x38c9b6,this['_revisionActions'],this['_requireRevisionName']),this['timePeriodViews']['add'](_0x30da50)),_0x30da50['addRevision'](_0xa68177);}['_removeRevision'](_0x580004){const _0x581a60=bi(_0x580004['createdAt'],this['locale']['uiLanguage'])['startDate'];this['_getTimePeriodViewByStartDate'](_0x581a60)['removeRevision'](_0x580004);}['_getTimePeriodViewByStartDate'](_0x1485e1){return this['timePeriodViews']['find'](_0x1af77c=>_0x1af77c['startDate']['getTime']()===_0x1485e1['getTime']());}}class f extends _0x3eb3aa{['_revisionViewer'];['_revisionsRepository'];['_sidebarView'];static ['defaultRevisionActions']=/* #__PURE__ -- @preserve */
28
28
  ((()=>['compareAgainstSelected','restoreRevision','nameRevision'])());static ['availableRevisionActions']=/* #__PURE__ -- @preserve */
29
- rt();static get['pluginName'](){return'RevisionsSidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[l];}constructor(_0x256c15){super(_0x256c15),this['_revisionViewer']=_0x256c15['plugins']['get'](l),this['_revisionsRepository']=this['_revisionViewer']['repository'],this['_sidebarView']=null;}['init'](){const _0x1798d4=this['_revisionsRepository']['_revisions'],_0x39827e=this['_createRevisionActions'](),_0x1eae8e=this['editor']['config']['get']('revisionHistory.viewerSidebarContainer');this['_sidebarView']=new ai(this['editor']['locale'],_0x1798d4,_0x39827e,this['editor']['config']['get']('revisionHistory.requireRevisionName')),this['_sidebarView']['on']('revisionSelected',this['_handleRevisionSelected']['bind'](this)),this['_sidebarView']['on']('revisionSetName',this['_handleRevisionSetName']['bind'](this)),this['_sidebarView']['bind']('isEnabled')['to'](this['_revisionViewer']),this['_sidebarView']['timePeriodViews']['on']('add',(_0xeaa02e,_0x233ca9)=>{_0x233ca9['revisionViews']['on']('add',(_0x4e841a,_0x589966)=>{_0x589966['bind']('isEnabled','isReady')['to'](this['_revisionViewer']);});}),this['_sidebarView']['render'](),this['listenTo'](this['editor']['data'],'ready',this['_handleEditorDataReady']['bind'](this)),this['listenTo'](this['_revisionViewer'],'change:diff',this['_handleDiffChange']['bind'](this)),_0x1eae8e['appendChild'](this['_sidebarView']['element']);}['destroy'](){this['_sidebarView']['element']['remove'](),this['_sidebarView']['destroy']();}['_handleEditorDataReady'](){const _0x113553=this['_revisionsRepository']['getRevision'](0x0);if(_0x113553){const _0xacd1b=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x113553['id']);this['_revisionViewer']['compare'](_0x113553,_0xacd1b);}}['_handleRevisionSelected'](_0x40d7ff,_0x207afe){const _0x26b964=this['_revisionsRepository']['getRevision'](_0x207afe['id']),_0x3ebcdf=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x26b964['id']);this['_revisionViewer']['compare'](_0x26b964,_0x3ebcdf);}['_handleRevisionSetName'](_0x756f2c,_0x13b5e6){this['_revisionsRepository']['getRevision'](_0x13b5e6['id'])['setName'](_0x13b5e6['name']);}['_handleDiffChange'](_0x4300c7,_0x2886a2,_0x30c5f1){const _0x3f735f=this['_revisionsRepository']['getRevisionsInDiff'](_0x30c5f1);_0x3f735f['length']>0x2?(this['_sidebarView']['highlightRevisions'](_0x3f735f),this['_sidebarView']['selectRevision'](null)):(this['_sidebarView']['highlightRevisions']([]),this['_sidebarView']['selectRevision'](_0x3f735f[0x0]));}['_createRevisionActions'](){const _0xfbcb60=this['editor'],_0x4e0a3b=f['availableRevisionActions'],_0x209667=_0xfbcb60['config']['get']('revisionHistory.revisionActions')||f['defaultRevisionActions'];if(_0x209667['length'])return _0x209667['map'](_0x409f6c=>{const _0x19b284='string'==typeof _0x409f6c?Object['assign']({},_0x4e0a3b[_0x409f6c]):_0x409f6c;return _0x19b284['action']=_0x19b284['action']['bind'](this,_0xfbcb60),_0x19b284['isVisible']&&(_0x19b284['isVisible']=_0x19b284['isVisible']['bind'](this,_0xfbcb60)),_0x19b284;});}}function rt(){return{'compareAgainstSelected':{'name':'Compare\x20against\x20selected','action':({plugins:_0x779c06},_0x24151b)=>{const _0x39f231=_0x779c06['get'](l),_0x3111ac=_0x39f231['repository'];let _0x5a40c9=_0x39f231['diff']['newRevisionId'],_0x3e6c09=_0x24151b['id'];_0x3111ac['getIndex'](_0x5a40c9)>_0x3111ac['getIndex'](_0x3e6c09)&&([_0x5a40c9,_0x3e6c09]=[_0x3e6c09,_0x5a40c9]),_0x39f231['compare'](_0x5a40c9,_0x3e6c09);},'isVisible':({plugins:_0x18ad82},_0x475157)=>{const _0x52978f=_0x18ad82['get'](l);return!(_0x52978f['repository']['getRevisionsInDiff'](_0x52978f['diff'])['length']>0x2)&&!_0x475157['isSelected'];}},'restoreRevision':{'name':'Restore\x20this\x20revision','action':(_0x38f154,{id:_0xba4923})=>{_0x38f154['config']['get']('revisionHistory')['restoreRevisionCallback'](_0xba4923);},'isVisible':({plugins:_0x2da6e1},_0x27c816)=>!!_0x2da6e1['get'](l)['repository']['getLaterVisibleRevision'](_0x27c816['id'])},'nameRevision':{'name':'Name\x20this\x20revision','action':({plugins:_0xda5e2a},{id:_0x160fd2,revisionNameView:_0x7f42bb})=>{const _0x4ae193=_0xda5e2a['get'](l),_0x4742a3=_0x4ae193['repository']['getEarlierVisibleRevision'](_0x160fd2);_0x4ae193['compare'](_0x160fd2,_0x4742a3),_0x7f42bb['focus'](),_0x7f42bb['fieldView']['select']();}}};}class Z extends tt{['_view'];['_toolbarConfig'];['_elementReplacer'];get['view'](){return this['_view'];}constructor(_0x2eda27,_0x58c5eb){super(_0x2eda27),this['_view']=_0x58c5eb,this['_toolbarConfig']=st(_0x2eda27['config']['get']('toolbar')),this['_elementReplacer']=new it();}get['element'](){return this['view']['element'];}['init'](_0x29f229){const _0x148992=this['editor'],_0x5a6e96=this['view'],_0x4999fd=_0x148992['editing']['view'],_0x420821=_0x5a6e96['editable'],_0x4b9e4b=_0x4999fd['document']['getRoot']();_0x420821['name']=_0x4b9e4b['rootName'],_0x5a6e96['render']();const _0x1c3ba6=_0x420821['element'];this['setEditableElement'](_0x420821['name'],_0x1c3ba6),_0x5a6e96['editable']['bind']('isFocused')['to'](this['focusTracker']),_0x4999fd['attachDomRoot'](_0x1c3ba6),this['_elementReplacer']['replace'](_0x29f229,this['element']),this['_initToolbar'](),this['fire']('ready');}['destroy'](){super['destroy']();const _0x29942b=this['view'],_0xe16404=this['editor']['editing']['view'];this['_elementReplacer']['restore'](),_0xe16404['detachDomRoot'](_0x29942b['editable']['name']),_0x29942b['destroy']();}['_initToolbar'](){const _0x488924=this['view'];_0x488924['stickyPanel']['bind']('isActive')['to'](this['focusTracker'],'isFocused'),_0x488924['stickyPanel']['limiterElement']=_0x488924['element'],_0x488924['stickyPanel']['bind']('viewportTopOffset')['to'](this,'viewportOffset',({top:_0x612842})=>_0x612842),_0x488924['toolbar']['fillFromConfig'](this['_toolbarConfig'],this['componentFactory']),this['addToolbar'](_0x488924['toolbar']);}}class ii extends _0x4fb2a1{['_editable'];['stickyPanel'];['toolbar'];get['editable'](){return this['_editable'];}constructor(_0x27a902,_0x450eb3,_0x1b1101={}){super(_0x27a902),this['stickyPanel']=new _0x2fa7fc(_0x27a902),this['toolbar']=new _0x5abd83(_0x27a902,{'shouldGroupWhenFull':_0x1b1101['shouldToolbarGroupWhenFull']}),this['_editable']=new te(_0x27a902,_0x450eb3);}['render'](){super['render'](),this['stickyPanel']['content']['add'](this['toolbar']),this['top']['add'](this['stickyPanel']),this['main']['add'](this['editable']);}}class m extends/* #__PURE__ -- @preserve */
30
- _0x14c85d(_0x502371){['_ui'];get['ui'](){return this['_ui'];}constructor(_0x59b103,_0x50e5fe){super(_0x50e5fe),this['sourceElement']=_0x59b103,this['model']['document']['createRoot']();const _0x5dfacd=new ii(this['locale'],this['editing']['view'],{'shouldToolbarGroupWhenFull':!0x0});this['_ui']=new Z(this,_0x5dfacd);}['destroy'](){return this['updateSourceElement'](),this['ui']['destroy'](),super['destroy']();}static async['create'](_0x591be6,_0x55f980){const _0x52ef23=new this(_0x591be6,_0x55f980);return await _0x52ef23['initPlugins'](),await _0x52ef23['ui']['init'](_0x591be6),await _0x52ef23['data']['init'](_0x52ef23['config']['get']('initialData')||''),_0x52ef23['fire']('ready'),_0x52ef23;}}const d=['RevisionHistoryUI','RestrictedEditingMode'];class at extends _0xb2d8c8{['result'];static get['pluginName'](){return'RevisionViewerIntegration';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x543c10){function _0x340755(_0x5cac25){return _0x5cac25['map'](_0x8ef5d2=>String['fromCharCode'](_0x8ef5d2))['join']('');}super(_0x543c10),this['result']='end',_0x543c10[_0x340755([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x340755([0x76,0x69,0x65,0x77])][_0x340755([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x340755([0x61,0x75,0x74,0x6f]),_0x543c10[_0x340755([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x340755([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x340755([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x340755([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x340755([0x6f,0x6b])});}}class ht extends _0xb2d8c8{['_viewerEditor'];static get['pluginName'](){return'RevisionHistory';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[h,v];}constructor(_0x3d363c){if(super(_0x3d363c),!this['editor']['config']['get']('revisionHistory'))throw new _0x557c8b('revision-history-missing-configuration',this);this['_viewerEditor']=null,this['set']('isRevisionViewerOpen',!0x1),this['editor']['config']['define']('revisionHistory.showRevisionViewerCallback',_0xb088f5=>this['_showRevisionViewer']({..._0xb088f5,'translations':this['editor']['locale']['translations']})),this['editor']['config']['define']('revisionHistory.closeRevisionViewerCallback',_0x522ba2=>this['_closeRevisionViewer'](_0x522ba2)),this['editor']['config']['define']('revisionHistory.restoreRevisionCallback',_0x53863c=>this['_restoreRevision'](_0x53863c)),this['editor']['config']['define']('revisionHistory.requireRevisionName',!0x1),this['_enhanceShowRevisionViewerCallback'](),this['_enhanceCloseRevisionViewerCallback']();}set['adapter'](_0x5282c3){this['editor']['plugins']['get']('RevisionTracker')['adapter']=_0x5282c3;}get['adapter'](){return this['editor']['plugins']['get']('RevisionTracker')['adapter'];}['addRevisionData'](_0x29e37f){return this['editor']['plugins']['get']('RevisionTracker')['addRevisionData'](_0x29e37f);}['getRevision'](_0x292b33){return this['editor']['plugins']['get']('RevisionsRepository')['getRevision'](_0x292b33);}['getRevisions'](_0x4dc78d){return this['editor']['plugins']['get']('RevisionsRepository')['getRevisions'](_0x4dc78d||{'toJSON':!0x1});}['_getRevisionViewerEditorConfig'](){const _0x34fe95=this['editor'],_0x1e1602=_0x5ea847(_0x34fe95,d),_0x6f4c49=_0x34fe95['plugins']['get']('RevisionTracker'),_0xd9ed8e=_0x34fe95['plugins']['get']('Users')['users'];return _0x1e1602['toolbar']=['exitToEditing','restoreRevision','changesNavigation'],delete _0x1e1602['lazyRoots'],(_0x1e1602['plugins']['push'](at,l,u,class extends _0xb2d8c8{static get['requires'](){return[l,'Users'];}['init'](){const _0x299b7e=this['editor']['plugins']['get']('Users');for(const _0x36a408 of _0xd9ed8e)_0x36a408['isAnonymous']||_0x299b7e['getUser'](_0x36a408['id'])||_0x299b7e['addUser'](_0x36a408);const _0x5cb625=_0x6f4c49['repository']['getRevisions']();let _0x130793=null;const _0xfc7522=this['editor']['plugins']['get']('RevisionViewer');_0xfc7522['adapter']=_0x6f4c49['adapter'],_0xfc7522['bind']('isEnabled')['to'](_0x6f4c49),this['editor']['commands']['get']('restoreRevision')['bind']('isEnabled')['to'](_0x34fe95,'isReadOnly',_0x28588d=>!_0x28588d);for(const _0x24ff9b of _0x5cb625){const _0x1d1d88=null===_0x24ff9b['creator'];if(_0x1d1d88&&_0x24ff9b['toVersion']===_0x24ff9b['fromVersion'])continue;const _0x76180a=_0x24ff9b['toJSON']();_0xfc7522['addRevisionData'](_0x76180a,(_0x1f6f49,_0x350ebd,_0x526660)=>{if(_0x1d1d88){if(_0x130793)_0x130793['_update'](_0x1f6f49,_0x350ebd);else{if(!_0x350ebd){const _0x3c25d3=_0x526660['toJSON']();_0x3c25d3['id']=_0x189557(),_0x6f4c49['saveRevision'](_0x3c25d3,_0x526660['toVersion'])['then'](_0x104fe9=>{_0x130793=_0x104fe9;});}}}else _0x24ff9b['_update'](_0x1f6f49,_0x350ebd);});}}},f),_0x1e1602);}['_enhanceShowRevisionViewerCallback'](){const _0x11f0de=this['editor']['config']['get']('revisionHistory')['showRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.showRevisionViewerCallback',async()=>{this['editor']['enableReadOnlyMode']('revision-history-viewer-opened');const _0x322e88=this['editor']['plugins']['get']('RevisionTracker');if(this['editor']['plugins']['has']('Autosave')){const _0x476045=this['editor']['plugins']['get']('Autosave');await _0x476045['save']();}else await _0x322e88['update']();if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('Dialog')){const _0x1cfae9=this['editor']['plugins']['get']('Dialog');_0x1cfae9['isOpen']&&_0x1cfae9['hide']();}const _0x860e44=this['_getRevisionViewerEditorConfig']();return _0x11f0de(_0x860e44)['then'](_0x11698e=>{return(this['_viewerEditor']=_0x11698e,this['editor']['plugins']['has']('Annotations'))&&this['editor']['plugins']['get']('Annotations')['refreshVisibility'](),(this['editor']['plugins']['has']('DocumentOutline')&&(this['editor']['plugins']['get']('DocumentOutlineUI')['view']['element']['style']['display']='none'),_0x11698e);})['catch'](_0x264b6=>(console['error'](_0x264b6),this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),null));});}['_enhanceCloseRevisionViewerCallback'](){const _0x1079af=this['editor']['config']['get']('revisionHistory')['closeRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.closeRevisionViewerCallback',()=>(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('DocumentOutline')&&(this['editor']['plugins']['get']('DocumentOutlineUI')['view']['element']['style']['display']=''),this['_viewerEditor']['plugins']['get']('RevisionViewer')['_cleanUp'](),_0x1079af(this['_viewerEditor'])['then'](()=>{if(this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),this['_viewerEditor']=null,this['editor']['plugins']['has']('Annotations')){const _0x5f580a=this['editor']['plugins']['get']('Annotations');_0x5f580a['refreshVisibility'](),_0x5f580a['refreshPositioning']();}})));}['_showRevisionViewer'](_0x9904c1){const _0xc27b32=this['editor']['config']['get']('revisionHistory.editorContainer'),_0xe53d01=this['editor']['config']['get']('revisionHistory.viewerContainer'),_0x1c25c5=this['editor']['config']['get']('revisionHistory.viewerEditorElement');return m['create'](_0x1c25c5,_0x9904c1)['then'](_0x3a2dd1=>(_0xe53d01['style']['display']='block',_0xc27b32['style']['display']='none',this['isRevisionViewerOpen']=!0x0,_0x3a2dd1));}['_closeRevisionViewer'](_0x119d8c){const _0x16f018=this['editor']['config']['get']('revisionHistory.editorContainer');return this['editor']['config']['get']('revisionHistory.viewerContainer')['style']['display']='none',_0x16f018['style']['display']='',this['isRevisionViewerOpen']=!0x1,_0x119d8c['destroy']();}async['_restoreRevision'](_0x1d550f){const _0x8bb375=this['editor'],_0x49e212=this['_viewerEditor']['plugins']['get']('RevisionViewer'),_0x44451c=_0x8bb375['plugins']['get']('RevisionTracker'),_0x378cfb=_0x8bb375['plugins']['get']('RevisionHistoryUtils'),_0x243091=_0x49e212['repository']['getRevision'](_0x1d550f);let _0x599402,_0x922610,_0x3a9b33;try{await _0x378cfb['loadRevisionData'](_0x243091,this['adapter']),_0x599402=_0x378cfb['getRevisionDocumentData'](_0x243091),_0x922610=_0x378cfb['getRevisionRootsAttributes'](_0x243091);}catch(_0x239893){return void console['error'](_0x239893);}_0x8bb375['model']['change'](_0x4581b8=>{for(const _0x4bf7aa of Array['from'](_0x8bb375['model']['markers']['getMarkersGroup']('restrictedEditingException')))_0x4581b8['removeMarker'](_0x4bf7aa);}),_0x49e212['isReady']=!0x1,_0x8bb375['model']['enqueueChange'](_0x229cb1=>{_0x229cb1['setSelection'](null),_0x229cb1['removeSelectionAttribute'](_0x8bb375['model']['document']['selection']['getAttributeKeys']());const _0xae747f=Object['keys'](_0x599402);for(const _0x42bcb4 of _0x8bb375['model']['document']['roots'])'$graveyard'!=_0x42bcb4['rootName']&&_0x42bcb4['isAttached']()&&!_0xae747f['includes'](_0x42bcb4['rootName'])&&_0x229cb1['detachRoot'](_0x42bcb4);for(const _0x468e34 of _0xae747f){let _0x535540=_0x8bb375['model']['document']['getRoot'](_0x468e34);_0x535540&&_0x535540['isAttached']()||(_0x535540=_0x229cb1['addRoot'](_0x468e34));const _0x52baba=_0x922610[_0x468e34],_0x48078b=Object['keys'](_0x52baba),_0x3f8b82=_0x599402[_0x468e34];for(const _0xc8df31 of _0x535540['getAttributeKeys']())_0x48078b['includes'](_0xc8df31)||_0x229cb1['removeAttribute'](_0xc8df31,_0x535540);for(const _0x3e41e6 of _0x48078b)_0x229cb1['setAttribute'](_0x3e41e6,_0x922610[_0x468e34][_0x3e41e6],_0x535540);_0x229cb1['remove'](_0x229cb1['createRangeIn'](_0x535540)),_0x229cb1['insert'](_0x8bb375['data']['parse'](_0x3f8b82,_0x535540),_0x535540,0x0);}});const _0x1d26d8=R(_0x8bb375['locale'],'Restored');if(_0x243091['name'])_0x3a9b33=-0x1==_0x243091['name']['indexOf'](_0x1d26d8)?_0x1d26d8+':\x20'+_0x243091['name']:_0x243091['name'];else _0x3a9b33=_0x1d26d8+':\x20'+(_0x243091['createdAt']['toLocaleDateString'](_0x8bb375['locale']['uiLanguage'],{'month':'long','day':'numeric'})+',\x20'+_0x243091['createdAt']['toLocaleTimeString'](_0x8bb375['locale']['uiLanguage'],{'hour':'numeric','minute':'numeric'}));return await _0x44451c['saveRevision']({'name':_0x3a9b33}),_0x49e212['isReady']=!0x0,_0x8bb375['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}}export{nt as RestoreRevisionCommand,I as Revision,ht as RevisionHistory,v as RevisionHistoryUI,$ as RevisionHistoryUtils,h as RevisionTracker,l as RevisionViewer,m as RevisionViewerEditor,at as RevisionViewerIntegration,Ri as RevisionViewerLoadingOverlay,u as RevisionViewerUI,S as RevisionsRepository,f as RevisionsSidebar,ot as ShowChangeCommand};
29
+ rt();static get['pluginName'](){return'RevisionsSidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[l];}constructor(_0xef46dd){super(_0xef46dd),this['_revisionViewer']=_0xef46dd['plugins']['get'](l),this['_revisionsRepository']=this['_revisionViewer']['repository'],this['_sidebarView']=null;}['init'](){const _0x3f8a67=this['_revisionsRepository']['_revisions'],_0x4310a2=this['_createRevisionActions'](),_0x587fec=this['editor']['config']['get']('revisionHistory.viewerSidebarContainer');this['_sidebarView']=new ui(this['editor']['locale'],_0x3f8a67,_0x4310a2,this['editor']['config']['get']('revisionHistory.requireRevisionName')),this['_sidebarView']['on']('revisionSelected',this['_handleRevisionSelected']['bind'](this)),this['_sidebarView']['on']('revisionSetName',this['_handleRevisionSetName']['bind'](this)),this['_sidebarView']['bind']('isEnabled')['to'](this['_revisionViewer']),this['_sidebarView']['timePeriodViews']['on']('add',(_0x499eac,_0x30670c)=>{_0x30670c['revisionViews']['on']('add',(_0x28e94a,_0x56a805)=>{_0x56a805['bind']('isEnabled','isReady')['to'](this['_revisionViewer']);});}),this['_sidebarView']['render'](),this['listenTo'](this['editor']['data'],'ready',this['_handleEditorDataReady']['bind'](this)),this['listenTo'](this['_revisionViewer'],'change:diff',this['_handleDiffChange']['bind'](this)),_0x587fec['appendChild'](this['_sidebarView']['element']);}['destroy'](){this['_sidebarView']['element']['remove'](),this['_sidebarView']['destroy']();}['_handleEditorDataReady'](){const _0x2c3501=this['_revisionsRepository']['getRevision'](0x0);if(_0x2c3501){const _0x395c0d=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x2c3501['id']);this['_revisionViewer']['compare'](_0x2c3501,_0x395c0d);}}['_handleRevisionSelected'](_0x5c26ab,_0x56e821){const _0x51c28c=this['_revisionsRepository']['getRevision'](_0x56e821['id']),_0x131930=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x51c28c['id']);this['_revisionViewer']['compare'](_0x51c28c,_0x131930);}['_handleRevisionSetName'](_0x49aaf0,_0xaac679){this['_revisionsRepository']['getRevision'](_0xaac679['id'])['setName'](_0xaac679['name']);}['_handleDiffChange'](_0x44154c,_0x390001,_0x57aeca){const _0x3900cc=this['_revisionsRepository']['getRevisionsInDiff'](_0x57aeca);_0x3900cc['length']>0x2?(this['_sidebarView']['highlightRevisions'](_0x3900cc),this['_sidebarView']['selectRevision'](null)):(this['_sidebarView']['highlightRevisions']([]),this['_sidebarView']['selectRevision'](_0x3900cc[0x0]));}['_createRevisionActions'](){const _0x205d92=this['editor'],_0x4117ea=f['availableRevisionActions'],_0x4394ce=_0x205d92['config']['get']('revisionHistory.revisionActions')||f['defaultRevisionActions'];if(_0x4394ce['length'])return _0x4394ce['map'](_0x1f36fe=>{const _0x1f5b40='string'==typeof _0x1f36fe?Object['assign']({},_0x4117ea[_0x1f36fe]):_0x1f36fe;return _0x1f5b40['action']=_0x1f5b40['action']['bind'](this,_0x205d92),_0x1f5b40['isVisible']&&(_0x1f5b40['isVisible']=_0x1f5b40['isVisible']['bind'](this,_0x205d92)),_0x1f5b40;});}}function rt(){return{'compareAgainstSelected':{'name':'Compare\x20against\x20selected','action':({plugins:_0xe1e353},_0xb786a6)=>{const _0x27dfc3=_0xe1e353['get'](l),_0x26fb3a=_0x27dfc3['repository'];let _0xe9ca0f=_0x27dfc3['diff']['newRevisionId'],_0x304ca8=_0xb786a6['id'];_0x26fb3a['getIndex'](_0xe9ca0f)>_0x26fb3a['getIndex'](_0x304ca8)&&([_0xe9ca0f,_0x304ca8]=[_0x304ca8,_0xe9ca0f]),_0x27dfc3['compare'](_0xe9ca0f,_0x304ca8);},'isVisible':({plugins:_0x57decf},_0x4bfaac)=>{const _0x4b31be=_0x57decf['get'](l);return!(_0x4b31be['repository']['getRevisionsInDiff'](_0x4b31be['diff'])['length']>0x2)&&!_0x4bfaac['isSelected'];}},'restoreRevision':{'name':'Restore\x20this\x20revision','action':(_0x2da7e,{id:_0x4e6319})=>{_0x2da7e['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x4e6319);},'isVisible':({plugins:_0x103beb},_0x14d284)=>!!_0x103beb['get'](l)['repository']['getLaterVisibleRevision'](_0x14d284['id'])},'nameRevision':{'name':'Name\x20this\x20revision','action':({plugins:_0x31be95},{id:_0x246ade,revisionNameView:_0x504235})=>{const _0x409cc9=_0x31be95['get'](l),_0x368a26=_0x409cc9['repository']['getEarlierVisibleRevision'](_0x246ade);_0x409cc9['compare'](_0x246ade,_0x368a26),_0x504235['focus'](),_0x504235['fieldView']['select']();}}};}class Z extends tt{['_view'];['_toolbarConfig'];['_elementReplacer'];get['view'](){return this['_view'];}constructor(_0x56331d,_0x3740fd){super(_0x56331d),this['_view']=_0x3740fd,this['_toolbarConfig']=st(_0x56331d['config']['get']('toolbar')),this['_elementReplacer']=new it();}get['element'](){return this['view']['element'];}['init'](_0x3e36cf){const _0x4ba1c7=this['editor'],_0x2cc7cc=this['view'],_0x58733f=_0x4ba1c7['editing']['view'],_0x3c8f92=_0x2cc7cc['editable'],_0x2c5da0=_0x58733f['document']['getRoot']();_0x3c8f92['name']=_0x2c5da0['rootName'],_0x2cc7cc['render']();const _0x9e6309=_0x3c8f92['element'];this['setEditableElement'](_0x3c8f92['name'],_0x9e6309),_0x2cc7cc['editable']['bind']('isFocused')['to'](this['focusTracker']),_0x58733f['attachDomRoot'](_0x9e6309),this['_elementReplacer']['replace'](_0x3e36cf,this['element']),this['_initToolbar'](),this['fire']('ready');}['destroy'](){super['destroy']();const _0x53a058=this['view'],_0x52de34=this['editor']['editing']['view'];this['_elementReplacer']['restore'](),_0x52de34['detachDomRoot'](_0x53a058['editable']['name']),_0x53a058['destroy']();}['_initToolbar'](){const _0x358e90=this['view'];_0x358e90['stickyPanel']['bind']('isActive')['to'](this['focusTracker'],'isFocused'),_0x358e90['stickyPanel']['limiterElement']=_0x358e90['element'],_0x358e90['stickyPanel']['bind']('viewportTopOffset')['to'](this,'viewportOffset',({top:_0x27c9a9})=>_0x27c9a9),_0x358e90['toolbar']['fillFromConfig'](this['_toolbarConfig'],this['componentFactory']),this['addToolbar'](_0x358e90['toolbar']);}}class ii extends _0x58c8a2{['_editable'];['stickyPanel'];['toolbar'];get['editable'](){return this['_editable'];}constructor(_0x2d51d8,_0x13c1d7,_0x32b4cc={}){super(_0x2d51d8),this['stickyPanel']=new _0x457380(_0x2d51d8),this['toolbar']=new _0x561180(_0x2d51d8,{'shouldGroupWhenFull':_0x32b4cc['shouldToolbarGroupWhenFull']}),this['_editable']=new te(_0x2d51d8,_0x13c1d7);}['render'](){super['render'](),this['stickyPanel']['content']['add'](this['toolbar']),this['top']['add'](this['stickyPanel']),this['main']['add'](this['editable']);}}class m extends/* #__PURE__ -- @preserve */
30
+ _0x33789f(_0x50610b){['_ui'];get['ui'](){return this['_ui'];}constructor(_0x322e06,_0x2da533){super(_0x2da533),this['sourceElement']=_0x322e06,this['model']['document']['createRoot']();const _0x2b1ba3=new ii(this['locale'],this['editing']['view'],{'shouldToolbarGroupWhenFull':!0x0});this['_ui']=new Z(this,_0x2b1ba3);}['destroy'](){return this['updateSourceElement'](),this['ui']['destroy'](),super['destroy']();}static async['create'](_0x238ee4,_0x1c8a11){const _0x207791=new this(_0x238ee4,_0x1c8a11);return await _0x207791['initPlugins'](),await _0x207791['ui']['init'](_0x238ee4),await _0x207791['data']['init'](_0x207791['config']['get']('initialData')||''),_0x207791['fire']('ready'),_0x207791;}}const d=['RevisionHistoryUI','RestrictedEditingMode'];class at extends _0x3eb3aa{['result'];static get['pluginName'](){return'RevisionViewerIntegration';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x44d03d){function _0x316377(_0x136300){return _0x136300['map'](_0x2676ff=>String['fromCharCode'](_0x2676ff))['join']('');}super(_0x44d03d),this['result']='end',_0x44d03d[_0x316377([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x316377([0x76,0x69,0x65,0x77])][_0x316377([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x316377([0x61,0x75,0x74,0x6f]),_0x44d03d[_0x316377([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x316377([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x316377([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x316377([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x316377([0x6f,0x6b])});}}class ht extends _0x3eb3aa{['_viewerEditor'];static get['pluginName'](){return'RevisionHistory';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[h,v];}constructor(_0x324c1e){if(super(_0x324c1e),!this['editor']['config']['get']('revisionHistory'))throw new _0x209f36('revision-history-missing-configuration',this);this['_viewerEditor']=null,this['set']('isRevisionViewerOpen',!0x1),this['editor']['config']['define']('revisionHistory.showRevisionViewerCallback',_0x132518=>this['_showRevisionViewer']({..._0x132518,'translations':this['editor']['locale']['translations']})),this['editor']['config']['define']('revisionHistory.closeRevisionViewerCallback',_0x2f3c52=>this['_closeRevisionViewer'](_0x2f3c52)),this['editor']['config']['define']('revisionHistory.restoreRevisionCallback',_0x772b8c=>this['_restoreRevision'](_0x772b8c)),this['editor']['config']['define']('revisionHistory.requireRevisionName',!0x1),this['_enhanceShowRevisionViewerCallback'](),this['_enhanceCloseRevisionViewerCallback']();}set['adapter'](_0x52bb8d){this['editor']['plugins']['get']('RevisionTracker')['adapter']=_0x52bb8d;}get['adapter'](){return this['editor']['plugins']['get']('RevisionTracker')['adapter'];}['addRevisionData'](_0x4f803a){return this['editor']['plugins']['get']('RevisionTracker')['addRevisionData'](_0x4f803a);}['getRevision'](_0x2bada3){return this['editor']['plugins']['get']('RevisionsRepository')['getRevision'](_0x2bada3);}['getRevisions'](_0x293a6e){return this['editor']['plugins']['get']('RevisionsRepository')['getRevisions'](_0x293a6e||{'toJSON':!0x1});}['_getRevisionViewerEditorConfig'](){const _0x15bc5d=this['editor'],_0x470e40=_0x32c703(_0x15bc5d,d),_0x395a50=_0x15bc5d['plugins']['get']('RevisionTracker'),_0x379495=_0x15bc5d['plugins']['get']('Users')['users'];return _0x470e40['toolbar']=['exitToEditing','restoreRevision','changesNavigation'],delete _0x470e40['lazyRoots'],(_0x470e40['plugins']['push'](at,l,u,class extends _0x3eb3aa{static get['requires'](){return[l,'Users'];}['init'](){const _0x1b87b6=this['editor']['plugins']['get']('Users');for(const _0x2dd045 of _0x379495)_0x2dd045['isAnonymous']||_0x1b87b6['getUser'](_0x2dd045['id'])||_0x1b87b6['addUser'](_0x2dd045);const _0x164419=_0x395a50['repository']['getRevisions']();let _0x1acd03=null;const _0x1914d9=this['editor']['plugins']['get']('RevisionViewer');_0x1914d9['adapter']=_0x395a50['adapter'],_0x1914d9['bind']('isEnabled')['to'](_0x395a50),this['editor']['commands']['get']('restoreRevision')['bind']('isEnabled')['to'](_0x15bc5d,'isReadOnly',_0x4313b3=>!_0x4313b3);for(const _0x538d2c of _0x164419){const _0x2f1cf5=null===_0x538d2c['creator'];if(_0x2f1cf5&&_0x538d2c['toVersion']===_0x538d2c['fromVersion'])continue;const _0x4c7b1d=_0x538d2c['toJSON']();_0x1914d9['addRevisionData'](_0x4c7b1d,(_0xd40ecc,_0x46308a,_0x4d4a86)=>{if(_0x2f1cf5){if(_0x1acd03)_0x1acd03['_update'](_0xd40ecc,_0x46308a);else{if(!_0x46308a){const _0x4a2fd2=_0x4d4a86['toJSON']();_0x4a2fd2['id']=_0x5a28d0(),_0x395a50['saveRevision'](_0x4a2fd2,_0x4d4a86['toVersion'])['then'](_0x56b26a=>{_0x1acd03=_0x56b26a;});}}}else _0x538d2c['_update'](_0xd40ecc,_0x46308a);});}}},f),_0x470e40);}['_enhanceShowRevisionViewerCallback'](){const _0x4718d7=this['editor']['config']['get']('revisionHistory')['showRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.showRevisionViewerCallback',async()=>{this['editor']['enableReadOnlyMode']('revision-history-viewer-opened');const _0x4f3a05=this['editor']['plugins']['get']('RevisionTracker');if(this['editor']['plugins']['has']('Autosave')){const _0x4bc122=this['editor']['plugins']['get']('Autosave');await _0x4bc122['save']();}else await _0x4f3a05['update']();if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('Dialog')){const _0x3977d3=this['editor']['plugins']['get']('Dialog');_0x3977d3['isOpen']&&_0x3977d3['hide']();}const _0x28d50f=this['_getRevisionViewerEditorConfig']();return _0x4718d7(_0x28d50f)['then'](_0x55e0bf=>{return(this['_viewerEditor']=_0x55e0bf,this['editor']['plugins']['has']('Annotations'))&&this['editor']['plugins']['get']('Annotations')['refreshVisibility'](),(this['editor']['plugins']['has']('DocumentOutline')&&(this['editor']['plugins']['get']('DocumentOutlineUI')['view']['element']['style']['display']='none'),_0x55e0bf);})['catch'](_0x317436=>(console['error'](_0x317436),this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),null));});}['_enhanceCloseRevisionViewerCallback'](){const _0x5d4d8a=this['editor']['config']['get']('revisionHistory')['closeRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.closeRevisionViewerCallback',()=>(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('DocumentOutline')&&(this['editor']['plugins']['get']('DocumentOutlineUI')['view']['element']['style']['display']=''),this['_viewerEditor']['plugins']['get']('RevisionViewer')['_cleanUp'](),_0x5d4d8a(this['_viewerEditor'])['then'](()=>{if(this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),this['_viewerEditor']=null,this['editor']['plugins']['has']('Annotations')){const _0x351edd=this['editor']['plugins']['get']('Annotations');_0x351edd['refreshVisibility'](),_0x351edd['refreshPositioning']();}})));}['_showRevisionViewer'](_0x3c5e98){const _0x2543b9=this['editor']['config']['get']('revisionHistory.editorContainer'),_0xcb6ace=this['editor']['config']['get']('revisionHistory.viewerContainer'),_0x4022f6=this['editor']['config']['get']('revisionHistory.viewerEditorElement');return m['create'](_0x4022f6,_0x3c5e98)['then'](_0x3e0dbf=>(_0xcb6ace['style']['display']='block',_0x2543b9['style']['display']='none',this['isRevisionViewerOpen']=!0x0,_0x3e0dbf));}['_closeRevisionViewer'](_0x5ed5c3){const _0x4eba6e=this['editor']['config']['get']('revisionHistory.editorContainer');return this['editor']['config']['get']('revisionHistory.viewerContainer')['style']['display']='none',_0x4eba6e['style']['display']='',this['isRevisionViewerOpen']=!0x1,_0x5ed5c3['destroy']();}async['_restoreRevision'](_0x55f6e3){const _0x30f809=this['editor'],_0x1677e3=this['_viewerEditor']['plugins']['get']('RevisionViewer'),_0x39db61=_0x30f809['plugins']['get']('RevisionTracker'),_0x383b24=_0x30f809['plugins']['get']('RevisionHistoryUtils'),_0x5bb02a=_0x1677e3['repository']['getRevision'](_0x55f6e3);let _0x22d288,_0x314c2f,_0x3b74f5;try{await _0x383b24['loadRevisionData'](_0x5bb02a,this['adapter']),_0x22d288=_0x383b24['getRevisionDocumentData'](_0x5bb02a),_0x314c2f=_0x383b24['getRevisionRootsAttributes'](_0x5bb02a);}catch(_0x5d1ff7){return void console['error'](_0x5d1ff7);}_0x30f809['model']['change'](_0x4484e5=>{for(const _0x25494b of Array['from'](_0x30f809['model']['markers']['getMarkersGroup']('restrictedEditingException')))_0x4484e5['removeMarker'](_0x25494b);}),_0x1677e3['isReady']=!0x1,_0x30f809['model']['enqueueChange'](_0x36128a=>{_0x36128a['setSelection'](null),_0x36128a['removeSelectionAttribute'](_0x30f809['model']['document']['selection']['getAttributeKeys']());const _0xfa83d=Object['keys'](_0x22d288);for(const _0xa23838 of _0x30f809['model']['document']['roots'])'$graveyard'!=_0xa23838['rootName']&&_0xa23838['isAttached']()&&!_0xfa83d['includes'](_0xa23838['rootName'])&&_0x36128a['detachRoot'](_0xa23838);for(const _0x541b59 of _0xfa83d){let _0x389e85=_0x30f809['model']['document']['getRoot'](_0x541b59);_0x389e85&&_0x389e85['isAttached']()||(_0x389e85=_0x36128a['addRoot'](_0x541b59));const _0xb685cb=_0x314c2f[_0x541b59],_0x4c6923=Object['keys'](_0xb685cb),_0x11be96=_0x22d288[_0x541b59];for(const _0x4b315f of _0x389e85['getAttributeKeys']())_0x4c6923['includes'](_0x4b315f)||_0x36128a['removeAttribute'](_0x4b315f,_0x389e85);for(const _0xb3f939 of _0x4c6923)_0x36128a['setAttribute'](_0xb3f939,_0x314c2f[_0x541b59][_0xb3f939],_0x389e85);_0x36128a['remove'](_0x36128a['createRangeIn'](_0x389e85)),_0x36128a['insert'](_0x30f809['data']['parse'](_0x11be96,_0x389e85),_0x389e85,0x0);}});const _0x3b7ed3=R(_0x30f809['locale'],'Restored');if(_0x5bb02a['name'])_0x3b74f5=-0x1==_0x5bb02a['name']['indexOf'](_0x3b7ed3)?_0x3b7ed3+':\x20'+_0x5bb02a['name']:_0x5bb02a['name'];else _0x3b74f5=_0x3b7ed3+':\x20'+(_0x5bb02a['createdAt']['toLocaleDateString'](_0x30f809['locale']['uiLanguage'],{'month':'long','day':'numeric'})+',\x20'+_0x5bb02a['createdAt']['toLocaleTimeString'](_0x30f809['locale']['uiLanguage'],{'hour':'numeric','minute':'numeric'}));return await _0x39db61['saveRevision']({'name':_0x3b74f5}),_0x1677e3['isReady']=!0x0,_0x30f809['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}}export{nt as RestoreRevisionCommand,I as Revision,ht as RevisionHistory,v as RevisionHistoryUI,$ as RevisionHistoryUtils,h as RevisionTracker,l as RevisionViewer,m as RevisionViewerEditor,at as RevisionViewerIntegration,ji as RevisionViewerLoadingOverlay,u as RevisionViewerUI,S as RevisionsRepository,f as RevisionsSidebar,ot as ShowChangeCommand};