@ckeditor/ckeditor5-revision-history 45.0.0-alpha.11 → 45.0.0-alpha.12

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 _0x3196fa,uid as _0x3fbd15,Collection as _0x5f0faf,logWarning as _0x1ce756,FocusTracker as _0x12b377,KeystrokeHandler as _0x10ecca,scrollViewportToShowTarget as _0x5c8233,ResizeObserver as nt,ElementReplacer as ot,CKEditorError as _0xae2ed9}from'@ckeditor/ckeditor5-utils/dist/index.js';import{cloneDeep as _0x4dbdf7,set as _0x3c9090,unset as _0x501d64,isEqual as _0x34eb88}from'es-toolkit/compat';import{Plugin as _0x1aaf30,PendingActions as _0x3cbd42,Command as _0x4e2556,ElementApiMixin as _0x59ee7c,Editor as _0x4d07a6}from'@ckeditor/ckeditor5-core/dist/index.js';import{Users as _0x25ff19,getMarkerDomElement as _0x56d34c,ConfirmMixin as ti,sanitizeEditorConfig as _0x1a3df8}from'ckeditor5-collaboration/dist/index.js';import{ViewContainerElement as _0x1586d5,ViewAttributeElement as _0x4a6f92,ViewEmptyElement as _0x35f70c,ViewRawElement as _0x34d858,ViewUIElement as _0x5e89db,ViewDocumentFragment as _0x12361a,ViewText as _0x3f0c02,ViewElement as _0x360a86,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 _0x2aae82,IconChevronUp as _0x1dd0dd,IconChevronDown as _0x2464b9,IconUndo as _0x5c9b99,IconUser as _0x3c4811,IconThreeVerticalDots as _0x45dd43}from'@ckeditor/ckeditor5-icons/dist/index.js';import{View as ts,injectCssTransitionDisabler as _0x47db8c,submitHandler as _0x3b4acf,LabeledFieldView as _0x21d0c2,createLabeledInputText as _0x1a6c7a,createDropdown as _0x3baa9b,ListView as _0xaeeef7,ListItemView as _0x250e3b,ButtonView as te,MenuBarMenuView as _0x471360,MenuBarMenuListView as _0x118393,MenuBarMenuListItemView as _0x47d63b,MenuBarMenuListItemButtonView as _0x53ffb1,ContextualBalloon as _0x52db93,ToolbarSeparatorView as _0x32da21,IconView as _0x5c83c3,addListToDropdown as _0x11596f,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 _0x3c368c}from'luxon';class h extends/* #__PURE__ -- @preserve */
24
- _0x3196fa(){['id'];['creator'];['authors'];['diffData'];['toVersion'];['fromVersion'];['model'];constructor(_0x4f2892){super(),this['id']=_0x4f2892['id']||_0x3fbd15(),this['creator']=_0x4f2892['creator']||null,this['authors']=_0x4f2892['authors']||[],this['diffData']=_0x4f2892['diffData']||null,this['toVersion']=_0x4f2892['toVersion']||0x0,this['fromVersion']=_0x4f2892['fromVersion']||0x0,this['set']('name',_0x4f2892['name']||''),this['set']('createdAt',_0x4f2892['createdAt']||new Date()),this['set']('attributes',_0x4f2892['attributes']||{});}['setName'](_0x54d8c9){this['_update']({'name':_0x54d8c9});}['setAttribute'](_0x4aed2c,_0x453abe){const _0x2078cc=_0x4dbdf7(this['attributes']);_0x3c9090(_0x2078cc,_0x4aed2c,_0x453abe),this['_update']({'attributes':_0x2078cc});}['removeAttribute'](_0x557add){const _0x3b2c0f=_0x4dbdf7(this['attributes']);_0x501d64(_0x3b2c0f,_0x557add),this['_update']({'attributes':_0x3b2c0f});}['_update'](_0x4de87c,_0x2e9749=!0x1){let _0xd9f18d=!0x1;const _0x34f53e={'id':this['id']},_0x4e41af=['name','createdAt','diffData','authors','attributes','toVersion','fromVersion','creatorId'];for(const _0x5a29d6 of _0x4e41af){const _0x42c293=_0x4de87c[_0x5a29d6];void 0x0!==_0x42c293&&_0x42c293!==this[_0x5a29d6]&&(this[_0x5a29d6]=_0x42c293,_0x34f53e[_0x5a29d6]=_0x42c293,_0xd9f18d=!0x0);}_0xd9f18d&&(_0x34f53e['authors']&&(_0x34f53e['authorsIds']=_0x34f53e['authors']['map'](_0x597caf=>_0x597caf['id']),delete _0x34f53e['authors']),this['fire']('_update',_0x34f53e,_0x2e9749));}['toJSON'](){return{'id':this['id'],'name':this['name'],'creatorId':this['creator']?this['creator']['id']:null,'authorsIds':this['authors']['map'](_0x3b1ec3=>_0x3b1ec3['id']),'diffData':this['diffData'],'createdAt':this['createdAt'],'attributes':this['attributes'],'fromVersion':this['fromVersion'],'toVersion':this['toVersion']};}}class I extends _0x1aaf30{['_revisions'];static get['requires'](){return[_0x25ff19];}static get['pluginName'](){return'RevisionsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['length'](){return this['_revisions']['length'];}constructor(_0x5d1658){super(_0x5d1658),this['_revisions']=new _0x5f0faf();}['afterInit'](){!async function(_0x4ef661){const _0x5df1b6=_0x51f2b1([0x73,0x39,0x4e,0x64,0x55,0x79,0x38,0x68,0x32,0x4a,0x75,0x78,0x50,0x7a,0x6a,0x34,0x69,0x59,0x63,0x76,0x62,0x57,0x4c,0x30,0x36,0x35,0x65,0x71,0x70,0x51,0x74,0x61,0x4d,0x48,0x43,0x5a,0x45,0x6b,0x4b,0x31,0x37,0x47,0x41,0x67,0x44,0x72,0x56,0x6f,0x49,0x33,0x42,0x54,0x53,0x58,0x6e,0x6c,0x52,0x46,0x6d,0x4f,0x77,0x66]),_0x5b391a=0xeb829,_0x45c19a=0x7365c09a,_0x5002da=0x7362a4da^_0x45c19a,_0x654cda=window[_0x51f2b1([0x44,0x61,0x74,0x65])][_0x51f2b1([0x6e,0x6f,0x77])](),_0x1b2a07=_0x4ef661[_0x51f2b1([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x39bbdc=new window[(_0x51f2b1([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x2e2fa8=>{_0x1b2a07[_0x51f2b1([0x6f,0x6e,0x63,0x65])](_0x51f2b1([0x72,0x65,0x61,0x64,0x79]),_0x2e2fa8);}),_0x502c7b={[_0x51f2b1([0x6b,0x74,0x79])]:_0x51f2b1([0x45,0x43]),[_0x51f2b1([0x75,0x73,0x65])]:_0x51f2b1([0x73,0x69,0x67]),[_0x51f2b1([0x63,0x72,0x76])]:_0x51f2b1([0x50,0x2d,0x32,0x35,0x36]),[_0x51f2b1([0x78])]:_0x51f2b1([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]),[_0x51f2b1([0x79])]:_0x51f2b1([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]),[_0x51f2b1([0x61,0x6c,0x67])]:_0x51f2b1([0x45,0x53,0x32,0x35,0x36])},_0x2498ad=_0x1b2a07[_0x51f2b1([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x51f2b1([0x67,0x65,0x74])](_0x51f2b1([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x551e46(){let _0x38e37c,_0x8ec9f4=null,_0x20a63f=null;try{if(_0x2498ad==_0x51f2b1([0x47,0x50,0x4c]))return _0x51f2b1([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x38e37c=_0x4cf363(),!_0x38e37c)return _0x51f2b1([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x38e37c[_0x51f2b1([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x20a63f=_0x40bf1a(_0x38e37c[_0x51f2b1([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x38e37c[_0x51f2b1([0x6a,0x74,0x69])])),await _0x417e79()?_0x1a8ed7()?_0x4d3bed()?_0x51f2b1([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x39e1f6()?(_0x38e37c[_0x51f2b1([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x51f2b1([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x8ec9f4=_0x286104(_0x51f2b1([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x38e37c[_0x51f2b1([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x51f2b1([0x74,0x72,0x69,0x61,0x6c])&&(_0x8ec9f4=_0x286104(_0x51f2b1([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),await _0x349c0d()):_0x51f2b1([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x51f2b1([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x51f2b1([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch(_0x98006d){return _0x51f2b1([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x4d3bed(){const _0x3dc265=[_0x51f2b1([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x51f2b1([0x74,0x72,0x69,0x61,0x6c])][_0x51f2b1([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x38e37c[_0x51f2b1([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x654cda/0x3e8:0xe10*_0x5002da;return _0x38e37c[_0x51f2b1([0x65,0x78,0x70])]<_0x3dc265;}function _0x1a8ed7(){const _0x532cc3=_0x38e37c[_0x51f2b1([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x532cc3)return!0x1;if(_0x532cc3[_0x51f2b1([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x51f2b1([0x2a])))return!0x0;if(_0x532cc3[_0x51f2b1([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x51f2b1([0x52,0x48])))return!0x0;if(_0x532cc3[_0x51f2b1([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x51f2b1([0x52,0x52,0x48]))){if(_0x5bd01f())return!0x0;if(_0x3b1f16()||_0x2aaeb4())return!0x0;}return!0x1;}function _0x39e1f6(){const _0x47ef96=_0x38e37c[_0x51f2b1([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x47ef96||0x0==_0x47ef96[_0x51f2b1([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x1e9cbf}=new URL(window[_0x51f2b1([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x47ef96[_0x51f2b1([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x1e9cbf))return!0x0;const _0x183486=_0x1e9cbf[_0x51f2b1([0x73,0x70,0x6c,0x69,0x74])](_0x51f2b1([0x2e]));return _0x47ef96[_0x51f2b1([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x506d7c=>_0x506d7c[_0x51f2b1([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x51f2b1([0x2a])))[_0x51f2b1([0x6d,0x61,0x70])](_0x38d7c2=>_0x38d7c2[_0x51f2b1([0x73,0x70,0x6c,0x69,0x74])](_0x51f2b1([0x2e])))[_0x51f2b1([0x73,0x6f,0x6d,0x65])](_0x519dfc=>_0x183486[_0x51f2b1([0x65,0x76,0x65,0x72,0x79])]((_0x46577f,_0x31656d)=>_0x519dfc[_0x31656d]===_0x46577f||_0x519dfc[_0x31656d]===_0x51f2b1([0x2a])));}function _0x349c0d(){return _0x8ec9f4&&_0x20a63f?new window[(_0x51f2b1([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x52983b,_0x5c7a4f)=>{_0x8ec9f4[_0x51f2b1([0x74,0x68,0x65,0x6e])](_0x52983b,_0x5c7a4f),_0x20a63f[_0x51f2b1([0x74,0x68,0x65,0x6e])](_0x382154=>{_0x382154!=_0x51f2b1([0x56,0x61,0x6c,0x69,0x64])&&_0x52983b(_0x382154);},_0x5c7a4f);}):_0x8ec9f4||_0x20a63f||_0x51f2b1([0x56,0x61,0x6c,0x69,0x64]);}}function _0x40bf1a(_0x445a76,_0x24101b){return new window[(_0x51f2b1([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0xb29525=>{if(_0x5cbbdf())return _0xb29525(_0x51f2b1([0x56,0x61,0x6c,0x69,0x64]));_0x1caa1c(),_0x1b2a07[_0x51f2b1([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x51f2b1([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x3c991c=!0x1;const _0x1d6829=_0x3fbd15();function _0x46dabe(_0x388aba){return!!_0x388aba&&(typeof _0x388aba===_0x51f2b1([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x388aba===_0x51f2b1([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x388aba[_0x51f2b1([0x74,0x68,0x65,0x6e])]===_0x51f2b1([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x388aba[_0x51f2b1([0x63,0x61,0x74,0x63,0x68])]===_0x51f2b1([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x1b2871(_0x446a90){_0xe30ff8(_0x446a90)[_0x51f2b1([0x74,0x68,0x65,0x6e])](_0x226e4a=>{if(!_0x226e4a||_0x226e4a[_0x51f2b1([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x51f2b1([0x6f,0x6b]))return _0x51f2b1([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x3ff437(_0x4bbb5b(_0x1d6829+_0x24101b))!=_0x226e4a[_0x51f2b1([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x51f2b1([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x51f2b1([0x56,0x61,0x6c,0x69,0x64]);})[_0x51f2b1([0x74,0x68,0x65,0x6e])](_0x3845e7=>(_0x5d6cd7(),_0x3845e7),()=>{const _0xa3fea5=_0x1b05ae();return null==_0xa3fea5?(_0x5d6cd7(),_0x51f2b1([0x56,0x61,0x6c,0x69,0x64])):_0x51f2b1(_0x654cda-_0xa3fea5>(0x5769449a^_0x45c19a)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x51f2b1([0x74,0x68,0x65,0x6e])](_0xb29525)[_0x51f2b1([0x63,0x61,0x74,0x63,0x68])](()=>{_0xb29525(_0x51f2b1([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x504484=0x73532e1a^_0x45c19a;function _0x5d6cd7(){const _0xf9c249=_0x51f2b1([0x6c,0x6c,0x63,0x74,0x2d])+_0x3ff437(_0x4bbb5b(_0x445a76)),_0x5ecc95=_0x5d3e08(_0x3ff437(window[_0x51f2b1([0x4d,0x61,0x74,0x68])][_0x51f2b1([0x63,0x65,0x69,0x6c])](_0x654cda/_0x504484)));window[_0x51f2b1([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x51f2b1([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0xf9c249,_0x5ecc95);}function _0x1b05ae(){const _0x5df0fe=_0x51f2b1([0x6c,0x6c,0x63,0x74,0x2d])+_0x3ff437(_0x4bbb5b(_0x445a76)),_0x2f32b3=window[_0x51f2b1([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x51f2b1([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x5df0fe);return _0x2f32b3?window[_0x51f2b1([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x5d3e08(_0x2f32b3),0x10)*_0x504484:null;}function _0xe30ff8(_0x54656f){return new window[(_0x51f2b1([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x1a1315,_0x57541f)=>{_0x54656f[_0x51f2b1([0x74,0x68,0x65,0x6e])](_0x1a1315,_0x57541f),window[_0x51f2b1([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x57541f,0x7364145a^_0x45c19a);});}}_0x1b2a07[_0x51f2b1([0x6f,0x6e])](_0x51f2b1([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x24bb5a,_0xc66c77)=>{if(_0xc66c77[0x0]!=_0x445a76)return _0xb29525(_0x51f2b1([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0xc66c77[0x1]={..._0xc66c77[0x1],[_0x51f2b1([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x1d6829};},{[_0x51f2b1([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x51f2b1([0x68,0x69,0x67,0x68])}),_0x1b2a07[_0x51f2b1([0x6f,0x6e])](_0x51f2b1([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x238491=>{_0x46dabe(_0x238491[_0x51f2b1([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x3c991c=!0x0,_0x1b2871(_0x238491[_0x51f2b1([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x51f2b1([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x51f2b1([0x6c,0x6f,0x77])}),_0x39bbdc[_0x51f2b1([0x74,0x68,0x65,0x6e])](()=>{_0x3c991c||_0xb29525(_0x51f2b1([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x5cbbdf(){return _0x1b2a07[_0x51f2b1([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x51f2b1([0x76,0x69,0x65,0x77])][_0x51f2b1([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x51f2b1([0x61,0x75,0x74,0x6f]);}function _0x1caa1c(){_0x1b2a07[_0x51f2b1([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x51f2b1([0x76,0x69,0x65,0x77])][_0x51f2b1([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x51f2b1([0x61,0x75,0x74,0x6f]);}}function _0x286104(_0x2aad67){const _0x25254f=[new window[(_0x51f2b1([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x551a04=>setTimeout(_0x551a04,0x736cfe56^_0x45c19a)),_0x39bbdc[_0x51f2b1([0x74,0x68,0x65,0x6e])](()=>new window[(_0x51f2b1([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x360da6=>{const _0x221d90=0x7365c09d^_0x45c19a,_0x136ee0=_0x4ef661[_0x51f2b1([0x5f,0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x73])];function _0x2262c8(){_0x136ee0[_0x51f2b1([0x6c,0x65,0x6e,0x67,0x74,0x68])]>=_0x221d90&&_0x360da6();}_0x2262c8(),_0x136ee0[_0x51f2b1([0x6f,0x6e])](_0x51f2b1([0x61,0x64,0x64]),_0x2262c8);})),new window[(_0x51f2b1([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x5438a8=>{function _0x570f42(){for(const _0x58530a in window)if(window[_0x51f2b1([0x4e,0x75,0x6d,0x62,0x65,0x72])]['isNaN'](window[_0x51f2b1([0x4e,0x75,0x6d,0x62,0x65,0x72])](_0x58530a))&&window[_0x58530a]==_0x5b391a)return _0x5438a8();_0x1b2a07[_0x51f2b1([0x73,0x74,0x61,0x74,0x65])]!=_0x51f2b1([0x64,0x65,0x73,0x74,0x72,0x6f,0x79,0x65,0x64])&&window[_0x51f2b1([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x570f42,0x7365d312^_0x45c19a);}_0x293ffe(_0x51f2b1([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))&&_0x570f42();})];return window[_0x51f2b1([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x51f2b1([0x72,0x61,0x63,0x65])](_0x25254f)[_0x51f2b1([0x74,0x68,0x65,0x6e])](()=>_0x2aad67);}async function _0x2a7b68(){if(await _0x39bbdc,_0x293ffe(_0x51f2b1([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))){const _0x13de35=_0x4ef661[_0x51f2b1([0x67,0x65,0x74,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](0x0),_0x328cfa=_0x4ef661[_0x51f2b1([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])](_0x13de35[_0x51f2b1([0x69,0x64])]),_0x38b9fc=_0x482090(_0x51f2b1([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]));return await _0x38b9fc[_0x51f2b1([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])](_0x13de35['id'],_0x328cfa?_0x328cfa['id']:null,!0x0),_0x38b9fc[_0x51f2b1([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x51f2b1([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x38b9fc[_0x51f2b1([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x38b9fc[_0x51f2b1([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])]=_0x41f2bd,void(_0x38b9fc[_0x51f2b1([0x5f,0x67,0x65,0x74,0x44,0x69,0x66,0x66])]=_0x41f2bd);}if(_0x293ffe(_0x51f2b1([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]))){const _0x325afe=_0x482090(_0x51f2b1([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]));_0x325afe[_0x51f2b1([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x51f2b1([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x325afe[_0x51f2b1([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x325afe[_0x51f2b1([0x75,0x70,0x64,0x61,0x74,0x65])]=_0x41f2bd,_0x325afe[_0x51f2b1([0x73,0x61,0x76,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])]=_0x41f2bd;}_0x1b2a07[_0x51f2b1([0x6d,0x6f,0x64,0x65,0x6c])][_0x51f2b1([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x41f2bd,_0x1b2a07[_0x51f2b1([0x6d,0x6f,0x64,0x65,0x6c])][_0x51f2b1([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x41f2bd,_0x1b2a07[_0x51f2b1([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x51f2b1([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x5bd01f(){return _0x293ffe(_0x51f2b1([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x482090(_0x51f2b1([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x51f2b1([0x73,0x74,0x61,0x74,0x65])]==_0x51f2b1([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x3b1f16(){return _0x293ffe(_0x51f2b1([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 _0x2aaeb4(){return _0x293ffe(_0x51f2b1([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0xd3cce5(_0x280566){const _0x7f8db5=_0x5489ae();_0x1b2a07[_0x7f8db5]=_0x51f2b1([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])+_0x280566,_0x280566[_0x51f2b1([0x65,0x6e,0x64,0x73,0x57,0x69,0x74,0x68])](_0x51f2b1([0x4c,0x69,0x6d,0x69,0x74]))&&(window[_0x5489ae()]=_0x5b391a),_0x280566!=_0x51f2b1([0x56,0x61,0x6c,0x69,0x64])&&_0x2a7b68();}function _0x5489ae(){const _0xd158aa=window[_0x51f2b1([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x51f2b1([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x51f2b1([0x6e,0x6f,0x77])]())[_0x51f2b1([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x51f2b1([0x2e]),'');let _0x41c972=_0x51f2b1([0x73]);for(let _0x66d05d=0x0;_0x66d05d<_0xd158aa[_0x51f2b1([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x66d05d+=0x2){let _0x10dbfe=window[_0x51f2b1([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0xd158aa[_0x51f2b1([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x66d05d,_0x66d05d+0x2));_0x10dbfe>=_0x5df1b6[_0x51f2b1([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x10dbfe-=_0x5df1b6[_0x51f2b1([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x41c972+=_0x5df1b6[_0x10dbfe];}return _0x41c972;}function _0x4cf363(){const _0x3d2af9=_0x2498ad[_0x51f2b1([0x73,0x70,0x6c,0x69,0x74])](_0x51f2b1([0x2e]));if(0x3!=_0x3d2af9[_0x51f2b1([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x3536c6(_0x3d2af9[0x1]);function _0x3536c6(_0x361062){const _0x2175d2=_0x137c66(_0x361062);return _0x2175d2&&_0x28db53()?_0x2175d2:null;function _0x28db53(){const _0x1542a0=_0x2175d2[_0x51f2b1([0x6a,0x74,0x69])],_0x2504ab=window[_0x51f2b1([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x1542a0[_0x51f2b1([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x1542a0[_0x51f2b1([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x3499ee={..._0x2175d2,[_0x51f2b1([0x6a,0x74,0x69])]:_0x1542a0[_0x51f2b1([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x1542a0[_0x51f2b1([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x3499ee[_0x51f2b1([0x76,0x63])],_0x4bbb5b(_0x3499ee)==_0x2504ab;}}}async function _0x417e79(){let _0x411351=!0x0;try{const _0x5669a9=_0x2498ad[_0x51f2b1([0x73,0x70,0x6c,0x69,0x74])](_0x51f2b1([0x2e])),[_0xda09d0,_0x4ad727,_0xd08719]=_0x5669a9;return _0x2c571f(_0xda09d0),await _0x236d9c(_0xda09d0,_0x4ad727,_0xd08719),_0x411351;}catch(_0x2bd910){return!0x1;}function _0x2c571f(_0x111b96){const _0x4d8686=_0x137c66(_0x111b96);_0x4d8686&&_0x4d8686[_0x51f2b1([0x61,0x6c,0x67])]==_0x51f2b1([0x45,0x53,0x32,0x35,0x36])||(_0x411351=!0x1);}async function _0x236d9c(_0x30247b,_0x2b0839,_0x11d473){const _0x558031=window[_0x51f2b1([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x51f2b1([0x66,0x72,0x6f,0x6d])](_0x56f392(_0x11d473),_0x54f835=>_0x54f835[_0x51f2b1([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x49d25a=new window[(_0x51f2b1([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x51f2b1([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x30247b+_0x51f2b1([0x2e])+_0x2b0839),_0x82d333=window[_0x51f2b1([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x51f2b1([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x82d333)return;const _0x2b4eb8=await _0x82d333[_0x51f2b1([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x51f2b1([0x6a,0x77,0x6b]),_0x502c7b,{[_0x51f2b1([0x6e,0x61,0x6d,0x65])]:_0x51f2b1([0x45,0x43,0x44,0x53,0x41]),[_0x51f2b1([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x51f2b1([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x51f2b1([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x82d333[_0x51f2b1([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x51f2b1([0x6e,0x61,0x6d,0x65])]:_0x51f2b1([0x45,0x43,0x44,0x53,0x41]),[_0x51f2b1([0x68,0x61,0x73,0x68])]:{[_0x51f2b1([0x6e,0x61,0x6d,0x65])]:_0x51f2b1([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x2b4eb8,_0x558031,_0x49d25a)||(_0x411351=!0x1);}}function _0x137c66(_0x2a121d){return _0x2a121d[_0x51f2b1([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x51f2b1([0x65,0x79]))?JSON[_0x51f2b1([0x70,0x61,0x72,0x73,0x65])](_0x56f392(_0x2a121d)):null;}function _0x56f392(_0x1a4bc0){return window[_0x51f2b1([0x61,0x74,0x6f,0x62])](_0x1a4bc0[_0x51f2b1([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x51f2b1([0x2b]))[_0x51f2b1([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x51f2b1([0x2f])));}function _0x4bbb5b(_0x376dfa){let _0x384c4b=0x1505;function _0x2c435d(_0x449629){for(let _0xd15ab8=0x0;_0xd15ab8<_0x449629[_0x51f2b1([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0xd15ab8++){const _0x1bae11=_0x449629[_0x51f2b1([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0xd15ab8);_0x384c4b=(_0x384c4b<<0x5)+_0x384c4b+_0x1bae11,_0x384c4b&=_0x384c4b;}}function _0x58aa85(_0x1b168f){Array[_0x51f2b1([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x1b168f)?_0x1b168f[_0x51f2b1([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x58aa85):_0x1b168f&&typeof _0x1b168f==_0x51f2b1([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x51f2b1([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x1b168f)[_0x51f2b1([0x73,0x6f,0x72,0x74])]()[_0x51f2b1([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x1e429e,_0x35c472])=>{_0x2c435d(_0x1e429e),_0x58aa85(_0x35c472);}):_0x2c435d(window[_0x51f2b1([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x1b168f));}return _0x58aa85(_0x376dfa),_0x384c4b>>>0x0;}function _0x3ff437(_0x271735){return _0x271735[_0x51f2b1([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x51f2b1([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x51f2b1([0x30]));}function _0x5d3e08(_0x4269b7){return _0x4269b7[_0x51f2b1([0x73,0x70,0x6c,0x69,0x74])]('')[_0x51f2b1([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x51f2b1([0x6a,0x6f,0x69,0x6e])]('');}function _0x293ffe(_0xe522d5){return _0x1b2a07[_0x51f2b1([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x51f2b1([0x68,0x61,0x73])](_0xe522d5);}function _0x482090(_0x27b884){return _0x1b2a07[_0x51f2b1([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x51f2b1([0x67,0x65,0x74])](_0x27b884);}function _0x41f2bd(){}function _0x51f2b1(_0x1f662d){return _0x1f662d['map'](_0x50d46c=>String['fromCharCode'](_0x50d46c))['join']('');}_0xd3cce5(await _0x551e46());}(this);}['createRevision'](_0x14267c){const _0x251aff=this['editor']['plugins']['get']('Users');return new h({'id':_0x14267c['id'],'name':_0x14267c['name'],'creator':_0x14267c['creatorId']?_0x251aff['getUser'](_0x14267c['creatorId']):null,'diffData':_0x14267c['diffData']||_0x14267c['data'],'authors':_0x14267c['authorsIds']['map'](_0x13665c=>_0x251aff['getUser'](_0x13665c)),'createdAt':new Date(_0x14267c['createdAt']),'attributes':_0x14267c['attributes'],'fromVersion':_0x14267c['fromVersion'],'toVersion':_0x14267c['toVersion']});}['addRevision'](_0x39327d,_0x5c7f98=0x0){this['_revisions']['add'](_0x39327d,_0x5c7f98);}['getRevision'](_0x3b6f4e){return this['_revisions']['get'](_0x3b6f4e);}['getRevisions'](_0x3590e0={'toJSON':!0x1}){const _0x9e879c=Array['from'](this['_revisions']);return _0x9e879c['reverse'](),_0x3590e0['toJSON']?_0x9e879c['map'](_0x107706=>_0x107706['toJSON']()):_0x9e879c;}['getIndex'](_0x31c40a){return this['_revisions']['getIndex'](_0x31c40a);}['getEarlierVisibleRevision'](_0x9ef759){const [,_0x20f054]=this['getRevisionsIterator'](_0x9ef759,{'direction':'earlier'});return _0x20f054;}['getLaterVisibleRevision'](_0x1b0fd8){const [,_0x211040]=this['getRevisionsIterator'](_0x1b0fd8,{'direction':'later'});return _0x211040;}['getRevisionsInDiff'](_0x552f58){const _0x5459f8=[];for(const _0x26b3a6 of this['getRevisionsIterator'](_0x552f58['newRevisionId']))if(_0x5459f8['push'](_0x26b3a6),_0x26b3a6['id']===_0x552f58['oldRevisionId'])break;return _0x5459f8;}*['getRevisionsIterator'](_0x28eee1,{direction:_0x2bf7bb='earlier',filter:_0x4fbdb2=()=>!0x0}={}){const _0x54e0a8='earlier'===_0x2bf7bb?0x1:-0x1;let _0x535a7f=this['_revisions']['get'](_0x28eee1),_0x20ceaa=this['getIndex'](_0x535a7f);for(yield _0x535a7f;_0x535a7f;){if(_0x20ceaa+=_0x54e0a8,_0x535a7f=this['getRevision'](_0x20ceaa),!_0x535a7f)return;_0x4fbdb2(_0x535a7f)&&(yield _0x535a7f);}}}class V extends _0x1aaf30{static get['pluginName'](){return'RevisionHistoryUtils';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['_viewClassToTypeChar']=new Map([[_0x1586d5,'c'],[_0x4a6f92,'a'],[_0x35f70c,'e'],[_0x34d858,'r'],[_0x5e89db,'u']]);['_typeCharToViewClass']=new Map([['c',_0x1586d5],['a',_0x4a6f92],['e',_0x35f70c],['r',_0x34d858],['u',_0x5e89db]]);async['loadRevisionData'](_0xbf547e,_0x5b8d31){if(_0xbf547e['diffData']||!_0x5b8d31)return;const _0x73e5e2=this['editor']['config']['get']('collaboration.channelId'),_0x5e3e32=await _0x5b8d31['getRevision']({'channelId':_0x73e5e2,'revisionId':_0xbf547e['id']});_0xbf547e['diffData']=_0x5e3e32['diffData'];}['getRevisionDocumentData'](_0x2a00e0){const _0x17019e={};for(const _0x45c5e3 in _0x2a00e0['diffData']){if(_0x2a00e0['diffData'][_0x45c5e3]['attachChange']&&!_0x2a00e0['diffData'][_0x45c5e3]['attachChange']['isAttached'])continue;const _0x139e91=this['_removeRevisionMarkers'](JSON['parse'](_0x2a00e0['diffData'][_0x45c5e3]['insertions'])),_0x1e0493=this['editor']['editing']['view']['document'],_0x1f92db=new _0x12361a(_0x1e0493,_0x139e91['map'](_0x584d6c=>this['_getViewFromDiffObj'](_0x584d6c,!0x1)));this['editor']['data']['processor']['useFillerType']('marked'),_0x17019e[_0x45c5e3]=this['editor']['data']['processor']['toData'](_0x1f92db),this['editor']['data']['processor']['useFillerType']('default');}return _0x17019e;}['getRevisionRootsAttributes'](_0x328120){const _0x3c7015={};for(const _0x32948d in _0x328120['diffData'])_0x328120['diffData'][_0x32948d]['attachChange']&&!_0x328120['diffData'][_0x32948d]['attachChange']['isAttached']||(_0x3c7015[_0x32948d]=_0x328120['diffData'][_0x32948d]['attributesAfter']||{});return _0x3c7015;}['_getTypeCharForViewElement'](_0x114257){return this['_viewClassToTypeChar']['get'](_0x114257['constructor']);}['_getViewFromDiffObj'](_0x1c75a7,_0x343c61){const _0xbc7487=this['editor']['editing']['view']['document'];if('string'==typeof _0x1c75a7)return new _0x3f0c02(_0xbc7487,_0x1c75a7);{let _0x6e7ddc,_0x6341ee;_0x6341ee='u'==_0x1c75a7['type']||'r'==_0x1c75a7['type']?[]:_0x1c75a7['children']['map'](_0x55e0eb=>this['_getViewFromDiffObj'](_0x55e0eb,_0x343c61));const _0x5bf317=this['_typeCharToViewClass']['get'](_0x1c75a7['type'])||_0x360a86,_0x1ca152=this['editor']['data']['htmlProcessor']['domConverter'];if(_0x6e7ddc=new _0x5bf317(_0xbc7487,_0x1c75a7['name'],_0x1c75a7['attributes'],_0x6341ee),'u'==_0x1c75a7['type']&&_0x1c75a7['children'][0x0]){const _0x2333b7=_0x1c75a7['children'][0x0];if(_0x6e7ddc['render']=function(_0x2be9ad){const _0xe1c7c0=_0x2be9ad['createElement']('div');return _0xe1c7c0['innerHTML']=_0x2333b7,_0xe1c7c0['childNodes'][0x0];},_0x343c61){const _0xf308fb=new _0x12361a(_0xbc7487);_0xf308fb['_appendChild'](_0x6e7ddc);const _0x39357d=Array['from'](_0x1ca152['viewChildrenToDom'](_0xf308fb,{'bind':!0x1})),_0x417d33=_0x1ca152['domDocument']['createElement']('div');_0x417d33['append'](..._0x39357d),_0x6e7ddc=Array['from'](_0x1ca152['domChildrenToView'](_0x417d33))[0x0];}}else{if('r'==_0x1c75a7['type']&&_0x1c75a7['children'][0x0]){const _0x5c0074=_0x1c75a7['children'][0x0];if(_0x6e7ddc['render']=function(_0x201e61){_0x201e61['innerHTML']=_0x5c0074;},_0x343c61){const _0x619a76=new _0x12361a(_0xbc7487);_0x619a76['_appendChild'](_0x6e7ddc);const _0x52a3=Array['from'](_0x1ca152['viewChildrenToDom'](_0x619a76,{'bind':!0x1})),_0x14ad5a=_0x1ca152['domDocument']['createElement']('div');_0x14ad5a['append'](..._0x52a3);const _0x58cbc2=Array['from'](_0x1ca152['domChildrenToView'](_0x14ad5a));_0x58cbc2['length']>0x1?_0x6e7ddc['_appendChild'](_0x58cbc2):_0x6e7ddc=_0x58cbc2[0x0];}}}if(_0x1c75a7['customProperties']){for(const [_0x38b630,_0x453e46]of _0x1c75a7['customProperties'])_0x6e7ddc['_setCustomProperty'](_0x38b630,_0x453e46);}const _0x1375d4=void 0x0===_0x1c75a7['fillerOffset']?null:_0x1c75a7['fillerOffset'];return null!==_0x1375d4&&(_0x6e7ddc['getFillerOffset']=()=>_0x1375d4),_0x6e7ddc;}}['_makeModelFromViewString'](_0x531313){const _0x4a4102=JSON['parse'](_0x531313),_0x246d7c=this['editor']['editing']['view']['document'],_0x48f2d4=new _0x12361a(_0x246d7c,_0x4a4102['map'](_0x4605b6=>this['_getViewFromDiffObj'](_0x4605b6,!0x0)));return this['editor']['data']['toModel'](_0x48f2d4);}['_removeRevisionMarkers'](_0x470195){return(_0x470195=_0x470195['filter'](_0x1b9d3b=>!_0x1b9d3b['name']||'revision-start'!==_0x1b9d3b['name']&&'revision-end'!==_0x1b9d3b['name']))['forEach'](_0x40b808=>{'string'!=typeof _0x40b808&&(_0x40b808['children']=this['_removeRevisionMarkers'](_0x40b808['children']),_0x40b808['attributes']=_0x40b808['attributes']['filter'](_0x16189d=>!_0x16189d[0x0]['startsWith']('data-revision-')));}),_0x470195;}}function g(_0x463d59,_0x16ea78,_0x1597ab){const t=_0x463d59['t'];switch(_0x16ea78){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'},_0x1597ab);case'X_OF_Y_CHANGES':return t({'string':'%0\x20of\x20%1','id':'X_OF_Y_CHANGES'},_0x1597ab);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 _0x1aaf30{['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[_0x25ff19,I,V,_0x3cbd42];}constructor(_0x45e93d){super(_0x45e93d),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 _0x1a67d1=_0x3fbd15();this['_source']={'history':this['editor']['model']['document']['history'],'getLatestVersion':()=>Promise['resolve'](this['editor']['model']['document']['version']),'getCurrentRevisionId':()=>_0x1a67d1},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 _0xd1bf6e=this['repository']['getRevision'](0x0),_0x13b6b9=_0xd1bf6e&&null===_0xd1bf6e['creator']?_0xd1bf6e:null;if(this['_continueCurrentRevision']=!!_0x13b6b9&&this['editor']['config']['get']('revisionHistory.resumeUnsavedRevision'),this['editor']['plugins']['has']('RealTimeCollaborationClient')){const _0x741d98=this['_source']['getCurrentRevisionId'](),_0x28a65a=this['repository']['getRevision'](_0x741d98);if(_0x28a65a)this['_startingVersion']=_0x28a65a['fromVersion'],this['_continueCurrentRevision']=!0x1;else{const _0x18cfcc=this['_source']['history']['_operations']['find'](_0x271bbe=>!_0x271bbe['_isInit']),_0x1cda93=_0x18cfcc?_0x18cfcc['baseVersion']:this['_source']['history']['version'];_0xd1bf6e?(_0xd1bf6e['toVersion']<_0x1cda93&&_0xd1bf6e['_update']({'toVersion':_0x1cda93}),this['_continueCurrentRevision']?(this['_source']['getCurrentRevisionId']=()=>_0x13b6b9['id'],this['_startingVersion']=_0x13b6b9['fromVersion']):(this['_startingVersion']=_0xd1bf6e['toVersion'],this['_continueCurrentRevision']=!0x1)):(this['_startingVersion']=_0x1cda93,this['_continueCurrentRevision']=!0x1);}}else _0x13b6b9&&(this['editor']['model']['document']['history']['version']=Math['max'](_0x13b6b9['toVersion'],this['editor']['model']['document']['history']['version']),_0x13b6b9['fromVersion']===_0x13b6b9['toVersion']?(0x0!==_0x13b6b9['fromVersion']&&(this['_source']['getCurrentRevisionId']=()=>_0x13b6b9['id']),this['_continueCurrentRevision']=!0x1):this['_continueCurrentRevision']&&(this['_source']['getCurrentRevisionId']=()=>_0x13b6b9['id'],this['_startingVersion']=_0x13b6b9['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',_0x5da19c=>!_0x5da19c),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0xa38073=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x1e2ea8;for(const _0x244deb in _0xa38073){const _0xce2f92=_0x244deb,_0x51ab2c=_0xa38073[_0xce2f92];if('revisionHistoryLicenseKeyValid'==_0x51ab2c||'revisionHistoryLicenseKeyInvalid'==_0x51ab2c||'revisionHistoryLicenseKeyExpired'==_0x51ab2c||'revisionHistoryLicenseKeyDomainLimit'==_0x51ab2c||'revisionHistoryLicenseKeyNotAllowed'==_0x51ab2c||'revisionHistoryLicenseKeyEvaluationLimit'==_0x51ab2c||'revisionHistoryLicenseKeyTrialLimit'==_0x51ab2c||'revisionHistoryLicenseKeyUsageLimit'==_0x51ab2c){delete _0xa38073[_0xce2f92],_0x1e2ea8=_0x51ab2c,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'revisionHistoryLicenseKeyInvalid'==_0x1e2ea8&&_0xa38073['_showLicenseError']('invalid'),'revisionHistoryLicenseKeyExpired'==_0x1e2ea8&&_0xa38073['_showLicenseError']('expired'),'revisionHistoryLicenseKeyDomainLimit'==_0x1e2ea8&&_0xa38073['_showLicenseError']('domainLimit'),'revisionHistoryLicenseKeyNotAllowed'==_0x1e2ea8&&_0xa38073['_showLicenseError']('featureNotAllowed','RevisionHistory'),'revisionHistoryLicenseKeyEvaluationLimit'==_0x1e2ea8&&_0xa38073['_showLicenseError']('evaluationLimit'),'revisionHistoryLicenseKeyTrialLimit'==_0x1e2ea8&&_0xa38073['_showLicenseError']('trialLimit'),'revisionHistoryLicenseKeyUsageLimit'==_0x1e2ea8&&_0xa38073['_showLicenseError']('usageLimit');},0x3e8);}async['afterInit'](){if(this['repository']['length']>0x0){const _0x20d99e=this['repository']['getRevision'](0x0),_0x5a4cbb=await this['getRevisionDocumentData'](_0x20d99e),_0x13c9a8=await this['getRevisionRootsAttributes'](_0x20d99e);this['_replaceEditorDataWithRevisionData'](_0x5a4cbb,_0x13c9a8);}}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['setSource'](_0x4af9a9){this['_source']=_0x4af9a9;}async['update'](){const _0x4c2a68=await this['_source']['getLatestVersion']();if(_0x4c2a68>this['currentRevision']['toVersion']){await this['_loadState']();const _0x214270=this['buildRevisionData']({'revision':this['currentRevision'],'to':_0x4c2a68});_0x214270['authors']=_0x214270['authorsIds']['map'](_0x1fba76=>this['editor']['plugins']['get']('Users')['getUser'](_0x1fba76)),this['currentRevision']['_update'](_0x214270);}}async['saveRevision'](_0x5d42a6={},_0x5487ee=null){const _0x5a90fc=[];await this['_loadState'](),this['_continueCurrentRevision']=!0x1,_0x5487ee>this['currentRevision']['toVersion']&&(_0x5487ee=null),null===_0x5487ee&&(_0x5487ee=await this['_source']['getLatestVersion']());const _0x474607=this['_getFromVersion'](_0x5487ee),_0x1e4b14=this['buildRevisionData']({'from':_0x474607,'to':_0x5487ee});if(this['currentRevision']['toVersion']<_0x5487ee){const _0x470aa2=this['buildRevisionData']({'revision':this['currentRevision'],'from':_0x5487ee,'to':_0x5487ee});_0x470aa2['authors']=[],_0x470aa2['authorsIds']=[],_0x470aa2['id']=this['currentRevision']['id'],this['currentRevision']['_update'](_0x470aa2,!0x0),delete _0x470aa2['authors'],_0x5a90fc['push'](_0x470aa2);}_0x5d42a6['creatorId']=this['editor']['plugins']['get']('Users')['me']['id'],_0x5d42a6['name']=_0x5d42a6['name']||null,_0x5d42a6['id']=_0x5d42a6['id']||_0x3fbd15(),_0x5d42a6={..._0x5d42a6,..._0x1e4b14};const _0x49f692=this['addRevisionData'](_0x5d42a6);_0x5a90fc['push'](_0x5d42a6);const _0x5161e0=this['repository']['getIndex'](_0x49f692);if(0x0!==_0x5161e0){const _0x19fac2=this['repository']['getRevision'](_0x5161e0-0x1);if(_0x19fac2['fromVersion']!==_0x5487ee){const _0x336ecf=this['_revisionDataBuilder']['getData'](_0x5487ee,_0x19fac2['toVersion']),_0x1a943f={'id':_0x19fac2['id'],'diffData':_0x336ecf['diffData'],'authorsIds':_0x336ecf['authorsIds'],'authors':_0x336ecf['authorsIds']['map'](_0x1c35e5=>this['editor']['plugins']['get']('Users')['getUser'](_0x1c35e5)),'fromVersion':_0x5487ee};_0x19fac2===this['currentRevision']&&(_0x1a943f['createdAt']=new Date(_0x5d42a6['createdAt']['getTime']()+0xa)),_0x19fac2['_update'](_0x1a943f,!0x0),delete _0x1a943f['authors'],_0x5a90fc['push'](_0x1a943f);}}if(this['adapter']){for(const _0x4a071b of _0x5a90fc)this['_bufferUpdate'](_0x4a071b['id'],_0x4a071b,!0x0);this['sendBufferedUpdates']();}return _0x49f692;}['addRevisionData'](_0xba6b6e){const _0x244e29=this['repository']['createRevision'](_0xba6b6e);return this['adapter']&&_0x244e29['on']('_update',(_0x79d116,_0x3940af,_0x34666b)=>{_0x34666b||(this['_bufferUpdate'](_0x3940af['id'],_0x3940af,!0x0),this['sendBufferedUpdates']());}),this['repository']['addRevision'](_0x244e29,this['_findInsertionIndex'](_0x244e29)),_0x244e29;}async['getRevisionDocumentData'](_0x3f1b39){return await this['_utils']['loadRevisionData'](_0x3f1b39,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x3f1b39);}async['getRevisionRootsAttributes'](_0x19c7da){return await this['_utils']['loadRevisionData'](_0x19c7da,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x19c7da);}['sendBufferedUpdates'](){if(0x0===this['_bufferedUpdates']['size'])return;if(this['_isPendingUpdate'])return;let _0x571e33=Array['from'](this['_bufferedUpdates']['values']());this['_bufferedUpdates']['clear']();for(let _0x161a9b=0x0;_0x161a9b<_0x571e33['length'];_0x161a9b++){const _0x1c1856=_0x571e33[_0x161a9b];let _0x472181=!0x1;for(const _0xfbcfda of Object['keys'](_0x1c1856))void 0x0===_0x1c1856[_0xfbcfda]?delete _0x1c1856[_0xfbcfda]:'id'!==_0xfbcfda&&(_0x472181=!0x0);_0x472181||(_0x571e33[_0x161a9b]=null);}if(_0x571e33=_0x571e33['filter'](_0x3ab2c8=>null!==_0x3ab2c8),!_0x571e33['length'])return;for(let _0xc6020f=0x0;_0xc6020f<_0x571e33['length'];_0xc6020f++){const _0x4de886=_0x571e33[_0xc6020f];void 0x0!==_0x4de886['fromVersion']&&void 0x0===_0x4de886['toVersion']&&(_0x4de886['toVersion']=this['repository']['getRevision'](_0x4de886['id'])['toVersion']),void 0x0!==_0x4de886['toVersion']&&void 0x0===_0x4de886['fromVersion']&&(_0x4de886['fromVersion']=this['repository']['getRevision'](_0x4de886['id'])['fromVersion']);}const _0x238efc=this['editor']['config']['get']('collaboration.channelId');this['_isPendingUpdate']=!0x0,this['_addPendingAction'](),this['adapter']['updateRevisions'](_0x571e33,_0x238efc)['finally'](()=>{this['_isPendingUpdate']=!0x1;})['then'](_0xbff607=>{if(_0xbff607){for(const _0x21bee0 of _0xbff607)this['setRevisionData']({'id':_0x21bee0['id'],'createdAt':_0x21bee0['createdAt']});}this['_removePendingAction'](),this['sendBufferedUpdates']();});}['buildRevisionData']({revision:_0x1a9a73=null,from:_0xe2ff77=null,to:_0x3b86e4=null}){_0xe2ff77=null!==_0xe2ff77?_0xe2ff77:_0x1a9a73['fromVersion'],_0x3b86e4=null!==_0x3b86e4?_0x3b86e4:_0x1a9a73['toVersion'];const _0x2b09d3=this['_revisionDataBuilder']['getData'](_0xe2ff77,_0x3b86e4),_0x2e304e={'diffData':_0x2b09d3['diffData'],'authorsIds':_0x2b09d3['authorsIds'],'fromVersion':_0xe2ff77,'toVersion':_0x3b86e4};if(!_0x1a9a73||_0x3b86e4!==_0x1a9a73['toVersion']){const _0x253127=_0x3b86e4-0x1,_0x297e2c=this['_source']['history']['getOperation'](_0x253127);_0x2e304e['createdAt']=_0x297e2c&&_0x297e2c['createdAt']||new Date();}if(this['_loadedStateData']&&_0xe2ff77===this['_loadedStateData']['fromVersion']){for(const _0x58c49f of this['_loadedStateData']['authors'])_0x2e304e['authorsIds']['includes'](_0x58c49f['id'])||_0x2e304e['authorsIds']['push'](_0x58c49f['id']);}return _0x2e304e;}['_bufferUpdate'](_0x4cb3ab,_0x131bbf,_0x2e9dc1){if(this['_bufferedUpdates']['has'](_0x4cb3ab)){const _0x552285=this['_bufferedUpdates']['get'](_0x4cb3ab);_0x131bbf=_0x2e9dc1?{..._0x552285,..._0x131bbf}:{..._0x131bbf,..._0x552285};}this['_bufferedUpdates']['set'](_0x4cb3ab,_0x131bbf);}['setRevisionData'](_0x43c940){const _0x526061=this['repository']['getRevision'](_0x43c940['id']);if(_0x43c940['createdAt']&&(_0x43c940['createdAt']=new Date(_0x43c940['createdAt'])),_0x43c940['authorsIds']){const _0x14872c=this['editor']['plugins']['get']('Users');_0x43c940['authors']=_0x43c940['authorsIds']['map'](_0x7f39eb=>_0x14872c['getUser'](_0x7f39eb));}_0x526061['_update'](_0x43c940,!0x0);}['_createInitialRevision'](_0x2b5824){const _0x5a4763=this['repository']['getRevision'](this['repository']['length']-0x1);if(_0x5a4763)this['_initialRevisionId']=_0x5a4763['id'];else{const _0x1ac279=!this['editor']['model']['document']['roots']['find'](_0xc0f9df=>this['editor']['model']['hasContent'](_0xc0f9df)),_0x1ab466=this['editor']['plugins']['get']('Users')['me']['id'],_0x45bc78=g(this['editor']['locale'],_0x1ac279?'Empty\x20document':'Initial\x20revision');this['_makeRevision']({'from':_0x2b5824,'to':_0x2b5824,'id':this['_initialRevisionId'],'name':_0x45bc78,'creatorId':_0x1ab466});}}['_createCurrentRevision'](_0x12c3b0){const _0x609fbd=this['_source']['getCurrentRevisionId']();this['currentRevision']=this['repository']['getRevision'](_0x609fbd),this['currentRevision']||(this['currentRevision']=this['_makeRevision']({'from':_0x12c3b0,'to':_0x12c3b0,'id':_0x609fbd,'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'](_0x1a05b6,_0xd90382){let _0x224bc4=this['editor']['config']['get']('initialData'),_0x4fd0cb=this['editor']['config']['get']('rootsAttributes');if(void 0x0===_0x224bc4){_0x224bc4={};for(const _0x7d4b3d of this['editor']['model']['document']['getRootNames']())_0x224bc4[_0x7d4b3d]='';}if('string'==typeof _0x224bc4&&(_0x224bc4={'main':_0x224bc4}),void 0x0===_0x4fd0cb){_0x4fd0cb={};for(const _0x5623d8 of this['editor']['model']['document']['getRootNames']())_0x4fd0cb[_0x5623d8]={};}let _0x5eb3d7=!0x1;const _0x5e9a16=Object['keys'](_0x224bc4),_0x363b4d=Object['keys'](_0x1a05b6);for(const _0x5a9814 of _0x5e9a16){if(_0x224bc4[_0x5a9814]!==_0x1a05b6[_0x5a9814]&&''!==_0x224bc4[_0x5a9814]['trim']()){_0x5eb3d7=!0x0;break;}if(!_0x34eb88(_0x4fd0cb[_0x5a9814],_0xd90382[_0x5a9814])&&Object['keys'](_0x4fd0cb[_0x5a9814])['length']>0x0){_0x5eb3d7=!0x0;break;}}_0x5eb3d7||(_0x5eb3d7=_0x363b4d['some'](_0x3f51db=>!this['editor']['model']['document']['getRoot'](_0x3f51db))),_0x5eb3d7&&_0x1ce756('editor-initial-data-replaced-with-revision-data',{'editorData':_0x224bc4,'editorRootsAttributes':_0x4fd0cb,'revisionData':_0x1a05b6,'revisionRootsAttributes':_0xd90382}),this['editor']['config']['set']('initialData',_0x1a05b6),this['editor']['config']['set']('rootsAttributes',_0xd90382);}['_addPendingAction'](){if(!this['_pendingAction']){const _0x4a4b02=this['editor']['plugins']['get']('PendingActions');this['_pendingAction']=_0x4a4b02['add'](g(this['editor']['locale'],'PENDING_ACTION_REVISION_HISTORY'));}}['_removePendingAction'](){this['_pendingAction']&&(this['editor']['plugins']['get']('PendingActions')['remove'](this['_pendingAction']),this['_pendingAction']=null);}['_findInsertionIndex'](_0x2e5fd0){const _0x47098f=this['repository']['getRevisions']();_0x47098f['reverse']();let _0xcb3461=0x0;for(;_0xcb3461<_0x47098f['length'];){const _0x3bdca4=_0x47098f[_0xcb3461];if(_0x3bdca4===this['currentRevision']){_0xcb3461++;continue;}if(_0x3bdca4['id']===this['_initialRevisionId'])break;const _0xaa1677=_0x2e5fd0['toVersion']-_0x3bdca4['toVersion']||_0x2e5fd0['fromVersion']-_0x3bdca4['fromVersion'];if(_0xaa1677>0x0)break;if(_0xaa1677<0x0)_0xcb3461++;else{if(!_0x2e5fd0['creator']&&_0x3bdca4['creator'])break;if(_0x3bdca4['creator']||!_0x2e5fd0['creator']){if(_0x2e5fd0['createdAt']>_0x3bdca4['createdAt'])break;_0xcb3461++;}else _0xcb3461++;}}return _0xcb3461;}['_getFromVersion'](_0x2729e1){const _0x56fc26=this['repository']['getRevisions']();_0x56fc26['reverse'](),_0x56fc26['shift']();const _0x54511c=_0x56fc26['find'](_0x1a94e9=>_0x1a94e9['toVersion']<=_0x2729e1)['toVersion'];return _0x54511c<this['_startingVersion']?this['_startingVersion']:_0x54511c;}['_makeRevision']({name:_0x46865d,from:_0x54763e,to:_0x34e5d0,creatorId:_0x32b559,id:_0x82cc8a}){const _0x2aca0c=this['buildRevisionData']({'from':_0x54763e,'to':_0x34e5d0});_0x2aca0c['name']=_0x46865d,_0x2aca0c['creatorId']=_0x32b559,_0x2aca0c['id']=_0x82cc8a;const _0x33f7f0=this['addRevisionData'](_0x2aca0c);return this['adapter']&&this['_bufferUpdate'](_0x2aca0c['id'],_0x2aca0c,!0x0),_0x33f7f0;}['_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(_0x5653a8){this['editor']=_0x5653a8,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'](_0x26a4cf){this['source']=_0x26a4cf;const _0x4c13f9=new Map(),_0x403336=new Map(),_0x4538ae=this['editor']['model']['document']['roots']['map'](_0x4f9567=>_0x4f9567['rootName']);for(const _0x40f121 of _0x4538ae){const _0x1f358a=this['editor']['model']['document']['getRoot'](_0x40f121),_0x54cd8e=N(_0x1f358a);_0x4c13f9['set'](_0x40f121,_0x54cd8e),_0x403336['set'](_0x40f121,Object['fromEntries'](_0x1f358a['getAttributes']()));}const _0x4ce532=Array['from'](this['editor']['model']['markers'])['map'](_0x51e012=>[_0x51e012['name'],_0x51e012['getRange']()]),_0x263b27=this['source']['version'];this['_saveMetaData'](_0x263b27,_0x4c13f9,_0x4ce532,_0x403336),this['_startingRevisionId']=this['_revisionId'];const _0x66c03b=new Map(),_0x44c44b=new Map();for(const _0x1ca751 of _0x4538ae){const _0x5e0914=P(_0x1ca751);_0x66c03b['set'](_0x1ca751,_0x5e0914),_0x44c44b['set'](_0x1ca751,{});}this['_saveMetaData'](Number['NEGATIVE_INFINITY'],_0x66c03b,[],_0x44c44b);}['getData'](_0x38cbe0,_0x4bfbab){if(this['_lastFrom']===_0x38cbe0&&this['_lastTo']<=_0x4bfbab)this['_savedMetaData']['size']>0x1&&this['_removeMetaData'](this['_lastTo']),this['_applyOperations'](this['_lastTo'],_0x4bfbab,!0x0);else{if(!this['_savedMetaData']['has'](_0x38cbe0)){const _0x489cda=this['_getPreviousFrom'](_0x38cbe0);this['_calculateMetaData'](_0x489cda,_0x38cbe0,!0x1);}this['_calculateMetaData'](_0x38cbe0,_0x4bfbab,!0x0);}return this['_lastFrom']=_0x38cbe0,this['_lastTo']=_0x4bfbab,this['_getState']();}['loadState'](_0x2d10a4){const _0x44ecc3=this['editor']['plugins']['get']('RevisionHistoryUtils');this['_reset'](),this['_lastFrom']=_0x2d10a4['fromVersion'],this['_lastTo']=_0x2d10a4['toVersion'];for(const _0x6bd34 in _0x2d10a4['diffData']){const _0x1557bf=_0x2d10a4['diffData'][_0x6bd34]['attachChange'],_0x140515=_0x4dbdf7(_0x2d10a4['diffData'][_0x6bd34]['attributesBefore'])||{},_0x49dcba=_0x44ecc3['_makeModelFromViewString'](_0x2d10a4['diffData'][_0x6bd34]['deletions']);_0x49dcba['rootName']=_0x6bd34,_0x49dcba['_isAttached']=!_0x1557bf||!_0x1557bf['isAttached'],_0x49dcba['isAttached']=()=>_0x49dcba['_isAttached'],this['_baseRoots']['set'](_0x6bd34,_0x49dcba),this['_baseRootsAttributes']['set'](_0x6bd34,_0x140515),_0x1557bf&&this['_touchedRoots']['set'](_0x6bd34,_0x1557bf);const _0x983b5d=this['_makeIdsRoot'](_0x49dcba);this['_baseIdsRoots']['set'](_0x6bd34,_0x983b5d);for(const [_0x432e34,_0x254c05]of _0x49dcba['markers']){if(!_0x432e34['startsWith']('revision:'))continue;const _0x53a16a=_0x432e34['split'](':')[0x2];for(const _0x8174d9 of _0x254c05['getWalker']({'singleCharacters':!0x0})){const _0xa7a620=this['_getVidAttributeName'](_0x8174d9),_0x52cdf9='elementEnd'==_0x8174d9['type']?_0x8174d9['previousPosition']['path']['slice'](0x0,-0x1):_0x8174d9['previousPosition']['path'],_0x4acc31=_0x983b5d['getNodeByPath'](_0x52cdf9)['getAttribute'](_0xa7a620);this['_touched']['set'](_0x4acc31,{'userId':_0x53a16a});}}}this['_startingRevisionId']=this['_revisionId'];const _0x21f180=[...Array(this['_revisionId'])['keys']()]['slice'](0x1)['filter'](_0x4c1a6c=>!this['_touched']['has'](_0x4c1a6c));let _0x1038fe=0x0;const _0xddfab6=new Map();for(const _0x111429 in _0x2d10a4['diffData']){const _0x26b3f6=_0x2d10a4['diffData'][_0x111429]['attachChange'],_0x2bc310=_0x4dbdf7(_0x2d10a4['diffData'][_0x111429]['attributesAfter'])||{},_0x1bb1ad=_0x44ecc3['_makeModelFromViewString'](_0x2d10a4['diffData'][_0x111429]['insertions']);_0x1bb1ad['rootName']=_0x111429,_0x1bb1ad['_isAttached']=!_0x26b3f6||_0x26b3f6['isAttached'],_0x1bb1ad['isAttached']=()=>_0x1bb1ad['_isAttached'],this['_diffRoots']['set'](_0x111429,_0x1bb1ad),this['_diffRootsAttributes']['set'](_0x111429,_0x2bc310);const _0x5117bb=this['_makeIdsRoot'](_0x1bb1ad,Number['NEGATIVE_INFINITY']);this['_idsRoots']['set'](_0x111429,_0x5117bb),_0xddfab6['set'](_0x111429,_0x1bb1ad['isAttached']()?_0x2bc310:{});for(const [_0x2a3488,_0x5e8dbd]of _0x1bb1ad['markers']){if(!_0x2a3488['startsWith']('revision:'))continue;const _0x4c418d=_0x2a3488['split'](':')[0x2];for(const _0x2dd61c of _0x5e8dbd['getWalker']({'singleCharacters':!0x0})){const _0x52038b=this['_getVidAttributeName'](_0x2dd61c),_0xe34fae=this['_revisionId']++,_0x472bfc='elementEnd'==_0x2dd61c['type']?_0x2dd61c['previousPosition']['path']['slice'](0x0,-0x1):_0x2dd61c['previousPosition']['path'];_0x5117bb['getNodeByPath'](_0x472bfc)['_setAttribute'](_0x52038b,_0xe34fae),this['_touched']['set'](_0xe34fae,{'userId':_0x4c418d});}}for(const _0x5624e9 of this['editor']['model']['createRangeIn'](_0x1bb1ad)['getWalker']({'singleCharacters':!0x0})){const _0x8589ec=this['_getVidAttributeName'](_0x5624e9),_0x5c1211='elementEnd'==_0x5624e9['type']?_0x5624e9['previousPosition']['path']['slice'](0x0,-0x1):_0x5624e9['previousPosition']['path'],_0x8d12b2=_0x5117bb['getNodeByPath'](_0x5c1211);_0x8d12b2['getAttribute'](_0x8589ec)>0x0||_0x8d12b2['_setAttribute'](_0x8589ec,_0x21f180[_0x1038fe++]);}for(const [_0x2e89ec,_0x5e1920]of _0x1bb1ad['markers'])_0x2e89ec['startsWith']('revision:')||this['_markers']['set'](_0x2e89ec,_0x5e1920);}const _0x27984b=P('$graveyard');this['_baseRoots']['set']('$graveyard',_0x27984b),this['_baseIdsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x27984b,0x1));const _0x9a01a3=P('$graveyard');this['_diffRoots']['set']('$graveyard',_0x9a01a3),this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x9a01a3,0x1));const _0x390f43=Array['from'](this['_diffRoots'])['map'](([_0x4efa44,_0x180a3f])=>[_0x4efa44,N(_0x180a3f)]);this['_saveMetaData'](this['_lastTo'],_0x390f43,this['_markers'],_0xddfab6);}['reInit'](){this['_reset'](),this['_lastFrom']=-0x1,this['_lastTo']=-0x1,this['_savedMetaData']['clear'](),this['init'](this['source']);}['_saveMetaData'](_0x2c4b7a,_0x2c7757,_0x4b44f3,_0x2bbf1e){const _0x5a8113=new Map(_0x2c7757),_0x5a6c4a=new Map(_0x4dbdf7(_0x2bbf1e)),_0x450dd5=new Map();for(const [_0x2da8b0,_0xa0fad1]of _0x4b44f3)_0x450dd5['set'](_0x2da8b0,{'start':_0xa0fad1['start']['clone'](),'end':_0xa0fad1['end']['clone'](),'rootName':_0xa0fad1['root']['rootName']});this['_savedMetaData']['set'](_0x2c4b7a,{'roots':_0x5a8113,'markers':_0x450dd5,'rootsAttributes':_0x5a6c4a});}['_removeMetaData'](_0x5a4b8e){this['_savedMetaData']['delete'](_0x5a4b8e);}['_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'](_0x69388d,_0x14bf0b=null){let _0x2390cc=null;_0x69388d['is']('documentFragment')||(_0x2390cc=new ut(_0x69388d['name'],{'vid_start':null===_0x14bf0b?this['_revisionId']++:_0x14bf0b++}));const _0x26d4ee=[];for(const _0x442fa9 of _0x69388d['getChildren']())if(_0x442fa9['is']('element')){_0x26d4ee['push'](this['_makeIdsRoot'](_0x442fa9,_0x14bf0b));const _0x25d590=_0x26d4ee[_0x26d4ee['length']-0x1];null!==_0x14bf0b&&(_0x14bf0b=_0x25d590['is']('element','$text')?_0x25d590['getAttribute']('vid')+0x1:_0x25d590['getAttribute']('vid_end')+0x1);}else{for(let _0x1a71f8=0x0;_0x1a71f8<_0x442fa9['offsetSize'];_0x1a71f8++)_0x26d4ee['push'](new ut('$text',{'vid':null===_0x14bf0b?this['_revisionId']++:_0x14bf0b++}));}if(_0x69388d['is']('documentFragment')){const _0x50571c=P(_0x69388d['rootName']);return _0x50571c['_insertChild'](0x0,_0x26d4ee),_0x50571c;}return _0x2390cc['_setAttribute']('vid_end',null===_0x14bf0b?this['_revisionId']++:_0x14bf0b++),_0x2390cc['_insertChild'](0x0,_0x26d4ee),_0x2390cc;}['_calculateMetaData'](_0x1e1d6d,_0x102dec,_0x1c8daf){this['_reset']();const {roots:_0x439cf8,markers:_0x42d876,rootsAttributes:_0x374978}=this['_savedMetaData']['get'](_0x1e1d6d);this['_baseRoots']=new Map(_0x439cf8),this['_baseRootsAttributes']=new Map(_0x4dbdf7(_0x374978));for(const [_0x2a89fa,_0x193981]of this['_baseRoots'])if('$graveyard'!==_0x2a89fa&&(this['_diffRoots']['set'](_0x2a89fa,N(_0x193981)),this['_diffRootsAttributes']=new Map(_0x4dbdf7(_0x374978)),_0x1c8daf)){const _0x4a59f4=this['_revisionId'];this['_idsRoots']['set'](_0x2a89fa,this['_makeIdsRoot'](_0x193981)),this['_baseIdsRoots']['set'](_0x2a89fa,this['_makeIdsRoot'](_0x193981,_0x4a59f4));}this['_startingRevisionId']=this['_revisionId'],this['_diffRoots']['set']('$graveyard',N(this['_baseRoots']['get']('$graveyard'))),_0x1c8daf&&this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](this['_baseRoots']['get']('$graveyard')));for(const [_0x4523f8,_0x3c7d6f]of _0x42d876){const _0x533080=this['_baseRoots']['get'](_0x3c7d6f['rootName']),_0x4a7f2f=this['_diffRoots']['get'](_0x3c7d6f['rootName']),_0x2d14c5=new lt(this['_fixPosition'](_0x3c7d6f['start'],_0x533080),this['_fixPosition'](_0x3c7d6f['end'],_0x533080)),_0x33122d=this['_fixRange'](_0x2d14c5,_0x4a7f2f);_0x533080['markers']['set'](_0x4523f8,_0x2d14c5),this['_markers']['set'](_0x4523f8,_0x33122d);}this['_applyOperations'](_0x1e1d6d,_0x102dec,_0x1c8daf);}['_applyOperations'](_0xe4dd24,_0x2d2927,_0x370f58){for(const _0x15d6bb of this['source']['getOperations'](_0xe4dd24,_0x2d2927))this['_handleOperation'](_0x15d6bb,_0x370f58);for(const _0x1c2a1c of this['_diffRoots']['values']())_0x1c2a1c['markers']['clear']();for(const [_0x583075,_0x179398]of this['_markers']){this['_diffRoots']['get'](_0x179398['root']['rootName'])['markers']['set'](_0x583075,_0x179398['clone']());}const _0x3ab8f9=new Map(),_0xa18032=new Map();for(const [_0x4e7f73,_0x3e585e]of this['_diffRoots'])_0x3ab8f9['set'](_0x4e7f73,N(_0x3e585e)),_0xa18032['set'](_0x4e7f73,this['_diffRootsAttributes']['get'](_0x4e7f73));this['_saveMetaData'](_0x2d2927,_0x3ab8f9,this['_markers'],_0xa18032);}['_getPreviousFrom'](_0x223d61){const _0x14469e=Array['from'](this['_savedMetaData']['keys']());_0x14469e['sort']((_0x1924ab,_0x3a2e3e)=>_0x1924ab-_0x3a2e3e),_0x14469e['reverse']();for(const _0x3de411 of _0x14469e)if(_0x3de411<_0x223d61)return _0x3de411;return Number['NEGATIVE_INFINITY'];}['_copyMarkers'](_0x3c8405,_0x1a5be2){const _0x3d17a8=Array['from'](_0x1a5be2['markers'])['map'](([_0x5bb5c1,_0x4cefc5])=>[_0x5bb5c1,this['_fixRange'](_0x4cefc5,_0x3c8405)]);_0x3c8405['markers']=new Map(_0x3d17a8);}['_transformMarkers'](_0x242078){for(const _0x1eff58 of this['_markers']['values']()){const _0x16b752=_0x1eff58['getTransformedByOperation'](_0x242078),_0x46b588=lt['_createFromRanges'](_0x16b752);_0x1eff58['start']=_0x46b588['start'],_0x1eff58['end']=_0x46b588['end'];}}['_handleOperation'](_0x2e4d59,_0xf396fc){if('addRoot'!=_0x2e4d59['type']&&'detachRoot'!=_0x2e4d59['type']){if('insert'==_0x2e4d59['type']){const _0x1e9ff8=_0x2e4d59['position']['root']['rootName'];this['_diffRoots']['has'](_0x1e9ff8)||(this['_diffRoots']['set'](_0x1e9ff8,P(_0x1e9ff8,!0x0)),this['_diffRootsAttributes']['set'](_0x1e9ff8,{}),_0xf396fc&&this['_idsRoots']['set'](_0x1e9ff8,P(_0x1e9ff8,!0x0)));}else{if('addRootAttribute'==_0x2e4d59['type']||'removeRootAttribute'==_0x2e4d59['type']||'changeRootAttribute'==_0x2e4d59['type'])return void this['_handleRootAttributeOperation'](_0x2e4d59);'marker'==_0x2e4d59['type']&&this['_handleMarkerOperation'](_0x2e4d59);}if('marker'!==_0x2e4d59['type']){const _0x2ca857=this['_cloneOperation'](_0x2e4d59,this['_diffRoots']);_0x2ca857['_execute'](),this['_transformMarkers'](_0x2ca857);}if(_0xf396fc)switch(_0x2e4d59['type']){case'insert':this['_handleInsertOperation'](_0x2e4d59);break;case'move':case'remove':case'reinsert':this['_handleMoveOperation'](_0x2e4d59);break;case'merge':this['_handleMergeOperation'](_0x2e4d59);break;case'split':this['_handleSplitOperation'](_0x2e4d59);}}else this['_handleRootOperation'](_0x2e4d59,_0xf396fc);}['_cloneOperation'](_0x2c2758,_0x30105c){const _0x4d40a0=_0x2c2758['clone']();return _0x4d40a0['_authorId']=_0x2c2758['_authorId'],this['_fixOperation'](_0x4d40a0,_0x30105c),_0x4d40a0;}['_getBaseVids'](_0x3c1275){return _0x3c1275['map'](_0x58f6d2=>{const _0x5be85f=this['_getVidAttributeName'](_0x58f6d2);return Number(_0x58f6d2['item']['getAttribute'](_0x5be85f));});}['_generateTape'](_0x1b1d88,_0x51a594){if(_0x1b1d88['is']('element','$text'))_0x51a594['push']({'item':_0x1b1d88,'type':'text'});else{_0x1b1d88['is']('element')&&_0x51a594['push']({'item':_0x1b1d88,'type':'elementStart'});for(const _0x4163d9 of _0x1b1d88['getChildren']())this['_generateTape'](_0x4163d9,_0x51a594);_0x1b1d88['is']('element')&&_0x51a594['push']({'item':_0x1b1d88,'type':'elementEnd'});}return _0x51a594;}['_getState'](){const _0xddfe9=new Map(this['_touched']),_0x4afb99=new Map(_0xddfe9),_0x23d4d3=new Map(),_0x5dedc6={'insertions':{},'deletions':{}},_0xa70b4d={'insertions':{},'deletions':{}},_0x3ff9ca=new Map(),_0x215f41=new Set([...this['_baseRoots']['keys'](),...this['_diffRoots']['keys']()]);_0x215f41['delete']('$graveyard');for(const _0x4b188b of _0x215f41){const _0x44b4cd=this['_diffRoots']['get'](_0x4b188b)||P(_0x4b188b,!0x1),_0x114c6f=this['_baseRoots']['get'](_0x4b188b)||P(_0x4b188b,!0x1);_0x44b4cd['isAttached']()||_0x114c6f['isAttached']()?(_0x5dedc6['insertions'][_0x4b188b]=N(_0x44b4cd),_0x5dedc6['deletions'][_0x4b188b]=N(_0x114c6f),this['_copyMarkers'](_0x5dedc6['deletions'][_0x4b188b],_0x114c6f),this['_copyMarkers'](_0x5dedc6['insertions'][_0x4b188b],_0x44b4cd),_0xa70b4d['insertions'][_0x4b188b]=this['_generateTape'](this['_idsRoots']['get'](_0x4b188b),[]),_0xa70b4d['deletions'][_0x4b188b]=this['_generateTape'](this['_baseIdsRoots']['get'](_0x4b188b)||P(_0x4b188b,!0x1),[])):_0x215f41['delete'](_0x4b188b);}for(const _0x5beb83 of _0x215f41){const _0x39972d=_0xa70b4d['insertions'][_0x5beb83];for(const _0x5e83eb of _0x39972d){const _0x37e245=this['_getVidAttributeName'](_0x5e83eb),_0x173415=_0x5e83eb['item']['getAttribute'](_0x37e245);_0x4afb99['delete'](_0x173415),_0x173415>=this['_startingRevisionId']&&_0x23d4d3['set'](_0x173415,_0xddfe9['get'](_0x173415));}}for(const _0x21c92b of _0x215f41){const _0x5d5889=_0xa70b4d['insertions'][_0x21c92b],_0x24d100=this['_getBaseVids'](_0xa70b4d['deletions'][_0x21c92b]);let _0x5c2a37=0x0;for(const _0xde9da3 of _0x5d5889){const _0x5f4517=this['_getVidAttributeName'](_0xde9da3),_0x1cc644=_0xde9da3['item']['getAttribute'](_0x5f4517);if(!_0x23d4d3['has'](_0x1cc644)&&!_0x3ff9ca['has'](_0x1cc644)){if(_0x4afb99['has'](_0x1cc644))_0x5c2a37++;else{if(_0x1cc644!=_0x24d100[_0x5c2a37]){const _0x3bff7e=_0xddfe9['get'](_0x1cc644)||_0xddfe9['get'](_0x24d100[_0x5c2a37]);for(;_0x1cc644!=_0x24d100[_0x5c2a37];)_0x4afb99['has'](_0x24d100[_0x5c2a37])||(_0x3ff9ca['set'](_0x24d100[_0x5c2a37],_0x3bff7e),_0xddfe9['set'](_0x24d100[_0x5c2a37],_0x3bff7e)),_0x5c2a37++;}_0x5c2a37++;}}}}for(const _0x5100e9 of _0x215f41){const _0x185b67=_0xa70b4d['insertions'][_0x5100e9];for(const _0x496efc of _0x185b67){const _0x4111cc=this['_getVidAttributeName'](_0x496efc),_0x17e009=_0x496efc['item']['getAttribute'](_0x4111cc);if(_0x3ff9ca['has'](_0x17e009)){const _0x33afed=_0x3ff9ca['get'](_0x17e009);_0x4afb99['has'](_0x17e009)||_0x4afb99['set'](_0x17e009,{..._0x33afed}),_0x23d4d3['set'](_0x17e009,{..._0x33afed});}}}for(const _0x9e12a7 of _0x4afb99['keys']())_0x9e12a7>=this['_startingRevisionId']&&_0x4afb99['delete'](_0x9e12a7);const _0xd5d1b9=new Map();for(const _0x458fb4 of _0x215f41){let _0x2c977d=_0xa70b4d['insertions'][_0x458fb4];for(const _0x10a18d of _0x2c977d)if(_0x10a18d['item']['is']('element','tableCell')){const _0x54acbe=this['_getVidAttributeName'](_0x10a18d),_0x1a7642=_0x10a18d['item']['getAttribute'](_0x54acbe);if(_0x23d4d3['has'](_0x1a7642)){const _0x107e44=_0x10a18d['item']['parent']['parent']['getAttribute']('vid_start'),_0x10b21b=_0xd5d1b9['get'](_0x107e44)||new Set();_0x10b21b['add'](_0x23d4d3['get'](_0x1a7642)['userId']),_0xd5d1b9['set'](_0x107e44,_0x10b21b);}}_0x2c977d=_0xa70b4d['deletions'][_0x458fb4];for(const _0x2213d3 of _0x2c977d)if(_0x2213d3['item']['is']('element','tableCell')){const _0xf3ad91=this['_getVidAttributeName'](_0x2213d3),_0x4a8861=_0x2213d3['item']['getAttribute'](_0xf3ad91);if(_0x4afb99['has'](_0x4a8861)){const _0x56aaab=_0x2213d3['item']['parent']['parent']['getAttribute']('vid_start'),_0x1e2f48=_0xd5d1b9['get'](_0x56aaab)||new Set();_0x1e2f48['add'](_0x4afb99['get'](_0x4a8861)['userId']),_0xd5d1b9['set'](_0x56aaab,_0x1e2f48);}}for(const _0x1c2e1f of _0xd5d1b9['keys']())(_0x23d4d3['has'](_0x1c2e1f)||_0x4afb99['has'](_0x1c2e1f))&&_0xd5d1b9['delete'](_0x1c2e1f);}for(const _0xdadc1e of _0x215f41){const _0x3fe539=_0xa70b4d['insertions'][_0xdadc1e];let _0x5a5901=null,_0x20b3b2=null;for(const _0xe9440e of _0x3fe539){const _0x86d234=this['_getVidAttributeName'](_0xe9440e),_0x29ae11=_0xe9440e['item']['getAttribute'](_0x86d234),_0x40dda2=_0xd5d1b9['get'](_0x29ae11);_0x40dda2&&'elementStart'==_0xe9440e['type']&&(_0x5a5901=Array['from'](_0x40dda2)[0x0],_0x20b3b2=_0xe9440e['item']['getAttribute']('vid_end')),_0x5a5901&&(_0x4afb99['set'](_0x29ae11,{'userId':_0x5a5901}),_0x23d4d3['set'](_0x29ae11,{'userId':_0x5a5901})),_0x29ae11==_0x20b3b2&&(_0x5a5901=null,_0x20b3b2=null);}}const _0x182f60={},_0x4bab10=new Set();for(const _0x551f2a of _0x215f41){const _0x51fe5a=_0x5dedc6['deletions'][_0x551f2a],_0x3eb17e=_0x5dedc6['insertions'][_0x551f2a];for(const {userId:_0x43e839}of this['_touchedMarkers']['values']())null!==_0x43e839&&_0x4bab10['add'](_0x43e839);for(const {userId:_0x557537}of this['_touchedRoots']['values']())null!==_0x557537&&_0x4bab10['add'](_0x557537);this['_markChanges'](_0x3eb17e,_0xa70b4d['insertions'][_0x551f2a],_0x23d4d3,'insertion',_0x4bab10),this['_markChanges'](_0x51fe5a,_0xa70b4d['deletions'][_0x551f2a],_0x4afb99,'deletion',_0x4bab10),_0x182f60[_0x551f2a]={'insertions':this['_prepareViewToSave'](_0x3eb17e),'deletions':this['_prepareViewToSave'](_0x51fe5a),'attachChange':this['_touchedRoots']['get'](_0x551f2a)||null,'attributesBefore':_0x4dbdf7(this['_baseRootsAttributes']['get'](_0x551f2a))||{},'attributesAfter':_0x4dbdf7(this['_diffRootsAttributes']['get'](_0x551f2a))};}return{'diffData':_0x182f60,'authorsIds':Array['from'](_0x4bab10)};}['_processRootBeforeSave'](_0x17eafc){for(const [,_0x29eb1e]of _0x17eafc['markers']){const _0x4029ed=_0x29eb1e['start']['getAncestors']()['filter'](_0x5b68cf=>'tableCell'==_0x5b68cf['name']);for(const _0x3d5302 of _0x4029ed)0x1==_0x3d5302['childCount']&&_0x3d5302['getChild'](0x0)['is']('element','paragraph')&&_0x3d5302['getChild'](0x0)['_setAttribute']('keepParagraph',!0x0);}}['_prepareViewToSave'](_0x15dfe3){this['_processRootBeforeSave'](_0x15dfe3);const _0x26136e=this['editor']['data']['toView'](_0x15dfe3,{}),_0x201954=Array['from'](_0x26136e['getChildren']())['map'](_0x3d7b77=>this['_getViewJson'](_0x3d7b77));return JSON['stringify'](_0x201954);}['_getViewJson'](_0x8c7317){if(_0x8c7317['is']('$text'))return _0x8c7317['data'];{const _0x50c592=this['editor']['plugins']['get']('RevisionHistoryUtils'),_0xcac413=_0x8c7317,_0x120db5=this['editor']['data']['htmlProcessor']['domConverter'],_0x3788b3={'type':_0x50c592['_getTypeCharForViewElement'](_0xcac413),'name':_0xcac413['name'],'attributes':Array['from'](_0xcac413['getAttributes']()),'children':Array['from'](_0xcac413['getChildren']())['map'](_0x4500d6=>this['_getViewJson'](_0x4500d6))};if(_0x8c7317['is']('uiElement')&&'$comment'!=_0x8c7317['name']){const _0x1ca64c=_0x8c7317['render'](_0x120db5['domDocument'],_0x120db5);_0x3788b3['children']['push'](_0x1ca64c['outerHTML']);}else{if(_0x8c7317['is']('rawElement')){const _0x355bb2=_0x120db5['domDocument']['createElement'](_0xcac413['name']);_0x8c7317['render'](_0x355bb2,_0x120db5),_0x3788b3['children']['push'](_0x355bb2['innerHTML']);}}const _0x3c6a76=Array['from'](_0xcac413['getCustomProperties']());_0x3c6a76['length']>0x0&&(_0x3788b3['customProperties']=_0x3c6a76);const _0x1cd290=_0xcac413['getFillerOffset']();return null!==_0x1cd290&&(_0x3788b3['fillerOffset']=_0x1cd290),_0x3788b3;}}['_markChanges'](_0xc4e8f0,_0x559001,_0x34a88c,_0x4a4ff9,_0x2dd39d){let _0x1870e2=null,_0x128f28=null,_0x311156=0x0;const _0xe81e7c=this['editor']['model'];for(let _0x5c02b3=0x0;_0x5c02b3<_0x559001['length'];_0x5c02b3++){const _0x1e929c=this['_getVidAttributeName'](_0x559001[_0x5c02b3]),_0x13edc7=_0x559001[_0x5c02b3]['item']['getAttribute'](_0x1e929c),_0x5157dd=_0x34a88c['get'](_0x13edc7),_0x4c429a=_0x5c02b3==_0x559001['length']-0x1;(!_0x1870e2&&_0x5157dd&&(_0x1870e2=_0x5157dd,_0x128f28=_0x559001[_0x5c02b3]),_0x1870e2&&(!_0x5157dd||_0x5157dd['userId']!=_0x1870e2['userId']))&&(_0x3f48ec(_0x5157dd,F(_0x128f28,_0xc4e8f0,_0xe81e7c),F(_0x559001[_0x5c02b3],_0xc4e8f0,_0xe81e7c)),_0x1870e2=_0x5157dd||null,_0x128f28=_0x5157dd?_0x559001[_0x5c02b3]:null),_0x1870e2&&_0x4c429a&&_0x3f48ec(_0x5157dd,F(_0x128f28,_0xc4e8f0,_0xe81e7c),B(_0x559001[_0x5c02b3],_0xc4e8f0,_0xe81e7c));}function _0x3f48ec(_0x20b5f6,_0x2ab743,_0x4ff7f3){const _0x38a745=_0x1870e2['userId'],_0x474711='revision:'+_0x4a4ff9+':'+_0x38a745+':'+_0x311156++,_0x34f149=_0xe81e7c['createRange'](_0x2ab743,_0x4ff7f3);_0xc4e8f0['markers']['set'](_0x474711,_0x34f149),null!==_0x38a745&&_0x2dd39d['add'](_0x38a745);}}['_getVidAttributeName'](_0x517dff){switch(_0x517dff['type']){case'elementStart':return'vid_start';case'elementEnd':return'vid_end';default:return'vid';}}['_fixOperation'](_0x5b7a0d,_0x14025c){_0x5b7a0d['baseVersion']=null;for(const _0x4e8f7e in _0x5b7a0d){const _0x5dfd50=_0x5b7a0d[_0x4e8f7e];if(_0x5dfd50 instanceof ft){const _0x5b7fa3=_0x14025c['get'](_0x5dfd50['root']['rootName']);_0x5b7a0d[_0x4e8f7e]=this['_fixPosition'](_0x5dfd50,_0x5b7fa3);}if(_0x5dfd50 instanceof lt){const _0xc8b292=_0x14025c['get'](_0x5dfd50['root']['rootName']);_0x5b7a0d[_0x4e8f7e]=this['_fixRange'](_0x5dfd50,_0xc8b292);}'root'===_0x4e8f7e&&(_0x5b7a0d['root']=_0x14025c['get'](_0x5b7a0d['root']['rootName']));}}['_fixRange'](_0x231f71,_0x3e3490){return this['editor']['model']['createRange'](this['_fixPosition'](_0x231f71['start'],_0x3e3490),this['_fixPosition'](_0x231f71['end'],_0x3e3490));}['_fixPosition'](_0xfe1bbf,_0x596575){return this['editor']['model']['createPositionFromPath'](_0x596575,_0xfe1bbf['path'],_0xfe1bbf['stickiness']);}['_handleInsertOperation'](_0x1539a6){const _0x3005e4=this['_idsRoots']['get'](_0x1539a6['position']['root']['rootName']),_0x5219c3=this['_fixPosition'](_0x1539a6['position'],_0x3005e4),_0x156c92=null===_0x1539a6['_authorId']?null:_0x1539a6['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x278425=_0x5219c3['parent'],_0x1b6410=this['_revisionId'],_0x1e16fe=[];for(const _0x5561f8 of _0x1539a6['nodes'])if(_0x5561f8['is']('element'))_0x1e16fe['push'](this['_makeIdsRoot'](_0x5561f8));else{for(let _0x4fa79d=0x0;_0x4fa79d<_0x5561f8['offsetSize'];_0x4fa79d++)_0x1e16fe['push'](new ut('$text',{'vid':this['_revisionId']++}));}const _0x1b55a7=this['_revisionId'];for(let _0x3be454=_0x1b6410;_0x3be454<_0x1b55a7;_0x3be454++)this['_touched']['set'](_0x3be454,{'userId':_0x156c92});_0x278425['_insertChild'](_0x5219c3['offset'],_0x1e16fe);}['_handleMoveOperation'](_0x976d5){(_0x976d5=this['_cloneOperation'](_0x976d5,this['_idsRoots']))['_execute']();const _0x3e1049=null===_0x976d5['_authorId']?null:_0x976d5['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x26940e=_0x976d5['getMovedRangeStart'](),_0x4e726a=_0x26940e['parent'],_0x100af6=_0x26940e['offset'];!function _0x5978a2(_0x199335,_0x5573bd,_0xd72624,_0x1e210f){for(let _0x252ee5=_0xd72624;_0x252ee5<_0x1e210f;_0x252ee5++){const _0x3f240e=_0x5573bd['getChild'](_0x252ee5);_0x3f240e['is']('element','$text')?_0x199335['set'](_0x3f240e['getAttribute']('vid'),{'userId':_0x3e1049}):(_0x199335['set'](_0x3f240e['getAttribute']('vid_start'),{'userId':_0x3e1049}),_0x5978a2(_0x199335,_0x3f240e,0x0,_0x3f240e['childCount']),_0x199335['set'](_0x3f240e['getAttribute']('vid_end'),{'userId':_0x3e1049}));}}(this['_touched'],_0x4e726a,_0x100af6,_0x100af6+_0x976d5['howMany']);}['_handleMergeOperation'](_0x1f7638){const _0x84cae=null===(_0x1f7638=this['_cloneOperation'](_0x1f7638,this['_idsRoots']))['_authorId']?null:_0x1f7638['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x5868e8=_0x1f7638['targetPosition']['parent'],_0x105bb2=_0x1f7638['sourcePosition']['parent'],_0x57723d=_0x5868e8['getAttribute']('vid_end'),_0x3e5a4d=_0x105bb2['getAttribute']('vid_start');_0x5868e8['_setAttribute']('vid_end',_0x105bb2['getAttribute']('vid_end')),_0x105bb2['_setAttribute']('vid_end',_0x57723d),this['_touched']['set'](_0x3e5a4d,{'userId':_0x84cae}),this['_touched']['set'](_0x57723d,{'userId':_0x84cae}),_0x1f7638['_execute']();}['_handleSplitOperation'](_0xb10788){const _0x55b329=null===(_0xb10788=this['_cloneOperation'](_0xb10788,this['_idsRoots']))['_authorId']?null:_0xb10788['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x3e15c4=_0xb10788['graveyardPosition'],_0x14b54b=_0xb10788['splitPosition']['parent'];_0xb10788['_execute']();const _0x184f1e=_0x14b54b['getAttribute']('vid_end'),_0x3173db=_0xb10788['insertionPosition']['nodeAfter'];if(_0x3e15c4){const _0x46f064=_0x3173db['getAttribute']('vid_end'),_0x18a8f7=_0x14b54b['getAttribute']('vid_end');_0x14b54b['_setAttribute']('vid_end',_0x46f064),_0x3173db['_setAttribute']('vid_end',_0x18a8f7),this['_touched']['set'](_0x14b54b['getAttribute']('vid_end'),{'userId':_0x55b329}),this['_touched']['set'](_0x3173db['getAttribute']('vid_start'),{'userId':_0x55b329});}else{const _0x45806d=this['_revisionId']++,_0x1c2b73=this['_revisionId']++;_0x14b54b['_setAttribute']('vid_end',_0x45806d),_0x3173db['_setAttribute']('vid_start',_0x1c2b73),_0x3173db['_setAttribute']('vid_end',_0x184f1e),this['_touched']['set'](_0x45806d,{'userId':_0x55b329}),this['_touched']['set'](_0x1c2b73,{'userId':_0x55b329});}}['_handleMarkerOperation'](_0x5f3e7c){if(!_0x5f3e7c['affectsData'])return;const _0x27f898=(_0x5f3e7c=this['_cloneOperation'](_0x5f3e7c,this['_diffRoots']))['oldRange']?_0x5f3e7c['oldRange']['root']:null,_0x571032=_0x5f3e7c['newRange']?_0x5f3e7c['newRange']['root']:null;_0x27f898&&this['_markers']['delete'](_0x5f3e7c['name']),_0x571032&&this['_markers']['set'](_0x5f3e7c['name'],_0x5f3e7c['newRange']['clone']());const _0x580246=null===_0x5f3e7c['_authorId']?null:_0x5f3e7c['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x3d14fb=_0x5f3e7c['name'];if(!this['_touchedMarkers']['has'](_0x3d14fb))return void this['_touchedMarkers']['set'](_0x3d14fb,{'range':_0x5f3e7c['oldRange'],'userId':_0x580246});const _0x1a71d3=this['_touchedMarkers']['get'](_0x3d14fb),_0x330886=_0x1a71d3['range'],_0x41174a=_0x5f3e7c['newRange'];null==_0x330886&&null==_0x41174a||_0x330886&&_0x41174a&&_0x330886['isEqual'](_0x41174a)?this['_touchedMarkers']['delete'](_0x5f3e7c['name']):_0x1a71d3['userId']=_0x580246;}['_handleRootOperation'](_0x3ce6e7,_0x22dc84){this['_diffRoots']['has'](_0x3ce6e7['rootName'])?this['_diffRoots']['get'](_0x3ce6e7['rootName'])['_isAttached']=_0x3ce6e7['isAdd']:(this['_diffRoots']['set'](_0x3ce6e7['rootName'],P(_0x3ce6e7['rootName'],!0x0)),this['_diffRootsAttributes']['set'](_0x3ce6e7['rootName'],{}),_0x22dc84&&this['_idsRoots']['set'](_0x3ce6e7['rootName'],P(_0x3ce6e7['rootName'],!0x0)));const _0x308527=null===_0x3ce6e7['_authorId']?null:_0x3ce6e7['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x33e8cd=this['_touchedRoots']['get'](_0x3ce6e7['rootName']);_0x33e8cd&&_0x33e8cd['userId']===_0x308527?this['_touchedRoots']['delete'](_0x3ce6e7['rootName']):this['_touchedRoots']['set'](_0x3ce6e7['rootName'],{'userId':_0x308527,'isAttached':_0x3ce6e7['isAdd']});}['_handleRootAttributeOperation'](_0x2d3a28){const _0x448f4a=this['_diffRootsAttributes']['get'](_0x2d3a28['root']['rootName']);null===_0x2d3a28['newValue']?delete _0x448f4a[_0x2d3a28['key']]:_0x448f4a[_0x2d3a28['key']]=_0x2d3a28['newValue'];}}function N(_0x1a8492){const _0x2bc094=P(_0x1a8492['rootName'],_0x1a8492['isAttached']());for(const _0x180443 of _0x1a8492['getChildren']()){const _0x3012a6=_0x180443['_clone'](!0x0);_0x2bc094['_appendChild'](_0x3012a6);}return _0x2bc094;}function P(_0x541280,_0x437151=!0x0){const _0x18e972=new vt();return _0x18e972['rootName']=_0x541280,_0x18e972['_isAttached']=_0x437151,_0x18e972['isAttached']=()=>_0x18e972['_isAttached'],_0x18e972;}function F(_0x51d27e,_0x5182ef,_0x3fb1a3){const _0x3595c4='elementEnd'==_0x51d27e['type']?_0x3fb1a3['createPositionAt'](_0x51d27e['item'],'end'):_0x3fb1a3['createPositionBefore'](_0x51d27e['item']);return _0x3fb1a3['createPositionFromPath'](_0x5182ef,_0x3595c4['path'],_0x3595c4['stickiness']);}function B(_0x5a22dd,_0xceae7d,_0x1b9d28){const _0x4db432='elementStart'==_0x5a22dd['type']?_0x1b9d28['createPositionAt'](_0x5a22dd['item'],0x0):_0x1b9d28['createPositionAfter'](_0x5a22dd['item']);return _0x1b9d28['createPositionFromPath'](_0xceae7d,_0x4db432['path'],_0x4db432['stickiness']);}class hs extends ts{['focusTracker'];['keystrokes'];['revisionNameInputView'];constructor(_0x17fd52,_0x47829f){super(_0x17fd52),this['focusTracker']=new _0x12b377(),this['keystrokes']=new _0x10ecca(),this['set']('revisionNameInputValue',''),this['revisionNameInputView']=this['_createRevisionNameInput'](_0x47829f),this['setTemplate']({'tag':'form','attributes':{'class':['ck','ck-revision-history-save-revision-form','ck-responsive-form'],'tabindex':'-1'},'children':[this['revisionNameInputView']]}),_0x47db8c(this);}['render'](){super['render'](),_0x3b4acf({'view':this}),this['focusTracker']['add'](this['revisionNameInputView']['element']),this['keystrokes']['listenTo'](this['element']);const _0xacd8e=_0x631862=>_0x631862['stopPropagation']();this['keystrokes']['set']('arrowright',_0xacd8e),this['keystrokes']['set']('arrowleft',_0xacd8e),this['keystrokes']['set']('arrowup',_0xacd8e),this['keystrokes']['set']('arrowdown',_0xacd8e);}['focus'](){this['revisionNameInputView']['focus']();}get['revisionName'](){return this['revisionNameInputView']['fieldView']['element']['value']['trim']();}set['revisionName'](_0x43eeb3){this['revisionNameInputView']['fieldView']['element']['value']=_0x43eeb3['trim']();}['reset'](){this['revisionNameInputView']['fieldView']['element']['value']='',this['revisionNameInputView']['errorText']=null;}['_createRevisionNameInput'](_0x14a17c){const _0x48941e=new _0x21d0c2(this['locale'],_0x1a6c7a),_0x51bd60=_0x48941e['fieldView'];_0x51bd60['extendTemplate']({'attributes':{'maxlength':'220'}});let _0x32b13f=g(this['locale'],'Name\x20of\x20the\x20revision');return!_0x14a17c&&(_0x32b13f+='\x20('+g(this['locale'],'optional')+')'),(_0x48941e['label']=_0x32b13f,_0x51bd60['on']('input',()=>{this['revisionNameInputValue']=_0x51bd60['element']['value']['trim']();}),_0x48941e);}}class f extends _0x1aaf30{static get['pluginName'](){return'RevisionHistoryUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[u];}['_saveRevisionFormView'];['init'](){const _0x39936e=this['editor'],_0x4846e8=_0x39936e['plugins']['get']('RevisionTracker');_0x39936e['ui']['componentFactory']['add']('revisionHistory',_0xdb2876=>{const _0x3d7b0f=_0x3baa9b(_0xdb2876),_0x4381cd=_0x3d7b0f['panelView']['children'],_0x703d16=new _0xaeeef7(_0xdb2876),_0x4cfaa5=new _0x250e3b(_0xdb2876),_0x168c6d=new te(_0xdb2876),_0x4d90a4=new _0x250e3b(_0xdb2876),_0x508894=new te(_0xdb2876);return _0x3d7b0f['bind']('isEnabled')['to'](_0x4846e8,'isReady',_0x4846e8,'isEnabled',_0x39936e,'isReadOnly',(_0x56e041,_0x5e9d37,_0x41de19)=>_0x56e041&&_0x5e9d37&&!_0x41de19),_0x3d7b0f['buttonView']['set']({'icon':_0x2aae82,'label':g(_0xdb2876,'Revision\x20history'),'tooltip':!0x0}),_0x168c6d['set']({'label':g(_0xdb2876,'Save\x20current\x20revision'),'withText':!0x0,'role':'menuitem'}),_0x168c6d['bind']('isEnabled')['to'](_0x4846e8,'isReady',_0x4846e8,'isEnabled',_0x39936e,'isReadOnly',(_0x3ccf8f,_0x136925,_0x5f4154)=>_0x3ccf8f&&_0x136925&&!_0x5f4154),_0x168c6d['on']('execute',()=>this['_showDialog']()),_0x508894['set']({'label':g(_0xdb2876,'Open\x20revision\x20history'),'withText':!0x0,'role':'menuitem'}),_0x508894['bind']('isEnabled')['to'](_0x4846e8,'isReady',_0x39936e,'isReadOnly',(_0xb14346,_0x5d0379)=>_0xb14346&&!_0x5d0379),_0x508894['on']('execute',()=>{_0x39936e['config']['get']('revisionHistory')['showRevisionViewerCallback'](),_0x3d7b0f['isOpen']=!0x1,_0x39936e['editing']['view']['focus']();}),_0x4cfaa5['children']['add'](_0x168c6d),_0x4d90a4['children']['add'](_0x508894),_0x703d16['role']='menu',_0x703d16['items']['addMany']([_0x4cfaa5,_0x4d90a4]),_0x4381cd['add'](_0x703d16),_0x3d7b0f;}),_0x39936e['ui']['componentFactory']['add']('menuBar:revisionHistory',()=>this['_registerMenuComponent']());}['_registerMenuComponent'](){const _0x57ef31=this['editor'],_0x20e8b2=_0x57ef31['locale'],_0x156bec=new _0x471360(_0x20e8b2),_0x2cad10=new _0x118393(_0x20e8b2);_0x156bec['buttonView']['set']({'icon':_0x2aae82,'label':g(_0x20e8b2,'Revision\x20history')});const _0x25933d=new _0x47d63b(_0x20e8b2,_0x156bec),_0x15c6b3=new _0x53ffb1(_0x20e8b2);_0x15c6b3['set']({'label':g(_0x20e8b2,'Save\x20current\x20revision')}),_0x15c6b3['delegate']('execute')['to'](_0x156bec),_0x15c6b3['on']('execute',()=>{this['_showDialog']();}),_0x25933d['children']['add'](_0x15c6b3),_0x2cad10['items']['add'](_0x25933d);const _0xdd2470=new _0x47d63b(_0x20e8b2,_0x156bec),_0x4bce90=new _0x53ffb1(_0x20e8b2);return _0x4bce90['set']({'label':g(_0x20e8b2,'Open\x20revision\x20history')}),_0x4bce90['delegate']('execute')['to'](_0x156bec),_0x4bce90['on']('execute',()=>{_0x57ef31['config']['get']('revisionHistory')['showRevisionViewerCallback']();}),_0xdd2470['children']['add'](_0x4bce90),_0x2cad10['items']['add'](_0xdd2470),_0x156bec['panelView']['children']['add'](_0x2cad10),_0x156bec;}['_showDialog'](){const _0x2c688d=this['editor'],_0x505b7b=_0x2c688d['locale'],_0x3222bc=_0x2c688d['plugins']['get']('Dialog'),_0x54a382=_0x2c688d['plugins']['get']('RevisionTracker');function _0x9354ef(_0x3e8354){_0x2c688d['config']['get']('revisionHistory.requireRevisionName')&&''===_0x3e8354['revisionName']?_0x3e8354['revisionNameInputView']['errorText']=g(_0x505b7b,'The\x20revision\x20name\x20cannot\x20be\x20empty.'):(_0x2c688d['plugins']['get'](u)['saveRevision']({'name':_0x3e8354['revisionName']}),_0x3222bc['hide']());}this['_saveRevisionFormView']||(this['_createSaveRevisionFormView'](),this['_saveRevisionFormView']['on']('submit',()=>_0x9354ef(this['_saveRevisionFormView']))),this['_saveRevisionFormView']['reset'](),_0x3222bc['show']({'id':'revisionSave','title':g(_0x505b7b,'Save\x20current\x20revision'),'isModal':!0x0,'content':this['_saveRevisionFormView'],'actionButtons':[{'label':g(_0x2c688d['locale'],'Cancel'),'withText':!0x0,'onExecute':()=>_0x3222bc['hide']()},{'label':g(_0x2c688d['locale'],'Accept'),'class':'ck-button-action','withText':!0x0,'onCreate'(_0x3743d3){_0x3743d3['bind']('isEnabled')['to'](_0x54a382,'isReady',_0x54a382,'isEnabled',_0x2c688d,'isReadOnly',(_0x263cf6,_0x29f129,_0x1beb9c)=>_0x263cf6&&_0x29f129&&!_0x1beb9c);},'onExecute':()=>_0x9354ef(this['_saveRevisionFormView'])}]});}['_createSaveRevisionFormView'](){const _0x161527=this['editor'],_0x309f14=_0x161527['locale'];this['_saveRevisionFormView']=new hs(_0x309f14,_0x161527['config']['get']('revisionHistory.requireRevisionName')),this['_saveRevisionFormView']['render']();}}class Q extends ts{['changeId'];['_model'];constructor(_0x46478f,_0x270f6d){super(_0x46478f),this['_model']=_0x270f6d,this['changeId']=_0x270f6d['id'];const _0x29deaf=this['bindTemplate'],_0x52eeb3=g(_0x46478f,_0x270f6d['data']['isSuggestion']?'Suggested\x20by':'add'==_0x270f6d['type']?'Added\x20by':'Removed\x20by');this['set']('type',_0x270f6d['type']),this['setTemplate']({'tag':'div','attributes':{'class':['ck-annotation','ck-revision-change',_0x29deaf['to']('type',_0x4ec083=>'ck-revision-change__'+_0x4ec083)],'tabindex':-0x1},'children':[{'tag':'span','children':[{'tag':'span','attributes':{'class':['ck-revision-change__label']},'children':[{'text':_0x52eeb3}]},{'text':'\x20'+_0x270f6d['author']['name']}]}]});}['focus'](){this['element']['focus']();}}class r extends/* #__PURE__ -- @preserve */
25
- _0x3196fa(){['id'];['author'];['type'];['data'];['rootName'];constructor(_0x52cf61){super(),this['id']=_0x52cf61['id']||_0x3fbd15(),this['author']=_0x52cf61['author'],this['type']=_0x52cf61['type'],this['data']=_0x52cf61['data']||{},this['rootName']=_0x52cf61['rootName'],this['set']('createdAt',_0x52cf61['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(_0x517c73,_0x434bc4){this['newRevisionId']=_0x517c73,this['oldRevisionId']=_0x434bc4,this['changes']=new _0x5f0faf();}['_setChanges'](_0xa44daa){for(const _0x31d15c of _0xa44daa)this['changes']['add'](_0x31d15c);}}class m extends _0x1aaf30{['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[_0x25ff19,_0x52db93,I,V];}constructor(_0xc8007){super(_0xc8007),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',(_0x155fb1,_0x461bd1,_0x542a87)=>{this['activeChange']=null,this['activeView']=null,this['editor']['editing']['view']['change'](_0x143f3a=>{for(const _0x3ed68f of this['editor']['editing']['view']['document']['roots'])_0x542a87?_0x143f3a['removeClass']('ck-editor__editable__overlay',_0x3ed68f):_0x143f3a['addClass']('ck-editor__editable__overlay',_0x3ed68f);});}),this['bind']('isNavigationMode')['to'](this,'activeChange',_0x1c266f=>null!==_0x1c266f),this['bind']('currentChangeNumber')['to'](this,'isReady',this,'diff',this,'activeChange',(_0x4b795e,_0x4a8e12,_0xa71252)=>_0x4b795e&&_0xa71252?_0x4a8e12['changes']['getIndex'](_0xa71252):0x0),this['bind']('numberOfChanges')['to'](this,'isReady',this,'diff',(_0x513ee2,_0x23e199)=>_0x513ee2?_0x23e199['changes']['length']:0x0),this['_changeView']=null,this['_changeIdToChange']=new Map(),this['_balloon']=this['editor']['plugins']['get'](_0x52db93);}['init'](){const _0x2678e6=this['editor'],_0x472825=new wt(_0x2678e6,{'direction':'backward'}),_0x1b40bd=new wt(_0x2678e6,{'direction':'forward'});(_0x2678e6['commands']['add']('showPreviousChange',_0x472825),_0x2678e6['commands']['add']('showNextChange',_0x1b40bd),_0x2678e6['commands']['add']('restoreRevision',new mt(_0x2678e6)),this['on']('change:numberOfChanges',()=>{_0x472825['refresh'](),_0x1b40bd['refresh']();}),this['_setConversion'](),this['_initInteractions'](),_0x2678e6['enableReadOnlyMode']('revision-viewer'),_0x2678e6['plugins']['has']('WidgetToolbarRepository'))&&_0x2678e6['plugins']['get']('WidgetToolbarRepository')['forceDisabled']('revision-viewer');}async['getRevisionDocumentData'](_0x12ddc0){return await this['_utils']['loadRevisionData'](_0x12ddc0,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x12ddc0);}async['getRevisionRootsAttributes'](_0x4fb5a1){return await this['_utils']['loadRevisionData'](_0x4fb5a1,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x4fb5a1);}async['compare'](_0x3ab766,_0x458a54,_0x45f6dc=!0x1){if(!this['isEnabled'])return;const _0x55bef2=this['diff'],_0x151d04=this['repository'],_0x23106e='string'==typeof _0x3ab766?_0x151d04['getRevision'](_0x3ab766):_0x3ab766,_0x463c13='string'==typeof _0x458a54?_0x151d04['getRevision'](_0x458a54):_0x458a54,_0x3fba0f=_0x23106e['id'],_0x17b3ef=_0x463c13?_0x463c13['id']:null;if(!_0x45f6dc&&this['diff']&&this['diff']['newRevisionId']===_0x3fba0f&&this['diff']['oldRevisionId']===_0x17b3ef)return Promise['resolve']();this['isReady']=!0x1,this['activeView']=null,this['activeChange']=null,this['diff']=new c(_0x3fba0f,_0x17b3ef);const _0x4165ee=this['_getRevisionsRange'](_0x23106e,_0x463c13,!0x0)['map'](_0x2f4504=>this['_utils']['loadRevisionData'](_0x2f4504,this['adapter']));return _0x4165ee['push'](new Promise(_0x30a92e=>{setTimeout(_0x30a92e,0x14);})),Promise['all'](_0x4165ee)['then'](()=>{if(!this['isEnabled'])return;this['_cleanUp']();const _0xe90cac=this['_getDiff'](_0x3fba0f,_0x17b3ef);for(const _0x3711d2 of _0xe90cac['changes'])this['_changeIdToChange']['set'](_0x3711d2['id'],_0x3711d2);this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x379996=>{for(const _0x33a480 of this['editor']['model']['document']['getRootNames']())_0x379996['detachRoot'](_0x33a480);for(const _0x4097b6 of Object['keys'](_0xe90cac['model'])){const _0x9cc671=_0x379996['addRoot'](_0x4097b6);for(const _0x8cc04e of Object['keys'](_0xe90cac['attributes'][_0x4097b6]))_0x379996['setAttribute'](_0x8cc04e,_0xe90cac['attributes'][_0x4097b6][_0x8cc04e],_0x9cc671);_0x379996['insert'](_0xe90cac['model'][_0x4097b6],_0x9cc671,0x0);}}),this['diff']['_setChanges'](this['_sortAndFilterDiffChanges'](_0xe90cac['changes'])),this['isReady']=!0x0;})['catch'](_0xaa5842=>{console['error'](_0xaa5842),this['_cleanUp'](),_0x55bef2&&(this['diff']=_0x55bef2),this['isReady']=!0x0;});}['addRevisionData'](_0x197688,_0x15196a){const _0x5e3470=this['repository']['createRevision'](_0x197688);return _0x5e3470['on']('_update',(_0x5c1ab9,_0x5927cb,_0x7a1e63)=>_0x15196a(_0x5927cb,_0x7a1e63,_0x5e3470)),this['repository']['addRevision'](_0x5e3470),_0x5e3470;}['_cleanUp'](){this['activeChange']=null,this['_cleanMarkers'](),this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=null,this['_changeIdToChange']['clear'](),this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x4761aa=>{for(const _0x6e8091 of this['editor']['model']['document']['getRootNames']())_0x4761aa['detachRoot'](_0x6e8091);});}['_sortAndFilterDiffChanges'](_0x4471c9){const _0x3145c8=[],_0x5a8633=new Map();for(const _0x551bb8 of this['editor']['model']['document']['getRootNames']()){const _0xa3612e=this['editor']['editing']['view']['getDomRoot'](_0x551bb8);if(!_0xa3612e)continue;const _0x2b84eb=_0xa3612e['getClientRects']()['item'](0x0);_0x2b84eb&&(_0x3145c8['push'](_0x551bb8),_0x5a8633['set'](_0x551bb8,_0x2b84eb));}return _0x3145c8['sort']((_0xb7f2ae,_0x6f0d55)=>{const _0x5045de=_0x5a8633['get'](_0xb7f2ae),_0x3153a8=_0x5a8633['get'](_0x6f0d55);return _0x5045de['y']-_0x3153a8['y']||_0x5045de['x']-_0x3153a8['x'];}),(_0x4471c9=_0x4471c9['filter'](_0x3c4d81=>_0x3145c8['includes'](_0x3c4d81['rootName'])))['sort']((_0x2159e2,_0x58a901)=>_0x3145c8['indexOf'](_0x2159e2['rootName'])-_0x3145c8['indexOf'](_0x58a901['rootName'])),_0x4471c9;}['_makeTape'](_0xecc0a){const _0x309bd1=Array['from'](_0xecc0a['markers'])['filter'](([_0x53a14a,_0x198839])=>_0x53a14a['startsWith']('revision:')&&!_0x198839['isCollapsed']),_0x2b4383=Array['from'](this['editor']['model']['createRangeIn'](_0xecc0a)['getWalker']({'singleCharacters':!0x0}));if(0x0!=_0x309bd1['length'])for(const _0x4680de of _0x2b4383){const [_0x30c58c,_0x5cf893]=_0x309bd1[0x0],[,_0x274777,_0x4f96f9]=_0x30c58c['split'](':');if(_0x5cf893['end']['isEqual'](_0x4680de['nextPosition'])&&_0x309bd1['shift'](),(_0x4680de['previousPosition']['isEqual'](_0x5cf893['start'])||_0x4680de['previousPosition']['isAfter'](_0x5cf893['start']))&&('insertion'==_0x274777?_0x4680de['isAdded']={'userId':_0x4f96f9}:'deletion'==_0x274777&&(_0x4680de['isRemoved']={'userId':_0x4f96f9})),0x0==_0x309bd1['length'])break;}return _0x2b4383;}['_refreshStartEndIndex'](_0x5d2696){const _0x20e318=new Map();for(let _0x4de539=0x0;_0x4de539<_0x5d2696['length'];_0x4de539++)'text'===_0x5d2696[_0x4de539]['type']?(_0x5d2696[_0x4de539]['item']['startIndex']=_0x4de539,_0x5d2696[_0x4de539]['item']['endIndex']=_0x4de539):('elementStart'===_0x5d2696[_0x4de539]['type']?_0x5d2696[_0x4de539]['item']['startIndex']=_0x4de539:'elementEnd'===_0x5d2696[_0x4de539]['type']&&(_0x5d2696[_0x4de539]['item']['endIndex']=_0x4de539),_0x20e318['set'](_0x5d2696[_0x4de539]['id'],_0x4de539));for(const _0x4a5113 of _0x20e318['values']())'elementStart'===_0x5d2696[_0x4a5113]['type']?_0x5d2696[_0x4a5113]['item']['endIndex']=_0x20e318['get'](_0x5d2696[_0x4a5113]['pairId']):'elementEnd'===_0x5d2696[_0x4a5113]['type']&&(_0x5d2696[_0x4a5113]['item']['startIndex']=_0x20e318['get'](_0x5d2696[_0x4a5113]['pairId']));}['_processTape'](_0x509bfe){for(let _0x1cdec2=0x0;_0x1cdec2<_0x509bfe['length'];_0x1cdec2++){if('elementStart'===_0x509bfe[_0x1cdec2]['type'])_0x509bfe[_0x1cdec2]['item']['startIndex']=_0x1cdec2;else{if('elementEnd'===_0x509bfe[_0x1cdec2]['type']){_0x509bfe[_0x1cdec2]['item']['endIndex']=_0x1cdec2;const _0x196339=_0x509bfe[_0x1cdec2]['item']['startIndex'];_0x509bfe[_0x196339]['pairId']=_0x509bfe[_0x1cdec2]['id'],_0x509bfe[_0x1cdec2]['pairId']=_0x509bfe[_0x196339]['id'];}else _0x509bfe[_0x1cdec2]['item']['startIndex']=_0x1cdec2,_0x509bfe[_0x1cdec2]['item']['endIndex']=_0x1cdec2,_0x509bfe[_0x1cdec2]['pairId']=null;}_0x509bfe[_0x1cdec2]['markersStart']||(_0x509bfe[_0x1cdec2]['markersStart']=[],_0x509bfe[_0x1cdec2]['markersEnd']=[]);}}['_markInsertions'](_0x44f4c4,_0x35fff0){const _0x4598c0=_0x44f4c4['filter'](_0x3790f5=>!_0x3790f5['isAdded']);for(let _0x5be7ad=0x0;_0x5be7ad<_0x35fff0['length'];_0x5be7ad++)_0x35fff0[_0x5be7ad]['isAdded']&&(_0x4598c0[_0x5be7ad]['isAdded']=_0x35fff0[_0x5be7ad]['isAdded']);}['_getDiff'](_0x3f0c68,_0x550ad8=null){const _0x3df6f0=this['repository']['getRevision'](_0x3f0c68),_0x4214cc=_0x550ad8?this['repository']['getRevision'](_0x550ad8):null,_0x4f55d2=this['_getRevisionsRange'](_0x3df6f0,_0x4214cc),_0x466893=_0x4f55d2[_0x4f55d2['length']-0x1],_0x54889f=new Map(),_0x36947e={'model':{},'attributes':{},'changes':[]},_0x32f163=new Set(),_0x4bf9db=new Map();for(let _0xbde911=_0x4f55d2['length']-0x1;_0xbde911>=0x0;_0xbde911--){const _0x50e64b=_0x4f55d2[_0xbde911];for(const _0x362ba5 of Object['keys'](_0x50e64b['diffData']))if(_0x50e64b['diffData'][_0x362ba5]['attachChange']){const _0x22d94b=_0x50e64b['diffData'][_0x362ba5]['attachChange'];_0x22d94b['isAttached']?(_0x32f163['add'](_0x362ba5),_0x4bf9db['has'](_0x362ba5)&&_0x4bf9db['get'](_0x362ba5)['userId']==_0x22d94b['userId']?_0x4bf9db['delete'](_0x362ba5):_0x4bf9db['set'](_0x362ba5,_0x22d94b)):_0x4bf9db['has'](_0x362ba5)?(_0x32f163['delete'](_0x362ba5),_0x4bf9db['delete'](_0x362ba5)):(_0x32f163['add'](_0x362ba5),_0x4bf9db['set'](_0x362ba5,_0x22d94b));}else _0x32f163['add'](_0x362ba5);}for(const _0x2c1d71 of _0x32f163){const _0x2eeba0=_0x4bf9db['has'](_0x2c1d71)&&!_0x4bf9db['get'](_0x2c1d71)['isAttached'];let _0x13bc0b=_0x2eeba0?_0x4f55d2['length']-0x1:0x0;const _0x9425bb=_0x2eeba0?-0x1:0x1;for(;_0x4f55d2[_0x13bc0b];){const _0x3c0249=_0x4f55d2[_0x13bc0b];if(_0x3c0249['diffData'][_0x2c1d71]){const _0x33d04d=_0x2eeba0?_0x3c0249['diffData'][_0x2c1d71]['attributesBefore']:_0x3c0249['diffData'][_0x2c1d71]['attributesAfter'];_0x36947e['attributes'][_0x2c1d71]=_0x33d04d?_0x4dbdf7(_0x33d04d):{};break;}_0x13bc0b+=_0x9425bb;}}for(const _0x3dbc8a of _0x4f55d2){_0x3dbc8a['model']={};for(const _0x5c0213 of _0x3dbc8a['authors'])_0x54889f['set'](_0x5c0213['id'],_0x5c0213);for(const _0xe9dec6 of _0x32f163){const _0x4104e9=_0x3dbc8a['diffData'][_0xe9dec6]?_0x3dbc8a['diffData'][_0xe9dec6]['insertions']:'[]',_0x1722ac=_0x3dbc8a['diffData'][_0xe9dec6]?_0x3dbc8a['diffData'][_0xe9dec6]['deletions']:'[]';_0x3dbc8a['model'][_0xe9dec6]={'insertions':this['_utils']['_makeModelFromViewString'](_0x4104e9),'deletions':this['_utils']['_makeModelFromViewString'](_0x1722ac)};}}for(const _0x2961bd of _0x32f163){let _0x5e6d15=null,_0x2cadd5=0x0;const _0x20dec9=new Map(Array['from'](_0x3df6f0['model'][_0x2961bd]['insertions']['markers'])['filter'](([_0x5ecd79])=>!_0x5ecd79['startsWith']('revision:')));let _0x585d03=0x0;for(const _0x12cd1d of _0x4f55d2){const _0x25dcb8=this['_makeTape'](_0x12cd1d['model'][_0x2961bd]['insertions']);_0x12cd1d==_0x3df6f0?(_0x5e6d15=_0x25dcb8,_0x2cadd5=_0x5e6d15['length'],_0x5e6d15['forEach'](_0x45822a=>{_0x45822a['id']=_0x585d03++;}),this['_processTape'](_0x5e6d15)):this['_markInsertions'](_0x5e6d15,_0x25dcb8);const _0x1bb6b9=_0x5e6d15['filter'](_0x4a674d=>!_0x4a674d['isAdded'])['map'](_0x436a51=>_0x436a51['id']);let _0x54a8fd=0x0;const _0x5d75d2=this['_makeTape'](_0x12cd1d['model'][_0x2961bd]['deletions']);_0x5d75d2['forEach'](_0x2b4240=>{_0x2b4240['isRemoved']?_0x2b4240['id']=_0x2cadd5++:_0x2b4240['id']=_0x1bb6b9[_0x54a8fd++];}),this['_processTape'](_0x5d75d2),this['_setDistance'](_0x5e6d15,'isAdded'),this['_setDistance'](_0x5d75d2,'isRemoved'),_0x12cd1d==_0x3df6f0&&this['_markMarkers'](_0x5e6d15,_0x20dec9),_0x5e6d15=this['_joinTapes'](_0x5e6d15,_0x5d75d2),this['_refreshStartEndIndex'](_0x5e6d15),this['_setDistance'](_0x5e6d15,'isRemoved');}_0x5e6d15=_0x5e6d15['filter'](_0x403a73=>!(_0x403a73['isAdded']&&_0x403a73['isRemoved']));const _0xde03be=new Map(_0x466893['model'][_0x2961bd]['deletions']['markers']),_0x1a75e8=new Set(_0x20dec9['keys']());for(const _0x2f9eef of _0xde03be['keys']())_0x1a75e8['delete'](_0x2f9eef);this['_markSuggestions'](_0x5e6d15,_0x1a75e8),this['_fixObsoleteTags'](_0x5e6d15),_0x5e6d15=this['_removeMissingPairs'](_0x5e6d15),_0x5e6d15=this['_markMismatchedRemovedTags'](_0x5e6d15),_0x5e6d15=this['_removeUnsupportedChanges'](_0x5e6d15);const {root:_0x37f56e,changes:_0x24dec8}=this['_makeModelFromTape'](_0x5e6d15,_0x54889f,_0x2961bd);_0x36947e['model'][_0x2961bd]=_0x37f56e;const _0x408337=_0x4bf9db['get'](_0x2961bd);if(_0x408337){const _0x11000f=_0x54889f['get'](_0x408337['userId']),_0xd16f78=new r({'author':_0x11000f,'type':_0x408337['isAttached']?'add':'remove','data':{'isOnRoot':!0x0},'createdAt':new Date(),'rootName':_0x2961bd});_0x24dec8['unshift'](_0xd16f78),_0x36947e['attributes'][_0x2961bd]['revisionHistoryAttachChange']=_0xd16f78['id'];}_0x36947e['changes']=_0x36947e['changes']['concat'](_0x24dec8);}return _0x36947e;}['_markMarkers'](_0x5bfdb1,_0x4f0a47){for(let _0x3e54b5=0x0;_0x3e54b5<_0x5bfdb1['length'];_0x3e54b5++)for(const [_0x2de637,_0xd6fc36]of _0x4f0a47)!_0xd6fc36['isCollapsed']&&_0xd6fc36['start']['isEqual'](_0x5bfdb1[_0x3e54b5]['previousPosition'])&&_0x5bfdb1[_0x3e54b5]['markersStart']['push'](_0x2de637),_0xd6fc36['end']['isEqual'](_0x5bfdb1[_0x3e54b5]['nextPosition'])&&_0x5bfdb1[_0x3e54b5]['markersEnd']['push'](_0x2de637);}['_joinTapes'](_0x132c93,_0x3f3050){let _0x802f0b=[],_0x371c8f=0x0,_0x32ad58=0x0;for(;_0x371c8f<_0x132c93['length']||_0x32ad58<_0x3f3050['length'];){const _0x19f72f=_0x132c93[_0x371c8f]||{},_0x46d2c4=_0x3f3050[_0x32ad58]||{};if(_0x19f72f['id']==_0x46d2c4['id'])_0x371c8f++,_0x32ad58++,_0x802f0b['push'](_0x19f72f);else{if(_0x46d2c4['isRemoved']&&_0x19f72f['isAdded']){const {commonTape:_0x2c326a,iEnd:_0x9be006,jEnd:_0x1685df}=this['_threeWayMerge'](_0x132c93,_0x371c8f,_0x3f3050,_0x32ad58);_0x802f0b=_0x802f0b['concat'](_0x2c326a),_0x371c8f=_0x9be006,_0x32ad58=_0x1685df;}else _0x46d2c4['isRemoved']?(_0x32ad58++,_0x802f0b['push'](_0x46d2c4)):(_0x371c8f++,_0x802f0b['push'](_0x19f72f));}}return _0x802f0b;}['_markSuggestions'](_0x3752b2,_0x3a0afd){const _0x39ab18=[];for(let _0x437f59=0x0;_0x437f59<_0x3752b2['length'];_0x437f59++){for(let _0x2b233e=0x0;_0x2b233e<_0x3752b2[_0x437f59]['markersStart']['length'];_0x2b233e++){const _0x23d767=_0x3752b2[_0x437f59]['markersStart'][_0x2b233e];if(!_0x3a0afd['has'](_0x23d767))continue;const {group:_0x5f2ac8,type:_0x146f2a,authorId:_0x492d81}=_0x3f0928(_0x23d767);'revision-suggestion'!=_0x5f2ac8||'insertion'!=_0x146f2a&&'deletion'!=_0x146f2a||(_0x39ab18['unshift']({'type':_0x146f2a,'name':_0x23d767,'userId':_0x492d81}),_0x3752b2[_0x437f59]['markersStart']['splice'](_0x2b233e,0x1),_0x2b233e--);}_0x158947(_0x3752b2[_0x437f59]);for(let _0x56b005=0x0;_0x56b005<_0x3752b2[_0x437f59]['markersEnd']['length'];_0x56b005++){const _0x24111e=_0x3752b2[_0x437f59]['markersEnd'][_0x56b005];if(!_0x3a0afd['has'](_0x24111e))continue;const {group:_0x138c10,type:_0x38116e}=_0x3f0928(_0x24111e);if('revision-suggestion'!=_0x138c10||'insertion'!=_0x38116e&&'deletion'!=_0x38116e)continue;_0x3752b2[_0x437f59]['markersEnd']['splice'](_0x56b005,0x1),_0x56b005--;const _0x8ac08a=_0x39ab18['findIndex'](_0x586a3a=>_0x586a3a['name']==_0x24111e);_0x8ac08a>-0x1&&_0x39ab18['splice'](_0x8ac08a,0x1);}}function _0x3f0928(_0x3e2400){const _0x5d7acd=_0x3e2400['split'](':');return{'group':_0x5d7acd[0x0],'type':_0x5d7acd[0x1],'subType':_0x5d7acd['length']>=0x5?_0x5d7acd[0x2]:null,'id':_0x5d7acd['length']<0x5?_0x5d7acd[0x2]:_0x5d7acd[0x3],'authorId':_0x5d7acd['length']<0x5?_0x5d7acd[0x3]:_0x5d7acd[0x4],'markerCount':0x6==_0x5d7acd['length']?_0x5d7acd[0x5]:null};}function _0x158947(_0x1cd483){for(let _0x450176=0x0;_0x450176<_0x39ab18['length'];_0x450176++){if(_0x1cd483['isAdded']&&'insertion'==_0x39ab18[_0x450176]['type'])return _0x1cd483['isAddSuggestion']=_0x39ab18[_0x450176],void delete _0x1cd483['isAdded'];if(!_0x1cd483['isAdded']&&!_0x1cd483['isRemoved']&&'deletion'==_0x39ab18[_0x450176]['type'])return void(_0x1cd483['isRemoveSuggestion']=_0x39ab18[_0x450176]);}}}['_setDistance'](_0x413a05,_0x42d055){let _0x17e6cd=0x0,_0x1eac30=!0x1;const _0xe6d70c=new Map();for(const _0x582cdb of _0x413a05)_0x582cdb[_0x42d055]?_0x1eac30&&(_0x17e6cd++,_0x1eac30=!0x1):(_0x17e6cd++,_0x1eac30=!0x0),_0xe6d70c['set'](_0x582cdb['id'],_0x17e6cd);for(let _0x2e8673=0x0;_0x2e8673<_0x413a05['length'];_0x2e8673++){if('isRemoved'==_0x42d055&&_0x413a05[_0x2e8673]['isAdded']||'isAdded'==_0x42d055&&_0x413a05[_0x2e8673]['isRemoved'])continue;if('text'==_0x413a05[_0x2e8673]['type']){_0x413a05[_0x2e8673]['distance']=0x0;continue;}const _0x279ff6=_0xe6d70c['get'](_0x413a05[_0x2e8673]['pairId']),_0x2201a5=_0xe6d70c['get'](_0x413a05[_0x2e8673]['id']);_0x413a05[_0x2e8673]['distance']=_0x279ff6-_0x2201a5;}}['_getRevisionsRange'](_0x3ebe62,_0x290d66,_0x43beec=!0x1){const _0x23dd8f=[];let _0x4f7772=this['repository']['getIndex'](_0x3ebe62),_0x23432b=this['repository']['getIndex'](_0x290d66);for(-0x1==_0x23432b&&(_0x23432b=this['repository']['_revisions']['length'],_0x43beec=!0x1);_0x4f7772<_0x23432b;)_0x23dd8f['push'](this['repository']['getRevision'](_0x4f7772)),_0x4f7772++;return _0x43beec&&_0x23dd8f['push'](this['repository']['getRevision'](_0x4f7772)),_0x23dd8f;}['_threeWayMerge'](_0x426f45,_0x17b346,_0x43aa02,_0x24ff01){const _0xa85513=this['editor']['model']['schema'];let _0x3de9ff=_0x17b346;for(;_0x426f45[_0x3de9ff]&&_0x426f45[_0x3de9ff]['isAdded'];)_0x3de9ff++;let _0x52b0c7=_0x24ff01;for(;_0x43aa02[_0x52b0c7]&&_0x43aa02[_0x52b0c7]['isRemoved'];)_0x52b0c7++;_0x4520a9(_0x426f45,_0x17b346,_0x3de9ff),_0x4520a9(_0x43aa02,_0x24ff01,_0x52b0c7);const _0x344d00=_0x43aa02['slice'](_0x24ff01,_0x52b0c7)['concat'](_0x426f45['slice'](_0x17b346,_0x3de9ff));return _0x344d00['sort']((_0x3cc78a,_0x6a573b)=>_0x3cc78a['side']!=_0x6a573b['side']?_0x3cc78a['side']-_0x6a573b['side']:_0x3cc78a['level']!=_0x6a573b['level']?_0x3cc78a['level']-_0x6a573b['level']:_0x3cc78a['distance']!=_0x6a573b['distance']?_0x6a573b['distance']-_0x3cc78a['distance']:!!_0x3cc78a['isAdded']!=!!_0x6a573b['isAdded']?-0x1==_0x3cc78a['side']||0x0==_0x3cc78a['side']?_0x3cc78a['isAdded']?-0x1:0x1:_0x3cc78a['isAdded']?0x1:-0x1:_0x3cc78a['index']-_0x6a573b['index']),{'commonTape':_0x344d00,'iEnd':_0x3de9ff,'jEnd':_0x52b0c7};function _0x4520a9(_0x365ce9,_0x21a41a,_0x20f3c5){let _0x1cfab0=-0x1,_0x447de4=Number['POSITIVE_INFINITY'],_0x3dd51a=!0x0;for(let _0x5823ff=_0x21a41a;_0x5823ff<_0x20f3c5;_0x5823ff++)if(_0xa85513['isInline'](_0x365ce9[_0x5823ff]['item'])||(_0x3dd51a=!0x1),_0x365ce9[_0x5823ff]['item']['startIndex']<_0x21a41a&&(_0x1cfab0=_0x5823ff),_0x365ce9[_0x5823ff]['item']['endIndex']>=_0x20f3c5){_0x447de4=_0x5823ff;break;}_0x3dd51a&&(_0x1cfab0=_0x20f3c5-0x1);for(let _0xe3977e=_0x21a41a;_0xe3977e<_0x20f3c5;_0xe3977e++)_0x365ce9[_0xe3977e]['side']=_0xe3977e<=_0x1cfab0?-0x1:_0xe3977e<_0x447de4?0x0:0x1,_0x365ce9[_0xe3977e]['index']=_0xe3977e;let _0x5bd23e=0x0;for(let _0x15c58e=_0x21a41a;_0x15c58e<=_0x1cfab0;_0x15c58e++)0x0==_0x365ce9[_0x15c58e]['distance']?_0x365ce9[_0x15c58e]['level']=_0x5bd23e:(_0x5bd23e++,_0x365ce9[_0x15c58e]['level']=_0x5bd23e,_0x5bd23e++);for(let _0xd90076=_0x21a41a;_0xd90076<_0x20f3c5;_0xd90076++)0x0==_0x365ce9[_0xd90076]['side']&&(_0x365ce9[_0xd90076]['level']=_0x5bd23e);_0x5bd23e=0x0;for(let _0x46cfde=_0x20f3c5-0x1;_0x46cfde>=_0x447de4;_0x46cfde--)0x0==_0x365ce9[_0x46cfde]['distance']?_0x365ce9[_0x46cfde]['level']=_0x5bd23e:(_0x5bd23e--,_0x365ce9[_0x46cfde]['level']=_0x5bd23e,_0x5bd23e--);}}['_fixObsoleteTags'](_0x5d9653){const _0x3133c5=new Map(),_0x228705=this['editor']['model']['schema'];for(let _0xcd14e4=0x1;_0xcd14e4<_0x5d9653['length'];_0xcd14e4++){let _0x3f35a6,_0x4e1ab6,_0x20b8b1;const _0xdd2993=_0x5d9653[_0xcd14e4],_0x57a2cc=_0x5d9653[_0xcd14e4-0x1];if('text'==_0xdd2993['type'])continue;if(_0xdd2993['type']!=_0x57a2cc['type'])continue;if(!_0x228705['isBlock'](_0x57a2cc['item'])||_0x228705['isLimit'](_0x57a2cc['item']))continue;if(!_0x228705['isBlock'](_0xdd2993['item'])||_0x228705['isLimit'](_0xdd2993['item']))continue;if((_0x5d9653[_0xcd14e4]['isAdded']||_0x5d9653[_0xcd14e4]['isAddSuggestion'])&&_0x5d9653[_0xcd14e4-0x1]['isRemoved'])_0x3f35a6=_0x5d9653[_0xcd14e4],_0x4e1ab6=_0x5d9653[_0xcd14e4-0x1],_0x20b8b1=_0xcd14e4-0x1;else{if(!_0x5d9653[_0xcd14e4]['isRemoved']||!_0x5d9653[_0xcd14e4-0x1]['isAdded']&&!_0x5d9653[_0xcd14e4-0x1]['isAddSuggestion'])continue;_0x3f35a6=_0x5d9653[_0xcd14e4-0x1],_0x4e1ab6=_0x5d9653[_0xcd14e4],_0x20b8b1=_0xcd14e4;}const _0x1c8f1f=_0x3f35a6['level']==_0x4e1ab6['level'],_0x1c54ef=Math['abs'](_0x3f35a6['level'])<Math['abs'](_0x4e1ab6['level'])&&0x0==_0x4e1ab6['distance'];(_0x1c8f1f||_0x1c54ef)&&(_0x3133c5['set'](_0x4e1ab6['id'],_0x3f35a6['id']),_0x5d9653['splice'](_0x20b8b1,0x1),_0xcd14e4--,_0x3f35a6['isAdded']=!0x1);}for(let _0x3df9f1=0x0;_0x3df9f1<_0x5d9653['length'];_0x3df9f1++)_0x3133c5['has'](_0x5d9653[_0x3df9f1]['pairId'])&&(_0x5d9653[_0x3df9f1]['pairId']=_0x3133c5['get'](_0x5d9653[_0x3df9f1]['pairId']));}['_removeMissingPairs'](_0xdd4b78){const _0x1ec90e=new Set(_0xdd4b78['map'](_0x5ee1a2=>_0x5ee1a2['id']));for(let _0x158061=0x0;_0x158061<_0xdd4b78['length'];_0x158061++)_0x1ec90e['has'](_0xdd4b78[_0x158061]['pairId'])||0x0==_0xdd4b78[_0x158061]['distance']||(_0xdd4b78[_0x158061]['isIncorrect']=!0x0);return _0xdd4b78['filter'](_0x296c1c=>!_0x296c1c['isIncorrect']);}['_markMismatchedRemovedTags'](_0x50739d){const _0x5f5cee=new Set();for(let _0x1ef216=0x0;_0x1ef216<_0x50739d['length'];_0x1ef216++){if(_0x5f5cee['has'](_0x50739d[_0x1ef216]['id'])&&_0x50739d[_0x1ef216]['isRemoved']&&(_0x50739d[_0x1ef216]['isIncorrect']=!0x0),_0x50739d[_0x1ef216]['isIncorrect'])continue;if(0x0==_0x50739d[_0x1ef216]['distance'])continue;if('elementStart'!=_0x50739d[_0x1ef216]['type'])continue;if(null==_0x50739d[_0x1ef216]['pairId'])continue;let _0x5c5f3b=_0x1ef216+0x1,_0x68c595=0x0;for(;_0x50739d[_0x5c5f3b]['id']!=_0x50739d[_0x1ef216]['pairId'];)'elementStart'==_0x50739d[_0x5c5f3b]['type']?_0x68c595++:'elementEnd'==_0x50739d[_0x5c5f3b]['type']&&_0x68c595--,_0x5c5f3b++;if(0x0!=_0x68c595){if(_0x50739d[_0x1ef216]['isRemoved'])_0x50739d[_0x1ef216]['isIncorrect']=!0x0;else{for(;_0x5c5f3b!=_0x1ef216;)_0x50739d[_0x5c5f3b]['isRemoved']&&0x0!=_0x50739d[_0x5c5f3b]['distance']&&(_0x50739d[_0x5c5f3b]['isIncorrect']=!0x0,_0x5f5cee['add'](_0x50739d[_0x5c5f3b]['pairId'])),_0x5c5f3b--;}}}return _0x50739d['filter'](_0xe62c13=>!_0xe62c13['isIncorrect']);}['_removeUnsupportedChanges'](_0x3fa082){const _0x43f748=this['editor']['model']['schema'];for(let _0x1f17f8=0x0;_0x1f17f8<_0x3fa082['length'];_0x1f17f8++){if(!(_0x3fa082[_0x1f17f8]['isAdded']||_0x3fa082[_0x1f17f8]['isAddSuggestion']||_0x3fa082[_0x1f17f8]['isRemoved']||_0x3fa082[_0x1f17f8]['isRemoveSuggestion']))continue;if(0x0==_0x3fa082[_0x1f17f8]['distance'])continue;const _0x482602=_0x3fa082[_0x1f17f8]['item'];_0x43f748['isBlock'](_0x482602)||_0x43f748['isLimit'](_0x482602)||(_0x3fa082[_0x1f17f8]['isAdded']&&delete _0x3fa082[_0x1f17f8]['isAdded'],_0x3fa082[_0x1f17f8]['isAddSuggestion']&&delete _0x3fa082[_0x1f17f8]['isAddSuggestion'],_0x3fa082[_0x1f17f8]['isRemoveSuggestion']&&delete _0x3fa082[_0x1f17f8]['isRemoveSuggestion'],_0x3fa082[_0x1f17f8]['isRemoved']&&(_0x3fa082[_0x1f17f8]['isIncorrect']=!0x0));}return _0x3fa082['filter'](_0x597625=>!_0x597625['isIncorrect']);}['_makeModelFromTape'](_0x2bd10b,_0x2f3838,_0x78bb86){const _0x6d89ea=new vt(),_0x1c2ed4=[],_0x1df030=new Map(),_0x43138c=this['editor']['model'],_0x35d489=_0x43138c['schema'],_0xa19a53=[_0x6d89ea],_0x51f3ae={},_0x2f8845={'isAdded':[],'isRemoved':[],'isAddSuggestion':[],'isRemoveSuggestion':[]};let _0x4dc062=null;const _0x31d934=[0x0];for(let _0x2a66a4=0x0;_0x2a66a4<_0x2bd10b['length'];_0x2a66a4++)if('elementStart'===_0x2bd10b[_0x2a66a4]['type']){_0x2bd10b[_0x2a66a4]['previousPosition']=_0x43138c['createPositionFromPath'](_0x6d89ea,_0x31d934);const _0x3e01c9=new ut(_0x2bd10b[_0x2a66a4]['item']['name'],_0x2bd10b[_0x2a66a4]['item']['getAttributes']());_0xa19a53[0x0]['_appendChild'](_0x3e01c9),_0x31d934['push'](0x0),_0xa19a53['unshift'](_0x3e01c9),_0x2bd10b[_0x2a66a4]['nextPosition']=_0x43138c['createPositionFromPath'](_0x6d89ea,_0x31d934);}else'elementEnd'===_0x2bd10b[_0x2a66a4]['type']?(_0xa19a53['shift'](),_0x2bd10b[_0x2a66a4]['previousPosition']=_0x43138c['createPositionFromPath'](_0x6d89ea,_0x31d934),_0x31d934['pop'](),_0x31d934[_0x31d934['length']-0x1]++,_0x2bd10b[_0x2a66a4]['nextPosition']=_0x43138c['createPositionFromPath'](_0x6d89ea,_0x31d934)):(_0x2bd10b[_0x2a66a4]['previousPosition']=_0x43138c['createPositionFromPath'](_0x6d89ea,_0x31d934),_0x4dc062?_0x4dc062['_data']+=_0x2bd10b[_0x2a66a4]['item']['data']:_0x4dc062=new gt(_0x2bd10b[_0x2a66a4]['item']['data'],_0x2bd10b[_0x2a66a4]['item']['getAttributes']()),_0x2bd10b[_0x2a66a4+0x1]&&'text'===_0x2bd10b[_0x2a66a4+0x1]['type']&&_0xdd137b(_0x4dc062,_0x2bd10b[_0x2a66a4+0x1]['item'])||(_0xa19a53[0x0]['_appendChild'](_0x4dc062),_0x4dc062=null),_0x31d934[_0x31d934['length']-0x1]+=_0x2bd10b[_0x2a66a4]['item']['offsetSize'],_0x2bd10b[_0x2a66a4]['nextPosition']=_0x43138c['createPositionFromPath'](_0x6d89ea,_0x31d934));for(let _0x34bbc4=0x0;_0x34bbc4<_0x2bd10b['length'];_0x34bbc4++){const _0x536592=_0x2bd10b[_0x34bbc4]['previousPosition'],_0x3d9dea=_0x2bd10b[_0x34bbc4]['nextPosition'];for(const _0x32221f of _0x2bd10b[_0x34bbc4]['markersStart'])_0x1df030['set'](_0x32221f,{'start':_0x536592,'end':null});_0x30fe40('isRemoveSuggestion',_0x34bbc4,_0x536592,_0x3d9dea),_0x30fe40('isAddSuggestion',_0x34bbc4,_0x536592,_0x3d9dea),_0x30fe40('isRemoved',_0x34bbc4,_0x536592,_0x3d9dea),_0x30fe40('isAdded',_0x34bbc4,_0x536592,_0x3d9dea);for(const _0x192c80 of _0x2bd10b[_0x34bbc4]['markersEnd']){const _0x262532=_0x1df030['get'](_0x192c80);_0x262532?_0x262532['end']=_0x3d9dea:_0x1df030['set'](_0x192c80,{'start':_0x3d9dea,'end':_0x3d9dea});}}for(const [_0x43a334,_0x455fbd]of _0x1df030){const _0x80ba22=this['editor']['model']['createRange'](_0x455fbd['start'],_0x455fbd['end']);_0x6d89ea['markers']['set'](_0x43a334,_0x80ba22);}return _0x1c2ed4['sort']((_0x505a16,_0x411a0e)=>{const _0x5a5af6=_0x6d89ea['markers']['get']('revision:'+_0x505a16['id']),_0x5bee43=_0x6d89ea['markers']['get']('revision:'+_0x411a0e['id']);return _0x5a5af6['start']['isBefore'](_0x5bee43['start'])?-0x1:_0x5a5af6['start']['isAfter'](_0x5bee43['start'])?0x1:_0x5a5af6['end']['isBefore'](_0x5bee43['end'])?-0x1:_0x5a5af6['end']['isAfter'](_0x5bee43['end'])?0x1:'add'===_0x505a16['type']?-0x1:0x1;}),{'root':_0x6d89ea,'changes':_0x1c2ed4};function _0x30fe40(_0x1f3a62,_0x548718,_0x572d8e,_0x1b8455){const _0x284fe9=!!_0x2bd10b[_0x548718][_0x1f3a62],_0x116618=_0x284fe9?_0x2bd10b[_0x548718][_0x1f3a62]['userId']:null,_0x5cdaaf=_0x548718===_0x2bd10b['length']-0x1,_0x16f321=_0x2f8845[_0x1f3a62][0x0],_0x1798ea=_0x35d489['isObject'](_0x2bd10b[_0x548718]['item']);!_0x51f3ae[_0x1f3a62]&&_0x284fe9?_0x51f3ae[_0x1f3a62]={'start':_0x572d8e,'tapeItem':_0x2bd10b[_0x548718],'userId':_0x116618,'type':_0x1f3a62}:_0x51f3ae[_0x1f3a62]&&!_0x284fe9?(_0x51f3ae[_0x1f3a62]['end']=_0x572d8e,_0x13c6ed(_0x51f3ae[_0x1f3a62]),_0x51f3ae[_0x1f3a62]=null):_0x51f3ae[_0x1f3a62]&&_0x284fe9&&_0x51f3ae[_0x1f3a62]['userId']!==_0x116618&&(_0x51f3ae[_0x1f3a62]['end']=_0x572d8e,_0x16f321&&_0x16f321['userId']===_0x51f3ae[_0x1f3a62]['userId']||_0x13c6ed(_0x51f3ae[_0x1f3a62]),_0x51f3ae[_0x1f3a62]={'start':_0x572d8e,'tapeItem':_0x2bd10b[_0x548718],'userId':_0x116618,'type':_0x1f3a62}),_0x51f3ae[_0x1f3a62]&&_0x1798ea&&('elementStart'!==_0x2bd10b[_0x548718]['type']||_0x16f321&&_0x16f321['userId']===_0x116618||_0x2f8845[_0x1f3a62]['unshift']({'userId':_0x116618,'object':_0x2bd10b[_0x548718]['item'],'change':_0x51f3ae[_0x1f3a62]}),'elementEnd'===_0x2bd10b[_0x548718]['type']&&_0x16f321&&_0x16f321['object']===_0x2bd10b[_0x548718]['item']&&(_0x2f8845[_0x1f3a62]['shift'](),_0x51f3ae[_0x1f3a62]=_0x16f321['change'])),_0x51f3ae[_0x1f3a62]&&_0x5cdaaf&&(_0x51f3ae[_0x1f3a62]['end']=_0x1b8455,_0x13c6ed(_0x51f3ae[_0x1f3a62]),_0x51f3ae[_0x1f3a62]=null);}function _0x13c6ed({start:_0x1d5a90,end:_0x31d7be,tapeItem:_0x13b560,userId:_0x482b24,type:_0x2481ce}){const _0xc63c60=_0x13b560['item'],_0x17bf9c=_0x43138c['schema']['isBlock'](_0xc63c60)&&!_0x43138c['schema']['isLimit'](_0xc63c60),_0xf6a720=_0x1d5a90['nodeAfter']==_0x31d7be['parent']&&_0x31d7be['isAtStart'];if(_0x17bf9c&&_0xf6a720)return;const _0xa605ed=_0x43138c['createRange'](_0x1d5a90,_0x31d7be),_0x55fb3c=_0x2f3838['get'](_0x482b24),_0x1ed7f5=new r({'author':_0x55fb3c,'type':'isAdded'==_0x2481ce||'isAddSuggestion'==_0x2481ce?'add':'remove','data':{'isSuggestion':'isAddSuggestion'==_0x2481ce||'isRemoveSuggestion'==_0x2481ce},'createdAt':new Date(),'rootName':_0x78bb86});_0x1c2ed4['push'](_0x1ed7f5),_0x6d89ea['markers']['set']('revision:'+_0x1ed7f5['id'],_0xa605ed);}function _0xdd137b(_0x196330,_0x16a414){const _0x374fb9=_0x196330['getAttributes'](),_0x2d3d64=_0x16a414['getAttributes']();for(const _0x3cb3dc of _0x374fb9){if(_0x3cb3dc[0x1]!==_0x16a414['getAttribute'](_0x3cb3dc[0x0]))return!0x1;_0x2d3d64['next']();}return _0x2d3d64['next']()['done'];}}['_setConversion'](){this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision','view':_0x59970e=>{const _0x52bddb=_0x59970e['markerName']['split'](':')[0x1],_0x5e13f7=this['_getChangeFromId'](_0x52bddb);if(!_0x5e13f7)return null;const _0x5debda='add'==_0x5e13f7['type']?'insertion':'deletion',_0x3a579c=['ck-suggestion-marker','ck-suggestion-marker-'+_0x5debda];return _0x5e13f7['data']['isSuggestion']&&_0x3a579c['push']('ck-suggestion-marker-'+_0x5debda+'-new'),this['activeChange']==_0x5e13f7&&_0x3a579c['push']('ck-suggestion-marker--active'),{'classes':_0x3a579c,'attributes':{'data-change-id':_0x52bddb}};}}),this['editor']['conversion']['for']('upcast')['add'](_0x140284=>{_0x140284['on']('element:pre',(_0x4bc49b,_0x468352,_0x37d10b)=>{const _0x118dd7=_0x468352['viewItem']['getChild'](0x0);if(!_0x118dd7||!_0x118dd7['is']('element','code'))return;if(!_0x37d10b['consumable']['consume'](_0x118dd7,{'attributes':['vid_start','vid_end']}))return;const _0x1beba2=_0x468352['modelRange']['start']['nodeAfter'];_0x37d10b['writer']['setAttribute']('vid_start',_0x118dd7['getAttribute']('vid_start'),_0x1beba2),_0x37d10b['writer']['setAttribute']('vid_end',_0x118dd7['getAttribute']('vid_end'),_0x1beba2);},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['add'](_0x8df8a2=>{_0x8df8a2['on']('element',(_0x5658f3,_0x390762,_0x5a2d77)=>{if(!_0x5a2d77['consumable']['consume'](_0x390762['viewItem'],{'attributes':['vid_start','vid_end']}))return;if(_0x390762['modelRange']['isCollapsed'])return;const _0x4c936a=_0x390762['modelRange']['start']['nodeAfter'];_0x4c936a['hasAttribute']('vid_start')||_0x4c936a['hasAttribute']('vid')||(_0x5a2d77['writer']['setAttribute']('vid_start',_0x390762['viewItem']['getAttribute']('vid_start'),_0x4c936a),_0x5a2d77['writer']['setAttribute']('vid_end',_0x390762['viewItem']['getAttribute']('vid_end'),_0x4c936a));},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['elementToAttribute']({'view':{'name':'span','attributes':{'vid':!0x0}},'model':{'key':'vid','value':_0x2fc5a4=>_0x2fc5a4['getAttribute']('vid')}}),this['editor']['model']['schema']['on']('checkAttribute',(_0x5e34fb,[,_0x4e91cf])=>{['vid_start','vid_end','vid']['includes'](_0x4e91cf)&&(_0x5e34fb['return']=!0x0,_0x5e34fb['stop']());},{'priority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x25eded=>{_0x25eded['on']('attribute:vid',(_0x50cfac,_0x3b401f,_0x52df49)=>{if('\x20'!=_0x3b401f['item']['data']||_0x3b401f['item']['parent']['maxOffset']>0x1)return;if(!_0x52df49['consumable']['consume'](_0x3b401f['item'],_0x50cfac['name']))return;const _0x21aa52=_0x52df49['writer'],_0x4ad819=_0x52df49['mapper']['toViewRange'](_0x3b401f['range']);_0x21aa52['wrap'](_0x4ad819,_0x21aa52['createAttributeElement']('span'));});}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',function(_0x2d222c){const _0x5b840b=_0x2d222c['plugins']['get']('RevisionViewer');return(_0x245854,_0x4bbc99,_0x385245)=>{const _0x50bb87=_0x4bbc99['markerName']['split'](':')[0x1],_0x208359=_0x5b840b['_getChangeFromId'](_0x50bb87);if(!_0x208359)return null;const _0x5ec730='add'==_0x208359['type']?'split':'merge';if(!_0x385245['consumable']['test'](_0x4bbc99['markerRange'],_0x245854['name']))return;const _0xc3dd22=_0x4bbc99['markerRange']['getWalker'](),_0x18b513=_0x4bbc99['markerRange']['start'],_0x4bbe0e=_0x2d222c['model']['schema'];let _0x57ccf3=null,_0x2e50ee=null,_0x2cebc2=!0x1,_0x1ca540=!0x1;for(const _0x48ee2d of _0xc3dd22){const _0x1cc25e=_0x48ee2d['item'];_0x2cebc2=_0x2cebc2||_0x4bbe0e['isContent'](_0x1cc25e);const _0x5d370d=_0x385245['mapper']['toViewElement'](_0x1cc25e);if(_0x5d370d&&_0x5d370d['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x48ee2d['type']&&(_0x4bbe0e['isBlock'](_0x1cc25e)&&!_0x4bbe0e['isLimit'](_0x1cc25e)&&(_0x1cc25e['nextSibling']||_0x18b513['isAtEnd']?_0x57ccf3&&_0x57ccf3['parent']==_0x1cc25e||(_0x57ccf3=_0x1cc25e,_0xdbcbf1(_0x48ee2d['previousPosition']),_0x1ca540=!0x0):_0x2e50ee=_0x2e50ee||_0x48ee2d['previousPosition']));}function _0xdbcbf1(_0x2c3c92){const _0x5c2836=_0x385245['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x5ec730}),_0x4bac0c=_0x385245['mapper']['toViewPosition'](_0x2c3c92);_0x208359['data']['isSuggestion']&&_0x385245['writer']['addClass']('ck-suggestion-marker-'+_0x5ec730+'-new',_0x5c2836),_0x5b840b['activeChange']==_0x208359&&_0x385245['writer']['addClass']('ck-suggestion-marker--active',_0x5c2836),_0x385245['writer']['insert'](_0x4bac0c,_0x5c2836),_0x385245['mapper']['bindElementToMarker'](_0x5c2836,_0x4bbc99['markerName']);}_0x2cebc2||_0x1ca540||!_0x2e50ee||_0xdbcbf1(_0x2e50ee);};}(this['editor']),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision',(_0x2432f9,_0x2d80e9,_0x570706)=>{const _0x1ea61a=_0x570706['mapper']['markerNameToElements'](_0x2d80e9['markerName']);if(_0x1ea61a){for(const _0x1d2755 of _0x1ea61a)(_0x1d2755['hasClass']('ck-suggestion-marker-split')||_0x1d2755['hasClass']('ck-suggestion-marker-merge'))&&(_0x570706['mapper']['unbindElementFromMarkerName'](_0x1d2755,_0x2d80e9['markerName']),_0x570706['writer']['remove'](_0x1d2755));}},{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',(_0x38f0a1,_0x4f5050,_0x5c8c14)=>{const _0x5cd0fa=_0x4f5050['markerName']['split'](':')[0x1],_0x20b5c9=this['_getChangeFromId'](_0x5cd0fa);if(!_0x20b5c9)return null;const _0x5c93b2='add'==_0x20b5c9['type']?'split':'merge';if(_0x5c8c14['consumable']['test'](_0x4f5050['markerRange'],_0x38f0a1['name']))for(const _0x17e6a0 of _0x4f5050['markerRange']['getItems']()){if(!_0x17e6a0['is']('element','softBreak'))continue;const _0x2db7dc=_0x5c8c14['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x5c93b2}),_0x14cfed=_0x5c8c14['mapper']['toViewPosition'](this['editor']['model']['createPositionBefore'](_0x17e6a0));_0x20b5c9['data']['isSuggestion']&&_0x5c8c14['writer']['addClass']('ck-suggestion-marker-'+_0x5c93b2+'-new',_0x2db7dc),this['activeChange']==_0x20b5c9&&_0x5c8c14['writer']['addClass']('ck-suggestion-marker--active',_0x2db7dc),_0x5c8c14['writer']['insert'](_0x14cfed,_0x2db7dc),_0x5c8c14['mapper']['bindElementToMarker'](_0x2db7dc,_0x4f5050['markerName']);}},{'priority':'high'}),this['editor']['model']['document']['on']('change',()=>{this['editor']['editing']['view']['change'](_0xca10cd=>{for(const _0x1405b9 of this['editor']['model']['document']['getRootNames']()){const _0x334fc1=this['editor']['model']['document']['getRoot'](_0x1405b9),_0x35d365=this['editor']['editing']['view']['document']['getRoot'](_0x1405b9);if(_0x35d365){const _0x56a540=_0x334fc1['getAttribute']('revisionHistoryAttachChange');if(_0xca10cd['removeAttribute']('data-change-id',_0x35d365),_0xca10cd['removeClass']('ck-revision-history-root-add',_0x35d365),_0xca10cd['removeClass']('ck-revision-history-root-remove',_0x35d365),_0xca10cd['removeClass']('ck-revision-history-root--active',_0x35d365),_0x56a540){const _0x2d185a=this['_getChangeFromId'](_0x56a540);if(!_0x2d185a)return null;_0xca10cd['setAttribute']('data-change-id',_0x56a540,_0x35d365),_0xca10cd['addClass']('ck-revision-history-root-'+_0x2d185a['type'],_0x35d365),this['activeChange']==_0x2d185a&&_0xca10cd['addClass']('ck-revision-history-root--active',_0x35d365);}}}});}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'comment','model':_0x3fce4f=>'revision-comment:'+_0x3fce4f,'converterPriority':'highest'}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'suggestion','model':_0x1784d7=>'revision-suggestion:'+_0x1784d7,'converterPriority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision-suggestion','view':_0x2623f4=>({'name':'suggestion:'+_0x2623f4,'group':'revision-suggestion'}),'converterPriority':'highest'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision-suggestion','view':_0xec1e48=>{const _0xc1c023=_0xec1e48['markerName']['split'](':')[0x1];return'insertion'!=_0xc1c023&&'deletion'!=_0xc1c023?null:{'classes':['ck-suggestion-preview-marker','ck-suggestion-preview-marker-'+_0xc1c023]};}}),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',(_0x27ae72,_0x4592aa,_0xa15a9d)=>{const _0x34bca4=_0xa15a9d['mapper']['markerNameToElements'](_0x4592aa['markerName']);if(_0x34bca4){for(const _0x488b0a of _0x34bca4)_0x488b0a['is']('uiElement')&&(_0xa15a9d['mapper']['unbindElementFromMarkerName'](_0x488b0a,_0x4592aa['markerName']),_0xa15a9d['writer']['remove'](_0x488b0a));}},{'priority':'high'});}['_getChangeFromId'](_0x5e140d){return this['_changeIdToChange']['get'](_0x5e140d);}['_getViewForChange'](_0x8af1bd){return this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=new Q(this['editor']['locale'],_0x8af1bd),this['_changeView'];}['_initInteractions'](){this['editor']['model']['document']['selection']['observeMarkers']('revision'),this['on']('change:activeView',(_0xb90226,_0x41c28f,_0x2dccbf,_0x4165d6)=>{_0x4165d6&&this['_balloon']['remove'](_0x4165d6),_0x2dccbf&&(this['_balloon']['add']({'view':_0x2dccbf,'stackId':'revisionHistoryLabel','position':{'target':()=>{const _0x3994a4=this['editor']['editing'],_0x488a9a=this['_getChangeFromId'](_0x2dccbf['changeId']);let _0x571d99;if(_0x488a9a['data']['isOnRoot']){const _0x16a78f=_0x3994a4['view']['getDomRoot'](_0x488a9a['rootName']);_0x571d99=Array['from'](_0x16a78f['getClientRects']());}else{const _0x2864c9=this['editor']['model']['markers']['get']('revision:'+_0x2dccbf['changeId']);_0x571d99=Array['from'](_0x3994a4['mapper']['markerNameToElements'](_0x2864c9['name']))['map'](_0x225703=>_0x3994a4['view']['domConverter']['mapViewToDom'](_0x225703))['map'](_0x5bb6f0=>Array['from'](_0x5bb6f0['getClientRects']()))['flat']();}if(!this['_activeViewTarget'])return _0x571d99[0x0];return _0x571d99['find'](_0xbd912a=>_0xbd912a['top']-0x3<=this['_activeViewTarget']['y']&&_0xbd912a['bottom']+0x3>=this['_activeViewTarget']['y']&&_0xbd912a['left']-0x3<=this['_activeViewTarget']['x']&&_0xbd912a['right']+0x3>=this['_activeViewTarget']['x'])||_0x571d99[0x0];}}}),this['_balloon']['showStack']('revisionHistoryLabel'));}),this['on']('change:activeChange',(_0x36840f,_0x41fa11,_0x4e66ce,_0x2beb9e)=>{this['activeView']=_0x4e66ce?this['_getViewForChange'](_0x4e66ce):null,this['editor']['model']['change'](()=>{const _0xf88a8=this['editor']['editing'];_0x2beb9e&&(_0x2beb9e['data']['isOnRoot']?_0xf88a8['view']['change'](_0x510100=>{_0x510100['removeClass']('ck-revision-history-root--active',_0xf88a8['view']['document']['getRoot'](_0x2beb9e['rootName']));}):_0xf88a8['reconvertMarker']('revision:'+_0x2beb9e['id'])),_0x4e66ce&&(_0x4e66ce['data']['isOnRoot']?_0xf88a8['view']['change'](_0x2f2fca=>{_0x2f2fca['addClass']('ck-revision-history-root--active',_0xf88a8['view']['document']['getRoot'](_0x4e66ce['rootName']));}):_0xf88a8['reconvertMarker']('revision:'+_0x4e66ce['id']));});}),this['listenTo'](this['editor']['editing']['view']['document'],'mouseover',(_0x2a8606,_0x179e3a)=>{if(this['activeChange'])return;const _0x211de1=this['_findChangeIdFromDomTarget'](_0x179e3a['target']),_0xd52585=this['_changeIdToChange']['get'](_0x211de1);_0xd52585?(this['_activeViewTarget']={'x':_0x179e3a['domEvent']['x'],'y':_0x179e3a['domEvent']['y']},this['activeView']=this['_getViewForChange'](_0xd52585)):(this['_activeViewTarget']=null,this['activeView']=null);}),this['listenTo'](this['editor']['editing']['view']['document'],'mousedown',(_0x4eb5c7,_0x1bb5fb)=>{const _0x31419e=this['_findChangeIdFromDomTarget'](_0x1bb5fb['target']),_0x4a13b9=this['_changeIdToChange']['get'](_0x31419e);_0x4a13b9?(this['_activeViewTarget']={'x':_0x1bb5fb['domEvent']['x'],'y':_0x1bb5fb['domEvent']['y']},_0x4a13b9===this['activeChange']?this['_balloon']['updatePosition']():this['activeChange']=_0x4a13b9):(this['_activeViewTarget']=null,this['activeChange']=null);});}['_findChangeIdFromDomTarget'](_0x5ab0ab){do{const _0x2bbe65=_0x5ab0ab['getAttribute']('data-change-id');if(_0x2bbe65)return _0x2bbe65;_0x5ab0ab=_0x5ab0ab['parent'];}while(_0x5ab0ab);return null;}['_cleanMarkers'](){this['editor']['model']['change'](_0x43e5a9=>{for(const _0x1abfbb of this['editor']['model']['markers'])_0x43e5a9['removeMarker'](_0x1abfbb);});}}function X(_0x23527e,_0x29bb6e){return(_0x1da8f7,_0x112a3e,_0x335126)=>{if(!_0x335126['consumable']['test'](_0x112a3e['markerRange'],_0x1da8f7['name']))return;const _0x26c633=_0x112a3e['markerRange']['getWalker'](),_0x28a2e9=_0x112a3e['markerRange']['start'],_0x51352f=_0x23527e['model']['schema'];let _0x2b40cb=null,_0x4ffaff=null,_0x490a45=!0x1,_0x1db828=!0x1;for(const _0x530201 of _0x26c633){const _0x482501=_0x530201['item'];_0x490a45=_0x490a45||_0x51352f['isContent'](_0x482501);const _0x489606=_0x335126['mapper']['toViewElement'](_0x482501);if(_0x489606&&_0x489606['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x530201['type']&&(_0x51352f['isBlock'](_0x482501)&&!_0x51352f['isLimit'](_0x482501)&&(_0x482501['nextSibling']||_0x28a2e9['isAtEnd']?_0x2b40cb&&_0x2b40cb['parent']==_0x482501||(_0x2b40cb=_0x482501,_0x117e71(_0x530201['previousPosition']),_0x1db828=!0x0):_0x4ffaff=_0x4ffaff||_0x530201['previousPosition']));}function _0x117e71(_0x5a3e5c){const _0x46dada=_0x335126['mapper']['toViewPosition'](_0x5a3e5c),_0xf947da=_0x335126['writer']['createUIElement']('span',{'class':'ck-suggestion-preview-marker-'+_0x29bb6e});_0x335126['writer']['insert'](_0x46dada,_0xf947da),_0x335126['mapper']['bindElementToMarker'](_0xf947da,_0x112a3e['markerName']);}_0x490a45||_0x1db828||!_0x4ffaff||_0x117e71(_0x4ffaff);};}class mt extends _0x4e2556{constructor(_0x2cf3b6){super(_0x2cf3b6);const _0x3e9158=_0x2cf3b6['plugins']['get'](m);this['affectsData']=!0x1,this['listenTo'](_0x3e9158,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x3e9158,'change:isEnabled',()=>this['refresh']());}['execute'](){const _0x4b93b3=this['editor'],_0x3880d4=_0x4b93b3['plugins']['get'](m),_0x380fba=_0x3880d4['isReady']?_0x3880d4['diff']['newRevisionId']:null;_0x4b93b3['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x380fba);}['refresh'](){const {isReady:_0x5c0806,isEnabled:_0x8df273,repository:_0x28ac1f,diff:_0x4f07e6}=this['editor']['plugins']['get'](m),_0x59c0fa=_0x4f07e6&&_0x28ac1f['getLaterVisibleRevision'](_0x4f07e6['newRevisionId']);this['isEnabled']=_0x5c0806&&_0x8df273&&Boolean(_0x59c0fa);}}class wt extends _0x4e2556{['_step'];constructor(_0x3e8252,{direction:_0xe4957b}){super(_0x3e8252);const _0x15f0b0=_0x3e8252['plugins']['get'](m);this['affectsData']=!0x1,this['_step']='forward'===_0xe4957b?0x1:-0x1,this['listenTo'](_0x15f0b0,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x15f0b0,'change:isEnabled',()=>this['refresh']()),this['listenTo'](_0x15f0b0,'change:activeChange',()=>this['refresh']());}['execute'](){const _0x507a8f=this['editor'],_0x231b01=_0x507a8f['plugins']['get'](m),{isNavigationMode:_0x8e4c6a,currentChangeNumber:_0x441864}=_0x231b01;let _0x3da299;if(_0x231b01['activeChange']=_0x8e4c6a?_0x231b01['diff']['changes']['get'](_0x441864+this['_step']):_0x231b01['diff']['changes']['first'],_0x231b01['activeChange']['data']['isOnRoot'])_0x3da299=_0x507a8f['editing']['view']['getDomRoot'](_0x231b01['activeChange']['rootName']);else{const _0x2c4bde=_0x507a8f['model']['markers']['get']('revision:'+_0x231b01['activeChange']['id']);_0x3da299=_0x56d34c(_0x507a8f['editing'],_0x2c4bde);}_0x5c8233({'target':_0x3da299,'viewportOffset':0x28});}['refresh'](){const {isNavigationMode:_0x48f58a,currentChangeNumber:_0x387bc5,numberOfChanges:_0xda8e19,isReady:_0x185f7b,isEnabled:_0x5a26b1}=this['editor']['plugins']['get'](m);this['isEnabled']=!!(_0x5a26b1&&_0x185f7b&&_0xda8e19)&&(!_0x48f58a||(0x1===this['_step']?_0x387bc5<_0xda8e19-0x1:_0x387bc5>0x0));}}class _i extends ts{constructor(_0x185c0e){super(_0x185c0e);const _0x36d848=this['bindTemplate'],_0x165414=new te(_0x185c0e),_0x2e3234=new te(_0x185c0e);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',(_0x1ab3c7,_0x5bd718)=>_0x1ab3c7&&_0x5bd718>0x0),this['bind']('_statusText')['to'](this,'isReady',this,'currentChangeNumber',this,'numberOfChanges',this,'isNavigationMode',(_0x30cd6e,_0xdb5d1a,_0x8a873b,_0x59caa4)=>{if(!_0x30cd6e)return g(_0x185c0e,'Loading...');if(!_0x8a873b)return g(_0x185c0e,'No\x20changes');const _0x4e0ada=g(_0x185c0e,'NUMBER_OF_CHANGES',_0x8a873b);return _0x59caa4?g(_0x185c0e,'X_OF_Y_CHANGES',[_0xdb5d1a+0x1,_0x8a873b]):_0x4e0ada;}),_0x165414['set']({'label':g(_0x185c0e,'Show\x20previous\x20change'),'tooltip':!0x0,'icon':_0x1dd0dd}),_0x2e3234['set']({'label':g(_0x185c0e,'Show\x20next\x20change'),'tooltip':!0x0,'icon':_0x2464b9}),_0x165414['bind']('isEnabled')['to'](this,'isBackwardNavigationEnabled'),_0x2e3234['bind']('isEnabled')['to'](this,'isForwardNavigationEnabled'),_0x165414['on']('execute',()=>this['fire']('execute','backward')),_0x2e3234['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',_0x36d848['if']('_isStatusLabelVisible','ck-hidden',_0xb94ab9=>!_0xb94ab9)]},'children':[{'text':_0x36d848['to']('isNavigationMode',_0x4d807a=>_0x4d807a?g(_0x185c0e,'EDIT_X_OF_Y_REVISIONS')+':\x20':g(_0x185c0e,'Total')+':\x20')}]},{'text':_0x36d848['to']('_statusText')}]},new _0x32da21(),{'tag':'div','attributes':{'class':['ck-revision-history-ui__changes-navigation__navigation']},'children':[_0x165414,_0x2e3234]}]});}}const le='ck-editor__editable__loading-overlay';class ge extends _0x1aaf30{static get['pluginName'](){return'RevisionViewerLoadingOverlay';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['show'](){const _0x2a79ee=this['editor']['editing']['view'];_0x2a79ee['change'](_0x4801bc=>{for(const _0x460236 of _0x2a79ee['document']['roots'])_0x4801bc['addClass'](le,_0x460236);});}['hide'](){const _0x3968d4=this['editor']['editing']['view'];_0x3968d4['change'](_0x1c0e0c=>{for(const _0x196b8a of _0x3968d4['document']['roots'])_0x1c0e0c['removeClass'](le,_0x196b8a);});}}class R extends _0x1aaf30{static get['pluginName'](){return'RevisionViewerUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[m,ge];}['init'](){const _0x4a77ef=this['editor'],_0x5ef176=_0x4a77ef['plugins']['get'](m),_0x4606da=_0x4a77ef['plugins']['get'](ge);_0x4a77ef['ui']['componentFactory']['add']('exitToEditing',_0x55ef76=>{const _0x3c7fd0=new te(_0x55ef76);return _0x3c7fd0['set']({'label':g(_0x55ef76,'Back\x20to\x20editing'),'icon':_0x5c9b99,'withText':!0x0,'tooltip':!0x0,'class':'ck-revision-history-ui__back-to-editing'}),this['listenTo'](_0x3c7fd0,'execute',()=>{_0x4a77ef['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}),_0x3c7fd0;}),_0x4a77ef['ui']['componentFactory']['add']('restoreRevision',_0x473232=>{const _0x4356bd=new te(_0x473232);return _0x4356bd['set']({'label':g(_0x473232,'Restore\x20this\x20revision'),'withText':!0x0,'tooltip':!0x0}),_0x4356bd['bind']('isEnabled')['to'](_0x4a77ef['commands']['get']('restoreRevision')),this['listenTo'](_0x4356bd,'execute',()=>_0x4a77ef['execute']('restoreRevision')),_0x4356bd;}),_0x4a77ef['ui']['componentFactory']['add']('changesNavigation',_0x2d6c44=>{const _0x2e645c=new _i(_0x2d6c44),_0x54dafa=_0x4a77ef['commands']['get']('showPreviousChange'),_0x198d2f=_0x4a77ef['commands']['get']('showNextChange');return _0x2e645c['bind']('isBackwardNavigationEnabled')['to'](_0x54dafa,'isEnabled'),_0x2e645c['bind']('isForwardNavigationEnabled')['to'](_0x198d2f,'isEnabled'),_0x2e645c['bind']('isReady','currentChangeNumber','numberOfChanges','isNavigationMode')['to'](_0x5ef176),this['listenTo'](_0x2e645c,'execute',(_0x2caa70,_0x569c45)=>{_0x4a77ef['execute']('forward'===_0x569c45?'showNextChange':'showPreviousChange');}),_0x2e645c;}),_0x4606da['show'](),_0x5ef176['on']('change:isReady',(_0x505125,_0x4f8666,_0x5166f0)=>{_0x5166f0?_0x4606da['hide']():_0x4606da['show']();});}}class at extends _0x21d0c2{['_resizeObserver']=null;constructor(_0x5e112f,_0x5c29ce){super(_0x5e112f,_0x5c29ce);const _0x1dc56a=this['bindTemplate'];this['set']({'label':g(_0x5e112f,'Revision\x20name'),'_tooltipString':''}),this['fieldView']['placeholder']=g(_0x5e112f,'Enter\x20the\x20revision\x20name'),this['extendTemplate']({'tag':'span','attributes':{'class':['ck-revision-history-sidebar__revision-name'],'data-cke-tooltip-text':_0x1dc56a['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 _0xb98629=this['fieldView']['element'];this['_tooltipString']=_0xb98629['scrollWidth']>_0xb98629['clientWidth']&&_0xb98629['value']||'';}}class si extends ts{constructor(_0x3e9072,_0x57e0a3,_0x6c7c89){super(_0x3e9072);const _0x4c84e8=new _0x5c83c3();_0x4c84e8['set']({'content':_0x3c4811,'viewBox':'0\x200\x2011\x2010'});const _0x5a5c5c=['ck','ck-revision-history-sidebar__revision-author'];_0x6c7c89&&_0x5a5c5c['push']('ck-revision-history-sidebar__revision-author_creator');const _0x5d1050=[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision-author__name'],'title':g(_0x3e9072,_0x6c7c89?'Revision\x20creator':'Revision\x20author')},'children':[_0x4c84e8,_0x57e0a3['name']]}];this['setTemplate']({'tag':'li','attributes':{'class':_0x5a5c5c},'children':_0x5d1050});}}function oi(_0x516a20,_0x5b7c37){const _0x171103=_0x516a20['bindTemplate'],_0x2b1fda=_0x516a20['locale'],_0x1b7a26=_0x3baa9b(_0x2b1fda);_0x1b7a26['panelPosition']='sw';const _0x445a72=function(_0x228694,_0x1b07d1){const _0x1d79ba=function(_0x488611,_0x139e63){const _0x1834aa=_0x488611['locale'],_0x54aa9c={'Compare\x20against\x20selected':g(_0x1834aa,'Compare\x20against\x20selected'),'Name\x20this\x20revision':g(_0x1834aa,'Name\x20this\x20revision'),'Restore\x20this\x20revision':g(_0x1834aa,'Restore\x20this\x20revision')};return _0x139e63['map'](_0x4b89e5=>{const _0x5bd130=_0x54aa9c[_0x4b89e5['name']];return _0x5bd130&&_0x5bd130!==_0x4b89e5['name']&&(_0x4b89e5['name']=_0x5bd130),_0x4b89e5;});}(_0x228694,_0x1b07d1),_0x3d1524=new _0x5f0faf();for(const _0x49fe37 of _0x1d79ba){const _0x5f52ea={'type':'button','model':new to({'label':_0x49fe37['name'],'class':_0x49fe37['class'],'withText':!0x0,'role':'menuitem','_action':_0x49fe37['action']})};_0x5f52ea['model']['bind']('isEnabled')['to'](_0x228694,'isActionsDropdownOpen',_0x55e741=>'function'!=typeof _0x49fe37['isEnabled']||(!_0x55e741||_0x49fe37['isEnabled'](_0x228694))),_0x3d1524['add'](_0x5f52ea);}return _0x3d1524;}(_0x516a20,_0x5b7c37);return _0x516a20['bind']('isActionsDropdownOpen')['to'](_0x1b7a26,'isOpen'),_0x1b7a26['buttonView']['set']({'label':g(_0x2b1fda,'Show\x20more\x20items'),'tooltip':!0x0,'tooltipPosition':'sw','icon':_0x45dd43}),_0x1b7a26['extendTemplate']({'attributes':{'class':['ck-revision-history-sidebar__revision__actions',_0x171103['if']('isActionsDropdownOpen','ck-on')]},'on':{'click':_0x171103['to'](_0x1cf960=>_0x1cf960['stopPropagation']())}}),_0x1b7a26['on']('execute',_0x257435=>{_0x516a20['isReady']&&'function'==typeof _0x257435['source']['_action']&&_0x257435['source']['_action'](_0x516a20);}),_0x11596f(_0x1b7a26,_0x445a72,{'role':'menu'}),_0x1b7a26['listenTo'](_0x516a20,'change:isActionsDropdownOpen',(_0x583077,_0x3ea725,_0xedd763)=>{if(_0xedd763)for(const _0x2649c0 of _0x1b7a26['listView']['items']){const _0x143dad=_0x2649c0['children']['first'],_0x44d063=_0x5b7c37['find'](_0x5c0cf6=>_0x5c0cf6['action']===_0x143dad['_action'])['isVisible'];_0x2649c0['isVisible']=void 0x0===_0x44d063||_0x44d063(_0x516a20);}}),_0x1b7a26;}class hi extends/* #__PURE__ -- @preserve */
26
- ti(ts){['id'];['revisionNameView'];['revisionActionsView'];['_revision'];['_requireRevisionName'];constructor(_0x5914f0,_0x46d5fa,_0x4c1777,_0x56b60f){super(_0x5914f0);const _0x1202de=this['bindTemplate'],_0x156d53=function(_0x74da23,_0x3855e4){const _0x516a15=Array['from'](_0x3855e4['authors'])['filter'](_0x38e63e=>_0x38e63e!=_0x3855e4['creator']);return _0x3855e4['creator']&&_0x516a15['unshift'](_0x3855e4['creator']),_0x516a15['map'](_0x445e93=>new si(_0x74da23,_0x445e93,_0x445e93==_0x3855e4['creator']));}(_0x5914f0,_0x46d5fa);this['id']=_0x46d5fa['id'],this['_revision']=_0x46d5fa,this['_requireRevisionName']=_0x56b60f,this['bind']('name','createdAt')['to'](_0x46d5fa),this['bind']('_createdAtFormatted')['to'](this,'createdAt',_0x41e878=>{return _0x23f422=_0x5914f0['uiLanguage'],(_0x595cc9=_0x41e878)['toLocaleDateString'](_0x23f422,{'month':'long','day':'numeric'})+',\x20'+_0x595cc9['toLocaleTimeString'](_0x23f422,{'hour':'numeric','minute':'numeric'});var _0x23f422,_0x595cc9;}),this['set']('isSelected',!0x1),this['set']('isHighlighted',!0x1),this['set']('isActionsDropdownOpen',!0x1),this['set']('isReady',!0x1),this['set']('isEnabled',!0x1),this['revisionNameView']=new at(_0x5914f0,_0x1a6c7a),this['revisionNameView']['fieldView']['extendTemplate']({'attributes':{'maxlength':'220'}}),this['revisionNameView']['fieldView']['bind']('value')['to'](this,'name',_0x4555f2=>_0x4555f2||this['_createdAtFormatted']),this['revisionNameView']['bind']('isEnabled')['to'](this,'isSelected',this,'isEnabled',(_0x5f431f,_0xf35c9d)=>_0x5f431f&&_0xf35c9d),this['revisionActionsView']=_0x4c1777&&_0x4c1777['length']?oi(this,_0x4c1777):'',this['revisionActionsView']&&this['revisionActionsView']['bind']('isEnabled')['to'](this),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision-wrapper',_0x1202de['if']('isConfirm','ck-revision-history-sidebar__revision-wrapper_confirmation_visible')]},'children':[{'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision',_0x1202de['if']('isEnabled','ck-disabled',_0x44b436=>!_0x44b436),_0x1202de['if']('isSelected','ck-revision-history-sidebar__revision_selected'),_0x1202de['if']('isHighlighted','ck-revision-history-sidebar__revision_highlighted'),_0x1202de['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':_0x1202de['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':_0x156d53}]},this['revisionActionsView']],'on':{'click':_0x1202de['to'](_0x195aa7=>{_0x195aa7['srcElement']['closest']('.ck-thread__remove-confirm')||this['isReady']&&this['isEnabled']&&this['fire']('select',{'id':this['id']});})}}]});}['render'](){super['render']();const _0x46b222=this['revisionNameView']['fieldView']['element'];this['listenTo'](_0x46b222,'change',()=>{this['_requireRevisionName']&&!_0x46b222['value']||this['fire']('setName',{'id':this['id'],'name':_0x46b222['value']}),_0x46b222['value']||(_0x46b222['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(_0x362a4b,_0x18f798){const _0x1619ab=_0x3c368c['fromJSDate'](_0x362a4b)['setLocale'](_0x18f798),_0x18580a=_0x3c368c['local'](),_0x9c024f=_0x18580a['minus']({'days':0x1})['startOf']('day');let _0x5b7d3b,_0x1c51f0;return _0x1619ab['hasSame'](_0x18580a,'day')?(_0x5b7d3b=_0x1619ab['startOf']('day')['toJSDate'](),_0x1c51f0=_0x1619ab['toRelativeCalendar']()):_0x1619ab['hasSame'](_0x9c024f,'day')?(_0x5b7d3b=_0x9c024f['toJSDate'](),_0x1c51f0=_0x1619ab['toRelativeCalendar']()):_0x1619ab['hasSame'](_0x18580a,'week')?(_0x5b7d3b=_0x1619ab['startOf']('week')['toJSDate'](),_0x1c51f0=_0x1619ab['weekdayLong']||''):_0x1619ab['hasSame'](_0x18580a,'year')?(_0x5b7d3b=_0x1619ab['startOf']('month')['toJSDate'](),_0x1c51f0=_0x1619ab['monthLong']||''):(_0x5b7d3b=_0x1619ab['startOf']('year')['toJSDate'](),_0x1c51f0=String(_0x1619ab['year'])),{'startDate':_0x5b7d3b,'localizedPeriodName':_0x1c51f0};}class di extends ts{['startDate'];['revisionViews'];['_revisionActions'];['_requireRevisionName'];constructor(_0x41bf9b,_0x94d0fa,_0x24d661,_0x5efbc0){super(_0x41bf9b);const _0x335e41=ai(_0x94d0fa,this['locale']['uiLanguage'])['localizedPeriodName'];this['startDate']=_0x94d0fa,this['revisionViews']=this['createCollection'](),this['_revisionActions']=_0x24d661,this['_requireRevisionName']=_0x5efbc0,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':_0x335e41}]},{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__time-period__revisions']},'children':this['revisionViews']}]});}['addRevision'](_0x433110){const _0x54f131=new hi(this['locale'],_0x433110,this['_revisionActions'],this['_requireRevisionName']);this['revisionViews']['add'](_0x54f131);}['removeRevision'](_0x2cd2ee){const _0x4c8acd=this['revisionViews']['find'](_0x2a164b=>_0x2a164b['id']===_0x2cd2ee['id']);this['revisionViews']['remove'](_0x4c8acd);}}class as extends ts{constructor(_0x53a4bf){super(_0x53a4bf);const _0x2b3827=new _0x5c83c3();_0x2b3827['content']=_0x2aae82,this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset_all','ck-revision-history-sidebar__header']},'children':[_0x2b3827,{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__header__label']},'children':[g(_0x53a4bf,'Revision\x20history')]}]});}}class ni extends ts{['timePeriodViews'];['_revisions'];['_revisionActions'];['_requireRevisionName'];constructor(_0x4f9c20,_0x5e9747,_0x8c5b8b,_0x282f9b){super(_0x4f9c20);const _0x517cd2=this['bindTemplate'];this['timePeriodViews']=this['createCollection'](),this['timePeriodViews']['delegate']('select')['to'](this),this['timePeriodViews']['delegate']('setName')['to'](this),this['_revisions']=_0x5e9747,this['_revisionActions']=_0x8c5b8b,this['_requireRevisionName']=_0x282f9b,this['on']('select',(_0x597762,_0x11be36)=>{this['fire']('revisionSelected',_0x11be36);}),this['on']('setName',(_0x22f856,_0x274d9d)=>{this['fire']('revisionSetName',_0x274d9d);}),this['set']('isEnabled',!0x1),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-rounded-corners','ck-revision-history-sidebar']},'children':[new as(_0x4f9c20),{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__timeline',_0x517cd2['if']('isEnabled','ck-disabled',_0x1f2fb0=>!_0x1f2fb0)]},'children':this['timePeriodViews']}]});}['render'](){super['render']();for(const _0x4904c7 of this['_revisions'])this['_addRevision'](_0x4904c7);this['_revisions']['on']('add',(_0x4eb560,_0x5354b5)=>{this['_addRevision'](_0x5354b5);}),this['_revisions']['on']('remove',(_0x4c082a,_0x43d8b6)=>{this['_removeRevision'](_0x43d8b6);});}get['revisionViews'](){return this['timePeriodViews']['map'](_0x4f08a7=>_0x4f08a7['revisionViews']['map'](_0x598382=>_0x598382))['flat']();}['selectRevision'](_0x4b7580){for(const _0x486dcd of this['revisionViews'])_0x4b7580&&_0x4b7580['id']===_0x486dcd['id']?_0x486dcd['select']():_0x486dcd['deselect']();}['highlightRevisions'](_0x45f93a){for(const _0x3bb45f of this['revisionViews'])_0x45f93a['some'](({id:_0x45ca67})=>_0x45ca67===_0x3bb45f['id'])?_0x3bb45f['highlight']():_0x3bb45f['unhighlight']();}['_addRevision'](_0xeb9bf4){const _0x32323e=ai(_0xeb9bf4['createdAt'],this['locale']['uiLanguage'])['startDate'];let _0x1d0937=this['timePeriodViews']['get'](0x0);_0x1d0937&&_0x1d0937['startDate']['getTime']()===_0x32323e['getTime']()||(_0x1d0937=new di(this['locale'],_0x32323e,this['_revisionActions'],this['_requireRevisionName']),this['timePeriodViews']['add'](_0x1d0937)),_0x1d0937['addRevision'](_0xeb9bf4);}['_removeRevision'](_0x25e8f2){const _0x10b90c=ai(_0x25e8f2['createdAt'],this['locale']['uiLanguage'])['startDate'];this['_getTimePeriodViewByStartDate'](_0x10b90c)['removeRevision'](_0x25e8f2);}['_getTimePeriodViewByStartDate'](_0x68bfcb){return this['timePeriodViews']['find'](_0x15f26f=>_0x15f26f['startDate']['getTime']()===_0x68bfcb['getTime']());}}class d extends _0x1aaf30{['_revisionViewer'];['_revisionsRepository'];['_sidebarView'];static ['defaultRevisionActions']=/* #__PURE__ -- @preserve */
23
+ import{ObservableMixin as _0x58c48e,uid as _0x488afd,Collection as _0x4419cc,logWarning as _0x31fe21,FocusTracker as _0x82470a,KeystrokeHandler as _0x35e91d,scrollViewportToShowTarget as _0x27def4,ResizeObserver as at,ElementReplacer as ot,CKEditorError as _0x1065a6}from'@ckeditor/ckeditor5-utils/dist/index.js';import{cloneDeep as _0x4631d1,set as _0x48f215,unset as _0xac9e88,isEqual as _0x244206}from'es-toolkit/compat';import{Plugin as _0x3f2981,PendingActions as _0x1b5502,Command as _0x206a38,ElementApiMixin as _0xf04e0d,Editor as _0x26f9dc}from'@ckeditor/ckeditor5-core/dist/index.js';import{Users as _0x2f8fb9,getMarkerDomElement as _0x3238b7,ConfirmMixin as _0x157757,sanitizeEditorConfig as _0x12d3c4}from'ckeditor5-collaboration/dist/index.js';import{ViewContainerElement as _0x4ed95e,ViewAttributeElement as _0x42afb0,ViewEmptyElement as _0x5e0b07,ViewRawElement as _0x3af5e8,ViewUIElement as _0x5a13dc,ViewDocumentFragment as _0xc287ed,ViewText as _0x4757dc,ViewElement as _0xf31048,Element as ut,Range as ft,Position as vt,DocumentFragment as gt,Text as mt}from'@ckeditor/ckeditor5-engine/dist/index.js';import{IconHistory as _0x184d1b,IconChevronUp as _0x351ec1,IconChevronDown as _0x182f02,IconUndo as te,IconUser as _0x3b361c,IconThreeVerticalDots as _0x38ab36}from'@ckeditor/ckeditor5-icons/dist/index.js';import{View as _0x1792c1,injectCssTransitionDisabler as ts,submitHandler as _0x44053f,LabeledFieldView as nt,createLabeledInputText as ti,createDropdown as _0x542f9c,ListView as _0x5142bf,ListItemView as _0x5acfd9,ButtonView as _0x1abc3e,MenuBarMenuView as _0x106d50,MenuBarMenuListView as _0x5c1d2b,MenuBarMenuListItemView as _0x1afdb1,MenuBarMenuListItemButtonView as _0x3eef0c,ContextualBalloon as _0x191e0,ToolbarSeparatorView as _0xea1f65,IconView as _0x184ac0,addListToDropdown as _0x1b9e98,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 _0x28e6bf}from'luxon';class h extends/* #__PURE__ -- @preserve */
24
+ _0x58c48e(){['id'];['creator'];['authors'];['diffData'];['toVersion'];['fromVersion'];['model'];constructor(_0x279e12){super(),this['id']=_0x279e12['id']||_0x488afd(),this['creator']=_0x279e12['creator']||null,this['authors']=_0x279e12['authors']||[],this['diffData']=_0x279e12['diffData']||null,this['toVersion']=_0x279e12['toVersion']||0x0,this['fromVersion']=_0x279e12['fromVersion']||0x0,this['set']('name',_0x279e12['name']||''),this['set']('createdAt',_0x279e12['createdAt']||new Date()),this['set']('attributes',_0x279e12['attributes']||{});}['setName'](_0x1bf047){this['_update']({'name':_0x1bf047});}['setAttribute'](_0x3a8f67,_0xd3175c){const _0xb2e790=_0x4631d1(this['attributes']);_0x48f215(_0xb2e790,_0x3a8f67,_0xd3175c),this['_update']({'attributes':_0xb2e790});}['removeAttribute'](_0x1a5a73){const _0x3682c8=_0x4631d1(this['attributes']);_0xac9e88(_0x3682c8,_0x1a5a73),this['_update']({'attributes':_0x3682c8});}['_update'](_0x22cc22,_0x5572be=!0x1){let _0xaceb8c=!0x1;const _0x17ea66={'id':this['id']},_0x47e1ac=['name','createdAt','diffData','authors','attributes','toVersion','fromVersion','creatorId'];for(const _0x297898 of _0x47e1ac){const _0x4a9de4=_0x22cc22[_0x297898];void 0x0!==_0x4a9de4&&_0x4a9de4!==this[_0x297898]&&(this[_0x297898]=_0x4a9de4,_0x17ea66[_0x297898]=_0x4a9de4,_0xaceb8c=!0x0);}_0xaceb8c&&(_0x17ea66['authors']&&(_0x17ea66['authorsIds']=_0x17ea66['authors']['map'](_0x1583b8=>_0x1583b8['id']),delete _0x17ea66['authors']),this['fire']('_update',_0x17ea66,_0x5572be));}['toJSON'](){return{'id':this['id'],'name':this['name'],'creatorId':this['creator']?this['creator']['id']:null,'authorsIds':this['authors']['map'](_0x59cdf7=>_0x59cdf7['id']),'diffData':this['diffData'],'createdAt':this['createdAt'],'attributes':this['attributes'],'fromVersion':this['fromVersion'],'toVersion':this['toVersion']};}}class I extends _0x3f2981{['_revisions'];static get['requires'](){return[_0x2f8fb9];}static get['pluginName'](){return'RevisionsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['length'](){return this['_revisions']['length'];}constructor(_0x540a37){super(_0x540a37),this['_revisions']=new _0x4419cc();}['afterInit'](){!async function(_0xb73076){const _0x27cd2f=_0x204fdb([0x42,0x41,0x35,0x56,0x5a,0x55,0x38,0x70,0x6d,0x36,0x4d,0x57,0x62,0x71,0x61,0x32,0x73,0x7a,0x64,0x6b,0x43,0x6c,0x78,0x58,0x46,0x30,0x51,0x48,0x49,0x74,0x52,0x31,0x67,0x54,0x6e,0x4a,0x44,0x37,0x69,0x4e,0x6f,0x75,0x6a,0x4f,0x47,0x33,0x63,0x68,0x77,0x66,0x65,0x59,0x39,0x4c,0x72,0x4b,0x34,0x76,0x45,0x79,0x53,0x50]),_0x4e5e0=0xeb829,_0x552a11=0x6ca2974b,_0x5d5452=0x6ca5f313^_0x552a11,_0x2c7e8d=window[_0x204fdb([0x44,0x61,0x74,0x65])][_0x204fdb([0x6e,0x6f,0x77])](),_0x244159=_0xb73076[_0x204fdb([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x341c72=new window[(_0x204fdb([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x5090f8=>{_0x244159[_0x204fdb([0x6f,0x6e,0x63,0x65])](_0x204fdb([0x72,0x65,0x61,0x64,0x79]),_0x5090f8);}),_0x4ed8d6={[_0x204fdb([0x6b,0x74,0x79])]:_0x204fdb([0x45,0x43]),[_0x204fdb([0x75,0x73,0x65])]:_0x204fdb([0x73,0x69,0x67]),[_0x204fdb([0x63,0x72,0x76])]:_0x204fdb([0x50,0x2d,0x32,0x35,0x36]),[_0x204fdb([0x78])]:_0x204fdb([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]),[_0x204fdb([0x79])]:_0x204fdb([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]),[_0x204fdb([0x61,0x6c,0x67])]:_0x204fdb([0x45,0x53,0x32,0x35,0x36])},_0x4e7295=_0x244159[_0x204fdb([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x204fdb([0x67,0x65,0x74])](_0x204fdb([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x467916(){let _0x481c83,_0x1af809=null,_0xd7f97d=null;try{if(_0x4e7295==_0x204fdb([0x47,0x50,0x4c]))return _0x204fdb([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x481c83=_0x468187(),!_0x481c83)return _0x204fdb([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x481c83[_0x204fdb([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0xd7f97d=_0x5e13df(_0x481c83[_0x204fdb([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x481c83[_0x204fdb([0x6a,0x74,0x69])])),await _0x14839a()?_0x36e8a1()?_0x4a0c51()?_0x204fdb([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x3365e4()?(_0x481c83[_0x204fdb([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x204fdb([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x1af809=_0x44e145(_0x204fdb([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x481c83[_0x204fdb([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x204fdb([0x74,0x72,0x69,0x61,0x6c])&&(_0x1af809=_0x44e145(_0x204fdb([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),await _0x2bc108()):_0x204fdb([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x204fdb([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x204fdb([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch(_0x201187){return _0x204fdb([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x4a0c51(){const _0x47270b=[_0x204fdb([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x204fdb([0x74,0x72,0x69,0x61,0x6c])][_0x204fdb([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x481c83[_0x204fdb([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x2c7e8d/0x3e8:0xe10*_0x5d5452;return _0x481c83[_0x204fdb([0x65,0x78,0x70])]<_0x47270b;}function _0x36e8a1(){const _0x5b0ca6=_0x481c83[_0x204fdb([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x5b0ca6)return!0x1;if(_0x5b0ca6[_0x204fdb([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x204fdb([0x2a])))return!0x0;if(_0x5b0ca6[_0x204fdb([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x204fdb([0x52,0x48])))return!0x0;if(_0x5b0ca6[_0x204fdb([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x204fdb([0x52,0x52,0x48]))){if(_0x44a92c())return!0x0;if(_0x477f68()||_0x2bea26())return!0x0;}return!0x1;}function _0x3365e4(){const _0x33dcda=_0x481c83[_0x204fdb([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x33dcda||0x0==_0x33dcda[_0x204fdb([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x377e47}=new URL(window[_0x204fdb([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x33dcda[_0x204fdb([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x377e47))return!0x0;const _0x2e1ce3=_0x377e47[_0x204fdb([0x73,0x70,0x6c,0x69,0x74])](_0x204fdb([0x2e]));return _0x33dcda[_0x204fdb([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x3ef22f=>_0x3ef22f[_0x204fdb([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x204fdb([0x2a])))[_0x204fdb([0x6d,0x61,0x70])](_0xe08448=>_0xe08448[_0x204fdb([0x73,0x70,0x6c,0x69,0x74])](_0x204fdb([0x2e])))[_0x204fdb([0x73,0x6f,0x6d,0x65])](_0x526b9a=>_0x2e1ce3[_0x204fdb([0x65,0x76,0x65,0x72,0x79])]((_0x44d197,_0x42ae5e)=>_0x526b9a[_0x42ae5e]===_0x44d197||_0x526b9a[_0x42ae5e]===_0x204fdb([0x2a])));}function _0x2bc108(){return _0x1af809&&_0xd7f97d?new window[(_0x204fdb([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x32b060,_0x3b7844)=>{_0x1af809[_0x204fdb([0x74,0x68,0x65,0x6e])](_0x32b060,_0x3b7844),_0xd7f97d[_0x204fdb([0x74,0x68,0x65,0x6e])](_0x1806d0=>{_0x1806d0!=_0x204fdb([0x56,0x61,0x6c,0x69,0x64])&&_0x32b060(_0x1806d0);},_0x3b7844);}):_0x1af809||_0xd7f97d||_0x204fdb([0x56,0x61,0x6c,0x69,0x64]);}}function _0x5e13df(_0xa035bf,_0x253b11){return new window[(_0x204fdb([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x2956b0=>{if(_0x553345())return _0x2956b0(_0x204fdb([0x56,0x61,0x6c,0x69,0x64]));_0x165604(),_0x244159[_0x204fdb([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x204fdb([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x20b495=!0x1;const _0x20c6e2=_0x488afd();function _0x5e6d5c(_0x452f53){return!!_0x452f53&&(typeof _0x452f53===_0x204fdb([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x452f53===_0x204fdb([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x452f53[_0x204fdb([0x74,0x68,0x65,0x6e])]===_0x204fdb([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x452f53[_0x204fdb([0x63,0x61,0x74,0x63,0x68])]===_0x204fdb([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x5a87de(_0x21521c){_0x345621(_0x21521c)[_0x204fdb([0x74,0x68,0x65,0x6e])](_0x4e2197=>{if(!_0x4e2197||_0x4e2197[_0x204fdb([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x204fdb([0x6f,0x6b]))return _0x204fdb([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x2adf62(_0x146f01(_0x20c6e2+_0x253b11))!=_0x4e2197[_0x204fdb([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x204fdb([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x204fdb([0x56,0x61,0x6c,0x69,0x64]);})[_0x204fdb([0x74,0x68,0x65,0x6e])](_0x4253b9=>(_0x5b493b(),_0x4253b9),()=>{const _0x5d56d0=_0x493582();return null==_0x5d56d0?(_0x5b493b(),_0x204fdb([0x56,0x61,0x6c,0x69,0x64])):_0x204fdb(_0x2c7e8d-_0x5d56d0>(0x48ae134b^_0x552a11)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x204fdb([0x74,0x68,0x65,0x6e])](_0x2956b0)[_0x204fdb([0x63,0x61,0x74,0x63,0x68])](()=>{_0x2956b0(_0x204fdb([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x331488=0x6c9479cb^_0x552a11;function _0x5b493b(){const _0x3f103c=_0x204fdb([0x6c,0x6c,0x63,0x74,0x2d])+_0x2adf62(_0x146f01(_0xa035bf)),_0x39e854=_0xd80031(_0x2adf62(window[_0x204fdb([0x4d,0x61,0x74,0x68])][_0x204fdb([0x63,0x65,0x69,0x6c])](_0x2c7e8d/_0x331488)));window[_0x204fdb([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x204fdb([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x3f103c,_0x39e854);}function _0x493582(){const _0x22760f=_0x204fdb([0x6c,0x6c,0x63,0x74,0x2d])+_0x2adf62(_0x146f01(_0xa035bf)),_0xa306f9=window[_0x204fdb([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x204fdb([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x22760f);return _0xa306f9?window[_0x204fdb([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0xd80031(_0xa306f9),0x10)*_0x331488:null;}function _0x345621(_0x18e128){return new window[(_0x204fdb([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x35f4d9,_0x4bfb18)=>{_0x18e128[_0x204fdb([0x74,0x68,0x65,0x6e])](_0x35f4d9,_0x4bfb18),window[_0x204fdb([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x4bfb18,0x6ca3438b^_0x552a11);});}}_0x244159[_0x204fdb([0x6f,0x6e])](_0x204fdb([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x3552a6,_0x5554f9)=>{if(_0x5554f9[0x0]!=_0xa035bf)return _0x2956b0(_0x204fdb([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x5554f9[0x1]={..._0x5554f9[0x1],[_0x204fdb([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x20c6e2};},{[_0x204fdb([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x204fdb([0x68,0x69,0x67,0x68])}),_0x244159[_0x204fdb([0x6f,0x6e])](_0x204fdb([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0xfe7f7e=>{_0x5e6d5c(_0xfe7f7e[_0x204fdb([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x20b495=!0x0,_0x5a87de(_0xfe7f7e[_0x204fdb([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x204fdb([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x204fdb([0x6c,0x6f,0x77])}),_0x341c72[_0x204fdb([0x74,0x68,0x65,0x6e])](()=>{_0x20b495||_0x2956b0(_0x204fdb([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x553345(){return _0x244159[_0x204fdb([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x204fdb([0x76,0x69,0x65,0x77])][_0x204fdb([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x204fdb([0x61,0x75,0x74,0x6f]);}function _0x165604(){_0x244159[_0x204fdb([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x204fdb([0x76,0x69,0x65,0x77])][_0x204fdb([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x204fdb([0x61,0x75,0x74,0x6f]);}}function _0x44e145(_0x22d9d3){const _0x91ff6=[new window[(_0x204fdb([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x172bb8=>setTimeout(_0x172bb8,0x6caba987^_0x552a11)),_0x341c72[_0x204fdb([0x74,0x68,0x65,0x6e])](()=>new window[(_0x204fdb([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x501f4b=>{const _0x3eb499=0x6ca2974c^_0x552a11,_0x1e3932=_0xb73076[_0x204fdb([0x5f,0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x73])];function _0x448239(){_0x1e3932[_0x204fdb([0x6c,0x65,0x6e,0x67,0x74,0x68])]>=_0x3eb499&&_0x501f4b();}_0x448239(),_0x1e3932[_0x204fdb([0x6f,0x6e])](_0x204fdb([0x61,0x64,0x64]),_0x448239);})),new window[(_0x204fdb([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0xada659=>{function _0x2b5b60(){for(const _0x19086a in window)if(window[_0x204fdb([0x4e,0x75,0x6d,0x62,0x65,0x72])]['isNaN'](window[_0x204fdb([0x4e,0x75,0x6d,0x62,0x65,0x72])](_0x19086a))&&window[_0x19086a]==_0x4e5e0)return _0xada659();_0x244159[_0x204fdb([0x73,0x74,0x61,0x74,0x65])]!=_0x204fdb([0x64,0x65,0x73,0x74,0x72,0x6f,0x79,0x65,0x64])&&window[_0x204fdb([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x2b5b60,0x6ca284c3^_0x552a11);}_0x1a7216(_0x204fdb([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))&&_0x2b5b60();})];return window[_0x204fdb([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x204fdb([0x72,0x61,0x63,0x65])](_0x91ff6)[_0x204fdb([0x74,0x68,0x65,0x6e])](()=>_0x22d9d3);}async function _0x12677d(){if(await _0x341c72,_0x1a7216(_0x204fdb([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))){const _0x20f5a1=_0xb73076[_0x204fdb([0x67,0x65,0x74,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](0x0),_0x19f131=_0xb73076[_0x204fdb([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])](_0x20f5a1[_0x204fdb([0x69,0x64])]),_0x109a44=_0x2c4cd9(_0x204fdb([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]));return await _0x109a44[_0x204fdb([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])](_0x20f5a1['id'],_0x19f131?_0x19f131['id']:null,!0x0),_0x109a44[_0x204fdb([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x204fdb([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x109a44[_0x204fdb([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x109a44[_0x204fdb([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])]=_0x5b5575,void(_0x109a44[_0x204fdb([0x5f,0x67,0x65,0x74,0x44,0x69,0x66,0x66])]=_0x5b5575);}if(_0x1a7216(_0x204fdb([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]))){const _0x32ef82=_0x2c4cd9(_0x204fdb([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]));_0x32ef82[_0x204fdb([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x204fdb([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x32ef82[_0x204fdb([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x32ef82[_0x204fdb([0x75,0x70,0x64,0x61,0x74,0x65])]=_0x5b5575,_0x32ef82[_0x204fdb([0x73,0x61,0x76,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])]=_0x5b5575;}_0x244159[_0x204fdb([0x6d,0x6f,0x64,0x65,0x6c])][_0x204fdb([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x5b5575,_0x244159[_0x204fdb([0x6d,0x6f,0x64,0x65,0x6c])][_0x204fdb([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x5b5575,_0x244159[_0x204fdb([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x204fdb([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x44a92c(){return _0x1a7216(_0x204fdb([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x2c4cd9(_0x204fdb([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x204fdb([0x73,0x74,0x61,0x74,0x65])]==_0x204fdb([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x477f68(){return _0x1a7216(_0x204fdb([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 _0x2bea26(){return _0x1a7216(_0x204fdb([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0x2b1a85(_0xa7b0d9){const _0x3300cb=_0x55dfaf();_0x244159[_0x3300cb]=_0x204fdb([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])+_0xa7b0d9,_0xa7b0d9[_0x204fdb([0x65,0x6e,0x64,0x73,0x57,0x69,0x74,0x68])](_0x204fdb([0x4c,0x69,0x6d,0x69,0x74]))&&(window[_0x55dfaf()]=_0x4e5e0),_0xa7b0d9!=_0x204fdb([0x56,0x61,0x6c,0x69,0x64])&&_0x12677d();}function _0x55dfaf(){const _0x1d438e=window[_0x204fdb([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x204fdb([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x204fdb([0x6e,0x6f,0x77])]())[_0x204fdb([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x204fdb([0x2e]),'');let _0x14cb00=_0x204fdb([0x42]);for(let _0x1ab91a=0x0;_0x1ab91a<_0x1d438e[_0x204fdb([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x1ab91a+=0x2){let _0x281dff=window[_0x204fdb([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x1d438e[_0x204fdb([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x1ab91a,_0x1ab91a+0x2));_0x281dff>=_0x27cd2f[_0x204fdb([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x281dff-=_0x27cd2f[_0x204fdb([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x14cb00+=_0x27cd2f[_0x281dff];}return _0x14cb00;}function _0x468187(){const _0x23b331=_0x4e7295[_0x204fdb([0x73,0x70,0x6c,0x69,0x74])](_0x204fdb([0x2e]));if(0x3!=_0x23b331[_0x204fdb([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x2e9941(_0x23b331[0x1]);function _0x2e9941(_0x3fe453){const _0x41f192=_0x1dd8ec(_0x3fe453);return _0x41f192&&_0x79d021()?_0x41f192:null;function _0x79d021(){const _0x210775=_0x41f192[_0x204fdb([0x6a,0x74,0x69])],_0x2a3820=window[_0x204fdb([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x210775[_0x204fdb([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x210775[_0x204fdb([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x1a6d7a={..._0x41f192,[_0x204fdb([0x6a,0x74,0x69])]:_0x210775[_0x204fdb([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x210775[_0x204fdb([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x1a6d7a[_0x204fdb([0x76,0x63])],_0x146f01(_0x1a6d7a)==_0x2a3820;}}}async function _0x14839a(){let _0x1744f9=!0x0;try{const _0x42504a=_0x4e7295[_0x204fdb([0x73,0x70,0x6c,0x69,0x74])](_0x204fdb([0x2e])),[_0x428d3d,_0x32a3d5,_0x55b94c]=_0x42504a;return _0x3c7288(_0x428d3d),await _0x28935e(_0x428d3d,_0x32a3d5,_0x55b94c),_0x1744f9;}catch(_0x2d5c26){return!0x1;}function _0x3c7288(_0x2433dd){const _0x63c80b=_0x1dd8ec(_0x2433dd);_0x63c80b&&_0x63c80b[_0x204fdb([0x61,0x6c,0x67])]==_0x204fdb([0x45,0x53,0x32,0x35,0x36])||(_0x1744f9=!0x1);}async function _0x28935e(_0xe8cc2b,_0x7ebcc2,_0x3beb03){const _0x16e807=window[_0x204fdb([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x204fdb([0x66,0x72,0x6f,0x6d])](_0x1d7b34(_0x3beb03),_0x566cd5=>_0x566cd5[_0x204fdb([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x214994=new window[(_0x204fdb([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x204fdb([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0xe8cc2b+_0x204fdb([0x2e])+_0x7ebcc2),_0x3b9f50=window[_0x204fdb([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x204fdb([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x3b9f50)return;const _0x276c0f=await _0x3b9f50[_0x204fdb([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x204fdb([0x6a,0x77,0x6b]),_0x4ed8d6,{[_0x204fdb([0x6e,0x61,0x6d,0x65])]:_0x204fdb([0x45,0x43,0x44,0x53,0x41]),[_0x204fdb([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x204fdb([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x204fdb([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x3b9f50[_0x204fdb([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x204fdb([0x6e,0x61,0x6d,0x65])]:_0x204fdb([0x45,0x43,0x44,0x53,0x41]),[_0x204fdb([0x68,0x61,0x73,0x68])]:{[_0x204fdb([0x6e,0x61,0x6d,0x65])]:_0x204fdb([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x276c0f,_0x16e807,_0x214994)||(_0x1744f9=!0x1);}}function _0x1dd8ec(_0x550374){return _0x550374[_0x204fdb([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x204fdb([0x65,0x79]))?JSON[_0x204fdb([0x70,0x61,0x72,0x73,0x65])](_0x1d7b34(_0x550374)):null;}function _0x1d7b34(_0x100579){return window[_0x204fdb([0x61,0x74,0x6f,0x62])](_0x100579[_0x204fdb([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x204fdb([0x2b]))[_0x204fdb([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x204fdb([0x2f])));}function _0x146f01(_0x3925ea){let _0x4af4ad=0x1505;function _0x19daf1(_0x1f1438){for(let _0x2f97f7=0x0;_0x2f97f7<_0x1f1438[_0x204fdb([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x2f97f7++){const _0x2e9186=_0x1f1438[_0x204fdb([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x2f97f7);_0x4af4ad=(_0x4af4ad<<0x5)+_0x4af4ad+_0x2e9186,_0x4af4ad&=_0x4af4ad;}}function _0x335a07(_0x19b29d){Array[_0x204fdb([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x19b29d)?_0x19b29d[_0x204fdb([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x335a07):_0x19b29d&&typeof _0x19b29d==_0x204fdb([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x204fdb([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x19b29d)[_0x204fdb([0x73,0x6f,0x72,0x74])]()[_0x204fdb([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x49c1d9,_0x1d6490])=>{_0x19daf1(_0x49c1d9),_0x335a07(_0x1d6490);}):_0x19daf1(window[_0x204fdb([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x19b29d));}return _0x335a07(_0x3925ea),_0x4af4ad>>>0x0;}function _0x2adf62(_0x2191c6){return _0x2191c6[_0x204fdb([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x204fdb([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x204fdb([0x30]));}function _0xd80031(_0xb12fee){return _0xb12fee[_0x204fdb([0x73,0x70,0x6c,0x69,0x74])]('')[_0x204fdb([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x204fdb([0x6a,0x6f,0x69,0x6e])]('');}function _0x1a7216(_0x364941){return _0x244159[_0x204fdb([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x204fdb([0x68,0x61,0x73])](_0x364941);}function _0x2c4cd9(_0x504e5d){return _0x244159[_0x204fdb([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x204fdb([0x67,0x65,0x74])](_0x504e5d);}function _0x5b5575(){}function _0x204fdb(_0x57b214){return _0x57b214['map'](_0x1a0ce9=>String['fromCharCode'](_0x1a0ce9))['join']('');}_0x2b1a85(await _0x467916());}(this);}['createRevision'](_0x4fc3d5){const _0x239d7e=this['editor']['plugins']['get']('Users');return new h({'id':_0x4fc3d5['id'],'name':_0x4fc3d5['name'],'creator':_0x4fc3d5['creatorId']?_0x239d7e['getUser'](_0x4fc3d5['creatorId']):null,'diffData':_0x4fc3d5['diffData']||_0x4fc3d5['data'],'authors':_0x4fc3d5['authorsIds']['map'](_0x10b9d9=>_0x239d7e['getUser'](_0x10b9d9)),'createdAt':new Date(_0x4fc3d5['createdAt']),'attributes':_0x4fc3d5['attributes'],'fromVersion':_0x4fc3d5['fromVersion'],'toVersion':_0x4fc3d5['toVersion']});}['addRevision'](_0x2c97e4,_0x501aed=0x0){this['_revisions']['add'](_0x2c97e4,_0x501aed);}['getRevision'](_0x59ddd6){return this['_revisions']['get'](_0x59ddd6);}['getRevisions'](_0xdfe86f={'toJSON':!0x1}){const _0x12f8f9=Array['from'](this['_revisions']);return _0x12f8f9['reverse'](),_0xdfe86f['toJSON']?_0x12f8f9['map'](_0x25ed89=>_0x25ed89['toJSON']()):_0x12f8f9;}['getIndex'](_0x2e7af9){return this['_revisions']['getIndex'](_0x2e7af9);}['getEarlierVisibleRevision'](_0x36d379){const [,_0x6ced66]=this['getRevisionsIterator'](_0x36d379,{'direction':'earlier'});return _0x6ced66;}['getLaterVisibleRevision'](_0x1e6ec8){const [,_0x47d2be]=this['getRevisionsIterator'](_0x1e6ec8,{'direction':'later'});return _0x47d2be;}['getRevisionsInDiff'](_0x40b58c){const _0x291c48=[];for(const _0x2966bf of this['getRevisionsIterator'](_0x40b58c['newRevisionId']))if(_0x291c48['push'](_0x2966bf),_0x2966bf['id']===_0x40b58c['oldRevisionId'])break;return _0x291c48;}*['getRevisionsIterator'](_0x7d144c,{direction:_0x13f178='earlier',filter:_0x27e5d5=()=>!0x0}={}){const _0x4c2f89='earlier'===_0x13f178?0x1:-0x1;let _0x4844fd=this['_revisions']['get'](_0x7d144c),_0x3f6329=this['getIndex'](_0x4844fd);for(yield _0x4844fd;_0x4844fd;){if(_0x3f6329+=_0x4c2f89,_0x4844fd=this['getRevision'](_0x3f6329),!_0x4844fd)return;_0x27e5d5(_0x4844fd)&&(yield _0x4844fd);}}}class V extends _0x3f2981{static get['pluginName'](){return'RevisionHistoryUtils';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['_viewClassToTypeChar']=new Map([[_0x4ed95e,'c'],[_0x42afb0,'a'],[_0x5e0b07,'e'],[_0x3af5e8,'r'],[_0x5a13dc,'u']]);['_typeCharToViewClass']=new Map([['c',_0x4ed95e],['a',_0x42afb0],['e',_0x5e0b07],['r',_0x3af5e8],['u',_0x5a13dc]]);async['loadRevisionData'](_0x4746e8,_0x4d11a6){if(_0x4746e8['diffData']||!_0x4d11a6)return;const _0x4462a5=this['editor']['config']['get']('collaboration.channelId'),_0x404a28=await _0x4d11a6['getRevision']({'channelId':_0x4462a5,'revisionId':_0x4746e8['id']});_0x4746e8['diffData']=_0x404a28['diffData'];}['getRevisionDocumentData'](_0x3bbc48){const _0x4deaa9={};for(const _0xfc5e32 in _0x3bbc48['diffData']){if(_0x3bbc48['diffData'][_0xfc5e32]['attachChange']&&!_0x3bbc48['diffData'][_0xfc5e32]['attachChange']['isAttached'])continue;const _0x1ccc2e=this['_removeRevisionMarkers'](JSON['parse'](_0x3bbc48['diffData'][_0xfc5e32]['insertions'])),_0x1f0cd5=this['editor']['editing']['view']['document'],_0x49f14f=new _0xc287ed(_0x1f0cd5,_0x1ccc2e['map'](_0x1a4247=>this['_getViewFromDiffObj'](_0x1a4247,!0x1)));this['editor']['data']['processor']['useFillerType']('marked'),_0x4deaa9[_0xfc5e32]=this['editor']['data']['processor']['toData'](_0x49f14f),this['editor']['data']['processor']['useFillerType']('default');}return _0x4deaa9;}['getRevisionRootsAttributes'](_0x3f7e61){const _0x3ecf74={};for(const _0x4bcfc1 in _0x3f7e61['diffData'])_0x3f7e61['diffData'][_0x4bcfc1]['attachChange']&&!_0x3f7e61['diffData'][_0x4bcfc1]['attachChange']['isAttached']||(_0x3ecf74[_0x4bcfc1]=_0x3f7e61['diffData'][_0x4bcfc1]['attributesAfter']||{});return _0x3ecf74;}['_getTypeCharForViewElement'](_0x45b7e4){return this['_viewClassToTypeChar']['get'](_0x45b7e4['constructor']);}['_getViewFromDiffObj'](_0x14d507,_0x2aff8d){const _0x5f4733=this['editor']['editing']['view']['document'];if('string'==typeof _0x14d507)return new _0x4757dc(_0x5f4733,_0x14d507);{let _0x54d35a,_0x32abc3;_0x32abc3='u'==_0x14d507['type']||'r'==_0x14d507['type']?[]:_0x14d507['children']['map'](_0x20a2bf=>this['_getViewFromDiffObj'](_0x20a2bf,_0x2aff8d));const _0x66aad0=this['_typeCharToViewClass']['get'](_0x14d507['type'])||_0xf31048,_0x106779=this['editor']['data']['htmlProcessor']['domConverter'];if(_0x54d35a=new _0x66aad0(_0x5f4733,_0x14d507['name'],_0x14d507['attributes'],_0x32abc3),'u'==_0x14d507['type']&&_0x14d507['children'][0x0]){const _0xdcd2c4=_0x14d507['children'][0x0];if(_0x54d35a['render']=function(_0x24a2c4){const _0x1c9eff=_0x24a2c4['createElement']('div');return _0x1c9eff['innerHTML']=_0xdcd2c4,_0x1c9eff['childNodes'][0x0];},_0x2aff8d){const _0x70edc1=new _0xc287ed(_0x5f4733);_0x70edc1['_appendChild'](_0x54d35a);const _0x2c7fd3=Array['from'](_0x106779['viewChildrenToDom'](_0x70edc1,{'bind':!0x1})),_0x57975d=_0x106779['domDocument']['createElement']('div');_0x57975d['append'](..._0x2c7fd3),_0x54d35a=Array['from'](_0x106779['domChildrenToView'](_0x57975d))[0x0];}}else{if('r'==_0x14d507['type']&&_0x14d507['children'][0x0]){const _0x473150=_0x14d507['children'][0x0];if(_0x54d35a['render']=function(_0x3db87b){_0x3db87b['innerHTML']=_0x473150;},_0x2aff8d){const _0x3237dc=new _0xc287ed(_0x5f4733);_0x3237dc['_appendChild'](_0x54d35a);const _0x1f8daf=Array['from'](_0x106779['viewChildrenToDom'](_0x3237dc,{'bind':!0x1})),_0x2f4d32=_0x106779['domDocument']['createElement']('div');_0x2f4d32['append'](..._0x1f8daf);const _0x3ace1e=Array['from'](_0x106779['domChildrenToView'](_0x2f4d32));_0x3ace1e['length']>0x1?_0x54d35a['_appendChild'](_0x3ace1e):_0x54d35a=_0x3ace1e[0x0];}}}if(_0x14d507['customProperties']){for(const [_0x383fed,_0x47397d]of _0x14d507['customProperties'])_0x54d35a['_setCustomProperty'](_0x383fed,_0x47397d);}const _0xc6568c=void 0x0===_0x14d507['fillerOffset']?null:_0x14d507['fillerOffset'];return null!==_0xc6568c&&(_0x54d35a['getFillerOffset']=()=>_0xc6568c),_0x54d35a;}}['_makeModelFromViewString'](_0x54b0b0){const _0x573091=JSON['parse'](_0x54b0b0),_0x282659=this['editor']['editing']['view']['document'],_0x3731fa=new _0xc287ed(_0x282659,_0x573091['map'](_0x38becf=>this['_getViewFromDiffObj'](_0x38becf,!0x0)));return this['editor']['data']['toModel'](_0x3731fa);}['_removeRevisionMarkers'](_0x6bcc3d){return(_0x6bcc3d=_0x6bcc3d['filter'](_0x53441a=>!_0x53441a['name']||'revision-start'!==_0x53441a['name']&&'revision-end'!==_0x53441a['name']))['forEach'](_0x581196=>{'string'!=typeof _0x581196&&(_0x581196['children']=this['_removeRevisionMarkers'](_0x581196['children']),_0x581196['attributes']=_0x581196['attributes']['filter'](_0x386dce=>!_0x386dce[0x0]['startsWith']('data-revision-')));}),_0x6bcc3d;}}function g(_0x32ee4e,_0x311452,_0x258e3a){const t=_0x32ee4e['t'];switch(_0x311452){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'},_0x258e3a);case'X_OF_Y_CHANGES':return t({'string':'%0\x20of\x20%1','id':'X_OF_Y_CHANGES'},_0x258e3a);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 _0x3f2981{['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[_0x2f8fb9,I,V,_0x1b5502];}constructor(_0x35eea4){super(_0x35eea4),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 _0x99fec9=_0x488afd();this['_source']={'history':this['editor']['model']['document']['history'],'getLatestVersion':()=>Promise['resolve'](this['editor']['model']['document']['version']),'getCurrentRevisionId':()=>_0x99fec9},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 _0xf1bd7e=this['repository']['getRevision'](0x0),_0x40d268=_0xf1bd7e&&null===_0xf1bd7e['creator']?_0xf1bd7e:null;if(this['_continueCurrentRevision']=!!_0x40d268&&this['editor']['config']['get']('revisionHistory.resumeUnsavedRevision'),this['editor']['plugins']['has']('RealTimeCollaborationClient')){const _0x4b8c36=this['_source']['getCurrentRevisionId'](),_0x28a1c7=this['repository']['getRevision'](_0x4b8c36);if(_0x28a1c7)this['_startingVersion']=_0x28a1c7['fromVersion'],this['_continueCurrentRevision']=!0x1;else{const _0x193eb1=this['_source']['history']['_operations']['find'](_0x3728ac=>!_0x3728ac['_isInit']),_0xc52001=_0x193eb1?_0x193eb1['baseVersion']:this['_source']['history']['version'];_0xf1bd7e?(_0xf1bd7e['toVersion']<_0xc52001&&_0xf1bd7e['_update']({'toVersion':_0xc52001}),this['_continueCurrentRevision']?(this['_source']['getCurrentRevisionId']=()=>_0x40d268['id'],this['_startingVersion']=_0x40d268['fromVersion']):(this['_startingVersion']=_0xf1bd7e['toVersion'],this['_continueCurrentRevision']=!0x1)):(this['_startingVersion']=_0xc52001,this['_continueCurrentRevision']=!0x1);}}else _0x40d268&&(this['editor']['model']['document']['history']['version']=Math['max'](_0x40d268['toVersion'],this['editor']['model']['document']['history']['version']),_0x40d268['fromVersion']===_0x40d268['toVersion']?(0x0!==_0x40d268['fromVersion']&&(this['_source']['getCurrentRevisionId']=()=>_0x40d268['id']),this['_continueCurrentRevision']=!0x1):this['_continueCurrentRevision']&&(this['_source']['getCurrentRevisionId']=()=>_0x40d268['id'],this['_startingVersion']=_0x40d268['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',_0x2c5c14=>!_0x2c5c14),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x3c0492=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x2c46b5;for(const _0x4553df in _0x3c0492){const _0x59314b=_0x4553df,_0x4d3c20=_0x3c0492[_0x59314b];if('revisionHistoryLicenseKeyValid'==_0x4d3c20||'revisionHistoryLicenseKeyInvalid'==_0x4d3c20||'revisionHistoryLicenseKeyExpired'==_0x4d3c20||'revisionHistoryLicenseKeyDomainLimit'==_0x4d3c20||'revisionHistoryLicenseKeyNotAllowed'==_0x4d3c20||'revisionHistoryLicenseKeyEvaluationLimit'==_0x4d3c20||'revisionHistoryLicenseKeyTrialLimit'==_0x4d3c20||'revisionHistoryLicenseKeyUsageLimit'==_0x4d3c20){delete _0x3c0492[_0x59314b],_0x2c46b5=_0x4d3c20,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'revisionHistoryLicenseKeyInvalid'==_0x2c46b5&&_0x3c0492['_showLicenseError']('invalid'),'revisionHistoryLicenseKeyExpired'==_0x2c46b5&&_0x3c0492['_showLicenseError']('expired'),'revisionHistoryLicenseKeyDomainLimit'==_0x2c46b5&&_0x3c0492['_showLicenseError']('domainLimit'),'revisionHistoryLicenseKeyNotAllowed'==_0x2c46b5&&_0x3c0492['_showLicenseError']('featureNotAllowed','RevisionHistory'),'revisionHistoryLicenseKeyEvaluationLimit'==_0x2c46b5&&_0x3c0492['_showLicenseError']('evaluationLimit'),'revisionHistoryLicenseKeyTrialLimit'==_0x2c46b5&&_0x3c0492['_showLicenseError']('trialLimit'),'revisionHistoryLicenseKeyUsageLimit'==_0x2c46b5&&_0x3c0492['_showLicenseError']('usageLimit');},0x3e8);}async['afterInit'](){if(this['repository']['length']>0x0){const _0x5b8e26=this['repository']['getRevision'](0x0),_0x38b7ff=await this['getRevisionDocumentData'](_0x5b8e26),_0x1ce9bd=await this['getRevisionRootsAttributes'](_0x5b8e26);this['_replaceEditorDataWithRevisionData'](_0x38b7ff,_0x1ce9bd);}}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['setSource'](_0x4b6eca){this['_source']=_0x4b6eca;}async['update'](){const _0x4ce2da=await this['_source']['getLatestVersion']();if(_0x4ce2da>this['currentRevision']['toVersion']){await this['_loadState']();const _0x5eaff4=this['buildRevisionData']({'revision':this['currentRevision'],'to':_0x4ce2da});_0x5eaff4['authors']=_0x5eaff4['authorsIds']['map'](_0x280a73=>this['editor']['plugins']['get']('Users')['getUser'](_0x280a73)),this['currentRevision']['_update'](_0x5eaff4);}}async['saveRevision'](_0x598ab5={},_0x4490cd=null){const _0xab17cd=[];await this['_loadState'](),this['_continueCurrentRevision']=!0x1,_0x4490cd>this['currentRevision']['toVersion']&&(_0x4490cd=null),null===_0x4490cd&&(_0x4490cd=await this['_source']['getLatestVersion']());const _0x50cdaf=this['_getFromVersion'](_0x4490cd),_0x48fb16=this['buildRevisionData']({'from':_0x50cdaf,'to':_0x4490cd});if(this['currentRevision']['toVersion']<_0x4490cd){const _0x27c8f8=this['buildRevisionData']({'revision':this['currentRevision'],'from':_0x4490cd,'to':_0x4490cd});_0x27c8f8['authors']=[],_0x27c8f8['authorsIds']=[],_0x27c8f8['id']=this['currentRevision']['id'],this['currentRevision']['_update'](_0x27c8f8,!0x0),delete _0x27c8f8['authors'],_0xab17cd['push'](_0x27c8f8);}_0x598ab5['creatorId']=this['editor']['plugins']['get']('Users')['me']['id'],_0x598ab5['name']=_0x598ab5['name']||null,_0x598ab5['id']=_0x598ab5['id']||_0x488afd(),_0x598ab5={..._0x598ab5,..._0x48fb16};const _0x262cb7=this['addRevisionData'](_0x598ab5);_0xab17cd['push'](_0x598ab5);const _0x596b5d=this['repository']['getIndex'](_0x262cb7);if(0x0!==_0x596b5d){const _0x1b8288=this['repository']['getRevision'](_0x596b5d-0x1);if(_0x1b8288['fromVersion']!==_0x4490cd){const _0x304407=this['_revisionDataBuilder']['getData'](_0x4490cd,_0x1b8288['toVersion']),_0x51d1b3={'id':_0x1b8288['id'],'diffData':_0x304407['diffData'],'authorsIds':_0x304407['authorsIds'],'authors':_0x304407['authorsIds']['map'](_0x4a7a5b=>this['editor']['plugins']['get']('Users')['getUser'](_0x4a7a5b)),'fromVersion':_0x4490cd};_0x1b8288===this['currentRevision']&&(_0x51d1b3['createdAt']=new Date(_0x598ab5['createdAt']['getTime']()+0xa)),_0x1b8288['_update'](_0x51d1b3,!0x0),delete _0x51d1b3['authors'],_0xab17cd['push'](_0x51d1b3);}}if(this['adapter']){for(const _0x881168 of _0xab17cd)this['_bufferUpdate'](_0x881168['id'],_0x881168,!0x0);this['sendBufferedUpdates']();}return _0x262cb7;}['addRevisionData'](_0x542f06){const _0x1ddf38=this['repository']['createRevision'](_0x542f06);return this['adapter']&&_0x1ddf38['on']('_update',(_0x2b3cf6,_0x3dae63,_0x63f77a)=>{_0x63f77a||(this['_bufferUpdate'](_0x3dae63['id'],_0x3dae63,!0x0),this['sendBufferedUpdates']());}),this['repository']['addRevision'](_0x1ddf38,this['_findInsertionIndex'](_0x1ddf38)),_0x1ddf38;}async['getRevisionDocumentData'](_0x2dd7ed){return await this['_utils']['loadRevisionData'](_0x2dd7ed,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x2dd7ed);}async['getRevisionRootsAttributes'](_0x1041c4){return await this['_utils']['loadRevisionData'](_0x1041c4,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x1041c4);}['sendBufferedUpdates'](){if(0x0===this['_bufferedUpdates']['size'])return;if(this['_isPendingUpdate'])return;let _0x4eb1e0=Array['from'](this['_bufferedUpdates']['values']());this['_bufferedUpdates']['clear']();for(let _0x4b32c3=0x0;_0x4b32c3<_0x4eb1e0['length'];_0x4b32c3++){const _0x885dc2=_0x4eb1e0[_0x4b32c3];let _0xafb69b=!0x1;for(const _0x2f75f8 of Object['keys'](_0x885dc2))void 0x0===_0x885dc2[_0x2f75f8]?delete _0x885dc2[_0x2f75f8]:'id'!==_0x2f75f8&&(_0xafb69b=!0x0);_0xafb69b||(_0x4eb1e0[_0x4b32c3]=null);}if(_0x4eb1e0=_0x4eb1e0['filter'](_0x7e00bc=>null!==_0x7e00bc),!_0x4eb1e0['length'])return;for(let _0x2d71f0=0x0;_0x2d71f0<_0x4eb1e0['length'];_0x2d71f0++){const _0xeb7deb=_0x4eb1e0[_0x2d71f0];void 0x0!==_0xeb7deb['fromVersion']&&void 0x0===_0xeb7deb['toVersion']&&(_0xeb7deb['toVersion']=this['repository']['getRevision'](_0xeb7deb['id'])['toVersion']),void 0x0!==_0xeb7deb['toVersion']&&void 0x0===_0xeb7deb['fromVersion']&&(_0xeb7deb['fromVersion']=this['repository']['getRevision'](_0xeb7deb['id'])['fromVersion']);}const _0x5ef6d9=this['editor']['config']['get']('collaboration.channelId');this['_isPendingUpdate']=!0x0,this['_addPendingAction'](),this['adapter']['updateRevisions'](_0x4eb1e0,_0x5ef6d9)['finally'](()=>{this['_isPendingUpdate']=!0x1;})['then'](_0x362c29=>{if(_0x362c29){for(const _0x11162a of _0x362c29)this['setRevisionData']({'id':_0x11162a['id'],'createdAt':_0x11162a['createdAt']});}this['_removePendingAction'](),this['sendBufferedUpdates']();});}['buildRevisionData']({revision:_0xc4264e=null,from:_0x64bf6f=null,to:_0x2c061c=null}){_0x64bf6f=null!==_0x64bf6f?_0x64bf6f:_0xc4264e['fromVersion'],_0x2c061c=null!==_0x2c061c?_0x2c061c:_0xc4264e['toVersion'];const _0x559f49=this['_revisionDataBuilder']['getData'](_0x64bf6f,_0x2c061c),_0x2cd559={'diffData':_0x559f49['diffData'],'authorsIds':_0x559f49['authorsIds'],'fromVersion':_0x64bf6f,'toVersion':_0x2c061c};if(!_0xc4264e||_0x2c061c!==_0xc4264e['toVersion']){const _0x3e0fad=_0x2c061c-0x1,_0x5a69e4=this['_source']['history']['getOperation'](_0x3e0fad);_0x2cd559['createdAt']=_0x5a69e4&&_0x5a69e4['createdAt']||new Date();}if(this['_loadedStateData']&&_0x64bf6f===this['_loadedStateData']['fromVersion']){for(const _0x2b2d46 of this['_loadedStateData']['authors'])_0x2cd559['authorsIds']['includes'](_0x2b2d46['id'])||_0x2cd559['authorsIds']['push'](_0x2b2d46['id']);}return _0x2cd559;}['_bufferUpdate'](_0x20c9d0,_0x3353b8,_0x3fc1e2){if(this['_bufferedUpdates']['has'](_0x20c9d0)){const _0x1572e9=this['_bufferedUpdates']['get'](_0x20c9d0);_0x3353b8=_0x3fc1e2?{..._0x1572e9,..._0x3353b8}:{..._0x3353b8,..._0x1572e9};}this['_bufferedUpdates']['set'](_0x20c9d0,_0x3353b8);}['setRevisionData'](_0x520ac8){const _0x758847=this['repository']['getRevision'](_0x520ac8['id']);if(_0x520ac8['createdAt']&&(_0x520ac8['createdAt']=new Date(_0x520ac8['createdAt'])),_0x520ac8['authorsIds']){const _0xaa13ea=this['editor']['plugins']['get']('Users');_0x520ac8['authors']=_0x520ac8['authorsIds']['map'](_0x2a6d0b=>_0xaa13ea['getUser'](_0x2a6d0b));}_0x758847['_update'](_0x520ac8,!0x0);}['_createInitialRevision'](_0x29b0c2){const _0x3eeea7=this['repository']['getRevision'](this['repository']['length']-0x1);if(_0x3eeea7)this['_initialRevisionId']=_0x3eeea7['id'];else{const _0x21c8f8=!this['editor']['model']['document']['roots']['find'](_0x5e49e4=>this['editor']['model']['hasContent'](_0x5e49e4)),_0x2792fe=this['editor']['plugins']['get']('Users')['me']['id'],_0x4789a3=g(this['editor']['locale'],_0x21c8f8?'Empty\x20document':'Initial\x20revision');this['_makeRevision']({'from':_0x29b0c2,'to':_0x29b0c2,'id':this['_initialRevisionId'],'name':_0x4789a3,'creatorId':_0x2792fe});}}['_createCurrentRevision'](_0xadaf47){const _0x515200=this['_source']['getCurrentRevisionId']();this['currentRevision']=this['repository']['getRevision'](_0x515200),this['currentRevision']||(this['currentRevision']=this['_makeRevision']({'from':_0xadaf47,'to':_0xadaf47,'id':_0x515200,'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'](_0x4916c3,_0x278a6e){let _0x10e1e7=this['editor']['config']['get']('initialData'),_0x587e9b=this['editor']['config']['get']('rootsAttributes');if(void 0x0===_0x10e1e7){_0x10e1e7={};for(const _0x5dcc96 of this['editor']['model']['document']['getRootNames']())_0x10e1e7[_0x5dcc96]='';}if('string'==typeof _0x10e1e7&&(_0x10e1e7={'main':_0x10e1e7}),void 0x0===_0x587e9b){_0x587e9b={};for(const _0x59a124 of this['editor']['model']['document']['getRootNames']())_0x587e9b[_0x59a124]={};}let _0x1cf69e=!0x1;const _0x5a7e03=Object['keys'](_0x10e1e7),_0x2823de=Object['keys'](_0x4916c3);for(const _0x1643dd of _0x5a7e03){if(_0x10e1e7[_0x1643dd]!==_0x4916c3[_0x1643dd]&&''!==_0x10e1e7[_0x1643dd]['trim']()){_0x1cf69e=!0x0;break;}if(!_0x244206(_0x587e9b[_0x1643dd],_0x278a6e[_0x1643dd])&&Object['keys'](_0x587e9b[_0x1643dd])['length']>0x0){_0x1cf69e=!0x0;break;}}_0x1cf69e||(_0x1cf69e=_0x2823de['some'](_0x34b60f=>!this['editor']['model']['document']['getRoot'](_0x34b60f))),_0x1cf69e&&_0x31fe21('editor-initial-data-replaced-with-revision-data',{'editorData':_0x10e1e7,'editorRootsAttributes':_0x587e9b,'revisionData':_0x4916c3,'revisionRootsAttributes':_0x278a6e}),this['editor']['config']['set']('initialData',_0x4916c3),this['editor']['config']['set']('rootsAttributes',_0x278a6e);}['_addPendingAction'](){if(!this['_pendingAction']){const _0x102916=this['editor']['plugins']['get']('PendingActions');this['_pendingAction']=_0x102916['add'](g(this['editor']['locale'],'PENDING_ACTION_REVISION_HISTORY'));}}['_removePendingAction'](){this['_pendingAction']&&(this['editor']['plugins']['get']('PendingActions')['remove'](this['_pendingAction']),this['_pendingAction']=null);}['_findInsertionIndex'](_0x48d516){const _0x5a3707=this['repository']['getRevisions']();_0x5a3707['reverse']();let _0x2d49eb=0x0;for(;_0x2d49eb<_0x5a3707['length'];){const _0xb43c3=_0x5a3707[_0x2d49eb];if(_0xb43c3===this['currentRevision']){_0x2d49eb++;continue;}if(_0xb43c3['id']===this['_initialRevisionId'])break;const _0x28ad6c=_0x48d516['toVersion']-_0xb43c3['toVersion']||_0x48d516['fromVersion']-_0xb43c3['fromVersion'];if(_0x28ad6c>0x0)break;if(_0x28ad6c<0x0)_0x2d49eb++;else{if(!_0x48d516['creator']&&_0xb43c3['creator'])break;if(_0xb43c3['creator']||!_0x48d516['creator']){if(_0x48d516['createdAt']>_0xb43c3['createdAt'])break;_0x2d49eb++;}else _0x2d49eb++;}}return _0x2d49eb;}['_getFromVersion'](_0x4e189c){const _0x3aca5b=this['repository']['getRevisions']();_0x3aca5b['reverse'](),_0x3aca5b['shift']();const _0x49ae52=_0x3aca5b['find'](_0x191049=>_0x191049['toVersion']<=_0x4e189c)['toVersion'];return _0x49ae52<this['_startingVersion']?this['_startingVersion']:_0x49ae52;}['_makeRevision']({name:_0x3b353f,from:_0x271912,to:_0x5b826d,creatorId:_0x3413f7,id:_0x1450cb}){const _0x4298a5=this['buildRevisionData']({'from':_0x271912,'to':_0x5b826d});_0x4298a5['name']=_0x3b353f,_0x4298a5['creatorId']=_0x3413f7,_0x4298a5['id']=_0x1450cb;const _0x380d12=this['addRevisionData'](_0x4298a5);return this['adapter']&&this['_bufferUpdate'](_0x4298a5['id'],_0x4298a5,!0x0),_0x380d12;}['_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(_0x1c3b70){this['editor']=_0x1c3b70,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'](_0x405150){this['source']=_0x405150;const _0x535131=new Map(),_0x3e1bce=new Map(),_0x5b307a=this['editor']['model']['document']['roots']['map'](_0x1fc407=>_0x1fc407['rootName']);for(const _0x23c5b2 of _0x5b307a){const _0x26cabb=this['editor']['model']['document']['getRoot'](_0x23c5b2),_0x53f0b2=N(_0x26cabb);_0x535131['set'](_0x23c5b2,_0x53f0b2),_0x3e1bce['set'](_0x23c5b2,Object['fromEntries'](_0x26cabb['getAttributes']()));}const _0x44749a=Array['from'](this['editor']['model']['markers'])['map'](_0x279910=>[_0x279910['name'],_0x279910['getRange']()]),_0xf3daee=this['source']['version'];this['_saveMetaData'](_0xf3daee,_0x535131,_0x44749a,_0x3e1bce),this['_startingRevisionId']=this['_revisionId'];const _0x162c51=new Map(),_0x36788d=new Map();for(const _0x2b7a8e of _0x5b307a){const _0x1f6e05=P(_0x2b7a8e);_0x162c51['set'](_0x2b7a8e,_0x1f6e05),_0x36788d['set'](_0x2b7a8e,{});}this['_saveMetaData'](Number['NEGATIVE_INFINITY'],_0x162c51,[],_0x36788d);}['getData'](_0x2cbe30,_0x108cc7){if(this['_lastFrom']===_0x2cbe30&&this['_lastTo']<=_0x108cc7)this['_savedMetaData']['size']>0x1&&this['_removeMetaData'](this['_lastTo']),this['_applyOperations'](this['_lastTo'],_0x108cc7,!0x0);else{if(!this['_savedMetaData']['has'](_0x2cbe30)){const _0x4292ef=this['_getPreviousFrom'](_0x2cbe30);this['_calculateMetaData'](_0x4292ef,_0x2cbe30,!0x1);}this['_calculateMetaData'](_0x2cbe30,_0x108cc7,!0x0);}return this['_lastFrom']=_0x2cbe30,this['_lastTo']=_0x108cc7,this['_getState']();}['loadState'](_0x4f362e){const _0x58b483=this['editor']['plugins']['get']('RevisionHistoryUtils');this['_reset'](),this['_lastFrom']=_0x4f362e['fromVersion'],this['_lastTo']=_0x4f362e['toVersion'];for(const _0xa69d9c in _0x4f362e['diffData']){const _0x3f7a90=_0x4f362e['diffData'][_0xa69d9c]['attachChange'],_0x13c66f=_0x4631d1(_0x4f362e['diffData'][_0xa69d9c]['attributesBefore'])||{},_0x39244e=_0x58b483['_makeModelFromViewString'](_0x4f362e['diffData'][_0xa69d9c]['deletions']);_0x39244e['rootName']=_0xa69d9c,_0x39244e['_isAttached']=!_0x3f7a90||!_0x3f7a90['isAttached'],_0x39244e['isAttached']=()=>_0x39244e['_isAttached'],this['_baseRoots']['set'](_0xa69d9c,_0x39244e),this['_baseRootsAttributes']['set'](_0xa69d9c,_0x13c66f),_0x3f7a90&&this['_touchedRoots']['set'](_0xa69d9c,_0x3f7a90);const _0x4a318a=this['_makeIdsRoot'](_0x39244e);this['_baseIdsRoots']['set'](_0xa69d9c,_0x4a318a);for(const [_0x1d0410,_0x5f2a7a]of _0x39244e['markers']){if(!_0x1d0410['startsWith']('revision:'))continue;const _0x57fbd7=_0x1d0410['split'](':')[0x2];for(const _0x2c0a7f of _0x5f2a7a['getWalker']({'singleCharacters':!0x0})){const _0x3ae25b=this['_getVidAttributeName'](_0x2c0a7f),_0x2bdb4a='elementEnd'==_0x2c0a7f['type']?_0x2c0a7f['previousPosition']['path']['slice'](0x0,-0x1):_0x2c0a7f['previousPosition']['path'],_0x26e1d1=_0x4a318a['getNodeByPath'](_0x2bdb4a)['getAttribute'](_0x3ae25b);this['_touched']['set'](_0x26e1d1,{'userId':_0x57fbd7});}}}this['_startingRevisionId']=this['_revisionId'];const _0x1e3b46=[...Array(this['_revisionId'])['keys']()]['slice'](0x1)['filter'](_0xaebc4d=>!this['_touched']['has'](_0xaebc4d));let _0x55fce4=0x0;const _0x20cd30=new Map();for(const _0x4d74b0 in _0x4f362e['diffData']){const _0x239d6b=_0x4f362e['diffData'][_0x4d74b0]['attachChange'],_0x2c3940=_0x4631d1(_0x4f362e['diffData'][_0x4d74b0]['attributesAfter'])||{},_0x51f4ba=_0x58b483['_makeModelFromViewString'](_0x4f362e['diffData'][_0x4d74b0]['insertions']);_0x51f4ba['rootName']=_0x4d74b0,_0x51f4ba['_isAttached']=!_0x239d6b||_0x239d6b['isAttached'],_0x51f4ba['isAttached']=()=>_0x51f4ba['_isAttached'],this['_diffRoots']['set'](_0x4d74b0,_0x51f4ba),this['_diffRootsAttributes']['set'](_0x4d74b0,_0x2c3940);const _0x16f341=this['_makeIdsRoot'](_0x51f4ba,Number['NEGATIVE_INFINITY']);this['_idsRoots']['set'](_0x4d74b0,_0x16f341),_0x20cd30['set'](_0x4d74b0,_0x51f4ba['isAttached']()?_0x2c3940:{});for(const [_0x10356a,_0x3097de]of _0x51f4ba['markers']){if(!_0x10356a['startsWith']('revision:'))continue;const _0x45357f=_0x10356a['split'](':')[0x2];for(const _0x594717 of _0x3097de['getWalker']({'singleCharacters':!0x0})){const _0x11d929=this['_getVidAttributeName'](_0x594717),_0x5221b4=this['_revisionId']++,_0x37aa60='elementEnd'==_0x594717['type']?_0x594717['previousPosition']['path']['slice'](0x0,-0x1):_0x594717['previousPosition']['path'];_0x16f341['getNodeByPath'](_0x37aa60)['_setAttribute'](_0x11d929,_0x5221b4),this['_touched']['set'](_0x5221b4,{'userId':_0x45357f});}}for(const _0xfa576d of this['editor']['model']['createRangeIn'](_0x51f4ba)['getWalker']({'singleCharacters':!0x0})){const _0x46972c=this['_getVidAttributeName'](_0xfa576d),_0x580d16='elementEnd'==_0xfa576d['type']?_0xfa576d['previousPosition']['path']['slice'](0x0,-0x1):_0xfa576d['previousPosition']['path'],_0x195c21=_0x16f341['getNodeByPath'](_0x580d16);_0x195c21['getAttribute'](_0x46972c)>0x0||_0x195c21['_setAttribute'](_0x46972c,_0x1e3b46[_0x55fce4++]);}for(const [_0x569350,_0x15fbf2]of _0x51f4ba['markers'])_0x569350['startsWith']('revision:')||this['_markers']['set'](_0x569350,_0x15fbf2);}const _0x2b19f0=P('$graveyard');this['_baseRoots']['set']('$graveyard',_0x2b19f0),this['_baseIdsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x2b19f0,0x1));const _0x21b3dd=P('$graveyard');this['_diffRoots']['set']('$graveyard',_0x21b3dd),this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x21b3dd,0x1));const _0x3c4f84=Array['from'](this['_diffRoots'])['map'](([_0x21c18b,_0x28f0ee])=>[_0x21c18b,N(_0x28f0ee)]);this['_saveMetaData'](this['_lastTo'],_0x3c4f84,this['_markers'],_0x20cd30);}['reInit'](){this['_reset'](),this['_lastFrom']=-0x1,this['_lastTo']=-0x1,this['_savedMetaData']['clear'](),this['init'](this['source']);}['_saveMetaData'](_0x1bfbc3,_0x1a1c1d,_0x4188d8,_0x5dfc4b){const _0x3e402c=new Map(_0x1a1c1d),_0xd7efd0=new Map(_0x4631d1(_0x5dfc4b)),_0x248207=new Map();for(const [_0x5981c6,_0x1cdc03]of _0x4188d8)_0x248207['set'](_0x5981c6,{'start':_0x1cdc03['start']['clone'](),'end':_0x1cdc03['end']['clone'](),'rootName':_0x1cdc03['root']['rootName']});this['_savedMetaData']['set'](_0x1bfbc3,{'roots':_0x3e402c,'markers':_0x248207,'rootsAttributes':_0xd7efd0});}['_removeMetaData'](_0x33852e){this['_savedMetaData']['delete'](_0x33852e);}['_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'](_0x4a5d9a,_0x34ef7c=null){let _0x1b0a2b=null;_0x4a5d9a['is']('documentFragment')||(_0x1b0a2b=new ut(_0x4a5d9a['name'],{'vid_start':null===_0x34ef7c?this['_revisionId']++:_0x34ef7c++}));const _0x1dbd15=[];for(const _0x10342c of _0x4a5d9a['getChildren']())if(_0x10342c['is']('element')){_0x1dbd15['push'](this['_makeIdsRoot'](_0x10342c,_0x34ef7c));const _0x42de70=_0x1dbd15[_0x1dbd15['length']-0x1];null!==_0x34ef7c&&(_0x34ef7c=_0x42de70['is']('element','$text')?_0x42de70['getAttribute']('vid')+0x1:_0x42de70['getAttribute']('vid_end')+0x1);}else{for(let _0x25fe72=0x0;_0x25fe72<_0x10342c['offsetSize'];_0x25fe72++)_0x1dbd15['push'](new ut('$text',{'vid':null===_0x34ef7c?this['_revisionId']++:_0x34ef7c++}));}if(_0x4a5d9a['is']('documentFragment')){const _0x5a177d=P(_0x4a5d9a['rootName']);return _0x5a177d['_insertChild'](0x0,_0x1dbd15),_0x5a177d;}return _0x1b0a2b['_setAttribute']('vid_end',null===_0x34ef7c?this['_revisionId']++:_0x34ef7c++),_0x1b0a2b['_insertChild'](0x0,_0x1dbd15),_0x1b0a2b;}['_calculateMetaData'](_0x3ab3c4,_0x120da1,_0x1a7e09){this['_reset']();const {roots:_0x307735,markers:_0x406d7d,rootsAttributes:_0x174011}=this['_savedMetaData']['get'](_0x3ab3c4);this['_baseRoots']=new Map(_0x307735),this['_baseRootsAttributes']=new Map(_0x4631d1(_0x174011));for(const [_0x5cc45a,_0x5020c3]of this['_baseRoots'])if('$graveyard'!==_0x5cc45a&&(this['_diffRoots']['set'](_0x5cc45a,N(_0x5020c3)),this['_diffRootsAttributes']=new Map(_0x4631d1(_0x174011)),_0x1a7e09)){const _0x559076=this['_revisionId'];this['_idsRoots']['set'](_0x5cc45a,this['_makeIdsRoot'](_0x5020c3)),this['_baseIdsRoots']['set'](_0x5cc45a,this['_makeIdsRoot'](_0x5020c3,_0x559076));}this['_startingRevisionId']=this['_revisionId'],this['_diffRoots']['set']('$graveyard',N(this['_baseRoots']['get']('$graveyard'))),_0x1a7e09&&this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](this['_baseRoots']['get']('$graveyard')));for(const [_0x1d4a20,_0x33273f]of _0x406d7d){const _0x3e0dec=this['_baseRoots']['get'](_0x33273f['rootName']),_0x56885f=this['_diffRoots']['get'](_0x33273f['rootName']),_0x30ac01=new ft(this['_fixPosition'](_0x33273f['start'],_0x3e0dec),this['_fixPosition'](_0x33273f['end'],_0x3e0dec)),_0x50b87b=this['_fixRange'](_0x30ac01,_0x56885f);_0x3e0dec['markers']['set'](_0x1d4a20,_0x30ac01),this['_markers']['set'](_0x1d4a20,_0x50b87b);}this['_applyOperations'](_0x3ab3c4,_0x120da1,_0x1a7e09);}['_applyOperations'](_0x2c3136,_0x41c74b,_0x509f73){for(const _0x4a8612 of this['source']['getOperations'](_0x2c3136,_0x41c74b))this['_handleOperation'](_0x4a8612,_0x509f73);for(const _0x242562 of this['_diffRoots']['values']())_0x242562['markers']['clear']();for(const [_0x55b18b,_0x107b2a]of this['_markers']){this['_diffRoots']['get'](_0x107b2a['root']['rootName'])['markers']['set'](_0x55b18b,_0x107b2a['clone']());}const _0x5d12c5=new Map(),_0x1f121c=new Map();for(const [_0x28c4b4,_0x52a25a]of this['_diffRoots'])_0x5d12c5['set'](_0x28c4b4,N(_0x52a25a)),_0x1f121c['set'](_0x28c4b4,this['_diffRootsAttributes']['get'](_0x28c4b4));this['_saveMetaData'](_0x41c74b,_0x5d12c5,this['_markers'],_0x1f121c);}['_getPreviousFrom'](_0x190e35){const _0x4f117d=Array['from'](this['_savedMetaData']['keys']());_0x4f117d['sort']((_0x18f995,_0x2239c3)=>_0x18f995-_0x2239c3),_0x4f117d['reverse']();for(const _0x10fd32 of _0x4f117d)if(_0x10fd32<_0x190e35)return _0x10fd32;return Number['NEGATIVE_INFINITY'];}['_copyMarkers'](_0x359b58,_0x4a0228){const _0x53353f=Array['from'](_0x4a0228['markers'])['map'](([_0xe27f5a,_0x5c667b])=>[_0xe27f5a,this['_fixRange'](_0x5c667b,_0x359b58)]);_0x359b58['markers']=new Map(_0x53353f);}['_transformMarkers'](_0x53a912){for(const _0x47c70c of this['_markers']['values']()){const _0x515347=_0x47c70c['getTransformedByOperation'](_0x53a912),_0x51887e=ft['_createFromRanges'](_0x515347);_0x47c70c['start']=_0x51887e['start'],_0x47c70c['end']=_0x51887e['end'];}}['_handleOperation'](_0x19ee15,_0x4cd3bd){if('addRoot'!=_0x19ee15['type']&&'detachRoot'!=_0x19ee15['type']){if('insert'==_0x19ee15['type']){const _0x2a624a=_0x19ee15['position']['root']['rootName'];this['_diffRoots']['has'](_0x2a624a)||(this['_diffRoots']['set'](_0x2a624a,P(_0x2a624a,!0x0)),this['_diffRootsAttributes']['set'](_0x2a624a,{}),_0x4cd3bd&&this['_idsRoots']['set'](_0x2a624a,P(_0x2a624a,!0x0)));}else{if('addRootAttribute'==_0x19ee15['type']||'removeRootAttribute'==_0x19ee15['type']||'changeRootAttribute'==_0x19ee15['type'])return void this['_handleRootAttributeOperation'](_0x19ee15);'marker'==_0x19ee15['type']&&this['_handleMarkerOperation'](_0x19ee15);}if('marker'!==_0x19ee15['type']){const _0x19326a=this['_cloneOperation'](_0x19ee15,this['_diffRoots']);_0x19326a['_execute'](),this['_transformMarkers'](_0x19326a);}if(_0x4cd3bd)switch(_0x19ee15['type']){case'insert':this['_handleInsertOperation'](_0x19ee15);break;case'move':case'remove':case'reinsert':this['_handleMoveOperation'](_0x19ee15);break;case'merge':this['_handleMergeOperation'](_0x19ee15);break;case'split':this['_handleSplitOperation'](_0x19ee15);}}else this['_handleRootOperation'](_0x19ee15,_0x4cd3bd);}['_cloneOperation'](_0x1c56fd,_0x36ada5){const _0x3a5041=_0x1c56fd['clone']();return _0x3a5041['_authorId']=_0x1c56fd['_authorId'],this['_fixOperation'](_0x3a5041,_0x36ada5),_0x3a5041;}['_getBaseVids'](_0x899f0a){return _0x899f0a['map'](_0x25c61b=>{const _0x4a95cf=this['_getVidAttributeName'](_0x25c61b);return Number(_0x25c61b['item']['getAttribute'](_0x4a95cf));});}['_generateTape'](_0x40d85f,_0x37ab37){if(_0x40d85f['is']('element','$text'))_0x37ab37['push']({'item':_0x40d85f,'type':'text'});else{_0x40d85f['is']('element')&&_0x37ab37['push']({'item':_0x40d85f,'type':'elementStart'});for(const _0x2ea59 of _0x40d85f['getChildren']())this['_generateTape'](_0x2ea59,_0x37ab37);_0x40d85f['is']('element')&&_0x37ab37['push']({'item':_0x40d85f,'type':'elementEnd'});}return _0x37ab37;}['_getState'](){const _0xc689d8=new Map(this['_touched']),_0x4f9c92=new Map(_0xc689d8),_0x223899=new Map(),_0x1ff92e={'insertions':{},'deletions':{}},_0x523883={'insertions':{},'deletions':{}},_0x59a550=new Map(),_0x47ab78=new Set([...this['_baseRoots']['keys'](),...this['_diffRoots']['keys']()]);_0x47ab78['delete']('$graveyard');for(const _0x40aebc of _0x47ab78){const _0x2ad19f=this['_diffRoots']['get'](_0x40aebc)||P(_0x40aebc,!0x1),_0xa71f13=this['_baseRoots']['get'](_0x40aebc)||P(_0x40aebc,!0x1);_0x2ad19f['isAttached']()||_0xa71f13['isAttached']()?(_0x1ff92e['insertions'][_0x40aebc]=N(_0x2ad19f),_0x1ff92e['deletions'][_0x40aebc]=N(_0xa71f13),this['_copyMarkers'](_0x1ff92e['deletions'][_0x40aebc],_0xa71f13),this['_copyMarkers'](_0x1ff92e['insertions'][_0x40aebc],_0x2ad19f),_0x523883['insertions'][_0x40aebc]=this['_generateTape'](this['_idsRoots']['get'](_0x40aebc),[]),_0x523883['deletions'][_0x40aebc]=this['_generateTape'](this['_baseIdsRoots']['get'](_0x40aebc)||P(_0x40aebc,!0x1),[])):_0x47ab78['delete'](_0x40aebc);}for(const _0x472c45 of _0x47ab78){const _0x422683=_0x523883['insertions'][_0x472c45];for(const _0x256327 of _0x422683){const _0x177145=this['_getVidAttributeName'](_0x256327),_0x225db8=_0x256327['item']['getAttribute'](_0x177145);_0x4f9c92['delete'](_0x225db8),_0x225db8>=this['_startingRevisionId']&&_0x223899['set'](_0x225db8,_0xc689d8['get'](_0x225db8));}}for(const _0x16fdfb of _0x47ab78){const _0x480143=_0x523883['insertions'][_0x16fdfb],_0x2f72fc=this['_getBaseVids'](_0x523883['deletions'][_0x16fdfb]);let _0x5214e8=0x0;for(const _0x407013 of _0x480143){const _0x5b8d98=this['_getVidAttributeName'](_0x407013),_0x970256=_0x407013['item']['getAttribute'](_0x5b8d98);if(!_0x223899['has'](_0x970256)&&!_0x59a550['has'](_0x970256)){if(_0x4f9c92['has'](_0x970256))_0x5214e8++;else{if(_0x970256!=_0x2f72fc[_0x5214e8]){const _0x563ea9=_0xc689d8['get'](_0x970256)||_0xc689d8['get'](_0x2f72fc[_0x5214e8]);for(;_0x970256!=_0x2f72fc[_0x5214e8];)_0x4f9c92['has'](_0x2f72fc[_0x5214e8])||(_0x59a550['set'](_0x2f72fc[_0x5214e8],_0x563ea9),_0xc689d8['set'](_0x2f72fc[_0x5214e8],_0x563ea9)),_0x5214e8++;}_0x5214e8++;}}}}for(const _0x33cf4e of _0x47ab78){const _0x3570c8=_0x523883['insertions'][_0x33cf4e];for(const _0x4c7c76 of _0x3570c8){const _0x2f804e=this['_getVidAttributeName'](_0x4c7c76),_0x1c9d65=_0x4c7c76['item']['getAttribute'](_0x2f804e);if(_0x59a550['has'](_0x1c9d65)){const _0x1a8a1e=_0x59a550['get'](_0x1c9d65);_0x4f9c92['has'](_0x1c9d65)||_0x4f9c92['set'](_0x1c9d65,{..._0x1a8a1e}),_0x223899['set'](_0x1c9d65,{..._0x1a8a1e});}}}for(const _0x447e55 of _0x4f9c92['keys']())_0x447e55>=this['_startingRevisionId']&&_0x4f9c92['delete'](_0x447e55);const _0x3cc44e=new Map();for(const _0x486916 of _0x47ab78){let _0x97860a=_0x523883['insertions'][_0x486916];for(const _0x2a654c of _0x97860a)if(_0x2a654c['item']['is']('element','tableCell')){const _0x2fc8e0=this['_getVidAttributeName'](_0x2a654c),_0x2ce7f5=_0x2a654c['item']['getAttribute'](_0x2fc8e0);if(_0x223899['has'](_0x2ce7f5)){const _0x2f3124=_0x2a654c['item']['parent']['parent']['getAttribute']('vid_start'),_0x48ea70=_0x3cc44e['get'](_0x2f3124)||new Set();_0x48ea70['add'](_0x223899['get'](_0x2ce7f5)['userId']),_0x3cc44e['set'](_0x2f3124,_0x48ea70);}}_0x97860a=_0x523883['deletions'][_0x486916];for(const _0x33df90 of _0x97860a)if(_0x33df90['item']['is']('element','tableCell')){const _0x36f305=this['_getVidAttributeName'](_0x33df90),_0x15c7e5=_0x33df90['item']['getAttribute'](_0x36f305);if(_0x4f9c92['has'](_0x15c7e5)){const _0x1bc708=_0x33df90['item']['parent']['parent']['getAttribute']('vid_start'),_0x12812e=_0x3cc44e['get'](_0x1bc708)||new Set();_0x12812e['add'](_0x4f9c92['get'](_0x15c7e5)['userId']),_0x3cc44e['set'](_0x1bc708,_0x12812e);}}for(const _0x276a0e of _0x3cc44e['keys']())(_0x223899['has'](_0x276a0e)||_0x4f9c92['has'](_0x276a0e))&&_0x3cc44e['delete'](_0x276a0e);}for(const _0x114f6a of _0x47ab78){const _0x2a99f3=_0x523883['insertions'][_0x114f6a];let _0x51e357=null,_0x326c81=null;for(const _0x311f86 of _0x2a99f3){const _0x14daf5=this['_getVidAttributeName'](_0x311f86),_0x3a7317=_0x311f86['item']['getAttribute'](_0x14daf5),_0x9b402c=_0x3cc44e['get'](_0x3a7317);_0x9b402c&&'elementStart'==_0x311f86['type']&&(_0x51e357=Array['from'](_0x9b402c)[0x0],_0x326c81=_0x311f86['item']['getAttribute']('vid_end')),_0x51e357&&(_0x4f9c92['set'](_0x3a7317,{'userId':_0x51e357}),_0x223899['set'](_0x3a7317,{'userId':_0x51e357})),_0x3a7317==_0x326c81&&(_0x51e357=null,_0x326c81=null);}}const _0x1d052a={},_0x20d10e=new Set();for(const _0x24a622 of _0x47ab78){const _0x3b1c91=_0x1ff92e['deletions'][_0x24a622],_0x4335bf=_0x1ff92e['insertions'][_0x24a622];for(const {userId:_0x581eb6}of this['_touchedMarkers']['values']())null!==_0x581eb6&&_0x20d10e['add'](_0x581eb6);for(const {userId:_0x437f31}of this['_touchedRoots']['values']())null!==_0x437f31&&_0x20d10e['add'](_0x437f31);this['_markChanges'](_0x4335bf,_0x523883['insertions'][_0x24a622],_0x223899,'insertion',_0x20d10e),this['_markChanges'](_0x3b1c91,_0x523883['deletions'][_0x24a622],_0x4f9c92,'deletion',_0x20d10e),_0x1d052a[_0x24a622]={'insertions':this['_prepareViewToSave'](_0x4335bf),'deletions':this['_prepareViewToSave'](_0x3b1c91),'attachChange':this['_touchedRoots']['get'](_0x24a622)||null,'attributesBefore':_0x4631d1(this['_baseRootsAttributes']['get'](_0x24a622))||{},'attributesAfter':_0x4631d1(this['_diffRootsAttributes']['get'](_0x24a622))};}return{'diffData':_0x1d052a,'authorsIds':Array['from'](_0x20d10e)};}['_processRootBeforeSave'](_0x3b4fce){for(const [,_0x120e57]of _0x3b4fce['markers']){const _0x193b6c=_0x120e57['start']['getAncestors']()['filter'](_0x4b7d4e=>'tableCell'==_0x4b7d4e['name']);for(const _0x218095 of _0x193b6c)0x1==_0x218095['childCount']&&_0x218095['getChild'](0x0)['is']('element','paragraph')&&_0x218095['getChild'](0x0)['_setAttribute']('keepParagraph',!0x0);}}['_prepareViewToSave'](_0x3194d0){this['_processRootBeforeSave'](_0x3194d0);const _0x45c813=this['editor']['data']['toView'](_0x3194d0,{}),_0x5ce54a=Array['from'](_0x45c813['getChildren']())['map'](_0x2527f3=>this['_getViewJson'](_0x2527f3));return JSON['stringify'](_0x5ce54a);}['_getViewJson'](_0x32a8e1){if(_0x32a8e1['is']('$text'))return _0x32a8e1['data'];{const _0x30962e=this['editor']['plugins']['get']('RevisionHistoryUtils'),_0x2c2eb0=_0x32a8e1,_0x12d0d1=this['editor']['data']['htmlProcessor']['domConverter'],_0x1212e7={'type':_0x30962e['_getTypeCharForViewElement'](_0x2c2eb0),'name':_0x2c2eb0['name'],'attributes':Array['from'](_0x2c2eb0['getAttributes']()),'children':Array['from'](_0x2c2eb0['getChildren']())['map'](_0x5558fd=>this['_getViewJson'](_0x5558fd))};if(_0x32a8e1['is']('uiElement')&&'$comment'!=_0x32a8e1['name']){const _0x15a176=_0x32a8e1['render'](_0x12d0d1['domDocument'],_0x12d0d1);_0x1212e7['children']['push'](_0x15a176['outerHTML']);}else{if(_0x32a8e1['is']('rawElement')){const _0x211d82=_0x12d0d1['domDocument']['createElement'](_0x2c2eb0['name']);_0x32a8e1['render'](_0x211d82,_0x12d0d1),_0x1212e7['children']['push'](_0x211d82['innerHTML']);}}const _0x2e1a0b=Array['from'](_0x2c2eb0['getCustomProperties']());_0x2e1a0b['length']>0x0&&(_0x1212e7['customProperties']=_0x2e1a0b);const _0x76c399=_0x2c2eb0['getFillerOffset']();return null!==_0x76c399&&(_0x1212e7['fillerOffset']=_0x76c399),_0x1212e7;}}['_markChanges'](_0x4fb294,_0x4a045d,_0x477ed6,_0x2ce52e,_0xfc1aae){let _0x34e230=null,_0x4c2db8=null,_0x43676f=0x0;const _0x567f87=this['editor']['model'];for(let _0x59c528=0x0;_0x59c528<_0x4a045d['length'];_0x59c528++){const _0x59b9e0=this['_getVidAttributeName'](_0x4a045d[_0x59c528]),_0x62e870=_0x4a045d[_0x59c528]['item']['getAttribute'](_0x59b9e0),_0x278bed=_0x477ed6['get'](_0x62e870),_0x3aea07=_0x59c528==_0x4a045d['length']-0x1;(!_0x34e230&&_0x278bed&&(_0x34e230=_0x278bed,_0x4c2db8=_0x4a045d[_0x59c528]),_0x34e230&&(!_0x278bed||_0x278bed['userId']!=_0x34e230['userId']))&&(_0x46b7a2(_0x278bed,F(_0x4c2db8,_0x4fb294,_0x567f87),F(_0x4a045d[_0x59c528],_0x4fb294,_0x567f87)),_0x34e230=_0x278bed||null,_0x4c2db8=_0x278bed?_0x4a045d[_0x59c528]:null),_0x34e230&&_0x3aea07&&_0x46b7a2(_0x278bed,F(_0x4c2db8,_0x4fb294,_0x567f87),B(_0x4a045d[_0x59c528],_0x4fb294,_0x567f87));}function _0x46b7a2(_0x1e1d9a,_0x4969ba,_0x29557c){const _0x29b7f6=_0x34e230['userId'],_0x433b17='revision:'+_0x2ce52e+':'+_0x29b7f6+':'+_0x43676f++,_0x5cf697=_0x567f87['createRange'](_0x4969ba,_0x29557c);_0x4fb294['markers']['set'](_0x433b17,_0x5cf697),null!==_0x29b7f6&&_0xfc1aae['add'](_0x29b7f6);}}['_getVidAttributeName'](_0x55fdd7){switch(_0x55fdd7['type']){case'elementStart':return'vid_start';case'elementEnd':return'vid_end';default:return'vid';}}['_fixOperation'](_0x1616de,_0x4b3dbc){_0x1616de['baseVersion']=null;for(const _0x48eaef in _0x1616de){const _0x3d1152=_0x1616de[_0x48eaef];if(_0x3d1152 instanceof vt){const _0x21d715=_0x4b3dbc['get'](_0x3d1152['root']['rootName']);_0x1616de[_0x48eaef]=this['_fixPosition'](_0x3d1152,_0x21d715);}if(_0x3d1152 instanceof ft){const _0x2d9a24=_0x4b3dbc['get'](_0x3d1152['root']['rootName']);_0x1616de[_0x48eaef]=this['_fixRange'](_0x3d1152,_0x2d9a24);}'root'===_0x48eaef&&(_0x1616de['root']=_0x4b3dbc['get'](_0x1616de['root']['rootName']));}}['_fixRange'](_0x3cd180,_0x1e414a){return this['editor']['model']['createRange'](this['_fixPosition'](_0x3cd180['start'],_0x1e414a),this['_fixPosition'](_0x3cd180['end'],_0x1e414a));}['_fixPosition'](_0x48c5ff,_0x451cd6){return this['editor']['model']['createPositionFromPath'](_0x451cd6,_0x48c5ff['path'],_0x48c5ff['stickiness']);}['_handleInsertOperation'](_0x576247){const _0x366e9e=this['_idsRoots']['get'](_0x576247['position']['root']['rootName']),_0xcecc9a=this['_fixPosition'](_0x576247['position'],_0x366e9e),_0x1185e0=null===_0x576247['_authorId']?null:_0x576247['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x55bb2b=_0xcecc9a['parent'],_0x136a3a=this['_revisionId'],_0x68b3be=[];for(const _0xadbeaa of _0x576247['nodes'])if(_0xadbeaa['is']('element'))_0x68b3be['push'](this['_makeIdsRoot'](_0xadbeaa));else{for(let _0x4f2b7d=0x0;_0x4f2b7d<_0xadbeaa['offsetSize'];_0x4f2b7d++)_0x68b3be['push'](new ut('$text',{'vid':this['_revisionId']++}));}const _0x1fc730=this['_revisionId'];for(let _0x81f9f2=_0x136a3a;_0x81f9f2<_0x1fc730;_0x81f9f2++)this['_touched']['set'](_0x81f9f2,{'userId':_0x1185e0});_0x55bb2b['_insertChild'](_0xcecc9a['offset'],_0x68b3be);}['_handleMoveOperation'](_0x4c87ff){(_0x4c87ff=this['_cloneOperation'](_0x4c87ff,this['_idsRoots']))['_execute']();const _0x2be398=null===_0x4c87ff['_authorId']?null:_0x4c87ff['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x4b29e6=_0x4c87ff['getMovedRangeStart'](),_0x4b9406=_0x4b29e6['parent'],_0x43601a=_0x4b29e6['offset'];!function _0x460fa9(_0xd0c6d5,_0x2d5906,_0x402901,_0x5e4532){for(let _0x5995d5=_0x402901;_0x5995d5<_0x5e4532;_0x5995d5++){const _0x150e50=_0x2d5906['getChild'](_0x5995d5);_0x150e50['is']('element','$text')?_0xd0c6d5['set'](_0x150e50['getAttribute']('vid'),{'userId':_0x2be398}):(_0xd0c6d5['set'](_0x150e50['getAttribute']('vid_start'),{'userId':_0x2be398}),_0x460fa9(_0xd0c6d5,_0x150e50,0x0,_0x150e50['childCount']),_0xd0c6d5['set'](_0x150e50['getAttribute']('vid_end'),{'userId':_0x2be398}));}}(this['_touched'],_0x4b9406,_0x43601a,_0x43601a+_0x4c87ff['howMany']);}['_handleMergeOperation'](_0x3982cd){const _0x4babda=null===(_0x3982cd=this['_cloneOperation'](_0x3982cd,this['_idsRoots']))['_authorId']?null:_0x3982cd['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0xace258=_0x3982cd['targetPosition']['parent'],_0x5eeee0=_0x3982cd['sourcePosition']['parent'],_0x29be6c=_0xace258['getAttribute']('vid_end'),_0xb4fc52=_0x5eeee0['getAttribute']('vid_start');_0xace258['_setAttribute']('vid_end',_0x5eeee0['getAttribute']('vid_end')),_0x5eeee0['_setAttribute']('vid_end',_0x29be6c),this['_touched']['set'](_0xb4fc52,{'userId':_0x4babda}),this['_touched']['set'](_0x29be6c,{'userId':_0x4babda}),_0x3982cd['_execute']();}['_handleSplitOperation'](_0x122661){const _0x2e83ea=null===(_0x122661=this['_cloneOperation'](_0x122661,this['_idsRoots']))['_authorId']?null:_0x122661['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x31b4b3=_0x122661['graveyardPosition'],_0x4d4d3c=_0x122661['splitPosition']['parent'];_0x122661['_execute']();const _0x22a854=_0x4d4d3c['getAttribute']('vid_end'),_0x38ef47=_0x122661['insertionPosition']['nodeAfter'];if(_0x31b4b3){const _0x448491=_0x38ef47['getAttribute']('vid_end'),_0x222010=_0x4d4d3c['getAttribute']('vid_end');_0x4d4d3c['_setAttribute']('vid_end',_0x448491),_0x38ef47['_setAttribute']('vid_end',_0x222010),this['_touched']['set'](_0x4d4d3c['getAttribute']('vid_end'),{'userId':_0x2e83ea}),this['_touched']['set'](_0x38ef47['getAttribute']('vid_start'),{'userId':_0x2e83ea});}else{const _0x54f35e=this['_revisionId']++,_0x2fa035=this['_revisionId']++;_0x4d4d3c['_setAttribute']('vid_end',_0x54f35e),_0x38ef47['_setAttribute']('vid_start',_0x2fa035),_0x38ef47['_setAttribute']('vid_end',_0x22a854),this['_touched']['set'](_0x54f35e,{'userId':_0x2e83ea}),this['_touched']['set'](_0x2fa035,{'userId':_0x2e83ea});}}['_handleMarkerOperation'](_0x6793e){if(!_0x6793e['affectsData'])return;const _0x4c056c=(_0x6793e=this['_cloneOperation'](_0x6793e,this['_diffRoots']))['oldRange']?_0x6793e['oldRange']['root']:null,_0x469713=_0x6793e['newRange']?_0x6793e['newRange']['root']:null;_0x4c056c&&this['_markers']['delete'](_0x6793e['name']),_0x469713&&this['_markers']['set'](_0x6793e['name'],_0x6793e['newRange']['clone']());const _0x4d6d76=null===_0x6793e['_authorId']?null:_0x6793e['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x3487e6=_0x6793e['name'];if(!this['_touchedMarkers']['has'](_0x3487e6))return void this['_touchedMarkers']['set'](_0x3487e6,{'range':_0x6793e['oldRange'],'userId':_0x4d6d76});const _0x4de979=this['_touchedMarkers']['get'](_0x3487e6),_0x31dc8e=_0x4de979['range'],_0x2fd508=_0x6793e['newRange'];null==_0x31dc8e&&null==_0x2fd508||_0x31dc8e&&_0x2fd508&&_0x31dc8e['isEqual'](_0x2fd508)?this['_touchedMarkers']['delete'](_0x6793e['name']):_0x4de979['userId']=_0x4d6d76;}['_handleRootOperation'](_0x3eee25,_0x3a99d6){this['_diffRoots']['has'](_0x3eee25['rootName'])?this['_diffRoots']['get'](_0x3eee25['rootName'])['_isAttached']=_0x3eee25['isAdd']:(this['_diffRoots']['set'](_0x3eee25['rootName'],P(_0x3eee25['rootName'],!0x0)),this['_diffRootsAttributes']['set'](_0x3eee25['rootName'],{}),_0x3a99d6&&this['_idsRoots']['set'](_0x3eee25['rootName'],P(_0x3eee25['rootName'],!0x0)));const _0xd320b0=null===_0x3eee25['_authorId']?null:_0x3eee25['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x14ce91=this['_touchedRoots']['get'](_0x3eee25['rootName']);_0x14ce91&&_0x14ce91['userId']===_0xd320b0?this['_touchedRoots']['delete'](_0x3eee25['rootName']):this['_touchedRoots']['set'](_0x3eee25['rootName'],{'userId':_0xd320b0,'isAttached':_0x3eee25['isAdd']});}['_handleRootAttributeOperation'](_0x1bea7a){const _0x18fb51=this['_diffRootsAttributes']['get'](_0x1bea7a['root']['rootName']);null===_0x1bea7a['newValue']?delete _0x18fb51[_0x1bea7a['key']]:_0x18fb51[_0x1bea7a['key']]=_0x1bea7a['newValue'];}}function N(_0x503662){const _0x5db0cc=P(_0x503662['rootName'],_0x503662['isAttached']());for(const _0x14e21e of _0x503662['getChildren']()){const _0x5b7c31=_0x14e21e['_clone'](!0x0);_0x5db0cc['_appendChild'](_0x5b7c31);}return _0x5db0cc;}function P(_0x19f86b,_0x583d3e=!0x0){const _0x45e0cc=new gt();return _0x45e0cc['rootName']=_0x19f86b,_0x45e0cc['_isAttached']=_0x583d3e,_0x45e0cc['isAttached']=()=>_0x45e0cc['_isAttached'],_0x45e0cc;}function F(_0x2ac4b9,_0x152348,_0x31404a){const _0x28ba73='elementEnd'==_0x2ac4b9['type']?_0x31404a['createPositionAt'](_0x2ac4b9['item'],'end'):_0x31404a['createPositionBefore'](_0x2ac4b9['item']);return _0x31404a['createPositionFromPath'](_0x152348,_0x28ba73['path'],_0x28ba73['stickiness']);}function B(_0x5a0955,_0x73e8c8,_0x4a447c){const _0x3b362e='elementStart'==_0x5a0955['type']?_0x4a447c['createPositionAt'](_0x5a0955['item'],0x0):_0x4a447c['createPositionAfter'](_0x5a0955['item']);return _0x4a447c['createPositionFromPath'](_0x73e8c8,_0x3b362e['path'],_0x3b362e['stickiness']);}class hs extends _0x1792c1{['focusTracker'];['keystrokes'];['revisionNameInputView'];constructor(_0xdcfe11,_0x313757){super(_0xdcfe11),this['focusTracker']=new _0x82470a(),this['keystrokes']=new _0x35e91d(),this['set']('revisionNameInputValue',''),this['revisionNameInputView']=this['_createRevisionNameInput'](_0x313757),this['setTemplate']({'tag':'form','attributes':{'class':['ck','ck-revision-history-save-revision-form','ck-responsive-form'],'tabindex':'-1'},'children':[this['revisionNameInputView']]}),ts(this);}['render'](){super['render'](),_0x44053f({'view':this}),this['focusTracker']['add'](this['revisionNameInputView']['element']),this['keystrokes']['listenTo'](this['element']);const _0x26bd17=_0x56ff32=>_0x56ff32['stopPropagation']();this['keystrokes']['set']('arrowright',_0x26bd17),this['keystrokes']['set']('arrowleft',_0x26bd17),this['keystrokes']['set']('arrowup',_0x26bd17),this['keystrokes']['set']('arrowdown',_0x26bd17);}['focus'](){this['revisionNameInputView']['focus']();}get['revisionName'](){return this['revisionNameInputView']['fieldView']['element']['value']['trim']();}set['revisionName'](_0x470b63){this['revisionNameInputView']['fieldView']['element']['value']=_0x470b63['trim']();}['reset'](){this['revisionNameInputView']['fieldView']['element']['value']='',this['revisionNameInputView']['errorText']=null;}['_createRevisionNameInput'](_0x3d7b07){const _0x17feea=new nt(this['locale'],ti),_0x4c78a6=_0x17feea['fieldView'];_0x4c78a6['extendTemplate']({'attributes':{'maxlength':'220'}});let _0x44b97e=g(this['locale'],'Name\x20of\x20the\x20revision');return!_0x3d7b07&&(_0x44b97e+='\x20('+g(this['locale'],'optional')+')'),(_0x17feea['label']=_0x44b97e,_0x4c78a6['on']('input',()=>{this['revisionNameInputValue']=_0x4c78a6['element']['value']['trim']();}),_0x17feea);}}class f extends _0x3f2981{static get['pluginName'](){return'RevisionHistoryUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[u];}['_saveRevisionFormView'];['init'](){const _0xd62710=this['editor'],_0x4323de=_0xd62710['plugins']['get']('RevisionTracker');_0xd62710['ui']['componentFactory']['add']('revisionHistory',_0x51b66e=>{const _0x1dac34=_0x542f9c(_0x51b66e),_0x199ddc=_0x1dac34['panelView']['children'],_0xd6c70a=new _0x5142bf(_0x51b66e),_0xeaa97a=new _0x5acfd9(_0x51b66e),_0x2dde42=new _0x1abc3e(_0x51b66e),_0x1c6947=new _0x5acfd9(_0x51b66e),_0x2a00c6=new _0x1abc3e(_0x51b66e);return _0x1dac34['bind']('isEnabled')['to'](_0x4323de,'isReady',_0x4323de,'isEnabled',_0xd62710,'isReadOnly',(_0x29748d,_0x431f73,_0x5020a1)=>_0x29748d&&_0x431f73&&!_0x5020a1),_0x1dac34['buttonView']['set']({'icon':_0x184d1b,'label':g(_0x51b66e,'Revision\x20history'),'tooltip':!0x0}),_0x2dde42['set']({'label':g(_0x51b66e,'Save\x20current\x20revision'),'withText':!0x0,'role':'menuitem'}),_0x2dde42['bind']('isEnabled')['to'](_0x4323de,'isReady',_0x4323de,'isEnabled',_0xd62710,'isReadOnly',(_0x429499,_0x5079d9,_0x18b428)=>_0x429499&&_0x5079d9&&!_0x18b428),_0x2dde42['on']('execute',()=>this['_showDialog']()),_0x2a00c6['set']({'label':g(_0x51b66e,'Open\x20revision\x20history'),'withText':!0x0,'role':'menuitem'}),_0x2a00c6['bind']('isEnabled')['to'](_0x4323de,'isReady',_0xd62710,'isReadOnly',(_0x89ba18,_0x4c3d8b)=>_0x89ba18&&!_0x4c3d8b),_0x2a00c6['on']('execute',()=>{_0xd62710['config']['get']('revisionHistory')['showRevisionViewerCallback'](),_0x1dac34['isOpen']=!0x1,_0xd62710['editing']['view']['focus']();}),_0xeaa97a['children']['add'](_0x2dde42),_0x1c6947['children']['add'](_0x2a00c6),_0xd6c70a['role']='menu',_0xd6c70a['items']['addMany']([_0xeaa97a,_0x1c6947]),_0x199ddc['add'](_0xd6c70a),_0x1dac34;}),_0xd62710['ui']['componentFactory']['add']('menuBar:revisionHistory',()=>this['_registerMenuComponent']());}['_registerMenuComponent'](){const _0x49dbd9=this['editor'],_0x451e7e=_0x49dbd9['locale'],_0x209f93=new _0x106d50(_0x451e7e),_0x5e7019=new _0x5c1d2b(_0x451e7e);_0x209f93['buttonView']['set']({'icon':_0x184d1b,'label':g(_0x451e7e,'Revision\x20history')});const _0x49e43c=new _0x1afdb1(_0x451e7e,_0x209f93),_0x711da2=new _0x3eef0c(_0x451e7e);_0x711da2['set']({'label':g(_0x451e7e,'Save\x20current\x20revision')}),_0x711da2['delegate']('execute')['to'](_0x209f93),_0x711da2['on']('execute',()=>{this['_showDialog']();}),_0x49e43c['children']['add'](_0x711da2),_0x5e7019['items']['add'](_0x49e43c);const _0x366eb4=new _0x1afdb1(_0x451e7e,_0x209f93),_0x326bd7=new _0x3eef0c(_0x451e7e);return _0x326bd7['set']({'label':g(_0x451e7e,'Open\x20revision\x20history')}),_0x326bd7['delegate']('execute')['to'](_0x209f93),_0x326bd7['on']('execute',()=>{_0x49dbd9['config']['get']('revisionHistory')['showRevisionViewerCallback']();}),_0x366eb4['children']['add'](_0x326bd7),_0x5e7019['items']['add'](_0x366eb4),_0x209f93['panelView']['children']['add'](_0x5e7019),_0x209f93;}['_showDialog'](){const _0x27ff18=this['editor'],_0x2d87e6=_0x27ff18['locale'],_0x32c405=_0x27ff18['plugins']['get']('Dialog'),_0x1eebb0=_0x27ff18['plugins']['get']('RevisionTracker');function _0x4bda5f(_0x5109fb){_0x27ff18['config']['get']('revisionHistory.requireRevisionName')&&''===_0x5109fb['revisionName']?_0x5109fb['revisionNameInputView']['errorText']=g(_0x2d87e6,'The\x20revision\x20name\x20cannot\x20be\x20empty.'):(_0x27ff18['plugins']['get'](u)['saveRevision']({'name':_0x5109fb['revisionName']}),_0x32c405['hide']());}this['_saveRevisionFormView']||(this['_createSaveRevisionFormView'](),this['_saveRevisionFormView']['on']('submit',()=>_0x4bda5f(this['_saveRevisionFormView']))),this['_saveRevisionFormView']['reset'](),_0x32c405['show']({'id':'revisionSave','title':g(_0x2d87e6,'Save\x20current\x20revision'),'isModal':!0x0,'content':this['_saveRevisionFormView'],'actionButtons':[{'label':g(_0x27ff18['locale'],'Cancel'),'withText':!0x0,'onExecute':()=>_0x32c405['hide']()},{'label':g(_0x27ff18['locale'],'Accept'),'class':'ck-button-action','withText':!0x0,'onCreate'(_0x3377e6){_0x3377e6['bind']('isEnabled')['to'](_0x1eebb0,'isReady',_0x1eebb0,'isEnabled',_0x27ff18,'isReadOnly',(_0x3e4985,_0x58a8d3,_0x4a0419)=>_0x3e4985&&_0x58a8d3&&!_0x4a0419);},'onExecute':()=>_0x4bda5f(this['_saveRevisionFormView'])}]});}['_createSaveRevisionFormView'](){const _0x21f363=this['editor'],_0x5dff57=_0x21f363['locale'];this['_saveRevisionFormView']=new hs(_0x5dff57,_0x21f363['config']['get']('revisionHistory.requireRevisionName')),this['_saveRevisionFormView']['render']();}}class Q extends _0x1792c1{['changeId'];['_model'];constructor(_0x544e84,_0x1014ed){super(_0x544e84),this['_model']=_0x1014ed,this['changeId']=_0x1014ed['id'];const _0x120012=this['bindTemplate'],_0x44f4e3=g(_0x544e84,_0x1014ed['data']['isSuggestion']?'Suggested\x20by':'add'==_0x1014ed['type']?'Added\x20by':'Removed\x20by');this['set']('type',_0x1014ed['type']),this['setTemplate']({'tag':'div','attributes':{'class':['ck-annotation','ck-revision-change',_0x120012['to']('type',_0x1a393f=>'ck-revision-change__'+_0x1a393f)],'tabindex':-0x1},'children':[{'tag':'span','children':[{'tag':'span','attributes':{'class':['ck-revision-change__label']},'children':[{'text':_0x44f4e3}]},{'text':'\x20'+_0x1014ed['author']['name']}]}]});}['focus'](){this['element']['focus']();}}class r extends/* #__PURE__ -- @preserve */
25
+ _0x58c48e(){['id'];['author'];['type'];['data'];['rootName'];constructor(_0x402ab1){super(),this['id']=_0x402ab1['id']||_0x488afd(),this['author']=_0x402ab1['author'],this['type']=_0x402ab1['type'],this['data']=_0x402ab1['data']||{},this['rootName']=_0x402ab1['rootName'],this['set']('createdAt',_0x402ab1['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(_0x4cec02,_0x1febda){this['newRevisionId']=_0x4cec02,this['oldRevisionId']=_0x1febda,this['changes']=new _0x4419cc();}['_setChanges'](_0x21e84d){for(const _0x25ee00 of _0x21e84d)this['changes']['add'](_0x25ee00);}}class m extends _0x3f2981{['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[_0x2f8fb9,_0x191e0,I,V];}constructor(_0x26bac9){super(_0x26bac9),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',(_0x56e722,_0x2594e6,_0x2d0ae4)=>{this['activeChange']=null,this['activeView']=null,this['editor']['editing']['view']['change'](_0x32d834=>{for(const _0x31615d of this['editor']['editing']['view']['document']['roots'])_0x2d0ae4?_0x32d834['removeClass']('ck-editor__editable__overlay',_0x31615d):_0x32d834['addClass']('ck-editor__editable__overlay',_0x31615d);});}),this['bind']('isNavigationMode')['to'](this,'activeChange',_0x26c4ed=>null!==_0x26c4ed),this['bind']('currentChangeNumber')['to'](this,'isReady',this,'diff',this,'activeChange',(_0x1138e0,_0x3e4f52,_0x5820a7)=>_0x1138e0&&_0x5820a7?_0x3e4f52['changes']['getIndex'](_0x5820a7):0x0),this['bind']('numberOfChanges')['to'](this,'isReady',this,'diff',(_0x3bb0ec,_0x584c3f)=>_0x3bb0ec?_0x584c3f['changes']['length']:0x0),this['_changeView']=null,this['_changeIdToChange']=new Map(),this['_balloon']=this['editor']['plugins']['get'](_0x191e0);}['init'](){const _0x2dd8bb=this['editor'],_0x766951=new pt(_0x2dd8bb,{'direction':'backward'}),_0x4d5909=new pt(_0x2dd8bb,{'direction':'forward'});(_0x2dd8bb['commands']['add']('showPreviousChange',_0x766951),_0x2dd8bb['commands']['add']('showNextChange',_0x4d5909),_0x2dd8bb['commands']['add']('restoreRevision',new wt(_0x2dd8bb)),this['on']('change:numberOfChanges',()=>{_0x766951['refresh'](),_0x4d5909['refresh']();}),this['_setConversion'](),this['_initInteractions'](),_0x2dd8bb['enableReadOnlyMode']('revision-viewer'),_0x2dd8bb['plugins']['has']('WidgetToolbarRepository'))&&_0x2dd8bb['plugins']['get']('WidgetToolbarRepository')['forceDisabled']('revision-viewer');}async['getRevisionDocumentData'](_0x30fc94){return await this['_utils']['loadRevisionData'](_0x30fc94,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x30fc94);}async['getRevisionRootsAttributes'](_0x65ddb1){return await this['_utils']['loadRevisionData'](_0x65ddb1,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x65ddb1);}async['compare'](_0x2ea771,_0x4f3942,_0x32675a=!0x1){if(!this['isEnabled'])return;const _0x23a735=this['diff'],_0x1c5c5f=this['repository'],_0x3f6a2b='string'==typeof _0x2ea771?_0x1c5c5f['getRevision'](_0x2ea771):_0x2ea771,_0x36cddc='string'==typeof _0x4f3942?_0x1c5c5f['getRevision'](_0x4f3942):_0x4f3942,_0x49c6cb=_0x3f6a2b['id'],_0x2e9ac2=_0x36cddc?_0x36cddc['id']:null;if(!_0x32675a&&this['diff']&&this['diff']['newRevisionId']===_0x49c6cb&&this['diff']['oldRevisionId']===_0x2e9ac2)return Promise['resolve']();this['isReady']=!0x1,this['activeView']=null,this['activeChange']=null,this['diff']=new c(_0x49c6cb,_0x2e9ac2);const _0x3c3352=this['_getRevisionsRange'](_0x3f6a2b,_0x36cddc,!0x0)['map'](_0x42fd8f=>this['_utils']['loadRevisionData'](_0x42fd8f,this['adapter']));return _0x3c3352['push'](new Promise(_0x1c518a=>{setTimeout(_0x1c518a,0x14);})),Promise['all'](_0x3c3352)['then'](()=>{if(!this['isEnabled'])return;this['_cleanUp']();const _0x25502b=this['_getDiff'](_0x49c6cb,_0x2e9ac2);for(const _0x3e99de of _0x25502b['changes'])this['_changeIdToChange']['set'](_0x3e99de['id'],_0x3e99de);this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x284bfd=>{for(const _0x4c733b of this['editor']['model']['document']['getRootNames']())_0x284bfd['detachRoot'](_0x4c733b);for(const _0x248be8 of Object['keys'](_0x25502b['model'])){const _0x47bfbe=_0x284bfd['addRoot'](_0x248be8);for(const _0x3f7b1b of Object['keys'](_0x25502b['attributes'][_0x248be8]))_0x284bfd['setAttribute'](_0x3f7b1b,_0x25502b['attributes'][_0x248be8][_0x3f7b1b],_0x47bfbe);_0x284bfd['insert'](_0x25502b['model'][_0x248be8],_0x47bfbe,0x0);}}),this['diff']['_setChanges'](this['_sortAndFilterDiffChanges'](_0x25502b['changes'])),this['isReady']=!0x0;})['catch'](_0x326f0f=>{console['error'](_0x326f0f),this['_cleanUp'](),_0x23a735&&(this['diff']=_0x23a735),this['isReady']=!0x0;});}['addRevisionData'](_0x4a3736,_0x15f144){const _0x3caa5e=this['repository']['createRevision'](_0x4a3736);return _0x3caa5e['on']('_update',(_0xf68382,_0x53cda8,_0x481346)=>_0x15f144(_0x53cda8,_0x481346,_0x3caa5e)),this['repository']['addRevision'](_0x3caa5e),_0x3caa5e;}['_cleanUp'](){this['activeChange']=null,this['_cleanMarkers'](),this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=null,this['_changeIdToChange']['clear'](),this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0xb73680=>{for(const _0x52b0d5 of this['editor']['model']['document']['getRootNames']())_0xb73680['detachRoot'](_0x52b0d5);});}['_sortAndFilterDiffChanges'](_0x347f32){const _0x352d5c=[],_0x50e60d=new Map();for(const _0x4d0089 of this['editor']['model']['document']['getRootNames']()){const _0x4f9d27=this['editor']['editing']['view']['getDomRoot'](_0x4d0089);if(!_0x4f9d27)continue;const _0x5cad2f=_0x4f9d27['getClientRects']()['item'](0x0);_0x5cad2f&&(_0x352d5c['push'](_0x4d0089),_0x50e60d['set'](_0x4d0089,_0x5cad2f));}return _0x352d5c['sort']((_0xc72860,_0x532688)=>{const _0x749d5c=_0x50e60d['get'](_0xc72860),_0x38064f=_0x50e60d['get'](_0x532688);return _0x749d5c['y']-_0x38064f['y']||_0x749d5c['x']-_0x38064f['x'];}),(_0x347f32=_0x347f32['filter'](_0x2bbe62=>_0x352d5c['includes'](_0x2bbe62['rootName'])))['sort']((_0x3255eb,_0x362d65)=>_0x352d5c['indexOf'](_0x3255eb['rootName'])-_0x352d5c['indexOf'](_0x362d65['rootName'])),_0x347f32;}['_makeTape'](_0x4dd0c0){const _0x479885=Array['from'](_0x4dd0c0['markers'])['filter'](([_0x64635c,_0x3b4573])=>_0x64635c['startsWith']('revision:')&&!_0x3b4573['isCollapsed']),_0x39b64b=Array['from'](this['editor']['model']['createRangeIn'](_0x4dd0c0)['getWalker']({'singleCharacters':!0x0}));if(0x0!=_0x479885['length'])for(const _0x28f599 of _0x39b64b){const [_0x181944,_0x573daf]=_0x479885[0x0],[,_0x5dc3ed,_0x206ed6]=_0x181944['split'](':');if(_0x573daf['end']['isEqual'](_0x28f599['nextPosition'])&&_0x479885['shift'](),(_0x28f599['previousPosition']['isEqual'](_0x573daf['start'])||_0x28f599['previousPosition']['isAfter'](_0x573daf['start']))&&('insertion'==_0x5dc3ed?_0x28f599['isAdded']={'userId':_0x206ed6}:'deletion'==_0x5dc3ed&&(_0x28f599['isRemoved']={'userId':_0x206ed6})),0x0==_0x479885['length'])break;}return _0x39b64b;}['_refreshStartEndIndex'](_0x5f4aa5){const _0x4370ec=new Map();for(let _0x4b92ba=0x0;_0x4b92ba<_0x5f4aa5['length'];_0x4b92ba++)'text'===_0x5f4aa5[_0x4b92ba]['type']?(_0x5f4aa5[_0x4b92ba]['item']['startIndex']=_0x4b92ba,_0x5f4aa5[_0x4b92ba]['item']['endIndex']=_0x4b92ba):('elementStart'===_0x5f4aa5[_0x4b92ba]['type']?_0x5f4aa5[_0x4b92ba]['item']['startIndex']=_0x4b92ba:'elementEnd'===_0x5f4aa5[_0x4b92ba]['type']&&(_0x5f4aa5[_0x4b92ba]['item']['endIndex']=_0x4b92ba),_0x4370ec['set'](_0x5f4aa5[_0x4b92ba]['id'],_0x4b92ba));for(const _0x1ae1fd of _0x4370ec['values']())'elementStart'===_0x5f4aa5[_0x1ae1fd]['type']?_0x5f4aa5[_0x1ae1fd]['item']['endIndex']=_0x4370ec['get'](_0x5f4aa5[_0x1ae1fd]['pairId']):'elementEnd'===_0x5f4aa5[_0x1ae1fd]['type']&&(_0x5f4aa5[_0x1ae1fd]['item']['startIndex']=_0x4370ec['get'](_0x5f4aa5[_0x1ae1fd]['pairId']));}['_processTape'](_0x4d3711){for(let _0x5837b7=0x0;_0x5837b7<_0x4d3711['length'];_0x5837b7++){if('elementStart'===_0x4d3711[_0x5837b7]['type'])_0x4d3711[_0x5837b7]['item']['startIndex']=_0x5837b7;else{if('elementEnd'===_0x4d3711[_0x5837b7]['type']){_0x4d3711[_0x5837b7]['item']['endIndex']=_0x5837b7;const _0x5cab39=_0x4d3711[_0x5837b7]['item']['startIndex'];_0x4d3711[_0x5cab39]['pairId']=_0x4d3711[_0x5837b7]['id'],_0x4d3711[_0x5837b7]['pairId']=_0x4d3711[_0x5cab39]['id'];}else _0x4d3711[_0x5837b7]['item']['startIndex']=_0x5837b7,_0x4d3711[_0x5837b7]['item']['endIndex']=_0x5837b7,_0x4d3711[_0x5837b7]['pairId']=null;}_0x4d3711[_0x5837b7]['markersStart']||(_0x4d3711[_0x5837b7]['markersStart']=[],_0x4d3711[_0x5837b7]['markersEnd']=[]);}}['_markInsertions'](_0xa54b0e,_0xa80ac3){const _0x524bc0=_0xa54b0e['filter'](_0x33cefa=>!_0x33cefa['isAdded']);for(let _0x2d3e9e=0x0;_0x2d3e9e<_0xa80ac3['length'];_0x2d3e9e++)_0xa80ac3[_0x2d3e9e]['isAdded']&&(_0x524bc0[_0x2d3e9e]['isAdded']=_0xa80ac3[_0x2d3e9e]['isAdded']);}['_getDiff'](_0x16a9e1,_0x3751c4=null){const _0x4697e1=this['repository']['getRevision'](_0x16a9e1),_0x1fb0c4=_0x3751c4?this['repository']['getRevision'](_0x3751c4):null,_0x24d78f=this['_getRevisionsRange'](_0x4697e1,_0x1fb0c4),_0x3e857e=_0x24d78f[_0x24d78f['length']-0x1],_0x196f9b=new Map(),_0x2f55a3={'model':{},'attributes':{},'changes':[]},_0x4d2514=new Set(),_0x4392b1=new Map();for(let _0x455c49=_0x24d78f['length']-0x1;_0x455c49>=0x0;_0x455c49--){const _0x3247e4=_0x24d78f[_0x455c49];for(const _0x3b15f0 of Object['keys'](_0x3247e4['diffData']))if(_0x3247e4['diffData'][_0x3b15f0]['attachChange']){const _0x3fa5b6=_0x3247e4['diffData'][_0x3b15f0]['attachChange'];_0x3fa5b6['isAttached']?(_0x4d2514['add'](_0x3b15f0),_0x4392b1['has'](_0x3b15f0)&&_0x4392b1['get'](_0x3b15f0)['userId']==_0x3fa5b6['userId']?_0x4392b1['delete'](_0x3b15f0):_0x4392b1['set'](_0x3b15f0,_0x3fa5b6)):_0x4392b1['has'](_0x3b15f0)?(_0x4d2514['delete'](_0x3b15f0),_0x4392b1['delete'](_0x3b15f0)):(_0x4d2514['add'](_0x3b15f0),_0x4392b1['set'](_0x3b15f0,_0x3fa5b6));}else _0x4d2514['add'](_0x3b15f0);}for(const _0x48e514 of _0x4d2514){const _0x5c29c1=_0x4392b1['has'](_0x48e514)&&!_0x4392b1['get'](_0x48e514)['isAttached'];let _0x18a6ce=_0x5c29c1?_0x24d78f['length']-0x1:0x0;const _0x2ea464=_0x5c29c1?-0x1:0x1;for(;_0x24d78f[_0x18a6ce];){const _0x35d414=_0x24d78f[_0x18a6ce];if(_0x35d414['diffData'][_0x48e514]){const _0x401f30=_0x5c29c1?_0x35d414['diffData'][_0x48e514]['attributesBefore']:_0x35d414['diffData'][_0x48e514]['attributesAfter'];_0x2f55a3['attributes'][_0x48e514]=_0x401f30?_0x4631d1(_0x401f30):{};break;}_0x18a6ce+=_0x2ea464;}}for(const _0x5c796c of _0x24d78f){_0x5c796c['model']={};for(const _0x4e263f of _0x5c796c['authors'])_0x196f9b['set'](_0x4e263f['id'],_0x4e263f);for(const _0x5e8300 of _0x4d2514){const _0x3fe813=_0x5c796c['diffData'][_0x5e8300]?_0x5c796c['diffData'][_0x5e8300]['insertions']:'[]',_0x17a49c=_0x5c796c['diffData'][_0x5e8300]?_0x5c796c['diffData'][_0x5e8300]['deletions']:'[]';_0x5c796c['model'][_0x5e8300]={'insertions':this['_utils']['_makeModelFromViewString'](_0x3fe813),'deletions':this['_utils']['_makeModelFromViewString'](_0x17a49c)};}}for(const _0x9d9a36 of _0x4d2514){let _0x461c7b=null,_0x16c6c9=0x0;const _0xe8d7a2=new Map(Array['from'](_0x4697e1['model'][_0x9d9a36]['insertions']['markers'])['filter'](([_0xf6ea33])=>!_0xf6ea33['startsWith']('revision:')));let _0x3c79f6=0x0;for(const _0x4d644f of _0x24d78f){const _0x223c9d=this['_makeTape'](_0x4d644f['model'][_0x9d9a36]['insertions']);_0x4d644f==_0x4697e1?(_0x461c7b=_0x223c9d,_0x16c6c9=_0x461c7b['length'],_0x461c7b['forEach'](_0x2338dc=>{_0x2338dc['id']=_0x3c79f6++;}),this['_processTape'](_0x461c7b)):this['_markInsertions'](_0x461c7b,_0x223c9d);const _0x11b278=_0x461c7b['filter'](_0x1c1134=>!_0x1c1134['isAdded'])['map'](_0x6f8c2f=>_0x6f8c2f['id']);let _0x123392=0x0;const _0xd123a8=this['_makeTape'](_0x4d644f['model'][_0x9d9a36]['deletions']);_0xd123a8['forEach'](_0x43377f=>{_0x43377f['isRemoved']?_0x43377f['id']=_0x16c6c9++:_0x43377f['id']=_0x11b278[_0x123392++];}),this['_processTape'](_0xd123a8),this['_setDistance'](_0x461c7b,'isAdded'),this['_setDistance'](_0xd123a8,'isRemoved'),_0x4d644f==_0x4697e1&&this['_markMarkers'](_0x461c7b,_0xe8d7a2),_0x461c7b=this['_joinTapes'](_0x461c7b,_0xd123a8),this['_refreshStartEndIndex'](_0x461c7b),this['_setDistance'](_0x461c7b,'isRemoved');}_0x461c7b=_0x461c7b['filter'](_0x1300b5=>!(_0x1300b5['isAdded']&&_0x1300b5['isRemoved']));const _0x51da43=new Map(_0x3e857e['model'][_0x9d9a36]['deletions']['markers']),_0x30672b=new Set(_0xe8d7a2['keys']());for(const _0x5453c8 of _0x51da43['keys']())_0x30672b['delete'](_0x5453c8);this['_markSuggestions'](_0x461c7b,_0x30672b),this['_fixObsoleteTags'](_0x461c7b),_0x461c7b=this['_removeMissingPairs'](_0x461c7b),_0x461c7b=this['_markMismatchedRemovedTags'](_0x461c7b),_0x461c7b=this['_removeUnsupportedChanges'](_0x461c7b);const {root:_0x12355d,changes:_0x58297a}=this['_makeModelFromTape'](_0x461c7b,_0x196f9b,_0x9d9a36);_0x2f55a3['model'][_0x9d9a36]=_0x12355d;const _0x1e6588=_0x4392b1['get'](_0x9d9a36);if(_0x1e6588){const _0x301e89=_0x196f9b['get'](_0x1e6588['userId']),_0x415e5a=new r({'author':_0x301e89,'type':_0x1e6588['isAttached']?'add':'remove','data':{'isOnRoot':!0x0},'createdAt':new Date(),'rootName':_0x9d9a36});_0x58297a['unshift'](_0x415e5a),_0x2f55a3['attributes'][_0x9d9a36]['revisionHistoryAttachChange']=_0x415e5a['id'];}_0x2f55a3['changes']=_0x2f55a3['changes']['concat'](_0x58297a);}return _0x2f55a3;}['_markMarkers'](_0xf5fbde,_0x4c8392){for(let _0x601fa7=0x0;_0x601fa7<_0xf5fbde['length'];_0x601fa7++)for(const [_0x54c76c,_0x34846b]of _0x4c8392)!_0x34846b['isCollapsed']&&_0x34846b['start']['isEqual'](_0xf5fbde[_0x601fa7]['previousPosition'])&&_0xf5fbde[_0x601fa7]['markersStart']['push'](_0x54c76c),_0x34846b['end']['isEqual'](_0xf5fbde[_0x601fa7]['nextPosition'])&&_0xf5fbde[_0x601fa7]['markersEnd']['push'](_0x54c76c);}['_joinTapes'](_0x678cd5,_0x3d75f7){let _0x17628a=[],_0x53644c=0x0,_0x13572a=0x0;for(;_0x53644c<_0x678cd5['length']||_0x13572a<_0x3d75f7['length'];){const _0x283472=_0x678cd5[_0x53644c]||{},_0x4638c9=_0x3d75f7[_0x13572a]||{};if(_0x283472['id']==_0x4638c9['id'])_0x53644c++,_0x13572a++,_0x17628a['push'](_0x283472);else{if(_0x4638c9['isRemoved']&&_0x283472['isAdded']){const {commonTape:_0x4a0255,iEnd:_0x2ab6f7,jEnd:_0x2cd7c9}=this['_threeWayMerge'](_0x678cd5,_0x53644c,_0x3d75f7,_0x13572a);_0x17628a=_0x17628a['concat'](_0x4a0255),_0x53644c=_0x2ab6f7,_0x13572a=_0x2cd7c9;}else _0x4638c9['isRemoved']?(_0x13572a++,_0x17628a['push'](_0x4638c9)):(_0x53644c++,_0x17628a['push'](_0x283472));}}return _0x17628a;}['_markSuggestions'](_0x4d647f,_0x1864ad){const _0x517de2=[];for(let _0x3be6a3=0x0;_0x3be6a3<_0x4d647f['length'];_0x3be6a3++){for(let _0xeb4fc1=0x0;_0xeb4fc1<_0x4d647f[_0x3be6a3]['markersStart']['length'];_0xeb4fc1++){const _0x5f2356=_0x4d647f[_0x3be6a3]['markersStart'][_0xeb4fc1];if(!_0x1864ad['has'](_0x5f2356))continue;const {group:_0x39dbcd,type:_0x150088,authorId:_0x10e96c}=_0x159e23(_0x5f2356);'revision-suggestion'!=_0x39dbcd||'insertion'!=_0x150088&&'deletion'!=_0x150088||(_0x517de2['unshift']({'type':_0x150088,'name':_0x5f2356,'userId':_0x10e96c}),_0x4d647f[_0x3be6a3]['markersStart']['splice'](_0xeb4fc1,0x1),_0xeb4fc1--);}_0x42cd22(_0x4d647f[_0x3be6a3]);for(let _0x16e2dc=0x0;_0x16e2dc<_0x4d647f[_0x3be6a3]['markersEnd']['length'];_0x16e2dc++){const _0x24c1ae=_0x4d647f[_0x3be6a3]['markersEnd'][_0x16e2dc];if(!_0x1864ad['has'](_0x24c1ae))continue;const {group:_0x134331,type:_0x43581c}=_0x159e23(_0x24c1ae);if('revision-suggestion'!=_0x134331||'insertion'!=_0x43581c&&'deletion'!=_0x43581c)continue;_0x4d647f[_0x3be6a3]['markersEnd']['splice'](_0x16e2dc,0x1),_0x16e2dc--;const _0x583463=_0x517de2['findIndex'](_0x1f180d=>_0x1f180d['name']==_0x24c1ae);_0x583463>-0x1&&_0x517de2['splice'](_0x583463,0x1);}}function _0x159e23(_0x392302){const _0x5b3888=_0x392302['split'](':');return{'group':_0x5b3888[0x0],'type':_0x5b3888[0x1],'subType':_0x5b3888['length']>=0x5?_0x5b3888[0x2]:null,'id':_0x5b3888['length']<0x5?_0x5b3888[0x2]:_0x5b3888[0x3],'authorId':_0x5b3888['length']<0x5?_0x5b3888[0x3]:_0x5b3888[0x4],'markerCount':0x6==_0x5b3888['length']?_0x5b3888[0x5]:null};}function _0x42cd22(_0x3d3070){for(let _0x163a92=0x0;_0x163a92<_0x517de2['length'];_0x163a92++){if(_0x3d3070['isAdded']&&'insertion'==_0x517de2[_0x163a92]['type'])return _0x3d3070['isAddSuggestion']=_0x517de2[_0x163a92],void delete _0x3d3070['isAdded'];if(!_0x3d3070['isAdded']&&!_0x3d3070['isRemoved']&&'deletion'==_0x517de2[_0x163a92]['type'])return void(_0x3d3070['isRemoveSuggestion']=_0x517de2[_0x163a92]);}}}['_setDistance'](_0x5c7538,_0x2ada06){let _0x291d36=0x0,_0x20ec5d=!0x1;const _0x1662c9=new Map();for(const _0x4e6cd0 of _0x5c7538)_0x4e6cd0[_0x2ada06]?_0x20ec5d&&(_0x291d36++,_0x20ec5d=!0x1):(_0x291d36++,_0x20ec5d=!0x0),_0x1662c9['set'](_0x4e6cd0['id'],_0x291d36);for(let _0x30ccaa=0x0;_0x30ccaa<_0x5c7538['length'];_0x30ccaa++){if('isRemoved'==_0x2ada06&&_0x5c7538[_0x30ccaa]['isAdded']||'isAdded'==_0x2ada06&&_0x5c7538[_0x30ccaa]['isRemoved'])continue;if('text'==_0x5c7538[_0x30ccaa]['type']){_0x5c7538[_0x30ccaa]['distance']=0x0;continue;}const _0x178e4d=_0x1662c9['get'](_0x5c7538[_0x30ccaa]['pairId']),_0x18fea5=_0x1662c9['get'](_0x5c7538[_0x30ccaa]['id']);_0x5c7538[_0x30ccaa]['distance']=_0x178e4d-_0x18fea5;}}['_getRevisionsRange'](_0x500da3,_0x59a532,_0x317da8=!0x1){const _0x388bc0=[];let _0x255425=this['repository']['getIndex'](_0x500da3),_0x1689c3=this['repository']['getIndex'](_0x59a532);for(-0x1==_0x1689c3&&(_0x1689c3=this['repository']['_revisions']['length'],_0x317da8=!0x1);_0x255425<_0x1689c3;)_0x388bc0['push'](this['repository']['getRevision'](_0x255425)),_0x255425++;return _0x317da8&&_0x388bc0['push'](this['repository']['getRevision'](_0x255425)),_0x388bc0;}['_threeWayMerge'](_0x4c8848,_0x37fec8,_0xee659b,_0x50027e){const _0x377b2f=this['editor']['model']['schema'];let _0x481427=_0x37fec8;for(;_0x4c8848[_0x481427]&&_0x4c8848[_0x481427]['isAdded'];)_0x481427++;let _0x55c812=_0x50027e;for(;_0xee659b[_0x55c812]&&_0xee659b[_0x55c812]['isRemoved'];)_0x55c812++;_0x3f751d(_0x4c8848,_0x37fec8,_0x481427),_0x3f751d(_0xee659b,_0x50027e,_0x55c812);const _0x16ba5a=_0xee659b['slice'](_0x50027e,_0x55c812)['concat'](_0x4c8848['slice'](_0x37fec8,_0x481427));return _0x16ba5a['sort']((_0x15ae4c,_0x42a43f)=>_0x15ae4c['side']!=_0x42a43f['side']?_0x15ae4c['side']-_0x42a43f['side']:_0x15ae4c['level']!=_0x42a43f['level']?_0x15ae4c['level']-_0x42a43f['level']:_0x15ae4c['distance']!=_0x42a43f['distance']?_0x42a43f['distance']-_0x15ae4c['distance']:!!_0x15ae4c['isAdded']!=!!_0x42a43f['isAdded']?-0x1==_0x15ae4c['side']||0x0==_0x15ae4c['side']?_0x15ae4c['isAdded']?-0x1:0x1:_0x15ae4c['isAdded']?0x1:-0x1:_0x15ae4c['index']-_0x42a43f['index']),{'commonTape':_0x16ba5a,'iEnd':_0x481427,'jEnd':_0x55c812};function _0x3f751d(_0x12fb49,_0x3346e1,_0x58084e){let _0xe88cca=-0x1,_0x4505ef=Number['POSITIVE_INFINITY'],_0x134680=!0x0;for(let _0x454f08=_0x3346e1;_0x454f08<_0x58084e;_0x454f08++)if(_0x377b2f['isInline'](_0x12fb49[_0x454f08]['item'])||(_0x134680=!0x1),_0x12fb49[_0x454f08]['item']['startIndex']<_0x3346e1&&(_0xe88cca=_0x454f08),_0x12fb49[_0x454f08]['item']['endIndex']>=_0x58084e){_0x4505ef=_0x454f08;break;}_0x134680&&(_0xe88cca=_0x58084e-0x1);for(let _0x41c564=_0x3346e1;_0x41c564<_0x58084e;_0x41c564++)_0x12fb49[_0x41c564]['side']=_0x41c564<=_0xe88cca?-0x1:_0x41c564<_0x4505ef?0x0:0x1,_0x12fb49[_0x41c564]['index']=_0x41c564;let _0x3febb5=0x0;for(let _0x299568=_0x3346e1;_0x299568<=_0xe88cca;_0x299568++)0x0==_0x12fb49[_0x299568]['distance']?_0x12fb49[_0x299568]['level']=_0x3febb5:(_0x3febb5++,_0x12fb49[_0x299568]['level']=_0x3febb5,_0x3febb5++);for(let _0x2e1491=_0x3346e1;_0x2e1491<_0x58084e;_0x2e1491++)0x0==_0x12fb49[_0x2e1491]['side']&&(_0x12fb49[_0x2e1491]['level']=_0x3febb5);_0x3febb5=0x0;for(let _0x33dcb6=_0x58084e-0x1;_0x33dcb6>=_0x4505ef;_0x33dcb6--)0x0==_0x12fb49[_0x33dcb6]['distance']?_0x12fb49[_0x33dcb6]['level']=_0x3febb5:(_0x3febb5--,_0x12fb49[_0x33dcb6]['level']=_0x3febb5,_0x3febb5--);}}['_fixObsoleteTags'](_0x4abf68){const _0x136067=new Map(),_0x5f2351=this['editor']['model']['schema'];for(let _0x6ec5f0=0x1;_0x6ec5f0<_0x4abf68['length'];_0x6ec5f0++){let _0x2d272d,_0x3c2c3f,_0x30307c;const _0x256f89=_0x4abf68[_0x6ec5f0],_0x3f1477=_0x4abf68[_0x6ec5f0-0x1];if('text'==_0x256f89['type'])continue;if(_0x256f89['type']!=_0x3f1477['type'])continue;if(!_0x5f2351['isBlock'](_0x3f1477['item'])||_0x5f2351['isLimit'](_0x3f1477['item']))continue;if(!_0x5f2351['isBlock'](_0x256f89['item'])||_0x5f2351['isLimit'](_0x256f89['item']))continue;if((_0x4abf68[_0x6ec5f0]['isAdded']||_0x4abf68[_0x6ec5f0]['isAddSuggestion'])&&_0x4abf68[_0x6ec5f0-0x1]['isRemoved'])_0x2d272d=_0x4abf68[_0x6ec5f0],_0x3c2c3f=_0x4abf68[_0x6ec5f0-0x1],_0x30307c=_0x6ec5f0-0x1;else{if(!_0x4abf68[_0x6ec5f0]['isRemoved']||!_0x4abf68[_0x6ec5f0-0x1]['isAdded']&&!_0x4abf68[_0x6ec5f0-0x1]['isAddSuggestion'])continue;_0x2d272d=_0x4abf68[_0x6ec5f0-0x1],_0x3c2c3f=_0x4abf68[_0x6ec5f0],_0x30307c=_0x6ec5f0;}const _0xc64b65=_0x2d272d['level']==_0x3c2c3f['level'],_0x50eb40=Math['abs'](_0x2d272d['level'])<Math['abs'](_0x3c2c3f['level'])&&0x0==_0x3c2c3f['distance'];(_0xc64b65||_0x50eb40)&&(_0x136067['set'](_0x3c2c3f['id'],_0x2d272d['id']),_0x4abf68['splice'](_0x30307c,0x1),_0x6ec5f0--,_0x2d272d['isAdded']=!0x1);}for(let _0xc00f8=0x0;_0xc00f8<_0x4abf68['length'];_0xc00f8++)_0x136067['has'](_0x4abf68[_0xc00f8]['pairId'])&&(_0x4abf68[_0xc00f8]['pairId']=_0x136067['get'](_0x4abf68[_0xc00f8]['pairId']));}['_removeMissingPairs'](_0x5232ed){const _0x2d8d93=new Set(_0x5232ed['map'](_0x14d0d6=>_0x14d0d6['id']));for(let _0x49c017=0x0;_0x49c017<_0x5232ed['length'];_0x49c017++)_0x2d8d93['has'](_0x5232ed[_0x49c017]['pairId'])||0x0==_0x5232ed[_0x49c017]['distance']||(_0x5232ed[_0x49c017]['isIncorrect']=!0x0);return _0x5232ed['filter'](_0x2a4791=>!_0x2a4791['isIncorrect']);}['_markMismatchedRemovedTags'](_0x4a10b8){const _0x51be04=new Set();for(let _0xeb1946=0x0;_0xeb1946<_0x4a10b8['length'];_0xeb1946++){if(_0x51be04['has'](_0x4a10b8[_0xeb1946]['id'])&&_0x4a10b8[_0xeb1946]['isRemoved']&&(_0x4a10b8[_0xeb1946]['isIncorrect']=!0x0),_0x4a10b8[_0xeb1946]['isIncorrect'])continue;if(0x0==_0x4a10b8[_0xeb1946]['distance'])continue;if('elementStart'!=_0x4a10b8[_0xeb1946]['type'])continue;if(null==_0x4a10b8[_0xeb1946]['pairId'])continue;let _0x53826c=_0xeb1946+0x1,_0x38c4fc=0x0;for(;_0x4a10b8[_0x53826c]['id']!=_0x4a10b8[_0xeb1946]['pairId'];)'elementStart'==_0x4a10b8[_0x53826c]['type']?_0x38c4fc++:'elementEnd'==_0x4a10b8[_0x53826c]['type']&&_0x38c4fc--,_0x53826c++;if(0x0!=_0x38c4fc){if(_0x4a10b8[_0xeb1946]['isRemoved'])_0x4a10b8[_0xeb1946]['isIncorrect']=!0x0;else{for(;_0x53826c!=_0xeb1946;)_0x4a10b8[_0x53826c]['isRemoved']&&0x0!=_0x4a10b8[_0x53826c]['distance']&&(_0x4a10b8[_0x53826c]['isIncorrect']=!0x0,_0x51be04['add'](_0x4a10b8[_0x53826c]['pairId'])),_0x53826c--;}}}return _0x4a10b8['filter'](_0x2f972a=>!_0x2f972a['isIncorrect']);}['_removeUnsupportedChanges'](_0x996ad2){const _0x26f1cf=this['editor']['model']['schema'];for(let _0x4151cf=0x0;_0x4151cf<_0x996ad2['length'];_0x4151cf++){if(!(_0x996ad2[_0x4151cf]['isAdded']||_0x996ad2[_0x4151cf]['isAddSuggestion']||_0x996ad2[_0x4151cf]['isRemoved']||_0x996ad2[_0x4151cf]['isRemoveSuggestion']))continue;if(0x0==_0x996ad2[_0x4151cf]['distance'])continue;const _0x1cfe60=_0x996ad2[_0x4151cf]['item'];_0x26f1cf['isBlock'](_0x1cfe60)||_0x26f1cf['isLimit'](_0x1cfe60)||(_0x996ad2[_0x4151cf]['isAdded']&&delete _0x996ad2[_0x4151cf]['isAdded'],_0x996ad2[_0x4151cf]['isAddSuggestion']&&delete _0x996ad2[_0x4151cf]['isAddSuggestion'],_0x996ad2[_0x4151cf]['isRemoveSuggestion']&&delete _0x996ad2[_0x4151cf]['isRemoveSuggestion'],_0x996ad2[_0x4151cf]['isRemoved']&&(_0x996ad2[_0x4151cf]['isIncorrect']=!0x0));}return _0x996ad2['filter'](_0x3ae12a=>!_0x3ae12a['isIncorrect']);}['_makeModelFromTape'](_0x1e10ae,_0x59f2d2,_0x439ccc){const _0x14f86e=new gt(),_0x9b033=[],_0x55308a=new Map(),_0x416549=this['editor']['model'],_0x3d8474=_0x416549['schema'],_0x179221=[_0x14f86e],_0x25eb01={},_0x4fd70f={'isAdded':[],'isRemoved':[],'isAddSuggestion':[],'isRemoveSuggestion':[]};let _0x419517=null;const _0x4df2e5=[0x0];for(let _0x338640=0x0;_0x338640<_0x1e10ae['length'];_0x338640++)if('elementStart'===_0x1e10ae[_0x338640]['type']){_0x1e10ae[_0x338640]['previousPosition']=_0x416549['createPositionFromPath'](_0x14f86e,_0x4df2e5);const _0x2d928a=new ut(_0x1e10ae[_0x338640]['item']['name'],_0x1e10ae[_0x338640]['item']['getAttributes']());_0x179221[0x0]['_appendChild'](_0x2d928a),_0x4df2e5['push'](0x0),_0x179221['unshift'](_0x2d928a),_0x1e10ae[_0x338640]['nextPosition']=_0x416549['createPositionFromPath'](_0x14f86e,_0x4df2e5);}else'elementEnd'===_0x1e10ae[_0x338640]['type']?(_0x179221['shift'](),_0x1e10ae[_0x338640]['previousPosition']=_0x416549['createPositionFromPath'](_0x14f86e,_0x4df2e5),_0x4df2e5['pop'](),_0x4df2e5[_0x4df2e5['length']-0x1]++,_0x1e10ae[_0x338640]['nextPosition']=_0x416549['createPositionFromPath'](_0x14f86e,_0x4df2e5)):(_0x1e10ae[_0x338640]['previousPosition']=_0x416549['createPositionFromPath'](_0x14f86e,_0x4df2e5),_0x419517?_0x419517['_data']+=_0x1e10ae[_0x338640]['item']['data']:_0x419517=new mt(_0x1e10ae[_0x338640]['item']['data'],_0x1e10ae[_0x338640]['item']['getAttributes']()),_0x1e10ae[_0x338640+0x1]&&'text'===_0x1e10ae[_0x338640+0x1]['type']&&_0x1bec9c(_0x419517,_0x1e10ae[_0x338640+0x1]['item'])||(_0x179221[0x0]['_appendChild'](_0x419517),_0x419517=null),_0x4df2e5[_0x4df2e5['length']-0x1]+=_0x1e10ae[_0x338640]['item']['offsetSize'],_0x1e10ae[_0x338640]['nextPosition']=_0x416549['createPositionFromPath'](_0x14f86e,_0x4df2e5));for(let _0x18c1f5=0x0;_0x18c1f5<_0x1e10ae['length'];_0x18c1f5++){const _0x40f993=_0x1e10ae[_0x18c1f5]['previousPosition'],_0x10a573=_0x1e10ae[_0x18c1f5]['nextPosition'];for(const _0x40dac9 of _0x1e10ae[_0x18c1f5]['markersStart'])_0x55308a['set'](_0x40dac9,{'start':_0x40f993,'end':null});_0x28b80a('isRemoveSuggestion',_0x18c1f5,_0x40f993,_0x10a573),_0x28b80a('isAddSuggestion',_0x18c1f5,_0x40f993,_0x10a573),_0x28b80a('isRemoved',_0x18c1f5,_0x40f993,_0x10a573),_0x28b80a('isAdded',_0x18c1f5,_0x40f993,_0x10a573);for(const _0x4fda35 of _0x1e10ae[_0x18c1f5]['markersEnd']){const _0x877382=_0x55308a['get'](_0x4fda35);_0x877382?_0x877382['end']=_0x10a573:_0x55308a['set'](_0x4fda35,{'start':_0x10a573,'end':_0x10a573});}}for(const [_0x2675cf,_0x3a135d]of _0x55308a){const _0x2c1c55=this['editor']['model']['createRange'](_0x3a135d['start'],_0x3a135d['end']);_0x14f86e['markers']['set'](_0x2675cf,_0x2c1c55);}return _0x9b033['sort']((_0x10598b,_0x40af21)=>{const _0x146196=_0x14f86e['markers']['get']('revision:'+_0x10598b['id']),_0x513253=_0x14f86e['markers']['get']('revision:'+_0x40af21['id']);return _0x146196['start']['isBefore'](_0x513253['start'])?-0x1:_0x146196['start']['isAfter'](_0x513253['start'])?0x1:_0x146196['end']['isBefore'](_0x513253['end'])?-0x1:_0x146196['end']['isAfter'](_0x513253['end'])?0x1:'add'===_0x10598b['type']?-0x1:0x1;}),{'root':_0x14f86e,'changes':_0x9b033};function _0x28b80a(_0x2e69c6,_0x3302ac,_0x4085ec,_0x584ef2){const _0x554b4d=!!_0x1e10ae[_0x3302ac][_0x2e69c6],_0x3a6f6d=_0x554b4d?_0x1e10ae[_0x3302ac][_0x2e69c6]['userId']:null,_0x449fc6=_0x3302ac===_0x1e10ae['length']-0x1,_0x409f76=_0x4fd70f[_0x2e69c6][0x0],_0xf2c491=_0x3d8474['isObject'](_0x1e10ae[_0x3302ac]['item']);!_0x25eb01[_0x2e69c6]&&_0x554b4d?_0x25eb01[_0x2e69c6]={'start':_0x4085ec,'tapeItem':_0x1e10ae[_0x3302ac],'userId':_0x3a6f6d,'type':_0x2e69c6}:_0x25eb01[_0x2e69c6]&&!_0x554b4d?(_0x25eb01[_0x2e69c6]['end']=_0x4085ec,_0x1f17be(_0x25eb01[_0x2e69c6]),_0x25eb01[_0x2e69c6]=null):_0x25eb01[_0x2e69c6]&&_0x554b4d&&_0x25eb01[_0x2e69c6]['userId']!==_0x3a6f6d&&(_0x25eb01[_0x2e69c6]['end']=_0x4085ec,_0x409f76&&_0x409f76['userId']===_0x25eb01[_0x2e69c6]['userId']||_0x1f17be(_0x25eb01[_0x2e69c6]),_0x25eb01[_0x2e69c6]={'start':_0x4085ec,'tapeItem':_0x1e10ae[_0x3302ac],'userId':_0x3a6f6d,'type':_0x2e69c6}),_0x25eb01[_0x2e69c6]&&_0xf2c491&&('elementStart'!==_0x1e10ae[_0x3302ac]['type']||_0x409f76&&_0x409f76['userId']===_0x3a6f6d||_0x4fd70f[_0x2e69c6]['unshift']({'userId':_0x3a6f6d,'object':_0x1e10ae[_0x3302ac]['item'],'change':_0x25eb01[_0x2e69c6]}),'elementEnd'===_0x1e10ae[_0x3302ac]['type']&&_0x409f76&&_0x409f76['object']===_0x1e10ae[_0x3302ac]['item']&&(_0x4fd70f[_0x2e69c6]['shift'](),_0x25eb01[_0x2e69c6]=_0x409f76['change'])),_0x25eb01[_0x2e69c6]&&_0x449fc6&&(_0x25eb01[_0x2e69c6]['end']=_0x584ef2,_0x1f17be(_0x25eb01[_0x2e69c6]),_0x25eb01[_0x2e69c6]=null);}function _0x1f17be({start:_0x5dc639,end:_0x2a3091,tapeItem:_0x30fa88,userId:_0x71b333,type:_0x56835f}){const _0x48a00c=_0x30fa88['item'],_0x4d2bf1=_0x416549['schema']['isBlock'](_0x48a00c)&&!_0x416549['schema']['isLimit'](_0x48a00c),_0xf445be=_0x5dc639['nodeAfter']==_0x2a3091['parent']&&_0x2a3091['isAtStart'];if(_0x4d2bf1&&_0xf445be)return;const _0x2d52d0=_0x416549['createRange'](_0x5dc639,_0x2a3091),_0x3c923a=_0x59f2d2['get'](_0x71b333),_0x2f75aa=new r({'author':_0x3c923a,'type':'isAdded'==_0x56835f||'isAddSuggestion'==_0x56835f?'add':'remove','data':{'isSuggestion':'isAddSuggestion'==_0x56835f||'isRemoveSuggestion'==_0x56835f},'createdAt':new Date(),'rootName':_0x439ccc});_0x9b033['push'](_0x2f75aa),_0x14f86e['markers']['set']('revision:'+_0x2f75aa['id'],_0x2d52d0);}function _0x1bec9c(_0x48517a,_0x129422){const _0x2562fa=_0x48517a['getAttributes'](),_0x98b067=_0x129422['getAttributes']();for(const _0xff072c of _0x2562fa){if(_0xff072c[0x1]!==_0x129422['getAttribute'](_0xff072c[0x0]))return!0x1;_0x98b067['next']();}return _0x98b067['next']()['done'];}}['_setConversion'](){this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision','view':_0xa84147=>{const _0x402e07=_0xa84147['markerName']['split'](':')[0x1],_0x129b5b=this['_getChangeFromId'](_0x402e07);if(!_0x129b5b)return null;const _0xec0abc='add'==_0x129b5b['type']?'insertion':'deletion',_0x105ab8=['ck-suggestion-marker','ck-suggestion-marker-'+_0xec0abc];return _0x129b5b['data']['isSuggestion']&&_0x105ab8['push']('ck-suggestion-marker-'+_0xec0abc+'-new'),this['activeChange']==_0x129b5b&&_0x105ab8['push']('ck-suggestion-marker--active'),{'classes':_0x105ab8,'attributes':{'data-change-id':_0x402e07}};}}),this['editor']['conversion']['for']('upcast')['add'](_0x23e779=>{_0x23e779['on']('element:pre',(_0x2eef12,_0xdb44a7,_0x2c5630)=>{const _0x45a3cd=_0xdb44a7['viewItem']['getChild'](0x0);if(!_0x45a3cd||!_0x45a3cd['is']('element','code'))return;if(!_0x2c5630['consumable']['consume'](_0x45a3cd,{'attributes':['vid_start','vid_end']}))return;const _0xbc911b=_0xdb44a7['modelRange']['start']['nodeAfter'];_0x2c5630['writer']['setAttribute']('vid_start',_0x45a3cd['getAttribute']('vid_start'),_0xbc911b),_0x2c5630['writer']['setAttribute']('vid_end',_0x45a3cd['getAttribute']('vid_end'),_0xbc911b);},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['add'](_0x3aec78=>{_0x3aec78['on']('element',(_0x346042,_0x4b09f3,_0x458191)=>{if(!_0x458191['consumable']['consume'](_0x4b09f3['viewItem'],{'attributes':['vid_start','vid_end']}))return;if(_0x4b09f3['modelRange']['isCollapsed'])return;const _0x54b507=_0x4b09f3['modelRange']['start']['nodeAfter'];_0x54b507['hasAttribute']('vid_start')||_0x54b507['hasAttribute']('vid')||(_0x458191['writer']['setAttribute']('vid_start',_0x4b09f3['viewItem']['getAttribute']('vid_start'),_0x54b507),_0x458191['writer']['setAttribute']('vid_end',_0x4b09f3['viewItem']['getAttribute']('vid_end'),_0x54b507));},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['elementToAttribute']({'view':{'name':'span','attributes':{'vid':!0x0}},'model':{'key':'vid','value':_0x277785=>_0x277785['getAttribute']('vid')}}),this['editor']['model']['schema']['on']('checkAttribute',(_0x5dbaac,[,_0x1c8930])=>{['vid_start','vid_end','vid']['includes'](_0x1c8930)&&(_0x5dbaac['return']=!0x0,_0x5dbaac['stop']());},{'priority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x287081=>{_0x287081['on']('attribute:vid',(_0x2f7968,_0x2a7c9f,_0x55aa13)=>{if('\x20'!=_0x2a7c9f['item']['data']||_0x2a7c9f['item']['parent']['maxOffset']>0x1)return;if(!_0x55aa13['consumable']['consume'](_0x2a7c9f['item'],_0x2f7968['name']))return;const _0x4024a8=_0x55aa13['writer'],_0x45e4aa=_0x55aa13['mapper']['toViewRange'](_0x2a7c9f['range']);_0x4024a8['wrap'](_0x45e4aa,_0x4024a8['createAttributeElement']('span'));});}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',function(_0x2fc647){const _0x158bfe=_0x2fc647['plugins']['get']('RevisionViewer');return(_0x981151,_0xef5701,_0x409a2a)=>{const _0x1a5c9b=_0xef5701['markerName']['split'](':')[0x1],_0x4074c5=_0x158bfe['_getChangeFromId'](_0x1a5c9b);if(!_0x4074c5)return null;const _0x5559c0='add'==_0x4074c5['type']?'split':'merge';if(!_0x409a2a['consumable']['test'](_0xef5701['markerRange'],_0x981151['name']))return;const _0x4f203e=_0xef5701['markerRange']['getWalker'](),_0x3b760b=_0xef5701['markerRange']['start'],_0x313667=_0x2fc647['model']['schema'];let _0x39a536=null,_0x2b101a=null,_0x123e17=!0x1,_0x1c9a75=!0x1;for(const _0x3b482d of _0x4f203e){const _0x1a4d38=_0x3b482d['item'];_0x123e17=_0x123e17||_0x313667['isContent'](_0x1a4d38);const _0x29e570=_0x409a2a['mapper']['toViewElement'](_0x1a4d38);if(_0x29e570&&_0x29e570['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x3b482d['type']&&(_0x313667['isBlock'](_0x1a4d38)&&!_0x313667['isLimit'](_0x1a4d38)&&(_0x1a4d38['nextSibling']||_0x3b760b['isAtEnd']?_0x39a536&&_0x39a536['parent']==_0x1a4d38||(_0x39a536=_0x1a4d38,_0x8645fb(_0x3b482d['previousPosition']),_0x1c9a75=!0x0):_0x2b101a=_0x2b101a||_0x3b482d['previousPosition']));}function _0x8645fb(_0x476ed0){const _0x3d2d6a=_0x409a2a['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x5559c0}),_0x2878d5=_0x409a2a['mapper']['toViewPosition'](_0x476ed0);_0x4074c5['data']['isSuggestion']&&_0x409a2a['writer']['addClass']('ck-suggestion-marker-'+_0x5559c0+'-new',_0x3d2d6a),_0x158bfe['activeChange']==_0x4074c5&&_0x409a2a['writer']['addClass']('ck-suggestion-marker--active',_0x3d2d6a),_0x409a2a['writer']['insert'](_0x2878d5,_0x3d2d6a),_0x409a2a['mapper']['bindElementToMarker'](_0x3d2d6a,_0xef5701['markerName']);}_0x123e17||_0x1c9a75||!_0x2b101a||_0x8645fb(_0x2b101a);};}(this['editor']),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision',(_0x440566,_0x5963a5,_0x49d91d)=>{const _0x5e7c83=_0x49d91d['mapper']['markerNameToElements'](_0x5963a5['markerName']);if(_0x5e7c83){for(const _0xf7c2fc of _0x5e7c83)(_0xf7c2fc['hasClass']('ck-suggestion-marker-split')||_0xf7c2fc['hasClass']('ck-suggestion-marker-merge'))&&(_0x49d91d['mapper']['unbindElementFromMarkerName'](_0xf7c2fc,_0x5963a5['markerName']),_0x49d91d['writer']['remove'](_0xf7c2fc));}},{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',(_0x2d7d65,_0xe71063,_0x1cd2df)=>{const _0x91992e=_0xe71063['markerName']['split'](':')[0x1],_0x15da86=this['_getChangeFromId'](_0x91992e);if(!_0x15da86)return null;const _0x364c97='add'==_0x15da86['type']?'split':'merge';if(_0x1cd2df['consumable']['test'](_0xe71063['markerRange'],_0x2d7d65['name']))for(const _0x5922e9 of _0xe71063['markerRange']['getItems']()){if(!_0x5922e9['is']('element','softBreak'))continue;const _0x18729f=_0x1cd2df['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x364c97}),_0x374546=_0x1cd2df['mapper']['toViewPosition'](this['editor']['model']['createPositionBefore'](_0x5922e9));_0x15da86['data']['isSuggestion']&&_0x1cd2df['writer']['addClass']('ck-suggestion-marker-'+_0x364c97+'-new',_0x18729f),this['activeChange']==_0x15da86&&_0x1cd2df['writer']['addClass']('ck-suggestion-marker--active',_0x18729f),_0x1cd2df['writer']['insert'](_0x374546,_0x18729f),_0x1cd2df['mapper']['bindElementToMarker'](_0x18729f,_0xe71063['markerName']);}},{'priority':'high'}),this['editor']['model']['document']['on']('change',()=>{this['editor']['editing']['view']['change'](_0x4b6bd5=>{for(const _0x19d068 of this['editor']['model']['document']['getRootNames']()){const _0x178c3d=this['editor']['model']['document']['getRoot'](_0x19d068),_0x4fecb3=this['editor']['editing']['view']['document']['getRoot'](_0x19d068);if(_0x4fecb3){const _0x5e7f3d=_0x178c3d['getAttribute']('revisionHistoryAttachChange');if(_0x4b6bd5['removeAttribute']('data-change-id',_0x4fecb3),_0x4b6bd5['removeClass']('ck-revision-history-root-add',_0x4fecb3),_0x4b6bd5['removeClass']('ck-revision-history-root-remove',_0x4fecb3),_0x4b6bd5['removeClass']('ck-revision-history-root--active',_0x4fecb3),_0x5e7f3d){const _0x23781e=this['_getChangeFromId'](_0x5e7f3d);if(!_0x23781e)return null;_0x4b6bd5['setAttribute']('data-change-id',_0x5e7f3d,_0x4fecb3),_0x4b6bd5['addClass']('ck-revision-history-root-'+_0x23781e['type'],_0x4fecb3),this['activeChange']==_0x23781e&&_0x4b6bd5['addClass']('ck-revision-history-root--active',_0x4fecb3);}}}});}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'comment','model':_0x13bf4d=>'revision-comment:'+_0x13bf4d,'converterPriority':'highest'}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'suggestion','model':_0x6c6376=>'revision-suggestion:'+_0x6c6376,'converterPriority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision-suggestion','view':_0x135893=>({'name':'suggestion:'+_0x135893,'group':'revision-suggestion'}),'converterPriority':'highest'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision-suggestion','view':_0x7d686f=>{const _0x3af224=_0x7d686f['markerName']['split'](':')[0x1];return'insertion'!=_0x3af224&&'deletion'!=_0x3af224?null:{'classes':['ck-suggestion-preview-marker','ck-suggestion-preview-marker-'+_0x3af224]};}}),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',(_0x57d48f,_0x20cea9,_0x3d14fd)=>{const _0x23f653=_0x3d14fd['mapper']['markerNameToElements'](_0x20cea9['markerName']);if(_0x23f653){for(const _0x545555 of _0x23f653)_0x545555['is']('uiElement')&&(_0x3d14fd['mapper']['unbindElementFromMarkerName'](_0x545555,_0x20cea9['markerName']),_0x3d14fd['writer']['remove'](_0x545555));}},{'priority':'high'});}['_getChangeFromId'](_0x7542e6){return this['_changeIdToChange']['get'](_0x7542e6);}['_getViewForChange'](_0x50c370){return this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=new Q(this['editor']['locale'],_0x50c370),this['_changeView'];}['_initInteractions'](){this['editor']['model']['document']['selection']['observeMarkers']('revision'),this['on']('change:activeView',(_0x32e2b4,_0xb2f11a,_0x14a094,_0x3fa776)=>{_0x3fa776&&this['_balloon']['remove'](_0x3fa776),_0x14a094&&(this['_balloon']['add']({'view':_0x14a094,'stackId':'revisionHistoryLabel','position':{'target':()=>{const _0x58dd9e=this['editor']['editing'],_0x134b7e=this['_getChangeFromId'](_0x14a094['changeId']);let _0x190540;if(_0x134b7e['data']['isOnRoot']){const _0x2d976d=_0x58dd9e['view']['getDomRoot'](_0x134b7e['rootName']);_0x190540=Array['from'](_0x2d976d['getClientRects']());}else{const _0x370184=this['editor']['model']['markers']['get']('revision:'+_0x14a094['changeId']);_0x190540=Array['from'](_0x58dd9e['mapper']['markerNameToElements'](_0x370184['name']))['map'](_0x3ce12f=>_0x58dd9e['view']['domConverter']['mapViewToDom'](_0x3ce12f))['map'](_0x4957a1=>Array['from'](_0x4957a1['getClientRects']()))['flat']();}if(!this['_activeViewTarget'])return _0x190540[0x0];return _0x190540['find'](_0x15da92=>_0x15da92['top']-0x3<=this['_activeViewTarget']['y']&&_0x15da92['bottom']+0x3>=this['_activeViewTarget']['y']&&_0x15da92['left']-0x3<=this['_activeViewTarget']['x']&&_0x15da92['right']+0x3>=this['_activeViewTarget']['x'])||_0x190540[0x0];}}}),this['_balloon']['showStack']('revisionHistoryLabel'));}),this['on']('change:activeChange',(_0x412181,_0x2c737a,_0x30714d,_0x285d6e)=>{this['activeView']=_0x30714d?this['_getViewForChange'](_0x30714d):null,this['editor']['model']['change'](()=>{const _0x4918b3=this['editor']['editing'];_0x285d6e&&(_0x285d6e['data']['isOnRoot']?_0x4918b3['view']['change'](_0x1c3c57=>{_0x1c3c57['removeClass']('ck-revision-history-root--active',_0x4918b3['view']['document']['getRoot'](_0x285d6e['rootName']));}):_0x4918b3['reconvertMarker']('revision:'+_0x285d6e['id'])),_0x30714d&&(_0x30714d['data']['isOnRoot']?_0x4918b3['view']['change'](_0x4f3f02=>{_0x4f3f02['addClass']('ck-revision-history-root--active',_0x4918b3['view']['document']['getRoot'](_0x30714d['rootName']));}):_0x4918b3['reconvertMarker']('revision:'+_0x30714d['id']));});}),this['listenTo'](this['editor']['editing']['view']['document'],'mouseover',(_0x514058,_0x35c6e5)=>{if(this['activeChange'])return;const _0x6a16c4=this['_findChangeIdFromDomTarget'](_0x35c6e5['target']),_0x1230f9=this['_changeIdToChange']['get'](_0x6a16c4);_0x1230f9?(this['_activeViewTarget']={'x':_0x35c6e5['domEvent']['x'],'y':_0x35c6e5['domEvent']['y']},this['activeView']=this['_getViewForChange'](_0x1230f9)):(this['_activeViewTarget']=null,this['activeView']=null);}),this['listenTo'](this['editor']['editing']['view']['document'],'mousedown',(_0x1faed8,_0x426bcf)=>{const _0x47ca72=this['_findChangeIdFromDomTarget'](_0x426bcf['target']),_0x2e4a75=this['_changeIdToChange']['get'](_0x47ca72);_0x2e4a75?(this['_activeViewTarget']={'x':_0x426bcf['domEvent']['x'],'y':_0x426bcf['domEvent']['y']},_0x2e4a75===this['activeChange']?this['_balloon']['updatePosition']():this['activeChange']=_0x2e4a75):(this['_activeViewTarget']=null,this['activeChange']=null);});}['_findChangeIdFromDomTarget'](_0x47511e){do{const _0x263b69=_0x47511e['getAttribute']('data-change-id');if(_0x263b69)return _0x263b69;_0x47511e=_0x47511e['parent'];}while(_0x47511e);return null;}['_cleanMarkers'](){this['editor']['model']['change'](_0x6246c3=>{for(const _0x5f247d of this['editor']['model']['markers'])_0x6246c3['removeMarker'](_0x5f247d);});}}function X(_0x2f95cf,_0x3b961d){return(_0x407239,_0x20af65,_0x89f0a8)=>{if(!_0x89f0a8['consumable']['test'](_0x20af65['markerRange'],_0x407239['name']))return;const _0x218cc1=_0x20af65['markerRange']['getWalker'](),_0x1c03e8=_0x20af65['markerRange']['start'],_0x439731=_0x2f95cf['model']['schema'];let _0xbe7116=null,_0x2b595b=null,_0x2c00ee=!0x1,_0x59c8e0=!0x1;for(const _0x4b639d of _0x218cc1){const _0x31b8b2=_0x4b639d['item'];_0x2c00ee=_0x2c00ee||_0x439731['isContent'](_0x31b8b2);const _0x286b57=_0x89f0a8['mapper']['toViewElement'](_0x31b8b2);if(_0x286b57&&_0x286b57['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x4b639d['type']&&(_0x439731['isBlock'](_0x31b8b2)&&!_0x439731['isLimit'](_0x31b8b2)&&(_0x31b8b2['nextSibling']||_0x1c03e8['isAtEnd']?_0xbe7116&&_0xbe7116['parent']==_0x31b8b2||(_0xbe7116=_0x31b8b2,_0x96a1c0(_0x4b639d['previousPosition']),_0x59c8e0=!0x0):_0x2b595b=_0x2b595b||_0x4b639d['previousPosition']));}function _0x96a1c0(_0x4ac61d){const _0x2c97a6=_0x89f0a8['mapper']['toViewPosition'](_0x4ac61d),_0x3b5099=_0x89f0a8['writer']['createUIElement']('span',{'class':'ck-suggestion-preview-marker-'+_0x3b961d});_0x89f0a8['writer']['insert'](_0x2c97a6,_0x3b5099),_0x89f0a8['mapper']['bindElementToMarker'](_0x3b5099,_0x20af65['markerName']);}_0x2c00ee||_0x59c8e0||!_0x2b595b||_0x96a1c0(_0x2b595b);};}class wt extends _0x206a38{constructor(_0x4df41a){super(_0x4df41a);const _0x2818a9=_0x4df41a['plugins']['get'](m);this['affectsData']=!0x1,this['listenTo'](_0x2818a9,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x2818a9,'change:isEnabled',()=>this['refresh']());}['execute'](){const _0x46c679=this['editor'],_0x47678d=_0x46c679['plugins']['get'](m),_0x3ff15c=_0x47678d['isReady']?_0x47678d['diff']['newRevisionId']:null;_0x46c679['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x3ff15c);}['refresh'](){const {isReady:_0x26c9dd,isEnabled:_0x469ca3,repository:_0x269407,diff:_0x4aea17}=this['editor']['plugins']['get'](m),_0x548914=_0x4aea17&&_0x269407['getLaterVisibleRevision'](_0x4aea17['newRevisionId']);this['isEnabled']=_0x26c9dd&&_0x469ca3&&Boolean(_0x548914);}}class pt extends _0x206a38{['_step'];constructor(_0x461f27,{direction:_0x1ed859}){super(_0x461f27);const _0x4467e2=_0x461f27['plugins']['get'](m);this['affectsData']=!0x1,this['_step']='forward'===_0x1ed859?0x1:-0x1,this['listenTo'](_0x4467e2,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x4467e2,'change:isEnabled',()=>this['refresh']()),this['listenTo'](_0x4467e2,'change:activeChange',()=>this['refresh']());}['execute'](){const _0xfd67c0=this['editor'],_0x546b96=_0xfd67c0['plugins']['get'](m),{isNavigationMode:_0x191223,currentChangeNumber:_0x214d96}=_0x546b96;let _0x10b67b;if(_0x546b96['activeChange']=_0x191223?_0x546b96['diff']['changes']['get'](_0x214d96+this['_step']):_0x546b96['diff']['changes']['first'],_0x546b96['activeChange']['data']['isOnRoot'])_0x10b67b=_0xfd67c0['editing']['view']['getDomRoot'](_0x546b96['activeChange']['rootName']);else{const _0x452479=_0xfd67c0['model']['markers']['get']('revision:'+_0x546b96['activeChange']['id']);_0x10b67b=_0x3238b7(_0xfd67c0['editing'],_0x452479);}_0x27def4({'target':_0x10b67b,'viewportOffset':0x28});}['refresh'](){const {isNavigationMode:_0x5e06d5,currentChangeNumber:_0x2bf319,numberOfChanges:_0x8b0030,isReady:_0x2188f2,isEnabled:_0x2c3a8e}=this['editor']['plugins']['get'](m);this['isEnabled']=!!(_0x2c3a8e&&_0x2188f2&&_0x8b0030)&&(!_0x5e06d5||(0x1===this['_step']?_0x2bf319<_0x8b0030-0x1:_0x2bf319>0x0));}}class _i extends _0x1792c1{constructor(_0x2b9add){super(_0x2b9add);const _0xaf159d=this['bindTemplate'],_0x259db6=new _0x1abc3e(_0x2b9add),_0xa8d7bc=new _0x1abc3e(_0x2b9add);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',(_0x1627b4,_0xc1cf0)=>_0x1627b4&&_0xc1cf0>0x0),this['bind']('_statusText')['to'](this,'isReady',this,'currentChangeNumber',this,'numberOfChanges',this,'isNavigationMode',(_0x5bf9eb,_0xb40fc9,_0x343e27,_0x1e7fb2)=>{if(!_0x5bf9eb)return g(_0x2b9add,'Loading...');if(!_0x343e27)return g(_0x2b9add,'No\x20changes');const _0x6f2e99=g(_0x2b9add,'NUMBER_OF_CHANGES',_0x343e27);return _0x1e7fb2?g(_0x2b9add,'X_OF_Y_CHANGES',[_0xb40fc9+0x1,_0x343e27]):_0x6f2e99;}),_0x259db6['set']({'label':g(_0x2b9add,'Show\x20previous\x20change'),'tooltip':!0x0,'icon':_0x351ec1}),_0xa8d7bc['set']({'label':g(_0x2b9add,'Show\x20next\x20change'),'tooltip':!0x0,'icon':_0x182f02}),_0x259db6['bind']('isEnabled')['to'](this,'isBackwardNavigationEnabled'),_0xa8d7bc['bind']('isEnabled')['to'](this,'isForwardNavigationEnabled'),_0x259db6['on']('execute',()=>this['fire']('execute','backward')),_0xa8d7bc['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',_0xaf159d['if']('_isStatusLabelVisible','ck-hidden',_0x5db455=>!_0x5db455)]},'children':[{'text':_0xaf159d['to']('isNavigationMode',_0x16895a=>_0x16895a?g(_0x2b9add,'EDIT_X_OF_Y_REVISIONS')+':\x20':g(_0x2b9add,'Total')+':\x20')}]},{'text':_0xaf159d['to']('_statusText')}]},new _0xea1f65(),{'tag':'div','attributes':{'class':['ck-revision-history-ui__changes-navigation__navigation']},'children':[_0x259db6,_0xa8d7bc]}]});}}const ee='ck-editor__editable__loading-overlay';class ie extends _0x3f2981{static get['pluginName'](){return'RevisionViewerLoadingOverlay';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['show'](){const _0x267d16=this['editor']['editing']['view'];_0x267d16['change'](_0x410e3d=>{for(const _0x555cf2 of _0x267d16['document']['roots'])_0x410e3d['addClass'](ee,_0x555cf2);});}['hide'](){const _0x32354b=this['editor']['editing']['view'];_0x32354b['change'](_0x9a16f0=>{for(const _0x359bbf of _0x32354b['document']['roots'])_0x9a16f0['removeClass'](ee,_0x359bbf);});}}class R extends _0x3f2981{static get['pluginName'](){return'RevisionViewerUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[m,ie];}['init'](){const _0x44e0f0=this['editor'],_0x12c965=_0x44e0f0['plugins']['get'](m),_0x2ec12a=_0x44e0f0['plugins']['get'](ie);_0x44e0f0['ui']['componentFactory']['add']('exitToEditing',_0x2ed037=>{const _0x4ab295=new _0x1abc3e(_0x2ed037);return _0x4ab295['set']({'label':g(_0x2ed037,'Back\x20to\x20editing'),'icon':te,'withText':!0x0,'tooltip':!0x0,'class':'ck-revision-history-ui__back-to-editing'}),this['listenTo'](_0x4ab295,'execute',()=>{_0x44e0f0['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}),_0x4ab295;}),_0x44e0f0['ui']['componentFactory']['add']('restoreRevision',_0x579002=>{const _0x46f160=new _0x1abc3e(_0x579002);return _0x46f160['set']({'label':g(_0x579002,'Restore\x20this\x20revision'),'withText':!0x0,'tooltip':!0x0}),_0x46f160['bind']('isEnabled')['to'](_0x44e0f0['commands']['get']('restoreRevision')),this['listenTo'](_0x46f160,'execute',()=>_0x44e0f0['execute']('restoreRevision')),_0x46f160;}),_0x44e0f0['ui']['componentFactory']['add']('changesNavigation',_0x1de8f3=>{const _0x2d023e=new _i(_0x1de8f3),_0x32f148=_0x44e0f0['commands']['get']('showPreviousChange'),_0x3227bc=_0x44e0f0['commands']['get']('showNextChange');return _0x2d023e['bind']('isBackwardNavigationEnabled')['to'](_0x32f148,'isEnabled'),_0x2d023e['bind']('isForwardNavigationEnabled')['to'](_0x3227bc,'isEnabled'),_0x2d023e['bind']('isReady','currentChangeNumber','numberOfChanges','isNavigationMode')['to'](_0x12c965),this['listenTo'](_0x2d023e,'execute',(_0x30ba2b,_0x5238ea)=>{_0x44e0f0['execute']('forward'===_0x5238ea?'showNextChange':'showPreviousChange');}),_0x2d023e;}),_0x2ec12a['show'](),_0x12c965['on']('change:isReady',(_0x58d3af,_0x583358,_0x443a83)=>{_0x443a83?_0x2ec12a['hide']():_0x2ec12a['show']();});}}class lt extends nt{['_resizeObserver']=null;constructor(_0x8c56bc,_0x725078){super(_0x8c56bc,_0x725078);const _0x1e240f=this['bindTemplate'];this['set']({'label':g(_0x8c56bc,'Revision\x20name'),'_tooltipString':''}),this['fieldView']['placeholder']=g(_0x8c56bc,'Enter\x20the\x20revision\x20name'),this['extendTemplate']({'tag':'span','attributes':{'class':['ck-revision-history-sidebar__revision-name'],'data-cke-tooltip-text':_0x1e240f['to']('_tooltipString'),'data-cke-tooltip-position':'s','data-cke-tooltip-class':'ck-tooltip_multi-line'}});}['render'](){super['render'](),this['_resizeObserver']=new at(this['fieldView']['element'],()=>this['_updateTooltipText']()),this['listenTo'](this['fieldView'],'input',()=>this['_updateTooltipText']());}['destroy'](){super['destroy'](),this['_resizeObserver']&&this['_resizeObserver']['destroy']();}['_updateTooltipText'](){const _0x3756ff=this['fieldView']['element'];this['_tooltipString']=_0x3756ff['scrollWidth']>_0x3756ff['clientWidth']&&_0x3756ff['value']||'';}}class oi extends _0x1792c1{constructor(_0x20f2c3,_0x5b4650,_0x3f16b0){super(_0x20f2c3);const _0x3f9a21=new _0x184ac0();_0x3f9a21['set']({'content':_0x3b361c,'viewBox':'0\x200\x2011\x2010'});const _0x1dba16=['ck','ck-revision-history-sidebar__revision-author'];_0x3f16b0&&_0x1dba16['push']('ck-revision-history-sidebar__revision-author_creator');const _0x26551f=[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision-author__name'],'title':g(_0x20f2c3,_0x3f16b0?'Revision\x20creator':'Revision\x20author')},'children':[_0x3f9a21,_0x5b4650['name']]}];this['setTemplate']({'tag':'li','attributes':{'class':_0x1dba16},'children':_0x26551f});}}function ni(_0x3dde4a,_0x64f123){const _0x2671f3=_0x3dde4a['bindTemplate'],_0xb15b0=_0x3dde4a['locale'],_0x4c62d4=_0x542f9c(_0xb15b0);_0x4c62d4['panelPosition']='sw';const _0x4ee97f=function(_0x2afec4,_0x28a511){const _0x4dca92=function(_0x5a4ced,_0x2c75fa){const _0xac0116=_0x5a4ced['locale'],_0x221054={'Compare\x20against\x20selected':g(_0xac0116,'Compare\x20against\x20selected'),'Name\x20this\x20revision':g(_0xac0116,'Name\x20this\x20revision'),'Restore\x20this\x20revision':g(_0xac0116,'Restore\x20this\x20revision')};return _0x2c75fa['map'](_0x28bcdd=>{const _0x29d8ac=_0x221054[_0x28bcdd['name']];return _0x29d8ac&&_0x29d8ac!==_0x28bcdd['name']&&(_0x28bcdd['name']=_0x29d8ac),_0x28bcdd;});}(_0x2afec4,_0x28a511),_0x2033ad=new _0x4419cc();for(const _0x10cafd of _0x4dca92){const _0x2b7604={'type':'button','model':new to({'label':_0x10cafd['name'],'class':_0x10cafd['class'],'withText':!0x0,'role':'menuitem','_action':_0x10cafd['action']})};_0x2b7604['model']['bind']('isEnabled')['to'](_0x2afec4,'isActionsDropdownOpen',_0x48faac=>'function'!=typeof _0x10cafd['isEnabled']||(!_0x48faac||_0x10cafd['isEnabled'](_0x2afec4))),_0x2033ad['add'](_0x2b7604);}return _0x2033ad;}(_0x3dde4a,_0x64f123);return _0x3dde4a['bind']('isActionsDropdownOpen')['to'](_0x4c62d4,'isOpen'),_0x4c62d4['buttonView']['set']({'label':g(_0xb15b0,'Show\x20more\x20items'),'tooltip':!0x0,'tooltipPosition':'sw','icon':_0x38ab36}),_0x4c62d4['extendTemplate']({'attributes':{'class':['ck-revision-history-sidebar__revision__actions',_0x2671f3['if']('isActionsDropdownOpen','ck-on')]},'on':{'click':_0x2671f3['to'](_0x5e013c=>_0x5e013c['stopPropagation']())}}),_0x4c62d4['on']('execute',_0x1d87e6=>{_0x3dde4a['isReady']&&'function'==typeof _0x1d87e6['source']['_action']&&_0x1d87e6['source']['_action'](_0x3dde4a);}),_0x1b9e98(_0x4c62d4,_0x4ee97f,{'role':'menu'}),_0x4c62d4['listenTo'](_0x3dde4a,'change:isActionsDropdownOpen',(_0x3fde91,_0x48baa5,_0x401591)=>{if(_0x401591)for(const _0x1c2d5c of _0x4c62d4['listView']['items']){const _0x18db1e=_0x1c2d5c['children']['first'],_0x1ba3fe=_0x64f123['find'](_0x55f2a7=>_0x55f2a7['action']===_0x18db1e['_action'])['isVisible'];_0x1c2d5c['isVisible']=void 0x0===_0x1ba3fe||_0x1ba3fe(_0x3dde4a);}}),_0x4c62d4;}class ai extends/* #__PURE__ -- @preserve */
26
+ _0x157757(_0x1792c1){['id'];['revisionNameView'];['revisionActionsView'];['_revision'];['_requireRevisionName'];constructor(_0x462d78,_0x4fe854,_0x2e5dfb,_0x37fe9a){super(_0x462d78);const _0x3036f6=this['bindTemplate'],_0x44414f=function(_0x3bdcb1,_0x49fe2d){const _0x305c24=Array['from'](_0x49fe2d['authors'])['filter'](_0x529d9f=>_0x529d9f!=_0x49fe2d['creator']);return _0x49fe2d['creator']&&_0x305c24['unshift'](_0x49fe2d['creator']),_0x305c24['map'](_0x2c5708=>new oi(_0x3bdcb1,_0x2c5708,_0x2c5708==_0x49fe2d['creator']));}(_0x462d78,_0x4fe854);this['id']=_0x4fe854['id'],this['_revision']=_0x4fe854,this['_requireRevisionName']=_0x37fe9a,this['bind']('name','createdAt')['to'](_0x4fe854),this['bind']('_createdAtFormatted')['to'](this,'createdAt',_0x57e9b1=>{return _0x575068=_0x462d78['uiLanguage'],(_0x111002=_0x57e9b1)['toLocaleDateString'](_0x575068,{'month':'long','day':'numeric'})+',\x20'+_0x111002['toLocaleTimeString'](_0x575068,{'hour':'numeric','minute':'numeric'});var _0x575068,_0x111002;}),this['set']('isSelected',!0x1),this['set']('isHighlighted',!0x1),this['set']('isActionsDropdownOpen',!0x1),this['set']('isReady',!0x1),this['set']('isEnabled',!0x1),this['revisionNameView']=new lt(_0x462d78,ti),this['revisionNameView']['fieldView']['extendTemplate']({'attributes':{'maxlength':'220'}}),this['revisionNameView']['fieldView']['bind']('value')['to'](this,'name',_0x44cfc4=>_0x44cfc4||this['_createdAtFormatted']),this['revisionNameView']['bind']('isEnabled')['to'](this,'isSelected',this,'isEnabled',(_0x2e60cf,_0x2b6128)=>_0x2e60cf&&_0x2b6128),this['revisionActionsView']=_0x2e5dfb&&_0x2e5dfb['length']?ni(this,_0x2e5dfb):'',this['revisionActionsView']&&this['revisionActionsView']['bind']('isEnabled')['to'](this),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision-wrapper',_0x3036f6['if']('isConfirm','ck-revision-history-sidebar__revision-wrapper_confirmation_visible')]},'children':[{'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision',_0x3036f6['if']('isEnabled','ck-disabled',_0x3844bb=>!_0x3844bb),_0x3036f6['if']('isSelected','ck-revision-history-sidebar__revision_selected'),_0x3036f6['if']('isHighlighted','ck-revision-history-sidebar__revision_highlighted'),_0x3036f6['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':_0x3036f6['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':_0x44414f}]},this['revisionActionsView']],'on':{'click':_0x3036f6['to'](_0x4e4e43=>{_0x4e4e43['srcElement']['closest']('.ck-thread__remove-confirm')||this['isReady']&&this['isEnabled']&&this['fire']('select',{'id':this['id']});})}}]});}['render'](){super['render']();const _0x37845d=this['revisionNameView']['fieldView']['element'];this['listenTo'](_0x37845d,'change',()=>{this['_requireRevisionName']&&!_0x37845d['value']||this['fire']('setName',{'id':this['id'],'name':_0x37845d['value']}),_0x37845d['value']||(_0x37845d['value']=this['name']?this['name']:this['_createdAtFormatted']);});}['select'](){this['isSelected']=!0x0;}['deselect'](){this['isSelected']=!0x1;}['highlight'](){this['isHighlighted']=!0x0;}['unhighlight'](){this['isHighlighted']=!0x1;}}function mi(_0x3ea6a6,_0x53be98){const _0x33e8fb=_0x28e6bf['fromJSDate'](_0x3ea6a6)['setLocale'](_0x53be98),_0x476287=_0x28e6bf['local'](),_0x1b4f84=_0x476287['minus']({'days':0x1})['startOf']('day');let _0x3dfe2b,_0x296a00;return _0x33e8fb['hasSame'](_0x476287,'day')?(_0x3dfe2b=_0x33e8fb['startOf']('day')['toJSDate'](),_0x296a00=_0x33e8fb['toRelativeCalendar']()):_0x33e8fb['hasSame'](_0x1b4f84,'day')?(_0x3dfe2b=_0x1b4f84['toJSDate'](),_0x296a00=_0x33e8fb['toRelativeCalendar']()):_0x33e8fb['hasSame'](_0x476287,'week')?(_0x3dfe2b=_0x33e8fb['startOf']('week')['toJSDate'](),_0x296a00=_0x33e8fb['weekdayLong']||''):_0x33e8fb['hasSame'](_0x476287,'year')?(_0x3dfe2b=_0x33e8fb['startOf']('month')['toJSDate'](),_0x296a00=_0x33e8fb['monthLong']||''):(_0x3dfe2b=_0x33e8fb['startOf']('year')['toJSDate'](),_0x296a00=String(_0x33e8fb['year'])),{'startDate':_0x3dfe2b,'localizedPeriodName':_0x296a00};}class pi extends _0x1792c1{['startDate'];['revisionViews'];['_revisionActions'];['_requireRevisionName'];constructor(_0x2c77b5,_0x171686,_0x114826,_0x368513){super(_0x2c77b5);const _0x201940=mi(_0x171686,this['locale']['uiLanguage'])['localizedPeriodName'];this['startDate']=_0x171686,this['revisionViews']=this['createCollection'](),this['_revisionActions']=_0x114826,this['_requireRevisionName']=_0x368513,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':_0x201940}]},{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__time-period__revisions']},'children':this['revisionViews']}]});}['addRevision'](_0x52c185){const _0x4b3468=new ai(this['locale'],_0x52c185,this['_revisionActions'],this['_requireRevisionName']);this['revisionViews']['add'](_0x4b3468);}['removeRevision'](_0x5e6154){const _0x3c2b5e=this['revisionViews']['find'](_0x5e3643=>_0x5e3643['id']===_0x5e6154['id']);this['revisionViews']['remove'](_0x3c2b5e);}}class is extends _0x1792c1{constructor(_0x19b809){super(_0x19b809);const _0x42234f=new _0x184ac0();_0x42234f['content']=_0x184d1b,this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset_all','ck-revision-history-sidebar__header']},'children':[_0x42234f,{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__header__label']},'children':[g(_0x19b809,'Revision\x20history')]}]});}}class vi extends _0x1792c1{['timePeriodViews'];['_revisions'];['_revisionActions'];['_requireRevisionName'];constructor(_0x39d87f,_0x4cfed0,_0xc5e2d8,_0x1d16ab){super(_0x39d87f);const _0x575f94=this['bindTemplate'];this['timePeriodViews']=this['createCollection'](),this['timePeriodViews']['delegate']('select')['to'](this),this['timePeriodViews']['delegate']('setName')['to'](this),this['_revisions']=_0x4cfed0,this['_revisionActions']=_0xc5e2d8,this['_requireRevisionName']=_0x1d16ab,this['on']('select',(_0x3bcdd8,_0x44c60f)=>{this['fire']('revisionSelected',_0x44c60f);}),this['on']('setName',(_0x39e032,_0x3da972)=>{this['fire']('revisionSetName',_0x3da972);}),this['set']('isEnabled',!0x1),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-rounded-corners','ck-revision-history-sidebar']},'children':[new is(_0x39d87f),{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__timeline',_0x575f94['if']('isEnabled','ck-disabled',_0x2dcb72=>!_0x2dcb72)]},'children':this['timePeriodViews']}]});}['render'](){super['render']();for(const _0x57f144 of this['_revisions'])this['_addRevision'](_0x57f144);this['_revisions']['on']('add',(_0x1b3ecf,_0x857eeb)=>{this['_addRevision'](_0x857eeb);}),this['_revisions']['on']('remove',(_0x3f8229,_0x4a7397)=>{this['_removeRevision'](_0x4a7397);});}get['revisionViews'](){return this['timePeriodViews']['map'](_0x439d72=>_0x439d72['revisionViews']['map'](_0x516e63=>_0x516e63))['flat']();}['selectRevision'](_0x119bac){for(const _0x4f1bc4 of this['revisionViews'])_0x119bac&&_0x119bac['id']===_0x4f1bc4['id']?_0x4f1bc4['select']():_0x4f1bc4['deselect']();}['highlightRevisions'](_0x8645f7){for(const _0x762090 of this['revisionViews'])_0x8645f7['some'](({id:_0x13fc29})=>_0x13fc29===_0x762090['id'])?_0x762090['highlight']():_0x762090['unhighlight']();}['_addRevision'](_0x13c42a){const _0x249055=mi(_0x13c42a['createdAt'],this['locale']['uiLanguage'])['startDate'];let _0x24ec1e=this['timePeriodViews']['get'](0x0);_0x24ec1e&&_0x24ec1e['startDate']['getTime']()===_0x249055['getTime']()||(_0x24ec1e=new pi(this['locale'],_0x249055,this['_revisionActions'],this['_requireRevisionName']),this['timePeriodViews']['add'](_0x24ec1e)),_0x24ec1e['addRevision'](_0x13c42a);}['_removeRevision'](_0x4bcb57){const _0x292fd2=mi(_0x4bcb57['createdAt'],this['locale']['uiLanguage'])['startDate'];this['_getTimePeriodViewByStartDate'](_0x292fd2)['removeRevision'](_0x4bcb57);}['_getTimePeriodViewByStartDate'](_0x3f6fb5){return this['timePeriodViews']['find'](_0x474858=>_0x474858['startDate']['getTime']()===_0x3f6fb5['getTime']());}}class d extends _0x3f2981{['_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(_0xabefbb){super(_0xabefbb),this['_revisionViewer']=_0xabefbb['plugins']['get'](m),this['_revisionsRepository']=this['_revisionViewer']['repository'],this['_sidebarView']=null;}['init'](){const _0x236004=this['_revisionsRepository']['_revisions'],_0x59f4d4=this['_createRevisionActions'](),_0x3a7396=this['editor']['config']['get']('revisionHistory.viewerSidebarContainer');this['_sidebarView']=new ni(this['editor']['locale'],_0x236004,_0x59f4d4,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',(_0x2f388e,_0x2064a2)=>{_0x2064a2['revisionViews']['on']('add',(_0x5688c5,_0x2c500d)=>{_0x2c500d['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)),_0x3a7396['appendChild'](this['_sidebarView']['element']);}['destroy'](){this['_sidebarView']['element']['remove'](),this['_sidebarView']['destroy']();}['_handleEditorDataReady'](){const _0x1a3e02=this['_revisionsRepository']['getRevision'](0x0);if(_0x1a3e02){const _0x48d440=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x1a3e02['id']);this['_revisionViewer']['compare'](_0x1a3e02,_0x48d440);}}['_handleRevisionSelected'](_0x51352e,_0x1380fc){const _0x39ec26=this['_revisionsRepository']['getRevision'](_0x1380fc['id']),_0x57f315=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x39ec26['id']);this['_revisionViewer']['compare'](_0x39ec26,_0x57f315);}['_handleRevisionSetName'](_0x5e2768,_0x12b5d4){this['_revisionsRepository']['getRevision'](_0x12b5d4['id'])['setName'](_0x12b5d4['name']);}['_handleDiffChange'](_0x57acb8,_0x34d426,_0x810393){const _0x245dc9=this['_revisionsRepository']['getRevisionsInDiff'](_0x810393);_0x245dc9['length']>0x2?(this['_sidebarView']['highlightRevisions'](_0x245dc9),this['_sidebarView']['selectRevision'](null)):(this['_sidebarView']['highlightRevisions']([]),this['_sidebarView']['selectRevision'](_0x245dc9[0x0]));}['_createRevisionActions'](){const _0x2f03af=this['editor'],_0x1d3947=d['availableRevisionActions'],_0x3b8d6c=_0x2f03af['config']['get']('revisionHistory.revisionActions')||d['defaultRevisionActions'];if(_0x3b8d6c['length'])return _0x3b8d6c['map'](_0x45ed3c=>{const _0xeaca4='string'==typeof _0x45ed3c?Object['assign']({},_0x1d3947[_0x45ed3c]):_0x45ed3c;return _0xeaca4['action']=_0xeaca4['action']['bind'](this,_0x2f03af),_0xeaca4['isVisible']&&(_0xeaca4['isVisible']=_0xeaca4['isVisible']['bind'](this,_0x2f03af)),_0xeaca4;});}}function pt(){return{'compareAgainstSelected':{'name':'Compare\x20against\x20selected','action':({plugins:_0x1062c7},_0x10af43)=>{const _0x29cf78=_0x1062c7['get'](m),_0x5e5706=_0x29cf78['repository'];let _0x2ad85e=_0x29cf78['diff']['newRevisionId'],_0x233207=_0x10af43['id'];_0x5e5706['getIndex'](_0x2ad85e)>_0x5e5706['getIndex'](_0x233207)&&([_0x2ad85e,_0x233207]=[_0x233207,_0x2ad85e]),_0x29cf78['compare'](_0x2ad85e,_0x233207);},'isVisible':({plugins:_0x5df2d0},_0x257607)=>{const _0x36b917=_0x5df2d0['get'](m);return!(_0x36b917['repository']['getRevisionsInDiff'](_0x36b917['diff'])['length']>0x2)&&!_0x257607['isSelected'];}},'restoreRevision':{'name':'Restore\x20this\x20revision','action':(_0x14fafc,{id:_0x542110})=>{_0x14fafc['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x542110);},'isVisible':({plugins:_0x1d9f65},_0x327d84)=>!!_0x1d9f65['get'](m)['repository']['getLaterVisibleRevision'](_0x327d84['id'])},'nameRevision':{'name':'Name\x20this\x20revision','action':({plugins:_0x352c2c},{id:_0xb359d6,revisionNameView:_0x140850})=>{const _0x291e74=_0x352c2c['get'](m),_0x43b2c2=_0x291e74['repository']['getEarlierVisibleRevision'](_0xb359d6);_0x291e74['compare'](_0xb359d6,_0x43b2c2),_0x140850['focus'](),_0x140850['fieldView']['select']();}}};}class tt extends st{['_view'];['_toolbarConfig'];['_elementReplacer'];get['view'](){return this['_view'];}constructor(_0xc3f22b,_0x36eee1){super(_0xc3f22b),this['_view']=_0x36eee1,this['_toolbarConfig']=et(_0xc3f22b['config']['get']('toolbar')),this['_elementReplacer']=new ot();}get['element'](){return this['view']['element'];}['init'](_0x91efdb){const _0x17cb19=this['editor'],_0x3b6b08=this['view'],_0x596665=_0x17cb19['editing']['view'],_0x5b0aa5=_0x3b6b08['editable'],_0x52e62b=_0x596665['document']['getRoot']();_0x5b0aa5['name']=_0x52e62b['rootName'],_0x3b6b08['render']();const _0x37c190=_0x5b0aa5['element'];this['setEditableElement'](_0x5b0aa5['name'],_0x37c190),_0x3b6b08['editable']['bind']('isFocused')['to'](this['focusTracker']),_0x596665['attachDomRoot'](_0x37c190),this['_elementReplacer']['replace'](_0x91efdb,this['element']),this['_initToolbar'](),this['fire']('ready');}['destroy'](){super['destroy']();const _0x2cb75e=this['view'],_0x21041f=this['editor']['editing']['view'];this['_elementReplacer']['restore'](),_0x21041f['detachDomRoot'](_0x2cb75e['editable']['name']),_0x2cb75e['destroy']();}['_initToolbar'](){const _0xbf78ea=this['view'];_0xbf78ea['stickyPanel']['bind']('isActive')['to'](this['focusTracker'],'isFocused'),_0xbf78ea['stickyPanel']['limiterElement']=_0xbf78ea['element'],_0xbf78ea['stickyPanel']['bind']('viewportTopOffset')['to'](this,'viewportOffset',({top:_0x22553e})=>_0x22553e),_0xbf78ea['toolbar']['fillFromConfig'](this['_toolbarConfig'],this['componentFactory']),this['addToolbar'](_0xbf78ea['toolbar']);}}class it extends rt{['_editable'];['stickyPanel'];['toolbar'];get['editable'](){return this['_editable'];}constructor(_0x307cb3,_0x14da58,_0x17934d={}){super(_0x307cb3),this['stickyPanel']=new ht(_0x307cb3),this['toolbar']=new dt(_0x307cb3,{'shouldGroupWhenFull':_0x17934d['shouldToolbarGroupWhenFull']}),this['_editable']=new ct(_0x307cb3,_0x14da58);}['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
- _0x59ee7c(_0x4d07a6){['_ui'];get['ui'](){return this['_ui'];}constructor(_0x2b6457,_0x5b06c2){super(_0x5b06c2),this['sourceElement']=_0x2b6457,this['model']['document']['createRoot']();const _0x494026=new it(this['locale'],this['editing']['view'],{'shouldToolbarGroupWhenFull':!0x0});this['_ui']=new tt(this,_0x494026);}['destroy'](){return this['updateSourceElement'](),this['ui']['destroy'](),super['destroy']();}static async['create'](_0x2aec87,_0x113d29){const _0x744d05=new this(_0x2aec87,_0x113d29);return await _0x744d05['initPlugins'](),await _0x744d05['ui']['init'](_0x2aec87),await _0x744d05['data']['init'](_0x744d05['config']['get']('initialData')||''),_0x744d05['fire']('ready'),_0x744d05;}}const p=['RevisionHistoryUI','RestrictedEditingMode'];class _t extends _0x1aaf30{['result'];static get['pluginName'](){return'RevisionViewerIntegration';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x3d41a5){function _0x1410d2(_0x4bca6b){return _0x4bca6b['map'](_0x3f8755=>String['fromCharCode'](_0x3f8755))['join']('');}super(_0x3d41a5),this['result']='end',_0x3d41a5[_0x1410d2([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x1410d2([0x76,0x69,0x65,0x77])][_0x1410d2([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x1410d2([0x61,0x75,0x74,0x6f]),_0x3d41a5[_0x1410d2([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x1410d2([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x1410d2([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x1410d2([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x1410d2([0x6f,0x6b])});}}class k extends _0x1aaf30{['_viewerEditor'];static get['pluginName'](){return'RevisionHistory';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[u,f];}constructor(_0x38d3c3){if(super(_0x38d3c3),!this['editor']['config']['get']('revisionHistory'))throw new _0xae2ed9('revision-history-missing-configuration',this);this['_viewerEditor']=null,this['set']('isRevisionViewerOpen',!0x1),this['editor']['config']['define']('revisionHistory.showRevisionViewerCallback',_0x2dee4b=>this['_showRevisionViewer']({..._0x2dee4b,'translations':this['editor']['locale']['translations']})),this['editor']['config']['define']('revisionHistory.closeRevisionViewerCallback',_0x4ee88e=>this['_closeRevisionViewer'](_0x4ee88e)),this['editor']['config']['define']('revisionHistory.restoreRevisionCallback',_0x4b0203=>this['_restoreRevision'](_0x4b0203)),this['editor']['config']['define']('revisionHistory.requireRevisionName',!0x1),this['_enhanceShowRevisionViewerCallback'](),this['_enhanceCloseRevisionViewerCallback']();}set['adapter'](_0x27c44d){this['editor']['plugins']['get']('RevisionTracker')['adapter']=_0x27c44d;}get['adapter'](){return this['editor']['plugins']['get']('RevisionTracker')['adapter'];}['addRevisionData'](_0x4c175e){return this['editor']['plugins']['get']('RevisionTracker')['addRevisionData'](_0x4c175e);}['getRevision'](_0x36743f){return this['editor']['plugins']['get']('RevisionsRepository')['getRevision'](_0x36743f);}['getRevisions'](_0x24df06){return this['editor']['plugins']['get']('RevisionsRepository')['getRevisions'](_0x24df06||{'toJSON':!0x1});}['_getRevisionViewerEditorConfig'](){const _0x55f90c=this['editor'],_0x14eb21=_0x1a3df8(_0x55f90c,p),_0x291f29=_0x55f90c['plugins']['get']('RevisionTracker'),_0x171e4a=_0x55f90c['plugins']['get']('Users')['users'];return _0x14eb21['toolbar']=['exitToEditing','restoreRevision','changesNavigation'],delete _0x14eb21['lazyRoots'],(_0x14eb21['plugins']['push'](_t,m,R,class extends _0x1aaf30{static get['requires'](){return[m,'Users'];}['init'](){const _0x4186ea=this['editor']['plugins']['get']('Users');for(const _0x547a3a of _0x171e4a)_0x547a3a['isAnonymous']||_0x4186ea['getUser'](_0x547a3a['id'])||_0x4186ea['addUser'](_0x547a3a);const _0x1ca21c=_0x291f29['repository']['getRevisions']();let _0x4c7f14=null;const _0x2604de=this['editor']['plugins']['get']('RevisionViewer');_0x2604de['adapter']=_0x291f29['adapter'],_0x2604de['bind']('isEnabled')['to'](_0x291f29),this['editor']['commands']['get']('restoreRevision')['bind']('isEnabled')['to'](_0x55f90c,'isReadOnly',_0x2a7e73=>!_0x2a7e73);for(const _0xf049e6 of _0x1ca21c){const _0x546116=null===_0xf049e6['creator'];if(_0x546116&&_0xf049e6['toVersion']===_0xf049e6['fromVersion'])continue;const _0x3b7b00=_0xf049e6['toJSON']();_0x2604de['addRevisionData'](_0x3b7b00,(_0x26fe5a,_0x12ba1f,_0x1966a1)=>{if(_0x546116){if(_0x4c7f14)_0x4c7f14['_update'](_0x26fe5a,_0x12ba1f);else{if(!_0x12ba1f){const _0x2c127e=_0x1966a1['toJSON']();_0x2c127e['id']=_0x3fbd15(),_0x291f29['saveRevision'](_0x2c127e,_0x1966a1['toVersion'])['then'](_0xfaf9f8=>{_0x4c7f14=_0xfaf9f8;});}}}else _0xf049e6['_update'](_0x26fe5a,_0x12ba1f);});}}},d),_0x14eb21);}['_enhanceShowRevisionViewerCallback'](){const _0xfd2ea0=this['editor']['config']['get']('revisionHistory')['showRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.showRevisionViewerCallback',async()=>{this['editor']['enableReadOnlyMode']('revision-history-viewer-opened');const _0x439ed8=this['editor']['plugins']['get']('RevisionTracker');if(this['editor']['plugins']['has']('Autosave')){const _0xa23ba8=this['editor']['plugins']['get']('Autosave');await _0xa23ba8['save']();}else await _0x439ed8['update']();if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('Dialog')){const _0x1f2822=this['editor']['plugins']['get']('Dialog');_0x1f2822['isOpen']&&_0x1f2822['hide']();}const _0x3694b5=this['_getRevisionViewerEditorConfig']();return _0xfd2ea0(_0x3694b5)['then'](_0x573569=>{return(this['_viewerEditor']=_0x573569,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'),_0x573569);})['catch'](_0x17da8a=>(console['error'](_0x17da8a),this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),null));});}['_enhanceCloseRevisionViewerCallback'](){const _0x28e8f5=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'](),_0x28e8f5(this['_viewerEditor'])['then'](()=>{if(this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),this['_viewerEditor']=null,this['editor']['plugins']['has']('Annotations')){const _0x40093d=this['editor']['plugins']['get']('Annotations');_0x40093d['refreshVisibility'](),_0x40093d['refreshPositioning']();}})));}['_showRevisionViewer'](_0x5ec48f){const _0x361f4a=this['editor']['config']['get']('revisionHistory.editorContainer'),_0x531910=this['editor']['config']['get']('revisionHistory.viewerContainer'),_0x5b3db5=this['editor']['config']['get']('revisionHistory.viewerEditorElement');return w['create'](_0x5b3db5,_0x5ec48f)['then'](_0x349e9c=>(_0x531910['style']['display']='block',_0x361f4a['style']['display']='none',this['isRevisionViewerOpen']=!0x0,_0x349e9c));}['_closeRevisionViewer'](_0x328c30){const _0x2c3c23=this['editor']['config']['get']('revisionHistory.editorContainer');return this['editor']['config']['get']('revisionHistory.viewerContainer')['style']['display']='none',_0x2c3c23['style']['display']='',this['isRevisionViewerOpen']=!0x1,_0x328c30['destroy']();}async['_restoreRevision'](_0x51075b){const _0x4d7c9f=this['editor'],_0x1c4e51=this['_viewerEditor']['plugins']['get']('RevisionViewer'),_0x12b085=_0x4d7c9f['plugins']['get']('RevisionTracker'),_0x161fe1=_0x4d7c9f['plugins']['get']('RevisionHistoryUtils'),_0xc328a9=_0x1c4e51['repository']['getRevision'](_0x51075b);let _0x5c5700,_0x1d9eba,_0x3d135d;try{await _0x161fe1['loadRevisionData'](_0xc328a9,this['adapter']),_0x5c5700=_0x161fe1['getRevisionDocumentData'](_0xc328a9),_0x1d9eba=_0x161fe1['getRevisionRootsAttributes'](_0xc328a9);}catch(_0x10640a){return void console['error'](_0x10640a);}_0x4d7c9f['model']['change'](_0xc97bc9=>{for(const _0x41a47a of Array['from'](_0x4d7c9f['model']['markers']['getMarkersGroup']('restrictedEditingException')))_0xc97bc9['removeMarker'](_0x41a47a);}),_0x1c4e51['isReady']=!0x1,_0x4d7c9f['model']['enqueueChange'](_0x245ffa=>{_0x245ffa['setSelection'](null),_0x245ffa['removeSelectionAttribute'](_0x4d7c9f['model']['document']['selection']['getAttributeKeys']());const _0x211775=Object['keys'](_0x5c5700);for(const _0x1582a9 of _0x4d7c9f['model']['document']['roots'])'$graveyard'!=_0x1582a9['rootName']&&_0x1582a9['isAttached']()&&!_0x211775['includes'](_0x1582a9['rootName'])&&_0x245ffa['detachRoot'](_0x1582a9);for(const _0x404d2c of _0x211775){let _0x405ae6=_0x4d7c9f['model']['document']['getRoot'](_0x404d2c);_0x405ae6&&_0x405ae6['isAttached']()||(_0x405ae6=_0x245ffa['addRoot'](_0x404d2c));const _0x27694d=_0x1d9eba[_0x404d2c],_0x2a3a61=Object['keys'](_0x27694d),_0x3590d0=_0x5c5700[_0x404d2c];for(const _0x19506d of _0x405ae6['getAttributeKeys']())_0x2a3a61['includes'](_0x19506d)||_0x245ffa['removeAttribute'](_0x19506d,_0x405ae6);for(const _0x3b4b0d of _0x2a3a61)_0x245ffa['setAttribute'](_0x3b4b0d,_0x1d9eba[_0x404d2c][_0x3b4b0d],_0x405ae6);_0x245ffa['remove'](_0x245ffa['createRangeIn'](_0x405ae6)),_0x245ffa['insert'](_0x4d7c9f['data']['parse'](_0x3590d0,_0x405ae6),_0x405ae6,0x0);}});const _0x4a5f65=g(_0x4d7c9f['locale'],'Restored');if(_0xc328a9['name'])_0x3d135d=-0x1==_0xc328a9['name']['indexOf'](_0x4a5f65)?_0x4a5f65+':\x20'+_0xc328a9['name']:_0xc328a9['name'];else _0x3d135d=_0x4a5f65+':\x20'+(_0xc328a9['createdAt']['toLocaleDateString'](_0x4d7c9f['locale']['uiLanguage'],{'month':'long','day':'numeric'})+',\x20'+_0xc328a9['createdAt']['toLocaleTimeString'](_0x4d7c9f['locale']['uiLanguage'],{'hour':'numeric','minute':'numeric'}));return await _0x12b085['saveRevision']({'name':_0x3d135d}),_0x1c4e51['isReady']=!0x0,_0x4d7c9f['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
+ _t();static get['pluginName'](){return'RevisionsSidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[m];}constructor(_0x2f2fbf){super(_0x2f2fbf),this['_revisionViewer']=_0x2f2fbf['plugins']['get'](m),this['_revisionsRepository']=this['_revisionViewer']['repository'],this['_sidebarView']=null;}['init'](){const _0x1374c5=this['_revisionsRepository']['_revisions'],_0x28aae9=this['_createRevisionActions'](),_0xff193b=this['editor']['config']['get']('revisionHistory.viewerSidebarContainer');this['_sidebarView']=new vi(this['editor']['locale'],_0x1374c5,_0x28aae9,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',(_0x2a8f54,_0x52b589)=>{_0x52b589['revisionViews']['on']('add',(_0x4fb09e,_0x2df8c6)=>{_0x2df8c6['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)),_0xff193b['appendChild'](this['_sidebarView']['element']);}['destroy'](){this['_sidebarView']['element']['remove'](),this['_sidebarView']['destroy']();}['_handleEditorDataReady'](){const _0x3302a7=this['_revisionsRepository']['getRevision'](0x0);if(_0x3302a7){const _0x4647e4=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x3302a7['id']);this['_revisionViewer']['compare'](_0x3302a7,_0x4647e4);}}['_handleRevisionSelected'](_0x41799a,_0x50b32e){const _0x370ab3=this['_revisionsRepository']['getRevision'](_0x50b32e['id']),_0x2be0d9=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x370ab3['id']);this['_revisionViewer']['compare'](_0x370ab3,_0x2be0d9);}['_handleRevisionSetName'](_0xecc0d1,_0x17eada){this['_revisionsRepository']['getRevision'](_0x17eada['id'])['setName'](_0x17eada['name']);}['_handleDiffChange'](_0x40b063,_0x5d3048,_0x283673){const _0x403c84=this['_revisionsRepository']['getRevisionsInDiff'](_0x283673);_0x403c84['length']>0x2?(this['_sidebarView']['highlightRevisions'](_0x403c84),this['_sidebarView']['selectRevision'](null)):(this['_sidebarView']['highlightRevisions']([]),this['_sidebarView']['selectRevision'](_0x403c84[0x0]));}['_createRevisionActions'](){const _0x4bab21=this['editor'],_0x5d8f22=d['availableRevisionActions'],_0x51e2fc=_0x4bab21['config']['get']('revisionHistory.revisionActions')||d['defaultRevisionActions'];if(_0x51e2fc['length'])return _0x51e2fc['map'](_0x32dd56=>{const _0x16fc3a='string'==typeof _0x32dd56?Object['assign']({},_0x5d8f22[_0x32dd56]):_0x32dd56;return _0x16fc3a['action']=_0x16fc3a['action']['bind'](this,_0x4bab21),_0x16fc3a['isVisible']&&(_0x16fc3a['isVisible']=_0x16fc3a['isVisible']['bind'](this,_0x4bab21)),_0x16fc3a;});}}function _t(){return{'compareAgainstSelected':{'name':'Compare\x20against\x20selected','action':({plugins:_0x4768b2},_0x12ef99)=>{const _0x533a33=_0x4768b2['get'](m),_0x157a95=_0x533a33['repository'];let _0x287c73=_0x533a33['diff']['newRevisionId'],_0x27ba0a=_0x12ef99['id'];_0x157a95['getIndex'](_0x287c73)>_0x157a95['getIndex'](_0x27ba0a)&&([_0x287c73,_0x27ba0a]=[_0x27ba0a,_0x287c73]),_0x533a33['compare'](_0x287c73,_0x27ba0a);},'isVisible':({plugins:_0x4bf441},_0x38d73d)=>{const _0x346c0a=_0x4bf441['get'](m);return!(_0x346c0a['repository']['getRevisionsInDiff'](_0x346c0a['diff'])['length']>0x2)&&!_0x38d73d['isSelected'];}},'restoreRevision':{'name':'Restore\x20this\x20revision','action':(_0x1c11c2,{id:_0x1442fb})=>{_0x1c11c2['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x1442fb);},'isVisible':({plugins:_0x1db530},_0x15454c)=>!!_0x1db530['get'](m)['repository']['getLaterVisibleRevision'](_0x15454c['id'])},'nameRevision':{'name':'Name\x20this\x20revision','action':({plugins:_0x4aef79},{id:_0x3ef2e3,revisionNameView:_0x4a785a})=>{const _0x23d86=_0x4aef79['get'](m),_0x52bf29=_0x23d86['repository']['getEarlierVisibleRevision'](_0x3ef2e3);_0x23d86['compare'](_0x3ef2e3,_0x52bf29),_0x4a785a['focus'](),_0x4a785a['fieldView']['select']();}}};}class tt extends st{['_view'];['_toolbarConfig'];['_elementReplacer'];get['view'](){return this['_view'];}constructor(_0x135a6a,_0x3d1fa9){super(_0x135a6a),this['_view']=_0x3d1fa9,this['_toolbarConfig']=et(_0x135a6a['config']['get']('toolbar')),this['_elementReplacer']=new ot();}get['element'](){return this['view']['element'];}['init'](_0x29f28a){const _0x180a36=this['editor'],_0x1b1bef=this['view'],_0x226751=_0x180a36['editing']['view'],_0x2adf39=_0x1b1bef['editable'],_0x160524=_0x226751['document']['getRoot']();_0x2adf39['name']=_0x160524['rootName'],_0x1b1bef['render']();const _0x30a9cc=_0x2adf39['element'];this['setEditableElement'](_0x2adf39['name'],_0x30a9cc),_0x1b1bef['editable']['bind']('isFocused')['to'](this['focusTracker']),_0x226751['attachDomRoot'](_0x30a9cc),this['_elementReplacer']['replace'](_0x29f28a,this['element']),this['_initToolbar'](),this['fire']('ready');}['destroy'](){super['destroy']();const _0x2a8936=this['view'],_0x3e3efc=this['editor']['editing']['view'];this['_elementReplacer']['restore'](),_0x3e3efc['detachDomRoot'](_0x2a8936['editable']['name']),_0x2a8936['destroy']();}['_initToolbar'](){const _0x21d9ae=this['view'];_0x21d9ae['stickyPanel']['bind']('isActive')['to'](this['focusTracker'],'isFocused'),_0x21d9ae['stickyPanel']['limiterElement']=_0x21d9ae['element'],_0x21d9ae['stickyPanel']['bind']('viewportTopOffset')['to'](this,'viewportOffset',({top:_0x16c38a})=>_0x16c38a),_0x21d9ae['toolbar']['fillFromConfig'](this['_toolbarConfig'],this['componentFactory']),this['addToolbar'](_0x21d9ae['toolbar']);}}class it extends rt{['_editable'];['stickyPanel'];['toolbar'];get['editable'](){return this['_editable'];}constructor(_0x57df53,_0x18774d,_0x3d76c4={}){super(_0x57df53),this['stickyPanel']=new ht(_0x57df53),this['toolbar']=new dt(_0x57df53,{'shouldGroupWhenFull':_0x3d76c4['shouldToolbarGroupWhenFull']}),this['_editable']=new ct(_0x57df53,_0x18774d);}['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
+ _0xf04e0d(_0x26f9dc){['_ui'];get['ui'](){return this['_ui'];}constructor(_0x2ff5c2,_0x2102c8){super(_0x2102c8),this['sourceElement']=_0x2ff5c2,this['model']['document']['createRoot']();const _0x3a6a93=new it(this['locale'],this['editing']['view'],{'shouldToolbarGroupWhenFull':!0x0});this['_ui']=new tt(this,_0x3a6a93);}['destroy'](){return this['updateSourceElement'](),this['ui']['destroy'](),super['destroy']();}static async['create'](_0x404673,_0x2fa8d7){const _0x559a00=new this(_0x404673,_0x2fa8d7);return await _0x559a00['initPlugins'](),await _0x559a00['ui']['init'](_0x404673),await _0x559a00['data']['init'](_0x559a00['config']['get']('initialData')||''),_0x559a00['fire']('ready'),_0x559a00;}}const p=['RevisionHistoryUI','RestrictedEditingMode'];class yt extends _0x3f2981{['result'];static get['pluginName'](){return'RevisionViewerIntegration';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x23914f){function _0x3a1765(_0x5a2d92){return _0x5a2d92['map'](_0xa4ec27=>String['fromCharCode'](_0xa4ec27))['join']('');}super(_0x23914f),this['result']='end',_0x23914f[_0x3a1765([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x3a1765([0x76,0x69,0x65,0x77])][_0x3a1765([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x3a1765([0x61,0x75,0x74,0x6f]),_0x23914f[_0x3a1765([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x3a1765([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x3a1765([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x3a1765([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x3a1765([0x6f,0x6b])});}}class k extends _0x3f2981{['_viewerEditor'];static get['pluginName'](){return'RevisionHistory';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[u,f];}constructor(_0x1e7c93){if(super(_0x1e7c93),!this['editor']['config']['get']('revisionHistory'))throw new _0x1065a6('revision-history-missing-configuration',this);this['_viewerEditor']=null,this['set']('isRevisionViewerOpen',!0x1),this['editor']['config']['define']('revisionHistory.showRevisionViewerCallback',_0x5a88e8=>this['_showRevisionViewer']({..._0x5a88e8,'translations':this['editor']['locale']['translations']})),this['editor']['config']['define']('revisionHistory.closeRevisionViewerCallback',_0x38a1b5=>this['_closeRevisionViewer'](_0x38a1b5)),this['editor']['config']['define']('revisionHistory.restoreRevisionCallback',_0x434e52=>this['_restoreRevision'](_0x434e52)),this['editor']['config']['define']('revisionHistory.requireRevisionName',!0x1),this['_enhanceShowRevisionViewerCallback'](),this['_enhanceCloseRevisionViewerCallback']();}set['adapter'](_0x31f063){this['editor']['plugins']['get']('RevisionTracker')['adapter']=_0x31f063;}get['adapter'](){return this['editor']['plugins']['get']('RevisionTracker')['adapter'];}['addRevisionData'](_0x17a6ae){return this['editor']['plugins']['get']('RevisionTracker')['addRevisionData'](_0x17a6ae);}['getRevision'](_0xdc3fd8){return this['editor']['plugins']['get']('RevisionsRepository')['getRevision'](_0xdc3fd8);}['getRevisions'](_0x4c0a28){return this['editor']['plugins']['get']('RevisionsRepository')['getRevisions'](_0x4c0a28||{'toJSON':!0x1});}['_getRevisionViewerEditorConfig'](){const _0x22dbf3=this['editor'],_0x315f15=_0x12d3c4(_0x22dbf3,p),_0x1e4c6a=_0x22dbf3['plugins']['get']('RevisionTracker'),_0x5343b0=_0x22dbf3['plugins']['get']('Users')['users'];return _0x315f15['toolbar']=['exitToEditing','restoreRevision','changesNavigation'],delete _0x315f15['lazyRoots'],(_0x315f15['plugins']['push'](yt,m,R,class extends _0x3f2981{static get['requires'](){return[m,'Users'];}['init'](){const _0x36ec5e=this['editor']['plugins']['get']('Users');for(const _0x516621 of _0x5343b0)_0x516621['isAnonymous']||_0x36ec5e['getUser'](_0x516621['id'])||_0x36ec5e['addUser'](_0x516621);const _0x5bf7a8=_0x1e4c6a['repository']['getRevisions']();let _0x10b44a=null;const _0x1637bc=this['editor']['plugins']['get']('RevisionViewer');_0x1637bc['adapter']=_0x1e4c6a['adapter'],_0x1637bc['bind']('isEnabled')['to'](_0x1e4c6a),this['editor']['commands']['get']('restoreRevision')['bind']('isEnabled')['to'](_0x22dbf3,'isReadOnly',_0x18cbc9=>!_0x18cbc9);for(const _0x5b8d95 of _0x5bf7a8){const _0x2ced21=null===_0x5b8d95['creator'];if(_0x2ced21&&_0x5b8d95['toVersion']===_0x5b8d95['fromVersion'])continue;const _0x1b2f58=_0x5b8d95['toJSON']();_0x1637bc['addRevisionData'](_0x1b2f58,(_0x4ea4ce,_0x4e9113,_0x31d5af)=>{if(_0x2ced21){if(_0x10b44a)_0x10b44a['_update'](_0x4ea4ce,_0x4e9113);else{if(!_0x4e9113){const _0x475c83=_0x31d5af['toJSON']();_0x475c83['id']=_0x488afd(),_0x1e4c6a['saveRevision'](_0x475c83,_0x31d5af['toVersion'])['then'](_0x5020db=>{_0x10b44a=_0x5020db;});}}}else _0x5b8d95['_update'](_0x4ea4ce,_0x4e9113);});}}},d),_0x315f15);}['_enhanceShowRevisionViewerCallback'](){const _0x5a2f21=this['editor']['config']['get']('revisionHistory')['showRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.showRevisionViewerCallback',async()=>{this['editor']['enableReadOnlyMode']('revision-history-viewer-opened');const _0x24b674=this['editor']['plugins']['get']('RevisionTracker');if(this['editor']['plugins']['has']('Autosave')){const _0x3a5dd2=this['editor']['plugins']['get']('Autosave');await _0x3a5dd2['save']();}else await _0x24b674['update']();if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('Dialog')){const _0x52520a=this['editor']['plugins']['get']('Dialog');_0x52520a['isOpen']&&_0x52520a['hide']();}const _0x3f73e4=this['_getRevisionViewerEditorConfig']();return _0x5a2f21(_0x3f73e4)['then'](_0x596959=>{return(this['_viewerEditor']=_0x596959,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'),_0x596959);})['catch'](_0x3f1f98=>(console['error'](_0x3f1f98),this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),null));});}['_enhanceCloseRevisionViewerCallback'](){const _0x57b317=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'](),_0x57b317(this['_viewerEditor'])['then'](()=>{if(this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),this['_viewerEditor']=null,this['editor']['plugins']['has']('Annotations')){const _0x2c9233=this['editor']['plugins']['get']('Annotations');_0x2c9233['refreshVisibility'](),_0x2c9233['refreshPositioning']();}})));}['_showRevisionViewer'](_0x45fa36){const _0x28e865=this['editor']['config']['get']('revisionHistory.editorContainer'),_0x1aedc2=this['editor']['config']['get']('revisionHistory.viewerContainer'),_0x554989=this['editor']['config']['get']('revisionHistory.viewerEditorElement');return w['create'](_0x554989,_0x45fa36)['then'](_0x43f9ef=>(_0x1aedc2['style']['display']='block',_0x28e865['style']['display']='none',this['isRevisionViewerOpen']=!0x0,_0x43f9ef));}['_closeRevisionViewer'](_0x1acb8b){const _0xc99f32=this['editor']['config']['get']('revisionHistory.editorContainer');return this['editor']['config']['get']('revisionHistory.viewerContainer')['style']['display']='none',_0xc99f32['style']['display']='',this['isRevisionViewerOpen']=!0x1,_0x1acb8b['destroy']();}async['_restoreRevision'](_0x5ee87b){const _0x4e8d45=this['editor'],_0x5704f2=this['_viewerEditor']['plugins']['get']('RevisionViewer'),_0x3a2fe4=_0x4e8d45['plugins']['get']('RevisionTracker'),_0x29136f=_0x4e8d45['plugins']['get']('RevisionHistoryUtils'),_0x2dd4f0=_0x5704f2['repository']['getRevision'](_0x5ee87b);let _0x539d87,_0x3f6222,_0x1d8b8f;try{await _0x29136f['loadRevisionData'](_0x2dd4f0,this['adapter']),_0x539d87=_0x29136f['getRevisionDocumentData'](_0x2dd4f0),_0x3f6222=_0x29136f['getRevisionRootsAttributes'](_0x2dd4f0);}catch(_0x19c851){return void console['error'](_0x19c851);}_0x4e8d45['model']['change'](_0x178a2f=>{for(const _0x21b28f of Array['from'](_0x4e8d45['model']['markers']['getMarkersGroup']('restrictedEditingException')))_0x178a2f['removeMarker'](_0x21b28f);}),_0x5704f2['isReady']=!0x1,_0x4e8d45['model']['enqueueChange'](_0xf3ae0b=>{_0xf3ae0b['setSelection'](null),_0xf3ae0b['removeSelectionAttribute'](_0x4e8d45['model']['document']['selection']['getAttributeKeys']());const _0x4d5523=Object['keys'](_0x539d87);for(const _0xcc2d0 of _0x4e8d45['model']['document']['roots'])'$graveyard'!=_0xcc2d0['rootName']&&_0xcc2d0['isAttached']()&&!_0x4d5523['includes'](_0xcc2d0['rootName'])&&_0xf3ae0b['detachRoot'](_0xcc2d0);for(const _0x19a031 of _0x4d5523){let _0x189847=_0x4e8d45['model']['document']['getRoot'](_0x19a031);_0x189847&&_0x189847['isAttached']()||(_0x189847=_0xf3ae0b['addRoot'](_0x19a031));const _0x23edba=_0x3f6222[_0x19a031],_0x28522c=Object['keys'](_0x23edba),_0xde23e=_0x539d87[_0x19a031];for(const _0x196033 of _0x189847['getAttributeKeys']())_0x28522c['includes'](_0x196033)||_0xf3ae0b['removeAttribute'](_0x196033,_0x189847);for(const _0x8cb4b6 of _0x28522c)_0xf3ae0b['setAttribute'](_0x8cb4b6,_0x3f6222[_0x19a031][_0x8cb4b6],_0x189847);_0xf3ae0b['remove'](_0xf3ae0b['createRangeIn'](_0x189847)),_0xf3ae0b['insert'](_0x4e8d45['data']['parse'](_0xde23e,_0x189847),_0x189847,0x0);}});const _0x366009=g(_0x4e8d45['locale'],'Restored');if(_0x2dd4f0['name'])_0x1d8b8f=-0x1==_0x2dd4f0['name']['indexOf'](_0x366009)?_0x366009+':\x20'+_0x2dd4f0['name']:_0x2dd4f0['name'];else _0x1d8b8f=_0x366009+':\x20'+(_0x2dd4f0['createdAt']['toLocaleDateString'](_0x4e8d45['locale']['uiLanguage'],{'month':'long','day':'numeric'})+',\x20'+_0x2dd4f0['createdAt']['toLocaleTimeString'](_0x4e8d45['locale']['uiLanguage'],{'hour':'numeric','minute':'numeric'}));return await _0x3a2fe4['saveRevision']({'name':_0x1d8b8f}),_0x5704f2['isReady']=!0x0,_0x4e8d45['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,ie as RevisionViewerLoadingOverlay,R as RevisionViewerUI,I as RevisionsRepository,d as RevisionsSidebar};