@ckeditor/ckeditor5-revision-history 0.0.0-nightly-20250531.0 → 0.0.0-nightly-20250601.0
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/revisionauthorview.js +1 -1
- package/src/ui/revision/revisionview.js +2 -2
- package/src/ui/revision/subrevisionview.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/changesnavigationview.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
|
-
_0x5f288e(){['id'];['creator'];['authors'];['diffData'];['toVersion'];['fromVersion'];['model'];constructor(_0x41ca87){super(),this['id']=_0x41ca87['id']||_0x46e088(),this['creator']=_0x41ca87['creator']||null,this['authors']=_0x41ca87['authors']||[],this['diffData']=_0x41ca87['diffData']||null,this['toVersion']=_0x41ca87['toVersion']||0x0,this['fromVersion']=_0x41ca87['fromVersion']||0x0,this['set']('name',_0x41ca87['name']||''),this['set']('createdAt',_0x41ca87['createdAt']||new Date()),this['set']('attributes',_0x41ca87['attributes']||{});}['setName'](_0x2001b0){this['_update']({'name':_0x2001b0});}['setAttribute'](_0x3e8359,_0x87f706){const _0x383761=_0x5a4053(this['attributes']);_0x18e45f(_0x383761,_0x3e8359,_0x87f706),this['_update']({'attributes':_0x383761});}['removeAttribute'](_0x31afc5){const _0x357cc0=_0x5a4053(this['attributes']);_0x5569ba(_0x357cc0,_0x31afc5),this['_update']({'attributes':_0x357cc0});}['_update'](_0x58aed2,_0x3d1f38=!0x1){let _0x53bc4d=!0x1;const _0x59c400={'id':this['id']},_0x1435c8=['name','createdAt','diffData','authors','attributes','toVersion','fromVersion','creatorId'];for(const _0x224574 of _0x1435c8){const _0x39c594=_0x58aed2[_0x224574];void 0x0!==_0x39c594&&_0x39c594!==this[_0x224574]&&(this[_0x224574]=_0x39c594,_0x59c400[_0x224574]=_0x39c594,_0x53bc4d=!0x0);}_0x53bc4d&&(_0x59c400['authors']&&(_0x59c400['authorsIds']=_0x59c400['authors']['map'](_0x1d343f=>_0x1d343f['id']),delete _0x59c400['authors']),this['fire']('_update',_0x59c400,_0x3d1f38));}['toJSON'](){return{'id':this['id'],'name':this['name'],'creatorId':this['creator']?this['creator']['id']:null,'authorsIds':this['authors']['map'](_0x5c428a=>_0x5c428a['id']),'diffData':this['diffData'],'createdAt':this['createdAt'],'attributes':this['attributes'],'fromVersion':this['fromVersion'],'toVersion':this['toVersion']};}}class I extends _0x3561a9{['_revisions'];static get['requires'](){return[_0x52250a];}static get['pluginName'](){return'RevisionsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['length'](){return this['_revisions']['length'];}constructor(_0x50b5c0){super(_0x50b5c0),this['_revisions']=new _0x57f501();}['afterInit'](){!async function(_0x35b1c1){const _0x2ebe63=_0x59202d([0x34,0x59,0x55,0x6d,0x78,0x39,0x6b,0x4a,0x58,0x76,0x36,0x6a,0x56,0x51,0x31,0x77,0x62,0x49,0x67,0x72,0x43,0x68,0x79,0x33,0x46,0x4c,0x37,0x57,0x47,0x66,0x73,0x4f,0x4e,0x48,0x44,0x38,0x41,0x74,0x70,0x50,0x7a,0x61,0x64,0x54,0x42,0x69,0x32,0x5a,0x4d,0x6f,0x30,0x53,0x4b,0x6c,0x52,0x45,0x6e,0x71,0x35,0x75,0x63,0x65]),_0x36c21f=0xeb829,_0x102e45=0x13188c0f,_0x261ede=0x131fe567^_0x102e45,_0x3ff7fb=window[_0x59202d([0x44,0x61,0x74,0x65])][_0x59202d([0x6e,0x6f,0x77])](),_0x17a461=_0x35b1c1[_0x59202d([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x4effec=new window[(_0x59202d([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x11558a=>{_0x17a461[_0x59202d([0x6f,0x6e,0x63,0x65])](_0x59202d([0x72,0x65,0x61,0x64,0x79]),_0x11558a);}),_0x1ce885={[_0x59202d([0x6b,0x74,0x79])]:_0x59202d([0x45,0x43]),[_0x59202d([0x75,0x73,0x65])]:_0x59202d([0x73,0x69,0x67]),[_0x59202d([0x63,0x72,0x76])]:_0x59202d([0x50,0x2d,0x32,0x35,0x36]),[_0x59202d([0x78])]:_0x59202d([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]),[_0x59202d([0x79])]:_0x59202d([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]),[_0x59202d([0x61,0x6c,0x67])]:_0x59202d([0x45,0x53,0x32,0x35,0x36])},_0x29509b=_0x17a461[_0x59202d([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x59202d([0x67,0x65,0x74])](_0x59202d([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0xc7104d(){let _0x2d76b0,_0x1278e2=null,_0x48682d=null;try{if(_0x29509b==_0x59202d([0x47,0x50,0x4c]))return _0x59202d([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x2d76b0=_0x197dd5(),!_0x2d76b0)return _0x59202d([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x2d76b0[_0x59202d([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x48682d=_0x92d37d(_0x2d76b0[_0x59202d([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x2d76b0[_0x59202d([0x6a,0x74,0x69])])),await _0x14ad0e()?_0xe67095()?_0xbad87d()?_0x59202d([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x9e4e2c()?(_0x2d76b0[_0x59202d([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x59202d([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x1278e2=_0x293adb(_0x59202d([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x2d76b0[_0x59202d([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x59202d([0x74,0x72,0x69,0x61,0x6c])&&(_0x1278e2=_0x293adb(_0x59202d([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),await _0x2ead37()):_0x59202d([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x59202d([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x59202d([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch{return _0x59202d([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0xbad87d(){const _0x5ac2f8=[_0x59202d([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x59202d([0x74,0x72,0x69,0x61,0x6c])][_0x59202d([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x2d76b0[_0x59202d([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x3ff7fb/0x3e8:0xe10*_0x261ede;return _0x2d76b0[_0x59202d([0x65,0x78,0x70])]<_0x5ac2f8;}function _0xe67095(){const _0x1a6d53=_0x2d76b0[_0x59202d([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x1a6d53)return!0x1;if(_0x1a6d53[_0x59202d([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x59202d([0x2a])))return!0x0;if(_0x1a6d53[_0x59202d([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x59202d([0x52,0x48])))return!0x0;if(_0x1a6d53[_0x59202d([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x59202d([0x52,0x52,0x48]))){if(_0x4a2817())return!0x0;if(_0x503e66()||_0x533a4d())return!0x0;}return!0x1;}function _0x9e4e2c(){const _0x59b396=_0x2d76b0[_0x59202d([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x59b396||0x0==_0x59b396[_0x59202d([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x4a01cc}=new URL(window[_0x59202d([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x59b396[_0x59202d([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x4a01cc))return!0x0;const _0x2ea678=_0x4a01cc[_0x59202d([0x73,0x70,0x6c,0x69,0x74])](_0x59202d([0x2e]));return _0x59b396[_0x59202d([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x58e299=>_0x58e299[_0x59202d([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x59202d([0x2a])))[_0x59202d([0x6d,0x61,0x70])](_0x3697f9=>_0x3697f9[_0x59202d([0x73,0x70,0x6c,0x69,0x74])](_0x59202d([0x2e])))[_0x59202d([0x73,0x6f,0x6d,0x65])](_0x3d083f=>_0x2ea678[_0x59202d([0x65,0x76,0x65,0x72,0x79])]((_0x150b5e,_0x4713e7)=>_0x3d083f[_0x4713e7]===_0x150b5e||_0x3d083f[_0x4713e7]===_0x59202d([0x2a])));}function _0x2ead37(){return _0x1278e2&&_0x48682d?new window[(_0x59202d([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x45fa1f,_0x34485c)=>{_0x1278e2[_0x59202d([0x74,0x68,0x65,0x6e])](_0x45fa1f,_0x34485c),_0x48682d[_0x59202d([0x74,0x68,0x65,0x6e])](_0x26642e=>{_0x26642e!=_0x59202d([0x56,0x61,0x6c,0x69,0x64])&&_0x45fa1f(_0x26642e);},_0x34485c);}):_0x1278e2||_0x48682d||_0x59202d([0x56,0x61,0x6c,0x69,0x64]);}}function _0x92d37d(_0x1b43a2,_0x3b11f2){return new window[(_0x59202d([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0xc68e0e=>{if(_0x536db4())return _0xc68e0e(_0x59202d([0x56,0x61,0x6c,0x69,0x64]));_0x12b690(),_0x17a461[_0x59202d([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x59202d([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x2c35fc=!0x1;const _0x5835e3=_0x46e088();function _0x4bd864(_0x3822f8){return!!_0x3822f8&&(typeof _0x3822f8===_0x59202d([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x3822f8===_0x59202d([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x3822f8[_0x59202d([0x74,0x68,0x65,0x6e])]===_0x59202d([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x3822f8[_0x59202d([0x63,0x61,0x74,0x63,0x68])]===_0x59202d([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x52197c(_0x1bc6a9){_0x3e0ad2(_0x1bc6a9)[_0x59202d([0x74,0x68,0x65,0x6e])](_0x47fb52=>{if(!_0x47fb52||_0x47fb52[_0x59202d([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x59202d([0x6f,0x6b]))return _0x59202d([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x150456(_0x57f670(_0x5835e3+_0x3b11f2))!=_0x47fb52[_0x59202d([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x59202d([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x59202d([0x56,0x61,0x6c,0x69,0x64]);})[_0x59202d([0x74,0x68,0x65,0x6e])](_0x2d1187=>(_0x38a8cb(),_0x2d1187),()=>{const _0x2b02db=_0x6efd92();return null==_0x2b02db?(_0x38a8cb(),_0x59202d([0x56,0x61,0x6c,0x69,0x64])):_0x59202d(_0x3ff7fb-_0x2b02db>(0x3714080f^_0x102e45)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x59202d([0x74,0x68,0x65,0x6e])](_0xc68e0e)[_0x59202d([0x63,0x61,0x74,0x63,0x68])](()=>{_0xc68e0e(_0x59202d([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x2b4307=0x132e628f^_0x102e45;function _0x38a8cb(){const _0xd73ff9=_0x59202d([0x6c,0x6c,0x63,0x74,0x2d])+_0x150456(_0x57f670(_0x1b43a2)),_0x431e69=_0x2249ff(_0x150456(window[_0x59202d([0x4d,0x61,0x74,0x68])][_0x59202d([0x63,0x65,0x69,0x6c])](_0x3ff7fb/_0x2b4307)));window[_0x59202d([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x59202d([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0xd73ff9,_0x431e69);}function _0x6efd92(){const _0x59001d=_0x59202d([0x6c,0x6c,0x63,0x74,0x2d])+_0x150456(_0x57f670(_0x1b43a2)),_0x176359=window[_0x59202d([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x59202d([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x59001d);return _0x176359?window[_0x59202d([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x2249ff(_0x176359),0x10)*_0x2b4307:null;}function _0x3e0ad2(_0x55f59f){return new window[(_0x59202d([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x421907,_0x39d56b)=>{_0x55f59f[_0x59202d([0x74,0x68,0x65,0x6e])](_0x421907,_0x39d56b),window[_0x59202d([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x39d56b,0x131958cf^_0x102e45);});}}_0x17a461[_0x59202d([0x6f,0x6e])](_0x59202d([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x470c11,_0x17b344)=>{if(_0x17b344[0x0]!=_0x1b43a2)return _0xc68e0e(_0x59202d([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x17b344[0x1]={..._0x17b344[0x1],[_0x59202d([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x5835e3};},{[_0x59202d([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x59202d([0x68,0x69,0x67,0x68])}),_0x17a461[_0x59202d([0x6f,0x6e])](_0x59202d([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x2f7d6f=>{_0x4bd864(_0x2f7d6f[_0x59202d([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x2c35fc=!0x0,_0x52197c(_0x2f7d6f[_0x59202d([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x59202d([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x59202d([0x6c,0x6f,0x77])}),_0x4effec[_0x59202d([0x74,0x68,0x65,0x6e])](()=>{_0x2c35fc||_0xc68e0e(_0x59202d([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x536db4(){return _0x17a461[_0x59202d([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x59202d([0x76,0x69,0x65,0x77])][_0x59202d([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x59202d([0x61,0x75,0x74,0x6f]);}function _0x12b690(){_0x17a461[_0x59202d([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x59202d([0x76,0x69,0x65,0x77])][_0x59202d([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x59202d([0x61,0x75,0x74,0x6f]);}}function _0x293adb(_0x129ac4){const _0x5200b3=[new window[(_0x59202d([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x98e8e9=>setTimeout(_0x98e8e9,0x1311b2c3^_0x102e45)),_0x4effec[_0x59202d([0x74,0x68,0x65,0x6e])](()=>new window[(_0x59202d([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x192e79=>{const _0x1f5a2c=0x13188c08^_0x102e45,_0x496dc4=_0x35b1c1[_0x59202d([0x5f,0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x73])];function _0x8d080b(){_0x496dc4[_0x59202d([0x6c,0x65,0x6e,0x67,0x74,0x68])]>=_0x1f5a2c&&_0x192e79();}_0x8d080b(),_0x496dc4[_0x59202d([0x6f,0x6e])](_0x59202d([0x61,0x64,0x64]),_0x8d080b);})),new window[(_0x59202d([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x18db00=>{function _0x1c6800(){for(const _0x4639d0 in window)if(window[_0x59202d([0x4e,0x75,0x6d,0x62,0x65,0x72])]['isNaN'](window[_0x59202d([0x4e,0x75,0x6d,0x62,0x65,0x72])](_0x4639d0))&&window[_0x4639d0]==_0x36c21f)return _0x18db00();_0x17a461[_0x59202d([0x73,0x74,0x61,0x74,0x65])]!=_0x59202d([0x64,0x65,0x73,0x74,0x72,0x6f,0x79,0x65,0x64])&&window[_0x59202d([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x1c6800,0x13189f87^_0x102e45);}_0x5f2eb1(_0x59202d([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))&&_0x1c6800();})];return window[_0x59202d([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x59202d([0x72,0x61,0x63,0x65])](_0x5200b3)[_0x59202d([0x74,0x68,0x65,0x6e])](()=>_0x129ac4);}async function _0x1fa12b(){if(await _0x4effec,_0x5f2eb1(_0x59202d([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))){const _0xec2adc=_0x35b1c1[_0x59202d([0x67,0x65,0x74,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](0x0),_0x4ca417=_0x35b1c1[_0x59202d([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])](_0xec2adc[_0x59202d([0x69,0x64])]),_0x5bce61=_0x57760f(_0x59202d([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]));return await _0x5bce61[_0x59202d([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])](_0xec2adc['id'],_0x4ca417?_0x4ca417['id']:null,!0x0),_0x5bce61[_0x59202d([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x59202d([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x5bce61[_0x59202d([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x5bce61[_0x59202d([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])]=_0x3356ec,void(_0x5bce61[_0x59202d([0x5f,0x67,0x65,0x74,0x44,0x69,0x66,0x66])]=_0x3356ec);}if(_0x5f2eb1(_0x59202d([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]))){const _0x35c683=_0x57760f(_0x59202d([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]));_0x35c683[_0x59202d([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x59202d([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x35c683[_0x59202d([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x35c683[_0x59202d([0x75,0x70,0x64,0x61,0x74,0x65])]=_0x3356ec,_0x35c683[_0x59202d([0x73,0x61,0x76,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])]=_0x3356ec;}_0x17a461[_0x59202d([0x6d,0x6f,0x64,0x65,0x6c])][_0x59202d([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x3356ec,_0x17a461[_0x59202d([0x6d,0x6f,0x64,0x65,0x6c])][_0x59202d([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x3356ec,_0x17a461[_0x59202d([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x59202d([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x4a2817(){return _0x5f2eb1(_0x59202d([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x57760f(_0x59202d([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x59202d([0x73,0x74,0x61,0x74,0x65])]==_0x59202d([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x503e66(){return _0x5f2eb1(_0x59202d([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 _0x533a4d(){return _0x5f2eb1(_0x59202d([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0x1fd1df(_0x1325d1){const _0x4b2cf2=_0x2408c7();_0x17a461[_0x4b2cf2]=_0x59202d([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])+_0x1325d1,_0x1325d1[_0x59202d([0x65,0x6e,0x64,0x73,0x57,0x69,0x74,0x68])](_0x59202d([0x4c,0x69,0x6d,0x69,0x74]))&&(window[_0x2408c7()]=_0x36c21f),_0x1325d1!=_0x59202d([0x56,0x61,0x6c,0x69,0x64])&&_0x1fa12b();}function _0x2408c7(){const _0xbd4f99=window[_0x59202d([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x59202d([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x59202d([0x6e,0x6f,0x77])]())[_0x59202d([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x59202d([0x2e]),'');let _0x511f81=_0x59202d([0x59]);for(let _0xbed6f5=0x0;_0xbed6f5<_0xbd4f99[_0x59202d([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0xbed6f5+=0x2){let _0x1b7874=window[_0x59202d([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0xbd4f99[_0x59202d([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0xbed6f5,_0xbed6f5+0x2));_0x1b7874>=_0x2ebe63[_0x59202d([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x1b7874-=_0x2ebe63[_0x59202d([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x511f81+=_0x2ebe63[_0x1b7874];}return _0x511f81;}function _0x197dd5(){const _0x343d2d=_0x29509b[_0x59202d([0x73,0x70,0x6c,0x69,0x74])](_0x59202d([0x2e]));if(0x3!=_0x343d2d[_0x59202d([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x211b43(_0x343d2d[0x1]);function _0x211b43(_0x40eeb2){const _0x2e4c26=_0xcfab67(_0x40eeb2);return _0x2e4c26&&_0x374abe()?_0x2e4c26:null;function _0x374abe(){const _0x492c3d=_0x2e4c26[_0x59202d([0x6a,0x74,0x69])],_0x2ae2f4=window[_0x59202d([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x492c3d[_0x59202d([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x492c3d[_0x59202d([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x1048fb={..._0x2e4c26,[_0x59202d([0x6a,0x74,0x69])]:_0x492c3d[_0x59202d([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x492c3d[_0x59202d([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x1048fb[_0x59202d([0x76,0x63])],_0x57f670(_0x1048fb)==_0x2ae2f4;}}}async function _0x14ad0e(){let _0x982ae=!0x0;try{const _0x11a678=_0x29509b[_0x59202d([0x73,0x70,0x6c,0x69,0x74])](_0x59202d([0x2e])),[_0x25421d,_0xe56f93,_0xdfb3b0]=_0x11a678;return _0x4635d4(_0x25421d),await _0x189bfa(_0x25421d,_0xe56f93,_0xdfb3b0),_0x982ae;}catch{return!0x1;}function _0x4635d4(_0x4eac1f){const _0x31339b=_0xcfab67(_0x4eac1f);_0x31339b&&_0x31339b[_0x59202d([0x61,0x6c,0x67])]==_0x59202d([0x45,0x53,0x32,0x35,0x36])||(_0x982ae=!0x1);}async function _0x189bfa(_0x18dbfb,_0x3b0fb9,_0x4460aa){const _0x5198c3=window[_0x59202d([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x59202d([0x66,0x72,0x6f,0x6d])](_0x28fc27(_0x4460aa),_0x3fed4b=>_0x3fed4b[_0x59202d([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0xe2bd31=new window[(_0x59202d([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x59202d([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x18dbfb+_0x59202d([0x2e])+_0x3b0fb9),_0x281405=window[_0x59202d([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x59202d([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x281405)return;const _0x1f28e1=await _0x281405[_0x59202d([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x59202d([0x6a,0x77,0x6b]),_0x1ce885,{[_0x59202d([0x6e,0x61,0x6d,0x65])]:_0x59202d([0x45,0x43,0x44,0x53,0x41]),[_0x59202d([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x59202d([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x59202d([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x281405[_0x59202d([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x59202d([0x6e,0x61,0x6d,0x65])]:_0x59202d([0x45,0x43,0x44,0x53,0x41]),[_0x59202d([0x68,0x61,0x73,0x68])]:{[_0x59202d([0x6e,0x61,0x6d,0x65])]:_0x59202d([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x1f28e1,_0x5198c3,_0xe2bd31)||(_0x982ae=!0x1);}}function _0xcfab67(_0x51ff8b){return _0x51ff8b[_0x59202d([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x59202d([0x65,0x79]))?JSON[_0x59202d([0x70,0x61,0x72,0x73,0x65])](_0x28fc27(_0x51ff8b)):null;}function _0x28fc27(_0x48e3df){return window[_0x59202d([0x61,0x74,0x6f,0x62])](_0x48e3df[_0x59202d([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x59202d([0x2b]))[_0x59202d([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x59202d([0x2f])));}function _0x57f670(_0x5b728b){let _0x39cee3=0x1505;function _0x5f5490(_0x532bfc){for(let _0x508c66=0x0;_0x508c66<_0x532bfc[_0x59202d([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x508c66++){const _0x3b6042=_0x532bfc[_0x59202d([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x508c66);_0x39cee3=(_0x39cee3<<0x5)+_0x39cee3+_0x3b6042,_0x39cee3&=_0x39cee3;}}function _0x5bd46f(_0x340f5e){Array[_0x59202d([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x340f5e)?_0x340f5e[_0x59202d([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x5bd46f):_0x340f5e&&typeof _0x340f5e==_0x59202d([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x59202d([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x340f5e)[_0x59202d([0x73,0x6f,0x72,0x74])]()[_0x59202d([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x1a0e93,_0x5d0270])=>{_0x5f5490(_0x1a0e93),_0x5bd46f(_0x5d0270);}):_0x5f5490(window[_0x59202d([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x340f5e));}return _0x5bd46f(_0x5b728b),_0x39cee3>>>0x0;}function _0x150456(_0x5d99f3){return _0x5d99f3[_0x59202d([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x59202d([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x59202d([0x30]));}function _0x2249ff(_0xd8a8b1){return _0xd8a8b1[_0x59202d([0x73,0x70,0x6c,0x69,0x74])]('')[_0x59202d([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x59202d([0x6a,0x6f,0x69,0x6e])]('');}function _0x5f2eb1(_0x1d0dc0){return _0x17a461[_0x59202d([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x59202d([0x68,0x61,0x73])](_0x1d0dc0);}function _0x57760f(_0x8767c7){return _0x17a461[_0x59202d([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x59202d([0x67,0x65,0x74])](_0x8767c7);}function _0x3356ec(){}function _0x59202d(_0x341868){return _0x341868['map'](_0x238464=>String['fromCharCode'](_0x238464))['join']('');}_0x1fd1df(await _0xc7104d());}(this);}['createRevision'](_0x5e95ee){const _0x281830=this['editor']['plugins']['get']('Users');return new h({'id':_0x5e95ee['id'],'name':_0x5e95ee['name'],'creator':_0x5e95ee['creatorId']?_0x281830['getUser'](_0x5e95ee['creatorId']):null,'diffData':_0x5e95ee['diffData']||_0x5e95ee['data'],'authors':_0x5e95ee['authorsIds']['map'](_0xd26b24=>_0x281830['getUser'](_0xd26b24)),'createdAt':new Date(_0x5e95ee['createdAt']),'attributes':_0x5e95ee['attributes'],'fromVersion':_0x5e95ee['fromVersion'],'toVersion':_0x5e95ee['toVersion']});}['addRevision'](_0x536dcb,_0x375367=0x0){this['_revisions']['add'](_0x536dcb,_0x375367);}['getRevision'](_0x15a86a){return this['_revisions']['get'](_0x15a86a);}['getRevisions'](_0x14ddae={'toJSON':!0x1}){const _0x1f89a1=Array['from'](this['_revisions']);return _0x1f89a1['reverse'](),_0x14ddae['toJSON']?_0x1f89a1['map'](_0x241167=>_0x241167['toJSON']()):_0x1f89a1;}['getIndex'](_0xe47485){return this['_revisions']['getIndex'](_0xe47485);}['getEarlierVisibleRevision'](_0x57b6c8){const [,_0x17fd23]=this['getRevisionsIterator'](_0x57b6c8,{'direction':'earlier'});return _0x17fd23;}['getLaterVisibleRevision'](_0x137366){const [,_0x5d2ec8]=this['getRevisionsIterator'](_0x137366,{'direction':'later'});return _0x5d2ec8;}['getRevisionsInDiff'](_0x2a91eb){const _0xa6f87=[];for(const _0x31ebf9 of this['getRevisionsIterator'](_0x2a91eb['newRevisionId']))if(_0xa6f87['push'](_0x31ebf9),_0x31ebf9['id']===_0x2a91eb['oldRevisionId'])break;return _0xa6f87;}*['getRevisionsIterator'](_0x30caf1,{direction:_0x2ee3c2='earlier',filter:_0x5ad959=()=>!0x0}={}){const _0x3ef19e='earlier'===_0x2ee3c2?0x1:-0x1;let _0x543121=this['_revisions']['get'](_0x30caf1),_0x32d02f=this['getIndex'](_0x543121);for(yield _0x543121;_0x543121;){if(_0x32d02f+=_0x3ef19e,_0x543121=this['getRevision'](_0x32d02f),!_0x543121)return;_0x5ad959(_0x543121)&&(yield _0x543121);}}}class V extends _0x3561a9{static get['pluginName'](){return'RevisionHistoryUtils';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['_viewClassToTypeChar']=new Map([[_0xf611b4,'c'],[_0x1649f7,'a'],[_0x452815,'e'],[_0x4a5f60,'r'],[_0x1319de,'u']]);['_typeCharToViewClass']=new Map([['c',_0xf611b4],['a',_0x1649f7],['e',_0x452815],['r',_0x4a5f60],['u',_0x1319de]]);async['loadRevisionData'](_0x53a601,_0x3520ef){if(_0x53a601['diffData']||!_0x3520ef)return;const _0x40ada7=this['editor']['config']['get']('collaboration.channelId'),_0xdc028e=await _0x3520ef['getRevision']({'channelId':_0x40ada7,'revisionId':_0x53a601['id']});_0x53a601['diffData']=_0xdc028e['diffData'];}['getRevisionDocumentData'](_0x5de66c){const _0x47f999={};for(const _0x3ccc90 in _0x5de66c['diffData']){if(_0x5de66c['diffData'][_0x3ccc90]['attachChange']&&!_0x5de66c['diffData'][_0x3ccc90]['attachChange']['isAttached'])continue;const _0xf55482=this['_removeRevisionMarkers'](JSON['parse'](_0x5de66c['diffData'][_0x3ccc90]['insertions'])),_0x286fca=this['editor']['editing']['view']['document'],_0x33f0b6=new _0x1a87c7(_0x286fca,_0xf55482['map'](_0x10e3df=>this['_getViewFromDiffObj'](_0x10e3df,!0x1)));this['editor']['data']['processor']['useFillerType']('marked'),_0x47f999[_0x3ccc90]=this['editor']['data']['processor']['toData'](_0x33f0b6),this['editor']['data']['processor']['useFillerType']('default');}return _0x47f999;}['getRevisionRootsAttributes'](_0x42c70c){const _0x5f1ada={};for(const _0x5a02a9 in _0x42c70c['diffData'])_0x42c70c['diffData'][_0x5a02a9]['attachChange']&&!_0x42c70c['diffData'][_0x5a02a9]['attachChange']['isAttached']||(_0x5f1ada[_0x5a02a9]=_0x42c70c['diffData'][_0x5a02a9]['attributesAfter']||{});return _0x5f1ada;}['_getTypeCharForViewElement'](_0x15c51b){return this['_viewClassToTypeChar']['get'](_0x15c51b['constructor']);}['_getViewFromDiffObj'](_0x55a632,_0x29003b){const _0xd216c0=this['editor']['editing']['view']['document'];if('string'==typeof _0x55a632)return new _0xdc1125(_0xd216c0,_0x55a632);{let _0x367724,_0x3b91ab;_0x3b91ab='u'==_0x55a632['type']||'r'==_0x55a632['type']?[]:_0x55a632['children']['map'](_0x21fdf5=>this['_getViewFromDiffObj'](_0x21fdf5,_0x29003b));const _0x479810=this['_typeCharToViewClass']['get'](_0x55a632['type'])||_0x503839,_0x5664e8=this['editor']['data']['htmlProcessor']['domConverter'];if(_0x367724=new _0x479810(_0xd216c0,_0x55a632['name'],_0x55a632['attributes'],_0x3b91ab),'u'==_0x55a632['type']&&_0x55a632['children'][0x0]){const _0x533584=_0x55a632['children'][0x0];if(_0x367724['render']=function(_0x5de1ce){const _0x6888c0=_0x5de1ce['createElement']('div');return _0x6888c0['innerHTML']=_0x533584,_0x6888c0['childNodes'][0x0];},_0x29003b){const _0x3324ae=new _0x1a87c7(_0xd216c0);_0x3324ae['_appendChild'](_0x367724);const _0x5b755d=Array['from'](_0x5664e8['viewChildrenToDom'](_0x3324ae,{'bind':!0x1})),_0x37f0d0=_0x5664e8['domDocument']['createElement']('div');_0x37f0d0['append'](..._0x5b755d),_0x367724=Array['from'](_0x5664e8['domChildrenToView'](_0x37f0d0))[0x0];}}else{if('r'==_0x55a632['type']&&_0x55a632['children'][0x0]){const _0x5a7d9d=_0x55a632['children'][0x0];if(_0x367724['render']=function(_0x1402c9){_0x1402c9['innerHTML']=_0x5a7d9d;},_0x29003b){const _0x14be2b=new _0x1a87c7(_0xd216c0);_0x14be2b['_appendChild'](_0x367724);const _0x132c8f=Array['from'](_0x5664e8['viewChildrenToDom'](_0x14be2b,{'bind':!0x1})),_0x277b9e=_0x5664e8['domDocument']['createElement']('div');_0x277b9e['append'](..._0x132c8f);const _0x4716f9=Array['from'](_0x5664e8['domChildrenToView'](_0x277b9e));_0x4716f9['length']>0x1?_0x367724['_appendChild'](_0x4716f9):_0x367724=_0x4716f9[0x0];}}}if(_0x55a632['customProperties']){for(const [_0x1b1a54,_0x4101d2]of _0x55a632['customProperties'])_0x367724['_setCustomProperty'](_0x1b1a54,_0x4101d2);}const _0x4c621e=void 0x0===_0x55a632['fillerOffset']?null:_0x55a632['fillerOffset'];return null!==_0x4c621e&&(_0x367724['getFillerOffset']=()=>_0x4c621e),_0x367724;}}['_makeModelFromViewString'](_0x3d7e1a){const _0x2330f2=JSON['parse'](_0x3d7e1a),_0x401a14=this['editor']['editing']['view']['document'],_0x3d1205=new _0x1a87c7(_0x401a14,_0x2330f2['map'](_0x550a2a=>this['_getViewFromDiffObj'](_0x550a2a,!0x0)));return this['editor']['data']['toModel'](_0x3d1205);}['_removeRevisionMarkers'](_0x6a9fbc){return(_0x6a9fbc=_0x6a9fbc['filter'](_0x18e5e4=>!_0x18e5e4['name']||'revision-start'!==_0x18e5e4['name']&&'revision-end'!==_0x18e5e4['name']))['forEach'](_0x3952d7=>{'string'!=typeof _0x3952d7&&(_0x3952d7['children']=this['_removeRevisionMarkers'](_0x3952d7['children']),_0x3952d7['attributes']=_0x3952d7['attributes']['filter'](_0x4bed50=>!_0x4bed50[0x0]['startsWith']('data-revision-')));}),_0x6a9fbc;}}function g(_0x2eb519,_0x1016cc,_0x341ca4){const t=_0x2eb519['t'];switch(_0x1016cc){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'},_0x341ca4);case'X_OF_Y_CHANGES':return t({'string':'%0\x20of\x20%1','id':'X_OF_Y_CHANGES'},_0x341ca4);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 _0x3561a9{['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[_0x52250a,I,V,_0x18c9a5];}constructor(_0x543df4){super(_0x543df4),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 _0x31c124=_0x46e088();this['_source']={'history':this['editor']['model']['document']['history'],'getLatestVersion':()=>Promise['resolve'](this['editor']['model']['document']['version']),'getCurrentRevisionId':()=>_0x31c124},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 _0x45e823=this['repository']['getRevision'](0x0),_0x5d6b20=_0x45e823&&null===_0x45e823['creator']?_0x45e823:null;if(this['_continueCurrentRevision']=!!_0x5d6b20&&this['editor']['config']['get']('revisionHistory.resumeUnsavedRevision'),this['editor']['plugins']['has']('RealTimeCollaborationClient')){const _0x4c8f9f=this['_source']['getCurrentRevisionId'](),_0x437638=this['repository']['getRevision'](_0x4c8f9f);if(_0x437638)this['_startingVersion']=_0x437638['fromVersion'],this['_continueCurrentRevision']=!0x1;else{const _0x4f00cc=this['_source']['history']['_operations']['find'](_0x99d00a=>!_0x99d00a['_isInit']),_0x397ef5=_0x4f00cc?_0x4f00cc['baseVersion']:this['_source']['history']['version'];_0x45e823?(_0x45e823['toVersion']<_0x397ef5&&_0x45e823['_update']({'toVersion':_0x397ef5}),this['_continueCurrentRevision']?(this['_source']['getCurrentRevisionId']=()=>_0x5d6b20['id'],this['_startingVersion']=_0x5d6b20['fromVersion']):(this['_startingVersion']=_0x45e823['toVersion'],this['_continueCurrentRevision']=!0x1)):(this['_startingVersion']=_0x397ef5,this['_continueCurrentRevision']=!0x1);}}else _0x5d6b20&&(this['editor']['model']['document']['history']['version']=Math['max'](_0x5d6b20['toVersion'],this['editor']['model']['document']['history']['version']),_0x5d6b20['fromVersion']===_0x5d6b20['toVersion']?(0x0!==_0x5d6b20['fromVersion']&&(this['_source']['getCurrentRevisionId']=()=>_0x5d6b20['id']),this['_continueCurrentRevision']=!0x1):this['_continueCurrentRevision']&&(this['_source']['getCurrentRevisionId']=()=>_0x5d6b20['id'],this['_startingVersion']=_0x5d6b20['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',_0x1d4120=>!_0x1d4120),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0xb12d27=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x412b80;for(const _0x40455b in _0xb12d27){const _0x59fb5c=_0x40455b,_0x1feecd=_0xb12d27[_0x59fb5c];if('revisionHistoryLicenseKeyValid'==_0x1feecd||'revisionHistoryLicenseKeyInvalid'==_0x1feecd||'revisionHistoryLicenseKeyExpired'==_0x1feecd||'revisionHistoryLicenseKeyDomainLimit'==_0x1feecd||'revisionHistoryLicenseKeyNotAllowed'==_0x1feecd||'revisionHistoryLicenseKeyEvaluationLimit'==_0x1feecd||'revisionHistoryLicenseKeyTrialLimit'==_0x1feecd||'revisionHistoryLicenseKeyUsageLimit'==_0x1feecd){delete _0xb12d27[_0x59fb5c],_0x412b80=_0x1feecd,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'revisionHistoryLicenseKeyInvalid'==_0x412b80&&_0xb12d27['_showLicenseError']('invalid'),'revisionHistoryLicenseKeyExpired'==_0x412b80&&_0xb12d27['_showLicenseError']('expired'),'revisionHistoryLicenseKeyDomainLimit'==_0x412b80&&_0xb12d27['_showLicenseError']('domainLimit'),'revisionHistoryLicenseKeyNotAllowed'==_0x412b80&&_0xb12d27['_showLicenseError']('featureNotAllowed','RevisionHistory'),'revisionHistoryLicenseKeyEvaluationLimit'==_0x412b80&&_0xb12d27['_showLicenseError']('evaluationLimit'),'revisionHistoryLicenseKeyTrialLimit'==_0x412b80&&_0xb12d27['_showLicenseError']('trialLimit'),'revisionHistoryLicenseKeyUsageLimit'==_0x412b80&&_0xb12d27['_showLicenseError']('usageLimit');},0x3e8);}async['afterInit'](){if(this['repository']['length']>0x0){const _0x289e95=this['repository']['getRevision'](0x0),_0x3cad6b=await this['getRevisionDocumentData'](_0x289e95),_0x54e243=await this['getRevisionRootsAttributes'](_0x289e95);this['_replaceEditorDataWithRevisionData'](_0x3cad6b,_0x54e243);}}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['setSource'](_0x1b2c0f){this['_source']=_0x1b2c0f;}async['update'](){const _0x1acea0=await this['_source']['getLatestVersion']();if(_0x1acea0>this['currentRevision']['toVersion']){await this['_loadState']();const _0x32d373=this['buildRevisionData']({'revision':this['currentRevision'],'to':_0x1acea0});_0x32d373['authors']=_0x32d373['authorsIds']['map'](_0xc62fe=>this['editor']['plugins']['get']('Users')['getUser'](_0xc62fe)),this['currentRevision']['_update'](_0x32d373);}}async['saveRevision'](_0x11adfe={},_0x2b7d97=null){const _0x429fc0=[];await this['_loadState'](),this['_continueCurrentRevision']=!0x1,_0x2b7d97>this['currentRevision']['toVersion']&&(_0x2b7d97=null),null===_0x2b7d97&&(_0x2b7d97=await this['_source']['getLatestVersion']());const _0x1f5923=this['_getFromVersion'](_0x2b7d97),_0x48d0c1=this['buildRevisionData']({'from':_0x1f5923,'to':_0x2b7d97});if(this['currentRevision']['toVersion']<_0x2b7d97){const _0x487762=this['buildRevisionData']({'revision':this['currentRevision'],'from':_0x2b7d97,'to':_0x2b7d97});_0x487762['authors']=[],_0x487762['authorsIds']=[],_0x487762['id']=this['currentRevision']['id'],this['currentRevision']['_update'](_0x487762,!0x0),delete _0x487762['authors'],_0x429fc0['push'](_0x487762);}_0x11adfe['creatorId']=this['editor']['plugins']['get']('Users')['me']['id'],_0x11adfe['name']=_0x11adfe['name']||null,_0x11adfe['id']=_0x11adfe['id']||_0x46e088(),_0x11adfe={..._0x11adfe,..._0x48d0c1};const _0x2fcc58=this['addRevisionData'](_0x11adfe);_0x429fc0['push'](_0x11adfe);const _0x152ce2=this['repository']['getIndex'](_0x2fcc58);if(0x0!==_0x152ce2){const _0xff1b0e=this['repository']['getRevision'](_0x152ce2-0x1);if(_0xff1b0e['fromVersion']!==_0x2b7d97){const _0x415974=this['_revisionDataBuilder']['getData'](_0x2b7d97,_0xff1b0e['toVersion']),_0x5016db={'id':_0xff1b0e['id'],'diffData':_0x415974['diffData'],'authorsIds':_0x415974['authorsIds'],'authors':_0x415974['authorsIds']['map'](_0x2e1047=>this['editor']['plugins']['get']('Users')['getUser'](_0x2e1047)),'fromVersion':_0x2b7d97};_0xff1b0e===this['currentRevision']&&(_0x5016db['createdAt']=new Date(_0x11adfe['createdAt']['getTime']()+0xa)),_0xff1b0e['_update'](_0x5016db,!0x0),delete _0x5016db['authors'],_0x429fc0['push'](_0x5016db);}}if(this['adapter']){for(const _0x2fd9d7 of _0x429fc0)this['_bufferUpdate'](_0x2fd9d7['id'],_0x2fd9d7,!0x0);this['sendBufferedUpdates']();}return _0x2fcc58;}['addRevisionData'](_0x2f3855){const _0x40b506=this['repository']['createRevision'](_0x2f3855);return this['adapter']&&_0x40b506['on']('_update',(_0x2bf7ee,_0x1818ca,_0x2e8bd9)=>{_0x2e8bd9||(this['_bufferUpdate'](_0x1818ca['id'],_0x1818ca,!0x0),this['sendBufferedUpdates']());}),this['repository']['addRevision'](_0x40b506,this['_findInsertionIndex'](_0x40b506)),_0x40b506;}async['getRevisionDocumentData'](_0x28d4de){return await this['_utils']['loadRevisionData'](_0x28d4de,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x28d4de);}async['getRevisionRootsAttributes'](_0x41f844){return await this['_utils']['loadRevisionData'](_0x41f844,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x41f844);}['sendBufferedUpdates'](){if(0x0===this['_bufferedUpdates']['size'])return;if(this['_isPendingUpdate'])return;let _0x243305=Array['from'](this['_bufferedUpdates']['values']());this['_bufferedUpdates']['clear']();for(let _0xc7e2fc=0x0;_0xc7e2fc<_0x243305['length'];_0xc7e2fc++){const _0x3ca0e5=_0x243305[_0xc7e2fc];let _0x543b6d=!0x1;for(const _0x144b11 of Object['keys'](_0x3ca0e5))void 0x0===_0x3ca0e5[_0x144b11]?delete _0x3ca0e5[_0x144b11]:'id'!==_0x144b11&&(_0x543b6d=!0x0);_0x543b6d||(_0x243305[_0xc7e2fc]=null);}if(_0x243305=_0x243305['filter'](_0x54f26c=>null!==_0x54f26c),!_0x243305['length'])return;for(let _0x47bf71=0x0;_0x47bf71<_0x243305['length'];_0x47bf71++){const _0x6ef2c6=_0x243305[_0x47bf71];void 0x0!==_0x6ef2c6['fromVersion']&&void 0x0===_0x6ef2c6['toVersion']&&(_0x6ef2c6['toVersion']=this['repository']['getRevision'](_0x6ef2c6['id'])['toVersion']),void 0x0!==_0x6ef2c6['toVersion']&&void 0x0===_0x6ef2c6['fromVersion']&&(_0x6ef2c6['fromVersion']=this['repository']['getRevision'](_0x6ef2c6['id'])['fromVersion']);}const _0x13b142=this['editor']['config']['get']('collaboration.channelId');this['_isPendingUpdate']=!0x0,this['_addPendingAction'](),this['adapter']['updateRevisions'](_0x243305,_0x13b142)['finally'](()=>{this['_isPendingUpdate']=!0x1;})['then'](_0x57658e=>{if(_0x57658e){for(const _0x2ff8a9 of _0x57658e)this['setRevisionData']({'id':_0x2ff8a9['id'],'createdAt':_0x2ff8a9['createdAt']});}this['_removePendingAction'](),this['sendBufferedUpdates']();});}['buildRevisionData']({revision:_0xccdd3f=null,from:_0x48376e=null,to:_0x278ddf=null}){_0x48376e=null!==_0x48376e?_0x48376e:_0xccdd3f['fromVersion'],_0x278ddf=null!==_0x278ddf?_0x278ddf:_0xccdd3f['toVersion'];const _0x16496b=this['_revisionDataBuilder']['getData'](_0x48376e,_0x278ddf),_0x10563b={'diffData':_0x16496b['diffData'],'authorsIds':_0x16496b['authorsIds'],'fromVersion':_0x48376e,'toVersion':_0x278ddf};if(!_0xccdd3f||_0x278ddf!==_0xccdd3f['toVersion']){const _0x659c1e=_0x278ddf-0x1,_0x1fd713=this['_source']['history']['getOperation'](_0x659c1e);_0x10563b['createdAt']=_0x1fd713&&_0x1fd713['createdAt']||new Date();}if(this['_loadedStateData']&&_0x48376e===this['_loadedStateData']['fromVersion']){for(const _0x267921 of this['_loadedStateData']['authors'])_0x10563b['authorsIds']['includes'](_0x267921['id'])||_0x10563b['authorsIds']['push'](_0x267921['id']);}return _0x10563b;}['_bufferUpdate'](_0x25c7f3,_0x46cc1b,_0x334d19){if(this['_bufferedUpdates']['has'](_0x25c7f3)){const _0x1c2a53=this['_bufferedUpdates']['get'](_0x25c7f3);_0x46cc1b=_0x334d19?{..._0x1c2a53,..._0x46cc1b}:{..._0x46cc1b,..._0x1c2a53};}this['_bufferedUpdates']['set'](_0x25c7f3,_0x46cc1b);}['setRevisionData'](_0x24f9f2){const _0x395919=this['repository']['getRevision'](_0x24f9f2['id']);if(_0x24f9f2['createdAt']&&(_0x24f9f2['createdAt']=new Date(_0x24f9f2['createdAt'])),_0x24f9f2['authorsIds']){const _0x262a39=this['editor']['plugins']['get']('Users');_0x24f9f2['authors']=_0x24f9f2['authorsIds']['map'](_0x3c5751=>_0x262a39['getUser'](_0x3c5751));}_0x395919['_update'](_0x24f9f2,!0x0);}['_createInitialRevision'](_0x56ebe5){const _0x1c4285=this['repository']['getRevision'](this['repository']['length']-0x1);if(_0x1c4285)this['_initialRevisionId']=_0x1c4285['id'];else{const _0x466208=!this['editor']['model']['document']['roots']['find'](_0x1582e4=>this['editor']['model']['hasContent'](_0x1582e4)),_0x4a4dcc=this['editor']['plugins']['get']('Users')['me']['id'],_0x33f1f5=g(this['editor']['locale'],_0x466208?'Empty\x20document':'Initial\x20revision');this['_makeRevision']({'from':_0x56ebe5,'to':_0x56ebe5,'id':this['_initialRevisionId'],'name':_0x33f1f5,'creatorId':_0x4a4dcc});}}['_createCurrentRevision'](_0x4a75b0){const _0x1fc95b=this['_source']['getCurrentRevisionId']();this['currentRevision']=this['repository']['getRevision'](_0x1fc95b),this['currentRevision']||(this['currentRevision']=this['_makeRevision']({'from':_0x4a75b0,'to':_0x4a75b0,'id':_0x1fc95b,'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'](_0x129dd9,_0x3767d5){let _0x1d89b1=this['editor']['config']['get']('initialData'),_0x595651=this['editor']['config']['get']('rootsAttributes');if(void 0x0===_0x1d89b1){_0x1d89b1={};for(const _0x2a48ee of this['editor']['model']['document']['getRootNames']())_0x1d89b1[_0x2a48ee]='';}if('string'==typeof _0x1d89b1&&(_0x1d89b1={'main':_0x1d89b1}),void 0x0===_0x595651){_0x595651={};for(const _0x193ca6 of this['editor']['model']['document']['getRootNames']())_0x595651[_0x193ca6]={};}let _0x50960f=!0x1;const _0x178c93=Object['keys'](_0x1d89b1),_0x4f3eb1=Object['keys'](_0x129dd9);for(const _0x1c294b of _0x178c93){if(_0x1d89b1[_0x1c294b]!==_0x129dd9[_0x1c294b]&&''!==_0x1d89b1[_0x1c294b]['trim']()){_0x50960f=!0x0;break;}if(!_0x27710b(_0x595651[_0x1c294b],_0x3767d5[_0x1c294b])&&Object['keys'](_0x595651[_0x1c294b])['length']>0x0){_0x50960f=!0x0;break;}}_0x50960f||(_0x50960f=_0x4f3eb1['some'](_0x1bf130=>!this['editor']['model']['document']['getRoot'](_0x1bf130))),_0x50960f&&_0x5a021b('editor-initial-data-replaced-with-revision-data',{'editorData':_0x1d89b1,'editorRootsAttributes':_0x595651,'revisionData':_0x129dd9,'revisionRootsAttributes':_0x3767d5}),this['editor']['config']['set']('initialData',_0x129dd9),this['editor']['config']['set']('rootsAttributes',_0x3767d5);}['_addPendingAction'](){if(!this['_pendingAction']){const _0x5b5897=this['editor']['plugins']['get']('PendingActions');this['_pendingAction']=_0x5b5897['add'](g(this['editor']['locale'],'PENDING_ACTION_REVISION_HISTORY'));}}['_removePendingAction'](){this['_pendingAction']&&(this['editor']['plugins']['get']('PendingActions')['remove'](this['_pendingAction']),this['_pendingAction']=null);}['_findInsertionIndex'](_0x24ebae){const _0x19e049=this['repository']['getRevisions']();_0x19e049['reverse']();let _0x2b7639=0x0;for(;_0x2b7639<_0x19e049['length'];){const _0x18cfa0=_0x19e049[_0x2b7639];if(_0x18cfa0===this['currentRevision']){_0x2b7639++;continue;}if(_0x18cfa0['id']===this['_initialRevisionId'])break;const _0x9aeea9=_0x24ebae['toVersion']-_0x18cfa0['toVersion']||_0x24ebae['fromVersion']-_0x18cfa0['fromVersion'];if(_0x9aeea9>0x0)break;if(_0x9aeea9<0x0)_0x2b7639++;else{if(!_0x24ebae['creator']&&_0x18cfa0['creator'])break;if(_0x18cfa0['creator']||!_0x24ebae['creator']){if(_0x24ebae['createdAt']>_0x18cfa0['createdAt'])break;_0x2b7639++;}else _0x2b7639++;}}return _0x2b7639;}['_getFromVersion'](_0x5cd756){const _0x346901=this['repository']['getRevisions']();_0x346901['reverse'](),_0x346901['shift']();const _0x1939f7=_0x346901['find'](_0x22e2f4=>_0x22e2f4['toVersion']<=_0x5cd756)['toVersion'];return _0x1939f7<this['_startingVersion']?this['_startingVersion']:_0x1939f7;}['_makeRevision']({name:_0x58038c,from:_0x2335cb,to:_0x174f66,creatorId:_0x5e7e7e,id:_0x39fef9}){const _0x14fab6=this['buildRevisionData']({'from':_0x2335cb,'to':_0x174f66});_0x14fab6['name']=_0x58038c,_0x14fab6['creatorId']=_0x5e7e7e,_0x14fab6['id']=_0x39fef9;const _0x7ede0d=this['addRevisionData'](_0x14fab6);return this['adapter']&&this['_bufferUpdate'](_0x14fab6['id'],_0x14fab6,!0x0),_0x7ede0d;}['_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(_0x39d761){this['editor']=_0x39d761,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'](_0x3b9daa){this['source']=_0x3b9daa;const _0x46e2dd=new Map(),_0x4f5610=new Map(),_0x237365=this['editor']['model']['document']['roots']['map'](_0x3675e6=>_0x3675e6['rootName']);for(const _0x3e6297 of _0x237365){const _0x35d8b7=this['editor']['model']['document']['getRoot'](_0x3e6297),_0x4cfedb=N(_0x35d8b7);_0x46e2dd['set'](_0x3e6297,_0x4cfedb),_0x4f5610['set'](_0x3e6297,Object['fromEntries'](_0x35d8b7['getAttributes']()));}const _0x2ef601=Array['from'](this['editor']['model']['markers'])['map'](_0x1f5bac=>[_0x1f5bac['name'],_0x1f5bac['getRange']()]),_0x4292a4=this['source']['version'];this['_saveMetaData'](_0x4292a4,_0x46e2dd,_0x2ef601,_0x4f5610),this['_startingRevisionId']=this['_revisionId'];const _0x3a725b=new Map(),_0x304c31=new Map();for(const _0x4e9a23 of _0x237365){const _0x26c0d1=P(_0x4e9a23);_0x3a725b['set'](_0x4e9a23,_0x26c0d1),_0x304c31['set'](_0x4e9a23,{});}this['_saveMetaData'](Number['NEGATIVE_INFINITY'],_0x3a725b,[],_0x304c31);}['getData'](_0x812c4f,_0x58b70c){if(this['_lastFrom']===_0x812c4f&&this['_lastTo']<=_0x58b70c)this['_savedMetaData']['size']>0x1&&this['_removeMetaData'](this['_lastTo']),this['_applyOperations'](this['_lastTo'],_0x58b70c,!0x0);else{if(!this['_savedMetaData']['has'](_0x812c4f)){const _0x18c168=this['_getPreviousFrom'](_0x812c4f);this['_calculateMetaData'](_0x18c168,_0x812c4f,!0x1);}this['_calculateMetaData'](_0x812c4f,_0x58b70c,!0x0);}return this['_lastFrom']=_0x812c4f,this['_lastTo']=_0x58b70c,this['_getState']();}['loadState'](_0x5e0868){const _0x2d442b=this['editor']['plugins']['get']('RevisionHistoryUtils');this['_reset'](),this['_lastFrom']=_0x5e0868['fromVersion'],this['_lastTo']=_0x5e0868['toVersion'];for(const _0x5e0859 in _0x5e0868['diffData']){const _0x245151=_0x5e0868['diffData'][_0x5e0859]['attachChange'],_0x1058d8=_0x5a4053(_0x5e0868['diffData'][_0x5e0859]['attributesBefore'])||{},_0x18f485=_0x2d442b['_makeModelFromViewString'](_0x5e0868['diffData'][_0x5e0859]['deletions']);_0x18f485['rootName']=_0x5e0859,_0x18f485['_isAttached']=!_0x245151||!_0x245151['isAttached'],_0x18f485['isAttached']=()=>_0x18f485['_isAttached'],this['_baseRoots']['set'](_0x5e0859,_0x18f485),this['_baseRootsAttributes']['set'](_0x5e0859,_0x1058d8),_0x245151&&this['_touchedRoots']['set'](_0x5e0859,_0x245151);const _0x12a98d=this['_makeIdsRoot'](_0x18f485);this['_baseIdsRoots']['set'](_0x5e0859,_0x12a98d);for(const [_0x3ef797,_0x104e94]of _0x18f485['markers']){if(!_0x3ef797['startsWith']('revision:'))continue;const _0x4e9dd2=_0x3ef797['split'](':')[0x2];for(const _0x208b38 of _0x104e94['getWalker']({'singleCharacters':!0x0})){const _0x1aa51c=this['_getVidAttributeName'](_0x208b38),_0x325e84='elementEnd'==_0x208b38['type']?_0x208b38['previousPosition']['path']['slice'](0x0,-0x1):_0x208b38['previousPosition']['path'],_0x3726b8=_0x12a98d['getNodeByPath'](_0x325e84)['getAttribute'](_0x1aa51c);this['_touched']['set'](_0x3726b8,{'userId':_0x4e9dd2});}}}this['_startingRevisionId']=this['_revisionId'];const _0x1c7409=[...Array(this['_revisionId'])['keys']()]['slice'](0x1)['filter'](_0x22cd42=>!this['_touched']['has'](_0x22cd42));let _0x3e4e90=0x0;const _0x2c66be=new Map();for(const _0x2cc803 in _0x5e0868['diffData']){const _0x4bdbce=_0x5e0868['diffData'][_0x2cc803]['attachChange'],_0x180537=_0x5a4053(_0x5e0868['diffData'][_0x2cc803]['attributesAfter'])||{},_0x259130=_0x2d442b['_makeModelFromViewString'](_0x5e0868['diffData'][_0x2cc803]['insertions']);_0x259130['rootName']=_0x2cc803,_0x259130['_isAttached']=!_0x4bdbce||_0x4bdbce['isAttached'],_0x259130['isAttached']=()=>_0x259130['_isAttached'],this['_diffRoots']['set'](_0x2cc803,_0x259130),this['_diffRootsAttributes']['set'](_0x2cc803,_0x180537);const _0x252efe=this['_makeIdsRoot'](_0x259130,Number['NEGATIVE_INFINITY']);this['_idsRoots']['set'](_0x2cc803,_0x252efe),_0x2c66be['set'](_0x2cc803,_0x259130['isAttached']()?_0x180537:{});for(const [_0x4403a2,_0x1f9d3c]of _0x259130['markers']){if(!_0x4403a2['startsWith']('revision:'))continue;const _0x5258e9=_0x4403a2['split'](':')[0x2];for(const _0x271296 of _0x1f9d3c['getWalker']({'singleCharacters':!0x0})){const _0x484465=this['_getVidAttributeName'](_0x271296),_0x46a616=this['_revisionId']++,_0x2ed402='elementEnd'==_0x271296['type']?_0x271296['previousPosition']['path']['slice'](0x0,-0x1):_0x271296['previousPosition']['path'];_0x252efe['getNodeByPath'](_0x2ed402)['_setAttribute'](_0x484465,_0x46a616),this['_touched']['set'](_0x46a616,{'userId':_0x5258e9});}}for(const _0x5f0c47 of this['editor']['model']['createRangeIn'](_0x259130)['getWalker']({'singleCharacters':!0x0})){const _0x42b377=this['_getVidAttributeName'](_0x5f0c47),_0x321ef9='elementEnd'==_0x5f0c47['type']?_0x5f0c47['previousPosition']['path']['slice'](0x0,-0x1):_0x5f0c47['previousPosition']['path'],_0xe43c66=_0x252efe['getNodeByPath'](_0x321ef9);_0xe43c66['getAttribute'](_0x42b377)>0x0||_0xe43c66['_setAttribute'](_0x42b377,_0x1c7409[_0x3e4e90++]);}for(const [_0x4775f6,_0x18aae8]of _0x259130['markers'])_0x4775f6['startsWith']('revision:')||this['_markers']['set'](_0x4775f6,_0x18aae8);}const _0x433d09=P('$graveyard');this['_baseRoots']['set']('$graveyard',_0x433d09),this['_baseIdsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x433d09,0x1));const _0x5e1698=P('$graveyard');this['_diffRoots']['set']('$graveyard',_0x5e1698),this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x5e1698,0x1));const _0x1c699d=Array['from'](this['_diffRoots'])['map'](([_0x1a0351,_0x2da2a9])=>[_0x1a0351,N(_0x2da2a9)]);this['_saveMetaData'](this['_lastTo'],_0x1c699d,this['_markers'],_0x2c66be);}['reInit'](){this['_reset'](),this['_lastFrom']=-0x1,this['_lastTo']=-0x1,this['_savedMetaData']['clear'](),this['init'](this['source']);}['_saveMetaData'](_0x48d25a,_0x4f3714,_0x144e17,_0x259031){const _0x4b8133=new Map(_0x4f3714),_0x1257cb=new Map(_0x5a4053(_0x259031)),_0x5bdba6=new Map();for(const [_0x10b382,_0x2ef8ea]of _0x144e17)_0x5bdba6['set'](_0x10b382,{'start':_0x2ef8ea['start']['clone'](),'end':_0x2ef8ea['end']['clone'](),'rootName':_0x2ef8ea['root']['rootName']});this['_savedMetaData']['set'](_0x48d25a,{'roots':_0x4b8133,'markers':_0x5bdba6,'rootsAttributes':_0x1257cb});}['_removeMetaData'](_0xb99e89){this['_savedMetaData']['delete'](_0xb99e89);}['_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'](_0x59f60b,_0x46aeed=null){let _0x57f0ac=null;_0x59f60b['is']('documentFragment')||(_0x57f0ac=new ut(_0x59f60b['name'],{'vid_start':null===_0x46aeed?this['_revisionId']++:_0x46aeed++}));const _0x2f44de=[];for(const _0x3961da of _0x59f60b['getChildren']())if(_0x3961da['is']('element')){_0x2f44de['push'](this['_makeIdsRoot'](_0x3961da,_0x46aeed));const _0x9d2316=_0x2f44de[_0x2f44de['length']-0x1];null!==_0x46aeed&&(_0x46aeed=_0x9d2316['is']('element','$text')?_0x9d2316['getAttribute']('vid')+0x1:_0x9d2316['getAttribute']('vid_end')+0x1);}else{for(let _0x38d747=0x0;_0x38d747<_0x3961da['offsetSize'];_0x38d747++)_0x2f44de['push'](new ut('$text',{'vid':null===_0x46aeed?this['_revisionId']++:_0x46aeed++}));}if(_0x59f60b['is']('documentFragment')){const _0x384e56=P(_0x59f60b['rootName']);return _0x384e56['_insertChild'](0x0,_0x2f44de),_0x384e56;}return _0x57f0ac['_setAttribute']('vid_end',null===_0x46aeed?this['_revisionId']++:_0x46aeed++),_0x57f0ac['_insertChild'](0x0,_0x2f44de),_0x57f0ac;}['_calculateMetaData'](_0x52166d,_0x860f66,_0xe1f44b){this['_reset']();const {roots:_0x1e9183,markers:_0x261118,rootsAttributes:_0x328f0c}=this['_savedMetaData']['get'](_0x52166d);this['_baseRoots']=new Map(_0x1e9183),this['_baseRootsAttributes']=new Map(_0x5a4053(_0x328f0c));for(const [_0x4e9922,_0x5d0658]of this['_baseRoots'])if('$graveyard'!==_0x4e9922&&(this['_diffRoots']['set'](_0x4e9922,N(_0x5d0658)),this['_diffRootsAttributes']=new Map(_0x5a4053(_0x328f0c)),_0xe1f44b)){const _0xcb153c=this['_revisionId'];this['_idsRoots']['set'](_0x4e9922,this['_makeIdsRoot'](_0x5d0658)),this['_baseIdsRoots']['set'](_0x4e9922,this['_makeIdsRoot'](_0x5d0658,_0xcb153c));}this['_startingRevisionId']=this['_revisionId'],this['_diffRoots']['set']('$graveyard',N(this['_baseRoots']['get']('$graveyard'))),_0xe1f44b&&this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](this['_baseRoots']['get']('$graveyard')));for(const [_0x128c05,_0x1ae9ae]of _0x261118){const _0x3e12e4=this['_baseRoots']['get'](_0x1ae9ae['rootName']),_0x390266=this['_diffRoots']['get'](_0x1ae9ae['rootName']),_0x9cdbd2=new lt(this['_fixPosition'](_0x1ae9ae['start'],_0x3e12e4),this['_fixPosition'](_0x1ae9ae['end'],_0x3e12e4)),_0x240411=this['_fixRange'](_0x9cdbd2,_0x390266);_0x3e12e4['markers']['set'](_0x128c05,_0x9cdbd2),this['_markers']['set'](_0x128c05,_0x240411);}this['_applyOperations'](_0x52166d,_0x860f66,_0xe1f44b);}['_applyOperations'](_0x38d180,_0x441183,_0x5456dc){for(const _0x3489f5 of this['source']['getOperations'](_0x38d180,_0x441183))this['_handleOperation'](_0x3489f5,_0x5456dc);for(const _0x46dfed of this['_diffRoots']['values']())_0x46dfed['markers']['clear']();for(const [_0x4ccc2f,_0x7d188a]of this['_markers']){this['_diffRoots']['get'](_0x7d188a['root']['rootName'])['markers']['set'](_0x4ccc2f,_0x7d188a['clone']());}const _0xf6fc4c=new Map(),_0x3b7976=new Map();for(const [_0x5aeb98,_0x1b5732]of this['_diffRoots'])_0xf6fc4c['set'](_0x5aeb98,N(_0x1b5732)),_0x3b7976['set'](_0x5aeb98,this['_diffRootsAttributes']['get'](_0x5aeb98));this['_saveMetaData'](_0x441183,_0xf6fc4c,this['_markers'],_0x3b7976);}['_getPreviousFrom'](_0x4b6c47){const _0x297374=Array['from'](this['_savedMetaData']['keys']());_0x297374['sort']((_0x5c7374,_0x13fa08)=>_0x5c7374-_0x13fa08),_0x297374['reverse']();for(const _0x52b32d of _0x297374)if(_0x52b32d<_0x4b6c47)return _0x52b32d;return Number['NEGATIVE_INFINITY'];}['_copyMarkers'](_0x77049e,_0x4f59bb){const _0x2473d9=Array['from'](_0x4f59bb['markers'])['map'](([_0x239f38,_0xb934b])=>[_0x239f38,this['_fixRange'](_0xb934b,_0x77049e)]);_0x77049e['markers']=new Map(_0x2473d9);}['_transformMarkers'](_0x274bf2){for(const _0x266afb of this['_markers']['values']()){const _0x3d3409=_0x266afb['getTransformedByOperation'](_0x274bf2),_0x50b1ed=lt['_createFromRanges'](_0x3d3409);_0x266afb['start']=_0x50b1ed['start'],_0x266afb['end']=_0x50b1ed['end'];}}['_handleOperation'](_0x23bc64,_0x3d6243){if('addRoot'!=_0x23bc64['type']&&'detachRoot'!=_0x23bc64['type']){if('insert'==_0x23bc64['type']){const _0xd1507c=_0x23bc64['position']['root']['rootName'];this['_diffRoots']['has'](_0xd1507c)||(this['_diffRoots']['set'](_0xd1507c,P(_0xd1507c,!0x0)),this['_diffRootsAttributes']['set'](_0xd1507c,{}),_0x3d6243&&this['_idsRoots']['set'](_0xd1507c,P(_0xd1507c,!0x0)));}else{if('addRootAttribute'==_0x23bc64['type']||'removeRootAttribute'==_0x23bc64['type']||'changeRootAttribute'==_0x23bc64['type'])return void this['_handleRootAttributeOperation'](_0x23bc64);'marker'==_0x23bc64['type']&&this['_handleMarkerOperation'](_0x23bc64);}if('marker'!==_0x23bc64['type']){const _0x587303=this['_cloneOperation'](_0x23bc64,this['_diffRoots']);_0x587303['_execute'](),this['_transformMarkers'](_0x587303);}if(_0x3d6243)switch(_0x23bc64['type']){case'insert':this['_handleInsertOperation'](_0x23bc64);break;case'move':case'remove':case'reinsert':this['_handleMoveOperation'](_0x23bc64);break;case'merge':this['_handleMergeOperation'](_0x23bc64);break;case'split':this['_handleSplitOperation'](_0x23bc64);}}else this['_handleRootOperation'](_0x23bc64,_0x3d6243);}['_cloneOperation'](_0x3d50d8,_0x1aaa64){const _0x50bef3=_0x3d50d8['clone']();return _0x50bef3['_authorId']=_0x3d50d8['_authorId'],this['_fixOperation'](_0x50bef3,_0x1aaa64),_0x50bef3;}['_getBaseVids'](_0x2f53fd){return _0x2f53fd['map'](_0x886c3d=>{const _0xd9fce7=this['_getVidAttributeName'](_0x886c3d);return Number(_0x886c3d['item']['getAttribute'](_0xd9fce7));});}['_generateTape'](_0xc5e409,_0x4f2374){if(_0xc5e409['is']('element','$text'))_0x4f2374['push']({'item':_0xc5e409,'type':'text'});else{_0xc5e409['is']('element')&&_0x4f2374['push']({'item':_0xc5e409,'type':'elementStart'});for(const _0x5d1b55 of _0xc5e409['getChildren']())this['_generateTape'](_0x5d1b55,_0x4f2374);_0xc5e409['is']('element')&&_0x4f2374['push']({'item':_0xc5e409,'type':'elementEnd'});}return _0x4f2374;}['_getState'](){const _0x31ddbc=new Map(this['_touched']),_0x23cf0e=new Map(_0x31ddbc),_0x226fb8=new Map(),_0x4096a6={'insertions':{},'deletions':{}},_0x57c551={'insertions':{},'deletions':{}},_0x27d8d6=new Map(),_0x4f0f0e=new Set([...this['_baseRoots']['keys'](),...this['_diffRoots']['keys']()]);_0x4f0f0e['delete']('$graveyard');for(const _0x14ec7d of _0x4f0f0e){const _0x8f95e0=this['_diffRoots']['get'](_0x14ec7d)||P(_0x14ec7d,!0x1),_0x1df58e=this['_baseRoots']['get'](_0x14ec7d)||P(_0x14ec7d,!0x1);_0x8f95e0['isAttached']()||_0x1df58e['isAttached']()?(_0x4096a6['insertions'][_0x14ec7d]=N(_0x8f95e0),_0x4096a6['deletions'][_0x14ec7d]=N(_0x1df58e),this['_copyMarkers'](_0x4096a6['deletions'][_0x14ec7d],_0x1df58e),this['_copyMarkers'](_0x4096a6['insertions'][_0x14ec7d],_0x8f95e0),_0x57c551['insertions'][_0x14ec7d]=this['_generateTape'](this['_idsRoots']['get'](_0x14ec7d),[]),_0x57c551['deletions'][_0x14ec7d]=this['_generateTape'](this['_baseIdsRoots']['get'](_0x14ec7d)||P(_0x14ec7d,!0x1),[])):_0x4f0f0e['delete'](_0x14ec7d);}for(const _0x595c85 of _0x4f0f0e){const _0x15c5fa=_0x57c551['insertions'][_0x595c85];for(const _0x3d11da of _0x15c5fa){const _0x503ed6=this['_getVidAttributeName'](_0x3d11da),_0x36843c=_0x3d11da['item']['getAttribute'](_0x503ed6);_0x23cf0e['delete'](_0x36843c),_0x36843c>=this['_startingRevisionId']&&_0x226fb8['set'](_0x36843c,_0x31ddbc['get'](_0x36843c));}}for(const _0x114e82 of _0x4f0f0e){const _0x1a6260=_0x57c551['insertions'][_0x114e82],_0xcceb73=this['_getBaseVids'](_0x57c551['deletions'][_0x114e82]);let _0xe5122=0x0;for(const _0x160dec of _0x1a6260){const _0x4323a5=this['_getVidAttributeName'](_0x160dec),_0x11aa41=_0x160dec['item']['getAttribute'](_0x4323a5);if(!_0x226fb8['has'](_0x11aa41)&&!_0x27d8d6['has'](_0x11aa41)){if(_0x23cf0e['has'](_0x11aa41))_0xe5122++;else{if(_0x11aa41!=_0xcceb73[_0xe5122]){const _0x5ad1ec=_0x31ddbc['get'](_0x11aa41)||_0x31ddbc['get'](_0xcceb73[_0xe5122]);for(;_0x11aa41!=_0xcceb73[_0xe5122];)_0x23cf0e['has'](_0xcceb73[_0xe5122])||(_0x27d8d6['set'](_0xcceb73[_0xe5122],_0x5ad1ec),_0x31ddbc['set'](_0xcceb73[_0xe5122],_0x5ad1ec)),_0xe5122++;}_0xe5122++;}}}}for(const _0x39dc86 of _0x4f0f0e){const _0x50412c=_0x57c551['insertions'][_0x39dc86];for(const _0x5d3713 of _0x50412c){const _0x549c63=this['_getVidAttributeName'](_0x5d3713),_0xa63ad=_0x5d3713['item']['getAttribute'](_0x549c63);if(_0x27d8d6['has'](_0xa63ad)){const _0x389061=_0x27d8d6['get'](_0xa63ad);_0x23cf0e['has'](_0xa63ad)||_0x23cf0e['set'](_0xa63ad,{..._0x389061}),_0x226fb8['set'](_0xa63ad,{..._0x389061});}}}for(const _0x4d4b8a of _0x23cf0e['keys']())_0x4d4b8a>=this['_startingRevisionId']&&_0x23cf0e['delete'](_0x4d4b8a);const _0x5e7511=new Map();for(const _0x20f8f9 of _0x4f0f0e){let _0x5e0bd1=_0x57c551['insertions'][_0x20f8f9];for(const _0x157808 of _0x5e0bd1)if(_0x157808['item']['is']('element','tableCell')){const _0x1651be=this['_getVidAttributeName'](_0x157808),_0x3d092f=_0x157808['item']['getAttribute'](_0x1651be);if(_0x226fb8['has'](_0x3d092f)){const _0x2b93c6=_0x157808['item']['parent']['parent']['getAttribute']('vid_start'),_0x32e77e=_0x5e7511['get'](_0x2b93c6)||new Set();_0x32e77e['add'](_0x226fb8['get'](_0x3d092f)['userId']),_0x5e7511['set'](_0x2b93c6,_0x32e77e);}}_0x5e0bd1=_0x57c551['deletions'][_0x20f8f9];for(const _0x581877 of _0x5e0bd1)if(_0x581877['item']['is']('element','tableCell')){const _0x54f27d=this['_getVidAttributeName'](_0x581877),_0x4bc61e=_0x581877['item']['getAttribute'](_0x54f27d);if(_0x23cf0e['has'](_0x4bc61e)){const _0x2da20a=_0x581877['item']['parent']['parent']['getAttribute']('vid_start'),_0x7d936c=_0x5e7511['get'](_0x2da20a)||new Set();_0x7d936c['add'](_0x23cf0e['get'](_0x4bc61e)['userId']),_0x5e7511['set'](_0x2da20a,_0x7d936c);}}for(const _0x216223 of _0x5e7511['keys']())(_0x226fb8['has'](_0x216223)||_0x23cf0e['has'](_0x216223))&&_0x5e7511['delete'](_0x216223);}for(const _0x4d75ea of _0x4f0f0e){const _0x127f17=_0x57c551['insertions'][_0x4d75ea];let _0x20630e=null,_0x3bde1f=null;for(const _0x3194a7 of _0x127f17){const _0x4e8f46=this['_getVidAttributeName'](_0x3194a7),_0x5db8fa=_0x3194a7['item']['getAttribute'](_0x4e8f46),_0x43264f=_0x5e7511['get'](_0x5db8fa);_0x43264f&&'elementStart'==_0x3194a7['type']&&(_0x20630e=Array['from'](_0x43264f)[0x0],_0x3bde1f=_0x3194a7['item']['getAttribute']('vid_end')),_0x20630e&&(_0x23cf0e['set'](_0x5db8fa,{'userId':_0x20630e}),_0x226fb8['set'](_0x5db8fa,{'userId':_0x20630e})),_0x5db8fa==_0x3bde1f&&(_0x20630e=null,_0x3bde1f=null);}}const _0x499dee={},_0x4cf6f4=new Set();for(const _0x59090e of _0x4f0f0e){const _0x3f63d6=_0x4096a6['deletions'][_0x59090e],_0x1d3091=_0x4096a6['insertions'][_0x59090e];for(const {userId:_0x33ffab}of this['_touchedMarkers']['values']())null!==_0x33ffab&&_0x4cf6f4['add'](_0x33ffab);for(const {userId:_0x3e8b74}of this['_touchedRoots']['values']())null!==_0x3e8b74&&_0x4cf6f4['add'](_0x3e8b74);this['_markChanges'](_0x1d3091,_0x57c551['insertions'][_0x59090e],_0x226fb8,'insertion',_0x4cf6f4),this['_markChanges'](_0x3f63d6,_0x57c551['deletions'][_0x59090e],_0x23cf0e,'deletion',_0x4cf6f4),_0x499dee[_0x59090e]={'insertions':this['_prepareViewToSave'](_0x1d3091),'deletions':this['_prepareViewToSave'](_0x3f63d6),'attachChange':this['_touchedRoots']['get'](_0x59090e)||null,'attributesBefore':_0x5a4053(this['_baseRootsAttributes']['get'](_0x59090e))||{},'attributesAfter':_0x5a4053(this['_diffRootsAttributes']['get'](_0x59090e))};}return{'diffData':_0x499dee,'authorsIds':Array['from'](_0x4cf6f4)};}['_processRootBeforeSave'](_0x542853){for(const [,_0x1af736]of _0x542853['markers']){const _0x4567dc=_0x1af736['start']['getAncestors']()['filter'](_0x24b244=>'tableCell'==_0x24b244['name']);for(const _0x505c69 of _0x4567dc)0x1==_0x505c69['childCount']&&_0x505c69['getChild'](0x0)['is']('element','paragraph')&&_0x505c69['getChild'](0x0)['_setAttribute']('keepParagraph',!0x0);}}['_prepareViewToSave'](_0x1b41e3){this['_processRootBeforeSave'](_0x1b41e3);const _0x1da44c=this['editor']['data']['toView'](_0x1b41e3,{}),_0x2c4d6a=Array['from'](_0x1da44c['getChildren']())['map'](_0x1331a5=>this['_getViewJson'](_0x1331a5));return JSON['stringify'](_0x2c4d6a);}['_getViewJson'](_0x2438ec){if(_0x2438ec['is']('$text'))return _0x2438ec['data'];{const _0x53dd63=this['editor']['plugins']['get']('RevisionHistoryUtils'),_0x5610bf=_0x2438ec,_0x46cb64=this['editor']['data']['htmlProcessor']['domConverter'],_0x19be81={'type':_0x53dd63['_getTypeCharForViewElement'](_0x5610bf),'name':_0x5610bf['name'],'attributes':Array['from'](_0x5610bf['getAttributes']()),'children':Array['from'](_0x5610bf['getChildren']())['map'](_0x58dbfd=>this['_getViewJson'](_0x58dbfd))};if(_0x2438ec['is']('uiElement')&&'$comment'!=_0x2438ec['name']){const _0x402d7a=_0x2438ec['render'](_0x46cb64['domDocument'],_0x46cb64);_0x19be81['children']['push'](_0x402d7a['outerHTML']);}else{if(_0x2438ec['is']('rawElement')){const _0x187b29=_0x46cb64['domDocument']['createElement'](_0x5610bf['name']);_0x2438ec['render'](_0x187b29,_0x46cb64),_0x19be81['children']['push'](_0x187b29['innerHTML']);}}const _0x2930be=Array['from'](_0x5610bf['getCustomProperties']());_0x2930be['length']>0x0&&(_0x19be81['customProperties']=_0x2930be);const _0x5f3b1e=_0x5610bf['getFillerOffset']();return null!==_0x5f3b1e&&(_0x19be81['fillerOffset']=_0x5f3b1e),_0x19be81;}}['_markChanges'](_0x465ba4,_0x3e016a,_0x10bce4,_0x497e6d,_0x359847){let _0x57cc66=null,_0x50f1e9=null,_0x3b8753=0x0;const _0x4f0897=this['editor']['model'];for(let _0x2f75fb=0x0;_0x2f75fb<_0x3e016a['length'];_0x2f75fb++){const _0x13146d=this['_getVidAttributeName'](_0x3e016a[_0x2f75fb]),_0x5ddc70=_0x3e016a[_0x2f75fb]['item']['getAttribute'](_0x13146d),_0x36f559=_0x10bce4['get'](_0x5ddc70),_0x5270e9=_0x2f75fb==_0x3e016a['length']-0x1;(!_0x57cc66&&_0x36f559&&(_0x57cc66=_0x36f559,_0x50f1e9=_0x3e016a[_0x2f75fb]),_0x57cc66&&(!_0x36f559||_0x36f559['userId']!=_0x57cc66['userId']))&&(_0x3fef25(_0x36f559,F(_0x50f1e9,_0x465ba4,_0x4f0897),F(_0x3e016a[_0x2f75fb],_0x465ba4,_0x4f0897)),_0x57cc66=_0x36f559||null,_0x50f1e9=_0x36f559?_0x3e016a[_0x2f75fb]:null),_0x57cc66&&_0x5270e9&&_0x3fef25(_0x36f559,F(_0x50f1e9,_0x465ba4,_0x4f0897),B(_0x3e016a[_0x2f75fb],_0x465ba4,_0x4f0897));}function _0x3fef25(_0x367694,_0x228f9f,_0x5a9e7c){const _0x4ce60c=_0x57cc66['userId'],_0x7fe62d='revision:'+_0x497e6d+':'+_0x4ce60c+':'+_0x3b8753++,_0x558f4b=_0x4f0897['createRange'](_0x228f9f,_0x5a9e7c);_0x465ba4['markers']['set'](_0x7fe62d,_0x558f4b),null!==_0x4ce60c&&_0x359847['add'](_0x4ce60c);}}['_getVidAttributeName'](_0x3bef40){switch(_0x3bef40['type']){case'elementStart':return'vid_start';case'elementEnd':return'vid_end';default:return'vid';}}['_fixOperation'](_0x17c799,_0x41e1a0){_0x17c799['baseVersion']=null;for(const _0x258050 in _0x17c799){const _0x25f5d8=_0x17c799[_0x258050];if(_0x25f5d8 instanceof ft){const _0x21a26e=_0x41e1a0['get'](_0x25f5d8['root']['rootName']);_0x17c799[_0x258050]=this['_fixPosition'](_0x25f5d8,_0x21a26e);}if(_0x25f5d8 instanceof lt){const _0x4a990d=_0x41e1a0['get'](_0x25f5d8['root']['rootName']);_0x17c799[_0x258050]=this['_fixRange'](_0x25f5d8,_0x4a990d);}'root'===_0x258050&&(_0x17c799['root']=_0x41e1a0['get'](_0x17c799['root']['rootName']));}}['_fixRange'](_0x3d41bf,_0x50c083){return this['editor']['model']['createRange'](this['_fixPosition'](_0x3d41bf['start'],_0x50c083),this['_fixPosition'](_0x3d41bf['end'],_0x50c083));}['_fixPosition'](_0x80a4dd,_0x1a3631){return this['editor']['model']['createPositionFromPath'](_0x1a3631,_0x80a4dd['path'],_0x80a4dd['stickiness']);}['_handleInsertOperation'](_0x182f51){const _0x2ce0d5=this['_idsRoots']['get'](_0x182f51['position']['root']['rootName']),_0x2ab359=this['_fixPosition'](_0x182f51['position'],_0x2ce0d5),_0x35fe33=null===_0x182f51['_authorId']?null:_0x182f51['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x1d266c=_0x2ab359['parent'],_0x3559d3=this['_revisionId'],_0x37ae43=[];for(const _0x290585 of _0x182f51['nodes'])if(_0x290585['is']('element'))_0x37ae43['push'](this['_makeIdsRoot'](_0x290585));else{for(let _0x2665a8=0x0;_0x2665a8<_0x290585['offsetSize'];_0x2665a8++)_0x37ae43['push'](new ut('$text',{'vid':this['_revisionId']++}));}const _0xb0b101=this['_revisionId'];for(let _0x14bb7f=_0x3559d3;_0x14bb7f<_0xb0b101;_0x14bb7f++)this['_touched']['set'](_0x14bb7f,{'userId':_0x35fe33});_0x1d266c['_insertChild'](_0x2ab359['offset'],_0x37ae43);}['_handleMoveOperation'](_0x26c6cb){(_0x26c6cb=this['_cloneOperation'](_0x26c6cb,this['_idsRoots']))['_execute']();const _0x4c0c89=null===_0x26c6cb['_authorId']?null:_0x26c6cb['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x205f61=_0x26c6cb['getMovedRangeStart'](),_0x1c5238=_0x205f61['parent'],_0x273d3c=_0x205f61['offset'];!function _0x4d976e(_0x11047a,_0x43fca9,_0x2794b7,_0x1ef7ec){for(let _0x48cd85=_0x2794b7;_0x48cd85<_0x1ef7ec;_0x48cd85++){const _0x103dcf=_0x43fca9['getChild'](_0x48cd85);_0x103dcf['is']('element','$text')?_0x11047a['set'](_0x103dcf['getAttribute']('vid'),{'userId':_0x4c0c89}):(_0x11047a['set'](_0x103dcf['getAttribute']('vid_start'),{'userId':_0x4c0c89}),_0x4d976e(_0x11047a,_0x103dcf,0x0,_0x103dcf['childCount']),_0x11047a['set'](_0x103dcf['getAttribute']('vid_end'),{'userId':_0x4c0c89}));}}(this['_touched'],_0x1c5238,_0x273d3c,_0x273d3c+_0x26c6cb['howMany']);}['_handleMergeOperation'](_0x112e9d){const _0x14de44=null===(_0x112e9d=this['_cloneOperation'](_0x112e9d,this['_idsRoots']))['_authorId']?null:_0x112e9d['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x18712d=_0x112e9d['targetPosition']['parent'],_0x5bdc0b=_0x112e9d['sourcePosition']['parent'],_0x1436b5=_0x18712d['getAttribute']('vid_end'),_0x101bc1=_0x5bdc0b['getAttribute']('vid_start');_0x18712d['_setAttribute']('vid_end',_0x5bdc0b['getAttribute']('vid_end')),_0x5bdc0b['_setAttribute']('vid_end',_0x1436b5),this['_touched']['set'](_0x101bc1,{'userId':_0x14de44}),this['_touched']['set'](_0x1436b5,{'userId':_0x14de44}),_0x112e9d['_execute']();}['_handleSplitOperation'](_0x47c22d){const _0x140e6d=null===(_0x47c22d=this['_cloneOperation'](_0x47c22d,this['_idsRoots']))['_authorId']?null:_0x47c22d['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x11e999=_0x47c22d['graveyardPosition'],_0x5c1857=_0x47c22d['splitPosition']['parent'];_0x47c22d['_execute']();const _0x340cd0=_0x5c1857['getAttribute']('vid_end'),_0x5f07d0=_0x47c22d['insertionPosition']['nodeAfter'];if(_0x11e999){const _0x28ba6f=_0x5f07d0['getAttribute']('vid_end'),_0x46e559=_0x5c1857['getAttribute']('vid_end');_0x5c1857['_setAttribute']('vid_end',_0x28ba6f),_0x5f07d0['_setAttribute']('vid_end',_0x46e559),this['_touched']['set'](_0x5c1857['getAttribute']('vid_end'),{'userId':_0x140e6d}),this['_touched']['set'](_0x5f07d0['getAttribute']('vid_start'),{'userId':_0x140e6d});}else{const _0x49f059=this['_revisionId']++,_0x1aa5ea=this['_revisionId']++;_0x5c1857['_setAttribute']('vid_end',_0x49f059),_0x5f07d0['_setAttribute']('vid_start',_0x1aa5ea),_0x5f07d0['_setAttribute']('vid_end',_0x340cd0),this['_touched']['set'](_0x49f059,{'userId':_0x140e6d}),this['_touched']['set'](_0x1aa5ea,{'userId':_0x140e6d});}}['_handleMarkerOperation'](_0x5cf72c){if(!_0x5cf72c['affectsData'])return;const _0x5c007c=(_0x5cf72c=this['_cloneOperation'](_0x5cf72c,this['_diffRoots']))['oldRange']?_0x5cf72c['oldRange']['root']:null,_0x3fcdf6=_0x5cf72c['newRange']?_0x5cf72c['newRange']['root']:null;_0x5c007c&&this['_markers']['delete'](_0x5cf72c['name']),_0x3fcdf6&&this['_markers']['set'](_0x5cf72c['name'],_0x5cf72c['newRange']['clone']());const _0x2ce4cb=null===_0x5cf72c['_authorId']?null:_0x5cf72c['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x3fd8d9=_0x5cf72c['name'];if(!this['_touchedMarkers']['has'](_0x3fd8d9))return void this['_touchedMarkers']['set'](_0x3fd8d9,{'range':_0x5cf72c['oldRange'],'userId':_0x2ce4cb});const _0x30ecf7=this['_touchedMarkers']['get'](_0x3fd8d9),_0xa7cc8b=_0x30ecf7['range'],_0x2e831a=_0x5cf72c['newRange'];null==_0xa7cc8b&&null==_0x2e831a||_0xa7cc8b&&_0x2e831a&&_0xa7cc8b['isEqual'](_0x2e831a)?this['_touchedMarkers']['delete'](_0x5cf72c['name']):_0x30ecf7['userId']=_0x2ce4cb;}['_handleRootOperation'](_0x2d4c32,_0x4f9fd3){this['_diffRoots']['has'](_0x2d4c32['rootName'])?this['_diffRoots']['get'](_0x2d4c32['rootName'])['_isAttached']=_0x2d4c32['isAdd']:(this['_diffRoots']['set'](_0x2d4c32['rootName'],P(_0x2d4c32['rootName'],!0x0)),this['_diffRootsAttributes']['set'](_0x2d4c32['rootName'],{}),_0x4f9fd3&&this['_idsRoots']['set'](_0x2d4c32['rootName'],P(_0x2d4c32['rootName'],!0x0)));const _0x4b8aa6=null===_0x2d4c32['_authorId']?null:_0x2d4c32['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x19e6f3=this['_touchedRoots']['get'](_0x2d4c32['rootName']);_0x19e6f3&&_0x19e6f3['userId']===_0x4b8aa6?this['_touchedRoots']['delete'](_0x2d4c32['rootName']):this['_touchedRoots']['set'](_0x2d4c32['rootName'],{'userId':_0x4b8aa6,'isAttached':_0x2d4c32['isAdd']});}['_handleRootAttributeOperation'](_0x79e103){const _0x48dfa9=this['_diffRootsAttributes']['get'](_0x79e103['root']['rootName']);null===_0x79e103['newValue']?delete _0x48dfa9[_0x79e103['key']]:_0x48dfa9[_0x79e103['key']]=_0x79e103['newValue'];}}function N(_0x581149){const _0x64460f=P(_0x581149['rootName'],_0x581149['isAttached']());for(const _0x55fc23 of _0x581149['getChildren']()){const _0x29edd7=_0x55fc23['_clone'](!0x0);_0x64460f['_appendChild'](_0x29edd7);}return _0x64460f;}function P(_0x75b6f5,_0x39c807=!0x0){const _0x5943d4=new vt();return _0x5943d4['rootName']=_0x75b6f5,_0x5943d4['_isAttached']=_0x39c807,_0x5943d4['isAttached']=()=>_0x5943d4['_isAttached'],_0x5943d4;}function F(_0x4606c4,_0x550468,_0x2a2a2d){const _0x1515b5='elementEnd'==_0x4606c4['type']?_0x2a2a2d['createPositionAt'](_0x4606c4['item'],'end'):_0x2a2a2d['createPositionBefore'](_0x4606c4['item']);return _0x2a2a2d['createPositionFromPath'](_0x550468,_0x1515b5['path'],_0x1515b5['stickiness']);}function B(_0x1570a8,_0x33b03f,_0x425a2b){const _0x5018ce='elementStart'==_0x1570a8['type']?_0x425a2b['createPositionAt'](_0x1570a8['item'],0x0):_0x425a2b['createPositionAfter'](_0x1570a8['item']);return _0x425a2b['createPositionFromPath'](_0x33b03f,_0x5018ce['path'],_0x5018ce['stickiness']);}class hs extends ts{['focusTracker'];['keystrokes'];['revisionNameInputView'];constructor(_0x430bc8,_0x3059b9){super(_0x430bc8),this['focusTracker']=new _0x5abe77(),this['keystrokes']=new _0x3454e8(),this['set']('revisionNameInputValue',''),this['revisionNameInputView']=this['_createRevisionNameInput'](_0x3059b9),this['setTemplate']({'tag':'form','attributes':{'class':['ck','ck-revision-history-save-revision-form','ck-responsive-form'],'tabindex':'-1'},'children':[this['revisionNameInputView']]}),_0x28d0a9(this);}['render'](){super['render'](),_0x4f10a2({'view':this}),this['focusTracker']['add'](this['revisionNameInputView']['element']),this['keystrokes']['listenTo'](this['element']);const _0x5eb0b7=_0x3bb652=>_0x3bb652['stopPropagation']();this['keystrokes']['set']('arrowright',_0x5eb0b7),this['keystrokes']['set']('arrowleft',_0x5eb0b7),this['keystrokes']['set']('arrowup',_0x5eb0b7),this['keystrokes']['set']('arrowdown',_0x5eb0b7);}['focus'](){this['revisionNameInputView']['focus']();}get['revisionName'](){return this['revisionNameInputView']['fieldView']['element']['value']['trim']();}set['revisionName'](_0x455e76){this['revisionNameInputView']['fieldView']['element']['value']=_0x455e76['trim']();}['reset'](){this['revisionNameInputView']['fieldView']['element']['value']='',this['revisionNameInputView']['errorText']=null;}['_createRevisionNameInput'](_0x12ea9c){const _0xc12745=new _0x403710(this['locale'],_0x2a4301),_0x3c8753=_0xc12745['fieldView'];_0x3c8753['extendTemplate']({'attributes':{'maxlength':'220'}});let _0x21f9d3=g(this['locale'],'Name\x20of\x20the\x20revision');return!_0x12ea9c&&(_0x21f9d3+='\x20('+g(this['locale'],'optional')+')'),(_0xc12745['label']=_0x21f9d3,_0x3c8753['on']('input',()=>{this['revisionNameInputValue']=_0x3c8753['element']['value']['trim']();}),_0xc12745);}}class f extends _0x3561a9{static get['pluginName'](){return'RevisionHistoryUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[u];}['_saveRevisionFormView'];['init'](){const _0x255551=this['editor'],_0x36283e=_0x255551['plugins']['get']('RevisionTracker');_0x255551['ui']['componentFactory']['add']('revisionHistory',_0x54970e=>{const _0x5eed2a=_0x44640e(_0x54970e),_0x524ba1=_0x5eed2a['panelView']['children'],_0x40631d=new _0x31e5fe(_0x54970e),_0x67b116=new _0x4b93ac(_0x54970e),_0x268a4d=new te(_0x54970e),_0x1c59c5=new _0x4b93ac(_0x54970e),_0x11927a=new te(_0x54970e);return _0x5eed2a['bind']('isEnabled')['to'](_0x36283e,'isReady',_0x36283e,'isEnabled',_0x255551,'isReadOnly',(_0x4644e1,_0x3fe792,_0x71adea)=>_0x4644e1&&_0x3fe792&&!_0x71adea),_0x5eed2a['buttonView']['set']({'icon':_0x21a65d,'label':g(_0x54970e,'Revision\x20history'),'tooltip':!0x0}),_0x268a4d['set']({'label':g(_0x54970e,'Save\x20current\x20revision'),'withText':!0x0,'role':'menuitem'}),_0x268a4d['bind']('isEnabled')['to'](_0x36283e,'isReady',_0x36283e,'isEnabled',_0x255551,'isReadOnly',(_0x5bab35,_0x197504,_0x3f6c90)=>_0x5bab35&&_0x197504&&!_0x3f6c90),_0x268a4d['on']('execute',()=>this['_showDialog']()),_0x11927a['set']({'label':g(_0x54970e,'Open\x20revision\x20history'),'withText':!0x0,'role':'menuitem'}),_0x11927a['bind']('isEnabled')['to'](_0x36283e,'isReady',_0x255551,'isReadOnly',(_0x1acfe1,_0x549ac8)=>_0x1acfe1&&!_0x549ac8),_0x11927a['on']('execute',()=>{_0x255551['config']['get']('revisionHistory')['showRevisionViewerCallback'](),_0x5eed2a['isOpen']=!0x1,_0x255551['editing']['view']['focus']();}),_0x67b116['children']['add'](_0x268a4d),_0x1c59c5['children']['add'](_0x11927a),_0x40631d['role']='menu',_0x40631d['items']['addMany']([_0x67b116,_0x1c59c5]),_0x524ba1['add'](_0x40631d),_0x5eed2a;}),_0x255551['ui']['componentFactory']['add']('menuBar:revisionHistory',()=>this['_registerMenuComponent']());}['_registerMenuComponent'](){const _0x26d07f=this['editor'],_0x201172=_0x26d07f['locale'],_0x304dc6=new _0x4f4aa3(_0x201172),_0x57b61b=new _0x132898(_0x201172);_0x304dc6['buttonView']['set']({'icon':_0x21a65d,'label':g(_0x201172,'Revision\x20history')});const _0x31d73d=new _0x84a53c(_0x201172,_0x304dc6),_0x41ec5f=new _0x3ea15b(_0x201172);_0x41ec5f['set']({'label':g(_0x201172,'Save\x20current\x20revision')}),_0x41ec5f['delegate']('execute')['to'](_0x304dc6),_0x41ec5f['on']('execute',()=>{this['_showDialog']();}),_0x31d73d['children']['add'](_0x41ec5f),_0x57b61b['items']['add'](_0x31d73d);const _0x513d1a=new _0x84a53c(_0x201172,_0x304dc6),_0x223227=new _0x3ea15b(_0x201172);return _0x223227['set']({'label':g(_0x201172,'Open\x20revision\x20history')}),_0x223227['delegate']('execute')['to'](_0x304dc6),_0x223227['on']('execute',()=>{_0x26d07f['config']['get']('revisionHistory')['showRevisionViewerCallback']();}),_0x513d1a['children']['add'](_0x223227),_0x57b61b['items']['add'](_0x513d1a),_0x304dc6['panelView']['children']['add'](_0x57b61b),_0x304dc6;}['_showDialog'](){const _0x575222=this['editor'],_0x33d8a5=_0x575222['locale'],_0x18ffde=_0x575222['plugins']['get']('Dialog'),_0x11ad81=_0x575222['plugins']['get']('RevisionTracker');function _0x5ca8bd(_0x8d41ce){_0x575222['config']['get']('revisionHistory.requireRevisionName')&&''===_0x8d41ce['revisionName']?_0x8d41ce['revisionNameInputView']['errorText']=g(_0x33d8a5,'The\x20revision\x20name\x20cannot\x20be\x20empty.'):(_0x575222['plugins']['get'](u)['saveRevision']({'name':_0x8d41ce['revisionName']}),_0x18ffde['hide']());}this['_saveRevisionFormView']||(this['_createSaveRevisionFormView'](),this['_saveRevisionFormView']['on']('submit',()=>_0x5ca8bd(this['_saveRevisionFormView']))),this['_saveRevisionFormView']['reset'](),_0x18ffde['show']({'id':'revisionSave','title':g(_0x33d8a5,'Save\x20current\x20revision'),'isModal':!0x0,'content':this['_saveRevisionFormView'],'actionButtons':[{'label':g(_0x575222['locale'],'Cancel'),'withText':!0x0,'onExecute':()=>_0x18ffde['hide']()},{'label':g(_0x575222['locale'],'Accept'),'class':'ck-button-action','withText':!0x0,'onCreate'(_0x668471){_0x668471['bind']('isEnabled')['to'](_0x11ad81,'isReady',_0x11ad81,'isEnabled',_0x575222,'isReadOnly',(_0x65bc3,_0x9bc59a,_0x27c5a8)=>_0x65bc3&&_0x9bc59a&&!_0x27c5a8);},'onExecute':()=>_0x5ca8bd(this['_saveRevisionFormView'])}]});}['_createSaveRevisionFormView'](){const _0x235fa3=this['editor'],_0x453ddb=_0x235fa3['locale'];this['_saveRevisionFormView']=new hs(_0x453ddb,_0x235fa3['config']['get']('revisionHistory.requireRevisionName')),this['_saveRevisionFormView']['render']();}}class Q extends ts{['changeId'];['_model'];constructor(_0x3eff20,_0x3145f3){super(_0x3eff20),this['_model']=_0x3145f3,this['changeId']=_0x3145f3['id'];const _0xdcee4f=this['bindTemplate'],_0x3ccc6c=g(_0x3eff20,_0x3145f3['data']['isSuggestion']?'Suggested\x20by':'add'==_0x3145f3['type']?'Added\x20by':'Removed\x20by');this['set']('type',_0x3145f3['type']),this['setTemplate']({'tag':'div','attributes':{'class':['ck-annotation','ck-revision-change',_0xdcee4f['to']('type',_0x443c31=>'ck-revision-change__'+_0x443c31)],'tabindex':-0x1},'children':[{'tag':'span','children':[{'tag':'span','attributes':{'class':['ck-revision-change__label']},'children':[{'text':_0x3ccc6c}]},{'text':'\x20'+_0x3145f3['author']['name']}]}]});}['focus'](){this['element']['focus']();}}class r extends/* #__PURE__ -- @preserve */
|
|
25
|
-
_0x5f288e(){['id'];['author'];['type'];['data'];['rootName'];constructor(_0x283d0e){super(),this['id']=_0x283d0e['id']||_0x46e088(),this['author']=_0x283d0e['author'],this['type']=_0x283d0e['type'],this['data']=_0x283d0e['data']||{},this['rootName']=_0x283d0e['rootName'],this['set']('createdAt',_0x283d0e['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(_0x40b6c2,_0x5952d6){this['newRevisionId']=_0x40b6c2,this['oldRevisionId']=_0x5952d6,this['changes']=new _0x57f501();}['_setChanges'](_0x4f4f10){for(const _0x264156 of _0x4f4f10)this['changes']['add'](_0x264156);}}class m extends _0x3561a9{['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[_0x52250a,_0x572f52,I,V];}constructor(_0x27dbfd){super(_0x27dbfd),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',(_0x4af3d5,_0x119617,_0x24a910)=>{this['activeChange']=null,this['activeView']=null,this['editor']['editing']['view']['change'](_0x2d1bfa=>{for(const _0x26d165 of this['editor']['editing']['view']['document']['roots'])_0x24a910?_0x2d1bfa['removeClass']('ck-editor__editable__overlay',_0x26d165):_0x2d1bfa['addClass']('ck-editor__editable__overlay',_0x26d165);});}),this['bind']('isNavigationMode')['to'](this,'activeChange',_0x1e8c28=>null!==_0x1e8c28),this['bind']('currentChangeNumber')['to'](this,'isReady',this,'diff',this,'activeChange',(_0x12e109,_0x5443a7,_0xe3f411)=>_0x12e109&&_0xe3f411?_0x5443a7['changes']['getIndex'](_0xe3f411):0x0),this['bind']('numberOfChanges')['to'](this,'isReady',this,'diff',(_0x317e55,_0x77610e)=>_0x317e55?_0x77610e['changes']['length']:0x0),this['_changeView']=null,this['_changeIdToChange']=new Map(),this['_balloon']=this['editor']['plugins']['get'](_0x572f52);}['init'](){const _0x52fc82=this['editor'],_0x5a6bc0=new wt(_0x52fc82,{'direction':'backward'}),_0x54cf62=new wt(_0x52fc82,{'direction':'forward'});(_0x52fc82['commands']['add']('showPreviousChange',_0x5a6bc0),_0x52fc82['commands']['add']('showNextChange',_0x54cf62),_0x52fc82['commands']['add']('restoreRevision',new mt(_0x52fc82)),this['on']('change:numberOfChanges',()=>{_0x5a6bc0['refresh'](),_0x54cf62['refresh']();}),this['_setConversion'](),this['_initInteractions'](),_0x52fc82['enableReadOnlyMode']('revision-viewer'),_0x52fc82['plugins']['has']('WidgetToolbarRepository'))&&_0x52fc82['plugins']['get']('WidgetToolbarRepository')['forceDisabled']('revision-viewer');}async['getRevisionDocumentData'](_0x419fb6){return await this['_utils']['loadRevisionData'](_0x419fb6,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x419fb6);}async['getRevisionRootsAttributes'](_0x464abc){return await this['_utils']['loadRevisionData'](_0x464abc,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x464abc);}async['compare'](_0xb861f4,_0x4c758e,_0x37cac5=!0x1){if(!this['isEnabled'])return;const _0x3496a5=this['diff'],_0x970ac4=this['repository'],_0x95653b='string'==typeof _0xb861f4?_0x970ac4['getRevision'](_0xb861f4):_0xb861f4,_0x5002c3='string'==typeof _0x4c758e?_0x970ac4['getRevision'](_0x4c758e):_0x4c758e,_0x294477=_0x95653b['id'],_0x34e039=_0x5002c3?_0x5002c3['id']:null;if(!_0x37cac5&&this['diff']&&this['diff']['newRevisionId']===_0x294477&&this['diff']['oldRevisionId']===_0x34e039)return Promise['resolve']();this['isReady']=!0x1,this['activeView']=null,this['activeChange']=null,this['diff']=new c(_0x294477,_0x34e039);const _0x494b24=this['_getRevisionsRange'](_0x95653b,_0x5002c3,!0x0)['map'](_0x2f2d84=>this['_utils']['loadRevisionData'](_0x2f2d84,this['adapter']));return _0x494b24['push'](new Promise(_0x48f643=>{setTimeout(_0x48f643,0x14);})),Promise['all'](_0x494b24)['then'](()=>{if(!this['isEnabled'])return;this['_cleanUp']();const _0x3fc0c0=this['_getDiff'](_0x294477,_0x34e039);for(const _0x46254a of _0x3fc0c0['changes'])this['_changeIdToChange']['set'](_0x46254a['id'],_0x46254a);this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x4a21a2=>{for(const _0x227fd0 of this['editor']['model']['document']['getRootNames']())_0x4a21a2['detachRoot'](_0x227fd0);for(const _0x6c7fe1 of Object['keys'](_0x3fc0c0['model'])){const _0x43790a=_0x4a21a2['addRoot'](_0x6c7fe1);for(const _0x3acd16 of Object['keys'](_0x3fc0c0['attributes'][_0x6c7fe1]))_0x4a21a2['setAttribute'](_0x3acd16,_0x3fc0c0['attributes'][_0x6c7fe1][_0x3acd16],_0x43790a);_0x4a21a2['insert'](_0x3fc0c0['model'][_0x6c7fe1],_0x43790a,0x0);}}),this['diff']['_setChanges'](this['_sortAndFilterDiffChanges'](_0x3fc0c0['changes'])),this['isReady']=!0x0;})['catch'](_0x3b5511=>{console['error'](_0x3b5511),this['_cleanUp'](),_0x3496a5&&(this['diff']=_0x3496a5),this['isReady']=!0x0;});}['addRevisionData'](_0xe26623,_0xa9d77c){const _0x245371=this['repository']['createRevision'](_0xe26623);return _0x245371['on']('_update',(_0x3d5e30,_0x2c0545,_0x2004a2)=>_0xa9d77c(_0x2c0545,_0x2004a2,_0x245371)),this['repository']['addRevision'](_0x245371),_0x245371;}['_cleanUp'](){this['activeChange']=null,this['_cleanMarkers'](),this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=null,this['_changeIdToChange']['clear'](),this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x3edc6b=>{for(const _0x46c090 of this['editor']['model']['document']['getRootNames']())_0x3edc6b['detachRoot'](_0x46c090);});}['_sortAndFilterDiffChanges'](_0x4ea0fd){const _0x53b01f=[],_0x121d23=new Map();for(const _0x5bf086 of this['editor']['model']['document']['getRootNames']()){const _0x34b17f=this['editor']['editing']['view']['getDomRoot'](_0x5bf086);if(!_0x34b17f)continue;const _0xa43e54=_0x34b17f['getClientRects']()['item'](0x0);_0xa43e54&&(_0x53b01f['push'](_0x5bf086),_0x121d23['set'](_0x5bf086,_0xa43e54));}return _0x53b01f['sort']((_0x55d056,_0x38c282)=>{const _0x180e67=_0x121d23['get'](_0x55d056),_0x5baf8f=_0x121d23['get'](_0x38c282);return _0x180e67['y']-_0x5baf8f['y']||_0x180e67['x']-_0x5baf8f['x'];}),(_0x4ea0fd=_0x4ea0fd['filter'](_0x2e0599=>_0x53b01f['includes'](_0x2e0599['rootName'])))['sort']((_0x4b325c,_0x5a3c7e)=>_0x53b01f['indexOf'](_0x4b325c['rootName'])-_0x53b01f['indexOf'](_0x5a3c7e['rootName'])),_0x4ea0fd;}['_makeTape'](_0x16a48a){const _0x407ed9=Array['from'](_0x16a48a['markers'])['filter'](([_0x756184,_0xf0f1cc])=>_0x756184['startsWith']('revision:')&&!_0xf0f1cc['isCollapsed']),_0x5ce543=Array['from'](this['editor']['model']['createRangeIn'](_0x16a48a)['getWalker']({'singleCharacters':!0x0}));if(0x0!=_0x407ed9['length'])for(const _0x292d7f of _0x5ce543){const [_0x24debb,_0x56835b]=_0x407ed9[0x0],[,_0x3c5908,_0x32a479]=_0x24debb['split'](':');if(_0x56835b['end']['isEqual'](_0x292d7f['nextPosition'])&&_0x407ed9['shift'](),(_0x292d7f['previousPosition']['isEqual'](_0x56835b['start'])||_0x292d7f['previousPosition']['isAfter'](_0x56835b['start']))&&('insertion'==_0x3c5908?_0x292d7f['isAdded']={'userId':_0x32a479}:'deletion'==_0x3c5908&&(_0x292d7f['isRemoved']={'userId':_0x32a479})),0x0==_0x407ed9['length'])break;}return _0x5ce543;}['_refreshStartEndIndex'](_0x51082f){const _0x5db837=new Map();for(let _0xa09c23=0x0;_0xa09c23<_0x51082f['length'];_0xa09c23++)'text'===_0x51082f[_0xa09c23]['type']?(_0x51082f[_0xa09c23]['item']['startIndex']=_0xa09c23,_0x51082f[_0xa09c23]['item']['endIndex']=_0xa09c23):('elementStart'===_0x51082f[_0xa09c23]['type']?_0x51082f[_0xa09c23]['item']['startIndex']=_0xa09c23:'elementEnd'===_0x51082f[_0xa09c23]['type']&&(_0x51082f[_0xa09c23]['item']['endIndex']=_0xa09c23),_0x5db837['set'](_0x51082f[_0xa09c23]['id'],_0xa09c23));for(const _0x4de0e9 of _0x5db837['values']())'elementStart'===_0x51082f[_0x4de0e9]['type']?_0x51082f[_0x4de0e9]['item']['endIndex']=_0x5db837['get'](_0x51082f[_0x4de0e9]['pairId']):'elementEnd'===_0x51082f[_0x4de0e9]['type']&&(_0x51082f[_0x4de0e9]['item']['startIndex']=_0x5db837['get'](_0x51082f[_0x4de0e9]['pairId']));}['_processTape'](_0x16227c){for(let _0x46badd=0x0;_0x46badd<_0x16227c['length'];_0x46badd++){if('elementStart'===_0x16227c[_0x46badd]['type'])_0x16227c[_0x46badd]['item']['startIndex']=_0x46badd;else{if('elementEnd'===_0x16227c[_0x46badd]['type']){_0x16227c[_0x46badd]['item']['endIndex']=_0x46badd;const _0x39a2bd=_0x16227c[_0x46badd]['item']['startIndex'];_0x16227c[_0x39a2bd]['pairId']=_0x16227c[_0x46badd]['id'],_0x16227c[_0x46badd]['pairId']=_0x16227c[_0x39a2bd]['id'];}else _0x16227c[_0x46badd]['item']['startIndex']=_0x46badd,_0x16227c[_0x46badd]['item']['endIndex']=_0x46badd,_0x16227c[_0x46badd]['pairId']=null;}_0x16227c[_0x46badd]['markersStart']||(_0x16227c[_0x46badd]['markersStart']=[],_0x16227c[_0x46badd]['markersEnd']=[]);}}['_markInsertions'](_0x171d86,_0x34a803){const _0x239aeb=_0x171d86['filter'](_0x46a0b0=>!_0x46a0b0['isAdded']);for(let _0x1aeb4b=0x0;_0x1aeb4b<_0x34a803['length'];_0x1aeb4b++)_0x34a803[_0x1aeb4b]['isAdded']&&(_0x239aeb[_0x1aeb4b]['isAdded']=_0x34a803[_0x1aeb4b]['isAdded']);}['_getDiff'](_0x342f64,_0x4230eb=null){const _0x48387d=this['repository']['getRevision'](_0x342f64),_0x59d457=_0x4230eb?this['repository']['getRevision'](_0x4230eb):null,_0xff1b69=this['_getRevisionsRange'](_0x48387d,_0x59d457),_0x597e54=_0xff1b69[_0xff1b69['length']-0x1],_0x550d97=new Map(),_0x166062={'model':{},'attributes':{},'changes':[]},_0x5c3446=new Set(),_0xb43354=new Map();for(let _0x4df009=_0xff1b69['length']-0x1;_0x4df009>=0x0;_0x4df009--){const _0x23435=_0xff1b69[_0x4df009];for(const _0x36a728 of Object['keys'](_0x23435['diffData']))if(_0x23435['diffData'][_0x36a728]['attachChange']){const _0x5440a9=_0x23435['diffData'][_0x36a728]['attachChange'];_0x5440a9['isAttached']?(_0x5c3446['add'](_0x36a728),_0xb43354['has'](_0x36a728)&&_0xb43354['get'](_0x36a728)['userId']==_0x5440a9['userId']?_0xb43354['delete'](_0x36a728):_0xb43354['set'](_0x36a728,_0x5440a9)):_0xb43354['has'](_0x36a728)?(_0x5c3446['delete'](_0x36a728),_0xb43354['delete'](_0x36a728)):(_0x5c3446['add'](_0x36a728),_0xb43354['set'](_0x36a728,_0x5440a9));}else _0x5c3446['add'](_0x36a728);}for(const _0x195281 of _0x5c3446){const _0x4abfeb=_0xb43354['has'](_0x195281)&&!_0xb43354['get'](_0x195281)['isAttached'];let _0x154f35=_0x4abfeb?_0xff1b69['length']-0x1:0x0;const _0x43b7d5=_0x4abfeb?-0x1:0x1;for(;_0xff1b69[_0x154f35];){const _0x760b6=_0xff1b69[_0x154f35];if(_0x760b6['diffData'][_0x195281]){const _0x2ec2a1=_0x4abfeb?_0x760b6['diffData'][_0x195281]['attributesBefore']:_0x760b6['diffData'][_0x195281]['attributesAfter'];_0x166062['attributes'][_0x195281]=_0x2ec2a1?_0x5a4053(_0x2ec2a1):{};break;}_0x154f35+=_0x43b7d5;}}for(const _0x22d21c of _0xff1b69){_0x22d21c['model']={};for(const _0x50687e of _0x22d21c['authors'])_0x550d97['set'](_0x50687e['id'],_0x50687e);for(const _0x5b4d30 of _0x5c3446){const _0x276732=_0x22d21c['diffData'][_0x5b4d30]?_0x22d21c['diffData'][_0x5b4d30]['insertions']:'[]',_0x507d4c=_0x22d21c['diffData'][_0x5b4d30]?_0x22d21c['diffData'][_0x5b4d30]['deletions']:'[]';_0x22d21c['model'][_0x5b4d30]={'insertions':this['_utils']['_makeModelFromViewString'](_0x276732),'deletions':this['_utils']['_makeModelFromViewString'](_0x507d4c)};}}for(const _0x412790 of _0x5c3446){let _0x2cc87c=null,_0x3b9bc3=0x0;const _0x2dc43e=new Map(Array['from'](_0x48387d['model'][_0x412790]['insertions']['markers'])['filter'](([_0x14e971])=>!_0x14e971['startsWith']('revision:')));let _0x5996aa=0x0;for(const _0x3e5a27 of _0xff1b69){const _0x362df8=this['_makeTape'](_0x3e5a27['model'][_0x412790]['insertions']);_0x3e5a27==_0x48387d?(_0x2cc87c=_0x362df8,_0x3b9bc3=_0x2cc87c['length'],_0x2cc87c['forEach'](_0x306727=>{_0x306727['id']=_0x5996aa++;}),this['_processTape'](_0x2cc87c)):this['_markInsertions'](_0x2cc87c,_0x362df8);const _0xb94a79=_0x2cc87c['filter'](_0x1935fd=>!_0x1935fd['isAdded'])['map'](_0x2f586f=>_0x2f586f['id']);let _0x450df7=0x0;const _0x5cba01=this['_makeTape'](_0x3e5a27['model'][_0x412790]['deletions']);_0x5cba01['forEach'](_0xcaf766=>{_0xcaf766['isRemoved']?_0xcaf766['id']=_0x3b9bc3++:_0xcaf766['id']=_0xb94a79[_0x450df7++];}),this['_processTape'](_0x5cba01),this['_setDistance'](_0x2cc87c,'isAdded'),this['_setDistance'](_0x5cba01,'isRemoved'),_0x3e5a27==_0x48387d&&this['_markMarkers'](_0x2cc87c,_0x2dc43e),_0x2cc87c=this['_joinTapes'](_0x2cc87c,_0x5cba01),this['_refreshStartEndIndex'](_0x2cc87c),this['_setDistance'](_0x2cc87c,'isRemoved');}_0x2cc87c=_0x2cc87c['filter'](_0x4b35dd=>!(_0x4b35dd['isAdded']&&_0x4b35dd['isRemoved']));const _0x780cdc=new Map(_0x597e54['model'][_0x412790]['deletions']['markers']),_0xd37a76=new Set(_0x2dc43e['keys']());for(const _0x3a1770 of _0x780cdc['keys']())_0xd37a76['delete'](_0x3a1770);this['_markSuggestions'](_0x2cc87c,_0xd37a76),this['_fixObsoleteTags'](_0x2cc87c),_0x2cc87c=this['_removeMissingPairs'](_0x2cc87c),_0x2cc87c=this['_markMismatchedRemovedTags'](_0x2cc87c),_0x2cc87c=this['_removeUnsupportedChanges'](_0x2cc87c);const {root:_0x1630c2,changes:_0x500b67}=this['_makeModelFromTape'](_0x2cc87c,_0x550d97,_0x412790);_0x166062['model'][_0x412790]=_0x1630c2;const _0x1304fe=_0xb43354['get'](_0x412790);if(_0x1304fe){const _0x4565d9=_0x550d97['get'](_0x1304fe['userId']),_0xb32910=new r({'author':_0x4565d9,'type':_0x1304fe['isAttached']?'add':'remove','data':{'isOnRoot':!0x0},'createdAt':new Date(),'rootName':_0x412790});_0x500b67['unshift'](_0xb32910),_0x166062['attributes'][_0x412790]['revisionHistoryAttachChange']=_0xb32910['id'];}_0x166062['changes']=_0x166062['changes']['concat'](_0x500b67);}return _0x166062;}['_markMarkers'](_0x33f1b7,_0x3e15f0){for(let _0x551b6f=0x0;_0x551b6f<_0x33f1b7['length'];_0x551b6f++)for(const [_0x18bb11,_0xcbfa01]of _0x3e15f0)!_0xcbfa01['isCollapsed']&&_0xcbfa01['start']['isEqual'](_0x33f1b7[_0x551b6f]['previousPosition'])&&_0x33f1b7[_0x551b6f]['markersStart']['push'](_0x18bb11),_0xcbfa01['end']['isEqual'](_0x33f1b7[_0x551b6f]['nextPosition'])&&_0x33f1b7[_0x551b6f]['markersEnd']['push'](_0x18bb11);}['_joinTapes'](_0x485de4,_0x4ce40a){let _0x1c9820=[],_0x527898=0x0,_0x4b90c8=0x0;for(;_0x527898<_0x485de4['length']||_0x4b90c8<_0x4ce40a['length'];){const _0x201445=_0x485de4[_0x527898]||{},_0x5708e7=_0x4ce40a[_0x4b90c8]||{};if(_0x201445['id']==_0x5708e7['id'])_0x527898++,_0x4b90c8++,_0x1c9820['push'](_0x201445);else{if(_0x5708e7['isRemoved']&&_0x201445['isAdded']){const {commonTape:_0x2e70bd,iEnd:_0x5dddff,jEnd:_0x2ec751}=this['_threeWayMerge'](_0x485de4,_0x527898,_0x4ce40a,_0x4b90c8);_0x1c9820=_0x1c9820['concat'](_0x2e70bd),_0x527898=_0x5dddff,_0x4b90c8=_0x2ec751;}else _0x5708e7['isRemoved']?(_0x4b90c8++,_0x1c9820['push'](_0x5708e7)):(_0x527898++,_0x1c9820['push'](_0x201445));}}return _0x1c9820;}['_markSuggestions'](_0x552b06,_0x245d07){const _0x144d47=[];for(let _0x5054a3=0x0;_0x5054a3<_0x552b06['length'];_0x5054a3++){for(let _0x53cdae=0x0;_0x53cdae<_0x552b06[_0x5054a3]['markersStart']['length'];_0x53cdae++){const _0x43fc31=_0x552b06[_0x5054a3]['markersStart'][_0x53cdae];if(!_0x245d07['has'](_0x43fc31))continue;const {group:_0x392c27,type:_0x2dc0aa,authorId:_0x35192e}=_0x4ab123(_0x43fc31);'revision-suggestion'!=_0x392c27||'insertion'!=_0x2dc0aa&&'deletion'!=_0x2dc0aa||(_0x144d47['unshift']({'type':_0x2dc0aa,'name':_0x43fc31,'userId':_0x35192e}),_0x552b06[_0x5054a3]['markersStart']['splice'](_0x53cdae,0x1),_0x53cdae--);}_0x365c80(_0x552b06[_0x5054a3]);for(let _0x5f2182=0x0;_0x5f2182<_0x552b06[_0x5054a3]['markersEnd']['length'];_0x5f2182++){const _0x4ba977=_0x552b06[_0x5054a3]['markersEnd'][_0x5f2182];if(!_0x245d07['has'](_0x4ba977))continue;const {group:_0x2a011c,type:_0x222e3c}=_0x4ab123(_0x4ba977);if('revision-suggestion'!=_0x2a011c||'insertion'!=_0x222e3c&&'deletion'!=_0x222e3c)continue;_0x552b06[_0x5054a3]['markersEnd']['splice'](_0x5f2182,0x1),_0x5f2182--;const _0x566e95=_0x144d47['findIndex'](_0x5ec67f=>_0x5ec67f['name']==_0x4ba977);_0x566e95>-0x1&&_0x144d47['splice'](_0x566e95,0x1);}}function _0x4ab123(_0x2e895a){const _0xe05698=_0x2e895a['split'](':');return{'group':_0xe05698[0x0],'type':_0xe05698[0x1],'subType':_0xe05698['length']>=0x5?_0xe05698[0x2]:null,'id':_0xe05698['length']<0x5?_0xe05698[0x2]:_0xe05698[0x3],'authorId':_0xe05698['length']<0x5?_0xe05698[0x3]:_0xe05698[0x4],'markerCount':0x6==_0xe05698['length']?_0xe05698[0x5]:null};}function _0x365c80(_0x19f3e4){for(let _0x4dcd61=0x0;_0x4dcd61<_0x144d47['length'];_0x4dcd61++){if(_0x19f3e4['isAdded']&&'insertion'==_0x144d47[_0x4dcd61]['type']&&_0x19f3e4['isAdded']['userId']==_0x144d47[_0x4dcd61]['userId'])return _0x19f3e4['isAddSuggestion']=_0x144d47[_0x4dcd61],void delete _0x19f3e4['isAdded'];if(!_0x19f3e4['isAdded']&&!_0x19f3e4['isRemoved']&&'deletion'==_0x144d47[_0x4dcd61]['type'])return void(_0x19f3e4['isRemoveSuggestion']=_0x144d47[_0x4dcd61]);}}}['_setDistance'](_0x31ce3f,_0x8ed509){let _0x5b07f4=0x0,_0x58e987=!0x1;const _0x3cb0e3=new Map();for(const _0x11d1a9 of _0x31ce3f)_0x11d1a9[_0x8ed509]?_0x58e987&&(_0x5b07f4++,_0x58e987=!0x1):(_0x5b07f4++,_0x58e987=!0x0),_0x3cb0e3['set'](_0x11d1a9['id'],_0x5b07f4);for(let _0x353e4b=0x0;_0x353e4b<_0x31ce3f['length'];_0x353e4b++){if('isRemoved'==_0x8ed509&&_0x31ce3f[_0x353e4b]['isAdded']||'isAdded'==_0x8ed509&&_0x31ce3f[_0x353e4b]['isRemoved'])continue;if('text'==_0x31ce3f[_0x353e4b]['type']){_0x31ce3f[_0x353e4b]['distance']=0x0;continue;}const _0x3ad140=_0x3cb0e3['get'](_0x31ce3f[_0x353e4b]['pairId']),_0x58cf24=_0x3cb0e3['get'](_0x31ce3f[_0x353e4b]['id']);_0x31ce3f[_0x353e4b]['distance']=_0x3ad140-_0x58cf24;}}['_getRevisionsRange'](_0x4187d1,_0x434578,_0x53a569=!0x1){const _0x1a907c=[];let _0x31537b=this['repository']['getIndex'](_0x4187d1),_0x1431c3=this['repository']['getIndex'](_0x434578);for(-0x1==_0x1431c3&&(_0x1431c3=this['repository']['_revisions']['length'],_0x53a569=!0x1);_0x31537b<_0x1431c3;)_0x1a907c['push'](this['repository']['getRevision'](_0x31537b)),_0x31537b++;return _0x53a569&&_0x1a907c['push'](this['repository']['getRevision'](_0x31537b)),_0x1a907c;}['_threeWayMerge'](_0x692339,_0x508e32,_0x4220cc,_0x38aef5){const _0x14454e=this['editor']['model']['schema'];let _0x2145e1=_0x508e32;for(;_0x692339[_0x2145e1]&&_0x692339[_0x2145e1]['isAdded'];)_0x2145e1++;let _0x1cda58=_0x38aef5;for(;_0x4220cc[_0x1cda58]&&_0x4220cc[_0x1cda58]['isRemoved'];)_0x1cda58++;_0xbee888(_0x692339,_0x508e32,_0x2145e1),_0xbee888(_0x4220cc,_0x38aef5,_0x1cda58);const _0x5a9c2e=_0x4220cc['slice'](_0x38aef5,_0x1cda58)['concat'](_0x692339['slice'](_0x508e32,_0x2145e1));return _0x5a9c2e['sort']((_0x37e833,_0x5e5b17)=>_0x37e833['side']!=_0x5e5b17['side']?_0x37e833['side']-_0x5e5b17['side']:_0x37e833['level']!=_0x5e5b17['level']?_0x37e833['level']-_0x5e5b17['level']:_0x37e833['distance']!=_0x5e5b17['distance']?_0x5e5b17['distance']-_0x37e833['distance']:!!_0x37e833['isAdded']!=!!_0x5e5b17['isAdded']?-0x1==_0x37e833['side']||0x0==_0x37e833['side']?_0x37e833['isAdded']?-0x1:0x1:_0x37e833['isAdded']?0x1:-0x1:_0x37e833['index']-_0x5e5b17['index']),{'commonTape':_0x5a9c2e,'iEnd':_0x2145e1,'jEnd':_0x1cda58};function _0xbee888(_0x476e20,_0x39d190,_0x3c5b75){let _0xc48845=-0x1,_0x1467cd=Number['POSITIVE_INFINITY'],_0x4afbc7=!0x0;for(let _0x19e0e8=_0x39d190;_0x19e0e8<_0x3c5b75;_0x19e0e8++)if(_0x14454e['isInline'](_0x476e20[_0x19e0e8]['item'])||(_0x4afbc7=!0x1),_0x476e20[_0x19e0e8]['item']['startIndex']<_0x39d190&&(_0xc48845=_0x19e0e8),_0x476e20[_0x19e0e8]['item']['endIndex']>=_0x3c5b75){_0x1467cd=_0x19e0e8;break;}_0x4afbc7&&(_0xc48845=_0x3c5b75-0x1);for(let _0x35fb9a=_0x39d190;_0x35fb9a<_0x3c5b75;_0x35fb9a++)_0x476e20[_0x35fb9a]['side']=_0x35fb9a<=_0xc48845?-0x1:_0x35fb9a<_0x1467cd?0x0:0x1,_0x476e20[_0x35fb9a]['index']=_0x35fb9a;let _0x124f1e=0x0;for(let _0x5b93bf=_0x39d190;_0x5b93bf<=_0xc48845;_0x5b93bf++)0x0==_0x476e20[_0x5b93bf]['distance']?_0x476e20[_0x5b93bf]['level']=_0x124f1e:(_0x124f1e++,_0x476e20[_0x5b93bf]['level']=_0x124f1e,_0x124f1e++);for(let _0x35a209=_0x39d190;_0x35a209<_0x3c5b75;_0x35a209++)0x0==_0x476e20[_0x35a209]['side']&&(_0x476e20[_0x35a209]['level']=_0x124f1e);_0x124f1e=0x0;for(let _0x35db6b=_0x3c5b75-0x1;_0x35db6b>=_0x1467cd;_0x35db6b--)0x0==_0x476e20[_0x35db6b]['distance']?_0x476e20[_0x35db6b]['level']=_0x124f1e:(_0x124f1e--,_0x476e20[_0x35db6b]['level']=_0x124f1e,_0x124f1e--);}}['_fixObsoleteTags'](_0x4727e8){const _0x45bb7d=new Map(),_0x471a4b=this['editor']['model']['schema'];for(let _0x3503eb=0x1;_0x3503eb<_0x4727e8['length'];_0x3503eb++){let _0x3b5214,_0x20049f,_0x5f8507;const _0x1b7198=_0x4727e8[_0x3503eb],_0x252bd3=_0x4727e8[_0x3503eb-0x1];if('text'==_0x1b7198['type'])continue;if(_0x1b7198['type']!=_0x252bd3['type'])continue;if(!_0x471a4b['isBlock'](_0x252bd3['item'])||_0x471a4b['isLimit'](_0x252bd3['item']))continue;if(!_0x471a4b['isBlock'](_0x1b7198['item'])||_0x471a4b['isLimit'](_0x1b7198['item']))continue;if((_0x4727e8[_0x3503eb]['isAdded']||_0x4727e8[_0x3503eb]['isAddSuggestion'])&&_0x4727e8[_0x3503eb-0x1]['isRemoved'])_0x3b5214=_0x4727e8[_0x3503eb],_0x20049f=_0x4727e8[_0x3503eb-0x1],_0x5f8507=_0x3503eb-0x1;else{if(!_0x4727e8[_0x3503eb]['isRemoved']||!_0x4727e8[_0x3503eb-0x1]['isAdded']&&!_0x4727e8[_0x3503eb-0x1]['isAddSuggestion'])continue;_0x3b5214=_0x4727e8[_0x3503eb-0x1],_0x20049f=_0x4727e8[_0x3503eb],_0x5f8507=_0x3503eb;}const _0x304dd8=_0x3b5214['level']==_0x20049f['level'],_0x29ca92=Math['abs'](_0x3b5214['level'])<Math['abs'](_0x20049f['level'])&&0x0==_0x20049f['distance'];(_0x304dd8||_0x29ca92)&&(_0x45bb7d['set'](_0x20049f['id'],_0x3b5214['id']),_0x4727e8['splice'](_0x5f8507,0x1),_0x3503eb--,_0x3b5214['isAdded']=!0x1);}for(let _0x3a72c6=0x0;_0x3a72c6<_0x4727e8['length'];_0x3a72c6++)_0x45bb7d['has'](_0x4727e8[_0x3a72c6]['pairId'])&&(_0x4727e8[_0x3a72c6]['pairId']=_0x45bb7d['get'](_0x4727e8[_0x3a72c6]['pairId']));}['_removeMissingPairs'](_0x49368c){const _0x365cb9=new Set(_0x49368c['map'](_0x28dc8a=>_0x28dc8a['id']));for(let _0x3c85b6=0x0;_0x3c85b6<_0x49368c['length'];_0x3c85b6++)_0x365cb9['has'](_0x49368c[_0x3c85b6]['pairId'])||0x0==_0x49368c[_0x3c85b6]['distance']||(_0x49368c[_0x3c85b6]['isIncorrect']=!0x0);return _0x49368c['filter'](_0x52628f=>!_0x52628f['isIncorrect']);}['_markMismatchedRemovedTags'](_0x4c5285){const _0x5ed71f=new Set();for(let _0x56a14d=0x0;_0x56a14d<_0x4c5285['length'];_0x56a14d++){if(_0x5ed71f['has'](_0x4c5285[_0x56a14d]['id'])&&_0x4c5285[_0x56a14d]['isRemoved']&&(_0x4c5285[_0x56a14d]['isIncorrect']=!0x0),_0x4c5285[_0x56a14d]['isIncorrect'])continue;if(0x0==_0x4c5285[_0x56a14d]['distance'])continue;if('elementStart'!=_0x4c5285[_0x56a14d]['type'])continue;if(null==_0x4c5285[_0x56a14d]['pairId'])continue;let _0x1c1b86=_0x56a14d+0x1,_0x3a7fe4=0x0;for(;_0x4c5285[_0x1c1b86]['id']!=_0x4c5285[_0x56a14d]['pairId'];)'elementStart'==_0x4c5285[_0x1c1b86]['type']?_0x3a7fe4++:'elementEnd'==_0x4c5285[_0x1c1b86]['type']&&_0x3a7fe4--,_0x1c1b86++;if(0x0!=_0x3a7fe4){if(_0x4c5285[_0x56a14d]['isRemoved'])_0x4c5285[_0x56a14d]['isIncorrect']=!0x0;else{for(;_0x1c1b86!=_0x56a14d;)_0x4c5285[_0x1c1b86]['isRemoved']&&0x0!=_0x4c5285[_0x1c1b86]['distance']&&(_0x4c5285[_0x1c1b86]['isIncorrect']=!0x0,_0x5ed71f['add'](_0x4c5285[_0x1c1b86]['pairId'])),_0x1c1b86--;}}}return _0x4c5285['filter'](_0x18c1d9=>!_0x18c1d9['isIncorrect']);}['_removeUnsupportedChanges'](_0x2d1d6f){const _0x3b53a6=this['editor']['model']['schema'];for(let _0x3b9ba9=0x0;_0x3b9ba9<_0x2d1d6f['length'];_0x3b9ba9++){if(!(_0x2d1d6f[_0x3b9ba9]['isAdded']||_0x2d1d6f[_0x3b9ba9]['isAddSuggestion']||_0x2d1d6f[_0x3b9ba9]['isRemoved']||_0x2d1d6f[_0x3b9ba9]['isRemoveSuggestion']))continue;if(0x0==_0x2d1d6f[_0x3b9ba9]['distance'])continue;const _0x4a2cfd=_0x2d1d6f[_0x3b9ba9]['item'];_0x3b53a6['isBlock'](_0x4a2cfd)||_0x3b53a6['isLimit'](_0x4a2cfd)||(_0x2d1d6f[_0x3b9ba9]['isAdded']&&delete _0x2d1d6f[_0x3b9ba9]['isAdded'],_0x2d1d6f[_0x3b9ba9]['isAddSuggestion']&&delete _0x2d1d6f[_0x3b9ba9]['isAddSuggestion'],_0x2d1d6f[_0x3b9ba9]['isRemoveSuggestion']&&delete _0x2d1d6f[_0x3b9ba9]['isRemoveSuggestion'],_0x2d1d6f[_0x3b9ba9]['isRemoved']&&(_0x2d1d6f[_0x3b9ba9]['isIncorrect']=!0x0));}return _0x2d1d6f['filter'](_0x13bb93=>!_0x13bb93['isIncorrect']);}['_makeModelFromTape'](_0x37a39c,_0x1d37fa,_0x320c62){const _0x220ab0=new vt(),_0x4df72b=[],_0x32d1ba=new Map(),_0x558d38=this['editor']['model'],_0x4fecef=_0x558d38['schema'],_0x5c066b=[_0x220ab0],_0x1a53ad={},_0x1d9327={'isAdded':[],'isRemoved':[],'isAddSuggestion':[],'isRemoveSuggestion':[]};let _0x445006=null;const _0x2a99d7=[0x0];for(let _0x2766e2=0x0;_0x2766e2<_0x37a39c['length'];_0x2766e2++)if('elementStart'===_0x37a39c[_0x2766e2]['type']){_0x37a39c[_0x2766e2]['previousPosition']=_0x558d38['createPositionFromPath'](_0x220ab0,_0x2a99d7);const _0x67d43f=new ut(_0x37a39c[_0x2766e2]['item']['name'],_0x37a39c[_0x2766e2]['item']['getAttributes']());_0x5c066b[0x0]['_appendChild'](_0x67d43f),_0x2a99d7['push'](0x0),_0x5c066b['unshift'](_0x67d43f),_0x37a39c[_0x2766e2]['nextPosition']=_0x558d38['createPositionFromPath'](_0x220ab0,_0x2a99d7);}else'elementEnd'===_0x37a39c[_0x2766e2]['type']?(_0x5c066b['shift'](),_0x37a39c[_0x2766e2]['previousPosition']=_0x558d38['createPositionFromPath'](_0x220ab0,_0x2a99d7),_0x2a99d7['pop'](),_0x2a99d7[_0x2a99d7['length']-0x1]++,_0x37a39c[_0x2766e2]['nextPosition']=_0x558d38['createPositionFromPath'](_0x220ab0,_0x2a99d7)):(_0x37a39c[_0x2766e2]['previousPosition']=_0x558d38['createPositionFromPath'](_0x220ab0,_0x2a99d7),_0x445006?_0x445006['_data']+=_0x37a39c[_0x2766e2]['item']['data']:_0x445006=new gt(_0x37a39c[_0x2766e2]['item']['data'],_0x37a39c[_0x2766e2]['item']['getAttributes']()),_0x37a39c[_0x2766e2+0x1]&&'text'===_0x37a39c[_0x2766e2+0x1]['type']&&_0x4b4e48(_0x445006,_0x37a39c[_0x2766e2+0x1]['item'])||(_0x5c066b[0x0]['_appendChild'](_0x445006),_0x445006=null),_0x2a99d7[_0x2a99d7['length']-0x1]+=_0x37a39c[_0x2766e2]['item']['offsetSize'],_0x37a39c[_0x2766e2]['nextPosition']=_0x558d38['createPositionFromPath'](_0x220ab0,_0x2a99d7));for(let _0x32beac=0x0;_0x32beac<_0x37a39c['length'];_0x32beac++){const _0xb1e165=_0x37a39c[_0x32beac]['previousPosition'],_0x1076e8=_0x37a39c[_0x32beac]['nextPosition'];for(const _0x429a7c of _0x37a39c[_0x32beac]['markersStart'])_0x32d1ba['set'](_0x429a7c,{'start':_0xb1e165,'end':null});_0x53ad0d('isRemoveSuggestion',_0x32beac,_0xb1e165,_0x1076e8),_0x53ad0d('isAddSuggestion',_0x32beac,_0xb1e165,_0x1076e8),_0x53ad0d('isRemoved',_0x32beac,_0xb1e165,_0x1076e8),_0x53ad0d('isAdded',_0x32beac,_0xb1e165,_0x1076e8);for(const _0xad8e44 of _0x37a39c[_0x32beac]['markersEnd']){const _0x28b357=_0x32d1ba['get'](_0xad8e44);_0x28b357?_0x28b357['end']=_0x1076e8:_0x32d1ba['set'](_0xad8e44,{'start':_0x1076e8,'end':_0x1076e8});}}for(const [_0x2f14af,_0x6f51c8]of _0x32d1ba){const _0x147ffc=this['editor']['model']['createRange'](_0x6f51c8['start'],_0x6f51c8['end']);_0x220ab0['markers']['set'](_0x2f14af,_0x147ffc);}return _0x4df72b['sort']((_0xcb5527,_0x199456)=>{const _0x37a278=_0x220ab0['markers']['get']('revision:'+_0xcb5527['id']),_0xa6ecd7=_0x220ab0['markers']['get']('revision:'+_0x199456['id']);return _0x37a278['start']['isBefore'](_0xa6ecd7['start'])?-0x1:_0x37a278['start']['isAfter'](_0xa6ecd7['start'])?0x1:_0x37a278['end']['isBefore'](_0xa6ecd7['end'])?-0x1:_0x37a278['end']['isAfter'](_0xa6ecd7['end'])?0x1:'add'===_0xcb5527['type']?-0x1:0x1;}),{'root':_0x220ab0,'changes':_0x4df72b};function _0x53ad0d(_0x23d63f,_0x4ae5b1,_0x5e4265,_0x21eb8f){const _0x3eeda7=!!_0x37a39c[_0x4ae5b1][_0x23d63f],_0x5579a0=_0x3eeda7?_0x37a39c[_0x4ae5b1][_0x23d63f]['userId']:null,_0x3d69f2=_0x4ae5b1===_0x37a39c['length']-0x1,_0x1b751a=_0x1d9327[_0x23d63f][0x0],_0x5b3f6f=_0x4fecef['isObject'](_0x37a39c[_0x4ae5b1]['item']);!_0x1a53ad[_0x23d63f]&&_0x3eeda7?_0x1a53ad[_0x23d63f]={'start':_0x5e4265,'tapeItem':_0x37a39c[_0x4ae5b1],'userId':_0x5579a0,'type':_0x23d63f}:_0x1a53ad[_0x23d63f]&&!_0x3eeda7?(_0x1a53ad[_0x23d63f]['end']=_0x5e4265,_0xd18ed5(_0x1a53ad[_0x23d63f]),_0x1a53ad[_0x23d63f]=null):_0x1a53ad[_0x23d63f]&&_0x3eeda7&&_0x1a53ad[_0x23d63f]['userId']!==_0x5579a0&&(_0x1a53ad[_0x23d63f]['end']=_0x5e4265,_0x1b751a&&_0x1b751a['userId']===_0x1a53ad[_0x23d63f]['userId']||_0xd18ed5(_0x1a53ad[_0x23d63f]),_0x1a53ad[_0x23d63f]={'start':_0x5e4265,'tapeItem':_0x37a39c[_0x4ae5b1],'userId':_0x5579a0,'type':_0x23d63f}),_0x1a53ad[_0x23d63f]&&_0x5b3f6f&&('elementStart'!==_0x37a39c[_0x4ae5b1]['type']||_0x1b751a&&_0x1b751a['userId']===_0x5579a0||_0x1d9327[_0x23d63f]['unshift']({'userId':_0x5579a0,'object':_0x37a39c[_0x4ae5b1]['item'],'change':_0x1a53ad[_0x23d63f]}),'elementEnd'===_0x37a39c[_0x4ae5b1]['type']&&_0x1b751a&&_0x1b751a['object']===_0x37a39c[_0x4ae5b1]['item']&&(_0x1d9327[_0x23d63f]['shift'](),_0x1a53ad[_0x23d63f]=_0x1b751a['change'])),_0x1a53ad[_0x23d63f]&&_0x3d69f2&&(_0x1a53ad[_0x23d63f]['end']=_0x21eb8f,_0xd18ed5(_0x1a53ad[_0x23d63f]),_0x1a53ad[_0x23d63f]=null);}function _0xd18ed5({start:_0xd545ad,end:_0x5213d3,tapeItem:_0x1c81b5,userId:_0x4dd24e,type:_0x214523}){const _0x36ccff=_0x1c81b5['item'],_0xf52b21=_0x558d38['schema']['isBlock'](_0x36ccff)&&!_0x558d38['schema']['isLimit'](_0x36ccff),_0x2414db=_0xd545ad['nodeAfter']==_0x5213d3['parent']&&_0x5213d3['isAtStart'];if(_0xf52b21&&_0x2414db)return;const _0x39a49f=_0x558d38['createRange'](_0xd545ad,_0x5213d3),_0x5577ae=_0x1d37fa['get'](_0x4dd24e),_0x499144=new r({'author':_0x5577ae,'type':'isAdded'==_0x214523||'isAddSuggestion'==_0x214523?'add':'remove','data':{'isSuggestion':'isAddSuggestion'==_0x214523||'isRemoveSuggestion'==_0x214523},'createdAt':new Date(),'rootName':_0x320c62});_0x4df72b['push'](_0x499144),_0x220ab0['markers']['set']('revision:'+_0x499144['id'],_0x39a49f);}function _0x4b4e48(_0x531713,_0x18314b){const _0xe36609=_0x531713['getAttributes'](),_0x5db421=_0x18314b['getAttributes']();for(const _0x213960 of _0xe36609){if(_0x213960[0x1]!==_0x18314b['getAttribute'](_0x213960[0x0]))return!0x1;_0x5db421['next']();}return _0x5db421['next']()['done'];}}['_setConversion'](){this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision','view':_0x77093e=>{const _0x43fd27=_0x77093e['markerName']['split'](':')[0x1],_0x5a3d29=this['_getChangeFromId'](_0x43fd27);if(!_0x5a3d29)return null;const _0x5a1a9e='add'==_0x5a3d29['type']?'insertion':'deletion',_0x4f64bd=['ck-suggestion-marker','ck-suggestion-marker-'+_0x5a1a9e];return _0x5a3d29['data']['isSuggestion']&&_0x4f64bd['push']('ck-suggestion-marker-'+_0x5a1a9e+'-new'),this['activeChange']==_0x5a3d29&&_0x4f64bd['push']('ck-suggestion-marker--active'),{'classes':_0x4f64bd,'attributes':{'data-change-id':_0x43fd27}};}}),this['editor']['conversion']['for']('upcast')['add'](_0x3db821=>{_0x3db821['on']('element:pre',(_0x2e7f57,_0xb39831,_0xb0b3dd)=>{const _0x347311=_0xb39831['viewItem']['getChild'](0x0);if(!_0x347311||!_0x347311['is']('element','code'))return;if(!_0xb0b3dd['consumable']['consume'](_0x347311,{'attributes':['vid_start','vid_end']}))return;const _0x4cef93=_0xb39831['modelRange']['start']['nodeAfter'];_0xb0b3dd['writer']['setAttribute']('vid_start',_0x347311['getAttribute']('vid_start'),_0x4cef93),_0xb0b3dd['writer']['setAttribute']('vid_end',_0x347311['getAttribute']('vid_end'),_0x4cef93);},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['add'](_0x432e3b=>{_0x432e3b['on']('element',(_0x1fc000,_0x13783b,_0x50433f)=>{if(!_0x50433f['consumable']['consume'](_0x13783b['viewItem'],{'attributes':['vid_start','vid_end']}))return;if(_0x13783b['modelRange']['isCollapsed'])return;const _0x6c806e=_0x13783b['modelRange']['start']['nodeAfter'];_0x6c806e['hasAttribute']('vid_start')||_0x6c806e['hasAttribute']('vid')||(_0x50433f['writer']['setAttribute']('vid_start',_0x13783b['viewItem']['getAttribute']('vid_start'),_0x6c806e),_0x50433f['writer']['setAttribute']('vid_end',_0x13783b['viewItem']['getAttribute']('vid_end'),_0x6c806e));},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['elementToAttribute']({'view':{'name':'span','attributes':{'vid':!0x0}},'model':{'key':'vid','value':_0x47da6d=>_0x47da6d['getAttribute']('vid')}}),this['editor']['model']['schema']['on']('checkAttribute',(_0x1b8dc6,[,_0x18a699])=>{['vid_start','vid_end','vid']['includes'](_0x18a699)&&(_0x1b8dc6['return']=!0x0,_0x1b8dc6['stop']());},{'priority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x576819=>{_0x576819['on']('attribute:vid',(_0x24569f,_0x3db69d,_0xb3ba1d)=>{if('\x20'!=_0x3db69d['item']['data']||_0x3db69d['item']['parent']['maxOffset']>0x1)return;if(!_0xb3ba1d['consumable']['consume'](_0x3db69d['item'],_0x24569f['name']))return;const _0x5c7a84=_0xb3ba1d['writer'],_0x59a1c1=_0xb3ba1d['mapper']['toViewRange'](_0x3db69d['range']);_0x5c7a84['wrap'](_0x59a1c1,_0x5c7a84['createAttributeElement']('span'));});}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',function(_0x2f11d5){const _0x357606=_0x2f11d5['plugins']['get']('RevisionViewer');return(_0x5701bf,_0x279d1b,_0x2a32b3)=>{const _0x492b10=_0x279d1b['markerName']['split'](':')[0x1],_0x5094e9=_0x357606['_getChangeFromId'](_0x492b10);if(!_0x5094e9)return null;const _0x46afc9='add'==_0x5094e9['type']?'split':'merge';if(!_0x2a32b3['consumable']['test'](_0x279d1b['markerRange'],_0x5701bf['name']))return;const _0x19038a=_0x279d1b['markerRange']['getWalker'](),_0x54e7e8=_0x279d1b['markerRange']['start'],_0x2f4edf=_0x2f11d5['model']['schema'];let _0x17952e=null,_0x58217a=null,_0x536d5b=!0x1,_0x13b674=!0x1;for(const _0x412f5c of _0x19038a){const _0x5a70e7=_0x412f5c['item'];_0x536d5b=_0x536d5b||_0x2f4edf['isContent'](_0x5a70e7);const _0x38d4ce=_0x2a32b3['mapper']['toViewElement'](_0x5a70e7);if(_0x38d4ce&&_0x38d4ce['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x412f5c['type']&&(_0x2f4edf['isBlock'](_0x5a70e7)&&!_0x2f4edf['isLimit'](_0x5a70e7)&&(_0x5a70e7['nextSibling']||_0x54e7e8['isAtEnd']?_0x17952e&&_0x17952e['parent']==_0x5a70e7||(_0x17952e=_0x5a70e7,_0x55a184(_0x412f5c['previousPosition']),_0x13b674=!0x0):_0x58217a=_0x58217a||_0x412f5c['previousPosition']));}function _0x55a184(_0x84921){const _0x17cdbf=_0x2a32b3['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x46afc9}),_0x5d878e=_0x2a32b3['mapper']['toViewPosition'](_0x84921);_0x5094e9['data']['isSuggestion']&&_0x2a32b3['writer']['addClass']('ck-suggestion-marker-'+_0x46afc9+'-new',_0x17cdbf),_0x357606['activeChange']==_0x5094e9&&_0x2a32b3['writer']['addClass']('ck-suggestion-marker--active',_0x17cdbf),_0x2a32b3['writer']['insert'](_0x5d878e,_0x17cdbf),_0x2a32b3['mapper']['bindElementToMarker'](_0x17cdbf,_0x279d1b['markerName']);}_0x536d5b||_0x13b674||!_0x58217a||_0x55a184(_0x58217a);};}(this['editor']),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision',(_0x17258c,_0x2a98a2,_0x5e61ef)=>{const _0x17898b=_0x5e61ef['mapper']['markerNameToElements'](_0x2a98a2['markerName']);if(_0x17898b){for(const _0x461124 of _0x17898b)(_0x461124['hasClass']('ck-suggestion-marker-split')||_0x461124['hasClass']('ck-suggestion-marker-merge'))&&(_0x5e61ef['mapper']['unbindElementFromMarkerName'](_0x461124,_0x2a98a2['markerName']),_0x5e61ef['writer']['remove'](_0x461124));}},{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',(_0x46462e,_0x3d20a1,_0x201ef4)=>{const _0x41f858=_0x3d20a1['markerName']['split'](':')[0x1],_0x1e7c65=this['_getChangeFromId'](_0x41f858);if(!_0x1e7c65)return null;const _0x14cf4f='add'==_0x1e7c65['type']?'split':'merge';if(_0x201ef4['consumable']['test'](_0x3d20a1['markerRange'],_0x46462e['name']))for(const _0x4feb17 of _0x3d20a1['markerRange']['getItems']()){if(!_0x4feb17['is']('element','softBreak'))continue;const _0x66fd3=_0x201ef4['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x14cf4f}),_0x284594=_0x201ef4['mapper']['toViewPosition'](this['editor']['model']['createPositionBefore'](_0x4feb17));_0x1e7c65['data']['isSuggestion']&&_0x201ef4['writer']['addClass']('ck-suggestion-marker-'+_0x14cf4f+'-new',_0x66fd3),this['activeChange']==_0x1e7c65&&_0x201ef4['writer']['addClass']('ck-suggestion-marker--active',_0x66fd3),_0x201ef4['writer']['insert'](_0x284594,_0x66fd3),_0x201ef4['mapper']['bindElementToMarker'](_0x66fd3,_0x3d20a1['markerName']);}},{'priority':'high'}),this['editor']['model']['document']['on']('change',()=>{this['editor']['editing']['view']['change'](_0x2534bd=>{for(const _0x36814b of this['editor']['model']['document']['getRootNames']()){const _0x12652b=this['editor']['model']['document']['getRoot'](_0x36814b),_0x44ad20=this['editor']['editing']['view']['document']['getRoot'](_0x36814b);if(_0x44ad20){const _0x1d9703=_0x12652b['getAttribute']('revisionHistoryAttachChange');if(_0x2534bd['removeAttribute']('data-change-id',_0x44ad20),_0x2534bd['removeClass']('ck-revision-history-root-add',_0x44ad20),_0x2534bd['removeClass']('ck-revision-history-root-remove',_0x44ad20),_0x2534bd['removeClass']('ck-revision-history-root--active',_0x44ad20),_0x1d9703){const _0x48ef30=this['_getChangeFromId'](_0x1d9703);if(!_0x48ef30)return null;_0x2534bd['setAttribute']('data-change-id',_0x1d9703,_0x44ad20),_0x2534bd['addClass']('ck-revision-history-root-'+_0x48ef30['type'],_0x44ad20),this['activeChange']==_0x48ef30&&_0x2534bd['addClass']('ck-revision-history-root--active',_0x44ad20);}}}});}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'comment','model':_0x204228=>'revision-comment:'+_0x204228,'converterPriority':'highest'}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'suggestion','model':_0x3b95be=>'revision-suggestion:'+_0x3b95be,'converterPriority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision-suggestion','view':_0x192dfc=>({'name':'suggestion:'+_0x192dfc,'group':'revision-suggestion'}),'converterPriority':'highest'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision-suggestion','view':_0x5743da=>{const _0x295a57=_0x5743da['markerName']['split'](':')[0x1];return'insertion'!=_0x295a57&&'deletion'!=_0x295a57?null:{'classes':['ck-suggestion-preview-marker','ck-suggestion-preview-marker-'+_0x295a57]};}}),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',(_0x41ce99,_0x25223c,_0xb22819)=>{const _0x591872=_0xb22819['mapper']['markerNameToElements'](_0x25223c['markerName']);if(_0x591872){for(const _0x582280 of _0x591872)_0x582280['is']('uiElement')&&(_0xb22819['mapper']['unbindElementFromMarkerName'](_0x582280,_0x25223c['markerName']),_0xb22819['writer']['remove'](_0x582280));}},{'priority':'high'});}['_getChangeFromId'](_0x365105){return this['_changeIdToChange']['get'](_0x365105);}['_getViewForChange'](_0x999089){return this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=new Q(this['editor']['locale'],_0x999089),this['_changeView'];}['_initInteractions'](){this['editor']['model']['document']['selection']['observeMarkers']('revision'),this['on']('change:activeView',(_0x1dae7b,_0x28fc7d,_0x1fcdae,_0x37d773)=>{_0x37d773&&this['_balloon']['remove'](_0x37d773),_0x1fcdae&&(this['_balloon']['add']({'view':_0x1fcdae,'stackId':'revisionHistoryLabel','position':{'target':()=>{const _0x15b596=this['editor']['editing'],_0x543cab=this['_getChangeFromId'](_0x1fcdae['changeId']);let _0x1dc99a;if(_0x543cab['data']['isOnRoot']){const _0x349e64=_0x15b596['view']['getDomRoot'](_0x543cab['rootName']);_0x1dc99a=Array['from'](_0x349e64['getClientRects']());}else{const _0x335ac8=this['editor']['model']['markers']['get']('revision:'+_0x1fcdae['changeId']);_0x1dc99a=Array['from'](_0x15b596['mapper']['markerNameToElements'](_0x335ac8['name']))['map'](_0x50f2a8=>_0x15b596['view']['domConverter']['mapViewToDom'](_0x50f2a8))['map'](_0x4b10bb=>Array['from'](_0x4b10bb['getClientRects']()))['flat']();}if(!this['_activeViewTarget'])return _0x1dc99a[0x0];return _0x1dc99a['find'](_0x444e9e=>_0x444e9e['top']-0x3<=this['_activeViewTarget']['y']&&_0x444e9e['bottom']+0x3>=this['_activeViewTarget']['y']&&_0x444e9e['left']-0x3<=this['_activeViewTarget']['x']&&_0x444e9e['right']+0x3>=this['_activeViewTarget']['x'])||_0x1dc99a[0x0];}}}),this['_balloon']['showStack']('revisionHistoryLabel'));}),this['on']('change:activeChange',(_0x4de782,_0x3d22ac,_0x103ced,_0x16ef7f)=>{this['activeView']=_0x103ced?this['_getViewForChange'](_0x103ced):null,this['editor']['model']['change'](()=>{const _0x4bb97e=this['editor']['editing'];_0x16ef7f&&(_0x16ef7f['data']['isOnRoot']?_0x4bb97e['view']['change'](_0x10d1cb=>{_0x10d1cb['removeClass']('ck-revision-history-root--active',_0x4bb97e['view']['document']['getRoot'](_0x16ef7f['rootName']));}):_0x4bb97e['reconvertMarker']('revision:'+_0x16ef7f['id'])),_0x103ced&&(_0x103ced['data']['isOnRoot']?_0x4bb97e['view']['change'](_0x3e5958=>{_0x3e5958['addClass']('ck-revision-history-root--active',_0x4bb97e['view']['document']['getRoot'](_0x103ced['rootName']));}):_0x4bb97e['reconvertMarker']('revision:'+_0x103ced['id']));});}),this['listenTo'](this['editor']['editing']['view']['document'],'mouseover',(_0x2a43af,_0x321d2e)=>{if(this['activeChange'])return;const _0x5aba80=this['_findChangeIdFromDomTarget'](_0x321d2e['target']),_0x2ddc77=this['_changeIdToChange']['get'](_0x5aba80);_0x2ddc77?(this['_activeViewTarget']={'x':_0x321d2e['domEvent']['x'],'y':_0x321d2e['domEvent']['y']},this['activeView']=this['_getViewForChange'](_0x2ddc77)):(this['_activeViewTarget']=null,this['activeView']=null);}),this['listenTo'](this['editor']['editing']['view']['document'],'mousedown',(_0x5bf2fb,_0x4af4c1)=>{const _0x74b3a8=this['_findChangeIdFromDomTarget'](_0x4af4c1['target']),_0x48d773=this['_changeIdToChange']['get'](_0x74b3a8);_0x48d773?(this['_activeViewTarget']={'x':_0x4af4c1['domEvent']['x'],'y':_0x4af4c1['domEvent']['y']},_0x48d773===this['activeChange']?this['_balloon']['updatePosition']():this['activeChange']=_0x48d773):(this['_activeViewTarget']=null,this['activeChange']=null);});}['_findChangeIdFromDomTarget'](_0x50943e){do{const _0x26b1a3=_0x50943e['getAttribute']('data-change-id');if(_0x26b1a3)return _0x26b1a3;_0x50943e=_0x50943e['parent'];}while(_0x50943e);return null;}['_cleanMarkers'](){this['editor']['model']['change'](_0x33d1cb=>{for(const _0x2328d4 of this['editor']['model']['markers'])_0x33d1cb['removeMarker'](_0x2328d4);});}}function X(_0x1cd6a5,_0x5c2dc8){return(_0x4728ef,_0x2cf185,_0x392909)=>{if(!_0x392909['consumable']['test'](_0x2cf185['markerRange'],_0x4728ef['name']))return;const _0x4b9743=_0x2cf185['markerRange']['getWalker'](),_0x2ee2a9=_0x2cf185['markerRange']['start'],_0x395b89=_0x1cd6a5['model']['schema'];let _0x3f4a6d=null,_0x1e0fd4=null,_0x4c5bec=!0x1,_0x301c49=!0x1;for(const _0x564b04 of _0x4b9743){const _0x1d1287=_0x564b04['item'];_0x4c5bec=_0x4c5bec||_0x395b89['isContent'](_0x1d1287);const _0x450d0a=_0x392909['mapper']['toViewElement'](_0x1d1287);if(_0x450d0a&&_0x450d0a['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x564b04['type']&&(_0x395b89['isBlock'](_0x1d1287)&&!_0x395b89['isLimit'](_0x1d1287)&&(_0x1d1287['nextSibling']||_0x2ee2a9['isAtEnd']?_0x3f4a6d&&_0x3f4a6d['parent']==_0x1d1287||(_0x3f4a6d=_0x1d1287,_0x56a00f(_0x564b04['previousPosition']),_0x301c49=!0x0):_0x1e0fd4=_0x1e0fd4||_0x564b04['previousPosition']));}function _0x56a00f(_0xb2c5ca){const _0x39d98e=_0x392909['mapper']['toViewPosition'](_0xb2c5ca),_0xb61dff=_0x392909['writer']['createUIElement']('span',{'class':'ck-suggestion-preview-marker-'+_0x5c2dc8});_0x392909['writer']['insert'](_0x39d98e,_0xb61dff),_0x392909['mapper']['bindElementToMarker'](_0xb61dff,_0x2cf185['markerName']);}_0x4c5bec||_0x301c49||!_0x1e0fd4||_0x56a00f(_0x1e0fd4);};}class mt extends _0xf18edc{constructor(_0x203b91){super(_0x203b91);const _0x5bff95=_0x203b91['plugins']['get'](m);this['affectsData']=!0x1,this['listenTo'](_0x5bff95,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x5bff95,'change:isEnabled',()=>this['refresh']());}['execute'](){const _0x463115=this['editor'],_0x1d7007=_0x463115['plugins']['get'](m),_0x389db9=_0x1d7007['isReady']?_0x1d7007['diff']['newRevisionId']:null;_0x463115['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x389db9);}['refresh'](){const {isReady:_0x628b39,isEnabled:_0x592d4f,repository:_0x1ed597,diff:_0x5bc387}=this['editor']['plugins']['get'](m),_0x4b1186=_0x5bc387&&_0x1ed597['getLaterVisibleRevision'](_0x5bc387['newRevisionId']);this['isEnabled']=_0x628b39&&_0x592d4f&&Boolean(_0x4b1186);}}class wt extends _0xf18edc{['_step'];constructor(_0xa257e3,{direction:_0x3f8c43}){super(_0xa257e3);const _0x39a336=_0xa257e3['plugins']['get'](m);this['affectsData']=!0x1,this['_step']='forward'===_0x3f8c43?0x1:-0x1,this['listenTo'](_0x39a336,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x39a336,'change:isEnabled',()=>this['refresh']()),this['listenTo'](_0x39a336,'change:activeChange',()=>this['refresh']());}['execute'](){const _0x3ece51=this['editor'],_0x10ae52=_0x3ece51['plugins']['get'](m),{isNavigationMode:_0x5a9f6d,currentChangeNumber:_0x34feff}=_0x10ae52;let _0x3eb7ca;if(_0x10ae52['activeChange']=_0x5a9f6d?_0x10ae52['diff']['changes']['get'](_0x34feff+this['_step']):_0x10ae52['diff']['changes']['first'],_0x10ae52['activeChange']['data']['isOnRoot'])_0x3eb7ca=_0x3ece51['editing']['view']['getDomRoot'](_0x10ae52['activeChange']['rootName']);else{const _0x527b65=_0x3ece51['model']['markers']['get']('revision:'+_0x10ae52['activeChange']['id']);_0x3eb7ca=_0x281c81(_0x3ece51['editing'],_0x527b65);}_0x992975({'target':_0x3eb7ca,'viewportOffset':0x28});}['refresh'](){const {isNavigationMode:_0x2a01ff,currentChangeNumber:_0x478a3e,numberOfChanges:_0x273213,isReady:_0x35c872,isEnabled:_0x4669c3}=this['editor']['plugins']['get'](m);this['isEnabled']=!!(_0x4669c3&&_0x35c872&&_0x273213)&&(!_0x2a01ff||(0x1===this['_step']?_0x478a3e<_0x273213-0x1:_0x478a3e>0x0));}}class _i extends ts{constructor(_0x2b30b2){super(_0x2b30b2);const _0x2792db=this['bindTemplate'],_0x430e4f=new te(_0x2b30b2),_0x38b9dd=new te(_0x2b30b2);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',(_0x18dc70,_0x3c5eed)=>_0x18dc70&&_0x3c5eed>0x0),this['bind']('_statusText')['to'](this,'isReady',this,'currentChangeNumber',this,'numberOfChanges',this,'isNavigationMode',(_0x3d29cf,_0x3cff67,_0x15ae8a,_0x329d45)=>{if(!_0x3d29cf)return g(_0x2b30b2,'Loading...');if(!_0x15ae8a)return g(_0x2b30b2,'No\x20changes');const _0x2949fb=g(_0x2b30b2,'NUMBER_OF_CHANGES',_0x15ae8a);return _0x329d45?g(_0x2b30b2,'X_OF_Y_CHANGES',[_0x3cff67+0x1,_0x15ae8a]):_0x2949fb;}),_0x430e4f['set']({'label':g(_0x2b30b2,'Show\x20previous\x20change'),'tooltip':!0x0,'icon':_0xf0e319}),_0x38b9dd['set']({'label':g(_0x2b30b2,'Show\x20next\x20change'),'tooltip':!0x0,'icon':_0x2e72f4}),_0x430e4f['bind']('isEnabled')['to'](this,'isBackwardNavigationEnabled'),_0x38b9dd['bind']('isEnabled')['to'](this,'isForwardNavigationEnabled'),_0x430e4f['on']('execute',()=>this['fire']('execute','backward')),_0x38b9dd['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',_0x2792db['if']('_isStatusLabelVisible','ck-hidden',_0x36e903=>!_0x36e903)]},'children':[{'text':_0x2792db['to']('isNavigationMode',_0x27a16d=>_0x27a16d?g(_0x2b30b2,'EDIT_X_OF_Y_REVISIONS')+':\x20':g(_0x2b30b2,'Total')+':\x20')}]},{'text':_0x2792db['to']('_statusText')}]},new _0x162f18(),{'tag':'div','attributes':{'class':['ck-revision-history-ui__changes-navigation__navigation']},'children':[_0x430e4f,_0x38b9dd]}]});}}const le='ck-editor__editable__loading-overlay';class ge extends _0x3561a9{static get['pluginName'](){return'RevisionViewerLoadingOverlay';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['show'](){const _0x2151a4=this['editor']['editing']['view'];_0x2151a4['change'](_0x5adbdc=>{for(const _0x447c02 of _0x2151a4['document']['roots'])_0x5adbdc['addClass'](le,_0x447c02);});}['hide'](){const _0x4a3c12=this['editor']['editing']['view'];_0x4a3c12['change'](_0x47b664=>{for(const _0x156fc9 of _0x4a3c12['document']['roots'])_0x47b664['removeClass'](le,_0x156fc9);});}}class R extends _0x3561a9{static get['pluginName'](){return'RevisionViewerUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[m,ge];}['init'](){const _0x9500db=this['editor'],_0x12a542=_0x9500db['plugins']['get'](m),_0x23015b=_0x9500db['plugins']['get'](ge);_0x9500db['ui']['componentFactory']['add']('exitToEditing',_0x10cd2b=>{const _0x20e317=new te(_0x10cd2b);return _0x20e317['set']({'label':g(_0x10cd2b,'Back\x20to\x20editing'),'icon':_0x5c1885,'withText':!0x0,'tooltip':!0x0,'class':'ck-revision-history-ui__back-to-editing'}),this['listenTo'](_0x20e317,'execute',()=>{_0x9500db['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}),_0x20e317;}),_0x9500db['ui']['componentFactory']['add']('restoreRevision',_0x380f9d=>{const _0x4b1f4a=new te(_0x380f9d);return _0x4b1f4a['set']({'label':g(_0x380f9d,'Restore\x20this\x20revision'),'withText':!0x0,'tooltip':!0x0}),_0x4b1f4a['bind']('isEnabled')['to'](_0x9500db['commands']['get']('restoreRevision')),this['listenTo'](_0x4b1f4a,'execute',()=>_0x9500db['execute']('restoreRevision')),_0x4b1f4a;}),_0x9500db['ui']['componentFactory']['add']('changesNavigation',_0x5813b5=>{const _0x1ff21c=new _i(_0x5813b5),_0x49777b=_0x9500db['commands']['get']('showPreviousChange'),_0x1606e5=_0x9500db['commands']['get']('showNextChange');return _0x1ff21c['bind']('isBackwardNavigationEnabled')['to'](_0x49777b,'isEnabled'),_0x1ff21c['bind']('isForwardNavigationEnabled')['to'](_0x1606e5,'isEnabled'),_0x1ff21c['bind']('isReady','currentChangeNumber','numberOfChanges','isNavigationMode')['to'](_0x12a542),this['listenTo'](_0x1ff21c,'execute',(_0x10f0c3,_0x5d3259)=>{_0x9500db['execute']('forward'===_0x5d3259?'showNextChange':'showPreviousChange');}),_0x1ff21c;}),_0x23015b['show'](),_0x12a542['on']('change:isReady',(_0x3dcace,_0x9d3147,_0x38ba23)=>{_0x38ba23?_0x23015b['hide']():_0x23015b['show']();});}}class at extends _0x403710{['_resizeObserver']=null;constructor(_0x223a52,_0x5a03a9){super(_0x223a52,_0x5a03a9);const _0x5306ff=this['bindTemplate'];this['set']({'label':g(_0x223a52,'Revision\x20name'),'_tooltipString':''}),this['fieldView']['placeholder']=g(_0x223a52,'Enter\x20the\x20revision\x20name'),this['extendTemplate']({'tag':'span','attributes':{'class':['ck-revision-history-sidebar__revision-name'],'data-cke-tooltip-text':_0x5306ff['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 _0x1817c6=this['fieldView']['element'];this['_tooltipString']=_0x1817c6['scrollWidth']>_0x1817c6['clientWidth']&&_0x1817c6['value']||'';}}class si extends ts{constructor(_0x4f6d65,_0x4c2015,_0xd8f3db){super(_0x4f6d65);const _0x57741d=new _0x1b24f4();_0x57741d['set']({'content':_0x3a717f,'viewBox':'0\x200\x2011\x2010'});const _0x52e961=['ck','ck-revision-history-sidebar__revision-author'];_0xd8f3db&&_0x52e961['push']('ck-revision-history-sidebar__revision-author_creator');const _0xf9e6b5=[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision-author__name'],'title':g(_0x4f6d65,_0xd8f3db?'Revision\x20creator':'Revision\x20author')},'children':[_0x57741d,_0x4c2015['name']]}];this['setTemplate']({'tag':'li','attributes':{'class':_0x52e961},'children':_0xf9e6b5});}}function oi(_0x445d27,_0x16e7a5){const _0x457a0c=_0x445d27['bindTemplate'],_0x45853e=_0x445d27['locale'],_0x4802a8=_0x44640e(_0x45853e);_0x4802a8['panelPosition']='sw';const _0x222bb5=function(_0x4a9fff,_0x6fd39b){const _0x50c491=function(_0x5b10bb,_0x33a588){const _0xa1eb1c=_0x5b10bb['locale'],_0x1ad565={'Compare\x20against\x20selected':g(_0xa1eb1c,'Compare\x20against\x20selected'),'Name\x20this\x20revision':g(_0xa1eb1c,'Name\x20this\x20revision'),'Restore\x20this\x20revision':g(_0xa1eb1c,'Restore\x20this\x20revision')};return _0x33a588['map'](_0x5cfecb=>{const _0x563b7c=_0x1ad565[_0x5cfecb['name']];return _0x563b7c&&_0x563b7c!==_0x5cfecb['name']&&(_0x5cfecb['name']=_0x563b7c),_0x5cfecb;});}(_0x4a9fff,_0x6fd39b),_0x14a515=new _0x57f501();for(const _0x2b7406 of _0x50c491){const _0x1fde4={'type':'button','model':new to({'label':_0x2b7406['name'],'class':_0x2b7406['class'],'withText':!0x0,'role':'menuitem','_action':_0x2b7406['action']})};_0x1fde4['model']['bind']('isEnabled')['to'](_0x4a9fff,'isActionsDropdownOpen',_0x2ef034=>'function'!=typeof _0x2b7406['isEnabled']||(!_0x2ef034||_0x2b7406['isEnabled'](_0x4a9fff))),_0x14a515['add'](_0x1fde4);}return _0x14a515;}(_0x445d27,_0x16e7a5);return _0x445d27['bind']('isActionsDropdownOpen')['to'](_0x4802a8,'isOpen'),_0x4802a8['buttonView']['set']({'label':g(_0x45853e,'Show\x20more\x20items'),'tooltip':!0x0,'tooltipPosition':'sw','icon':_0x4bb82e}),_0x4802a8['extendTemplate']({'attributes':{'class':['ck-revision-history-sidebar__revision__actions',_0x457a0c['if']('isActionsDropdownOpen','ck-on')]},'on':{'click':_0x457a0c['to'](_0x307d17=>_0x307d17['stopPropagation']())}}),_0x4802a8['on']('execute',_0x520d36=>{_0x445d27['isReady']&&'function'==typeof _0x520d36['source']['_action']&&_0x520d36['source']['_action'](_0x445d27);}),_0x488c53(_0x4802a8,_0x222bb5,{'role':'menu'}),_0x4802a8['listenTo'](_0x445d27,'change:isActionsDropdownOpen',(_0x82a7a8,_0x37e8db,_0x1fd817)=>{if(_0x1fd817)for(const _0xf6712f of _0x4802a8['listView']['items']){const _0x529fb5=_0xf6712f['children']['first'],_0x236c11=_0x16e7a5['find'](_0x4f3d29=>_0x4f3d29['action']===_0x529fb5['_action'])['isVisible'];_0xf6712f['isVisible']=void 0x0===_0x236c11||_0x236c11(_0x445d27);}}),_0x4802a8;}class hi extends/* #__PURE__ -- @preserve */
|
|
26
|
-
|
|
23
|
+
import{ObservableMixin as _0x1fae21,uid as _0x498586,Collection as _0x2a9213,logWarning as _0x2a2f93,FocusTracker as _0x1abf6e,KeystrokeHandler as _0x39fef4,scrollViewportToShowTarget as _0x40b14f,ResizeObserver as nt,ElementReplacer as ot,CKEditorError as _0x2b5225}from'@ckeditor/ckeditor5-utils/dist/index.js';import{cloneDeep as _0x74c535,set as _0x6d4807,unset as _0x7ce151,isEqual as _0x3ea6af}from'es-toolkit/compat';import{Plugin as _0x37aa98,PendingActions as _0x3d5281,Command as _0x5123c0,ElementApiMixin as _0x376351,Editor as _0x56567c}from'@ckeditor/ckeditor5-core/dist/index.js';import{Users as _0x3c957c,getMarkerDomElement as _0x2e5ebc,ConfirmMixin as _0x36d32c,sanitizeEditorConfig as _0x44ead7}from'ckeditor5-collaboration/dist/index.js';import{ViewContainerElement as _0x18e66d,ViewAttributeElement as _0x30ecb7,ViewEmptyElement as _0x592f5a,ViewRawElement as _0xf086ef,ViewUIElement as _0x13e1ec,ViewDocumentFragment as _0x3a2e4d,ViewText as _0x57cd03,ViewElement as _0xb35323,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 _0x3acfa9,IconChevronUp as _0x29bc7b,IconChevronDown as _0x55b434,IconUndo as _0x548abb,IconUser as _0x20ebe2,IconThreeVerticalDots as _0x28c97e}from'@ckeditor/ckeditor5-icons/dist/index.js';import{View as ts,injectCssTransitionDisabler as _0x57348d,submitHandler as _0x28ff76,LabeledFieldView as _0x2be6a1,createLabeledInputText as _0x22d3ee,createDropdown as _0x5d6b2b,ListView as _0x42b4bf,ListItemView as _0x2b9608,ButtonView as te,MenuBarMenuView as _0x30700f,MenuBarMenuListView as _0x106d90,MenuBarMenuListItemView as _0x5c4104,MenuBarMenuListItemButtonView as _0x51450e,ContextualBalloon as _0x400c5c,ToolbarSeparatorView as _0x4dae21,IconView as _0xaa104a,addListToDropdown as _0x548dd5,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 _0x45883b}from'luxon';class h extends/* #__PURE__ -- @preserve */
|
|
24
|
+
_0x1fae21(){['id'];['creator'];['authors'];['diffData'];['toVersion'];['fromVersion'];['model'];constructor(_0x45e7e6){super(),this['id']=_0x45e7e6['id']||_0x498586(),this['creator']=_0x45e7e6['creator']||null,this['authors']=_0x45e7e6['authors']||[],this['diffData']=_0x45e7e6['diffData']||null,this['toVersion']=_0x45e7e6['toVersion']||0x0,this['fromVersion']=_0x45e7e6['fromVersion']||0x0,this['set']('name',_0x45e7e6['name']||''),this['set']('createdAt',_0x45e7e6['createdAt']||new Date()),this['set']('attributes',_0x45e7e6['attributes']||{});}['setName'](_0x41e5dd){this['_update']({'name':_0x41e5dd});}['setAttribute'](_0x1e693c,_0x1c9de0){const _0x4b1369=_0x74c535(this['attributes']);_0x6d4807(_0x4b1369,_0x1e693c,_0x1c9de0),this['_update']({'attributes':_0x4b1369});}['removeAttribute'](_0x4c39da){const _0x4d3648=_0x74c535(this['attributes']);_0x7ce151(_0x4d3648,_0x4c39da),this['_update']({'attributes':_0x4d3648});}['_update'](_0x331311,_0x40d48c=!0x1){let _0x70d91e=!0x1;const _0x4df48d={'id':this['id']},_0x2c0c2c=['name','createdAt','diffData','authors','attributes','toVersion','fromVersion','creatorId'];for(const _0x500a7b of _0x2c0c2c){const _0x1eccf1=_0x331311[_0x500a7b];void 0x0!==_0x1eccf1&&_0x1eccf1!==this[_0x500a7b]&&(this[_0x500a7b]=_0x1eccf1,_0x4df48d[_0x500a7b]=_0x1eccf1,_0x70d91e=!0x0);}_0x70d91e&&(_0x4df48d['authors']&&(_0x4df48d['authorsIds']=_0x4df48d['authors']['map'](_0x2f8add=>_0x2f8add['id']),delete _0x4df48d['authors']),this['fire']('_update',_0x4df48d,_0x40d48c));}['toJSON'](){return{'id':this['id'],'name':this['name'],'creatorId':this['creator']?this['creator']['id']:null,'authorsIds':this['authors']['map'](_0x1cbed6=>_0x1cbed6['id']),'diffData':this['diffData'],'createdAt':this['createdAt'],'attributes':this['attributes'],'fromVersion':this['fromVersion'],'toVersion':this['toVersion']};}}class I extends _0x37aa98{['_revisions'];static get['requires'](){return[_0x3c957c];}static get['pluginName'](){return'RevisionsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['length'](){return this['_revisions']['length'];}constructor(_0x5246af){super(_0x5246af),this['_revisions']=new _0x2a9213();}['afterInit'](){!async function(_0x18086d){const _0x44e8be=_0x4922b6([0x76,0x30,0x4b,0x79,0x37,0x6b,0x44,0x71,0x43,0x6d,0x36,0x65,0x31,0x56,0x5a,0x4e,0x57,0x55,0x50,0x77,0x7a,0x32,0x78,0x72,0x6c,0x47,0x64,0x4a,0x70,0x35,0x68,0x75,0x33,0x48,0x6f,0x38,0x45,0x4f,0x69,0x66,0x6a,0x41,0x46,0x74,0x53,0x4c,0x49,0x58,0x6e,0x4d,0x42,0x63,0x61,0x67,0x54,0x62,0x59,0x34,0x52,0x73,0x39,0x51]),_0x29d6eb=0xeb829,_0x5500fe=0x2d09eb4,_0x33207c=0x2d7f734^_0x5500fe,_0x4af738=window[_0x4922b6([0x44,0x61,0x74,0x65])][_0x4922b6([0x6e,0x6f,0x77])](),_0x570317=_0x18086d[_0x4922b6([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x5d04e3=new window[(_0x4922b6([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x5ad576=>{_0x570317[_0x4922b6([0x6f,0x6e,0x63,0x65])](_0x4922b6([0x72,0x65,0x61,0x64,0x79]),_0x5ad576);}),_0x42b305={[_0x4922b6([0x6b,0x74,0x79])]:_0x4922b6([0x45,0x43]),[_0x4922b6([0x75,0x73,0x65])]:_0x4922b6([0x73,0x69,0x67]),[_0x4922b6([0x63,0x72,0x76])]:_0x4922b6([0x50,0x2d,0x32,0x35,0x36]),[_0x4922b6([0x78])]:_0x4922b6([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]),[_0x4922b6([0x79])]:_0x4922b6([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]),[_0x4922b6([0x61,0x6c,0x67])]:_0x4922b6([0x45,0x53,0x32,0x35,0x36])},_0x363e18=_0x570317[_0x4922b6([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x4922b6([0x67,0x65,0x74])](_0x4922b6([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x265c1d(){let _0x45a349,_0x41b7ec=null,_0x29ffef=null;try{if(_0x363e18==_0x4922b6([0x47,0x50,0x4c]))return _0x4922b6([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x45a349=_0x12dcaf(),!_0x45a349)return _0x4922b6([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x45a349[_0x4922b6([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x29ffef=_0x1ffcad(_0x45a349[_0x4922b6([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x45a349[_0x4922b6([0x6a,0x74,0x69])])),await _0x4498ad()?_0xa502d2()?_0x820371()?_0x4922b6([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x315851()?(_0x45a349[_0x4922b6([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x4922b6([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x41b7ec=_0x24c024(_0x4922b6([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x45a349[_0x4922b6([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x4922b6([0x74,0x72,0x69,0x61,0x6c])&&(_0x41b7ec=_0x24c024(_0x4922b6([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),await _0x2e6fb0()):_0x4922b6([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x4922b6([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x4922b6([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch{return _0x4922b6([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x820371(){const _0x117c95=[_0x4922b6([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x4922b6([0x74,0x72,0x69,0x61,0x6c])][_0x4922b6([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x45a349[_0x4922b6([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x4af738/0x3e8:0xe10*_0x33207c;return _0x45a349[_0x4922b6([0x65,0x78,0x70])]<_0x117c95;}function _0xa502d2(){const _0x1a7bec=_0x45a349[_0x4922b6([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x1a7bec)return!0x1;if(_0x1a7bec[_0x4922b6([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x4922b6([0x2a])))return!0x0;if(_0x1a7bec[_0x4922b6([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x4922b6([0x52,0x48])))return!0x0;if(_0x1a7bec[_0x4922b6([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x4922b6([0x52,0x52,0x48]))){if(_0x506848())return!0x0;if(_0x24376f()||_0x1c1c4c())return!0x0;}return!0x1;}function _0x315851(){const _0x495185=_0x45a349[_0x4922b6([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x495185||0x0==_0x495185[_0x4922b6([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x3e3c45}=new URL(window[_0x4922b6([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x495185[_0x4922b6([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x3e3c45))return!0x0;const _0x5bc7f2=_0x3e3c45[_0x4922b6([0x73,0x70,0x6c,0x69,0x74])](_0x4922b6([0x2e]));return _0x495185[_0x4922b6([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x1af5e8=>_0x1af5e8[_0x4922b6([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x4922b6([0x2a])))[_0x4922b6([0x6d,0x61,0x70])](_0x321cd0=>_0x321cd0[_0x4922b6([0x73,0x70,0x6c,0x69,0x74])](_0x4922b6([0x2e])))[_0x4922b6([0x73,0x6f,0x6d,0x65])](_0x2a44bc=>_0x5bc7f2[_0x4922b6([0x65,0x76,0x65,0x72,0x79])]((_0x14104c,_0x1faf3d)=>_0x2a44bc[_0x1faf3d]===_0x14104c||_0x2a44bc[_0x1faf3d]===_0x4922b6([0x2a])));}function _0x2e6fb0(){return _0x41b7ec&&_0x29ffef?new window[(_0x4922b6([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x4e02e8,_0x2f728b)=>{_0x41b7ec[_0x4922b6([0x74,0x68,0x65,0x6e])](_0x4e02e8,_0x2f728b),_0x29ffef[_0x4922b6([0x74,0x68,0x65,0x6e])](_0x4ad8bc=>{_0x4ad8bc!=_0x4922b6([0x56,0x61,0x6c,0x69,0x64])&&_0x4e02e8(_0x4ad8bc);},_0x2f728b);}):_0x41b7ec||_0x29ffef||_0x4922b6([0x56,0x61,0x6c,0x69,0x64]);}}function _0x1ffcad(_0x4993ce,_0x25ff37){return new window[(_0x4922b6([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x5b59d0=>{if(_0x279da0())return _0x5b59d0(_0x4922b6([0x56,0x61,0x6c,0x69,0x64]));_0x2c7b1d(),_0x570317[_0x4922b6([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x4922b6([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x389bdb=!0x1;const _0x2d0064=_0x498586();function _0x456e94(_0x5e9566){return!!_0x5e9566&&(typeof _0x5e9566===_0x4922b6([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x5e9566===_0x4922b6([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x5e9566[_0x4922b6([0x74,0x68,0x65,0x6e])]===_0x4922b6([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x5e9566[_0x4922b6([0x63,0x61,0x74,0x63,0x68])]===_0x4922b6([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x1065ec(_0x4918c3){_0xde24fe(_0x4918c3)[_0x4922b6([0x74,0x68,0x65,0x6e])](_0x3a3622=>{if(!_0x3a3622||_0x3a3622[_0x4922b6([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x4922b6([0x6f,0x6b]))return _0x4922b6([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x9df40f(_0xeaa5d9(_0x2d0064+_0x25ff37))!=_0x3a3622[_0x4922b6([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x4922b6([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x4922b6([0x56,0x61,0x6c,0x69,0x64]);})[_0x4922b6([0x74,0x68,0x65,0x6e])](_0x4f7662=>(_0x1d8872(),_0x4f7662),()=>{const _0x251850=_0x41ad7e();return null==_0x251850?(_0x1d8872(),_0x4922b6([0x56,0x61,0x6c,0x69,0x64])):_0x4922b6(_0x4af738-_0x251850>(0x26dc1ab4^_0x5500fe)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x4922b6([0x74,0x68,0x65,0x6e])](_0x5b59d0)[_0x4922b6([0x63,0x61,0x74,0x63,0x68])](()=>{_0x5b59d0(_0x4922b6([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x356cc7=0x2e67034^_0x5500fe;function _0x1d8872(){const _0x4a9024=_0x4922b6([0x6c,0x6c,0x63,0x74,0x2d])+_0x9df40f(_0xeaa5d9(_0x4993ce)),_0x58cc00=_0x18ef0f(_0x9df40f(window[_0x4922b6([0x4d,0x61,0x74,0x68])][_0x4922b6([0x63,0x65,0x69,0x6c])](_0x4af738/_0x356cc7)));window[_0x4922b6([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x4922b6([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x4a9024,_0x58cc00);}function _0x41ad7e(){const _0x1713a2=_0x4922b6([0x6c,0x6c,0x63,0x74,0x2d])+_0x9df40f(_0xeaa5d9(_0x4993ce)),_0x21b5be=window[_0x4922b6([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x4922b6([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x1713a2);return _0x21b5be?window[_0x4922b6([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x18ef0f(_0x21b5be),0x10)*_0x356cc7:null;}function _0xde24fe(_0x357a68){return new window[(_0x4922b6([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x241d74,_0x28b878)=>{_0x357a68[_0x4922b6([0x74,0x68,0x65,0x6e])](_0x241d74,_0x28b878),window[_0x4922b6([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x28b878,0x2d14a74^_0x5500fe);});}}_0x570317[_0x4922b6([0x6f,0x6e])](_0x4922b6([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x5ab5c7,_0x45a924)=>{if(_0x45a924[0x0]!=_0x4993ce)return _0x5b59d0(_0x4922b6([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x45a924[0x1]={..._0x45a924[0x1],[_0x4922b6([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x2d0064};},{[_0x4922b6([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x4922b6([0x68,0x69,0x67,0x68])}),_0x570317[_0x4922b6([0x6f,0x6e])](_0x4922b6([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x3570e5=>{_0x456e94(_0x3570e5[_0x4922b6([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x389bdb=!0x0,_0x1065ec(_0x3570e5[_0x4922b6([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x4922b6([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x4922b6([0x6c,0x6f,0x77])}),_0x5d04e3[_0x4922b6([0x74,0x68,0x65,0x6e])](()=>{_0x389bdb||_0x5b59d0(_0x4922b6([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x279da0(){return _0x570317[_0x4922b6([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x4922b6([0x76,0x69,0x65,0x77])][_0x4922b6([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x4922b6([0x61,0x75,0x74,0x6f]);}function _0x2c7b1d(){_0x570317[_0x4922b6([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x4922b6([0x76,0x69,0x65,0x77])][_0x4922b6([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x4922b6([0x61,0x75,0x74,0x6f]);}}function _0x24c024(_0x37b234){const _0x5bc804=[new window[(_0x4922b6([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x42ce35=>setTimeout(_0x42ce35,0x2d9a078^_0x5500fe)),_0x5d04e3[_0x4922b6([0x74,0x68,0x65,0x6e])](()=>new window[(_0x4922b6([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x287c88=>{const _0x19f42b=0x2d09eb3^_0x5500fe,_0x11e092=_0x18086d[_0x4922b6([0x5f,0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x73])];function _0x155835(){_0x11e092[_0x4922b6([0x6c,0x65,0x6e,0x67,0x74,0x68])]>=_0x19f42b&&_0x287c88();}_0x155835(),_0x11e092[_0x4922b6([0x6f,0x6e])](_0x4922b6([0x61,0x64,0x64]),_0x155835);})),new window[(_0x4922b6([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x1519f1=>{function _0x28d761(){for(const _0x3330e5 in window)if(window[_0x4922b6([0x4e,0x75,0x6d,0x62,0x65,0x72])]['isNaN'](window[_0x4922b6([0x4e,0x75,0x6d,0x62,0x65,0x72])](_0x3330e5))&&window[_0x3330e5]==_0x29d6eb)return _0x1519f1();_0x570317[_0x4922b6([0x73,0x74,0x61,0x74,0x65])]!=_0x4922b6([0x64,0x65,0x73,0x74,0x72,0x6f,0x79,0x65,0x64])&&window[_0x4922b6([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x28d761,0x2d08d3c^_0x5500fe);}_0x148945(_0x4922b6([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))&&_0x28d761();})];return window[_0x4922b6([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x4922b6([0x72,0x61,0x63,0x65])](_0x5bc804)[_0x4922b6([0x74,0x68,0x65,0x6e])](()=>_0x37b234);}async function _0x314403(){if(await _0x5d04e3,_0x148945(_0x4922b6([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))){const _0x1277f3=_0x18086d[_0x4922b6([0x67,0x65,0x74,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](0x0),_0x446132=_0x18086d[_0x4922b6([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])](_0x1277f3[_0x4922b6([0x69,0x64])]),_0x4fd315=_0x16cdf0(_0x4922b6([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]));return await _0x4fd315[_0x4922b6([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])](_0x1277f3['id'],_0x446132?_0x446132['id']:null,!0x0),_0x4fd315[_0x4922b6([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x4922b6([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x4fd315[_0x4922b6([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x4fd315[_0x4922b6([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])]=_0x94f7aa,void(_0x4fd315[_0x4922b6([0x5f,0x67,0x65,0x74,0x44,0x69,0x66,0x66])]=_0x94f7aa);}if(_0x148945(_0x4922b6([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]))){const _0x2d50fe=_0x16cdf0(_0x4922b6([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]));_0x2d50fe[_0x4922b6([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x4922b6([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x2d50fe[_0x4922b6([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x2d50fe[_0x4922b6([0x75,0x70,0x64,0x61,0x74,0x65])]=_0x94f7aa,_0x2d50fe[_0x4922b6([0x73,0x61,0x76,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])]=_0x94f7aa;}_0x570317[_0x4922b6([0x6d,0x6f,0x64,0x65,0x6c])][_0x4922b6([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x94f7aa,_0x570317[_0x4922b6([0x6d,0x6f,0x64,0x65,0x6c])][_0x4922b6([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x94f7aa,_0x570317[_0x4922b6([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x4922b6([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x506848(){return _0x148945(_0x4922b6([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x16cdf0(_0x4922b6([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x4922b6([0x73,0x74,0x61,0x74,0x65])]==_0x4922b6([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x24376f(){return _0x148945(_0x4922b6([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 _0x1c1c4c(){return _0x148945(_0x4922b6([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0x4b0460(_0xab4aba){const _0x3cb246=_0x4ccda1();_0x570317[_0x3cb246]=_0x4922b6([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])+_0xab4aba,_0xab4aba[_0x4922b6([0x65,0x6e,0x64,0x73,0x57,0x69,0x74,0x68])](_0x4922b6([0x4c,0x69,0x6d,0x69,0x74]))&&(window[_0x4ccda1()]=_0x29d6eb),_0xab4aba!=_0x4922b6([0x56,0x61,0x6c,0x69,0x64])&&_0x314403();}function _0x4ccda1(){const _0x1d9d01=window[_0x4922b6([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x4922b6([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x4922b6([0x6e,0x6f,0x77])]())[_0x4922b6([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x4922b6([0x2e]),'');let _0x199c2e=_0x4922b6([0x76]);for(let _0x28ee75=0x0;_0x28ee75<_0x1d9d01[_0x4922b6([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x28ee75+=0x2){let _0x526a1f=window[_0x4922b6([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x1d9d01[_0x4922b6([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x28ee75,_0x28ee75+0x2));_0x526a1f>=_0x44e8be[_0x4922b6([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x526a1f-=_0x44e8be[_0x4922b6([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x199c2e+=_0x44e8be[_0x526a1f];}return _0x199c2e;}function _0x12dcaf(){const _0xe65757=_0x363e18[_0x4922b6([0x73,0x70,0x6c,0x69,0x74])](_0x4922b6([0x2e]));if(0x3!=_0xe65757[_0x4922b6([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x2eb30d(_0xe65757[0x1]);function _0x2eb30d(_0x18e910){const _0x238849=_0x51194a(_0x18e910);return _0x238849&&_0x136c21()?_0x238849:null;function _0x136c21(){const _0x5c1a6f=_0x238849[_0x4922b6([0x6a,0x74,0x69])],_0xf64016=window[_0x4922b6([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x5c1a6f[_0x4922b6([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x5c1a6f[_0x4922b6([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0xaea2d={..._0x238849,[_0x4922b6([0x6a,0x74,0x69])]:_0x5c1a6f[_0x4922b6([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x5c1a6f[_0x4922b6([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0xaea2d[_0x4922b6([0x76,0x63])],_0xeaa5d9(_0xaea2d)==_0xf64016;}}}async function _0x4498ad(){let _0x42f816=!0x0;try{const _0x3b8e10=_0x363e18[_0x4922b6([0x73,0x70,0x6c,0x69,0x74])](_0x4922b6([0x2e])),[_0x21972d,_0x2e95d8,_0x591d59]=_0x3b8e10;return _0x1db36d(_0x21972d),await _0x117cb4(_0x21972d,_0x2e95d8,_0x591d59),_0x42f816;}catch{return!0x1;}function _0x1db36d(_0x2d9b7b){const _0x2b2d85=_0x51194a(_0x2d9b7b);_0x2b2d85&&_0x2b2d85[_0x4922b6([0x61,0x6c,0x67])]==_0x4922b6([0x45,0x53,0x32,0x35,0x36])||(_0x42f816=!0x1);}async function _0x117cb4(_0x31b795,_0x2fe139,_0x3fc38d){const _0x505d97=window[_0x4922b6([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x4922b6([0x66,0x72,0x6f,0x6d])](_0x473b41(_0x3fc38d),_0x114271=>_0x114271[_0x4922b6([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x259f45=new window[(_0x4922b6([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x4922b6([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x31b795+_0x4922b6([0x2e])+_0x2fe139),_0x56fa86=window[_0x4922b6([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x4922b6([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x56fa86)return;const _0x1ca60c=await _0x56fa86[_0x4922b6([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x4922b6([0x6a,0x77,0x6b]),_0x42b305,{[_0x4922b6([0x6e,0x61,0x6d,0x65])]:_0x4922b6([0x45,0x43,0x44,0x53,0x41]),[_0x4922b6([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x4922b6([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x4922b6([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x56fa86[_0x4922b6([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x4922b6([0x6e,0x61,0x6d,0x65])]:_0x4922b6([0x45,0x43,0x44,0x53,0x41]),[_0x4922b6([0x68,0x61,0x73,0x68])]:{[_0x4922b6([0x6e,0x61,0x6d,0x65])]:_0x4922b6([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x1ca60c,_0x505d97,_0x259f45)||(_0x42f816=!0x1);}}function _0x51194a(_0x282163){return _0x282163[_0x4922b6([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x4922b6([0x65,0x79]))?JSON[_0x4922b6([0x70,0x61,0x72,0x73,0x65])](_0x473b41(_0x282163)):null;}function _0x473b41(_0x850f8d){return window[_0x4922b6([0x61,0x74,0x6f,0x62])](_0x850f8d[_0x4922b6([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x4922b6([0x2b]))[_0x4922b6([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x4922b6([0x2f])));}function _0xeaa5d9(_0x25be50){let _0xb42597=0x1505;function _0x5ad93f(_0x3ad2e6){for(let _0x43e236=0x0;_0x43e236<_0x3ad2e6[_0x4922b6([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x43e236++){const _0x5aaa59=_0x3ad2e6[_0x4922b6([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x43e236);_0xb42597=(_0xb42597<<0x5)+_0xb42597+_0x5aaa59,_0xb42597&=_0xb42597;}}function _0x3963e2(_0x21d63e){Array[_0x4922b6([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x21d63e)?_0x21d63e[_0x4922b6([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x3963e2):_0x21d63e&&typeof _0x21d63e==_0x4922b6([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x4922b6([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x21d63e)[_0x4922b6([0x73,0x6f,0x72,0x74])]()[_0x4922b6([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x42ee07,_0x2b27e9])=>{_0x5ad93f(_0x42ee07),_0x3963e2(_0x2b27e9);}):_0x5ad93f(window[_0x4922b6([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x21d63e));}return _0x3963e2(_0x25be50),_0xb42597>>>0x0;}function _0x9df40f(_0x602011){return _0x602011[_0x4922b6([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x4922b6([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x4922b6([0x30]));}function _0x18ef0f(_0x4f0823){return _0x4f0823[_0x4922b6([0x73,0x70,0x6c,0x69,0x74])]('')[_0x4922b6([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x4922b6([0x6a,0x6f,0x69,0x6e])]('');}function _0x148945(_0x2b3dfe){return _0x570317[_0x4922b6([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x4922b6([0x68,0x61,0x73])](_0x2b3dfe);}function _0x16cdf0(_0x2b09b4){return _0x570317[_0x4922b6([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x4922b6([0x67,0x65,0x74])](_0x2b09b4);}function _0x94f7aa(){}function _0x4922b6(_0x231191){return _0x231191['map'](_0xfc0903=>String['fromCharCode'](_0xfc0903))['join']('');}_0x4b0460(await _0x265c1d());}(this);}['createRevision'](_0x498b9e){const _0x178eae=this['editor']['plugins']['get']('Users');return new h({'id':_0x498b9e['id'],'name':_0x498b9e['name'],'creator':_0x498b9e['creatorId']?_0x178eae['getUser'](_0x498b9e['creatorId']):null,'diffData':_0x498b9e['diffData']||_0x498b9e['data'],'authors':_0x498b9e['authorsIds']['map'](_0x5cce7d=>_0x178eae['getUser'](_0x5cce7d)),'createdAt':new Date(_0x498b9e['createdAt']),'attributes':_0x498b9e['attributes'],'fromVersion':_0x498b9e['fromVersion'],'toVersion':_0x498b9e['toVersion']});}['addRevision'](_0x5770ba,_0x192a25=0x0){this['_revisions']['add'](_0x5770ba,_0x192a25);}['getRevision'](_0x19bd88){return this['_revisions']['get'](_0x19bd88);}['getRevisions'](_0x43c6f8={'toJSON':!0x1}){const _0x3e244a=Array['from'](this['_revisions']);return _0x3e244a['reverse'](),_0x43c6f8['toJSON']?_0x3e244a['map'](_0x1ea032=>_0x1ea032['toJSON']()):_0x3e244a;}['getIndex'](_0x25ef6c){return this['_revisions']['getIndex'](_0x25ef6c);}['getEarlierVisibleRevision'](_0x10059c){const [,_0x3e19b0]=this['getRevisionsIterator'](_0x10059c,{'direction':'earlier'});return _0x3e19b0;}['getLaterVisibleRevision'](_0x20a3bc){const [,_0x297376]=this['getRevisionsIterator'](_0x20a3bc,{'direction':'later'});return _0x297376;}['getRevisionsInDiff'](_0x54ab9b){const _0xae9871=[];for(const _0x5f057 of this['getRevisionsIterator'](_0x54ab9b['newRevisionId']))if(_0xae9871['push'](_0x5f057),_0x5f057['id']===_0x54ab9b['oldRevisionId'])break;return _0xae9871;}*['getRevisionsIterator'](_0x43a314,{direction:_0x3796ca='earlier',filter:_0x16a13d=()=>!0x0}={}){const _0x3bae0d='earlier'===_0x3796ca?0x1:-0x1;let _0x3fdd2b=this['_revisions']['get'](_0x43a314),_0x512362=this['getIndex'](_0x3fdd2b);for(yield _0x3fdd2b;_0x3fdd2b;){if(_0x512362+=_0x3bae0d,_0x3fdd2b=this['getRevision'](_0x512362),!_0x3fdd2b)return;_0x16a13d(_0x3fdd2b)&&(yield _0x3fdd2b);}}}class V extends _0x37aa98{static get['pluginName'](){return'RevisionHistoryUtils';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['_viewClassToTypeChar']=new Map([[_0x18e66d,'c'],[_0x30ecb7,'a'],[_0x592f5a,'e'],[_0xf086ef,'r'],[_0x13e1ec,'u']]);['_typeCharToViewClass']=new Map([['c',_0x18e66d],['a',_0x30ecb7],['e',_0x592f5a],['r',_0xf086ef],['u',_0x13e1ec]]);async['loadRevisionData'](_0x187f06,_0x4ed206){if(_0x187f06['diffData']||!_0x4ed206)return;const _0x4d38de=this['editor']['config']['get']('collaboration.channelId'),_0x3d18c8=await _0x4ed206['getRevision']({'channelId':_0x4d38de,'revisionId':_0x187f06['id']});_0x187f06['diffData']=_0x3d18c8['diffData'];}['getRevisionDocumentData'](_0xe23ef7){const _0x71f0a4={};for(const _0x4064a2 in _0xe23ef7['diffData']){if(_0xe23ef7['diffData'][_0x4064a2]['attachChange']&&!_0xe23ef7['diffData'][_0x4064a2]['attachChange']['isAttached'])continue;const _0x231d32=this['_removeRevisionMarkers'](JSON['parse'](_0xe23ef7['diffData'][_0x4064a2]['insertions'])),_0x5808ea=this['editor']['editing']['view']['document'],_0x445d87=new _0x3a2e4d(_0x5808ea,_0x231d32['map'](_0x15c928=>this['_getViewFromDiffObj'](_0x15c928,!0x1)));this['editor']['data']['processor']['useFillerType']('marked'),_0x71f0a4[_0x4064a2]=this['editor']['data']['processor']['toData'](_0x445d87),this['editor']['data']['processor']['useFillerType']('default');}return _0x71f0a4;}['getRevisionRootsAttributes'](_0x3b9e3b){const _0x2dc801={};for(const _0x2a369b in _0x3b9e3b['diffData'])_0x3b9e3b['diffData'][_0x2a369b]['attachChange']&&!_0x3b9e3b['diffData'][_0x2a369b]['attachChange']['isAttached']||(_0x2dc801[_0x2a369b]=_0x3b9e3b['diffData'][_0x2a369b]['attributesAfter']||{});return _0x2dc801;}['_getTypeCharForViewElement'](_0x5c842f){return this['_viewClassToTypeChar']['get'](_0x5c842f['constructor']);}['_getViewFromDiffObj'](_0x3ec463,_0x1256c2){const _0x231c7b=this['editor']['editing']['view']['document'];if('string'==typeof _0x3ec463)return new _0x57cd03(_0x231c7b,_0x3ec463);{let _0x19713f,_0x4fea0c;_0x4fea0c='u'==_0x3ec463['type']||'r'==_0x3ec463['type']?[]:_0x3ec463['children']['map'](_0xf3a85e=>this['_getViewFromDiffObj'](_0xf3a85e,_0x1256c2));const _0xc6434d=this['_typeCharToViewClass']['get'](_0x3ec463['type'])||_0xb35323,_0xb019e3=this['editor']['data']['htmlProcessor']['domConverter'];if(_0x19713f=new _0xc6434d(_0x231c7b,_0x3ec463['name'],_0x3ec463['attributes'],_0x4fea0c),'u'==_0x3ec463['type']&&_0x3ec463['children'][0x0]){const _0x32d288=_0x3ec463['children'][0x0];if(_0x19713f['render']=function(_0x730599){const _0x4675b9=_0x730599['createElement']('div');return _0x4675b9['innerHTML']=_0x32d288,_0x4675b9['childNodes'][0x0];},_0x1256c2){const _0x50ab06=new _0x3a2e4d(_0x231c7b);_0x50ab06['_appendChild'](_0x19713f);const _0x5ebd1e=Array['from'](_0xb019e3['viewChildrenToDom'](_0x50ab06,{'bind':!0x1})),_0x231971=_0xb019e3['domDocument']['createElement']('div');_0x231971['append'](..._0x5ebd1e),_0x19713f=Array['from'](_0xb019e3['domChildrenToView'](_0x231971))[0x0];}}else{if('r'==_0x3ec463['type']&&_0x3ec463['children'][0x0]){const _0x2a0ba4=_0x3ec463['children'][0x0];if(_0x19713f['render']=function(_0x3c184c){_0x3c184c['innerHTML']=_0x2a0ba4;},_0x1256c2){const _0x2e000a=new _0x3a2e4d(_0x231c7b);_0x2e000a['_appendChild'](_0x19713f);const _0x1bfd33=Array['from'](_0xb019e3['viewChildrenToDom'](_0x2e000a,{'bind':!0x1})),_0x4d8144=_0xb019e3['domDocument']['createElement']('div');_0x4d8144['append'](..._0x1bfd33);const _0x25e713=Array['from'](_0xb019e3['domChildrenToView'](_0x4d8144));_0x25e713['length']>0x1?_0x19713f['_appendChild'](_0x25e713):_0x19713f=_0x25e713[0x0];}}}if(_0x3ec463['customProperties']){for(const [_0x56ace5,_0x309dea]of _0x3ec463['customProperties'])_0x19713f['_setCustomProperty'](_0x56ace5,_0x309dea);}const _0xf471d7=void 0x0===_0x3ec463['fillerOffset']?null:_0x3ec463['fillerOffset'];return null!==_0xf471d7&&(_0x19713f['getFillerOffset']=()=>_0xf471d7),_0x19713f;}}['_makeModelFromViewString'](_0x62a02f){const _0x2611bd=JSON['parse'](_0x62a02f),_0x4199fb=this['editor']['editing']['view']['document'],_0x1cad37=new _0x3a2e4d(_0x4199fb,_0x2611bd['map'](_0x58bbe6=>this['_getViewFromDiffObj'](_0x58bbe6,!0x0)));return this['editor']['data']['toModel'](_0x1cad37);}['_removeRevisionMarkers'](_0x55c1e9){return(_0x55c1e9=_0x55c1e9['filter'](_0x3a0083=>!_0x3a0083['name']||'revision-start'!==_0x3a0083['name']&&'revision-end'!==_0x3a0083['name']))['forEach'](_0x3085a9=>{'string'!=typeof _0x3085a9&&(_0x3085a9['children']=this['_removeRevisionMarkers'](_0x3085a9['children']),_0x3085a9['attributes']=_0x3085a9['attributes']['filter'](_0x15407b=>!_0x15407b[0x0]['startsWith']('data-revision-')));}),_0x55c1e9;}}function g(_0x365a96,_0x36d634,_0x425de7){const t=_0x365a96['t'];switch(_0x36d634){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'},_0x425de7);case'X_OF_Y_CHANGES':return t({'string':'%0\x20of\x20%1','id':'X_OF_Y_CHANGES'},_0x425de7);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 _0x37aa98{['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[_0x3c957c,I,V,_0x3d5281];}constructor(_0x53909c){super(_0x53909c),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 _0x5230df=_0x498586();this['_source']={'history':this['editor']['model']['document']['history'],'getLatestVersion':()=>Promise['resolve'](this['editor']['model']['document']['version']),'getCurrentRevisionId':()=>_0x5230df},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 _0x463d47=this['repository']['getRevision'](0x0),_0x100059=_0x463d47&&null===_0x463d47['creator']?_0x463d47:null;if(this['_continueCurrentRevision']=!!_0x100059&&this['editor']['config']['get']('revisionHistory.resumeUnsavedRevision'),this['editor']['plugins']['has']('RealTimeCollaborationClient')){const _0x480bba=this['_source']['getCurrentRevisionId'](),_0x5277ed=this['repository']['getRevision'](_0x480bba);if(_0x5277ed)this['_startingVersion']=_0x5277ed['fromVersion'],this['_continueCurrentRevision']=!0x1;else{const _0x176185=this['_source']['history']['_operations']['find'](_0x2e74eb=>!_0x2e74eb['_isInit']),_0x5418c7=_0x176185?_0x176185['baseVersion']:this['_source']['history']['version'];_0x463d47?(_0x463d47['toVersion']<_0x5418c7&&_0x463d47['_update']({'toVersion':_0x5418c7}),this['_continueCurrentRevision']?(this['_source']['getCurrentRevisionId']=()=>_0x100059['id'],this['_startingVersion']=_0x100059['fromVersion']):(this['_startingVersion']=_0x463d47['toVersion'],this['_continueCurrentRevision']=!0x1)):(this['_startingVersion']=_0x5418c7,this['_continueCurrentRevision']=!0x1);}}else _0x100059&&(this['editor']['model']['document']['history']['version']=Math['max'](_0x100059['toVersion'],this['editor']['model']['document']['history']['version']),_0x100059['fromVersion']===_0x100059['toVersion']?(0x0!==_0x100059['fromVersion']&&(this['_source']['getCurrentRevisionId']=()=>_0x100059['id']),this['_continueCurrentRevision']=!0x1):this['_continueCurrentRevision']&&(this['_source']['getCurrentRevisionId']=()=>_0x100059['id'],this['_startingVersion']=_0x100059['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',_0x597bae=>!_0x597bae),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x3ef683=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x28fd5e;for(const _0x194db7 in _0x3ef683){const _0x506cf0=_0x194db7,_0x17b25f=_0x3ef683[_0x506cf0];if('revisionHistoryLicenseKeyValid'==_0x17b25f||'revisionHistoryLicenseKeyInvalid'==_0x17b25f||'revisionHistoryLicenseKeyExpired'==_0x17b25f||'revisionHistoryLicenseKeyDomainLimit'==_0x17b25f||'revisionHistoryLicenseKeyNotAllowed'==_0x17b25f||'revisionHistoryLicenseKeyEvaluationLimit'==_0x17b25f||'revisionHistoryLicenseKeyTrialLimit'==_0x17b25f||'revisionHistoryLicenseKeyUsageLimit'==_0x17b25f){delete _0x3ef683[_0x506cf0],_0x28fd5e=_0x17b25f,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'revisionHistoryLicenseKeyInvalid'==_0x28fd5e&&_0x3ef683['_showLicenseError']('invalid'),'revisionHistoryLicenseKeyExpired'==_0x28fd5e&&_0x3ef683['_showLicenseError']('expired'),'revisionHistoryLicenseKeyDomainLimit'==_0x28fd5e&&_0x3ef683['_showLicenseError']('domainLimit'),'revisionHistoryLicenseKeyNotAllowed'==_0x28fd5e&&_0x3ef683['_showLicenseError']('featureNotAllowed','RevisionHistory'),'revisionHistoryLicenseKeyEvaluationLimit'==_0x28fd5e&&_0x3ef683['_showLicenseError']('evaluationLimit'),'revisionHistoryLicenseKeyTrialLimit'==_0x28fd5e&&_0x3ef683['_showLicenseError']('trialLimit'),'revisionHistoryLicenseKeyUsageLimit'==_0x28fd5e&&_0x3ef683['_showLicenseError']('usageLimit');},0x3e8);}async['afterInit'](){if(this['repository']['length']>0x0){const _0x313ca2=this['repository']['getRevision'](0x0),_0x2b3a39=await this['getRevisionDocumentData'](_0x313ca2),_0x5ecf00=await this['getRevisionRootsAttributes'](_0x313ca2);this['_replaceEditorDataWithRevisionData'](_0x2b3a39,_0x5ecf00);}}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['setSource'](_0x50e5b6){this['_source']=_0x50e5b6;}async['update'](){const _0x1095cd=await this['_source']['getLatestVersion']();if(_0x1095cd>this['currentRevision']['toVersion']){await this['_loadState']();const _0x292a80=this['buildRevisionData']({'revision':this['currentRevision'],'to':_0x1095cd});_0x292a80['authors']=_0x292a80['authorsIds']['map'](_0x333d17=>this['editor']['plugins']['get']('Users')['getUser'](_0x333d17)),this['currentRevision']['_update'](_0x292a80);}}async['saveRevision'](_0x1d1f4b={},_0x39ff02=null){const _0x2d932c=[];await this['_loadState'](),this['_continueCurrentRevision']=!0x1,_0x39ff02>this['currentRevision']['toVersion']&&(_0x39ff02=null),null===_0x39ff02&&(_0x39ff02=await this['_source']['getLatestVersion']());const _0x2db4ab=this['_getFromVersion'](_0x39ff02),_0x2c9164=this['buildRevisionData']({'from':_0x2db4ab,'to':_0x39ff02});if(this['currentRevision']['toVersion']<_0x39ff02){const _0x33b0b6=this['buildRevisionData']({'revision':this['currentRevision'],'from':_0x39ff02,'to':_0x39ff02});_0x33b0b6['authors']=[],_0x33b0b6['authorsIds']=[],_0x33b0b6['id']=this['currentRevision']['id'],this['currentRevision']['_update'](_0x33b0b6,!0x0),delete _0x33b0b6['authors'],_0x2d932c['push'](_0x33b0b6);}_0x1d1f4b['creatorId']=this['editor']['plugins']['get']('Users')['me']['id'],_0x1d1f4b['name']=_0x1d1f4b['name']||null,_0x1d1f4b['id']=_0x1d1f4b['id']||_0x498586(),_0x1d1f4b={..._0x1d1f4b,..._0x2c9164};const _0x313c8d=this['addRevisionData'](_0x1d1f4b);_0x2d932c['push'](_0x1d1f4b);const _0x1bee01=this['repository']['getIndex'](_0x313c8d);if(0x0!==_0x1bee01){const _0x565a54=this['repository']['getRevision'](_0x1bee01-0x1);if(_0x565a54['fromVersion']!==_0x39ff02){const _0x203191=this['_revisionDataBuilder']['getData'](_0x39ff02,_0x565a54['toVersion']),_0x2231c2={'id':_0x565a54['id'],'diffData':_0x203191['diffData'],'authorsIds':_0x203191['authorsIds'],'authors':_0x203191['authorsIds']['map'](_0x365f49=>this['editor']['plugins']['get']('Users')['getUser'](_0x365f49)),'fromVersion':_0x39ff02};_0x565a54===this['currentRevision']&&(_0x2231c2['createdAt']=new Date(_0x1d1f4b['createdAt']['getTime']()+0xa)),_0x565a54['_update'](_0x2231c2,!0x0),delete _0x2231c2['authors'],_0x2d932c['push'](_0x2231c2);}}if(this['adapter']){for(const _0x52f647 of _0x2d932c)this['_bufferUpdate'](_0x52f647['id'],_0x52f647,!0x0);this['sendBufferedUpdates']();}return _0x313c8d;}['addRevisionData'](_0x1ccf2b){const _0x2ec2c6=this['repository']['createRevision'](_0x1ccf2b);return this['adapter']&&_0x2ec2c6['on']('_update',(_0x499248,_0x2e7005,_0xc1f6)=>{_0xc1f6||(this['_bufferUpdate'](_0x2e7005['id'],_0x2e7005,!0x0),this['sendBufferedUpdates']());}),this['repository']['addRevision'](_0x2ec2c6,this['_findInsertionIndex'](_0x2ec2c6)),_0x2ec2c6;}async['getRevisionDocumentData'](_0x5cd108){return await this['_utils']['loadRevisionData'](_0x5cd108,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x5cd108);}async['getRevisionRootsAttributes'](_0x4a82cc){return await this['_utils']['loadRevisionData'](_0x4a82cc,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x4a82cc);}['sendBufferedUpdates'](){if(0x0===this['_bufferedUpdates']['size'])return;if(this['_isPendingUpdate'])return;let _0x3d00a0=Array['from'](this['_bufferedUpdates']['values']());this['_bufferedUpdates']['clear']();for(let _0x560aee=0x0;_0x560aee<_0x3d00a0['length'];_0x560aee++){const _0x5f55b2=_0x3d00a0[_0x560aee];let _0x1d2f10=!0x1;for(const _0x5ced56 of Object['keys'](_0x5f55b2))void 0x0===_0x5f55b2[_0x5ced56]?delete _0x5f55b2[_0x5ced56]:'id'!==_0x5ced56&&(_0x1d2f10=!0x0);_0x1d2f10||(_0x3d00a0[_0x560aee]=null);}if(_0x3d00a0=_0x3d00a0['filter'](_0x32a20c=>null!==_0x32a20c),!_0x3d00a0['length'])return;for(let _0x1997d7=0x0;_0x1997d7<_0x3d00a0['length'];_0x1997d7++){const _0x1ddfbc=_0x3d00a0[_0x1997d7];void 0x0!==_0x1ddfbc['fromVersion']&&void 0x0===_0x1ddfbc['toVersion']&&(_0x1ddfbc['toVersion']=this['repository']['getRevision'](_0x1ddfbc['id'])['toVersion']),void 0x0!==_0x1ddfbc['toVersion']&&void 0x0===_0x1ddfbc['fromVersion']&&(_0x1ddfbc['fromVersion']=this['repository']['getRevision'](_0x1ddfbc['id'])['fromVersion']);}const _0x5e5fb6=this['editor']['config']['get']('collaboration.channelId');this['_isPendingUpdate']=!0x0,this['_addPendingAction'](),this['adapter']['updateRevisions'](_0x3d00a0,_0x5e5fb6)['finally'](()=>{this['_isPendingUpdate']=!0x1;})['then'](_0x1f8b82=>{if(_0x1f8b82){for(const _0x44d874 of _0x1f8b82)this['setRevisionData']({'id':_0x44d874['id'],'createdAt':_0x44d874['createdAt']});}this['_removePendingAction'](),this['sendBufferedUpdates']();});}['buildRevisionData']({revision:_0x4a7e4a=null,from:_0x7cd413=null,to:_0x22bc5e=null}){_0x7cd413=null!==_0x7cd413?_0x7cd413:_0x4a7e4a['fromVersion'],_0x22bc5e=null!==_0x22bc5e?_0x22bc5e:_0x4a7e4a['toVersion'];const _0x18e29a=this['_revisionDataBuilder']['getData'](_0x7cd413,_0x22bc5e),_0x1ce2a4={'diffData':_0x18e29a['diffData'],'authorsIds':_0x18e29a['authorsIds'],'fromVersion':_0x7cd413,'toVersion':_0x22bc5e};if(!_0x4a7e4a||_0x22bc5e!==_0x4a7e4a['toVersion']){const _0x3b0cad=_0x22bc5e-0x1,_0x38d5c2=this['_source']['history']['getOperation'](_0x3b0cad);_0x1ce2a4['createdAt']=_0x38d5c2&&_0x38d5c2['createdAt']||new Date();}if(this['_loadedStateData']&&_0x7cd413===this['_loadedStateData']['fromVersion']){for(const _0x1c22e3 of this['_loadedStateData']['authors'])_0x1ce2a4['authorsIds']['includes'](_0x1c22e3['id'])||_0x1ce2a4['authorsIds']['push'](_0x1c22e3['id']);}return _0x1ce2a4;}['_bufferUpdate'](_0x440ca9,_0x3ed23e,_0x1b37b4){if(this['_bufferedUpdates']['has'](_0x440ca9)){const _0x590e27=this['_bufferedUpdates']['get'](_0x440ca9);_0x3ed23e=_0x1b37b4?{..._0x590e27,..._0x3ed23e}:{..._0x3ed23e,..._0x590e27};}this['_bufferedUpdates']['set'](_0x440ca9,_0x3ed23e);}['setRevisionData'](_0x13b2aa){const _0x220f3b=this['repository']['getRevision'](_0x13b2aa['id']);if(_0x13b2aa['createdAt']&&(_0x13b2aa['createdAt']=new Date(_0x13b2aa['createdAt'])),_0x13b2aa['authorsIds']){const _0x18e8dc=this['editor']['plugins']['get']('Users');_0x13b2aa['authors']=_0x13b2aa['authorsIds']['map'](_0x3f709a=>_0x18e8dc['getUser'](_0x3f709a));}_0x220f3b['_update'](_0x13b2aa,!0x0);}['_createInitialRevision'](_0x50821f){const _0x44b490=this['repository']['getRevision'](this['repository']['length']-0x1);if(_0x44b490)this['_initialRevisionId']=_0x44b490['id'];else{const _0x497a4a=!this['editor']['model']['document']['roots']['find'](_0x6f9541=>this['editor']['model']['hasContent'](_0x6f9541)),_0x31dbd0=this['editor']['plugins']['get']('Users')['me']['id'],_0x4a35f8=g(this['editor']['locale'],_0x497a4a?'Empty\x20document':'Initial\x20revision');this['_makeRevision']({'from':_0x50821f,'to':_0x50821f,'id':this['_initialRevisionId'],'name':_0x4a35f8,'creatorId':_0x31dbd0});}}['_createCurrentRevision'](_0x490cdf){const _0x1312d9=this['_source']['getCurrentRevisionId']();this['currentRevision']=this['repository']['getRevision'](_0x1312d9),this['currentRevision']||(this['currentRevision']=this['_makeRevision']({'from':_0x490cdf,'to':_0x490cdf,'id':_0x1312d9,'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'](_0x43dda5,_0x57d7d7){let _0x1ebebf=this['editor']['config']['get']('initialData'),_0x56b11d=this['editor']['config']['get']('rootsAttributes');if(void 0x0===_0x1ebebf){_0x1ebebf={};for(const _0x1f8caf of this['editor']['model']['document']['getRootNames']())_0x1ebebf[_0x1f8caf]='';}if('string'==typeof _0x1ebebf&&(_0x1ebebf={'main':_0x1ebebf}),void 0x0===_0x56b11d){_0x56b11d={};for(const _0x1b098d of this['editor']['model']['document']['getRootNames']())_0x56b11d[_0x1b098d]={};}let _0xd6b5c1=!0x1;const _0x12c616=Object['keys'](_0x1ebebf),_0x4625d8=Object['keys'](_0x43dda5);for(const _0xc8ebc1 of _0x12c616){if(_0x1ebebf[_0xc8ebc1]!==_0x43dda5[_0xc8ebc1]&&''!==_0x1ebebf[_0xc8ebc1]['trim']()){_0xd6b5c1=!0x0;break;}if(!_0x3ea6af(_0x56b11d[_0xc8ebc1],_0x57d7d7[_0xc8ebc1])&&Object['keys'](_0x56b11d[_0xc8ebc1])['length']>0x0){_0xd6b5c1=!0x0;break;}}_0xd6b5c1||(_0xd6b5c1=_0x4625d8['some'](_0x868ce3=>!this['editor']['model']['document']['getRoot'](_0x868ce3))),_0xd6b5c1&&_0x2a2f93('editor-initial-data-replaced-with-revision-data',{'editorData':_0x1ebebf,'editorRootsAttributes':_0x56b11d,'revisionData':_0x43dda5,'revisionRootsAttributes':_0x57d7d7}),this['editor']['config']['set']('initialData',_0x43dda5),this['editor']['config']['set']('rootsAttributes',_0x57d7d7);}['_addPendingAction'](){if(!this['_pendingAction']){const _0x525aca=this['editor']['plugins']['get']('PendingActions');this['_pendingAction']=_0x525aca['add'](g(this['editor']['locale'],'PENDING_ACTION_REVISION_HISTORY'));}}['_removePendingAction'](){this['_pendingAction']&&(this['editor']['plugins']['get']('PendingActions')['remove'](this['_pendingAction']),this['_pendingAction']=null);}['_findInsertionIndex'](_0x1b5be8){const _0x173e6b=this['repository']['getRevisions']();_0x173e6b['reverse']();let _0x5b7daf=0x0;for(;_0x5b7daf<_0x173e6b['length'];){const _0x3506a7=_0x173e6b[_0x5b7daf];if(_0x3506a7===this['currentRevision']){_0x5b7daf++;continue;}if(_0x3506a7['id']===this['_initialRevisionId'])break;const _0x2d9c2a=_0x1b5be8['toVersion']-_0x3506a7['toVersion']||_0x1b5be8['fromVersion']-_0x3506a7['fromVersion'];if(_0x2d9c2a>0x0)break;if(_0x2d9c2a<0x0)_0x5b7daf++;else{if(!_0x1b5be8['creator']&&_0x3506a7['creator'])break;if(_0x3506a7['creator']||!_0x1b5be8['creator']){if(_0x1b5be8['createdAt']>_0x3506a7['createdAt'])break;_0x5b7daf++;}else _0x5b7daf++;}}return _0x5b7daf;}['_getFromVersion'](_0x4683f9){const _0x37a644=this['repository']['getRevisions']();_0x37a644['reverse'](),_0x37a644['shift']();const _0x234bc7=_0x37a644['find'](_0x12d8de=>_0x12d8de['toVersion']<=_0x4683f9)['toVersion'];return _0x234bc7<this['_startingVersion']?this['_startingVersion']:_0x234bc7;}['_makeRevision']({name:_0x30190d,from:_0x22e861,to:_0x1cdab5,creatorId:_0x10362a,id:_0x389aa7}){const _0x2eff71=this['buildRevisionData']({'from':_0x22e861,'to':_0x1cdab5});_0x2eff71['name']=_0x30190d,_0x2eff71['creatorId']=_0x10362a,_0x2eff71['id']=_0x389aa7;const _0x40ac8f=this['addRevisionData'](_0x2eff71);return this['adapter']&&this['_bufferUpdate'](_0x2eff71['id'],_0x2eff71,!0x0),_0x40ac8f;}['_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(_0x3c2c2a){this['editor']=_0x3c2c2a,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'](_0x4b4f34){this['source']=_0x4b4f34;const _0x4fdf5e=new Map(),_0x3ae5d7=new Map(),_0x46f54d=this['editor']['model']['document']['roots']['map'](_0x16d454=>_0x16d454['rootName']);for(const _0x533b63 of _0x46f54d){const _0x4c0529=this['editor']['model']['document']['getRoot'](_0x533b63),_0x4f12bf=N(_0x4c0529);_0x4fdf5e['set'](_0x533b63,_0x4f12bf),_0x3ae5d7['set'](_0x533b63,Object['fromEntries'](_0x4c0529['getAttributes']()));}const _0x194f8f=Array['from'](this['editor']['model']['markers'])['map'](_0x13b5d3=>[_0x13b5d3['name'],_0x13b5d3['getRange']()]),_0x4f8e1e=this['source']['version'];this['_saveMetaData'](_0x4f8e1e,_0x4fdf5e,_0x194f8f,_0x3ae5d7),this['_startingRevisionId']=this['_revisionId'];const _0x3ce46a=new Map(),_0x4a020b=new Map();for(const _0x866e48 of _0x46f54d){const _0x399bda=P(_0x866e48);_0x3ce46a['set'](_0x866e48,_0x399bda),_0x4a020b['set'](_0x866e48,{});}this['_saveMetaData'](Number['NEGATIVE_INFINITY'],_0x3ce46a,[],_0x4a020b);}['getData'](_0x51e214,_0x35626e){if(this['_lastFrom']===_0x51e214&&this['_lastTo']<=_0x35626e)this['_savedMetaData']['size']>0x1&&this['_removeMetaData'](this['_lastTo']),this['_applyOperations'](this['_lastTo'],_0x35626e,!0x0);else{if(!this['_savedMetaData']['has'](_0x51e214)){const _0x523c5a=this['_getPreviousFrom'](_0x51e214);this['_calculateMetaData'](_0x523c5a,_0x51e214,!0x1);}this['_calculateMetaData'](_0x51e214,_0x35626e,!0x0);}return this['_lastFrom']=_0x51e214,this['_lastTo']=_0x35626e,this['_getState']();}['loadState'](_0x4cf4e9){const _0x1e7df2=this['editor']['plugins']['get']('RevisionHistoryUtils');this['_reset'](),this['_lastFrom']=_0x4cf4e9['fromVersion'],this['_lastTo']=_0x4cf4e9['toVersion'];for(const _0x1b4868 in _0x4cf4e9['diffData']){const _0xb00073=_0x4cf4e9['diffData'][_0x1b4868]['attachChange'],_0x21b55e=_0x74c535(_0x4cf4e9['diffData'][_0x1b4868]['attributesBefore'])||{},_0x4cda8c=_0x1e7df2['_makeModelFromViewString'](_0x4cf4e9['diffData'][_0x1b4868]['deletions']);_0x4cda8c['rootName']=_0x1b4868,_0x4cda8c['_isAttached']=!_0xb00073||!_0xb00073['isAttached'],_0x4cda8c['isAttached']=()=>_0x4cda8c['_isAttached'],this['_baseRoots']['set'](_0x1b4868,_0x4cda8c),this['_baseRootsAttributes']['set'](_0x1b4868,_0x21b55e),_0xb00073&&this['_touchedRoots']['set'](_0x1b4868,_0xb00073);const _0x48bbcf=this['_makeIdsRoot'](_0x4cda8c);this['_baseIdsRoots']['set'](_0x1b4868,_0x48bbcf);for(const [_0x1c5413,_0x4478e8]of _0x4cda8c['markers']){if(!_0x1c5413['startsWith']('revision:'))continue;const _0x235b09=_0x1c5413['split'](':')[0x2];for(const _0x6ede13 of _0x4478e8['getWalker']({'singleCharacters':!0x0})){const _0x3787b8=this['_getVidAttributeName'](_0x6ede13),_0x1cdfdc='elementEnd'==_0x6ede13['type']?_0x6ede13['previousPosition']['path']['slice'](0x0,-0x1):_0x6ede13['previousPosition']['path'],_0x36d09d=_0x48bbcf['getNodeByPath'](_0x1cdfdc)['getAttribute'](_0x3787b8);this['_touched']['set'](_0x36d09d,{'userId':_0x235b09});}}}this['_startingRevisionId']=this['_revisionId'];const _0x5e3278=[...Array(this['_revisionId'])['keys']()]['slice'](0x1)['filter'](_0x633303=>!this['_touched']['has'](_0x633303));let _0x35ec0d=0x0;const _0x548fbf=new Map();for(const _0x88be6d in _0x4cf4e9['diffData']){const _0x4902cd=_0x4cf4e9['diffData'][_0x88be6d]['attachChange'],_0x2ee255=_0x74c535(_0x4cf4e9['diffData'][_0x88be6d]['attributesAfter'])||{},_0xac7ca4=_0x1e7df2['_makeModelFromViewString'](_0x4cf4e9['diffData'][_0x88be6d]['insertions']);_0xac7ca4['rootName']=_0x88be6d,_0xac7ca4['_isAttached']=!_0x4902cd||_0x4902cd['isAttached'],_0xac7ca4['isAttached']=()=>_0xac7ca4['_isAttached'],this['_diffRoots']['set'](_0x88be6d,_0xac7ca4),this['_diffRootsAttributes']['set'](_0x88be6d,_0x2ee255);const _0x5e549c=this['_makeIdsRoot'](_0xac7ca4,Number['NEGATIVE_INFINITY']);this['_idsRoots']['set'](_0x88be6d,_0x5e549c),_0x548fbf['set'](_0x88be6d,_0xac7ca4['isAttached']()?_0x2ee255:{});for(const [_0x4b4865,_0x3913b1]of _0xac7ca4['markers']){if(!_0x4b4865['startsWith']('revision:'))continue;const _0x31f39d=_0x4b4865['split'](':')[0x2];for(const _0x4f4fe7 of _0x3913b1['getWalker']({'singleCharacters':!0x0})){const _0x333c1d=this['_getVidAttributeName'](_0x4f4fe7),_0x2edab7=this['_revisionId']++,_0x523004='elementEnd'==_0x4f4fe7['type']?_0x4f4fe7['previousPosition']['path']['slice'](0x0,-0x1):_0x4f4fe7['previousPosition']['path'];_0x5e549c['getNodeByPath'](_0x523004)['_setAttribute'](_0x333c1d,_0x2edab7),this['_touched']['set'](_0x2edab7,{'userId':_0x31f39d});}}for(const _0x1e55f1 of this['editor']['model']['createRangeIn'](_0xac7ca4)['getWalker']({'singleCharacters':!0x0})){const _0xd22273=this['_getVidAttributeName'](_0x1e55f1),_0x5a63ba='elementEnd'==_0x1e55f1['type']?_0x1e55f1['previousPosition']['path']['slice'](0x0,-0x1):_0x1e55f1['previousPosition']['path'],_0x4e3d47=_0x5e549c['getNodeByPath'](_0x5a63ba);_0x4e3d47['getAttribute'](_0xd22273)>0x0||_0x4e3d47['_setAttribute'](_0xd22273,_0x5e3278[_0x35ec0d++]);}for(const [_0x818de2,_0x4297d5]of _0xac7ca4['markers'])_0x818de2['startsWith']('revision:')||this['_markers']['set'](_0x818de2,_0x4297d5);}const _0x1487e0=P('$graveyard');this['_baseRoots']['set']('$graveyard',_0x1487e0),this['_baseIdsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x1487e0,0x1));const _0x2b64e1=P('$graveyard');this['_diffRoots']['set']('$graveyard',_0x2b64e1),this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x2b64e1,0x1));const _0x115465=Array['from'](this['_diffRoots'])['map'](([_0x58b73e,_0x2c0b72])=>[_0x58b73e,N(_0x2c0b72)]);this['_saveMetaData'](this['_lastTo'],_0x115465,this['_markers'],_0x548fbf);}['reInit'](){this['_reset'](),this['_lastFrom']=-0x1,this['_lastTo']=-0x1,this['_savedMetaData']['clear'](),this['init'](this['source']);}['_saveMetaData'](_0x1ca650,_0x45e118,_0xb5bac4,_0x3cbaf0){const _0x546b23=new Map(_0x45e118),_0x4edfed=new Map(_0x74c535(_0x3cbaf0)),_0x4877a1=new Map();for(const [_0x324ab9,_0x3a6e9a]of _0xb5bac4)_0x4877a1['set'](_0x324ab9,{'start':_0x3a6e9a['start']['clone'](),'end':_0x3a6e9a['end']['clone'](),'rootName':_0x3a6e9a['root']['rootName']});this['_savedMetaData']['set'](_0x1ca650,{'roots':_0x546b23,'markers':_0x4877a1,'rootsAttributes':_0x4edfed});}['_removeMetaData'](_0x37a91e){this['_savedMetaData']['delete'](_0x37a91e);}['_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'](_0x37fec4,_0x5ebcf7=null){let _0x356057=null;_0x37fec4['is']('documentFragment')||(_0x356057=new ut(_0x37fec4['name'],{'vid_start':null===_0x5ebcf7?this['_revisionId']++:_0x5ebcf7++}));const _0x501e92=[];for(const _0x13d8e3 of _0x37fec4['getChildren']())if(_0x13d8e3['is']('element')){_0x501e92['push'](this['_makeIdsRoot'](_0x13d8e3,_0x5ebcf7));const _0x46b8a7=_0x501e92[_0x501e92['length']-0x1];null!==_0x5ebcf7&&(_0x5ebcf7=_0x46b8a7['is']('element','$text')?_0x46b8a7['getAttribute']('vid')+0x1:_0x46b8a7['getAttribute']('vid_end')+0x1);}else{for(let _0x1542e5=0x0;_0x1542e5<_0x13d8e3['offsetSize'];_0x1542e5++)_0x501e92['push'](new ut('$text',{'vid':null===_0x5ebcf7?this['_revisionId']++:_0x5ebcf7++}));}if(_0x37fec4['is']('documentFragment')){const _0x5647dd=P(_0x37fec4['rootName']);return _0x5647dd['_insertChild'](0x0,_0x501e92),_0x5647dd;}return _0x356057['_setAttribute']('vid_end',null===_0x5ebcf7?this['_revisionId']++:_0x5ebcf7++),_0x356057['_insertChild'](0x0,_0x501e92),_0x356057;}['_calculateMetaData'](_0x3003ef,_0x4ec1ac,_0x1d2bab){this['_reset']();const {roots:_0x1bd9fe,markers:_0x296924,rootsAttributes:_0x7681fc}=this['_savedMetaData']['get'](_0x3003ef);this['_baseRoots']=new Map(_0x1bd9fe),this['_baseRootsAttributes']=new Map(_0x74c535(_0x7681fc));for(const [_0x51bf14,_0x571c1d]of this['_baseRoots'])if('$graveyard'!==_0x51bf14&&(this['_diffRoots']['set'](_0x51bf14,N(_0x571c1d)),this['_diffRootsAttributes']=new Map(_0x74c535(_0x7681fc)),_0x1d2bab)){const _0x6ec9=this['_revisionId'];this['_idsRoots']['set'](_0x51bf14,this['_makeIdsRoot'](_0x571c1d)),this['_baseIdsRoots']['set'](_0x51bf14,this['_makeIdsRoot'](_0x571c1d,_0x6ec9));}this['_startingRevisionId']=this['_revisionId'],this['_diffRoots']['set']('$graveyard',N(this['_baseRoots']['get']('$graveyard'))),_0x1d2bab&&this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](this['_baseRoots']['get']('$graveyard')));for(const [_0x491012,_0x20f7bc]of _0x296924){const _0x32e6bf=this['_baseRoots']['get'](_0x20f7bc['rootName']),_0x707a69=this['_diffRoots']['get'](_0x20f7bc['rootName']),_0x274142=new lt(this['_fixPosition'](_0x20f7bc['start'],_0x32e6bf),this['_fixPosition'](_0x20f7bc['end'],_0x32e6bf)),_0xd6d547=this['_fixRange'](_0x274142,_0x707a69);_0x32e6bf['markers']['set'](_0x491012,_0x274142),this['_markers']['set'](_0x491012,_0xd6d547);}this['_applyOperations'](_0x3003ef,_0x4ec1ac,_0x1d2bab);}['_applyOperations'](_0x3bdd7f,_0xcfb484,_0x5a59be){for(const _0x3a7c69 of this['source']['getOperations'](_0x3bdd7f,_0xcfb484))this['_handleOperation'](_0x3a7c69,_0x5a59be);for(const _0x40c9be of this['_diffRoots']['values']())_0x40c9be['markers']['clear']();for(const [_0x268113,_0x318419]of this['_markers']){this['_diffRoots']['get'](_0x318419['root']['rootName'])['markers']['set'](_0x268113,_0x318419['clone']());}const _0x2579ef=new Map(),_0x4c1cb3=new Map();for(const [_0x2a56d3,_0x1d960b]of this['_diffRoots'])_0x2579ef['set'](_0x2a56d3,N(_0x1d960b)),_0x4c1cb3['set'](_0x2a56d3,this['_diffRootsAttributes']['get'](_0x2a56d3));this['_saveMetaData'](_0xcfb484,_0x2579ef,this['_markers'],_0x4c1cb3);}['_getPreviousFrom'](_0x5a40f4){const _0x188cec=Array['from'](this['_savedMetaData']['keys']());_0x188cec['sort']((_0xa855dc,_0x6e495e)=>_0xa855dc-_0x6e495e),_0x188cec['reverse']();for(const _0x43d14a of _0x188cec)if(_0x43d14a<_0x5a40f4)return _0x43d14a;return Number['NEGATIVE_INFINITY'];}['_copyMarkers'](_0x401852,_0x265326){const _0x42f306=Array['from'](_0x265326['markers'])['map'](([_0x20ad9e,_0x3d8c92])=>[_0x20ad9e,this['_fixRange'](_0x3d8c92,_0x401852)]);_0x401852['markers']=new Map(_0x42f306);}['_transformMarkers'](_0x86200e){for(const _0x35825b of this['_markers']['values']()){const _0x587644=_0x35825b['getTransformedByOperation'](_0x86200e),_0x101967=lt['_createFromRanges'](_0x587644);_0x35825b['start']=_0x101967['start'],_0x35825b['end']=_0x101967['end'];}}['_handleOperation'](_0x25f855,_0x21be2c){if('addRoot'!=_0x25f855['type']&&'detachRoot'!=_0x25f855['type']){if('insert'==_0x25f855['type']){const _0x55e46d=_0x25f855['position']['root']['rootName'];this['_diffRoots']['has'](_0x55e46d)||(this['_diffRoots']['set'](_0x55e46d,P(_0x55e46d,!0x0)),this['_diffRootsAttributes']['set'](_0x55e46d,{}),_0x21be2c&&this['_idsRoots']['set'](_0x55e46d,P(_0x55e46d,!0x0)));}else{if('addRootAttribute'==_0x25f855['type']||'removeRootAttribute'==_0x25f855['type']||'changeRootAttribute'==_0x25f855['type'])return void this['_handleRootAttributeOperation'](_0x25f855);'marker'==_0x25f855['type']&&this['_handleMarkerOperation'](_0x25f855);}if('marker'!==_0x25f855['type']){const _0x2d3b57=this['_cloneOperation'](_0x25f855,this['_diffRoots']);_0x2d3b57['_execute'](),this['_transformMarkers'](_0x2d3b57);}if(_0x21be2c)switch(_0x25f855['type']){case'insert':this['_handleInsertOperation'](_0x25f855);break;case'move':case'remove':case'reinsert':this['_handleMoveOperation'](_0x25f855);break;case'merge':this['_handleMergeOperation'](_0x25f855);break;case'split':this['_handleSplitOperation'](_0x25f855);}}else this['_handleRootOperation'](_0x25f855,_0x21be2c);}['_cloneOperation'](_0x14e43a,_0x34794d){const _0x1a8d5b=_0x14e43a['clone']();return _0x1a8d5b['_authorId']=_0x14e43a['_authorId'],this['_fixOperation'](_0x1a8d5b,_0x34794d),_0x1a8d5b;}['_getBaseVids'](_0x20d7d1){return _0x20d7d1['map'](_0x33759e=>{const _0x2265ff=this['_getVidAttributeName'](_0x33759e);return Number(_0x33759e['item']['getAttribute'](_0x2265ff));});}['_generateTape'](_0x2276c9,_0x35e671){if(_0x2276c9['is']('element','$text'))_0x35e671['push']({'item':_0x2276c9,'type':'text'});else{_0x2276c9['is']('element')&&_0x35e671['push']({'item':_0x2276c9,'type':'elementStart'});for(const _0x4db705 of _0x2276c9['getChildren']())this['_generateTape'](_0x4db705,_0x35e671);_0x2276c9['is']('element')&&_0x35e671['push']({'item':_0x2276c9,'type':'elementEnd'});}return _0x35e671;}['_getState'](){const _0x4f0a7e=new Map(this['_touched']),_0x3cf78e=new Map(_0x4f0a7e),_0x26c546=new Map(),_0x4cc4b8={'insertions':{},'deletions':{}},_0x54b1ad={'insertions':{},'deletions':{}},_0x38b205=new Map(),_0x308073=new Set([...this['_baseRoots']['keys'](),...this['_diffRoots']['keys']()]);_0x308073['delete']('$graveyard');for(const _0xe4a8f9 of _0x308073){const _0x4b400a=this['_diffRoots']['get'](_0xe4a8f9)||P(_0xe4a8f9,!0x1),_0xcf6bb1=this['_baseRoots']['get'](_0xe4a8f9)||P(_0xe4a8f9,!0x1);_0x4b400a['isAttached']()||_0xcf6bb1['isAttached']()?(_0x4cc4b8['insertions'][_0xe4a8f9]=N(_0x4b400a),_0x4cc4b8['deletions'][_0xe4a8f9]=N(_0xcf6bb1),this['_copyMarkers'](_0x4cc4b8['deletions'][_0xe4a8f9],_0xcf6bb1),this['_copyMarkers'](_0x4cc4b8['insertions'][_0xe4a8f9],_0x4b400a),_0x54b1ad['insertions'][_0xe4a8f9]=this['_generateTape'](this['_idsRoots']['get'](_0xe4a8f9),[]),_0x54b1ad['deletions'][_0xe4a8f9]=this['_generateTape'](this['_baseIdsRoots']['get'](_0xe4a8f9)||P(_0xe4a8f9,!0x1),[])):_0x308073['delete'](_0xe4a8f9);}for(const _0x1e00ec of _0x308073){const _0xaff5bf=_0x54b1ad['insertions'][_0x1e00ec];for(const _0x590484 of _0xaff5bf){const _0x88f4b1=this['_getVidAttributeName'](_0x590484),_0x519614=_0x590484['item']['getAttribute'](_0x88f4b1);_0x3cf78e['delete'](_0x519614),_0x519614>=this['_startingRevisionId']&&_0x26c546['set'](_0x519614,_0x4f0a7e['get'](_0x519614));}}for(const _0x3e6714 of _0x308073){const _0x4e7ff2=_0x54b1ad['insertions'][_0x3e6714],_0x32d79e=this['_getBaseVids'](_0x54b1ad['deletions'][_0x3e6714]);let _0x154e00=0x0;for(const _0x178332 of _0x4e7ff2){const _0x3f1558=this['_getVidAttributeName'](_0x178332),_0x2f7a4a=_0x178332['item']['getAttribute'](_0x3f1558);if(!_0x26c546['has'](_0x2f7a4a)&&!_0x38b205['has'](_0x2f7a4a)){if(_0x3cf78e['has'](_0x2f7a4a))_0x154e00++;else{if(_0x2f7a4a!=_0x32d79e[_0x154e00]){const _0xf579a4=_0x4f0a7e['get'](_0x2f7a4a)||_0x4f0a7e['get'](_0x32d79e[_0x154e00]);for(;_0x2f7a4a!=_0x32d79e[_0x154e00];)_0x3cf78e['has'](_0x32d79e[_0x154e00])||(_0x38b205['set'](_0x32d79e[_0x154e00],_0xf579a4),_0x4f0a7e['set'](_0x32d79e[_0x154e00],_0xf579a4)),_0x154e00++;}_0x154e00++;}}}}for(const _0x4736f6 of _0x308073){const _0x3d4fde=_0x54b1ad['insertions'][_0x4736f6];for(const _0x4a38f5 of _0x3d4fde){const _0x47854b=this['_getVidAttributeName'](_0x4a38f5),_0x3bba23=_0x4a38f5['item']['getAttribute'](_0x47854b);if(_0x38b205['has'](_0x3bba23)){const _0x26ff58=_0x38b205['get'](_0x3bba23);_0x3cf78e['has'](_0x3bba23)||_0x3cf78e['set'](_0x3bba23,{..._0x26ff58}),_0x26c546['set'](_0x3bba23,{..._0x26ff58});}}}for(const _0xa8c2ac of _0x3cf78e['keys']())_0xa8c2ac>=this['_startingRevisionId']&&_0x3cf78e['delete'](_0xa8c2ac);const _0x55710c=new Map();for(const _0x1262e7 of _0x308073){let _0x327feb=_0x54b1ad['insertions'][_0x1262e7];for(const _0x5c187e of _0x327feb)if(_0x5c187e['item']['is']('element','tableCell')){const _0x3f160c=this['_getVidAttributeName'](_0x5c187e),_0xef29cf=_0x5c187e['item']['getAttribute'](_0x3f160c);if(_0x26c546['has'](_0xef29cf)){const _0x4c7ec2=_0x5c187e['item']['parent']['parent']['getAttribute']('vid_start'),_0x2d1bdc=_0x55710c['get'](_0x4c7ec2)||new Set();_0x2d1bdc['add'](_0x26c546['get'](_0xef29cf)['userId']),_0x55710c['set'](_0x4c7ec2,_0x2d1bdc);}}_0x327feb=_0x54b1ad['deletions'][_0x1262e7];for(const _0x1aab03 of _0x327feb)if(_0x1aab03['item']['is']('element','tableCell')){const _0x51a6ac=this['_getVidAttributeName'](_0x1aab03),_0x593b9b=_0x1aab03['item']['getAttribute'](_0x51a6ac);if(_0x3cf78e['has'](_0x593b9b)){const _0x3bf208=_0x1aab03['item']['parent']['parent']['getAttribute']('vid_start'),_0x25ab0b=_0x55710c['get'](_0x3bf208)||new Set();_0x25ab0b['add'](_0x3cf78e['get'](_0x593b9b)['userId']),_0x55710c['set'](_0x3bf208,_0x25ab0b);}}for(const _0x441c26 of _0x55710c['keys']())(_0x26c546['has'](_0x441c26)||_0x3cf78e['has'](_0x441c26))&&_0x55710c['delete'](_0x441c26);}for(const _0x305c0a of _0x308073){const _0x5d1688=_0x54b1ad['insertions'][_0x305c0a];let _0x8de701=null,_0x10b109=null;for(const _0x568a01 of _0x5d1688){const _0x54a254=this['_getVidAttributeName'](_0x568a01),_0x34dde5=_0x568a01['item']['getAttribute'](_0x54a254),_0x435e65=_0x55710c['get'](_0x34dde5);_0x435e65&&'elementStart'==_0x568a01['type']&&(_0x8de701=Array['from'](_0x435e65)[0x0],_0x10b109=_0x568a01['item']['getAttribute']('vid_end')),_0x8de701&&(_0x3cf78e['set'](_0x34dde5,{'userId':_0x8de701}),_0x26c546['set'](_0x34dde5,{'userId':_0x8de701})),_0x34dde5==_0x10b109&&(_0x8de701=null,_0x10b109=null);}}const _0x24c739={},_0x55b633=new Set();for(const _0x31fdb3 of _0x308073){const _0x5b640a=_0x4cc4b8['deletions'][_0x31fdb3],_0x4012e9=_0x4cc4b8['insertions'][_0x31fdb3];for(const {userId:_0x50532a}of this['_touchedMarkers']['values']())null!==_0x50532a&&_0x55b633['add'](_0x50532a);for(const {userId:_0x4ac16b}of this['_touchedRoots']['values']())null!==_0x4ac16b&&_0x55b633['add'](_0x4ac16b);this['_markChanges'](_0x4012e9,_0x54b1ad['insertions'][_0x31fdb3],_0x26c546,'insertion',_0x55b633),this['_markChanges'](_0x5b640a,_0x54b1ad['deletions'][_0x31fdb3],_0x3cf78e,'deletion',_0x55b633),_0x24c739[_0x31fdb3]={'insertions':this['_prepareViewToSave'](_0x4012e9),'deletions':this['_prepareViewToSave'](_0x5b640a),'attachChange':this['_touchedRoots']['get'](_0x31fdb3)||null,'attributesBefore':_0x74c535(this['_baseRootsAttributes']['get'](_0x31fdb3))||{},'attributesAfter':_0x74c535(this['_diffRootsAttributes']['get'](_0x31fdb3))};}return{'diffData':_0x24c739,'authorsIds':Array['from'](_0x55b633)};}['_processRootBeforeSave'](_0x388189){for(const [,_0x389f8c]of _0x388189['markers']){const _0x493a8e=_0x389f8c['start']['getAncestors']()['filter'](_0x2c6e54=>'tableCell'==_0x2c6e54['name']);for(const _0x4edc00 of _0x493a8e)0x1==_0x4edc00['childCount']&&_0x4edc00['getChild'](0x0)['is']('element','paragraph')&&_0x4edc00['getChild'](0x0)['_setAttribute']('keepParagraph',!0x0);}}['_prepareViewToSave'](_0x36efc5){this['_processRootBeforeSave'](_0x36efc5);const _0x3e8f85=this['editor']['data']['toView'](_0x36efc5,{}),_0x1b885c=Array['from'](_0x3e8f85['getChildren']())['map'](_0x213597=>this['_getViewJson'](_0x213597));return JSON['stringify'](_0x1b885c);}['_getViewJson'](_0x41100d){if(_0x41100d['is']('$text'))return _0x41100d['data'];{const _0x43927f=this['editor']['plugins']['get']('RevisionHistoryUtils'),_0x5d4286=_0x41100d,_0x275d44=this['editor']['data']['htmlProcessor']['domConverter'],_0x3f1ecb={'type':_0x43927f['_getTypeCharForViewElement'](_0x5d4286),'name':_0x5d4286['name'],'attributes':Array['from'](_0x5d4286['getAttributes']()),'children':Array['from'](_0x5d4286['getChildren']())['map'](_0xc0ef6e=>this['_getViewJson'](_0xc0ef6e))};if(_0x41100d['is']('uiElement')&&'$comment'!=_0x41100d['name']){const _0x5af204=_0x41100d['render'](_0x275d44['domDocument'],_0x275d44);_0x3f1ecb['children']['push'](_0x5af204['outerHTML']);}else{if(_0x41100d['is']('rawElement')){const _0x4d4dfb=_0x275d44['domDocument']['createElement'](_0x5d4286['name']);_0x41100d['render'](_0x4d4dfb,_0x275d44),_0x3f1ecb['children']['push'](_0x4d4dfb['innerHTML']);}}const _0x34c90d=Array['from'](_0x5d4286['getCustomProperties']());_0x34c90d['length']>0x0&&(_0x3f1ecb['customProperties']=_0x34c90d);const _0x3a6301=_0x5d4286['getFillerOffset']();return null!==_0x3a6301&&(_0x3f1ecb['fillerOffset']=_0x3a6301),_0x3f1ecb;}}['_markChanges'](_0x70d3da,_0xdc56c6,_0x2422d0,_0x26a8a7,_0x12bd69){let _0x4bf23f=null,_0x1a37f1=null,_0x3f2729=0x0;const _0x15370c=this['editor']['model'];for(let _0x1b57e8=0x0;_0x1b57e8<_0xdc56c6['length'];_0x1b57e8++){const _0x34b1c3=this['_getVidAttributeName'](_0xdc56c6[_0x1b57e8]),_0x4f02aa=_0xdc56c6[_0x1b57e8]['item']['getAttribute'](_0x34b1c3),_0x48427f=_0x2422d0['get'](_0x4f02aa),_0x2d8592=_0x1b57e8==_0xdc56c6['length']-0x1;(!_0x4bf23f&&_0x48427f&&(_0x4bf23f=_0x48427f,_0x1a37f1=_0xdc56c6[_0x1b57e8]),_0x4bf23f&&(!_0x48427f||_0x48427f['userId']!=_0x4bf23f['userId']))&&(_0x507d44(_0x48427f,F(_0x1a37f1,_0x70d3da,_0x15370c),F(_0xdc56c6[_0x1b57e8],_0x70d3da,_0x15370c)),_0x4bf23f=_0x48427f||null,_0x1a37f1=_0x48427f?_0xdc56c6[_0x1b57e8]:null),_0x4bf23f&&_0x2d8592&&_0x507d44(_0x48427f,F(_0x1a37f1,_0x70d3da,_0x15370c),B(_0xdc56c6[_0x1b57e8],_0x70d3da,_0x15370c));}function _0x507d44(_0x3484f2,_0x1ceb8f,_0xcd4de6){const _0x4e24f0=_0x4bf23f['userId'],_0x1a8ca7='revision:'+_0x26a8a7+':'+_0x4e24f0+':'+_0x3f2729++,_0x48403f=_0x15370c['createRange'](_0x1ceb8f,_0xcd4de6);_0x70d3da['markers']['set'](_0x1a8ca7,_0x48403f),null!==_0x4e24f0&&_0x12bd69['add'](_0x4e24f0);}}['_getVidAttributeName'](_0x2dcae3){switch(_0x2dcae3['type']){case'elementStart':return'vid_start';case'elementEnd':return'vid_end';default:return'vid';}}['_fixOperation'](_0x61599d,_0x168bfc){_0x61599d['baseVersion']=null;for(const _0x2a158e in _0x61599d){const _0x564355=_0x61599d[_0x2a158e];if(_0x564355 instanceof ft){const _0x1553c2=_0x168bfc['get'](_0x564355['root']['rootName']);_0x61599d[_0x2a158e]=this['_fixPosition'](_0x564355,_0x1553c2);}if(_0x564355 instanceof lt){const _0x1bcd57=_0x168bfc['get'](_0x564355['root']['rootName']);_0x61599d[_0x2a158e]=this['_fixRange'](_0x564355,_0x1bcd57);}'root'===_0x2a158e&&(_0x61599d['root']=_0x168bfc['get'](_0x61599d['root']['rootName']));}}['_fixRange'](_0x391b94,_0x5ebfda){return this['editor']['model']['createRange'](this['_fixPosition'](_0x391b94['start'],_0x5ebfda),this['_fixPosition'](_0x391b94['end'],_0x5ebfda));}['_fixPosition'](_0xece24a,_0x3d6a1b){return this['editor']['model']['createPositionFromPath'](_0x3d6a1b,_0xece24a['path'],_0xece24a['stickiness']);}['_handleInsertOperation'](_0x80bfe2){const _0x35da92=this['_idsRoots']['get'](_0x80bfe2['position']['root']['rootName']),_0x5dc25d=this['_fixPosition'](_0x80bfe2['position'],_0x35da92),_0x2aa606=null===_0x80bfe2['_authorId']?null:_0x80bfe2['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x2f172e=_0x5dc25d['parent'],_0x469e8a=this['_revisionId'],_0x25bfb7=[];for(const _0x907c99 of _0x80bfe2['nodes'])if(_0x907c99['is']('element'))_0x25bfb7['push'](this['_makeIdsRoot'](_0x907c99));else{for(let _0x39b02d=0x0;_0x39b02d<_0x907c99['offsetSize'];_0x39b02d++)_0x25bfb7['push'](new ut('$text',{'vid':this['_revisionId']++}));}const _0xd28ec6=this['_revisionId'];for(let _0x1cc6c9=_0x469e8a;_0x1cc6c9<_0xd28ec6;_0x1cc6c9++)this['_touched']['set'](_0x1cc6c9,{'userId':_0x2aa606});_0x2f172e['_insertChild'](_0x5dc25d['offset'],_0x25bfb7);}['_handleMoveOperation'](_0x54b6da){(_0x54b6da=this['_cloneOperation'](_0x54b6da,this['_idsRoots']))['_execute']();const _0x4e0854=null===_0x54b6da['_authorId']?null:_0x54b6da['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x493092=_0x54b6da['getMovedRangeStart'](),_0x3497f6=_0x493092['parent'],_0x4d3a4b=_0x493092['offset'];!function _0x1c5bd3(_0x4453ad,_0x5aef36,_0x4d1904,_0xa6890f){for(let _0x792185=_0x4d1904;_0x792185<_0xa6890f;_0x792185++){const _0x565b17=_0x5aef36['getChild'](_0x792185);_0x565b17['is']('element','$text')?_0x4453ad['set'](_0x565b17['getAttribute']('vid'),{'userId':_0x4e0854}):(_0x4453ad['set'](_0x565b17['getAttribute']('vid_start'),{'userId':_0x4e0854}),_0x1c5bd3(_0x4453ad,_0x565b17,0x0,_0x565b17['childCount']),_0x4453ad['set'](_0x565b17['getAttribute']('vid_end'),{'userId':_0x4e0854}));}}(this['_touched'],_0x3497f6,_0x4d3a4b,_0x4d3a4b+_0x54b6da['howMany']);}['_handleMergeOperation'](_0x1253c8){const _0x96f93c=null===(_0x1253c8=this['_cloneOperation'](_0x1253c8,this['_idsRoots']))['_authorId']?null:_0x1253c8['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x316573=_0x1253c8['targetPosition']['parent'],_0x19b235=_0x1253c8['sourcePosition']['parent'],_0x22e748=_0x316573['getAttribute']('vid_end'),_0x1d80ff=_0x19b235['getAttribute']('vid_start');_0x316573['_setAttribute']('vid_end',_0x19b235['getAttribute']('vid_end')),_0x19b235['_setAttribute']('vid_end',_0x22e748),this['_touched']['set'](_0x1d80ff,{'userId':_0x96f93c}),this['_touched']['set'](_0x22e748,{'userId':_0x96f93c}),_0x1253c8['_execute']();}['_handleSplitOperation'](_0x365072){const _0x58de47=null===(_0x365072=this['_cloneOperation'](_0x365072,this['_idsRoots']))['_authorId']?null:_0x365072['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x1e5a0c=_0x365072['graveyardPosition'],_0x523261=_0x365072['splitPosition']['parent'];_0x365072['_execute']();const _0x57ecd1=_0x523261['getAttribute']('vid_end'),_0x3dbda4=_0x365072['insertionPosition']['nodeAfter'];if(_0x1e5a0c){const _0x3c20e0=_0x3dbda4['getAttribute']('vid_end'),_0x231a4d=_0x523261['getAttribute']('vid_end');_0x523261['_setAttribute']('vid_end',_0x3c20e0),_0x3dbda4['_setAttribute']('vid_end',_0x231a4d),this['_touched']['set'](_0x523261['getAttribute']('vid_end'),{'userId':_0x58de47}),this['_touched']['set'](_0x3dbda4['getAttribute']('vid_start'),{'userId':_0x58de47});}else{const _0x2a3e2b=this['_revisionId']++,_0x1c70ec=this['_revisionId']++;_0x523261['_setAttribute']('vid_end',_0x2a3e2b),_0x3dbda4['_setAttribute']('vid_start',_0x1c70ec),_0x3dbda4['_setAttribute']('vid_end',_0x57ecd1),this['_touched']['set'](_0x2a3e2b,{'userId':_0x58de47}),this['_touched']['set'](_0x1c70ec,{'userId':_0x58de47});}}['_handleMarkerOperation'](_0x4380d5){if(!_0x4380d5['affectsData'])return;const _0x507414=(_0x4380d5=this['_cloneOperation'](_0x4380d5,this['_diffRoots']))['oldRange']?_0x4380d5['oldRange']['root']:null,_0x43ead5=_0x4380d5['newRange']?_0x4380d5['newRange']['root']:null;_0x507414&&this['_markers']['delete'](_0x4380d5['name']),_0x43ead5&&this['_markers']['set'](_0x4380d5['name'],_0x4380d5['newRange']['clone']());const _0x15a80b=null===_0x4380d5['_authorId']?null:_0x4380d5['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x29d62f=_0x4380d5['name'];if(!this['_touchedMarkers']['has'](_0x29d62f))return void this['_touchedMarkers']['set'](_0x29d62f,{'range':_0x4380d5['oldRange'],'userId':_0x15a80b});const _0x111fee=this['_touchedMarkers']['get'](_0x29d62f),_0x4c67fe=_0x111fee['range'],_0x3bc34f=_0x4380d5['newRange'];null==_0x4c67fe&&null==_0x3bc34f||_0x4c67fe&&_0x3bc34f&&_0x4c67fe['isEqual'](_0x3bc34f)?this['_touchedMarkers']['delete'](_0x4380d5['name']):_0x111fee['userId']=_0x15a80b;}['_handleRootOperation'](_0xbd239a,_0xb2b633){this['_diffRoots']['has'](_0xbd239a['rootName'])?this['_diffRoots']['get'](_0xbd239a['rootName'])['_isAttached']=_0xbd239a['isAdd']:(this['_diffRoots']['set'](_0xbd239a['rootName'],P(_0xbd239a['rootName'],!0x0)),this['_diffRootsAttributes']['set'](_0xbd239a['rootName'],{}),_0xb2b633&&this['_idsRoots']['set'](_0xbd239a['rootName'],P(_0xbd239a['rootName'],!0x0)));const _0xe555e4=null===_0xbd239a['_authorId']?null:_0xbd239a['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x4810ed=this['_touchedRoots']['get'](_0xbd239a['rootName']);_0x4810ed&&_0x4810ed['userId']===_0xe555e4?this['_touchedRoots']['delete'](_0xbd239a['rootName']):this['_touchedRoots']['set'](_0xbd239a['rootName'],{'userId':_0xe555e4,'isAttached':_0xbd239a['isAdd']});}['_handleRootAttributeOperation'](_0x3c788d){const _0x13fe62=this['_diffRootsAttributes']['get'](_0x3c788d['root']['rootName']);null===_0x3c788d['newValue']?delete _0x13fe62[_0x3c788d['key']]:_0x13fe62[_0x3c788d['key']]=_0x3c788d['newValue'];}}function N(_0x2e37e1){const _0x27eeeb=P(_0x2e37e1['rootName'],_0x2e37e1['isAttached']());for(const _0x35ec92 of _0x2e37e1['getChildren']()){const _0x3d8a09=_0x35ec92['_clone'](!0x0);_0x27eeeb['_appendChild'](_0x3d8a09);}return _0x27eeeb;}function P(_0x4b4f6e,_0x1ed949=!0x0){const _0x1a2409=new vt();return _0x1a2409['rootName']=_0x4b4f6e,_0x1a2409['_isAttached']=_0x1ed949,_0x1a2409['isAttached']=()=>_0x1a2409['_isAttached'],_0x1a2409;}function F(_0x429edd,_0x3e4dca,_0x32d9b6){const _0x47ea9b='elementEnd'==_0x429edd['type']?_0x32d9b6['createPositionAt'](_0x429edd['item'],'end'):_0x32d9b6['createPositionBefore'](_0x429edd['item']);return _0x32d9b6['createPositionFromPath'](_0x3e4dca,_0x47ea9b['path'],_0x47ea9b['stickiness']);}function B(_0x69bade,_0x5c2a3b,_0x4d64cd){const _0x13dcc7='elementStart'==_0x69bade['type']?_0x4d64cd['createPositionAt'](_0x69bade['item'],0x0):_0x4d64cd['createPositionAfter'](_0x69bade['item']);return _0x4d64cd['createPositionFromPath'](_0x5c2a3b,_0x13dcc7['path'],_0x13dcc7['stickiness']);}class hs extends ts{['focusTracker'];['keystrokes'];['revisionNameInputView'];constructor(_0x239a14,_0x228da1){super(_0x239a14),this['focusTracker']=new _0x1abf6e(),this['keystrokes']=new _0x39fef4(),this['set']('revisionNameInputValue',''),this['revisionNameInputView']=this['_createRevisionNameInput'](_0x228da1),this['setTemplate']({'tag':'form','attributes':{'class':['ck','ck-revision-history-save-revision-form','ck-responsive-form'],'tabindex':'-1'},'children':[this['revisionNameInputView']]}),_0x57348d(this);}['render'](){super['render'](),_0x28ff76({'view':this}),this['focusTracker']['add'](this['revisionNameInputView']['element']),this['keystrokes']['listenTo'](this['element']);const _0x4ac9a7=_0x596911=>_0x596911['stopPropagation']();this['keystrokes']['set']('arrowright',_0x4ac9a7),this['keystrokes']['set']('arrowleft',_0x4ac9a7),this['keystrokes']['set']('arrowup',_0x4ac9a7),this['keystrokes']['set']('arrowdown',_0x4ac9a7);}['focus'](){this['revisionNameInputView']['focus']();}get['revisionName'](){return this['revisionNameInputView']['fieldView']['element']['value']['trim']();}set['revisionName'](_0x47dfc1){this['revisionNameInputView']['fieldView']['element']['value']=_0x47dfc1['trim']();}['reset'](){this['revisionNameInputView']['fieldView']['element']['value']='',this['revisionNameInputView']['errorText']=null;}['_createRevisionNameInput'](_0x2c9a78){const _0x502710=new _0x2be6a1(this['locale'],_0x22d3ee),_0x123cb4=_0x502710['fieldView'];_0x123cb4['extendTemplate']({'attributes':{'maxlength':'220'}});let _0x35f99b=g(this['locale'],'Name\x20of\x20the\x20revision');return!_0x2c9a78&&(_0x35f99b+='\x20('+g(this['locale'],'optional')+')'),(_0x502710['label']=_0x35f99b,_0x123cb4['on']('input',()=>{this['revisionNameInputValue']=_0x123cb4['element']['value']['trim']();}),_0x502710);}}class f extends _0x37aa98{static get['pluginName'](){return'RevisionHistoryUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[u];}['_saveRevisionFormView'];['init'](){const _0x10e9dd=this['editor'],_0x159524=_0x10e9dd['plugins']['get']('RevisionTracker');_0x10e9dd['ui']['componentFactory']['add']('revisionHistory',_0x105495=>{const _0x1e524d=_0x5d6b2b(_0x105495),_0x3d9c31=_0x1e524d['panelView']['children'],_0x207af3=new _0x42b4bf(_0x105495),_0x194e38=new _0x2b9608(_0x105495),_0x1c3bc0=new te(_0x105495),_0xd14a35=new _0x2b9608(_0x105495),_0x1d5886=new te(_0x105495);return _0x1e524d['bind']('isEnabled')['to'](_0x159524,'isReady',_0x159524,'isEnabled',_0x10e9dd,'isReadOnly',(_0x5385dd,_0x4ecee0,_0x176821)=>_0x5385dd&&_0x4ecee0&&!_0x176821),_0x1e524d['buttonView']['set']({'icon':_0x3acfa9,'label':g(_0x105495,'Revision\x20history'),'tooltip':!0x0}),_0x1c3bc0['set']({'label':g(_0x105495,'Save\x20current\x20revision'),'withText':!0x0,'role':'menuitem'}),_0x1c3bc0['bind']('isEnabled')['to'](_0x159524,'isReady',_0x159524,'isEnabled',_0x10e9dd,'isReadOnly',(_0x3f1e6a,_0x3e1107,_0x2174b8)=>_0x3f1e6a&&_0x3e1107&&!_0x2174b8),_0x1c3bc0['on']('execute',()=>this['_showDialog']()),_0x1d5886['set']({'label':g(_0x105495,'Open\x20revision\x20history'),'withText':!0x0,'role':'menuitem'}),_0x1d5886['bind']('isEnabled')['to'](_0x159524,'isReady',_0x10e9dd,'isReadOnly',(_0x5837b4,_0x20fcaa)=>_0x5837b4&&!_0x20fcaa),_0x1d5886['on']('execute',()=>{_0x10e9dd['config']['get']('revisionHistory')['showRevisionViewerCallback'](),_0x1e524d['isOpen']=!0x1,_0x10e9dd['editing']['view']['focus']();}),_0x194e38['children']['add'](_0x1c3bc0),_0xd14a35['children']['add'](_0x1d5886),_0x207af3['role']='menu',_0x207af3['items']['addMany']([_0x194e38,_0xd14a35]),_0x3d9c31['add'](_0x207af3),_0x1e524d;}),_0x10e9dd['ui']['componentFactory']['add']('menuBar:revisionHistory',()=>this['_registerMenuComponent']());}['_registerMenuComponent'](){const _0x3397b5=this['editor'],_0x1e1396=_0x3397b5['locale'],_0x65db73=new _0x30700f(_0x1e1396),_0x3c231c=new _0x106d90(_0x1e1396);_0x65db73['buttonView']['set']({'icon':_0x3acfa9,'label':g(_0x1e1396,'Revision\x20history')});const _0x2b999a=new _0x5c4104(_0x1e1396,_0x65db73),_0x1d0b89=new _0x51450e(_0x1e1396);_0x1d0b89['set']({'label':g(_0x1e1396,'Save\x20current\x20revision')}),_0x1d0b89['delegate']('execute')['to'](_0x65db73),_0x1d0b89['on']('execute',()=>{this['_showDialog']();}),_0x2b999a['children']['add'](_0x1d0b89),_0x3c231c['items']['add'](_0x2b999a);const _0x37703d=new _0x5c4104(_0x1e1396,_0x65db73),_0x158bd0=new _0x51450e(_0x1e1396);return _0x158bd0['set']({'label':g(_0x1e1396,'Open\x20revision\x20history')}),_0x158bd0['delegate']('execute')['to'](_0x65db73),_0x158bd0['on']('execute',()=>{_0x3397b5['config']['get']('revisionHistory')['showRevisionViewerCallback']();}),_0x37703d['children']['add'](_0x158bd0),_0x3c231c['items']['add'](_0x37703d),_0x65db73['panelView']['children']['add'](_0x3c231c),_0x65db73;}['_showDialog'](){const _0x1b4e50=this['editor'],_0x518386=_0x1b4e50['locale'],_0x59b344=_0x1b4e50['plugins']['get']('Dialog'),_0x208f71=_0x1b4e50['plugins']['get']('RevisionTracker');function _0x5b1583(_0x1a6aa7){_0x1b4e50['config']['get']('revisionHistory.requireRevisionName')&&''===_0x1a6aa7['revisionName']?_0x1a6aa7['revisionNameInputView']['errorText']=g(_0x518386,'The\x20revision\x20name\x20cannot\x20be\x20empty.'):(_0x1b4e50['plugins']['get'](u)['saveRevision']({'name':_0x1a6aa7['revisionName']}),_0x59b344['hide']());}this['_saveRevisionFormView']||(this['_createSaveRevisionFormView'](),this['_saveRevisionFormView']['on']('submit',()=>_0x5b1583(this['_saveRevisionFormView']))),this['_saveRevisionFormView']['reset'](),_0x59b344['show']({'id':'revisionSave','title':g(_0x518386,'Save\x20current\x20revision'),'isModal':!0x0,'content':this['_saveRevisionFormView'],'actionButtons':[{'label':g(_0x1b4e50['locale'],'Cancel'),'withText':!0x0,'onExecute':()=>_0x59b344['hide']()},{'label':g(_0x1b4e50['locale'],'Accept'),'class':'ck-button-action','withText':!0x0,'onCreate'(_0x3dd4d4){_0x3dd4d4['bind']('isEnabled')['to'](_0x208f71,'isReady',_0x208f71,'isEnabled',_0x1b4e50,'isReadOnly',(_0x5f0f1d,_0x1610d4,_0x2b30fa)=>_0x5f0f1d&&_0x1610d4&&!_0x2b30fa);},'onExecute':()=>_0x5b1583(this['_saveRevisionFormView'])}]});}['_createSaveRevisionFormView'](){const _0xe01e37=this['editor'],_0x189905=_0xe01e37['locale'];this['_saveRevisionFormView']=new hs(_0x189905,_0xe01e37['config']['get']('revisionHistory.requireRevisionName')),this['_saveRevisionFormView']['render']();}}class Q extends ts{['changeId'];['_model'];constructor(_0x313863,_0x1573c7){super(_0x313863),this['_model']=_0x1573c7,this['changeId']=_0x1573c7['id'];const _0x1df979=this['bindTemplate'],_0x459085=g(_0x313863,_0x1573c7['data']['isSuggestion']?'Suggested\x20by':'add'==_0x1573c7['type']?'Added\x20by':'Removed\x20by');this['set']('type',_0x1573c7['type']),this['setTemplate']({'tag':'div','attributes':{'class':['ck-annotation','ck-revision-change',_0x1df979['to']('type',_0x3d6e2a=>'ck-revision-change__'+_0x3d6e2a)],'tabindex':-0x1},'children':[{'tag':'span','children':[{'tag':'span','attributes':{'class':['ck-revision-change__label']},'children':[{'text':_0x459085}]},{'text':'\x20'+_0x1573c7['author']['name']}]}]});}['focus'](){this['element']['focus']();}}class r extends/* #__PURE__ -- @preserve */
|
|
25
|
+
_0x1fae21(){['id'];['author'];['type'];['data'];['rootName'];constructor(_0x1f6c60){super(),this['id']=_0x1f6c60['id']||_0x498586(),this['author']=_0x1f6c60['author'],this['type']=_0x1f6c60['type'],this['data']=_0x1f6c60['data']||{},this['rootName']=_0x1f6c60['rootName'],this['set']('createdAt',_0x1f6c60['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(_0x11dae5,_0x33f89f){this['newRevisionId']=_0x11dae5,this['oldRevisionId']=_0x33f89f,this['changes']=new _0x2a9213();}['_setChanges'](_0x14e9c3){for(const _0x551629 of _0x14e9c3)this['changes']['add'](_0x551629);}}class m extends _0x37aa98{['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[_0x3c957c,_0x400c5c,I,V];}constructor(_0x5cbce0){super(_0x5cbce0),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',(_0x2cf128,_0x2561e2,_0x49cde5)=>{this['activeChange']=null,this['activeView']=null,this['editor']['editing']['view']['change'](_0x100fd0=>{for(const _0x506703 of this['editor']['editing']['view']['document']['roots'])_0x49cde5?_0x100fd0['removeClass']('ck-editor__editable__overlay',_0x506703):_0x100fd0['addClass']('ck-editor__editable__overlay',_0x506703);});}),this['bind']('isNavigationMode')['to'](this,'activeChange',_0x784519=>null!==_0x784519),this['bind']('currentChangeNumber')['to'](this,'isReady',this,'diff',this,'activeChange',(_0x53f1fb,_0x2db385,_0x507efa)=>_0x53f1fb&&_0x507efa?_0x2db385['changes']['getIndex'](_0x507efa):0x0),this['bind']('numberOfChanges')['to'](this,'isReady',this,'diff',(_0x282a25,_0xb6f862)=>_0x282a25?_0xb6f862['changes']['length']:0x0),this['_changeView']=null,this['_changeIdToChange']=new Map(),this['_balloon']=this['editor']['plugins']['get'](_0x400c5c);}['init'](){const _0x8b86b8=this['editor'],_0x17e710=new wt(_0x8b86b8,{'direction':'backward'}),_0x44f06b=new wt(_0x8b86b8,{'direction':'forward'});(_0x8b86b8['commands']['add']('showPreviousChange',_0x17e710),_0x8b86b8['commands']['add']('showNextChange',_0x44f06b),_0x8b86b8['commands']['add']('restoreRevision',new mt(_0x8b86b8)),this['on']('change:numberOfChanges',()=>{_0x17e710['refresh'](),_0x44f06b['refresh']();}),this['_setConversion'](),this['_initInteractions'](),_0x8b86b8['enableReadOnlyMode']('revision-viewer'),_0x8b86b8['plugins']['has']('WidgetToolbarRepository'))&&_0x8b86b8['plugins']['get']('WidgetToolbarRepository')['forceDisabled']('revision-viewer');}async['getRevisionDocumentData'](_0x239ef6){return await this['_utils']['loadRevisionData'](_0x239ef6,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x239ef6);}async['getRevisionRootsAttributes'](_0x8ac952){return await this['_utils']['loadRevisionData'](_0x8ac952,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x8ac952);}async['compare'](_0x1940b2,_0x35f03c,_0x5734f3=!0x1){if(!this['isEnabled'])return;const _0x541868=this['diff'],_0x4ae760=this['repository'],_0x5ccb18='string'==typeof _0x1940b2?_0x4ae760['getRevision'](_0x1940b2):_0x1940b2,_0x36c2dc='string'==typeof _0x35f03c?_0x4ae760['getRevision'](_0x35f03c):_0x35f03c,_0x170974=_0x5ccb18['id'],_0x503775=_0x36c2dc?_0x36c2dc['id']:null;if(!_0x5734f3&&this['diff']&&this['diff']['newRevisionId']===_0x170974&&this['diff']['oldRevisionId']===_0x503775)return Promise['resolve']();this['isReady']=!0x1,this['activeView']=null,this['activeChange']=null,this['diff']=new c(_0x170974,_0x503775);const _0x17cc69=this['_getRevisionsRange'](_0x5ccb18,_0x36c2dc,!0x0)['map'](_0x31027f=>this['_utils']['loadRevisionData'](_0x31027f,this['adapter']));return _0x17cc69['push'](new Promise(_0x1ef2bc=>{setTimeout(_0x1ef2bc,0x14);})),Promise['all'](_0x17cc69)['then'](()=>{if(!this['isEnabled'])return;this['_cleanUp']();const _0x2d8f0d=this['_getDiff'](_0x170974,_0x503775);for(const _0x17162b of _0x2d8f0d['changes'])this['_changeIdToChange']['set'](_0x17162b['id'],_0x17162b);this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0xd1c8a2=>{for(const _0x4d862a of this['editor']['model']['document']['getRootNames']())_0xd1c8a2['detachRoot'](_0x4d862a);for(const _0x328957 of Object['keys'](_0x2d8f0d['model'])){const _0x24bea8=_0xd1c8a2['addRoot'](_0x328957);for(const _0x14251a of Object['keys'](_0x2d8f0d['attributes'][_0x328957]))_0xd1c8a2['setAttribute'](_0x14251a,_0x2d8f0d['attributes'][_0x328957][_0x14251a],_0x24bea8);_0xd1c8a2['insert'](_0x2d8f0d['model'][_0x328957],_0x24bea8,0x0);}}),this['diff']['_setChanges'](this['_sortAndFilterDiffChanges'](_0x2d8f0d['changes'])),this['isReady']=!0x0;})['catch'](_0x292bb5=>{console['error'](_0x292bb5),this['_cleanUp'](),_0x541868&&(this['diff']=_0x541868),this['isReady']=!0x0;});}['addRevisionData'](_0x56f130,_0x1bd1cd){const _0x253028=this['repository']['createRevision'](_0x56f130);return _0x253028['on']('_update',(_0x3e4fa9,_0x3c22fc,_0x247b62)=>_0x1bd1cd(_0x3c22fc,_0x247b62,_0x253028)),this['repository']['addRevision'](_0x253028),_0x253028;}['_cleanUp'](){this['activeChange']=null,this['_cleanMarkers'](),this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=null,this['_changeIdToChange']['clear'](),this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x5b7755=>{for(const _0x111182 of this['editor']['model']['document']['getRootNames']())_0x5b7755['detachRoot'](_0x111182);});}['_sortAndFilterDiffChanges'](_0x6af5b9){const _0x3855a4=[],_0x2fa098=new Map();for(const _0x286e66 of this['editor']['model']['document']['getRootNames']()){const _0x3089f2=this['editor']['editing']['view']['getDomRoot'](_0x286e66);if(!_0x3089f2)continue;const _0x5589c6=_0x3089f2['getClientRects']()['item'](0x0);_0x5589c6&&(_0x3855a4['push'](_0x286e66),_0x2fa098['set'](_0x286e66,_0x5589c6));}return _0x3855a4['sort']((_0xc01201,_0x160cdb)=>{const _0x5a8d8e=_0x2fa098['get'](_0xc01201),_0x520ea8=_0x2fa098['get'](_0x160cdb);return _0x5a8d8e['y']-_0x520ea8['y']||_0x5a8d8e['x']-_0x520ea8['x'];}),(_0x6af5b9=_0x6af5b9['filter'](_0x3af3cc=>_0x3855a4['includes'](_0x3af3cc['rootName'])))['sort']((_0x264979,_0x5a1f1c)=>_0x3855a4['indexOf'](_0x264979['rootName'])-_0x3855a4['indexOf'](_0x5a1f1c['rootName'])),_0x6af5b9;}['_makeTape'](_0x45f7d7){const _0x31895e=Array['from'](_0x45f7d7['markers'])['filter'](([_0x4f9580,_0x111211])=>_0x4f9580['startsWith']('revision:')&&!_0x111211['isCollapsed']),_0x5a7dad=Array['from'](this['editor']['model']['createRangeIn'](_0x45f7d7)['getWalker']({'singleCharacters':!0x0}));if(0x0!=_0x31895e['length'])for(const _0xbf4382 of _0x5a7dad){const [_0x313c31,_0x413cad]=_0x31895e[0x0],[,_0x5578d3,_0x56be26]=_0x313c31['split'](':');if(_0x413cad['end']['isEqual'](_0xbf4382['nextPosition'])&&_0x31895e['shift'](),(_0xbf4382['previousPosition']['isEqual'](_0x413cad['start'])||_0xbf4382['previousPosition']['isAfter'](_0x413cad['start']))&&('insertion'==_0x5578d3?_0xbf4382['isAdded']={'userId':_0x56be26}:'deletion'==_0x5578d3&&(_0xbf4382['isRemoved']={'userId':_0x56be26})),0x0==_0x31895e['length'])break;}return _0x5a7dad;}['_refreshStartEndIndex'](_0x35c515){const _0x463f9f=new Map();for(let _0x5dd9e4=0x0;_0x5dd9e4<_0x35c515['length'];_0x5dd9e4++)'text'===_0x35c515[_0x5dd9e4]['type']?(_0x35c515[_0x5dd9e4]['item']['startIndex']=_0x5dd9e4,_0x35c515[_0x5dd9e4]['item']['endIndex']=_0x5dd9e4):('elementStart'===_0x35c515[_0x5dd9e4]['type']?_0x35c515[_0x5dd9e4]['item']['startIndex']=_0x5dd9e4:'elementEnd'===_0x35c515[_0x5dd9e4]['type']&&(_0x35c515[_0x5dd9e4]['item']['endIndex']=_0x5dd9e4),_0x463f9f['set'](_0x35c515[_0x5dd9e4]['id'],_0x5dd9e4));for(const _0x553e50 of _0x463f9f['values']())'elementStart'===_0x35c515[_0x553e50]['type']?_0x35c515[_0x553e50]['item']['endIndex']=_0x463f9f['get'](_0x35c515[_0x553e50]['pairId']):'elementEnd'===_0x35c515[_0x553e50]['type']&&(_0x35c515[_0x553e50]['item']['startIndex']=_0x463f9f['get'](_0x35c515[_0x553e50]['pairId']));}['_processTape'](_0x60cb72){for(let _0x5cb65f=0x0;_0x5cb65f<_0x60cb72['length'];_0x5cb65f++){if('elementStart'===_0x60cb72[_0x5cb65f]['type'])_0x60cb72[_0x5cb65f]['item']['startIndex']=_0x5cb65f;else{if('elementEnd'===_0x60cb72[_0x5cb65f]['type']){_0x60cb72[_0x5cb65f]['item']['endIndex']=_0x5cb65f;const _0x41054b=_0x60cb72[_0x5cb65f]['item']['startIndex'];_0x60cb72[_0x41054b]['pairId']=_0x60cb72[_0x5cb65f]['id'],_0x60cb72[_0x5cb65f]['pairId']=_0x60cb72[_0x41054b]['id'];}else _0x60cb72[_0x5cb65f]['item']['startIndex']=_0x5cb65f,_0x60cb72[_0x5cb65f]['item']['endIndex']=_0x5cb65f,_0x60cb72[_0x5cb65f]['pairId']=null;}_0x60cb72[_0x5cb65f]['markersStart']||(_0x60cb72[_0x5cb65f]['markersStart']=[],_0x60cb72[_0x5cb65f]['markersEnd']=[]);}}['_markInsertions'](_0x7272d5,_0x52f720){const _0x5ec1cb=_0x7272d5['filter'](_0x338516=>!_0x338516['isAdded']);for(let _0x33753f=0x0;_0x33753f<_0x52f720['length'];_0x33753f++)_0x52f720[_0x33753f]['isAdded']&&(_0x5ec1cb[_0x33753f]['isAdded']=_0x52f720[_0x33753f]['isAdded']);}['_getDiff'](_0x30021,_0x50d9f9=null){const _0x47e4e3=this['repository']['getRevision'](_0x30021),_0x2d2ecb=_0x50d9f9?this['repository']['getRevision'](_0x50d9f9):null,_0x5aaec5=this['_getRevisionsRange'](_0x47e4e3,_0x2d2ecb),_0x19075c=_0x5aaec5[_0x5aaec5['length']-0x1],_0x5c531a=new Map(),_0x20e199={'model':{},'attributes':{},'changes':[]},_0x5a3908=new Set(),_0x3ee6bf=new Map();for(let _0x27dc26=_0x5aaec5['length']-0x1;_0x27dc26>=0x0;_0x27dc26--){const _0x4d9cb9=_0x5aaec5[_0x27dc26];for(const _0x4aba8f of Object['keys'](_0x4d9cb9['diffData']))if(_0x4d9cb9['diffData'][_0x4aba8f]['attachChange']){const _0xa7076c=_0x4d9cb9['diffData'][_0x4aba8f]['attachChange'];_0xa7076c['isAttached']?(_0x5a3908['add'](_0x4aba8f),_0x3ee6bf['has'](_0x4aba8f)&&_0x3ee6bf['get'](_0x4aba8f)['userId']==_0xa7076c['userId']?_0x3ee6bf['delete'](_0x4aba8f):_0x3ee6bf['set'](_0x4aba8f,_0xa7076c)):_0x3ee6bf['has'](_0x4aba8f)?(_0x5a3908['delete'](_0x4aba8f),_0x3ee6bf['delete'](_0x4aba8f)):(_0x5a3908['add'](_0x4aba8f),_0x3ee6bf['set'](_0x4aba8f,_0xa7076c));}else _0x5a3908['add'](_0x4aba8f);}for(const _0x3465aa of _0x5a3908){const _0x1fc07b=_0x3ee6bf['has'](_0x3465aa)&&!_0x3ee6bf['get'](_0x3465aa)['isAttached'];let _0x41ccba=_0x1fc07b?_0x5aaec5['length']-0x1:0x0;const _0x3ed9fa=_0x1fc07b?-0x1:0x1;for(;_0x5aaec5[_0x41ccba];){const _0x410252=_0x5aaec5[_0x41ccba];if(_0x410252['diffData'][_0x3465aa]){const _0x55147b=_0x1fc07b?_0x410252['diffData'][_0x3465aa]['attributesBefore']:_0x410252['diffData'][_0x3465aa]['attributesAfter'];_0x20e199['attributes'][_0x3465aa]=_0x55147b?_0x74c535(_0x55147b):{};break;}_0x41ccba+=_0x3ed9fa;}}for(const _0x285a72 of _0x5aaec5){_0x285a72['model']={};for(const _0x3b49c5 of _0x285a72['authors'])_0x5c531a['set'](_0x3b49c5['id'],_0x3b49c5);for(const _0x83c185 of _0x5a3908){const _0x4a9d4b=_0x285a72['diffData'][_0x83c185]?_0x285a72['diffData'][_0x83c185]['insertions']:'[]',_0x5e20f1=_0x285a72['diffData'][_0x83c185]?_0x285a72['diffData'][_0x83c185]['deletions']:'[]';_0x285a72['model'][_0x83c185]={'insertions':this['_utils']['_makeModelFromViewString'](_0x4a9d4b),'deletions':this['_utils']['_makeModelFromViewString'](_0x5e20f1)};}}for(const _0x50d49b of _0x5a3908){let _0x217134=null,_0x5ac8e0=0x0;const _0x21b71a=new Map(Array['from'](_0x47e4e3['model'][_0x50d49b]['insertions']['markers'])['filter'](([_0x9e22ad])=>!_0x9e22ad['startsWith']('revision:')));let _0x567a9b=0x0;for(const _0x317bc2 of _0x5aaec5){const _0x470103=this['_makeTape'](_0x317bc2['model'][_0x50d49b]['insertions']);_0x317bc2==_0x47e4e3?(_0x217134=_0x470103,_0x5ac8e0=_0x217134['length'],_0x217134['forEach'](_0x37164f=>{_0x37164f['id']=_0x567a9b++;}),this['_processTape'](_0x217134)):this['_markInsertions'](_0x217134,_0x470103);const _0x4cb473=_0x217134['filter'](_0x1ad117=>!_0x1ad117['isAdded'])['map'](_0x452988=>_0x452988['id']);let _0x31cedf=0x0;const _0xd27ed=this['_makeTape'](_0x317bc2['model'][_0x50d49b]['deletions']);_0xd27ed['forEach'](_0x367e63=>{_0x367e63['isRemoved']?_0x367e63['id']=_0x5ac8e0++:_0x367e63['id']=_0x4cb473[_0x31cedf++];}),this['_processTape'](_0xd27ed),this['_setDistance'](_0x217134,'isAdded'),this['_setDistance'](_0xd27ed,'isRemoved'),_0x317bc2==_0x47e4e3&&this['_markMarkers'](_0x217134,_0x21b71a),_0x217134=this['_joinTapes'](_0x217134,_0xd27ed),this['_refreshStartEndIndex'](_0x217134),this['_setDistance'](_0x217134,'isRemoved');}_0x217134=_0x217134['filter'](_0x5195d8=>!(_0x5195d8['isAdded']&&_0x5195d8['isRemoved']));const _0x4ced36=new Map(_0x19075c['model'][_0x50d49b]['deletions']['markers']),_0x4b8147=new Set(_0x21b71a['keys']());for(const _0x182b63 of _0x4ced36['keys']())_0x4b8147['delete'](_0x182b63);this['_markSuggestions'](_0x217134,_0x4b8147),this['_fixObsoleteTags'](_0x217134),_0x217134=this['_removeMissingPairs'](_0x217134),_0x217134=this['_markMismatchedRemovedTags'](_0x217134),_0x217134=this['_removeUnsupportedChanges'](_0x217134);const {root:_0x4741c2,changes:_0x22bada}=this['_makeModelFromTape'](_0x217134,_0x5c531a,_0x50d49b);_0x20e199['model'][_0x50d49b]=_0x4741c2;const _0x563aca=_0x3ee6bf['get'](_0x50d49b);if(_0x563aca){const _0x1d9852=_0x5c531a['get'](_0x563aca['userId']),_0x2bab56=new r({'author':_0x1d9852,'type':_0x563aca['isAttached']?'add':'remove','data':{'isOnRoot':!0x0},'createdAt':new Date(),'rootName':_0x50d49b});_0x22bada['unshift'](_0x2bab56),_0x20e199['attributes'][_0x50d49b]['revisionHistoryAttachChange']=_0x2bab56['id'];}_0x20e199['changes']=_0x20e199['changes']['concat'](_0x22bada);}return _0x20e199;}['_markMarkers'](_0x2fbb33,_0x15b7a8){for(let _0x250d73=0x0;_0x250d73<_0x2fbb33['length'];_0x250d73++)for(const [_0x5b3635,_0x37fb5a]of _0x15b7a8)!_0x37fb5a['isCollapsed']&&_0x37fb5a['start']['isEqual'](_0x2fbb33[_0x250d73]['previousPosition'])&&_0x2fbb33[_0x250d73]['markersStart']['push'](_0x5b3635),_0x37fb5a['end']['isEqual'](_0x2fbb33[_0x250d73]['nextPosition'])&&_0x2fbb33[_0x250d73]['markersEnd']['push'](_0x5b3635);}['_joinTapes'](_0x2ccecb,_0x57a619){let _0x4884b5=[],_0x442b24=0x0,_0x15888c=0x0;for(;_0x442b24<_0x2ccecb['length']||_0x15888c<_0x57a619['length'];){const _0x48d8ee=_0x2ccecb[_0x442b24]||{},_0x20bd1f=_0x57a619[_0x15888c]||{};if(_0x48d8ee['id']==_0x20bd1f['id'])_0x442b24++,_0x15888c++,_0x4884b5['push'](_0x48d8ee);else{if(_0x20bd1f['isRemoved']&&_0x48d8ee['isAdded']){const {commonTape:_0x39deac,iEnd:_0x57c2e1,jEnd:_0x4af538}=this['_threeWayMerge'](_0x2ccecb,_0x442b24,_0x57a619,_0x15888c);_0x4884b5=_0x4884b5['concat'](_0x39deac),_0x442b24=_0x57c2e1,_0x15888c=_0x4af538;}else _0x20bd1f['isRemoved']?(_0x15888c++,_0x4884b5['push'](_0x20bd1f)):(_0x442b24++,_0x4884b5['push'](_0x48d8ee));}}return _0x4884b5;}['_markSuggestions'](_0xf46c28,_0x37ce50){const _0x55028d=[];for(let _0x2fa409=0x0;_0x2fa409<_0xf46c28['length'];_0x2fa409++){for(let _0x7368cb=0x0;_0x7368cb<_0xf46c28[_0x2fa409]['markersStart']['length'];_0x7368cb++){const _0x33ad3e=_0xf46c28[_0x2fa409]['markersStart'][_0x7368cb];if(!_0x37ce50['has'](_0x33ad3e))continue;const {group:_0x367d3b,type:_0x63ea28,authorId:_0x2fcb38}=_0x419f76(_0x33ad3e);'revision-suggestion'!=_0x367d3b||'insertion'!=_0x63ea28&&'deletion'!=_0x63ea28||(_0x55028d['unshift']({'type':_0x63ea28,'name':_0x33ad3e,'userId':_0x2fcb38}),_0xf46c28[_0x2fa409]['markersStart']['splice'](_0x7368cb,0x1),_0x7368cb--);}_0x2b6fa2(_0xf46c28[_0x2fa409]);for(let _0x522a67=0x0;_0x522a67<_0xf46c28[_0x2fa409]['markersEnd']['length'];_0x522a67++){const _0x45ba55=_0xf46c28[_0x2fa409]['markersEnd'][_0x522a67];if(!_0x37ce50['has'](_0x45ba55))continue;const {group:_0x233456,type:_0x1f4a6f}=_0x419f76(_0x45ba55);if('revision-suggestion'!=_0x233456||'insertion'!=_0x1f4a6f&&'deletion'!=_0x1f4a6f)continue;_0xf46c28[_0x2fa409]['markersEnd']['splice'](_0x522a67,0x1),_0x522a67--;const _0x39f8d1=_0x55028d['findIndex'](_0x1ec539=>_0x1ec539['name']==_0x45ba55);_0x39f8d1>-0x1&&_0x55028d['splice'](_0x39f8d1,0x1);}}function _0x419f76(_0x2a230d){const _0x22d5dc=_0x2a230d['split'](':');return{'group':_0x22d5dc[0x0],'type':_0x22d5dc[0x1],'subType':_0x22d5dc['length']>=0x5?_0x22d5dc[0x2]:null,'id':_0x22d5dc['length']<0x5?_0x22d5dc[0x2]:_0x22d5dc[0x3],'authorId':_0x22d5dc['length']<0x5?_0x22d5dc[0x3]:_0x22d5dc[0x4],'markerCount':0x6==_0x22d5dc['length']?_0x22d5dc[0x5]:null};}function _0x2b6fa2(_0x3eb09b){for(let _0x139196=0x0;_0x139196<_0x55028d['length'];_0x139196++){if(_0x3eb09b['isAdded']&&'insertion'==_0x55028d[_0x139196]['type']&&_0x3eb09b['isAdded']['userId']==_0x55028d[_0x139196]['userId'])return _0x3eb09b['isAddSuggestion']=_0x55028d[_0x139196],void delete _0x3eb09b['isAdded'];if(!_0x3eb09b['isAdded']&&!_0x3eb09b['isRemoved']&&'deletion'==_0x55028d[_0x139196]['type'])return void(_0x3eb09b['isRemoveSuggestion']=_0x55028d[_0x139196]);}}}['_setDistance'](_0x5974d4,_0x4043c4){let _0x1978d9=0x0,_0x1740c1=!0x1;const _0x216f4d=new Map();for(const _0x22e22b of _0x5974d4)_0x22e22b[_0x4043c4]?_0x1740c1&&(_0x1978d9++,_0x1740c1=!0x1):(_0x1978d9++,_0x1740c1=!0x0),_0x216f4d['set'](_0x22e22b['id'],_0x1978d9);for(let _0x38e374=0x0;_0x38e374<_0x5974d4['length'];_0x38e374++){if('isRemoved'==_0x4043c4&&_0x5974d4[_0x38e374]['isAdded']||'isAdded'==_0x4043c4&&_0x5974d4[_0x38e374]['isRemoved'])continue;if('text'==_0x5974d4[_0x38e374]['type']){_0x5974d4[_0x38e374]['distance']=0x0;continue;}const _0x4dc2bd=_0x216f4d['get'](_0x5974d4[_0x38e374]['pairId']),_0x521435=_0x216f4d['get'](_0x5974d4[_0x38e374]['id']);_0x5974d4[_0x38e374]['distance']=_0x4dc2bd-_0x521435;}}['_getRevisionsRange'](_0xb7429,_0x2138e5,_0x3ee10b=!0x1){const _0x51d8b7=[];let _0x17174a=this['repository']['getIndex'](_0xb7429),_0x5d593c=this['repository']['getIndex'](_0x2138e5);for(-0x1==_0x5d593c&&(_0x5d593c=this['repository']['_revisions']['length'],_0x3ee10b=!0x1);_0x17174a<_0x5d593c;)_0x51d8b7['push'](this['repository']['getRevision'](_0x17174a)),_0x17174a++;return _0x3ee10b&&_0x51d8b7['push'](this['repository']['getRevision'](_0x17174a)),_0x51d8b7;}['_threeWayMerge'](_0x1104ad,_0x4e9e3e,_0x5013a7,_0x146872){const _0x22a619=this['editor']['model']['schema'];let _0x402ec5=_0x4e9e3e;for(;_0x1104ad[_0x402ec5]&&_0x1104ad[_0x402ec5]['isAdded'];)_0x402ec5++;let _0x2da434=_0x146872;for(;_0x5013a7[_0x2da434]&&_0x5013a7[_0x2da434]['isRemoved'];)_0x2da434++;_0x4797b7(_0x1104ad,_0x4e9e3e,_0x402ec5),_0x4797b7(_0x5013a7,_0x146872,_0x2da434);const _0x1ec16c=_0x5013a7['slice'](_0x146872,_0x2da434)['concat'](_0x1104ad['slice'](_0x4e9e3e,_0x402ec5));return _0x1ec16c['sort']((_0x262a78,_0x2aa107)=>_0x262a78['side']!=_0x2aa107['side']?_0x262a78['side']-_0x2aa107['side']:_0x262a78['level']!=_0x2aa107['level']?_0x262a78['level']-_0x2aa107['level']:_0x262a78['distance']!=_0x2aa107['distance']?_0x2aa107['distance']-_0x262a78['distance']:!!_0x262a78['isAdded']!=!!_0x2aa107['isAdded']?-0x1==_0x262a78['side']||0x0==_0x262a78['side']?_0x262a78['isAdded']?-0x1:0x1:_0x262a78['isAdded']?0x1:-0x1:_0x262a78['index']-_0x2aa107['index']),{'commonTape':_0x1ec16c,'iEnd':_0x402ec5,'jEnd':_0x2da434};function _0x4797b7(_0x574d18,_0x235116,_0x418c61){let _0x323656=-0x1,_0x3db268=Number['POSITIVE_INFINITY'],_0x5d5fc5=!0x0;for(let _0x351932=_0x235116;_0x351932<_0x418c61;_0x351932++)if(_0x22a619['isInline'](_0x574d18[_0x351932]['item'])||(_0x5d5fc5=!0x1),_0x574d18[_0x351932]['item']['startIndex']<_0x235116&&(_0x323656=_0x351932),_0x574d18[_0x351932]['item']['endIndex']>=_0x418c61){_0x3db268=_0x351932;break;}_0x5d5fc5&&(_0x323656=_0x418c61-0x1);for(let _0x5a70ec=_0x235116;_0x5a70ec<_0x418c61;_0x5a70ec++)_0x574d18[_0x5a70ec]['side']=_0x5a70ec<=_0x323656?-0x1:_0x5a70ec<_0x3db268?0x0:0x1,_0x574d18[_0x5a70ec]['index']=_0x5a70ec;let _0x2b7033=0x0;for(let _0x195f6f=_0x235116;_0x195f6f<=_0x323656;_0x195f6f++)0x0==_0x574d18[_0x195f6f]['distance']?_0x574d18[_0x195f6f]['level']=_0x2b7033:(_0x2b7033++,_0x574d18[_0x195f6f]['level']=_0x2b7033,_0x2b7033++);for(let _0xce1e79=_0x235116;_0xce1e79<_0x418c61;_0xce1e79++)0x0==_0x574d18[_0xce1e79]['side']&&(_0x574d18[_0xce1e79]['level']=_0x2b7033);_0x2b7033=0x0;for(let _0x37f97e=_0x418c61-0x1;_0x37f97e>=_0x3db268;_0x37f97e--)0x0==_0x574d18[_0x37f97e]['distance']?_0x574d18[_0x37f97e]['level']=_0x2b7033:(_0x2b7033--,_0x574d18[_0x37f97e]['level']=_0x2b7033,_0x2b7033--);}}['_fixObsoleteTags'](_0x4338c2){const _0xcebbe7=new Map(),_0x50cd85=this['editor']['model']['schema'];for(let _0x19b1ff=0x1;_0x19b1ff<_0x4338c2['length'];_0x19b1ff++){let _0x100e95,_0x38ab15,_0x17535c;const _0x25764a=_0x4338c2[_0x19b1ff],_0x3b23c4=_0x4338c2[_0x19b1ff-0x1];if('text'==_0x25764a['type'])continue;if(_0x25764a['type']!=_0x3b23c4['type'])continue;if(!_0x50cd85['isBlock'](_0x3b23c4['item'])||_0x50cd85['isLimit'](_0x3b23c4['item']))continue;if(!_0x50cd85['isBlock'](_0x25764a['item'])||_0x50cd85['isLimit'](_0x25764a['item']))continue;if((_0x4338c2[_0x19b1ff]['isAdded']||_0x4338c2[_0x19b1ff]['isAddSuggestion'])&&_0x4338c2[_0x19b1ff-0x1]['isRemoved'])_0x100e95=_0x4338c2[_0x19b1ff],_0x38ab15=_0x4338c2[_0x19b1ff-0x1],_0x17535c=_0x19b1ff-0x1;else{if(!_0x4338c2[_0x19b1ff]['isRemoved']||!_0x4338c2[_0x19b1ff-0x1]['isAdded']&&!_0x4338c2[_0x19b1ff-0x1]['isAddSuggestion'])continue;_0x100e95=_0x4338c2[_0x19b1ff-0x1],_0x38ab15=_0x4338c2[_0x19b1ff],_0x17535c=_0x19b1ff;}const _0xf0d700=_0x100e95['level']==_0x38ab15['level'],_0x4e749e=Math['abs'](_0x100e95['level'])<Math['abs'](_0x38ab15['level'])&&0x0==_0x38ab15['distance'];(_0xf0d700||_0x4e749e)&&(_0xcebbe7['set'](_0x38ab15['id'],_0x100e95['id']),_0x4338c2['splice'](_0x17535c,0x1),_0x19b1ff--,_0x100e95['isAdded']=!0x1);}for(let _0x3ff177=0x0;_0x3ff177<_0x4338c2['length'];_0x3ff177++)_0xcebbe7['has'](_0x4338c2[_0x3ff177]['pairId'])&&(_0x4338c2[_0x3ff177]['pairId']=_0xcebbe7['get'](_0x4338c2[_0x3ff177]['pairId']));}['_removeMissingPairs'](_0x130538){const _0x2be2b1=new Set(_0x130538['map'](_0x44fa8b=>_0x44fa8b['id']));for(let _0x33ac20=0x0;_0x33ac20<_0x130538['length'];_0x33ac20++)_0x2be2b1['has'](_0x130538[_0x33ac20]['pairId'])||0x0==_0x130538[_0x33ac20]['distance']||(_0x130538[_0x33ac20]['isIncorrect']=!0x0);return _0x130538['filter'](_0x32e741=>!_0x32e741['isIncorrect']);}['_markMismatchedRemovedTags'](_0x4a6cea){const _0x4b2dd3=new Set();for(let _0x20f806=0x0;_0x20f806<_0x4a6cea['length'];_0x20f806++){if(_0x4b2dd3['has'](_0x4a6cea[_0x20f806]['id'])&&_0x4a6cea[_0x20f806]['isRemoved']&&(_0x4a6cea[_0x20f806]['isIncorrect']=!0x0),_0x4a6cea[_0x20f806]['isIncorrect'])continue;if(0x0==_0x4a6cea[_0x20f806]['distance'])continue;if('elementStart'!=_0x4a6cea[_0x20f806]['type'])continue;if(null==_0x4a6cea[_0x20f806]['pairId'])continue;let _0x4a2099=_0x20f806+0x1,_0x2d5e91=0x0;for(;_0x4a6cea[_0x4a2099]['id']!=_0x4a6cea[_0x20f806]['pairId'];)'elementStart'==_0x4a6cea[_0x4a2099]['type']?_0x2d5e91++:'elementEnd'==_0x4a6cea[_0x4a2099]['type']&&_0x2d5e91--,_0x4a2099++;if(0x0!=_0x2d5e91){if(_0x4a6cea[_0x20f806]['isRemoved'])_0x4a6cea[_0x20f806]['isIncorrect']=!0x0;else{for(;_0x4a2099!=_0x20f806;)_0x4a6cea[_0x4a2099]['isRemoved']&&0x0!=_0x4a6cea[_0x4a2099]['distance']&&(_0x4a6cea[_0x4a2099]['isIncorrect']=!0x0,_0x4b2dd3['add'](_0x4a6cea[_0x4a2099]['pairId'])),_0x4a2099--;}}}return _0x4a6cea['filter'](_0x14402a=>!_0x14402a['isIncorrect']);}['_removeUnsupportedChanges'](_0x182674){const _0x3fb84a=this['editor']['model']['schema'];for(let _0x365393=0x0;_0x365393<_0x182674['length'];_0x365393++){if(!(_0x182674[_0x365393]['isAdded']||_0x182674[_0x365393]['isAddSuggestion']||_0x182674[_0x365393]['isRemoved']||_0x182674[_0x365393]['isRemoveSuggestion']))continue;if(0x0==_0x182674[_0x365393]['distance'])continue;const _0x34cd23=_0x182674[_0x365393]['item'];_0x3fb84a['isBlock'](_0x34cd23)||_0x3fb84a['isLimit'](_0x34cd23)||(_0x182674[_0x365393]['isAdded']&&delete _0x182674[_0x365393]['isAdded'],_0x182674[_0x365393]['isAddSuggestion']&&delete _0x182674[_0x365393]['isAddSuggestion'],_0x182674[_0x365393]['isRemoveSuggestion']&&delete _0x182674[_0x365393]['isRemoveSuggestion'],_0x182674[_0x365393]['isRemoved']&&(_0x182674[_0x365393]['isIncorrect']=!0x0));}return _0x182674['filter'](_0x17a0df=>!_0x17a0df['isIncorrect']);}['_makeModelFromTape'](_0x27c45a,_0x2a455d,_0x1c66bc){const _0x3a5829=new vt(),_0x476fcd=[],_0x52d8da=new Map(),_0x26fb5b=this['editor']['model'],_0x27bc39=_0x26fb5b['schema'],_0x580592=[_0x3a5829],_0x5bd525={},_0x15f430={'isAdded':[],'isRemoved':[],'isAddSuggestion':[],'isRemoveSuggestion':[]};let _0x423199=null;const _0x3dda82=[0x0];for(let _0x2b5395=0x0;_0x2b5395<_0x27c45a['length'];_0x2b5395++)if('elementStart'===_0x27c45a[_0x2b5395]['type']){_0x27c45a[_0x2b5395]['previousPosition']=_0x26fb5b['createPositionFromPath'](_0x3a5829,_0x3dda82);const _0x292593=new ut(_0x27c45a[_0x2b5395]['item']['name'],_0x27c45a[_0x2b5395]['item']['getAttributes']());_0x580592[0x0]['_appendChild'](_0x292593),_0x3dda82['push'](0x0),_0x580592['unshift'](_0x292593),_0x27c45a[_0x2b5395]['nextPosition']=_0x26fb5b['createPositionFromPath'](_0x3a5829,_0x3dda82);}else'elementEnd'===_0x27c45a[_0x2b5395]['type']?(_0x580592['shift'](),_0x27c45a[_0x2b5395]['previousPosition']=_0x26fb5b['createPositionFromPath'](_0x3a5829,_0x3dda82),_0x3dda82['pop'](),_0x3dda82[_0x3dda82['length']-0x1]++,_0x27c45a[_0x2b5395]['nextPosition']=_0x26fb5b['createPositionFromPath'](_0x3a5829,_0x3dda82)):(_0x27c45a[_0x2b5395]['previousPosition']=_0x26fb5b['createPositionFromPath'](_0x3a5829,_0x3dda82),_0x423199?_0x423199['_data']+=_0x27c45a[_0x2b5395]['item']['data']:_0x423199=new gt(_0x27c45a[_0x2b5395]['item']['data'],_0x27c45a[_0x2b5395]['item']['getAttributes']()),_0x27c45a[_0x2b5395+0x1]&&'text'===_0x27c45a[_0x2b5395+0x1]['type']&&_0x143d03(_0x423199,_0x27c45a[_0x2b5395+0x1]['item'])||(_0x580592[0x0]['_appendChild'](_0x423199),_0x423199=null),_0x3dda82[_0x3dda82['length']-0x1]+=_0x27c45a[_0x2b5395]['item']['offsetSize'],_0x27c45a[_0x2b5395]['nextPosition']=_0x26fb5b['createPositionFromPath'](_0x3a5829,_0x3dda82));for(let _0x57f514=0x0;_0x57f514<_0x27c45a['length'];_0x57f514++){const _0x4d83b8=_0x27c45a[_0x57f514]['previousPosition'],_0x13b251=_0x27c45a[_0x57f514]['nextPosition'];for(const _0x4d85bd of _0x27c45a[_0x57f514]['markersStart'])_0x52d8da['set'](_0x4d85bd,{'start':_0x4d83b8,'end':null});_0x3cb23f('isRemoveSuggestion',_0x57f514,_0x4d83b8,_0x13b251),_0x3cb23f('isAddSuggestion',_0x57f514,_0x4d83b8,_0x13b251),_0x3cb23f('isRemoved',_0x57f514,_0x4d83b8,_0x13b251),_0x3cb23f('isAdded',_0x57f514,_0x4d83b8,_0x13b251);for(const _0x313dbe of _0x27c45a[_0x57f514]['markersEnd']){const _0x1a942e=_0x52d8da['get'](_0x313dbe);_0x1a942e?_0x1a942e['end']=_0x13b251:_0x52d8da['set'](_0x313dbe,{'start':_0x13b251,'end':_0x13b251});}}for(const [_0x1da9fa,_0x649b9d]of _0x52d8da){const _0x56511e=this['editor']['model']['createRange'](_0x649b9d['start'],_0x649b9d['end']);_0x3a5829['markers']['set'](_0x1da9fa,_0x56511e);}return _0x476fcd['sort']((_0x28f0c4,_0x2ff3f9)=>{const _0x42aca3=_0x3a5829['markers']['get']('revision:'+_0x28f0c4['id']),_0x7578d5=_0x3a5829['markers']['get']('revision:'+_0x2ff3f9['id']);return _0x42aca3['start']['isBefore'](_0x7578d5['start'])?-0x1:_0x42aca3['start']['isAfter'](_0x7578d5['start'])?0x1:_0x42aca3['end']['isBefore'](_0x7578d5['end'])?-0x1:_0x42aca3['end']['isAfter'](_0x7578d5['end'])?0x1:'add'===_0x28f0c4['type']?-0x1:0x1;}),{'root':_0x3a5829,'changes':_0x476fcd};function _0x3cb23f(_0x4fae9c,_0x5e1290,_0x464a2c,_0x4e3707){const _0x3878ed=!!_0x27c45a[_0x5e1290][_0x4fae9c],_0x465487=_0x3878ed?_0x27c45a[_0x5e1290][_0x4fae9c]['userId']:null,_0xc61da6=_0x5e1290===_0x27c45a['length']-0x1,_0x2ddaf5=_0x15f430[_0x4fae9c][0x0],_0x52972a=_0x27bc39['isObject'](_0x27c45a[_0x5e1290]['item']);!_0x5bd525[_0x4fae9c]&&_0x3878ed?_0x5bd525[_0x4fae9c]={'start':_0x464a2c,'tapeItem':_0x27c45a[_0x5e1290],'userId':_0x465487,'type':_0x4fae9c}:_0x5bd525[_0x4fae9c]&&!_0x3878ed?(_0x5bd525[_0x4fae9c]['end']=_0x464a2c,_0xa503b9(_0x5bd525[_0x4fae9c]),_0x5bd525[_0x4fae9c]=null):_0x5bd525[_0x4fae9c]&&_0x3878ed&&_0x5bd525[_0x4fae9c]['userId']!==_0x465487&&(_0x5bd525[_0x4fae9c]['end']=_0x464a2c,_0x2ddaf5&&_0x2ddaf5['userId']===_0x5bd525[_0x4fae9c]['userId']||_0xa503b9(_0x5bd525[_0x4fae9c]),_0x5bd525[_0x4fae9c]={'start':_0x464a2c,'tapeItem':_0x27c45a[_0x5e1290],'userId':_0x465487,'type':_0x4fae9c}),_0x5bd525[_0x4fae9c]&&_0x52972a&&('elementStart'!==_0x27c45a[_0x5e1290]['type']||_0x2ddaf5&&_0x2ddaf5['userId']===_0x465487||_0x15f430[_0x4fae9c]['unshift']({'userId':_0x465487,'object':_0x27c45a[_0x5e1290]['item'],'change':_0x5bd525[_0x4fae9c]}),'elementEnd'===_0x27c45a[_0x5e1290]['type']&&_0x2ddaf5&&_0x2ddaf5['object']===_0x27c45a[_0x5e1290]['item']&&(_0x15f430[_0x4fae9c]['shift'](),_0x5bd525[_0x4fae9c]=_0x2ddaf5['change'])),_0x5bd525[_0x4fae9c]&&_0xc61da6&&(_0x5bd525[_0x4fae9c]['end']=_0x4e3707,_0xa503b9(_0x5bd525[_0x4fae9c]),_0x5bd525[_0x4fae9c]=null);}function _0xa503b9({start:_0x15133b,end:_0x5c5041,tapeItem:_0x38d742,userId:_0x51ac27,type:_0x3a6c3e}){const _0x1ac036=_0x38d742['item'],_0x2e1eb9=_0x26fb5b['schema']['isBlock'](_0x1ac036)&&!_0x26fb5b['schema']['isLimit'](_0x1ac036),_0x2378c3=_0x15133b['nodeAfter']==_0x5c5041['parent']&&_0x5c5041['isAtStart'];if(_0x2e1eb9&&_0x2378c3)return;const _0x384fd4=_0x26fb5b['createRange'](_0x15133b,_0x5c5041),_0xf32aa7=_0x2a455d['get'](_0x51ac27),_0x1b234f=new r({'author':_0xf32aa7,'type':'isAdded'==_0x3a6c3e||'isAddSuggestion'==_0x3a6c3e?'add':'remove','data':{'isSuggestion':'isAddSuggestion'==_0x3a6c3e||'isRemoveSuggestion'==_0x3a6c3e},'createdAt':new Date(),'rootName':_0x1c66bc});_0x476fcd['push'](_0x1b234f),_0x3a5829['markers']['set']('revision:'+_0x1b234f['id'],_0x384fd4);}function _0x143d03(_0x528b2f,_0x594ae2){const _0x19a16a=_0x528b2f['getAttributes'](),_0x138849=_0x594ae2['getAttributes']();for(const _0x152a47 of _0x19a16a){if(_0x152a47[0x1]!==_0x594ae2['getAttribute'](_0x152a47[0x0]))return!0x1;_0x138849['next']();}return _0x138849['next']()['done'];}}['_setConversion'](){this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision','view':_0xe60bca=>{const _0x37c09a=_0xe60bca['markerName']['split'](':')[0x1],_0x6bebc5=this['_getChangeFromId'](_0x37c09a);if(!_0x6bebc5)return null;const _0x48928d='add'==_0x6bebc5['type']?'insertion':'deletion',_0x3214d2=['ck-suggestion-marker','ck-suggestion-marker-'+_0x48928d];return _0x6bebc5['data']['isSuggestion']&&_0x3214d2['push']('ck-suggestion-marker-'+_0x48928d+'-new'),this['activeChange']==_0x6bebc5&&_0x3214d2['push']('ck-suggestion-marker--active'),{'classes':_0x3214d2,'attributes':{'data-change-id':_0x37c09a}};}}),this['editor']['conversion']['for']('upcast')['add'](_0x231a60=>{_0x231a60['on']('element:pre',(_0x30bc11,_0xc34ec7,_0x10d9e6)=>{const _0x182e61=_0xc34ec7['viewItem']['getChild'](0x0);if(!_0x182e61||!_0x182e61['is']('element','code'))return;if(!_0x10d9e6['consumable']['consume'](_0x182e61,{'attributes':['vid_start','vid_end']}))return;const _0x4c2e16=_0xc34ec7['modelRange']['start']['nodeAfter'];_0x10d9e6['writer']['setAttribute']('vid_start',_0x182e61['getAttribute']('vid_start'),_0x4c2e16),_0x10d9e6['writer']['setAttribute']('vid_end',_0x182e61['getAttribute']('vid_end'),_0x4c2e16);},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['add'](_0x48deca=>{_0x48deca['on']('element',(_0x3e5b3c,_0x41d360,_0x2589c8)=>{if(!_0x2589c8['consumable']['consume'](_0x41d360['viewItem'],{'attributes':['vid_start','vid_end']}))return;if(_0x41d360['modelRange']['isCollapsed'])return;const _0x2108d1=_0x41d360['modelRange']['start']['nodeAfter'];_0x2108d1['hasAttribute']('vid_start')||_0x2108d1['hasAttribute']('vid')||(_0x2589c8['writer']['setAttribute']('vid_start',_0x41d360['viewItem']['getAttribute']('vid_start'),_0x2108d1),_0x2589c8['writer']['setAttribute']('vid_end',_0x41d360['viewItem']['getAttribute']('vid_end'),_0x2108d1));},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['elementToAttribute']({'view':{'name':'span','attributes':{'vid':!0x0}},'model':{'key':'vid','value':_0x57e7f7=>_0x57e7f7['getAttribute']('vid')}}),this['editor']['model']['schema']['on']('checkAttribute',(_0x1b5f38,[,_0x31945f])=>{['vid_start','vid_end','vid']['includes'](_0x31945f)&&(_0x1b5f38['return']=!0x0,_0x1b5f38['stop']());},{'priority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x3636ea=>{_0x3636ea['on']('attribute:vid',(_0x24ab16,_0x2125c4,_0x158e31)=>{if('\x20'!=_0x2125c4['item']['data']||_0x2125c4['item']['parent']['maxOffset']>0x1)return;if(!_0x158e31['consumable']['consume'](_0x2125c4['item'],_0x24ab16['name']))return;const _0x390abf=_0x158e31['writer'],_0x199aa1=_0x158e31['mapper']['toViewRange'](_0x2125c4['range']);_0x390abf['wrap'](_0x199aa1,_0x390abf['createAttributeElement']('span'));});}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',function(_0x3f0e68){const _0x2b3e16=_0x3f0e68['plugins']['get']('RevisionViewer');return(_0xe6683c,_0x141538,_0x6d3104)=>{const _0x4cfbfd=_0x141538['markerName']['split'](':')[0x1],_0x26c1b1=_0x2b3e16['_getChangeFromId'](_0x4cfbfd);if(!_0x26c1b1)return null;const _0x1c7890='add'==_0x26c1b1['type']?'split':'merge';if(!_0x6d3104['consumable']['test'](_0x141538['markerRange'],_0xe6683c['name']))return;const _0x10091d=_0x141538['markerRange']['getWalker'](),_0x74f616=_0x141538['markerRange']['start'],_0x34615b=_0x3f0e68['model']['schema'];let _0x474b33=null,_0x370d7d=null,_0x2c2c6e=!0x1,_0x5da068=!0x1;for(const _0x57b38b of _0x10091d){const _0x158fe1=_0x57b38b['item'];_0x2c2c6e=_0x2c2c6e||_0x34615b['isContent'](_0x158fe1);const _0x1974cd=_0x6d3104['mapper']['toViewElement'](_0x158fe1);if(_0x1974cd&&_0x1974cd['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x57b38b['type']&&(_0x34615b['isBlock'](_0x158fe1)&&!_0x34615b['isLimit'](_0x158fe1)&&(_0x158fe1['nextSibling']||_0x74f616['isAtEnd']?_0x474b33&&_0x474b33['parent']==_0x158fe1||(_0x474b33=_0x158fe1,_0x5e6580(_0x57b38b['previousPosition']),_0x5da068=!0x0):_0x370d7d=_0x370d7d||_0x57b38b['previousPosition']));}function _0x5e6580(_0x1a54ae){const _0x31222c=_0x6d3104['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x1c7890}),_0x525454=_0x6d3104['mapper']['toViewPosition'](_0x1a54ae);_0x26c1b1['data']['isSuggestion']&&_0x6d3104['writer']['addClass']('ck-suggestion-marker-'+_0x1c7890+'-new',_0x31222c),_0x2b3e16['activeChange']==_0x26c1b1&&_0x6d3104['writer']['addClass']('ck-suggestion-marker--active',_0x31222c),_0x6d3104['writer']['insert'](_0x525454,_0x31222c),_0x6d3104['mapper']['bindElementToMarker'](_0x31222c,_0x141538['markerName']);}_0x2c2c6e||_0x5da068||!_0x370d7d||_0x5e6580(_0x370d7d);};}(this['editor']),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision',(_0x9c6c72,_0x5212eb,_0x5aaecc)=>{const _0x24214e=_0x5aaecc['mapper']['markerNameToElements'](_0x5212eb['markerName']);if(_0x24214e){for(const _0x15e491 of _0x24214e)(_0x15e491['hasClass']('ck-suggestion-marker-split')||_0x15e491['hasClass']('ck-suggestion-marker-merge'))&&(_0x5aaecc['mapper']['unbindElementFromMarkerName'](_0x15e491,_0x5212eb['markerName']),_0x5aaecc['writer']['remove'](_0x15e491));}},{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',(_0x9fccc4,_0x4ed113,_0x20001e)=>{const _0x22f331=_0x4ed113['markerName']['split'](':')[0x1],_0x211f13=this['_getChangeFromId'](_0x22f331);if(!_0x211f13)return null;const _0x1c17ca='add'==_0x211f13['type']?'split':'merge';if(_0x20001e['consumable']['test'](_0x4ed113['markerRange'],_0x9fccc4['name']))for(const _0x48f6ea of _0x4ed113['markerRange']['getItems']()){if(!_0x48f6ea['is']('element','softBreak'))continue;const _0x201aeb=_0x20001e['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x1c17ca}),_0x58f5a3=_0x20001e['mapper']['toViewPosition'](this['editor']['model']['createPositionBefore'](_0x48f6ea));_0x211f13['data']['isSuggestion']&&_0x20001e['writer']['addClass']('ck-suggestion-marker-'+_0x1c17ca+'-new',_0x201aeb),this['activeChange']==_0x211f13&&_0x20001e['writer']['addClass']('ck-suggestion-marker--active',_0x201aeb),_0x20001e['writer']['insert'](_0x58f5a3,_0x201aeb),_0x20001e['mapper']['bindElementToMarker'](_0x201aeb,_0x4ed113['markerName']);}},{'priority':'high'}),this['editor']['model']['document']['on']('change',()=>{this['editor']['editing']['view']['change'](_0xacedb3=>{for(const _0x187e6b of this['editor']['model']['document']['getRootNames']()){const _0x420b38=this['editor']['model']['document']['getRoot'](_0x187e6b),_0x52362a=this['editor']['editing']['view']['document']['getRoot'](_0x187e6b);if(_0x52362a){const _0x108642=_0x420b38['getAttribute']('revisionHistoryAttachChange');if(_0xacedb3['removeAttribute']('data-change-id',_0x52362a),_0xacedb3['removeClass']('ck-revision-history-root-add',_0x52362a),_0xacedb3['removeClass']('ck-revision-history-root-remove',_0x52362a),_0xacedb3['removeClass']('ck-revision-history-root--active',_0x52362a),_0x108642){const _0x123f98=this['_getChangeFromId'](_0x108642);if(!_0x123f98)return null;_0xacedb3['setAttribute']('data-change-id',_0x108642,_0x52362a),_0xacedb3['addClass']('ck-revision-history-root-'+_0x123f98['type'],_0x52362a),this['activeChange']==_0x123f98&&_0xacedb3['addClass']('ck-revision-history-root--active',_0x52362a);}}}});}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'comment','model':_0x421247=>'revision-comment:'+_0x421247,'converterPriority':'highest'}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'suggestion','model':_0x33d8cf=>'revision-suggestion:'+_0x33d8cf,'converterPriority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision-suggestion','view':_0x2507d5=>({'name':'suggestion:'+_0x2507d5,'group':'revision-suggestion'}),'converterPriority':'highest'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision-suggestion','view':_0x52e949=>{const _0x2cc2fa=_0x52e949['markerName']['split'](':')[0x1];return'insertion'!=_0x2cc2fa&&'deletion'!=_0x2cc2fa?null:{'classes':['ck-suggestion-preview-marker','ck-suggestion-preview-marker-'+_0x2cc2fa]};}}),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',(_0xbc36e8,_0x5e6742,_0x1e2d1f)=>{const _0x52e28c=_0x1e2d1f['mapper']['markerNameToElements'](_0x5e6742['markerName']);if(_0x52e28c){for(const _0x27ebe9 of _0x52e28c)_0x27ebe9['is']('uiElement')&&(_0x1e2d1f['mapper']['unbindElementFromMarkerName'](_0x27ebe9,_0x5e6742['markerName']),_0x1e2d1f['writer']['remove'](_0x27ebe9));}},{'priority':'high'});}['_getChangeFromId'](_0xb954aa){return this['_changeIdToChange']['get'](_0xb954aa);}['_getViewForChange'](_0x370a79){return this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=new Q(this['editor']['locale'],_0x370a79),this['_changeView'];}['_initInteractions'](){this['editor']['model']['document']['selection']['observeMarkers']('revision'),this['on']('change:activeView',(_0x2c0d41,_0xac2a20,_0x47e8ed,_0x5be253)=>{_0x5be253&&this['_balloon']['remove'](_0x5be253),_0x47e8ed&&(this['_balloon']['add']({'view':_0x47e8ed,'stackId':'revisionHistoryLabel','position':{'target':()=>{const _0x292626=this['editor']['editing'],_0x438897=this['_getChangeFromId'](_0x47e8ed['changeId']);let _0x2fa101;if(_0x438897['data']['isOnRoot']){const _0x7c0e4d=_0x292626['view']['getDomRoot'](_0x438897['rootName']);_0x2fa101=Array['from'](_0x7c0e4d['getClientRects']());}else{const _0x1e1b82=this['editor']['model']['markers']['get']('revision:'+_0x47e8ed['changeId']);_0x2fa101=Array['from'](_0x292626['mapper']['markerNameToElements'](_0x1e1b82['name']))['map'](_0x3a3575=>_0x292626['view']['domConverter']['mapViewToDom'](_0x3a3575))['map'](_0x140856=>Array['from'](_0x140856['getClientRects']()))['flat']();}if(!this['_activeViewTarget'])return _0x2fa101[0x0];return _0x2fa101['find'](_0xb3cde4=>_0xb3cde4['top']-0x3<=this['_activeViewTarget']['y']&&_0xb3cde4['bottom']+0x3>=this['_activeViewTarget']['y']&&_0xb3cde4['left']-0x3<=this['_activeViewTarget']['x']&&_0xb3cde4['right']+0x3>=this['_activeViewTarget']['x'])||_0x2fa101[0x0];}}}),this['_balloon']['showStack']('revisionHistoryLabel'));}),this['on']('change:activeChange',(_0x4499eb,_0x35a2bd,_0x405fb1,_0x1239b9)=>{this['activeView']=_0x405fb1?this['_getViewForChange'](_0x405fb1):null,this['editor']['model']['change'](()=>{const _0x26f2dd=this['editor']['editing'];_0x1239b9&&(_0x1239b9['data']['isOnRoot']?_0x26f2dd['view']['change'](_0x4c7c31=>{_0x4c7c31['removeClass']('ck-revision-history-root--active',_0x26f2dd['view']['document']['getRoot'](_0x1239b9['rootName']));}):_0x26f2dd['reconvertMarker']('revision:'+_0x1239b9['id'])),_0x405fb1&&(_0x405fb1['data']['isOnRoot']?_0x26f2dd['view']['change'](_0xa1c308=>{_0xa1c308['addClass']('ck-revision-history-root--active',_0x26f2dd['view']['document']['getRoot'](_0x405fb1['rootName']));}):_0x26f2dd['reconvertMarker']('revision:'+_0x405fb1['id']));});}),this['listenTo'](this['editor']['editing']['view']['document'],'mouseover',(_0x222d16,_0x4ae53c)=>{if(this['activeChange'])return;const _0x283b88=this['_findChangeIdFromDomTarget'](_0x4ae53c['target']),_0x493572=this['_changeIdToChange']['get'](_0x283b88);_0x493572?(this['_activeViewTarget']={'x':_0x4ae53c['domEvent']['x'],'y':_0x4ae53c['domEvent']['y']},this['activeView']=this['_getViewForChange'](_0x493572)):(this['_activeViewTarget']=null,this['activeView']=null);}),this['listenTo'](this['editor']['editing']['view']['document'],'mousedown',(_0x80b1dd,_0x10e8c2)=>{const _0x5c7ffc=this['_findChangeIdFromDomTarget'](_0x10e8c2['target']),_0x2888fc=this['_changeIdToChange']['get'](_0x5c7ffc);_0x2888fc?(this['_activeViewTarget']={'x':_0x10e8c2['domEvent']['x'],'y':_0x10e8c2['domEvent']['y']},_0x2888fc===this['activeChange']?this['_balloon']['updatePosition']():this['activeChange']=_0x2888fc):(this['_activeViewTarget']=null,this['activeChange']=null);});}['_findChangeIdFromDomTarget'](_0x822cad){do{const _0x205c46=_0x822cad['getAttribute']('data-change-id');if(_0x205c46)return _0x205c46;_0x822cad=_0x822cad['parent'];}while(_0x822cad);return null;}['_cleanMarkers'](){this['editor']['model']['change'](_0x44b60b=>{for(const _0x3c5243 of this['editor']['model']['markers'])_0x44b60b['removeMarker'](_0x3c5243);});}}function X(_0x4f66b5,_0x72a22e){return(_0x42113c,_0x4689da,_0x1ea32e)=>{if(!_0x1ea32e['consumable']['test'](_0x4689da['markerRange'],_0x42113c['name']))return;const _0x56bc0d=_0x4689da['markerRange']['getWalker'](),_0x592a25=_0x4689da['markerRange']['start'],_0x16f85a=_0x4f66b5['model']['schema'];let _0x1cc892=null,_0x284b88=null,_0x2217b=!0x1,_0x1c26eb=!0x1;for(const _0x3cbd59 of _0x56bc0d){const _0xaaa2bb=_0x3cbd59['item'];_0x2217b=_0x2217b||_0x16f85a['isContent'](_0xaaa2bb);const _0x36a6fe=_0x1ea32e['mapper']['toViewElement'](_0xaaa2bb);if(_0x36a6fe&&_0x36a6fe['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x3cbd59['type']&&(_0x16f85a['isBlock'](_0xaaa2bb)&&!_0x16f85a['isLimit'](_0xaaa2bb)&&(_0xaaa2bb['nextSibling']||_0x592a25['isAtEnd']?_0x1cc892&&_0x1cc892['parent']==_0xaaa2bb||(_0x1cc892=_0xaaa2bb,_0x33b325(_0x3cbd59['previousPosition']),_0x1c26eb=!0x0):_0x284b88=_0x284b88||_0x3cbd59['previousPosition']));}function _0x33b325(_0x541d29){const _0x255fab=_0x1ea32e['mapper']['toViewPosition'](_0x541d29),_0x2b56d3=_0x1ea32e['writer']['createUIElement']('span',{'class':'ck-suggestion-preview-marker-'+_0x72a22e});_0x1ea32e['writer']['insert'](_0x255fab,_0x2b56d3),_0x1ea32e['mapper']['bindElementToMarker'](_0x2b56d3,_0x4689da['markerName']);}_0x2217b||_0x1c26eb||!_0x284b88||_0x33b325(_0x284b88);};}class mt extends _0x5123c0{constructor(_0x31081d){super(_0x31081d);const _0x5937b4=_0x31081d['plugins']['get'](m);this['affectsData']=!0x1,this['listenTo'](_0x5937b4,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x5937b4,'change:isEnabled',()=>this['refresh']());}['execute'](){const _0x447dd9=this['editor'],_0x3b17c1=_0x447dd9['plugins']['get'](m),_0x1a3706=_0x3b17c1['isReady']?_0x3b17c1['diff']['newRevisionId']:null;_0x447dd9['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x1a3706);}['refresh'](){const {isReady:_0x2a6373,isEnabled:_0x93c99b,repository:_0x1ae77c,diff:_0x32dfd9}=this['editor']['plugins']['get'](m),_0x59eee8=_0x32dfd9&&_0x1ae77c['getLaterVisibleRevision'](_0x32dfd9['newRevisionId']);this['isEnabled']=_0x2a6373&&_0x93c99b&&Boolean(_0x59eee8);}}class wt extends _0x5123c0{['_step'];constructor(_0x155907,{direction:_0x256fec}){super(_0x155907);const _0x3cc66c=_0x155907['plugins']['get'](m);this['affectsData']=!0x1,this['_step']='forward'===_0x256fec?0x1:-0x1,this['listenTo'](_0x3cc66c,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x3cc66c,'change:isEnabled',()=>this['refresh']()),this['listenTo'](_0x3cc66c,'change:activeChange',()=>this['refresh']());}['execute'](){const _0x58fb37=this['editor'],_0x3ca6f2=_0x58fb37['plugins']['get'](m),{isNavigationMode:_0x53aef4,currentChangeNumber:_0x515acb}=_0x3ca6f2;let _0x3a31df;if(_0x3ca6f2['activeChange']=_0x53aef4?_0x3ca6f2['diff']['changes']['get'](_0x515acb+this['_step']):_0x3ca6f2['diff']['changes']['first'],_0x3ca6f2['activeChange']['data']['isOnRoot'])_0x3a31df=_0x58fb37['editing']['view']['getDomRoot'](_0x3ca6f2['activeChange']['rootName']);else{const _0x2d2da9=_0x58fb37['model']['markers']['get']('revision:'+_0x3ca6f2['activeChange']['id']);_0x3a31df=_0x2e5ebc(_0x58fb37['editing'],_0x2d2da9);}_0x40b14f({'target':_0x3a31df,'viewportOffset':0x28});}['refresh'](){const {isNavigationMode:_0x23ac04,currentChangeNumber:_0x1be7c7,numberOfChanges:_0x3aacb9,isReady:_0xb2f22d,isEnabled:_0x5b2a66}=this['editor']['plugins']['get'](m);this['isEnabled']=!!(_0x5b2a66&&_0xb2f22d&&_0x3aacb9)&&(!_0x23ac04||(0x1===this['_step']?_0x1be7c7<_0x3aacb9-0x1:_0x1be7c7>0x0));}}class li extends ts{constructor(_0x53cc78){super(_0x53cc78);const _0x2bcb5c=this['bindTemplate'],_0x40e249=new te(_0x53cc78),_0x5c7d38=new te(_0x53cc78);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',(_0xdadbb0,_0x37021f)=>_0xdadbb0&&_0x37021f>0x0),this['bind']('_statusText')['to'](this,'isReady',this,'currentChangeNumber',this,'numberOfChanges',this,'isNavigationMode',(_0x49ee96,_0x11952f,_0x4179de,_0x27beff)=>{if(!_0x49ee96)return g(_0x53cc78,'Loading...');if(!_0x4179de)return g(_0x53cc78,'No\x20changes');const _0x90170a=g(_0x53cc78,'NUMBER_OF_CHANGES',_0x4179de);return _0x27beff?g(_0x53cc78,'X_OF_Y_CHANGES',[_0x11952f+0x1,_0x4179de]):_0x90170a;}),_0x40e249['set']({'label':g(_0x53cc78,'Show\x20previous\x20change'),'tooltip':!0x0,'icon':_0x29bc7b}),_0x5c7d38['set']({'label':g(_0x53cc78,'Show\x20next\x20change'),'tooltip':!0x0,'icon':_0x55b434}),_0x40e249['bind']('isEnabled')['to'](this,'isBackwardNavigationEnabled'),_0x5c7d38['bind']('isEnabled')['to'](this,'isForwardNavigationEnabled'),_0x40e249['on']('execute',()=>this['fire']('execute','backward')),_0x5c7d38['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',_0x2bcb5c['if']('_isStatusLabelVisible','ck-hidden',_0x35a946=>!_0x35a946)]},'children':[{'text':_0x2bcb5c['to']('isNavigationMode',_0x18e9ad=>_0x18e9ad?g(_0x53cc78,'EDIT_X_OF_Y_REVISIONS')+':\x20':g(_0x53cc78,'Total')+':\x20')}]},{'text':_0x2bcb5c['to']('_statusText')}]},new _0x4dae21(),{'tag':'div','attributes':{'class':['ck-revision-history-ui__changes-navigation__navigation']},'children':[_0x40e249,_0x5c7d38]}]});}}const le='ck-editor__editable__loading-overlay';class ge extends _0x37aa98{static get['pluginName'](){return'RevisionViewerLoadingOverlay';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['show'](){const _0x5d3575=this['editor']['editing']['view'];_0x5d3575['change'](_0x92804=>{for(const _0x25c7d3 of _0x5d3575['document']['roots'])_0x92804['addClass'](le,_0x25c7d3);});}['hide'](){const _0x3e7850=this['editor']['editing']['view'];_0x3e7850['change'](_0x53bfb4=>{for(const _0x22e3a5 of _0x3e7850['document']['roots'])_0x53bfb4['removeClass'](le,_0x22e3a5);});}}class R extends _0x37aa98{static get['pluginName'](){return'RevisionViewerUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[m,ge];}['init'](){const _0x2c4a86=this['editor'],_0x227910=_0x2c4a86['plugins']['get'](m),_0x371489=_0x2c4a86['plugins']['get'](ge);_0x2c4a86['ui']['componentFactory']['add']('exitToEditing',_0x58bfd6=>{const _0x48bfc7=new te(_0x58bfd6);return _0x48bfc7['set']({'label':g(_0x58bfd6,'Back\x20to\x20editing'),'icon':_0x548abb,'withText':!0x0,'tooltip':!0x0,'class':'ck-revision-history-ui__back-to-editing'}),this['listenTo'](_0x48bfc7,'execute',()=>{_0x2c4a86['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}),_0x48bfc7;}),_0x2c4a86['ui']['componentFactory']['add']('restoreRevision',_0x513d04=>{const _0x5c2cc3=new te(_0x513d04);return _0x5c2cc3['set']({'label':g(_0x513d04,'Restore\x20this\x20revision'),'withText':!0x0,'tooltip':!0x0}),_0x5c2cc3['bind']('isEnabled')['to'](_0x2c4a86['commands']['get']('restoreRevision')),this['listenTo'](_0x5c2cc3,'execute',()=>_0x2c4a86['execute']('restoreRevision')),_0x5c2cc3;}),_0x2c4a86['ui']['componentFactory']['add']('changesNavigation',_0x5d1d8a=>{const _0x500df9=new li(_0x5d1d8a),_0x235cc3=_0x2c4a86['commands']['get']('showPreviousChange'),_0x1cf644=_0x2c4a86['commands']['get']('showNextChange');return _0x500df9['bind']('isBackwardNavigationEnabled')['to'](_0x235cc3,'isEnabled'),_0x500df9['bind']('isForwardNavigationEnabled')['to'](_0x1cf644,'isEnabled'),_0x500df9['bind']('isReady','currentChangeNumber','numberOfChanges','isNavigationMode')['to'](_0x227910),this['listenTo'](_0x500df9,'execute',(_0x572816,_0x5100a3)=>{_0x2c4a86['execute']('forward'===_0x5100a3?'showNextChange':'showPreviousChange');}),_0x500df9;}),_0x371489['show'](),_0x227910['on']('change:isReady',(_0xef4abb,_0x5edcac,_0x4f2d5f)=>{_0x4f2d5f?_0x371489['hide']():_0x371489['show']();});}}class at extends _0x2be6a1{['_resizeObserver']=null;constructor(_0x3ef91d,_0x1d2ad7){super(_0x3ef91d,_0x1d2ad7);const _0x544783=this['bindTemplate'];this['set']({'label':g(_0x3ef91d,'Revision\x20name'),'_tooltipString':''}),this['fieldView']['placeholder']=g(_0x3ef91d,'Enter\x20the\x20revision\x20name'),this['extendTemplate']({'tag':'span','attributes':{'class':['ck-revision-history-sidebar__revision-name'],'data-cke-tooltip-text':_0x544783['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 _0x28e032=this['fieldView']['element'];this['_tooltipString']=_0x28e032['scrollWidth']>_0x28e032['clientWidth']&&_0x28e032['value']||'';}}class oi extends ts{constructor(_0x53186b,_0x3d081d,_0x448f38){super(_0x53186b);const _0x5cf9d4=new _0xaa104a();_0x5cf9d4['set']({'content':_0x20ebe2,'viewBox':'0\x200\x2011\x2010'});const _0x438684=['ck','ck-revision-history-sidebar__revision-author'];_0x448f38&&_0x438684['push']('ck-revision-history-sidebar__revision-author_creator');const _0x103341=[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision-author__name'],'title':g(_0x53186b,_0x448f38?'Revision\x20creator':'Revision\x20author')},'children':[_0x5cf9d4,_0x3d081d['name']]}];this['setTemplate']({'tag':'li','attributes':{'class':_0x438684},'children':_0x103341});}}function ai(_0x2de1be,_0x549170){const _0x2c7caf=_0x2de1be['bindTemplate'],_0x1755e5=_0x2de1be['locale'],_0x2195b3=_0x5d6b2b(_0x1755e5);_0x2195b3['panelPosition']='sw';const _0x253729=function(_0x1adeff,_0x46f1a5){const _0x494d6f=function(_0x396c00,_0x5ad166){const _0x2a9567=_0x396c00['locale'],_0x4ca245={'Compare\x20against\x20selected':g(_0x2a9567,'Compare\x20against\x20selected'),'Name\x20this\x20revision':g(_0x2a9567,'Name\x20this\x20revision'),'Restore\x20this\x20revision':g(_0x2a9567,'Restore\x20this\x20revision')};return _0x5ad166['map'](_0x31dff8=>{const _0x571833=_0x4ca245[_0x31dff8['name']];return _0x571833&&_0x571833!==_0x31dff8['name']&&(_0x31dff8['name']=_0x571833),_0x31dff8;});}(_0x1adeff,_0x46f1a5),_0x5596c0=new _0x2a9213();for(const _0x571dcf of _0x494d6f){const _0x17eea4={'type':'button','model':new to({'label':_0x571dcf['name'],'class':_0x571dcf['class'],'withText':!0x0,'role':'menuitem','_action':_0x571dcf['action']})};_0x17eea4['model']['bind']('isEnabled')['to'](_0x1adeff,'isActionsDropdownOpen',_0x2c0016=>'function'!=typeof _0x571dcf['isEnabled']||(!_0x2c0016||_0x571dcf['isEnabled'](_0x1adeff))),_0x5596c0['add'](_0x17eea4);}return _0x5596c0;}(_0x2de1be,_0x549170);return _0x2de1be['bind']('isActionsDropdownOpen')['to'](_0x2195b3,'isOpen'),_0x2195b3['buttonView']['set']({'label':g(_0x1755e5,'Show\x20more\x20items'),'tooltip':!0x0,'tooltipPosition':'sw','icon':_0x28c97e}),_0x2195b3['extendTemplate']({'attributes':{'class':['ck-revision-history-sidebar__revision__actions',_0x2c7caf['if']('isActionsDropdownOpen','ck-on')]},'on':{'click':_0x2c7caf['to'](_0x4b3db8=>_0x4b3db8['stopPropagation']())}}),_0x2195b3['on']('execute',_0x21257f=>{_0x2de1be['isReady']&&'function'==typeof _0x21257f['source']['_action']&&_0x21257f['source']['_action'](_0x2de1be);}),_0x548dd5(_0x2195b3,_0x253729,{'role':'menu'}),_0x2195b3['listenTo'](_0x2de1be,'change:isActionsDropdownOpen',(_0x53e412,_0x5d916c,_0x30c7b5)=>{if(_0x30c7b5)for(const _0xeee071 of _0x2195b3['listView']['items']){const _0x48b85f=_0xeee071['children']['first'],_0x56027d=_0x549170['find'](_0x261e59=>_0x261e59['action']===_0x48b85f['_action'])['isVisible'];_0xeee071['isVisible']=void 0x0===_0x56027d||_0x56027d(_0x2de1be);}}),_0x2195b3;}class si extends/* #__PURE__ -- @preserve */
|
|
26
|
+
_0x36d32c(ts){['id'];['revisionNameView'];['revisionActionsView'];['_revision'];['_requireRevisionName'];constructor(_0x23bdd5,_0x194292,_0x59e59b,_0x5aead5){super(_0x23bdd5);const _0x15ed22=this['bindTemplate'],_0x32346c=function(_0x3abeac,_0x23f748){const _0x260286=Array['from'](_0x23f748['authors'])['filter'](_0x37b766=>_0x37b766!=_0x23f748['creator']);return _0x23f748['creator']&&_0x260286['unshift'](_0x23f748['creator']),_0x260286['map'](_0x3fa4ea=>new oi(_0x3abeac,_0x3fa4ea,_0x3fa4ea==_0x23f748['creator']));}(_0x23bdd5,_0x194292);this['id']=_0x194292['id'],this['_revision']=_0x194292,this['_requireRevisionName']=_0x5aead5,this['bind']('name','createdAt')['to'](_0x194292),this['bind']('_createdAtFormatted')['to'](this,'createdAt',_0x3f955d=>{return _0x4f1a27=_0x23bdd5['uiLanguage'],(_0x10231a=_0x3f955d)['toLocaleDateString'](_0x4f1a27,{'month':'long','day':'numeric'})+',\x20'+_0x10231a['toLocaleTimeString'](_0x4f1a27,{'hour':'numeric','minute':'numeric'});var _0x4f1a27,_0x10231a;}),this['set']('isSelected',!0x1),this['set']('isHighlighted',!0x1),this['set']('isActionsDropdownOpen',!0x1),this['set']('isReady',!0x1),this['set']('isEnabled',!0x1),this['revisionNameView']=new at(_0x23bdd5,_0x22d3ee),this['revisionNameView']['fieldView']['extendTemplate']({'attributes':{'maxlength':'220'}}),this['revisionNameView']['fieldView']['bind']('value')['to'](this,'name',_0x498b4b=>_0x498b4b||this['_createdAtFormatted']),this['revisionNameView']['bind']('isEnabled')['to'](this,'isSelected',this,'isEnabled',(_0x46d1ed,_0x405056)=>_0x46d1ed&&_0x405056),this['revisionActionsView']=_0x59e59b&&_0x59e59b['length']?ai(this,_0x59e59b):'',this['revisionActionsView']&&this['revisionActionsView']['bind']('isEnabled')['to'](this),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision-wrapper',_0x15ed22['if']('isConfirm','ck-revision-history-sidebar__revision-wrapper_confirmation_visible')]},'children':[{'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision',_0x15ed22['if']('isEnabled','ck-disabled',_0x55bd46=>!_0x55bd46),_0x15ed22['if']('isSelected','ck-revision-history-sidebar__revision_selected'),_0x15ed22['if']('isHighlighted','ck-revision-history-sidebar__revision_highlighted'),_0x15ed22['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':_0x15ed22['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':_0x32346c}]},this['revisionActionsView']],'on':{'click':_0x15ed22['to'](_0x52eca8=>{_0x52eca8['srcElement']['closest']('.ck-thread__remove-confirm')||this['isReady']&&this['isEnabled']&&this['fire']('select',{'id':this['id']});})}}]});}['render'](){super['render']();const _0x4c1564=this['revisionNameView']['fieldView']['element'];this['listenTo'](_0x4c1564,'change',()=>{this['_requireRevisionName']&&!_0x4c1564['value']||this['fire']('setName',{'id':this['id'],'name':_0x4c1564['value']}),_0x4c1564['value']||(_0x4c1564['value']=this['name']?this['name']:this['_createdAtFormatted']);});}['select'](){this['isSelected']=!0x0;}['deselect'](){this['isSelected']=!0x1;}['highlight'](){this['isHighlighted']=!0x0;}['unhighlight'](){this['isHighlighted']=!0x1;}}function ti(_0x3d2d17,_0x469b36){const _0x43a11b=_0x45883b['fromJSDate'](_0x3d2d17)['setLocale'](_0x469b36),_0xdee722=_0x45883b['local'](),_0x46444b=_0xdee722['minus']({'days':0x1})['startOf']('day');let _0x24ed34,_0x44f51a;return _0x43a11b['hasSame'](_0xdee722,'day')?(_0x24ed34=_0x43a11b['startOf']('day')['toJSDate'](),_0x44f51a=_0x43a11b['toRelativeCalendar']()):_0x43a11b['hasSame'](_0x46444b,'day')?(_0x24ed34=_0x46444b['toJSDate'](),_0x44f51a=_0x43a11b['toRelativeCalendar']()):_0x43a11b['hasSame'](_0xdee722,'week')?(_0x24ed34=_0x43a11b['startOf']('week')['toJSDate'](),_0x44f51a=_0x43a11b['weekdayLong']||''):_0x43a11b['hasSame'](_0xdee722,'year')?(_0x24ed34=_0x43a11b['startOf']('month')['toJSDate'](),_0x44f51a=_0x43a11b['monthLong']||''):(_0x24ed34=_0x43a11b['startOf']('year')['toJSDate'](),_0x44f51a=String(_0x43a11b['year'])),{'startDate':_0x24ed34,'localizedPeriodName':_0x44f51a};}class ei extends ts{['startDate'];['revisionViews'];['_revisionActions'];['_requireRevisionName'];constructor(_0x49ca33,_0x1d4765,_0x23af2c,_0xc7b390){super(_0x49ca33);const _0x4aa9ce=ti(_0x1d4765,this['locale']['uiLanguage'])['localizedPeriodName'];this['startDate']=_0x1d4765,this['revisionViews']=this['createCollection'](),this['_revisionActions']=_0x23af2c,this['_requireRevisionName']=_0xc7b390,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':_0x4aa9ce}]},{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__time-period__revisions']},'children':this['revisionViews']}]});}['addRevision'](_0x26da2c){const _0x4c09f1=new si(this['locale'],_0x26da2c,this['_revisionActions'],this['_requireRevisionName']);this['revisionViews']['add'](_0x4c09f1);}['removeRevision'](_0x5cf622){const _0x5babd5=this['revisionViews']['find'](_0x37bcac=>_0x37bcac['id']===_0x5cf622['id']);this['revisionViews']['remove'](_0x5babd5);}}class cs extends ts{constructor(_0x32dca2){super(_0x32dca2);const _0x74da58=new _0xaa104a();_0x74da58['content']=_0x3acfa9,this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset_all','ck-revision-history-sidebar__header']},'children':[_0x74da58,{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__header__label']},'children':[g(_0x32dca2,'Revision\x20history')]}]});}}class ii extends ts{['timePeriodViews'];['_revisions'];['_revisionActions'];['_requireRevisionName'];constructor(_0x1fbd94,_0x2127e2,_0xab5b82,_0x39011d){super(_0x1fbd94);const _0x56f0ef=this['bindTemplate'];this['timePeriodViews']=this['createCollection'](),this['timePeriodViews']['delegate']('select')['to'](this),this['timePeriodViews']['delegate']('setName')['to'](this),this['_revisions']=_0x2127e2,this['_revisionActions']=_0xab5b82,this['_requireRevisionName']=_0x39011d,this['on']('select',(_0x5f5b15,_0x20b2fe)=>{this['fire']('revisionSelected',_0x20b2fe);}),this['on']('setName',(_0x44d2f3,_0x348d6e)=>{this['fire']('revisionSetName',_0x348d6e);}),this['set']('isEnabled',!0x1),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-rounded-corners','ck-revision-history-sidebar']},'children':[new cs(_0x1fbd94),{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__timeline',_0x56f0ef['if']('isEnabled','ck-disabled',_0x578635=>!_0x578635)]},'children':this['timePeriodViews']}]});}['render'](){super['render']();for(const _0x1b1e07 of this['_revisions'])this['_addRevision'](_0x1b1e07);this['_revisions']['on']('add',(_0x6ec10a,_0x5a294f)=>{this['_addRevision'](_0x5a294f);}),this['_revisions']['on']('remove',(_0x3b9588,_0x5495ce)=>{this['_removeRevision'](_0x5495ce);});}get['revisionViews'](){return this['timePeriodViews']['map'](_0x10772d=>_0x10772d['revisionViews']['map'](_0x48a771=>_0x48a771))['flat']();}['selectRevision'](_0x57f856){for(const _0xcaaa58 of this['revisionViews'])_0x57f856&&_0x57f856['id']===_0xcaaa58['id']?_0xcaaa58['select']():_0xcaaa58['deselect']();}['highlightRevisions'](_0x5821c9){for(const _0x508bdc of this['revisionViews'])_0x5821c9['some'](({id:_0x9d6b19})=>_0x9d6b19===_0x508bdc['id'])?_0x508bdc['highlight']():_0x508bdc['unhighlight']();}['_addRevision'](_0x2f2e49){const _0x5c34b4=ti(_0x2f2e49['createdAt'],this['locale']['uiLanguage'])['startDate'];let _0x4a9e91=this['timePeriodViews']['get'](0x0);_0x4a9e91&&_0x4a9e91['startDate']['getTime']()===_0x5c34b4['getTime']()||(_0x4a9e91=new ei(this['locale'],_0x5c34b4,this['_revisionActions'],this['_requireRevisionName']),this['timePeriodViews']['add'](_0x4a9e91)),_0x4a9e91['addRevision'](_0x2f2e49);}['_removeRevision'](_0x265d32){const _0xecb1=ti(_0x265d32['createdAt'],this['locale']['uiLanguage'])['startDate'];this['_getTimePeriodViewByStartDate'](_0xecb1)['removeRevision'](_0x265d32);}['_getTimePeriodViewByStartDate'](_0x430792){return this['timePeriodViews']['find'](_0x5e6175=>_0x5e6175['startDate']['getTime']()===_0x430792['getTime']());}}class d extends _0x37aa98{['_revisionViewer'];['_revisionsRepository'];['_sidebarView'];static ['defaultRevisionActions']=/* #__PURE__ -- @preserve */
|
|
27
27
|
((()=>['compareAgainstSelected','restoreRevision','nameRevision'])());static ['availableRevisionActions']=/* #__PURE__ -- @preserve */
|
|
28
|
-
pt();static get['pluginName'](){return'RevisionsSidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[m];}constructor(
|
|
29
|
-
_0x54e498(_0x3de20e){['_ui'];get['ui'](){return this['_ui'];}constructor(_0x31115b,_0x306df9){super(_0x306df9),this['sourceElement']=_0x31115b,this['model']['document']['createRoot']();const _0x3ba89d=new it(this['locale'],this['editing']['view'],{'shouldToolbarGroupWhenFull':!0x0});this['_ui']=new tt(this,_0x3ba89d);}['destroy'](){return this['updateSourceElement'](),this['ui']['destroy'](),super['destroy']();}static async['create'](_0x553fe9,_0x575f13){const _0x4ed758=new this(_0x553fe9,_0x575f13);return await _0x4ed758['initPlugins'](),await _0x4ed758['ui']['init'](_0x553fe9),await _0x4ed758['data']['init'](_0x4ed758['config']['get']('initialData')||''),_0x4ed758['fire']('ready'),_0x4ed758;}}const p=['RevisionHistoryUI','RestrictedEditingMode'];class _t extends _0x3561a9{['result'];static get['pluginName'](){return'RevisionViewerIntegration';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x53754e){function _0x35a736(_0xf17e70){return _0xf17e70['map'](_0x121a4d=>String['fromCharCode'](_0x121a4d))['join']('');}super(_0x53754e),this['result']='end',_0x53754e[_0x35a736([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x35a736([0x76,0x69,0x65,0x77])][_0x35a736([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x35a736([0x61,0x75,0x74,0x6f]),_0x53754e[_0x35a736([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x35a736([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x35a736([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x35a736([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x35a736([0x6f,0x6b])});}}class k extends _0x3561a9{['_viewerEditor'];static get['pluginName'](){return'RevisionHistory';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[u,f];}constructor(_0x38f98a){if(super(_0x38f98a),!this['editor']['config']['get']('revisionHistory'))throw new _0x42c7fc('revision-history-missing-configuration',this);this['_viewerEditor']=null,this['set']('isRevisionViewerOpen',!0x1),this['editor']['config']['define']('revisionHistory.showRevisionViewerCallback',_0x14cda2=>this['_showRevisionViewer']({..._0x14cda2,'translations':this['editor']['locale']['translations']})),this['editor']['config']['define']('revisionHistory.closeRevisionViewerCallback',_0x53a3d7=>this['_closeRevisionViewer'](_0x53a3d7)),this['editor']['config']['define']('revisionHistory.restoreRevisionCallback',_0x20820d=>this['_restoreRevision'](_0x20820d)),this['editor']['config']['define']('revisionHistory.requireRevisionName',!0x1),this['_enhanceShowRevisionViewerCallback'](),this['_enhanceCloseRevisionViewerCallback']();}set['adapter'](_0x39d8e0){this['editor']['plugins']['get']('RevisionTracker')['adapter']=_0x39d8e0;}get['adapter'](){return this['editor']['plugins']['get']('RevisionTracker')['adapter'];}['addRevisionData'](_0x547e68){return this['editor']['plugins']['get']('RevisionTracker')['addRevisionData'](_0x547e68);}['getRevision'](_0x3e6b80){return this['editor']['plugins']['get']('RevisionsRepository')['getRevision'](_0x3e6b80);}['getRevisions'](_0x281276){return this['editor']['plugins']['get']('RevisionsRepository')['getRevisions'](_0x281276||{'toJSON':!0x1});}['_getRevisionViewerEditorConfig'](){const _0xba7c84=this['editor'],_0x664159=_0x5ce59e(_0xba7c84,p),_0x2c5227=_0xba7c84['plugins']['get']('RevisionTracker'),_0x227df5=_0xba7c84['plugins']['get']('Users')['users'];return _0x664159['toolbar']=['exitToEditing','restoreRevision','changesNavigation'],delete _0x664159['lazyRoots'],(_0x664159['plugins']['push'](_t,m,R,class extends _0x3561a9{static get['requires'](){return[m,'Users'];}['init'](){const _0x3cff69=this['editor']['plugins']['get']('Users');for(const _0x51c7e4 of _0x227df5)_0x51c7e4['isAnonymous']||_0x3cff69['getUser'](_0x51c7e4['id'])||_0x3cff69['addUser'](_0x51c7e4);const _0x38db1a=_0x2c5227['repository']['getRevisions']();let _0x32f681=null;const _0x57ec3e=this['editor']['plugins']['get']('RevisionViewer');_0x57ec3e['adapter']=_0x2c5227['adapter'],_0x57ec3e['bind']('isEnabled')['to'](_0x2c5227),this['editor']['commands']['get']('restoreRevision')['bind']('isEnabled')['to'](_0xba7c84,'isReadOnly',_0xae4655=>!_0xae4655);for(const _0x2295eb of _0x38db1a){const _0x354656=null===_0x2295eb['creator'];if(_0x354656&&_0x2295eb['toVersion']===_0x2295eb['fromVersion'])continue;const _0xe4b7d7=_0x2295eb['toJSON']();_0x57ec3e['addRevisionData'](_0xe4b7d7,(_0x5664d5,_0x331e07,_0x49eb94)=>{if(_0x354656){if(_0x32f681)_0x32f681['_update'](_0x5664d5,_0x331e07);else{if(!_0x331e07){const _0x1bef14=_0x49eb94['toJSON']();_0x1bef14['id']=_0x46e088(),_0x2c5227['saveRevision'](_0x1bef14,_0x49eb94['toVersion'])['then'](_0x19673c=>{_0x32f681=_0x19673c;});}}}else _0x2295eb['_update'](_0x5664d5,_0x331e07);});}}},d),_0x664159);}['_enhanceShowRevisionViewerCallback'](){const _0x58d234=this['editor']['config']['get']('revisionHistory')['showRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.showRevisionViewerCallback',async()=>{this['editor']['enableReadOnlyMode']('revision-history-viewer-opened');const _0x2bba4e=this['editor']['plugins']['get']('RevisionTracker');if(this['editor']['plugins']['has']('Autosave')){const _0x21ad46=this['editor']['plugins']['get']('Autosave');await _0x21ad46['save']();}else await _0x2bba4e['update']();if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('Dialog')){const _0x51a61f=this['editor']['plugins']['get']('Dialog');_0x51a61f['isOpen']&&_0x51a61f['hide']();}const _0x31a6ce=this['_getRevisionViewerEditorConfig']();return _0x58d234(_0x31a6ce)['then'](_0x1ac421=>{return(this['_viewerEditor']=_0x1ac421,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'),_0x1ac421);})['catch'](_0x1224d3=>(console['error'](_0x1224d3),this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),null));});}['_enhanceCloseRevisionViewerCallback'](){const _0x3a4c9e=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'](),_0x3a4c9e(this['_viewerEditor'])['then'](()=>{if(this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),this['_viewerEditor']=null,this['editor']['plugins']['has']('Annotations')){const _0x1d72de=this['editor']['plugins']['get']('Annotations');_0x1d72de['refreshVisibility'](),_0x1d72de['refreshPositioning']();}})));}['_showRevisionViewer'](_0xccc010){const _0x16a204=this['editor']['config']['get']('revisionHistory.editorContainer'),_0x4d5e0a=this['editor']['config']['get']('revisionHistory.viewerContainer'),_0x154135=this['editor']['config']['get']('revisionHistory.viewerEditorElement');return w['create'](_0x154135,_0xccc010)['then'](_0x45ef13=>(_0x4d5e0a['style']['display']='block',_0x16a204['style']['display']='none',this['isRevisionViewerOpen']=!0x0,_0x45ef13));}['_closeRevisionViewer'](_0x7219d2){const _0x35f08f=this['editor']['config']['get']('revisionHistory.editorContainer');return this['editor']['config']['get']('revisionHistory.viewerContainer')['style']['display']='none',_0x35f08f['style']['display']='',this['isRevisionViewerOpen']=!0x1,_0x7219d2['destroy']();}async['_restoreRevision'](_0x266dde){const _0x91e34e=this['editor'],_0x255354=this['_viewerEditor']['plugins']['get']('RevisionViewer'),_0x327946=_0x91e34e['plugins']['get']('RevisionTracker'),_0xe5bc77=_0x91e34e['plugins']['get']('RevisionHistoryUtils'),_0xcedab3=_0x255354['repository']['getRevision'](_0x266dde);let _0x520542,_0x88bc04,_0x5ad3f2;try{await _0xe5bc77['loadRevisionData'](_0xcedab3,this['adapter']),_0x520542=_0xe5bc77['getRevisionDocumentData'](_0xcedab3),_0x88bc04=_0xe5bc77['getRevisionRootsAttributes'](_0xcedab3);}catch(_0x5d537b){return void console['error'](_0x5d537b);}_0x91e34e['model']['change'](_0xc88971=>{for(const _0x5c73b4 of Array['from'](_0x91e34e['model']['markers']['getMarkersGroup']('restrictedEditingException')))_0xc88971['removeMarker'](_0x5c73b4);}),_0x255354['isReady']=!0x1,_0x91e34e['model']['enqueueChange'](_0x24517f=>{_0x24517f['setSelection'](null),_0x24517f['removeSelectionAttribute'](_0x91e34e['model']['document']['selection']['getAttributeKeys']());const _0x5a5905=Object['keys'](_0x520542);for(const _0xd9795f of _0x91e34e['model']['document']['roots'])'$graveyard'!=_0xd9795f['rootName']&&_0xd9795f['isAttached']()&&!_0x5a5905['includes'](_0xd9795f['rootName'])&&_0x24517f['detachRoot'](_0xd9795f);for(const _0x2b9e09 of _0x5a5905){let _0x5c30df=_0x91e34e['model']['document']['getRoot'](_0x2b9e09);_0x5c30df&&_0x5c30df['isAttached']()||(_0x5c30df=_0x24517f['addRoot'](_0x2b9e09));const _0x4e460e=_0x88bc04[_0x2b9e09],_0x303bf8=Object['keys'](_0x4e460e),_0x241c99=_0x520542[_0x2b9e09];for(const _0x5c4247 of _0x5c30df['getAttributeKeys']())_0x303bf8['includes'](_0x5c4247)||_0x24517f['removeAttribute'](_0x5c4247,_0x5c30df);for(const _0x1bb546 of _0x303bf8)_0x24517f['setAttribute'](_0x1bb546,_0x88bc04[_0x2b9e09][_0x1bb546],_0x5c30df);_0x24517f['remove'](_0x24517f['createRangeIn'](_0x5c30df)),_0x24517f['insert'](_0x91e34e['data']['parse'](_0x241c99,_0x5c30df),_0x5c30df,0x0);}});const _0x1741a2=g(_0x91e34e['locale'],'Restored');if(_0xcedab3['name'])_0x5ad3f2=-0x1==_0xcedab3['name']['indexOf'](_0x1741a2)?_0x1741a2+':\x20'+_0xcedab3['name']:_0xcedab3['name'];else _0x5ad3f2=_0x1741a2+':\x20'+(_0xcedab3['createdAt']['toLocaleDateString'](_0x91e34e['locale']['uiLanguage'],{'month':'long','day':'numeric'})+',\x20'+_0xcedab3['createdAt']['toLocaleTimeString'](_0x91e34e['locale']['uiLanguage'],{'hour':'numeric','minute':'numeric'}));return await _0x327946['saveRevision']({'name':_0x5ad3f2}),_0x255354['isReady']=!0x0,_0x91e34e['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}}export{h as Revision,k as RevisionHistory,f as RevisionHistoryUI,V as RevisionHistoryUtils,u as RevisionTracker,m as RevisionViewer,w as RevisionViewerEditor,ge as RevisionViewerLoadingOverlay,R as RevisionViewerUI,I as RevisionsRepository,d as RevisionsSidebar};
|
|
28
|
+
pt();static get['pluginName'](){return'RevisionsSidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[m];}constructor(_0x35f865){super(_0x35f865),this['_revisionViewer']=_0x35f865['plugins']['get'](m),this['_revisionsRepository']=this['_revisionViewer']['repository'],this['_sidebarView']=null;}['init'](){const _0xc2e11a=this['_revisionsRepository']['_revisions'],_0xe96b0f=this['_createRevisionActions'](),_0x3391d4=this['editor']['config']['get']('revisionHistory.viewerSidebarContainer');this['_sidebarView']=new ii(this['editor']['locale'],_0xc2e11a,_0xe96b0f,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',(_0x284daa,_0x4492b6)=>{_0x4492b6['revisionViews']['on']('add',(_0x1f3183,_0x160a26)=>{_0x160a26['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)),_0x3391d4['appendChild'](this['_sidebarView']['element']);}['destroy'](){this['_sidebarView']['element']['remove'](),this['_sidebarView']['destroy']();}['_handleEditorDataReady'](){const _0x178a53=this['_revisionsRepository']['getRevision'](0x0);if(_0x178a53){const _0x2f1fe7=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x178a53['id']);this['_revisionViewer']['compare'](_0x178a53,_0x2f1fe7);}}['_handleRevisionSelected'](_0x55d373,_0x212c5a){const _0xa163e2=this['_revisionsRepository']['getRevision'](_0x212c5a['id']),_0x5f1715=this['_revisionsRepository']['getEarlierVisibleRevision'](_0xa163e2['id']);this['_revisionViewer']['compare'](_0xa163e2,_0x5f1715);}['_handleRevisionSetName'](_0x479ad3,_0x2cfbc9){this['_revisionsRepository']['getRevision'](_0x2cfbc9['id'])['setName'](_0x2cfbc9['name']);}['_handleDiffChange'](_0x4c56a6,_0x15ae25,_0x526b6b){const _0x88eeb3=this['_revisionsRepository']['getRevisionsInDiff'](_0x526b6b);_0x88eeb3['length']>0x2?(this['_sidebarView']['highlightRevisions'](_0x88eeb3),this['_sidebarView']['selectRevision'](null)):(this['_sidebarView']['highlightRevisions']([]),this['_sidebarView']['selectRevision'](_0x88eeb3[0x0]));}['_createRevisionActions'](){const _0x2b033d=this['editor'],_0x2736d6=d['availableRevisionActions'],_0x541ae4=_0x2b033d['config']['get']('revisionHistory.revisionActions')||d['defaultRevisionActions'];if(_0x541ae4['length'])return _0x541ae4['map'](_0x5c023a=>{const _0x4306d8='string'==typeof _0x5c023a?Object['assign']({},_0x2736d6[_0x5c023a]):_0x5c023a;return _0x4306d8['action']=_0x4306d8['action']['bind'](this,_0x2b033d),_0x4306d8['isVisible']&&(_0x4306d8['isVisible']=_0x4306d8['isVisible']['bind'](this,_0x2b033d)),_0x4306d8;});}}function pt(){return{'compareAgainstSelected':{'name':'Compare\x20against\x20selected','action':({plugins:_0x7c8cdf},_0x22dabe)=>{const _0xcfe1f5=_0x7c8cdf['get'](m),_0xc22e58=_0xcfe1f5['repository'];let _0x5dc119=_0xcfe1f5['diff']['newRevisionId'],_0x257227=_0x22dabe['id'];_0xc22e58['getIndex'](_0x5dc119)>_0xc22e58['getIndex'](_0x257227)&&([_0x5dc119,_0x257227]=[_0x257227,_0x5dc119]),_0xcfe1f5['compare'](_0x5dc119,_0x257227);},'isVisible':({plugins:_0xf20d63},_0x474b56)=>{const _0x5bcdaf=_0xf20d63['get'](m);return!(_0x5bcdaf['repository']['getRevisionsInDiff'](_0x5bcdaf['diff'])['length']>0x2)&&!_0x474b56['isSelected'];}},'restoreRevision':{'name':'Restore\x20this\x20revision','action':(_0x3a3c7d,{id:_0x8ad148})=>{_0x3a3c7d['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x8ad148);},'isVisible':({plugins:_0x4d5f43},_0x12b89f)=>!!_0x4d5f43['get'](m)['repository']['getLaterVisibleRevision'](_0x12b89f['id'])},'nameRevision':{'name':'Name\x20this\x20revision','action':({plugins:_0x7ff510},{id:_0x12e3ba,revisionNameView:_0x52722f})=>{const _0x3a95bc=_0x7ff510['get'](m),_0x183deb=_0x3a95bc['repository']['getEarlierVisibleRevision'](_0x12e3ba);_0x3a95bc['compare'](_0x12e3ba,_0x183deb),_0x52722f['focus'](),_0x52722f['fieldView']['select']();}}};}class tt extends st{['_view'];['_toolbarConfig'];['_elementReplacer'];get['view'](){return this['_view'];}constructor(_0x18f580,_0x4fc2d9){super(_0x18f580),this['_view']=_0x4fc2d9,this['_toolbarConfig']=et(_0x18f580['config']['get']('toolbar')),this['_elementReplacer']=new ot();}get['element'](){return this['view']['element'];}['init'](_0x3390f5){const _0x95ce51=this['editor'],_0x469b7f=this['view'],_0x5e7e04=_0x95ce51['editing']['view'],_0x3c981d=_0x469b7f['editable'],_0x3d372a=_0x5e7e04['document']['getRoot']();_0x3c981d['name']=_0x3d372a['rootName'],_0x469b7f['render']();const _0x3a61ee=_0x3c981d['element'];this['setEditableElement'](_0x3c981d['name'],_0x3a61ee),_0x469b7f['editable']['bind']('isFocused')['to'](this['focusTracker']),_0x5e7e04['attachDomRoot'](_0x3a61ee),this['_elementReplacer']['replace'](_0x3390f5,this['element']),this['_initToolbar'](),this['fire']('ready');}['destroy'](){super['destroy']();const _0x5a8820=this['view'],_0xa0dd81=this['editor']['editing']['view'];this['_elementReplacer']['restore'](),_0xa0dd81['detachDomRoot'](_0x5a8820['editable']['name']),_0x5a8820['destroy']();}['_initToolbar'](){const _0x5c94dc=this['view'];_0x5c94dc['stickyPanel']['bind']('isActive')['to'](this['focusTracker'],'isFocused'),_0x5c94dc['stickyPanel']['limiterElement']=_0x5c94dc['element'],_0x5c94dc['stickyPanel']['bind']('viewportTopOffset')['to'](this,'viewportOffset',({top:_0x202638})=>_0x202638),_0x5c94dc['toolbar']['fillFromConfig'](this['_toolbarConfig'],this['componentFactory']),this['addToolbar'](_0x5c94dc['toolbar']);}}class it extends rt{['_editable'];['stickyPanel'];['toolbar'];get['editable'](){return this['_editable'];}constructor(_0x326cec,_0x21e44e,_0x3355f2={}){super(_0x326cec),this['stickyPanel']=new ht(_0x326cec),this['toolbar']=new dt(_0x326cec,{'shouldGroupWhenFull':_0x3355f2['shouldToolbarGroupWhenFull']}),this['_editable']=new ct(_0x326cec,_0x21e44e);}['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
|
+
_0x376351(_0x56567c){['_ui'];get['ui'](){return this['_ui'];}constructor(_0xefbb51,_0x3de2b5){super(_0x3de2b5),this['sourceElement']=_0xefbb51,this['model']['document']['createRoot']();const _0x2f796c=new it(this['locale'],this['editing']['view'],{'shouldToolbarGroupWhenFull':!0x0});this['_ui']=new tt(this,_0x2f796c);}['destroy'](){return this['updateSourceElement'](),this['ui']['destroy'](),super['destroy']();}static async['create'](_0x35a6b2,_0x2f9c39){const _0x5cdc83=new this(_0x35a6b2,_0x2f9c39);return await _0x5cdc83['initPlugins'](),await _0x5cdc83['ui']['init'](_0x35a6b2),await _0x5cdc83['data']['init'](_0x5cdc83['config']['get']('initialData')||''),_0x5cdc83['fire']('ready'),_0x5cdc83;}}const p=['RevisionHistoryUI','RestrictedEditingMode'];class _t extends _0x37aa98{['result'];static get['pluginName'](){return'RevisionViewerIntegration';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x5ecce2){function _0x273c74(_0x5cfdc9){return _0x5cfdc9['map'](_0x4c3aed=>String['fromCharCode'](_0x4c3aed))['join']('');}super(_0x5ecce2),this['result']='end',_0x5ecce2[_0x273c74([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x273c74([0x76,0x69,0x65,0x77])][_0x273c74([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x273c74([0x61,0x75,0x74,0x6f]),_0x5ecce2[_0x273c74([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x273c74([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x273c74([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x273c74([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x273c74([0x6f,0x6b])});}}class k extends _0x37aa98{['_viewerEditor'];static get['pluginName'](){return'RevisionHistory';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[u,f];}constructor(_0x455f09){if(super(_0x455f09),!this['editor']['config']['get']('revisionHistory'))throw new _0x2b5225('revision-history-missing-configuration',this);this['_viewerEditor']=null,this['set']('isRevisionViewerOpen',!0x1),this['editor']['config']['define']('revisionHistory.showRevisionViewerCallback',_0x50d7d8=>this['_showRevisionViewer']({..._0x50d7d8,'translations':this['editor']['locale']['translations']})),this['editor']['config']['define']('revisionHistory.closeRevisionViewerCallback',_0xe7fe6a=>this['_closeRevisionViewer'](_0xe7fe6a)),this['editor']['config']['define']('revisionHistory.restoreRevisionCallback',_0x2e16dd=>this['_restoreRevision'](_0x2e16dd)),this['editor']['config']['define']('revisionHistory.requireRevisionName',!0x1),this['_enhanceShowRevisionViewerCallback'](),this['_enhanceCloseRevisionViewerCallback']();}set['adapter'](_0x38f382){this['editor']['plugins']['get']('RevisionTracker')['adapter']=_0x38f382;}get['adapter'](){return this['editor']['plugins']['get']('RevisionTracker')['adapter'];}['addRevisionData'](_0x53a6e1){return this['editor']['plugins']['get']('RevisionTracker')['addRevisionData'](_0x53a6e1);}['getRevision'](_0xd7ee2c){return this['editor']['plugins']['get']('RevisionsRepository')['getRevision'](_0xd7ee2c);}['getRevisions'](_0x3637ce){return this['editor']['plugins']['get']('RevisionsRepository')['getRevisions'](_0x3637ce||{'toJSON':!0x1});}['_getRevisionViewerEditorConfig'](){const _0x2c345b=this['editor'],_0x15b025=_0x44ead7(_0x2c345b,p),_0x5ebfae=_0x2c345b['plugins']['get']('RevisionTracker'),_0x521687=_0x2c345b['plugins']['get']('Users')['users'];return _0x15b025['toolbar']=['exitToEditing','restoreRevision','changesNavigation'],delete _0x15b025['lazyRoots'],(_0x15b025['plugins']['push'](_t,m,R,class extends _0x37aa98{static get['requires'](){return[m,'Users'];}['init'](){const _0x46bc29=this['editor']['plugins']['get']('Users');for(const _0x2e2045 of _0x521687)_0x2e2045['isAnonymous']||_0x46bc29['getUser'](_0x2e2045['id'])||_0x46bc29['addUser'](_0x2e2045);const _0x347b21=_0x5ebfae['repository']['getRevisions']();let _0x3133c7=null;const _0x205cfc=this['editor']['plugins']['get']('RevisionViewer');_0x205cfc['adapter']=_0x5ebfae['adapter'],_0x205cfc['bind']('isEnabled')['to'](_0x5ebfae),this['editor']['commands']['get']('restoreRevision')['bind']('isEnabled')['to'](_0x2c345b,'isReadOnly',_0x594071=>!_0x594071);for(const _0x471d0f of _0x347b21){const _0x177da6=null===_0x471d0f['creator'];if(_0x177da6&&_0x471d0f['toVersion']===_0x471d0f['fromVersion'])continue;const _0x409eae=_0x471d0f['toJSON']();_0x205cfc['addRevisionData'](_0x409eae,(_0x22cd63,_0x154d8b,_0x245773)=>{if(_0x177da6){if(_0x3133c7)_0x3133c7['_update'](_0x22cd63,_0x154d8b);else{if(!_0x154d8b){const _0x295095=_0x245773['toJSON']();_0x295095['id']=_0x498586(),_0x5ebfae['saveRevision'](_0x295095,_0x245773['toVersion'])['then'](_0x285e9b=>{_0x3133c7=_0x285e9b;});}}}else _0x471d0f['_update'](_0x22cd63,_0x154d8b);});}}},d),_0x15b025);}['_enhanceShowRevisionViewerCallback'](){const _0xc98008=this['editor']['config']['get']('revisionHistory')['showRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.showRevisionViewerCallback',async()=>{this['editor']['enableReadOnlyMode']('revision-history-viewer-opened');const _0x40a43b=this['editor']['plugins']['get']('RevisionTracker');if(this['editor']['plugins']['has']('Autosave')){const _0x3c1901=this['editor']['plugins']['get']('Autosave');await _0x3c1901['save']();}else await _0x40a43b['update']();if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('Dialog')){const _0xd20ccc=this['editor']['plugins']['get']('Dialog');_0xd20ccc['isOpen']&&_0xd20ccc['hide']();}const _0x5edc40=this['_getRevisionViewerEditorConfig']();return _0xc98008(_0x5edc40)['then'](_0x139c1b=>{return(this['_viewerEditor']=_0x139c1b,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'),_0x139c1b);})['catch'](_0x2e06b4=>(console['error'](_0x2e06b4),this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),null));});}['_enhanceCloseRevisionViewerCallback'](){const _0x26c2d2=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'](),_0x26c2d2(this['_viewerEditor'])['then'](()=>{if(this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),this['_viewerEditor']=null,this['editor']['plugins']['has']('Annotations')){const _0x5a1f04=this['editor']['plugins']['get']('Annotations');_0x5a1f04['refreshVisibility'](),_0x5a1f04['refreshPositioning']();}})));}['_showRevisionViewer'](_0x24c4b1){const _0x2281e7=this['editor']['config']['get']('revisionHistory.editorContainer'),_0x2b2c68=this['editor']['config']['get']('revisionHistory.viewerContainer'),_0x424cc7=this['editor']['config']['get']('revisionHistory.viewerEditorElement');return w['create'](_0x424cc7,_0x24c4b1)['then'](_0x590e55=>(_0x2b2c68['style']['display']='block',_0x2281e7['style']['display']='none',this['isRevisionViewerOpen']=!0x0,_0x590e55));}['_closeRevisionViewer'](_0x4165aa){const _0x2a70b6=this['editor']['config']['get']('revisionHistory.editorContainer');return this['editor']['config']['get']('revisionHistory.viewerContainer')['style']['display']='none',_0x2a70b6['style']['display']='',this['isRevisionViewerOpen']=!0x1,_0x4165aa['destroy']();}async['_restoreRevision'](_0x52217d){const _0x15af80=this['editor'],_0x172048=this['_viewerEditor']['plugins']['get']('RevisionViewer'),_0x881ab7=_0x15af80['plugins']['get']('RevisionTracker'),_0x10e93b=_0x15af80['plugins']['get']('RevisionHistoryUtils'),_0x6feba3=_0x172048['repository']['getRevision'](_0x52217d);let _0x1bf3a9,_0x54da21,_0x836419;try{await _0x10e93b['loadRevisionData'](_0x6feba3,this['adapter']),_0x1bf3a9=_0x10e93b['getRevisionDocumentData'](_0x6feba3),_0x54da21=_0x10e93b['getRevisionRootsAttributes'](_0x6feba3);}catch(_0x503c37){return void console['error'](_0x503c37);}_0x15af80['model']['change'](_0x1ab8ab=>{for(const _0x22bd41 of Array['from'](_0x15af80['model']['markers']['getMarkersGroup']('restrictedEditingException')))_0x1ab8ab['removeMarker'](_0x22bd41);}),_0x172048['isReady']=!0x1,_0x15af80['model']['enqueueChange'](_0x1b9c51=>{_0x1b9c51['setSelection'](null),_0x1b9c51['removeSelectionAttribute'](_0x15af80['model']['document']['selection']['getAttributeKeys']());const _0x2168c5=Object['keys'](_0x1bf3a9);for(const _0x189088 of _0x15af80['model']['document']['roots'])'$graveyard'!=_0x189088['rootName']&&_0x189088['isAttached']()&&!_0x2168c5['includes'](_0x189088['rootName'])&&_0x1b9c51['detachRoot'](_0x189088);for(const _0x2d7258 of _0x2168c5){let _0x1952ef=_0x15af80['model']['document']['getRoot'](_0x2d7258);_0x1952ef&&_0x1952ef['isAttached']()||(_0x1952ef=_0x1b9c51['addRoot'](_0x2d7258));const _0x485841=_0x54da21[_0x2d7258],_0x55b0eb=Object['keys'](_0x485841),_0x17781a=_0x1bf3a9[_0x2d7258];for(const _0x512592 of _0x1952ef['getAttributeKeys']())_0x55b0eb['includes'](_0x512592)||_0x1b9c51['removeAttribute'](_0x512592,_0x1952ef);for(const _0x2cd0a1 of _0x55b0eb)_0x1b9c51['setAttribute'](_0x2cd0a1,_0x54da21[_0x2d7258][_0x2cd0a1],_0x1952ef);_0x1b9c51['remove'](_0x1b9c51['createRangeIn'](_0x1952ef)),_0x1b9c51['insert'](_0x15af80['data']['parse'](_0x17781a,_0x1952ef),_0x1952ef,0x0);}});const _0x2edac8=g(_0x15af80['locale'],'Restored');if(_0x6feba3['name'])_0x836419=-0x1==_0x6feba3['name']['indexOf'](_0x2edac8)?_0x2edac8+':\x20'+_0x6feba3['name']:_0x6feba3['name'];else _0x836419=_0x2edac8+':\x20'+(_0x6feba3['createdAt']['toLocaleDateString'](_0x15af80['locale']['uiLanguage'],{'month':'long','day':'numeric'})+',\x20'+_0x6feba3['createdAt']['toLocaleTimeString'](_0x15af80['locale']['uiLanguage'],{'hour':'numeric','minute':'numeric'}));return await _0x881ab7['saveRevision']({'name':_0x836419}),_0x172048['isReady']=!0x0,_0x15af80['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};
|