@ckeditor/ckeditor5-revision-history 47.4.0-alpha.0 → 47.4.0-alpha.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js CHANGED
@@ -20,11 +20,11 @@
20
20
  *
21
21
  *
22
22
  */
23
- import{ObservableMixin as _0x460399,uid as _0x356b12,Collection as _0xd2e413,logWarning as _0x3ffb6d,FocusTracker as _0x45eb63,KeystrokeHandler as _0x11da2f,scrollViewportToShowTarget as _0xf4a10b,ResizeObserver as ot,ElementReplacer as it,CKEditorError as _0x4119b6}from'@ckeditor/ckeditor5-utils/dist/index.js';import{cloneDeep as _0x4665e6,set as _0xe64bb1,unset as _0x140109,isEqual as _0x3f4dce}from'es-toolkit/compat';import{Plugin as _0x17be55,PendingActions as _0x5efc60,Command as _0x5e6e25,ElementApiMixin as _0x43cb1a,Editor as _0x42df48}from'@ckeditor/ckeditor5-core/dist/index.js';import{Users as _0xfbc7c8,getMarkerDomElement as _0x5b00f2,ConfirmMixin as _0x32ef73,sanitizeEditorConfig as _0x4f9702}from'ckeditor5-collaboration/dist/index.js';import{ViewContainerElement as _0x5f11f6,ViewAttributeElement as _0x5d63c7,ViewEmptyElement as _0x48fb67,ViewRawElement as _0x1a416c,ViewUIElement as _0x141c69,ViewDocumentFragment as _0x559a2b,ViewText as _0x2a5809,ViewElement as _0x34b245,ModelElement as _0x314e33,ModelRange as _0x62b852,ModelPosition as _0x1ddb04,ModelDocumentFragment as _0x1237f0,ModelText as _0x29743a}from'@ckeditor/ckeditor5-engine/dist/index.js';import{IconHistory as _0x30d3bd,IconChevronUp as _0x21aa3d,IconChevronDown as _0x44f4be,IconUndo as _0x2a8575,IconUser as _0x145712,IconThreeVerticalDots as _0x1c849a}from'@ckeditor/ckeditor5-icons/dist/index.js';import{CssTransitionDisablerMixin as _0x4d4ba6,View as _0x1f7714,submitHandler as _0x35ff4b,LabeledFieldView as et,createLabeledInputText as ti,createDropdown as _0x3826ff,ListView as _0x403c33,ListItemView as _0x3ae127,ButtonView as _0x41e223,MenuBarMenuView as _0x539594,MenuBarMenuListView as _0x309602,MenuBarMenuListItemView as _0x57a792,MenuBarMenuListItemButtonView as _0x1ed467,ContextualBalloon as _0x2649e2,ToolbarSeparatorView as _0x16b0d8,IconView as _0x8f1b89,addListToDropdown as _0x3768a3,UIModel as to,EditorUI as tt,normalizeToolbarConfig as st,BoxedEditorUIView as _0xa1fcad,StickyPanelView as _0x90e838,ToolbarView as _0x293c23,InlineEditableUIView as te}from'@ckeditor/ckeditor5-ui/dist/index.js';import{DateTime as _0x3f1237}from'luxon';class I extends/* #__PURE__ -- @preserve */
24
- _0x460399(){['id'];['creator'];['authors'];['diffData'];['toVersion'];['fromVersion'];['model'];constructor(_0x367f43){super(),this['id']=_0x367f43['id']||_0x356b12(),this['creator']=_0x367f43['creator']||null,this['authors']=_0x367f43['authors']||[],this['diffData']=_0x367f43['diffData']||null,this['toVersion']=_0x367f43['toVersion']||0x0,this['fromVersion']=_0x367f43['fromVersion']||0x0,this['set']('name',_0x367f43['name']||''),this['set']('createdAt',_0x367f43['createdAt']||new Date()),this['set']('attributes',_0x367f43['attributes']||{});}['setName'](_0x44db7b){this['_update']({'name':_0x44db7b});}['setAttribute'](_0x12b5f2,_0x1dbc5c){const _0x11c77f=_0x4665e6(this['attributes']);_0xe64bb1(_0x11c77f,_0x12b5f2,_0x1dbc5c),this['_update']({'attributes':_0x11c77f});}['removeAttribute'](_0x4d7f13){const _0x1c1090=_0x4665e6(this['attributes']);_0x140109(_0x1c1090,_0x4d7f13),this['_update']({'attributes':_0x1c1090});}['_update'](_0x1c0727,_0x3fff69=!0x1){let _0x3fb9d2=!0x1;const _0x28df38={'id':this['id']},_0x46fcf7=['name','createdAt','diffData','authors','attributes','toVersion','fromVersion','creatorId'];for(const _0x3aedd2 of _0x46fcf7){const _0x51f18a=_0x1c0727[_0x3aedd2];void 0x0!==_0x51f18a&&_0x51f18a!==this[_0x3aedd2]&&(this[_0x3aedd2]=_0x51f18a,_0x28df38[_0x3aedd2]=_0x51f18a,_0x3fb9d2=!0x0);}_0x3fb9d2&&(_0x28df38['authors']&&(_0x28df38['authorsIds']=_0x28df38['authors']['map'](_0x34ee36=>_0x34ee36['id']),delete _0x28df38['authors']),this['fire']('_update',_0x28df38,_0x3fff69));}['toJSON'](){return{'id':this['id'],'name':this['name'],'creatorId':this['creator']?this['creator']['id']:null,'authorsIds':this['authors']['map'](_0x5d10c3=>_0x5d10c3['id']),'diffData':this['diffData'],'createdAt':this['createdAt'],'attributes':this['attributes'],'fromVersion':this['fromVersion'],'toVersion':this['toVersion']};}}class S extends _0x17be55{['_revisions'];static get['requires'](){return[_0xfbc7c8];}static get['pluginName'](){return'RevisionsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['length'](){return this['_revisions']['length'];}constructor(_0x177f60){super(_0x177f60),this['_revisions']=new _0xd2e413();}['afterInit'](){!async function(_0x417426){const _0x57fd29=_0x2c5bc8([0x76,0x73,0x6d,0x4c,0x34,0x54,0x50,0x70,0x75,0x52,0x35,0x33,0x4d,0x6c,0x71,0x53,0x6a,0x32,0x56,0x58,0x77,0x48,0x39,0x6f,0x45,0x41,0x4e,0x38,0x46,0x78,0x4a,0x74,0x47,0x55,0x4f,0x64,0x62,0x44,0x43,0x5a,0x30,0x31,0x69,0x68,0x79,0x66,0x6b,0x42,0x51,0x59,0x36,0x61,0x63,0x67,0x7a,0x37,0x72,0x49,0x65,0x57,0x4b,0x6e]),_0x662198=0xeb829,_0x4bfaea=0x359e09b0,_0x14535c=0x35997788^_0x4bfaea,_0xf1e6=window[_0x2c5bc8([0x44,0x61,0x74,0x65])][_0x2c5bc8([0x6e,0x6f,0x77])](),_0x1f1a83=_0x417426[_0x2c5bc8([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x218d69=new window[(_0x2c5bc8([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x5af175=>{_0x1f1a83[_0x2c5bc8([0x6f,0x6e,0x63,0x65])](_0x2c5bc8([0x72,0x65,0x61,0x64,0x79]),_0x5af175);}),_0x5b7567={[_0x2c5bc8([0x6b,0x74,0x79])]:_0x2c5bc8([0x45,0x43]),[_0x2c5bc8([0x75,0x73,0x65])]:_0x2c5bc8([0x73,0x69,0x67]),[_0x2c5bc8([0x63,0x72,0x76])]:_0x2c5bc8([0x50,0x2d,0x32,0x35,0x36]),[_0x2c5bc8([0x78])]:_0x2c5bc8([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]),[_0x2c5bc8([0x79])]:_0x2c5bc8([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]),[_0x2c5bc8([0x61,0x6c,0x67])]:_0x2c5bc8([0x45,0x53,0x32,0x35,0x36])},_0x3c77ba=_0x1f1a83[_0x2c5bc8([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x2c5bc8([0x67,0x65,0x74])](_0x2c5bc8([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x43dc14(){let _0x495477,_0x62363e=null,_0x391965=null;try{if(_0x3c77ba==_0x2c5bc8([0x47,0x50,0x4c]))return _0x2c5bc8([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x495477=_0x5761de(),!_0x495477)return _0x2c5bc8([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x495477[_0x2c5bc8([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x391965=_0x51d47f(_0x495477[_0x2c5bc8([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x495477[_0x2c5bc8([0x6a,0x74,0x69])])),await _0x5a3770()?_0x33d34f()?_0x228194()?_0x2c5bc8([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x295ee5()?(_0x495477[_0x2c5bc8([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x2c5bc8([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x62363e=_0x38f23c(_0x2c5bc8([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),await _0x2fd4b6()):_0x2c5bc8([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x2c5bc8([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x2c5bc8([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch{return _0x2c5bc8([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x228194(){const _0x4733c2=[_0x2c5bc8([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x2c5bc8([0x74,0x72,0x69,0x61,0x6c])][_0x2c5bc8([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x495477[_0x2c5bc8([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0xf1e6/0x3e8:0xe10*_0x14535c;return _0x495477[_0x2c5bc8([0x65,0x78,0x70])]<_0x4733c2;}function _0x33d34f(){const _0x839811=_0x495477[_0x2c5bc8([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x839811)return!0x1;if(_0x839811[_0x2c5bc8([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x2c5bc8([0x2a])))return!0x0;if(_0x839811[_0x2c5bc8([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x2c5bc8([0x52,0x48])))return!0x0;if(_0x839811[_0x2c5bc8([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x2c5bc8([0x52,0x52,0x48]))){if(_0x218abd())return!0x0;if(_0x2ef623()||_0x529149())return!0x0;}return!0x1;}function _0x295ee5(){const _0x265850=_0x495477[_0x2c5bc8([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x265850||0x0==_0x265850[_0x2c5bc8([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x4cdc91}=new URL(window[_0x2c5bc8([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x265850[_0x2c5bc8([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x4cdc91))return!0x0;const _0x25daae=_0x4cdc91[_0x2c5bc8([0x73,0x70,0x6c,0x69,0x74])](_0x2c5bc8([0x2e]));return _0x265850[_0x2c5bc8([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x4fdaf6=>_0x4fdaf6[_0x2c5bc8([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x2c5bc8([0x2a])))[_0x2c5bc8([0x6d,0x61,0x70])](_0x3b5bed=>_0x3b5bed[_0x2c5bc8([0x73,0x70,0x6c,0x69,0x74])](_0x2c5bc8([0x2e])))[_0x2c5bc8([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x1abc2d=>_0x1abc2d[_0x2c5bc8([0x6c,0x65,0x6e,0x67,0x74,0x68])]<=_0x25daae[_0x2c5bc8([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x2c5bc8([0x6d,0x61,0x70])](_0x43d17f=>Array(_0x25daae[_0x2c5bc8([0x6c,0x65,0x6e,0x67,0x74,0x68])]-_0x43d17f[_0x2c5bc8([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x2c5bc8([0x66,0x69,0x6c,0x6c])](_0x43d17f[0x0]===_0x2c5bc8([0x2a])?_0x2c5bc8([0x2a]):'')[_0x2c5bc8([0x63,0x6f,0x6e,0x63,0x61,0x74])](_0x43d17f))[_0x2c5bc8([0x73,0x6f,0x6d,0x65])](_0x850f30=>_0x25daae[_0x2c5bc8([0x65,0x76,0x65,0x72,0x79])]((_0x35e2b8,_0x253fee)=>_0x850f30[_0x253fee]===_0x35e2b8||_0x850f30[_0x253fee]===_0x2c5bc8([0x2a])));}function _0x2fd4b6(){return _0x62363e&&_0x391965?new window[(_0x2c5bc8([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x2eaa12,_0xc7d4a0)=>{_0x62363e[_0x2c5bc8([0x74,0x68,0x65,0x6e])](_0x2eaa12,_0xc7d4a0),_0x391965[_0x2c5bc8([0x74,0x68,0x65,0x6e])](_0x22a170=>{_0x22a170!=_0x2c5bc8([0x56,0x61,0x6c,0x69,0x64])&&_0x2eaa12(_0x22a170);},_0xc7d4a0);}):_0x62363e||_0x391965||_0x2c5bc8([0x56,0x61,0x6c,0x69,0x64]);}}function _0x51d47f(_0x210075,_0x555f40){return new window[(_0x2c5bc8([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x55faaf=>{if(_0x5d3c8a())return _0x55faaf(_0x2c5bc8([0x56,0x61,0x6c,0x69,0x64]));_0x1c243e(),_0x1f1a83[_0x2c5bc8([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x2c5bc8([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x4e8879=!0x1;const _0x27c0d4=_0x356b12();function _0x502392(_0x88d000){return!!_0x88d000&&(typeof _0x88d000===_0x2c5bc8([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x88d000===_0x2c5bc8([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x88d000[_0x2c5bc8([0x74,0x68,0x65,0x6e])]===_0x2c5bc8([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x88d000[_0x2c5bc8([0x63,0x61,0x74,0x63,0x68])]===_0x2c5bc8([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x144dfb(_0x15e2c9){_0x18fe9e(_0x15e2c9)[_0x2c5bc8([0x74,0x68,0x65,0x6e])](_0x13ca5c=>{if(!_0x13ca5c||_0x13ca5c[_0x2c5bc8([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x2c5bc8([0x6f,0x6b]))return _0x2c5bc8([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x349143(_0x22707c(_0x27c0d4+_0x555f40))!=_0x13ca5c[_0x2c5bc8([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x2c5bc8([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x2c5bc8([0x56,0x61,0x6c,0x69,0x64]);})[_0x2c5bc8([0x74,0x68,0x65,0x6e])](_0x2f3a1e=>(_0xedb0e1(),_0x2f3a1e),()=>{const _0x5362f0=_0x1ca057();return null==_0x5362f0?(_0xedb0e1(),_0x2c5bc8([0x56,0x61,0x6c,0x69,0x64])):_0x2c5bc8(_0xf1e6-_0x5362f0>(0x11928db0^_0x4bfaea)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x2c5bc8([0x74,0x68,0x65,0x6e])](_0x55faaf)[_0x2c5bc8([0x63,0x61,0x74,0x63,0x68])](()=>{_0x55faaf(_0x2c5bc8([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x2bf7fc=0x35a8e730^_0x4bfaea;function _0xedb0e1(){const _0x2d216c=_0x2c5bc8([0x6c,0x6c,0x63,0x74,0x2d])+_0x349143(_0x22707c(_0x210075)),_0x1c858d=_0x41460d(_0x349143(window[_0x2c5bc8([0x4d,0x61,0x74,0x68])][_0x2c5bc8([0x63,0x65,0x69,0x6c])](_0xf1e6/_0x2bf7fc)));window[_0x2c5bc8([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x2c5bc8([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x2d216c,_0x1c858d);}function _0x1ca057(){const _0x32b1e5=_0x2c5bc8([0x6c,0x6c,0x63,0x74,0x2d])+_0x349143(_0x22707c(_0x210075)),_0x1742be=window[_0x2c5bc8([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x2c5bc8([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x32b1e5);return _0x1742be?window[_0x2c5bc8([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x41460d(_0x1742be),0x10)*_0x2bf7fc:null;}function _0x18fe9e(_0x290e33){return new window[(_0x2c5bc8([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x2f0ebc,_0x2675cd)=>{_0x290e33[_0x2c5bc8([0x74,0x68,0x65,0x6e])](_0x2f0ebc,_0x2675cd),window[_0x2c5bc8([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x2675cd,0x359fdd70^_0x4bfaea);});}}_0x1f1a83[_0x2c5bc8([0x6f,0x6e])](_0x2c5bc8([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0xb42e00,_0x1e1499)=>{if(_0x1e1499[0x0]!=_0x210075)return _0x55faaf(_0x2c5bc8([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x1e1499[0x1]={..._0x1e1499[0x1],[_0x2c5bc8([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x27c0d4};},{[_0x2c5bc8([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x2c5bc8([0x68,0x69,0x67,0x68])}),_0x1f1a83[_0x2c5bc8([0x6f,0x6e])](_0x2c5bc8([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x5b4731=>{_0x502392(_0x5b4731[_0x2c5bc8([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x4e8879=!0x0,_0x144dfb(_0x5b4731[_0x2c5bc8([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x2c5bc8([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x2c5bc8([0x6c,0x6f,0x77])}),_0x218d69[_0x2c5bc8([0x74,0x68,0x65,0x6e])](()=>{_0x4e8879||_0x55faaf(_0x2c5bc8([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x5d3c8a(){return _0x1f1a83[_0x2c5bc8([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x2c5bc8([0x76,0x69,0x65,0x77])][_0x2c5bc8([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x2c5bc8([0x61,0x75,0x74,0x6f]);}function _0x1c243e(){_0x1f1a83[_0x2c5bc8([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x2c5bc8([0x76,0x69,0x65,0x77])][_0x2c5bc8([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x2c5bc8([0x61,0x75,0x74,0x6f]);}}function _0x38f23c(_0x1cd3c3){const _0x4e98cf=[new window[(_0x2c5bc8([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x1427ba=>setTimeout(_0x1427ba,0x3597377c^_0x4bfaea)),_0x218d69[_0x2c5bc8([0x74,0x68,0x65,0x6e])](()=>new window[(_0x2c5bc8([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x173d6b=>{const _0x15a065=0x359e09b7^_0x4bfaea,_0x4bc052=_0x417426[_0x2c5bc8([0x5f,0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x73])];function _0x3235f1(){_0x4bc052[_0x2c5bc8([0x6c,0x65,0x6e,0x67,0x74,0x68])]>=_0x15a065&&_0x173d6b();}_0x3235f1(),_0x4bc052[_0x2c5bc8([0x6f,0x6e])](_0x2c5bc8([0x61,0x64,0x64]),_0x3235f1);})),new window[(_0x2c5bc8([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x44b4dc=>{function _0x5eb14c(){for(const _0x3c5c26 in window)if(window[_0x2c5bc8([0x4e,0x75,0x6d,0x62,0x65,0x72])]['isNaN'](window[_0x2c5bc8([0x4e,0x75,0x6d,0x62,0x65,0x72])](_0x3c5c26))&&window[_0x3c5c26]==_0x662198)return _0x44b4dc();_0x1f1a83[_0x2c5bc8([0x73,0x74,0x61,0x74,0x65])]!=_0x2c5bc8([0x64,0x65,0x73,0x74,0x72,0x6f,0x79,0x65,0x64])&&window[_0x2c5bc8([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x5eb14c,0x359e1a38^_0x4bfaea);}_0x3fd496(_0x2c5bc8([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))&&_0x5eb14c();})];return window[_0x2c5bc8([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x2c5bc8([0x72,0x61,0x63,0x65])](_0x4e98cf)[_0x2c5bc8([0x74,0x68,0x65,0x6e])](()=>_0x1cd3c3);}async function _0x4fb7e1(){if(await _0x218d69,_0x3fd496(_0x2c5bc8([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))){const _0x12cc03=_0x417426[_0x2c5bc8([0x67,0x65,0x74,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](0x0),_0x275887=_0x417426[_0x2c5bc8([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])](_0x12cc03[_0x2c5bc8([0x69,0x64])]),_0x5bbab2=_0x2ea945(_0x2c5bc8([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]));return await _0x5bbab2[_0x2c5bc8([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])](_0x12cc03['id'],_0x275887?_0x275887['id']:null,!0x0),_0x5bbab2[_0x2c5bc8([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x2c5bc8([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x5bbab2[_0x2c5bc8([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x5bbab2[_0x2c5bc8([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])]=_0x483eb4,void(_0x5bbab2[_0x2c5bc8([0x5f,0x67,0x65,0x74,0x44,0x69,0x66,0x66])]=_0x483eb4);}if(_0x3fd496(_0x2c5bc8([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]))){const _0x2b0210=_0x2ea945(_0x2c5bc8([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]));_0x2b0210[_0x2c5bc8([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x2c5bc8([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x2b0210[_0x2c5bc8([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x2b0210[_0x2c5bc8([0x75,0x70,0x64,0x61,0x74,0x65])]=_0x483eb4,_0x2b0210[_0x2c5bc8([0x73,0x61,0x76,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])]=_0x483eb4;}_0x1f1a83[_0x2c5bc8([0x6d,0x6f,0x64,0x65,0x6c])][_0x2c5bc8([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x483eb4,_0x1f1a83[_0x2c5bc8([0x6d,0x6f,0x64,0x65,0x6c])][_0x2c5bc8([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x483eb4,_0x1f1a83[_0x2c5bc8([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x2c5bc8([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x218abd(){return _0x3fd496(_0x2c5bc8([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x2ea945(_0x2c5bc8([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x2c5bc8([0x73,0x74,0x61,0x74,0x65])]==_0x2c5bc8([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x2ef623(){return _0x3fd496(_0x2c5bc8([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 _0x529149(){return _0x3fd496(_0x2c5bc8([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0x15f232(_0x34043a){const _0x4aee87=_0x4781a6();_0x1f1a83[_0x4aee87]=_0x2c5bc8([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])+_0x34043a,_0x34043a[_0x2c5bc8([0x65,0x6e,0x64,0x73,0x57,0x69,0x74,0x68])](_0x2c5bc8([0x4c,0x69,0x6d,0x69,0x74]))&&(window[_0x4781a6()]=_0x662198),_0x34043a!=_0x2c5bc8([0x56,0x61,0x6c,0x69,0x64])&&_0x4fb7e1();}function _0x4781a6(){const _0x18a3a4=window[_0x2c5bc8([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x2c5bc8([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x2c5bc8([0x6e,0x6f,0x77])]())[_0x2c5bc8([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x2c5bc8([0x2e]),'');let _0x48265f=_0x2c5bc8([0x76]);for(let _0x83c01a=0x0;_0x83c01a<_0x18a3a4[_0x2c5bc8([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x83c01a+=0x2){let _0x57459c=window[_0x2c5bc8([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x18a3a4[_0x2c5bc8([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x83c01a,_0x83c01a+0x2));_0x57459c>=_0x57fd29[_0x2c5bc8([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x57459c-=_0x57fd29[_0x2c5bc8([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x48265f+=_0x57fd29[_0x57459c];}return _0x48265f;}function _0x5761de(){const _0x502e72=_0x3c77ba[_0x2c5bc8([0x73,0x70,0x6c,0x69,0x74])](_0x2c5bc8([0x2e]));if(0x3!=_0x502e72[_0x2c5bc8([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x13e400(_0x502e72[0x1]);function _0x13e400(_0x149168){const _0x17d16a=_0xcd37(_0x149168);return _0x17d16a&&_0x61aeb9()?_0x17d16a:null;function _0x61aeb9(){const _0x5d7098=_0x17d16a[_0x2c5bc8([0x6a,0x74,0x69])],_0x5bda69=window[_0x2c5bc8([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x5d7098[_0x2c5bc8([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x5d7098[_0x2c5bc8([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x5eda08={..._0x17d16a,[_0x2c5bc8([0x6a,0x74,0x69])]:_0x5d7098[_0x2c5bc8([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x5d7098[_0x2c5bc8([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x5eda08[_0x2c5bc8([0x76,0x63])],_0x22707c(_0x5eda08)==_0x5bda69;}}}async function _0x5a3770(){let _0x4cdbd9=!0x0;try{const _0x1873d8=_0x3c77ba[_0x2c5bc8([0x73,0x70,0x6c,0x69,0x74])](_0x2c5bc8([0x2e])),[_0x34aeef,_0x1ea4d0,_0x8d8861]=_0x1873d8;return _0x44643a(_0x34aeef),await _0x8bfcf7(_0x34aeef,_0x1ea4d0,_0x8d8861),_0x4cdbd9;}catch{return!0x1;}function _0x44643a(_0x373fbf){const _0x3e06e1=_0xcd37(_0x373fbf);_0x3e06e1&&_0x3e06e1[_0x2c5bc8([0x61,0x6c,0x67])]==_0x2c5bc8([0x45,0x53,0x32,0x35,0x36])||(_0x4cdbd9=!0x1);}async function _0x8bfcf7(_0x1373c1,_0x3da78f,_0x5ee656){const _0x2ca735=window[_0x2c5bc8([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x2c5bc8([0x66,0x72,0x6f,0x6d])](_0x32e3ee(_0x5ee656),_0x1c2a2c=>_0x1c2a2c[_0x2c5bc8([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0xb4af22=new window[(_0x2c5bc8([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x2c5bc8([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x1373c1+_0x2c5bc8([0x2e])+_0x3da78f),_0x4e1491=window[_0x2c5bc8([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x2c5bc8([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x4e1491)return;const _0x5d4489=await _0x4e1491[_0x2c5bc8([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x2c5bc8([0x6a,0x77,0x6b]),_0x5b7567,{[_0x2c5bc8([0x6e,0x61,0x6d,0x65])]:_0x2c5bc8([0x45,0x43,0x44,0x53,0x41]),[_0x2c5bc8([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x2c5bc8([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x2c5bc8([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x4e1491[_0x2c5bc8([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x2c5bc8([0x6e,0x61,0x6d,0x65])]:_0x2c5bc8([0x45,0x43,0x44,0x53,0x41]),[_0x2c5bc8([0x68,0x61,0x73,0x68])]:{[_0x2c5bc8([0x6e,0x61,0x6d,0x65])]:_0x2c5bc8([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x5d4489,_0x2ca735,_0xb4af22)||(_0x4cdbd9=!0x1);}}function _0xcd37(_0x16bc69){return _0x16bc69[_0x2c5bc8([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x2c5bc8([0x65,0x79]))?JSON[_0x2c5bc8([0x70,0x61,0x72,0x73,0x65])](_0x32e3ee(_0x16bc69)):null;}function _0x32e3ee(_0x50cc61){return window[_0x2c5bc8([0x61,0x74,0x6f,0x62])](_0x50cc61[_0x2c5bc8([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x2c5bc8([0x2b]))[_0x2c5bc8([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x2c5bc8([0x2f])));}function _0x22707c(_0x2024a6){let _0x2daee9=0x1505;function _0x4750a5(_0x176e39){for(let _0x2425f0=0x0;_0x2425f0<_0x176e39[_0x2c5bc8([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x2425f0++){const _0x434573=_0x176e39[_0x2c5bc8([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x2425f0);_0x2daee9=(_0x2daee9<<0x5)+_0x2daee9+_0x434573,_0x2daee9&=_0x2daee9;}}function _0xb3e64f(_0x27602a){Array[_0x2c5bc8([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x27602a)?_0x27602a[_0x2c5bc8([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0xb3e64f):_0x27602a&&typeof _0x27602a==_0x2c5bc8([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x2c5bc8([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x27602a)[_0x2c5bc8([0x73,0x6f,0x72,0x74])]()[_0x2c5bc8([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x53e27a,_0x321dca])=>{_0x4750a5(_0x53e27a),_0xb3e64f(_0x321dca);}):_0x4750a5(window[_0x2c5bc8([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x27602a));}return _0xb3e64f(_0x2024a6),_0x2daee9>>>0x0;}function _0x349143(_0x5538c4){return _0x5538c4[_0x2c5bc8([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x2c5bc8([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x2c5bc8([0x30]));}function _0x41460d(_0x209b13){return _0x209b13[_0x2c5bc8([0x73,0x70,0x6c,0x69,0x74])]('')[_0x2c5bc8([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x2c5bc8([0x6a,0x6f,0x69,0x6e])]('');}function _0x3fd496(_0x59e0ba){return _0x1f1a83[_0x2c5bc8([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x2c5bc8([0x68,0x61,0x73])](_0x59e0ba);}function _0x2ea945(_0xf0ad5a){return _0x1f1a83[_0x2c5bc8([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x2c5bc8([0x67,0x65,0x74])](_0xf0ad5a);}function _0x483eb4(){}function _0x2c5bc8(_0x2bc167){return _0x2bc167['map'](_0x2ba5d2=>String['fromCharCode'](_0x2ba5d2))['join']('');}_0x15f232(await _0x43dc14());}(this);}['createRevision'](_0x26b9f8){const _0x368caf=this['editor']['plugins']['get']('Users');return new I({'id':_0x26b9f8['id'],'name':_0x26b9f8['name'],'creator':_0x26b9f8['creatorId']?_0x368caf['getUser'](_0x26b9f8['creatorId']):null,'diffData':_0x26b9f8['diffData']||_0x26b9f8['data'],'authors':_0x26b9f8['authorsIds']['map'](_0x510ad0=>_0x368caf['getUser'](_0x510ad0)),'createdAt':new Date(_0x26b9f8['createdAt']),'attributes':_0x26b9f8['attributes'],'fromVersion':_0x26b9f8['fromVersion'],'toVersion':_0x26b9f8['toVersion']});}['addRevision'](_0x5eb316,_0x1f5b8f=0x0){this['_revisions']['add'](_0x5eb316,_0x1f5b8f);}['getRevision'](_0x414094){return this['_revisions']['get'](_0x414094);}['getRevisions'](_0x9f9685={'toJSON':!0x1}){const _0x31766b=Array['from'](this['_revisions']);return _0x31766b['reverse'](),_0x9f9685['toJSON']?_0x31766b['map'](_0x2170dc=>_0x2170dc['toJSON']()):_0x31766b;}['getIndex'](_0xde763b){return this['_revisions']['getIndex'](_0xde763b);}['getEarlierVisibleRevision'](_0x3a1ec7){const [,_0x92052a]=this['getRevisionsIterator'](_0x3a1ec7,{'direction':'earlier'});return _0x92052a;}['getLaterVisibleRevision'](_0x1a4070){const [,_0x583d57]=this['getRevisionsIterator'](_0x1a4070,{'direction':'later'});return _0x583d57;}['getRevisionsInDiff'](_0xd12e39){const _0x15566d=[];for(const _0x5b82b0 of this['getRevisionsIterator'](_0xd12e39['newRevisionId']))if(_0x15566d['push'](_0x5b82b0),_0x5b82b0['id']===_0xd12e39['oldRevisionId'])break;return _0x15566d;}*['getRevisionsIterator'](_0x489c5d,{direction:_0x2e4fe6='earlier',filter:_0x24a83b=()=>!0x0}={}){const _0x1e2a81='earlier'===_0x2e4fe6?0x1:-0x1;let _0x53b3a3=this['_revisions']['get'](_0x489c5d),_0x62491b=this['getIndex'](_0x53b3a3);for(yield _0x53b3a3;_0x53b3a3;){if(_0x62491b+=_0x1e2a81,_0x53b3a3=this['getRevision'](_0x62491b),!_0x53b3a3)return;_0x24a83b(_0x53b3a3)&&(yield _0x53b3a3);}}}class $ extends _0x17be55{static get['pluginName'](){return'RevisionHistoryUtils';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['_viewClassToTypeChar']=new Map([[_0x5f11f6,'c'],[_0x5d63c7,'a'],[_0x48fb67,'e'],[_0x1a416c,'r'],[_0x141c69,'u']]);['_typeCharToViewClass']=new Map([['c',_0x5f11f6],['a',_0x5d63c7],['e',_0x48fb67],['r',_0x1a416c],['u',_0x141c69]]);async['loadRevisionData'](_0x437c1c,_0x12ccd5){if(_0x437c1c['diffData']||!_0x12ccd5)return;const _0x5b8e4c=this['editor']['config']['get']('collaboration.channelId'),_0x418b59=await _0x12ccd5['getRevision']({'channelId':_0x5b8e4c,'revisionId':_0x437c1c['id']});_0x437c1c['diffData']=_0x418b59['diffData'];}['getRevisionDocumentData'](_0x58bdde){const _0x39a934={};for(const _0x396e69 in _0x58bdde['diffData']){if(_0x58bdde['diffData'][_0x396e69]['attachChange']&&!_0x58bdde['diffData'][_0x396e69]['attachChange']['isAttached'])continue;const _0x2be859=this['_removeRevisionMarkers'](JSON['parse'](_0x58bdde['diffData'][_0x396e69]['insertions'])),_0x4285e6=this['editor']['editing']['view']['document'],_0x32780f=new _0x559a2b(_0x4285e6,_0x2be859['map'](_0x3e5444=>this['_getViewFromDiffObj'](_0x3e5444,!0x1)));this['editor']['data']['processor']['useFillerType']('marked'),_0x39a934[_0x396e69]=this['editor']['data']['processor']['toData'](_0x32780f),this['editor']['data']['processor']['useFillerType']('default');}return _0x39a934;}['getRevisionRootsAttributes'](_0xab32b2){const _0x285f8f={};for(const _0x4c2f21 in _0xab32b2['diffData'])_0xab32b2['diffData'][_0x4c2f21]['attachChange']&&!_0xab32b2['diffData'][_0x4c2f21]['attachChange']['isAttached']||(_0x285f8f[_0x4c2f21]=_0xab32b2['diffData'][_0x4c2f21]['attributesAfter']||{});return _0x285f8f;}['_getTypeCharForViewElement'](_0x1baf0a){return this['_viewClassToTypeChar']['get'](_0x1baf0a['constructor']);}['_getViewFromDiffObj'](_0x137b28,_0x53541f){const _0x4b2078=this['editor']['editing']['view']['document'];if('string'==typeof _0x137b28)return new _0x2a5809(_0x4b2078,_0x137b28);{let _0x1d9ae9,_0x4ca77c;_0x4ca77c='u'==_0x137b28['type']||'r'==_0x137b28['type']?[]:_0x137b28['children']['map'](_0x5abf62=>this['_getViewFromDiffObj'](_0x5abf62,_0x53541f));const _0x42f246=this['_typeCharToViewClass']['get'](_0x137b28['type'])||_0x34b245,_0x42581a=this['editor']['data']['htmlProcessor']['domConverter'];if(_0x1d9ae9=new _0x42f246(_0x4b2078,_0x137b28['name'],_0x137b28['attributes'],_0x4ca77c),'u'==_0x137b28['type']&&_0x137b28['children'][0x0]){const _0x4f209b=_0x137b28['children'][0x0];if(_0x1d9ae9['render']=function(_0x8e3d3c){const _0x3cab1a=_0x8e3d3c['createElement']('div');return _0x3cab1a['innerHTML']=_0x4f209b,_0x3cab1a['childNodes'][0x0];},_0x53541f){const _0x3bc12f=new _0x559a2b(_0x4b2078);_0x3bc12f['_appendChild'](_0x1d9ae9);const _0x5c8df1=Array['from'](_0x42581a['viewChildrenToDom'](_0x3bc12f,{'bind':!0x1})),_0x503ffc=_0x42581a['domDocument']['createElement']('div');_0x503ffc['append'](..._0x5c8df1),_0x1d9ae9=Array['from'](_0x42581a['domChildrenToView'](_0x503ffc))[0x0];}}else{if('r'==_0x137b28['type']&&_0x137b28['children'][0x0]){const _0xbe5704=_0x137b28['children'][0x0];if(_0x1d9ae9['render']=function(_0x161abf){_0x161abf['innerHTML']=_0xbe5704;},_0x53541f){const _0x41af32=new _0x559a2b(_0x4b2078);_0x41af32['_appendChild'](_0x1d9ae9);const _0x175ed4=Array['from'](_0x42581a['viewChildrenToDom'](_0x41af32,{'bind':!0x1})),_0x2e6521=_0x42581a['domDocument']['createElement']('div');_0x2e6521['append'](..._0x175ed4);const _0x321852=Array['from'](_0x42581a['domChildrenToView'](_0x2e6521));_0x321852['length']>0x1?_0x1d9ae9['_appendChild'](_0x321852):_0x1d9ae9=_0x321852[0x0];}}}if(_0x137b28['customProperties']){for(const [_0x341a54,_0x2b8815]of _0x137b28['customProperties'])_0x1d9ae9['_setCustomProperty'](_0x341a54,_0x2b8815);}const _0x40b737=void 0x0===_0x137b28['fillerOffset']?null:_0x137b28['fillerOffset'];return null!==_0x40b737&&(_0x1d9ae9['getFillerOffset']=()=>_0x40b737),_0x1d9ae9;}}['_makeModelFromViewString'](_0x29b27e){const _0x5384d0=JSON['parse'](_0x29b27e),_0x6060ae=this['editor']['editing']['view']['document'],_0x2c7b54=new _0x559a2b(_0x6060ae,_0x5384d0['map'](_0x25daf0=>this['_getViewFromDiffObj'](_0x25daf0,!0x0)));return this['editor']['data']['toModel'](_0x2c7b54);}['_removeRevisionMarkers'](_0x126dac){return(_0x126dac=_0x126dac['filter'](_0xc320fb=>!_0xc320fb['name']||'revision-start'!==_0xc320fb['name']&&'revision-end'!==_0xc320fb['name']))['forEach'](_0x57d98a=>{'string'!=typeof _0x57d98a&&(_0x57d98a['children']=this['_removeRevisionMarkers'](_0x57d98a['children']),_0x57d98a['attributes']=_0x57d98a['attributes']['filter'](_0x1792fa=>!_0x1792fa[0x0]['startsWith']('data-revision-')));}),_0x126dac;}}function m(_0x14ba22,_0x1afda0,_0x321af1){const t=_0x14ba22['t'];switch(_0x1afda0){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'},_0x321af1);case'X_OF_Y_CHANGES':return t({'string':'%0\x20of\x20%1','id':'X_OF_Y_CHANGES'},_0x321af1);case'Show\x20previous\x20change':return t('Show\x20previous\x20change');case'Show\x20next\x20change':return t('Show\x20next\x20change');case'EDIT_X_OF_Y_REVISIONS':return t({'string':'Edit','id':'EDIT_X_OF_Y_REVISIONS'});case'Total':return t('Total');case'Revision\x20creator':return t('Revision\x20creator');case'Revision\x20author':return t('Revision\x20author');case'Revision\x20name':return t('Revision\x20name');case'Save\x20current\x20revision':return t('Save\x20current\x20revision');case'Accept':return t('Accept');case'Save':return t('Save');case'Cancel':return t('Cancel');case'Name\x20of\x20the\x20revision':return t('Name\x20of\x20the\x20revision');case'optional':return t('optional');case'PENDING_ACTION_REVISION_HISTORY':return t({'string':'Unsaved\x20change\x20in\x20revision\x20history.','id':'PENDING_ACTION_REVISION_HISTORY'});case'The\x20revision\x20name\x20cannot\x20be\x20empty.':return t('The\x20revision\x20name\x20cannot\x20be\x20empty.');case'Enter\x20the\x20revision\x20name':return t('Enter\x20the\x20revision\x20name');default:return'';}}class h extends _0x17be55{['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[_0xfbc7c8,S,$,_0x5efc60];}constructor(_0x37a5b4){super(_0x37a5b4),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 _0x49478a=_0x356b12();this['_source']={'history':this['editor']['model']['document']['history'],'getLatestVersion':()=>Promise['resolve'](this['editor']['model']['document']['version']),'getCurrentRevisionId':()=>_0x49478a},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 _0x3e55fa=this['repository']['getRevision'](0x0),_0x5da220=_0x3e55fa&&null===_0x3e55fa['creator']?_0x3e55fa:null;if(this['_continueCurrentRevision']=!!_0x5da220&&this['editor']['config']['get']('revisionHistory.resumeUnsavedRevision'),this['editor']['plugins']['has']('RealTimeCollaborationClient')){const _0xc4a1a8=this['_source']['getCurrentRevisionId'](),_0x3c467a=this['repository']['getRevision'](_0xc4a1a8);if(_0x3c467a)this['_startingVersion']=_0x3c467a['fromVersion'],this['_continueCurrentRevision']=!0x1;else{const _0x227e9c=this['_source']['history']['_operations']['find'](_0x412663=>!_0x412663['_isInit']),_0x5b306a=_0x227e9c?_0x227e9c['baseVersion']:this['_source']['history']['version'];_0x3e55fa?(_0x3e55fa['toVersion']<_0x5b306a&&_0x3e55fa['_update']({'toVersion':_0x5b306a}),this['_continueCurrentRevision']?(this['_source']['getCurrentRevisionId']=()=>_0x5da220['id'],this['_startingVersion']=_0x5da220['fromVersion']):(this['_startingVersion']=_0x3e55fa['toVersion'],this['_continueCurrentRevision']=!0x1)):(this['_startingVersion']=_0x5b306a,this['_continueCurrentRevision']=!0x1);}}else _0x5da220&&(this['editor']['model']['document']['history']['version']=Math['max'](_0x5da220['toVersion'],this['editor']['model']['document']['history']['version']),_0x5da220['fromVersion']===_0x5da220['toVersion']?(0x0!==_0x5da220['fromVersion']&&(this['_source']['getCurrentRevisionId']=()=>_0x5da220['id']),this['_continueCurrentRevision']=!0x1):this['_continueCurrentRevision']&&(this['_source']['getCurrentRevisionId']=()=>_0x5da220['id'],this['_startingVersion']=_0x5da220['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',_0x12e7bf=>!_0x12e7bf),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x11aa3d=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x1b5155;for(const _0xaa75fa in _0x11aa3d){const _0x588c16=_0xaa75fa,_0x235495=_0x11aa3d[_0x588c16];if('revisionHistoryLicenseKeyValid'==_0x235495||'revisionHistoryLicenseKeyInvalid'==_0x235495||'revisionHistoryLicenseKeyExpired'==_0x235495||'revisionHistoryLicenseKeyDomainLimit'==_0x235495||'revisionHistoryLicenseKeyNotAllowed'==_0x235495||'revisionHistoryLicenseKeyEvaluationLimit'==_0x235495||'revisionHistoryLicenseKeyUsageLimit'==_0x235495){delete _0x11aa3d[_0x588c16],_0x1b5155=_0x235495,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'revisionHistoryLicenseKeyInvalid'==_0x1b5155&&_0x11aa3d['_showLicenseError']('invalid'),'revisionHistoryLicenseKeyExpired'==_0x1b5155&&_0x11aa3d['_showLicenseError']('expired'),'revisionHistoryLicenseKeyDomainLimit'==_0x1b5155&&_0x11aa3d['_showLicenseError']('domainLimit'),'revisionHistoryLicenseKeyNotAllowed'==_0x1b5155&&_0x11aa3d['_showLicenseError']('featureNotAllowed','RevisionHistory'),'revisionHistoryLicenseKeyEvaluationLimit'==_0x1b5155&&_0x11aa3d['_showLicenseError']('evaluationLimit'),'revisionHistoryLicenseKeyUsageLimit'==_0x1b5155&&_0x11aa3d['_showLicenseError']('usageLimit');},0x3e8);}async['afterInit'](){if(this['repository']['length']>0x0){const _0x3662ec=this['repository']['getRevision'](0x0),_0x2d186d=await this['getRevisionDocumentData'](_0x3662ec),_0x41ebff=await this['getRevisionRootsAttributes'](_0x3662ec);this['_replaceEditorDataWithRevisionData'](_0x2d186d,_0x41ebff);}}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['setSource'](_0x480ab1){this['_source']=_0x480ab1;}async['update'](){const _0x497f71=await this['_source']['getLatestVersion']();if(_0x497f71>this['currentRevision']['toVersion']){await this['_loadState']();const _0x1c1e2c=this['buildRevisionData']({'revision':this['currentRevision'],'to':_0x497f71});_0x1c1e2c['authors']=_0x1c1e2c['authorsIds']['map'](_0x11ec73=>this['editor']['plugins']['get']('Users')['getUser'](_0x11ec73)),this['currentRevision']['_update'](_0x1c1e2c);}}async['saveRevision'](_0x37c86e={},_0x1b610b=null){const _0x408087=[];await this['_loadState'](),this['_continueCurrentRevision']=!0x1,_0x1b610b>this['currentRevision']['toVersion']&&(_0x1b610b=null),null===_0x1b610b&&(_0x1b610b=await this['_source']['getLatestVersion']());const _0x3b851e=this['_getFromVersion'](_0x1b610b),_0x320433=this['buildRevisionData']({'from':_0x3b851e,'to':_0x1b610b});if(this['currentRevision']['toVersion']<_0x1b610b){const _0x34d3dd=this['buildRevisionData']({'revision':this['currentRevision'],'from':_0x1b610b,'to':_0x1b610b});_0x34d3dd['authors']=[],_0x34d3dd['authorsIds']=[],_0x34d3dd['id']=this['currentRevision']['id'],this['currentRevision']['_update'](_0x34d3dd,!0x0),delete _0x34d3dd['authors'],_0x408087['push'](_0x34d3dd);}_0x37c86e['creatorId']=this['editor']['plugins']['get']('Users')['me']['id'],_0x37c86e['name']=_0x37c86e['name']||null,_0x37c86e['id']=_0x37c86e['id']||_0x356b12(),_0x37c86e={..._0x37c86e,..._0x320433};const _0xa8da1d=this['addRevisionData'](_0x37c86e);_0x408087['push'](_0x37c86e);const _0xbe9633=this['repository']['getIndex'](_0xa8da1d);if(0x0!==_0xbe9633){const _0x5d150c=this['repository']['getRevision'](_0xbe9633-0x1);if(_0x5d150c['fromVersion']!==_0x1b610b){const _0x10cf08=this['_revisionDataBuilder']['getData'](_0x1b610b,_0x5d150c['toVersion']),_0x526ef1={'id':_0x5d150c['id'],'diffData':_0x10cf08['diffData'],'authorsIds':_0x10cf08['authorsIds'],'authors':_0x10cf08['authorsIds']['map'](_0x4f24e8=>this['editor']['plugins']['get']('Users')['getUser'](_0x4f24e8)),'fromVersion':_0x1b610b};_0x5d150c===this['currentRevision']&&(_0x526ef1['createdAt']=new Date(_0x37c86e['createdAt']['getTime']()+0xa)),_0x5d150c['_update'](_0x526ef1,!0x0),delete _0x526ef1['authors'],_0x408087['push'](_0x526ef1);}}if(this['adapter']){for(const _0x3f6426 of _0x408087)this['_bufferUpdate'](_0x3f6426['id'],_0x3f6426,!0x0);this['sendBufferedUpdates']();}return _0xa8da1d;}['addRevisionData'](_0x2fa282){const _0x1e0b33=this['repository']['createRevision'](_0x2fa282);return this['adapter']&&_0x1e0b33['on']('_update',(_0x432410,_0x3d832b,_0x205833)=>{_0x205833||(this['_bufferUpdate'](_0x3d832b['id'],_0x3d832b,!0x0),this['sendBufferedUpdates']());}),this['repository']['addRevision'](_0x1e0b33,this['_findInsertionIndex'](_0x1e0b33)),_0x1e0b33;}async['getRevisionDocumentData'](_0x10b735){return await this['_utils']['loadRevisionData'](_0x10b735,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x10b735);}async['getRevisionRootsAttributes'](_0x1c719b){return await this['_utils']['loadRevisionData'](_0x1c719b,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x1c719b);}['sendBufferedUpdates'](){if(0x0===this['_bufferedUpdates']['size'])return;if(this['_isPendingUpdate'])return;let _0x91506e=Array['from'](this['_bufferedUpdates']['values']());this['_bufferedUpdates']['clear']();for(let _0x4550c5=0x0;_0x4550c5<_0x91506e['length'];_0x4550c5++){const _0x45f6b4=_0x91506e[_0x4550c5];let _0x2cd8b4=!0x1;for(const _0x2be24d of Object['keys'](_0x45f6b4))void 0x0===_0x45f6b4[_0x2be24d]?delete _0x45f6b4[_0x2be24d]:'id'!==_0x2be24d&&(_0x2cd8b4=!0x0);_0x2cd8b4||(_0x91506e[_0x4550c5]=null);}if(_0x91506e=_0x91506e['filter'](_0x2874d1=>null!==_0x2874d1),!_0x91506e['length'])return;for(let _0x46e21f=0x0;_0x46e21f<_0x91506e['length'];_0x46e21f++){const _0x43f708=_0x91506e[_0x46e21f];void 0x0!==_0x43f708['fromVersion']&&void 0x0===_0x43f708['toVersion']&&(_0x43f708['toVersion']=this['repository']['getRevision'](_0x43f708['id'])['toVersion']),void 0x0!==_0x43f708['toVersion']&&void 0x0===_0x43f708['fromVersion']&&(_0x43f708['fromVersion']=this['repository']['getRevision'](_0x43f708['id'])['fromVersion']);}const _0x1b0e21=this['editor']['config']['get']('collaboration.channelId');this['_isPendingUpdate']=!0x0,this['_addPendingAction'](),this['adapter']['updateRevisions'](_0x91506e,_0x1b0e21)['finally'](()=>{this['_isPendingUpdate']=!0x1;})['then'](_0x2b1606=>{if(_0x2b1606){for(const _0x1ad4b2 of _0x2b1606)this['setRevisionData']({'id':_0x1ad4b2['id'],'createdAt':_0x1ad4b2['createdAt']});}this['_removePendingAction'](),this['sendBufferedUpdates']();});}['buildRevisionData']({revision:_0xeb6e6d=null,from:_0xe48e8d=null,to:_0x93e8fa=null}){_0xe48e8d=null!==_0xe48e8d?_0xe48e8d:_0xeb6e6d['fromVersion'],_0x93e8fa=null!==_0x93e8fa?_0x93e8fa:_0xeb6e6d['toVersion'];const _0x15a1d3=this['_revisionDataBuilder']['getData'](_0xe48e8d,_0x93e8fa),_0x56bef9={'diffData':_0x15a1d3['diffData'],'authorsIds':_0x15a1d3['authorsIds'],'fromVersion':_0xe48e8d,'toVersion':_0x93e8fa};if(!_0xeb6e6d||_0x93e8fa!==_0xeb6e6d['toVersion']){const _0x104825=_0x93e8fa-0x1,_0x17238d=this['_source']['history']['getOperation'](_0x104825);_0x56bef9['createdAt']=_0x17238d&&_0x17238d['createdAt']||new Date();}if(this['_loadedStateData']&&_0xe48e8d===this['_loadedStateData']['fromVersion']){for(const _0x3dfc2c of this['_loadedStateData']['authors'])_0x56bef9['authorsIds']['includes'](_0x3dfc2c['id'])||_0x56bef9['authorsIds']['push'](_0x3dfc2c['id']);}return _0x56bef9;}['_bufferUpdate'](_0x4d80da,_0x1f3c79,_0xbce3df){if(this['_bufferedUpdates']['has'](_0x4d80da)){const _0x3c5439=this['_bufferedUpdates']['get'](_0x4d80da);_0x1f3c79=_0xbce3df?{..._0x3c5439,..._0x1f3c79}:{..._0x1f3c79,..._0x3c5439};}this['_bufferedUpdates']['set'](_0x4d80da,_0x1f3c79);}['setRevisionData'](_0x3982b6){const _0xd936f5=this['repository']['getRevision'](_0x3982b6['id']);if(_0x3982b6['createdAt']&&(_0x3982b6['createdAt']=new Date(_0x3982b6['createdAt'])),_0x3982b6['authorsIds']){const _0x2205d3=this['editor']['plugins']['get']('Users');_0x3982b6['authors']=_0x3982b6['authorsIds']['map'](_0x544d9a=>_0x2205d3['getUser'](_0x544d9a));}_0xd936f5['_update'](_0x3982b6,!0x0);}['_createInitialRevision'](_0x3ca326){const _0xa299b6=this['repository']['getRevision'](this['repository']['length']-0x1);if(_0xa299b6)this['_initialRevisionId']=_0xa299b6['id'];else{const _0x1ea816=!this['editor']['model']['document']['roots']['find'](_0x41a611=>this['editor']['model']['hasContent'](_0x41a611)),_0x791c6a=this['editor']['plugins']['get']('Users')['me']['id'],_0x5e64df=m(this['editor']['locale'],_0x1ea816?'Empty\x20document':'Initial\x20revision');this['_makeRevision']({'from':_0x3ca326,'to':_0x3ca326,'id':this['_initialRevisionId'],'name':_0x5e64df,'creatorId':_0x791c6a});}}['_createCurrentRevision'](_0x499617){const _0x4db078=this['_source']['getCurrentRevisionId']();this['currentRevision']=this['repository']['getRevision'](_0x4db078),this['currentRevision']||(this['currentRevision']=this['_makeRevision']({'from':_0x499617,'to':_0x499617,'id':_0x4db078,'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'](_0x736880,_0x465ccf){let _0x3a1cf7=this['editor']['config']['get']('initialData'),_0x4c9219=this['editor']['config']['get']('rootsAttributes');if(void 0x0===_0x3a1cf7){_0x3a1cf7={};for(const _0x2312a5 of this['editor']['model']['document']['getRootNames']())_0x3a1cf7[_0x2312a5]='';}if('string'==typeof _0x3a1cf7&&(_0x3a1cf7={'main':_0x3a1cf7}),void 0x0===_0x4c9219){_0x4c9219={};for(const _0x115e62 of this['editor']['model']['document']['getRootNames']())_0x4c9219[_0x115e62]={};}let _0x2b108=!0x1;const _0x28aa80=Object['keys'](_0x3a1cf7),_0x40c8c6=Object['keys'](_0x736880);for(const _0x14ab5f of _0x28aa80){if(_0x3a1cf7[_0x14ab5f]!==_0x736880[_0x14ab5f]&&''!==_0x3a1cf7[_0x14ab5f]['trim']()){_0x2b108=!0x0;break;}if(!_0x3f4dce(_0x4c9219[_0x14ab5f],_0x465ccf[_0x14ab5f])&&Object['keys'](_0x4c9219[_0x14ab5f])['length']>0x0){_0x2b108=!0x0;break;}}_0x2b108||(_0x2b108=_0x40c8c6['some'](_0x3f6135=>!this['editor']['model']['document']['getRoot'](_0x3f6135))),_0x2b108&&_0x3ffb6d('editor-initial-data-replaced-with-revision-data',{'editorData':_0x3a1cf7,'editorRootsAttributes':_0x4c9219,'revisionData':_0x736880,'revisionRootsAttributes':_0x465ccf}),this['editor']['config']['set']('initialData',_0x736880),this['editor']['config']['set']('rootsAttributes',_0x465ccf);}['_addPendingAction'](){if(!this['_pendingAction']){const _0xc3c4b9=this['editor']['plugins']['get']('PendingActions');this['_pendingAction']=_0xc3c4b9['add'](m(this['editor']['locale'],'PENDING_ACTION_REVISION_HISTORY'));}}['_removePendingAction'](){this['_pendingAction']&&(this['editor']['plugins']['get']('PendingActions')['remove'](this['_pendingAction']),this['_pendingAction']=null);}['_findInsertionIndex'](_0x3e014a){const _0xcc91c1=this['repository']['getRevisions']();_0xcc91c1['reverse']();let _0x131635=0x0;for(;_0x131635<_0xcc91c1['length'];){const _0x3b566e=_0xcc91c1[_0x131635];if(_0x3b566e===this['currentRevision']){_0x131635++;continue;}if(_0x3b566e['id']===this['_initialRevisionId'])break;const _0x4678ed=_0x3e014a['toVersion']-_0x3b566e['toVersion']||_0x3e014a['fromVersion']-_0x3b566e['fromVersion'];if(_0x4678ed>0x0)break;if(_0x4678ed<0x0)_0x131635++;else{if(!_0x3e014a['creator']&&_0x3b566e['creator'])break;if(_0x3b566e['creator']||!_0x3e014a['creator']){if(_0x3e014a['createdAt']>_0x3b566e['createdAt'])break;_0x131635++;}else _0x131635++;}}return _0x131635;}['_getFromVersion'](_0x20e953){const _0x19843f=this['repository']['getRevisions']();_0x19843f['reverse'](),_0x19843f['shift']();const _0x1c4d08=_0x19843f['find'](_0x493f8c=>_0x493f8c['toVersion']<=_0x20e953)['toVersion'];return _0x1c4d08<this['_startingVersion']?this['_startingVersion']:_0x1c4d08;}['_makeRevision']({name:_0x166323,from:_0xecd237,to:_0x5b4015,creatorId:_0x23e967,id:_0x2f4b3f}){const _0x120449=this['buildRevisionData']({'from':_0xecd237,'to':_0x5b4015});_0x120449['name']=_0x166323,_0x120449['creatorId']=_0x23e967,_0x120449['id']=_0x2f4b3f;const _0x33d837=this['addRevisionData'](_0x120449);return this['adapter']&&this['_bufferUpdate'](_0x120449['id'],_0x120449,!0x0),_0x33d837;}['_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(_0x49e115){this['editor']=_0x49e115,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'](_0x20d903){this['source']=_0x20d903;const _0x5caa60=new Map(),_0x1bb9fc=new Map(),_0x3809cb=this['editor']['model']['document']['roots']['map'](_0x1e5a03=>_0x1e5a03['rootName']);for(const _0x1cd796 of _0x3809cb){const _0x50708a=this['editor']['model']['document']['getRoot'](_0x1cd796),_0x5c4476=K(_0x50708a);_0x5caa60['set'](_0x1cd796,_0x5c4476),_0x1bb9fc['set'](_0x1cd796,Object['fromEntries'](_0x50708a['getAttributes']()));}const _0x3585d1=Array['from'](this['editor']['model']['markers'])['map'](_0x591f36=>[_0x591f36['name'],_0x591f36['getRange']()]),_0x24668b=this['source']['version'];this['_saveMetaData'](_0x24668b,_0x5caa60,_0x3585d1,_0x1bb9fc),this['_startingRevisionId']=this['_revisionId'];const _0x174d3b=new Map(),_0x12fbaf=new Map();for(const _0x286e68 of _0x3809cb){const _0x15c737=N(_0x286e68);_0x174d3b['set'](_0x286e68,_0x15c737),_0x12fbaf['set'](_0x286e68,{});}this['_saveMetaData'](Number['NEGATIVE_INFINITY'],_0x174d3b,[],_0x12fbaf);}['getData'](_0x35412f,_0x351768){if(this['_lastFrom']===_0x35412f&&this['_lastTo']<=_0x351768)this['_savedMetaData']['size']>0x1&&this['_removeMetaData'](this['_lastTo']),this['_applyOperations'](this['_lastTo'],_0x351768,!0x0);else{if(!this['_savedMetaData']['has'](_0x35412f)){const _0xefd0fb=this['_getPreviousFrom'](_0x35412f);this['_calculateMetaData'](_0xefd0fb,_0x35412f,!0x1);}this['_calculateMetaData'](_0x35412f,_0x351768,!0x0);}return this['_lastFrom']=_0x35412f,this['_lastTo']=_0x351768,this['_getState']();}['loadState'](_0x3bf40b){if(!this['_savedMetaData']['has'](_0x3bf40b['fromVersion'])){const _0x5d39a4=this['_getPreviousFrom'](_0x3bf40b['fromVersion']);this['_calculateMetaData'](_0x5d39a4,_0x3bf40b['fromVersion'],!0x1);}this['_calculateMetaData'](_0x3bf40b['fromVersion'],_0x3bf40b['toVersion'],!0x1);const _0x5f4a0b=this['editor']['plugins']['get']('RevisionHistoryUtils');this['_reset'](),this['_lastFrom']=_0x3bf40b['fromVersion'],this['_lastTo']=_0x3bf40b['toVersion'];for(const _0x25a72e in _0x3bf40b['diffData']){const _0x21df5a=_0x3bf40b['diffData'][_0x25a72e]['attachChange'],_0x3e3ba6=_0x4665e6(_0x3bf40b['diffData'][_0x25a72e]['attributesBefore'])||{},_0x2136e0=_0x5f4a0b['_makeModelFromViewString'](_0x3bf40b['diffData'][_0x25a72e]['deletions']);_0x2136e0['rootName']=_0x25a72e,_0x2136e0['_isAttached']=!_0x21df5a||!_0x21df5a['isAttached'],_0x2136e0['isAttached']=()=>_0x2136e0['_isAttached'],this['_baseRoots']['set'](_0x25a72e,_0x2136e0),this['_baseRootsAttributes']['set'](_0x25a72e,_0x3e3ba6),_0x21df5a&&this['_touchedRoots']['set'](_0x25a72e,_0x21df5a);const _0x3a29c5=this['_makeIdsRoot'](_0x2136e0);this['_baseIdsRoots']['set'](_0x25a72e,_0x3a29c5);for(const [_0x1d7096,_0x5bcd28]of _0x2136e0['markers']){if(!_0x1d7096['startsWith']('revision:'))continue;const _0x241b51=_0x1d7096['split'](':')[0x2];for(const _0x803e47 of _0x5bcd28['getWalker']({'singleCharacters':!0x0})){const _0x429aa1=this['_getVidAttributeName'](_0x803e47),_0x36b448='elementEnd'==_0x803e47['type']?_0x803e47['previousPosition']['path']['slice'](0x0,-0x1):_0x803e47['previousPosition']['path'],_0xa27cc=_0x3a29c5['getNodeByPath'](_0x36b448)['getAttribute'](_0x429aa1);this['_touched']['set'](_0xa27cc,{'userId':_0x241b51});}_0x2136e0['markers']['delete'](_0x1d7096);}}this['_startingRevisionId']=this['_revisionId'];const _0x5776f1=[...Array(this['_revisionId'])['keys']()]['slice'](0x1)['filter'](_0x36278b=>!this['_touched']['has'](_0x36278b));let _0x7ac4ab=0x0;const _0x58cf0c=new Map();for(const _0xbdf1cf in _0x3bf40b['diffData']){const _0x2fe28c=_0x3bf40b['diffData'][_0xbdf1cf]['attachChange'],_0x23d79a=_0x4665e6(_0x3bf40b['diffData'][_0xbdf1cf]['attributesAfter'])||{},_0x312896=_0x5f4a0b['_makeModelFromViewString'](_0x3bf40b['diffData'][_0xbdf1cf]['insertions']);_0x312896['rootName']=_0xbdf1cf,_0x312896['_isAttached']=!_0x2fe28c||_0x2fe28c['isAttached'],_0x312896['isAttached']=()=>_0x312896['_isAttached'],this['_diffRoots']['set'](_0xbdf1cf,_0x312896),this['_diffRootsAttributes']['set'](_0xbdf1cf,_0x23d79a);const _0x4b85b0=this['_makeIdsRoot'](_0x312896,Number['NEGATIVE_INFINITY']);this['_idsRoots']['set'](_0xbdf1cf,_0x4b85b0),_0x58cf0c['set'](_0xbdf1cf,_0x312896['isAttached']()?_0x23d79a:{});for(const [_0x37957a,_0x5bbb93]of _0x312896['markers']){if(!_0x37957a['startsWith']('revision:'))continue;const _0x37741e=_0x37957a['split'](':')[0x2];for(const _0x350a20 of _0x5bbb93['getWalker']({'singleCharacters':!0x0})){const _0x34affa=this['_getVidAttributeName'](_0x350a20),_0x17a68e=this['_revisionId']++,_0x5e90df='elementEnd'==_0x350a20['type']?_0x350a20['previousPosition']['path']['slice'](0x0,-0x1):_0x350a20['previousPosition']['path'];_0x4b85b0['getNodeByPath'](_0x5e90df)['_setAttribute'](_0x34affa,_0x17a68e),this['_touched']['set'](_0x17a68e,{'userId':_0x37741e});}_0x312896['markers']['delete'](_0x37957a);}for(const _0x39649e of this['editor']['model']['createRangeIn'](_0x312896)['getWalker']({'singleCharacters':!0x0})){const _0x2bb661=this['_getVidAttributeName'](_0x39649e),_0x461153='elementEnd'==_0x39649e['type']?_0x39649e['previousPosition']['path']['slice'](0x0,-0x1):_0x39649e['previousPosition']['path'],_0x26293b=_0x4b85b0['getNodeByPath'](_0x461153);_0x26293b['getAttribute'](_0x2bb661)>0x0||_0x26293b['_setAttribute'](_0x2bb661,_0x5776f1[_0x7ac4ab++]);}for(const [_0x19e6c,_0x155ac5]of _0x312896['markers'])_0x19e6c['startsWith']('revision:')||this['_markers']['set'](_0x19e6c,_0x155ac5);}const {roots:_0x30d5eb}=this['_savedMetaData']['get'](_0x3bf40b['fromVersion']),{roots:_0x2d36aa}=this['_savedMetaData']['get'](_0x3bf40b['toVersion']),_0x3c7223=K(_0x30d5eb['get']('$graveyard'));this['_baseRoots']['set']('$graveyard',_0x3c7223),this['_baseIdsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x3c7223,Number['NEGATIVE_INFINITY']));const _0xc5e3e5=K(_0x2d36aa['get']('$graveyard'));this['_diffRoots']['set']('$graveyard',_0xc5e3e5),this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0xc5e3e5));const _0xb0dd4c=Array['from'](this['_diffRoots'])['map'](([_0x11ce35,_0x134ce4])=>[_0x11ce35,K(_0x134ce4)]);this['_saveMetaData'](this['_lastTo'],_0xb0dd4c,this['_markers'],_0x58cf0c);}['reInit'](){this['_reset'](),this['_lastFrom']=-0x1,this['_lastTo']=-0x1,this['_savedMetaData']['clear'](),this['init'](this['source']);}['_saveMetaData'](_0x5115e9,_0x21e03a,_0x5c8229,_0x38fd3d){const _0x3ef789=new Map(_0x21e03a),_0x178043=new Map(_0x4665e6(_0x38fd3d)),_0x469086=new Map();for(const [_0x6c7039,_0x5154ad]of _0x5c8229)_0x469086['set'](_0x6c7039,{'start':_0x5154ad['start']['clone'](),'end':_0x5154ad['end']['clone'](),'rootName':_0x5154ad['root']['rootName']});this['_savedMetaData']['set'](_0x5115e9,{'roots':_0x3ef789,'markers':_0x469086,'rootsAttributes':_0x178043});}['_removeMetaData'](_0x50954e){this['_savedMetaData']['delete'](_0x50954e);}['_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'](_0x5bdf62,_0x3c1ec9=null){let _0x584c98=null;_0x5bdf62['is']('documentFragment')||(_0x584c98=new _0x314e33(_0x5bdf62['name'],{'vid_start':null===_0x3c1ec9?this['_revisionId']++:_0x3c1ec9++}));const _0x254914=[];for(const _0x5b8856 of _0x5bdf62['getChildren']())if(_0x5b8856['is']('element')){_0x254914['push'](this['_makeIdsRoot'](_0x5b8856,_0x3c1ec9));const _0x243526=_0x254914[_0x254914['length']-0x1];null!==_0x3c1ec9&&(_0x3c1ec9=_0x243526['is']('element','$text')?_0x243526['getAttribute']('vid')+0x1:_0x243526['getAttribute']('vid_end')+0x1);}else{for(let _0x28cb52=0x0;_0x28cb52<_0x5b8856['offsetSize'];_0x28cb52++)_0x254914['push'](new _0x314e33('$text',{'vid':null===_0x3c1ec9?this['_revisionId']++:_0x3c1ec9++}));}if(_0x5bdf62['is']('documentFragment')){const _0x388451=N(_0x5bdf62['rootName']);return _0x388451['_insertChild'](0x0,_0x254914),_0x388451;}return _0x584c98['_setAttribute']('vid_end',null===_0x3c1ec9?this['_revisionId']++:_0x3c1ec9++),_0x584c98['_insertChild'](0x0,_0x254914),_0x584c98;}['_calculateMetaData'](_0x408208,_0x441c53,_0x18e742){this['_reset']();const {roots:_0x489521,markers:_0x301c5f,rootsAttributes:_0x30d75d}=this['_savedMetaData']['get'](_0x408208);this['_baseRoots']=new Map(_0x489521),this['_baseRootsAttributes']=new Map(_0x4665e6(_0x30d75d));for(const [_0x1619bc,_0x4e27b9]of this['_baseRoots'])if('$graveyard'!==_0x1619bc&&(this['_diffRoots']['set'](_0x1619bc,K(_0x4e27b9)),this['_diffRootsAttributes']=new Map(_0x4665e6(_0x30d75d)),_0x18e742)){const _0x39d0f5=this['_revisionId'];this['_idsRoots']['set'](_0x1619bc,this['_makeIdsRoot'](_0x4e27b9)),this['_baseIdsRoots']['set'](_0x1619bc,this['_makeIdsRoot'](_0x4e27b9,_0x39d0f5));}this['_startingRevisionId']=this['_revisionId'],this['_diffRoots']['set']('$graveyard',K(this['_baseRoots']['get']('$graveyard'))),_0x18e742&&this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](this['_baseRoots']['get']('$graveyard')));for(const [_0x32e6c0,_0x26dcec]of _0x301c5f){const _0x3ee0ea=this['_baseRoots']['get'](_0x26dcec['rootName']),_0x36cdf8=this['_diffRoots']['get'](_0x26dcec['rootName']),_0xc94ec3=new _0x62b852(this['_fixPosition'](_0x26dcec['start'],_0x3ee0ea),this['_fixPosition'](_0x26dcec['end'],_0x3ee0ea)),_0x12dec1=this['_fixRange'](_0xc94ec3,_0x36cdf8);_0x3ee0ea['markers']['set'](_0x32e6c0,_0xc94ec3),this['_markers']['set'](_0x32e6c0,_0x12dec1);}this['_applyOperations'](_0x408208,_0x441c53,_0x18e742);}['_applyOperations'](_0x4cd570,_0x58b89d,_0xf706d6){for(const _0xb0bbb0 of this['source']['getOperations'](_0x4cd570,_0x58b89d))this['_handleOperation'](_0xb0bbb0,_0xf706d6);for(const _0x248b4d of this['_diffRoots']['values']())_0x248b4d['markers']['clear']();for(const [_0x4020b4,_0x4ad4f5]of this['_markers']){this['_diffRoots']['get'](_0x4ad4f5['root']['rootName'])['markers']['set'](_0x4020b4,_0x4ad4f5['clone']());}const _0x56e5ee=new Map(),_0x4735ef=new Map();for(const [_0x389d7d,_0xe74ff6]of this['_diffRoots'])_0x56e5ee['set'](_0x389d7d,K(_0xe74ff6)),_0x4735ef['set'](_0x389d7d,this['_diffRootsAttributes']['get'](_0x389d7d));this['_saveMetaData'](_0x58b89d,_0x56e5ee,this['_markers'],_0x4735ef);}['_getPreviousFrom'](_0x244597){const _0x427dd0=Array['from'](this['_savedMetaData']['keys']());_0x427dd0['sort']((_0x3d50e1,_0x1e792c)=>_0x3d50e1-_0x1e792c),_0x427dd0['reverse']();for(const _0x3bcd5e of _0x427dd0)if(_0x3bcd5e<_0x244597)return _0x3bcd5e;return Number['NEGATIVE_INFINITY'];}['_copyMarkers'](_0x3aea6f,_0x27d210){const _0x35c796=Array['from'](_0x27d210['markers'])['map'](([_0x301bc9,_0xea9a6d])=>[_0x301bc9,this['_fixRange'](_0xea9a6d,_0x3aea6f)]);_0x3aea6f['markers']=new Map(_0x35c796);}['_transformMarkers'](_0x58f9bf){for(const _0x458de0 of this['_markers']['values']()){const _0x5021eb=_0x458de0['getTransformedByOperation'](_0x58f9bf),_0x3891f6=_0x62b852['_createFromRanges'](_0x5021eb);_0x458de0['start']=_0x3891f6['start'],_0x458de0['end']=_0x3891f6['end'];}}['_handleOperation'](_0xd7d597,_0x34fb55){if('addRoot'!=_0xd7d597['type']&&'detachRoot'!=_0xd7d597['type']){if('insert'==_0xd7d597['type']){const _0x4c1838=_0xd7d597['position']['root']['rootName'];this['_diffRoots']['has'](_0x4c1838)||(this['_diffRoots']['set'](_0x4c1838,N(_0x4c1838,!0x0)),this['_diffRootsAttributes']['set'](_0x4c1838,{}),_0x34fb55&&this['_idsRoots']['set'](_0x4c1838,N(_0x4c1838,!0x0)));}else{if('addRootAttribute'==_0xd7d597['type']||'removeRootAttribute'==_0xd7d597['type']||'changeRootAttribute'==_0xd7d597['type'])return void this['_handleRootAttributeOperation'](_0xd7d597);'marker'==_0xd7d597['type']&&this['_handleMarkerOperation'](_0xd7d597);}if('marker'!==_0xd7d597['type']){const _0x2a33a6=this['_cloneOperation'](_0xd7d597,this['_diffRoots']);_0x2a33a6['_execute'](),this['_transformMarkers'](_0x2a33a6);}if(_0x34fb55)switch(_0xd7d597['type']){case'insert':this['_handleInsertOperation'](_0xd7d597);break;case'move':case'remove':case'reinsert':this['_handleMoveOperation'](_0xd7d597);break;case'merge':this['_handleMergeOperation'](_0xd7d597);break;case'split':this['_handleSplitOperation'](_0xd7d597);}}else this['_handleRootOperation'](_0xd7d597,_0x34fb55);}['_cloneOperation'](_0x24b091,_0x583e4b){const _0x222533=_0x24b091['clone']();return _0x222533['_authorId']=_0x24b091['_authorId'],this['_fixOperation'](_0x222533,_0x583e4b),_0x222533;}['_getBaseVids'](_0x3f22ae){return _0x3f22ae['map'](_0x35bbb0=>{const _0xd9432c=this['_getVidAttributeName'](_0x35bbb0);return Number(_0x35bbb0['item']['getAttribute'](_0xd9432c));});}['_generateTape'](_0xf7f263,_0x416734){if(_0xf7f263['is']('element','$text'))_0x416734['push']({'item':_0xf7f263,'type':'text'});else{_0xf7f263['is']('element')&&_0x416734['push']({'item':_0xf7f263,'type':'elementStart'});for(const _0x1992f0 of _0xf7f263['getChildren']())this['_generateTape'](_0x1992f0,_0x416734);_0xf7f263['is']('element')&&_0x416734['push']({'item':_0xf7f263,'type':'elementEnd'});}return _0x416734;}['_getState'](){const _0x31b5d5=new Map(this['_touched']),_0x2e8586=new Map(_0x31b5d5),_0x476bd8=new Map(),_0x1ef754={'insertions':{},'deletions':{}},_0x412872={'insertions':{},'deletions':{}},_0x13c05d=new Map(),_0x4a08a7=new Set([...this['_baseRoots']['keys'](),...this['_diffRoots']['keys']()]);_0x4a08a7['delete']('$graveyard');for(const _0x493fd3 of _0x4a08a7){const _0x54cf89=this['_diffRoots']['get'](_0x493fd3)||N(_0x493fd3,!0x1),_0x568144=this['_baseRoots']['get'](_0x493fd3)||N(_0x493fd3,!0x1);_0x54cf89['isAttached']()||_0x568144['isAttached']()?(_0x1ef754['insertions'][_0x493fd3]=K(_0x54cf89),_0x1ef754['deletions'][_0x493fd3]=K(_0x568144),this['_copyMarkers'](_0x1ef754['deletions'][_0x493fd3],_0x568144),this['_copyMarkers'](_0x1ef754['insertions'][_0x493fd3],_0x54cf89),_0x412872['insertions'][_0x493fd3]=this['_generateTape'](this['_idsRoots']['get'](_0x493fd3),[]),_0x412872['deletions'][_0x493fd3]=this['_generateTape'](this['_baseIdsRoots']['get'](_0x493fd3)||N(_0x493fd3,!0x1),[])):_0x4a08a7['delete'](_0x493fd3);}for(const _0x4e93c6 of _0x4a08a7){const _0xc46760=_0x412872['insertions'][_0x4e93c6];for(const _0x442832 of _0xc46760){const _0x24a9c2=this['_getVidAttributeName'](_0x442832),_0x13d15c=_0x442832['item']['getAttribute'](_0x24a9c2);_0x2e8586['delete'](_0x13d15c),_0x13d15c>=this['_startingRevisionId']&&_0x476bd8['set'](_0x13d15c,_0x31b5d5['get'](_0x13d15c));}}for(const _0x3b77d9 of _0x4a08a7){const _0x1a22e6=_0x412872['insertions'][_0x3b77d9],_0x55151d=this['_getBaseVids'](_0x412872['deletions'][_0x3b77d9]);let _0x154e1e=0x0;for(const _0x222ee8 of _0x1a22e6){const _0x21995e=this['_getVidAttributeName'](_0x222ee8),_0x51a103=_0x222ee8['item']['getAttribute'](_0x21995e);if(!_0x476bd8['has'](_0x51a103)&&!_0x13c05d['has'](_0x51a103)){if(_0x2e8586['has'](_0x51a103))_0x154e1e++;else{if(_0x51a103!=_0x55151d[_0x154e1e]){const _0x356ba9=_0x31b5d5['get'](_0x51a103)||_0x31b5d5['get'](_0x55151d[_0x154e1e]);for(;_0x51a103!=_0x55151d[_0x154e1e];)_0x2e8586['has'](_0x55151d[_0x154e1e])||(_0x13c05d['set'](_0x55151d[_0x154e1e],_0x356ba9),_0x31b5d5['set'](_0x55151d[_0x154e1e],_0x356ba9)),_0x154e1e++;}_0x154e1e++;}}}}for(const _0x5c9d0f of _0x4a08a7){const _0x5b2512=_0x412872['insertions'][_0x5c9d0f];for(const _0x4ba26f of _0x5b2512){const _0x346179=this['_getVidAttributeName'](_0x4ba26f),_0x1d81e1=_0x4ba26f['item']['getAttribute'](_0x346179);if(_0x13c05d['has'](_0x1d81e1)){const _0x2135f6=_0x13c05d['get'](_0x1d81e1);_0x2e8586['has'](_0x1d81e1)||_0x2e8586['set'](_0x1d81e1,{..._0x2135f6}),_0x476bd8['set'](_0x1d81e1,{..._0x2135f6});}}}for(const _0x3c0089 of _0x2e8586['keys']())_0x3c0089>=this['_startingRevisionId']&&_0x2e8586['delete'](_0x3c0089);const _0x198a63=new Map();for(const _0xc6a6c8 of _0x4a08a7){let _0x25eea6=_0x412872['insertions'][_0xc6a6c8];for(const _0x4724c2 of _0x25eea6)if(_0x4724c2['item']['is']('element','tableCell')){const _0x231447=this['_getVidAttributeName'](_0x4724c2),_0x39547a=_0x4724c2['item']['getAttribute'](_0x231447);if(_0x476bd8['has'](_0x39547a)){const _0x39bcb6=_0x4724c2['item']['parent']['parent']['getAttribute']('vid_start'),_0x486ec9=_0x198a63['get'](_0x39bcb6)||new Set();_0x486ec9['add'](_0x476bd8['get'](_0x39547a)['userId']),_0x198a63['set'](_0x39bcb6,_0x486ec9);}}_0x25eea6=_0x412872['deletions'][_0xc6a6c8];for(const _0x2c4c05 of _0x25eea6)if(_0x2c4c05['item']['is']('element','tableCell')){const _0x430ce3=this['_getVidAttributeName'](_0x2c4c05),_0x537f9=_0x2c4c05['item']['getAttribute'](_0x430ce3);if(_0x2e8586['has'](_0x537f9)){const _0xd4fb53=_0x2c4c05['item']['parent']['parent']['getAttribute']('vid_start'),_0x5af609=_0x198a63['get'](_0xd4fb53)||new Set();_0x5af609['add'](_0x2e8586['get'](_0x537f9)['userId']),_0x198a63['set'](_0xd4fb53,_0x5af609);}}for(const _0x2c8131 of _0x198a63['keys']())(_0x476bd8['has'](_0x2c8131)||_0x2e8586['has'](_0x2c8131))&&_0x198a63['delete'](_0x2c8131);}for(const _0xe57616 of _0x4a08a7){const _0x370f71=_0x412872['insertions'][_0xe57616];let _0x293e5e=null,_0x1f2eda=null;for(const _0x5ec8e6 of _0x370f71){const _0x14c26b=this['_getVidAttributeName'](_0x5ec8e6),_0x51a959=_0x5ec8e6['item']['getAttribute'](_0x14c26b),_0xbda7dc=_0x198a63['get'](_0x51a959);_0xbda7dc&&'elementStart'==_0x5ec8e6['type']&&(_0x293e5e=Array['from'](_0xbda7dc)[0x0],_0x1f2eda=_0x5ec8e6['item']['getAttribute']('vid_end')),_0x293e5e&&(_0x2e8586['set'](_0x51a959,{'userId':_0x293e5e}),_0x476bd8['set'](_0x51a959,{'userId':_0x293e5e})),_0x51a959==_0x1f2eda&&(_0x293e5e=null,_0x1f2eda=null);}}const _0xa3cd53={},_0x1c9a3a=new Set();for(const _0xdec91f of _0x4a08a7){const _0x294fd7=_0x1ef754['deletions'][_0xdec91f],_0x5bcfda=_0x1ef754['insertions'][_0xdec91f];for(const {userId:_0x5b6a99}of this['_touchedMarkers']['values']())null!==_0x5b6a99&&_0x1c9a3a['add'](_0x5b6a99);for(const {userId:_0x3265ae}of this['_touchedRoots']['values']())null!==_0x3265ae&&_0x1c9a3a['add'](_0x3265ae);this['_markChanges'](_0x5bcfda,_0x412872['insertions'][_0xdec91f],_0x476bd8,'insertion',_0x1c9a3a),this['_markChanges'](_0x294fd7,_0x412872['deletions'][_0xdec91f],_0x2e8586,'deletion',_0x1c9a3a),_0xa3cd53[_0xdec91f]={'insertions':this['_prepareViewToSave'](_0x5bcfda),'deletions':this['_prepareViewToSave'](_0x294fd7),'attachChange':this['_touchedRoots']['get'](_0xdec91f)||null,'attributesBefore':_0x4665e6(this['_baseRootsAttributes']['get'](_0xdec91f))||{},'attributesAfter':_0x4665e6(this['_diffRootsAttributes']['get'](_0xdec91f))};}return{'diffData':_0xa3cd53,'authorsIds':Array['from'](_0x1c9a3a)};}['_processRootBeforeSave'](_0x5c5995){for(const [,_0x3dbf43]of _0x5c5995['markers']){const _0x5acf72=_0x3dbf43['start']['getAncestors']()['filter'](_0x2dfad1=>'tableCell'==_0x2dfad1['name']);for(const _0x1dfc41 of _0x5acf72)0x1==_0x1dfc41['childCount']&&_0x1dfc41['getChild'](0x0)['is']('element','paragraph')&&_0x1dfc41['getChild'](0x0)['_setAttribute']('keepParagraph',!0x0);}}['_prepareViewToSave'](_0x515fca){this['_processRootBeforeSave'](_0x515fca);const _0x240457=this['editor']['data']['toView'](_0x515fca,{}),_0x1e3620=Array['from'](_0x240457['getChildren']())['map'](_0x464eec=>this['_getViewJson'](_0x464eec));return JSON['stringify'](_0x1e3620);}['_getViewJson'](_0x316287){if(_0x316287['is']('$text'))return _0x316287['data'];{const _0x371fed=this['editor']['plugins']['get']('RevisionHistoryUtils'),_0x26a347=_0x316287,_0x3164d9=this['editor']['data']['htmlProcessor']['domConverter'],_0x59f5e9={'type':_0x371fed['_getTypeCharForViewElement'](_0x26a347),'name':_0x26a347['name'],'attributes':Array['from'](_0x26a347['getAttributes']()),'children':Array['from'](_0x26a347['getChildren']())['map'](_0x3d3777=>this['_getViewJson'](_0x3d3777))};if(_0x316287['is']('uiElement')&&'$comment'!=_0x316287['name']){const _0x2369c4=_0x316287['render'](_0x3164d9['domDocument'],_0x3164d9);_0x59f5e9['children']['push'](_0x2369c4['outerHTML']);}else{if(_0x316287['is']('rawElement')){const _0xcda85d=_0x3164d9['domDocument']['createElement'](_0x26a347['name']);_0x316287['render'](_0xcda85d,_0x3164d9),_0x59f5e9['children']['push'](_0xcda85d['innerHTML']);}}const _0x645095=Array['from'](_0x26a347['getCustomProperties']());_0x645095['length']>0x0&&(_0x59f5e9['customProperties']=_0x645095);const _0x188be8=_0x26a347['getFillerOffset']();return null!==_0x188be8&&(_0x59f5e9['fillerOffset']=_0x188be8),_0x59f5e9;}}['_markChanges'](_0x1094f9,_0x300d9c,_0x235371,_0x2e8e02,_0x3bfdba){let _0x303d61=null,_0x111916=null,_0x98ff70=0x0;const _0x4e39f8=this['editor']['model'];for(let _0x16a5f9=0x0;_0x16a5f9<_0x300d9c['length'];_0x16a5f9++){const _0x39536b=this['_getVidAttributeName'](_0x300d9c[_0x16a5f9]),_0x407a98=_0x300d9c[_0x16a5f9]['item']['getAttribute'](_0x39536b),_0x16c15c=_0x235371['get'](_0x407a98),_0x4e40b2=_0x16a5f9==_0x300d9c['length']-0x1;(!_0x303d61&&_0x16c15c&&(_0x303d61=_0x16c15c,_0x111916=_0x300d9c[_0x16a5f9]),_0x303d61&&(!_0x16c15c||_0x16c15c['userId']!=_0x303d61['userId']))&&(_0xb7718b(_0x16c15c,P(_0x111916,_0x1094f9,_0x4e39f8),P(_0x300d9c[_0x16a5f9],_0x1094f9,_0x4e39f8)),_0x303d61=_0x16c15c||null,_0x111916=_0x16c15c?_0x300d9c[_0x16a5f9]:null),_0x303d61&&_0x4e40b2&&_0xb7718b(_0x16c15c,P(_0x111916,_0x1094f9,_0x4e39f8),V(_0x300d9c[_0x16a5f9],_0x1094f9,_0x4e39f8));}function _0xb7718b(_0x750add,_0x45f0a1,_0x414099){const _0x200e15=_0x303d61['userId'],_0x4b960c='revision:'+_0x2e8e02+':'+_0x200e15+':'+_0x98ff70++,_0x571d52=_0x4e39f8['createRange'](_0x45f0a1,_0x414099);_0x1094f9['markers']['set'](_0x4b960c,_0x571d52),null!==_0x200e15&&_0x3bfdba['add'](_0x200e15);}}['_getVidAttributeName'](_0x1e737f){switch(_0x1e737f['type']){case'elementStart':return'vid_start';case'elementEnd':return'vid_end';default:return'vid';}}['_fixOperation'](_0x2d5f9f,_0xdc36f3){_0x2d5f9f['baseVersion']=null;for(const _0x16be70 in _0x2d5f9f){const _0x581f0d=_0x2d5f9f[_0x16be70];if(_0x581f0d instanceof _0x1ddb04){const _0x5d0020=_0xdc36f3['get'](_0x581f0d['root']['rootName']);_0x2d5f9f[_0x16be70]=this['_fixPosition'](_0x581f0d,_0x5d0020);}if(_0x581f0d instanceof _0x62b852){const _0x149547=_0xdc36f3['get'](_0x581f0d['root']['rootName']);_0x2d5f9f[_0x16be70]=this['_fixRange'](_0x581f0d,_0x149547);}'root'===_0x16be70&&(_0x2d5f9f['root']=_0xdc36f3['get'](_0x2d5f9f['root']['rootName']));}}['_fixRange'](_0x17086c,_0x53d5cc){return this['editor']['model']['createRange'](this['_fixPosition'](_0x17086c['start'],_0x53d5cc),this['_fixPosition'](_0x17086c['end'],_0x53d5cc));}['_fixPosition'](_0x542dc1,_0x13b9c2){return this['editor']['model']['createPositionFromPath'](_0x13b9c2,_0x542dc1['path'],_0x542dc1['stickiness']);}['_handleInsertOperation'](_0x26ecff){const _0x2e527e=this['_idsRoots']['get'](_0x26ecff['position']['root']['rootName']),_0x4480cd=this['_fixPosition'](_0x26ecff['position'],_0x2e527e),_0x10ea3e=null===_0x26ecff['_authorId']?null:_0x26ecff['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x1b8f93=_0x4480cd['parent'],_0x1696d5=this['_revisionId'],_0x10666b=[];for(const _0x42048f of _0x26ecff['nodes'])if(_0x42048f['is']('element'))_0x10666b['push'](this['_makeIdsRoot'](_0x42048f));else{for(let _0x132561=0x0;_0x132561<_0x42048f['offsetSize'];_0x132561++)_0x10666b['push'](new _0x314e33('$text',{'vid':this['_revisionId']++}));}const _0x535072=this['_revisionId'];for(let _0x79954=_0x1696d5;_0x79954<_0x535072;_0x79954++)this['_touched']['set'](_0x79954,{'userId':_0x10ea3e});_0x1b8f93['_insertChild'](_0x4480cd['offset'],_0x10666b);}['_handleMoveOperation'](_0x200405){(_0x200405=this['_cloneOperation'](_0x200405,this['_idsRoots']))['_execute']();const _0x102679=null===_0x200405['_authorId']?null:_0x200405['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x46e970=_0x200405['getMovedRangeStart'](),_0x9503bc=_0x46e970['parent'],_0xbadce4=_0x46e970['offset'];!function _0x2cf3c1(_0x1b9b9d,_0x54305c,_0x211939,_0x30d728){for(let _0xc4fc54=_0x211939;_0xc4fc54<_0x30d728;_0xc4fc54++){const _0x1250a0=_0x54305c['getChild'](_0xc4fc54);_0x1250a0['is']('element','$text')?_0x1b9b9d['set'](_0x1250a0['getAttribute']('vid'),{'userId':_0x102679}):(_0x1b9b9d['set'](_0x1250a0['getAttribute']('vid_start'),{'userId':_0x102679}),_0x2cf3c1(_0x1b9b9d,_0x1250a0,0x0,_0x1250a0['childCount']),_0x1b9b9d['set'](_0x1250a0['getAttribute']('vid_end'),{'userId':_0x102679}));}}(this['_touched'],_0x9503bc,_0xbadce4,_0xbadce4+_0x200405['howMany']);}['_handleMergeOperation'](_0x19a19f){const _0x31ef24=null===(_0x19a19f=this['_cloneOperation'](_0x19a19f,this['_idsRoots']))['_authorId']?null:_0x19a19f['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x31bd81=_0x19a19f['targetPosition']['parent'],_0x5b4a89=_0x19a19f['sourcePosition']['parent'],_0x355236=_0x31bd81['getAttribute']('vid_end'),_0x1a52a9=_0x5b4a89['getAttribute']('vid_start');_0x31bd81['_setAttribute']('vid_end',_0x5b4a89['getAttribute']('vid_end')),_0x5b4a89['_setAttribute']('vid_end',_0x355236),this['_touched']['set'](_0x1a52a9,{'userId':_0x31ef24}),this['_touched']['set'](_0x355236,{'userId':_0x31ef24}),_0x19a19f['_execute']();}['_handleSplitOperation'](_0x32b031){const _0x2b7836=null===(_0x32b031=this['_cloneOperation'](_0x32b031,this['_idsRoots']))['_authorId']?null:_0x32b031['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x1987a8=_0x32b031['graveyardPosition'],_0xf42488=_0x32b031['splitPosition']['parent'];_0x32b031['_execute']();const _0x245896=_0xf42488['getAttribute']('vid_end'),_0x43afea=_0x32b031['insertionPosition']['nodeAfter'];if(_0x1987a8){const _0x2c5c6d=_0x43afea['getAttribute']('vid_end'),_0x1795a5=_0xf42488['getAttribute']('vid_end');_0xf42488['_setAttribute']('vid_end',_0x2c5c6d),_0x43afea['_setAttribute']('vid_end',_0x1795a5),this['_touched']['set'](_0xf42488['getAttribute']('vid_end'),{'userId':_0x2b7836}),this['_touched']['set'](_0x43afea['getAttribute']('vid_start'),{'userId':_0x2b7836});}else{const _0x4c5df3=this['_revisionId']++,_0x53f615=this['_revisionId']++;_0xf42488['_setAttribute']('vid_end',_0x4c5df3),_0x43afea['_setAttribute']('vid_start',_0x53f615),_0x43afea['_setAttribute']('vid_end',_0x245896),this['_touched']['set'](_0x4c5df3,{'userId':_0x2b7836}),this['_touched']['set'](_0x53f615,{'userId':_0x2b7836});}}['_handleMarkerOperation'](_0x3b0de3){if(!_0x3b0de3['affectsData'])return;const _0x3c36a3=(_0x3b0de3=this['_cloneOperation'](_0x3b0de3,this['_diffRoots']))['oldRange']?_0x3b0de3['oldRange']['root']:null,_0x10d49e=_0x3b0de3['newRange']?_0x3b0de3['newRange']['root']:null;_0x3c36a3&&this['_markers']['delete'](_0x3b0de3['name']),_0x10d49e&&this['_markers']['set'](_0x3b0de3['name'],_0x3b0de3['newRange']['clone']());const _0x5e00fd=null===_0x3b0de3['_authorId']?null:_0x3b0de3['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x31e1df=_0x3b0de3['name'];if(!this['_touchedMarkers']['has'](_0x31e1df))return void this['_touchedMarkers']['set'](_0x31e1df,{'range':_0x3b0de3['oldRange'],'userId':_0x5e00fd});const _0x3e75f6=this['_touchedMarkers']['get'](_0x31e1df),_0x1d1697=_0x3e75f6['range'],_0x29ff4d=_0x3b0de3['newRange'];null==_0x1d1697&&null==_0x29ff4d||_0x1d1697&&_0x29ff4d&&_0x1d1697['isEqual'](_0x29ff4d)?this['_touchedMarkers']['delete'](_0x3b0de3['name']):_0x3e75f6['userId']=_0x5e00fd;}['_handleRootOperation'](_0x101eba,_0x3eeae9){this['_diffRoots']['has'](_0x101eba['rootName'])?this['_diffRoots']['get'](_0x101eba['rootName'])['_isAttached']=_0x101eba['isAdd']:(this['_diffRoots']['set'](_0x101eba['rootName'],N(_0x101eba['rootName'],!0x0)),this['_diffRootsAttributes']['set'](_0x101eba['rootName'],{}),_0x3eeae9&&this['_idsRoots']['set'](_0x101eba['rootName'],N(_0x101eba['rootName'],!0x0)));const _0x4d6708=null===_0x101eba['_authorId']?null:_0x101eba['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x4874c0=this['_touchedRoots']['get'](_0x101eba['rootName']);_0x4874c0&&_0x4874c0['userId']===_0x4d6708?this['_touchedRoots']['delete'](_0x101eba['rootName']):this['_touchedRoots']['set'](_0x101eba['rootName'],{'userId':_0x4d6708,'isAttached':_0x101eba['isAdd']});}['_handleRootAttributeOperation'](_0xdabd5e){const _0x1a0f64=this['_diffRootsAttributes']['get'](_0xdabd5e['root']['rootName']);null===_0xdabd5e['newValue']?delete _0x1a0f64[_0xdabd5e['key']]:_0x1a0f64[_0xdabd5e['key']]=_0xdabd5e['newValue'];}}function K(_0x424191){const _0x1ac210=N(_0x424191['rootName'],_0x424191['isAttached']());for(const _0x2a3a5e of _0x424191['getChildren']()){const _0x4454a8=_0x2a3a5e['_clone'](!0x0);_0x1ac210['_appendChild'](_0x4454a8);}return _0x1ac210;}function N(_0x2f6e48,_0x298c07=!0x0){const _0x402fde=new _0x1237f0();return _0x402fde['rootName']=_0x2f6e48,_0x402fde['_isAttached']=_0x298c07,_0x402fde['isAttached']=()=>_0x402fde['_isAttached'],_0x402fde;}function P(_0x4fb238,_0x4ae669,_0x20a3a){const _0x343223='elementEnd'==_0x4fb238['type']?_0x20a3a['createPositionAt'](_0x4fb238['item'],'end'):_0x20a3a['createPositionBefore'](_0x4fb238['item']);return _0x20a3a['createPositionFromPath'](_0x4ae669,_0x343223['path'],_0x343223['stickiness']);}function V(_0x3a1dca,_0x4d83d3,_0x3e9c60){const _0x2206bf='elementStart'==_0x3a1dca['type']?_0x3e9c60['createPositionAt'](_0x3a1dca['item'],0x0):_0x3e9c60['createPositionAfter'](_0x3a1dca['item']);return _0x3e9c60['createPositionFromPath'](_0x4d83d3,_0x2206bf['path'],_0x2206bf['stickiness']);}class he extends/* #__PURE__ -- @preserve */
25
- _0x4d4ba6(_0x1f7714){['focusTracker'];['keystrokes'];['revisionNameInputView'];constructor(_0x55baf6,_0x4f2a0e){super(_0x55baf6),this['focusTracker']=new _0x45eb63(),this['keystrokes']=new _0x11da2f(),this['set']('revisionNameInputValue',''),this['revisionNameInputView']=this['_createRevisionNameInput'](_0x4f2a0e),this['setTemplate']({'tag':'form','attributes':{'class':['ck','ck-revision-history-save-revision-form','ck-responsive-form'],'tabindex':'-1'},'children':[this['revisionNameInputView']]}),this['initializeCssTransitionDisablerMixin']();}['render'](){super['render'](),_0x35ff4b({'view':this}),this['focusTracker']['add'](this['revisionNameInputView']['element']),this['keystrokes']['listenTo'](this['element']);const _0x491cab=_0x1718f2=>_0x1718f2['stopPropagation']();this['keystrokes']['set']('arrowright',_0x491cab),this['keystrokes']['set']('arrowleft',_0x491cab),this['keystrokes']['set']('arrowup',_0x491cab),this['keystrokes']['set']('arrowdown',_0x491cab);}['focus'](){this['revisionNameInputView']['focus']();}get['revisionName'](){return this['revisionNameInputView']['fieldView']['element']['value']['trim']();}set['revisionName'](_0x3c5b48){this['revisionNameInputView']['fieldView']['element']['value']=_0x3c5b48['trim']();}['reset'](){this['revisionNameInputView']['fieldView']['element']['value']='',this['revisionNameInputView']['errorText']=null;}['_createRevisionNameInput'](_0x3090ab){const _0x2911a4=new et(this['locale'],ti),_0x53adb4=_0x2911a4['fieldView'];_0x53adb4['extendTemplate']({'attributes':{'maxlength':'220'}});let _0x33f6b0=m(this['locale'],'Name\x20of\x20the\x20revision');return!_0x3090ab&&(_0x33f6b0+='\x20('+m(this['locale'],'optional')+')'),(_0x2911a4['label']=_0x33f6b0,_0x53adb4['on']('input',()=>{this['revisionNameInputValue']=_0x53adb4['element']['value']['trim']();}),_0x2911a4);}}class l extends _0x17be55{static get['pluginName'](){return'RevisionHistoryUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[h];}['_saveRevisionFormView'];['init'](){const _0x353286=this['editor'],_0x5c39f4=_0x353286['plugins']['get']('RevisionTracker');_0x353286['ui']['componentFactory']['add']('revisionHistory',_0x3b68bc=>{const _0x124da2=_0x3826ff(_0x3b68bc),_0x52dd61=_0x124da2['panelView']['children'],_0x29246d=new _0x403c33(_0x3b68bc),_0x740fd9=new _0x3ae127(_0x3b68bc),_0xc819fd=this['_createSaveRevisionButton'](_0x41e223),_0x54fc7b=new _0x3ae127(_0x3b68bc),_0x32dada=this['_createOpenRevisionButton'](_0x41e223);return _0x124da2['bind']('isEnabled')['to'](_0x5c39f4,'isReady',_0x5c39f4,'isEnabled',_0x353286,'isReadOnly',(_0x37ba94,_0x273275,_0x59370c)=>_0x37ba94&&_0x273275&&!_0x59370c),_0x124da2['buttonView']['set']({'icon':_0x30d3bd,'label':m(_0x3b68bc,'Revision\x20history'),'tooltip':!0x0}),_0xc819fd['set']({'withText':!0x0,'role':'menuitem'}),_0x32dada['set']({'withText':!0x0,'role':'menuitem'}),this['listenTo'](_0x32dada,'execute',()=>{_0x124da2['isOpen']=!0x1,_0x353286['editing']['view']['focus']();},{'priority':'low'}),_0x740fd9['children']['add'](_0xc819fd),_0x54fc7b['children']['add'](_0x32dada),_0x29246d['role']='menu',_0x29246d['items']['addMany']([_0x740fd9,_0x54fc7b]),_0x52dd61['add'](_0x29246d),_0x124da2;}),_0x353286['ui']['componentFactory']['add']('menuBar:revisionHistory',()=>this['_registerMenuComponent']());}['_registerMenuComponent'](){const _0x34164a=this['editor'],_0x2613ed=_0x34164a['locale'],_0x698dda=_0x34164a['plugins']['get']('RevisionTracker'),_0x4b0cb5=new _0x539594(_0x2613ed),_0x315ba9=new _0x309602(_0x2613ed);_0x4b0cb5['bind']('isEnabled')['to'](_0x698dda,'isReady',_0x698dda,'isEnabled',_0x34164a,'isReadOnly',(_0x2074e3,_0x188017,_0x4deb07)=>_0x2074e3&&_0x188017&&!_0x4deb07),_0x4b0cb5['buttonView']['set']({'icon':_0x30d3bd,'label':m(_0x2613ed,'Revision\x20history')});const _0x120ec7=new _0x57a792(_0x2613ed,_0x4b0cb5),_0x5ce76f=this['_createSaveRevisionButton'](_0x1ed467);_0x5ce76f['delegate']('execute')['to'](_0x4b0cb5),_0x120ec7['children']['add'](_0x5ce76f),_0x315ba9['items']['add'](_0x120ec7);const _0x28fb9c=new _0x57a792(_0x2613ed,_0x4b0cb5),_0x3bb475=this['_createOpenRevisionButton'](_0x1ed467);return _0x3bb475['delegate']('execute')['to'](_0x4b0cb5),_0x28fb9c['children']['add'](_0x3bb475),_0x315ba9['items']['add'](_0x28fb9c),_0x4b0cb5['panelView']['children']['add'](_0x315ba9),_0x4b0cb5;}['_createSaveRevisionButton'](_0x52ef44){const _0x3f05fd=this['editor'],_0x5c0564=_0x3f05fd['plugins']['get']('RevisionTracker'),_0x35d8c7=new _0x52ef44(_0x3f05fd['locale']);return _0x35d8c7['set']({'label':m(_0x3f05fd['locale'],'Save\x20current\x20revision')}),_0x35d8c7['bind']('isEnabled')['to'](_0x5c0564,'isReady',_0x5c0564,'isEnabled',_0x3f05fd,'isReadOnly',(_0x4a5eeb,_0x24f8b8,_0xa8ec21)=>_0x4a5eeb&&_0x24f8b8&&!_0xa8ec21),this['listenTo'](_0x35d8c7,'execute',()=>{this['_showDialog']();}),_0x35d8c7;}['_createOpenRevisionButton'](_0x53e549){const _0x3e2307=this['editor'],_0x1bd03b=_0x3e2307['plugins']['get']('RevisionTracker'),_0x2c6032=new _0x53e549(_0x3e2307['locale']);return _0x2c6032['set']({'label':m(_0x3e2307['locale'],'Open\x20revision\x20history')}),_0x2c6032['bind']('isEnabled')['to'](_0x1bd03b,'isReady',_0x3e2307,'isReadOnly',(_0x567fb5,_0x28aa3f)=>_0x567fb5&&!_0x28aa3f),this['listenTo'](_0x2c6032,'execute',()=>{_0x3e2307['config']['get']('revisionHistory')['showRevisionViewerCallback']();}),_0x2c6032;}['_showDialog'](){const _0x4df5d5=this['editor'],_0x5af12f=_0x4df5d5['locale'],_0x14bb21=_0x4df5d5['plugins']['get']('Dialog'),_0x258c00=_0x4df5d5['plugins']['get']('RevisionTracker');function _0x35ba00(_0x4445d7){_0x4df5d5['config']['get']('revisionHistory.requireRevisionName')&&''===_0x4445d7['revisionName']?_0x4445d7['revisionNameInputView']['errorText']=m(_0x5af12f,'The\x20revision\x20name\x20cannot\x20be\x20empty.'):(_0x4df5d5['plugins']['get'](h)['saveRevision']({'name':_0x4445d7['revisionName']}),_0x14bb21['hide']());}this['_saveRevisionFormView']||(this['_createSaveRevisionFormView'](),this['_saveRevisionFormView']['on']('submit',()=>_0x35ba00(this['_saveRevisionFormView']))),this['_saveRevisionFormView']['reset'](),_0x14bb21['show']({'id':'revisionSave','title':m(_0x5af12f,'Save\x20current\x20revision'),'isModal':!0x0,'content':this['_saveRevisionFormView'],'actionButtons':[{'label':m(_0x4df5d5['locale'],'Cancel'),'withText':!0x0,'onExecute':()=>_0x14bb21['hide']()},{'label':m(_0x4df5d5['locale'],'Accept'),'class':'ck-button-action','withText':!0x0,'onCreate'(_0xd43d9b){_0xd43d9b['bind']('isEnabled')['to'](_0x258c00,'isReady',_0x258c00,'isEnabled',_0x4df5d5,'isReadOnly',(_0x53045c,_0xa3a0c0,_0x1db58b)=>_0x53045c&&_0xa3a0c0&&!_0x1db58b);},'onExecute':()=>_0x35ba00(this['_saveRevisionFormView'])}]});}['_createSaveRevisionFormView'](){const _0x3dfa97=this['editor'],_0x565a24=_0x3dfa97['locale'];this['_saveRevisionFormView']=new he(_0x565a24,_0x3dfa97['config']['get']('revisionHistory.requireRevisionName')),this['_saveRevisionFormView']['render']();}}class z extends _0x1f7714{['changeId'];['_model'];constructor(_0x378fab,_0x370d32){super(_0x378fab),this['_model']=_0x370d32,this['changeId']=_0x370d32['id'];const _0x41b42f=this['bindTemplate'],_0x352582=m(_0x378fab,_0x370d32['data']['isSuggestion']?'Suggested\x20by':'add'==_0x370d32['type']?'Added\x20by':'Removed\x20by');this['set']('type',_0x370d32['type']),this['setTemplate']({'tag':'div','attributes':{'class':['ck-annotation','ck-revision-change',_0x41b42f['to']('type',_0x22c740=>'ck-revision-change__'+_0x22c740)],'tabindex':-0x1},'children':[{'tag':'span','children':[{'tag':'span','attributes':{'class':['ck-revision-change__label']},'children':[{'text':_0x352582}]},{'text':'\x20'+_0x370d32['author']['name']}]}]});}['focus'](){this['element']['focus']();}}class G extends/* #__PURE__ -- @preserve */
26
- _0x460399(){['id'];['author'];['type'];['data'];['rootName'];constructor(_0x5b9d3e){super(),this['id']=_0x5b9d3e['id']||_0x356b12(),this['author']=_0x5b9d3e['author'],this['type']=_0x5b9d3e['type'],this['data']=_0x5b9d3e['data']||{},this['rootName']=_0x5b9d3e['rootName'],this['set']('createdAt',_0x5b9d3e['createdAt']);}['toJSON'](){return{'id':this['id'],'authorId':this['author']['id'],'type':this['type'],'data':this['data'],'createdAt':this['createdAt']};}}class J{['newRevisionId'];['oldRevisionId'];['changes'];constructor(_0x4ec4b4,_0x11ab98){this['newRevisionId']=_0x4ec4b4,this['oldRevisionId']=_0x11ab98,this['changes']=new _0xd2e413();}['_setChanges'](_0xecfb2c){for(const _0x4a134e of _0xecfb2c)this['changes']['add'](_0x4a134e);}}class u extends _0x17be55{['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[_0xfbc7c8,_0x2649e2,S,$];}constructor(_0x5daa80){super(_0x5daa80),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',(_0x414c84,_0x538f15,_0x21fca0)=>{this['activeChange']=null,this['activeView']=null,this['editor']['editing']['view']['change'](_0x4b097f=>{for(const _0x117547 of this['editor']['editing']['view']['document']['roots'])_0x21fca0?_0x4b097f['removeClass']('ck-editor__editable__overlay',_0x117547):_0x4b097f['addClass']('ck-editor__editable__overlay',_0x117547);});}),this['bind']('isNavigationMode')['to'](this,'activeChange',_0x16501c=>null!==_0x16501c),this['bind']('currentChangeNumber')['to'](this,'isReady',this,'diff',this,'activeChange',(_0x54fa76,_0x15a16d,_0x35269e)=>_0x54fa76&&_0x35269e?_0x15a16d['changes']['getIndex'](_0x35269e):0x0),this['bind']('numberOfChanges')['to'](this,'isReady',this,'diff',(_0x104f3a,_0x5a6d2b)=>_0x104f3a?_0x5a6d2b['changes']['length']:0x0),this['_changeView']=null,this['_changeIdToChange']=new Map(),this['_balloon']=this['editor']['plugins']['get'](_0x2649e2);}['init'](){const _0x463aa1=this['editor'],_0x235cbc=new rt(_0x463aa1,{'direction':'backward'}),_0x1ee219=new rt(_0x463aa1,{'direction':'forward'});(_0x463aa1['commands']['add']('showPreviousChange',_0x235cbc),_0x463aa1['commands']['add']('showNextChange',_0x1ee219),_0x463aa1['commands']['add']('restoreRevision',new nt(_0x463aa1)),this['on']('change:numberOfChanges',()=>{_0x235cbc['refresh'](),_0x1ee219['refresh']();}),this['_setConversion'](),this['_initInteractions'](),_0x463aa1['enableReadOnlyMode']('revision-viewer'),_0x463aa1['plugins']['has']('WidgetToolbarRepository'))&&_0x463aa1['plugins']['get']('WidgetToolbarRepository')['forceDisabled']('revision-viewer');}async['getRevisionDocumentData'](_0x184165){return await this['_utils']['loadRevisionData'](_0x184165,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x184165);}async['getRevisionRootsAttributes'](_0x2401c5){return await this['_utils']['loadRevisionData'](_0x2401c5,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x2401c5);}async['compare'](_0x562b13,_0x14a3a7,_0x437cb1=!0x1){if(!this['isEnabled'])return;const _0x5c5239=this['diff'],_0x2a1476=this['repository'],_0x37849a='string'==typeof _0x562b13?_0x2a1476['getRevision'](_0x562b13):_0x562b13,_0x436007='string'==typeof _0x14a3a7?_0x2a1476['getRevision'](_0x14a3a7):_0x14a3a7,_0x26c646=_0x37849a['id'],_0x44a809=_0x436007?_0x436007['id']:null;if(!_0x437cb1&&this['diff']&&this['diff']['newRevisionId']===_0x26c646&&this['diff']['oldRevisionId']===_0x44a809)return Promise['resolve']();this['isReady']=!0x1,this['activeView']=null,this['activeChange']=null,this['diff']=new J(_0x26c646,_0x44a809);const _0x50b65f=this['_getRevisionsRange'](_0x37849a,_0x436007,!0x0)['map'](_0x59a8d4=>this['_utils']['loadRevisionData'](_0x59a8d4,this['adapter']));return _0x50b65f['push'](new Promise(_0x36405f=>{setTimeout(_0x36405f,0x14);})),Promise['all'](_0x50b65f)['then'](()=>{if(!this['isEnabled'])return;this['_cleanUp']();const _0x4dfab2=this['_getDiff'](_0x26c646,_0x44a809);for(const _0x3003fa of _0x4dfab2['changes'])this['_changeIdToChange']['set'](_0x3003fa['id'],_0x3003fa);this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x358a02=>{for(const _0x56cdf4 of this['editor']['model']['document']['getRootNames']())_0x358a02['detachRoot'](_0x56cdf4);for(const _0x3f85d1 of Object['keys'](_0x4dfab2['model'])){const _0x5e6457=_0x358a02['addRoot'](_0x3f85d1);for(const _0x22a6fb of Object['keys'](_0x4dfab2['attributes'][_0x3f85d1]))_0x358a02['setAttribute'](_0x22a6fb,_0x4dfab2['attributes'][_0x3f85d1][_0x22a6fb],_0x5e6457);_0x358a02['insert'](_0x4dfab2['model'][_0x3f85d1],_0x5e6457,0x0);}}),this['diff']['_setChanges'](this['_sortAndFilterDiffChanges'](_0x4dfab2['changes'])),this['isReady']=!0x0;})['catch'](_0x1d0402=>{console['error'](_0x1d0402),this['_cleanUp'](),_0x5c5239&&(this['diff']=_0x5c5239),this['isReady']=!0x0;});}['addRevisionData'](_0x5e4299,_0x56ac03){const _0x493254=this['repository']['createRevision'](_0x5e4299);return _0x493254['on']('_update',(_0x192fb3,_0x4d1e37,_0x50853f)=>_0x56ac03(_0x4d1e37,_0x50853f,_0x493254)),this['repository']['addRevision'](_0x493254),_0x493254;}['_cleanUp'](){this['activeChange']=null,this['_cleanMarkers'](),this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=null,this['_changeIdToChange']['clear'](),this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x3bc6d1=>{for(const _0x296fe7 of this['editor']['model']['document']['getRootNames']())_0x3bc6d1['detachRoot'](_0x296fe7);});}['_sortAndFilterDiffChanges'](_0x2b8868){const _0x11f724=[],_0x4e0338=new Map();for(const _0x257eed of this['editor']['model']['document']['getRootNames']()){const _0x1e7601=this['editor']['editing']['view']['getDomRoot'](_0x257eed);if(!_0x1e7601)continue;const _0x55167a=_0x1e7601['getClientRects']()['item'](0x0);_0x55167a&&(_0x11f724['push'](_0x257eed),_0x4e0338['set'](_0x257eed,_0x55167a));}return _0x11f724['sort']((_0x51d242,_0x35b502)=>{const _0x1f8626=_0x4e0338['get'](_0x51d242),_0x2a4650=_0x4e0338['get'](_0x35b502);return _0x1f8626['y']-_0x2a4650['y']||_0x1f8626['x']-_0x2a4650['x'];}),(_0x2b8868=_0x2b8868['filter'](_0x54ff7f=>_0x11f724['includes'](_0x54ff7f['rootName'])))['sort']((_0x472237,_0x174a88)=>_0x11f724['indexOf'](_0x472237['rootName'])-_0x11f724['indexOf'](_0x174a88['rootName'])),_0x2b8868;}['_makeTape'](_0x4cce70){const _0x3a4b15=Array['from'](_0x4cce70['markers'])['filter'](([_0x3e3d53,_0x34b3a7])=>_0x3e3d53['startsWith']('revision:')&&!_0x34b3a7['isCollapsed']),_0x3779f6=Array['from'](this['editor']['model']['createRangeIn'](_0x4cce70)['getWalker']({'singleCharacters':!0x0}));if(0x0!=_0x3a4b15['length'])for(const _0x15ae87 of _0x3779f6){const [_0x4b6d24,_0x1a454e]=_0x3a4b15[0x0],[,_0x1e7832,_0x4ca6a1]=_0x4b6d24['split'](':');if(_0x1a454e['end']['isEqual'](_0x15ae87['nextPosition'])&&_0x3a4b15['shift'](),(_0x15ae87['previousPosition']['isEqual'](_0x1a454e['start'])||_0x15ae87['previousPosition']['isAfter'](_0x1a454e['start']))&&('insertion'==_0x1e7832?_0x15ae87['isAdded']={'userId':_0x4ca6a1}:'deletion'==_0x1e7832&&(_0x15ae87['isRemoved']={'userId':_0x4ca6a1})),0x0==_0x3a4b15['length'])break;}return _0x3779f6;}['_refreshStartEndIndex'](_0x436886){const _0x46e093=new Map();for(let _0x3140bc=0x0;_0x3140bc<_0x436886['length'];_0x3140bc++)'text'===_0x436886[_0x3140bc]['type']?(_0x436886[_0x3140bc]['item']['startIndex']=_0x3140bc,_0x436886[_0x3140bc]['item']['endIndex']=_0x3140bc):('elementStart'===_0x436886[_0x3140bc]['type']?_0x436886[_0x3140bc]['item']['startIndex']=_0x3140bc:'elementEnd'===_0x436886[_0x3140bc]['type']&&(_0x436886[_0x3140bc]['item']['endIndex']=_0x3140bc),_0x46e093['set'](_0x436886[_0x3140bc]['id'],_0x3140bc));for(const _0x49a88e of _0x46e093['values']())'elementStart'===_0x436886[_0x49a88e]['type']?_0x436886[_0x49a88e]['item']['endIndex']=_0x46e093['get'](_0x436886[_0x49a88e]['pairId']):'elementEnd'===_0x436886[_0x49a88e]['type']&&(_0x436886[_0x49a88e]['item']['startIndex']=_0x46e093['get'](_0x436886[_0x49a88e]['pairId']));}['_processTape'](_0x50c9fc){for(let _0x1ffd62=0x0;_0x1ffd62<_0x50c9fc['length'];_0x1ffd62++){if('elementStart'===_0x50c9fc[_0x1ffd62]['type'])_0x50c9fc[_0x1ffd62]['item']['startIndex']=_0x1ffd62;else{if('elementEnd'===_0x50c9fc[_0x1ffd62]['type']){_0x50c9fc[_0x1ffd62]['item']['endIndex']=_0x1ffd62;const _0x17b361=_0x50c9fc[_0x1ffd62]['item']['startIndex'];_0x50c9fc[_0x17b361]['pairId']=_0x50c9fc[_0x1ffd62]['id'],_0x50c9fc[_0x1ffd62]['pairId']=_0x50c9fc[_0x17b361]['id'];}else _0x50c9fc[_0x1ffd62]['item']['startIndex']=_0x1ffd62,_0x50c9fc[_0x1ffd62]['item']['endIndex']=_0x1ffd62,_0x50c9fc[_0x1ffd62]['pairId']=null;}_0x50c9fc[_0x1ffd62]['markersStart']||(_0x50c9fc[_0x1ffd62]['markersStart']=[],_0x50c9fc[_0x1ffd62]['markersEnd']=[]);}}['_markInsertions'](_0x477289,_0x3ecb24){const _0x4af95c=_0x477289['filter'](_0x332e6e=>!_0x332e6e['isAdded']);for(let _0x20bd72=0x0;_0x20bd72<_0x3ecb24['length'];_0x20bd72++)_0x3ecb24[_0x20bd72]['isAdded']&&(_0x4af95c[_0x20bd72]['isAdded']=_0x3ecb24[_0x20bd72]['isAdded']);}['_getDiff'](_0x4c9538,_0x1a16a2=null){const _0x58f179=this['repository']['getRevision'](_0x4c9538),_0x2469fe=_0x1a16a2?this['repository']['getRevision'](_0x1a16a2):null,_0x3f1425=this['_getRevisionsRange'](_0x58f179,_0x2469fe),_0x287694=_0x3f1425[_0x3f1425['length']-0x1],_0x53186a=new Map(),_0x4e3e3e={'model':{},'attributes':{},'changes':[]},_0x2b4401=new Set(),_0x70979d=new Map();for(let _0x5566a4=_0x3f1425['length']-0x1;_0x5566a4>=0x0;_0x5566a4--){const _0x32468e=_0x3f1425[_0x5566a4];for(const _0x44bcb0 of Object['keys'](_0x32468e['diffData']))if(_0x32468e['diffData'][_0x44bcb0]['attachChange']){const _0x1e3ccd=_0x32468e['diffData'][_0x44bcb0]['attachChange'];_0x1e3ccd['isAttached']?(_0x2b4401['add'](_0x44bcb0),_0x70979d['has'](_0x44bcb0)&&_0x70979d['get'](_0x44bcb0)['userId']==_0x1e3ccd['userId']?_0x70979d['delete'](_0x44bcb0):_0x70979d['set'](_0x44bcb0,_0x1e3ccd)):_0x70979d['has'](_0x44bcb0)?(_0x2b4401['delete'](_0x44bcb0),_0x70979d['delete'](_0x44bcb0)):(_0x2b4401['add'](_0x44bcb0),_0x70979d['set'](_0x44bcb0,_0x1e3ccd));}else _0x2b4401['add'](_0x44bcb0);}for(const _0x4d2ee0 of _0x2b4401){const _0x10c7ad=_0x70979d['has'](_0x4d2ee0)&&!_0x70979d['get'](_0x4d2ee0)['isAttached'];let _0x632d99=_0x10c7ad?_0x3f1425['length']-0x1:0x0;const _0x30ab0c=_0x10c7ad?-0x1:0x1;for(;_0x3f1425[_0x632d99];){const _0x48928f=_0x3f1425[_0x632d99];if(_0x48928f['diffData'][_0x4d2ee0]){const _0x4146e9=_0x10c7ad?_0x48928f['diffData'][_0x4d2ee0]['attributesBefore']:_0x48928f['diffData'][_0x4d2ee0]['attributesAfter'];_0x4e3e3e['attributes'][_0x4d2ee0]=_0x4146e9?_0x4665e6(_0x4146e9):{};break;}_0x632d99+=_0x30ab0c;}}for(const _0x3f00f8 of _0x3f1425){_0x3f00f8['model']={};for(const _0x2a23f6 of _0x3f00f8['authors'])_0x53186a['set'](_0x2a23f6['id'],_0x2a23f6);for(const _0x4e08a2 of _0x2b4401){const _0x21a13c=_0x3f00f8['diffData'][_0x4e08a2]?_0x3f00f8['diffData'][_0x4e08a2]['insertions']:'[]',_0x204cf4=_0x3f00f8['diffData'][_0x4e08a2]?_0x3f00f8['diffData'][_0x4e08a2]['deletions']:'[]';_0x3f00f8['model'][_0x4e08a2]={'insertions':this['_utils']['_makeModelFromViewString'](_0x21a13c),'deletions':this['_utils']['_makeModelFromViewString'](_0x204cf4)};}}for(const _0x8eac25 of _0x2b4401){let _0x3a3be0=null,_0x3d0df7=0x0;const _0x72583c=new Map(Array['from'](_0x58f179['model'][_0x8eac25]['insertions']['markers'])['filter'](([_0x38af13])=>!_0x38af13['startsWith']('revision:')));let _0x3a75c7=0x0;for(const _0x14a32e of _0x3f1425){const _0x3dd3bd=this['_makeTape'](_0x14a32e['model'][_0x8eac25]['insertions']);_0x14a32e==_0x58f179?(_0x3a3be0=_0x3dd3bd,_0x3d0df7=_0x3a3be0['length'],_0x3a3be0['forEach'](_0x18f47b=>{_0x18f47b['id']=_0x3a75c7++;}),this['_processTape'](_0x3a3be0)):this['_markInsertions'](_0x3a3be0,_0x3dd3bd);const _0x5ef22b=_0x3a3be0['filter'](_0x3f37b5=>!_0x3f37b5['isAdded'])['map'](_0x2ac1be=>_0x2ac1be['id']);let _0x4de19a=0x0;const _0x376312=this['_makeTape'](_0x14a32e['model'][_0x8eac25]['deletions']);_0x376312['forEach'](_0x1b20b8=>{_0x1b20b8['isRemoved']?_0x1b20b8['id']=_0x3d0df7++:_0x1b20b8['id']=_0x5ef22b[_0x4de19a++];}),this['_processTape'](_0x376312),this['_setDistance'](_0x3a3be0,'isAdded'),this['_setDistance'](_0x376312,'isRemoved'),_0x14a32e==_0x58f179&&this['_markMarkers'](_0x3a3be0,_0x72583c),_0x3a3be0=this['_joinTapes'](_0x3a3be0,_0x376312),this['_refreshStartEndIndex'](_0x3a3be0),this['_setDistance'](_0x3a3be0,'isRemoved');}_0x3a3be0=_0x3a3be0['filter'](_0x38b8b0=>!(_0x38b8b0['isAdded']&&_0x38b8b0['isRemoved']));const _0x25847a=new Map(_0x287694['model'][_0x8eac25]['deletions']['markers']),_0x23eba2=new Set(_0x72583c['keys']());for(const _0x3734b0 of _0x25847a['keys']())_0x23eba2['delete'](_0x3734b0);this['_markSuggestions'](_0x3a3be0,_0x23eba2),this['_fixObsoleteTags'](_0x3a3be0),_0x3a3be0=this['_removeMissingPairs'](_0x3a3be0),_0x3a3be0=this['_markMismatchedRemovedTags'](_0x3a3be0),_0x3a3be0=this['_removeUnsupportedChanges'](_0x3a3be0);const {root:_0x2e40b0,changes:_0x2b9203}=this['_makeModelFromTape'](_0x3a3be0,_0x53186a,_0x8eac25);_0x4e3e3e['model'][_0x8eac25]=_0x2e40b0;const _0x42825d=_0x70979d['get'](_0x8eac25);if(_0x42825d){const _0x47f254=_0x53186a['get'](_0x42825d['userId']),_0x111810=new G({'author':_0x47f254,'type':_0x42825d['isAttached']?'add':'remove','data':{'isOnRoot':!0x0},'createdAt':new Date(),'rootName':_0x8eac25});_0x2b9203['unshift'](_0x111810),_0x4e3e3e['attributes'][_0x8eac25]['revisionHistoryAttachChange']=_0x111810['id'];}_0x4e3e3e['changes']=_0x4e3e3e['changes']['concat'](_0x2b9203);}return _0x4e3e3e;}['_markMarkers'](_0x3b9d6a,_0x3da726){for(let _0xb8f5b8=0x0;_0xb8f5b8<_0x3b9d6a['length'];_0xb8f5b8++)for(const [_0x352659,_0x23b945]of _0x3da726)!_0x23b945['isCollapsed']&&_0x23b945['start']['isEqual'](_0x3b9d6a[_0xb8f5b8]['previousPosition'])&&_0x3b9d6a[_0xb8f5b8]['markersStart']['push'](_0x352659),_0x23b945['end']['isEqual'](_0x3b9d6a[_0xb8f5b8]['nextPosition'])&&_0x3b9d6a[_0xb8f5b8]['markersEnd']['push'](_0x352659);}['_joinTapes'](_0x5437a5,_0x4f9f7a){let _0x180076=[],_0x48dd00=0x0,_0x93e4ac=0x0;for(;_0x48dd00<_0x5437a5['length']||_0x93e4ac<_0x4f9f7a['length'];){const _0x125e1e=_0x5437a5[_0x48dd00]||{},_0x10f980=_0x4f9f7a[_0x93e4ac]||{};if(_0x125e1e['id']==_0x10f980['id'])_0x48dd00++,_0x93e4ac++,_0x180076['push'](_0x125e1e);else{if(_0x10f980['isRemoved']&&_0x125e1e['isAdded']){const {commonTape:_0x722fc5,iEnd:_0x5be2f5,jEnd:_0xb7c1bb}=this['_threeWayMerge'](_0x5437a5,_0x48dd00,_0x4f9f7a,_0x93e4ac);_0x180076=_0x180076['concat'](_0x722fc5),_0x48dd00=_0x5be2f5,_0x93e4ac=_0xb7c1bb;}else _0x10f980['isRemoved']?(_0x93e4ac++,_0x180076['push'](_0x10f980)):(_0x48dd00++,_0x180076['push'](_0x125e1e));}}return _0x180076;}['_markSuggestions'](_0x4df35f,_0xfd02b6){const _0x4c9481=[];for(let _0x273966=0x0;_0x273966<_0x4df35f['length'];_0x273966++){for(let _0x2e41b1=0x0;_0x2e41b1<_0x4df35f[_0x273966]['markersStart']['length'];_0x2e41b1++){const _0x5b78d3=_0x4df35f[_0x273966]['markersStart'][_0x2e41b1];if(!_0xfd02b6['has'](_0x5b78d3))continue;const {group:_0x3cb270,type:_0x2a6a0a,authorId:_0x3ecaa3}=_0x1892b9(_0x5b78d3);'revision-suggestion'!=_0x3cb270||'insertion'!=_0x2a6a0a&&'deletion'!=_0x2a6a0a||(_0x4c9481['unshift']({'type':_0x2a6a0a,'name':_0x5b78d3,'userId':_0x3ecaa3}),_0x4df35f[_0x273966]['markersStart']['splice'](_0x2e41b1,0x1),_0x2e41b1--);}_0x56f68e(_0x4df35f[_0x273966]);for(let _0x21b877=0x0;_0x21b877<_0x4df35f[_0x273966]['markersEnd']['length'];_0x21b877++){const _0x5c5ce8=_0x4df35f[_0x273966]['markersEnd'][_0x21b877];if(!_0xfd02b6['has'](_0x5c5ce8))continue;const {group:_0x443e5b,type:_0x2940b9}=_0x1892b9(_0x5c5ce8);if('revision-suggestion'!=_0x443e5b||'insertion'!=_0x2940b9&&'deletion'!=_0x2940b9)continue;_0x4df35f[_0x273966]['markersEnd']['splice'](_0x21b877,0x1),_0x21b877--;const _0x1bfde2=_0x4c9481['findIndex'](_0x3fcd0b=>_0x3fcd0b['name']==_0x5c5ce8);_0x1bfde2>-0x1&&_0x4c9481['splice'](_0x1bfde2,0x1);}}function _0x1892b9(_0x245fb3){const _0x59c2f8=_0x245fb3['split'](':');return{'group':_0x59c2f8[0x0],'type':_0x59c2f8[0x1],'subType':_0x59c2f8['length']>=0x5?_0x59c2f8[0x2]:null,'id':_0x59c2f8['length']<0x5?_0x59c2f8[0x2]:_0x59c2f8[0x3],'authorId':_0x59c2f8['length']<0x5?_0x59c2f8[0x3]:_0x59c2f8[0x4],'markerCount':0x6==_0x59c2f8['length']?_0x59c2f8[0x5]:null};}function _0x56f68e(_0x540c5f){for(let _0x110e15=0x0;_0x110e15<_0x4c9481['length'];_0x110e15++){if(_0x540c5f['isAdded']&&'insertion'==_0x4c9481[_0x110e15]['type']&&_0x540c5f['isAdded']['userId']==_0x4c9481[_0x110e15]['userId'])return _0x540c5f['isAddSuggestion']=_0x4c9481[_0x110e15],void delete _0x540c5f['isAdded'];if(!_0x540c5f['isAdded']&&!_0x540c5f['isRemoved']&&'deletion'==_0x4c9481[_0x110e15]['type'])return void(_0x540c5f['isRemoveSuggestion']=_0x4c9481[_0x110e15]);}}}['_setDistance'](_0x212a64,_0x275baa){let _0x1c15f4=0x0,_0x45a78c=!0x1;const _0xd13877=new Map();for(const _0x30a58e of _0x212a64)_0x30a58e[_0x275baa]?_0x45a78c&&(_0x1c15f4++,_0x45a78c=!0x1):(_0x1c15f4++,_0x45a78c=!0x0),_0xd13877['set'](_0x30a58e['id'],_0x1c15f4);for(let _0x1933a9=0x0;_0x1933a9<_0x212a64['length'];_0x1933a9++){if('isRemoved'==_0x275baa&&_0x212a64[_0x1933a9]['isAdded']||'isAdded'==_0x275baa&&_0x212a64[_0x1933a9]['isRemoved'])continue;if('text'==_0x212a64[_0x1933a9]['type']){_0x212a64[_0x1933a9]['distance']=0x0;continue;}const _0x3eb800=_0xd13877['get'](_0x212a64[_0x1933a9]['pairId']),_0xcbd20a=_0xd13877['get'](_0x212a64[_0x1933a9]['id']);_0x212a64[_0x1933a9]['distance']=_0x3eb800-_0xcbd20a;}}['_getRevisionsRange'](_0x19d522,_0x3f0e55,_0xc237e3=!0x1){const _0x2729c1=[];let _0x27aa96=this['repository']['getIndex'](_0x19d522),_0xce77e6=this['repository']['getIndex'](_0x3f0e55);for(-0x1==_0xce77e6&&(_0xce77e6=this['repository']['_revisions']['length'],_0xc237e3=!0x1);_0x27aa96<_0xce77e6;)_0x2729c1['push'](this['repository']['getRevision'](_0x27aa96)),_0x27aa96++;return _0xc237e3&&_0x2729c1['push'](this['repository']['getRevision'](_0x27aa96)),_0x2729c1;}['_threeWayMerge'](_0x1194c7,_0x7a4638,_0x321b69,_0x32774e){const _0x13a947=this['editor']['model']['schema'];let _0x37d433=_0x7a4638;for(;_0x1194c7[_0x37d433]&&_0x1194c7[_0x37d433]['isAdded'];)_0x37d433++;let _0x4cea6a=_0x32774e;for(;_0x321b69[_0x4cea6a]&&_0x321b69[_0x4cea6a]['isRemoved'];)_0x4cea6a++;_0xd29ad8(_0x1194c7,_0x7a4638,_0x37d433),_0xd29ad8(_0x321b69,_0x32774e,_0x4cea6a);const _0x216a7c=_0x321b69['slice'](_0x32774e,_0x4cea6a)['concat'](_0x1194c7['slice'](_0x7a4638,_0x37d433));return _0x216a7c['sort']((_0x5f2bce,_0x1d26c8)=>_0x5f2bce['side']!=_0x1d26c8['side']?_0x5f2bce['side']-_0x1d26c8['side']:_0x5f2bce['level']!=_0x1d26c8['level']?_0x5f2bce['level']-_0x1d26c8['level']:_0x5f2bce['distance']!=_0x1d26c8['distance']?_0x1d26c8['distance']-_0x5f2bce['distance']:!!_0x5f2bce['isAdded']!=!!_0x1d26c8['isAdded']?-0x1==_0x5f2bce['side']||0x0==_0x5f2bce['side']?_0x5f2bce['isAdded']?-0x1:0x1:_0x5f2bce['isAdded']?0x1:-0x1:_0x5f2bce['index']-_0x1d26c8['index']),{'commonTape':_0x216a7c,'iEnd':_0x37d433,'jEnd':_0x4cea6a};function _0xd29ad8(_0x496470,_0x50ce30,_0x4c5fa4){let _0x3a212e=-0x1,_0x318f0f=Number['POSITIVE_INFINITY'],_0x4b58f6=!0x0;for(let _0x2575b2=_0x50ce30;_0x2575b2<_0x4c5fa4;_0x2575b2++)if(_0x13a947['isInline'](_0x496470[_0x2575b2]['item'])||(_0x4b58f6=!0x1),_0x496470[_0x2575b2]['item']['startIndex']<_0x50ce30&&(_0x3a212e=_0x2575b2),_0x496470[_0x2575b2]['item']['endIndex']>=_0x4c5fa4){_0x318f0f=_0x2575b2;break;}_0x4b58f6&&(_0x3a212e=_0x4c5fa4-0x1);for(let _0x425c90=_0x50ce30;_0x425c90<_0x4c5fa4;_0x425c90++)_0x496470[_0x425c90]['side']=_0x425c90<=_0x3a212e?-0x1:_0x425c90<_0x318f0f?0x0:0x1,_0x496470[_0x425c90]['index']=_0x425c90;let _0x1d5fab=0x0;for(let _0x4ad0fd=_0x50ce30;_0x4ad0fd<=_0x3a212e;_0x4ad0fd++)0x0==_0x496470[_0x4ad0fd]['distance']?_0x496470[_0x4ad0fd]['level']=_0x1d5fab:(_0x1d5fab++,_0x496470[_0x4ad0fd]['level']=_0x1d5fab,_0x1d5fab++);for(let _0x21da43=_0x50ce30;_0x21da43<_0x4c5fa4;_0x21da43++)0x0==_0x496470[_0x21da43]['side']&&(_0x496470[_0x21da43]['level']=_0x1d5fab);_0x1d5fab=0x0;for(let _0x11d53a=_0x4c5fa4-0x1;_0x11d53a>=_0x318f0f;_0x11d53a--)0x0==_0x496470[_0x11d53a]['distance']?_0x496470[_0x11d53a]['level']=_0x1d5fab:(_0x1d5fab--,_0x496470[_0x11d53a]['level']=_0x1d5fab,_0x1d5fab--);}}['_fixObsoleteTags'](_0x1ade34){const _0x2edaf1=new Map(),_0xeb138e=this['editor']['model']['schema'];for(let _0x22b82c=0x1;_0x22b82c<_0x1ade34['length'];_0x22b82c++){let _0x299c24,_0x4a2fdd,_0x5ed111;const _0x246888=_0x1ade34[_0x22b82c],_0x36ae36=_0x1ade34[_0x22b82c-0x1];if('text'==_0x246888['type'])continue;if(_0x246888['type']!=_0x36ae36['type'])continue;if(!_0xeb138e['isBlock'](_0x36ae36['item'])||_0xeb138e['isLimit'](_0x36ae36['item']))continue;if(!_0xeb138e['isBlock'](_0x246888['item'])||_0xeb138e['isLimit'](_0x246888['item']))continue;if((_0x1ade34[_0x22b82c]['isAdded']||_0x1ade34[_0x22b82c]['isAddSuggestion'])&&_0x1ade34[_0x22b82c-0x1]['isRemoved'])_0x299c24=_0x1ade34[_0x22b82c],_0x4a2fdd=_0x1ade34[_0x22b82c-0x1],_0x5ed111=_0x22b82c-0x1;else{if(!_0x1ade34[_0x22b82c]['isRemoved']||!_0x1ade34[_0x22b82c-0x1]['isAdded']&&!_0x1ade34[_0x22b82c-0x1]['isAddSuggestion'])continue;_0x299c24=_0x1ade34[_0x22b82c-0x1],_0x4a2fdd=_0x1ade34[_0x22b82c],_0x5ed111=_0x22b82c;}const _0x58c050=_0x299c24['level']==_0x4a2fdd['level'],_0x5a7417=Math['abs'](_0x299c24['level'])<Math['abs'](_0x4a2fdd['level'])&&0x0==_0x4a2fdd['distance'];(_0x58c050||_0x5a7417)&&(_0x2edaf1['set'](_0x4a2fdd['id'],_0x299c24['id']),_0x1ade34['splice'](_0x5ed111,0x1),_0x22b82c--,_0x299c24['isAdded']=!0x1);}for(let _0x4cd525=0x0;_0x4cd525<_0x1ade34['length'];_0x4cd525++)_0x2edaf1['has'](_0x1ade34[_0x4cd525]['pairId'])&&(_0x1ade34[_0x4cd525]['pairId']=_0x2edaf1['get'](_0x1ade34[_0x4cd525]['pairId']));}['_removeMissingPairs'](_0x3ff4ac){const _0x59bd17=new Set(_0x3ff4ac['map'](_0x1912df=>_0x1912df['id']));for(let _0x196885=0x0;_0x196885<_0x3ff4ac['length'];_0x196885++)_0x59bd17['has'](_0x3ff4ac[_0x196885]['pairId'])||0x0==_0x3ff4ac[_0x196885]['distance']||(_0x3ff4ac[_0x196885]['isIncorrect']=!0x0);return _0x3ff4ac['filter'](_0x2e5f49=>!_0x2e5f49['isIncorrect']);}['_markMismatchedRemovedTags'](_0x307c42){const _0x3cc468=new Set();for(let _0x1bf7d8=0x0;_0x1bf7d8<_0x307c42['length'];_0x1bf7d8++){if(_0x3cc468['has'](_0x307c42[_0x1bf7d8]['id'])&&_0x307c42[_0x1bf7d8]['isRemoved']&&(_0x307c42[_0x1bf7d8]['isIncorrect']=!0x0),_0x307c42[_0x1bf7d8]['isIncorrect'])continue;if(0x0==_0x307c42[_0x1bf7d8]['distance'])continue;if('elementStart'!=_0x307c42[_0x1bf7d8]['type'])continue;if(null==_0x307c42[_0x1bf7d8]['pairId'])continue;let _0x312e7e=_0x1bf7d8+0x1,_0x4ad59e=0x0;for(;_0x307c42[_0x312e7e]['id']!=_0x307c42[_0x1bf7d8]['pairId'];)'elementStart'==_0x307c42[_0x312e7e]['type']?_0x4ad59e++:'elementEnd'==_0x307c42[_0x312e7e]['type']&&_0x4ad59e--,_0x312e7e++;if(0x0!=_0x4ad59e){if(_0x307c42[_0x1bf7d8]['isRemoved'])_0x307c42[_0x1bf7d8]['isIncorrect']=!0x0;else{for(;_0x312e7e!=_0x1bf7d8;)_0x307c42[_0x312e7e]['isRemoved']&&0x0!=_0x307c42[_0x312e7e]['distance']&&(_0x307c42[_0x312e7e]['isIncorrect']=!0x0,_0x3cc468['add'](_0x307c42[_0x312e7e]['pairId'])),_0x312e7e--;}}}return _0x307c42['filter'](_0x13de7a=>!_0x13de7a['isIncorrect']);}['_removeUnsupportedChanges'](_0x5c9118){const _0x1cee26=this['editor']['model']['schema'];for(let _0x35e6b2=0x0;_0x35e6b2<_0x5c9118['length'];_0x35e6b2++){if(!(_0x5c9118[_0x35e6b2]['isAdded']||_0x5c9118[_0x35e6b2]['isAddSuggestion']||_0x5c9118[_0x35e6b2]['isRemoved']||_0x5c9118[_0x35e6b2]['isRemoveSuggestion']))continue;if(0x0==_0x5c9118[_0x35e6b2]['distance'])continue;const _0x459aae=_0x5c9118[_0x35e6b2]['item'];_0x1cee26['isBlock'](_0x459aae)||_0x1cee26['isLimit'](_0x459aae)||(_0x5c9118[_0x35e6b2]['isAdded']&&delete _0x5c9118[_0x35e6b2]['isAdded'],_0x5c9118[_0x35e6b2]['isAddSuggestion']&&delete _0x5c9118[_0x35e6b2]['isAddSuggestion'],_0x5c9118[_0x35e6b2]['isRemoveSuggestion']&&delete _0x5c9118[_0x35e6b2]['isRemoveSuggestion'],_0x5c9118[_0x35e6b2]['isRemoved']&&(_0x5c9118[_0x35e6b2]['isIncorrect']=!0x0));}return _0x5c9118['filter'](_0x394cca=>!_0x394cca['isIncorrect']);}['_makeModelFromTape'](_0x5e6758,_0x2037e1,_0x4dae3d){const _0x4b9d16=new _0x1237f0(),_0x5e2f85=[],_0x2428d6=new Map(),_0x3f4abc=this['editor']['model'],_0x2274dd=_0x3f4abc['schema'],_0x1c63ba=[_0x4b9d16],_0x26dc6f={},_0xa456bd={'isAdded':[],'isRemoved':[],'isAddSuggestion':[],'isRemoveSuggestion':[]};let _0x209d75=null;const _0x2014f0=[0x0];for(let _0x2e693f=0x0;_0x2e693f<_0x5e6758['length'];_0x2e693f++)if('elementStart'===_0x5e6758[_0x2e693f]['type']){_0x5e6758[_0x2e693f]['previousPosition']=_0x3f4abc['createPositionFromPath'](_0x4b9d16,_0x2014f0);const _0x241d29=new _0x314e33(_0x5e6758[_0x2e693f]['item']['name'],_0x5e6758[_0x2e693f]['item']['getAttributes']());_0x1c63ba[0x0]['_appendChild'](_0x241d29),_0x2014f0['push'](0x0),_0x1c63ba['unshift'](_0x241d29),_0x5e6758[_0x2e693f]['nextPosition']=_0x3f4abc['createPositionFromPath'](_0x4b9d16,_0x2014f0);}else'elementEnd'===_0x5e6758[_0x2e693f]['type']?(_0x1c63ba['shift'](),_0x5e6758[_0x2e693f]['previousPosition']=_0x3f4abc['createPositionFromPath'](_0x4b9d16,_0x2014f0),_0x2014f0['pop'](),_0x2014f0[_0x2014f0['length']-0x1]++,_0x5e6758[_0x2e693f]['nextPosition']=_0x3f4abc['createPositionFromPath'](_0x4b9d16,_0x2014f0)):(_0x5e6758[_0x2e693f]['previousPosition']=_0x3f4abc['createPositionFromPath'](_0x4b9d16,_0x2014f0),_0x209d75?_0x209d75['_data']+=_0x5e6758[_0x2e693f]['item']['data']:_0x209d75=new _0x29743a(_0x5e6758[_0x2e693f]['item']['data'],_0x5e6758[_0x2e693f]['item']['getAttributes']()),_0x5e6758[_0x2e693f+0x1]&&'text'===_0x5e6758[_0x2e693f+0x1]['type']&&_0x5375a1(_0x209d75,_0x5e6758[_0x2e693f+0x1]['item'])||(_0x1c63ba[0x0]['_appendChild'](_0x209d75),_0x209d75=null),_0x2014f0[_0x2014f0['length']-0x1]+=_0x5e6758[_0x2e693f]['item']['offsetSize'],_0x5e6758[_0x2e693f]['nextPosition']=_0x3f4abc['createPositionFromPath'](_0x4b9d16,_0x2014f0));for(let _0x4d9aed=0x0;_0x4d9aed<_0x5e6758['length'];_0x4d9aed++){const _0x901a84=_0x5e6758[_0x4d9aed]['previousPosition'],_0xf96637=_0x5e6758[_0x4d9aed]['nextPosition'];for(const _0x1f7532 of _0x5e6758[_0x4d9aed]['markersStart'])_0x2428d6['set'](_0x1f7532,{'start':_0x901a84,'end':null});_0x10dfe4('isRemoveSuggestion',_0x4d9aed,_0x901a84,_0xf96637),_0x10dfe4('isAddSuggestion',_0x4d9aed,_0x901a84,_0xf96637),_0x10dfe4('isRemoved',_0x4d9aed,_0x901a84,_0xf96637),_0x10dfe4('isAdded',_0x4d9aed,_0x901a84,_0xf96637);for(const _0x3117fb of _0x5e6758[_0x4d9aed]['markersEnd']){const _0x42fa89=_0x2428d6['get'](_0x3117fb);_0x42fa89?_0x42fa89['end']=_0xf96637:_0x2428d6['set'](_0x3117fb,{'start':_0xf96637,'end':_0xf96637});}}for(const [_0x4633d3,_0x33a0a4]of _0x2428d6){const _0x55fce5=this['editor']['model']['createRange'](_0x33a0a4['start'],_0x33a0a4['end']);_0x4b9d16['markers']['set'](_0x4633d3,_0x55fce5);}return _0x5e2f85['sort']((_0x4b8b6a,_0x1502eb)=>{const _0x2bc0ad=_0x4b9d16['markers']['get']('revision:'+_0x4b8b6a['id']),_0x8ebf33=_0x4b9d16['markers']['get']('revision:'+_0x1502eb['id']);return _0x2bc0ad['start']['isBefore'](_0x8ebf33['start'])?-0x1:_0x2bc0ad['start']['isAfter'](_0x8ebf33['start'])?0x1:_0x2bc0ad['end']['isBefore'](_0x8ebf33['end'])?-0x1:_0x2bc0ad['end']['isAfter'](_0x8ebf33['end'])?0x1:'add'===_0x4b8b6a['type']?-0x1:0x1;}),{'root':_0x4b9d16,'changes':_0x5e2f85};function _0x10dfe4(_0x4b42d4,_0x48dac9,_0x1939b9,_0x24a57e){const _0x2ed278=!!_0x5e6758[_0x48dac9][_0x4b42d4],_0x4733c4=_0x2ed278?_0x5e6758[_0x48dac9][_0x4b42d4]['userId']:null,_0x4d2faf=_0x48dac9===_0x5e6758['length']-0x1,_0x2b1e14=_0xa456bd[_0x4b42d4][0x0],_0x2172d1=_0x2274dd['isObject'](_0x5e6758[_0x48dac9]['item']);!_0x26dc6f[_0x4b42d4]&&_0x2ed278?_0x26dc6f[_0x4b42d4]={'start':_0x1939b9,'tapeItem':_0x5e6758[_0x48dac9],'userId':_0x4733c4,'type':_0x4b42d4}:_0x26dc6f[_0x4b42d4]&&!_0x2ed278?(_0x26dc6f[_0x4b42d4]['end']=_0x1939b9,_0x29eb2a(_0x26dc6f[_0x4b42d4]),_0x26dc6f[_0x4b42d4]=null):_0x26dc6f[_0x4b42d4]&&_0x2ed278&&_0x26dc6f[_0x4b42d4]['userId']!==_0x4733c4&&(_0x26dc6f[_0x4b42d4]['end']=_0x1939b9,_0x2b1e14&&_0x2b1e14['userId']===_0x26dc6f[_0x4b42d4]['userId']||_0x29eb2a(_0x26dc6f[_0x4b42d4]),_0x26dc6f[_0x4b42d4]={'start':_0x1939b9,'tapeItem':_0x5e6758[_0x48dac9],'userId':_0x4733c4,'type':_0x4b42d4}),_0x26dc6f[_0x4b42d4]&&_0x2172d1&&('elementStart'!==_0x5e6758[_0x48dac9]['type']||_0x2b1e14&&_0x2b1e14['userId']===_0x4733c4||_0xa456bd[_0x4b42d4]['unshift']({'userId':_0x4733c4,'object':_0x5e6758[_0x48dac9]['item'],'change':_0x26dc6f[_0x4b42d4]}),'elementEnd'===_0x5e6758[_0x48dac9]['type']&&_0x2b1e14&&_0x2b1e14['object']===_0x5e6758[_0x48dac9]['item']&&(_0xa456bd[_0x4b42d4]['shift'](),_0x26dc6f[_0x4b42d4]=_0x2b1e14['change'])),_0x26dc6f[_0x4b42d4]&&_0x4d2faf&&(_0x26dc6f[_0x4b42d4]['end']=_0x24a57e,_0x29eb2a(_0x26dc6f[_0x4b42d4]),_0x26dc6f[_0x4b42d4]=null);}function _0x29eb2a({start:_0x14f513,end:_0x3a1ef5,tapeItem:_0x34c658,userId:_0x1ba6d8,type:_0x5b5621}){const _0x1050cd=_0x34c658['item'],_0x3584af=_0x3f4abc['schema']['isBlock'](_0x1050cd)&&!_0x3f4abc['schema']['isLimit'](_0x1050cd),_0x4ec4bc=_0x14f513['nodeAfter']==_0x3a1ef5['parent']&&_0x3a1ef5['isAtStart'];if(_0x3584af&&_0x4ec4bc)return;const _0x570c18=_0x3f4abc['createRange'](_0x14f513,_0x3a1ef5),_0x2d037b=_0x2037e1['get'](_0x1ba6d8),_0x3b89c6=new G({'author':_0x2d037b,'type':'isAdded'==_0x5b5621||'isAddSuggestion'==_0x5b5621?'add':'remove','data':{'isSuggestion':'isAddSuggestion'==_0x5b5621||'isRemoveSuggestion'==_0x5b5621},'createdAt':new Date(),'rootName':_0x4dae3d});_0x5e2f85['push'](_0x3b89c6),_0x4b9d16['markers']['set']('revision:'+_0x3b89c6['id'],_0x570c18);}function _0x5375a1(_0x5265a9,_0x177968){const _0x2ec1fa=_0x5265a9['getAttributes'](),_0x4c485b=_0x177968['getAttributes']();for(const _0x511b93 of _0x2ec1fa){if(_0x511b93[0x1]!==_0x177968['getAttribute'](_0x511b93[0x0]))return!0x1;_0x4c485b['next']();}return _0x4c485b['next']()['done'];}}['_setConversion'](){this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision','view':_0x289200=>{const _0x1a9b9e=_0x289200['markerName']['split'](':')[0x1],_0x2fde8e=this['_getChangeFromId'](_0x1a9b9e);if(!_0x2fde8e)return null;const _0x52ec54='add'==_0x2fde8e['type']?'insertion':'deletion',_0x5378e1=['ck-suggestion-marker','ck-suggestion-marker-'+_0x52ec54];return _0x2fde8e['data']['isSuggestion']&&_0x5378e1['push']('ck-suggestion-marker-'+_0x52ec54+'-new'),this['activeChange']==_0x2fde8e&&_0x5378e1['push']('ck-suggestion-marker--active'),{'classes':_0x5378e1,'attributes':{'data-change-id':_0x1a9b9e}};}}),this['editor']['conversion']['for']('upcast')['add'](_0x548905=>{_0x548905['on']('element:pre',(_0x26bad4,_0x435b67,_0x216666)=>{const _0x4ef23f=_0x435b67['viewItem']['getChild'](0x0);if(!_0x4ef23f||!_0x4ef23f['is']('element','code'))return;if(!_0x216666['consumable']['consume'](_0x4ef23f,{'attributes':['vid_start','vid_end']}))return;const _0x6a945e=_0x435b67['modelRange']['start']['nodeAfter'];_0x216666['writer']['setAttribute']('vid_start',_0x4ef23f['getAttribute']('vid_start'),_0x6a945e),_0x216666['writer']['setAttribute']('vid_end',_0x4ef23f['getAttribute']('vid_end'),_0x6a945e);},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['add'](_0x13f471=>{_0x13f471['on']('element',(_0x5429c2,_0x3f2a10,_0x2fa7a4)=>{if(!_0x2fa7a4['consumable']['consume'](_0x3f2a10['viewItem'],{'attributes':['vid_start','vid_end']}))return;if(_0x3f2a10['modelRange']['isCollapsed'])return;const _0x551564=_0x3f2a10['modelRange']['start']['nodeAfter'];_0x551564['hasAttribute']('vid_start')||_0x551564['hasAttribute']('vid')||(_0x2fa7a4['writer']['setAttribute']('vid_start',_0x3f2a10['viewItem']['getAttribute']('vid_start'),_0x551564),_0x2fa7a4['writer']['setAttribute']('vid_end',_0x3f2a10['viewItem']['getAttribute']('vid_end'),_0x551564));},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['elementToAttribute']({'view':{'name':'span','attributes':{'vid':!0x0}},'model':{'key':'vid','value':_0x36a3b7=>_0x36a3b7['getAttribute']('vid')}}),this['editor']['model']['schema']['on']('checkAttribute',(_0xb7f7f3,[,_0x21c70e])=>{['vid_start','vid_end','vid']['includes'](_0x21c70e)&&(_0xb7f7f3['return']=!0x0,_0xb7f7f3['stop']());},{'priority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x30df51=>{_0x30df51['on']('attribute:vid',(_0x36de74,_0x5c9012,_0x3670dd)=>{if('\x20'!=_0x5c9012['item']['data']||_0x5c9012['item']['parent']['maxOffset']>0x1)return;if(!_0x3670dd['consumable']['consume'](_0x5c9012['item'],_0x36de74['name']))return;const _0x55ca64=_0x3670dd['writer'],_0x54972e=_0x3670dd['mapper']['toViewRange'](_0x5c9012['range']);_0x55ca64['wrap'](_0x54972e,_0x55ca64['createAttributeElement']('span'));});}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',function(_0x20ca82){const _0x29309e=_0x20ca82['plugins']['get']('RevisionViewer');return(_0xedcae7,_0x143596,_0x27b113)=>{const _0x530df9=_0x143596['markerName']['split'](':')[0x1],_0x1a8b61=_0x29309e['_getChangeFromId'](_0x530df9);if(!_0x1a8b61)return null;const _0x4dda24='add'==_0x1a8b61['type']?'split':'merge';if(!_0x27b113['consumable']['test'](_0x143596['markerRange'],_0xedcae7['name']))return;const _0x4918eb=_0x143596['markerRange']['getWalker'](),_0xf7bfc2=_0x143596['markerRange']['start'],_0xfbba6e=_0x20ca82['model']['schema'];let _0x12cba4=null,_0x2b5009=null,_0x4da36b=!0x1,_0x46645c=!0x1;for(const _0x58cda5 of _0x4918eb){const _0x447945=_0x58cda5['item'];_0x4da36b=_0x4da36b||_0xfbba6e['isContent'](_0x447945);const _0x27d817=_0x27b113['mapper']['toViewElement'](_0x447945);if(_0x27d817&&_0x27d817['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x58cda5['type']&&(_0xfbba6e['isBlock'](_0x447945)&&!_0xfbba6e['isLimit'](_0x447945)&&(_0x447945['nextSibling']||_0xf7bfc2['isAtEnd']?_0x12cba4&&_0x12cba4['parent']==_0x447945||(_0x12cba4=_0x447945,_0xf1f264(_0x58cda5['previousPosition']),_0x46645c=!0x0):_0x2b5009=_0x2b5009||_0x58cda5['previousPosition']));}function _0xf1f264(_0x5e9db5){const _0x3c6664=_0x27b113['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x4dda24}),_0x3c0204=_0x27b113['mapper']['toViewPosition'](_0x5e9db5);_0x1a8b61['data']['isSuggestion']&&_0x27b113['writer']['addClass']('ck-suggestion-marker-'+_0x4dda24+'-new',_0x3c6664),_0x29309e['activeChange']==_0x1a8b61&&_0x27b113['writer']['addClass']('ck-suggestion-marker--active',_0x3c6664),_0x27b113['writer']['insert'](_0x3c0204,_0x3c6664),_0x27b113['mapper']['bindElementToMarker'](_0x3c6664,_0x143596['markerName']);}_0x4da36b||_0x46645c||!_0x2b5009||_0xf1f264(_0x2b5009);};}(this['editor']),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision',(_0xdba13e,_0x9f04ab,_0x3f93e0)=>{const _0x100453=_0x3f93e0['mapper']['markerNameToElements'](_0x9f04ab['markerName']);if(_0x100453){for(const _0x4731ad of _0x100453)(_0x4731ad['hasClass']('ck-suggestion-marker-split')||_0x4731ad['hasClass']('ck-suggestion-marker-merge'))&&(_0x3f93e0['mapper']['unbindElementFromMarkerName'](_0x4731ad,_0x9f04ab['markerName']),_0x3f93e0['writer']['remove'](_0x4731ad));}},{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',(_0x496313,_0x59581d,_0x326c1b)=>{const _0x5430d2=_0x59581d['markerName']['split'](':')[0x1],_0x1a5ed5=this['_getChangeFromId'](_0x5430d2);if(!_0x1a5ed5)return null;const _0x2e7988='add'==_0x1a5ed5['type']?'split':'merge';if(_0x326c1b['consumable']['test'](_0x59581d['markerRange'],_0x496313['name']))for(const _0x8dec3c of _0x59581d['markerRange']['getItems']()){if(!_0x8dec3c['is']('element','softBreak'))continue;const _0xd54a54=_0x326c1b['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x2e7988}),_0x327e8d=_0x326c1b['mapper']['toViewPosition'](this['editor']['model']['createPositionBefore'](_0x8dec3c));_0x1a5ed5['data']['isSuggestion']&&_0x326c1b['writer']['addClass']('ck-suggestion-marker-'+_0x2e7988+'-new',_0xd54a54),this['activeChange']==_0x1a5ed5&&_0x326c1b['writer']['addClass']('ck-suggestion-marker--active',_0xd54a54),_0x326c1b['writer']['insert'](_0x327e8d,_0xd54a54),_0x326c1b['mapper']['bindElementToMarker'](_0xd54a54,_0x59581d['markerName']);}},{'priority':'high'}),this['editor']['model']['document']['on']('change',()=>{this['editor']['editing']['view']['change'](_0x37850c=>{for(const _0x264027 of this['editor']['model']['document']['getRootNames']()){const _0x5176e9=this['editor']['model']['document']['getRoot'](_0x264027),_0x10b576=this['editor']['editing']['view']['document']['getRoot'](_0x264027);if(_0x10b576){const _0xb88fd1=_0x5176e9['getAttribute']('revisionHistoryAttachChange');if(_0x37850c['removeAttribute']('data-change-id',_0x10b576),_0x37850c['removeClass']('ck-revision-history-root-add',_0x10b576),_0x37850c['removeClass']('ck-revision-history-root-remove',_0x10b576),_0x37850c['removeClass']('ck-revision-history-root--active',_0x10b576),_0xb88fd1){const _0x1c8ee0=this['_getChangeFromId'](_0xb88fd1);if(!_0x1c8ee0)return null;_0x37850c['setAttribute']('data-change-id',_0xb88fd1,_0x10b576),_0x37850c['addClass']('ck-revision-history-root-'+_0x1c8ee0['type'],_0x10b576),this['activeChange']==_0x1c8ee0&&_0x37850c['addClass']('ck-revision-history-root--active',_0x10b576);}}}});}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'comment','model':_0x2dae5a=>'revision-comment:'+_0x2dae5a,'converterPriority':'highest'}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'suggestion','model':_0x2a39eb=>'revision-suggestion:'+_0x2a39eb,'converterPriority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision-suggestion','view':_0x15de49=>({'name':'suggestion:'+_0x15de49,'group':'revision-suggestion'}),'converterPriority':'highest'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision-suggestion','view':_0x411ac1=>{const _0x5315f6=_0x411ac1['markerName']['split'](':')[0x1];return'insertion'!=_0x5315f6&&'deletion'!=_0x5315f6?null:{'classes':['ck-suggestion-preview-marker','ck-suggestion-preview-marker-'+_0x5315f6]};}}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:deletion',Q(this['editor'],'merge'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:insertion',Q(this['editor'],'split'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision-suggestion',(_0x5f249a,_0x32eb56,_0x29e84f)=>{const _0x50cab8=_0x29e84f['mapper']['markerNameToElements'](_0x32eb56['markerName']);if(_0x50cab8){for(const _0x3395d8 of _0x50cab8)_0x3395d8['is']('uiElement')&&(_0x29e84f['mapper']['unbindElementFromMarkerName'](_0x3395d8,_0x32eb56['markerName']),_0x29e84f['writer']['remove'](_0x3395d8));}},{'priority':'high'});}['_getChangeFromId'](_0x5a469d){return this['_changeIdToChange']['get'](_0x5a469d);}['_getViewForChange'](_0x2c2252){return this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=new z(this['editor']['locale'],_0x2c2252),this['_changeView'];}['_initInteractions'](){this['editor']['model']['document']['selection']['observeMarkers']('revision'),this['on']('change:activeView',(_0x43d426,_0x2c0591,_0x537383,_0xef85f2)=>{_0xef85f2&&this['_balloon']['remove'](_0xef85f2),_0x537383&&(this['_balloon']['add']({'view':_0x537383,'stackId':'revisionHistoryLabel','position':{'target':()=>{const _0x1436d0=this['editor']['editing'],_0x5ed965=this['_getChangeFromId'](_0x537383['changeId']);let _0x5aaa67;if(_0x5ed965['data']['isOnRoot']){const _0x99394=_0x1436d0['view']['getDomRoot'](_0x5ed965['rootName']);_0x5aaa67=Array['from'](_0x99394['getClientRects']());}else{const _0x39d026=this['editor']['model']['markers']['get']('revision:'+_0x537383['changeId']);_0x5aaa67=Array['from'](_0x1436d0['mapper']['markerNameToElements'](_0x39d026['name']))['map'](_0xdbfe74=>_0x1436d0['view']['domConverter']['mapViewToDom'](_0xdbfe74))['map'](_0x15ad0d=>Array['from'](_0x15ad0d['getClientRects']()))['flat']();}if(!this['_activeViewTarget'])return _0x5aaa67[0x0];return _0x5aaa67['find'](_0x59ed00=>_0x59ed00['top']-0x3<=this['_activeViewTarget']['y']&&_0x59ed00['bottom']+0x3>=this['_activeViewTarget']['y']&&_0x59ed00['left']-0x3<=this['_activeViewTarget']['x']&&_0x59ed00['right']+0x3>=this['_activeViewTarget']['x'])||_0x5aaa67[0x0];}}}),this['_balloon']['showStack']('revisionHistoryLabel'));}),this['on']('change:activeChange',(_0x42662f,_0x2f727e,_0x1dfbe8,_0x53bd52)=>{this['activeView']=_0x1dfbe8?this['_getViewForChange'](_0x1dfbe8):null,this['editor']['model']['change'](()=>{const _0x275083=this['editor']['editing'];_0x53bd52&&(_0x53bd52['data']['isOnRoot']?_0x275083['view']['change'](_0x771172=>{_0x771172['removeClass']('ck-revision-history-root--active',_0x275083['view']['document']['getRoot'](_0x53bd52['rootName']));}):_0x275083['reconvertMarker']('revision:'+_0x53bd52['id'])),_0x1dfbe8&&(_0x1dfbe8['data']['isOnRoot']?_0x275083['view']['change'](_0x1c128c=>{_0x1c128c['addClass']('ck-revision-history-root--active',_0x275083['view']['document']['getRoot'](_0x1dfbe8['rootName']));}):_0x275083['reconvertMarker']('revision:'+_0x1dfbe8['id']));});}),this['listenTo'](this['editor']['editing']['view']['document'],'mouseover',(_0x4588bb,_0xfd4f3b)=>{if(this['activeChange'])return;const _0x210d5a=this['_findChangeIdFromDomTarget'](_0xfd4f3b['target']),_0x1c516d=this['_changeIdToChange']['get'](_0x210d5a);_0x1c516d?(this['_activeViewTarget']={'x':_0xfd4f3b['domEvent']['x'],'y':_0xfd4f3b['domEvent']['y']},this['activeView']=this['_getViewForChange'](_0x1c516d)):(this['_activeViewTarget']=null,this['activeView']=null);}),this['listenTo'](this['editor']['editing']['view']['document'],'mousedown',(_0x21baa7,_0x4d91a8)=>{const _0x32b24e=this['_findChangeIdFromDomTarget'](_0x4d91a8['target']),_0x117b42=this['_changeIdToChange']['get'](_0x32b24e);_0x117b42?(this['_activeViewTarget']={'x':_0x4d91a8['domEvent']['x'],'y':_0x4d91a8['domEvent']['y']},_0x117b42===this['activeChange']?this['_balloon']['updatePosition']():this['activeChange']=_0x117b42):(this['_activeViewTarget']=null,this['activeChange']=null);});}['_findChangeIdFromDomTarget'](_0x453f53){do{const _0x40bd14=_0x453f53['getAttribute']('data-change-id');if(_0x40bd14)return _0x40bd14;_0x453f53=_0x453f53['parent'];}while(_0x453f53);return null;}['_cleanMarkers'](){this['editor']['model']['change'](_0x4944ac=>{for(const _0x564062 of this['editor']['model']['markers'])_0x4944ac['removeMarker'](_0x564062);});}}function Q(_0xc87646,_0x37bfd6){return(_0x1cf713,_0x39832c,_0x10f1d2)=>{if(!_0x10f1d2['consumable']['test'](_0x39832c['markerRange'],_0x1cf713['name']))return;const _0x56b931=_0x39832c['markerRange']['getWalker'](),_0x446610=_0x39832c['markerRange']['start'],_0xcdb668=_0xc87646['model']['schema'];let _0x16b165=null,_0x46de6d=null,_0x147d2a=!0x1,_0x2918c3=!0x1;for(const _0x32afe6 of _0x56b931){const _0x115b63=_0x32afe6['item'];_0x147d2a=_0x147d2a||_0xcdb668['isContent'](_0x115b63);const _0x130a41=_0x10f1d2['mapper']['toViewElement'](_0x115b63);if(_0x130a41&&_0x130a41['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x32afe6['type']&&(_0xcdb668['isBlock'](_0x115b63)&&!_0xcdb668['isLimit'](_0x115b63)&&(_0x115b63['nextSibling']||_0x446610['isAtEnd']?_0x16b165&&_0x16b165['parent']==_0x115b63||(_0x16b165=_0x115b63,_0x191c5b(_0x32afe6['previousPosition']),_0x2918c3=!0x0):_0x46de6d=_0x46de6d||_0x32afe6['previousPosition']));}function _0x191c5b(_0x18ed18){const _0x463e96=_0x10f1d2['mapper']['toViewPosition'](_0x18ed18),_0x352cc2=_0x10f1d2['writer']['createUIElement']('span',{'class':'ck-suggestion-preview-marker-'+_0x37bfd6});_0x10f1d2['writer']['insert'](_0x463e96,_0x352cc2),_0x10f1d2['mapper']['bindElementToMarker'](_0x352cc2,_0x39832c['markerName']);}_0x147d2a||_0x2918c3||!_0x46de6d||_0x191c5b(_0x46de6d);};}class nt extends _0x5e6e25{constructor(_0x458c5c){super(_0x458c5c);const _0xac434b=_0x458c5c['plugins']['get'](u);this['affectsData']=!0x1,this['listenTo'](_0xac434b,'change:isReady',()=>this['refresh']()),this['listenTo'](_0xac434b,'change:isEnabled',()=>this['refresh']());}['execute'](){const _0x18cac1=this['editor'],_0x40f953=_0x18cac1['plugins']['get'](u),_0x27ab97=_0x40f953['isReady']?_0x40f953['diff']['newRevisionId']:null;_0x18cac1['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x27ab97);}['refresh'](){const {isReady:_0x293b61,isEnabled:_0x45fcce,repository:_0x2b8e4b,diff:_0xcc7ac6}=this['editor']['plugins']['get'](u),_0x507b87=_0xcc7ac6&&_0x2b8e4b['getLaterVisibleRevision'](_0xcc7ac6['newRevisionId']);this['isEnabled']=_0x293b61&&_0x45fcce&&Boolean(_0x507b87);}}class rt extends _0x5e6e25{['_step'];constructor(_0x3f62cf,{direction:_0x1dc552}){super(_0x3f62cf);const _0x217125=_0x3f62cf['plugins']['get'](u);this['affectsData']=!0x1,this['_step']='forward'===_0x1dc552?0x1:-0x1,this['listenTo'](_0x217125,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x217125,'change:isEnabled',()=>this['refresh']()),this['listenTo'](_0x217125,'change:activeChange',()=>this['refresh']());}['execute'](){const _0x135802=this['editor'],_0x53ad34=_0x135802['plugins']['get'](u),{isNavigationMode:_0x43e052,currentChangeNumber:_0x5734c0}=_0x53ad34;let _0x547911;if(_0x53ad34['activeChange']=_0x43e052?_0x53ad34['diff']['changes']['get'](_0x5734c0+this['_step']):_0x53ad34['diff']['changes']['first'],_0x53ad34['activeChange']['data']['isOnRoot'])_0x547911=_0x135802['editing']['view']['getDomRoot'](_0x53ad34['activeChange']['rootName']);else{const _0x44fb81=_0x135802['model']['markers']['get']('revision:'+_0x53ad34['activeChange']['id']);_0x547911=_0x5b00f2(_0x135802['editing'],_0x44fb81);}_0xf4a10b({'target':_0x547911,'viewportOffset':0x28});}['refresh'](){const {isNavigationMode:_0x46d8f0,currentChangeNumber:_0x2f231a,numberOfChanges:_0xa3ec1a,isReady:_0x349906,isEnabled:_0x340f8d}=this['editor']['plugins']['get'](u);this['isEnabled']=!!(_0x340f8d&&_0x349906&&_0xa3ec1a)&&(!_0x46d8f0||(0x1===this['_step']?_0x2f231a<_0xa3ec1a-0x1:_0x2f231a>0x0));}}class pi extends _0x1f7714{constructor(_0x47999d){super(_0x47999d);const _0x4174b1=this['bindTemplate'],_0x3d3c70=new _0x41e223(_0x47999d),_0x2ab8c1=new _0x41e223(_0x47999d);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',(_0x2a0778,_0x3d7272)=>_0x2a0778&&_0x3d7272>0x0),this['bind']('_statusText')['to'](this,'isReady',this,'currentChangeNumber',this,'numberOfChanges',this,'isNavigationMode',(_0x77f99,_0x5a09cc,_0x566e67,_0x221660)=>{if(!_0x77f99)return m(_0x47999d,'Loading...');if(!_0x566e67)return m(_0x47999d,'No\x20changes');const _0x552622=m(_0x47999d,'NUMBER_OF_CHANGES',_0x566e67);return _0x221660?m(_0x47999d,'X_OF_Y_CHANGES',[_0x5a09cc+0x1,_0x566e67]):_0x552622;}),_0x3d3c70['set']({'label':m(_0x47999d,'Show\x20previous\x20change'),'tooltip':!0x0,'icon':_0x21aa3d}),_0x2ab8c1['set']({'label':m(_0x47999d,'Show\x20next\x20change'),'tooltip':!0x0,'icon':_0x44f4be}),_0x3d3c70['bind']('isEnabled')['to'](this,'isBackwardNavigationEnabled'),_0x2ab8c1['bind']('isEnabled')['to'](this,'isForwardNavigationEnabled'),_0x3d3c70['on']('execute',()=>this['fire']('execute','backward')),_0x2ab8c1['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',_0x4174b1['if']('_isStatusLabelVisible','ck-hidden',_0x46b2ba=>!_0x46b2ba)]},'children':[{'text':_0x4174b1['to']('isNavigationMode',_0x3dd5bc=>_0x3dd5bc?m(_0x47999d,'EDIT_X_OF_Y_REVISIONS')+':\x20':m(_0x47999d,'Total')+':\x20')}]},{'text':_0x4174b1['to']('_statusText')}]},new _0x16b0d8(),{'tag':'div','attributes':{'class':['ck-revision-history-ui__changes-navigation__navigation']},'children':[_0x3d3c70,_0x2ab8c1]}]});}}const oe='ck-editor__editable__loading-overlay';class fi extends _0x17be55{static get['pluginName'](){return'RevisionViewerLoadingOverlay';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['show'](){const _0x448b03=this['editor']['editing']['view'];_0x448b03['change'](_0x17299e=>{for(const _0x2cd07b of _0x448b03['document']['roots'])_0x17299e['addClass'](oe,_0x2cd07b);});}['hide'](){const _0xc4bbcc=this['editor']['editing']['view'];_0xc4bbcc['change'](_0x1718ba=>{for(const _0x1299a5 of _0xc4bbcc['document']['roots'])_0x1718ba['removeClass'](oe,_0x1299a5);});}}class v extends _0x17be55{static get['pluginName'](){return'RevisionViewerUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[u,fi];}['init'](){const _0x391189=this['editor'],_0xbaa4d0=_0x391189['plugins']['get'](u),_0x16e445=_0x391189['plugins']['get'](fi);_0x391189['ui']['componentFactory']['add']('exitToEditing',_0x5c17fb=>{const _0x79f7f7=new _0x41e223(_0x5c17fb);return _0x79f7f7['set']({'label':m(_0x5c17fb,'Back\x20to\x20editing'),'icon':_0x2a8575,'withText':!0x0,'tooltip':!0x0,'class':'ck-revision-history-ui__back-to-editing'}),this['listenTo'](_0x79f7f7,'execute',()=>{_0x391189['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}),_0x79f7f7;}),_0x391189['ui']['componentFactory']['add']('restoreRevision',_0x5cd6f6=>{const _0x30bafd=new _0x41e223(_0x5cd6f6);return _0x30bafd['set']({'label':m(_0x5cd6f6,'Restore\x20this\x20revision'),'withText':!0x0,'tooltip':!0x0}),_0x30bafd['bind']('isEnabled')['to'](_0x391189['commands']['get']('restoreRevision')),this['listenTo'](_0x30bafd,'execute',()=>_0x391189['execute']('restoreRevision')),_0x30bafd;}),_0x391189['ui']['componentFactory']['add']('changesNavigation',_0x2bec2f=>{const _0xacb7ac=new pi(_0x2bec2f),_0x27f54b=_0x391189['commands']['get']('showPreviousChange'),_0x2b67c0=_0x391189['commands']['get']('showNextChange');return _0xacb7ac['bind']('isBackwardNavigationEnabled')['to'](_0x27f54b,'isEnabled'),_0xacb7ac['bind']('isForwardNavigationEnabled')['to'](_0x2b67c0,'isEnabled'),_0xacb7ac['bind']('isReady','currentChangeNumber','numberOfChanges','isNavigationMode')['to'](_0xbaa4d0),this['listenTo'](_0xacb7ac,'execute',(_0x3cb972,_0x40fa2e)=>{_0x391189['execute']('forward'===_0x40fa2e?'showNextChange':'showPreviousChange');}),_0xacb7ac;}),_0x16e445['show'](),_0xbaa4d0['on']('change:isReady',(_0x48c3e3,_0x3d213e,_0x45e584)=>{_0x45e584?_0x16e445['hide']():_0x16e445['show']();});}}class hi extends et{['_resizeObserver']=null;constructor(_0x272793,_0x1e9896){super(_0x272793,_0x1e9896);const _0x479f00=this['bindTemplate'];this['set']({'label':m(_0x272793,'Revision\x20name'),'_tooltipString':''}),this['fieldView']['placeholder']=m(_0x272793,'Enter\x20the\x20revision\x20name'),this['extendTemplate']({'tag':'span','attributes':{'class':['ck-revision-history-sidebar__revision-name'],'data-cke-tooltip-text':_0x479f00['to']('_tooltipString'),'data-cke-tooltip-position':'s','data-cke-tooltip-class':'ck-tooltip_multi-line'}});}['render'](){super['render'](),this['_resizeObserver']=new ot(this['fieldView']['element'],()=>this['_updateTooltipText']()),this['listenTo'](this['fieldView'],'input',()=>this['_updateTooltipText']());}['destroy'](){super['destroy'](),this['_resizeObserver']&&this['_resizeObserver']['destroy']();}['_updateTooltipText'](){const _0x32e92d=this['fieldView']['element'];this['_tooltipString']=_0x32e92d['scrollWidth']>_0x32e92d['clientWidth']&&_0x32e92d['value']||'';}}class ni extends _0x1f7714{constructor(_0x3205e0,_0x3809b6,_0x341ead){super(_0x3205e0);const _0x52cd31=new _0x8f1b89();_0x52cd31['set']({'content':_0x145712,'viewBox':'0\x200\x2011\x2010'});const _0x145dac=['ck','ck-revision-history-sidebar__revision-author'];_0x341ead&&_0x145dac['push']('ck-revision-history-sidebar__revision-author_creator');const _0x3a7617=[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision-author__name'],'title':m(_0x3205e0,_0x341ead?'Revision\x20creator':'Revision\x20author')},'children':[_0x52cd31,_0x3809b6['name']]}];this['setTemplate']({'tag':'li','attributes':{'class':_0x145dac},'children':_0x3a7617});}}function ai(_0x2a1848,_0x3dbc34){const _0x19ee0d=_0x2a1848['bindTemplate'],_0x1969f0=_0x2a1848['locale'],_0x449f2f=_0x3826ff(_0x1969f0);_0x449f2f['panelPosition']='sw';const _0x258cd6=function(_0x1f0386,_0x33afe5){const _0x310e5f=function(_0x438148,_0x53500e){const _0x14ad66=_0x438148['locale'],_0x13da65={'Compare\x20against\x20selected':m(_0x14ad66,'Compare\x20against\x20selected'),'Name\x20this\x20revision':m(_0x14ad66,'Name\x20this\x20revision'),'Restore\x20this\x20revision':m(_0x14ad66,'Restore\x20this\x20revision')};return _0x53500e['map'](_0x561f89=>{const _0x8b040=_0x13da65[_0x561f89['name']];return _0x8b040&&_0x8b040!==_0x561f89['name']&&(_0x561f89['name']=_0x8b040),_0x561f89;});}(_0x1f0386,_0x33afe5),_0x642ff7=new _0xd2e413();for(const _0x2e3df5 of _0x310e5f){const _0x82aad4={'type':'button','model':new to({'label':_0x2e3df5['name'],'class':_0x2e3df5['class'],'withText':!0x0,'role':'menuitem','_action':_0x2e3df5['action']})};_0x82aad4['model']['bind']('isEnabled')['to'](_0x1f0386,'isActionsDropdownOpen',_0x5a4676=>'function'!=typeof _0x2e3df5['isEnabled']||(!_0x5a4676||_0x2e3df5['isEnabled'](_0x1f0386))),_0x642ff7['add'](_0x82aad4);}return _0x642ff7;}(_0x2a1848,_0x3dbc34);return _0x2a1848['bind']('isActionsDropdownOpen')['to'](_0x449f2f,'isOpen'),_0x449f2f['buttonView']['set']({'label':m(_0x1969f0,'Show\x20more\x20items'),'tooltip':!0x0,'tooltipPosition':'sw','icon':_0x1c849a}),_0x449f2f['extendTemplate']({'attributes':{'class':['ck-revision-history-sidebar__revision__actions',_0x19ee0d['if']('isActionsDropdownOpen','ck-on')]},'on':{'click':_0x19ee0d['to'](_0x3f22a8=>_0x3f22a8['stopPropagation']())}}),_0x449f2f['on']('execute',_0x368d4c=>{_0x2a1848['isReady']&&'function'==typeof _0x368d4c['source']['_action']&&_0x368d4c['source']['_action'](_0x2a1848);}),_0x3768a3(_0x449f2f,_0x258cd6,{'role':'menu'}),_0x449f2f['listenTo'](_0x2a1848,'change:isActionsDropdownOpen',(_0x149730,_0x7d298e,_0x46cc82)=>{if(_0x46cc82)for(const _0x4635e1 of _0x449f2f['listView']['items']){const _0x1ca0a3=_0x4635e1['children']['first'],_0x330544=_0x3dbc34['find'](_0x3e4c96=>_0x3e4c96['action']===_0x1ca0a3['_action'])['isVisible'];_0x4635e1['isVisible']=void 0x0===_0x330544||_0x330544(_0x2a1848);}}),_0x449f2f;}class vi extends/* #__PURE__ -- @preserve */
27
- _0x32ef73(_0x1f7714){['id'];['revisionNameView'];['revisionActionsView'];['_revision'];['_requireRevisionName'];constructor(_0x2b3ca9,_0x18b892,_0x2d5dd2,_0x42cd98){super(_0x2b3ca9);const _0x41cc05=this['bindTemplate'],_0x4a8635=function(_0x40ea85,_0xa352e2){const _0x3032e4=Array['from'](_0xa352e2['authors'])['filter'](_0x152816=>_0x152816!=_0xa352e2['creator']);return _0xa352e2['creator']&&_0x3032e4['unshift'](_0xa352e2['creator']),_0x3032e4['map'](_0x51e7b7=>new ni(_0x40ea85,_0x51e7b7,_0x51e7b7==_0xa352e2['creator']));}(_0x2b3ca9,_0x18b892);this['id']=_0x18b892['id'],this['_revision']=_0x18b892,this['_requireRevisionName']=_0x42cd98,this['bind']('name','createdAt')['to'](_0x18b892),this['bind']('_createdAtFormatted')['to'](this,'createdAt',_0x3309ac=>{return _0x523844=_0x2b3ca9['uiLanguage'],(_0x33c6fb=_0x3309ac)['toLocaleDateString'](_0x523844,{'month':'long','day':'numeric'})+',\x20'+_0x33c6fb['toLocaleTimeString'](_0x523844,{'hour':'numeric','minute':'numeric'});var _0x523844,_0x33c6fb;}),this['set']('isSelected',!0x1),this['set']('isHighlighted',!0x1),this['set']('isActionsDropdownOpen',!0x1),this['set']('isReady',!0x1),this['set']('isEnabled',!0x1),this['revisionNameView']=new hi(_0x2b3ca9,ti),this['revisionNameView']['fieldView']['extendTemplate']({'attributes':{'maxlength':'220'}}),this['revisionNameView']['fieldView']['bind']('value')['to'](this,'name',_0x819329=>_0x819329||this['_createdAtFormatted']),this['revisionNameView']['bind']('isEnabled')['to'](this,'isSelected',this,'isEnabled',(_0x3692d0,_0x1005ad)=>_0x3692d0&&_0x1005ad),this['revisionActionsView']=_0x2d5dd2&&_0x2d5dd2['length']?ai(this,_0x2d5dd2):'',this['revisionActionsView']&&this['revisionActionsView']['bind']('isEnabled')['to'](this),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision-wrapper',_0x41cc05['if']('isConfirm','ck-revision-history-sidebar__revision-wrapper_confirmation_visible')]},'children':[{'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision',_0x41cc05['if']('isEnabled','ck-disabled',_0x1195e9=>!_0x1195e9),_0x41cc05['if']('isSelected','ck-revision-history-sidebar__revision_selected'),_0x41cc05['if']('isHighlighted','ck-revision-history-sidebar__revision_highlighted'),_0x41cc05['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':_0x41cc05['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':_0x4a8635}]},this['revisionActionsView']],'on':{'click':_0x41cc05['to'](_0x4c938d=>{_0x4c938d['srcElement']['closest']('.ck-confirm-view')||this['isReady']&&this['isEnabled']&&this['fire']('select',{'id':this['id']});})}}]});}['render'](){super['render']();const _0x27cb76=this['revisionNameView']['fieldView']['element'];this['listenTo'](_0x27cb76,'change',()=>{this['_requireRevisionName']&&!_0x27cb76['value']||this['fire']('setName',{'id':this['id'],'name':_0x27cb76['value']}),_0x27cb76['value']||(_0x27cb76['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(_0x3230e6,_0x10a383){const _0x128b89=_0x3f1237['fromJSDate'](_0x3230e6)['setLocale'](_0x10a383),_0x142770=_0x3f1237['local'](),_0x432888=_0x142770['minus']({'days':0x1})['startOf']('day');let _0x5b2674,_0x30d5be;return _0x128b89['hasSame'](_0x142770,'day')?(_0x5b2674=_0x128b89['startOf']('day')['toJSDate'](),_0x30d5be=_0x128b89['toRelativeCalendar']()):_0x128b89['hasSame'](_0x432888,'day')?(_0x5b2674=_0x432888['toJSDate'](),_0x30d5be=_0x128b89['toRelativeCalendar']()):_0x128b89['hasSame'](_0x142770,'week')?(_0x5b2674=_0x128b89['startOf']('week')['toJSDate'](),_0x30d5be=_0x128b89['weekdayLong']||''):_0x128b89['hasSame'](_0x142770,'year')?(_0x5b2674=_0x128b89['startOf']('month')['toJSDate'](),_0x30d5be=_0x128b89['monthLong']||''):(_0x5b2674=_0x128b89['startOf']('year')['toJSDate'](),_0x30d5be=String(_0x128b89['year'])),{'startDate':_0x5b2674,'localizedPeriodName':_0x30d5be};}class li extends _0x1f7714{['startDate'];['revisionViews'];['_revisionActions'];['_requireRevisionName'];constructor(_0x2059d7,_0x2eb934,_0x17cc65,_0x52841e){super(_0x2059d7);const _0x119384=mi(_0x2eb934,this['locale']['uiLanguage'])['localizedPeriodName'];this['startDate']=_0x2eb934,this['revisionViews']=this['createCollection'](),this['_revisionActions']=_0x17cc65,this['_requireRevisionName']=_0x52841e,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':_0x119384}]},{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__time-period__revisions']},'children':this['revisionViews']}]});}['addRevision'](_0x52b555){const _0x11d4e7=new vi(this['locale'],_0x52b555,this['_revisionActions'],this['_requireRevisionName']);this['revisionViews']['add'](_0x11d4e7);}['removeRevision'](_0x49fb62){const _0x52cd1b=this['revisionViews']['find'](_0x29a6de=>_0x29a6de['id']===_0x49fb62['id']);this['revisionViews']['remove'](_0x52cd1b);}}class bi extends _0x1f7714{constructor(_0x4af2a9){super(_0x4af2a9);const _0x5293bd=new _0x8f1b89();_0x5293bd['content']=_0x30d3bd,this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset_all','ck-revision-history-sidebar__header']},'children':[_0x5293bd,{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__header__label']},'children':[m(_0x4af2a9,'Revision\x20history')]}]});}}class di extends _0x1f7714{['timePeriodViews'];['_revisions'];['_revisionActions'];['_requireRevisionName'];constructor(_0x160da7,_0x5543e9,_0x24985b,_0xc2857b){super(_0x160da7);const _0x20da30=this['bindTemplate'];this['timePeriodViews']=this['createCollection'](),this['timePeriodViews']['delegate']('select')['to'](this),this['timePeriodViews']['delegate']('setName')['to'](this),this['_revisions']=_0x5543e9,this['_revisionActions']=_0x24985b,this['_requireRevisionName']=_0xc2857b,this['on']('select',(_0x172d1f,_0x166393)=>{this['fire']('revisionSelected',_0x166393);}),this['on']('setName',(_0x82e43d,_0x295410)=>{this['fire']('revisionSetName',_0x295410);}),this['set']('isEnabled',!0x1),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-rounded-corners','ck-revision-history-sidebar']},'children':[new bi(_0x160da7),{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__timeline',_0x20da30['if']('isEnabled','ck-disabled',_0x74102a=>!_0x74102a)]},'children':this['timePeriodViews']}]});}['render'](){super['render']();for(const _0x36e139 of this['_revisions'])this['_addRevision'](_0x36e139);this['_revisions']['on']('add',(_0x4a739d,_0x384252)=>{this['_addRevision'](_0x384252);}),this['_revisions']['on']('remove',(_0x5648a3,_0x40fbf7)=>{this['_removeRevision'](_0x40fbf7);});}get['revisionViews'](){return this['timePeriodViews']['map'](_0x2c302=>_0x2c302['revisionViews']['map'](_0x2c66f8=>_0x2c66f8))['flat']();}['selectRevision'](_0x572f1d){for(const _0x280340 of this['revisionViews'])_0x572f1d&&_0x572f1d['id']===_0x280340['id']?_0x280340['select']():_0x280340['deselect']();}['highlightRevisions'](_0x2586bd){for(const _0x141098 of this['revisionViews'])_0x2586bd['some'](({id:_0x4cae6c})=>_0x4cae6c===_0x141098['id'])?_0x141098['highlight']():_0x141098['unhighlight']();}['_addRevision'](_0x5e3438){const _0x583144=mi(_0x5e3438['createdAt'],this['locale']['uiLanguage'])['startDate'];let _0x521718=this['timePeriodViews']['get'](0x0);_0x521718&&_0x521718['startDate']['getTime']()===_0x583144['getTime']()||(_0x521718=new li(this['locale'],_0x583144,this['_revisionActions'],this['_requireRevisionName']),this['timePeriodViews']['add'](_0x521718)),_0x521718['addRevision'](_0x5e3438);}['_removeRevision'](_0x354c06){const _0x4f9775=mi(_0x354c06['createdAt'],this['locale']['uiLanguage'])['startDate'];this['_getTimePeriodViewByStartDate'](_0x4f9775)['removeRevision'](_0x354c06);}['_getTimePeriodViewByStartDate'](_0x178f1d){return this['timePeriodViews']['find'](_0x666b49=>_0x666b49['startDate']['getTime']()===_0x178f1d['getTime']());}}class d extends _0x17be55{['_revisionViewer'];['_revisionsRepository'];['_sidebarView'];static ['defaultRevisionActions']=/* #__PURE__ -- @preserve */
23
+ import{ObservableMixin as _0xb6d8a,uid as _0x391c61,Collection as _0x480dd0,logWarning as _0x598afb,FocusTracker as _0x158451,KeystrokeHandler as _0x2465a1,scrollViewportToShowTarget as _0x57502f,ResizeObserver as ot,ElementReplacer as it,CKEditorError as _0x1b5dfa}from'@ckeditor/ckeditor5-utils/dist/index.js';import{cloneDeep as _0x115d90,set as _0x38753d,unset as _0x2b39b2,isEqual as _0x3c1091}from'es-toolkit/compat';import{Plugin as _0x439397,PendingActions as _0x3a0f3e,Command as _0x3687d4,ElementApiMixin as _0x37a1b5,Editor as _0x28b480}from'@ckeditor/ckeditor5-core/dist/index.js';import{Users as _0x153f01,getMarkerDomElement as _0x37341c,ConfirmMixin as _0xd98c6c,sanitizeEditorConfig as _0x1dfe24}from'ckeditor5-collaboration/dist/index.js';import{ViewContainerElement as _0xc04067,ViewAttributeElement as _0x27f1be,ViewEmptyElement as _0x18bbe4,ViewRawElement as _0x362490,ViewUIElement as _0xf8962f,ViewDocumentFragment as _0x3581a6,ViewText as _0x398fcf,ViewElement as _0x12e4e5,ModelElement as _0x14fd90,ModelRange as _0x23adf7,ModelPosition as _0x3ee28f,ModelDocumentFragment as _0xf3d172,ModelText as _0xe3cd6f}from'@ckeditor/ckeditor5-engine/dist/index.js';import{IconHistory as _0x5d69e0,IconChevronUp as _0x592aca,IconChevronDown as _0x31f17d,IconUndo as _0x4f5970,IconUser as _0x24ea6a,IconThreeVerticalDots as _0x2761e7}from'@ckeditor/ckeditor5-icons/dist/index.js';import{CssTransitionDisablerMixin as _0x569437,View as _0x5f53a2,submitHandler as _0x77e4ed,LabeledFieldView as et,createLabeledInputText as ti,createDropdown as _0x488b40,ListView as _0x177957,ListItemView as _0x3e754b,ButtonView as _0x5108a7,MenuBarMenuView as _0x199c1c,MenuBarMenuListView as _0x4b9c74,MenuBarMenuListItemView as _0xaee688,MenuBarMenuListItemButtonView as _0x3ce466,ContextualBalloon as _0x9a6d6b,ToolbarSeparatorView as _0x3f3ce6,IconView as _0x243002,addListToDropdown as _0x150c07,UIModel as to,EditorUI as tt,normalizeToolbarConfig as st,BoxedEditorUIView as _0x30ff7f,StickyPanelView as _0x124771,ToolbarView as _0x406902,InlineEditableUIView as te}from'@ckeditor/ckeditor5-ui/dist/index.js';import{DateTime as _0x271ae0}from'luxon';class I extends/* #__PURE__ -- @preserve */
24
+ _0xb6d8a(){['id'];['creator'];['authors'];['diffData'];['toVersion'];['fromVersion'];['model'];constructor(_0x5b5ae1){super(),this['id']=_0x5b5ae1['id']||_0x391c61(),this['creator']=_0x5b5ae1['creator']||null,this['authors']=_0x5b5ae1['authors']||[],this['diffData']=_0x5b5ae1['diffData']||null,this['toVersion']=_0x5b5ae1['toVersion']||0x0,this['fromVersion']=_0x5b5ae1['fromVersion']||0x0,this['set']('name',_0x5b5ae1['name']||''),this['set']('createdAt',_0x5b5ae1['createdAt']||new Date()),this['set']('attributes',_0x5b5ae1['attributes']||{});}['setName'](_0x4249c3){this['_update']({'name':_0x4249c3});}['setAttribute'](_0x2b4335,_0x2b6b41){const _0x30b201=_0x115d90(this['attributes']);_0x38753d(_0x30b201,_0x2b4335,_0x2b6b41),this['_update']({'attributes':_0x30b201});}['removeAttribute'](_0x3f444a){const _0x474a70=_0x115d90(this['attributes']);_0x2b39b2(_0x474a70,_0x3f444a),this['_update']({'attributes':_0x474a70});}['_update'](_0x42743f,_0x362a7d=!0x1){let _0x2592ca=!0x1;const _0x2ba90e={'id':this['id']},_0x239524=['name','createdAt','diffData','authors','attributes','toVersion','fromVersion','creatorId'];for(const _0x1c8aa0 of _0x239524){const _0x29f24a=_0x42743f[_0x1c8aa0];void 0x0!==_0x29f24a&&_0x29f24a!==this[_0x1c8aa0]&&(this[_0x1c8aa0]=_0x29f24a,_0x2ba90e[_0x1c8aa0]=_0x29f24a,_0x2592ca=!0x0);}_0x2592ca&&(_0x2ba90e['authors']&&(_0x2ba90e['authorsIds']=_0x2ba90e['authors']['map'](_0x4401b6=>_0x4401b6['id']),delete _0x2ba90e['authors']),this['fire']('_update',_0x2ba90e,_0x362a7d));}['toJSON'](){return{'id':this['id'],'name':this['name'],'creatorId':this['creator']?this['creator']['id']:null,'authorsIds':this['authors']['map'](_0x1b013a=>_0x1b013a['id']),'diffData':this['diffData'],'createdAt':this['createdAt'],'attributes':this['attributes'],'fromVersion':this['fromVersion'],'toVersion':this['toVersion']};}}class S extends _0x439397{['_revisions'];static get['requires'](){return[_0x153f01];}static get['pluginName'](){return'RevisionsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['length'](){return this['_revisions']['length'];}constructor(_0x10567f){super(_0x10567f),this['_revisions']=new _0x480dd0();}['afterInit'](){!async function(_0x216252){const _0x4621c9=_0x12cff5([0x76,0x73,0x6d,0x4c,0x34,0x54,0x50,0x70,0x75,0x52,0x35,0x33,0x4d,0x6c,0x71,0x53,0x6a,0x32,0x56,0x58,0x77,0x48,0x39,0x6f,0x45,0x41,0x4e,0x38,0x46,0x78,0x4a,0x74,0x47,0x55,0x4f,0x64,0x62,0x44,0x43,0x5a,0x30,0x31,0x69,0x68,0x79,0x66,0x6b,0x42,0x51,0x59,0x36,0x61,0x63,0x67,0x7a,0x37,0x72,0x49,0x65,0x57,0x4b,0x6e]),_0x214e94=0xeb829,_0x152855=0x359e09b0,_0x28838b=0x359977e0^_0x152855,_0x3341c4=window[_0x12cff5([0x44,0x61,0x74,0x65])][_0x12cff5([0x6e,0x6f,0x77])](),_0x2627af=_0x216252[_0x12cff5([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x495c99=new window[(_0x12cff5([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0xfed79e=>{_0x2627af[_0x12cff5([0x6f,0x6e,0x63,0x65])](_0x12cff5([0x72,0x65,0x61,0x64,0x79]),_0xfed79e);}),_0x22de97={[_0x12cff5([0x6b,0x74,0x79])]:_0x12cff5([0x45,0x43]),[_0x12cff5([0x75,0x73,0x65])]:_0x12cff5([0x73,0x69,0x67]),[_0x12cff5([0x63,0x72,0x76])]:_0x12cff5([0x50,0x2d,0x32,0x35,0x36]),[_0x12cff5([0x78])]:_0x12cff5([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]),[_0x12cff5([0x79])]:_0x12cff5([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]),[_0x12cff5([0x61,0x6c,0x67])]:_0x12cff5([0x45,0x53,0x32,0x35,0x36])},_0x72289c=_0x2627af[_0x12cff5([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x12cff5([0x67,0x65,0x74])](_0x12cff5([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x31bc8b(){let _0x3e12dc,_0x379e5f=null,_0x13d3cc=null;try{if(_0x72289c==_0x12cff5([0x47,0x50,0x4c]))return _0x12cff5([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x3e12dc=_0x1d312c(),!_0x3e12dc)return _0x12cff5([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x3e12dc[_0x12cff5([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x13d3cc=_0x374b43(_0x3e12dc[_0x12cff5([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x3e12dc[_0x12cff5([0x6a,0x74,0x69])])),await _0x2f3e0f()?_0xebe958()?_0x10cdc2()?_0x12cff5([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x1ba14c()?(_0x3e12dc[_0x12cff5([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x12cff5([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x379e5f=_0x1094d0(_0x12cff5([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),await _0x4c292b()):_0x12cff5([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x12cff5([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x12cff5([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch{return _0x12cff5([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x10cdc2(){const _0x41c438=[_0x12cff5([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x12cff5([0x74,0x72,0x69,0x61,0x6c])][_0x12cff5([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x3e12dc[_0x12cff5([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x3341c4/0x3e8:0xe10*_0x28838b;return _0x3e12dc[_0x12cff5([0x65,0x78,0x70])]<_0x41c438;}function _0xebe958(){const _0x44f31a=_0x3e12dc[_0x12cff5([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x44f31a)return!0x1;if(_0x44f31a[_0x12cff5([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x12cff5([0x2a])))return!0x0;if(_0x44f31a[_0x12cff5([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x12cff5([0x52,0x48])))return!0x0;if(_0x44f31a[_0x12cff5([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x12cff5([0x52,0x52,0x48]))){if(_0x46a195())return!0x0;if(_0x2aa256()||_0x3325b4())return!0x0;}return!0x1;}function _0x1ba14c(){const _0x456ad6=_0x3e12dc[_0x12cff5([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x456ad6||0x0==_0x456ad6[_0x12cff5([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x5a58d0}=new URL(window[_0x12cff5([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x456ad6[_0x12cff5([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x5a58d0))return!0x0;const _0x57fbe1=_0x5a58d0[_0x12cff5([0x73,0x70,0x6c,0x69,0x74])](_0x12cff5([0x2e]));return _0x456ad6[_0x12cff5([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x45b619=>_0x45b619[_0x12cff5([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x12cff5([0x2a])))[_0x12cff5([0x6d,0x61,0x70])](_0xa07847=>_0xa07847[_0x12cff5([0x73,0x70,0x6c,0x69,0x74])](_0x12cff5([0x2e])))[_0x12cff5([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x4672a9=>_0x4672a9[_0x12cff5([0x6c,0x65,0x6e,0x67,0x74,0x68])]<=_0x57fbe1[_0x12cff5([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x12cff5([0x6d,0x61,0x70])](_0x59d2f7=>Array(_0x57fbe1[_0x12cff5([0x6c,0x65,0x6e,0x67,0x74,0x68])]-_0x59d2f7[_0x12cff5([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x12cff5([0x66,0x69,0x6c,0x6c])](_0x59d2f7[0x0]===_0x12cff5([0x2a])?_0x12cff5([0x2a]):'')[_0x12cff5([0x63,0x6f,0x6e,0x63,0x61,0x74])](_0x59d2f7))[_0x12cff5([0x73,0x6f,0x6d,0x65])](_0x151ebf=>_0x57fbe1[_0x12cff5([0x65,0x76,0x65,0x72,0x79])]((_0x233d3e,_0xe405ec)=>_0x151ebf[_0xe405ec]===_0x233d3e||_0x151ebf[_0xe405ec]===_0x12cff5([0x2a])));}function _0x4c292b(){return _0x379e5f&&_0x13d3cc?new window[(_0x12cff5([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x5c2561,_0xb6fc1a)=>{_0x379e5f[_0x12cff5([0x74,0x68,0x65,0x6e])](_0x5c2561,_0xb6fc1a),_0x13d3cc[_0x12cff5([0x74,0x68,0x65,0x6e])](_0x133f83=>{_0x133f83!=_0x12cff5([0x56,0x61,0x6c,0x69,0x64])&&_0x5c2561(_0x133f83);},_0xb6fc1a);}):_0x379e5f||_0x13d3cc||_0x12cff5([0x56,0x61,0x6c,0x69,0x64]);}}function _0x374b43(_0x5e49f4,_0x5dea05){return new window[(_0x12cff5([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x4c797=>{if(_0x459b01())return _0x4c797(_0x12cff5([0x56,0x61,0x6c,0x69,0x64]));_0x399997(),_0x2627af[_0x12cff5([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x12cff5([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x5b5e07=!0x1;const _0x18799a=_0x391c61();function _0x3de778(_0x189fb1){return!!_0x189fb1&&(typeof _0x189fb1===_0x12cff5([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x189fb1===_0x12cff5([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x189fb1[_0x12cff5([0x74,0x68,0x65,0x6e])]===_0x12cff5([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x189fb1[_0x12cff5([0x63,0x61,0x74,0x63,0x68])]===_0x12cff5([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x312858(_0x492df2){_0x2116cb(_0x492df2)[_0x12cff5([0x74,0x68,0x65,0x6e])](_0x1f332f=>{if(!_0x1f332f||_0x1f332f[_0x12cff5([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x12cff5([0x6f,0x6b]))return _0x12cff5([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x3fa4fa(_0x43e355(_0x18799a+_0x5dea05))!=_0x1f332f[_0x12cff5([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x12cff5([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x12cff5([0x56,0x61,0x6c,0x69,0x64]);})[_0x12cff5([0x74,0x68,0x65,0x6e])](_0x21c628=>(_0x64977b(),_0x21c628),()=>{const _0xc1a718=_0x5be6ee();return null==_0xc1a718?(_0x64977b(),_0x12cff5([0x56,0x61,0x6c,0x69,0x64])):_0x12cff5(_0x3341c4-_0xc1a718>(0x11928db0^_0x152855)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x12cff5([0x74,0x68,0x65,0x6e])](_0x4c797)[_0x12cff5([0x63,0x61,0x74,0x63,0x68])](()=>{_0x4c797(_0x12cff5([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x23a190=0x35a8e730^_0x152855;function _0x64977b(){const _0x486545=_0x12cff5([0x6c,0x6c,0x63,0x74,0x2d])+_0x3fa4fa(_0x43e355(_0x5e49f4)),_0x5bae66=_0x455485(_0x3fa4fa(window[_0x12cff5([0x4d,0x61,0x74,0x68])][_0x12cff5([0x63,0x65,0x69,0x6c])](_0x3341c4/_0x23a190)));window[_0x12cff5([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x12cff5([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x486545,_0x5bae66);}function _0x5be6ee(){const _0x31d4f5=_0x12cff5([0x6c,0x6c,0x63,0x74,0x2d])+_0x3fa4fa(_0x43e355(_0x5e49f4)),_0x4df187=window[_0x12cff5([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x12cff5([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x31d4f5);return _0x4df187?window[_0x12cff5([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x455485(_0x4df187),0x10)*_0x23a190:null;}function _0x2116cb(_0x117edf){return new window[(_0x12cff5([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x5b371c,_0x3aeed0)=>{_0x117edf[_0x12cff5([0x74,0x68,0x65,0x6e])](_0x5b371c,_0x3aeed0),window[_0x12cff5([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x3aeed0,0x359fdd70^_0x152855);});}}_0x2627af[_0x12cff5([0x6f,0x6e])](_0x12cff5([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x2b16c7,_0x92b29e)=>{if(_0x92b29e[0x0]!=_0x5e49f4)return _0x4c797(_0x12cff5([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x92b29e[0x1]={..._0x92b29e[0x1],[_0x12cff5([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x18799a};},{[_0x12cff5([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x12cff5([0x68,0x69,0x67,0x68])}),_0x2627af[_0x12cff5([0x6f,0x6e])](_0x12cff5([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x58baa0=>{_0x3de778(_0x58baa0[_0x12cff5([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x5b5e07=!0x0,_0x312858(_0x58baa0[_0x12cff5([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x12cff5([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x12cff5([0x6c,0x6f,0x77])}),_0x495c99[_0x12cff5([0x74,0x68,0x65,0x6e])](()=>{_0x5b5e07||_0x4c797(_0x12cff5([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x459b01(){return _0x2627af[_0x12cff5([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x12cff5([0x76,0x69,0x65,0x77])][_0x12cff5([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x12cff5([0x61,0x75,0x74,0x6f]);}function _0x399997(){_0x2627af[_0x12cff5([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x12cff5([0x76,0x69,0x65,0x77])][_0x12cff5([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x12cff5([0x61,0x75,0x74,0x6f]);}}function _0x1094d0(_0x203b41){const _0x210512=[new window[(_0x12cff5([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x329851=>setTimeout(_0x329851,0x3597377c^_0x152855)),_0x495c99[_0x12cff5([0x74,0x68,0x65,0x6e])](()=>new window[(_0x12cff5([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x437ffb=>{const _0x453da7=0x359e09b7^_0x152855,_0x1fdc3=_0x216252[_0x12cff5([0x5f,0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x73])];function _0x399483(){_0x1fdc3[_0x12cff5([0x6c,0x65,0x6e,0x67,0x74,0x68])]>=_0x453da7&&_0x437ffb();}_0x399483(),_0x1fdc3[_0x12cff5([0x6f,0x6e])](_0x12cff5([0x61,0x64,0x64]),_0x399483);})),new window[(_0x12cff5([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x3b870a=>{function _0x3abecc(){for(const _0x33f3d9 in window)if(window[_0x12cff5([0x4e,0x75,0x6d,0x62,0x65,0x72])]['isNaN'](window[_0x12cff5([0x4e,0x75,0x6d,0x62,0x65,0x72])](_0x33f3d9))&&window[_0x33f3d9]==_0x214e94)return _0x3b870a();_0x2627af[_0x12cff5([0x73,0x74,0x61,0x74,0x65])]!=_0x12cff5([0x64,0x65,0x73,0x74,0x72,0x6f,0x79,0x65,0x64])&&window[_0x12cff5([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x3abecc,0x359e1a38^_0x152855);}_0xe573be(_0x12cff5([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))&&_0x3abecc();})];return window[_0x12cff5([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x12cff5([0x72,0x61,0x63,0x65])](_0x210512)[_0x12cff5([0x74,0x68,0x65,0x6e])](()=>_0x203b41);}async function _0x421b34(){if(await _0x495c99,_0xe573be(_0x12cff5([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))){const _0x524402=_0x216252[_0x12cff5([0x67,0x65,0x74,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](0x0),_0x27090e=_0x216252[_0x12cff5([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])](_0x524402[_0x12cff5([0x69,0x64])]),_0x2b2679=_0x5501d7(_0x12cff5([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]));return await _0x2b2679[_0x12cff5([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])](_0x524402['id'],_0x27090e?_0x27090e['id']:null,!0x0),_0x2b2679[_0x12cff5([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x12cff5([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x2b2679[_0x12cff5([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x2b2679[_0x12cff5([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])]=_0x2a266a,void(_0x2b2679[_0x12cff5([0x5f,0x67,0x65,0x74,0x44,0x69,0x66,0x66])]=_0x2a266a);}if(_0xe573be(_0x12cff5([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]))){const _0x10d372=_0x5501d7(_0x12cff5([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]));_0x10d372[_0x12cff5([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x12cff5([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x10d372[_0x12cff5([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x10d372[_0x12cff5([0x75,0x70,0x64,0x61,0x74,0x65])]=_0x2a266a,_0x10d372[_0x12cff5([0x73,0x61,0x76,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])]=_0x2a266a;}_0x2627af[_0x12cff5([0x6d,0x6f,0x64,0x65,0x6c])][_0x12cff5([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x2a266a,_0x2627af[_0x12cff5([0x6d,0x6f,0x64,0x65,0x6c])][_0x12cff5([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x2a266a,_0x2627af[_0x12cff5([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x12cff5([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x46a195(){return _0xe573be(_0x12cff5([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x5501d7(_0x12cff5([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x12cff5([0x73,0x74,0x61,0x74,0x65])]==_0x12cff5([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x2aa256(){return _0xe573be(_0x12cff5([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 _0x3325b4(){return _0xe573be(_0x12cff5([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0x4885ee(_0xdf4dff){const _0x5ee72c=_0xa46b06();_0x2627af[_0x5ee72c]=_0x12cff5([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])+_0xdf4dff,_0xdf4dff[_0x12cff5([0x65,0x6e,0x64,0x73,0x57,0x69,0x74,0x68])](_0x12cff5([0x4c,0x69,0x6d,0x69,0x74]))&&(window[_0xa46b06()]=_0x214e94),_0xdf4dff!=_0x12cff5([0x56,0x61,0x6c,0x69,0x64])&&_0x421b34();}function _0xa46b06(){const _0x32c66d=window[_0x12cff5([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x12cff5([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x12cff5([0x6e,0x6f,0x77])]())[_0x12cff5([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x12cff5([0x2e]),'');let _0x2954b8=_0x12cff5([0x76]);for(let _0x3753d9=0x0;_0x3753d9<_0x32c66d[_0x12cff5([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x3753d9+=0x2){let _0x577f6c=window[_0x12cff5([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x32c66d[_0x12cff5([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x3753d9,_0x3753d9+0x2));_0x577f6c>=_0x4621c9[_0x12cff5([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x577f6c-=_0x4621c9[_0x12cff5([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x2954b8+=_0x4621c9[_0x577f6c];}return _0x2954b8;}function _0x1d312c(){const _0x1b6f58=_0x72289c[_0x12cff5([0x73,0x70,0x6c,0x69,0x74])](_0x12cff5([0x2e]));if(0x3!=_0x1b6f58[_0x12cff5([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x52b395(_0x1b6f58[0x1]);function _0x52b395(_0x10c844){const _0x25262b=_0x46b71e(_0x10c844);return _0x25262b&&_0x27959c()?_0x25262b:null;function _0x27959c(){const _0x51eab8=_0x25262b[_0x12cff5([0x6a,0x74,0x69])],_0xb25d5a=window[_0x12cff5([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x51eab8[_0x12cff5([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x51eab8[_0x12cff5([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x4a8e93={..._0x25262b,[_0x12cff5([0x6a,0x74,0x69])]:_0x51eab8[_0x12cff5([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x51eab8[_0x12cff5([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x4a8e93[_0x12cff5([0x76,0x63])],_0x43e355(_0x4a8e93)==_0xb25d5a;}}}async function _0x2f3e0f(){let _0x44e84a=!0x0;try{const _0x365b09=_0x72289c[_0x12cff5([0x73,0x70,0x6c,0x69,0x74])](_0x12cff5([0x2e])),[_0x1d30f3,_0x395423,_0x3945d9]=_0x365b09;return _0x769a43(_0x1d30f3),await _0x38b510(_0x1d30f3,_0x395423,_0x3945d9),_0x44e84a;}catch{return!0x1;}function _0x769a43(_0x4df963){const _0x254583=_0x46b71e(_0x4df963);_0x254583&&_0x254583[_0x12cff5([0x61,0x6c,0x67])]==_0x12cff5([0x45,0x53,0x32,0x35,0x36])||(_0x44e84a=!0x1);}async function _0x38b510(_0x4951b6,_0x489bfd,_0x30d05b){const _0x226912=window[_0x12cff5([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x12cff5([0x66,0x72,0x6f,0x6d])](_0x1b5b5c(_0x30d05b),_0x1b475c=>_0x1b475c[_0x12cff5([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x265c7d=new window[(_0x12cff5([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x12cff5([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x4951b6+_0x12cff5([0x2e])+_0x489bfd),_0x5e4a4c=window[_0x12cff5([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x12cff5([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x5e4a4c)return;const _0xd3a0eb=await _0x5e4a4c[_0x12cff5([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x12cff5([0x6a,0x77,0x6b]),_0x22de97,{[_0x12cff5([0x6e,0x61,0x6d,0x65])]:_0x12cff5([0x45,0x43,0x44,0x53,0x41]),[_0x12cff5([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x12cff5([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x12cff5([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x5e4a4c[_0x12cff5([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x12cff5([0x6e,0x61,0x6d,0x65])]:_0x12cff5([0x45,0x43,0x44,0x53,0x41]),[_0x12cff5([0x68,0x61,0x73,0x68])]:{[_0x12cff5([0x6e,0x61,0x6d,0x65])]:_0x12cff5([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0xd3a0eb,_0x226912,_0x265c7d)||(_0x44e84a=!0x1);}}function _0x46b71e(_0x27b8d8){return _0x27b8d8[_0x12cff5([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x12cff5([0x65,0x79]))?JSON[_0x12cff5([0x70,0x61,0x72,0x73,0x65])](_0x1b5b5c(_0x27b8d8)):null;}function _0x1b5b5c(_0x1a833e){return window[_0x12cff5([0x61,0x74,0x6f,0x62])](_0x1a833e[_0x12cff5([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x12cff5([0x2b]))[_0x12cff5([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x12cff5([0x2f])));}function _0x43e355(_0x2073d3){let _0x2950b2=0x1505;function _0x2db645(_0x78fea3){for(let _0x24d22f=0x0;_0x24d22f<_0x78fea3[_0x12cff5([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x24d22f++){const _0x55fc68=_0x78fea3[_0x12cff5([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x24d22f);_0x2950b2=(_0x2950b2<<0x5)+_0x2950b2+_0x55fc68,_0x2950b2&=_0x2950b2;}}function _0x1cf543(_0x419e8b){Array[_0x12cff5([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x419e8b)?_0x419e8b[_0x12cff5([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x1cf543):_0x419e8b&&typeof _0x419e8b==_0x12cff5([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x12cff5([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x419e8b)[_0x12cff5([0x73,0x6f,0x72,0x74])]()[_0x12cff5([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x46c351,_0x282dcd])=>{_0x2db645(_0x46c351),_0x1cf543(_0x282dcd);}):_0x2db645(window[_0x12cff5([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x419e8b));}return _0x1cf543(_0x2073d3),_0x2950b2>>>0x0;}function _0x3fa4fa(_0x18bcf4){return _0x18bcf4[_0x12cff5([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x12cff5([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x12cff5([0x30]));}function _0x455485(_0xb97540){return _0xb97540[_0x12cff5([0x73,0x70,0x6c,0x69,0x74])]('')[_0x12cff5([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x12cff5([0x6a,0x6f,0x69,0x6e])]('');}function _0xe573be(_0xbd413e){return _0x2627af[_0x12cff5([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x12cff5([0x68,0x61,0x73])](_0xbd413e);}function _0x5501d7(_0x447724){return _0x2627af[_0x12cff5([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x12cff5([0x67,0x65,0x74])](_0x447724);}function _0x2a266a(){}function _0x12cff5(_0x469795){return _0x469795['map'](_0x51c409=>String['fromCharCode'](_0x51c409))['join']('');}_0x4885ee(await _0x31bc8b());}(this);}['createRevision'](_0x3a2815){const _0x4e0da6=this['editor']['plugins']['get']('Users');return new I({'id':_0x3a2815['id'],'name':_0x3a2815['name'],'creator':_0x3a2815['creatorId']?_0x4e0da6['getUser'](_0x3a2815['creatorId']):null,'diffData':_0x3a2815['diffData']||_0x3a2815['data'],'authors':_0x3a2815['authorsIds']['map'](_0x3f1df1=>_0x4e0da6['getUser'](_0x3f1df1)),'createdAt':new Date(_0x3a2815['createdAt']),'attributes':_0x3a2815['attributes'],'fromVersion':_0x3a2815['fromVersion'],'toVersion':_0x3a2815['toVersion']});}['addRevision'](_0x191ba3,_0x2a49dc=0x0){this['_revisions']['add'](_0x191ba3,_0x2a49dc);}['getRevision'](_0x50e68e){return this['_revisions']['get'](_0x50e68e);}['getRevisions'](_0x18e63c={'toJSON':!0x1}){const _0x3d495d=Array['from'](this['_revisions']);return _0x3d495d['reverse'](),_0x18e63c['toJSON']?_0x3d495d['map'](_0x3de661=>_0x3de661['toJSON']()):_0x3d495d;}['getIndex'](_0x4f6aba){return this['_revisions']['getIndex'](_0x4f6aba);}['getEarlierVisibleRevision'](_0x5822fb){const [,_0x504ddd]=this['getRevisionsIterator'](_0x5822fb,{'direction':'earlier'});return _0x504ddd;}['getLaterVisibleRevision'](_0x38aa97){const [,_0x4ab346]=this['getRevisionsIterator'](_0x38aa97,{'direction':'later'});return _0x4ab346;}['getRevisionsInDiff'](_0x5a9a58){const _0x48dc5f=[];for(const _0x498b8f of this['getRevisionsIterator'](_0x5a9a58['newRevisionId']))if(_0x48dc5f['push'](_0x498b8f),_0x498b8f['id']===_0x5a9a58['oldRevisionId'])break;return _0x48dc5f;}*['getRevisionsIterator'](_0x2d826b,{direction:_0x19634d='earlier',filter:_0x289d31=()=>!0x0}={}){const _0x5c343b='earlier'===_0x19634d?0x1:-0x1;let _0x290137=this['_revisions']['get'](_0x2d826b),_0x498967=this['getIndex'](_0x290137);for(yield _0x290137;_0x290137;){if(_0x498967+=_0x5c343b,_0x290137=this['getRevision'](_0x498967),!_0x290137)return;_0x289d31(_0x290137)&&(yield _0x290137);}}}class $ extends _0x439397{static get['pluginName'](){return'RevisionHistoryUtils';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['_viewClassToTypeChar']=new Map([[_0xc04067,'c'],[_0x27f1be,'a'],[_0x18bbe4,'e'],[_0x362490,'r'],[_0xf8962f,'u']]);['_typeCharToViewClass']=new Map([['c',_0xc04067],['a',_0x27f1be],['e',_0x18bbe4],['r',_0x362490],['u',_0xf8962f]]);async['loadRevisionData'](_0x8f27f7,_0xcfcc62){if(_0x8f27f7['diffData']||!_0xcfcc62)return;const _0x2e7d4a=this['editor']['config']['get']('collaboration.channelId'),_0x236422=await _0xcfcc62['getRevision']({'channelId':_0x2e7d4a,'revisionId':_0x8f27f7['id']});_0x8f27f7['diffData']=_0x236422['diffData'];}['getRevisionDocumentData'](_0x227053){const _0x5ce4f6={};for(const _0x322b69 in _0x227053['diffData']){if(_0x227053['diffData'][_0x322b69]['attachChange']&&!_0x227053['diffData'][_0x322b69]['attachChange']['isAttached'])continue;const _0x454ae3=this['_removeRevisionMarkers'](JSON['parse'](_0x227053['diffData'][_0x322b69]['insertions'])),_0x5aa4e5=this['editor']['editing']['view']['document'],_0x6722c4=new _0x3581a6(_0x5aa4e5,_0x454ae3['map'](_0x52d324=>this['_getViewFromDiffObj'](_0x52d324,!0x1)));this['editor']['data']['processor']['useFillerType']('marked'),_0x5ce4f6[_0x322b69]=this['editor']['data']['processor']['toData'](_0x6722c4),this['editor']['data']['processor']['useFillerType']('default');}return _0x5ce4f6;}['getRevisionRootsAttributes'](_0x159df3){const _0x460a4a={};for(const _0x5719b9 in _0x159df3['diffData'])_0x159df3['diffData'][_0x5719b9]['attachChange']&&!_0x159df3['diffData'][_0x5719b9]['attachChange']['isAttached']||(_0x460a4a[_0x5719b9]=_0x159df3['diffData'][_0x5719b9]['attributesAfter']||{});return _0x460a4a;}['_getTypeCharForViewElement'](_0x417e6c){return this['_viewClassToTypeChar']['get'](_0x417e6c['constructor']);}['_getViewFromDiffObj'](_0x185616,_0x55b5a7){const _0x2cabaf=this['editor']['editing']['view']['document'];if('string'==typeof _0x185616)return new _0x398fcf(_0x2cabaf,_0x185616);{let _0x53363a,_0x522c21;_0x522c21='u'==_0x185616['type']||'r'==_0x185616['type']?[]:_0x185616['children']['map'](_0xb7c90=>this['_getViewFromDiffObj'](_0xb7c90,_0x55b5a7));const _0x8d84a7=this['_typeCharToViewClass']['get'](_0x185616['type'])||_0x12e4e5,_0x580e88=this['editor']['data']['htmlProcessor']['domConverter'];if(_0x53363a=new _0x8d84a7(_0x2cabaf,_0x185616['name'],_0x185616['attributes'],_0x522c21),'u'==_0x185616['type']&&_0x185616['children'][0x0]){const _0x286cc8=_0x185616['children'][0x0];if(_0x53363a['render']=function(_0x262ab0){const _0x1d439a=_0x262ab0['createElement']('div');return _0x1d439a['innerHTML']=_0x286cc8,_0x1d439a['childNodes'][0x0];},_0x55b5a7){const _0x148336=new _0x3581a6(_0x2cabaf);_0x148336['_appendChild'](_0x53363a);const _0x33dd87=Array['from'](_0x580e88['viewChildrenToDom'](_0x148336,{'bind':!0x1})),_0x26b815=_0x580e88['domDocument']['createElement']('div');_0x26b815['append'](..._0x33dd87),_0x53363a=Array['from'](_0x580e88['domChildrenToView'](_0x26b815))[0x0];}}else{if('r'==_0x185616['type']&&_0x185616['children'][0x0]){const _0x2df719=_0x185616['children'][0x0];if(_0x53363a['render']=function(_0x52a68a){_0x52a68a['innerHTML']=_0x2df719;},_0x55b5a7){const _0x51e7a6=new _0x3581a6(_0x2cabaf);_0x51e7a6['_appendChild'](_0x53363a);const _0x2e2eab=Array['from'](_0x580e88['viewChildrenToDom'](_0x51e7a6,{'bind':!0x1})),_0x5992e1=_0x580e88['domDocument']['createElement']('div');_0x5992e1['append'](..._0x2e2eab);const _0x1a983a=Array['from'](_0x580e88['domChildrenToView'](_0x5992e1));_0x1a983a['length']>0x1?_0x53363a['_appendChild'](_0x1a983a):_0x53363a=_0x1a983a[0x0];}}}if(_0x185616['customProperties']){for(const [_0x3ebd6c,_0x418203]of _0x185616['customProperties'])_0x53363a['_setCustomProperty'](_0x3ebd6c,_0x418203);}const _0x4121d9=void 0x0===_0x185616['fillerOffset']?null:_0x185616['fillerOffset'];return null!==_0x4121d9&&(_0x53363a['getFillerOffset']=()=>_0x4121d9),_0x53363a;}}['_makeModelFromViewString'](_0x1042e5){const _0x1ffa21=JSON['parse'](_0x1042e5),_0x1f503f=this['editor']['editing']['view']['document'],_0x36fbc6=new _0x3581a6(_0x1f503f,_0x1ffa21['map'](_0x565d89=>this['_getViewFromDiffObj'](_0x565d89,!0x0)));return this['editor']['data']['toModel'](_0x36fbc6);}['_removeRevisionMarkers'](_0x1960f4){return(_0x1960f4=_0x1960f4['filter'](_0x3ba39a=>!_0x3ba39a['name']||'revision-start'!==_0x3ba39a['name']&&'revision-end'!==_0x3ba39a['name']))['forEach'](_0x3974b4=>{'string'!=typeof _0x3974b4&&(_0x3974b4['children']=this['_removeRevisionMarkers'](_0x3974b4['children']),_0x3974b4['attributes']=_0x3974b4['attributes']['filter'](_0x55a6f6=>!_0x55a6f6[0x0]['startsWith']('data-revision-')));}),_0x1960f4;}}function m(_0x382954,_0x771302,_0xc4c565){const t=_0x382954['t'];switch(_0x771302){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'},_0xc4c565);case'X_OF_Y_CHANGES':return t({'string':'%0\x20of\x20%1','id':'X_OF_Y_CHANGES'},_0xc4c565);case'Show\x20previous\x20change':return t('Show\x20previous\x20change');case'Show\x20next\x20change':return t('Show\x20next\x20change');case'EDIT_X_OF_Y_REVISIONS':return t({'string':'Edit','id':'EDIT_X_OF_Y_REVISIONS'});case'Total':return t('Total');case'Revision\x20creator':return t('Revision\x20creator');case'Revision\x20author':return t('Revision\x20author');case'Revision\x20name':return t('Revision\x20name');case'Save\x20current\x20revision':return t('Save\x20current\x20revision');case'Accept':return t('Accept');case'Save':return t('Save');case'Cancel':return t('Cancel');case'Name\x20of\x20the\x20revision':return t('Name\x20of\x20the\x20revision');case'optional':return t('optional');case'PENDING_ACTION_REVISION_HISTORY':return t({'string':'Unsaved\x20change\x20in\x20revision\x20history.','id':'PENDING_ACTION_REVISION_HISTORY'});case'The\x20revision\x20name\x20cannot\x20be\x20empty.':return t('The\x20revision\x20name\x20cannot\x20be\x20empty.');case'Enter\x20the\x20revision\x20name':return t('Enter\x20the\x20revision\x20name');default:return'';}}class h extends _0x439397{['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[_0x153f01,S,$,_0x3a0f3e];}constructor(_0x485b2e){super(_0x485b2e),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 _0x35214b=_0x391c61();this['_source']={'history':this['editor']['model']['document']['history'],'getLatestVersion':()=>Promise['resolve'](this['editor']['model']['document']['version']),'getCurrentRevisionId':()=>_0x35214b},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 _0x1d065b=this['repository']['getRevision'](0x0),_0x5f1e03=_0x1d065b&&null===_0x1d065b['creator']?_0x1d065b:null;if(this['_continueCurrentRevision']=!!_0x5f1e03&&this['editor']['config']['get']('revisionHistory.resumeUnsavedRevision'),this['editor']['plugins']['has']('RealTimeCollaborationClient')){const _0x1a1551=this['_source']['getCurrentRevisionId'](),_0x30931f=this['repository']['getRevision'](_0x1a1551);if(_0x30931f)this['_startingVersion']=_0x30931f['fromVersion'],this['_continueCurrentRevision']=!0x1;else{const _0x1926d0=this['_source']['history']['_operations']['find'](_0x1ba9c7=>!_0x1ba9c7['_isInit']),_0x245633=_0x1926d0?_0x1926d0['baseVersion']:this['_source']['history']['version'];_0x1d065b?(_0x1d065b['toVersion']<_0x245633&&_0x1d065b['_update']({'toVersion':_0x245633}),this['_continueCurrentRevision']?(this['_source']['getCurrentRevisionId']=()=>_0x5f1e03['id'],this['_startingVersion']=_0x5f1e03['fromVersion']):(this['_startingVersion']=_0x1d065b['toVersion'],this['_continueCurrentRevision']=!0x1)):(this['_startingVersion']=_0x245633,this['_continueCurrentRevision']=!0x1);}}else _0x5f1e03&&(this['editor']['model']['document']['history']['version']=Math['max'](_0x5f1e03['toVersion'],this['editor']['model']['document']['history']['version']),_0x5f1e03['fromVersion']===_0x5f1e03['toVersion']?(0x0!==_0x5f1e03['fromVersion']&&(this['_source']['getCurrentRevisionId']=()=>_0x5f1e03['id']),this['_continueCurrentRevision']=!0x1):this['_continueCurrentRevision']&&(this['_source']['getCurrentRevisionId']=()=>_0x5f1e03['id'],this['_startingVersion']=_0x5f1e03['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',_0x162953=>!_0x162953),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x4ef85d=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x34bbd7;for(const _0x128eda in _0x4ef85d){const _0x2494c7=_0x128eda,_0x3bc04b=_0x4ef85d[_0x2494c7];if('revisionHistoryLicenseKeyValid'==_0x3bc04b||'revisionHistoryLicenseKeyInvalid'==_0x3bc04b||'revisionHistoryLicenseKeyExpired'==_0x3bc04b||'revisionHistoryLicenseKeyDomainLimit'==_0x3bc04b||'revisionHistoryLicenseKeyNotAllowed'==_0x3bc04b||'revisionHistoryLicenseKeyEvaluationLimit'==_0x3bc04b||'revisionHistoryLicenseKeyUsageLimit'==_0x3bc04b){delete _0x4ef85d[_0x2494c7],_0x34bbd7=_0x3bc04b,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'revisionHistoryLicenseKeyInvalid'==_0x34bbd7&&_0x4ef85d['_showLicenseError']('invalid'),'revisionHistoryLicenseKeyExpired'==_0x34bbd7&&_0x4ef85d['_showLicenseError']('expired'),'revisionHistoryLicenseKeyDomainLimit'==_0x34bbd7&&_0x4ef85d['_showLicenseError']('domainLimit'),'revisionHistoryLicenseKeyNotAllowed'==_0x34bbd7&&_0x4ef85d['_showLicenseError']('featureNotAllowed','RevisionHistory'),'revisionHistoryLicenseKeyEvaluationLimit'==_0x34bbd7&&_0x4ef85d['_showLicenseError']('evaluationLimit'),'revisionHistoryLicenseKeyUsageLimit'==_0x34bbd7&&_0x4ef85d['_showLicenseError']('usageLimit');},0x3e8);}async['afterInit'](){if(this['repository']['length']>0x0){const _0x39a679=this['repository']['getRevision'](0x0),_0xcdfe7a=await this['getRevisionDocumentData'](_0x39a679),_0x33675d=await this['getRevisionRootsAttributes'](_0x39a679);this['_replaceEditorDataWithRevisionData'](_0xcdfe7a,_0x33675d);}}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['setSource'](_0x34ad17){this['_source']=_0x34ad17;}async['update'](){const _0x985765=await this['_source']['getLatestVersion']();if(_0x985765>this['currentRevision']['toVersion']){await this['_loadState']();const _0x1c1e62=this['buildRevisionData']({'revision':this['currentRevision'],'to':_0x985765});_0x1c1e62['authors']=_0x1c1e62['authorsIds']['map'](_0x3d1d2d=>this['editor']['plugins']['get']('Users')['getUser'](_0x3d1d2d)),this['currentRevision']['_update'](_0x1c1e62);}}async['saveRevision'](_0x9056aa={},_0x52c283=null){const _0x3eea76=[];await this['_loadState'](),this['_continueCurrentRevision']=!0x1,_0x52c283>this['currentRevision']['toVersion']&&(_0x52c283=null),null===_0x52c283&&(_0x52c283=await this['_source']['getLatestVersion']());const _0x2352f8=this['_getFromVersion'](_0x52c283),_0x90bb22=this['buildRevisionData']({'from':_0x2352f8,'to':_0x52c283});if(this['currentRevision']['toVersion']<_0x52c283){const _0x1ae1fe=this['buildRevisionData']({'revision':this['currentRevision'],'from':_0x52c283,'to':_0x52c283});_0x1ae1fe['authors']=[],_0x1ae1fe['authorsIds']=[],_0x1ae1fe['id']=this['currentRevision']['id'],this['currentRevision']['_update'](_0x1ae1fe,!0x0),delete _0x1ae1fe['authors'],_0x3eea76['push'](_0x1ae1fe);}_0x9056aa['creatorId']=this['editor']['plugins']['get']('Users')['me']['id'],_0x9056aa['name']=_0x9056aa['name']||null,_0x9056aa['id']=_0x9056aa['id']||_0x391c61(),_0x9056aa={..._0x9056aa,..._0x90bb22};const _0x5951f3=this['addRevisionData'](_0x9056aa);_0x3eea76['push'](_0x9056aa);const _0xbd060b=this['repository']['getIndex'](_0x5951f3);if(0x0!==_0xbd060b){const _0x2edcf2=this['repository']['getRevision'](_0xbd060b-0x1);if(_0x2edcf2['fromVersion']!==_0x52c283){const _0x1f4040=this['_revisionDataBuilder']['getData'](_0x52c283,_0x2edcf2['toVersion']),_0x2c18a5={'id':_0x2edcf2['id'],'diffData':_0x1f4040['diffData'],'authorsIds':_0x1f4040['authorsIds'],'authors':_0x1f4040['authorsIds']['map'](_0x4cf634=>this['editor']['plugins']['get']('Users')['getUser'](_0x4cf634)),'fromVersion':_0x52c283};_0x2edcf2===this['currentRevision']&&(_0x2c18a5['createdAt']=new Date(_0x9056aa['createdAt']['getTime']()+0xa)),_0x2edcf2['_update'](_0x2c18a5,!0x0),delete _0x2c18a5['authors'],_0x3eea76['push'](_0x2c18a5);}}if(this['adapter']){for(const _0x282522 of _0x3eea76)this['_bufferUpdate'](_0x282522['id'],_0x282522,!0x0);this['sendBufferedUpdates']();}return _0x5951f3;}['addRevisionData'](_0xbb9aa){const _0xaee615=this['repository']['createRevision'](_0xbb9aa);return this['adapter']&&_0xaee615['on']('_update',(_0x3a07a2,_0xb2bbf3,_0x2025a9)=>{_0x2025a9||(this['_bufferUpdate'](_0xb2bbf3['id'],_0xb2bbf3,!0x0),this['sendBufferedUpdates']());}),this['repository']['addRevision'](_0xaee615,this['_findInsertionIndex'](_0xaee615)),_0xaee615;}async['getRevisionDocumentData'](_0x4cd6c1){return await this['_utils']['loadRevisionData'](_0x4cd6c1,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x4cd6c1);}async['getRevisionRootsAttributes'](_0x104d37){return await this['_utils']['loadRevisionData'](_0x104d37,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x104d37);}['sendBufferedUpdates'](){if(0x0===this['_bufferedUpdates']['size'])return;if(this['_isPendingUpdate'])return;let _0x43696a=Array['from'](this['_bufferedUpdates']['values']());this['_bufferedUpdates']['clear']();for(let _0x5778a6=0x0;_0x5778a6<_0x43696a['length'];_0x5778a6++){const _0xb75c8c=_0x43696a[_0x5778a6];let _0x4c7bce=!0x1;for(const _0x5b7b7f of Object['keys'](_0xb75c8c))void 0x0===_0xb75c8c[_0x5b7b7f]?delete _0xb75c8c[_0x5b7b7f]:'id'!==_0x5b7b7f&&(_0x4c7bce=!0x0);_0x4c7bce||(_0x43696a[_0x5778a6]=null);}if(_0x43696a=_0x43696a['filter'](_0x4e90cb=>null!==_0x4e90cb),!_0x43696a['length'])return;for(let _0x4a5301=0x0;_0x4a5301<_0x43696a['length'];_0x4a5301++){const _0x34e232=_0x43696a[_0x4a5301];void 0x0!==_0x34e232['fromVersion']&&void 0x0===_0x34e232['toVersion']&&(_0x34e232['toVersion']=this['repository']['getRevision'](_0x34e232['id'])['toVersion']),void 0x0!==_0x34e232['toVersion']&&void 0x0===_0x34e232['fromVersion']&&(_0x34e232['fromVersion']=this['repository']['getRevision'](_0x34e232['id'])['fromVersion']);}const _0x1e4dfc=this['editor']['config']['get']('collaboration.channelId');this['_isPendingUpdate']=!0x0,this['_addPendingAction'](),this['adapter']['updateRevisions'](_0x43696a,_0x1e4dfc)['finally'](()=>{this['_isPendingUpdate']=!0x1;})['then'](_0x51f4dd=>{if(_0x51f4dd){for(const _0x4beb2d of _0x51f4dd)this['setRevisionData']({'id':_0x4beb2d['id'],'createdAt':_0x4beb2d['createdAt']});}this['_removePendingAction'](),this['sendBufferedUpdates']();});}['buildRevisionData']({revision:_0x47f14a=null,from:_0x3960f6=null,to:_0x406c08=null}){_0x3960f6=null!==_0x3960f6?_0x3960f6:_0x47f14a['fromVersion'],_0x406c08=null!==_0x406c08?_0x406c08:_0x47f14a['toVersion'];const _0x4b4f9e=this['_revisionDataBuilder']['getData'](_0x3960f6,_0x406c08),_0x477ec4={'diffData':_0x4b4f9e['diffData'],'authorsIds':_0x4b4f9e['authorsIds'],'fromVersion':_0x3960f6,'toVersion':_0x406c08};if(!_0x47f14a||_0x406c08!==_0x47f14a['toVersion']){const _0x25d206=_0x406c08-0x1,_0x285c9b=this['_source']['history']['getOperation'](_0x25d206);_0x477ec4['createdAt']=_0x285c9b&&_0x285c9b['createdAt']||new Date();}if(this['_loadedStateData']&&_0x3960f6===this['_loadedStateData']['fromVersion']){for(const _0x3c4e0d of this['_loadedStateData']['authors'])_0x477ec4['authorsIds']['includes'](_0x3c4e0d['id'])||_0x477ec4['authorsIds']['push'](_0x3c4e0d['id']);}return _0x477ec4;}['_bufferUpdate'](_0x3c5a1a,_0xd6f2fd,_0x105537){if(this['_bufferedUpdates']['has'](_0x3c5a1a)){const _0xeede0c=this['_bufferedUpdates']['get'](_0x3c5a1a);_0xd6f2fd=_0x105537?{..._0xeede0c,..._0xd6f2fd}:{..._0xd6f2fd,..._0xeede0c};}this['_bufferedUpdates']['set'](_0x3c5a1a,_0xd6f2fd);}['setRevisionData'](_0xd35d5d){const _0x2cc8ac=this['repository']['getRevision'](_0xd35d5d['id']);if(_0xd35d5d['createdAt']&&(_0xd35d5d['createdAt']=new Date(_0xd35d5d['createdAt'])),_0xd35d5d['authorsIds']){const _0x3bc6af=this['editor']['plugins']['get']('Users');_0xd35d5d['authors']=_0xd35d5d['authorsIds']['map'](_0x4c65cf=>_0x3bc6af['getUser'](_0x4c65cf));}_0x2cc8ac['_update'](_0xd35d5d,!0x0);}['_createInitialRevision'](_0x308d75){const _0x5b7e37=this['repository']['getRevision'](this['repository']['length']-0x1);if(_0x5b7e37)this['_initialRevisionId']=_0x5b7e37['id'];else{const _0x34d8f5=!this['editor']['model']['document']['roots']['find'](_0x3de80a=>this['editor']['model']['hasContent'](_0x3de80a)),_0x5dce7a=this['editor']['plugins']['get']('Users')['me']['id'],_0x5bef6d=m(this['editor']['locale'],_0x34d8f5?'Empty\x20document':'Initial\x20revision');this['_makeRevision']({'from':_0x308d75,'to':_0x308d75,'id':this['_initialRevisionId'],'name':_0x5bef6d,'creatorId':_0x5dce7a});}}['_createCurrentRevision'](_0x1aa252){const _0xf5d135=this['_source']['getCurrentRevisionId']();this['currentRevision']=this['repository']['getRevision'](_0xf5d135),this['currentRevision']||(this['currentRevision']=this['_makeRevision']({'from':_0x1aa252,'to':_0x1aa252,'id':_0xf5d135,'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'](_0x1af819,_0x36129b){let _0x17ab9e=this['editor']['config']['get']('initialData'),_0x376289=this['editor']['config']['get']('rootsAttributes');if(void 0x0===_0x17ab9e){_0x17ab9e={};for(const _0x1f32f5 of this['editor']['model']['document']['getRootNames']())_0x17ab9e[_0x1f32f5]='';}if('string'==typeof _0x17ab9e&&(_0x17ab9e={'main':_0x17ab9e}),void 0x0===_0x376289){_0x376289={};for(const _0x3d83b7 of this['editor']['model']['document']['getRootNames']())_0x376289[_0x3d83b7]={};}let _0x44eb44=!0x1;const _0x45a7fa=Object['keys'](_0x17ab9e),_0x1e33ad=Object['keys'](_0x1af819);for(const _0x5c9e11 of _0x45a7fa){if(_0x17ab9e[_0x5c9e11]!==_0x1af819[_0x5c9e11]&&''!==_0x17ab9e[_0x5c9e11]['trim']()){_0x44eb44=!0x0;break;}if(!_0x3c1091(_0x376289[_0x5c9e11],_0x36129b[_0x5c9e11])&&Object['keys'](_0x376289[_0x5c9e11])['length']>0x0){_0x44eb44=!0x0;break;}}_0x44eb44||(_0x44eb44=_0x1e33ad['some'](_0x1cb3b6=>!this['editor']['model']['document']['getRoot'](_0x1cb3b6))),_0x44eb44&&_0x598afb('editor-initial-data-replaced-with-revision-data',{'editorData':_0x17ab9e,'editorRootsAttributes':_0x376289,'revisionData':_0x1af819,'revisionRootsAttributes':_0x36129b}),this['editor']['config']['set']('initialData',_0x1af819),this['editor']['config']['set']('rootsAttributes',_0x36129b);}['_addPendingAction'](){if(!this['_pendingAction']){const _0x4466f7=this['editor']['plugins']['get']('PendingActions');this['_pendingAction']=_0x4466f7['add'](m(this['editor']['locale'],'PENDING_ACTION_REVISION_HISTORY'));}}['_removePendingAction'](){this['_pendingAction']&&(this['editor']['plugins']['get']('PendingActions')['remove'](this['_pendingAction']),this['_pendingAction']=null);}['_findInsertionIndex'](_0x42ab01){const _0x28655=this['repository']['getRevisions']();_0x28655['reverse']();let _0x5e8912=0x0;for(;_0x5e8912<_0x28655['length'];){const _0xf2e4e1=_0x28655[_0x5e8912];if(_0xf2e4e1===this['currentRevision']){_0x5e8912++;continue;}if(_0xf2e4e1['id']===this['_initialRevisionId'])break;const _0xff69e7=_0x42ab01['toVersion']-_0xf2e4e1['toVersion']||_0x42ab01['fromVersion']-_0xf2e4e1['fromVersion'];if(_0xff69e7>0x0)break;if(_0xff69e7<0x0)_0x5e8912++;else{if(!_0x42ab01['creator']&&_0xf2e4e1['creator'])break;if(_0xf2e4e1['creator']||!_0x42ab01['creator']){if(_0x42ab01['createdAt']>_0xf2e4e1['createdAt'])break;_0x5e8912++;}else _0x5e8912++;}}return _0x5e8912;}['_getFromVersion'](_0x4f7d15){const _0x4f0966=this['repository']['getRevisions']();_0x4f0966['reverse'](),_0x4f0966['shift']();const _0x267071=_0x4f0966['find'](_0x187671=>_0x187671['toVersion']<=_0x4f7d15)['toVersion'];return _0x267071<this['_startingVersion']?this['_startingVersion']:_0x267071;}['_makeRevision']({name:_0x14bb2d,from:_0x1a8ecc,to:_0x9d578b,creatorId:_0x312368,id:_0x3dac81}){const _0x25ebac=this['buildRevisionData']({'from':_0x1a8ecc,'to':_0x9d578b});_0x25ebac['name']=_0x14bb2d,_0x25ebac['creatorId']=_0x312368,_0x25ebac['id']=_0x3dac81;const _0x3485b8=this['addRevisionData'](_0x25ebac);return this['adapter']&&this['_bufferUpdate'](_0x25ebac['id'],_0x25ebac,!0x0),_0x3485b8;}['_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(_0x2a3efe){this['editor']=_0x2a3efe,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'](_0x5839db){this['source']=_0x5839db;const _0x1b7042=new Map(),_0x26b468=new Map(),_0x5ced28=this['editor']['model']['document']['roots']['map'](_0x519be7=>_0x519be7['rootName']);for(const _0x6d3174 of _0x5ced28){const _0x50d64f=this['editor']['model']['document']['getRoot'](_0x6d3174),_0x6be1f6=K(_0x50d64f);_0x1b7042['set'](_0x6d3174,_0x6be1f6),_0x26b468['set'](_0x6d3174,Object['fromEntries'](_0x50d64f['getAttributes']()));}const _0x5771a5=Array['from'](this['editor']['model']['markers'])['map'](_0x396bcf=>[_0x396bcf['name'],_0x396bcf['getRange']()]),_0xd2f09b=this['source']['version'];this['_saveMetaData'](_0xd2f09b,_0x1b7042,_0x5771a5,_0x26b468),this['_startingRevisionId']=this['_revisionId'];const _0x460a7f=new Map(),_0x14df30=new Map();for(const _0x35ea17 of _0x5ced28){const _0x381bef=N(_0x35ea17);_0x460a7f['set'](_0x35ea17,_0x381bef),_0x14df30['set'](_0x35ea17,{});}this['_saveMetaData'](Number['NEGATIVE_INFINITY'],_0x460a7f,[],_0x14df30);}['getData'](_0x23d015,_0x5dc334){if(this['_lastFrom']===_0x23d015&&this['_lastTo']<=_0x5dc334)this['_savedMetaData']['size']>0x1&&this['_removeMetaData'](this['_lastTo']),this['_applyOperations'](this['_lastTo'],_0x5dc334,!0x0);else{if(!this['_savedMetaData']['has'](_0x23d015)){const _0x2dac90=this['_getPreviousFrom'](_0x23d015);this['_calculateMetaData'](_0x2dac90,_0x23d015,!0x1);}this['_calculateMetaData'](_0x23d015,_0x5dc334,!0x0);}return this['_lastFrom']=_0x23d015,this['_lastTo']=_0x5dc334,this['_getState']();}['loadState'](_0x536418){if(!this['_savedMetaData']['has'](_0x536418['fromVersion'])){const _0x5085ab=this['_getPreviousFrom'](_0x536418['fromVersion']);this['_calculateMetaData'](_0x5085ab,_0x536418['fromVersion'],!0x1);}this['_calculateMetaData'](_0x536418['fromVersion'],_0x536418['toVersion'],!0x1);const _0x3e676b=this['editor']['plugins']['get']('RevisionHistoryUtils');this['_reset'](),this['_lastFrom']=_0x536418['fromVersion'],this['_lastTo']=_0x536418['toVersion'];for(const _0x2cb078 in _0x536418['diffData']){const _0x19e832=_0x536418['diffData'][_0x2cb078]['attachChange'],_0x325375=_0x115d90(_0x536418['diffData'][_0x2cb078]['attributesBefore'])||{},_0x6b313e=_0x3e676b['_makeModelFromViewString'](_0x536418['diffData'][_0x2cb078]['deletions']);_0x6b313e['rootName']=_0x2cb078,_0x6b313e['_isAttached']=!_0x19e832||!_0x19e832['isAttached'],_0x6b313e['isAttached']=()=>_0x6b313e['_isAttached'],this['_baseRoots']['set'](_0x2cb078,_0x6b313e),this['_baseRootsAttributes']['set'](_0x2cb078,_0x325375),_0x19e832&&this['_touchedRoots']['set'](_0x2cb078,_0x19e832);const _0x2a1ba3=this['_makeIdsRoot'](_0x6b313e);this['_baseIdsRoots']['set'](_0x2cb078,_0x2a1ba3);for(const [_0x3513c6,_0x9ca794]of _0x6b313e['markers']){if(!_0x3513c6['startsWith']('revision:'))continue;const _0x5431a4=_0x3513c6['split'](':')[0x2];for(const _0x4cb936 of _0x9ca794['getWalker']({'singleCharacters':!0x0})){const _0x4c84a4=this['_getVidAttributeName'](_0x4cb936),_0xcd4d24='elementEnd'==_0x4cb936['type']?_0x4cb936['previousPosition']['path']['slice'](0x0,-0x1):_0x4cb936['previousPosition']['path'],_0x402f50=_0x2a1ba3['getNodeByPath'](_0xcd4d24)['getAttribute'](_0x4c84a4);this['_touched']['set'](_0x402f50,{'userId':_0x5431a4});}_0x6b313e['markers']['delete'](_0x3513c6);}}this['_startingRevisionId']=this['_revisionId'];const _0x2719e4=[...Array(this['_revisionId'])['keys']()]['slice'](0x1)['filter'](_0x1ec2d1=>!this['_touched']['has'](_0x1ec2d1));let _0x29b743=0x0;const _0x3e7a34=new Map();for(const _0x519253 in _0x536418['diffData']){const _0x23e1b6=_0x536418['diffData'][_0x519253]['attachChange'],_0x23cc85=_0x115d90(_0x536418['diffData'][_0x519253]['attributesAfter'])||{},_0x52eabe=_0x3e676b['_makeModelFromViewString'](_0x536418['diffData'][_0x519253]['insertions']);_0x52eabe['rootName']=_0x519253,_0x52eabe['_isAttached']=!_0x23e1b6||_0x23e1b6['isAttached'],_0x52eabe['isAttached']=()=>_0x52eabe['_isAttached'],this['_diffRoots']['set'](_0x519253,_0x52eabe),this['_diffRootsAttributes']['set'](_0x519253,_0x23cc85);const _0x45ebc9=this['_makeIdsRoot'](_0x52eabe,Number['NEGATIVE_INFINITY']);this['_idsRoots']['set'](_0x519253,_0x45ebc9),_0x3e7a34['set'](_0x519253,_0x52eabe['isAttached']()?_0x23cc85:{});for(const [_0x365ba4,_0x28856a]of _0x52eabe['markers']){if(!_0x365ba4['startsWith']('revision:'))continue;const _0x5ef38a=_0x365ba4['split'](':')[0x2];for(const _0x8abb6c of _0x28856a['getWalker']({'singleCharacters':!0x0})){const _0xc56669=this['_getVidAttributeName'](_0x8abb6c),_0x337b4c=this['_revisionId']++,_0x1915ba='elementEnd'==_0x8abb6c['type']?_0x8abb6c['previousPosition']['path']['slice'](0x0,-0x1):_0x8abb6c['previousPosition']['path'];_0x45ebc9['getNodeByPath'](_0x1915ba)['_setAttribute'](_0xc56669,_0x337b4c),this['_touched']['set'](_0x337b4c,{'userId':_0x5ef38a});}_0x52eabe['markers']['delete'](_0x365ba4);}for(const _0x4a0982 of this['editor']['model']['createRangeIn'](_0x52eabe)['getWalker']({'singleCharacters':!0x0})){const _0x3a8c2f=this['_getVidAttributeName'](_0x4a0982),_0x205439='elementEnd'==_0x4a0982['type']?_0x4a0982['previousPosition']['path']['slice'](0x0,-0x1):_0x4a0982['previousPosition']['path'],_0x5c55c8=_0x45ebc9['getNodeByPath'](_0x205439);_0x5c55c8['getAttribute'](_0x3a8c2f)>0x0||_0x5c55c8['_setAttribute'](_0x3a8c2f,_0x2719e4[_0x29b743++]);}for(const [_0x4ddf52,_0x9b8b55]of _0x52eabe['markers'])_0x4ddf52['startsWith']('revision:')||this['_markers']['set'](_0x4ddf52,_0x9b8b55);}const {roots:_0x18d152}=this['_savedMetaData']['get'](_0x536418['fromVersion']),{roots:_0x632752}=this['_savedMetaData']['get'](_0x536418['toVersion']),_0x591d27=K(_0x18d152['get']('$graveyard'));this['_baseRoots']['set']('$graveyard',_0x591d27),this['_baseIdsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x591d27,Number['NEGATIVE_INFINITY']));const _0x2d9844=K(_0x632752['get']('$graveyard'));this['_diffRoots']['set']('$graveyard',_0x2d9844),this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x2d9844));const _0x37a2e6=Array['from'](this['_diffRoots'])['map'](([_0x2789f1,_0x1d587b])=>[_0x2789f1,K(_0x1d587b)]);this['_saveMetaData'](this['_lastTo'],_0x37a2e6,this['_markers'],_0x3e7a34);}['reInit'](){this['_reset'](),this['_lastFrom']=-0x1,this['_lastTo']=-0x1,this['_savedMetaData']['clear'](),this['init'](this['source']);}['_saveMetaData'](_0xa9e323,_0x23e6f2,_0xb76c7f,_0xd0f07a){const _0x49c039=new Map(_0x23e6f2),_0x1414bc=new Map(_0x115d90(_0xd0f07a)),_0x232013=new Map();for(const [_0x20f938,_0xa67b84]of _0xb76c7f)_0x232013['set'](_0x20f938,{'start':_0xa67b84['start']['clone'](),'end':_0xa67b84['end']['clone'](),'rootName':_0xa67b84['root']['rootName']});this['_savedMetaData']['set'](_0xa9e323,{'roots':_0x49c039,'markers':_0x232013,'rootsAttributes':_0x1414bc});}['_removeMetaData'](_0x1bf2bc){this['_savedMetaData']['delete'](_0x1bf2bc);}['_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'](_0x34f887,_0x3b8964=null){let _0x321acd=null;_0x34f887['is']('documentFragment')||(_0x321acd=new _0x14fd90(_0x34f887['name'],{'vid_start':null===_0x3b8964?this['_revisionId']++:_0x3b8964++}));const _0xb80a33=[];for(const _0x589a8b of _0x34f887['getChildren']())if(_0x589a8b['is']('element')){_0xb80a33['push'](this['_makeIdsRoot'](_0x589a8b,_0x3b8964));const _0x3144f6=_0xb80a33[_0xb80a33['length']-0x1];null!==_0x3b8964&&(_0x3b8964=_0x3144f6['is']('element','$text')?_0x3144f6['getAttribute']('vid')+0x1:_0x3144f6['getAttribute']('vid_end')+0x1);}else{for(let _0x1c71d6=0x0;_0x1c71d6<_0x589a8b['offsetSize'];_0x1c71d6++)_0xb80a33['push'](new _0x14fd90('$text',{'vid':null===_0x3b8964?this['_revisionId']++:_0x3b8964++}));}if(_0x34f887['is']('documentFragment')){const _0x4a7bc2=N(_0x34f887['rootName']);return _0x4a7bc2['_insertChild'](0x0,_0xb80a33),_0x4a7bc2;}return _0x321acd['_setAttribute']('vid_end',null===_0x3b8964?this['_revisionId']++:_0x3b8964++),_0x321acd['_insertChild'](0x0,_0xb80a33),_0x321acd;}['_calculateMetaData'](_0x4e3296,_0x3f773d,_0x5ad445){this['_reset']();const {roots:_0x28c1e6,markers:_0x1a7b98,rootsAttributes:_0x519dd3}=this['_savedMetaData']['get'](_0x4e3296);this['_baseRoots']=new Map(_0x28c1e6),this['_baseRootsAttributes']=new Map(_0x115d90(_0x519dd3));for(const [_0xa4007b,_0x33560d]of this['_baseRoots'])if('$graveyard'!==_0xa4007b&&(this['_diffRoots']['set'](_0xa4007b,K(_0x33560d)),this['_diffRootsAttributes']=new Map(_0x115d90(_0x519dd3)),_0x5ad445)){const _0x5803c7=this['_revisionId'];this['_idsRoots']['set'](_0xa4007b,this['_makeIdsRoot'](_0x33560d)),this['_baseIdsRoots']['set'](_0xa4007b,this['_makeIdsRoot'](_0x33560d,_0x5803c7));}this['_startingRevisionId']=this['_revisionId'],this['_diffRoots']['set']('$graveyard',K(this['_baseRoots']['get']('$graveyard'))),_0x5ad445&&this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](this['_baseRoots']['get']('$graveyard')));for(const [_0x22fd67,_0x3098fa]of _0x1a7b98){const _0x27bcdd=this['_baseRoots']['get'](_0x3098fa['rootName']),_0x1494f7=this['_diffRoots']['get'](_0x3098fa['rootName']),_0x5b1d79=new _0x23adf7(this['_fixPosition'](_0x3098fa['start'],_0x27bcdd),this['_fixPosition'](_0x3098fa['end'],_0x27bcdd)),_0x193a13=this['_fixRange'](_0x5b1d79,_0x1494f7);_0x27bcdd['markers']['set'](_0x22fd67,_0x5b1d79),this['_markers']['set'](_0x22fd67,_0x193a13);}this['_applyOperations'](_0x4e3296,_0x3f773d,_0x5ad445);}['_applyOperations'](_0x31b7b4,_0x24015e,_0x2f4b1c){for(const _0x36c4ff of this['source']['getOperations'](_0x31b7b4,_0x24015e))this['_handleOperation'](_0x36c4ff,_0x2f4b1c);for(const _0x20d972 of this['_diffRoots']['values']())_0x20d972['markers']['clear']();for(const [_0x486c0a,_0x12e097]of this['_markers']){this['_diffRoots']['get'](_0x12e097['root']['rootName'])['markers']['set'](_0x486c0a,_0x12e097['clone']());}const _0x519ef3=new Map(),_0xbfcecd=new Map();for(const [_0x57c9db,_0x5d702f]of this['_diffRoots'])_0x519ef3['set'](_0x57c9db,K(_0x5d702f)),_0xbfcecd['set'](_0x57c9db,this['_diffRootsAttributes']['get'](_0x57c9db));this['_saveMetaData'](_0x24015e,_0x519ef3,this['_markers'],_0xbfcecd);}['_getPreviousFrom'](_0x35819b){const _0x361fea=Array['from'](this['_savedMetaData']['keys']());_0x361fea['sort']((_0x2b04ac,_0x4d0d6f)=>_0x2b04ac-_0x4d0d6f),_0x361fea['reverse']();for(const _0x152620 of _0x361fea)if(_0x152620<_0x35819b)return _0x152620;return Number['NEGATIVE_INFINITY'];}['_copyMarkers'](_0xf802f0,_0xadd66d){const _0x4c25b1=Array['from'](_0xadd66d['markers'])['map'](([_0x198609,_0x250abd])=>[_0x198609,this['_fixRange'](_0x250abd,_0xf802f0)]);_0xf802f0['markers']=new Map(_0x4c25b1);}['_transformMarkers'](_0x477f0e){for(const _0x1aa6af of this['_markers']['values']()){const _0x1464fe=_0x1aa6af['getTransformedByOperation'](_0x477f0e),_0x5c31b2=_0x23adf7['_createFromRanges'](_0x1464fe);_0x1aa6af['start']=_0x5c31b2['start'],_0x1aa6af['end']=_0x5c31b2['end'];}}['_handleOperation'](_0xe507f7,_0x45e267){if('addRoot'!=_0xe507f7['type']&&'detachRoot'!=_0xe507f7['type']){if('insert'==_0xe507f7['type']){const _0x37db18=_0xe507f7['position']['root']['rootName'];this['_diffRoots']['has'](_0x37db18)||(this['_diffRoots']['set'](_0x37db18,N(_0x37db18,!0x0)),this['_diffRootsAttributes']['set'](_0x37db18,{}),_0x45e267&&this['_idsRoots']['set'](_0x37db18,N(_0x37db18,!0x0)));}else{if('addRootAttribute'==_0xe507f7['type']||'removeRootAttribute'==_0xe507f7['type']||'changeRootAttribute'==_0xe507f7['type'])return void this['_handleRootAttributeOperation'](_0xe507f7);'marker'==_0xe507f7['type']&&this['_handleMarkerOperation'](_0xe507f7);}if('marker'!==_0xe507f7['type']){const _0x261f16=this['_cloneOperation'](_0xe507f7,this['_diffRoots']);_0x261f16['_execute'](),this['_transformMarkers'](_0x261f16);}if(_0x45e267)switch(_0xe507f7['type']){case'insert':this['_handleInsertOperation'](_0xe507f7);break;case'move':case'remove':case'reinsert':this['_handleMoveOperation'](_0xe507f7);break;case'merge':this['_handleMergeOperation'](_0xe507f7);break;case'split':this['_handleSplitOperation'](_0xe507f7);}}else this['_handleRootOperation'](_0xe507f7,_0x45e267);}['_cloneOperation'](_0x3f45cd,_0x3fd0fc){const _0x33318f=_0x3f45cd['clone']();return _0x33318f['_authorId']=_0x3f45cd['_authorId'],this['_fixOperation'](_0x33318f,_0x3fd0fc),_0x33318f;}['_getBaseVids'](_0x4e8aed){return _0x4e8aed['map'](_0x1cabd2=>{const _0x10a17d=this['_getVidAttributeName'](_0x1cabd2);return Number(_0x1cabd2['item']['getAttribute'](_0x10a17d));});}['_generateTape'](_0x28ceb6,_0x4ec0ef){if(_0x28ceb6['is']('element','$text'))_0x4ec0ef['push']({'item':_0x28ceb6,'type':'text'});else{_0x28ceb6['is']('element')&&_0x4ec0ef['push']({'item':_0x28ceb6,'type':'elementStart'});for(const _0x57b3ea of _0x28ceb6['getChildren']())this['_generateTape'](_0x57b3ea,_0x4ec0ef);_0x28ceb6['is']('element')&&_0x4ec0ef['push']({'item':_0x28ceb6,'type':'elementEnd'});}return _0x4ec0ef;}['_getState'](){const _0x432a33=new Map(this['_touched']),_0x5c7515=new Map(_0x432a33),_0x8e5d67=new Map(),_0x1b2e91={'insertions':{},'deletions':{}},_0x1e3d42={'insertions':{},'deletions':{}},_0x3a0bdd=new Map(),_0x4ca651=new Set([...this['_baseRoots']['keys'](),...this['_diffRoots']['keys']()]);_0x4ca651['delete']('$graveyard');for(const _0xd77c7a of _0x4ca651){const _0x1b3f89=this['_diffRoots']['get'](_0xd77c7a)||N(_0xd77c7a,!0x1),_0x4b0345=this['_baseRoots']['get'](_0xd77c7a)||N(_0xd77c7a,!0x1);_0x1b3f89['isAttached']()||_0x4b0345['isAttached']()?(_0x1b2e91['insertions'][_0xd77c7a]=K(_0x1b3f89),_0x1b2e91['deletions'][_0xd77c7a]=K(_0x4b0345),this['_copyMarkers'](_0x1b2e91['deletions'][_0xd77c7a],_0x4b0345),this['_copyMarkers'](_0x1b2e91['insertions'][_0xd77c7a],_0x1b3f89),_0x1e3d42['insertions'][_0xd77c7a]=this['_generateTape'](this['_idsRoots']['get'](_0xd77c7a),[]),_0x1e3d42['deletions'][_0xd77c7a]=this['_generateTape'](this['_baseIdsRoots']['get'](_0xd77c7a)||N(_0xd77c7a,!0x1),[])):_0x4ca651['delete'](_0xd77c7a);}for(const _0xd7cf8b of _0x4ca651){const _0x19fb34=_0x1e3d42['insertions'][_0xd7cf8b];for(const _0x21fc8a of _0x19fb34){const _0x43f2d1=this['_getVidAttributeName'](_0x21fc8a),_0x139d93=_0x21fc8a['item']['getAttribute'](_0x43f2d1);_0x5c7515['delete'](_0x139d93),_0x139d93>=this['_startingRevisionId']&&_0x8e5d67['set'](_0x139d93,_0x432a33['get'](_0x139d93));}}for(const _0x518004 of _0x4ca651){const _0x44abbb=_0x1e3d42['insertions'][_0x518004],_0x22a494=this['_getBaseVids'](_0x1e3d42['deletions'][_0x518004]);let _0x324c11=0x0;for(const _0x2f1432 of _0x44abbb){const _0x2e2021=this['_getVidAttributeName'](_0x2f1432),_0x1fe7c9=_0x2f1432['item']['getAttribute'](_0x2e2021);if(!_0x8e5d67['has'](_0x1fe7c9)&&!_0x3a0bdd['has'](_0x1fe7c9)){if(_0x5c7515['has'](_0x1fe7c9))_0x324c11++;else{if(_0x1fe7c9!=_0x22a494[_0x324c11]){const _0x78f7ed=_0x432a33['get'](_0x1fe7c9)||_0x432a33['get'](_0x22a494[_0x324c11]);for(;_0x1fe7c9!=_0x22a494[_0x324c11];)_0x5c7515['has'](_0x22a494[_0x324c11])||(_0x3a0bdd['set'](_0x22a494[_0x324c11],_0x78f7ed),_0x432a33['set'](_0x22a494[_0x324c11],_0x78f7ed)),_0x324c11++;}_0x324c11++;}}}}for(const _0x2c8764 of _0x4ca651){const _0x5b8df7=_0x1e3d42['insertions'][_0x2c8764];for(const _0x491e9d of _0x5b8df7){const _0x247072=this['_getVidAttributeName'](_0x491e9d),_0x185b11=_0x491e9d['item']['getAttribute'](_0x247072);if(_0x3a0bdd['has'](_0x185b11)){const _0x329d04=_0x3a0bdd['get'](_0x185b11);_0x5c7515['has'](_0x185b11)||_0x5c7515['set'](_0x185b11,{..._0x329d04}),_0x8e5d67['set'](_0x185b11,{..._0x329d04});}}}for(const _0x28d944 of _0x5c7515['keys']())_0x28d944>=this['_startingRevisionId']&&_0x5c7515['delete'](_0x28d944);const _0x4788b6=new Map();for(const _0x1b6099 of _0x4ca651){let _0x50826f=_0x1e3d42['insertions'][_0x1b6099];for(const _0x56b81e of _0x50826f)if(_0x56b81e['item']['is']('element','tableCell')){const _0x2c768b=this['_getVidAttributeName'](_0x56b81e),_0x5e384a=_0x56b81e['item']['getAttribute'](_0x2c768b);if(_0x8e5d67['has'](_0x5e384a)){const _0x399d40=_0x56b81e['item']['parent']['parent']['getAttribute']('vid_start'),_0x5c6feb=_0x4788b6['get'](_0x399d40)||new Set();_0x5c6feb['add'](_0x8e5d67['get'](_0x5e384a)['userId']),_0x4788b6['set'](_0x399d40,_0x5c6feb);}}_0x50826f=_0x1e3d42['deletions'][_0x1b6099];for(const _0x460039 of _0x50826f)if(_0x460039['item']['is']('element','tableCell')){const _0x34b52d=this['_getVidAttributeName'](_0x460039),_0x3c09a5=_0x460039['item']['getAttribute'](_0x34b52d);if(_0x5c7515['has'](_0x3c09a5)){const _0xbfbb35=_0x460039['item']['parent']['parent']['getAttribute']('vid_start'),_0x78dd32=_0x4788b6['get'](_0xbfbb35)||new Set();_0x78dd32['add'](_0x5c7515['get'](_0x3c09a5)['userId']),_0x4788b6['set'](_0xbfbb35,_0x78dd32);}}for(const _0xeaed5b of _0x4788b6['keys']())(_0x8e5d67['has'](_0xeaed5b)||_0x5c7515['has'](_0xeaed5b))&&_0x4788b6['delete'](_0xeaed5b);}for(const _0x54dd0e of _0x4ca651){const _0x5cd540=_0x1e3d42['insertions'][_0x54dd0e];let _0x152312=null,_0x22d934=null;for(const _0x3c60ad of _0x5cd540){const _0x56d463=this['_getVidAttributeName'](_0x3c60ad),_0x5a0c94=_0x3c60ad['item']['getAttribute'](_0x56d463),_0x33e267=_0x4788b6['get'](_0x5a0c94);_0x33e267&&'elementStart'==_0x3c60ad['type']&&(_0x152312=Array['from'](_0x33e267)[0x0],_0x22d934=_0x3c60ad['item']['getAttribute']('vid_end')),_0x152312&&(_0x5c7515['set'](_0x5a0c94,{'userId':_0x152312}),_0x8e5d67['set'](_0x5a0c94,{'userId':_0x152312})),_0x5a0c94==_0x22d934&&(_0x152312=null,_0x22d934=null);}}const _0x57f015={},_0x2143f3=new Set();for(const _0x4e619c of _0x4ca651){const _0x27a692=_0x1b2e91['deletions'][_0x4e619c],_0xdfc591=_0x1b2e91['insertions'][_0x4e619c];for(const {userId:_0x9bd184}of this['_touchedMarkers']['values']())null!==_0x9bd184&&_0x2143f3['add'](_0x9bd184);for(const {userId:_0x335cf5}of this['_touchedRoots']['values']())null!==_0x335cf5&&_0x2143f3['add'](_0x335cf5);this['_markChanges'](_0xdfc591,_0x1e3d42['insertions'][_0x4e619c],_0x8e5d67,'insertion',_0x2143f3),this['_markChanges'](_0x27a692,_0x1e3d42['deletions'][_0x4e619c],_0x5c7515,'deletion',_0x2143f3),_0x57f015[_0x4e619c]={'insertions':this['_prepareViewToSave'](_0xdfc591),'deletions':this['_prepareViewToSave'](_0x27a692),'attachChange':this['_touchedRoots']['get'](_0x4e619c)||null,'attributesBefore':_0x115d90(this['_baseRootsAttributes']['get'](_0x4e619c))||{},'attributesAfter':_0x115d90(this['_diffRootsAttributes']['get'](_0x4e619c))};}return{'diffData':_0x57f015,'authorsIds':Array['from'](_0x2143f3)};}['_processRootBeforeSave'](_0x5c03c5){for(const [,_0x1bba4b]of _0x5c03c5['markers']){const _0x28bc8b=_0x1bba4b['start']['getAncestors']()['filter'](_0x508c6a=>'tableCell'==_0x508c6a['name']);for(const _0x135fa4 of _0x28bc8b)0x1==_0x135fa4['childCount']&&_0x135fa4['getChild'](0x0)['is']('element','paragraph')&&_0x135fa4['getChild'](0x0)['_setAttribute']('keepParagraph',!0x0);}}['_prepareViewToSave'](_0x55e39c){this['_processRootBeforeSave'](_0x55e39c);const _0x4f513b=this['editor']['data']['toView'](_0x55e39c,{}),_0x2f6955=Array['from'](_0x4f513b['getChildren']())['map'](_0x1f9855=>this['_getViewJson'](_0x1f9855));return JSON['stringify'](_0x2f6955);}['_getViewJson'](_0x359629){if(_0x359629['is']('$text'))return _0x359629['data'];{const _0xfa0624=this['editor']['plugins']['get']('RevisionHistoryUtils'),_0x44ceec=_0x359629,_0x39f754=this['editor']['data']['htmlProcessor']['domConverter'],_0x1944f7={'type':_0xfa0624['_getTypeCharForViewElement'](_0x44ceec),'name':_0x44ceec['name'],'attributes':Array['from'](_0x44ceec['getAttributes']()),'children':Array['from'](_0x44ceec['getChildren']())['map'](_0x19462c=>this['_getViewJson'](_0x19462c))};if(_0x359629['is']('uiElement')&&'$comment'!=_0x359629['name']){const _0x3152bb=_0x359629['render'](_0x39f754['domDocument'],_0x39f754);_0x1944f7['children']['push'](_0x3152bb['outerHTML']);}else{if(_0x359629['is']('rawElement')){const _0xa4222b=_0x39f754['domDocument']['createElement'](_0x44ceec['name']);_0x359629['render'](_0xa4222b,_0x39f754),_0x1944f7['children']['push'](_0xa4222b['innerHTML']);}}const _0x268174=Array['from'](_0x44ceec['getCustomProperties']());_0x268174['length']>0x0&&(_0x1944f7['customProperties']=_0x268174);const _0x50c2ab=_0x44ceec['getFillerOffset']();return null!==_0x50c2ab&&(_0x1944f7['fillerOffset']=_0x50c2ab),_0x1944f7;}}['_markChanges'](_0x240eff,_0x2ac969,_0x50a245,_0x273079,_0x327d14){let _0x35ad93=null,_0x32bcca=null,_0x3a48ca=0x0;const _0xef4946=this['editor']['model'];for(let _0x2b2305=0x0;_0x2b2305<_0x2ac969['length'];_0x2b2305++){const _0xbce2b3=this['_getVidAttributeName'](_0x2ac969[_0x2b2305]),_0x401f6f=_0x2ac969[_0x2b2305]['item']['getAttribute'](_0xbce2b3),_0x3dca3f=_0x50a245['get'](_0x401f6f),_0x4c6c5f=_0x2b2305==_0x2ac969['length']-0x1;(!_0x35ad93&&_0x3dca3f&&(_0x35ad93=_0x3dca3f,_0x32bcca=_0x2ac969[_0x2b2305]),_0x35ad93&&(!_0x3dca3f||_0x3dca3f['userId']!=_0x35ad93['userId']))&&(_0x34bf84(_0x3dca3f,P(_0x32bcca,_0x240eff,_0xef4946),P(_0x2ac969[_0x2b2305],_0x240eff,_0xef4946)),_0x35ad93=_0x3dca3f||null,_0x32bcca=_0x3dca3f?_0x2ac969[_0x2b2305]:null),_0x35ad93&&_0x4c6c5f&&_0x34bf84(_0x3dca3f,P(_0x32bcca,_0x240eff,_0xef4946),V(_0x2ac969[_0x2b2305],_0x240eff,_0xef4946));}function _0x34bf84(_0x21d8fb,_0x1d0cba,_0x4b5cd8){const _0x3b7fd4=_0x35ad93['userId'],_0x4c87e7='revision:'+_0x273079+':'+_0x3b7fd4+':'+_0x3a48ca++,_0x3966b1=_0xef4946['createRange'](_0x1d0cba,_0x4b5cd8);_0x240eff['markers']['set'](_0x4c87e7,_0x3966b1),null!==_0x3b7fd4&&_0x327d14['add'](_0x3b7fd4);}}['_getVidAttributeName'](_0x739673){switch(_0x739673['type']){case'elementStart':return'vid_start';case'elementEnd':return'vid_end';default:return'vid';}}['_fixOperation'](_0x430c31,_0x14fac9){_0x430c31['baseVersion']=null;for(const _0x1df86d in _0x430c31){const _0x51a33e=_0x430c31[_0x1df86d];if(_0x51a33e instanceof _0x3ee28f){const _0x45dc76=_0x14fac9['get'](_0x51a33e['root']['rootName']);_0x430c31[_0x1df86d]=this['_fixPosition'](_0x51a33e,_0x45dc76);}if(_0x51a33e instanceof _0x23adf7){const _0x5333a5=_0x14fac9['get'](_0x51a33e['root']['rootName']);_0x430c31[_0x1df86d]=this['_fixRange'](_0x51a33e,_0x5333a5);}'root'===_0x1df86d&&(_0x430c31['root']=_0x14fac9['get'](_0x430c31['root']['rootName']));}}['_fixRange'](_0x2f0253,_0x31d100){return this['editor']['model']['createRange'](this['_fixPosition'](_0x2f0253['start'],_0x31d100),this['_fixPosition'](_0x2f0253['end'],_0x31d100));}['_fixPosition'](_0x1f5408,_0x417f58){return this['editor']['model']['createPositionFromPath'](_0x417f58,_0x1f5408['path'],_0x1f5408['stickiness']);}['_handleInsertOperation'](_0x1c7ad8){const _0x1ea10c=this['_idsRoots']['get'](_0x1c7ad8['position']['root']['rootName']),_0x36a8dd=this['_fixPosition'](_0x1c7ad8['position'],_0x1ea10c),_0x415c4a=null===_0x1c7ad8['_authorId']?null:_0x1c7ad8['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x393822=_0x36a8dd['parent'],_0x239288=this['_revisionId'],_0x20835a=[];for(const _0x4741a1 of _0x1c7ad8['nodes'])if(_0x4741a1['is']('element'))_0x20835a['push'](this['_makeIdsRoot'](_0x4741a1));else{for(let _0x5db889=0x0;_0x5db889<_0x4741a1['offsetSize'];_0x5db889++)_0x20835a['push'](new _0x14fd90('$text',{'vid':this['_revisionId']++}));}const _0x1d6a01=this['_revisionId'];for(let _0x1d998c=_0x239288;_0x1d998c<_0x1d6a01;_0x1d998c++)this['_touched']['set'](_0x1d998c,{'userId':_0x415c4a});_0x393822['_insertChild'](_0x36a8dd['offset'],_0x20835a);}['_handleMoveOperation'](_0x1ab0cb){(_0x1ab0cb=this['_cloneOperation'](_0x1ab0cb,this['_idsRoots']))['_execute']();const _0x4e91f5=null===_0x1ab0cb['_authorId']?null:_0x1ab0cb['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x12f587=_0x1ab0cb['getMovedRangeStart'](),_0x40babc=_0x12f587['parent'],_0xf003ca=_0x12f587['offset'];!function _0x382f27(_0x196021,_0x5541b2,_0x3a43c2,_0x277af3){for(let _0x532dd1=_0x3a43c2;_0x532dd1<_0x277af3;_0x532dd1++){const _0x27b745=_0x5541b2['getChild'](_0x532dd1);_0x27b745['is']('element','$text')?_0x196021['set'](_0x27b745['getAttribute']('vid'),{'userId':_0x4e91f5}):(_0x196021['set'](_0x27b745['getAttribute']('vid_start'),{'userId':_0x4e91f5}),_0x382f27(_0x196021,_0x27b745,0x0,_0x27b745['childCount']),_0x196021['set'](_0x27b745['getAttribute']('vid_end'),{'userId':_0x4e91f5}));}}(this['_touched'],_0x40babc,_0xf003ca,_0xf003ca+_0x1ab0cb['howMany']);}['_handleMergeOperation'](_0x343ec0){const _0x87f49a=null===(_0x343ec0=this['_cloneOperation'](_0x343ec0,this['_idsRoots']))['_authorId']?null:_0x343ec0['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x348170=_0x343ec0['targetPosition']['parent'],_0x121406=_0x343ec0['sourcePosition']['parent'],_0x400185=_0x348170['getAttribute']('vid_end'),_0x5d3c84=_0x121406['getAttribute']('vid_start');_0x348170['_setAttribute']('vid_end',_0x121406['getAttribute']('vid_end')),_0x121406['_setAttribute']('vid_end',_0x400185),this['_touched']['set'](_0x5d3c84,{'userId':_0x87f49a}),this['_touched']['set'](_0x400185,{'userId':_0x87f49a}),_0x343ec0['_execute']();}['_handleSplitOperation'](_0x50b693){const _0x11e465=null===(_0x50b693=this['_cloneOperation'](_0x50b693,this['_idsRoots']))['_authorId']?null:_0x50b693['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x14fded=_0x50b693['graveyardPosition'],_0x2395e8=_0x50b693['splitPosition']['parent'];_0x50b693['_execute']();const _0x1c0872=_0x2395e8['getAttribute']('vid_end'),_0x4fc6e4=_0x50b693['insertionPosition']['nodeAfter'];if(_0x14fded){const _0x38bf27=_0x4fc6e4['getAttribute']('vid_end'),_0x72316e=_0x2395e8['getAttribute']('vid_end');_0x2395e8['_setAttribute']('vid_end',_0x38bf27),_0x4fc6e4['_setAttribute']('vid_end',_0x72316e),this['_touched']['set'](_0x2395e8['getAttribute']('vid_end'),{'userId':_0x11e465}),this['_touched']['set'](_0x4fc6e4['getAttribute']('vid_start'),{'userId':_0x11e465});}else{const _0x332970=this['_revisionId']++,_0x52d56b=this['_revisionId']++;_0x2395e8['_setAttribute']('vid_end',_0x332970),_0x4fc6e4['_setAttribute']('vid_start',_0x52d56b),_0x4fc6e4['_setAttribute']('vid_end',_0x1c0872),this['_touched']['set'](_0x332970,{'userId':_0x11e465}),this['_touched']['set'](_0x52d56b,{'userId':_0x11e465});}}['_handleMarkerOperation'](_0x2def22){if(!_0x2def22['affectsData'])return;const _0x431cc8=(_0x2def22=this['_cloneOperation'](_0x2def22,this['_diffRoots']))['oldRange']?_0x2def22['oldRange']['root']:null,_0x3d01f0=_0x2def22['newRange']?_0x2def22['newRange']['root']:null;_0x431cc8&&this['_markers']['delete'](_0x2def22['name']),_0x3d01f0&&this['_markers']['set'](_0x2def22['name'],_0x2def22['newRange']['clone']());const _0xdbc407=null===_0x2def22['_authorId']?null:_0x2def22['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x5c5d92=_0x2def22['name'];if(!this['_touchedMarkers']['has'](_0x5c5d92))return void this['_touchedMarkers']['set'](_0x5c5d92,{'range':_0x2def22['oldRange'],'userId':_0xdbc407});const _0x256864=this['_touchedMarkers']['get'](_0x5c5d92),_0x5bb95b=_0x256864['range'],_0x4c2278=_0x2def22['newRange'];null==_0x5bb95b&&null==_0x4c2278||_0x5bb95b&&_0x4c2278&&_0x5bb95b['isEqual'](_0x4c2278)?this['_touchedMarkers']['delete'](_0x2def22['name']):_0x256864['userId']=_0xdbc407;}['_handleRootOperation'](_0x12dcec,_0x5134e9){this['_diffRoots']['has'](_0x12dcec['rootName'])?this['_diffRoots']['get'](_0x12dcec['rootName'])['_isAttached']=_0x12dcec['isAdd']:(this['_diffRoots']['set'](_0x12dcec['rootName'],N(_0x12dcec['rootName'],!0x0)),this['_diffRootsAttributes']['set'](_0x12dcec['rootName'],{}),_0x5134e9&&this['_idsRoots']['set'](_0x12dcec['rootName'],N(_0x12dcec['rootName'],!0x0)));const _0x3ace48=null===_0x12dcec['_authorId']?null:_0x12dcec['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x18b7ec=this['_touchedRoots']['get'](_0x12dcec['rootName']);_0x18b7ec&&_0x18b7ec['userId']===_0x3ace48?this['_touchedRoots']['delete'](_0x12dcec['rootName']):this['_touchedRoots']['set'](_0x12dcec['rootName'],{'userId':_0x3ace48,'isAttached':_0x12dcec['isAdd']});}['_handleRootAttributeOperation'](_0x4349ed){const _0x336586=this['_diffRootsAttributes']['get'](_0x4349ed['root']['rootName']);null===_0x4349ed['newValue']?delete _0x336586[_0x4349ed['key']]:_0x336586[_0x4349ed['key']]=_0x4349ed['newValue'];}}function K(_0x48f95a){const _0xad40b1=N(_0x48f95a['rootName'],_0x48f95a['isAttached']());for(const _0x3a5ce8 of _0x48f95a['getChildren']()){const _0x25b523=_0x3a5ce8['_clone'](!0x0);_0xad40b1['_appendChild'](_0x25b523);}return _0xad40b1;}function N(_0x1b684e,_0x270af3=!0x0){const _0x5c7c00=new _0xf3d172();return _0x5c7c00['rootName']=_0x1b684e,_0x5c7c00['_isAttached']=_0x270af3,_0x5c7c00['isAttached']=()=>_0x5c7c00['_isAttached'],_0x5c7c00;}function P(_0x2ae5d7,_0x3a0172,_0x3db48b){const _0x59c1ce='elementEnd'==_0x2ae5d7['type']?_0x3db48b['createPositionAt'](_0x2ae5d7['item'],'end'):_0x3db48b['createPositionBefore'](_0x2ae5d7['item']);return _0x3db48b['createPositionFromPath'](_0x3a0172,_0x59c1ce['path'],_0x59c1ce['stickiness']);}function V(_0x1b9a07,_0x4b90c7,_0x176ed9){const _0x1bf080='elementStart'==_0x1b9a07['type']?_0x176ed9['createPositionAt'](_0x1b9a07['item'],0x0):_0x176ed9['createPositionAfter'](_0x1b9a07['item']);return _0x176ed9['createPositionFromPath'](_0x4b90c7,_0x1bf080['path'],_0x1bf080['stickiness']);}class he extends/* #__PURE__ -- @preserve */
25
+ _0x569437(_0x5f53a2){['focusTracker'];['keystrokes'];['revisionNameInputView'];constructor(_0x349b3e,_0x289b5d){super(_0x349b3e),this['focusTracker']=new _0x158451(),this['keystrokes']=new _0x2465a1(),this['set']('revisionNameInputValue',''),this['revisionNameInputView']=this['_createRevisionNameInput'](_0x289b5d),this['setTemplate']({'tag':'form','attributes':{'class':['ck','ck-revision-history-save-revision-form','ck-responsive-form'],'tabindex':'-1'},'children':[this['revisionNameInputView']]}),this['initializeCssTransitionDisablerMixin']();}['render'](){super['render'](),_0x77e4ed({'view':this}),this['focusTracker']['add'](this['revisionNameInputView']['element']),this['keystrokes']['listenTo'](this['element']);const _0x4a5b21=_0x47b6e8=>_0x47b6e8['stopPropagation']();this['keystrokes']['set']('arrowright',_0x4a5b21),this['keystrokes']['set']('arrowleft',_0x4a5b21),this['keystrokes']['set']('arrowup',_0x4a5b21),this['keystrokes']['set']('arrowdown',_0x4a5b21);}['focus'](){this['revisionNameInputView']['focus']();}get['revisionName'](){return this['revisionNameInputView']['fieldView']['element']['value']['trim']();}set['revisionName'](_0x11355c){this['revisionNameInputView']['fieldView']['element']['value']=_0x11355c['trim']();}['reset'](){this['revisionNameInputView']['fieldView']['element']['value']='',this['revisionNameInputView']['errorText']=null;}['_createRevisionNameInput'](_0x5147a0){const _0x18ec6b=new et(this['locale'],ti),_0x16a610=_0x18ec6b['fieldView'];_0x16a610['extendTemplate']({'attributes':{'maxlength':'220'}});let _0x1a7305=m(this['locale'],'Name\x20of\x20the\x20revision');return!_0x5147a0&&(_0x1a7305+='\x20('+m(this['locale'],'optional')+')'),(_0x18ec6b['label']=_0x1a7305,_0x16a610['on']('input',()=>{this['revisionNameInputValue']=_0x16a610['element']['value']['trim']();}),_0x18ec6b);}}class l extends _0x439397{static get['pluginName'](){return'RevisionHistoryUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[h];}['_saveRevisionFormView'];['init'](){const _0x5066a7=this['editor'],_0x1662b0=_0x5066a7['plugins']['get']('RevisionTracker');_0x5066a7['ui']['componentFactory']['add']('revisionHistory',_0x4efd24=>{const _0x4bf2eb=_0x488b40(_0x4efd24),_0x2c6014=_0x4bf2eb['panelView']['children'],_0x2593ff=new _0x177957(_0x4efd24),_0x561b13=new _0x3e754b(_0x4efd24),_0x2dcbb5=this['_createSaveRevisionButton'](_0x5108a7),_0x498965=new _0x3e754b(_0x4efd24),_0x19f8e9=this['_createOpenRevisionButton'](_0x5108a7);return _0x4bf2eb['bind']('isEnabled')['to'](_0x1662b0,'isReady',_0x1662b0,'isEnabled',_0x5066a7,'isReadOnly',(_0x2e5e45,_0x5c8127,_0x632cd5)=>_0x2e5e45&&_0x5c8127&&!_0x632cd5),_0x4bf2eb['buttonView']['set']({'icon':_0x5d69e0,'label':m(_0x4efd24,'Revision\x20history'),'tooltip':!0x0}),_0x2dcbb5['set']({'withText':!0x0,'role':'menuitem'}),_0x19f8e9['set']({'withText':!0x0,'role':'menuitem'}),this['listenTo'](_0x19f8e9,'execute',()=>{_0x4bf2eb['isOpen']=!0x1,_0x5066a7['editing']['view']['focus']();},{'priority':'low'}),_0x561b13['children']['add'](_0x2dcbb5),_0x498965['children']['add'](_0x19f8e9),_0x2593ff['role']='menu',_0x2593ff['items']['addMany']([_0x561b13,_0x498965]),_0x2c6014['add'](_0x2593ff),_0x4bf2eb;}),_0x5066a7['ui']['componentFactory']['add']('menuBar:revisionHistory',()=>this['_registerMenuComponent']());}['_registerMenuComponent'](){const _0x44a103=this['editor'],_0x13cfc2=_0x44a103['locale'],_0x2a221a=_0x44a103['plugins']['get']('RevisionTracker'),_0x440ab7=new _0x199c1c(_0x13cfc2),_0x2ff602=new _0x4b9c74(_0x13cfc2);_0x440ab7['bind']('isEnabled')['to'](_0x2a221a,'isReady',_0x2a221a,'isEnabled',_0x44a103,'isReadOnly',(_0x3835b2,_0x5b4161,_0x5ec299)=>_0x3835b2&&_0x5b4161&&!_0x5ec299),_0x440ab7['buttonView']['set']({'icon':_0x5d69e0,'label':m(_0x13cfc2,'Revision\x20history')});const _0x952e1f=new _0xaee688(_0x13cfc2,_0x440ab7),_0x29079e=this['_createSaveRevisionButton'](_0x3ce466);_0x29079e['delegate']('execute')['to'](_0x440ab7),_0x952e1f['children']['add'](_0x29079e),_0x2ff602['items']['add'](_0x952e1f);const _0x245220=new _0xaee688(_0x13cfc2,_0x440ab7),_0xdf3dcc=this['_createOpenRevisionButton'](_0x3ce466);return _0xdf3dcc['delegate']('execute')['to'](_0x440ab7),_0x245220['children']['add'](_0xdf3dcc),_0x2ff602['items']['add'](_0x245220),_0x440ab7['panelView']['children']['add'](_0x2ff602),_0x440ab7;}['_createSaveRevisionButton'](_0x58fd4d){const _0x5536c9=this['editor'],_0x48cb4d=_0x5536c9['plugins']['get']('RevisionTracker'),_0x5772a4=new _0x58fd4d(_0x5536c9['locale']);return _0x5772a4['set']({'label':m(_0x5536c9['locale'],'Save\x20current\x20revision')}),_0x5772a4['bind']('isEnabled')['to'](_0x48cb4d,'isReady',_0x48cb4d,'isEnabled',_0x5536c9,'isReadOnly',(_0x571eca,_0x5adafd,_0x34c7da)=>_0x571eca&&_0x5adafd&&!_0x34c7da),this['listenTo'](_0x5772a4,'execute',()=>{this['_showDialog']();}),_0x5772a4;}['_createOpenRevisionButton'](_0x27dc9d){const _0x1c0e25=this['editor'],_0x314bd3=_0x1c0e25['plugins']['get']('RevisionTracker'),_0x99bb60=new _0x27dc9d(_0x1c0e25['locale']);return _0x99bb60['set']({'label':m(_0x1c0e25['locale'],'Open\x20revision\x20history')}),_0x99bb60['bind']('isEnabled')['to'](_0x314bd3,'isReady',_0x1c0e25,'isReadOnly',(_0x3d0119,_0x8c72d9)=>_0x3d0119&&!_0x8c72d9),this['listenTo'](_0x99bb60,'execute',()=>{_0x1c0e25['config']['get']('revisionHistory')['showRevisionViewerCallback']();}),_0x99bb60;}['_showDialog'](){const _0x240e9d=this['editor'],_0x1f7655=_0x240e9d['locale'],_0x4072f9=_0x240e9d['plugins']['get']('Dialog'),_0x24c03b=_0x240e9d['plugins']['get']('RevisionTracker');function _0x365f17(_0x4e4159){_0x240e9d['config']['get']('revisionHistory.requireRevisionName')&&''===_0x4e4159['revisionName']?_0x4e4159['revisionNameInputView']['errorText']=m(_0x1f7655,'The\x20revision\x20name\x20cannot\x20be\x20empty.'):(_0x240e9d['plugins']['get'](h)['saveRevision']({'name':_0x4e4159['revisionName']}),_0x4072f9['hide']());}this['_saveRevisionFormView']||(this['_createSaveRevisionFormView'](),this['_saveRevisionFormView']['on']('submit',()=>_0x365f17(this['_saveRevisionFormView']))),this['_saveRevisionFormView']['reset'](),_0x4072f9['show']({'id':'revisionSave','title':m(_0x1f7655,'Save\x20current\x20revision'),'isModal':!0x0,'content':this['_saveRevisionFormView'],'actionButtons':[{'label':m(_0x240e9d['locale'],'Cancel'),'withText':!0x0,'onExecute':()=>_0x4072f9['hide']()},{'label':m(_0x240e9d['locale'],'Accept'),'class':'ck-button-action','withText':!0x0,'onCreate'(_0x5a11f4){_0x5a11f4['bind']('isEnabled')['to'](_0x24c03b,'isReady',_0x24c03b,'isEnabled',_0x240e9d,'isReadOnly',(_0x2ac72d,_0x53694e,_0x2afcfd)=>_0x2ac72d&&_0x53694e&&!_0x2afcfd);},'onExecute':()=>_0x365f17(this['_saveRevisionFormView'])}]});}['_createSaveRevisionFormView'](){const _0x1a8743=this['editor'],_0x5dfb1a=_0x1a8743['locale'];this['_saveRevisionFormView']=new he(_0x5dfb1a,_0x1a8743['config']['get']('revisionHistory.requireRevisionName')),this['_saveRevisionFormView']['render']();}}class z extends _0x5f53a2{['changeId'];['_model'];constructor(_0x2d81f3,_0x340eca){super(_0x2d81f3),this['_model']=_0x340eca,this['changeId']=_0x340eca['id'];const _0x10fda3=this['bindTemplate'],_0x3b5145=m(_0x2d81f3,_0x340eca['data']['isSuggestion']?'Suggested\x20by':'add'==_0x340eca['type']?'Added\x20by':'Removed\x20by');this['set']('type',_0x340eca['type']),this['setTemplate']({'tag':'div','attributes':{'class':['ck-annotation','ck-revision-change',_0x10fda3['to']('type',_0x4a46a1=>'ck-revision-change__'+_0x4a46a1)],'tabindex':-0x1},'children':[{'tag':'span','children':[{'tag':'span','attributes':{'class':['ck-revision-change__label']},'children':[{'text':_0x3b5145}]},{'text':'\x20'+_0x340eca['author']['name']}]}]});}['focus'](){this['element']['focus']();}}class G extends/* #__PURE__ -- @preserve */
26
+ _0xb6d8a(){['id'];['author'];['type'];['data'];['rootName'];constructor(_0x12ebac){super(),this['id']=_0x12ebac['id']||_0x391c61(),this['author']=_0x12ebac['author'],this['type']=_0x12ebac['type'],this['data']=_0x12ebac['data']||{},this['rootName']=_0x12ebac['rootName'],this['set']('createdAt',_0x12ebac['createdAt']);}['toJSON'](){return{'id':this['id'],'authorId':this['author']['id'],'type':this['type'],'data':this['data'],'createdAt':this['createdAt']};}}class J{['newRevisionId'];['oldRevisionId'];['changes'];constructor(_0x1812b2,_0xc6f041){this['newRevisionId']=_0x1812b2,this['oldRevisionId']=_0xc6f041,this['changes']=new _0x480dd0();}['_setChanges'](_0x48b181){for(const _0x15df86 of _0x48b181)this['changes']['add'](_0x15df86);}}class u extends _0x439397{['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[_0x153f01,_0x9a6d6b,S,$];}constructor(_0x3e284e){super(_0x3e284e),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',(_0x4a4134,_0x2831fe,_0x37a712)=>{this['activeChange']=null,this['activeView']=null,this['editor']['editing']['view']['change'](_0x158040=>{for(const _0x1d7fcf of this['editor']['editing']['view']['document']['roots'])_0x37a712?_0x158040['removeClass']('ck-editor__editable__overlay',_0x1d7fcf):_0x158040['addClass']('ck-editor__editable__overlay',_0x1d7fcf);});}),this['bind']('isNavigationMode')['to'](this,'activeChange',_0x5989c7=>null!==_0x5989c7),this['bind']('currentChangeNumber')['to'](this,'isReady',this,'diff',this,'activeChange',(_0x2792b1,_0x4d60d8,_0x5d9c2e)=>_0x2792b1&&_0x5d9c2e?_0x4d60d8['changes']['getIndex'](_0x5d9c2e):0x0),this['bind']('numberOfChanges')['to'](this,'isReady',this,'diff',(_0x42120f,_0xb4afba)=>_0x42120f?_0xb4afba['changes']['length']:0x0),this['_changeView']=null,this['_changeIdToChange']=new Map(),this['_balloon']=this['editor']['plugins']['get'](_0x9a6d6b);}['init'](){const _0x12e484=this['editor'],_0x115b6e=new rt(_0x12e484,{'direction':'backward'}),_0x26d8fd=new rt(_0x12e484,{'direction':'forward'});(_0x12e484['commands']['add']('showPreviousChange',_0x115b6e),_0x12e484['commands']['add']('showNextChange',_0x26d8fd),_0x12e484['commands']['add']('restoreRevision',new nt(_0x12e484)),this['on']('change:numberOfChanges',()=>{_0x115b6e['refresh'](),_0x26d8fd['refresh']();}),this['_setConversion'](),this['_initInteractions'](),_0x12e484['enableReadOnlyMode']('revision-viewer'),_0x12e484['plugins']['has']('WidgetToolbarRepository'))&&_0x12e484['plugins']['get']('WidgetToolbarRepository')['forceDisabled']('revision-viewer');}async['getRevisionDocumentData'](_0x16ec8f){return await this['_utils']['loadRevisionData'](_0x16ec8f,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x16ec8f);}async['getRevisionRootsAttributes'](_0xdcdcfe){return await this['_utils']['loadRevisionData'](_0xdcdcfe,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0xdcdcfe);}async['compare'](_0x414a71,_0x5791de,_0x54aca1=!0x1){if(!this['isEnabled'])return;const _0x5b3355=this['diff'],_0x4f7209=this['repository'],_0x351d46='string'==typeof _0x414a71?_0x4f7209['getRevision'](_0x414a71):_0x414a71,_0x2695f6='string'==typeof _0x5791de?_0x4f7209['getRevision'](_0x5791de):_0x5791de,_0x14aaaa=_0x351d46['id'],_0xde599f=_0x2695f6?_0x2695f6['id']:null;if(!_0x54aca1&&this['diff']&&this['diff']['newRevisionId']===_0x14aaaa&&this['diff']['oldRevisionId']===_0xde599f)return Promise['resolve']();this['isReady']=!0x1,this['activeView']=null,this['activeChange']=null,this['diff']=new J(_0x14aaaa,_0xde599f);const _0x1c3b37=this['_getRevisionsRange'](_0x351d46,_0x2695f6,!0x0)['map'](_0xcab67e=>this['_utils']['loadRevisionData'](_0xcab67e,this['adapter']));return _0x1c3b37['push'](new Promise(_0x58400e=>{setTimeout(_0x58400e,0x14);})),Promise['all'](_0x1c3b37)['then'](()=>{if(!this['isEnabled'])return;this['_cleanUp']();const _0x36db24=this['_getDiff'](_0x14aaaa,_0xde599f);for(const _0x30762a of _0x36db24['changes'])this['_changeIdToChange']['set'](_0x30762a['id'],_0x30762a);this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x4ea83d=>{for(const _0x4e6b16 of this['editor']['model']['document']['getRootNames']())_0x4ea83d['detachRoot'](_0x4e6b16);for(const _0x41175f of Object['keys'](_0x36db24['model'])){const _0x4734f9=_0x4ea83d['addRoot'](_0x41175f);for(const _0x1977b9 of Object['keys'](_0x36db24['attributes'][_0x41175f]))_0x4ea83d['setAttribute'](_0x1977b9,_0x36db24['attributes'][_0x41175f][_0x1977b9],_0x4734f9);_0x4ea83d['insert'](_0x36db24['model'][_0x41175f],_0x4734f9,0x0);}}),this['diff']['_setChanges'](this['_sortAndFilterDiffChanges'](_0x36db24['changes'])),this['isReady']=!0x0;})['catch'](_0x2aa1bf=>{console['error'](_0x2aa1bf),this['_cleanUp'](),_0x5b3355&&(this['diff']=_0x5b3355),this['isReady']=!0x0;});}['addRevisionData'](_0x138dcc,_0xb2178a){const _0x58c593=this['repository']['createRevision'](_0x138dcc);return _0x58c593['on']('_update',(_0x4c35eb,_0x842bd7,_0x148aed)=>_0xb2178a(_0x842bd7,_0x148aed,_0x58c593)),this['repository']['addRevision'](_0x58c593),_0x58c593;}['_cleanUp'](){this['activeChange']=null,this['_cleanMarkers'](),this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=null,this['_changeIdToChange']['clear'](),this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x37e957=>{for(const _0x357961 of this['editor']['model']['document']['getRootNames']())_0x37e957['detachRoot'](_0x357961);});}['_sortAndFilterDiffChanges'](_0x5623c1){const _0x3cd1e2=[],_0x3661f6=new Map();for(const _0x368d88 of this['editor']['model']['document']['getRootNames']()){const _0x3524f2=this['editor']['editing']['view']['getDomRoot'](_0x368d88);if(!_0x3524f2)continue;const _0xad7215=_0x3524f2['getClientRects']()['item'](0x0);_0xad7215&&(_0x3cd1e2['push'](_0x368d88),_0x3661f6['set'](_0x368d88,_0xad7215));}return _0x3cd1e2['sort']((_0x1b6974,_0x2b76cc)=>{const _0xd13f7d=_0x3661f6['get'](_0x1b6974),_0x30efce=_0x3661f6['get'](_0x2b76cc);return _0xd13f7d['y']-_0x30efce['y']||_0xd13f7d['x']-_0x30efce['x'];}),(_0x5623c1=_0x5623c1['filter'](_0x69bda3=>_0x3cd1e2['includes'](_0x69bda3['rootName'])))['sort']((_0xa42988,_0x35ed62)=>_0x3cd1e2['indexOf'](_0xa42988['rootName'])-_0x3cd1e2['indexOf'](_0x35ed62['rootName'])),_0x5623c1;}['_makeTape'](_0xfa55f0){const _0x3effe8=Array['from'](_0xfa55f0['markers'])['filter'](([_0x57c76e,_0x5c7fa2])=>_0x57c76e['startsWith']('revision:')&&!_0x5c7fa2['isCollapsed']),_0x4d2bda=Array['from'](this['editor']['model']['createRangeIn'](_0xfa55f0)['getWalker']({'singleCharacters':!0x0}));if(0x0!=_0x3effe8['length'])for(const _0x5d0b0 of _0x4d2bda){const [_0x93876c,_0x242d14]=_0x3effe8[0x0],[,_0x168d50,_0x10243a]=_0x93876c['split'](':');if(_0x242d14['end']['isEqual'](_0x5d0b0['nextPosition'])&&_0x3effe8['shift'](),(_0x5d0b0['previousPosition']['isEqual'](_0x242d14['start'])||_0x5d0b0['previousPosition']['isAfter'](_0x242d14['start']))&&('insertion'==_0x168d50?_0x5d0b0['isAdded']={'userId':_0x10243a}:'deletion'==_0x168d50&&(_0x5d0b0['isRemoved']={'userId':_0x10243a})),0x0==_0x3effe8['length'])break;}return _0x4d2bda;}['_refreshStartEndIndex'](_0x5cbc3a){const _0x5c0a55=new Map();for(let _0x1db88b=0x0;_0x1db88b<_0x5cbc3a['length'];_0x1db88b++)'text'===_0x5cbc3a[_0x1db88b]['type']?(_0x5cbc3a[_0x1db88b]['item']['startIndex']=_0x1db88b,_0x5cbc3a[_0x1db88b]['item']['endIndex']=_0x1db88b):('elementStart'===_0x5cbc3a[_0x1db88b]['type']?_0x5cbc3a[_0x1db88b]['item']['startIndex']=_0x1db88b:'elementEnd'===_0x5cbc3a[_0x1db88b]['type']&&(_0x5cbc3a[_0x1db88b]['item']['endIndex']=_0x1db88b),_0x5c0a55['set'](_0x5cbc3a[_0x1db88b]['id'],_0x1db88b));for(const _0x4d804d of _0x5c0a55['values']())'elementStart'===_0x5cbc3a[_0x4d804d]['type']?_0x5cbc3a[_0x4d804d]['item']['endIndex']=_0x5c0a55['get'](_0x5cbc3a[_0x4d804d]['pairId']):'elementEnd'===_0x5cbc3a[_0x4d804d]['type']&&(_0x5cbc3a[_0x4d804d]['item']['startIndex']=_0x5c0a55['get'](_0x5cbc3a[_0x4d804d]['pairId']));}['_processTape'](_0x2dd897){for(let _0x21a77e=0x0;_0x21a77e<_0x2dd897['length'];_0x21a77e++){if('elementStart'===_0x2dd897[_0x21a77e]['type'])_0x2dd897[_0x21a77e]['item']['startIndex']=_0x21a77e;else{if('elementEnd'===_0x2dd897[_0x21a77e]['type']){_0x2dd897[_0x21a77e]['item']['endIndex']=_0x21a77e;const _0x124acf=_0x2dd897[_0x21a77e]['item']['startIndex'];_0x2dd897[_0x124acf]['pairId']=_0x2dd897[_0x21a77e]['id'],_0x2dd897[_0x21a77e]['pairId']=_0x2dd897[_0x124acf]['id'];}else _0x2dd897[_0x21a77e]['item']['startIndex']=_0x21a77e,_0x2dd897[_0x21a77e]['item']['endIndex']=_0x21a77e,_0x2dd897[_0x21a77e]['pairId']=null;}_0x2dd897[_0x21a77e]['markersStart']||(_0x2dd897[_0x21a77e]['markersStart']=[],_0x2dd897[_0x21a77e]['markersEnd']=[]);}}['_markInsertions'](_0x3a1b79,_0x2e7d9b){const _0x4f028f=_0x3a1b79['filter'](_0x54ea42=>!_0x54ea42['isAdded']);for(let _0xe20d47=0x0;_0xe20d47<_0x2e7d9b['length'];_0xe20d47++)_0x2e7d9b[_0xe20d47]['isAdded']&&(_0x4f028f[_0xe20d47]['isAdded']=_0x2e7d9b[_0xe20d47]['isAdded']);}['_getDiff'](_0x1672b2,_0x279708=null){const _0x30f725=this['repository']['getRevision'](_0x1672b2),_0x3a0d0a=_0x279708?this['repository']['getRevision'](_0x279708):null,_0x5c3c9c=this['_getRevisionsRange'](_0x30f725,_0x3a0d0a),_0x1c30da=_0x5c3c9c[_0x5c3c9c['length']-0x1],_0x247f0c=new Map(),_0x56e443={'model':{},'attributes':{},'changes':[]},_0x135fe3=new Set(),_0x5891a2=new Map();for(let _0x4bded0=_0x5c3c9c['length']-0x1;_0x4bded0>=0x0;_0x4bded0--){const _0x104a85=_0x5c3c9c[_0x4bded0];for(const _0x506bca of Object['keys'](_0x104a85['diffData']))if(_0x104a85['diffData'][_0x506bca]['attachChange']){const _0x27b787=_0x104a85['diffData'][_0x506bca]['attachChange'];_0x27b787['isAttached']?(_0x135fe3['add'](_0x506bca),_0x5891a2['has'](_0x506bca)&&_0x5891a2['get'](_0x506bca)['userId']==_0x27b787['userId']?_0x5891a2['delete'](_0x506bca):_0x5891a2['set'](_0x506bca,_0x27b787)):_0x5891a2['has'](_0x506bca)?(_0x135fe3['delete'](_0x506bca),_0x5891a2['delete'](_0x506bca)):(_0x135fe3['add'](_0x506bca),_0x5891a2['set'](_0x506bca,_0x27b787));}else _0x135fe3['add'](_0x506bca);}for(const _0x4c45c6 of _0x135fe3){const _0x459d4d=_0x5891a2['has'](_0x4c45c6)&&!_0x5891a2['get'](_0x4c45c6)['isAttached'];let _0x1507df=_0x459d4d?_0x5c3c9c['length']-0x1:0x0;const _0x2cbb84=_0x459d4d?-0x1:0x1;for(;_0x5c3c9c[_0x1507df];){const _0x1c211a=_0x5c3c9c[_0x1507df];if(_0x1c211a['diffData'][_0x4c45c6]){const _0x246237=_0x459d4d?_0x1c211a['diffData'][_0x4c45c6]['attributesBefore']:_0x1c211a['diffData'][_0x4c45c6]['attributesAfter'];_0x56e443['attributes'][_0x4c45c6]=_0x246237?_0x115d90(_0x246237):{};break;}_0x1507df+=_0x2cbb84;}}for(const _0x2ba182 of _0x5c3c9c){_0x2ba182['model']={};for(const _0x1ff6c0 of _0x2ba182['authors'])_0x247f0c['set'](_0x1ff6c0['id'],_0x1ff6c0);for(const _0x1193f3 of _0x135fe3){const _0x343953=_0x2ba182['diffData'][_0x1193f3]?_0x2ba182['diffData'][_0x1193f3]['insertions']:'[]',_0x526c1a=_0x2ba182['diffData'][_0x1193f3]?_0x2ba182['diffData'][_0x1193f3]['deletions']:'[]';_0x2ba182['model'][_0x1193f3]={'insertions':this['_utils']['_makeModelFromViewString'](_0x343953),'deletions':this['_utils']['_makeModelFromViewString'](_0x526c1a)};}}for(const _0x3998ea of _0x135fe3){let _0x1790fa=null,_0x35c0a5=0x0;const _0x118040=new Map(Array['from'](_0x30f725['model'][_0x3998ea]['insertions']['markers'])['filter'](([_0x2ae8b8])=>!_0x2ae8b8['startsWith']('revision:')));let _0x106113=0x0;for(const _0x8aa9c5 of _0x5c3c9c){const _0x1c4000=this['_makeTape'](_0x8aa9c5['model'][_0x3998ea]['insertions']);_0x8aa9c5==_0x30f725?(_0x1790fa=_0x1c4000,_0x35c0a5=_0x1790fa['length'],_0x1790fa['forEach'](_0x1a9a6a=>{_0x1a9a6a['id']=_0x106113++;}),this['_processTape'](_0x1790fa)):this['_markInsertions'](_0x1790fa,_0x1c4000);const _0x3baacd=_0x1790fa['filter'](_0x4cdbd1=>!_0x4cdbd1['isAdded'])['map'](_0x3c9271=>_0x3c9271['id']);let _0x2ec438=0x0;const _0x499b3f=this['_makeTape'](_0x8aa9c5['model'][_0x3998ea]['deletions']);_0x499b3f['forEach'](_0x648eac=>{_0x648eac['isRemoved']?_0x648eac['id']=_0x35c0a5++:_0x648eac['id']=_0x3baacd[_0x2ec438++];}),this['_processTape'](_0x499b3f),this['_setDistance'](_0x1790fa,'isAdded'),this['_setDistance'](_0x499b3f,'isRemoved'),_0x8aa9c5==_0x30f725&&this['_markMarkers'](_0x1790fa,_0x118040),_0x1790fa=this['_joinTapes'](_0x1790fa,_0x499b3f),this['_refreshStartEndIndex'](_0x1790fa),this['_setDistance'](_0x1790fa,'isRemoved');}_0x1790fa=_0x1790fa['filter'](_0x25bcd7=>!(_0x25bcd7['isAdded']&&_0x25bcd7['isRemoved']));const _0x18124b=new Map(_0x1c30da['model'][_0x3998ea]['deletions']['markers']),_0x5a53e7=new Set(_0x118040['keys']());for(const _0x3440cc of _0x18124b['keys']())_0x5a53e7['delete'](_0x3440cc);this['_markSuggestions'](_0x1790fa,_0x5a53e7),this['_fixObsoleteTags'](_0x1790fa),_0x1790fa=this['_removeMissingPairs'](_0x1790fa),_0x1790fa=this['_markMismatchedRemovedTags'](_0x1790fa),_0x1790fa=this['_removeUnsupportedChanges'](_0x1790fa);const {root:_0x369f70,changes:_0x158efd}=this['_makeModelFromTape'](_0x1790fa,_0x247f0c,_0x3998ea);_0x56e443['model'][_0x3998ea]=_0x369f70;const _0x292874=_0x5891a2['get'](_0x3998ea);if(_0x292874){const _0x158fa1=_0x247f0c['get'](_0x292874['userId']),_0x2300e5=new G({'author':_0x158fa1,'type':_0x292874['isAttached']?'add':'remove','data':{'isOnRoot':!0x0},'createdAt':new Date(),'rootName':_0x3998ea});_0x158efd['unshift'](_0x2300e5),_0x56e443['attributes'][_0x3998ea]['revisionHistoryAttachChange']=_0x2300e5['id'];}_0x56e443['changes']=_0x56e443['changes']['concat'](_0x158efd);}return _0x56e443;}['_markMarkers'](_0x57f736,_0x33e836){for(let _0x5c2eed=0x0;_0x5c2eed<_0x57f736['length'];_0x5c2eed++)for(const [_0x1642a4,_0x4e2c49]of _0x33e836)!_0x4e2c49['isCollapsed']&&_0x4e2c49['start']['isEqual'](_0x57f736[_0x5c2eed]['previousPosition'])&&_0x57f736[_0x5c2eed]['markersStart']['push'](_0x1642a4),_0x4e2c49['end']['isEqual'](_0x57f736[_0x5c2eed]['nextPosition'])&&_0x57f736[_0x5c2eed]['markersEnd']['push'](_0x1642a4);}['_joinTapes'](_0x66d8c3,_0x4b6713){let _0x221eea=[],_0x317ffa=0x0,_0x42badb=0x0;for(;_0x317ffa<_0x66d8c3['length']||_0x42badb<_0x4b6713['length'];){const _0x2f75de=_0x66d8c3[_0x317ffa]||{},_0x1540af=_0x4b6713[_0x42badb]||{};if(_0x2f75de['id']==_0x1540af['id'])_0x317ffa++,_0x42badb++,_0x221eea['push'](_0x2f75de);else{if(_0x1540af['isRemoved']&&_0x2f75de['isAdded']){const {commonTape:_0x30d1e9,iEnd:_0x19fa1e,jEnd:_0x5b54fc}=this['_threeWayMerge'](_0x66d8c3,_0x317ffa,_0x4b6713,_0x42badb);_0x221eea=_0x221eea['concat'](_0x30d1e9),_0x317ffa=_0x19fa1e,_0x42badb=_0x5b54fc;}else _0x1540af['isRemoved']?(_0x42badb++,_0x221eea['push'](_0x1540af)):(_0x317ffa++,_0x221eea['push'](_0x2f75de));}}return _0x221eea;}['_markSuggestions'](_0x44d158,_0x5b4fc9){const _0x52e5f7=[];for(let _0x5c7b83=0x0;_0x5c7b83<_0x44d158['length'];_0x5c7b83++){for(let _0x5dc3f2=0x0;_0x5dc3f2<_0x44d158[_0x5c7b83]['markersStart']['length'];_0x5dc3f2++){const _0x27c5d5=_0x44d158[_0x5c7b83]['markersStart'][_0x5dc3f2];if(!_0x5b4fc9['has'](_0x27c5d5))continue;const {group:_0x590cb7,type:_0x1f2ba1,authorId:_0x106024}=_0x214458(_0x27c5d5);'revision-suggestion'!=_0x590cb7||'insertion'!=_0x1f2ba1&&'deletion'!=_0x1f2ba1||(_0x52e5f7['unshift']({'type':_0x1f2ba1,'name':_0x27c5d5,'userId':_0x106024}),_0x44d158[_0x5c7b83]['markersStart']['splice'](_0x5dc3f2,0x1),_0x5dc3f2--);}_0x1e536e(_0x44d158[_0x5c7b83]);for(let _0x20e381=0x0;_0x20e381<_0x44d158[_0x5c7b83]['markersEnd']['length'];_0x20e381++){const _0x3e423d=_0x44d158[_0x5c7b83]['markersEnd'][_0x20e381];if(!_0x5b4fc9['has'](_0x3e423d))continue;const {group:_0x44cedb,type:_0x2caf07}=_0x214458(_0x3e423d);if('revision-suggestion'!=_0x44cedb||'insertion'!=_0x2caf07&&'deletion'!=_0x2caf07)continue;_0x44d158[_0x5c7b83]['markersEnd']['splice'](_0x20e381,0x1),_0x20e381--;const _0x4ab327=_0x52e5f7['findIndex'](_0xbc4e57=>_0xbc4e57['name']==_0x3e423d);_0x4ab327>-0x1&&_0x52e5f7['splice'](_0x4ab327,0x1);}}function _0x214458(_0x226d4a){const _0x335869=_0x226d4a['split'](':');return{'group':_0x335869[0x0],'type':_0x335869[0x1],'subType':_0x335869['length']>=0x5?_0x335869[0x2]:null,'id':_0x335869['length']<0x5?_0x335869[0x2]:_0x335869[0x3],'authorId':_0x335869['length']<0x5?_0x335869[0x3]:_0x335869[0x4],'markerCount':0x6==_0x335869['length']?_0x335869[0x5]:null};}function _0x1e536e(_0xa770d8){for(let _0x4c8e36=0x0;_0x4c8e36<_0x52e5f7['length'];_0x4c8e36++){if(_0xa770d8['isAdded']&&'insertion'==_0x52e5f7[_0x4c8e36]['type']&&_0xa770d8['isAdded']['userId']==_0x52e5f7[_0x4c8e36]['userId'])return _0xa770d8['isAddSuggestion']=_0x52e5f7[_0x4c8e36],void delete _0xa770d8['isAdded'];if(!_0xa770d8['isAdded']&&!_0xa770d8['isRemoved']&&'deletion'==_0x52e5f7[_0x4c8e36]['type'])return void(_0xa770d8['isRemoveSuggestion']=_0x52e5f7[_0x4c8e36]);}}}['_setDistance'](_0x4b6542,_0x16f006){let _0x3daa5a=0x0,_0x2992c8=!0x1;const _0x39b31a=new Map();for(const _0x561f09 of _0x4b6542)_0x561f09[_0x16f006]?_0x2992c8&&(_0x3daa5a++,_0x2992c8=!0x1):(_0x3daa5a++,_0x2992c8=!0x0),_0x39b31a['set'](_0x561f09['id'],_0x3daa5a);for(let _0x175bbf=0x0;_0x175bbf<_0x4b6542['length'];_0x175bbf++){if('isRemoved'==_0x16f006&&_0x4b6542[_0x175bbf]['isAdded']||'isAdded'==_0x16f006&&_0x4b6542[_0x175bbf]['isRemoved'])continue;if('text'==_0x4b6542[_0x175bbf]['type']){_0x4b6542[_0x175bbf]['distance']=0x0;continue;}const _0x1396e8=_0x39b31a['get'](_0x4b6542[_0x175bbf]['pairId']),_0x2e293f=_0x39b31a['get'](_0x4b6542[_0x175bbf]['id']);_0x4b6542[_0x175bbf]['distance']=_0x1396e8-_0x2e293f;}}['_getRevisionsRange'](_0x3d625f,_0x5656c9,_0x262765=!0x1){const _0x250232=[];let _0x13030c=this['repository']['getIndex'](_0x3d625f),_0x50ee2d=this['repository']['getIndex'](_0x5656c9);for(-0x1==_0x50ee2d&&(_0x50ee2d=this['repository']['_revisions']['length'],_0x262765=!0x1);_0x13030c<_0x50ee2d;)_0x250232['push'](this['repository']['getRevision'](_0x13030c)),_0x13030c++;return _0x262765&&_0x250232['push'](this['repository']['getRevision'](_0x13030c)),_0x250232;}['_threeWayMerge'](_0x5eb0e2,_0x906f5d,_0x1f62bb,_0xfb10ad){const _0x26416f=this['editor']['model']['schema'];let _0x1f1d1e=_0x906f5d;for(;_0x5eb0e2[_0x1f1d1e]&&_0x5eb0e2[_0x1f1d1e]['isAdded'];)_0x1f1d1e++;let _0xb295c1=_0xfb10ad;for(;_0x1f62bb[_0xb295c1]&&_0x1f62bb[_0xb295c1]['isRemoved'];)_0xb295c1++;_0x551e00(_0x5eb0e2,_0x906f5d,_0x1f1d1e),_0x551e00(_0x1f62bb,_0xfb10ad,_0xb295c1);const _0x5ccfb7=_0x1f62bb['slice'](_0xfb10ad,_0xb295c1)['concat'](_0x5eb0e2['slice'](_0x906f5d,_0x1f1d1e));return _0x5ccfb7['sort']((_0x8f0ec4,_0x3e41fb)=>_0x8f0ec4['side']!=_0x3e41fb['side']?_0x8f0ec4['side']-_0x3e41fb['side']:_0x8f0ec4['level']!=_0x3e41fb['level']?_0x8f0ec4['level']-_0x3e41fb['level']:_0x8f0ec4['distance']!=_0x3e41fb['distance']?_0x3e41fb['distance']-_0x8f0ec4['distance']:!!_0x8f0ec4['isAdded']!=!!_0x3e41fb['isAdded']?-0x1==_0x8f0ec4['side']||0x0==_0x8f0ec4['side']?_0x8f0ec4['isAdded']?-0x1:0x1:_0x8f0ec4['isAdded']?0x1:-0x1:_0x8f0ec4['index']-_0x3e41fb['index']),{'commonTape':_0x5ccfb7,'iEnd':_0x1f1d1e,'jEnd':_0xb295c1};function _0x551e00(_0x67cfe9,_0x183b0f,_0x3f8332){let _0x4b256d=-0x1,_0x25f681=Number['POSITIVE_INFINITY'],_0x4e83c5=!0x0;for(let _0x3f8bd4=_0x183b0f;_0x3f8bd4<_0x3f8332;_0x3f8bd4++)if(_0x26416f['isInline'](_0x67cfe9[_0x3f8bd4]['item'])||(_0x4e83c5=!0x1),_0x67cfe9[_0x3f8bd4]['item']['startIndex']<_0x183b0f&&(_0x4b256d=_0x3f8bd4),_0x67cfe9[_0x3f8bd4]['item']['endIndex']>=_0x3f8332){_0x25f681=_0x3f8bd4;break;}_0x4e83c5&&(_0x4b256d=_0x3f8332-0x1);for(let _0x450554=_0x183b0f;_0x450554<_0x3f8332;_0x450554++)_0x67cfe9[_0x450554]['side']=_0x450554<=_0x4b256d?-0x1:_0x450554<_0x25f681?0x0:0x1,_0x67cfe9[_0x450554]['index']=_0x450554;let _0x33e7a2=0x0;for(let _0x3dd2b2=_0x183b0f;_0x3dd2b2<=_0x4b256d;_0x3dd2b2++)0x0==_0x67cfe9[_0x3dd2b2]['distance']?_0x67cfe9[_0x3dd2b2]['level']=_0x33e7a2:(_0x33e7a2++,_0x67cfe9[_0x3dd2b2]['level']=_0x33e7a2,_0x33e7a2++);for(let _0x1b8eb2=_0x183b0f;_0x1b8eb2<_0x3f8332;_0x1b8eb2++)0x0==_0x67cfe9[_0x1b8eb2]['side']&&(_0x67cfe9[_0x1b8eb2]['level']=_0x33e7a2);_0x33e7a2=0x0;for(let _0xd1d586=_0x3f8332-0x1;_0xd1d586>=_0x25f681;_0xd1d586--)0x0==_0x67cfe9[_0xd1d586]['distance']?_0x67cfe9[_0xd1d586]['level']=_0x33e7a2:(_0x33e7a2--,_0x67cfe9[_0xd1d586]['level']=_0x33e7a2,_0x33e7a2--);}}['_fixObsoleteTags'](_0xa36916){const _0x3a9924=new Map(),_0x431042=this['editor']['model']['schema'];for(let _0x19af11=0x1;_0x19af11<_0xa36916['length'];_0x19af11++){let _0x58f86f,_0x5d6f45,_0x55bc25;const _0x25a3e0=_0xa36916[_0x19af11],_0x58234b=_0xa36916[_0x19af11-0x1];if('text'==_0x25a3e0['type'])continue;if(_0x25a3e0['type']!=_0x58234b['type'])continue;if(!_0x431042['isBlock'](_0x58234b['item'])||_0x431042['isLimit'](_0x58234b['item']))continue;if(!_0x431042['isBlock'](_0x25a3e0['item'])||_0x431042['isLimit'](_0x25a3e0['item']))continue;if((_0xa36916[_0x19af11]['isAdded']||_0xa36916[_0x19af11]['isAddSuggestion'])&&_0xa36916[_0x19af11-0x1]['isRemoved'])_0x58f86f=_0xa36916[_0x19af11],_0x5d6f45=_0xa36916[_0x19af11-0x1],_0x55bc25=_0x19af11-0x1;else{if(!_0xa36916[_0x19af11]['isRemoved']||!_0xa36916[_0x19af11-0x1]['isAdded']&&!_0xa36916[_0x19af11-0x1]['isAddSuggestion'])continue;_0x58f86f=_0xa36916[_0x19af11-0x1],_0x5d6f45=_0xa36916[_0x19af11],_0x55bc25=_0x19af11;}const _0x3b6769=_0x58f86f['level']==_0x5d6f45['level'],_0x4948a7=Math['abs'](_0x58f86f['level'])<Math['abs'](_0x5d6f45['level'])&&0x0==_0x5d6f45['distance'];(_0x3b6769||_0x4948a7)&&(_0x3a9924['set'](_0x5d6f45['id'],_0x58f86f['id']),_0xa36916['splice'](_0x55bc25,0x1),_0x19af11--,_0x58f86f['isAdded']=!0x1);}for(let _0x151d9e=0x0;_0x151d9e<_0xa36916['length'];_0x151d9e++)_0x3a9924['has'](_0xa36916[_0x151d9e]['pairId'])&&(_0xa36916[_0x151d9e]['pairId']=_0x3a9924['get'](_0xa36916[_0x151d9e]['pairId']));}['_removeMissingPairs'](_0x50444c){const _0x83707b=new Set(_0x50444c['map'](_0x14cd51=>_0x14cd51['id']));for(let _0x5f3475=0x0;_0x5f3475<_0x50444c['length'];_0x5f3475++)_0x83707b['has'](_0x50444c[_0x5f3475]['pairId'])||0x0==_0x50444c[_0x5f3475]['distance']||(_0x50444c[_0x5f3475]['isIncorrect']=!0x0);return _0x50444c['filter'](_0x37245f=>!_0x37245f['isIncorrect']);}['_markMismatchedRemovedTags'](_0x1e6948){const _0xbbb041=new Set();for(let _0x5277f0=0x0;_0x5277f0<_0x1e6948['length'];_0x5277f0++){if(_0xbbb041['has'](_0x1e6948[_0x5277f0]['id'])&&_0x1e6948[_0x5277f0]['isRemoved']&&(_0x1e6948[_0x5277f0]['isIncorrect']=!0x0),_0x1e6948[_0x5277f0]['isIncorrect'])continue;if(0x0==_0x1e6948[_0x5277f0]['distance'])continue;if('elementStart'!=_0x1e6948[_0x5277f0]['type'])continue;if(null==_0x1e6948[_0x5277f0]['pairId'])continue;let _0x23f294=_0x5277f0+0x1,_0x9aefc4=0x0;for(;_0x1e6948[_0x23f294]['id']!=_0x1e6948[_0x5277f0]['pairId'];)'elementStart'==_0x1e6948[_0x23f294]['type']?_0x9aefc4++:'elementEnd'==_0x1e6948[_0x23f294]['type']&&_0x9aefc4--,_0x23f294++;if(0x0!=_0x9aefc4){if(_0x1e6948[_0x5277f0]['isRemoved'])_0x1e6948[_0x5277f0]['isIncorrect']=!0x0;else{for(;_0x23f294!=_0x5277f0;)_0x1e6948[_0x23f294]['isRemoved']&&0x0!=_0x1e6948[_0x23f294]['distance']&&(_0x1e6948[_0x23f294]['isIncorrect']=!0x0,_0xbbb041['add'](_0x1e6948[_0x23f294]['pairId'])),_0x23f294--;}}}return _0x1e6948['filter'](_0x56b320=>!_0x56b320['isIncorrect']);}['_removeUnsupportedChanges'](_0x222410){const _0x3e5b36=this['editor']['model']['schema'];for(let _0x426fe7=0x0;_0x426fe7<_0x222410['length'];_0x426fe7++){if(!(_0x222410[_0x426fe7]['isAdded']||_0x222410[_0x426fe7]['isAddSuggestion']||_0x222410[_0x426fe7]['isRemoved']||_0x222410[_0x426fe7]['isRemoveSuggestion']))continue;if(0x0==_0x222410[_0x426fe7]['distance'])continue;const _0x5ca451=_0x222410[_0x426fe7]['item'];_0x3e5b36['isBlock'](_0x5ca451)||_0x3e5b36['isLimit'](_0x5ca451)||(_0x222410[_0x426fe7]['isAdded']&&delete _0x222410[_0x426fe7]['isAdded'],_0x222410[_0x426fe7]['isAddSuggestion']&&delete _0x222410[_0x426fe7]['isAddSuggestion'],_0x222410[_0x426fe7]['isRemoveSuggestion']&&delete _0x222410[_0x426fe7]['isRemoveSuggestion'],_0x222410[_0x426fe7]['isRemoved']&&(_0x222410[_0x426fe7]['isIncorrect']=!0x0));}return _0x222410['filter'](_0x241d51=>!_0x241d51['isIncorrect']);}['_makeModelFromTape'](_0x3b2003,_0x413c8a,_0xa64d85){const _0x2b3ffe=new _0xf3d172(),_0x43a908=[],_0x5e9411=new Map(),_0x1e9a9e=this['editor']['model'],_0x3e4efc=_0x1e9a9e['schema'],_0x512fd3=[_0x2b3ffe],_0x2951f9={},_0x2ab641={'isAdded':[],'isRemoved':[],'isAddSuggestion':[],'isRemoveSuggestion':[]};let _0x3171be=null;const _0x2a4569=[0x0];for(let _0x392161=0x0;_0x392161<_0x3b2003['length'];_0x392161++)if('elementStart'===_0x3b2003[_0x392161]['type']){_0x3b2003[_0x392161]['previousPosition']=_0x1e9a9e['createPositionFromPath'](_0x2b3ffe,_0x2a4569);const _0x5c34d7=new _0x14fd90(_0x3b2003[_0x392161]['item']['name'],_0x3b2003[_0x392161]['item']['getAttributes']());_0x512fd3[0x0]['_appendChild'](_0x5c34d7),_0x2a4569['push'](0x0),_0x512fd3['unshift'](_0x5c34d7),_0x3b2003[_0x392161]['nextPosition']=_0x1e9a9e['createPositionFromPath'](_0x2b3ffe,_0x2a4569);}else'elementEnd'===_0x3b2003[_0x392161]['type']?(_0x512fd3['shift'](),_0x3b2003[_0x392161]['previousPosition']=_0x1e9a9e['createPositionFromPath'](_0x2b3ffe,_0x2a4569),_0x2a4569['pop'](),_0x2a4569[_0x2a4569['length']-0x1]++,_0x3b2003[_0x392161]['nextPosition']=_0x1e9a9e['createPositionFromPath'](_0x2b3ffe,_0x2a4569)):(_0x3b2003[_0x392161]['previousPosition']=_0x1e9a9e['createPositionFromPath'](_0x2b3ffe,_0x2a4569),_0x3171be?_0x3171be['_data']+=_0x3b2003[_0x392161]['item']['data']:_0x3171be=new _0xe3cd6f(_0x3b2003[_0x392161]['item']['data'],_0x3b2003[_0x392161]['item']['getAttributes']()),_0x3b2003[_0x392161+0x1]&&'text'===_0x3b2003[_0x392161+0x1]['type']&&_0x1effd8(_0x3171be,_0x3b2003[_0x392161+0x1]['item'])||(_0x512fd3[0x0]['_appendChild'](_0x3171be),_0x3171be=null),_0x2a4569[_0x2a4569['length']-0x1]+=_0x3b2003[_0x392161]['item']['offsetSize'],_0x3b2003[_0x392161]['nextPosition']=_0x1e9a9e['createPositionFromPath'](_0x2b3ffe,_0x2a4569));for(let _0x4c2581=0x0;_0x4c2581<_0x3b2003['length'];_0x4c2581++){const _0x2ce0bf=_0x3b2003[_0x4c2581]['previousPosition'],_0x227939=_0x3b2003[_0x4c2581]['nextPosition'];for(const _0x55679c of _0x3b2003[_0x4c2581]['markersStart'])_0x5e9411['set'](_0x55679c,{'start':_0x2ce0bf,'end':null});_0x305e18('isRemoveSuggestion',_0x4c2581,_0x2ce0bf,_0x227939),_0x305e18('isAddSuggestion',_0x4c2581,_0x2ce0bf,_0x227939),_0x305e18('isRemoved',_0x4c2581,_0x2ce0bf,_0x227939),_0x305e18('isAdded',_0x4c2581,_0x2ce0bf,_0x227939);for(const _0x23a257 of _0x3b2003[_0x4c2581]['markersEnd']){const _0x34a800=_0x5e9411['get'](_0x23a257);_0x34a800?_0x34a800['end']=_0x227939:_0x5e9411['set'](_0x23a257,{'start':_0x227939,'end':_0x227939});}}for(const [_0x8b83a8,_0x453f72]of _0x5e9411){const _0x236e7c=this['editor']['model']['createRange'](_0x453f72['start'],_0x453f72['end']);_0x2b3ffe['markers']['set'](_0x8b83a8,_0x236e7c);}return _0x43a908['sort']((_0x1cdef4,_0x3b2cd1)=>{const _0x1f433e=_0x2b3ffe['markers']['get']('revision:'+_0x1cdef4['id']),_0x5ae86c=_0x2b3ffe['markers']['get']('revision:'+_0x3b2cd1['id']);return _0x1f433e['start']['isBefore'](_0x5ae86c['start'])?-0x1:_0x1f433e['start']['isAfter'](_0x5ae86c['start'])?0x1:_0x1f433e['end']['isBefore'](_0x5ae86c['end'])?-0x1:_0x1f433e['end']['isAfter'](_0x5ae86c['end'])?0x1:'add'===_0x1cdef4['type']?-0x1:0x1;}),{'root':_0x2b3ffe,'changes':_0x43a908};function _0x305e18(_0x48ed19,_0x483a97,_0x61b641,_0x1fca36){const _0xf568c8=!!_0x3b2003[_0x483a97][_0x48ed19],_0x5c1783=_0xf568c8?_0x3b2003[_0x483a97][_0x48ed19]['userId']:null,_0x4b4918=_0x483a97===_0x3b2003['length']-0x1,_0x3145ea=_0x2ab641[_0x48ed19][0x0],_0x4d059f=_0x3e4efc['isObject'](_0x3b2003[_0x483a97]['item']);!_0x2951f9[_0x48ed19]&&_0xf568c8?_0x2951f9[_0x48ed19]={'start':_0x61b641,'tapeItem':_0x3b2003[_0x483a97],'userId':_0x5c1783,'type':_0x48ed19}:_0x2951f9[_0x48ed19]&&!_0xf568c8?(_0x2951f9[_0x48ed19]['end']=_0x61b641,_0x556bf7(_0x2951f9[_0x48ed19]),_0x2951f9[_0x48ed19]=null):_0x2951f9[_0x48ed19]&&_0xf568c8&&_0x2951f9[_0x48ed19]['userId']!==_0x5c1783&&(_0x2951f9[_0x48ed19]['end']=_0x61b641,_0x3145ea&&_0x3145ea['userId']===_0x2951f9[_0x48ed19]['userId']||_0x556bf7(_0x2951f9[_0x48ed19]),_0x2951f9[_0x48ed19]={'start':_0x61b641,'tapeItem':_0x3b2003[_0x483a97],'userId':_0x5c1783,'type':_0x48ed19}),_0x2951f9[_0x48ed19]&&_0x4d059f&&('elementStart'!==_0x3b2003[_0x483a97]['type']||_0x3145ea&&_0x3145ea['userId']===_0x5c1783||_0x2ab641[_0x48ed19]['unshift']({'userId':_0x5c1783,'object':_0x3b2003[_0x483a97]['item'],'change':_0x2951f9[_0x48ed19]}),'elementEnd'===_0x3b2003[_0x483a97]['type']&&_0x3145ea&&_0x3145ea['object']===_0x3b2003[_0x483a97]['item']&&(_0x2ab641[_0x48ed19]['shift'](),_0x2951f9[_0x48ed19]=_0x3145ea['change'])),_0x2951f9[_0x48ed19]&&_0x4b4918&&(_0x2951f9[_0x48ed19]['end']=_0x1fca36,_0x556bf7(_0x2951f9[_0x48ed19]),_0x2951f9[_0x48ed19]=null);}function _0x556bf7({start:_0x1c6c86,end:_0x42d763,tapeItem:_0x36ce57,userId:_0x25ebbe,type:_0xc15fa9}){const _0x1c7d10=_0x36ce57['item'],_0x554264=_0x1e9a9e['schema']['isBlock'](_0x1c7d10)&&!_0x1e9a9e['schema']['isLimit'](_0x1c7d10),_0x3ae7fd=_0x1c6c86['nodeAfter']==_0x42d763['parent']&&_0x42d763['isAtStart'];if(_0x554264&&_0x3ae7fd)return;const _0x291aca=_0x1e9a9e['createRange'](_0x1c6c86,_0x42d763),_0x20726b=_0x413c8a['get'](_0x25ebbe),_0x293c44=new G({'author':_0x20726b,'type':'isAdded'==_0xc15fa9||'isAddSuggestion'==_0xc15fa9?'add':'remove','data':{'isSuggestion':'isAddSuggestion'==_0xc15fa9||'isRemoveSuggestion'==_0xc15fa9},'createdAt':new Date(),'rootName':_0xa64d85});_0x43a908['push'](_0x293c44),_0x2b3ffe['markers']['set']('revision:'+_0x293c44['id'],_0x291aca);}function _0x1effd8(_0xde1510,_0x2392ce){const _0x5d1f71=_0xde1510['getAttributes'](),_0x37534c=_0x2392ce['getAttributes']();for(const _0x32af2d of _0x5d1f71){if(_0x32af2d[0x1]!==_0x2392ce['getAttribute'](_0x32af2d[0x0]))return!0x1;_0x37534c['next']();}return _0x37534c['next']()['done'];}}['_setConversion'](){this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision','view':_0x4c2361=>{const _0x4a1f3b=_0x4c2361['markerName']['split'](':')[0x1],_0x30f974=this['_getChangeFromId'](_0x4a1f3b);if(!_0x30f974)return null;const _0x5ab9a2='add'==_0x30f974['type']?'insertion':'deletion',_0x26a829=['ck-suggestion-marker','ck-suggestion-marker-'+_0x5ab9a2];return _0x30f974['data']['isSuggestion']&&_0x26a829['push']('ck-suggestion-marker-'+_0x5ab9a2+'-new'),this['activeChange']==_0x30f974&&_0x26a829['push']('ck-suggestion-marker--active'),{'classes':_0x26a829,'attributes':{'data-change-id':_0x4a1f3b}};}}),this['editor']['conversion']['for']('upcast')['add'](_0x36325a=>{_0x36325a['on']('element:pre',(_0x1102c8,_0x1aa5fd,_0x132a08)=>{const _0x1fe88b=_0x1aa5fd['viewItem']['getChild'](0x0);if(!_0x1fe88b||!_0x1fe88b['is']('element','code'))return;if(!_0x132a08['consumable']['consume'](_0x1fe88b,{'attributes':['vid_start','vid_end']}))return;const _0x5cb20a=_0x1aa5fd['modelRange']['start']['nodeAfter'];_0x132a08['writer']['setAttribute']('vid_start',_0x1fe88b['getAttribute']('vid_start'),_0x5cb20a),_0x132a08['writer']['setAttribute']('vid_end',_0x1fe88b['getAttribute']('vid_end'),_0x5cb20a);},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['add'](_0x190aa4=>{_0x190aa4['on']('element',(_0x3ea1b4,_0x1e7c3f,_0x1b1dae)=>{if(!_0x1b1dae['consumable']['consume'](_0x1e7c3f['viewItem'],{'attributes':['vid_start','vid_end']}))return;if(_0x1e7c3f['modelRange']['isCollapsed'])return;const _0x265160=_0x1e7c3f['modelRange']['start']['nodeAfter'];_0x265160['hasAttribute']('vid_start')||_0x265160['hasAttribute']('vid')||(_0x1b1dae['writer']['setAttribute']('vid_start',_0x1e7c3f['viewItem']['getAttribute']('vid_start'),_0x265160),_0x1b1dae['writer']['setAttribute']('vid_end',_0x1e7c3f['viewItem']['getAttribute']('vid_end'),_0x265160));},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['elementToAttribute']({'view':{'name':'span','attributes':{'vid':!0x0}},'model':{'key':'vid','value':_0xe08050=>_0xe08050['getAttribute']('vid')}}),this['editor']['model']['schema']['on']('checkAttribute',(_0x3e845b,[,_0x413e0c])=>{['vid_start','vid_end','vid']['includes'](_0x413e0c)&&(_0x3e845b['return']=!0x0,_0x3e845b['stop']());},{'priority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x124197=>{_0x124197['on']('attribute:vid',(_0x3d75c3,_0x54e4e0,_0x4579ac)=>{if('\x20'!=_0x54e4e0['item']['data']||_0x54e4e0['item']['parent']['maxOffset']>0x1)return;if(!_0x4579ac['consumable']['consume'](_0x54e4e0['item'],_0x3d75c3['name']))return;const _0x279faa=_0x4579ac['writer'],_0x3d58b2=_0x4579ac['mapper']['toViewRange'](_0x54e4e0['range']);_0x279faa['wrap'](_0x3d58b2,_0x279faa['createAttributeElement']('span'));});}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',function(_0x511e65){const _0x4f270c=_0x511e65['plugins']['get']('RevisionViewer');return(_0x9c8d17,_0x247104,_0x1e5dc5)=>{const _0x5be0f2=_0x247104['markerName']['split'](':')[0x1],_0x1230e7=_0x4f270c['_getChangeFromId'](_0x5be0f2);if(!_0x1230e7)return null;const _0x324350='add'==_0x1230e7['type']?'split':'merge';if(!_0x1e5dc5['consumable']['test'](_0x247104['markerRange'],_0x9c8d17['name']))return;const _0xd3e2d7=_0x247104['markerRange']['getWalker'](),_0x12d9f0=_0x247104['markerRange']['start'],_0x3189ce=_0x511e65['model']['schema'];let _0x4bbbf6=null,_0x50b813=null,_0x3a88cb=!0x1,_0x56a61b=!0x1;for(const _0x87e39e of _0xd3e2d7){const _0x4847cc=_0x87e39e['item'];_0x3a88cb=_0x3a88cb||_0x3189ce['isContent'](_0x4847cc);const _0x2d1088=_0x1e5dc5['mapper']['toViewElement'](_0x4847cc);if(_0x2d1088&&_0x2d1088['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x87e39e['type']&&(_0x3189ce['isBlock'](_0x4847cc)&&!_0x3189ce['isLimit'](_0x4847cc)&&(_0x4847cc['nextSibling']||_0x12d9f0['isAtEnd']?_0x4bbbf6&&_0x4bbbf6['parent']==_0x4847cc||(_0x4bbbf6=_0x4847cc,_0xe757e1(_0x87e39e['previousPosition']),_0x56a61b=!0x0):_0x50b813=_0x50b813||_0x87e39e['previousPosition']));}function _0xe757e1(_0x2ccbed){const _0x2c2d70=_0x1e5dc5['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x324350}),_0x5cb422=_0x1e5dc5['mapper']['toViewPosition'](_0x2ccbed);_0x1230e7['data']['isSuggestion']&&_0x1e5dc5['writer']['addClass']('ck-suggestion-marker-'+_0x324350+'-new',_0x2c2d70),_0x4f270c['activeChange']==_0x1230e7&&_0x1e5dc5['writer']['addClass']('ck-suggestion-marker--active',_0x2c2d70),_0x1e5dc5['writer']['insert'](_0x5cb422,_0x2c2d70),_0x1e5dc5['mapper']['bindElementToMarker'](_0x2c2d70,_0x247104['markerName']);}_0x3a88cb||_0x56a61b||!_0x50b813||_0xe757e1(_0x50b813);};}(this['editor']),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision',(_0xaf129c,_0x5b371d,_0x4ca572)=>{const _0x2925ae=_0x4ca572['mapper']['markerNameToElements'](_0x5b371d['markerName']);if(_0x2925ae){for(const _0x47d371 of _0x2925ae)(_0x47d371['hasClass']('ck-suggestion-marker-split')||_0x47d371['hasClass']('ck-suggestion-marker-merge'))&&(_0x4ca572['mapper']['unbindElementFromMarkerName'](_0x47d371,_0x5b371d['markerName']),_0x4ca572['writer']['remove'](_0x47d371));}},{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',(_0x399dc5,_0x3a1f04,_0x10936f)=>{const _0x46167e=_0x3a1f04['markerName']['split'](':')[0x1],_0x59c051=this['_getChangeFromId'](_0x46167e);if(!_0x59c051)return null;const _0x2a1e29='add'==_0x59c051['type']?'split':'merge';if(_0x10936f['consumable']['test'](_0x3a1f04['markerRange'],_0x399dc5['name']))for(const _0x133628 of _0x3a1f04['markerRange']['getItems']()){if(!_0x133628['is']('element','softBreak'))continue;const _0x5206e1=_0x10936f['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x2a1e29}),_0x22fabc=_0x10936f['mapper']['toViewPosition'](this['editor']['model']['createPositionBefore'](_0x133628));_0x59c051['data']['isSuggestion']&&_0x10936f['writer']['addClass']('ck-suggestion-marker-'+_0x2a1e29+'-new',_0x5206e1),this['activeChange']==_0x59c051&&_0x10936f['writer']['addClass']('ck-suggestion-marker--active',_0x5206e1),_0x10936f['writer']['insert'](_0x22fabc,_0x5206e1),_0x10936f['mapper']['bindElementToMarker'](_0x5206e1,_0x3a1f04['markerName']);}},{'priority':'high'}),this['editor']['model']['document']['on']('change',()=>{this['editor']['editing']['view']['change'](_0x432d92=>{for(const _0x20e622 of this['editor']['model']['document']['getRootNames']()){const _0x1a0d8d=this['editor']['model']['document']['getRoot'](_0x20e622),_0x7061f6=this['editor']['editing']['view']['document']['getRoot'](_0x20e622);if(_0x7061f6){const _0x21b2dd=_0x1a0d8d['getAttribute']('revisionHistoryAttachChange');if(_0x432d92['removeAttribute']('data-change-id',_0x7061f6),_0x432d92['removeClass']('ck-revision-history-root-add',_0x7061f6),_0x432d92['removeClass']('ck-revision-history-root-remove',_0x7061f6),_0x432d92['removeClass']('ck-revision-history-root--active',_0x7061f6),_0x21b2dd){const _0x4f29ac=this['_getChangeFromId'](_0x21b2dd);if(!_0x4f29ac)return null;_0x432d92['setAttribute']('data-change-id',_0x21b2dd,_0x7061f6),_0x432d92['addClass']('ck-revision-history-root-'+_0x4f29ac['type'],_0x7061f6),this['activeChange']==_0x4f29ac&&_0x432d92['addClass']('ck-revision-history-root--active',_0x7061f6);}}}});}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'comment','model':_0x3ac67e=>'revision-comment:'+_0x3ac67e,'converterPriority':'highest'}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'suggestion','model':_0xb8e05e=>'revision-suggestion:'+_0xb8e05e,'converterPriority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision-suggestion','view':_0x913603=>({'name':'suggestion:'+_0x913603,'group':'revision-suggestion'}),'converterPriority':'highest'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision-suggestion','view':_0x312133=>{const _0x2d55ee=_0x312133['markerName']['split'](':')[0x1];return'insertion'!=_0x2d55ee&&'deletion'!=_0x2d55ee?null:{'classes':['ck-suggestion-preview-marker','ck-suggestion-preview-marker-'+_0x2d55ee]};}}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:deletion',Q(this['editor'],'merge'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:insertion',Q(this['editor'],'split'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision-suggestion',(_0x303b7c,_0x1bc1fa,_0x7b79fc)=>{const _0x38af62=_0x7b79fc['mapper']['markerNameToElements'](_0x1bc1fa['markerName']);if(_0x38af62){for(const _0xb41c07 of _0x38af62)_0xb41c07['is']('uiElement')&&(_0x7b79fc['mapper']['unbindElementFromMarkerName'](_0xb41c07,_0x1bc1fa['markerName']),_0x7b79fc['writer']['remove'](_0xb41c07));}},{'priority':'high'});}['_getChangeFromId'](_0x456642){return this['_changeIdToChange']['get'](_0x456642);}['_getViewForChange'](_0x1ace83){return this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=new z(this['editor']['locale'],_0x1ace83),this['_changeView'];}['_initInteractions'](){this['editor']['model']['document']['selection']['observeMarkers']('revision'),this['on']('change:activeView',(_0xa743a4,_0x368694,_0x30b176,_0x53fd60)=>{_0x53fd60&&this['_balloon']['remove'](_0x53fd60),_0x30b176&&(this['_balloon']['add']({'view':_0x30b176,'stackId':'revisionHistoryLabel','position':{'target':()=>{const _0x242cb9=this['editor']['editing'],_0x11015d=this['_getChangeFromId'](_0x30b176['changeId']);let _0x29a324;if(_0x11015d['data']['isOnRoot']){const _0x44ab7b=_0x242cb9['view']['getDomRoot'](_0x11015d['rootName']);_0x29a324=Array['from'](_0x44ab7b['getClientRects']());}else{const _0xb59782=this['editor']['model']['markers']['get']('revision:'+_0x30b176['changeId']);_0x29a324=Array['from'](_0x242cb9['mapper']['markerNameToElements'](_0xb59782['name']))['map'](_0x402b65=>_0x242cb9['view']['domConverter']['mapViewToDom'](_0x402b65))['map'](_0x48387b=>Array['from'](_0x48387b['getClientRects']()))['flat']();}if(!this['_activeViewTarget'])return _0x29a324[0x0];return _0x29a324['find'](_0x260c85=>_0x260c85['top']-0x3<=this['_activeViewTarget']['y']&&_0x260c85['bottom']+0x3>=this['_activeViewTarget']['y']&&_0x260c85['left']-0x3<=this['_activeViewTarget']['x']&&_0x260c85['right']+0x3>=this['_activeViewTarget']['x'])||_0x29a324[0x0];}}}),this['_balloon']['showStack']('revisionHistoryLabel'));}),this['on']('change:activeChange',(_0xf281fd,_0x48a76a,_0x2698b3,_0x2ce6d4)=>{this['activeView']=_0x2698b3?this['_getViewForChange'](_0x2698b3):null,this['editor']['model']['change'](()=>{const _0x309ed8=this['editor']['editing'];_0x2ce6d4&&(_0x2ce6d4['data']['isOnRoot']?_0x309ed8['view']['change'](_0x67d60a=>{_0x67d60a['removeClass']('ck-revision-history-root--active',_0x309ed8['view']['document']['getRoot'](_0x2ce6d4['rootName']));}):_0x309ed8['reconvertMarker']('revision:'+_0x2ce6d4['id'])),_0x2698b3&&(_0x2698b3['data']['isOnRoot']?_0x309ed8['view']['change'](_0x4d93ee=>{_0x4d93ee['addClass']('ck-revision-history-root--active',_0x309ed8['view']['document']['getRoot'](_0x2698b3['rootName']));}):_0x309ed8['reconvertMarker']('revision:'+_0x2698b3['id']));});}),this['listenTo'](this['editor']['editing']['view']['document'],'mouseover',(_0x477090,_0x1c3c8f)=>{if(this['activeChange'])return;const _0x59c121=this['_findChangeIdFromDomTarget'](_0x1c3c8f['target']),_0x9439b0=this['_changeIdToChange']['get'](_0x59c121);_0x9439b0?(this['_activeViewTarget']={'x':_0x1c3c8f['domEvent']['x'],'y':_0x1c3c8f['domEvent']['y']},this['activeView']=this['_getViewForChange'](_0x9439b0)):(this['_activeViewTarget']=null,this['activeView']=null);}),this['listenTo'](this['editor']['editing']['view']['document'],'mousedown',(_0x169684,_0x5515ee)=>{const _0x5719c1=this['_findChangeIdFromDomTarget'](_0x5515ee['target']),_0x2a16c8=this['_changeIdToChange']['get'](_0x5719c1);_0x2a16c8?(this['_activeViewTarget']={'x':_0x5515ee['domEvent']['x'],'y':_0x5515ee['domEvent']['y']},_0x2a16c8===this['activeChange']?this['_balloon']['updatePosition']():this['activeChange']=_0x2a16c8):(this['_activeViewTarget']=null,this['activeChange']=null);});}['_findChangeIdFromDomTarget'](_0x351b32){do{const _0x4cbd32=_0x351b32['getAttribute']('data-change-id');if(_0x4cbd32)return _0x4cbd32;_0x351b32=_0x351b32['parent'];}while(_0x351b32);return null;}['_cleanMarkers'](){this['editor']['model']['change'](_0x35e31c=>{for(const _0x1bd807 of this['editor']['model']['markers'])_0x35e31c['removeMarker'](_0x1bd807);});}}function Q(_0x8cc761,_0x51858d){return(_0x2c02ae,_0x52832c,_0x41760b)=>{if(!_0x41760b['consumable']['test'](_0x52832c['markerRange'],_0x2c02ae['name']))return;const _0x35d578=_0x52832c['markerRange']['getWalker'](),_0x6bf622=_0x52832c['markerRange']['start'],_0x3fd574=_0x8cc761['model']['schema'];let _0x3ccd29=null,_0xee8518=null,_0xf8804e=!0x1,_0x54e929=!0x1;for(const _0x40665f of _0x35d578){const _0x45c161=_0x40665f['item'];_0xf8804e=_0xf8804e||_0x3fd574['isContent'](_0x45c161);const _0x8c419d=_0x41760b['mapper']['toViewElement'](_0x45c161);if(_0x8c419d&&_0x8c419d['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x40665f['type']&&(_0x3fd574['isBlock'](_0x45c161)&&!_0x3fd574['isLimit'](_0x45c161)&&(_0x45c161['nextSibling']||_0x6bf622['isAtEnd']?_0x3ccd29&&_0x3ccd29['parent']==_0x45c161||(_0x3ccd29=_0x45c161,_0x1c83cf(_0x40665f['previousPosition']),_0x54e929=!0x0):_0xee8518=_0xee8518||_0x40665f['previousPosition']));}function _0x1c83cf(_0x8029a9){const _0x340317=_0x41760b['mapper']['toViewPosition'](_0x8029a9),_0x180fd3=_0x41760b['writer']['createUIElement']('span',{'class':'ck-suggestion-preview-marker-'+_0x51858d});_0x41760b['writer']['insert'](_0x340317,_0x180fd3),_0x41760b['mapper']['bindElementToMarker'](_0x180fd3,_0x52832c['markerName']);}_0xf8804e||_0x54e929||!_0xee8518||_0x1c83cf(_0xee8518);};}class nt extends _0x3687d4{constructor(_0x437224){super(_0x437224);const _0x21f91c=_0x437224['plugins']['get'](u);this['affectsData']=!0x1,this['listenTo'](_0x21f91c,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x21f91c,'change:isEnabled',()=>this['refresh']());}['execute'](){const _0x44a737=this['editor'],_0x562cb9=_0x44a737['plugins']['get'](u),_0x181025=_0x562cb9['isReady']?_0x562cb9['diff']['newRevisionId']:null;_0x44a737['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x181025);}['refresh'](){const {isReady:_0x2bfc16,isEnabled:_0x5a9d38,repository:_0x3e8ca1,diff:_0x1f4b64}=this['editor']['plugins']['get'](u),_0x176d46=_0x1f4b64&&_0x3e8ca1['getLaterVisibleRevision'](_0x1f4b64['newRevisionId']);this['isEnabled']=_0x2bfc16&&_0x5a9d38&&Boolean(_0x176d46);}}class rt extends _0x3687d4{['_step'];constructor(_0x36f290,{direction:_0x569451}){super(_0x36f290);const _0x5846dd=_0x36f290['plugins']['get'](u);this['affectsData']=!0x1,this['_step']='forward'===_0x569451?0x1:-0x1,this['listenTo'](_0x5846dd,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x5846dd,'change:isEnabled',()=>this['refresh']()),this['listenTo'](_0x5846dd,'change:activeChange',()=>this['refresh']());}['execute'](){const _0x434649=this['editor'],_0x570733=_0x434649['plugins']['get'](u),{isNavigationMode:_0x51a5b8,currentChangeNumber:_0x2c0336}=_0x570733;let _0xdd603e;if(_0x570733['activeChange']=_0x51a5b8?_0x570733['diff']['changes']['get'](_0x2c0336+this['_step']):_0x570733['diff']['changes']['first'],_0x570733['activeChange']['data']['isOnRoot'])_0xdd603e=_0x434649['editing']['view']['getDomRoot'](_0x570733['activeChange']['rootName']);else{const _0x470fd6=_0x434649['model']['markers']['get']('revision:'+_0x570733['activeChange']['id']);_0xdd603e=_0x37341c(_0x434649['editing'],_0x470fd6);}_0x57502f({'target':_0xdd603e,'viewportOffset':0x28});}['refresh'](){const {isNavigationMode:_0x26dccd,currentChangeNumber:_0x1839e5,numberOfChanges:_0x1c5ec4,isReady:_0x24cf91,isEnabled:_0x336776}=this['editor']['plugins']['get'](u);this['isEnabled']=!!(_0x336776&&_0x24cf91&&_0x1c5ec4)&&(!_0x26dccd||(0x1===this['_step']?_0x1839e5<_0x1c5ec4-0x1:_0x1839e5>0x0));}}class Ri extends _0x5f53a2{constructor(_0x5a6c83){super(_0x5a6c83);const _0x2b1351=this['bindTemplate'],_0x3ce004=new _0x5108a7(_0x5a6c83),_0x17797f=new _0x5108a7(_0x5a6c83);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',(_0x3a3c50,_0x3ef14a)=>_0x3a3c50&&_0x3ef14a>0x0),this['bind']('_statusText')['to'](this,'isReady',this,'currentChangeNumber',this,'numberOfChanges',this,'isNavigationMode',(_0x14e9b0,_0x2d0b77,_0x1263b5,_0x437974)=>{if(!_0x14e9b0)return m(_0x5a6c83,'Loading...');if(!_0x1263b5)return m(_0x5a6c83,'No\x20changes');const _0x4ab1fc=m(_0x5a6c83,'NUMBER_OF_CHANGES',_0x1263b5);return _0x437974?m(_0x5a6c83,'X_OF_Y_CHANGES',[_0x2d0b77+0x1,_0x1263b5]):_0x4ab1fc;}),_0x3ce004['set']({'label':m(_0x5a6c83,'Show\x20previous\x20change'),'tooltip':!0x0,'icon':_0x592aca}),_0x17797f['set']({'label':m(_0x5a6c83,'Show\x20next\x20change'),'tooltip':!0x0,'icon':_0x31f17d}),_0x3ce004['bind']('isEnabled')['to'](this,'isBackwardNavigationEnabled'),_0x17797f['bind']('isEnabled')['to'](this,'isForwardNavigationEnabled'),_0x3ce004['on']('execute',()=>this['fire']('execute','backward')),_0x17797f['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',_0x2b1351['if']('_isStatusLabelVisible','ck-hidden',_0x255f1f=>!_0x255f1f)]},'children':[{'text':_0x2b1351['to']('isNavigationMode',_0x21b1ab=>_0x21b1ab?m(_0x5a6c83,'EDIT_X_OF_Y_REVISIONS')+':\x20':m(_0x5a6c83,'Total')+':\x20')}]},{'text':_0x2b1351['to']('_statusText')}]},new _0x3f3ce6(),{'tag':'div','attributes':{'class':['ck-revision-history-ui__changes-navigation__navigation']},'children':[_0x3ce004,_0x17797f]}]});}}const ge='ck-editor__editable__loading-overlay';class ji extends _0x439397{static get['pluginName'](){return'RevisionViewerLoadingOverlay';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['show'](){const _0x58fec0=this['editor']['editing']['view'];_0x58fec0['change'](_0x5e366d=>{for(const _0x29b228 of _0x58fec0['document']['roots'])_0x5e366d['addClass'](ge,_0x29b228);});}['hide'](){const _0x4c0a8c=this['editor']['editing']['view'];_0x4c0a8c['change'](_0xb6ecb0=>{for(const _0x115afc of _0x4c0a8c['document']['roots'])_0xb6ecb0['removeClass'](ge,_0x115afc);});}}class v extends _0x439397{static get['pluginName'](){return'RevisionViewerUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[u,ji];}['init'](){const _0x52ce24=this['editor'],_0x77aff3=_0x52ce24['plugins']['get'](u),_0x42db88=_0x52ce24['plugins']['get'](ji);_0x52ce24['ui']['componentFactory']['add']('exitToEditing',_0x2bdc7f=>{const _0x3d4cc0=new _0x5108a7(_0x2bdc7f);return _0x3d4cc0['set']({'label':m(_0x2bdc7f,'Back\x20to\x20editing'),'icon':_0x4f5970,'withText':!0x0,'tooltip':!0x0,'class':'ck-revision-history-ui__back-to-editing'}),this['listenTo'](_0x3d4cc0,'execute',()=>{_0x52ce24['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}),_0x3d4cc0;}),_0x52ce24['ui']['componentFactory']['add']('restoreRevision',_0x4b05a7=>{const _0x140563=new _0x5108a7(_0x4b05a7);return _0x140563['set']({'label':m(_0x4b05a7,'Restore\x20this\x20revision'),'withText':!0x0,'tooltip':!0x0}),_0x140563['bind']('isEnabled')['to'](_0x52ce24['commands']['get']('restoreRevision')),this['listenTo'](_0x140563,'execute',()=>_0x52ce24['execute']('restoreRevision')),_0x140563;}),_0x52ce24['ui']['componentFactory']['add']('changesNavigation',_0x43e096=>{const _0x361444=new Ri(_0x43e096),_0xcc2cdd=_0x52ce24['commands']['get']('showPreviousChange'),_0x2006ce=_0x52ce24['commands']['get']('showNextChange');return _0x361444['bind']('isBackwardNavigationEnabled')['to'](_0xcc2cdd,'isEnabled'),_0x361444['bind']('isForwardNavigationEnabled')['to'](_0x2006ce,'isEnabled'),_0x361444['bind']('isReady','currentChangeNumber','numberOfChanges','isNavigationMode')['to'](_0x77aff3),this['listenTo'](_0x361444,'execute',(_0x3f1ef1,_0x5ef24d)=>{_0x52ce24['execute']('forward'===_0x5ef24d?'showNextChange':'showPreviousChange');}),_0x361444;}),_0x42db88['show'](),_0x77aff3['on']('change:isReady',(_0x2dee9f,_0x64f9c5,_0xb83149)=>{_0xb83149?_0x42db88['hide']():_0x42db88['show']();});}}class hi extends et{['_resizeObserver']=null;constructor(_0x45074a,_0x5516a4){super(_0x45074a,_0x5516a4);const _0x4c44ae=this['bindTemplate'];this['set']({'label':m(_0x45074a,'Revision\x20name'),'_tooltipString':''}),this['fieldView']['placeholder']=m(_0x45074a,'Enter\x20the\x20revision\x20name'),this['extendTemplate']({'tag':'span','attributes':{'class':['ck-revision-history-sidebar__revision-name'],'data-cke-tooltip-text':_0x4c44ae['to']('_tooltipString'),'data-cke-tooltip-position':'s','data-cke-tooltip-class':'ck-tooltip_multi-line'}});}['render'](){super['render'](),this['_resizeObserver']=new ot(this['fieldView']['element'],()=>this['_updateTooltipText']()),this['listenTo'](this['fieldView'],'input',()=>this['_updateTooltipText']());}['destroy'](){super['destroy'](),this['_resizeObserver']&&this['_resizeObserver']['destroy']();}['_updateTooltipText'](){const _0x16b933=this['fieldView']['element'];this['_tooltipString']=_0x16b933['scrollWidth']>_0x16b933['clientWidth']&&_0x16b933['value']||'';}}class ni extends _0x5f53a2{constructor(_0x4d69f2,_0x20e821,_0x5a9d4d){super(_0x4d69f2);const _0x21e0bb=new _0x243002();_0x21e0bb['set']({'content':_0x24ea6a,'viewBox':'0\x200\x2011\x2010'});const _0x122f95=['ck','ck-revision-history-sidebar__revision-author'];_0x5a9d4d&&_0x122f95['push']('ck-revision-history-sidebar__revision-author_creator');const _0x1582b5=[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision-author__name'],'title':m(_0x4d69f2,_0x5a9d4d?'Revision\x20creator':'Revision\x20author')},'children':[_0x21e0bb,_0x20e821['name']]}];this['setTemplate']({'tag':'li','attributes':{'class':_0x122f95},'children':_0x1582b5});}}function ai(_0xe8a835,_0x4ee62b){const _0x4cd15f=_0xe8a835['bindTemplate'],_0x3f0005=_0xe8a835['locale'],_0x402f9b=_0x488b40(_0x3f0005);_0x402f9b['panelPosition']='sw';const _0x3425c5=function(_0x11c4b4,_0x117dcd){const _0x1eb95b=function(_0x2ce67b,_0xc69ce1){const _0xb4a546=_0x2ce67b['locale'],_0x49131f={'Compare\x20against\x20selected':m(_0xb4a546,'Compare\x20against\x20selected'),'Name\x20this\x20revision':m(_0xb4a546,'Name\x20this\x20revision'),'Restore\x20this\x20revision':m(_0xb4a546,'Restore\x20this\x20revision')};return _0xc69ce1['map'](_0x15bfed=>{const _0xc020dc=_0x49131f[_0x15bfed['name']];return _0xc020dc&&_0xc020dc!==_0x15bfed['name']&&(_0x15bfed['name']=_0xc020dc),_0x15bfed;});}(_0x11c4b4,_0x117dcd),_0x50d36a=new _0x480dd0();for(const _0x28b062 of _0x1eb95b){const _0x41e2eb={'type':'button','model':new to({'label':_0x28b062['name'],'class':_0x28b062['class'],'withText':!0x0,'role':'menuitem','_action':_0x28b062['action']})};_0x41e2eb['model']['bind']('isEnabled')['to'](_0x11c4b4,'isActionsDropdownOpen',_0x4540d1=>'function'!=typeof _0x28b062['isEnabled']||(!_0x4540d1||_0x28b062['isEnabled'](_0x11c4b4))),_0x50d36a['add'](_0x41e2eb);}return _0x50d36a;}(_0xe8a835,_0x4ee62b);return _0xe8a835['bind']('isActionsDropdownOpen')['to'](_0x402f9b,'isOpen'),_0x402f9b['buttonView']['set']({'label':m(_0x3f0005,'Show\x20more\x20items'),'tooltip':!0x0,'tooltipPosition':'sw','icon':_0x2761e7}),_0x402f9b['extendTemplate']({'attributes':{'class':['ck-revision-history-sidebar__revision__actions',_0x4cd15f['if']('isActionsDropdownOpen','ck-on')]},'on':{'click':_0x4cd15f['to'](_0x4abc2e=>_0x4abc2e['stopPropagation']())}}),_0x402f9b['on']('execute',_0xdc5279=>{_0xe8a835['isReady']&&'function'==typeof _0xdc5279['source']['_action']&&_0xdc5279['source']['_action'](_0xe8a835);}),_0x150c07(_0x402f9b,_0x3425c5,{'role':'menu'}),_0x402f9b['listenTo'](_0xe8a835,'change:isActionsDropdownOpen',(_0x3a9b38,_0x1dcb1e,_0x237a00)=>{if(_0x237a00)for(const _0x12e62f of _0x402f9b['listView']['items']){const _0xe3bf4c=_0x12e62f['children']['first'],_0x3a84fb=_0x4ee62b['find'](_0x372719=>_0x372719['action']===_0xe3bf4c['_action'])['isVisible'];_0x12e62f['isVisible']=void 0x0===_0x3a84fb||_0x3a84fb(_0xe8a835);}}),_0x402f9b;}class _i extends/* #__PURE__ -- @preserve */
27
+ _0xd98c6c(_0x5f53a2){['id'];['revisionNameView'];['revisionActionsView'];['_revision'];['_requireRevisionName'];constructor(_0x2cf418,_0xf9ff72,_0x56389e,_0x3af789){super(_0x2cf418);const _0x2cd522=this['bindTemplate'],_0x38ffd3=function(_0x3d4cfe,_0x5e1baf){const _0x1a5203=Array['from'](_0x5e1baf['authors'])['filter'](_0x1aab1b=>_0x1aab1b!=_0x5e1baf['creator']);return _0x5e1baf['creator']&&_0x1a5203['unshift'](_0x5e1baf['creator']),_0x1a5203['map'](_0x4cbcfb=>new ni(_0x3d4cfe,_0x4cbcfb,_0x4cbcfb==_0x5e1baf['creator']));}(_0x2cf418,_0xf9ff72);this['id']=_0xf9ff72['id'],this['_revision']=_0xf9ff72,this['_requireRevisionName']=_0x3af789,this['bind']('name','createdAt')['to'](_0xf9ff72),this['bind']('_createdAtFormatted')['to'](this,'createdAt',_0x31f907=>{return _0x4ef5f2=_0x2cf418['uiLanguage'],(_0x2e8214=_0x31f907)['toLocaleDateString'](_0x4ef5f2,{'month':'long','day':'numeric'})+',\x20'+_0x2e8214['toLocaleTimeString'](_0x4ef5f2,{'hour':'numeric','minute':'numeric'});var _0x4ef5f2,_0x2e8214;}),this['set']('isSelected',!0x1),this['set']('isHighlighted',!0x1),this['set']('isActionsDropdownOpen',!0x1),this['set']('isReady',!0x1),this['set']('isEnabled',!0x1),this['revisionNameView']=new hi(_0x2cf418,ti),this['revisionNameView']['fieldView']['extendTemplate']({'attributes':{'maxlength':'220'}}),this['revisionNameView']['fieldView']['bind']('value')['to'](this,'name',_0x47646f=>_0x47646f||this['_createdAtFormatted']),this['revisionNameView']['bind']('isEnabled')['to'](this,'isSelected',this,'isEnabled',(_0x4bee92,_0x136073)=>_0x4bee92&&_0x136073),this['revisionActionsView']=_0x56389e&&_0x56389e['length']?ai(this,_0x56389e):'',this['revisionActionsView']&&this['revisionActionsView']['bind']('isEnabled')['to'](this),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision-wrapper',_0x2cd522['if']('isConfirm','ck-revision-history-sidebar__revision-wrapper_confirmation_visible')]},'children':[{'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision',_0x2cd522['if']('isEnabled','ck-disabled',_0x27b36e=>!_0x27b36e),_0x2cd522['if']('isSelected','ck-revision-history-sidebar__revision_selected'),_0x2cd522['if']('isHighlighted','ck-revision-history-sidebar__revision_highlighted'),_0x2cd522['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':_0x2cd522['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':_0x38ffd3}]},this['revisionActionsView']],'on':{'click':_0x2cd522['to'](_0x56d67a=>{_0x56d67a['srcElement']['closest']('.ck-confirm-view')||this['isReady']&&this['isEnabled']&&this['fire']('select',{'id':this['id']});})}}]});}['render'](){super['render']();const _0x33b0a0=this['revisionNameView']['fieldView']['element'];this['listenTo'](_0x33b0a0,'change',()=>{this['_requireRevisionName']&&!_0x33b0a0['value']||this['fire']('setName',{'id':this['id'],'name':_0x33b0a0['value']}),_0x33b0a0['value']||(_0x33b0a0['value']=this['name']?this['name']:this['_createdAtFormatted']);});}['select'](){this['isSelected']=!0x0;}['deselect'](){this['isSelected']=!0x1;}['highlight'](){this['isHighlighted']=!0x0;}['unhighlight'](){this['isHighlighted']=!0x1;}}function li(_0x764ced,_0x865f96){const _0x412c6e=_0x271ae0['fromJSDate'](_0x764ced)['setLocale'](_0x865f96),_0x364c2f=_0x271ae0['local'](),_0x1e3276=_0x364c2f['minus']({'days':0x1})['startOf']('day');let _0x5ee849,_0x1a2fe4;return _0x412c6e['hasSame'](_0x364c2f,'day')?(_0x5ee849=_0x412c6e['startOf']('day')['toJSDate'](),_0x1a2fe4=_0x412c6e['toRelativeCalendar']()):_0x412c6e['hasSame'](_0x1e3276,'day')?(_0x5ee849=_0x1e3276['toJSDate'](),_0x1a2fe4=_0x412c6e['toRelativeCalendar']()):_0x412c6e['hasSame'](_0x364c2f,'week')?(_0x5ee849=_0x412c6e['startOf']('week')['toJSDate'](),_0x1a2fe4=_0x412c6e['weekdayLong']||''):_0x412c6e['hasSame'](_0x364c2f,'year')?(_0x5ee849=_0x412c6e['startOf']('month')['toJSDate'](),_0x1a2fe4=_0x412c6e['monthLong']||''):(_0x5ee849=_0x412c6e['startOf']('year')['toJSDate'](),_0x1a2fe4=String(_0x412c6e['year'])),{'startDate':_0x5ee849,'localizedPeriodName':_0x1a2fe4};}class bi extends _0x5f53a2{['startDate'];['revisionViews'];['_revisionActions'];['_requireRevisionName'];constructor(_0x388257,_0x3d7060,_0x5ab8f4,_0x34a664){super(_0x388257);const _0x7d5782=li(_0x3d7060,this['locale']['uiLanguage'])['localizedPeriodName'];this['startDate']=_0x3d7060,this['revisionViews']=this['createCollection'](),this['_revisionActions']=_0x5ab8f4,this['_requireRevisionName']=_0x34a664,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':_0x7d5782}]},{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__time-period__revisions']},'children':this['revisionViews']}]});}['addRevision'](_0x326f87){const _0x3b0a98=new _i(this['locale'],_0x326f87,this['_revisionActions'],this['_requireRevisionName']);this['revisionViews']['add'](_0x3b0a98);}['removeRevision'](_0x29ad3c){const _0xba16f6=this['revisionViews']['find'](_0x16be32=>_0x16be32['id']===_0x29ad3c['id']);this['revisionViews']['remove'](_0xba16f6);}}class fi extends _0x5f53a2{constructor(_0x1c1641){super(_0x1c1641);const _0x2547be=new _0x243002();_0x2547be['content']=_0x5d69e0,this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset_all','ck-revision-history-sidebar__header']},'children':[_0x2547be,{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__header__label']},'children':[m(_0x1c1641,'Revision\x20history')]}]});}}class di extends _0x5f53a2{['timePeriodViews'];['_revisions'];['_revisionActions'];['_requireRevisionName'];constructor(_0x44464c,_0x2d8624,_0x2bbaaf,_0x13e327){super(_0x44464c);const _0x303b0c=this['bindTemplate'];this['timePeriodViews']=this['createCollection'](),this['timePeriodViews']['delegate']('select')['to'](this),this['timePeriodViews']['delegate']('setName')['to'](this),this['_revisions']=_0x2d8624,this['_revisionActions']=_0x2bbaaf,this['_requireRevisionName']=_0x13e327,this['on']('select',(_0xf77266,_0x4b118a)=>{this['fire']('revisionSelected',_0x4b118a);}),this['on']('setName',(_0x321094,_0x1adb62)=>{this['fire']('revisionSetName',_0x1adb62);}),this['set']('isEnabled',!0x1),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-rounded-corners','ck-revision-history-sidebar']},'children':[new fi(_0x44464c),{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__timeline',_0x303b0c['if']('isEnabled','ck-disabled',_0x384339=>!_0x384339)]},'children':this['timePeriodViews']}]});}['render'](){super['render']();for(const _0x4cd11c of this['_revisions'])this['_addRevision'](_0x4cd11c);this['_revisions']['on']('add',(_0x317351,_0x5337b5)=>{this['_addRevision'](_0x5337b5);}),this['_revisions']['on']('remove',(_0x52cc95,_0x57ce4c)=>{this['_removeRevision'](_0x57ce4c);});}get['revisionViews'](){return this['timePeriodViews']['map'](_0x5b70e7=>_0x5b70e7['revisionViews']['map'](_0xe122d7=>_0xe122d7))['flat']();}['selectRevision'](_0x466d52){for(const _0x4505a3 of this['revisionViews'])_0x466d52&&_0x466d52['id']===_0x4505a3['id']?_0x4505a3['select']():_0x4505a3['deselect']();}['highlightRevisions'](_0x35f4d5){for(const _0x2169eb of this['revisionViews'])_0x35f4d5['some'](({id:_0x119af9})=>_0x119af9===_0x2169eb['id'])?_0x2169eb['highlight']():_0x2169eb['unhighlight']();}['_addRevision'](_0x2acfdb){const _0x4aa2a9=li(_0x2acfdb['createdAt'],this['locale']['uiLanguage'])['startDate'];let _0x8e4a7c=this['timePeriodViews']['get'](0x0);_0x8e4a7c&&_0x8e4a7c['startDate']['getTime']()===_0x4aa2a9['getTime']()||(_0x8e4a7c=new bi(this['locale'],_0x4aa2a9,this['_revisionActions'],this['_requireRevisionName']),this['timePeriodViews']['add'](_0x8e4a7c)),_0x8e4a7c['addRevision'](_0x2acfdb);}['_removeRevision'](_0x12c630){const _0x55bfea=li(_0x12c630['createdAt'],this['locale']['uiLanguage'])['startDate'];this['_getTimePeriodViewByStartDate'](_0x55bfea)['removeRevision'](_0x12c630);}['_getTimePeriodViewByStartDate'](_0x3f45e7){return this['timePeriodViews']['find'](_0x496cf3=>_0x496cf3['startDate']['getTime']()===_0x3f45e7['getTime']());}}class d extends _0x439397{['_revisionViewer'];['_revisionsRepository'];['_sidebarView'];static ['defaultRevisionActions']=/* #__PURE__ -- @preserve */
28
28
  ((()=>['compareAgainstSelected','restoreRevision','nameRevision'])());static ['availableRevisionActions']=/* #__PURE__ -- @preserve */
29
- at();static get['pluginName'](){return'RevisionsSidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[u];}constructor(_0x188e00){super(_0x188e00),this['_revisionViewer']=_0x188e00['plugins']['get'](u),this['_revisionsRepository']=this['_revisionViewer']['repository'],this['_sidebarView']=null;}['init'](){const _0x3ad1e7=this['_revisionsRepository']['_revisions'],_0x246d0=this['_createRevisionActions'](),_0x39978b=this['editor']['config']['get']('revisionHistory.viewerSidebarContainer');this['_sidebarView']=new di(this['editor']['locale'],_0x3ad1e7,_0x246d0,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',(_0x4b660c,_0x502056)=>{_0x502056['revisionViews']['on']('add',(_0x1ca9da,_0x5ce14b)=>{_0x5ce14b['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)),_0x39978b['appendChild'](this['_sidebarView']['element']);}['destroy'](){this['_sidebarView']['element']['remove'](),this['_sidebarView']['destroy']();}['_handleEditorDataReady'](){const _0x3fe3cd=this['_revisionsRepository']['getRevision'](0x0);if(_0x3fe3cd){const _0x39acce=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x3fe3cd['id']);this['_revisionViewer']['compare'](_0x3fe3cd,_0x39acce);}}['_handleRevisionSelected'](_0x10f070,_0x57f0a5){const _0x31be77=this['_revisionsRepository']['getRevision'](_0x57f0a5['id']),_0x19271e=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x31be77['id']);this['_revisionViewer']['compare'](_0x31be77,_0x19271e);}['_handleRevisionSetName'](_0x4d4118,_0x3b8fcd){this['_revisionsRepository']['getRevision'](_0x3b8fcd['id'])['setName'](_0x3b8fcd['name']);}['_handleDiffChange'](_0x59ed8c,_0x253d65,_0xb6c8b1){const _0x55104a=this['_revisionsRepository']['getRevisionsInDiff'](_0xb6c8b1);_0x55104a['length']>0x2?(this['_sidebarView']['highlightRevisions'](_0x55104a),this['_sidebarView']['selectRevision'](null)):(this['_sidebarView']['highlightRevisions']([]),this['_sidebarView']['selectRevision'](_0x55104a[0x0]));}['_createRevisionActions'](){const _0x4e4561=this['editor'],_0x572d2d=d['availableRevisionActions'],_0x1b1872=_0x4e4561['config']['get']('revisionHistory.revisionActions')||d['defaultRevisionActions'];if(_0x1b1872['length'])return _0x1b1872['map'](_0x2979b5=>{const _0x4a65fa='string'==typeof _0x2979b5?Object['assign']({},_0x572d2d[_0x2979b5]):_0x2979b5;return _0x4a65fa['action']=_0x4a65fa['action']['bind'](this,_0x4e4561),_0x4a65fa['isVisible']&&(_0x4a65fa['isVisible']=_0x4a65fa['isVisible']['bind'](this,_0x4e4561)),_0x4a65fa;});}}function at(){return{'compareAgainstSelected':{'name':'Compare\x20against\x20selected','action':({plugins:_0x55faa6},_0x10199a)=>{const _0x33c03f=_0x55faa6['get'](u),_0xafd265=_0x33c03f['repository'];let _0x3ac8be=_0x33c03f['diff']['newRevisionId'],_0x84019a=_0x10199a['id'];_0xafd265['getIndex'](_0x3ac8be)>_0xafd265['getIndex'](_0x84019a)&&([_0x3ac8be,_0x84019a]=[_0x84019a,_0x3ac8be]),_0x33c03f['compare'](_0x3ac8be,_0x84019a);},'isVisible':({plugins:_0x437b11},_0x1b3a30)=>{const _0x1e4189=_0x437b11['get'](u);return!(_0x1e4189['repository']['getRevisionsInDiff'](_0x1e4189['diff'])['length']>0x2)&&!_0x1b3a30['isSelected'];}},'restoreRevision':{'name':'Restore\x20this\x20revision','action':(_0x39a000,{id:_0x358041})=>{_0x39a000['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x358041);},'isVisible':({plugins:_0x481b8a},_0x56e168)=>!!_0x481b8a['get'](u)['repository']['getLaterVisibleRevision'](_0x56e168['id'])},'nameRevision':{'name':'Name\x20this\x20revision','action':({plugins:_0x5b0a03},{id:_0x4d02d6,revisionNameView:_0xe38bba})=>{const _0x2512e5=_0x5b0a03['get'](u),_0x184360=_0x2512e5['repository']['getEarlierVisibleRevision'](_0x4d02d6);_0x2512e5['compare'](_0x4d02d6,_0x184360),_0xe38bba['focus'](),_0xe38bba['fieldView']['select']();}}};}class Z extends tt{['_view'];['_toolbarConfig'];['_elementReplacer'];get['view'](){return this['_view'];}constructor(_0x3ecf18,_0x99150f){super(_0x3ecf18),this['_view']=_0x99150f,this['_toolbarConfig']=st(_0x3ecf18['config']['get']('toolbar')),this['_elementReplacer']=new it();}get['element'](){return this['view']['element'];}['init'](_0x54b21b){const _0xa0a925=this['editor'],_0x4a7f49=this['view'],_0x2c8b15=_0xa0a925['editing']['view'],_0x1fe545=_0x4a7f49['editable'],_0x470229=_0x2c8b15['document']['getRoot']();_0x1fe545['name']=_0x470229['rootName'],_0x4a7f49['render']();const _0x52c820=_0x1fe545['element'];this['setEditableElement'](_0x1fe545['name'],_0x52c820),_0x4a7f49['editable']['bind']('isFocused')['to'](this['focusTracker']),_0x2c8b15['attachDomRoot'](_0x52c820),this['_elementReplacer']['replace'](_0x54b21b,this['element']),this['_initToolbar'](),this['fire']('ready');}['destroy'](){super['destroy']();const _0xabb9a9=this['view'],_0x5cbfff=this['editor']['editing']['view'];this['_elementReplacer']['restore'](),_0x5cbfff['detachDomRoot'](_0xabb9a9['editable']['name']),_0xabb9a9['destroy']();}['_initToolbar'](){const _0x761599=this['view'];_0x761599['stickyPanel']['bind']('isActive')['to'](this['focusTracker'],'isFocused'),_0x761599['stickyPanel']['limiterElement']=_0x761599['element'],_0x761599['stickyPanel']['bind']('viewportTopOffset')['to'](this,'viewportOffset',({top:_0x42e343})=>_0x42e343),_0x761599['toolbar']['fillFromConfig'](this['_toolbarConfig'],this['componentFactory']),this['addToolbar'](_0x761599['toolbar']);}}class ii extends _0xa1fcad{['_editable'];['stickyPanel'];['toolbar'];get['editable'](){return this['_editable'];}constructor(_0x29914e,_0x117e17,_0x40b733={}){super(_0x29914e),this['stickyPanel']=new _0x90e838(_0x29914e),this['toolbar']=new _0x293c23(_0x29914e,{'shouldGroupWhenFull':_0x40b733['shouldToolbarGroupWhenFull']}),this['_editable']=new te(_0x29914e,_0x117e17);}['render'](){super['render'](),this['stickyPanel']['content']['add'](this['toolbar']),this['top']['add'](this['stickyPanel']),this['main']['add'](this['editable']);}}class f extends/* #__PURE__ -- @preserve */
30
- _0x43cb1a(_0x42df48){['_ui'];get['ui'](){return this['_ui'];}constructor(_0x1afa98,_0x343ba3){super(_0x343ba3),this['sourceElement']=_0x1afa98,this['model']['document']['createRoot']();const _0xa75a4f=new ii(this['locale'],this['editing']['view'],{'shouldToolbarGroupWhenFull':!0x0});this['_ui']=new Z(this,_0xa75a4f);}['destroy'](){return this['updateSourceElement'](),this['ui']['destroy'](),super['destroy']();}static async['create'](_0x204979,_0x2e3ec4){const _0x3f6034=new this(_0x204979,_0x2e3ec4);return await _0x3f6034['initPlugins'](),await _0x3f6034['ui']['init'](_0x204979),await _0x3f6034['data']['init'](_0x3f6034['config']['get']('initialData')||''),_0x3f6034['fire']('ready'),_0x3f6034;}}const p=['RevisionHistoryUI','RestrictedEditingMode','AIChat','AIReviewMode','AIBalloon','AIQuickActions','AIActions'];class ht extends _0x17be55{['result'];static get['pluginName'](){return'RevisionViewerIntegration';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x5e6abe){function _0x10eaaa(_0x56e5ae){return _0x56e5ae['map'](_0x11f01d=>String['fromCharCode'](_0x11f01d))['join']('');}super(_0x5e6abe),this['result']='end',_0x5e6abe[_0x10eaaa([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x10eaaa([0x76,0x69,0x65,0x77])][_0x10eaaa([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x10eaaa([0x61,0x75,0x74,0x6f]),_0x5e6abe[_0x10eaaa([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x10eaaa([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x10eaaa([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x10eaaa([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x10eaaa([0x6f,0x6b])});}}class ct extends _0x17be55{['_viewerEditor'];static get['pluginName'](){return'RevisionHistory';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[h,l];}constructor(_0x3dde55){if(super(_0x3dde55),!this['editor']['config']['get']('revisionHistory'))throw new _0x4119b6('revision-history-missing-configuration',this);this['_viewerEditor']=null,this['set']('isRevisionViewerOpen',!0x1),this['editor']['config']['define']('revisionHistory.showRevisionViewerCallback',_0x2ac3a8=>this['_showRevisionViewer']({..._0x2ac3a8,'translations':this['editor']['locale']['translations']})),this['editor']['config']['define']('revisionHistory.closeRevisionViewerCallback',_0xf5d0e5=>this['_closeRevisionViewer'](_0xf5d0e5)),this['editor']['config']['define']('revisionHistory.restoreRevisionCallback',_0x3b8087=>this['_restoreRevision'](_0x3b8087)),this['editor']['config']['define']('revisionHistory.requireRevisionName',!0x1),this['_enhanceShowRevisionViewerCallback'](),this['_enhanceCloseRevisionViewerCallback']();}set['adapter'](_0x3ec56e){this['editor']['plugins']['get']('RevisionTracker')['adapter']=_0x3ec56e;}get['adapter'](){return this['editor']['plugins']['get']('RevisionTracker')['adapter'];}['addRevisionData'](_0x35a19c){return this['editor']['plugins']['get']('RevisionTracker')['addRevisionData'](_0x35a19c);}['getRevision'](_0x136e0e){return this['editor']['plugins']['get']('RevisionsRepository')['getRevision'](_0x136e0e);}['getRevisions'](_0x2975f2){return this['editor']['plugins']['get']('RevisionsRepository')['getRevisions'](_0x2975f2||{'toJSON':!0x1});}['_getRevisionViewerEditorConfig'](){const _0x43cf53=this['editor'],_0x1dcc22=_0x4f9702(_0x43cf53,p),_0x38dab7=_0x43cf53['plugins']['get']('RevisionTracker'),_0x1b2159=_0x43cf53['plugins']['get']('Users')['users'];return _0x1dcc22['toolbar']=['exitToEditing','restoreRevision','changesNavigation'],delete _0x1dcc22['lazyRoots'],(_0x1dcc22['plugins']['push'](ht,u,v,class extends _0x17be55{static get['requires'](){return[u,'Users'];}['init'](){const _0x6c3412=this['editor']['plugins']['get']('Users');for(const _0x2753d9 of _0x1b2159)_0x2753d9['isAnonymous']||_0x6c3412['getUser'](_0x2753d9['id'])||_0x6c3412['addUser'](_0x2753d9);const _0xf00911=_0x38dab7['repository']['getRevisions']();let _0x42ec65=null;const _0x16587c=this['editor']['plugins']['get']('RevisionViewer');_0x16587c['adapter']=_0x38dab7['adapter'],_0x16587c['bind']('isEnabled')['to'](_0x38dab7),this['editor']['commands']['get']('restoreRevision')['bind']('isEnabled')['to'](_0x43cf53,'isReadOnly',_0x571455=>!_0x571455);for(const _0x168a63 of _0xf00911){const _0x2a1de3=null===_0x168a63['creator'];if(_0x2a1de3&&_0x168a63['toVersion']===_0x168a63['fromVersion'])continue;const _0x17b370=_0x168a63['toJSON']();_0x16587c['addRevisionData'](_0x17b370,(_0x37ec40,_0x281185,_0x2823d8)=>{if(_0x2a1de3){if(_0x42ec65)_0x42ec65['_update'](_0x37ec40,_0x281185);else{if(!_0x281185){const _0x394ce0=_0x2823d8['toJSON']();_0x394ce0['id']=_0x356b12(),_0x38dab7['saveRevision'](_0x394ce0,_0x2823d8['toVersion'])['then'](_0x3779f8=>{_0x42ec65=_0x3779f8;});}}}else _0x168a63['_update'](_0x37ec40,_0x281185);});}}},d),_0x1dcc22);}['_enhanceShowRevisionViewerCallback'](){const _0x5d8462=this['editor']['config']['get']('revisionHistory')['showRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.showRevisionViewerCallback',async()=>{this['editor']['enableReadOnlyMode']('revision-history-viewer-opened');const _0x4a6144=this['editor']['plugins']['get']('RevisionTracker');if(this['editor']['plugins']['has']('Autosave')){const _0x1b6b52=this['editor']['plugins']['get']('Autosave');await _0x1b6b52['save']();}else await _0x4a6144['update']();if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('Dialog')){const _0x3614b6=this['editor']['plugins']['get']('Dialog');_0x3614b6['isOpen']&&_0x3614b6['hide']();}if(this['editor']['plugins']['has']('AITabs')){const _0x5b6a44=this['editor']['plugins']['get']('AITabs')['view']['panelViews'];for(const _0x55a031 of _0x5b6a44)_0x55a031['class']=_0x55a031['class']?_0x55a031['class']+'\x20ck-tab-panel_disabled':'ck-tab-panel_disabled';if(this['editor']['plugins']['has']('AIChat')){const _0x194fbf=document['querySelector']('.ck-ai-chat__prompt-input\x20.ck-textarea');_0x194fbf&&_0x194fbf['setAttribute']('tabindex','-1');}if(this['editor']['plugins']['has']('AIChatHistory')){const _0x4ea555=document['querySelector']('.ck-ai-chat-history\x20.ck-input');_0x4ea555&&_0x4ea555['setAttribute']('tabindex','-1');}}const _0x28b2f4=this['_getRevisionViewerEditorConfig']();return _0x5d8462(_0x28b2f4)['then'](_0x2c3636=>{return(this['_viewerEditor']=_0x2c3636,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'),_0x2c3636);})['catch'](_0x50899f=>(console['error'](_0x50899f),this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),null));});}['_enhanceCloseRevisionViewerCallback'](){const _0x12a571=this['editor']['config']['get']('revisionHistory')['closeRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.closeRevisionViewerCallback',()=>{if(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['editor']['plugins']['has']('AITabs')){const _0x465c64=this['editor']['plugins']['get']('AITabs')['view']['panelViews'];for(const _0x4273cf of _0x465c64)_0x4273cf['class']='ck-tab-panel_disabled'===_0x4273cf['class']?'':_0x4273cf['class']['replace']('\x20ck-tab-panel_disabled','');if(this['editor']['plugins']['has']('AIChat')){const _0x5eeaa8=document['querySelector']('.ck-ai-chat__prompt-input\x20.ck-textarea');_0x5eeaa8&&_0x5eeaa8['removeAttribute']('tabindex');}if(this['editor']['plugins']['has']('AIChatHistory')){const _0x55438f=document['querySelector']('.ck-ai-chat-history\x20.ck-input');_0x55438f&&_0x55438f['removeAttribute']('tabindex');}}return this['_viewerEditor']['plugins']['get']('RevisionViewer')['_cleanUp'](),_0x12a571(this['_viewerEditor'])['then'](()=>{if(this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),this['_viewerEditor']=null,this['editor']['plugins']['has']('Annotations')){const _0x520cb3=this['editor']['plugins']['get']('Annotations');_0x520cb3['refreshVisibility'](),_0x520cb3['refreshPositioning']();}});});}['_showRevisionViewer'](_0x4d3a55){const _0x14887c=this['editor']['config']['get']('revisionHistory.editorContainer'),_0x46409a=this['editor']['config']['get']('revisionHistory.viewerContainer'),_0x9303f5=this['editor']['config']['get']('revisionHistory.viewerEditorElement');return f['create'](_0x9303f5,_0x4d3a55)['then'](_0x3f4db4=>(_0x46409a['style']['display']='block',_0x14887c['style']['display']='none',this['isRevisionViewerOpen']=!0x0,_0x3f4db4));}['_closeRevisionViewer'](_0x32592a){const _0x23bef7=this['editor']['config']['get']('revisionHistory.editorContainer');return this['editor']['config']['get']('revisionHistory.viewerContainer')['style']['display']='none',_0x23bef7['style']['display']='',this['isRevisionViewerOpen']=!0x1,_0x32592a['destroy']();}async['_restoreRevision'](_0x227056){const _0xb236ce=this['editor'],_0x335d9f=this['_viewerEditor']['plugins']['get']('RevisionViewer'),_0x2d8e33=_0xb236ce['plugins']['get']('RevisionTracker'),_0x251257=_0xb236ce['plugins']['get']('RevisionHistoryUtils'),_0x52885d=_0x335d9f['repository']['getRevision'](_0x227056);let _0x12c8b6,_0x396512,_0x5990c5;try{await _0x251257['loadRevisionData'](_0x52885d,this['adapter']),_0x12c8b6=_0x251257['getRevisionDocumentData'](_0x52885d),_0x396512=_0x251257['getRevisionRootsAttributes'](_0x52885d);}catch(_0x40c182){return void console['error'](_0x40c182);}_0xb236ce['model']['change'](_0xbbbcc8=>{for(const _0x54271b of Array['from'](_0xb236ce['model']['markers']['getMarkersGroup']('restrictedEditingException')))_0xbbbcc8['removeMarker'](_0x54271b);}),_0x335d9f['isReady']=!0x1,_0xb236ce['model']['enqueueChange'](_0x23733f=>{_0x23733f['setSelection'](null),_0x23733f['removeSelectionAttribute'](_0xb236ce['model']['document']['selection']['getAttributeKeys']());const _0x126c42=Object['keys'](_0x12c8b6);for(const _0x3fe98b of _0xb236ce['model']['document']['roots'])'$graveyard'!=_0x3fe98b['rootName']&&_0x3fe98b['isAttached']()&&!_0x126c42['includes'](_0x3fe98b['rootName'])&&_0x23733f['detachRoot'](_0x3fe98b);for(const _0x541649 of _0x126c42){let _0x335ae9=_0xb236ce['model']['document']['getRoot'](_0x541649);_0x335ae9&&_0x335ae9['isAttached']()||(_0x335ae9=_0x23733f['addRoot'](_0x541649));const _0x4b7420=_0x396512[_0x541649],_0x41a2b5=Object['keys'](_0x4b7420),_0x369dd8=_0x12c8b6[_0x541649];for(const _0xf7856c of _0x335ae9['getAttributeKeys']())_0x41a2b5['includes'](_0xf7856c)||_0x23733f['removeAttribute'](_0xf7856c,_0x335ae9);for(const _0x16ebc1 of _0x41a2b5)_0x23733f['setAttribute'](_0x16ebc1,_0x396512[_0x541649][_0x16ebc1],_0x335ae9);_0x23733f['remove'](_0x23733f['createRangeIn'](_0x335ae9)),_0x23733f['insert'](_0xb236ce['data']['parse'](_0x369dd8,_0x335ae9),_0x335ae9,0x0);}});const _0x485032=m(_0xb236ce['locale'],'Restored');if(_0x52885d['name'])_0x5990c5=-0x1==_0x52885d['name']['indexOf'](_0x485032)?_0x485032+':\x20'+_0x52885d['name']:_0x52885d['name'];else _0x5990c5=_0x485032+':\x20'+(_0x52885d['createdAt']['toLocaleDateString'](_0xb236ce['locale']['uiLanguage'],{'month':'long','day':'numeric'})+',\x20'+_0x52885d['createdAt']['toLocaleTimeString'](_0xb236ce['locale']['uiLanguage'],{'hour':'numeric','minute':'numeric'}));return await _0x2d8e33['saveRevision']({'name':_0x5990c5}),_0x335d9f['isReady']=!0x0,_0xb236ce['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}}export{nt as RestoreRevisionCommand,I as Revision,ct as RevisionHistory,l as RevisionHistoryUI,$ as RevisionHistoryUtils,h as RevisionTracker,u as RevisionViewer,f as RevisionViewerEditor,ht as RevisionViewerIntegration,fi as RevisionViewerLoadingOverlay,v as RevisionViewerUI,S as RevisionsRepository,d as RevisionsSidebar,rt as ShowChangeCommand};
29
+ at();static get['pluginName'](){return'RevisionsSidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[u];}constructor(_0x53dbcd){super(_0x53dbcd),this['_revisionViewer']=_0x53dbcd['plugins']['get'](u),this['_revisionsRepository']=this['_revisionViewer']['repository'],this['_sidebarView']=null;}['init'](){const _0x2d5f89=this['_revisionsRepository']['_revisions'],_0x4fb22a=this['_createRevisionActions'](),_0x464ebe=this['editor']['config']['get']('revisionHistory.viewerSidebarContainer');this['_sidebarView']=new di(this['editor']['locale'],_0x2d5f89,_0x4fb22a,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',(_0x1176e7,_0x505389)=>{_0x505389['revisionViews']['on']('add',(_0x387afd,_0x4f5e73)=>{_0x4f5e73['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)),_0x464ebe['appendChild'](this['_sidebarView']['element']);}['destroy'](){this['_sidebarView']['element']['remove'](),this['_sidebarView']['destroy']();}['_handleEditorDataReady'](){const _0x431232=this['_revisionsRepository']['getRevision'](0x0);if(_0x431232){const _0x146f37=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x431232['id']);this['_revisionViewer']['compare'](_0x431232,_0x146f37);}}['_handleRevisionSelected'](_0x510c15,_0x4c7e61){const _0x1b54a9=this['_revisionsRepository']['getRevision'](_0x4c7e61['id']),_0x6e22f4=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x1b54a9['id']);this['_revisionViewer']['compare'](_0x1b54a9,_0x6e22f4);}['_handleRevisionSetName'](_0x46508a,_0x16a12d){this['_revisionsRepository']['getRevision'](_0x16a12d['id'])['setName'](_0x16a12d['name']);}['_handleDiffChange'](_0x41be98,_0x53179b,_0x2307c1){const _0x584fb5=this['_revisionsRepository']['getRevisionsInDiff'](_0x2307c1);_0x584fb5['length']>0x2?(this['_sidebarView']['highlightRevisions'](_0x584fb5),this['_sidebarView']['selectRevision'](null)):(this['_sidebarView']['highlightRevisions']([]),this['_sidebarView']['selectRevision'](_0x584fb5[0x0]));}['_createRevisionActions'](){const _0x491c93=this['editor'],_0x164f4c=d['availableRevisionActions'],_0x5138d6=_0x491c93['config']['get']('revisionHistory.revisionActions')||d['defaultRevisionActions'];if(_0x5138d6['length'])return _0x5138d6['map'](_0x57e5b5=>{const _0x45b612='string'==typeof _0x57e5b5?Object['assign']({},_0x164f4c[_0x57e5b5]):_0x57e5b5;return _0x45b612['action']=_0x45b612['action']['bind'](this,_0x491c93),_0x45b612['isVisible']&&(_0x45b612['isVisible']=_0x45b612['isVisible']['bind'](this,_0x491c93)),_0x45b612;});}}function at(){return{'compareAgainstSelected':{'name':'Compare\x20against\x20selected','action':({plugins:_0x228f59},_0x50d5e5)=>{const _0x5b8bb5=_0x228f59['get'](u),_0x72fef1=_0x5b8bb5['repository'];let _0x54bab4=_0x5b8bb5['diff']['newRevisionId'],_0x485e57=_0x50d5e5['id'];_0x72fef1['getIndex'](_0x54bab4)>_0x72fef1['getIndex'](_0x485e57)&&([_0x54bab4,_0x485e57]=[_0x485e57,_0x54bab4]),_0x5b8bb5['compare'](_0x54bab4,_0x485e57);},'isVisible':({plugins:_0x43976d},_0x1c3894)=>{const _0x1cc8d5=_0x43976d['get'](u);return!(_0x1cc8d5['repository']['getRevisionsInDiff'](_0x1cc8d5['diff'])['length']>0x2)&&!_0x1c3894['isSelected'];}},'restoreRevision':{'name':'Restore\x20this\x20revision','action':(_0x1a0e7e,{id:_0x5e9a1c})=>{_0x1a0e7e['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x5e9a1c);},'isVisible':({plugins:_0x5401e0},_0x7ac937)=>!!_0x5401e0['get'](u)['repository']['getLaterVisibleRevision'](_0x7ac937['id'])},'nameRevision':{'name':'Name\x20this\x20revision','action':({plugins:_0x426a10},{id:_0x1191a2,revisionNameView:_0xce68b7})=>{const _0x5b2624=_0x426a10['get'](u),_0x413bd6=_0x5b2624['repository']['getEarlierVisibleRevision'](_0x1191a2);_0x5b2624['compare'](_0x1191a2,_0x413bd6),_0xce68b7['focus'](),_0xce68b7['fieldView']['select']();}}};}class Z extends tt{['_view'];['_toolbarConfig'];['_elementReplacer'];get['view'](){return this['_view'];}constructor(_0x59c0a0,_0x518e0a){super(_0x59c0a0),this['_view']=_0x518e0a,this['_toolbarConfig']=st(_0x59c0a0['config']['get']('toolbar')),this['_elementReplacer']=new it();}get['element'](){return this['view']['element'];}['init'](_0x3c550e){const _0x53281e=this['editor'],_0x231405=this['view'],_0x3c3060=_0x53281e['editing']['view'],_0x49c428=_0x231405['editable'],_0x5f2394=_0x3c3060['document']['getRoot']();_0x49c428['name']=_0x5f2394['rootName'],_0x231405['render']();const _0x5a7f7c=_0x49c428['element'];this['setEditableElement'](_0x49c428['name'],_0x5a7f7c),_0x231405['editable']['bind']('isFocused')['to'](this['focusTracker']),_0x3c3060['attachDomRoot'](_0x5a7f7c),this['_elementReplacer']['replace'](_0x3c550e,this['element']),this['_initToolbar'](),this['fire']('ready');}['destroy'](){super['destroy']();const _0x596b6f=this['view'],_0x1f274a=this['editor']['editing']['view'];this['_elementReplacer']['restore'](),_0x1f274a['detachDomRoot'](_0x596b6f['editable']['name']),_0x596b6f['destroy']();}['_initToolbar'](){const _0xc98ad=this['view'];_0xc98ad['stickyPanel']['bind']('isActive')['to'](this['focusTracker'],'isFocused'),_0xc98ad['stickyPanel']['limiterElement']=_0xc98ad['element'],_0xc98ad['stickyPanel']['bind']('viewportTopOffset')['to'](this,'viewportOffset',({top:_0x2aa0b0})=>_0x2aa0b0),_0xc98ad['toolbar']['fillFromConfig'](this['_toolbarConfig'],this['componentFactory']),this['addToolbar'](_0xc98ad['toolbar']);}}class ii extends _0x30ff7f{['_editable'];['stickyPanel'];['toolbar'];get['editable'](){return this['_editable'];}constructor(_0x53a903,_0x560107,_0x341622={}){super(_0x53a903),this['stickyPanel']=new _0x124771(_0x53a903),this['toolbar']=new _0x406902(_0x53a903,{'shouldGroupWhenFull':_0x341622['shouldToolbarGroupWhenFull']}),this['_editable']=new te(_0x53a903,_0x560107);}['render'](){super['render'](),this['stickyPanel']['content']['add'](this['toolbar']),this['top']['add'](this['stickyPanel']),this['main']['add'](this['editable']);}}class f extends/* #__PURE__ -- @preserve */
30
+ _0x37a1b5(_0x28b480){['_ui'];get['ui'](){return this['_ui'];}constructor(_0x52138a,_0x24cba1){super(_0x24cba1),this['sourceElement']=_0x52138a,this['model']['document']['createRoot']();const _0x527cdb=new ii(this['locale'],this['editing']['view'],{'shouldToolbarGroupWhenFull':!0x0});this['_ui']=new Z(this,_0x527cdb);}['destroy'](){return this['updateSourceElement'](),this['ui']['destroy'](),super['destroy']();}static async['create'](_0x4fa567,_0x135486){const _0x440a77=new this(_0x4fa567,_0x135486);return await _0x440a77['initPlugins'](),await _0x440a77['ui']['init'](_0x4fa567),await _0x440a77['data']['init'](_0x440a77['config']['get']('initialData')||''),_0x440a77['fire']('ready'),_0x440a77;}}const p=['RevisionHistoryUI','RestrictedEditingMode','AIChat','AIReviewMode','AIBalloon','AIQuickActions','AIActions'];class ht extends _0x439397{['result'];static get['pluginName'](){return'RevisionViewerIntegration';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x3f06dc){function _0xb4128(_0x48adf5){return _0x48adf5['map'](_0x18156f=>String['fromCharCode'](_0x18156f))['join']('');}super(_0x3f06dc),this['result']='end',_0x3f06dc[_0xb4128([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0xb4128([0x76,0x69,0x65,0x77])][_0xb4128([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0xb4128([0x61,0x75,0x74,0x6f]),_0x3f06dc[_0xb4128([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0xb4128([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0xb4128([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0xb4128([0x73,0x74,0x61,0x74,0x75,0x73])]:_0xb4128([0x6f,0x6b])});}}class ct extends _0x439397{['_viewerEditor'];static get['pluginName'](){return'RevisionHistory';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[h,l];}constructor(_0x273bbd){if(super(_0x273bbd),!this['editor']['config']['get']('revisionHistory'))throw new _0x1b5dfa('revision-history-missing-configuration',this);this['_viewerEditor']=null,this['set']('isRevisionViewerOpen',!0x1),this['editor']['config']['define']('revisionHistory.showRevisionViewerCallback',_0x3fa517=>this['_showRevisionViewer']({..._0x3fa517,'translations':this['editor']['locale']['translations']})),this['editor']['config']['define']('revisionHistory.closeRevisionViewerCallback',_0x50b7bf=>this['_closeRevisionViewer'](_0x50b7bf)),this['editor']['config']['define']('revisionHistory.restoreRevisionCallback',_0xa954e1=>this['_restoreRevision'](_0xa954e1)),this['editor']['config']['define']('revisionHistory.requireRevisionName',!0x1),this['_enhanceShowRevisionViewerCallback'](),this['_enhanceCloseRevisionViewerCallback']();}set['adapter'](_0x6f1c3f){this['editor']['plugins']['get']('RevisionTracker')['adapter']=_0x6f1c3f;}get['adapter'](){return this['editor']['plugins']['get']('RevisionTracker')['adapter'];}['addRevisionData'](_0x1bf92b){return this['editor']['plugins']['get']('RevisionTracker')['addRevisionData'](_0x1bf92b);}['getRevision'](_0x18b2eb){return this['editor']['plugins']['get']('RevisionsRepository')['getRevision'](_0x18b2eb);}['getRevisions'](_0x380459){return this['editor']['plugins']['get']('RevisionsRepository')['getRevisions'](_0x380459||{'toJSON':!0x1});}['_getRevisionViewerEditorConfig'](){const _0x57fc4a=this['editor'],_0x2c65e7=_0x1dfe24(_0x57fc4a,p),_0x380da2=_0x57fc4a['plugins']['get']('RevisionTracker'),_0x141504=_0x57fc4a['plugins']['get']('Users')['users'];return _0x2c65e7['toolbar']=['exitToEditing','restoreRevision','changesNavigation'],delete _0x2c65e7['lazyRoots'],(_0x2c65e7['plugins']['push'](ht,u,v,class extends _0x439397{static get['requires'](){return[u,'Users'];}['init'](){const _0xee8567=this['editor']['plugins']['get']('Users');for(const _0xaba6f7 of _0x141504)_0xaba6f7['isAnonymous']||_0xee8567['getUser'](_0xaba6f7['id'])||_0xee8567['addUser'](_0xaba6f7);const _0x351e93=_0x380da2['repository']['getRevisions']();let _0x13024e=null;const _0x42b82b=this['editor']['plugins']['get']('RevisionViewer');_0x42b82b['adapter']=_0x380da2['adapter'],_0x42b82b['bind']('isEnabled')['to'](_0x380da2),this['editor']['commands']['get']('restoreRevision')['bind']('isEnabled')['to'](_0x57fc4a,'isReadOnly',_0x49d17d=>!_0x49d17d);for(const _0x4c4a89 of _0x351e93){const _0x3edc86=null===_0x4c4a89['creator'];if(_0x3edc86&&_0x4c4a89['toVersion']===_0x4c4a89['fromVersion'])continue;const _0x24f3ff=_0x4c4a89['toJSON']();_0x42b82b['addRevisionData'](_0x24f3ff,(_0x43a597,_0x560199,_0x38eb04)=>{if(_0x3edc86){if(_0x13024e)_0x13024e['_update'](_0x43a597,_0x560199);else{if(!_0x560199){const _0x25b85d=_0x38eb04['toJSON']();_0x25b85d['id']=_0x391c61(),_0x380da2['saveRevision'](_0x25b85d,_0x38eb04['toVersion'])['then'](_0x41217b=>{_0x13024e=_0x41217b;});}}}else _0x4c4a89['_update'](_0x43a597,_0x560199);});}}},d),_0x2c65e7);}['_enhanceShowRevisionViewerCallback'](){const _0x271356=this['editor']['config']['get']('revisionHistory')['showRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.showRevisionViewerCallback',async()=>{this['editor']['enableReadOnlyMode']('revision-history-viewer-opened');const _0x1e53c4=this['editor']['plugins']['get']('RevisionTracker');if(this['editor']['plugins']['has']('Autosave')){const _0x56a0ec=this['editor']['plugins']['get']('Autosave');await _0x56a0ec['save']();}else await _0x1e53c4['update']();if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('Dialog')){const _0x1cae3a=this['editor']['plugins']['get']('Dialog');_0x1cae3a['isOpen']&&_0x1cae3a['hide']();}if(this['editor']['plugins']['has']('AITabs')){const _0x4edd48=this['editor']['plugins']['get']('AITabs')['view']['panelViews'];for(const _0x48bea4 of _0x4edd48)_0x48bea4['class']=_0x48bea4['class']?_0x48bea4['class']+'\x20ck-tab-panel_disabled':'ck-tab-panel_disabled';if(this['editor']['plugins']['has']('AIChat')){const _0x2a3a3d=document['querySelector']('.ck-ai-chat__prompt-input\x20.ck-textarea');_0x2a3a3d&&_0x2a3a3d['setAttribute']('tabindex','-1');}if(this['editor']['plugins']['has']('AIChatHistory')){const _0x6fdd22=document['querySelector']('.ck-ai-chat-history\x20.ck-input');_0x6fdd22&&_0x6fdd22['setAttribute']('tabindex','-1');}}const _0x43ee6f=this['_getRevisionViewerEditorConfig']();return _0x271356(_0x43ee6f)['then'](_0x5d3acf=>{return(this['_viewerEditor']=_0x5d3acf,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'),_0x5d3acf);})['catch'](_0x39146c=>(console['error'](_0x39146c),this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),null));});}['_enhanceCloseRevisionViewerCallback'](){const _0x21c695=this['editor']['config']['get']('revisionHistory')['closeRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.closeRevisionViewerCallback',()=>{if(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['editor']['plugins']['has']('AITabs')){const _0x423440=this['editor']['plugins']['get']('AITabs')['view']['panelViews'];for(const _0x3f6a4e of _0x423440)_0x3f6a4e['class']='ck-tab-panel_disabled'===_0x3f6a4e['class']?'':_0x3f6a4e['class']['replace']('\x20ck-tab-panel_disabled','');if(this['editor']['plugins']['has']('AIChat')){const _0x1cc9a0=document['querySelector']('.ck-ai-chat__prompt-input\x20.ck-textarea');_0x1cc9a0&&_0x1cc9a0['removeAttribute']('tabindex');}if(this['editor']['plugins']['has']('AIChatHistory')){const _0x2764d2=document['querySelector']('.ck-ai-chat-history\x20.ck-input');_0x2764d2&&_0x2764d2['removeAttribute']('tabindex');}}return this['_viewerEditor']['plugins']['get']('RevisionViewer')['_cleanUp'](),_0x21c695(this['_viewerEditor'])['then'](()=>{if(this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),this['_viewerEditor']=null,this['editor']['plugins']['has']('Annotations')){const _0x50a895=this['editor']['plugins']['get']('Annotations');_0x50a895['refreshVisibility'](),_0x50a895['refreshPositioning']();}});});}['_showRevisionViewer'](_0x1c2398){const _0x3f14bd=this['editor']['config']['get']('revisionHistory.editorContainer'),_0x126282=this['editor']['config']['get']('revisionHistory.viewerContainer'),_0x4d5950=this['editor']['config']['get']('revisionHistory.viewerEditorElement');return f['create'](_0x4d5950,_0x1c2398)['then'](_0x21e379=>(_0x126282['style']['display']='block',_0x3f14bd['style']['display']='none',this['isRevisionViewerOpen']=!0x0,_0x21e379));}['_closeRevisionViewer'](_0x508b67){const _0x2803ca=this['editor']['config']['get']('revisionHistory.editorContainer');return this['editor']['config']['get']('revisionHistory.viewerContainer')['style']['display']='none',_0x2803ca['style']['display']='',this['isRevisionViewerOpen']=!0x1,_0x508b67['destroy']();}async['_restoreRevision'](_0x51b53d){const _0x54ecf7=this['editor'],_0x3cc9fc=this['_viewerEditor']['plugins']['get']('RevisionViewer'),_0x2682fa=_0x54ecf7['plugins']['get']('RevisionTracker'),_0x49ca33=_0x54ecf7['plugins']['get']('RevisionHistoryUtils'),_0x2f5212=_0x3cc9fc['repository']['getRevision'](_0x51b53d);let _0x1615b8,_0x81eedc,_0x4c9e26;try{await _0x49ca33['loadRevisionData'](_0x2f5212,this['adapter']),_0x1615b8=_0x49ca33['getRevisionDocumentData'](_0x2f5212),_0x81eedc=_0x49ca33['getRevisionRootsAttributes'](_0x2f5212);}catch(_0x14c63d){return void console['error'](_0x14c63d);}_0x54ecf7['model']['change'](_0x54a335=>{for(const _0x1de57b of Array['from'](_0x54ecf7['model']['markers']['getMarkersGroup']('restrictedEditingException')))_0x54a335['removeMarker'](_0x1de57b);}),_0x3cc9fc['isReady']=!0x1,_0x54ecf7['model']['enqueueChange'](_0x3d9223=>{_0x3d9223['setSelection'](null),_0x3d9223['removeSelectionAttribute'](_0x54ecf7['model']['document']['selection']['getAttributeKeys']());const _0x2ba909=Object['keys'](_0x1615b8);for(const _0x1a10c3 of _0x54ecf7['model']['document']['roots'])'$graveyard'!=_0x1a10c3['rootName']&&_0x1a10c3['isAttached']()&&!_0x2ba909['includes'](_0x1a10c3['rootName'])&&_0x3d9223['detachRoot'](_0x1a10c3);for(const _0x5b7f3f of _0x2ba909){let _0x3ed3f5=_0x54ecf7['model']['document']['getRoot'](_0x5b7f3f);_0x3ed3f5&&_0x3ed3f5['isAttached']()||(_0x3ed3f5=_0x3d9223['addRoot'](_0x5b7f3f));const _0xdf3a11=_0x81eedc[_0x5b7f3f],_0x4cd688=Object['keys'](_0xdf3a11),_0x5a5e55=_0x1615b8[_0x5b7f3f];for(const _0x357ede of _0x3ed3f5['getAttributeKeys']())_0x4cd688['includes'](_0x357ede)||_0x3d9223['removeAttribute'](_0x357ede,_0x3ed3f5);for(const _0x1f003c of _0x4cd688)_0x3d9223['setAttribute'](_0x1f003c,_0x81eedc[_0x5b7f3f][_0x1f003c],_0x3ed3f5);_0x3d9223['remove'](_0x3d9223['createRangeIn'](_0x3ed3f5)),_0x3d9223['insert'](_0x54ecf7['data']['parse'](_0x5a5e55,_0x3ed3f5),_0x3ed3f5,0x0);}});const _0x4b9295=m(_0x54ecf7['locale'],'Restored');if(_0x2f5212['name'])_0x4c9e26=-0x1==_0x2f5212['name']['indexOf'](_0x4b9295)?_0x4b9295+':\x20'+_0x2f5212['name']:_0x2f5212['name'];else _0x4c9e26=_0x4b9295+':\x20'+(_0x2f5212['createdAt']['toLocaleDateString'](_0x54ecf7['locale']['uiLanguage'],{'month':'long','day':'numeric'})+',\x20'+_0x2f5212['createdAt']['toLocaleTimeString'](_0x54ecf7['locale']['uiLanguage'],{'hour':'numeric','minute':'numeric'}));return await _0x2682fa['saveRevision']({'name':_0x4c9e26}),_0x3cc9fc['isReady']=!0x0,_0x54ecf7['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}}export{nt as RestoreRevisionCommand,I as Revision,ct as RevisionHistory,l as RevisionHistoryUI,$ as RevisionHistoryUtils,h as RevisionTracker,u as RevisionViewer,f as RevisionViewerEditor,ht as RevisionViewerIntegration,ji as RevisionViewerLoadingOverlay,v as RevisionViewerUI,S as RevisionsRepository,d as RevisionsSidebar,rt as ShowChangeCommand};