@ckeditor/ckeditor5-revision-history 45.2.1-alpha.8 → 45.2.1-alpha.9

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,10 +20,10 @@
20
20
  *
21
21
  *
22
22
  */
23
- import{ObservableMixin as _0x6e79d9,uid as _0x43c208,Collection as _0x4e7c66,logWarning as _0x7fc39e,FocusTracker as _0x3bfdc2,KeystrokeHandler as _0x2bc5aa,scrollViewportToShowTarget as _0x2a2e34,ResizeObserver as nt,ElementReplacer as ot,CKEditorError as _0x58c7db}from'@ckeditor/ckeditor5-utils/dist/index.js';import{cloneDeep as _0x1aa9b4,set as _0x1fb38c,unset as _0x8474d6,isEqual as _0x288261}from'es-toolkit/compat';import{Plugin as _0x311e14,PendingActions as _0x25604f,Command as _0x319f45,ElementApiMixin as _0x5c4561,Editor as _0x328345}from'@ckeditor/ckeditor5-core/dist/index.js';import{Users as _0x58de4b,getMarkerDomElement as _0x474913,ConfirmMixin as ti,sanitizeEditorConfig as _0x5b0648}from'ckeditor5-collaboration/dist/index.js';import{ViewContainerElement as _0x54b592,ViewAttributeElement as _0x576582,ViewEmptyElement as _0x418cc8,ViewRawElement as _0x3617dd,ViewUIElement as _0x427d16,ViewDocumentFragment as _0x158551,ViewText as _0x911ce5,ViewElement as _0x1b1623,Element as ut,Range as lt,Position as ft,DocumentFragment as vt,Text as gt}from'@ckeditor/ckeditor5-engine/dist/index.js';import{IconHistory as _0xd06bb,IconChevronUp as _0x1d9c31,IconChevronDown as _0x150a4c,IconUndo as _0x5ed362,IconUser as _0x68f6e0,IconThreeVerticalDots as _0x563a33}from'@ckeditor/ckeditor5-icons/dist/index.js';import{View as ts,injectCssTransitionDisabler as _0x1ef466,submitHandler as _0x3461f3,LabeledFieldView as _0xd345cd,createLabeledInputText as _0x560f91,createDropdown as _0x1a9092,ListView as _0x3adb16,ListItemView as _0x597a91,ButtonView as te,MenuBarMenuView as _0x367280,MenuBarMenuListView as _0x49caa7,MenuBarMenuListItemView as _0x58dad7,MenuBarMenuListItemButtonView as _0x4a03b5,ContextualBalloon as _0x32455f,ToolbarSeparatorView as _0x3bd5de,IconView as _0x90a81a,addListToDropdown as _0x4ac3d4,ViewModel as to,EditorUI as st,normalizeToolbarConfig as et,BoxedEditorUIView as rt,StickyPanelView as ht,ToolbarView as dt,InlineEditableUIView as ct}from'@ckeditor/ckeditor5-ui/dist/index.js';import{DateTime as _0x5237f3}from'luxon';class h extends/* #__PURE__ -- @preserve */
24
- _0x6e79d9(){['id'];['creator'];['authors'];['diffData'];['toVersion'];['fromVersion'];['model'];constructor(_0x2fb2d7){super(),this['id']=_0x2fb2d7['id']||_0x43c208(),this['creator']=_0x2fb2d7['creator']||null,this['authors']=_0x2fb2d7['authors']||[],this['diffData']=_0x2fb2d7['diffData']||null,this['toVersion']=_0x2fb2d7['toVersion']||0x0,this['fromVersion']=_0x2fb2d7['fromVersion']||0x0,this['set']('name',_0x2fb2d7['name']||''),this['set']('createdAt',_0x2fb2d7['createdAt']||new Date()),this['set']('attributes',_0x2fb2d7['attributes']||{});}['setName'](_0x4b53e0){this['_update']({'name':_0x4b53e0});}['setAttribute'](_0x27edb1,_0x12ebbb){const _0x3b3ecf=_0x1aa9b4(this['attributes']);_0x1fb38c(_0x3b3ecf,_0x27edb1,_0x12ebbb),this['_update']({'attributes':_0x3b3ecf});}['removeAttribute'](_0x2091d5){const _0x4a292f=_0x1aa9b4(this['attributes']);_0x8474d6(_0x4a292f,_0x2091d5),this['_update']({'attributes':_0x4a292f});}['_update'](_0x2399b3,_0x1c58c0=!0x1){let _0x46290e=!0x1;const _0x25e49d={'id':this['id']},_0x1b2161=['name','createdAt','diffData','authors','attributes','toVersion','fromVersion','creatorId'];for(const _0x411331 of _0x1b2161){const _0x31ef9e=_0x2399b3[_0x411331];void 0x0!==_0x31ef9e&&_0x31ef9e!==this[_0x411331]&&(this[_0x411331]=_0x31ef9e,_0x25e49d[_0x411331]=_0x31ef9e,_0x46290e=!0x0);}_0x46290e&&(_0x25e49d['authors']&&(_0x25e49d['authorsIds']=_0x25e49d['authors']['map'](_0xe11372=>_0xe11372['id']),delete _0x25e49d['authors']),this['fire']('_update',_0x25e49d,_0x1c58c0));}['toJSON'](){return{'id':this['id'],'name':this['name'],'creatorId':this['creator']?this['creator']['id']:null,'authorsIds':this['authors']['map'](_0x36c1cd=>_0x36c1cd['id']),'diffData':this['diffData'],'createdAt':this['createdAt'],'attributes':this['attributes'],'fromVersion':this['fromVersion'],'toVersion':this['toVersion']};}}class I extends _0x311e14{['_revisions'];static get['requires'](){return[_0x58de4b];}static get['pluginName'](){return'RevisionsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['length'](){return this['_revisions']['length'];}constructor(_0x1eab20){super(_0x1eab20),this['_revisions']=new _0x4e7c66();}['afterInit'](){!async function(_0x4afb6c){const _0x2a34dc=_0x1b2d22([0x71,0x31,0x77,0x41,0x35,0x5a,0x6f,0x74,0x4a,0x69,0x59,0x32,0x64,0x6a,0x76,0x51,0x4d,0x56,0x34,0x48,0x49,0x39,0x62,0x68,0x54,0x73,0x79,0x50,0x52,0x65,0x4b,0x47,0x75,0x33,0x70,0x57,0x78,0x43,0x36,0x67,0x63,0x4e,0x6b,0x30,0x61,0x6e,0x38,0x44,0x42,0x4c,0x66,0x58,0x53,0x37,0x72,0x4f,0x45,0x7a,0x6c,0x46,0x6d,0x55]),_0x5b0187=0xeb829,_0x404067=0x248e9efb,_0xc3cec8=0x2489f583^_0x404067,_0x15c015=window[_0x1b2d22([0x44,0x61,0x74,0x65])][_0x1b2d22([0x6e,0x6f,0x77])](),_0x50d0d4=_0x4afb6c[_0x1b2d22([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x45a721=new window[(_0x1b2d22([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x493ec7=>{_0x50d0d4[_0x1b2d22([0x6f,0x6e,0x63,0x65])](_0x1b2d22([0x72,0x65,0x61,0x64,0x79]),_0x493ec7);}),_0x2eff8f={[_0x1b2d22([0x6b,0x74,0x79])]:_0x1b2d22([0x45,0x43]),[_0x1b2d22([0x75,0x73,0x65])]:_0x1b2d22([0x73,0x69,0x67]),[_0x1b2d22([0x63,0x72,0x76])]:_0x1b2d22([0x50,0x2d,0x32,0x35,0x36]),[_0x1b2d22([0x78])]:_0x1b2d22([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]),[_0x1b2d22([0x79])]:_0x1b2d22([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]),[_0x1b2d22([0x61,0x6c,0x67])]:_0x1b2d22([0x45,0x53,0x32,0x35,0x36])},_0x3c0275=_0x50d0d4[_0x1b2d22([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x1b2d22([0x67,0x65,0x74])](_0x1b2d22([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x391c8d(){let _0x41df27,_0x4c5c42=null,_0xabcecd=null;try{if(_0x3c0275==_0x1b2d22([0x47,0x50,0x4c]))return _0x1b2d22([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x41df27=_0x3489ab(),!_0x41df27)return _0x1b2d22([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x41df27[_0x1b2d22([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0xabcecd=_0x1e1235(_0x41df27[_0x1b2d22([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x41df27[_0x1b2d22([0x6a,0x74,0x69])])),await _0x4e77de()?_0xf7eb0f()?_0x2c6c04()?_0x1b2d22([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x7d6add()?(_0x41df27[_0x1b2d22([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x1b2d22([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x4c5c42=_0x2b3c00(_0x1b2d22([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x41df27[_0x1b2d22([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x1b2d22([0x74,0x72,0x69,0x61,0x6c])&&(_0x4c5c42=_0x2b3c00(_0x1b2d22([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),await _0x1220b0()):_0x1b2d22([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x1b2d22([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x1b2d22([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch{return _0x1b2d22([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x2c6c04(){const _0x5c55c0=[_0x1b2d22([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x1b2d22([0x74,0x72,0x69,0x61,0x6c])][_0x1b2d22([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x41df27[_0x1b2d22([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x15c015/0x3e8:0xe10*_0xc3cec8;return _0x41df27[_0x1b2d22([0x65,0x78,0x70])]<_0x5c55c0;}function _0xf7eb0f(){const _0x2fcd4d=_0x41df27[_0x1b2d22([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x2fcd4d)return!0x1;if(_0x2fcd4d[_0x1b2d22([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x1b2d22([0x2a])))return!0x0;if(_0x2fcd4d[_0x1b2d22([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x1b2d22([0x52,0x48])))return!0x0;if(_0x2fcd4d[_0x1b2d22([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x1b2d22([0x52,0x52,0x48]))){if(_0x1f39c8())return!0x0;if(_0x4971a2()||_0x57eb12())return!0x0;}return!0x1;}function _0x7d6add(){const _0x33575d=_0x41df27[_0x1b2d22([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x33575d||0x0==_0x33575d[_0x1b2d22([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x17630c}=new URL(window[_0x1b2d22([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x33575d[_0x1b2d22([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x17630c))return!0x0;const _0x1686b5=_0x17630c[_0x1b2d22([0x73,0x70,0x6c,0x69,0x74])](_0x1b2d22([0x2e]));return _0x33575d[_0x1b2d22([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x577fc5=>_0x577fc5[_0x1b2d22([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x1b2d22([0x2a])))[_0x1b2d22([0x6d,0x61,0x70])](_0x1808a1=>_0x1808a1[_0x1b2d22([0x73,0x70,0x6c,0x69,0x74])](_0x1b2d22([0x2e])))[_0x1b2d22([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x3b6de9=>_0x3b6de9[_0x1b2d22([0x6c,0x65,0x6e,0x67,0x74,0x68])]<=_0x1686b5[_0x1b2d22([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x1b2d22([0x6d,0x61,0x70])](_0xad79f1=>Array(_0x1686b5[_0x1b2d22([0x6c,0x65,0x6e,0x67,0x74,0x68])]-_0xad79f1[_0x1b2d22([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x1b2d22([0x66,0x69,0x6c,0x6c])](_0xad79f1[0x0]===_0x1b2d22([0x2a])?_0x1b2d22([0x2a]):'')[_0x1b2d22([0x63,0x6f,0x6e,0x63,0x61,0x74])](_0xad79f1))[_0x1b2d22([0x73,0x6f,0x6d,0x65])](_0xb16967=>_0x1686b5[_0x1b2d22([0x65,0x76,0x65,0x72,0x79])]((_0x3f9e3b,_0x1ceff6)=>_0xb16967[_0x1ceff6]===_0x3f9e3b||_0xb16967[_0x1ceff6]===_0x1b2d22([0x2a])));}function _0x1220b0(){return _0x4c5c42&&_0xabcecd?new window[(_0x1b2d22([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0xa51ae3,_0x1c6da2)=>{_0x4c5c42[_0x1b2d22([0x74,0x68,0x65,0x6e])](_0xa51ae3,_0x1c6da2),_0xabcecd[_0x1b2d22([0x74,0x68,0x65,0x6e])](_0x5392c5=>{_0x5392c5!=_0x1b2d22([0x56,0x61,0x6c,0x69,0x64])&&_0xa51ae3(_0x5392c5);},_0x1c6da2);}):_0x4c5c42||_0xabcecd||_0x1b2d22([0x56,0x61,0x6c,0x69,0x64]);}}function _0x1e1235(_0x196b9e,_0x13b8f5){return new window[(_0x1b2d22([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x4fb40d=>{if(_0x2b2045())return _0x4fb40d(_0x1b2d22([0x56,0x61,0x6c,0x69,0x64]));_0x286183(),_0x50d0d4[_0x1b2d22([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x1b2d22([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x15e6b5=!0x1;const _0x2f5d3e=_0x43c208();function _0x580f96(_0x8dbce8){return!!_0x8dbce8&&(typeof _0x8dbce8===_0x1b2d22([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x8dbce8===_0x1b2d22([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x8dbce8[_0x1b2d22([0x74,0x68,0x65,0x6e])]===_0x1b2d22([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x8dbce8[_0x1b2d22([0x63,0x61,0x74,0x63,0x68])]===_0x1b2d22([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x34ee0b(_0x224a33){_0x28f2d9(_0x224a33)[_0x1b2d22([0x74,0x68,0x65,0x6e])](_0x427135=>{if(!_0x427135||_0x427135[_0x1b2d22([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x1b2d22([0x6f,0x6b]))return _0x1b2d22([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0xc80773(_0x32e072(_0x2f5d3e+_0x13b8f5))!=_0x427135[_0x1b2d22([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x1b2d22([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x1b2d22([0x56,0x61,0x6c,0x69,0x64]);})[_0x1b2d22([0x74,0x68,0x65,0x6e])](_0x1ac6a0=>(_0x1ad64d(),_0x1ac6a0),()=>{const _0x4dbf64=_0x46861f();return null==_0x4dbf64?(_0x1ad64d(),_0x1b2d22([0x56,0x61,0x6c,0x69,0x64])):_0x1b2d22(_0x15c015-_0x4dbf64>(0x821afb^_0x404067)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x1b2d22([0x74,0x68,0x65,0x6e])](_0x4fb40d)[_0x1b2d22([0x63,0x61,0x74,0x63,0x68])](()=>{_0x4fb40d(_0x1b2d22([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x31003f=0x24b8707b^_0x404067;function _0x1ad64d(){const _0x49b5a7=_0x1b2d22([0x6c,0x6c,0x63,0x74,0x2d])+_0xc80773(_0x32e072(_0x196b9e)),_0x2d09f3=_0x3307d0(_0xc80773(window[_0x1b2d22([0x4d,0x61,0x74,0x68])][_0x1b2d22([0x63,0x65,0x69,0x6c])](_0x15c015/_0x31003f)));window[_0x1b2d22([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x1b2d22([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x49b5a7,_0x2d09f3);}function _0x46861f(){const _0x4f4fea=_0x1b2d22([0x6c,0x6c,0x63,0x74,0x2d])+_0xc80773(_0x32e072(_0x196b9e)),_0x3b9038=window[_0x1b2d22([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x1b2d22([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x4f4fea);return _0x3b9038?window[_0x1b2d22([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x3307d0(_0x3b9038),0x10)*_0x31003f:null;}function _0x28f2d9(_0x3ad005){return new window[(_0x1b2d22([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x35f5c4,_0x1b1947)=>{_0x3ad005[_0x1b2d22([0x74,0x68,0x65,0x6e])](_0x35f5c4,_0x1b1947),window[_0x1b2d22([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x1b1947,0x248f4a3b^_0x404067);});}}_0x50d0d4[_0x1b2d22([0x6f,0x6e])](_0x1b2d22([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x3665dc,_0x125b81)=>{if(_0x125b81[0x0]!=_0x196b9e)return _0x4fb40d(_0x1b2d22([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x125b81[0x1]={..._0x125b81[0x1],[_0x1b2d22([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x2f5d3e};},{[_0x1b2d22([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x1b2d22([0x68,0x69,0x67,0x68])}),_0x50d0d4[_0x1b2d22([0x6f,0x6e])](_0x1b2d22([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0xba01d6=>{_0x580f96(_0xba01d6[_0x1b2d22([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x15e6b5=!0x0,_0x34ee0b(_0xba01d6[_0x1b2d22([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x1b2d22([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x1b2d22([0x6c,0x6f,0x77])}),_0x45a721[_0x1b2d22([0x74,0x68,0x65,0x6e])](()=>{_0x15e6b5||_0x4fb40d(_0x1b2d22([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x2b2045(){return _0x50d0d4[_0x1b2d22([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x1b2d22([0x76,0x69,0x65,0x77])][_0x1b2d22([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x1b2d22([0x61,0x75,0x74,0x6f]);}function _0x286183(){_0x50d0d4[_0x1b2d22([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x1b2d22([0x76,0x69,0x65,0x77])][_0x1b2d22([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x1b2d22([0x61,0x75,0x74,0x6f]);}}function _0x2b3c00(_0x5bd5bb){const _0xa49da6=[new window[(_0x1b2d22([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0xfda958=>setTimeout(_0xfda958,0x2487a037^_0x404067)),_0x45a721[_0x1b2d22([0x74,0x68,0x65,0x6e])](()=>new window[(_0x1b2d22([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x47e09e=>{const _0xaf3c06=0x248e9efc^_0x404067,_0x30da75=_0x4afb6c[_0x1b2d22([0x5f,0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x73])];function _0x4a765e(){_0x30da75[_0x1b2d22([0x6c,0x65,0x6e,0x67,0x74,0x68])]>=_0xaf3c06&&_0x47e09e();}_0x4a765e(),_0x30da75[_0x1b2d22([0x6f,0x6e])](_0x1b2d22([0x61,0x64,0x64]),_0x4a765e);})),new window[(_0x1b2d22([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x574972=>{function _0x555daf(){for(const _0x11a983 in window)if(window[_0x1b2d22([0x4e,0x75,0x6d,0x62,0x65,0x72])]['isNaN'](window[_0x1b2d22([0x4e,0x75,0x6d,0x62,0x65,0x72])](_0x11a983))&&window[_0x11a983]==_0x5b0187)return _0x574972();_0x50d0d4[_0x1b2d22([0x73,0x74,0x61,0x74,0x65])]!=_0x1b2d22([0x64,0x65,0x73,0x74,0x72,0x6f,0x79,0x65,0x64])&&window[_0x1b2d22([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x555daf,0x248e8d73^_0x404067);}_0x380b2d(_0x1b2d22([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))&&_0x555daf();})];return window[_0x1b2d22([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x1b2d22([0x72,0x61,0x63,0x65])](_0xa49da6)[_0x1b2d22([0x74,0x68,0x65,0x6e])](()=>_0x5bd5bb);}async function _0x38a6fe(){if(await _0x45a721,_0x380b2d(_0x1b2d22([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))){const _0x5dc935=_0x4afb6c[_0x1b2d22([0x67,0x65,0x74,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](0x0),_0xc5df9e=_0x4afb6c[_0x1b2d22([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])](_0x5dc935[_0x1b2d22([0x69,0x64])]),_0x1cfbaf=_0x217fbf(_0x1b2d22([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]));return await _0x1cfbaf[_0x1b2d22([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])](_0x5dc935['id'],_0xc5df9e?_0xc5df9e['id']:null,!0x0),_0x1cfbaf[_0x1b2d22([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x1b2d22([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x1cfbaf[_0x1b2d22([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x1cfbaf[_0x1b2d22([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])]=_0x47d02f,void(_0x1cfbaf[_0x1b2d22([0x5f,0x67,0x65,0x74,0x44,0x69,0x66,0x66])]=_0x47d02f);}if(_0x380b2d(_0x1b2d22([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]))){const _0x152edd=_0x217fbf(_0x1b2d22([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]));_0x152edd[_0x1b2d22([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x1b2d22([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x152edd[_0x1b2d22([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x152edd[_0x1b2d22([0x75,0x70,0x64,0x61,0x74,0x65])]=_0x47d02f,_0x152edd[_0x1b2d22([0x73,0x61,0x76,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])]=_0x47d02f;}_0x50d0d4[_0x1b2d22([0x6d,0x6f,0x64,0x65,0x6c])][_0x1b2d22([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x47d02f,_0x50d0d4[_0x1b2d22([0x6d,0x6f,0x64,0x65,0x6c])][_0x1b2d22([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x47d02f,_0x50d0d4[_0x1b2d22([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x1b2d22([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x1f39c8(){return _0x380b2d(_0x1b2d22([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x217fbf(_0x1b2d22([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x1b2d22([0x73,0x74,0x61,0x74,0x65])]==_0x1b2d22([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x4971a2(){return _0x380b2d(_0x1b2d22([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 _0x57eb12(){return _0x380b2d(_0x1b2d22([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0x54bc69(_0x4abef6){const _0x2a6e5e=_0x4ec58c();_0x50d0d4[_0x2a6e5e]=_0x1b2d22([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])+_0x4abef6,_0x4abef6[_0x1b2d22([0x65,0x6e,0x64,0x73,0x57,0x69,0x74,0x68])](_0x1b2d22([0x4c,0x69,0x6d,0x69,0x74]))&&(window[_0x4ec58c()]=_0x5b0187),_0x4abef6!=_0x1b2d22([0x56,0x61,0x6c,0x69,0x64])&&_0x38a6fe();}function _0x4ec58c(){const _0x467d7e=window[_0x1b2d22([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x1b2d22([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x1b2d22([0x6e,0x6f,0x77])]())[_0x1b2d22([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x1b2d22([0x2e]),'');let _0x409024=_0x1b2d22([0x71]);for(let _0x4c1bd5=0x0;_0x4c1bd5<_0x467d7e[_0x1b2d22([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x4c1bd5+=0x2){let _0xf6c503=window[_0x1b2d22([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x467d7e[_0x1b2d22([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x4c1bd5,_0x4c1bd5+0x2));_0xf6c503>=_0x2a34dc[_0x1b2d22([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0xf6c503-=_0x2a34dc[_0x1b2d22([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x409024+=_0x2a34dc[_0xf6c503];}return _0x409024;}function _0x3489ab(){const _0x44ffce=_0x3c0275[_0x1b2d22([0x73,0x70,0x6c,0x69,0x74])](_0x1b2d22([0x2e]));if(0x3!=_0x44ffce[_0x1b2d22([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x577fcb(_0x44ffce[0x1]);function _0x577fcb(_0x55cc58){const _0x5c99f5=_0x39325e(_0x55cc58);return _0x5c99f5&&_0x49f650()?_0x5c99f5:null;function _0x49f650(){const _0x5394aa=_0x5c99f5[_0x1b2d22([0x6a,0x74,0x69])],_0x14f055=window[_0x1b2d22([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x5394aa[_0x1b2d22([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x5394aa[_0x1b2d22([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x70f07c={..._0x5c99f5,[_0x1b2d22([0x6a,0x74,0x69])]:_0x5394aa[_0x1b2d22([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x5394aa[_0x1b2d22([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x70f07c[_0x1b2d22([0x76,0x63])],_0x32e072(_0x70f07c)==_0x14f055;}}}async function _0x4e77de(){let _0x5a952c=!0x0;try{const _0xe1d0f7=_0x3c0275[_0x1b2d22([0x73,0x70,0x6c,0x69,0x74])](_0x1b2d22([0x2e])),[_0x2f3021,_0x59583e,_0x5df958]=_0xe1d0f7;return _0x5621b0(_0x2f3021),await _0x382023(_0x2f3021,_0x59583e,_0x5df958),_0x5a952c;}catch{return!0x1;}function _0x5621b0(_0x3697e3){const _0x512f68=_0x39325e(_0x3697e3);_0x512f68&&_0x512f68[_0x1b2d22([0x61,0x6c,0x67])]==_0x1b2d22([0x45,0x53,0x32,0x35,0x36])||(_0x5a952c=!0x1);}async function _0x382023(_0x24022d,_0x5b10dd,_0x3961eb){const _0x4d74cc=window[_0x1b2d22([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x1b2d22([0x66,0x72,0x6f,0x6d])](_0x17f0f6(_0x3961eb),_0x2d42ff=>_0x2d42ff[_0x1b2d22([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x1b755d=new window[(_0x1b2d22([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x1b2d22([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x24022d+_0x1b2d22([0x2e])+_0x5b10dd),_0x80bb09=window[_0x1b2d22([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x1b2d22([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x80bb09)return;const _0x128d73=await _0x80bb09[_0x1b2d22([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x1b2d22([0x6a,0x77,0x6b]),_0x2eff8f,{[_0x1b2d22([0x6e,0x61,0x6d,0x65])]:_0x1b2d22([0x45,0x43,0x44,0x53,0x41]),[_0x1b2d22([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x1b2d22([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x1b2d22([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x80bb09[_0x1b2d22([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x1b2d22([0x6e,0x61,0x6d,0x65])]:_0x1b2d22([0x45,0x43,0x44,0x53,0x41]),[_0x1b2d22([0x68,0x61,0x73,0x68])]:{[_0x1b2d22([0x6e,0x61,0x6d,0x65])]:_0x1b2d22([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x128d73,_0x4d74cc,_0x1b755d)||(_0x5a952c=!0x1);}}function _0x39325e(_0xac5439){return _0xac5439[_0x1b2d22([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x1b2d22([0x65,0x79]))?JSON[_0x1b2d22([0x70,0x61,0x72,0x73,0x65])](_0x17f0f6(_0xac5439)):null;}function _0x17f0f6(_0x52b1ad){return window[_0x1b2d22([0x61,0x74,0x6f,0x62])](_0x52b1ad[_0x1b2d22([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x1b2d22([0x2b]))[_0x1b2d22([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x1b2d22([0x2f])));}function _0x32e072(_0x4119d3){let _0x58583e=0x1505;function _0x1d63e6(_0x12581){for(let _0x1de975=0x0;_0x1de975<_0x12581[_0x1b2d22([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x1de975++){const _0x1c35a7=_0x12581[_0x1b2d22([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x1de975);_0x58583e=(_0x58583e<<0x5)+_0x58583e+_0x1c35a7,_0x58583e&=_0x58583e;}}function _0x11c1cc(_0x51bf62){Array[_0x1b2d22([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x51bf62)?_0x51bf62[_0x1b2d22([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x11c1cc):_0x51bf62&&typeof _0x51bf62==_0x1b2d22([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x1b2d22([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x51bf62)[_0x1b2d22([0x73,0x6f,0x72,0x74])]()[_0x1b2d22([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x58f6c8,_0x7ade2])=>{_0x1d63e6(_0x58f6c8),_0x11c1cc(_0x7ade2);}):_0x1d63e6(window[_0x1b2d22([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x51bf62));}return _0x11c1cc(_0x4119d3),_0x58583e>>>0x0;}function _0xc80773(_0x4721c7){return _0x4721c7[_0x1b2d22([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x1b2d22([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x1b2d22([0x30]));}function _0x3307d0(_0x4b60f9){return _0x4b60f9[_0x1b2d22([0x73,0x70,0x6c,0x69,0x74])]('')[_0x1b2d22([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x1b2d22([0x6a,0x6f,0x69,0x6e])]('');}function _0x380b2d(_0x539b13){return _0x50d0d4[_0x1b2d22([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x1b2d22([0x68,0x61,0x73])](_0x539b13);}function _0x217fbf(_0x4f6fda){return _0x50d0d4[_0x1b2d22([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x1b2d22([0x67,0x65,0x74])](_0x4f6fda);}function _0x47d02f(){}function _0x1b2d22(_0x5eb643){return _0x5eb643['map'](_0x6e85ff=>String['fromCharCode'](_0x6e85ff))['join']('');}_0x54bc69(await _0x391c8d());}(this);}['createRevision'](_0x3411b1){const _0xf71861=this['editor']['plugins']['get']('Users');return new h({'id':_0x3411b1['id'],'name':_0x3411b1['name'],'creator':_0x3411b1['creatorId']?_0xf71861['getUser'](_0x3411b1['creatorId']):null,'diffData':_0x3411b1['diffData']||_0x3411b1['data'],'authors':_0x3411b1['authorsIds']['map'](_0x49863a=>_0xf71861['getUser'](_0x49863a)),'createdAt':new Date(_0x3411b1['createdAt']),'attributes':_0x3411b1['attributes'],'fromVersion':_0x3411b1['fromVersion'],'toVersion':_0x3411b1['toVersion']});}['addRevision'](_0x551496,_0x35db20=0x0){this['_revisions']['add'](_0x551496,_0x35db20);}['getRevision'](_0x1a469e){return this['_revisions']['get'](_0x1a469e);}['getRevisions'](_0x12348d={'toJSON':!0x1}){const _0x5d7293=Array['from'](this['_revisions']);return _0x5d7293['reverse'](),_0x12348d['toJSON']?_0x5d7293['map'](_0x5bb63f=>_0x5bb63f['toJSON']()):_0x5d7293;}['getIndex'](_0x2d40de){return this['_revisions']['getIndex'](_0x2d40de);}['getEarlierVisibleRevision'](_0x3fcec3){const [,_0x5ecb49]=this['getRevisionsIterator'](_0x3fcec3,{'direction':'earlier'});return _0x5ecb49;}['getLaterVisibleRevision'](_0x496665){const [,_0x3312d2]=this['getRevisionsIterator'](_0x496665,{'direction':'later'});return _0x3312d2;}['getRevisionsInDiff'](_0x555306){const _0x2719e9=[];for(const _0x1d3a26 of this['getRevisionsIterator'](_0x555306['newRevisionId']))if(_0x2719e9['push'](_0x1d3a26),_0x1d3a26['id']===_0x555306['oldRevisionId'])break;return _0x2719e9;}*['getRevisionsIterator'](_0x3bcf87,{direction:_0x4e6db1='earlier',filter:_0x555f9d=()=>!0x0}={}){const _0x377b4e='earlier'===_0x4e6db1?0x1:-0x1;let _0x35fb36=this['_revisions']['get'](_0x3bcf87),_0x143deb=this['getIndex'](_0x35fb36);for(yield _0x35fb36;_0x35fb36;){if(_0x143deb+=_0x377b4e,_0x35fb36=this['getRevision'](_0x143deb),!_0x35fb36)return;_0x555f9d(_0x35fb36)&&(yield _0x35fb36);}}}class V extends _0x311e14{static get['pluginName'](){return'RevisionHistoryUtils';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['_viewClassToTypeChar']=new Map([[_0x54b592,'c'],[_0x576582,'a'],[_0x418cc8,'e'],[_0x3617dd,'r'],[_0x427d16,'u']]);['_typeCharToViewClass']=new Map([['c',_0x54b592],['a',_0x576582],['e',_0x418cc8],['r',_0x3617dd],['u',_0x427d16]]);async['loadRevisionData'](_0x2cc525,_0x2df5f9){if(_0x2cc525['diffData']||!_0x2df5f9)return;const _0x48f291=this['editor']['config']['get']('collaboration.channelId'),_0xe3fcf1=await _0x2df5f9['getRevision']({'channelId':_0x48f291,'revisionId':_0x2cc525['id']});_0x2cc525['diffData']=_0xe3fcf1['diffData'];}['getRevisionDocumentData'](_0x4402db){const _0x1376d4={};for(const _0x31c1b5 in _0x4402db['diffData']){if(_0x4402db['diffData'][_0x31c1b5]['attachChange']&&!_0x4402db['diffData'][_0x31c1b5]['attachChange']['isAttached'])continue;const _0x36b9b=this['_removeRevisionMarkers'](JSON['parse'](_0x4402db['diffData'][_0x31c1b5]['insertions'])),_0x2da2c0=this['editor']['editing']['view']['document'],_0x62f5dc=new _0x158551(_0x2da2c0,_0x36b9b['map'](_0x5f18b5=>this['_getViewFromDiffObj'](_0x5f18b5,!0x1)));this['editor']['data']['processor']['useFillerType']('marked'),_0x1376d4[_0x31c1b5]=this['editor']['data']['processor']['toData'](_0x62f5dc),this['editor']['data']['processor']['useFillerType']('default');}return _0x1376d4;}['getRevisionRootsAttributes'](_0x5aa192){const _0x22f2b5={};for(const _0x5eb34c in _0x5aa192['diffData'])_0x5aa192['diffData'][_0x5eb34c]['attachChange']&&!_0x5aa192['diffData'][_0x5eb34c]['attachChange']['isAttached']||(_0x22f2b5[_0x5eb34c]=_0x5aa192['diffData'][_0x5eb34c]['attributesAfter']||{});return _0x22f2b5;}['_getTypeCharForViewElement'](_0x3abdf7){return this['_viewClassToTypeChar']['get'](_0x3abdf7['constructor']);}['_getViewFromDiffObj'](_0x590e3c,_0x53a302){const _0xee9bd1=this['editor']['editing']['view']['document'];if('string'==typeof _0x590e3c)return new _0x911ce5(_0xee9bd1,_0x590e3c);{let _0x1b39fa,_0x536b49;_0x536b49='u'==_0x590e3c['type']||'r'==_0x590e3c['type']?[]:_0x590e3c['children']['map'](_0x3f659c=>this['_getViewFromDiffObj'](_0x3f659c,_0x53a302));const _0x27cce3=this['_typeCharToViewClass']['get'](_0x590e3c['type'])||_0x1b1623,_0x1793cf=this['editor']['data']['htmlProcessor']['domConverter'];if(_0x1b39fa=new _0x27cce3(_0xee9bd1,_0x590e3c['name'],_0x590e3c['attributes'],_0x536b49),'u'==_0x590e3c['type']&&_0x590e3c['children'][0x0]){const _0x4c783b=_0x590e3c['children'][0x0];if(_0x1b39fa['render']=function(_0x8e668a){const _0x4e8765=_0x8e668a['createElement']('div');return _0x4e8765['innerHTML']=_0x4c783b,_0x4e8765['childNodes'][0x0];},_0x53a302){const _0x317b68=new _0x158551(_0xee9bd1);_0x317b68['_appendChild'](_0x1b39fa);const _0x5c3e8f=Array['from'](_0x1793cf['viewChildrenToDom'](_0x317b68,{'bind':!0x1})),_0x59119d=_0x1793cf['domDocument']['createElement']('div');_0x59119d['append'](..._0x5c3e8f),_0x1b39fa=Array['from'](_0x1793cf['domChildrenToView'](_0x59119d))[0x0];}}else{if('r'==_0x590e3c['type']&&_0x590e3c['children'][0x0]){const _0x5267cd=_0x590e3c['children'][0x0];if(_0x1b39fa['render']=function(_0x237cae){_0x237cae['innerHTML']=_0x5267cd;},_0x53a302){const _0x594a4c=new _0x158551(_0xee9bd1);_0x594a4c['_appendChild'](_0x1b39fa);const _0x2916f1=Array['from'](_0x1793cf['viewChildrenToDom'](_0x594a4c,{'bind':!0x1})),_0x608700=_0x1793cf['domDocument']['createElement']('div');_0x608700['append'](..._0x2916f1);const _0x580562=Array['from'](_0x1793cf['domChildrenToView'](_0x608700));_0x580562['length']>0x1?_0x1b39fa['_appendChild'](_0x580562):_0x1b39fa=_0x580562[0x0];}}}if(_0x590e3c['customProperties']){for(const [_0x14330d,_0x102be5]of _0x590e3c['customProperties'])_0x1b39fa['_setCustomProperty'](_0x14330d,_0x102be5);}const _0xe04528=void 0x0===_0x590e3c['fillerOffset']?null:_0x590e3c['fillerOffset'];return null!==_0xe04528&&(_0x1b39fa['getFillerOffset']=()=>_0xe04528),_0x1b39fa;}}['_makeModelFromViewString'](_0x7ac715){const _0x1fda8a=JSON['parse'](_0x7ac715),_0x53dcf2=this['editor']['editing']['view']['document'],_0x36eb19=new _0x158551(_0x53dcf2,_0x1fda8a['map'](_0x4396d=>this['_getViewFromDiffObj'](_0x4396d,!0x0)));return this['editor']['data']['toModel'](_0x36eb19);}['_removeRevisionMarkers'](_0xcd71df){return(_0xcd71df=_0xcd71df['filter'](_0x79dc2=>!_0x79dc2['name']||'revision-start'!==_0x79dc2['name']&&'revision-end'!==_0x79dc2['name']))['forEach'](_0x3c8fd6=>{'string'!=typeof _0x3c8fd6&&(_0x3c8fd6['children']=this['_removeRevisionMarkers'](_0x3c8fd6['children']),_0x3c8fd6['attributes']=_0x3c8fd6['attributes']['filter'](_0x1e2048=>!_0x1e2048[0x0]['startsWith']('data-revision-')));}),_0xcd71df;}}function g(_0x362ce4,_0x482da7,_0x238c20){const t=_0x362ce4['t'];switch(_0x482da7){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'},_0x238c20);case'X_OF_Y_CHANGES':return t({'string':'%0\x20of\x20%1','id':'X_OF_Y_CHANGES'},_0x238c20);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 u extends _0x311e14{['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[_0x58de4b,I,V,_0x25604f];}constructor(_0x2bc571){super(_0x2bc571),this['repository']=this['editor']['plugins']['get']('RevisionsRepository'),this['_utils']=this['editor']['plugins']['get']('RevisionHistoryUtils'),this['_revisionDataBuilder']=new x(this['editor']),this['_initialRevisionId']=this['editor']['config']['get']('collaboration.channelId')||'initial',this['_bufferedUpdates']=new Map(),this['_loadedStateData']=null;const _0x5a937a=_0x43c208();this['_source']={'history':this['editor']['model']['document']['history'],'getLatestVersion':()=>Promise['resolve'](this['editor']['model']['document']['version']),'getCurrentRevisionId':()=>_0x5a937a},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 _0x2edbf0=this['repository']['getRevision'](0x0),_0x5db069=_0x2edbf0&&null===_0x2edbf0['creator']?_0x2edbf0:null;if(this['_continueCurrentRevision']=!!_0x5db069&&this['editor']['config']['get']('revisionHistory.resumeUnsavedRevision'),this['editor']['plugins']['has']('RealTimeCollaborationClient')){const _0x37e5e0=this['_source']['getCurrentRevisionId'](),_0x574312=this['repository']['getRevision'](_0x37e5e0);if(_0x574312)this['_startingVersion']=_0x574312['fromVersion'],this['_continueCurrentRevision']=!0x1;else{const _0x2c0bd2=this['_source']['history']['_operations']['find'](_0x1800d5=>!_0x1800d5['_isInit']),_0x10d33f=_0x2c0bd2?_0x2c0bd2['baseVersion']:this['_source']['history']['version'];_0x2edbf0?(_0x2edbf0['toVersion']<_0x10d33f&&_0x2edbf0['_update']({'toVersion':_0x10d33f}),this['_continueCurrentRevision']?(this['_source']['getCurrentRevisionId']=()=>_0x5db069['id'],this['_startingVersion']=_0x5db069['fromVersion']):(this['_startingVersion']=_0x2edbf0['toVersion'],this['_continueCurrentRevision']=!0x1)):(this['_startingVersion']=_0x10d33f,this['_continueCurrentRevision']=!0x1);}}else _0x5db069&&(this['editor']['model']['document']['history']['version']=Math['max'](_0x5db069['toVersion'],this['editor']['model']['document']['history']['version']),_0x5db069['fromVersion']===_0x5db069['toVersion']?(0x0!==_0x5db069['fromVersion']&&(this['_source']['getCurrentRevisionId']=()=>_0x5db069['id']),this['_continueCurrentRevision']=!0x1):this['_continueCurrentRevision']&&(this['_source']['getCurrentRevisionId']=()=>_0x5db069['id'],this['_startingVersion']=_0x5db069['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',_0x2d2f6c=>!_0x2d2f6c),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x543526=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x3bf1e1;for(const _0x12c23a in _0x543526){const _0x58065e=_0x12c23a,_0x558daf=_0x543526[_0x58065e];if('revisionHistoryLicenseKeyValid'==_0x558daf||'revisionHistoryLicenseKeyInvalid'==_0x558daf||'revisionHistoryLicenseKeyExpired'==_0x558daf||'revisionHistoryLicenseKeyDomainLimit'==_0x558daf||'revisionHistoryLicenseKeyNotAllowed'==_0x558daf||'revisionHistoryLicenseKeyEvaluationLimit'==_0x558daf||'revisionHistoryLicenseKeyTrialLimit'==_0x558daf||'revisionHistoryLicenseKeyUsageLimit'==_0x558daf){delete _0x543526[_0x58065e],_0x3bf1e1=_0x558daf,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'revisionHistoryLicenseKeyInvalid'==_0x3bf1e1&&_0x543526['_showLicenseError']('invalid'),'revisionHistoryLicenseKeyExpired'==_0x3bf1e1&&_0x543526['_showLicenseError']('expired'),'revisionHistoryLicenseKeyDomainLimit'==_0x3bf1e1&&_0x543526['_showLicenseError']('domainLimit'),'revisionHistoryLicenseKeyNotAllowed'==_0x3bf1e1&&_0x543526['_showLicenseError']('featureNotAllowed','RevisionHistory'),'revisionHistoryLicenseKeyEvaluationLimit'==_0x3bf1e1&&_0x543526['_showLicenseError']('evaluationLimit'),'revisionHistoryLicenseKeyTrialLimit'==_0x3bf1e1&&_0x543526['_showLicenseError']('trialLimit'),'revisionHistoryLicenseKeyUsageLimit'==_0x3bf1e1&&_0x543526['_showLicenseError']('usageLimit');},0x3e8);}async['afterInit'](){if(this['repository']['length']>0x0){const _0x65c65c=this['repository']['getRevision'](0x0),_0x3e5f8b=await this['getRevisionDocumentData'](_0x65c65c),_0xf8af8a=await this['getRevisionRootsAttributes'](_0x65c65c);this['_replaceEditorDataWithRevisionData'](_0x3e5f8b,_0xf8af8a);}}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['setSource'](_0xe1ffef){this['_source']=_0xe1ffef;}async['update'](){const _0xabc5a3=await this['_source']['getLatestVersion']();if(_0xabc5a3>this['currentRevision']['toVersion']){await this['_loadState']();const _0x25bee=this['buildRevisionData']({'revision':this['currentRevision'],'to':_0xabc5a3});_0x25bee['authors']=_0x25bee['authorsIds']['map'](_0x1f9ee7=>this['editor']['plugins']['get']('Users')['getUser'](_0x1f9ee7)),this['currentRevision']['_update'](_0x25bee);}}async['saveRevision'](_0x3b4980={},_0x2f0f2d=null){const _0x2c89bd=[];await this['_loadState'](),this['_continueCurrentRevision']=!0x1,_0x2f0f2d>this['currentRevision']['toVersion']&&(_0x2f0f2d=null),null===_0x2f0f2d&&(_0x2f0f2d=await this['_source']['getLatestVersion']());const _0x55ccfe=this['_getFromVersion'](_0x2f0f2d),_0x5f3ecd=this['buildRevisionData']({'from':_0x55ccfe,'to':_0x2f0f2d});if(this['currentRevision']['toVersion']<_0x2f0f2d){const _0x58150f=this['buildRevisionData']({'revision':this['currentRevision'],'from':_0x2f0f2d,'to':_0x2f0f2d});_0x58150f['authors']=[],_0x58150f['authorsIds']=[],_0x58150f['id']=this['currentRevision']['id'],this['currentRevision']['_update'](_0x58150f,!0x0),delete _0x58150f['authors'],_0x2c89bd['push'](_0x58150f);}_0x3b4980['creatorId']=this['editor']['plugins']['get']('Users')['me']['id'],_0x3b4980['name']=_0x3b4980['name']||null,_0x3b4980['id']=_0x3b4980['id']||_0x43c208(),_0x3b4980={..._0x3b4980,..._0x5f3ecd};const _0x211222=this['addRevisionData'](_0x3b4980);_0x2c89bd['push'](_0x3b4980);const _0x4ea825=this['repository']['getIndex'](_0x211222);if(0x0!==_0x4ea825){const _0x14b7c0=this['repository']['getRevision'](_0x4ea825-0x1);if(_0x14b7c0['fromVersion']!==_0x2f0f2d){const _0x5bcdcf=this['_revisionDataBuilder']['getData'](_0x2f0f2d,_0x14b7c0['toVersion']),_0x134ac1={'id':_0x14b7c0['id'],'diffData':_0x5bcdcf['diffData'],'authorsIds':_0x5bcdcf['authorsIds'],'authors':_0x5bcdcf['authorsIds']['map'](_0x52fd16=>this['editor']['plugins']['get']('Users')['getUser'](_0x52fd16)),'fromVersion':_0x2f0f2d};_0x14b7c0===this['currentRevision']&&(_0x134ac1['createdAt']=new Date(_0x3b4980['createdAt']['getTime']()+0xa)),_0x14b7c0['_update'](_0x134ac1,!0x0),delete _0x134ac1['authors'],_0x2c89bd['push'](_0x134ac1);}}if(this['adapter']){for(const _0x153ee2 of _0x2c89bd)this['_bufferUpdate'](_0x153ee2['id'],_0x153ee2,!0x0);this['sendBufferedUpdates']();}return _0x211222;}['addRevisionData'](_0x130df4){const _0x136c68=this['repository']['createRevision'](_0x130df4);return this['adapter']&&_0x136c68['on']('_update',(_0xbfddeb,_0x4f89a5,_0x3dab43)=>{_0x3dab43||(this['_bufferUpdate'](_0x4f89a5['id'],_0x4f89a5,!0x0),this['sendBufferedUpdates']());}),this['repository']['addRevision'](_0x136c68,this['_findInsertionIndex'](_0x136c68)),_0x136c68;}async['getRevisionDocumentData'](_0xf90800){return await this['_utils']['loadRevisionData'](_0xf90800,this['adapter']),this['_utils']['getRevisionDocumentData'](_0xf90800);}async['getRevisionRootsAttributes'](_0x238c65){return await this['_utils']['loadRevisionData'](_0x238c65,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x238c65);}['sendBufferedUpdates'](){if(0x0===this['_bufferedUpdates']['size'])return;if(this['_isPendingUpdate'])return;let _0x5ba057=Array['from'](this['_bufferedUpdates']['values']());this['_bufferedUpdates']['clear']();for(let _0x3d1942=0x0;_0x3d1942<_0x5ba057['length'];_0x3d1942++){const _0x41ea17=_0x5ba057[_0x3d1942];let _0x3b9348=!0x1;for(const _0x303443 of Object['keys'](_0x41ea17))void 0x0===_0x41ea17[_0x303443]?delete _0x41ea17[_0x303443]:'id'!==_0x303443&&(_0x3b9348=!0x0);_0x3b9348||(_0x5ba057[_0x3d1942]=null);}if(_0x5ba057=_0x5ba057['filter'](_0x56a47b=>null!==_0x56a47b),!_0x5ba057['length'])return;for(let _0x111d65=0x0;_0x111d65<_0x5ba057['length'];_0x111d65++){const _0xe8adc7=_0x5ba057[_0x111d65];void 0x0!==_0xe8adc7['fromVersion']&&void 0x0===_0xe8adc7['toVersion']&&(_0xe8adc7['toVersion']=this['repository']['getRevision'](_0xe8adc7['id'])['toVersion']),void 0x0!==_0xe8adc7['toVersion']&&void 0x0===_0xe8adc7['fromVersion']&&(_0xe8adc7['fromVersion']=this['repository']['getRevision'](_0xe8adc7['id'])['fromVersion']);}const _0x1204ab=this['editor']['config']['get']('collaboration.channelId');this['_isPendingUpdate']=!0x0,this['_addPendingAction'](),this['adapter']['updateRevisions'](_0x5ba057,_0x1204ab)['finally'](()=>{this['_isPendingUpdate']=!0x1;})['then'](_0x307784=>{if(_0x307784){for(const _0x966bb2 of _0x307784)this['setRevisionData']({'id':_0x966bb2['id'],'createdAt':_0x966bb2['createdAt']});}this['_removePendingAction'](),this['sendBufferedUpdates']();});}['buildRevisionData']({revision:_0x35ce68=null,from:_0x11d328=null,to:_0x56b483=null}){_0x11d328=null!==_0x11d328?_0x11d328:_0x35ce68['fromVersion'],_0x56b483=null!==_0x56b483?_0x56b483:_0x35ce68['toVersion'];const _0x40b0c8=this['_revisionDataBuilder']['getData'](_0x11d328,_0x56b483),_0x309029={'diffData':_0x40b0c8['diffData'],'authorsIds':_0x40b0c8['authorsIds'],'fromVersion':_0x11d328,'toVersion':_0x56b483};if(!_0x35ce68||_0x56b483!==_0x35ce68['toVersion']){const _0xa808f7=_0x56b483-0x1,_0x4d14bd=this['_source']['history']['getOperation'](_0xa808f7);_0x309029['createdAt']=_0x4d14bd&&_0x4d14bd['createdAt']||new Date();}if(this['_loadedStateData']&&_0x11d328===this['_loadedStateData']['fromVersion']){for(const _0x2b9376 of this['_loadedStateData']['authors'])_0x309029['authorsIds']['includes'](_0x2b9376['id'])||_0x309029['authorsIds']['push'](_0x2b9376['id']);}return _0x309029;}['_bufferUpdate'](_0x3a1e86,_0xdd2e2d,_0xd66497){if(this['_bufferedUpdates']['has'](_0x3a1e86)){const _0x49087d=this['_bufferedUpdates']['get'](_0x3a1e86);_0xdd2e2d=_0xd66497?{..._0x49087d,..._0xdd2e2d}:{..._0xdd2e2d,..._0x49087d};}this['_bufferedUpdates']['set'](_0x3a1e86,_0xdd2e2d);}['setRevisionData'](_0x32775d){const _0x8e7974=this['repository']['getRevision'](_0x32775d['id']);if(_0x32775d['createdAt']&&(_0x32775d['createdAt']=new Date(_0x32775d['createdAt'])),_0x32775d['authorsIds']){const _0x501b10=this['editor']['plugins']['get']('Users');_0x32775d['authors']=_0x32775d['authorsIds']['map'](_0x2bf27d=>_0x501b10['getUser'](_0x2bf27d));}_0x8e7974['_update'](_0x32775d,!0x0);}['_createInitialRevision'](_0x3c7094){const _0x18a8ff=this['repository']['getRevision'](this['repository']['length']-0x1);if(_0x18a8ff)this['_initialRevisionId']=_0x18a8ff['id'];else{const _0x4300aa=!this['editor']['model']['document']['roots']['find'](_0x48dd74=>this['editor']['model']['hasContent'](_0x48dd74)),_0x15552d=this['editor']['plugins']['get']('Users')['me']['id'],_0x3466bd=g(this['editor']['locale'],_0x4300aa?'Empty\x20document':'Initial\x20revision');this['_makeRevision']({'from':_0x3c7094,'to':_0x3c7094,'id':this['_initialRevisionId'],'name':_0x3466bd,'creatorId':_0x15552d});}}['_createCurrentRevision'](_0x191cc2){const _0x17d1dd=this['_source']['getCurrentRevisionId']();this['currentRevision']=this['repository']['getRevision'](_0x17d1dd),this['currentRevision']||(this['currentRevision']=this['_makeRevision']({'from':_0x191cc2,'to':_0x191cc2,'id':_0x17d1dd,'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'](_0x33286e,_0x1e5b18){let _0xa059e=this['editor']['config']['get']('initialData'),_0x18e6a8=this['editor']['config']['get']('rootsAttributes');if(void 0x0===_0xa059e){_0xa059e={};for(const _0x4222ff of this['editor']['model']['document']['getRootNames']())_0xa059e[_0x4222ff]='';}if('string'==typeof _0xa059e&&(_0xa059e={'main':_0xa059e}),void 0x0===_0x18e6a8){_0x18e6a8={};for(const _0x4cc14a of this['editor']['model']['document']['getRootNames']())_0x18e6a8[_0x4cc14a]={};}let _0x433f6c=!0x1;const _0x246515=Object['keys'](_0xa059e),_0x1d0ecb=Object['keys'](_0x33286e);for(const _0x223ca9 of _0x246515){if(_0xa059e[_0x223ca9]!==_0x33286e[_0x223ca9]&&''!==_0xa059e[_0x223ca9]['trim']()){_0x433f6c=!0x0;break;}if(!_0x288261(_0x18e6a8[_0x223ca9],_0x1e5b18[_0x223ca9])&&Object['keys'](_0x18e6a8[_0x223ca9])['length']>0x0){_0x433f6c=!0x0;break;}}_0x433f6c||(_0x433f6c=_0x1d0ecb['some'](_0x45e751=>!this['editor']['model']['document']['getRoot'](_0x45e751))),_0x433f6c&&_0x7fc39e('editor-initial-data-replaced-with-revision-data',{'editorData':_0xa059e,'editorRootsAttributes':_0x18e6a8,'revisionData':_0x33286e,'revisionRootsAttributes':_0x1e5b18}),this['editor']['config']['set']('initialData',_0x33286e),this['editor']['config']['set']('rootsAttributes',_0x1e5b18);}['_addPendingAction'](){if(!this['_pendingAction']){const _0x5522b5=this['editor']['plugins']['get']('PendingActions');this['_pendingAction']=_0x5522b5['add'](g(this['editor']['locale'],'PENDING_ACTION_REVISION_HISTORY'));}}['_removePendingAction'](){this['_pendingAction']&&(this['editor']['plugins']['get']('PendingActions')['remove'](this['_pendingAction']),this['_pendingAction']=null);}['_findInsertionIndex'](_0x3bd8fd){const _0x3c7192=this['repository']['getRevisions']();_0x3c7192['reverse']();let _0x5a5fb4=0x0;for(;_0x5a5fb4<_0x3c7192['length'];){const _0xef68c5=_0x3c7192[_0x5a5fb4];if(_0xef68c5===this['currentRevision']){_0x5a5fb4++;continue;}if(_0xef68c5['id']===this['_initialRevisionId'])break;const _0x2e5e11=_0x3bd8fd['toVersion']-_0xef68c5['toVersion']||_0x3bd8fd['fromVersion']-_0xef68c5['fromVersion'];if(_0x2e5e11>0x0)break;if(_0x2e5e11<0x0)_0x5a5fb4++;else{if(!_0x3bd8fd['creator']&&_0xef68c5['creator'])break;if(_0xef68c5['creator']||!_0x3bd8fd['creator']){if(_0x3bd8fd['createdAt']>_0xef68c5['createdAt'])break;_0x5a5fb4++;}else _0x5a5fb4++;}}return _0x5a5fb4;}['_getFromVersion'](_0x39536c){const _0x5095d2=this['repository']['getRevisions']();_0x5095d2['reverse'](),_0x5095d2['shift']();const _0xac42a6=_0x5095d2['find'](_0x1b18d1=>_0x1b18d1['toVersion']<=_0x39536c)['toVersion'];return _0xac42a6<this['_startingVersion']?this['_startingVersion']:_0xac42a6;}['_makeRevision']({name:_0x1ba3f7,from:_0x4ef11b,to:_0x147e01,creatorId:_0x5cdb4b,id:_0x29d4ca}){const _0x323619=this['buildRevisionData']({'from':_0x4ef11b,'to':_0x147e01});_0x323619['name']=_0x1ba3f7,_0x323619['creatorId']=_0x5cdb4b,_0x323619['id']=_0x29d4ca;const _0x306805=this['addRevisionData'](_0x323619);return this['adapter']&&this['_bufferUpdate'](_0x323619['id'],_0x323619,!0x0),_0x306805;}['_setConversion'](){this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'});}}class x{['editor'];['source'];['_savedMetaData'];['_lastFrom'];['_lastTo'];['_markers'];['_diffRoots'];['_diffRootsAttributes'];['_baseRoots'];['_baseRootsAttributes'];['_idsRoots'];['_baseIdsRoots'];['_touched'];['_touchedMarkers'];['_touchedRoots'];['_revisionId'];['_startingRevisionId'];constructor(_0x31f4ee){this['editor']=_0x31f4ee,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'](_0x4f92bb){this['source']=_0x4f92bb;const _0x3eb812=new Map(),_0x4294a3=new Map(),_0x25ee90=this['editor']['model']['document']['roots']['map'](_0x4c14bc=>_0x4c14bc['rootName']);for(const _0x48bc7d of _0x25ee90){const _0x319e37=this['editor']['model']['document']['getRoot'](_0x48bc7d),_0x4105ce=N(_0x319e37);_0x3eb812['set'](_0x48bc7d,_0x4105ce),_0x4294a3['set'](_0x48bc7d,Object['fromEntries'](_0x319e37['getAttributes']()));}const _0x3d7248=Array['from'](this['editor']['model']['markers'])['map'](_0x5943fa=>[_0x5943fa['name'],_0x5943fa['getRange']()]),_0x1e6118=this['source']['version'];this['_saveMetaData'](_0x1e6118,_0x3eb812,_0x3d7248,_0x4294a3),this['_startingRevisionId']=this['_revisionId'];const _0x290e11=new Map(),_0x2dc3c3=new Map();for(const _0x5e0968 of _0x25ee90){const _0x250119=P(_0x5e0968);_0x290e11['set'](_0x5e0968,_0x250119),_0x2dc3c3['set'](_0x5e0968,{});}this['_saveMetaData'](Number['NEGATIVE_INFINITY'],_0x290e11,[],_0x2dc3c3);}['getData'](_0x2f0632,_0x4ff2b4){if(this['_lastFrom']===_0x2f0632&&this['_lastTo']<=_0x4ff2b4)this['_savedMetaData']['size']>0x1&&this['_removeMetaData'](this['_lastTo']),this['_applyOperations'](this['_lastTo'],_0x4ff2b4,!0x0);else{if(!this['_savedMetaData']['has'](_0x2f0632)){const _0x3475b5=this['_getPreviousFrom'](_0x2f0632);this['_calculateMetaData'](_0x3475b5,_0x2f0632,!0x1);}this['_calculateMetaData'](_0x2f0632,_0x4ff2b4,!0x0);}return this['_lastFrom']=_0x2f0632,this['_lastTo']=_0x4ff2b4,this['_getState']();}['loadState'](_0x4ab19a){const _0x4ce680=this['editor']['plugins']['get']('RevisionHistoryUtils');this['_reset'](),this['_lastFrom']=_0x4ab19a['fromVersion'],this['_lastTo']=_0x4ab19a['toVersion'];for(const _0x17639a in _0x4ab19a['diffData']){const _0x3293e6=_0x4ab19a['diffData'][_0x17639a]['attachChange'],_0x15e4ed=_0x1aa9b4(_0x4ab19a['diffData'][_0x17639a]['attributesBefore'])||{},_0x373ef0=_0x4ce680['_makeModelFromViewString'](_0x4ab19a['diffData'][_0x17639a]['deletions']);_0x373ef0['rootName']=_0x17639a,_0x373ef0['_isAttached']=!_0x3293e6||!_0x3293e6['isAttached'],_0x373ef0['isAttached']=()=>_0x373ef0['_isAttached'],this['_baseRoots']['set'](_0x17639a,_0x373ef0),this['_baseRootsAttributes']['set'](_0x17639a,_0x15e4ed),_0x3293e6&&this['_touchedRoots']['set'](_0x17639a,_0x3293e6);const _0x1cf8e7=this['_makeIdsRoot'](_0x373ef0);this['_baseIdsRoots']['set'](_0x17639a,_0x1cf8e7);for(const [_0x119ed7,_0x2d0c9f]of _0x373ef0['markers']){if(!_0x119ed7['startsWith']('revision:'))continue;const _0x37a807=_0x119ed7['split'](':')[0x2];for(const _0x4faf18 of _0x2d0c9f['getWalker']({'singleCharacters':!0x0})){const _0x4a58c3=this['_getVidAttributeName'](_0x4faf18),_0x2847fa='elementEnd'==_0x4faf18['type']?_0x4faf18['previousPosition']['path']['slice'](0x0,-0x1):_0x4faf18['previousPosition']['path'],_0x43ce6b=_0x1cf8e7['getNodeByPath'](_0x2847fa)['getAttribute'](_0x4a58c3);this['_touched']['set'](_0x43ce6b,{'userId':_0x37a807});}}}this['_startingRevisionId']=this['_revisionId'];const _0x43f562=[...Array(this['_revisionId'])['keys']()]['slice'](0x1)['filter'](_0x51a9a5=>!this['_touched']['has'](_0x51a9a5));let _0x134f2a=0x0;const _0x33df74=new Map();for(const _0x169b16 in _0x4ab19a['diffData']){const _0x192bb1=_0x4ab19a['diffData'][_0x169b16]['attachChange'],_0x5494bd=_0x1aa9b4(_0x4ab19a['diffData'][_0x169b16]['attributesAfter'])||{},_0x1e5345=_0x4ce680['_makeModelFromViewString'](_0x4ab19a['diffData'][_0x169b16]['insertions']);_0x1e5345['rootName']=_0x169b16,_0x1e5345['_isAttached']=!_0x192bb1||_0x192bb1['isAttached'],_0x1e5345['isAttached']=()=>_0x1e5345['_isAttached'],this['_diffRoots']['set'](_0x169b16,_0x1e5345),this['_diffRootsAttributes']['set'](_0x169b16,_0x5494bd);const _0x4e18be=this['_makeIdsRoot'](_0x1e5345,Number['NEGATIVE_INFINITY']);this['_idsRoots']['set'](_0x169b16,_0x4e18be),_0x33df74['set'](_0x169b16,_0x1e5345['isAttached']()?_0x5494bd:{});for(const [_0x5809b7,_0x4aa0e3]of _0x1e5345['markers']){if(!_0x5809b7['startsWith']('revision:'))continue;const _0x3dbc71=_0x5809b7['split'](':')[0x2];for(const _0x45e8b3 of _0x4aa0e3['getWalker']({'singleCharacters':!0x0})){const _0x4905a6=this['_getVidAttributeName'](_0x45e8b3),_0x4ca992=this['_revisionId']++,_0x1d56a5='elementEnd'==_0x45e8b3['type']?_0x45e8b3['previousPosition']['path']['slice'](0x0,-0x1):_0x45e8b3['previousPosition']['path'];_0x4e18be['getNodeByPath'](_0x1d56a5)['_setAttribute'](_0x4905a6,_0x4ca992),this['_touched']['set'](_0x4ca992,{'userId':_0x3dbc71});}}for(const _0x274dd3 of this['editor']['model']['createRangeIn'](_0x1e5345)['getWalker']({'singleCharacters':!0x0})){const _0x5635c0=this['_getVidAttributeName'](_0x274dd3),_0x56ec15='elementEnd'==_0x274dd3['type']?_0x274dd3['previousPosition']['path']['slice'](0x0,-0x1):_0x274dd3['previousPosition']['path'],_0x5abe23=_0x4e18be['getNodeByPath'](_0x56ec15);_0x5abe23['getAttribute'](_0x5635c0)>0x0||_0x5abe23['_setAttribute'](_0x5635c0,_0x43f562[_0x134f2a++]);}for(const [_0x1983a6,_0x5aecaa]of _0x1e5345['markers'])_0x1983a6['startsWith']('revision:')||this['_markers']['set'](_0x1983a6,_0x5aecaa);}const _0x596a20=P('$graveyard');this['_baseRoots']['set']('$graveyard',_0x596a20),this['_baseIdsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x596a20,0x1));const _0x2351ba=P('$graveyard');this['_diffRoots']['set']('$graveyard',_0x2351ba),this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x2351ba,0x1));const _0x32c55a=Array['from'](this['_diffRoots'])['map'](([_0xecfb9c,_0x3a3990])=>[_0xecfb9c,N(_0x3a3990)]);this['_saveMetaData'](this['_lastTo'],_0x32c55a,this['_markers'],_0x33df74);}['reInit'](){this['_reset'](),this['_lastFrom']=-0x1,this['_lastTo']=-0x1,this['_savedMetaData']['clear'](),this['init'](this['source']);}['_saveMetaData'](_0x10a09a,_0x475b2a,_0x513af3,_0x3a3f0c){const _0x2a8e76=new Map(_0x475b2a),_0x101905=new Map(_0x1aa9b4(_0x3a3f0c)),_0x3fdedb=new Map();for(const [_0x26c5b4,_0x52d53c]of _0x513af3)_0x3fdedb['set'](_0x26c5b4,{'start':_0x52d53c['start']['clone'](),'end':_0x52d53c['end']['clone'](),'rootName':_0x52d53c['root']['rootName']});this['_savedMetaData']['set'](_0x10a09a,{'roots':_0x2a8e76,'markers':_0x3fdedb,'rootsAttributes':_0x101905});}['_removeMetaData'](_0x32953d){this['_savedMetaData']['delete'](_0x32953d);}['_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'](_0xc13af,_0x4c1574=null){let _0x257060=null;_0xc13af['is']('documentFragment')||(_0x257060=new ut(_0xc13af['name'],{'vid_start':null===_0x4c1574?this['_revisionId']++:_0x4c1574++}));const _0x46f9e2=[];for(const _0x39200d of _0xc13af['getChildren']())if(_0x39200d['is']('element')){_0x46f9e2['push'](this['_makeIdsRoot'](_0x39200d,_0x4c1574));const _0x532286=_0x46f9e2[_0x46f9e2['length']-0x1];null!==_0x4c1574&&(_0x4c1574=_0x532286['is']('element','$text')?_0x532286['getAttribute']('vid')+0x1:_0x532286['getAttribute']('vid_end')+0x1);}else{for(let _0x6a30e2=0x0;_0x6a30e2<_0x39200d['offsetSize'];_0x6a30e2++)_0x46f9e2['push'](new ut('$text',{'vid':null===_0x4c1574?this['_revisionId']++:_0x4c1574++}));}if(_0xc13af['is']('documentFragment')){const _0x5a86cc=P(_0xc13af['rootName']);return _0x5a86cc['_insertChild'](0x0,_0x46f9e2),_0x5a86cc;}return _0x257060['_setAttribute']('vid_end',null===_0x4c1574?this['_revisionId']++:_0x4c1574++),_0x257060['_insertChild'](0x0,_0x46f9e2),_0x257060;}['_calculateMetaData'](_0x3298f7,_0x4f30e9,_0x320f82){this['_reset']();const {roots:_0xe15c81,markers:_0x2b8a1b,rootsAttributes:_0x544d95}=this['_savedMetaData']['get'](_0x3298f7);this['_baseRoots']=new Map(_0xe15c81),this['_baseRootsAttributes']=new Map(_0x1aa9b4(_0x544d95));for(const [_0x156906,_0x4e7cad]of this['_baseRoots'])if('$graveyard'!==_0x156906&&(this['_diffRoots']['set'](_0x156906,N(_0x4e7cad)),this['_diffRootsAttributes']=new Map(_0x1aa9b4(_0x544d95)),_0x320f82)){const _0x41270d=this['_revisionId'];this['_idsRoots']['set'](_0x156906,this['_makeIdsRoot'](_0x4e7cad)),this['_baseIdsRoots']['set'](_0x156906,this['_makeIdsRoot'](_0x4e7cad,_0x41270d));}this['_startingRevisionId']=this['_revisionId'],this['_diffRoots']['set']('$graveyard',N(this['_baseRoots']['get']('$graveyard'))),_0x320f82&&this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](this['_baseRoots']['get']('$graveyard')));for(const [_0x95f8e4,_0x4ab439]of _0x2b8a1b){const _0x229586=this['_baseRoots']['get'](_0x4ab439['rootName']),_0x3b3a38=this['_diffRoots']['get'](_0x4ab439['rootName']),_0x51e206=new lt(this['_fixPosition'](_0x4ab439['start'],_0x229586),this['_fixPosition'](_0x4ab439['end'],_0x229586)),_0x5cbde6=this['_fixRange'](_0x51e206,_0x3b3a38);_0x229586['markers']['set'](_0x95f8e4,_0x51e206),this['_markers']['set'](_0x95f8e4,_0x5cbde6);}this['_applyOperations'](_0x3298f7,_0x4f30e9,_0x320f82);}['_applyOperations'](_0x496f4b,_0x4e2068,_0x256eeb){for(const _0x2d5d03 of this['source']['getOperations'](_0x496f4b,_0x4e2068))this['_handleOperation'](_0x2d5d03,_0x256eeb);for(const _0x5cfd2a of this['_diffRoots']['values']())_0x5cfd2a['markers']['clear']();for(const [_0x44946a,_0x2c623c]of this['_markers']){this['_diffRoots']['get'](_0x2c623c['root']['rootName'])['markers']['set'](_0x44946a,_0x2c623c['clone']());}const _0x532c5c=new Map(),_0x34aaae=new Map();for(const [_0x4470b9,_0x2e15a2]of this['_diffRoots'])_0x532c5c['set'](_0x4470b9,N(_0x2e15a2)),_0x34aaae['set'](_0x4470b9,this['_diffRootsAttributes']['get'](_0x4470b9));this['_saveMetaData'](_0x4e2068,_0x532c5c,this['_markers'],_0x34aaae);}['_getPreviousFrom'](_0x300d29){const _0x59aca1=Array['from'](this['_savedMetaData']['keys']());_0x59aca1['sort']((_0x3905e3,_0x132232)=>_0x3905e3-_0x132232),_0x59aca1['reverse']();for(const _0x105a26 of _0x59aca1)if(_0x105a26<_0x300d29)return _0x105a26;return Number['NEGATIVE_INFINITY'];}['_copyMarkers'](_0x436e20,_0x42ee4a){const _0x49b005=Array['from'](_0x42ee4a['markers'])['map'](([_0x33b435,_0xaa2dde])=>[_0x33b435,this['_fixRange'](_0xaa2dde,_0x436e20)]);_0x436e20['markers']=new Map(_0x49b005);}['_transformMarkers'](_0x459c0e){for(const _0x540b10 of this['_markers']['values']()){const _0x3b0015=_0x540b10['getTransformedByOperation'](_0x459c0e),_0x494285=lt['_createFromRanges'](_0x3b0015);_0x540b10['start']=_0x494285['start'],_0x540b10['end']=_0x494285['end'];}}['_handleOperation'](_0x269f04,_0x134b58){if('addRoot'!=_0x269f04['type']&&'detachRoot'!=_0x269f04['type']){if('insert'==_0x269f04['type']){const _0x2a8f87=_0x269f04['position']['root']['rootName'];this['_diffRoots']['has'](_0x2a8f87)||(this['_diffRoots']['set'](_0x2a8f87,P(_0x2a8f87,!0x0)),this['_diffRootsAttributes']['set'](_0x2a8f87,{}),_0x134b58&&this['_idsRoots']['set'](_0x2a8f87,P(_0x2a8f87,!0x0)));}else{if('addRootAttribute'==_0x269f04['type']||'removeRootAttribute'==_0x269f04['type']||'changeRootAttribute'==_0x269f04['type'])return void this['_handleRootAttributeOperation'](_0x269f04);'marker'==_0x269f04['type']&&this['_handleMarkerOperation'](_0x269f04);}if('marker'!==_0x269f04['type']){const _0x553867=this['_cloneOperation'](_0x269f04,this['_diffRoots']);_0x553867['_execute'](),this['_transformMarkers'](_0x553867);}if(_0x134b58)switch(_0x269f04['type']){case'insert':this['_handleInsertOperation'](_0x269f04);break;case'move':case'remove':case'reinsert':this['_handleMoveOperation'](_0x269f04);break;case'merge':this['_handleMergeOperation'](_0x269f04);break;case'split':this['_handleSplitOperation'](_0x269f04);}}else this['_handleRootOperation'](_0x269f04,_0x134b58);}['_cloneOperation'](_0x583c27,_0x39a8bf){const _0x5f22d4=_0x583c27['clone']();return _0x5f22d4['_authorId']=_0x583c27['_authorId'],this['_fixOperation'](_0x5f22d4,_0x39a8bf),_0x5f22d4;}['_getBaseVids'](_0x13bc9a){return _0x13bc9a['map'](_0x3740a3=>{const _0x2f0be6=this['_getVidAttributeName'](_0x3740a3);return Number(_0x3740a3['item']['getAttribute'](_0x2f0be6));});}['_generateTape'](_0x31ed68,_0x5733cd){if(_0x31ed68['is']('element','$text'))_0x5733cd['push']({'item':_0x31ed68,'type':'text'});else{_0x31ed68['is']('element')&&_0x5733cd['push']({'item':_0x31ed68,'type':'elementStart'});for(const _0x3caf5d of _0x31ed68['getChildren']())this['_generateTape'](_0x3caf5d,_0x5733cd);_0x31ed68['is']('element')&&_0x5733cd['push']({'item':_0x31ed68,'type':'elementEnd'});}return _0x5733cd;}['_getState'](){const _0x3a7e9d=new Map(this['_touched']),_0xa66c3d=new Map(_0x3a7e9d),_0x4ce397=new Map(),_0x1848d5={'insertions':{},'deletions':{}},_0x432409={'insertions':{},'deletions':{}},_0xa8f2ca=new Map(),_0x21984b=new Set([...this['_baseRoots']['keys'](),...this['_diffRoots']['keys']()]);_0x21984b['delete']('$graveyard');for(const _0x59d6b4 of _0x21984b){const _0x875c98=this['_diffRoots']['get'](_0x59d6b4)||P(_0x59d6b4,!0x1),_0xba501a=this['_baseRoots']['get'](_0x59d6b4)||P(_0x59d6b4,!0x1);_0x875c98['isAttached']()||_0xba501a['isAttached']()?(_0x1848d5['insertions'][_0x59d6b4]=N(_0x875c98),_0x1848d5['deletions'][_0x59d6b4]=N(_0xba501a),this['_copyMarkers'](_0x1848d5['deletions'][_0x59d6b4],_0xba501a),this['_copyMarkers'](_0x1848d5['insertions'][_0x59d6b4],_0x875c98),_0x432409['insertions'][_0x59d6b4]=this['_generateTape'](this['_idsRoots']['get'](_0x59d6b4),[]),_0x432409['deletions'][_0x59d6b4]=this['_generateTape'](this['_baseIdsRoots']['get'](_0x59d6b4)||P(_0x59d6b4,!0x1),[])):_0x21984b['delete'](_0x59d6b4);}for(const _0x335d1c of _0x21984b){const _0x1195ef=_0x432409['insertions'][_0x335d1c];for(const _0x561782 of _0x1195ef){const _0x59dada=this['_getVidAttributeName'](_0x561782),_0x100e7c=_0x561782['item']['getAttribute'](_0x59dada);_0xa66c3d['delete'](_0x100e7c),_0x100e7c>=this['_startingRevisionId']&&_0x4ce397['set'](_0x100e7c,_0x3a7e9d['get'](_0x100e7c));}}for(const _0x387dde of _0x21984b){const _0xed6e10=_0x432409['insertions'][_0x387dde],_0x8245d3=this['_getBaseVids'](_0x432409['deletions'][_0x387dde]);let _0x8078a2=0x0;for(const _0x571e50 of _0xed6e10){const _0x4301dd=this['_getVidAttributeName'](_0x571e50),_0x1afe55=_0x571e50['item']['getAttribute'](_0x4301dd);if(!_0x4ce397['has'](_0x1afe55)&&!_0xa8f2ca['has'](_0x1afe55)){if(_0xa66c3d['has'](_0x1afe55))_0x8078a2++;else{if(_0x1afe55!=_0x8245d3[_0x8078a2]){const _0x143fd3=_0x3a7e9d['get'](_0x1afe55)||_0x3a7e9d['get'](_0x8245d3[_0x8078a2]);for(;_0x1afe55!=_0x8245d3[_0x8078a2];)_0xa66c3d['has'](_0x8245d3[_0x8078a2])||(_0xa8f2ca['set'](_0x8245d3[_0x8078a2],_0x143fd3),_0x3a7e9d['set'](_0x8245d3[_0x8078a2],_0x143fd3)),_0x8078a2++;}_0x8078a2++;}}}}for(const _0x5621cb of _0x21984b){const _0x4dfa0d=_0x432409['insertions'][_0x5621cb];for(const _0x2d2a2c of _0x4dfa0d){const _0x1788c7=this['_getVidAttributeName'](_0x2d2a2c),_0x368ef9=_0x2d2a2c['item']['getAttribute'](_0x1788c7);if(_0xa8f2ca['has'](_0x368ef9)){const _0x5e9ba6=_0xa8f2ca['get'](_0x368ef9);_0xa66c3d['has'](_0x368ef9)||_0xa66c3d['set'](_0x368ef9,{..._0x5e9ba6}),_0x4ce397['set'](_0x368ef9,{..._0x5e9ba6});}}}for(const _0x3291db of _0xa66c3d['keys']())_0x3291db>=this['_startingRevisionId']&&_0xa66c3d['delete'](_0x3291db);const _0x18c765=new Map();for(const _0x5c5e18 of _0x21984b){let _0x2b87ff=_0x432409['insertions'][_0x5c5e18];for(const _0x3da8f9 of _0x2b87ff)if(_0x3da8f9['item']['is']('element','tableCell')){const _0x104bc5=this['_getVidAttributeName'](_0x3da8f9),_0x5d2535=_0x3da8f9['item']['getAttribute'](_0x104bc5);if(_0x4ce397['has'](_0x5d2535)){const _0x228d2c=_0x3da8f9['item']['parent']['parent']['getAttribute']('vid_start'),_0x3bb157=_0x18c765['get'](_0x228d2c)||new Set();_0x3bb157['add'](_0x4ce397['get'](_0x5d2535)['userId']),_0x18c765['set'](_0x228d2c,_0x3bb157);}}_0x2b87ff=_0x432409['deletions'][_0x5c5e18];for(const _0xb1d83e of _0x2b87ff)if(_0xb1d83e['item']['is']('element','tableCell')){const _0x4fda5d=this['_getVidAttributeName'](_0xb1d83e),_0x15758e=_0xb1d83e['item']['getAttribute'](_0x4fda5d);if(_0xa66c3d['has'](_0x15758e)){const _0xae8900=_0xb1d83e['item']['parent']['parent']['getAttribute']('vid_start'),_0x142069=_0x18c765['get'](_0xae8900)||new Set();_0x142069['add'](_0xa66c3d['get'](_0x15758e)['userId']),_0x18c765['set'](_0xae8900,_0x142069);}}for(const _0x1be67f of _0x18c765['keys']())(_0x4ce397['has'](_0x1be67f)||_0xa66c3d['has'](_0x1be67f))&&_0x18c765['delete'](_0x1be67f);}for(const _0x426d7a of _0x21984b){const _0x288ce2=_0x432409['insertions'][_0x426d7a];let _0x16f2e5=null,_0x6cdd44=null;for(const _0x1dcd12 of _0x288ce2){const _0x1a3a45=this['_getVidAttributeName'](_0x1dcd12),_0x57f848=_0x1dcd12['item']['getAttribute'](_0x1a3a45),_0x4230a1=_0x18c765['get'](_0x57f848);_0x4230a1&&'elementStart'==_0x1dcd12['type']&&(_0x16f2e5=Array['from'](_0x4230a1)[0x0],_0x6cdd44=_0x1dcd12['item']['getAttribute']('vid_end')),_0x16f2e5&&(_0xa66c3d['set'](_0x57f848,{'userId':_0x16f2e5}),_0x4ce397['set'](_0x57f848,{'userId':_0x16f2e5})),_0x57f848==_0x6cdd44&&(_0x16f2e5=null,_0x6cdd44=null);}}const _0x3cd972={},_0x3107b9=new Set();for(const _0x3b8da3 of _0x21984b){const _0x825fb9=_0x1848d5['deletions'][_0x3b8da3],_0x10599f=_0x1848d5['insertions'][_0x3b8da3];for(const {userId:_0x58c5c3}of this['_touchedMarkers']['values']())null!==_0x58c5c3&&_0x3107b9['add'](_0x58c5c3);for(const {userId:_0xe55036}of this['_touchedRoots']['values']())null!==_0xe55036&&_0x3107b9['add'](_0xe55036);this['_markChanges'](_0x10599f,_0x432409['insertions'][_0x3b8da3],_0x4ce397,'insertion',_0x3107b9),this['_markChanges'](_0x825fb9,_0x432409['deletions'][_0x3b8da3],_0xa66c3d,'deletion',_0x3107b9),_0x3cd972[_0x3b8da3]={'insertions':this['_prepareViewToSave'](_0x10599f),'deletions':this['_prepareViewToSave'](_0x825fb9),'attachChange':this['_touchedRoots']['get'](_0x3b8da3)||null,'attributesBefore':_0x1aa9b4(this['_baseRootsAttributes']['get'](_0x3b8da3))||{},'attributesAfter':_0x1aa9b4(this['_diffRootsAttributes']['get'](_0x3b8da3))};}return{'diffData':_0x3cd972,'authorsIds':Array['from'](_0x3107b9)};}['_processRootBeforeSave'](_0x5b52f3){for(const [,_0x57c8e5]of _0x5b52f3['markers']){const _0x13b44e=_0x57c8e5['start']['getAncestors']()['filter'](_0x147377=>'tableCell'==_0x147377['name']);for(const _0x27a32a of _0x13b44e)0x1==_0x27a32a['childCount']&&_0x27a32a['getChild'](0x0)['is']('element','paragraph')&&_0x27a32a['getChild'](0x0)['_setAttribute']('keepParagraph',!0x0);}}['_prepareViewToSave'](_0x5384c0){this['_processRootBeforeSave'](_0x5384c0);const _0x2c9e5a=this['editor']['data']['toView'](_0x5384c0,{}),_0x162835=Array['from'](_0x2c9e5a['getChildren']())['map'](_0x3df7ee=>this['_getViewJson'](_0x3df7ee));return JSON['stringify'](_0x162835);}['_getViewJson'](_0x532150){if(_0x532150['is']('$text'))return _0x532150['data'];{const _0x153e58=this['editor']['plugins']['get']('RevisionHistoryUtils'),_0x159237=_0x532150,_0x26dae3=this['editor']['data']['htmlProcessor']['domConverter'],_0x5ed4d9={'type':_0x153e58['_getTypeCharForViewElement'](_0x159237),'name':_0x159237['name'],'attributes':Array['from'](_0x159237['getAttributes']()),'children':Array['from'](_0x159237['getChildren']())['map'](_0x512534=>this['_getViewJson'](_0x512534))};if(_0x532150['is']('uiElement')&&'$comment'!=_0x532150['name']){const _0x4a5f32=_0x532150['render'](_0x26dae3['domDocument'],_0x26dae3);_0x5ed4d9['children']['push'](_0x4a5f32['outerHTML']);}else{if(_0x532150['is']('rawElement')){const _0x491d46=_0x26dae3['domDocument']['createElement'](_0x159237['name']);_0x532150['render'](_0x491d46,_0x26dae3),_0x5ed4d9['children']['push'](_0x491d46['innerHTML']);}}const _0x5b44be=Array['from'](_0x159237['getCustomProperties']());_0x5b44be['length']>0x0&&(_0x5ed4d9['customProperties']=_0x5b44be);const _0x341293=_0x159237['getFillerOffset']();return null!==_0x341293&&(_0x5ed4d9['fillerOffset']=_0x341293),_0x5ed4d9;}}['_markChanges'](_0x1957df,_0x407036,_0x222291,_0x5cb77f,_0x3a67f9){let _0x1bfef4=null,_0xf280e2=null,_0x14c210=0x0;const _0x3461b2=this['editor']['model'];for(let _0x1b6bda=0x0;_0x1b6bda<_0x407036['length'];_0x1b6bda++){const _0x5ad12b=this['_getVidAttributeName'](_0x407036[_0x1b6bda]),_0xa9117a=_0x407036[_0x1b6bda]['item']['getAttribute'](_0x5ad12b),_0x52d85a=_0x222291['get'](_0xa9117a),_0x50b7a2=_0x1b6bda==_0x407036['length']-0x1;(!_0x1bfef4&&_0x52d85a&&(_0x1bfef4=_0x52d85a,_0xf280e2=_0x407036[_0x1b6bda]),_0x1bfef4&&(!_0x52d85a||_0x52d85a['userId']!=_0x1bfef4['userId']))&&(_0x60a601(_0x52d85a,F(_0xf280e2,_0x1957df,_0x3461b2),F(_0x407036[_0x1b6bda],_0x1957df,_0x3461b2)),_0x1bfef4=_0x52d85a||null,_0xf280e2=_0x52d85a?_0x407036[_0x1b6bda]:null),_0x1bfef4&&_0x50b7a2&&_0x60a601(_0x52d85a,F(_0xf280e2,_0x1957df,_0x3461b2),B(_0x407036[_0x1b6bda],_0x1957df,_0x3461b2));}function _0x60a601(_0x22faac,_0x1a9db8,_0x581a64){const _0xd84699=_0x1bfef4['userId'],_0x1fb9c1='revision:'+_0x5cb77f+':'+_0xd84699+':'+_0x14c210++,_0xfe83f4=_0x3461b2['createRange'](_0x1a9db8,_0x581a64);_0x1957df['markers']['set'](_0x1fb9c1,_0xfe83f4),null!==_0xd84699&&_0x3a67f9['add'](_0xd84699);}}['_getVidAttributeName'](_0xb982e6){switch(_0xb982e6['type']){case'elementStart':return'vid_start';case'elementEnd':return'vid_end';default:return'vid';}}['_fixOperation'](_0x582fc4,_0x174129){_0x582fc4['baseVersion']=null;for(const _0xa3a480 in _0x582fc4){const _0xeea2d1=_0x582fc4[_0xa3a480];if(_0xeea2d1 instanceof ft){const _0x23aeb4=_0x174129['get'](_0xeea2d1['root']['rootName']);_0x582fc4[_0xa3a480]=this['_fixPosition'](_0xeea2d1,_0x23aeb4);}if(_0xeea2d1 instanceof lt){const _0x52783f=_0x174129['get'](_0xeea2d1['root']['rootName']);_0x582fc4[_0xa3a480]=this['_fixRange'](_0xeea2d1,_0x52783f);}'root'===_0xa3a480&&(_0x582fc4['root']=_0x174129['get'](_0x582fc4['root']['rootName']));}}['_fixRange'](_0x11d557,_0x30e9be){return this['editor']['model']['createRange'](this['_fixPosition'](_0x11d557['start'],_0x30e9be),this['_fixPosition'](_0x11d557['end'],_0x30e9be));}['_fixPosition'](_0x5bb087,_0x44efa9){return this['editor']['model']['createPositionFromPath'](_0x44efa9,_0x5bb087['path'],_0x5bb087['stickiness']);}['_handleInsertOperation'](_0x1f0fbe){const _0x458913=this['_idsRoots']['get'](_0x1f0fbe['position']['root']['rootName']),_0x5cda5b=this['_fixPosition'](_0x1f0fbe['position'],_0x458913),_0xc9a7aa=null===_0x1f0fbe['_authorId']?null:_0x1f0fbe['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x4e194a=_0x5cda5b['parent'],_0x388314=this['_revisionId'],_0x403717=[];for(const _0x497618 of _0x1f0fbe['nodes'])if(_0x497618['is']('element'))_0x403717['push'](this['_makeIdsRoot'](_0x497618));else{for(let _0x1b89c0=0x0;_0x1b89c0<_0x497618['offsetSize'];_0x1b89c0++)_0x403717['push'](new ut('$text',{'vid':this['_revisionId']++}));}const _0x4bb09c=this['_revisionId'];for(let _0x36ae0d=_0x388314;_0x36ae0d<_0x4bb09c;_0x36ae0d++)this['_touched']['set'](_0x36ae0d,{'userId':_0xc9a7aa});_0x4e194a['_insertChild'](_0x5cda5b['offset'],_0x403717);}['_handleMoveOperation'](_0x4144a3){(_0x4144a3=this['_cloneOperation'](_0x4144a3,this['_idsRoots']))['_execute']();const _0x5078e4=null===_0x4144a3['_authorId']?null:_0x4144a3['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x4a4810=_0x4144a3['getMovedRangeStart'](),_0x4d1566=_0x4a4810['parent'],_0x2be5a5=_0x4a4810['offset'];!function _0x46cc1f(_0xa6e54c,_0xd97dd4,_0x1b0659,_0x248ede){for(let _0xc62c4c=_0x1b0659;_0xc62c4c<_0x248ede;_0xc62c4c++){const _0x5cd9b6=_0xd97dd4['getChild'](_0xc62c4c);_0x5cd9b6['is']('element','$text')?_0xa6e54c['set'](_0x5cd9b6['getAttribute']('vid'),{'userId':_0x5078e4}):(_0xa6e54c['set'](_0x5cd9b6['getAttribute']('vid_start'),{'userId':_0x5078e4}),_0x46cc1f(_0xa6e54c,_0x5cd9b6,0x0,_0x5cd9b6['childCount']),_0xa6e54c['set'](_0x5cd9b6['getAttribute']('vid_end'),{'userId':_0x5078e4}));}}(this['_touched'],_0x4d1566,_0x2be5a5,_0x2be5a5+_0x4144a3['howMany']);}['_handleMergeOperation'](_0x1971dd){const _0xb25f7a=null===(_0x1971dd=this['_cloneOperation'](_0x1971dd,this['_idsRoots']))['_authorId']?null:_0x1971dd['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x492512=_0x1971dd['targetPosition']['parent'],_0x222a85=_0x1971dd['sourcePosition']['parent'],_0x59910a=_0x492512['getAttribute']('vid_end'),_0x4f3c15=_0x222a85['getAttribute']('vid_start');_0x492512['_setAttribute']('vid_end',_0x222a85['getAttribute']('vid_end')),_0x222a85['_setAttribute']('vid_end',_0x59910a),this['_touched']['set'](_0x4f3c15,{'userId':_0xb25f7a}),this['_touched']['set'](_0x59910a,{'userId':_0xb25f7a}),_0x1971dd['_execute']();}['_handleSplitOperation'](_0x26e55c){const _0x4a2680=null===(_0x26e55c=this['_cloneOperation'](_0x26e55c,this['_idsRoots']))['_authorId']?null:_0x26e55c['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x258f0f=_0x26e55c['graveyardPosition'],_0x1a5180=_0x26e55c['splitPosition']['parent'];_0x26e55c['_execute']();const _0xa4925a=_0x1a5180['getAttribute']('vid_end'),_0x32bfa6=_0x26e55c['insertionPosition']['nodeAfter'];if(_0x258f0f){const _0x2fa15a=_0x32bfa6['getAttribute']('vid_end'),_0x3dbaa3=_0x1a5180['getAttribute']('vid_end');_0x1a5180['_setAttribute']('vid_end',_0x2fa15a),_0x32bfa6['_setAttribute']('vid_end',_0x3dbaa3),this['_touched']['set'](_0x1a5180['getAttribute']('vid_end'),{'userId':_0x4a2680}),this['_touched']['set'](_0x32bfa6['getAttribute']('vid_start'),{'userId':_0x4a2680});}else{const _0x1b7a8e=this['_revisionId']++,_0x125620=this['_revisionId']++;_0x1a5180['_setAttribute']('vid_end',_0x1b7a8e),_0x32bfa6['_setAttribute']('vid_start',_0x125620),_0x32bfa6['_setAttribute']('vid_end',_0xa4925a),this['_touched']['set'](_0x1b7a8e,{'userId':_0x4a2680}),this['_touched']['set'](_0x125620,{'userId':_0x4a2680});}}['_handleMarkerOperation'](_0x2ea678){if(!_0x2ea678['affectsData'])return;const _0xb0ce9f=(_0x2ea678=this['_cloneOperation'](_0x2ea678,this['_diffRoots']))['oldRange']?_0x2ea678['oldRange']['root']:null,_0x8eff76=_0x2ea678['newRange']?_0x2ea678['newRange']['root']:null;_0xb0ce9f&&this['_markers']['delete'](_0x2ea678['name']),_0x8eff76&&this['_markers']['set'](_0x2ea678['name'],_0x2ea678['newRange']['clone']());const _0x596f27=null===_0x2ea678['_authorId']?null:_0x2ea678['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x42fabf=_0x2ea678['name'];if(!this['_touchedMarkers']['has'](_0x42fabf))return void this['_touchedMarkers']['set'](_0x42fabf,{'range':_0x2ea678['oldRange'],'userId':_0x596f27});const _0x5dab00=this['_touchedMarkers']['get'](_0x42fabf),_0x3507c5=_0x5dab00['range'],_0xf9deef=_0x2ea678['newRange'];null==_0x3507c5&&null==_0xf9deef||_0x3507c5&&_0xf9deef&&_0x3507c5['isEqual'](_0xf9deef)?this['_touchedMarkers']['delete'](_0x2ea678['name']):_0x5dab00['userId']=_0x596f27;}['_handleRootOperation'](_0x4de795,_0x44ade3){this['_diffRoots']['has'](_0x4de795['rootName'])?this['_diffRoots']['get'](_0x4de795['rootName'])['_isAttached']=_0x4de795['isAdd']:(this['_diffRoots']['set'](_0x4de795['rootName'],P(_0x4de795['rootName'],!0x0)),this['_diffRootsAttributes']['set'](_0x4de795['rootName'],{}),_0x44ade3&&this['_idsRoots']['set'](_0x4de795['rootName'],P(_0x4de795['rootName'],!0x0)));const _0x47c28c=null===_0x4de795['_authorId']?null:_0x4de795['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x17f85d=this['_touchedRoots']['get'](_0x4de795['rootName']);_0x17f85d&&_0x17f85d['userId']===_0x47c28c?this['_touchedRoots']['delete'](_0x4de795['rootName']):this['_touchedRoots']['set'](_0x4de795['rootName'],{'userId':_0x47c28c,'isAttached':_0x4de795['isAdd']});}['_handleRootAttributeOperation'](_0x31987f){const _0x58e8e4=this['_diffRootsAttributes']['get'](_0x31987f['root']['rootName']);null===_0x31987f['newValue']?delete _0x58e8e4[_0x31987f['key']]:_0x58e8e4[_0x31987f['key']]=_0x31987f['newValue'];}}function N(_0x3c8d8b){const _0x27a1f4=P(_0x3c8d8b['rootName'],_0x3c8d8b['isAttached']());for(const _0x37b971 of _0x3c8d8b['getChildren']()){const _0x51d75d=_0x37b971['_clone'](!0x0);_0x27a1f4['_appendChild'](_0x51d75d);}return _0x27a1f4;}function P(_0x2645c9,_0x366769=!0x0){const _0xd6ae91=new vt();return _0xd6ae91['rootName']=_0x2645c9,_0xd6ae91['_isAttached']=_0x366769,_0xd6ae91['isAttached']=()=>_0xd6ae91['_isAttached'],_0xd6ae91;}function F(_0x169633,_0x211f67,_0x30966e){const _0x120294='elementEnd'==_0x169633['type']?_0x30966e['createPositionAt'](_0x169633['item'],'end'):_0x30966e['createPositionBefore'](_0x169633['item']);return _0x30966e['createPositionFromPath'](_0x211f67,_0x120294['path'],_0x120294['stickiness']);}function B(_0x2f6540,_0x3bbba0,_0x53f93d){const _0x3df851='elementStart'==_0x2f6540['type']?_0x53f93d['createPositionAt'](_0x2f6540['item'],0x0):_0x53f93d['createPositionAfter'](_0x2f6540['item']);return _0x53f93d['createPositionFromPath'](_0x3bbba0,_0x3df851['path'],_0x3df851['stickiness']);}class hs extends ts{['focusTracker'];['keystrokes'];['revisionNameInputView'];constructor(_0x52deb2,_0x3ded85){super(_0x52deb2),this['focusTracker']=new _0x3bfdc2(),this['keystrokes']=new _0x2bc5aa(),this['set']('revisionNameInputValue',''),this['revisionNameInputView']=this['_createRevisionNameInput'](_0x3ded85),this['setTemplate']({'tag':'form','attributes':{'class':['ck','ck-revision-history-save-revision-form','ck-responsive-form'],'tabindex':'-1'},'children':[this['revisionNameInputView']]}),_0x1ef466(this);}['render'](){super['render'](),_0x3461f3({'view':this}),this['focusTracker']['add'](this['revisionNameInputView']['element']),this['keystrokes']['listenTo'](this['element']);const _0x214779=_0x2b98cf=>_0x2b98cf['stopPropagation']();this['keystrokes']['set']('arrowright',_0x214779),this['keystrokes']['set']('arrowleft',_0x214779),this['keystrokes']['set']('arrowup',_0x214779),this['keystrokes']['set']('arrowdown',_0x214779);}['focus'](){this['revisionNameInputView']['focus']();}get['revisionName'](){return this['revisionNameInputView']['fieldView']['element']['value']['trim']();}set['revisionName'](_0x2c4474){this['revisionNameInputView']['fieldView']['element']['value']=_0x2c4474['trim']();}['reset'](){this['revisionNameInputView']['fieldView']['element']['value']='',this['revisionNameInputView']['errorText']=null;}['_createRevisionNameInput'](_0x204b8a){const _0x2d0e93=new _0xd345cd(this['locale'],_0x560f91),_0x339790=_0x2d0e93['fieldView'];_0x339790['extendTemplate']({'attributes':{'maxlength':'220'}});let _0x5a0c55=g(this['locale'],'Name\x20of\x20the\x20revision');return!_0x204b8a&&(_0x5a0c55+='\x20('+g(this['locale'],'optional')+')'),(_0x2d0e93['label']=_0x5a0c55,_0x339790['on']('input',()=>{this['revisionNameInputValue']=_0x339790['element']['value']['trim']();}),_0x2d0e93);}}class f extends _0x311e14{static get['pluginName'](){return'RevisionHistoryUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[u];}['_saveRevisionFormView'];['init'](){const _0x1eaa92=this['editor'],_0x37ab4a=_0x1eaa92['plugins']['get']('RevisionTracker');_0x1eaa92['ui']['componentFactory']['add']('revisionHistory',_0x4758b7=>{const _0x696b8e=_0x1a9092(_0x4758b7),_0x1517d9=_0x696b8e['panelView']['children'],_0x45c61b=new _0x3adb16(_0x4758b7),_0x36cd88=new _0x597a91(_0x4758b7),_0x35b170=new te(_0x4758b7),_0x1abc18=new _0x597a91(_0x4758b7),_0x490d8d=new te(_0x4758b7);return _0x696b8e['bind']('isEnabled')['to'](_0x37ab4a,'isReady',_0x37ab4a,'isEnabled',_0x1eaa92,'isReadOnly',(_0x376a87,_0x165685,_0x2ac10d)=>_0x376a87&&_0x165685&&!_0x2ac10d),_0x696b8e['buttonView']['set']({'icon':_0xd06bb,'label':g(_0x4758b7,'Revision\x20history'),'tooltip':!0x0}),_0x35b170['set']({'label':g(_0x4758b7,'Save\x20current\x20revision'),'withText':!0x0,'role':'menuitem'}),_0x35b170['bind']('isEnabled')['to'](_0x37ab4a,'isReady',_0x37ab4a,'isEnabled',_0x1eaa92,'isReadOnly',(_0x31cd7e,_0x2a91b5,_0x4422a3)=>_0x31cd7e&&_0x2a91b5&&!_0x4422a3),_0x35b170['on']('execute',()=>this['_showDialog']()),_0x490d8d['set']({'label':g(_0x4758b7,'Open\x20revision\x20history'),'withText':!0x0,'role':'menuitem'}),_0x490d8d['bind']('isEnabled')['to'](_0x37ab4a,'isReady',_0x1eaa92,'isReadOnly',(_0xdae2fe,_0x3e57e7)=>_0xdae2fe&&!_0x3e57e7),_0x490d8d['on']('execute',()=>{_0x1eaa92['config']['get']('revisionHistory')['showRevisionViewerCallback'](),_0x696b8e['isOpen']=!0x1,_0x1eaa92['editing']['view']['focus']();}),_0x36cd88['children']['add'](_0x35b170),_0x1abc18['children']['add'](_0x490d8d),_0x45c61b['role']='menu',_0x45c61b['items']['addMany']([_0x36cd88,_0x1abc18]),_0x1517d9['add'](_0x45c61b),_0x696b8e;}),_0x1eaa92['ui']['componentFactory']['add']('menuBar:revisionHistory',()=>this['_registerMenuComponent']());}['_registerMenuComponent'](){const _0xfefb49=this['editor'],_0x14e51b=_0xfefb49['locale'],_0x51baa3=new _0x367280(_0x14e51b),_0x277a6e=new _0x49caa7(_0x14e51b);_0x51baa3['buttonView']['set']({'icon':_0xd06bb,'label':g(_0x14e51b,'Revision\x20history')});const _0x631c82=new _0x58dad7(_0x14e51b,_0x51baa3),_0x5138cb=new _0x4a03b5(_0x14e51b);_0x5138cb['set']({'label':g(_0x14e51b,'Save\x20current\x20revision')}),_0x5138cb['delegate']('execute')['to'](_0x51baa3),_0x5138cb['on']('execute',()=>{this['_showDialog']();}),_0x631c82['children']['add'](_0x5138cb),_0x277a6e['items']['add'](_0x631c82);const _0x3b8030=new _0x58dad7(_0x14e51b,_0x51baa3),_0xedb6d3=new _0x4a03b5(_0x14e51b);return _0xedb6d3['set']({'label':g(_0x14e51b,'Open\x20revision\x20history')}),_0xedb6d3['delegate']('execute')['to'](_0x51baa3),_0xedb6d3['on']('execute',()=>{_0xfefb49['config']['get']('revisionHistory')['showRevisionViewerCallback']();}),_0x3b8030['children']['add'](_0xedb6d3),_0x277a6e['items']['add'](_0x3b8030),_0x51baa3['panelView']['children']['add'](_0x277a6e),_0x51baa3;}['_showDialog'](){const _0x522524=this['editor'],_0xbe8335=_0x522524['locale'],_0x408a29=_0x522524['plugins']['get']('Dialog'),_0x531903=_0x522524['plugins']['get']('RevisionTracker');function _0x561569(_0x585af2){_0x522524['config']['get']('revisionHistory.requireRevisionName')&&''===_0x585af2['revisionName']?_0x585af2['revisionNameInputView']['errorText']=g(_0xbe8335,'The\x20revision\x20name\x20cannot\x20be\x20empty.'):(_0x522524['plugins']['get'](u)['saveRevision']({'name':_0x585af2['revisionName']}),_0x408a29['hide']());}this['_saveRevisionFormView']||(this['_createSaveRevisionFormView'](),this['_saveRevisionFormView']['on']('submit',()=>_0x561569(this['_saveRevisionFormView']))),this['_saveRevisionFormView']['reset'](),_0x408a29['show']({'id':'revisionSave','title':g(_0xbe8335,'Save\x20current\x20revision'),'isModal':!0x0,'content':this['_saveRevisionFormView'],'actionButtons':[{'label':g(_0x522524['locale'],'Cancel'),'withText':!0x0,'onExecute':()=>_0x408a29['hide']()},{'label':g(_0x522524['locale'],'Accept'),'class':'ck-button-action','withText':!0x0,'onCreate'(_0xbd5623){_0xbd5623['bind']('isEnabled')['to'](_0x531903,'isReady',_0x531903,'isEnabled',_0x522524,'isReadOnly',(_0x72d95d,_0x161c1d,_0x348a53)=>_0x72d95d&&_0x161c1d&&!_0x348a53);},'onExecute':()=>_0x561569(this['_saveRevisionFormView'])}]});}['_createSaveRevisionFormView'](){const _0x110962=this['editor'],_0x23f291=_0x110962['locale'];this['_saveRevisionFormView']=new hs(_0x23f291,_0x110962['config']['get']('revisionHistory.requireRevisionName')),this['_saveRevisionFormView']['render']();}}class Q extends ts{['changeId'];['_model'];constructor(_0x1fa7e3,_0x1fc55d){super(_0x1fa7e3),this['_model']=_0x1fc55d,this['changeId']=_0x1fc55d['id'];const _0x30aafc=this['bindTemplate'],_0x4b7446=g(_0x1fa7e3,_0x1fc55d['data']['isSuggestion']?'Suggested\x20by':'add'==_0x1fc55d['type']?'Added\x20by':'Removed\x20by');this['set']('type',_0x1fc55d['type']),this['setTemplate']({'tag':'div','attributes':{'class':['ck-annotation','ck-revision-change',_0x30aafc['to']('type',_0x1e8460=>'ck-revision-change__'+_0x1e8460)],'tabindex':-0x1},'children':[{'tag':'span','children':[{'tag':'span','attributes':{'class':['ck-revision-change__label']},'children':[{'text':_0x4b7446}]},{'text':'\x20'+_0x1fc55d['author']['name']}]}]});}['focus'](){this['element']['focus']();}}class r extends/* #__PURE__ -- @preserve */
25
- _0x6e79d9(){['id'];['author'];['type'];['data'];['rootName'];constructor(_0x15ca99){super(),this['id']=_0x15ca99['id']||_0x43c208(),this['author']=_0x15ca99['author'],this['type']=_0x15ca99['type'],this['data']=_0x15ca99['data']||{},this['rootName']=_0x15ca99['rootName'],this['set']('createdAt',_0x15ca99['createdAt']);}['toJSON'](){return{'id':this['id'],'authorId':this['author']['id'],'type':this['type'],'data':this['data'],'createdAt':this['createdAt']};}}class c{['newRevisionId'];['oldRevisionId'];['changes'];constructor(_0x27f0de,_0x3609d6){this['newRevisionId']=_0x27f0de,this['oldRevisionId']=_0x3609d6,this['changes']=new _0x4e7c66();}['_setChanges'](_0x1e5abe){for(const _0x507334 of _0x1e5abe)this['changes']['add'](_0x507334);}}class m extends _0x311e14{['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[_0x58de4b,_0x32455f,I,V];}constructor(_0x4a4846){super(_0x4a4846),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',(_0x25aedb,_0x567e3a,_0x297bb4)=>{this['activeChange']=null,this['activeView']=null,this['editor']['editing']['view']['change'](_0xa77dcf=>{for(const _0x208ae4 of this['editor']['editing']['view']['document']['roots'])_0x297bb4?_0xa77dcf['removeClass']('ck-editor__editable__overlay',_0x208ae4):_0xa77dcf['addClass']('ck-editor__editable__overlay',_0x208ae4);});}),this['bind']('isNavigationMode')['to'](this,'activeChange',_0x17cd24=>null!==_0x17cd24),this['bind']('currentChangeNumber')['to'](this,'isReady',this,'diff',this,'activeChange',(_0x1959d2,_0xa83545,_0x3d4cf7)=>_0x1959d2&&_0x3d4cf7?_0xa83545['changes']['getIndex'](_0x3d4cf7):0x0),this['bind']('numberOfChanges')['to'](this,'isReady',this,'diff',(_0x5c1675,_0x1de0bc)=>_0x5c1675?_0x1de0bc['changes']['length']:0x0),this['_changeView']=null,this['_changeIdToChange']=new Map(),this['_balloon']=this['editor']['plugins']['get'](_0x32455f);}['init'](){const _0x928f0=this['editor'],_0x356fbe=new wt(_0x928f0,{'direction':'backward'}),_0x5ca866=new wt(_0x928f0,{'direction':'forward'});(_0x928f0['commands']['add']('showPreviousChange',_0x356fbe),_0x928f0['commands']['add']('showNextChange',_0x5ca866),_0x928f0['commands']['add']('restoreRevision',new mt(_0x928f0)),this['on']('change:numberOfChanges',()=>{_0x356fbe['refresh'](),_0x5ca866['refresh']();}),this['_setConversion'](),this['_initInteractions'](),_0x928f0['enableReadOnlyMode']('revision-viewer'),_0x928f0['plugins']['has']('WidgetToolbarRepository'))&&_0x928f0['plugins']['get']('WidgetToolbarRepository')['forceDisabled']('revision-viewer');}async['getRevisionDocumentData'](_0x2596ad){return await this['_utils']['loadRevisionData'](_0x2596ad,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x2596ad);}async['getRevisionRootsAttributes'](_0x3bd2aa){return await this['_utils']['loadRevisionData'](_0x3bd2aa,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x3bd2aa);}async['compare'](_0x51a8af,_0x4ad8a3,_0x335431=!0x1){if(!this['isEnabled'])return;const _0x27f9be=this['diff'],_0x5dd14d=this['repository'],_0x9e44a1='string'==typeof _0x51a8af?_0x5dd14d['getRevision'](_0x51a8af):_0x51a8af,_0x277e69='string'==typeof _0x4ad8a3?_0x5dd14d['getRevision'](_0x4ad8a3):_0x4ad8a3,_0x27c29e=_0x9e44a1['id'],_0x35109d=_0x277e69?_0x277e69['id']:null;if(!_0x335431&&this['diff']&&this['diff']['newRevisionId']===_0x27c29e&&this['diff']['oldRevisionId']===_0x35109d)return Promise['resolve']();this['isReady']=!0x1,this['activeView']=null,this['activeChange']=null,this['diff']=new c(_0x27c29e,_0x35109d);const _0x29ec46=this['_getRevisionsRange'](_0x9e44a1,_0x277e69,!0x0)['map'](_0xc255cf=>this['_utils']['loadRevisionData'](_0xc255cf,this['adapter']));return _0x29ec46['push'](new Promise(_0x174052=>{setTimeout(_0x174052,0x14);})),Promise['all'](_0x29ec46)['then'](()=>{if(!this['isEnabled'])return;this['_cleanUp']();const _0x29f751=this['_getDiff'](_0x27c29e,_0x35109d);for(const _0x52ba2f of _0x29f751['changes'])this['_changeIdToChange']['set'](_0x52ba2f['id'],_0x52ba2f);this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x1af518=>{for(const _0x9bac97 of this['editor']['model']['document']['getRootNames']())_0x1af518['detachRoot'](_0x9bac97);for(const _0x3e7302 of Object['keys'](_0x29f751['model'])){const _0x2c7ec1=_0x1af518['addRoot'](_0x3e7302);for(const _0x50d73e of Object['keys'](_0x29f751['attributes'][_0x3e7302]))_0x1af518['setAttribute'](_0x50d73e,_0x29f751['attributes'][_0x3e7302][_0x50d73e],_0x2c7ec1);_0x1af518['insert'](_0x29f751['model'][_0x3e7302],_0x2c7ec1,0x0);}}),this['diff']['_setChanges'](this['_sortAndFilterDiffChanges'](_0x29f751['changes'])),this['isReady']=!0x0;})['catch'](_0x308d58=>{console['error'](_0x308d58),this['_cleanUp'](),_0x27f9be&&(this['diff']=_0x27f9be),this['isReady']=!0x0;});}['addRevisionData'](_0x5e0935,_0x2d0843){const _0x1c827d=this['repository']['createRevision'](_0x5e0935);return _0x1c827d['on']('_update',(_0x4047f0,_0xab2206,_0x399934)=>_0x2d0843(_0xab2206,_0x399934,_0x1c827d)),this['repository']['addRevision'](_0x1c827d),_0x1c827d;}['_cleanUp'](){this['activeChange']=null,this['_cleanMarkers'](),this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=null,this['_changeIdToChange']['clear'](),this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x4a3dd2=>{for(const _0x21e0c6 of this['editor']['model']['document']['getRootNames']())_0x4a3dd2['detachRoot'](_0x21e0c6);});}['_sortAndFilterDiffChanges'](_0x3cecb8){const _0x2b6b52=[],_0x54af08=new Map();for(const _0x1446bf of this['editor']['model']['document']['getRootNames']()){const _0x2dfc75=this['editor']['editing']['view']['getDomRoot'](_0x1446bf);if(!_0x2dfc75)continue;const _0x5ed7a8=_0x2dfc75['getClientRects']()['item'](0x0);_0x5ed7a8&&(_0x2b6b52['push'](_0x1446bf),_0x54af08['set'](_0x1446bf,_0x5ed7a8));}return _0x2b6b52['sort']((_0x4ef88e,_0xfb227)=>{const _0x1e82eb=_0x54af08['get'](_0x4ef88e),_0x4bcfc0=_0x54af08['get'](_0xfb227);return _0x1e82eb['y']-_0x4bcfc0['y']||_0x1e82eb['x']-_0x4bcfc0['x'];}),(_0x3cecb8=_0x3cecb8['filter'](_0x508d1=>_0x2b6b52['includes'](_0x508d1['rootName'])))['sort']((_0x12d813,_0x2e855e)=>_0x2b6b52['indexOf'](_0x12d813['rootName'])-_0x2b6b52['indexOf'](_0x2e855e['rootName'])),_0x3cecb8;}['_makeTape'](_0x4c42be){const _0x147be1=Array['from'](_0x4c42be['markers'])['filter'](([_0x77eb8b,_0x3a1897])=>_0x77eb8b['startsWith']('revision:')&&!_0x3a1897['isCollapsed']),_0x255d94=Array['from'](this['editor']['model']['createRangeIn'](_0x4c42be)['getWalker']({'singleCharacters':!0x0}));if(0x0!=_0x147be1['length'])for(const _0x24827e of _0x255d94){const [_0x256ef7,_0x2ec98c]=_0x147be1[0x0],[,_0x16d546,_0x41eaf]=_0x256ef7['split'](':');if(_0x2ec98c['end']['isEqual'](_0x24827e['nextPosition'])&&_0x147be1['shift'](),(_0x24827e['previousPosition']['isEqual'](_0x2ec98c['start'])||_0x24827e['previousPosition']['isAfter'](_0x2ec98c['start']))&&('insertion'==_0x16d546?_0x24827e['isAdded']={'userId':_0x41eaf}:'deletion'==_0x16d546&&(_0x24827e['isRemoved']={'userId':_0x41eaf})),0x0==_0x147be1['length'])break;}return _0x255d94;}['_refreshStartEndIndex'](_0x4f7337){const _0x271152=new Map();for(let _0x16d7fd=0x0;_0x16d7fd<_0x4f7337['length'];_0x16d7fd++)'text'===_0x4f7337[_0x16d7fd]['type']?(_0x4f7337[_0x16d7fd]['item']['startIndex']=_0x16d7fd,_0x4f7337[_0x16d7fd]['item']['endIndex']=_0x16d7fd):('elementStart'===_0x4f7337[_0x16d7fd]['type']?_0x4f7337[_0x16d7fd]['item']['startIndex']=_0x16d7fd:'elementEnd'===_0x4f7337[_0x16d7fd]['type']&&(_0x4f7337[_0x16d7fd]['item']['endIndex']=_0x16d7fd),_0x271152['set'](_0x4f7337[_0x16d7fd]['id'],_0x16d7fd));for(const _0xaa7ca1 of _0x271152['values']())'elementStart'===_0x4f7337[_0xaa7ca1]['type']?_0x4f7337[_0xaa7ca1]['item']['endIndex']=_0x271152['get'](_0x4f7337[_0xaa7ca1]['pairId']):'elementEnd'===_0x4f7337[_0xaa7ca1]['type']&&(_0x4f7337[_0xaa7ca1]['item']['startIndex']=_0x271152['get'](_0x4f7337[_0xaa7ca1]['pairId']));}['_processTape'](_0x30bc56){for(let _0x4e9c23=0x0;_0x4e9c23<_0x30bc56['length'];_0x4e9c23++){if('elementStart'===_0x30bc56[_0x4e9c23]['type'])_0x30bc56[_0x4e9c23]['item']['startIndex']=_0x4e9c23;else{if('elementEnd'===_0x30bc56[_0x4e9c23]['type']){_0x30bc56[_0x4e9c23]['item']['endIndex']=_0x4e9c23;const _0x3e161f=_0x30bc56[_0x4e9c23]['item']['startIndex'];_0x30bc56[_0x3e161f]['pairId']=_0x30bc56[_0x4e9c23]['id'],_0x30bc56[_0x4e9c23]['pairId']=_0x30bc56[_0x3e161f]['id'];}else _0x30bc56[_0x4e9c23]['item']['startIndex']=_0x4e9c23,_0x30bc56[_0x4e9c23]['item']['endIndex']=_0x4e9c23,_0x30bc56[_0x4e9c23]['pairId']=null;}_0x30bc56[_0x4e9c23]['markersStart']||(_0x30bc56[_0x4e9c23]['markersStart']=[],_0x30bc56[_0x4e9c23]['markersEnd']=[]);}}['_markInsertions'](_0x43d4cf,_0x3f85e4){const _0xad9217=_0x43d4cf['filter'](_0x4f057b=>!_0x4f057b['isAdded']);for(let _0x4305aa=0x0;_0x4305aa<_0x3f85e4['length'];_0x4305aa++)_0x3f85e4[_0x4305aa]['isAdded']&&(_0xad9217[_0x4305aa]['isAdded']=_0x3f85e4[_0x4305aa]['isAdded']);}['_getDiff'](_0x1e7e04,_0x1a9934=null){const _0x37a0ba=this['repository']['getRevision'](_0x1e7e04),_0x8a94e2=_0x1a9934?this['repository']['getRevision'](_0x1a9934):null,_0x599773=this['_getRevisionsRange'](_0x37a0ba,_0x8a94e2),_0x7ba17d=_0x599773[_0x599773['length']-0x1],_0x188878=new Map(),_0x22d4ef={'model':{},'attributes':{},'changes':[]},_0x57df3a=new Set(),_0x11110a=new Map();for(let _0x4fd3b2=_0x599773['length']-0x1;_0x4fd3b2>=0x0;_0x4fd3b2--){const _0x33f5a9=_0x599773[_0x4fd3b2];for(const _0x3fdf3e of Object['keys'](_0x33f5a9['diffData']))if(_0x33f5a9['diffData'][_0x3fdf3e]['attachChange']){const _0x48b2a5=_0x33f5a9['diffData'][_0x3fdf3e]['attachChange'];_0x48b2a5['isAttached']?(_0x57df3a['add'](_0x3fdf3e),_0x11110a['has'](_0x3fdf3e)&&_0x11110a['get'](_0x3fdf3e)['userId']==_0x48b2a5['userId']?_0x11110a['delete'](_0x3fdf3e):_0x11110a['set'](_0x3fdf3e,_0x48b2a5)):_0x11110a['has'](_0x3fdf3e)?(_0x57df3a['delete'](_0x3fdf3e),_0x11110a['delete'](_0x3fdf3e)):(_0x57df3a['add'](_0x3fdf3e),_0x11110a['set'](_0x3fdf3e,_0x48b2a5));}else _0x57df3a['add'](_0x3fdf3e);}for(const _0x5adcfe of _0x57df3a){const _0x2a038d=_0x11110a['has'](_0x5adcfe)&&!_0x11110a['get'](_0x5adcfe)['isAttached'];let _0x2aca10=_0x2a038d?_0x599773['length']-0x1:0x0;const _0x24aedd=_0x2a038d?-0x1:0x1;for(;_0x599773[_0x2aca10];){const _0x3fc607=_0x599773[_0x2aca10];if(_0x3fc607['diffData'][_0x5adcfe]){const _0x1ef259=_0x2a038d?_0x3fc607['diffData'][_0x5adcfe]['attributesBefore']:_0x3fc607['diffData'][_0x5adcfe]['attributesAfter'];_0x22d4ef['attributes'][_0x5adcfe]=_0x1ef259?_0x1aa9b4(_0x1ef259):{};break;}_0x2aca10+=_0x24aedd;}}for(const _0x28e2b2 of _0x599773){_0x28e2b2['model']={};for(const _0x5b7393 of _0x28e2b2['authors'])_0x188878['set'](_0x5b7393['id'],_0x5b7393);for(const _0x441d43 of _0x57df3a){const _0x425ee9=_0x28e2b2['diffData'][_0x441d43]?_0x28e2b2['diffData'][_0x441d43]['insertions']:'[]',_0x34fbd2=_0x28e2b2['diffData'][_0x441d43]?_0x28e2b2['diffData'][_0x441d43]['deletions']:'[]';_0x28e2b2['model'][_0x441d43]={'insertions':this['_utils']['_makeModelFromViewString'](_0x425ee9),'deletions':this['_utils']['_makeModelFromViewString'](_0x34fbd2)};}}for(const _0x264693 of _0x57df3a){let _0x252fdd=null,_0x3c1ddc=0x0;const _0x57a906=new Map(Array['from'](_0x37a0ba['model'][_0x264693]['insertions']['markers'])['filter'](([_0x15f347])=>!_0x15f347['startsWith']('revision:')));let _0x30e9a6=0x0;for(const _0x32c911 of _0x599773){const _0x4d5831=this['_makeTape'](_0x32c911['model'][_0x264693]['insertions']);_0x32c911==_0x37a0ba?(_0x252fdd=_0x4d5831,_0x3c1ddc=_0x252fdd['length'],_0x252fdd['forEach'](_0x52164e=>{_0x52164e['id']=_0x30e9a6++;}),this['_processTape'](_0x252fdd)):this['_markInsertions'](_0x252fdd,_0x4d5831);const _0x290a5e=_0x252fdd['filter'](_0x3a3001=>!_0x3a3001['isAdded'])['map'](_0x1efa61=>_0x1efa61['id']);let _0x293b75=0x0;const _0x56efc7=this['_makeTape'](_0x32c911['model'][_0x264693]['deletions']);_0x56efc7['forEach'](_0x37b8f8=>{_0x37b8f8['isRemoved']?_0x37b8f8['id']=_0x3c1ddc++:_0x37b8f8['id']=_0x290a5e[_0x293b75++];}),this['_processTape'](_0x56efc7),this['_setDistance'](_0x252fdd,'isAdded'),this['_setDistance'](_0x56efc7,'isRemoved'),_0x32c911==_0x37a0ba&&this['_markMarkers'](_0x252fdd,_0x57a906),_0x252fdd=this['_joinTapes'](_0x252fdd,_0x56efc7),this['_refreshStartEndIndex'](_0x252fdd),this['_setDistance'](_0x252fdd,'isRemoved');}_0x252fdd=_0x252fdd['filter'](_0x1bd55e=>!(_0x1bd55e['isAdded']&&_0x1bd55e['isRemoved']));const _0x5a3b8b=new Map(_0x7ba17d['model'][_0x264693]['deletions']['markers']),_0x4cdc50=new Set(_0x57a906['keys']());for(const _0x513807 of _0x5a3b8b['keys']())_0x4cdc50['delete'](_0x513807);this['_markSuggestions'](_0x252fdd,_0x4cdc50),this['_fixObsoleteTags'](_0x252fdd),_0x252fdd=this['_removeMissingPairs'](_0x252fdd),_0x252fdd=this['_markMismatchedRemovedTags'](_0x252fdd),_0x252fdd=this['_removeUnsupportedChanges'](_0x252fdd);const {root:_0x12455a,changes:_0x1faa9f}=this['_makeModelFromTape'](_0x252fdd,_0x188878,_0x264693);_0x22d4ef['model'][_0x264693]=_0x12455a;const _0x39c581=_0x11110a['get'](_0x264693);if(_0x39c581){const _0x42e6f4=_0x188878['get'](_0x39c581['userId']),_0x351807=new r({'author':_0x42e6f4,'type':_0x39c581['isAttached']?'add':'remove','data':{'isOnRoot':!0x0},'createdAt':new Date(),'rootName':_0x264693});_0x1faa9f['unshift'](_0x351807),_0x22d4ef['attributes'][_0x264693]['revisionHistoryAttachChange']=_0x351807['id'];}_0x22d4ef['changes']=_0x22d4ef['changes']['concat'](_0x1faa9f);}return _0x22d4ef;}['_markMarkers'](_0x529553,_0x570b52){for(let _0x55f8bf=0x0;_0x55f8bf<_0x529553['length'];_0x55f8bf++)for(const [_0x3f29ba,_0x11a00c]of _0x570b52)!_0x11a00c['isCollapsed']&&_0x11a00c['start']['isEqual'](_0x529553[_0x55f8bf]['previousPosition'])&&_0x529553[_0x55f8bf]['markersStart']['push'](_0x3f29ba),_0x11a00c['end']['isEqual'](_0x529553[_0x55f8bf]['nextPosition'])&&_0x529553[_0x55f8bf]['markersEnd']['push'](_0x3f29ba);}['_joinTapes'](_0x48a8c1,_0x2bba2f){let _0x157fa8=[],_0x314d36=0x0,_0x169941=0x0;for(;_0x314d36<_0x48a8c1['length']||_0x169941<_0x2bba2f['length'];){const _0x51dd80=_0x48a8c1[_0x314d36]||{},_0x2887ea=_0x2bba2f[_0x169941]||{};if(_0x51dd80['id']==_0x2887ea['id'])_0x314d36++,_0x169941++,_0x157fa8['push'](_0x51dd80);else{if(_0x2887ea['isRemoved']&&_0x51dd80['isAdded']){const {commonTape:_0x842f10,iEnd:_0x13b188,jEnd:_0x572065}=this['_threeWayMerge'](_0x48a8c1,_0x314d36,_0x2bba2f,_0x169941);_0x157fa8=_0x157fa8['concat'](_0x842f10),_0x314d36=_0x13b188,_0x169941=_0x572065;}else _0x2887ea['isRemoved']?(_0x169941++,_0x157fa8['push'](_0x2887ea)):(_0x314d36++,_0x157fa8['push'](_0x51dd80));}}return _0x157fa8;}['_markSuggestions'](_0x543a17,_0x57cce7){const _0x50ec33=[];for(let _0x59d046=0x0;_0x59d046<_0x543a17['length'];_0x59d046++){for(let _0x5c04a3=0x0;_0x5c04a3<_0x543a17[_0x59d046]['markersStart']['length'];_0x5c04a3++){const _0x5ee23d=_0x543a17[_0x59d046]['markersStart'][_0x5c04a3];if(!_0x57cce7['has'](_0x5ee23d))continue;const {group:_0x1e72b8,type:_0x333917,authorId:_0x4a32f7}=_0x37e8a4(_0x5ee23d);'revision-suggestion'!=_0x1e72b8||'insertion'!=_0x333917&&'deletion'!=_0x333917||(_0x50ec33['unshift']({'type':_0x333917,'name':_0x5ee23d,'userId':_0x4a32f7}),_0x543a17[_0x59d046]['markersStart']['splice'](_0x5c04a3,0x1),_0x5c04a3--);}_0x5e387b(_0x543a17[_0x59d046]);for(let _0x44fd76=0x0;_0x44fd76<_0x543a17[_0x59d046]['markersEnd']['length'];_0x44fd76++){const _0x4f91af=_0x543a17[_0x59d046]['markersEnd'][_0x44fd76];if(!_0x57cce7['has'](_0x4f91af))continue;const {group:_0x53ab4a,type:_0x52d661}=_0x37e8a4(_0x4f91af);if('revision-suggestion'!=_0x53ab4a||'insertion'!=_0x52d661&&'deletion'!=_0x52d661)continue;_0x543a17[_0x59d046]['markersEnd']['splice'](_0x44fd76,0x1),_0x44fd76--;const _0x573caf=_0x50ec33['findIndex'](_0x585c0d=>_0x585c0d['name']==_0x4f91af);_0x573caf>-0x1&&_0x50ec33['splice'](_0x573caf,0x1);}}function _0x37e8a4(_0x2613cb){const _0x1ab5df=_0x2613cb['split'](':');return{'group':_0x1ab5df[0x0],'type':_0x1ab5df[0x1],'subType':_0x1ab5df['length']>=0x5?_0x1ab5df[0x2]:null,'id':_0x1ab5df['length']<0x5?_0x1ab5df[0x2]:_0x1ab5df[0x3],'authorId':_0x1ab5df['length']<0x5?_0x1ab5df[0x3]:_0x1ab5df[0x4],'markerCount':0x6==_0x1ab5df['length']?_0x1ab5df[0x5]:null};}function _0x5e387b(_0x50b205){for(let _0x5e484b=0x0;_0x5e484b<_0x50ec33['length'];_0x5e484b++){if(_0x50b205['isAdded']&&'insertion'==_0x50ec33[_0x5e484b]['type']&&_0x50b205['isAdded']['userId']==_0x50ec33[_0x5e484b]['userId'])return _0x50b205['isAddSuggestion']=_0x50ec33[_0x5e484b],void delete _0x50b205['isAdded'];if(!_0x50b205['isAdded']&&!_0x50b205['isRemoved']&&'deletion'==_0x50ec33[_0x5e484b]['type'])return void(_0x50b205['isRemoveSuggestion']=_0x50ec33[_0x5e484b]);}}}['_setDistance'](_0xac8d89,_0x23efc2){let _0xf37048=0x0,_0x5f28be=!0x1;const _0x397756=new Map();for(const _0x12f4b6 of _0xac8d89)_0x12f4b6[_0x23efc2]?_0x5f28be&&(_0xf37048++,_0x5f28be=!0x1):(_0xf37048++,_0x5f28be=!0x0),_0x397756['set'](_0x12f4b6['id'],_0xf37048);for(let _0xbd2275=0x0;_0xbd2275<_0xac8d89['length'];_0xbd2275++){if('isRemoved'==_0x23efc2&&_0xac8d89[_0xbd2275]['isAdded']||'isAdded'==_0x23efc2&&_0xac8d89[_0xbd2275]['isRemoved'])continue;if('text'==_0xac8d89[_0xbd2275]['type']){_0xac8d89[_0xbd2275]['distance']=0x0;continue;}const _0x1c72c1=_0x397756['get'](_0xac8d89[_0xbd2275]['pairId']),_0x4e5aba=_0x397756['get'](_0xac8d89[_0xbd2275]['id']);_0xac8d89[_0xbd2275]['distance']=_0x1c72c1-_0x4e5aba;}}['_getRevisionsRange'](_0x2bda86,_0x23b0e2,_0x3f4f36=!0x1){const _0x543296=[];let _0x1e50d5=this['repository']['getIndex'](_0x2bda86),_0x50f2aa=this['repository']['getIndex'](_0x23b0e2);for(-0x1==_0x50f2aa&&(_0x50f2aa=this['repository']['_revisions']['length'],_0x3f4f36=!0x1);_0x1e50d5<_0x50f2aa;)_0x543296['push'](this['repository']['getRevision'](_0x1e50d5)),_0x1e50d5++;return _0x3f4f36&&_0x543296['push'](this['repository']['getRevision'](_0x1e50d5)),_0x543296;}['_threeWayMerge'](_0x47be88,_0x23a270,_0x2d3517,_0x475f94){const _0x19646e=this['editor']['model']['schema'];let _0x4e545b=_0x23a270;for(;_0x47be88[_0x4e545b]&&_0x47be88[_0x4e545b]['isAdded'];)_0x4e545b++;let _0x5901a7=_0x475f94;for(;_0x2d3517[_0x5901a7]&&_0x2d3517[_0x5901a7]['isRemoved'];)_0x5901a7++;_0x3782fd(_0x47be88,_0x23a270,_0x4e545b),_0x3782fd(_0x2d3517,_0x475f94,_0x5901a7);const _0x5d34a3=_0x2d3517['slice'](_0x475f94,_0x5901a7)['concat'](_0x47be88['slice'](_0x23a270,_0x4e545b));return _0x5d34a3['sort']((_0x2924b5,_0x1731f1)=>_0x2924b5['side']!=_0x1731f1['side']?_0x2924b5['side']-_0x1731f1['side']:_0x2924b5['level']!=_0x1731f1['level']?_0x2924b5['level']-_0x1731f1['level']:_0x2924b5['distance']!=_0x1731f1['distance']?_0x1731f1['distance']-_0x2924b5['distance']:!!_0x2924b5['isAdded']!=!!_0x1731f1['isAdded']?-0x1==_0x2924b5['side']||0x0==_0x2924b5['side']?_0x2924b5['isAdded']?-0x1:0x1:_0x2924b5['isAdded']?0x1:-0x1:_0x2924b5['index']-_0x1731f1['index']),{'commonTape':_0x5d34a3,'iEnd':_0x4e545b,'jEnd':_0x5901a7};function _0x3782fd(_0x31eb3d,_0x4d93d3,_0x3fc4b0){let _0x5cc78f=-0x1,_0x5f2f8e=Number['POSITIVE_INFINITY'],_0x4c6675=!0x0;for(let _0x6f3fd1=_0x4d93d3;_0x6f3fd1<_0x3fc4b0;_0x6f3fd1++)if(_0x19646e['isInline'](_0x31eb3d[_0x6f3fd1]['item'])||(_0x4c6675=!0x1),_0x31eb3d[_0x6f3fd1]['item']['startIndex']<_0x4d93d3&&(_0x5cc78f=_0x6f3fd1),_0x31eb3d[_0x6f3fd1]['item']['endIndex']>=_0x3fc4b0){_0x5f2f8e=_0x6f3fd1;break;}_0x4c6675&&(_0x5cc78f=_0x3fc4b0-0x1);for(let _0x3e4beb=_0x4d93d3;_0x3e4beb<_0x3fc4b0;_0x3e4beb++)_0x31eb3d[_0x3e4beb]['side']=_0x3e4beb<=_0x5cc78f?-0x1:_0x3e4beb<_0x5f2f8e?0x0:0x1,_0x31eb3d[_0x3e4beb]['index']=_0x3e4beb;let _0x5c5fa3=0x0;for(let _0x2ae069=_0x4d93d3;_0x2ae069<=_0x5cc78f;_0x2ae069++)0x0==_0x31eb3d[_0x2ae069]['distance']?_0x31eb3d[_0x2ae069]['level']=_0x5c5fa3:(_0x5c5fa3++,_0x31eb3d[_0x2ae069]['level']=_0x5c5fa3,_0x5c5fa3++);for(let _0x1efe9c=_0x4d93d3;_0x1efe9c<_0x3fc4b0;_0x1efe9c++)0x0==_0x31eb3d[_0x1efe9c]['side']&&(_0x31eb3d[_0x1efe9c]['level']=_0x5c5fa3);_0x5c5fa3=0x0;for(let _0x16292f=_0x3fc4b0-0x1;_0x16292f>=_0x5f2f8e;_0x16292f--)0x0==_0x31eb3d[_0x16292f]['distance']?_0x31eb3d[_0x16292f]['level']=_0x5c5fa3:(_0x5c5fa3--,_0x31eb3d[_0x16292f]['level']=_0x5c5fa3,_0x5c5fa3--);}}['_fixObsoleteTags'](_0x56e80f){const _0x6e317b=new Map(),_0x3002cc=this['editor']['model']['schema'];for(let _0x185c0b=0x1;_0x185c0b<_0x56e80f['length'];_0x185c0b++){let _0x522a95,_0x26b37a,_0x560e02;const _0x3aab51=_0x56e80f[_0x185c0b],_0x20f51e=_0x56e80f[_0x185c0b-0x1];if('text'==_0x3aab51['type'])continue;if(_0x3aab51['type']!=_0x20f51e['type'])continue;if(!_0x3002cc['isBlock'](_0x20f51e['item'])||_0x3002cc['isLimit'](_0x20f51e['item']))continue;if(!_0x3002cc['isBlock'](_0x3aab51['item'])||_0x3002cc['isLimit'](_0x3aab51['item']))continue;if((_0x56e80f[_0x185c0b]['isAdded']||_0x56e80f[_0x185c0b]['isAddSuggestion'])&&_0x56e80f[_0x185c0b-0x1]['isRemoved'])_0x522a95=_0x56e80f[_0x185c0b],_0x26b37a=_0x56e80f[_0x185c0b-0x1],_0x560e02=_0x185c0b-0x1;else{if(!_0x56e80f[_0x185c0b]['isRemoved']||!_0x56e80f[_0x185c0b-0x1]['isAdded']&&!_0x56e80f[_0x185c0b-0x1]['isAddSuggestion'])continue;_0x522a95=_0x56e80f[_0x185c0b-0x1],_0x26b37a=_0x56e80f[_0x185c0b],_0x560e02=_0x185c0b;}const _0x5e30a6=_0x522a95['level']==_0x26b37a['level'],_0x408fa0=Math['abs'](_0x522a95['level'])<Math['abs'](_0x26b37a['level'])&&0x0==_0x26b37a['distance'];(_0x5e30a6||_0x408fa0)&&(_0x6e317b['set'](_0x26b37a['id'],_0x522a95['id']),_0x56e80f['splice'](_0x560e02,0x1),_0x185c0b--,_0x522a95['isAdded']=!0x1);}for(let _0x3cf465=0x0;_0x3cf465<_0x56e80f['length'];_0x3cf465++)_0x6e317b['has'](_0x56e80f[_0x3cf465]['pairId'])&&(_0x56e80f[_0x3cf465]['pairId']=_0x6e317b['get'](_0x56e80f[_0x3cf465]['pairId']));}['_removeMissingPairs'](_0x12b05a){const _0x2c7624=new Set(_0x12b05a['map'](_0x40957c=>_0x40957c['id']));for(let _0x1ecee2=0x0;_0x1ecee2<_0x12b05a['length'];_0x1ecee2++)_0x2c7624['has'](_0x12b05a[_0x1ecee2]['pairId'])||0x0==_0x12b05a[_0x1ecee2]['distance']||(_0x12b05a[_0x1ecee2]['isIncorrect']=!0x0);return _0x12b05a['filter'](_0x45d663=>!_0x45d663['isIncorrect']);}['_markMismatchedRemovedTags'](_0x220111){const _0x1e16d8=new Set();for(let _0x303bbf=0x0;_0x303bbf<_0x220111['length'];_0x303bbf++){if(_0x1e16d8['has'](_0x220111[_0x303bbf]['id'])&&_0x220111[_0x303bbf]['isRemoved']&&(_0x220111[_0x303bbf]['isIncorrect']=!0x0),_0x220111[_0x303bbf]['isIncorrect'])continue;if(0x0==_0x220111[_0x303bbf]['distance'])continue;if('elementStart'!=_0x220111[_0x303bbf]['type'])continue;if(null==_0x220111[_0x303bbf]['pairId'])continue;let _0x3bc1c1=_0x303bbf+0x1,_0x20a7a5=0x0;for(;_0x220111[_0x3bc1c1]['id']!=_0x220111[_0x303bbf]['pairId'];)'elementStart'==_0x220111[_0x3bc1c1]['type']?_0x20a7a5++:'elementEnd'==_0x220111[_0x3bc1c1]['type']&&_0x20a7a5--,_0x3bc1c1++;if(0x0!=_0x20a7a5){if(_0x220111[_0x303bbf]['isRemoved'])_0x220111[_0x303bbf]['isIncorrect']=!0x0;else{for(;_0x3bc1c1!=_0x303bbf;)_0x220111[_0x3bc1c1]['isRemoved']&&0x0!=_0x220111[_0x3bc1c1]['distance']&&(_0x220111[_0x3bc1c1]['isIncorrect']=!0x0,_0x1e16d8['add'](_0x220111[_0x3bc1c1]['pairId'])),_0x3bc1c1--;}}}return _0x220111['filter'](_0x192258=>!_0x192258['isIncorrect']);}['_removeUnsupportedChanges'](_0x406bfe){const _0x4d5f52=this['editor']['model']['schema'];for(let _0x393906=0x0;_0x393906<_0x406bfe['length'];_0x393906++){if(!(_0x406bfe[_0x393906]['isAdded']||_0x406bfe[_0x393906]['isAddSuggestion']||_0x406bfe[_0x393906]['isRemoved']||_0x406bfe[_0x393906]['isRemoveSuggestion']))continue;if(0x0==_0x406bfe[_0x393906]['distance'])continue;const _0x50f857=_0x406bfe[_0x393906]['item'];_0x4d5f52['isBlock'](_0x50f857)||_0x4d5f52['isLimit'](_0x50f857)||(_0x406bfe[_0x393906]['isAdded']&&delete _0x406bfe[_0x393906]['isAdded'],_0x406bfe[_0x393906]['isAddSuggestion']&&delete _0x406bfe[_0x393906]['isAddSuggestion'],_0x406bfe[_0x393906]['isRemoveSuggestion']&&delete _0x406bfe[_0x393906]['isRemoveSuggestion'],_0x406bfe[_0x393906]['isRemoved']&&(_0x406bfe[_0x393906]['isIncorrect']=!0x0));}return _0x406bfe['filter'](_0x16cadc=>!_0x16cadc['isIncorrect']);}['_makeModelFromTape'](_0x45c4fb,_0x3c50dc,_0x290a5c){const _0x138a70=new vt(),_0x21c2a6=[],_0x2daa4a=new Map(),_0x1ac215=this['editor']['model'],_0x113cbe=_0x1ac215['schema'],_0x4f9a2c=[_0x138a70],_0xee3dc6={},_0x4f172e={'isAdded':[],'isRemoved':[],'isAddSuggestion':[],'isRemoveSuggestion':[]};let _0x33086b=null;const _0x353f68=[0x0];for(let _0x343615=0x0;_0x343615<_0x45c4fb['length'];_0x343615++)if('elementStart'===_0x45c4fb[_0x343615]['type']){_0x45c4fb[_0x343615]['previousPosition']=_0x1ac215['createPositionFromPath'](_0x138a70,_0x353f68);const _0x5aa8b4=new ut(_0x45c4fb[_0x343615]['item']['name'],_0x45c4fb[_0x343615]['item']['getAttributes']());_0x4f9a2c[0x0]['_appendChild'](_0x5aa8b4),_0x353f68['push'](0x0),_0x4f9a2c['unshift'](_0x5aa8b4),_0x45c4fb[_0x343615]['nextPosition']=_0x1ac215['createPositionFromPath'](_0x138a70,_0x353f68);}else'elementEnd'===_0x45c4fb[_0x343615]['type']?(_0x4f9a2c['shift'](),_0x45c4fb[_0x343615]['previousPosition']=_0x1ac215['createPositionFromPath'](_0x138a70,_0x353f68),_0x353f68['pop'](),_0x353f68[_0x353f68['length']-0x1]++,_0x45c4fb[_0x343615]['nextPosition']=_0x1ac215['createPositionFromPath'](_0x138a70,_0x353f68)):(_0x45c4fb[_0x343615]['previousPosition']=_0x1ac215['createPositionFromPath'](_0x138a70,_0x353f68),_0x33086b?_0x33086b['_data']+=_0x45c4fb[_0x343615]['item']['data']:_0x33086b=new gt(_0x45c4fb[_0x343615]['item']['data'],_0x45c4fb[_0x343615]['item']['getAttributes']()),_0x45c4fb[_0x343615+0x1]&&'text'===_0x45c4fb[_0x343615+0x1]['type']&&_0x14b82a(_0x33086b,_0x45c4fb[_0x343615+0x1]['item'])||(_0x4f9a2c[0x0]['_appendChild'](_0x33086b),_0x33086b=null),_0x353f68[_0x353f68['length']-0x1]+=_0x45c4fb[_0x343615]['item']['offsetSize'],_0x45c4fb[_0x343615]['nextPosition']=_0x1ac215['createPositionFromPath'](_0x138a70,_0x353f68));for(let _0xb4605f=0x0;_0xb4605f<_0x45c4fb['length'];_0xb4605f++){const _0x283315=_0x45c4fb[_0xb4605f]['previousPosition'],_0x2d9143=_0x45c4fb[_0xb4605f]['nextPosition'];for(const _0x4fa844 of _0x45c4fb[_0xb4605f]['markersStart'])_0x2daa4a['set'](_0x4fa844,{'start':_0x283315,'end':null});_0x1cdd01('isRemoveSuggestion',_0xb4605f,_0x283315,_0x2d9143),_0x1cdd01('isAddSuggestion',_0xb4605f,_0x283315,_0x2d9143),_0x1cdd01('isRemoved',_0xb4605f,_0x283315,_0x2d9143),_0x1cdd01('isAdded',_0xb4605f,_0x283315,_0x2d9143);for(const _0x1b3461 of _0x45c4fb[_0xb4605f]['markersEnd']){const _0x484de6=_0x2daa4a['get'](_0x1b3461);_0x484de6?_0x484de6['end']=_0x2d9143:_0x2daa4a['set'](_0x1b3461,{'start':_0x2d9143,'end':_0x2d9143});}}for(const [_0x49474c,_0x102eea]of _0x2daa4a){const _0x590833=this['editor']['model']['createRange'](_0x102eea['start'],_0x102eea['end']);_0x138a70['markers']['set'](_0x49474c,_0x590833);}return _0x21c2a6['sort']((_0x341501,_0x1f7f2f)=>{const _0x423d77=_0x138a70['markers']['get']('revision:'+_0x341501['id']),_0x4691db=_0x138a70['markers']['get']('revision:'+_0x1f7f2f['id']);return _0x423d77['start']['isBefore'](_0x4691db['start'])?-0x1:_0x423d77['start']['isAfter'](_0x4691db['start'])?0x1:_0x423d77['end']['isBefore'](_0x4691db['end'])?-0x1:_0x423d77['end']['isAfter'](_0x4691db['end'])?0x1:'add'===_0x341501['type']?-0x1:0x1;}),{'root':_0x138a70,'changes':_0x21c2a6};function _0x1cdd01(_0x14bd44,_0x5a46da,_0x36414b,_0xa17d67){const _0x4c3af8=!!_0x45c4fb[_0x5a46da][_0x14bd44],_0x457140=_0x4c3af8?_0x45c4fb[_0x5a46da][_0x14bd44]['userId']:null,_0x3d8fd8=_0x5a46da===_0x45c4fb['length']-0x1,_0x21a6c6=_0x4f172e[_0x14bd44][0x0],_0x359b2d=_0x113cbe['isObject'](_0x45c4fb[_0x5a46da]['item']);!_0xee3dc6[_0x14bd44]&&_0x4c3af8?_0xee3dc6[_0x14bd44]={'start':_0x36414b,'tapeItem':_0x45c4fb[_0x5a46da],'userId':_0x457140,'type':_0x14bd44}:_0xee3dc6[_0x14bd44]&&!_0x4c3af8?(_0xee3dc6[_0x14bd44]['end']=_0x36414b,_0x1b4129(_0xee3dc6[_0x14bd44]),_0xee3dc6[_0x14bd44]=null):_0xee3dc6[_0x14bd44]&&_0x4c3af8&&_0xee3dc6[_0x14bd44]['userId']!==_0x457140&&(_0xee3dc6[_0x14bd44]['end']=_0x36414b,_0x21a6c6&&_0x21a6c6['userId']===_0xee3dc6[_0x14bd44]['userId']||_0x1b4129(_0xee3dc6[_0x14bd44]),_0xee3dc6[_0x14bd44]={'start':_0x36414b,'tapeItem':_0x45c4fb[_0x5a46da],'userId':_0x457140,'type':_0x14bd44}),_0xee3dc6[_0x14bd44]&&_0x359b2d&&('elementStart'!==_0x45c4fb[_0x5a46da]['type']||_0x21a6c6&&_0x21a6c6['userId']===_0x457140||_0x4f172e[_0x14bd44]['unshift']({'userId':_0x457140,'object':_0x45c4fb[_0x5a46da]['item'],'change':_0xee3dc6[_0x14bd44]}),'elementEnd'===_0x45c4fb[_0x5a46da]['type']&&_0x21a6c6&&_0x21a6c6['object']===_0x45c4fb[_0x5a46da]['item']&&(_0x4f172e[_0x14bd44]['shift'](),_0xee3dc6[_0x14bd44]=_0x21a6c6['change'])),_0xee3dc6[_0x14bd44]&&_0x3d8fd8&&(_0xee3dc6[_0x14bd44]['end']=_0xa17d67,_0x1b4129(_0xee3dc6[_0x14bd44]),_0xee3dc6[_0x14bd44]=null);}function _0x1b4129({start:_0xa7038d,end:_0x2c7090,tapeItem:_0x4f7af3,userId:_0x1deb33,type:_0x5d8095}){const _0x52c5e0=_0x4f7af3['item'],_0x12aa72=_0x1ac215['schema']['isBlock'](_0x52c5e0)&&!_0x1ac215['schema']['isLimit'](_0x52c5e0),_0x1615ad=_0xa7038d['nodeAfter']==_0x2c7090['parent']&&_0x2c7090['isAtStart'];if(_0x12aa72&&_0x1615ad)return;const _0x3e951c=_0x1ac215['createRange'](_0xa7038d,_0x2c7090),_0x290803=_0x3c50dc['get'](_0x1deb33),_0x24773f=new r({'author':_0x290803,'type':'isAdded'==_0x5d8095||'isAddSuggestion'==_0x5d8095?'add':'remove','data':{'isSuggestion':'isAddSuggestion'==_0x5d8095||'isRemoveSuggestion'==_0x5d8095},'createdAt':new Date(),'rootName':_0x290a5c});_0x21c2a6['push'](_0x24773f),_0x138a70['markers']['set']('revision:'+_0x24773f['id'],_0x3e951c);}function _0x14b82a(_0x179e28,_0x185a41){const _0xd24a38=_0x179e28['getAttributes'](),_0x52674d=_0x185a41['getAttributes']();for(const _0x1bdcd9 of _0xd24a38){if(_0x1bdcd9[0x1]!==_0x185a41['getAttribute'](_0x1bdcd9[0x0]))return!0x1;_0x52674d['next']();}return _0x52674d['next']()['done'];}}['_setConversion'](){this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision','view':_0x105ce8=>{const _0x510f95=_0x105ce8['markerName']['split'](':')[0x1],_0x357d73=this['_getChangeFromId'](_0x510f95);if(!_0x357d73)return null;const _0x1bef37='add'==_0x357d73['type']?'insertion':'deletion',_0x330329=['ck-suggestion-marker','ck-suggestion-marker-'+_0x1bef37];return _0x357d73['data']['isSuggestion']&&_0x330329['push']('ck-suggestion-marker-'+_0x1bef37+'-new'),this['activeChange']==_0x357d73&&_0x330329['push']('ck-suggestion-marker--active'),{'classes':_0x330329,'attributes':{'data-change-id':_0x510f95}};}}),this['editor']['conversion']['for']('upcast')['add'](_0x53c7e0=>{_0x53c7e0['on']('element:pre',(_0x30cab9,_0x26f3d,_0x241f57)=>{const _0x158bde=_0x26f3d['viewItem']['getChild'](0x0);if(!_0x158bde||!_0x158bde['is']('element','code'))return;if(!_0x241f57['consumable']['consume'](_0x158bde,{'attributes':['vid_start','vid_end']}))return;const _0xc76f52=_0x26f3d['modelRange']['start']['nodeAfter'];_0x241f57['writer']['setAttribute']('vid_start',_0x158bde['getAttribute']('vid_start'),_0xc76f52),_0x241f57['writer']['setAttribute']('vid_end',_0x158bde['getAttribute']('vid_end'),_0xc76f52);},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['add'](_0xe68a66=>{_0xe68a66['on']('element',(_0x15e314,_0x41b1fa,_0x2908fe)=>{if(!_0x2908fe['consumable']['consume'](_0x41b1fa['viewItem'],{'attributes':['vid_start','vid_end']}))return;if(_0x41b1fa['modelRange']['isCollapsed'])return;const _0x4f3007=_0x41b1fa['modelRange']['start']['nodeAfter'];_0x4f3007['hasAttribute']('vid_start')||_0x4f3007['hasAttribute']('vid')||(_0x2908fe['writer']['setAttribute']('vid_start',_0x41b1fa['viewItem']['getAttribute']('vid_start'),_0x4f3007),_0x2908fe['writer']['setAttribute']('vid_end',_0x41b1fa['viewItem']['getAttribute']('vid_end'),_0x4f3007));},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['elementToAttribute']({'view':{'name':'span','attributes':{'vid':!0x0}},'model':{'key':'vid','value':_0x968cf9=>_0x968cf9['getAttribute']('vid')}}),this['editor']['model']['schema']['on']('checkAttribute',(_0x18041d,[,_0x536bcf])=>{['vid_start','vid_end','vid']['includes'](_0x536bcf)&&(_0x18041d['return']=!0x0,_0x18041d['stop']());},{'priority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x15aac6=>{_0x15aac6['on']('attribute:vid',(_0x46ee65,_0x4dcc43,_0x208f40)=>{if('\x20'!=_0x4dcc43['item']['data']||_0x4dcc43['item']['parent']['maxOffset']>0x1)return;if(!_0x208f40['consumable']['consume'](_0x4dcc43['item'],_0x46ee65['name']))return;const _0x1467ec=_0x208f40['writer'],_0x2165a7=_0x208f40['mapper']['toViewRange'](_0x4dcc43['range']);_0x1467ec['wrap'](_0x2165a7,_0x1467ec['createAttributeElement']('span'));});}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',function(_0x139c80){const _0x418820=_0x139c80['plugins']['get']('RevisionViewer');return(_0xcd3aaf,_0x1c5778,_0x38c9cb)=>{const _0x59b688=_0x1c5778['markerName']['split'](':')[0x1],_0x9d0bd1=_0x418820['_getChangeFromId'](_0x59b688);if(!_0x9d0bd1)return null;const _0xa15031='add'==_0x9d0bd1['type']?'split':'merge';if(!_0x38c9cb['consumable']['test'](_0x1c5778['markerRange'],_0xcd3aaf['name']))return;const _0x350acf=_0x1c5778['markerRange']['getWalker'](),_0x4463e5=_0x1c5778['markerRange']['start'],_0x447e17=_0x139c80['model']['schema'];let _0x1725ec=null,_0x5791ec=null,_0x2b4c88=!0x1,_0x3fc253=!0x1;for(const _0xd9384c of _0x350acf){const _0x299d07=_0xd9384c['item'];_0x2b4c88=_0x2b4c88||_0x447e17['isContent'](_0x299d07);const _0x2b48a0=_0x38c9cb['mapper']['toViewElement'](_0x299d07);if(_0x2b48a0&&_0x2b48a0['getCustomProperty']('addHighlight'))return;'elementEnd'==_0xd9384c['type']&&(_0x447e17['isBlock'](_0x299d07)&&!_0x447e17['isLimit'](_0x299d07)&&(_0x299d07['nextSibling']||_0x4463e5['isAtEnd']?_0x1725ec&&_0x1725ec['parent']==_0x299d07||(_0x1725ec=_0x299d07,_0x477703(_0xd9384c['previousPosition']),_0x3fc253=!0x0):_0x5791ec=_0x5791ec||_0xd9384c['previousPosition']));}function _0x477703(_0x35ea28){const _0x333f5d=_0x38c9cb['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0xa15031}),_0x2bd3fe=_0x38c9cb['mapper']['toViewPosition'](_0x35ea28);_0x9d0bd1['data']['isSuggestion']&&_0x38c9cb['writer']['addClass']('ck-suggestion-marker-'+_0xa15031+'-new',_0x333f5d),_0x418820['activeChange']==_0x9d0bd1&&_0x38c9cb['writer']['addClass']('ck-suggestion-marker--active',_0x333f5d),_0x38c9cb['writer']['insert'](_0x2bd3fe,_0x333f5d),_0x38c9cb['mapper']['bindElementToMarker'](_0x333f5d,_0x1c5778['markerName']);}_0x2b4c88||_0x3fc253||!_0x5791ec||_0x477703(_0x5791ec);};}(this['editor']),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision',(_0x13f7c3,_0x3e6802,_0x44f895)=>{const _0x288393=_0x44f895['mapper']['markerNameToElements'](_0x3e6802['markerName']);if(_0x288393){for(const _0x3a9b50 of _0x288393)(_0x3a9b50['hasClass']('ck-suggestion-marker-split')||_0x3a9b50['hasClass']('ck-suggestion-marker-merge'))&&(_0x44f895['mapper']['unbindElementFromMarkerName'](_0x3a9b50,_0x3e6802['markerName']),_0x44f895['writer']['remove'](_0x3a9b50));}},{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',(_0x386e50,_0x2ef610,_0x33cfa1)=>{const _0x5f051b=_0x2ef610['markerName']['split'](':')[0x1],_0x59bc36=this['_getChangeFromId'](_0x5f051b);if(!_0x59bc36)return null;const _0x2fb358='add'==_0x59bc36['type']?'split':'merge';if(_0x33cfa1['consumable']['test'](_0x2ef610['markerRange'],_0x386e50['name']))for(const _0x2f075f of _0x2ef610['markerRange']['getItems']()){if(!_0x2f075f['is']('element','softBreak'))continue;const _0x32ae4f=_0x33cfa1['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x2fb358}),_0x55360d=_0x33cfa1['mapper']['toViewPosition'](this['editor']['model']['createPositionBefore'](_0x2f075f));_0x59bc36['data']['isSuggestion']&&_0x33cfa1['writer']['addClass']('ck-suggestion-marker-'+_0x2fb358+'-new',_0x32ae4f),this['activeChange']==_0x59bc36&&_0x33cfa1['writer']['addClass']('ck-suggestion-marker--active',_0x32ae4f),_0x33cfa1['writer']['insert'](_0x55360d,_0x32ae4f),_0x33cfa1['mapper']['bindElementToMarker'](_0x32ae4f,_0x2ef610['markerName']);}},{'priority':'high'}),this['editor']['model']['document']['on']('change',()=>{this['editor']['editing']['view']['change'](_0x15fcf1=>{for(const _0x71dfea of this['editor']['model']['document']['getRootNames']()){const _0x4eb96a=this['editor']['model']['document']['getRoot'](_0x71dfea),_0x4fde9c=this['editor']['editing']['view']['document']['getRoot'](_0x71dfea);if(_0x4fde9c){const _0x5b0d1c=_0x4eb96a['getAttribute']('revisionHistoryAttachChange');if(_0x15fcf1['removeAttribute']('data-change-id',_0x4fde9c),_0x15fcf1['removeClass']('ck-revision-history-root-add',_0x4fde9c),_0x15fcf1['removeClass']('ck-revision-history-root-remove',_0x4fde9c),_0x15fcf1['removeClass']('ck-revision-history-root--active',_0x4fde9c),_0x5b0d1c){const _0x142ede=this['_getChangeFromId'](_0x5b0d1c);if(!_0x142ede)return null;_0x15fcf1['setAttribute']('data-change-id',_0x5b0d1c,_0x4fde9c),_0x15fcf1['addClass']('ck-revision-history-root-'+_0x142ede['type'],_0x4fde9c),this['activeChange']==_0x142ede&&_0x15fcf1['addClass']('ck-revision-history-root--active',_0x4fde9c);}}}});}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'comment','model':_0xde7212=>'revision-comment:'+_0xde7212,'converterPriority':'highest'}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'suggestion','model':_0x2e9efe=>'revision-suggestion:'+_0x2e9efe,'converterPriority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision-suggestion','view':_0x52ffb3=>({'name':'suggestion:'+_0x52ffb3,'group':'revision-suggestion'}),'converterPriority':'highest'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision-suggestion','view':_0x141cd5=>{const _0x355bd9=_0x141cd5['markerName']['split'](':')[0x1];return'insertion'!=_0x355bd9&&'deletion'!=_0x355bd9?null:{'classes':['ck-suggestion-preview-marker','ck-suggestion-preview-marker-'+_0x355bd9]};}}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:deletion',X(this['editor'],'merge'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:insertion',X(this['editor'],'split'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision-suggestion',(_0x165143,_0x24cfed,_0x4448b4)=>{const _0x439ba5=_0x4448b4['mapper']['markerNameToElements'](_0x24cfed['markerName']);if(_0x439ba5){for(const _0x5e0974 of _0x439ba5)_0x5e0974['is']('uiElement')&&(_0x4448b4['mapper']['unbindElementFromMarkerName'](_0x5e0974,_0x24cfed['markerName']),_0x4448b4['writer']['remove'](_0x5e0974));}},{'priority':'high'});}['_getChangeFromId'](_0x2b0cab){return this['_changeIdToChange']['get'](_0x2b0cab);}['_getViewForChange'](_0x3daf6a){return this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=new Q(this['editor']['locale'],_0x3daf6a),this['_changeView'];}['_initInteractions'](){this['editor']['model']['document']['selection']['observeMarkers']('revision'),this['on']('change:activeView',(_0x4c0f49,_0x307544,_0x5b0e7c,_0x5e6a70)=>{_0x5e6a70&&this['_balloon']['remove'](_0x5e6a70),_0x5b0e7c&&(this['_balloon']['add']({'view':_0x5b0e7c,'stackId':'revisionHistoryLabel','position':{'target':()=>{const _0x330963=this['editor']['editing'],_0x6ca99=this['_getChangeFromId'](_0x5b0e7c['changeId']);let _0x24f739;if(_0x6ca99['data']['isOnRoot']){const _0x198be9=_0x330963['view']['getDomRoot'](_0x6ca99['rootName']);_0x24f739=Array['from'](_0x198be9['getClientRects']());}else{const _0x1a27d8=this['editor']['model']['markers']['get']('revision:'+_0x5b0e7c['changeId']);_0x24f739=Array['from'](_0x330963['mapper']['markerNameToElements'](_0x1a27d8['name']))['map'](_0x56e788=>_0x330963['view']['domConverter']['mapViewToDom'](_0x56e788))['map'](_0x36733c=>Array['from'](_0x36733c['getClientRects']()))['flat']();}if(!this['_activeViewTarget'])return _0x24f739[0x0];return _0x24f739['find'](_0x3e1113=>_0x3e1113['top']-0x3<=this['_activeViewTarget']['y']&&_0x3e1113['bottom']+0x3>=this['_activeViewTarget']['y']&&_0x3e1113['left']-0x3<=this['_activeViewTarget']['x']&&_0x3e1113['right']+0x3>=this['_activeViewTarget']['x'])||_0x24f739[0x0];}}}),this['_balloon']['showStack']('revisionHistoryLabel'));}),this['on']('change:activeChange',(_0x429a05,_0x47d599,_0x51caf7,_0x38a6f7)=>{this['activeView']=_0x51caf7?this['_getViewForChange'](_0x51caf7):null,this['editor']['model']['change'](()=>{const _0x50745c=this['editor']['editing'];_0x38a6f7&&(_0x38a6f7['data']['isOnRoot']?_0x50745c['view']['change'](_0x2f4359=>{_0x2f4359['removeClass']('ck-revision-history-root--active',_0x50745c['view']['document']['getRoot'](_0x38a6f7['rootName']));}):_0x50745c['reconvertMarker']('revision:'+_0x38a6f7['id'])),_0x51caf7&&(_0x51caf7['data']['isOnRoot']?_0x50745c['view']['change'](_0x2c306c=>{_0x2c306c['addClass']('ck-revision-history-root--active',_0x50745c['view']['document']['getRoot'](_0x51caf7['rootName']));}):_0x50745c['reconvertMarker']('revision:'+_0x51caf7['id']));});}),this['listenTo'](this['editor']['editing']['view']['document'],'mouseover',(_0x26ed82,_0x2acf23)=>{if(this['activeChange'])return;const _0x4dc887=this['_findChangeIdFromDomTarget'](_0x2acf23['target']),_0x4f0f0d=this['_changeIdToChange']['get'](_0x4dc887);_0x4f0f0d?(this['_activeViewTarget']={'x':_0x2acf23['domEvent']['x'],'y':_0x2acf23['domEvent']['y']},this['activeView']=this['_getViewForChange'](_0x4f0f0d)):(this['_activeViewTarget']=null,this['activeView']=null);}),this['listenTo'](this['editor']['editing']['view']['document'],'mousedown',(_0x1b2325,_0xefd280)=>{const _0x6e8e83=this['_findChangeIdFromDomTarget'](_0xefd280['target']),_0x3264f6=this['_changeIdToChange']['get'](_0x6e8e83);_0x3264f6?(this['_activeViewTarget']={'x':_0xefd280['domEvent']['x'],'y':_0xefd280['domEvent']['y']},_0x3264f6===this['activeChange']?this['_balloon']['updatePosition']():this['activeChange']=_0x3264f6):(this['_activeViewTarget']=null,this['activeChange']=null);});}['_findChangeIdFromDomTarget'](_0xb94be0){do{const _0x2181e3=_0xb94be0['getAttribute']('data-change-id');if(_0x2181e3)return _0x2181e3;_0xb94be0=_0xb94be0['parent'];}while(_0xb94be0);return null;}['_cleanMarkers'](){this['editor']['model']['change'](_0x105986=>{for(const _0x3cdb2a of this['editor']['model']['markers'])_0x105986['removeMarker'](_0x3cdb2a);});}}function X(_0x2a47ea,_0x54d669){return(_0x1d3ab5,_0x2075cc,_0x5e0800)=>{if(!_0x5e0800['consumable']['test'](_0x2075cc['markerRange'],_0x1d3ab5['name']))return;const _0x590f3c=_0x2075cc['markerRange']['getWalker'](),_0x4f7fbe=_0x2075cc['markerRange']['start'],_0x2bd29d=_0x2a47ea['model']['schema'];let _0x350724=null,_0x3760a9=null,_0x54c053=!0x1,_0x338708=!0x1;for(const _0x302856 of _0x590f3c){const _0x15dfa2=_0x302856['item'];_0x54c053=_0x54c053||_0x2bd29d['isContent'](_0x15dfa2);const _0x463382=_0x5e0800['mapper']['toViewElement'](_0x15dfa2);if(_0x463382&&_0x463382['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x302856['type']&&(_0x2bd29d['isBlock'](_0x15dfa2)&&!_0x2bd29d['isLimit'](_0x15dfa2)&&(_0x15dfa2['nextSibling']||_0x4f7fbe['isAtEnd']?_0x350724&&_0x350724['parent']==_0x15dfa2||(_0x350724=_0x15dfa2,_0x544585(_0x302856['previousPosition']),_0x338708=!0x0):_0x3760a9=_0x3760a9||_0x302856['previousPosition']));}function _0x544585(_0x105afb){const _0x5c119b=_0x5e0800['mapper']['toViewPosition'](_0x105afb),_0x528c00=_0x5e0800['writer']['createUIElement']('span',{'class':'ck-suggestion-preview-marker-'+_0x54d669});_0x5e0800['writer']['insert'](_0x5c119b,_0x528c00),_0x5e0800['mapper']['bindElementToMarker'](_0x528c00,_0x2075cc['markerName']);}_0x54c053||_0x338708||!_0x3760a9||_0x544585(_0x3760a9);};}class mt extends _0x319f45{constructor(_0x361183){super(_0x361183);const _0x57cc3a=_0x361183['plugins']['get'](m);this['affectsData']=!0x1,this['listenTo'](_0x57cc3a,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x57cc3a,'change:isEnabled',()=>this['refresh']());}['execute'](){const _0x7b79d3=this['editor'],_0x3880f9=_0x7b79d3['plugins']['get'](m),_0x46a33a=_0x3880f9['isReady']?_0x3880f9['diff']['newRevisionId']:null;_0x7b79d3['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x46a33a);}['refresh'](){const {isReady:_0xc002ff,isEnabled:_0xda7ed9,repository:_0x1ac0ed,diff:_0x542356}=this['editor']['plugins']['get'](m),_0x3c3d1e=_0x542356&&_0x1ac0ed['getLaterVisibleRevision'](_0x542356['newRevisionId']);this['isEnabled']=_0xc002ff&&_0xda7ed9&&Boolean(_0x3c3d1e);}}class wt extends _0x319f45{['_step'];constructor(_0x14bfb7,{direction:_0x4cad45}){super(_0x14bfb7);const _0x1f5633=_0x14bfb7['plugins']['get'](m);this['affectsData']=!0x1,this['_step']='forward'===_0x4cad45?0x1:-0x1,this['listenTo'](_0x1f5633,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x1f5633,'change:isEnabled',()=>this['refresh']()),this['listenTo'](_0x1f5633,'change:activeChange',()=>this['refresh']());}['execute'](){const _0x1ee245=this['editor'],_0x2c7818=_0x1ee245['plugins']['get'](m),{isNavigationMode:_0x650e83,currentChangeNumber:_0x17d4f5}=_0x2c7818;let _0x3801fa;if(_0x2c7818['activeChange']=_0x650e83?_0x2c7818['diff']['changes']['get'](_0x17d4f5+this['_step']):_0x2c7818['diff']['changes']['first'],_0x2c7818['activeChange']['data']['isOnRoot'])_0x3801fa=_0x1ee245['editing']['view']['getDomRoot'](_0x2c7818['activeChange']['rootName']);else{const _0x573fad=_0x1ee245['model']['markers']['get']('revision:'+_0x2c7818['activeChange']['id']);_0x3801fa=_0x474913(_0x1ee245['editing'],_0x573fad);}_0x2a2e34({'target':_0x3801fa,'viewportOffset':0x28});}['refresh'](){const {isNavigationMode:_0x16659b,currentChangeNumber:_0x8bc8fc,numberOfChanges:_0x4611f2,isReady:_0x236419,isEnabled:_0x597906}=this['editor']['plugins']['get'](m);this['isEnabled']=!!(_0x597906&&_0x236419&&_0x4611f2)&&(!_0x16659b||(0x1===this['_step']?_0x8bc8fc<_0x4611f2-0x1:_0x8bc8fc>0x0));}}class _i extends ts{constructor(_0x22d738){super(_0x22d738);const _0xb857ae=this['bindTemplate'],_0x39cf3b=new te(_0x22d738),_0x44cad3=new te(_0x22d738);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',(_0x4127ae,_0x3fb0c6)=>_0x4127ae&&_0x3fb0c6>0x0),this['bind']('_statusText')['to'](this,'isReady',this,'currentChangeNumber',this,'numberOfChanges',this,'isNavigationMode',(_0x1698d1,_0xce2ed6,_0xf6e0ce,_0x7b0a3c)=>{if(!_0x1698d1)return g(_0x22d738,'Loading...');if(!_0xf6e0ce)return g(_0x22d738,'No\x20changes');const _0x53e877=g(_0x22d738,'NUMBER_OF_CHANGES',_0xf6e0ce);return _0x7b0a3c?g(_0x22d738,'X_OF_Y_CHANGES',[_0xce2ed6+0x1,_0xf6e0ce]):_0x53e877;}),_0x39cf3b['set']({'label':g(_0x22d738,'Show\x20previous\x20change'),'tooltip':!0x0,'icon':_0x1d9c31}),_0x44cad3['set']({'label':g(_0x22d738,'Show\x20next\x20change'),'tooltip':!0x0,'icon':_0x150a4c}),_0x39cf3b['bind']('isEnabled')['to'](this,'isBackwardNavigationEnabled'),_0x44cad3['bind']('isEnabled')['to'](this,'isForwardNavigationEnabled'),_0x39cf3b['on']('execute',()=>this['fire']('execute','backward')),_0x44cad3['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',_0xb857ae['if']('_isStatusLabelVisible','ck-hidden',_0x33d8d0=>!_0x33d8d0)]},'children':[{'text':_0xb857ae['to']('isNavigationMode',_0x11bce0=>_0x11bce0?g(_0x22d738,'EDIT_X_OF_Y_REVISIONS')+':\x20':g(_0x22d738,'Total')+':\x20')}]},{'text':_0xb857ae['to']('_statusText')}]},new _0x3bd5de(),{'tag':'div','attributes':{'class':['ck-revision-history-ui__changes-navigation__navigation']},'children':[_0x39cf3b,_0x44cad3]}]});}}const le='ck-editor__editable__loading-overlay';class ge extends _0x311e14{static get['pluginName'](){return'RevisionViewerLoadingOverlay';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['show'](){const _0x1f9a52=this['editor']['editing']['view'];_0x1f9a52['change'](_0x2b4f34=>{for(const _0x1f8669 of _0x1f9a52['document']['roots'])_0x2b4f34['addClass'](le,_0x1f8669);});}['hide'](){const _0x4ff2fe=this['editor']['editing']['view'];_0x4ff2fe['change'](_0x1203f6=>{for(const _0x32e229 of _0x4ff2fe['document']['roots'])_0x1203f6['removeClass'](le,_0x32e229);});}}class R extends _0x311e14{static get['pluginName'](){return'RevisionViewerUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[m,ge];}['init'](){const _0x238124=this['editor'],_0xf438d4=_0x238124['plugins']['get'](m),_0x35f6f3=_0x238124['plugins']['get'](ge);_0x238124['ui']['componentFactory']['add']('exitToEditing',_0x1b5c33=>{const _0x233d3a=new te(_0x1b5c33);return _0x233d3a['set']({'label':g(_0x1b5c33,'Back\x20to\x20editing'),'icon':_0x5ed362,'withText':!0x0,'tooltip':!0x0,'class':'ck-revision-history-ui__back-to-editing'}),this['listenTo'](_0x233d3a,'execute',()=>{_0x238124['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}),_0x233d3a;}),_0x238124['ui']['componentFactory']['add']('restoreRevision',_0x352b9c=>{const _0x7967e7=new te(_0x352b9c);return _0x7967e7['set']({'label':g(_0x352b9c,'Restore\x20this\x20revision'),'withText':!0x0,'tooltip':!0x0}),_0x7967e7['bind']('isEnabled')['to'](_0x238124['commands']['get']('restoreRevision')),this['listenTo'](_0x7967e7,'execute',()=>_0x238124['execute']('restoreRevision')),_0x7967e7;}),_0x238124['ui']['componentFactory']['add']('changesNavigation',_0x312675=>{const _0x39689c=new _i(_0x312675),_0x5e4c0b=_0x238124['commands']['get']('showPreviousChange'),_0x3656c6=_0x238124['commands']['get']('showNextChange');return _0x39689c['bind']('isBackwardNavigationEnabled')['to'](_0x5e4c0b,'isEnabled'),_0x39689c['bind']('isForwardNavigationEnabled')['to'](_0x3656c6,'isEnabled'),_0x39689c['bind']('isReady','currentChangeNumber','numberOfChanges','isNavigationMode')['to'](_0xf438d4),this['listenTo'](_0x39689c,'execute',(_0x22f636,_0x26e438)=>{_0x238124['execute']('forward'===_0x26e438?'showNextChange':'showPreviousChange');}),_0x39689c;}),_0x35f6f3['show'](),_0xf438d4['on']('change:isReady',(_0x5ab9e8,_0x44b67c,_0x413667)=>{_0x413667?_0x35f6f3['hide']():_0x35f6f3['show']();});}}class at extends _0xd345cd{['_resizeObserver']=null;constructor(_0x328863,_0x50ff88){super(_0x328863,_0x50ff88);const _0xf6d06e=this['bindTemplate'];this['set']({'label':g(_0x328863,'Revision\x20name'),'_tooltipString':''}),this['fieldView']['placeholder']=g(_0x328863,'Enter\x20the\x20revision\x20name'),this['extendTemplate']({'tag':'span','attributes':{'class':['ck-revision-history-sidebar__revision-name'],'data-cke-tooltip-text':_0xf6d06e['to']('_tooltipString'),'data-cke-tooltip-position':'s','data-cke-tooltip-class':'ck-tooltip_multi-line'}});}['render'](){super['render'](),this['_resizeObserver']=new nt(this['fieldView']['element'],()=>this['_updateTooltipText']()),this['listenTo'](this['fieldView'],'input',()=>this['_updateTooltipText']());}['destroy'](){super['destroy'](),this['_resizeObserver']&&this['_resizeObserver']['destroy']();}['_updateTooltipText'](){const _0x58dd48=this['fieldView']['element'];this['_tooltipString']=_0x58dd48['scrollWidth']>_0x58dd48['clientWidth']&&_0x58dd48['value']||'';}}class si extends ts{constructor(_0x1a3107,_0x138c64,_0xe27d38){super(_0x1a3107);const _0x12d579=new _0x90a81a();_0x12d579['set']({'content':_0x68f6e0,'viewBox':'0\x200\x2011\x2010'});const _0x2bac27=['ck','ck-revision-history-sidebar__revision-author'];_0xe27d38&&_0x2bac27['push']('ck-revision-history-sidebar__revision-author_creator');const _0x30a5eb=[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision-author__name'],'title':g(_0x1a3107,_0xe27d38?'Revision\x20creator':'Revision\x20author')},'children':[_0x12d579,_0x138c64['name']]}];this['setTemplate']({'tag':'li','attributes':{'class':_0x2bac27},'children':_0x30a5eb});}}function oi(_0x2749e9,_0x1ff0b2){const _0x49d9d2=_0x2749e9['bindTemplate'],_0x5a7e94=_0x2749e9['locale'],_0x4ae400=_0x1a9092(_0x5a7e94);_0x4ae400['panelPosition']='sw';const _0x3a8a1a=function(_0x43eedc,_0x4990d5){const _0x598721=function(_0x31046c,_0x50b35c){const _0x3b18b5=_0x31046c['locale'],_0x4d23a7={'Compare\x20against\x20selected':g(_0x3b18b5,'Compare\x20against\x20selected'),'Name\x20this\x20revision':g(_0x3b18b5,'Name\x20this\x20revision'),'Restore\x20this\x20revision':g(_0x3b18b5,'Restore\x20this\x20revision')};return _0x50b35c['map'](_0x55efbb=>{const _0xba96e=_0x4d23a7[_0x55efbb['name']];return _0xba96e&&_0xba96e!==_0x55efbb['name']&&(_0x55efbb['name']=_0xba96e),_0x55efbb;});}(_0x43eedc,_0x4990d5),_0x124c99=new _0x4e7c66();for(const _0xd20a22 of _0x598721){const _0x4ef85c={'type':'button','model':new to({'label':_0xd20a22['name'],'class':_0xd20a22['class'],'withText':!0x0,'role':'menuitem','_action':_0xd20a22['action']})};_0x4ef85c['model']['bind']('isEnabled')['to'](_0x43eedc,'isActionsDropdownOpen',_0x323ac9=>'function'!=typeof _0xd20a22['isEnabled']||(!_0x323ac9||_0xd20a22['isEnabled'](_0x43eedc))),_0x124c99['add'](_0x4ef85c);}return _0x124c99;}(_0x2749e9,_0x1ff0b2);return _0x2749e9['bind']('isActionsDropdownOpen')['to'](_0x4ae400,'isOpen'),_0x4ae400['buttonView']['set']({'label':g(_0x5a7e94,'Show\x20more\x20items'),'tooltip':!0x0,'tooltipPosition':'sw','icon':_0x563a33}),_0x4ae400['extendTemplate']({'attributes':{'class':['ck-revision-history-sidebar__revision__actions',_0x49d9d2['if']('isActionsDropdownOpen','ck-on')]},'on':{'click':_0x49d9d2['to'](_0x360f65=>_0x360f65['stopPropagation']())}}),_0x4ae400['on']('execute',_0x275092=>{_0x2749e9['isReady']&&'function'==typeof _0x275092['source']['_action']&&_0x275092['source']['_action'](_0x2749e9);}),_0x4ac3d4(_0x4ae400,_0x3a8a1a,{'role':'menu'}),_0x4ae400['listenTo'](_0x2749e9,'change:isActionsDropdownOpen',(_0x4258c6,_0xd4bdc8,_0x245bc0)=>{if(_0x245bc0)for(const _0x4cc424 of _0x4ae400['listView']['items']){const _0x270ff7=_0x4cc424['children']['first'],_0x516b6f=_0x1ff0b2['find'](_0xbaabc1=>_0xbaabc1['action']===_0x270ff7['_action'])['isVisible'];_0x4cc424['isVisible']=void 0x0===_0x516b6f||_0x516b6f(_0x2749e9);}}),_0x4ae400;}class hi extends/* #__PURE__ -- @preserve */
26
- ti(ts){['id'];['revisionNameView'];['revisionActionsView'];['_revision'];['_requireRevisionName'];constructor(_0x7577ce,_0xd9d2de,_0x4df8a2,_0x287bbd){super(_0x7577ce);const _0xfc52b3=this['bindTemplate'],_0x37455a=function(_0xba61db,_0x280405){const _0x5da88a=Array['from'](_0x280405['authors'])['filter'](_0x2dc9a1=>_0x2dc9a1!=_0x280405['creator']);return _0x280405['creator']&&_0x5da88a['unshift'](_0x280405['creator']),_0x5da88a['map'](_0x2049f6=>new si(_0xba61db,_0x2049f6,_0x2049f6==_0x280405['creator']));}(_0x7577ce,_0xd9d2de);this['id']=_0xd9d2de['id'],this['_revision']=_0xd9d2de,this['_requireRevisionName']=_0x287bbd,this['bind']('name','createdAt')['to'](_0xd9d2de),this['bind']('_createdAtFormatted')['to'](this,'createdAt',_0x5449e5=>{return _0x4fc626=_0x7577ce['uiLanguage'],(_0x78dd2c=_0x5449e5)['toLocaleDateString'](_0x4fc626,{'month':'long','day':'numeric'})+',\x20'+_0x78dd2c['toLocaleTimeString'](_0x4fc626,{'hour':'numeric','minute':'numeric'});var _0x4fc626,_0x78dd2c;}),this['set']('isSelected',!0x1),this['set']('isHighlighted',!0x1),this['set']('isActionsDropdownOpen',!0x1),this['set']('isReady',!0x1),this['set']('isEnabled',!0x1),this['revisionNameView']=new at(_0x7577ce,_0x560f91),this['revisionNameView']['fieldView']['extendTemplate']({'attributes':{'maxlength':'220'}}),this['revisionNameView']['fieldView']['bind']('value')['to'](this,'name',_0x3b4c5a=>_0x3b4c5a||this['_createdAtFormatted']),this['revisionNameView']['bind']('isEnabled')['to'](this,'isSelected',this,'isEnabled',(_0x80205d,_0x395934)=>_0x80205d&&_0x395934),this['revisionActionsView']=_0x4df8a2&&_0x4df8a2['length']?oi(this,_0x4df8a2):'',this['revisionActionsView']&&this['revisionActionsView']['bind']('isEnabled')['to'](this),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision-wrapper',_0xfc52b3['if']('isConfirm','ck-revision-history-sidebar__revision-wrapper_confirmation_visible')]},'children':[{'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision',_0xfc52b3['if']('isEnabled','ck-disabled',_0x4947c4=>!_0x4947c4),_0xfc52b3['if']('isSelected','ck-revision-history-sidebar__revision_selected'),_0xfc52b3['if']('isHighlighted','ck-revision-history-sidebar__revision_highlighted'),_0xfc52b3['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':_0xfc52b3['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':_0x37455a}]},this['revisionActionsView']],'on':{'click':_0xfc52b3['to'](_0x42e47b=>{_0x42e47b['srcElement']['closest']('.ck-thread__remove-confirm')||this['isReady']&&this['isEnabled']&&this['fire']('select',{'id':this['id']});})}}]});}['render'](){super['render']();const _0x51be7f=this['revisionNameView']['fieldView']['element'];this['listenTo'](_0x51be7f,'change',()=>{this['_requireRevisionName']&&!_0x51be7f['value']||this['fire']('setName',{'id':this['id'],'name':_0x51be7f['value']}),_0x51be7f['value']||(_0x51be7f['value']=this['name']?this['name']:this['_createdAtFormatted']);});}['select'](){this['isSelected']=!0x0;}['deselect'](){this['isSelected']=!0x1;}['highlight'](){this['isHighlighted']=!0x0;}['unhighlight'](){this['isHighlighted']=!0x1;}}function ai(_0xddc69,_0x6f369a){const _0x365c80=_0x5237f3['fromJSDate'](_0xddc69)['setLocale'](_0x6f369a),_0x5bd33d=_0x5237f3['local'](),_0x387285=_0x5bd33d['minus']({'days':0x1})['startOf']('day');let _0x1ea18a,_0x2da85c;return _0x365c80['hasSame'](_0x5bd33d,'day')?(_0x1ea18a=_0x365c80['startOf']('day')['toJSDate'](),_0x2da85c=_0x365c80['toRelativeCalendar']()):_0x365c80['hasSame'](_0x387285,'day')?(_0x1ea18a=_0x387285['toJSDate'](),_0x2da85c=_0x365c80['toRelativeCalendar']()):_0x365c80['hasSame'](_0x5bd33d,'week')?(_0x1ea18a=_0x365c80['startOf']('week')['toJSDate'](),_0x2da85c=_0x365c80['weekdayLong']||''):_0x365c80['hasSame'](_0x5bd33d,'year')?(_0x1ea18a=_0x365c80['startOf']('month')['toJSDate'](),_0x2da85c=_0x365c80['monthLong']||''):(_0x1ea18a=_0x365c80['startOf']('year')['toJSDate'](),_0x2da85c=String(_0x365c80['year'])),{'startDate':_0x1ea18a,'localizedPeriodName':_0x2da85c};}class di extends ts{['startDate'];['revisionViews'];['_revisionActions'];['_requireRevisionName'];constructor(_0x5c7e81,_0x243175,_0x7a32ca,_0x246089){super(_0x5c7e81);const _0xab9a28=ai(_0x243175,this['locale']['uiLanguage'])['localizedPeriodName'];this['startDate']=_0x243175,this['revisionViews']=this['createCollection'](),this['_revisionActions']=_0x7a32ca,this['_requireRevisionName']=_0x246089,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':_0xab9a28}]},{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__time-period__revisions']},'children':this['revisionViews']}]});}['addRevision'](_0x1e78e2){const _0x293239=new hi(this['locale'],_0x1e78e2,this['_revisionActions'],this['_requireRevisionName']);this['revisionViews']['add'](_0x293239);}['removeRevision'](_0x3b1d3f){const _0x118ff9=this['revisionViews']['find'](_0x24dadf=>_0x24dadf['id']===_0x3b1d3f['id']);this['revisionViews']['remove'](_0x118ff9);}}class as extends ts{constructor(_0x11a4a9){super(_0x11a4a9);const _0x11d3fb=new _0x90a81a();_0x11d3fb['content']=_0xd06bb,this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset_all','ck-revision-history-sidebar__header']},'children':[_0x11d3fb,{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__header__label']},'children':[g(_0x11a4a9,'Revision\x20history')]}]});}}class ni extends ts{['timePeriodViews'];['_revisions'];['_revisionActions'];['_requireRevisionName'];constructor(_0x2afed3,_0x1b2045,_0x407189,_0x1fcdcd){super(_0x2afed3);const _0x300f15=this['bindTemplate'];this['timePeriodViews']=this['createCollection'](),this['timePeriodViews']['delegate']('select')['to'](this),this['timePeriodViews']['delegate']('setName')['to'](this),this['_revisions']=_0x1b2045,this['_revisionActions']=_0x407189,this['_requireRevisionName']=_0x1fcdcd,this['on']('select',(_0x3bc12b,_0x1f4ddf)=>{this['fire']('revisionSelected',_0x1f4ddf);}),this['on']('setName',(_0x3da702,_0x5565ff)=>{this['fire']('revisionSetName',_0x5565ff);}),this['set']('isEnabled',!0x1),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-rounded-corners','ck-revision-history-sidebar']},'children':[new as(_0x2afed3),{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__timeline',_0x300f15['if']('isEnabled','ck-disabled',_0x2656d6=>!_0x2656d6)]},'children':this['timePeriodViews']}]});}['render'](){super['render']();for(const _0x213052 of this['_revisions'])this['_addRevision'](_0x213052);this['_revisions']['on']('add',(_0x56cdb9,_0x5691ec)=>{this['_addRevision'](_0x5691ec);}),this['_revisions']['on']('remove',(_0x42cfe1,_0x2672d3)=>{this['_removeRevision'](_0x2672d3);});}get['revisionViews'](){return this['timePeriodViews']['map'](_0x35c0af=>_0x35c0af['revisionViews']['map'](_0x4ce90f=>_0x4ce90f))['flat']();}['selectRevision'](_0x4563f7){for(const _0x53d1a2 of this['revisionViews'])_0x4563f7&&_0x4563f7['id']===_0x53d1a2['id']?_0x53d1a2['select']():_0x53d1a2['deselect']();}['highlightRevisions'](_0x488ecf){for(const _0x288a8d of this['revisionViews'])_0x488ecf['some'](({id:_0x9c9fe})=>_0x9c9fe===_0x288a8d['id'])?_0x288a8d['highlight']():_0x288a8d['unhighlight']();}['_addRevision'](_0x405fa0){const _0x4a9b39=ai(_0x405fa0['createdAt'],this['locale']['uiLanguage'])['startDate'];let _0xc8f83a=this['timePeriodViews']['get'](0x0);_0xc8f83a&&_0xc8f83a['startDate']['getTime']()===_0x4a9b39['getTime']()||(_0xc8f83a=new di(this['locale'],_0x4a9b39,this['_revisionActions'],this['_requireRevisionName']),this['timePeriodViews']['add'](_0xc8f83a)),_0xc8f83a['addRevision'](_0x405fa0);}['_removeRevision'](_0x5e4b8b){const _0x166c9d=ai(_0x5e4b8b['createdAt'],this['locale']['uiLanguage'])['startDate'];this['_getTimePeriodViewByStartDate'](_0x166c9d)['removeRevision'](_0x5e4b8b);}['_getTimePeriodViewByStartDate'](_0xb085ce){return this['timePeriodViews']['find'](_0x50fd14=>_0x50fd14['startDate']['getTime']()===_0xb085ce['getTime']());}}class d extends _0x311e14{['_revisionViewer'];['_revisionsRepository'];['_sidebarView'];static ['defaultRevisionActions']=/* #__PURE__ -- @preserve */
23
+ import{ObservableMixin as _0x4fa367,uid as _0x2a1139,Collection as _0x239345,logWarning as _0x1e9999,FocusTracker as _0x1a5bd3,KeystrokeHandler as _0x5906fb,scrollViewportToShowTarget as _0xdb082a,ResizeObserver as nt,ElementReplacer as ot,CKEditorError as _0x5b4da3}from'@ckeditor/ckeditor5-utils/dist/index.js';import{cloneDeep as _0x40ea9a,set as _0x3cff0f,unset as _0x499e91,isEqual as _0x1f0b3c}from'es-toolkit/compat';import{Plugin as _0x443a46,PendingActions as _0x41643f,Command as _0x4ad7f3,ElementApiMixin as _0x5380ba,Editor as _0x17449b}from'@ckeditor/ckeditor5-core/dist/index.js';import{Users as _0x33d7db,getMarkerDomElement as _0x286786,ConfirmMixin as ti,sanitizeEditorConfig as _0x2915b1}from'ckeditor5-collaboration/dist/index.js';import{ViewContainerElement as _0x20d04c,ViewAttributeElement as _0x5550f8,ViewEmptyElement as _0x415b23,ViewRawElement as _0x161449,ViewUIElement as _0x3188b4,ViewDocumentFragment as _0x3a3b7a,ViewText as _0x255c11,ViewElement as _0x1eabbf,Element as ut,Range as lt,Position as ft,DocumentFragment as vt,Text as gt}from'@ckeditor/ckeditor5-engine/dist/index.js';import{IconHistory as _0x1ac31f,IconChevronUp as _0x2858bc,IconChevronDown as _0x1c5bf8,IconUndo as _0x7b404c,IconUser as _0x461254,IconThreeVerticalDots as _0x3a1eed}from'@ckeditor/ckeditor5-icons/dist/index.js';import{View as ts,injectCssTransitionDisabler as _0x51d33e,submitHandler as _0x47de8a,LabeledFieldView as _0x5d8229,createLabeledInputText as _0x302711,createDropdown as _0x1429b9,ListView as _0x8fa149,ListItemView as _0xd18afd,ButtonView as te,MenuBarMenuView as _0x2126e1,MenuBarMenuListView as _0x1ff503,MenuBarMenuListItemView as _0x4a9d4a,MenuBarMenuListItemButtonView as _0x3fe7a4,ContextualBalloon as _0x1d7948,ToolbarSeparatorView as _0x4f8ba2,IconView as _0x5c632d,addListToDropdown as _0xc4778d,ViewModel as to,EditorUI as st,normalizeToolbarConfig as et,BoxedEditorUIView as rt,StickyPanelView as ht,ToolbarView as dt,InlineEditableUIView as ct}from'@ckeditor/ckeditor5-ui/dist/index.js';import{DateTime as _0x473ede}from'luxon';class h extends/* #__PURE__ -- @preserve */
24
+ _0x4fa367(){['id'];['creator'];['authors'];['diffData'];['toVersion'];['fromVersion'];['model'];constructor(_0x39b478){super(),this['id']=_0x39b478['id']||_0x2a1139(),this['creator']=_0x39b478['creator']||null,this['authors']=_0x39b478['authors']||[],this['diffData']=_0x39b478['diffData']||null,this['toVersion']=_0x39b478['toVersion']||0x0,this['fromVersion']=_0x39b478['fromVersion']||0x0,this['set']('name',_0x39b478['name']||''),this['set']('createdAt',_0x39b478['createdAt']||new Date()),this['set']('attributes',_0x39b478['attributes']||{});}['setName'](_0x13d754){this['_update']({'name':_0x13d754});}['setAttribute'](_0x4776dd,_0xa04512){const _0x2c3871=_0x40ea9a(this['attributes']);_0x3cff0f(_0x2c3871,_0x4776dd,_0xa04512),this['_update']({'attributes':_0x2c3871});}['removeAttribute'](_0x45a39c){const _0x50f2af=_0x40ea9a(this['attributes']);_0x499e91(_0x50f2af,_0x45a39c),this['_update']({'attributes':_0x50f2af});}['_update'](_0x2fe6e9,_0x1fcc43=!0x1){let _0x55c8ba=!0x1;const _0x5510d1={'id':this['id']},_0x54ac3b=['name','createdAt','diffData','authors','attributes','toVersion','fromVersion','creatorId'];for(const _0x531888 of _0x54ac3b){const _0x146589=_0x2fe6e9[_0x531888];void 0x0!==_0x146589&&_0x146589!==this[_0x531888]&&(this[_0x531888]=_0x146589,_0x5510d1[_0x531888]=_0x146589,_0x55c8ba=!0x0);}_0x55c8ba&&(_0x5510d1['authors']&&(_0x5510d1['authorsIds']=_0x5510d1['authors']['map'](_0x35aa61=>_0x35aa61['id']),delete _0x5510d1['authors']),this['fire']('_update',_0x5510d1,_0x1fcc43));}['toJSON'](){return{'id':this['id'],'name':this['name'],'creatorId':this['creator']?this['creator']['id']:null,'authorsIds':this['authors']['map'](_0x2c251c=>_0x2c251c['id']),'diffData':this['diffData'],'createdAt':this['createdAt'],'attributes':this['attributes'],'fromVersion':this['fromVersion'],'toVersion':this['toVersion']};}}class I extends _0x443a46{['_revisions'];static get['requires'](){return[_0x33d7db];}static get['pluginName'](){return'RevisionsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['length'](){return this['_revisions']['length'];}constructor(_0xd0fe2c){super(_0xd0fe2c),this['_revisions']=new _0x239345();}['afterInit'](){!async function(_0x22be14){const _0x2da73c=_0x27acd9([0x4b,0x6e,0x79,0x52,0x4a,0x6b,0x4d,0x54,0x49,0x4e,0x50,0x41,0x77,0x75,0x51,0x70,0x42,0x47,0x33,0x61,0x71,0x38,0x32,0x68,0x58,0x59,0x66,0x37,0x30,0x36,0x6a,0x57,0x43,0x44,0x53,0x46,0x56,0x7a,0x55,0x78,0x31,0x4f,0x64,0x35,0x6f,0x45,0x69,0x72,0x48,0x74,0x4c,0x5a,0x65,0x63,0x62,0x34,0x67,0x73,0x39,0x76,0x6d,0x6c]),_0x4689aa=0xeb829,_0x422992=0x66ba9dbe,_0x4c7940=0x66bdf62e^_0x422992,_0x4288f7=window[_0x27acd9([0x44,0x61,0x74,0x65])][_0x27acd9([0x6e,0x6f,0x77])](),_0x539bf9=_0x22be14[_0x27acd9([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x300aa7=new window[(_0x27acd9([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x20875b=>{_0x539bf9[_0x27acd9([0x6f,0x6e,0x63,0x65])](_0x27acd9([0x72,0x65,0x61,0x64,0x79]),_0x20875b);}),_0x20c486={[_0x27acd9([0x6b,0x74,0x79])]:_0x27acd9([0x45,0x43]),[_0x27acd9([0x75,0x73,0x65])]:_0x27acd9([0x73,0x69,0x67]),[_0x27acd9([0x63,0x72,0x76])]:_0x27acd9([0x50,0x2d,0x32,0x35,0x36]),[_0x27acd9([0x78])]:_0x27acd9([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]),[_0x27acd9([0x79])]:_0x27acd9([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]),[_0x27acd9([0x61,0x6c,0x67])]:_0x27acd9([0x45,0x53,0x32,0x35,0x36])},_0x524060=_0x539bf9[_0x27acd9([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x27acd9([0x67,0x65,0x74])](_0x27acd9([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x2cbe56(){let _0x56b479,_0xe7e4da=null,_0x4314f5=null;try{if(_0x524060==_0x27acd9([0x47,0x50,0x4c]))return _0x27acd9([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x56b479=_0x261440(),!_0x56b479)return _0x27acd9([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x56b479[_0x27acd9([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x4314f5=_0x2fcc64(_0x56b479[_0x27acd9([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x56b479[_0x27acd9([0x6a,0x74,0x69])])),await _0x600cb5()?_0x5cb2d1()?_0x24d2ef()?_0x27acd9([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x178791()?(_0x56b479[_0x27acd9([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x27acd9([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0xe7e4da=_0x498f87(_0x27acd9([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x56b479[_0x27acd9([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x27acd9([0x74,0x72,0x69,0x61,0x6c])&&(_0xe7e4da=_0x498f87(_0x27acd9([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),await _0x15f110()):_0x27acd9([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x27acd9([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x27acd9([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch{return _0x27acd9([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x24d2ef(){const _0x265682=[_0x27acd9([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x27acd9([0x74,0x72,0x69,0x61,0x6c])][_0x27acd9([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x56b479[_0x27acd9([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x4288f7/0x3e8:0xe10*_0x4c7940;return _0x56b479[_0x27acd9([0x65,0x78,0x70])]<_0x265682;}function _0x5cb2d1(){const _0x1ac330=_0x56b479[_0x27acd9([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x1ac330)return!0x1;if(_0x1ac330[_0x27acd9([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x27acd9([0x2a])))return!0x0;if(_0x1ac330[_0x27acd9([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x27acd9([0x52,0x48])))return!0x0;if(_0x1ac330[_0x27acd9([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x27acd9([0x52,0x52,0x48]))){if(_0x3f944d())return!0x0;if(_0x1a35f8()||_0x1280d4())return!0x0;}return!0x1;}function _0x178791(){const _0x3f606b=_0x56b479[_0x27acd9([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x3f606b||0x0==_0x3f606b[_0x27acd9([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0xf770c8}=new URL(window[_0x27acd9([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x3f606b[_0x27acd9([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0xf770c8))return!0x0;const _0x3c6fc6=_0xf770c8[_0x27acd9([0x73,0x70,0x6c,0x69,0x74])](_0x27acd9([0x2e]));return _0x3f606b[_0x27acd9([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x4bcdfe=>_0x4bcdfe[_0x27acd9([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x27acd9([0x2a])))[_0x27acd9([0x6d,0x61,0x70])](_0x2e48fe=>_0x2e48fe[_0x27acd9([0x73,0x70,0x6c,0x69,0x74])](_0x27acd9([0x2e])))[_0x27acd9([0x66,0x69,0x6c,0x74,0x65,0x72])](_0xa87b8c=>_0xa87b8c[_0x27acd9([0x6c,0x65,0x6e,0x67,0x74,0x68])]<=_0x3c6fc6[_0x27acd9([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x27acd9([0x6d,0x61,0x70])](_0x482aca=>Array(_0x3c6fc6[_0x27acd9([0x6c,0x65,0x6e,0x67,0x74,0x68])]-_0x482aca[_0x27acd9([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x27acd9([0x66,0x69,0x6c,0x6c])](_0x482aca[0x0]===_0x27acd9([0x2a])?_0x27acd9([0x2a]):'')[_0x27acd9([0x63,0x6f,0x6e,0x63,0x61,0x74])](_0x482aca))[_0x27acd9([0x73,0x6f,0x6d,0x65])](_0x5c9377=>_0x3c6fc6[_0x27acd9([0x65,0x76,0x65,0x72,0x79])]((_0x5a60be,_0x2bd812)=>_0x5c9377[_0x2bd812]===_0x5a60be||_0x5c9377[_0x2bd812]===_0x27acd9([0x2a])));}function _0x15f110(){return _0xe7e4da&&_0x4314f5?new window[(_0x27acd9([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x4a3585,_0x5a6b9a)=>{_0xe7e4da[_0x27acd9([0x74,0x68,0x65,0x6e])](_0x4a3585,_0x5a6b9a),_0x4314f5[_0x27acd9([0x74,0x68,0x65,0x6e])](_0x55aab7=>{_0x55aab7!=_0x27acd9([0x56,0x61,0x6c,0x69,0x64])&&_0x4a3585(_0x55aab7);},_0x5a6b9a);}):_0xe7e4da||_0x4314f5||_0x27acd9([0x56,0x61,0x6c,0x69,0x64]);}}function _0x2fcc64(_0x160de4,_0x34145a){return new window[(_0x27acd9([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x2149d6=>{if(_0x58daf4())return _0x2149d6(_0x27acd9([0x56,0x61,0x6c,0x69,0x64]));_0x88955f(),_0x539bf9[_0x27acd9([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x27acd9([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x3c66d9=!0x1;const _0x312edf=_0x2a1139();function _0x42b7e4(_0x282498){return!!_0x282498&&(typeof _0x282498===_0x27acd9([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x282498===_0x27acd9([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x282498[_0x27acd9([0x74,0x68,0x65,0x6e])]===_0x27acd9([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x282498[_0x27acd9([0x63,0x61,0x74,0x63,0x68])]===_0x27acd9([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x11a3f8(_0x588b03){_0x10b8c4(_0x588b03)[_0x27acd9([0x74,0x68,0x65,0x6e])](_0x3aaa28=>{if(!_0x3aaa28||_0x3aaa28[_0x27acd9([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x27acd9([0x6f,0x6b]))return _0x27acd9([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0xe40fb(_0x255ab8(_0x312edf+_0x34145a))!=_0x3aaa28[_0x27acd9([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x27acd9([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x27acd9([0x56,0x61,0x6c,0x69,0x64]);})[_0x27acd9([0x74,0x68,0x65,0x6e])](_0xb2ec8c=>(_0x1fa8c9(),_0xb2ec8c),()=>{const _0x192f55=_0x4e8b27();return null==_0x192f55?(_0x1fa8c9(),_0x27acd9([0x56,0x61,0x6c,0x69,0x64])):_0x27acd9(_0x4288f7-_0x192f55>(0x42b619be^_0x422992)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x27acd9([0x74,0x68,0x65,0x6e])](_0x2149d6)[_0x27acd9([0x63,0x61,0x74,0x63,0x68])](()=>{_0x2149d6(_0x27acd9([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x2cbe47=0x668c733e^_0x422992;function _0x1fa8c9(){const _0x21b725=_0x27acd9([0x6c,0x6c,0x63,0x74,0x2d])+_0xe40fb(_0x255ab8(_0x160de4)),_0x1c07f1=_0x999d34(_0xe40fb(window[_0x27acd9([0x4d,0x61,0x74,0x68])][_0x27acd9([0x63,0x65,0x69,0x6c])](_0x4288f7/_0x2cbe47)));window[_0x27acd9([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x27acd9([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x21b725,_0x1c07f1);}function _0x4e8b27(){const _0x938a18=_0x27acd9([0x6c,0x6c,0x63,0x74,0x2d])+_0xe40fb(_0x255ab8(_0x160de4)),_0x48b180=window[_0x27acd9([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x27acd9([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x938a18);return _0x48b180?window[_0x27acd9([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x999d34(_0x48b180),0x10)*_0x2cbe47:null;}function _0x10b8c4(_0x3171b5){return new window[(_0x27acd9([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x5489f0,_0x4d515d)=>{_0x3171b5[_0x27acd9([0x74,0x68,0x65,0x6e])](_0x5489f0,_0x4d515d),window[_0x27acd9([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x4d515d,0x66bb497e^_0x422992);});}}_0x539bf9[_0x27acd9([0x6f,0x6e])](_0x27acd9([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x4480fc,_0x2ff125)=>{if(_0x2ff125[0x0]!=_0x160de4)return _0x2149d6(_0x27acd9([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x2ff125[0x1]={..._0x2ff125[0x1],[_0x27acd9([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x312edf};},{[_0x27acd9([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x27acd9([0x68,0x69,0x67,0x68])}),_0x539bf9[_0x27acd9([0x6f,0x6e])](_0x27acd9([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x215ffe=>{_0x42b7e4(_0x215ffe[_0x27acd9([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x3c66d9=!0x0,_0x11a3f8(_0x215ffe[_0x27acd9([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x27acd9([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x27acd9([0x6c,0x6f,0x77])}),_0x300aa7[_0x27acd9([0x74,0x68,0x65,0x6e])](()=>{_0x3c66d9||_0x2149d6(_0x27acd9([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x58daf4(){return _0x539bf9[_0x27acd9([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x27acd9([0x76,0x69,0x65,0x77])][_0x27acd9([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x27acd9([0x61,0x75,0x74,0x6f]);}function _0x88955f(){_0x539bf9[_0x27acd9([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x27acd9([0x76,0x69,0x65,0x77])][_0x27acd9([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x27acd9([0x61,0x75,0x74,0x6f]);}}function _0x498f87(_0x53d5f1){const _0x3dbec6=[new window[(_0x27acd9([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x85a961=>setTimeout(_0x85a961,0x66b3a372^_0x422992)),_0x300aa7[_0x27acd9([0x74,0x68,0x65,0x6e])](()=>new window[(_0x27acd9([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x54ee08=>{const _0x5e8102=0x66ba9db9^_0x422992,_0x2d4a42=_0x22be14[_0x27acd9([0x5f,0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x73])];function _0xbb5a4(){_0x2d4a42[_0x27acd9([0x6c,0x65,0x6e,0x67,0x74,0x68])]>=_0x5e8102&&_0x54ee08();}_0xbb5a4(),_0x2d4a42[_0x27acd9([0x6f,0x6e])](_0x27acd9([0x61,0x64,0x64]),_0xbb5a4);})),new window[(_0x27acd9([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x52b1cc=>{function _0x648958(){for(const _0x103bef in window)if(window[_0x27acd9([0x4e,0x75,0x6d,0x62,0x65,0x72])]['isNaN'](window[_0x27acd9([0x4e,0x75,0x6d,0x62,0x65,0x72])](_0x103bef))&&window[_0x103bef]==_0x4689aa)return _0x52b1cc();_0x539bf9[_0x27acd9([0x73,0x74,0x61,0x74,0x65])]!=_0x27acd9([0x64,0x65,0x73,0x74,0x72,0x6f,0x79,0x65,0x64])&&window[_0x27acd9([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x648958,0x66ba8e36^_0x422992);}_0x2a845e(_0x27acd9([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))&&_0x648958();})];return window[_0x27acd9([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x27acd9([0x72,0x61,0x63,0x65])](_0x3dbec6)[_0x27acd9([0x74,0x68,0x65,0x6e])](()=>_0x53d5f1);}async function _0x544278(){if(await _0x300aa7,_0x2a845e(_0x27acd9([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))){const _0x22e11c=_0x22be14[_0x27acd9([0x67,0x65,0x74,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](0x0),_0x38bfab=_0x22be14[_0x27acd9([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])](_0x22e11c[_0x27acd9([0x69,0x64])]),_0x1f9669=_0x290696(_0x27acd9([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]));return await _0x1f9669[_0x27acd9([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])](_0x22e11c['id'],_0x38bfab?_0x38bfab['id']:null,!0x0),_0x1f9669[_0x27acd9([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x27acd9([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x1f9669[_0x27acd9([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x1f9669[_0x27acd9([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])]=_0x5c9f17,void(_0x1f9669[_0x27acd9([0x5f,0x67,0x65,0x74,0x44,0x69,0x66,0x66])]=_0x5c9f17);}if(_0x2a845e(_0x27acd9([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]))){const _0x171543=_0x290696(_0x27acd9([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]));_0x171543[_0x27acd9([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x27acd9([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x171543[_0x27acd9([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x171543[_0x27acd9([0x75,0x70,0x64,0x61,0x74,0x65])]=_0x5c9f17,_0x171543[_0x27acd9([0x73,0x61,0x76,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])]=_0x5c9f17;}_0x539bf9[_0x27acd9([0x6d,0x6f,0x64,0x65,0x6c])][_0x27acd9([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x5c9f17,_0x539bf9[_0x27acd9([0x6d,0x6f,0x64,0x65,0x6c])][_0x27acd9([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x5c9f17,_0x539bf9[_0x27acd9([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x27acd9([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x3f944d(){return _0x2a845e(_0x27acd9([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x290696(_0x27acd9([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x27acd9([0x73,0x74,0x61,0x74,0x65])]==_0x27acd9([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x1a35f8(){return _0x2a845e(_0x27acd9([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 _0x1280d4(){return _0x2a845e(_0x27acd9([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0x3e7655(_0x3dec3b){const _0x8e92e2=_0x510660();_0x539bf9[_0x8e92e2]=_0x27acd9([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])+_0x3dec3b,_0x3dec3b[_0x27acd9([0x65,0x6e,0x64,0x73,0x57,0x69,0x74,0x68])](_0x27acd9([0x4c,0x69,0x6d,0x69,0x74]))&&(window[_0x510660()]=_0x4689aa),_0x3dec3b!=_0x27acd9([0x56,0x61,0x6c,0x69,0x64])&&_0x544278();}function _0x510660(){const _0x1699ca=window[_0x27acd9([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x27acd9([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x27acd9([0x6e,0x6f,0x77])]())[_0x27acd9([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x27acd9([0x2e]),'');let _0x3da837=_0x27acd9([0x4b]);for(let _0x43cfbf=0x0;_0x43cfbf<_0x1699ca[_0x27acd9([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x43cfbf+=0x2){let _0x4c9504=window[_0x27acd9([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x1699ca[_0x27acd9([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x43cfbf,_0x43cfbf+0x2));_0x4c9504>=_0x2da73c[_0x27acd9([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x4c9504-=_0x2da73c[_0x27acd9([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x3da837+=_0x2da73c[_0x4c9504];}return _0x3da837;}function _0x261440(){const _0x50a954=_0x524060[_0x27acd9([0x73,0x70,0x6c,0x69,0x74])](_0x27acd9([0x2e]));if(0x3!=_0x50a954[_0x27acd9([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x19be2d(_0x50a954[0x1]);function _0x19be2d(_0x13a60d){const _0x57ab2d=_0x3f79b0(_0x13a60d);return _0x57ab2d&&_0x2501ed()?_0x57ab2d:null;function _0x2501ed(){const _0x458bc8=_0x57ab2d[_0x27acd9([0x6a,0x74,0x69])],_0x279d51=window[_0x27acd9([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x458bc8[_0x27acd9([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x458bc8[_0x27acd9([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x5eef4d={..._0x57ab2d,[_0x27acd9([0x6a,0x74,0x69])]:_0x458bc8[_0x27acd9([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x458bc8[_0x27acd9([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x5eef4d[_0x27acd9([0x76,0x63])],_0x255ab8(_0x5eef4d)==_0x279d51;}}}async function _0x600cb5(){let _0x5856a8=!0x0;try{const _0x2c9ffe=_0x524060[_0x27acd9([0x73,0x70,0x6c,0x69,0x74])](_0x27acd9([0x2e])),[_0x4d4b04,_0x33d8f6,_0x33cc72]=_0x2c9ffe;return _0x35f6eb(_0x4d4b04),await _0x1010e8(_0x4d4b04,_0x33d8f6,_0x33cc72),_0x5856a8;}catch{return!0x1;}function _0x35f6eb(_0x3ae3fc){const _0x195009=_0x3f79b0(_0x3ae3fc);_0x195009&&_0x195009[_0x27acd9([0x61,0x6c,0x67])]==_0x27acd9([0x45,0x53,0x32,0x35,0x36])||(_0x5856a8=!0x1);}async function _0x1010e8(_0x1c62ae,_0x11ab0d,_0x44312d){const _0x363279=window[_0x27acd9([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x27acd9([0x66,0x72,0x6f,0x6d])](_0x2f1927(_0x44312d),_0x522f9e=>_0x522f9e[_0x27acd9([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x36f15e=new window[(_0x27acd9([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x27acd9([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x1c62ae+_0x27acd9([0x2e])+_0x11ab0d),_0x372dcb=window[_0x27acd9([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x27acd9([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x372dcb)return;const _0x509d01=await _0x372dcb[_0x27acd9([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x27acd9([0x6a,0x77,0x6b]),_0x20c486,{[_0x27acd9([0x6e,0x61,0x6d,0x65])]:_0x27acd9([0x45,0x43,0x44,0x53,0x41]),[_0x27acd9([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x27acd9([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x27acd9([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x372dcb[_0x27acd9([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x27acd9([0x6e,0x61,0x6d,0x65])]:_0x27acd9([0x45,0x43,0x44,0x53,0x41]),[_0x27acd9([0x68,0x61,0x73,0x68])]:{[_0x27acd9([0x6e,0x61,0x6d,0x65])]:_0x27acd9([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x509d01,_0x363279,_0x36f15e)||(_0x5856a8=!0x1);}}function _0x3f79b0(_0x2e264c){return _0x2e264c[_0x27acd9([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x27acd9([0x65,0x79]))?JSON[_0x27acd9([0x70,0x61,0x72,0x73,0x65])](_0x2f1927(_0x2e264c)):null;}function _0x2f1927(_0xe5926b){return window[_0x27acd9([0x61,0x74,0x6f,0x62])](_0xe5926b[_0x27acd9([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x27acd9([0x2b]))[_0x27acd9([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x27acd9([0x2f])));}function _0x255ab8(_0x590469){let _0x4f9d4a=0x1505;function _0x564328(_0x56b6dd){for(let _0x5c3fa0=0x0;_0x5c3fa0<_0x56b6dd[_0x27acd9([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x5c3fa0++){const _0x25a1bd=_0x56b6dd[_0x27acd9([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x5c3fa0);_0x4f9d4a=(_0x4f9d4a<<0x5)+_0x4f9d4a+_0x25a1bd,_0x4f9d4a&=_0x4f9d4a;}}function _0x5a3d45(_0x2e70ab){Array[_0x27acd9([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x2e70ab)?_0x2e70ab[_0x27acd9([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x5a3d45):_0x2e70ab&&typeof _0x2e70ab==_0x27acd9([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x27acd9([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x2e70ab)[_0x27acd9([0x73,0x6f,0x72,0x74])]()[_0x27acd9([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x25603d,_0x3b1642])=>{_0x564328(_0x25603d),_0x5a3d45(_0x3b1642);}):_0x564328(window[_0x27acd9([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x2e70ab));}return _0x5a3d45(_0x590469),_0x4f9d4a>>>0x0;}function _0xe40fb(_0x4ea7e3){return _0x4ea7e3[_0x27acd9([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x27acd9([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x27acd9([0x30]));}function _0x999d34(_0x33678f){return _0x33678f[_0x27acd9([0x73,0x70,0x6c,0x69,0x74])]('')[_0x27acd9([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x27acd9([0x6a,0x6f,0x69,0x6e])]('');}function _0x2a845e(_0x7a2ffd){return _0x539bf9[_0x27acd9([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x27acd9([0x68,0x61,0x73])](_0x7a2ffd);}function _0x290696(_0x325332){return _0x539bf9[_0x27acd9([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x27acd9([0x67,0x65,0x74])](_0x325332);}function _0x5c9f17(){}function _0x27acd9(_0x52b28e){return _0x52b28e['map'](_0x479cba=>String['fromCharCode'](_0x479cba))['join']('');}_0x3e7655(await _0x2cbe56());}(this);}['createRevision'](_0x89a6a0){const _0x13f830=this['editor']['plugins']['get']('Users');return new h({'id':_0x89a6a0['id'],'name':_0x89a6a0['name'],'creator':_0x89a6a0['creatorId']?_0x13f830['getUser'](_0x89a6a0['creatorId']):null,'diffData':_0x89a6a0['diffData']||_0x89a6a0['data'],'authors':_0x89a6a0['authorsIds']['map'](_0x2d8121=>_0x13f830['getUser'](_0x2d8121)),'createdAt':new Date(_0x89a6a0['createdAt']),'attributes':_0x89a6a0['attributes'],'fromVersion':_0x89a6a0['fromVersion'],'toVersion':_0x89a6a0['toVersion']});}['addRevision'](_0x497f4b,_0x778e60=0x0){this['_revisions']['add'](_0x497f4b,_0x778e60);}['getRevision'](_0x275665){return this['_revisions']['get'](_0x275665);}['getRevisions'](_0x15dd41={'toJSON':!0x1}){const _0x42b34b=Array['from'](this['_revisions']);return _0x42b34b['reverse'](),_0x15dd41['toJSON']?_0x42b34b['map'](_0x371fee=>_0x371fee['toJSON']()):_0x42b34b;}['getIndex'](_0x9c4414){return this['_revisions']['getIndex'](_0x9c4414);}['getEarlierVisibleRevision'](_0x313f66){const [,_0x58fa8c]=this['getRevisionsIterator'](_0x313f66,{'direction':'earlier'});return _0x58fa8c;}['getLaterVisibleRevision'](_0x2b2ade){const [,_0x1049b7]=this['getRevisionsIterator'](_0x2b2ade,{'direction':'later'});return _0x1049b7;}['getRevisionsInDiff'](_0x42a5bc){const _0x3bec9f=[];for(const _0x112e85 of this['getRevisionsIterator'](_0x42a5bc['newRevisionId']))if(_0x3bec9f['push'](_0x112e85),_0x112e85['id']===_0x42a5bc['oldRevisionId'])break;return _0x3bec9f;}*['getRevisionsIterator'](_0x28e11e,{direction:_0x478a44='earlier',filter:_0x473707=()=>!0x0}={}){const _0xe5d7c7='earlier'===_0x478a44?0x1:-0x1;let _0x33cb63=this['_revisions']['get'](_0x28e11e),_0x5c52b0=this['getIndex'](_0x33cb63);for(yield _0x33cb63;_0x33cb63;){if(_0x5c52b0+=_0xe5d7c7,_0x33cb63=this['getRevision'](_0x5c52b0),!_0x33cb63)return;_0x473707(_0x33cb63)&&(yield _0x33cb63);}}}class V extends _0x443a46{static get['pluginName'](){return'RevisionHistoryUtils';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['_viewClassToTypeChar']=new Map([[_0x20d04c,'c'],[_0x5550f8,'a'],[_0x415b23,'e'],[_0x161449,'r'],[_0x3188b4,'u']]);['_typeCharToViewClass']=new Map([['c',_0x20d04c],['a',_0x5550f8],['e',_0x415b23],['r',_0x161449],['u',_0x3188b4]]);async['loadRevisionData'](_0x476a63,_0xb1ea6){if(_0x476a63['diffData']||!_0xb1ea6)return;const _0x4a5c90=this['editor']['config']['get']('collaboration.channelId'),_0x5ad81f=await _0xb1ea6['getRevision']({'channelId':_0x4a5c90,'revisionId':_0x476a63['id']});_0x476a63['diffData']=_0x5ad81f['diffData'];}['getRevisionDocumentData'](_0x4c6682){const _0x516cba={};for(const _0x2b65b6 in _0x4c6682['diffData']){if(_0x4c6682['diffData'][_0x2b65b6]['attachChange']&&!_0x4c6682['diffData'][_0x2b65b6]['attachChange']['isAttached'])continue;const _0x5e205c=this['_removeRevisionMarkers'](JSON['parse'](_0x4c6682['diffData'][_0x2b65b6]['insertions'])),_0x51c56=this['editor']['editing']['view']['document'],_0x3c14bb=new _0x3a3b7a(_0x51c56,_0x5e205c['map'](_0x4fd575=>this['_getViewFromDiffObj'](_0x4fd575,!0x1)));this['editor']['data']['processor']['useFillerType']('marked'),_0x516cba[_0x2b65b6]=this['editor']['data']['processor']['toData'](_0x3c14bb),this['editor']['data']['processor']['useFillerType']('default');}return _0x516cba;}['getRevisionRootsAttributes'](_0x21d544){const _0x36fbb8={};for(const _0x332db7 in _0x21d544['diffData'])_0x21d544['diffData'][_0x332db7]['attachChange']&&!_0x21d544['diffData'][_0x332db7]['attachChange']['isAttached']||(_0x36fbb8[_0x332db7]=_0x21d544['diffData'][_0x332db7]['attributesAfter']||{});return _0x36fbb8;}['_getTypeCharForViewElement'](_0xef4014){return this['_viewClassToTypeChar']['get'](_0xef4014['constructor']);}['_getViewFromDiffObj'](_0x2fe046,_0x53a460){const _0xb23dda=this['editor']['editing']['view']['document'];if('string'==typeof _0x2fe046)return new _0x255c11(_0xb23dda,_0x2fe046);{let _0x4f762f,_0x34777c;_0x34777c='u'==_0x2fe046['type']||'r'==_0x2fe046['type']?[]:_0x2fe046['children']['map'](_0x464531=>this['_getViewFromDiffObj'](_0x464531,_0x53a460));const _0x5152a6=this['_typeCharToViewClass']['get'](_0x2fe046['type'])||_0x1eabbf,_0x54d747=this['editor']['data']['htmlProcessor']['domConverter'];if(_0x4f762f=new _0x5152a6(_0xb23dda,_0x2fe046['name'],_0x2fe046['attributes'],_0x34777c),'u'==_0x2fe046['type']&&_0x2fe046['children'][0x0]){const _0x432b49=_0x2fe046['children'][0x0];if(_0x4f762f['render']=function(_0x5b9d85){const _0x15ae9a=_0x5b9d85['createElement']('div');return _0x15ae9a['innerHTML']=_0x432b49,_0x15ae9a['childNodes'][0x0];},_0x53a460){const _0x40bf2a=new _0x3a3b7a(_0xb23dda);_0x40bf2a['_appendChild'](_0x4f762f);const _0xc71174=Array['from'](_0x54d747['viewChildrenToDom'](_0x40bf2a,{'bind':!0x1})),_0x5e0943=_0x54d747['domDocument']['createElement']('div');_0x5e0943['append'](..._0xc71174),_0x4f762f=Array['from'](_0x54d747['domChildrenToView'](_0x5e0943))[0x0];}}else{if('r'==_0x2fe046['type']&&_0x2fe046['children'][0x0]){const _0x32c624=_0x2fe046['children'][0x0];if(_0x4f762f['render']=function(_0x249b65){_0x249b65['innerHTML']=_0x32c624;},_0x53a460){const _0x29c23f=new _0x3a3b7a(_0xb23dda);_0x29c23f['_appendChild'](_0x4f762f);const _0x47820f=Array['from'](_0x54d747['viewChildrenToDom'](_0x29c23f,{'bind':!0x1})),_0x22710e=_0x54d747['domDocument']['createElement']('div');_0x22710e['append'](..._0x47820f);const _0x49784c=Array['from'](_0x54d747['domChildrenToView'](_0x22710e));_0x49784c['length']>0x1?_0x4f762f['_appendChild'](_0x49784c):_0x4f762f=_0x49784c[0x0];}}}if(_0x2fe046['customProperties']){for(const [_0x279f94,_0x5d8275]of _0x2fe046['customProperties'])_0x4f762f['_setCustomProperty'](_0x279f94,_0x5d8275);}const _0x30411a=void 0x0===_0x2fe046['fillerOffset']?null:_0x2fe046['fillerOffset'];return null!==_0x30411a&&(_0x4f762f['getFillerOffset']=()=>_0x30411a),_0x4f762f;}}['_makeModelFromViewString'](_0x5f4f74){const _0x2032ea=JSON['parse'](_0x5f4f74),_0x835495=this['editor']['editing']['view']['document'],_0x36b286=new _0x3a3b7a(_0x835495,_0x2032ea['map'](_0x3b4a06=>this['_getViewFromDiffObj'](_0x3b4a06,!0x0)));return this['editor']['data']['toModel'](_0x36b286);}['_removeRevisionMarkers'](_0x276017){return(_0x276017=_0x276017['filter'](_0xee8aeb=>!_0xee8aeb['name']||'revision-start'!==_0xee8aeb['name']&&'revision-end'!==_0xee8aeb['name']))['forEach'](_0x44d704=>{'string'!=typeof _0x44d704&&(_0x44d704['children']=this['_removeRevisionMarkers'](_0x44d704['children']),_0x44d704['attributes']=_0x44d704['attributes']['filter'](_0x3f06fa=>!_0x3f06fa[0x0]['startsWith']('data-revision-')));}),_0x276017;}}function g(_0x594987,_0x1b58ed,_0x1218f7){const t=_0x594987['t'];switch(_0x1b58ed){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'},_0x1218f7);case'X_OF_Y_CHANGES':return t({'string':'%0\x20of\x20%1','id':'X_OF_Y_CHANGES'},_0x1218f7);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 u extends _0x443a46{['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[_0x33d7db,I,V,_0x41643f];}constructor(_0x1070ae){super(_0x1070ae),this['repository']=this['editor']['plugins']['get']('RevisionsRepository'),this['_utils']=this['editor']['plugins']['get']('RevisionHistoryUtils'),this['_revisionDataBuilder']=new x(this['editor']),this['_initialRevisionId']=this['editor']['config']['get']('collaboration.channelId')||'initial',this['_bufferedUpdates']=new Map(),this['_loadedStateData']=null;const _0x531d82=_0x2a1139();this['_source']={'history':this['editor']['model']['document']['history'],'getLatestVersion':()=>Promise['resolve'](this['editor']['model']['document']['version']),'getCurrentRevisionId':()=>_0x531d82},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 _0x1781fb=this['repository']['getRevision'](0x0),_0x114023=_0x1781fb&&null===_0x1781fb['creator']?_0x1781fb:null;if(this['_continueCurrentRevision']=!!_0x114023&&this['editor']['config']['get']('revisionHistory.resumeUnsavedRevision'),this['editor']['plugins']['has']('RealTimeCollaborationClient')){const _0x37a83e=this['_source']['getCurrentRevisionId'](),_0x146a29=this['repository']['getRevision'](_0x37a83e);if(_0x146a29)this['_startingVersion']=_0x146a29['fromVersion'],this['_continueCurrentRevision']=!0x1;else{const _0xa237a1=this['_source']['history']['_operations']['find'](_0x25bbd3=>!_0x25bbd3['_isInit']),_0x4ef84d=_0xa237a1?_0xa237a1['baseVersion']:this['_source']['history']['version'];_0x1781fb?(_0x1781fb['toVersion']<_0x4ef84d&&_0x1781fb['_update']({'toVersion':_0x4ef84d}),this['_continueCurrentRevision']?(this['_source']['getCurrentRevisionId']=()=>_0x114023['id'],this['_startingVersion']=_0x114023['fromVersion']):(this['_startingVersion']=_0x1781fb['toVersion'],this['_continueCurrentRevision']=!0x1)):(this['_startingVersion']=_0x4ef84d,this['_continueCurrentRevision']=!0x1);}}else _0x114023&&(this['editor']['model']['document']['history']['version']=Math['max'](_0x114023['toVersion'],this['editor']['model']['document']['history']['version']),_0x114023['fromVersion']===_0x114023['toVersion']?(0x0!==_0x114023['fromVersion']&&(this['_source']['getCurrentRevisionId']=()=>_0x114023['id']),this['_continueCurrentRevision']=!0x1):this['_continueCurrentRevision']&&(this['_source']['getCurrentRevisionId']=()=>_0x114023['id'],this['_startingVersion']=_0x114023['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',_0x236b00=>!_0x236b00),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x3a1390=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x19b90f;for(const _0x4ce40b in _0x3a1390){const _0x3eea1a=_0x4ce40b,_0x4254fe=_0x3a1390[_0x3eea1a];if('revisionHistoryLicenseKeyValid'==_0x4254fe||'revisionHistoryLicenseKeyInvalid'==_0x4254fe||'revisionHistoryLicenseKeyExpired'==_0x4254fe||'revisionHistoryLicenseKeyDomainLimit'==_0x4254fe||'revisionHistoryLicenseKeyNotAllowed'==_0x4254fe||'revisionHistoryLicenseKeyEvaluationLimit'==_0x4254fe||'revisionHistoryLicenseKeyTrialLimit'==_0x4254fe||'revisionHistoryLicenseKeyUsageLimit'==_0x4254fe){delete _0x3a1390[_0x3eea1a],_0x19b90f=_0x4254fe,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'revisionHistoryLicenseKeyInvalid'==_0x19b90f&&_0x3a1390['_showLicenseError']('invalid'),'revisionHistoryLicenseKeyExpired'==_0x19b90f&&_0x3a1390['_showLicenseError']('expired'),'revisionHistoryLicenseKeyDomainLimit'==_0x19b90f&&_0x3a1390['_showLicenseError']('domainLimit'),'revisionHistoryLicenseKeyNotAllowed'==_0x19b90f&&_0x3a1390['_showLicenseError']('featureNotAllowed','RevisionHistory'),'revisionHistoryLicenseKeyEvaluationLimit'==_0x19b90f&&_0x3a1390['_showLicenseError']('evaluationLimit'),'revisionHistoryLicenseKeyTrialLimit'==_0x19b90f&&_0x3a1390['_showLicenseError']('trialLimit'),'revisionHistoryLicenseKeyUsageLimit'==_0x19b90f&&_0x3a1390['_showLicenseError']('usageLimit');},0x3e8);}async['afterInit'](){if(this['repository']['length']>0x0){const _0x4a8f45=this['repository']['getRevision'](0x0),_0x54e9de=await this['getRevisionDocumentData'](_0x4a8f45),_0x13fbaa=await this['getRevisionRootsAttributes'](_0x4a8f45);this['_replaceEditorDataWithRevisionData'](_0x54e9de,_0x13fbaa);}}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['setSource'](_0x41d0da){this['_source']=_0x41d0da;}async['update'](){const _0x1b4b18=await this['_source']['getLatestVersion']();if(_0x1b4b18>this['currentRevision']['toVersion']){await this['_loadState']();const _0x4e178c=this['buildRevisionData']({'revision':this['currentRevision'],'to':_0x1b4b18});_0x4e178c['authors']=_0x4e178c['authorsIds']['map'](_0xfb1264=>this['editor']['plugins']['get']('Users')['getUser'](_0xfb1264)),this['currentRevision']['_update'](_0x4e178c);}}async['saveRevision'](_0x185922={},_0x318041=null){const _0x1eebaa=[];await this['_loadState'](),this['_continueCurrentRevision']=!0x1,_0x318041>this['currentRevision']['toVersion']&&(_0x318041=null),null===_0x318041&&(_0x318041=await this['_source']['getLatestVersion']());const _0x511159=this['_getFromVersion'](_0x318041),_0x5174d1=this['buildRevisionData']({'from':_0x511159,'to':_0x318041});if(this['currentRevision']['toVersion']<_0x318041){const _0x46e74b=this['buildRevisionData']({'revision':this['currentRevision'],'from':_0x318041,'to':_0x318041});_0x46e74b['authors']=[],_0x46e74b['authorsIds']=[],_0x46e74b['id']=this['currentRevision']['id'],this['currentRevision']['_update'](_0x46e74b,!0x0),delete _0x46e74b['authors'],_0x1eebaa['push'](_0x46e74b);}_0x185922['creatorId']=this['editor']['plugins']['get']('Users')['me']['id'],_0x185922['name']=_0x185922['name']||null,_0x185922['id']=_0x185922['id']||_0x2a1139(),_0x185922={..._0x185922,..._0x5174d1};const _0x2ce792=this['addRevisionData'](_0x185922);_0x1eebaa['push'](_0x185922);const _0x5b9b71=this['repository']['getIndex'](_0x2ce792);if(0x0!==_0x5b9b71){const _0x5b4292=this['repository']['getRevision'](_0x5b9b71-0x1);if(_0x5b4292['fromVersion']!==_0x318041){const _0x1212bc=this['_revisionDataBuilder']['getData'](_0x318041,_0x5b4292['toVersion']),_0x43a428={'id':_0x5b4292['id'],'diffData':_0x1212bc['diffData'],'authorsIds':_0x1212bc['authorsIds'],'authors':_0x1212bc['authorsIds']['map'](_0x779005=>this['editor']['plugins']['get']('Users')['getUser'](_0x779005)),'fromVersion':_0x318041};_0x5b4292===this['currentRevision']&&(_0x43a428['createdAt']=new Date(_0x185922['createdAt']['getTime']()+0xa)),_0x5b4292['_update'](_0x43a428,!0x0),delete _0x43a428['authors'],_0x1eebaa['push'](_0x43a428);}}if(this['adapter']){for(const _0x1208b0 of _0x1eebaa)this['_bufferUpdate'](_0x1208b0['id'],_0x1208b0,!0x0);this['sendBufferedUpdates']();}return _0x2ce792;}['addRevisionData'](_0x27c71c){const _0x5c2191=this['repository']['createRevision'](_0x27c71c);return this['adapter']&&_0x5c2191['on']('_update',(_0x413eb6,_0x3b869b,_0xb9c9a2)=>{_0xb9c9a2||(this['_bufferUpdate'](_0x3b869b['id'],_0x3b869b,!0x0),this['sendBufferedUpdates']());}),this['repository']['addRevision'](_0x5c2191,this['_findInsertionIndex'](_0x5c2191)),_0x5c2191;}async['getRevisionDocumentData'](_0x4e5f65){return await this['_utils']['loadRevisionData'](_0x4e5f65,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x4e5f65);}async['getRevisionRootsAttributes'](_0x120080){return await this['_utils']['loadRevisionData'](_0x120080,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x120080);}['sendBufferedUpdates'](){if(0x0===this['_bufferedUpdates']['size'])return;if(this['_isPendingUpdate'])return;let _0x166616=Array['from'](this['_bufferedUpdates']['values']());this['_bufferedUpdates']['clear']();for(let _0x3ff903=0x0;_0x3ff903<_0x166616['length'];_0x3ff903++){const _0x24854a=_0x166616[_0x3ff903];let _0x5b8530=!0x1;for(const _0x45b3b7 of Object['keys'](_0x24854a))void 0x0===_0x24854a[_0x45b3b7]?delete _0x24854a[_0x45b3b7]:'id'!==_0x45b3b7&&(_0x5b8530=!0x0);_0x5b8530||(_0x166616[_0x3ff903]=null);}if(_0x166616=_0x166616['filter'](_0x16ccc6=>null!==_0x16ccc6),!_0x166616['length'])return;for(let _0x4af77d=0x0;_0x4af77d<_0x166616['length'];_0x4af77d++){const _0x328426=_0x166616[_0x4af77d];void 0x0!==_0x328426['fromVersion']&&void 0x0===_0x328426['toVersion']&&(_0x328426['toVersion']=this['repository']['getRevision'](_0x328426['id'])['toVersion']),void 0x0!==_0x328426['toVersion']&&void 0x0===_0x328426['fromVersion']&&(_0x328426['fromVersion']=this['repository']['getRevision'](_0x328426['id'])['fromVersion']);}const _0x5157c0=this['editor']['config']['get']('collaboration.channelId');this['_isPendingUpdate']=!0x0,this['_addPendingAction'](),this['adapter']['updateRevisions'](_0x166616,_0x5157c0)['finally'](()=>{this['_isPendingUpdate']=!0x1;})['then'](_0x393287=>{if(_0x393287){for(const _0x4b9504 of _0x393287)this['setRevisionData']({'id':_0x4b9504['id'],'createdAt':_0x4b9504['createdAt']});}this['_removePendingAction'](),this['sendBufferedUpdates']();});}['buildRevisionData']({revision:_0x487704=null,from:_0x592f05=null,to:_0x4e5212=null}){_0x592f05=null!==_0x592f05?_0x592f05:_0x487704['fromVersion'],_0x4e5212=null!==_0x4e5212?_0x4e5212:_0x487704['toVersion'];const _0x411f68=this['_revisionDataBuilder']['getData'](_0x592f05,_0x4e5212),_0x2ba89e={'diffData':_0x411f68['diffData'],'authorsIds':_0x411f68['authorsIds'],'fromVersion':_0x592f05,'toVersion':_0x4e5212};if(!_0x487704||_0x4e5212!==_0x487704['toVersion']){const _0x30481f=_0x4e5212-0x1,_0x26eca5=this['_source']['history']['getOperation'](_0x30481f);_0x2ba89e['createdAt']=_0x26eca5&&_0x26eca5['createdAt']||new Date();}if(this['_loadedStateData']&&_0x592f05===this['_loadedStateData']['fromVersion']){for(const _0x5ea8e2 of this['_loadedStateData']['authors'])_0x2ba89e['authorsIds']['includes'](_0x5ea8e2['id'])||_0x2ba89e['authorsIds']['push'](_0x5ea8e2['id']);}return _0x2ba89e;}['_bufferUpdate'](_0x4fb96c,_0x1dc95a,_0x3200f0){if(this['_bufferedUpdates']['has'](_0x4fb96c)){const _0x54a79e=this['_bufferedUpdates']['get'](_0x4fb96c);_0x1dc95a=_0x3200f0?{..._0x54a79e,..._0x1dc95a}:{..._0x1dc95a,..._0x54a79e};}this['_bufferedUpdates']['set'](_0x4fb96c,_0x1dc95a);}['setRevisionData'](_0x20bea2){const _0x37a833=this['repository']['getRevision'](_0x20bea2['id']);if(_0x20bea2['createdAt']&&(_0x20bea2['createdAt']=new Date(_0x20bea2['createdAt'])),_0x20bea2['authorsIds']){const _0x3ea2ab=this['editor']['plugins']['get']('Users');_0x20bea2['authors']=_0x20bea2['authorsIds']['map'](_0xbba66d=>_0x3ea2ab['getUser'](_0xbba66d));}_0x37a833['_update'](_0x20bea2,!0x0);}['_createInitialRevision'](_0x371940){const _0x2d1895=this['repository']['getRevision'](this['repository']['length']-0x1);if(_0x2d1895)this['_initialRevisionId']=_0x2d1895['id'];else{const _0x1bd5da=!this['editor']['model']['document']['roots']['find'](_0x27b84e=>this['editor']['model']['hasContent'](_0x27b84e)),_0x3f960a=this['editor']['plugins']['get']('Users')['me']['id'],_0x56b027=g(this['editor']['locale'],_0x1bd5da?'Empty\x20document':'Initial\x20revision');this['_makeRevision']({'from':_0x371940,'to':_0x371940,'id':this['_initialRevisionId'],'name':_0x56b027,'creatorId':_0x3f960a});}}['_createCurrentRevision'](_0x530961){const _0x29f453=this['_source']['getCurrentRevisionId']();this['currentRevision']=this['repository']['getRevision'](_0x29f453),this['currentRevision']||(this['currentRevision']=this['_makeRevision']({'from':_0x530961,'to':_0x530961,'id':_0x29f453,'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'](_0x177ebf,_0x56f405){let _0x168c8b=this['editor']['config']['get']('initialData'),_0x5c171a=this['editor']['config']['get']('rootsAttributes');if(void 0x0===_0x168c8b){_0x168c8b={};for(const _0x401764 of this['editor']['model']['document']['getRootNames']())_0x168c8b[_0x401764]='';}if('string'==typeof _0x168c8b&&(_0x168c8b={'main':_0x168c8b}),void 0x0===_0x5c171a){_0x5c171a={};for(const _0x3b0c8a of this['editor']['model']['document']['getRootNames']())_0x5c171a[_0x3b0c8a]={};}let _0x2943ae=!0x1;const _0x3b27ea=Object['keys'](_0x168c8b),_0x340280=Object['keys'](_0x177ebf);for(const _0x5b57d6 of _0x3b27ea){if(_0x168c8b[_0x5b57d6]!==_0x177ebf[_0x5b57d6]&&''!==_0x168c8b[_0x5b57d6]['trim']()){_0x2943ae=!0x0;break;}if(!_0x1f0b3c(_0x5c171a[_0x5b57d6],_0x56f405[_0x5b57d6])&&Object['keys'](_0x5c171a[_0x5b57d6])['length']>0x0){_0x2943ae=!0x0;break;}}_0x2943ae||(_0x2943ae=_0x340280['some'](_0x187f23=>!this['editor']['model']['document']['getRoot'](_0x187f23))),_0x2943ae&&_0x1e9999('editor-initial-data-replaced-with-revision-data',{'editorData':_0x168c8b,'editorRootsAttributes':_0x5c171a,'revisionData':_0x177ebf,'revisionRootsAttributes':_0x56f405}),this['editor']['config']['set']('initialData',_0x177ebf),this['editor']['config']['set']('rootsAttributes',_0x56f405);}['_addPendingAction'](){if(!this['_pendingAction']){const _0x4a2b78=this['editor']['plugins']['get']('PendingActions');this['_pendingAction']=_0x4a2b78['add'](g(this['editor']['locale'],'PENDING_ACTION_REVISION_HISTORY'));}}['_removePendingAction'](){this['_pendingAction']&&(this['editor']['plugins']['get']('PendingActions')['remove'](this['_pendingAction']),this['_pendingAction']=null);}['_findInsertionIndex'](_0x4b0d2c){const _0xd35a4d=this['repository']['getRevisions']();_0xd35a4d['reverse']();let _0x407fcb=0x0;for(;_0x407fcb<_0xd35a4d['length'];){const _0x489180=_0xd35a4d[_0x407fcb];if(_0x489180===this['currentRevision']){_0x407fcb++;continue;}if(_0x489180['id']===this['_initialRevisionId'])break;const _0x36e93e=_0x4b0d2c['toVersion']-_0x489180['toVersion']||_0x4b0d2c['fromVersion']-_0x489180['fromVersion'];if(_0x36e93e>0x0)break;if(_0x36e93e<0x0)_0x407fcb++;else{if(!_0x4b0d2c['creator']&&_0x489180['creator'])break;if(_0x489180['creator']||!_0x4b0d2c['creator']){if(_0x4b0d2c['createdAt']>_0x489180['createdAt'])break;_0x407fcb++;}else _0x407fcb++;}}return _0x407fcb;}['_getFromVersion'](_0x4a96ea){const _0x628d60=this['repository']['getRevisions']();_0x628d60['reverse'](),_0x628d60['shift']();const _0x347207=_0x628d60['find'](_0x408f0a=>_0x408f0a['toVersion']<=_0x4a96ea)['toVersion'];return _0x347207<this['_startingVersion']?this['_startingVersion']:_0x347207;}['_makeRevision']({name:_0x587c65,from:_0x2e1b7d,to:_0x2ec30d,creatorId:_0x3c3943,id:_0x2e28ef}){const _0x5593de=this['buildRevisionData']({'from':_0x2e1b7d,'to':_0x2ec30d});_0x5593de['name']=_0x587c65,_0x5593de['creatorId']=_0x3c3943,_0x5593de['id']=_0x2e28ef;const _0xfef5e4=this['addRevisionData'](_0x5593de);return this['adapter']&&this['_bufferUpdate'](_0x5593de['id'],_0x5593de,!0x0),_0xfef5e4;}['_setConversion'](){this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'});}}class x{['editor'];['source'];['_savedMetaData'];['_lastFrom'];['_lastTo'];['_markers'];['_diffRoots'];['_diffRootsAttributes'];['_baseRoots'];['_baseRootsAttributes'];['_idsRoots'];['_baseIdsRoots'];['_touched'];['_touchedMarkers'];['_touchedRoots'];['_revisionId'];['_startingRevisionId'];constructor(_0x58e750){this['editor']=_0x58e750,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'](_0x50675c){this['source']=_0x50675c;const _0x1053c7=new Map(),_0x1d5cb4=new Map(),_0x11aa6c=this['editor']['model']['document']['roots']['map'](_0x382a7a=>_0x382a7a['rootName']);for(const _0x26456a of _0x11aa6c){const _0x45ad6f=this['editor']['model']['document']['getRoot'](_0x26456a),_0xb01981=N(_0x45ad6f);_0x1053c7['set'](_0x26456a,_0xb01981),_0x1d5cb4['set'](_0x26456a,Object['fromEntries'](_0x45ad6f['getAttributes']()));}const _0x2d7591=Array['from'](this['editor']['model']['markers'])['map'](_0x2e7e1e=>[_0x2e7e1e['name'],_0x2e7e1e['getRange']()]),_0x487d8e=this['source']['version'];this['_saveMetaData'](_0x487d8e,_0x1053c7,_0x2d7591,_0x1d5cb4),this['_startingRevisionId']=this['_revisionId'];const _0x130cc5=new Map(),_0x4277c1=new Map();for(const _0x4adfb5 of _0x11aa6c){const _0x5bd0df=P(_0x4adfb5);_0x130cc5['set'](_0x4adfb5,_0x5bd0df),_0x4277c1['set'](_0x4adfb5,{});}this['_saveMetaData'](Number['NEGATIVE_INFINITY'],_0x130cc5,[],_0x4277c1);}['getData'](_0x4f9212,_0x248b53){if(this['_lastFrom']===_0x4f9212&&this['_lastTo']<=_0x248b53)this['_savedMetaData']['size']>0x1&&this['_removeMetaData'](this['_lastTo']),this['_applyOperations'](this['_lastTo'],_0x248b53,!0x0);else{if(!this['_savedMetaData']['has'](_0x4f9212)){const _0x1489b8=this['_getPreviousFrom'](_0x4f9212);this['_calculateMetaData'](_0x1489b8,_0x4f9212,!0x1);}this['_calculateMetaData'](_0x4f9212,_0x248b53,!0x0);}return this['_lastFrom']=_0x4f9212,this['_lastTo']=_0x248b53,this['_getState']();}['loadState'](_0x4285e2){const _0x197447=this['editor']['plugins']['get']('RevisionHistoryUtils');this['_reset'](),this['_lastFrom']=_0x4285e2['fromVersion'],this['_lastTo']=_0x4285e2['toVersion'];for(const _0x17a5c5 in _0x4285e2['diffData']){const _0x553a78=_0x4285e2['diffData'][_0x17a5c5]['attachChange'],_0x4bf208=_0x40ea9a(_0x4285e2['diffData'][_0x17a5c5]['attributesBefore'])||{},_0x170c97=_0x197447['_makeModelFromViewString'](_0x4285e2['diffData'][_0x17a5c5]['deletions']);_0x170c97['rootName']=_0x17a5c5,_0x170c97['_isAttached']=!_0x553a78||!_0x553a78['isAttached'],_0x170c97['isAttached']=()=>_0x170c97['_isAttached'],this['_baseRoots']['set'](_0x17a5c5,_0x170c97),this['_baseRootsAttributes']['set'](_0x17a5c5,_0x4bf208),_0x553a78&&this['_touchedRoots']['set'](_0x17a5c5,_0x553a78);const _0x590973=this['_makeIdsRoot'](_0x170c97);this['_baseIdsRoots']['set'](_0x17a5c5,_0x590973);for(const [_0x7445bd,_0x2cd240]of _0x170c97['markers']){if(!_0x7445bd['startsWith']('revision:'))continue;const _0x3fb477=_0x7445bd['split'](':')[0x2];for(const _0x31a9db of _0x2cd240['getWalker']({'singleCharacters':!0x0})){const _0x453739=this['_getVidAttributeName'](_0x31a9db),_0x4d85f7='elementEnd'==_0x31a9db['type']?_0x31a9db['previousPosition']['path']['slice'](0x0,-0x1):_0x31a9db['previousPosition']['path'],_0x3c91c7=_0x590973['getNodeByPath'](_0x4d85f7)['getAttribute'](_0x453739);this['_touched']['set'](_0x3c91c7,{'userId':_0x3fb477});}}}this['_startingRevisionId']=this['_revisionId'];const _0x3ec50f=[...Array(this['_revisionId'])['keys']()]['slice'](0x1)['filter'](_0x7e4d9e=>!this['_touched']['has'](_0x7e4d9e));let _0x5c6b12=0x0;const _0x58bc76=new Map();for(const _0x61f1ac in _0x4285e2['diffData']){const _0x17299e=_0x4285e2['diffData'][_0x61f1ac]['attachChange'],_0x180f6e=_0x40ea9a(_0x4285e2['diffData'][_0x61f1ac]['attributesAfter'])||{},_0x2ffea8=_0x197447['_makeModelFromViewString'](_0x4285e2['diffData'][_0x61f1ac]['insertions']);_0x2ffea8['rootName']=_0x61f1ac,_0x2ffea8['_isAttached']=!_0x17299e||_0x17299e['isAttached'],_0x2ffea8['isAttached']=()=>_0x2ffea8['_isAttached'],this['_diffRoots']['set'](_0x61f1ac,_0x2ffea8),this['_diffRootsAttributes']['set'](_0x61f1ac,_0x180f6e);const _0x3172b4=this['_makeIdsRoot'](_0x2ffea8,Number['NEGATIVE_INFINITY']);this['_idsRoots']['set'](_0x61f1ac,_0x3172b4),_0x58bc76['set'](_0x61f1ac,_0x2ffea8['isAttached']()?_0x180f6e:{});for(const [_0xfb46a9,_0x29ab6f]of _0x2ffea8['markers']){if(!_0xfb46a9['startsWith']('revision:'))continue;const _0x13ec25=_0xfb46a9['split'](':')[0x2];for(const _0x267a9e of _0x29ab6f['getWalker']({'singleCharacters':!0x0})){const _0x7c3b2b=this['_getVidAttributeName'](_0x267a9e),_0x29b286=this['_revisionId']++,_0x5ee6a3='elementEnd'==_0x267a9e['type']?_0x267a9e['previousPosition']['path']['slice'](0x0,-0x1):_0x267a9e['previousPosition']['path'];_0x3172b4['getNodeByPath'](_0x5ee6a3)['_setAttribute'](_0x7c3b2b,_0x29b286),this['_touched']['set'](_0x29b286,{'userId':_0x13ec25});}}for(const _0x5408bb of this['editor']['model']['createRangeIn'](_0x2ffea8)['getWalker']({'singleCharacters':!0x0})){const _0xf63305=this['_getVidAttributeName'](_0x5408bb),_0x1fce55='elementEnd'==_0x5408bb['type']?_0x5408bb['previousPosition']['path']['slice'](0x0,-0x1):_0x5408bb['previousPosition']['path'],_0x56e7a1=_0x3172b4['getNodeByPath'](_0x1fce55);_0x56e7a1['getAttribute'](_0xf63305)>0x0||_0x56e7a1['_setAttribute'](_0xf63305,_0x3ec50f[_0x5c6b12++]);}for(const [_0x438199,_0x274f3a]of _0x2ffea8['markers'])_0x438199['startsWith']('revision:')||this['_markers']['set'](_0x438199,_0x274f3a);}const _0x61e713=P('$graveyard');this['_baseRoots']['set']('$graveyard',_0x61e713),this['_baseIdsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x61e713,0x1));const _0x4f8d05=P('$graveyard');this['_diffRoots']['set']('$graveyard',_0x4f8d05),this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x4f8d05,0x1));const _0x557ad2=Array['from'](this['_diffRoots'])['map'](([_0x2cd861,_0x17cff2])=>[_0x2cd861,N(_0x17cff2)]);this['_saveMetaData'](this['_lastTo'],_0x557ad2,this['_markers'],_0x58bc76);}['reInit'](){this['_reset'](),this['_lastFrom']=-0x1,this['_lastTo']=-0x1,this['_savedMetaData']['clear'](),this['init'](this['source']);}['_saveMetaData'](_0x1b8165,_0xbd31fd,_0xe946e0,_0x51b066){const _0x121bfc=new Map(_0xbd31fd),_0x34539d=new Map(_0x40ea9a(_0x51b066)),_0x28ac66=new Map();for(const [_0x23755c,_0x5446ba]of _0xe946e0)_0x28ac66['set'](_0x23755c,{'start':_0x5446ba['start']['clone'](),'end':_0x5446ba['end']['clone'](),'rootName':_0x5446ba['root']['rootName']});this['_savedMetaData']['set'](_0x1b8165,{'roots':_0x121bfc,'markers':_0x28ac66,'rootsAttributes':_0x34539d});}['_removeMetaData'](_0x2f1c1f){this['_savedMetaData']['delete'](_0x2f1c1f);}['_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'](_0x32baf0,_0x56eed9=null){let _0x5de769=null;_0x32baf0['is']('documentFragment')||(_0x5de769=new ut(_0x32baf0['name'],{'vid_start':null===_0x56eed9?this['_revisionId']++:_0x56eed9++}));const _0x496b48=[];for(const _0xd9fa6a of _0x32baf0['getChildren']())if(_0xd9fa6a['is']('element')){_0x496b48['push'](this['_makeIdsRoot'](_0xd9fa6a,_0x56eed9));const _0x4f610f=_0x496b48[_0x496b48['length']-0x1];null!==_0x56eed9&&(_0x56eed9=_0x4f610f['is']('element','$text')?_0x4f610f['getAttribute']('vid')+0x1:_0x4f610f['getAttribute']('vid_end')+0x1);}else{for(let _0x4f0093=0x0;_0x4f0093<_0xd9fa6a['offsetSize'];_0x4f0093++)_0x496b48['push'](new ut('$text',{'vid':null===_0x56eed9?this['_revisionId']++:_0x56eed9++}));}if(_0x32baf0['is']('documentFragment')){const _0x125f8e=P(_0x32baf0['rootName']);return _0x125f8e['_insertChild'](0x0,_0x496b48),_0x125f8e;}return _0x5de769['_setAttribute']('vid_end',null===_0x56eed9?this['_revisionId']++:_0x56eed9++),_0x5de769['_insertChild'](0x0,_0x496b48),_0x5de769;}['_calculateMetaData'](_0x30ff2f,_0x299bcb,_0x5d319d){this['_reset']();const {roots:_0x4afd86,markers:_0x4ced79,rootsAttributes:_0x58ea97}=this['_savedMetaData']['get'](_0x30ff2f);this['_baseRoots']=new Map(_0x4afd86),this['_baseRootsAttributes']=new Map(_0x40ea9a(_0x58ea97));for(const [_0x596ef8,_0x5d1be3]of this['_baseRoots'])if('$graveyard'!==_0x596ef8&&(this['_diffRoots']['set'](_0x596ef8,N(_0x5d1be3)),this['_diffRootsAttributes']=new Map(_0x40ea9a(_0x58ea97)),_0x5d319d)){const _0x55add9=this['_revisionId'];this['_idsRoots']['set'](_0x596ef8,this['_makeIdsRoot'](_0x5d1be3)),this['_baseIdsRoots']['set'](_0x596ef8,this['_makeIdsRoot'](_0x5d1be3,_0x55add9));}this['_startingRevisionId']=this['_revisionId'],this['_diffRoots']['set']('$graveyard',N(this['_baseRoots']['get']('$graveyard'))),_0x5d319d&&this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](this['_baseRoots']['get']('$graveyard')));for(const [_0x41c2be,_0x54e070]of _0x4ced79){const _0x172dc8=this['_baseRoots']['get'](_0x54e070['rootName']),_0x45c9c3=this['_diffRoots']['get'](_0x54e070['rootName']),_0x54253f=new lt(this['_fixPosition'](_0x54e070['start'],_0x172dc8),this['_fixPosition'](_0x54e070['end'],_0x172dc8)),_0x554c9e=this['_fixRange'](_0x54253f,_0x45c9c3);_0x172dc8['markers']['set'](_0x41c2be,_0x54253f),this['_markers']['set'](_0x41c2be,_0x554c9e);}this['_applyOperations'](_0x30ff2f,_0x299bcb,_0x5d319d);}['_applyOperations'](_0x1a29d0,_0x10f1ad,_0x46b1fb){for(const _0x1b046b of this['source']['getOperations'](_0x1a29d0,_0x10f1ad))this['_handleOperation'](_0x1b046b,_0x46b1fb);for(const _0x23919f of this['_diffRoots']['values']())_0x23919f['markers']['clear']();for(const [_0x2779d5,_0x3ad422]of this['_markers']){this['_diffRoots']['get'](_0x3ad422['root']['rootName'])['markers']['set'](_0x2779d5,_0x3ad422['clone']());}const _0x65800e=new Map(),_0x33f297=new Map();for(const [_0x15fbe9,_0x2e55b6]of this['_diffRoots'])_0x65800e['set'](_0x15fbe9,N(_0x2e55b6)),_0x33f297['set'](_0x15fbe9,this['_diffRootsAttributes']['get'](_0x15fbe9));this['_saveMetaData'](_0x10f1ad,_0x65800e,this['_markers'],_0x33f297);}['_getPreviousFrom'](_0x12831e){const _0x77f09f=Array['from'](this['_savedMetaData']['keys']());_0x77f09f['sort']((_0x4aff37,_0x2bfd6c)=>_0x4aff37-_0x2bfd6c),_0x77f09f['reverse']();for(const _0x58e491 of _0x77f09f)if(_0x58e491<_0x12831e)return _0x58e491;return Number['NEGATIVE_INFINITY'];}['_copyMarkers'](_0x5251d7,_0x3a11a2){const _0x5c5d35=Array['from'](_0x3a11a2['markers'])['map'](([_0x24df35,_0x119d33])=>[_0x24df35,this['_fixRange'](_0x119d33,_0x5251d7)]);_0x5251d7['markers']=new Map(_0x5c5d35);}['_transformMarkers'](_0x3ac7f2){for(const _0x524b60 of this['_markers']['values']()){const _0x569f2e=_0x524b60['getTransformedByOperation'](_0x3ac7f2),_0x36510c=lt['_createFromRanges'](_0x569f2e);_0x524b60['start']=_0x36510c['start'],_0x524b60['end']=_0x36510c['end'];}}['_handleOperation'](_0x22ad31,_0x4a0502){if('addRoot'!=_0x22ad31['type']&&'detachRoot'!=_0x22ad31['type']){if('insert'==_0x22ad31['type']){const _0x2376bb=_0x22ad31['position']['root']['rootName'];this['_diffRoots']['has'](_0x2376bb)||(this['_diffRoots']['set'](_0x2376bb,P(_0x2376bb,!0x0)),this['_diffRootsAttributes']['set'](_0x2376bb,{}),_0x4a0502&&this['_idsRoots']['set'](_0x2376bb,P(_0x2376bb,!0x0)));}else{if('addRootAttribute'==_0x22ad31['type']||'removeRootAttribute'==_0x22ad31['type']||'changeRootAttribute'==_0x22ad31['type'])return void this['_handleRootAttributeOperation'](_0x22ad31);'marker'==_0x22ad31['type']&&this['_handleMarkerOperation'](_0x22ad31);}if('marker'!==_0x22ad31['type']){const _0x28ee17=this['_cloneOperation'](_0x22ad31,this['_diffRoots']);_0x28ee17['_execute'](),this['_transformMarkers'](_0x28ee17);}if(_0x4a0502)switch(_0x22ad31['type']){case'insert':this['_handleInsertOperation'](_0x22ad31);break;case'move':case'remove':case'reinsert':this['_handleMoveOperation'](_0x22ad31);break;case'merge':this['_handleMergeOperation'](_0x22ad31);break;case'split':this['_handleSplitOperation'](_0x22ad31);}}else this['_handleRootOperation'](_0x22ad31,_0x4a0502);}['_cloneOperation'](_0x2cf08a,_0x4907fd){const _0x148a14=_0x2cf08a['clone']();return _0x148a14['_authorId']=_0x2cf08a['_authorId'],this['_fixOperation'](_0x148a14,_0x4907fd),_0x148a14;}['_getBaseVids'](_0x3640c7){return _0x3640c7['map'](_0x467060=>{const _0x89be9d=this['_getVidAttributeName'](_0x467060);return Number(_0x467060['item']['getAttribute'](_0x89be9d));});}['_generateTape'](_0x113cf3,_0x573c4b){if(_0x113cf3['is']('element','$text'))_0x573c4b['push']({'item':_0x113cf3,'type':'text'});else{_0x113cf3['is']('element')&&_0x573c4b['push']({'item':_0x113cf3,'type':'elementStart'});for(const _0x4ab06c of _0x113cf3['getChildren']())this['_generateTape'](_0x4ab06c,_0x573c4b);_0x113cf3['is']('element')&&_0x573c4b['push']({'item':_0x113cf3,'type':'elementEnd'});}return _0x573c4b;}['_getState'](){const _0x5a70ea=new Map(this['_touched']),_0x1e841a=new Map(_0x5a70ea),_0x304566=new Map(),_0x33291b={'insertions':{},'deletions':{}},_0x81bf0e={'insertions':{},'deletions':{}},_0x20592d=new Map(),_0x95e77a=new Set([...this['_baseRoots']['keys'](),...this['_diffRoots']['keys']()]);_0x95e77a['delete']('$graveyard');for(const _0x175005 of _0x95e77a){const _0x112ae7=this['_diffRoots']['get'](_0x175005)||P(_0x175005,!0x1),_0x1ecdf5=this['_baseRoots']['get'](_0x175005)||P(_0x175005,!0x1);_0x112ae7['isAttached']()||_0x1ecdf5['isAttached']()?(_0x33291b['insertions'][_0x175005]=N(_0x112ae7),_0x33291b['deletions'][_0x175005]=N(_0x1ecdf5),this['_copyMarkers'](_0x33291b['deletions'][_0x175005],_0x1ecdf5),this['_copyMarkers'](_0x33291b['insertions'][_0x175005],_0x112ae7),_0x81bf0e['insertions'][_0x175005]=this['_generateTape'](this['_idsRoots']['get'](_0x175005),[]),_0x81bf0e['deletions'][_0x175005]=this['_generateTape'](this['_baseIdsRoots']['get'](_0x175005)||P(_0x175005,!0x1),[])):_0x95e77a['delete'](_0x175005);}for(const _0x4a148e of _0x95e77a){const _0x2f71c3=_0x81bf0e['insertions'][_0x4a148e];for(const _0x5b3dfb of _0x2f71c3){const _0x342726=this['_getVidAttributeName'](_0x5b3dfb),_0x7f3fe6=_0x5b3dfb['item']['getAttribute'](_0x342726);_0x1e841a['delete'](_0x7f3fe6),_0x7f3fe6>=this['_startingRevisionId']&&_0x304566['set'](_0x7f3fe6,_0x5a70ea['get'](_0x7f3fe6));}}for(const _0x48445c of _0x95e77a){const _0x2b8e21=_0x81bf0e['insertions'][_0x48445c],_0x26195e=this['_getBaseVids'](_0x81bf0e['deletions'][_0x48445c]);let _0x29875c=0x0;for(const _0x20b968 of _0x2b8e21){const _0x2505a0=this['_getVidAttributeName'](_0x20b968),_0x5b0c28=_0x20b968['item']['getAttribute'](_0x2505a0);if(!_0x304566['has'](_0x5b0c28)&&!_0x20592d['has'](_0x5b0c28)){if(_0x1e841a['has'](_0x5b0c28))_0x29875c++;else{if(_0x5b0c28!=_0x26195e[_0x29875c]){const _0x361c60=_0x5a70ea['get'](_0x5b0c28)||_0x5a70ea['get'](_0x26195e[_0x29875c]);for(;_0x5b0c28!=_0x26195e[_0x29875c];)_0x1e841a['has'](_0x26195e[_0x29875c])||(_0x20592d['set'](_0x26195e[_0x29875c],_0x361c60),_0x5a70ea['set'](_0x26195e[_0x29875c],_0x361c60)),_0x29875c++;}_0x29875c++;}}}}for(const _0x9f888e of _0x95e77a){const _0x48f0e6=_0x81bf0e['insertions'][_0x9f888e];for(const _0x42a651 of _0x48f0e6){const _0x72a019=this['_getVidAttributeName'](_0x42a651),_0x2e1376=_0x42a651['item']['getAttribute'](_0x72a019);if(_0x20592d['has'](_0x2e1376)){const _0x39b463=_0x20592d['get'](_0x2e1376);_0x1e841a['has'](_0x2e1376)||_0x1e841a['set'](_0x2e1376,{..._0x39b463}),_0x304566['set'](_0x2e1376,{..._0x39b463});}}}for(const _0x2c7549 of _0x1e841a['keys']())_0x2c7549>=this['_startingRevisionId']&&_0x1e841a['delete'](_0x2c7549);const _0x4637c6=new Map();for(const _0x1c9a69 of _0x95e77a){let _0x59b4c3=_0x81bf0e['insertions'][_0x1c9a69];for(const _0x3bb293 of _0x59b4c3)if(_0x3bb293['item']['is']('element','tableCell')){const _0x3dc009=this['_getVidAttributeName'](_0x3bb293),_0x358694=_0x3bb293['item']['getAttribute'](_0x3dc009);if(_0x304566['has'](_0x358694)){const _0x852225=_0x3bb293['item']['parent']['parent']['getAttribute']('vid_start'),_0x390e53=_0x4637c6['get'](_0x852225)||new Set();_0x390e53['add'](_0x304566['get'](_0x358694)['userId']),_0x4637c6['set'](_0x852225,_0x390e53);}}_0x59b4c3=_0x81bf0e['deletions'][_0x1c9a69];for(const _0x98d0e1 of _0x59b4c3)if(_0x98d0e1['item']['is']('element','tableCell')){const _0x4c6a57=this['_getVidAttributeName'](_0x98d0e1),_0x45604b=_0x98d0e1['item']['getAttribute'](_0x4c6a57);if(_0x1e841a['has'](_0x45604b)){const _0x3c0fff=_0x98d0e1['item']['parent']['parent']['getAttribute']('vid_start'),_0x4321e0=_0x4637c6['get'](_0x3c0fff)||new Set();_0x4321e0['add'](_0x1e841a['get'](_0x45604b)['userId']),_0x4637c6['set'](_0x3c0fff,_0x4321e0);}}for(const _0x3f5e51 of _0x4637c6['keys']())(_0x304566['has'](_0x3f5e51)||_0x1e841a['has'](_0x3f5e51))&&_0x4637c6['delete'](_0x3f5e51);}for(const _0x1af7a2 of _0x95e77a){const _0x254d91=_0x81bf0e['insertions'][_0x1af7a2];let _0x378ca4=null,_0x253fb9=null;for(const _0x347212 of _0x254d91){const _0x5ac95c=this['_getVidAttributeName'](_0x347212),_0x252a3e=_0x347212['item']['getAttribute'](_0x5ac95c),_0x5a263e=_0x4637c6['get'](_0x252a3e);_0x5a263e&&'elementStart'==_0x347212['type']&&(_0x378ca4=Array['from'](_0x5a263e)[0x0],_0x253fb9=_0x347212['item']['getAttribute']('vid_end')),_0x378ca4&&(_0x1e841a['set'](_0x252a3e,{'userId':_0x378ca4}),_0x304566['set'](_0x252a3e,{'userId':_0x378ca4})),_0x252a3e==_0x253fb9&&(_0x378ca4=null,_0x253fb9=null);}}const _0x38455a={},_0x15300d=new Set();for(const _0x9e2fe1 of _0x95e77a){const _0x20f2e8=_0x33291b['deletions'][_0x9e2fe1],_0x75d1db=_0x33291b['insertions'][_0x9e2fe1];for(const {userId:_0x443096}of this['_touchedMarkers']['values']())null!==_0x443096&&_0x15300d['add'](_0x443096);for(const {userId:_0x1f60a3}of this['_touchedRoots']['values']())null!==_0x1f60a3&&_0x15300d['add'](_0x1f60a3);this['_markChanges'](_0x75d1db,_0x81bf0e['insertions'][_0x9e2fe1],_0x304566,'insertion',_0x15300d),this['_markChanges'](_0x20f2e8,_0x81bf0e['deletions'][_0x9e2fe1],_0x1e841a,'deletion',_0x15300d),_0x38455a[_0x9e2fe1]={'insertions':this['_prepareViewToSave'](_0x75d1db),'deletions':this['_prepareViewToSave'](_0x20f2e8),'attachChange':this['_touchedRoots']['get'](_0x9e2fe1)||null,'attributesBefore':_0x40ea9a(this['_baseRootsAttributes']['get'](_0x9e2fe1))||{},'attributesAfter':_0x40ea9a(this['_diffRootsAttributes']['get'](_0x9e2fe1))};}return{'diffData':_0x38455a,'authorsIds':Array['from'](_0x15300d)};}['_processRootBeforeSave'](_0x16c6d5){for(const [,_0x417a92]of _0x16c6d5['markers']){const _0x4a8e7c=_0x417a92['start']['getAncestors']()['filter'](_0x2dab15=>'tableCell'==_0x2dab15['name']);for(const _0x2bc874 of _0x4a8e7c)0x1==_0x2bc874['childCount']&&_0x2bc874['getChild'](0x0)['is']('element','paragraph')&&_0x2bc874['getChild'](0x0)['_setAttribute']('keepParagraph',!0x0);}}['_prepareViewToSave'](_0xe3154f){this['_processRootBeforeSave'](_0xe3154f);const _0x8e8de9=this['editor']['data']['toView'](_0xe3154f,{}),_0x5b66a9=Array['from'](_0x8e8de9['getChildren']())['map'](_0x185274=>this['_getViewJson'](_0x185274));return JSON['stringify'](_0x5b66a9);}['_getViewJson'](_0x551a56){if(_0x551a56['is']('$text'))return _0x551a56['data'];{const _0x3a97fc=this['editor']['plugins']['get']('RevisionHistoryUtils'),_0x1d3011=_0x551a56,_0x1f77ef=this['editor']['data']['htmlProcessor']['domConverter'],_0x54114d={'type':_0x3a97fc['_getTypeCharForViewElement'](_0x1d3011),'name':_0x1d3011['name'],'attributes':Array['from'](_0x1d3011['getAttributes']()),'children':Array['from'](_0x1d3011['getChildren']())['map'](_0x533060=>this['_getViewJson'](_0x533060))};if(_0x551a56['is']('uiElement')&&'$comment'!=_0x551a56['name']){const _0x5ee1a3=_0x551a56['render'](_0x1f77ef['domDocument'],_0x1f77ef);_0x54114d['children']['push'](_0x5ee1a3['outerHTML']);}else{if(_0x551a56['is']('rawElement')){const _0x484616=_0x1f77ef['domDocument']['createElement'](_0x1d3011['name']);_0x551a56['render'](_0x484616,_0x1f77ef),_0x54114d['children']['push'](_0x484616['innerHTML']);}}const _0x418d48=Array['from'](_0x1d3011['getCustomProperties']());_0x418d48['length']>0x0&&(_0x54114d['customProperties']=_0x418d48);const _0x243097=_0x1d3011['getFillerOffset']();return null!==_0x243097&&(_0x54114d['fillerOffset']=_0x243097),_0x54114d;}}['_markChanges'](_0x36b42b,_0x5cd129,_0x1e1cdd,_0x12fc4c,_0x144f5f){let _0x54a960=null,_0x5db880=null,_0x4fa9e6=0x0;const _0x306e14=this['editor']['model'];for(let _0x2e3c44=0x0;_0x2e3c44<_0x5cd129['length'];_0x2e3c44++){const _0x50de58=this['_getVidAttributeName'](_0x5cd129[_0x2e3c44]),_0x1c4031=_0x5cd129[_0x2e3c44]['item']['getAttribute'](_0x50de58),_0x1f26c6=_0x1e1cdd['get'](_0x1c4031),_0x44648d=_0x2e3c44==_0x5cd129['length']-0x1;(!_0x54a960&&_0x1f26c6&&(_0x54a960=_0x1f26c6,_0x5db880=_0x5cd129[_0x2e3c44]),_0x54a960&&(!_0x1f26c6||_0x1f26c6['userId']!=_0x54a960['userId']))&&(_0x511863(_0x1f26c6,F(_0x5db880,_0x36b42b,_0x306e14),F(_0x5cd129[_0x2e3c44],_0x36b42b,_0x306e14)),_0x54a960=_0x1f26c6||null,_0x5db880=_0x1f26c6?_0x5cd129[_0x2e3c44]:null),_0x54a960&&_0x44648d&&_0x511863(_0x1f26c6,F(_0x5db880,_0x36b42b,_0x306e14),B(_0x5cd129[_0x2e3c44],_0x36b42b,_0x306e14));}function _0x511863(_0x2effa3,_0x452ded,_0x5a53cf){const _0x1ebe49=_0x54a960['userId'],_0x1cd1bd='revision:'+_0x12fc4c+':'+_0x1ebe49+':'+_0x4fa9e6++,_0x577006=_0x306e14['createRange'](_0x452ded,_0x5a53cf);_0x36b42b['markers']['set'](_0x1cd1bd,_0x577006),null!==_0x1ebe49&&_0x144f5f['add'](_0x1ebe49);}}['_getVidAttributeName'](_0x4fa02f){switch(_0x4fa02f['type']){case'elementStart':return'vid_start';case'elementEnd':return'vid_end';default:return'vid';}}['_fixOperation'](_0x99403f,_0x76b095){_0x99403f['baseVersion']=null;for(const _0x39d89a in _0x99403f){const _0x562e09=_0x99403f[_0x39d89a];if(_0x562e09 instanceof ft){const _0x3c13ed=_0x76b095['get'](_0x562e09['root']['rootName']);_0x99403f[_0x39d89a]=this['_fixPosition'](_0x562e09,_0x3c13ed);}if(_0x562e09 instanceof lt){const _0x32b4ee=_0x76b095['get'](_0x562e09['root']['rootName']);_0x99403f[_0x39d89a]=this['_fixRange'](_0x562e09,_0x32b4ee);}'root'===_0x39d89a&&(_0x99403f['root']=_0x76b095['get'](_0x99403f['root']['rootName']));}}['_fixRange'](_0x1f2720,_0x2ef6d1){return this['editor']['model']['createRange'](this['_fixPosition'](_0x1f2720['start'],_0x2ef6d1),this['_fixPosition'](_0x1f2720['end'],_0x2ef6d1));}['_fixPosition'](_0x270f27,_0x4a817c){return this['editor']['model']['createPositionFromPath'](_0x4a817c,_0x270f27['path'],_0x270f27['stickiness']);}['_handleInsertOperation'](_0x11a6a1){const _0x577d9f=this['_idsRoots']['get'](_0x11a6a1['position']['root']['rootName']),_0xf4f2a7=this['_fixPosition'](_0x11a6a1['position'],_0x577d9f),_0x57a426=null===_0x11a6a1['_authorId']?null:_0x11a6a1['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x4e1196=_0xf4f2a7['parent'],_0x3c6ae2=this['_revisionId'],_0x51abf5=[];for(const _0x588b13 of _0x11a6a1['nodes'])if(_0x588b13['is']('element'))_0x51abf5['push'](this['_makeIdsRoot'](_0x588b13));else{for(let _0xb90aba=0x0;_0xb90aba<_0x588b13['offsetSize'];_0xb90aba++)_0x51abf5['push'](new ut('$text',{'vid':this['_revisionId']++}));}const _0x42f69f=this['_revisionId'];for(let _0x2752fc=_0x3c6ae2;_0x2752fc<_0x42f69f;_0x2752fc++)this['_touched']['set'](_0x2752fc,{'userId':_0x57a426});_0x4e1196['_insertChild'](_0xf4f2a7['offset'],_0x51abf5);}['_handleMoveOperation'](_0xd59803){(_0xd59803=this['_cloneOperation'](_0xd59803,this['_idsRoots']))['_execute']();const _0x1e80dc=null===_0xd59803['_authorId']?null:_0xd59803['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x6849a5=_0xd59803['getMovedRangeStart'](),_0x40a290=_0x6849a5['parent'],_0x420858=_0x6849a5['offset'];!function _0x1a139a(_0xc5381f,_0x3850ed,_0x24a841,_0x404586){for(let _0x431169=_0x24a841;_0x431169<_0x404586;_0x431169++){const _0x3e9ba5=_0x3850ed['getChild'](_0x431169);_0x3e9ba5['is']('element','$text')?_0xc5381f['set'](_0x3e9ba5['getAttribute']('vid'),{'userId':_0x1e80dc}):(_0xc5381f['set'](_0x3e9ba5['getAttribute']('vid_start'),{'userId':_0x1e80dc}),_0x1a139a(_0xc5381f,_0x3e9ba5,0x0,_0x3e9ba5['childCount']),_0xc5381f['set'](_0x3e9ba5['getAttribute']('vid_end'),{'userId':_0x1e80dc}));}}(this['_touched'],_0x40a290,_0x420858,_0x420858+_0xd59803['howMany']);}['_handleMergeOperation'](_0x3d9219){const _0x513a90=null===(_0x3d9219=this['_cloneOperation'](_0x3d9219,this['_idsRoots']))['_authorId']?null:_0x3d9219['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x3242dc=_0x3d9219['targetPosition']['parent'],_0x3d48d5=_0x3d9219['sourcePosition']['parent'],_0x4c2681=_0x3242dc['getAttribute']('vid_end'),_0x3a034d=_0x3d48d5['getAttribute']('vid_start');_0x3242dc['_setAttribute']('vid_end',_0x3d48d5['getAttribute']('vid_end')),_0x3d48d5['_setAttribute']('vid_end',_0x4c2681),this['_touched']['set'](_0x3a034d,{'userId':_0x513a90}),this['_touched']['set'](_0x4c2681,{'userId':_0x513a90}),_0x3d9219['_execute']();}['_handleSplitOperation'](_0x26ae49){const _0x4261fc=null===(_0x26ae49=this['_cloneOperation'](_0x26ae49,this['_idsRoots']))['_authorId']?null:_0x26ae49['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x5e6748=_0x26ae49['graveyardPosition'],_0x518506=_0x26ae49['splitPosition']['parent'];_0x26ae49['_execute']();const _0x3c4d4d=_0x518506['getAttribute']('vid_end'),_0x109621=_0x26ae49['insertionPosition']['nodeAfter'];if(_0x5e6748){const _0x38b89b=_0x109621['getAttribute']('vid_end'),_0xdc8f9e=_0x518506['getAttribute']('vid_end');_0x518506['_setAttribute']('vid_end',_0x38b89b),_0x109621['_setAttribute']('vid_end',_0xdc8f9e),this['_touched']['set'](_0x518506['getAttribute']('vid_end'),{'userId':_0x4261fc}),this['_touched']['set'](_0x109621['getAttribute']('vid_start'),{'userId':_0x4261fc});}else{const _0x13fe13=this['_revisionId']++,_0xe1603f=this['_revisionId']++;_0x518506['_setAttribute']('vid_end',_0x13fe13),_0x109621['_setAttribute']('vid_start',_0xe1603f),_0x109621['_setAttribute']('vid_end',_0x3c4d4d),this['_touched']['set'](_0x13fe13,{'userId':_0x4261fc}),this['_touched']['set'](_0xe1603f,{'userId':_0x4261fc});}}['_handleMarkerOperation'](_0x12c78d){if(!_0x12c78d['affectsData'])return;const _0x5512d1=(_0x12c78d=this['_cloneOperation'](_0x12c78d,this['_diffRoots']))['oldRange']?_0x12c78d['oldRange']['root']:null,_0x475f6a=_0x12c78d['newRange']?_0x12c78d['newRange']['root']:null;_0x5512d1&&this['_markers']['delete'](_0x12c78d['name']),_0x475f6a&&this['_markers']['set'](_0x12c78d['name'],_0x12c78d['newRange']['clone']());const _0x27c0ff=null===_0x12c78d['_authorId']?null:_0x12c78d['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x356358=_0x12c78d['name'];if(!this['_touchedMarkers']['has'](_0x356358))return void this['_touchedMarkers']['set'](_0x356358,{'range':_0x12c78d['oldRange'],'userId':_0x27c0ff});const _0x347eb5=this['_touchedMarkers']['get'](_0x356358),_0x1e2110=_0x347eb5['range'],_0x5f37cc=_0x12c78d['newRange'];null==_0x1e2110&&null==_0x5f37cc||_0x1e2110&&_0x5f37cc&&_0x1e2110['isEqual'](_0x5f37cc)?this['_touchedMarkers']['delete'](_0x12c78d['name']):_0x347eb5['userId']=_0x27c0ff;}['_handleRootOperation'](_0x4f798f,_0x42a5be){this['_diffRoots']['has'](_0x4f798f['rootName'])?this['_diffRoots']['get'](_0x4f798f['rootName'])['_isAttached']=_0x4f798f['isAdd']:(this['_diffRoots']['set'](_0x4f798f['rootName'],P(_0x4f798f['rootName'],!0x0)),this['_diffRootsAttributes']['set'](_0x4f798f['rootName'],{}),_0x42a5be&&this['_idsRoots']['set'](_0x4f798f['rootName'],P(_0x4f798f['rootName'],!0x0)));const _0x1d96e1=null===_0x4f798f['_authorId']?null:_0x4f798f['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x148c9f=this['_touchedRoots']['get'](_0x4f798f['rootName']);_0x148c9f&&_0x148c9f['userId']===_0x1d96e1?this['_touchedRoots']['delete'](_0x4f798f['rootName']):this['_touchedRoots']['set'](_0x4f798f['rootName'],{'userId':_0x1d96e1,'isAttached':_0x4f798f['isAdd']});}['_handleRootAttributeOperation'](_0x16384e){const _0x8312fd=this['_diffRootsAttributes']['get'](_0x16384e['root']['rootName']);null===_0x16384e['newValue']?delete _0x8312fd[_0x16384e['key']]:_0x8312fd[_0x16384e['key']]=_0x16384e['newValue'];}}function N(_0x4f208b){const _0x8755f7=P(_0x4f208b['rootName'],_0x4f208b['isAttached']());for(const _0x15fbfb of _0x4f208b['getChildren']()){const _0x27df44=_0x15fbfb['_clone'](!0x0);_0x8755f7['_appendChild'](_0x27df44);}return _0x8755f7;}function P(_0x4f9004,_0x403e22=!0x0){const _0x398402=new vt();return _0x398402['rootName']=_0x4f9004,_0x398402['_isAttached']=_0x403e22,_0x398402['isAttached']=()=>_0x398402['_isAttached'],_0x398402;}function F(_0x3c63b0,_0x7bb793,_0x253212){const _0x15c5d4='elementEnd'==_0x3c63b0['type']?_0x253212['createPositionAt'](_0x3c63b0['item'],'end'):_0x253212['createPositionBefore'](_0x3c63b0['item']);return _0x253212['createPositionFromPath'](_0x7bb793,_0x15c5d4['path'],_0x15c5d4['stickiness']);}function B(_0x1e34fc,_0x1c2fe2,_0xbb4909){const _0x27e0c9='elementStart'==_0x1e34fc['type']?_0xbb4909['createPositionAt'](_0x1e34fc['item'],0x0):_0xbb4909['createPositionAfter'](_0x1e34fc['item']);return _0xbb4909['createPositionFromPath'](_0x1c2fe2,_0x27e0c9['path'],_0x27e0c9['stickiness']);}class hs extends ts{['focusTracker'];['keystrokes'];['revisionNameInputView'];constructor(_0x1343c5,_0x5f3159){super(_0x1343c5),this['focusTracker']=new _0x1a5bd3(),this['keystrokes']=new _0x5906fb(),this['set']('revisionNameInputValue',''),this['revisionNameInputView']=this['_createRevisionNameInput'](_0x5f3159),this['setTemplate']({'tag':'form','attributes':{'class':['ck','ck-revision-history-save-revision-form','ck-responsive-form'],'tabindex':'-1'},'children':[this['revisionNameInputView']]}),_0x51d33e(this);}['render'](){super['render'](),_0x47de8a({'view':this}),this['focusTracker']['add'](this['revisionNameInputView']['element']),this['keystrokes']['listenTo'](this['element']);const _0x509ff7=_0x4d4e4f=>_0x4d4e4f['stopPropagation']();this['keystrokes']['set']('arrowright',_0x509ff7),this['keystrokes']['set']('arrowleft',_0x509ff7),this['keystrokes']['set']('arrowup',_0x509ff7),this['keystrokes']['set']('arrowdown',_0x509ff7);}['focus'](){this['revisionNameInputView']['focus']();}get['revisionName'](){return this['revisionNameInputView']['fieldView']['element']['value']['trim']();}set['revisionName'](_0x2fe79){this['revisionNameInputView']['fieldView']['element']['value']=_0x2fe79['trim']();}['reset'](){this['revisionNameInputView']['fieldView']['element']['value']='',this['revisionNameInputView']['errorText']=null;}['_createRevisionNameInput'](_0x474e92){const _0x3c9e17=new _0x5d8229(this['locale'],_0x302711),_0x47da26=_0x3c9e17['fieldView'];_0x47da26['extendTemplate']({'attributes':{'maxlength':'220'}});let _0x5909d1=g(this['locale'],'Name\x20of\x20the\x20revision');return!_0x474e92&&(_0x5909d1+='\x20('+g(this['locale'],'optional')+')'),(_0x3c9e17['label']=_0x5909d1,_0x47da26['on']('input',()=>{this['revisionNameInputValue']=_0x47da26['element']['value']['trim']();}),_0x3c9e17);}}class f extends _0x443a46{static get['pluginName'](){return'RevisionHistoryUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[u];}['_saveRevisionFormView'];['init'](){const _0x5101ba=this['editor'],_0x528ae1=_0x5101ba['plugins']['get']('RevisionTracker');_0x5101ba['ui']['componentFactory']['add']('revisionHistory',_0x35b6d9=>{const _0x1a76c7=_0x1429b9(_0x35b6d9),_0x88ece1=_0x1a76c7['panelView']['children'],_0x42c749=new _0x8fa149(_0x35b6d9),_0xce5bc1=new _0xd18afd(_0x35b6d9),_0x1b1892=new te(_0x35b6d9),_0x3a3be6=new _0xd18afd(_0x35b6d9),_0x45aecb=new te(_0x35b6d9);return _0x1a76c7['bind']('isEnabled')['to'](_0x528ae1,'isReady',_0x528ae1,'isEnabled',_0x5101ba,'isReadOnly',(_0x80294,_0x43a634,_0x21173d)=>_0x80294&&_0x43a634&&!_0x21173d),_0x1a76c7['buttonView']['set']({'icon':_0x1ac31f,'label':g(_0x35b6d9,'Revision\x20history'),'tooltip':!0x0}),_0x1b1892['set']({'label':g(_0x35b6d9,'Save\x20current\x20revision'),'withText':!0x0,'role':'menuitem'}),_0x1b1892['bind']('isEnabled')['to'](_0x528ae1,'isReady',_0x528ae1,'isEnabled',_0x5101ba,'isReadOnly',(_0x4dbbea,_0x189058,_0x14c96f)=>_0x4dbbea&&_0x189058&&!_0x14c96f),_0x1b1892['on']('execute',()=>this['_showDialog']()),_0x45aecb['set']({'label':g(_0x35b6d9,'Open\x20revision\x20history'),'withText':!0x0,'role':'menuitem'}),_0x45aecb['bind']('isEnabled')['to'](_0x528ae1,'isReady',_0x5101ba,'isReadOnly',(_0x42ebbe,_0x12f2a8)=>_0x42ebbe&&!_0x12f2a8),_0x45aecb['on']('execute',()=>{_0x5101ba['config']['get']('revisionHistory')['showRevisionViewerCallback'](),_0x1a76c7['isOpen']=!0x1,_0x5101ba['editing']['view']['focus']();}),_0xce5bc1['children']['add'](_0x1b1892),_0x3a3be6['children']['add'](_0x45aecb),_0x42c749['role']='menu',_0x42c749['items']['addMany']([_0xce5bc1,_0x3a3be6]),_0x88ece1['add'](_0x42c749),_0x1a76c7;}),_0x5101ba['ui']['componentFactory']['add']('menuBar:revisionHistory',()=>this['_registerMenuComponent']());}['_registerMenuComponent'](){const _0x1193c5=this['editor'],_0x96c850=_0x1193c5['locale'],_0x12f1ca=new _0x2126e1(_0x96c850),_0x25be4a=new _0x1ff503(_0x96c850);_0x12f1ca['buttonView']['set']({'icon':_0x1ac31f,'label':g(_0x96c850,'Revision\x20history')});const _0x73453c=new _0x4a9d4a(_0x96c850,_0x12f1ca),_0x1f5141=new _0x3fe7a4(_0x96c850);_0x1f5141['set']({'label':g(_0x96c850,'Save\x20current\x20revision')}),_0x1f5141['delegate']('execute')['to'](_0x12f1ca),_0x1f5141['on']('execute',()=>{this['_showDialog']();}),_0x73453c['children']['add'](_0x1f5141),_0x25be4a['items']['add'](_0x73453c);const _0x59e5da=new _0x4a9d4a(_0x96c850,_0x12f1ca),_0x360d34=new _0x3fe7a4(_0x96c850);return _0x360d34['set']({'label':g(_0x96c850,'Open\x20revision\x20history')}),_0x360d34['delegate']('execute')['to'](_0x12f1ca),_0x360d34['on']('execute',()=>{_0x1193c5['config']['get']('revisionHistory')['showRevisionViewerCallback']();}),_0x59e5da['children']['add'](_0x360d34),_0x25be4a['items']['add'](_0x59e5da),_0x12f1ca['panelView']['children']['add'](_0x25be4a),_0x12f1ca;}['_showDialog'](){const _0x1a7bf9=this['editor'],_0x1db5b5=_0x1a7bf9['locale'],_0x57cf38=_0x1a7bf9['plugins']['get']('Dialog'),_0x1b0067=_0x1a7bf9['plugins']['get']('RevisionTracker');function _0x4c5e39(_0x25d929){_0x1a7bf9['config']['get']('revisionHistory.requireRevisionName')&&''===_0x25d929['revisionName']?_0x25d929['revisionNameInputView']['errorText']=g(_0x1db5b5,'The\x20revision\x20name\x20cannot\x20be\x20empty.'):(_0x1a7bf9['plugins']['get'](u)['saveRevision']({'name':_0x25d929['revisionName']}),_0x57cf38['hide']());}this['_saveRevisionFormView']||(this['_createSaveRevisionFormView'](),this['_saveRevisionFormView']['on']('submit',()=>_0x4c5e39(this['_saveRevisionFormView']))),this['_saveRevisionFormView']['reset'](),_0x57cf38['show']({'id':'revisionSave','title':g(_0x1db5b5,'Save\x20current\x20revision'),'isModal':!0x0,'content':this['_saveRevisionFormView'],'actionButtons':[{'label':g(_0x1a7bf9['locale'],'Cancel'),'withText':!0x0,'onExecute':()=>_0x57cf38['hide']()},{'label':g(_0x1a7bf9['locale'],'Accept'),'class':'ck-button-action','withText':!0x0,'onCreate'(_0x11dc2a){_0x11dc2a['bind']('isEnabled')['to'](_0x1b0067,'isReady',_0x1b0067,'isEnabled',_0x1a7bf9,'isReadOnly',(_0x542b59,_0x2cad78,_0x1ae3ad)=>_0x542b59&&_0x2cad78&&!_0x1ae3ad);},'onExecute':()=>_0x4c5e39(this['_saveRevisionFormView'])}]});}['_createSaveRevisionFormView'](){const _0x459fcb=this['editor'],_0x3dc856=_0x459fcb['locale'];this['_saveRevisionFormView']=new hs(_0x3dc856,_0x459fcb['config']['get']('revisionHistory.requireRevisionName')),this['_saveRevisionFormView']['render']();}}class Q extends ts{['changeId'];['_model'];constructor(_0x2f5b06,_0xe72665){super(_0x2f5b06),this['_model']=_0xe72665,this['changeId']=_0xe72665['id'];const _0x37ddec=this['bindTemplate'],_0x4c26a5=g(_0x2f5b06,_0xe72665['data']['isSuggestion']?'Suggested\x20by':'add'==_0xe72665['type']?'Added\x20by':'Removed\x20by');this['set']('type',_0xe72665['type']),this['setTemplate']({'tag':'div','attributes':{'class':['ck-annotation','ck-revision-change',_0x37ddec['to']('type',_0x4ec689=>'ck-revision-change__'+_0x4ec689)],'tabindex':-0x1},'children':[{'tag':'span','children':[{'tag':'span','attributes':{'class':['ck-revision-change__label']},'children':[{'text':_0x4c26a5}]},{'text':'\x20'+_0xe72665['author']['name']}]}]});}['focus'](){this['element']['focus']();}}class r extends/* #__PURE__ -- @preserve */
25
+ _0x4fa367(){['id'];['author'];['type'];['data'];['rootName'];constructor(_0x8d9b7c){super(),this['id']=_0x8d9b7c['id']||_0x2a1139(),this['author']=_0x8d9b7c['author'],this['type']=_0x8d9b7c['type'],this['data']=_0x8d9b7c['data']||{},this['rootName']=_0x8d9b7c['rootName'],this['set']('createdAt',_0x8d9b7c['createdAt']);}['toJSON'](){return{'id':this['id'],'authorId':this['author']['id'],'type':this['type'],'data':this['data'],'createdAt':this['createdAt']};}}class c{['newRevisionId'];['oldRevisionId'];['changes'];constructor(_0x553bff,_0x4992c2){this['newRevisionId']=_0x553bff,this['oldRevisionId']=_0x4992c2,this['changes']=new _0x239345();}['_setChanges'](_0x2c2e6b){for(const _0x1b3797 of _0x2c2e6b)this['changes']['add'](_0x1b3797);}}class m extends _0x443a46{['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[_0x33d7db,_0x1d7948,I,V];}constructor(_0x5c5e3a){super(_0x5c5e3a),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',(_0x185d71,_0x1dc78d,_0x43632e)=>{this['activeChange']=null,this['activeView']=null,this['editor']['editing']['view']['change'](_0x113a7f=>{for(const _0x2c3314 of this['editor']['editing']['view']['document']['roots'])_0x43632e?_0x113a7f['removeClass']('ck-editor__editable__overlay',_0x2c3314):_0x113a7f['addClass']('ck-editor__editable__overlay',_0x2c3314);});}),this['bind']('isNavigationMode')['to'](this,'activeChange',_0x345bf1=>null!==_0x345bf1),this['bind']('currentChangeNumber')['to'](this,'isReady',this,'diff',this,'activeChange',(_0xa6fb44,_0x25c79a,_0x54d7d8)=>_0xa6fb44&&_0x54d7d8?_0x25c79a['changes']['getIndex'](_0x54d7d8):0x0),this['bind']('numberOfChanges')['to'](this,'isReady',this,'diff',(_0x35835d,_0x5c6f43)=>_0x35835d?_0x5c6f43['changes']['length']:0x0),this['_changeView']=null,this['_changeIdToChange']=new Map(),this['_balloon']=this['editor']['plugins']['get'](_0x1d7948);}['init'](){const _0x51cd92=this['editor'],_0x207acc=new wt(_0x51cd92,{'direction':'backward'}),_0x5ac4c2=new wt(_0x51cd92,{'direction':'forward'});(_0x51cd92['commands']['add']('showPreviousChange',_0x207acc),_0x51cd92['commands']['add']('showNextChange',_0x5ac4c2),_0x51cd92['commands']['add']('restoreRevision',new mt(_0x51cd92)),this['on']('change:numberOfChanges',()=>{_0x207acc['refresh'](),_0x5ac4c2['refresh']();}),this['_setConversion'](),this['_initInteractions'](),_0x51cd92['enableReadOnlyMode']('revision-viewer'),_0x51cd92['plugins']['has']('WidgetToolbarRepository'))&&_0x51cd92['plugins']['get']('WidgetToolbarRepository')['forceDisabled']('revision-viewer');}async['getRevisionDocumentData'](_0x2ee17a){return await this['_utils']['loadRevisionData'](_0x2ee17a,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x2ee17a);}async['getRevisionRootsAttributes'](_0x1fddba){return await this['_utils']['loadRevisionData'](_0x1fddba,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x1fddba);}async['compare'](_0x1244fa,_0x2af48f,_0x263a0a=!0x1){if(!this['isEnabled'])return;const _0xd36b76=this['diff'],_0x5b774d=this['repository'],_0xd31f52='string'==typeof _0x1244fa?_0x5b774d['getRevision'](_0x1244fa):_0x1244fa,_0x405028='string'==typeof _0x2af48f?_0x5b774d['getRevision'](_0x2af48f):_0x2af48f,_0x6a99eb=_0xd31f52['id'],_0x1296e9=_0x405028?_0x405028['id']:null;if(!_0x263a0a&&this['diff']&&this['diff']['newRevisionId']===_0x6a99eb&&this['diff']['oldRevisionId']===_0x1296e9)return Promise['resolve']();this['isReady']=!0x1,this['activeView']=null,this['activeChange']=null,this['diff']=new c(_0x6a99eb,_0x1296e9);const _0x52a375=this['_getRevisionsRange'](_0xd31f52,_0x405028,!0x0)['map'](_0x25abe4=>this['_utils']['loadRevisionData'](_0x25abe4,this['adapter']));return _0x52a375['push'](new Promise(_0x366c93=>{setTimeout(_0x366c93,0x14);})),Promise['all'](_0x52a375)['then'](()=>{if(!this['isEnabled'])return;this['_cleanUp']();const _0xf0f2bc=this['_getDiff'](_0x6a99eb,_0x1296e9);for(const _0x969cab of _0xf0f2bc['changes'])this['_changeIdToChange']['set'](_0x969cab['id'],_0x969cab);this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x44c694=>{for(const _0x35b5c0 of this['editor']['model']['document']['getRootNames']())_0x44c694['detachRoot'](_0x35b5c0);for(const _0x227f8f of Object['keys'](_0xf0f2bc['model'])){const _0xa6e4d4=_0x44c694['addRoot'](_0x227f8f);for(const _0x507ae6 of Object['keys'](_0xf0f2bc['attributes'][_0x227f8f]))_0x44c694['setAttribute'](_0x507ae6,_0xf0f2bc['attributes'][_0x227f8f][_0x507ae6],_0xa6e4d4);_0x44c694['insert'](_0xf0f2bc['model'][_0x227f8f],_0xa6e4d4,0x0);}}),this['diff']['_setChanges'](this['_sortAndFilterDiffChanges'](_0xf0f2bc['changes'])),this['isReady']=!0x0;})['catch'](_0x134f0b=>{console['error'](_0x134f0b),this['_cleanUp'](),_0xd36b76&&(this['diff']=_0xd36b76),this['isReady']=!0x0;});}['addRevisionData'](_0x504407,_0x170f42){const _0x4cb9b6=this['repository']['createRevision'](_0x504407);return _0x4cb9b6['on']('_update',(_0x57ba7e,_0x379d54,_0x4c714a)=>_0x170f42(_0x379d54,_0x4c714a,_0x4cb9b6)),this['repository']['addRevision'](_0x4cb9b6),_0x4cb9b6;}['_cleanUp'](){this['activeChange']=null,this['_cleanMarkers'](),this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=null,this['_changeIdToChange']['clear'](),this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x373adf=>{for(const _0x10b04f of this['editor']['model']['document']['getRootNames']())_0x373adf['detachRoot'](_0x10b04f);});}['_sortAndFilterDiffChanges'](_0x2b23ef){const _0x1fc47a=[],_0x2915c0=new Map();for(const _0x24bee9 of this['editor']['model']['document']['getRootNames']()){const _0x1b1922=this['editor']['editing']['view']['getDomRoot'](_0x24bee9);if(!_0x1b1922)continue;const _0x18b0f2=_0x1b1922['getClientRects']()['item'](0x0);_0x18b0f2&&(_0x1fc47a['push'](_0x24bee9),_0x2915c0['set'](_0x24bee9,_0x18b0f2));}return _0x1fc47a['sort']((_0x1d0ac8,_0x312d3e)=>{const _0x488558=_0x2915c0['get'](_0x1d0ac8),_0x1d49b3=_0x2915c0['get'](_0x312d3e);return _0x488558['y']-_0x1d49b3['y']||_0x488558['x']-_0x1d49b3['x'];}),(_0x2b23ef=_0x2b23ef['filter'](_0x58d57b=>_0x1fc47a['includes'](_0x58d57b['rootName'])))['sort']((_0x4a6d57,_0x5b07b2)=>_0x1fc47a['indexOf'](_0x4a6d57['rootName'])-_0x1fc47a['indexOf'](_0x5b07b2['rootName'])),_0x2b23ef;}['_makeTape'](_0x57eb5f){const _0xc44ecf=Array['from'](_0x57eb5f['markers'])['filter'](([_0x17ec90,_0x4793b8])=>_0x17ec90['startsWith']('revision:')&&!_0x4793b8['isCollapsed']),_0x448065=Array['from'](this['editor']['model']['createRangeIn'](_0x57eb5f)['getWalker']({'singleCharacters':!0x0}));if(0x0!=_0xc44ecf['length'])for(const _0x10d9f7 of _0x448065){const [_0x4adc4f,_0x369248]=_0xc44ecf[0x0],[,_0x702530,_0x25e03b]=_0x4adc4f['split'](':');if(_0x369248['end']['isEqual'](_0x10d9f7['nextPosition'])&&_0xc44ecf['shift'](),(_0x10d9f7['previousPosition']['isEqual'](_0x369248['start'])||_0x10d9f7['previousPosition']['isAfter'](_0x369248['start']))&&('insertion'==_0x702530?_0x10d9f7['isAdded']={'userId':_0x25e03b}:'deletion'==_0x702530&&(_0x10d9f7['isRemoved']={'userId':_0x25e03b})),0x0==_0xc44ecf['length'])break;}return _0x448065;}['_refreshStartEndIndex'](_0x28df9a){const _0x9b9016=new Map();for(let _0x203329=0x0;_0x203329<_0x28df9a['length'];_0x203329++)'text'===_0x28df9a[_0x203329]['type']?(_0x28df9a[_0x203329]['item']['startIndex']=_0x203329,_0x28df9a[_0x203329]['item']['endIndex']=_0x203329):('elementStart'===_0x28df9a[_0x203329]['type']?_0x28df9a[_0x203329]['item']['startIndex']=_0x203329:'elementEnd'===_0x28df9a[_0x203329]['type']&&(_0x28df9a[_0x203329]['item']['endIndex']=_0x203329),_0x9b9016['set'](_0x28df9a[_0x203329]['id'],_0x203329));for(const _0x4598bc of _0x9b9016['values']())'elementStart'===_0x28df9a[_0x4598bc]['type']?_0x28df9a[_0x4598bc]['item']['endIndex']=_0x9b9016['get'](_0x28df9a[_0x4598bc]['pairId']):'elementEnd'===_0x28df9a[_0x4598bc]['type']&&(_0x28df9a[_0x4598bc]['item']['startIndex']=_0x9b9016['get'](_0x28df9a[_0x4598bc]['pairId']));}['_processTape'](_0x1fc7f2){for(let _0xb17a13=0x0;_0xb17a13<_0x1fc7f2['length'];_0xb17a13++){if('elementStart'===_0x1fc7f2[_0xb17a13]['type'])_0x1fc7f2[_0xb17a13]['item']['startIndex']=_0xb17a13;else{if('elementEnd'===_0x1fc7f2[_0xb17a13]['type']){_0x1fc7f2[_0xb17a13]['item']['endIndex']=_0xb17a13;const _0x6c2b83=_0x1fc7f2[_0xb17a13]['item']['startIndex'];_0x1fc7f2[_0x6c2b83]['pairId']=_0x1fc7f2[_0xb17a13]['id'],_0x1fc7f2[_0xb17a13]['pairId']=_0x1fc7f2[_0x6c2b83]['id'];}else _0x1fc7f2[_0xb17a13]['item']['startIndex']=_0xb17a13,_0x1fc7f2[_0xb17a13]['item']['endIndex']=_0xb17a13,_0x1fc7f2[_0xb17a13]['pairId']=null;}_0x1fc7f2[_0xb17a13]['markersStart']||(_0x1fc7f2[_0xb17a13]['markersStart']=[],_0x1fc7f2[_0xb17a13]['markersEnd']=[]);}}['_markInsertions'](_0x17e7a0,_0x26e1ef){const _0x239059=_0x17e7a0['filter'](_0x10bc02=>!_0x10bc02['isAdded']);for(let _0x1ba763=0x0;_0x1ba763<_0x26e1ef['length'];_0x1ba763++)_0x26e1ef[_0x1ba763]['isAdded']&&(_0x239059[_0x1ba763]['isAdded']=_0x26e1ef[_0x1ba763]['isAdded']);}['_getDiff'](_0x132bda,_0x45afce=null){const _0x5dbe62=this['repository']['getRevision'](_0x132bda),_0x44b9ce=_0x45afce?this['repository']['getRevision'](_0x45afce):null,_0x115284=this['_getRevisionsRange'](_0x5dbe62,_0x44b9ce),_0x15b3d2=_0x115284[_0x115284['length']-0x1],_0x179de6=new Map(),_0x42ef1b={'model':{},'attributes':{},'changes':[]},_0x16da95=new Set(),_0x4be5cf=new Map();for(let _0x3f3d55=_0x115284['length']-0x1;_0x3f3d55>=0x0;_0x3f3d55--){const _0x3a3ca=_0x115284[_0x3f3d55];for(const _0xa11f34 of Object['keys'](_0x3a3ca['diffData']))if(_0x3a3ca['diffData'][_0xa11f34]['attachChange']){const _0x32a4f5=_0x3a3ca['diffData'][_0xa11f34]['attachChange'];_0x32a4f5['isAttached']?(_0x16da95['add'](_0xa11f34),_0x4be5cf['has'](_0xa11f34)&&_0x4be5cf['get'](_0xa11f34)['userId']==_0x32a4f5['userId']?_0x4be5cf['delete'](_0xa11f34):_0x4be5cf['set'](_0xa11f34,_0x32a4f5)):_0x4be5cf['has'](_0xa11f34)?(_0x16da95['delete'](_0xa11f34),_0x4be5cf['delete'](_0xa11f34)):(_0x16da95['add'](_0xa11f34),_0x4be5cf['set'](_0xa11f34,_0x32a4f5));}else _0x16da95['add'](_0xa11f34);}for(const _0x1cf811 of _0x16da95){const _0x48b7f2=_0x4be5cf['has'](_0x1cf811)&&!_0x4be5cf['get'](_0x1cf811)['isAttached'];let _0x3c2eb7=_0x48b7f2?_0x115284['length']-0x1:0x0;const _0x1f47e1=_0x48b7f2?-0x1:0x1;for(;_0x115284[_0x3c2eb7];){const _0x642669=_0x115284[_0x3c2eb7];if(_0x642669['diffData'][_0x1cf811]){const _0x555bf3=_0x48b7f2?_0x642669['diffData'][_0x1cf811]['attributesBefore']:_0x642669['diffData'][_0x1cf811]['attributesAfter'];_0x42ef1b['attributes'][_0x1cf811]=_0x555bf3?_0x40ea9a(_0x555bf3):{};break;}_0x3c2eb7+=_0x1f47e1;}}for(const _0x293952 of _0x115284){_0x293952['model']={};for(const _0x25440f of _0x293952['authors'])_0x179de6['set'](_0x25440f['id'],_0x25440f);for(const _0x2b7433 of _0x16da95){const _0x286fc9=_0x293952['diffData'][_0x2b7433]?_0x293952['diffData'][_0x2b7433]['insertions']:'[]',_0x381f88=_0x293952['diffData'][_0x2b7433]?_0x293952['diffData'][_0x2b7433]['deletions']:'[]';_0x293952['model'][_0x2b7433]={'insertions':this['_utils']['_makeModelFromViewString'](_0x286fc9),'deletions':this['_utils']['_makeModelFromViewString'](_0x381f88)};}}for(const _0x3e8fa9 of _0x16da95){let _0x272a57=null,_0x14ae4c=0x0;const _0x54303b=new Map(Array['from'](_0x5dbe62['model'][_0x3e8fa9]['insertions']['markers'])['filter'](([_0x372057])=>!_0x372057['startsWith']('revision:')));let _0x44f61a=0x0;for(const _0x1c197d of _0x115284){const _0x2481fb=this['_makeTape'](_0x1c197d['model'][_0x3e8fa9]['insertions']);_0x1c197d==_0x5dbe62?(_0x272a57=_0x2481fb,_0x14ae4c=_0x272a57['length'],_0x272a57['forEach'](_0x51ce83=>{_0x51ce83['id']=_0x44f61a++;}),this['_processTape'](_0x272a57)):this['_markInsertions'](_0x272a57,_0x2481fb);const _0x1353b8=_0x272a57['filter'](_0x18ccd2=>!_0x18ccd2['isAdded'])['map'](_0x55b699=>_0x55b699['id']);let _0x121b34=0x0;const _0x134c93=this['_makeTape'](_0x1c197d['model'][_0x3e8fa9]['deletions']);_0x134c93['forEach'](_0x5bc026=>{_0x5bc026['isRemoved']?_0x5bc026['id']=_0x14ae4c++:_0x5bc026['id']=_0x1353b8[_0x121b34++];}),this['_processTape'](_0x134c93),this['_setDistance'](_0x272a57,'isAdded'),this['_setDistance'](_0x134c93,'isRemoved'),_0x1c197d==_0x5dbe62&&this['_markMarkers'](_0x272a57,_0x54303b),_0x272a57=this['_joinTapes'](_0x272a57,_0x134c93),this['_refreshStartEndIndex'](_0x272a57),this['_setDistance'](_0x272a57,'isRemoved');}_0x272a57=_0x272a57['filter'](_0x4546a8=>!(_0x4546a8['isAdded']&&_0x4546a8['isRemoved']));const _0x37f5af=new Map(_0x15b3d2['model'][_0x3e8fa9]['deletions']['markers']),_0x2d54af=new Set(_0x54303b['keys']());for(const _0x1ef030 of _0x37f5af['keys']())_0x2d54af['delete'](_0x1ef030);this['_markSuggestions'](_0x272a57,_0x2d54af),this['_fixObsoleteTags'](_0x272a57),_0x272a57=this['_removeMissingPairs'](_0x272a57),_0x272a57=this['_markMismatchedRemovedTags'](_0x272a57),_0x272a57=this['_removeUnsupportedChanges'](_0x272a57);const {root:_0x25c175,changes:_0x1768b8}=this['_makeModelFromTape'](_0x272a57,_0x179de6,_0x3e8fa9);_0x42ef1b['model'][_0x3e8fa9]=_0x25c175;const _0x38b24c=_0x4be5cf['get'](_0x3e8fa9);if(_0x38b24c){const _0x251ea1=_0x179de6['get'](_0x38b24c['userId']),_0x250370=new r({'author':_0x251ea1,'type':_0x38b24c['isAttached']?'add':'remove','data':{'isOnRoot':!0x0},'createdAt':new Date(),'rootName':_0x3e8fa9});_0x1768b8['unshift'](_0x250370),_0x42ef1b['attributes'][_0x3e8fa9]['revisionHistoryAttachChange']=_0x250370['id'];}_0x42ef1b['changes']=_0x42ef1b['changes']['concat'](_0x1768b8);}return _0x42ef1b;}['_markMarkers'](_0x776cbd,_0x5ef6a7){for(let _0x11198e=0x0;_0x11198e<_0x776cbd['length'];_0x11198e++)for(const [_0x11d170,_0x581804]of _0x5ef6a7)!_0x581804['isCollapsed']&&_0x581804['start']['isEqual'](_0x776cbd[_0x11198e]['previousPosition'])&&_0x776cbd[_0x11198e]['markersStart']['push'](_0x11d170),_0x581804['end']['isEqual'](_0x776cbd[_0x11198e]['nextPosition'])&&_0x776cbd[_0x11198e]['markersEnd']['push'](_0x11d170);}['_joinTapes'](_0x3fbeb5,_0x4ad37b){let _0x2ff46f=[],_0x2d6d72=0x0,_0x257133=0x0;for(;_0x2d6d72<_0x3fbeb5['length']||_0x257133<_0x4ad37b['length'];){const _0x3bd7d8=_0x3fbeb5[_0x2d6d72]||{},_0x51aee0=_0x4ad37b[_0x257133]||{};if(_0x3bd7d8['id']==_0x51aee0['id'])_0x2d6d72++,_0x257133++,_0x2ff46f['push'](_0x3bd7d8);else{if(_0x51aee0['isRemoved']&&_0x3bd7d8['isAdded']){const {commonTape:_0x3e1908,iEnd:_0x3fae5e,jEnd:_0x36f236}=this['_threeWayMerge'](_0x3fbeb5,_0x2d6d72,_0x4ad37b,_0x257133);_0x2ff46f=_0x2ff46f['concat'](_0x3e1908),_0x2d6d72=_0x3fae5e,_0x257133=_0x36f236;}else _0x51aee0['isRemoved']?(_0x257133++,_0x2ff46f['push'](_0x51aee0)):(_0x2d6d72++,_0x2ff46f['push'](_0x3bd7d8));}}return _0x2ff46f;}['_markSuggestions'](_0x2a0b06,_0x11f41d){const _0x440fcb=[];for(let _0x40f418=0x0;_0x40f418<_0x2a0b06['length'];_0x40f418++){for(let _0x13fd31=0x0;_0x13fd31<_0x2a0b06[_0x40f418]['markersStart']['length'];_0x13fd31++){const _0x339748=_0x2a0b06[_0x40f418]['markersStart'][_0x13fd31];if(!_0x11f41d['has'](_0x339748))continue;const {group:_0x4743c1,type:_0x4071d8,authorId:_0x5ecfeb}=_0x45ab18(_0x339748);'revision-suggestion'!=_0x4743c1||'insertion'!=_0x4071d8&&'deletion'!=_0x4071d8||(_0x440fcb['unshift']({'type':_0x4071d8,'name':_0x339748,'userId':_0x5ecfeb}),_0x2a0b06[_0x40f418]['markersStart']['splice'](_0x13fd31,0x1),_0x13fd31--);}_0x4e2eb2(_0x2a0b06[_0x40f418]);for(let _0x415684=0x0;_0x415684<_0x2a0b06[_0x40f418]['markersEnd']['length'];_0x415684++){const _0x5a9a74=_0x2a0b06[_0x40f418]['markersEnd'][_0x415684];if(!_0x11f41d['has'](_0x5a9a74))continue;const {group:_0x55ab21,type:_0xc37928}=_0x45ab18(_0x5a9a74);if('revision-suggestion'!=_0x55ab21||'insertion'!=_0xc37928&&'deletion'!=_0xc37928)continue;_0x2a0b06[_0x40f418]['markersEnd']['splice'](_0x415684,0x1),_0x415684--;const _0x164aff=_0x440fcb['findIndex'](_0x5123d6=>_0x5123d6['name']==_0x5a9a74);_0x164aff>-0x1&&_0x440fcb['splice'](_0x164aff,0x1);}}function _0x45ab18(_0x403064){const _0xc5801d=_0x403064['split'](':');return{'group':_0xc5801d[0x0],'type':_0xc5801d[0x1],'subType':_0xc5801d['length']>=0x5?_0xc5801d[0x2]:null,'id':_0xc5801d['length']<0x5?_0xc5801d[0x2]:_0xc5801d[0x3],'authorId':_0xc5801d['length']<0x5?_0xc5801d[0x3]:_0xc5801d[0x4],'markerCount':0x6==_0xc5801d['length']?_0xc5801d[0x5]:null};}function _0x4e2eb2(_0x1bc043){for(let _0x27663b=0x0;_0x27663b<_0x440fcb['length'];_0x27663b++){if(_0x1bc043['isAdded']&&'insertion'==_0x440fcb[_0x27663b]['type']&&_0x1bc043['isAdded']['userId']==_0x440fcb[_0x27663b]['userId'])return _0x1bc043['isAddSuggestion']=_0x440fcb[_0x27663b],void delete _0x1bc043['isAdded'];if(!_0x1bc043['isAdded']&&!_0x1bc043['isRemoved']&&'deletion'==_0x440fcb[_0x27663b]['type'])return void(_0x1bc043['isRemoveSuggestion']=_0x440fcb[_0x27663b]);}}}['_setDistance'](_0x8bbabb,_0x5aaa46){let _0x20baca=0x0,_0xf66237=!0x1;const _0x5639f6=new Map();for(const _0x4d3686 of _0x8bbabb)_0x4d3686[_0x5aaa46]?_0xf66237&&(_0x20baca++,_0xf66237=!0x1):(_0x20baca++,_0xf66237=!0x0),_0x5639f6['set'](_0x4d3686['id'],_0x20baca);for(let _0x23c4fe=0x0;_0x23c4fe<_0x8bbabb['length'];_0x23c4fe++){if('isRemoved'==_0x5aaa46&&_0x8bbabb[_0x23c4fe]['isAdded']||'isAdded'==_0x5aaa46&&_0x8bbabb[_0x23c4fe]['isRemoved'])continue;if('text'==_0x8bbabb[_0x23c4fe]['type']){_0x8bbabb[_0x23c4fe]['distance']=0x0;continue;}const _0x22dcef=_0x5639f6['get'](_0x8bbabb[_0x23c4fe]['pairId']),_0x54544f=_0x5639f6['get'](_0x8bbabb[_0x23c4fe]['id']);_0x8bbabb[_0x23c4fe]['distance']=_0x22dcef-_0x54544f;}}['_getRevisionsRange'](_0x16be83,_0x311885,_0x3cff5e=!0x1){const _0x75b2bc=[];let _0x182b90=this['repository']['getIndex'](_0x16be83),_0x53a8ab=this['repository']['getIndex'](_0x311885);for(-0x1==_0x53a8ab&&(_0x53a8ab=this['repository']['_revisions']['length'],_0x3cff5e=!0x1);_0x182b90<_0x53a8ab;)_0x75b2bc['push'](this['repository']['getRevision'](_0x182b90)),_0x182b90++;return _0x3cff5e&&_0x75b2bc['push'](this['repository']['getRevision'](_0x182b90)),_0x75b2bc;}['_threeWayMerge'](_0x1c9716,_0x3e3d7e,_0x4087b1,_0x1dde4d){const _0x12143d=this['editor']['model']['schema'];let _0x304a56=_0x3e3d7e;for(;_0x1c9716[_0x304a56]&&_0x1c9716[_0x304a56]['isAdded'];)_0x304a56++;let _0x2a56d5=_0x1dde4d;for(;_0x4087b1[_0x2a56d5]&&_0x4087b1[_0x2a56d5]['isRemoved'];)_0x2a56d5++;_0x451114(_0x1c9716,_0x3e3d7e,_0x304a56),_0x451114(_0x4087b1,_0x1dde4d,_0x2a56d5);const _0x526dde=_0x4087b1['slice'](_0x1dde4d,_0x2a56d5)['concat'](_0x1c9716['slice'](_0x3e3d7e,_0x304a56));return _0x526dde['sort']((_0x2ea9d9,_0x3c8618)=>_0x2ea9d9['side']!=_0x3c8618['side']?_0x2ea9d9['side']-_0x3c8618['side']:_0x2ea9d9['level']!=_0x3c8618['level']?_0x2ea9d9['level']-_0x3c8618['level']:_0x2ea9d9['distance']!=_0x3c8618['distance']?_0x3c8618['distance']-_0x2ea9d9['distance']:!!_0x2ea9d9['isAdded']!=!!_0x3c8618['isAdded']?-0x1==_0x2ea9d9['side']||0x0==_0x2ea9d9['side']?_0x2ea9d9['isAdded']?-0x1:0x1:_0x2ea9d9['isAdded']?0x1:-0x1:_0x2ea9d9['index']-_0x3c8618['index']),{'commonTape':_0x526dde,'iEnd':_0x304a56,'jEnd':_0x2a56d5};function _0x451114(_0x5317da,_0x3460f0,_0x302e93){let _0x152391=-0x1,_0x144d20=Number['POSITIVE_INFINITY'],_0x1d8d59=!0x0;for(let _0x5bedfe=_0x3460f0;_0x5bedfe<_0x302e93;_0x5bedfe++)if(_0x12143d['isInline'](_0x5317da[_0x5bedfe]['item'])||(_0x1d8d59=!0x1),_0x5317da[_0x5bedfe]['item']['startIndex']<_0x3460f0&&(_0x152391=_0x5bedfe),_0x5317da[_0x5bedfe]['item']['endIndex']>=_0x302e93){_0x144d20=_0x5bedfe;break;}_0x1d8d59&&(_0x152391=_0x302e93-0x1);for(let _0x3d38c8=_0x3460f0;_0x3d38c8<_0x302e93;_0x3d38c8++)_0x5317da[_0x3d38c8]['side']=_0x3d38c8<=_0x152391?-0x1:_0x3d38c8<_0x144d20?0x0:0x1,_0x5317da[_0x3d38c8]['index']=_0x3d38c8;let _0x3f0e57=0x0;for(let _0x4dd511=_0x3460f0;_0x4dd511<=_0x152391;_0x4dd511++)0x0==_0x5317da[_0x4dd511]['distance']?_0x5317da[_0x4dd511]['level']=_0x3f0e57:(_0x3f0e57++,_0x5317da[_0x4dd511]['level']=_0x3f0e57,_0x3f0e57++);for(let _0xc8b0fa=_0x3460f0;_0xc8b0fa<_0x302e93;_0xc8b0fa++)0x0==_0x5317da[_0xc8b0fa]['side']&&(_0x5317da[_0xc8b0fa]['level']=_0x3f0e57);_0x3f0e57=0x0;for(let _0x55948f=_0x302e93-0x1;_0x55948f>=_0x144d20;_0x55948f--)0x0==_0x5317da[_0x55948f]['distance']?_0x5317da[_0x55948f]['level']=_0x3f0e57:(_0x3f0e57--,_0x5317da[_0x55948f]['level']=_0x3f0e57,_0x3f0e57--);}}['_fixObsoleteTags'](_0xd9debd){const _0x105045=new Map(),_0x529ad0=this['editor']['model']['schema'];for(let _0x2fa9e1=0x1;_0x2fa9e1<_0xd9debd['length'];_0x2fa9e1++){let _0x1a99f4,_0x239578,_0x2d1d77;const _0x480643=_0xd9debd[_0x2fa9e1],_0x47b77c=_0xd9debd[_0x2fa9e1-0x1];if('text'==_0x480643['type'])continue;if(_0x480643['type']!=_0x47b77c['type'])continue;if(!_0x529ad0['isBlock'](_0x47b77c['item'])||_0x529ad0['isLimit'](_0x47b77c['item']))continue;if(!_0x529ad0['isBlock'](_0x480643['item'])||_0x529ad0['isLimit'](_0x480643['item']))continue;if((_0xd9debd[_0x2fa9e1]['isAdded']||_0xd9debd[_0x2fa9e1]['isAddSuggestion'])&&_0xd9debd[_0x2fa9e1-0x1]['isRemoved'])_0x1a99f4=_0xd9debd[_0x2fa9e1],_0x239578=_0xd9debd[_0x2fa9e1-0x1],_0x2d1d77=_0x2fa9e1-0x1;else{if(!_0xd9debd[_0x2fa9e1]['isRemoved']||!_0xd9debd[_0x2fa9e1-0x1]['isAdded']&&!_0xd9debd[_0x2fa9e1-0x1]['isAddSuggestion'])continue;_0x1a99f4=_0xd9debd[_0x2fa9e1-0x1],_0x239578=_0xd9debd[_0x2fa9e1],_0x2d1d77=_0x2fa9e1;}const _0x518228=_0x1a99f4['level']==_0x239578['level'],_0x1ac72d=Math['abs'](_0x1a99f4['level'])<Math['abs'](_0x239578['level'])&&0x0==_0x239578['distance'];(_0x518228||_0x1ac72d)&&(_0x105045['set'](_0x239578['id'],_0x1a99f4['id']),_0xd9debd['splice'](_0x2d1d77,0x1),_0x2fa9e1--,_0x1a99f4['isAdded']=!0x1);}for(let _0x19e971=0x0;_0x19e971<_0xd9debd['length'];_0x19e971++)_0x105045['has'](_0xd9debd[_0x19e971]['pairId'])&&(_0xd9debd[_0x19e971]['pairId']=_0x105045['get'](_0xd9debd[_0x19e971]['pairId']));}['_removeMissingPairs'](_0x46ff75){const _0x5dbb81=new Set(_0x46ff75['map'](_0x50f151=>_0x50f151['id']));for(let _0xf5967e=0x0;_0xf5967e<_0x46ff75['length'];_0xf5967e++)_0x5dbb81['has'](_0x46ff75[_0xf5967e]['pairId'])||0x0==_0x46ff75[_0xf5967e]['distance']||(_0x46ff75[_0xf5967e]['isIncorrect']=!0x0);return _0x46ff75['filter'](_0x3f84bb=>!_0x3f84bb['isIncorrect']);}['_markMismatchedRemovedTags'](_0x248b0d){const _0x58e890=new Set();for(let _0x530c4e=0x0;_0x530c4e<_0x248b0d['length'];_0x530c4e++){if(_0x58e890['has'](_0x248b0d[_0x530c4e]['id'])&&_0x248b0d[_0x530c4e]['isRemoved']&&(_0x248b0d[_0x530c4e]['isIncorrect']=!0x0),_0x248b0d[_0x530c4e]['isIncorrect'])continue;if(0x0==_0x248b0d[_0x530c4e]['distance'])continue;if('elementStart'!=_0x248b0d[_0x530c4e]['type'])continue;if(null==_0x248b0d[_0x530c4e]['pairId'])continue;let _0x191e39=_0x530c4e+0x1,_0x43f106=0x0;for(;_0x248b0d[_0x191e39]['id']!=_0x248b0d[_0x530c4e]['pairId'];)'elementStart'==_0x248b0d[_0x191e39]['type']?_0x43f106++:'elementEnd'==_0x248b0d[_0x191e39]['type']&&_0x43f106--,_0x191e39++;if(0x0!=_0x43f106){if(_0x248b0d[_0x530c4e]['isRemoved'])_0x248b0d[_0x530c4e]['isIncorrect']=!0x0;else{for(;_0x191e39!=_0x530c4e;)_0x248b0d[_0x191e39]['isRemoved']&&0x0!=_0x248b0d[_0x191e39]['distance']&&(_0x248b0d[_0x191e39]['isIncorrect']=!0x0,_0x58e890['add'](_0x248b0d[_0x191e39]['pairId'])),_0x191e39--;}}}return _0x248b0d['filter'](_0x5bb8c1=>!_0x5bb8c1['isIncorrect']);}['_removeUnsupportedChanges'](_0x2abddc){const _0x57aecd=this['editor']['model']['schema'];for(let _0x42ec39=0x0;_0x42ec39<_0x2abddc['length'];_0x42ec39++){if(!(_0x2abddc[_0x42ec39]['isAdded']||_0x2abddc[_0x42ec39]['isAddSuggestion']||_0x2abddc[_0x42ec39]['isRemoved']||_0x2abddc[_0x42ec39]['isRemoveSuggestion']))continue;if(0x0==_0x2abddc[_0x42ec39]['distance'])continue;const _0x183b20=_0x2abddc[_0x42ec39]['item'];_0x57aecd['isBlock'](_0x183b20)||_0x57aecd['isLimit'](_0x183b20)||(_0x2abddc[_0x42ec39]['isAdded']&&delete _0x2abddc[_0x42ec39]['isAdded'],_0x2abddc[_0x42ec39]['isAddSuggestion']&&delete _0x2abddc[_0x42ec39]['isAddSuggestion'],_0x2abddc[_0x42ec39]['isRemoveSuggestion']&&delete _0x2abddc[_0x42ec39]['isRemoveSuggestion'],_0x2abddc[_0x42ec39]['isRemoved']&&(_0x2abddc[_0x42ec39]['isIncorrect']=!0x0));}return _0x2abddc['filter'](_0x1b0c38=>!_0x1b0c38['isIncorrect']);}['_makeModelFromTape'](_0x3f7562,_0x23eb3f,_0x143207){const _0x151d12=new vt(),_0x3aeb88=[],_0x35117e=new Map(),_0xf5b5e4=this['editor']['model'],_0x560085=_0xf5b5e4['schema'],_0x8e7d06=[_0x151d12],_0x3c67fe={},_0x2a13a8={'isAdded':[],'isRemoved':[],'isAddSuggestion':[],'isRemoveSuggestion':[]};let _0x3743be=null;const _0x54837e=[0x0];for(let _0x3d63dd=0x0;_0x3d63dd<_0x3f7562['length'];_0x3d63dd++)if('elementStart'===_0x3f7562[_0x3d63dd]['type']){_0x3f7562[_0x3d63dd]['previousPosition']=_0xf5b5e4['createPositionFromPath'](_0x151d12,_0x54837e);const _0x5e42cd=new ut(_0x3f7562[_0x3d63dd]['item']['name'],_0x3f7562[_0x3d63dd]['item']['getAttributes']());_0x8e7d06[0x0]['_appendChild'](_0x5e42cd),_0x54837e['push'](0x0),_0x8e7d06['unshift'](_0x5e42cd),_0x3f7562[_0x3d63dd]['nextPosition']=_0xf5b5e4['createPositionFromPath'](_0x151d12,_0x54837e);}else'elementEnd'===_0x3f7562[_0x3d63dd]['type']?(_0x8e7d06['shift'](),_0x3f7562[_0x3d63dd]['previousPosition']=_0xf5b5e4['createPositionFromPath'](_0x151d12,_0x54837e),_0x54837e['pop'](),_0x54837e[_0x54837e['length']-0x1]++,_0x3f7562[_0x3d63dd]['nextPosition']=_0xf5b5e4['createPositionFromPath'](_0x151d12,_0x54837e)):(_0x3f7562[_0x3d63dd]['previousPosition']=_0xf5b5e4['createPositionFromPath'](_0x151d12,_0x54837e),_0x3743be?_0x3743be['_data']+=_0x3f7562[_0x3d63dd]['item']['data']:_0x3743be=new gt(_0x3f7562[_0x3d63dd]['item']['data'],_0x3f7562[_0x3d63dd]['item']['getAttributes']()),_0x3f7562[_0x3d63dd+0x1]&&'text'===_0x3f7562[_0x3d63dd+0x1]['type']&&_0x4c0ccb(_0x3743be,_0x3f7562[_0x3d63dd+0x1]['item'])||(_0x8e7d06[0x0]['_appendChild'](_0x3743be),_0x3743be=null),_0x54837e[_0x54837e['length']-0x1]+=_0x3f7562[_0x3d63dd]['item']['offsetSize'],_0x3f7562[_0x3d63dd]['nextPosition']=_0xf5b5e4['createPositionFromPath'](_0x151d12,_0x54837e));for(let _0xf21e46=0x0;_0xf21e46<_0x3f7562['length'];_0xf21e46++){const _0x5788d4=_0x3f7562[_0xf21e46]['previousPosition'],_0x4dc3b5=_0x3f7562[_0xf21e46]['nextPosition'];for(const _0x1b51d7 of _0x3f7562[_0xf21e46]['markersStart'])_0x35117e['set'](_0x1b51d7,{'start':_0x5788d4,'end':null});_0x5bcd17('isRemoveSuggestion',_0xf21e46,_0x5788d4,_0x4dc3b5),_0x5bcd17('isAddSuggestion',_0xf21e46,_0x5788d4,_0x4dc3b5),_0x5bcd17('isRemoved',_0xf21e46,_0x5788d4,_0x4dc3b5),_0x5bcd17('isAdded',_0xf21e46,_0x5788d4,_0x4dc3b5);for(const _0x2f92c7 of _0x3f7562[_0xf21e46]['markersEnd']){const _0x135ee9=_0x35117e['get'](_0x2f92c7);_0x135ee9?_0x135ee9['end']=_0x4dc3b5:_0x35117e['set'](_0x2f92c7,{'start':_0x4dc3b5,'end':_0x4dc3b5});}}for(const [_0x3747cc,_0xc0a788]of _0x35117e){const _0x1842ed=this['editor']['model']['createRange'](_0xc0a788['start'],_0xc0a788['end']);_0x151d12['markers']['set'](_0x3747cc,_0x1842ed);}return _0x3aeb88['sort']((_0x456519,_0x394ccd)=>{const _0x3a70ed=_0x151d12['markers']['get']('revision:'+_0x456519['id']),_0x77c2be=_0x151d12['markers']['get']('revision:'+_0x394ccd['id']);return _0x3a70ed['start']['isBefore'](_0x77c2be['start'])?-0x1:_0x3a70ed['start']['isAfter'](_0x77c2be['start'])?0x1:_0x3a70ed['end']['isBefore'](_0x77c2be['end'])?-0x1:_0x3a70ed['end']['isAfter'](_0x77c2be['end'])?0x1:'add'===_0x456519['type']?-0x1:0x1;}),{'root':_0x151d12,'changes':_0x3aeb88};function _0x5bcd17(_0x18732e,_0x24551e,_0x4e41ad,_0x41445d){const _0x364a85=!!_0x3f7562[_0x24551e][_0x18732e],_0xad2f00=_0x364a85?_0x3f7562[_0x24551e][_0x18732e]['userId']:null,_0xf51c7=_0x24551e===_0x3f7562['length']-0x1,_0xcbdff9=_0x2a13a8[_0x18732e][0x0],_0x4229bc=_0x560085['isObject'](_0x3f7562[_0x24551e]['item']);!_0x3c67fe[_0x18732e]&&_0x364a85?_0x3c67fe[_0x18732e]={'start':_0x4e41ad,'tapeItem':_0x3f7562[_0x24551e],'userId':_0xad2f00,'type':_0x18732e}:_0x3c67fe[_0x18732e]&&!_0x364a85?(_0x3c67fe[_0x18732e]['end']=_0x4e41ad,_0x43c296(_0x3c67fe[_0x18732e]),_0x3c67fe[_0x18732e]=null):_0x3c67fe[_0x18732e]&&_0x364a85&&_0x3c67fe[_0x18732e]['userId']!==_0xad2f00&&(_0x3c67fe[_0x18732e]['end']=_0x4e41ad,_0xcbdff9&&_0xcbdff9['userId']===_0x3c67fe[_0x18732e]['userId']||_0x43c296(_0x3c67fe[_0x18732e]),_0x3c67fe[_0x18732e]={'start':_0x4e41ad,'tapeItem':_0x3f7562[_0x24551e],'userId':_0xad2f00,'type':_0x18732e}),_0x3c67fe[_0x18732e]&&_0x4229bc&&('elementStart'!==_0x3f7562[_0x24551e]['type']||_0xcbdff9&&_0xcbdff9['userId']===_0xad2f00||_0x2a13a8[_0x18732e]['unshift']({'userId':_0xad2f00,'object':_0x3f7562[_0x24551e]['item'],'change':_0x3c67fe[_0x18732e]}),'elementEnd'===_0x3f7562[_0x24551e]['type']&&_0xcbdff9&&_0xcbdff9['object']===_0x3f7562[_0x24551e]['item']&&(_0x2a13a8[_0x18732e]['shift'](),_0x3c67fe[_0x18732e]=_0xcbdff9['change'])),_0x3c67fe[_0x18732e]&&_0xf51c7&&(_0x3c67fe[_0x18732e]['end']=_0x41445d,_0x43c296(_0x3c67fe[_0x18732e]),_0x3c67fe[_0x18732e]=null);}function _0x43c296({start:_0x1efc5d,end:_0x1ca768,tapeItem:_0x293957,userId:_0x45518e,type:_0x29f0d6}){const _0x2c47fb=_0x293957['item'],_0x4d4d1b=_0xf5b5e4['schema']['isBlock'](_0x2c47fb)&&!_0xf5b5e4['schema']['isLimit'](_0x2c47fb),_0x4e81c0=_0x1efc5d['nodeAfter']==_0x1ca768['parent']&&_0x1ca768['isAtStart'];if(_0x4d4d1b&&_0x4e81c0)return;const _0x191b73=_0xf5b5e4['createRange'](_0x1efc5d,_0x1ca768),_0x4dbc8a=_0x23eb3f['get'](_0x45518e),_0x275ab6=new r({'author':_0x4dbc8a,'type':'isAdded'==_0x29f0d6||'isAddSuggestion'==_0x29f0d6?'add':'remove','data':{'isSuggestion':'isAddSuggestion'==_0x29f0d6||'isRemoveSuggestion'==_0x29f0d6},'createdAt':new Date(),'rootName':_0x143207});_0x3aeb88['push'](_0x275ab6),_0x151d12['markers']['set']('revision:'+_0x275ab6['id'],_0x191b73);}function _0x4c0ccb(_0x12f5e5,_0x89ada0){const _0x4228a3=_0x12f5e5['getAttributes'](),_0x238d33=_0x89ada0['getAttributes']();for(const _0x52de44 of _0x4228a3){if(_0x52de44[0x1]!==_0x89ada0['getAttribute'](_0x52de44[0x0]))return!0x1;_0x238d33['next']();}return _0x238d33['next']()['done'];}}['_setConversion'](){this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision','view':_0x19ee1e=>{const _0x5c7900=_0x19ee1e['markerName']['split'](':')[0x1],_0x2bd676=this['_getChangeFromId'](_0x5c7900);if(!_0x2bd676)return null;const _0x5b6477='add'==_0x2bd676['type']?'insertion':'deletion',_0x3500a1=['ck-suggestion-marker','ck-suggestion-marker-'+_0x5b6477];return _0x2bd676['data']['isSuggestion']&&_0x3500a1['push']('ck-suggestion-marker-'+_0x5b6477+'-new'),this['activeChange']==_0x2bd676&&_0x3500a1['push']('ck-suggestion-marker--active'),{'classes':_0x3500a1,'attributes':{'data-change-id':_0x5c7900}};}}),this['editor']['conversion']['for']('upcast')['add'](_0x4824ab=>{_0x4824ab['on']('element:pre',(_0x11bd80,_0x4f35af,_0x1c50ff)=>{const _0x3e9681=_0x4f35af['viewItem']['getChild'](0x0);if(!_0x3e9681||!_0x3e9681['is']('element','code'))return;if(!_0x1c50ff['consumable']['consume'](_0x3e9681,{'attributes':['vid_start','vid_end']}))return;const _0x137e81=_0x4f35af['modelRange']['start']['nodeAfter'];_0x1c50ff['writer']['setAttribute']('vid_start',_0x3e9681['getAttribute']('vid_start'),_0x137e81),_0x1c50ff['writer']['setAttribute']('vid_end',_0x3e9681['getAttribute']('vid_end'),_0x137e81);},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['add'](_0x84d0ed=>{_0x84d0ed['on']('element',(_0x3c5390,_0x2c312c,_0x31232a)=>{if(!_0x31232a['consumable']['consume'](_0x2c312c['viewItem'],{'attributes':['vid_start','vid_end']}))return;if(_0x2c312c['modelRange']['isCollapsed'])return;const _0x2dd689=_0x2c312c['modelRange']['start']['nodeAfter'];_0x2dd689['hasAttribute']('vid_start')||_0x2dd689['hasAttribute']('vid')||(_0x31232a['writer']['setAttribute']('vid_start',_0x2c312c['viewItem']['getAttribute']('vid_start'),_0x2dd689),_0x31232a['writer']['setAttribute']('vid_end',_0x2c312c['viewItem']['getAttribute']('vid_end'),_0x2dd689));},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['elementToAttribute']({'view':{'name':'span','attributes':{'vid':!0x0}},'model':{'key':'vid','value':_0x445c94=>_0x445c94['getAttribute']('vid')}}),this['editor']['model']['schema']['on']('checkAttribute',(_0x260db8,[,_0x47a412])=>{['vid_start','vid_end','vid']['includes'](_0x47a412)&&(_0x260db8['return']=!0x0,_0x260db8['stop']());},{'priority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x420443=>{_0x420443['on']('attribute:vid',(_0x495cdd,_0x38335b,_0x33c914)=>{if('\x20'!=_0x38335b['item']['data']||_0x38335b['item']['parent']['maxOffset']>0x1)return;if(!_0x33c914['consumable']['consume'](_0x38335b['item'],_0x495cdd['name']))return;const _0xb93330=_0x33c914['writer'],_0x4d9de8=_0x33c914['mapper']['toViewRange'](_0x38335b['range']);_0xb93330['wrap'](_0x4d9de8,_0xb93330['createAttributeElement']('span'));});}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',function(_0x483270){const _0x7aa25=_0x483270['plugins']['get']('RevisionViewer');return(_0x230de1,_0x127844,_0xab4679)=>{const _0x416026=_0x127844['markerName']['split'](':')[0x1],_0x1935c8=_0x7aa25['_getChangeFromId'](_0x416026);if(!_0x1935c8)return null;const _0x7f9884='add'==_0x1935c8['type']?'split':'merge';if(!_0xab4679['consumable']['test'](_0x127844['markerRange'],_0x230de1['name']))return;const _0x502168=_0x127844['markerRange']['getWalker'](),_0x529961=_0x127844['markerRange']['start'],_0x55990e=_0x483270['model']['schema'];let _0x46f768=null,_0x145a3e=null,_0x55ceee=!0x1,_0x53cb8b=!0x1;for(const _0x41324f of _0x502168){const _0x558522=_0x41324f['item'];_0x55ceee=_0x55ceee||_0x55990e['isContent'](_0x558522);const _0x34c5b5=_0xab4679['mapper']['toViewElement'](_0x558522);if(_0x34c5b5&&_0x34c5b5['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x41324f['type']&&(_0x55990e['isBlock'](_0x558522)&&!_0x55990e['isLimit'](_0x558522)&&(_0x558522['nextSibling']||_0x529961['isAtEnd']?_0x46f768&&_0x46f768['parent']==_0x558522||(_0x46f768=_0x558522,_0x185ac8(_0x41324f['previousPosition']),_0x53cb8b=!0x0):_0x145a3e=_0x145a3e||_0x41324f['previousPosition']));}function _0x185ac8(_0x298851){const _0x106e81=_0xab4679['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x7f9884}),_0x5a1999=_0xab4679['mapper']['toViewPosition'](_0x298851);_0x1935c8['data']['isSuggestion']&&_0xab4679['writer']['addClass']('ck-suggestion-marker-'+_0x7f9884+'-new',_0x106e81),_0x7aa25['activeChange']==_0x1935c8&&_0xab4679['writer']['addClass']('ck-suggestion-marker--active',_0x106e81),_0xab4679['writer']['insert'](_0x5a1999,_0x106e81),_0xab4679['mapper']['bindElementToMarker'](_0x106e81,_0x127844['markerName']);}_0x55ceee||_0x53cb8b||!_0x145a3e||_0x185ac8(_0x145a3e);};}(this['editor']),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision',(_0x5d02ff,_0x12191e,_0xe8fe5b)=>{const _0x599273=_0xe8fe5b['mapper']['markerNameToElements'](_0x12191e['markerName']);if(_0x599273){for(const _0x2ebf7c of _0x599273)(_0x2ebf7c['hasClass']('ck-suggestion-marker-split')||_0x2ebf7c['hasClass']('ck-suggestion-marker-merge'))&&(_0xe8fe5b['mapper']['unbindElementFromMarkerName'](_0x2ebf7c,_0x12191e['markerName']),_0xe8fe5b['writer']['remove'](_0x2ebf7c));}},{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',(_0x48a434,_0x343fe1,_0x42caba)=>{const _0x1effbe=_0x343fe1['markerName']['split'](':')[0x1],_0x3d773f=this['_getChangeFromId'](_0x1effbe);if(!_0x3d773f)return null;const _0x2f891a='add'==_0x3d773f['type']?'split':'merge';if(_0x42caba['consumable']['test'](_0x343fe1['markerRange'],_0x48a434['name']))for(const _0x1da1aa of _0x343fe1['markerRange']['getItems']()){if(!_0x1da1aa['is']('element','softBreak'))continue;const _0x3707f1=_0x42caba['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x2f891a}),_0xd78664=_0x42caba['mapper']['toViewPosition'](this['editor']['model']['createPositionBefore'](_0x1da1aa));_0x3d773f['data']['isSuggestion']&&_0x42caba['writer']['addClass']('ck-suggestion-marker-'+_0x2f891a+'-new',_0x3707f1),this['activeChange']==_0x3d773f&&_0x42caba['writer']['addClass']('ck-suggestion-marker--active',_0x3707f1),_0x42caba['writer']['insert'](_0xd78664,_0x3707f1),_0x42caba['mapper']['bindElementToMarker'](_0x3707f1,_0x343fe1['markerName']);}},{'priority':'high'}),this['editor']['model']['document']['on']('change',()=>{this['editor']['editing']['view']['change'](_0x24e090=>{for(const _0x185da5 of this['editor']['model']['document']['getRootNames']()){const _0x18e89f=this['editor']['model']['document']['getRoot'](_0x185da5),_0x1ae68b=this['editor']['editing']['view']['document']['getRoot'](_0x185da5);if(_0x1ae68b){const _0x24e1b1=_0x18e89f['getAttribute']('revisionHistoryAttachChange');if(_0x24e090['removeAttribute']('data-change-id',_0x1ae68b),_0x24e090['removeClass']('ck-revision-history-root-add',_0x1ae68b),_0x24e090['removeClass']('ck-revision-history-root-remove',_0x1ae68b),_0x24e090['removeClass']('ck-revision-history-root--active',_0x1ae68b),_0x24e1b1){const _0x419491=this['_getChangeFromId'](_0x24e1b1);if(!_0x419491)return null;_0x24e090['setAttribute']('data-change-id',_0x24e1b1,_0x1ae68b),_0x24e090['addClass']('ck-revision-history-root-'+_0x419491['type'],_0x1ae68b),this['activeChange']==_0x419491&&_0x24e090['addClass']('ck-revision-history-root--active',_0x1ae68b);}}}});}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'comment','model':_0x60017e=>'revision-comment:'+_0x60017e,'converterPriority':'highest'}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'suggestion','model':_0x5b637f=>'revision-suggestion:'+_0x5b637f,'converterPriority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision-suggestion','view':_0x51842d=>({'name':'suggestion:'+_0x51842d,'group':'revision-suggestion'}),'converterPriority':'highest'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision-suggestion','view':_0x2ee28b=>{const _0x129f69=_0x2ee28b['markerName']['split'](':')[0x1];return'insertion'!=_0x129f69&&'deletion'!=_0x129f69?null:{'classes':['ck-suggestion-preview-marker','ck-suggestion-preview-marker-'+_0x129f69]};}}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:deletion',X(this['editor'],'merge'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:insertion',X(this['editor'],'split'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision-suggestion',(_0x3aee48,_0xff0ec8,_0x47a6c3)=>{const _0x2fec9d=_0x47a6c3['mapper']['markerNameToElements'](_0xff0ec8['markerName']);if(_0x2fec9d){for(const _0x311828 of _0x2fec9d)_0x311828['is']('uiElement')&&(_0x47a6c3['mapper']['unbindElementFromMarkerName'](_0x311828,_0xff0ec8['markerName']),_0x47a6c3['writer']['remove'](_0x311828));}},{'priority':'high'});}['_getChangeFromId'](_0x2e3588){return this['_changeIdToChange']['get'](_0x2e3588);}['_getViewForChange'](_0x2fb7e5){return this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=new Q(this['editor']['locale'],_0x2fb7e5),this['_changeView'];}['_initInteractions'](){this['editor']['model']['document']['selection']['observeMarkers']('revision'),this['on']('change:activeView',(_0x2da9d8,_0x425b06,_0x2db7a0,_0x12efc3)=>{_0x12efc3&&this['_balloon']['remove'](_0x12efc3),_0x2db7a0&&(this['_balloon']['add']({'view':_0x2db7a0,'stackId':'revisionHistoryLabel','position':{'target':()=>{const _0x321ec0=this['editor']['editing'],_0x5b3d35=this['_getChangeFromId'](_0x2db7a0['changeId']);let _0x79c1aa;if(_0x5b3d35['data']['isOnRoot']){const _0x4fc078=_0x321ec0['view']['getDomRoot'](_0x5b3d35['rootName']);_0x79c1aa=Array['from'](_0x4fc078['getClientRects']());}else{const _0x48e1c6=this['editor']['model']['markers']['get']('revision:'+_0x2db7a0['changeId']);_0x79c1aa=Array['from'](_0x321ec0['mapper']['markerNameToElements'](_0x48e1c6['name']))['map'](_0x4f49b4=>_0x321ec0['view']['domConverter']['mapViewToDom'](_0x4f49b4))['map'](_0x355d99=>Array['from'](_0x355d99['getClientRects']()))['flat']();}if(!this['_activeViewTarget'])return _0x79c1aa[0x0];return _0x79c1aa['find'](_0x361c51=>_0x361c51['top']-0x3<=this['_activeViewTarget']['y']&&_0x361c51['bottom']+0x3>=this['_activeViewTarget']['y']&&_0x361c51['left']-0x3<=this['_activeViewTarget']['x']&&_0x361c51['right']+0x3>=this['_activeViewTarget']['x'])||_0x79c1aa[0x0];}}}),this['_balloon']['showStack']('revisionHistoryLabel'));}),this['on']('change:activeChange',(_0x2e04b6,_0x5020e8,_0x2b29d4,_0x11e7a8)=>{this['activeView']=_0x2b29d4?this['_getViewForChange'](_0x2b29d4):null,this['editor']['model']['change'](()=>{const _0x58a153=this['editor']['editing'];_0x11e7a8&&(_0x11e7a8['data']['isOnRoot']?_0x58a153['view']['change'](_0x2c9dc8=>{_0x2c9dc8['removeClass']('ck-revision-history-root--active',_0x58a153['view']['document']['getRoot'](_0x11e7a8['rootName']));}):_0x58a153['reconvertMarker']('revision:'+_0x11e7a8['id'])),_0x2b29d4&&(_0x2b29d4['data']['isOnRoot']?_0x58a153['view']['change'](_0x1e0f69=>{_0x1e0f69['addClass']('ck-revision-history-root--active',_0x58a153['view']['document']['getRoot'](_0x2b29d4['rootName']));}):_0x58a153['reconvertMarker']('revision:'+_0x2b29d4['id']));});}),this['listenTo'](this['editor']['editing']['view']['document'],'mouseover',(_0x18d2e7,_0x6f672d)=>{if(this['activeChange'])return;const _0x4876f5=this['_findChangeIdFromDomTarget'](_0x6f672d['target']),_0x396141=this['_changeIdToChange']['get'](_0x4876f5);_0x396141?(this['_activeViewTarget']={'x':_0x6f672d['domEvent']['x'],'y':_0x6f672d['domEvent']['y']},this['activeView']=this['_getViewForChange'](_0x396141)):(this['_activeViewTarget']=null,this['activeView']=null);}),this['listenTo'](this['editor']['editing']['view']['document'],'mousedown',(_0x127d79,_0x446ac1)=>{const _0x5a3d4b=this['_findChangeIdFromDomTarget'](_0x446ac1['target']),_0x3c11e9=this['_changeIdToChange']['get'](_0x5a3d4b);_0x3c11e9?(this['_activeViewTarget']={'x':_0x446ac1['domEvent']['x'],'y':_0x446ac1['domEvent']['y']},_0x3c11e9===this['activeChange']?this['_balloon']['updatePosition']():this['activeChange']=_0x3c11e9):(this['_activeViewTarget']=null,this['activeChange']=null);});}['_findChangeIdFromDomTarget'](_0x3b9f23){do{const _0xeeaa06=_0x3b9f23['getAttribute']('data-change-id');if(_0xeeaa06)return _0xeeaa06;_0x3b9f23=_0x3b9f23['parent'];}while(_0x3b9f23);return null;}['_cleanMarkers'](){this['editor']['model']['change'](_0x37269d=>{for(const _0xfe84d5 of this['editor']['model']['markers'])_0x37269d['removeMarker'](_0xfe84d5);});}}function X(_0xbdb6fe,_0x695191){return(_0x33f52b,_0x4a71ce,_0x1517cc)=>{if(!_0x1517cc['consumable']['test'](_0x4a71ce['markerRange'],_0x33f52b['name']))return;const _0x4ced38=_0x4a71ce['markerRange']['getWalker'](),_0x1c08b1=_0x4a71ce['markerRange']['start'],_0x5f0c44=_0xbdb6fe['model']['schema'];let _0x500d17=null,_0x591a83=null,_0x553b71=!0x1,_0x1573c7=!0x1;for(const _0x37ea1b of _0x4ced38){const _0x6578ac=_0x37ea1b['item'];_0x553b71=_0x553b71||_0x5f0c44['isContent'](_0x6578ac);const _0x3ffd1a=_0x1517cc['mapper']['toViewElement'](_0x6578ac);if(_0x3ffd1a&&_0x3ffd1a['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x37ea1b['type']&&(_0x5f0c44['isBlock'](_0x6578ac)&&!_0x5f0c44['isLimit'](_0x6578ac)&&(_0x6578ac['nextSibling']||_0x1c08b1['isAtEnd']?_0x500d17&&_0x500d17['parent']==_0x6578ac||(_0x500d17=_0x6578ac,_0x356cee(_0x37ea1b['previousPosition']),_0x1573c7=!0x0):_0x591a83=_0x591a83||_0x37ea1b['previousPosition']));}function _0x356cee(_0x32b3b5){const _0x4a0370=_0x1517cc['mapper']['toViewPosition'](_0x32b3b5),_0x480153=_0x1517cc['writer']['createUIElement']('span',{'class':'ck-suggestion-preview-marker-'+_0x695191});_0x1517cc['writer']['insert'](_0x4a0370,_0x480153),_0x1517cc['mapper']['bindElementToMarker'](_0x480153,_0x4a71ce['markerName']);}_0x553b71||_0x1573c7||!_0x591a83||_0x356cee(_0x591a83);};}class mt extends _0x4ad7f3{constructor(_0x3ead89){super(_0x3ead89);const _0x56a9c9=_0x3ead89['plugins']['get'](m);this['affectsData']=!0x1,this['listenTo'](_0x56a9c9,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x56a9c9,'change:isEnabled',()=>this['refresh']());}['execute'](){const _0x57f1cb=this['editor'],_0x3415f5=_0x57f1cb['plugins']['get'](m),_0x2e1533=_0x3415f5['isReady']?_0x3415f5['diff']['newRevisionId']:null;_0x57f1cb['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x2e1533);}['refresh'](){const {isReady:_0x366627,isEnabled:_0xc8083a,repository:_0x445ae9,diff:_0x1d0a02}=this['editor']['plugins']['get'](m),_0x16d9d7=_0x1d0a02&&_0x445ae9['getLaterVisibleRevision'](_0x1d0a02['newRevisionId']);this['isEnabled']=_0x366627&&_0xc8083a&&Boolean(_0x16d9d7);}}class wt extends _0x4ad7f3{['_step'];constructor(_0x2d3f7e,{direction:_0x4c5b68}){super(_0x2d3f7e);const _0x979913=_0x2d3f7e['plugins']['get'](m);this['affectsData']=!0x1,this['_step']='forward'===_0x4c5b68?0x1:-0x1,this['listenTo'](_0x979913,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x979913,'change:isEnabled',()=>this['refresh']()),this['listenTo'](_0x979913,'change:activeChange',()=>this['refresh']());}['execute'](){const _0x3791d7=this['editor'],_0x53d4ee=_0x3791d7['plugins']['get'](m),{isNavigationMode:_0x505623,currentChangeNumber:_0x2611cf}=_0x53d4ee;let _0xfdc57f;if(_0x53d4ee['activeChange']=_0x505623?_0x53d4ee['diff']['changes']['get'](_0x2611cf+this['_step']):_0x53d4ee['diff']['changes']['first'],_0x53d4ee['activeChange']['data']['isOnRoot'])_0xfdc57f=_0x3791d7['editing']['view']['getDomRoot'](_0x53d4ee['activeChange']['rootName']);else{const _0x1cd136=_0x3791d7['model']['markers']['get']('revision:'+_0x53d4ee['activeChange']['id']);_0xfdc57f=_0x286786(_0x3791d7['editing'],_0x1cd136);}_0xdb082a({'target':_0xfdc57f,'viewportOffset':0x28});}['refresh'](){const {isNavigationMode:_0x19c253,currentChangeNumber:_0x5cda0f,numberOfChanges:_0x71f495,isReady:_0x1e76b9,isEnabled:_0x253db4}=this['editor']['plugins']['get'](m);this['isEnabled']=!!(_0x253db4&&_0x1e76b9&&_0x71f495)&&(!_0x19c253||(0x1===this['_step']?_0x5cda0f<_0x71f495-0x1:_0x5cda0f>0x0));}}class _i extends ts{constructor(_0x1e0d1b){super(_0x1e0d1b);const _0x4d415c=this['bindTemplate'],_0x436111=new te(_0x1e0d1b),_0x121b6c=new te(_0x1e0d1b);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',(_0x277ff0,_0x2a7fa6)=>_0x277ff0&&_0x2a7fa6>0x0),this['bind']('_statusText')['to'](this,'isReady',this,'currentChangeNumber',this,'numberOfChanges',this,'isNavigationMode',(_0x49a9b8,_0x235ff8,_0x45f33d,_0x31c8ea)=>{if(!_0x49a9b8)return g(_0x1e0d1b,'Loading...');if(!_0x45f33d)return g(_0x1e0d1b,'No\x20changes');const _0x221aea=g(_0x1e0d1b,'NUMBER_OF_CHANGES',_0x45f33d);return _0x31c8ea?g(_0x1e0d1b,'X_OF_Y_CHANGES',[_0x235ff8+0x1,_0x45f33d]):_0x221aea;}),_0x436111['set']({'label':g(_0x1e0d1b,'Show\x20previous\x20change'),'tooltip':!0x0,'icon':_0x2858bc}),_0x121b6c['set']({'label':g(_0x1e0d1b,'Show\x20next\x20change'),'tooltip':!0x0,'icon':_0x1c5bf8}),_0x436111['bind']('isEnabled')['to'](this,'isBackwardNavigationEnabled'),_0x121b6c['bind']('isEnabled')['to'](this,'isForwardNavigationEnabled'),_0x436111['on']('execute',()=>this['fire']('execute','backward')),_0x121b6c['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',_0x4d415c['if']('_isStatusLabelVisible','ck-hidden',_0x1409d3=>!_0x1409d3)]},'children':[{'text':_0x4d415c['to']('isNavigationMode',_0x2d276a=>_0x2d276a?g(_0x1e0d1b,'EDIT_X_OF_Y_REVISIONS')+':\x20':g(_0x1e0d1b,'Total')+':\x20')}]},{'text':_0x4d415c['to']('_statusText')}]},new _0x4f8ba2(),{'tag':'div','attributes':{'class':['ck-revision-history-ui__changes-navigation__navigation']},'children':[_0x436111,_0x121b6c]}]});}}const le='ck-editor__editable__loading-overlay';class ge extends _0x443a46{static get['pluginName'](){return'RevisionViewerLoadingOverlay';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['show'](){const _0x1bbb3b=this['editor']['editing']['view'];_0x1bbb3b['change'](_0x17350d=>{for(const _0xbe14f8 of _0x1bbb3b['document']['roots'])_0x17350d['addClass'](le,_0xbe14f8);});}['hide'](){const _0x10cb46=this['editor']['editing']['view'];_0x10cb46['change'](_0x3fed70=>{for(const _0x542b27 of _0x10cb46['document']['roots'])_0x3fed70['removeClass'](le,_0x542b27);});}}class R extends _0x443a46{static get['pluginName'](){return'RevisionViewerUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[m,ge];}['init'](){const _0x1a2f4f=this['editor'],_0x5625b7=_0x1a2f4f['plugins']['get'](m),_0x53fcf6=_0x1a2f4f['plugins']['get'](ge);_0x1a2f4f['ui']['componentFactory']['add']('exitToEditing',_0x547f61=>{const _0x46625d=new te(_0x547f61);return _0x46625d['set']({'label':g(_0x547f61,'Back\x20to\x20editing'),'icon':_0x7b404c,'withText':!0x0,'tooltip':!0x0,'class':'ck-revision-history-ui__back-to-editing'}),this['listenTo'](_0x46625d,'execute',()=>{_0x1a2f4f['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}),_0x46625d;}),_0x1a2f4f['ui']['componentFactory']['add']('restoreRevision',_0x1e5add=>{const _0xf47fc1=new te(_0x1e5add);return _0xf47fc1['set']({'label':g(_0x1e5add,'Restore\x20this\x20revision'),'withText':!0x0,'tooltip':!0x0}),_0xf47fc1['bind']('isEnabled')['to'](_0x1a2f4f['commands']['get']('restoreRevision')),this['listenTo'](_0xf47fc1,'execute',()=>_0x1a2f4f['execute']('restoreRevision')),_0xf47fc1;}),_0x1a2f4f['ui']['componentFactory']['add']('changesNavigation',_0x1b18e1=>{const _0x32ae69=new _i(_0x1b18e1),_0x26d1b=_0x1a2f4f['commands']['get']('showPreviousChange'),_0x59185d=_0x1a2f4f['commands']['get']('showNextChange');return _0x32ae69['bind']('isBackwardNavigationEnabled')['to'](_0x26d1b,'isEnabled'),_0x32ae69['bind']('isForwardNavigationEnabled')['to'](_0x59185d,'isEnabled'),_0x32ae69['bind']('isReady','currentChangeNumber','numberOfChanges','isNavigationMode')['to'](_0x5625b7),this['listenTo'](_0x32ae69,'execute',(_0x313f3a,_0x3615c1)=>{_0x1a2f4f['execute']('forward'===_0x3615c1?'showNextChange':'showPreviousChange');}),_0x32ae69;}),_0x53fcf6['show'](),_0x5625b7['on']('change:isReady',(_0x45cef2,_0x2cffce,_0x1948d5)=>{_0x1948d5?_0x53fcf6['hide']():_0x53fcf6['show']();});}}class at extends _0x5d8229{['_resizeObserver']=null;constructor(_0x110419,_0x547c16){super(_0x110419,_0x547c16);const _0x186cf0=this['bindTemplate'];this['set']({'label':g(_0x110419,'Revision\x20name'),'_tooltipString':''}),this['fieldView']['placeholder']=g(_0x110419,'Enter\x20the\x20revision\x20name'),this['extendTemplate']({'tag':'span','attributes':{'class':['ck-revision-history-sidebar__revision-name'],'data-cke-tooltip-text':_0x186cf0['to']('_tooltipString'),'data-cke-tooltip-position':'s','data-cke-tooltip-class':'ck-tooltip_multi-line'}});}['render'](){super['render'](),this['_resizeObserver']=new nt(this['fieldView']['element'],()=>this['_updateTooltipText']()),this['listenTo'](this['fieldView'],'input',()=>this['_updateTooltipText']());}['destroy'](){super['destroy'](),this['_resizeObserver']&&this['_resizeObserver']['destroy']();}['_updateTooltipText'](){const _0x263feb=this['fieldView']['element'];this['_tooltipString']=_0x263feb['scrollWidth']>_0x263feb['clientWidth']&&_0x263feb['value']||'';}}class si extends ts{constructor(_0x71164a,_0x2597df,_0x25fd2f){super(_0x71164a);const _0x1aed1c=new _0x5c632d();_0x1aed1c['set']({'content':_0x461254,'viewBox':'0\x200\x2011\x2010'});const _0x2241cc=['ck','ck-revision-history-sidebar__revision-author'];_0x25fd2f&&_0x2241cc['push']('ck-revision-history-sidebar__revision-author_creator');const _0x4ec89b=[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision-author__name'],'title':g(_0x71164a,_0x25fd2f?'Revision\x20creator':'Revision\x20author')},'children':[_0x1aed1c,_0x2597df['name']]}];this['setTemplate']({'tag':'li','attributes':{'class':_0x2241cc},'children':_0x4ec89b});}}function oi(_0x30b947,_0x2ec505){const _0x1268b3=_0x30b947['bindTemplate'],_0xc1023=_0x30b947['locale'],_0x239cf8=_0x1429b9(_0xc1023);_0x239cf8['panelPosition']='sw';const _0x396eee=function(_0x3759b4,_0x55092b){const _0x216f65=function(_0x1c857d,_0x28d025){const _0x4d58f2=_0x1c857d['locale'],_0x2324b9={'Compare\x20against\x20selected':g(_0x4d58f2,'Compare\x20against\x20selected'),'Name\x20this\x20revision':g(_0x4d58f2,'Name\x20this\x20revision'),'Restore\x20this\x20revision':g(_0x4d58f2,'Restore\x20this\x20revision')};return _0x28d025['map'](_0x25d8f2=>{const _0x54bbd1=_0x2324b9[_0x25d8f2['name']];return _0x54bbd1&&_0x54bbd1!==_0x25d8f2['name']&&(_0x25d8f2['name']=_0x54bbd1),_0x25d8f2;});}(_0x3759b4,_0x55092b),_0x48bd67=new _0x239345();for(const _0x465280 of _0x216f65){const _0x86b2e8={'type':'button','model':new to({'label':_0x465280['name'],'class':_0x465280['class'],'withText':!0x0,'role':'menuitem','_action':_0x465280['action']})};_0x86b2e8['model']['bind']('isEnabled')['to'](_0x3759b4,'isActionsDropdownOpen',_0x24138b=>'function'!=typeof _0x465280['isEnabled']||(!_0x24138b||_0x465280['isEnabled'](_0x3759b4))),_0x48bd67['add'](_0x86b2e8);}return _0x48bd67;}(_0x30b947,_0x2ec505);return _0x30b947['bind']('isActionsDropdownOpen')['to'](_0x239cf8,'isOpen'),_0x239cf8['buttonView']['set']({'label':g(_0xc1023,'Show\x20more\x20items'),'tooltip':!0x0,'tooltipPosition':'sw','icon':_0x3a1eed}),_0x239cf8['extendTemplate']({'attributes':{'class':['ck-revision-history-sidebar__revision__actions',_0x1268b3['if']('isActionsDropdownOpen','ck-on')]},'on':{'click':_0x1268b3['to'](_0x405388=>_0x405388['stopPropagation']())}}),_0x239cf8['on']('execute',_0x451906=>{_0x30b947['isReady']&&'function'==typeof _0x451906['source']['_action']&&_0x451906['source']['_action'](_0x30b947);}),_0xc4778d(_0x239cf8,_0x396eee,{'role':'menu'}),_0x239cf8['listenTo'](_0x30b947,'change:isActionsDropdownOpen',(_0x437ac1,_0x1205a8,_0x5db9cd)=>{if(_0x5db9cd)for(const _0x1e30ad of _0x239cf8['listView']['items']){const _0x214487=_0x1e30ad['children']['first'],_0x3da42b=_0x2ec505['find'](_0x34ca86=>_0x34ca86['action']===_0x214487['_action'])['isVisible'];_0x1e30ad['isVisible']=void 0x0===_0x3da42b||_0x3da42b(_0x30b947);}}),_0x239cf8;}class hi extends/* #__PURE__ -- @preserve */
26
+ ti(ts){['id'];['revisionNameView'];['revisionActionsView'];['_revision'];['_requireRevisionName'];constructor(_0x2e947f,_0x3140ac,_0x511f9a,_0x20495e){super(_0x2e947f);const _0x3b56ba=this['bindTemplate'],_0x522bb7=function(_0x42e666,_0x98e617){const _0xc3b501=Array['from'](_0x98e617['authors'])['filter'](_0x1dc0a2=>_0x1dc0a2!=_0x98e617['creator']);return _0x98e617['creator']&&_0xc3b501['unshift'](_0x98e617['creator']),_0xc3b501['map'](_0x58868c=>new si(_0x42e666,_0x58868c,_0x58868c==_0x98e617['creator']));}(_0x2e947f,_0x3140ac);this['id']=_0x3140ac['id'],this['_revision']=_0x3140ac,this['_requireRevisionName']=_0x20495e,this['bind']('name','createdAt')['to'](_0x3140ac),this['bind']('_createdAtFormatted')['to'](this,'createdAt',_0x48a67d=>{return _0x13a09d=_0x2e947f['uiLanguage'],(_0x46d08f=_0x48a67d)['toLocaleDateString'](_0x13a09d,{'month':'long','day':'numeric'})+',\x20'+_0x46d08f['toLocaleTimeString'](_0x13a09d,{'hour':'numeric','minute':'numeric'});var _0x13a09d,_0x46d08f;}),this['set']('isSelected',!0x1),this['set']('isHighlighted',!0x1),this['set']('isActionsDropdownOpen',!0x1),this['set']('isReady',!0x1),this['set']('isEnabled',!0x1),this['revisionNameView']=new at(_0x2e947f,_0x302711),this['revisionNameView']['fieldView']['extendTemplate']({'attributes':{'maxlength':'220'}}),this['revisionNameView']['fieldView']['bind']('value')['to'](this,'name',_0x50fa02=>_0x50fa02||this['_createdAtFormatted']),this['revisionNameView']['bind']('isEnabled')['to'](this,'isSelected',this,'isEnabled',(_0x2c2325,_0x2de62c)=>_0x2c2325&&_0x2de62c),this['revisionActionsView']=_0x511f9a&&_0x511f9a['length']?oi(this,_0x511f9a):'',this['revisionActionsView']&&this['revisionActionsView']['bind']('isEnabled')['to'](this),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision-wrapper',_0x3b56ba['if']('isConfirm','ck-revision-history-sidebar__revision-wrapper_confirmation_visible')]},'children':[{'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision',_0x3b56ba['if']('isEnabled','ck-disabled',_0x1fe7b6=>!_0x1fe7b6),_0x3b56ba['if']('isSelected','ck-revision-history-sidebar__revision_selected'),_0x3b56ba['if']('isHighlighted','ck-revision-history-sidebar__revision_highlighted'),_0x3b56ba['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':_0x3b56ba['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':_0x522bb7}]},this['revisionActionsView']],'on':{'click':_0x3b56ba['to'](_0x4d4435=>{_0x4d4435['srcElement']['closest']('.ck-thread__remove-confirm')||this['isReady']&&this['isEnabled']&&this['fire']('select',{'id':this['id']});})}}]});}['render'](){super['render']();const _0x4f47f1=this['revisionNameView']['fieldView']['element'];this['listenTo'](_0x4f47f1,'change',()=>{this['_requireRevisionName']&&!_0x4f47f1['value']||this['fire']('setName',{'id':this['id'],'name':_0x4f47f1['value']}),_0x4f47f1['value']||(_0x4f47f1['value']=this['name']?this['name']:this['_createdAtFormatted']);});}['select'](){this['isSelected']=!0x0;}['deselect'](){this['isSelected']=!0x1;}['highlight'](){this['isHighlighted']=!0x0;}['unhighlight'](){this['isHighlighted']=!0x1;}}function ai(_0x4425b2,_0x4dc0fc){const _0x5bfbb8=_0x473ede['fromJSDate'](_0x4425b2)['setLocale'](_0x4dc0fc),_0x4eae20=_0x473ede['local'](),_0x23c06e=_0x4eae20['minus']({'days':0x1})['startOf']('day');let _0x321769,_0x139991;return _0x5bfbb8['hasSame'](_0x4eae20,'day')?(_0x321769=_0x5bfbb8['startOf']('day')['toJSDate'](),_0x139991=_0x5bfbb8['toRelativeCalendar']()):_0x5bfbb8['hasSame'](_0x23c06e,'day')?(_0x321769=_0x23c06e['toJSDate'](),_0x139991=_0x5bfbb8['toRelativeCalendar']()):_0x5bfbb8['hasSame'](_0x4eae20,'week')?(_0x321769=_0x5bfbb8['startOf']('week')['toJSDate'](),_0x139991=_0x5bfbb8['weekdayLong']||''):_0x5bfbb8['hasSame'](_0x4eae20,'year')?(_0x321769=_0x5bfbb8['startOf']('month')['toJSDate'](),_0x139991=_0x5bfbb8['monthLong']||''):(_0x321769=_0x5bfbb8['startOf']('year')['toJSDate'](),_0x139991=String(_0x5bfbb8['year'])),{'startDate':_0x321769,'localizedPeriodName':_0x139991};}class di extends ts{['startDate'];['revisionViews'];['_revisionActions'];['_requireRevisionName'];constructor(_0x1214b2,_0xa84e65,_0x36ff02,_0x315b01){super(_0x1214b2);const _0x279da8=ai(_0xa84e65,this['locale']['uiLanguage'])['localizedPeriodName'];this['startDate']=_0xa84e65,this['revisionViews']=this['createCollection'](),this['_revisionActions']=_0x36ff02,this['_requireRevisionName']=_0x315b01,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':_0x279da8}]},{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__time-period__revisions']},'children':this['revisionViews']}]});}['addRevision'](_0xc09b66){const _0x396752=new hi(this['locale'],_0xc09b66,this['_revisionActions'],this['_requireRevisionName']);this['revisionViews']['add'](_0x396752);}['removeRevision'](_0x27261e){const _0x1e4a5b=this['revisionViews']['find'](_0x26446a=>_0x26446a['id']===_0x27261e['id']);this['revisionViews']['remove'](_0x1e4a5b);}}class as extends ts{constructor(_0x4bc531){super(_0x4bc531);const _0x57e984=new _0x5c632d();_0x57e984['content']=_0x1ac31f,this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset_all','ck-revision-history-sidebar__header']},'children':[_0x57e984,{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__header__label']},'children':[g(_0x4bc531,'Revision\x20history')]}]});}}class ni extends ts{['timePeriodViews'];['_revisions'];['_revisionActions'];['_requireRevisionName'];constructor(_0x57847e,_0xd1a29f,_0xb0707a,_0x3eadf0){super(_0x57847e);const _0x377305=this['bindTemplate'];this['timePeriodViews']=this['createCollection'](),this['timePeriodViews']['delegate']('select')['to'](this),this['timePeriodViews']['delegate']('setName')['to'](this),this['_revisions']=_0xd1a29f,this['_revisionActions']=_0xb0707a,this['_requireRevisionName']=_0x3eadf0,this['on']('select',(_0x5b91fa,_0x3b8d6c)=>{this['fire']('revisionSelected',_0x3b8d6c);}),this['on']('setName',(_0x4593e4,_0x532bad)=>{this['fire']('revisionSetName',_0x532bad);}),this['set']('isEnabled',!0x1),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-rounded-corners','ck-revision-history-sidebar']},'children':[new as(_0x57847e),{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__timeline',_0x377305['if']('isEnabled','ck-disabled',_0x279da3=>!_0x279da3)]},'children':this['timePeriodViews']}]});}['render'](){super['render']();for(const _0x599f5b of this['_revisions'])this['_addRevision'](_0x599f5b);this['_revisions']['on']('add',(_0x6305b4,_0x39987c)=>{this['_addRevision'](_0x39987c);}),this['_revisions']['on']('remove',(_0x3f4f50,_0x5ef222)=>{this['_removeRevision'](_0x5ef222);});}get['revisionViews'](){return this['timePeriodViews']['map'](_0x2cc99a=>_0x2cc99a['revisionViews']['map'](_0x2ae7f3=>_0x2ae7f3))['flat']();}['selectRevision'](_0x1ab683){for(const _0x2146a4 of this['revisionViews'])_0x1ab683&&_0x1ab683['id']===_0x2146a4['id']?_0x2146a4['select']():_0x2146a4['deselect']();}['highlightRevisions'](_0x25ba25){for(const _0x46d104 of this['revisionViews'])_0x25ba25['some'](({id:_0x294f7c})=>_0x294f7c===_0x46d104['id'])?_0x46d104['highlight']():_0x46d104['unhighlight']();}['_addRevision'](_0x40e0a4){const _0x491820=ai(_0x40e0a4['createdAt'],this['locale']['uiLanguage'])['startDate'];let _0x21603d=this['timePeriodViews']['get'](0x0);_0x21603d&&_0x21603d['startDate']['getTime']()===_0x491820['getTime']()||(_0x21603d=new di(this['locale'],_0x491820,this['_revisionActions'],this['_requireRevisionName']),this['timePeriodViews']['add'](_0x21603d)),_0x21603d['addRevision'](_0x40e0a4);}['_removeRevision'](_0x36f88c){const _0x3dd8a0=ai(_0x36f88c['createdAt'],this['locale']['uiLanguage'])['startDate'];this['_getTimePeriodViewByStartDate'](_0x3dd8a0)['removeRevision'](_0x36f88c);}['_getTimePeriodViewByStartDate'](_0x44d52a){return this['timePeriodViews']['find'](_0xfaa534=>_0xfaa534['startDate']['getTime']()===_0x44d52a['getTime']());}}class d extends _0x443a46{['_revisionViewer'];['_revisionsRepository'];['_sidebarView'];static ['defaultRevisionActions']=/* #__PURE__ -- @preserve */
27
27
  ((()=>['compareAgainstSelected','restoreRevision','nameRevision'])());static ['availableRevisionActions']=/* #__PURE__ -- @preserve */
28
- pt();static get['pluginName'](){return'RevisionsSidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[m];}constructor(_0x5e43a6){super(_0x5e43a6),this['_revisionViewer']=_0x5e43a6['plugins']['get'](m),this['_revisionsRepository']=this['_revisionViewer']['repository'],this['_sidebarView']=null;}['init'](){const _0x38fd5e=this['_revisionsRepository']['_revisions'],_0x26ce6c=this['_createRevisionActions'](),_0x2a9b1b=this['editor']['config']['get']('revisionHistory.viewerSidebarContainer');this['_sidebarView']=new ni(this['editor']['locale'],_0x38fd5e,_0x26ce6c,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',(_0xda79c1,_0x18a2d8)=>{_0x18a2d8['revisionViews']['on']('add',(_0x1dc39e,_0x4db074)=>{_0x4db074['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)),_0x2a9b1b['appendChild'](this['_sidebarView']['element']);}['destroy'](){this['_sidebarView']['element']['remove'](),this['_sidebarView']['destroy']();}['_handleEditorDataReady'](){const _0x79cc6e=this['_revisionsRepository']['getRevision'](0x0);if(_0x79cc6e){const _0x5dadcd=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x79cc6e['id']);this['_revisionViewer']['compare'](_0x79cc6e,_0x5dadcd);}}['_handleRevisionSelected'](_0x1dba71,_0x26555e){const _0x845983=this['_revisionsRepository']['getRevision'](_0x26555e['id']),_0x4506f4=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x845983['id']);this['_revisionViewer']['compare'](_0x845983,_0x4506f4);}['_handleRevisionSetName'](_0x358595,_0x58e0c6){this['_revisionsRepository']['getRevision'](_0x58e0c6['id'])['setName'](_0x58e0c6['name']);}['_handleDiffChange'](_0x4d1ecf,_0x1d1119,_0x44cd8e){const _0x5c661c=this['_revisionsRepository']['getRevisionsInDiff'](_0x44cd8e);_0x5c661c['length']>0x2?(this['_sidebarView']['highlightRevisions'](_0x5c661c),this['_sidebarView']['selectRevision'](null)):(this['_sidebarView']['highlightRevisions']([]),this['_sidebarView']['selectRevision'](_0x5c661c[0x0]));}['_createRevisionActions'](){const _0x192c9e=this['editor'],_0x21506a=d['availableRevisionActions'],_0x4dcf6e=_0x192c9e['config']['get']('revisionHistory.revisionActions')||d['defaultRevisionActions'];if(_0x4dcf6e['length'])return _0x4dcf6e['map'](_0x4516c6=>{const _0x10a869='string'==typeof _0x4516c6?Object['assign']({},_0x21506a[_0x4516c6]):_0x4516c6;return _0x10a869['action']=_0x10a869['action']['bind'](this,_0x192c9e),_0x10a869['isVisible']&&(_0x10a869['isVisible']=_0x10a869['isVisible']['bind'](this,_0x192c9e)),_0x10a869;});}}function pt(){return{'compareAgainstSelected':{'name':'Compare\x20against\x20selected','action':({plugins:_0x2f35d8},_0x5e7777)=>{const _0x57ac72=_0x2f35d8['get'](m),_0x4774b2=_0x57ac72['repository'];let _0x579e55=_0x57ac72['diff']['newRevisionId'],_0x1cc0ff=_0x5e7777['id'];_0x4774b2['getIndex'](_0x579e55)>_0x4774b2['getIndex'](_0x1cc0ff)&&([_0x579e55,_0x1cc0ff]=[_0x1cc0ff,_0x579e55]),_0x57ac72['compare'](_0x579e55,_0x1cc0ff);},'isVisible':({plugins:_0x1735b4},_0x3f611e)=>{const _0x5bd587=_0x1735b4['get'](m);return!(_0x5bd587['repository']['getRevisionsInDiff'](_0x5bd587['diff'])['length']>0x2)&&!_0x3f611e['isSelected'];}},'restoreRevision':{'name':'Restore\x20this\x20revision','action':(_0x457982,{id:_0x5b4014})=>{_0x457982['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x5b4014);},'isVisible':({plugins:_0x10e04d},_0x32de59)=>!!_0x10e04d['get'](m)['repository']['getLaterVisibleRevision'](_0x32de59['id'])},'nameRevision':{'name':'Name\x20this\x20revision','action':({plugins:_0x39a133},{id:_0x54774a,revisionNameView:_0x225252})=>{const _0x40dc97=_0x39a133['get'](m),_0x20ed6c=_0x40dc97['repository']['getEarlierVisibleRevision'](_0x54774a);_0x40dc97['compare'](_0x54774a,_0x20ed6c),_0x225252['focus'](),_0x225252['fieldView']['select']();}}};}class tt extends st{['_view'];['_toolbarConfig'];['_elementReplacer'];get['view'](){return this['_view'];}constructor(_0xcc82de,_0x1ac5dd){super(_0xcc82de),this['_view']=_0x1ac5dd,this['_toolbarConfig']=et(_0xcc82de['config']['get']('toolbar')),this['_elementReplacer']=new ot();}get['element'](){return this['view']['element'];}['init'](_0x5076f5){const _0x4f8926=this['editor'],_0xbb656e=this['view'],_0x5a8775=_0x4f8926['editing']['view'],_0x28e1f1=_0xbb656e['editable'],_0x7c537=_0x5a8775['document']['getRoot']();_0x28e1f1['name']=_0x7c537['rootName'],_0xbb656e['render']();const _0x2171f2=_0x28e1f1['element'];this['setEditableElement'](_0x28e1f1['name'],_0x2171f2),_0xbb656e['editable']['bind']('isFocused')['to'](this['focusTracker']),_0x5a8775['attachDomRoot'](_0x2171f2),this['_elementReplacer']['replace'](_0x5076f5,this['element']),this['_initToolbar'](),this['fire']('ready');}['destroy'](){super['destroy']();const _0x56dd6a=this['view'],_0x5e312b=this['editor']['editing']['view'];this['_elementReplacer']['restore'](),_0x5e312b['detachDomRoot'](_0x56dd6a['editable']['name']),_0x56dd6a['destroy']();}['_initToolbar'](){const _0x2be98b=this['view'];_0x2be98b['stickyPanel']['bind']('isActive')['to'](this['focusTracker'],'isFocused'),_0x2be98b['stickyPanel']['limiterElement']=_0x2be98b['element'],_0x2be98b['stickyPanel']['bind']('viewportTopOffset')['to'](this,'viewportOffset',({top:_0x7e2da3})=>_0x7e2da3),_0x2be98b['toolbar']['fillFromConfig'](this['_toolbarConfig'],this['componentFactory']),this['addToolbar'](_0x2be98b['toolbar']);}}class it extends rt{['_editable'];['stickyPanel'];['toolbar'];get['editable'](){return this['_editable'];}constructor(_0x10d3ef,_0x13f306,_0x2349b7={}){super(_0x10d3ef),this['stickyPanel']=new ht(_0x10d3ef),this['toolbar']=new dt(_0x10d3ef,{'shouldGroupWhenFull':_0x2349b7['shouldToolbarGroupWhenFull']}),this['_editable']=new ct(_0x10d3ef,_0x13f306);}['render'](){super['render'](),this['stickyPanel']['content']['add'](this['toolbar']),this['top']['add'](this['stickyPanel']),this['main']['add'](this['editable']);}}class w extends/* #__PURE__ -- @preserve */
29
- _0x5c4561(_0x328345){['_ui'];get['ui'](){return this['_ui'];}constructor(_0x111d9c,_0xc27076){super(_0xc27076),this['sourceElement']=_0x111d9c,this['model']['document']['createRoot']();const _0x6cf266=new it(this['locale'],this['editing']['view'],{'shouldToolbarGroupWhenFull':!0x0});this['_ui']=new tt(this,_0x6cf266);}['destroy'](){return this['updateSourceElement'](),this['ui']['destroy'](),super['destroy']();}static async['create'](_0x4d2f33,_0x35c14e){const _0x185086=new this(_0x4d2f33,_0x35c14e);return await _0x185086['initPlugins'](),await _0x185086['ui']['init'](_0x4d2f33),await _0x185086['data']['init'](_0x185086['config']['get']('initialData')||''),_0x185086['fire']('ready'),_0x185086;}}const p=['RevisionHistoryUI','RestrictedEditingMode'];class _t extends _0x311e14{['result'];static get['pluginName'](){return'RevisionViewerIntegration';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x29062f){function _0x3edadc(_0x22ba37){return _0x22ba37['map'](_0x379026=>String['fromCharCode'](_0x379026))['join']('');}super(_0x29062f),this['result']='end',_0x29062f[_0x3edadc([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x3edadc([0x76,0x69,0x65,0x77])][_0x3edadc([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x3edadc([0x61,0x75,0x74,0x6f]),_0x29062f[_0x3edadc([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x3edadc([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x3edadc([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x3edadc([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x3edadc([0x6f,0x6b])});}}class k extends _0x311e14{['_viewerEditor'];static get['pluginName'](){return'RevisionHistory';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[u,f];}constructor(_0x5ad690){if(super(_0x5ad690),!this['editor']['config']['get']('revisionHistory'))throw new _0x58c7db('revision-history-missing-configuration',this);this['_viewerEditor']=null,this['set']('isRevisionViewerOpen',!0x1),this['editor']['config']['define']('revisionHistory.showRevisionViewerCallback',_0x14ef65=>this['_showRevisionViewer']({..._0x14ef65,'translations':this['editor']['locale']['translations']})),this['editor']['config']['define']('revisionHistory.closeRevisionViewerCallback',_0x5c5e2=>this['_closeRevisionViewer'](_0x5c5e2)),this['editor']['config']['define']('revisionHistory.restoreRevisionCallback',_0x54246e=>this['_restoreRevision'](_0x54246e)),this['editor']['config']['define']('revisionHistory.requireRevisionName',!0x1),this['_enhanceShowRevisionViewerCallback'](),this['_enhanceCloseRevisionViewerCallback']();}set['adapter'](_0x67f7bd){this['editor']['plugins']['get']('RevisionTracker')['adapter']=_0x67f7bd;}get['adapter'](){return this['editor']['plugins']['get']('RevisionTracker')['adapter'];}['addRevisionData'](_0x2d9a9d){return this['editor']['plugins']['get']('RevisionTracker')['addRevisionData'](_0x2d9a9d);}['getRevision'](_0x209897){return this['editor']['plugins']['get']('RevisionsRepository')['getRevision'](_0x209897);}['getRevisions'](_0x2b06d8){return this['editor']['plugins']['get']('RevisionsRepository')['getRevisions'](_0x2b06d8||{'toJSON':!0x1});}['_getRevisionViewerEditorConfig'](){const _0x141fd1=this['editor'],_0x2539a7=_0x5b0648(_0x141fd1,p),_0x516070=_0x141fd1['plugins']['get']('RevisionTracker'),_0x290257=_0x141fd1['plugins']['get']('Users')['users'];return _0x2539a7['toolbar']=['exitToEditing','restoreRevision','changesNavigation'],delete _0x2539a7['lazyRoots'],(_0x2539a7['plugins']['push'](_t,m,R,class extends _0x311e14{static get['requires'](){return[m,'Users'];}['init'](){const _0x4703a3=this['editor']['plugins']['get']('Users');for(const _0x159846 of _0x290257)_0x159846['isAnonymous']||_0x4703a3['getUser'](_0x159846['id'])||_0x4703a3['addUser'](_0x159846);const _0x19a5eb=_0x516070['repository']['getRevisions']();let _0x3f375c=null;const _0x10e1f5=this['editor']['plugins']['get']('RevisionViewer');_0x10e1f5['adapter']=_0x516070['adapter'],_0x10e1f5['bind']('isEnabled')['to'](_0x516070),this['editor']['commands']['get']('restoreRevision')['bind']('isEnabled')['to'](_0x141fd1,'isReadOnly',_0x321296=>!_0x321296);for(const _0x385428 of _0x19a5eb){const _0x5634e3=null===_0x385428['creator'];if(_0x5634e3&&_0x385428['toVersion']===_0x385428['fromVersion'])continue;const _0x193832=_0x385428['toJSON']();_0x10e1f5['addRevisionData'](_0x193832,(_0x4f48ec,_0x4352f3,_0x22c30d)=>{if(_0x5634e3){if(_0x3f375c)_0x3f375c['_update'](_0x4f48ec,_0x4352f3);else{if(!_0x4352f3){const _0x4d717e=_0x22c30d['toJSON']();_0x4d717e['id']=_0x43c208(),_0x516070['saveRevision'](_0x4d717e,_0x22c30d['toVersion'])['then'](_0x11fcd3=>{_0x3f375c=_0x11fcd3;});}}}else _0x385428['_update'](_0x4f48ec,_0x4352f3);});}}},d),_0x2539a7);}['_enhanceShowRevisionViewerCallback'](){const _0x484762=this['editor']['config']['get']('revisionHistory')['showRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.showRevisionViewerCallback',async()=>{this['editor']['enableReadOnlyMode']('revision-history-viewer-opened');const _0x3f2897=this['editor']['plugins']['get']('RevisionTracker');if(this['editor']['plugins']['has']('Autosave')){const _0x134695=this['editor']['plugins']['get']('Autosave');await _0x134695['save']();}else await _0x3f2897['update']();if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('Dialog')){const _0x586723=this['editor']['plugins']['get']('Dialog');_0x586723['isOpen']&&_0x586723['hide']();}const _0x273ff1=this['_getRevisionViewerEditorConfig']();return _0x484762(_0x273ff1)['then'](_0x47960f=>{return(this['_viewerEditor']=_0x47960f,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'),_0x47960f);})['catch'](_0xe00c9e=>(console['error'](_0xe00c9e),this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),null));});}['_enhanceCloseRevisionViewerCallback'](){const _0x549b60=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'](),_0x549b60(this['_viewerEditor'])['then'](()=>{if(this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),this['_viewerEditor']=null,this['editor']['plugins']['has']('Annotations')){const _0x36b645=this['editor']['plugins']['get']('Annotations');_0x36b645['refreshVisibility'](),_0x36b645['refreshPositioning']();}})));}['_showRevisionViewer'](_0x23a228){const _0x319a1d=this['editor']['config']['get']('revisionHistory.editorContainer'),_0x58be97=this['editor']['config']['get']('revisionHistory.viewerContainer'),_0x2a6fc1=this['editor']['config']['get']('revisionHistory.viewerEditorElement');return w['create'](_0x2a6fc1,_0x23a228)['then'](_0x102b09=>(_0x58be97['style']['display']='block',_0x319a1d['style']['display']='none',this['isRevisionViewerOpen']=!0x0,_0x102b09));}['_closeRevisionViewer'](_0x244158){const _0x144578=this['editor']['config']['get']('revisionHistory.editorContainer');return this['editor']['config']['get']('revisionHistory.viewerContainer')['style']['display']='none',_0x144578['style']['display']='',this['isRevisionViewerOpen']=!0x1,_0x244158['destroy']();}async['_restoreRevision'](_0x200bfe){const _0x475f9e=this['editor'],_0x2ba35b=this['_viewerEditor']['plugins']['get']('RevisionViewer'),_0x293eb4=_0x475f9e['plugins']['get']('RevisionTracker'),_0x4009f5=_0x475f9e['plugins']['get']('RevisionHistoryUtils'),_0x3988d8=_0x2ba35b['repository']['getRevision'](_0x200bfe);let _0x53b589,_0x25b7ad,_0x59334d;try{await _0x4009f5['loadRevisionData'](_0x3988d8,this['adapter']),_0x53b589=_0x4009f5['getRevisionDocumentData'](_0x3988d8),_0x25b7ad=_0x4009f5['getRevisionRootsAttributes'](_0x3988d8);}catch(_0x226201){return void console['error'](_0x226201);}_0x475f9e['model']['change'](_0x43726d=>{for(const _0x57b0da of Array['from'](_0x475f9e['model']['markers']['getMarkersGroup']('restrictedEditingException')))_0x43726d['removeMarker'](_0x57b0da);}),_0x2ba35b['isReady']=!0x1,_0x475f9e['model']['enqueueChange'](_0x2cf811=>{_0x2cf811['setSelection'](null),_0x2cf811['removeSelectionAttribute'](_0x475f9e['model']['document']['selection']['getAttributeKeys']());const _0x6cc715=Object['keys'](_0x53b589);for(const _0x417d68 of _0x475f9e['model']['document']['roots'])'$graveyard'!=_0x417d68['rootName']&&_0x417d68['isAttached']()&&!_0x6cc715['includes'](_0x417d68['rootName'])&&_0x2cf811['detachRoot'](_0x417d68);for(const _0x5de6e5 of _0x6cc715){let _0x3aa992=_0x475f9e['model']['document']['getRoot'](_0x5de6e5);_0x3aa992&&_0x3aa992['isAttached']()||(_0x3aa992=_0x2cf811['addRoot'](_0x5de6e5));const _0x19ea41=_0x25b7ad[_0x5de6e5],_0x5d6db1=Object['keys'](_0x19ea41),_0x2ace88=_0x53b589[_0x5de6e5];for(const _0x40830a of _0x3aa992['getAttributeKeys']())_0x5d6db1['includes'](_0x40830a)||_0x2cf811['removeAttribute'](_0x40830a,_0x3aa992);for(const _0x35ef79 of _0x5d6db1)_0x2cf811['setAttribute'](_0x35ef79,_0x25b7ad[_0x5de6e5][_0x35ef79],_0x3aa992);_0x2cf811['remove'](_0x2cf811['createRangeIn'](_0x3aa992)),_0x2cf811['insert'](_0x475f9e['data']['parse'](_0x2ace88,_0x3aa992),_0x3aa992,0x0);}});const _0x51f894=g(_0x475f9e['locale'],'Restored');if(_0x3988d8['name'])_0x59334d=-0x1==_0x3988d8['name']['indexOf'](_0x51f894)?_0x51f894+':\x20'+_0x3988d8['name']:_0x3988d8['name'];else _0x59334d=_0x51f894+':\x20'+(_0x3988d8['createdAt']['toLocaleDateString'](_0x475f9e['locale']['uiLanguage'],{'month':'long','day':'numeric'})+',\x20'+_0x3988d8['createdAt']['toLocaleTimeString'](_0x475f9e['locale']['uiLanguage'],{'hour':'numeric','minute':'numeric'}));return await _0x293eb4['saveRevision']({'name':_0x59334d}),_0x2ba35b['isReady']=!0x0,_0x475f9e['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}}export{h as Revision,k as RevisionHistory,f as RevisionHistoryUI,V as RevisionHistoryUtils,u as RevisionTracker,m as RevisionViewer,w as RevisionViewerEditor,ge as RevisionViewerLoadingOverlay,R as RevisionViewerUI,I as RevisionsRepository,d as RevisionsSidebar};
28
+ pt();static get['pluginName'](){return'RevisionsSidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[m];}constructor(_0x37704){super(_0x37704),this['_revisionViewer']=_0x37704['plugins']['get'](m),this['_revisionsRepository']=this['_revisionViewer']['repository'],this['_sidebarView']=null;}['init'](){const _0x1d9726=this['_revisionsRepository']['_revisions'],_0x332b6e=this['_createRevisionActions'](),_0x1c1ef7=this['editor']['config']['get']('revisionHistory.viewerSidebarContainer');this['_sidebarView']=new ni(this['editor']['locale'],_0x1d9726,_0x332b6e,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',(_0x31c251,_0x477b24)=>{_0x477b24['revisionViews']['on']('add',(_0x4830c8,_0x3ff4e4)=>{_0x3ff4e4['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)),_0x1c1ef7['appendChild'](this['_sidebarView']['element']);}['destroy'](){this['_sidebarView']['element']['remove'](),this['_sidebarView']['destroy']();}['_handleEditorDataReady'](){const _0x30617a=this['_revisionsRepository']['getRevision'](0x0);if(_0x30617a){const _0x19a2fb=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x30617a['id']);this['_revisionViewer']['compare'](_0x30617a,_0x19a2fb);}}['_handleRevisionSelected'](_0x5af5d9,_0x230d78){const _0x256ed4=this['_revisionsRepository']['getRevision'](_0x230d78['id']),_0x1361d8=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x256ed4['id']);this['_revisionViewer']['compare'](_0x256ed4,_0x1361d8);}['_handleRevisionSetName'](_0x13a3a9,_0x331265){this['_revisionsRepository']['getRevision'](_0x331265['id'])['setName'](_0x331265['name']);}['_handleDiffChange'](_0x3bebe8,_0x2970e9,_0x38b1ed){const _0x564dd0=this['_revisionsRepository']['getRevisionsInDiff'](_0x38b1ed);_0x564dd0['length']>0x2?(this['_sidebarView']['highlightRevisions'](_0x564dd0),this['_sidebarView']['selectRevision'](null)):(this['_sidebarView']['highlightRevisions']([]),this['_sidebarView']['selectRevision'](_0x564dd0[0x0]));}['_createRevisionActions'](){const _0x41e07c=this['editor'],_0x5063e2=d['availableRevisionActions'],_0x124f3c=_0x41e07c['config']['get']('revisionHistory.revisionActions')||d['defaultRevisionActions'];if(_0x124f3c['length'])return _0x124f3c['map'](_0x9a13d7=>{const _0x38c8c1='string'==typeof _0x9a13d7?Object['assign']({},_0x5063e2[_0x9a13d7]):_0x9a13d7;return _0x38c8c1['action']=_0x38c8c1['action']['bind'](this,_0x41e07c),_0x38c8c1['isVisible']&&(_0x38c8c1['isVisible']=_0x38c8c1['isVisible']['bind'](this,_0x41e07c)),_0x38c8c1;});}}function pt(){return{'compareAgainstSelected':{'name':'Compare\x20against\x20selected','action':({plugins:_0x45a0db},_0x58b781)=>{const _0x2ebb54=_0x45a0db['get'](m),_0x2c8659=_0x2ebb54['repository'];let _0x3b3af3=_0x2ebb54['diff']['newRevisionId'],_0x3058ca=_0x58b781['id'];_0x2c8659['getIndex'](_0x3b3af3)>_0x2c8659['getIndex'](_0x3058ca)&&([_0x3b3af3,_0x3058ca]=[_0x3058ca,_0x3b3af3]),_0x2ebb54['compare'](_0x3b3af3,_0x3058ca);},'isVisible':({plugins:_0x1bce7f},_0x482897)=>{const _0x200b43=_0x1bce7f['get'](m);return!(_0x200b43['repository']['getRevisionsInDiff'](_0x200b43['diff'])['length']>0x2)&&!_0x482897['isSelected'];}},'restoreRevision':{'name':'Restore\x20this\x20revision','action':(_0x3b1b2e,{id:_0x3cb070})=>{_0x3b1b2e['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x3cb070);},'isVisible':({plugins:_0x257098},_0x11157e)=>!!_0x257098['get'](m)['repository']['getLaterVisibleRevision'](_0x11157e['id'])},'nameRevision':{'name':'Name\x20this\x20revision','action':({plugins:_0x771685},{id:_0x54bc2e,revisionNameView:_0x2057c2})=>{const _0x33d7eb=_0x771685['get'](m),_0x121031=_0x33d7eb['repository']['getEarlierVisibleRevision'](_0x54bc2e);_0x33d7eb['compare'](_0x54bc2e,_0x121031),_0x2057c2['focus'](),_0x2057c2['fieldView']['select']();}}};}class tt extends st{['_view'];['_toolbarConfig'];['_elementReplacer'];get['view'](){return this['_view'];}constructor(_0x1cfadd,_0x157f4d){super(_0x1cfadd),this['_view']=_0x157f4d,this['_toolbarConfig']=et(_0x1cfadd['config']['get']('toolbar')),this['_elementReplacer']=new ot();}get['element'](){return this['view']['element'];}['init'](_0x11a444){const _0x3657da=this['editor'],_0x34dc31=this['view'],_0x2efad7=_0x3657da['editing']['view'],_0x1c932f=_0x34dc31['editable'],_0x40e146=_0x2efad7['document']['getRoot']();_0x1c932f['name']=_0x40e146['rootName'],_0x34dc31['render']();const _0x223b33=_0x1c932f['element'];this['setEditableElement'](_0x1c932f['name'],_0x223b33),_0x34dc31['editable']['bind']('isFocused')['to'](this['focusTracker']),_0x2efad7['attachDomRoot'](_0x223b33),this['_elementReplacer']['replace'](_0x11a444,this['element']),this['_initToolbar'](),this['fire']('ready');}['destroy'](){super['destroy']();const _0x1f5902=this['view'],_0x291033=this['editor']['editing']['view'];this['_elementReplacer']['restore'](),_0x291033['detachDomRoot'](_0x1f5902['editable']['name']),_0x1f5902['destroy']();}['_initToolbar'](){const _0x113fe5=this['view'];_0x113fe5['stickyPanel']['bind']('isActive')['to'](this['focusTracker'],'isFocused'),_0x113fe5['stickyPanel']['limiterElement']=_0x113fe5['element'],_0x113fe5['stickyPanel']['bind']('viewportTopOffset')['to'](this,'viewportOffset',({top:_0x34880e})=>_0x34880e),_0x113fe5['toolbar']['fillFromConfig'](this['_toolbarConfig'],this['componentFactory']),this['addToolbar'](_0x113fe5['toolbar']);}}class it extends rt{['_editable'];['stickyPanel'];['toolbar'];get['editable'](){return this['_editable'];}constructor(_0x2aba33,_0x3ecfaa,_0x308924={}){super(_0x2aba33),this['stickyPanel']=new ht(_0x2aba33),this['toolbar']=new dt(_0x2aba33,{'shouldGroupWhenFull':_0x308924['shouldToolbarGroupWhenFull']}),this['_editable']=new ct(_0x2aba33,_0x3ecfaa);}['render'](){super['render'](),this['stickyPanel']['content']['add'](this['toolbar']),this['top']['add'](this['stickyPanel']),this['main']['add'](this['editable']);}}class w extends/* #__PURE__ -- @preserve */
29
+ _0x5380ba(_0x17449b){['_ui'];get['ui'](){return this['_ui'];}constructor(_0x17cdb8,_0x5113cb){super(_0x5113cb),this['sourceElement']=_0x17cdb8,this['model']['document']['createRoot']();const _0x2ca1a3=new it(this['locale'],this['editing']['view'],{'shouldToolbarGroupWhenFull':!0x0});this['_ui']=new tt(this,_0x2ca1a3);}['destroy'](){return this['updateSourceElement'](),this['ui']['destroy'](),super['destroy']();}static async['create'](_0x373ab7,_0x1f02c0){const _0x34807c=new this(_0x373ab7,_0x1f02c0);return await _0x34807c['initPlugins'](),await _0x34807c['ui']['init'](_0x373ab7),await _0x34807c['data']['init'](_0x34807c['config']['get']('initialData')||''),_0x34807c['fire']('ready'),_0x34807c;}}const p=['RevisionHistoryUI','RestrictedEditingMode'];class _t extends _0x443a46{['result'];static get['pluginName'](){return'RevisionViewerIntegration';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x4e9263){function _0xd7e19b(_0x22d004){return _0x22d004['map'](_0x472d9b=>String['fromCharCode'](_0x472d9b))['join']('');}super(_0x4e9263),this['result']='end',_0x4e9263[_0xd7e19b([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0xd7e19b([0x76,0x69,0x65,0x77])][_0xd7e19b([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0xd7e19b([0x61,0x75,0x74,0x6f]),_0x4e9263[_0xd7e19b([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0xd7e19b([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0xd7e19b([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0xd7e19b([0x73,0x74,0x61,0x74,0x75,0x73])]:_0xd7e19b([0x6f,0x6b])});}}class k extends _0x443a46{['_viewerEditor'];static get['pluginName'](){return'RevisionHistory';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[u,f];}constructor(_0x2b8718){if(super(_0x2b8718),!this['editor']['config']['get']('revisionHistory'))throw new _0x5b4da3('revision-history-missing-configuration',this);this['_viewerEditor']=null,this['set']('isRevisionViewerOpen',!0x1),this['editor']['config']['define']('revisionHistory.showRevisionViewerCallback',_0x40b1f5=>this['_showRevisionViewer']({..._0x40b1f5,'translations':this['editor']['locale']['translations']})),this['editor']['config']['define']('revisionHistory.closeRevisionViewerCallback',_0x464b2d=>this['_closeRevisionViewer'](_0x464b2d)),this['editor']['config']['define']('revisionHistory.restoreRevisionCallback',_0x40f411=>this['_restoreRevision'](_0x40f411)),this['editor']['config']['define']('revisionHistory.requireRevisionName',!0x1),this['_enhanceShowRevisionViewerCallback'](),this['_enhanceCloseRevisionViewerCallback']();}set['adapter'](_0x1855f0){this['editor']['plugins']['get']('RevisionTracker')['adapter']=_0x1855f0;}get['adapter'](){return this['editor']['plugins']['get']('RevisionTracker')['adapter'];}['addRevisionData'](_0x20bbdb){return this['editor']['plugins']['get']('RevisionTracker')['addRevisionData'](_0x20bbdb);}['getRevision'](_0x32376c){return this['editor']['plugins']['get']('RevisionsRepository')['getRevision'](_0x32376c);}['getRevisions'](_0x33e259){return this['editor']['plugins']['get']('RevisionsRepository')['getRevisions'](_0x33e259||{'toJSON':!0x1});}['_getRevisionViewerEditorConfig'](){const _0x7ae693=this['editor'],_0x8ad4b9=_0x2915b1(_0x7ae693,p),_0x14cf6f=_0x7ae693['plugins']['get']('RevisionTracker'),_0x34d79a=_0x7ae693['plugins']['get']('Users')['users'];return _0x8ad4b9['toolbar']=['exitToEditing','restoreRevision','changesNavigation'],delete _0x8ad4b9['lazyRoots'],(_0x8ad4b9['plugins']['push'](_t,m,R,class extends _0x443a46{static get['requires'](){return[m,'Users'];}['init'](){const _0x586db3=this['editor']['plugins']['get']('Users');for(const _0x59a6ef of _0x34d79a)_0x59a6ef['isAnonymous']||_0x586db3['getUser'](_0x59a6ef['id'])||_0x586db3['addUser'](_0x59a6ef);const _0x13bbef=_0x14cf6f['repository']['getRevisions']();let _0x126b79=null;const _0x5db64f=this['editor']['plugins']['get']('RevisionViewer');_0x5db64f['adapter']=_0x14cf6f['adapter'],_0x5db64f['bind']('isEnabled')['to'](_0x14cf6f),this['editor']['commands']['get']('restoreRevision')['bind']('isEnabled')['to'](_0x7ae693,'isReadOnly',_0x6122c4=>!_0x6122c4);for(const _0x2df271 of _0x13bbef){const _0x2cdbdc=null===_0x2df271['creator'];if(_0x2cdbdc&&_0x2df271['toVersion']===_0x2df271['fromVersion'])continue;const _0x11af0c=_0x2df271['toJSON']();_0x5db64f['addRevisionData'](_0x11af0c,(_0x5f1ad1,_0xe798a8,_0x6f50d7)=>{if(_0x2cdbdc){if(_0x126b79)_0x126b79['_update'](_0x5f1ad1,_0xe798a8);else{if(!_0xe798a8){const _0x323224=_0x6f50d7['toJSON']();_0x323224['id']=_0x2a1139(),_0x14cf6f['saveRevision'](_0x323224,_0x6f50d7['toVersion'])['then'](_0x138c11=>{_0x126b79=_0x138c11;});}}}else _0x2df271['_update'](_0x5f1ad1,_0xe798a8);});}}},d),_0x8ad4b9);}['_enhanceShowRevisionViewerCallback'](){const _0xfe8aaa=this['editor']['config']['get']('revisionHistory')['showRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.showRevisionViewerCallback',async()=>{this['editor']['enableReadOnlyMode']('revision-history-viewer-opened');const _0x5db07c=this['editor']['plugins']['get']('RevisionTracker');if(this['editor']['plugins']['has']('Autosave')){const _0xc638bc=this['editor']['plugins']['get']('Autosave');await _0xc638bc['save']();}else await _0x5db07c['update']();if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('Dialog')){const _0x4b4d2b=this['editor']['plugins']['get']('Dialog');_0x4b4d2b['isOpen']&&_0x4b4d2b['hide']();}const _0xc6df4=this['_getRevisionViewerEditorConfig']();return _0xfe8aaa(_0xc6df4)['then'](_0xddb2a0=>{return(this['_viewerEditor']=_0xddb2a0,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'),_0xddb2a0);})['catch'](_0x3c9636=>(console['error'](_0x3c9636),this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),null));});}['_enhanceCloseRevisionViewerCallback'](){const _0x3e542d=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'](),_0x3e542d(this['_viewerEditor'])['then'](()=>{if(this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),this['_viewerEditor']=null,this['editor']['plugins']['has']('Annotations')){const _0xce5b6e=this['editor']['plugins']['get']('Annotations');_0xce5b6e['refreshVisibility'](),_0xce5b6e['refreshPositioning']();}})));}['_showRevisionViewer'](_0xaece20){const _0x31b6d7=this['editor']['config']['get']('revisionHistory.editorContainer'),_0x217f7e=this['editor']['config']['get']('revisionHistory.viewerContainer'),_0x25ea5d=this['editor']['config']['get']('revisionHistory.viewerEditorElement');return w['create'](_0x25ea5d,_0xaece20)['then'](_0x7ed5f7=>(_0x217f7e['style']['display']='block',_0x31b6d7['style']['display']='none',this['isRevisionViewerOpen']=!0x0,_0x7ed5f7));}['_closeRevisionViewer'](_0x268a9e){const _0xb0c2d9=this['editor']['config']['get']('revisionHistory.editorContainer');return this['editor']['config']['get']('revisionHistory.viewerContainer')['style']['display']='none',_0xb0c2d9['style']['display']='',this['isRevisionViewerOpen']=!0x1,_0x268a9e['destroy']();}async['_restoreRevision'](_0x2f7aa9){const _0x1651aa=this['editor'],_0x146e8c=this['_viewerEditor']['plugins']['get']('RevisionViewer'),_0x40cccc=_0x1651aa['plugins']['get']('RevisionTracker'),_0x4b5b87=_0x1651aa['plugins']['get']('RevisionHistoryUtils'),_0x193b27=_0x146e8c['repository']['getRevision'](_0x2f7aa9);let _0x5f2d9e,_0x3d4d90,_0x439948;try{await _0x4b5b87['loadRevisionData'](_0x193b27,this['adapter']),_0x5f2d9e=_0x4b5b87['getRevisionDocumentData'](_0x193b27),_0x3d4d90=_0x4b5b87['getRevisionRootsAttributes'](_0x193b27);}catch(_0xfd989a){return void console['error'](_0xfd989a);}_0x1651aa['model']['change'](_0x3a6b65=>{for(const _0x22e7b7 of Array['from'](_0x1651aa['model']['markers']['getMarkersGroup']('restrictedEditingException')))_0x3a6b65['removeMarker'](_0x22e7b7);}),_0x146e8c['isReady']=!0x1,_0x1651aa['model']['enqueueChange'](_0xd14424=>{_0xd14424['setSelection'](null),_0xd14424['removeSelectionAttribute'](_0x1651aa['model']['document']['selection']['getAttributeKeys']());const _0x395e93=Object['keys'](_0x5f2d9e);for(const _0x32bb00 of _0x1651aa['model']['document']['roots'])'$graveyard'!=_0x32bb00['rootName']&&_0x32bb00['isAttached']()&&!_0x395e93['includes'](_0x32bb00['rootName'])&&_0xd14424['detachRoot'](_0x32bb00);for(const _0x18160d of _0x395e93){let _0xeae490=_0x1651aa['model']['document']['getRoot'](_0x18160d);_0xeae490&&_0xeae490['isAttached']()||(_0xeae490=_0xd14424['addRoot'](_0x18160d));const _0x316d2b=_0x3d4d90[_0x18160d],_0x3a22d0=Object['keys'](_0x316d2b),_0x57b1b6=_0x5f2d9e[_0x18160d];for(const _0x821a1f of _0xeae490['getAttributeKeys']())_0x3a22d0['includes'](_0x821a1f)||_0xd14424['removeAttribute'](_0x821a1f,_0xeae490);for(const _0x22dc25 of _0x3a22d0)_0xd14424['setAttribute'](_0x22dc25,_0x3d4d90[_0x18160d][_0x22dc25],_0xeae490);_0xd14424['remove'](_0xd14424['createRangeIn'](_0xeae490)),_0xd14424['insert'](_0x1651aa['data']['parse'](_0x57b1b6,_0xeae490),_0xeae490,0x0);}});const _0x1db1ac=g(_0x1651aa['locale'],'Restored');if(_0x193b27['name'])_0x439948=-0x1==_0x193b27['name']['indexOf'](_0x1db1ac)?_0x1db1ac+':\x20'+_0x193b27['name']:_0x193b27['name'];else _0x439948=_0x1db1ac+':\x20'+(_0x193b27['createdAt']['toLocaleDateString'](_0x1651aa['locale']['uiLanguage'],{'month':'long','day':'numeric'})+',\x20'+_0x193b27['createdAt']['toLocaleTimeString'](_0x1651aa['locale']['uiLanguage'],{'hour':'numeric','minute':'numeric'}));return await _0x40cccc['saveRevision']({'name':_0x439948}),_0x146e8c['isReady']=!0x0,_0x1651aa['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}}export{h as Revision,k as RevisionHistory,f as RevisionHistoryUI,V as RevisionHistoryUtils,u as RevisionTracker,m as RevisionViewer,w as RevisionViewerEditor,ge as RevisionViewerLoadingOverlay,R as RevisionViewerUI,I as RevisionsRepository,d as RevisionsSidebar};