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

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js CHANGED
@@ -20,10 +20,10 @@
20
20
  *
21
21
  *
22
22
  */
23
- import{ObservableMixin as _0x14857d,uid as _0x451426,Collection as _0x3fcc51,logWarning as _0x572bf6,FocusTracker as _0x5a36b0,KeystrokeHandler as _0x37dc31,scrollViewportToShowTarget as _0x5d9a0a,ResizeObserver as nt,ElementReplacer as ot,CKEditorError as _0x4676dd}from'@ckeditor/ckeditor5-utils/dist/index.js';import{cloneDeep as _0x36f289,set as _0x268604,unset as _0x3f51ab,isEqual as _0x4ffb34}from'es-toolkit/compat';import{Plugin as _0x149b28,PendingActions as _0x18e594,Command as _0x2a06ae,ElementApiMixin as _0x5055df,Editor as _0x5c1f04}from'@ckeditor/ckeditor5-core/dist/index.js';import{Users as _0x43b4df,getMarkerDomElement as _0x5dbfca,ConfirmMixin as ti,sanitizeEditorConfig as _0x38849b}from'ckeditor5-collaboration/dist/index.js';import{ViewContainerElement as _0x373619,ViewAttributeElement as _0x4df112,ViewEmptyElement as _0x553de7,ViewRawElement as _0x57c601,ViewUIElement as _0x316267,ViewDocumentFragment as _0x118cac,ViewText as _0x589e56,ViewElement as _0x3827c1,Element as ut,Range as lt,Position as ft,DocumentFragment as vt,Text as gt}from'@ckeditor/ckeditor5-engine/dist/index.js';import{IconHistory as _0x2f11fa,IconChevronUp as _0x19d9b9,IconChevronDown as _0x44f056,IconUndo as _0x58cf49,IconUser as _0xe5b4b4,IconThreeVerticalDots as _0x28c0d7}from'@ckeditor/ckeditor5-icons/dist/index.js';import{View as ts,injectCssTransitionDisabler as _0x1d874c,submitHandler as _0x5b119f,LabeledFieldView as _0x256e64,createLabeledInputText as _0xb8ce7b,createDropdown as _0x3c0c02,ListView as _0x5b1655,ListItemView as _0x3f34f5,ButtonView as te,MenuBarMenuView as _0x505352,MenuBarMenuListView as _0x222b9c,MenuBarMenuListItemView as _0x1d2298,MenuBarMenuListItemButtonView as _0x11e198,ContextualBalloon as _0x1663f0,ToolbarSeparatorView as _0x114a41,IconView as _0x418e0a,addListToDropdown as _0x2ce9a1,ViewModel as to,EditorUI as st,normalizeToolbarConfig as et,BoxedEditorUIView as rt,StickyPanelView as ht,ToolbarView as dt,InlineEditableUIView as ct}from'@ckeditor/ckeditor5-ui/dist/index.js';import{DateTime as _0x9f88ff}from'luxon';class h extends/* #__PURE__ -- @preserve */
24
- _0x14857d(){['id'];['creator'];['authors'];['diffData'];['toVersion'];['fromVersion'];['model'];constructor(_0x55918e){super(),this['id']=_0x55918e['id']||_0x451426(),this['creator']=_0x55918e['creator']||null,this['authors']=_0x55918e['authors']||[],this['diffData']=_0x55918e['diffData']||null,this['toVersion']=_0x55918e['toVersion']||0x0,this['fromVersion']=_0x55918e['fromVersion']||0x0,this['set']('name',_0x55918e['name']||''),this['set']('createdAt',_0x55918e['createdAt']||new Date()),this['set']('attributes',_0x55918e['attributes']||{});}['setName'](_0x1d3cdf){this['_update']({'name':_0x1d3cdf});}['setAttribute'](_0x2174e7,_0xc7aa57){const _0x1c6d15=_0x36f289(this['attributes']);_0x268604(_0x1c6d15,_0x2174e7,_0xc7aa57),this['_update']({'attributes':_0x1c6d15});}['removeAttribute'](_0x2ff3f3){const _0x4ee813=_0x36f289(this['attributes']);_0x3f51ab(_0x4ee813,_0x2ff3f3),this['_update']({'attributes':_0x4ee813});}['_update'](_0x425289,_0x34b4dc=!0x1){let _0x2c3459=!0x1;const _0x1656f8={'id':this['id']},_0x3b11c8=['name','createdAt','diffData','authors','attributes','toVersion','fromVersion','creatorId'];for(const _0x5ab7d9 of _0x3b11c8){const _0x2ac261=_0x425289[_0x5ab7d9];void 0x0!==_0x2ac261&&_0x2ac261!==this[_0x5ab7d9]&&(this[_0x5ab7d9]=_0x2ac261,_0x1656f8[_0x5ab7d9]=_0x2ac261,_0x2c3459=!0x0);}_0x2c3459&&(_0x1656f8['authors']&&(_0x1656f8['authorsIds']=_0x1656f8['authors']['map'](_0x3cb8f7=>_0x3cb8f7['id']),delete _0x1656f8['authors']),this['fire']('_update',_0x1656f8,_0x34b4dc));}['toJSON'](){return{'id':this['id'],'name':this['name'],'creatorId':this['creator']?this['creator']['id']:null,'authorsIds':this['authors']['map'](_0x3eeb54=>_0x3eeb54['id']),'diffData':this['diffData'],'createdAt':this['createdAt'],'attributes':this['attributes'],'fromVersion':this['fromVersion'],'toVersion':this['toVersion']};}}class I extends _0x149b28{['_revisions'];static get['requires'](){return[_0x43b4df];}static get['pluginName'](){return'RevisionsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['length'](){return this['_revisions']['length'];}constructor(_0x302136){super(_0x302136),this['_revisions']=new _0x3fcc51();}['afterInit'](){!async function(_0x1f9b42){const _0x347073=_0xa8d78f([0x70,0x74,0x78,0x4e,0x41,0x31,0x36,0x42,0x6b,0x73,0x52,0x45,0x79,0x69,0x59,0x6f,0x43,0x55,0x4f,0x71,0x30,0x6e,0x44,0x76,0x50,0x65,0x37,0x75,0x32,0x54,0x68,0x51,0x67,0x62,0x6c,0x4a,0x58,0x4c,0x77,0x34,0x35,0x7a,0x47,0x61,0x6d,0x38,0x5a,0x33,0x64,0x57,0x4b,0x39,0x66,0x53,0x4d,0x46,0x48,0x56,0x63,0x72,0x49,0x6a]),_0x36d9e6=0xeb829,_0x2d9955=0x66e9f56b,_0x305a12=0x66ee9143^_0x2d9955,_0x196f4d=window[_0xa8d78f([0x44,0x61,0x74,0x65])][_0xa8d78f([0x6e,0x6f,0x77])](),_0x236736=_0x1f9b42[_0xa8d78f([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x206d07=new window[(_0xa8d78f([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x1b0009=>{_0x236736[_0xa8d78f([0x6f,0x6e,0x63,0x65])](_0xa8d78f([0x72,0x65,0x61,0x64,0x79]),_0x1b0009);}),_0x56f1af={[_0xa8d78f([0x6b,0x74,0x79])]:_0xa8d78f([0x45,0x43]),[_0xa8d78f([0x75,0x73,0x65])]:_0xa8d78f([0x73,0x69,0x67]),[_0xa8d78f([0x63,0x72,0x76])]:_0xa8d78f([0x50,0x2d,0x32,0x35,0x36]),[_0xa8d78f([0x78])]:_0xa8d78f([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]),[_0xa8d78f([0x79])]:_0xa8d78f([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]),[_0xa8d78f([0x61,0x6c,0x67])]:_0xa8d78f([0x45,0x53,0x32,0x35,0x36])},_0x14ca01=_0x236736[_0xa8d78f([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0xa8d78f([0x67,0x65,0x74])](_0xa8d78f([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x11c174(){let _0x339f7d,_0x1270a8=null,_0x497d62=null;try{if(_0x14ca01==_0xa8d78f([0x47,0x50,0x4c]))return _0xa8d78f([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x339f7d=_0x2262ca(),!_0x339f7d)return _0xa8d78f([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x339f7d[_0xa8d78f([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x497d62=_0x456cf3(_0x339f7d[_0xa8d78f([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x339f7d[_0xa8d78f([0x6a,0x74,0x69])])),await _0x35a016()?_0x5de48f()?_0x55cbae()?_0xa8d78f([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x26b902()?(_0x339f7d[_0xa8d78f([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0xa8d78f([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x1270a8=_0x401032(_0xa8d78f([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x339f7d[_0xa8d78f([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0xa8d78f([0x74,0x72,0x69,0x61,0x6c])&&(_0x1270a8=_0x401032(_0xa8d78f([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),await _0x4de499()):_0xa8d78f([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0xa8d78f([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0xa8d78f([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch(_0x366ff1){return _0xa8d78f([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x55cbae(){const _0x3209fc=[_0xa8d78f([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0xa8d78f([0x74,0x72,0x69,0x61,0x6c])][_0xa8d78f([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x339f7d[_0xa8d78f([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x196f4d/0x3e8:0xe10*_0x305a12;return _0x339f7d[_0xa8d78f([0x65,0x78,0x70])]<_0x3209fc;}function _0x5de48f(){const _0x1d1106=_0x339f7d[_0xa8d78f([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x1d1106)return!0x1;if(_0x1d1106[_0xa8d78f([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0xa8d78f([0x2a])))return!0x0;if(_0x1d1106[_0xa8d78f([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0xa8d78f([0x52,0x48])))return!0x0;if(_0x1d1106[_0xa8d78f([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0xa8d78f([0x52,0x52,0x48]))){if(_0x21aad4())return!0x0;if(_0x3a8a2a()||_0x29abb9())return!0x0;}return!0x1;}function _0x26b902(){const _0x448abd=_0x339f7d[_0xa8d78f([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x448abd||0x0==_0x448abd[_0xa8d78f([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x314b64}=new URL(window[_0xa8d78f([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x448abd[_0xa8d78f([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x314b64))return!0x0;const _0x991367=_0x314b64[_0xa8d78f([0x73,0x70,0x6c,0x69,0x74])](_0xa8d78f([0x2e]));return _0x448abd[_0xa8d78f([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x1da43f=>_0x1da43f[_0xa8d78f([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0xa8d78f([0x2a])))[_0xa8d78f([0x6d,0x61,0x70])](_0x10648d=>_0x10648d[_0xa8d78f([0x73,0x70,0x6c,0x69,0x74])](_0xa8d78f([0x2e])))[_0xa8d78f([0x73,0x6f,0x6d,0x65])](_0x2cd346=>_0x991367[_0xa8d78f([0x65,0x76,0x65,0x72,0x79])]((_0x416f68,_0x5b0377)=>_0x2cd346[_0x5b0377]===_0x416f68||_0x2cd346[_0x5b0377]===_0xa8d78f([0x2a])));}function _0x4de499(){return _0x1270a8&&_0x497d62?new window[(_0xa8d78f([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x1b0ca0,_0x214e88)=>{_0x1270a8[_0xa8d78f([0x74,0x68,0x65,0x6e])](_0x1b0ca0,_0x214e88),_0x497d62[_0xa8d78f([0x74,0x68,0x65,0x6e])](_0x2db954=>{_0x2db954!=_0xa8d78f([0x56,0x61,0x6c,0x69,0x64])&&_0x1b0ca0(_0x2db954);},_0x214e88);}):_0x1270a8||_0x497d62||_0xa8d78f([0x56,0x61,0x6c,0x69,0x64]);}}function _0x456cf3(_0x419085,_0x27db51){return new window[(_0xa8d78f([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x487d78=>{if(_0x49d4a3())return _0x487d78(_0xa8d78f([0x56,0x61,0x6c,0x69,0x64]));_0xd2640e(),_0x236736[_0xa8d78f([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0xa8d78f([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x5b4e0c=!0x1;const _0x2b335e=_0x451426();function _0x270293(_0x48f5c9){return!!_0x48f5c9&&(typeof _0x48f5c9===_0xa8d78f([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x48f5c9===_0xa8d78f([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x48f5c9[_0xa8d78f([0x74,0x68,0x65,0x6e])]===_0xa8d78f([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x48f5c9[_0xa8d78f([0x63,0x61,0x74,0x63,0x68])]===_0xa8d78f([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x2e4dd1(_0x5e5cf8){_0x4cd65c(_0x5e5cf8)[_0xa8d78f([0x74,0x68,0x65,0x6e])](_0x3eb908=>{if(!_0x3eb908||_0x3eb908[_0xa8d78f([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0xa8d78f([0x6f,0x6b]))return _0xa8d78f([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x3cad42(_0x4fd66f(_0x2b335e+_0x27db51))!=_0x3eb908[_0xa8d78f([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0xa8d78f([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0xa8d78f([0x56,0x61,0x6c,0x69,0x64]);})[_0xa8d78f([0x74,0x68,0x65,0x6e])](_0x3445b0=>(_0x2aa3c5(),_0x3445b0),()=>{const _0x29e380=_0xe2b20c();return null==_0x29e380?(_0x2aa3c5(),_0xa8d78f([0x56,0x61,0x6c,0x69,0x64])):_0xa8d78f(_0x196f4d-_0x29e380>(0x42e5716b^_0x2d9955)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0xa8d78f([0x74,0x68,0x65,0x6e])](_0x487d78)[_0xa8d78f([0x63,0x61,0x74,0x63,0x68])](()=>{_0x487d78(_0xa8d78f([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x1bcadd=0x66df1beb^_0x2d9955;function _0x2aa3c5(){const _0x4567f4=_0xa8d78f([0x6c,0x6c,0x63,0x74,0x2d])+_0x3cad42(_0x4fd66f(_0x419085)),_0x579ac5=_0x3bf081(_0x3cad42(window[_0xa8d78f([0x4d,0x61,0x74,0x68])][_0xa8d78f([0x63,0x65,0x69,0x6c])](_0x196f4d/_0x1bcadd)));window[_0xa8d78f([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0xa8d78f([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x4567f4,_0x579ac5);}function _0xe2b20c(){const _0x47d2bb=_0xa8d78f([0x6c,0x6c,0x63,0x74,0x2d])+_0x3cad42(_0x4fd66f(_0x419085)),_0x20c4fd=window[_0xa8d78f([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0xa8d78f([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x47d2bb);return _0x20c4fd?window[_0xa8d78f([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x3bf081(_0x20c4fd),0x10)*_0x1bcadd:null;}function _0x4cd65c(_0x385178){return new window[(_0xa8d78f([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x21ef7e,_0x11ffdb)=>{_0x385178[_0xa8d78f([0x74,0x68,0x65,0x6e])](_0x21ef7e,_0x11ffdb),window[_0xa8d78f([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x11ffdb,0x66e821ab^_0x2d9955);});}}_0x236736[_0xa8d78f([0x6f,0x6e])](_0xa8d78f([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x331f4b,_0x28db59)=>{if(_0x28db59[0x0]!=_0x419085)return _0x487d78(_0xa8d78f([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x28db59[0x1]={..._0x28db59[0x1],[_0xa8d78f([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x2b335e};},{[_0xa8d78f([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0xa8d78f([0x68,0x69,0x67,0x68])}),_0x236736[_0xa8d78f([0x6f,0x6e])](_0xa8d78f([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x44de77=>{_0x270293(_0x44de77[_0xa8d78f([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x5b4e0c=!0x0,_0x2e4dd1(_0x44de77[_0xa8d78f([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0xa8d78f([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0xa8d78f([0x6c,0x6f,0x77])}),_0x206d07[_0xa8d78f([0x74,0x68,0x65,0x6e])](()=>{_0x5b4e0c||_0x487d78(_0xa8d78f([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x49d4a3(){return _0x236736[_0xa8d78f([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0xa8d78f([0x76,0x69,0x65,0x77])][_0xa8d78f([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0xa8d78f([0x61,0x75,0x74,0x6f]);}function _0xd2640e(){_0x236736[_0xa8d78f([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0xa8d78f([0x76,0x69,0x65,0x77])][_0xa8d78f([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0xa8d78f([0x61,0x75,0x74,0x6f]);}}function _0x401032(_0x5e56f8){const _0x4f61d2=[new window[(_0xa8d78f([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x440ab5=>setTimeout(_0x440ab5,0x66e0cba7^_0x2d9955)),_0x206d07[_0xa8d78f([0x74,0x68,0x65,0x6e])](()=>new window[(_0xa8d78f([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x1bdade=>{const _0x8dc8bb=0x66e9f56c^_0x2d9955,_0x3b6f32=_0x1f9b42[_0xa8d78f([0x5f,0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x73])];function _0x184691(){_0x3b6f32[_0xa8d78f([0x6c,0x65,0x6e,0x67,0x74,0x68])]>=_0x8dc8bb&&_0x1bdade();}_0x184691(),_0x3b6f32[_0xa8d78f([0x6f,0x6e])](_0xa8d78f([0x61,0x64,0x64]),_0x184691);})),new window[(_0xa8d78f([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x2ba48f=>{function _0x164fad(){for(const _0x464cd5 in window)if(window[_0xa8d78f([0x4e,0x75,0x6d,0x62,0x65,0x72])]['isNaN'](window[_0xa8d78f([0x4e,0x75,0x6d,0x62,0x65,0x72])](_0x464cd5))&&window[_0x464cd5]==_0x36d9e6)return _0x2ba48f();_0x236736[_0xa8d78f([0x73,0x74,0x61,0x74,0x65])]!=_0xa8d78f([0x64,0x65,0x73,0x74,0x72,0x6f,0x79,0x65,0x64])&&window[_0xa8d78f([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x164fad,0x66e9e6e3^_0x2d9955);}_0x12a518(_0xa8d78f([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))&&_0x164fad();})];return window[_0xa8d78f([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0xa8d78f([0x72,0x61,0x63,0x65])](_0x4f61d2)[_0xa8d78f([0x74,0x68,0x65,0x6e])](()=>_0x5e56f8);}async function _0x3d5a4d(){if(await _0x206d07,_0x12a518(_0xa8d78f([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))){const _0x2cfbaa=_0x1f9b42[_0xa8d78f([0x67,0x65,0x74,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](0x0),_0x3e0b96=_0x1f9b42[_0xa8d78f([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])](_0x2cfbaa[_0xa8d78f([0x69,0x64])]),_0x1ba8a7=_0x53f4be(_0xa8d78f([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]));return await _0x1ba8a7[_0xa8d78f([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])](_0x2cfbaa['id'],_0x3e0b96?_0x3e0b96['id']:null,!0x0),_0x1ba8a7[_0xa8d78f([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0xa8d78f([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x1ba8a7[_0xa8d78f([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x1ba8a7[_0xa8d78f([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])]=_0x135e00,void(_0x1ba8a7[_0xa8d78f([0x5f,0x67,0x65,0x74,0x44,0x69,0x66,0x66])]=_0x135e00);}if(_0x12a518(_0xa8d78f([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]))){const _0x196e65=_0x53f4be(_0xa8d78f([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]));_0x196e65[_0xa8d78f([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0xa8d78f([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x196e65[_0xa8d78f([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x196e65[_0xa8d78f([0x75,0x70,0x64,0x61,0x74,0x65])]=_0x135e00,_0x196e65[_0xa8d78f([0x73,0x61,0x76,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])]=_0x135e00;}_0x236736[_0xa8d78f([0x6d,0x6f,0x64,0x65,0x6c])][_0xa8d78f([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x135e00,_0x236736[_0xa8d78f([0x6d,0x6f,0x64,0x65,0x6c])][_0xa8d78f([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x135e00,_0x236736[_0xa8d78f([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0xa8d78f([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x21aad4(){return _0x12a518(_0xa8d78f([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x53f4be(_0xa8d78f([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0xa8d78f([0x73,0x74,0x61,0x74,0x65])]==_0xa8d78f([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x3a8a2a(){return _0x12a518(_0xa8d78f([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 _0x29abb9(){return _0x12a518(_0xa8d78f([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0x316ff8(_0x64181f){const _0x150b23=_0x11db1a();_0x236736[_0x150b23]=_0xa8d78f([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])+_0x64181f,_0x64181f[_0xa8d78f([0x65,0x6e,0x64,0x73,0x57,0x69,0x74,0x68])](_0xa8d78f([0x4c,0x69,0x6d,0x69,0x74]))&&(window[_0x11db1a()]=_0x36d9e6),_0x64181f!=_0xa8d78f([0x56,0x61,0x6c,0x69,0x64])&&_0x3d5a4d();}function _0x11db1a(){const _0x466e1f=window[_0xa8d78f([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0xa8d78f([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0xa8d78f([0x6e,0x6f,0x77])]())[_0xa8d78f([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0xa8d78f([0x2e]),'');let _0x50b794=_0xa8d78f([0x70]);for(let _0x201758=0x0;_0x201758<_0x466e1f[_0xa8d78f([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x201758+=0x2){let _0x18caa4=window[_0xa8d78f([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x466e1f[_0xa8d78f([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x201758,_0x201758+0x2));_0x18caa4>=_0x347073[_0xa8d78f([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x18caa4-=_0x347073[_0xa8d78f([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x50b794+=_0x347073[_0x18caa4];}return _0x50b794;}function _0x2262ca(){const _0x3e16de=_0x14ca01[_0xa8d78f([0x73,0x70,0x6c,0x69,0x74])](_0xa8d78f([0x2e]));if(0x3!=_0x3e16de[_0xa8d78f([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x1fa5a8(_0x3e16de[0x1]);function _0x1fa5a8(_0x1c1419){const _0x2f894c=_0x148a54(_0x1c1419);return _0x2f894c&&_0x20cad5()?_0x2f894c:null;function _0x20cad5(){const _0x5e96fb=_0x2f894c[_0xa8d78f([0x6a,0x74,0x69])],_0x261452=window[_0xa8d78f([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x5e96fb[_0xa8d78f([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x5e96fb[_0xa8d78f([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x1c9767={..._0x2f894c,[_0xa8d78f([0x6a,0x74,0x69])]:_0x5e96fb[_0xa8d78f([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x5e96fb[_0xa8d78f([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x1c9767[_0xa8d78f([0x76,0x63])],_0x4fd66f(_0x1c9767)==_0x261452;}}}async function _0x35a016(){let _0x212007=!0x0;try{const _0x2a882c=_0x14ca01[_0xa8d78f([0x73,0x70,0x6c,0x69,0x74])](_0xa8d78f([0x2e])),[_0x10cd9e,_0x21d6c3,_0x4f3875]=_0x2a882c;return _0x3efafe(_0x10cd9e),await _0x15950c(_0x10cd9e,_0x21d6c3,_0x4f3875),_0x212007;}catch(_0x88faf){return!0x1;}function _0x3efafe(_0x389c54){const _0x394254=_0x148a54(_0x389c54);_0x394254&&_0x394254[_0xa8d78f([0x61,0x6c,0x67])]==_0xa8d78f([0x45,0x53,0x32,0x35,0x36])||(_0x212007=!0x1);}async function _0x15950c(_0x5b762e,_0x3baf8f,_0x215255){const _0x4ce583=window[_0xa8d78f([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0xa8d78f([0x66,0x72,0x6f,0x6d])](_0x400e4b(_0x215255),_0x11b918=>_0x11b918[_0xa8d78f([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x111db6=new window[(_0xa8d78f([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0xa8d78f([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x5b762e+_0xa8d78f([0x2e])+_0x3baf8f),_0x1b8009=window[_0xa8d78f([0x63,0x72,0x79,0x70,0x74,0x6f])][_0xa8d78f([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x1b8009)return;const _0x2eb3b0=await _0x1b8009[_0xa8d78f([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0xa8d78f([0x6a,0x77,0x6b]),_0x56f1af,{[_0xa8d78f([0x6e,0x61,0x6d,0x65])]:_0xa8d78f([0x45,0x43,0x44,0x53,0x41]),[_0xa8d78f([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0xa8d78f([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0xa8d78f([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x1b8009[_0xa8d78f([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0xa8d78f([0x6e,0x61,0x6d,0x65])]:_0xa8d78f([0x45,0x43,0x44,0x53,0x41]),[_0xa8d78f([0x68,0x61,0x73,0x68])]:{[_0xa8d78f([0x6e,0x61,0x6d,0x65])]:_0xa8d78f([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x2eb3b0,_0x4ce583,_0x111db6)||(_0x212007=!0x1);}}function _0x148a54(_0x33b8df){return _0x33b8df[_0xa8d78f([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0xa8d78f([0x65,0x79]))?JSON[_0xa8d78f([0x70,0x61,0x72,0x73,0x65])](_0x400e4b(_0x33b8df)):null;}function _0x400e4b(_0x53c359){return window[_0xa8d78f([0x61,0x74,0x6f,0x62])](_0x53c359[_0xa8d78f([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0xa8d78f([0x2b]))[_0xa8d78f([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0xa8d78f([0x2f])));}function _0x4fd66f(_0x533ba5){let _0x13d8ba=0x1505;function _0xf3ce3e(_0x8115df){for(let _0x7c0f92=0x0;_0x7c0f92<_0x8115df[_0xa8d78f([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x7c0f92++){const _0x56c6e7=_0x8115df[_0xa8d78f([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x7c0f92);_0x13d8ba=(_0x13d8ba<<0x5)+_0x13d8ba+_0x56c6e7,_0x13d8ba&=_0x13d8ba;}}function _0x5c3f4b(_0x8d610d){Array[_0xa8d78f([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x8d610d)?_0x8d610d[_0xa8d78f([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x5c3f4b):_0x8d610d&&typeof _0x8d610d==_0xa8d78f([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0xa8d78f([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x8d610d)[_0xa8d78f([0x73,0x6f,0x72,0x74])]()[_0xa8d78f([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x52cd71,_0x2143ec])=>{_0xf3ce3e(_0x52cd71),_0x5c3f4b(_0x2143ec);}):_0xf3ce3e(window[_0xa8d78f([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x8d610d));}return _0x5c3f4b(_0x533ba5),_0x13d8ba>>>0x0;}function _0x3cad42(_0x2a8418){return _0x2a8418[_0xa8d78f([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0xa8d78f([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0xa8d78f([0x30]));}function _0x3bf081(_0xaf7d77){return _0xaf7d77[_0xa8d78f([0x73,0x70,0x6c,0x69,0x74])]('')[_0xa8d78f([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0xa8d78f([0x6a,0x6f,0x69,0x6e])]('');}function _0x12a518(_0x4bae2f){return _0x236736[_0xa8d78f([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0xa8d78f([0x68,0x61,0x73])](_0x4bae2f);}function _0x53f4be(_0x258fdb){return _0x236736[_0xa8d78f([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0xa8d78f([0x67,0x65,0x74])](_0x258fdb);}function _0x135e00(){}function _0xa8d78f(_0x2e4db4){return _0x2e4db4['map'](_0x1528d8=>String['fromCharCode'](_0x1528d8))['join']('');}_0x316ff8(await _0x11c174());}(this);}['createRevision'](_0x347a98){const _0x2a456d=this['editor']['plugins']['get']('Users');return new h({'id':_0x347a98['id'],'name':_0x347a98['name'],'creator':_0x347a98['creatorId']?_0x2a456d['getUser'](_0x347a98['creatorId']):null,'diffData':_0x347a98['diffData']||_0x347a98['data'],'authors':_0x347a98['authorsIds']['map'](_0x3b95c1=>_0x2a456d['getUser'](_0x3b95c1)),'createdAt':new Date(_0x347a98['createdAt']),'attributes':_0x347a98['attributes'],'fromVersion':_0x347a98['fromVersion'],'toVersion':_0x347a98['toVersion']});}['addRevision'](_0x3c5286,_0x45932a=0x0){this['_revisions']['add'](_0x3c5286,_0x45932a);}['getRevision'](_0x3ef819){return this['_revisions']['get'](_0x3ef819);}['getRevisions'](_0x1d79eb={'toJSON':!0x1}){const _0x3cb076=Array['from'](this['_revisions']);return _0x3cb076['reverse'](),_0x1d79eb['toJSON']?_0x3cb076['map'](_0x36845f=>_0x36845f['toJSON']()):_0x3cb076;}['getIndex'](_0x10d027){return this['_revisions']['getIndex'](_0x10d027);}['getEarlierVisibleRevision'](_0x2a2eb7){const [,_0x414d89]=this['getRevisionsIterator'](_0x2a2eb7,{'direction':'earlier'});return _0x414d89;}['getLaterVisibleRevision'](_0x34330c){const [,_0x13786e]=this['getRevisionsIterator'](_0x34330c,{'direction':'later'});return _0x13786e;}['getRevisionsInDiff'](_0xd1542f){const _0xf8adca=[];for(const _0x28cc40 of this['getRevisionsIterator'](_0xd1542f['newRevisionId']))if(_0xf8adca['push'](_0x28cc40),_0x28cc40['id']===_0xd1542f['oldRevisionId'])break;return _0xf8adca;}*['getRevisionsIterator'](_0x1b41b8,{direction:_0x27fd0a='earlier',filter:_0x3a733c=()=>!0x0}={}){const _0x471e19='earlier'===_0x27fd0a?0x1:-0x1;let _0x2543f0=this['_revisions']['get'](_0x1b41b8),_0x5333f5=this['getIndex'](_0x2543f0);for(yield _0x2543f0;_0x2543f0;){if(_0x5333f5+=_0x471e19,_0x2543f0=this['getRevision'](_0x5333f5),!_0x2543f0)return;_0x3a733c(_0x2543f0)&&(yield _0x2543f0);}}}class V extends _0x149b28{static get['pluginName'](){return'RevisionHistoryUtils';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['_viewClassToTypeChar']=new Map([[_0x373619,'c'],[_0x4df112,'a'],[_0x553de7,'e'],[_0x57c601,'r'],[_0x316267,'u']]);['_typeCharToViewClass']=new Map([['c',_0x373619],['a',_0x4df112],['e',_0x553de7],['r',_0x57c601],['u',_0x316267]]);async['loadRevisionData'](_0x558f16,_0x23cd18){if(_0x558f16['diffData']||!_0x23cd18)return;const _0x747bd7=this['editor']['config']['get']('collaboration.channelId'),_0x37da63=await _0x23cd18['getRevision']({'channelId':_0x747bd7,'revisionId':_0x558f16['id']});_0x558f16['diffData']=_0x37da63['diffData'];}['getRevisionDocumentData'](_0x1fba23){const _0x5db67f={};for(const _0x382771 in _0x1fba23['diffData']){if(_0x1fba23['diffData'][_0x382771]['attachChange']&&!_0x1fba23['diffData'][_0x382771]['attachChange']['isAttached'])continue;const _0x285b72=this['_removeRevisionMarkers'](JSON['parse'](_0x1fba23['diffData'][_0x382771]['insertions'])),_0x305341=this['editor']['editing']['view']['document'],_0x6934a9=new _0x118cac(_0x305341,_0x285b72['map'](_0x12b8d5=>this['_getViewFromDiffObj'](_0x12b8d5,!0x1)));this['editor']['data']['processor']['useFillerType']('marked'),_0x5db67f[_0x382771]=this['editor']['data']['processor']['toData'](_0x6934a9),this['editor']['data']['processor']['useFillerType']('default');}return _0x5db67f;}['getRevisionRootsAttributes'](_0x46286b){const _0x19650f={};for(const _0x285c0d in _0x46286b['diffData'])_0x46286b['diffData'][_0x285c0d]['attachChange']&&!_0x46286b['diffData'][_0x285c0d]['attachChange']['isAttached']||(_0x19650f[_0x285c0d]=_0x46286b['diffData'][_0x285c0d]['attributesAfter']||{});return _0x19650f;}['_getTypeCharForViewElement'](_0x5b9bb7){return this['_viewClassToTypeChar']['get'](_0x5b9bb7['constructor']);}['_getViewFromDiffObj'](_0x3fbc43,_0x260761){const _0x3d6c81=this['editor']['editing']['view']['document'];if('string'==typeof _0x3fbc43)return new _0x589e56(_0x3d6c81,_0x3fbc43);{let _0xb38308,_0x3305a7;_0x3305a7='u'==_0x3fbc43['type']||'r'==_0x3fbc43['type']?[]:_0x3fbc43['children']['map'](_0x2c6c01=>this['_getViewFromDiffObj'](_0x2c6c01,_0x260761));const _0x4780ef=this['_typeCharToViewClass']['get'](_0x3fbc43['type'])||_0x3827c1,_0x3cb807=this['editor']['data']['htmlProcessor']['domConverter'];if(_0xb38308=new _0x4780ef(_0x3d6c81,_0x3fbc43['name'],_0x3fbc43['attributes'],_0x3305a7),'u'==_0x3fbc43['type']&&_0x3fbc43['children'][0x0]){const _0x2fbde2=_0x3fbc43['children'][0x0];if(_0xb38308['render']=function(_0x119e40){const _0x139c54=_0x119e40['createElement']('div');return _0x139c54['innerHTML']=_0x2fbde2,_0x139c54['childNodes'][0x0];},_0x260761){const _0x4d6efc=new _0x118cac(_0x3d6c81);_0x4d6efc['_appendChild'](_0xb38308);const _0x5562a2=Array['from'](_0x3cb807['viewChildrenToDom'](_0x4d6efc,{'bind':!0x1})),_0x2afb72=_0x3cb807['domDocument']['createElement']('div');_0x2afb72['append'](..._0x5562a2),_0xb38308=Array['from'](_0x3cb807['domChildrenToView'](_0x2afb72))[0x0];}}else{if('r'==_0x3fbc43['type']&&_0x3fbc43['children'][0x0]){const _0x4122db=_0x3fbc43['children'][0x0];if(_0xb38308['render']=function(_0x44ce16){_0x44ce16['innerHTML']=_0x4122db;},_0x260761){const _0x2e7652=new _0x118cac(_0x3d6c81);_0x2e7652['_appendChild'](_0xb38308);const _0x393add=Array['from'](_0x3cb807['viewChildrenToDom'](_0x2e7652,{'bind':!0x1})),_0x18c271=_0x3cb807['domDocument']['createElement']('div');_0x18c271['append'](..._0x393add);const _0x529792=Array['from'](_0x3cb807['domChildrenToView'](_0x18c271));_0x529792['length']>0x1?_0xb38308['_appendChild'](_0x529792):_0xb38308=_0x529792[0x0];}}}if(_0x3fbc43['customProperties']){for(const [_0x3ee65b,_0x6692fe]of _0x3fbc43['customProperties'])_0xb38308['_setCustomProperty'](_0x3ee65b,_0x6692fe);}const _0x1fb870=void 0x0===_0x3fbc43['fillerOffset']?null:_0x3fbc43['fillerOffset'];return null!==_0x1fb870&&(_0xb38308['getFillerOffset']=()=>_0x1fb870),_0xb38308;}}['_makeModelFromViewString'](_0x29ea40){const _0x546a43=JSON['parse'](_0x29ea40),_0x1256b2=this['editor']['editing']['view']['document'],_0x1c964f=new _0x118cac(_0x1256b2,_0x546a43['map'](_0x490e56=>this['_getViewFromDiffObj'](_0x490e56,!0x0)));return this['editor']['data']['toModel'](_0x1c964f);}['_removeRevisionMarkers'](_0x2bc5ac){return(_0x2bc5ac=_0x2bc5ac['filter'](_0x13ac06=>!_0x13ac06['name']||'revision-start'!==_0x13ac06['name']&&'revision-end'!==_0x13ac06['name']))['forEach'](_0xb860ff=>{'string'!=typeof _0xb860ff&&(_0xb860ff['children']=this['_removeRevisionMarkers'](_0xb860ff['children']),_0xb860ff['attributes']=_0xb860ff['attributes']['filter'](_0x200778=>!_0x200778[0x0]['startsWith']('data-revision-')));}),_0x2bc5ac;}}function g(_0xd19fa1,_0x51c3fb,_0x57903f){const t=_0xd19fa1['t'];switch(_0x51c3fb){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'},_0x57903f);case'X_OF_Y_CHANGES':return t({'string':'%0\x20of\x20%1','id':'X_OF_Y_CHANGES'},_0x57903f);case'Show\x20previous\x20change':return t('Show\x20previous\x20change');case'Show\x20next\x20change':return t('Show\x20next\x20change');case'EDIT_X_OF_Y_REVISIONS':return t({'string':'Edit','id':'EDIT_X_OF_Y_REVISIONS'});case'Total':return t('Total');case'Revision\x20creator':return t('Revision\x20creator');case'Revision\x20author':return t('Revision\x20author');case'Revision\x20name':return t('Revision\x20name');case'Save\x20current\x20revision':return t('Save\x20current\x20revision');case'Accept':return t('Accept');case'Save':return t('Save');case'Cancel':return t('Cancel');case'Name\x20of\x20the\x20revision':return t('Name\x20of\x20the\x20revision');case'optional':return t('optional');case'PENDING_ACTION_REVISION_HISTORY':return t({'string':'Unsaved\x20change\x20in\x20revision\x20history.','id':'PENDING_ACTION_REVISION_HISTORY'});case'The\x20revision\x20name\x20cannot\x20be\x20empty.':return t('The\x20revision\x20name\x20cannot\x20be\x20empty.');case'Enter\x20the\x20revision\x20name':return t('Enter\x20the\x20revision\x20name');default:return'';}}class u extends _0x149b28{['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[_0x43b4df,I,V,_0x18e594];}constructor(_0x54e999){super(_0x54e999),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 _0x13222a=_0x451426();this['_source']={'history':this['editor']['model']['document']['history'],'getLatestVersion':()=>Promise['resolve'](this['editor']['model']['document']['version']),'getCurrentRevisionId':()=>_0x13222a},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 _0x16acdc=this['repository']['getRevision'](0x0),_0xf0880d=_0x16acdc&&null===_0x16acdc['creator']?_0x16acdc:null;if(this['_continueCurrentRevision']=!!_0xf0880d&&this['editor']['config']['get']('revisionHistory.resumeUnsavedRevision'),this['editor']['plugins']['has']('RealTimeCollaborationClient')){const _0x460da4=this['_source']['getCurrentRevisionId'](),_0x570f5f=this['repository']['getRevision'](_0x460da4);if(_0x570f5f)this['_startingVersion']=_0x570f5f['fromVersion'],this['_continueCurrentRevision']=!0x1;else{const _0x2eefb8=this['_source']['history']['_operations']['find'](_0x2cd0a3=>!_0x2cd0a3['_isInit']),_0x158d59=_0x2eefb8?_0x2eefb8['baseVersion']:this['_source']['history']['version'];_0x16acdc?(_0x16acdc['toVersion']<_0x158d59&&_0x16acdc['_update']({'toVersion':_0x158d59}),this['_continueCurrentRevision']?(this['_source']['getCurrentRevisionId']=()=>_0xf0880d['id'],this['_startingVersion']=_0xf0880d['fromVersion']):(this['_startingVersion']=_0x16acdc['toVersion'],this['_continueCurrentRevision']=!0x1)):(this['_startingVersion']=_0x158d59,this['_continueCurrentRevision']=!0x1);}}else _0xf0880d&&(this['editor']['model']['document']['history']['version']=Math['max'](_0xf0880d['toVersion'],this['editor']['model']['document']['history']['version']),_0xf0880d['fromVersion']===_0xf0880d['toVersion']?(0x0!==_0xf0880d['fromVersion']&&(this['_source']['getCurrentRevisionId']=()=>_0xf0880d['id']),this['_continueCurrentRevision']=!0x1):this['_continueCurrentRevision']&&(this['_source']['getCurrentRevisionId']=()=>_0xf0880d['id'],this['_startingVersion']=_0xf0880d['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',_0x43e0cb=>!_0x43e0cb),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x32c7b9=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x5cd912;for(const _0x311acb in _0x32c7b9){const _0x1a8a80=_0x311acb,_0x271f34=_0x32c7b9[_0x1a8a80];if('revisionHistoryLicenseKeyValid'==_0x271f34||'revisionHistoryLicenseKeyInvalid'==_0x271f34||'revisionHistoryLicenseKeyExpired'==_0x271f34||'revisionHistoryLicenseKeyDomainLimit'==_0x271f34||'revisionHistoryLicenseKeyNotAllowed'==_0x271f34||'revisionHistoryLicenseKeyEvaluationLimit'==_0x271f34||'revisionHistoryLicenseKeyTrialLimit'==_0x271f34||'revisionHistoryLicenseKeyUsageLimit'==_0x271f34){delete _0x32c7b9[_0x1a8a80],_0x5cd912=_0x271f34,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'revisionHistoryLicenseKeyInvalid'==_0x5cd912&&_0x32c7b9['_showLicenseError']('invalid'),'revisionHistoryLicenseKeyExpired'==_0x5cd912&&_0x32c7b9['_showLicenseError']('expired'),'revisionHistoryLicenseKeyDomainLimit'==_0x5cd912&&_0x32c7b9['_showLicenseError']('domainLimit'),'revisionHistoryLicenseKeyNotAllowed'==_0x5cd912&&_0x32c7b9['_showLicenseError']('featureNotAllowed','RevisionHistory'),'revisionHistoryLicenseKeyEvaluationLimit'==_0x5cd912&&_0x32c7b9['_showLicenseError']('evaluationLimit'),'revisionHistoryLicenseKeyTrialLimit'==_0x5cd912&&_0x32c7b9['_showLicenseError']('trialLimit'),'revisionHistoryLicenseKeyUsageLimit'==_0x5cd912&&_0x32c7b9['_showLicenseError']('usageLimit');},0x3e8);}async['afterInit'](){if(this['repository']['length']>0x0){const _0x4bf71e=this['repository']['getRevision'](0x0),_0x4093d2=await this['getRevisionDocumentData'](_0x4bf71e),_0x324c95=await this['getRevisionRootsAttributes'](_0x4bf71e);this['_replaceEditorDataWithRevisionData'](_0x4093d2,_0x324c95);}}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['setSource'](_0x328ba0){this['_source']=_0x328ba0;}async['update'](){const _0x1f678e=await this['_source']['getLatestVersion']();if(_0x1f678e>this['currentRevision']['toVersion']){await this['_loadState']();const _0x21f281=this['buildRevisionData']({'revision':this['currentRevision'],'to':_0x1f678e});_0x21f281['authors']=_0x21f281['authorsIds']['map'](_0x37477b=>this['editor']['plugins']['get']('Users')['getUser'](_0x37477b)),this['currentRevision']['_update'](_0x21f281);}}async['saveRevision'](_0x4a58b8={},_0x2bf369=null){const _0x14f008=[];await this['_loadState'](),this['_continueCurrentRevision']=!0x1,_0x2bf369>this['currentRevision']['toVersion']&&(_0x2bf369=null),null===_0x2bf369&&(_0x2bf369=await this['_source']['getLatestVersion']());const _0x377dad=this['_getFromVersion'](_0x2bf369),_0x5a0060=this['buildRevisionData']({'from':_0x377dad,'to':_0x2bf369});if(this['currentRevision']['toVersion']<_0x2bf369){const _0x377ecd=this['buildRevisionData']({'revision':this['currentRevision'],'from':_0x2bf369,'to':_0x2bf369});_0x377ecd['authors']=[],_0x377ecd['authorsIds']=[],_0x377ecd['id']=this['currentRevision']['id'],this['currentRevision']['_update'](_0x377ecd,!0x0),delete _0x377ecd['authors'],_0x14f008['push'](_0x377ecd);}_0x4a58b8['creatorId']=this['editor']['plugins']['get']('Users')['me']['id'],_0x4a58b8['name']=_0x4a58b8['name']||null,_0x4a58b8['id']=_0x4a58b8['id']||_0x451426(),_0x4a58b8={..._0x4a58b8,..._0x5a0060};const _0x282264=this['addRevisionData'](_0x4a58b8);_0x14f008['push'](_0x4a58b8);const _0x509f59=this['repository']['getIndex'](_0x282264);if(0x0!==_0x509f59){const _0x264460=this['repository']['getRevision'](_0x509f59-0x1);if(_0x264460['fromVersion']!==_0x2bf369){const _0x3f1d0b=this['_revisionDataBuilder']['getData'](_0x2bf369,_0x264460['toVersion']),_0x1458a8={'id':_0x264460['id'],'diffData':_0x3f1d0b['diffData'],'authorsIds':_0x3f1d0b['authorsIds'],'authors':_0x3f1d0b['authorsIds']['map'](_0x586774=>this['editor']['plugins']['get']('Users')['getUser'](_0x586774)),'fromVersion':_0x2bf369};_0x264460===this['currentRevision']&&(_0x1458a8['createdAt']=new Date(_0x4a58b8['createdAt']['getTime']()+0xa)),_0x264460['_update'](_0x1458a8,!0x0),delete _0x1458a8['authors'],_0x14f008['push'](_0x1458a8);}}if(this['adapter']){for(const _0x35c9f8 of _0x14f008)this['_bufferUpdate'](_0x35c9f8['id'],_0x35c9f8,!0x0);this['sendBufferedUpdates']();}return _0x282264;}['addRevisionData'](_0x540bbb){const _0x4de68f=this['repository']['createRevision'](_0x540bbb);return this['adapter']&&_0x4de68f['on']('_update',(_0xa094bf,_0x1f299d,_0x54c272)=>{_0x54c272||(this['_bufferUpdate'](_0x1f299d['id'],_0x1f299d,!0x0),this['sendBufferedUpdates']());}),this['repository']['addRevision'](_0x4de68f,this['_findInsertionIndex'](_0x4de68f)),_0x4de68f;}async['getRevisionDocumentData'](_0x2f22a4){return await this['_utils']['loadRevisionData'](_0x2f22a4,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x2f22a4);}async['getRevisionRootsAttributes'](_0x52ee05){return await this['_utils']['loadRevisionData'](_0x52ee05,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x52ee05);}['sendBufferedUpdates'](){if(0x0===this['_bufferedUpdates']['size'])return;if(this['_isPendingUpdate'])return;let _0x1183d7=Array['from'](this['_bufferedUpdates']['values']());this['_bufferedUpdates']['clear']();for(let _0x7ed4b1=0x0;_0x7ed4b1<_0x1183d7['length'];_0x7ed4b1++){const _0xb8cdda=_0x1183d7[_0x7ed4b1];let _0x2a3710=!0x1;for(const _0x238d8c of Object['keys'](_0xb8cdda))void 0x0===_0xb8cdda[_0x238d8c]?delete _0xb8cdda[_0x238d8c]:'id'!==_0x238d8c&&(_0x2a3710=!0x0);_0x2a3710||(_0x1183d7[_0x7ed4b1]=null);}if(_0x1183d7=_0x1183d7['filter'](_0x4469cc=>null!==_0x4469cc),!_0x1183d7['length'])return;for(let _0x54a08c=0x0;_0x54a08c<_0x1183d7['length'];_0x54a08c++){const _0x32d175=_0x1183d7[_0x54a08c];void 0x0!==_0x32d175['fromVersion']&&void 0x0===_0x32d175['toVersion']&&(_0x32d175['toVersion']=this['repository']['getRevision'](_0x32d175['id'])['toVersion']),void 0x0!==_0x32d175['toVersion']&&void 0x0===_0x32d175['fromVersion']&&(_0x32d175['fromVersion']=this['repository']['getRevision'](_0x32d175['id'])['fromVersion']);}const _0x3215ab=this['editor']['config']['get']('collaboration.channelId');this['_isPendingUpdate']=!0x0,this['_addPendingAction'](),this['adapter']['updateRevisions'](_0x1183d7,_0x3215ab)['finally'](()=>{this['_isPendingUpdate']=!0x1;})['then'](_0x3e8bce=>{if(_0x3e8bce){for(const _0x4dbcd5 of _0x3e8bce)this['setRevisionData']({'id':_0x4dbcd5['id'],'createdAt':_0x4dbcd5['createdAt']});}this['_removePendingAction'](),this['sendBufferedUpdates']();});}['buildRevisionData']({revision:_0x2526bd=null,from:_0x2d2817=null,to:_0x318d4c=null}){_0x2d2817=null!==_0x2d2817?_0x2d2817:_0x2526bd['fromVersion'],_0x318d4c=null!==_0x318d4c?_0x318d4c:_0x2526bd['toVersion'];const _0x43fc84=this['_revisionDataBuilder']['getData'](_0x2d2817,_0x318d4c),_0x1fc533={'diffData':_0x43fc84['diffData'],'authorsIds':_0x43fc84['authorsIds'],'fromVersion':_0x2d2817,'toVersion':_0x318d4c};if(!_0x2526bd||_0x318d4c!==_0x2526bd['toVersion']){const _0x13ec8d=_0x318d4c-0x1,_0x562e75=this['_source']['history']['getOperation'](_0x13ec8d);_0x1fc533['createdAt']=_0x562e75&&_0x562e75['createdAt']||new Date();}if(this['_loadedStateData']&&_0x2d2817===this['_loadedStateData']['fromVersion']){for(const _0x244c7c of this['_loadedStateData']['authors'])_0x1fc533['authorsIds']['includes'](_0x244c7c['id'])||_0x1fc533['authorsIds']['push'](_0x244c7c['id']);}return _0x1fc533;}['_bufferUpdate'](_0x58f6dc,_0x26524b,_0x3e8605){if(this['_bufferedUpdates']['has'](_0x58f6dc)){const _0x43bf64=this['_bufferedUpdates']['get'](_0x58f6dc);_0x26524b=_0x3e8605?{..._0x43bf64,..._0x26524b}:{..._0x26524b,..._0x43bf64};}this['_bufferedUpdates']['set'](_0x58f6dc,_0x26524b);}['setRevisionData'](_0x161333){const _0x461474=this['repository']['getRevision'](_0x161333['id']);if(_0x161333['createdAt']&&(_0x161333['createdAt']=new Date(_0x161333['createdAt'])),_0x161333['authorsIds']){const _0x4d68e8=this['editor']['plugins']['get']('Users');_0x161333['authors']=_0x161333['authorsIds']['map'](_0x5366ed=>_0x4d68e8['getUser'](_0x5366ed));}_0x461474['_update'](_0x161333,!0x0);}['_createInitialRevision'](_0x572449){const _0x395e09=this['repository']['getRevision'](this['repository']['length']-0x1);if(_0x395e09)this['_initialRevisionId']=_0x395e09['id'];else{const _0x2b4b45=!this['editor']['model']['document']['roots']['find'](_0x5a8849=>this['editor']['model']['hasContent'](_0x5a8849)),_0x6bee8=this['editor']['plugins']['get']('Users')['me']['id'],_0x40643c=g(this['editor']['locale'],_0x2b4b45?'Empty\x20document':'Initial\x20revision');this['_makeRevision']({'from':_0x572449,'to':_0x572449,'id':this['_initialRevisionId'],'name':_0x40643c,'creatorId':_0x6bee8});}}['_createCurrentRevision'](_0x4a9136){const _0x1baef0=this['_source']['getCurrentRevisionId']();this['currentRevision']=this['repository']['getRevision'](_0x1baef0),this['currentRevision']||(this['currentRevision']=this['_makeRevision']({'from':_0x4a9136,'to':_0x4a9136,'id':_0x1baef0,'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'](_0x561c82,_0x3bd6d8){let _0x11781b=this['editor']['config']['get']('initialData'),_0x3b1630=this['editor']['config']['get']('rootsAttributes');if(void 0x0===_0x11781b){_0x11781b={};for(const _0x32fc67 of this['editor']['model']['document']['getRootNames']())_0x11781b[_0x32fc67]='';}if('string'==typeof _0x11781b&&(_0x11781b={'main':_0x11781b}),void 0x0===_0x3b1630){_0x3b1630={};for(const _0x17d02c of this['editor']['model']['document']['getRootNames']())_0x3b1630[_0x17d02c]={};}let _0xec287b=!0x1;const _0x5e03de=Object['keys'](_0x11781b),_0x1b5986=Object['keys'](_0x561c82);for(const _0xf0c2be of _0x5e03de){if(_0x11781b[_0xf0c2be]!==_0x561c82[_0xf0c2be]&&''!==_0x11781b[_0xf0c2be]['trim']()){_0xec287b=!0x0;break;}if(!_0x4ffb34(_0x3b1630[_0xf0c2be],_0x3bd6d8[_0xf0c2be])&&Object['keys'](_0x3b1630[_0xf0c2be])['length']>0x0){_0xec287b=!0x0;break;}}_0xec287b||(_0xec287b=_0x1b5986['some'](_0x52a48e=>!this['editor']['model']['document']['getRoot'](_0x52a48e))),_0xec287b&&_0x572bf6('editor-initial-data-replaced-with-revision-data',{'editorData':_0x11781b,'editorRootsAttributes':_0x3b1630,'revisionData':_0x561c82,'revisionRootsAttributes':_0x3bd6d8}),this['editor']['config']['set']('initialData',_0x561c82),this['editor']['config']['set']('rootsAttributes',_0x3bd6d8);}['_addPendingAction'](){if(!this['_pendingAction']){const _0x45698a=this['editor']['plugins']['get']('PendingActions');this['_pendingAction']=_0x45698a['add'](g(this['editor']['locale'],'PENDING_ACTION_REVISION_HISTORY'));}}['_removePendingAction'](){this['_pendingAction']&&(this['editor']['plugins']['get']('PendingActions')['remove'](this['_pendingAction']),this['_pendingAction']=null);}['_findInsertionIndex'](_0x1d4c71){const _0x5467f4=this['repository']['getRevisions']();_0x5467f4['reverse']();let _0x20c40a=0x0;for(;_0x20c40a<_0x5467f4['length'];){const _0x40aff5=_0x5467f4[_0x20c40a];if(_0x40aff5===this['currentRevision']){_0x20c40a++;continue;}if(_0x40aff5['id']===this['_initialRevisionId'])break;const _0x24dbdf=_0x1d4c71['toVersion']-_0x40aff5['toVersion']||_0x1d4c71['fromVersion']-_0x40aff5['fromVersion'];if(_0x24dbdf>0x0)break;if(_0x24dbdf<0x0)_0x20c40a++;else{if(!_0x1d4c71['creator']&&_0x40aff5['creator'])break;if(_0x40aff5['creator']||!_0x1d4c71['creator']){if(_0x1d4c71['createdAt']>_0x40aff5['createdAt'])break;_0x20c40a++;}else _0x20c40a++;}}return _0x20c40a;}['_getFromVersion'](_0x236540){const _0x25b101=this['repository']['getRevisions']();_0x25b101['reverse'](),_0x25b101['shift']();const _0x56e59c=_0x25b101['find'](_0x1ed966=>_0x1ed966['toVersion']<=_0x236540)['toVersion'];return _0x56e59c<this['_startingVersion']?this['_startingVersion']:_0x56e59c;}['_makeRevision']({name:_0x39367d,from:_0x1be0fd,to:_0x580b0f,creatorId:_0x177918,id:_0x4fc596}){const _0x418815=this['buildRevisionData']({'from':_0x1be0fd,'to':_0x580b0f});_0x418815['name']=_0x39367d,_0x418815['creatorId']=_0x177918,_0x418815['id']=_0x4fc596;const _0x2261de=this['addRevisionData'](_0x418815);return this['adapter']&&this['_bufferUpdate'](_0x418815['id'],_0x418815,!0x0),_0x2261de;}['_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(_0x41a494){this['editor']=_0x41a494,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'](_0x4ee7a2){this['source']=_0x4ee7a2;const _0x421bd3=new Map(),_0x450256=new Map(),_0x1fc223=this['editor']['model']['document']['roots']['map'](_0x5e3c64=>_0x5e3c64['rootName']);for(const _0x41ad47 of _0x1fc223){const _0x597e27=this['editor']['model']['document']['getRoot'](_0x41ad47),_0x3250ce=N(_0x597e27);_0x421bd3['set'](_0x41ad47,_0x3250ce),_0x450256['set'](_0x41ad47,Object['fromEntries'](_0x597e27['getAttributes']()));}const _0xaa2a68=Array['from'](this['editor']['model']['markers'])['map'](_0x103c5f=>[_0x103c5f['name'],_0x103c5f['getRange']()]),_0xd36af7=this['source']['version'];this['_saveMetaData'](_0xd36af7,_0x421bd3,_0xaa2a68,_0x450256),this['_startingRevisionId']=this['_revisionId'];const _0x23538a=new Map(),_0x5b00f5=new Map();for(const _0xa0b432 of _0x1fc223){const _0x5d9d2a=P(_0xa0b432);_0x23538a['set'](_0xa0b432,_0x5d9d2a),_0x5b00f5['set'](_0xa0b432,{});}this['_saveMetaData'](Number['NEGATIVE_INFINITY'],_0x23538a,[],_0x5b00f5);}['getData'](_0xc5184b,_0x3173){if(this['_lastFrom']===_0xc5184b&&this['_lastTo']<=_0x3173)this['_savedMetaData']['size']>0x1&&this['_removeMetaData'](this['_lastTo']),this['_applyOperations'](this['_lastTo'],_0x3173,!0x0);else{if(!this['_savedMetaData']['has'](_0xc5184b)){const _0x54e40c=this['_getPreviousFrom'](_0xc5184b);this['_calculateMetaData'](_0x54e40c,_0xc5184b,!0x1);}this['_calculateMetaData'](_0xc5184b,_0x3173,!0x0);}return this['_lastFrom']=_0xc5184b,this['_lastTo']=_0x3173,this['_getState']();}['loadState'](_0x17af4a){const _0x1d18a0=this['editor']['plugins']['get']('RevisionHistoryUtils');this['_reset'](),this['_lastFrom']=_0x17af4a['fromVersion'],this['_lastTo']=_0x17af4a['toVersion'];for(const _0x514625 in _0x17af4a['diffData']){const _0x523468=_0x17af4a['diffData'][_0x514625]['attachChange'],_0x44983b=_0x36f289(_0x17af4a['diffData'][_0x514625]['attributesBefore'])||{},_0x47ebc7=_0x1d18a0['_makeModelFromViewString'](_0x17af4a['diffData'][_0x514625]['deletions']);_0x47ebc7['rootName']=_0x514625,_0x47ebc7['_isAttached']=!_0x523468||!_0x523468['isAttached'],_0x47ebc7['isAttached']=()=>_0x47ebc7['_isAttached'],this['_baseRoots']['set'](_0x514625,_0x47ebc7),this['_baseRootsAttributes']['set'](_0x514625,_0x44983b),_0x523468&&this['_touchedRoots']['set'](_0x514625,_0x523468);const _0x141fbd=this['_makeIdsRoot'](_0x47ebc7);this['_baseIdsRoots']['set'](_0x514625,_0x141fbd);for(const [_0x14541f,_0x3d0d9c]of _0x47ebc7['markers']){if(!_0x14541f['startsWith']('revision:'))continue;const _0xf46957=_0x14541f['split'](':')[0x2];for(const _0x4f81bd of _0x3d0d9c['getWalker']({'singleCharacters':!0x0})){const _0x36734e=this['_getVidAttributeName'](_0x4f81bd),_0xf92552='elementEnd'==_0x4f81bd['type']?_0x4f81bd['previousPosition']['path']['slice'](0x0,-0x1):_0x4f81bd['previousPosition']['path'],_0x69c053=_0x141fbd['getNodeByPath'](_0xf92552)['getAttribute'](_0x36734e);this['_touched']['set'](_0x69c053,{'userId':_0xf46957});}}}this['_startingRevisionId']=this['_revisionId'];const _0x19d1a8=[...Array(this['_revisionId'])['keys']()]['slice'](0x1)['filter'](_0x202001=>!this['_touched']['has'](_0x202001));let _0x5877dd=0x0;const _0x5021e2=new Map();for(const _0x47494c in _0x17af4a['diffData']){const _0x472d6f=_0x17af4a['diffData'][_0x47494c]['attachChange'],_0x522ef9=_0x36f289(_0x17af4a['diffData'][_0x47494c]['attributesAfter'])||{},_0x2a1758=_0x1d18a0['_makeModelFromViewString'](_0x17af4a['diffData'][_0x47494c]['insertions']);_0x2a1758['rootName']=_0x47494c,_0x2a1758['_isAttached']=!_0x472d6f||_0x472d6f['isAttached'],_0x2a1758['isAttached']=()=>_0x2a1758['_isAttached'],this['_diffRoots']['set'](_0x47494c,_0x2a1758),this['_diffRootsAttributes']['set'](_0x47494c,_0x522ef9);const _0x19b57a=this['_makeIdsRoot'](_0x2a1758,Number['NEGATIVE_INFINITY']);this['_idsRoots']['set'](_0x47494c,_0x19b57a),_0x5021e2['set'](_0x47494c,_0x2a1758['isAttached']()?_0x522ef9:{});for(const [_0xf2c72f,_0xa5e36d]of _0x2a1758['markers']){if(!_0xf2c72f['startsWith']('revision:'))continue;const _0x1ef01=_0xf2c72f['split'](':')[0x2];for(const _0x13ae1e of _0xa5e36d['getWalker']({'singleCharacters':!0x0})){const _0xc59763=this['_getVidAttributeName'](_0x13ae1e),_0x2dafdf=this['_revisionId']++,_0x13dcd5='elementEnd'==_0x13ae1e['type']?_0x13ae1e['previousPosition']['path']['slice'](0x0,-0x1):_0x13ae1e['previousPosition']['path'];_0x19b57a['getNodeByPath'](_0x13dcd5)['_setAttribute'](_0xc59763,_0x2dafdf),this['_touched']['set'](_0x2dafdf,{'userId':_0x1ef01});}}for(const _0x26cdfa of this['editor']['model']['createRangeIn'](_0x2a1758)['getWalker']({'singleCharacters':!0x0})){const _0x3dbecd=this['_getVidAttributeName'](_0x26cdfa),_0x4a1e29='elementEnd'==_0x26cdfa['type']?_0x26cdfa['previousPosition']['path']['slice'](0x0,-0x1):_0x26cdfa['previousPosition']['path'],_0x5b8902=_0x19b57a['getNodeByPath'](_0x4a1e29);_0x5b8902['getAttribute'](_0x3dbecd)>0x0||_0x5b8902['_setAttribute'](_0x3dbecd,_0x19d1a8[_0x5877dd++]);}for(const [_0x9059b8,_0x17f4e4]of _0x2a1758['markers'])_0x9059b8['startsWith']('revision:')||this['_markers']['set'](_0x9059b8,_0x17f4e4);}const _0x188c17=P('$graveyard');this['_baseRoots']['set']('$graveyard',_0x188c17),this['_baseIdsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x188c17,0x1));const _0x249b1f=P('$graveyard');this['_diffRoots']['set']('$graveyard',_0x249b1f),this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x249b1f,0x1));const _0xc924f2=Array['from'](this['_diffRoots'])['map'](([_0x5294f3,_0x38f96a])=>[_0x5294f3,N(_0x38f96a)]);this['_saveMetaData'](this['_lastTo'],_0xc924f2,this['_markers'],_0x5021e2);}['reInit'](){this['_reset'](),this['_lastFrom']=-0x1,this['_lastTo']=-0x1,this['_savedMetaData']['clear'](),this['init'](this['source']);}['_saveMetaData'](_0x35419d,_0x26e088,_0x59e77f,_0x454ddc){const _0x55efe2=new Map(_0x26e088),_0x268a09=new Map(_0x36f289(_0x454ddc)),_0x1542d7=new Map();for(const [_0x324a82,_0x2ae49f]of _0x59e77f)_0x1542d7['set'](_0x324a82,{'start':_0x2ae49f['start']['clone'](),'end':_0x2ae49f['end']['clone'](),'rootName':_0x2ae49f['root']['rootName']});this['_savedMetaData']['set'](_0x35419d,{'roots':_0x55efe2,'markers':_0x1542d7,'rootsAttributes':_0x268a09});}['_removeMetaData'](_0x394398){this['_savedMetaData']['delete'](_0x394398);}['_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'](_0x1edfbe,_0x3d580b=null){let _0x2fe6d0=null;_0x1edfbe['is']('documentFragment')||(_0x2fe6d0=new ut(_0x1edfbe['name'],{'vid_start':null===_0x3d580b?this['_revisionId']++:_0x3d580b++}));const _0xe2ed05=[];for(const _0x48fac0 of _0x1edfbe['getChildren']())if(_0x48fac0['is']('element')){_0xe2ed05['push'](this['_makeIdsRoot'](_0x48fac0,_0x3d580b));const _0x7ed459=_0xe2ed05[_0xe2ed05['length']-0x1];null!==_0x3d580b&&(_0x3d580b=_0x7ed459['is']('element','$text')?_0x7ed459['getAttribute']('vid')+0x1:_0x7ed459['getAttribute']('vid_end')+0x1);}else{for(let _0x12c997=0x0;_0x12c997<_0x48fac0['offsetSize'];_0x12c997++)_0xe2ed05['push'](new ut('$text',{'vid':null===_0x3d580b?this['_revisionId']++:_0x3d580b++}));}if(_0x1edfbe['is']('documentFragment')){const _0x5595ee=P(_0x1edfbe['rootName']);return _0x5595ee['_insertChild'](0x0,_0xe2ed05),_0x5595ee;}return _0x2fe6d0['_setAttribute']('vid_end',null===_0x3d580b?this['_revisionId']++:_0x3d580b++),_0x2fe6d0['_insertChild'](0x0,_0xe2ed05),_0x2fe6d0;}['_calculateMetaData'](_0x293a32,_0x124794,_0x1d99e5){this['_reset']();const {roots:_0xaa6d33,markers:_0x407c58,rootsAttributes:_0x668982}=this['_savedMetaData']['get'](_0x293a32);this['_baseRoots']=new Map(_0xaa6d33),this['_baseRootsAttributes']=new Map(_0x36f289(_0x668982));for(const [_0x578190,_0x3279a0]of this['_baseRoots'])if('$graveyard'!==_0x578190&&(this['_diffRoots']['set'](_0x578190,N(_0x3279a0)),this['_diffRootsAttributes']=new Map(_0x36f289(_0x668982)),_0x1d99e5)){const _0x36f251=this['_revisionId'];this['_idsRoots']['set'](_0x578190,this['_makeIdsRoot'](_0x3279a0)),this['_baseIdsRoots']['set'](_0x578190,this['_makeIdsRoot'](_0x3279a0,_0x36f251));}this['_startingRevisionId']=this['_revisionId'],this['_diffRoots']['set']('$graveyard',N(this['_baseRoots']['get']('$graveyard'))),_0x1d99e5&&this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](this['_baseRoots']['get']('$graveyard')));for(const [_0x4a479b,_0x51e6c3]of _0x407c58){const _0x3ee25c=this['_baseRoots']['get'](_0x51e6c3['rootName']),_0x410cb6=this['_diffRoots']['get'](_0x51e6c3['rootName']),_0x3e9434=new lt(this['_fixPosition'](_0x51e6c3['start'],_0x3ee25c),this['_fixPosition'](_0x51e6c3['end'],_0x3ee25c)),_0x257492=this['_fixRange'](_0x3e9434,_0x410cb6);_0x3ee25c['markers']['set'](_0x4a479b,_0x3e9434),this['_markers']['set'](_0x4a479b,_0x257492);}this['_applyOperations'](_0x293a32,_0x124794,_0x1d99e5);}['_applyOperations'](_0x5189cc,_0x3ad93f,_0x2c482a){for(const _0x40980d of this['source']['getOperations'](_0x5189cc,_0x3ad93f))this['_handleOperation'](_0x40980d,_0x2c482a);for(const _0x19b8d4 of this['_diffRoots']['values']())_0x19b8d4['markers']['clear']();for(const [_0x25fe9a,_0x2a8524]of this['_markers']){this['_diffRoots']['get'](_0x2a8524['root']['rootName'])['markers']['set'](_0x25fe9a,_0x2a8524['clone']());}const _0x905fb=new Map(),_0x1e9a2c=new Map();for(const [_0x1b24b9,_0x5a8c53]of this['_diffRoots'])_0x905fb['set'](_0x1b24b9,N(_0x5a8c53)),_0x1e9a2c['set'](_0x1b24b9,this['_diffRootsAttributes']['get'](_0x1b24b9));this['_saveMetaData'](_0x3ad93f,_0x905fb,this['_markers'],_0x1e9a2c);}['_getPreviousFrom'](_0x12f73d){const _0x434711=Array['from'](this['_savedMetaData']['keys']());_0x434711['sort']((_0x1702b4,_0x22e4c0)=>_0x1702b4-_0x22e4c0),_0x434711['reverse']();for(const _0x270d1f of _0x434711)if(_0x270d1f<_0x12f73d)return _0x270d1f;return Number['NEGATIVE_INFINITY'];}['_copyMarkers'](_0x18d30a,_0x44ab4f){const _0x85bc62=Array['from'](_0x44ab4f['markers'])['map'](([_0x356ed8,_0x423499])=>[_0x356ed8,this['_fixRange'](_0x423499,_0x18d30a)]);_0x18d30a['markers']=new Map(_0x85bc62);}['_transformMarkers'](_0x5c1ce1){for(const _0x23117c of this['_markers']['values']()){const _0x419e5b=_0x23117c['getTransformedByOperation'](_0x5c1ce1),_0x953940=lt['_createFromRanges'](_0x419e5b);_0x23117c['start']=_0x953940['start'],_0x23117c['end']=_0x953940['end'];}}['_handleOperation'](_0x43fcfa,_0x352f4a){if('addRoot'!=_0x43fcfa['type']&&'detachRoot'!=_0x43fcfa['type']){if('insert'==_0x43fcfa['type']){const _0xa06b31=_0x43fcfa['position']['root']['rootName'];this['_diffRoots']['has'](_0xa06b31)||(this['_diffRoots']['set'](_0xa06b31,P(_0xa06b31,!0x0)),this['_diffRootsAttributes']['set'](_0xa06b31,{}),_0x352f4a&&this['_idsRoots']['set'](_0xa06b31,P(_0xa06b31,!0x0)));}else{if('addRootAttribute'==_0x43fcfa['type']||'removeRootAttribute'==_0x43fcfa['type']||'changeRootAttribute'==_0x43fcfa['type'])return void this['_handleRootAttributeOperation'](_0x43fcfa);'marker'==_0x43fcfa['type']&&this['_handleMarkerOperation'](_0x43fcfa);}if('marker'!==_0x43fcfa['type']){const _0x1c3211=this['_cloneOperation'](_0x43fcfa,this['_diffRoots']);_0x1c3211['_execute'](),this['_transformMarkers'](_0x1c3211);}if(_0x352f4a)switch(_0x43fcfa['type']){case'insert':this['_handleInsertOperation'](_0x43fcfa);break;case'move':case'remove':case'reinsert':this['_handleMoveOperation'](_0x43fcfa);break;case'merge':this['_handleMergeOperation'](_0x43fcfa);break;case'split':this['_handleSplitOperation'](_0x43fcfa);}}else this['_handleRootOperation'](_0x43fcfa,_0x352f4a);}['_cloneOperation'](_0x3daeb4,_0x50d8ce){const _0xcdbcaf=_0x3daeb4['clone']();return _0xcdbcaf['_authorId']=_0x3daeb4['_authorId'],this['_fixOperation'](_0xcdbcaf,_0x50d8ce),_0xcdbcaf;}['_getBaseVids'](_0x50ff87){return _0x50ff87['map'](_0x550a7a=>{const _0xb91be0=this['_getVidAttributeName'](_0x550a7a);return Number(_0x550a7a['item']['getAttribute'](_0xb91be0));});}['_generateTape'](_0x37ec04,_0x637c4e){if(_0x37ec04['is']('element','$text'))_0x637c4e['push']({'item':_0x37ec04,'type':'text'});else{_0x37ec04['is']('element')&&_0x637c4e['push']({'item':_0x37ec04,'type':'elementStart'});for(const _0x5da0ee of _0x37ec04['getChildren']())this['_generateTape'](_0x5da0ee,_0x637c4e);_0x37ec04['is']('element')&&_0x637c4e['push']({'item':_0x37ec04,'type':'elementEnd'});}return _0x637c4e;}['_getState'](){const _0x5f49f3=new Map(this['_touched']),_0x6326b5=new Map(_0x5f49f3),_0x29d491=new Map(),_0x31d825={'insertions':{},'deletions':{}},_0x2c8887={'insertions':{},'deletions':{}},_0x1428ae=new Map(),_0x5ce9b7=new Set([...this['_baseRoots']['keys'](),...this['_diffRoots']['keys']()]);_0x5ce9b7['delete']('$graveyard');for(const _0x46e723 of _0x5ce9b7){const _0x302b56=this['_diffRoots']['get'](_0x46e723)||P(_0x46e723,!0x1),_0x450054=this['_baseRoots']['get'](_0x46e723)||P(_0x46e723,!0x1);_0x302b56['isAttached']()||_0x450054['isAttached']()?(_0x31d825['insertions'][_0x46e723]=N(_0x302b56),_0x31d825['deletions'][_0x46e723]=N(_0x450054),this['_copyMarkers'](_0x31d825['deletions'][_0x46e723],_0x450054),this['_copyMarkers'](_0x31d825['insertions'][_0x46e723],_0x302b56),_0x2c8887['insertions'][_0x46e723]=this['_generateTape'](this['_idsRoots']['get'](_0x46e723),[]),_0x2c8887['deletions'][_0x46e723]=this['_generateTape'](this['_baseIdsRoots']['get'](_0x46e723)||P(_0x46e723,!0x1),[])):_0x5ce9b7['delete'](_0x46e723);}for(const _0x51b728 of _0x5ce9b7){const _0xc70d0f=_0x2c8887['insertions'][_0x51b728];for(const _0x9e2301 of _0xc70d0f){const _0x5e27b3=this['_getVidAttributeName'](_0x9e2301),_0x4b5a3b=_0x9e2301['item']['getAttribute'](_0x5e27b3);_0x6326b5['delete'](_0x4b5a3b),_0x4b5a3b>=this['_startingRevisionId']&&_0x29d491['set'](_0x4b5a3b,_0x5f49f3['get'](_0x4b5a3b));}}for(const _0x4a0f19 of _0x5ce9b7){const _0x3f1332=_0x2c8887['insertions'][_0x4a0f19],_0xc71957=this['_getBaseVids'](_0x2c8887['deletions'][_0x4a0f19]);let _0x52f8e3=0x0;for(const _0x3a62b2 of _0x3f1332){const _0x479ac3=this['_getVidAttributeName'](_0x3a62b2),_0x51353b=_0x3a62b2['item']['getAttribute'](_0x479ac3);if(!_0x29d491['has'](_0x51353b)&&!_0x1428ae['has'](_0x51353b)){if(_0x6326b5['has'](_0x51353b))_0x52f8e3++;else{if(_0x51353b!=_0xc71957[_0x52f8e3]){const _0x55d8f2=_0x5f49f3['get'](_0x51353b)||_0x5f49f3['get'](_0xc71957[_0x52f8e3]);for(;_0x51353b!=_0xc71957[_0x52f8e3];)_0x6326b5['has'](_0xc71957[_0x52f8e3])||(_0x1428ae['set'](_0xc71957[_0x52f8e3],_0x55d8f2),_0x5f49f3['set'](_0xc71957[_0x52f8e3],_0x55d8f2)),_0x52f8e3++;}_0x52f8e3++;}}}}for(const _0x9633b3 of _0x5ce9b7){const _0x11f0af=_0x2c8887['insertions'][_0x9633b3];for(const _0x86215e of _0x11f0af){const _0x41e8a2=this['_getVidAttributeName'](_0x86215e),_0x1f8438=_0x86215e['item']['getAttribute'](_0x41e8a2);if(_0x1428ae['has'](_0x1f8438)){const _0x519d2d=_0x1428ae['get'](_0x1f8438);_0x6326b5['has'](_0x1f8438)||_0x6326b5['set'](_0x1f8438,{..._0x519d2d}),_0x29d491['set'](_0x1f8438,{..._0x519d2d});}}}for(const _0x406473 of _0x6326b5['keys']())_0x406473>=this['_startingRevisionId']&&_0x6326b5['delete'](_0x406473);const _0x386dca=new Map();for(const _0x17fda8 of _0x5ce9b7){let _0x3b82b9=_0x2c8887['insertions'][_0x17fda8];for(const _0x545a17 of _0x3b82b9)if(_0x545a17['item']['is']('element','tableCell')){const _0x5a252a=this['_getVidAttributeName'](_0x545a17),_0x1904cd=_0x545a17['item']['getAttribute'](_0x5a252a);if(_0x29d491['has'](_0x1904cd)){const _0x11a1af=_0x545a17['item']['parent']['parent']['getAttribute']('vid_start'),_0x5b6dc1=_0x386dca['get'](_0x11a1af)||new Set();_0x5b6dc1['add'](_0x29d491['get'](_0x1904cd)['userId']),_0x386dca['set'](_0x11a1af,_0x5b6dc1);}}_0x3b82b9=_0x2c8887['deletions'][_0x17fda8];for(const _0x59f51b of _0x3b82b9)if(_0x59f51b['item']['is']('element','tableCell')){const _0x402f43=this['_getVidAttributeName'](_0x59f51b),_0x5c00f8=_0x59f51b['item']['getAttribute'](_0x402f43);if(_0x6326b5['has'](_0x5c00f8)){const _0x2955b0=_0x59f51b['item']['parent']['parent']['getAttribute']('vid_start'),_0x59326e=_0x386dca['get'](_0x2955b0)||new Set();_0x59326e['add'](_0x6326b5['get'](_0x5c00f8)['userId']),_0x386dca['set'](_0x2955b0,_0x59326e);}}for(const _0x218855 of _0x386dca['keys']())(_0x29d491['has'](_0x218855)||_0x6326b5['has'](_0x218855))&&_0x386dca['delete'](_0x218855);}for(const _0x42b2b2 of _0x5ce9b7){const _0x425c25=_0x2c8887['insertions'][_0x42b2b2];let _0x3f1039=null,_0x3c4b72=null;for(const _0x3801df of _0x425c25){const _0x203601=this['_getVidAttributeName'](_0x3801df),_0x71b32f=_0x3801df['item']['getAttribute'](_0x203601),_0x15f38c=_0x386dca['get'](_0x71b32f);_0x15f38c&&'elementStart'==_0x3801df['type']&&(_0x3f1039=Array['from'](_0x15f38c)[0x0],_0x3c4b72=_0x3801df['item']['getAttribute']('vid_end')),_0x3f1039&&(_0x6326b5['set'](_0x71b32f,{'userId':_0x3f1039}),_0x29d491['set'](_0x71b32f,{'userId':_0x3f1039})),_0x71b32f==_0x3c4b72&&(_0x3f1039=null,_0x3c4b72=null);}}const _0x17ff1e={},_0x3b6054=new Set();for(const _0x5c269c of _0x5ce9b7){const _0x232cfa=_0x31d825['deletions'][_0x5c269c],_0x273365=_0x31d825['insertions'][_0x5c269c];for(const {userId:_0x5b5bb0}of this['_touchedMarkers']['values']())null!==_0x5b5bb0&&_0x3b6054['add'](_0x5b5bb0);for(const {userId:_0x165e5f}of this['_touchedRoots']['values']())null!==_0x165e5f&&_0x3b6054['add'](_0x165e5f);this['_markChanges'](_0x273365,_0x2c8887['insertions'][_0x5c269c],_0x29d491,'insertion',_0x3b6054),this['_markChanges'](_0x232cfa,_0x2c8887['deletions'][_0x5c269c],_0x6326b5,'deletion',_0x3b6054),_0x17ff1e[_0x5c269c]={'insertions':this['_prepareViewToSave'](_0x273365),'deletions':this['_prepareViewToSave'](_0x232cfa),'attachChange':this['_touchedRoots']['get'](_0x5c269c)||null,'attributesBefore':_0x36f289(this['_baseRootsAttributes']['get'](_0x5c269c))||{},'attributesAfter':_0x36f289(this['_diffRootsAttributes']['get'](_0x5c269c))};}return{'diffData':_0x17ff1e,'authorsIds':Array['from'](_0x3b6054)};}['_processRootBeforeSave'](_0x41a7f1){for(const [,_0x19bbe0]of _0x41a7f1['markers']){const _0x400877=_0x19bbe0['start']['getAncestors']()['filter'](_0x7264c0=>'tableCell'==_0x7264c0['name']);for(const _0x26e858 of _0x400877)0x1==_0x26e858['childCount']&&_0x26e858['getChild'](0x0)['is']('element','paragraph')&&_0x26e858['getChild'](0x0)['_setAttribute']('keepParagraph',!0x0);}}['_prepareViewToSave'](_0x1e1ff6){this['_processRootBeforeSave'](_0x1e1ff6);const _0x4d0099=this['editor']['data']['toView'](_0x1e1ff6,{}),_0x3a2686=Array['from'](_0x4d0099['getChildren']())['map'](_0x310bb6=>this['_getViewJson'](_0x310bb6));return JSON['stringify'](_0x3a2686);}['_getViewJson'](_0x5d9103){if(_0x5d9103['is']('$text'))return _0x5d9103['data'];{const _0x3df6e4=this['editor']['plugins']['get']('RevisionHistoryUtils'),_0xcd1216=_0x5d9103,_0x4c03ad=this['editor']['data']['htmlProcessor']['domConverter'],_0x278afa={'type':_0x3df6e4['_getTypeCharForViewElement'](_0xcd1216),'name':_0xcd1216['name'],'attributes':Array['from'](_0xcd1216['getAttributes']()),'children':Array['from'](_0xcd1216['getChildren']())['map'](_0x3fc44a=>this['_getViewJson'](_0x3fc44a))};if(_0x5d9103['is']('uiElement')&&'$comment'!=_0x5d9103['name']){const _0x2d469c=_0x5d9103['render'](_0x4c03ad['domDocument'],_0x4c03ad);_0x278afa['children']['push'](_0x2d469c['outerHTML']);}else{if(_0x5d9103['is']('rawElement')){const _0x4753b9=_0x4c03ad['domDocument']['createElement'](_0xcd1216['name']);_0x5d9103['render'](_0x4753b9,_0x4c03ad),_0x278afa['children']['push'](_0x4753b9['innerHTML']);}}const _0x4ae966=Array['from'](_0xcd1216['getCustomProperties']());_0x4ae966['length']>0x0&&(_0x278afa['customProperties']=_0x4ae966);const _0x5ec59b=_0xcd1216['getFillerOffset']();return null!==_0x5ec59b&&(_0x278afa['fillerOffset']=_0x5ec59b),_0x278afa;}}['_markChanges'](_0x3f4a16,_0x58a16b,_0x1e1b2c,_0x24b61e,_0x114d07){let _0x182ec3=null,_0x1f137b=null,_0x1e189b=0x0;const _0x19f232=this['editor']['model'];for(let _0xde32d2=0x0;_0xde32d2<_0x58a16b['length'];_0xde32d2++){const _0x3d5b88=this['_getVidAttributeName'](_0x58a16b[_0xde32d2]),_0x33b786=_0x58a16b[_0xde32d2]['item']['getAttribute'](_0x3d5b88),_0x364f27=_0x1e1b2c['get'](_0x33b786),_0x38fec3=_0xde32d2==_0x58a16b['length']-0x1;(!_0x182ec3&&_0x364f27&&(_0x182ec3=_0x364f27,_0x1f137b=_0x58a16b[_0xde32d2]),_0x182ec3&&(!_0x364f27||_0x364f27['userId']!=_0x182ec3['userId']))&&(_0x5b7aca(_0x364f27,F(_0x1f137b,_0x3f4a16,_0x19f232),F(_0x58a16b[_0xde32d2],_0x3f4a16,_0x19f232)),_0x182ec3=_0x364f27||null,_0x1f137b=_0x364f27?_0x58a16b[_0xde32d2]:null),_0x182ec3&&_0x38fec3&&_0x5b7aca(_0x364f27,F(_0x1f137b,_0x3f4a16,_0x19f232),B(_0x58a16b[_0xde32d2],_0x3f4a16,_0x19f232));}function _0x5b7aca(_0x3f45c6,_0x41f18d,_0xfe9161){const _0x21516d=_0x182ec3['userId'],_0x559f2d='revision:'+_0x24b61e+':'+_0x21516d+':'+_0x1e189b++,_0x5b0541=_0x19f232['createRange'](_0x41f18d,_0xfe9161);_0x3f4a16['markers']['set'](_0x559f2d,_0x5b0541),null!==_0x21516d&&_0x114d07['add'](_0x21516d);}}['_getVidAttributeName'](_0x55008f){switch(_0x55008f['type']){case'elementStart':return'vid_start';case'elementEnd':return'vid_end';default:return'vid';}}['_fixOperation'](_0xf84edd,_0x5d4e60){_0xf84edd['baseVersion']=null;for(const _0x4439ae in _0xf84edd){const _0xd8d9be=_0xf84edd[_0x4439ae];if(_0xd8d9be instanceof ft){const _0x299d34=_0x5d4e60['get'](_0xd8d9be['root']['rootName']);_0xf84edd[_0x4439ae]=this['_fixPosition'](_0xd8d9be,_0x299d34);}if(_0xd8d9be instanceof lt){const _0x3d5321=_0x5d4e60['get'](_0xd8d9be['root']['rootName']);_0xf84edd[_0x4439ae]=this['_fixRange'](_0xd8d9be,_0x3d5321);}'root'===_0x4439ae&&(_0xf84edd['root']=_0x5d4e60['get'](_0xf84edd['root']['rootName']));}}['_fixRange'](_0x3d8714,_0x5c6d3a){return this['editor']['model']['createRange'](this['_fixPosition'](_0x3d8714['start'],_0x5c6d3a),this['_fixPosition'](_0x3d8714['end'],_0x5c6d3a));}['_fixPosition'](_0x5cb701,_0x525976){return this['editor']['model']['createPositionFromPath'](_0x525976,_0x5cb701['path'],_0x5cb701['stickiness']);}['_handleInsertOperation'](_0x262b45){const _0x5307a9=this['_idsRoots']['get'](_0x262b45['position']['root']['rootName']),_0x3b0610=this['_fixPosition'](_0x262b45['position'],_0x5307a9),_0x27e9a2=null===_0x262b45['_authorId']?null:_0x262b45['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x68cd7f=_0x3b0610['parent'],_0x4161ea=this['_revisionId'],_0x2906b4=[];for(const _0xf24ed1 of _0x262b45['nodes'])if(_0xf24ed1['is']('element'))_0x2906b4['push'](this['_makeIdsRoot'](_0xf24ed1));else{for(let _0x438acd=0x0;_0x438acd<_0xf24ed1['offsetSize'];_0x438acd++)_0x2906b4['push'](new ut('$text',{'vid':this['_revisionId']++}));}const _0x4e139a=this['_revisionId'];for(let _0x450f8e=_0x4161ea;_0x450f8e<_0x4e139a;_0x450f8e++)this['_touched']['set'](_0x450f8e,{'userId':_0x27e9a2});_0x68cd7f['_insertChild'](_0x3b0610['offset'],_0x2906b4);}['_handleMoveOperation'](_0x3bd06d){(_0x3bd06d=this['_cloneOperation'](_0x3bd06d,this['_idsRoots']))['_execute']();const _0x1e2495=null===_0x3bd06d['_authorId']?null:_0x3bd06d['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x171eb8=_0x3bd06d['getMovedRangeStart'](),_0x1b0eb1=_0x171eb8['parent'],_0x370494=_0x171eb8['offset'];!function _0x4da2b3(_0x2781f9,_0x7c4ce4,_0x562275,_0xdd6d93){for(let _0x539633=_0x562275;_0x539633<_0xdd6d93;_0x539633++){const _0x148328=_0x7c4ce4['getChild'](_0x539633);_0x148328['is']('element','$text')?_0x2781f9['set'](_0x148328['getAttribute']('vid'),{'userId':_0x1e2495}):(_0x2781f9['set'](_0x148328['getAttribute']('vid_start'),{'userId':_0x1e2495}),_0x4da2b3(_0x2781f9,_0x148328,0x0,_0x148328['childCount']),_0x2781f9['set'](_0x148328['getAttribute']('vid_end'),{'userId':_0x1e2495}));}}(this['_touched'],_0x1b0eb1,_0x370494,_0x370494+_0x3bd06d['howMany']);}['_handleMergeOperation'](_0x32ab64){const _0xe4acb8=null===(_0x32ab64=this['_cloneOperation'](_0x32ab64,this['_idsRoots']))['_authorId']?null:_0x32ab64['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x5c01fb=_0x32ab64['targetPosition']['parent'],_0x56d082=_0x32ab64['sourcePosition']['parent'],_0x21fdd8=_0x5c01fb['getAttribute']('vid_end'),_0x401b3c=_0x56d082['getAttribute']('vid_start');_0x5c01fb['_setAttribute']('vid_end',_0x56d082['getAttribute']('vid_end')),_0x56d082['_setAttribute']('vid_end',_0x21fdd8),this['_touched']['set'](_0x401b3c,{'userId':_0xe4acb8}),this['_touched']['set'](_0x21fdd8,{'userId':_0xe4acb8}),_0x32ab64['_execute']();}['_handleSplitOperation'](_0x5404af){const _0x1b9821=null===(_0x5404af=this['_cloneOperation'](_0x5404af,this['_idsRoots']))['_authorId']?null:_0x5404af['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x568084=_0x5404af['graveyardPosition'],_0x5f4015=_0x5404af['splitPosition']['parent'];_0x5404af['_execute']();const _0x271da5=_0x5f4015['getAttribute']('vid_end'),_0x3c58d2=_0x5404af['insertionPosition']['nodeAfter'];if(_0x568084){const _0x5973b6=_0x3c58d2['getAttribute']('vid_end'),_0x39d990=_0x5f4015['getAttribute']('vid_end');_0x5f4015['_setAttribute']('vid_end',_0x5973b6),_0x3c58d2['_setAttribute']('vid_end',_0x39d990),this['_touched']['set'](_0x5f4015['getAttribute']('vid_end'),{'userId':_0x1b9821}),this['_touched']['set'](_0x3c58d2['getAttribute']('vid_start'),{'userId':_0x1b9821});}else{const _0x5a350b=this['_revisionId']++,_0x171fb8=this['_revisionId']++;_0x5f4015['_setAttribute']('vid_end',_0x5a350b),_0x3c58d2['_setAttribute']('vid_start',_0x171fb8),_0x3c58d2['_setAttribute']('vid_end',_0x271da5),this['_touched']['set'](_0x5a350b,{'userId':_0x1b9821}),this['_touched']['set'](_0x171fb8,{'userId':_0x1b9821});}}['_handleMarkerOperation'](_0x375dc1){if(!_0x375dc1['affectsData'])return;const _0x438f89=(_0x375dc1=this['_cloneOperation'](_0x375dc1,this['_diffRoots']))['oldRange']?_0x375dc1['oldRange']['root']:null,_0x4272e3=_0x375dc1['newRange']?_0x375dc1['newRange']['root']:null;_0x438f89&&this['_markers']['delete'](_0x375dc1['name']),_0x4272e3&&this['_markers']['set'](_0x375dc1['name'],_0x375dc1['newRange']['clone']());const _0xcfed27=null===_0x375dc1['_authorId']?null:_0x375dc1['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x575bbd=_0x375dc1['name'];if(!this['_touchedMarkers']['has'](_0x575bbd))return void this['_touchedMarkers']['set'](_0x575bbd,{'range':_0x375dc1['oldRange'],'userId':_0xcfed27});const _0x12bf72=this['_touchedMarkers']['get'](_0x575bbd),_0x9bc576=_0x12bf72['range'],_0x279a03=_0x375dc1['newRange'];null==_0x9bc576&&null==_0x279a03||_0x9bc576&&_0x279a03&&_0x9bc576['isEqual'](_0x279a03)?this['_touchedMarkers']['delete'](_0x375dc1['name']):_0x12bf72['userId']=_0xcfed27;}['_handleRootOperation'](_0xa93cfc,_0x4bf02c){this['_diffRoots']['has'](_0xa93cfc['rootName'])?this['_diffRoots']['get'](_0xa93cfc['rootName'])['_isAttached']=_0xa93cfc['isAdd']:(this['_diffRoots']['set'](_0xa93cfc['rootName'],P(_0xa93cfc['rootName'],!0x0)),this['_diffRootsAttributes']['set'](_0xa93cfc['rootName'],{}),_0x4bf02c&&this['_idsRoots']['set'](_0xa93cfc['rootName'],P(_0xa93cfc['rootName'],!0x0)));const _0x5b5fbc=null===_0xa93cfc['_authorId']?null:_0xa93cfc['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x403f89=this['_touchedRoots']['get'](_0xa93cfc['rootName']);_0x403f89&&_0x403f89['userId']===_0x5b5fbc?this['_touchedRoots']['delete'](_0xa93cfc['rootName']):this['_touchedRoots']['set'](_0xa93cfc['rootName'],{'userId':_0x5b5fbc,'isAttached':_0xa93cfc['isAdd']});}['_handleRootAttributeOperation'](_0x55fa24){const _0x3593c0=this['_diffRootsAttributes']['get'](_0x55fa24['root']['rootName']);null===_0x55fa24['newValue']?delete _0x3593c0[_0x55fa24['key']]:_0x3593c0[_0x55fa24['key']]=_0x55fa24['newValue'];}}function N(_0x57bb9f){const _0xcfb389=P(_0x57bb9f['rootName'],_0x57bb9f['isAttached']());for(const _0x2332b2 of _0x57bb9f['getChildren']()){const _0x2729ae=_0x2332b2['_clone'](!0x0);_0xcfb389['_appendChild'](_0x2729ae);}return _0xcfb389;}function P(_0x434ad7,_0x44c56f=!0x0){const _0x581458=new vt();return _0x581458['rootName']=_0x434ad7,_0x581458['_isAttached']=_0x44c56f,_0x581458['isAttached']=()=>_0x581458['_isAttached'],_0x581458;}function F(_0x1b523b,_0x49b00e,_0xcfc8e2){const _0x35e07b='elementEnd'==_0x1b523b['type']?_0xcfc8e2['createPositionAt'](_0x1b523b['item'],'end'):_0xcfc8e2['createPositionBefore'](_0x1b523b['item']);return _0xcfc8e2['createPositionFromPath'](_0x49b00e,_0x35e07b['path'],_0x35e07b['stickiness']);}function B(_0x27987f,_0x517c85,_0x5263a3){const _0x23275b='elementStart'==_0x27987f['type']?_0x5263a3['createPositionAt'](_0x27987f['item'],0x0):_0x5263a3['createPositionAfter'](_0x27987f['item']);return _0x5263a3['createPositionFromPath'](_0x517c85,_0x23275b['path'],_0x23275b['stickiness']);}class hs extends ts{['focusTracker'];['keystrokes'];['revisionNameInputView'];constructor(_0x13a62c,_0xb7a8e4){super(_0x13a62c),this['focusTracker']=new _0x5a36b0(),this['keystrokes']=new _0x37dc31(),this['set']('revisionNameInputValue',''),this['revisionNameInputView']=this['_createRevisionNameInput'](_0xb7a8e4),this['setTemplate']({'tag':'form','attributes':{'class':['ck','ck-revision-history-save-revision-form','ck-responsive-form'],'tabindex':'-1'},'children':[this['revisionNameInputView']]}),_0x1d874c(this);}['render'](){super['render'](),_0x5b119f({'view':this}),this['focusTracker']['add'](this['revisionNameInputView']['element']),this['keystrokes']['listenTo'](this['element']);const _0x2578dd=_0x1f4fdf=>_0x1f4fdf['stopPropagation']();this['keystrokes']['set']('arrowright',_0x2578dd),this['keystrokes']['set']('arrowleft',_0x2578dd),this['keystrokes']['set']('arrowup',_0x2578dd),this['keystrokes']['set']('arrowdown',_0x2578dd);}['focus'](){this['revisionNameInputView']['focus']();}get['revisionName'](){return this['revisionNameInputView']['fieldView']['element']['value']['trim']();}set['revisionName'](_0x25b97e){this['revisionNameInputView']['fieldView']['element']['value']=_0x25b97e['trim']();}['reset'](){this['revisionNameInputView']['fieldView']['element']['value']='',this['revisionNameInputView']['errorText']=null;}['_createRevisionNameInput'](_0x1ed1b2){const _0x395e3f=new _0x256e64(this['locale'],_0xb8ce7b),_0x5bc6a1=_0x395e3f['fieldView'];_0x5bc6a1['extendTemplate']({'attributes':{'maxlength':'220'}});let _0x542acd=g(this['locale'],'Name\x20of\x20the\x20revision');return!_0x1ed1b2&&(_0x542acd+='\x20('+g(this['locale'],'optional')+')'),(_0x395e3f['label']=_0x542acd,_0x5bc6a1['on']('input',()=>{this['revisionNameInputValue']=_0x5bc6a1['element']['value']['trim']();}),_0x395e3f);}}class f extends _0x149b28{static get['pluginName'](){return'RevisionHistoryUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[u];}['_saveRevisionFormView'];['init'](){const _0x4cc819=this['editor'],_0x59c2e7=_0x4cc819['plugins']['get']('RevisionTracker');_0x4cc819['ui']['componentFactory']['add']('revisionHistory',_0x288aad=>{const _0x578182=_0x3c0c02(_0x288aad),_0x585acf=_0x578182['panelView']['children'],_0x35d9e6=new _0x5b1655(_0x288aad),_0x2f0cf7=new _0x3f34f5(_0x288aad),_0x479034=new te(_0x288aad),_0x15cafd=new _0x3f34f5(_0x288aad),_0x5a84cc=new te(_0x288aad);return _0x578182['bind']('isEnabled')['to'](_0x59c2e7,'isReady',_0x59c2e7,'isEnabled',_0x4cc819,'isReadOnly',(_0x3cda6d,_0x2fbe9b,_0xe3657e)=>_0x3cda6d&&_0x2fbe9b&&!_0xe3657e),_0x578182['buttonView']['set']({'icon':_0x2f11fa,'label':g(_0x288aad,'Revision\x20history'),'tooltip':!0x0}),_0x479034['set']({'label':g(_0x288aad,'Save\x20current\x20revision'),'withText':!0x0,'role':'menuitem'}),_0x479034['bind']('isEnabled')['to'](_0x59c2e7,'isReady',_0x59c2e7,'isEnabled',_0x4cc819,'isReadOnly',(_0x46f285,_0x246e5c,_0x4290d6)=>_0x46f285&&_0x246e5c&&!_0x4290d6),_0x479034['on']('execute',()=>this['_showDialog']()),_0x5a84cc['set']({'label':g(_0x288aad,'Open\x20revision\x20history'),'withText':!0x0,'role':'menuitem'}),_0x5a84cc['bind']('isEnabled')['to'](_0x59c2e7,'isReady',_0x4cc819,'isReadOnly',(_0xb2c515,_0x5c650f)=>_0xb2c515&&!_0x5c650f),_0x5a84cc['on']('execute',()=>{_0x4cc819['config']['get']('revisionHistory')['showRevisionViewerCallback'](),_0x578182['isOpen']=!0x1,_0x4cc819['editing']['view']['focus']();}),_0x2f0cf7['children']['add'](_0x479034),_0x15cafd['children']['add'](_0x5a84cc),_0x35d9e6['role']='menu',_0x35d9e6['items']['addMany']([_0x2f0cf7,_0x15cafd]),_0x585acf['add'](_0x35d9e6),_0x578182;}),_0x4cc819['ui']['componentFactory']['add']('menuBar:revisionHistory',()=>this['_registerMenuComponent']());}['_registerMenuComponent'](){const _0x1cace1=this['editor'],_0x304b90=_0x1cace1['locale'],_0xfd533a=new _0x505352(_0x304b90),_0x59b376=new _0x222b9c(_0x304b90);_0xfd533a['buttonView']['set']({'icon':_0x2f11fa,'label':g(_0x304b90,'Revision\x20history')});const _0x7525ec=new _0x1d2298(_0x304b90,_0xfd533a),_0x1c3c2f=new _0x11e198(_0x304b90);_0x1c3c2f['set']({'label':g(_0x304b90,'Save\x20current\x20revision')}),_0x1c3c2f['delegate']('execute')['to'](_0xfd533a),_0x1c3c2f['on']('execute',()=>{this['_showDialog']();}),_0x7525ec['children']['add'](_0x1c3c2f),_0x59b376['items']['add'](_0x7525ec);const _0x1ec4dc=new _0x1d2298(_0x304b90,_0xfd533a),_0x5ebb38=new _0x11e198(_0x304b90);return _0x5ebb38['set']({'label':g(_0x304b90,'Open\x20revision\x20history')}),_0x5ebb38['delegate']('execute')['to'](_0xfd533a),_0x5ebb38['on']('execute',()=>{_0x1cace1['config']['get']('revisionHistory')['showRevisionViewerCallback']();}),_0x1ec4dc['children']['add'](_0x5ebb38),_0x59b376['items']['add'](_0x1ec4dc),_0xfd533a['panelView']['children']['add'](_0x59b376),_0xfd533a;}['_showDialog'](){const _0x18e2ac=this['editor'],_0x1eef08=_0x18e2ac['locale'],_0x47b89a=_0x18e2ac['plugins']['get']('Dialog'),_0x5848ce=_0x18e2ac['plugins']['get']('RevisionTracker');function _0x3b98b2(_0x3c7613){_0x18e2ac['config']['get']('revisionHistory.requireRevisionName')&&''===_0x3c7613['revisionName']?_0x3c7613['revisionNameInputView']['errorText']=g(_0x1eef08,'The\x20revision\x20name\x20cannot\x20be\x20empty.'):(_0x18e2ac['plugins']['get'](u)['saveRevision']({'name':_0x3c7613['revisionName']}),_0x47b89a['hide']());}this['_saveRevisionFormView']||(this['_createSaveRevisionFormView'](),this['_saveRevisionFormView']['on']('submit',()=>_0x3b98b2(this['_saveRevisionFormView']))),this['_saveRevisionFormView']['reset'](),_0x47b89a['show']({'id':'revisionSave','title':g(_0x1eef08,'Save\x20current\x20revision'),'isModal':!0x0,'content':this['_saveRevisionFormView'],'actionButtons':[{'label':g(_0x18e2ac['locale'],'Cancel'),'withText':!0x0,'onExecute':()=>_0x47b89a['hide']()},{'label':g(_0x18e2ac['locale'],'Accept'),'class':'ck-button-action','withText':!0x0,'onCreate'(_0x5de72e){_0x5de72e['bind']('isEnabled')['to'](_0x5848ce,'isReady',_0x5848ce,'isEnabled',_0x18e2ac,'isReadOnly',(_0x8f302a,_0x54520c,_0x466030)=>_0x8f302a&&_0x54520c&&!_0x466030);},'onExecute':()=>_0x3b98b2(this['_saveRevisionFormView'])}]});}['_createSaveRevisionFormView'](){const _0x553dd7=this['editor'],_0x160e8d=_0x553dd7['locale'];this['_saveRevisionFormView']=new hs(_0x160e8d,_0x553dd7['config']['get']('revisionHistory.requireRevisionName')),this['_saveRevisionFormView']['render']();}}class Q extends ts{['changeId'];['_model'];constructor(_0x541ee7,_0x356984){super(_0x541ee7),this['_model']=_0x356984,this['changeId']=_0x356984['id'];const _0x33f012=this['bindTemplate'],_0x407b91=g(_0x541ee7,_0x356984['data']['isSuggestion']?'Suggested\x20by':'add'==_0x356984['type']?'Added\x20by':'Removed\x20by');this['set']('type',_0x356984['type']),this['setTemplate']({'tag':'div','attributes':{'class':['ck-annotation','ck-revision-change',_0x33f012['to']('type',_0x379064=>'ck-revision-change__'+_0x379064)],'tabindex':-0x1},'children':[{'tag':'span','children':[{'tag':'span','attributes':{'class':['ck-revision-change__label']},'children':[{'text':_0x407b91}]},{'text':'\x20'+_0x356984['author']['name']}]}]});}['focus'](){this['element']['focus']();}}class r extends/* #__PURE__ -- @preserve */
25
- _0x14857d(){['id'];['author'];['type'];['data'];['rootName'];constructor(_0x1ee65e){super(),this['id']=_0x1ee65e['id']||_0x451426(),this['author']=_0x1ee65e['author'],this['type']=_0x1ee65e['type'],this['data']=_0x1ee65e['data']||{},this['rootName']=_0x1ee65e['rootName'],this['set']('createdAt',_0x1ee65e['createdAt']);}['toJSON'](){return{'id':this['id'],'authorId':this['author']['id'],'type':this['type'],'data':this['data'],'createdAt':this['createdAt']};}}class c{['newRevisionId'];['oldRevisionId'];['changes'];constructor(_0xf27823,_0x280bdf){this['newRevisionId']=_0xf27823,this['oldRevisionId']=_0x280bdf,this['changes']=new _0x3fcc51();}['_setChanges'](_0x4cd166){for(const _0x528328 of _0x4cd166)this['changes']['add'](_0x528328);}}class m extends _0x149b28{['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[_0x43b4df,_0x1663f0,I,V];}constructor(_0xda1191){super(_0xda1191),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',(_0x181734,_0x143b0d,_0x3259dd)=>{this['activeChange']=null,this['activeView']=null,this['editor']['editing']['view']['change'](_0x9fc213=>{for(const _0x529733 of this['editor']['editing']['view']['document']['roots'])_0x3259dd?_0x9fc213['removeClass']('ck-editor__editable__overlay',_0x529733):_0x9fc213['addClass']('ck-editor__editable__overlay',_0x529733);});}),this['bind']('isNavigationMode')['to'](this,'activeChange',_0x320d63=>null!==_0x320d63),this['bind']('currentChangeNumber')['to'](this,'isReady',this,'diff',this,'activeChange',(_0x466cf7,_0x544a0c,_0x64a5b6)=>_0x466cf7&&_0x64a5b6?_0x544a0c['changes']['getIndex'](_0x64a5b6):0x0),this['bind']('numberOfChanges')['to'](this,'isReady',this,'diff',(_0x11863c,_0x572c8b)=>_0x11863c?_0x572c8b['changes']['length']:0x0),this['_changeView']=null,this['_changeIdToChange']=new Map(),this['_balloon']=this['editor']['plugins']['get'](_0x1663f0);}['init'](){const _0x1f4ed3=this['editor'],_0x5587fe=new wt(_0x1f4ed3,{'direction':'backward'}),_0x586276=new wt(_0x1f4ed3,{'direction':'forward'});(_0x1f4ed3['commands']['add']('showPreviousChange',_0x5587fe),_0x1f4ed3['commands']['add']('showNextChange',_0x586276),_0x1f4ed3['commands']['add']('restoreRevision',new mt(_0x1f4ed3)),this['on']('change:numberOfChanges',()=>{_0x5587fe['refresh'](),_0x586276['refresh']();}),this['_setConversion'](),this['_initInteractions'](),_0x1f4ed3['enableReadOnlyMode']('revision-viewer'),_0x1f4ed3['plugins']['has']('WidgetToolbarRepository'))&&_0x1f4ed3['plugins']['get']('WidgetToolbarRepository')['forceDisabled']('revision-viewer');}async['getRevisionDocumentData'](_0x34345d){return await this['_utils']['loadRevisionData'](_0x34345d,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x34345d);}async['getRevisionRootsAttributes'](_0x68be0a){return await this['_utils']['loadRevisionData'](_0x68be0a,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x68be0a);}async['compare'](_0x412686,_0x247e60,_0x2cd7c6=!0x1){if(!this['isEnabled'])return;const _0x313833=this['diff'],_0xb72f1=this['repository'],_0x5f1182='string'==typeof _0x412686?_0xb72f1['getRevision'](_0x412686):_0x412686,_0x4012d5='string'==typeof _0x247e60?_0xb72f1['getRevision'](_0x247e60):_0x247e60,_0x10ad4a=_0x5f1182['id'],_0x35386d=_0x4012d5?_0x4012d5['id']:null;if(!_0x2cd7c6&&this['diff']&&this['diff']['newRevisionId']===_0x10ad4a&&this['diff']['oldRevisionId']===_0x35386d)return Promise['resolve']();this['isReady']=!0x1,this['activeView']=null,this['activeChange']=null,this['diff']=new c(_0x10ad4a,_0x35386d);const _0x442776=this['_getRevisionsRange'](_0x5f1182,_0x4012d5,!0x0)['map'](_0x2af5bb=>this['_utils']['loadRevisionData'](_0x2af5bb,this['adapter']));return _0x442776['push'](new Promise(_0x51d4b1=>{setTimeout(_0x51d4b1,0x14);})),Promise['all'](_0x442776)['then'](()=>{if(!this['isEnabled'])return;this['_cleanUp']();const _0x316303=this['_getDiff'](_0x10ad4a,_0x35386d);for(const _0x17444c of _0x316303['changes'])this['_changeIdToChange']['set'](_0x17444c['id'],_0x17444c);this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x323efd=>{for(const _0x2f24f1 of this['editor']['model']['document']['getRootNames']())_0x323efd['detachRoot'](_0x2f24f1);for(const _0x32ec56 of Object['keys'](_0x316303['model'])){const _0x5bde61=_0x323efd['addRoot'](_0x32ec56);for(const _0x40423e of Object['keys'](_0x316303['attributes'][_0x32ec56]))_0x323efd['setAttribute'](_0x40423e,_0x316303['attributes'][_0x32ec56][_0x40423e],_0x5bde61);_0x323efd['insert'](_0x316303['model'][_0x32ec56],_0x5bde61,0x0);}}),this['diff']['_setChanges'](this['_sortAndFilterDiffChanges'](_0x316303['changes'])),this['isReady']=!0x0;})['catch'](_0x22aa41=>{console['error'](_0x22aa41),this['_cleanUp'](),_0x313833&&(this['diff']=_0x313833),this['isReady']=!0x0;});}['addRevisionData'](_0x173394,_0x1e4e7f){const _0xde2de4=this['repository']['createRevision'](_0x173394);return _0xde2de4['on']('_update',(_0x599007,_0x27f085,_0x411686)=>_0x1e4e7f(_0x27f085,_0x411686,_0xde2de4)),this['repository']['addRevision'](_0xde2de4),_0xde2de4;}['_cleanUp'](){this['activeChange']=null,this['_cleanMarkers'](),this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=null,this['_changeIdToChange']['clear'](),this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x551c54=>{for(const _0x50e483 of this['editor']['model']['document']['getRootNames']())_0x551c54['detachRoot'](_0x50e483);});}['_sortAndFilterDiffChanges'](_0x283421){const _0x4bfe46=[],_0x46239b=new Map();for(const _0x34e831 of this['editor']['model']['document']['getRootNames']()){const _0x2c3b07=this['editor']['editing']['view']['getDomRoot'](_0x34e831);if(!_0x2c3b07)continue;const _0x528a56=_0x2c3b07['getClientRects']()['item'](0x0);_0x528a56&&(_0x4bfe46['push'](_0x34e831),_0x46239b['set'](_0x34e831,_0x528a56));}return _0x4bfe46['sort']((_0x1bd447,_0x1a194e)=>{const _0x211d4d=_0x46239b['get'](_0x1bd447),_0x19e167=_0x46239b['get'](_0x1a194e);return _0x211d4d['y']-_0x19e167['y']||_0x211d4d['x']-_0x19e167['x'];}),(_0x283421=_0x283421['filter'](_0x296dd2=>_0x4bfe46['includes'](_0x296dd2['rootName'])))['sort']((_0xbe5028,_0x315da0)=>_0x4bfe46['indexOf'](_0xbe5028['rootName'])-_0x4bfe46['indexOf'](_0x315da0['rootName'])),_0x283421;}['_makeTape'](_0xb0e5dd){const _0xcb5390=Array['from'](_0xb0e5dd['markers'])['filter'](([_0x1a0de9,_0x5cfb0c])=>_0x1a0de9['startsWith']('revision:')&&!_0x5cfb0c['isCollapsed']),_0x594700=Array['from'](this['editor']['model']['createRangeIn'](_0xb0e5dd)['getWalker']({'singleCharacters':!0x0}));if(0x0!=_0xcb5390['length'])for(const _0x44b8fa of _0x594700){const [_0x144796,_0xfcbaf9]=_0xcb5390[0x0],[,_0xc0a35d,_0x2a7ca1]=_0x144796['split'](':');if(_0xfcbaf9['end']['isEqual'](_0x44b8fa['nextPosition'])&&_0xcb5390['shift'](),(_0x44b8fa['previousPosition']['isEqual'](_0xfcbaf9['start'])||_0x44b8fa['previousPosition']['isAfter'](_0xfcbaf9['start']))&&('insertion'==_0xc0a35d?_0x44b8fa['isAdded']={'userId':_0x2a7ca1}:'deletion'==_0xc0a35d&&(_0x44b8fa['isRemoved']={'userId':_0x2a7ca1})),0x0==_0xcb5390['length'])break;}return _0x594700;}['_refreshStartEndIndex'](_0x580a1e){const _0x55838e=new Map();for(let _0x5dccd1=0x0;_0x5dccd1<_0x580a1e['length'];_0x5dccd1++)'text'===_0x580a1e[_0x5dccd1]['type']?(_0x580a1e[_0x5dccd1]['item']['startIndex']=_0x5dccd1,_0x580a1e[_0x5dccd1]['item']['endIndex']=_0x5dccd1):('elementStart'===_0x580a1e[_0x5dccd1]['type']?_0x580a1e[_0x5dccd1]['item']['startIndex']=_0x5dccd1:'elementEnd'===_0x580a1e[_0x5dccd1]['type']&&(_0x580a1e[_0x5dccd1]['item']['endIndex']=_0x5dccd1),_0x55838e['set'](_0x580a1e[_0x5dccd1]['id'],_0x5dccd1));for(const _0x4eeade of _0x55838e['values']())'elementStart'===_0x580a1e[_0x4eeade]['type']?_0x580a1e[_0x4eeade]['item']['endIndex']=_0x55838e['get'](_0x580a1e[_0x4eeade]['pairId']):'elementEnd'===_0x580a1e[_0x4eeade]['type']&&(_0x580a1e[_0x4eeade]['item']['startIndex']=_0x55838e['get'](_0x580a1e[_0x4eeade]['pairId']));}['_processTape'](_0x19a606){for(let _0x1b7905=0x0;_0x1b7905<_0x19a606['length'];_0x1b7905++){if('elementStart'===_0x19a606[_0x1b7905]['type'])_0x19a606[_0x1b7905]['item']['startIndex']=_0x1b7905;else{if('elementEnd'===_0x19a606[_0x1b7905]['type']){_0x19a606[_0x1b7905]['item']['endIndex']=_0x1b7905;const _0x37ba9f=_0x19a606[_0x1b7905]['item']['startIndex'];_0x19a606[_0x37ba9f]['pairId']=_0x19a606[_0x1b7905]['id'],_0x19a606[_0x1b7905]['pairId']=_0x19a606[_0x37ba9f]['id'];}else _0x19a606[_0x1b7905]['item']['startIndex']=_0x1b7905,_0x19a606[_0x1b7905]['item']['endIndex']=_0x1b7905,_0x19a606[_0x1b7905]['pairId']=null;}_0x19a606[_0x1b7905]['markersStart']||(_0x19a606[_0x1b7905]['markersStart']=[],_0x19a606[_0x1b7905]['markersEnd']=[]);}}['_markInsertions'](_0xeb1826,_0x202223){const _0x503ba1=_0xeb1826['filter'](_0x27a267=>!_0x27a267['isAdded']);for(let _0x5b2cf0=0x0;_0x5b2cf0<_0x202223['length'];_0x5b2cf0++)_0x202223[_0x5b2cf0]['isAdded']&&(_0x503ba1[_0x5b2cf0]['isAdded']=_0x202223[_0x5b2cf0]['isAdded']);}['_getDiff'](_0x37abd1,_0x1c2b2c=null){const _0x4fa35b=this['repository']['getRevision'](_0x37abd1),_0x408dd0=_0x1c2b2c?this['repository']['getRevision'](_0x1c2b2c):null,_0x34baec=this['_getRevisionsRange'](_0x4fa35b,_0x408dd0),_0x5a91dc=_0x34baec[_0x34baec['length']-0x1],_0x548368=new Map(),_0x4be1f2={'model':{},'attributes':{},'changes':[]},_0x142885=new Set(),_0x380cbc=new Map();for(let _0x166c45=_0x34baec['length']-0x1;_0x166c45>=0x0;_0x166c45--){const _0x480e0b=_0x34baec[_0x166c45];for(const _0x4a8d5b of Object['keys'](_0x480e0b['diffData']))if(_0x480e0b['diffData'][_0x4a8d5b]['attachChange']){const _0x5f5d5=_0x480e0b['diffData'][_0x4a8d5b]['attachChange'];_0x5f5d5['isAttached']?(_0x142885['add'](_0x4a8d5b),_0x380cbc['has'](_0x4a8d5b)&&_0x380cbc['get'](_0x4a8d5b)['userId']==_0x5f5d5['userId']?_0x380cbc['delete'](_0x4a8d5b):_0x380cbc['set'](_0x4a8d5b,_0x5f5d5)):_0x380cbc['has'](_0x4a8d5b)?(_0x142885['delete'](_0x4a8d5b),_0x380cbc['delete'](_0x4a8d5b)):(_0x142885['add'](_0x4a8d5b),_0x380cbc['set'](_0x4a8d5b,_0x5f5d5));}else _0x142885['add'](_0x4a8d5b);}for(const _0x5b6023 of _0x142885){const _0x5cbf59=_0x380cbc['has'](_0x5b6023)&&!_0x380cbc['get'](_0x5b6023)['isAttached'];let _0x153e25=_0x5cbf59?_0x34baec['length']-0x1:0x0;const _0x522b2c=_0x5cbf59?-0x1:0x1;for(;_0x34baec[_0x153e25];){const _0x1194b7=_0x34baec[_0x153e25];if(_0x1194b7['diffData'][_0x5b6023]){const _0x4d036e=_0x5cbf59?_0x1194b7['diffData'][_0x5b6023]['attributesBefore']:_0x1194b7['diffData'][_0x5b6023]['attributesAfter'];_0x4be1f2['attributes'][_0x5b6023]=_0x4d036e?_0x36f289(_0x4d036e):{};break;}_0x153e25+=_0x522b2c;}}for(const _0x3f0912 of _0x34baec){_0x3f0912['model']={};for(const _0xe547b4 of _0x3f0912['authors'])_0x548368['set'](_0xe547b4['id'],_0xe547b4);for(const _0x1bd8c1 of _0x142885){const _0x2dcc24=_0x3f0912['diffData'][_0x1bd8c1]?_0x3f0912['diffData'][_0x1bd8c1]['insertions']:'[]',_0x15aff5=_0x3f0912['diffData'][_0x1bd8c1]?_0x3f0912['diffData'][_0x1bd8c1]['deletions']:'[]';_0x3f0912['model'][_0x1bd8c1]={'insertions':this['_utils']['_makeModelFromViewString'](_0x2dcc24),'deletions':this['_utils']['_makeModelFromViewString'](_0x15aff5)};}}for(const _0x393141 of _0x142885){let _0x2146b6=null,_0x52d2f6=0x0;const _0x2b15c4=new Map(Array['from'](_0x4fa35b['model'][_0x393141]['insertions']['markers'])['filter'](([_0x51d9c2])=>!_0x51d9c2['startsWith']('revision:')));let _0x905f91=0x0;for(const _0x59ce36 of _0x34baec){const _0x47eb6a=this['_makeTape'](_0x59ce36['model'][_0x393141]['insertions']);_0x59ce36==_0x4fa35b?(_0x2146b6=_0x47eb6a,_0x52d2f6=_0x2146b6['length'],_0x2146b6['forEach'](_0x3cc919=>{_0x3cc919['id']=_0x905f91++;}),this['_processTape'](_0x2146b6)):this['_markInsertions'](_0x2146b6,_0x47eb6a);const _0x2e1fac=_0x2146b6['filter'](_0x4abb61=>!_0x4abb61['isAdded'])['map'](_0x43d134=>_0x43d134['id']);let _0x3d55f2=0x0;const _0x179132=this['_makeTape'](_0x59ce36['model'][_0x393141]['deletions']);_0x179132['forEach'](_0x4656f7=>{_0x4656f7['isRemoved']?_0x4656f7['id']=_0x52d2f6++:_0x4656f7['id']=_0x2e1fac[_0x3d55f2++];}),this['_processTape'](_0x179132),this['_setDistance'](_0x2146b6,'isAdded'),this['_setDistance'](_0x179132,'isRemoved'),_0x59ce36==_0x4fa35b&&this['_markMarkers'](_0x2146b6,_0x2b15c4),_0x2146b6=this['_joinTapes'](_0x2146b6,_0x179132),this['_refreshStartEndIndex'](_0x2146b6),this['_setDistance'](_0x2146b6,'isRemoved');}_0x2146b6=_0x2146b6['filter'](_0x4abb8=>!(_0x4abb8['isAdded']&&_0x4abb8['isRemoved']));const _0x14a66b=new Map(_0x5a91dc['model'][_0x393141]['deletions']['markers']),_0x128050=new Set(_0x2b15c4['keys']());for(const _0x46ada8 of _0x14a66b['keys']())_0x128050['delete'](_0x46ada8);this['_markSuggestions'](_0x2146b6,_0x128050),this['_fixObsoleteTags'](_0x2146b6),_0x2146b6=this['_removeMissingPairs'](_0x2146b6),_0x2146b6=this['_markMismatchedRemovedTags'](_0x2146b6),_0x2146b6=this['_removeUnsupportedChanges'](_0x2146b6);const {root:_0x421b05,changes:_0x50dfb7}=this['_makeModelFromTape'](_0x2146b6,_0x548368,_0x393141);_0x4be1f2['model'][_0x393141]=_0x421b05;const _0x5b85a1=_0x380cbc['get'](_0x393141);if(_0x5b85a1){const _0x2e933c=_0x548368['get'](_0x5b85a1['userId']),_0x184188=new r({'author':_0x2e933c,'type':_0x5b85a1['isAttached']?'add':'remove','data':{'isOnRoot':!0x0},'createdAt':new Date(),'rootName':_0x393141});_0x50dfb7['unshift'](_0x184188),_0x4be1f2['attributes'][_0x393141]['revisionHistoryAttachChange']=_0x184188['id'];}_0x4be1f2['changes']=_0x4be1f2['changes']['concat'](_0x50dfb7);}return _0x4be1f2;}['_markMarkers'](_0x4e3434,_0x5b5a46){for(let _0x559a19=0x0;_0x559a19<_0x4e3434['length'];_0x559a19++)for(const [_0x15ecee,_0x51b527]of _0x5b5a46)!_0x51b527['isCollapsed']&&_0x51b527['start']['isEqual'](_0x4e3434[_0x559a19]['previousPosition'])&&_0x4e3434[_0x559a19]['markersStart']['push'](_0x15ecee),_0x51b527['end']['isEqual'](_0x4e3434[_0x559a19]['nextPosition'])&&_0x4e3434[_0x559a19]['markersEnd']['push'](_0x15ecee);}['_joinTapes'](_0x9e13fc,_0x4ec9c3){let _0x917218=[],_0x7dc234=0x0,_0x260d5a=0x0;for(;_0x7dc234<_0x9e13fc['length']||_0x260d5a<_0x4ec9c3['length'];){const _0x29111f=_0x9e13fc[_0x7dc234]||{},_0x363cdb=_0x4ec9c3[_0x260d5a]||{};if(_0x29111f['id']==_0x363cdb['id'])_0x7dc234++,_0x260d5a++,_0x917218['push'](_0x29111f);else{if(_0x363cdb['isRemoved']&&_0x29111f['isAdded']){const {commonTape:_0x102e73,iEnd:_0x519295,jEnd:_0x228435}=this['_threeWayMerge'](_0x9e13fc,_0x7dc234,_0x4ec9c3,_0x260d5a);_0x917218=_0x917218['concat'](_0x102e73),_0x7dc234=_0x519295,_0x260d5a=_0x228435;}else _0x363cdb['isRemoved']?(_0x260d5a++,_0x917218['push'](_0x363cdb)):(_0x7dc234++,_0x917218['push'](_0x29111f));}}return _0x917218;}['_markSuggestions'](_0x1b8a6e,_0x2609fb){const _0xcc0343=[];for(let _0x3f1231=0x0;_0x3f1231<_0x1b8a6e['length'];_0x3f1231++){for(let _0x39d393=0x0;_0x39d393<_0x1b8a6e[_0x3f1231]['markersStart']['length'];_0x39d393++){const _0x47ead5=_0x1b8a6e[_0x3f1231]['markersStart'][_0x39d393];if(!_0x2609fb['has'](_0x47ead5))continue;const {group:_0xff4bc5,type:_0x284563,authorId:_0x3a3c60}=_0x549143(_0x47ead5);'revision-suggestion'!=_0xff4bc5||'insertion'!=_0x284563&&'deletion'!=_0x284563||(_0xcc0343['unshift']({'type':_0x284563,'name':_0x47ead5,'userId':_0x3a3c60}),_0x1b8a6e[_0x3f1231]['markersStart']['splice'](_0x39d393,0x1),_0x39d393--);}_0xad8822(_0x1b8a6e[_0x3f1231]);for(let _0x3e14a1=0x0;_0x3e14a1<_0x1b8a6e[_0x3f1231]['markersEnd']['length'];_0x3e14a1++){const _0x408d85=_0x1b8a6e[_0x3f1231]['markersEnd'][_0x3e14a1];if(!_0x2609fb['has'](_0x408d85))continue;const {group:_0x4f37f7,type:_0x5bdea0}=_0x549143(_0x408d85);if('revision-suggestion'!=_0x4f37f7||'insertion'!=_0x5bdea0&&'deletion'!=_0x5bdea0)continue;_0x1b8a6e[_0x3f1231]['markersEnd']['splice'](_0x3e14a1,0x1),_0x3e14a1--;const _0x4e73a9=_0xcc0343['findIndex'](_0x525933=>_0x525933['name']==_0x408d85);_0x4e73a9>-0x1&&_0xcc0343['splice'](_0x4e73a9,0x1);}}function _0x549143(_0x558c2e){const _0x1d85b3=_0x558c2e['split'](':');return{'group':_0x1d85b3[0x0],'type':_0x1d85b3[0x1],'subType':_0x1d85b3['length']>=0x5?_0x1d85b3[0x2]:null,'id':_0x1d85b3['length']<0x5?_0x1d85b3[0x2]:_0x1d85b3[0x3],'authorId':_0x1d85b3['length']<0x5?_0x1d85b3[0x3]:_0x1d85b3[0x4],'markerCount':0x6==_0x1d85b3['length']?_0x1d85b3[0x5]:null};}function _0xad8822(_0x44a026){for(let _0x547a96=0x0;_0x547a96<_0xcc0343['length'];_0x547a96++){if(_0x44a026['isAdded']&&'insertion'==_0xcc0343[_0x547a96]['type'])return _0x44a026['isAddSuggestion']=_0xcc0343[_0x547a96],void delete _0x44a026['isAdded'];if(!_0x44a026['isAdded']&&!_0x44a026['isRemoved']&&'deletion'==_0xcc0343[_0x547a96]['type'])return void(_0x44a026['isRemoveSuggestion']=_0xcc0343[_0x547a96]);}}}['_setDistance'](_0x1f5eb8,_0x11528b){let _0x46d956=0x0,_0x52f550=!0x1;const _0x20471e=new Map();for(const _0x144c52 of _0x1f5eb8)_0x144c52[_0x11528b]?_0x52f550&&(_0x46d956++,_0x52f550=!0x1):(_0x46d956++,_0x52f550=!0x0),_0x20471e['set'](_0x144c52['id'],_0x46d956);for(let _0x58345f=0x0;_0x58345f<_0x1f5eb8['length'];_0x58345f++){if('isRemoved'==_0x11528b&&_0x1f5eb8[_0x58345f]['isAdded']||'isAdded'==_0x11528b&&_0x1f5eb8[_0x58345f]['isRemoved'])continue;if('text'==_0x1f5eb8[_0x58345f]['type']){_0x1f5eb8[_0x58345f]['distance']=0x0;continue;}const _0xb5aa3=_0x20471e['get'](_0x1f5eb8[_0x58345f]['pairId']),_0x23eade=_0x20471e['get'](_0x1f5eb8[_0x58345f]['id']);_0x1f5eb8[_0x58345f]['distance']=_0xb5aa3-_0x23eade;}}['_getRevisionsRange'](_0x650b66,_0x4464bc,_0x9dbec9=!0x1){const _0x2812d6=[];let _0x1df885=this['repository']['getIndex'](_0x650b66),_0x309f5c=this['repository']['getIndex'](_0x4464bc);for(-0x1==_0x309f5c&&(_0x309f5c=this['repository']['_revisions']['length'],_0x9dbec9=!0x1);_0x1df885<_0x309f5c;)_0x2812d6['push'](this['repository']['getRevision'](_0x1df885)),_0x1df885++;return _0x9dbec9&&_0x2812d6['push'](this['repository']['getRevision'](_0x1df885)),_0x2812d6;}['_threeWayMerge'](_0x36de31,_0x23e84a,_0x456594,_0x5503eb){const _0x3302b7=this['editor']['model']['schema'];let _0x1e91c5=_0x23e84a;for(;_0x36de31[_0x1e91c5]&&_0x36de31[_0x1e91c5]['isAdded'];)_0x1e91c5++;let _0x548337=_0x5503eb;for(;_0x456594[_0x548337]&&_0x456594[_0x548337]['isRemoved'];)_0x548337++;_0x195629(_0x36de31,_0x23e84a,_0x1e91c5),_0x195629(_0x456594,_0x5503eb,_0x548337);const _0x23ef1d=_0x456594['slice'](_0x5503eb,_0x548337)['concat'](_0x36de31['slice'](_0x23e84a,_0x1e91c5));return _0x23ef1d['sort']((_0x71a524,_0x122faf)=>_0x71a524['side']!=_0x122faf['side']?_0x71a524['side']-_0x122faf['side']:_0x71a524['level']!=_0x122faf['level']?_0x71a524['level']-_0x122faf['level']:_0x71a524['distance']!=_0x122faf['distance']?_0x122faf['distance']-_0x71a524['distance']:!!_0x71a524['isAdded']!=!!_0x122faf['isAdded']?-0x1==_0x71a524['side']||0x0==_0x71a524['side']?_0x71a524['isAdded']?-0x1:0x1:_0x71a524['isAdded']?0x1:-0x1:_0x71a524['index']-_0x122faf['index']),{'commonTape':_0x23ef1d,'iEnd':_0x1e91c5,'jEnd':_0x548337};function _0x195629(_0x32b679,_0x517049,_0x22f594){let _0x4486d2=-0x1,_0x484f38=Number['POSITIVE_INFINITY'],_0x41e682=!0x0;for(let _0x4ae4bb=_0x517049;_0x4ae4bb<_0x22f594;_0x4ae4bb++)if(_0x3302b7['isInline'](_0x32b679[_0x4ae4bb]['item'])||(_0x41e682=!0x1),_0x32b679[_0x4ae4bb]['item']['startIndex']<_0x517049&&(_0x4486d2=_0x4ae4bb),_0x32b679[_0x4ae4bb]['item']['endIndex']>=_0x22f594){_0x484f38=_0x4ae4bb;break;}_0x41e682&&(_0x4486d2=_0x22f594-0x1);for(let _0x2b219a=_0x517049;_0x2b219a<_0x22f594;_0x2b219a++)_0x32b679[_0x2b219a]['side']=_0x2b219a<=_0x4486d2?-0x1:_0x2b219a<_0x484f38?0x0:0x1,_0x32b679[_0x2b219a]['index']=_0x2b219a;let _0x2221ff=0x0;for(let _0x13eabd=_0x517049;_0x13eabd<=_0x4486d2;_0x13eabd++)0x0==_0x32b679[_0x13eabd]['distance']?_0x32b679[_0x13eabd]['level']=_0x2221ff:(_0x2221ff++,_0x32b679[_0x13eabd]['level']=_0x2221ff,_0x2221ff++);for(let _0x3ffff4=_0x517049;_0x3ffff4<_0x22f594;_0x3ffff4++)0x0==_0x32b679[_0x3ffff4]['side']&&(_0x32b679[_0x3ffff4]['level']=_0x2221ff);_0x2221ff=0x0;for(let _0x5924b1=_0x22f594-0x1;_0x5924b1>=_0x484f38;_0x5924b1--)0x0==_0x32b679[_0x5924b1]['distance']?_0x32b679[_0x5924b1]['level']=_0x2221ff:(_0x2221ff--,_0x32b679[_0x5924b1]['level']=_0x2221ff,_0x2221ff--);}}['_fixObsoleteTags'](_0x4a7102){const _0x3fe779=new Map(),_0x2c3eb5=this['editor']['model']['schema'];for(let _0x2fefa4=0x1;_0x2fefa4<_0x4a7102['length'];_0x2fefa4++){let _0x70e90e,_0x374920,_0x1e0403;const _0x1bfbfb=_0x4a7102[_0x2fefa4],_0xb00624=_0x4a7102[_0x2fefa4-0x1];if('text'==_0x1bfbfb['type'])continue;if(_0x1bfbfb['type']!=_0xb00624['type'])continue;if(!_0x2c3eb5['isBlock'](_0xb00624['item'])||_0x2c3eb5['isLimit'](_0xb00624['item']))continue;if(!_0x2c3eb5['isBlock'](_0x1bfbfb['item'])||_0x2c3eb5['isLimit'](_0x1bfbfb['item']))continue;if((_0x4a7102[_0x2fefa4]['isAdded']||_0x4a7102[_0x2fefa4]['isAddSuggestion'])&&_0x4a7102[_0x2fefa4-0x1]['isRemoved'])_0x70e90e=_0x4a7102[_0x2fefa4],_0x374920=_0x4a7102[_0x2fefa4-0x1],_0x1e0403=_0x2fefa4-0x1;else{if(!_0x4a7102[_0x2fefa4]['isRemoved']||!_0x4a7102[_0x2fefa4-0x1]['isAdded']&&!_0x4a7102[_0x2fefa4-0x1]['isAddSuggestion'])continue;_0x70e90e=_0x4a7102[_0x2fefa4-0x1],_0x374920=_0x4a7102[_0x2fefa4],_0x1e0403=_0x2fefa4;}const _0x3677f7=_0x70e90e['level']==_0x374920['level'],_0x546bd6=Math['abs'](_0x70e90e['level'])<Math['abs'](_0x374920['level'])&&0x0==_0x374920['distance'];(_0x3677f7||_0x546bd6)&&(_0x3fe779['set'](_0x374920['id'],_0x70e90e['id']),_0x4a7102['splice'](_0x1e0403,0x1),_0x2fefa4--,_0x70e90e['isAdded']=!0x1);}for(let _0x375e14=0x0;_0x375e14<_0x4a7102['length'];_0x375e14++)_0x3fe779['has'](_0x4a7102[_0x375e14]['pairId'])&&(_0x4a7102[_0x375e14]['pairId']=_0x3fe779['get'](_0x4a7102[_0x375e14]['pairId']));}['_removeMissingPairs'](_0x46eaf8){const _0xa3d99b=new Set(_0x46eaf8['map'](_0x39d884=>_0x39d884['id']));for(let _0x9a8ed6=0x0;_0x9a8ed6<_0x46eaf8['length'];_0x9a8ed6++)_0xa3d99b['has'](_0x46eaf8[_0x9a8ed6]['pairId'])||0x0==_0x46eaf8[_0x9a8ed6]['distance']||(_0x46eaf8[_0x9a8ed6]['isIncorrect']=!0x0);return _0x46eaf8['filter'](_0x632dfc=>!_0x632dfc['isIncorrect']);}['_markMismatchedRemovedTags'](_0x51c2d2){const _0x2f5911=new Set();for(let _0x26d0b7=0x0;_0x26d0b7<_0x51c2d2['length'];_0x26d0b7++){if(_0x2f5911['has'](_0x51c2d2[_0x26d0b7]['id'])&&_0x51c2d2[_0x26d0b7]['isRemoved']&&(_0x51c2d2[_0x26d0b7]['isIncorrect']=!0x0),_0x51c2d2[_0x26d0b7]['isIncorrect'])continue;if(0x0==_0x51c2d2[_0x26d0b7]['distance'])continue;if('elementStart'!=_0x51c2d2[_0x26d0b7]['type'])continue;if(null==_0x51c2d2[_0x26d0b7]['pairId'])continue;let _0x5e2a82=_0x26d0b7+0x1,_0x3c4d53=0x0;for(;_0x51c2d2[_0x5e2a82]['id']!=_0x51c2d2[_0x26d0b7]['pairId'];)'elementStart'==_0x51c2d2[_0x5e2a82]['type']?_0x3c4d53++:'elementEnd'==_0x51c2d2[_0x5e2a82]['type']&&_0x3c4d53--,_0x5e2a82++;if(0x0!=_0x3c4d53){if(_0x51c2d2[_0x26d0b7]['isRemoved'])_0x51c2d2[_0x26d0b7]['isIncorrect']=!0x0;else{for(;_0x5e2a82!=_0x26d0b7;)_0x51c2d2[_0x5e2a82]['isRemoved']&&0x0!=_0x51c2d2[_0x5e2a82]['distance']&&(_0x51c2d2[_0x5e2a82]['isIncorrect']=!0x0,_0x2f5911['add'](_0x51c2d2[_0x5e2a82]['pairId'])),_0x5e2a82--;}}}return _0x51c2d2['filter'](_0x27599e=>!_0x27599e['isIncorrect']);}['_removeUnsupportedChanges'](_0x56ef81){const _0x4ef10d=this['editor']['model']['schema'];for(let _0x492302=0x0;_0x492302<_0x56ef81['length'];_0x492302++){if(!(_0x56ef81[_0x492302]['isAdded']||_0x56ef81[_0x492302]['isAddSuggestion']||_0x56ef81[_0x492302]['isRemoved']||_0x56ef81[_0x492302]['isRemoveSuggestion']))continue;if(0x0==_0x56ef81[_0x492302]['distance'])continue;const _0x5b9c7d=_0x56ef81[_0x492302]['item'];_0x4ef10d['isBlock'](_0x5b9c7d)||_0x4ef10d['isLimit'](_0x5b9c7d)||(_0x56ef81[_0x492302]['isAdded']&&delete _0x56ef81[_0x492302]['isAdded'],_0x56ef81[_0x492302]['isAddSuggestion']&&delete _0x56ef81[_0x492302]['isAddSuggestion'],_0x56ef81[_0x492302]['isRemoveSuggestion']&&delete _0x56ef81[_0x492302]['isRemoveSuggestion'],_0x56ef81[_0x492302]['isRemoved']&&(_0x56ef81[_0x492302]['isIncorrect']=!0x0));}return _0x56ef81['filter'](_0x58b676=>!_0x58b676['isIncorrect']);}['_makeModelFromTape'](_0x538320,_0x1cb4eb,_0x315ef0){const _0x3a4dd8=new vt(),_0x37a1b7=[],_0x8f7e7=new Map(),_0x26a505=this['editor']['model'],_0x4d3951=_0x26a505['schema'],_0x64e6c7=[_0x3a4dd8],_0x1707b8={},_0x36ef85={'isAdded':[],'isRemoved':[],'isAddSuggestion':[],'isRemoveSuggestion':[]};let _0x83f2b8=null;const _0x210d28=[0x0];for(let _0x40f7f9=0x0;_0x40f7f9<_0x538320['length'];_0x40f7f9++)if('elementStart'===_0x538320[_0x40f7f9]['type']){_0x538320[_0x40f7f9]['previousPosition']=_0x26a505['createPositionFromPath'](_0x3a4dd8,_0x210d28);const _0x3523fd=new ut(_0x538320[_0x40f7f9]['item']['name'],_0x538320[_0x40f7f9]['item']['getAttributes']());_0x64e6c7[0x0]['_appendChild'](_0x3523fd),_0x210d28['push'](0x0),_0x64e6c7['unshift'](_0x3523fd),_0x538320[_0x40f7f9]['nextPosition']=_0x26a505['createPositionFromPath'](_0x3a4dd8,_0x210d28);}else'elementEnd'===_0x538320[_0x40f7f9]['type']?(_0x64e6c7['shift'](),_0x538320[_0x40f7f9]['previousPosition']=_0x26a505['createPositionFromPath'](_0x3a4dd8,_0x210d28),_0x210d28['pop'](),_0x210d28[_0x210d28['length']-0x1]++,_0x538320[_0x40f7f9]['nextPosition']=_0x26a505['createPositionFromPath'](_0x3a4dd8,_0x210d28)):(_0x538320[_0x40f7f9]['previousPosition']=_0x26a505['createPositionFromPath'](_0x3a4dd8,_0x210d28),_0x83f2b8?_0x83f2b8['_data']+=_0x538320[_0x40f7f9]['item']['data']:_0x83f2b8=new gt(_0x538320[_0x40f7f9]['item']['data'],_0x538320[_0x40f7f9]['item']['getAttributes']()),_0x538320[_0x40f7f9+0x1]&&'text'===_0x538320[_0x40f7f9+0x1]['type']&&_0x5a1477(_0x83f2b8,_0x538320[_0x40f7f9+0x1]['item'])||(_0x64e6c7[0x0]['_appendChild'](_0x83f2b8),_0x83f2b8=null),_0x210d28[_0x210d28['length']-0x1]+=_0x538320[_0x40f7f9]['item']['offsetSize'],_0x538320[_0x40f7f9]['nextPosition']=_0x26a505['createPositionFromPath'](_0x3a4dd8,_0x210d28));for(let _0x5aa9ee=0x0;_0x5aa9ee<_0x538320['length'];_0x5aa9ee++){const _0x439e1e=_0x538320[_0x5aa9ee]['previousPosition'],_0x240f05=_0x538320[_0x5aa9ee]['nextPosition'];for(const _0x27bcb8 of _0x538320[_0x5aa9ee]['markersStart'])_0x8f7e7['set'](_0x27bcb8,{'start':_0x439e1e,'end':null});_0xbf2be1('isRemoveSuggestion',_0x5aa9ee,_0x439e1e,_0x240f05),_0xbf2be1('isAddSuggestion',_0x5aa9ee,_0x439e1e,_0x240f05),_0xbf2be1('isRemoved',_0x5aa9ee,_0x439e1e,_0x240f05),_0xbf2be1('isAdded',_0x5aa9ee,_0x439e1e,_0x240f05);for(const _0x3888fc of _0x538320[_0x5aa9ee]['markersEnd']){const _0xf2c2da=_0x8f7e7['get'](_0x3888fc);_0xf2c2da?_0xf2c2da['end']=_0x240f05:_0x8f7e7['set'](_0x3888fc,{'start':_0x240f05,'end':_0x240f05});}}for(const [_0x178a30,_0x3f507f]of _0x8f7e7){const _0x55e126=this['editor']['model']['createRange'](_0x3f507f['start'],_0x3f507f['end']);_0x3a4dd8['markers']['set'](_0x178a30,_0x55e126);}return _0x37a1b7['sort']((_0x4d09e8,_0x58c1a2)=>{const _0x43575a=_0x3a4dd8['markers']['get']('revision:'+_0x4d09e8['id']),_0x59023e=_0x3a4dd8['markers']['get']('revision:'+_0x58c1a2['id']);return _0x43575a['start']['isBefore'](_0x59023e['start'])?-0x1:_0x43575a['start']['isAfter'](_0x59023e['start'])?0x1:_0x43575a['end']['isBefore'](_0x59023e['end'])?-0x1:_0x43575a['end']['isAfter'](_0x59023e['end'])?0x1:'add'===_0x4d09e8['type']?-0x1:0x1;}),{'root':_0x3a4dd8,'changes':_0x37a1b7};function _0xbf2be1(_0x2245a1,_0x197de9,_0x5c4ed0,_0x702007){const _0x4745a8=!!_0x538320[_0x197de9][_0x2245a1],_0x52e1bc=_0x4745a8?_0x538320[_0x197de9][_0x2245a1]['userId']:null,_0x5a7a28=_0x197de9===_0x538320['length']-0x1,_0x5e517e=_0x36ef85[_0x2245a1][0x0],_0x35c574=_0x4d3951['isObject'](_0x538320[_0x197de9]['item']);!_0x1707b8[_0x2245a1]&&_0x4745a8?_0x1707b8[_0x2245a1]={'start':_0x5c4ed0,'tapeItem':_0x538320[_0x197de9],'userId':_0x52e1bc,'type':_0x2245a1}:_0x1707b8[_0x2245a1]&&!_0x4745a8?(_0x1707b8[_0x2245a1]['end']=_0x5c4ed0,_0x2d1954(_0x1707b8[_0x2245a1]),_0x1707b8[_0x2245a1]=null):_0x1707b8[_0x2245a1]&&_0x4745a8&&_0x1707b8[_0x2245a1]['userId']!==_0x52e1bc&&(_0x1707b8[_0x2245a1]['end']=_0x5c4ed0,_0x5e517e&&_0x5e517e['userId']===_0x1707b8[_0x2245a1]['userId']||_0x2d1954(_0x1707b8[_0x2245a1]),_0x1707b8[_0x2245a1]={'start':_0x5c4ed0,'tapeItem':_0x538320[_0x197de9],'userId':_0x52e1bc,'type':_0x2245a1}),_0x1707b8[_0x2245a1]&&_0x35c574&&('elementStart'!==_0x538320[_0x197de9]['type']||_0x5e517e&&_0x5e517e['userId']===_0x52e1bc||_0x36ef85[_0x2245a1]['unshift']({'userId':_0x52e1bc,'object':_0x538320[_0x197de9]['item'],'change':_0x1707b8[_0x2245a1]}),'elementEnd'===_0x538320[_0x197de9]['type']&&_0x5e517e&&_0x5e517e['object']===_0x538320[_0x197de9]['item']&&(_0x36ef85[_0x2245a1]['shift'](),_0x1707b8[_0x2245a1]=_0x5e517e['change'])),_0x1707b8[_0x2245a1]&&_0x5a7a28&&(_0x1707b8[_0x2245a1]['end']=_0x702007,_0x2d1954(_0x1707b8[_0x2245a1]),_0x1707b8[_0x2245a1]=null);}function _0x2d1954({start:_0x26b22c,end:_0x5b08eb,tapeItem:_0x2bac61,userId:_0x4b2493,type:_0x6f53be}){const _0x54b3eb=_0x2bac61['item'],_0x212393=_0x26a505['schema']['isBlock'](_0x54b3eb)&&!_0x26a505['schema']['isLimit'](_0x54b3eb),_0x5dd370=_0x26b22c['nodeAfter']==_0x5b08eb['parent']&&_0x5b08eb['isAtStart'];if(_0x212393&&_0x5dd370)return;const _0x31d06a=_0x26a505['createRange'](_0x26b22c,_0x5b08eb),_0x4be777=_0x1cb4eb['get'](_0x4b2493),_0x26cf41=new r({'author':_0x4be777,'type':'isAdded'==_0x6f53be||'isAddSuggestion'==_0x6f53be?'add':'remove','data':{'isSuggestion':'isAddSuggestion'==_0x6f53be||'isRemoveSuggestion'==_0x6f53be},'createdAt':new Date(),'rootName':_0x315ef0});_0x37a1b7['push'](_0x26cf41),_0x3a4dd8['markers']['set']('revision:'+_0x26cf41['id'],_0x31d06a);}function _0x5a1477(_0x5c9578,_0x366f70){const _0x2de1bc=_0x5c9578['getAttributes'](),_0x24e443=_0x366f70['getAttributes']();for(const _0x581272 of _0x2de1bc){if(_0x581272[0x1]!==_0x366f70['getAttribute'](_0x581272[0x0]))return!0x1;_0x24e443['next']();}return _0x24e443['next']()['done'];}}['_setConversion'](){this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision','view':_0x42e276=>{const _0x298634=_0x42e276['markerName']['split'](':')[0x1],_0x4868e3=this['_getChangeFromId'](_0x298634);if(!_0x4868e3)return null;const _0x21c094='add'==_0x4868e3['type']?'insertion':'deletion',_0x3b0d35=['ck-suggestion-marker','ck-suggestion-marker-'+_0x21c094];return _0x4868e3['data']['isSuggestion']&&_0x3b0d35['push']('ck-suggestion-marker-'+_0x21c094+'-new'),this['activeChange']==_0x4868e3&&_0x3b0d35['push']('ck-suggestion-marker--active'),{'classes':_0x3b0d35,'attributes':{'data-change-id':_0x298634}};}}),this['editor']['conversion']['for']('upcast')['add'](_0x5ce872=>{_0x5ce872['on']('element:pre',(_0x75234a,_0x1e04d8,_0x32cc0b)=>{const _0x24a491=_0x1e04d8['viewItem']['getChild'](0x0);if(!_0x24a491||!_0x24a491['is']('element','code'))return;if(!_0x32cc0b['consumable']['consume'](_0x24a491,{'attributes':['vid_start','vid_end']}))return;const _0x172a5d=_0x1e04d8['modelRange']['start']['nodeAfter'];_0x32cc0b['writer']['setAttribute']('vid_start',_0x24a491['getAttribute']('vid_start'),_0x172a5d),_0x32cc0b['writer']['setAttribute']('vid_end',_0x24a491['getAttribute']('vid_end'),_0x172a5d);},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['add'](_0xeb0d71=>{_0xeb0d71['on']('element',(_0x55a306,_0x28e4b1,_0x3bc32e)=>{if(!_0x3bc32e['consumable']['consume'](_0x28e4b1['viewItem'],{'attributes':['vid_start','vid_end']}))return;if(_0x28e4b1['modelRange']['isCollapsed'])return;const _0x4a1645=_0x28e4b1['modelRange']['start']['nodeAfter'];_0x4a1645['hasAttribute']('vid_start')||_0x4a1645['hasAttribute']('vid')||(_0x3bc32e['writer']['setAttribute']('vid_start',_0x28e4b1['viewItem']['getAttribute']('vid_start'),_0x4a1645),_0x3bc32e['writer']['setAttribute']('vid_end',_0x28e4b1['viewItem']['getAttribute']('vid_end'),_0x4a1645));},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['elementToAttribute']({'view':{'name':'span','attributes':{'vid':!0x0}},'model':{'key':'vid','value':_0x457c8a=>_0x457c8a['getAttribute']('vid')}}),this['editor']['model']['schema']['on']('checkAttribute',(_0x4da576,[,_0x582141])=>{['vid_start','vid_end','vid']['includes'](_0x582141)&&(_0x4da576['return']=!0x0,_0x4da576['stop']());},{'priority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x6cf283=>{_0x6cf283['on']('attribute:vid',(_0x518853,_0xa23fd2,_0x18016d)=>{if('\x20'!=_0xa23fd2['item']['data']||_0xa23fd2['item']['parent']['maxOffset']>0x1)return;if(!_0x18016d['consumable']['consume'](_0xa23fd2['item'],_0x518853['name']))return;const _0x428709=_0x18016d['writer'],_0x8e271c=_0x18016d['mapper']['toViewRange'](_0xa23fd2['range']);_0x428709['wrap'](_0x8e271c,_0x428709['createAttributeElement']('span'));});}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',function(_0x3a2ee6){const _0x21ecfa=_0x3a2ee6['plugins']['get']('RevisionViewer');return(_0x5348ff,_0x33bf8a,_0x4bc233)=>{const _0x5c1801=_0x33bf8a['markerName']['split'](':')[0x1],_0x301b4e=_0x21ecfa['_getChangeFromId'](_0x5c1801);if(!_0x301b4e)return null;const _0x56b66e='add'==_0x301b4e['type']?'split':'merge';if(!_0x4bc233['consumable']['test'](_0x33bf8a['markerRange'],_0x5348ff['name']))return;const _0x59ad0d=_0x33bf8a['markerRange']['getWalker'](),_0x41d2e1=_0x33bf8a['markerRange']['start'],_0xacf022=_0x3a2ee6['model']['schema'];let _0x22f6e1=null,_0xf22d45=null,_0xbf4848=!0x1,_0x26f10f=!0x1;for(const _0x431bba of _0x59ad0d){const _0x42fe00=_0x431bba['item'];_0xbf4848=_0xbf4848||_0xacf022['isContent'](_0x42fe00);const _0x5c3f14=_0x4bc233['mapper']['toViewElement'](_0x42fe00);if(_0x5c3f14&&_0x5c3f14['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x431bba['type']&&(_0xacf022['isBlock'](_0x42fe00)&&!_0xacf022['isLimit'](_0x42fe00)&&(_0x42fe00['nextSibling']||_0x41d2e1['isAtEnd']?_0x22f6e1&&_0x22f6e1['parent']==_0x42fe00||(_0x22f6e1=_0x42fe00,_0x5e98e3(_0x431bba['previousPosition']),_0x26f10f=!0x0):_0xf22d45=_0xf22d45||_0x431bba['previousPosition']));}function _0x5e98e3(_0x561f3e){const _0x1e7631=_0x4bc233['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x56b66e}),_0x531541=_0x4bc233['mapper']['toViewPosition'](_0x561f3e);_0x301b4e['data']['isSuggestion']&&_0x4bc233['writer']['addClass']('ck-suggestion-marker-'+_0x56b66e+'-new',_0x1e7631),_0x21ecfa['activeChange']==_0x301b4e&&_0x4bc233['writer']['addClass']('ck-suggestion-marker--active',_0x1e7631),_0x4bc233['writer']['insert'](_0x531541,_0x1e7631),_0x4bc233['mapper']['bindElementToMarker'](_0x1e7631,_0x33bf8a['markerName']);}_0xbf4848||_0x26f10f||!_0xf22d45||_0x5e98e3(_0xf22d45);};}(this['editor']),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision',(_0xcce3bf,_0x100c5c,_0x54240d)=>{const _0x1c88c0=_0x54240d['mapper']['markerNameToElements'](_0x100c5c['markerName']);if(_0x1c88c0){for(const _0x4eb9b5 of _0x1c88c0)(_0x4eb9b5['hasClass']('ck-suggestion-marker-split')||_0x4eb9b5['hasClass']('ck-suggestion-marker-merge'))&&(_0x54240d['mapper']['unbindElementFromMarkerName'](_0x4eb9b5,_0x100c5c['markerName']),_0x54240d['writer']['remove'](_0x4eb9b5));}},{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',(_0xd6d18d,_0xa02e5f,_0x1f83d2)=>{const _0x279ca5=_0xa02e5f['markerName']['split'](':')[0x1],_0x332b7e=this['_getChangeFromId'](_0x279ca5);if(!_0x332b7e)return null;const _0x1b30c2='add'==_0x332b7e['type']?'split':'merge';if(_0x1f83d2['consumable']['test'](_0xa02e5f['markerRange'],_0xd6d18d['name']))for(const _0x41ede1 of _0xa02e5f['markerRange']['getItems']()){if(!_0x41ede1['is']('element','softBreak'))continue;const _0x3a15c6=_0x1f83d2['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x1b30c2}),_0x44d433=_0x1f83d2['mapper']['toViewPosition'](this['editor']['model']['createPositionBefore'](_0x41ede1));_0x332b7e['data']['isSuggestion']&&_0x1f83d2['writer']['addClass']('ck-suggestion-marker-'+_0x1b30c2+'-new',_0x3a15c6),this['activeChange']==_0x332b7e&&_0x1f83d2['writer']['addClass']('ck-suggestion-marker--active',_0x3a15c6),_0x1f83d2['writer']['insert'](_0x44d433,_0x3a15c6),_0x1f83d2['mapper']['bindElementToMarker'](_0x3a15c6,_0xa02e5f['markerName']);}},{'priority':'high'}),this['editor']['model']['document']['on']('change',()=>{this['editor']['editing']['view']['change'](_0x19743b=>{for(const _0xfceba8 of this['editor']['model']['document']['getRootNames']()){const _0xf1b70e=this['editor']['model']['document']['getRoot'](_0xfceba8),_0xf9274=this['editor']['editing']['view']['document']['getRoot'](_0xfceba8);if(_0xf9274){const _0x2bf3a3=_0xf1b70e['getAttribute']('revisionHistoryAttachChange');if(_0x19743b['removeAttribute']('data-change-id',_0xf9274),_0x19743b['removeClass']('ck-revision-history-root-add',_0xf9274),_0x19743b['removeClass']('ck-revision-history-root-remove',_0xf9274),_0x19743b['removeClass']('ck-revision-history-root--active',_0xf9274),_0x2bf3a3){const _0x1986ba=this['_getChangeFromId'](_0x2bf3a3);if(!_0x1986ba)return null;_0x19743b['setAttribute']('data-change-id',_0x2bf3a3,_0xf9274),_0x19743b['addClass']('ck-revision-history-root-'+_0x1986ba['type'],_0xf9274),this['activeChange']==_0x1986ba&&_0x19743b['addClass']('ck-revision-history-root--active',_0xf9274);}}}});}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'comment','model':_0x128dac=>'revision-comment:'+_0x128dac,'converterPriority':'highest'}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'suggestion','model':_0x3b87c5=>'revision-suggestion:'+_0x3b87c5,'converterPriority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision-suggestion','view':_0x103e96=>({'name':'suggestion:'+_0x103e96,'group':'revision-suggestion'}),'converterPriority':'highest'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision-suggestion','view':_0x24a910=>{const _0x1a3de5=_0x24a910['markerName']['split'](':')[0x1];return'insertion'!=_0x1a3de5&&'deletion'!=_0x1a3de5?null:{'classes':['ck-suggestion-preview-marker','ck-suggestion-preview-marker-'+_0x1a3de5]};}}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:deletion',X(this['editor'],'merge'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:insertion',X(this['editor'],'split'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision-suggestion',(_0x85ba7e,_0x4ca2a6,_0x2ec598)=>{const _0x145893=_0x2ec598['mapper']['markerNameToElements'](_0x4ca2a6['markerName']);if(_0x145893){for(const _0x454688 of _0x145893)_0x454688['is']('uiElement')&&(_0x2ec598['mapper']['unbindElementFromMarkerName'](_0x454688,_0x4ca2a6['markerName']),_0x2ec598['writer']['remove'](_0x454688));}},{'priority':'high'});}['_getChangeFromId'](_0x24e5dd){return this['_changeIdToChange']['get'](_0x24e5dd);}['_getViewForChange'](_0x1ce054){return this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=new Q(this['editor']['locale'],_0x1ce054),this['_changeView'];}['_initInteractions'](){this['editor']['model']['document']['selection']['observeMarkers']('revision'),this['on']('change:activeView',(_0x8af1f5,_0x1bdae6,_0x26eec,_0x53c24d)=>{_0x53c24d&&this['_balloon']['remove'](_0x53c24d),_0x26eec&&(this['_balloon']['add']({'view':_0x26eec,'stackId':'revisionHistoryLabel','position':{'target':()=>{const _0x98b21c=this['editor']['editing'],_0x3166a4=this['_getChangeFromId'](_0x26eec['changeId']);let _0x1d4c60;if(_0x3166a4['data']['isOnRoot']){const _0x23e2bb=_0x98b21c['view']['getDomRoot'](_0x3166a4['rootName']);_0x1d4c60=Array['from'](_0x23e2bb['getClientRects']());}else{const _0x30720c=this['editor']['model']['markers']['get']('revision:'+_0x26eec['changeId']);_0x1d4c60=Array['from'](_0x98b21c['mapper']['markerNameToElements'](_0x30720c['name']))['map'](_0x419d0d=>_0x98b21c['view']['domConverter']['mapViewToDom'](_0x419d0d))['map'](_0x3bef20=>Array['from'](_0x3bef20['getClientRects']()))['flat']();}if(!this['_activeViewTarget'])return _0x1d4c60[0x0];return _0x1d4c60['find'](_0x440793=>_0x440793['top']-0x3<=this['_activeViewTarget']['y']&&_0x440793['bottom']+0x3>=this['_activeViewTarget']['y']&&_0x440793['left']-0x3<=this['_activeViewTarget']['x']&&_0x440793['right']+0x3>=this['_activeViewTarget']['x'])||_0x1d4c60[0x0];}}}),this['_balloon']['showStack']('revisionHistoryLabel'));}),this['on']('change:activeChange',(_0x3cbeae,_0x36732b,_0x205d8b,_0x22ba27)=>{this['activeView']=_0x205d8b?this['_getViewForChange'](_0x205d8b):null,this['editor']['model']['change'](()=>{const _0x4e6be1=this['editor']['editing'];_0x22ba27&&(_0x22ba27['data']['isOnRoot']?_0x4e6be1['view']['change'](_0x16311d=>{_0x16311d['removeClass']('ck-revision-history-root--active',_0x4e6be1['view']['document']['getRoot'](_0x22ba27['rootName']));}):_0x4e6be1['reconvertMarker']('revision:'+_0x22ba27['id'])),_0x205d8b&&(_0x205d8b['data']['isOnRoot']?_0x4e6be1['view']['change'](_0x355b75=>{_0x355b75['addClass']('ck-revision-history-root--active',_0x4e6be1['view']['document']['getRoot'](_0x205d8b['rootName']));}):_0x4e6be1['reconvertMarker']('revision:'+_0x205d8b['id']));});}),this['listenTo'](this['editor']['editing']['view']['document'],'mouseover',(_0x113518,_0x140f13)=>{if(this['activeChange'])return;const _0x5affa1=this['_findChangeIdFromDomTarget'](_0x140f13['target']),_0x3e0989=this['_changeIdToChange']['get'](_0x5affa1);_0x3e0989?(this['_activeViewTarget']={'x':_0x140f13['domEvent']['x'],'y':_0x140f13['domEvent']['y']},this['activeView']=this['_getViewForChange'](_0x3e0989)):(this['_activeViewTarget']=null,this['activeView']=null);}),this['listenTo'](this['editor']['editing']['view']['document'],'mousedown',(_0x3c5475,_0x32e0d8)=>{const _0x5519dd=this['_findChangeIdFromDomTarget'](_0x32e0d8['target']),_0xbd8a92=this['_changeIdToChange']['get'](_0x5519dd);_0xbd8a92?(this['_activeViewTarget']={'x':_0x32e0d8['domEvent']['x'],'y':_0x32e0d8['domEvent']['y']},_0xbd8a92===this['activeChange']?this['_balloon']['updatePosition']():this['activeChange']=_0xbd8a92):(this['_activeViewTarget']=null,this['activeChange']=null);});}['_findChangeIdFromDomTarget'](_0x405e9f){do{const _0x4408a9=_0x405e9f['getAttribute']('data-change-id');if(_0x4408a9)return _0x4408a9;_0x405e9f=_0x405e9f['parent'];}while(_0x405e9f);return null;}['_cleanMarkers'](){this['editor']['model']['change'](_0x45ec8d=>{for(const _0x4459f2 of this['editor']['model']['markers'])_0x45ec8d['removeMarker'](_0x4459f2);});}}function X(_0x36252d,_0xf4b222){return(_0x3a2243,_0x55e88d,_0x5d4158)=>{if(!_0x5d4158['consumable']['test'](_0x55e88d['markerRange'],_0x3a2243['name']))return;const _0x3dd49a=_0x55e88d['markerRange']['getWalker'](),_0x301eb9=_0x55e88d['markerRange']['start'],_0xf1b48=_0x36252d['model']['schema'];let _0x17936b=null,_0x2ae2d7=null,_0x256b3e=!0x1,_0xe9eaca=!0x1;for(const _0x4b6e4 of _0x3dd49a){const _0x4bdaa8=_0x4b6e4['item'];_0x256b3e=_0x256b3e||_0xf1b48['isContent'](_0x4bdaa8);const _0x1ac16c=_0x5d4158['mapper']['toViewElement'](_0x4bdaa8);if(_0x1ac16c&&_0x1ac16c['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x4b6e4['type']&&(_0xf1b48['isBlock'](_0x4bdaa8)&&!_0xf1b48['isLimit'](_0x4bdaa8)&&(_0x4bdaa8['nextSibling']||_0x301eb9['isAtEnd']?_0x17936b&&_0x17936b['parent']==_0x4bdaa8||(_0x17936b=_0x4bdaa8,_0x15b53a(_0x4b6e4['previousPosition']),_0xe9eaca=!0x0):_0x2ae2d7=_0x2ae2d7||_0x4b6e4['previousPosition']));}function _0x15b53a(_0x38c30a){const _0x1cedd7=_0x5d4158['mapper']['toViewPosition'](_0x38c30a),_0x456012=_0x5d4158['writer']['createUIElement']('span',{'class':'ck-suggestion-preview-marker-'+_0xf4b222});_0x5d4158['writer']['insert'](_0x1cedd7,_0x456012),_0x5d4158['mapper']['bindElementToMarker'](_0x456012,_0x55e88d['markerName']);}_0x256b3e||_0xe9eaca||!_0x2ae2d7||_0x15b53a(_0x2ae2d7);};}class mt extends _0x2a06ae{constructor(_0x4f86d1){super(_0x4f86d1);const _0x15c3f8=_0x4f86d1['plugins']['get'](m);this['affectsData']=!0x1,this['listenTo'](_0x15c3f8,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x15c3f8,'change:isEnabled',()=>this['refresh']());}['execute'](){const _0x5ae506=this['editor'],_0x2fe020=_0x5ae506['plugins']['get'](m),_0x544551=_0x2fe020['isReady']?_0x2fe020['diff']['newRevisionId']:null;_0x5ae506['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x544551);}['refresh'](){const {isReady:_0x19763c,isEnabled:_0x466f9f,repository:_0x2b4c59,diff:_0x491918}=this['editor']['plugins']['get'](m),_0x4a44c9=_0x491918&&_0x2b4c59['getLaterVisibleRevision'](_0x491918['newRevisionId']);this['isEnabled']=_0x19763c&&_0x466f9f&&Boolean(_0x4a44c9);}}class wt extends _0x2a06ae{['_step'];constructor(_0x379e79,{direction:_0x2a040e}){super(_0x379e79);const _0x4bf289=_0x379e79['plugins']['get'](m);this['affectsData']=!0x1,this['_step']='forward'===_0x2a040e?0x1:-0x1,this['listenTo'](_0x4bf289,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x4bf289,'change:isEnabled',()=>this['refresh']()),this['listenTo'](_0x4bf289,'change:activeChange',()=>this['refresh']());}['execute'](){const _0x38598e=this['editor'],_0x5a86bf=_0x38598e['plugins']['get'](m),{isNavigationMode:_0x23871b,currentChangeNumber:_0x3b77df}=_0x5a86bf;let _0x5cf56e;if(_0x5a86bf['activeChange']=_0x23871b?_0x5a86bf['diff']['changes']['get'](_0x3b77df+this['_step']):_0x5a86bf['diff']['changes']['first'],_0x5a86bf['activeChange']['data']['isOnRoot'])_0x5cf56e=_0x38598e['editing']['view']['getDomRoot'](_0x5a86bf['activeChange']['rootName']);else{const _0x5b8046=_0x38598e['model']['markers']['get']('revision:'+_0x5a86bf['activeChange']['id']);_0x5cf56e=_0x5dbfca(_0x38598e['editing'],_0x5b8046);}_0x5d9a0a({'target':_0x5cf56e,'viewportOffset':0x28});}['refresh'](){const {isNavigationMode:_0x11cc68,currentChangeNumber:_0x5f3a45,numberOfChanges:_0x330ba9,isReady:_0x44d526,isEnabled:_0x5bc334}=this['editor']['plugins']['get'](m);this['isEnabled']=!!(_0x5bc334&&_0x44d526&&_0x330ba9)&&(!_0x11cc68||(0x1===this['_step']?_0x5f3a45<_0x330ba9-0x1:_0x5f3a45>0x0));}}class _i extends ts{constructor(_0x19cd30){super(_0x19cd30);const _0x3c60d8=this['bindTemplate'],_0x3f187a=new te(_0x19cd30),_0x42133d=new te(_0x19cd30);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',(_0x37fd22,_0x1164ce)=>_0x37fd22&&_0x1164ce>0x0),this['bind']('_statusText')['to'](this,'isReady',this,'currentChangeNumber',this,'numberOfChanges',this,'isNavigationMode',(_0x47fcda,_0x4f4965,_0x4cc8b9,_0x26a802)=>{if(!_0x47fcda)return g(_0x19cd30,'Loading...');if(!_0x4cc8b9)return g(_0x19cd30,'No\x20changes');const _0x392937=g(_0x19cd30,'NUMBER_OF_CHANGES',_0x4cc8b9);return _0x26a802?g(_0x19cd30,'X_OF_Y_CHANGES',[_0x4f4965+0x1,_0x4cc8b9]):_0x392937;}),_0x3f187a['set']({'label':g(_0x19cd30,'Show\x20previous\x20change'),'tooltip':!0x0,'icon':_0x19d9b9}),_0x42133d['set']({'label':g(_0x19cd30,'Show\x20next\x20change'),'tooltip':!0x0,'icon':_0x44f056}),_0x3f187a['bind']('isEnabled')['to'](this,'isBackwardNavigationEnabled'),_0x42133d['bind']('isEnabled')['to'](this,'isForwardNavigationEnabled'),_0x3f187a['on']('execute',()=>this['fire']('execute','backward')),_0x42133d['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',_0x3c60d8['if']('_isStatusLabelVisible','ck-hidden',_0x2c0600=>!_0x2c0600)]},'children':[{'text':_0x3c60d8['to']('isNavigationMode',_0x2acd4c=>_0x2acd4c?g(_0x19cd30,'EDIT_X_OF_Y_REVISIONS')+':\x20':g(_0x19cd30,'Total')+':\x20')}]},{'text':_0x3c60d8['to']('_statusText')}]},new _0x114a41(),{'tag':'div','attributes':{'class':['ck-revision-history-ui__changes-navigation__navigation']},'children':[_0x3f187a,_0x42133d]}]});}}const le='ck-editor__editable__loading-overlay';class ge extends _0x149b28{static get['pluginName'](){return'RevisionViewerLoadingOverlay';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['show'](){const _0x46deb7=this['editor']['editing']['view'];_0x46deb7['change'](_0x39f7cb=>{for(const _0x5a9757 of _0x46deb7['document']['roots'])_0x39f7cb['addClass'](le,_0x5a9757);});}['hide'](){const _0x1e3589=this['editor']['editing']['view'];_0x1e3589['change'](_0x253e79=>{for(const _0x8eb99a of _0x1e3589['document']['roots'])_0x253e79['removeClass'](le,_0x8eb99a);});}}class R extends _0x149b28{static get['pluginName'](){return'RevisionViewerUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[m,ge];}['init'](){const _0x556deb=this['editor'],_0x2d0749=_0x556deb['plugins']['get'](m),_0x220d75=_0x556deb['plugins']['get'](ge);_0x556deb['ui']['componentFactory']['add']('exitToEditing',_0x33be0b=>{const _0x1c95db=new te(_0x33be0b);return _0x1c95db['set']({'label':g(_0x33be0b,'Back\x20to\x20editing'),'icon':_0x58cf49,'withText':!0x0,'tooltip':!0x0,'class':'ck-revision-history-ui__back-to-editing'}),this['listenTo'](_0x1c95db,'execute',()=>{_0x556deb['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}),_0x1c95db;}),_0x556deb['ui']['componentFactory']['add']('restoreRevision',_0x3dd955=>{const _0x305cd8=new te(_0x3dd955);return _0x305cd8['set']({'label':g(_0x3dd955,'Restore\x20this\x20revision'),'withText':!0x0,'tooltip':!0x0}),_0x305cd8['bind']('isEnabled')['to'](_0x556deb['commands']['get']('restoreRevision')),this['listenTo'](_0x305cd8,'execute',()=>_0x556deb['execute']('restoreRevision')),_0x305cd8;}),_0x556deb['ui']['componentFactory']['add']('changesNavigation',_0x190cc9=>{const _0x30cb1e=new _i(_0x190cc9),_0x3044aa=_0x556deb['commands']['get']('showPreviousChange'),_0x59566c=_0x556deb['commands']['get']('showNextChange');return _0x30cb1e['bind']('isBackwardNavigationEnabled')['to'](_0x3044aa,'isEnabled'),_0x30cb1e['bind']('isForwardNavigationEnabled')['to'](_0x59566c,'isEnabled'),_0x30cb1e['bind']('isReady','currentChangeNumber','numberOfChanges','isNavigationMode')['to'](_0x2d0749),this['listenTo'](_0x30cb1e,'execute',(_0x25f81f,_0x4f639e)=>{_0x556deb['execute']('forward'===_0x4f639e?'showNextChange':'showPreviousChange');}),_0x30cb1e;}),_0x220d75['show'](),_0x2d0749['on']('change:isReady',(_0x70b489,_0x1968b9,_0x18f0e8)=>{_0x18f0e8?_0x220d75['hide']():_0x220d75['show']();});}}class at extends _0x256e64{['_resizeObserver']=null;constructor(_0x5713ce,_0x58f1c2){super(_0x5713ce,_0x58f1c2);const _0x2cfa55=this['bindTemplate'];this['set']({'label':g(_0x5713ce,'Revision\x20name'),'_tooltipString':''}),this['fieldView']['placeholder']=g(_0x5713ce,'Enter\x20the\x20revision\x20name'),this['extendTemplate']({'tag':'span','attributes':{'class':['ck-revision-history-sidebar__revision-name'],'data-cke-tooltip-text':_0x2cfa55['to']('_tooltipString'),'data-cke-tooltip-position':'s','data-cke-tooltip-class':'ck-tooltip_multi-line'}});}['render'](){super['render'](),this['_resizeObserver']=new nt(this['fieldView']['element'],()=>this['_updateTooltipText']()),this['listenTo'](this['fieldView'],'input',()=>this['_updateTooltipText']());}['destroy'](){super['destroy'](),this['_resizeObserver']&&this['_resizeObserver']['destroy']();}['_updateTooltipText'](){const _0x2e3c8e=this['fieldView']['element'];this['_tooltipString']=_0x2e3c8e['scrollWidth']>_0x2e3c8e['clientWidth']&&_0x2e3c8e['value']||'';}}class si extends ts{constructor(_0x349ff5,_0xb417c,_0x3d3a84){super(_0x349ff5);const _0xd1c2a4=new _0x418e0a();_0xd1c2a4['set']({'content':_0xe5b4b4,'viewBox':'0\x200\x2011\x2010'});const _0x1e2b9c=['ck','ck-revision-history-sidebar__revision-author'];_0x3d3a84&&_0x1e2b9c['push']('ck-revision-history-sidebar__revision-author_creator');const _0x400eb9=[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision-author__name'],'title':g(_0x349ff5,_0x3d3a84?'Revision\x20creator':'Revision\x20author')},'children':[_0xd1c2a4,_0xb417c['name']]}];this['setTemplate']({'tag':'li','attributes':{'class':_0x1e2b9c},'children':_0x400eb9});}}function oi(_0x2abfeb,_0x25a06b){const _0x30c9b2=_0x2abfeb['bindTemplate'],_0x1c986d=_0x2abfeb['locale'],_0x1c69ae=_0x3c0c02(_0x1c986d);_0x1c69ae['panelPosition']='sw';const _0x3a595b=function(_0xbac91e,_0x14d689){const _0x2d3d79=function(_0x273c79,_0x5ee27f){const _0x431d8c=_0x273c79['locale'],_0x260df1={'Compare\x20against\x20selected':g(_0x431d8c,'Compare\x20against\x20selected'),'Name\x20this\x20revision':g(_0x431d8c,'Name\x20this\x20revision'),'Restore\x20this\x20revision':g(_0x431d8c,'Restore\x20this\x20revision')};return _0x5ee27f['map'](_0x2c79a3=>{const _0x5b1317=_0x260df1[_0x2c79a3['name']];return _0x5b1317&&_0x5b1317!==_0x2c79a3['name']&&(_0x2c79a3['name']=_0x5b1317),_0x2c79a3;});}(_0xbac91e,_0x14d689),_0x2f09b9=new _0x3fcc51();for(const _0x34010f of _0x2d3d79){const _0x298e17={'type':'button','model':new to({'label':_0x34010f['name'],'class':_0x34010f['class'],'withText':!0x0,'role':'menuitem','_action':_0x34010f['action']})};_0x298e17['model']['bind']('isEnabled')['to'](_0xbac91e,'isActionsDropdownOpen',_0x48f951=>'function'!=typeof _0x34010f['isEnabled']||(!_0x48f951||_0x34010f['isEnabled'](_0xbac91e))),_0x2f09b9['add'](_0x298e17);}return _0x2f09b9;}(_0x2abfeb,_0x25a06b);return _0x2abfeb['bind']('isActionsDropdownOpen')['to'](_0x1c69ae,'isOpen'),_0x1c69ae['buttonView']['set']({'label':g(_0x1c986d,'Show\x20more\x20items'),'tooltip':!0x0,'tooltipPosition':'sw','icon':_0x28c0d7}),_0x1c69ae['extendTemplate']({'attributes':{'class':['ck-revision-history-sidebar__revision__actions',_0x30c9b2['if']('isActionsDropdownOpen','ck-on')]},'on':{'click':_0x30c9b2['to'](_0x3b684b=>_0x3b684b['stopPropagation']())}}),_0x1c69ae['on']('execute',_0x193747=>{_0x2abfeb['isReady']&&'function'==typeof _0x193747['source']['_action']&&_0x193747['source']['_action'](_0x2abfeb);}),_0x2ce9a1(_0x1c69ae,_0x3a595b,{'role':'menu'}),_0x1c69ae['listenTo'](_0x2abfeb,'change:isActionsDropdownOpen',(_0x40baa3,_0x525df7,_0x3bb58d)=>{if(_0x3bb58d)for(const _0x27be87 of _0x1c69ae['listView']['items']){const _0x369ca1=_0x27be87['children']['first'],_0x594d7f=_0x25a06b['find'](_0x1d6699=>_0x1d6699['action']===_0x369ca1['_action'])['isVisible'];_0x27be87['isVisible']=void 0x0===_0x594d7f||_0x594d7f(_0x2abfeb);}}),_0x1c69ae;}class hi extends/* #__PURE__ -- @preserve */
26
- ti(ts){['id'];['revisionNameView'];['revisionActionsView'];['_revision'];['_requireRevisionName'];constructor(_0xda9d0,_0x2ab90d,_0x7cbed7,_0x16b4d8){super(_0xda9d0);const _0x5d6e60=this['bindTemplate'],_0x2cbb75=function(_0x117331,_0xedfc63){const _0x24b777=Array['from'](_0xedfc63['authors'])['filter'](_0x1e5a11=>_0x1e5a11!=_0xedfc63['creator']);return _0xedfc63['creator']&&_0x24b777['unshift'](_0xedfc63['creator']),_0x24b777['map'](_0x16ed55=>new si(_0x117331,_0x16ed55,_0x16ed55==_0xedfc63['creator']));}(_0xda9d0,_0x2ab90d);this['id']=_0x2ab90d['id'],this['_revision']=_0x2ab90d,this['_requireRevisionName']=_0x16b4d8,this['bind']('name','createdAt')['to'](_0x2ab90d),this['bind']('_createdAtFormatted')['to'](this,'createdAt',_0x15186f=>{return _0x58fd8c=_0xda9d0['uiLanguage'],(_0x506e35=_0x15186f)['toLocaleDateString'](_0x58fd8c,{'month':'long','day':'numeric'})+',\x20'+_0x506e35['toLocaleTimeString'](_0x58fd8c,{'hour':'numeric','minute':'numeric'});var _0x58fd8c,_0x506e35;}),this['set']('isSelected',!0x1),this['set']('isHighlighted',!0x1),this['set']('isActionsDropdownOpen',!0x1),this['set']('isReady',!0x1),this['set']('isEnabled',!0x1),this['revisionNameView']=new at(_0xda9d0,_0xb8ce7b),this['revisionNameView']['fieldView']['extendTemplate']({'attributes':{'maxlength':'220'}}),this['revisionNameView']['fieldView']['bind']('value')['to'](this,'name',_0x94b560=>_0x94b560||this['_createdAtFormatted']),this['revisionNameView']['bind']('isEnabled')['to'](this,'isSelected',this,'isEnabled',(_0x11d1b6,_0x4de3cf)=>_0x11d1b6&&_0x4de3cf),this['revisionActionsView']=_0x7cbed7&&_0x7cbed7['length']?oi(this,_0x7cbed7):'',this['revisionActionsView']&&this['revisionActionsView']['bind']('isEnabled')['to'](this),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision-wrapper',_0x5d6e60['if']('isConfirm','ck-revision-history-sidebar__revision-wrapper_confirmation_visible')]},'children':[{'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision',_0x5d6e60['if']('isEnabled','ck-disabled',_0x18fcd6=>!_0x18fcd6),_0x5d6e60['if']('isSelected','ck-revision-history-sidebar__revision_selected'),_0x5d6e60['if']('isHighlighted','ck-revision-history-sidebar__revision_highlighted'),_0x5d6e60['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':_0x5d6e60['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':_0x2cbb75}]},this['revisionActionsView']],'on':{'click':_0x5d6e60['to'](_0x58f01d=>{_0x58f01d['srcElement']['closest']('.ck-thread__remove-confirm')||this['isReady']&&this['isEnabled']&&this['fire']('select',{'id':this['id']});})}}]});}['render'](){super['render']();const _0x1c183d=this['revisionNameView']['fieldView']['element'];this['listenTo'](_0x1c183d,'change',()=>{this['_requireRevisionName']&&!_0x1c183d['value']||this['fire']('setName',{'id':this['id'],'name':_0x1c183d['value']}),_0x1c183d['value']||(_0x1c183d['value']=this['name']?this['name']:this['_createdAtFormatted']);});}['select'](){this['isSelected']=!0x0;}['deselect'](){this['isSelected']=!0x1;}['highlight'](){this['isHighlighted']=!0x0;}['unhighlight'](){this['isHighlighted']=!0x1;}}function ai(_0x2edc19,_0x2e18eb){const _0x1c7333=_0x9f88ff['fromJSDate'](_0x2edc19)['setLocale'](_0x2e18eb),_0x309b2e=_0x9f88ff['local'](),_0x177773=_0x309b2e['minus']({'days':0x1})['startOf']('day');let _0x2368b3,_0x39ba07;return _0x1c7333['hasSame'](_0x309b2e,'day')?(_0x2368b3=_0x1c7333['startOf']('day')['toJSDate'](),_0x39ba07=_0x1c7333['toRelativeCalendar']()):_0x1c7333['hasSame'](_0x177773,'day')?(_0x2368b3=_0x177773['toJSDate'](),_0x39ba07=_0x1c7333['toRelativeCalendar']()):_0x1c7333['hasSame'](_0x309b2e,'week')?(_0x2368b3=_0x1c7333['startOf']('week')['toJSDate'](),_0x39ba07=_0x1c7333['weekdayLong']||''):_0x1c7333['hasSame'](_0x309b2e,'year')?(_0x2368b3=_0x1c7333['startOf']('month')['toJSDate'](),_0x39ba07=_0x1c7333['monthLong']||''):(_0x2368b3=_0x1c7333['startOf']('year')['toJSDate'](),_0x39ba07=String(_0x1c7333['year'])),{'startDate':_0x2368b3,'localizedPeriodName':_0x39ba07};}class di extends ts{['startDate'];['revisionViews'];['_revisionActions'];['_requireRevisionName'];constructor(_0x1bc873,_0x46019b,_0x5175ef,_0xa655ce){super(_0x1bc873);const _0x112387=ai(_0x46019b,this['locale']['uiLanguage'])['localizedPeriodName'];this['startDate']=_0x46019b,this['revisionViews']=this['createCollection'](),this['_revisionActions']=_0x5175ef,this['_requireRevisionName']=_0xa655ce,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':_0x112387}]},{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__time-period__revisions']},'children':this['revisionViews']}]});}['addRevision'](_0x294de3){const _0x1ba59f=new hi(this['locale'],_0x294de3,this['_revisionActions'],this['_requireRevisionName']);this['revisionViews']['add'](_0x1ba59f);}['removeRevision'](_0x10383d){const _0x5122f3=this['revisionViews']['find'](_0x37f258=>_0x37f258['id']===_0x10383d['id']);this['revisionViews']['remove'](_0x5122f3);}}class as extends ts{constructor(_0x484b76){super(_0x484b76);const _0x5d000b=new _0x418e0a();_0x5d000b['content']=_0x2f11fa,this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset_all','ck-revision-history-sidebar__header']},'children':[_0x5d000b,{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__header__label']},'children':[g(_0x484b76,'Revision\x20history')]}]});}}class ni extends ts{['timePeriodViews'];['_revisions'];['_revisionActions'];['_requireRevisionName'];constructor(_0x5100b2,_0x41a3a0,_0x43a569,_0x3d847c){super(_0x5100b2);const _0x2ac722=this['bindTemplate'];this['timePeriodViews']=this['createCollection'](),this['timePeriodViews']['delegate']('select')['to'](this),this['timePeriodViews']['delegate']('setName')['to'](this),this['_revisions']=_0x41a3a0,this['_revisionActions']=_0x43a569,this['_requireRevisionName']=_0x3d847c,this['on']('select',(_0x2afa68,_0x5ceb65)=>{this['fire']('revisionSelected',_0x5ceb65);}),this['on']('setName',(_0x2f99f0,_0x31ae6d)=>{this['fire']('revisionSetName',_0x31ae6d);}),this['set']('isEnabled',!0x1),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-rounded-corners','ck-revision-history-sidebar']},'children':[new as(_0x5100b2),{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__timeline',_0x2ac722['if']('isEnabled','ck-disabled',_0x300a6c=>!_0x300a6c)]},'children':this['timePeriodViews']}]});}['render'](){super['render']();for(const _0x15537c of this['_revisions'])this['_addRevision'](_0x15537c);this['_revisions']['on']('add',(_0x466741,_0x462828)=>{this['_addRevision'](_0x462828);}),this['_revisions']['on']('remove',(_0x50c88c,_0x53ec0e)=>{this['_removeRevision'](_0x53ec0e);});}get['revisionViews'](){return this['timePeriodViews']['map'](_0x5671c7=>_0x5671c7['revisionViews']['map'](_0x89a3bb=>_0x89a3bb))['flat']();}['selectRevision'](_0x56dfc1){for(const _0x2654a3 of this['revisionViews'])_0x56dfc1&&_0x56dfc1['id']===_0x2654a3['id']?_0x2654a3['select']():_0x2654a3['deselect']();}['highlightRevisions'](_0x15c5fa){for(const _0x37ecaa of this['revisionViews'])_0x15c5fa['some'](({id:_0x2f9f9c})=>_0x2f9f9c===_0x37ecaa['id'])?_0x37ecaa['highlight']():_0x37ecaa['unhighlight']();}['_addRevision'](_0x17574){const _0x21daa7=ai(_0x17574['createdAt'],this['locale']['uiLanguage'])['startDate'];let _0x5b6779=this['timePeriodViews']['get'](0x0);_0x5b6779&&_0x5b6779['startDate']['getTime']()===_0x21daa7['getTime']()||(_0x5b6779=new di(this['locale'],_0x21daa7,this['_revisionActions'],this['_requireRevisionName']),this['timePeriodViews']['add'](_0x5b6779)),_0x5b6779['addRevision'](_0x17574);}['_removeRevision'](_0x25093c){const _0x5abcb6=ai(_0x25093c['createdAt'],this['locale']['uiLanguage'])['startDate'];this['_getTimePeriodViewByStartDate'](_0x5abcb6)['removeRevision'](_0x25093c);}['_getTimePeriodViewByStartDate'](_0x5ac037){return this['timePeriodViews']['find'](_0x4dcd7d=>_0x4dcd7d['startDate']['getTime']()===_0x5ac037['getTime']());}}class d extends _0x149b28{['_revisionViewer'];['_revisionsRepository'];['_sidebarView'];static ['defaultRevisionActions']=/* #__PURE__ -- @preserve */
23
+ import{ObservableMixin as _0x3196fa,uid as _0x3fbd15,Collection as _0x5f0faf,logWarning as _0x1ce756,FocusTracker as _0x12b377,KeystrokeHandler as _0x10ecca,scrollViewportToShowTarget as _0x5c8233,ResizeObserver as nt,ElementReplacer as ot,CKEditorError as _0xae2ed9}from'@ckeditor/ckeditor5-utils/dist/index.js';import{cloneDeep as _0x4dbdf7,set as _0x3c9090,unset as _0x501d64,isEqual as _0x34eb88}from'es-toolkit/compat';import{Plugin as _0x1aaf30,PendingActions as _0x3cbd42,Command as _0x4e2556,ElementApiMixin as _0x59ee7c,Editor as _0x4d07a6}from'@ckeditor/ckeditor5-core/dist/index.js';import{Users as _0x25ff19,getMarkerDomElement as _0x56d34c,ConfirmMixin as ti,sanitizeEditorConfig as _0x1a3df8}from'ckeditor5-collaboration/dist/index.js';import{ViewContainerElement as _0x1586d5,ViewAttributeElement as _0x4a6f92,ViewEmptyElement as _0x35f70c,ViewRawElement as _0x34d858,ViewUIElement as _0x5e89db,ViewDocumentFragment as _0x12361a,ViewText as _0x3f0c02,ViewElement as _0x360a86,Element as ut,Range as lt,Position as ft,DocumentFragment as vt,Text as gt}from'@ckeditor/ckeditor5-engine/dist/index.js';import{IconHistory as _0x2aae82,IconChevronUp as _0x1dd0dd,IconChevronDown as _0x2464b9,IconUndo as _0x5c9b99,IconUser as _0x3c4811,IconThreeVerticalDots as _0x45dd43}from'@ckeditor/ckeditor5-icons/dist/index.js';import{View as ts,injectCssTransitionDisabler as _0x47db8c,submitHandler as _0x3b4acf,LabeledFieldView as _0x21d0c2,createLabeledInputText as _0x1a6c7a,createDropdown as _0x3baa9b,ListView as _0xaeeef7,ListItemView as _0x250e3b,ButtonView as te,MenuBarMenuView as _0x471360,MenuBarMenuListView as _0x118393,MenuBarMenuListItemView as _0x47d63b,MenuBarMenuListItemButtonView as _0x53ffb1,ContextualBalloon as _0x52db93,ToolbarSeparatorView as _0x32da21,IconView as _0x5c83c3,addListToDropdown as _0x11596f,ViewModel as to,EditorUI as st,normalizeToolbarConfig as et,BoxedEditorUIView as rt,StickyPanelView as ht,ToolbarView as dt,InlineEditableUIView as ct}from'@ckeditor/ckeditor5-ui/dist/index.js';import{DateTime as _0x3c368c}from'luxon';class h extends/* #__PURE__ -- @preserve */
24
+ _0x3196fa(){['id'];['creator'];['authors'];['diffData'];['toVersion'];['fromVersion'];['model'];constructor(_0x4f2892){super(),this['id']=_0x4f2892['id']||_0x3fbd15(),this['creator']=_0x4f2892['creator']||null,this['authors']=_0x4f2892['authors']||[],this['diffData']=_0x4f2892['diffData']||null,this['toVersion']=_0x4f2892['toVersion']||0x0,this['fromVersion']=_0x4f2892['fromVersion']||0x0,this['set']('name',_0x4f2892['name']||''),this['set']('createdAt',_0x4f2892['createdAt']||new Date()),this['set']('attributes',_0x4f2892['attributes']||{});}['setName'](_0x54d8c9){this['_update']({'name':_0x54d8c9});}['setAttribute'](_0x4aed2c,_0x453abe){const _0x2078cc=_0x4dbdf7(this['attributes']);_0x3c9090(_0x2078cc,_0x4aed2c,_0x453abe),this['_update']({'attributes':_0x2078cc});}['removeAttribute'](_0x557add){const _0x3b2c0f=_0x4dbdf7(this['attributes']);_0x501d64(_0x3b2c0f,_0x557add),this['_update']({'attributes':_0x3b2c0f});}['_update'](_0x4de87c,_0x2e9749=!0x1){let _0xd9f18d=!0x1;const _0x34f53e={'id':this['id']},_0x4e41af=['name','createdAt','diffData','authors','attributes','toVersion','fromVersion','creatorId'];for(const _0x5a29d6 of _0x4e41af){const _0x42c293=_0x4de87c[_0x5a29d6];void 0x0!==_0x42c293&&_0x42c293!==this[_0x5a29d6]&&(this[_0x5a29d6]=_0x42c293,_0x34f53e[_0x5a29d6]=_0x42c293,_0xd9f18d=!0x0);}_0xd9f18d&&(_0x34f53e['authors']&&(_0x34f53e['authorsIds']=_0x34f53e['authors']['map'](_0x597caf=>_0x597caf['id']),delete _0x34f53e['authors']),this['fire']('_update',_0x34f53e,_0x2e9749));}['toJSON'](){return{'id':this['id'],'name':this['name'],'creatorId':this['creator']?this['creator']['id']:null,'authorsIds':this['authors']['map'](_0x3b1ec3=>_0x3b1ec3['id']),'diffData':this['diffData'],'createdAt':this['createdAt'],'attributes':this['attributes'],'fromVersion':this['fromVersion'],'toVersion':this['toVersion']};}}class I extends _0x1aaf30{['_revisions'];static get['requires'](){return[_0x25ff19];}static get['pluginName'](){return'RevisionsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['length'](){return this['_revisions']['length'];}constructor(_0x5d1658){super(_0x5d1658),this['_revisions']=new _0x5f0faf();}['afterInit'](){!async function(_0x4ef661){const _0x5df1b6=_0x51f2b1([0x73,0x39,0x4e,0x64,0x55,0x79,0x38,0x68,0x32,0x4a,0x75,0x78,0x50,0x7a,0x6a,0x34,0x69,0x59,0x63,0x76,0x62,0x57,0x4c,0x30,0x36,0x35,0x65,0x71,0x70,0x51,0x74,0x61,0x4d,0x48,0x43,0x5a,0x45,0x6b,0x4b,0x31,0x37,0x47,0x41,0x67,0x44,0x72,0x56,0x6f,0x49,0x33,0x42,0x54,0x53,0x58,0x6e,0x6c,0x52,0x46,0x6d,0x4f,0x77,0x66]),_0x5b391a=0xeb829,_0x45c19a=0x7365c09a,_0x5002da=0x7362a4da^_0x45c19a,_0x654cda=window[_0x51f2b1([0x44,0x61,0x74,0x65])][_0x51f2b1([0x6e,0x6f,0x77])](),_0x1b2a07=_0x4ef661[_0x51f2b1([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x39bbdc=new window[(_0x51f2b1([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x2e2fa8=>{_0x1b2a07[_0x51f2b1([0x6f,0x6e,0x63,0x65])](_0x51f2b1([0x72,0x65,0x61,0x64,0x79]),_0x2e2fa8);}),_0x502c7b={[_0x51f2b1([0x6b,0x74,0x79])]:_0x51f2b1([0x45,0x43]),[_0x51f2b1([0x75,0x73,0x65])]:_0x51f2b1([0x73,0x69,0x67]),[_0x51f2b1([0x63,0x72,0x76])]:_0x51f2b1([0x50,0x2d,0x32,0x35,0x36]),[_0x51f2b1([0x78])]:_0x51f2b1([0x69,0x43,0x6a,0x4f,0x43,0x76,0x44,0x46,0x49,0x36,0x6c,0x51,0x48,0x48,0x54,0x31,0x38,0x6a,0x56,0x77,0x52,0x66,0x6b,0x66,0x48,0x51,0x32,0x61,0x5f,0x4d,0x79,0x6d,0x54,0x33,0x35,0x4c,0x51,0x56,0x6f,0x46,0x53,0x41,0x49]),[_0x51f2b1([0x79])]:_0x51f2b1([0x6b,0x58,0x49,0x79,0x4a,0x34,0x65,0x76,0x74,0x43,0x45,0x46,0x52,0x6d,0x78,0x4b,0x53,0x55,0x70,0x4b,0x39,0x66,0x44,0x57,0x34,0x35,0x39,0x76,0x58,0x4f,0x76,0x56,0x72,0x68,0x66,0x36,0x75,0x51,0x41,0x65,0x4f,0x69,0x6f]),[_0x51f2b1([0x61,0x6c,0x67])]:_0x51f2b1([0x45,0x53,0x32,0x35,0x36])},_0x2498ad=_0x1b2a07[_0x51f2b1([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x51f2b1([0x67,0x65,0x74])](_0x51f2b1([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x551e46(){let _0x38e37c,_0x8ec9f4=null,_0x20a63f=null;try{if(_0x2498ad==_0x51f2b1([0x47,0x50,0x4c]))return _0x51f2b1([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x38e37c=_0x4cf363(),!_0x38e37c)return _0x51f2b1([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x38e37c[_0x51f2b1([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x20a63f=_0x40bf1a(_0x38e37c[_0x51f2b1([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x38e37c[_0x51f2b1([0x6a,0x74,0x69])])),await _0x417e79()?_0x1a8ed7()?_0x4d3bed()?_0x51f2b1([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x39e1f6()?(_0x38e37c[_0x51f2b1([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x51f2b1([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x8ec9f4=_0x286104(_0x51f2b1([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x38e37c[_0x51f2b1([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x51f2b1([0x74,0x72,0x69,0x61,0x6c])&&(_0x8ec9f4=_0x286104(_0x51f2b1([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),await _0x349c0d()):_0x51f2b1([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x51f2b1([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x51f2b1([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch(_0x98006d){return _0x51f2b1([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x4d3bed(){const _0x3dc265=[_0x51f2b1([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x51f2b1([0x74,0x72,0x69,0x61,0x6c])][_0x51f2b1([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x38e37c[_0x51f2b1([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x654cda/0x3e8:0xe10*_0x5002da;return _0x38e37c[_0x51f2b1([0x65,0x78,0x70])]<_0x3dc265;}function _0x1a8ed7(){const _0x532cc3=_0x38e37c[_0x51f2b1([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x532cc3)return!0x1;if(_0x532cc3[_0x51f2b1([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x51f2b1([0x2a])))return!0x0;if(_0x532cc3[_0x51f2b1([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x51f2b1([0x52,0x48])))return!0x0;if(_0x532cc3[_0x51f2b1([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x51f2b1([0x52,0x52,0x48]))){if(_0x5bd01f())return!0x0;if(_0x3b1f16()||_0x2aaeb4())return!0x0;}return!0x1;}function _0x39e1f6(){const _0x47ef96=_0x38e37c[_0x51f2b1([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x47ef96||0x0==_0x47ef96[_0x51f2b1([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x1e9cbf}=new URL(window[_0x51f2b1([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x47ef96[_0x51f2b1([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x1e9cbf))return!0x0;const _0x183486=_0x1e9cbf[_0x51f2b1([0x73,0x70,0x6c,0x69,0x74])](_0x51f2b1([0x2e]));return _0x47ef96[_0x51f2b1([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x506d7c=>_0x506d7c[_0x51f2b1([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x51f2b1([0x2a])))[_0x51f2b1([0x6d,0x61,0x70])](_0x38d7c2=>_0x38d7c2[_0x51f2b1([0x73,0x70,0x6c,0x69,0x74])](_0x51f2b1([0x2e])))[_0x51f2b1([0x73,0x6f,0x6d,0x65])](_0x519dfc=>_0x183486[_0x51f2b1([0x65,0x76,0x65,0x72,0x79])]((_0x46577f,_0x31656d)=>_0x519dfc[_0x31656d]===_0x46577f||_0x519dfc[_0x31656d]===_0x51f2b1([0x2a])));}function _0x349c0d(){return _0x8ec9f4&&_0x20a63f?new window[(_0x51f2b1([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x52983b,_0x5c7a4f)=>{_0x8ec9f4[_0x51f2b1([0x74,0x68,0x65,0x6e])](_0x52983b,_0x5c7a4f),_0x20a63f[_0x51f2b1([0x74,0x68,0x65,0x6e])](_0x382154=>{_0x382154!=_0x51f2b1([0x56,0x61,0x6c,0x69,0x64])&&_0x52983b(_0x382154);},_0x5c7a4f);}):_0x8ec9f4||_0x20a63f||_0x51f2b1([0x56,0x61,0x6c,0x69,0x64]);}}function _0x40bf1a(_0x445a76,_0x24101b){return new window[(_0x51f2b1([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0xb29525=>{if(_0x5cbbdf())return _0xb29525(_0x51f2b1([0x56,0x61,0x6c,0x69,0x64]));_0x1caa1c(),_0x1b2a07[_0x51f2b1([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x51f2b1([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x3c991c=!0x1;const _0x1d6829=_0x3fbd15();function _0x46dabe(_0x388aba){return!!_0x388aba&&(typeof _0x388aba===_0x51f2b1([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x388aba===_0x51f2b1([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x388aba[_0x51f2b1([0x74,0x68,0x65,0x6e])]===_0x51f2b1([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x388aba[_0x51f2b1([0x63,0x61,0x74,0x63,0x68])]===_0x51f2b1([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x1b2871(_0x446a90){_0xe30ff8(_0x446a90)[_0x51f2b1([0x74,0x68,0x65,0x6e])](_0x226e4a=>{if(!_0x226e4a||_0x226e4a[_0x51f2b1([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x51f2b1([0x6f,0x6b]))return _0x51f2b1([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x3ff437(_0x4bbb5b(_0x1d6829+_0x24101b))!=_0x226e4a[_0x51f2b1([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x51f2b1([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x51f2b1([0x56,0x61,0x6c,0x69,0x64]);})[_0x51f2b1([0x74,0x68,0x65,0x6e])](_0x3845e7=>(_0x5d6cd7(),_0x3845e7),()=>{const _0xa3fea5=_0x1b05ae();return null==_0xa3fea5?(_0x5d6cd7(),_0x51f2b1([0x56,0x61,0x6c,0x69,0x64])):_0x51f2b1(_0x654cda-_0xa3fea5>(0x5769449a^_0x45c19a)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x51f2b1([0x74,0x68,0x65,0x6e])](_0xb29525)[_0x51f2b1([0x63,0x61,0x74,0x63,0x68])](()=>{_0xb29525(_0x51f2b1([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x504484=0x73532e1a^_0x45c19a;function _0x5d6cd7(){const _0xf9c249=_0x51f2b1([0x6c,0x6c,0x63,0x74,0x2d])+_0x3ff437(_0x4bbb5b(_0x445a76)),_0x5ecc95=_0x5d3e08(_0x3ff437(window[_0x51f2b1([0x4d,0x61,0x74,0x68])][_0x51f2b1([0x63,0x65,0x69,0x6c])](_0x654cda/_0x504484)));window[_0x51f2b1([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x51f2b1([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0xf9c249,_0x5ecc95);}function _0x1b05ae(){const _0x5df0fe=_0x51f2b1([0x6c,0x6c,0x63,0x74,0x2d])+_0x3ff437(_0x4bbb5b(_0x445a76)),_0x2f32b3=window[_0x51f2b1([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x51f2b1([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x5df0fe);return _0x2f32b3?window[_0x51f2b1([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x5d3e08(_0x2f32b3),0x10)*_0x504484:null;}function _0xe30ff8(_0x54656f){return new window[(_0x51f2b1([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x1a1315,_0x57541f)=>{_0x54656f[_0x51f2b1([0x74,0x68,0x65,0x6e])](_0x1a1315,_0x57541f),window[_0x51f2b1([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x57541f,0x7364145a^_0x45c19a);});}}_0x1b2a07[_0x51f2b1([0x6f,0x6e])](_0x51f2b1([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x24bb5a,_0xc66c77)=>{if(_0xc66c77[0x0]!=_0x445a76)return _0xb29525(_0x51f2b1([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0xc66c77[0x1]={..._0xc66c77[0x1],[_0x51f2b1([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x1d6829};},{[_0x51f2b1([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x51f2b1([0x68,0x69,0x67,0x68])}),_0x1b2a07[_0x51f2b1([0x6f,0x6e])](_0x51f2b1([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x238491=>{_0x46dabe(_0x238491[_0x51f2b1([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x3c991c=!0x0,_0x1b2871(_0x238491[_0x51f2b1([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x51f2b1([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x51f2b1([0x6c,0x6f,0x77])}),_0x39bbdc[_0x51f2b1([0x74,0x68,0x65,0x6e])](()=>{_0x3c991c||_0xb29525(_0x51f2b1([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x5cbbdf(){return _0x1b2a07[_0x51f2b1([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x51f2b1([0x76,0x69,0x65,0x77])][_0x51f2b1([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x51f2b1([0x61,0x75,0x74,0x6f]);}function _0x1caa1c(){_0x1b2a07[_0x51f2b1([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x51f2b1([0x76,0x69,0x65,0x77])][_0x51f2b1([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x51f2b1([0x61,0x75,0x74,0x6f]);}}function _0x286104(_0x2aad67){const _0x25254f=[new window[(_0x51f2b1([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x551a04=>setTimeout(_0x551a04,0x736cfe56^_0x45c19a)),_0x39bbdc[_0x51f2b1([0x74,0x68,0x65,0x6e])](()=>new window[(_0x51f2b1([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x360da6=>{const _0x221d90=0x7365c09d^_0x45c19a,_0x136ee0=_0x4ef661[_0x51f2b1([0x5f,0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x73])];function _0x2262c8(){_0x136ee0[_0x51f2b1([0x6c,0x65,0x6e,0x67,0x74,0x68])]>=_0x221d90&&_0x360da6();}_0x2262c8(),_0x136ee0[_0x51f2b1([0x6f,0x6e])](_0x51f2b1([0x61,0x64,0x64]),_0x2262c8);})),new window[(_0x51f2b1([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x5438a8=>{function _0x570f42(){for(const _0x58530a in window)if(window[_0x51f2b1([0x4e,0x75,0x6d,0x62,0x65,0x72])]['isNaN'](window[_0x51f2b1([0x4e,0x75,0x6d,0x62,0x65,0x72])](_0x58530a))&&window[_0x58530a]==_0x5b391a)return _0x5438a8();_0x1b2a07[_0x51f2b1([0x73,0x74,0x61,0x74,0x65])]!=_0x51f2b1([0x64,0x65,0x73,0x74,0x72,0x6f,0x79,0x65,0x64])&&window[_0x51f2b1([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x570f42,0x7365d312^_0x45c19a);}_0x293ffe(_0x51f2b1([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))&&_0x570f42();})];return window[_0x51f2b1([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x51f2b1([0x72,0x61,0x63,0x65])](_0x25254f)[_0x51f2b1([0x74,0x68,0x65,0x6e])](()=>_0x2aad67);}async function _0x2a7b68(){if(await _0x39bbdc,_0x293ffe(_0x51f2b1([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))){const _0x13de35=_0x4ef661[_0x51f2b1([0x67,0x65,0x74,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](0x0),_0x328cfa=_0x4ef661[_0x51f2b1([0x67,0x65,0x74,0x45,0x61,0x72,0x6c,0x69,0x65,0x72,0x56,0x69,0x73,0x69,0x62,0x6c,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](_0x13de35[_0x51f2b1([0x69,0x64])]),_0x38b9fc=_0x482090(_0x51f2b1([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]));return await _0x38b9fc[_0x51f2b1([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])](_0x13de35['id'],_0x328cfa?_0x328cfa['id']:null,!0x0),_0x38b9fc[_0x51f2b1([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x51f2b1([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x38b9fc[_0x51f2b1([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x38b9fc[_0x51f2b1([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])]=_0x41f2bd,void(_0x38b9fc[_0x51f2b1([0x5f,0x67,0x65,0x74,0x44,0x69,0x66,0x66])]=_0x41f2bd);}if(_0x293ffe(_0x51f2b1([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]))){const _0x325afe=_0x482090(_0x51f2b1([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]));_0x325afe[_0x51f2b1([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x51f2b1([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x325afe[_0x51f2b1([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x325afe[_0x51f2b1([0x75,0x70,0x64,0x61,0x74,0x65])]=_0x41f2bd,_0x325afe[_0x51f2b1([0x73,0x61,0x76,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])]=_0x41f2bd;}_0x1b2a07[_0x51f2b1([0x6d,0x6f,0x64,0x65,0x6c])][_0x51f2b1([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x41f2bd,_0x1b2a07[_0x51f2b1([0x6d,0x6f,0x64,0x65,0x6c])][_0x51f2b1([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x41f2bd,_0x1b2a07[_0x51f2b1([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x51f2b1([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x5bd01f(){return _0x293ffe(_0x51f2b1([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x482090(_0x51f2b1([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x51f2b1([0x73,0x74,0x61,0x74,0x65])]==_0x51f2b1([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x3b1f16(){return _0x293ffe(_0x51f2b1([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72,0x49,0x6e,0x74,0x65,0x67,0x72,0x61,0x74,0x69,0x6f,0x6e]));}function _0x2aaeb4(){return _0x293ffe(_0x51f2b1([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0xd3cce5(_0x280566){const _0x7f8db5=_0x5489ae();_0x1b2a07[_0x7f8db5]=_0x51f2b1([0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x48,0x69,0x73,0x74,0x6f,0x72,0x79,0x4c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79])+_0x280566,_0x280566[_0x51f2b1([0x65,0x6e,0x64,0x73,0x57,0x69,0x74,0x68])](_0x51f2b1([0x4c,0x69,0x6d,0x69,0x74]))&&(window[_0x5489ae()]=_0x5b391a),_0x280566!=_0x51f2b1([0x56,0x61,0x6c,0x69,0x64])&&_0x2a7b68();}function _0x5489ae(){const _0xd158aa=window[_0x51f2b1([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x51f2b1([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x51f2b1([0x6e,0x6f,0x77])]())[_0x51f2b1([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x51f2b1([0x2e]),'');let _0x41c972=_0x51f2b1([0x73]);for(let _0x66d05d=0x0;_0x66d05d<_0xd158aa[_0x51f2b1([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x66d05d+=0x2){let _0x10dbfe=window[_0x51f2b1([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0xd158aa[_0x51f2b1([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x66d05d,_0x66d05d+0x2));_0x10dbfe>=_0x5df1b6[_0x51f2b1([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x10dbfe-=_0x5df1b6[_0x51f2b1([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x41c972+=_0x5df1b6[_0x10dbfe];}return _0x41c972;}function _0x4cf363(){const _0x3d2af9=_0x2498ad[_0x51f2b1([0x73,0x70,0x6c,0x69,0x74])](_0x51f2b1([0x2e]));if(0x3!=_0x3d2af9[_0x51f2b1([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x3536c6(_0x3d2af9[0x1]);function _0x3536c6(_0x361062){const _0x2175d2=_0x137c66(_0x361062);return _0x2175d2&&_0x28db53()?_0x2175d2:null;function _0x28db53(){const _0x1542a0=_0x2175d2[_0x51f2b1([0x6a,0x74,0x69])],_0x2504ab=window[_0x51f2b1([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x1542a0[_0x51f2b1([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x1542a0[_0x51f2b1([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x3499ee={..._0x2175d2,[_0x51f2b1([0x6a,0x74,0x69])]:_0x1542a0[_0x51f2b1([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x1542a0[_0x51f2b1([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x3499ee[_0x51f2b1([0x76,0x63])],_0x4bbb5b(_0x3499ee)==_0x2504ab;}}}async function _0x417e79(){let _0x411351=!0x0;try{const _0x5669a9=_0x2498ad[_0x51f2b1([0x73,0x70,0x6c,0x69,0x74])](_0x51f2b1([0x2e])),[_0xda09d0,_0x4ad727,_0xd08719]=_0x5669a9;return _0x2c571f(_0xda09d0),await _0x236d9c(_0xda09d0,_0x4ad727,_0xd08719),_0x411351;}catch(_0x2bd910){return!0x1;}function _0x2c571f(_0x111b96){const _0x4d8686=_0x137c66(_0x111b96);_0x4d8686&&_0x4d8686[_0x51f2b1([0x61,0x6c,0x67])]==_0x51f2b1([0x45,0x53,0x32,0x35,0x36])||(_0x411351=!0x1);}async function _0x236d9c(_0x30247b,_0x2b0839,_0x11d473){const _0x558031=window[_0x51f2b1([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x51f2b1([0x66,0x72,0x6f,0x6d])](_0x56f392(_0x11d473),_0x54f835=>_0x54f835[_0x51f2b1([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x49d25a=new window[(_0x51f2b1([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x51f2b1([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x30247b+_0x51f2b1([0x2e])+_0x2b0839),_0x82d333=window[_0x51f2b1([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x51f2b1([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x82d333)return;const _0x2b4eb8=await _0x82d333[_0x51f2b1([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x51f2b1([0x6a,0x77,0x6b]),_0x502c7b,{[_0x51f2b1([0x6e,0x61,0x6d,0x65])]:_0x51f2b1([0x45,0x43,0x44,0x53,0x41]),[_0x51f2b1([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x51f2b1([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x51f2b1([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x82d333[_0x51f2b1([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x51f2b1([0x6e,0x61,0x6d,0x65])]:_0x51f2b1([0x45,0x43,0x44,0x53,0x41]),[_0x51f2b1([0x68,0x61,0x73,0x68])]:{[_0x51f2b1([0x6e,0x61,0x6d,0x65])]:_0x51f2b1([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x2b4eb8,_0x558031,_0x49d25a)||(_0x411351=!0x1);}}function _0x137c66(_0x2a121d){return _0x2a121d[_0x51f2b1([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x51f2b1([0x65,0x79]))?JSON[_0x51f2b1([0x70,0x61,0x72,0x73,0x65])](_0x56f392(_0x2a121d)):null;}function _0x56f392(_0x1a4bc0){return window[_0x51f2b1([0x61,0x74,0x6f,0x62])](_0x1a4bc0[_0x51f2b1([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x51f2b1([0x2b]))[_0x51f2b1([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x51f2b1([0x2f])));}function _0x4bbb5b(_0x376dfa){let _0x384c4b=0x1505;function _0x2c435d(_0x449629){for(let _0xd15ab8=0x0;_0xd15ab8<_0x449629[_0x51f2b1([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0xd15ab8++){const _0x1bae11=_0x449629[_0x51f2b1([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0xd15ab8);_0x384c4b=(_0x384c4b<<0x5)+_0x384c4b+_0x1bae11,_0x384c4b&=_0x384c4b;}}function _0x58aa85(_0x1b168f){Array[_0x51f2b1([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x1b168f)?_0x1b168f[_0x51f2b1([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x58aa85):_0x1b168f&&typeof _0x1b168f==_0x51f2b1([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x51f2b1([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x1b168f)[_0x51f2b1([0x73,0x6f,0x72,0x74])]()[_0x51f2b1([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x1e429e,_0x35c472])=>{_0x2c435d(_0x1e429e),_0x58aa85(_0x35c472);}):_0x2c435d(window[_0x51f2b1([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x1b168f));}return _0x58aa85(_0x376dfa),_0x384c4b>>>0x0;}function _0x3ff437(_0x271735){return _0x271735[_0x51f2b1([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x51f2b1([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x51f2b1([0x30]));}function _0x5d3e08(_0x4269b7){return _0x4269b7[_0x51f2b1([0x73,0x70,0x6c,0x69,0x74])]('')[_0x51f2b1([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x51f2b1([0x6a,0x6f,0x69,0x6e])]('');}function _0x293ffe(_0xe522d5){return _0x1b2a07[_0x51f2b1([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x51f2b1([0x68,0x61,0x73])](_0xe522d5);}function _0x482090(_0x27b884){return _0x1b2a07[_0x51f2b1([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x51f2b1([0x67,0x65,0x74])](_0x27b884);}function _0x41f2bd(){}function _0x51f2b1(_0x1f662d){return _0x1f662d['map'](_0x50d46c=>String['fromCharCode'](_0x50d46c))['join']('');}_0xd3cce5(await _0x551e46());}(this);}['createRevision'](_0x14267c){const _0x251aff=this['editor']['plugins']['get']('Users');return new h({'id':_0x14267c['id'],'name':_0x14267c['name'],'creator':_0x14267c['creatorId']?_0x251aff['getUser'](_0x14267c['creatorId']):null,'diffData':_0x14267c['diffData']||_0x14267c['data'],'authors':_0x14267c['authorsIds']['map'](_0x13665c=>_0x251aff['getUser'](_0x13665c)),'createdAt':new Date(_0x14267c['createdAt']),'attributes':_0x14267c['attributes'],'fromVersion':_0x14267c['fromVersion'],'toVersion':_0x14267c['toVersion']});}['addRevision'](_0x39327d,_0x5c7f98=0x0){this['_revisions']['add'](_0x39327d,_0x5c7f98);}['getRevision'](_0x3b6f4e){return this['_revisions']['get'](_0x3b6f4e);}['getRevisions'](_0x3590e0={'toJSON':!0x1}){const _0x9e879c=Array['from'](this['_revisions']);return _0x9e879c['reverse'](),_0x3590e0['toJSON']?_0x9e879c['map'](_0x107706=>_0x107706['toJSON']()):_0x9e879c;}['getIndex'](_0x31c40a){return this['_revisions']['getIndex'](_0x31c40a);}['getEarlierVisibleRevision'](_0x9ef759){const [,_0x20f054]=this['getRevisionsIterator'](_0x9ef759,{'direction':'earlier'});return _0x20f054;}['getLaterVisibleRevision'](_0x1b0fd8){const [,_0x211040]=this['getRevisionsIterator'](_0x1b0fd8,{'direction':'later'});return _0x211040;}['getRevisionsInDiff'](_0x552f58){const _0x5459f8=[];for(const _0x26b3a6 of this['getRevisionsIterator'](_0x552f58['newRevisionId']))if(_0x5459f8['push'](_0x26b3a6),_0x26b3a6['id']===_0x552f58['oldRevisionId'])break;return _0x5459f8;}*['getRevisionsIterator'](_0x28eee1,{direction:_0x2bf7bb='earlier',filter:_0x4fbdb2=()=>!0x0}={}){const _0x54e0a8='earlier'===_0x2bf7bb?0x1:-0x1;let _0x535a7f=this['_revisions']['get'](_0x28eee1),_0x20ceaa=this['getIndex'](_0x535a7f);for(yield _0x535a7f;_0x535a7f;){if(_0x20ceaa+=_0x54e0a8,_0x535a7f=this['getRevision'](_0x20ceaa),!_0x535a7f)return;_0x4fbdb2(_0x535a7f)&&(yield _0x535a7f);}}}class V extends _0x1aaf30{static get['pluginName'](){return'RevisionHistoryUtils';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['_viewClassToTypeChar']=new Map([[_0x1586d5,'c'],[_0x4a6f92,'a'],[_0x35f70c,'e'],[_0x34d858,'r'],[_0x5e89db,'u']]);['_typeCharToViewClass']=new Map([['c',_0x1586d5],['a',_0x4a6f92],['e',_0x35f70c],['r',_0x34d858],['u',_0x5e89db]]);async['loadRevisionData'](_0xbf547e,_0x5b8d31){if(_0xbf547e['diffData']||!_0x5b8d31)return;const _0x73e5e2=this['editor']['config']['get']('collaboration.channelId'),_0x5e3e32=await _0x5b8d31['getRevision']({'channelId':_0x73e5e2,'revisionId':_0xbf547e['id']});_0xbf547e['diffData']=_0x5e3e32['diffData'];}['getRevisionDocumentData'](_0x2a00e0){const _0x17019e={};for(const _0x45c5e3 in _0x2a00e0['diffData']){if(_0x2a00e0['diffData'][_0x45c5e3]['attachChange']&&!_0x2a00e0['diffData'][_0x45c5e3]['attachChange']['isAttached'])continue;const _0x139e91=this['_removeRevisionMarkers'](JSON['parse'](_0x2a00e0['diffData'][_0x45c5e3]['insertions'])),_0x1e0493=this['editor']['editing']['view']['document'],_0x1f92db=new _0x12361a(_0x1e0493,_0x139e91['map'](_0x584d6c=>this['_getViewFromDiffObj'](_0x584d6c,!0x1)));this['editor']['data']['processor']['useFillerType']('marked'),_0x17019e[_0x45c5e3]=this['editor']['data']['processor']['toData'](_0x1f92db),this['editor']['data']['processor']['useFillerType']('default');}return _0x17019e;}['getRevisionRootsAttributes'](_0x328120){const _0x3c7015={};for(const _0x32948d in _0x328120['diffData'])_0x328120['diffData'][_0x32948d]['attachChange']&&!_0x328120['diffData'][_0x32948d]['attachChange']['isAttached']||(_0x3c7015[_0x32948d]=_0x328120['diffData'][_0x32948d]['attributesAfter']||{});return _0x3c7015;}['_getTypeCharForViewElement'](_0x114257){return this['_viewClassToTypeChar']['get'](_0x114257['constructor']);}['_getViewFromDiffObj'](_0x1c75a7,_0x343c61){const _0xbc7487=this['editor']['editing']['view']['document'];if('string'==typeof _0x1c75a7)return new _0x3f0c02(_0xbc7487,_0x1c75a7);{let _0x6e7ddc,_0x6341ee;_0x6341ee='u'==_0x1c75a7['type']||'r'==_0x1c75a7['type']?[]:_0x1c75a7['children']['map'](_0x55e0eb=>this['_getViewFromDiffObj'](_0x55e0eb,_0x343c61));const _0x5bf317=this['_typeCharToViewClass']['get'](_0x1c75a7['type'])||_0x360a86,_0x1ca152=this['editor']['data']['htmlProcessor']['domConverter'];if(_0x6e7ddc=new _0x5bf317(_0xbc7487,_0x1c75a7['name'],_0x1c75a7['attributes'],_0x6341ee),'u'==_0x1c75a7['type']&&_0x1c75a7['children'][0x0]){const _0x2333b7=_0x1c75a7['children'][0x0];if(_0x6e7ddc['render']=function(_0x2be9ad){const _0xe1c7c0=_0x2be9ad['createElement']('div');return _0xe1c7c0['innerHTML']=_0x2333b7,_0xe1c7c0['childNodes'][0x0];},_0x343c61){const _0xf308fb=new _0x12361a(_0xbc7487);_0xf308fb['_appendChild'](_0x6e7ddc);const _0x39357d=Array['from'](_0x1ca152['viewChildrenToDom'](_0xf308fb,{'bind':!0x1})),_0x417d33=_0x1ca152['domDocument']['createElement']('div');_0x417d33['append'](..._0x39357d),_0x6e7ddc=Array['from'](_0x1ca152['domChildrenToView'](_0x417d33))[0x0];}}else{if('r'==_0x1c75a7['type']&&_0x1c75a7['children'][0x0]){const _0x5c0074=_0x1c75a7['children'][0x0];if(_0x6e7ddc['render']=function(_0x201e61){_0x201e61['innerHTML']=_0x5c0074;},_0x343c61){const _0x619a76=new _0x12361a(_0xbc7487);_0x619a76['_appendChild'](_0x6e7ddc);const _0x52a3=Array['from'](_0x1ca152['viewChildrenToDom'](_0x619a76,{'bind':!0x1})),_0x14ad5a=_0x1ca152['domDocument']['createElement']('div');_0x14ad5a['append'](..._0x52a3);const _0x58cbc2=Array['from'](_0x1ca152['domChildrenToView'](_0x14ad5a));_0x58cbc2['length']>0x1?_0x6e7ddc['_appendChild'](_0x58cbc2):_0x6e7ddc=_0x58cbc2[0x0];}}}if(_0x1c75a7['customProperties']){for(const [_0x38b630,_0x453e46]of _0x1c75a7['customProperties'])_0x6e7ddc['_setCustomProperty'](_0x38b630,_0x453e46);}const _0x1375d4=void 0x0===_0x1c75a7['fillerOffset']?null:_0x1c75a7['fillerOffset'];return null!==_0x1375d4&&(_0x6e7ddc['getFillerOffset']=()=>_0x1375d4),_0x6e7ddc;}}['_makeModelFromViewString'](_0x531313){const _0x4a4102=JSON['parse'](_0x531313),_0x246d7c=this['editor']['editing']['view']['document'],_0x48f2d4=new _0x12361a(_0x246d7c,_0x4a4102['map'](_0x4605b6=>this['_getViewFromDiffObj'](_0x4605b6,!0x0)));return this['editor']['data']['toModel'](_0x48f2d4);}['_removeRevisionMarkers'](_0x470195){return(_0x470195=_0x470195['filter'](_0x1b9d3b=>!_0x1b9d3b['name']||'revision-start'!==_0x1b9d3b['name']&&'revision-end'!==_0x1b9d3b['name']))['forEach'](_0x40b808=>{'string'!=typeof _0x40b808&&(_0x40b808['children']=this['_removeRevisionMarkers'](_0x40b808['children']),_0x40b808['attributes']=_0x40b808['attributes']['filter'](_0x16189d=>!_0x16189d[0x0]['startsWith']('data-revision-')));}),_0x470195;}}function g(_0x463d59,_0x16ea78,_0x1597ab){const t=_0x463d59['t'];switch(_0x16ea78){case'Revision\x20history':return t('Revision\x20history');case'Open\x20revision\x20history':return t('Open\x20revision\x20history');case'Restored':return t('Restored');case'Empty\x20document':return t('Empty\x20document');case'Initial\x20revision':return t('Initial\x20revision');case'Suggested\x20by':return t('Suggested\x20by');case'Added\x20by':return t('Added\x20by');case'Removed\x20by':return t('Removed\x20by');case'Show\x20more\x20items':return t('Show\x20more\x20items');case'Compare\x20against\x20selected':return t('Compare\x20against\x20selected');case'Name\x20this\x20revision':return t('Name\x20this\x20revision');case'Restore\x20this\x20revision':return t('Restore\x20this\x20revision');case'Back\x20to\x20editing':return t('Back\x20to\x20editing');case'Loading...':return t('Loading...');case'No\x20changes':return t('No\x20changes');case'NUMBER_OF_CHANGES':return t({'string':'%0\x20change','plural':'%0\x20changes','id':'NUMBER_OF_CHANGES'},_0x1597ab);case'X_OF_Y_CHANGES':return t({'string':'%0\x20of\x20%1','id':'X_OF_Y_CHANGES'},_0x1597ab);case'Show\x20previous\x20change':return t('Show\x20previous\x20change');case'Show\x20next\x20change':return t('Show\x20next\x20change');case'EDIT_X_OF_Y_REVISIONS':return t({'string':'Edit','id':'EDIT_X_OF_Y_REVISIONS'});case'Total':return t('Total');case'Revision\x20creator':return t('Revision\x20creator');case'Revision\x20author':return t('Revision\x20author');case'Revision\x20name':return t('Revision\x20name');case'Save\x20current\x20revision':return t('Save\x20current\x20revision');case'Accept':return t('Accept');case'Save':return t('Save');case'Cancel':return t('Cancel');case'Name\x20of\x20the\x20revision':return t('Name\x20of\x20the\x20revision');case'optional':return t('optional');case'PENDING_ACTION_REVISION_HISTORY':return t({'string':'Unsaved\x20change\x20in\x20revision\x20history.','id':'PENDING_ACTION_REVISION_HISTORY'});case'The\x20revision\x20name\x20cannot\x20be\x20empty.':return t('The\x20revision\x20name\x20cannot\x20be\x20empty.');case'Enter\x20the\x20revision\x20name':return t('Enter\x20the\x20revision\x20name');default:return'';}}class u extends _0x1aaf30{['licenseKey'];['_licenseKeyCheckInterval'];['currentRevision']=null;['repository'];['adapter']=null;['_revisionDataBuilder'];['_source'];['_initialRevisionId'];['_bufferedUpdates'];['_utils'];['_pendingAction'];['_continueCurrentRevision'];['_startingVersion'];['_loadedStateData'];static get['pluginName'](){return'RevisionTracker';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[_0x25ff19,I,V,_0x3cbd42];}constructor(_0x45e93d){super(_0x45e93d),this['repository']=this['editor']['plugins']['get']('RevisionsRepository'),this['_utils']=this['editor']['plugins']['get']('RevisionHistoryUtils'),this['_revisionDataBuilder']=new x(this['editor']),this['_initialRevisionId']=this['editor']['config']['get']('collaboration.channelId')||'initial',this['_bufferedUpdates']=new Map(),this['_loadedStateData']=null;const _0x1a67d1=_0x3fbd15();this['_source']={'history':this['editor']['model']['document']['history'],'getLatestVersion':()=>Promise['resolve'](this['editor']['model']['document']['version']),'getCurrentRevisionId':()=>_0x1a67d1},this['set']('isReady',!0x1),this['set']('isEnabled',!0x0),this['set']('_isPendingUpdate',!0x1),this['editor']['config']['define']('revisionHistory.resumeUnsavedRevision',!0x0),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'});}['init'](){this['_setConversion'](),this['editor']['data']['on']('ready',()=>{const _0xd1bf6e=this['repository']['getRevision'](0x0),_0x13b6b9=_0xd1bf6e&&null===_0xd1bf6e['creator']?_0xd1bf6e:null;if(this['_continueCurrentRevision']=!!_0x13b6b9&&this['editor']['config']['get']('revisionHistory.resumeUnsavedRevision'),this['editor']['plugins']['has']('RealTimeCollaborationClient')){const _0x741d98=this['_source']['getCurrentRevisionId'](),_0x28a65a=this['repository']['getRevision'](_0x741d98);if(_0x28a65a)this['_startingVersion']=_0x28a65a['fromVersion'],this['_continueCurrentRevision']=!0x1;else{const _0x18cfcc=this['_source']['history']['_operations']['find'](_0x271bbe=>!_0x271bbe['_isInit']),_0x1cda93=_0x18cfcc?_0x18cfcc['baseVersion']:this['_source']['history']['version'];_0xd1bf6e?(_0xd1bf6e['toVersion']<_0x1cda93&&_0xd1bf6e['_update']({'toVersion':_0x1cda93}),this['_continueCurrentRevision']?(this['_source']['getCurrentRevisionId']=()=>_0x13b6b9['id'],this['_startingVersion']=_0x13b6b9['fromVersion']):(this['_startingVersion']=_0xd1bf6e['toVersion'],this['_continueCurrentRevision']=!0x1)):(this['_startingVersion']=_0x1cda93,this['_continueCurrentRevision']=!0x1);}}else _0x13b6b9&&(this['editor']['model']['document']['history']['version']=Math['max'](_0x13b6b9['toVersion'],this['editor']['model']['document']['history']['version']),_0x13b6b9['fromVersion']===_0x13b6b9['toVersion']?(0x0!==_0x13b6b9['fromVersion']&&(this['_source']['getCurrentRevisionId']=()=>_0x13b6b9['id']),this['_continueCurrentRevision']=!0x1):this['_continueCurrentRevision']&&(this['_source']['getCurrentRevisionId']=()=>_0x13b6b9['id'],this['_startingVersion']=_0x13b6b9['fromVersion'])),this['_continueCurrentRevision']||(this['_startingVersion']=this['editor']['model']['document']['version']);this['_revisionDataBuilder']['init'](this['_source']['history']),this['_createInitialRevision'](this['_startingVersion']),this['_createCurrentRevision'](this['_startingVersion']),this['adapter']&&this['sendBufferedUpdates']();}),this['bind']('isReady')['to'](this,'_isPendingUpdate',_0x5da19c=>!_0x5da19c),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0xa38073=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x1e2ea8;for(const _0x244deb in _0xa38073){const _0xce2f92=_0x244deb,_0x51ab2c=_0xa38073[_0xce2f92];if('revisionHistoryLicenseKeyValid'==_0x51ab2c||'revisionHistoryLicenseKeyInvalid'==_0x51ab2c||'revisionHistoryLicenseKeyExpired'==_0x51ab2c||'revisionHistoryLicenseKeyDomainLimit'==_0x51ab2c||'revisionHistoryLicenseKeyNotAllowed'==_0x51ab2c||'revisionHistoryLicenseKeyEvaluationLimit'==_0x51ab2c||'revisionHistoryLicenseKeyTrialLimit'==_0x51ab2c||'revisionHistoryLicenseKeyUsageLimit'==_0x51ab2c){delete _0xa38073[_0xce2f92],_0x1e2ea8=_0x51ab2c,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'revisionHistoryLicenseKeyInvalid'==_0x1e2ea8&&_0xa38073['_showLicenseError']('invalid'),'revisionHistoryLicenseKeyExpired'==_0x1e2ea8&&_0xa38073['_showLicenseError']('expired'),'revisionHistoryLicenseKeyDomainLimit'==_0x1e2ea8&&_0xa38073['_showLicenseError']('domainLimit'),'revisionHistoryLicenseKeyNotAllowed'==_0x1e2ea8&&_0xa38073['_showLicenseError']('featureNotAllowed','RevisionHistory'),'revisionHistoryLicenseKeyEvaluationLimit'==_0x1e2ea8&&_0xa38073['_showLicenseError']('evaluationLimit'),'revisionHistoryLicenseKeyTrialLimit'==_0x1e2ea8&&_0xa38073['_showLicenseError']('trialLimit'),'revisionHistoryLicenseKeyUsageLimit'==_0x1e2ea8&&_0xa38073['_showLicenseError']('usageLimit');},0x3e8);}async['afterInit'](){if(this['repository']['length']>0x0){const _0x20d99e=this['repository']['getRevision'](0x0),_0x5a4cbb=await this['getRevisionDocumentData'](_0x20d99e),_0x13c9a8=await this['getRevisionRootsAttributes'](_0x20d99e);this['_replaceEditorDataWithRevisionData'](_0x5a4cbb,_0x13c9a8);}}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['setSource'](_0x4af9a9){this['_source']=_0x4af9a9;}async['update'](){const _0x4c2a68=await this['_source']['getLatestVersion']();if(_0x4c2a68>this['currentRevision']['toVersion']){await this['_loadState']();const _0x214270=this['buildRevisionData']({'revision':this['currentRevision'],'to':_0x4c2a68});_0x214270['authors']=_0x214270['authorsIds']['map'](_0x1fba76=>this['editor']['plugins']['get']('Users')['getUser'](_0x1fba76)),this['currentRevision']['_update'](_0x214270);}}async['saveRevision'](_0x5d42a6={},_0x5487ee=null){const _0x5a90fc=[];await this['_loadState'](),this['_continueCurrentRevision']=!0x1,_0x5487ee>this['currentRevision']['toVersion']&&(_0x5487ee=null),null===_0x5487ee&&(_0x5487ee=await this['_source']['getLatestVersion']());const _0x474607=this['_getFromVersion'](_0x5487ee),_0x1e4b14=this['buildRevisionData']({'from':_0x474607,'to':_0x5487ee});if(this['currentRevision']['toVersion']<_0x5487ee){const _0x470aa2=this['buildRevisionData']({'revision':this['currentRevision'],'from':_0x5487ee,'to':_0x5487ee});_0x470aa2['authors']=[],_0x470aa2['authorsIds']=[],_0x470aa2['id']=this['currentRevision']['id'],this['currentRevision']['_update'](_0x470aa2,!0x0),delete _0x470aa2['authors'],_0x5a90fc['push'](_0x470aa2);}_0x5d42a6['creatorId']=this['editor']['plugins']['get']('Users')['me']['id'],_0x5d42a6['name']=_0x5d42a6['name']||null,_0x5d42a6['id']=_0x5d42a6['id']||_0x3fbd15(),_0x5d42a6={..._0x5d42a6,..._0x1e4b14};const _0x49f692=this['addRevisionData'](_0x5d42a6);_0x5a90fc['push'](_0x5d42a6);const _0x5161e0=this['repository']['getIndex'](_0x49f692);if(0x0!==_0x5161e0){const _0x19fac2=this['repository']['getRevision'](_0x5161e0-0x1);if(_0x19fac2['fromVersion']!==_0x5487ee){const _0x336ecf=this['_revisionDataBuilder']['getData'](_0x5487ee,_0x19fac2['toVersion']),_0x1a943f={'id':_0x19fac2['id'],'diffData':_0x336ecf['diffData'],'authorsIds':_0x336ecf['authorsIds'],'authors':_0x336ecf['authorsIds']['map'](_0x1c35e5=>this['editor']['plugins']['get']('Users')['getUser'](_0x1c35e5)),'fromVersion':_0x5487ee};_0x19fac2===this['currentRevision']&&(_0x1a943f['createdAt']=new Date(_0x5d42a6['createdAt']['getTime']()+0xa)),_0x19fac2['_update'](_0x1a943f,!0x0),delete _0x1a943f['authors'],_0x5a90fc['push'](_0x1a943f);}}if(this['adapter']){for(const _0x4a071b of _0x5a90fc)this['_bufferUpdate'](_0x4a071b['id'],_0x4a071b,!0x0);this['sendBufferedUpdates']();}return _0x49f692;}['addRevisionData'](_0xba6b6e){const _0x244e29=this['repository']['createRevision'](_0xba6b6e);return this['adapter']&&_0x244e29['on']('_update',(_0x79d116,_0x3940af,_0x34666b)=>{_0x34666b||(this['_bufferUpdate'](_0x3940af['id'],_0x3940af,!0x0),this['sendBufferedUpdates']());}),this['repository']['addRevision'](_0x244e29,this['_findInsertionIndex'](_0x244e29)),_0x244e29;}async['getRevisionDocumentData'](_0x3f1b39){return await this['_utils']['loadRevisionData'](_0x3f1b39,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x3f1b39);}async['getRevisionRootsAttributes'](_0x19c7da){return await this['_utils']['loadRevisionData'](_0x19c7da,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x19c7da);}['sendBufferedUpdates'](){if(0x0===this['_bufferedUpdates']['size'])return;if(this['_isPendingUpdate'])return;let _0x571e33=Array['from'](this['_bufferedUpdates']['values']());this['_bufferedUpdates']['clear']();for(let _0x161a9b=0x0;_0x161a9b<_0x571e33['length'];_0x161a9b++){const _0x1c1856=_0x571e33[_0x161a9b];let _0x472181=!0x1;for(const _0xfbcfda of Object['keys'](_0x1c1856))void 0x0===_0x1c1856[_0xfbcfda]?delete _0x1c1856[_0xfbcfda]:'id'!==_0xfbcfda&&(_0x472181=!0x0);_0x472181||(_0x571e33[_0x161a9b]=null);}if(_0x571e33=_0x571e33['filter'](_0x3ab2c8=>null!==_0x3ab2c8),!_0x571e33['length'])return;for(let _0xc6020f=0x0;_0xc6020f<_0x571e33['length'];_0xc6020f++){const _0x4de886=_0x571e33[_0xc6020f];void 0x0!==_0x4de886['fromVersion']&&void 0x0===_0x4de886['toVersion']&&(_0x4de886['toVersion']=this['repository']['getRevision'](_0x4de886['id'])['toVersion']),void 0x0!==_0x4de886['toVersion']&&void 0x0===_0x4de886['fromVersion']&&(_0x4de886['fromVersion']=this['repository']['getRevision'](_0x4de886['id'])['fromVersion']);}const _0x238efc=this['editor']['config']['get']('collaboration.channelId');this['_isPendingUpdate']=!0x0,this['_addPendingAction'](),this['adapter']['updateRevisions'](_0x571e33,_0x238efc)['finally'](()=>{this['_isPendingUpdate']=!0x1;})['then'](_0xbff607=>{if(_0xbff607){for(const _0x21bee0 of _0xbff607)this['setRevisionData']({'id':_0x21bee0['id'],'createdAt':_0x21bee0['createdAt']});}this['_removePendingAction'](),this['sendBufferedUpdates']();});}['buildRevisionData']({revision:_0x1a9a73=null,from:_0xe2ff77=null,to:_0x3b86e4=null}){_0xe2ff77=null!==_0xe2ff77?_0xe2ff77:_0x1a9a73['fromVersion'],_0x3b86e4=null!==_0x3b86e4?_0x3b86e4:_0x1a9a73['toVersion'];const _0x2b09d3=this['_revisionDataBuilder']['getData'](_0xe2ff77,_0x3b86e4),_0x2e304e={'diffData':_0x2b09d3['diffData'],'authorsIds':_0x2b09d3['authorsIds'],'fromVersion':_0xe2ff77,'toVersion':_0x3b86e4};if(!_0x1a9a73||_0x3b86e4!==_0x1a9a73['toVersion']){const _0x253127=_0x3b86e4-0x1,_0x297e2c=this['_source']['history']['getOperation'](_0x253127);_0x2e304e['createdAt']=_0x297e2c&&_0x297e2c['createdAt']||new Date();}if(this['_loadedStateData']&&_0xe2ff77===this['_loadedStateData']['fromVersion']){for(const _0x58c49f of this['_loadedStateData']['authors'])_0x2e304e['authorsIds']['includes'](_0x58c49f['id'])||_0x2e304e['authorsIds']['push'](_0x58c49f['id']);}return _0x2e304e;}['_bufferUpdate'](_0x4cb3ab,_0x131bbf,_0x2e9dc1){if(this['_bufferedUpdates']['has'](_0x4cb3ab)){const _0x552285=this['_bufferedUpdates']['get'](_0x4cb3ab);_0x131bbf=_0x2e9dc1?{..._0x552285,..._0x131bbf}:{..._0x131bbf,..._0x552285};}this['_bufferedUpdates']['set'](_0x4cb3ab,_0x131bbf);}['setRevisionData'](_0x43c940){const _0x526061=this['repository']['getRevision'](_0x43c940['id']);if(_0x43c940['createdAt']&&(_0x43c940['createdAt']=new Date(_0x43c940['createdAt'])),_0x43c940['authorsIds']){const _0x14872c=this['editor']['plugins']['get']('Users');_0x43c940['authors']=_0x43c940['authorsIds']['map'](_0x7f39eb=>_0x14872c['getUser'](_0x7f39eb));}_0x526061['_update'](_0x43c940,!0x0);}['_createInitialRevision'](_0x2b5824){const _0x5a4763=this['repository']['getRevision'](this['repository']['length']-0x1);if(_0x5a4763)this['_initialRevisionId']=_0x5a4763['id'];else{const _0x1ac279=!this['editor']['model']['document']['roots']['find'](_0xc0f9df=>this['editor']['model']['hasContent'](_0xc0f9df)),_0x1ab466=this['editor']['plugins']['get']('Users')['me']['id'],_0x45bc78=g(this['editor']['locale'],_0x1ac279?'Empty\x20document':'Initial\x20revision');this['_makeRevision']({'from':_0x2b5824,'to':_0x2b5824,'id':this['_initialRevisionId'],'name':_0x45bc78,'creatorId':_0x1ab466});}}['_createCurrentRevision'](_0x12c3b0){const _0x609fbd=this['_source']['getCurrentRevisionId']();this['currentRevision']=this['repository']['getRevision'](_0x609fbd),this['currentRevision']||(this['currentRevision']=this['_makeRevision']({'from':_0x12c3b0,'to':_0x12c3b0,'id':_0x609fbd,'name':'','creatorId':null}));}async['_loadState'](){this['_continueCurrentRevision']&&!this['_loadedStateData']&&(await this['_utils']['loadRevisionData'](this['currentRevision'],this['adapter']),this['_revisionDataBuilder']['loadState'](this['currentRevision']),this['_loadedStateData']={'fromVersion':this['currentRevision']['fromVersion'],'authors':this['currentRevision']['authors']['slice']()});}['_replaceEditorDataWithRevisionData'](_0x1a05b6,_0xd90382){let _0x224bc4=this['editor']['config']['get']('initialData'),_0x4fd0cb=this['editor']['config']['get']('rootsAttributes');if(void 0x0===_0x224bc4){_0x224bc4={};for(const _0x7d4b3d of this['editor']['model']['document']['getRootNames']())_0x224bc4[_0x7d4b3d]='';}if('string'==typeof _0x224bc4&&(_0x224bc4={'main':_0x224bc4}),void 0x0===_0x4fd0cb){_0x4fd0cb={};for(const _0x5623d8 of this['editor']['model']['document']['getRootNames']())_0x4fd0cb[_0x5623d8]={};}let _0x5eb3d7=!0x1;const _0x5e9a16=Object['keys'](_0x224bc4),_0x363b4d=Object['keys'](_0x1a05b6);for(const _0x5a9814 of _0x5e9a16){if(_0x224bc4[_0x5a9814]!==_0x1a05b6[_0x5a9814]&&''!==_0x224bc4[_0x5a9814]['trim']()){_0x5eb3d7=!0x0;break;}if(!_0x34eb88(_0x4fd0cb[_0x5a9814],_0xd90382[_0x5a9814])&&Object['keys'](_0x4fd0cb[_0x5a9814])['length']>0x0){_0x5eb3d7=!0x0;break;}}_0x5eb3d7||(_0x5eb3d7=_0x363b4d['some'](_0x3f51db=>!this['editor']['model']['document']['getRoot'](_0x3f51db))),_0x5eb3d7&&_0x1ce756('editor-initial-data-replaced-with-revision-data',{'editorData':_0x224bc4,'editorRootsAttributes':_0x4fd0cb,'revisionData':_0x1a05b6,'revisionRootsAttributes':_0xd90382}),this['editor']['config']['set']('initialData',_0x1a05b6),this['editor']['config']['set']('rootsAttributes',_0xd90382);}['_addPendingAction'](){if(!this['_pendingAction']){const _0x4a4b02=this['editor']['plugins']['get']('PendingActions');this['_pendingAction']=_0x4a4b02['add'](g(this['editor']['locale'],'PENDING_ACTION_REVISION_HISTORY'));}}['_removePendingAction'](){this['_pendingAction']&&(this['editor']['plugins']['get']('PendingActions')['remove'](this['_pendingAction']),this['_pendingAction']=null);}['_findInsertionIndex'](_0x2e5fd0){const _0x47098f=this['repository']['getRevisions']();_0x47098f['reverse']();let _0xcb3461=0x0;for(;_0xcb3461<_0x47098f['length'];){const _0x3bdca4=_0x47098f[_0xcb3461];if(_0x3bdca4===this['currentRevision']){_0xcb3461++;continue;}if(_0x3bdca4['id']===this['_initialRevisionId'])break;const _0xaa1677=_0x2e5fd0['toVersion']-_0x3bdca4['toVersion']||_0x2e5fd0['fromVersion']-_0x3bdca4['fromVersion'];if(_0xaa1677>0x0)break;if(_0xaa1677<0x0)_0xcb3461++;else{if(!_0x2e5fd0['creator']&&_0x3bdca4['creator'])break;if(_0x3bdca4['creator']||!_0x2e5fd0['creator']){if(_0x2e5fd0['createdAt']>_0x3bdca4['createdAt'])break;_0xcb3461++;}else _0xcb3461++;}}return _0xcb3461;}['_getFromVersion'](_0x2729e1){const _0x56fc26=this['repository']['getRevisions']();_0x56fc26['reverse'](),_0x56fc26['shift']();const _0x54511c=_0x56fc26['find'](_0x1a94e9=>_0x1a94e9['toVersion']<=_0x2729e1)['toVersion'];return _0x54511c<this['_startingVersion']?this['_startingVersion']:_0x54511c;}['_makeRevision']({name:_0x46865d,from:_0x54763e,to:_0x34e5d0,creatorId:_0x32b559,id:_0x82cc8a}){const _0x2aca0c=this['buildRevisionData']({'from':_0x54763e,'to':_0x34e5d0});_0x2aca0c['name']=_0x46865d,_0x2aca0c['creatorId']=_0x32b559,_0x2aca0c['id']=_0x82cc8a;const _0x33f7f0=this['addRevisionData'](_0x2aca0c);return this['adapter']&&this['_bufferUpdate'](_0x2aca0c['id'],_0x2aca0c,!0x0),_0x33f7f0;}['_setConversion'](){this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'});}}class x{['editor'];['source'];['_savedMetaData'];['_lastFrom'];['_lastTo'];['_markers'];['_diffRoots'];['_diffRootsAttributes'];['_baseRoots'];['_baseRootsAttributes'];['_idsRoots'];['_baseIdsRoots'];['_touched'];['_touchedMarkers'];['_touchedRoots'];['_revisionId'];['_startingRevisionId'];constructor(_0x5653a8){this['editor']=_0x5653a8,this['_savedMetaData']=new Map(),this['_lastFrom']=-0x1,this['_lastTo']=-0x1,this['_markers']=new Map(),this['_diffRoots']=new Map(),this['_diffRootsAttributes']=new Map(),this['_baseRoots']=new Map(),this['_baseRootsAttributes']=new Map(),this['_idsRoots']=new Map(),this['_baseIdsRoots']=new Map(),this['_touched']=new Map(),this['_touchedMarkers']=new Map(),this['_touchedRoots']=new Map(),this['_revisionId']=0x1;}['init'](_0x26a4cf){this['source']=_0x26a4cf;const _0x4c13f9=new Map(),_0x403336=new Map(),_0x4538ae=this['editor']['model']['document']['roots']['map'](_0x4f9567=>_0x4f9567['rootName']);for(const _0x40f121 of _0x4538ae){const _0x1f358a=this['editor']['model']['document']['getRoot'](_0x40f121),_0x54cd8e=N(_0x1f358a);_0x4c13f9['set'](_0x40f121,_0x54cd8e),_0x403336['set'](_0x40f121,Object['fromEntries'](_0x1f358a['getAttributes']()));}const _0x4ce532=Array['from'](this['editor']['model']['markers'])['map'](_0x51e012=>[_0x51e012['name'],_0x51e012['getRange']()]),_0x263b27=this['source']['version'];this['_saveMetaData'](_0x263b27,_0x4c13f9,_0x4ce532,_0x403336),this['_startingRevisionId']=this['_revisionId'];const _0x66c03b=new Map(),_0x44c44b=new Map();for(const _0x1ca751 of _0x4538ae){const _0x5e0914=P(_0x1ca751);_0x66c03b['set'](_0x1ca751,_0x5e0914),_0x44c44b['set'](_0x1ca751,{});}this['_saveMetaData'](Number['NEGATIVE_INFINITY'],_0x66c03b,[],_0x44c44b);}['getData'](_0x38cbe0,_0x4bfbab){if(this['_lastFrom']===_0x38cbe0&&this['_lastTo']<=_0x4bfbab)this['_savedMetaData']['size']>0x1&&this['_removeMetaData'](this['_lastTo']),this['_applyOperations'](this['_lastTo'],_0x4bfbab,!0x0);else{if(!this['_savedMetaData']['has'](_0x38cbe0)){const _0x489cda=this['_getPreviousFrom'](_0x38cbe0);this['_calculateMetaData'](_0x489cda,_0x38cbe0,!0x1);}this['_calculateMetaData'](_0x38cbe0,_0x4bfbab,!0x0);}return this['_lastFrom']=_0x38cbe0,this['_lastTo']=_0x4bfbab,this['_getState']();}['loadState'](_0x2d10a4){const _0x44ecc3=this['editor']['plugins']['get']('RevisionHistoryUtils');this['_reset'](),this['_lastFrom']=_0x2d10a4['fromVersion'],this['_lastTo']=_0x2d10a4['toVersion'];for(const _0x6bd34 in _0x2d10a4['diffData']){const _0x1557bf=_0x2d10a4['diffData'][_0x6bd34]['attachChange'],_0x140515=_0x4dbdf7(_0x2d10a4['diffData'][_0x6bd34]['attributesBefore'])||{},_0x49dcba=_0x44ecc3['_makeModelFromViewString'](_0x2d10a4['diffData'][_0x6bd34]['deletions']);_0x49dcba['rootName']=_0x6bd34,_0x49dcba['_isAttached']=!_0x1557bf||!_0x1557bf['isAttached'],_0x49dcba['isAttached']=()=>_0x49dcba['_isAttached'],this['_baseRoots']['set'](_0x6bd34,_0x49dcba),this['_baseRootsAttributes']['set'](_0x6bd34,_0x140515),_0x1557bf&&this['_touchedRoots']['set'](_0x6bd34,_0x1557bf);const _0x983b5d=this['_makeIdsRoot'](_0x49dcba);this['_baseIdsRoots']['set'](_0x6bd34,_0x983b5d);for(const [_0x432e34,_0x254c05]of _0x49dcba['markers']){if(!_0x432e34['startsWith']('revision:'))continue;const _0x53a16a=_0x432e34['split'](':')[0x2];for(const _0x8174d9 of _0x254c05['getWalker']({'singleCharacters':!0x0})){const _0xa7a620=this['_getVidAttributeName'](_0x8174d9),_0x52cdf9='elementEnd'==_0x8174d9['type']?_0x8174d9['previousPosition']['path']['slice'](0x0,-0x1):_0x8174d9['previousPosition']['path'],_0x4acc31=_0x983b5d['getNodeByPath'](_0x52cdf9)['getAttribute'](_0xa7a620);this['_touched']['set'](_0x4acc31,{'userId':_0x53a16a});}}}this['_startingRevisionId']=this['_revisionId'];const _0x21f180=[...Array(this['_revisionId'])['keys']()]['slice'](0x1)['filter'](_0x4c1a6c=>!this['_touched']['has'](_0x4c1a6c));let _0x1038fe=0x0;const _0xddfab6=new Map();for(const _0x111429 in _0x2d10a4['diffData']){const _0x26b3f6=_0x2d10a4['diffData'][_0x111429]['attachChange'],_0x2bc310=_0x4dbdf7(_0x2d10a4['diffData'][_0x111429]['attributesAfter'])||{},_0x1bb1ad=_0x44ecc3['_makeModelFromViewString'](_0x2d10a4['diffData'][_0x111429]['insertions']);_0x1bb1ad['rootName']=_0x111429,_0x1bb1ad['_isAttached']=!_0x26b3f6||_0x26b3f6['isAttached'],_0x1bb1ad['isAttached']=()=>_0x1bb1ad['_isAttached'],this['_diffRoots']['set'](_0x111429,_0x1bb1ad),this['_diffRootsAttributes']['set'](_0x111429,_0x2bc310);const _0x5117bb=this['_makeIdsRoot'](_0x1bb1ad,Number['NEGATIVE_INFINITY']);this['_idsRoots']['set'](_0x111429,_0x5117bb),_0xddfab6['set'](_0x111429,_0x1bb1ad['isAttached']()?_0x2bc310:{});for(const [_0x2a3488,_0x5e8dbd]of _0x1bb1ad['markers']){if(!_0x2a3488['startsWith']('revision:'))continue;const _0x4c418d=_0x2a3488['split'](':')[0x2];for(const _0x2dd61c of _0x5e8dbd['getWalker']({'singleCharacters':!0x0})){const _0x52038b=this['_getVidAttributeName'](_0x2dd61c),_0xe34fae=this['_revisionId']++,_0x472bfc='elementEnd'==_0x2dd61c['type']?_0x2dd61c['previousPosition']['path']['slice'](0x0,-0x1):_0x2dd61c['previousPosition']['path'];_0x5117bb['getNodeByPath'](_0x472bfc)['_setAttribute'](_0x52038b,_0xe34fae),this['_touched']['set'](_0xe34fae,{'userId':_0x4c418d});}}for(const _0x5624e9 of this['editor']['model']['createRangeIn'](_0x1bb1ad)['getWalker']({'singleCharacters':!0x0})){const _0x8589ec=this['_getVidAttributeName'](_0x5624e9),_0x5c1211='elementEnd'==_0x5624e9['type']?_0x5624e9['previousPosition']['path']['slice'](0x0,-0x1):_0x5624e9['previousPosition']['path'],_0x8d12b2=_0x5117bb['getNodeByPath'](_0x5c1211);_0x8d12b2['getAttribute'](_0x8589ec)>0x0||_0x8d12b2['_setAttribute'](_0x8589ec,_0x21f180[_0x1038fe++]);}for(const [_0x2e89ec,_0x5e1920]of _0x1bb1ad['markers'])_0x2e89ec['startsWith']('revision:')||this['_markers']['set'](_0x2e89ec,_0x5e1920);}const _0x27984b=P('$graveyard');this['_baseRoots']['set']('$graveyard',_0x27984b),this['_baseIdsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x27984b,0x1));const _0x9a01a3=P('$graveyard');this['_diffRoots']['set']('$graveyard',_0x9a01a3),this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x9a01a3,0x1));const _0x390f43=Array['from'](this['_diffRoots'])['map'](([_0x4efa44,_0x180a3f])=>[_0x4efa44,N(_0x180a3f)]);this['_saveMetaData'](this['_lastTo'],_0x390f43,this['_markers'],_0xddfab6);}['reInit'](){this['_reset'](),this['_lastFrom']=-0x1,this['_lastTo']=-0x1,this['_savedMetaData']['clear'](),this['init'](this['source']);}['_saveMetaData'](_0x2c4b7a,_0x2c7757,_0x4b44f3,_0x2bbf1e){const _0x5a8113=new Map(_0x2c7757),_0x5a6c4a=new Map(_0x4dbdf7(_0x2bbf1e)),_0x450dd5=new Map();for(const [_0x2da8b0,_0xa0fad1]of _0x4b44f3)_0x450dd5['set'](_0x2da8b0,{'start':_0xa0fad1['start']['clone'](),'end':_0xa0fad1['end']['clone'](),'rootName':_0xa0fad1['root']['rootName']});this['_savedMetaData']['set'](_0x2c4b7a,{'roots':_0x5a8113,'markers':_0x450dd5,'rootsAttributes':_0x5a6c4a});}['_removeMetaData'](_0x5a4b8e){this['_savedMetaData']['delete'](_0x5a4b8e);}['_reset'](){this['_touched']['clear'](),this['_touchedMarkers']['clear'](),this['_touchedRoots']['clear'](),this['_diffRoots']['clear'](),this['_diffRootsAttributes']['clear'](),this['_baseRoots']['clear'](),this['_baseRootsAttributes']['clear'](),this['_idsRoots']['clear'](),this['_baseIdsRoots']['clear'](),this['_markers']['clear'](),this['_revisionId']=0x1,this['_startingRevisionId']=this['_revisionId'];}['_makeIdsRoot'](_0x69388d,_0x14bf0b=null){let _0x2390cc=null;_0x69388d['is']('documentFragment')||(_0x2390cc=new ut(_0x69388d['name'],{'vid_start':null===_0x14bf0b?this['_revisionId']++:_0x14bf0b++}));const _0x26d4ee=[];for(const _0x442fa9 of _0x69388d['getChildren']())if(_0x442fa9['is']('element')){_0x26d4ee['push'](this['_makeIdsRoot'](_0x442fa9,_0x14bf0b));const _0x25d590=_0x26d4ee[_0x26d4ee['length']-0x1];null!==_0x14bf0b&&(_0x14bf0b=_0x25d590['is']('element','$text')?_0x25d590['getAttribute']('vid')+0x1:_0x25d590['getAttribute']('vid_end')+0x1);}else{for(let _0x1a71f8=0x0;_0x1a71f8<_0x442fa9['offsetSize'];_0x1a71f8++)_0x26d4ee['push'](new ut('$text',{'vid':null===_0x14bf0b?this['_revisionId']++:_0x14bf0b++}));}if(_0x69388d['is']('documentFragment')){const _0x50571c=P(_0x69388d['rootName']);return _0x50571c['_insertChild'](0x0,_0x26d4ee),_0x50571c;}return _0x2390cc['_setAttribute']('vid_end',null===_0x14bf0b?this['_revisionId']++:_0x14bf0b++),_0x2390cc['_insertChild'](0x0,_0x26d4ee),_0x2390cc;}['_calculateMetaData'](_0x1e1d6d,_0x102dec,_0x1c8daf){this['_reset']();const {roots:_0x439cf8,markers:_0x42d876,rootsAttributes:_0x374978}=this['_savedMetaData']['get'](_0x1e1d6d);this['_baseRoots']=new Map(_0x439cf8),this['_baseRootsAttributes']=new Map(_0x4dbdf7(_0x374978));for(const [_0x2a89fa,_0x193981]of this['_baseRoots'])if('$graveyard'!==_0x2a89fa&&(this['_diffRoots']['set'](_0x2a89fa,N(_0x193981)),this['_diffRootsAttributes']=new Map(_0x4dbdf7(_0x374978)),_0x1c8daf)){const _0x4a59f4=this['_revisionId'];this['_idsRoots']['set'](_0x2a89fa,this['_makeIdsRoot'](_0x193981)),this['_baseIdsRoots']['set'](_0x2a89fa,this['_makeIdsRoot'](_0x193981,_0x4a59f4));}this['_startingRevisionId']=this['_revisionId'],this['_diffRoots']['set']('$graveyard',N(this['_baseRoots']['get']('$graveyard'))),_0x1c8daf&&this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](this['_baseRoots']['get']('$graveyard')));for(const [_0x4523f8,_0x3c7d6f]of _0x42d876){const _0x533080=this['_baseRoots']['get'](_0x3c7d6f['rootName']),_0x4a7f2f=this['_diffRoots']['get'](_0x3c7d6f['rootName']),_0x2d14c5=new lt(this['_fixPosition'](_0x3c7d6f['start'],_0x533080),this['_fixPosition'](_0x3c7d6f['end'],_0x533080)),_0x33122d=this['_fixRange'](_0x2d14c5,_0x4a7f2f);_0x533080['markers']['set'](_0x4523f8,_0x2d14c5),this['_markers']['set'](_0x4523f8,_0x33122d);}this['_applyOperations'](_0x1e1d6d,_0x102dec,_0x1c8daf);}['_applyOperations'](_0xe4dd24,_0x2d2927,_0x370f58){for(const _0x15d6bb of this['source']['getOperations'](_0xe4dd24,_0x2d2927))this['_handleOperation'](_0x15d6bb,_0x370f58);for(const _0x1c2a1c of this['_diffRoots']['values']())_0x1c2a1c['markers']['clear']();for(const [_0x583075,_0x179398]of this['_markers']){this['_diffRoots']['get'](_0x179398['root']['rootName'])['markers']['set'](_0x583075,_0x179398['clone']());}const _0x3ab8f9=new Map(),_0xa18032=new Map();for(const [_0x4e7f73,_0x3e585e]of this['_diffRoots'])_0x3ab8f9['set'](_0x4e7f73,N(_0x3e585e)),_0xa18032['set'](_0x4e7f73,this['_diffRootsAttributes']['get'](_0x4e7f73));this['_saveMetaData'](_0x2d2927,_0x3ab8f9,this['_markers'],_0xa18032);}['_getPreviousFrom'](_0x223d61){const _0x14469e=Array['from'](this['_savedMetaData']['keys']());_0x14469e['sort']((_0x1924ab,_0x3a2e3e)=>_0x1924ab-_0x3a2e3e),_0x14469e['reverse']();for(const _0x3de411 of _0x14469e)if(_0x3de411<_0x223d61)return _0x3de411;return Number['NEGATIVE_INFINITY'];}['_copyMarkers'](_0x3c8405,_0x1a5be2){const _0x3d17a8=Array['from'](_0x1a5be2['markers'])['map'](([_0x5bb5c1,_0x4cefc5])=>[_0x5bb5c1,this['_fixRange'](_0x4cefc5,_0x3c8405)]);_0x3c8405['markers']=new Map(_0x3d17a8);}['_transformMarkers'](_0x242078){for(const _0x1eff58 of this['_markers']['values']()){const _0x16b752=_0x1eff58['getTransformedByOperation'](_0x242078),_0x46b588=lt['_createFromRanges'](_0x16b752);_0x1eff58['start']=_0x46b588['start'],_0x1eff58['end']=_0x46b588['end'];}}['_handleOperation'](_0x2e4d59,_0xf396fc){if('addRoot'!=_0x2e4d59['type']&&'detachRoot'!=_0x2e4d59['type']){if('insert'==_0x2e4d59['type']){const _0x1e9ff8=_0x2e4d59['position']['root']['rootName'];this['_diffRoots']['has'](_0x1e9ff8)||(this['_diffRoots']['set'](_0x1e9ff8,P(_0x1e9ff8,!0x0)),this['_diffRootsAttributes']['set'](_0x1e9ff8,{}),_0xf396fc&&this['_idsRoots']['set'](_0x1e9ff8,P(_0x1e9ff8,!0x0)));}else{if('addRootAttribute'==_0x2e4d59['type']||'removeRootAttribute'==_0x2e4d59['type']||'changeRootAttribute'==_0x2e4d59['type'])return void this['_handleRootAttributeOperation'](_0x2e4d59);'marker'==_0x2e4d59['type']&&this['_handleMarkerOperation'](_0x2e4d59);}if('marker'!==_0x2e4d59['type']){const _0x2ca857=this['_cloneOperation'](_0x2e4d59,this['_diffRoots']);_0x2ca857['_execute'](),this['_transformMarkers'](_0x2ca857);}if(_0xf396fc)switch(_0x2e4d59['type']){case'insert':this['_handleInsertOperation'](_0x2e4d59);break;case'move':case'remove':case'reinsert':this['_handleMoveOperation'](_0x2e4d59);break;case'merge':this['_handleMergeOperation'](_0x2e4d59);break;case'split':this['_handleSplitOperation'](_0x2e4d59);}}else this['_handleRootOperation'](_0x2e4d59,_0xf396fc);}['_cloneOperation'](_0x2c2758,_0x30105c){const _0x4d40a0=_0x2c2758['clone']();return _0x4d40a0['_authorId']=_0x2c2758['_authorId'],this['_fixOperation'](_0x4d40a0,_0x30105c),_0x4d40a0;}['_getBaseVids'](_0x3c1275){return _0x3c1275['map'](_0x58f6d2=>{const _0x5be85f=this['_getVidAttributeName'](_0x58f6d2);return Number(_0x58f6d2['item']['getAttribute'](_0x5be85f));});}['_generateTape'](_0x1b1d88,_0x51a594){if(_0x1b1d88['is']('element','$text'))_0x51a594['push']({'item':_0x1b1d88,'type':'text'});else{_0x1b1d88['is']('element')&&_0x51a594['push']({'item':_0x1b1d88,'type':'elementStart'});for(const _0x4163d9 of _0x1b1d88['getChildren']())this['_generateTape'](_0x4163d9,_0x51a594);_0x1b1d88['is']('element')&&_0x51a594['push']({'item':_0x1b1d88,'type':'elementEnd'});}return _0x51a594;}['_getState'](){const _0xddfe9=new Map(this['_touched']),_0x4afb99=new Map(_0xddfe9),_0x23d4d3=new Map(),_0x5dedc6={'insertions':{},'deletions':{}},_0xa70b4d={'insertions':{},'deletions':{}},_0x3ff9ca=new Map(),_0x215f41=new Set([...this['_baseRoots']['keys'](),...this['_diffRoots']['keys']()]);_0x215f41['delete']('$graveyard');for(const _0x4b188b of _0x215f41){const _0x44b4cd=this['_diffRoots']['get'](_0x4b188b)||P(_0x4b188b,!0x1),_0x114c6f=this['_baseRoots']['get'](_0x4b188b)||P(_0x4b188b,!0x1);_0x44b4cd['isAttached']()||_0x114c6f['isAttached']()?(_0x5dedc6['insertions'][_0x4b188b]=N(_0x44b4cd),_0x5dedc6['deletions'][_0x4b188b]=N(_0x114c6f),this['_copyMarkers'](_0x5dedc6['deletions'][_0x4b188b],_0x114c6f),this['_copyMarkers'](_0x5dedc6['insertions'][_0x4b188b],_0x44b4cd),_0xa70b4d['insertions'][_0x4b188b]=this['_generateTape'](this['_idsRoots']['get'](_0x4b188b),[]),_0xa70b4d['deletions'][_0x4b188b]=this['_generateTape'](this['_baseIdsRoots']['get'](_0x4b188b)||P(_0x4b188b,!0x1),[])):_0x215f41['delete'](_0x4b188b);}for(const _0x5beb83 of _0x215f41){const _0x39972d=_0xa70b4d['insertions'][_0x5beb83];for(const _0x5e83eb of _0x39972d){const _0x37e245=this['_getVidAttributeName'](_0x5e83eb),_0x173415=_0x5e83eb['item']['getAttribute'](_0x37e245);_0x4afb99['delete'](_0x173415),_0x173415>=this['_startingRevisionId']&&_0x23d4d3['set'](_0x173415,_0xddfe9['get'](_0x173415));}}for(const _0x21c92b of _0x215f41){const _0x5d5889=_0xa70b4d['insertions'][_0x21c92b],_0x24d100=this['_getBaseVids'](_0xa70b4d['deletions'][_0x21c92b]);let _0x5c2a37=0x0;for(const _0xde9da3 of _0x5d5889){const _0x5f4517=this['_getVidAttributeName'](_0xde9da3),_0x1cc644=_0xde9da3['item']['getAttribute'](_0x5f4517);if(!_0x23d4d3['has'](_0x1cc644)&&!_0x3ff9ca['has'](_0x1cc644)){if(_0x4afb99['has'](_0x1cc644))_0x5c2a37++;else{if(_0x1cc644!=_0x24d100[_0x5c2a37]){const _0x3bff7e=_0xddfe9['get'](_0x1cc644)||_0xddfe9['get'](_0x24d100[_0x5c2a37]);for(;_0x1cc644!=_0x24d100[_0x5c2a37];)_0x4afb99['has'](_0x24d100[_0x5c2a37])||(_0x3ff9ca['set'](_0x24d100[_0x5c2a37],_0x3bff7e),_0xddfe9['set'](_0x24d100[_0x5c2a37],_0x3bff7e)),_0x5c2a37++;}_0x5c2a37++;}}}}for(const _0x5100e9 of _0x215f41){const _0x185b67=_0xa70b4d['insertions'][_0x5100e9];for(const _0x496efc of _0x185b67){const _0x4111cc=this['_getVidAttributeName'](_0x496efc),_0x17e009=_0x496efc['item']['getAttribute'](_0x4111cc);if(_0x3ff9ca['has'](_0x17e009)){const _0x33afed=_0x3ff9ca['get'](_0x17e009);_0x4afb99['has'](_0x17e009)||_0x4afb99['set'](_0x17e009,{..._0x33afed}),_0x23d4d3['set'](_0x17e009,{..._0x33afed});}}}for(const _0x9e12a7 of _0x4afb99['keys']())_0x9e12a7>=this['_startingRevisionId']&&_0x4afb99['delete'](_0x9e12a7);const _0xd5d1b9=new Map();for(const _0x458fb4 of _0x215f41){let _0x2c977d=_0xa70b4d['insertions'][_0x458fb4];for(const _0x10a18d of _0x2c977d)if(_0x10a18d['item']['is']('element','tableCell')){const _0x54acbe=this['_getVidAttributeName'](_0x10a18d),_0x1a7642=_0x10a18d['item']['getAttribute'](_0x54acbe);if(_0x23d4d3['has'](_0x1a7642)){const _0x107e44=_0x10a18d['item']['parent']['parent']['getAttribute']('vid_start'),_0x10b21b=_0xd5d1b9['get'](_0x107e44)||new Set();_0x10b21b['add'](_0x23d4d3['get'](_0x1a7642)['userId']),_0xd5d1b9['set'](_0x107e44,_0x10b21b);}}_0x2c977d=_0xa70b4d['deletions'][_0x458fb4];for(const _0x2213d3 of _0x2c977d)if(_0x2213d3['item']['is']('element','tableCell')){const _0xf3ad91=this['_getVidAttributeName'](_0x2213d3),_0x4a8861=_0x2213d3['item']['getAttribute'](_0xf3ad91);if(_0x4afb99['has'](_0x4a8861)){const _0x56aaab=_0x2213d3['item']['parent']['parent']['getAttribute']('vid_start'),_0x1e2f48=_0xd5d1b9['get'](_0x56aaab)||new Set();_0x1e2f48['add'](_0x4afb99['get'](_0x4a8861)['userId']),_0xd5d1b9['set'](_0x56aaab,_0x1e2f48);}}for(const _0x1c2e1f of _0xd5d1b9['keys']())(_0x23d4d3['has'](_0x1c2e1f)||_0x4afb99['has'](_0x1c2e1f))&&_0xd5d1b9['delete'](_0x1c2e1f);}for(const _0xdadc1e of _0x215f41){const _0x3fe539=_0xa70b4d['insertions'][_0xdadc1e];let _0x5a5901=null,_0x20b3b2=null;for(const _0xe9440e of _0x3fe539){const _0x86d234=this['_getVidAttributeName'](_0xe9440e),_0x29ae11=_0xe9440e['item']['getAttribute'](_0x86d234),_0x40dda2=_0xd5d1b9['get'](_0x29ae11);_0x40dda2&&'elementStart'==_0xe9440e['type']&&(_0x5a5901=Array['from'](_0x40dda2)[0x0],_0x20b3b2=_0xe9440e['item']['getAttribute']('vid_end')),_0x5a5901&&(_0x4afb99['set'](_0x29ae11,{'userId':_0x5a5901}),_0x23d4d3['set'](_0x29ae11,{'userId':_0x5a5901})),_0x29ae11==_0x20b3b2&&(_0x5a5901=null,_0x20b3b2=null);}}const _0x182f60={},_0x4bab10=new Set();for(const _0x551f2a of _0x215f41){const _0x51fe5a=_0x5dedc6['deletions'][_0x551f2a],_0x3eb17e=_0x5dedc6['insertions'][_0x551f2a];for(const {userId:_0x43e839}of this['_touchedMarkers']['values']())null!==_0x43e839&&_0x4bab10['add'](_0x43e839);for(const {userId:_0x557537}of this['_touchedRoots']['values']())null!==_0x557537&&_0x4bab10['add'](_0x557537);this['_markChanges'](_0x3eb17e,_0xa70b4d['insertions'][_0x551f2a],_0x23d4d3,'insertion',_0x4bab10),this['_markChanges'](_0x51fe5a,_0xa70b4d['deletions'][_0x551f2a],_0x4afb99,'deletion',_0x4bab10),_0x182f60[_0x551f2a]={'insertions':this['_prepareViewToSave'](_0x3eb17e),'deletions':this['_prepareViewToSave'](_0x51fe5a),'attachChange':this['_touchedRoots']['get'](_0x551f2a)||null,'attributesBefore':_0x4dbdf7(this['_baseRootsAttributes']['get'](_0x551f2a))||{},'attributesAfter':_0x4dbdf7(this['_diffRootsAttributes']['get'](_0x551f2a))};}return{'diffData':_0x182f60,'authorsIds':Array['from'](_0x4bab10)};}['_processRootBeforeSave'](_0x17eafc){for(const [,_0x29eb1e]of _0x17eafc['markers']){const _0x4029ed=_0x29eb1e['start']['getAncestors']()['filter'](_0x5b68cf=>'tableCell'==_0x5b68cf['name']);for(const _0x3d5302 of _0x4029ed)0x1==_0x3d5302['childCount']&&_0x3d5302['getChild'](0x0)['is']('element','paragraph')&&_0x3d5302['getChild'](0x0)['_setAttribute']('keepParagraph',!0x0);}}['_prepareViewToSave'](_0x15dfe3){this['_processRootBeforeSave'](_0x15dfe3);const _0x26136e=this['editor']['data']['toView'](_0x15dfe3,{}),_0x201954=Array['from'](_0x26136e['getChildren']())['map'](_0x3d7b77=>this['_getViewJson'](_0x3d7b77));return JSON['stringify'](_0x201954);}['_getViewJson'](_0x8c7317){if(_0x8c7317['is']('$text'))return _0x8c7317['data'];{const _0x50c592=this['editor']['plugins']['get']('RevisionHistoryUtils'),_0xcac413=_0x8c7317,_0x120db5=this['editor']['data']['htmlProcessor']['domConverter'],_0x3788b3={'type':_0x50c592['_getTypeCharForViewElement'](_0xcac413),'name':_0xcac413['name'],'attributes':Array['from'](_0xcac413['getAttributes']()),'children':Array['from'](_0xcac413['getChildren']())['map'](_0x4500d6=>this['_getViewJson'](_0x4500d6))};if(_0x8c7317['is']('uiElement')&&'$comment'!=_0x8c7317['name']){const _0x1ca64c=_0x8c7317['render'](_0x120db5['domDocument'],_0x120db5);_0x3788b3['children']['push'](_0x1ca64c['outerHTML']);}else{if(_0x8c7317['is']('rawElement')){const _0x355bb2=_0x120db5['domDocument']['createElement'](_0xcac413['name']);_0x8c7317['render'](_0x355bb2,_0x120db5),_0x3788b3['children']['push'](_0x355bb2['innerHTML']);}}const _0x3c6a76=Array['from'](_0xcac413['getCustomProperties']());_0x3c6a76['length']>0x0&&(_0x3788b3['customProperties']=_0x3c6a76);const _0x1cd290=_0xcac413['getFillerOffset']();return null!==_0x1cd290&&(_0x3788b3['fillerOffset']=_0x1cd290),_0x3788b3;}}['_markChanges'](_0xc4e8f0,_0x559001,_0x34a88c,_0x4a4ff9,_0x2dd39d){let _0x1870e2=null,_0x128f28=null,_0x311156=0x0;const _0xe81e7c=this['editor']['model'];for(let _0x5c02b3=0x0;_0x5c02b3<_0x559001['length'];_0x5c02b3++){const _0x1e929c=this['_getVidAttributeName'](_0x559001[_0x5c02b3]),_0x13edc7=_0x559001[_0x5c02b3]['item']['getAttribute'](_0x1e929c),_0x5157dd=_0x34a88c['get'](_0x13edc7),_0x4c429a=_0x5c02b3==_0x559001['length']-0x1;(!_0x1870e2&&_0x5157dd&&(_0x1870e2=_0x5157dd,_0x128f28=_0x559001[_0x5c02b3]),_0x1870e2&&(!_0x5157dd||_0x5157dd['userId']!=_0x1870e2['userId']))&&(_0x3f48ec(_0x5157dd,F(_0x128f28,_0xc4e8f0,_0xe81e7c),F(_0x559001[_0x5c02b3],_0xc4e8f0,_0xe81e7c)),_0x1870e2=_0x5157dd||null,_0x128f28=_0x5157dd?_0x559001[_0x5c02b3]:null),_0x1870e2&&_0x4c429a&&_0x3f48ec(_0x5157dd,F(_0x128f28,_0xc4e8f0,_0xe81e7c),B(_0x559001[_0x5c02b3],_0xc4e8f0,_0xe81e7c));}function _0x3f48ec(_0x20b5f6,_0x2ab743,_0x4ff7f3){const _0x38a745=_0x1870e2['userId'],_0x474711='revision:'+_0x4a4ff9+':'+_0x38a745+':'+_0x311156++,_0x34f149=_0xe81e7c['createRange'](_0x2ab743,_0x4ff7f3);_0xc4e8f0['markers']['set'](_0x474711,_0x34f149),null!==_0x38a745&&_0x2dd39d['add'](_0x38a745);}}['_getVidAttributeName'](_0x517dff){switch(_0x517dff['type']){case'elementStart':return'vid_start';case'elementEnd':return'vid_end';default:return'vid';}}['_fixOperation'](_0x5b7a0d,_0x14025c){_0x5b7a0d['baseVersion']=null;for(const _0x4e8f7e in _0x5b7a0d){const _0x5dfd50=_0x5b7a0d[_0x4e8f7e];if(_0x5dfd50 instanceof ft){const _0x5b7fa3=_0x14025c['get'](_0x5dfd50['root']['rootName']);_0x5b7a0d[_0x4e8f7e]=this['_fixPosition'](_0x5dfd50,_0x5b7fa3);}if(_0x5dfd50 instanceof lt){const _0xc8b292=_0x14025c['get'](_0x5dfd50['root']['rootName']);_0x5b7a0d[_0x4e8f7e]=this['_fixRange'](_0x5dfd50,_0xc8b292);}'root'===_0x4e8f7e&&(_0x5b7a0d['root']=_0x14025c['get'](_0x5b7a0d['root']['rootName']));}}['_fixRange'](_0x231f71,_0x3e3490){return this['editor']['model']['createRange'](this['_fixPosition'](_0x231f71['start'],_0x3e3490),this['_fixPosition'](_0x231f71['end'],_0x3e3490));}['_fixPosition'](_0xfe1bbf,_0x596575){return this['editor']['model']['createPositionFromPath'](_0x596575,_0xfe1bbf['path'],_0xfe1bbf['stickiness']);}['_handleInsertOperation'](_0x1539a6){const _0x3005e4=this['_idsRoots']['get'](_0x1539a6['position']['root']['rootName']),_0x5219c3=this['_fixPosition'](_0x1539a6['position'],_0x3005e4),_0x156c92=null===_0x1539a6['_authorId']?null:_0x1539a6['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x278425=_0x5219c3['parent'],_0x1b6410=this['_revisionId'],_0x1e16fe=[];for(const _0x5561f8 of _0x1539a6['nodes'])if(_0x5561f8['is']('element'))_0x1e16fe['push'](this['_makeIdsRoot'](_0x5561f8));else{for(let _0x4fa79d=0x0;_0x4fa79d<_0x5561f8['offsetSize'];_0x4fa79d++)_0x1e16fe['push'](new ut('$text',{'vid':this['_revisionId']++}));}const _0x1b55a7=this['_revisionId'];for(let _0x3be454=_0x1b6410;_0x3be454<_0x1b55a7;_0x3be454++)this['_touched']['set'](_0x3be454,{'userId':_0x156c92});_0x278425['_insertChild'](_0x5219c3['offset'],_0x1e16fe);}['_handleMoveOperation'](_0x976d5){(_0x976d5=this['_cloneOperation'](_0x976d5,this['_idsRoots']))['_execute']();const _0x3e1049=null===_0x976d5['_authorId']?null:_0x976d5['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x26940e=_0x976d5['getMovedRangeStart'](),_0x4e726a=_0x26940e['parent'],_0x100af6=_0x26940e['offset'];!function _0x5978a2(_0x199335,_0x5573bd,_0xd72624,_0x1e210f){for(let _0x252ee5=_0xd72624;_0x252ee5<_0x1e210f;_0x252ee5++){const _0x3f240e=_0x5573bd['getChild'](_0x252ee5);_0x3f240e['is']('element','$text')?_0x199335['set'](_0x3f240e['getAttribute']('vid'),{'userId':_0x3e1049}):(_0x199335['set'](_0x3f240e['getAttribute']('vid_start'),{'userId':_0x3e1049}),_0x5978a2(_0x199335,_0x3f240e,0x0,_0x3f240e['childCount']),_0x199335['set'](_0x3f240e['getAttribute']('vid_end'),{'userId':_0x3e1049}));}}(this['_touched'],_0x4e726a,_0x100af6,_0x100af6+_0x976d5['howMany']);}['_handleMergeOperation'](_0x1f7638){const _0x84cae=null===(_0x1f7638=this['_cloneOperation'](_0x1f7638,this['_idsRoots']))['_authorId']?null:_0x1f7638['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x5868e8=_0x1f7638['targetPosition']['parent'],_0x105bb2=_0x1f7638['sourcePosition']['parent'],_0x57723d=_0x5868e8['getAttribute']('vid_end'),_0x3e5a4d=_0x105bb2['getAttribute']('vid_start');_0x5868e8['_setAttribute']('vid_end',_0x105bb2['getAttribute']('vid_end')),_0x105bb2['_setAttribute']('vid_end',_0x57723d),this['_touched']['set'](_0x3e5a4d,{'userId':_0x84cae}),this['_touched']['set'](_0x57723d,{'userId':_0x84cae}),_0x1f7638['_execute']();}['_handleSplitOperation'](_0xb10788){const _0x55b329=null===(_0xb10788=this['_cloneOperation'](_0xb10788,this['_idsRoots']))['_authorId']?null:_0xb10788['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x3e15c4=_0xb10788['graveyardPosition'],_0x14b54b=_0xb10788['splitPosition']['parent'];_0xb10788['_execute']();const _0x184f1e=_0x14b54b['getAttribute']('vid_end'),_0x3173db=_0xb10788['insertionPosition']['nodeAfter'];if(_0x3e15c4){const _0x46f064=_0x3173db['getAttribute']('vid_end'),_0x18a8f7=_0x14b54b['getAttribute']('vid_end');_0x14b54b['_setAttribute']('vid_end',_0x46f064),_0x3173db['_setAttribute']('vid_end',_0x18a8f7),this['_touched']['set'](_0x14b54b['getAttribute']('vid_end'),{'userId':_0x55b329}),this['_touched']['set'](_0x3173db['getAttribute']('vid_start'),{'userId':_0x55b329});}else{const _0x45806d=this['_revisionId']++,_0x1c2b73=this['_revisionId']++;_0x14b54b['_setAttribute']('vid_end',_0x45806d),_0x3173db['_setAttribute']('vid_start',_0x1c2b73),_0x3173db['_setAttribute']('vid_end',_0x184f1e),this['_touched']['set'](_0x45806d,{'userId':_0x55b329}),this['_touched']['set'](_0x1c2b73,{'userId':_0x55b329});}}['_handleMarkerOperation'](_0x5f3e7c){if(!_0x5f3e7c['affectsData'])return;const _0x27f898=(_0x5f3e7c=this['_cloneOperation'](_0x5f3e7c,this['_diffRoots']))['oldRange']?_0x5f3e7c['oldRange']['root']:null,_0x571032=_0x5f3e7c['newRange']?_0x5f3e7c['newRange']['root']:null;_0x27f898&&this['_markers']['delete'](_0x5f3e7c['name']),_0x571032&&this['_markers']['set'](_0x5f3e7c['name'],_0x5f3e7c['newRange']['clone']());const _0x580246=null===_0x5f3e7c['_authorId']?null:_0x5f3e7c['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x3d14fb=_0x5f3e7c['name'];if(!this['_touchedMarkers']['has'](_0x3d14fb))return void this['_touchedMarkers']['set'](_0x3d14fb,{'range':_0x5f3e7c['oldRange'],'userId':_0x580246});const _0x1a71d3=this['_touchedMarkers']['get'](_0x3d14fb),_0x330886=_0x1a71d3['range'],_0x41174a=_0x5f3e7c['newRange'];null==_0x330886&&null==_0x41174a||_0x330886&&_0x41174a&&_0x330886['isEqual'](_0x41174a)?this['_touchedMarkers']['delete'](_0x5f3e7c['name']):_0x1a71d3['userId']=_0x580246;}['_handleRootOperation'](_0x3ce6e7,_0x22dc84){this['_diffRoots']['has'](_0x3ce6e7['rootName'])?this['_diffRoots']['get'](_0x3ce6e7['rootName'])['_isAttached']=_0x3ce6e7['isAdd']:(this['_diffRoots']['set'](_0x3ce6e7['rootName'],P(_0x3ce6e7['rootName'],!0x0)),this['_diffRootsAttributes']['set'](_0x3ce6e7['rootName'],{}),_0x22dc84&&this['_idsRoots']['set'](_0x3ce6e7['rootName'],P(_0x3ce6e7['rootName'],!0x0)));const _0x308527=null===_0x3ce6e7['_authorId']?null:_0x3ce6e7['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x33e8cd=this['_touchedRoots']['get'](_0x3ce6e7['rootName']);_0x33e8cd&&_0x33e8cd['userId']===_0x308527?this['_touchedRoots']['delete'](_0x3ce6e7['rootName']):this['_touchedRoots']['set'](_0x3ce6e7['rootName'],{'userId':_0x308527,'isAttached':_0x3ce6e7['isAdd']});}['_handleRootAttributeOperation'](_0x2d3a28){const _0x448f4a=this['_diffRootsAttributes']['get'](_0x2d3a28['root']['rootName']);null===_0x2d3a28['newValue']?delete _0x448f4a[_0x2d3a28['key']]:_0x448f4a[_0x2d3a28['key']]=_0x2d3a28['newValue'];}}function N(_0x1a8492){const _0x2bc094=P(_0x1a8492['rootName'],_0x1a8492['isAttached']());for(const _0x180443 of _0x1a8492['getChildren']()){const _0x3012a6=_0x180443['_clone'](!0x0);_0x2bc094['_appendChild'](_0x3012a6);}return _0x2bc094;}function P(_0x541280,_0x437151=!0x0){const _0x18e972=new vt();return _0x18e972['rootName']=_0x541280,_0x18e972['_isAttached']=_0x437151,_0x18e972['isAttached']=()=>_0x18e972['_isAttached'],_0x18e972;}function F(_0x51d27e,_0x5182ef,_0x3fb1a3){const _0x3595c4='elementEnd'==_0x51d27e['type']?_0x3fb1a3['createPositionAt'](_0x51d27e['item'],'end'):_0x3fb1a3['createPositionBefore'](_0x51d27e['item']);return _0x3fb1a3['createPositionFromPath'](_0x5182ef,_0x3595c4['path'],_0x3595c4['stickiness']);}function B(_0x5a22dd,_0xceae7d,_0x1b9d28){const _0x4db432='elementStart'==_0x5a22dd['type']?_0x1b9d28['createPositionAt'](_0x5a22dd['item'],0x0):_0x1b9d28['createPositionAfter'](_0x5a22dd['item']);return _0x1b9d28['createPositionFromPath'](_0xceae7d,_0x4db432['path'],_0x4db432['stickiness']);}class hs extends ts{['focusTracker'];['keystrokes'];['revisionNameInputView'];constructor(_0x17fd52,_0x47829f){super(_0x17fd52),this['focusTracker']=new _0x12b377(),this['keystrokes']=new _0x10ecca(),this['set']('revisionNameInputValue',''),this['revisionNameInputView']=this['_createRevisionNameInput'](_0x47829f),this['setTemplate']({'tag':'form','attributes':{'class':['ck','ck-revision-history-save-revision-form','ck-responsive-form'],'tabindex':'-1'},'children':[this['revisionNameInputView']]}),_0x47db8c(this);}['render'](){super['render'](),_0x3b4acf({'view':this}),this['focusTracker']['add'](this['revisionNameInputView']['element']),this['keystrokes']['listenTo'](this['element']);const _0xacd8e=_0x631862=>_0x631862['stopPropagation']();this['keystrokes']['set']('arrowright',_0xacd8e),this['keystrokes']['set']('arrowleft',_0xacd8e),this['keystrokes']['set']('arrowup',_0xacd8e),this['keystrokes']['set']('arrowdown',_0xacd8e);}['focus'](){this['revisionNameInputView']['focus']();}get['revisionName'](){return this['revisionNameInputView']['fieldView']['element']['value']['trim']();}set['revisionName'](_0x43eeb3){this['revisionNameInputView']['fieldView']['element']['value']=_0x43eeb3['trim']();}['reset'](){this['revisionNameInputView']['fieldView']['element']['value']='',this['revisionNameInputView']['errorText']=null;}['_createRevisionNameInput'](_0x14a17c){const _0x48941e=new _0x21d0c2(this['locale'],_0x1a6c7a),_0x51bd60=_0x48941e['fieldView'];_0x51bd60['extendTemplate']({'attributes':{'maxlength':'220'}});let _0x32b13f=g(this['locale'],'Name\x20of\x20the\x20revision');return!_0x14a17c&&(_0x32b13f+='\x20('+g(this['locale'],'optional')+')'),(_0x48941e['label']=_0x32b13f,_0x51bd60['on']('input',()=>{this['revisionNameInputValue']=_0x51bd60['element']['value']['trim']();}),_0x48941e);}}class f extends _0x1aaf30{static get['pluginName'](){return'RevisionHistoryUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[u];}['_saveRevisionFormView'];['init'](){const _0x39936e=this['editor'],_0x4846e8=_0x39936e['plugins']['get']('RevisionTracker');_0x39936e['ui']['componentFactory']['add']('revisionHistory',_0xdb2876=>{const _0x3d7b0f=_0x3baa9b(_0xdb2876),_0x4381cd=_0x3d7b0f['panelView']['children'],_0x703d16=new _0xaeeef7(_0xdb2876),_0x4cfaa5=new _0x250e3b(_0xdb2876),_0x168c6d=new te(_0xdb2876),_0x4d90a4=new _0x250e3b(_0xdb2876),_0x508894=new te(_0xdb2876);return _0x3d7b0f['bind']('isEnabled')['to'](_0x4846e8,'isReady',_0x4846e8,'isEnabled',_0x39936e,'isReadOnly',(_0x56e041,_0x5e9d37,_0x41de19)=>_0x56e041&&_0x5e9d37&&!_0x41de19),_0x3d7b0f['buttonView']['set']({'icon':_0x2aae82,'label':g(_0xdb2876,'Revision\x20history'),'tooltip':!0x0}),_0x168c6d['set']({'label':g(_0xdb2876,'Save\x20current\x20revision'),'withText':!0x0,'role':'menuitem'}),_0x168c6d['bind']('isEnabled')['to'](_0x4846e8,'isReady',_0x4846e8,'isEnabled',_0x39936e,'isReadOnly',(_0x3ccf8f,_0x136925,_0x5f4154)=>_0x3ccf8f&&_0x136925&&!_0x5f4154),_0x168c6d['on']('execute',()=>this['_showDialog']()),_0x508894['set']({'label':g(_0xdb2876,'Open\x20revision\x20history'),'withText':!0x0,'role':'menuitem'}),_0x508894['bind']('isEnabled')['to'](_0x4846e8,'isReady',_0x39936e,'isReadOnly',(_0xb14346,_0x5d0379)=>_0xb14346&&!_0x5d0379),_0x508894['on']('execute',()=>{_0x39936e['config']['get']('revisionHistory')['showRevisionViewerCallback'](),_0x3d7b0f['isOpen']=!0x1,_0x39936e['editing']['view']['focus']();}),_0x4cfaa5['children']['add'](_0x168c6d),_0x4d90a4['children']['add'](_0x508894),_0x703d16['role']='menu',_0x703d16['items']['addMany']([_0x4cfaa5,_0x4d90a4]),_0x4381cd['add'](_0x703d16),_0x3d7b0f;}),_0x39936e['ui']['componentFactory']['add']('menuBar:revisionHistory',()=>this['_registerMenuComponent']());}['_registerMenuComponent'](){const _0x57ef31=this['editor'],_0x20e8b2=_0x57ef31['locale'],_0x156bec=new _0x471360(_0x20e8b2),_0x2cad10=new _0x118393(_0x20e8b2);_0x156bec['buttonView']['set']({'icon':_0x2aae82,'label':g(_0x20e8b2,'Revision\x20history')});const _0x25933d=new _0x47d63b(_0x20e8b2,_0x156bec),_0x15c6b3=new _0x53ffb1(_0x20e8b2);_0x15c6b3['set']({'label':g(_0x20e8b2,'Save\x20current\x20revision')}),_0x15c6b3['delegate']('execute')['to'](_0x156bec),_0x15c6b3['on']('execute',()=>{this['_showDialog']();}),_0x25933d['children']['add'](_0x15c6b3),_0x2cad10['items']['add'](_0x25933d);const _0xdd2470=new _0x47d63b(_0x20e8b2,_0x156bec),_0x4bce90=new _0x53ffb1(_0x20e8b2);return _0x4bce90['set']({'label':g(_0x20e8b2,'Open\x20revision\x20history')}),_0x4bce90['delegate']('execute')['to'](_0x156bec),_0x4bce90['on']('execute',()=>{_0x57ef31['config']['get']('revisionHistory')['showRevisionViewerCallback']();}),_0xdd2470['children']['add'](_0x4bce90),_0x2cad10['items']['add'](_0xdd2470),_0x156bec['panelView']['children']['add'](_0x2cad10),_0x156bec;}['_showDialog'](){const _0x2c688d=this['editor'],_0x505b7b=_0x2c688d['locale'],_0x3222bc=_0x2c688d['plugins']['get']('Dialog'),_0x54a382=_0x2c688d['plugins']['get']('RevisionTracker');function _0x9354ef(_0x3e8354){_0x2c688d['config']['get']('revisionHistory.requireRevisionName')&&''===_0x3e8354['revisionName']?_0x3e8354['revisionNameInputView']['errorText']=g(_0x505b7b,'The\x20revision\x20name\x20cannot\x20be\x20empty.'):(_0x2c688d['plugins']['get'](u)['saveRevision']({'name':_0x3e8354['revisionName']}),_0x3222bc['hide']());}this['_saveRevisionFormView']||(this['_createSaveRevisionFormView'](),this['_saveRevisionFormView']['on']('submit',()=>_0x9354ef(this['_saveRevisionFormView']))),this['_saveRevisionFormView']['reset'](),_0x3222bc['show']({'id':'revisionSave','title':g(_0x505b7b,'Save\x20current\x20revision'),'isModal':!0x0,'content':this['_saveRevisionFormView'],'actionButtons':[{'label':g(_0x2c688d['locale'],'Cancel'),'withText':!0x0,'onExecute':()=>_0x3222bc['hide']()},{'label':g(_0x2c688d['locale'],'Accept'),'class':'ck-button-action','withText':!0x0,'onCreate'(_0x3743d3){_0x3743d3['bind']('isEnabled')['to'](_0x54a382,'isReady',_0x54a382,'isEnabled',_0x2c688d,'isReadOnly',(_0x263cf6,_0x29f129,_0x1beb9c)=>_0x263cf6&&_0x29f129&&!_0x1beb9c);},'onExecute':()=>_0x9354ef(this['_saveRevisionFormView'])}]});}['_createSaveRevisionFormView'](){const _0x161527=this['editor'],_0x309f14=_0x161527['locale'];this['_saveRevisionFormView']=new hs(_0x309f14,_0x161527['config']['get']('revisionHistory.requireRevisionName')),this['_saveRevisionFormView']['render']();}}class Q extends ts{['changeId'];['_model'];constructor(_0x46478f,_0x270f6d){super(_0x46478f),this['_model']=_0x270f6d,this['changeId']=_0x270f6d['id'];const _0x29deaf=this['bindTemplate'],_0x52eeb3=g(_0x46478f,_0x270f6d['data']['isSuggestion']?'Suggested\x20by':'add'==_0x270f6d['type']?'Added\x20by':'Removed\x20by');this['set']('type',_0x270f6d['type']),this['setTemplate']({'tag':'div','attributes':{'class':['ck-annotation','ck-revision-change',_0x29deaf['to']('type',_0x4ec083=>'ck-revision-change__'+_0x4ec083)],'tabindex':-0x1},'children':[{'tag':'span','children':[{'tag':'span','attributes':{'class':['ck-revision-change__label']},'children':[{'text':_0x52eeb3}]},{'text':'\x20'+_0x270f6d['author']['name']}]}]});}['focus'](){this['element']['focus']();}}class r extends/* #__PURE__ -- @preserve */
25
+ _0x3196fa(){['id'];['author'];['type'];['data'];['rootName'];constructor(_0x52cf61){super(),this['id']=_0x52cf61['id']||_0x3fbd15(),this['author']=_0x52cf61['author'],this['type']=_0x52cf61['type'],this['data']=_0x52cf61['data']||{},this['rootName']=_0x52cf61['rootName'],this['set']('createdAt',_0x52cf61['createdAt']);}['toJSON'](){return{'id':this['id'],'authorId':this['author']['id'],'type':this['type'],'data':this['data'],'createdAt':this['createdAt']};}}class c{['newRevisionId'];['oldRevisionId'];['changes'];constructor(_0x517c73,_0x434bc4){this['newRevisionId']=_0x517c73,this['oldRevisionId']=_0x434bc4,this['changes']=new _0x5f0faf();}['_setChanges'](_0xa44daa){for(const _0x31d15c of _0xa44daa)this['changes']['add'](_0x31d15c);}}class m extends _0x1aaf30{['repository'];['adapter']=null;['_utils'];['_activeViewTarget'];['_changeView'];['_changeIdToChange'];['_balloon'];static get['pluginName'](){return'RevisionViewer';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[_0x25ff19,_0x52db93,I,V];}constructor(_0xc8007){super(_0xc8007),this['repository']=this['editor']['plugins']['get']('RevisionsRepository'),this['_utils']=this['editor']['plugins']['get']('RevisionHistoryUtils'),this['set']('activeChange',null),this['set']('activeView',null),this['_activeViewTarget']=null,this['set']('diff',null),this['set']('isReady',!0x1),this['set']('isEnabled',!0x0),this['on']('change:isEnabled',(_0x155fb1,_0x461bd1,_0x542a87)=>{this['activeChange']=null,this['activeView']=null,this['editor']['editing']['view']['change'](_0x143f3a=>{for(const _0x3ed68f of this['editor']['editing']['view']['document']['roots'])_0x542a87?_0x143f3a['removeClass']('ck-editor__editable__overlay',_0x3ed68f):_0x143f3a['addClass']('ck-editor__editable__overlay',_0x3ed68f);});}),this['bind']('isNavigationMode')['to'](this,'activeChange',_0x1c266f=>null!==_0x1c266f),this['bind']('currentChangeNumber')['to'](this,'isReady',this,'diff',this,'activeChange',(_0x4b795e,_0x4a8e12,_0xa71252)=>_0x4b795e&&_0xa71252?_0x4a8e12['changes']['getIndex'](_0xa71252):0x0),this['bind']('numberOfChanges')['to'](this,'isReady',this,'diff',(_0x513ee2,_0x23e199)=>_0x513ee2?_0x23e199['changes']['length']:0x0),this['_changeView']=null,this['_changeIdToChange']=new Map(),this['_balloon']=this['editor']['plugins']['get'](_0x52db93);}['init'](){const _0x2678e6=this['editor'],_0x472825=new wt(_0x2678e6,{'direction':'backward'}),_0x1b40bd=new wt(_0x2678e6,{'direction':'forward'});(_0x2678e6['commands']['add']('showPreviousChange',_0x472825),_0x2678e6['commands']['add']('showNextChange',_0x1b40bd),_0x2678e6['commands']['add']('restoreRevision',new mt(_0x2678e6)),this['on']('change:numberOfChanges',()=>{_0x472825['refresh'](),_0x1b40bd['refresh']();}),this['_setConversion'](),this['_initInteractions'](),_0x2678e6['enableReadOnlyMode']('revision-viewer'),_0x2678e6['plugins']['has']('WidgetToolbarRepository'))&&_0x2678e6['plugins']['get']('WidgetToolbarRepository')['forceDisabled']('revision-viewer');}async['getRevisionDocumentData'](_0x12ddc0){return await this['_utils']['loadRevisionData'](_0x12ddc0,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x12ddc0);}async['getRevisionRootsAttributes'](_0x4fb5a1){return await this['_utils']['loadRevisionData'](_0x4fb5a1,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x4fb5a1);}async['compare'](_0x3ab766,_0x458a54,_0x45f6dc=!0x1){if(!this['isEnabled'])return;const _0x55bef2=this['diff'],_0x151d04=this['repository'],_0x23106e='string'==typeof _0x3ab766?_0x151d04['getRevision'](_0x3ab766):_0x3ab766,_0x463c13='string'==typeof _0x458a54?_0x151d04['getRevision'](_0x458a54):_0x458a54,_0x3fba0f=_0x23106e['id'],_0x17b3ef=_0x463c13?_0x463c13['id']:null;if(!_0x45f6dc&&this['diff']&&this['diff']['newRevisionId']===_0x3fba0f&&this['diff']['oldRevisionId']===_0x17b3ef)return Promise['resolve']();this['isReady']=!0x1,this['activeView']=null,this['activeChange']=null,this['diff']=new c(_0x3fba0f,_0x17b3ef);const _0x4165ee=this['_getRevisionsRange'](_0x23106e,_0x463c13,!0x0)['map'](_0x2f4504=>this['_utils']['loadRevisionData'](_0x2f4504,this['adapter']));return _0x4165ee['push'](new Promise(_0x30a92e=>{setTimeout(_0x30a92e,0x14);})),Promise['all'](_0x4165ee)['then'](()=>{if(!this['isEnabled'])return;this['_cleanUp']();const _0xe90cac=this['_getDiff'](_0x3fba0f,_0x17b3ef);for(const _0x3711d2 of _0xe90cac['changes'])this['_changeIdToChange']['set'](_0x3711d2['id'],_0x3711d2);this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x379996=>{for(const _0x33a480 of this['editor']['model']['document']['getRootNames']())_0x379996['detachRoot'](_0x33a480);for(const _0x4097b6 of Object['keys'](_0xe90cac['model'])){const _0x9cc671=_0x379996['addRoot'](_0x4097b6);for(const _0x8cc04e of Object['keys'](_0xe90cac['attributes'][_0x4097b6]))_0x379996['setAttribute'](_0x8cc04e,_0xe90cac['attributes'][_0x4097b6][_0x8cc04e],_0x9cc671);_0x379996['insert'](_0xe90cac['model'][_0x4097b6],_0x9cc671,0x0);}}),this['diff']['_setChanges'](this['_sortAndFilterDiffChanges'](_0xe90cac['changes'])),this['isReady']=!0x0;})['catch'](_0xaa5842=>{console['error'](_0xaa5842),this['_cleanUp'](),_0x55bef2&&(this['diff']=_0x55bef2),this['isReady']=!0x0;});}['addRevisionData'](_0x197688,_0x15196a){const _0x5e3470=this['repository']['createRevision'](_0x197688);return _0x5e3470['on']('_update',(_0x5c1ab9,_0x5927cb,_0x7a1e63)=>_0x15196a(_0x5927cb,_0x7a1e63,_0x5e3470)),this['repository']['addRevision'](_0x5e3470),_0x5e3470;}['_cleanUp'](){this['activeChange']=null,this['_cleanMarkers'](),this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=null,this['_changeIdToChange']['clear'](),this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x4761aa=>{for(const _0x6e8091 of this['editor']['model']['document']['getRootNames']())_0x4761aa['detachRoot'](_0x6e8091);});}['_sortAndFilterDiffChanges'](_0x4471c9){const _0x3145c8=[],_0x5a8633=new Map();for(const _0x551bb8 of this['editor']['model']['document']['getRootNames']()){const _0xa3612e=this['editor']['editing']['view']['getDomRoot'](_0x551bb8);if(!_0xa3612e)continue;const _0x2b84eb=_0xa3612e['getClientRects']()['item'](0x0);_0x2b84eb&&(_0x3145c8['push'](_0x551bb8),_0x5a8633['set'](_0x551bb8,_0x2b84eb));}return _0x3145c8['sort']((_0xb7f2ae,_0x6f0d55)=>{const _0x5045de=_0x5a8633['get'](_0xb7f2ae),_0x3153a8=_0x5a8633['get'](_0x6f0d55);return _0x5045de['y']-_0x3153a8['y']||_0x5045de['x']-_0x3153a8['x'];}),(_0x4471c9=_0x4471c9['filter'](_0x3c4d81=>_0x3145c8['includes'](_0x3c4d81['rootName'])))['sort']((_0x2159e2,_0x58a901)=>_0x3145c8['indexOf'](_0x2159e2['rootName'])-_0x3145c8['indexOf'](_0x58a901['rootName'])),_0x4471c9;}['_makeTape'](_0xecc0a){const _0x309bd1=Array['from'](_0xecc0a['markers'])['filter'](([_0x53a14a,_0x198839])=>_0x53a14a['startsWith']('revision:')&&!_0x198839['isCollapsed']),_0x2b4383=Array['from'](this['editor']['model']['createRangeIn'](_0xecc0a)['getWalker']({'singleCharacters':!0x0}));if(0x0!=_0x309bd1['length'])for(const _0x4680de of _0x2b4383){const [_0x30c58c,_0x5cf893]=_0x309bd1[0x0],[,_0x274777,_0x4f96f9]=_0x30c58c['split'](':');if(_0x5cf893['end']['isEqual'](_0x4680de['nextPosition'])&&_0x309bd1['shift'](),(_0x4680de['previousPosition']['isEqual'](_0x5cf893['start'])||_0x4680de['previousPosition']['isAfter'](_0x5cf893['start']))&&('insertion'==_0x274777?_0x4680de['isAdded']={'userId':_0x4f96f9}:'deletion'==_0x274777&&(_0x4680de['isRemoved']={'userId':_0x4f96f9})),0x0==_0x309bd1['length'])break;}return _0x2b4383;}['_refreshStartEndIndex'](_0x5d2696){const _0x20e318=new Map();for(let _0x4de539=0x0;_0x4de539<_0x5d2696['length'];_0x4de539++)'text'===_0x5d2696[_0x4de539]['type']?(_0x5d2696[_0x4de539]['item']['startIndex']=_0x4de539,_0x5d2696[_0x4de539]['item']['endIndex']=_0x4de539):('elementStart'===_0x5d2696[_0x4de539]['type']?_0x5d2696[_0x4de539]['item']['startIndex']=_0x4de539:'elementEnd'===_0x5d2696[_0x4de539]['type']&&(_0x5d2696[_0x4de539]['item']['endIndex']=_0x4de539),_0x20e318['set'](_0x5d2696[_0x4de539]['id'],_0x4de539));for(const _0x4a5113 of _0x20e318['values']())'elementStart'===_0x5d2696[_0x4a5113]['type']?_0x5d2696[_0x4a5113]['item']['endIndex']=_0x20e318['get'](_0x5d2696[_0x4a5113]['pairId']):'elementEnd'===_0x5d2696[_0x4a5113]['type']&&(_0x5d2696[_0x4a5113]['item']['startIndex']=_0x20e318['get'](_0x5d2696[_0x4a5113]['pairId']));}['_processTape'](_0x509bfe){for(let _0x1cdec2=0x0;_0x1cdec2<_0x509bfe['length'];_0x1cdec2++){if('elementStart'===_0x509bfe[_0x1cdec2]['type'])_0x509bfe[_0x1cdec2]['item']['startIndex']=_0x1cdec2;else{if('elementEnd'===_0x509bfe[_0x1cdec2]['type']){_0x509bfe[_0x1cdec2]['item']['endIndex']=_0x1cdec2;const _0x196339=_0x509bfe[_0x1cdec2]['item']['startIndex'];_0x509bfe[_0x196339]['pairId']=_0x509bfe[_0x1cdec2]['id'],_0x509bfe[_0x1cdec2]['pairId']=_0x509bfe[_0x196339]['id'];}else _0x509bfe[_0x1cdec2]['item']['startIndex']=_0x1cdec2,_0x509bfe[_0x1cdec2]['item']['endIndex']=_0x1cdec2,_0x509bfe[_0x1cdec2]['pairId']=null;}_0x509bfe[_0x1cdec2]['markersStart']||(_0x509bfe[_0x1cdec2]['markersStart']=[],_0x509bfe[_0x1cdec2]['markersEnd']=[]);}}['_markInsertions'](_0x44f4c4,_0x35fff0){const _0x4598c0=_0x44f4c4['filter'](_0x3790f5=>!_0x3790f5['isAdded']);for(let _0x5be7ad=0x0;_0x5be7ad<_0x35fff0['length'];_0x5be7ad++)_0x35fff0[_0x5be7ad]['isAdded']&&(_0x4598c0[_0x5be7ad]['isAdded']=_0x35fff0[_0x5be7ad]['isAdded']);}['_getDiff'](_0x3f0c68,_0x550ad8=null){const _0x3df6f0=this['repository']['getRevision'](_0x3f0c68),_0x4214cc=_0x550ad8?this['repository']['getRevision'](_0x550ad8):null,_0x4f55d2=this['_getRevisionsRange'](_0x3df6f0,_0x4214cc),_0x466893=_0x4f55d2[_0x4f55d2['length']-0x1],_0x54889f=new Map(),_0x36947e={'model':{},'attributes':{},'changes':[]},_0x32f163=new Set(),_0x4bf9db=new Map();for(let _0xbde911=_0x4f55d2['length']-0x1;_0xbde911>=0x0;_0xbde911--){const _0x50e64b=_0x4f55d2[_0xbde911];for(const _0x362ba5 of Object['keys'](_0x50e64b['diffData']))if(_0x50e64b['diffData'][_0x362ba5]['attachChange']){const _0x22d94b=_0x50e64b['diffData'][_0x362ba5]['attachChange'];_0x22d94b['isAttached']?(_0x32f163['add'](_0x362ba5),_0x4bf9db['has'](_0x362ba5)&&_0x4bf9db['get'](_0x362ba5)['userId']==_0x22d94b['userId']?_0x4bf9db['delete'](_0x362ba5):_0x4bf9db['set'](_0x362ba5,_0x22d94b)):_0x4bf9db['has'](_0x362ba5)?(_0x32f163['delete'](_0x362ba5),_0x4bf9db['delete'](_0x362ba5)):(_0x32f163['add'](_0x362ba5),_0x4bf9db['set'](_0x362ba5,_0x22d94b));}else _0x32f163['add'](_0x362ba5);}for(const _0x2c1d71 of _0x32f163){const _0x2eeba0=_0x4bf9db['has'](_0x2c1d71)&&!_0x4bf9db['get'](_0x2c1d71)['isAttached'];let _0x13bc0b=_0x2eeba0?_0x4f55d2['length']-0x1:0x0;const _0x9425bb=_0x2eeba0?-0x1:0x1;for(;_0x4f55d2[_0x13bc0b];){const _0x3c0249=_0x4f55d2[_0x13bc0b];if(_0x3c0249['diffData'][_0x2c1d71]){const _0x33d04d=_0x2eeba0?_0x3c0249['diffData'][_0x2c1d71]['attributesBefore']:_0x3c0249['diffData'][_0x2c1d71]['attributesAfter'];_0x36947e['attributes'][_0x2c1d71]=_0x33d04d?_0x4dbdf7(_0x33d04d):{};break;}_0x13bc0b+=_0x9425bb;}}for(const _0x3dbc8a of _0x4f55d2){_0x3dbc8a['model']={};for(const _0x5c0213 of _0x3dbc8a['authors'])_0x54889f['set'](_0x5c0213['id'],_0x5c0213);for(const _0xe9dec6 of _0x32f163){const _0x4104e9=_0x3dbc8a['diffData'][_0xe9dec6]?_0x3dbc8a['diffData'][_0xe9dec6]['insertions']:'[]',_0x1722ac=_0x3dbc8a['diffData'][_0xe9dec6]?_0x3dbc8a['diffData'][_0xe9dec6]['deletions']:'[]';_0x3dbc8a['model'][_0xe9dec6]={'insertions':this['_utils']['_makeModelFromViewString'](_0x4104e9),'deletions':this['_utils']['_makeModelFromViewString'](_0x1722ac)};}}for(const _0x2961bd of _0x32f163){let _0x5e6d15=null,_0x2cadd5=0x0;const _0x20dec9=new Map(Array['from'](_0x3df6f0['model'][_0x2961bd]['insertions']['markers'])['filter'](([_0x5ecd79])=>!_0x5ecd79['startsWith']('revision:')));let _0x585d03=0x0;for(const _0x12cd1d of _0x4f55d2){const _0x25dcb8=this['_makeTape'](_0x12cd1d['model'][_0x2961bd]['insertions']);_0x12cd1d==_0x3df6f0?(_0x5e6d15=_0x25dcb8,_0x2cadd5=_0x5e6d15['length'],_0x5e6d15['forEach'](_0x45822a=>{_0x45822a['id']=_0x585d03++;}),this['_processTape'](_0x5e6d15)):this['_markInsertions'](_0x5e6d15,_0x25dcb8);const _0x1bb6b9=_0x5e6d15['filter'](_0x4a674d=>!_0x4a674d['isAdded'])['map'](_0x436a51=>_0x436a51['id']);let _0x54a8fd=0x0;const _0x5d75d2=this['_makeTape'](_0x12cd1d['model'][_0x2961bd]['deletions']);_0x5d75d2['forEach'](_0x2b4240=>{_0x2b4240['isRemoved']?_0x2b4240['id']=_0x2cadd5++:_0x2b4240['id']=_0x1bb6b9[_0x54a8fd++];}),this['_processTape'](_0x5d75d2),this['_setDistance'](_0x5e6d15,'isAdded'),this['_setDistance'](_0x5d75d2,'isRemoved'),_0x12cd1d==_0x3df6f0&&this['_markMarkers'](_0x5e6d15,_0x20dec9),_0x5e6d15=this['_joinTapes'](_0x5e6d15,_0x5d75d2),this['_refreshStartEndIndex'](_0x5e6d15),this['_setDistance'](_0x5e6d15,'isRemoved');}_0x5e6d15=_0x5e6d15['filter'](_0x403a73=>!(_0x403a73['isAdded']&&_0x403a73['isRemoved']));const _0xde03be=new Map(_0x466893['model'][_0x2961bd]['deletions']['markers']),_0x1a75e8=new Set(_0x20dec9['keys']());for(const _0x2f9eef of _0xde03be['keys']())_0x1a75e8['delete'](_0x2f9eef);this['_markSuggestions'](_0x5e6d15,_0x1a75e8),this['_fixObsoleteTags'](_0x5e6d15),_0x5e6d15=this['_removeMissingPairs'](_0x5e6d15),_0x5e6d15=this['_markMismatchedRemovedTags'](_0x5e6d15),_0x5e6d15=this['_removeUnsupportedChanges'](_0x5e6d15);const {root:_0x37f56e,changes:_0x24dec8}=this['_makeModelFromTape'](_0x5e6d15,_0x54889f,_0x2961bd);_0x36947e['model'][_0x2961bd]=_0x37f56e;const _0x408337=_0x4bf9db['get'](_0x2961bd);if(_0x408337){const _0x11000f=_0x54889f['get'](_0x408337['userId']),_0xd16f78=new r({'author':_0x11000f,'type':_0x408337['isAttached']?'add':'remove','data':{'isOnRoot':!0x0},'createdAt':new Date(),'rootName':_0x2961bd});_0x24dec8['unshift'](_0xd16f78),_0x36947e['attributes'][_0x2961bd]['revisionHistoryAttachChange']=_0xd16f78['id'];}_0x36947e['changes']=_0x36947e['changes']['concat'](_0x24dec8);}return _0x36947e;}['_markMarkers'](_0x5bfdb1,_0x4f0a47){for(let _0x3e54b5=0x0;_0x3e54b5<_0x5bfdb1['length'];_0x3e54b5++)for(const [_0x2de637,_0xd6fc36]of _0x4f0a47)!_0xd6fc36['isCollapsed']&&_0xd6fc36['start']['isEqual'](_0x5bfdb1[_0x3e54b5]['previousPosition'])&&_0x5bfdb1[_0x3e54b5]['markersStart']['push'](_0x2de637),_0xd6fc36['end']['isEqual'](_0x5bfdb1[_0x3e54b5]['nextPosition'])&&_0x5bfdb1[_0x3e54b5]['markersEnd']['push'](_0x2de637);}['_joinTapes'](_0x132c93,_0x3f3050){let _0x802f0b=[],_0x371c8f=0x0,_0x32ad58=0x0;for(;_0x371c8f<_0x132c93['length']||_0x32ad58<_0x3f3050['length'];){const _0x19f72f=_0x132c93[_0x371c8f]||{},_0x46d2c4=_0x3f3050[_0x32ad58]||{};if(_0x19f72f['id']==_0x46d2c4['id'])_0x371c8f++,_0x32ad58++,_0x802f0b['push'](_0x19f72f);else{if(_0x46d2c4['isRemoved']&&_0x19f72f['isAdded']){const {commonTape:_0x2c326a,iEnd:_0x9be006,jEnd:_0x1685df}=this['_threeWayMerge'](_0x132c93,_0x371c8f,_0x3f3050,_0x32ad58);_0x802f0b=_0x802f0b['concat'](_0x2c326a),_0x371c8f=_0x9be006,_0x32ad58=_0x1685df;}else _0x46d2c4['isRemoved']?(_0x32ad58++,_0x802f0b['push'](_0x46d2c4)):(_0x371c8f++,_0x802f0b['push'](_0x19f72f));}}return _0x802f0b;}['_markSuggestions'](_0x3752b2,_0x3a0afd){const _0x39ab18=[];for(let _0x437f59=0x0;_0x437f59<_0x3752b2['length'];_0x437f59++){for(let _0x2b233e=0x0;_0x2b233e<_0x3752b2[_0x437f59]['markersStart']['length'];_0x2b233e++){const _0x23d767=_0x3752b2[_0x437f59]['markersStart'][_0x2b233e];if(!_0x3a0afd['has'](_0x23d767))continue;const {group:_0x5f2ac8,type:_0x146f2a,authorId:_0x492d81}=_0x3f0928(_0x23d767);'revision-suggestion'!=_0x5f2ac8||'insertion'!=_0x146f2a&&'deletion'!=_0x146f2a||(_0x39ab18['unshift']({'type':_0x146f2a,'name':_0x23d767,'userId':_0x492d81}),_0x3752b2[_0x437f59]['markersStart']['splice'](_0x2b233e,0x1),_0x2b233e--);}_0x158947(_0x3752b2[_0x437f59]);for(let _0x56b005=0x0;_0x56b005<_0x3752b2[_0x437f59]['markersEnd']['length'];_0x56b005++){const _0x24111e=_0x3752b2[_0x437f59]['markersEnd'][_0x56b005];if(!_0x3a0afd['has'](_0x24111e))continue;const {group:_0x138c10,type:_0x38116e}=_0x3f0928(_0x24111e);if('revision-suggestion'!=_0x138c10||'insertion'!=_0x38116e&&'deletion'!=_0x38116e)continue;_0x3752b2[_0x437f59]['markersEnd']['splice'](_0x56b005,0x1),_0x56b005--;const _0x8ac08a=_0x39ab18['findIndex'](_0x586a3a=>_0x586a3a['name']==_0x24111e);_0x8ac08a>-0x1&&_0x39ab18['splice'](_0x8ac08a,0x1);}}function _0x3f0928(_0x3e2400){const _0x5d7acd=_0x3e2400['split'](':');return{'group':_0x5d7acd[0x0],'type':_0x5d7acd[0x1],'subType':_0x5d7acd['length']>=0x5?_0x5d7acd[0x2]:null,'id':_0x5d7acd['length']<0x5?_0x5d7acd[0x2]:_0x5d7acd[0x3],'authorId':_0x5d7acd['length']<0x5?_0x5d7acd[0x3]:_0x5d7acd[0x4],'markerCount':0x6==_0x5d7acd['length']?_0x5d7acd[0x5]:null};}function _0x158947(_0x1cd483){for(let _0x450176=0x0;_0x450176<_0x39ab18['length'];_0x450176++){if(_0x1cd483['isAdded']&&'insertion'==_0x39ab18[_0x450176]['type'])return _0x1cd483['isAddSuggestion']=_0x39ab18[_0x450176],void delete _0x1cd483['isAdded'];if(!_0x1cd483['isAdded']&&!_0x1cd483['isRemoved']&&'deletion'==_0x39ab18[_0x450176]['type'])return void(_0x1cd483['isRemoveSuggestion']=_0x39ab18[_0x450176]);}}}['_setDistance'](_0x413a05,_0x42d055){let _0x17e6cd=0x0,_0x1eac30=!0x1;const _0xe6d70c=new Map();for(const _0x582cdb of _0x413a05)_0x582cdb[_0x42d055]?_0x1eac30&&(_0x17e6cd++,_0x1eac30=!0x1):(_0x17e6cd++,_0x1eac30=!0x0),_0xe6d70c['set'](_0x582cdb['id'],_0x17e6cd);for(let _0x2e8673=0x0;_0x2e8673<_0x413a05['length'];_0x2e8673++){if('isRemoved'==_0x42d055&&_0x413a05[_0x2e8673]['isAdded']||'isAdded'==_0x42d055&&_0x413a05[_0x2e8673]['isRemoved'])continue;if('text'==_0x413a05[_0x2e8673]['type']){_0x413a05[_0x2e8673]['distance']=0x0;continue;}const _0x279ff6=_0xe6d70c['get'](_0x413a05[_0x2e8673]['pairId']),_0x2201a5=_0xe6d70c['get'](_0x413a05[_0x2e8673]['id']);_0x413a05[_0x2e8673]['distance']=_0x279ff6-_0x2201a5;}}['_getRevisionsRange'](_0x3ebe62,_0x290d66,_0x43beec=!0x1){const _0x23dd8f=[];let _0x4f7772=this['repository']['getIndex'](_0x3ebe62),_0x23432b=this['repository']['getIndex'](_0x290d66);for(-0x1==_0x23432b&&(_0x23432b=this['repository']['_revisions']['length'],_0x43beec=!0x1);_0x4f7772<_0x23432b;)_0x23dd8f['push'](this['repository']['getRevision'](_0x4f7772)),_0x4f7772++;return _0x43beec&&_0x23dd8f['push'](this['repository']['getRevision'](_0x4f7772)),_0x23dd8f;}['_threeWayMerge'](_0x426f45,_0x17b346,_0x43aa02,_0x24ff01){const _0xa85513=this['editor']['model']['schema'];let _0x3de9ff=_0x17b346;for(;_0x426f45[_0x3de9ff]&&_0x426f45[_0x3de9ff]['isAdded'];)_0x3de9ff++;let _0x52b0c7=_0x24ff01;for(;_0x43aa02[_0x52b0c7]&&_0x43aa02[_0x52b0c7]['isRemoved'];)_0x52b0c7++;_0x4520a9(_0x426f45,_0x17b346,_0x3de9ff),_0x4520a9(_0x43aa02,_0x24ff01,_0x52b0c7);const _0x344d00=_0x43aa02['slice'](_0x24ff01,_0x52b0c7)['concat'](_0x426f45['slice'](_0x17b346,_0x3de9ff));return _0x344d00['sort']((_0x3cc78a,_0x6a573b)=>_0x3cc78a['side']!=_0x6a573b['side']?_0x3cc78a['side']-_0x6a573b['side']:_0x3cc78a['level']!=_0x6a573b['level']?_0x3cc78a['level']-_0x6a573b['level']:_0x3cc78a['distance']!=_0x6a573b['distance']?_0x6a573b['distance']-_0x3cc78a['distance']:!!_0x3cc78a['isAdded']!=!!_0x6a573b['isAdded']?-0x1==_0x3cc78a['side']||0x0==_0x3cc78a['side']?_0x3cc78a['isAdded']?-0x1:0x1:_0x3cc78a['isAdded']?0x1:-0x1:_0x3cc78a['index']-_0x6a573b['index']),{'commonTape':_0x344d00,'iEnd':_0x3de9ff,'jEnd':_0x52b0c7};function _0x4520a9(_0x365ce9,_0x21a41a,_0x20f3c5){let _0x1cfab0=-0x1,_0x447de4=Number['POSITIVE_INFINITY'],_0x3dd51a=!0x0;for(let _0x5823ff=_0x21a41a;_0x5823ff<_0x20f3c5;_0x5823ff++)if(_0xa85513['isInline'](_0x365ce9[_0x5823ff]['item'])||(_0x3dd51a=!0x1),_0x365ce9[_0x5823ff]['item']['startIndex']<_0x21a41a&&(_0x1cfab0=_0x5823ff),_0x365ce9[_0x5823ff]['item']['endIndex']>=_0x20f3c5){_0x447de4=_0x5823ff;break;}_0x3dd51a&&(_0x1cfab0=_0x20f3c5-0x1);for(let _0xe3977e=_0x21a41a;_0xe3977e<_0x20f3c5;_0xe3977e++)_0x365ce9[_0xe3977e]['side']=_0xe3977e<=_0x1cfab0?-0x1:_0xe3977e<_0x447de4?0x0:0x1,_0x365ce9[_0xe3977e]['index']=_0xe3977e;let _0x5bd23e=0x0;for(let _0x15c58e=_0x21a41a;_0x15c58e<=_0x1cfab0;_0x15c58e++)0x0==_0x365ce9[_0x15c58e]['distance']?_0x365ce9[_0x15c58e]['level']=_0x5bd23e:(_0x5bd23e++,_0x365ce9[_0x15c58e]['level']=_0x5bd23e,_0x5bd23e++);for(let _0xd90076=_0x21a41a;_0xd90076<_0x20f3c5;_0xd90076++)0x0==_0x365ce9[_0xd90076]['side']&&(_0x365ce9[_0xd90076]['level']=_0x5bd23e);_0x5bd23e=0x0;for(let _0x46cfde=_0x20f3c5-0x1;_0x46cfde>=_0x447de4;_0x46cfde--)0x0==_0x365ce9[_0x46cfde]['distance']?_0x365ce9[_0x46cfde]['level']=_0x5bd23e:(_0x5bd23e--,_0x365ce9[_0x46cfde]['level']=_0x5bd23e,_0x5bd23e--);}}['_fixObsoleteTags'](_0x5d9653){const _0x3133c5=new Map(),_0x228705=this['editor']['model']['schema'];for(let _0xcd14e4=0x1;_0xcd14e4<_0x5d9653['length'];_0xcd14e4++){let _0x3f35a6,_0x4e1ab6,_0x20b8b1;const _0xdd2993=_0x5d9653[_0xcd14e4],_0x57a2cc=_0x5d9653[_0xcd14e4-0x1];if('text'==_0xdd2993['type'])continue;if(_0xdd2993['type']!=_0x57a2cc['type'])continue;if(!_0x228705['isBlock'](_0x57a2cc['item'])||_0x228705['isLimit'](_0x57a2cc['item']))continue;if(!_0x228705['isBlock'](_0xdd2993['item'])||_0x228705['isLimit'](_0xdd2993['item']))continue;if((_0x5d9653[_0xcd14e4]['isAdded']||_0x5d9653[_0xcd14e4]['isAddSuggestion'])&&_0x5d9653[_0xcd14e4-0x1]['isRemoved'])_0x3f35a6=_0x5d9653[_0xcd14e4],_0x4e1ab6=_0x5d9653[_0xcd14e4-0x1],_0x20b8b1=_0xcd14e4-0x1;else{if(!_0x5d9653[_0xcd14e4]['isRemoved']||!_0x5d9653[_0xcd14e4-0x1]['isAdded']&&!_0x5d9653[_0xcd14e4-0x1]['isAddSuggestion'])continue;_0x3f35a6=_0x5d9653[_0xcd14e4-0x1],_0x4e1ab6=_0x5d9653[_0xcd14e4],_0x20b8b1=_0xcd14e4;}const _0x1c8f1f=_0x3f35a6['level']==_0x4e1ab6['level'],_0x1c54ef=Math['abs'](_0x3f35a6['level'])<Math['abs'](_0x4e1ab6['level'])&&0x0==_0x4e1ab6['distance'];(_0x1c8f1f||_0x1c54ef)&&(_0x3133c5['set'](_0x4e1ab6['id'],_0x3f35a6['id']),_0x5d9653['splice'](_0x20b8b1,0x1),_0xcd14e4--,_0x3f35a6['isAdded']=!0x1);}for(let _0x3df9f1=0x0;_0x3df9f1<_0x5d9653['length'];_0x3df9f1++)_0x3133c5['has'](_0x5d9653[_0x3df9f1]['pairId'])&&(_0x5d9653[_0x3df9f1]['pairId']=_0x3133c5['get'](_0x5d9653[_0x3df9f1]['pairId']));}['_removeMissingPairs'](_0xdd4b78){const _0x1ec90e=new Set(_0xdd4b78['map'](_0x5ee1a2=>_0x5ee1a2['id']));for(let _0x158061=0x0;_0x158061<_0xdd4b78['length'];_0x158061++)_0x1ec90e['has'](_0xdd4b78[_0x158061]['pairId'])||0x0==_0xdd4b78[_0x158061]['distance']||(_0xdd4b78[_0x158061]['isIncorrect']=!0x0);return _0xdd4b78['filter'](_0x296c1c=>!_0x296c1c['isIncorrect']);}['_markMismatchedRemovedTags'](_0x50739d){const _0x5f5cee=new Set();for(let _0x1ef216=0x0;_0x1ef216<_0x50739d['length'];_0x1ef216++){if(_0x5f5cee['has'](_0x50739d[_0x1ef216]['id'])&&_0x50739d[_0x1ef216]['isRemoved']&&(_0x50739d[_0x1ef216]['isIncorrect']=!0x0),_0x50739d[_0x1ef216]['isIncorrect'])continue;if(0x0==_0x50739d[_0x1ef216]['distance'])continue;if('elementStart'!=_0x50739d[_0x1ef216]['type'])continue;if(null==_0x50739d[_0x1ef216]['pairId'])continue;let _0x5c5f3b=_0x1ef216+0x1,_0x68c595=0x0;for(;_0x50739d[_0x5c5f3b]['id']!=_0x50739d[_0x1ef216]['pairId'];)'elementStart'==_0x50739d[_0x5c5f3b]['type']?_0x68c595++:'elementEnd'==_0x50739d[_0x5c5f3b]['type']&&_0x68c595--,_0x5c5f3b++;if(0x0!=_0x68c595){if(_0x50739d[_0x1ef216]['isRemoved'])_0x50739d[_0x1ef216]['isIncorrect']=!0x0;else{for(;_0x5c5f3b!=_0x1ef216;)_0x50739d[_0x5c5f3b]['isRemoved']&&0x0!=_0x50739d[_0x5c5f3b]['distance']&&(_0x50739d[_0x5c5f3b]['isIncorrect']=!0x0,_0x5f5cee['add'](_0x50739d[_0x5c5f3b]['pairId'])),_0x5c5f3b--;}}}return _0x50739d['filter'](_0xe62c13=>!_0xe62c13['isIncorrect']);}['_removeUnsupportedChanges'](_0x3fa082){const _0x43f748=this['editor']['model']['schema'];for(let _0x1f17f8=0x0;_0x1f17f8<_0x3fa082['length'];_0x1f17f8++){if(!(_0x3fa082[_0x1f17f8]['isAdded']||_0x3fa082[_0x1f17f8]['isAddSuggestion']||_0x3fa082[_0x1f17f8]['isRemoved']||_0x3fa082[_0x1f17f8]['isRemoveSuggestion']))continue;if(0x0==_0x3fa082[_0x1f17f8]['distance'])continue;const _0x482602=_0x3fa082[_0x1f17f8]['item'];_0x43f748['isBlock'](_0x482602)||_0x43f748['isLimit'](_0x482602)||(_0x3fa082[_0x1f17f8]['isAdded']&&delete _0x3fa082[_0x1f17f8]['isAdded'],_0x3fa082[_0x1f17f8]['isAddSuggestion']&&delete _0x3fa082[_0x1f17f8]['isAddSuggestion'],_0x3fa082[_0x1f17f8]['isRemoveSuggestion']&&delete _0x3fa082[_0x1f17f8]['isRemoveSuggestion'],_0x3fa082[_0x1f17f8]['isRemoved']&&(_0x3fa082[_0x1f17f8]['isIncorrect']=!0x0));}return _0x3fa082['filter'](_0x597625=>!_0x597625['isIncorrect']);}['_makeModelFromTape'](_0x2bd10b,_0x2f3838,_0x78bb86){const _0x6d89ea=new vt(),_0x1c2ed4=[],_0x1df030=new Map(),_0x43138c=this['editor']['model'],_0x35d489=_0x43138c['schema'],_0xa19a53=[_0x6d89ea],_0x51f3ae={},_0x2f8845={'isAdded':[],'isRemoved':[],'isAddSuggestion':[],'isRemoveSuggestion':[]};let _0x4dc062=null;const _0x31d934=[0x0];for(let _0x2a66a4=0x0;_0x2a66a4<_0x2bd10b['length'];_0x2a66a4++)if('elementStart'===_0x2bd10b[_0x2a66a4]['type']){_0x2bd10b[_0x2a66a4]['previousPosition']=_0x43138c['createPositionFromPath'](_0x6d89ea,_0x31d934);const _0x3e01c9=new ut(_0x2bd10b[_0x2a66a4]['item']['name'],_0x2bd10b[_0x2a66a4]['item']['getAttributes']());_0xa19a53[0x0]['_appendChild'](_0x3e01c9),_0x31d934['push'](0x0),_0xa19a53['unshift'](_0x3e01c9),_0x2bd10b[_0x2a66a4]['nextPosition']=_0x43138c['createPositionFromPath'](_0x6d89ea,_0x31d934);}else'elementEnd'===_0x2bd10b[_0x2a66a4]['type']?(_0xa19a53['shift'](),_0x2bd10b[_0x2a66a4]['previousPosition']=_0x43138c['createPositionFromPath'](_0x6d89ea,_0x31d934),_0x31d934['pop'](),_0x31d934[_0x31d934['length']-0x1]++,_0x2bd10b[_0x2a66a4]['nextPosition']=_0x43138c['createPositionFromPath'](_0x6d89ea,_0x31d934)):(_0x2bd10b[_0x2a66a4]['previousPosition']=_0x43138c['createPositionFromPath'](_0x6d89ea,_0x31d934),_0x4dc062?_0x4dc062['_data']+=_0x2bd10b[_0x2a66a4]['item']['data']:_0x4dc062=new gt(_0x2bd10b[_0x2a66a4]['item']['data'],_0x2bd10b[_0x2a66a4]['item']['getAttributes']()),_0x2bd10b[_0x2a66a4+0x1]&&'text'===_0x2bd10b[_0x2a66a4+0x1]['type']&&_0xdd137b(_0x4dc062,_0x2bd10b[_0x2a66a4+0x1]['item'])||(_0xa19a53[0x0]['_appendChild'](_0x4dc062),_0x4dc062=null),_0x31d934[_0x31d934['length']-0x1]+=_0x2bd10b[_0x2a66a4]['item']['offsetSize'],_0x2bd10b[_0x2a66a4]['nextPosition']=_0x43138c['createPositionFromPath'](_0x6d89ea,_0x31d934));for(let _0x34bbc4=0x0;_0x34bbc4<_0x2bd10b['length'];_0x34bbc4++){const _0x536592=_0x2bd10b[_0x34bbc4]['previousPosition'],_0x3d9dea=_0x2bd10b[_0x34bbc4]['nextPosition'];for(const _0x32221f of _0x2bd10b[_0x34bbc4]['markersStart'])_0x1df030['set'](_0x32221f,{'start':_0x536592,'end':null});_0x30fe40('isRemoveSuggestion',_0x34bbc4,_0x536592,_0x3d9dea),_0x30fe40('isAddSuggestion',_0x34bbc4,_0x536592,_0x3d9dea),_0x30fe40('isRemoved',_0x34bbc4,_0x536592,_0x3d9dea),_0x30fe40('isAdded',_0x34bbc4,_0x536592,_0x3d9dea);for(const _0x192c80 of _0x2bd10b[_0x34bbc4]['markersEnd']){const _0x262532=_0x1df030['get'](_0x192c80);_0x262532?_0x262532['end']=_0x3d9dea:_0x1df030['set'](_0x192c80,{'start':_0x3d9dea,'end':_0x3d9dea});}}for(const [_0x43a334,_0x455fbd]of _0x1df030){const _0x80ba22=this['editor']['model']['createRange'](_0x455fbd['start'],_0x455fbd['end']);_0x6d89ea['markers']['set'](_0x43a334,_0x80ba22);}return _0x1c2ed4['sort']((_0x505a16,_0x411a0e)=>{const _0x5a5af6=_0x6d89ea['markers']['get']('revision:'+_0x505a16['id']),_0x5bee43=_0x6d89ea['markers']['get']('revision:'+_0x411a0e['id']);return _0x5a5af6['start']['isBefore'](_0x5bee43['start'])?-0x1:_0x5a5af6['start']['isAfter'](_0x5bee43['start'])?0x1:_0x5a5af6['end']['isBefore'](_0x5bee43['end'])?-0x1:_0x5a5af6['end']['isAfter'](_0x5bee43['end'])?0x1:'add'===_0x505a16['type']?-0x1:0x1;}),{'root':_0x6d89ea,'changes':_0x1c2ed4};function _0x30fe40(_0x1f3a62,_0x548718,_0x572d8e,_0x1b8455){const _0x284fe9=!!_0x2bd10b[_0x548718][_0x1f3a62],_0x116618=_0x284fe9?_0x2bd10b[_0x548718][_0x1f3a62]['userId']:null,_0x5cdaaf=_0x548718===_0x2bd10b['length']-0x1,_0x16f321=_0x2f8845[_0x1f3a62][0x0],_0x1798ea=_0x35d489['isObject'](_0x2bd10b[_0x548718]['item']);!_0x51f3ae[_0x1f3a62]&&_0x284fe9?_0x51f3ae[_0x1f3a62]={'start':_0x572d8e,'tapeItem':_0x2bd10b[_0x548718],'userId':_0x116618,'type':_0x1f3a62}:_0x51f3ae[_0x1f3a62]&&!_0x284fe9?(_0x51f3ae[_0x1f3a62]['end']=_0x572d8e,_0x13c6ed(_0x51f3ae[_0x1f3a62]),_0x51f3ae[_0x1f3a62]=null):_0x51f3ae[_0x1f3a62]&&_0x284fe9&&_0x51f3ae[_0x1f3a62]['userId']!==_0x116618&&(_0x51f3ae[_0x1f3a62]['end']=_0x572d8e,_0x16f321&&_0x16f321['userId']===_0x51f3ae[_0x1f3a62]['userId']||_0x13c6ed(_0x51f3ae[_0x1f3a62]),_0x51f3ae[_0x1f3a62]={'start':_0x572d8e,'tapeItem':_0x2bd10b[_0x548718],'userId':_0x116618,'type':_0x1f3a62}),_0x51f3ae[_0x1f3a62]&&_0x1798ea&&('elementStart'!==_0x2bd10b[_0x548718]['type']||_0x16f321&&_0x16f321['userId']===_0x116618||_0x2f8845[_0x1f3a62]['unshift']({'userId':_0x116618,'object':_0x2bd10b[_0x548718]['item'],'change':_0x51f3ae[_0x1f3a62]}),'elementEnd'===_0x2bd10b[_0x548718]['type']&&_0x16f321&&_0x16f321['object']===_0x2bd10b[_0x548718]['item']&&(_0x2f8845[_0x1f3a62]['shift'](),_0x51f3ae[_0x1f3a62]=_0x16f321['change'])),_0x51f3ae[_0x1f3a62]&&_0x5cdaaf&&(_0x51f3ae[_0x1f3a62]['end']=_0x1b8455,_0x13c6ed(_0x51f3ae[_0x1f3a62]),_0x51f3ae[_0x1f3a62]=null);}function _0x13c6ed({start:_0x1d5a90,end:_0x31d7be,tapeItem:_0x13b560,userId:_0x482b24,type:_0x2481ce}){const _0xc63c60=_0x13b560['item'],_0x17bf9c=_0x43138c['schema']['isBlock'](_0xc63c60)&&!_0x43138c['schema']['isLimit'](_0xc63c60),_0xf6a720=_0x1d5a90['nodeAfter']==_0x31d7be['parent']&&_0x31d7be['isAtStart'];if(_0x17bf9c&&_0xf6a720)return;const _0xa605ed=_0x43138c['createRange'](_0x1d5a90,_0x31d7be),_0x55fb3c=_0x2f3838['get'](_0x482b24),_0x1ed7f5=new r({'author':_0x55fb3c,'type':'isAdded'==_0x2481ce||'isAddSuggestion'==_0x2481ce?'add':'remove','data':{'isSuggestion':'isAddSuggestion'==_0x2481ce||'isRemoveSuggestion'==_0x2481ce},'createdAt':new Date(),'rootName':_0x78bb86});_0x1c2ed4['push'](_0x1ed7f5),_0x6d89ea['markers']['set']('revision:'+_0x1ed7f5['id'],_0xa605ed);}function _0xdd137b(_0x196330,_0x16a414){const _0x374fb9=_0x196330['getAttributes'](),_0x2d3d64=_0x16a414['getAttributes']();for(const _0x3cb3dc of _0x374fb9){if(_0x3cb3dc[0x1]!==_0x16a414['getAttribute'](_0x3cb3dc[0x0]))return!0x1;_0x2d3d64['next']();}return _0x2d3d64['next']()['done'];}}['_setConversion'](){this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision','view':_0x59970e=>{const _0x52bddb=_0x59970e['markerName']['split'](':')[0x1],_0x5e13f7=this['_getChangeFromId'](_0x52bddb);if(!_0x5e13f7)return null;const _0x5debda='add'==_0x5e13f7['type']?'insertion':'deletion',_0x3a579c=['ck-suggestion-marker','ck-suggestion-marker-'+_0x5debda];return _0x5e13f7['data']['isSuggestion']&&_0x3a579c['push']('ck-suggestion-marker-'+_0x5debda+'-new'),this['activeChange']==_0x5e13f7&&_0x3a579c['push']('ck-suggestion-marker--active'),{'classes':_0x3a579c,'attributes':{'data-change-id':_0x52bddb}};}}),this['editor']['conversion']['for']('upcast')['add'](_0x140284=>{_0x140284['on']('element:pre',(_0x4bc49b,_0x468352,_0x37d10b)=>{const _0x118dd7=_0x468352['viewItem']['getChild'](0x0);if(!_0x118dd7||!_0x118dd7['is']('element','code'))return;if(!_0x37d10b['consumable']['consume'](_0x118dd7,{'attributes':['vid_start','vid_end']}))return;const _0x1beba2=_0x468352['modelRange']['start']['nodeAfter'];_0x37d10b['writer']['setAttribute']('vid_start',_0x118dd7['getAttribute']('vid_start'),_0x1beba2),_0x37d10b['writer']['setAttribute']('vid_end',_0x118dd7['getAttribute']('vid_end'),_0x1beba2);},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['add'](_0x8df8a2=>{_0x8df8a2['on']('element',(_0x5658f3,_0x390762,_0x5a2d77)=>{if(!_0x5a2d77['consumable']['consume'](_0x390762['viewItem'],{'attributes':['vid_start','vid_end']}))return;if(_0x390762['modelRange']['isCollapsed'])return;const _0x4c936a=_0x390762['modelRange']['start']['nodeAfter'];_0x4c936a['hasAttribute']('vid_start')||_0x4c936a['hasAttribute']('vid')||(_0x5a2d77['writer']['setAttribute']('vid_start',_0x390762['viewItem']['getAttribute']('vid_start'),_0x4c936a),_0x5a2d77['writer']['setAttribute']('vid_end',_0x390762['viewItem']['getAttribute']('vid_end'),_0x4c936a));},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['elementToAttribute']({'view':{'name':'span','attributes':{'vid':!0x0}},'model':{'key':'vid','value':_0x2fc5a4=>_0x2fc5a4['getAttribute']('vid')}}),this['editor']['model']['schema']['on']('checkAttribute',(_0x5e34fb,[,_0x4e91cf])=>{['vid_start','vid_end','vid']['includes'](_0x4e91cf)&&(_0x5e34fb['return']=!0x0,_0x5e34fb['stop']());},{'priority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x25eded=>{_0x25eded['on']('attribute:vid',(_0x50cfac,_0x3b401f,_0x52df49)=>{if('\x20'!=_0x3b401f['item']['data']||_0x3b401f['item']['parent']['maxOffset']>0x1)return;if(!_0x52df49['consumable']['consume'](_0x3b401f['item'],_0x50cfac['name']))return;const _0x21aa52=_0x52df49['writer'],_0x4ad819=_0x52df49['mapper']['toViewRange'](_0x3b401f['range']);_0x21aa52['wrap'](_0x4ad819,_0x21aa52['createAttributeElement']('span'));});}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',function(_0x2d222c){const _0x5b840b=_0x2d222c['plugins']['get']('RevisionViewer');return(_0x245854,_0x4bbc99,_0x385245)=>{const _0x50bb87=_0x4bbc99['markerName']['split'](':')[0x1],_0x208359=_0x5b840b['_getChangeFromId'](_0x50bb87);if(!_0x208359)return null;const _0x5ec730='add'==_0x208359['type']?'split':'merge';if(!_0x385245['consumable']['test'](_0x4bbc99['markerRange'],_0x245854['name']))return;const _0xc3dd22=_0x4bbc99['markerRange']['getWalker'](),_0x18b513=_0x4bbc99['markerRange']['start'],_0x4bbe0e=_0x2d222c['model']['schema'];let _0x57ccf3=null,_0x2e50ee=null,_0x2cebc2=!0x1,_0x1ca540=!0x1;for(const _0x48ee2d of _0xc3dd22){const _0x1cc25e=_0x48ee2d['item'];_0x2cebc2=_0x2cebc2||_0x4bbe0e['isContent'](_0x1cc25e);const _0x5d370d=_0x385245['mapper']['toViewElement'](_0x1cc25e);if(_0x5d370d&&_0x5d370d['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x48ee2d['type']&&(_0x4bbe0e['isBlock'](_0x1cc25e)&&!_0x4bbe0e['isLimit'](_0x1cc25e)&&(_0x1cc25e['nextSibling']||_0x18b513['isAtEnd']?_0x57ccf3&&_0x57ccf3['parent']==_0x1cc25e||(_0x57ccf3=_0x1cc25e,_0xdbcbf1(_0x48ee2d['previousPosition']),_0x1ca540=!0x0):_0x2e50ee=_0x2e50ee||_0x48ee2d['previousPosition']));}function _0xdbcbf1(_0x2c3c92){const _0x5c2836=_0x385245['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x5ec730}),_0x4bac0c=_0x385245['mapper']['toViewPosition'](_0x2c3c92);_0x208359['data']['isSuggestion']&&_0x385245['writer']['addClass']('ck-suggestion-marker-'+_0x5ec730+'-new',_0x5c2836),_0x5b840b['activeChange']==_0x208359&&_0x385245['writer']['addClass']('ck-suggestion-marker--active',_0x5c2836),_0x385245['writer']['insert'](_0x4bac0c,_0x5c2836),_0x385245['mapper']['bindElementToMarker'](_0x5c2836,_0x4bbc99['markerName']);}_0x2cebc2||_0x1ca540||!_0x2e50ee||_0xdbcbf1(_0x2e50ee);};}(this['editor']),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision',(_0x2432f9,_0x2d80e9,_0x570706)=>{const _0x1ea61a=_0x570706['mapper']['markerNameToElements'](_0x2d80e9['markerName']);if(_0x1ea61a){for(const _0x1d2755 of _0x1ea61a)(_0x1d2755['hasClass']('ck-suggestion-marker-split')||_0x1d2755['hasClass']('ck-suggestion-marker-merge'))&&(_0x570706['mapper']['unbindElementFromMarkerName'](_0x1d2755,_0x2d80e9['markerName']),_0x570706['writer']['remove'](_0x1d2755));}},{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',(_0x38f0a1,_0x4f5050,_0x5c8c14)=>{const _0x5cd0fa=_0x4f5050['markerName']['split'](':')[0x1],_0x20b5c9=this['_getChangeFromId'](_0x5cd0fa);if(!_0x20b5c9)return null;const _0x5c93b2='add'==_0x20b5c9['type']?'split':'merge';if(_0x5c8c14['consumable']['test'](_0x4f5050['markerRange'],_0x38f0a1['name']))for(const _0x17e6a0 of _0x4f5050['markerRange']['getItems']()){if(!_0x17e6a0['is']('element','softBreak'))continue;const _0x2db7dc=_0x5c8c14['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x5c93b2}),_0x14cfed=_0x5c8c14['mapper']['toViewPosition'](this['editor']['model']['createPositionBefore'](_0x17e6a0));_0x20b5c9['data']['isSuggestion']&&_0x5c8c14['writer']['addClass']('ck-suggestion-marker-'+_0x5c93b2+'-new',_0x2db7dc),this['activeChange']==_0x20b5c9&&_0x5c8c14['writer']['addClass']('ck-suggestion-marker--active',_0x2db7dc),_0x5c8c14['writer']['insert'](_0x14cfed,_0x2db7dc),_0x5c8c14['mapper']['bindElementToMarker'](_0x2db7dc,_0x4f5050['markerName']);}},{'priority':'high'}),this['editor']['model']['document']['on']('change',()=>{this['editor']['editing']['view']['change'](_0xca10cd=>{for(const _0x1405b9 of this['editor']['model']['document']['getRootNames']()){const _0x334fc1=this['editor']['model']['document']['getRoot'](_0x1405b9),_0x35d365=this['editor']['editing']['view']['document']['getRoot'](_0x1405b9);if(_0x35d365){const _0x56a540=_0x334fc1['getAttribute']('revisionHistoryAttachChange');if(_0xca10cd['removeAttribute']('data-change-id',_0x35d365),_0xca10cd['removeClass']('ck-revision-history-root-add',_0x35d365),_0xca10cd['removeClass']('ck-revision-history-root-remove',_0x35d365),_0xca10cd['removeClass']('ck-revision-history-root--active',_0x35d365),_0x56a540){const _0x2d185a=this['_getChangeFromId'](_0x56a540);if(!_0x2d185a)return null;_0xca10cd['setAttribute']('data-change-id',_0x56a540,_0x35d365),_0xca10cd['addClass']('ck-revision-history-root-'+_0x2d185a['type'],_0x35d365),this['activeChange']==_0x2d185a&&_0xca10cd['addClass']('ck-revision-history-root--active',_0x35d365);}}}});}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'comment','model':_0x3fce4f=>'revision-comment:'+_0x3fce4f,'converterPriority':'highest'}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'suggestion','model':_0x1784d7=>'revision-suggestion:'+_0x1784d7,'converterPriority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision-suggestion','view':_0x2623f4=>({'name':'suggestion:'+_0x2623f4,'group':'revision-suggestion'}),'converterPriority':'highest'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision-suggestion','view':_0xec1e48=>{const _0xc1c023=_0xec1e48['markerName']['split'](':')[0x1];return'insertion'!=_0xc1c023&&'deletion'!=_0xc1c023?null:{'classes':['ck-suggestion-preview-marker','ck-suggestion-preview-marker-'+_0xc1c023]};}}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:deletion',X(this['editor'],'merge'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:insertion',X(this['editor'],'split'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision-suggestion',(_0x27ae72,_0x4592aa,_0xa15a9d)=>{const _0x34bca4=_0xa15a9d['mapper']['markerNameToElements'](_0x4592aa['markerName']);if(_0x34bca4){for(const _0x488b0a of _0x34bca4)_0x488b0a['is']('uiElement')&&(_0xa15a9d['mapper']['unbindElementFromMarkerName'](_0x488b0a,_0x4592aa['markerName']),_0xa15a9d['writer']['remove'](_0x488b0a));}},{'priority':'high'});}['_getChangeFromId'](_0x5e140d){return this['_changeIdToChange']['get'](_0x5e140d);}['_getViewForChange'](_0x8af1bd){return this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=new Q(this['editor']['locale'],_0x8af1bd),this['_changeView'];}['_initInteractions'](){this['editor']['model']['document']['selection']['observeMarkers']('revision'),this['on']('change:activeView',(_0xb90226,_0x41c28f,_0x2dccbf,_0x4165d6)=>{_0x4165d6&&this['_balloon']['remove'](_0x4165d6),_0x2dccbf&&(this['_balloon']['add']({'view':_0x2dccbf,'stackId':'revisionHistoryLabel','position':{'target':()=>{const _0x3994a4=this['editor']['editing'],_0x488a9a=this['_getChangeFromId'](_0x2dccbf['changeId']);let _0x571d99;if(_0x488a9a['data']['isOnRoot']){const _0x16a78f=_0x3994a4['view']['getDomRoot'](_0x488a9a['rootName']);_0x571d99=Array['from'](_0x16a78f['getClientRects']());}else{const _0x2864c9=this['editor']['model']['markers']['get']('revision:'+_0x2dccbf['changeId']);_0x571d99=Array['from'](_0x3994a4['mapper']['markerNameToElements'](_0x2864c9['name']))['map'](_0x225703=>_0x3994a4['view']['domConverter']['mapViewToDom'](_0x225703))['map'](_0x5bb6f0=>Array['from'](_0x5bb6f0['getClientRects']()))['flat']();}if(!this['_activeViewTarget'])return _0x571d99[0x0];return _0x571d99['find'](_0xbd912a=>_0xbd912a['top']-0x3<=this['_activeViewTarget']['y']&&_0xbd912a['bottom']+0x3>=this['_activeViewTarget']['y']&&_0xbd912a['left']-0x3<=this['_activeViewTarget']['x']&&_0xbd912a['right']+0x3>=this['_activeViewTarget']['x'])||_0x571d99[0x0];}}}),this['_balloon']['showStack']('revisionHistoryLabel'));}),this['on']('change:activeChange',(_0x36840f,_0x41fa11,_0x4e66ce,_0x2beb9e)=>{this['activeView']=_0x4e66ce?this['_getViewForChange'](_0x4e66ce):null,this['editor']['model']['change'](()=>{const _0xf88a8=this['editor']['editing'];_0x2beb9e&&(_0x2beb9e['data']['isOnRoot']?_0xf88a8['view']['change'](_0x510100=>{_0x510100['removeClass']('ck-revision-history-root--active',_0xf88a8['view']['document']['getRoot'](_0x2beb9e['rootName']));}):_0xf88a8['reconvertMarker']('revision:'+_0x2beb9e['id'])),_0x4e66ce&&(_0x4e66ce['data']['isOnRoot']?_0xf88a8['view']['change'](_0x2f2fca=>{_0x2f2fca['addClass']('ck-revision-history-root--active',_0xf88a8['view']['document']['getRoot'](_0x4e66ce['rootName']));}):_0xf88a8['reconvertMarker']('revision:'+_0x4e66ce['id']));});}),this['listenTo'](this['editor']['editing']['view']['document'],'mouseover',(_0x2a8606,_0x179e3a)=>{if(this['activeChange'])return;const _0x211de1=this['_findChangeIdFromDomTarget'](_0x179e3a['target']),_0xd52585=this['_changeIdToChange']['get'](_0x211de1);_0xd52585?(this['_activeViewTarget']={'x':_0x179e3a['domEvent']['x'],'y':_0x179e3a['domEvent']['y']},this['activeView']=this['_getViewForChange'](_0xd52585)):(this['_activeViewTarget']=null,this['activeView']=null);}),this['listenTo'](this['editor']['editing']['view']['document'],'mousedown',(_0x4eb5c7,_0x1bb5fb)=>{const _0x31419e=this['_findChangeIdFromDomTarget'](_0x1bb5fb['target']),_0x4a13b9=this['_changeIdToChange']['get'](_0x31419e);_0x4a13b9?(this['_activeViewTarget']={'x':_0x1bb5fb['domEvent']['x'],'y':_0x1bb5fb['domEvent']['y']},_0x4a13b9===this['activeChange']?this['_balloon']['updatePosition']():this['activeChange']=_0x4a13b9):(this['_activeViewTarget']=null,this['activeChange']=null);});}['_findChangeIdFromDomTarget'](_0x5ab0ab){do{const _0x2bbe65=_0x5ab0ab['getAttribute']('data-change-id');if(_0x2bbe65)return _0x2bbe65;_0x5ab0ab=_0x5ab0ab['parent'];}while(_0x5ab0ab);return null;}['_cleanMarkers'](){this['editor']['model']['change'](_0x43e5a9=>{for(const _0x1abfbb of this['editor']['model']['markers'])_0x43e5a9['removeMarker'](_0x1abfbb);});}}function X(_0x23527e,_0x29bb6e){return(_0x1da8f7,_0x112a3e,_0x335126)=>{if(!_0x335126['consumable']['test'](_0x112a3e['markerRange'],_0x1da8f7['name']))return;const _0x26c633=_0x112a3e['markerRange']['getWalker'](),_0x28a2e9=_0x112a3e['markerRange']['start'],_0x51352f=_0x23527e['model']['schema'];let _0x2b40cb=null,_0x4ffaff=null,_0x490a45=!0x1,_0x1db828=!0x1;for(const _0x530201 of _0x26c633){const _0x482501=_0x530201['item'];_0x490a45=_0x490a45||_0x51352f['isContent'](_0x482501);const _0x489606=_0x335126['mapper']['toViewElement'](_0x482501);if(_0x489606&&_0x489606['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x530201['type']&&(_0x51352f['isBlock'](_0x482501)&&!_0x51352f['isLimit'](_0x482501)&&(_0x482501['nextSibling']||_0x28a2e9['isAtEnd']?_0x2b40cb&&_0x2b40cb['parent']==_0x482501||(_0x2b40cb=_0x482501,_0x117e71(_0x530201['previousPosition']),_0x1db828=!0x0):_0x4ffaff=_0x4ffaff||_0x530201['previousPosition']));}function _0x117e71(_0x5a3e5c){const _0x46dada=_0x335126['mapper']['toViewPosition'](_0x5a3e5c),_0xf947da=_0x335126['writer']['createUIElement']('span',{'class':'ck-suggestion-preview-marker-'+_0x29bb6e});_0x335126['writer']['insert'](_0x46dada,_0xf947da),_0x335126['mapper']['bindElementToMarker'](_0xf947da,_0x112a3e['markerName']);}_0x490a45||_0x1db828||!_0x4ffaff||_0x117e71(_0x4ffaff);};}class mt extends _0x4e2556{constructor(_0x2cf3b6){super(_0x2cf3b6);const _0x3e9158=_0x2cf3b6['plugins']['get'](m);this['affectsData']=!0x1,this['listenTo'](_0x3e9158,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x3e9158,'change:isEnabled',()=>this['refresh']());}['execute'](){const _0x4b93b3=this['editor'],_0x3880d4=_0x4b93b3['plugins']['get'](m),_0x380fba=_0x3880d4['isReady']?_0x3880d4['diff']['newRevisionId']:null;_0x4b93b3['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x380fba);}['refresh'](){const {isReady:_0x5c0806,isEnabled:_0x8df273,repository:_0x28ac1f,diff:_0x4f07e6}=this['editor']['plugins']['get'](m),_0x59c0fa=_0x4f07e6&&_0x28ac1f['getLaterVisibleRevision'](_0x4f07e6['newRevisionId']);this['isEnabled']=_0x5c0806&&_0x8df273&&Boolean(_0x59c0fa);}}class wt extends _0x4e2556{['_step'];constructor(_0x3e8252,{direction:_0xe4957b}){super(_0x3e8252);const _0x15f0b0=_0x3e8252['plugins']['get'](m);this['affectsData']=!0x1,this['_step']='forward'===_0xe4957b?0x1:-0x1,this['listenTo'](_0x15f0b0,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x15f0b0,'change:isEnabled',()=>this['refresh']()),this['listenTo'](_0x15f0b0,'change:activeChange',()=>this['refresh']());}['execute'](){const _0x507a8f=this['editor'],_0x231b01=_0x507a8f['plugins']['get'](m),{isNavigationMode:_0x8e4c6a,currentChangeNumber:_0x441864}=_0x231b01;let _0x3da299;if(_0x231b01['activeChange']=_0x8e4c6a?_0x231b01['diff']['changes']['get'](_0x441864+this['_step']):_0x231b01['diff']['changes']['first'],_0x231b01['activeChange']['data']['isOnRoot'])_0x3da299=_0x507a8f['editing']['view']['getDomRoot'](_0x231b01['activeChange']['rootName']);else{const _0x2c4bde=_0x507a8f['model']['markers']['get']('revision:'+_0x231b01['activeChange']['id']);_0x3da299=_0x56d34c(_0x507a8f['editing'],_0x2c4bde);}_0x5c8233({'target':_0x3da299,'viewportOffset':0x28});}['refresh'](){const {isNavigationMode:_0x48f58a,currentChangeNumber:_0x387bc5,numberOfChanges:_0xda8e19,isReady:_0x185f7b,isEnabled:_0x5a26b1}=this['editor']['plugins']['get'](m);this['isEnabled']=!!(_0x5a26b1&&_0x185f7b&&_0xda8e19)&&(!_0x48f58a||(0x1===this['_step']?_0x387bc5<_0xda8e19-0x1:_0x387bc5>0x0));}}class _i extends ts{constructor(_0x185c0e){super(_0x185c0e);const _0x36d848=this['bindTemplate'],_0x165414=new te(_0x185c0e),_0x2e3234=new te(_0x185c0e);this['set']('isNavigationMode',!0x1),this['set']('isReady',!0x1),this['set']('currentChangeNumber',0x0),this['set']('numberOfChanges',0x0),this['set']('isForwardNavigationEnabled',!0x1),this['set']('isBackwardNavigationEnabled',!0x1),this['bind']('_isStatusLabelVisible')['to'](this,'isReady',this,'numberOfChanges',(_0x1ab3c7,_0x5bd718)=>_0x1ab3c7&&_0x5bd718>0x0),this['bind']('_statusText')['to'](this,'isReady',this,'currentChangeNumber',this,'numberOfChanges',this,'isNavigationMode',(_0x30cd6e,_0xdb5d1a,_0x8a873b,_0x59caa4)=>{if(!_0x30cd6e)return g(_0x185c0e,'Loading...');if(!_0x8a873b)return g(_0x185c0e,'No\x20changes');const _0x4e0ada=g(_0x185c0e,'NUMBER_OF_CHANGES',_0x8a873b);return _0x59caa4?g(_0x185c0e,'X_OF_Y_CHANGES',[_0xdb5d1a+0x1,_0x8a873b]):_0x4e0ada;}),_0x165414['set']({'label':g(_0x185c0e,'Show\x20previous\x20change'),'tooltip':!0x0,'icon':_0x1dd0dd}),_0x2e3234['set']({'label':g(_0x185c0e,'Show\x20next\x20change'),'tooltip':!0x0,'icon':_0x2464b9}),_0x165414['bind']('isEnabled')['to'](this,'isBackwardNavigationEnabled'),_0x2e3234['bind']('isEnabled')['to'](this,'isForwardNavigationEnabled'),_0x165414['on']('execute',()=>this['fire']('execute','backward')),_0x2e3234['on']('execute',()=>this['fire']('execute','forward')),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-revision-history-ui','ck-revision-history-ui__changes-navigation']},'children':[{'tag':'span','attributes':{'class':['ck-revision-history-ui__changes-navigation__wrapper']},'children':[{'tag':'span','attributes':{'class':['ck-revision-history-ui__changes-navigation__label',_0x36d848['if']('_isStatusLabelVisible','ck-hidden',_0xb94ab9=>!_0xb94ab9)]},'children':[{'text':_0x36d848['to']('isNavigationMode',_0x4d807a=>_0x4d807a?g(_0x185c0e,'EDIT_X_OF_Y_REVISIONS')+':\x20':g(_0x185c0e,'Total')+':\x20')}]},{'text':_0x36d848['to']('_statusText')}]},new _0x32da21(),{'tag':'div','attributes':{'class':['ck-revision-history-ui__changes-navigation__navigation']},'children':[_0x165414,_0x2e3234]}]});}}const le='ck-editor__editable__loading-overlay';class ge extends _0x1aaf30{static get['pluginName'](){return'RevisionViewerLoadingOverlay';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['show'](){const _0x2a79ee=this['editor']['editing']['view'];_0x2a79ee['change'](_0x4801bc=>{for(const _0x460236 of _0x2a79ee['document']['roots'])_0x4801bc['addClass'](le,_0x460236);});}['hide'](){const _0x3968d4=this['editor']['editing']['view'];_0x3968d4['change'](_0x1c0e0c=>{for(const _0x196b8a of _0x3968d4['document']['roots'])_0x1c0e0c['removeClass'](le,_0x196b8a);});}}class R extends _0x1aaf30{static get['pluginName'](){return'RevisionViewerUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[m,ge];}['init'](){const _0x4a77ef=this['editor'],_0x5ef176=_0x4a77ef['plugins']['get'](m),_0x4606da=_0x4a77ef['plugins']['get'](ge);_0x4a77ef['ui']['componentFactory']['add']('exitToEditing',_0x55ef76=>{const _0x3c7fd0=new te(_0x55ef76);return _0x3c7fd0['set']({'label':g(_0x55ef76,'Back\x20to\x20editing'),'icon':_0x5c9b99,'withText':!0x0,'tooltip':!0x0,'class':'ck-revision-history-ui__back-to-editing'}),this['listenTo'](_0x3c7fd0,'execute',()=>{_0x4a77ef['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}),_0x3c7fd0;}),_0x4a77ef['ui']['componentFactory']['add']('restoreRevision',_0x473232=>{const _0x4356bd=new te(_0x473232);return _0x4356bd['set']({'label':g(_0x473232,'Restore\x20this\x20revision'),'withText':!0x0,'tooltip':!0x0}),_0x4356bd['bind']('isEnabled')['to'](_0x4a77ef['commands']['get']('restoreRevision')),this['listenTo'](_0x4356bd,'execute',()=>_0x4a77ef['execute']('restoreRevision')),_0x4356bd;}),_0x4a77ef['ui']['componentFactory']['add']('changesNavigation',_0x2d6c44=>{const _0x2e645c=new _i(_0x2d6c44),_0x54dafa=_0x4a77ef['commands']['get']('showPreviousChange'),_0x198d2f=_0x4a77ef['commands']['get']('showNextChange');return _0x2e645c['bind']('isBackwardNavigationEnabled')['to'](_0x54dafa,'isEnabled'),_0x2e645c['bind']('isForwardNavigationEnabled')['to'](_0x198d2f,'isEnabled'),_0x2e645c['bind']('isReady','currentChangeNumber','numberOfChanges','isNavigationMode')['to'](_0x5ef176),this['listenTo'](_0x2e645c,'execute',(_0x2caa70,_0x569c45)=>{_0x4a77ef['execute']('forward'===_0x569c45?'showNextChange':'showPreviousChange');}),_0x2e645c;}),_0x4606da['show'](),_0x5ef176['on']('change:isReady',(_0x505125,_0x4f8666,_0x5166f0)=>{_0x5166f0?_0x4606da['hide']():_0x4606da['show']();});}}class at extends _0x21d0c2{['_resizeObserver']=null;constructor(_0x5e112f,_0x5c29ce){super(_0x5e112f,_0x5c29ce);const _0x1dc56a=this['bindTemplate'];this['set']({'label':g(_0x5e112f,'Revision\x20name'),'_tooltipString':''}),this['fieldView']['placeholder']=g(_0x5e112f,'Enter\x20the\x20revision\x20name'),this['extendTemplate']({'tag':'span','attributes':{'class':['ck-revision-history-sidebar__revision-name'],'data-cke-tooltip-text':_0x1dc56a['to']('_tooltipString'),'data-cke-tooltip-position':'s','data-cke-tooltip-class':'ck-tooltip_multi-line'}});}['render'](){super['render'](),this['_resizeObserver']=new nt(this['fieldView']['element'],()=>this['_updateTooltipText']()),this['listenTo'](this['fieldView'],'input',()=>this['_updateTooltipText']());}['destroy'](){super['destroy'](),this['_resizeObserver']&&this['_resizeObserver']['destroy']();}['_updateTooltipText'](){const _0xb98629=this['fieldView']['element'];this['_tooltipString']=_0xb98629['scrollWidth']>_0xb98629['clientWidth']&&_0xb98629['value']||'';}}class si extends ts{constructor(_0x3e9072,_0x57e0a3,_0x6c7c89){super(_0x3e9072);const _0x4c84e8=new _0x5c83c3();_0x4c84e8['set']({'content':_0x3c4811,'viewBox':'0\x200\x2011\x2010'});const _0x5a5c5c=['ck','ck-revision-history-sidebar__revision-author'];_0x6c7c89&&_0x5a5c5c['push']('ck-revision-history-sidebar__revision-author_creator');const _0x5d1050=[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision-author__name'],'title':g(_0x3e9072,_0x6c7c89?'Revision\x20creator':'Revision\x20author')},'children':[_0x4c84e8,_0x57e0a3['name']]}];this['setTemplate']({'tag':'li','attributes':{'class':_0x5a5c5c},'children':_0x5d1050});}}function oi(_0x516a20,_0x5b7c37){const _0x171103=_0x516a20['bindTemplate'],_0x2b1fda=_0x516a20['locale'],_0x1b7a26=_0x3baa9b(_0x2b1fda);_0x1b7a26['panelPosition']='sw';const _0x445a72=function(_0x228694,_0x1b07d1){const _0x1d79ba=function(_0x488611,_0x139e63){const _0x1834aa=_0x488611['locale'],_0x54aa9c={'Compare\x20against\x20selected':g(_0x1834aa,'Compare\x20against\x20selected'),'Name\x20this\x20revision':g(_0x1834aa,'Name\x20this\x20revision'),'Restore\x20this\x20revision':g(_0x1834aa,'Restore\x20this\x20revision')};return _0x139e63['map'](_0x4b89e5=>{const _0x5bd130=_0x54aa9c[_0x4b89e5['name']];return _0x5bd130&&_0x5bd130!==_0x4b89e5['name']&&(_0x4b89e5['name']=_0x5bd130),_0x4b89e5;});}(_0x228694,_0x1b07d1),_0x3d1524=new _0x5f0faf();for(const _0x49fe37 of _0x1d79ba){const _0x5f52ea={'type':'button','model':new to({'label':_0x49fe37['name'],'class':_0x49fe37['class'],'withText':!0x0,'role':'menuitem','_action':_0x49fe37['action']})};_0x5f52ea['model']['bind']('isEnabled')['to'](_0x228694,'isActionsDropdownOpen',_0x55e741=>'function'!=typeof _0x49fe37['isEnabled']||(!_0x55e741||_0x49fe37['isEnabled'](_0x228694))),_0x3d1524['add'](_0x5f52ea);}return _0x3d1524;}(_0x516a20,_0x5b7c37);return _0x516a20['bind']('isActionsDropdownOpen')['to'](_0x1b7a26,'isOpen'),_0x1b7a26['buttonView']['set']({'label':g(_0x2b1fda,'Show\x20more\x20items'),'tooltip':!0x0,'tooltipPosition':'sw','icon':_0x45dd43}),_0x1b7a26['extendTemplate']({'attributes':{'class':['ck-revision-history-sidebar__revision__actions',_0x171103['if']('isActionsDropdownOpen','ck-on')]},'on':{'click':_0x171103['to'](_0x1cf960=>_0x1cf960['stopPropagation']())}}),_0x1b7a26['on']('execute',_0x257435=>{_0x516a20['isReady']&&'function'==typeof _0x257435['source']['_action']&&_0x257435['source']['_action'](_0x516a20);}),_0x11596f(_0x1b7a26,_0x445a72,{'role':'menu'}),_0x1b7a26['listenTo'](_0x516a20,'change:isActionsDropdownOpen',(_0x583077,_0x3ea725,_0xedd763)=>{if(_0xedd763)for(const _0x2649c0 of _0x1b7a26['listView']['items']){const _0x143dad=_0x2649c0['children']['first'],_0x44d063=_0x5b7c37['find'](_0x5c0cf6=>_0x5c0cf6['action']===_0x143dad['_action'])['isVisible'];_0x2649c0['isVisible']=void 0x0===_0x44d063||_0x44d063(_0x516a20);}}),_0x1b7a26;}class hi extends/* #__PURE__ -- @preserve */
26
+ ti(ts){['id'];['revisionNameView'];['revisionActionsView'];['_revision'];['_requireRevisionName'];constructor(_0x5914f0,_0x46d5fa,_0x4c1777,_0x56b60f){super(_0x5914f0);const _0x1202de=this['bindTemplate'],_0x156d53=function(_0x74da23,_0x3855e4){const _0x516a15=Array['from'](_0x3855e4['authors'])['filter'](_0x38e63e=>_0x38e63e!=_0x3855e4['creator']);return _0x3855e4['creator']&&_0x516a15['unshift'](_0x3855e4['creator']),_0x516a15['map'](_0x445e93=>new si(_0x74da23,_0x445e93,_0x445e93==_0x3855e4['creator']));}(_0x5914f0,_0x46d5fa);this['id']=_0x46d5fa['id'],this['_revision']=_0x46d5fa,this['_requireRevisionName']=_0x56b60f,this['bind']('name','createdAt')['to'](_0x46d5fa),this['bind']('_createdAtFormatted')['to'](this,'createdAt',_0x41e878=>{return _0x23f422=_0x5914f0['uiLanguage'],(_0x595cc9=_0x41e878)['toLocaleDateString'](_0x23f422,{'month':'long','day':'numeric'})+',\x20'+_0x595cc9['toLocaleTimeString'](_0x23f422,{'hour':'numeric','minute':'numeric'});var _0x23f422,_0x595cc9;}),this['set']('isSelected',!0x1),this['set']('isHighlighted',!0x1),this['set']('isActionsDropdownOpen',!0x1),this['set']('isReady',!0x1),this['set']('isEnabled',!0x1),this['revisionNameView']=new at(_0x5914f0,_0x1a6c7a),this['revisionNameView']['fieldView']['extendTemplate']({'attributes':{'maxlength':'220'}}),this['revisionNameView']['fieldView']['bind']('value')['to'](this,'name',_0x4555f2=>_0x4555f2||this['_createdAtFormatted']),this['revisionNameView']['bind']('isEnabled')['to'](this,'isSelected',this,'isEnabled',(_0x5f431f,_0xf35c9d)=>_0x5f431f&&_0xf35c9d),this['revisionActionsView']=_0x4c1777&&_0x4c1777['length']?oi(this,_0x4c1777):'',this['revisionActionsView']&&this['revisionActionsView']['bind']('isEnabled')['to'](this),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision-wrapper',_0x1202de['if']('isConfirm','ck-revision-history-sidebar__revision-wrapper_confirmation_visible')]},'children':[{'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision',_0x1202de['if']('isEnabled','ck-disabled',_0x44b436=>!_0x44b436),_0x1202de['if']('isSelected','ck-revision-history-sidebar__revision_selected'),_0x1202de['if']('isHighlighted','ck-revision-history-sidebar__revision_highlighted'),_0x1202de['if']('isActionsDropdownOpen','ck-revision-history-sidebar__actions_dropdown_open')]},'children':[this['revisionNameView'],{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision__date']},'children':[{'text':_0x1202de['to']('_createdAtFormatted')}]},{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__revision__controls-wrapper']},'children':[{'tag':'ul','attributes':{'class':['ck','ck-revision-history-sidebar__revision-authors']},'children':_0x156d53}]},this['revisionActionsView']],'on':{'click':_0x1202de['to'](_0x195aa7=>{_0x195aa7['srcElement']['closest']('.ck-thread__remove-confirm')||this['isReady']&&this['isEnabled']&&this['fire']('select',{'id':this['id']});})}}]});}['render'](){super['render']();const _0x46b222=this['revisionNameView']['fieldView']['element'];this['listenTo'](_0x46b222,'change',()=>{this['_requireRevisionName']&&!_0x46b222['value']||this['fire']('setName',{'id':this['id'],'name':_0x46b222['value']}),_0x46b222['value']||(_0x46b222['value']=this['name']?this['name']:this['_createdAtFormatted']);});}['select'](){this['isSelected']=!0x0;}['deselect'](){this['isSelected']=!0x1;}['highlight'](){this['isHighlighted']=!0x0;}['unhighlight'](){this['isHighlighted']=!0x1;}}function ai(_0x362a4b,_0x18f798){const _0x1619ab=_0x3c368c['fromJSDate'](_0x362a4b)['setLocale'](_0x18f798),_0x18580a=_0x3c368c['local'](),_0x9c024f=_0x18580a['minus']({'days':0x1})['startOf']('day');let _0x5b7d3b,_0x1c51f0;return _0x1619ab['hasSame'](_0x18580a,'day')?(_0x5b7d3b=_0x1619ab['startOf']('day')['toJSDate'](),_0x1c51f0=_0x1619ab['toRelativeCalendar']()):_0x1619ab['hasSame'](_0x9c024f,'day')?(_0x5b7d3b=_0x9c024f['toJSDate'](),_0x1c51f0=_0x1619ab['toRelativeCalendar']()):_0x1619ab['hasSame'](_0x18580a,'week')?(_0x5b7d3b=_0x1619ab['startOf']('week')['toJSDate'](),_0x1c51f0=_0x1619ab['weekdayLong']||''):_0x1619ab['hasSame'](_0x18580a,'year')?(_0x5b7d3b=_0x1619ab['startOf']('month')['toJSDate'](),_0x1c51f0=_0x1619ab['monthLong']||''):(_0x5b7d3b=_0x1619ab['startOf']('year')['toJSDate'](),_0x1c51f0=String(_0x1619ab['year'])),{'startDate':_0x5b7d3b,'localizedPeriodName':_0x1c51f0};}class di extends ts{['startDate'];['revisionViews'];['_revisionActions'];['_requireRevisionName'];constructor(_0x41bf9b,_0x94d0fa,_0x24d661,_0x5efbc0){super(_0x41bf9b);const _0x335e41=ai(_0x94d0fa,this['locale']['uiLanguage'])['localizedPeriodName'];this['startDate']=_0x94d0fa,this['revisionViews']=this['createCollection'](),this['_revisionActions']=_0x24d661,this['_requireRevisionName']=_0x5efbc0,this['revisionViews']['delegate']('select')['to'](this),this['revisionViews']['delegate']('setName')['to'](this),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__time-period']},'children':[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__time-period__label']},'children':[{'text':_0x335e41}]},{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__time-period__revisions']},'children':this['revisionViews']}]});}['addRevision'](_0x433110){const _0x54f131=new hi(this['locale'],_0x433110,this['_revisionActions'],this['_requireRevisionName']);this['revisionViews']['add'](_0x54f131);}['removeRevision'](_0x2cd2ee){const _0x4c8acd=this['revisionViews']['find'](_0x2a164b=>_0x2a164b['id']===_0x2cd2ee['id']);this['revisionViews']['remove'](_0x4c8acd);}}class as extends ts{constructor(_0x53a4bf){super(_0x53a4bf);const _0x2b3827=new _0x5c83c3();_0x2b3827['content']=_0x2aae82,this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset_all','ck-revision-history-sidebar__header']},'children':[_0x2b3827,{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__header__label']},'children':[g(_0x53a4bf,'Revision\x20history')]}]});}}class ni extends ts{['timePeriodViews'];['_revisions'];['_revisionActions'];['_requireRevisionName'];constructor(_0x4f9c20,_0x5e9747,_0x8c5b8b,_0x282f9b){super(_0x4f9c20);const _0x517cd2=this['bindTemplate'];this['timePeriodViews']=this['createCollection'](),this['timePeriodViews']['delegate']('select')['to'](this),this['timePeriodViews']['delegate']('setName')['to'](this),this['_revisions']=_0x5e9747,this['_revisionActions']=_0x8c5b8b,this['_requireRevisionName']=_0x282f9b,this['on']('select',(_0x597762,_0x11be36)=>{this['fire']('revisionSelected',_0x11be36);}),this['on']('setName',(_0x22f856,_0x274d9d)=>{this['fire']('revisionSetName',_0x274d9d);}),this['set']('isEnabled',!0x1),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-rounded-corners','ck-revision-history-sidebar']},'children':[new as(_0x4f9c20),{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__timeline',_0x517cd2['if']('isEnabled','ck-disabled',_0x1f2fb0=>!_0x1f2fb0)]},'children':this['timePeriodViews']}]});}['render'](){super['render']();for(const _0x4904c7 of this['_revisions'])this['_addRevision'](_0x4904c7);this['_revisions']['on']('add',(_0x4eb560,_0x5354b5)=>{this['_addRevision'](_0x5354b5);}),this['_revisions']['on']('remove',(_0x4c082a,_0x43d8b6)=>{this['_removeRevision'](_0x43d8b6);});}get['revisionViews'](){return this['timePeriodViews']['map'](_0x4f08a7=>_0x4f08a7['revisionViews']['map'](_0x598382=>_0x598382))['flat']();}['selectRevision'](_0x4b7580){for(const _0x486dcd of this['revisionViews'])_0x4b7580&&_0x4b7580['id']===_0x486dcd['id']?_0x486dcd['select']():_0x486dcd['deselect']();}['highlightRevisions'](_0x45f93a){for(const _0x3bb45f of this['revisionViews'])_0x45f93a['some'](({id:_0x45ca67})=>_0x45ca67===_0x3bb45f['id'])?_0x3bb45f['highlight']():_0x3bb45f['unhighlight']();}['_addRevision'](_0xeb9bf4){const _0x32323e=ai(_0xeb9bf4['createdAt'],this['locale']['uiLanguage'])['startDate'];let _0x1d0937=this['timePeriodViews']['get'](0x0);_0x1d0937&&_0x1d0937['startDate']['getTime']()===_0x32323e['getTime']()||(_0x1d0937=new di(this['locale'],_0x32323e,this['_revisionActions'],this['_requireRevisionName']),this['timePeriodViews']['add'](_0x1d0937)),_0x1d0937['addRevision'](_0xeb9bf4);}['_removeRevision'](_0x25e8f2){const _0x10b90c=ai(_0x25e8f2['createdAt'],this['locale']['uiLanguage'])['startDate'];this['_getTimePeriodViewByStartDate'](_0x10b90c)['removeRevision'](_0x25e8f2);}['_getTimePeriodViewByStartDate'](_0x68bfcb){return this['timePeriodViews']['find'](_0x15f26f=>_0x15f26f['startDate']['getTime']()===_0x68bfcb['getTime']());}}class d extends _0x1aaf30{['_revisionViewer'];['_revisionsRepository'];['_sidebarView'];static ['defaultRevisionActions']=/* #__PURE__ -- @preserve */
27
27
  ((()=>['compareAgainstSelected','restoreRevision','nameRevision'])());static ['availableRevisionActions']=/* #__PURE__ -- @preserve */
28
- pt();static get['pluginName'](){return'RevisionsSidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[m];}constructor(_0x4ae1ae){super(_0x4ae1ae),this['_revisionViewer']=_0x4ae1ae['plugins']['get'](m),this['_revisionsRepository']=this['_revisionViewer']['repository'],this['_sidebarView']=null;}['init'](){const _0x37e60f=this['_revisionsRepository']['_revisions'],_0x5c34bd=this['_createRevisionActions'](),_0x50481a=this['editor']['config']['get']('revisionHistory.viewerSidebarContainer');this['_sidebarView']=new ni(this['editor']['locale'],_0x37e60f,_0x5c34bd,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',(_0xb30eef,_0x1f59a2)=>{_0x1f59a2['revisionViews']['on']('add',(_0x1aff0c,_0x3eaa9a)=>{_0x3eaa9a['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)),_0x50481a['appendChild'](this['_sidebarView']['element']);}['destroy'](){this['_sidebarView']['element']['remove'](),this['_sidebarView']['destroy']();}['_handleEditorDataReady'](){const _0x36cf6b=this['_revisionsRepository']['getRevision'](0x0);if(_0x36cf6b){const _0x422c79=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x36cf6b['id']);this['_revisionViewer']['compare'](_0x36cf6b,_0x422c79);}}['_handleRevisionSelected'](_0x306928,_0x3a450c){const _0x3bd186=this['_revisionsRepository']['getRevision'](_0x3a450c['id']),_0xc8b594=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x3bd186['id']);this['_revisionViewer']['compare'](_0x3bd186,_0xc8b594);}['_handleRevisionSetName'](_0x159251,_0x5598e1){this['_revisionsRepository']['getRevision'](_0x5598e1['id'])['setName'](_0x5598e1['name']);}['_handleDiffChange'](_0xaf67c9,_0x20a30c,_0x59cbb3){const _0xaa5684=this['_revisionsRepository']['getRevisionsInDiff'](_0x59cbb3);_0xaa5684['length']>0x2?(this['_sidebarView']['highlightRevisions'](_0xaa5684),this['_sidebarView']['selectRevision'](null)):(this['_sidebarView']['highlightRevisions']([]),this['_sidebarView']['selectRevision'](_0xaa5684[0x0]));}['_createRevisionActions'](){const _0x4c1225=this['editor'],_0x3263a8=d['availableRevisionActions'],_0x2b248b=_0x4c1225['config']['get']('revisionHistory.revisionActions')||d['defaultRevisionActions'];if(_0x2b248b['length'])return _0x2b248b['map'](_0x529126=>{const _0x34dc26='string'==typeof _0x529126?Object['assign']({},_0x3263a8[_0x529126]):_0x529126;return _0x34dc26['action']=_0x34dc26['action']['bind'](this,_0x4c1225),_0x34dc26['isVisible']&&(_0x34dc26['isVisible']=_0x34dc26['isVisible']['bind'](this,_0x4c1225)),_0x34dc26;});}}function pt(){return{'compareAgainstSelected':{'name':'Compare\x20against\x20selected','action':({plugins:_0x399645},_0x267a1f)=>{const _0xd00175=_0x399645['get'](m),_0x2cdbe5=_0xd00175['repository'];let _0x1986fd=_0xd00175['diff']['newRevisionId'],_0x4f6fa3=_0x267a1f['id'];_0x2cdbe5['getIndex'](_0x1986fd)>_0x2cdbe5['getIndex'](_0x4f6fa3)&&([_0x1986fd,_0x4f6fa3]=[_0x4f6fa3,_0x1986fd]),_0xd00175['compare'](_0x1986fd,_0x4f6fa3);},'isVisible':({plugins:_0x38ec81},_0x247afe)=>{const _0x45657a=_0x38ec81['get'](m);return!(_0x45657a['repository']['getRevisionsInDiff'](_0x45657a['diff'])['length']>0x2)&&!_0x247afe['isSelected'];}},'restoreRevision':{'name':'Restore\x20this\x20revision','action':(_0x182b30,{id:_0x3f1d84})=>{_0x182b30['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x3f1d84);},'isVisible':({plugins:_0x58cfb2},_0x31ba5d)=>!!_0x58cfb2['get'](m)['repository']['getLaterVisibleRevision'](_0x31ba5d['id'])},'nameRevision':{'name':'Name\x20this\x20revision','action':({plugins:_0x4947f2},{id:_0x246611,revisionNameView:_0x28fca5})=>{const _0x17f491=_0x4947f2['get'](m),_0x2351c6=_0x17f491['repository']['getEarlierVisibleRevision'](_0x246611);_0x17f491['compare'](_0x246611,_0x2351c6),_0x28fca5['focus'](),_0x28fca5['fieldView']['select']();}}};}class tt extends st{['_view'];['_toolbarConfig'];['_elementReplacer'];get['view'](){return this['_view'];}constructor(_0x24d2ed,_0x2e9bc0){super(_0x24d2ed),this['_view']=_0x2e9bc0,this['_toolbarConfig']=et(_0x24d2ed['config']['get']('toolbar')),this['_elementReplacer']=new ot();}get['element'](){return this['view']['element'];}['init'](_0x5d357a){const _0x6b2f19=this['editor'],_0x53176f=this['view'],_0x31bf19=_0x6b2f19['editing']['view'],_0x973c38=_0x53176f['editable'],_0xea7bf2=_0x31bf19['document']['getRoot']();_0x973c38['name']=_0xea7bf2['rootName'],_0x53176f['render']();const _0x38b6f4=_0x973c38['element'];this['setEditableElement'](_0x973c38['name'],_0x38b6f4),_0x53176f['editable']['bind']('isFocused')['to'](this['focusTracker']),_0x31bf19['attachDomRoot'](_0x38b6f4),this['_elementReplacer']['replace'](_0x5d357a,this['element']),this['_initToolbar'](),this['fire']('ready');}['destroy'](){super['destroy']();const _0x2b23c7=this['view'],_0x572314=this['editor']['editing']['view'];this['_elementReplacer']['restore'](),_0x572314['detachDomRoot'](_0x2b23c7['editable']['name']),_0x2b23c7['destroy']();}['_initToolbar'](){const _0x3a0b4c=this['view'];_0x3a0b4c['stickyPanel']['bind']('isActive')['to'](this['focusTracker'],'isFocused'),_0x3a0b4c['stickyPanel']['limiterElement']=_0x3a0b4c['element'],_0x3a0b4c['stickyPanel']['bind']('viewportTopOffset')['to'](this,'viewportOffset',({top:_0x4d626b})=>_0x4d626b),_0x3a0b4c['toolbar']['fillFromConfig'](this['_toolbarConfig'],this['componentFactory']),this['addToolbar'](_0x3a0b4c['toolbar']);}}class it extends rt{['_editable'];['stickyPanel'];['toolbar'];get['editable'](){return this['_editable'];}constructor(_0x3f2fcd,_0x197adf,_0x1dbf8b={}){super(_0x3f2fcd),this['stickyPanel']=new ht(_0x3f2fcd),this['toolbar']=new dt(_0x3f2fcd,{'shouldGroupWhenFull':_0x1dbf8b['shouldToolbarGroupWhenFull']}),this['_editable']=new ct(_0x3f2fcd,_0x197adf);}['render'](){super['render'](),this['stickyPanel']['content']['add'](this['toolbar']),this['top']['add'](this['stickyPanel']),this['main']['add'](this['editable']);}}class w extends/* #__PURE__ -- @preserve */
29
- _0x5055df(_0x5c1f04){['_ui'];get['ui'](){return this['_ui'];}constructor(_0x668e62,_0x5accf7){super(_0x5accf7),this['sourceElement']=_0x668e62,this['model']['document']['createRoot']();const _0x540847=new it(this['locale'],this['editing']['view'],{'shouldToolbarGroupWhenFull':!0x0});this['_ui']=new tt(this,_0x540847);}['destroy'](){return this['updateSourceElement'](),this['ui']['destroy'](),super['destroy']();}static async['create'](_0x3bf4b2,_0x5936ce){const _0x5a1ac4=new this(_0x3bf4b2,_0x5936ce);return await _0x5a1ac4['initPlugins'](),await _0x5a1ac4['ui']['init'](_0x3bf4b2),await _0x5a1ac4['data']['init'](_0x5a1ac4['config']['get']('initialData')||''),_0x5a1ac4['fire']('ready'),_0x5a1ac4;}}const p=['RevisionHistoryUI','RestrictedEditingMode'];class _t extends _0x149b28{['result'];static get['pluginName'](){return'RevisionViewerIntegration';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x4f4085){function _0x434caf(_0x59818d){return _0x59818d['map'](_0x565821=>String['fromCharCode'](_0x565821))['join']('');}super(_0x4f4085),this['result']='end',_0x4f4085[_0x434caf([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x434caf([0x76,0x69,0x65,0x77])][_0x434caf([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x434caf([0x61,0x75,0x74,0x6f]),_0x4f4085[_0x434caf([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x434caf([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x434caf([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x434caf([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x434caf([0x6f,0x6b])});}}class k extends _0x149b28{['_viewerEditor'];static get['pluginName'](){return'RevisionHistory';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[u,f];}constructor(_0x22a2a8){if(super(_0x22a2a8),!this['editor']['config']['get']('revisionHistory'))throw new _0x4676dd('revision-history-missing-configuration',this);this['_viewerEditor']=null,this['set']('isRevisionViewerOpen',!0x1),this['editor']['config']['define']('revisionHistory.showRevisionViewerCallback',_0x4a61a6=>this['_showRevisionViewer']({..._0x4a61a6,'translations':this['editor']['locale']['translations']})),this['editor']['config']['define']('revisionHistory.closeRevisionViewerCallback',_0x3a5c8e=>this['_closeRevisionViewer'](_0x3a5c8e)),this['editor']['config']['define']('revisionHistory.restoreRevisionCallback',_0x238889=>this['_restoreRevision'](_0x238889)),this['editor']['config']['define']('revisionHistory.requireRevisionName',!0x1),this['_enhanceShowRevisionViewerCallback'](),this['_enhanceCloseRevisionViewerCallback']();}set['adapter'](_0x3d8a16){this['editor']['plugins']['get']('RevisionTracker')['adapter']=_0x3d8a16;}get['adapter'](){return this['editor']['plugins']['get']('RevisionTracker')['adapter'];}['addRevisionData'](_0x1131b4){return this['editor']['plugins']['get']('RevisionTracker')['addRevisionData'](_0x1131b4);}['getRevision'](_0x2ce890){return this['editor']['plugins']['get']('RevisionsRepository')['getRevision'](_0x2ce890);}['getRevisions'](_0x2aefea){return this['editor']['plugins']['get']('RevisionsRepository')['getRevisions'](_0x2aefea||{'toJSON':!0x1});}['_getRevisionViewerEditorConfig'](){const _0x4d64bc=this['editor'],_0x4bc25d=_0x38849b(_0x4d64bc,p),_0x78221b=_0x4d64bc['plugins']['get']('RevisionTracker'),_0x5ead80=_0x4d64bc['plugins']['get']('Users')['users'];return _0x4bc25d['toolbar']=['exitToEditing','restoreRevision','changesNavigation'],delete _0x4bc25d['lazyRoots'],(_0x4bc25d['plugins']['push'](_t,m,R,class extends _0x149b28{static get['requires'](){return[m,'Users'];}['init'](){const _0x29d2b4=this['editor']['plugins']['get']('Users');for(const _0x19c9bc of _0x5ead80)_0x19c9bc['isAnonymous']||_0x29d2b4['getUser'](_0x19c9bc['id'])||_0x29d2b4['addUser'](_0x19c9bc);const _0x417eeb=_0x78221b['repository']['getRevisions']();let _0x158710=null;const _0x3cb49c=this['editor']['plugins']['get']('RevisionViewer');_0x3cb49c['adapter']=_0x78221b['adapter'],_0x3cb49c['bind']('isEnabled')['to'](_0x78221b),this['editor']['commands']['get']('restoreRevision')['bind']('isEnabled')['to'](_0x4d64bc,'isReadOnly',_0x384f54=>!_0x384f54);for(const _0x4d4a87 of _0x417eeb){const _0x5d82f0=null===_0x4d4a87['creator'];if(_0x5d82f0&&_0x4d4a87['toVersion']===_0x4d4a87['fromVersion'])continue;const _0x30fd7e=_0x4d4a87['toJSON']();_0x3cb49c['addRevisionData'](_0x30fd7e,(_0x4d0b18,_0x40df68,_0x1cd910)=>{if(_0x5d82f0){if(_0x158710)_0x158710['_update'](_0x4d0b18,_0x40df68);else{if(!_0x40df68){const _0x574cf7=_0x1cd910['toJSON']();_0x574cf7['id']=_0x451426(),_0x78221b['saveRevision'](_0x574cf7,_0x1cd910['toVersion'])['then'](_0x5463c2=>{_0x158710=_0x5463c2;});}}}else _0x4d4a87['_update'](_0x4d0b18,_0x40df68);});}}},d),_0x4bc25d);}['_enhanceShowRevisionViewerCallback'](){const _0x4d18b6=this['editor']['config']['get']('revisionHistory')['showRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.showRevisionViewerCallback',async()=>{this['editor']['enableReadOnlyMode']('revision-history-viewer-opened');const _0x4a1622=this['editor']['plugins']['get']('RevisionTracker');if(this['editor']['plugins']['has']('Autosave')){const _0x1eb4d9=this['editor']['plugins']['get']('Autosave');await _0x1eb4d9['save']();}else await _0x4a1622['update']();if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('Dialog')){const _0x5c4573=this['editor']['plugins']['get']('Dialog');_0x5c4573['isOpen']&&_0x5c4573['hide']();}const _0x4cf10b=this['_getRevisionViewerEditorConfig']();return _0x4d18b6(_0x4cf10b)['then'](_0x36b139=>{return(this['_viewerEditor']=_0x36b139,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'),_0x36b139);})['catch'](_0x9e6de9=>(console['error'](_0x9e6de9),this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),null));});}['_enhanceCloseRevisionViewerCallback'](){const _0x5be9c4=this['editor']['config']['get']('revisionHistory')['closeRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.closeRevisionViewerCallback',()=>(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('DocumentOutline')&&(this['editor']['plugins']['get']('DocumentOutlineUI')['view']['element']['style']['display']=''),this['_viewerEditor']['plugins']['get']('RevisionViewer')['_cleanUp'](),_0x5be9c4(this['_viewerEditor'])['then'](()=>{if(this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),this['_viewerEditor']=null,this['editor']['plugins']['has']('Annotations')){const _0x4ffc83=this['editor']['plugins']['get']('Annotations');_0x4ffc83['refreshVisibility'](),_0x4ffc83['refreshPositioning']();}})));}['_showRevisionViewer'](_0x518ae6){const _0x50c373=this['editor']['config']['get']('revisionHistory.editorContainer'),_0xae1a2d=this['editor']['config']['get']('revisionHistory.viewerContainer'),_0x194825=this['editor']['config']['get']('revisionHistory.viewerEditorElement');return w['create'](_0x194825,_0x518ae6)['then'](_0x53de9d=>(_0xae1a2d['style']['display']='block',_0x50c373['style']['display']='none',this['isRevisionViewerOpen']=!0x0,_0x53de9d));}['_closeRevisionViewer'](_0x323aed){const _0x401746=this['editor']['config']['get']('revisionHistory.editorContainer');return this['editor']['config']['get']('revisionHistory.viewerContainer')['style']['display']='none',_0x401746['style']['display']='',this['isRevisionViewerOpen']=!0x1,_0x323aed['destroy']();}async['_restoreRevision'](_0x5b7759){const _0x41522d=this['editor'],_0x4d9fd3=this['_viewerEditor']['plugins']['get']('RevisionViewer'),_0x59473c=_0x41522d['plugins']['get']('RevisionTracker'),_0x259b85=_0x41522d['plugins']['get']('RevisionHistoryUtils'),_0x10f51f=_0x4d9fd3['repository']['getRevision'](_0x5b7759);let _0x280b9e,_0x5cb54b,_0x1fc12b;try{await _0x259b85['loadRevisionData'](_0x10f51f,this['adapter']),_0x280b9e=_0x259b85['getRevisionDocumentData'](_0x10f51f),_0x5cb54b=_0x259b85['getRevisionRootsAttributes'](_0x10f51f);}catch(_0x1f3c5b){return void console['error'](_0x1f3c5b);}_0x41522d['model']['change'](_0x4fd2e0=>{for(const _0x143870 of Array['from'](_0x41522d['model']['markers']['getMarkersGroup']('restrictedEditingException')))_0x4fd2e0['removeMarker'](_0x143870);}),_0x4d9fd3['isReady']=!0x1,_0x41522d['model']['enqueueChange'](_0x23f048=>{_0x23f048['setSelection'](null),_0x23f048['removeSelectionAttribute'](_0x41522d['model']['document']['selection']['getAttributeKeys']());const _0x2a92bc=Object['keys'](_0x280b9e);for(const _0x3ca3d0 of _0x41522d['model']['document']['roots'])'$graveyard'!=_0x3ca3d0['rootName']&&_0x3ca3d0['isAttached']()&&!_0x2a92bc['includes'](_0x3ca3d0['rootName'])&&_0x23f048['detachRoot'](_0x3ca3d0);for(const _0x397281 of _0x2a92bc){let _0x53a4c4=_0x41522d['model']['document']['getRoot'](_0x397281);_0x53a4c4&&_0x53a4c4['isAttached']()||(_0x53a4c4=_0x23f048['addRoot'](_0x397281));const _0x55a493=_0x5cb54b[_0x397281],_0x3ad2c1=Object['keys'](_0x55a493),_0x1eed79=_0x280b9e[_0x397281];for(const _0x17a89c of _0x53a4c4['getAttributeKeys']())_0x3ad2c1['includes'](_0x17a89c)||_0x23f048['removeAttribute'](_0x17a89c,_0x53a4c4);for(const _0x247cb0 of _0x3ad2c1)_0x23f048['setAttribute'](_0x247cb0,_0x5cb54b[_0x397281][_0x247cb0],_0x53a4c4);_0x23f048['remove'](_0x23f048['createRangeIn'](_0x53a4c4)),_0x23f048['insert'](_0x41522d['data']['parse'](_0x1eed79,_0x53a4c4),_0x53a4c4,0x0);}});const _0x49c7d3=g(_0x41522d['locale'],'Restored');if(_0x10f51f['name'])_0x1fc12b=-0x1==_0x10f51f['name']['indexOf'](_0x49c7d3)?_0x49c7d3+':\x20'+_0x10f51f['name']:_0x10f51f['name'];else _0x1fc12b=_0x49c7d3+':\x20'+(_0x10f51f['createdAt']['toLocaleDateString'](_0x41522d['locale']['uiLanguage'],{'month':'long','day':'numeric'})+',\x20'+_0x10f51f['createdAt']['toLocaleTimeString'](_0x41522d['locale']['uiLanguage'],{'hour':'numeric','minute':'numeric'}));return await _0x59473c['saveRevision']({'name':_0x1fc12b}),_0x4d9fd3['isReady']=!0x0,_0x41522d['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}}export{h as Revision,k as RevisionHistory,f as RevisionHistoryUI,V as RevisionHistoryUtils,u as RevisionTracker,m as RevisionViewer,w as RevisionViewerEditor,ge as RevisionViewerLoadingOverlay,R as RevisionViewerUI,I as RevisionsRepository,d as RevisionsSidebar};
28
+ pt();static get['pluginName'](){return'RevisionsSidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[m];}constructor(_0xabefbb){super(_0xabefbb),this['_revisionViewer']=_0xabefbb['plugins']['get'](m),this['_revisionsRepository']=this['_revisionViewer']['repository'],this['_sidebarView']=null;}['init'](){const _0x236004=this['_revisionsRepository']['_revisions'],_0x59f4d4=this['_createRevisionActions'](),_0x3a7396=this['editor']['config']['get']('revisionHistory.viewerSidebarContainer');this['_sidebarView']=new ni(this['editor']['locale'],_0x236004,_0x59f4d4,this['editor']['config']['get']('revisionHistory.requireRevisionName')),this['_sidebarView']['on']('revisionSelected',this['_handleRevisionSelected']['bind'](this)),this['_sidebarView']['on']('revisionSetName',this['_handleRevisionSetName']['bind'](this)),this['_sidebarView']['bind']('isEnabled')['to'](this['_revisionViewer']),this['_sidebarView']['timePeriodViews']['on']('add',(_0x2f388e,_0x2064a2)=>{_0x2064a2['revisionViews']['on']('add',(_0x5688c5,_0x2c500d)=>{_0x2c500d['bind']('isEnabled','isReady')['to'](this['_revisionViewer']);});}),this['_sidebarView']['render'](),this['listenTo'](this['editor']['data'],'ready',this['_handleEditorDataReady']['bind'](this)),this['listenTo'](this['_revisionViewer'],'change:diff',this['_handleDiffChange']['bind'](this)),_0x3a7396['appendChild'](this['_sidebarView']['element']);}['destroy'](){this['_sidebarView']['element']['remove'](),this['_sidebarView']['destroy']();}['_handleEditorDataReady'](){const _0x1a3e02=this['_revisionsRepository']['getRevision'](0x0);if(_0x1a3e02){const _0x48d440=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x1a3e02['id']);this['_revisionViewer']['compare'](_0x1a3e02,_0x48d440);}}['_handleRevisionSelected'](_0x51352e,_0x1380fc){const _0x39ec26=this['_revisionsRepository']['getRevision'](_0x1380fc['id']),_0x57f315=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x39ec26['id']);this['_revisionViewer']['compare'](_0x39ec26,_0x57f315);}['_handleRevisionSetName'](_0x5e2768,_0x12b5d4){this['_revisionsRepository']['getRevision'](_0x12b5d4['id'])['setName'](_0x12b5d4['name']);}['_handleDiffChange'](_0x57acb8,_0x34d426,_0x810393){const _0x245dc9=this['_revisionsRepository']['getRevisionsInDiff'](_0x810393);_0x245dc9['length']>0x2?(this['_sidebarView']['highlightRevisions'](_0x245dc9),this['_sidebarView']['selectRevision'](null)):(this['_sidebarView']['highlightRevisions']([]),this['_sidebarView']['selectRevision'](_0x245dc9[0x0]));}['_createRevisionActions'](){const _0x2f03af=this['editor'],_0x1d3947=d['availableRevisionActions'],_0x3b8d6c=_0x2f03af['config']['get']('revisionHistory.revisionActions')||d['defaultRevisionActions'];if(_0x3b8d6c['length'])return _0x3b8d6c['map'](_0x45ed3c=>{const _0xeaca4='string'==typeof _0x45ed3c?Object['assign']({},_0x1d3947[_0x45ed3c]):_0x45ed3c;return _0xeaca4['action']=_0xeaca4['action']['bind'](this,_0x2f03af),_0xeaca4['isVisible']&&(_0xeaca4['isVisible']=_0xeaca4['isVisible']['bind'](this,_0x2f03af)),_0xeaca4;});}}function pt(){return{'compareAgainstSelected':{'name':'Compare\x20against\x20selected','action':({plugins:_0x1062c7},_0x10af43)=>{const _0x29cf78=_0x1062c7['get'](m),_0x5e5706=_0x29cf78['repository'];let _0x2ad85e=_0x29cf78['diff']['newRevisionId'],_0x233207=_0x10af43['id'];_0x5e5706['getIndex'](_0x2ad85e)>_0x5e5706['getIndex'](_0x233207)&&([_0x2ad85e,_0x233207]=[_0x233207,_0x2ad85e]),_0x29cf78['compare'](_0x2ad85e,_0x233207);},'isVisible':({plugins:_0x5df2d0},_0x257607)=>{const _0x36b917=_0x5df2d0['get'](m);return!(_0x36b917['repository']['getRevisionsInDiff'](_0x36b917['diff'])['length']>0x2)&&!_0x257607['isSelected'];}},'restoreRevision':{'name':'Restore\x20this\x20revision','action':(_0x14fafc,{id:_0x542110})=>{_0x14fafc['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x542110);},'isVisible':({plugins:_0x1d9f65},_0x327d84)=>!!_0x1d9f65['get'](m)['repository']['getLaterVisibleRevision'](_0x327d84['id'])},'nameRevision':{'name':'Name\x20this\x20revision','action':({plugins:_0x352c2c},{id:_0xb359d6,revisionNameView:_0x140850})=>{const _0x291e74=_0x352c2c['get'](m),_0x43b2c2=_0x291e74['repository']['getEarlierVisibleRevision'](_0xb359d6);_0x291e74['compare'](_0xb359d6,_0x43b2c2),_0x140850['focus'](),_0x140850['fieldView']['select']();}}};}class tt extends st{['_view'];['_toolbarConfig'];['_elementReplacer'];get['view'](){return this['_view'];}constructor(_0xc3f22b,_0x36eee1){super(_0xc3f22b),this['_view']=_0x36eee1,this['_toolbarConfig']=et(_0xc3f22b['config']['get']('toolbar')),this['_elementReplacer']=new ot();}get['element'](){return this['view']['element'];}['init'](_0x91efdb){const _0x17cb19=this['editor'],_0x3b6b08=this['view'],_0x596665=_0x17cb19['editing']['view'],_0x5b0aa5=_0x3b6b08['editable'],_0x52e62b=_0x596665['document']['getRoot']();_0x5b0aa5['name']=_0x52e62b['rootName'],_0x3b6b08['render']();const _0x37c190=_0x5b0aa5['element'];this['setEditableElement'](_0x5b0aa5['name'],_0x37c190),_0x3b6b08['editable']['bind']('isFocused')['to'](this['focusTracker']),_0x596665['attachDomRoot'](_0x37c190),this['_elementReplacer']['replace'](_0x91efdb,this['element']),this['_initToolbar'](),this['fire']('ready');}['destroy'](){super['destroy']();const _0x2cb75e=this['view'],_0x21041f=this['editor']['editing']['view'];this['_elementReplacer']['restore'](),_0x21041f['detachDomRoot'](_0x2cb75e['editable']['name']),_0x2cb75e['destroy']();}['_initToolbar'](){const _0xbf78ea=this['view'];_0xbf78ea['stickyPanel']['bind']('isActive')['to'](this['focusTracker'],'isFocused'),_0xbf78ea['stickyPanel']['limiterElement']=_0xbf78ea['element'],_0xbf78ea['stickyPanel']['bind']('viewportTopOffset')['to'](this,'viewportOffset',({top:_0x22553e})=>_0x22553e),_0xbf78ea['toolbar']['fillFromConfig'](this['_toolbarConfig'],this['componentFactory']),this['addToolbar'](_0xbf78ea['toolbar']);}}class it extends rt{['_editable'];['stickyPanel'];['toolbar'];get['editable'](){return this['_editable'];}constructor(_0x307cb3,_0x14da58,_0x17934d={}){super(_0x307cb3),this['stickyPanel']=new ht(_0x307cb3),this['toolbar']=new dt(_0x307cb3,{'shouldGroupWhenFull':_0x17934d['shouldToolbarGroupWhenFull']}),this['_editable']=new ct(_0x307cb3,_0x14da58);}['render'](){super['render'](),this['stickyPanel']['content']['add'](this['toolbar']),this['top']['add'](this['stickyPanel']),this['main']['add'](this['editable']);}}class w extends/* #__PURE__ -- @preserve */
29
+ _0x59ee7c(_0x4d07a6){['_ui'];get['ui'](){return this['_ui'];}constructor(_0x2b6457,_0x5b06c2){super(_0x5b06c2),this['sourceElement']=_0x2b6457,this['model']['document']['createRoot']();const _0x494026=new it(this['locale'],this['editing']['view'],{'shouldToolbarGroupWhenFull':!0x0});this['_ui']=new tt(this,_0x494026);}['destroy'](){return this['updateSourceElement'](),this['ui']['destroy'](),super['destroy']();}static async['create'](_0x2aec87,_0x113d29){const _0x744d05=new this(_0x2aec87,_0x113d29);return await _0x744d05['initPlugins'](),await _0x744d05['ui']['init'](_0x2aec87),await _0x744d05['data']['init'](_0x744d05['config']['get']('initialData')||''),_0x744d05['fire']('ready'),_0x744d05;}}const p=['RevisionHistoryUI','RestrictedEditingMode'];class _t extends _0x1aaf30{['result'];static get['pluginName'](){return'RevisionViewerIntegration';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x3d41a5){function _0x1410d2(_0x4bca6b){return _0x4bca6b['map'](_0x3f8755=>String['fromCharCode'](_0x3f8755))['join']('');}super(_0x3d41a5),this['result']='end',_0x3d41a5[_0x1410d2([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x1410d2([0x76,0x69,0x65,0x77])][_0x1410d2([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x1410d2([0x61,0x75,0x74,0x6f]),_0x3d41a5[_0x1410d2([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x1410d2([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x1410d2([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x1410d2([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x1410d2([0x6f,0x6b])});}}class k extends _0x1aaf30{['_viewerEditor'];static get['pluginName'](){return'RevisionHistory';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[u,f];}constructor(_0x38d3c3){if(super(_0x38d3c3),!this['editor']['config']['get']('revisionHistory'))throw new _0xae2ed9('revision-history-missing-configuration',this);this['_viewerEditor']=null,this['set']('isRevisionViewerOpen',!0x1),this['editor']['config']['define']('revisionHistory.showRevisionViewerCallback',_0x2dee4b=>this['_showRevisionViewer']({..._0x2dee4b,'translations':this['editor']['locale']['translations']})),this['editor']['config']['define']('revisionHistory.closeRevisionViewerCallback',_0x4ee88e=>this['_closeRevisionViewer'](_0x4ee88e)),this['editor']['config']['define']('revisionHistory.restoreRevisionCallback',_0x4b0203=>this['_restoreRevision'](_0x4b0203)),this['editor']['config']['define']('revisionHistory.requireRevisionName',!0x1),this['_enhanceShowRevisionViewerCallback'](),this['_enhanceCloseRevisionViewerCallback']();}set['adapter'](_0x27c44d){this['editor']['plugins']['get']('RevisionTracker')['adapter']=_0x27c44d;}get['adapter'](){return this['editor']['plugins']['get']('RevisionTracker')['adapter'];}['addRevisionData'](_0x4c175e){return this['editor']['plugins']['get']('RevisionTracker')['addRevisionData'](_0x4c175e);}['getRevision'](_0x36743f){return this['editor']['plugins']['get']('RevisionsRepository')['getRevision'](_0x36743f);}['getRevisions'](_0x24df06){return this['editor']['plugins']['get']('RevisionsRepository')['getRevisions'](_0x24df06||{'toJSON':!0x1});}['_getRevisionViewerEditorConfig'](){const _0x55f90c=this['editor'],_0x14eb21=_0x1a3df8(_0x55f90c,p),_0x291f29=_0x55f90c['plugins']['get']('RevisionTracker'),_0x171e4a=_0x55f90c['plugins']['get']('Users')['users'];return _0x14eb21['toolbar']=['exitToEditing','restoreRevision','changesNavigation'],delete _0x14eb21['lazyRoots'],(_0x14eb21['plugins']['push'](_t,m,R,class extends _0x1aaf30{static get['requires'](){return[m,'Users'];}['init'](){const _0x4186ea=this['editor']['plugins']['get']('Users');for(const _0x547a3a of _0x171e4a)_0x547a3a['isAnonymous']||_0x4186ea['getUser'](_0x547a3a['id'])||_0x4186ea['addUser'](_0x547a3a);const _0x1ca21c=_0x291f29['repository']['getRevisions']();let _0x4c7f14=null;const _0x2604de=this['editor']['plugins']['get']('RevisionViewer');_0x2604de['adapter']=_0x291f29['adapter'],_0x2604de['bind']('isEnabled')['to'](_0x291f29),this['editor']['commands']['get']('restoreRevision')['bind']('isEnabled')['to'](_0x55f90c,'isReadOnly',_0x2a7e73=>!_0x2a7e73);for(const _0xf049e6 of _0x1ca21c){const _0x546116=null===_0xf049e6['creator'];if(_0x546116&&_0xf049e6['toVersion']===_0xf049e6['fromVersion'])continue;const _0x3b7b00=_0xf049e6['toJSON']();_0x2604de['addRevisionData'](_0x3b7b00,(_0x26fe5a,_0x12ba1f,_0x1966a1)=>{if(_0x546116){if(_0x4c7f14)_0x4c7f14['_update'](_0x26fe5a,_0x12ba1f);else{if(!_0x12ba1f){const _0x2c127e=_0x1966a1['toJSON']();_0x2c127e['id']=_0x3fbd15(),_0x291f29['saveRevision'](_0x2c127e,_0x1966a1['toVersion'])['then'](_0xfaf9f8=>{_0x4c7f14=_0xfaf9f8;});}}}else _0xf049e6['_update'](_0x26fe5a,_0x12ba1f);});}}},d),_0x14eb21);}['_enhanceShowRevisionViewerCallback'](){const _0xfd2ea0=this['editor']['config']['get']('revisionHistory')['showRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.showRevisionViewerCallback',async()=>{this['editor']['enableReadOnlyMode']('revision-history-viewer-opened');const _0x439ed8=this['editor']['plugins']['get']('RevisionTracker');if(this['editor']['plugins']['has']('Autosave')){const _0xa23ba8=this['editor']['plugins']['get']('Autosave');await _0xa23ba8['save']();}else await _0x439ed8['update']();if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('Dialog')){const _0x1f2822=this['editor']['plugins']['get']('Dialog');_0x1f2822['isOpen']&&_0x1f2822['hide']();}const _0x3694b5=this['_getRevisionViewerEditorConfig']();return _0xfd2ea0(_0x3694b5)['then'](_0x573569=>{return(this['_viewerEditor']=_0x573569,this['editor']['plugins']['has']('Annotations'))&&this['editor']['plugins']['get']('Annotations')['refreshVisibility'](),(this['editor']['plugins']['has']('DocumentOutline')&&(this['editor']['plugins']['get']('DocumentOutlineUI')['view']['element']['style']['display']='none'),_0x573569);})['catch'](_0x17da8a=>(console['error'](_0x17da8a),this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),null));});}['_enhanceCloseRevisionViewerCallback'](){const _0x28e8f5=this['editor']['config']['get']('revisionHistory')['closeRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.closeRevisionViewerCallback',()=>(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('DocumentOutline')&&(this['editor']['plugins']['get']('DocumentOutlineUI')['view']['element']['style']['display']=''),this['_viewerEditor']['plugins']['get']('RevisionViewer')['_cleanUp'](),_0x28e8f5(this['_viewerEditor'])['then'](()=>{if(this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),this['_viewerEditor']=null,this['editor']['plugins']['has']('Annotations')){const _0x40093d=this['editor']['plugins']['get']('Annotations');_0x40093d['refreshVisibility'](),_0x40093d['refreshPositioning']();}})));}['_showRevisionViewer'](_0x5ec48f){const _0x361f4a=this['editor']['config']['get']('revisionHistory.editorContainer'),_0x531910=this['editor']['config']['get']('revisionHistory.viewerContainer'),_0x5b3db5=this['editor']['config']['get']('revisionHistory.viewerEditorElement');return w['create'](_0x5b3db5,_0x5ec48f)['then'](_0x349e9c=>(_0x531910['style']['display']='block',_0x361f4a['style']['display']='none',this['isRevisionViewerOpen']=!0x0,_0x349e9c));}['_closeRevisionViewer'](_0x328c30){const _0x2c3c23=this['editor']['config']['get']('revisionHistory.editorContainer');return this['editor']['config']['get']('revisionHistory.viewerContainer')['style']['display']='none',_0x2c3c23['style']['display']='',this['isRevisionViewerOpen']=!0x1,_0x328c30['destroy']();}async['_restoreRevision'](_0x51075b){const _0x4d7c9f=this['editor'],_0x1c4e51=this['_viewerEditor']['plugins']['get']('RevisionViewer'),_0x12b085=_0x4d7c9f['plugins']['get']('RevisionTracker'),_0x161fe1=_0x4d7c9f['plugins']['get']('RevisionHistoryUtils'),_0xc328a9=_0x1c4e51['repository']['getRevision'](_0x51075b);let _0x5c5700,_0x1d9eba,_0x3d135d;try{await _0x161fe1['loadRevisionData'](_0xc328a9,this['adapter']),_0x5c5700=_0x161fe1['getRevisionDocumentData'](_0xc328a9),_0x1d9eba=_0x161fe1['getRevisionRootsAttributes'](_0xc328a9);}catch(_0x10640a){return void console['error'](_0x10640a);}_0x4d7c9f['model']['change'](_0xc97bc9=>{for(const _0x41a47a of Array['from'](_0x4d7c9f['model']['markers']['getMarkersGroup']('restrictedEditingException')))_0xc97bc9['removeMarker'](_0x41a47a);}),_0x1c4e51['isReady']=!0x1,_0x4d7c9f['model']['enqueueChange'](_0x245ffa=>{_0x245ffa['setSelection'](null),_0x245ffa['removeSelectionAttribute'](_0x4d7c9f['model']['document']['selection']['getAttributeKeys']());const _0x211775=Object['keys'](_0x5c5700);for(const _0x1582a9 of _0x4d7c9f['model']['document']['roots'])'$graveyard'!=_0x1582a9['rootName']&&_0x1582a9['isAttached']()&&!_0x211775['includes'](_0x1582a9['rootName'])&&_0x245ffa['detachRoot'](_0x1582a9);for(const _0x404d2c of _0x211775){let _0x405ae6=_0x4d7c9f['model']['document']['getRoot'](_0x404d2c);_0x405ae6&&_0x405ae6['isAttached']()||(_0x405ae6=_0x245ffa['addRoot'](_0x404d2c));const _0x27694d=_0x1d9eba[_0x404d2c],_0x2a3a61=Object['keys'](_0x27694d),_0x3590d0=_0x5c5700[_0x404d2c];for(const _0x19506d of _0x405ae6['getAttributeKeys']())_0x2a3a61['includes'](_0x19506d)||_0x245ffa['removeAttribute'](_0x19506d,_0x405ae6);for(const _0x3b4b0d of _0x2a3a61)_0x245ffa['setAttribute'](_0x3b4b0d,_0x1d9eba[_0x404d2c][_0x3b4b0d],_0x405ae6);_0x245ffa['remove'](_0x245ffa['createRangeIn'](_0x405ae6)),_0x245ffa['insert'](_0x4d7c9f['data']['parse'](_0x3590d0,_0x405ae6),_0x405ae6,0x0);}});const _0x4a5f65=g(_0x4d7c9f['locale'],'Restored');if(_0xc328a9['name'])_0x3d135d=-0x1==_0xc328a9['name']['indexOf'](_0x4a5f65)?_0x4a5f65+':\x20'+_0xc328a9['name']:_0xc328a9['name'];else _0x3d135d=_0x4a5f65+':\x20'+(_0xc328a9['createdAt']['toLocaleDateString'](_0x4d7c9f['locale']['uiLanguage'],{'month':'long','day':'numeric'})+',\x20'+_0xc328a9['createdAt']['toLocaleTimeString'](_0x4d7c9f['locale']['uiLanguage'],{'hour':'numeric','minute':'numeric'}));return await _0x12b085['saveRevision']({'name':_0x3d135d}),_0x1c4e51['isReady']=!0x0,_0x4d7c9f['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}}export{h as Revision,k as RevisionHistory,f as RevisionHistoryUI,V as RevisionHistoryUtils,u as RevisionTracker,m as RevisionViewer,w as RevisionViewerEditor,ge as RevisionViewerLoadingOverlay,R as RevisionViewerUI,I as RevisionsRepository,d as RevisionsSidebar};