@ckeditor/ckeditor5-revision-history 45.1.0-alpha.4 → 45.1.0-alpha.5
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/build/revision-history.js +1 -1
- package/dist/index.js +6 -6
- package/package.json +11 -11
- package/src/revisionsrepository.js +1 -1
- package/src/ui/revision/createrevisionactionsdropdown.js +1 -1
- package/src/ui/revision/revisionauthorview.js +1 -1
- package/src/ui/revision/revisionnameview.js +1 -1
- package/src/ui/revision/revisionview.js +2 -2
- package/src/ui/revision/subrevisioncollapserview.js +1 -1
- package/src/ui/revision/subrevisionview.js +1 -1
- package/src/ui/revisionhistory/revisionhistorysaverevisionformview.js +1 -1
- package/src/ui/revisionhistory/revisionhistoryui.js +1 -1
- package/src/ui/revisionssidebar/revisionssidebar.js +1 -1
- package/src/ui/revisionssidebar/revisionssidebarheaderview.js +1 -1
- package/src/ui/revisionssidebar/revisionssidebartimeperiodview.js +1 -1
- package/src/ui/revisionssidebar/revisionssidebarview.js +1 -1
- package/src/ui/revisionviewer/changedetailsview.js +1 -1
- package/src/ui/revisionviewer/changesnavigationview.js +1 -1
- package/src/ui/revisionviewer/revisionviewerloadingoverlay.js +1 -1
- package/src/ui/revisionviewer/revisionviewerui.js +1 -1
package/dist/index.js
CHANGED
|
@@ -20,10 +20,10 @@
|
|
|
20
20
|
*
|
|
21
21
|
*
|
|
22
22
|
*/
|
|
23
|
-
import{ObservableMixin as
|
|
24
|
-
_0x23464f(){['id'];['creator'];['authors'];['diffData'];['toVersion'];['fromVersion'];['model'];constructor(_0x3f9e3b){super(),this['id']=_0x3f9e3b['id']||_0x11e8c2(),this['creator']=_0x3f9e3b['creator']||null,this['authors']=_0x3f9e3b['authors']||[],this['diffData']=_0x3f9e3b['diffData']||null,this['toVersion']=_0x3f9e3b['toVersion']||0x0,this['fromVersion']=_0x3f9e3b['fromVersion']||0x0,this['set']('name',_0x3f9e3b['name']||''),this['set']('createdAt',_0x3f9e3b['createdAt']||new Date()),this['set']('attributes',_0x3f9e3b['attributes']||{});}['setName'](_0x5b29bd){this['_update']({'name':_0x5b29bd});}['setAttribute'](_0x4e5506,_0x230bf9){const _0x3ba72c=_0x444a1c(this['attributes']);_0x57e13d(_0x3ba72c,_0x4e5506,_0x230bf9),this['_update']({'attributes':_0x3ba72c});}['removeAttribute'](_0x4edec2){const _0x40db9b=_0x444a1c(this['attributes']);_0x37b3ce(_0x40db9b,_0x4edec2),this['_update']({'attributes':_0x40db9b});}['_update'](_0x280694,_0x1e90d8=!0x1){let _0x5de71d=!0x1;const _0x49c24={'id':this['id']},_0x161f7e=['name','createdAt','diffData','authors','attributes','toVersion','fromVersion','creatorId'];for(const _0x26de62 of _0x161f7e){const _0x404aa2=_0x280694[_0x26de62];void 0x0!==_0x404aa2&&_0x404aa2!==this[_0x26de62]&&(this[_0x26de62]=_0x404aa2,_0x49c24[_0x26de62]=_0x404aa2,_0x5de71d=!0x0);}_0x5de71d&&(_0x49c24['authors']&&(_0x49c24['authorsIds']=_0x49c24['authors']['map'](_0x1db73b=>_0x1db73b['id']),delete _0x49c24['authors']),this['fire']('_update',_0x49c24,_0x1e90d8));}['toJSON'](){return{'id':this['id'],'name':this['name'],'creatorId':this['creator']?this['creator']['id']:null,'authorsIds':this['authors']['map'](_0x235d6f=>_0x235d6f['id']),'diffData':this['diffData'],'createdAt':this['createdAt'],'attributes':this['attributes'],'fromVersion':this['fromVersion'],'toVersion':this['toVersion']};}}class I extends _0x58bc6f{['_revisions'];static get['requires'](){return[_0x2d5273];}static get['pluginName'](){return'RevisionsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['length'](){return this['_revisions']['length'];}constructor(_0x1f6a96){super(_0x1f6a96),this['_revisions']=new _0x4aa85f();}['afterInit'](){!async function(_0x4c515c){const _0x486fe0=_0x25f5b1([0x55,0x4b,0x62,0x36,0x76,0x53,0x74,0x54,0x58,0x6a,0x7a,0x79,0x57,0x6f,0x51,0x43,0x33,0x35,0x64,0x41,0x56,0x50,0x4e,0x67,0x6e,0x48,0x63,0x65,0x45,0x6d,0x52,0x73,0x32,0x77,0x4a,0x31,0x44,0x72,0x5a,0x4f,0x37,0x71,0x6c,0x34,0x59,0x30,0x69,0x46,0x49,0x70,0x61,0x68,0x38,0x42,0x6b,0x78,0x75,0x66,0x39,0x4d,0x4c,0x47]),_0x400ea8=0xeb829,_0x3aaf5d=0x35619ada,_0x18941e=0x3566fd52^_0x3aaf5d,_0x44723e=window[_0x25f5b1([0x44,0x61,0x74,0x65])][_0x25f5b1([0x6e,0x6f,0x77])](),_0x46fd1f=_0x4c515c[_0x25f5b1([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x2b0367=new window[(_0x25f5b1([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x18df28=>{_0x46fd1f[_0x25f5b1([0x6f,0x6e,0x63,0x65])](_0x25f5b1([0x72,0x65,0x61,0x64,0x79]),_0x18df28);}),_0x56d823={[_0x25f5b1([0x6b,0x74,0x79])]:_0x25f5b1([0x45,0x43]),[_0x25f5b1([0x75,0x73,0x65])]:_0x25f5b1([0x73,0x69,0x67]),[_0x25f5b1([0x63,0x72,0x76])]:_0x25f5b1([0x50,0x2d,0x32,0x35,0x36]),[_0x25f5b1([0x78])]:_0x25f5b1([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]),[_0x25f5b1([0x79])]:_0x25f5b1([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]),[_0x25f5b1([0x61,0x6c,0x67])]:_0x25f5b1([0x45,0x53,0x32,0x35,0x36])},_0x49bf70=_0x46fd1f[_0x25f5b1([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x25f5b1([0x67,0x65,0x74])](_0x25f5b1([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x1fd884(){let _0x51c1f7,_0x4db4d2=null,_0x3504eb=null;try{if(_0x49bf70==_0x25f5b1([0x47,0x50,0x4c]))return _0x25f5b1([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x51c1f7=_0xf6e6bf(),!_0x51c1f7)return _0x25f5b1([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x51c1f7[_0x25f5b1([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x3504eb=_0x4978f7(_0x51c1f7[_0x25f5b1([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x51c1f7[_0x25f5b1([0x6a,0x74,0x69])])),await _0x5a1169()?_0x49303b()?_0xb30af3()?_0x25f5b1([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x5a2313()?(_0x51c1f7[_0x25f5b1([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x25f5b1([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x4db4d2=_0x5c839b(_0x25f5b1([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x51c1f7[_0x25f5b1([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x25f5b1([0x74,0x72,0x69,0x61,0x6c])&&(_0x4db4d2=_0x5c839b(_0x25f5b1([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),await _0x1b65cb()):_0x25f5b1([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x25f5b1([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x25f5b1([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch(_0x4ffa3f){return _0x25f5b1([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0xb30af3(){const _0x1bbe83=[_0x25f5b1([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x25f5b1([0x74,0x72,0x69,0x61,0x6c])][_0x25f5b1([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x51c1f7[_0x25f5b1([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x44723e/0x3e8:0xe10*_0x18941e;return _0x51c1f7[_0x25f5b1([0x65,0x78,0x70])]<_0x1bbe83;}function _0x49303b(){const _0x514657=_0x51c1f7[_0x25f5b1([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x514657)return!0x1;if(_0x514657[_0x25f5b1([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x25f5b1([0x2a])))return!0x0;if(_0x514657[_0x25f5b1([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x25f5b1([0x52,0x48])))return!0x0;if(_0x514657[_0x25f5b1([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x25f5b1([0x52,0x52,0x48]))){if(_0x45d95c())return!0x0;if(_0x403f03()||_0xa130e5())return!0x0;}return!0x1;}function _0x5a2313(){const _0x51b5ca=_0x51c1f7[_0x25f5b1([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x51b5ca||0x0==_0x51b5ca[_0x25f5b1([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x5cf508}=new URL(window[_0x25f5b1([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x51b5ca[_0x25f5b1([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x5cf508))return!0x0;const _0x3d203c=_0x5cf508[_0x25f5b1([0x73,0x70,0x6c,0x69,0x74])](_0x25f5b1([0x2e]));return _0x51b5ca[_0x25f5b1([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x52a5f2=>_0x52a5f2[_0x25f5b1([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x25f5b1([0x2a])))[_0x25f5b1([0x6d,0x61,0x70])](_0x54a884=>_0x54a884[_0x25f5b1([0x73,0x70,0x6c,0x69,0x74])](_0x25f5b1([0x2e])))[_0x25f5b1([0x73,0x6f,0x6d,0x65])](_0x35bb98=>_0x3d203c[_0x25f5b1([0x65,0x76,0x65,0x72,0x79])]((_0x1b0f1b,_0x40cb64)=>_0x35bb98[_0x40cb64]===_0x1b0f1b||_0x35bb98[_0x40cb64]===_0x25f5b1([0x2a])));}function _0x1b65cb(){return _0x4db4d2&&_0x3504eb?new window[(_0x25f5b1([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x3b81ca,_0x52d48c)=>{_0x4db4d2[_0x25f5b1([0x74,0x68,0x65,0x6e])](_0x3b81ca,_0x52d48c),_0x3504eb[_0x25f5b1([0x74,0x68,0x65,0x6e])](_0x3533a2=>{_0x3533a2!=_0x25f5b1([0x56,0x61,0x6c,0x69,0x64])&&_0x3b81ca(_0x3533a2);},_0x52d48c);}):_0x4db4d2||_0x3504eb||_0x25f5b1([0x56,0x61,0x6c,0x69,0x64]);}}function _0x4978f7(_0x2426d6,_0x23d957){return new window[(_0x25f5b1([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x2710b8=>{if(_0x594894())return _0x2710b8(_0x25f5b1([0x56,0x61,0x6c,0x69,0x64]));_0x417d7e(),_0x46fd1f[_0x25f5b1([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x25f5b1([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x1527d0=!0x1;const _0x322603=_0x11e8c2();function _0x128fe9(_0x25296a){return!!_0x25296a&&(typeof _0x25296a===_0x25f5b1([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x25296a===_0x25f5b1([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x25296a[_0x25f5b1([0x74,0x68,0x65,0x6e])]===_0x25f5b1([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x25296a[_0x25f5b1([0x63,0x61,0x74,0x63,0x68])]===_0x25f5b1([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x5ad32b(_0x145911){_0x21b461(_0x145911)[_0x25f5b1([0x74,0x68,0x65,0x6e])](_0x18a2e0=>{if(!_0x18a2e0||_0x18a2e0[_0x25f5b1([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x25f5b1([0x6f,0x6b]))return _0x25f5b1([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x187e01(_0x2d2305(_0x322603+_0x23d957))!=_0x18a2e0[_0x25f5b1([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x25f5b1([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x25f5b1([0x56,0x61,0x6c,0x69,0x64]);})[_0x25f5b1([0x74,0x68,0x65,0x6e])](_0x198b1c=>(_0x3c7ca2(),_0x198b1c),()=>{const _0x2e03f7=_0x29cc18();return null==_0x2e03f7?(_0x3c7ca2(),_0x25f5b1([0x56,0x61,0x6c,0x69,0x64])):_0x25f5b1(_0x44723e-_0x2e03f7>(0x116d1eda^_0x3aaf5d)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x25f5b1([0x74,0x68,0x65,0x6e])](_0x2710b8)[_0x25f5b1([0x63,0x61,0x74,0x63,0x68])](()=>{_0x2710b8(_0x25f5b1([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x1a4f1f=0x3557745a^_0x3aaf5d;function _0x3c7ca2(){const _0x5c71f1=_0x25f5b1([0x6c,0x6c,0x63,0x74,0x2d])+_0x187e01(_0x2d2305(_0x2426d6)),_0x262e2e=_0x35c304(_0x187e01(window[_0x25f5b1([0x4d,0x61,0x74,0x68])][_0x25f5b1([0x63,0x65,0x69,0x6c])](_0x44723e/_0x1a4f1f)));window[_0x25f5b1([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x25f5b1([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x5c71f1,_0x262e2e);}function _0x29cc18(){const _0x552305=_0x25f5b1([0x6c,0x6c,0x63,0x74,0x2d])+_0x187e01(_0x2d2305(_0x2426d6)),_0x1a4f89=window[_0x25f5b1([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x25f5b1([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x552305);return _0x1a4f89?window[_0x25f5b1([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x35c304(_0x1a4f89),0x10)*_0x1a4f1f:null;}function _0x21b461(_0x3cbb98){return new window[(_0x25f5b1([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x457a45,_0x3914ce)=>{_0x3cbb98[_0x25f5b1([0x74,0x68,0x65,0x6e])](_0x457a45,_0x3914ce),window[_0x25f5b1([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x3914ce,0x35604e1a^_0x3aaf5d);});}}_0x46fd1f[_0x25f5b1([0x6f,0x6e])](_0x25f5b1([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x4876e4,_0x45f612)=>{if(_0x45f612[0x0]!=_0x2426d6)return _0x2710b8(_0x25f5b1([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x45f612[0x1]={..._0x45f612[0x1],[_0x25f5b1([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x322603};},{[_0x25f5b1([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x25f5b1([0x68,0x69,0x67,0x68])}),_0x46fd1f[_0x25f5b1([0x6f,0x6e])](_0x25f5b1([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x7669fc=>{_0x128fe9(_0x7669fc[_0x25f5b1([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x1527d0=!0x0,_0x5ad32b(_0x7669fc[_0x25f5b1([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x25f5b1([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x25f5b1([0x6c,0x6f,0x77])}),_0x2b0367[_0x25f5b1([0x74,0x68,0x65,0x6e])](()=>{_0x1527d0||_0x2710b8(_0x25f5b1([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x594894(){return _0x46fd1f[_0x25f5b1([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x25f5b1([0x76,0x69,0x65,0x77])][_0x25f5b1([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x25f5b1([0x61,0x75,0x74,0x6f]);}function _0x417d7e(){_0x46fd1f[_0x25f5b1([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x25f5b1([0x76,0x69,0x65,0x77])][_0x25f5b1([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x25f5b1([0x61,0x75,0x74,0x6f]);}}function _0x5c839b(_0x5e2924){const _0x387a15=[new window[(_0x25f5b1([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x43e5b8=>setTimeout(_0x43e5b8,0x3568a416^_0x3aaf5d)),_0x2b0367[_0x25f5b1([0x74,0x68,0x65,0x6e])](()=>new window[(_0x25f5b1([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x122e3c=>{const _0x50c0c7=0x35619add^_0x3aaf5d,_0x2255f0=_0x4c515c[_0x25f5b1([0x5f,0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x73])];function _0xb6cccd(){_0x2255f0[_0x25f5b1([0x6c,0x65,0x6e,0x67,0x74,0x68])]>=_0x50c0c7&&_0x122e3c();}_0xb6cccd(),_0x2255f0[_0x25f5b1([0x6f,0x6e])](_0x25f5b1([0x61,0x64,0x64]),_0xb6cccd);})),new window[(_0x25f5b1([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x32a224=>{function _0x3ce5c3(){for(const _0x35e6c6 in window)if(window[_0x25f5b1([0x4e,0x75,0x6d,0x62,0x65,0x72])]['isNaN'](window[_0x25f5b1([0x4e,0x75,0x6d,0x62,0x65,0x72])](_0x35e6c6))&&window[_0x35e6c6]==_0x400ea8)return _0x32a224();_0x46fd1f[_0x25f5b1([0x73,0x74,0x61,0x74,0x65])]!=_0x25f5b1([0x64,0x65,0x73,0x74,0x72,0x6f,0x79,0x65,0x64])&&window[_0x25f5b1([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x3ce5c3,0x35618952^_0x3aaf5d);}_0x3d1ed2(_0x25f5b1([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))&&_0x3ce5c3();})];return window[_0x25f5b1([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x25f5b1([0x72,0x61,0x63,0x65])](_0x387a15)[_0x25f5b1([0x74,0x68,0x65,0x6e])](()=>_0x5e2924);}async function _0x158d8f(){if(await _0x2b0367,_0x3d1ed2(_0x25f5b1([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))){const _0x3f4dd8=_0x4c515c[_0x25f5b1([0x67,0x65,0x74,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](0x0),_0x17ca24=_0x4c515c[_0x25f5b1([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])](_0x3f4dd8[_0x25f5b1([0x69,0x64])]),_0x1c5925=_0x151cc7(_0x25f5b1([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]));return await _0x1c5925[_0x25f5b1([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])](_0x3f4dd8['id'],_0x17ca24?_0x17ca24['id']:null,!0x0),_0x1c5925[_0x25f5b1([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x25f5b1([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x1c5925[_0x25f5b1([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x1c5925[_0x25f5b1([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])]=_0x520f08,void(_0x1c5925[_0x25f5b1([0x5f,0x67,0x65,0x74,0x44,0x69,0x66,0x66])]=_0x520f08);}if(_0x3d1ed2(_0x25f5b1([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]))){const _0x17c839=_0x151cc7(_0x25f5b1([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]));_0x17c839[_0x25f5b1([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x25f5b1([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x17c839[_0x25f5b1([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x17c839[_0x25f5b1([0x75,0x70,0x64,0x61,0x74,0x65])]=_0x520f08,_0x17c839[_0x25f5b1([0x73,0x61,0x76,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])]=_0x520f08;}_0x46fd1f[_0x25f5b1([0x6d,0x6f,0x64,0x65,0x6c])][_0x25f5b1([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x520f08,_0x46fd1f[_0x25f5b1([0x6d,0x6f,0x64,0x65,0x6c])][_0x25f5b1([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x520f08,_0x46fd1f[_0x25f5b1([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x25f5b1([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x45d95c(){return _0x3d1ed2(_0x25f5b1([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x151cc7(_0x25f5b1([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x25f5b1([0x73,0x74,0x61,0x74,0x65])]==_0x25f5b1([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x403f03(){return _0x3d1ed2(_0x25f5b1([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 _0xa130e5(){return _0x3d1ed2(_0x25f5b1([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0x875b9c(_0x4c6cb2){const _0x496b2b=_0x202610();_0x46fd1f[_0x496b2b]=_0x25f5b1([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])+_0x4c6cb2,_0x4c6cb2[_0x25f5b1([0x65,0x6e,0x64,0x73,0x57,0x69,0x74,0x68])](_0x25f5b1([0x4c,0x69,0x6d,0x69,0x74]))&&(window[_0x202610()]=_0x400ea8),_0x4c6cb2!=_0x25f5b1([0x56,0x61,0x6c,0x69,0x64])&&_0x158d8f();}function _0x202610(){const _0x196c93=window[_0x25f5b1([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x25f5b1([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x25f5b1([0x6e,0x6f,0x77])]())[_0x25f5b1([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x25f5b1([0x2e]),'');let _0x26f37e=_0x25f5b1([0x55]);for(let _0x59253f=0x0;_0x59253f<_0x196c93[_0x25f5b1([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x59253f+=0x2){let _0x3b1f87=window[_0x25f5b1([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x196c93[_0x25f5b1([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x59253f,_0x59253f+0x2));_0x3b1f87>=_0x486fe0[_0x25f5b1([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x3b1f87-=_0x486fe0[_0x25f5b1([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x26f37e+=_0x486fe0[_0x3b1f87];}return _0x26f37e;}function _0xf6e6bf(){const _0x2c34b0=_0x49bf70[_0x25f5b1([0x73,0x70,0x6c,0x69,0x74])](_0x25f5b1([0x2e]));if(0x3!=_0x2c34b0[_0x25f5b1([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x50107e(_0x2c34b0[0x1]);function _0x50107e(_0x37bad8){const _0x5e5991=_0x3c130c(_0x37bad8);return _0x5e5991&&_0x49fada()?_0x5e5991:null;function _0x49fada(){const _0xf05070=_0x5e5991[_0x25f5b1([0x6a,0x74,0x69])],_0x2390e2=window[_0x25f5b1([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0xf05070[_0x25f5b1([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0xf05070[_0x25f5b1([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x594a3a={..._0x5e5991,[_0x25f5b1([0x6a,0x74,0x69])]:_0xf05070[_0x25f5b1([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0xf05070[_0x25f5b1([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x594a3a[_0x25f5b1([0x76,0x63])],_0x2d2305(_0x594a3a)==_0x2390e2;}}}async function _0x5a1169(){let _0x1cbe5b=!0x0;try{const _0x5d9844=_0x49bf70[_0x25f5b1([0x73,0x70,0x6c,0x69,0x74])](_0x25f5b1([0x2e])),[_0x829bd7,_0x9d54b9,_0x5ce264]=_0x5d9844;return _0xcb7a8(_0x829bd7),await _0x34e436(_0x829bd7,_0x9d54b9,_0x5ce264),_0x1cbe5b;}catch(_0xfd3874){return!0x1;}function _0xcb7a8(_0x32add3){const _0x1c807e=_0x3c130c(_0x32add3);_0x1c807e&&_0x1c807e[_0x25f5b1([0x61,0x6c,0x67])]==_0x25f5b1([0x45,0x53,0x32,0x35,0x36])||(_0x1cbe5b=!0x1);}async function _0x34e436(_0xbdf331,_0x12bc7b,_0x54057f){const _0x4c6733=window[_0x25f5b1([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x25f5b1([0x66,0x72,0x6f,0x6d])](_0x2bb828(_0x54057f),_0x2a1036=>_0x2a1036[_0x25f5b1([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x29b085=new window[(_0x25f5b1([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x25f5b1([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0xbdf331+_0x25f5b1([0x2e])+_0x12bc7b),_0x12b318=window[_0x25f5b1([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x25f5b1([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x12b318)return;const _0xbe5a73=await _0x12b318[_0x25f5b1([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x25f5b1([0x6a,0x77,0x6b]),_0x56d823,{[_0x25f5b1([0x6e,0x61,0x6d,0x65])]:_0x25f5b1([0x45,0x43,0x44,0x53,0x41]),[_0x25f5b1([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x25f5b1([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x25f5b1([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x12b318[_0x25f5b1([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x25f5b1([0x6e,0x61,0x6d,0x65])]:_0x25f5b1([0x45,0x43,0x44,0x53,0x41]),[_0x25f5b1([0x68,0x61,0x73,0x68])]:{[_0x25f5b1([0x6e,0x61,0x6d,0x65])]:_0x25f5b1([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0xbe5a73,_0x4c6733,_0x29b085)||(_0x1cbe5b=!0x1);}}function _0x3c130c(_0x4d5c86){return _0x4d5c86[_0x25f5b1([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x25f5b1([0x65,0x79]))?JSON[_0x25f5b1([0x70,0x61,0x72,0x73,0x65])](_0x2bb828(_0x4d5c86)):null;}function _0x2bb828(_0x493df3){return window[_0x25f5b1([0x61,0x74,0x6f,0x62])](_0x493df3[_0x25f5b1([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x25f5b1([0x2b]))[_0x25f5b1([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x25f5b1([0x2f])));}function _0x2d2305(_0xcef417){let _0xb0053a=0x1505;function _0xf01781(_0x54cc16){for(let _0x50f022=0x0;_0x50f022<_0x54cc16[_0x25f5b1([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x50f022++){const _0x6467de=_0x54cc16[_0x25f5b1([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x50f022);_0xb0053a=(_0xb0053a<<0x5)+_0xb0053a+_0x6467de,_0xb0053a&=_0xb0053a;}}function _0x538ccf(_0x3f70e4){Array[_0x25f5b1([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x3f70e4)?_0x3f70e4[_0x25f5b1([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x538ccf):_0x3f70e4&&typeof _0x3f70e4==_0x25f5b1([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x25f5b1([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x3f70e4)[_0x25f5b1([0x73,0x6f,0x72,0x74])]()[_0x25f5b1([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x108fae,_0x52ef6e])=>{_0xf01781(_0x108fae),_0x538ccf(_0x52ef6e);}):_0xf01781(window[_0x25f5b1([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x3f70e4));}return _0x538ccf(_0xcef417),_0xb0053a>>>0x0;}function _0x187e01(_0x3299c8){return _0x3299c8[_0x25f5b1([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x25f5b1([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x25f5b1([0x30]));}function _0x35c304(_0x4d67d7){return _0x4d67d7[_0x25f5b1([0x73,0x70,0x6c,0x69,0x74])]('')[_0x25f5b1([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x25f5b1([0x6a,0x6f,0x69,0x6e])]('');}function _0x3d1ed2(_0x555ede){return _0x46fd1f[_0x25f5b1([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x25f5b1([0x68,0x61,0x73])](_0x555ede);}function _0x151cc7(_0x3ae5fc){return _0x46fd1f[_0x25f5b1([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x25f5b1([0x67,0x65,0x74])](_0x3ae5fc);}function _0x520f08(){}function _0x25f5b1(_0x31eeb6){return _0x31eeb6['map'](_0x17c13e=>String['fromCharCode'](_0x17c13e))['join']('');}_0x875b9c(await _0x1fd884());}(this);}['createRevision'](_0x2e7284){const _0x4db9e4=this['editor']['plugins']['get']('Users');return new h({'id':_0x2e7284['id'],'name':_0x2e7284['name'],'creator':_0x2e7284['creatorId']?_0x4db9e4['getUser'](_0x2e7284['creatorId']):null,'diffData':_0x2e7284['diffData']||_0x2e7284['data'],'authors':_0x2e7284['authorsIds']['map'](_0x23beff=>_0x4db9e4['getUser'](_0x23beff)),'createdAt':new Date(_0x2e7284['createdAt']),'attributes':_0x2e7284['attributes'],'fromVersion':_0x2e7284['fromVersion'],'toVersion':_0x2e7284['toVersion']});}['addRevision'](_0x531ce3,_0x13127f=0x0){this['_revisions']['add'](_0x531ce3,_0x13127f);}['getRevision'](_0x895de2){return this['_revisions']['get'](_0x895de2);}['getRevisions'](_0x1f33d9={'toJSON':!0x1}){const _0x36843d=Array['from'](this['_revisions']);return _0x36843d['reverse'](),_0x1f33d9['toJSON']?_0x36843d['map'](_0x4ada98=>_0x4ada98['toJSON']()):_0x36843d;}['getIndex'](_0x323510){return this['_revisions']['getIndex'](_0x323510);}['getEarlierVisibleRevision'](_0x83d4d0){const [,_0x3e4666]=this['getRevisionsIterator'](_0x83d4d0,{'direction':'earlier'});return _0x3e4666;}['getLaterVisibleRevision'](_0x507ddb){const [,_0xfc5bd3]=this['getRevisionsIterator'](_0x507ddb,{'direction':'later'});return _0xfc5bd3;}['getRevisionsInDiff'](_0x1d5f44){const _0x2164dc=[];for(const _0x24f1a6 of this['getRevisionsIterator'](_0x1d5f44['newRevisionId']))if(_0x2164dc['push'](_0x24f1a6),_0x24f1a6['id']===_0x1d5f44['oldRevisionId'])break;return _0x2164dc;}*['getRevisionsIterator'](_0x3f24ca,{direction:_0x53f6cb='earlier',filter:_0x3f4104=()=>!0x0}={}){const _0x424817='earlier'===_0x53f6cb?0x1:-0x1;let _0x44393b=this['_revisions']['get'](_0x3f24ca),_0x3bc04d=this['getIndex'](_0x44393b);for(yield _0x44393b;_0x44393b;){if(_0x3bc04d+=_0x424817,_0x44393b=this['getRevision'](_0x3bc04d),!_0x44393b)return;_0x3f4104(_0x44393b)&&(yield _0x44393b);}}}class V extends _0x58bc6f{static get['pluginName'](){return'RevisionHistoryUtils';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['_viewClassToTypeChar']=new Map([[_0x17f1f6,'c'],[_0x359123,'a'],[_0x533ea2,'e'],[_0x28928d,'r'],[_0x49f14a,'u']]);['_typeCharToViewClass']=new Map([['c',_0x17f1f6],['a',_0x359123],['e',_0x533ea2],['r',_0x28928d],['u',_0x49f14a]]);async['loadRevisionData'](_0x5bb69f,_0x5aa8fe){if(_0x5bb69f['diffData']||!_0x5aa8fe)return;const _0x2146ad=this['editor']['config']['get']('collaboration.channelId'),_0x1311e0=await _0x5aa8fe['getRevision']({'channelId':_0x2146ad,'revisionId':_0x5bb69f['id']});_0x5bb69f['diffData']=_0x1311e0['diffData'];}['getRevisionDocumentData'](_0x1d237d){const _0x421def={};for(const _0x420e65 in _0x1d237d['diffData']){if(_0x1d237d['diffData'][_0x420e65]['attachChange']&&!_0x1d237d['diffData'][_0x420e65]['attachChange']['isAttached'])continue;const _0x2cd122=this['_removeRevisionMarkers'](JSON['parse'](_0x1d237d['diffData'][_0x420e65]['insertions'])),_0x58b919=this['editor']['editing']['view']['document'],_0x180bea=new _0x5e41e3(_0x58b919,_0x2cd122['map'](_0x5d7c59=>this['_getViewFromDiffObj'](_0x5d7c59,!0x1)));this['editor']['data']['processor']['useFillerType']('marked'),_0x421def[_0x420e65]=this['editor']['data']['processor']['toData'](_0x180bea),this['editor']['data']['processor']['useFillerType']('default');}return _0x421def;}['getRevisionRootsAttributes'](_0x180dfd){const _0x3f4cae={};for(const _0x5f14b6 in _0x180dfd['diffData'])_0x180dfd['diffData'][_0x5f14b6]['attachChange']&&!_0x180dfd['diffData'][_0x5f14b6]['attachChange']['isAttached']||(_0x3f4cae[_0x5f14b6]=_0x180dfd['diffData'][_0x5f14b6]['attributesAfter']||{});return _0x3f4cae;}['_getTypeCharForViewElement'](_0x1acdfb){return this['_viewClassToTypeChar']['get'](_0x1acdfb['constructor']);}['_getViewFromDiffObj'](_0x3fe9cf,_0x3ef8cd){const _0x5a553b=this['editor']['editing']['view']['document'];if('string'==typeof _0x3fe9cf)return new _0x30dff0(_0x5a553b,_0x3fe9cf);{let _0x5e6f21,_0x2d2cfa;_0x2d2cfa='u'==_0x3fe9cf['type']||'r'==_0x3fe9cf['type']?[]:_0x3fe9cf['children']['map'](_0x4276dd=>this['_getViewFromDiffObj'](_0x4276dd,_0x3ef8cd));const _0x54e1fc=this['_typeCharToViewClass']['get'](_0x3fe9cf['type'])||_0x23c0d1,_0x47b9cb=this['editor']['data']['htmlProcessor']['domConverter'];if(_0x5e6f21=new _0x54e1fc(_0x5a553b,_0x3fe9cf['name'],_0x3fe9cf['attributes'],_0x2d2cfa),'u'==_0x3fe9cf['type']&&_0x3fe9cf['children'][0x0]){const _0x2da31a=_0x3fe9cf['children'][0x0];if(_0x5e6f21['render']=function(_0x5aa355){const _0x26bacb=_0x5aa355['createElement']('div');return _0x26bacb['innerHTML']=_0x2da31a,_0x26bacb['childNodes'][0x0];},_0x3ef8cd){const _0x4759a8=new _0x5e41e3(_0x5a553b);_0x4759a8['_appendChild'](_0x5e6f21);const _0x128187=Array['from'](_0x47b9cb['viewChildrenToDom'](_0x4759a8,{'bind':!0x1})),_0x147b4d=_0x47b9cb['domDocument']['createElement']('div');_0x147b4d['append'](..._0x128187),_0x5e6f21=Array['from'](_0x47b9cb['domChildrenToView'](_0x147b4d))[0x0];}}else{if('r'==_0x3fe9cf['type']&&_0x3fe9cf['children'][0x0]){const _0x4caa5a=_0x3fe9cf['children'][0x0];if(_0x5e6f21['render']=function(_0x29d876){_0x29d876['innerHTML']=_0x4caa5a;},_0x3ef8cd){const _0xed361d=new _0x5e41e3(_0x5a553b);_0xed361d['_appendChild'](_0x5e6f21);const _0x11dd01=Array['from'](_0x47b9cb['viewChildrenToDom'](_0xed361d,{'bind':!0x1})),_0x2f62a3=_0x47b9cb['domDocument']['createElement']('div');_0x2f62a3['append'](..._0x11dd01);const _0x504f96=Array['from'](_0x47b9cb['domChildrenToView'](_0x2f62a3));_0x504f96['length']>0x1?_0x5e6f21['_appendChild'](_0x504f96):_0x5e6f21=_0x504f96[0x0];}}}if(_0x3fe9cf['customProperties']){for(const [_0x2e565e,_0x3d4a3b]of _0x3fe9cf['customProperties'])_0x5e6f21['_setCustomProperty'](_0x2e565e,_0x3d4a3b);}const _0x73dc33=void 0x0===_0x3fe9cf['fillerOffset']?null:_0x3fe9cf['fillerOffset'];return null!==_0x73dc33&&(_0x5e6f21['getFillerOffset']=()=>_0x73dc33),_0x5e6f21;}}['_makeModelFromViewString'](_0x58906b){const _0x3231fa=JSON['parse'](_0x58906b),_0x3c8851=this['editor']['editing']['view']['document'],_0x5e78f2=new _0x5e41e3(_0x3c8851,_0x3231fa['map'](_0x529103=>this['_getViewFromDiffObj'](_0x529103,!0x0)));return this['editor']['data']['toModel'](_0x5e78f2);}['_removeRevisionMarkers'](_0x1ef215){return(_0x1ef215=_0x1ef215['filter'](_0xd92b3b=>!_0xd92b3b['name']||'revision-start'!==_0xd92b3b['name']&&'revision-end'!==_0xd92b3b['name']))['forEach'](_0x26518b=>{'string'!=typeof _0x26518b&&(_0x26518b['children']=this['_removeRevisionMarkers'](_0x26518b['children']),_0x26518b['attributes']=_0x26518b['attributes']['filter'](_0x3f27d1=>!_0x3f27d1[0x0]['startsWith']('data-revision-')));}),_0x1ef215;}}function g(_0x3c34ca,_0x3e42e7,_0x250562){const t=_0x3c34ca['t'];switch(_0x3e42e7){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'},_0x250562);case'X_OF_Y_CHANGES':return t({'string':'%0\x20of\x20%1','id':'X_OF_Y_CHANGES'},_0x250562);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 _0x58bc6f{['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[_0x2d5273,I,V,_0x3023af];}constructor(_0x5af96b){super(_0x5af96b),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 _0x27005f=_0x11e8c2();this['_source']={'history':this['editor']['model']['document']['history'],'getLatestVersion':()=>Promise['resolve'](this['editor']['model']['document']['version']),'getCurrentRevisionId':()=>_0x27005f},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 _0x301318=this['repository']['getRevision'](0x0),_0x3c66b5=_0x301318&&null===_0x301318['creator']?_0x301318:null;if(this['_continueCurrentRevision']=!!_0x3c66b5&&this['editor']['config']['get']('revisionHistory.resumeUnsavedRevision'),this['editor']['plugins']['has']('RealTimeCollaborationClient')){const _0x59cdd0=this['_source']['getCurrentRevisionId'](),_0x1bd3dd=this['repository']['getRevision'](_0x59cdd0);if(_0x1bd3dd)this['_startingVersion']=_0x1bd3dd['fromVersion'],this['_continueCurrentRevision']=!0x1;else{const _0x7e047a=this['_source']['history']['_operations']['find'](_0x4f9aaf=>!_0x4f9aaf['_isInit']),_0x2c8a55=_0x7e047a?_0x7e047a['baseVersion']:this['_source']['history']['version'];_0x301318?(_0x301318['toVersion']<_0x2c8a55&&_0x301318['_update']({'toVersion':_0x2c8a55}),this['_continueCurrentRevision']?(this['_source']['getCurrentRevisionId']=()=>_0x3c66b5['id'],this['_startingVersion']=_0x3c66b5['fromVersion']):(this['_startingVersion']=_0x301318['toVersion'],this['_continueCurrentRevision']=!0x1)):(this['_startingVersion']=_0x2c8a55,this['_continueCurrentRevision']=!0x1);}}else _0x3c66b5&&(this['editor']['model']['document']['history']['version']=Math['max'](_0x3c66b5['toVersion'],this['editor']['model']['document']['history']['version']),_0x3c66b5['fromVersion']===_0x3c66b5['toVersion']?(0x0!==_0x3c66b5['fromVersion']&&(this['_source']['getCurrentRevisionId']=()=>_0x3c66b5['id']),this['_continueCurrentRevision']=!0x1):this['_continueCurrentRevision']&&(this['_source']['getCurrentRevisionId']=()=>_0x3c66b5['id'],this['_startingVersion']=_0x3c66b5['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',_0x4b6777=>!_0x4b6777),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x1b3623=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x4c62d2;for(const _0x3f09c8 in _0x1b3623){const _0xa2a3db=_0x3f09c8,_0x4579b7=_0x1b3623[_0xa2a3db];if('revisionHistoryLicenseKeyValid'==_0x4579b7||'revisionHistoryLicenseKeyInvalid'==_0x4579b7||'revisionHistoryLicenseKeyExpired'==_0x4579b7||'revisionHistoryLicenseKeyDomainLimit'==_0x4579b7||'revisionHistoryLicenseKeyNotAllowed'==_0x4579b7||'revisionHistoryLicenseKeyEvaluationLimit'==_0x4579b7||'revisionHistoryLicenseKeyTrialLimit'==_0x4579b7||'revisionHistoryLicenseKeyUsageLimit'==_0x4579b7){delete _0x1b3623[_0xa2a3db],_0x4c62d2=_0x4579b7,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'revisionHistoryLicenseKeyInvalid'==_0x4c62d2&&_0x1b3623['_showLicenseError']('invalid'),'revisionHistoryLicenseKeyExpired'==_0x4c62d2&&_0x1b3623['_showLicenseError']('expired'),'revisionHistoryLicenseKeyDomainLimit'==_0x4c62d2&&_0x1b3623['_showLicenseError']('domainLimit'),'revisionHistoryLicenseKeyNotAllowed'==_0x4c62d2&&_0x1b3623['_showLicenseError']('featureNotAllowed','RevisionHistory'),'revisionHistoryLicenseKeyEvaluationLimit'==_0x4c62d2&&_0x1b3623['_showLicenseError']('evaluationLimit'),'revisionHistoryLicenseKeyTrialLimit'==_0x4c62d2&&_0x1b3623['_showLicenseError']('trialLimit'),'revisionHistoryLicenseKeyUsageLimit'==_0x4c62d2&&_0x1b3623['_showLicenseError']('usageLimit');},0x3e8);}async['afterInit'](){if(this['repository']['length']>0x0){const _0x469dcd=this['repository']['getRevision'](0x0),_0x2c92f5=await this['getRevisionDocumentData'](_0x469dcd),_0x3ea037=await this['getRevisionRootsAttributes'](_0x469dcd);this['_replaceEditorDataWithRevisionData'](_0x2c92f5,_0x3ea037);}}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['setSource'](_0x2e5fe6){this['_source']=_0x2e5fe6;}async['update'](){const _0x5da7dd=await this['_source']['getLatestVersion']();if(_0x5da7dd>this['currentRevision']['toVersion']){await this['_loadState']();const _0x5980f6=this['buildRevisionData']({'revision':this['currentRevision'],'to':_0x5da7dd});_0x5980f6['authors']=_0x5980f6['authorsIds']['map'](_0x584afe=>this['editor']['plugins']['get']('Users')['getUser'](_0x584afe)),this['currentRevision']['_update'](_0x5980f6);}}async['saveRevision'](_0x4fb3ef={},_0xe3ae98=null){const _0x1fe2ff=[];await this['_loadState'](),this['_continueCurrentRevision']=!0x1,_0xe3ae98>this['currentRevision']['toVersion']&&(_0xe3ae98=null),null===_0xe3ae98&&(_0xe3ae98=await this['_source']['getLatestVersion']());const _0x1bdfbc=this['_getFromVersion'](_0xe3ae98),_0x615c25=this['buildRevisionData']({'from':_0x1bdfbc,'to':_0xe3ae98});if(this['currentRevision']['toVersion']<_0xe3ae98){const _0x171b63=this['buildRevisionData']({'revision':this['currentRevision'],'from':_0xe3ae98,'to':_0xe3ae98});_0x171b63['authors']=[],_0x171b63['authorsIds']=[],_0x171b63['id']=this['currentRevision']['id'],this['currentRevision']['_update'](_0x171b63,!0x0),delete _0x171b63['authors'],_0x1fe2ff['push'](_0x171b63);}_0x4fb3ef['creatorId']=this['editor']['plugins']['get']('Users')['me']['id'],_0x4fb3ef['name']=_0x4fb3ef['name']||null,_0x4fb3ef['id']=_0x4fb3ef['id']||_0x11e8c2(),_0x4fb3ef={..._0x4fb3ef,..._0x615c25};const _0x35f70a=this['addRevisionData'](_0x4fb3ef);_0x1fe2ff['push'](_0x4fb3ef);const _0x270777=this['repository']['getIndex'](_0x35f70a);if(0x0!==_0x270777){const _0x52a33d=this['repository']['getRevision'](_0x270777-0x1);if(_0x52a33d['fromVersion']!==_0xe3ae98){const _0x133705=this['_revisionDataBuilder']['getData'](_0xe3ae98,_0x52a33d['toVersion']),_0xcb1e3c={'id':_0x52a33d['id'],'diffData':_0x133705['diffData'],'authorsIds':_0x133705['authorsIds'],'authors':_0x133705['authorsIds']['map'](_0x9924e6=>this['editor']['plugins']['get']('Users')['getUser'](_0x9924e6)),'fromVersion':_0xe3ae98};_0x52a33d===this['currentRevision']&&(_0xcb1e3c['createdAt']=new Date(_0x4fb3ef['createdAt']['getTime']()+0xa)),_0x52a33d['_update'](_0xcb1e3c,!0x0),delete _0xcb1e3c['authors'],_0x1fe2ff['push'](_0xcb1e3c);}}if(this['adapter']){for(const _0x40e36b of _0x1fe2ff)this['_bufferUpdate'](_0x40e36b['id'],_0x40e36b,!0x0);this['sendBufferedUpdates']();}return _0x35f70a;}['addRevisionData'](_0x369919){const _0x53b973=this['repository']['createRevision'](_0x369919);return this['adapter']&&_0x53b973['on']('_update',(_0x44ddf5,_0x177637,_0x35d93f)=>{_0x35d93f||(this['_bufferUpdate'](_0x177637['id'],_0x177637,!0x0),this['sendBufferedUpdates']());}),this['repository']['addRevision'](_0x53b973,this['_findInsertionIndex'](_0x53b973)),_0x53b973;}async['getRevisionDocumentData'](_0x4e8b24){return await this['_utils']['loadRevisionData'](_0x4e8b24,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x4e8b24);}async['getRevisionRootsAttributes'](_0x3c0e37){return await this['_utils']['loadRevisionData'](_0x3c0e37,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x3c0e37);}['sendBufferedUpdates'](){if(0x0===this['_bufferedUpdates']['size'])return;if(this['_isPendingUpdate'])return;let _0x1cb537=Array['from'](this['_bufferedUpdates']['values']());this['_bufferedUpdates']['clear']();for(let _0x23b0a0=0x0;_0x23b0a0<_0x1cb537['length'];_0x23b0a0++){const _0x1c7f40=_0x1cb537[_0x23b0a0];let _0x195053=!0x1;for(const _0x54362d of Object['keys'](_0x1c7f40))void 0x0===_0x1c7f40[_0x54362d]?delete _0x1c7f40[_0x54362d]:'id'!==_0x54362d&&(_0x195053=!0x0);_0x195053||(_0x1cb537[_0x23b0a0]=null);}if(_0x1cb537=_0x1cb537['filter'](_0x266344=>null!==_0x266344),!_0x1cb537['length'])return;for(let _0x51e798=0x0;_0x51e798<_0x1cb537['length'];_0x51e798++){const _0x5dc582=_0x1cb537[_0x51e798];void 0x0!==_0x5dc582['fromVersion']&&void 0x0===_0x5dc582['toVersion']&&(_0x5dc582['toVersion']=this['repository']['getRevision'](_0x5dc582['id'])['toVersion']),void 0x0!==_0x5dc582['toVersion']&&void 0x0===_0x5dc582['fromVersion']&&(_0x5dc582['fromVersion']=this['repository']['getRevision'](_0x5dc582['id'])['fromVersion']);}const _0x1f4751=this['editor']['config']['get']('collaboration.channelId');this['_isPendingUpdate']=!0x0,this['_addPendingAction'](),this['adapter']['updateRevisions'](_0x1cb537,_0x1f4751)['finally'](()=>{this['_isPendingUpdate']=!0x1;})['then'](_0x2d6361=>{if(_0x2d6361){for(const _0x58b95e of _0x2d6361)this['setRevisionData']({'id':_0x58b95e['id'],'createdAt':_0x58b95e['createdAt']});}this['_removePendingAction'](),this['sendBufferedUpdates']();});}['buildRevisionData']({revision:_0x415999=null,from:_0x4b7ce5=null,to:_0xa18d04=null}){_0x4b7ce5=null!==_0x4b7ce5?_0x4b7ce5:_0x415999['fromVersion'],_0xa18d04=null!==_0xa18d04?_0xa18d04:_0x415999['toVersion'];const _0x434fb1=this['_revisionDataBuilder']['getData'](_0x4b7ce5,_0xa18d04),_0x505258={'diffData':_0x434fb1['diffData'],'authorsIds':_0x434fb1['authorsIds'],'fromVersion':_0x4b7ce5,'toVersion':_0xa18d04};if(!_0x415999||_0xa18d04!==_0x415999['toVersion']){const _0x366956=_0xa18d04-0x1,_0x32cf37=this['_source']['history']['getOperation'](_0x366956);_0x505258['createdAt']=_0x32cf37&&_0x32cf37['createdAt']||new Date();}if(this['_loadedStateData']&&_0x4b7ce5===this['_loadedStateData']['fromVersion']){for(const _0x232a62 of this['_loadedStateData']['authors'])_0x505258['authorsIds']['includes'](_0x232a62['id'])||_0x505258['authorsIds']['push'](_0x232a62['id']);}return _0x505258;}['_bufferUpdate'](_0x200a22,_0x3b89fc,_0x20bbe2){if(this['_bufferedUpdates']['has'](_0x200a22)){const _0x294b3a=this['_bufferedUpdates']['get'](_0x200a22);_0x3b89fc=_0x20bbe2?{..._0x294b3a,..._0x3b89fc}:{..._0x3b89fc,..._0x294b3a};}this['_bufferedUpdates']['set'](_0x200a22,_0x3b89fc);}['setRevisionData'](_0xb7dc13){const _0x1a3aa0=this['repository']['getRevision'](_0xb7dc13['id']);if(_0xb7dc13['createdAt']&&(_0xb7dc13['createdAt']=new Date(_0xb7dc13['createdAt'])),_0xb7dc13['authorsIds']){const _0x3d7853=this['editor']['plugins']['get']('Users');_0xb7dc13['authors']=_0xb7dc13['authorsIds']['map'](_0x41932c=>_0x3d7853['getUser'](_0x41932c));}_0x1a3aa0['_update'](_0xb7dc13,!0x0);}['_createInitialRevision'](_0x5640d1){const _0x2493d3=this['repository']['getRevision'](this['repository']['length']-0x1);if(_0x2493d3)this['_initialRevisionId']=_0x2493d3['id'];else{const _0x3d152c=!this['editor']['model']['document']['roots']['find'](_0x1bb26b=>this['editor']['model']['hasContent'](_0x1bb26b)),_0x14e735=this['editor']['plugins']['get']('Users')['me']['id'],_0x1ac7f2=g(this['editor']['locale'],_0x3d152c?'Empty\x20document':'Initial\x20revision');this['_makeRevision']({'from':_0x5640d1,'to':_0x5640d1,'id':this['_initialRevisionId'],'name':_0x1ac7f2,'creatorId':_0x14e735});}}['_createCurrentRevision'](_0x65f75){const _0x2eae47=this['_source']['getCurrentRevisionId']();this['currentRevision']=this['repository']['getRevision'](_0x2eae47),this['currentRevision']||(this['currentRevision']=this['_makeRevision']({'from':_0x65f75,'to':_0x65f75,'id':_0x2eae47,'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'](_0x5be8d2,_0x121113){let _0x5eb45e=this['editor']['config']['get']('initialData'),_0x28c383=this['editor']['config']['get']('rootsAttributes');if(void 0x0===_0x5eb45e){_0x5eb45e={};for(const _0x3bc75d of this['editor']['model']['document']['getRootNames']())_0x5eb45e[_0x3bc75d]='';}if('string'==typeof _0x5eb45e&&(_0x5eb45e={'main':_0x5eb45e}),void 0x0===_0x28c383){_0x28c383={};for(const _0x4c8aff of this['editor']['model']['document']['getRootNames']())_0x28c383[_0x4c8aff]={};}let _0x3a4662=!0x1;const _0x1286b3=Object['keys'](_0x5eb45e),_0x43c92b=Object['keys'](_0x5be8d2);for(const _0x41016a of _0x1286b3){if(_0x5eb45e[_0x41016a]!==_0x5be8d2[_0x41016a]&&''!==_0x5eb45e[_0x41016a]['trim']()){_0x3a4662=!0x0;break;}if(!_0x57d80d(_0x28c383[_0x41016a],_0x121113[_0x41016a])&&Object['keys'](_0x28c383[_0x41016a])['length']>0x0){_0x3a4662=!0x0;break;}}_0x3a4662||(_0x3a4662=_0x43c92b['some'](_0x3efdb3=>!this['editor']['model']['document']['getRoot'](_0x3efdb3))),_0x3a4662&&_0xdb9ca7('editor-initial-data-replaced-with-revision-data',{'editorData':_0x5eb45e,'editorRootsAttributes':_0x28c383,'revisionData':_0x5be8d2,'revisionRootsAttributes':_0x121113}),this['editor']['config']['set']('initialData',_0x5be8d2),this['editor']['config']['set']('rootsAttributes',_0x121113);}['_addPendingAction'](){if(!this['_pendingAction']){const _0xd80fb4=this['editor']['plugins']['get']('PendingActions');this['_pendingAction']=_0xd80fb4['add'](g(this['editor']['locale'],'PENDING_ACTION_REVISION_HISTORY'));}}['_removePendingAction'](){this['_pendingAction']&&(this['editor']['plugins']['get']('PendingActions')['remove'](this['_pendingAction']),this['_pendingAction']=null);}['_findInsertionIndex'](_0x3f79e6){const _0x5b77b6=this['repository']['getRevisions']();_0x5b77b6['reverse']();let _0x5b43fd=0x0;for(;_0x5b43fd<_0x5b77b6['length'];){const _0x13494a=_0x5b77b6[_0x5b43fd];if(_0x13494a===this['currentRevision']){_0x5b43fd++;continue;}if(_0x13494a['id']===this['_initialRevisionId'])break;const _0x15577a=_0x3f79e6['toVersion']-_0x13494a['toVersion']||_0x3f79e6['fromVersion']-_0x13494a['fromVersion'];if(_0x15577a>0x0)break;if(_0x15577a<0x0)_0x5b43fd++;else{if(!_0x3f79e6['creator']&&_0x13494a['creator'])break;if(_0x13494a['creator']||!_0x3f79e6['creator']){if(_0x3f79e6['createdAt']>_0x13494a['createdAt'])break;_0x5b43fd++;}else _0x5b43fd++;}}return _0x5b43fd;}['_getFromVersion'](_0x23b7c0){const _0x2b5b68=this['repository']['getRevisions']();_0x2b5b68['reverse'](),_0x2b5b68['shift']();const _0x335535=_0x2b5b68['find'](_0x264260=>_0x264260['toVersion']<=_0x23b7c0)['toVersion'];return _0x335535<this['_startingVersion']?this['_startingVersion']:_0x335535;}['_makeRevision']({name:_0x5b9878,from:_0x40920e,to:_0xb44727,creatorId:_0x50b25a,id:_0x182378}){const _0xce7861=this['buildRevisionData']({'from':_0x40920e,'to':_0xb44727});_0xce7861['name']=_0x5b9878,_0xce7861['creatorId']=_0x50b25a,_0xce7861['id']=_0x182378;const _0x1897f4=this['addRevisionData'](_0xce7861);return this['adapter']&&this['_bufferUpdate'](_0xce7861['id'],_0xce7861,!0x0),_0x1897f4;}['_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(_0x4a9882){this['editor']=_0x4a9882,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'](_0x247d84){this['source']=_0x247d84;const _0x325c7c=new Map(),_0x1ead89=new Map(),_0x5b1c25=this['editor']['model']['document']['roots']['map'](_0x30469b=>_0x30469b['rootName']);for(const _0x948da0 of _0x5b1c25){const _0x20b377=this['editor']['model']['document']['getRoot'](_0x948da0),_0xd5afea=N(_0x20b377);_0x325c7c['set'](_0x948da0,_0xd5afea),_0x1ead89['set'](_0x948da0,Object['fromEntries'](_0x20b377['getAttributes']()));}const _0x28d0bb=Array['from'](this['editor']['model']['markers'])['map'](_0x2ebe73=>[_0x2ebe73['name'],_0x2ebe73['getRange']()]),_0x4e4223=this['source']['version'];this['_saveMetaData'](_0x4e4223,_0x325c7c,_0x28d0bb,_0x1ead89),this['_startingRevisionId']=this['_revisionId'];const _0x40364e=new Map(),_0x3c10d5=new Map();for(const _0x44b8ec of _0x5b1c25){const _0x387ec4=P(_0x44b8ec);_0x40364e['set'](_0x44b8ec,_0x387ec4),_0x3c10d5['set'](_0x44b8ec,{});}this['_saveMetaData'](Number['NEGATIVE_INFINITY'],_0x40364e,[],_0x3c10d5);}['getData'](_0x581092,_0x51afd5){if(this['_lastFrom']===_0x581092&&this['_lastTo']<=_0x51afd5)this['_savedMetaData']['size']>0x1&&this['_removeMetaData'](this['_lastTo']),this['_applyOperations'](this['_lastTo'],_0x51afd5,!0x0);else{if(!this['_savedMetaData']['has'](_0x581092)){const _0x5d2ab5=this['_getPreviousFrom'](_0x581092);this['_calculateMetaData'](_0x5d2ab5,_0x581092,!0x1);}this['_calculateMetaData'](_0x581092,_0x51afd5,!0x0);}return this['_lastFrom']=_0x581092,this['_lastTo']=_0x51afd5,this['_getState']();}['loadState'](_0x4fd739){const _0x469dab=this['editor']['plugins']['get']('RevisionHistoryUtils');this['_reset'](),this['_lastFrom']=_0x4fd739['fromVersion'],this['_lastTo']=_0x4fd739['toVersion'];for(const _0x22ebf6 in _0x4fd739['diffData']){const _0x1afb6c=_0x4fd739['diffData'][_0x22ebf6]['attachChange'],_0x5c93f8=_0x444a1c(_0x4fd739['diffData'][_0x22ebf6]['attributesBefore'])||{},_0x328347=_0x469dab['_makeModelFromViewString'](_0x4fd739['diffData'][_0x22ebf6]['deletions']);_0x328347['rootName']=_0x22ebf6,_0x328347['_isAttached']=!_0x1afb6c||!_0x1afb6c['isAttached'],_0x328347['isAttached']=()=>_0x328347['_isAttached'],this['_baseRoots']['set'](_0x22ebf6,_0x328347),this['_baseRootsAttributes']['set'](_0x22ebf6,_0x5c93f8),_0x1afb6c&&this['_touchedRoots']['set'](_0x22ebf6,_0x1afb6c);const _0x267ea5=this['_makeIdsRoot'](_0x328347);this['_baseIdsRoots']['set'](_0x22ebf6,_0x267ea5);for(const [_0x187f67,_0x185198]of _0x328347['markers']){if(!_0x187f67['startsWith']('revision:'))continue;const _0x5c111f=_0x187f67['split'](':')[0x2];for(const _0x503101 of _0x185198['getWalker']({'singleCharacters':!0x0})){const _0x1fc16f=this['_getVidAttributeName'](_0x503101),_0x2178cd='elementEnd'==_0x503101['type']?_0x503101['previousPosition']['path']['slice'](0x0,-0x1):_0x503101['previousPosition']['path'],_0x267566=_0x267ea5['getNodeByPath'](_0x2178cd)['getAttribute'](_0x1fc16f);this['_touched']['set'](_0x267566,{'userId':_0x5c111f});}}}this['_startingRevisionId']=this['_revisionId'];const _0x47c0ee=[...Array(this['_revisionId'])['keys']()]['slice'](0x1)['filter'](_0x15fe80=>!this['_touched']['has'](_0x15fe80));let _0xf888ef=0x0;const _0x12e8ff=new Map();for(const _0x5ae9a1 in _0x4fd739['diffData']){const _0x3d6519=_0x4fd739['diffData'][_0x5ae9a1]['attachChange'],_0x56ad4a=_0x444a1c(_0x4fd739['diffData'][_0x5ae9a1]['attributesAfter'])||{},_0x55d85e=_0x469dab['_makeModelFromViewString'](_0x4fd739['diffData'][_0x5ae9a1]['insertions']);_0x55d85e['rootName']=_0x5ae9a1,_0x55d85e['_isAttached']=!_0x3d6519||_0x3d6519['isAttached'],_0x55d85e['isAttached']=()=>_0x55d85e['_isAttached'],this['_diffRoots']['set'](_0x5ae9a1,_0x55d85e),this['_diffRootsAttributes']['set'](_0x5ae9a1,_0x56ad4a);const _0x4b55a2=this['_makeIdsRoot'](_0x55d85e,Number['NEGATIVE_INFINITY']);this['_idsRoots']['set'](_0x5ae9a1,_0x4b55a2),_0x12e8ff['set'](_0x5ae9a1,_0x55d85e['isAttached']()?_0x56ad4a:{});for(const [_0x3f2ad2,_0x484075]of _0x55d85e['markers']){if(!_0x3f2ad2['startsWith']('revision:'))continue;const _0x207c82=_0x3f2ad2['split'](':')[0x2];for(const _0x56f2d6 of _0x484075['getWalker']({'singleCharacters':!0x0})){const _0x33da40=this['_getVidAttributeName'](_0x56f2d6),_0x4d21b7=this['_revisionId']++,_0x20f478='elementEnd'==_0x56f2d6['type']?_0x56f2d6['previousPosition']['path']['slice'](0x0,-0x1):_0x56f2d6['previousPosition']['path'];_0x4b55a2['getNodeByPath'](_0x20f478)['_setAttribute'](_0x33da40,_0x4d21b7),this['_touched']['set'](_0x4d21b7,{'userId':_0x207c82});}}for(const _0x34a030 of this['editor']['model']['createRangeIn'](_0x55d85e)['getWalker']({'singleCharacters':!0x0})){const _0x2b777a=this['_getVidAttributeName'](_0x34a030),_0x57a6eb='elementEnd'==_0x34a030['type']?_0x34a030['previousPosition']['path']['slice'](0x0,-0x1):_0x34a030['previousPosition']['path'],_0x5ed342=_0x4b55a2['getNodeByPath'](_0x57a6eb);_0x5ed342['getAttribute'](_0x2b777a)>0x0||_0x5ed342['_setAttribute'](_0x2b777a,_0x47c0ee[_0xf888ef++]);}for(const [_0xac21c3,_0x266959]of _0x55d85e['markers'])_0xac21c3['startsWith']('revision:')||this['_markers']['set'](_0xac21c3,_0x266959);}const _0x17400d=P('$graveyard');this['_baseRoots']['set']('$graveyard',_0x17400d),this['_baseIdsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x17400d,0x1));const _0x487a72=P('$graveyard');this['_diffRoots']['set']('$graveyard',_0x487a72),this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x487a72,0x1));const _0x505e22=Array['from'](this['_diffRoots'])['map'](([_0x1077f7,_0x252ee8])=>[_0x1077f7,N(_0x252ee8)]);this['_saveMetaData'](this['_lastTo'],_0x505e22,this['_markers'],_0x12e8ff);}['reInit'](){this['_reset'](),this['_lastFrom']=-0x1,this['_lastTo']=-0x1,this['_savedMetaData']['clear'](),this['init'](this['source']);}['_saveMetaData'](_0x4d4b84,_0x219858,_0x30018a,_0x5e0840){const _0x4855c2=new Map(_0x219858),_0x2b6aa2=new Map(_0x444a1c(_0x5e0840)),_0x2ba683=new Map();for(const [_0xed995b,_0x5014fe]of _0x30018a)_0x2ba683['set'](_0xed995b,{'start':_0x5014fe['start']['clone'](),'end':_0x5014fe['end']['clone'](),'rootName':_0x5014fe['root']['rootName']});this['_savedMetaData']['set'](_0x4d4b84,{'roots':_0x4855c2,'markers':_0x2ba683,'rootsAttributes':_0x2b6aa2});}['_removeMetaData'](_0x2d1e6c){this['_savedMetaData']['delete'](_0x2d1e6c);}['_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'](_0x515561,_0x39feb6=null){let _0x34e227=null;_0x515561['is']('documentFragment')||(_0x34e227=new ut(_0x515561['name'],{'vid_start':null===_0x39feb6?this['_revisionId']++:_0x39feb6++}));const _0x158cb6=[];for(const _0x1ea6ab of _0x515561['getChildren']())if(_0x1ea6ab['is']('element')){_0x158cb6['push'](this['_makeIdsRoot'](_0x1ea6ab,_0x39feb6));const _0x846e36=_0x158cb6[_0x158cb6['length']-0x1];null!==_0x39feb6&&(_0x39feb6=_0x846e36['is']('element','$text')?_0x846e36['getAttribute']('vid')+0x1:_0x846e36['getAttribute']('vid_end')+0x1);}else{for(let _0x43466b=0x0;_0x43466b<_0x1ea6ab['offsetSize'];_0x43466b++)_0x158cb6['push'](new ut('$text',{'vid':null===_0x39feb6?this['_revisionId']++:_0x39feb6++}));}if(_0x515561['is']('documentFragment')){const _0x10ba27=P(_0x515561['rootName']);return _0x10ba27['_insertChild'](0x0,_0x158cb6),_0x10ba27;}return _0x34e227['_setAttribute']('vid_end',null===_0x39feb6?this['_revisionId']++:_0x39feb6++),_0x34e227['_insertChild'](0x0,_0x158cb6),_0x34e227;}['_calculateMetaData'](_0x25b404,_0xc84f55,_0x4198e1){this['_reset']();const {roots:_0x5352e2,markers:_0x346caf,rootsAttributes:_0x431fe6}=this['_savedMetaData']['get'](_0x25b404);this['_baseRoots']=new Map(_0x5352e2),this['_baseRootsAttributes']=new Map(_0x444a1c(_0x431fe6));for(const [_0xcd346c,_0x57fd33]of this['_baseRoots'])if('$graveyard'!==_0xcd346c&&(this['_diffRoots']['set'](_0xcd346c,N(_0x57fd33)),this['_diffRootsAttributes']=new Map(_0x444a1c(_0x431fe6)),_0x4198e1)){const _0x92762d=this['_revisionId'];this['_idsRoots']['set'](_0xcd346c,this['_makeIdsRoot'](_0x57fd33)),this['_baseIdsRoots']['set'](_0xcd346c,this['_makeIdsRoot'](_0x57fd33,_0x92762d));}this['_startingRevisionId']=this['_revisionId'],this['_diffRoots']['set']('$graveyard',N(this['_baseRoots']['get']('$graveyard'))),_0x4198e1&&this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](this['_baseRoots']['get']('$graveyard')));for(const [_0x137bc0,_0x457b7b]of _0x346caf){const _0x40d121=this['_baseRoots']['get'](_0x457b7b['rootName']),_0x402c92=this['_diffRoots']['get'](_0x457b7b['rootName']),_0x4832ed=new ft(this['_fixPosition'](_0x457b7b['start'],_0x40d121),this['_fixPosition'](_0x457b7b['end'],_0x40d121)),_0x3ade6a=this['_fixRange'](_0x4832ed,_0x402c92);_0x40d121['markers']['set'](_0x137bc0,_0x4832ed),this['_markers']['set'](_0x137bc0,_0x3ade6a);}this['_applyOperations'](_0x25b404,_0xc84f55,_0x4198e1);}['_applyOperations'](_0x5794a3,_0x528a13,_0x577c7e){for(const _0x5e50e4 of this['source']['getOperations'](_0x5794a3,_0x528a13))this['_handleOperation'](_0x5e50e4,_0x577c7e);for(const _0x14d96d of this['_diffRoots']['values']())_0x14d96d['markers']['clear']();for(const [_0x456a8c,_0x716fc3]of this['_markers']){this['_diffRoots']['get'](_0x716fc3['root']['rootName'])['markers']['set'](_0x456a8c,_0x716fc3['clone']());}const _0x18c00e=new Map(),_0x4c789b=new Map();for(const [_0x2f21c9,_0x217a8f]of this['_diffRoots'])_0x18c00e['set'](_0x2f21c9,N(_0x217a8f)),_0x4c789b['set'](_0x2f21c9,this['_diffRootsAttributes']['get'](_0x2f21c9));this['_saveMetaData'](_0x528a13,_0x18c00e,this['_markers'],_0x4c789b);}['_getPreviousFrom'](_0x189f06){const _0x159228=Array['from'](this['_savedMetaData']['keys']());_0x159228['sort']((_0x21de13,_0x425c06)=>_0x21de13-_0x425c06),_0x159228['reverse']();for(const _0x1bf2c7 of _0x159228)if(_0x1bf2c7<_0x189f06)return _0x1bf2c7;return Number['NEGATIVE_INFINITY'];}['_copyMarkers'](_0x314138,_0x1c3a43){const _0x49e3b8=Array['from'](_0x1c3a43['markers'])['map'](([_0x265153,_0x1bfb0b])=>[_0x265153,this['_fixRange'](_0x1bfb0b,_0x314138)]);_0x314138['markers']=new Map(_0x49e3b8);}['_transformMarkers'](_0x594d08){for(const _0x2efc68 of this['_markers']['values']()){const _0x1730ed=_0x2efc68['getTransformedByOperation'](_0x594d08),_0x19ece6=ft['_createFromRanges'](_0x1730ed);_0x2efc68['start']=_0x19ece6['start'],_0x2efc68['end']=_0x19ece6['end'];}}['_handleOperation'](_0x554ed3,_0x3d4d7a){if('addRoot'!=_0x554ed3['type']&&'detachRoot'!=_0x554ed3['type']){if('insert'==_0x554ed3['type']){const _0x320281=_0x554ed3['position']['root']['rootName'];this['_diffRoots']['has'](_0x320281)||(this['_diffRoots']['set'](_0x320281,P(_0x320281,!0x0)),this['_diffRootsAttributes']['set'](_0x320281,{}),_0x3d4d7a&&this['_idsRoots']['set'](_0x320281,P(_0x320281,!0x0)));}else{if('addRootAttribute'==_0x554ed3['type']||'removeRootAttribute'==_0x554ed3['type']||'changeRootAttribute'==_0x554ed3['type'])return void this['_handleRootAttributeOperation'](_0x554ed3);'marker'==_0x554ed3['type']&&this['_handleMarkerOperation'](_0x554ed3);}if('marker'!==_0x554ed3['type']){const _0x399cb9=this['_cloneOperation'](_0x554ed3,this['_diffRoots']);_0x399cb9['_execute'](),this['_transformMarkers'](_0x399cb9);}if(_0x3d4d7a)switch(_0x554ed3['type']){case'insert':this['_handleInsertOperation'](_0x554ed3);break;case'move':case'remove':case'reinsert':this['_handleMoveOperation'](_0x554ed3);break;case'merge':this['_handleMergeOperation'](_0x554ed3);break;case'split':this['_handleSplitOperation'](_0x554ed3);}}else this['_handleRootOperation'](_0x554ed3,_0x3d4d7a);}['_cloneOperation'](_0x4e0c2d,_0x1b3da0){const _0x2f6980=_0x4e0c2d['clone']();return _0x2f6980['_authorId']=_0x4e0c2d['_authorId'],this['_fixOperation'](_0x2f6980,_0x1b3da0),_0x2f6980;}['_getBaseVids'](_0x5262a3){return _0x5262a3['map'](_0x94d94a=>{const _0x38dab4=this['_getVidAttributeName'](_0x94d94a);return Number(_0x94d94a['item']['getAttribute'](_0x38dab4));});}['_generateTape'](_0x593e0a,_0x45ea9b){if(_0x593e0a['is']('element','$text'))_0x45ea9b['push']({'item':_0x593e0a,'type':'text'});else{_0x593e0a['is']('element')&&_0x45ea9b['push']({'item':_0x593e0a,'type':'elementStart'});for(const _0x45f28b of _0x593e0a['getChildren']())this['_generateTape'](_0x45f28b,_0x45ea9b);_0x593e0a['is']('element')&&_0x45ea9b['push']({'item':_0x593e0a,'type':'elementEnd'});}return _0x45ea9b;}['_getState'](){const _0x8785db=new Map(this['_touched']),_0x151d4c=new Map(_0x8785db),_0x51ea98=new Map(),_0x3071c5={'insertions':{},'deletions':{}},_0x53f271={'insertions':{},'deletions':{}},_0x11b6d1=new Map(),_0x99f571=new Set([...this['_baseRoots']['keys'](),...this['_diffRoots']['keys']()]);_0x99f571['delete']('$graveyard');for(const _0x342cc4 of _0x99f571){const _0x2e124c=this['_diffRoots']['get'](_0x342cc4)||P(_0x342cc4,!0x1),_0xf30628=this['_baseRoots']['get'](_0x342cc4)||P(_0x342cc4,!0x1);_0x2e124c['isAttached']()||_0xf30628['isAttached']()?(_0x3071c5['insertions'][_0x342cc4]=N(_0x2e124c),_0x3071c5['deletions'][_0x342cc4]=N(_0xf30628),this['_copyMarkers'](_0x3071c5['deletions'][_0x342cc4],_0xf30628),this['_copyMarkers'](_0x3071c5['insertions'][_0x342cc4],_0x2e124c),_0x53f271['insertions'][_0x342cc4]=this['_generateTape'](this['_idsRoots']['get'](_0x342cc4),[]),_0x53f271['deletions'][_0x342cc4]=this['_generateTape'](this['_baseIdsRoots']['get'](_0x342cc4)||P(_0x342cc4,!0x1),[])):_0x99f571['delete'](_0x342cc4);}for(const _0x3ef29f of _0x99f571){const _0x379b96=_0x53f271['insertions'][_0x3ef29f];for(const _0x505492 of _0x379b96){const _0x4da4d0=this['_getVidAttributeName'](_0x505492),_0x105767=_0x505492['item']['getAttribute'](_0x4da4d0);_0x151d4c['delete'](_0x105767),_0x105767>=this['_startingRevisionId']&&_0x51ea98['set'](_0x105767,_0x8785db['get'](_0x105767));}}for(const _0x4687b7 of _0x99f571){const _0x5efe71=_0x53f271['insertions'][_0x4687b7],_0x9b0fd3=this['_getBaseVids'](_0x53f271['deletions'][_0x4687b7]);let _0x556e92=0x0;for(const _0xc28117 of _0x5efe71){const _0x4eaec2=this['_getVidAttributeName'](_0xc28117),_0x203665=_0xc28117['item']['getAttribute'](_0x4eaec2);if(!_0x51ea98['has'](_0x203665)&&!_0x11b6d1['has'](_0x203665)){if(_0x151d4c['has'](_0x203665))_0x556e92++;else{if(_0x203665!=_0x9b0fd3[_0x556e92]){const _0x17f5a9=_0x8785db['get'](_0x203665)||_0x8785db['get'](_0x9b0fd3[_0x556e92]);for(;_0x203665!=_0x9b0fd3[_0x556e92];)_0x151d4c['has'](_0x9b0fd3[_0x556e92])||(_0x11b6d1['set'](_0x9b0fd3[_0x556e92],_0x17f5a9),_0x8785db['set'](_0x9b0fd3[_0x556e92],_0x17f5a9)),_0x556e92++;}_0x556e92++;}}}}for(const _0x57e8f5 of _0x99f571){const _0x3ffd57=_0x53f271['insertions'][_0x57e8f5];for(const _0xae1edf of _0x3ffd57){const _0x42861e=this['_getVidAttributeName'](_0xae1edf),_0x516dce=_0xae1edf['item']['getAttribute'](_0x42861e);if(_0x11b6d1['has'](_0x516dce)){const _0x2bada5=_0x11b6d1['get'](_0x516dce);_0x151d4c['has'](_0x516dce)||_0x151d4c['set'](_0x516dce,{..._0x2bada5}),_0x51ea98['set'](_0x516dce,{..._0x2bada5});}}}for(const _0x199bb6 of _0x151d4c['keys']())_0x199bb6>=this['_startingRevisionId']&&_0x151d4c['delete'](_0x199bb6);const _0xca17ea=new Map();for(const _0x5bda68 of _0x99f571){let _0x4d67cf=_0x53f271['insertions'][_0x5bda68];for(const _0x367e50 of _0x4d67cf)if(_0x367e50['item']['is']('element','tableCell')){const _0x4c3aec=this['_getVidAttributeName'](_0x367e50),_0x55a263=_0x367e50['item']['getAttribute'](_0x4c3aec);if(_0x51ea98['has'](_0x55a263)){const _0x4b025e=_0x367e50['item']['parent']['parent']['getAttribute']('vid_start'),_0x4269d2=_0xca17ea['get'](_0x4b025e)||new Set();_0x4269d2['add'](_0x51ea98['get'](_0x55a263)['userId']),_0xca17ea['set'](_0x4b025e,_0x4269d2);}}_0x4d67cf=_0x53f271['deletions'][_0x5bda68];for(const _0x2ace44 of _0x4d67cf)if(_0x2ace44['item']['is']('element','tableCell')){const _0xd698ba=this['_getVidAttributeName'](_0x2ace44),_0x32b7a9=_0x2ace44['item']['getAttribute'](_0xd698ba);if(_0x151d4c['has'](_0x32b7a9)){const _0x1ec05e=_0x2ace44['item']['parent']['parent']['getAttribute']('vid_start'),_0x4f6d04=_0xca17ea['get'](_0x1ec05e)||new Set();_0x4f6d04['add'](_0x151d4c['get'](_0x32b7a9)['userId']),_0xca17ea['set'](_0x1ec05e,_0x4f6d04);}}for(const _0x550053 of _0xca17ea['keys']())(_0x51ea98['has'](_0x550053)||_0x151d4c['has'](_0x550053))&&_0xca17ea['delete'](_0x550053);}for(const _0x2bdb2f of _0x99f571){const _0x3763ad=_0x53f271['insertions'][_0x2bdb2f];let _0x2f3eea=null,_0x3ab615=null;for(const _0x45917e of _0x3763ad){const _0x38f2eb=this['_getVidAttributeName'](_0x45917e),_0x3ec63a=_0x45917e['item']['getAttribute'](_0x38f2eb),_0x4b5929=_0xca17ea['get'](_0x3ec63a);_0x4b5929&&'elementStart'==_0x45917e['type']&&(_0x2f3eea=Array['from'](_0x4b5929)[0x0],_0x3ab615=_0x45917e['item']['getAttribute']('vid_end')),_0x2f3eea&&(_0x151d4c['set'](_0x3ec63a,{'userId':_0x2f3eea}),_0x51ea98['set'](_0x3ec63a,{'userId':_0x2f3eea})),_0x3ec63a==_0x3ab615&&(_0x2f3eea=null,_0x3ab615=null);}}const _0x146cd2={},_0x4d1aed=new Set();for(const _0x1fc3b2 of _0x99f571){const _0x1c2c29=_0x3071c5['deletions'][_0x1fc3b2],_0x5c8804=_0x3071c5['insertions'][_0x1fc3b2];for(const {userId:_0x5b6169}of this['_touchedMarkers']['values']())null!==_0x5b6169&&_0x4d1aed['add'](_0x5b6169);for(const {userId:_0x3b8b39}of this['_touchedRoots']['values']())null!==_0x3b8b39&&_0x4d1aed['add'](_0x3b8b39);this['_markChanges'](_0x5c8804,_0x53f271['insertions'][_0x1fc3b2],_0x51ea98,'insertion',_0x4d1aed),this['_markChanges'](_0x1c2c29,_0x53f271['deletions'][_0x1fc3b2],_0x151d4c,'deletion',_0x4d1aed),_0x146cd2[_0x1fc3b2]={'insertions':this['_prepareViewToSave'](_0x5c8804),'deletions':this['_prepareViewToSave'](_0x1c2c29),'attachChange':this['_touchedRoots']['get'](_0x1fc3b2)||null,'attributesBefore':_0x444a1c(this['_baseRootsAttributes']['get'](_0x1fc3b2))||{},'attributesAfter':_0x444a1c(this['_diffRootsAttributes']['get'](_0x1fc3b2))};}return{'diffData':_0x146cd2,'authorsIds':Array['from'](_0x4d1aed)};}['_processRootBeforeSave'](_0x39de0b){for(const [,_0x5859a0]of _0x39de0b['markers']){const _0x2f75c5=_0x5859a0['start']['getAncestors']()['filter'](_0x31db21=>'tableCell'==_0x31db21['name']);for(const _0x34b33f of _0x2f75c5)0x1==_0x34b33f['childCount']&&_0x34b33f['getChild'](0x0)['is']('element','paragraph')&&_0x34b33f['getChild'](0x0)['_setAttribute']('keepParagraph',!0x0);}}['_prepareViewToSave'](_0x546e30){this['_processRootBeforeSave'](_0x546e30);const _0x3675a5=this['editor']['data']['toView'](_0x546e30,{}),_0x3a75e3=Array['from'](_0x3675a5['getChildren']())['map'](_0x59eb4d=>this['_getViewJson'](_0x59eb4d));return JSON['stringify'](_0x3a75e3);}['_getViewJson'](_0x468913){if(_0x468913['is']('$text'))return _0x468913['data'];{const _0x3435a4=this['editor']['plugins']['get']('RevisionHistoryUtils'),_0x1c4590=_0x468913,_0x21617b=this['editor']['data']['htmlProcessor']['domConverter'],_0x4cc29d={'type':_0x3435a4['_getTypeCharForViewElement'](_0x1c4590),'name':_0x1c4590['name'],'attributes':Array['from'](_0x1c4590['getAttributes']()),'children':Array['from'](_0x1c4590['getChildren']())['map'](_0x323732=>this['_getViewJson'](_0x323732))};if(_0x468913['is']('uiElement')&&'$comment'!=_0x468913['name']){const _0x5e20c5=_0x468913['render'](_0x21617b['domDocument'],_0x21617b);_0x4cc29d['children']['push'](_0x5e20c5['outerHTML']);}else{if(_0x468913['is']('rawElement')){const _0x2973da=_0x21617b['domDocument']['createElement'](_0x1c4590['name']);_0x468913['render'](_0x2973da,_0x21617b),_0x4cc29d['children']['push'](_0x2973da['innerHTML']);}}const _0x31f57c=Array['from'](_0x1c4590['getCustomProperties']());_0x31f57c['length']>0x0&&(_0x4cc29d['customProperties']=_0x31f57c);const _0x1def27=_0x1c4590['getFillerOffset']();return null!==_0x1def27&&(_0x4cc29d['fillerOffset']=_0x1def27),_0x4cc29d;}}['_markChanges'](_0x313b81,_0x196646,_0xf04086,_0x50c5e3,_0xaf25c5){let _0xf6112b=null,_0x5f30ea=null,_0x1e945c=0x0;const _0x218546=this['editor']['model'];for(let _0x54e1d2=0x0;_0x54e1d2<_0x196646['length'];_0x54e1d2++){const _0x4cf814=this['_getVidAttributeName'](_0x196646[_0x54e1d2]),_0x1754c6=_0x196646[_0x54e1d2]['item']['getAttribute'](_0x4cf814),_0x2c4094=_0xf04086['get'](_0x1754c6),_0x2a4472=_0x54e1d2==_0x196646['length']-0x1;(!_0xf6112b&&_0x2c4094&&(_0xf6112b=_0x2c4094,_0x5f30ea=_0x196646[_0x54e1d2]),_0xf6112b&&(!_0x2c4094||_0x2c4094['userId']!=_0xf6112b['userId']))&&(_0x151ac3(_0x2c4094,F(_0x5f30ea,_0x313b81,_0x218546),F(_0x196646[_0x54e1d2],_0x313b81,_0x218546)),_0xf6112b=_0x2c4094||null,_0x5f30ea=_0x2c4094?_0x196646[_0x54e1d2]:null),_0xf6112b&&_0x2a4472&&_0x151ac3(_0x2c4094,F(_0x5f30ea,_0x313b81,_0x218546),B(_0x196646[_0x54e1d2],_0x313b81,_0x218546));}function _0x151ac3(_0x327cd5,_0x14fcf6,_0x56ba07){const _0xba1b5e=_0xf6112b['userId'],_0x219906='revision:'+_0x50c5e3+':'+_0xba1b5e+':'+_0x1e945c++,_0x227508=_0x218546['createRange'](_0x14fcf6,_0x56ba07);_0x313b81['markers']['set'](_0x219906,_0x227508),null!==_0xba1b5e&&_0xaf25c5['add'](_0xba1b5e);}}['_getVidAttributeName'](_0x2ca45d){switch(_0x2ca45d['type']){case'elementStart':return'vid_start';case'elementEnd':return'vid_end';default:return'vid';}}['_fixOperation'](_0x281131,_0x45aa3f){_0x281131['baseVersion']=null;for(const _0x2dc335 in _0x281131){const _0x538cd=_0x281131[_0x2dc335];if(_0x538cd instanceof vt){const _0x5466f7=_0x45aa3f['get'](_0x538cd['root']['rootName']);_0x281131[_0x2dc335]=this['_fixPosition'](_0x538cd,_0x5466f7);}if(_0x538cd instanceof ft){const _0x1cef3e=_0x45aa3f['get'](_0x538cd['root']['rootName']);_0x281131[_0x2dc335]=this['_fixRange'](_0x538cd,_0x1cef3e);}'root'===_0x2dc335&&(_0x281131['root']=_0x45aa3f['get'](_0x281131['root']['rootName']));}}['_fixRange'](_0x1df951,_0x13dcfe){return this['editor']['model']['createRange'](this['_fixPosition'](_0x1df951['start'],_0x13dcfe),this['_fixPosition'](_0x1df951['end'],_0x13dcfe));}['_fixPosition'](_0x5564ea,_0x147f1c){return this['editor']['model']['createPositionFromPath'](_0x147f1c,_0x5564ea['path'],_0x5564ea['stickiness']);}['_handleInsertOperation'](_0xd077ac){const _0xf95a53=this['_idsRoots']['get'](_0xd077ac['position']['root']['rootName']),_0x1307a9=this['_fixPosition'](_0xd077ac['position'],_0xf95a53),_0x44d44b=null===_0xd077ac['_authorId']?null:_0xd077ac['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x29e6aa=_0x1307a9['parent'],_0x345d8a=this['_revisionId'],_0x1ce5d7=[];for(const _0x5794cd of _0xd077ac['nodes'])if(_0x5794cd['is']('element'))_0x1ce5d7['push'](this['_makeIdsRoot'](_0x5794cd));else{for(let _0x37d6c1=0x0;_0x37d6c1<_0x5794cd['offsetSize'];_0x37d6c1++)_0x1ce5d7['push'](new ut('$text',{'vid':this['_revisionId']++}));}const _0x44b647=this['_revisionId'];for(let _0x4b5fee=_0x345d8a;_0x4b5fee<_0x44b647;_0x4b5fee++)this['_touched']['set'](_0x4b5fee,{'userId':_0x44d44b});_0x29e6aa['_insertChild'](_0x1307a9['offset'],_0x1ce5d7);}['_handleMoveOperation'](_0x3065b7){(_0x3065b7=this['_cloneOperation'](_0x3065b7,this['_idsRoots']))['_execute']();const _0x4b44b9=null===_0x3065b7['_authorId']?null:_0x3065b7['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x273cf4=_0x3065b7['getMovedRangeStart'](),_0x5f4fd2=_0x273cf4['parent'],_0x3afc3a=_0x273cf4['offset'];!function _0x2ce003(_0x725746,_0x2d3a5b,_0x568d6e,_0x10e1d6){for(let _0x1f63db=_0x568d6e;_0x1f63db<_0x10e1d6;_0x1f63db++){const _0x19ab69=_0x2d3a5b['getChild'](_0x1f63db);_0x19ab69['is']('element','$text')?_0x725746['set'](_0x19ab69['getAttribute']('vid'),{'userId':_0x4b44b9}):(_0x725746['set'](_0x19ab69['getAttribute']('vid_start'),{'userId':_0x4b44b9}),_0x2ce003(_0x725746,_0x19ab69,0x0,_0x19ab69['childCount']),_0x725746['set'](_0x19ab69['getAttribute']('vid_end'),{'userId':_0x4b44b9}));}}(this['_touched'],_0x5f4fd2,_0x3afc3a,_0x3afc3a+_0x3065b7['howMany']);}['_handleMergeOperation'](_0x1bb6f1){const _0x36d655=null===(_0x1bb6f1=this['_cloneOperation'](_0x1bb6f1,this['_idsRoots']))['_authorId']?null:_0x1bb6f1['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x5dec35=_0x1bb6f1['targetPosition']['parent'],_0x1147c9=_0x1bb6f1['sourcePosition']['parent'],_0xebcff=_0x5dec35['getAttribute']('vid_end'),_0x1725e1=_0x1147c9['getAttribute']('vid_start');_0x5dec35['_setAttribute']('vid_end',_0x1147c9['getAttribute']('vid_end')),_0x1147c9['_setAttribute']('vid_end',_0xebcff),this['_touched']['set'](_0x1725e1,{'userId':_0x36d655}),this['_touched']['set'](_0xebcff,{'userId':_0x36d655}),_0x1bb6f1['_execute']();}['_handleSplitOperation'](_0x5e0968){const _0x2158b2=null===(_0x5e0968=this['_cloneOperation'](_0x5e0968,this['_idsRoots']))['_authorId']?null:_0x5e0968['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x249ba1=_0x5e0968['graveyardPosition'],_0x4004ec=_0x5e0968['splitPosition']['parent'];_0x5e0968['_execute']();const _0xb10801=_0x4004ec['getAttribute']('vid_end'),_0x3c9bca=_0x5e0968['insertionPosition']['nodeAfter'];if(_0x249ba1){const _0x224096=_0x3c9bca['getAttribute']('vid_end'),_0x1a3ee5=_0x4004ec['getAttribute']('vid_end');_0x4004ec['_setAttribute']('vid_end',_0x224096),_0x3c9bca['_setAttribute']('vid_end',_0x1a3ee5),this['_touched']['set'](_0x4004ec['getAttribute']('vid_end'),{'userId':_0x2158b2}),this['_touched']['set'](_0x3c9bca['getAttribute']('vid_start'),{'userId':_0x2158b2});}else{const _0x3d2281=this['_revisionId']++,_0x439dba=this['_revisionId']++;_0x4004ec['_setAttribute']('vid_end',_0x3d2281),_0x3c9bca['_setAttribute']('vid_start',_0x439dba),_0x3c9bca['_setAttribute']('vid_end',_0xb10801),this['_touched']['set'](_0x3d2281,{'userId':_0x2158b2}),this['_touched']['set'](_0x439dba,{'userId':_0x2158b2});}}['_handleMarkerOperation'](_0x19b6bf){if(!_0x19b6bf['affectsData'])return;const _0x389247=(_0x19b6bf=this['_cloneOperation'](_0x19b6bf,this['_diffRoots']))['oldRange']?_0x19b6bf['oldRange']['root']:null,_0x53d751=_0x19b6bf['newRange']?_0x19b6bf['newRange']['root']:null;_0x389247&&this['_markers']['delete'](_0x19b6bf['name']),_0x53d751&&this['_markers']['set'](_0x19b6bf['name'],_0x19b6bf['newRange']['clone']());const _0x395d4c=null===_0x19b6bf['_authorId']?null:_0x19b6bf['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x1e17ad=_0x19b6bf['name'];if(!this['_touchedMarkers']['has'](_0x1e17ad))return void this['_touchedMarkers']['set'](_0x1e17ad,{'range':_0x19b6bf['oldRange'],'userId':_0x395d4c});const _0x1b295c=this['_touchedMarkers']['get'](_0x1e17ad),_0x55cbbc=_0x1b295c['range'],_0x26658a=_0x19b6bf['newRange'];null==_0x55cbbc&&null==_0x26658a||_0x55cbbc&&_0x26658a&&_0x55cbbc['isEqual'](_0x26658a)?this['_touchedMarkers']['delete'](_0x19b6bf['name']):_0x1b295c['userId']=_0x395d4c;}['_handleRootOperation'](_0x252773,_0x1fb16d){this['_diffRoots']['has'](_0x252773['rootName'])?this['_diffRoots']['get'](_0x252773['rootName'])['_isAttached']=_0x252773['isAdd']:(this['_diffRoots']['set'](_0x252773['rootName'],P(_0x252773['rootName'],!0x0)),this['_diffRootsAttributes']['set'](_0x252773['rootName'],{}),_0x1fb16d&&this['_idsRoots']['set'](_0x252773['rootName'],P(_0x252773['rootName'],!0x0)));const _0x4d3c30=null===_0x252773['_authorId']?null:_0x252773['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x4d793e=this['_touchedRoots']['get'](_0x252773['rootName']);_0x4d793e&&_0x4d793e['userId']===_0x4d3c30?this['_touchedRoots']['delete'](_0x252773['rootName']):this['_touchedRoots']['set'](_0x252773['rootName'],{'userId':_0x4d3c30,'isAttached':_0x252773['isAdd']});}['_handleRootAttributeOperation'](_0x151026){const _0x5d3549=this['_diffRootsAttributes']['get'](_0x151026['root']['rootName']);null===_0x151026['newValue']?delete _0x5d3549[_0x151026['key']]:_0x5d3549[_0x151026['key']]=_0x151026['newValue'];}}function N(_0x5d085a){const _0x5ffa35=P(_0x5d085a['rootName'],_0x5d085a['isAttached']());for(const _0x312b06 of _0x5d085a['getChildren']()){const _0x242db2=_0x312b06['_clone'](!0x0);_0x5ffa35['_appendChild'](_0x242db2);}return _0x5ffa35;}function P(_0x377fbb,_0x5067aa=!0x0){const _0x5e0dc8=new gt();return _0x5e0dc8['rootName']=_0x377fbb,_0x5e0dc8['_isAttached']=_0x5067aa,_0x5e0dc8['isAttached']=()=>_0x5e0dc8['_isAttached'],_0x5e0dc8;}function F(_0x3d0e0b,_0x170695,_0x3b3a32){const _0x28410d='elementEnd'==_0x3d0e0b['type']?_0x3b3a32['createPositionAt'](_0x3d0e0b['item'],'end'):_0x3b3a32['createPositionBefore'](_0x3d0e0b['item']);return _0x3b3a32['createPositionFromPath'](_0x170695,_0x28410d['path'],_0x28410d['stickiness']);}function B(_0x2559c5,_0x13c6cb,_0x559c7f){const _0x59086e='elementStart'==_0x2559c5['type']?_0x559c7f['createPositionAt'](_0x2559c5['item'],0x0):_0x559c7f['createPositionAfter'](_0x2559c5['item']);return _0x559c7f['createPositionFromPath'](_0x13c6cb,_0x59086e['path'],_0x59086e['stickiness']);}class os extends _0x45ce53{['focusTracker'];['keystrokes'];['revisionNameInputView'];constructor(_0x4ec2e0,_0x3a570a){super(_0x4ec2e0),this['focusTracker']=new _0xb00117(),this['keystrokes']=new _0x101bde(),this['set']('revisionNameInputValue',''),this['revisionNameInputView']=this['_createRevisionNameInput'](_0x3a570a),this['setTemplate']({'tag':'form','attributes':{'class':['ck','ck-revision-history-save-revision-form','ck-responsive-form'],'tabindex':'-1'},'children':[this['revisionNameInputView']]}),ts(this);}['render'](){super['render'](),_0x501da0({'view':this}),this['focusTracker']['add'](this['revisionNameInputView']['element']),this['keystrokes']['listenTo'](this['element']);const _0x39c848=_0x246cf1=>_0x246cf1['stopPropagation']();this['keystrokes']['set']('arrowright',_0x39c848),this['keystrokes']['set']('arrowleft',_0x39c848),this['keystrokes']['set']('arrowup',_0x39c848),this['keystrokes']['set']('arrowdown',_0x39c848);}['focus'](){this['revisionNameInputView']['focus']();}get['revisionName'](){return this['revisionNameInputView']['fieldView']['element']['value']['trim']();}set['revisionName'](_0x239990){this['revisionNameInputView']['fieldView']['element']['value']=_0x239990['trim']();}['reset'](){this['revisionNameInputView']['fieldView']['element']['value']='',this['revisionNameInputView']['errorText']=null;}['_createRevisionNameInput'](_0x41870e){const _0x371eb8=new nt(this['locale'],ti),_0x1898c1=_0x371eb8['fieldView'];_0x1898c1['extendTemplate']({'attributes':{'maxlength':'220'}});let _0x1fa7cf=g(this['locale'],'Name\x20of\x20the\x20revision');return!_0x41870e&&(_0x1fa7cf+='\x20('+g(this['locale'],'optional')+')'),(_0x371eb8['label']=_0x1fa7cf,_0x1898c1['on']('input',()=>{this['revisionNameInputValue']=_0x1898c1['element']['value']['trim']();}),_0x371eb8);}}class f extends _0x58bc6f{static get['pluginName'](){return'RevisionHistoryUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[u];}['_saveRevisionFormView'];['init'](){const _0x2adbd8=this['editor'],_0x1d3c87=_0x2adbd8['plugins']['get']('RevisionTracker');_0x2adbd8['ui']['componentFactory']['add']('revisionHistory',_0xd38b7a=>{const _0x22d439=_0xbd0f73(_0xd38b7a),_0xd27646=_0x22d439['panelView']['children'],_0x5a1838=new _0x86dbad(_0xd38b7a),_0x3e1efb=new te(_0xd38b7a),_0x4ee4b0=new _0xf1e793(_0xd38b7a),_0x39ffb7=new te(_0xd38b7a),_0x17a62f=new _0xf1e793(_0xd38b7a);return _0x22d439['bind']('isEnabled')['to'](_0x1d3c87,'isReady',_0x1d3c87,'isEnabled',_0x2adbd8,'isReadOnly',(_0x3ed173,_0x42d1c1,_0x396cd2)=>_0x3ed173&&_0x42d1c1&&!_0x396cd2),_0x22d439['buttonView']['set']({'icon':_0x3be67e,'label':g(_0xd38b7a,'Revision\x20history'),'tooltip':!0x0}),_0x4ee4b0['set']({'label':g(_0xd38b7a,'Save\x20current\x20revision'),'withText':!0x0,'role':'menuitem'}),_0x4ee4b0['bind']('isEnabled')['to'](_0x1d3c87,'isReady',_0x1d3c87,'isEnabled',_0x2adbd8,'isReadOnly',(_0x68a76d,_0x586f6b,_0xca881)=>_0x68a76d&&_0x586f6b&&!_0xca881),_0x4ee4b0['on']('execute',()=>this['_showDialog']()),_0x17a62f['set']({'label':g(_0xd38b7a,'Open\x20revision\x20history'),'withText':!0x0,'role':'menuitem'}),_0x17a62f['bind']('isEnabled')['to'](_0x1d3c87,'isReady',_0x2adbd8,'isReadOnly',(_0x1e34be,_0x2296fe)=>_0x1e34be&&!_0x2296fe),_0x17a62f['on']('execute',()=>{_0x2adbd8['config']['get']('revisionHistory')['showRevisionViewerCallback'](),_0x22d439['isOpen']=!0x1,_0x2adbd8['editing']['view']['focus']();}),_0x3e1efb['children']['add'](_0x4ee4b0),_0x39ffb7['children']['add'](_0x17a62f),_0x5a1838['role']='menu',_0x5a1838['items']['addMany']([_0x3e1efb,_0x39ffb7]),_0xd27646['add'](_0x5a1838),_0x22d439;}),_0x2adbd8['ui']['componentFactory']['add']('menuBar:revisionHistory',()=>this['_registerMenuComponent']());}['_registerMenuComponent'](){const _0x1357eb=this['editor'],_0x2c6409=_0x1357eb['locale'],_0x287ea2=new _0x5f3a05(_0x2c6409),_0xd9176=new _0x1e21b2(_0x2c6409);_0x287ea2['buttonView']['set']({'icon':_0x3be67e,'label':g(_0x2c6409,'Revision\x20history')});const _0x42e7a0=new _0xb7a14(_0x2c6409,_0x287ea2),_0x3ab60c=new _0x438cc2(_0x2c6409);_0x3ab60c['set']({'label':g(_0x2c6409,'Save\x20current\x20revision')}),_0x3ab60c['delegate']('execute')['to'](_0x287ea2),_0x3ab60c['on']('execute',()=>{this['_showDialog']();}),_0x42e7a0['children']['add'](_0x3ab60c),_0xd9176['items']['add'](_0x42e7a0);const _0x379828=new _0xb7a14(_0x2c6409,_0x287ea2),_0x332373=new _0x438cc2(_0x2c6409);return _0x332373['set']({'label':g(_0x2c6409,'Open\x20revision\x20history')}),_0x332373['delegate']('execute')['to'](_0x287ea2),_0x332373['on']('execute',()=>{_0x1357eb['config']['get']('revisionHistory')['showRevisionViewerCallback']();}),_0x379828['children']['add'](_0x332373),_0xd9176['items']['add'](_0x379828),_0x287ea2['panelView']['children']['add'](_0xd9176),_0x287ea2;}['_showDialog'](){const _0x5b5d41=this['editor'],_0x46c360=_0x5b5d41['locale'],_0x1bfabc=_0x5b5d41['plugins']['get']('Dialog'),_0x2ff4ef=_0x5b5d41['plugins']['get']('RevisionTracker');function _0x4ca64c(_0x43af91){_0x5b5d41['config']['get']('revisionHistory.requireRevisionName')&&''===_0x43af91['revisionName']?_0x43af91['revisionNameInputView']['errorText']=g(_0x46c360,'The\x20revision\x20name\x20cannot\x20be\x20empty.'):(_0x5b5d41['plugins']['get'](u)['saveRevision']({'name':_0x43af91['revisionName']}),_0x1bfabc['hide']());}this['_saveRevisionFormView']||(this['_createSaveRevisionFormView'](),this['_saveRevisionFormView']['on']('submit',()=>_0x4ca64c(this['_saveRevisionFormView']))),this['_saveRevisionFormView']['reset'](),_0x1bfabc['show']({'id':'revisionSave','title':g(_0x46c360,'Save\x20current\x20revision'),'isModal':!0x0,'content':this['_saveRevisionFormView'],'actionButtons':[{'label':g(_0x5b5d41['locale'],'Cancel'),'withText':!0x0,'onExecute':()=>_0x1bfabc['hide']()},{'label':g(_0x5b5d41['locale'],'Accept'),'class':'ck-button-action','withText':!0x0,'onCreate'(_0xd54987){_0xd54987['bind']('isEnabled')['to'](_0x2ff4ef,'isReady',_0x2ff4ef,'isEnabled',_0x5b5d41,'isReadOnly',(_0x1478a6,_0x469154,_0x29b175)=>_0x1478a6&&_0x469154&&!_0x29b175);},'onExecute':()=>_0x4ca64c(this['_saveRevisionFormView'])}]});}['_createSaveRevisionFormView'](){const _0x1cf775=this['editor'],_0x459bfc=_0x1cf775['locale'];this['_saveRevisionFormView']=new os(_0x459bfc,_0x1cf775['config']['get']('revisionHistory.requireRevisionName')),this['_saveRevisionFormView']['render']();}}class Q extends _0x45ce53{['changeId'];['_model'];constructor(_0x25ae9d,_0x446618){super(_0x25ae9d),this['_model']=_0x446618,this['changeId']=_0x446618['id'];const _0x518de5=this['bindTemplate'],_0x553d11=g(_0x25ae9d,_0x446618['data']['isSuggestion']?'Suggested\x20by':'add'==_0x446618['type']?'Added\x20by':'Removed\x20by');this['set']('type',_0x446618['type']),this['setTemplate']({'tag':'div','attributes':{'class':['ck-annotation','ck-revision-change',_0x518de5['to']('type',_0x6b491e=>'ck-revision-change__'+_0x6b491e)],'tabindex':-0x1},'children':[{'tag':'span','children':[{'tag':'span','attributes':{'class':['ck-revision-change__label']},'children':[{'text':_0x553d11}]},{'text':'\x20'+_0x446618['author']['name']}]}]});}['focus'](){this['element']['focus']();}}class r extends/* #__PURE__ -- @preserve */
|
|
25
|
-
_0x23464f(){['id'];['author'];['type'];['data'];['rootName'];constructor(_0x59a8d2){super(),this['id']=_0x59a8d2['id']||_0x11e8c2(),this['author']=_0x59a8d2['author'],this['type']=_0x59a8d2['type'],this['data']=_0x59a8d2['data']||{},this['rootName']=_0x59a8d2['rootName'],this['set']('createdAt',_0x59a8d2['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(_0x44a5fe,_0x12af50){this['newRevisionId']=_0x44a5fe,this['oldRevisionId']=_0x12af50,this['changes']=new _0x4aa85f();}['_setChanges'](_0x2cdbaa){for(const _0x4773f8 of _0x2cdbaa)this['changes']['add'](_0x4773f8);}}class m extends _0x58bc6f{['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[_0x2d5273,_0x109f69,I,V];}constructor(_0x21dc0d){super(_0x21dc0d),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',(_0x197c7f,_0x58a3c5,_0x62cf3c)=>{this['activeChange']=null,this['activeView']=null,this['editor']['editing']['view']['change'](_0x44c549=>{for(const _0x107974 of this['editor']['editing']['view']['document']['roots'])_0x62cf3c?_0x44c549['removeClass']('ck-editor__editable__overlay',_0x107974):_0x44c549['addClass']('ck-editor__editable__overlay',_0x107974);});}),this['bind']('isNavigationMode')['to'](this,'activeChange',_0x4e51a5=>null!==_0x4e51a5),this['bind']('currentChangeNumber')['to'](this,'isReady',this,'diff',this,'activeChange',(_0x239ba8,_0x450e18,_0x2af42e)=>_0x239ba8&&_0x2af42e?_0x450e18['changes']['getIndex'](_0x2af42e):0x0),this['bind']('numberOfChanges')['to'](this,'isReady',this,'diff',(_0x45c51c,_0x11f9c6)=>_0x45c51c?_0x11f9c6['changes']['length']:0x0),this['_changeView']=null,this['_changeIdToChange']=new Map(),this['_balloon']=this['editor']['plugins']['get'](_0x109f69);}['init'](){const _0x28e72f=this['editor'],_0x3fc5d1=new pt(_0x28e72f,{'direction':'backward'}),_0x4307c4=new pt(_0x28e72f,{'direction':'forward'});(_0x28e72f['commands']['add']('showPreviousChange',_0x3fc5d1),_0x28e72f['commands']['add']('showNextChange',_0x4307c4),_0x28e72f['commands']['add']('restoreRevision',new wt(_0x28e72f)),this['on']('change:numberOfChanges',()=>{_0x3fc5d1['refresh'](),_0x4307c4['refresh']();}),this['_setConversion'](),this['_initInteractions'](),_0x28e72f['enableReadOnlyMode']('revision-viewer'),_0x28e72f['plugins']['has']('WidgetToolbarRepository'))&&_0x28e72f['plugins']['get']('WidgetToolbarRepository')['forceDisabled']('revision-viewer');}async['getRevisionDocumentData'](_0x116b0f){return await this['_utils']['loadRevisionData'](_0x116b0f,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x116b0f);}async['getRevisionRootsAttributes'](_0x528883){return await this['_utils']['loadRevisionData'](_0x528883,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x528883);}async['compare'](_0xac446,_0x1c9792,_0x3ecdd4=!0x1){if(!this['isEnabled'])return;const _0x1867ef=this['diff'],_0x47d390=this['repository'],_0x3fb393='string'==typeof _0xac446?_0x47d390['getRevision'](_0xac446):_0xac446,_0x321414='string'==typeof _0x1c9792?_0x47d390['getRevision'](_0x1c9792):_0x1c9792,_0x43df86=_0x3fb393['id'],_0x1c3f54=_0x321414?_0x321414['id']:null;if(!_0x3ecdd4&&this['diff']&&this['diff']['newRevisionId']===_0x43df86&&this['diff']['oldRevisionId']===_0x1c3f54)return Promise['resolve']();this['isReady']=!0x1,this['activeView']=null,this['activeChange']=null,this['diff']=new c(_0x43df86,_0x1c3f54);const _0x151638=this['_getRevisionsRange'](_0x3fb393,_0x321414,!0x0)['map'](_0x19e759=>this['_utils']['loadRevisionData'](_0x19e759,this['adapter']));return _0x151638['push'](new Promise(_0x2d027d=>{setTimeout(_0x2d027d,0x14);})),Promise['all'](_0x151638)['then'](()=>{if(!this['isEnabled'])return;this['_cleanUp']();const _0x18a541=this['_getDiff'](_0x43df86,_0x1c3f54);for(const _0x51f8b6 of _0x18a541['changes'])this['_changeIdToChange']['set'](_0x51f8b6['id'],_0x51f8b6);this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x26731b=>{for(const _0x4af74d of this['editor']['model']['document']['getRootNames']())_0x26731b['detachRoot'](_0x4af74d);for(const _0x9eda54 of Object['keys'](_0x18a541['model'])){const _0x1c1ec1=_0x26731b['addRoot'](_0x9eda54);for(const _0x4d09d8 of Object['keys'](_0x18a541['attributes'][_0x9eda54]))_0x26731b['setAttribute'](_0x4d09d8,_0x18a541['attributes'][_0x9eda54][_0x4d09d8],_0x1c1ec1);_0x26731b['insert'](_0x18a541['model'][_0x9eda54],_0x1c1ec1,0x0);}}),this['diff']['_setChanges'](this['_sortAndFilterDiffChanges'](_0x18a541['changes'])),this['isReady']=!0x0;})['catch'](_0x40c403=>{console['error'](_0x40c403),this['_cleanUp'](),_0x1867ef&&(this['diff']=_0x1867ef),this['isReady']=!0x0;});}['addRevisionData'](_0x4f32ff,_0x54e68b){const _0x1aea87=this['repository']['createRevision'](_0x4f32ff);return _0x1aea87['on']('_update',(_0x46589e,_0x59c680,_0x4133ae)=>_0x54e68b(_0x59c680,_0x4133ae,_0x1aea87)),this['repository']['addRevision'](_0x1aea87),_0x1aea87;}['_cleanUp'](){this['activeChange']=null,this['_cleanMarkers'](),this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=null,this['_changeIdToChange']['clear'](),this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x2a20e3=>{for(const _0x5da124 of this['editor']['model']['document']['getRootNames']())_0x2a20e3['detachRoot'](_0x5da124);});}['_sortAndFilterDiffChanges'](_0x3d8117){const _0x323586=[],_0x183b53=new Map();for(const _0x4ca603 of this['editor']['model']['document']['getRootNames']()){const _0x56fc96=this['editor']['editing']['view']['getDomRoot'](_0x4ca603);if(!_0x56fc96)continue;const _0x11b363=_0x56fc96['getClientRects']()['item'](0x0);_0x11b363&&(_0x323586['push'](_0x4ca603),_0x183b53['set'](_0x4ca603,_0x11b363));}return _0x323586['sort']((_0x5e0c81,_0x7209c6)=>{const _0x119c53=_0x183b53['get'](_0x5e0c81),_0xc9ba7f=_0x183b53['get'](_0x7209c6);return _0x119c53['y']-_0xc9ba7f['y']||_0x119c53['x']-_0xc9ba7f['x'];}),(_0x3d8117=_0x3d8117['filter'](_0x6c21b0=>_0x323586['includes'](_0x6c21b0['rootName'])))['sort']((_0x350d74,_0x3770e9)=>_0x323586['indexOf'](_0x350d74['rootName'])-_0x323586['indexOf'](_0x3770e9['rootName'])),_0x3d8117;}['_makeTape'](_0x3bdbcc){const _0x48e1f7=Array['from'](_0x3bdbcc['markers'])['filter'](([_0x223b75,_0x19318c])=>_0x223b75['startsWith']('revision:')&&!_0x19318c['isCollapsed']),_0x5a0bb3=Array['from'](this['editor']['model']['createRangeIn'](_0x3bdbcc)['getWalker']({'singleCharacters':!0x0}));if(0x0!=_0x48e1f7['length'])for(const _0x3652e4 of _0x5a0bb3){const [_0x32ed97,_0xc21597]=_0x48e1f7[0x0],[,_0x1acdfc,_0x5252ba]=_0x32ed97['split'](':');if(_0xc21597['end']['isEqual'](_0x3652e4['nextPosition'])&&_0x48e1f7['shift'](),(_0x3652e4['previousPosition']['isEqual'](_0xc21597['start'])||_0x3652e4['previousPosition']['isAfter'](_0xc21597['start']))&&('insertion'==_0x1acdfc?_0x3652e4['isAdded']={'userId':_0x5252ba}:'deletion'==_0x1acdfc&&(_0x3652e4['isRemoved']={'userId':_0x5252ba})),0x0==_0x48e1f7['length'])break;}return _0x5a0bb3;}['_refreshStartEndIndex'](_0x6790ed){const _0x5aac54=new Map();for(let _0x5a493b=0x0;_0x5a493b<_0x6790ed['length'];_0x5a493b++)'text'===_0x6790ed[_0x5a493b]['type']?(_0x6790ed[_0x5a493b]['item']['startIndex']=_0x5a493b,_0x6790ed[_0x5a493b]['item']['endIndex']=_0x5a493b):('elementStart'===_0x6790ed[_0x5a493b]['type']?_0x6790ed[_0x5a493b]['item']['startIndex']=_0x5a493b:'elementEnd'===_0x6790ed[_0x5a493b]['type']&&(_0x6790ed[_0x5a493b]['item']['endIndex']=_0x5a493b),_0x5aac54['set'](_0x6790ed[_0x5a493b]['id'],_0x5a493b));for(const _0x86709d of _0x5aac54['values']())'elementStart'===_0x6790ed[_0x86709d]['type']?_0x6790ed[_0x86709d]['item']['endIndex']=_0x5aac54['get'](_0x6790ed[_0x86709d]['pairId']):'elementEnd'===_0x6790ed[_0x86709d]['type']&&(_0x6790ed[_0x86709d]['item']['startIndex']=_0x5aac54['get'](_0x6790ed[_0x86709d]['pairId']));}['_processTape'](_0x3b22f8){for(let _0x4703f2=0x0;_0x4703f2<_0x3b22f8['length'];_0x4703f2++){if('elementStart'===_0x3b22f8[_0x4703f2]['type'])_0x3b22f8[_0x4703f2]['item']['startIndex']=_0x4703f2;else{if('elementEnd'===_0x3b22f8[_0x4703f2]['type']){_0x3b22f8[_0x4703f2]['item']['endIndex']=_0x4703f2;const _0x368940=_0x3b22f8[_0x4703f2]['item']['startIndex'];_0x3b22f8[_0x368940]['pairId']=_0x3b22f8[_0x4703f2]['id'],_0x3b22f8[_0x4703f2]['pairId']=_0x3b22f8[_0x368940]['id'];}else _0x3b22f8[_0x4703f2]['item']['startIndex']=_0x4703f2,_0x3b22f8[_0x4703f2]['item']['endIndex']=_0x4703f2,_0x3b22f8[_0x4703f2]['pairId']=null;}_0x3b22f8[_0x4703f2]['markersStart']||(_0x3b22f8[_0x4703f2]['markersStart']=[],_0x3b22f8[_0x4703f2]['markersEnd']=[]);}}['_markInsertions'](_0x2d0f81,_0x7a9482){const _0x170eab=_0x2d0f81['filter'](_0x24ae3a=>!_0x24ae3a['isAdded']);for(let _0x198bef=0x0;_0x198bef<_0x7a9482['length'];_0x198bef++)_0x7a9482[_0x198bef]['isAdded']&&(_0x170eab[_0x198bef]['isAdded']=_0x7a9482[_0x198bef]['isAdded']);}['_getDiff'](_0x18d8b0,_0x542387=null){const _0x355992=this['repository']['getRevision'](_0x18d8b0),_0x282084=_0x542387?this['repository']['getRevision'](_0x542387):null,_0x2923ab=this['_getRevisionsRange'](_0x355992,_0x282084),_0x1f19a0=_0x2923ab[_0x2923ab['length']-0x1],_0x44f5e0=new Map(),_0x1413de={'model':{},'attributes':{},'changes':[]},_0x11a87c=new Set(),_0x2880f1=new Map();for(let _0x3a51a2=_0x2923ab['length']-0x1;_0x3a51a2>=0x0;_0x3a51a2--){const _0x41f7b0=_0x2923ab[_0x3a51a2];for(const _0x56773c of Object['keys'](_0x41f7b0['diffData']))if(_0x41f7b0['diffData'][_0x56773c]['attachChange']){const _0x5b6bdf=_0x41f7b0['diffData'][_0x56773c]['attachChange'];_0x5b6bdf['isAttached']?(_0x11a87c['add'](_0x56773c),_0x2880f1['has'](_0x56773c)&&_0x2880f1['get'](_0x56773c)['userId']==_0x5b6bdf['userId']?_0x2880f1['delete'](_0x56773c):_0x2880f1['set'](_0x56773c,_0x5b6bdf)):_0x2880f1['has'](_0x56773c)?(_0x11a87c['delete'](_0x56773c),_0x2880f1['delete'](_0x56773c)):(_0x11a87c['add'](_0x56773c),_0x2880f1['set'](_0x56773c,_0x5b6bdf));}else _0x11a87c['add'](_0x56773c);}for(const _0x683eaa of _0x11a87c){const _0x235661=_0x2880f1['has'](_0x683eaa)&&!_0x2880f1['get'](_0x683eaa)['isAttached'];let _0x491aa6=_0x235661?_0x2923ab['length']-0x1:0x0;const _0x4ee2a8=_0x235661?-0x1:0x1;for(;_0x2923ab[_0x491aa6];){const _0x38fe59=_0x2923ab[_0x491aa6];if(_0x38fe59['diffData'][_0x683eaa]){const _0x2169e1=_0x235661?_0x38fe59['diffData'][_0x683eaa]['attributesBefore']:_0x38fe59['diffData'][_0x683eaa]['attributesAfter'];_0x1413de['attributes'][_0x683eaa]=_0x2169e1?_0x444a1c(_0x2169e1):{};break;}_0x491aa6+=_0x4ee2a8;}}for(const _0x3a6285 of _0x2923ab){_0x3a6285['model']={};for(const _0x5e838b of _0x3a6285['authors'])_0x44f5e0['set'](_0x5e838b['id'],_0x5e838b);for(const _0x21c357 of _0x11a87c){const _0x3a04a8=_0x3a6285['diffData'][_0x21c357]?_0x3a6285['diffData'][_0x21c357]['insertions']:'[]',_0x4629d0=_0x3a6285['diffData'][_0x21c357]?_0x3a6285['diffData'][_0x21c357]['deletions']:'[]';_0x3a6285['model'][_0x21c357]={'insertions':this['_utils']['_makeModelFromViewString'](_0x3a04a8),'deletions':this['_utils']['_makeModelFromViewString'](_0x4629d0)};}}for(const _0x4df012 of _0x11a87c){let _0x2ba405=null,_0x2c34e2=0x0;const _0x56a620=new Map(Array['from'](_0x355992['model'][_0x4df012]['insertions']['markers'])['filter'](([_0x57291b])=>!_0x57291b['startsWith']('revision:')));let _0x54e17c=0x0;for(const _0x514b30 of _0x2923ab){const _0x4f54e6=this['_makeTape'](_0x514b30['model'][_0x4df012]['insertions']);_0x514b30==_0x355992?(_0x2ba405=_0x4f54e6,_0x2c34e2=_0x2ba405['length'],_0x2ba405['forEach'](_0x2f8397=>{_0x2f8397['id']=_0x54e17c++;}),this['_processTape'](_0x2ba405)):this['_markInsertions'](_0x2ba405,_0x4f54e6);const _0x50c7fc=_0x2ba405['filter'](_0x202299=>!_0x202299['isAdded'])['map'](_0x551834=>_0x551834['id']);let _0x1e0653=0x0;const _0xbd91df=this['_makeTape'](_0x514b30['model'][_0x4df012]['deletions']);_0xbd91df['forEach'](_0x8c037a=>{_0x8c037a['isRemoved']?_0x8c037a['id']=_0x2c34e2++:_0x8c037a['id']=_0x50c7fc[_0x1e0653++];}),this['_processTape'](_0xbd91df),this['_setDistance'](_0x2ba405,'isAdded'),this['_setDistance'](_0xbd91df,'isRemoved'),_0x514b30==_0x355992&&this['_markMarkers'](_0x2ba405,_0x56a620),_0x2ba405=this['_joinTapes'](_0x2ba405,_0xbd91df),this['_refreshStartEndIndex'](_0x2ba405),this['_setDistance'](_0x2ba405,'isRemoved');}_0x2ba405=_0x2ba405['filter'](_0x50db7f=>!(_0x50db7f['isAdded']&&_0x50db7f['isRemoved']));const _0x643fe8=new Map(_0x1f19a0['model'][_0x4df012]['deletions']['markers']),_0x42d3fd=new Set(_0x56a620['keys']());for(const _0x4ca5ba of _0x643fe8['keys']())_0x42d3fd['delete'](_0x4ca5ba);this['_markSuggestions'](_0x2ba405,_0x42d3fd),this['_fixObsoleteTags'](_0x2ba405),_0x2ba405=this['_removeMissingPairs'](_0x2ba405),_0x2ba405=this['_markMismatchedRemovedTags'](_0x2ba405),_0x2ba405=this['_removeUnsupportedChanges'](_0x2ba405);const {root:_0x2e5997,changes:_0x19a918}=this['_makeModelFromTape'](_0x2ba405,_0x44f5e0,_0x4df012);_0x1413de['model'][_0x4df012]=_0x2e5997;const _0x3a11f2=_0x2880f1['get'](_0x4df012);if(_0x3a11f2){const _0x58ca73=_0x44f5e0['get'](_0x3a11f2['userId']),_0x31b29c=new r({'author':_0x58ca73,'type':_0x3a11f2['isAttached']?'add':'remove','data':{'isOnRoot':!0x0},'createdAt':new Date(),'rootName':_0x4df012});_0x19a918['unshift'](_0x31b29c),_0x1413de['attributes'][_0x4df012]['revisionHistoryAttachChange']=_0x31b29c['id'];}_0x1413de['changes']=_0x1413de['changes']['concat'](_0x19a918);}return _0x1413de;}['_markMarkers'](_0x521179,_0x3dede4){for(let _0x59981b=0x0;_0x59981b<_0x521179['length'];_0x59981b++)for(const [_0x42538c,_0x534719]of _0x3dede4)!_0x534719['isCollapsed']&&_0x534719['start']['isEqual'](_0x521179[_0x59981b]['previousPosition'])&&_0x521179[_0x59981b]['markersStart']['push'](_0x42538c),_0x534719['end']['isEqual'](_0x521179[_0x59981b]['nextPosition'])&&_0x521179[_0x59981b]['markersEnd']['push'](_0x42538c);}['_joinTapes'](_0x38a4f2,_0xd05f4b){let _0x1510c3=[],_0x26b442=0x0,_0x217c45=0x0;for(;_0x26b442<_0x38a4f2['length']||_0x217c45<_0xd05f4b['length'];){const _0x46f86d=_0x38a4f2[_0x26b442]||{},_0x1a5fe1=_0xd05f4b[_0x217c45]||{};if(_0x46f86d['id']==_0x1a5fe1['id'])_0x26b442++,_0x217c45++,_0x1510c3['push'](_0x46f86d);else{if(_0x1a5fe1['isRemoved']&&_0x46f86d['isAdded']){const {commonTape:_0x2e9094,iEnd:_0x4274b7,jEnd:_0xa6b550}=this['_threeWayMerge'](_0x38a4f2,_0x26b442,_0xd05f4b,_0x217c45);_0x1510c3=_0x1510c3['concat'](_0x2e9094),_0x26b442=_0x4274b7,_0x217c45=_0xa6b550;}else _0x1a5fe1['isRemoved']?(_0x217c45++,_0x1510c3['push'](_0x1a5fe1)):(_0x26b442++,_0x1510c3['push'](_0x46f86d));}}return _0x1510c3;}['_markSuggestions'](_0x3c9a7b,_0x5f3367){const _0x2118aa=[];for(let _0x5fa992=0x0;_0x5fa992<_0x3c9a7b['length'];_0x5fa992++){for(let _0x1e22d1=0x0;_0x1e22d1<_0x3c9a7b[_0x5fa992]['markersStart']['length'];_0x1e22d1++){const _0x6bf058=_0x3c9a7b[_0x5fa992]['markersStart'][_0x1e22d1];if(!_0x5f3367['has'](_0x6bf058))continue;const {group:_0x50582c,type:_0x23cfc5,authorId:_0x1c478f}=_0xd0676b(_0x6bf058);'revision-suggestion'!=_0x50582c||'insertion'!=_0x23cfc5&&'deletion'!=_0x23cfc5||(_0x2118aa['unshift']({'type':_0x23cfc5,'name':_0x6bf058,'userId':_0x1c478f}),_0x3c9a7b[_0x5fa992]['markersStart']['splice'](_0x1e22d1,0x1),_0x1e22d1--);}_0x5ed07d(_0x3c9a7b[_0x5fa992]);for(let _0xc62c54=0x0;_0xc62c54<_0x3c9a7b[_0x5fa992]['markersEnd']['length'];_0xc62c54++){const _0x1f6186=_0x3c9a7b[_0x5fa992]['markersEnd'][_0xc62c54];if(!_0x5f3367['has'](_0x1f6186))continue;const {group:_0x2c95e4,type:_0x442091}=_0xd0676b(_0x1f6186);if('revision-suggestion'!=_0x2c95e4||'insertion'!=_0x442091&&'deletion'!=_0x442091)continue;_0x3c9a7b[_0x5fa992]['markersEnd']['splice'](_0xc62c54,0x1),_0xc62c54--;const _0x51c633=_0x2118aa['findIndex'](_0x5d1919=>_0x5d1919['name']==_0x1f6186);_0x51c633>-0x1&&_0x2118aa['splice'](_0x51c633,0x1);}}function _0xd0676b(_0x16c625){const _0x5752c4=_0x16c625['split'](':');return{'group':_0x5752c4[0x0],'type':_0x5752c4[0x1],'subType':_0x5752c4['length']>=0x5?_0x5752c4[0x2]:null,'id':_0x5752c4['length']<0x5?_0x5752c4[0x2]:_0x5752c4[0x3],'authorId':_0x5752c4['length']<0x5?_0x5752c4[0x3]:_0x5752c4[0x4],'markerCount':0x6==_0x5752c4['length']?_0x5752c4[0x5]:null};}function _0x5ed07d(_0x5bcfe3){for(let _0x6495fb=0x0;_0x6495fb<_0x2118aa['length'];_0x6495fb++){if(_0x5bcfe3['isAdded']&&'insertion'==_0x2118aa[_0x6495fb]['type'])return _0x5bcfe3['isAddSuggestion']=_0x2118aa[_0x6495fb],void delete _0x5bcfe3['isAdded'];if(!_0x5bcfe3['isAdded']&&!_0x5bcfe3['isRemoved']&&'deletion'==_0x2118aa[_0x6495fb]['type'])return void(_0x5bcfe3['isRemoveSuggestion']=_0x2118aa[_0x6495fb]);}}}['_setDistance'](_0x559faf,_0xd47a0){let _0x55a62a=0x0,_0xb0d587=!0x1;const _0x659a0c=new Map();for(const _0x1e5103 of _0x559faf)_0x1e5103[_0xd47a0]?_0xb0d587&&(_0x55a62a++,_0xb0d587=!0x1):(_0x55a62a++,_0xb0d587=!0x0),_0x659a0c['set'](_0x1e5103['id'],_0x55a62a);for(let _0x37aca3=0x0;_0x37aca3<_0x559faf['length'];_0x37aca3++){if('isRemoved'==_0xd47a0&&_0x559faf[_0x37aca3]['isAdded']||'isAdded'==_0xd47a0&&_0x559faf[_0x37aca3]['isRemoved'])continue;if('text'==_0x559faf[_0x37aca3]['type']){_0x559faf[_0x37aca3]['distance']=0x0;continue;}const _0x422e43=_0x659a0c['get'](_0x559faf[_0x37aca3]['pairId']),_0x5774fd=_0x659a0c['get'](_0x559faf[_0x37aca3]['id']);_0x559faf[_0x37aca3]['distance']=_0x422e43-_0x5774fd;}}['_getRevisionsRange'](_0x3741ac,_0x3407ac,_0x57950a=!0x1){const _0x4309ef=[];let _0x1da6db=this['repository']['getIndex'](_0x3741ac),_0x268012=this['repository']['getIndex'](_0x3407ac);for(-0x1==_0x268012&&(_0x268012=this['repository']['_revisions']['length'],_0x57950a=!0x1);_0x1da6db<_0x268012;)_0x4309ef['push'](this['repository']['getRevision'](_0x1da6db)),_0x1da6db++;return _0x57950a&&_0x4309ef['push'](this['repository']['getRevision'](_0x1da6db)),_0x4309ef;}['_threeWayMerge'](_0x384f1c,_0x1019a8,_0x4f383f,_0x3439db){const _0x381b08=this['editor']['model']['schema'];let _0xce54a4=_0x1019a8;for(;_0x384f1c[_0xce54a4]&&_0x384f1c[_0xce54a4]['isAdded'];)_0xce54a4++;let _0x31de1e=_0x3439db;for(;_0x4f383f[_0x31de1e]&&_0x4f383f[_0x31de1e]['isRemoved'];)_0x31de1e++;_0x150375(_0x384f1c,_0x1019a8,_0xce54a4),_0x150375(_0x4f383f,_0x3439db,_0x31de1e);const _0xc683db=_0x4f383f['slice'](_0x3439db,_0x31de1e)['concat'](_0x384f1c['slice'](_0x1019a8,_0xce54a4));return _0xc683db['sort']((_0x70c5b1,_0x2153e9)=>_0x70c5b1['side']!=_0x2153e9['side']?_0x70c5b1['side']-_0x2153e9['side']:_0x70c5b1['level']!=_0x2153e9['level']?_0x70c5b1['level']-_0x2153e9['level']:_0x70c5b1['distance']!=_0x2153e9['distance']?_0x2153e9['distance']-_0x70c5b1['distance']:!!_0x70c5b1['isAdded']!=!!_0x2153e9['isAdded']?-0x1==_0x70c5b1['side']||0x0==_0x70c5b1['side']?_0x70c5b1['isAdded']?-0x1:0x1:_0x70c5b1['isAdded']?0x1:-0x1:_0x70c5b1['index']-_0x2153e9['index']),{'commonTape':_0xc683db,'iEnd':_0xce54a4,'jEnd':_0x31de1e};function _0x150375(_0x42b4c3,_0x32b992,_0x15d98a){let _0x543efe=-0x1,_0x43d6df=Number['POSITIVE_INFINITY'],_0x4f6322=!0x0;for(let _0x3c6c88=_0x32b992;_0x3c6c88<_0x15d98a;_0x3c6c88++)if(_0x381b08['isInline'](_0x42b4c3[_0x3c6c88]['item'])||(_0x4f6322=!0x1),_0x42b4c3[_0x3c6c88]['item']['startIndex']<_0x32b992&&(_0x543efe=_0x3c6c88),_0x42b4c3[_0x3c6c88]['item']['endIndex']>=_0x15d98a){_0x43d6df=_0x3c6c88;break;}_0x4f6322&&(_0x543efe=_0x15d98a-0x1);for(let _0x416a03=_0x32b992;_0x416a03<_0x15d98a;_0x416a03++)_0x42b4c3[_0x416a03]['side']=_0x416a03<=_0x543efe?-0x1:_0x416a03<_0x43d6df?0x0:0x1,_0x42b4c3[_0x416a03]['index']=_0x416a03;let _0x2a1777=0x0;for(let _0x4ad33b=_0x32b992;_0x4ad33b<=_0x543efe;_0x4ad33b++)0x0==_0x42b4c3[_0x4ad33b]['distance']?_0x42b4c3[_0x4ad33b]['level']=_0x2a1777:(_0x2a1777++,_0x42b4c3[_0x4ad33b]['level']=_0x2a1777,_0x2a1777++);for(let _0x50f12d=_0x32b992;_0x50f12d<_0x15d98a;_0x50f12d++)0x0==_0x42b4c3[_0x50f12d]['side']&&(_0x42b4c3[_0x50f12d]['level']=_0x2a1777);_0x2a1777=0x0;for(let _0x3ecd9b=_0x15d98a-0x1;_0x3ecd9b>=_0x43d6df;_0x3ecd9b--)0x0==_0x42b4c3[_0x3ecd9b]['distance']?_0x42b4c3[_0x3ecd9b]['level']=_0x2a1777:(_0x2a1777--,_0x42b4c3[_0x3ecd9b]['level']=_0x2a1777,_0x2a1777--);}}['_fixObsoleteTags'](_0x133e8c){const _0x525cef=new Map(),_0x38170c=this['editor']['model']['schema'];for(let _0x3d7b3d=0x1;_0x3d7b3d<_0x133e8c['length'];_0x3d7b3d++){let _0x3a2d39,_0x599893,_0x55bf07;const _0x5c19cb=_0x133e8c[_0x3d7b3d],_0x272d41=_0x133e8c[_0x3d7b3d-0x1];if('text'==_0x5c19cb['type'])continue;if(_0x5c19cb['type']!=_0x272d41['type'])continue;if(!_0x38170c['isBlock'](_0x272d41['item'])||_0x38170c['isLimit'](_0x272d41['item']))continue;if(!_0x38170c['isBlock'](_0x5c19cb['item'])||_0x38170c['isLimit'](_0x5c19cb['item']))continue;if((_0x133e8c[_0x3d7b3d]['isAdded']||_0x133e8c[_0x3d7b3d]['isAddSuggestion'])&&_0x133e8c[_0x3d7b3d-0x1]['isRemoved'])_0x3a2d39=_0x133e8c[_0x3d7b3d],_0x599893=_0x133e8c[_0x3d7b3d-0x1],_0x55bf07=_0x3d7b3d-0x1;else{if(!_0x133e8c[_0x3d7b3d]['isRemoved']||!_0x133e8c[_0x3d7b3d-0x1]['isAdded']&&!_0x133e8c[_0x3d7b3d-0x1]['isAddSuggestion'])continue;_0x3a2d39=_0x133e8c[_0x3d7b3d-0x1],_0x599893=_0x133e8c[_0x3d7b3d],_0x55bf07=_0x3d7b3d;}const _0x48e79d=_0x3a2d39['level']==_0x599893['level'],_0x3b3c63=Math['abs'](_0x3a2d39['level'])<Math['abs'](_0x599893['level'])&&0x0==_0x599893['distance'];(_0x48e79d||_0x3b3c63)&&(_0x525cef['set'](_0x599893['id'],_0x3a2d39['id']),_0x133e8c['splice'](_0x55bf07,0x1),_0x3d7b3d--,_0x3a2d39['isAdded']=!0x1);}for(let _0x1ea173=0x0;_0x1ea173<_0x133e8c['length'];_0x1ea173++)_0x525cef['has'](_0x133e8c[_0x1ea173]['pairId'])&&(_0x133e8c[_0x1ea173]['pairId']=_0x525cef['get'](_0x133e8c[_0x1ea173]['pairId']));}['_removeMissingPairs'](_0x3c4d6d){const _0x913347=new Set(_0x3c4d6d['map'](_0x472de2=>_0x472de2['id']));for(let _0x1bf638=0x0;_0x1bf638<_0x3c4d6d['length'];_0x1bf638++)_0x913347['has'](_0x3c4d6d[_0x1bf638]['pairId'])||0x0==_0x3c4d6d[_0x1bf638]['distance']||(_0x3c4d6d[_0x1bf638]['isIncorrect']=!0x0);return _0x3c4d6d['filter'](_0x478a9e=>!_0x478a9e['isIncorrect']);}['_markMismatchedRemovedTags'](_0x237e7e){const _0x5371dd=new Set();for(let _0x7b56a0=0x0;_0x7b56a0<_0x237e7e['length'];_0x7b56a0++){if(_0x5371dd['has'](_0x237e7e[_0x7b56a0]['id'])&&_0x237e7e[_0x7b56a0]['isRemoved']&&(_0x237e7e[_0x7b56a0]['isIncorrect']=!0x0),_0x237e7e[_0x7b56a0]['isIncorrect'])continue;if(0x0==_0x237e7e[_0x7b56a0]['distance'])continue;if('elementStart'!=_0x237e7e[_0x7b56a0]['type'])continue;if(null==_0x237e7e[_0x7b56a0]['pairId'])continue;let _0x285b99=_0x7b56a0+0x1,_0x16a09f=0x0;for(;_0x237e7e[_0x285b99]['id']!=_0x237e7e[_0x7b56a0]['pairId'];)'elementStart'==_0x237e7e[_0x285b99]['type']?_0x16a09f++:'elementEnd'==_0x237e7e[_0x285b99]['type']&&_0x16a09f--,_0x285b99++;if(0x0!=_0x16a09f){if(_0x237e7e[_0x7b56a0]['isRemoved'])_0x237e7e[_0x7b56a0]['isIncorrect']=!0x0;else{for(;_0x285b99!=_0x7b56a0;)_0x237e7e[_0x285b99]['isRemoved']&&0x0!=_0x237e7e[_0x285b99]['distance']&&(_0x237e7e[_0x285b99]['isIncorrect']=!0x0,_0x5371dd['add'](_0x237e7e[_0x285b99]['pairId'])),_0x285b99--;}}}return _0x237e7e['filter'](_0x58d215=>!_0x58d215['isIncorrect']);}['_removeUnsupportedChanges'](_0xa64f54){const _0x532210=this['editor']['model']['schema'];for(let _0x4e986e=0x0;_0x4e986e<_0xa64f54['length'];_0x4e986e++){if(!(_0xa64f54[_0x4e986e]['isAdded']||_0xa64f54[_0x4e986e]['isAddSuggestion']||_0xa64f54[_0x4e986e]['isRemoved']||_0xa64f54[_0x4e986e]['isRemoveSuggestion']))continue;if(0x0==_0xa64f54[_0x4e986e]['distance'])continue;const _0x3d2a21=_0xa64f54[_0x4e986e]['item'];_0x532210['isBlock'](_0x3d2a21)||_0x532210['isLimit'](_0x3d2a21)||(_0xa64f54[_0x4e986e]['isAdded']&&delete _0xa64f54[_0x4e986e]['isAdded'],_0xa64f54[_0x4e986e]['isAddSuggestion']&&delete _0xa64f54[_0x4e986e]['isAddSuggestion'],_0xa64f54[_0x4e986e]['isRemoveSuggestion']&&delete _0xa64f54[_0x4e986e]['isRemoveSuggestion'],_0xa64f54[_0x4e986e]['isRemoved']&&(_0xa64f54[_0x4e986e]['isIncorrect']=!0x0));}return _0xa64f54['filter'](_0x1729da=>!_0x1729da['isIncorrect']);}['_makeModelFromTape'](_0x330c9b,_0x5f3d1b,_0x25397c){const _0x1ea565=new gt(),_0x29fcfc=[],_0x28d765=new Map(),_0x3611e6=this['editor']['model'],_0x4335ea=_0x3611e6['schema'],_0x3d9fe4=[_0x1ea565],_0x44c7f8={},_0x37d283={'isAdded':[],'isRemoved':[],'isAddSuggestion':[],'isRemoveSuggestion':[]};let _0x408fef=null;const _0x42687a=[0x0];for(let _0x4852cb=0x0;_0x4852cb<_0x330c9b['length'];_0x4852cb++)if('elementStart'===_0x330c9b[_0x4852cb]['type']){_0x330c9b[_0x4852cb]['previousPosition']=_0x3611e6['createPositionFromPath'](_0x1ea565,_0x42687a);const _0x1f4912=new ut(_0x330c9b[_0x4852cb]['item']['name'],_0x330c9b[_0x4852cb]['item']['getAttributes']());_0x3d9fe4[0x0]['_appendChild'](_0x1f4912),_0x42687a['push'](0x0),_0x3d9fe4['unshift'](_0x1f4912),_0x330c9b[_0x4852cb]['nextPosition']=_0x3611e6['createPositionFromPath'](_0x1ea565,_0x42687a);}else'elementEnd'===_0x330c9b[_0x4852cb]['type']?(_0x3d9fe4['shift'](),_0x330c9b[_0x4852cb]['previousPosition']=_0x3611e6['createPositionFromPath'](_0x1ea565,_0x42687a),_0x42687a['pop'](),_0x42687a[_0x42687a['length']-0x1]++,_0x330c9b[_0x4852cb]['nextPosition']=_0x3611e6['createPositionFromPath'](_0x1ea565,_0x42687a)):(_0x330c9b[_0x4852cb]['previousPosition']=_0x3611e6['createPositionFromPath'](_0x1ea565,_0x42687a),_0x408fef?_0x408fef['_data']+=_0x330c9b[_0x4852cb]['item']['data']:_0x408fef=new mt(_0x330c9b[_0x4852cb]['item']['data'],_0x330c9b[_0x4852cb]['item']['getAttributes']()),_0x330c9b[_0x4852cb+0x1]&&'text'===_0x330c9b[_0x4852cb+0x1]['type']&&_0x5f0dc4(_0x408fef,_0x330c9b[_0x4852cb+0x1]['item'])||(_0x3d9fe4[0x0]['_appendChild'](_0x408fef),_0x408fef=null),_0x42687a[_0x42687a['length']-0x1]+=_0x330c9b[_0x4852cb]['item']['offsetSize'],_0x330c9b[_0x4852cb]['nextPosition']=_0x3611e6['createPositionFromPath'](_0x1ea565,_0x42687a));for(let _0x2e967f=0x0;_0x2e967f<_0x330c9b['length'];_0x2e967f++){const _0x1330c3=_0x330c9b[_0x2e967f]['previousPosition'],_0x2e4517=_0x330c9b[_0x2e967f]['nextPosition'];for(const _0x26897f of _0x330c9b[_0x2e967f]['markersStart'])_0x28d765['set'](_0x26897f,{'start':_0x1330c3,'end':null});_0x45058a('isRemoveSuggestion',_0x2e967f,_0x1330c3,_0x2e4517),_0x45058a('isAddSuggestion',_0x2e967f,_0x1330c3,_0x2e4517),_0x45058a('isRemoved',_0x2e967f,_0x1330c3,_0x2e4517),_0x45058a('isAdded',_0x2e967f,_0x1330c3,_0x2e4517);for(const _0x237f61 of _0x330c9b[_0x2e967f]['markersEnd']){const _0x211d35=_0x28d765['get'](_0x237f61);_0x211d35?_0x211d35['end']=_0x2e4517:_0x28d765['set'](_0x237f61,{'start':_0x2e4517,'end':_0x2e4517});}}for(const [_0x25f63d,_0x4030ea]of _0x28d765){const _0x495a20=this['editor']['model']['createRange'](_0x4030ea['start'],_0x4030ea['end']);_0x1ea565['markers']['set'](_0x25f63d,_0x495a20);}return _0x29fcfc['sort']((_0x2ea6f5,_0x3561e0)=>{const _0x26f14d=_0x1ea565['markers']['get']('revision:'+_0x2ea6f5['id']),_0x10c9d7=_0x1ea565['markers']['get']('revision:'+_0x3561e0['id']);return _0x26f14d['start']['isBefore'](_0x10c9d7['start'])?-0x1:_0x26f14d['start']['isAfter'](_0x10c9d7['start'])?0x1:_0x26f14d['end']['isBefore'](_0x10c9d7['end'])?-0x1:_0x26f14d['end']['isAfter'](_0x10c9d7['end'])?0x1:'add'===_0x2ea6f5['type']?-0x1:0x1;}),{'root':_0x1ea565,'changes':_0x29fcfc};function _0x45058a(_0x30cccb,_0x2d4828,_0x4a08ff,_0x3acce2){const _0x249d27=!!_0x330c9b[_0x2d4828][_0x30cccb],_0x1fb80c=_0x249d27?_0x330c9b[_0x2d4828][_0x30cccb]['userId']:null,_0x50ee13=_0x2d4828===_0x330c9b['length']-0x1,_0x5a3821=_0x37d283[_0x30cccb][0x0],_0x365212=_0x4335ea['isObject'](_0x330c9b[_0x2d4828]['item']);!_0x44c7f8[_0x30cccb]&&_0x249d27?_0x44c7f8[_0x30cccb]={'start':_0x4a08ff,'tapeItem':_0x330c9b[_0x2d4828],'userId':_0x1fb80c,'type':_0x30cccb}:_0x44c7f8[_0x30cccb]&&!_0x249d27?(_0x44c7f8[_0x30cccb]['end']=_0x4a08ff,_0x1bd327(_0x44c7f8[_0x30cccb]),_0x44c7f8[_0x30cccb]=null):_0x44c7f8[_0x30cccb]&&_0x249d27&&_0x44c7f8[_0x30cccb]['userId']!==_0x1fb80c&&(_0x44c7f8[_0x30cccb]['end']=_0x4a08ff,_0x5a3821&&_0x5a3821['userId']===_0x44c7f8[_0x30cccb]['userId']||_0x1bd327(_0x44c7f8[_0x30cccb]),_0x44c7f8[_0x30cccb]={'start':_0x4a08ff,'tapeItem':_0x330c9b[_0x2d4828],'userId':_0x1fb80c,'type':_0x30cccb}),_0x44c7f8[_0x30cccb]&&_0x365212&&('elementStart'!==_0x330c9b[_0x2d4828]['type']||_0x5a3821&&_0x5a3821['userId']===_0x1fb80c||_0x37d283[_0x30cccb]['unshift']({'userId':_0x1fb80c,'object':_0x330c9b[_0x2d4828]['item'],'change':_0x44c7f8[_0x30cccb]}),'elementEnd'===_0x330c9b[_0x2d4828]['type']&&_0x5a3821&&_0x5a3821['object']===_0x330c9b[_0x2d4828]['item']&&(_0x37d283[_0x30cccb]['shift'](),_0x44c7f8[_0x30cccb]=_0x5a3821['change'])),_0x44c7f8[_0x30cccb]&&_0x50ee13&&(_0x44c7f8[_0x30cccb]['end']=_0x3acce2,_0x1bd327(_0x44c7f8[_0x30cccb]),_0x44c7f8[_0x30cccb]=null);}function _0x1bd327({start:_0x29bad1,end:_0xb19465,tapeItem:_0xbd6fc6,userId:_0x26d0f1,type:_0x4a1305}){const _0x5c5d3b=_0xbd6fc6['item'],_0x3c7216=_0x3611e6['schema']['isBlock'](_0x5c5d3b)&&!_0x3611e6['schema']['isLimit'](_0x5c5d3b),_0xaae6ac=_0x29bad1['nodeAfter']==_0xb19465['parent']&&_0xb19465['isAtStart'];if(_0x3c7216&&_0xaae6ac)return;const _0x9754ff=_0x3611e6['createRange'](_0x29bad1,_0xb19465),_0xc08b39=_0x5f3d1b['get'](_0x26d0f1),_0x4fb560=new r({'author':_0xc08b39,'type':'isAdded'==_0x4a1305||'isAddSuggestion'==_0x4a1305?'add':'remove','data':{'isSuggestion':'isAddSuggestion'==_0x4a1305||'isRemoveSuggestion'==_0x4a1305},'createdAt':new Date(),'rootName':_0x25397c});_0x29fcfc['push'](_0x4fb560),_0x1ea565['markers']['set']('revision:'+_0x4fb560['id'],_0x9754ff);}function _0x5f0dc4(_0x1b4a41,_0x3d4d1e){const _0x29dfd=_0x1b4a41['getAttributes'](),_0x8f1ccd=_0x3d4d1e['getAttributes']();for(const _0x2406ba of _0x29dfd){if(_0x2406ba[0x1]!==_0x3d4d1e['getAttribute'](_0x2406ba[0x0]))return!0x1;_0x8f1ccd['next']();}return _0x8f1ccd['next']()['done'];}}['_setConversion'](){this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision','view':_0x50fbc3=>{const _0x1558ce=_0x50fbc3['markerName']['split'](':')[0x1],_0x1c3094=this['_getChangeFromId'](_0x1558ce);if(!_0x1c3094)return null;const _0x36fb40='add'==_0x1c3094['type']?'insertion':'deletion',_0x301858=['ck-suggestion-marker','ck-suggestion-marker-'+_0x36fb40];return _0x1c3094['data']['isSuggestion']&&_0x301858['push']('ck-suggestion-marker-'+_0x36fb40+'-new'),this['activeChange']==_0x1c3094&&_0x301858['push']('ck-suggestion-marker--active'),{'classes':_0x301858,'attributes':{'data-change-id':_0x1558ce}};}}),this['editor']['conversion']['for']('upcast')['add'](_0x22ddb0=>{_0x22ddb0['on']('element:pre',(_0x43d8a2,_0xd82441,_0x429dbc)=>{const _0x246227=_0xd82441['viewItem']['getChild'](0x0);if(!_0x246227||!_0x246227['is']('element','code'))return;if(!_0x429dbc['consumable']['consume'](_0x246227,{'attributes':['vid_start','vid_end']}))return;const _0x2aace0=_0xd82441['modelRange']['start']['nodeAfter'];_0x429dbc['writer']['setAttribute']('vid_start',_0x246227['getAttribute']('vid_start'),_0x2aace0),_0x429dbc['writer']['setAttribute']('vid_end',_0x246227['getAttribute']('vid_end'),_0x2aace0);},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['add'](_0xde4a28=>{_0xde4a28['on']('element',(_0x279ace,_0x34acf6,_0x1dc5b0)=>{if(!_0x1dc5b0['consumable']['consume'](_0x34acf6['viewItem'],{'attributes':['vid_start','vid_end']}))return;if(_0x34acf6['modelRange']['isCollapsed'])return;const _0x52cb7b=_0x34acf6['modelRange']['start']['nodeAfter'];_0x52cb7b['hasAttribute']('vid_start')||_0x52cb7b['hasAttribute']('vid')||(_0x1dc5b0['writer']['setAttribute']('vid_start',_0x34acf6['viewItem']['getAttribute']('vid_start'),_0x52cb7b),_0x1dc5b0['writer']['setAttribute']('vid_end',_0x34acf6['viewItem']['getAttribute']('vid_end'),_0x52cb7b));},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['elementToAttribute']({'view':{'name':'span','attributes':{'vid':!0x0}},'model':{'key':'vid','value':_0x413bc5=>_0x413bc5['getAttribute']('vid')}}),this['editor']['model']['schema']['on']('checkAttribute',(_0x425177,[,_0x348ff7])=>{['vid_start','vid_end','vid']['includes'](_0x348ff7)&&(_0x425177['return']=!0x0,_0x425177['stop']());},{'priority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x15b45e=>{_0x15b45e['on']('attribute:vid',(_0x59a03b,_0x4cca08,_0x1daf96)=>{if('\x20'!=_0x4cca08['item']['data']||_0x4cca08['item']['parent']['maxOffset']>0x1)return;if(!_0x1daf96['consumable']['consume'](_0x4cca08['item'],_0x59a03b['name']))return;const _0x210a43=_0x1daf96['writer'],_0xc1297b=_0x1daf96['mapper']['toViewRange'](_0x4cca08['range']);_0x210a43['wrap'](_0xc1297b,_0x210a43['createAttributeElement']('span'));});}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',function(_0x4d81c5){const _0x26b9ab=_0x4d81c5['plugins']['get']('RevisionViewer');return(_0x20a30d,_0x5c7838,_0x401607)=>{const _0x20ca88=_0x5c7838['markerName']['split'](':')[0x1],_0x52a17c=_0x26b9ab['_getChangeFromId'](_0x20ca88);if(!_0x52a17c)return null;const _0x4e2fa8='add'==_0x52a17c['type']?'split':'merge';if(!_0x401607['consumable']['test'](_0x5c7838['markerRange'],_0x20a30d['name']))return;const _0x1a9fea=_0x5c7838['markerRange']['getWalker'](),_0x3b4b85=_0x5c7838['markerRange']['start'],_0x4143ff=_0x4d81c5['model']['schema'];let _0x4a94b6=null,_0x594c37=null,_0x26bd38=!0x1,_0x347a3b=!0x1;for(const _0x51ceae of _0x1a9fea){const _0x3b9831=_0x51ceae['item'];_0x26bd38=_0x26bd38||_0x4143ff['isContent'](_0x3b9831);const _0x4f41f5=_0x401607['mapper']['toViewElement'](_0x3b9831);if(_0x4f41f5&&_0x4f41f5['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x51ceae['type']&&(_0x4143ff['isBlock'](_0x3b9831)&&!_0x4143ff['isLimit'](_0x3b9831)&&(_0x3b9831['nextSibling']||_0x3b4b85['isAtEnd']?_0x4a94b6&&_0x4a94b6['parent']==_0x3b9831||(_0x4a94b6=_0x3b9831,_0x36d2e1(_0x51ceae['previousPosition']),_0x347a3b=!0x0):_0x594c37=_0x594c37||_0x51ceae['previousPosition']));}function _0x36d2e1(_0x1ada18){const _0x578e0b=_0x401607['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x4e2fa8}),_0x419a39=_0x401607['mapper']['toViewPosition'](_0x1ada18);_0x52a17c['data']['isSuggestion']&&_0x401607['writer']['addClass']('ck-suggestion-marker-'+_0x4e2fa8+'-new',_0x578e0b),_0x26b9ab['activeChange']==_0x52a17c&&_0x401607['writer']['addClass']('ck-suggestion-marker--active',_0x578e0b),_0x401607['writer']['insert'](_0x419a39,_0x578e0b),_0x401607['mapper']['bindElementToMarker'](_0x578e0b,_0x5c7838['markerName']);}_0x26bd38||_0x347a3b||!_0x594c37||_0x36d2e1(_0x594c37);};}(this['editor']),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision',(_0x10efb4,_0x4537d2,_0xd671dd)=>{const _0x1b921a=_0xd671dd['mapper']['markerNameToElements'](_0x4537d2['markerName']);if(_0x1b921a){for(const _0x3e60d4 of _0x1b921a)(_0x3e60d4['hasClass']('ck-suggestion-marker-split')||_0x3e60d4['hasClass']('ck-suggestion-marker-merge'))&&(_0xd671dd['mapper']['unbindElementFromMarkerName'](_0x3e60d4,_0x4537d2['markerName']),_0xd671dd['writer']['remove'](_0x3e60d4));}},{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',(_0x2eb2f0,_0x5ef584,_0x21371a)=>{const _0x2c62dd=_0x5ef584['markerName']['split'](':')[0x1],_0x1585e1=this['_getChangeFromId'](_0x2c62dd);if(!_0x1585e1)return null;const _0x5c29a7='add'==_0x1585e1['type']?'split':'merge';if(_0x21371a['consumable']['test'](_0x5ef584['markerRange'],_0x2eb2f0['name']))for(const _0x3caf3d of _0x5ef584['markerRange']['getItems']()){if(!_0x3caf3d['is']('element','softBreak'))continue;const _0x41c8d8=_0x21371a['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x5c29a7}),_0x365fd3=_0x21371a['mapper']['toViewPosition'](this['editor']['model']['createPositionBefore'](_0x3caf3d));_0x1585e1['data']['isSuggestion']&&_0x21371a['writer']['addClass']('ck-suggestion-marker-'+_0x5c29a7+'-new',_0x41c8d8),this['activeChange']==_0x1585e1&&_0x21371a['writer']['addClass']('ck-suggestion-marker--active',_0x41c8d8),_0x21371a['writer']['insert'](_0x365fd3,_0x41c8d8),_0x21371a['mapper']['bindElementToMarker'](_0x41c8d8,_0x5ef584['markerName']);}},{'priority':'high'}),this['editor']['model']['document']['on']('change',()=>{this['editor']['editing']['view']['change'](_0x5c6061=>{for(const _0xc178d1 of this['editor']['model']['document']['getRootNames']()){const _0x41dc7e=this['editor']['model']['document']['getRoot'](_0xc178d1),_0x3fe62a=this['editor']['editing']['view']['document']['getRoot'](_0xc178d1);if(_0x3fe62a){const _0x87cba6=_0x41dc7e['getAttribute']('revisionHistoryAttachChange');if(_0x5c6061['removeAttribute']('data-change-id',_0x3fe62a),_0x5c6061['removeClass']('ck-revision-history-root-add',_0x3fe62a),_0x5c6061['removeClass']('ck-revision-history-root-remove',_0x3fe62a),_0x5c6061['removeClass']('ck-revision-history-root--active',_0x3fe62a),_0x87cba6){const _0x242dd3=this['_getChangeFromId'](_0x87cba6);if(!_0x242dd3)return null;_0x5c6061['setAttribute']('data-change-id',_0x87cba6,_0x3fe62a),_0x5c6061['addClass']('ck-revision-history-root-'+_0x242dd3['type'],_0x3fe62a),this['activeChange']==_0x242dd3&&_0x5c6061['addClass']('ck-revision-history-root--active',_0x3fe62a);}}}});}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'comment','model':_0x1c9485=>'revision-comment:'+_0x1c9485,'converterPriority':'highest'}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'suggestion','model':_0x10c43d=>'revision-suggestion:'+_0x10c43d,'converterPriority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision-suggestion','view':_0x2b43ba=>({'name':'suggestion:'+_0x2b43ba,'group':'revision-suggestion'}),'converterPriority':'highest'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision-suggestion','view':_0x2832ac=>{const _0x252f04=_0x2832ac['markerName']['split'](':')[0x1];return'insertion'!=_0x252f04&&'deletion'!=_0x252f04?null:{'classes':['ck-suggestion-preview-marker','ck-suggestion-preview-marker-'+_0x252f04]};}}),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',(_0xb87fd3,_0x845cbd,_0x5139b7)=>{const _0x1b39f3=_0x5139b7['mapper']['markerNameToElements'](_0x845cbd['markerName']);if(_0x1b39f3){for(const _0x4f60b8 of _0x1b39f3)_0x4f60b8['is']('uiElement')&&(_0x5139b7['mapper']['unbindElementFromMarkerName'](_0x4f60b8,_0x845cbd['markerName']),_0x5139b7['writer']['remove'](_0x4f60b8));}},{'priority':'high'});}['_getChangeFromId'](_0x459554){return this['_changeIdToChange']['get'](_0x459554);}['_getViewForChange'](_0xdb23da){return this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=new Q(this['editor']['locale'],_0xdb23da),this['_changeView'];}['_initInteractions'](){this['editor']['model']['document']['selection']['observeMarkers']('revision'),this['on']('change:activeView',(_0xb4776b,_0x5cf33a,_0x21ae4c,_0x38c757)=>{_0x38c757&&this['_balloon']['remove'](_0x38c757),_0x21ae4c&&(this['_balloon']['add']({'view':_0x21ae4c,'stackId':'revisionHistoryLabel','position':{'target':()=>{const _0x46030c=this['editor']['editing'],_0x396e84=this['_getChangeFromId'](_0x21ae4c['changeId']);let _0x672b41;if(_0x396e84['data']['isOnRoot']){const _0x2f6854=_0x46030c['view']['getDomRoot'](_0x396e84['rootName']);_0x672b41=Array['from'](_0x2f6854['getClientRects']());}else{const _0x48c435=this['editor']['model']['markers']['get']('revision:'+_0x21ae4c['changeId']);_0x672b41=Array['from'](_0x46030c['mapper']['markerNameToElements'](_0x48c435['name']))['map'](_0x58b678=>_0x46030c['view']['domConverter']['mapViewToDom'](_0x58b678))['map'](_0x27919e=>Array['from'](_0x27919e['getClientRects']()))['flat']();}if(!this['_activeViewTarget'])return _0x672b41[0x0];return _0x672b41['find'](_0x4ee14d=>_0x4ee14d['top']-0x3<=this['_activeViewTarget']['y']&&_0x4ee14d['bottom']+0x3>=this['_activeViewTarget']['y']&&_0x4ee14d['left']-0x3<=this['_activeViewTarget']['x']&&_0x4ee14d['right']+0x3>=this['_activeViewTarget']['x'])||_0x672b41[0x0];}}}),this['_balloon']['showStack']('revisionHistoryLabel'));}),this['on']('change:activeChange',(_0xfdbb37,_0x1deb04,_0x326b54,_0x5705d0)=>{this['activeView']=_0x326b54?this['_getViewForChange'](_0x326b54):null,this['editor']['model']['change'](()=>{const _0x46b23c=this['editor']['editing'];_0x5705d0&&(_0x5705d0['data']['isOnRoot']?_0x46b23c['view']['change'](_0x2d5803=>{_0x2d5803['removeClass']('ck-revision-history-root--active',_0x46b23c['view']['document']['getRoot'](_0x5705d0['rootName']));}):_0x46b23c['reconvertMarker']('revision:'+_0x5705d0['id'])),_0x326b54&&(_0x326b54['data']['isOnRoot']?_0x46b23c['view']['change'](_0x4c762e=>{_0x4c762e['addClass']('ck-revision-history-root--active',_0x46b23c['view']['document']['getRoot'](_0x326b54['rootName']));}):_0x46b23c['reconvertMarker']('revision:'+_0x326b54['id']));});}),this['listenTo'](this['editor']['editing']['view']['document'],'mouseover',(_0x1b2eb0,_0x4f7c46)=>{if(this['activeChange'])return;const _0x41846a=this['_findChangeIdFromDomTarget'](_0x4f7c46['target']),_0x56dd97=this['_changeIdToChange']['get'](_0x41846a);_0x56dd97?(this['_activeViewTarget']={'x':_0x4f7c46['domEvent']['x'],'y':_0x4f7c46['domEvent']['y']},this['activeView']=this['_getViewForChange'](_0x56dd97)):(this['_activeViewTarget']=null,this['activeView']=null);}),this['listenTo'](this['editor']['editing']['view']['document'],'mousedown',(_0x40a861,_0x403e2b)=>{const _0x554a99=this['_findChangeIdFromDomTarget'](_0x403e2b['target']),_0x1b7770=this['_changeIdToChange']['get'](_0x554a99);_0x1b7770?(this['_activeViewTarget']={'x':_0x403e2b['domEvent']['x'],'y':_0x403e2b['domEvent']['y']},_0x1b7770===this['activeChange']?this['_balloon']['updatePosition']():this['activeChange']=_0x1b7770):(this['_activeViewTarget']=null,this['activeChange']=null);});}['_findChangeIdFromDomTarget'](_0x55c426){do{const _0x41b0c5=_0x55c426['getAttribute']('data-change-id');if(_0x41b0c5)return _0x41b0c5;_0x55c426=_0x55c426['parent'];}while(_0x55c426);return null;}['_cleanMarkers'](){this['editor']['model']['change'](_0x1a0e6f=>{for(const _0x148402 of this['editor']['model']['markers'])_0x1a0e6f['removeMarker'](_0x148402);});}}function X(_0x4b3036,_0x55cc41){return(_0x491db3,_0x3dff44,_0x5e5c0b)=>{if(!_0x5e5c0b['consumable']['test'](_0x3dff44['markerRange'],_0x491db3['name']))return;const _0x4e7e29=_0x3dff44['markerRange']['getWalker'](),_0x2edb79=_0x3dff44['markerRange']['start'],_0x51e579=_0x4b3036['model']['schema'];let _0x14abef=null,_0x3317e9=null,_0x44adb6=!0x1,_0x5a96be=!0x1;for(const _0x2c6379 of _0x4e7e29){const _0x460994=_0x2c6379['item'];_0x44adb6=_0x44adb6||_0x51e579['isContent'](_0x460994);const _0x1550aa=_0x5e5c0b['mapper']['toViewElement'](_0x460994);if(_0x1550aa&&_0x1550aa['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x2c6379['type']&&(_0x51e579['isBlock'](_0x460994)&&!_0x51e579['isLimit'](_0x460994)&&(_0x460994['nextSibling']||_0x2edb79['isAtEnd']?_0x14abef&&_0x14abef['parent']==_0x460994||(_0x14abef=_0x460994,_0x3bec0c(_0x2c6379['previousPosition']),_0x5a96be=!0x0):_0x3317e9=_0x3317e9||_0x2c6379['previousPosition']));}function _0x3bec0c(_0x30a00d){const _0x1a88a8=_0x5e5c0b['mapper']['toViewPosition'](_0x30a00d),_0x34183a=_0x5e5c0b['writer']['createUIElement']('span',{'class':'ck-suggestion-preview-marker-'+_0x55cc41});_0x5e5c0b['writer']['insert'](_0x1a88a8,_0x34183a),_0x5e5c0b['mapper']['bindElementToMarker'](_0x34183a,_0x3dff44['markerName']);}_0x44adb6||_0x5a96be||!_0x3317e9||_0x3bec0c(_0x3317e9);};}class wt extends _0x4024a8{constructor(_0x5aa5bd){super(_0x5aa5bd);const _0x2e9d27=_0x5aa5bd['plugins']['get'](m);this['affectsData']=!0x1,this['listenTo'](_0x2e9d27,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x2e9d27,'change:isEnabled',()=>this['refresh']());}['execute'](){const _0x52e802=this['editor'],_0x1f79c2=_0x52e802['plugins']['get'](m),_0x31bf7d=_0x1f79c2['isReady']?_0x1f79c2['diff']['newRevisionId']:null;_0x52e802['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x31bf7d);}['refresh'](){const {isReady:_0x417106,isEnabled:_0x7ea6e,repository:_0x571a44,diff:_0x216650}=this['editor']['plugins']['get'](m),_0x40f484=_0x216650&&_0x571a44['getLaterVisibleRevision'](_0x216650['newRevisionId']);this['isEnabled']=_0x417106&&_0x7ea6e&&Boolean(_0x40f484);}}class pt extends _0x4024a8{['_step'];constructor(_0x1418e8,{direction:_0x4905f2}){super(_0x1418e8);const _0x5440e7=_0x1418e8['plugins']['get'](m);this['affectsData']=!0x1,this['_step']='forward'===_0x4905f2?0x1:-0x1,this['listenTo'](_0x5440e7,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x5440e7,'change:isEnabled',()=>this['refresh']()),this['listenTo'](_0x5440e7,'change:activeChange',()=>this['refresh']());}['execute'](){const _0x4e0aa0=this['editor'],_0x25810d=_0x4e0aa0['plugins']['get'](m),{isNavigationMode:_0x18ed88,currentChangeNumber:_0x4a0049}=_0x25810d;let _0x5c6025;if(_0x25810d['activeChange']=_0x18ed88?_0x25810d['diff']['changes']['get'](_0x4a0049+this['_step']):_0x25810d['diff']['changes']['first'],_0x25810d['activeChange']['data']['isOnRoot'])_0x5c6025=_0x4e0aa0['editing']['view']['getDomRoot'](_0x25810d['activeChange']['rootName']);else{const _0x505990=_0x4e0aa0['model']['markers']['get']('revision:'+_0x25810d['activeChange']['id']);_0x5c6025=_0xba3d92(_0x4e0aa0['editing'],_0x505990);}_0x4c6269({'target':_0x5c6025,'viewportOffset':0x28});}['refresh'](){const {isNavigationMode:_0x264926,currentChangeNumber:_0x4fef2d,numberOfChanges:_0x32daaa,isReady:_0x60a649,isEnabled:_0x1f4739}=this['editor']['plugins']['get'](m);this['isEnabled']=!!(_0x1f4739&&_0x60a649&&_0x32daaa)&&(!_0x264926||(0x1===this['_step']?_0x4fef2d<_0x32daaa-0x1:_0x4fef2d>0x0));}}class _i extends _0x45ce53{constructor(_0x3d3f82){super(_0x3d3f82);const _0x311b6d=this['bindTemplate'],_0x82d936=new _0xf1e793(_0x3d3f82),_0x52fb6f=new _0xf1e793(_0x3d3f82);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',(_0x5c1b25,_0x54b56c)=>_0x5c1b25&&_0x54b56c>0x0),this['bind']('_statusText')['to'](this,'isReady',this,'currentChangeNumber',this,'numberOfChanges',this,'isNavigationMode',(_0x242600,_0x583981,_0x4ff6ac,_0x9dd539)=>{if(!_0x242600)return g(_0x3d3f82,'Loading...');if(!_0x4ff6ac)return g(_0x3d3f82,'No\x20changes');const _0x2ce6f0=g(_0x3d3f82,'NUMBER_OF_CHANGES',_0x4ff6ac);return _0x9dd539?g(_0x3d3f82,'X_OF_Y_CHANGES',[_0x583981+0x1,_0x4ff6ac]):_0x2ce6f0;}),_0x82d936['set']({'label':g(_0x3d3f82,'Show\x20previous\x20change'),'tooltip':!0x0,'icon':_0x2859cd}),_0x52fb6f['set']({'label':g(_0x3d3f82,'Show\x20next\x20change'),'tooltip':!0x0,'icon':_0x4e16f1}),_0x82d936['bind']('isEnabled')['to'](this,'isBackwardNavigationEnabled'),_0x52fb6f['bind']('isEnabled')['to'](this,'isForwardNavigationEnabled'),_0x82d936['on']('execute',()=>this['fire']('execute','backward')),_0x52fb6f['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',_0x311b6d['if']('_isStatusLabelVisible','ck-hidden',_0x36ca14=>!_0x36ca14)]},'children':[{'text':_0x311b6d['to']('isNavigationMode',_0x34f1ec=>_0x34f1ec?g(_0x3d3f82,'EDIT_X_OF_Y_REVISIONS')+':\x20':g(_0x3d3f82,'Total')+':\x20')}]},{'text':_0x311b6d['to']('_statusText')}]},new _0x4a94af(),{'tag':'div','attributes':{'class':['ck-revision-history-ui__changes-navigation__navigation']},'children':[_0x82d936,_0x52fb6f]}]});}}const ce='ck-editor__editable__loading-overlay';class le extends _0x58bc6f{static get['pluginName'](){return'RevisionViewerLoadingOverlay';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['show'](){const _0x2e934e=this['editor']['editing']['view'];_0x2e934e['change'](_0x1a5dda=>{for(const _0x4e799f of _0x2e934e['document']['roots'])_0x1a5dda['addClass'](ce,_0x4e799f);});}['hide'](){const _0x172c5=this['editor']['editing']['view'];_0x172c5['change'](_0x5ef6f9=>{for(const _0x28cb88 of _0x172c5['document']['roots'])_0x5ef6f9['removeClass'](ce,_0x28cb88);});}}class R extends _0x58bc6f{static get['pluginName'](){return'RevisionViewerUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[m,le];}['init'](){const _0x46e4cc=this['editor'],_0x5c4960=_0x46e4cc['plugins']['get'](m),_0x230a4c=_0x46e4cc['plugins']['get'](le);_0x46e4cc['ui']['componentFactory']['add']('exitToEditing',_0x5ee7cd=>{const _0x1f684f=new _0xf1e793(_0x5ee7cd);return _0x1f684f['set']({'label':g(_0x5ee7cd,'Back\x20to\x20editing'),'icon':_0x529c1c,'withText':!0x0,'tooltip':!0x0,'class':'ck-revision-history-ui__back-to-editing'}),this['listenTo'](_0x1f684f,'execute',()=>{_0x46e4cc['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}),_0x1f684f;}),_0x46e4cc['ui']['componentFactory']['add']('restoreRevision',_0x24d0a8=>{const _0x21a06e=new _0xf1e793(_0x24d0a8);return _0x21a06e['set']({'label':g(_0x24d0a8,'Restore\x20this\x20revision'),'withText':!0x0,'tooltip':!0x0}),_0x21a06e['bind']('isEnabled')['to'](_0x46e4cc['commands']['get']('restoreRevision')),this['listenTo'](_0x21a06e,'execute',()=>_0x46e4cc['execute']('restoreRevision')),_0x21a06e;}),_0x46e4cc['ui']['componentFactory']['add']('changesNavigation',_0x319903=>{const _0xb8316=new _i(_0x319903),_0x1477a0=_0x46e4cc['commands']['get']('showPreviousChange'),_0x1e3a41=_0x46e4cc['commands']['get']('showNextChange');return _0xb8316['bind']('isBackwardNavigationEnabled')['to'](_0x1477a0,'isEnabled'),_0xb8316['bind']('isForwardNavigationEnabled')['to'](_0x1e3a41,'isEnabled'),_0xb8316['bind']('isReady','currentChangeNumber','numberOfChanges','isNavigationMode')['to'](_0x5c4960),this['listenTo'](_0xb8316,'execute',(_0x19a052,_0xe472ed)=>{_0x46e4cc['execute']('forward'===_0xe472ed?'showNextChange':'showPreviousChange');}),_0xb8316;}),_0x230a4c['show'](),_0x5c4960['on']('change:isReady',(_0x38003e,_0x3377de,_0x442f7b)=>{_0x442f7b?_0x230a4c['hide']():_0x230a4c['show']();});}}class lt extends nt{['_resizeObserver']=null;constructor(_0xf156d0,_0x47b3d3){super(_0xf156d0,_0x47b3d3);const _0x1c58e7=this['bindTemplate'];this['set']({'label':g(_0xf156d0,'Revision\x20name'),'_tooltipString':''}),this['fieldView']['placeholder']=g(_0xf156d0,'Enter\x20the\x20revision\x20name'),this['extendTemplate']({'tag':'span','attributes':{'class':['ck-revision-history-sidebar__revision-name'],'data-cke-tooltip-text':_0x1c58e7['to']('_tooltipString'),'data-cke-tooltip-position':'s','data-cke-tooltip-class':'ck-tooltip_multi-line'}});}['render'](){super['render'](),this['_resizeObserver']=new at(this['fieldView']['element'],()=>this['_updateTooltipText']()),this['listenTo'](this['fieldView'],'input',()=>this['_updateTooltipText']());}['destroy'](){super['destroy'](),this['_resizeObserver']&&this['_resizeObserver']['destroy']();}['_updateTooltipText'](){const _0x372a4a=this['fieldView']['element'];this['_tooltipString']=_0x372a4a['scrollWidth']>_0x372a4a['clientWidth']&&_0x372a4a['value']||'';}}class oi extends _0x45ce53{constructor(_0x233777,_0x539a58,_0x5c713c){super(_0x233777);const _0x56e2dc=new _0x28f921();_0x56e2dc['set']({'content':_0x1f2c16,'viewBox':'0\x200\x2011\x2010'});const _0xf28b48=['ck','ck-revision-history-sidebar__revision-author'];_0x5c713c&&_0xf28b48['push']('ck-revision-history-sidebar__revision-author_creator');const _0xf7232d=[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision-author__name'],'title':g(_0x233777,_0x5c713c?'Revision\x20creator':'Revision\x20author')},'children':[_0x56e2dc,_0x539a58['name']]}];this['setTemplate']({'tag':'li','attributes':{'class':_0xf28b48},'children':_0xf7232d});}}function ni(_0x16c184,_0x4198a0){const _0x549d8e=_0x16c184['bindTemplate'],_0x161ab2=_0x16c184['locale'],_0x1b45e7=_0xbd0f73(_0x161ab2);_0x1b45e7['panelPosition']='sw';const _0x84617b=function(_0x14a527,_0x49f751){const _0x43e64f=function(_0xe3a746,_0x56cea7){const _0x484a4f=_0xe3a746['locale'],_0x36b903={'Compare\x20against\x20selected':g(_0x484a4f,'Compare\x20against\x20selected'),'Name\x20this\x20revision':g(_0x484a4f,'Name\x20this\x20revision'),'Restore\x20this\x20revision':g(_0x484a4f,'Restore\x20this\x20revision')};return _0x56cea7['map'](_0x20b2ad=>{const _0x30f0cd=_0x36b903[_0x20b2ad['name']];return _0x30f0cd&&_0x30f0cd!==_0x20b2ad['name']&&(_0x20b2ad['name']=_0x30f0cd),_0x20b2ad;});}(_0x14a527,_0x49f751),_0xd1a87a=new _0x4aa85f();for(const _0x530a64 of _0x43e64f){const _0x3670b9={'type':'button','model':new to({'label':_0x530a64['name'],'class':_0x530a64['class'],'withText':!0x0,'role':'menuitem','_action':_0x530a64['action']})};_0x3670b9['model']['bind']('isEnabled')['to'](_0x14a527,'isActionsDropdownOpen',_0xdf995d=>'function'!=typeof _0x530a64['isEnabled']||(!_0xdf995d||_0x530a64['isEnabled'](_0x14a527))),_0xd1a87a['add'](_0x3670b9);}return _0xd1a87a;}(_0x16c184,_0x4198a0);return _0x16c184['bind']('isActionsDropdownOpen')['to'](_0x1b45e7,'isOpen'),_0x1b45e7['buttonView']['set']({'label':g(_0x161ab2,'Show\x20more\x20items'),'tooltip':!0x0,'tooltipPosition':'sw','icon':_0x60fa10}),_0x1b45e7['extendTemplate']({'attributes':{'class':['ck-revision-history-sidebar__revision__actions',_0x549d8e['if']('isActionsDropdownOpen','ck-on')]},'on':{'click':_0x549d8e['to'](_0x19b179=>_0x19b179['stopPropagation']())}}),_0x1b45e7['on']('execute',_0x5d7bdd=>{_0x16c184['isReady']&&'function'==typeof _0x5d7bdd['source']['_action']&&_0x5d7bdd['source']['_action'](_0x16c184);}),_0x2116eb(_0x1b45e7,_0x84617b,{'role':'menu'}),_0x1b45e7['listenTo'](_0x16c184,'change:isActionsDropdownOpen',(_0x323619,_0x1b113a,_0xb21d80)=>{if(_0xb21d80)for(const _0x500f6e of _0x1b45e7['listView']['items']){const _0x520e6c=_0x500f6e['children']['first'],_0x197269=_0x4198a0['find'](_0x5d02ea=>_0x5d02ea['action']===_0x520e6c['_action'])['isVisible'];_0x500f6e['isVisible']=void 0x0===_0x197269||_0x197269(_0x16c184);}}),_0x1b45e7;}class ai extends/* #__PURE__ -- @preserve */
|
|
26
|
-
|
|
23
|
+
import{ObservableMixin as _0x11f117,uid as _0x571ba5,Collection as _0x3f8e7a,logWarning as _0x39c6af,FocusTracker as _0x338ab8,KeystrokeHandler as _0x143d1e,scrollViewportToShowTarget as _0x47b4d2,ResizeObserver as nt,ElementReplacer as ot,CKEditorError as _0x5afe82}from'@ckeditor/ckeditor5-utils/dist/index.js';import{cloneDeep as _0x503699,set as _0x2bcce7,unset as _0x1e57ba,isEqual as _0x3cd36b}from'es-toolkit/compat';import{Plugin as _0x527fd9,PendingActions as _0x3d46e5,Command as _0x4a9630,ElementApiMixin as _0x52547e,Editor as _0x3270d8}from'@ckeditor/ckeditor5-core/dist/index.js';import{Users as _0x386857,getMarkerDomElement as _0x5b2979,ConfirmMixin as ti,sanitizeEditorConfig as _0x5ba2f0}from'ckeditor5-collaboration/dist/index.js';import{ViewContainerElement as _0x5942a7,ViewAttributeElement as _0x49ccc4,ViewEmptyElement as _0x409f3d,ViewRawElement as _0x4d034c,ViewUIElement as _0x20e593,ViewDocumentFragment as _0x2a3854,ViewText as _0x48de41,ViewElement as _0x257259,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 _0x278e4f,IconChevronUp as _0x157ddd,IconChevronDown as _0x577587,IconUndo as _0x42d483,IconUser as _0x594709,IconThreeVerticalDots as _0x14de33}from'@ckeditor/ckeditor5-icons/dist/index.js';import{View as ts,injectCssTransitionDisabler as _0x149bf4,submitHandler as _0x451b44,LabeledFieldView as _0x4a54d4,createLabeledInputText as _0x37da91,createDropdown as _0x2bb1f1,ListView as _0x28cadf,ListItemView as _0x3bce81,ButtonView as te,MenuBarMenuView as _0x77737,MenuBarMenuListView as _0x4c1111,MenuBarMenuListItemView as _0x94bb0e,MenuBarMenuListItemButtonView as _0x1308fb,ContextualBalloon as _0x3e17e6,ToolbarSeparatorView as _0x2f1e4b,IconView as _0x226077,addListToDropdown as _0x43d39a,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 _0x3f3942}from'luxon';class h extends/* #__PURE__ -- @preserve */
|
|
24
|
+
_0x11f117(){['id'];['creator'];['authors'];['diffData'];['toVersion'];['fromVersion'];['model'];constructor(_0x408d45){super(),this['id']=_0x408d45['id']||_0x571ba5(),this['creator']=_0x408d45['creator']||null,this['authors']=_0x408d45['authors']||[],this['diffData']=_0x408d45['diffData']||null,this['toVersion']=_0x408d45['toVersion']||0x0,this['fromVersion']=_0x408d45['fromVersion']||0x0,this['set']('name',_0x408d45['name']||''),this['set']('createdAt',_0x408d45['createdAt']||new Date()),this['set']('attributes',_0x408d45['attributes']||{});}['setName'](_0xf6fbf7){this['_update']({'name':_0xf6fbf7});}['setAttribute'](_0xfe05b7,_0xd80ffd){const _0x4ac458=_0x503699(this['attributes']);_0x2bcce7(_0x4ac458,_0xfe05b7,_0xd80ffd),this['_update']({'attributes':_0x4ac458});}['removeAttribute'](_0x75282){const _0x2c20eb=_0x503699(this['attributes']);_0x1e57ba(_0x2c20eb,_0x75282),this['_update']({'attributes':_0x2c20eb});}['_update'](_0x1569d2,_0x1fa4b9=!0x1){let _0x25c99b=!0x1;const _0x58e708={'id':this['id']},_0x490b1c=['name','createdAt','diffData','authors','attributes','toVersion','fromVersion','creatorId'];for(const _0xe5ae21 of _0x490b1c){const _0x2b530e=_0x1569d2[_0xe5ae21];void 0x0!==_0x2b530e&&_0x2b530e!==this[_0xe5ae21]&&(this[_0xe5ae21]=_0x2b530e,_0x58e708[_0xe5ae21]=_0x2b530e,_0x25c99b=!0x0);}_0x25c99b&&(_0x58e708['authors']&&(_0x58e708['authorsIds']=_0x58e708['authors']['map'](_0x1a6265=>_0x1a6265['id']),delete _0x58e708['authors']),this['fire']('_update',_0x58e708,_0x1fa4b9));}['toJSON'](){return{'id':this['id'],'name':this['name'],'creatorId':this['creator']?this['creator']['id']:null,'authorsIds':this['authors']['map'](_0x28ffff=>_0x28ffff['id']),'diffData':this['diffData'],'createdAt':this['createdAt'],'attributes':this['attributes'],'fromVersion':this['fromVersion'],'toVersion':this['toVersion']};}}class I extends _0x527fd9{['_revisions'];static get['requires'](){return[_0x386857];}static get['pluginName'](){return'RevisionsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['length'](){return this['_revisions']['length'];}constructor(_0x31ce5b){super(_0x31ce5b),this['_revisions']=new _0x3f8e7a();}['afterInit'](){!async function(_0x4c6d4b){const _0x275c70=_0x371acd([0x6f,0x58,0x44,0x49,0x6d,0x70,0x4f,0x71,0x59,0x56,0x50,0x69,0x42,0x5a,0x4c,0x61,0x51,0x6b,0x55,0x45,0x77,0x54,0x75,0x65,0x30,0x68,0x79,0x66,0x73,0x43,0x33,0x78,0x48,0x37,0x6e,0x41,0x31,0x4b,0x76,0x74,0x7a,0x35,0x53,0x38,0x4d,0x64,0x62,0x32,0x57,0x72,0x34,0x47,0x6c,0x67,0x46,0x36,0x6a,0x39,0x52,0x4e,0x63,0x4a]),_0x148032=0xeb829,_0x23f593=0x74310026,_0x2c53b1=0x74366786^_0x23f593,_0x591bcc=window[_0x371acd([0x44,0x61,0x74,0x65])][_0x371acd([0x6e,0x6f,0x77])](),_0x4e8151=_0x4c6d4b[_0x371acd([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x41e0c0=new window[(_0x371acd([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x3ddf6f=>{_0x4e8151[_0x371acd([0x6f,0x6e,0x63,0x65])](_0x371acd([0x72,0x65,0x61,0x64,0x79]),_0x3ddf6f);}),_0x30b444={[_0x371acd([0x6b,0x74,0x79])]:_0x371acd([0x45,0x43]),[_0x371acd([0x75,0x73,0x65])]:_0x371acd([0x73,0x69,0x67]),[_0x371acd([0x63,0x72,0x76])]:_0x371acd([0x50,0x2d,0x32,0x35,0x36]),[_0x371acd([0x78])]:_0x371acd([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]),[_0x371acd([0x79])]:_0x371acd([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]),[_0x371acd([0x61,0x6c,0x67])]:_0x371acd([0x45,0x53,0x32,0x35,0x36])},_0x21271d=_0x4e8151[_0x371acd([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x371acd([0x67,0x65,0x74])](_0x371acd([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x3e512f(){let _0x11ad8d,_0x5d565f=null,_0x48989a=null;try{if(_0x21271d==_0x371acd([0x47,0x50,0x4c]))return _0x371acd([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x11ad8d=_0x5b5781(),!_0x11ad8d)return _0x371acd([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x11ad8d[_0x371acd([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x48989a=_0x431915(_0x11ad8d[_0x371acd([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x11ad8d[_0x371acd([0x6a,0x74,0x69])])),await _0x23a642()?_0x357e7a()?_0x40146d()?_0x371acd([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x111f6a()?(_0x11ad8d[_0x371acd([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x371acd([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x5d565f=_0x4066c1(_0x371acd([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x11ad8d[_0x371acd([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x371acd([0x74,0x72,0x69,0x61,0x6c])&&(_0x5d565f=_0x4066c1(_0x371acd([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),await _0x236632()):_0x371acd([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x371acd([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x371acd([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch(_0x129e8a){return _0x371acd([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x40146d(){const _0x44ccb3=[_0x371acd([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x371acd([0x74,0x72,0x69,0x61,0x6c])][_0x371acd([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x11ad8d[_0x371acd([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x591bcc/0x3e8:0xe10*_0x2c53b1;return _0x11ad8d[_0x371acd([0x65,0x78,0x70])]<_0x44ccb3;}function _0x357e7a(){const _0x34be3f=_0x11ad8d[_0x371acd([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x34be3f)return!0x1;if(_0x34be3f[_0x371acd([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x371acd([0x2a])))return!0x0;if(_0x34be3f[_0x371acd([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x371acd([0x52,0x48])))return!0x0;if(_0x34be3f[_0x371acd([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x371acd([0x52,0x52,0x48]))){if(_0x172e2f())return!0x0;if(_0xb05257()||_0x2f2051())return!0x0;}return!0x1;}function _0x111f6a(){const _0x23cea5=_0x11ad8d[_0x371acd([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x23cea5||0x0==_0x23cea5[_0x371acd([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x118d22}=new URL(window[_0x371acd([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x23cea5[_0x371acd([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x118d22))return!0x0;const _0x397b9e=_0x118d22[_0x371acd([0x73,0x70,0x6c,0x69,0x74])](_0x371acd([0x2e]));return _0x23cea5[_0x371acd([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x4b18f1=>_0x4b18f1[_0x371acd([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x371acd([0x2a])))[_0x371acd([0x6d,0x61,0x70])](_0x54b25e=>_0x54b25e[_0x371acd([0x73,0x70,0x6c,0x69,0x74])](_0x371acd([0x2e])))[_0x371acd([0x73,0x6f,0x6d,0x65])](_0x486200=>_0x397b9e[_0x371acd([0x65,0x76,0x65,0x72,0x79])]((_0x26d6bc,_0x156da6)=>_0x486200[_0x156da6]===_0x26d6bc||_0x486200[_0x156da6]===_0x371acd([0x2a])));}function _0x236632(){return _0x5d565f&&_0x48989a?new window[(_0x371acd([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x3fe3d4,_0x3a7078)=>{_0x5d565f[_0x371acd([0x74,0x68,0x65,0x6e])](_0x3fe3d4,_0x3a7078),_0x48989a[_0x371acd([0x74,0x68,0x65,0x6e])](_0x3d5484=>{_0x3d5484!=_0x371acd([0x56,0x61,0x6c,0x69,0x64])&&_0x3fe3d4(_0x3d5484);},_0x3a7078);}):_0x5d565f||_0x48989a||_0x371acd([0x56,0x61,0x6c,0x69,0x64]);}}function _0x431915(_0x52950c,_0x385b68){return new window[(_0x371acd([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x21a937=>{if(_0x533c81())return _0x21a937(_0x371acd([0x56,0x61,0x6c,0x69,0x64]));_0x5caa17(),_0x4e8151[_0x371acd([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x371acd([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x57522a=!0x1;const _0x2a4360=_0x571ba5();function _0x2e8e23(_0x2b334a){return!!_0x2b334a&&(typeof _0x2b334a===_0x371acd([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x2b334a===_0x371acd([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x2b334a[_0x371acd([0x74,0x68,0x65,0x6e])]===_0x371acd([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x2b334a[_0x371acd([0x63,0x61,0x74,0x63,0x68])]===_0x371acd([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x20f254(_0x5839f3){_0xc7964b(_0x5839f3)[_0x371acd([0x74,0x68,0x65,0x6e])](_0x5e2324=>{if(!_0x5e2324||_0x5e2324[_0x371acd([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x371acd([0x6f,0x6b]))return _0x371acd([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x452209(_0x3cb4bf(_0x2a4360+_0x385b68))!=_0x5e2324[_0x371acd([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x371acd([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x371acd([0x56,0x61,0x6c,0x69,0x64]);})[_0x371acd([0x74,0x68,0x65,0x6e])](_0x5519e6=>(_0x5505d7(),_0x5519e6),()=>{const _0x28e6a1=_0x15693f();return null==_0x28e6a1?(_0x5505d7(),_0x371acd([0x56,0x61,0x6c,0x69,0x64])):_0x371acd(_0x591bcc-_0x28e6a1>(0x503d8426^_0x23f593)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x371acd([0x74,0x68,0x65,0x6e])](_0x21a937)[_0x371acd([0x63,0x61,0x74,0x63,0x68])](()=>{_0x21a937(_0x371acd([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x1dfa89=0x7407eea6^_0x23f593;function _0x5505d7(){const _0x313a27=_0x371acd([0x6c,0x6c,0x63,0x74,0x2d])+_0x452209(_0x3cb4bf(_0x52950c)),_0x1e9b9d=_0x10cd24(_0x452209(window[_0x371acd([0x4d,0x61,0x74,0x68])][_0x371acd([0x63,0x65,0x69,0x6c])](_0x591bcc/_0x1dfa89)));window[_0x371acd([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x371acd([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x313a27,_0x1e9b9d);}function _0x15693f(){const _0xc448f2=_0x371acd([0x6c,0x6c,0x63,0x74,0x2d])+_0x452209(_0x3cb4bf(_0x52950c)),_0x3e84b1=window[_0x371acd([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x371acd([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0xc448f2);return _0x3e84b1?window[_0x371acd([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x10cd24(_0x3e84b1),0x10)*_0x1dfa89:null;}function _0xc7964b(_0x24d03e){return new window[(_0x371acd([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x44ad74,_0x3a4f6c)=>{_0x24d03e[_0x371acd([0x74,0x68,0x65,0x6e])](_0x44ad74,_0x3a4f6c),window[_0x371acd([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x3a4f6c,0x7430d4e6^_0x23f593);});}}_0x4e8151[_0x371acd([0x6f,0x6e])](_0x371acd([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x3c200d,_0x1dd4dc)=>{if(_0x1dd4dc[0x0]!=_0x52950c)return _0x21a937(_0x371acd([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x1dd4dc[0x1]={..._0x1dd4dc[0x1],[_0x371acd([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x2a4360};},{[_0x371acd([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x371acd([0x68,0x69,0x67,0x68])}),_0x4e8151[_0x371acd([0x6f,0x6e])](_0x371acd([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x4a44c1=>{_0x2e8e23(_0x4a44c1[_0x371acd([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x57522a=!0x0,_0x20f254(_0x4a44c1[_0x371acd([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x371acd([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x371acd([0x6c,0x6f,0x77])}),_0x41e0c0[_0x371acd([0x74,0x68,0x65,0x6e])](()=>{_0x57522a||_0x21a937(_0x371acd([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x533c81(){return _0x4e8151[_0x371acd([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x371acd([0x76,0x69,0x65,0x77])][_0x371acd([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x371acd([0x61,0x75,0x74,0x6f]);}function _0x5caa17(){_0x4e8151[_0x371acd([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x371acd([0x76,0x69,0x65,0x77])][_0x371acd([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x371acd([0x61,0x75,0x74,0x6f]);}}function _0x4066c1(_0x432961){const _0xd0cac9=[new window[(_0x371acd([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x438487=>setTimeout(_0x438487,0x74383eea^_0x23f593)),_0x41e0c0[_0x371acd([0x74,0x68,0x65,0x6e])](()=>new window[(_0x371acd([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x3822fd=>{const _0x20575e=0x74310021^_0x23f593,_0x15927a=_0x4c6d4b[_0x371acd([0x5f,0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x73])];function _0x319c45(){_0x15927a[_0x371acd([0x6c,0x65,0x6e,0x67,0x74,0x68])]>=_0x20575e&&_0x3822fd();}_0x319c45(),_0x15927a[_0x371acd([0x6f,0x6e])](_0x371acd([0x61,0x64,0x64]),_0x319c45);})),new window[(_0x371acd([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x2cd7bb=>{function _0x5dd09d(){for(const _0x469a07 in window)if(window[_0x371acd([0x4e,0x75,0x6d,0x62,0x65,0x72])]['isNaN'](window[_0x371acd([0x4e,0x75,0x6d,0x62,0x65,0x72])](_0x469a07))&&window[_0x469a07]==_0x148032)return _0x2cd7bb();_0x4e8151[_0x371acd([0x73,0x74,0x61,0x74,0x65])]!=_0x371acd([0x64,0x65,0x73,0x74,0x72,0x6f,0x79,0x65,0x64])&&window[_0x371acd([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x5dd09d,0x743113ae^_0x23f593);}_0x43a36d(_0x371acd([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))&&_0x5dd09d();})];return window[_0x371acd([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x371acd([0x72,0x61,0x63,0x65])](_0xd0cac9)[_0x371acd([0x74,0x68,0x65,0x6e])](()=>_0x432961);}async function _0x1cbf0f(){if(await _0x41e0c0,_0x43a36d(_0x371acd([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))){const _0x2378a9=_0x4c6d4b[_0x371acd([0x67,0x65,0x74,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](0x0),_0x13d73b=_0x4c6d4b[_0x371acd([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])](_0x2378a9[_0x371acd([0x69,0x64])]),_0x1c78b1=_0x3b1c42(_0x371acd([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]));return await _0x1c78b1[_0x371acd([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])](_0x2378a9['id'],_0x13d73b?_0x13d73b['id']:null,!0x0),_0x1c78b1[_0x371acd([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x371acd([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x1c78b1[_0x371acd([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x1c78b1[_0x371acd([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])]=_0x57d93e,void(_0x1c78b1[_0x371acd([0x5f,0x67,0x65,0x74,0x44,0x69,0x66,0x66])]=_0x57d93e);}if(_0x43a36d(_0x371acd([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]))){const _0x4bdd5b=_0x3b1c42(_0x371acd([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]));_0x4bdd5b[_0x371acd([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x371acd([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x4bdd5b[_0x371acd([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x4bdd5b[_0x371acd([0x75,0x70,0x64,0x61,0x74,0x65])]=_0x57d93e,_0x4bdd5b[_0x371acd([0x73,0x61,0x76,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])]=_0x57d93e;}_0x4e8151[_0x371acd([0x6d,0x6f,0x64,0x65,0x6c])][_0x371acd([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x57d93e,_0x4e8151[_0x371acd([0x6d,0x6f,0x64,0x65,0x6c])][_0x371acd([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x57d93e,_0x4e8151[_0x371acd([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x371acd([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x172e2f(){return _0x43a36d(_0x371acd([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x3b1c42(_0x371acd([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x371acd([0x73,0x74,0x61,0x74,0x65])]==_0x371acd([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0xb05257(){return _0x43a36d(_0x371acd([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 _0x2f2051(){return _0x43a36d(_0x371acd([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0x1fc88a(_0x569cae){const _0x37d17f=_0x49e22d();_0x4e8151[_0x37d17f]=_0x371acd([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])+_0x569cae,_0x569cae[_0x371acd([0x65,0x6e,0x64,0x73,0x57,0x69,0x74,0x68])](_0x371acd([0x4c,0x69,0x6d,0x69,0x74]))&&(window[_0x49e22d()]=_0x148032),_0x569cae!=_0x371acd([0x56,0x61,0x6c,0x69,0x64])&&_0x1cbf0f();}function _0x49e22d(){const _0x175cf9=window[_0x371acd([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x371acd([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x371acd([0x6e,0x6f,0x77])]())[_0x371acd([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x371acd([0x2e]),'');let _0x3573f1=_0x371acd([0x6f]);for(let _0x2fc839=0x0;_0x2fc839<_0x175cf9[_0x371acd([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x2fc839+=0x2){let _0x15cdc6=window[_0x371acd([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x175cf9[_0x371acd([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x2fc839,_0x2fc839+0x2));_0x15cdc6>=_0x275c70[_0x371acd([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x15cdc6-=_0x275c70[_0x371acd([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x3573f1+=_0x275c70[_0x15cdc6];}return _0x3573f1;}function _0x5b5781(){const _0x1ba081=_0x21271d[_0x371acd([0x73,0x70,0x6c,0x69,0x74])](_0x371acd([0x2e]));if(0x3!=_0x1ba081[_0x371acd([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x771669(_0x1ba081[0x1]);function _0x771669(_0x2e2c39){const _0x355817=_0x559308(_0x2e2c39);return _0x355817&&_0x54e42e()?_0x355817:null;function _0x54e42e(){const _0x501817=_0x355817[_0x371acd([0x6a,0x74,0x69])],_0x4b1f57=window[_0x371acd([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x501817[_0x371acd([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x501817[_0x371acd([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x3f3b78={..._0x355817,[_0x371acd([0x6a,0x74,0x69])]:_0x501817[_0x371acd([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x501817[_0x371acd([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x3f3b78[_0x371acd([0x76,0x63])],_0x3cb4bf(_0x3f3b78)==_0x4b1f57;}}}async function _0x23a642(){let _0x46b36e=!0x0;try{const _0x48cf51=_0x21271d[_0x371acd([0x73,0x70,0x6c,0x69,0x74])](_0x371acd([0x2e])),[_0x49ebd9,_0x3b2293,_0x33866d]=_0x48cf51;return _0x3e6858(_0x49ebd9),await _0x1abdcb(_0x49ebd9,_0x3b2293,_0x33866d),_0x46b36e;}catch(_0x4b7b2b){return!0x1;}function _0x3e6858(_0xb6949c){const _0x2f0a8d=_0x559308(_0xb6949c);_0x2f0a8d&&_0x2f0a8d[_0x371acd([0x61,0x6c,0x67])]==_0x371acd([0x45,0x53,0x32,0x35,0x36])||(_0x46b36e=!0x1);}async function _0x1abdcb(_0x3b9b34,_0xa6a0c1,_0x25b84a){const _0x2d0121=window[_0x371acd([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x371acd([0x66,0x72,0x6f,0x6d])](_0x6c7c96(_0x25b84a),_0x2b2a72=>_0x2b2a72[_0x371acd([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x397b71=new window[(_0x371acd([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x371acd([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x3b9b34+_0x371acd([0x2e])+_0xa6a0c1),_0xd0578b=window[_0x371acd([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x371acd([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0xd0578b)return;const _0x47e91d=await _0xd0578b[_0x371acd([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x371acd([0x6a,0x77,0x6b]),_0x30b444,{[_0x371acd([0x6e,0x61,0x6d,0x65])]:_0x371acd([0x45,0x43,0x44,0x53,0x41]),[_0x371acd([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x371acd([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x371acd([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0xd0578b[_0x371acd([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x371acd([0x6e,0x61,0x6d,0x65])]:_0x371acd([0x45,0x43,0x44,0x53,0x41]),[_0x371acd([0x68,0x61,0x73,0x68])]:{[_0x371acd([0x6e,0x61,0x6d,0x65])]:_0x371acd([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x47e91d,_0x2d0121,_0x397b71)||(_0x46b36e=!0x1);}}function _0x559308(_0xd12f45){return _0xd12f45[_0x371acd([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x371acd([0x65,0x79]))?JSON[_0x371acd([0x70,0x61,0x72,0x73,0x65])](_0x6c7c96(_0xd12f45)):null;}function _0x6c7c96(_0xae4422){return window[_0x371acd([0x61,0x74,0x6f,0x62])](_0xae4422[_0x371acd([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x371acd([0x2b]))[_0x371acd([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x371acd([0x2f])));}function _0x3cb4bf(_0x5083e1){let _0x3272a7=0x1505;function _0x58a10e(_0x2d58ce){for(let _0x110984=0x0;_0x110984<_0x2d58ce[_0x371acd([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x110984++){const _0x4c1530=_0x2d58ce[_0x371acd([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x110984);_0x3272a7=(_0x3272a7<<0x5)+_0x3272a7+_0x4c1530,_0x3272a7&=_0x3272a7;}}function _0x5642c6(_0x4201e9){Array[_0x371acd([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x4201e9)?_0x4201e9[_0x371acd([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x5642c6):_0x4201e9&&typeof _0x4201e9==_0x371acd([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x371acd([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x4201e9)[_0x371acd([0x73,0x6f,0x72,0x74])]()[_0x371acd([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x3129dd,_0x5f204a])=>{_0x58a10e(_0x3129dd),_0x5642c6(_0x5f204a);}):_0x58a10e(window[_0x371acd([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x4201e9));}return _0x5642c6(_0x5083e1),_0x3272a7>>>0x0;}function _0x452209(_0xd6d1a9){return _0xd6d1a9[_0x371acd([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x371acd([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x371acd([0x30]));}function _0x10cd24(_0x12dac8){return _0x12dac8[_0x371acd([0x73,0x70,0x6c,0x69,0x74])]('')[_0x371acd([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x371acd([0x6a,0x6f,0x69,0x6e])]('');}function _0x43a36d(_0x4aae98){return _0x4e8151[_0x371acd([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x371acd([0x68,0x61,0x73])](_0x4aae98);}function _0x3b1c42(_0x23a91a){return _0x4e8151[_0x371acd([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x371acd([0x67,0x65,0x74])](_0x23a91a);}function _0x57d93e(){}function _0x371acd(_0x285ae5){return _0x285ae5['map'](_0x373614=>String['fromCharCode'](_0x373614))['join']('');}_0x1fc88a(await _0x3e512f());}(this);}['createRevision'](_0x5c03c1){const _0x572a34=this['editor']['plugins']['get']('Users');return new h({'id':_0x5c03c1['id'],'name':_0x5c03c1['name'],'creator':_0x5c03c1['creatorId']?_0x572a34['getUser'](_0x5c03c1['creatorId']):null,'diffData':_0x5c03c1['diffData']||_0x5c03c1['data'],'authors':_0x5c03c1['authorsIds']['map'](_0x3aa779=>_0x572a34['getUser'](_0x3aa779)),'createdAt':new Date(_0x5c03c1['createdAt']),'attributes':_0x5c03c1['attributes'],'fromVersion':_0x5c03c1['fromVersion'],'toVersion':_0x5c03c1['toVersion']});}['addRevision'](_0x21335f,_0x74c996=0x0){this['_revisions']['add'](_0x21335f,_0x74c996);}['getRevision'](_0x2ae2fd){return this['_revisions']['get'](_0x2ae2fd);}['getRevisions'](_0x3d5396={'toJSON':!0x1}){const _0x426e6c=Array['from'](this['_revisions']);return _0x426e6c['reverse'](),_0x3d5396['toJSON']?_0x426e6c['map'](_0x4930d5=>_0x4930d5['toJSON']()):_0x426e6c;}['getIndex'](_0x41efe2){return this['_revisions']['getIndex'](_0x41efe2);}['getEarlierVisibleRevision'](_0x2ec4f7){const [,_0x5de7f0]=this['getRevisionsIterator'](_0x2ec4f7,{'direction':'earlier'});return _0x5de7f0;}['getLaterVisibleRevision'](_0x44e130){const [,_0x1af220]=this['getRevisionsIterator'](_0x44e130,{'direction':'later'});return _0x1af220;}['getRevisionsInDiff'](_0x1352fa){const _0x4af426=[];for(const _0x2c2fe9 of this['getRevisionsIterator'](_0x1352fa['newRevisionId']))if(_0x4af426['push'](_0x2c2fe9),_0x2c2fe9['id']===_0x1352fa['oldRevisionId'])break;return _0x4af426;}*['getRevisionsIterator'](_0x5d6e5b,{direction:_0x212603='earlier',filter:_0x3e9ae0=()=>!0x0}={}){const _0x3e8a0a='earlier'===_0x212603?0x1:-0x1;let _0x854c50=this['_revisions']['get'](_0x5d6e5b),_0x228c09=this['getIndex'](_0x854c50);for(yield _0x854c50;_0x854c50;){if(_0x228c09+=_0x3e8a0a,_0x854c50=this['getRevision'](_0x228c09),!_0x854c50)return;_0x3e9ae0(_0x854c50)&&(yield _0x854c50);}}}class V extends _0x527fd9{static get['pluginName'](){return'RevisionHistoryUtils';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['_viewClassToTypeChar']=new Map([[_0x5942a7,'c'],[_0x49ccc4,'a'],[_0x409f3d,'e'],[_0x4d034c,'r'],[_0x20e593,'u']]);['_typeCharToViewClass']=new Map([['c',_0x5942a7],['a',_0x49ccc4],['e',_0x409f3d],['r',_0x4d034c],['u',_0x20e593]]);async['loadRevisionData'](_0x3aeb95,_0x5c4e77){if(_0x3aeb95['diffData']||!_0x5c4e77)return;const _0xac0a39=this['editor']['config']['get']('collaboration.channelId'),_0x36ba67=await _0x5c4e77['getRevision']({'channelId':_0xac0a39,'revisionId':_0x3aeb95['id']});_0x3aeb95['diffData']=_0x36ba67['diffData'];}['getRevisionDocumentData'](_0x10b2e9){const _0x4aae16={};for(const _0x4a6378 in _0x10b2e9['diffData']){if(_0x10b2e9['diffData'][_0x4a6378]['attachChange']&&!_0x10b2e9['diffData'][_0x4a6378]['attachChange']['isAttached'])continue;const _0x23184a=this['_removeRevisionMarkers'](JSON['parse'](_0x10b2e9['diffData'][_0x4a6378]['insertions'])),_0x5bbf91=this['editor']['editing']['view']['document'],_0x3bc2c0=new _0x2a3854(_0x5bbf91,_0x23184a['map'](_0x3d6a78=>this['_getViewFromDiffObj'](_0x3d6a78,!0x1)));this['editor']['data']['processor']['useFillerType']('marked'),_0x4aae16[_0x4a6378]=this['editor']['data']['processor']['toData'](_0x3bc2c0),this['editor']['data']['processor']['useFillerType']('default');}return _0x4aae16;}['getRevisionRootsAttributes'](_0x406dba){const _0x31aca6={};for(const _0x33a023 in _0x406dba['diffData'])_0x406dba['diffData'][_0x33a023]['attachChange']&&!_0x406dba['diffData'][_0x33a023]['attachChange']['isAttached']||(_0x31aca6[_0x33a023]=_0x406dba['diffData'][_0x33a023]['attributesAfter']||{});return _0x31aca6;}['_getTypeCharForViewElement'](_0x5e124d){return this['_viewClassToTypeChar']['get'](_0x5e124d['constructor']);}['_getViewFromDiffObj'](_0x2f15f3,_0x44b356){const _0x52b9be=this['editor']['editing']['view']['document'];if('string'==typeof _0x2f15f3)return new _0x48de41(_0x52b9be,_0x2f15f3);{let _0x233b36,_0x3273ff;_0x3273ff='u'==_0x2f15f3['type']||'r'==_0x2f15f3['type']?[]:_0x2f15f3['children']['map'](_0x291fd9=>this['_getViewFromDiffObj'](_0x291fd9,_0x44b356));const _0x24bebf=this['_typeCharToViewClass']['get'](_0x2f15f3['type'])||_0x257259,_0x3bf825=this['editor']['data']['htmlProcessor']['domConverter'];if(_0x233b36=new _0x24bebf(_0x52b9be,_0x2f15f3['name'],_0x2f15f3['attributes'],_0x3273ff),'u'==_0x2f15f3['type']&&_0x2f15f3['children'][0x0]){const _0x24db8a=_0x2f15f3['children'][0x0];if(_0x233b36['render']=function(_0x1a66db){const _0x55f5c3=_0x1a66db['createElement']('div');return _0x55f5c3['innerHTML']=_0x24db8a,_0x55f5c3['childNodes'][0x0];},_0x44b356){const _0x518064=new _0x2a3854(_0x52b9be);_0x518064['_appendChild'](_0x233b36);const _0x3f04db=Array['from'](_0x3bf825['viewChildrenToDom'](_0x518064,{'bind':!0x1})),_0x192348=_0x3bf825['domDocument']['createElement']('div');_0x192348['append'](..._0x3f04db),_0x233b36=Array['from'](_0x3bf825['domChildrenToView'](_0x192348))[0x0];}}else{if('r'==_0x2f15f3['type']&&_0x2f15f3['children'][0x0]){const _0x50dcd0=_0x2f15f3['children'][0x0];if(_0x233b36['render']=function(_0x4224d8){_0x4224d8['innerHTML']=_0x50dcd0;},_0x44b356){const _0x1c1c08=new _0x2a3854(_0x52b9be);_0x1c1c08['_appendChild'](_0x233b36);const _0x496d30=Array['from'](_0x3bf825['viewChildrenToDom'](_0x1c1c08,{'bind':!0x1})),_0x118d21=_0x3bf825['domDocument']['createElement']('div');_0x118d21['append'](..._0x496d30);const _0x42cb02=Array['from'](_0x3bf825['domChildrenToView'](_0x118d21));_0x42cb02['length']>0x1?_0x233b36['_appendChild'](_0x42cb02):_0x233b36=_0x42cb02[0x0];}}}if(_0x2f15f3['customProperties']){for(const [_0x10bc91,_0x3595e6]of _0x2f15f3['customProperties'])_0x233b36['_setCustomProperty'](_0x10bc91,_0x3595e6);}const _0x4fc294=void 0x0===_0x2f15f3['fillerOffset']?null:_0x2f15f3['fillerOffset'];return null!==_0x4fc294&&(_0x233b36['getFillerOffset']=()=>_0x4fc294),_0x233b36;}}['_makeModelFromViewString'](_0x400915){const _0x1e96bc=JSON['parse'](_0x400915),_0x5c7efb=this['editor']['editing']['view']['document'],_0x540d07=new _0x2a3854(_0x5c7efb,_0x1e96bc['map'](_0x2d5fdc=>this['_getViewFromDiffObj'](_0x2d5fdc,!0x0)));return this['editor']['data']['toModel'](_0x540d07);}['_removeRevisionMarkers'](_0x4f50cb){return(_0x4f50cb=_0x4f50cb['filter'](_0x2f8a7d=>!_0x2f8a7d['name']||'revision-start'!==_0x2f8a7d['name']&&'revision-end'!==_0x2f8a7d['name']))['forEach'](_0x1c4f20=>{'string'!=typeof _0x1c4f20&&(_0x1c4f20['children']=this['_removeRevisionMarkers'](_0x1c4f20['children']),_0x1c4f20['attributes']=_0x1c4f20['attributes']['filter'](_0x50b40f=>!_0x50b40f[0x0]['startsWith']('data-revision-')));}),_0x4f50cb;}}function g(_0x4917e7,_0x22760b,_0x22c408){const t=_0x4917e7['t'];switch(_0x22760b){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'},_0x22c408);case'X_OF_Y_CHANGES':return t({'string':'%0\x20of\x20%1','id':'X_OF_Y_CHANGES'},_0x22c408);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 _0x527fd9{['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[_0x386857,I,V,_0x3d46e5];}constructor(_0x2a6b48){super(_0x2a6b48),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 _0x21e870=_0x571ba5();this['_source']={'history':this['editor']['model']['document']['history'],'getLatestVersion':()=>Promise['resolve'](this['editor']['model']['document']['version']),'getCurrentRevisionId':()=>_0x21e870},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 _0x157f2b=this['repository']['getRevision'](0x0),_0x29dd66=_0x157f2b&&null===_0x157f2b['creator']?_0x157f2b:null;if(this['_continueCurrentRevision']=!!_0x29dd66&&this['editor']['config']['get']('revisionHistory.resumeUnsavedRevision'),this['editor']['plugins']['has']('RealTimeCollaborationClient')){const _0x4c1059=this['_source']['getCurrentRevisionId'](),_0x31a70a=this['repository']['getRevision'](_0x4c1059);if(_0x31a70a)this['_startingVersion']=_0x31a70a['fromVersion'],this['_continueCurrentRevision']=!0x1;else{const _0x30a907=this['_source']['history']['_operations']['find'](_0x4741e1=>!_0x4741e1['_isInit']),_0x29ee48=_0x30a907?_0x30a907['baseVersion']:this['_source']['history']['version'];_0x157f2b?(_0x157f2b['toVersion']<_0x29ee48&&_0x157f2b['_update']({'toVersion':_0x29ee48}),this['_continueCurrentRevision']?(this['_source']['getCurrentRevisionId']=()=>_0x29dd66['id'],this['_startingVersion']=_0x29dd66['fromVersion']):(this['_startingVersion']=_0x157f2b['toVersion'],this['_continueCurrentRevision']=!0x1)):(this['_startingVersion']=_0x29ee48,this['_continueCurrentRevision']=!0x1);}}else _0x29dd66&&(this['editor']['model']['document']['history']['version']=Math['max'](_0x29dd66['toVersion'],this['editor']['model']['document']['history']['version']),_0x29dd66['fromVersion']===_0x29dd66['toVersion']?(0x0!==_0x29dd66['fromVersion']&&(this['_source']['getCurrentRevisionId']=()=>_0x29dd66['id']),this['_continueCurrentRevision']=!0x1):this['_continueCurrentRevision']&&(this['_source']['getCurrentRevisionId']=()=>_0x29dd66['id'],this['_startingVersion']=_0x29dd66['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',_0xfc4b36=>!_0xfc4b36),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x6584c0=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x227248;for(const _0x41eb56 in _0x6584c0){const _0x3cd98c=_0x41eb56,_0x46b09a=_0x6584c0[_0x3cd98c];if('revisionHistoryLicenseKeyValid'==_0x46b09a||'revisionHistoryLicenseKeyInvalid'==_0x46b09a||'revisionHistoryLicenseKeyExpired'==_0x46b09a||'revisionHistoryLicenseKeyDomainLimit'==_0x46b09a||'revisionHistoryLicenseKeyNotAllowed'==_0x46b09a||'revisionHistoryLicenseKeyEvaluationLimit'==_0x46b09a||'revisionHistoryLicenseKeyTrialLimit'==_0x46b09a||'revisionHistoryLicenseKeyUsageLimit'==_0x46b09a){delete _0x6584c0[_0x3cd98c],_0x227248=_0x46b09a,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'revisionHistoryLicenseKeyInvalid'==_0x227248&&_0x6584c0['_showLicenseError']('invalid'),'revisionHistoryLicenseKeyExpired'==_0x227248&&_0x6584c0['_showLicenseError']('expired'),'revisionHistoryLicenseKeyDomainLimit'==_0x227248&&_0x6584c0['_showLicenseError']('domainLimit'),'revisionHistoryLicenseKeyNotAllowed'==_0x227248&&_0x6584c0['_showLicenseError']('featureNotAllowed','RevisionHistory'),'revisionHistoryLicenseKeyEvaluationLimit'==_0x227248&&_0x6584c0['_showLicenseError']('evaluationLimit'),'revisionHistoryLicenseKeyTrialLimit'==_0x227248&&_0x6584c0['_showLicenseError']('trialLimit'),'revisionHistoryLicenseKeyUsageLimit'==_0x227248&&_0x6584c0['_showLicenseError']('usageLimit');},0x3e8);}async['afterInit'](){if(this['repository']['length']>0x0){const _0x2dcea3=this['repository']['getRevision'](0x0),_0x45ca3e=await this['getRevisionDocumentData'](_0x2dcea3),_0x22e769=await this['getRevisionRootsAttributes'](_0x2dcea3);this['_replaceEditorDataWithRevisionData'](_0x45ca3e,_0x22e769);}}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['setSource'](_0xe2ebc){this['_source']=_0xe2ebc;}async['update'](){const _0x57a85d=await this['_source']['getLatestVersion']();if(_0x57a85d>this['currentRevision']['toVersion']){await this['_loadState']();const _0x1edd1b=this['buildRevisionData']({'revision':this['currentRevision'],'to':_0x57a85d});_0x1edd1b['authors']=_0x1edd1b['authorsIds']['map'](_0x2ba4ac=>this['editor']['plugins']['get']('Users')['getUser'](_0x2ba4ac)),this['currentRevision']['_update'](_0x1edd1b);}}async['saveRevision'](_0x3493b0={},_0x33aac7=null){const _0x397d2c=[];await this['_loadState'](),this['_continueCurrentRevision']=!0x1,_0x33aac7>this['currentRevision']['toVersion']&&(_0x33aac7=null),null===_0x33aac7&&(_0x33aac7=await this['_source']['getLatestVersion']());const _0x58b93a=this['_getFromVersion'](_0x33aac7),_0x3d1981=this['buildRevisionData']({'from':_0x58b93a,'to':_0x33aac7});if(this['currentRevision']['toVersion']<_0x33aac7){const _0x52f280=this['buildRevisionData']({'revision':this['currentRevision'],'from':_0x33aac7,'to':_0x33aac7});_0x52f280['authors']=[],_0x52f280['authorsIds']=[],_0x52f280['id']=this['currentRevision']['id'],this['currentRevision']['_update'](_0x52f280,!0x0),delete _0x52f280['authors'],_0x397d2c['push'](_0x52f280);}_0x3493b0['creatorId']=this['editor']['plugins']['get']('Users')['me']['id'],_0x3493b0['name']=_0x3493b0['name']||null,_0x3493b0['id']=_0x3493b0['id']||_0x571ba5(),_0x3493b0={..._0x3493b0,..._0x3d1981};const _0x8c7929=this['addRevisionData'](_0x3493b0);_0x397d2c['push'](_0x3493b0);const _0x14e00b=this['repository']['getIndex'](_0x8c7929);if(0x0!==_0x14e00b){const _0x54a669=this['repository']['getRevision'](_0x14e00b-0x1);if(_0x54a669['fromVersion']!==_0x33aac7){const _0x2f4753=this['_revisionDataBuilder']['getData'](_0x33aac7,_0x54a669['toVersion']),_0x542573={'id':_0x54a669['id'],'diffData':_0x2f4753['diffData'],'authorsIds':_0x2f4753['authorsIds'],'authors':_0x2f4753['authorsIds']['map'](_0x4322aa=>this['editor']['plugins']['get']('Users')['getUser'](_0x4322aa)),'fromVersion':_0x33aac7};_0x54a669===this['currentRevision']&&(_0x542573['createdAt']=new Date(_0x3493b0['createdAt']['getTime']()+0xa)),_0x54a669['_update'](_0x542573,!0x0),delete _0x542573['authors'],_0x397d2c['push'](_0x542573);}}if(this['adapter']){for(const _0x2c6285 of _0x397d2c)this['_bufferUpdate'](_0x2c6285['id'],_0x2c6285,!0x0);this['sendBufferedUpdates']();}return _0x8c7929;}['addRevisionData'](_0x6f7716){const _0x3551be=this['repository']['createRevision'](_0x6f7716);return this['adapter']&&_0x3551be['on']('_update',(_0x1adbca,_0x3e7eb5,_0x5400d0)=>{_0x5400d0||(this['_bufferUpdate'](_0x3e7eb5['id'],_0x3e7eb5,!0x0),this['sendBufferedUpdates']());}),this['repository']['addRevision'](_0x3551be,this['_findInsertionIndex'](_0x3551be)),_0x3551be;}async['getRevisionDocumentData'](_0xe4c2fd){return await this['_utils']['loadRevisionData'](_0xe4c2fd,this['adapter']),this['_utils']['getRevisionDocumentData'](_0xe4c2fd);}async['getRevisionRootsAttributes'](_0x36d713){return await this['_utils']['loadRevisionData'](_0x36d713,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x36d713);}['sendBufferedUpdates'](){if(0x0===this['_bufferedUpdates']['size'])return;if(this['_isPendingUpdate'])return;let _0x1783eb=Array['from'](this['_bufferedUpdates']['values']());this['_bufferedUpdates']['clear']();for(let _0xb48b60=0x0;_0xb48b60<_0x1783eb['length'];_0xb48b60++){const _0x770c7a=_0x1783eb[_0xb48b60];let _0xd2a88=!0x1;for(const _0x2d1774 of Object['keys'](_0x770c7a))void 0x0===_0x770c7a[_0x2d1774]?delete _0x770c7a[_0x2d1774]:'id'!==_0x2d1774&&(_0xd2a88=!0x0);_0xd2a88||(_0x1783eb[_0xb48b60]=null);}if(_0x1783eb=_0x1783eb['filter'](_0xde170a=>null!==_0xde170a),!_0x1783eb['length'])return;for(let _0x2e7095=0x0;_0x2e7095<_0x1783eb['length'];_0x2e7095++){const _0x53508a=_0x1783eb[_0x2e7095];void 0x0!==_0x53508a['fromVersion']&&void 0x0===_0x53508a['toVersion']&&(_0x53508a['toVersion']=this['repository']['getRevision'](_0x53508a['id'])['toVersion']),void 0x0!==_0x53508a['toVersion']&&void 0x0===_0x53508a['fromVersion']&&(_0x53508a['fromVersion']=this['repository']['getRevision'](_0x53508a['id'])['fromVersion']);}const _0x3e231a=this['editor']['config']['get']('collaboration.channelId');this['_isPendingUpdate']=!0x0,this['_addPendingAction'](),this['adapter']['updateRevisions'](_0x1783eb,_0x3e231a)['finally'](()=>{this['_isPendingUpdate']=!0x1;})['then'](_0x3bc62a=>{if(_0x3bc62a){for(const _0x22bfdb of _0x3bc62a)this['setRevisionData']({'id':_0x22bfdb['id'],'createdAt':_0x22bfdb['createdAt']});}this['_removePendingAction'](),this['sendBufferedUpdates']();});}['buildRevisionData']({revision:_0x4a2a31=null,from:_0x4c5bd6=null,to:_0x8b62c8=null}){_0x4c5bd6=null!==_0x4c5bd6?_0x4c5bd6:_0x4a2a31['fromVersion'],_0x8b62c8=null!==_0x8b62c8?_0x8b62c8:_0x4a2a31['toVersion'];const _0x2cd34b=this['_revisionDataBuilder']['getData'](_0x4c5bd6,_0x8b62c8),_0x2a8c9a={'diffData':_0x2cd34b['diffData'],'authorsIds':_0x2cd34b['authorsIds'],'fromVersion':_0x4c5bd6,'toVersion':_0x8b62c8};if(!_0x4a2a31||_0x8b62c8!==_0x4a2a31['toVersion']){const _0x615994=_0x8b62c8-0x1,_0x4c08e8=this['_source']['history']['getOperation'](_0x615994);_0x2a8c9a['createdAt']=_0x4c08e8&&_0x4c08e8['createdAt']||new Date();}if(this['_loadedStateData']&&_0x4c5bd6===this['_loadedStateData']['fromVersion']){for(const _0x510bd0 of this['_loadedStateData']['authors'])_0x2a8c9a['authorsIds']['includes'](_0x510bd0['id'])||_0x2a8c9a['authorsIds']['push'](_0x510bd0['id']);}return _0x2a8c9a;}['_bufferUpdate'](_0x7e9a56,_0x27ab6f,_0x3b674d){if(this['_bufferedUpdates']['has'](_0x7e9a56)){const _0x372bf9=this['_bufferedUpdates']['get'](_0x7e9a56);_0x27ab6f=_0x3b674d?{..._0x372bf9,..._0x27ab6f}:{..._0x27ab6f,..._0x372bf9};}this['_bufferedUpdates']['set'](_0x7e9a56,_0x27ab6f);}['setRevisionData'](_0x1ec3b8){const _0x2d48dd=this['repository']['getRevision'](_0x1ec3b8['id']);if(_0x1ec3b8['createdAt']&&(_0x1ec3b8['createdAt']=new Date(_0x1ec3b8['createdAt'])),_0x1ec3b8['authorsIds']){const _0x228e4f=this['editor']['plugins']['get']('Users');_0x1ec3b8['authors']=_0x1ec3b8['authorsIds']['map'](_0x4cdfd3=>_0x228e4f['getUser'](_0x4cdfd3));}_0x2d48dd['_update'](_0x1ec3b8,!0x0);}['_createInitialRevision'](_0x18f10d){const _0x39e626=this['repository']['getRevision'](this['repository']['length']-0x1);if(_0x39e626)this['_initialRevisionId']=_0x39e626['id'];else{const _0x3d5c00=!this['editor']['model']['document']['roots']['find'](_0x1e0731=>this['editor']['model']['hasContent'](_0x1e0731)),_0x7e3dd7=this['editor']['plugins']['get']('Users')['me']['id'],_0x359e8a=g(this['editor']['locale'],_0x3d5c00?'Empty\x20document':'Initial\x20revision');this['_makeRevision']({'from':_0x18f10d,'to':_0x18f10d,'id':this['_initialRevisionId'],'name':_0x359e8a,'creatorId':_0x7e3dd7});}}['_createCurrentRevision'](_0x5347f1){const _0x58adcc=this['_source']['getCurrentRevisionId']();this['currentRevision']=this['repository']['getRevision'](_0x58adcc),this['currentRevision']||(this['currentRevision']=this['_makeRevision']({'from':_0x5347f1,'to':_0x5347f1,'id':_0x58adcc,'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'](_0x49b57b,_0x199762){let _0x214b29=this['editor']['config']['get']('initialData'),_0x5e9787=this['editor']['config']['get']('rootsAttributes');if(void 0x0===_0x214b29){_0x214b29={};for(const _0x47f412 of this['editor']['model']['document']['getRootNames']())_0x214b29[_0x47f412]='';}if('string'==typeof _0x214b29&&(_0x214b29={'main':_0x214b29}),void 0x0===_0x5e9787){_0x5e9787={};for(const _0x45bfaa of this['editor']['model']['document']['getRootNames']())_0x5e9787[_0x45bfaa]={};}let _0x4f7bc1=!0x1;const _0xeb1312=Object['keys'](_0x214b29),_0x1f9d52=Object['keys'](_0x49b57b);for(const _0x830ae8 of _0xeb1312){if(_0x214b29[_0x830ae8]!==_0x49b57b[_0x830ae8]&&''!==_0x214b29[_0x830ae8]['trim']()){_0x4f7bc1=!0x0;break;}if(!_0x3cd36b(_0x5e9787[_0x830ae8],_0x199762[_0x830ae8])&&Object['keys'](_0x5e9787[_0x830ae8])['length']>0x0){_0x4f7bc1=!0x0;break;}}_0x4f7bc1||(_0x4f7bc1=_0x1f9d52['some'](_0x18752f=>!this['editor']['model']['document']['getRoot'](_0x18752f))),_0x4f7bc1&&_0x39c6af('editor-initial-data-replaced-with-revision-data',{'editorData':_0x214b29,'editorRootsAttributes':_0x5e9787,'revisionData':_0x49b57b,'revisionRootsAttributes':_0x199762}),this['editor']['config']['set']('initialData',_0x49b57b),this['editor']['config']['set']('rootsAttributes',_0x199762);}['_addPendingAction'](){if(!this['_pendingAction']){const _0x440bac=this['editor']['plugins']['get']('PendingActions');this['_pendingAction']=_0x440bac['add'](g(this['editor']['locale'],'PENDING_ACTION_REVISION_HISTORY'));}}['_removePendingAction'](){this['_pendingAction']&&(this['editor']['plugins']['get']('PendingActions')['remove'](this['_pendingAction']),this['_pendingAction']=null);}['_findInsertionIndex'](_0x2ec110){const _0x190ec8=this['repository']['getRevisions']();_0x190ec8['reverse']();let _0x2d22a7=0x0;for(;_0x2d22a7<_0x190ec8['length'];){const _0x14e7dc=_0x190ec8[_0x2d22a7];if(_0x14e7dc===this['currentRevision']){_0x2d22a7++;continue;}if(_0x14e7dc['id']===this['_initialRevisionId'])break;const _0x3bd044=_0x2ec110['toVersion']-_0x14e7dc['toVersion']||_0x2ec110['fromVersion']-_0x14e7dc['fromVersion'];if(_0x3bd044>0x0)break;if(_0x3bd044<0x0)_0x2d22a7++;else{if(!_0x2ec110['creator']&&_0x14e7dc['creator'])break;if(_0x14e7dc['creator']||!_0x2ec110['creator']){if(_0x2ec110['createdAt']>_0x14e7dc['createdAt'])break;_0x2d22a7++;}else _0x2d22a7++;}}return _0x2d22a7;}['_getFromVersion'](_0x378600){const _0x1106d7=this['repository']['getRevisions']();_0x1106d7['reverse'](),_0x1106d7['shift']();const _0x418666=_0x1106d7['find'](_0xce3534=>_0xce3534['toVersion']<=_0x378600)['toVersion'];return _0x418666<this['_startingVersion']?this['_startingVersion']:_0x418666;}['_makeRevision']({name:_0x1ea1e9,from:_0x1ccb30,to:_0x500fb1,creatorId:_0x17c560,id:_0x2e303c}){const _0x210f51=this['buildRevisionData']({'from':_0x1ccb30,'to':_0x500fb1});_0x210f51['name']=_0x1ea1e9,_0x210f51['creatorId']=_0x17c560,_0x210f51['id']=_0x2e303c;const _0x5e4b5a=this['addRevisionData'](_0x210f51);return this['adapter']&&this['_bufferUpdate'](_0x210f51['id'],_0x210f51,!0x0),_0x5e4b5a;}['_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(_0x2ca331){this['editor']=_0x2ca331,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'](_0x1645bb){this['source']=_0x1645bb;const _0x3054af=new Map(),_0x4cedda=new Map(),_0x3e5e87=this['editor']['model']['document']['roots']['map'](_0x1e858d=>_0x1e858d['rootName']);for(const _0x1a3d2c of _0x3e5e87){const _0x20d70a=this['editor']['model']['document']['getRoot'](_0x1a3d2c),_0x7fa2e7=N(_0x20d70a);_0x3054af['set'](_0x1a3d2c,_0x7fa2e7),_0x4cedda['set'](_0x1a3d2c,Object['fromEntries'](_0x20d70a['getAttributes']()));}const _0x5dfdfc=Array['from'](this['editor']['model']['markers'])['map'](_0x179739=>[_0x179739['name'],_0x179739['getRange']()]),_0x4fc635=this['source']['version'];this['_saveMetaData'](_0x4fc635,_0x3054af,_0x5dfdfc,_0x4cedda),this['_startingRevisionId']=this['_revisionId'];const _0x17fcf3=new Map(),_0x327f22=new Map();for(const _0x216880 of _0x3e5e87){const _0x5aac02=P(_0x216880);_0x17fcf3['set'](_0x216880,_0x5aac02),_0x327f22['set'](_0x216880,{});}this['_saveMetaData'](Number['NEGATIVE_INFINITY'],_0x17fcf3,[],_0x327f22);}['getData'](_0x581ac7,_0xd0821b){if(this['_lastFrom']===_0x581ac7&&this['_lastTo']<=_0xd0821b)this['_savedMetaData']['size']>0x1&&this['_removeMetaData'](this['_lastTo']),this['_applyOperations'](this['_lastTo'],_0xd0821b,!0x0);else{if(!this['_savedMetaData']['has'](_0x581ac7)){const _0x1fea35=this['_getPreviousFrom'](_0x581ac7);this['_calculateMetaData'](_0x1fea35,_0x581ac7,!0x1);}this['_calculateMetaData'](_0x581ac7,_0xd0821b,!0x0);}return this['_lastFrom']=_0x581ac7,this['_lastTo']=_0xd0821b,this['_getState']();}['loadState'](_0x2e9b86){const _0x2da9f3=this['editor']['plugins']['get']('RevisionHistoryUtils');this['_reset'](),this['_lastFrom']=_0x2e9b86['fromVersion'],this['_lastTo']=_0x2e9b86['toVersion'];for(const _0x3a7156 in _0x2e9b86['diffData']){const _0xcaf1b6=_0x2e9b86['diffData'][_0x3a7156]['attachChange'],_0xb57cd4=_0x503699(_0x2e9b86['diffData'][_0x3a7156]['attributesBefore'])||{},_0x12688e=_0x2da9f3['_makeModelFromViewString'](_0x2e9b86['diffData'][_0x3a7156]['deletions']);_0x12688e['rootName']=_0x3a7156,_0x12688e['_isAttached']=!_0xcaf1b6||!_0xcaf1b6['isAttached'],_0x12688e['isAttached']=()=>_0x12688e['_isAttached'],this['_baseRoots']['set'](_0x3a7156,_0x12688e),this['_baseRootsAttributes']['set'](_0x3a7156,_0xb57cd4),_0xcaf1b6&&this['_touchedRoots']['set'](_0x3a7156,_0xcaf1b6);const _0x439802=this['_makeIdsRoot'](_0x12688e);this['_baseIdsRoots']['set'](_0x3a7156,_0x439802);for(const [_0x340f26,_0x66d8ad]of _0x12688e['markers']){if(!_0x340f26['startsWith']('revision:'))continue;const _0x592163=_0x340f26['split'](':')[0x2];for(const _0x241227 of _0x66d8ad['getWalker']({'singleCharacters':!0x0})){const _0x5e3e01=this['_getVidAttributeName'](_0x241227),_0x270b01='elementEnd'==_0x241227['type']?_0x241227['previousPosition']['path']['slice'](0x0,-0x1):_0x241227['previousPosition']['path'],_0x16c09a=_0x439802['getNodeByPath'](_0x270b01)['getAttribute'](_0x5e3e01);this['_touched']['set'](_0x16c09a,{'userId':_0x592163});}}}this['_startingRevisionId']=this['_revisionId'];const _0x48a19a=[...Array(this['_revisionId'])['keys']()]['slice'](0x1)['filter'](_0x29c533=>!this['_touched']['has'](_0x29c533));let _0x140049=0x0;const _0x5cf1b0=new Map();for(const _0x156ef8 in _0x2e9b86['diffData']){const _0x2f3103=_0x2e9b86['diffData'][_0x156ef8]['attachChange'],_0x983bc4=_0x503699(_0x2e9b86['diffData'][_0x156ef8]['attributesAfter'])||{},_0x57bb25=_0x2da9f3['_makeModelFromViewString'](_0x2e9b86['diffData'][_0x156ef8]['insertions']);_0x57bb25['rootName']=_0x156ef8,_0x57bb25['_isAttached']=!_0x2f3103||_0x2f3103['isAttached'],_0x57bb25['isAttached']=()=>_0x57bb25['_isAttached'],this['_diffRoots']['set'](_0x156ef8,_0x57bb25),this['_diffRootsAttributes']['set'](_0x156ef8,_0x983bc4);const _0x247f0d=this['_makeIdsRoot'](_0x57bb25,Number['NEGATIVE_INFINITY']);this['_idsRoots']['set'](_0x156ef8,_0x247f0d),_0x5cf1b0['set'](_0x156ef8,_0x57bb25['isAttached']()?_0x983bc4:{});for(const [_0x44f326,_0x52d035]of _0x57bb25['markers']){if(!_0x44f326['startsWith']('revision:'))continue;const _0x5b0cbe=_0x44f326['split'](':')[0x2];for(const _0x545058 of _0x52d035['getWalker']({'singleCharacters':!0x0})){const _0x430116=this['_getVidAttributeName'](_0x545058),_0x286cf9=this['_revisionId']++,_0x37b0fb='elementEnd'==_0x545058['type']?_0x545058['previousPosition']['path']['slice'](0x0,-0x1):_0x545058['previousPosition']['path'];_0x247f0d['getNodeByPath'](_0x37b0fb)['_setAttribute'](_0x430116,_0x286cf9),this['_touched']['set'](_0x286cf9,{'userId':_0x5b0cbe});}}for(const _0x3d16d9 of this['editor']['model']['createRangeIn'](_0x57bb25)['getWalker']({'singleCharacters':!0x0})){const _0x4004ee=this['_getVidAttributeName'](_0x3d16d9),_0x2fae26='elementEnd'==_0x3d16d9['type']?_0x3d16d9['previousPosition']['path']['slice'](0x0,-0x1):_0x3d16d9['previousPosition']['path'],_0x234cf1=_0x247f0d['getNodeByPath'](_0x2fae26);_0x234cf1['getAttribute'](_0x4004ee)>0x0||_0x234cf1['_setAttribute'](_0x4004ee,_0x48a19a[_0x140049++]);}for(const [_0x28d46b,_0x5a4b01]of _0x57bb25['markers'])_0x28d46b['startsWith']('revision:')||this['_markers']['set'](_0x28d46b,_0x5a4b01);}const _0x1591a1=P('$graveyard');this['_baseRoots']['set']('$graveyard',_0x1591a1),this['_baseIdsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x1591a1,0x1));const _0x57cd79=P('$graveyard');this['_diffRoots']['set']('$graveyard',_0x57cd79),this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x57cd79,0x1));const _0x10c2cf=Array['from'](this['_diffRoots'])['map'](([_0x3ffd21,_0x4c3ef6])=>[_0x3ffd21,N(_0x4c3ef6)]);this['_saveMetaData'](this['_lastTo'],_0x10c2cf,this['_markers'],_0x5cf1b0);}['reInit'](){this['_reset'](),this['_lastFrom']=-0x1,this['_lastTo']=-0x1,this['_savedMetaData']['clear'](),this['init'](this['source']);}['_saveMetaData'](_0x482aa0,_0x3a8ff9,_0x1eeed1,_0x5bdc42){const _0x3cad58=new Map(_0x3a8ff9),_0x4f2fc0=new Map(_0x503699(_0x5bdc42)),_0x482106=new Map();for(const [_0x3ecc23,_0x57d99f]of _0x1eeed1)_0x482106['set'](_0x3ecc23,{'start':_0x57d99f['start']['clone'](),'end':_0x57d99f['end']['clone'](),'rootName':_0x57d99f['root']['rootName']});this['_savedMetaData']['set'](_0x482aa0,{'roots':_0x3cad58,'markers':_0x482106,'rootsAttributes':_0x4f2fc0});}['_removeMetaData'](_0x372795){this['_savedMetaData']['delete'](_0x372795);}['_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'](_0x6e0fd0,_0x493ebd=null){let _0xd2cd14=null;_0x6e0fd0['is']('documentFragment')||(_0xd2cd14=new ut(_0x6e0fd0['name'],{'vid_start':null===_0x493ebd?this['_revisionId']++:_0x493ebd++}));const _0x2f5e9a=[];for(const _0x4dab57 of _0x6e0fd0['getChildren']())if(_0x4dab57['is']('element')){_0x2f5e9a['push'](this['_makeIdsRoot'](_0x4dab57,_0x493ebd));const _0x4512d6=_0x2f5e9a[_0x2f5e9a['length']-0x1];null!==_0x493ebd&&(_0x493ebd=_0x4512d6['is']('element','$text')?_0x4512d6['getAttribute']('vid')+0x1:_0x4512d6['getAttribute']('vid_end')+0x1);}else{for(let _0x24327f=0x0;_0x24327f<_0x4dab57['offsetSize'];_0x24327f++)_0x2f5e9a['push'](new ut('$text',{'vid':null===_0x493ebd?this['_revisionId']++:_0x493ebd++}));}if(_0x6e0fd0['is']('documentFragment')){const _0x413220=P(_0x6e0fd0['rootName']);return _0x413220['_insertChild'](0x0,_0x2f5e9a),_0x413220;}return _0xd2cd14['_setAttribute']('vid_end',null===_0x493ebd?this['_revisionId']++:_0x493ebd++),_0xd2cd14['_insertChild'](0x0,_0x2f5e9a),_0xd2cd14;}['_calculateMetaData'](_0x45b379,_0x14af63,_0x9e84ce){this['_reset']();const {roots:_0xf328f0,markers:_0x4e681a,rootsAttributes:_0x4b3531}=this['_savedMetaData']['get'](_0x45b379);this['_baseRoots']=new Map(_0xf328f0),this['_baseRootsAttributes']=new Map(_0x503699(_0x4b3531));for(const [_0x17d4ac,_0x4a019c]of this['_baseRoots'])if('$graveyard'!==_0x17d4ac&&(this['_diffRoots']['set'](_0x17d4ac,N(_0x4a019c)),this['_diffRootsAttributes']=new Map(_0x503699(_0x4b3531)),_0x9e84ce)){const _0x5507a8=this['_revisionId'];this['_idsRoots']['set'](_0x17d4ac,this['_makeIdsRoot'](_0x4a019c)),this['_baseIdsRoots']['set'](_0x17d4ac,this['_makeIdsRoot'](_0x4a019c,_0x5507a8));}this['_startingRevisionId']=this['_revisionId'],this['_diffRoots']['set']('$graveyard',N(this['_baseRoots']['get']('$graveyard'))),_0x9e84ce&&this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](this['_baseRoots']['get']('$graveyard')));for(const [_0x3d68b5,_0x3fb929]of _0x4e681a){const _0x129126=this['_baseRoots']['get'](_0x3fb929['rootName']),_0x29327e=this['_diffRoots']['get'](_0x3fb929['rootName']),_0x1ff541=new lt(this['_fixPosition'](_0x3fb929['start'],_0x129126),this['_fixPosition'](_0x3fb929['end'],_0x129126)),_0x3a6f2a=this['_fixRange'](_0x1ff541,_0x29327e);_0x129126['markers']['set'](_0x3d68b5,_0x1ff541),this['_markers']['set'](_0x3d68b5,_0x3a6f2a);}this['_applyOperations'](_0x45b379,_0x14af63,_0x9e84ce);}['_applyOperations'](_0x2b4f0a,_0x1e0beb,_0x2ff5be){for(const _0x4ec24c of this['source']['getOperations'](_0x2b4f0a,_0x1e0beb))this['_handleOperation'](_0x4ec24c,_0x2ff5be);for(const _0x2019ab of this['_diffRoots']['values']())_0x2019ab['markers']['clear']();for(const [_0x479fc7,_0x1de13f]of this['_markers']){this['_diffRoots']['get'](_0x1de13f['root']['rootName'])['markers']['set'](_0x479fc7,_0x1de13f['clone']());}const _0x38f8a7=new Map(),_0x14dd33=new Map();for(const [_0xa85956,_0x76851e]of this['_diffRoots'])_0x38f8a7['set'](_0xa85956,N(_0x76851e)),_0x14dd33['set'](_0xa85956,this['_diffRootsAttributes']['get'](_0xa85956));this['_saveMetaData'](_0x1e0beb,_0x38f8a7,this['_markers'],_0x14dd33);}['_getPreviousFrom'](_0xc13d9b){const _0x59df54=Array['from'](this['_savedMetaData']['keys']());_0x59df54['sort']((_0x3090ed,_0x3109c7)=>_0x3090ed-_0x3109c7),_0x59df54['reverse']();for(const _0x5493a3 of _0x59df54)if(_0x5493a3<_0xc13d9b)return _0x5493a3;return Number['NEGATIVE_INFINITY'];}['_copyMarkers'](_0x5d0c8a,_0x582693){const _0x56015a=Array['from'](_0x582693['markers'])['map'](([_0x5d87de,_0x317851])=>[_0x5d87de,this['_fixRange'](_0x317851,_0x5d0c8a)]);_0x5d0c8a['markers']=new Map(_0x56015a);}['_transformMarkers'](_0x1f997f){for(const _0xc87d57 of this['_markers']['values']()){const _0x1c9e12=_0xc87d57['getTransformedByOperation'](_0x1f997f),_0x21c3b2=lt['_createFromRanges'](_0x1c9e12);_0xc87d57['start']=_0x21c3b2['start'],_0xc87d57['end']=_0x21c3b2['end'];}}['_handleOperation'](_0x3382ef,_0x4ab8e9){if('addRoot'!=_0x3382ef['type']&&'detachRoot'!=_0x3382ef['type']){if('insert'==_0x3382ef['type']){const _0x1464d2=_0x3382ef['position']['root']['rootName'];this['_diffRoots']['has'](_0x1464d2)||(this['_diffRoots']['set'](_0x1464d2,P(_0x1464d2,!0x0)),this['_diffRootsAttributes']['set'](_0x1464d2,{}),_0x4ab8e9&&this['_idsRoots']['set'](_0x1464d2,P(_0x1464d2,!0x0)));}else{if('addRootAttribute'==_0x3382ef['type']||'removeRootAttribute'==_0x3382ef['type']||'changeRootAttribute'==_0x3382ef['type'])return void this['_handleRootAttributeOperation'](_0x3382ef);'marker'==_0x3382ef['type']&&this['_handleMarkerOperation'](_0x3382ef);}if('marker'!==_0x3382ef['type']){const _0x4f6a26=this['_cloneOperation'](_0x3382ef,this['_diffRoots']);_0x4f6a26['_execute'](),this['_transformMarkers'](_0x4f6a26);}if(_0x4ab8e9)switch(_0x3382ef['type']){case'insert':this['_handleInsertOperation'](_0x3382ef);break;case'move':case'remove':case'reinsert':this['_handleMoveOperation'](_0x3382ef);break;case'merge':this['_handleMergeOperation'](_0x3382ef);break;case'split':this['_handleSplitOperation'](_0x3382ef);}}else this['_handleRootOperation'](_0x3382ef,_0x4ab8e9);}['_cloneOperation'](_0x117202,_0x40b1c6){const _0x5c1d89=_0x117202['clone']();return _0x5c1d89['_authorId']=_0x117202['_authorId'],this['_fixOperation'](_0x5c1d89,_0x40b1c6),_0x5c1d89;}['_getBaseVids'](_0x3d9dd9){return _0x3d9dd9['map'](_0x7a6b3=>{const _0x34b29d=this['_getVidAttributeName'](_0x7a6b3);return Number(_0x7a6b3['item']['getAttribute'](_0x34b29d));});}['_generateTape'](_0x4b04eb,_0x22b0c0){if(_0x4b04eb['is']('element','$text'))_0x22b0c0['push']({'item':_0x4b04eb,'type':'text'});else{_0x4b04eb['is']('element')&&_0x22b0c0['push']({'item':_0x4b04eb,'type':'elementStart'});for(const _0x3ed753 of _0x4b04eb['getChildren']())this['_generateTape'](_0x3ed753,_0x22b0c0);_0x4b04eb['is']('element')&&_0x22b0c0['push']({'item':_0x4b04eb,'type':'elementEnd'});}return _0x22b0c0;}['_getState'](){const _0x3e9ac0=new Map(this['_touched']),_0x5511bb=new Map(_0x3e9ac0),_0x14fe7e=new Map(),_0x402779={'insertions':{},'deletions':{}},_0x3f84ab={'insertions':{},'deletions':{}},_0x2c671e=new Map(),_0x21c775=new Set([...this['_baseRoots']['keys'](),...this['_diffRoots']['keys']()]);_0x21c775['delete']('$graveyard');for(const _0x19d4c6 of _0x21c775){const _0x263028=this['_diffRoots']['get'](_0x19d4c6)||P(_0x19d4c6,!0x1),_0x363621=this['_baseRoots']['get'](_0x19d4c6)||P(_0x19d4c6,!0x1);_0x263028['isAttached']()||_0x363621['isAttached']()?(_0x402779['insertions'][_0x19d4c6]=N(_0x263028),_0x402779['deletions'][_0x19d4c6]=N(_0x363621),this['_copyMarkers'](_0x402779['deletions'][_0x19d4c6],_0x363621),this['_copyMarkers'](_0x402779['insertions'][_0x19d4c6],_0x263028),_0x3f84ab['insertions'][_0x19d4c6]=this['_generateTape'](this['_idsRoots']['get'](_0x19d4c6),[]),_0x3f84ab['deletions'][_0x19d4c6]=this['_generateTape'](this['_baseIdsRoots']['get'](_0x19d4c6)||P(_0x19d4c6,!0x1),[])):_0x21c775['delete'](_0x19d4c6);}for(const _0x1d93f2 of _0x21c775){const _0x2471e2=_0x3f84ab['insertions'][_0x1d93f2];for(const _0x5460f6 of _0x2471e2){const _0x551665=this['_getVidAttributeName'](_0x5460f6),_0x36edba=_0x5460f6['item']['getAttribute'](_0x551665);_0x5511bb['delete'](_0x36edba),_0x36edba>=this['_startingRevisionId']&&_0x14fe7e['set'](_0x36edba,_0x3e9ac0['get'](_0x36edba));}}for(const _0x4ac217 of _0x21c775){const _0x921fd2=_0x3f84ab['insertions'][_0x4ac217],_0x385e83=this['_getBaseVids'](_0x3f84ab['deletions'][_0x4ac217]);let _0xab8508=0x0;for(const _0x5e5e00 of _0x921fd2){const _0x461518=this['_getVidAttributeName'](_0x5e5e00),_0x3d1696=_0x5e5e00['item']['getAttribute'](_0x461518);if(!_0x14fe7e['has'](_0x3d1696)&&!_0x2c671e['has'](_0x3d1696)){if(_0x5511bb['has'](_0x3d1696))_0xab8508++;else{if(_0x3d1696!=_0x385e83[_0xab8508]){const _0x2f6e47=_0x3e9ac0['get'](_0x3d1696)||_0x3e9ac0['get'](_0x385e83[_0xab8508]);for(;_0x3d1696!=_0x385e83[_0xab8508];)_0x5511bb['has'](_0x385e83[_0xab8508])||(_0x2c671e['set'](_0x385e83[_0xab8508],_0x2f6e47),_0x3e9ac0['set'](_0x385e83[_0xab8508],_0x2f6e47)),_0xab8508++;}_0xab8508++;}}}}for(const _0x38a27c of _0x21c775){const _0x400157=_0x3f84ab['insertions'][_0x38a27c];for(const _0x183a6f of _0x400157){const _0x46dcec=this['_getVidAttributeName'](_0x183a6f),_0x19268a=_0x183a6f['item']['getAttribute'](_0x46dcec);if(_0x2c671e['has'](_0x19268a)){const _0xcdbae3=_0x2c671e['get'](_0x19268a);_0x5511bb['has'](_0x19268a)||_0x5511bb['set'](_0x19268a,{..._0xcdbae3}),_0x14fe7e['set'](_0x19268a,{..._0xcdbae3});}}}for(const _0x2fee6b of _0x5511bb['keys']())_0x2fee6b>=this['_startingRevisionId']&&_0x5511bb['delete'](_0x2fee6b);const _0x23aa80=new Map();for(const _0x2b3c80 of _0x21c775){let _0x2ec329=_0x3f84ab['insertions'][_0x2b3c80];for(const _0x158b43 of _0x2ec329)if(_0x158b43['item']['is']('element','tableCell')){const _0x258223=this['_getVidAttributeName'](_0x158b43),_0x1a3248=_0x158b43['item']['getAttribute'](_0x258223);if(_0x14fe7e['has'](_0x1a3248)){const _0x3b67d3=_0x158b43['item']['parent']['parent']['getAttribute']('vid_start'),_0x3447b4=_0x23aa80['get'](_0x3b67d3)||new Set();_0x3447b4['add'](_0x14fe7e['get'](_0x1a3248)['userId']),_0x23aa80['set'](_0x3b67d3,_0x3447b4);}}_0x2ec329=_0x3f84ab['deletions'][_0x2b3c80];for(const _0x1b9585 of _0x2ec329)if(_0x1b9585['item']['is']('element','tableCell')){const _0x1b1363=this['_getVidAttributeName'](_0x1b9585),_0x113cad=_0x1b9585['item']['getAttribute'](_0x1b1363);if(_0x5511bb['has'](_0x113cad)){const _0x51be68=_0x1b9585['item']['parent']['parent']['getAttribute']('vid_start'),_0x4aec15=_0x23aa80['get'](_0x51be68)||new Set();_0x4aec15['add'](_0x5511bb['get'](_0x113cad)['userId']),_0x23aa80['set'](_0x51be68,_0x4aec15);}}for(const _0xe425f7 of _0x23aa80['keys']())(_0x14fe7e['has'](_0xe425f7)||_0x5511bb['has'](_0xe425f7))&&_0x23aa80['delete'](_0xe425f7);}for(const _0x58c92f of _0x21c775){const _0x5a9d10=_0x3f84ab['insertions'][_0x58c92f];let _0x319528=null,_0x3f7675=null;for(const _0x104fb6 of _0x5a9d10){const _0x10a90f=this['_getVidAttributeName'](_0x104fb6),_0x641baf=_0x104fb6['item']['getAttribute'](_0x10a90f),_0x1a2008=_0x23aa80['get'](_0x641baf);_0x1a2008&&'elementStart'==_0x104fb6['type']&&(_0x319528=Array['from'](_0x1a2008)[0x0],_0x3f7675=_0x104fb6['item']['getAttribute']('vid_end')),_0x319528&&(_0x5511bb['set'](_0x641baf,{'userId':_0x319528}),_0x14fe7e['set'](_0x641baf,{'userId':_0x319528})),_0x641baf==_0x3f7675&&(_0x319528=null,_0x3f7675=null);}}const _0x348b54={},_0x3a92bd=new Set();for(const _0x4e1ac1 of _0x21c775){const _0x466893=_0x402779['deletions'][_0x4e1ac1],_0x5d9327=_0x402779['insertions'][_0x4e1ac1];for(const {userId:_0x4132e9}of this['_touchedMarkers']['values']())null!==_0x4132e9&&_0x3a92bd['add'](_0x4132e9);for(const {userId:_0x5263d4}of this['_touchedRoots']['values']())null!==_0x5263d4&&_0x3a92bd['add'](_0x5263d4);this['_markChanges'](_0x5d9327,_0x3f84ab['insertions'][_0x4e1ac1],_0x14fe7e,'insertion',_0x3a92bd),this['_markChanges'](_0x466893,_0x3f84ab['deletions'][_0x4e1ac1],_0x5511bb,'deletion',_0x3a92bd),_0x348b54[_0x4e1ac1]={'insertions':this['_prepareViewToSave'](_0x5d9327),'deletions':this['_prepareViewToSave'](_0x466893),'attachChange':this['_touchedRoots']['get'](_0x4e1ac1)||null,'attributesBefore':_0x503699(this['_baseRootsAttributes']['get'](_0x4e1ac1))||{},'attributesAfter':_0x503699(this['_diffRootsAttributes']['get'](_0x4e1ac1))};}return{'diffData':_0x348b54,'authorsIds':Array['from'](_0x3a92bd)};}['_processRootBeforeSave'](_0x257207){for(const [,_0x4e6c0a]of _0x257207['markers']){const _0x5e0656=_0x4e6c0a['start']['getAncestors']()['filter'](_0x162967=>'tableCell'==_0x162967['name']);for(const _0x28ceac of _0x5e0656)0x1==_0x28ceac['childCount']&&_0x28ceac['getChild'](0x0)['is']('element','paragraph')&&_0x28ceac['getChild'](0x0)['_setAttribute']('keepParagraph',!0x0);}}['_prepareViewToSave'](_0x159fb7){this['_processRootBeforeSave'](_0x159fb7);const _0x37c62d=this['editor']['data']['toView'](_0x159fb7,{}),_0xfbad4f=Array['from'](_0x37c62d['getChildren']())['map'](_0x515960=>this['_getViewJson'](_0x515960));return JSON['stringify'](_0xfbad4f);}['_getViewJson'](_0xec7e43){if(_0xec7e43['is']('$text'))return _0xec7e43['data'];{const _0x15edab=this['editor']['plugins']['get']('RevisionHistoryUtils'),_0x2ecf0c=_0xec7e43,_0x364721=this['editor']['data']['htmlProcessor']['domConverter'],_0x1ef8f8={'type':_0x15edab['_getTypeCharForViewElement'](_0x2ecf0c),'name':_0x2ecf0c['name'],'attributes':Array['from'](_0x2ecf0c['getAttributes']()),'children':Array['from'](_0x2ecf0c['getChildren']())['map'](_0x4d90d8=>this['_getViewJson'](_0x4d90d8))};if(_0xec7e43['is']('uiElement')&&'$comment'!=_0xec7e43['name']){const _0x2469ec=_0xec7e43['render'](_0x364721['domDocument'],_0x364721);_0x1ef8f8['children']['push'](_0x2469ec['outerHTML']);}else{if(_0xec7e43['is']('rawElement')){const _0x4d05ea=_0x364721['domDocument']['createElement'](_0x2ecf0c['name']);_0xec7e43['render'](_0x4d05ea,_0x364721),_0x1ef8f8['children']['push'](_0x4d05ea['innerHTML']);}}const _0x42d960=Array['from'](_0x2ecf0c['getCustomProperties']());_0x42d960['length']>0x0&&(_0x1ef8f8['customProperties']=_0x42d960);const _0x1ce9df=_0x2ecf0c['getFillerOffset']();return null!==_0x1ce9df&&(_0x1ef8f8['fillerOffset']=_0x1ce9df),_0x1ef8f8;}}['_markChanges'](_0x4f2b13,_0x2b1de4,_0x5c468a,_0x16c94c,_0x2bb321){let _0x52de19=null,_0x170b96=null,_0x2df86d=0x0;const _0x28bb43=this['editor']['model'];for(let _0x4290c2=0x0;_0x4290c2<_0x2b1de4['length'];_0x4290c2++){const _0x13cd8b=this['_getVidAttributeName'](_0x2b1de4[_0x4290c2]),_0x1ea9a4=_0x2b1de4[_0x4290c2]['item']['getAttribute'](_0x13cd8b),_0x290892=_0x5c468a['get'](_0x1ea9a4),_0xc52387=_0x4290c2==_0x2b1de4['length']-0x1;(!_0x52de19&&_0x290892&&(_0x52de19=_0x290892,_0x170b96=_0x2b1de4[_0x4290c2]),_0x52de19&&(!_0x290892||_0x290892['userId']!=_0x52de19['userId']))&&(_0x2120f4(_0x290892,F(_0x170b96,_0x4f2b13,_0x28bb43),F(_0x2b1de4[_0x4290c2],_0x4f2b13,_0x28bb43)),_0x52de19=_0x290892||null,_0x170b96=_0x290892?_0x2b1de4[_0x4290c2]:null),_0x52de19&&_0xc52387&&_0x2120f4(_0x290892,F(_0x170b96,_0x4f2b13,_0x28bb43),B(_0x2b1de4[_0x4290c2],_0x4f2b13,_0x28bb43));}function _0x2120f4(_0x46d2cd,_0x2593ce,_0x19ee85){const _0x495a4f=_0x52de19['userId'],_0x303314='revision:'+_0x16c94c+':'+_0x495a4f+':'+_0x2df86d++,_0xded9e8=_0x28bb43['createRange'](_0x2593ce,_0x19ee85);_0x4f2b13['markers']['set'](_0x303314,_0xded9e8),null!==_0x495a4f&&_0x2bb321['add'](_0x495a4f);}}['_getVidAttributeName'](_0x3b914f){switch(_0x3b914f['type']){case'elementStart':return'vid_start';case'elementEnd':return'vid_end';default:return'vid';}}['_fixOperation'](_0x287c91,_0x2832bb){_0x287c91['baseVersion']=null;for(const _0x33fb5e in _0x287c91){const _0x1e27c6=_0x287c91[_0x33fb5e];if(_0x1e27c6 instanceof ft){const _0x3e4fb1=_0x2832bb['get'](_0x1e27c6['root']['rootName']);_0x287c91[_0x33fb5e]=this['_fixPosition'](_0x1e27c6,_0x3e4fb1);}if(_0x1e27c6 instanceof lt){const _0x4e54cf=_0x2832bb['get'](_0x1e27c6['root']['rootName']);_0x287c91[_0x33fb5e]=this['_fixRange'](_0x1e27c6,_0x4e54cf);}'root'===_0x33fb5e&&(_0x287c91['root']=_0x2832bb['get'](_0x287c91['root']['rootName']));}}['_fixRange'](_0x203400,_0x294a60){return this['editor']['model']['createRange'](this['_fixPosition'](_0x203400['start'],_0x294a60),this['_fixPosition'](_0x203400['end'],_0x294a60));}['_fixPosition'](_0x302a24,_0x56c3f1){return this['editor']['model']['createPositionFromPath'](_0x56c3f1,_0x302a24['path'],_0x302a24['stickiness']);}['_handleInsertOperation'](_0x786b99){const _0x3dfbd4=this['_idsRoots']['get'](_0x786b99['position']['root']['rootName']),_0x1b1b7e=this['_fixPosition'](_0x786b99['position'],_0x3dfbd4),_0x117ee7=null===_0x786b99['_authorId']?null:_0x786b99['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x35eac2=_0x1b1b7e['parent'],_0x27b3bd=this['_revisionId'],_0x279afa=[];for(const _0x478db8 of _0x786b99['nodes'])if(_0x478db8['is']('element'))_0x279afa['push'](this['_makeIdsRoot'](_0x478db8));else{for(let _0x3b5e54=0x0;_0x3b5e54<_0x478db8['offsetSize'];_0x3b5e54++)_0x279afa['push'](new ut('$text',{'vid':this['_revisionId']++}));}const _0x53bb97=this['_revisionId'];for(let _0xcfdeed=_0x27b3bd;_0xcfdeed<_0x53bb97;_0xcfdeed++)this['_touched']['set'](_0xcfdeed,{'userId':_0x117ee7});_0x35eac2['_insertChild'](_0x1b1b7e['offset'],_0x279afa);}['_handleMoveOperation'](_0x1da144){(_0x1da144=this['_cloneOperation'](_0x1da144,this['_idsRoots']))['_execute']();const _0x5b4921=null===_0x1da144['_authorId']?null:_0x1da144['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x2bddf2=_0x1da144['getMovedRangeStart'](),_0x3bc832=_0x2bddf2['parent'],_0x2c31bb=_0x2bddf2['offset'];!function _0x19dff1(_0x5cc820,_0x212a2d,_0x4f01db,_0x1f2d12){for(let _0x1a2814=_0x4f01db;_0x1a2814<_0x1f2d12;_0x1a2814++){const _0x31aab2=_0x212a2d['getChild'](_0x1a2814);_0x31aab2['is']('element','$text')?_0x5cc820['set'](_0x31aab2['getAttribute']('vid'),{'userId':_0x5b4921}):(_0x5cc820['set'](_0x31aab2['getAttribute']('vid_start'),{'userId':_0x5b4921}),_0x19dff1(_0x5cc820,_0x31aab2,0x0,_0x31aab2['childCount']),_0x5cc820['set'](_0x31aab2['getAttribute']('vid_end'),{'userId':_0x5b4921}));}}(this['_touched'],_0x3bc832,_0x2c31bb,_0x2c31bb+_0x1da144['howMany']);}['_handleMergeOperation'](_0x55ccc3){const _0x51a1a0=null===(_0x55ccc3=this['_cloneOperation'](_0x55ccc3,this['_idsRoots']))['_authorId']?null:_0x55ccc3['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x4c30c9=_0x55ccc3['targetPosition']['parent'],_0xb82a6e=_0x55ccc3['sourcePosition']['parent'],_0x4583b9=_0x4c30c9['getAttribute']('vid_end'),_0x11e8ff=_0xb82a6e['getAttribute']('vid_start');_0x4c30c9['_setAttribute']('vid_end',_0xb82a6e['getAttribute']('vid_end')),_0xb82a6e['_setAttribute']('vid_end',_0x4583b9),this['_touched']['set'](_0x11e8ff,{'userId':_0x51a1a0}),this['_touched']['set'](_0x4583b9,{'userId':_0x51a1a0}),_0x55ccc3['_execute']();}['_handleSplitOperation'](_0x26b862){const _0x5ca6ec=null===(_0x26b862=this['_cloneOperation'](_0x26b862,this['_idsRoots']))['_authorId']?null:_0x26b862['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x282d39=_0x26b862['graveyardPosition'],_0x221e14=_0x26b862['splitPosition']['parent'];_0x26b862['_execute']();const _0x41e470=_0x221e14['getAttribute']('vid_end'),_0x283e03=_0x26b862['insertionPosition']['nodeAfter'];if(_0x282d39){const _0x62956a=_0x283e03['getAttribute']('vid_end'),_0x8dcce5=_0x221e14['getAttribute']('vid_end');_0x221e14['_setAttribute']('vid_end',_0x62956a),_0x283e03['_setAttribute']('vid_end',_0x8dcce5),this['_touched']['set'](_0x221e14['getAttribute']('vid_end'),{'userId':_0x5ca6ec}),this['_touched']['set'](_0x283e03['getAttribute']('vid_start'),{'userId':_0x5ca6ec});}else{const _0x4c1862=this['_revisionId']++,_0x50299f=this['_revisionId']++;_0x221e14['_setAttribute']('vid_end',_0x4c1862),_0x283e03['_setAttribute']('vid_start',_0x50299f),_0x283e03['_setAttribute']('vid_end',_0x41e470),this['_touched']['set'](_0x4c1862,{'userId':_0x5ca6ec}),this['_touched']['set'](_0x50299f,{'userId':_0x5ca6ec});}}['_handleMarkerOperation'](_0x51c16c){if(!_0x51c16c['affectsData'])return;const _0x55fb07=(_0x51c16c=this['_cloneOperation'](_0x51c16c,this['_diffRoots']))['oldRange']?_0x51c16c['oldRange']['root']:null,_0x5212a7=_0x51c16c['newRange']?_0x51c16c['newRange']['root']:null;_0x55fb07&&this['_markers']['delete'](_0x51c16c['name']),_0x5212a7&&this['_markers']['set'](_0x51c16c['name'],_0x51c16c['newRange']['clone']());const _0x15f448=null===_0x51c16c['_authorId']?null:_0x51c16c['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x442e0a=_0x51c16c['name'];if(!this['_touchedMarkers']['has'](_0x442e0a))return void this['_touchedMarkers']['set'](_0x442e0a,{'range':_0x51c16c['oldRange'],'userId':_0x15f448});const _0x4483fb=this['_touchedMarkers']['get'](_0x442e0a),_0x13f00a=_0x4483fb['range'],_0x1214cf=_0x51c16c['newRange'];null==_0x13f00a&&null==_0x1214cf||_0x13f00a&&_0x1214cf&&_0x13f00a['isEqual'](_0x1214cf)?this['_touchedMarkers']['delete'](_0x51c16c['name']):_0x4483fb['userId']=_0x15f448;}['_handleRootOperation'](_0x525dd0,_0x1b2359){this['_diffRoots']['has'](_0x525dd0['rootName'])?this['_diffRoots']['get'](_0x525dd0['rootName'])['_isAttached']=_0x525dd0['isAdd']:(this['_diffRoots']['set'](_0x525dd0['rootName'],P(_0x525dd0['rootName'],!0x0)),this['_diffRootsAttributes']['set'](_0x525dd0['rootName'],{}),_0x1b2359&&this['_idsRoots']['set'](_0x525dd0['rootName'],P(_0x525dd0['rootName'],!0x0)));const _0x1c8d48=null===_0x525dd0['_authorId']?null:_0x525dd0['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x1f3741=this['_touchedRoots']['get'](_0x525dd0['rootName']);_0x1f3741&&_0x1f3741['userId']===_0x1c8d48?this['_touchedRoots']['delete'](_0x525dd0['rootName']):this['_touchedRoots']['set'](_0x525dd0['rootName'],{'userId':_0x1c8d48,'isAttached':_0x525dd0['isAdd']});}['_handleRootAttributeOperation'](_0x207f05){const _0x1cd77a=this['_diffRootsAttributes']['get'](_0x207f05['root']['rootName']);null===_0x207f05['newValue']?delete _0x1cd77a[_0x207f05['key']]:_0x1cd77a[_0x207f05['key']]=_0x207f05['newValue'];}}function N(_0x26dcde){const _0x43fd28=P(_0x26dcde['rootName'],_0x26dcde['isAttached']());for(const _0xef7cc1 of _0x26dcde['getChildren']()){const _0x9ceddb=_0xef7cc1['_clone'](!0x0);_0x43fd28['_appendChild'](_0x9ceddb);}return _0x43fd28;}function P(_0x410093,_0x45d856=!0x0){const _0x521664=new vt();return _0x521664['rootName']=_0x410093,_0x521664['_isAttached']=_0x45d856,_0x521664['isAttached']=()=>_0x521664['_isAttached'],_0x521664;}function F(_0x2ca3a6,_0x21d78c,_0x16871a){const _0x57689a='elementEnd'==_0x2ca3a6['type']?_0x16871a['createPositionAt'](_0x2ca3a6['item'],'end'):_0x16871a['createPositionBefore'](_0x2ca3a6['item']);return _0x16871a['createPositionFromPath'](_0x21d78c,_0x57689a['path'],_0x57689a['stickiness']);}function B(_0xea1aaf,_0x529d1f,_0x58e4f8){const _0x1a7187='elementStart'==_0xea1aaf['type']?_0x58e4f8['createPositionAt'](_0xea1aaf['item'],0x0):_0x58e4f8['createPositionAfter'](_0xea1aaf['item']);return _0x58e4f8['createPositionFromPath'](_0x529d1f,_0x1a7187['path'],_0x1a7187['stickiness']);}class hs extends ts{['focusTracker'];['keystrokes'];['revisionNameInputView'];constructor(_0x1ca0c2,_0x4541e5){super(_0x1ca0c2),this['focusTracker']=new _0x338ab8(),this['keystrokes']=new _0x143d1e(),this['set']('revisionNameInputValue',''),this['revisionNameInputView']=this['_createRevisionNameInput'](_0x4541e5),this['setTemplate']({'tag':'form','attributes':{'class':['ck','ck-revision-history-save-revision-form','ck-responsive-form'],'tabindex':'-1'},'children':[this['revisionNameInputView']]}),_0x149bf4(this);}['render'](){super['render'](),_0x451b44({'view':this}),this['focusTracker']['add'](this['revisionNameInputView']['element']),this['keystrokes']['listenTo'](this['element']);const _0x5a9473=_0x292e1b=>_0x292e1b['stopPropagation']();this['keystrokes']['set']('arrowright',_0x5a9473),this['keystrokes']['set']('arrowleft',_0x5a9473),this['keystrokes']['set']('arrowup',_0x5a9473),this['keystrokes']['set']('arrowdown',_0x5a9473);}['focus'](){this['revisionNameInputView']['focus']();}get['revisionName'](){return this['revisionNameInputView']['fieldView']['element']['value']['trim']();}set['revisionName'](_0x567d7a){this['revisionNameInputView']['fieldView']['element']['value']=_0x567d7a['trim']();}['reset'](){this['revisionNameInputView']['fieldView']['element']['value']='',this['revisionNameInputView']['errorText']=null;}['_createRevisionNameInput'](_0x34c37a){const _0x8213db=new _0x4a54d4(this['locale'],_0x37da91),_0x1a9223=_0x8213db['fieldView'];_0x1a9223['extendTemplate']({'attributes':{'maxlength':'220'}});let _0x2c993c=g(this['locale'],'Name\x20of\x20the\x20revision');return!_0x34c37a&&(_0x2c993c+='\x20('+g(this['locale'],'optional')+')'),(_0x8213db['label']=_0x2c993c,_0x1a9223['on']('input',()=>{this['revisionNameInputValue']=_0x1a9223['element']['value']['trim']();}),_0x8213db);}}class f extends _0x527fd9{static get['pluginName'](){return'RevisionHistoryUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[u];}['_saveRevisionFormView'];['init'](){const _0x4ce05c=this['editor'],_0x554009=_0x4ce05c['plugins']['get']('RevisionTracker');_0x4ce05c['ui']['componentFactory']['add']('revisionHistory',_0x48d4d3=>{const _0x17220b=_0x2bb1f1(_0x48d4d3),_0x17ec5c=_0x17220b['panelView']['children'],_0x17c61f=new _0x28cadf(_0x48d4d3),_0x4a78d3=new _0x3bce81(_0x48d4d3),_0x2c1bcf=new te(_0x48d4d3),_0x272fdb=new _0x3bce81(_0x48d4d3),_0x4664e4=new te(_0x48d4d3);return _0x17220b['bind']('isEnabled')['to'](_0x554009,'isReady',_0x554009,'isEnabled',_0x4ce05c,'isReadOnly',(_0x451021,_0x2612f2,_0x262831)=>_0x451021&&_0x2612f2&&!_0x262831),_0x17220b['buttonView']['set']({'icon':_0x278e4f,'label':g(_0x48d4d3,'Revision\x20history'),'tooltip':!0x0}),_0x2c1bcf['set']({'label':g(_0x48d4d3,'Save\x20current\x20revision'),'withText':!0x0,'role':'menuitem'}),_0x2c1bcf['bind']('isEnabled')['to'](_0x554009,'isReady',_0x554009,'isEnabled',_0x4ce05c,'isReadOnly',(_0x2909b3,_0x57f6e0,_0x56981c)=>_0x2909b3&&_0x57f6e0&&!_0x56981c),_0x2c1bcf['on']('execute',()=>this['_showDialog']()),_0x4664e4['set']({'label':g(_0x48d4d3,'Open\x20revision\x20history'),'withText':!0x0,'role':'menuitem'}),_0x4664e4['bind']('isEnabled')['to'](_0x554009,'isReady',_0x4ce05c,'isReadOnly',(_0xbbb33,_0x327778)=>_0xbbb33&&!_0x327778),_0x4664e4['on']('execute',()=>{_0x4ce05c['config']['get']('revisionHistory')['showRevisionViewerCallback'](),_0x17220b['isOpen']=!0x1,_0x4ce05c['editing']['view']['focus']();}),_0x4a78d3['children']['add'](_0x2c1bcf),_0x272fdb['children']['add'](_0x4664e4),_0x17c61f['role']='menu',_0x17c61f['items']['addMany']([_0x4a78d3,_0x272fdb]),_0x17ec5c['add'](_0x17c61f),_0x17220b;}),_0x4ce05c['ui']['componentFactory']['add']('menuBar:revisionHistory',()=>this['_registerMenuComponent']());}['_registerMenuComponent'](){const _0x513175=this['editor'],_0x5969a7=_0x513175['locale'],_0x24f03d=new _0x77737(_0x5969a7),_0xd574ec=new _0x4c1111(_0x5969a7);_0x24f03d['buttonView']['set']({'icon':_0x278e4f,'label':g(_0x5969a7,'Revision\x20history')});const _0x1bac82=new _0x94bb0e(_0x5969a7,_0x24f03d),_0x585fed=new _0x1308fb(_0x5969a7);_0x585fed['set']({'label':g(_0x5969a7,'Save\x20current\x20revision')}),_0x585fed['delegate']('execute')['to'](_0x24f03d),_0x585fed['on']('execute',()=>{this['_showDialog']();}),_0x1bac82['children']['add'](_0x585fed),_0xd574ec['items']['add'](_0x1bac82);const _0x522c98=new _0x94bb0e(_0x5969a7,_0x24f03d),_0x521d34=new _0x1308fb(_0x5969a7);return _0x521d34['set']({'label':g(_0x5969a7,'Open\x20revision\x20history')}),_0x521d34['delegate']('execute')['to'](_0x24f03d),_0x521d34['on']('execute',()=>{_0x513175['config']['get']('revisionHistory')['showRevisionViewerCallback']();}),_0x522c98['children']['add'](_0x521d34),_0xd574ec['items']['add'](_0x522c98),_0x24f03d['panelView']['children']['add'](_0xd574ec),_0x24f03d;}['_showDialog'](){const _0x5042e9=this['editor'],_0x1580d9=_0x5042e9['locale'],_0x1fa9b1=_0x5042e9['plugins']['get']('Dialog'),_0x53167c=_0x5042e9['plugins']['get']('RevisionTracker');function _0x3d0c96(_0x5bcf5b){_0x5042e9['config']['get']('revisionHistory.requireRevisionName')&&''===_0x5bcf5b['revisionName']?_0x5bcf5b['revisionNameInputView']['errorText']=g(_0x1580d9,'The\x20revision\x20name\x20cannot\x20be\x20empty.'):(_0x5042e9['plugins']['get'](u)['saveRevision']({'name':_0x5bcf5b['revisionName']}),_0x1fa9b1['hide']());}this['_saveRevisionFormView']||(this['_createSaveRevisionFormView'](),this['_saveRevisionFormView']['on']('submit',()=>_0x3d0c96(this['_saveRevisionFormView']))),this['_saveRevisionFormView']['reset'](),_0x1fa9b1['show']({'id':'revisionSave','title':g(_0x1580d9,'Save\x20current\x20revision'),'isModal':!0x0,'content':this['_saveRevisionFormView'],'actionButtons':[{'label':g(_0x5042e9['locale'],'Cancel'),'withText':!0x0,'onExecute':()=>_0x1fa9b1['hide']()},{'label':g(_0x5042e9['locale'],'Accept'),'class':'ck-button-action','withText':!0x0,'onCreate'(_0x13aa57){_0x13aa57['bind']('isEnabled')['to'](_0x53167c,'isReady',_0x53167c,'isEnabled',_0x5042e9,'isReadOnly',(_0x4d5d57,_0x37d435,_0x14d916)=>_0x4d5d57&&_0x37d435&&!_0x14d916);},'onExecute':()=>_0x3d0c96(this['_saveRevisionFormView'])}]});}['_createSaveRevisionFormView'](){const _0x5519fd=this['editor'],_0x41dbc8=_0x5519fd['locale'];this['_saveRevisionFormView']=new hs(_0x41dbc8,_0x5519fd['config']['get']('revisionHistory.requireRevisionName')),this['_saveRevisionFormView']['render']();}}class Q extends ts{['changeId'];['_model'];constructor(_0x1cacb3,_0x3c05f4){super(_0x1cacb3),this['_model']=_0x3c05f4,this['changeId']=_0x3c05f4['id'];const _0x409b70=this['bindTemplate'],_0x47aa75=g(_0x1cacb3,_0x3c05f4['data']['isSuggestion']?'Suggested\x20by':'add'==_0x3c05f4['type']?'Added\x20by':'Removed\x20by');this['set']('type',_0x3c05f4['type']),this['setTemplate']({'tag':'div','attributes':{'class':['ck-annotation','ck-revision-change',_0x409b70['to']('type',_0x36f106=>'ck-revision-change__'+_0x36f106)],'tabindex':-0x1},'children':[{'tag':'span','children':[{'tag':'span','attributes':{'class':['ck-revision-change__label']},'children':[{'text':_0x47aa75}]},{'text':'\x20'+_0x3c05f4['author']['name']}]}]});}['focus'](){this['element']['focus']();}}class r extends/* #__PURE__ -- @preserve */
|
|
25
|
+
_0x11f117(){['id'];['author'];['type'];['data'];['rootName'];constructor(_0x253aff){super(),this['id']=_0x253aff['id']||_0x571ba5(),this['author']=_0x253aff['author'],this['type']=_0x253aff['type'],this['data']=_0x253aff['data']||{},this['rootName']=_0x253aff['rootName'],this['set']('createdAt',_0x253aff['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(_0x1a6ed2,_0x895860){this['newRevisionId']=_0x1a6ed2,this['oldRevisionId']=_0x895860,this['changes']=new _0x3f8e7a();}['_setChanges'](_0x3f39b2){for(const _0x2f0088 of _0x3f39b2)this['changes']['add'](_0x2f0088);}}class m extends _0x527fd9{['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[_0x386857,_0x3e17e6,I,V];}constructor(_0x1dd1c3){super(_0x1dd1c3),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',(_0x5becc3,_0x210ad7,_0x54e0e3)=>{this['activeChange']=null,this['activeView']=null,this['editor']['editing']['view']['change'](_0x40460d=>{for(const _0x528ec0 of this['editor']['editing']['view']['document']['roots'])_0x54e0e3?_0x40460d['removeClass']('ck-editor__editable__overlay',_0x528ec0):_0x40460d['addClass']('ck-editor__editable__overlay',_0x528ec0);});}),this['bind']('isNavigationMode')['to'](this,'activeChange',_0x38ae94=>null!==_0x38ae94),this['bind']('currentChangeNumber')['to'](this,'isReady',this,'diff',this,'activeChange',(_0x57d97c,_0x224b26,_0x6af041)=>_0x57d97c&&_0x6af041?_0x224b26['changes']['getIndex'](_0x6af041):0x0),this['bind']('numberOfChanges')['to'](this,'isReady',this,'diff',(_0x454e24,_0x122338)=>_0x454e24?_0x122338['changes']['length']:0x0),this['_changeView']=null,this['_changeIdToChange']=new Map(),this['_balloon']=this['editor']['plugins']['get'](_0x3e17e6);}['init'](){const _0x2c3997=this['editor'],_0x5a1920=new wt(_0x2c3997,{'direction':'backward'}),_0x519c02=new wt(_0x2c3997,{'direction':'forward'});(_0x2c3997['commands']['add']('showPreviousChange',_0x5a1920),_0x2c3997['commands']['add']('showNextChange',_0x519c02),_0x2c3997['commands']['add']('restoreRevision',new mt(_0x2c3997)),this['on']('change:numberOfChanges',()=>{_0x5a1920['refresh'](),_0x519c02['refresh']();}),this['_setConversion'](),this['_initInteractions'](),_0x2c3997['enableReadOnlyMode']('revision-viewer'),_0x2c3997['plugins']['has']('WidgetToolbarRepository'))&&_0x2c3997['plugins']['get']('WidgetToolbarRepository')['forceDisabled']('revision-viewer');}async['getRevisionDocumentData'](_0x437f93){return await this['_utils']['loadRevisionData'](_0x437f93,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x437f93);}async['getRevisionRootsAttributes'](_0xba2e0b){return await this['_utils']['loadRevisionData'](_0xba2e0b,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0xba2e0b);}async['compare'](_0x4f86d7,_0x55b7ed,_0xf09334=!0x1){if(!this['isEnabled'])return;const _0x328380=this['diff'],_0x11f5af=this['repository'],_0x20a247='string'==typeof _0x4f86d7?_0x11f5af['getRevision'](_0x4f86d7):_0x4f86d7,_0x22a647='string'==typeof _0x55b7ed?_0x11f5af['getRevision'](_0x55b7ed):_0x55b7ed,_0xd878a6=_0x20a247['id'],_0x33bdbe=_0x22a647?_0x22a647['id']:null;if(!_0xf09334&&this['diff']&&this['diff']['newRevisionId']===_0xd878a6&&this['diff']['oldRevisionId']===_0x33bdbe)return Promise['resolve']();this['isReady']=!0x1,this['activeView']=null,this['activeChange']=null,this['diff']=new c(_0xd878a6,_0x33bdbe);const _0x1d9c29=this['_getRevisionsRange'](_0x20a247,_0x22a647,!0x0)['map'](_0xa4931f=>this['_utils']['loadRevisionData'](_0xa4931f,this['adapter']));return _0x1d9c29['push'](new Promise(_0x3c5f2d=>{setTimeout(_0x3c5f2d,0x14);})),Promise['all'](_0x1d9c29)['then'](()=>{if(!this['isEnabled'])return;this['_cleanUp']();const _0x31796e=this['_getDiff'](_0xd878a6,_0x33bdbe);for(const _0xc998c2 of _0x31796e['changes'])this['_changeIdToChange']['set'](_0xc998c2['id'],_0xc998c2);this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x566424=>{for(const _0x346a1c of this['editor']['model']['document']['getRootNames']())_0x566424['detachRoot'](_0x346a1c);for(const _0x3164ab of Object['keys'](_0x31796e['model'])){const _0x203c40=_0x566424['addRoot'](_0x3164ab);for(const _0x43d868 of Object['keys'](_0x31796e['attributes'][_0x3164ab]))_0x566424['setAttribute'](_0x43d868,_0x31796e['attributes'][_0x3164ab][_0x43d868],_0x203c40);_0x566424['insert'](_0x31796e['model'][_0x3164ab],_0x203c40,0x0);}}),this['diff']['_setChanges'](this['_sortAndFilterDiffChanges'](_0x31796e['changes'])),this['isReady']=!0x0;})['catch'](_0x283fbf=>{console['error'](_0x283fbf),this['_cleanUp'](),_0x328380&&(this['diff']=_0x328380),this['isReady']=!0x0;});}['addRevisionData'](_0x3aa9c4,_0x164fbb){const _0x47a7b1=this['repository']['createRevision'](_0x3aa9c4);return _0x47a7b1['on']('_update',(_0x228d10,_0x34f80b,_0x194101)=>_0x164fbb(_0x34f80b,_0x194101,_0x47a7b1)),this['repository']['addRevision'](_0x47a7b1),_0x47a7b1;}['_cleanUp'](){this['activeChange']=null,this['_cleanMarkers'](),this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=null,this['_changeIdToChange']['clear'](),this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x124721=>{for(const _0x3fdf97 of this['editor']['model']['document']['getRootNames']())_0x124721['detachRoot'](_0x3fdf97);});}['_sortAndFilterDiffChanges'](_0x23e84){const _0x128e46=[],_0x4b101a=new Map();for(const _0x238495 of this['editor']['model']['document']['getRootNames']()){const _0x38b158=this['editor']['editing']['view']['getDomRoot'](_0x238495);if(!_0x38b158)continue;const _0x139342=_0x38b158['getClientRects']()['item'](0x0);_0x139342&&(_0x128e46['push'](_0x238495),_0x4b101a['set'](_0x238495,_0x139342));}return _0x128e46['sort']((_0x2deba7,_0x14431c)=>{const _0x53e630=_0x4b101a['get'](_0x2deba7),_0x1d2af1=_0x4b101a['get'](_0x14431c);return _0x53e630['y']-_0x1d2af1['y']||_0x53e630['x']-_0x1d2af1['x'];}),(_0x23e84=_0x23e84['filter'](_0x3cab61=>_0x128e46['includes'](_0x3cab61['rootName'])))['sort']((_0x1a805a,_0x2ce7b5)=>_0x128e46['indexOf'](_0x1a805a['rootName'])-_0x128e46['indexOf'](_0x2ce7b5['rootName'])),_0x23e84;}['_makeTape'](_0x3e9d4e){const _0x1daaa7=Array['from'](_0x3e9d4e['markers'])['filter'](([_0xa53cc4,_0x1a4de6])=>_0xa53cc4['startsWith']('revision:')&&!_0x1a4de6['isCollapsed']),_0x260c07=Array['from'](this['editor']['model']['createRangeIn'](_0x3e9d4e)['getWalker']({'singleCharacters':!0x0}));if(0x0!=_0x1daaa7['length'])for(const _0x5becb3 of _0x260c07){const [_0x14b6bb,_0x544c2d]=_0x1daaa7[0x0],[,_0x30e500,_0xc58016]=_0x14b6bb['split'](':');if(_0x544c2d['end']['isEqual'](_0x5becb3['nextPosition'])&&_0x1daaa7['shift'](),(_0x5becb3['previousPosition']['isEqual'](_0x544c2d['start'])||_0x5becb3['previousPosition']['isAfter'](_0x544c2d['start']))&&('insertion'==_0x30e500?_0x5becb3['isAdded']={'userId':_0xc58016}:'deletion'==_0x30e500&&(_0x5becb3['isRemoved']={'userId':_0xc58016})),0x0==_0x1daaa7['length'])break;}return _0x260c07;}['_refreshStartEndIndex'](_0x5cf851){const _0x30e2c1=new Map();for(let _0x21adf4=0x0;_0x21adf4<_0x5cf851['length'];_0x21adf4++)'text'===_0x5cf851[_0x21adf4]['type']?(_0x5cf851[_0x21adf4]['item']['startIndex']=_0x21adf4,_0x5cf851[_0x21adf4]['item']['endIndex']=_0x21adf4):('elementStart'===_0x5cf851[_0x21adf4]['type']?_0x5cf851[_0x21adf4]['item']['startIndex']=_0x21adf4:'elementEnd'===_0x5cf851[_0x21adf4]['type']&&(_0x5cf851[_0x21adf4]['item']['endIndex']=_0x21adf4),_0x30e2c1['set'](_0x5cf851[_0x21adf4]['id'],_0x21adf4));for(const _0x422fdf of _0x30e2c1['values']())'elementStart'===_0x5cf851[_0x422fdf]['type']?_0x5cf851[_0x422fdf]['item']['endIndex']=_0x30e2c1['get'](_0x5cf851[_0x422fdf]['pairId']):'elementEnd'===_0x5cf851[_0x422fdf]['type']&&(_0x5cf851[_0x422fdf]['item']['startIndex']=_0x30e2c1['get'](_0x5cf851[_0x422fdf]['pairId']));}['_processTape'](_0xc090ec){for(let _0xa8889c=0x0;_0xa8889c<_0xc090ec['length'];_0xa8889c++){if('elementStart'===_0xc090ec[_0xa8889c]['type'])_0xc090ec[_0xa8889c]['item']['startIndex']=_0xa8889c;else{if('elementEnd'===_0xc090ec[_0xa8889c]['type']){_0xc090ec[_0xa8889c]['item']['endIndex']=_0xa8889c;const _0x39ef01=_0xc090ec[_0xa8889c]['item']['startIndex'];_0xc090ec[_0x39ef01]['pairId']=_0xc090ec[_0xa8889c]['id'],_0xc090ec[_0xa8889c]['pairId']=_0xc090ec[_0x39ef01]['id'];}else _0xc090ec[_0xa8889c]['item']['startIndex']=_0xa8889c,_0xc090ec[_0xa8889c]['item']['endIndex']=_0xa8889c,_0xc090ec[_0xa8889c]['pairId']=null;}_0xc090ec[_0xa8889c]['markersStart']||(_0xc090ec[_0xa8889c]['markersStart']=[],_0xc090ec[_0xa8889c]['markersEnd']=[]);}}['_markInsertions'](_0x3f7fd9,_0x495c69){const _0x1e92ad=_0x3f7fd9['filter'](_0x41b05e=>!_0x41b05e['isAdded']);for(let _0x5a3b56=0x0;_0x5a3b56<_0x495c69['length'];_0x5a3b56++)_0x495c69[_0x5a3b56]['isAdded']&&(_0x1e92ad[_0x5a3b56]['isAdded']=_0x495c69[_0x5a3b56]['isAdded']);}['_getDiff'](_0x75545d,_0x5ef397=null){const _0x4558cb=this['repository']['getRevision'](_0x75545d),_0x546ea9=_0x5ef397?this['repository']['getRevision'](_0x5ef397):null,_0x4f98a8=this['_getRevisionsRange'](_0x4558cb,_0x546ea9),_0x3eeac5=_0x4f98a8[_0x4f98a8['length']-0x1],_0x59af94=new Map(),_0x287e29={'model':{},'attributes':{},'changes':[]},_0x4ec825=new Set(),_0x8af27d=new Map();for(let _0x1a2d33=_0x4f98a8['length']-0x1;_0x1a2d33>=0x0;_0x1a2d33--){const _0x2933b8=_0x4f98a8[_0x1a2d33];for(const _0x1d3762 of Object['keys'](_0x2933b8['diffData']))if(_0x2933b8['diffData'][_0x1d3762]['attachChange']){const _0x288a47=_0x2933b8['diffData'][_0x1d3762]['attachChange'];_0x288a47['isAttached']?(_0x4ec825['add'](_0x1d3762),_0x8af27d['has'](_0x1d3762)&&_0x8af27d['get'](_0x1d3762)['userId']==_0x288a47['userId']?_0x8af27d['delete'](_0x1d3762):_0x8af27d['set'](_0x1d3762,_0x288a47)):_0x8af27d['has'](_0x1d3762)?(_0x4ec825['delete'](_0x1d3762),_0x8af27d['delete'](_0x1d3762)):(_0x4ec825['add'](_0x1d3762),_0x8af27d['set'](_0x1d3762,_0x288a47));}else _0x4ec825['add'](_0x1d3762);}for(const _0x5c972a of _0x4ec825){const _0x4fb16c=_0x8af27d['has'](_0x5c972a)&&!_0x8af27d['get'](_0x5c972a)['isAttached'];let _0x330ad9=_0x4fb16c?_0x4f98a8['length']-0x1:0x0;const _0x116570=_0x4fb16c?-0x1:0x1;for(;_0x4f98a8[_0x330ad9];){const _0x402781=_0x4f98a8[_0x330ad9];if(_0x402781['diffData'][_0x5c972a]){const _0x88df65=_0x4fb16c?_0x402781['diffData'][_0x5c972a]['attributesBefore']:_0x402781['diffData'][_0x5c972a]['attributesAfter'];_0x287e29['attributes'][_0x5c972a]=_0x88df65?_0x503699(_0x88df65):{};break;}_0x330ad9+=_0x116570;}}for(const _0x1a417c of _0x4f98a8){_0x1a417c['model']={};for(const _0x54a338 of _0x1a417c['authors'])_0x59af94['set'](_0x54a338['id'],_0x54a338);for(const _0x157c72 of _0x4ec825){const _0x252230=_0x1a417c['diffData'][_0x157c72]?_0x1a417c['diffData'][_0x157c72]['insertions']:'[]',_0x38401b=_0x1a417c['diffData'][_0x157c72]?_0x1a417c['diffData'][_0x157c72]['deletions']:'[]';_0x1a417c['model'][_0x157c72]={'insertions':this['_utils']['_makeModelFromViewString'](_0x252230),'deletions':this['_utils']['_makeModelFromViewString'](_0x38401b)};}}for(const _0x329e3b of _0x4ec825){let _0xe25347=null,_0x2fc05f=0x0;const _0x21878a=new Map(Array['from'](_0x4558cb['model'][_0x329e3b]['insertions']['markers'])['filter'](([_0x57035b])=>!_0x57035b['startsWith']('revision:')));let _0x3d97a0=0x0;for(const _0x35195b of _0x4f98a8){const _0x415d2e=this['_makeTape'](_0x35195b['model'][_0x329e3b]['insertions']);_0x35195b==_0x4558cb?(_0xe25347=_0x415d2e,_0x2fc05f=_0xe25347['length'],_0xe25347['forEach'](_0x1df6d8=>{_0x1df6d8['id']=_0x3d97a0++;}),this['_processTape'](_0xe25347)):this['_markInsertions'](_0xe25347,_0x415d2e);const _0x36549e=_0xe25347['filter'](_0xbeb9b8=>!_0xbeb9b8['isAdded'])['map'](_0x127970=>_0x127970['id']);let _0x263539=0x0;const _0x32dfcf=this['_makeTape'](_0x35195b['model'][_0x329e3b]['deletions']);_0x32dfcf['forEach'](_0x5583e9=>{_0x5583e9['isRemoved']?_0x5583e9['id']=_0x2fc05f++:_0x5583e9['id']=_0x36549e[_0x263539++];}),this['_processTape'](_0x32dfcf),this['_setDistance'](_0xe25347,'isAdded'),this['_setDistance'](_0x32dfcf,'isRemoved'),_0x35195b==_0x4558cb&&this['_markMarkers'](_0xe25347,_0x21878a),_0xe25347=this['_joinTapes'](_0xe25347,_0x32dfcf),this['_refreshStartEndIndex'](_0xe25347),this['_setDistance'](_0xe25347,'isRemoved');}_0xe25347=_0xe25347['filter'](_0xebf1c8=>!(_0xebf1c8['isAdded']&&_0xebf1c8['isRemoved']));const _0x4e8a9f=new Map(_0x3eeac5['model'][_0x329e3b]['deletions']['markers']),_0x557213=new Set(_0x21878a['keys']());for(const _0x267684 of _0x4e8a9f['keys']())_0x557213['delete'](_0x267684);this['_markSuggestions'](_0xe25347,_0x557213),this['_fixObsoleteTags'](_0xe25347),_0xe25347=this['_removeMissingPairs'](_0xe25347),_0xe25347=this['_markMismatchedRemovedTags'](_0xe25347),_0xe25347=this['_removeUnsupportedChanges'](_0xe25347);const {root:_0x333b09,changes:_0x44d4f4}=this['_makeModelFromTape'](_0xe25347,_0x59af94,_0x329e3b);_0x287e29['model'][_0x329e3b]=_0x333b09;const _0x4c43ce=_0x8af27d['get'](_0x329e3b);if(_0x4c43ce){const _0x3a2a1=_0x59af94['get'](_0x4c43ce['userId']),_0x1896d6=new r({'author':_0x3a2a1,'type':_0x4c43ce['isAttached']?'add':'remove','data':{'isOnRoot':!0x0},'createdAt':new Date(),'rootName':_0x329e3b});_0x44d4f4['unshift'](_0x1896d6),_0x287e29['attributes'][_0x329e3b]['revisionHistoryAttachChange']=_0x1896d6['id'];}_0x287e29['changes']=_0x287e29['changes']['concat'](_0x44d4f4);}return _0x287e29;}['_markMarkers'](_0x1468a5,_0x49146c){for(let _0x3db2c3=0x0;_0x3db2c3<_0x1468a5['length'];_0x3db2c3++)for(const [_0x2256a3,_0x5e4845]of _0x49146c)!_0x5e4845['isCollapsed']&&_0x5e4845['start']['isEqual'](_0x1468a5[_0x3db2c3]['previousPosition'])&&_0x1468a5[_0x3db2c3]['markersStart']['push'](_0x2256a3),_0x5e4845['end']['isEqual'](_0x1468a5[_0x3db2c3]['nextPosition'])&&_0x1468a5[_0x3db2c3]['markersEnd']['push'](_0x2256a3);}['_joinTapes'](_0x5037db,_0x5e9a5c){let _0x280aa8=[],_0x5e1954=0x0,_0xd27869=0x0;for(;_0x5e1954<_0x5037db['length']||_0xd27869<_0x5e9a5c['length'];){const _0xa4ec85=_0x5037db[_0x5e1954]||{},_0x1f23bc=_0x5e9a5c[_0xd27869]||{};if(_0xa4ec85['id']==_0x1f23bc['id'])_0x5e1954++,_0xd27869++,_0x280aa8['push'](_0xa4ec85);else{if(_0x1f23bc['isRemoved']&&_0xa4ec85['isAdded']){const {commonTape:_0x13afdd,iEnd:_0xd27a06,jEnd:_0x263395}=this['_threeWayMerge'](_0x5037db,_0x5e1954,_0x5e9a5c,_0xd27869);_0x280aa8=_0x280aa8['concat'](_0x13afdd),_0x5e1954=_0xd27a06,_0xd27869=_0x263395;}else _0x1f23bc['isRemoved']?(_0xd27869++,_0x280aa8['push'](_0x1f23bc)):(_0x5e1954++,_0x280aa8['push'](_0xa4ec85));}}return _0x280aa8;}['_markSuggestions'](_0x277f9b,_0x47bf89){const _0x198514=[];for(let _0x5d6a3b=0x0;_0x5d6a3b<_0x277f9b['length'];_0x5d6a3b++){for(let _0x1cc03a=0x0;_0x1cc03a<_0x277f9b[_0x5d6a3b]['markersStart']['length'];_0x1cc03a++){const _0x2ee5b8=_0x277f9b[_0x5d6a3b]['markersStart'][_0x1cc03a];if(!_0x47bf89['has'](_0x2ee5b8))continue;const {group:_0x34dd80,type:_0x652bcb,authorId:_0x5bf87d}=_0x5655b3(_0x2ee5b8);'revision-suggestion'!=_0x34dd80||'insertion'!=_0x652bcb&&'deletion'!=_0x652bcb||(_0x198514['unshift']({'type':_0x652bcb,'name':_0x2ee5b8,'userId':_0x5bf87d}),_0x277f9b[_0x5d6a3b]['markersStart']['splice'](_0x1cc03a,0x1),_0x1cc03a--);}_0x55b51b(_0x277f9b[_0x5d6a3b]);for(let _0x19d849=0x0;_0x19d849<_0x277f9b[_0x5d6a3b]['markersEnd']['length'];_0x19d849++){const _0x9fbcf1=_0x277f9b[_0x5d6a3b]['markersEnd'][_0x19d849];if(!_0x47bf89['has'](_0x9fbcf1))continue;const {group:_0x127cc1,type:_0x297969}=_0x5655b3(_0x9fbcf1);if('revision-suggestion'!=_0x127cc1||'insertion'!=_0x297969&&'deletion'!=_0x297969)continue;_0x277f9b[_0x5d6a3b]['markersEnd']['splice'](_0x19d849,0x1),_0x19d849--;const _0x1b551c=_0x198514['findIndex'](_0x1c4c10=>_0x1c4c10['name']==_0x9fbcf1);_0x1b551c>-0x1&&_0x198514['splice'](_0x1b551c,0x1);}}function _0x5655b3(_0x4254c3){const _0xe72989=_0x4254c3['split'](':');return{'group':_0xe72989[0x0],'type':_0xe72989[0x1],'subType':_0xe72989['length']>=0x5?_0xe72989[0x2]:null,'id':_0xe72989['length']<0x5?_0xe72989[0x2]:_0xe72989[0x3],'authorId':_0xe72989['length']<0x5?_0xe72989[0x3]:_0xe72989[0x4],'markerCount':0x6==_0xe72989['length']?_0xe72989[0x5]:null};}function _0x55b51b(_0x1e4ee2){for(let _0x90c871=0x0;_0x90c871<_0x198514['length'];_0x90c871++){if(_0x1e4ee2['isAdded']&&'insertion'==_0x198514[_0x90c871]['type'])return _0x1e4ee2['isAddSuggestion']=_0x198514[_0x90c871],void delete _0x1e4ee2['isAdded'];if(!_0x1e4ee2['isAdded']&&!_0x1e4ee2['isRemoved']&&'deletion'==_0x198514[_0x90c871]['type'])return void(_0x1e4ee2['isRemoveSuggestion']=_0x198514[_0x90c871]);}}}['_setDistance'](_0x9542b7,_0xb04dba){let _0x4bf894=0x0,_0x2d045f=!0x1;const _0x5b5ce2=new Map();for(const _0x5761bc of _0x9542b7)_0x5761bc[_0xb04dba]?_0x2d045f&&(_0x4bf894++,_0x2d045f=!0x1):(_0x4bf894++,_0x2d045f=!0x0),_0x5b5ce2['set'](_0x5761bc['id'],_0x4bf894);for(let _0xb7c195=0x0;_0xb7c195<_0x9542b7['length'];_0xb7c195++){if('isRemoved'==_0xb04dba&&_0x9542b7[_0xb7c195]['isAdded']||'isAdded'==_0xb04dba&&_0x9542b7[_0xb7c195]['isRemoved'])continue;if('text'==_0x9542b7[_0xb7c195]['type']){_0x9542b7[_0xb7c195]['distance']=0x0;continue;}const _0x346dfc=_0x5b5ce2['get'](_0x9542b7[_0xb7c195]['pairId']),_0x2ca361=_0x5b5ce2['get'](_0x9542b7[_0xb7c195]['id']);_0x9542b7[_0xb7c195]['distance']=_0x346dfc-_0x2ca361;}}['_getRevisionsRange'](_0x5e88da,_0x5e966a,_0x464190=!0x1){const _0x4839ce=[];let _0x1387af=this['repository']['getIndex'](_0x5e88da),_0x2c9ff1=this['repository']['getIndex'](_0x5e966a);for(-0x1==_0x2c9ff1&&(_0x2c9ff1=this['repository']['_revisions']['length'],_0x464190=!0x1);_0x1387af<_0x2c9ff1;)_0x4839ce['push'](this['repository']['getRevision'](_0x1387af)),_0x1387af++;return _0x464190&&_0x4839ce['push'](this['repository']['getRevision'](_0x1387af)),_0x4839ce;}['_threeWayMerge'](_0x4847c4,_0x395594,_0x39da08,_0x2e0239){const _0x18efee=this['editor']['model']['schema'];let _0x47c013=_0x395594;for(;_0x4847c4[_0x47c013]&&_0x4847c4[_0x47c013]['isAdded'];)_0x47c013++;let _0x228614=_0x2e0239;for(;_0x39da08[_0x228614]&&_0x39da08[_0x228614]['isRemoved'];)_0x228614++;_0x7ff3ae(_0x4847c4,_0x395594,_0x47c013),_0x7ff3ae(_0x39da08,_0x2e0239,_0x228614);const _0x47c286=_0x39da08['slice'](_0x2e0239,_0x228614)['concat'](_0x4847c4['slice'](_0x395594,_0x47c013));return _0x47c286['sort']((_0x1f4e4a,_0x449b74)=>_0x1f4e4a['side']!=_0x449b74['side']?_0x1f4e4a['side']-_0x449b74['side']:_0x1f4e4a['level']!=_0x449b74['level']?_0x1f4e4a['level']-_0x449b74['level']:_0x1f4e4a['distance']!=_0x449b74['distance']?_0x449b74['distance']-_0x1f4e4a['distance']:!!_0x1f4e4a['isAdded']!=!!_0x449b74['isAdded']?-0x1==_0x1f4e4a['side']||0x0==_0x1f4e4a['side']?_0x1f4e4a['isAdded']?-0x1:0x1:_0x1f4e4a['isAdded']?0x1:-0x1:_0x1f4e4a['index']-_0x449b74['index']),{'commonTape':_0x47c286,'iEnd':_0x47c013,'jEnd':_0x228614};function _0x7ff3ae(_0x34b949,_0x3d313b,_0x26b072){let _0x4e4573=-0x1,_0x55ba00=Number['POSITIVE_INFINITY'],_0x11c89e=!0x0;for(let _0x2d289c=_0x3d313b;_0x2d289c<_0x26b072;_0x2d289c++)if(_0x18efee['isInline'](_0x34b949[_0x2d289c]['item'])||(_0x11c89e=!0x1),_0x34b949[_0x2d289c]['item']['startIndex']<_0x3d313b&&(_0x4e4573=_0x2d289c),_0x34b949[_0x2d289c]['item']['endIndex']>=_0x26b072){_0x55ba00=_0x2d289c;break;}_0x11c89e&&(_0x4e4573=_0x26b072-0x1);for(let _0x26cbc5=_0x3d313b;_0x26cbc5<_0x26b072;_0x26cbc5++)_0x34b949[_0x26cbc5]['side']=_0x26cbc5<=_0x4e4573?-0x1:_0x26cbc5<_0x55ba00?0x0:0x1,_0x34b949[_0x26cbc5]['index']=_0x26cbc5;let _0x2633c5=0x0;for(let _0x4fb02d=_0x3d313b;_0x4fb02d<=_0x4e4573;_0x4fb02d++)0x0==_0x34b949[_0x4fb02d]['distance']?_0x34b949[_0x4fb02d]['level']=_0x2633c5:(_0x2633c5++,_0x34b949[_0x4fb02d]['level']=_0x2633c5,_0x2633c5++);for(let _0x1e73ef=_0x3d313b;_0x1e73ef<_0x26b072;_0x1e73ef++)0x0==_0x34b949[_0x1e73ef]['side']&&(_0x34b949[_0x1e73ef]['level']=_0x2633c5);_0x2633c5=0x0;for(let _0x1a4c66=_0x26b072-0x1;_0x1a4c66>=_0x55ba00;_0x1a4c66--)0x0==_0x34b949[_0x1a4c66]['distance']?_0x34b949[_0x1a4c66]['level']=_0x2633c5:(_0x2633c5--,_0x34b949[_0x1a4c66]['level']=_0x2633c5,_0x2633c5--);}}['_fixObsoleteTags'](_0xb6ad90){const _0x244a79=new Map(),_0x4858c9=this['editor']['model']['schema'];for(let _0x5ce53b=0x1;_0x5ce53b<_0xb6ad90['length'];_0x5ce53b++){let _0x600e39,_0xad19b0,_0x1f49f6;const _0x55ffa3=_0xb6ad90[_0x5ce53b],_0x11d1d4=_0xb6ad90[_0x5ce53b-0x1];if('text'==_0x55ffa3['type'])continue;if(_0x55ffa3['type']!=_0x11d1d4['type'])continue;if(!_0x4858c9['isBlock'](_0x11d1d4['item'])||_0x4858c9['isLimit'](_0x11d1d4['item']))continue;if(!_0x4858c9['isBlock'](_0x55ffa3['item'])||_0x4858c9['isLimit'](_0x55ffa3['item']))continue;if((_0xb6ad90[_0x5ce53b]['isAdded']||_0xb6ad90[_0x5ce53b]['isAddSuggestion'])&&_0xb6ad90[_0x5ce53b-0x1]['isRemoved'])_0x600e39=_0xb6ad90[_0x5ce53b],_0xad19b0=_0xb6ad90[_0x5ce53b-0x1],_0x1f49f6=_0x5ce53b-0x1;else{if(!_0xb6ad90[_0x5ce53b]['isRemoved']||!_0xb6ad90[_0x5ce53b-0x1]['isAdded']&&!_0xb6ad90[_0x5ce53b-0x1]['isAddSuggestion'])continue;_0x600e39=_0xb6ad90[_0x5ce53b-0x1],_0xad19b0=_0xb6ad90[_0x5ce53b],_0x1f49f6=_0x5ce53b;}const _0x18192e=_0x600e39['level']==_0xad19b0['level'],_0x527312=Math['abs'](_0x600e39['level'])<Math['abs'](_0xad19b0['level'])&&0x0==_0xad19b0['distance'];(_0x18192e||_0x527312)&&(_0x244a79['set'](_0xad19b0['id'],_0x600e39['id']),_0xb6ad90['splice'](_0x1f49f6,0x1),_0x5ce53b--,_0x600e39['isAdded']=!0x1);}for(let _0x43cab4=0x0;_0x43cab4<_0xb6ad90['length'];_0x43cab4++)_0x244a79['has'](_0xb6ad90[_0x43cab4]['pairId'])&&(_0xb6ad90[_0x43cab4]['pairId']=_0x244a79['get'](_0xb6ad90[_0x43cab4]['pairId']));}['_removeMissingPairs'](_0x342ba3){const _0x256a15=new Set(_0x342ba3['map'](_0x5f2a87=>_0x5f2a87['id']));for(let _0x464805=0x0;_0x464805<_0x342ba3['length'];_0x464805++)_0x256a15['has'](_0x342ba3[_0x464805]['pairId'])||0x0==_0x342ba3[_0x464805]['distance']||(_0x342ba3[_0x464805]['isIncorrect']=!0x0);return _0x342ba3['filter'](_0x33529e=>!_0x33529e['isIncorrect']);}['_markMismatchedRemovedTags'](_0x3d56f3){const _0x32f81a=new Set();for(let _0x406e56=0x0;_0x406e56<_0x3d56f3['length'];_0x406e56++){if(_0x32f81a['has'](_0x3d56f3[_0x406e56]['id'])&&_0x3d56f3[_0x406e56]['isRemoved']&&(_0x3d56f3[_0x406e56]['isIncorrect']=!0x0),_0x3d56f3[_0x406e56]['isIncorrect'])continue;if(0x0==_0x3d56f3[_0x406e56]['distance'])continue;if('elementStart'!=_0x3d56f3[_0x406e56]['type'])continue;if(null==_0x3d56f3[_0x406e56]['pairId'])continue;let _0x1a9a8f=_0x406e56+0x1,_0x30b2b0=0x0;for(;_0x3d56f3[_0x1a9a8f]['id']!=_0x3d56f3[_0x406e56]['pairId'];)'elementStart'==_0x3d56f3[_0x1a9a8f]['type']?_0x30b2b0++:'elementEnd'==_0x3d56f3[_0x1a9a8f]['type']&&_0x30b2b0--,_0x1a9a8f++;if(0x0!=_0x30b2b0){if(_0x3d56f3[_0x406e56]['isRemoved'])_0x3d56f3[_0x406e56]['isIncorrect']=!0x0;else{for(;_0x1a9a8f!=_0x406e56;)_0x3d56f3[_0x1a9a8f]['isRemoved']&&0x0!=_0x3d56f3[_0x1a9a8f]['distance']&&(_0x3d56f3[_0x1a9a8f]['isIncorrect']=!0x0,_0x32f81a['add'](_0x3d56f3[_0x1a9a8f]['pairId'])),_0x1a9a8f--;}}}return _0x3d56f3['filter'](_0x2752f1=>!_0x2752f1['isIncorrect']);}['_removeUnsupportedChanges'](_0x239ffe){const _0x37c986=this['editor']['model']['schema'];for(let _0x3a54a9=0x0;_0x3a54a9<_0x239ffe['length'];_0x3a54a9++){if(!(_0x239ffe[_0x3a54a9]['isAdded']||_0x239ffe[_0x3a54a9]['isAddSuggestion']||_0x239ffe[_0x3a54a9]['isRemoved']||_0x239ffe[_0x3a54a9]['isRemoveSuggestion']))continue;if(0x0==_0x239ffe[_0x3a54a9]['distance'])continue;const _0x365ca4=_0x239ffe[_0x3a54a9]['item'];_0x37c986['isBlock'](_0x365ca4)||_0x37c986['isLimit'](_0x365ca4)||(_0x239ffe[_0x3a54a9]['isAdded']&&delete _0x239ffe[_0x3a54a9]['isAdded'],_0x239ffe[_0x3a54a9]['isAddSuggestion']&&delete _0x239ffe[_0x3a54a9]['isAddSuggestion'],_0x239ffe[_0x3a54a9]['isRemoveSuggestion']&&delete _0x239ffe[_0x3a54a9]['isRemoveSuggestion'],_0x239ffe[_0x3a54a9]['isRemoved']&&(_0x239ffe[_0x3a54a9]['isIncorrect']=!0x0));}return _0x239ffe['filter'](_0x201f80=>!_0x201f80['isIncorrect']);}['_makeModelFromTape'](_0x37ea90,_0x1a47a8,_0x5c46c7){const _0x5cd9a2=new vt(),_0x82b986=[],_0x3667eb=new Map(),_0x10dcd3=this['editor']['model'],_0x206739=_0x10dcd3['schema'],_0x1c48fa=[_0x5cd9a2],_0x113d5f={},_0xf90ebc={'isAdded':[],'isRemoved':[],'isAddSuggestion':[],'isRemoveSuggestion':[]};let _0x466087=null;const _0x5399e9=[0x0];for(let _0x5aae9e=0x0;_0x5aae9e<_0x37ea90['length'];_0x5aae9e++)if('elementStart'===_0x37ea90[_0x5aae9e]['type']){_0x37ea90[_0x5aae9e]['previousPosition']=_0x10dcd3['createPositionFromPath'](_0x5cd9a2,_0x5399e9);const _0x4b86fc=new ut(_0x37ea90[_0x5aae9e]['item']['name'],_0x37ea90[_0x5aae9e]['item']['getAttributes']());_0x1c48fa[0x0]['_appendChild'](_0x4b86fc),_0x5399e9['push'](0x0),_0x1c48fa['unshift'](_0x4b86fc),_0x37ea90[_0x5aae9e]['nextPosition']=_0x10dcd3['createPositionFromPath'](_0x5cd9a2,_0x5399e9);}else'elementEnd'===_0x37ea90[_0x5aae9e]['type']?(_0x1c48fa['shift'](),_0x37ea90[_0x5aae9e]['previousPosition']=_0x10dcd3['createPositionFromPath'](_0x5cd9a2,_0x5399e9),_0x5399e9['pop'](),_0x5399e9[_0x5399e9['length']-0x1]++,_0x37ea90[_0x5aae9e]['nextPosition']=_0x10dcd3['createPositionFromPath'](_0x5cd9a2,_0x5399e9)):(_0x37ea90[_0x5aae9e]['previousPosition']=_0x10dcd3['createPositionFromPath'](_0x5cd9a2,_0x5399e9),_0x466087?_0x466087['_data']+=_0x37ea90[_0x5aae9e]['item']['data']:_0x466087=new gt(_0x37ea90[_0x5aae9e]['item']['data'],_0x37ea90[_0x5aae9e]['item']['getAttributes']()),_0x37ea90[_0x5aae9e+0x1]&&'text'===_0x37ea90[_0x5aae9e+0x1]['type']&&_0x2a9e66(_0x466087,_0x37ea90[_0x5aae9e+0x1]['item'])||(_0x1c48fa[0x0]['_appendChild'](_0x466087),_0x466087=null),_0x5399e9[_0x5399e9['length']-0x1]+=_0x37ea90[_0x5aae9e]['item']['offsetSize'],_0x37ea90[_0x5aae9e]['nextPosition']=_0x10dcd3['createPositionFromPath'](_0x5cd9a2,_0x5399e9));for(let _0x5abf0b=0x0;_0x5abf0b<_0x37ea90['length'];_0x5abf0b++){const _0x324513=_0x37ea90[_0x5abf0b]['previousPosition'],_0x94a945=_0x37ea90[_0x5abf0b]['nextPosition'];for(const _0x540336 of _0x37ea90[_0x5abf0b]['markersStart'])_0x3667eb['set'](_0x540336,{'start':_0x324513,'end':null});_0x18e9c4('isRemoveSuggestion',_0x5abf0b,_0x324513,_0x94a945),_0x18e9c4('isAddSuggestion',_0x5abf0b,_0x324513,_0x94a945),_0x18e9c4('isRemoved',_0x5abf0b,_0x324513,_0x94a945),_0x18e9c4('isAdded',_0x5abf0b,_0x324513,_0x94a945);for(const _0x570079 of _0x37ea90[_0x5abf0b]['markersEnd']){const _0x2a63e0=_0x3667eb['get'](_0x570079);_0x2a63e0?_0x2a63e0['end']=_0x94a945:_0x3667eb['set'](_0x570079,{'start':_0x94a945,'end':_0x94a945});}}for(const [_0x33c0f5,_0x373c11]of _0x3667eb){const _0x4a2dd4=this['editor']['model']['createRange'](_0x373c11['start'],_0x373c11['end']);_0x5cd9a2['markers']['set'](_0x33c0f5,_0x4a2dd4);}return _0x82b986['sort']((_0x52bad1,_0x1caf35)=>{const _0x337f39=_0x5cd9a2['markers']['get']('revision:'+_0x52bad1['id']),_0x236b26=_0x5cd9a2['markers']['get']('revision:'+_0x1caf35['id']);return _0x337f39['start']['isBefore'](_0x236b26['start'])?-0x1:_0x337f39['start']['isAfter'](_0x236b26['start'])?0x1:_0x337f39['end']['isBefore'](_0x236b26['end'])?-0x1:_0x337f39['end']['isAfter'](_0x236b26['end'])?0x1:'add'===_0x52bad1['type']?-0x1:0x1;}),{'root':_0x5cd9a2,'changes':_0x82b986};function _0x18e9c4(_0x269b3e,_0x4b40c4,_0x396fc1,_0x41ee96){const _0x2a3695=!!_0x37ea90[_0x4b40c4][_0x269b3e],_0x238472=_0x2a3695?_0x37ea90[_0x4b40c4][_0x269b3e]['userId']:null,_0x5af510=_0x4b40c4===_0x37ea90['length']-0x1,_0x4c6b11=_0xf90ebc[_0x269b3e][0x0],_0x375854=_0x206739['isObject'](_0x37ea90[_0x4b40c4]['item']);!_0x113d5f[_0x269b3e]&&_0x2a3695?_0x113d5f[_0x269b3e]={'start':_0x396fc1,'tapeItem':_0x37ea90[_0x4b40c4],'userId':_0x238472,'type':_0x269b3e}:_0x113d5f[_0x269b3e]&&!_0x2a3695?(_0x113d5f[_0x269b3e]['end']=_0x396fc1,_0x5899db(_0x113d5f[_0x269b3e]),_0x113d5f[_0x269b3e]=null):_0x113d5f[_0x269b3e]&&_0x2a3695&&_0x113d5f[_0x269b3e]['userId']!==_0x238472&&(_0x113d5f[_0x269b3e]['end']=_0x396fc1,_0x4c6b11&&_0x4c6b11['userId']===_0x113d5f[_0x269b3e]['userId']||_0x5899db(_0x113d5f[_0x269b3e]),_0x113d5f[_0x269b3e]={'start':_0x396fc1,'tapeItem':_0x37ea90[_0x4b40c4],'userId':_0x238472,'type':_0x269b3e}),_0x113d5f[_0x269b3e]&&_0x375854&&('elementStart'!==_0x37ea90[_0x4b40c4]['type']||_0x4c6b11&&_0x4c6b11['userId']===_0x238472||_0xf90ebc[_0x269b3e]['unshift']({'userId':_0x238472,'object':_0x37ea90[_0x4b40c4]['item'],'change':_0x113d5f[_0x269b3e]}),'elementEnd'===_0x37ea90[_0x4b40c4]['type']&&_0x4c6b11&&_0x4c6b11['object']===_0x37ea90[_0x4b40c4]['item']&&(_0xf90ebc[_0x269b3e]['shift'](),_0x113d5f[_0x269b3e]=_0x4c6b11['change'])),_0x113d5f[_0x269b3e]&&_0x5af510&&(_0x113d5f[_0x269b3e]['end']=_0x41ee96,_0x5899db(_0x113d5f[_0x269b3e]),_0x113d5f[_0x269b3e]=null);}function _0x5899db({start:_0x58243b,end:_0x59f6b2,tapeItem:_0x5e6da2,userId:_0x254ece,type:_0x21ba89}){const _0x4a7831=_0x5e6da2['item'],_0x50e784=_0x10dcd3['schema']['isBlock'](_0x4a7831)&&!_0x10dcd3['schema']['isLimit'](_0x4a7831),_0x1dc322=_0x58243b['nodeAfter']==_0x59f6b2['parent']&&_0x59f6b2['isAtStart'];if(_0x50e784&&_0x1dc322)return;const _0x58908e=_0x10dcd3['createRange'](_0x58243b,_0x59f6b2),_0x41d8de=_0x1a47a8['get'](_0x254ece),_0x53ecb3=new r({'author':_0x41d8de,'type':'isAdded'==_0x21ba89||'isAddSuggestion'==_0x21ba89?'add':'remove','data':{'isSuggestion':'isAddSuggestion'==_0x21ba89||'isRemoveSuggestion'==_0x21ba89},'createdAt':new Date(),'rootName':_0x5c46c7});_0x82b986['push'](_0x53ecb3),_0x5cd9a2['markers']['set']('revision:'+_0x53ecb3['id'],_0x58908e);}function _0x2a9e66(_0x282c53,_0x10bf63){const _0x57109e=_0x282c53['getAttributes'](),_0x390368=_0x10bf63['getAttributes']();for(const _0x18ca9b of _0x57109e){if(_0x18ca9b[0x1]!==_0x10bf63['getAttribute'](_0x18ca9b[0x0]))return!0x1;_0x390368['next']();}return _0x390368['next']()['done'];}}['_setConversion'](){this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision','view':_0x31f81a=>{const _0x3dc948=_0x31f81a['markerName']['split'](':')[0x1],_0x251e01=this['_getChangeFromId'](_0x3dc948);if(!_0x251e01)return null;const _0x55c873='add'==_0x251e01['type']?'insertion':'deletion',_0x47eb62=['ck-suggestion-marker','ck-suggestion-marker-'+_0x55c873];return _0x251e01['data']['isSuggestion']&&_0x47eb62['push']('ck-suggestion-marker-'+_0x55c873+'-new'),this['activeChange']==_0x251e01&&_0x47eb62['push']('ck-suggestion-marker--active'),{'classes':_0x47eb62,'attributes':{'data-change-id':_0x3dc948}};}}),this['editor']['conversion']['for']('upcast')['add'](_0x391f9f=>{_0x391f9f['on']('element:pre',(_0xd160f7,_0x1fc00b,_0x16e90a)=>{const _0x446d02=_0x1fc00b['viewItem']['getChild'](0x0);if(!_0x446d02||!_0x446d02['is']('element','code'))return;if(!_0x16e90a['consumable']['consume'](_0x446d02,{'attributes':['vid_start','vid_end']}))return;const _0x15b785=_0x1fc00b['modelRange']['start']['nodeAfter'];_0x16e90a['writer']['setAttribute']('vid_start',_0x446d02['getAttribute']('vid_start'),_0x15b785),_0x16e90a['writer']['setAttribute']('vid_end',_0x446d02['getAttribute']('vid_end'),_0x15b785);},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['add'](_0x33c033=>{_0x33c033['on']('element',(_0x2dbf55,_0x322e3a,_0x1a13f0)=>{if(!_0x1a13f0['consumable']['consume'](_0x322e3a['viewItem'],{'attributes':['vid_start','vid_end']}))return;if(_0x322e3a['modelRange']['isCollapsed'])return;const _0x51e728=_0x322e3a['modelRange']['start']['nodeAfter'];_0x51e728['hasAttribute']('vid_start')||_0x51e728['hasAttribute']('vid')||(_0x1a13f0['writer']['setAttribute']('vid_start',_0x322e3a['viewItem']['getAttribute']('vid_start'),_0x51e728),_0x1a13f0['writer']['setAttribute']('vid_end',_0x322e3a['viewItem']['getAttribute']('vid_end'),_0x51e728));},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['elementToAttribute']({'view':{'name':'span','attributes':{'vid':!0x0}},'model':{'key':'vid','value':_0x2058ea=>_0x2058ea['getAttribute']('vid')}}),this['editor']['model']['schema']['on']('checkAttribute',(_0x4cebfc,[,_0x408deb])=>{['vid_start','vid_end','vid']['includes'](_0x408deb)&&(_0x4cebfc['return']=!0x0,_0x4cebfc['stop']());},{'priority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x27ac04=>{_0x27ac04['on']('attribute:vid',(_0x3d60c9,_0x8406a9,_0x15d7a4)=>{if('\x20'!=_0x8406a9['item']['data']||_0x8406a9['item']['parent']['maxOffset']>0x1)return;if(!_0x15d7a4['consumable']['consume'](_0x8406a9['item'],_0x3d60c9['name']))return;const _0x15d895=_0x15d7a4['writer'],_0x3359e9=_0x15d7a4['mapper']['toViewRange'](_0x8406a9['range']);_0x15d895['wrap'](_0x3359e9,_0x15d895['createAttributeElement']('span'));});}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',function(_0x426ceb){const _0x5912f0=_0x426ceb['plugins']['get']('RevisionViewer');return(_0x3e1b1c,_0x979899,_0x4429ec)=>{const _0x43e6d8=_0x979899['markerName']['split'](':')[0x1],_0x15af5a=_0x5912f0['_getChangeFromId'](_0x43e6d8);if(!_0x15af5a)return null;const _0xdb6807='add'==_0x15af5a['type']?'split':'merge';if(!_0x4429ec['consumable']['test'](_0x979899['markerRange'],_0x3e1b1c['name']))return;const _0x3ad1c4=_0x979899['markerRange']['getWalker'](),_0x3fa402=_0x979899['markerRange']['start'],_0x1eb02a=_0x426ceb['model']['schema'];let _0x56f287=null,_0xf4bd57=null,_0x39e551=!0x1,_0x944709=!0x1;for(const _0x40c01a of _0x3ad1c4){const _0x3058e6=_0x40c01a['item'];_0x39e551=_0x39e551||_0x1eb02a['isContent'](_0x3058e6);const _0x40530e=_0x4429ec['mapper']['toViewElement'](_0x3058e6);if(_0x40530e&&_0x40530e['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x40c01a['type']&&(_0x1eb02a['isBlock'](_0x3058e6)&&!_0x1eb02a['isLimit'](_0x3058e6)&&(_0x3058e6['nextSibling']||_0x3fa402['isAtEnd']?_0x56f287&&_0x56f287['parent']==_0x3058e6||(_0x56f287=_0x3058e6,_0x587040(_0x40c01a['previousPosition']),_0x944709=!0x0):_0xf4bd57=_0xf4bd57||_0x40c01a['previousPosition']));}function _0x587040(_0x17acb5){const _0x3fc307=_0x4429ec['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0xdb6807}),_0x5eb475=_0x4429ec['mapper']['toViewPosition'](_0x17acb5);_0x15af5a['data']['isSuggestion']&&_0x4429ec['writer']['addClass']('ck-suggestion-marker-'+_0xdb6807+'-new',_0x3fc307),_0x5912f0['activeChange']==_0x15af5a&&_0x4429ec['writer']['addClass']('ck-suggestion-marker--active',_0x3fc307),_0x4429ec['writer']['insert'](_0x5eb475,_0x3fc307),_0x4429ec['mapper']['bindElementToMarker'](_0x3fc307,_0x979899['markerName']);}_0x39e551||_0x944709||!_0xf4bd57||_0x587040(_0xf4bd57);};}(this['editor']),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision',(_0x4376fb,_0x55b8fe,_0x48549e)=>{const _0x34a320=_0x48549e['mapper']['markerNameToElements'](_0x55b8fe['markerName']);if(_0x34a320){for(const _0x12721b of _0x34a320)(_0x12721b['hasClass']('ck-suggestion-marker-split')||_0x12721b['hasClass']('ck-suggestion-marker-merge'))&&(_0x48549e['mapper']['unbindElementFromMarkerName'](_0x12721b,_0x55b8fe['markerName']),_0x48549e['writer']['remove'](_0x12721b));}},{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',(_0x114ba2,_0x5c7dfd,_0x4eecf3)=>{const _0x222c45=_0x5c7dfd['markerName']['split'](':')[0x1],_0x4fac09=this['_getChangeFromId'](_0x222c45);if(!_0x4fac09)return null;const _0x343d1e='add'==_0x4fac09['type']?'split':'merge';if(_0x4eecf3['consumable']['test'](_0x5c7dfd['markerRange'],_0x114ba2['name']))for(const _0x95efa4 of _0x5c7dfd['markerRange']['getItems']()){if(!_0x95efa4['is']('element','softBreak'))continue;const _0x3cc952=_0x4eecf3['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x343d1e}),_0x2d3298=_0x4eecf3['mapper']['toViewPosition'](this['editor']['model']['createPositionBefore'](_0x95efa4));_0x4fac09['data']['isSuggestion']&&_0x4eecf3['writer']['addClass']('ck-suggestion-marker-'+_0x343d1e+'-new',_0x3cc952),this['activeChange']==_0x4fac09&&_0x4eecf3['writer']['addClass']('ck-suggestion-marker--active',_0x3cc952),_0x4eecf3['writer']['insert'](_0x2d3298,_0x3cc952),_0x4eecf3['mapper']['bindElementToMarker'](_0x3cc952,_0x5c7dfd['markerName']);}},{'priority':'high'}),this['editor']['model']['document']['on']('change',()=>{this['editor']['editing']['view']['change'](_0x31b3fc=>{for(const _0x32872a of this['editor']['model']['document']['getRootNames']()){const _0x37e8ef=this['editor']['model']['document']['getRoot'](_0x32872a),_0x5b8a3b=this['editor']['editing']['view']['document']['getRoot'](_0x32872a);if(_0x5b8a3b){const _0x46e241=_0x37e8ef['getAttribute']('revisionHistoryAttachChange');if(_0x31b3fc['removeAttribute']('data-change-id',_0x5b8a3b),_0x31b3fc['removeClass']('ck-revision-history-root-add',_0x5b8a3b),_0x31b3fc['removeClass']('ck-revision-history-root-remove',_0x5b8a3b),_0x31b3fc['removeClass']('ck-revision-history-root--active',_0x5b8a3b),_0x46e241){const _0x1c0102=this['_getChangeFromId'](_0x46e241);if(!_0x1c0102)return null;_0x31b3fc['setAttribute']('data-change-id',_0x46e241,_0x5b8a3b),_0x31b3fc['addClass']('ck-revision-history-root-'+_0x1c0102['type'],_0x5b8a3b),this['activeChange']==_0x1c0102&&_0x31b3fc['addClass']('ck-revision-history-root--active',_0x5b8a3b);}}}});}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'comment','model':_0x1d9192=>'revision-comment:'+_0x1d9192,'converterPriority':'highest'}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'suggestion','model':_0x53766d=>'revision-suggestion:'+_0x53766d,'converterPriority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision-suggestion','view':_0x2f9459=>({'name':'suggestion:'+_0x2f9459,'group':'revision-suggestion'}),'converterPriority':'highest'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision-suggestion','view':_0x2e9ebf=>{const _0x5edc1d=_0x2e9ebf['markerName']['split'](':')[0x1];return'insertion'!=_0x5edc1d&&'deletion'!=_0x5edc1d?null:{'classes':['ck-suggestion-preview-marker','ck-suggestion-preview-marker-'+_0x5edc1d]};}}),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',(_0x4d3297,_0x3c220a,_0x59a23c)=>{const _0x30b8ba=_0x59a23c['mapper']['markerNameToElements'](_0x3c220a['markerName']);if(_0x30b8ba){for(const _0x58ed7e of _0x30b8ba)_0x58ed7e['is']('uiElement')&&(_0x59a23c['mapper']['unbindElementFromMarkerName'](_0x58ed7e,_0x3c220a['markerName']),_0x59a23c['writer']['remove'](_0x58ed7e));}},{'priority':'high'});}['_getChangeFromId'](_0x361e03){return this['_changeIdToChange']['get'](_0x361e03);}['_getViewForChange'](_0x51af90){return this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=new Q(this['editor']['locale'],_0x51af90),this['_changeView'];}['_initInteractions'](){this['editor']['model']['document']['selection']['observeMarkers']('revision'),this['on']('change:activeView',(_0x160778,_0x3cf478,_0x35cad6,_0xa54c46)=>{_0xa54c46&&this['_balloon']['remove'](_0xa54c46),_0x35cad6&&(this['_balloon']['add']({'view':_0x35cad6,'stackId':'revisionHistoryLabel','position':{'target':()=>{const _0x5f2c9d=this['editor']['editing'],_0x334f63=this['_getChangeFromId'](_0x35cad6['changeId']);let _0x9ec5b0;if(_0x334f63['data']['isOnRoot']){const _0x104e76=_0x5f2c9d['view']['getDomRoot'](_0x334f63['rootName']);_0x9ec5b0=Array['from'](_0x104e76['getClientRects']());}else{const _0x315257=this['editor']['model']['markers']['get']('revision:'+_0x35cad6['changeId']);_0x9ec5b0=Array['from'](_0x5f2c9d['mapper']['markerNameToElements'](_0x315257['name']))['map'](_0x1adb0c=>_0x5f2c9d['view']['domConverter']['mapViewToDom'](_0x1adb0c))['map'](_0x5eeb0f=>Array['from'](_0x5eeb0f['getClientRects']()))['flat']();}if(!this['_activeViewTarget'])return _0x9ec5b0[0x0];return _0x9ec5b0['find'](_0x4bcb0c=>_0x4bcb0c['top']-0x3<=this['_activeViewTarget']['y']&&_0x4bcb0c['bottom']+0x3>=this['_activeViewTarget']['y']&&_0x4bcb0c['left']-0x3<=this['_activeViewTarget']['x']&&_0x4bcb0c['right']+0x3>=this['_activeViewTarget']['x'])||_0x9ec5b0[0x0];}}}),this['_balloon']['showStack']('revisionHistoryLabel'));}),this['on']('change:activeChange',(_0x12179b,_0x3d1aa9,_0x47fa00,_0x44099d)=>{this['activeView']=_0x47fa00?this['_getViewForChange'](_0x47fa00):null,this['editor']['model']['change'](()=>{const _0x3554d3=this['editor']['editing'];_0x44099d&&(_0x44099d['data']['isOnRoot']?_0x3554d3['view']['change'](_0x21f997=>{_0x21f997['removeClass']('ck-revision-history-root--active',_0x3554d3['view']['document']['getRoot'](_0x44099d['rootName']));}):_0x3554d3['reconvertMarker']('revision:'+_0x44099d['id'])),_0x47fa00&&(_0x47fa00['data']['isOnRoot']?_0x3554d3['view']['change'](_0x51d479=>{_0x51d479['addClass']('ck-revision-history-root--active',_0x3554d3['view']['document']['getRoot'](_0x47fa00['rootName']));}):_0x3554d3['reconvertMarker']('revision:'+_0x47fa00['id']));});}),this['listenTo'](this['editor']['editing']['view']['document'],'mouseover',(_0x350e3f,_0x30e265)=>{if(this['activeChange'])return;const _0x23aced=this['_findChangeIdFromDomTarget'](_0x30e265['target']),_0x218af2=this['_changeIdToChange']['get'](_0x23aced);_0x218af2?(this['_activeViewTarget']={'x':_0x30e265['domEvent']['x'],'y':_0x30e265['domEvent']['y']},this['activeView']=this['_getViewForChange'](_0x218af2)):(this['_activeViewTarget']=null,this['activeView']=null);}),this['listenTo'](this['editor']['editing']['view']['document'],'mousedown',(_0x3256d8,_0x37f44a)=>{const _0x43147f=this['_findChangeIdFromDomTarget'](_0x37f44a['target']),_0x186679=this['_changeIdToChange']['get'](_0x43147f);_0x186679?(this['_activeViewTarget']={'x':_0x37f44a['domEvent']['x'],'y':_0x37f44a['domEvent']['y']},_0x186679===this['activeChange']?this['_balloon']['updatePosition']():this['activeChange']=_0x186679):(this['_activeViewTarget']=null,this['activeChange']=null);});}['_findChangeIdFromDomTarget'](_0x4ff235){do{const _0x4f51bb=_0x4ff235['getAttribute']('data-change-id');if(_0x4f51bb)return _0x4f51bb;_0x4ff235=_0x4ff235['parent'];}while(_0x4ff235);return null;}['_cleanMarkers'](){this['editor']['model']['change'](_0x5cb495=>{for(const _0x1aab4d of this['editor']['model']['markers'])_0x5cb495['removeMarker'](_0x1aab4d);});}}function X(_0x1a21b7,_0x305b97){return(_0x3d09c4,_0x599b4f,_0x35d54f)=>{if(!_0x35d54f['consumable']['test'](_0x599b4f['markerRange'],_0x3d09c4['name']))return;const _0x34eee5=_0x599b4f['markerRange']['getWalker'](),_0x50edde=_0x599b4f['markerRange']['start'],_0x5988bd=_0x1a21b7['model']['schema'];let _0x78ae48=null,_0x181b0b=null,_0x33544a=!0x1,_0xa43ebf=!0x1;for(const _0x589763 of _0x34eee5){const _0x58d8e5=_0x589763['item'];_0x33544a=_0x33544a||_0x5988bd['isContent'](_0x58d8e5);const _0x37e8a1=_0x35d54f['mapper']['toViewElement'](_0x58d8e5);if(_0x37e8a1&&_0x37e8a1['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x589763['type']&&(_0x5988bd['isBlock'](_0x58d8e5)&&!_0x5988bd['isLimit'](_0x58d8e5)&&(_0x58d8e5['nextSibling']||_0x50edde['isAtEnd']?_0x78ae48&&_0x78ae48['parent']==_0x58d8e5||(_0x78ae48=_0x58d8e5,_0x4eb303(_0x589763['previousPosition']),_0xa43ebf=!0x0):_0x181b0b=_0x181b0b||_0x589763['previousPosition']));}function _0x4eb303(_0xc5603f){const _0x2344d7=_0x35d54f['mapper']['toViewPosition'](_0xc5603f),_0x4bbe58=_0x35d54f['writer']['createUIElement']('span',{'class':'ck-suggestion-preview-marker-'+_0x305b97});_0x35d54f['writer']['insert'](_0x2344d7,_0x4bbe58),_0x35d54f['mapper']['bindElementToMarker'](_0x4bbe58,_0x599b4f['markerName']);}_0x33544a||_0xa43ebf||!_0x181b0b||_0x4eb303(_0x181b0b);};}class mt extends _0x4a9630{constructor(_0x2e4f94){super(_0x2e4f94);const _0x4598e7=_0x2e4f94['plugins']['get'](m);this['affectsData']=!0x1,this['listenTo'](_0x4598e7,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x4598e7,'change:isEnabled',()=>this['refresh']());}['execute'](){const _0x4bf6d8=this['editor'],_0x22c68b=_0x4bf6d8['plugins']['get'](m),_0x19b425=_0x22c68b['isReady']?_0x22c68b['diff']['newRevisionId']:null;_0x4bf6d8['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x19b425);}['refresh'](){const {isReady:_0x3dd120,isEnabled:_0x509da8,repository:_0x5c476d,diff:_0x15aba8}=this['editor']['plugins']['get'](m),_0x5a86fb=_0x15aba8&&_0x5c476d['getLaterVisibleRevision'](_0x15aba8['newRevisionId']);this['isEnabled']=_0x3dd120&&_0x509da8&&Boolean(_0x5a86fb);}}class wt extends _0x4a9630{['_step'];constructor(_0x5a2e3a,{direction:_0x1c4218}){super(_0x5a2e3a);const _0x369bd5=_0x5a2e3a['plugins']['get'](m);this['affectsData']=!0x1,this['_step']='forward'===_0x1c4218?0x1:-0x1,this['listenTo'](_0x369bd5,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x369bd5,'change:isEnabled',()=>this['refresh']()),this['listenTo'](_0x369bd5,'change:activeChange',()=>this['refresh']());}['execute'](){const _0x2902f9=this['editor'],_0x16f3a1=_0x2902f9['plugins']['get'](m),{isNavigationMode:_0x2bfbef,currentChangeNumber:_0x2d6c1f}=_0x16f3a1;let _0x391921;if(_0x16f3a1['activeChange']=_0x2bfbef?_0x16f3a1['diff']['changes']['get'](_0x2d6c1f+this['_step']):_0x16f3a1['diff']['changes']['first'],_0x16f3a1['activeChange']['data']['isOnRoot'])_0x391921=_0x2902f9['editing']['view']['getDomRoot'](_0x16f3a1['activeChange']['rootName']);else{const _0xdfbb75=_0x2902f9['model']['markers']['get']('revision:'+_0x16f3a1['activeChange']['id']);_0x391921=_0x5b2979(_0x2902f9['editing'],_0xdfbb75);}_0x47b4d2({'target':_0x391921,'viewportOffset':0x28});}['refresh'](){const {isNavigationMode:_0x13a5cc,currentChangeNumber:_0x692dfd,numberOfChanges:_0x4ac6b2,isReady:_0x89b8c,isEnabled:_0x9b5018}=this['editor']['plugins']['get'](m);this['isEnabled']=!!(_0x9b5018&&_0x89b8c&&_0x4ac6b2)&&(!_0x13a5cc||(0x1===this['_step']?_0x692dfd<_0x4ac6b2-0x1:_0x692dfd>0x0));}}class _i extends ts{constructor(_0x18983a){super(_0x18983a);const _0x48f58a=this['bindTemplate'],_0x4d8ce4=new te(_0x18983a),_0x4627df=new te(_0x18983a);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',(_0x419542,_0x52f120)=>_0x419542&&_0x52f120>0x0),this['bind']('_statusText')['to'](this,'isReady',this,'currentChangeNumber',this,'numberOfChanges',this,'isNavigationMode',(_0x2ae850,_0x2d8317,_0x508e65,_0x4dc1de)=>{if(!_0x2ae850)return g(_0x18983a,'Loading...');if(!_0x508e65)return g(_0x18983a,'No\x20changes');const _0x3e1935=g(_0x18983a,'NUMBER_OF_CHANGES',_0x508e65);return _0x4dc1de?g(_0x18983a,'X_OF_Y_CHANGES',[_0x2d8317+0x1,_0x508e65]):_0x3e1935;}),_0x4d8ce4['set']({'label':g(_0x18983a,'Show\x20previous\x20change'),'tooltip':!0x0,'icon':_0x157ddd}),_0x4627df['set']({'label':g(_0x18983a,'Show\x20next\x20change'),'tooltip':!0x0,'icon':_0x577587}),_0x4d8ce4['bind']('isEnabled')['to'](this,'isBackwardNavigationEnabled'),_0x4627df['bind']('isEnabled')['to'](this,'isForwardNavigationEnabled'),_0x4d8ce4['on']('execute',()=>this['fire']('execute','backward')),_0x4627df['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',_0x48f58a['if']('_isStatusLabelVisible','ck-hidden',_0x59cff6=>!_0x59cff6)]},'children':[{'text':_0x48f58a['to']('isNavigationMode',_0x3ec7fd=>_0x3ec7fd?g(_0x18983a,'EDIT_X_OF_Y_REVISIONS')+':\x20':g(_0x18983a,'Total')+':\x20')}]},{'text':_0x48f58a['to']('_statusText')}]},new _0x2f1e4b(),{'tag':'div','attributes':{'class':['ck-revision-history-ui__changes-navigation__navigation']},'children':[_0x4d8ce4,_0x4627df]}]});}}const le='ck-editor__editable__loading-overlay';class ge extends _0x527fd9{static get['pluginName'](){return'RevisionViewerLoadingOverlay';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['show'](){const _0x464daa=this['editor']['editing']['view'];_0x464daa['change'](_0x1ef803=>{for(const _0x1f4796 of _0x464daa['document']['roots'])_0x1ef803['addClass'](le,_0x1f4796);});}['hide'](){const _0x5e9186=this['editor']['editing']['view'];_0x5e9186['change'](_0x3535d2=>{for(const _0x3b5e57 of _0x5e9186['document']['roots'])_0x3535d2['removeClass'](le,_0x3b5e57);});}}class R extends _0x527fd9{static get['pluginName'](){return'RevisionViewerUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[m,ge];}['init'](){const _0xc18f7f=this['editor'],_0x191463=_0xc18f7f['plugins']['get'](m),_0x40015e=_0xc18f7f['plugins']['get'](ge);_0xc18f7f['ui']['componentFactory']['add']('exitToEditing',_0x2b1c1d=>{const _0x13ecdd=new te(_0x2b1c1d);return _0x13ecdd['set']({'label':g(_0x2b1c1d,'Back\x20to\x20editing'),'icon':_0x42d483,'withText':!0x0,'tooltip':!0x0,'class':'ck-revision-history-ui__back-to-editing'}),this['listenTo'](_0x13ecdd,'execute',()=>{_0xc18f7f['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}),_0x13ecdd;}),_0xc18f7f['ui']['componentFactory']['add']('restoreRevision',_0x24b2a9=>{const _0x328dfa=new te(_0x24b2a9);return _0x328dfa['set']({'label':g(_0x24b2a9,'Restore\x20this\x20revision'),'withText':!0x0,'tooltip':!0x0}),_0x328dfa['bind']('isEnabled')['to'](_0xc18f7f['commands']['get']('restoreRevision')),this['listenTo'](_0x328dfa,'execute',()=>_0xc18f7f['execute']('restoreRevision')),_0x328dfa;}),_0xc18f7f['ui']['componentFactory']['add']('changesNavigation',_0x5bab2d=>{const _0x3a7217=new _i(_0x5bab2d),_0x5007ec=_0xc18f7f['commands']['get']('showPreviousChange'),_0x1d91da=_0xc18f7f['commands']['get']('showNextChange');return _0x3a7217['bind']('isBackwardNavigationEnabled')['to'](_0x5007ec,'isEnabled'),_0x3a7217['bind']('isForwardNavigationEnabled')['to'](_0x1d91da,'isEnabled'),_0x3a7217['bind']('isReady','currentChangeNumber','numberOfChanges','isNavigationMode')['to'](_0x191463),this['listenTo'](_0x3a7217,'execute',(_0x5f5bd4,_0x38da09)=>{_0xc18f7f['execute']('forward'===_0x38da09?'showNextChange':'showPreviousChange');}),_0x3a7217;}),_0x40015e['show'](),_0x191463['on']('change:isReady',(_0x3be478,_0x2bf95e,_0x20c766)=>{_0x20c766?_0x40015e['hide']():_0x40015e['show']();});}}class at extends _0x4a54d4{['_resizeObserver']=null;constructor(_0xeaf4e5,_0x556b6a){super(_0xeaf4e5,_0x556b6a);const _0x1b177f=this['bindTemplate'];this['set']({'label':g(_0xeaf4e5,'Revision\x20name'),'_tooltipString':''}),this['fieldView']['placeholder']=g(_0xeaf4e5,'Enter\x20the\x20revision\x20name'),this['extendTemplate']({'tag':'span','attributes':{'class':['ck-revision-history-sidebar__revision-name'],'data-cke-tooltip-text':_0x1b177f['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 _0x21b878=this['fieldView']['element'];this['_tooltipString']=_0x21b878['scrollWidth']>_0x21b878['clientWidth']&&_0x21b878['value']||'';}}class si extends ts{constructor(_0x5cb450,_0x1c32b1,_0x42c249){super(_0x5cb450);const _0x32c643=new _0x226077();_0x32c643['set']({'content':_0x594709,'viewBox':'0\x200\x2011\x2010'});const _0x399691=['ck','ck-revision-history-sidebar__revision-author'];_0x42c249&&_0x399691['push']('ck-revision-history-sidebar__revision-author_creator');const _0x577c93=[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision-author__name'],'title':g(_0x5cb450,_0x42c249?'Revision\x20creator':'Revision\x20author')},'children':[_0x32c643,_0x1c32b1['name']]}];this['setTemplate']({'tag':'li','attributes':{'class':_0x399691},'children':_0x577c93});}}function oi(_0x2cbca3,_0x4202e2){const _0x23ce54=_0x2cbca3['bindTemplate'],_0x209843=_0x2cbca3['locale'],_0x31201b=_0x2bb1f1(_0x209843);_0x31201b['panelPosition']='sw';const _0x971c67=function(_0xf56ed5,_0x46471d){const _0x565a00=function(_0x51203a,_0xff4db8){const _0x45ec51=_0x51203a['locale'],_0xaec155={'Compare\x20against\x20selected':g(_0x45ec51,'Compare\x20against\x20selected'),'Name\x20this\x20revision':g(_0x45ec51,'Name\x20this\x20revision'),'Restore\x20this\x20revision':g(_0x45ec51,'Restore\x20this\x20revision')};return _0xff4db8['map'](_0x28420b=>{const _0x316dba=_0xaec155[_0x28420b['name']];return _0x316dba&&_0x316dba!==_0x28420b['name']&&(_0x28420b['name']=_0x316dba),_0x28420b;});}(_0xf56ed5,_0x46471d),_0x417525=new _0x3f8e7a();for(const _0x1fac61 of _0x565a00){const _0x25906a={'type':'button','model':new to({'label':_0x1fac61['name'],'class':_0x1fac61['class'],'withText':!0x0,'role':'menuitem','_action':_0x1fac61['action']})};_0x25906a['model']['bind']('isEnabled')['to'](_0xf56ed5,'isActionsDropdownOpen',_0x226431=>'function'!=typeof _0x1fac61['isEnabled']||(!_0x226431||_0x1fac61['isEnabled'](_0xf56ed5))),_0x417525['add'](_0x25906a);}return _0x417525;}(_0x2cbca3,_0x4202e2);return _0x2cbca3['bind']('isActionsDropdownOpen')['to'](_0x31201b,'isOpen'),_0x31201b['buttonView']['set']({'label':g(_0x209843,'Show\x20more\x20items'),'tooltip':!0x0,'tooltipPosition':'sw','icon':_0x14de33}),_0x31201b['extendTemplate']({'attributes':{'class':['ck-revision-history-sidebar__revision__actions',_0x23ce54['if']('isActionsDropdownOpen','ck-on')]},'on':{'click':_0x23ce54['to'](_0x5e4434=>_0x5e4434['stopPropagation']())}}),_0x31201b['on']('execute',_0x36705e=>{_0x2cbca3['isReady']&&'function'==typeof _0x36705e['source']['_action']&&_0x36705e['source']['_action'](_0x2cbca3);}),_0x43d39a(_0x31201b,_0x971c67,{'role':'menu'}),_0x31201b['listenTo'](_0x2cbca3,'change:isActionsDropdownOpen',(_0x40c076,_0xde275d,_0x4fc435)=>{if(_0x4fc435)for(const _0x3a59d6 of _0x31201b['listView']['items']){const _0x176a4e=_0x3a59d6['children']['first'],_0x17ba6b=_0x4202e2['find'](_0x249e50=>_0x249e50['action']===_0x176a4e['_action'])['isVisible'];_0x3a59d6['isVisible']=void 0x0===_0x17ba6b||_0x17ba6b(_0x2cbca3);}}),_0x31201b;}class hi extends/* #__PURE__ -- @preserve */
|
|
26
|
+
ti(ts){['id'];['revisionNameView'];['revisionActionsView'];['_revision'];['_requireRevisionName'];constructor(_0x5e1318,_0x51983f,_0x239d2c,_0x50b28e){super(_0x5e1318);const _0x94c8a0=this['bindTemplate'],_0x4e9387=function(_0x4e5e3c,_0x2754d5){const _0x1a52d4=Array['from'](_0x2754d5['authors'])['filter'](_0x558675=>_0x558675!=_0x2754d5['creator']);return _0x2754d5['creator']&&_0x1a52d4['unshift'](_0x2754d5['creator']),_0x1a52d4['map'](_0x21da3e=>new si(_0x4e5e3c,_0x21da3e,_0x21da3e==_0x2754d5['creator']));}(_0x5e1318,_0x51983f);this['id']=_0x51983f['id'],this['_revision']=_0x51983f,this['_requireRevisionName']=_0x50b28e,this['bind']('name','createdAt')['to'](_0x51983f),this['bind']('_createdAtFormatted')['to'](this,'createdAt',_0x226581=>{return _0x23b04b=_0x5e1318['uiLanguage'],(_0x33fe88=_0x226581)['toLocaleDateString'](_0x23b04b,{'month':'long','day':'numeric'})+',\x20'+_0x33fe88['toLocaleTimeString'](_0x23b04b,{'hour':'numeric','minute':'numeric'});var _0x23b04b,_0x33fe88;}),this['set']('isSelected',!0x1),this['set']('isHighlighted',!0x1),this['set']('isActionsDropdownOpen',!0x1),this['set']('isReady',!0x1),this['set']('isEnabled',!0x1),this['revisionNameView']=new at(_0x5e1318,_0x37da91),this['revisionNameView']['fieldView']['extendTemplate']({'attributes':{'maxlength':'220'}}),this['revisionNameView']['fieldView']['bind']('value')['to'](this,'name',_0x3c4c57=>_0x3c4c57||this['_createdAtFormatted']),this['revisionNameView']['bind']('isEnabled')['to'](this,'isSelected',this,'isEnabled',(_0x42b67a,_0x2b14b6)=>_0x42b67a&&_0x2b14b6),this['revisionActionsView']=_0x239d2c&&_0x239d2c['length']?oi(this,_0x239d2c):'',this['revisionActionsView']&&this['revisionActionsView']['bind']('isEnabled')['to'](this),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision-wrapper',_0x94c8a0['if']('isConfirm','ck-revision-history-sidebar__revision-wrapper_confirmation_visible')]},'children':[{'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision',_0x94c8a0['if']('isEnabled','ck-disabled',_0x4f7a9c=>!_0x4f7a9c),_0x94c8a0['if']('isSelected','ck-revision-history-sidebar__revision_selected'),_0x94c8a0['if']('isHighlighted','ck-revision-history-sidebar__revision_highlighted'),_0x94c8a0['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':_0x94c8a0['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':_0x4e9387}]},this['revisionActionsView']],'on':{'click':_0x94c8a0['to'](_0x368680=>{_0x368680['srcElement']['closest']('.ck-thread__remove-confirm')||this['isReady']&&this['isEnabled']&&this['fire']('select',{'id':this['id']});})}}]});}['render'](){super['render']();const _0x5c26b3=this['revisionNameView']['fieldView']['element'];this['listenTo'](_0x5c26b3,'change',()=>{this['_requireRevisionName']&&!_0x5c26b3['value']||this['fire']('setName',{'id':this['id'],'name':_0x5c26b3['value']}),_0x5c26b3['value']||(_0x5c26b3['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(_0x1afe9c,_0x53e21b){const _0x21f1ac=_0x3f3942['fromJSDate'](_0x1afe9c)['setLocale'](_0x53e21b),_0x57dcfc=_0x3f3942['local'](),_0x3a5d65=_0x57dcfc['minus']({'days':0x1})['startOf']('day');let _0x2e910b,_0x3da1a8;return _0x21f1ac['hasSame'](_0x57dcfc,'day')?(_0x2e910b=_0x21f1ac['startOf']('day')['toJSDate'](),_0x3da1a8=_0x21f1ac['toRelativeCalendar']()):_0x21f1ac['hasSame'](_0x3a5d65,'day')?(_0x2e910b=_0x3a5d65['toJSDate'](),_0x3da1a8=_0x21f1ac['toRelativeCalendar']()):_0x21f1ac['hasSame'](_0x57dcfc,'week')?(_0x2e910b=_0x21f1ac['startOf']('week')['toJSDate'](),_0x3da1a8=_0x21f1ac['weekdayLong']||''):_0x21f1ac['hasSame'](_0x57dcfc,'year')?(_0x2e910b=_0x21f1ac['startOf']('month')['toJSDate'](),_0x3da1a8=_0x21f1ac['monthLong']||''):(_0x2e910b=_0x21f1ac['startOf']('year')['toJSDate'](),_0x3da1a8=String(_0x21f1ac['year'])),{'startDate':_0x2e910b,'localizedPeriodName':_0x3da1a8};}class di extends ts{['startDate'];['revisionViews'];['_revisionActions'];['_requireRevisionName'];constructor(_0x44324a,_0x329500,_0x4dd575,_0x407925){super(_0x44324a);const _0x3d1cc7=ai(_0x329500,this['locale']['uiLanguage'])['localizedPeriodName'];this['startDate']=_0x329500,this['revisionViews']=this['createCollection'](),this['_revisionActions']=_0x4dd575,this['_requireRevisionName']=_0x407925,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':_0x3d1cc7}]},{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__time-period__revisions']},'children':this['revisionViews']}]});}['addRevision'](_0x44aa29){const _0x15e9e6=new hi(this['locale'],_0x44aa29,this['_revisionActions'],this['_requireRevisionName']);this['revisionViews']['add'](_0x15e9e6);}['removeRevision'](_0x18f33a){const _0xa0d111=this['revisionViews']['find'](_0x23a74d=>_0x23a74d['id']===_0x18f33a['id']);this['revisionViews']['remove'](_0xa0d111);}}class as extends ts{constructor(_0xea1fa1){super(_0xea1fa1);const _0x48cd9f=new _0x226077();_0x48cd9f['content']=_0x278e4f,this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset_all','ck-revision-history-sidebar__header']},'children':[_0x48cd9f,{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__header__label']},'children':[g(_0xea1fa1,'Revision\x20history')]}]});}}class ni extends ts{['timePeriodViews'];['_revisions'];['_revisionActions'];['_requireRevisionName'];constructor(_0x35e547,_0xd0fdef,_0x65f5d,_0x411bbe){super(_0x35e547);const _0x59382c=this['bindTemplate'];this['timePeriodViews']=this['createCollection'](),this['timePeriodViews']['delegate']('select')['to'](this),this['timePeriodViews']['delegate']('setName')['to'](this),this['_revisions']=_0xd0fdef,this['_revisionActions']=_0x65f5d,this['_requireRevisionName']=_0x411bbe,this['on']('select',(_0x139512,_0x2db29c)=>{this['fire']('revisionSelected',_0x2db29c);}),this['on']('setName',(_0x308fb9,_0x1c4f7e)=>{this['fire']('revisionSetName',_0x1c4f7e);}),this['set']('isEnabled',!0x1),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-rounded-corners','ck-revision-history-sidebar']},'children':[new as(_0x35e547),{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__timeline',_0x59382c['if']('isEnabled','ck-disabled',_0x2abff6=>!_0x2abff6)]},'children':this['timePeriodViews']}]});}['render'](){super['render']();for(const _0x5ab2df of this['_revisions'])this['_addRevision'](_0x5ab2df);this['_revisions']['on']('add',(_0x5d4073,_0x5d278e)=>{this['_addRevision'](_0x5d278e);}),this['_revisions']['on']('remove',(_0x5f079b,_0xf3ff32)=>{this['_removeRevision'](_0xf3ff32);});}get['revisionViews'](){return this['timePeriodViews']['map'](_0x5c02e9=>_0x5c02e9['revisionViews']['map'](_0x265425=>_0x265425))['flat']();}['selectRevision'](_0x1d9fc6){for(const _0xd648a6 of this['revisionViews'])_0x1d9fc6&&_0x1d9fc6['id']===_0xd648a6['id']?_0xd648a6['select']():_0xd648a6['deselect']();}['highlightRevisions'](_0x2bc745){for(const _0x22a0ff of this['revisionViews'])_0x2bc745['some'](({id:_0x59d5b5})=>_0x59d5b5===_0x22a0ff['id'])?_0x22a0ff['highlight']():_0x22a0ff['unhighlight']();}['_addRevision'](_0x5a2001){const _0x2cbe95=ai(_0x5a2001['createdAt'],this['locale']['uiLanguage'])['startDate'];let _0x301cc4=this['timePeriodViews']['get'](0x0);_0x301cc4&&_0x301cc4['startDate']['getTime']()===_0x2cbe95['getTime']()||(_0x301cc4=new di(this['locale'],_0x2cbe95,this['_revisionActions'],this['_requireRevisionName']),this['timePeriodViews']['add'](_0x301cc4)),_0x301cc4['addRevision'](_0x5a2001);}['_removeRevision'](_0x28696){const _0x478486=ai(_0x28696['createdAt'],this['locale']['uiLanguage'])['startDate'];this['_getTimePeriodViewByStartDate'](_0x478486)['removeRevision'](_0x28696);}['_getTimePeriodViewByStartDate'](_0x316a60){return this['timePeriodViews']['find'](_0x248022=>_0x248022['startDate']['getTime']()===_0x316a60['getTime']());}}class d extends _0x527fd9{['_revisionViewer'];['_revisionsRepository'];['_sidebarView'];static ['defaultRevisionActions']=/* #__PURE__ -- @preserve */
|
|
27
27
|
((()=>['compareAgainstSelected','restoreRevision','nameRevision'])());static ['availableRevisionActions']=/* #__PURE__ -- @preserve */
|
|
28
|
-
|
|
29
|
-
_0x5aa471(_0x54efd4){['_ui'];get['ui'](){return this['_ui'];}constructor(_0x52bbea,_0x201140){super(_0x201140),this['sourceElement']=_0x52bbea,this['model']['document']['createRoot']();const _0x5797d5=new it(this['locale'],this['editing']['view'],{'shouldToolbarGroupWhenFull':!0x0});this['_ui']=new tt(this,_0x5797d5);}['destroy'](){return this['updateSourceElement'](),this['ui']['destroy'](),super['destroy']();}static async['create'](_0x31552f,_0x3c2c45){const _0xab2e21=new this(_0x31552f,_0x3c2c45);return await _0xab2e21['initPlugins'](),await _0xab2e21['ui']['init'](_0x31552f),await _0xab2e21['data']['init'](_0xab2e21['config']['get']('initialData')||''),_0xab2e21['fire']('ready'),_0xab2e21;}}const p=['RevisionHistoryUI','RestrictedEditingMode'];class yt extends _0x58bc6f{['result'];static get['pluginName'](){return'RevisionViewerIntegration';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x3079ff){function _0x5c5695(_0x47c872){return _0x47c872['map'](_0x17a700=>String['fromCharCode'](_0x17a700))['join']('');}super(_0x3079ff),this['result']='end',_0x3079ff[_0x5c5695([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x5c5695([0x76,0x69,0x65,0x77])][_0x5c5695([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x5c5695([0x61,0x75,0x74,0x6f]),_0x3079ff[_0x5c5695([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x5c5695([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x5c5695([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x5c5695([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x5c5695([0x6f,0x6b])});}}class k extends _0x58bc6f{['_viewerEditor'];static get['pluginName'](){return'RevisionHistory';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[u,f];}constructor(_0x181fdf){if(super(_0x181fdf),!this['editor']['config']['get']('revisionHistory'))throw new _0x43b617('revision-history-missing-configuration',this);this['_viewerEditor']=null,this['set']('isRevisionViewerOpen',!0x1),this['editor']['config']['define']('revisionHistory.showRevisionViewerCallback',_0xeadb8d=>this['_showRevisionViewer']({..._0xeadb8d,'translations':this['editor']['locale']['translations']})),this['editor']['config']['define']('revisionHistory.closeRevisionViewerCallback',_0x5e154e=>this['_closeRevisionViewer'](_0x5e154e)),this['editor']['config']['define']('revisionHistory.restoreRevisionCallback',_0x36952a=>this['_restoreRevision'](_0x36952a)),this['editor']['config']['define']('revisionHistory.requireRevisionName',!0x1),this['_enhanceShowRevisionViewerCallback'](),this['_enhanceCloseRevisionViewerCallback']();}set['adapter'](_0x5d7dd5){this['editor']['plugins']['get']('RevisionTracker')['adapter']=_0x5d7dd5;}get['adapter'](){return this['editor']['plugins']['get']('RevisionTracker')['adapter'];}['addRevisionData'](_0x4cafb0){return this['editor']['plugins']['get']('RevisionTracker')['addRevisionData'](_0x4cafb0);}['getRevision'](_0x5769b3){return this['editor']['plugins']['get']('RevisionsRepository')['getRevision'](_0x5769b3);}['getRevisions'](_0x35817c){return this['editor']['plugins']['get']('RevisionsRepository')['getRevisions'](_0x35817c||{'toJSON':!0x1});}['_getRevisionViewerEditorConfig'](){const _0x541e81=this['editor'],_0xe8915=_0x23feb7(_0x541e81,p),_0x49f357=_0x541e81['plugins']['get']('RevisionTracker'),_0x533307=_0x541e81['plugins']['get']('Users')['users'];return _0xe8915['toolbar']=['exitToEditing','restoreRevision','changesNavigation'],delete _0xe8915['lazyRoots'],(_0xe8915['plugins']['push'](yt,m,R,class extends _0x58bc6f{static get['requires'](){return[m,'Users'];}['init'](){const _0x10c469=this['editor']['plugins']['get']('Users');for(const _0x22d723 of _0x533307)_0x22d723['isAnonymous']||_0x10c469['getUser'](_0x22d723['id'])||_0x10c469['addUser'](_0x22d723);const _0x187960=_0x49f357['repository']['getRevisions']();let _0x6f26ad=null;const _0x29916b=this['editor']['plugins']['get']('RevisionViewer');_0x29916b['adapter']=_0x49f357['adapter'],_0x29916b['bind']('isEnabled')['to'](_0x49f357),this['editor']['commands']['get']('restoreRevision')['bind']('isEnabled')['to'](_0x541e81,'isReadOnly',_0x3c9f37=>!_0x3c9f37);for(const _0x1f9adf of _0x187960){const _0xd9175=null===_0x1f9adf['creator'];if(_0xd9175&&_0x1f9adf['toVersion']===_0x1f9adf['fromVersion'])continue;const _0x5170ee=_0x1f9adf['toJSON']();_0x29916b['addRevisionData'](_0x5170ee,(_0x2467ef,_0x3ec48b,_0x126cf0)=>{if(_0xd9175){if(_0x6f26ad)_0x6f26ad['_update'](_0x2467ef,_0x3ec48b);else{if(!_0x3ec48b){const _0x4afba2=_0x126cf0['toJSON']();_0x4afba2['id']=_0x11e8c2(),_0x49f357['saveRevision'](_0x4afba2,_0x126cf0['toVersion'])['then'](_0x5f1d6e=>{_0x6f26ad=_0x5f1d6e;});}}}else _0x1f9adf['_update'](_0x2467ef,_0x3ec48b);});}}},d),_0xe8915);}['_enhanceShowRevisionViewerCallback'](){const _0x8a3602=this['editor']['config']['get']('revisionHistory')['showRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.showRevisionViewerCallback',async()=>{this['editor']['enableReadOnlyMode']('revision-history-viewer-opened');const _0x2195a8=this['editor']['plugins']['get']('RevisionTracker');if(this['editor']['plugins']['has']('Autosave')){const _0x28953d=this['editor']['plugins']['get']('Autosave');await _0x28953d['save']();}else await _0x2195a8['update']();if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('Dialog')){const _0x56f514=this['editor']['plugins']['get']('Dialog');_0x56f514['isOpen']&&_0x56f514['hide']();}const _0x42db08=this['_getRevisionViewerEditorConfig']();return _0x8a3602(_0x42db08)['then'](_0x31a59e=>{return(this['_viewerEditor']=_0x31a59e,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'),_0x31a59e);})['catch'](_0xb917b2=>(console['error'](_0xb917b2),this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),null));});}['_enhanceCloseRevisionViewerCallback'](){const _0x4dd6a9=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'](),_0x4dd6a9(this['_viewerEditor'])['then'](()=>{if(this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),this['_viewerEditor']=null,this['editor']['plugins']['has']('Annotations')){const _0x4eb94d=this['editor']['plugins']['get']('Annotations');_0x4eb94d['refreshVisibility'](),_0x4eb94d['refreshPositioning']();}})));}['_showRevisionViewer'](_0x16e0c8){const _0x1ade8e=this['editor']['config']['get']('revisionHistory.editorContainer'),_0x5838d3=this['editor']['config']['get']('revisionHistory.viewerContainer'),_0x109dc0=this['editor']['config']['get']('revisionHistory.viewerEditorElement');return w['create'](_0x109dc0,_0x16e0c8)['then'](_0x43275c=>(_0x5838d3['style']['display']='block',_0x1ade8e['style']['display']='none',this['isRevisionViewerOpen']=!0x0,_0x43275c));}['_closeRevisionViewer'](_0x46d7ef){const _0x173a7e=this['editor']['config']['get']('revisionHistory.editorContainer');return this['editor']['config']['get']('revisionHistory.viewerContainer')['style']['display']='none',_0x173a7e['style']['display']='',this['isRevisionViewerOpen']=!0x1,_0x46d7ef['destroy']();}async['_restoreRevision'](_0x1839ce){const _0x26af39=this['editor'],_0x15eae1=this['_viewerEditor']['plugins']['get']('RevisionViewer'),_0x5dc907=_0x26af39['plugins']['get']('RevisionTracker'),_0x55f52a=_0x26af39['plugins']['get']('RevisionHistoryUtils'),_0x4d8dcb=_0x15eae1['repository']['getRevision'](_0x1839ce);let _0x30f613,_0x5f0345,_0x127cec;try{await _0x55f52a['loadRevisionData'](_0x4d8dcb,this['adapter']),_0x30f613=_0x55f52a['getRevisionDocumentData'](_0x4d8dcb),_0x5f0345=_0x55f52a['getRevisionRootsAttributes'](_0x4d8dcb);}catch(_0x20d0ab){return void console['error'](_0x20d0ab);}_0x26af39['model']['change'](_0x927239=>{for(const _0x2cd1bd of Array['from'](_0x26af39['model']['markers']['getMarkersGroup']('restrictedEditingException')))_0x927239['removeMarker'](_0x2cd1bd);}),_0x15eae1['isReady']=!0x1,_0x26af39['model']['enqueueChange'](_0x39239b=>{_0x39239b['setSelection'](null),_0x39239b['removeSelectionAttribute'](_0x26af39['model']['document']['selection']['getAttributeKeys']());const _0x37144f=Object['keys'](_0x30f613);for(const _0x2ad5bb of _0x26af39['model']['document']['roots'])'$graveyard'!=_0x2ad5bb['rootName']&&_0x2ad5bb['isAttached']()&&!_0x37144f['includes'](_0x2ad5bb['rootName'])&&_0x39239b['detachRoot'](_0x2ad5bb);for(const _0x54ff69 of _0x37144f){let _0x46cf05=_0x26af39['model']['document']['getRoot'](_0x54ff69);_0x46cf05&&_0x46cf05['isAttached']()||(_0x46cf05=_0x39239b['addRoot'](_0x54ff69));const _0x4b7c6f=_0x5f0345[_0x54ff69],_0x5e6502=Object['keys'](_0x4b7c6f),_0x2f1376=_0x30f613[_0x54ff69];for(const _0x14cc22 of _0x46cf05['getAttributeKeys']())_0x5e6502['includes'](_0x14cc22)||_0x39239b['removeAttribute'](_0x14cc22,_0x46cf05);for(const _0xd3995 of _0x5e6502)_0x39239b['setAttribute'](_0xd3995,_0x5f0345[_0x54ff69][_0xd3995],_0x46cf05);_0x39239b['remove'](_0x39239b['createRangeIn'](_0x46cf05)),_0x39239b['insert'](_0x26af39['data']['parse'](_0x2f1376,_0x46cf05),_0x46cf05,0x0);}});const _0x5f4c2b=g(_0x26af39['locale'],'Restored');if(_0x4d8dcb['name'])_0x127cec=-0x1==_0x4d8dcb['name']['indexOf'](_0x5f4c2b)?_0x5f4c2b+':\x20'+_0x4d8dcb['name']:_0x4d8dcb['name'];else _0x127cec=_0x5f4c2b+':\x20'+(_0x4d8dcb['createdAt']['toLocaleDateString'](_0x26af39['locale']['uiLanguage'],{'month':'long','day':'numeric'})+',\x20'+_0x4d8dcb['createdAt']['toLocaleTimeString'](_0x26af39['locale']['uiLanguage'],{'hour':'numeric','minute':'numeric'}));return await _0x5dc907['saveRevision']({'name':_0x127cec}),_0x15eae1['isReady']=!0x0,_0x26af39['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,le 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(_0x3d64b7){super(_0x3d64b7),this['_revisionViewer']=_0x3d64b7['plugins']['get'](m),this['_revisionsRepository']=this['_revisionViewer']['repository'],this['_sidebarView']=null;}['init'](){const _0x1a87e4=this['_revisionsRepository']['_revisions'],_0x31b6fd=this['_createRevisionActions'](),_0x54715a=this['editor']['config']['get']('revisionHistory.viewerSidebarContainer');this['_sidebarView']=new ni(this['editor']['locale'],_0x1a87e4,_0x31b6fd,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',(_0x123d31,_0x488f70)=>{_0x488f70['revisionViews']['on']('add',(_0x5880f0,_0x58ec71)=>{_0x58ec71['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)),_0x54715a['appendChild'](this['_sidebarView']['element']);}['destroy'](){this['_sidebarView']['element']['remove'](),this['_sidebarView']['destroy']();}['_handleEditorDataReady'](){const _0x4b9452=this['_revisionsRepository']['getRevision'](0x0);if(_0x4b9452){const _0x58de15=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x4b9452['id']);this['_revisionViewer']['compare'](_0x4b9452,_0x58de15);}}['_handleRevisionSelected'](_0x4e40e2,_0x3ffd63){const _0x19d582=this['_revisionsRepository']['getRevision'](_0x3ffd63['id']),_0x151573=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x19d582['id']);this['_revisionViewer']['compare'](_0x19d582,_0x151573);}['_handleRevisionSetName'](_0x5dc93e,_0x5f1a04){this['_revisionsRepository']['getRevision'](_0x5f1a04['id'])['setName'](_0x5f1a04['name']);}['_handleDiffChange'](_0x29ff63,_0xb85bdd,_0x39704b){const _0x287685=this['_revisionsRepository']['getRevisionsInDiff'](_0x39704b);_0x287685['length']>0x2?(this['_sidebarView']['highlightRevisions'](_0x287685),this['_sidebarView']['selectRevision'](null)):(this['_sidebarView']['highlightRevisions']([]),this['_sidebarView']['selectRevision'](_0x287685[0x0]));}['_createRevisionActions'](){const _0x3f2441=this['editor'],_0x1d58ad=d['availableRevisionActions'],_0x395b0e=_0x3f2441['config']['get']('revisionHistory.revisionActions')||d['defaultRevisionActions'];if(_0x395b0e['length'])return _0x395b0e['map'](_0x3ee2a2=>{const _0x23e24b='string'==typeof _0x3ee2a2?Object['assign']({},_0x1d58ad[_0x3ee2a2]):_0x3ee2a2;return _0x23e24b['action']=_0x23e24b['action']['bind'](this,_0x3f2441),_0x23e24b['isVisible']&&(_0x23e24b['isVisible']=_0x23e24b['isVisible']['bind'](this,_0x3f2441)),_0x23e24b;});}}function pt(){return{'compareAgainstSelected':{'name':'Compare\x20against\x20selected','action':({plugins:_0x3ba104},_0x14a77c)=>{const _0x36d242=_0x3ba104['get'](m),_0x5e0b1b=_0x36d242['repository'];let _0x1f6f86=_0x36d242['diff']['newRevisionId'],_0x347dba=_0x14a77c['id'];_0x5e0b1b['getIndex'](_0x1f6f86)>_0x5e0b1b['getIndex'](_0x347dba)&&([_0x1f6f86,_0x347dba]=[_0x347dba,_0x1f6f86]),_0x36d242['compare'](_0x1f6f86,_0x347dba);},'isVisible':({plugins:_0x590f8b},_0x584e53)=>{const _0x2186b5=_0x590f8b['get'](m);return!(_0x2186b5['repository']['getRevisionsInDiff'](_0x2186b5['diff'])['length']>0x2)&&!_0x584e53['isSelected'];}},'restoreRevision':{'name':'Restore\x20this\x20revision','action':(_0x32ea61,{id:_0x23db8c})=>{_0x32ea61['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x23db8c);},'isVisible':({plugins:_0x4069f8},_0x421b16)=>!!_0x4069f8['get'](m)['repository']['getLaterVisibleRevision'](_0x421b16['id'])},'nameRevision':{'name':'Name\x20this\x20revision','action':({plugins:_0x1d8a7a},{id:_0xe916e,revisionNameView:_0x3bafe7})=>{const _0x6e10=_0x1d8a7a['get'](m),_0x1b2829=_0x6e10['repository']['getEarlierVisibleRevision'](_0xe916e);_0x6e10['compare'](_0xe916e,_0x1b2829),_0x3bafe7['focus'](),_0x3bafe7['fieldView']['select']();}}};}class tt extends st{['_view'];['_toolbarConfig'];['_elementReplacer'];get['view'](){return this['_view'];}constructor(_0x1bc060,_0x2a9647){super(_0x1bc060),this['_view']=_0x2a9647,this['_toolbarConfig']=et(_0x1bc060['config']['get']('toolbar')),this['_elementReplacer']=new ot();}get['element'](){return this['view']['element'];}['init'](_0x2f6a8c){const _0x3a7ddc=this['editor'],_0x3dbf46=this['view'],_0x31f381=_0x3a7ddc['editing']['view'],_0x2315e8=_0x3dbf46['editable'],_0x42dfc4=_0x31f381['document']['getRoot']();_0x2315e8['name']=_0x42dfc4['rootName'],_0x3dbf46['render']();const _0x2da7bd=_0x2315e8['element'];this['setEditableElement'](_0x2315e8['name'],_0x2da7bd),_0x3dbf46['editable']['bind']('isFocused')['to'](this['focusTracker']),_0x31f381['attachDomRoot'](_0x2da7bd),this['_elementReplacer']['replace'](_0x2f6a8c,this['element']),this['_initToolbar'](),this['fire']('ready');}['destroy'](){super['destroy']();const _0x28b844=this['view'],_0x909226=this['editor']['editing']['view'];this['_elementReplacer']['restore'](),_0x909226['detachDomRoot'](_0x28b844['editable']['name']),_0x28b844['destroy']();}['_initToolbar'](){const _0x4855e0=this['view'];_0x4855e0['stickyPanel']['bind']('isActive')['to'](this['focusTracker'],'isFocused'),_0x4855e0['stickyPanel']['limiterElement']=_0x4855e0['element'],_0x4855e0['stickyPanel']['bind']('viewportTopOffset')['to'](this,'viewportOffset',({top:_0x486fd5})=>_0x486fd5),_0x4855e0['toolbar']['fillFromConfig'](this['_toolbarConfig'],this['componentFactory']),this['addToolbar'](_0x4855e0['toolbar']);}}class it extends rt{['_editable'];['stickyPanel'];['toolbar'];get['editable'](){return this['_editable'];}constructor(_0x31b412,_0x119a7e,_0x51d0e9={}){super(_0x31b412),this['stickyPanel']=new ht(_0x31b412),this['toolbar']=new dt(_0x31b412,{'shouldGroupWhenFull':_0x51d0e9['shouldToolbarGroupWhenFull']}),this['_editable']=new ct(_0x31b412,_0x119a7e);}['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
|
+
_0x52547e(_0x3270d8){['_ui'];get['ui'](){return this['_ui'];}constructor(_0x723ecf,_0x44effd){super(_0x44effd),this['sourceElement']=_0x723ecf,this['model']['document']['createRoot']();const _0x418b62=new it(this['locale'],this['editing']['view'],{'shouldToolbarGroupWhenFull':!0x0});this['_ui']=new tt(this,_0x418b62);}['destroy'](){return this['updateSourceElement'](),this['ui']['destroy'](),super['destroy']();}static async['create'](_0x1b5bc8,_0x24ee4a){const _0x2e5d00=new this(_0x1b5bc8,_0x24ee4a);return await _0x2e5d00['initPlugins'](),await _0x2e5d00['ui']['init'](_0x1b5bc8),await _0x2e5d00['data']['init'](_0x2e5d00['config']['get']('initialData')||''),_0x2e5d00['fire']('ready'),_0x2e5d00;}}const p=['RevisionHistoryUI','RestrictedEditingMode'];class _t extends _0x527fd9{['result'];static get['pluginName'](){return'RevisionViewerIntegration';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x381c68){function _0x424474(_0x18adeb){return _0x18adeb['map'](_0x1c44cb=>String['fromCharCode'](_0x1c44cb))['join']('');}super(_0x381c68),this['result']='end',_0x381c68[_0x424474([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x424474([0x76,0x69,0x65,0x77])][_0x424474([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x424474([0x61,0x75,0x74,0x6f]),_0x381c68[_0x424474([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x424474([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x424474([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x424474([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x424474([0x6f,0x6b])});}}class k extends _0x527fd9{['_viewerEditor'];static get['pluginName'](){return'RevisionHistory';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[u,f];}constructor(_0x45d8be){if(super(_0x45d8be),!this['editor']['config']['get']('revisionHistory'))throw new _0x5afe82('revision-history-missing-configuration',this);this['_viewerEditor']=null,this['set']('isRevisionViewerOpen',!0x1),this['editor']['config']['define']('revisionHistory.showRevisionViewerCallback',_0x1928c5=>this['_showRevisionViewer']({..._0x1928c5,'translations':this['editor']['locale']['translations']})),this['editor']['config']['define']('revisionHistory.closeRevisionViewerCallback',_0x148853=>this['_closeRevisionViewer'](_0x148853)),this['editor']['config']['define']('revisionHistory.restoreRevisionCallback',_0x523f3f=>this['_restoreRevision'](_0x523f3f)),this['editor']['config']['define']('revisionHistory.requireRevisionName',!0x1),this['_enhanceShowRevisionViewerCallback'](),this['_enhanceCloseRevisionViewerCallback']();}set['adapter'](_0x4f6ee5){this['editor']['plugins']['get']('RevisionTracker')['adapter']=_0x4f6ee5;}get['adapter'](){return this['editor']['plugins']['get']('RevisionTracker')['adapter'];}['addRevisionData'](_0xb76c5b){return this['editor']['plugins']['get']('RevisionTracker')['addRevisionData'](_0xb76c5b);}['getRevision'](_0x572d6d){return this['editor']['plugins']['get']('RevisionsRepository')['getRevision'](_0x572d6d);}['getRevisions'](_0x16fd41){return this['editor']['plugins']['get']('RevisionsRepository')['getRevisions'](_0x16fd41||{'toJSON':!0x1});}['_getRevisionViewerEditorConfig'](){const _0x4117b1=this['editor'],_0x12e5b3=_0x5ba2f0(_0x4117b1,p),_0x2dfb8e=_0x4117b1['plugins']['get']('RevisionTracker'),_0x2805d2=_0x4117b1['plugins']['get']('Users')['users'];return _0x12e5b3['toolbar']=['exitToEditing','restoreRevision','changesNavigation'],delete _0x12e5b3['lazyRoots'],(_0x12e5b3['plugins']['push'](_t,m,R,class extends _0x527fd9{static get['requires'](){return[m,'Users'];}['init'](){const _0xf5b3eb=this['editor']['plugins']['get']('Users');for(const _0x1fe626 of _0x2805d2)_0x1fe626['isAnonymous']||_0xf5b3eb['getUser'](_0x1fe626['id'])||_0xf5b3eb['addUser'](_0x1fe626);const _0x5bc591=_0x2dfb8e['repository']['getRevisions']();let _0x6c076=null;const _0x472af6=this['editor']['plugins']['get']('RevisionViewer');_0x472af6['adapter']=_0x2dfb8e['adapter'],_0x472af6['bind']('isEnabled')['to'](_0x2dfb8e),this['editor']['commands']['get']('restoreRevision')['bind']('isEnabled')['to'](_0x4117b1,'isReadOnly',_0x125992=>!_0x125992);for(const _0x2d6f51 of _0x5bc591){const _0x53139a=null===_0x2d6f51['creator'];if(_0x53139a&&_0x2d6f51['toVersion']===_0x2d6f51['fromVersion'])continue;const _0x100b1c=_0x2d6f51['toJSON']();_0x472af6['addRevisionData'](_0x100b1c,(_0xd6d8f2,_0x54f86e,_0x13168a)=>{if(_0x53139a){if(_0x6c076)_0x6c076['_update'](_0xd6d8f2,_0x54f86e);else{if(!_0x54f86e){const _0x4584d5=_0x13168a['toJSON']();_0x4584d5['id']=_0x571ba5(),_0x2dfb8e['saveRevision'](_0x4584d5,_0x13168a['toVersion'])['then'](_0xe2ba43=>{_0x6c076=_0xe2ba43;});}}}else _0x2d6f51['_update'](_0xd6d8f2,_0x54f86e);});}}},d),_0x12e5b3);}['_enhanceShowRevisionViewerCallback'](){const _0x33f819=this['editor']['config']['get']('revisionHistory')['showRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.showRevisionViewerCallback',async()=>{this['editor']['enableReadOnlyMode']('revision-history-viewer-opened');const _0x2bbd20=this['editor']['plugins']['get']('RevisionTracker');if(this['editor']['plugins']['has']('Autosave')){const _0x12a507=this['editor']['plugins']['get']('Autosave');await _0x12a507['save']();}else await _0x2bbd20['update']();if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('Dialog')){const _0xbdde47=this['editor']['plugins']['get']('Dialog');_0xbdde47['isOpen']&&_0xbdde47['hide']();}const _0x160676=this['_getRevisionViewerEditorConfig']();return _0x33f819(_0x160676)['then'](_0x6d07bf=>{return(this['_viewerEditor']=_0x6d07bf,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'),_0x6d07bf);})['catch'](_0x122322=>(console['error'](_0x122322),this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),null));});}['_enhanceCloseRevisionViewerCallback'](){const _0x5fe5f1=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'](),_0x5fe5f1(this['_viewerEditor'])['then'](()=>{if(this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),this['_viewerEditor']=null,this['editor']['plugins']['has']('Annotations')){const _0x5081c2=this['editor']['plugins']['get']('Annotations');_0x5081c2['refreshVisibility'](),_0x5081c2['refreshPositioning']();}})));}['_showRevisionViewer'](_0x42af73){const _0x19b2ff=this['editor']['config']['get']('revisionHistory.editorContainer'),_0x41bef6=this['editor']['config']['get']('revisionHistory.viewerContainer'),_0x45f63d=this['editor']['config']['get']('revisionHistory.viewerEditorElement');return w['create'](_0x45f63d,_0x42af73)['then'](_0xa4032f=>(_0x41bef6['style']['display']='block',_0x19b2ff['style']['display']='none',this['isRevisionViewerOpen']=!0x0,_0xa4032f));}['_closeRevisionViewer'](_0x5769b2){const _0x3de08a=this['editor']['config']['get']('revisionHistory.editorContainer');return this['editor']['config']['get']('revisionHistory.viewerContainer')['style']['display']='none',_0x3de08a['style']['display']='',this['isRevisionViewerOpen']=!0x1,_0x5769b2['destroy']();}async['_restoreRevision'](_0x22349c){const _0xf7e22f=this['editor'],_0x3f71f5=this['_viewerEditor']['plugins']['get']('RevisionViewer'),_0x395d84=_0xf7e22f['plugins']['get']('RevisionTracker'),_0x11e497=_0xf7e22f['plugins']['get']('RevisionHistoryUtils'),_0x26c4b8=_0x3f71f5['repository']['getRevision'](_0x22349c);let _0x457d7b,_0x5855c0,_0x2122ff;try{await _0x11e497['loadRevisionData'](_0x26c4b8,this['adapter']),_0x457d7b=_0x11e497['getRevisionDocumentData'](_0x26c4b8),_0x5855c0=_0x11e497['getRevisionRootsAttributes'](_0x26c4b8);}catch(_0x16ddd8){return void console['error'](_0x16ddd8);}_0xf7e22f['model']['change'](_0x3ad997=>{for(const _0x574d99 of Array['from'](_0xf7e22f['model']['markers']['getMarkersGroup']('restrictedEditingException')))_0x3ad997['removeMarker'](_0x574d99);}),_0x3f71f5['isReady']=!0x1,_0xf7e22f['model']['enqueueChange'](_0x45c660=>{_0x45c660['setSelection'](null),_0x45c660['removeSelectionAttribute'](_0xf7e22f['model']['document']['selection']['getAttributeKeys']());const _0x4358e9=Object['keys'](_0x457d7b);for(const _0x34b67c of _0xf7e22f['model']['document']['roots'])'$graveyard'!=_0x34b67c['rootName']&&_0x34b67c['isAttached']()&&!_0x4358e9['includes'](_0x34b67c['rootName'])&&_0x45c660['detachRoot'](_0x34b67c);for(const _0x12599f of _0x4358e9){let _0x40aaa8=_0xf7e22f['model']['document']['getRoot'](_0x12599f);_0x40aaa8&&_0x40aaa8['isAttached']()||(_0x40aaa8=_0x45c660['addRoot'](_0x12599f));const _0x2fd5c0=_0x5855c0[_0x12599f],_0x4df9c8=Object['keys'](_0x2fd5c0),_0x43c17a=_0x457d7b[_0x12599f];for(const _0x2974b9 of _0x40aaa8['getAttributeKeys']())_0x4df9c8['includes'](_0x2974b9)||_0x45c660['removeAttribute'](_0x2974b9,_0x40aaa8);for(const _0x47907f of _0x4df9c8)_0x45c660['setAttribute'](_0x47907f,_0x5855c0[_0x12599f][_0x47907f],_0x40aaa8);_0x45c660['remove'](_0x45c660['createRangeIn'](_0x40aaa8)),_0x45c660['insert'](_0xf7e22f['data']['parse'](_0x43c17a,_0x40aaa8),_0x40aaa8,0x0);}});const _0xcd5846=g(_0xf7e22f['locale'],'Restored');if(_0x26c4b8['name'])_0x2122ff=-0x1==_0x26c4b8['name']['indexOf'](_0xcd5846)?_0xcd5846+':\x20'+_0x26c4b8['name']:_0x26c4b8['name'];else _0x2122ff=_0xcd5846+':\x20'+(_0x26c4b8['createdAt']['toLocaleDateString'](_0xf7e22f['locale']['uiLanguage'],{'month':'long','day':'numeric'})+',\x20'+_0x26c4b8['createdAt']['toLocaleTimeString'](_0xf7e22f['locale']['uiLanguage'],{'hour':'numeric','minute':'numeric'}));return await _0x395d84['saveRevision']({'name':_0x2122ff}),_0x3f71f5['isReady']=!0x0,_0xf7e22f['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};
|