@ckeditor/ckeditor5-revision-history 47.4.0-alpha.6 → 47.4.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 +7 -7
- package/package.json +12 -12
- package/src/ui/revision/createrevisionactionsdropdown.js +1 -1
- package/src/ui/revision/revisionauthorview.js +1 -1
- package/src/ui/revision/revisionnameview.js +1 -1
- package/src/ui/revision/revisionview.js +2 -2
- package/src/ui/revision/subrevisioncollapserview.js +1 -1
- package/src/ui/revision/subrevisionview.js +1 -1
- package/src/ui/revisionhistory/revisionhistorysaverevisionformview.js +2 -2
- package/src/ui/revisionhistory/revisionhistoryui.js +1 -1
- package/src/ui/revisionssidebar/revisionssidebar.js +1 -1
- package/src/ui/revisionssidebar/revisionssidebarheaderview.js +1 -1
- package/src/ui/revisionssidebar/revisionssidebartimeperiodview.js +1 -1
- package/src/ui/revisionssidebar/revisionssidebarview.js +1 -1
- package/src/ui/revisionviewer/changedetailsview.js +1 -1
- package/src/ui/revisionviewer/changesnavigationview.js +1 -1
- package/src/ui/revisionviewer/revisionviewerui.js +1 -1
package/dist/index.js
CHANGED
|
@@ -20,11 +20,11 @@
|
|
|
20
20
|
*
|
|
21
21
|
*
|
|
22
22
|
*/
|
|
23
|
-
import{ObservableMixin as
|
|
24
|
-
_0x1deb7c(){['id'];['creator'];['authors'];['diffData'];['toVersion'];['fromVersion'];['model'];constructor(_0x44d79f){super(),this['id']=_0x44d79f['id']||_0x6a7f74(),this['creator']=_0x44d79f['creator']||null,this['authors']=_0x44d79f['authors']||[],this['diffData']=_0x44d79f['diffData']||null,this['toVersion']=_0x44d79f['toVersion']||0x0,this['fromVersion']=_0x44d79f['fromVersion']||0x0,this['set']('name',_0x44d79f['name']||''),this['set']('createdAt',_0x44d79f['createdAt']||new Date()),this['set']('attributes',_0x44d79f['attributes']||{});}['setName'](_0x17a632){this['_update']({'name':_0x17a632});}['setAttribute'](_0x2c4065,_0x1f24bf){const _0x175fcd=_0x52aca2(this['attributes']);_0x1fe81a(_0x175fcd,_0x2c4065,_0x1f24bf),this['_update']({'attributes':_0x175fcd});}['removeAttribute'](_0x2d13dc){const _0x2374e5=_0x52aca2(this['attributes']);_0x5811e9(_0x2374e5,_0x2d13dc),this['_update']({'attributes':_0x2374e5});}['_update'](_0xc1948e,_0x4a0fff=!0x1){let _0x4792a0=!0x1;const _0x36c3b7={'id':this['id']},_0x44df0f=['name','createdAt','diffData','authors','attributes','toVersion','fromVersion','creatorId'];for(const _0x4779ea of _0x44df0f){const _0x2e81e4=_0xc1948e[_0x4779ea];void 0x0!==_0x2e81e4&&_0x2e81e4!==this[_0x4779ea]&&(this[_0x4779ea]=_0x2e81e4,_0x36c3b7[_0x4779ea]=_0x2e81e4,_0x4792a0=!0x0);}_0x4792a0&&(_0x36c3b7['authors']&&(_0x36c3b7['authorsIds']=_0x36c3b7['authors']['map'](_0x1ef235=>_0x1ef235['id']),delete _0x36c3b7['authors']),this['fire']('_update',_0x36c3b7,_0x4a0fff));}['toJSON'](){return{'id':this['id'],'name':this['name'],'creatorId':this['creator']?this['creator']['id']:null,'authorsIds':this['authors']['map'](_0x2645b8=>_0x2645b8['id']),'diffData':this['diffData'],'createdAt':this['createdAt'],'attributes':this['attributes'],'fromVersion':this['fromVersion'],'toVersion':this['toVersion']};}}class S extends _0x9e7f10{['_revisions'];static get['requires'](){return[_0x143e17];}static get['pluginName'](){return'RevisionsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['length'](){return this['_revisions']['length'];}constructor(_0x42c567){super(_0x42c567),this['_revisions']=new _0x99deee();}['afterInit'](){!async function(_0x311eea){const _0x113ccf=_0x57deb2([0x76,0x73,0x6d,0x4c,0x34,0x54,0x50,0x70,0x75,0x52,0x35,0x33,0x4d,0x6c,0x71,0x53,0x6a,0x32,0x56,0x58,0x77,0x48,0x39,0x6f,0x45,0x41,0x4e,0x38,0x46,0x78,0x4a,0x74,0x47,0x55,0x4f,0x64,0x62,0x44,0x43,0x5a,0x30,0x31,0x69,0x68,0x79,0x66,0x6b,0x42,0x51,0x59,0x36,0x61,0x63,0x67,0x7a,0x37,0x72,0x49,0x65,0x57,0x4b,0x6e]),_0x296e9d=0xeb829,_0x424352=0x359e09b0,_0x332e8a=0x35997778^_0x424352,_0xe4bb36=window[_0x57deb2([0x44,0x61,0x74,0x65])][_0x57deb2([0x6e,0x6f,0x77])](),_0x189433=_0x311eea[_0x57deb2([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x908a9=new window[(_0x57deb2([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x42be1c=>{_0x189433[_0x57deb2([0x6f,0x6e,0x63,0x65])](_0x57deb2([0x72,0x65,0x61,0x64,0x79]),_0x42be1c);}),_0x369392={[_0x57deb2([0x6b,0x74,0x79])]:_0x57deb2([0x45,0x43]),[_0x57deb2([0x75,0x73,0x65])]:_0x57deb2([0x73,0x69,0x67]),[_0x57deb2([0x63,0x72,0x76])]:_0x57deb2([0x50,0x2d,0x32,0x35,0x36]),[_0x57deb2([0x78])]:_0x57deb2([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]),[_0x57deb2([0x79])]:_0x57deb2([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]),[_0x57deb2([0x61,0x6c,0x67])]:_0x57deb2([0x45,0x53,0x32,0x35,0x36])},_0x42ad63=_0x189433[_0x57deb2([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x57deb2([0x67,0x65,0x74])](_0x57deb2([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x46d763(){let _0x2328f7,_0x1812b0=null,_0x1f144c=null;try{if(_0x42ad63==_0x57deb2([0x47,0x50,0x4c]))return _0x57deb2([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x2328f7=_0x5973cb(),!_0x2328f7)return _0x57deb2([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x2328f7[_0x57deb2([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x1f144c=_0x240133(_0x2328f7[_0x57deb2([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x2328f7[_0x57deb2([0x6a,0x74,0x69])])),await _0x14b9a0()?_0x2f8031()?_0x18ef77()?_0x57deb2([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x196420()?(_0x2328f7[_0x57deb2([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x57deb2([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x1812b0=_0x554315(_0x57deb2([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),await _0x2a6959()):_0x57deb2([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x57deb2([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x57deb2([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch{return _0x57deb2([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x18ef77(){const _0x27d6cd=[_0x57deb2([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x57deb2([0x74,0x72,0x69,0x61,0x6c])][_0x57deb2([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x2328f7[_0x57deb2([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0xe4bb36/0x3e8:0xe10*_0x332e8a;return _0x2328f7[_0x57deb2([0x65,0x78,0x70])]<_0x27d6cd;}function _0x2f8031(){const _0x4d9b27=_0x2328f7[_0x57deb2([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x4d9b27)return!0x1;if(_0x4d9b27[_0x57deb2([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x57deb2([0x2a])))return!0x0;if(_0x4d9b27[_0x57deb2([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x57deb2([0x52,0x48])))return!0x0;if(_0x4d9b27[_0x57deb2([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x57deb2([0x52,0x52,0x48]))){if(_0x296924())return!0x0;if(_0x524c16()||_0x217a93())return!0x0;}return!0x1;}function _0x196420(){const _0x30c6d2=_0x2328f7[_0x57deb2([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x30c6d2||0x0==_0x30c6d2[_0x57deb2([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x13b07c}=new URL(window[_0x57deb2([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x30c6d2[_0x57deb2([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x13b07c))return!0x0;const _0x55c8d7=_0x13b07c[_0x57deb2([0x73,0x70,0x6c,0x69,0x74])](_0x57deb2([0x2e]));return _0x30c6d2[_0x57deb2([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x508927=>_0x508927[_0x57deb2([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x57deb2([0x2a])))[_0x57deb2([0x6d,0x61,0x70])](_0x5bf57b=>_0x5bf57b[_0x57deb2([0x73,0x70,0x6c,0x69,0x74])](_0x57deb2([0x2e])))[_0x57deb2([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x2e3e5c=>_0x2e3e5c[_0x57deb2([0x6c,0x65,0x6e,0x67,0x74,0x68])]<=_0x55c8d7[_0x57deb2([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x57deb2([0x6d,0x61,0x70])](_0x408832=>Array(_0x55c8d7[_0x57deb2([0x6c,0x65,0x6e,0x67,0x74,0x68])]-_0x408832[_0x57deb2([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x57deb2([0x66,0x69,0x6c,0x6c])](_0x408832[0x0]===_0x57deb2([0x2a])?_0x57deb2([0x2a]):'')[_0x57deb2([0x63,0x6f,0x6e,0x63,0x61,0x74])](_0x408832))[_0x57deb2([0x73,0x6f,0x6d,0x65])](_0x346c48=>_0x55c8d7[_0x57deb2([0x65,0x76,0x65,0x72,0x79])]((_0x408402,_0x1a9f0f)=>_0x346c48[_0x1a9f0f]===_0x408402||_0x346c48[_0x1a9f0f]===_0x57deb2([0x2a])));}function _0x2a6959(){return _0x1812b0&&_0x1f144c?new window[(_0x57deb2([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x1efd14,_0x40eb0f)=>{_0x1812b0[_0x57deb2([0x74,0x68,0x65,0x6e])](_0x1efd14,_0x40eb0f),_0x1f144c[_0x57deb2([0x74,0x68,0x65,0x6e])](_0x2a5ed=>{_0x2a5ed!=_0x57deb2([0x56,0x61,0x6c,0x69,0x64])&&_0x1efd14(_0x2a5ed);},_0x40eb0f);}):_0x1812b0||_0x1f144c||_0x57deb2([0x56,0x61,0x6c,0x69,0x64]);}}function _0x240133(_0x1c5f86,_0x4b6188){return new window[(_0x57deb2([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x388743=>{if(_0x1df675())return _0x388743(_0x57deb2([0x56,0x61,0x6c,0x69,0x64]));_0x343bc6(),_0x189433[_0x57deb2([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x57deb2([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0xb34cc=!0x1;const _0x365b57=_0x6a7f74();function _0x104844(_0x5a3469){return!!_0x5a3469&&(typeof _0x5a3469===_0x57deb2([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x5a3469===_0x57deb2([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x5a3469[_0x57deb2([0x74,0x68,0x65,0x6e])]===_0x57deb2([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x5a3469[_0x57deb2([0x63,0x61,0x74,0x63,0x68])]===_0x57deb2([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x23a148(_0x3b3800){_0x123a1e(_0x3b3800)[_0x57deb2([0x74,0x68,0x65,0x6e])](_0x4e2c4f=>{if(!_0x4e2c4f||_0x4e2c4f[_0x57deb2([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x57deb2([0x6f,0x6b]))return _0x57deb2([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x1550ec(_0x1149cf(_0x365b57+_0x4b6188))!=_0x4e2c4f[_0x57deb2([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x57deb2([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x57deb2([0x56,0x61,0x6c,0x69,0x64]);})[_0x57deb2([0x74,0x68,0x65,0x6e])](_0x5de155=>(_0x56dab3(),_0x5de155),()=>{const _0x5d0db8=_0x274a48();return null==_0x5d0db8?(_0x56dab3(),_0x57deb2([0x56,0x61,0x6c,0x69,0x64])):_0x57deb2(_0xe4bb36-_0x5d0db8>(0x11928db0^_0x424352)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x57deb2([0x74,0x68,0x65,0x6e])](_0x388743)[_0x57deb2([0x63,0x61,0x74,0x63,0x68])](()=>{_0x388743(_0x57deb2([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x2aa6c7=0x35a8e730^_0x424352;function _0x56dab3(){const _0x447ef6=_0x57deb2([0x6c,0x6c,0x63,0x74,0x2d])+_0x1550ec(_0x1149cf(_0x1c5f86)),_0x1adb85=_0x55adcc(_0x1550ec(window[_0x57deb2([0x4d,0x61,0x74,0x68])][_0x57deb2([0x63,0x65,0x69,0x6c])](_0xe4bb36/_0x2aa6c7)));window[_0x57deb2([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x57deb2([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x447ef6,_0x1adb85);}function _0x274a48(){const _0x336d26=_0x57deb2([0x6c,0x6c,0x63,0x74,0x2d])+_0x1550ec(_0x1149cf(_0x1c5f86)),_0x519b3c=window[_0x57deb2([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x57deb2([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x336d26);return _0x519b3c?window[_0x57deb2([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x55adcc(_0x519b3c),0x10)*_0x2aa6c7:null;}function _0x123a1e(_0x1b0ca5){return new window[(_0x57deb2([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x4a82be,_0x2000ce)=>{_0x1b0ca5[_0x57deb2([0x74,0x68,0x65,0x6e])](_0x4a82be,_0x2000ce),window[_0x57deb2([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x2000ce,0x359fdd70^_0x424352);});}}_0x189433[_0x57deb2([0x6f,0x6e])](_0x57deb2([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x32d9bc,_0xd0588)=>{if(_0xd0588[0x0]!=_0x1c5f86)return _0x388743(_0x57deb2([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0xd0588[0x1]={..._0xd0588[0x1],[_0x57deb2([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x365b57};},{[_0x57deb2([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x57deb2([0x68,0x69,0x67,0x68])}),_0x189433[_0x57deb2([0x6f,0x6e])](_0x57deb2([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x481ba7=>{_0x104844(_0x481ba7[_0x57deb2([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0xb34cc=!0x0,_0x23a148(_0x481ba7[_0x57deb2([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x57deb2([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x57deb2([0x6c,0x6f,0x77])}),_0x908a9[_0x57deb2([0x74,0x68,0x65,0x6e])](()=>{_0xb34cc||_0x388743(_0x57deb2([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x1df675(){return _0x189433[_0x57deb2([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x57deb2([0x76,0x69,0x65,0x77])][_0x57deb2([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x57deb2([0x61,0x75,0x74,0x6f]);}function _0x343bc6(){_0x189433[_0x57deb2([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x57deb2([0x76,0x69,0x65,0x77])][_0x57deb2([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x57deb2([0x61,0x75,0x74,0x6f]);}}function _0x554315(_0x187e6d){const _0x2f7499=[new window[(_0x57deb2([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x2264de=>setTimeout(_0x2264de,0x3597377c^_0x424352)),_0x908a9[_0x57deb2([0x74,0x68,0x65,0x6e])](()=>new window[(_0x57deb2([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x3d8178=>{const _0x255215=0x359e09b7^_0x424352,_0xc6dda8=_0x311eea[_0x57deb2([0x5f,0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x73])];function _0x50095f(){_0xc6dda8[_0x57deb2([0x6c,0x65,0x6e,0x67,0x74,0x68])]>=_0x255215&&_0x3d8178();}_0x50095f(),_0xc6dda8[_0x57deb2([0x6f,0x6e])](_0x57deb2([0x61,0x64,0x64]),_0x50095f);})),new window[(_0x57deb2([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x3f5b4d=>{function _0xee5ab2(){for(const _0x185636 in window)if(window[_0x57deb2([0x4e,0x75,0x6d,0x62,0x65,0x72])]['isNaN'](window[_0x57deb2([0x4e,0x75,0x6d,0x62,0x65,0x72])](_0x185636))&&window[_0x185636]==_0x296e9d)return _0x3f5b4d();_0x189433[_0x57deb2([0x73,0x74,0x61,0x74,0x65])]!=_0x57deb2([0x64,0x65,0x73,0x74,0x72,0x6f,0x79,0x65,0x64])&&window[_0x57deb2([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0xee5ab2,0x359e1a38^_0x424352);}_0x3c49c8(_0x57deb2([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))&&_0xee5ab2();})];return window[_0x57deb2([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x57deb2([0x72,0x61,0x63,0x65])](_0x2f7499)[_0x57deb2([0x74,0x68,0x65,0x6e])](()=>_0x187e6d);}async function _0x231d16(){if(await _0x908a9,_0x3c49c8(_0x57deb2([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))){const _0x51da70=_0x311eea[_0x57deb2([0x67,0x65,0x74,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](0x0),_0x43d550=_0x311eea[_0x57deb2([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])](_0x51da70[_0x57deb2([0x69,0x64])]),_0x5c3058=_0x4f17be(_0x57deb2([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]));return await _0x5c3058[_0x57deb2([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])](_0x51da70['id'],_0x43d550?_0x43d550['id']:null,!0x0),_0x5c3058[_0x57deb2([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x57deb2([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x5c3058[_0x57deb2([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x5c3058[_0x57deb2([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])]=_0x452c5e,void(_0x5c3058[_0x57deb2([0x5f,0x67,0x65,0x74,0x44,0x69,0x66,0x66])]=_0x452c5e);}if(_0x3c49c8(_0x57deb2([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]))){const _0x5df439=_0x4f17be(_0x57deb2([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]));_0x5df439[_0x57deb2([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x57deb2([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x5df439[_0x57deb2([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x5df439[_0x57deb2([0x75,0x70,0x64,0x61,0x74,0x65])]=_0x452c5e,_0x5df439[_0x57deb2([0x73,0x61,0x76,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])]=_0x452c5e;}_0x189433[_0x57deb2([0x6d,0x6f,0x64,0x65,0x6c])][_0x57deb2([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x452c5e,_0x189433[_0x57deb2([0x6d,0x6f,0x64,0x65,0x6c])][_0x57deb2([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x452c5e,_0x189433[_0x57deb2([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x57deb2([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x296924(){return _0x3c49c8(_0x57deb2([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x4f17be(_0x57deb2([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x57deb2([0x73,0x74,0x61,0x74,0x65])]==_0x57deb2([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x524c16(){return _0x3c49c8(_0x57deb2([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 _0x217a93(){return _0x3c49c8(_0x57deb2([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0x29d626(_0x4e2b2d){const _0x4a47a6=_0x3969c3();_0x189433[_0x4a47a6]=_0x57deb2([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])+_0x4e2b2d,_0x4e2b2d[_0x57deb2([0x65,0x6e,0x64,0x73,0x57,0x69,0x74,0x68])](_0x57deb2([0x4c,0x69,0x6d,0x69,0x74]))&&(window[_0x3969c3()]=_0x296e9d),_0x4e2b2d!=_0x57deb2([0x56,0x61,0x6c,0x69,0x64])&&_0x231d16();}function _0x3969c3(){const _0x4688a0=window[_0x57deb2([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x57deb2([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x57deb2([0x6e,0x6f,0x77])]())[_0x57deb2([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x57deb2([0x2e]),'');let _0x4c803f=_0x57deb2([0x76]);for(let _0xde9470=0x0;_0xde9470<_0x4688a0[_0x57deb2([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0xde9470+=0x2){let _0x272622=window[_0x57deb2([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x4688a0[_0x57deb2([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0xde9470,_0xde9470+0x2));_0x272622>=_0x113ccf[_0x57deb2([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x272622-=_0x113ccf[_0x57deb2([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x4c803f+=_0x113ccf[_0x272622];}return _0x4c803f;}function _0x5973cb(){const _0x299b9d=_0x42ad63[_0x57deb2([0x73,0x70,0x6c,0x69,0x74])](_0x57deb2([0x2e]));if(0x3!=_0x299b9d[_0x57deb2([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x2675ec(_0x299b9d[0x1]);function _0x2675ec(_0x58066b){const _0x3ec438=_0x2ee559(_0x58066b);return _0x3ec438&&_0x56c775()?_0x3ec438:null;function _0x56c775(){const _0x4aaedf=_0x3ec438[_0x57deb2([0x6a,0x74,0x69])],_0x3c9acb=window[_0x57deb2([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x4aaedf[_0x57deb2([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x4aaedf[_0x57deb2([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x122f3c={..._0x3ec438,[_0x57deb2([0x6a,0x74,0x69])]:_0x4aaedf[_0x57deb2([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x4aaedf[_0x57deb2([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x122f3c[_0x57deb2([0x76,0x63])],_0x1149cf(_0x122f3c)==_0x3c9acb;}}}async function _0x14b9a0(){let _0x512021=!0x0;try{const _0x45308a=_0x42ad63[_0x57deb2([0x73,0x70,0x6c,0x69,0x74])](_0x57deb2([0x2e])),[_0x308d8c,_0x149a96,_0x35fc3f]=_0x45308a;return _0x3339f9(_0x308d8c),await _0x5f00d3(_0x308d8c,_0x149a96,_0x35fc3f),_0x512021;}catch{return!0x1;}function _0x3339f9(_0x47c8d8){const _0x494a2a=_0x2ee559(_0x47c8d8);_0x494a2a&&_0x494a2a[_0x57deb2([0x61,0x6c,0x67])]==_0x57deb2([0x45,0x53,0x32,0x35,0x36])||(_0x512021=!0x1);}async function _0x5f00d3(_0x20cd1a,_0xccd0b4,_0x1ba433){const _0x2e2eda=window[_0x57deb2([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x57deb2([0x66,0x72,0x6f,0x6d])](_0x471a06(_0x1ba433),_0x3da12a=>_0x3da12a[_0x57deb2([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x3d7889=new window[(_0x57deb2([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x57deb2([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x20cd1a+_0x57deb2([0x2e])+_0xccd0b4),_0x13b0b9=window[_0x57deb2([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x57deb2([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x13b0b9)return;const _0x19e83=await _0x13b0b9[_0x57deb2([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x57deb2([0x6a,0x77,0x6b]),_0x369392,{[_0x57deb2([0x6e,0x61,0x6d,0x65])]:_0x57deb2([0x45,0x43,0x44,0x53,0x41]),[_0x57deb2([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x57deb2([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x57deb2([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x13b0b9[_0x57deb2([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x57deb2([0x6e,0x61,0x6d,0x65])]:_0x57deb2([0x45,0x43,0x44,0x53,0x41]),[_0x57deb2([0x68,0x61,0x73,0x68])]:{[_0x57deb2([0x6e,0x61,0x6d,0x65])]:_0x57deb2([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x19e83,_0x2e2eda,_0x3d7889)||(_0x512021=!0x1);}}function _0x2ee559(_0x68205e){return _0x68205e[_0x57deb2([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x57deb2([0x65,0x79]))?JSON[_0x57deb2([0x70,0x61,0x72,0x73,0x65])](_0x471a06(_0x68205e)):null;}function _0x471a06(_0x3fc97d){return window[_0x57deb2([0x61,0x74,0x6f,0x62])](_0x3fc97d[_0x57deb2([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x57deb2([0x2b]))[_0x57deb2([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x57deb2([0x2f])));}function _0x1149cf(_0x4b0860){let _0x271bdc=0x1505;function _0x2317aa(_0xcc7b9a){for(let _0x1bd3a3=0x0;_0x1bd3a3<_0xcc7b9a[_0x57deb2([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x1bd3a3++){const _0x4da293=_0xcc7b9a[_0x57deb2([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x1bd3a3);_0x271bdc=(_0x271bdc<<0x5)+_0x271bdc+_0x4da293,_0x271bdc&=_0x271bdc;}}function _0x260eee(_0x5e24c3){Array[_0x57deb2([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x5e24c3)?_0x5e24c3[_0x57deb2([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x260eee):_0x5e24c3&&typeof _0x5e24c3==_0x57deb2([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x57deb2([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x5e24c3)[_0x57deb2([0x73,0x6f,0x72,0x74])]()[_0x57deb2([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x4e58c1,_0x4e718b])=>{_0x2317aa(_0x4e58c1),_0x260eee(_0x4e718b);}):_0x2317aa(window[_0x57deb2([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x5e24c3));}return _0x260eee(_0x4b0860),_0x271bdc>>>0x0;}function _0x1550ec(_0x133e8a){return _0x133e8a[_0x57deb2([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x57deb2([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x57deb2([0x30]));}function _0x55adcc(_0x203f68){return _0x203f68[_0x57deb2([0x73,0x70,0x6c,0x69,0x74])]('')[_0x57deb2([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x57deb2([0x6a,0x6f,0x69,0x6e])]('');}function _0x3c49c8(_0x36f69b){return _0x189433[_0x57deb2([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x57deb2([0x68,0x61,0x73])](_0x36f69b);}function _0x4f17be(_0x3e7fa6){return _0x189433[_0x57deb2([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x57deb2([0x67,0x65,0x74])](_0x3e7fa6);}function _0x452c5e(){}function _0x57deb2(_0x5dd7b0){return _0x5dd7b0['map'](_0xd3cdef=>String['fromCharCode'](_0xd3cdef))['join']('');}_0x29d626(await _0x46d763());}(this);}['createRevision'](_0x2cf0a4){const _0x11e5be=this['editor']['plugins']['get']('Users');return new I({'id':_0x2cf0a4['id'],'name':_0x2cf0a4['name'],'creator':_0x2cf0a4['creatorId']?_0x11e5be['getUser'](_0x2cf0a4['creatorId']):null,'diffData':_0x2cf0a4['diffData']||_0x2cf0a4['data'],'authors':_0x2cf0a4['authorsIds']['map'](_0x17d6a7=>_0x11e5be['getUser'](_0x17d6a7)),'createdAt':new Date(_0x2cf0a4['createdAt']),'attributes':_0x2cf0a4['attributes'],'fromVersion':_0x2cf0a4['fromVersion'],'toVersion':_0x2cf0a4['toVersion']});}['addRevision'](_0x2fd32f,_0x24e3e6=0x0){this['_revisions']['add'](_0x2fd32f,_0x24e3e6);}['getRevision'](_0x50ed99){return this['_revisions']['get'](_0x50ed99);}['getRevisions'](_0x45f530={'toJSON':!0x1}){const _0x1b4d6c=Array['from'](this['_revisions']);return _0x1b4d6c['reverse'](),_0x45f530['toJSON']?_0x1b4d6c['map'](_0x5c3d90=>_0x5c3d90['toJSON']()):_0x1b4d6c;}['getIndex'](_0xb41195){return this['_revisions']['getIndex'](_0xb41195);}['getEarlierVisibleRevision'](_0x3a0227){const [,_0x4008f9]=this['getRevisionsIterator'](_0x3a0227,{'direction':'earlier'});return _0x4008f9;}['getLaterVisibleRevision'](_0x122df7){const [,_0x4b3391]=this['getRevisionsIterator'](_0x122df7,{'direction':'later'});return _0x4b3391;}['getRevisionsInDiff'](_0x3c25f9){const _0x4ce6ba=[];for(const _0x105b11 of this['getRevisionsIterator'](_0x3c25f9['newRevisionId']))if(_0x4ce6ba['push'](_0x105b11),_0x105b11['id']===_0x3c25f9['oldRevisionId'])break;return _0x4ce6ba;}*['getRevisionsIterator'](_0x46fa86,{direction:_0x51552a='earlier',filter:_0x3b49dc=()=>!0x0}={}){const _0x59ed73='earlier'===_0x51552a?0x1:-0x1;let _0x25b4a9=this['_revisions']['get'](_0x46fa86),_0x229e33=this['getIndex'](_0x25b4a9);for(yield _0x25b4a9;_0x25b4a9;){if(_0x229e33+=_0x59ed73,_0x25b4a9=this['getRevision'](_0x229e33),!_0x25b4a9)return;_0x3b49dc(_0x25b4a9)&&(yield _0x25b4a9);}}}class $ extends _0x9e7f10{static get['pluginName'](){return'RevisionHistoryUtils';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['_viewClassToTypeChar']=new Map([[_0x2377ca,'c'],[_0x4dc800,'a'],[_0x71b5fe,'e'],[_0xadf836,'r'],[_0x3c2bbf,'u']]);['_typeCharToViewClass']=new Map([['c',_0x2377ca],['a',_0x4dc800],['e',_0x71b5fe],['r',_0xadf836],['u',_0x3c2bbf]]);async['loadRevisionData'](_0x3b2db2,_0x5acb49){if(_0x3b2db2['diffData']||!_0x5acb49)return;const _0x27c0e6=this['editor']['config']['get']('collaboration.channelId'),_0x3ef1a2=await _0x5acb49['getRevision']({'channelId':_0x27c0e6,'revisionId':_0x3b2db2['id']});_0x3b2db2['diffData']=_0x3ef1a2['diffData'];}['getRevisionDocumentData'](_0x44c8dd){const _0x3660b9={};for(const _0x5027ca in _0x44c8dd['diffData']){if(_0x44c8dd['diffData'][_0x5027ca]['attachChange']&&!_0x44c8dd['diffData'][_0x5027ca]['attachChange']['isAttached'])continue;const _0x55f703=this['_removeRevisionMarkers'](JSON['parse'](_0x44c8dd['diffData'][_0x5027ca]['insertions'])),_0xd07a2=this['editor']['editing']['view']['document'],_0x109c36=new _0xff354b(_0xd07a2,_0x55f703['map'](_0x16d016=>this['_getViewFromDiffObj'](_0x16d016,!0x1)));this['editor']['data']['processor']['useFillerType']('marked'),_0x3660b9[_0x5027ca]=this['editor']['data']['processor']['toData'](_0x109c36),this['editor']['data']['processor']['useFillerType']('default');}return _0x3660b9;}['getRevisionRootsAttributes'](_0x3e0fce){const _0x5eb1a2={};for(const _0x2ecd95 in _0x3e0fce['diffData'])_0x3e0fce['diffData'][_0x2ecd95]['attachChange']&&!_0x3e0fce['diffData'][_0x2ecd95]['attachChange']['isAttached']||(_0x5eb1a2[_0x2ecd95]=_0x3e0fce['diffData'][_0x2ecd95]['attributesAfter']||{});return _0x5eb1a2;}['_getTypeCharForViewElement'](_0x3b2f17){return this['_viewClassToTypeChar']['get'](_0x3b2f17['constructor']);}['_getViewFromDiffObj'](_0xb5e1ac,_0x58811c){const _0x28b15e=this['editor']['editing']['view']['document'];if('string'==typeof _0xb5e1ac)return new _0x5e4b91(_0x28b15e,_0xb5e1ac);{let _0x3a7d81,_0x36965b;_0x36965b='u'==_0xb5e1ac['type']||'r'==_0xb5e1ac['type']?[]:_0xb5e1ac['children']['map'](_0x3aced6=>this['_getViewFromDiffObj'](_0x3aced6,_0x58811c));const _0x4fddcc=this['_typeCharToViewClass']['get'](_0xb5e1ac['type'])||_0x4fdd5c,_0x4b4c68=this['editor']['data']['htmlProcessor']['domConverter'];if(_0x3a7d81=new _0x4fddcc(_0x28b15e,_0xb5e1ac['name'],_0xb5e1ac['attributes'],_0x36965b),'u'==_0xb5e1ac['type']&&_0xb5e1ac['children'][0x0]){const _0x39d51=_0xb5e1ac['children'][0x0];if(_0x3a7d81['render']=function(_0x102194){const _0x49adea=_0x102194['createElement']('div');return _0x49adea['innerHTML']=_0x39d51,_0x49adea['childNodes'][0x0];},_0x58811c){const _0x491ce5=new _0xff354b(_0x28b15e);_0x491ce5['_appendChild'](_0x3a7d81);const _0x52061f=Array['from'](_0x4b4c68['viewChildrenToDom'](_0x491ce5,{'bind':!0x1})),_0x20103b=_0x4b4c68['domDocument']['createElement']('div');_0x20103b['append'](..._0x52061f),_0x3a7d81=Array['from'](_0x4b4c68['domChildrenToView'](_0x20103b))[0x0];}}else{if('r'==_0xb5e1ac['type']&&_0xb5e1ac['children'][0x0]){const _0x57bf27=_0xb5e1ac['children'][0x0];if(_0x3a7d81['render']=function(_0x4406fb){_0x4406fb['innerHTML']=_0x57bf27;},_0x58811c){const _0x4dd89b=new _0xff354b(_0x28b15e);_0x4dd89b['_appendChild'](_0x3a7d81);const _0x41839a=Array['from'](_0x4b4c68['viewChildrenToDom'](_0x4dd89b,{'bind':!0x1})),_0x52ad71=_0x4b4c68['domDocument']['createElement']('div');_0x52ad71['append'](..._0x41839a);const _0x13ec3a=Array['from'](_0x4b4c68['domChildrenToView'](_0x52ad71));_0x13ec3a['length']>0x1?_0x3a7d81['_appendChild'](_0x13ec3a):_0x3a7d81=_0x13ec3a[0x0];}}}if(_0xb5e1ac['customProperties']){for(const [_0x2c1106,_0x285f52]of _0xb5e1ac['customProperties'])_0x3a7d81['_setCustomProperty'](_0x2c1106,_0x285f52);}const _0x5e5e3e=void 0x0===_0xb5e1ac['fillerOffset']?null:_0xb5e1ac['fillerOffset'];return null!==_0x5e5e3e&&(_0x3a7d81['getFillerOffset']=()=>_0x5e5e3e),_0x3a7d81;}}['_makeModelFromViewString'](_0xcde931){const _0x191578=JSON['parse'](_0xcde931),_0x3dfb40=this['editor']['editing']['view']['document'],_0x509ca1=new _0xff354b(_0x3dfb40,_0x191578['map'](_0x7ff4ba=>this['_getViewFromDiffObj'](_0x7ff4ba,!0x0)));return this['editor']['data']['toModel'](_0x509ca1);}['_removeRevisionMarkers'](_0x114441){return(_0x114441=_0x114441['filter'](_0x34daf2=>!_0x34daf2['name']||'revision-start'!==_0x34daf2['name']&&'revision-end'!==_0x34daf2['name']))['forEach'](_0x53370c=>{'string'!=typeof _0x53370c&&(_0x53370c['children']=this['_removeRevisionMarkers'](_0x53370c['children']),_0x53370c['attributes']=_0x53370c['attributes']['filter'](_0x1a8a81=>!_0x1a8a81[0x0]['startsWith']('data-revision-')));}),_0x114441;}}function m(_0x3ab19e,_0x30a9a7,_0x149cd9){const t=_0x3ab19e['t'];switch(_0x30a9a7){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'},_0x149cd9);case'X_OF_Y_CHANGES':return t({'string':'%0\x20of\x20%1','id':'X_OF_Y_CHANGES'},_0x149cd9);case'Show\x20previous\x20change':return t('Show\x20previous\x20change');case'Show\x20next\x20change':return t('Show\x20next\x20change');case'EDIT_X_OF_Y_REVISIONS':return t({'string':'Edit','id':'EDIT_X_OF_Y_REVISIONS'});case'Total':return t('Total');case'Revision\x20creator':return t('Revision\x20creator');case'Revision\x20author':return t('Revision\x20author');case'Revision\x20name':return t('Revision\x20name');case'Save\x20current\x20revision':return t('Save\x20current\x20revision');case'Accept':return t('Accept');case'Save':return t('Save');case'Cancel':return t('Cancel');case'Name\x20of\x20the\x20revision':return t('Name\x20of\x20the\x20revision');case'optional':return t('optional');case'PENDING_ACTION_REVISION_HISTORY':return t({'string':'Unsaved\x20change\x20in\x20revision\x20history.','id':'PENDING_ACTION_REVISION_HISTORY'});case'The\x20revision\x20name\x20cannot\x20be\x20empty.':return t('The\x20revision\x20name\x20cannot\x20be\x20empty.');case'Enter\x20the\x20revision\x20name':return t('Enter\x20the\x20revision\x20name');default:return'';}}class h extends _0x9e7f10{['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[_0x143e17,S,$,_0x5bec0e];}constructor(_0x1a98a7){super(_0x1a98a7),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 _0x2fae8c=_0x6a7f74();this['_source']={'history':this['editor']['model']['document']['history'],'getLatestVersion':()=>Promise['resolve'](this['editor']['model']['document']['version']),'getCurrentRevisionId':()=>_0x2fae8c},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 _0xb0b363=this['repository']['getRevision'](0x0),_0x358140=_0xb0b363&&null===_0xb0b363['creator']?_0xb0b363:null;if(this['_continueCurrentRevision']=!!_0x358140&&this['editor']['config']['get']('revisionHistory.resumeUnsavedRevision'),this['editor']['plugins']['has']('RealTimeCollaborationClient')){const _0x44ddcf=this['_source']['getCurrentRevisionId'](),_0x1cf5dc=this['repository']['getRevision'](_0x44ddcf);if(_0x1cf5dc)this['_startingVersion']=_0x1cf5dc['fromVersion'],this['_continueCurrentRevision']=!0x1;else{const _0x5e44a9=this['_source']['history']['_operations']['find'](_0x472547=>!_0x472547['_isInit']),_0x3049fc=_0x5e44a9?_0x5e44a9['baseVersion']:this['_source']['history']['version'];_0xb0b363?(_0xb0b363['toVersion']<_0x3049fc&&_0xb0b363['_update']({'toVersion':_0x3049fc}),this['_continueCurrentRevision']?(this['_source']['getCurrentRevisionId']=()=>_0x358140['id'],this['_startingVersion']=_0x358140['fromVersion']):(this['_startingVersion']=_0xb0b363['toVersion'],this['_continueCurrentRevision']=!0x1)):(this['_startingVersion']=_0x3049fc,this['_continueCurrentRevision']=!0x1);}}else _0x358140&&(this['editor']['model']['document']['history']['version']=Math['max'](_0x358140['toVersion'],this['editor']['model']['document']['history']['version']),_0x358140['fromVersion']===_0x358140['toVersion']?(0x0!==_0x358140['fromVersion']&&(this['_source']['getCurrentRevisionId']=()=>_0x358140['id']),this['_continueCurrentRevision']=!0x1):this['_continueCurrentRevision']&&(this['_source']['getCurrentRevisionId']=()=>_0x358140['id'],this['_startingVersion']=_0x358140['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',_0xb48857=>!_0xb48857),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x239a71=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x25de5d;for(const _0x5ca479 in _0x239a71){const _0x4f205d=_0x5ca479,_0x4bff0c=_0x239a71[_0x4f205d];if('revisionHistoryLicenseKeyValid'==_0x4bff0c||'revisionHistoryLicenseKeyInvalid'==_0x4bff0c||'revisionHistoryLicenseKeyExpired'==_0x4bff0c||'revisionHistoryLicenseKeyDomainLimit'==_0x4bff0c||'revisionHistoryLicenseKeyNotAllowed'==_0x4bff0c||'revisionHistoryLicenseKeyEvaluationLimit'==_0x4bff0c||'revisionHistoryLicenseKeyUsageLimit'==_0x4bff0c){delete _0x239a71[_0x4f205d],_0x25de5d=_0x4bff0c,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'revisionHistoryLicenseKeyInvalid'==_0x25de5d&&_0x239a71['_showLicenseError']('invalid'),'revisionHistoryLicenseKeyExpired'==_0x25de5d&&_0x239a71['_showLicenseError']('expired'),'revisionHistoryLicenseKeyDomainLimit'==_0x25de5d&&_0x239a71['_showLicenseError']('domainLimit'),'revisionHistoryLicenseKeyNotAllowed'==_0x25de5d&&_0x239a71['_showLicenseError']('featureNotAllowed','RevisionHistory'),'revisionHistoryLicenseKeyEvaluationLimit'==_0x25de5d&&_0x239a71['_showLicenseError']('evaluationLimit'),'revisionHistoryLicenseKeyUsageLimit'==_0x25de5d&&_0x239a71['_showLicenseError']('usageLimit');},0x3e8);}async['afterInit'](){if(this['repository']['length']>0x0){const _0x418e6f=this['repository']['getRevision'](0x0),_0x5451d9=await this['getRevisionDocumentData'](_0x418e6f),_0xff41d8=await this['getRevisionRootsAttributes'](_0x418e6f);this['_replaceEditorDataWithRevisionData'](_0x5451d9,_0xff41d8);}}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['setSource'](_0x3b64b1){this['_source']=_0x3b64b1;}async['update'](){const _0x399aaa=await this['_source']['getLatestVersion']();if(_0x399aaa>this['currentRevision']['toVersion']){await this['_loadState']();const _0x2100f1=this['buildRevisionData']({'revision':this['currentRevision'],'to':_0x399aaa});_0x2100f1['authors']=_0x2100f1['authorsIds']['map'](_0x2dc2b1=>this['editor']['plugins']['get']('Users')['getUser'](_0x2dc2b1)),this['currentRevision']['_update'](_0x2100f1);}}async['saveRevision'](_0xed2a61={},_0x1ae393=null){const _0x341dc7=[];await this['_loadState'](),this['_continueCurrentRevision']=!0x1,_0x1ae393>this['currentRevision']['toVersion']&&(_0x1ae393=null),null===_0x1ae393&&(_0x1ae393=await this['_source']['getLatestVersion']());const _0x1873c5=this['_getFromVersion'](_0x1ae393),_0x1fb8ac=this['buildRevisionData']({'from':_0x1873c5,'to':_0x1ae393});if(this['currentRevision']['toVersion']<_0x1ae393){const _0x3acfb7=this['buildRevisionData']({'revision':this['currentRevision'],'from':_0x1ae393,'to':_0x1ae393});_0x3acfb7['authors']=[],_0x3acfb7['authorsIds']=[],_0x3acfb7['id']=this['currentRevision']['id'],this['currentRevision']['_update'](_0x3acfb7,!0x0),delete _0x3acfb7['authors'],_0x341dc7['push'](_0x3acfb7);}_0xed2a61['creatorId']=this['editor']['plugins']['get']('Users')['me']['id'],_0xed2a61['name']=_0xed2a61['name']||null,_0xed2a61['id']=_0xed2a61['id']||_0x6a7f74(),_0xed2a61={..._0xed2a61,..._0x1fb8ac};const _0x211295=this['addRevisionData'](_0xed2a61);_0x341dc7['push'](_0xed2a61);const _0x25c019=this['repository']['getIndex'](_0x211295);if(0x0!==_0x25c019){const _0x25132a=this['repository']['getRevision'](_0x25c019-0x1);if(_0x25132a['fromVersion']!==_0x1ae393){const _0x1b7ef4=this['_revisionDataBuilder']['getData'](_0x1ae393,_0x25132a['toVersion']),_0x336aca={'id':_0x25132a['id'],'diffData':_0x1b7ef4['diffData'],'authorsIds':_0x1b7ef4['authorsIds'],'authors':_0x1b7ef4['authorsIds']['map'](_0x3fa2e0=>this['editor']['plugins']['get']('Users')['getUser'](_0x3fa2e0)),'fromVersion':_0x1ae393};_0x25132a===this['currentRevision']&&(_0x336aca['createdAt']=new Date(_0xed2a61['createdAt']['getTime']()+0xa)),_0x25132a['_update'](_0x336aca,!0x0),delete _0x336aca['authors'],_0x341dc7['push'](_0x336aca);}}if(this['adapter']){for(const _0x50ffa4 of _0x341dc7)this['_bufferUpdate'](_0x50ffa4['id'],_0x50ffa4,!0x0);this['sendBufferedUpdates']();}return _0x211295;}['addRevisionData'](_0x36f26f){const _0x13696f=this['repository']['createRevision'](_0x36f26f);return this['adapter']&&_0x13696f['on']('_update',(_0x23b395,_0x135cc2,_0x3caabd)=>{_0x3caabd||(this['_bufferUpdate'](_0x135cc2['id'],_0x135cc2,!0x0),this['sendBufferedUpdates']());}),this['repository']['addRevision'](_0x13696f,this['_findInsertionIndex'](_0x13696f)),_0x13696f;}async['getRevisionDocumentData'](_0x2b37a0){return await this['_utils']['loadRevisionData'](_0x2b37a0,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x2b37a0);}async['getRevisionRootsAttributes'](_0x2cbc34){return await this['_utils']['loadRevisionData'](_0x2cbc34,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x2cbc34);}['sendBufferedUpdates'](){if(0x0===this['_bufferedUpdates']['size'])return;if(this['_isPendingUpdate'])return;let _0x5d9d4e=Array['from'](this['_bufferedUpdates']['values']());this['_bufferedUpdates']['clear']();for(let _0xd2aa00=0x0;_0xd2aa00<_0x5d9d4e['length'];_0xd2aa00++){const _0x34d82a=_0x5d9d4e[_0xd2aa00];let _0x47ebc6=!0x1;for(const _0x3423fd of Object['keys'](_0x34d82a))void 0x0===_0x34d82a[_0x3423fd]?delete _0x34d82a[_0x3423fd]:'id'!==_0x3423fd&&(_0x47ebc6=!0x0);_0x47ebc6||(_0x5d9d4e[_0xd2aa00]=null);}if(_0x5d9d4e=_0x5d9d4e['filter'](_0x2ef6ca=>null!==_0x2ef6ca),!_0x5d9d4e['length'])return;for(let _0x1a18e2=0x0;_0x1a18e2<_0x5d9d4e['length'];_0x1a18e2++){const _0x14906f=_0x5d9d4e[_0x1a18e2];void 0x0!==_0x14906f['fromVersion']&&void 0x0===_0x14906f['toVersion']&&(_0x14906f['toVersion']=this['repository']['getRevision'](_0x14906f['id'])['toVersion']),void 0x0!==_0x14906f['toVersion']&&void 0x0===_0x14906f['fromVersion']&&(_0x14906f['fromVersion']=this['repository']['getRevision'](_0x14906f['id'])['fromVersion']);}const _0x58f111=this['editor']['config']['get']('collaboration.channelId');this['_isPendingUpdate']=!0x0,this['_addPendingAction'](),this['adapter']['updateRevisions'](_0x5d9d4e,_0x58f111)['finally'](()=>{this['_isPendingUpdate']=!0x1;})['then'](_0x14ea05=>{if(_0x14ea05){for(const _0x2f4832 of _0x14ea05)this['setRevisionData']({'id':_0x2f4832['id'],'createdAt':_0x2f4832['createdAt']});}this['_removePendingAction'](),this['sendBufferedUpdates']();});}['buildRevisionData']({revision:_0x4c69df=null,from:_0x1317c6=null,to:_0x5065ee=null}){_0x1317c6=null!==_0x1317c6?_0x1317c6:_0x4c69df['fromVersion'],_0x5065ee=null!==_0x5065ee?_0x5065ee:_0x4c69df['toVersion'];const _0x4dcf54=this['_revisionDataBuilder']['getData'](_0x1317c6,_0x5065ee),_0x220cfc={'diffData':_0x4dcf54['diffData'],'authorsIds':_0x4dcf54['authorsIds'],'fromVersion':_0x1317c6,'toVersion':_0x5065ee};if(!_0x4c69df||_0x5065ee!==_0x4c69df['toVersion']){const _0x2b2ce3=_0x5065ee-0x1,_0x539007=this['_source']['history']['getOperation'](_0x2b2ce3);_0x220cfc['createdAt']=_0x539007&&_0x539007['createdAt']||new Date();}if(this['_loadedStateData']&&_0x1317c6===this['_loadedStateData']['fromVersion']){for(const _0x5ddf9f of this['_loadedStateData']['authors'])_0x220cfc['authorsIds']['includes'](_0x5ddf9f['id'])||_0x220cfc['authorsIds']['push'](_0x5ddf9f['id']);}return _0x220cfc;}['_bufferUpdate'](_0x23a494,_0xd888ac,_0x12668e){if(this['_bufferedUpdates']['has'](_0x23a494)){const _0x372113=this['_bufferedUpdates']['get'](_0x23a494);_0xd888ac=_0x12668e?{..._0x372113,..._0xd888ac}:{..._0xd888ac,..._0x372113};}this['_bufferedUpdates']['set'](_0x23a494,_0xd888ac);}['setRevisionData'](_0x119d95){const _0x29a59e=this['repository']['getRevision'](_0x119d95['id']);if(_0x119d95['createdAt']&&(_0x119d95['createdAt']=new Date(_0x119d95['createdAt'])),_0x119d95['authorsIds']){const _0x40d021=this['editor']['plugins']['get']('Users');_0x119d95['authors']=_0x119d95['authorsIds']['map'](_0x3298e7=>_0x40d021['getUser'](_0x3298e7));}_0x29a59e['_update'](_0x119d95,!0x0);}['_createInitialRevision'](_0x4a36f9){const _0xba0823=this['repository']['getRevision'](this['repository']['length']-0x1);if(_0xba0823)this['_initialRevisionId']=_0xba0823['id'];else{const _0x591cb1=!this['editor']['model']['document']['roots']['find'](_0x5b638e=>this['editor']['model']['hasContent'](_0x5b638e)),_0x1623c6=this['editor']['plugins']['get']('Users')['me']['id'],_0x4781ec=m(this['editor']['locale'],_0x591cb1?'Empty\x20document':'Initial\x20revision');this['_makeRevision']({'from':_0x4a36f9,'to':_0x4a36f9,'id':this['_initialRevisionId'],'name':_0x4781ec,'creatorId':_0x1623c6});}}['_createCurrentRevision'](_0x22517b){const _0x46ff5a=this['_source']['getCurrentRevisionId']();this['currentRevision']=this['repository']['getRevision'](_0x46ff5a),this['currentRevision']||(this['currentRevision']=this['_makeRevision']({'from':_0x22517b,'to':_0x22517b,'id':_0x46ff5a,'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'](_0x11e33d,_0x3b930e){let _0x1e64cf=this['editor']['config']['get']('initialData'),_0x3d1e46=this['editor']['config']['get']('rootsAttributes');if(void 0x0===_0x1e64cf){_0x1e64cf={};for(const _0x127a2c of this['editor']['model']['document']['getRootNames']())_0x1e64cf[_0x127a2c]='';}if('string'==typeof _0x1e64cf&&(_0x1e64cf={'main':_0x1e64cf}),void 0x0===_0x3d1e46){_0x3d1e46={};for(const _0x324043 of this['editor']['model']['document']['getRootNames']())_0x3d1e46[_0x324043]={};}let _0x86a45=!0x1;const _0x265104=Object['keys'](_0x1e64cf),_0xd6f76=Object['keys'](_0x11e33d);for(const _0x2c00e5 of _0x265104){if(_0x1e64cf[_0x2c00e5]!==_0x11e33d[_0x2c00e5]&&''!==_0x1e64cf[_0x2c00e5]['trim']()){_0x86a45=!0x0;break;}if(!_0xc17835(_0x3d1e46[_0x2c00e5],_0x3b930e[_0x2c00e5])&&Object['keys'](_0x3d1e46[_0x2c00e5])['length']>0x0){_0x86a45=!0x0;break;}}_0x86a45||(_0x86a45=_0xd6f76['some'](_0x37e557=>!this['editor']['model']['document']['getRoot'](_0x37e557))),_0x86a45&&_0x4f9ac5('editor-initial-data-replaced-with-revision-data',{'editorData':_0x1e64cf,'editorRootsAttributes':_0x3d1e46,'revisionData':_0x11e33d,'revisionRootsAttributes':_0x3b930e}),this['editor']['config']['set']('initialData',_0x11e33d),this['editor']['config']['set']('rootsAttributes',_0x3b930e);}['_addPendingAction'](){if(!this['_pendingAction']){const _0x19a8a1=this['editor']['plugins']['get']('PendingActions');this['_pendingAction']=_0x19a8a1['add'](m(this['editor']['locale'],'PENDING_ACTION_REVISION_HISTORY'));}}['_removePendingAction'](){this['_pendingAction']&&(this['editor']['plugins']['get']('PendingActions')['remove'](this['_pendingAction']),this['_pendingAction']=null);}['_findInsertionIndex'](_0x4413aa){const _0x1443fc=this['repository']['getRevisions']();_0x1443fc['reverse']();let _0x3490db=0x0;for(;_0x3490db<_0x1443fc['length'];){const _0x129251=_0x1443fc[_0x3490db];if(_0x129251===this['currentRevision']){_0x3490db++;continue;}if(_0x129251['id']===this['_initialRevisionId'])break;const _0x2bbb58=_0x4413aa['toVersion']-_0x129251['toVersion']||_0x4413aa['fromVersion']-_0x129251['fromVersion'];if(_0x2bbb58>0x0)break;if(_0x2bbb58<0x0)_0x3490db++;else{if(!_0x4413aa['creator']&&_0x129251['creator'])break;if(_0x129251['creator']||!_0x4413aa['creator']){if(_0x4413aa['createdAt']>_0x129251['createdAt'])break;_0x3490db++;}else _0x3490db++;}}return _0x3490db;}['_getFromVersion'](_0x316164){const _0x11c497=this['repository']['getRevisions']();_0x11c497['reverse'](),_0x11c497['shift']();const _0x3eb2bc=_0x11c497['find'](_0x51827f=>_0x51827f['toVersion']<=_0x316164)['toVersion'];return _0x3eb2bc<this['_startingVersion']?this['_startingVersion']:_0x3eb2bc;}['_makeRevision']({name:_0xe5a11d,from:_0x20e19b,to:_0x142296,creatorId:_0x19d3f1,id:_0x3b256a}){const _0x341429=this['buildRevisionData']({'from':_0x20e19b,'to':_0x142296});_0x341429['name']=_0xe5a11d,_0x341429['creatorId']=_0x19d3f1,_0x341429['id']=_0x3b256a;const _0x79f4fb=this['addRevisionData'](_0x341429);return this['adapter']&&this['_bufferUpdate'](_0x341429['id'],_0x341429,!0x0),_0x79f4fb;}['_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(_0x1b0c71){this['editor']=_0x1b0c71,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'](_0x1e4018){this['source']=_0x1e4018;const _0xa408ae=new Map(),_0x26ed88=new Map(),_0x3343e8=this['editor']['model']['document']['roots']['map'](_0x55ed03=>_0x55ed03['rootName']);for(const _0x453811 of _0x3343e8){const _0x1ff8f8=this['editor']['model']['document']['getRoot'](_0x453811),_0x3401bf=K(_0x1ff8f8);_0xa408ae['set'](_0x453811,_0x3401bf),_0x26ed88['set'](_0x453811,Object['fromEntries'](_0x1ff8f8['getAttributes']()));}const _0xc46a3e=Array['from'](this['editor']['model']['markers'])['map'](_0x16ee6a=>[_0x16ee6a['name'],_0x16ee6a['getRange']()]),_0x272b62=this['source']['version'];this['_saveMetaData'](_0x272b62,_0xa408ae,_0xc46a3e,_0x26ed88),this['_startingRevisionId']=this['_revisionId'];const _0x20bfb5=new Map(),_0x111804=new Map();for(const _0x57d09b of _0x3343e8){const _0x1843b6=N(_0x57d09b);_0x20bfb5['set'](_0x57d09b,_0x1843b6),_0x111804['set'](_0x57d09b,{});}this['_saveMetaData'](Number['NEGATIVE_INFINITY'],_0x20bfb5,[],_0x111804);}['getData'](_0x414f50,_0x2fe30a){if(this['_lastFrom']===_0x414f50&&this['_lastTo']<=_0x2fe30a)this['_savedMetaData']['size']>0x1&&this['_removeMetaData'](this['_lastTo']),this['_applyOperations'](this['_lastTo'],_0x2fe30a,!0x0);else{if(!this['_savedMetaData']['has'](_0x414f50)){const _0x13b20d=this['_getPreviousFrom'](_0x414f50);this['_calculateMetaData'](_0x13b20d,_0x414f50,!0x1);}this['_calculateMetaData'](_0x414f50,_0x2fe30a,!0x0);}return this['_lastFrom']=_0x414f50,this['_lastTo']=_0x2fe30a,this['_getState']();}['loadState'](_0x286f69){if(!this['_savedMetaData']['has'](_0x286f69['fromVersion'])){const _0x5ca71c=this['_getPreviousFrom'](_0x286f69['fromVersion']);this['_calculateMetaData'](_0x5ca71c,_0x286f69['fromVersion'],!0x1);}this['_calculateMetaData'](_0x286f69['fromVersion'],_0x286f69['toVersion'],!0x1);const _0x54e393=this['editor']['plugins']['get']('RevisionHistoryUtils');this['_reset'](),this['_lastFrom']=_0x286f69['fromVersion'],this['_lastTo']=_0x286f69['toVersion'];for(const _0x3ba798 in _0x286f69['diffData']){const _0x3f3ba8=_0x286f69['diffData'][_0x3ba798]['attachChange'],_0x5ef612=_0x52aca2(_0x286f69['diffData'][_0x3ba798]['attributesBefore'])||{},_0x165629=_0x54e393['_makeModelFromViewString'](_0x286f69['diffData'][_0x3ba798]['deletions']);_0x165629['rootName']=_0x3ba798,_0x165629['_isAttached']=!_0x3f3ba8||!_0x3f3ba8['isAttached'],_0x165629['isAttached']=()=>_0x165629['_isAttached'],this['_baseRoots']['set'](_0x3ba798,_0x165629),this['_baseRootsAttributes']['set'](_0x3ba798,_0x5ef612),_0x3f3ba8&&this['_touchedRoots']['set'](_0x3ba798,_0x3f3ba8);const _0x499257=this['_makeIdsRoot'](_0x165629);this['_baseIdsRoots']['set'](_0x3ba798,_0x499257);for(const [_0x115267,_0x40f947]of _0x165629['markers']){if(!_0x115267['startsWith']('revision:'))continue;const _0xb41d64=_0x115267['split'](':')[0x2];for(const _0x184a8c of _0x40f947['getWalker']({'singleCharacters':!0x0})){const _0x1ad1ae=this['_getVidAttributeName'](_0x184a8c),_0x55cf5a='elementEnd'==_0x184a8c['type']?_0x184a8c['previousPosition']['path']['slice'](0x0,-0x1):_0x184a8c['previousPosition']['path'],_0x3687f9=_0x499257['getNodeByPath'](_0x55cf5a)['getAttribute'](_0x1ad1ae);this['_touched']['set'](_0x3687f9,{'userId':_0xb41d64});}_0x165629['markers']['delete'](_0x115267);}}this['_startingRevisionId']=this['_revisionId'];const _0xa59a8e=[...Array(this['_revisionId'])['keys']()]['slice'](0x1)['filter'](_0x2937b7=>!this['_touched']['has'](_0x2937b7));let _0x296aa8=0x0;const _0x420042=new Map();for(const _0x103bdf in _0x286f69['diffData']){const _0xc9ce99=_0x286f69['diffData'][_0x103bdf]['attachChange'],_0xdab8bc=_0x52aca2(_0x286f69['diffData'][_0x103bdf]['attributesAfter'])||{},_0x572bee=_0x54e393['_makeModelFromViewString'](_0x286f69['diffData'][_0x103bdf]['insertions']);_0x572bee['rootName']=_0x103bdf,_0x572bee['_isAttached']=!_0xc9ce99||_0xc9ce99['isAttached'],_0x572bee['isAttached']=()=>_0x572bee['_isAttached'],this['_diffRoots']['set'](_0x103bdf,_0x572bee),this['_diffRootsAttributes']['set'](_0x103bdf,_0xdab8bc);const _0xe96bb5=this['_makeIdsRoot'](_0x572bee,Number['NEGATIVE_INFINITY']);this['_idsRoots']['set'](_0x103bdf,_0xe96bb5),_0x420042['set'](_0x103bdf,_0x572bee['isAttached']()?_0xdab8bc:{});for(const [_0x567264,_0x49277c]of _0x572bee['markers']){if(!_0x567264['startsWith']('revision:'))continue;const _0x18a188=_0x567264['split'](':')[0x2];for(const _0x2f943a of _0x49277c['getWalker']({'singleCharacters':!0x0})){const _0x2e4eaa=this['_getVidAttributeName'](_0x2f943a),_0x12e4ce=this['_revisionId']++,_0x409bad='elementEnd'==_0x2f943a['type']?_0x2f943a['previousPosition']['path']['slice'](0x0,-0x1):_0x2f943a['previousPosition']['path'];_0xe96bb5['getNodeByPath'](_0x409bad)['_setAttribute'](_0x2e4eaa,_0x12e4ce),this['_touched']['set'](_0x12e4ce,{'userId':_0x18a188});}_0x572bee['markers']['delete'](_0x567264);}for(const _0x1447ce of this['editor']['model']['createRangeIn'](_0x572bee)['getWalker']({'singleCharacters':!0x0})){const _0x2752f6=this['_getVidAttributeName'](_0x1447ce),_0x3f4420='elementEnd'==_0x1447ce['type']?_0x1447ce['previousPosition']['path']['slice'](0x0,-0x1):_0x1447ce['previousPosition']['path'],_0x45af1f=_0xe96bb5['getNodeByPath'](_0x3f4420);_0x45af1f['getAttribute'](_0x2752f6)>0x0||_0x45af1f['_setAttribute'](_0x2752f6,_0xa59a8e[_0x296aa8++]);}for(const [_0x55fef7,_0x294367]of _0x572bee['markers'])_0x55fef7['startsWith']('revision:')||this['_markers']['set'](_0x55fef7,_0x294367);}const {roots:_0x259b1a}=this['_savedMetaData']['get'](_0x286f69['fromVersion']),{roots:_0x22bfae}=this['_savedMetaData']['get'](_0x286f69['toVersion']),_0x40cf4d=K(_0x259b1a['get']('$graveyard'));this['_baseRoots']['set']('$graveyard',_0x40cf4d),this['_baseIdsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x40cf4d,Number['NEGATIVE_INFINITY']));const _0x2e5927=K(_0x22bfae['get']('$graveyard'));this['_diffRoots']['set']('$graveyard',_0x2e5927),this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x2e5927));const _0x3abb04=Array['from'](this['_diffRoots'])['map'](([_0x6bf5b3,_0x57fb83])=>[_0x6bf5b3,K(_0x57fb83)]);this['_saveMetaData'](this['_lastTo'],_0x3abb04,this['_markers'],_0x420042);}['reInit'](){this['_reset'](),this['_lastFrom']=-0x1,this['_lastTo']=-0x1,this['_savedMetaData']['clear'](),this['init'](this['source']);}['_saveMetaData'](_0x72955f,_0x447923,_0x3068c8,_0x34776a){const _0x3e4733=new Map(_0x447923),_0x84bd40=new Map(_0x52aca2(_0x34776a)),_0x53da19=new Map();for(const [_0x2112bd,_0x20c4b2]of _0x3068c8)_0x53da19['set'](_0x2112bd,{'start':_0x20c4b2['start']['clone'](),'end':_0x20c4b2['end']['clone'](),'rootName':_0x20c4b2['root']['rootName']});this['_savedMetaData']['set'](_0x72955f,{'roots':_0x3e4733,'markers':_0x53da19,'rootsAttributes':_0x84bd40});}['_removeMetaData'](_0x161ac8){this['_savedMetaData']['delete'](_0x161ac8);}['_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'](_0x15cdbc,_0x1b55ef=null){let _0x48bfb4=null;_0x15cdbc['is']('documentFragment')||(_0x48bfb4=new _0x45f0e1(_0x15cdbc['name'],{'vid_start':null===_0x1b55ef?this['_revisionId']++:_0x1b55ef++}));const _0x25c900=[];for(const _0xff58c8 of _0x15cdbc['getChildren']())if(_0xff58c8['is']('element')){_0x25c900['push'](this['_makeIdsRoot'](_0xff58c8,_0x1b55ef));const _0x749879=_0x25c900[_0x25c900['length']-0x1];null!==_0x1b55ef&&(_0x1b55ef=_0x749879['is']('element','$text')?_0x749879['getAttribute']('vid')+0x1:_0x749879['getAttribute']('vid_end')+0x1);}else{for(let _0x4a3fa4=0x0;_0x4a3fa4<_0xff58c8['offsetSize'];_0x4a3fa4++)_0x25c900['push'](new _0x45f0e1('$text',{'vid':null===_0x1b55ef?this['_revisionId']++:_0x1b55ef++}));}if(_0x15cdbc['is']('documentFragment')){const _0x4e9486=N(_0x15cdbc['rootName']);return _0x4e9486['_insertChild'](0x0,_0x25c900),_0x4e9486;}return _0x48bfb4['_setAttribute']('vid_end',null===_0x1b55ef?this['_revisionId']++:_0x1b55ef++),_0x48bfb4['_insertChild'](0x0,_0x25c900),_0x48bfb4;}['_calculateMetaData'](_0x2be6de,_0x1f0bd9,_0x4a0254){this['_reset']();const {roots:_0x32c743,markers:_0x3c361e,rootsAttributes:_0x17f556}=this['_savedMetaData']['get'](_0x2be6de);this['_baseRoots']=new Map(_0x32c743),this['_baseRootsAttributes']=new Map(_0x52aca2(_0x17f556));for(const [_0x2b6364,_0xcbe75]of this['_baseRoots'])if('$graveyard'!==_0x2b6364&&(this['_diffRoots']['set'](_0x2b6364,K(_0xcbe75)),this['_diffRootsAttributes']=new Map(_0x52aca2(_0x17f556)),_0x4a0254)){const _0x1638ad=this['_revisionId'];this['_idsRoots']['set'](_0x2b6364,this['_makeIdsRoot'](_0xcbe75)),this['_baseIdsRoots']['set'](_0x2b6364,this['_makeIdsRoot'](_0xcbe75,_0x1638ad));}this['_startingRevisionId']=this['_revisionId'],this['_diffRoots']['set']('$graveyard',K(this['_baseRoots']['get']('$graveyard'))),_0x4a0254&&this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](this['_baseRoots']['get']('$graveyard')));for(const [_0x1dc942,_0x1a21e1]of _0x3c361e){const _0x4f9866=this['_baseRoots']['get'](_0x1a21e1['rootName']),_0x1d11d1=this['_diffRoots']['get'](_0x1a21e1['rootName']),_0x52fe32=new _0xfc51be(this['_fixPosition'](_0x1a21e1['start'],_0x4f9866),this['_fixPosition'](_0x1a21e1['end'],_0x4f9866)),_0x204799=this['_fixRange'](_0x52fe32,_0x1d11d1);_0x4f9866['markers']['set'](_0x1dc942,_0x52fe32),this['_markers']['set'](_0x1dc942,_0x204799);}this['_applyOperations'](_0x2be6de,_0x1f0bd9,_0x4a0254);}['_applyOperations'](_0x15330b,_0x326b3a,_0x48bcbe){for(const _0x410cdc of this['source']['getOperations'](_0x15330b,_0x326b3a))this['_handleOperation'](_0x410cdc,_0x48bcbe);for(const _0x5731d7 of this['_diffRoots']['values']())_0x5731d7['markers']['clear']();for(const [_0x345ee3,_0x7d9071]of this['_markers']){this['_diffRoots']['get'](_0x7d9071['root']['rootName'])['markers']['set'](_0x345ee3,_0x7d9071['clone']());}const _0x2ed36c=new Map(),_0x1219b9=new Map();for(const [_0x5a6bfe,_0x23c79d]of this['_diffRoots'])_0x2ed36c['set'](_0x5a6bfe,K(_0x23c79d)),_0x1219b9['set'](_0x5a6bfe,this['_diffRootsAttributes']['get'](_0x5a6bfe));this['_saveMetaData'](_0x326b3a,_0x2ed36c,this['_markers'],_0x1219b9);}['_getPreviousFrom'](_0x58fb82){const _0x4b8525=Array['from'](this['_savedMetaData']['keys']());_0x4b8525['sort']((_0x1b291c,_0x347923)=>_0x1b291c-_0x347923),_0x4b8525['reverse']();for(const _0x567531 of _0x4b8525)if(_0x567531<_0x58fb82)return _0x567531;return Number['NEGATIVE_INFINITY'];}['_copyMarkers'](_0x3ece98,_0x56fdc9){const _0x322e93=Array['from'](_0x56fdc9['markers'])['map'](([_0x9d130e,_0xa0e2d4])=>[_0x9d130e,this['_fixRange'](_0xa0e2d4,_0x3ece98)]);_0x3ece98['markers']=new Map(_0x322e93);}['_transformMarkers'](_0x31aab0){for(const _0x12777e of this['_markers']['values']()){const _0x400f0c=_0x12777e['getTransformedByOperation'](_0x31aab0),_0x515f0e=_0xfc51be['_createFromRanges'](_0x400f0c);_0x12777e['start']=_0x515f0e['start'],_0x12777e['end']=_0x515f0e['end'];}}['_handleOperation'](_0x103708,_0x4ca789){if('addRoot'!=_0x103708['type']&&'detachRoot'!=_0x103708['type']){if('insert'==_0x103708['type']){const _0x2a97e7=_0x103708['position']['root']['rootName'];this['_diffRoots']['has'](_0x2a97e7)||(this['_diffRoots']['set'](_0x2a97e7,N(_0x2a97e7,!0x0)),this['_diffRootsAttributes']['set'](_0x2a97e7,{}),_0x4ca789&&this['_idsRoots']['set'](_0x2a97e7,N(_0x2a97e7,!0x0)));}else{if('addRootAttribute'==_0x103708['type']||'removeRootAttribute'==_0x103708['type']||'changeRootAttribute'==_0x103708['type'])return void this['_handleRootAttributeOperation'](_0x103708);'marker'==_0x103708['type']&&this['_handleMarkerOperation'](_0x103708);}if('marker'!==_0x103708['type']){const _0x4f0d5a=this['_cloneOperation'](_0x103708,this['_diffRoots']);_0x4f0d5a['_execute'](),this['_transformMarkers'](_0x4f0d5a);}if(_0x4ca789)switch(_0x103708['type']){case'insert':this['_handleInsertOperation'](_0x103708);break;case'move':case'remove':case'reinsert':this['_handleMoveOperation'](_0x103708);break;case'merge':this['_handleMergeOperation'](_0x103708);break;case'split':this['_handleSplitOperation'](_0x103708);}}else this['_handleRootOperation'](_0x103708,_0x4ca789);}['_cloneOperation'](_0xd2bc48,_0x2f0a35){const _0x2b613a=_0xd2bc48['clone']();return _0x2b613a['_authorId']=_0xd2bc48['_authorId'],this['_fixOperation'](_0x2b613a,_0x2f0a35),_0x2b613a;}['_getBaseVids'](_0x673dd){return _0x673dd['map'](_0x53921a=>{const _0x501616=this['_getVidAttributeName'](_0x53921a);return Number(_0x53921a['item']['getAttribute'](_0x501616));});}['_generateTape'](_0x1d12dd,_0x5c7747){if(_0x1d12dd['is']('element','$text'))_0x5c7747['push']({'item':_0x1d12dd,'type':'text'});else{_0x1d12dd['is']('element')&&_0x5c7747['push']({'item':_0x1d12dd,'type':'elementStart'});for(const _0x4e9ed4 of _0x1d12dd['getChildren']())this['_generateTape'](_0x4e9ed4,_0x5c7747);_0x1d12dd['is']('element')&&_0x5c7747['push']({'item':_0x1d12dd,'type':'elementEnd'});}return _0x5c7747;}['_getState'](){const _0x1b6c9f=new Map(this['_touched']),_0x509174=new Map(_0x1b6c9f),_0x2aeef3=new Map(),_0x5d525e={'insertions':{},'deletions':{}},_0x435462={'insertions':{},'deletions':{}},_0x3f1844=new Map(),_0x7708c8=new Set([...this['_baseRoots']['keys'](),...this['_diffRoots']['keys']()]);_0x7708c8['delete']('$graveyard');for(const _0x2eb15e of _0x7708c8){const _0x2619d3=this['_diffRoots']['get'](_0x2eb15e)||N(_0x2eb15e,!0x1),_0x3904d5=this['_baseRoots']['get'](_0x2eb15e)||N(_0x2eb15e,!0x1);_0x2619d3['isAttached']()||_0x3904d5['isAttached']()?(_0x5d525e['insertions'][_0x2eb15e]=K(_0x2619d3),_0x5d525e['deletions'][_0x2eb15e]=K(_0x3904d5),this['_copyMarkers'](_0x5d525e['deletions'][_0x2eb15e],_0x3904d5),this['_copyMarkers'](_0x5d525e['insertions'][_0x2eb15e],_0x2619d3),_0x435462['insertions'][_0x2eb15e]=this['_generateTape'](this['_idsRoots']['get'](_0x2eb15e),[]),_0x435462['deletions'][_0x2eb15e]=this['_generateTape'](this['_baseIdsRoots']['get'](_0x2eb15e)||N(_0x2eb15e,!0x1),[])):_0x7708c8['delete'](_0x2eb15e);}for(const _0x45fcc6 of _0x7708c8){const _0x1368fb=_0x435462['insertions'][_0x45fcc6];for(const _0x5d004e of _0x1368fb){const _0xb33a1f=this['_getVidAttributeName'](_0x5d004e),_0x3c3a93=_0x5d004e['item']['getAttribute'](_0xb33a1f);_0x509174['delete'](_0x3c3a93),_0x3c3a93>=this['_startingRevisionId']&&_0x2aeef3['set'](_0x3c3a93,_0x1b6c9f['get'](_0x3c3a93));}}for(const _0x1f0294 of _0x7708c8){const _0x3156c5=_0x435462['insertions'][_0x1f0294],_0x227f88=this['_getBaseVids'](_0x435462['deletions'][_0x1f0294]);let _0x4fc19e=0x0;for(const _0x5adeae of _0x3156c5){const _0x2706c1=this['_getVidAttributeName'](_0x5adeae),_0xa402dc=_0x5adeae['item']['getAttribute'](_0x2706c1);if(!_0x2aeef3['has'](_0xa402dc)&&!_0x3f1844['has'](_0xa402dc)){if(_0x509174['has'](_0xa402dc))_0x4fc19e++;else{if(_0xa402dc!=_0x227f88[_0x4fc19e]){const _0x2122ff=_0x1b6c9f['get'](_0xa402dc)||_0x1b6c9f['get'](_0x227f88[_0x4fc19e]);for(;_0xa402dc!=_0x227f88[_0x4fc19e];)_0x509174['has'](_0x227f88[_0x4fc19e])||(_0x3f1844['set'](_0x227f88[_0x4fc19e],_0x2122ff),_0x1b6c9f['set'](_0x227f88[_0x4fc19e],_0x2122ff)),_0x4fc19e++;}_0x4fc19e++;}}}}for(const _0x1825ba of _0x7708c8){const _0x2f8568=_0x435462['insertions'][_0x1825ba];for(const _0x2a78ec of _0x2f8568){const _0x43ecb0=this['_getVidAttributeName'](_0x2a78ec),_0x12208d=_0x2a78ec['item']['getAttribute'](_0x43ecb0);if(_0x3f1844['has'](_0x12208d)){const _0x1a51fe=_0x3f1844['get'](_0x12208d);_0x509174['has'](_0x12208d)||_0x509174['set'](_0x12208d,{..._0x1a51fe}),_0x2aeef3['set'](_0x12208d,{..._0x1a51fe});}}}for(const _0x3175e6 of _0x509174['keys']())_0x3175e6>=this['_startingRevisionId']&&_0x509174['delete'](_0x3175e6);const _0x790c40=new Map();for(const _0x82c48c of _0x7708c8){let _0x261ff6=_0x435462['insertions'][_0x82c48c];for(const _0x95035a of _0x261ff6)if(_0x95035a['item']['is']('element','tableCell')){const _0x4ef49e=this['_getVidAttributeName'](_0x95035a),_0x156d20=_0x95035a['item']['getAttribute'](_0x4ef49e);if(_0x2aeef3['has'](_0x156d20)){const _0xf04da8=_0x95035a['item']['parent']['parent']['getAttribute']('vid_start'),_0xbabce2=_0x790c40['get'](_0xf04da8)||new Set();_0xbabce2['add'](_0x2aeef3['get'](_0x156d20)['userId']),_0x790c40['set'](_0xf04da8,_0xbabce2);}}_0x261ff6=_0x435462['deletions'][_0x82c48c];for(const _0x43a3c5 of _0x261ff6)if(_0x43a3c5['item']['is']('element','tableCell')){const _0x286ceb=this['_getVidAttributeName'](_0x43a3c5),_0xd4bce0=_0x43a3c5['item']['getAttribute'](_0x286ceb);if(_0x509174['has'](_0xd4bce0)){const _0x2271a6=_0x43a3c5['item']['parent']['parent']['getAttribute']('vid_start'),_0x1f1558=_0x790c40['get'](_0x2271a6)||new Set();_0x1f1558['add'](_0x509174['get'](_0xd4bce0)['userId']),_0x790c40['set'](_0x2271a6,_0x1f1558);}}for(const _0x40416f of _0x790c40['keys']())(_0x2aeef3['has'](_0x40416f)||_0x509174['has'](_0x40416f))&&_0x790c40['delete'](_0x40416f);}for(const _0x218d5c of _0x7708c8){const _0x55bf17=_0x435462['insertions'][_0x218d5c];let _0x11abfe=null,_0x1211d3=null;for(const _0x373fdb of _0x55bf17){const _0x4ed1df=this['_getVidAttributeName'](_0x373fdb),_0x56703d=_0x373fdb['item']['getAttribute'](_0x4ed1df),_0x20d1c2=_0x790c40['get'](_0x56703d);_0x20d1c2&&'elementStart'==_0x373fdb['type']&&(_0x11abfe=Array['from'](_0x20d1c2)[0x0],_0x1211d3=_0x373fdb['item']['getAttribute']('vid_end')),_0x11abfe&&(_0x509174['set'](_0x56703d,{'userId':_0x11abfe}),_0x2aeef3['set'](_0x56703d,{'userId':_0x11abfe})),_0x56703d==_0x1211d3&&(_0x11abfe=null,_0x1211d3=null);}}const _0x64cb24={},_0x20b6c1=new Set();for(const _0x28e1ba of _0x7708c8){const _0x2747b4=_0x5d525e['deletions'][_0x28e1ba],_0x364d38=_0x5d525e['insertions'][_0x28e1ba];for(const {userId:_0x5ab08a}of this['_touchedMarkers']['values']())null!==_0x5ab08a&&_0x20b6c1['add'](_0x5ab08a);for(const {userId:_0x45938e}of this['_touchedRoots']['values']())null!==_0x45938e&&_0x20b6c1['add'](_0x45938e);this['_markChanges'](_0x364d38,_0x435462['insertions'][_0x28e1ba],_0x2aeef3,'insertion',_0x20b6c1),this['_markChanges'](_0x2747b4,_0x435462['deletions'][_0x28e1ba],_0x509174,'deletion',_0x20b6c1),_0x64cb24[_0x28e1ba]={'insertions':this['_prepareViewToSave'](_0x364d38),'deletions':this['_prepareViewToSave'](_0x2747b4),'attachChange':this['_touchedRoots']['get'](_0x28e1ba)||null,'attributesBefore':_0x52aca2(this['_baseRootsAttributes']['get'](_0x28e1ba))||{},'attributesAfter':_0x52aca2(this['_diffRootsAttributes']['get'](_0x28e1ba))};}return{'diffData':_0x64cb24,'authorsIds':Array['from'](_0x20b6c1)};}['_processRootBeforeSave'](_0x370174){for(const [,_0x48bc04]of _0x370174['markers']){const _0x25e7db=_0x48bc04['start']['getAncestors']()['filter'](_0x1a9cb=>'tableCell'==_0x1a9cb['name']);for(const _0x5f2f2d of _0x25e7db)0x1==_0x5f2f2d['childCount']&&_0x5f2f2d['getChild'](0x0)['is']('element','paragraph')&&_0x5f2f2d['getChild'](0x0)['_setAttribute']('keepParagraph',!0x0);}}['_prepareViewToSave'](_0x1a2869){this['_processRootBeforeSave'](_0x1a2869);const _0x3e5a7d=this['editor']['data']['toView'](_0x1a2869,{}),_0x25c4a2=Array['from'](_0x3e5a7d['getChildren']())['map'](_0x1b8881=>this['_getViewJson'](_0x1b8881));return JSON['stringify'](_0x25c4a2);}['_getViewJson'](_0x146583){if(_0x146583['is']('$text'))return _0x146583['data'];{const _0x38bc18=this['editor']['plugins']['get']('RevisionHistoryUtils'),_0x1be1a0=_0x146583,_0x4b12e0=this['editor']['data']['htmlProcessor']['domConverter'],_0x3f1ba6={'type':_0x38bc18['_getTypeCharForViewElement'](_0x1be1a0),'name':_0x1be1a0['name'],'attributes':Array['from'](_0x1be1a0['getAttributes']()),'children':Array['from'](_0x1be1a0['getChildren']())['map'](_0x4591d7=>this['_getViewJson'](_0x4591d7))};if(_0x146583['is']('uiElement')&&'$comment'!=_0x146583['name']){const _0x4de449=_0x146583['render'](_0x4b12e0['domDocument'],_0x4b12e0);_0x3f1ba6['children']['push'](_0x4de449['outerHTML']);}else{if(_0x146583['is']('rawElement')){const _0x1047f5=_0x4b12e0['domDocument']['createElement'](_0x1be1a0['name']);_0x146583['render'](_0x1047f5,_0x4b12e0),_0x3f1ba6['children']['push'](_0x1047f5['innerHTML']);}}const _0x44e47b=Array['from'](_0x1be1a0['getCustomProperties']());_0x44e47b['length']>0x0&&(_0x3f1ba6['customProperties']=_0x44e47b);const _0x468269=_0x1be1a0['getFillerOffset']();return null!==_0x468269&&(_0x3f1ba6['fillerOffset']=_0x468269),_0x3f1ba6;}}['_markChanges'](_0x39bea7,_0x3a4e42,_0x31a999,_0x145933,_0x332b19){let _0x105daa=null,_0x51d0cf=null,_0x2248d6=0x0;const _0xf00a88=this['editor']['model'];for(let _0x1befd1=0x0;_0x1befd1<_0x3a4e42['length'];_0x1befd1++){const _0x4200ea=this['_getVidAttributeName'](_0x3a4e42[_0x1befd1]),_0x2bd7dd=_0x3a4e42[_0x1befd1]['item']['getAttribute'](_0x4200ea),_0x2c9497=_0x31a999['get'](_0x2bd7dd),_0x12d93e=_0x1befd1==_0x3a4e42['length']-0x1;(!_0x105daa&&_0x2c9497&&(_0x105daa=_0x2c9497,_0x51d0cf=_0x3a4e42[_0x1befd1]),_0x105daa&&(!_0x2c9497||_0x2c9497['userId']!=_0x105daa['userId']))&&(_0x32d6f4(_0x2c9497,P(_0x51d0cf,_0x39bea7,_0xf00a88),P(_0x3a4e42[_0x1befd1],_0x39bea7,_0xf00a88)),_0x105daa=_0x2c9497||null,_0x51d0cf=_0x2c9497?_0x3a4e42[_0x1befd1]:null),_0x105daa&&_0x12d93e&&_0x32d6f4(_0x2c9497,P(_0x51d0cf,_0x39bea7,_0xf00a88),V(_0x3a4e42[_0x1befd1],_0x39bea7,_0xf00a88));}function _0x32d6f4(_0x2deca1,_0x5eb29d,_0x46b315){const _0x5773cb=_0x105daa['userId'],_0x4a545b='revision:'+_0x145933+':'+_0x5773cb+':'+_0x2248d6++,_0x495dda=_0xf00a88['createRange'](_0x5eb29d,_0x46b315);_0x39bea7['markers']['set'](_0x4a545b,_0x495dda),null!==_0x5773cb&&_0x332b19['add'](_0x5773cb);}}['_getVidAttributeName'](_0x3c2f04){switch(_0x3c2f04['type']){case'elementStart':return'vid_start';case'elementEnd':return'vid_end';default:return'vid';}}['_fixOperation'](_0x2b4bf2,_0x5d726a){_0x2b4bf2['baseVersion']=null;for(const _0x5094e5 in _0x2b4bf2){const _0x7da08a=_0x2b4bf2[_0x5094e5];if(_0x7da08a instanceof _0x599783){const _0x239497=_0x5d726a['get'](_0x7da08a['root']['rootName']);_0x2b4bf2[_0x5094e5]=this['_fixPosition'](_0x7da08a,_0x239497);}if(_0x7da08a instanceof _0xfc51be){const _0x339634=_0x5d726a['get'](_0x7da08a['root']['rootName']);_0x2b4bf2[_0x5094e5]=this['_fixRange'](_0x7da08a,_0x339634);}'root'===_0x5094e5&&(_0x2b4bf2['root']=_0x5d726a['get'](_0x2b4bf2['root']['rootName']));}}['_fixRange'](_0x3ee238,_0x195103){return this['editor']['model']['createRange'](this['_fixPosition'](_0x3ee238['start'],_0x195103),this['_fixPosition'](_0x3ee238['end'],_0x195103));}['_fixPosition'](_0x39ce31,_0x321311){return this['editor']['model']['createPositionFromPath'](_0x321311,_0x39ce31['path'],_0x39ce31['stickiness']);}['_handleInsertOperation'](_0x1b752d){const _0x363d51=this['_idsRoots']['get'](_0x1b752d['position']['root']['rootName']),_0x3638b3=this['_fixPosition'](_0x1b752d['position'],_0x363d51),_0x3dd052=null===_0x1b752d['_authorId']?null:_0x1b752d['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x1edfad=_0x3638b3['parent'],_0x18cdb7=this['_revisionId'],_0x3adda1=[];for(const _0x4f1409 of _0x1b752d['nodes'])if(_0x4f1409['is']('element'))_0x3adda1['push'](this['_makeIdsRoot'](_0x4f1409));else{for(let _0x594485=0x0;_0x594485<_0x4f1409['offsetSize'];_0x594485++)_0x3adda1['push'](new _0x45f0e1('$text',{'vid':this['_revisionId']++}));}const _0x9963a9=this['_revisionId'];for(let _0x7bbba1=_0x18cdb7;_0x7bbba1<_0x9963a9;_0x7bbba1++)this['_touched']['set'](_0x7bbba1,{'userId':_0x3dd052});_0x1edfad['_insertChild'](_0x3638b3['offset'],_0x3adda1);}['_handleMoveOperation'](_0x4804a0){(_0x4804a0=this['_cloneOperation'](_0x4804a0,this['_idsRoots']))['_execute']();const _0x45b04a=null===_0x4804a0['_authorId']?null:_0x4804a0['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x499f71=_0x4804a0['getMovedRangeStart'](),_0x4cf6ca=_0x499f71['parent'],_0x2f1d22=_0x499f71['offset'];!function _0x4cf6d6(_0x1aff1f,_0x4ccc08,_0x5e06eb,_0x3da095){for(let _0x4392a2=_0x5e06eb;_0x4392a2<_0x3da095;_0x4392a2++){const _0x5c817f=_0x4ccc08['getChild'](_0x4392a2);_0x5c817f['is']('element','$text')?_0x1aff1f['set'](_0x5c817f['getAttribute']('vid'),{'userId':_0x45b04a}):(_0x1aff1f['set'](_0x5c817f['getAttribute']('vid_start'),{'userId':_0x45b04a}),_0x4cf6d6(_0x1aff1f,_0x5c817f,0x0,_0x5c817f['childCount']),_0x1aff1f['set'](_0x5c817f['getAttribute']('vid_end'),{'userId':_0x45b04a}));}}(this['_touched'],_0x4cf6ca,_0x2f1d22,_0x2f1d22+_0x4804a0['howMany']);}['_handleMergeOperation'](_0x53840a){const _0x41ff49=null===(_0x53840a=this['_cloneOperation'](_0x53840a,this['_idsRoots']))['_authorId']?null:_0x53840a['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x35acfb=_0x53840a['targetPosition']['parent'],_0x2812b3=_0x53840a['sourcePosition']['parent'],_0x5193cb=_0x35acfb['getAttribute']('vid_end'),_0x89d46d=_0x2812b3['getAttribute']('vid_start');_0x35acfb['_setAttribute']('vid_end',_0x2812b3['getAttribute']('vid_end')),_0x2812b3['_setAttribute']('vid_end',_0x5193cb),this['_touched']['set'](_0x89d46d,{'userId':_0x41ff49}),this['_touched']['set'](_0x5193cb,{'userId':_0x41ff49}),_0x53840a['_execute']();}['_handleSplitOperation'](_0x3b0233){const _0xe4d5b6=null===(_0x3b0233=this['_cloneOperation'](_0x3b0233,this['_idsRoots']))['_authorId']?null:_0x3b0233['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x5ba4e1=_0x3b0233['graveyardPosition'],_0x5a3dab=_0x3b0233['splitPosition']['parent'];_0x3b0233['_execute']();const _0x932dbc=_0x5a3dab['getAttribute']('vid_end'),_0x4eadf1=_0x3b0233['insertionPosition']['nodeAfter'];if(_0x5ba4e1){const _0x45be96=_0x4eadf1['getAttribute']('vid_end'),_0x550d9b=_0x5a3dab['getAttribute']('vid_end');_0x5a3dab['_setAttribute']('vid_end',_0x45be96),_0x4eadf1['_setAttribute']('vid_end',_0x550d9b),this['_touched']['set'](_0x5a3dab['getAttribute']('vid_end'),{'userId':_0xe4d5b6}),this['_touched']['set'](_0x4eadf1['getAttribute']('vid_start'),{'userId':_0xe4d5b6});}else{const _0x268341=this['_revisionId']++,_0x2bca9d=this['_revisionId']++;_0x5a3dab['_setAttribute']('vid_end',_0x268341),_0x4eadf1['_setAttribute']('vid_start',_0x2bca9d),_0x4eadf1['_setAttribute']('vid_end',_0x932dbc),this['_touched']['set'](_0x268341,{'userId':_0xe4d5b6}),this['_touched']['set'](_0x2bca9d,{'userId':_0xe4d5b6});}}['_handleMarkerOperation'](_0x1a85c8){if(!_0x1a85c8['affectsData'])return;const _0x48da34=(_0x1a85c8=this['_cloneOperation'](_0x1a85c8,this['_diffRoots']))['oldRange']?_0x1a85c8['oldRange']['root']:null,_0x333aa4=_0x1a85c8['newRange']?_0x1a85c8['newRange']['root']:null;_0x48da34&&this['_markers']['delete'](_0x1a85c8['name']),_0x333aa4&&this['_markers']['set'](_0x1a85c8['name'],_0x1a85c8['newRange']['clone']());const _0x4bbeb8=null===_0x1a85c8['_authorId']?null:_0x1a85c8['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0xe00db3=_0x1a85c8['name'];if(!this['_touchedMarkers']['has'](_0xe00db3))return void this['_touchedMarkers']['set'](_0xe00db3,{'range':_0x1a85c8['oldRange'],'userId':_0x4bbeb8});const _0x35999e=this['_touchedMarkers']['get'](_0xe00db3),_0x3899ad=_0x35999e['range'],_0x4822ba=_0x1a85c8['newRange'];null==_0x3899ad&&null==_0x4822ba||_0x3899ad&&_0x4822ba&&_0x3899ad['isEqual'](_0x4822ba)?this['_touchedMarkers']['delete'](_0x1a85c8['name']):_0x35999e['userId']=_0x4bbeb8;}['_handleRootOperation'](_0x2b866b,_0x5caf6d){this['_diffRoots']['has'](_0x2b866b['rootName'])?this['_diffRoots']['get'](_0x2b866b['rootName'])['_isAttached']=_0x2b866b['isAdd']:(this['_diffRoots']['set'](_0x2b866b['rootName'],N(_0x2b866b['rootName'],!0x0)),this['_diffRootsAttributes']['set'](_0x2b866b['rootName'],{}),_0x5caf6d&&this['_idsRoots']['set'](_0x2b866b['rootName'],N(_0x2b866b['rootName'],!0x0)));const _0x2e258d=null===_0x2b866b['_authorId']?null:_0x2b866b['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x1f5f00=this['_touchedRoots']['get'](_0x2b866b['rootName']);_0x1f5f00&&_0x1f5f00['userId']===_0x2e258d?this['_touchedRoots']['delete'](_0x2b866b['rootName']):this['_touchedRoots']['set'](_0x2b866b['rootName'],{'userId':_0x2e258d,'isAttached':_0x2b866b['isAdd']});}['_handleRootAttributeOperation'](_0x41e326){const _0x24f12d=this['_diffRootsAttributes']['get'](_0x41e326['root']['rootName']);null===_0x41e326['newValue']?delete _0x24f12d[_0x41e326['key']]:_0x24f12d[_0x41e326['key']]=_0x41e326['newValue'];}}function K(_0x5244f1){const _0x19e3c1=N(_0x5244f1['rootName'],_0x5244f1['isAttached']());for(const _0xbdb00d of _0x5244f1['getChildren']()){const _0x5e4393=_0xbdb00d['_clone'](!0x0);_0x19e3c1['_appendChild'](_0x5e4393);}return _0x19e3c1;}function N(_0x1f1317,_0xc6bde2=!0x0){const _0x351110=new _0x520f27();return _0x351110['rootName']=_0x1f1317,_0x351110['_isAttached']=_0xc6bde2,_0x351110['isAttached']=()=>_0x351110['_isAttached'],_0x351110;}function P(_0x4e728d,_0x2cd66c,_0xe7458){const _0xba6d26='elementEnd'==_0x4e728d['type']?_0xe7458['createPositionAt'](_0x4e728d['item'],'end'):_0xe7458['createPositionBefore'](_0x4e728d['item']);return _0xe7458['createPositionFromPath'](_0x2cd66c,_0xba6d26['path'],_0xba6d26['stickiness']);}function V(_0x3484eb,_0x5c0b46,_0x6b9333){const _0x5540a6='elementStart'==_0x3484eb['type']?_0x6b9333['createPositionAt'](_0x3484eb['item'],0x0):_0x6b9333['createPositionAfter'](_0x3484eb['item']);return _0x6b9333['createPositionFromPath'](_0x5c0b46,_0x5540a6['path'],_0x5540a6['stickiness']);}class me extends/* #__PURE__ -- @preserve */
|
|
25
|
-
|
|
26
|
-
_0x1deb7c(){['id'];['author'];['type'];['data'];['rootName'];constructor(_0x22c0de){super(),this['id']=_0x22c0de['id']||_0x6a7f74(),this['author']=_0x22c0de['author'],this['type']=_0x22c0de['type'],this['data']=_0x22c0de['data']||{},this['rootName']=_0x22c0de['rootName'],this['set']('createdAt',_0x22c0de['createdAt']);}['toJSON'](){return{'id':this['id'],'authorId':this['author']['id'],'type':this['type'],'data':this['data'],'createdAt':this['createdAt']};}}class J{['newRevisionId'];['oldRevisionId'];['changes'];constructor(_0x14c44a,_0x449526){this['newRevisionId']=_0x14c44a,this['oldRevisionId']=_0x449526,this['changes']=new _0x99deee();}['_setChanges'](_0x2dff97){for(const _0x1159ca of _0x2dff97)this['changes']['add'](_0x1159ca);}}class u extends _0x9e7f10{['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[_0x143e17,_0x2ce1bb,S,$];}constructor(_0x278bce){super(_0x278bce),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',(_0x351f3f,_0x5005d4,_0x5be115)=>{this['activeChange']=null,this['activeView']=null,this['editor']['editing']['view']['change'](_0x248b27=>{for(const _0x766d24 of this['editor']['editing']['view']['document']['roots'])_0x5be115?_0x248b27['removeClass']('ck-editor__editable__overlay',_0x766d24):_0x248b27['addClass']('ck-editor__editable__overlay',_0x766d24);});}),this['bind']('isNavigationMode')['to'](this,'activeChange',_0x5b0039=>null!==_0x5b0039),this['bind']('currentChangeNumber')['to'](this,'isReady',this,'diff',this,'activeChange',(_0x22f8ea,_0x1ebc43,_0x28c415)=>_0x22f8ea&&_0x28c415?_0x1ebc43['changes']['getIndex'](_0x28c415):0x0),this['bind']('numberOfChanges')['to'](this,'isReady',this,'diff',(_0x59342f,_0x377d0b)=>_0x59342f?_0x377d0b['changes']['length']:0x0),this['_changeView']=null,this['_changeIdToChange']=new Map(),this['_balloon']=this['editor']['plugins']['get'](_0x2ce1bb);}['init'](){const _0x199423=this['editor'],_0x1114e0=new ot(_0x199423,{'direction':'backward'}),_0xda80f=new ot(_0x199423,{'direction':'forward'});(_0x199423['commands']['add']('showPreviousChange',_0x1114e0),_0x199423['commands']['add']('showNextChange',_0xda80f),_0x199423['commands']['add']('restoreRevision',new nt(_0x199423)),this['on']('change:numberOfChanges',()=>{_0x1114e0['refresh'](),_0xda80f['refresh']();}),this['_setConversion'](),this['_initInteractions'](),_0x199423['enableReadOnlyMode']('revision-viewer'),_0x199423['plugins']['has']('WidgetToolbarRepository'))&&_0x199423['plugins']['get']('WidgetToolbarRepository')['forceDisabled']('revision-viewer');}async['getRevisionDocumentData'](_0x5e5ba8){return await this['_utils']['loadRevisionData'](_0x5e5ba8,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x5e5ba8);}async['getRevisionRootsAttributes'](_0x3a6ef0){return await this['_utils']['loadRevisionData'](_0x3a6ef0,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x3a6ef0);}async['compare'](_0x4b1346,_0x38f59a,_0x14edb0=!0x1){if(!this['isEnabled'])return;const _0x54a261=this['diff'],_0x696fdd=this['repository'],_0x4a39bf='string'==typeof _0x4b1346?_0x696fdd['getRevision'](_0x4b1346):_0x4b1346,_0x219198='string'==typeof _0x38f59a?_0x696fdd['getRevision'](_0x38f59a):_0x38f59a,_0x3b3b0c=_0x4a39bf['id'],_0x2bd522=_0x219198?_0x219198['id']:null;if(!_0x14edb0&&this['diff']&&this['diff']['newRevisionId']===_0x3b3b0c&&this['diff']['oldRevisionId']===_0x2bd522)return Promise['resolve']();this['isReady']=!0x1,this['activeView']=null,this['activeChange']=null,this['diff']=new J(_0x3b3b0c,_0x2bd522);const _0x3ff0a4=this['_getRevisionsRange'](_0x4a39bf,_0x219198,!0x0)['map'](_0x5e055e=>this['_utils']['loadRevisionData'](_0x5e055e,this['adapter']));return _0x3ff0a4['push'](new Promise(_0x5ea455=>{setTimeout(_0x5ea455,0x14);})),Promise['all'](_0x3ff0a4)['then'](()=>{if(!this['isEnabled'])return;this['_cleanUp']();const _0x2cb164=this['_getDiff'](_0x3b3b0c,_0x2bd522);for(const _0x240387 of _0x2cb164['changes'])this['_changeIdToChange']['set'](_0x240387['id'],_0x240387);this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x1c03c2=>{for(const _0x10695d of this['editor']['model']['document']['getRootNames']())_0x1c03c2['detachRoot'](_0x10695d);for(const _0x3fd322 of Object['keys'](_0x2cb164['model'])){const _0x5955e8=_0x1c03c2['addRoot'](_0x3fd322);for(const _0x12649a of Object['keys'](_0x2cb164['attributes'][_0x3fd322]))_0x1c03c2['setAttribute'](_0x12649a,_0x2cb164['attributes'][_0x3fd322][_0x12649a],_0x5955e8);_0x1c03c2['insert'](_0x2cb164['model'][_0x3fd322],_0x5955e8,0x0);}}),this['diff']['_setChanges'](this['_sortAndFilterDiffChanges'](_0x2cb164['changes'])),this['isReady']=!0x0;})['catch'](_0x442c8c=>{console['error'](_0x442c8c),this['_cleanUp'](),_0x54a261&&(this['diff']=_0x54a261),this['isReady']=!0x0;});}['addRevisionData'](_0x5b4741,_0x30b5b7){const _0x38bda0=this['repository']['createRevision'](_0x5b4741);return _0x38bda0['on']('_update',(_0x129d90,_0x212b96,_0xaf7d06)=>_0x30b5b7(_0x212b96,_0xaf7d06,_0x38bda0)),this['repository']['addRevision'](_0x38bda0),_0x38bda0;}['_cleanUp'](){this['activeChange']=null,this['_cleanMarkers'](),this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=null,this['_changeIdToChange']['clear'](),this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x5e82fa=>{for(const _0x4535bb of this['editor']['model']['document']['getRootNames']())_0x5e82fa['detachRoot'](_0x4535bb);});}['_sortAndFilterDiffChanges'](_0x2f18eb){const _0x4e1710=[],_0x4e539b=new Map();for(const _0x51404f of this['editor']['model']['document']['getRootNames']()){const _0x1eb8ae=this['editor']['editing']['view']['getDomRoot'](_0x51404f);if(!_0x1eb8ae)continue;const _0x5b52e1=_0x1eb8ae['getClientRects']()['item'](0x0);_0x5b52e1&&(_0x4e1710['push'](_0x51404f),_0x4e539b['set'](_0x51404f,_0x5b52e1));}return _0x4e1710['sort']((_0x4c8aaf,_0x2ce668)=>{const _0x32c5c4=_0x4e539b['get'](_0x4c8aaf),_0x1652cd=_0x4e539b['get'](_0x2ce668);return _0x32c5c4['y']-_0x1652cd['y']||_0x32c5c4['x']-_0x1652cd['x'];}),(_0x2f18eb=_0x2f18eb['filter'](_0x1827e2=>_0x4e1710['includes'](_0x1827e2['rootName'])))['sort']((_0x1380be,_0x239fd6)=>_0x4e1710['indexOf'](_0x1380be['rootName'])-_0x4e1710['indexOf'](_0x239fd6['rootName'])),_0x2f18eb;}['_makeTape'](_0x10dbfb){const _0x17cc98=Array['from'](_0x10dbfb['markers'])['filter'](([_0x4a40cb,_0x3217fc])=>_0x4a40cb['startsWith']('revision:')&&!_0x3217fc['isCollapsed']),_0x8c0de=Array['from'](this['editor']['model']['createRangeIn'](_0x10dbfb)['getWalker']({'singleCharacters':!0x0}));if(0x0!=_0x17cc98['length'])for(const _0x53f3f0 of _0x8c0de){const [_0x3b6c0c,_0x146207]=_0x17cc98[0x0],[,_0x584c0d,_0x40e207]=_0x3b6c0c['split'](':');if(_0x146207['end']['isEqual'](_0x53f3f0['nextPosition'])&&_0x17cc98['shift'](),(_0x53f3f0['previousPosition']['isEqual'](_0x146207['start'])||_0x53f3f0['previousPosition']['isAfter'](_0x146207['start']))&&('insertion'==_0x584c0d?_0x53f3f0['isAdded']={'userId':_0x40e207}:'deletion'==_0x584c0d&&(_0x53f3f0['isRemoved']={'userId':_0x40e207})),0x0==_0x17cc98['length'])break;}return _0x8c0de;}['_refreshStartEndIndex'](_0x357900){const _0x235233=new Map();for(let _0x1fad7a=0x0;_0x1fad7a<_0x357900['length'];_0x1fad7a++)'text'===_0x357900[_0x1fad7a]['type']?(_0x357900[_0x1fad7a]['item']['startIndex']=_0x1fad7a,_0x357900[_0x1fad7a]['item']['endIndex']=_0x1fad7a):('elementStart'===_0x357900[_0x1fad7a]['type']?_0x357900[_0x1fad7a]['item']['startIndex']=_0x1fad7a:'elementEnd'===_0x357900[_0x1fad7a]['type']&&(_0x357900[_0x1fad7a]['item']['endIndex']=_0x1fad7a),_0x235233['set'](_0x357900[_0x1fad7a]['id'],_0x1fad7a));for(const _0x1261e6 of _0x235233['values']())'elementStart'===_0x357900[_0x1261e6]['type']?_0x357900[_0x1261e6]['item']['endIndex']=_0x235233['get'](_0x357900[_0x1261e6]['pairId']):'elementEnd'===_0x357900[_0x1261e6]['type']&&(_0x357900[_0x1261e6]['item']['startIndex']=_0x235233['get'](_0x357900[_0x1261e6]['pairId']));}['_processTape'](_0x265010){for(let _0x139ee6=0x0;_0x139ee6<_0x265010['length'];_0x139ee6++){if('elementStart'===_0x265010[_0x139ee6]['type'])_0x265010[_0x139ee6]['item']['startIndex']=_0x139ee6;else{if('elementEnd'===_0x265010[_0x139ee6]['type']){_0x265010[_0x139ee6]['item']['endIndex']=_0x139ee6;const _0x93dc07=_0x265010[_0x139ee6]['item']['startIndex'];_0x265010[_0x93dc07]['pairId']=_0x265010[_0x139ee6]['id'],_0x265010[_0x139ee6]['pairId']=_0x265010[_0x93dc07]['id'];}else _0x265010[_0x139ee6]['item']['startIndex']=_0x139ee6,_0x265010[_0x139ee6]['item']['endIndex']=_0x139ee6,_0x265010[_0x139ee6]['pairId']=null;}_0x265010[_0x139ee6]['markersStart']||(_0x265010[_0x139ee6]['markersStart']=[],_0x265010[_0x139ee6]['markersEnd']=[]);}}['_markInsertions'](_0xb8f61,_0x2c4d0d){const _0x4377ef=_0xb8f61['filter'](_0x22818d=>!_0x22818d['isAdded']);for(let _0x3c9398=0x0;_0x3c9398<_0x2c4d0d['length'];_0x3c9398++)_0x2c4d0d[_0x3c9398]['isAdded']&&(_0x4377ef[_0x3c9398]['isAdded']=_0x2c4d0d[_0x3c9398]['isAdded']);}['_getDiff'](_0x39115a,_0x3b45c9=null){const _0x4c8b59=this['repository']['getRevision'](_0x39115a),_0x571f15=_0x3b45c9?this['repository']['getRevision'](_0x3b45c9):null,_0x3b1a9e=this['_getRevisionsRange'](_0x4c8b59,_0x571f15),_0x201f4d=_0x3b1a9e[_0x3b1a9e['length']-0x1],_0x2e8c93=new Map(),_0x657145={'model':{},'attributes':{},'changes':[]},_0x38680e=new Set(),_0x3aa59e=new Map();for(let _0x411287=_0x3b1a9e['length']-0x1;_0x411287>=0x0;_0x411287--){const _0x948293=_0x3b1a9e[_0x411287];for(const _0x183f81 of Object['keys'](_0x948293['diffData']))if(_0x948293['diffData'][_0x183f81]['attachChange']){const _0x367891=_0x948293['diffData'][_0x183f81]['attachChange'];_0x367891['isAttached']?(_0x38680e['add'](_0x183f81),_0x3aa59e['has'](_0x183f81)&&_0x3aa59e['get'](_0x183f81)['userId']==_0x367891['userId']?_0x3aa59e['delete'](_0x183f81):_0x3aa59e['set'](_0x183f81,_0x367891)):_0x3aa59e['has'](_0x183f81)?(_0x38680e['delete'](_0x183f81),_0x3aa59e['delete'](_0x183f81)):(_0x38680e['add'](_0x183f81),_0x3aa59e['set'](_0x183f81,_0x367891));}else _0x38680e['add'](_0x183f81);}for(const _0x5ee50f of _0x38680e){const _0x4a6ee2=_0x3aa59e['has'](_0x5ee50f)&&!_0x3aa59e['get'](_0x5ee50f)['isAttached'];let _0x384f55=_0x4a6ee2?_0x3b1a9e['length']-0x1:0x0;const _0x22d7d9=_0x4a6ee2?-0x1:0x1;for(;_0x3b1a9e[_0x384f55];){const _0x343631=_0x3b1a9e[_0x384f55];if(_0x343631['diffData'][_0x5ee50f]){const _0xea46d3=_0x4a6ee2?_0x343631['diffData'][_0x5ee50f]['attributesBefore']:_0x343631['diffData'][_0x5ee50f]['attributesAfter'];_0x657145['attributes'][_0x5ee50f]=_0xea46d3?_0x52aca2(_0xea46d3):{};break;}_0x384f55+=_0x22d7d9;}}for(const _0x567e08 of _0x3b1a9e){_0x567e08['model']={};for(const _0x77649e of _0x567e08['authors'])_0x2e8c93['set'](_0x77649e['id'],_0x77649e);for(const _0x109618 of _0x38680e){const _0x193bb8=_0x567e08['diffData'][_0x109618]?_0x567e08['diffData'][_0x109618]['insertions']:'[]',_0x553d0a=_0x567e08['diffData'][_0x109618]?_0x567e08['diffData'][_0x109618]['deletions']:'[]';_0x567e08['model'][_0x109618]={'insertions':this['_utils']['_makeModelFromViewString'](_0x193bb8),'deletions':this['_utils']['_makeModelFromViewString'](_0x553d0a)};}}for(const _0x59c956 of _0x38680e){let _0x3aa46f=null,_0x4dc120=0x0;const _0x55c28f=new Map(Array['from'](_0x4c8b59['model'][_0x59c956]['insertions']['markers'])['filter'](([_0x1c08ae])=>!_0x1c08ae['startsWith']('revision:')));let _0x2cdf63=0x0;for(const _0x528a6a of _0x3b1a9e){const _0x35e9fb=this['_makeTape'](_0x528a6a['model'][_0x59c956]['insertions']);_0x528a6a==_0x4c8b59?(_0x3aa46f=_0x35e9fb,_0x4dc120=_0x3aa46f['length'],_0x3aa46f['forEach'](_0x5c3ad8=>{_0x5c3ad8['id']=_0x2cdf63++;}),this['_processTape'](_0x3aa46f)):this['_markInsertions'](_0x3aa46f,_0x35e9fb);const _0x3141ec=_0x3aa46f['filter'](_0x113362=>!_0x113362['isAdded'])['map'](_0x4a65af=>_0x4a65af['id']);let _0x32fcf8=0x0;const _0x22fe5f=this['_makeTape'](_0x528a6a['model'][_0x59c956]['deletions']);_0x22fe5f['forEach'](_0x2d24f4=>{_0x2d24f4['isRemoved']?_0x2d24f4['id']=_0x4dc120++:_0x2d24f4['id']=_0x3141ec[_0x32fcf8++];}),this['_processTape'](_0x22fe5f),this['_setDistance'](_0x3aa46f,'isAdded'),this['_setDistance'](_0x22fe5f,'isRemoved'),_0x528a6a==_0x4c8b59&&this['_markMarkers'](_0x3aa46f,_0x55c28f),_0x3aa46f=this['_joinTapes'](_0x3aa46f,_0x22fe5f),this['_refreshStartEndIndex'](_0x3aa46f),this['_setDistance'](_0x3aa46f,'isRemoved');}_0x3aa46f=_0x3aa46f['filter'](_0x514a45=>!(_0x514a45['isAdded']&&_0x514a45['isRemoved']));const _0x4f63a4=new Map(_0x201f4d['model'][_0x59c956]['deletions']['markers']),_0x321f34=new Set(_0x55c28f['keys']());for(const _0x18d2db of _0x4f63a4['keys']())_0x321f34['delete'](_0x18d2db);this['_markSuggestions'](_0x3aa46f,_0x321f34),this['_fixObsoleteTags'](_0x3aa46f),_0x3aa46f=this['_removeMissingPairs'](_0x3aa46f),_0x3aa46f=this['_markMismatchedRemovedTags'](_0x3aa46f),_0x3aa46f=this['_removeUnsupportedChanges'](_0x3aa46f);const {root:_0x2074f4,changes:_0x3d214f}=this['_makeModelFromTape'](_0x3aa46f,_0x2e8c93,_0x59c956);_0x657145['model'][_0x59c956]=_0x2074f4;const _0x53bbd4=_0x3aa59e['get'](_0x59c956);if(_0x53bbd4){const _0x5544bb=_0x2e8c93['get'](_0x53bbd4['userId']),_0x2d0a4c=new G({'author':_0x5544bb,'type':_0x53bbd4['isAttached']?'add':'remove','data':{'isOnRoot':!0x0},'createdAt':new Date(),'rootName':_0x59c956});_0x3d214f['unshift'](_0x2d0a4c),_0x657145['attributes'][_0x59c956]['revisionHistoryAttachChange']=_0x2d0a4c['id'];}_0x657145['changes']=_0x657145['changes']['concat'](_0x3d214f);}return _0x657145;}['_markMarkers'](_0x5a2f03,_0x418ef4){for(let _0x4d0b4a=0x0;_0x4d0b4a<_0x5a2f03['length'];_0x4d0b4a++)for(const [_0x29d53f,_0x4fba81]of _0x418ef4)!_0x4fba81['isCollapsed']&&_0x4fba81['start']['isEqual'](_0x5a2f03[_0x4d0b4a]['previousPosition'])&&_0x5a2f03[_0x4d0b4a]['markersStart']['push'](_0x29d53f),_0x4fba81['end']['isEqual'](_0x5a2f03[_0x4d0b4a]['nextPosition'])&&_0x5a2f03[_0x4d0b4a]['markersEnd']['push'](_0x29d53f);}['_joinTapes'](_0x33883d,_0x2fd07d){let _0xe4e0c1=[],_0x4dbca1=0x0,_0x49cf0f=0x0;for(;_0x4dbca1<_0x33883d['length']||_0x49cf0f<_0x2fd07d['length'];){const _0x4146cf=_0x33883d[_0x4dbca1]||{},_0x458bc4=_0x2fd07d[_0x49cf0f]||{};if(_0x4146cf['id']==_0x458bc4['id'])_0x4dbca1++,_0x49cf0f++,_0xe4e0c1['push'](_0x4146cf);else{if(_0x458bc4['isRemoved']&&_0x4146cf['isAdded']){const {commonTape:_0x62b94b,iEnd:_0x3a7b34,jEnd:_0x2e96be}=this['_threeWayMerge'](_0x33883d,_0x4dbca1,_0x2fd07d,_0x49cf0f);_0xe4e0c1=_0xe4e0c1['concat'](_0x62b94b),_0x4dbca1=_0x3a7b34,_0x49cf0f=_0x2e96be;}else _0x458bc4['isRemoved']?(_0x49cf0f++,_0xe4e0c1['push'](_0x458bc4)):(_0x4dbca1++,_0xe4e0c1['push'](_0x4146cf));}}return _0xe4e0c1;}['_markSuggestions'](_0x5a1ad9,_0x72a118){const _0x1c8e4a=[];for(let _0x30337f=0x0;_0x30337f<_0x5a1ad9['length'];_0x30337f++){for(let _0x2e9ccb=0x0;_0x2e9ccb<_0x5a1ad9[_0x30337f]['markersStart']['length'];_0x2e9ccb++){const _0x1560b0=_0x5a1ad9[_0x30337f]['markersStart'][_0x2e9ccb];if(!_0x72a118['has'](_0x1560b0))continue;const {group:_0x2a4332,type:_0x229f7,authorId:_0x2f47bb}=_0x1f5c11(_0x1560b0);'revision-suggestion'!=_0x2a4332||'insertion'!=_0x229f7&&'deletion'!=_0x229f7||(_0x1c8e4a['unshift']({'type':_0x229f7,'name':_0x1560b0,'userId':_0x2f47bb}),_0x5a1ad9[_0x30337f]['markersStart']['splice'](_0x2e9ccb,0x1),_0x2e9ccb--);}_0x50546c(_0x5a1ad9[_0x30337f]);for(let _0x30f7b6=0x0;_0x30f7b6<_0x5a1ad9[_0x30337f]['markersEnd']['length'];_0x30f7b6++){const _0x3b96a9=_0x5a1ad9[_0x30337f]['markersEnd'][_0x30f7b6];if(!_0x72a118['has'](_0x3b96a9))continue;const {group:_0x3474fc,type:_0x4786c6}=_0x1f5c11(_0x3b96a9);if('revision-suggestion'!=_0x3474fc||'insertion'!=_0x4786c6&&'deletion'!=_0x4786c6)continue;_0x5a1ad9[_0x30337f]['markersEnd']['splice'](_0x30f7b6,0x1),_0x30f7b6--;const _0x23ff86=_0x1c8e4a['findIndex'](_0x2c39e2=>_0x2c39e2['name']==_0x3b96a9);_0x23ff86>-0x1&&_0x1c8e4a['splice'](_0x23ff86,0x1);}}function _0x1f5c11(_0x41d69d){const _0x1d26d1=_0x41d69d['split'](':');return{'group':_0x1d26d1[0x0],'type':_0x1d26d1[0x1],'subType':_0x1d26d1['length']>=0x5?_0x1d26d1[0x2]:null,'id':_0x1d26d1['length']<0x5?_0x1d26d1[0x2]:_0x1d26d1[0x3],'authorId':_0x1d26d1['length']<0x5?_0x1d26d1[0x3]:_0x1d26d1[0x4],'markerCount':0x6==_0x1d26d1['length']?_0x1d26d1[0x5]:null};}function _0x50546c(_0x17e7fe){for(let _0x344293=0x0;_0x344293<_0x1c8e4a['length'];_0x344293++){if(_0x17e7fe['isAdded']&&'insertion'==_0x1c8e4a[_0x344293]['type']&&_0x17e7fe['isAdded']['userId']==_0x1c8e4a[_0x344293]['userId'])return _0x17e7fe['isAddSuggestion']=_0x1c8e4a[_0x344293],void delete _0x17e7fe['isAdded'];if(!_0x17e7fe['isAdded']&&!_0x17e7fe['isRemoved']&&'deletion'==_0x1c8e4a[_0x344293]['type'])return void(_0x17e7fe['isRemoveSuggestion']=_0x1c8e4a[_0x344293]);}}}['_setDistance'](_0xb88be7,_0x34f32d){let _0x1a04e5=0x0,_0x3cf5bf=!0x1;const _0x51ee56=new Map();for(const _0x4db09d of _0xb88be7)_0x4db09d[_0x34f32d]?_0x3cf5bf&&(_0x1a04e5++,_0x3cf5bf=!0x1):(_0x1a04e5++,_0x3cf5bf=!0x0),_0x51ee56['set'](_0x4db09d['id'],_0x1a04e5);for(let _0x468936=0x0;_0x468936<_0xb88be7['length'];_0x468936++){if('isRemoved'==_0x34f32d&&_0xb88be7[_0x468936]['isAdded']||'isAdded'==_0x34f32d&&_0xb88be7[_0x468936]['isRemoved'])continue;if('text'==_0xb88be7[_0x468936]['type']){_0xb88be7[_0x468936]['distance']=0x0;continue;}const _0x100d3a=_0x51ee56['get'](_0xb88be7[_0x468936]['pairId']),_0x40e714=_0x51ee56['get'](_0xb88be7[_0x468936]['id']);_0xb88be7[_0x468936]['distance']=_0x100d3a-_0x40e714;}}['_getRevisionsRange'](_0x2f6fb7,_0x5c6cd5,_0x224f82=!0x1){const _0x3fc43b=[];let _0x5a2f8e=this['repository']['getIndex'](_0x2f6fb7),_0x3cbb98=this['repository']['getIndex'](_0x5c6cd5);for(-0x1==_0x3cbb98&&(_0x3cbb98=this['repository']['_revisions']['length'],_0x224f82=!0x1);_0x5a2f8e<_0x3cbb98;)_0x3fc43b['push'](this['repository']['getRevision'](_0x5a2f8e)),_0x5a2f8e++;return _0x224f82&&_0x3fc43b['push'](this['repository']['getRevision'](_0x5a2f8e)),_0x3fc43b;}['_threeWayMerge'](_0x529efe,_0x1553cd,_0x2c06ef,_0x48f9a2){const _0x414527=this['editor']['model']['schema'];let _0x1b6cef=_0x1553cd;for(;_0x529efe[_0x1b6cef]&&_0x529efe[_0x1b6cef]['isAdded'];)_0x1b6cef++;let _0x4851ab=_0x48f9a2;for(;_0x2c06ef[_0x4851ab]&&_0x2c06ef[_0x4851ab]['isRemoved'];)_0x4851ab++;_0x56bc63(_0x529efe,_0x1553cd,_0x1b6cef),_0x56bc63(_0x2c06ef,_0x48f9a2,_0x4851ab);const _0x1fc497=_0x2c06ef['slice'](_0x48f9a2,_0x4851ab)['concat'](_0x529efe['slice'](_0x1553cd,_0x1b6cef));return _0x1fc497['sort']((_0xd558b3,_0x14b6d4)=>_0xd558b3['side']!=_0x14b6d4['side']?_0xd558b3['side']-_0x14b6d4['side']:_0xd558b3['level']!=_0x14b6d4['level']?_0xd558b3['level']-_0x14b6d4['level']:_0xd558b3['distance']!=_0x14b6d4['distance']?_0x14b6d4['distance']-_0xd558b3['distance']:!!_0xd558b3['isAdded']!=!!_0x14b6d4['isAdded']?-0x1==_0xd558b3['side']||0x0==_0xd558b3['side']?_0xd558b3['isAdded']?-0x1:0x1:_0xd558b3['isAdded']?0x1:-0x1:_0xd558b3['index']-_0x14b6d4['index']),{'commonTape':_0x1fc497,'iEnd':_0x1b6cef,'jEnd':_0x4851ab};function _0x56bc63(_0x4b6fea,_0xd1ab5a,_0x2b7109){let _0x52c427=-0x1,_0x3915d5=Number['POSITIVE_INFINITY'],_0x2b678a=!0x0;for(let _0x419e64=_0xd1ab5a;_0x419e64<_0x2b7109;_0x419e64++)if(_0x414527['isInline'](_0x4b6fea[_0x419e64]['item'])||(_0x2b678a=!0x1),_0x4b6fea[_0x419e64]['item']['startIndex']<_0xd1ab5a&&(_0x52c427=_0x419e64),_0x4b6fea[_0x419e64]['item']['endIndex']>=_0x2b7109){_0x3915d5=_0x419e64;break;}_0x2b678a&&(_0x52c427=_0x2b7109-0x1);for(let _0x5d62c4=_0xd1ab5a;_0x5d62c4<_0x2b7109;_0x5d62c4++)_0x4b6fea[_0x5d62c4]['side']=_0x5d62c4<=_0x52c427?-0x1:_0x5d62c4<_0x3915d5?0x0:0x1,_0x4b6fea[_0x5d62c4]['index']=_0x5d62c4;let _0x4250e7=0x0;for(let _0x1d40cb=_0xd1ab5a;_0x1d40cb<=_0x52c427;_0x1d40cb++)0x0==_0x4b6fea[_0x1d40cb]['distance']?_0x4b6fea[_0x1d40cb]['level']=_0x4250e7:(_0x4250e7++,_0x4b6fea[_0x1d40cb]['level']=_0x4250e7,_0x4250e7++);for(let _0x57f59e=_0xd1ab5a;_0x57f59e<_0x2b7109;_0x57f59e++)0x0==_0x4b6fea[_0x57f59e]['side']&&(_0x4b6fea[_0x57f59e]['level']=_0x4250e7);_0x4250e7=0x0;for(let _0x293857=_0x2b7109-0x1;_0x293857>=_0x3915d5;_0x293857--)0x0==_0x4b6fea[_0x293857]['distance']?_0x4b6fea[_0x293857]['level']=_0x4250e7:(_0x4250e7--,_0x4b6fea[_0x293857]['level']=_0x4250e7,_0x4250e7--);}}['_fixObsoleteTags'](_0x4ae727){const _0x32f573=new Map(),_0x305065=this['editor']['model']['schema'];for(let _0x50a1d7=0x1;_0x50a1d7<_0x4ae727['length'];_0x50a1d7++){let _0x2d99f4,_0x1d0219,_0x278f36;const _0x2eb405=_0x4ae727[_0x50a1d7],_0x311fea=_0x4ae727[_0x50a1d7-0x1];if('text'==_0x2eb405['type'])continue;if(_0x2eb405['type']!=_0x311fea['type'])continue;if(!_0x305065['isBlock'](_0x311fea['item'])||_0x305065['isLimit'](_0x311fea['item']))continue;if(!_0x305065['isBlock'](_0x2eb405['item'])||_0x305065['isLimit'](_0x2eb405['item']))continue;if((_0x4ae727[_0x50a1d7]['isAdded']||_0x4ae727[_0x50a1d7]['isAddSuggestion'])&&_0x4ae727[_0x50a1d7-0x1]['isRemoved'])_0x2d99f4=_0x4ae727[_0x50a1d7],_0x1d0219=_0x4ae727[_0x50a1d7-0x1],_0x278f36=_0x50a1d7-0x1;else{if(!_0x4ae727[_0x50a1d7]['isRemoved']||!_0x4ae727[_0x50a1d7-0x1]['isAdded']&&!_0x4ae727[_0x50a1d7-0x1]['isAddSuggestion'])continue;_0x2d99f4=_0x4ae727[_0x50a1d7-0x1],_0x1d0219=_0x4ae727[_0x50a1d7],_0x278f36=_0x50a1d7;}const _0x10f576=_0x2d99f4['level']==_0x1d0219['level'],_0x35d2ae=Math['abs'](_0x2d99f4['level'])<Math['abs'](_0x1d0219['level'])&&0x0==_0x1d0219['distance'];(_0x10f576||_0x35d2ae)&&(_0x32f573['set'](_0x1d0219['id'],_0x2d99f4['id']),_0x4ae727['splice'](_0x278f36,0x1),_0x50a1d7--,_0x2d99f4['isAdded']=!0x1);}for(let _0xdf3a3d=0x0;_0xdf3a3d<_0x4ae727['length'];_0xdf3a3d++)_0x32f573['has'](_0x4ae727[_0xdf3a3d]['pairId'])&&(_0x4ae727[_0xdf3a3d]['pairId']=_0x32f573['get'](_0x4ae727[_0xdf3a3d]['pairId']));}['_removeMissingPairs'](_0x2bbd9d){const _0xb9e005=new Set(_0x2bbd9d['map'](_0x4cc06c=>_0x4cc06c['id']));for(let _0xf0ad8d=0x0;_0xf0ad8d<_0x2bbd9d['length'];_0xf0ad8d++)_0xb9e005['has'](_0x2bbd9d[_0xf0ad8d]['pairId'])||0x0==_0x2bbd9d[_0xf0ad8d]['distance']||(_0x2bbd9d[_0xf0ad8d]['isIncorrect']=!0x0);return _0x2bbd9d['filter'](_0x3baf43=>!_0x3baf43['isIncorrect']);}['_markMismatchedRemovedTags'](_0x728a7d){const _0x568a21=new Set();for(let _0x17b5c3=0x0;_0x17b5c3<_0x728a7d['length'];_0x17b5c3++){if(_0x568a21['has'](_0x728a7d[_0x17b5c3]['id'])&&_0x728a7d[_0x17b5c3]['isRemoved']&&(_0x728a7d[_0x17b5c3]['isIncorrect']=!0x0),_0x728a7d[_0x17b5c3]['isIncorrect'])continue;if(0x0==_0x728a7d[_0x17b5c3]['distance'])continue;if('elementStart'!=_0x728a7d[_0x17b5c3]['type'])continue;if(null==_0x728a7d[_0x17b5c3]['pairId'])continue;let _0x307731=_0x17b5c3+0x1,_0xa3ee7a=0x0;for(;_0x728a7d[_0x307731]['id']!=_0x728a7d[_0x17b5c3]['pairId'];)'elementStart'==_0x728a7d[_0x307731]['type']?_0xa3ee7a++:'elementEnd'==_0x728a7d[_0x307731]['type']&&_0xa3ee7a--,_0x307731++;if(0x0!=_0xa3ee7a){if(_0x728a7d[_0x17b5c3]['isRemoved'])_0x728a7d[_0x17b5c3]['isIncorrect']=!0x0;else{for(;_0x307731!=_0x17b5c3;)_0x728a7d[_0x307731]['isRemoved']&&0x0!=_0x728a7d[_0x307731]['distance']&&(_0x728a7d[_0x307731]['isIncorrect']=!0x0,_0x568a21['add'](_0x728a7d[_0x307731]['pairId'])),_0x307731--;}}}return _0x728a7d['filter'](_0x4e2b65=>!_0x4e2b65['isIncorrect']);}['_removeUnsupportedChanges'](_0x2fcab9){const _0x59d729=this['editor']['model']['schema'];for(let _0xbd783f=0x0;_0xbd783f<_0x2fcab9['length'];_0xbd783f++){if(!(_0x2fcab9[_0xbd783f]['isAdded']||_0x2fcab9[_0xbd783f]['isAddSuggestion']||_0x2fcab9[_0xbd783f]['isRemoved']||_0x2fcab9[_0xbd783f]['isRemoveSuggestion']))continue;if(0x0==_0x2fcab9[_0xbd783f]['distance'])continue;const _0x1ad822=_0x2fcab9[_0xbd783f]['item'];_0x59d729['isBlock'](_0x1ad822)||_0x59d729['isLimit'](_0x1ad822)||(_0x2fcab9[_0xbd783f]['isAdded']&&delete _0x2fcab9[_0xbd783f]['isAdded'],_0x2fcab9[_0xbd783f]['isAddSuggestion']&&delete _0x2fcab9[_0xbd783f]['isAddSuggestion'],_0x2fcab9[_0xbd783f]['isRemoveSuggestion']&&delete _0x2fcab9[_0xbd783f]['isRemoveSuggestion'],_0x2fcab9[_0xbd783f]['isRemoved']&&(_0x2fcab9[_0xbd783f]['isIncorrect']=!0x0));}return _0x2fcab9['filter'](_0x20348b=>!_0x20348b['isIncorrect']);}['_makeModelFromTape'](_0x125bb3,_0x539c71,_0x391215){const _0x3d7be0=new _0x520f27(),_0x37c8d2=[],_0x2c95a6=new Map(),_0x45ae18=this['editor']['model'],_0x3f87d9=_0x45ae18['schema'],_0x41da3d=[_0x3d7be0],_0x48b903={},_0x2fe1bc={'isAdded':[],'isRemoved':[],'isAddSuggestion':[],'isRemoveSuggestion':[]};let _0x5f1772=null;const _0x555cb2=[0x0];for(let _0xe2dc5d=0x0;_0xe2dc5d<_0x125bb3['length'];_0xe2dc5d++)if('elementStart'===_0x125bb3[_0xe2dc5d]['type']){_0x125bb3[_0xe2dc5d]['previousPosition']=_0x45ae18['createPositionFromPath'](_0x3d7be0,_0x555cb2);const _0x3cde3c=new _0x45f0e1(_0x125bb3[_0xe2dc5d]['item']['name'],_0x125bb3[_0xe2dc5d]['item']['getAttributes']());_0x41da3d[0x0]['_appendChild'](_0x3cde3c),_0x555cb2['push'](0x0),_0x41da3d['unshift'](_0x3cde3c),_0x125bb3[_0xe2dc5d]['nextPosition']=_0x45ae18['createPositionFromPath'](_0x3d7be0,_0x555cb2);}else'elementEnd'===_0x125bb3[_0xe2dc5d]['type']?(_0x41da3d['shift'](),_0x125bb3[_0xe2dc5d]['previousPosition']=_0x45ae18['createPositionFromPath'](_0x3d7be0,_0x555cb2),_0x555cb2['pop'](),_0x555cb2[_0x555cb2['length']-0x1]++,_0x125bb3[_0xe2dc5d]['nextPosition']=_0x45ae18['createPositionFromPath'](_0x3d7be0,_0x555cb2)):(_0x125bb3[_0xe2dc5d]['previousPosition']=_0x45ae18['createPositionFromPath'](_0x3d7be0,_0x555cb2),_0x5f1772?_0x5f1772['_data']+=_0x125bb3[_0xe2dc5d]['item']['data']:_0x5f1772=new _0x318795(_0x125bb3[_0xe2dc5d]['item']['data'],_0x125bb3[_0xe2dc5d]['item']['getAttributes']()),_0x125bb3[_0xe2dc5d+0x1]&&'text'===_0x125bb3[_0xe2dc5d+0x1]['type']&&_0x1a15b4(_0x5f1772,_0x125bb3[_0xe2dc5d+0x1]['item'])||(_0x41da3d[0x0]['_appendChild'](_0x5f1772),_0x5f1772=null),_0x555cb2[_0x555cb2['length']-0x1]+=_0x125bb3[_0xe2dc5d]['item']['offsetSize'],_0x125bb3[_0xe2dc5d]['nextPosition']=_0x45ae18['createPositionFromPath'](_0x3d7be0,_0x555cb2));for(let _0xae1c7=0x0;_0xae1c7<_0x125bb3['length'];_0xae1c7++){const _0x5eee47=_0x125bb3[_0xae1c7]['previousPosition'],_0x115e83=_0x125bb3[_0xae1c7]['nextPosition'];for(const _0x19a11a of _0x125bb3[_0xae1c7]['markersStart'])_0x2c95a6['set'](_0x19a11a,{'start':_0x5eee47,'end':null});_0x40910f('isRemoveSuggestion',_0xae1c7,_0x5eee47,_0x115e83),_0x40910f('isAddSuggestion',_0xae1c7,_0x5eee47,_0x115e83),_0x40910f('isRemoved',_0xae1c7,_0x5eee47,_0x115e83),_0x40910f('isAdded',_0xae1c7,_0x5eee47,_0x115e83);for(const _0x5162ff of _0x125bb3[_0xae1c7]['markersEnd']){const _0x31d293=_0x2c95a6['get'](_0x5162ff);_0x31d293?_0x31d293['end']=_0x115e83:_0x2c95a6['set'](_0x5162ff,{'start':_0x115e83,'end':_0x115e83});}}for(const [_0x3f39b7,_0x49dc39]of _0x2c95a6){const _0x4eec2e=this['editor']['model']['createRange'](_0x49dc39['start'],_0x49dc39['end']);_0x3d7be0['markers']['set'](_0x3f39b7,_0x4eec2e);}return _0x37c8d2['sort']((_0x49982d,_0x1616d3)=>{const _0x5a508f=_0x3d7be0['markers']['get']('revision:'+_0x49982d['id']),_0x186334=_0x3d7be0['markers']['get']('revision:'+_0x1616d3['id']);return _0x5a508f['start']['isBefore'](_0x186334['start'])?-0x1:_0x5a508f['start']['isAfter'](_0x186334['start'])?0x1:_0x5a508f['end']['isBefore'](_0x186334['end'])?-0x1:_0x5a508f['end']['isAfter'](_0x186334['end'])?0x1:'add'===_0x49982d['type']?-0x1:0x1;}),{'root':_0x3d7be0,'changes':_0x37c8d2};function _0x40910f(_0x42ca6e,_0x4c84f3,_0x977f31,_0x2d2a94){const _0x12b70e=!!_0x125bb3[_0x4c84f3][_0x42ca6e],_0xf1a555=_0x12b70e?_0x125bb3[_0x4c84f3][_0x42ca6e]['userId']:null,_0xde5245=_0x4c84f3===_0x125bb3['length']-0x1,_0x9077bf=_0x2fe1bc[_0x42ca6e][0x0],_0x58e724=_0x3f87d9['isObject'](_0x125bb3[_0x4c84f3]['item']);!_0x48b903[_0x42ca6e]&&_0x12b70e?_0x48b903[_0x42ca6e]={'start':_0x977f31,'tapeItem':_0x125bb3[_0x4c84f3],'userId':_0xf1a555,'type':_0x42ca6e}:_0x48b903[_0x42ca6e]&&!_0x12b70e?(_0x48b903[_0x42ca6e]['end']=_0x977f31,_0x21e379(_0x48b903[_0x42ca6e]),_0x48b903[_0x42ca6e]=null):_0x48b903[_0x42ca6e]&&_0x12b70e&&_0x48b903[_0x42ca6e]['userId']!==_0xf1a555&&(_0x48b903[_0x42ca6e]['end']=_0x977f31,_0x9077bf&&_0x9077bf['userId']===_0x48b903[_0x42ca6e]['userId']||_0x21e379(_0x48b903[_0x42ca6e]),_0x48b903[_0x42ca6e]={'start':_0x977f31,'tapeItem':_0x125bb3[_0x4c84f3],'userId':_0xf1a555,'type':_0x42ca6e}),_0x48b903[_0x42ca6e]&&_0x58e724&&('elementStart'!==_0x125bb3[_0x4c84f3]['type']||_0x9077bf&&_0x9077bf['userId']===_0xf1a555||_0x2fe1bc[_0x42ca6e]['unshift']({'userId':_0xf1a555,'object':_0x125bb3[_0x4c84f3]['item'],'change':_0x48b903[_0x42ca6e]}),'elementEnd'===_0x125bb3[_0x4c84f3]['type']&&_0x9077bf&&_0x9077bf['object']===_0x125bb3[_0x4c84f3]['item']&&(_0x2fe1bc[_0x42ca6e]['shift'](),_0x48b903[_0x42ca6e]=_0x9077bf['change'])),_0x48b903[_0x42ca6e]&&_0xde5245&&(_0x48b903[_0x42ca6e]['end']=_0x2d2a94,_0x21e379(_0x48b903[_0x42ca6e]),_0x48b903[_0x42ca6e]=null);}function _0x21e379({start:_0x487c05,end:_0x1fbdff,tapeItem:_0x169e49,userId:_0xe1e57f,type:_0x490fa7}){const _0x6c4816=_0x169e49['item'],_0x3153b6=_0x45ae18['schema']['isBlock'](_0x6c4816)&&!_0x45ae18['schema']['isLimit'](_0x6c4816),_0x401872=_0x487c05['nodeAfter']==_0x1fbdff['parent']&&_0x1fbdff['isAtStart'];if(_0x3153b6&&_0x401872)return;const _0xf5f6e9=_0x45ae18['createRange'](_0x487c05,_0x1fbdff),_0x131297=_0x539c71['get'](_0xe1e57f),_0x4ee437=new G({'author':_0x131297,'type':'isAdded'==_0x490fa7||'isAddSuggestion'==_0x490fa7?'add':'remove','data':{'isSuggestion':'isAddSuggestion'==_0x490fa7||'isRemoveSuggestion'==_0x490fa7},'createdAt':new Date(),'rootName':_0x391215});_0x37c8d2['push'](_0x4ee437),_0x3d7be0['markers']['set']('revision:'+_0x4ee437['id'],_0xf5f6e9);}function _0x1a15b4(_0x44dcfa,_0x76bf65){const _0x335378=_0x44dcfa['getAttributes'](),_0x530ebc=_0x76bf65['getAttributes']();for(const _0x4f2669 of _0x335378){if(_0x4f2669[0x1]!==_0x76bf65['getAttribute'](_0x4f2669[0x0]))return!0x1;_0x530ebc['next']();}return _0x530ebc['next']()['done'];}}['_setConversion'](){this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision','view':_0x22e905=>{const _0x134e09=_0x22e905['markerName']['split'](':')[0x1],_0x7a92c6=this['_getChangeFromId'](_0x134e09);if(!_0x7a92c6)return null;const _0x250b19='add'==_0x7a92c6['type']?'insertion':'deletion',_0xc20e5c=['ck-suggestion-marker','ck-suggestion-marker-'+_0x250b19];return _0x7a92c6['data']['isSuggestion']&&_0xc20e5c['push']('ck-suggestion-marker-'+_0x250b19+'-new'),this['activeChange']==_0x7a92c6&&_0xc20e5c['push']('ck-suggestion-marker--active'),{'classes':_0xc20e5c,'attributes':{'data-change-id':_0x134e09}};}}),this['editor']['conversion']['for']('upcast')['add'](_0x261f55=>{_0x261f55['on']('element:pre',(_0x34e4d9,_0x3c27fd,_0x28bbcb)=>{const _0x558e37=_0x3c27fd['viewItem']['getChild'](0x0);if(!_0x558e37||!_0x558e37['is']('element','code'))return;if(!_0x28bbcb['consumable']['consume'](_0x558e37,{'attributes':['vid_start','vid_end']}))return;const _0x2c181a=_0x3c27fd['modelRange']['start']['nodeAfter'];_0x28bbcb['writer']['setAttribute']('vid_start',_0x558e37['getAttribute']('vid_start'),_0x2c181a),_0x28bbcb['writer']['setAttribute']('vid_end',_0x558e37['getAttribute']('vid_end'),_0x2c181a);},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['add'](_0x3338ed=>{_0x3338ed['on']('element',(_0x18aaa4,_0xa2cad8,_0x10b919)=>{if(!_0x10b919['consumable']['consume'](_0xa2cad8['viewItem'],{'attributes':['vid_start','vid_end']}))return;if(_0xa2cad8['modelRange']['isCollapsed'])return;const _0x327c67=_0xa2cad8['modelRange']['start']['nodeAfter'];_0x327c67['hasAttribute']('vid_start')||_0x327c67['hasAttribute']('vid')||(_0x10b919['writer']['setAttribute']('vid_start',_0xa2cad8['viewItem']['getAttribute']('vid_start'),_0x327c67),_0x10b919['writer']['setAttribute']('vid_end',_0xa2cad8['viewItem']['getAttribute']('vid_end'),_0x327c67));},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['elementToAttribute']({'view':{'name':'span','attributes':{'vid':!0x0}},'model':{'key':'vid','value':_0x458cfc=>_0x458cfc['getAttribute']('vid')}}),this['editor']['model']['schema']['on']('checkAttribute',(_0x3bc81c,[,_0x111cf4])=>{['vid_start','vid_end','vid']['includes'](_0x111cf4)&&(_0x3bc81c['return']=!0x0,_0x3bc81c['stop']());},{'priority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x22bd2f=>{_0x22bd2f['on']('attribute:vid',(_0x175e88,_0x2a3c49,_0x607dc)=>{if('\x20'!=_0x2a3c49['item']['data']||_0x2a3c49['item']['parent']['maxOffset']>0x1)return;if(!_0x607dc['consumable']['consume'](_0x2a3c49['item'],_0x175e88['name']))return;const _0x556dbe=_0x607dc['writer'],_0x35a94a=_0x607dc['mapper']['toViewRange'](_0x2a3c49['range']);_0x556dbe['wrap'](_0x35a94a,_0x556dbe['createAttributeElement']('span'));});}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',function(_0x4df3f8){const _0x3a94d0=_0x4df3f8['plugins']['get']('RevisionViewer');return(_0xd8007,_0x37eb17,_0x47e7e7)=>{const _0x97ec9a=_0x37eb17['markerName']['split'](':')[0x1],_0x3258d1=_0x3a94d0['_getChangeFromId'](_0x97ec9a);if(!_0x3258d1)return null;const _0x1d133b='add'==_0x3258d1['type']?'split':'merge';if(!_0x47e7e7['consumable']['test'](_0x37eb17['markerRange'],_0xd8007['name']))return;const _0x52a591=_0x37eb17['markerRange']['getWalker'](),_0x350502=_0x37eb17['markerRange']['start'],_0x18ce88=_0x4df3f8['model']['schema'];let _0x5d75b6=null,_0x513d95=null,_0x3f0b38=!0x1,_0x5185d0=!0x1;for(const _0x1ffddc of _0x52a591){const _0x4b6804=_0x1ffddc['item'];_0x3f0b38=_0x3f0b38||_0x18ce88['isContent'](_0x4b6804);const _0x2ac914=_0x47e7e7['mapper']['toViewElement'](_0x4b6804);if(_0x2ac914&&_0x2ac914['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x1ffddc['type']&&(_0x18ce88['isBlock'](_0x4b6804)&&!_0x18ce88['isLimit'](_0x4b6804)&&(_0x4b6804['nextSibling']||_0x350502['isAtEnd']?_0x5d75b6&&_0x5d75b6['parent']==_0x4b6804||(_0x5d75b6=_0x4b6804,_0x284cc8(_0x1ffddc['previousPosition']),_0x5185d0=!0x0):_0x513d95=_0x513d95||_0x1ffddc['previousPosition']));}function _0x284cc8(_0x74e794){const _0x4657d2=_0x47e7e7['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x1d133b}),_0x5440c9=_0x47e7e7['mapper']['toViewPosition'](_0x74e794);_0x3258d1['data']['isSuggestion']&&_0x47e7e7['writer']['addClass']('ck-suggestion-marker-'+_0x1d133b+'-new',_0x4657d2),_0x3a94d0['activeChange']==_0x3258d1&&_0x47e7e7['writer']['addClass']('ck-suggestion-marker--active',_0x4657d2),_0x47e7e7['writer']['insert'](_0x5440c9,_0x4657d2),_0x47e7e7['mapper']['bindElementToMarker'](_0x4657d2,_0x37eb17['markerName']);}_0x3f0b38||_0x5185d0||!_0x513d95||_0x284cc8(_0x513d95);};}(this['editor']),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision',(_0x5d40dc,_0x53d7ee,_0x25a653)=>{const _0x326a4d=_0x25a653['mapper']['markerNameToElements'](_0x53d7ee['markerName']);if(_0x326a4d){for(const _0x5b0939 of _0x326a4d)(_0x5b0939['hasClass']('ck-suggestion-marker-split')||_0x5b0939['hasClass']('ck-suggestion-marker-merge'))&&(_0x25a653['mapper']['unbindElementFromMarkerName'](_0x5b0939,_0x53d7ee['markerName']),_0x25a653['writer']['remove'](_0x5b0939));}},{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',(_0x425940,_0x213675,_0x1bd368)=>{const _0x3f4aa9=_0x213675['markerName']['split'](':')[0x1],_0x5d8c2d=this['_getChangeFromId'](_0x3f4aa9);if(!_0x5d8c2d)return null;const _0x30873b='add'==_0x5d8c2d['type']?'split':'merge';if(_0x1bd368['consumable']['test'](_0x213675['markerRange'],_0x425940['name']))for(const _0x470424 of _0x213675['markerRange']['getItems']()){if(!_0x470424['is']('element','softBreak'))continue;const _0x530f83=_0x1bd368['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x30873b}),_0x51c795=_0x1bd368['mapper']['toViewPosition'](this['editor']['model']['createPositionBefore'](_0x470424));_0x5d8c2d['data']['isSuggestion']&&_0x1bd368['writer']['addClass']('ck-suggestion-marker-'+_0x30873b+'-new',_0x530f83),this['activeChange']==_0x5d8c2d&&_0x1bd368['writer']['addClass']('ck-suggestion-marker--active',_0x530f83),_0x1bd368['writer']['insert'](_0x51c795,_0x530f83),_0x1bd368['mapper']['bindElementToMarker'](_0x530f83,_0x213675['markerName']);}},{'priority':'high'}),this['editor']['model']['document']['on']('change',()=>{this['editor']['editing']['view']['change'](_0x48d19c=>{for(const _0x18e58e of this['editor']['model']['document']['getRootNames']()){const _0x788c46=this['editor']['model']['document']['getRoot'](_0x18e58e),_0x45065d=this['editor']['editing']['view']['document']['getRoot'](_0x18e58e);if(_0x45065d){const _0x4ed9ce=_0x788c46['getAttribute']('revisionHistoryAttachChange');if(_0x48d19c['removeAttribute']('data-change-id',_0x45065d),_0x48d19c['removeClass']('ck-revision-history-root-add',_0x45065d),_0x48d19c['removeClass']('ck-revision-history-root-remove',_0x45065d),_0x48d19c['removeClass']('ck-revision-history-root--active',_0x45065d),_0x4ed9ce){const _0x1e150a=this['_getChangeFromId'](_0x4ed9ce);if(!_0x1e150a)return null;_0x48d19c['setAttribute']('data-change-id',_0x4ed9ce,_0x45065d),_0x48d19c['addClass']('ck-revision-history-root-'+_0x1e150a['type'],_0x45065d),this['activeChange']==_0x1e150a&&_0x48d19c['addClass']('ck-revision-history-root--active',_0x45065d);}}}});}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'comment','model':_0x5649a7=>'revision-comment:'+_0x5649a7,'converterPriority':'highest'}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'suggestion','model':_0x1781ad=>'revision-suggestion:'+_0x1781ad,'converterPriority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision-suggestion','view':_0x59912c=>({'name':'suggestion:'+_0x59912c,'group':'revision-suggestion'}),'converterPriority':'highest'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision-suggestion','view':_0x5bf0d4=>{const _0x32cf71=_0x5bf0d4['markerName']['split'](':')[0x1];return'insertion'!=_0x32cf71&&'deletion'!=_0x32cf71?null:{'classes':['ck-suggestion-preview-marker','ck-suggestion-preview-marker-'+_0x32cf71]};}}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:deletion',Q(this['editor'],'merge'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:insertion',Q(this['editor'],'split'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision-suggestion',(_0x387b6d,_0x9ac084,_0x1efd8e)=>{const _0x3f5f4e=_0x1efd8e['mapper']['markerNameToElements'](_0x9ac084['markerName']);if(_0x3f5f4e){for(const _0x38ee12 of _0x3f5f4e)_0x38ee12['is']('uiElement')&&(_0x1efd8e['mapper']['unbindElementFromMarkerName'](_0x38ee12,_0x9ac084['markerName']),_0x1efd8e['writer']['remove'](_0x38ee12));}},{'priority':'high'});}['_getChangeFromId'](_0x4875e1){return this['_changeIdToChange']['get'](_0x4875e1);}['_getViewForChange'](_0x199e20){return this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=new z(this['editor']['locale'],_0x199e20),this['_changeView'];}['_initInteractions'](){this['editor']['model']['document']['selection']['observeMarkers']('revision'),this['on']('change:activeView',(_0x35452b,_0x364d77,_0x25414f,_0x3b7b38)=>{_0x3b7b38&&this['_balloon']['remove'](_0x3b7b38),_0x25414f&&(this['_balloon']['add']({'view':_0x25414f,'stackId':'revisionHistoryLabel','position':{'target':()=>{const _0x14f0d3=this['editor']['editing'],_0x3d611e=this['_getChangeFromId'](_0x25414f['changeId']);let _0x2091f5;if(_0x3d611e['data']['isOnRoot']){const _0x467d68=_0x14f0d3['view']['getDomRoot'](_0x3d611e['rootName']);_0x2091f5=Array['from'](_0x467d68['getClientRects']());}else{const _0x54da57=this['editor']['model']['markers']['get']('revision:'+_0x25414f['changeId']);_0x2091f5=Array['from'](_0x14f0d3['mapper']['markerNameToElements'](_0x54da57['name']))['map'](_0x432337=>_0x14f0d3['view']['domConverter']['mapViewToDom'](_0x432337))['map'](_0x1cf680=>Array['from'](_0x1cf680['getClientRects']()))['flat']();}if(!this['_activeViewTarget'])return _0x2091f5[0x0];return _0x2091f5['find'](_0x2eacca=>_0x2eacca['top']-0x3<=this['_activeViewTarget']['y']&&_0x2eacca['bottom']+0x3>=this['_activeViewTarget']['y']&&_0x2eacca['left']-0x3<=this['_activeViewTarget']['x']&&_0x2eacca['right']+0x3>=this['_activeViewTarget']['x'])||_0x2091f5[0x0];}}}),this['_balloon']['showStack']('revisionHistoryLabel'));}),this['on']('change:activeChange',(_0x5acb43,_0x1a5c35,_0x1ceb85,_0x3f7ce2)=>{this['activeView']=_0x1ceb85?this['_getViewForChange'](_0x1ceb85):null,this['editor']['model']['change'](()=>{const _0x2da035=this['editor']['editing'];_0x3f7ce2&&(_0x3f7ce2['data']['isOnRoot']?_0x2da035['view']['change'](_0x123c10=>{_0x123c10['removeClass']('ck-revision-history-root--active',_0x2da035['view']['document']['getRoot'](_0x3f7ce2['rootName']));}):_0x2da035['reconvertMarker']('revision:'+_0x3f7ce2['id'])),_0x1ceb85&&(_0x1ceb85['data']['isOnRoot']?_0x2da035['view']['change'](_0x52ff1e=>{_0x52ff1e['addClass']('ck-revision-history-root--active',_0x2da035['view']['document']['getRoot'](_0x1ceb85['rootName']));}):_0x2da035['reconvertMarker']('revision:'+_0x1ceb85['id']));});}),this['listenTo'](this['editor']['editing']['view']['document'],'mouseover',(_0x1ae0c7,_0x3d0456)=>{if(this['activeChange'])return;const _0xb7b6ab=this['_findChangeIdFromDomTarget'](_0x3d0456['target']),_0x455073=this['_changeIdToChange']['get'](_0xb7b6ab);_0x455073?(this['_activeViewTarget']={'x':_0x3d0456['domEvent']['x'],'y':_0x3d0456['domEvent']['y']},this['activeView']=this['_getViewForChange'](_0x455073)):(this['_activeViewTarget']=null,this['activeView']=null);}),this['listenTo'](this['editor']['editing']['view']['document'],'mousedown',(_0x1de705,_0x31a414)=>{const _0x2f8988=this['_findChangeIdFromDomTarget'](_0x31a414['target']),_0x4eaa1b=this['_changeIdToChange']['get'](_0x2f8988);_0x4eaa1b?(this['_activeViewTarget']={'x':_0x31a414['domEvent']['x'],'y':_0x31a414['domEvent']['y']},_0x4eaa1b===this['activeChange']?this['_balloon']['updatePosition']():this['activeChange']=_0x4eaa1b):(this['_activeViewTarget']=null,this['activeChange']=null);});}['_findChangeIdFromDomTarget'](_0x85fc5b){do{const _0x59af1d=_0x85fc5b['getAttribute']('data-change-id');if(_0x59af1d)return _0x59af1d;_0x85fc5b=_0x85fc5b['parent'];}while(_0x85fc5b);return null;}['_cleanMarkers'](){this['editor']['model']['change'](_0x3a4298=>{for(const _0xdcb5e1 of this['editor']['model']['markers'])_0x3a4298['removeMarker'](_0xdcb5e1);});}}function Q(_0x19e525,_0x4ab1b5){return(_0x511106,_0x11a556,_0x1e52e3)=>{if(!_0x1e52e3['consumable']['test'](_0x11a556['markerRange'],_0x511106['name']))return;const _0x293448=_0x11a556['markerRange']['getWalker'](),_0x2bb0ae=_0x11a556['markerRange']['start'],_0x4fe633=_0x19e525['model']['schema'];let _0x51024c=null,_0x34ad7d=null,_0x42ff54=!0x1,_0x361a2e=!0x1;for(const _0x245caa of _0x293448){const _0x5c3d97=_0x245caa['item'];_0x42ff54=_0x42ff54||_0x4fe633['isContent'](_0x5c3d97);const _0x330955=_0x1e52e3['mapper']['toViewElement'](_0x5c3d97);if(_0x330955&&_0x330955['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x245caa['type']&&(_0x4fe633['isBlock'](_0x5c3d97)&&!_0x4fe633['isLimit'](_0x5c3d97)&&(_0x5c3d97['nextSibling']||_0x2bb0ae['isAtEnd']?_0x51024c&&_0x51024c['parent']==_0x5c3d97||(_0x51024c=_0x5c3d97,_0x1d3b28(_0x245caa['previousPosition']),_0x361a2e=!0x0):_0x34ad7d=_0x34ad7d||_0x245caa['previousPosition']));}function _0x1d3b28(_0x4785bf){const _0x17de4c=_0x1e52e3['mapper']['toViewPosition'](_0x4785bf),_0x2f8241=_0x1e52e3['writer']['createUIElement']('span',{'class':'ck-suggestion-preview-marker-'+_0x4ab1b5});_0x1e52e3['writer']['insert'](_0x17de4c,_0x2f8241),_0x1e52e3['mapper']['bindElementToMarker'](_0x2f8241,_0x11a556['markerName']);}_0x42ff54||_0x361a2e||!_0x34ad7d||_0x1d3b28(_0x34ad7d);};}class nt extends _0x41fedf{constructor(_0x488483){super(_0x488483);const _0x306bdb=_0x488483['plugins']['get'](u);this['affectsData']=!0x1,this['listenTo'](_0x306bdb,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x306bdb,'change:isEnabled',()=>this['refresh']());}['execute'](){const _0x23c7b3=this['editor'],_0x1acbf7=_0x23c7b3['plugins']['get'](u),_0x26a32b=_0x1acbf7['isReady']?_0x1acbf7['diff']['newRevisionId']:null;_0x23c7b3['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x26a32b);}['refresh'](){const {isReady:_0x1c1cdd,isEnabled:_0x224f45,repository:_0x576ee9,diff:_0x88afbf}=this['editor']['plugins']['get'](u),_0x3edfd8=_0x88afbf&&_0x576ee9['getLaterVisibleRevision'](_0x88afbf['newRevisionId']);this['isEnabled']=_0x1c1cdd&&_0x224f45&&Boolean(_0x3edfd8);}}class ot extends _0x41fedf{['_step'];constructor(_0x2fa3f6,{direction:_0x326775}){super(_0x2fa3f6);const _0x43881c=_0x2fa3f6['plugins']['get'](u);this['affectsData']=!0x1,this['_step']='forward'===_0x326775?0x1:-0x1,this['listenTo'](_0x43881c,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x43881c,'change:isEnabled',()=>this['refresh']()),this['listenTo'](_0x43881c,'change:activeChange',()=>this['refresh']());}['execute'](){const _0x38ae5d=this['editor'],_0x16806a=_0x38ae5d['plugins']['get'](u),{isNavigationMode:_0x2b544e,currentChangeNumber:_0x37106e}=_0x16806a;let _0x33d061;if(_0x16806a['activeChange']=_0x2b544e?_0x16806a['diff']['changes']['get'](_0x37106e+this['_step']):_0x16806a['diff']['changes']['first'],_0x16806a['activeChange']['data']['isOnRoot'])_0x33d061=_0x38ae5d['editing']['view']['getDomRoot'](_0x16806a['activeChange']['rootName']);else{const _0xe0656=_0x38ae5d['model']['markers']['get']('revision:'+_0x16806a['activeChange']['id']);_0x33d061=_0x4cbb64(_0x38ae5d['editing'],_0xe0656);}_0x3c85a9({'target':_0x33d061,'viewportOffset':0x28});}['refresh'](){const {isNavigationMode:_0x436ee2,currentChangeNumber:_0x2dfa00,numberOfChanges:_0x17a5ab,isReady:_0x149b2,isEnabled:_0x4be601}=this['editor']['plugins']['get'](u);this['isEnabled']=!!(_0x4be601&&_0x149b2&&_0x17a5ab)&&(!_0x436ee2||(0x1===this['_step']?_0x2dfa00<_0x17a5ab-0x1:_0x2dfa00>0x0));}}class xi extends _0x2d19ff{constructor(_0x4249ec){super(_0x4249ec);const _0x50e300=this['bindTemplate'],_0x3e225d=new _0x3bd28b(_0x4249ec),_0x218a45=new _0x3bd28b(_0x4249ec);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',(_0x289c0e,_0xa76d9)=>_0x289c0e&&_0xa76d9>0x0),this['bind']('_statusText')['to'](this,'isReady',this,'currentChangeNumber',this,'numberOfChanges',this,'isNavigationMode',(_0x5e36d2,_0x5ca114,_0x4ac9ee,_0x3f11af)=>{if(!_0x5e36d2)return m(_0x4249ec,'Loading...');if(!_0x4ac9ee)return m(_0x4249ec,'No\x20changes');const _0x1c893e=m(_0x4249ec,'NUMBER_OF_CHANGES',_0x4ac9ee);return _0x3f11af?m(_0x4249ec,'X_OF_Y_CHANGES',[_0x5ca114+0x1,_0x4ac9ee]):_0x1c893e;}),_0x3e225d['set']({'label':m(_0x4249ec,'Show\x20previous\x20change'),'tooltip':!0x0,'icon':_0x39e6a6}),_0x218a45['set']({'label':m(_0x4249ec,'Show\x20next\x20change'),'tooltip':!0x0,'icon':_0x38ccfb}),_0x3e225d['bind']('isEnabled')['to'](this,'isBackwardNavigationEnabled'),_0x218a45['bind']('isEnabled')['to'](this,'isForwardNavigationEnabled'),_0x3e225d['on']('execute',()=>this['fire']('execute','backward')),_0x218a45['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',_0x50e300['if']('_isStatusLabelVisible','ck-hidden',_0x2a661f=>!_0x2a661f)]},'children':[{'text':_0x50e300['to']('isNavigationMode',_0x19c2f8=>_0x19c2f8?m(_0x4249ec,'EDIT_X_OF_Y_REVISIONS')+':\x20':m(_0x4249ec,'Total')+':\x20')}]},{'text':_0x50e300['to']('_statusText')}]},new _0x387a2f(),{'tag':'div','attributes':{'class':['ck-revision-history-ui__changes-navigation__navigation']},'children':[_0x3e225d,_0x218a45]}]});}}const ge='ck-editor__editable__loading-overlay';class Ri extends _0x9e7f10{static get['pluginName'](){return'RevisionViewerLoadingOverlay';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['show'](){const _0x34b146=this['editor']['editing']['view'];_0x34b146['change'](_0x12c777=>{for(const _0x4e51fd of _0x34b146['document']['roots'])_0x12c777['addClass'](ge,_0x4e51fd);});}['hide'](){const _0x1ab183=this['editor']['editing']['view'];_0x1ab183['change'](_0x17e333=>{for(const _0xd15897 of _0x1ab183['document']['roots'])_0x17e333['removeClass'](ge,_0xd15897);});}}class v extends _0x9e7f10{static get['pluginName'](){return'RevisionViewerUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[u,Ri];}['init'](){const _0x5e4b48=this['editor'],_0x4c1649=_0x5e4b48['plugins']['get'](u),_0x2710b2=_0x5e4b48['plugins']['get'](Ri);_0x5e4b48['ui']['componentFactory']['add']('exitToEditing',_0x118a2f=>{const _0x117cdc=new _0x3bd28b(_0x118a2f);return _0x117cdc['set']({'label':m(_0x118a2f,'Back\x20to\x20editing'),'icon':_0x486d8c,'withText':!0x0,'tooltip':!0x0,'class':'ck-revision-history-ui__back-to-editing'}),this['listenTo'](_0x117cdc,'execute',()=>{_0x5e4b48['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}),_0x117cdc;}),_0x5e4b48['ui']['componentFactory']['add']('restoreRevision',_0x88a491=>{const _0x2854f6=new _0x3bd28b(_0x88a491);return _0x2854f6['set']({'label':m(_0x88a491,'Restore\x20this\x20revision'),'withText':!0x0,'tooltip':!0x0}),_0x2854f6['bind']('isEnabled')['to'](_0x5e4b48['commands']['get']('restoreRevision')),this['listenTo'](_0x2854f6,'execute',()=>_0x5e4b48['execute']('restoreRevision')),_0x2854f6;}),_0x5e4b48['ui']['componentFactory']['add']('changesNavigation',_0x49e762=>{const _0x240319=new xi(_0x49e762),_0x3d1a44=_0x5e4b48['commands']['get']('showPreviousChange'),_0x1d7f35=_0x5e4b48['commands']['get']('showNextChange');return _0x240319['bind']('isBackwardNavigationEnabled')['to'](_0x3d1a44,'isEnabled'),_0x240319['bind']('isForwardNavigationEnabled')['to'](_0x1d7f35,'isEnabled'),_0x240319['bind']('isReady','currentChangeNumber','numberOfChanges','isNavigationMode')['to'](_0x4c1649),this['listenTo'](_0x240319,'execute',(_0x1ea477,_0x2d4ba3)=>{_0x5e4b48['execute']('forward'===_0x2d4ba3?'showNextChange':'showPreviousChange');}),_0x240319;}),_0x2710b2['show'](),_0x4c1649['on']('change:isReady',(_0x8af226,_0x42fcd,_0x398f8b)=>{_0x398f8b?_0x2710b2['hide']():_0x2710b2['show']();});}}class _i extends ti{['_resizeObserver']=null;constructor(_0x4c92dd,_0x4778d4){super(_0x4c92dd,_0x4778d4);const _0x518f6d=this['bindTemplate'];this['set']({'label':m(_0x4c92dd,'Revision\x20name'),'_tooltipString':''}),this['fieldView']['placeholder']=m(_0x4c92dd,'Enter\x20the\x20revision\x20name'),this['extendTemplate']({'tag':'span','attributes':{'class':['ck-revision-history-sidebar__revision-name'],'data-cke-tooltip-text':_0x518f6d['to']('_tooltipString'),'data-cke-tooltip-position':'s','data-cke-tooltip-class':'ck-tooltip_multi-line'}});}['render'](){super['render'](),this['_resizeObserver']=new et(this['fieldView']['element'],()=>this['_updateTooltipText']()),this['listenTo'](this['fieldView'],'input',()=>this['_updateTooltipText']());}['destroy'](){super['destroy'](),this['_resizeObserver']&&this['_resizeObserver']['destroy']();}['_updateTooltipText'](){const _0x224f6e=this['fieldView']['element'];this['_tooltipString']=_0x224f6e['scrollWidth']>_0x224f6e['clientWidth']&&_0x224f6e['value']||'';}}class bi extends _0x2d19ff{constructor(_0x345e1f,_0x97240f,_0x26d62a){super(_0x345e1f);const _0x166982=new _0x4c900f();_0x166982['set']({'content':_0x30f9d4,'viewBox':'0\x200\x2011\x2010'});const _0x142f13=['ck','ck-revision-history-sidebar__revision-author'];_0x26d62a&&_0x142f13['push']('ck-revision-history-sidebar__revision-author_creator');const _0x5b991d=[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision-author__name'],'title':m(_0x345e1f,_0x26d62a?'Revision\x20creator':'Revision\x20author')},'children':[_0x166982,_0x97240f['name']]}];this['setTemplate']({'tag':'li','attributes':{'class':_0x142f13},'children':_0x5b991d});}}function ki(_0x3a2ef7,_0x271a1e){const _0x2becf7=_0x3a2ef7['bindTemplate'],_0x1b4d08=_0x3a2ef7['locale'],_0x4f86ae=_0x17788b(_0x1b4d08);_0x4f86ae['panelPosition']='sw';const _0x1d67d4=function(_0x48ac25,_0x251813){const _0x1994c9=function(_0x14e92c,_0x21e471){const _0x466da1=_0x14e92c['locale'],_0x4f88ab={'Compare\x20against\x20selected':m(_0x466da1,'Compare\x20against\x20selected'),'Name\x20this\x20revision':m(_0x466da1,'Name\x20this\x20revision'),'Restore\x20this\x20revision':m(_0x466da1,'Restore\x20this\x20revision')};return _0x21e471['map'](_0x34d3b5=>{const _0x360eeb=_0x4f88ab[_0x34d3b5['name']];return _0x360eeb&&_0x360eeb!==_0x34d3b5['name']&&(_0x34d3b5['name']=_0x360eeb),_0x34d3b5;});}(_0x48ac25,_0x251813),_0x583447=new _0x99deee();for(const _0x547e8e of _0x1994c9){const _0x411987={'type':'button','model':new to({'label':_0x547e8e['name'],'class':_0x547e8e['class'],'withText':!0x0,'role':'menuitem','_action':_0x547e8e['action']})};_0x411987['model']['bind']('isEnabled')['to'](_0x48ac25,'isActionsDropdownOpen',_0x51390c=>'function'!=typeof _0x547e8e['isEnabled']||(!_0x51390c||_0x547e8e['isEnabled'](_0x48ac25))),_0x583447['add'](_0x411987);}return _0x583447;}(_0x3a2ef7,_0x271a1e);return _0x3a2ef7['bind']('isActionsDropdownOpen')['to'](_0x4f86ae,'isOpen'),_0x4f86ae['buttonView']['set']({'label':m(_0x1b4d08,'Show\x20more\x20items'),'tooltip':!0x0,'tooltipPosition':'sw','icon':_0x59fe17}),_0x4f86ae['extendTemplate']({'attributes':{'class':['ck-revision-history-sidebar__revision__actions',_0x2becf7['if']('isActionsDropdownOpen','ck-on')]},'on':{'click':_0x2becf7['to'](_0x114f3b=>_0x114f3b['stopPropagation']())}}),_0x4f86ae['on']('execute',_0x14aba0=>{_0x3a2ef7['isReady']&&'function'==typeof _0x14aba0['source']['_action']&&_0x14aba0['source']['_action'](_0x3a2ef7);}),_0x478a54(_0x4f86ae,_0x1d67d4,{'role':'menu'}),_0x4f86ae['listenTo'](_0x3a2ef7,'change:isActionsDropdownOpen',(_0x2d09e9,_0x5a5c88,_0x578acf)=>{if(_0x578acf)for(const _0x144305 of _0x4f86ae['listView']['items']){const _0x4dc4eb=_0x144305['children']['first'],_0x4fdd66=_0x271a1e['find'](_0x23583b=>_0x23583b['action']===_0x4dc4eb['_action'])['isVisible'];_0x144305['isVisible']=void 0x0===_0x4fdd66||_0x4fdd66(_0x3a2ef7);}}),_0x4f86ae;}class ci extends/* #__PURE__ -- @preserve */
|
|
27
|
-
|
|
23
|
+
import{ObservableMixin as _0x9ab2a1,uid as _0x422cf0,Collection as _0x4772da,logWarning as _0x5948a1,FocusTracker as _0x451fce,KeystrokeHandler as _0x2b80a9,scrollViewportToShowTarget as _0x3e961f,ResizeObserver as ot,ElementReplacer as it,CKEditorError as _0x3aa039}from'@ckeditor/ckeditor5-utils/dist/index.js';import{cloneDeep as _0x40b863,set as _0x4f85f2,unset as _0xaab4b,isEqual as _0x5efc66}from'es-toolkit/compat';import{Plugin as _0xf4a8c2,PendingActions as _0xf5aefe,Command as _0x3d72a2,ElementApiMixin as _0x15b0bc,Editor as _0x10091e}from'@ckeditor/ckeditor5-core/dist/index.js';import{Users as _0x1de907,getMarkerDomElement as _0x51a435,ConfirmMixin as _0x206b6c,sanitizeEditorConfig as _0x3f540c}from'ckeditor5-collaboration/dist/index.js';import{ViewContainerElement as _0x139772,ViewAttributeElement as _0x231550,ViewEmptyElement as _0x1a362d,ViewRawElement as _0x5988b9,ViewUIElement as _0x55743e,ViewDocumentFragment as _0x113415,ViewText as _0x3c6b0a,ViewElement as _0xe8ba8f,ModelElement as _0x5978e5,ModelRange as _0x1a05b7,ModelPosition as _0x3644ea,ModelDocumentFragment as _0x3269cc,ModelText as _0x44cd4c}from'@ckeditor/ckeditor5-engine/dist/index.js';import{IconHistory as _0x34181b,IconChevronUp as _0x417944,IconChevronDown as _0x1a66a1,IconUndo as _0x33482a,IconUser as _0x4185e8,IconThreeVerticalDots as _0x53ced5}from'@ckeditor/ckeditor5-icons/dist/index.js';import{CssTransitionDisablerMixin as _0x278ba5,View as _0x1252c,submitHandler as _0x2cf676,LabeledFieldView as et,createLabeledInputText as ti,createDropdown as _0x537cf1,ListView as _0x415240,ListItemView as _0x432834,ButtonView as _0x3e3281,MenuBarMenuView as _0x30aab5,MenuBarMenuListView as _0x425f1f,MenuBarMenuListItemView as _0x2805e1,MenuBarMenuListItemButtonView as _0x12d25a,ContextualBalloon as _0x867a1d,ToolbarSeparatorView as _0x3401cb,IconView as _0x5381bd,addListToDropdown as _0x13fdf3,UIModel as to,EditorUI as tt,normalizeToolbarConfig as st,BoxedEditorUIView as _0x4d5754,StickyPanelView as _0x53b49a,ToolbarView as _0x423d27,InlineEditableUIView as te}from'@ckeditor/ckeditor5-ui/dist/index.js';import{DateTime as _0x100c11}from'luxon';class I extends/* #__PURE__ -- @preserve */
|
|
24
|
+
_0x9ab2a1(){['id'];['creator'];['authors'];['diffData'];['toVersion'];['fromVersion'];['model'];constructor(_0x57831d){super(),this['id']=_0x57831d['id']||_0x422cf0(),this['creator']=_0x57831d['creator']||null,this['authors']=_0x57831d['authors']||[],this['diffData']=_0x57831d['diffData']||null,this['toVersion']=_0x57831d['toVersion']||0x0,this['fromVersion']=_0x57831d['fromVersion']||0x0,this['set']('name',_0x57831d['name']||''),this['set']('createdAt',_0x57831d['createdAt']||new Date()),this['set']('attributes',_0x57831d['attributes']||{});}['setName'](_0x1efe7a){this['_update']({'name':_0x1efe7a});}['setAttribute'](_0x2e10de,_0x318afd){const _0x3fb0c8=_0x40b863(this['attributes']);_0x4f85f2(_0x3fb0c8,_0x2e10de,_0x318afd),this['_update']({'attributes':_0x3fb0c8});}['removeAttribute'](_0x1620f6){const _0x500c4b=_0x40b863(this['attributes']);_0xaab4b(_0x500c4b,_0x1620f6),this['_update']({'attributes':_0x500c4b});}['_update'](_0x180010,_0x16bced=!0x1){let _0x328c7f=!0x1;const _0x1fbcff={'id':this['id']},_0x1ab762=['name','createdAt','diffData','authors','attributes','toVersion','fromVersion','creatorId'];for(const _0x5b8631 of _0x1ab762){const _0x50b068=_0x180010[_0x5b8631];void 0x0!==_0x50b068&&_0x50b068!==this[_0x5b8631]&&(this[_0x5b8631]=_0x50b068,_0x1fbcff[_0x5b8631]=_0x50b068,_0x328c7f=!0x0);}_0x328c7f&&(_0x1fbcff['authors']&&(_0x1fbcff['authorsIds']=_0x1fbcff['authors']['map'](_0x347e5e=>_0x347e5e['id']),delete _0x1fbcff['authors']),this['fire']('_update',_0x1fbcff,_0x16bced));}['toJSON'](){return{'id':this['id'],'name':this['name'],'creatorId':this['creator']?this['creator']['id']:null,'authorsIds':this['authors']['map'](_0x493e97=>_0x493e97['id']),'diffData':this['diffData'],'createdAt':this['createdAt'],'attributes':this['attributes'],'fromVersion':this['fromVersion'],'toVersion':this['toVersion']};}}class S extends _0xf4a8c2{['_revisions'];static get['requires'](){return[_0x1de907];}static get['pluginName'](){return'RevisionsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['length'](){return this['_revisions']['length'];}constructor(_0x172247){super(_0x172247),this['_revisions']=new _0x4772da();}['afterInit'](){!async function(_0x23e335){const _0x55be49=_0x275ab0([0x76,0x73,0x6d,0x4c,0x34,0x54,0x50,0x70,0x75,0x52,0x35,0x33,0x4d,0x6c,0x71,0x53,0x6a,0x32,0x56,0x58,0x77,0x48,0x39,0x6f,0x45,0x41,0x4e,0x38,0x46,0x78,0x4a,0x74,0x47,0x55,0x4f,0x64,0x62,0x44,0x43,0x5a,0x30,0x31,0x69,0x68,0x79,0x66,0x6b,0x42,0x51,0x59,0x36,0x61,0x63,0x67,0x7a,0x37,0x72,0x49,0x65,0x57,0x4b,0x6e]),_0x49d2de=0xeb829,_0x469fe8=0x359e09b0,_0x5f234a=0x35997778^_0x469fe8,_0x4fd7ce=window[_0x275ab0([0x44,0x61,0x74,0x65])][_0x275ab0([0x6e,0x6f,0x77])](),_0x3cd8d1=_0x23e335[_0x275ab0([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x45fa74=new window[(_0x275ab0([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x20a39c=>{_0x3cd8d1[_0x275ab0([0x6f,0x6e,0x63,0x65])](_0x275ab0([0x72,0x65,0x61,0x64,0x79]),_0x20a39c);}),_0x31ed75={[_0x275ab0([0x6b,0x74,0x79])]:_0x275ab0([0x45,0x43]),[_0x275ab0([0x75,0x73,0x65])]:_0x275ab0([0x73,0x69,0x67]),[_0x275ab0([0x63,0x72,0x76])]:_0x275ab0([0x50,0x2d,0x32,0x35,0x36]),[_0x275ab0([0x78])]:_0x275ab0([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]),[_0x275ab0([0x79])]:_0x275ab0([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]),[_0x275ab0([0x61,0x6c,0x67])]:_0x275ab0([0x45,0x53,0x32,0x35,0x36])},_0x10b2c9=_0x3cd8d1[_0x275ab0([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x275ab0([0x67,0x65,0x74])](_0x275ab0([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x2c4edd(){let _0x31df1d,_0x4f0c7c=null,_0x6341e3=null;try{if(_0x10b2c9==_0x275ab0([0x47,0x50,0x4c]))return _0x275ab0([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x31df1d=_0x1b1a24(),!_0x31df1d)return _0x275ab0([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x31df1d[_0x275ab0([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x6341e3=_0x2f8254(_0x31df1d[_0x275ab0([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x31df1d[_0x275ab0([0x6a,0x74,0x69])])),await _0x16cdc2()?_0x17c504()?_0xa1617a()?_0x275ab0([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x4a2588()?(_0x31df1d[_0x275ab0([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x275ab0([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x4f0c7c=_0x3a5266(_0x275ab0([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),await _0x1e83e0()):_0x275ab0([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x275ab0([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x275ab0([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch{return _0x275ab0([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0xa1617a(){const _0x13c60d=[_0x275ab0([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x275ab0([0x74,0x72,0x69,0x61,0x6c])][_0x275ab0([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x31df1d[_0x275ab0([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x4fd7ce/0x3e8:0xe10*_0x5f234a;return _0x31df1d[_0x275ab0([0x65,0x78,0x70])]<_0x13c60d;}function _0x17c504(){const _0x80f33a=_0x31df1d[_0x275ab0([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x80f33a)return!0x1;if(_0x80f33a[_0x275ab0([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x275ab0([0x2a])))return!0x0;if(_0x80f33a[_0x275ab0([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x275ab0([0x52,0x48])))return!0x0;if(_0x80f33a[_0x275ab0([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x275ab0([0x52,0x52,0x48]))){if(_0xfdb14a())return!0x0;if(_0x1cf1cf()||_0x63cf6e())return!0x0;}return!0x1;}function _0x4a2588(){const _0x20745d=_0x31df1d[_0x275ab0([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x20745d||0x0==_0x20745d[_0x275ab0([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x21a3c2}=new URL(window[_0x275ab0([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x20745d[_0x275ab0([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x21a3c2))return!0x0;const _0x4170a4=_0x21a3c2[_0x275ab0([0x73,0x70,0x6c,0x69,0x74])](_0x275ab0([0x2e]));return _0x20745d[_0x275ab0([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x4330e8=>_0x4330e8[_0x275ab0([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x275ab0([0x2a])))[_0x275ab0([0x6d,0x61,0x70])](_0x377292=>_0x377292[_0x275ab0([0x73,0x70,0x6c,0x69,0x74])](_0x275ab0([0x2e])))[_0x275ab0([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x4ad173=>_0x4ad173[_0x275ab0([0x6c,0x65,0x6e,0x67,0x74,0x68])]<=_0x4170a4[_0x275ab0([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x275ab0([0x6d,0x61,0x70])](_0x23fc81=>Array(_0x4170a4[_0x275ab0([0x6c,0x65,0x6e,0x67,0x74,0x68])]-_0x23fc81[_0x275ab0([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x275ab0([0x66,0x69,0x6c,0x6c])](_0x23fc81[0x0]===_0x275ab0([0x2a])?_0x275ab0([0x2a]):'')[_0x275ab0([0x63,0x6f,0x6e,0x63,0x61,0x74])](_0x23fc81))[_0x275ab0([0x73,0x6f,0x6d,0x65])](_0x538f27=>_0x4170a4[_0x275ab0([0x65,0x76,0x65,0x72,0x79])]((_0x48eb39,_0x132898)=>_0x538f27[_0x132898]===_0x48eb39||_0x538f27[_0x132898]===_0x275ab0([0x2a])));}function _0x1e83e0(){return _0x4f0c7c&&_0x6341e3?new window[(_0x275ab0([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x500cd4,_0x210c02)=>{_0x4f0c7c[_0x275ab0([0x74,0x68,0x65,0x6e])](_0x500cd4,_0x210c02),_0x6341e3[_0x275ab0([0x74,0x68,0x65,0x6e])](_0x198d16=>{_0x198d16!=_0x275ab0([0x56,0x61,0x6c,0x69,0x64])&&_0x500cd4(_0x198d16);},_0x210c02);}):_0x4f0c7c||_0x6341e3||_0x275ab0([0x56,0x61,0x6c,0x69,0x64]);}}function _0x2f8254(_0x427204,_0x11d666){return new window[(_0x275ab0([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x3994cc=>{if(_0x4b0674())return _0x3994cc(_0x275ab0([0x56,0x61,0x6c,0x69,0x64]));_0x217266(),_0x3cd8d1[_0x275ab0([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x275ab0([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x5b25b9=!0x1;const _0x541b84=_0x422cf0();function _0x4d8b04(_0x1d9b50){return!!_0x1d9b50&&(typeof _0x1d9b50===_0x275ab0([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x1d9b50===_0x275ab0([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x1d9b50[_0x275ab0([0x74,0x68,0x65,0x6e])]===_0x275ab0([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x1d9b50[_0x275ab0([0x63,0x61,0x74,0x63,0x68])]===_0x275ab0([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x7f4374(_0x507d55){_0x2edd20(_0x507d55)[_0x275ab0([0x74,0x68,0x65,0x6e])](_0x31dc0e=>{if(!_0x31dc0e||_0x31dc0e[_0x275ab0([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x275ab0([0x6f,0x6b]))return _0x275ab0([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x2b9514(_0x367308(_0x541b84+_0x11d666))!=_0x31dc0e[_0x275ab0([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x275ab0([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x275ab0([0x56,0x61,0x6c,0x69,0x64]);})[_0x275ab0([0x74,0x68,0x65,0x6e])](_0x4d25e6=>(_0x184887(),_0x4d25e6),()=>{const _0x1c0430=_0x137906();return null==_0x1c0430?(_0x184887(),_0x275ab0([0x56,0x61,0x6c,0x69,0x64])):_0x275ab0(_0x4fd7ce-_0x1c0430>(0x11928db0^_0x469fe8)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x275ab0([0x74,0x68,0x65,0x6e])](_0x3994cc)[_0x275ab0([0x63,0x61,0x74,0x63,0x68])](()=>{_0x3994cc(_0x275ab0([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x1ed56c=0x35a8e730^_0x469fe8;function _0x184887(){const _0x185017=_0x275ab0([0x6c,0x6c,0x63,0x74,0x2d])+_0x2b9514(_0x367308(_0x427204)),_0x3d14de=_0x39930c(_0x2b9514(window[_0x275ab0([0x4d,0x61,0x74,0x68])][_0x275ab0([0x63,0x65,0x69,0x6c])](_0x4fd7ce/_0x1ed56c)));window[_0x275ab0([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x275ab0([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x185017,_0x3d14de);}function _0x137906(){const _0x4e3df5=_0x275ab0([0x6c,0x6c,0x63,0x74,0x2d])+_0x2b9514(_0x367308(_0x427204)),_0x508ad6=window[_0x275ab0([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x275ab0([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x4e3df5);return _0x508ad6?window[_0x275ab0([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x39930c(_0x508ad6),0x10)*_0x1ed56c:null;}function _0x2edd20(_0x4c2521){return new window[(_0x275ab0([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x3fdf46,_0x5092b9)=>{_0x4c2521[_0x275ab0([0x74,0x68,0x65,0x6e])](_0x3fdf46,_0x5092b9),window[_0x275ab0([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x5092b9,0x359fdd70^_0x469fe8);});}}_0x3cd8d1[_0x275ab0([0x6f,0x6e])](_0x275ab0([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x133cb2,_0x387b43)=>{if(_0x387b43[0x0]!=_0x427204)return _0x3994cc(_0x275ab0([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x387b43[0x1]={..._0x387b43[0x1],[_0x275ab0([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x541b84};},{[_0x275ab0([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x275ab0([0x68,0x69,0x67,0x68])}),_0x3cd8d1[_0x275ab0([0x6f,0x6e])](_0x275ab0([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x206200=>{_0x4d8b04(_0x206200[_0x275ab0([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x5b25b9=!0x0,_0x7f4374(_0x206200[_0x275ab0([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x275ab0([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x275ab0([0x6c,0x6f,0x77])}),_0x45fa74[_0x275ab0([0x74,0x68,0x65,0x6e])](()=>{_0x5b25b9||_0x3994cc(_0x275ab0([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x4b0674(){return _0x3cd8d1[_0x275ab0([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x275ab0([0x76,0x69,0x65,0x77])][_0x275ab0([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x275ab0([0x61,0x75,0x74,0x6f]);}function _0x217266(){_0x3cd8d1[_0x275ab0([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x275ab0([0x76,0x69,0x65,0x77])][_0x275ab0([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x275ab0([0x61,0x75,0x74,0x6f]);}}function _0x3a5266(_0x9aa679){const _0x4170e5=[new window[(_0x275ab0([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x2c1053=>setTimeout(_0x2c1053,0x3597377c^_0x469fe8)),_0x45fa74[_0x275ab0([0x74,0x68,0x65,0x6e])](()=>new window[(_0x275ab0([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x152702=>{const _0x3ff2d9=0x359e09b7^_0x469fe8,_0x353582=_0x23e335[_0x275ab0([0x5f,0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x73])];function _0x27b3a5(){_0x353582[_0x275ab0([0x6c,0x65,0x6e,0x67,0x74,0x68])]>=_0x3ff2d9&&_0x152702();}_0x27b3a5(),_0x353582[_0x275ab0([0x6f,0x6e])](_0x275ab0([0x61,0x64,0x64]),_0x27b3a5);})),new window[(_0x275ab0([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x4f36fc=>{function _0x59c851(){for(const _0x17ea0f in window)if(window[_0x275ab0([0x4e,0x75,0x6d,0x62,0x65,0x72])]['isNaN'](window[_0x275ab0([0x4e,0x75,0x6d,0x62,0x65,0x72])](_0x17ea0f))&&window[_0x17ea0f]==_0x49d2de)return _0x4f36fc();_0x3cd8d1[_0x275ab0([0x73,0x74,0x61,0x74,0x65])]!=_0x275ab0([0x64,0x65,0x73,0x74,0x72,0x6f,0x79,0x65,0x64])&&window[_0x275ab0([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x59c851,0x359e1a38^_0x469fe8);}_0x5df118(_0x275ab0([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))&&_0x59c851();})];return window[_0x275ab0([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x275ab0([0x72,0x61,0x63,0x65])](_0x4170e5)[_0x275ab0([0x74,0x68,0x65,0x6e])](()=>_0x9aa679);}async function _0x3f4ea3(){if(await _0x45fa74,_0x5df118(_0x275ab0([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))){const _0x3d294f=_0x23e335[_0x275ab0([0x67,0x65,0x74,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](0x0),_0xc79858=_0x23e335[_0x275ab0([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])](_0x3d294f[_0x275ab0([0x69,0x64])]),_0x28a05b=_0x504049(_0x275ab0([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]));return await _0x28a05b[_0x275ab0([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])](_0x3d294f['id'],_0xc79858?_0xc79858['id']:null,!0x0),_0x28a05b[_0x275ab0([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x275ab0([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x28a05b[_0x275ab0([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x28a05b[_0x275ab0([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])]=_0x8161c1,void(_0x28a05b[_0x275ab0([0x5f,0x67,0x65,0x74,0x44,0x69,0x66,0x66])]=_0x8161c1);}if(_0x5df118(_0x275ab0([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]))){const _0x26b278=_0x504049(_0x275ab0([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]));_0x26b278[_0x275ab0([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x275ab0([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x26b278[_0x275ab0([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x26b278[_0x275ab0([0x75,0x70,0x64,0x61,0x74,0x65])]=_0x8161c1,_0x26b278[_0x275ab0([0x73,0x61,0x76,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])]=_0x8161c1;}_0x3cd8d1[_0x275ab0([0x6d,0x6f,0x64,0x65,0x6c])][_0x275ab0([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x8161c1,_0x3cd8d1[_0x275ab0([0x6d,0x6f,0x64,0x65,0x6c])][_0x275ab0([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x8161c1,_0x3cd8d1[_0x275ab0([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x275ab0([0x6d,0x6f,0x64,0x65,0x6c]));}function _0xfdb14a(){return _0x5df118(_0x275ab0([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x504049(_0x275ab0([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x275ab0([0x73,0x74,0x61,0x74,0x65])]==_0x275ab0([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x1cf1cf(){return _0x5df118(_0x275ab0([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 _0x63cf6e(){return _0x5df118(_0x275ab0([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0x333961(_0x38b8a2){const _0x338792=_0x2d4f15();_0x3cd8d1[_0x338792]=_0x275ab0([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])+_0x38b8a2,_0x38b8a2[_0x275ab0([0x65,0x6e,0x64,0x73,0x57,0x69,0x74,0x68])](_0x275ab0([0x4c,0x69,0x6d,0x69,0x74]))&&(window[_0x2d4f15()]=_0x49d2de),_0x38b8a2!=_0x275ab0([0x56,0x61,0x6c,0x69,0x64])&&_0x3f4ea3();}function _0x2d4f15(){const _0x1c2f07=window[_0x275ab0([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x275ab0([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x275ab0([0x6e,0x6f,0x77])]())[_0x275ab0([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x275ab0([0x2e]),'');let _0x1de6d5=_0x275ab0([0x76]);for(let _0x469ed0=0x0;_0x469ed0<_0x1c2f07[_0x275ab0([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x469ed0+=0x2){let _0x496172=window[_0x275ab0([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x1c2f07[_0x275ab0([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x469ed0,_0x469ed0+0x2));_0x496172>=_0x55be49[_0x275ab0([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x496172-=_0x55be49[_0x275ab0([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x1de6d5+=_0x55be49[_0x496172];}return _0x1de6d5;}function _0x1b1a24(){const _0x386396=_0x10b2c9[_0x275ab0([0x73,0x70,0x6c,0x69,0x74])](_0x275ab0([0x2e]));if(0x3!=_0x386396[_0x275ab0([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x262edf(_0x386396[0x1]);function _0x262edf(_0x421428){const _0x9ba062=_0x4eede2(_0x421428);return _0x9ba062&&_0x2fd161()?_0x9ba062:null;function _0x2fd161(){const _0x4789f6=_0x9ba062[_0x275ab0([0x6a,0x74,0x69])],_0x3c724f=window[_0x275ab0([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x4789f6[_0x275ab0([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x4789f6[_0x275ab0([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x11169c={..._0x9ba062,[_0x275ab0([0x6a,0x74,0x69])]:_0x4789f6[_0x275ab0([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x4789f6[_0x275ab0([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x11169c[_0x275ab0([0x76,0x63])],_0x367308(_0x11169c)==_0x3c724f;}}}async function _0x16cdc2(){let _0x21a70a=!0x0;try{const _0x2c1809=_0x10b2c9[_0x275ab0([0x73,0x70,0x6c,0x69,0x74])](_0x275ab0([0x2e])),[_0x430ba4,_0x388104,_0x387f77]=_0x2c1809;return _0x47faf3(_0x430ba4),await _0x4b0d9a(_0x430ba4,_0x388104,_0x387f77),_0x21a70a;}catch{return!0x1;}function _0x47faf3(_0x9f968d){const _0x5a9d3e=_0x4eede2(_0x9f968d);_0x5a9d3e&&_0x5a9d3e[_0x275ab0([0x61,0x6c,0x67])]==_0x275ab0([0x45,0x53,0x32,0x35,0x36])||(_0x21a70a=!0x1);}async function _0x4b0d9a(_0x455850,_0x2ba33d,_0x6eb49f){const _0x15c406=window[_0x275ab0([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x275ab0([0x66,0x72,0x6f,0x6d])](_0x4d883b(_0x6eb49f),_0x4d6d50=>_0x4d6d50[_0x275ab0([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x2dd476=new window[(_0x275ab0([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x275ab0([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x455850+_0x275ab0([0x2e])+_0x2ba33d),_0x18b6d1=window[_0x275ab0([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x275ab0([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x18b6d1)return;const _0xd2e3ed=await _0x18b6d1[_0x275ab0([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x275ab0([0x6a,0x77,0x6b]),_0x31ed75,{[_0x275ab0([0x6e,0x61,0x6d,0x65])]:_0x275ab0([0x45,0x43,0x44,0x53,0x41]),[_0x275ab0([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x275ab0([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x275ab0([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x18b6d1[_0x275ab0([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x275ab0([0x6e,0x61,0x6d,0x65])]:_0x275ab0([0x45,0x43,0x44,0x53,0x41]),[_0x275ab0([0x68,0x61,0x73,0x68])]:{[_0x275ab0([0x6e,0x61,0x6d,0x65])]:_0x275ab0([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0xd2e3ed,_0x15c406,_0x2dd476)||(_0x21a70a=!0x1);}}function _0x4eede2(_0xf01dc1){return _0xf01dc1[_0x275ab0([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x275ab0([0x65,0x79]))?JSON[_0x275ab0([0x70,0x61,0x72,0x73,0x65])](_0x4d883b(_0xf01dc1)):null;}function _0x4d883b(_0xe78f9d){return window[_0x275ab0([0x61,0x74,0x6f,0x62])](_0xe78f9d[_0x275ab0([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x275ab0([0x2b]))[_0x275ab0([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x275ab0([0x2f])));}function _0x367308(_0x4801ec){let _0x4f9dfc=0x1505;function _0x5c3861(_0x51a0ea){for(let _0x523c48=0x0;_0x523c48<_0x51a0ea[_0x275ab0([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x523c48++){const _0x5b46f7=_0x51a0ea[_0x275ab0([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x523c48);_0x4f9dfc=(_0x4f9dfc<<0x5)+_0x4f9dfc+_0x5b46f7,_0x4f9dfc&=_0x4f9dfc;}}function _0x663ced(_0x102117){Array[_0x275ab0([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x102117)?_0x102117[_0x275ab0([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x663ced):_0x102117&&typeof _0x102117==_0x275ab0([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x275ab0([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x102117)[_0x275ab0([0x73,0x6f,0x72,0x74])]()[_0x275ab0([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x5d7ebe,_0x18199f])=>{_0x5c3861(_0x5d7ebe),_0x663ced(_0x18199f);}):_0x5c3861(window[_0x275ab0([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x102117));}return _0x663ced(_0x4801ec),_0x4f9dfc>>>0x0;}function _0x2b9514(_0x318509){return _0x318509[_0x275ab0([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x275ab0([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x275ab0([0x30]));}function _0x39930c(_0x2a3a74){return _0x2a3a74[_0x275ab0([0x73,0x70,0x6c,0x69,0x74])]('')[_0x275ab0([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x275ab0([0x6a,0x6f,0x69,0x6e])]('');}function _0x5df118(_0x44863b){return _0x3cd8d1[_0x275ab0([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x275ab0([0x68,0x61,0x73])](_0x44863b);}function _0x504049(_0x4c59dc){return _0x3cd8d1[_0x275ab0([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x275ab0([0x67,0x65,0x74])](_0x4c59dc);}function _0x8161c1(){}function _0x275ab0(_0x55b60f){return _0x55b60f['map'](_0x43844d=>String['fromCharCode'](_0x43844d))['join']('');}_0x333961(await _0x2c4edd());}(this);}['createRevision'](_0x4f08fb){const _0x3d03ec=this['editor']['plugins']['get']('Users');return new I({'id':_0x4f08fb['id'],'name':_0x4f08fb['name'],'creator':_0x4f08fb['creatorId']?_0x3d03ec['getUser'](_0x4f08fb['creatorId']):null,'diffData':_0x4f08fb['diffData']||_0x4f08fb['data'],'authors':_0x4f08fb['authorsIds']['map'](_0x322c08=>_0x3d03ec['getUser'](_0x322c08)),'createdAt':new Date(_0x4f08fb['createdAt']),'attributes':_0x4f08fb['attributes'],'fromVersion':_0x4f08fb['fromVersion'],'toVersion':_0x4f08fb['toVersion']});}['addRevision'](_0x2ea695,_0xfc1f26=0x0){this['_revisions']['add'](_0x2ea695,_0xfc1f26);}['getRevision'](_0xb4a4fb){return this['_revisions']['get'](_0xb4a4fb);}['getRevisions'](_0x4b8a23={'toJSON':!0x1}){const _0x5143b2=Array['from'](this['_revisions']);return _0x5143b2['reverse'](),_0x4b8a23['toJSON']?_0x5143b2['map'](_0x3b13c2=>_0x3b13c2['toJSON']()):_0x5143b2;}['getIndex'](_0x25b4d7){return this['_revisions']['getIndex'](_0x25b4d7);}['getEarlierVisibleRevision'](_0x5328e5){const [,_0xfcb6]=this['getRevisionsIterator'](_0x5328e5,{'direction':'earlier'});return _0xfcb6;}['getLaterVisibleRevision'](_0x1085ae){const [,_0xb99702]=this['getRevisionsIterator'](_0x1085ae,{'direction':'later'});return _0xb99702;}['getRevisionsInDiff'](_0x8720b1){const _0x2835c2=[];for(const _0x473a88 of this['getRevisionsIterator'](_0x8720b1['newRevisionId']))if(_0x2835c2['push'](_0x473a88),_0x473a88['id']===_0x8720b1['oldRevisionId'])break;return _0x2835c2;}*['getRevisionsIterator'](_0x2b56f4,{direction:_0x487d9c='earlier',filter:_0x1133a7=()=>!0x0}={}){const _0x188c57='earlier'===_0x487d9c?0x1:-0x1;let _0x23c14e=this['_revisions']['get'](_0x2b56f4),_0x31e616=this['getIndex'](_0x23c14e);for(yield _0x23c14e;_0x23c14e;){if(_0x31e616+=_0x188c57,_0x23c14e=this['getRevision'](_0x31e616),!_0x23c14e)return;_0x1133a7(_0x23c14e)&&(yield _0x23c14e);}}}class $ extends _0xf4a8c2{static get['pluginName'](){return'RevisionHistoryUtils';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['_viewClassToTypeChar']=new Map([[_0x139772,'c'],[_0x231550,'a'],[_0x1a362d,'e'],[_0x5988b9,'r'],[_0x55743e,'u']]);['_typeCharToViewClass']=new Map([['c',_0x139772],['a',_0x231550],['e',_0x1a362d],['r',_0x5988b9],['u',_0x55743e]]);async['loadRevisionData'](_0x2edc8f,_0x470232){if(_0x2edc8f['diffData']||!_0x470232)return;const _0x46b543=this['editor']['config']['get']('collaboration.channelId'),_0x592b8e=await _0x470232['getRevision']({'channelId':_0x46b543,'revisionId':_0x2edc8f['id']});_0x2edc8f['diffData']=_0x592b8e['diffData'];}['getRevisionDocumentData'](_0x59f808){const _0xca0667={};for(const _0x16f9bf in _0x59f808['diffData']){if(_0x59f808['diffData'][_0x16f9bf]['attachChange']&&!_0x59f808['diffData'][_0x16f9bf]['attachChange']['isAttached'])continue;const _0x89588c=this['_removeRevisionMarkers'](JSON['parse'](_0x59f808['diffData'][_0x16f9bf]['insertions'])),_0x38a71f=this['editor']['editing']['view']['document'],_0x35cac1=new _0x113415(_0x38a71f,_0x89588c['map'](_0x3a23eb=>this['_getViewFromDiffObj'](_0x3a23eb,!0x1)));this['editor']['data']['processor']['useFillerType']('marked'),_0xca0667[_0x16f9bf]=this['editor']['data']['processor']['toData'](_0x35cac1),this['editor']['data']['processor']['useFillerType']('default');}return _0xca0667;}['getRevisionRootsAttributes'](_0x222fd4){const _0x4f2317={};for(const _0x4f8c9d in _0x222fd4['diffData'])_0x222fd4['diffData'][_0x4f8c9d]['attachChange']&&!_0x222fd4['diffData'][_0x4f8c9d]['attachChange']['isAttached']||(_0x4f2317[_0x4f8c9d]=_0x222fd4['diffData'][_0x4f8c9d]['attributesAfter']||{});return _0x4f2317;}['_getTypeCharForViewElement'](_0x4b2dfe){return this['_viewClassToTypeChar']['get'](_0x4b2dfe['constructor']);}['_getViewFromDiffObj'](_0x6b70cb,_0x313431){const _0x1eeb80=this['editor']['editing']['view']['document'];if('string'==typeof _0x6b70cb)return new _0x3c6b0a(_0x1eeb80,_0x6b70cb);{let _0x15c432,_0x5e445c;_0x5e445c='u'==_0x6b70cb['type']||'r'==_0x6b70cb['type']?[]:_0x6b70cb['children']['map'](_0x578003=>this['_getViewFromDiffObj'](_0x578003,_0x313431));const _0x41b4c6=this['_typeCharToViewClass']['get'](_0x6b70cb['type'])||_0xe8ba8f,_0x4c4f9b=this['editor']['data']['htmlProcessor']['domConverter'];if(_0x15c432=new _0x41b4c6(_0x1eeb80,_0x6b70cb['name'],_0x6b70cb['attributes'],_0x5e445c),'u'==_0x6b70cb['type']&&_0x6b70cb['children'][0x0]){const _0x5a051d=_0x6b70cb['children'][0x0];if(_0x15c432['render']=function(_0x44d51c){const _0x506f86=_0x44d51c['createElement']('div');return _0x506f86['innerHTML']=_0x5a051d,_0x506f86['childNodes'][0x0];},_0x313431){const _0x7bf7b7=new _0x113415(_0x1eeb80);_0x7bf7b7['_appendChild'](_0x15c432);const _0x4bd8a4=Array['from'](_0x4c4f9b['viewChildrenToDom'](_0x7bf7b7,{'bind':!0x1})),_0x2f4fd4=_0x4c4f9b['domDocument']['createElement']('div');_0x2f4fd4['append'](..._0x4bd8a4),_0x15c432=Array['from'](_0x4c4f9b['domChildrenToView'](_0x2f4fd4))[0x0];}}else{if('r'==_0x6b70cb['type']&&_0x6b70cb['children'][0x0]){const _0x26a6d3=_0x6b70cb['children'][0x0];if(_0x15c432['render']=function(_0x291193){_0x291193['innerHTML']=_0x26a6d3;},_0x313431){const _0x1dd02e=new _0x113415(_0x1eeb80);_0x1dd02e['_appendChild'](_0x15c432);const _0x542cba=Array['from'](_0x4c4f9b['viewChildrenToDom'](_0x1dd02e,{'bind':!0x1})),_0x58b442=_0x4c4f9b['domDocument']['createElement']('div');_0x58b442['append'](..._0x542cba);const _0x59f899=Array['from'](_0x4c4f9b['domChildrenToView'](_0x58b442));_0x59f899['length']>0x1?_0x15c432['_appendChild'](_0x59f899):_0x15c432=_0x59f899[0x0];}}}if(_0x6b70cb['customProperties']){for(const [_0x2b0fc5,_0x11d158]of _0x6b70cb['customProperties'])_0x15c432['_setCustomProperty'](_0x2b0fc5,_0x11d158);}const _0x2809cc=void 0x0===_0x6b70cb['fillerOffset']?null:_0x6b70cb['fillerOffset'];return null!==_0x2809cc&&(_0x15c432['getFillerOffset']=()=>_0x2809cc),_0x15c432;}}['_makeModelFromViewString'](_0x41a791){const _0x243cf9=JSON['parse'](_0x41a791),_0x49c265=this['editor']['editing']['view']['document'],_0xac26c5=new _0x113415(_0x49c265,_0x243cf9['map'](_0x18899e=>this['_getViewFromDiffObj'](_0x18899e,!0x0)));return this['editor']['data']['toModel'](_0xac26c5);}['_removeRevisionMarkers'](_0x66f19b){return(_0x66f19b=_0x66f19b['filter'](_0x1a6ec4=>!_0x1a6ec4['name']||'revision-start'!==_0x1a6ec4['name']&&'revision-end'!==_0x1a6ec4['name']))['forEach'](_0x4daba8=>{'string'!=typeof _0x4daba8&&(_0x4daba8['children']=this['_removeRevisionMarkers'](_0x4daba8['children']),_0x4daba8['attributes']=_0x4daba8['attributes']['filter'](_0x3cf8c6=>!_0x3cf8c6[0x0]['startsWith']('data-revision-')));}),_0x66f19b;}}function m(_0x56e051,_0x48fed8,_0x54aaaf){const t=_0x56e051['t'];switch(_0x48fed8){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'},_0x54aaaf);case'X_OF_Y_CHANGES':return t({'string':'%0\x20of\x20%1','id':'X_OF_Y_CHANGES'},_0x54aaaf);case'Show\x20previous\x20change':return t('Show\x20previous\x20change');case'Show\x20next\x20change':return t('Show\x20next\x20change');case'EDIT_X_OF_Y_REVISIONS':return t({'string':'Edit','id':'EDIT_X_OF_Y_REVISIONS'});case'Total':return t('Total');case'Revision\x20creator':return t('Revision\x20creator');case'Revision\x20author':return t('Revision\x20author');case'Revision\x20name':return t('Revision\x20name');case'Save\x20current\x20revision':return t('Save\x20current\x20revision');case'Accept':return t('Accept');case'Save':return t('Save');case'Cancel':return t('Cancel');case'Name\x20of\x20the\x20revision':return t('Name\x20of\x20the\x20revision');case'optional':return t('optional');case'PENDING_ACTION_REVISION_HISTORY':return t({'string':'Unsaved\x20change\x20in\x20revision\x20history.','id':'PENDING_ACTION_REVISION_HISTORY'});case'The\x20revision\x20name\x20cannot\x20be\x20empty.':return t('The\x20revision\x20name\x20cannot\x20be\x20empty.');case'Enter\x20the\x20revision\x20name':return t('Enter\x20the\x20revision\x20name');default:return'';}}class h extends _0xf4a8c2{['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[_0x1de907,S,$,_0xf5aefe];}constructor(_0x2a98fa){super(_0x2a98fa),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 _0x812c68=_0x422cf0();this['_source']={'history':this['editor']['model']['document']['history'],'getLatestVersion':()=>Promise['resolve'](this['editor']['model']['document']['version']),'getCurrentRevisionId':()=>_0x812c68},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 _0x254383=this['repository']['getRevision'](0x0),_0x387a82=_0x254383&&null===_0x254383['creator']?_0x254383:null;if(this['_continueCurrentRevision']=!!_0x387a82&&this['editor']['config']['get']('revisionHistory.resumeUnsavedRevision'),this['editor']['plugins']['has']('RealTimeCollaborationClient')){const _0x54e511=this['_source']['getCurrentRevisionId'](),_0x41e92b=this['repository']['getRevision'](_0x54e511);if(_0x41e92b)this['_startingVersion']=_0x41e92b['fromVersion'],this['_continueCurrentRevision']=!0x1;else{const _0x5ea80f=this['_source']['history']['_operations']['find'](_0x3e3b7c=>!_0x3e3b7c['_isInit']),_0x5db349=_0x5ea80f?_0x5ea80f['baseVersion']:this['_source']['history']['version'];_0x254383?(_0x254383['toVersion']<_0x5db349&&_0x254383['_update']({'toVersion':_0x5db349}),this['_continueCurrentRevision']?(this['_source']['getCurrentRevisionId']=()=>_0x387a82['id'],this['_startingVersion']=_0x387a82['fromVersion']):(this['_startingVersion']=_0x254383['toVersion'],this['_continueCurrentRevision']=!0x1)):(this['_startingVersion']=_0x5db349,this['_continueCurrentRevision']=!0x1);}}else _0x387a82&&(this['editor']['model']['document']['history']['version']=Math['max'](_0x387a82['toVersion'],this['editor']['model']['document']['history']['version']),_0x387a82['fromVersion']===_0x387a82['toVersion']?(0x0!==_0x387a82['fromVersion']&&(this['_source']['getCurrentRevisionId']=()=>_0x387a82['id']),this['_continueCurrentRevision']=!0x1):this['_continueCurrentRevision']&&(this['_source']['getCurrentRevisionId']=()=>_0x387a82['id'],this['_startingVersion']=_0x387a82['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',_0x441d39=>!_0x441d39),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x2a5a56=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x2dd21c;for(const _0x27a624 in _0x2a5a56){const _0x38e89b=_0x27a624,_0x1c4bd2=_0x2a5a56[_0x38e89b];if('revisionHistoryLicenseKeyValid'==_0x1c4bd2||'revisionHistoryLicenseKeyInvalid'==_0x1c4bd2||'revisionHistoryLicenseKeyExpired'==_0x1c4bd2||'revisionHistoryLicenseKeyDomainLimit'==_0x1c4bd2||'revisionHistoryLicenseKeyNotAllowed'==_0x1c4bd2||'revisionHistoryLicenseKeyEvaluationLimit'==_0x1c4bd2||'revisionHistoryLicenseKeyUsageLimit'==_0x1c4bd2){delete _0x2a5a56[_0x38e89b],_0x2dd21c=_0x1c4bd2,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'revisionHistoryLicenseKeyInvalid'==_0x2dd21c&&_0x2a5a56['_showLicenseError']('invalid'),'revisionHistoryLicenseKeyExpired'==_0x2dd21c&&_0x2a5a56['_showLicenseError']('expired'),'revisionHistoryLicenseKeyDomainLimit'==_0x2dd21c&&_0x2a5a56['_showLicenseError']('domainLimit'),'revisionHistoryLicenseKeyNotAllowed'==_0x2dd21c&&_0x2a5a56['_showLicenseError']('featureNotAllowed','RevisionHistory'),'revisionHistoryLicenseKeyEvaluationLimit'==_0x2dd21c&&_0x2a5a56['_showLicenseError']('evaluationLimit'),'revisionHistoryLicenseKeyUsageLimit'==_0x2dd21c&&_0x2a5a56['_showLicenseError']('usageLimit');},0x3e8);}async['afterInit'](){if(this['repository']['length']>0x0){const _0x274b10=this['repository']['getRevision'](0x0),_0x56a986=await this['getRevisionDocumentData'](_0x274b10),_0x53966e=await this['getRevisionRootsAttributes'](_0x274b10);this['_replaceEditorDataWithRevisionData'](_0x56a986,_0x53966e);}}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['setSource'](_0x2cb1ea){this['_source']=_0x2cb1ea;}async['update'](){const _0x162b36=await this['_source']['getLatestVersion']();if(_0x162b36>this['currentRevision']['toVersion']){await this['_loadState']();const _0x490c18=this['buildRevisionData']({'revision':this['currentRevision'],'to':_0x162b36});_0x490c18['authors']=_0x490c18['authorsIds']['map'](_0x3e1027=>this['editor']['plugins']['get']('Users')['getUser'](_0x3e1027)),this['currentRevision']['_update'](_0x490c18);}}async['saveRevision'](_0x2266e7={},_0x4637bb=null){const _0x52f4c1=[];await this['_loadState'](),this['_continueCurrentRevision']=!0x1,_0x4637bb>this['currentRevision']['toVersion']&&(_0x4637bb=null),null===_0x4637bb&&(_0x4637bb=await this['_source']['getLatestVersion']());const _0x48d565=this['_getFromVersion'](_0x4637bb),_0x1112af=this['buildRevisionData']({'from':_0x48d565,'to':_0x4637bb});if(this['currentRevision']['toVersion']<_0x4637bb){const _0x1a277b=this['buildRevisionData']({'revision':this['currentRevision'],'from':_0x4637bb,'to':_0x4637bb});_0x1a277b['authors']=[],_0x1a277b['authorsIds']=[],_0x1a277b['id']=this['currentRevision']['id'],this['currentRevision']['_update'](_0x1a277b,!0x0),delete _0x1a277b['authors'],_0x52f4c1['push'](_0x1a277b);}_0x2266e7['creatorId']=this['editor']['plugins']['get']('Users')['me']['id'],_0x2266e7['name']=_0x2266e7['name']||null,_0x2266e7['id']=_0x2266e7['id']||_0x422cf0(),_0x2266e7={..._0x2266e7,..._0x1112af};const _0x2a461c=this['addRevisionData'](_0x2266e7);_0x52f4c1['push'](_0x2266e7);const _0x21d9c8=this['repository']['getIndex'](_0x2a461c);if(0x0!==_0x21d9c8){const _0x1e3363=this['repository']['getRevision'](_0x21d9c8-0x1);if(_0x1e3363['fromVersion']!==_0x4637bb){const _0x4020d8=this['_revisionDataBuilder']['getData'](_0x4637bb,_0x1e3363['toVersion']),_0x5468a5={'id':_0x1e3363['id'],'diffData':_0x4020d8['diffData'],'authorsIds':_0x4020d8['authorsIds'],'authors':_0x4020d8['authorsIds']['map'](_0x2cc8dd=>this['editor']['plugins']['get']('Users')['getUser'](_0x2cc8dd)),'fromVersion':_0x4637bb};_0x1e3363===this['currentRevision']&&(_0x5468a5['createdAt']=new Date(_0x2266e7['createdAt']['getTime']()+0xa)),_0x1e3363['_update'](_0x5468a5,!0x0),delete _0x5468a5['authors'],_0x52f4c1['push'](_0x5468a5);}}if(this['adapter']){for(const _0x216b88 of _0x52f4c1)this['_bufferUpdate'](_0x216b88['id'],_0x216b88,!0x0);this['sendBufferedUpdates']();}return _0x2a461c;}['addRevisionData'](_0x160e09){const _0x91db43=this['repository']['createRevision'](_0x160e09);return this['adapter']&&_0x91db43['on']('_update',(_0x49822f,_0xb06853,_0x38295c)=>{_0x38295c||(this['_bufferUpdate'](_0xb06853['id'],_0xb06853,!0x0),this['sendBufferedUpdates']());}),this['repository']['addRevision'](_0x91db43,this['_findInsertionIndex'](_0x91db43)),_0x91db43;}async['getRevisionDocumentData'](_0x1d090){return await this['_utils']['loadRevisionData'](_0x1d090,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x1d090);}async['getRevisionRootsAttributes'](_0x585ca4){return await this['_utils']['loadRevisionData'](_0x585ca4,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x585ca4);}['sendBufferedUpdates'](){if(0x0===this['_bufferedUpdates']['size'])return;if(this['_isPendingUpdate'])return;let _0x44dc24=Array['from'](this['_bufferedUpdates']['values']());this['_bufferedUpdates']['clear']();for(let _0x4fca51=0x0;_0x4fca51<_0x44dc24['length'];_0x4fca51++){const _0x5134ee=_0x44dc24[_0x4fca51];let _0x31ad8=!0x1;for(const _0x418558 of Object['keys'](_0x5134ee))void 0x0===_0x5134ee[_0x418558]?delete _0x5134ee[_0x418558]:'id'!==_0x418558&&(_0x31ad8=!0x0);_0x31ad8||(_0x44dc24[_0x4fca51]=null);}if(_0x44dc24=_0x44dc24['filter'](_0x50bf66=>null!==_0x50bf66),!_0x44dc24['length'])return;for(let _0x5ce264=0x0;_0x5ce264<_0x44dc24['length'];_0x5ce264++){const _0x22eac3=_0x44dc24[_0x5ce264];void 0x0!==_0x22eac3['fromVersion']&&void 0x0===_0x22eac3['toVersion']&&(_0x22eac3['toVersion']=this['repository']['getRevision'](_0x22eac3['id'])['toVersion']),void 0x0!==_0x22eac3['toVersion']&&void 0x0===_0x22eac3['fromVersion']&&(_0x22eac3['fromVersion']=this['repository']['getRevision'](_0x22eac3['id'])['fromVersion']);}const _0xc92092=this['editor']['config']['get']('collaboration.channelId');this['_isPendingUpdate']=!0x0,this['_addPendingAction'](),this['adapter']['updateRevisions'](_0x44dc24,_0xc92092)['finally'](()=>{this['_isPendingUpdate']=!0x1;})['then'](_0x1aed03=>{if(_0x1aed03){for(const _0x42d1d7 of _0x1aed03)this['setRevisionData']({'id':_0x42d1d7['id'],'createdAt':_0x42d1d7['createdAt']});}this['_removePendingAction'](),this['sendBufferedUpdates']();});}['buildRevisionData']({revision:_0xc5805c=null,from:_0x27498c=null,to:_0x592f96=null}){_0x27498c=null!==_0x27498c?_0x27498c:_0xc5805c['fromVersion'],_0x592f96=null!==_0x592f96?_0x592f96:_0xc5805c['toVersion'];const _0x6a6347=this['_revisionDataBuilder']['getData'](_0x27498c,_0x592f96),_0x14834a={'diffData':_0x6a6347['diffData'],'authorsIds':_0x6a6347['authorsIds'],'fromVersion':_0x27498c,'toVersion':_0x592f96};if(!_0xc5805c||_0x592f96!==_0xc5805c['toVersion']){const _0x14dfa2=_0x592f96-0x1,_0x375a8b=this['_source']['history']['getOperation'](_0x14dfa2);_0x14834a['createdAt']=_0x375a8b&&_0x375a8b['createdAt']||new Date();}if(this['_loadedStateData']&&_0x27498c===this['_loadedStateData']['fromVersion']){for(const _0x56ee81 of this['_loadedStateData']['authors'])_0x14834a['authorsIds']['includes'](_0x56ee81['id'])||_0x14834a['authorsIds']['push'](_0x56ee81['id']);}return _0x14834a;}['_bufferUpdate'](_0x3f413d,_0x48c206,_0xf77a07){if(this['_bufferedUpdates']['has'](_0x3f413d)){const _0xc83b3d=this['_bufferedUpdates']['get'](_0x3f413d);_0x48c206=_0xf77a07?{..._0xc83b3d,..._0x48c206}:{..._0x48c206,..._0xc83b3d};}this['_bufferedUpdates']['set'](_0x3f413d,_0x48c206);}['setRevisionData'](_0x4653fa){const _0x35edb2=this['repository']['getRevision'](_0x4653fa['id']);if(_0x4653fa['createdAt']&&(_0x4653fa['createdAt']=new Date(_0x4653fa['createdAt'])),_0x4653fa['authorsIds']){const _0xa62391=this['editor']['plugins']['get']('Users');_0x4653fa['authors']=_0x4653fa['authorsIds']['map'](_0x3ed95e=>_0xa62391['getUser'](_0x3ed95e));}_0x35edb2['_update'](_0x4653fa,!0x0);}['_createInitialRevision'](_0x23e30c){const _0x19556d=this['repository']['getRevision'](this['repository']['length']-0x1);if(_0x19556d)this['_initialRevisionId']=_0x19556d['id'];else{const _0x43eec3=!this['editor']['model']['document']['roots']['find'](_0x368f59=>this['editor']['model']['hasContent'](_0x368f59)),_0x57042e=this['editor']['plugins']['get']('Users')['me']['id'],_0x5e76ff=m(this['editor']['locale'],_0x43eec3?'Empty\x20document':'Initial\x20revision');this['_makeRevision']({'from':_0x23e30c,'to':_0x23e30c,'id':this['_initialRevisionId'],'name':_0x5e76ff,'creatorId':_0x57042e});}}['_createCurrentRevision'](_0x27a0f6){const _0x532b92=this['_source']['getCurrentRevisionId']();this['currentRevision']=this['repository']['getRevision'](_0x532b92),this['currentRevision']||(this['currentRevision']=this['_makeRevision']({'from':_0x27a0f6,'to':_0x27a0f6,'id':_0x532b92,'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'](_0x5e9ae4,_0x59a102){let _0x2af575=this['editor']['config']['get']('initialData'),_0x4a4ced=this['editor']['config']['get']('rootsAttributes');if(void 0x0===_0x2af575){_0x2af575={};for(const _0x2fb7bd of this['editor']['model']['document']['getRootNames']())_0x2af575[_0x2fb7bd]='';}if('string'==typeof _0x2af575&&(_0x2af575={'main':_0x2af575}),void 0x0===_0x4a4ced){_0x4a4ced={};for(const _0x187567 of this['editor']['model']['document']['getRootNames']())_0x4a4ced[_0x187567]={};}let _0x19d110=!0x1;const _0x1956c5=Object['keys'](_0x2af575),_0x480cf8=Object['keys'](_0x5e9ae4);for(const _0x405339 of _0x1956c5){if(_0x2af575[_0x405339]!==_0x5e9ae4[_0x405339]&&''!==_0x2af575[_0x405339]['trim']()){_0x19d110=!0x0;break;}if(!_0x5efc66(_0x4a4ced[_0x405339],_0x59a102[_0x405339])&&Object['keys'](_0x4a4ced[_0x405339])['length']>0x0){_0x19d110=!0x0;break;}}_0x19d110||(_0x19d110=_0x480cf8['some'](_0x2e16be=>!this['editor']['model']['document']['getRoot'](_0x2e16be))),_0x19d110&&_0x5948a1('editor-initial-data-replaced-with-revision-data',{'editorData':_0x2af575,'editorRootsAttributes':_0x4a4ced,'revisionData':_0x5e9ae4,'revisionRootsAttributes':_0x59a102}),this['editor']['config']['set']('initialData',_0x5e9ae4),this['editor']['config']['set']('rootsAttributes',_0x59a102);}['_addPendingAction'](){if(!this['_pendingAction']){const _0x25ebe4=this['editor']['plugins']['get']('PendingActions');this['_pendingAction']=_0x25ebe4['add'](m(this['editor']['locale'],'PENDING_ACTION_REVISION_HISTORY'));}}['_removePendingAction'](){this['_pendingAction']&&(this['editor']['plugins']['get']('PendingActions')['remove'](this['_pendingAction']),this['_pendingAction']=null);}['_findInsertionIndex'](_0x445585){const _0x472ae6=this['repository']['getRevisions']();_0x472ae6['reverse']();let _0x2053b5=0x0;for(;_0x2053b5<_0x472ae6['length'];){const _0x4994c4=_0x472ae6[_0x2053b5];if(_0x4994c4===this['currentRevision']){_0x2053b5++;continue;}if(_0x4994c4['id']===this['_initialRevisionId'])break;const _0xcef51e=_0x445585['toVersion']-_0x4994c4['toVersion']||_0x445585['fromVersion']-_0x4994c4['fromVersion'];if(_0xcef51e>0x0)break;if(_0xcef51e<0x0)_0x2053b5++;else{if(!_0x445585['creator']&&_0x4994c4['creator'])break;if(_0x4994c4['creator']||!_0x445585['creator']){if(_0x445585['createdAt']>_0x4994c4['createdAt'])break;_0x2053b5++;}else _0x2053b5++;}}return _0x2053b5;}['_getFromVersion'](_0x11bb56){const _0x49ff6f=this['repository']['getRevisions']();_0x49ff6f['reverse'](),_0x49ff6f['shift']();const _0x44b71f=_0x49ff6f['find'](_0x4183b2=>_0x4183b2['toVersion']<=_0x11bb56)['toVersion'];return _0x44b71f<this['_startingVersion']?this['_startingVersion']:_0x44b71f;}['_makeRevision']({name:_0x16bfc9,from:_0x162cb7,to:_0x1a74c4,creatorId:_0x40a3b4,id:_0x7c414a}){const _0x877662=this['buildRevisionData']({'from':_0x162cb7,'to':_0x1a74c4});_0x877662['name']=_0x16bfc9,_0x877662['creatorId']=_0x40a3b4,_0x877662['id']=_0x7c414a;const _0x35b488=this['addRevisionData'](_0x877662);return this['adapter']&&this['_bufferUpdate'](_0x877662['id'],_0x877662,!0x0),_0x35b488;}['_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(_0x3f6865){this['editor']=_0x3f6865,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'](_0x42863a){this['source']=_0x42863a;const _0x9a22b=new Map(),_0x55afe8=new Map(),_0x5cdac8=this['editor']['model']['document']['roots']['map'](_0x337a18=>_0x337a18['rootName']);for(const _0x13a858 of _0x5cdac8){const _0x4a4610=this['editor']['model']['document']['getRoot'](_0x13a858),_0x24a9fd=K(_0x4a4610);_0x9a22b['set'](_0x13a858,_0x24a9fd),_0x55afe8['set'](_0x13a858,Object['fromEntries'](_0x4a4610['getAttributes']()));}const _0x1c18ed=Array['from'](this['editor']['model']['markers'])['map'](_0x32a13a=>[_0x32a13a['name'],_0x32a13a['getRange']()]),_0x1a30e5=this['source']['version'];this['_saveMetaData'](_0x1a30e5,_0x9a22b,_0x1c18ed,_0x55afe8),this['_startingRevisionId']=this['_revisionId'];const _0x1afaa3=new Map(),_0x5dd6b1=new Map();for(const _0xc5b284 of _0x5cdac8){const _0x59d124=N(_0xc5b284);_0x1afaa3['set'](_0xc5b284,_0x59d124),_0x5dd6b1['set'](_0xc5b284,{});}this['_saveMetaData'](Number['NEGATIVE_INFINITY'],_0x1afaa3,[],_0x5dd6b1);}['getData'](_0x3736e1,_0x31ccd0){if(this['_lastFrom']===_0x3736e1&&this['_lastTo']<=_0x31ccd0)this['_savedMetaData']['size']>0x1&&this['_removeMetaData'](this['_lastTo']),this['_applyOperations'](this['_lastTo'],_0x31ccd0,!0x0);else{if(!this['_savedMetaData']['has'](_0x3736e1)){const _0x573de1=this['_getPreviousFrom'](_0x3736e1);this['_calculateMetaData'](_0x573de1,_0x3736e1,!0x1);}this['_calculateMetaData'](_0x3736e1,_0x31ccd0,!0x0);}return this['_lastFrom']=_0x3736e1,this['_lastTo']=_0x31ccd0,this['_getState']();}['loadState'](_0x5f514f){if(!this['_savedMetaData']['has'](_0x5f514f['fromVersion'])){const _0x20bdb8=this['_getPreviousFrom'](_0x5f514f['fromVersion']);this['_calculateMetaData'](_0x20bdb8,_0x5f514f['fromVersion'],!0x1);}this['_calculateMetaData'](_0x5f514f['fromVersion'],_0x5f514f['toVersion'],!0x1);const _0xf11e51=this['editor']['plugins']['get']('RevisionHistoryUtils');this['_reset'](),this['_lastFrom']=_0x5f514f['fromVersion'],this['_lastTo']=_0x5f514f['toVersion'];for(const _0x2ca6b0 in _0x5f514f['diffData']){const _0x33261e=_0x5f514f['diffData'][_0x2ca6b0]['attachChange'],_0x11b442=_0x40b863(_0x5f514f['diffData'][_0x2ca6b0]['attributesBefore'])||{},_0x1b5c55=_0xf11e51['_makeModelFromViewString'](_0x5f514f['diffData'][_0x2ca6b0]['deletions']);_0x1b5c55['rootName']=_0x2ca6b0,_0x1b5c55['_isAttached']=!_0x33261e||!_0x33261e['isAttached'],_0x1b5c55['isAttached']=()=>_0x1b5c55['_isAttached'],this['_baseRoots']['set'](_0x2ca6b0,_0x1b5c55),this['_baseRootsAttributes']['set'](_0x2ca6b0,_0x11b442),_0x33261e&&this['_touchedRoots']['set'](_0x2ca6b0,_0x33261e);const _0x5170c8=this['_makeIdsRoot'](_0x1b5c55);this['_baseIdsRoots']['set'](_0x2ca6b0,_0x5170c8);for(const [_0x34c8ce,_0x33b783]of _0x1b5c55['markers']){if(!_0x34c8ce['startsWith']('revision:'))continue;const _0x4cc316=_0x34c8ce['split'](':')[0x2];for(const _0x528914 of _0x33b783['getWalker']({'singleCharacters':!0x0})){const _0xe65c0d=this['_getVidAttributeName'](_0x528914),_0x662b23='elementEnd'==_0x528914['type']?_0x528914['previousPosition']['path']['slice'](0x0,-0x1):_0x528914['previousPosition']['path'],_0x4f2aec=_0x5170c8['getNodeByPath'](_0x662b23)['getAttribute'](_0xe65c0d);this['_touched']['set'](_0x4f2aec,{'userId':_0x4cc316});}_0x1b5c55['markers']['delete'](_0x34c8ce);}}this['_startingRevisionId']=this['_revisionId'];const _0x5604d8=[...Array(this['_revisionId'])['keys']()]['slice'](0x1)['filter'](_0x84cd19=>!this['_touched']['has'](_0x84cd19));let _0x4b373d=0x0;const _0x1577e3=new Map();for(const _0x1c3310 in _0x5f514f['diffData']){const _0x34caba=_0x5f514f['diffData'][_0x1c3310]['attachChange'],_0x302b9f=_0x40b863(_0x5f514f['diffData'][_0x1c3310]['attributesAfter'])||{},_0x50a4ef=_0xf11e51['_makeModelFromViewString'](_0x5f514f['diffData'][_0x1c3310]['insertions']);_0x50a4ef['rootName']=_0x1c3310,_0x50a4ef['_isAttached']=!_0x34caba||_0x34caba['isAttached'],_0x50a4ef['isAttached']=()=>_0x50a4ef['_isAttached'],this['_diffRoots']['set'](_0x1c3310,_0x50a4ef),this['_diffRootsAttributes']['set'](_0x1c3310,_0x302b9f);const _0x254bf2=this['_makeIdsRoot'](_0x50a4ef,Number['NEGATIVE_INFINITY']);this['_idsRoots']['set'](_0x1c3310,_0x254bf2),_0x1577e3['set'](_0x1c3310,_0x50a4ef['isAttached']()?_0x302b9f:{});for(const [_0x25c35d,_0x53e627]of _0x50a4ef['markers']){if(!_0x25c35d['startsWith']('revision:'))continue;const _0x3a2ec7=_0x25c35d['split'](':')[0x2];for(const _0xf4a1b9 of _0x53e627['getWalker']({'singleCharacters':!0x0})){const _0x32e4f7=this['_getVidAttributeName'](_0xf4a1b9),_0x395d4b=this['_revisionId']++,_0x1265d8='elementEnd'==_0xf4a1b9['type']?_0xf4a1b9['previousPosition']['path']['slice'](0x0,-0x1):_0xf4a1b9['previousPosition']['path'];_0x254bf2['getNodeByPath'](_0x1265d8)['_setAttribute'](_0x32e4f7,_0x395d4b),this['_touched']['set'](_0x395d4b,{'userId':_0x3a2ec7});}_0x50a4ef['markers']['delete'](_0x25c35d);}for(const _0x4737d6 of this['editor']['model']['createRangeIn'](_0x50a4ef)['getWalker']({'singleCharacters':!0x0})){const _0x1cfed4=this['_getVidAttributeName'](_0x4737d6),_0x168482='elementEnd'==_0x4737d6['type']?_0x4737d6['previousPosition']['path']['slice'](0x0,-0x1):_0x4737d6['previousPosition']['path'],_0x589c76=_0x254bf2['getNodeByPath'](_0x168482);_0x589c76['getAttribute'](_0x1cfed4)>0x0||_0x589c76['_setAttribute'](_0x1cfed4,_0x5604d8[_0x4b373d++]);}for(const [_0x23f03c,_0x275cde]of _0x50a4ef['markers'])_0x23f03c['startsWith']('revision:')||this['_markers']['set'](_0x23f03c,_0x275cde);}const {roots:_0x3317f2}=this['_savedMetaData']['get'](_0x5f514f['fromVersion']),{roots:_0x3b0272}=this['_savedMetaData']['get'](_0x5f514f['toVersion']),_0xba3a83=K(_0x3317f2['get']('$graveyard'));this['_baseRoots']['set']('$graveyard',_0xba3a83),this['_baseIdsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0xba3a83,Number['NEGATIVE_INFINITY']));const _0x3d7717=K(_0x3b0272['get']('$graveyard'));this['_diffRoots']['set']('$graveyard',_0x3d7717),this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x3d7717));const _0x5f8aa4=Array['from'](this['_diffRoots'])['map'](([_0x584596,_0x5701df])=>[_0x584596,K(_0x5701df)]);this['_saveMetaData'](this['_lastTo'],_0x5f8aa4,this['_markers'],_0x1577e3);}['reInit'](){this['_reset'](),this['_lastFrom']=-0x1,this['_lastTo']=-0x1,this['_savedMetaData']['clear'](),this['init'](this['source']);}['_saveMetaData'](_0x280e5f,_0x302bb9,_0x49fce2,_0x5a1ef9){const _0x2457e0=new Map(_0x302bb9),_0x463062=new Map(_0x40b863(_0x5a1ef9)),_0x479c6b=new Map();for(const [_0x394978,_0x53bf4f]of _0x49fce2)_0x479c6b['set'](_0x394978,{'start':_0x53bf4f['start']['clone'](),'end':_0x53bf4f['end']['clone'](),'rootName':_0x53bf4f['root']['rootName']});this['_savedMetaData']['set'](_0x280e5f,{'roots':_0x2457e0,'markers':_0x479c6b,'rootsAttributes':_0x463062});}['_removeMetaData'](_0x48aed6){this['_savedMetaData']['delete'](_0x48aed6);}['_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'](_0x385f68,_0x190cd6=null){let _0x570a49=null;_0x385f68['is']('documentFragment')||(_0x570a49=new _0x5978e5(_0x385f68['name'],{'vid_start':null===_0x190cd6?this['_revisionId']++:_0x190cd6++}));const _0x1e6a47=[];for(const _0x323275 of _0x385f68['getChildren']())if(_0x323275['is']('element')){_0x1e6a47['push'](this['_makeIdsRoot'](_0x323275,_0x190cd6));const _0x286088=_0x1e6a47[_0x1e6a47['length']-0x1];null!==_0x190cd6&&(_0x190cd6=_0x286088['is']('element','$text')?_0x286088['getAttribute']('vid')+0x1:_0x286088['getAttribute']('vid_end')+0x1);}else{for(let _0x412e86=0x0;_0x412e86<_0x323275['offsetSize'];_0x412e86++)_0x1e6a47['push'](new _0x5978e5('$text',{'vid':null===_0x190cd6?this['_revisionId']++:_0x190cd6++}));}if(_0x385f68['is']('documentFragment')){const _0x3e292f=N(_0x385f68['rootName']);return _0x3e292f['_insertChild'](0x0,_0x1e6a47),_0x3e292f;}return _0x570a49['_setAttribute']('vid_end',null===_0x190cd6?this['_revisionId']++:_0x190cd6++),_0x570a49['_insertChild'](0x0,_0x1e6a47),_0x570a49;}['_calculateMetaData'](_0x42995b,_0x408be6,_0x5a9e2f){this['_reset']();const {roots:_0x497563,markers:_0x3cd4b0,rootsAttributes:_0x26a63f}=this['_savedMetaData']['get'](_0x42995b);this['_baseRoots']=new Map(_0x497563),this['_baseRootsAttributes']=new Map(_0x40b863(_0x26a63f));for(const [_0x31fbff,_0x324033]of this['_baseRoots'])if('$graveyard'!==_0x31fbff&&(this['_diffRoots']['set'](_0x31fbff,K(_0x324033)),this['_diffRootsAttributes']=new Map(_0x40b863(_0x26a63f)),_0x5a9e2f)){const _0x1fb33a=this['_revisionId'];this['_idsRoots']['set'](_0x31fbff,this['_makeIdsRoot'](_0x324033)),this['_baseIdsRoots']['set'](_0x31fbff,this['_makeIdsRoot'](_0x324033,_0x1fb33a));}this['_startingRevisionId']=this['_revisionId'],this['_diffRoots']['set']('$graveyard',K(this['_baseRoots']['get']('$graveyard'))),_0x5a9e2f&&this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](this['_baseRoots']['get']('$graveyard')));for(const [_0x17363b,_0x1dc55f]of _0x3cd4b0){const _0x1a162b=this['_baseRoots']['get'](_0x1dc55f['rootName']),_0x13a5f1=this['_diffRoots']['get'](_0x1dc55f['rootName']),_0x1d2bc4=new _0x1a05b7(this['_fixPosition'](_0x1dc55f['start'],_0x1a162b),this['_fixPosition'](_0x1dc55f['end'],_0x1a162b)),_0x5aa6d2=this['_fixRange'](_0x1d2bc4,_0x13a5f1);_0x1a162b['markers']['set'](_0x17363b,_0x1d2bc4),this['_markers']['set'](_0x17363b,_0x5aa6d2);}this['_applyOperations'](_0x42995b,_0x408be6,_0x5a9e2f);}['_applyOperations'](_0x14a5d5,_0x134025,_0x1707c8){for(const _0x5113e8 of this['source']['getOperations'](_0x14a5d5,_0x134025))this['_handleOperation'](_0x5113e8,_0x1707c8);for(const _0x4a2b7d of this['_diffRoots']['values']())_0x4a2b7d['markers']['clear']();for(const [_0x18b4d2,_0xd5dd08]of this['_markers']){this['_diffRoots']['get'](_0xd5dd08['root']['rootName'])['markers']['set'](_0x18b4d2,_0xd5dd08['clone']());}const _0x533397=new Map(),_0x10954c=new Map();for(const [_0x2f7f72,_0x15e2d7]of this['_diffRoots'])_0x533397['set'](_0x2f7f72,K(_0x15e2d7)),_0x10954c['set'](_0x2f7f72,this['_diffRootsAttributes']['get'](_0x2f7f72));this['_saveMetaData'](_0x134025,_0x533397,this['_markers'],_0x10954c);}['_getPreviousFrom'](_0xbd67a1){const _0x22b3ba=Array['from'](this['_savedMetaData']['keys']());_0x22b3ba['sort']((_0x42b8d8,_0x30ffb3)=>_0x42b8d8-_0x30ffb3),_0x22b3ba['reverse']();for(const _0x303410 of _0x22b3ba)if(_0x303410<_0xbd67a1)return _0x303410;return Number['NEGATIVE_INFINITY'];}['_copyMarkers'](_0xf2927,_0x2b00de){const _0x204954=Array['from'](_0x2b00de['markers'])['map'](([_0x27ab4b,_0x5c3254])=>[_0x27ab4b,this['_fixRange'](_0x5c3254,_0xf2927)]);_0xf2927['markers']=new Map(_0x204954);}['_transformMarkers'](_0x5a8995){for(const _0xdc6959 of this['_markers']['values']()){const _0x69dee6=_0xdc6959['getTransformedByOperation'](_0x5a8995),_0xe23d61=_0x1a05b7['_createFromRanges'](_0x69dee6);_0xdc6959['start']=_0xe23d61['start'],_0xdc6959['end']=_0xe23d61['end'];}}['_handleOperation'](_0x2d45e7,_0x7ff9f5){if('addRoot'!=_0x2d45e7['type']&&'detachRoot'!=_0x2d45e7['type']){if('insert'==_0x2d45e7['type']){const _0x5549a5=_0x2d45e7['position']['root']['rootName'];this['_diffRoots']['has'](_0x5549a5)||(this['_diffRoots']['set'](_0x5549a5,N(_0x5549a5,!0x0)),this['_diffRootsAttributes']['set'](_0x5549a5,{}),_0x7ff9f5&&this['_idsRoots']['set'](_0x5549a5,N(_0x5549a5,!0x0)));}else{if('addRootAttribute'==_0x2d45e7['type']||'removeRootAttribute'==_0x2d45e7['type']||'changeRootAttribute'==_0x2d45e7['type'])return void this['_handleRootAttributeOperation'](_0x2d45e7);'marker'==_0x2d45e7['type']&&this['_handleMarkerOperation'](_0x2d45e7);}if('marker'!==_0x2d45e7['type']){const _0x2d1e99=this['_cloneOperation'](_0x2d45e7,this['_diffRoots']);_0x2d1e99['_execute'](),this['_transformMarkers'](_0x2d1e99);}if(_0x7ff9f5)switch(_0x2d45e7['type']){case'insert':this['_handleInsertOperation'](_0x2d45e7);break;case'move':case'remove':case'reinsert':this['_handleMoveOperation'](_0x2d45e7);break;case'merge':this['_handleMergeOperation'](_0x2d45e7);break;case'split':this['_handleSplitOperation'](_0x2d45e7);}}else this['_handleRootOperation'](_0x2d45e7,_0x7ff9f5);}['_cloneOperation'](_0x5e48b2,_0x50f965){const _0x7008a=_0x5e48b2['clone']();return _0x7008a['_authorId']=_0x5e48b2['_authorId'],this['_fixOperation'](_0x7008a,_0x50f965),_0x7008a;}['_getBaseVids'](_0x4814f0){return _0x4814f0['map'](_0x55a926=>{const _0x129fe1=this['_getVidAttributeName'](_0x55a926);return Number(_0x55a926['item']['getAttribute'](_0x129fe1));});}['_generateTape'](_0x398403,_0x1b686b){if(_0x398403['is']('element','$text'))_0x1b686b['push']({'item':_0x398403,'type':'text'});else{_0x398403['is']('element')&&_0x1b686b['push']({'item':_0x398403,'type':'elementStart'});for(const _0xac9d13 of _0x398403['getChildren']())this['_generateTape'](_0xac9d13,_0x1b686b);_0x398403['is']('element')&&_0x1b686b['push']({'item':_0x398403,'type':'elementEnd'});}return _0x1b686b;}['_getState'](){const _0x2d3611=new Map(this['_touched']),_0x538d68=new Map(_0x2d3611),_0x7daa7e=new Map(),_0x5e3dd1={'insertions':{},'deletions':{}},_0x377507={'insertions':{},'deletions':{}},_0x48f144=new Map(),_0x5b24e8=new Set([...this['_baseRoots']['keys'](),...this['_diffRoots']['keys']()]);_0x5b24e8['delete']('$graveyard');for(const _0x56b7ba of _0x5b24e8){const _0x4b8045=this['_diffRoots']['get'](_0x56b7ba)||N(_0x56b7ba,!0x1),_0x560d04=this['_baseRoots']['get'](_0x56b7ba)||N(_0x56b7ba,!0x1);_0x4b8045['isAttached']()||_0x560d04['isAttached']()?(_0x5e3dd1['insertions'][_0x56b7ba]=K(_0x4b8045),_0x5e3dd1['deletions'][_0x56b7ba]=K(_0x560d04),this['_copyMarkers'](_0x5e3dd1['deletions'][_0x56b7ba],_0x560d04),this['_copyMarkers'](_0x5e3dd1['insertions'][_0x56b7ba],_0x4b8045),_0x377507['insertions'][_0x56b7ba]=this['_generateTape'](this['_idsRoots']['get'](_0x56b7ba),[]),_0x377507['deletions'][_0x56b7ba]=this['_generateTape'](this['_baseIdsRoots']['get'](_0x56b7ba)||N(_0x56b7ba,!0x1),[])):_0x5b24e8['delete'](_0x56b7ba);}for(const _0x586277 of _0x5b24e8){const _0x406146=_0x377507['insertions'][_0x586277];for(const _0x68a80c of _0x406146){const _0x50e9b5=this['_getVidAttributeName'](_0x68a80c),_0x23483b=_0x68a80c['item']['getAttribute'](_0x50e9b5);_0x538d68['delete'](_0x23483b),_0x23483b>=this['_startingRevisionId']&&_0x7daa7e['set'](_0x23483b,_0x2d3611['get'](_0x23483b));}}for(const _0x4ef87d of _0x5b24e8){const _0x3d9c82=_0x377507['insertions'][_0x4ef87d],_0x2b7d91=this['_getBaseVids'](_0x377507['deletions'][_0x4ef87d]);let _0x368cb1=0x0;for(const _0x2ee0a5 of _0x3d9c82){const _0xd351f3=this['_getVidAttributeName'](_0x2ee0a5),_0x15e90f=_0x2ee0a5['item']['getAttribute'](_0xd351f3);if(!_0x7daa7e['has'](_0x15e90f)&&!_0x48f144['has'](_0x15e90f)){if(_0x538d68['has'](_0x15e90f))_0x368cb1++;else{if(_0x15e90f!=_0x2b7d91[_0x368cb1]){const _0x519b0e=_0x2d3611['get'](_0x15e90f)||_0x2d3611['get'](_0x2b7d91[_0x368cb1]);for(;_0x15e90f!=_0x2b7d91[_0x368cb1];)_0x538d68['has'](_0x2b7d91[_0x368cb1])||(_0x48f144['set'](_0x2b7d91[_0x368cb1],_0x519b0e),_0x2d3611['set'](_0x2b7d91[_0x368cb1],_0x519b0e)),_0x368cb1++;}_0x368cb1++;}}}}for(const _0x40c6a5 of _0x5b24e8){const _0x2d971a=_0x377507['insertions'][_0x40c6a5];for(const _0x33ff32 of _0x2d971a){const _0x23b07a=this['_getVidAttributeName'](_0x33ff32),_0x538e3e=_0x33ff32['item']['getAttribute'](_0x23b07a);if(_0x48f144['has'](_0x538e3e)){const _0x46ed33=_0x48f144['get'](_0x538e3e);_0x538d68['has'](_0x538e3e)||_0x538d68['set'](_0x538e3e,{..._0x46ed33}),_0x7daa7e['set'](_0x538e3e,{..._0x46ed33});}}}for(const _0x30209 of _0x538d68['keys']())_0x30209>=this['_startingRevisionId']&&_0x538d68['delete'](_0x30209);const _0x5326c7=new Map();for(const _0x2c6ede of _0x5b24e8){let _0x18e594=_0x377507['insertions'][_0x2c6ede];for(const _0x53d04c of _0x18e594)if(_0x53d04c['item']['is']('element','tableCell')){const _0x4fd9fb=this['_getVidAttributeName'](_0x53d04c),_0x568817=_0x53d04c['item']['getAttribute'](_0x4fd9fb);if(_0x7daa7e['has'](_0x568817)){const _0x3e5617=_0x53d04c['item']['parent']['parent']['getAttribute']('vid_start'),_0x3e7877=_0x5326c7['get'](_0x3e5617)||new Set();_0x3e7877['add'](_0x7daa7e['get'](_0x568817)['userId']),_0x5326c7['set'](_0x3e5617,_0x3e7877);}}_0x18e594=_0x377507['deletions'][_0x2c6ede];for(const _0x10dd7c of _0x18e594)if(_0x10dd7c['item']['is']('element','tableCell')){const _0x5dd42e=this['_getVidAttributeName'](_0x10dd7c),_0x563f91=_0x10dd7c['item']['getAttribute'](_0x5dd42e);if(_0x538d68['has'](_0x563f91)){const _0x1be310=_0x10dd7c['item']['parent']['parent']['getAttribute']('vid_start'),_0x562fcd=_0x5326c7['get'](_0x1be310)||new Set();_0x562fcd['add'](_0x538d68['get'](_0x563f91)['userId']),_0x5326c7['set'](_0x1be310,_0x562fcd);}}for(const _0x21ce9b of _0x5326c7['keys']())(_0x7daa7e['has'](_0x21ce9b)||_0x538d68['has'](_0x21ce9b))&&_0x5326c7['delete'](_0x21ce9b);}for(const _0x217d04 of _0x5b24e8){const _0x4af44e=_0x377507['insertions'][_0x217d04];let _0x4fd451=null,_0x51fc25=null;for(const _0x4c938a of _0x4af44e){const _0x4685e8=this['_getVidAttributeName'](_0x4c938a),_0x3558de=_0x4c938a['item']['getAttribute'](_0x4685e8),_0x1da4b0=_0x5326c7['get'](_0x3558de);_0x1da4b0&&'elementStart'==_0x4c938a['type']&&(_0x4fd451=Array['from'](_0x1da4b0)[0x0],_0x51fc25=_0x4c938a['item']['getAttribute']('vid_end')),_0x4fd451&&(_0x538d68['set'](_0x3558de,{'userId':_0x4fd451}),_0x7daa7e['set'](_0x3558de,{'userId':_0x4fd451})),_0x3558de==_0x51fc25&&(_0x4fd451=null,_0x51fc25=null);}}const _0x4db6c5={},_0x41be79=new Set();for(const _0x2829ec of _0x5b24e8){const _0x34d220=_0x5e3dd1['deletions'][_0x2829ec],_0x496f98=_0x5e3dd1['insertions'][_0x2829ec];for(const {userId:_0x981473}of this['_touchedMarkers']['values']())null!==_0x981473&&_0x41be79['add'](_0x981473);for(const {userId:_0x50f128}of this['_touchedRoots']['values']())null!==_0x50f128&&_0x41be79['add'](_0x50f128);this['_markChanges'](_0x496f98,_0x377507['insertions'][_0x2829ec],_0x7daa7e,'insertion',_0x41be79),this['_markChanges'](_0x34d220,_0x377507['deletions'][_0x2829ec],_0x538d68,'deletion',_0x41be79),_0x4db6c5[_0x2829ec]={'insertions':this['_prepareViewToSave'](_0x496f98),'deletions':this['_prepareViewToSave'](_0x34d220),'attachChange':this['_touchedRoots']['get'](_0x2829ec)||null,'attributesBefore':_0x40b863(this['_baseRootsAttributes']['get'](_0x2829ec))||{},'attributesAfter':_0x40b863(this['_diffRootsAttributes']['get'](_0x2829ec))};}return{'diffData':_0x4db6c5,'authorsIds':Array['from'](_0x41be79)};}['_processRootBeforeSave'](_0x1ef845){for(const [,_0x23cf6b]of _0x1ef845['markers']){const _0x58f879=_0x23cf6b['start']['getAncestors']()['filter'](_0x539a09=>'tableCell'==_0x539a09['name']);for(const _0x5208bb of _0x58f879)0x1==_0x5208bb['childCount']&&_0x5208bb['getChild'](0x0)['is']('element','paragraph')&&_0x5208bb['getChild'](0x0)['_setAttribute']('keepParagraph',!0x0);}}['_prepareViewToSave'](_0x1050c6){this['_processRootBeforeSave'](_0x1050c6);const _0x5a13a1=this['editor']['data']['toView'](_0x1050c6,{}),_0x2c185c=Array['from'](_0x5a13a1['getChildren']())['map'](_0x4af5c0=>this['_getViewJson'](_0x4af5c0));return JSON['stringify'](_0x2c185c);}['_getViewJson'](_0x48bbe5){if(_0x48bbe5['is']('$text'))return _0x48bbe5['data'];{const _0x4f35af=this['editor']['plugins']['get']('RevisionHistoryUtils'),_0x3609e1=_0x48bbe5,_0x2c568e=this['editor']['data']['htmlProcessor']['domConverter'],_0x532533={'type':_0x4f35af['_getTypeCharForViewElement'](_0x3609e1),'name':_0x3609e1['name'],'attributes':Array['from'](_0x3609e1['getAttributes']()),'children':Array['from'](_0x3609e1['getChildren']())['map'](_0x34802f=>this['_getViewJson'](_0x34802f))};if(_0x48bbe5['is']('uiElement')&&'$comment'!=_0x48bbe5['name']){const _0x20730c=_0x48bbe5['render'](_0x2c568e['domDocument'],_0x2c568e);_0x532533['children']['push'](_0x20730c['outerHTML']);}else{if(_0x48bbe5['is']('rawElement')){const _0x30ff8f=_0x2c568e['domDocument']['createElement'](_0x3609e1['name']);_0x48bbe5['render'](_0x30ff8f,_0x2c568e),_0x532533['children']['push'](_0x30ff8f['innerHTML']);}}const _0x47989d=Array['from'](_0x3609e1['getCustomProperties']());_0x47989d['length']>0x0&&(_0x532533['customProperties']=_0x47989d);const _0x575ec2=_0x3609e1['getFillerOffset']();return null!==_0x575ec2&&(_0x532533['fillerOffset']=_0x575ec2),_0x532533;}}['_markChanges'](_0x495adf,_0x47f799,_0xe1ea40,_0x1a8869,_0x849399){let _0xbcb332=null,_0x3210a2=null,_0x36807e=0x0;const _0x2e0e1e=this['editor']['model'];for(let _0x1444db=0x0;_0x1444db<_0x47f799['length'];_0x1444db++){const _0x4ae7a4=this['_getVidAttributeName'](_0x47f799[_0x1444db]),_0x3b715e=_0x47f799[_0x1444db]['item']['getAttribute'](_0x4ae7a4),_0x535d72=_0xe1ea40['get'](_0x3b715e),_0x2d2e9a=_0x1444db==_0x47f799['length']-0x1;(!_0xbcb332&&_0x535d72&&(_0xbcb332=_0x535d72,_0x3210a2=_0x47f799[_0x1444db]),_0xbcb332&&(!_0x535d72||_0x535d72['userId']!=_0xbcb332['userId']))&&(_0x195709(_0x535d72,P(_0x3210a2,_0x495adf,_0x2e0e1e),P(_0x47f799[_0x1444db],_0x495adf,_0x2e0e1e)),_0xbcb332=_0x535d72||null,_0x3210a2=_0x535d72?_0x47f799[_0x1444db]:null),_0xbcb332&&_0x2d2e9a&&_0x195709(_0x535d72,P(_0x3210a2,_0x495adf,_0x2e0e1e),V(_0x47f799[_0x1444db],_0x495adf,_0x2e0e1e));}function _0x195709(_0x290538,_0x43c574,_0x27469c){const _0x5bf4e7=_0xbcb332['userId'],_0x400c51='revision:'+_0x1a8869+':'+_0x5bf4e7+':'+_0x36807e++,_0x31e784=_0x2e0e1e['createRange'](_0x43c574,_0x27469c);_0x495adf['markers']['set'](_0x400c51,_0x31e784),null!==_0x5bf4e7&&_0x849399['add'](_0x5bf4e7);}}['_getVidAttributeName'](_0x35af1c){switch(_0x35af1c['type']){case'elementStart':return'vid_start';case'elementEnd':return'vid_end';default:return'vid';}}['_fixOperation'](_0x30dc91,_0x26fc44){_0x30dc91['baseVersion']=null;for(const _0x53d276 in _0x30dc91){const _0x3de5d7=_0x30dc91[_0x53d276];if(_0x3de5d7 instanceof _0x3644ea){const _0x26ca82=_0x26fc44['get'](_0x3de5d7['root']['rootName']);_0x30dc91[_0x53d276]=this['_fixPosition'](_0x3de5d7,_0x26ca82);}if(_0x3de5d7 instanceof _0x1a05b7){const _0x553bfc=_0x26fc44['get'](_0x3de5d7['root']['rootName']);_0x30dc91[_0x53d276]=this['_fixRange'](_0x3de5d7,_0x553bfc);}'root'===_0x53d276&&(_0x30dc91['root']=_0x26fc44['get'](_0x30dc91['root']['rootName']));}}['_fixRange'](_0x4efb63,_0x2a6866){return this['editor']['model']['createRange'](this['_fixPosition'](_0x4efb63['start'],_0x2a6866),this['_fixPosition'](_0x4efb63['end'],_0x2a6866));}['_fixPosition'](_0x1411bd,_0x432a74){return this['editor']['model']['createPositionFromPath'](_0x432a74,_0x1411bd['path'],_0x1411bd['stickiness']);}['_handleInsertOperation'](_0x119838){const _0x590012=this['_idsRoots']['get'](_0x119838['position']['root']['rootName']),_0x9c73ac=this['_fixPosition'](_0x119838['position'],_0x590012),_0x245724=null===_0x119838['_authorId']?null:_0x119838['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0xbd927f=_0x9c73ac['parent'],_0x14ce41=this['_revisionId'],_0x36db87=[];for(const _0x10e92f of _0x119838['nodes'])if(_0x10e92f['is']('element'))_0x36db87['push'](this['_makeIdsRoot'](_0x10e92f));else{for(let _0x337606=0x0;_0x337606<_0x10e92f['offsetSize'];_0x337606++)_0x36db87['push'](new _0x5978e5('$text',{'vid':this['_revisionId']++}));}const _0x3e57af=this['_revisionId'];for(let _0x2f8288=_0x14ce41;_0x2f8288<_0x3e57af;_0x2f8288++)this['_touched']['set'](_0x2f8288,{'userId':_0x245724});_0xbd927f['_insertChild'](_0x9c73ac['offset'],_0x36db87);}['_handleMoveOperation'](_0x253452){(_0x253452=this['_cloneOperation'](_0x253452,this['_idsRoots']))['_execute']();const _0x3897a6=null===_0x253452['_authorId']?null:_0x253452['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x1d2b73=_0x253452['getMovedRangeStart'](),_0x535313=_0x1d2b73['parent'],_0x660c38=_0x1d2b73['offset'];!function _0xc8e236(_0x21409b,_0x3ddda3,_0x35933a,_0x5d8818){for(let _0x523040=_0x35933a;_0x523040<_0x5d8818;_0x523040++){const _0x42440d=_0x3ddda3['getChild'](_0x523040);_0x42440d['is']('element','$text')?_0x21409b['set'](_0x42440d['getAttribute']('vid'),{'userId':_0x3897a6}):(_0x21409b['set'](_0x42440d['getAttribute']('vid_start'),{'userId':_0x3897a6}),_0xc8e236(_0x21409b,_0x42440d,0x0,_0x42440d['childCount']),_0x21409b['set'](_0x42440d['getAttribute']('vid_end'),{'userId':_0x3897a6}));}}(this['_touched'],_0x535313,_0x660c38,_0x660c38+_0x253452['howMany']);}['_handleMergeOperation'](_0xc6ed87){const _0x9ce7b8=null===(_0xc6ed87=this['_cloneOperation'](_0xc6ed87,this['_idsRoots']))['_authorId']?null:_0xc6ed87['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x3afe74=_0xc6ed87['targetPosition']['parent'],_0x4e3a10=_0xc6ed87['sourcePosition']['parent'],_0x20a652=_0x3afe74['getAttribute']('vid_end'),_0x4c87d2=_0x4e3a10['getAttribute']('vid_start');_0x3afe74['_setAttribute']('vid_end',_0x4e3a10['getAttribute']('vid_end')),_0x4e3a10['_setAttribute']('vid_end',_0x20a652),this['_touched']['set'](_0x4c87d2,{'userId':_0x9ce7b8}),this['_touched']['set'](_0x20a652,{'userId':_0x9ce7b8}),_0xc6ed87['_execute']();}['_handleSplitOperation'](_0x3fc937){const _0x26d1e6=null===(_0x3fc937=this['_cloneOperation'](_0x3fc937,this['_idsRoots']))['_authorId']?null:_0x3fc937['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x47821c=_0x3fc937['graveyardPosition'],_0x5dc1e1=_0x3fc937['splitPosition']['parent'];_0x3fc937['_execute']();const _0x6c6057=_0x5dc1e1['getAttribute']('vid_end'),_0x4cb987=_0x3fc937['insertionPosition']['nodeAfter'];if(_0x47821c){const _0x9107b=_0x4cb987['getAttribute']('vid_end'),_0x102dda=_0x5dc1e1['getAttribute']('vid_end');_0x5dc1e1['_setAttribute']('vid_end',_0x9107b),_0x4cb987['_setAttribute']('vid_end',_0x102dda),this['_touched']['set'](_0x5dc1e1['getAttribute']('vid_end'),{'userId':_0x26d1e6}),this['_touched']['set'](_0x4cb987['getAttribute']('vid_start'),{'userId':_0x26d1e6});}else{const _0x457068=this['_revisionId']++,_0x23139a=this['_revisionId']++;_0x5dc1e1['_setAttribute']('vid_end',_0x457068),_0x4cb987['_setAttribute']('vid_start',_0x23139a),_0x4cb987['_setAttribute']('vid_end',_0x6c6057),this['_touched']['set'](_0x457068,{'userId':_0x26d1e6}),this['_touched']['set'](_0x23139a,{'userId':_0x26d1e6});}}['_handleMarkerOperation'](_0x46f7be){if(!_0x46f7be['affectsData'])return;const _0xaf9b77=(_0x46f7be=this['_cloneOperation'](_0x46f7be,this['_diffRoots']))['oldRange']?_0x46f7be['oldRange']['root']:null,_0x9413a0=_0x46f7be['newRange']?_0x46f7be['newRange']['root']:null;_0xaf9b77&&this['_markers']['delete'](_0x46f7be['name']),_0x9413a0&&this['_markers']['set'](_0x46f7be['name'],_0x46f7be['newRange']['clone']());const _0x6013ef=null===_0x46f7be['_authorId']?null:_0x46f7be['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x1e01ae=_0x46f7be['name'];if(!this['_touchedMarkers']['has'](_0x1e01ae))return void this['_touchedMarkers']['set'](_0x1e01ae,{'range':_0x46f7be['oldRange'],'userId':_0x6013ef});const _0x36f534=this['_touchedMarkers']['get'](_0x1e01ae),_0x16a66f=_0x36f534['range'],_0x14ac15=_0x46f7be['newRange'];null==_0x16a66f&&null==_0x14ac15||_0x16a66f&&_0x14ac15&&_0x16a66f['isEqual'](_0x14ac15)?this['_touchedMarkers']['delete'](_0x46f7be['name']):_0x36f534['userId']=_0x6013ef;}['_handleRootOperation'](_0x25da65,_0x3de237){this['_diffRoots']['has'](_0x25da65['rootName'])?this['_diffRoots']['get'](_0x25da65['rootName'])['_isAttached']=_0x25da65['isAdd']:(this['_diffRoots']['set'](_0x25da65['rootName'],N(_0x25da65['rootName'],!0x0)),this['_diffRootsAttributes']['set'](_0x25da65['rootName'],{}),_0x3de237&&this['_idsRoots']['set'](_0x25da65['rootName'],N(_0x25da65['rootName'],!0x0)));const _0x2ac8a0=null===_0x25da65['_authorId']?null:_0x25da65['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x5b36e2=this['_touchedRoots']['get'](_0x25da65['rootName']);_0x5b36e2&&_0x5b36e2['userId']===_0x2ac8a0?this['_touchedRoots']['delete'](_0x25da65['rootName']):this['_touchedRoots']['set'](_0x25da65['rootName'],{'userId':_0x2ac8a0,'isAttached':_0x25da65['isAdd']});}['_handleRootAttributeOperation'](_0x55d338){const _0x2e33bd=this['_diffRootsAttributes']['get'](_0x55d338['root']['rootName']);null===_0x55d338['newValue']?delete _0x2e33bd[_0x55d338['key']]:_0x2e33bd[_0x55d338['key']]=_0x55d338['newValue'];}}function K(_0x5594e1){const _0x14579d=N(_0x5594e1['rootName'],_0x5594e1['isAttached']());for(const _0xc3461d of _0x5594e1['getChildren']()){const _0x4305d9=_0xc3461d['_clone'](!0x0);_0x14579d['_appendChild'](_0x4305d9);}return _0x14579d;}function N(_0x4a156d,_0x864d49=!0x0){const _0x50f047=new _0x3269cc();return _0x50f047['rootName']=_0x4a156d,_0x50f047['_isAttached']=_0x864d49,_0x50f047['isAttached']=()=>_0x50f047['_isAttached'],_0x50f047;}function P(_0x4974bc,_0x75b698,_0xbf3f95){const _0x5e9549='elementEnd'==_0x4974bc['type']?_0xbf3f95['createPositionAt'](_0x4974bc['item'],'end'):_0xbf3f95['createPositionBefore'](_0x4974bc['item']);return _0xbf3f95['createPositionFromPath'](_0x75b698,_0x5e9549['path'],_0x5e9549['stickiness']);}function V(_0x30a33c,_0x49d7f0,_0x405aa9){const _0x87c621='elementStart'==_0x30a33c['type']?_0x405aa9['createPositionAt'](_0x30a33c['item'],0x0):_0x405aa9['createPositionAfter'](_0x30a33c['item']);return _0x405aa9['createPositionFromPath'](_0x49d7f0,_0x87c621['path'],_0x87c621['stickiness']);}class he extends/* #__PURE__ -- @preserve */
|
|
25
|
+
_0x278ba5(_0x1252c){['focusTracker'];['keystrokes'];['revisionNameInputView'];constructor(_0x4d0f1a,_0x3c1ff0){super(_0x4d0f1a),this['focusTracker']=new _0x451fce(),this['keystrokes']=new _0x2b80a9(),this['set']('revisionNameInputValue',''),this['revisionNameInputView']=this['_createRevisionNameInput'](_0x3c1ff0),this['setTemplate']({'tag':'form','attributes':{'class':['ck','ck-revision-history-save-revision-form','ck-responsive-form'],'tabindex':'-1'},'children':[this['revisionNameInputView']]}),this['initializeCssTransitionDisablerMixin']();}['render'](){super['render'](),_0x2cf676({'view':this}),this['focusTracker']['add'](this['revisionNameInputView']['element']),this['keystrokes']['listenTo'](this['element']);const _0x208f6e=_0x2e1352=>_0x2e1352['stopPropagation']();this['keystrokes']['set']('arrowright',_0x208f6e),this['keystrokes']['set']('arrowleft',_0x208f6e),this['keystrokes']['set']('arrowup',_0x208f6e),this['keystrokes']['set']('arrowdown',_0x208f6e);}['focus'](){this['revisionNameInputView']['focus']();}get['revisionName'](){return this['revisionNameInputView']['fieldView']['element']['value']['trim']();}set['revisionName'](_0x482362){this['revisionNameInputView']['fieldView']['element']['value']=_0x482362['trim']();}['reset'](){this['revisionNameInputView']['fieldView']['element']['value']='',this['revisionNameInputView']['errorText']=null;}['_createRevisionNameInput'](_0x3315b3){const _0x4e79fe=new et(this['locale'],ti),_0x1357f5=_0x4e79fe['fieldView'];_0x1357f5['extendTemplate']({'attributes':{'maxlength':'220'}});let _0x1b4997=m(this['locale'],'Name\x20of\x20the\x20revision');return!_0x3315b3&&(_0x1b4997+='\x20('+m(this['locale'],'optional')+')'),(_0x4e79fe['label']=_0x1b4997,_0x1357f5['on']('input',()=>{this['revisionNameInputValue']=_0x1357f5['element']['value']['trim']();}),_0x4e79fe);}}class l extends _0xf4a8c2{static get['pluginName'](){return'RevisionHistoryUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[h];}['_saveRevisionFormView'];['init'](){const _0x39fbc5=this['editor'],_0x6dc3e4=_0x39fbc5['plugins']['get']('RevisionTracker');_0x39fbc5['ui']['componentFactory']['add']('revisionHistory',_0x347ee3=>{const _0xe1b2ee=_0x537cf1(_0x347ee3),_0x433b36=_0xe1b2ee['panelView']['children'],_0x24d78a=new _0x415240(_0x347ee3),_0x5c55fe=new _0x432834(_0x347ee3),_0xafef5=this['_createSaveRevisionButton'](_0x3e3281),_0x91b2e7=new _0x432834(_0x347ee3),_0x537cef=this['_createOpenRevisionButton'](_0x3e3281);return _0xe1b2ee['bind']('isEnabled')['to'](_0x6dc3e4,'isReady',_0x6dc3e4,'isEnabled',_0x39fbc5,'isReadOnly',(_0x17ac43,_0x4dcb4f,_0x12c4c5)=>_0x17ac43&&_0x4dcb4f&&!_0x12c4c5),_0xe1b2ee['buttonView']['set']({'icon':_0x34181b,'label':m(_0x347ee3,'Revision\x20history'),'tooltip':!0x0}),_0xafef5['set']({'withText':!0x0,'role':'menuitem'}),_0x537cef['set']({'withText':!0x0,'role':'menuitem'}),this['listenTo'](_0x537cef,'execute',()=>{_0xe1b2ee['isOpen']=!0x1,_0x39fbc5['editing']['view']['focus']();},{'priority':'low'}),_0x5c55fe['children']['add'](_0xafef5),_0x91b2e7['children']['add'](_0x537cef),_0x24d78a['role']='menu',_0x24d78a['items']['addMany']([_0x5c55fe,_0x91b2e7]),_0x433b36['add'](_0x24d78a),_0xe1b2ee;}),_0x39fbc5['ui']['componentFactory']['add']('menuBar:revisionHistory',()=>this['_registerMenuComponent']());}['_registerMenuComponent'](){const _0x5cab23=this['editor'],_0x1fc053=_0x5cab23['locale'],_0x2f20d7=_0x5cab23['plugins']['get']('RevisionTracker'),_0xcc8161=new _0x30aab5(_0x1fc053),_0x1a414c=new _0x425f1f(_0x1fc053);_0xcc8161['bind']('isEnabled')['to'](_0x2f20d7,'isReady',_0x2f20d7,'isEnabled',_0x5cab23,'isReadOnly',(_0x360011,_0x17516e,_0x6364b9)=>_0x360011&&_0x17516e&&!_0x6364b9),_0xcc8161['buttonView']['set']({'icon':_0x34181b,'label':m(_0x1fc053,'Revision\x20history')});const _0xcb825b=new _0x2805e1(_0x1fc053,_0xcc8161),_0x85aad4=this['_createSaveRevisionButton'](_0x12d25a);_0x85aad4['delegate']('execute')['to'](_0xcc8161),_0xcb825b['children']['add'](_0x85aad4),_0x1a414c['items']['add'](_0xcb825b);const _0x2f2882=new _0x2805e1(_0x1fc053,_0xcc8161),_0x3d1927=this['_createOpenRevisionButton'](_0x12d25a);return _0x3d1927['delegate']('execute')['to'](_0xcc8161),_0x2f2882['children']['add'](_0x3d1927),_0x1a414c['items']['add'](_0x2f2882),_0xcc8161['panelView']['children']['add'](_0x1a414c),_0xcc8161;}['_createSaveRevisionButton'](_0x2347ec){const _0x401834=this['editor'],_0x2e5a0e=_0x401834['plugins']['get']('RevisionTracker'),_0xc4792d=new _0x2347ec(_0x401834['locale']);return _0xc4792d['set']({'label':m(_0x401834['locale'],'Save\x20current\x20revision')}),_0xc4792d['bind']('isEnabled')['to'](_0x2e5a0e,'isReady',_0x2e5a0e,'isEnabled',_0x401834,'isReadOnly',(_0x5ba1b6,_0x1fc665,_0x574c73)=>_0x5ba1b6&&_0x1fc665&&!_0x574c73),this['listenTo'](_0xc4792d,'execute',()=>{this['_showDialog']();}),_0xc4792d;}['_createOpenRevisionButton'](_0x2867e2){const _0x3d2496=this['editor'],_0x490d42=_0x3d2496['plugins']['get']('RevisionTracker'),_0x108f27=new _0x2867e2(_0x3d2496['locale']);return _0x108f27['set']({'label':m(_0x3d2496['locale'],'Open\x20revision\x20history')}),_0x108f27['bind']('isEnabled')['to'](_0x490d42,'isReady',_0x3d2496,'isReadOnly',(_0xfe04b0,_0x581de0)=>_0xfe04b0&&!_0x581de0),this['listenTo'](_0x108f27,'execute',()=>{_0x3d2496['config']['get']('revisionHistory')['showRevisionViewerCallback']();}),_0x108f27;}['_showDialog'](){const _0x85c4f0=this['editor'],_0x428914=_0x85c4f0['locale'],_0x35c820=_0x85c4f0['plugins']['get']('Dialog'),_0x58ef2c=_0x85c4f0['plugins']['get']('RevisionTracker');function _0x1c5aa4(_0x2fd02e){_0x85c4f0['config']['get']('revisionHistory.requireRevisionName')&&''===_0x2fd02e['revisionName']?_0x2fd02e['revisionNameInputView']['errorText']=m(_0x428914,'The\x20revision\x20name\x20cannot\x20be\x20empty.'):(_0x85c4f0['plugins']['get'](h)['saveRevision']({'name':_0x2fd02e['revisionName']}),_0x35c820['hide']());}this['_saveRevisionFormView']||(this['_createSaveRevisionFormView'](),this['_saveRevisionFormView']['on']('submit',()=>_0x1c5aa4(this['_saveRevisionFormView']))),this['_saveRevisionFormView']['reset'](),_0x35c820['show']({'id':'revisionSave','title':m(_0x428914,'Save\x20current\x20revision'),'isModal':!0x0,'content':this['_saveRevisionFormView'],'actionButtons':[{'label':m(_0x85c4f0['locale'],'Cancel'),'withText':!0x0,'onExecute':()=>_0x35c820['hide']()},{'label':m(_0x85c4f0['locale'],'Accept'),'class':'ck-button-action','withText':!0x0,'onCreate'(_0xfb4b91){_0xfb4b91['bind']('isEnabled')['to'](_0x58ef2c,'isReady',_0x58ef2c,'isEnabled',_0x85c4f0,'isReadOnly',(_0x9c456e,_0x2943f1,_0x1626ca)=>_0x9c456e&&_0x2943f1&&!_0x1626ca);},'onExecute':()=>_0x1c5aa4(this['_saveRevisionFormView'])}]});}['_createSaveRevisionFormView'](){const _0x1346df=this['editor'],_0x524fcd=_0x1346df['locale'];this['_saveRevisionFormView']=new he(_0x524fcd,_0x1346df['config']['get']('revisionHistory.requireRevisionName')),this['_saveRevisionFormView']['render']();}}class z extends _0x1252c{['changeId'];['_model'];constructor(_0x2d9f06,_0x4bc273){super(_0x2d9f06),this['_model']=_0x4bc273,this['changeId']=_0x4bc273['id'];const _0xd5ea8a=this['bindTemplate'],_0x2019c8=m(_0x2d9f06,_0x4bc273['data']['isSuggestion']?'Suggested\x20by':'add'==_0x4bc273['type']?'Added\x20by':'Removed\x20by');this['set']('type',_0x4bc273['type']),this['setTemplate']({'tag':'div','attributes':{'class':['ck-annotation','ck-revision-change',_0xd5ea8a['to']('type',_0x4b4aa8=>'ck-revision-change__'+_0x4b4aa8)],'tabindex':-0x1},'children':[{'tag':'span','children':[{'tag':'span','attributes':{'class':['ck-revision-change__label']},'children':[{'text':_0x2019c8}]},{'text':'\x20'+_0x4bc273['author']['name']}]}]});}['focus'](){this['element']['focus']();}}class G extends/* #__PURE__ -- @preserve */
|
|
26
|
+
_0x9ab2a1(){['id'];['author'];['type'];['data'];['rootName'];constructor(_0x3ed306){super(),this['id']=_0x3ed306['id']||_0x422cf0(),this['author']=_0x3ed306['author'],this['type']=_0x3ed306['type'],this['data']=_0x3ed306['data']||{},this['rootName']=_0x3ed306['rootName'],this['set']('createdAt',_0x3ed306['createdAt']);}['toJSON'](){return{'id':this['id'],'authorId':this['author']['id'],'type':this['type'],'data':this['data'],'createdAt':this['createdAt']};}}class J{['newRevisionId'];['oldRevisionId'];['changes'];constructor(_0x1c15a8,_0x3c1475){this['newRevisionId']=_0x1c15a8,this['oldRevisionId']=_0x3c1475,this['changes']=new _0x4772da();}['_setChanges'](_0xc614c0){for(const _0x8fcde3 of _0xc614c0)this['changes']['add'](_0x8fcde3);}}class u extends _0xf4a8c2{['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[_0x1de907,_0x867a1d,S,$];}constructor(_0x331eff){super(_0x331eff),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',(_0x388cd9,_0x2f0b29,_0x52b926)=>{this['activeChange']=null,this['activeView']=null,this['editor']['editing']['view']['change'](_0x64c7df=>{for(const _0x3d4d16 of this['editor']['editing']['view']['document']['roots'])_0x52b926?_0x64c7df['removeClass']('ck-editor__editable__overlay',_0x3d4d16):_0x64c7df['addClass']('ck-editor__editable__overlay',_0x3d4d16);});}),this['bind']('isNavigationMode')['to'](this,'activeChange',_0x26fd2c=>null!==_0x26fd2c),this['bind']('currentChangeNumber')['to'](this,'isReady',this,'diff',this,'activeChange',(_0x5ac271,_0x72d423,_0x184ca7)=>_0x5ac271&&_0x184ca7?_0x72d423['changes']['getIndex'](_0x184ca7):0x0),this['bind']('numberOfChanges')['to'](this,'isReady',this,'diff',(_0x861dc7,_0x1eef4b)=>_0x861dc7?_0x1eef4b['changes']['length']:0x0),this['_changeView']=null,this['_changeIdToChange']=new Map(),this['_balloon']=this['editor']['plugins']['get'](_0x867a1d);}['init'](){const _0x4a2657=this['editor'],_0x38e266=new rt(_0x4a2657,{'direction':'backward'}),_0x7feb1d=new rt(_0x4a2657,{'direction':'forward'});(_0x4a2657['commands']['add']('showPreviousChange',_0x38e266),_0x4a2657['commands']['add']('showNextChange',_0x7feb1d),_0x4a2657['commands']['add']('restoreRevision',new nt(_0x4a2657)),this['on']('change:numberOfChanges',()=>{_0x38e266['refresh'](),_0x7feb1d['refresh']();}),this['_setConversion'](),this['_initInteractions'](),_0x4a2657['enableReadOnlyMode']('revision-viewer'),_0x4a2657['plugins']['has']('WidgetToolbarRepository'))&&_0x4a2657['plugins']['get']('WidgetToolbarRepository')['forceDisabled']('revision-viewer');}async['getRevisionDocumentData'](_0x5e95a2){return await this['_utils']['loadRevisionData'](_0x5e95a2,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x5e95a2);}async['getRevisionRootsAttributes'](_0xf63cca){return await this['_utils']['loadRevisionData'](_0xf63cca,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0xf63cca);}async['compare'](_0x3d2317,_0x471d24,_0x37a94a=!0x1){if(!this['isEnabled'])return;const _0x34c213=this['diff'],_0x5022b8=this['repository'],_0x1fe289='string'==typeof _0x3d2317?_0x5022b8['getRevision'](_0x3d2317):_0x3d2317,_0x5b6917='string'==typeof _0x471d24?_0x5022b8['getRevision'](_0x471d24):_0x471d24,_0x587ad2=_0x1fe289['id'],_0x16c85b=_0x5b6917?_0x5b6917['id']:null;if(!_0x37a94a&&this['diff']&&this['diff']['newRevisionId']===_0x587ad2&&this['diff']['oldRevisionId']===_0x16c85b)return Promise['resolve']();this['isReady']=!0x1,this['activeView']=null,this['activeChange']=null,this['diff']=new J(_0x587ad2,_0x16c85b);const _0x363e8a=this['_getRevisionsRange'](_0x1fe289,_0x5b6917,!0x0)['map'](_0x2f88cf=>this['_utils']['loadRevisionData'](_0x2f88cf,this['adapter']));return _0x363e8a['push'](new Promise(_0x5ab77d=>{setTimeout(_0x5ab77d,0x14);})),Promise['all'](_0x363e8a)['then'](()=>{if(!this['isEnabled'])return;this['_cleanUp']();const _0x22f16a=this['_getDiff'](_0x587ad2,_0x16c85b);for(const _0x4ad12f of _0x22f16a['changes'])this['_changeIdToChange']['set'](_0x4ad12f['id'],_0x4ad12f);this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x29cf7e=>{for(const _0x3a1d15 of this['editor']['model']['document']['getRootNames']())_0x29cf7e['detachRoot'](_0x3a1d15);for(const _0x8f048f of Object['keys'](_0x22f16a['model'])){const _0x5398d=_0x29cf7e['addRoot'](_0x8f048f);for(const _0x6892d7 of Object['keys'](_0x22f16a['attributes'][_0x8f048f]))_0x29cf7e['setAttribute'](_0x6892d7,_0x22f16a['attributes'][_0x8f048f][_0x6892d7],_0x5398d);_0x29cf7e['insert'](_0x22f16a['model'][_0x8f048f],_0x5398d,0x0);}}),this['diff']['_setChanges'](this['_sortAndFilterDiffChanges'](_0x22f16a['changes'])),this['isReady']=!0x0;})['catch'](_0x33a32b=>{console['error'](_0x33a32b),this['_cleanUp'](),_0x34c213&&(this['diff']=_0x34c213),this['isReady']=!0x0;});}['addRevisionData'](_0x34d0ab,_0x9fa743){const _0x345432=this['repository']['createRevision'](_0x34d0ab);return _0x345432['on']('_update',(_0x4612a5,_0x238f45,_0x3f297c)=>_0x9fa743(_0x238f45,_0x3f297c,_0x345432)),this['repository']['addRevision'](_0x345432),_0x345432;}['_cleanUp'](){this['activeChange']=null,this['_cleanMarkers'](),this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=null,this['_changeIdToChange']['clear'](),this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x572f11=>{for(const _0x2acfb9 of this['editor']['model']['document']['getRootNames']())_0x572f11['detachRoot'](_0x2acfb9);});}['_sortAndFilterDiffChanges'](_0x31f515){const _0x11c384=[],_0x2fab10=new Map();for(const _0x21c5d9 of this['editor']['model']['document']['getRootNames']()){const _0x409e60=this['editor']['editing']['view']['getDomRoot'](_0x21c5d9);if(!_0x409e60)continue;const _0x424835=_0x409e60['getClientRects']()['item'](0x0);_0x424835&&(_0x11c384['push'](_0x21c5d9),_0x2fab10['set'](_0x21c5d9,_0x424835));}return _0x11c384['sort']((_0x43fae7,_0x48b7e3)=>{const _0x2ba9ea=_0x2fab10['get'](_0x43fae7),_0x50b7e5=_0x2fab10['get'](_0x48b7e3);return _0x2ba9ea['y']-_0x50b7e5['y']||_0x2ba9ea['x']-_0x50b7e5['x'];}),(_0x31f515=_0x31f515['filter'](_0x1179e4=>_0x11c384['includes'](_0x1179e4['rootName'])))['sort']((_0x1875b7,_0x6de901)=>_0x11c384['indexOf'](_0x1875b7['rootName'])-_0x11c384['indexOf'](_0x6de901['rootName'])),_0x31f515;}['_makeTape'](_0xc445a0){const _0x42b722=Array['from'](_0xc445a0['markers'])['filter'](([_0x3ee8d0,_0x3e09bd])=>_0x3ee8d0['startsWith']('revision:')&&!_0x3e09bd['isCollapsed']),_0x2ea007=Array['from'](this['editor']['model']['createRangeIn'](_0xc445a0)['getWalker']({'singleCharacters':!0x0}));if(0x0!=_0x42b722['length'])for(const _0x117094 of _0x2ea007){const [_0x2e6b6,_0x8f4923]=_0x42b722[0x0],[,_0x35c86a,_0x63ef8b]=_0x2e6b6['split'](':');if(_0x8f4923['end']['isEqual'](_0x117094['nextPosition'])&&_0x42b722['shift'](),(_0x117094['previousPosition']['isEqual'](_0x8f4923['start'])||_0x117094['previousPosition']['isAfter'](_0x8f4923['start']))&&('insertion'==_0x35c86a?_0x117094['isAdded']={'userId':_0x63ef8b}:'deletion'==_0x35c86a&&(_0x117094['isRemoved']={'userId':_0x63ef8b})),0x0==_0x42b722['length'])break;}return _0x2ea007;}['_refreshStartEndIndex'](_0x5bd9cf){const _0x5e3259=new Map();for(let _0x516713=0x0;_0x516713<_0x5bd9cf['length'];_0x516713++)'text'===_0x5bd9cf[_0x516713]['type']?(_0x5bd9cf[_0x516713]['item']['startIndex']=_0x516713,_0x5bd9cf[_0x516713]['item']['endIndex']=_0x516713):('elementStart'===_0x5bd9cf[_0x516713]['type']?_0x5bd9cf[_0x516713]['item']['startIndex']=_0x516713:'elementEnd'===_0x5bd9cf[_0x516713]['type']&&(_0x5bd9cf[_0x516713]['item']['endIndex']=_0x516713),_0x5e3259['set'](_0x5bd9cf[_0x516713]['id'],_0x516713));for(const _0x12b19b of _0x5e3259['values']())'elementStart'===_0x5bd9cf[_0x12b19b]['type']?_0x5bd9cf[_0x12b19b]['item']['endIndex']=_0x5e3259['get'](_0x5bd9cf[_0x12b19b]['pairId']):'elementEnd'===_0x5bd9cf[_0x12b19b]['type']&&(_0x5bd9cf[_0x12b19b]['item']['startIndex']=_0x5e3259['get'](_0x5bd9cf[_0x12b19b]['pairId']));}['_processTape'](_0x1c2c4b){for(let _0x34292f=0x0;_0x34292f<_0x1c2c4b['length'];_0x34292f++){if('elementStart'===_0x1c2c4b[_0x34292f]['type'])_0x1c2c4b[_0x34292f]['item']['startIndex']=_0x34292f;else{if('elementEnd'===_0x1c2c4b[_0x34292f]['type']){_0x1c2c4b[_0x34292f]['item']['endIndex']=_0x34292f;const _0x5366b4=_0x1c2c4b[_0x34292f]['item']['startIndex'];_0x1c2c4b[_0x5366b4]['pairId']=_0x1c2c4b[_0x34292f]['id'],_0x1c2c4b[_0x34292f]['pairId']=_0x1c2c4b[_0x5366b4]['id'];}else _0x1c2c4b[_0x34292f]['item']['startIndex']=_0x34292f,_0x1c2c4b[_0x34292f]['item']['endIndex']=_0x34292f,_0x1c2c4b[_0x34292f]['pairId']=null;}_0x1c2c4b[_0x34292f]['markersStart']||(_0x1c2c4b[_0x34292f]['markersStart']=[],_0x1c2c4b[_0x34292f]['markersEnd']=[]);}}['_markInsertions'](_0x38f387,_0x2b9a60){const _0x29714f=_0x38f387['filter'](_0x2e503c=>!_0x2e503c['isAdded']);for(let _0x4074eb=0x0;_0x4074eb<_0x2b9a60['length'];_0x4074eb++)_0x2b9a60[_0x4074eb]['isAdded']&&(_0x29714f[_0x4074eb]['isAdded']=_0x2b9a60[_0x4074eb]['isAdded']);}['_getDiff'](_0x4a6d6f,_0x550ec4=null){const _0x5de328=this['repository']['getRevision'](_0x4a6d6f),_0x5cf73c=_0x550ec4?this['repository']['getRevision'](_0x550ec4):null,_0x4dac85=this['_getRevisionsRange'](_0x5de328,_0x5cf73c),_0x5a99ea=_0x4dac85[_0x4dac85['length']-0x1],_0x201386=new Map(),_0x3e92fe={'model':{},'attributes':{},'changes':[]},_0x627a99=new Set(),_0x13a080=new Map();for(let _0x52358a=_0x4dac85['length']-0x1;_0x52358a>=0x0;_0x52358a--){const _0x67e3c5=_0x4dac85[_0x52358a];for(const _0x16b18c of Object['keys'](_0x67e3c5['diffData']))if(_0x67e3c5['diffData'][_0x16b18c]['attachChange']){const _0x34b4f4=_0x67e3c5['diffData'][_0x16b18c]['attachChange'];_0x34b4f4['isAttached']?(_0x627a99['add'](_0x16b18c),_0x13a080['has'](_0x16b18c)&&_0x13a080['get'](_0x16b18c)['userId']==_0x34b4f4['userId']?_0x13a080['delete'](_0x16b18c):_0x13a080['set'](_0x16b18c,_0x34b4f4)):_0x13a080['has'](_0x16b18c)?(_0x627a99['delete'](_0x16b18c),_0x13a080['delete'](_0x16b18c)):(_0x627a99['add'](_0x16b18c),_0x13a080['set'](_0x16b18c,_0x34b4f4));}else _0x627a99['add'](_0x16b18c);}for(const _0x3b5441 of _0x627a99){const _0x5450e0=_0x13a080['has'](_0x3b5441)&&!_0x13a080['get'](_0x3b5441)['isAttached'];let _0x2f17c1=_0x5450e0?_0x4dac85['length']-0x1:0x0;const _0x4c6c5f=_0x5450e0?-0x1:0x1;for(;_0x4dac85[_0x2f17c1];){const _0x19e624=_0x4dac85[_0x2f17c1];if(_0x19e624['diffData'][_0x3b5441]){const _0x50ee5f=_0x5450e0?_0x19e624['diffData'][_0x3b5441]['attributesBefore']:_0x19e624['diffData'][_0x3b5441]['attributesAfter'];_0x3e92fe['attributes'][_0x3b5441]=_0x50ee5f?_0x40b863(_0x50ee5f):{};break;}_0x2f17c1+=_0x4c6c5f;}}for(const _0x57def9 of _0x4dac85){_0x57def9['model']={};for(const _0x4e5d39 of _0x57def9['authors'])_0x201386['set'](_0x4e5d39['id'],_0x4e5d39);for(const _0x524866 of _0x627a99){const _0x3c44d0=_0x57def9['diffData'][_0x524866]?_0x57def9['diffData'][_0x524866]['insertions']:'[]',_0x5318ca=_0x57def9['diffData'][_0x524866]?_0x57def9['diffData'][_0x524866]['deletions']:'[]';_0x57def9['model'][_0x524866]={'insertions':this['_utils']['_makeModelFromViewString'](_0x3c44d0),'deletions':this['_utils']['_makeModelFromViewString'](_0x5318ca)};}}for(const _0xeae38b of _0x627a99){let _0x194eef=null,_0x26ff99=0x0;const _0x4fc4ce=new Map(Array['from'](_0x5de328['model'][_0xeae38b]['insertions']['markers'])['filter'](([_0x3f6503])=>!_0x3f6503['startsWith']('revision:')));let _0x1f0cf7=0x0;for(const _0x281bab of _0x4dac85){const _0xae5497=this['_makeTape'](_0x281bab['model'][_0xeae38b]['insertions']);_0x281bab==_0x5de328?(_0x194eef=_0xae5497,_0x26ff99=_0x194eef['length'],_0x194eef['forEach'](_0x30484b=>{_0x30484b['id']=_0x1f0cf7++;}),this['_processTape'](_0x194eef)):this['_markInsertions'](_0x194eef,_0xae5497);const _0x29afc2=_0x194eef['filter'](_0x24753f=>!_0x24753f['isAdded'])['map'](_0x55096e=>_0x55096e['id']);let _0x5c9be8=0x0;const _0x1eecc5=this['_makeTape'](_0x281bab['model'][_0xeae38b]['deletions']);_0x1eecc5['forEach'](_0x3667c9=>{_0x3667c9['isRemoved']?_0x3667c9['id']=_0x26ff99++:_0x3667c9['id']=_0x29afc2[_0x5c9be8++];}),this['_processTape'](_0x1eecc5),this['_setDistance'](_0x194eef,'isAdded'),this['_setDistance'](_0x1eecc5,'isRemoved'),_0x281bab==_0x5de328&&this['_markMarkers'](_0x194eef,_0x4fc4ce),_0x194eef=this['_joinTapes'](_0x194eef,_0x1eecc5),this['_refreshStartEndIndex'](_0x194eef),this['_setDistance'](_0x194eef,'isRemoved');}_0x194eef=_0x194eef['filter'](_0x62230c=>!(_0x62230c['isAdded']&&_0x62230c['isRemoved']));const _0x4ee8ea=new Map(_0x5a99ea['model'][_0xeae38b]['deletions']['markers']),_0x34f787=new Set(_0x4fc4ce['keys']());for(const _0x4712e6 of _0x4ee8ea['keys']())_0x34f787['delete'](_0x4712e6);this['_markSuggestions'](_0x194eef,_0x34f787),this['_fixObsoleteTags'](_0x194eef),_0x194eef=this['_removeMissingPairs'](_0x194eef),_0x194eef=this['_markMismatchedRemovedTags'](_0x194eef),_0x194eef=this['_removeUnsupportedChanges'](_0x194eef);const {root:_0x24d5a7,changes:_0x59e63e}=this['_makeModelFromTape'](_0x194eef,_0x201386,_0xeae38b);_0x3e92fe['model'][_0xeae38b]=_0x24d5a7;const _0x6f8731=_0x13a080['get'](_0xeae38b);if(_0x6f8731){const _0x325fcf=_0x201386['get'](_0x6f8731['userId']),_0x1bec4e=new G({'author':_0x325fcf,'type':_0x6f8731['isAttached']?'add':'remove','data':{'isOnRoot':!0x0},'createdAt':new Date(),'rootName':_0xeae38b});_0x59e63e['unshift'](_0x1bec4e),_0x3e92fe['attributes'][_0xeae38b]['revisionHistoryAttachChange']=_0x1bec4e['id'];}_0x3e92fe['changes']=_0x3e92fe['changes']['concat'](_0x59e63e);}return _0x3e92fe;}['_markMarkers'](_0x227c9d,_0x4cca66){for(let _0xae05d3=0x0;_0xae05d3<_0x227c9d['length'];_0xae05d3++)for(const [_0x44b9f3,_0x2ce1b7]of _0x4cca66)!_0x2ce1b7['isCollapsed']&&_0x2ce1b7['start']['isEqual'](_0x227c9d[_0xae05d3]['previousPosition'])&&_0x227c9d[_0xae05d3]['markersStart']['push'](_0x44b9f3),_0x2ce1b7['end']['isEqual'](_0x227c9d[_0xae05d3]['nextPosition'])&&_0x227c9d[_0xae05d3]['markersEnd']['push'](_0x44b9f3);}['_joinTapes'](_0xf72de1,_0x132882){let _0x343d97=[],_0x44c279=0x0,_0x140379=0x0;for(;_0x44c279<_0xf72de1['length']||_0x140379<_0x132882['length'];){const _0x469c3a=_0xf72de1[_0x44c279]||{},_0xc5ff76=_0x132882[_0x140379]||{};if(_0x469c3a['id']==_0xc5ff76['id'])_0x44c279++,_0x140379++,_0x343d97['push'](_0x469c3a);else{if(_0xc5ff76['isRemoved']&&_0x469c3a['isAdded']){const {commonTape:_0x15d53e,iEnd:_0x3ad441,jEnd:_0x186f1}=this['_threeWayMerge'](_0xf72de1,_0x44c279,_0x132882,_0x140379);_0x343d97=_0x343d97['concat'](_0x15d53e),_0x44c279=_0x3ad441,_0x140379=_0x186f1;}else _0xc5ff76['isRemoved']?(_0x140379++,_0x343d97['push'](_0xc5ff76)):(_0x44c279++,_0x343d97['push'](_0x469c3a));}}return _0x343d97;}['_markSuggestions'](_0x2fdd73,_0x4db469){const _0x2b561d=[];for(let _0x4fee8a=0x0;_0x4fee8a<_0x2fdd73['length'];_0x4fee8a++){for(let _0x365034=0x0;_0x365034<_0x2fdd73[_0x4fee8a]['markersStart']['length'];_0x365034++){const _0x56a61e=_0x2fdd73[_0x4fee8a]['markersStart'][_0x365034];if(!_0x4db469['has'](_0x56a61e))continue;const {group:_0x5e2d2a,type:_0x3edb29,authorId:_0x5dca77}=_0x48fa5b(_0x56a61e);'revision-suggestion'!=_0x5e2d2a||'insertion'!=_0x3edb29&&'deletion'!=_0x3edb29||(_0x2b561d['unshift']({'type':_0x3edb29,'name':_0x56a61e,'userId':_0x5dca77}),_0x2fdd73[_0x4fee8a]['markersStart']['splice'](_0x365034,0x1),_0x365034--);}_0x3e35bc(_0x2fdd73[_0x4fee8a]);for(let _0x5de289=0x0;_0x5de289<_0x2fdd73[_0x4fee8a]['markersEnd']['length'];_0x5de289++){const _0x3af2b3=_0x2fdd73[_0x4fee8a]['markersEnd'][_0x5de289];if(!_0x4db469['has'](_0x3af2b3))continue;const {group:_0x16e0d2,type:_0x35c003}=_0x48fa5b(_0x3af2b3);if('revision-suggestion'!=_0x16e0d2||'insertion'!=_0x35c003&&'deletion'!=_0x35c003)continue;_0x2fdd73[_0x4fee8a]['markersEnd']['splice'](_0x5de289,0x1),_0x5de289--;const _0xdec05=_0x2b561d['findIndex'](_0xfd712b=>_0xfd712b['name']==_0x3af2b3);_0xdec05>-0x1&&_0x2b561d['splice'](_0xdec05,0x1);}}function _0x48fa5b(_0x5808b5){const _0x99c327=_0x5808b5['split'](':');return{'group':_0x99c327[0x0],'type':_0x99c327[0x1],'subType':_0x99c327['length']>=0x5?_0x99c327[0x2]:null,'id':_0x99c327['length']<0x5?_0x99c327[0x2]:_0x99c327[0x3],'authorId':_0x99c327['length']<0x5?_0x99c327[0x3]:_0x99c327[0x4],'markerCount':0x6==_0x99c327['length']?_0x99c327[0x5]:null};}function _0x3e35bc(_0x387f73){for(let _0x3d8d2a=0x0;_0x3d8d2a<_0x2b561d['length'];_0x3d8d2a++){if(_0x387f73['isAdded']&&'insertion'==_0x2b561d[_0x3d8d2a]['type']&&_0x387f73['isAdded']['userId']==_0x2b561d[_0x3d8d2a]['userId'])return _0x387f73['isAddSuggestion']=_0x2b561d[_0x3d8d2a],void delete _0x387f73['isAdded'];if(!_0x387f73['isAdded']&&!_0x387f73['isRemoved']&&'deletion'==_0x2b561d[_0x3d8d2a]['type'])return void(_0x387f73['isRemoveSuggestion']=_0x2b561d[_0x3d8d2a]);}}}['_setDistance'](_0x507f2a,_0xd4d0ec){let _0x19271c=0x0,_0x43ceee=!0x1;const _0x1cb092=new Map();for(const _0x1765da of _0x507f2a)_0x1765da[_0xd4d0ec]?_0x43ceee&&(_0x19271c++,_0x43ceee=!0x1):(_0x19271c++,_0x43ceee=!0x0),_0x1cb092['set'](_0x1765da['id'],_0x19271c);for(let _0x7f34e5=0x0;_0x7f34e5<_0x507f2a['length'];_0x7f34e5++){if('isRemoved'==_0xd4d0ec&&_0x507f2a[_0x7f34e5]['isAdded']||'isAdded'==_0xd4d0ec&&_0x507f2a[_0x7f34e5]['isRemoved'])continue;if('text'==_0x507f2a[_0x7f34e5]['type']){_0x507f2a[_0x7f34e5]['distance']=0x0;continue;}const _0x2d761a=_0x1cb092['get'](_0x507f2a[_0x7f34e5]['pairId']),_0x5337f7=_0x1cb092['get'](_0x507f2a[_0x7f34e5]['id']);_0x507f2a[_0x7f34e5]['distance']=_0x2d761a-_0x5337f7;}}['_getRevisionsRange'](_0x5994d8,_0x4653f8,_0x3fde9c=!0x1){const _0x4e8423=[];let _0x2465f6=this['repository']['getIndex'](_0x5994d8),_0x4ed638=this['repository']['getIndex'](_0x4653f8);for(-0x1==_0x4ed638&&(_0x4ed638=this['repository']['_revisions']['length'],_0x3fde9c=!0x1);_0x2465f6<_0x4ed638;)_0x4e8423['push'](this['repository']['getRevision'](_0x2465f6)),_0x2465f6++;return _0x3fde9c&&_0x4e8423['push'](this['repository']['getRevision'](_0x2465f6)),_0x4e8423;}['_threeWayMerge'](_0x4a1517,_0x3976af,_0x544a88,_0xc59edb){const _0x9f104b=this['editor']['model']['schema'];let _0x125c7e=_0x3976af;for(;_0x4a1517[_0x125c7e]&&_0x4a1517[_0x125c7e]['isAdded'];)_0x125c7e++;let _0x224229=_0xc59edb;for(;_0x544a88[_0x224229]&&_0x544a88[_0x224229]['isRemoved'];)_0x224229++;_0x2108d9(_0x4a1517,_0x3976af,_0x125c7e),_0x2108d9(_0x544a88,_0xc59edb,_0x224229);const _0x1656f8=_0x544a88['slice'](_0xc59edb,_0x224229)['concat'](_0x4a1517['slice'](_0x3976af,_0x125c7e));return _0x1656f8['sort']((_0x3592be,_0x33bb94)=>_0x3592be['side']!=_0x33bb94['side']?_0x3592be['side']-_0x33bb94['side']:_0x3592be['level']!=_0x33bb94['level']?_0x3592be['level']-_0x33bb94['level']:_0x3592be['distance']!=_0x33bb94['distance']?_0x33bb94['distance']-_0x3592be['distance']:!!_0x3592be['isAdded']!=!!_0x33bb94['isAdded']?-0x1==_0x3592be['side']||0x0==_0x3592be['side']?_0x3592be['isAdded']?-0x1:0x1:_0x3592be['isAdded']?0x1:-0x1:_0x3592be['index']-_0x33bb94['index']),{'commonTape':_0x1656f8,'iEnd':_0x125c7e,'jEnd':_0x224229};function _0x2108d9(_0x18ec84,_0x5ef4b5,_0x3aa616){let _0x42486e=-0x1,_0x20f2fd=Number['POSITIVE_INFINITY'],_0x1ef631=!0x0;for(let _0x406248=_0x5ef4b5;_0x406248<_0x3aa616;_0x406248++)if(_0x9f104b['isInline'](_0x18ec84[_0x406248]['item'])||(_0x1ef631=!0x1),_0x18ec84[_0x406248]['item']['startIndex']<_0x5ef4b5&&(_0x42486e=_0x406248),_0x18ec84[_0x406248]['item']['endIndex']>=_0x3aa616){_0x20f2fd=_0x406248;break;}_0x1ef631&&(_0x42486e=_0x3aa616-0x1);for(let _0x253f95=_0x5ef4b5;_0x253f95<_0x3aa616;_0x253f95++)_0x18ec84[_0x253f95]['side']=_0x253f95<=_0x42486e?-0x1:_0x253f95<_0x20f2fd?0x0:0x1,_0x18ec84[_0x253f95]['index']=_0x253f95;let _0x3deba8=0x0;for(let _0x4b471a=_0x5ef4b5;_0x4b471a<=_0x42486e;_0x4b471a++)0x0==_0x18ec84[_0x4b471a]['distance']?_0x18ec84[_0x4b471a]['level']=_0x3deba8:(_0x3deba8++,_0x18ec84[_0x4b471a]['level']=_0x3deba8,_0x3deba8++);for(let _0x389e39=_0x5ef4b5;_0x389e39<_0x3aa616;_0x389e39++)0x0==_0x18ec84[_0x389e39]['side']&&(_0x18ec84[_0x389e39]['level']=_0x3deba8);_0x3deba8=0x0;for(let _0x5e05ca=_0x3aa616-0x1;_0x5e05ca>=_0x20f2fd;_0x5e05ca--)0x0==_0x18ec84[_0x5e05ca]['distance']?_0x18ec84[_0x5e05ca]['level']=_0x3deba8:(_0x3deba8--,_0x18ec84[_0x5e05ca]['level']=_0x3deba8,_0x3deba8--);}}['_fixObsoleteTags'](_0x3d7817){const _0x169106=new Map(),_0x146c96=this['editor']['model']['schema'];for(let _0xefdce3=0x1;_0xefdce3<_0x3d7817['length'];_0xefdce3++){let _0x4af6c3,_0x1ceb38,_0x24f68d;const _0x4a43e4=_0x3d7817[_0xefdce3],_0x47086d=_0x3d7817[_0xefdce3-0x1];if('text'==_0x4a43e4['type'])continue;if(_0x4a43e4['type']!=_0x47086d['type'])continue;if(!_0x146c96['isBlock'](_0x47086d['item'])||_0x146c96['isLimit'](_0x47086d['item']))continue;if(!_0x146c96['isBlock'](_0x4a43e4['item'])||_0x146c96['isLimit'](_0x4a43e4['item']))continue;if((_0x3d7817[_0xefdce3]['isAdded']||_0x3d7817[_0xefdce3]['isAddSuggestion'])&&_0x3d7817[_0xefdce3-0x1]['isRemoved'])_0x4af6c3=_0x3d7817[_0xefdce3],_0x1ceb38=_0x3d7817[_0xefdce3-0x1],_0x24f68d=_0xefdce3-0x1;else{if(!_0x3d7817[_0xefdce3]['isRemoved']||!_0x3d7817[_0xefdce3-0x1]['isAdded']&&!_0x3d7817[_0xefdce3-0x1]['isAddSuggestion'])continue;_0x4af6c3=_0x3d7817[_0xefdce3-0x1],_0x1ceb38=_0x3d7817[_0xefdce3],_0x24f68d=_0xefdce3;}const _0x30bff9=_0x4af6c3['level']==_0x1ceb38['level'],_0x29de04=Math['abs'](_0x4af6c3['level'])<Math['abs'](_0x1ceb38['level'])&&0x0==_0x1ceb38['distance'];(_0x30bff9||_0x29de04)&&(_0x169106['set'](_0x1ceb38['id'],_0x4af6c3['id']),_0x3d7817['splice'](_0x24f68d,0x1),_0xefdce3--,_0x4af6c3['isAdded']=!0x1);}for(let _0x5c9e7e=0x0;_0x5c9e7e<_0x3d7817['length'];_0x5c9e7e++)_0x169106['has'](_0x3d7817[_0x5c9e7e]['pairId'])&&(_0x3d7817[_0x5c9e7e]['pairId']=_0x169106['get'](_0x3d7817[_0x5c9e7e]['pairId']));}['_removeMissingPairs'](_0x3a08f2){const _0x156c5e=new Set(_0x3a08f2['map'](_0xd4d83f=>_0xd4d83f['id']));for(let _0x2e0456=0x0;_0x2e0456<_0x3a08f2['length'];_0x2e0456++)_0x156c5e['has'](_0x3a08f2[_0x2e0456]['pairId'])||0x0==_0x3a08f2[_0x2e0456]['distance']||(_0x3a08f2[_0x2e0456]['isIncorrect']=!0x0);return _0x3a08f2['filter'](_0x3e28d9=>!_0x3e28d9['isIncorrect']);}['_markMismatchedRemovedTags'](_0x5d6bc7){const _0x170644=new Set();for(let _0x3bf36c=0x0;_0x3bf36c<_0x5d6bc7['length'];_0x3bf36c++){if(_0x170644['has'](_0x5d6bc7[_0x3bf36c]['id'])&&_0x5d6bc7[_0x3bf36c]['isRemoved']&&(_0x5d6bc7[_0x3bf36c]['isIncorrect']=!0x0),_0x5d6bc7[_0x3bf36c]['isIncorrect'])continue;if(0x0==_0x5d6bc7[_0x3bf36c]['distance'])continue;if('elementStart'!=_0x5d6bc7[_0x3bf36c]['type'])continue;if(null==_0x5d6bc7[_0x3bf36c]['pairId'])continue;let _0x4d348e=_0x3bf36c+0x1,_0x39c17e=0x0;for(;_0x5d6bc7[_0x4d348e]['id']!=_0x5d6bc7[_0x3bf36c]['pairId'];)'elementStart'==_0x5d6bc7[_0x4d348e]['type']?_0x39c17e++:'elementEnd'==_0x5d6bc7[_0x4d348e]['type']&&_0x39c17e--,_0x4d348e++;if(0x0!=_0x39c17e){if(_0x5d6bc7[_0x3bf36c]['isRemoved'])_0x5d6bc7[_0x3bf36c]['isIncorrect']=!0x0;else{for(;_0x4d348e!=_0x3bf36c;)_0x5d6bc7[_0x4d348e]['isRemoved']&&0x0!=_0x5d6bc7[_0x4d348e]['distance']&&(_0x5d6bc7[_0x4d348e]['isIncorrect']=!0x0,_0x170644['add'](_0x5d6bc7[_0x4d348e]['pairId'])),_0x4d348e--;}}}return _0x5d6bc7['filter'](_0x384b55=>!_0x384b55['isIncorrect']);}['_removeUnsupportedChanges'](_0x450e9a){const _0x181df3=this['editor']['model']['schema'];for(let _0x4bbb05=0x0;_0x4bbb05<_0x450e9a['length'];_0x4bbb05++){if(!(_0x450e9a[_0x4bbb05]['isAdded']||_0x450e9a[_0x4bbb05]['isAddSuggestion']||_0x450e9a[_0x4bbb05]['isRemoved']||_0x450e9a[_0x4bbb05]['isRemoveSuggestion']))continue;if(0x0==_0x450e9a[_0x4bbb05]['distance'])continue;const _0xb4d3e=_0x450e9a[_0x4bbb05]['item'];_0x181df3['isBlock'](_0xb4d3e)||_0x181df3['isLimit'](_0xb4d3e)||(_0x450e9a[_0x4bbb05]['isAdded']&&delete _0x450e9a[_0x4bbb05]['isAdded'],_0x450e9a[_0x4bbb05]['isAddSuggestion']&&delete _0x450e9a[_0x4bbb05]['isAddSuggestion'],_0x450e9a[_0x4bbb05]['isRemoveSuggestion']&&delete _0x450e9a[_0x4bbb05]['isRemoveSuggestion'],_0x450e9a[_0x4bbb05]['isRemoved']&&(_0x450e9a[_0x4bbb05]['isIncorrect']=!0x0));}return _0x450e9a['filter'](_0x1fc4e2=>!_0x1fc4e2['isIncorrect']);}['_makeModelFromTape'](_0xd16e98,_0x311eb2,_0x2f0810){const _0x3a0900=new _0x3269cc(),_0x4031d1=[],_0x43b8d4=new Map(),_0x5bc072=this['editor']['model'],_0x36c2fa=_0x5bc072['schema'],_0x522b16=[_0x3a0900],_0x366e92={},_0x1d9868={'isAdded':[],'isRemoved':[],'isAddSuggestion':[],'isRemoveSuggestion':[]};let _0x11dd38=null;const _0x40643c=[0x0];for(let _0x174421=0x0;_0x174421<_0xd16e98['length'];_0x174421++)if('elementStart'===_0xd16e98[_0x174421]['type']){_0xd16e98[_0x174421]['previousPosition']=_0x5bc072['createPositionFromPath'](_0x3a0900,_0x40643c);const _0x13f0c0=new _0x5978e5(_0xd16e98[_0x174421]['item']['name'],_0xd16e98[_0x174421]['item']['getAttributes']());_0x522b16[0x0]['_appendChild'](_0x13f0c0),_0x40643c['push'](0x0),_0x522b16['unshift'](_0x13f0c0),_0xd16e98[_0x174421]['nextPosition']=_0x5bc072['createPositionFromPath'](_0x3a0900,_0x40643c);}else'elementEnd'===_0xd16e98[_0x174421]['type']?(_0x522b16['shift'](),_0xd16e98[_0x174421]['previousPosition']=_0x5bc072['createPositionFromPath'](_0x3a0900,_0x40643c),_0x40643c['pop'](),_0x40643c[_0x40643c['length']-0x1]++,_0xd16e98[_0x174421]['nextPosition']=_0x5bc072['createPositionFromPath'](_0x3a0900,_0x40643c)):(_0xd16e98[_0x174421]['previousPosition']=_0x5bc072['createPositionFromPath'](_0x3a0900,_0x40643c),_0x11dd38?_0x11dd38['_data']+=_0xd16e98[_0x174421]['item']['data']:_0x11dd38=new _0x44cd4c(_0xd16e98[_0x174421]['item']['data'],_0xd16e98[_0x174421]['item']['getAttributes']()),_0xd16e98[_0x174421+0x1]&&'text'===_0xd16e98[_0x174421+0x1]['type']&&_0x594e92(_0x11dd38,_0xd16e98[_0x174421+0x1]['item'])||(_0x522b16[0x0]['_appendChild'](_0x11dd38),_0x11dd38=null),_0x40643c[_0x40643c['length']-0x1]+=_0xd16e98[_0x174421]['item']['offsetSize'],_0xd16e98[_0x174421]['nextPosition']=_0x5bc072['createPositionFromPath'](_0x3a0900,_0x40643c));for(let _0x3215d2=0x0;_0x3215d2<_0xd16e98['length'];_0x3215d2++){const _0x1ba332=_0xd16e98[_0x3215d2]['previousPosition'],_0x409ab8=_0xd16e98[_0x3215d2]['nextPosition'];for(const _0x3460bc of _0xd16e98[_0x3215d2]['markersStart'])_0x43b8d4['set'](_0x3460bc,{'start':_0x1ba332,'end':null});_0x52c28b('isRemoveSuggestion',_0x3215d2,_0x1ba332,_0x409ab8),_0x52c28b('isAddSuggestion',_0x3215d2,_0x1ba332,_0x409ab8),_0x52c28b('isRemoved',_0x3215d2,_0x1ba332,_0x409ab8),_0x52c28b('isAdded',_0x3215d2,_0x1ba332,_0x409ab8);for(const _0x30910f of _0xd16e98[_0x3215d2]['markersEnd']){const _0x5b860a=_0x43b8d4['get'](_0x30910f);_0x5b860a?_0x5b860a['end']=_0x409ab8:_0x43b8d4['set'](_0x30910f,{'start':_0x409ab8,'end':_0x409ab8});}}for(const [_0x46a1ad,_0x152186]of _0x43b8d4){const _0x67d47c=this['editor']['model']['createRange'](_0x152186['start'],_0x152186['end']);_0x3a0900['markers']['set'](_0x46a1ad,_0x67d47c);}return _0x4031d1['sort']((_0x59d361,_0x481944)=>{const _0x4f6e53=_0x3a0900['markers']['get']('revision:'+_0x59d361['id']),_0xbab63f=_0x3a0900['markers']['get']('revision:'+_0x481944['id']);return _0x4f6e53['start']['isBefore'](_0xbab63f['start'])?-0x1:_0x4f6e53['start']['isAfter'](_0xbab63f['start'])?0x1:_0x4f6e53['end']['isBefore'](_0xbab63f['end'])?-0x1:_0x4f6e53['end']['isAfter'](_0xbab63f['end'])?0x1:'add'===_0x59d361['type']?-0x1:0x1;}),{'root':_0x3a0900,'changes':_0x4031d1};function _0x52c28b(_0x15941b,_0xec24c4,_0x1d5672,_0x754128){const _0x463fd8=!!_0xd16e98[_0xec24c4][_0x15941b],_0x4f436c=_0x463fd8?_0xd16e98[_0xec24c4][_0x15941b]['userId']:null,_0x38153c=_0xec24c4===_0xd16e98['length']-0x1,_0x59d80a=_0x1d9868[_0x15941b][0x0],_0x424f45=_0x36c2fa['isObject'](_0xd16e98[_0xec24c4]['item']);!_0x366e92[_0x15941b]&&_0x463fd8?_0x366e92[_0x15941b]={'start':_0x1d5672,'tapeItem':_0xd16e98[_0xec24c4],'userId':_0x4f436c,'type':_0x15941b}:_0x366e92[_0x15941b]&&!_0x463fd8?(_0x366e92[_0x15941b]['end']=_0x1d5672,_0x5e3b39(_0x366e92[_0x15941b]),_0x366e92[_0x15941b]=null):_0x366e92[_0x15941b]&&_0x463fd8&&_0x366e92[_0x15941b]['userId']!==_0x4f436c&&(_0x366e92[_0x15941b]['end']=_0x1d5672,_0x59d80a&&_0x59d80a['userId']===_0x366e92[_0x15941b]['userId']||_0x5e3b39(_0x366e92[_0x15941b]),_0x366e92[_0x15941b]={'start':_0x1d5672,'tapeItem':_0xd16e98[_0xec24c4],'userId':_0x4f436c,'type':_0x15941b}),_0x366e92[_0x15941b]&&_0x424f45&&('elementStart'!==_0xd16e98[_0xec24c4]['type']||_0x59d80a&&_0x59d80a['userId']===_0x4f436c||_0x1d9868[_0x15941b]['unshift']({'userId':_0x4f436c,'object':_0xd16e98[_0xec24c4]['item'],'change':_0x366e92[_0x15941b]}),'elementEnd'===_0xd16e98[_0xec24c4]['type']&&_0x59d80a&&_0x59d80a['object']===_0xd16e98[_0xec24c4]['item']&&(_0x1d9868[_0x15941b]['shift'](),_0x366e92[_0x15941b]=_0x59d80a['change'])),_0x366e92[_0x15941b]&&_0x38153c&&(_0x366e92[_0x15941b]['end']=_0x754128,_0x5e3b39(_0x366e92[_0x15941b]),_0x366e92[_0x15941b]=null);}function _0x5e3b39({start:_0x378245,end:_0x33fb9e,tapeItem:_0x167027,userId:_0x17d22f,type:_0x4fd835}){const _0x59654e=_0x167027['item'],_0x2d2f93=_0x5bc072['schema']['isBlock'](_0x59654e)&&!_0x5bc072['schema']['isLimit'](_0x59654e),_0x5897d7=_0x378245['nodeAfter']==_0x33fb9e['parent']&&_0x33fb9e['isAtStart'];if(_0x2d2f93&&_0x5897d7)return;const _0x40ab4e=_0x5bc072['createRange'](_0x378245,_0x33fb9e),_0x1aaf75=_0x311eb2['get'](_0x17d22f),_0x403a57=new G({'author':_0x1aaf75,'type':'isAdded'==_0x4fd835||'isAddSuggestion'==_0x4fd835?'add':'remove','data':{'isSuggestion':'isAddSuggestion'==_0x4fd835||'isRemoveSuggestion'==_0x4fd835},'createdAt':new Date(),'rootName':_0x2f0810});_0x4031d1['push'](_0x403a57),_0x3a0900['markers']['set']('revision:'+_0x403a57['id'],_0x40ab4e);}function _0x594e92(_0x2945ab,_0x20f720){const _0x55720a=_0x2945ab['getAttributes'](),_0x4c1330=_0x20f720['getAttributes']();for(const _0x15314a of _0x55720a){if(_0x15314a[0x1]!==_0x20f720['getAttribute'](_0x15314a[0x0]))return!0x1;_0x4c1330['next']();}return _0x4c1330['next']()['done'];}}['_setConversion'](){this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision','view':_0x386eeb=>{const _0x2bbd89=_0x386eeb['markerName']['split'](':')[0x1],_0x974a77=this['_getChangeFromId'](_0x2bbd89);if(!_0x974a77)return null;const _0x1656b4='add'==_0x974a77['type']?'insertion':'deletion',_0x76881b=['ck-suggestion-marker','ck-suggestion-marker-'+_0x1656b4];return _0x974a77['data']['isSuggestion']&&_0x76881b['push']('ck-suggestion-marker-'+_0x1656b4+'-new'),this['activeChange']==_0x974a77&&_0x76881b['push']('ck-suggestion-marker--active'),{'classes':_0x76881b,'attributes':{'data-change-id':_0x2bbd89}};}}),this['editor']['conversion']['for']('upcast')['add'](_0x5a33e2=>{_0x5a33e2['on']('element:pre',(_0x570965,_0x5b2b25,_0x311705)=>{const _0x327e3a=_0x5b2b25['viewItem']['getChild'](0x0);if(!_0x327e3a||!_0x327e3a['is']('element','code'))return;if(!_0x311705['consumable']['consume'](_0x327e3a,{'attributes':['vid_start','vid_end']}))return;const _0x4454c6=_0x5b2b25['modelRange']['start']['nodeAfter'];_0x311705['writer']['setAttribute']('vid_start',_0x327e3a['getAttribute']('vid_start'),_0x4454c6),_0x311705['writer']['setAttribute']('vid_end',_0x327e3a['getAttribute']('vid_end'),_0x4454c6);},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['add'](_0x1ae3e1=>{_0x1ae3e1['on']('element',(_0x157b27,_0x4a7418,_0x4ddcd3)=>{if(!_0x4ddcd3['consumable']['consume'](_0x4a7418['viewItem'],{'attributes':['vid_start','vid_end']}))return;if(_0x4a7418['modelRange']['isCollapsed'])return;const _0x2d9092=_0x4a7418['modelRange']['start']['nodeAfter'];_0x2d9092['hasAttribute']('vid_start')||_0x2d9092['hasAttribute']('vid')||(_0x4ddcd3['writer']['setAttribute']('vid_start',_0x4a7418['viewItem']['getAttribute']('vid_start'),_0x2d9092),_0x4ddcd3['writer']['setAttribute']('vid_end',_0x4a7418['viewItem']['getAttribute']('vid_end'),_0x2d9092));},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['elementToAttribute']({'view':{'name':'span','attributes':{'vid':!0x0}},'model':{'key':'vid','value':_0x4020ce=>_0x4020ce['getAttribute']('vid')}}),this['editor']['model']['schema']['on']('checkAttribute',(_0x56719d,[,_0x5f097d])=>{['vid_start','vid_end','vid']['includes'](_0x5f097d)&&(_0x56719d['return']=!0x0,_0x56719d['stop']());},{'priority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x8765ab=>{_0x8765ab['on']('attribute:vid',(_0x5e3059,_0xb41360,_0x34e158)=>{if('\x20'!=_0xb41360['item']['data']||_0xb41360['item']['parent']['maxOffset']>0x1)return;if(!_0x34e158['consumable']['consume'](_0xb41360['item'],_0x5e3059['name']))return;const _0x4be4c5=_0x34e158['writer'],_0x51ac5a=_0x34e158['mapper']['toViewRange'](_0xb41360['range']);_0x4be4c5['wrap'](_0x51ac5a,_0x4be4c5['createAttributeElement']('span'));});}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',function(_0x54f4b2){const _0x3d87c1=_0x54f4b2['plugins']['get']('RevisionViewer');return(_0x335416,_0x280030,_0x364799)=>{const _0x5152be=_0x280030['markerName']['split'](':')[0x1],_0x3cb2f8=_0x3d87c1['_getChangeFromId'](_0x5152be);if(!_0x3cb2f8)return null;const _0x5bc3e9='add'==_0x3cb2f8['type']?'split':'merge';if(!_0x364799['consumable']['test'](_0x280030['markerRange'],_0x335416['name']))return;const _0x24751b=_0x280030['markerRange']['getWalker'](),_0x5df7ac=_0x280030['markerRange']['start'],_0x3c89bf=_0x54f4b2['model']['schema'];let _0xb41559=null,_0x2132a0=null,_0x2179e2=!0x1,_0x8cdbac=!0x1;for(const _0x241dd5 of _0x24751b){const _0x439814=_0x241dd5['item'];_0x2179e2=_0x2179e2||_0x3c89bf['isContent'](_0x439814);const _0x29d2c0=_0x364799['mapper']['toViewElement'](_0x439814);if(_0x29d2c0&&_0x29d2c0['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x241dd5['type']&&(_0x3c89bf['isBlock'](_0x439814)&&!_0x3c89bf['isLimit'](_0x439814)&&(_0x439814['nextSibling']||_0x5df7ac['isAtEnd']?_0xb41559&&_0xb41559['parent']==_0x439814||(_0xb41559=_0x439814,_0x5f542e(_0x241dd5['previousPosition']),_0x8cdbac=!0x0):_0x2132a0=_0x2132a0||_0x241dd5['previousPosition']));}function _0x5f542e(_0x71d7dc){const _0x9f4525=_0x364799['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x5bc3e9}),_0x3da299=_0x364799['mapper']['toViewPosition'](_0x71d7dc);_0x3cb2f8['data']['isSuggestion']&&_0x364799['writer']['addClass']('ck-suggestion-marker-'+_0x5bc3e9+'-new',_0x9f4525),_0x3d87c1['activeChange']==_0x3cb2f8&&_0x364799['writer']['addClass']('ck-suggestion-marker--active',_0x9f4525),_0x364799['writer']['insert'](_0x3da299,_0x9f4525),_0x364799['mapper']['bindElementToMarker'](_0x9f4525,_0x280030['markerName']);}_0x2179e2||_0x8cdbac||!_0x2132a0||_0x5f542e(_0x2132a0);};}(this['editor']),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision',(_0xb6a278,_0x2a8747,_0xb7971b)=>{const _0xd82850=_0xb7971b['mapper']['markerNameToElements'](_0x2a8747['markerName']);if(_0xd82850){for(const _0x225dcf of _0xd82850)(_0x225dcf['hasClass']('ck-suggestion-marker-split')||_0x225dcf['hasClass']('ck-suggestion-marker-merge'))&&(_0xb7971b['mapper']['unbindElementFromMarkerName'](_0x225dcf,_0x2a8747['markerName']),_0xb7971b['writer']['remove'](_0x225dcf));}},{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',(_0x3ae08f,_0x2605e0,_0x36c3c1)=>{const _0x17a992=_0x2605e0['markerName']['split'](':')[0x1],_0x408f58=this['_getChangeFromId'](_0x17a992);if(!_0x408f58)return null;const _0x3f9017='add'==_0x408f58['type']?'split':'merge';if(_0x36c3c1['consumable']['test'](_0x2605e0['markerRange'],_0x3ae08f['name']))for(const _0x46f30f of _0x2605e0['markerRange']['getItems']()){if(!_0x46f30f['is']('element','softBreak'))continue;const _0xc41b45=_0x36c3c1['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x3f9017}),_0x10d62e=_0x36c3c1['mapper']['toViewPosition'](this['editor']['model']['createPositionBefore'](_0x46f30f));_0x408f58['data']['isSuggestion']&&_0x36c3c1['writer']['addClass']('ck-suggestion-marker-'+_0x3f9017+'-new',_0xc41b45),this['activeChange']==_0x408f58&&_0x36c3c1['writer']['addClass']('ck-suggestion-marker--active',_0xc41b45),_0x36c3c1['writer']['insert'](_0x10d62e,_0xc41b45),_0x36c3c1['mapper']['bindElementToMarker'](_0xc41b45,_0x2605e0['markerName']);}},{'priority':'high'}),this['editor']['model']['document']['on']('change',()=>{this['editor']['editing']['view']['change'](_0x2fe09f=>{for(const _0x5f30d8 of this['editor']['model']['document']['getRootNames']()){const _0x52bfeb=this['editor']['model']['document']['getRoot'](_0x5f30d8),_0x34be9d=this['editor']['editing']['view']['document']['getRoot'](_0x5f30d8);if(_0x34be9d){const _0x47121d=_0x52bfeb['getAttribute']('revisionHistoryAttachChange');if(_0x2fe09f['removeAttribute']('data-change-id',_0x34be9d),_0x2fe09f['removeClass']('ck-revision-history-root-add',_0x34be9d),_0x2fe09f['removeClass']('ck-revision-history-root-remove',_0x34be9d),_0x2fe09f['removeClass']('ck-revision-history-root--active',_0x34be9d),_0x47121d){const _0x114a95=this['_getChangeFromId'](_0x47121d);if(!_0x114a95)return null;_0x2fe09f['setAttribute']('data-change-id',_0x47121d,_0x34be9d),_0x2fe09f['addClass']('ck-revision-history-root-'+_0x114a95['type'],_0x34be9d),this['activeChange']==_0x114a95&&_0x2fe09f['addClass']('ck-revision-history-root--active',_0x34be9d);}}}});}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'comment','model':_0x474be2=>'revision-comment:'+_0x474be2,'converterPriority':'highest'}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'suggestion','model':_0x5662cc=>'revision-suggestion:'+_0x5662cc,'converterPriority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision-suggestion','view':_0x687ba7=>({'name':'suggestion:'+_0x687ba7,'group':'revision-suggestion'}),'converterPriority':'highest'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision-suggestion','view':_0x2cbcb9=>{const _0x4a08b6=_0x2cbcb9['markerName']['split'](':')[0x1];return'insertion'!=_0x4a08b6&&'deletion'!=_0x4a08b6?null:{'classes':['ck-suggestion-preview-marker','ck-suggestion-preview-marker-'+_0x4a08b6]};}}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:deletion',Q(this['editor'],'merge'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:insertion',Q(this['editor'],'split'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision-suggestion',(_0x4a548a,_0x3a3693,_0x33a9fd)=>{const _0x2294a3=_0x33a9fd['mapper']['markerNameToElements'](_0x3a3693['markerName']);if(_0x2294a3){for(const _0xb42775 of _0x2294a3)_0xb42775['is']('uiElement')&&(_0x33a9fd['mapper']['unbindElementFromMarkerName'](_0xb42775,_0x3a3693['markerName']),_0x33a9fd['writer']['remove'](_0xb42775));}},{'priority':'high'});}['_getChangeFromId'](_0x125e72){return this['_changeIdToChange']['get'](_0x125e72);}['_getViewForChange'](_0x33f6dc){return this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=new z(this['editor']['locale'],_0x33f6dc),this['_changeView'];}['_initInteractions'](){this['editor']['model']['document']['selection']['observeMarkers']('revision'),this['on']('change:activeView',(_0x5b2e13,_0x995d5c,_0x52d2ee,_0x45cd26)=>{_0x45cd26&&this['_balloon']['remove'](_0x45cd26),_0x52d2ee&&(this['_balloon']['add']({'view':_0x52d2ee,'stackId':'revisionHistoryLabel','position':{'target':()=>{const _0x3f2eab=this['editor']['editing'],_0x38c3c8=this['_getChangeFromId'](_0x52d2ee['changeId']);let _0x43329d;if(_0x38c3c8['data']['isOnRoot']){const _0x5216e1=_0x3f2eab['view']['getDomRoot'](_0x38c3c8['rootName']);_0x43329d=Array['from'](_0x5216e1['getClientRects']());}else{const _0x2b433d=this['editor']['model']['markers']['get']('revision:'+_0x52d2ee['changeId']);_0x43329d=Array['from'](_0x3f2eab['mapper']['markerNameToElements'](_0x2b433d['name']))['map'](_0x2d6cc9=>_0x3f2eab['view']['domConverter']['mapViewToDom'](_0x2d6cc9))['map'](_0x1ed1e5=>Array['from'](_0x1ed1e5['getClientRects']()))['flat']();}if(!this['_activeViewTarget'])return _0x43329d[0x0];return _0x43329d['find'](_0x33e716=>_0x33e716['top']-0x3<=this['_activeViewTarget']['y']&&_0x33e716['bottom']+0x3>=this['_activeViewTarget']['y']&&_0x33e716['left']-0x3<=this['_activeViewTarget']['x']&&_0x33e716['right']+0x3>=this['_activeViewTarget']['x'])||_0x43329d[0x0];}}}),this['_balloon']['showStack']('revisionHistoryLabel'));}),this['on']('change:activeChange',(_0x58b1e2,_0x53c76c,_0x1ef3e7,_0x39bb26)=>{this['activeView']=_0x1ef3e7?this['_getViewForChange'](_0x1ef3e7):null,this['editor']['model']['change'](()=>{const _0x1c23f7=this['editor']['editing'];_0x39bb26&&(_0x39bb26['data']['isOnRoot']?_0x1c23f7['view']['change'](_0x2a29fc=>{_0x2a29fc['removeClass']('ck-revision-history-root--active',_0x1c23f7['view']['document']['getRoot'](_0x39bb26['rootName']));}):_0x1c23f7['reconvertMarker']('revision:'+_0x39bb26['id'])),_0x1ef3e7&&(_0x1ef3e7['data']['isOnRoot']?_0x1c23f7['view']['change'](_0x60e129=>{_0x60e129['addClass']('ck-revision-history-root--active',_0x1c23f7['view']['document']['getRoot'](_0x1ef3e7['rootName']));}):_0x1c23f7['reconvertMarker']('revision:'+_0x1ef3e7['id']));});}),this['listenTo'](this['editor']['editing']['view']['document'],'mouseover',(_0x13ed6b,_0x444a2c)=>{if(this['activeChange'])return;const _0x18c8b0=this['_findChangeIdFromDomTarget'](_0x444a2c['target']),_0x25b95c=this['_changeIdToChange']['get'](_0x18c8b0);_0x25b95c?(this['_activeViewTarget']={'x':_0x444a2c['domEvent']['x'],'y':_0x444a2c['domEvent']['y']},this['activeView']=this['_getViewForChange'](_0x25b95c)):(this['_activeViewTarget']=null,this['activeView']=null);}),this['listenTo'](this['editor']['editing']['view']['document'],'mousedown',(_0x235249,_0x4dcc56)=>{const _0x3870b5=this['_findChangeIdFromDomTarget'](_0x4dcc56['target']),_0x41c7d7=this['_changeIdToChange']['get'](_0x3870b5);_0x41c7d7?(this['_activeViewTarget']={'x':_0x4dcc56['domEvent']['x'],'y':_0x4dcc56['domEvent']['y']},_0x41c7d7===this['activeChange']?this['_balloon']['updatePosition']():this['activeChange']=_0x41c7d7):(this['_activeViewTarget']=null,this['activeChange']=null);});}['_findChangeIdFromDomTarget'](_0x4a9738){do{const _0x184ac0=_0x4a9738['getAttribute']('data-change-id');if(_0x184ac0)return _0x184ac0;_0x4a9738=_0x4a9738['parent'];}while(_0x4a9738);return null;}['_cleanMarkers'](){this['editor']['model']['change'](_0x146bb9=>{for(const _0x3e50c6 of this['editor']['model']['markers'])_0x146bb9['removeMarker'](_0x3e50c6);});}}function Q(_0x2e5f05,_0x40fd35){return(_0x17bedc,_0x7d332e,_0x25fa11)=>{if(!_0x25fa11['consumable']['test'](_0x7d332e['markerRange'],_0x17bedc['name']))return;const _0x279e75=_0x7d332e['markerRange']['getWalker'](),_0x548a9d=_0x7d332e['markerRange']['start'],_0x19dd8f=_0x2e5f05['model']['schema'];let _0x3989ad=null,_0x3bbcdb=null,_0x293dd0=!0x1,_0x597acc=!0x1;for(const _0x5ac609 of _0x279e75){const _0x2f1efd=_0x5ac609['item'];_0x293dd0=_0x293dd0||_0x19dd8f['isContent'](_0x2f1efd);const _0xb567ad=_0x25fa11['mapper']['toViewElement'](_0x2f1efd);if(_0xb567ad&&_0xb567ad['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x5ac609['type']&&(_0x19dd8f['isBlock'](_0x2f1efd)&&!_0x19dd8f['isLimit'](_0x2f1efd)&&(_0x2f1efd['nextSibling']||_0x548a9d['isAtEnd']?_0x3989ad&&_0x3989ad['parent']==_0x2f1efd||(_0x3989ad=_0x2f1efd,_0x34a842(_0x5ac609['previousPosition']),_0x597acc=!0x0):_0x3bbcdb=_0x3bbcdb||_0x5ac609['previousPosition']));}function _0x34a842(_0x11f561){const _0x5946c9=_0x25fa11['mapper']['toViewPosition'](_0x11f561),_0x4fca7c=_0x25fa11['writer']['createUIElement']('span',{'class':'ck-suggestion-preview-marker-'+_0x40fd35});_0x25fa11['writer']['insert'](_0x5946c9,_0x4fca7c),_0x25fa11['mapper']['bindElementToMarker'](_0x4fca7c,_0x7d332e['markerName']);}_0x293dd0||_0x597acc||!_0x3bbcdb||_0x34a842(_0x3bbcdb);};}class nt extends _0x3d72a2{constructor(_0x5a41ab){super(_0x5a41ab);const _0xa433a3=_0x5a41ab['plugins']['get'](u);this['affectsData']=!0x1,this['listenTo'](_0xa433a3,'change:isReady',()=>this['refresh']()),this['listenTo'](_0xa433a3,'change:isEnabled',()=>this['refresh']());}['execute'](){const _0x29e43e=this['editor'],_0x1b7521=_0x29e43e['plugins']['get'](u),_0x57269b=_0x1b7521['isReady']?_0x1b7521['diff']['newRevisionId']:null;_0x29e43e['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x57269b);}['refresh'](){const {isReady:_0x563b0b,isEnabled:_0x269b52,repository:_0x55dbd6,diff:_0x5f482e}=this['editor']['plugins']['get'](u),_0x5c81cc=_0x5f482e&&_0x55dbd6['getLaterVisibleRevision'](_0x5f482e['newRevisionId']);this['isEnabled']=_0x563b0b&&_0x269b52&&Boolean(_0x5c81cc);}}class rt extends _0x3d72a2{['_step'];constructor(_0x5c1f6e,{direction:_0x38bdf0}){super(_0x5c1f6e);const _0x332649=_0x5c1f6e['plugins']['get'](u);this['affectsData']=!0x1,this['_step']='forward'===_0x38bdf0?0x1:-0x1,this['listenTo'](_0x332649,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x332649,'change:isEnabled',()=>this['refresh']()),this['listenTo'](_0x332649,'change:activeChange',()=>this['refresh']());}['execute'](){const _0x46376f=this['editor'],_0x6ff4d7=_0x46376f['plugins']['get'](u),{isNavigationMode:_0x529225,currentChangeNumber:_0x5297da}=_0x6ff4d7;let _0x34206e;if(_0x6ff4d7['activeChange']=_0x529225?_0x6ff4d7['diff']['changes']['get'](_0x5297da+this['_step']):_0x6ff4d7['diff']['changes']['first'],_0x6ff4d7['activeChange']['data']['isOnRoot'])_0x34206e=_0x46376f['editing']['view']['getDomRoot'](_0x6ff4d7['activeChange']['rootName']);else{const _0x5dd2c1=_0x46376f['model']['markers']['get']('revision:'+_0x6ff4d7['activeChange']['id']);_0x34206e=_0x51a435(_0x46376f['editing'],_0x5dd2c1);}_0x3e961f({'target':_0x34206e,'viewportOffset':0x28});}['refresh'](){const {isNavigationMode:_0x55b4f4,currentChangeNumber:_0x5116de,numberOfChanges:_0x4d589f,isReady:_0x4697fa,isEnabled:_0xf610f6}=this['editor']['plugins']['get'](u);this['isEnabled']=!!(_0xf610f6&&_0x4697fa&&_0x4d589f)&&(!_0x55b4f4||(0x1===this['_step']?_0x5116de<_0x4d589f-0x1:_0x5116de>0x0));}}class Ri extends _0x1252c{constructor(_0x32c140){super(_0x32c140);const _0x4b77d8=this['bindTemplate'],_0x56f9c2=new _0x3e3281(_0x32c140),_0x429c89=new _0x3e3281(_0x32c140);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',(_0x3d9044,_0x3e3d84)=>_0x3d9044&&_0x3e3d84>0x0),this['bind']('_statusText')['to'](this,'isReady',this,'currentChangeNumber',this,'numberOfChanges',this,'isNavigationMode',(_0x5c2ed8,_0x2f129,_0x5d4445,_0x404019)=>{if(!_0x5c2ed8)return m(_0x32c140,'Loading...');if(!_0x5d4445)return m(_0x32c140,'No\x20changes');const _0xa6b075=m(_0x32c140,'NUMBER_OF_CHANGES',_0x5d4445);return _0x404019?m(_0x32c140,'X_OF_Y_CHANGES',[_0x2f129+0x1,_0x5d4445]):_0xa6b075;}),_0x56f9c2['set']({'label':m(_0x32c140,'Show\x20previous\x20change'),'tooltip':!0x0,'icon':_0x417944}),_0x429c89['set']({'label':m(_0x32c140,'Show\x20next\x20change'),'tooltip':!0x0,'icon':_0x1a66a1}),_0x56f9c2['bind']('isEnabled')['to'](this,'isBackwardNavigationEnabled'),_0x429c89['bind']('isEnabled')['to'](this,'isForwardNavigationEnabled'),_0x56f9c2['on']('execute',()=>this['fire']('execute','backward')),_0x429c89['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',_0x4b77d8['if']('_isStatusLabelVisible','ck-hidden',_0xb4d530=>!_0xb4d530)]},'children':[{'text':_0x4b77d8['to']('isNavigationMode',_0x54ab2c=>_0x54ab2c?m(_0x32c140,'EDIT_X_OF_Y_REVISIONS')+':\x20':m(_0x32c140,'Total')+':\x20')}]},{'text':_0x4b77d8['to']('_statusText')}]},new _0x3401cb(),{'tag':'div','attributes':{'class':['ck-revision-history-ui__changes-navigation__navigation']},'children':[_0x56f9c2,_0x429c89]}]});}}const ge='ck-editor__editable__loading-overlay';class ji extends _0xf4a8c2{static get['pluginName'](){return'RevisionViewerLoadingOverlay';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['show'](){const _0x2ea374=this['editor']['editing']['view'];_0x2ea374['change'](_0x3f7903=>{for(const _0x49789e of _0x2ea374['document']['roots'])_0x3f7903['addClass'](ge,_0x49789e);});}['hide'](){const _0x399ab8=this['editor']['editing']['view'];_0x399ab8['change'](_0x32e0c1=>{for(const _0x5c9576 of _0x399ab8['document']['roots'])_0x32e0c1['removeClass'](ge,_0x5c9576);});}}class v extends _0xf4a8c2{static get['pluginName'](){return'RevisionViewerUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[u,ji];}['init'](){const _0x217ffd=this['editor'],_0x2756b3=_0x217ffd['plugins']['get'](u),_0x41cdc4=_0x217ffd['plugins']['get'](ji);_0x217ffd['ui']['componentFactory']['add']('exitToEditing',_0x2a79c8=>{const _0x274f37=new _0x3e3281(_0x2a79c8);return _0x274f37['set']({'label':m(_0x2a79c8,'Back\x20to\x20editing'),'icon':_0x33482a,'withText':!0x0,'tooltip':!0x0,'class':'ck-revision-history-ui__back-to-editing'}),this['listenTo'](_0x274f37,'execute',()=>{_0x217ffd['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}),_0x274f37;}),_0x217ffd['ui']['componentFactory']['add']('restoreRevision',_0x247f64=>{const _0x243196=new _0x3e3281(_0x247f64);return _0x243196['set']({'label':m(_0x247f64,'Restore\x20this\x20revision'),'withText':!0x0,'tooltip':!0x0}),_0x243196['bind']('isEnabled')['to'](_0x217ffd['commands']['get']('restoreRevision')),this['listenTo'](_0x243196,'execute',()=>_0x217ffd['execute']('restoreRevision')),_0x243196;}),_0x217ffd['ui']['componentFactory']['add']('changesNavigation',_0x2e3200=>{const _0x2e98f8=new Ri(_0x2e3200),_0x665ef=_0x217ffd['commands']['get']('showPreviousChange'),_0x54121b=_0x217ffd['commands']['get']('showNextChange');return _0x2e98f8['bind']('isBackwardNavigationEnabled')['to'](_0x665ef,'isEnabled'),_0x2e98f8['bind']('isForwardNavigationEnabled')['to'](_0x54121b,'isEnabled'),_0x2e98f8['bind']('isReady','currentChangeNumber','numberOfChanges','isNavigationMode')['to'](_0x2756b3),this['listenTo'](_0x2e98f8,'execute',(_0x3e530f,_0x38db91)=>{_0x217ffd['execute']('forward'===_0x38db91?'showNextChange':'showPreviousChange');}),_0x2e98f8;}),_0x41cdc4['show'](),_0x2756b3['on']('change:isReady',(_0xe73706,_0x223f8a,_0x2902f8)=>{_0x2902f8?_0x41cdc4['hide']():_0x41cdc4['show']();});}}class hi extends et{['_resizeObserver']=null;constructor(_0x25d1d6,_0x573959){super(_0x25d1d6,_0x573959);const _0x2654b1=this['bindTemplate'];this['set']({'label':m(_0x25d1d6,'Revision\x20name'),'_tooltipString':''}),this['fieldView']['placeholder']=m(_0x25d1d6,'Enter\x20the\x20revision\x20name'),this['extendTemplate']({'tag':'span','attributes':{'class':['ck-revision-history-sidebar__revision-name'],'data-cke-tooltip-text':_0x2654b1['to']('_tooltipString'),'data-cke-tooltip-position':'s','data-cke-tooltip-class':'ck-tooltip_multi-line'}});}['render'](){super['render'](),this['_resizeObserver']=new ot(this['fieldView']['element'],()=>this['_updateTooltipText']()),this['listenTo'](this['fieldView'],'input',()=>this['_updateTooltipText']());}['destroy'](){super['destroy'](),this['_resizeObserver']&&this['_resizeObserver']['destroy']();}['_updateTooltipText'](){const _0x2bcc4e=this['fieldView']['element'];this['_tooltipString']=_0x2bcc4e['scrollWidth']>_0x2bcc4e['clientWidth']&&_0x2bcc4e['value']||'';}}class ni extends _0x1252c{constructor(_0x244ad6,_0x7710b0,_0x3260e2){super(_0x244ad6);const _0x443273=new _0x5381bd();_0x443273['set']({'content':_0x4185e8,'viewBox':'0\x200\x2011\x2010'});const _0xfc9d8e=['ck','ck-revision-history-sidebar__revision-author'];_0x3260e2&&_0xfc9d8e['push']('ck-revision-history-sidebar__revision-author_creator');const _0x54f378=[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision-author__name'],'title':m(_0x244ad6,_0x3260e2?'Revision\x20creator':'Revision\x20author')},'children':[_0x443273,_0x7710b0['name']]}];this['setTemplate']({'tag':'li','attributes':{'class':_0xfc9d8e},'children':_0x54f378});}}function ai(_0x13601e,_0x1879f0){const _0x131e1c=_0x13601e['bindTemplate'],_0x25a619=_0x13601e['locale'],_0x428f78=_0x537cf1(_0x25a619);_0x428f78['panelPosition']='sw';const _0x94eb80=function(_0x4c7b9a,_0x5c037e){const _0x30a653=function(_0x309e53,_0x70ca65){const _0x1c22ad=_0x309e53['locale'],_0x5c33ae={'Compare\x20against\x20selected':m(_0x1c22ad,'Compare\x20against\x20selected'),'Name\x20this\x20revision':m(_0x1c22ad,'Name\x20this\x20revision'),'Restore\x20this\x20revision':m(_0x1c22ad,'Restore\x20this\x20revision')};return _0x70ca65['map'](_0x40c738=>{const _0x494ed0=_0x5c33ae[_0x40c738['name']];return _0x494ed0&&_0x494ed0!==_0x40c738['name']&&(_0x40c738['name']=_0x494ed0),_0x40c738;});}(_0x4c7b9a,_0x5c037e),_0x4e0952=new _0x4772da();for(const _0x2b09d9 of _0x30a653){const _0x44c3fa={'type':'button','model':new to({'label':_0x2b09d9['name'],'class':_0x2b09d9['class'],'withText':!0x0,'role':'menuitem','_action':_0x2b09d9['action']})};_0x44c3fa['model']['bind']('isEnabled')['to'](_0x4c7b9a,'isActionsDropdownOpen',_0x3dc523=>'function'!=typeof _0x2b09d9['isEnabled']||(!_0x3dc523||_0x2b09d9['isEnabled'](_0x4c7b9a))),_0x4e0952['add'](_0x44c3fa);}return _0x4e0952;}(_0x13601e,_0x1879f0);return _0x13601e['bind']('isActionsDropdownOpen')['to'](_0x428f78,'isOpen'),_0x428f78['buttonView']['set']({'label':m(_0x25a619,'Show\x20more\x20items'),'tooltip':!0x0,'tooltipPosition':'sw','icon':_0x53ced5}),_0x428f78['extendTemplate']({'attributes':{'class':['ck-revision-history-sidebar__revision__actions',_0x131e1c['if']('isActionsDropdownOpen','ck-on')]},'on':{'click':_0x131e1c['to'](_0x13bc5d=>_0x13bc5d['stopPropagation']())}}),_0x428f78['on']('execute',_0x2d0f8b=>{_0x13601e['isReady']&&'function'==typeof _0x2d0f8b['source']['_action']&&_0x2d0f8b['source']['_action'](_0x13601e);}),_0x13fdf3(_0x428f78,_0x94eb80,{'role':'menu'}),_0x428f78['listenTo'](_0x13601e,'change:isActionsDropdownOpen',(_0xb8a733,_0x26d2b1,_0x321b12)=>{if(_0x321b12)for(const _0xeef687 of _0x428f78['listView']['items']){const _0x15659a=_0xeef687['children']['first'],_0x305374=_0x1879f0['find'](_0xf1103a=>_0xf1103a['action']===_0x15659a['_action'])['isVisible'];_0xeef687['isVisible']=void 0x0===_0x305374||_0x305374(_0x13601e);}}),_0x428f78;}class _i extends/* #__PURE__ -- @preserve */
|
|
27
|
+
_0x206b6c(_0x1252c){['id'];['revisionNameView'];['revisionActionsView'];['_revision'];['_requireRevisionName'];constructor(_0x2e837b,_0x4712ab,_0x436ab3,_0x4e99dd){super(_0x2e837b);const _0x4ab14a=this['bindTemplate'],_0x151e2a=function(_0x1fcddb,_0x4c8baf){const _0x2dbae9=Array['from'](_0x4c8baf['authors'])['filter'](_0xe5e018=>_0xe5e018!=_0x4c8baf['creator']);return _0x4c8baf['creator']&&_0x2dbae9['unshift'](_0x4c8baf['creator']),_0x2dbae9['map'](_0x4b5177=>new ni(_0x1fcddb,_0x4b5177,_0x4b5177==_0x4c8baf['creator']));}(_0x2e837b,_0x4712ab);this['id']=_0x4712ab['id'],this['_revision']=_0x4712ab,this['_requireRevisionName']=_0x4e99dd,this['bind']('name','createdAt')['to'](_0x4712ab),this['bind']('_createdAtFormatted')['to'](this,'createdAt',_0xfda68=>{return _0x4bdd7c=_0x2e837b['uiLanguage'],(_0x4f3a8b=_0xfda68)['toLocaleDateString'](_0x4bdd7c,{'month':'long','day':'numeric'})+',\x20'+_0x4f3a8b['toLocaleTimeString'](_0x4bdd7c,{'hour':'numeric','minute':'numeric'});var _0x4bdd7c,_0x4f3a8b;}),this['set']('isSelected',!0x1),this['set']('isHighlighted',!0x1),this['set']('isActionsDropdownOpen',!0x1),this['set']('isReady',!0x1),this['set']('isEnabled',!0x1),this['revisionNameView']=new hi(_0x2e837b,ti),this['revisionNameView']['fieldView']['extendTemplate']({'attributes':{'maxlength':'220'}}),this['revisionNameView']['fieldView']['bind']('value')['to'](this,'name',_0x3ae103=>_0x3ae103||this['_createdAtFormatted']),this['revisionNameView']['bind']('isEnabled')['to'](this,'isSelected',this,'isEnabled',(_0x1e01bb,_0x3ddd9f)=>_0x1e01bb&&_0x3ddd9f),this['revisionActionsView']=_0x436ab3&&_0x436ab3['length']?ai(this,_0x436ab3):'',this['revisionActionsView']&&this['revisionActionsView']['bind']('isEnabled')['to'](this),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision-wrapper',_0x4ab14a['if']('isConfirm','ck-revision-history-sidebar__revision-wrapper_confirmation_visible')]},'children':[{'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision',_0x4ab14a['if']('isEnabled','ck-disabled',_0x3da67f=>!_0x3da67f),_0x4ab14a['if']('isSelected','ck-revision-history-sidebar__revision_selected'),_0x4ab14a['if']('isHighlighted','ck-revision-history-sidebar__revision_highlighted'),_0x4ab14a['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':_0x4ab14a['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':_0x151e2a}]},this['revisionActionsView']],'on':{'click':_0x4ab14a['to'](_0x216b14=>{_0x216b14['srcElement']['closest']('.ck-confirm-view')||this['isReady']&&this['isEnabled']&&this['fire']('select',{'id':this['id']});})}}]});}['render'](){super['render']();const _0x27b00a=this['revisionNameView']['fieldView']['element'];this['listenTo'](_0x27b00a,'change',()=>{this['_requireRevisionName']&&!_0x27b00a['value']||this['fire']('setName',{'id':this['id'],'name':_0x27b00a['value']}),_0x27b00a['value']||(_0x27b00a['value']=this['name']?this['name']:this['_createdAtFormatted']);});}['select'](){this['isSelected']=!0x0;}['deselect'](){this['isSelected']=!0x1;}['highlight'](){this['isHighlighted']=!0x0;}['unhighlight'](){this['isHighlighted']=!0x1;}}function li(_0xbb68ef,_0xac7beb){const _0x4d6983=_0x100c11['fromJSDate'](_0xbb68ef)['setLocale'](_0xac7beb),_0x56becb=_0x100c11['local'](),_0x386263=_0x56becb['minus']({'days':0x1})['startOf']('day');let _0x5a4159,_0x2e04b5;return _0x4d6983['hasSame'](_0x56becb,'day')?(_0x5a4159=_0x4d6983['startOf']('day')['toJSDate'](),_0x2e04b5=_0x4d6983['toRelativeCalendar']()):_0x4d6983['hasSame'](_0x386263,'day')?(_0x5a4159=_0x386263['toJSDate'](),_0x2e04b5=_0x4d6983['toRelativeCalendar']()):_0x4d6983['hasSame'](_0x56becb,'week')?(_0x5a4159=_0x4d6983['startOf']('week')['toJSDate'](),_0x2e04b5=_0x4d6983['weekdayLong']||''):_0x4d6983['hasSame'](_0x56becb,'year')?(_0x5a4159=_0x4d6983['startOf']('month')['toJSDate'](),_0x2e04b5=_0x4d6983['monthLong']||''):(_0x5a4159=_0x4d6983['startOf']('year')['toJSDate'](),_0x2e04b5=String(_0x4d6983['year'])),{'startDate':_0x5a4159,'localizedPeriodName':_0x2e04b5};}class bi extends _0x1252c{['startDate'];['revisionViews'];['_revisionActions'];['_requireRevisionName'];constructor(_0x825b66,_0x27d3a2,_0x3668b7,_0x5baedc){super(_0x825b66);const _0x1d7b64=li(_0x27d3a2,this['locale']['uiLanguage'])['localizedPeriodName'];this['startDate']=_0x27d3a2,this['revisionViews']=this['createCollection'](),this['_revisionActions']=_0x3668b7,this['_requireRevisionName']=_0x5baedc,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':_0x1d7b64}]},{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__time-period__revisions']},'children':this['revisionViews']}]});}['addRevision'](_0x101ca7){const _0x13e79b=new _i(this['locale'],_0x101ca7,this['_revisionActions'],this['_requireRevisionName']);this['revisionViews']['add'](_0x13e79b);}['removeRevision'](_0x296c24){const _0x14acee=this['revisionViews']['find'](_0x25aff3=>_0x25aff3['id']===_0x296c24['id']);this['revisionViews']['remove'](_0x14acee);}}class fi extends _0x1252c{constructor(_0x2bf818){super(_0x2bf818);const _0x32826f=new _0x5381bd();_0x32826f['content']=_0x34181b,this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset_all','ck-revision-history-sidebar__header']},'children':[_0x32826f,{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__header__label']},'children':[m(_0x2bf818,'Revision\x20history')]}]});}}class di extends _0x1252c{['timePeriodViews'];['_revisions'];['_revisionActions'];['_requireRevisionName'];constructor(_0x4465dc,_0x3b3508,_0x30caec,_0x113c8a){super(_0x4465dc);const _0x2d3a7e=this['bindTemplate'];this['timePeriodViews']=this['createCollection'](),this['timePeriodViews']['delegate']('select')['to'](this),this['timePeriodViews']['delegate']('setName')['to'](this),this['_revisions']=_0x3b3508,this['_revisionActions']=_0x30caec,this['_requireRevisionName']=_0x113c8a,this['on']('select',(_0x546716,_0x3aa492)=>{this['fire']('revisionSelected',_0x3aa492);}),this['on']('setName',(_0x1719dc,_0x372573)=>{this['fire']('revisionSetName',_0x372573);}),this['set']('isEnabled',!0x1),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-rounded-corners','ck-revision-history-sidebar']},'children':[new fi(_0x4465dc),{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__timeline',_0x2d3a7e['if']('isEnabled','ck-disabled',_0x41db89=>!_0x41db89)]},'children':this['timePeriodViews']}]});}['render'](){super['render']();for(const _0x102103 of this['_revisions'])this['_addRevision'](_0x102103);this['_revisions']['on']('add',(_0x1baa1d,_0x1db5b7)=>{this['_addRevision'](_0x1db5b7);}),this['_revisions']['on']('remove',(_0x1a8ade,_0x245a7d)=>{this['_removeRevision'](_0x245a7d);});}get['revisionViews'](){return this['timePeriodViews']['map'](_0x13a653=>_0x13a653['revisionViews']['map'](_0x5248df=>_0x5248df))['flat']();}['selectRevision'](_0x54631b){for(const _0x217f2e of this['revisionViews'])_0x54631b&&_0x54631b['id']===_0x217f2e['id']?_0x217f2e['select']():_0x217f2e['deselect']();}['highlightRevisions'](_0x3a6c1d){for(const _0x57360a of this['revisionViews'])_0x3a6c1d['some'](({id:_0x222c1b})=>_0x222c1b===_0x57360a['id'])?_0x57360a['highlight']():_0x57360a['unhighlight']();}['_addRevision'](_0x157ad3){const _0x3cce44=li(_0x157ad3['createdAt'],this['locale']['uiLanguage'])['startDate'];let _0xaeb985=this['timePeriodViews']['get'](0x0);_0xaeb985&&_0xaeb985['startDate']['getTime']()===_0x3cce44['getTime']()||(_0xaeb985=new bi(this['locale'],_0x3cce44,this['_revisionActions'],this['_requireRevisionName']),this['timePeriodViews']['add'](_0xaeb985)),_0xaeb985['addRevision'](_0x157ad3);}['_removeRevision'](_0x341c1f){const _0x3ffdf6=li(_0x341c1f['createdAt'],this['locale']['uiLanguage'])['startDate'];this['_getTimePeriodViewByStartDate'](_0x3ffdf6)['removeRevision'](_0x341c1f);}['_getTimePeriodViewByStartDate'](_0x5a4807){return this['timePeriodViews']['find'](_0x223276=>_0x223276['startDate']['getTime']()===_0x5a4807['getTime']());}}class d extends _0xf4a8c2{['_revisionViewer'];['_revisionsRepository'];['_sidebarView'];static ['defaultRevisionActions']=/* #__PURE__ -- @preserve */
|
|
28
28
|
((()=>['compareAgainstSelected','restoreRevision','nameRevision'])());static ['availableRevisionActions']=/* #__PURE__ -- @preserve */
|
|
29
|
-
|
|
30
|
-
_0x13206d(_0x47e722){['_ui'];get['ui'](){return this['_ui'];}constructor(_0x13cd50,_0x5dbb76){super(_0x5dbb76),this['sourceElement']=_0x13cd50,this['model']['document']['createRoot']();const _0x14c80=new ii(this['locale'],this['editing']['view'],{'shouldToolbarGroupWhenFull':!0x0});this['_ui']=new Z(this,_0x14c80);}['destroy'](){return this['updateSourceElement'](),this['ui']['destroy'](),super['destroy']();}static async['create'](_0x16e0ba,_0xbae37e){const _0x25096e=new this(_0x16e0ba,_0xbae37e);return await _0x25096e['initPlugins'](),await _0x25096e['ui']['init'](_0x16e0ba),await _0x25096e['data']['init'](_0x25096e['config']['get']('initialData')||''),_0x25096e['fire']('ready'),_0x25096e;}}const p=['RevisionHistoryUI','RestrictedEditingMode','AIChat','AIReviewMode','AIBalloon','AIQuickActions','AIActions'];class at extends _0x9e7f10{['result'];static get['pluginName'](){return'RevisionViewerIntegration';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x97a4d2){function _0x52d45e(_0x13c1fb){return _0x13c1fb['map'](_0x4bcd34=>String['fromCharCode'](_0x4bcd34))['join']('');}super(_0x97a4d2),this['result']='end',_0x97a4d2[_0x52d45e([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x52d45e([0x76,0x69,0x65,0x77])][_0x52d45e([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x52d45e([0x61,0x75,0x74,0x6f]),_0x97a4d2[_0x52d45e([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x52d45e([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x52d45e([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x52d45e([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x52d45e([0x6f,0x6b])});}}class ht extends _0x9e7f10{['_viewerEditor'];static get['pluginName'](){return'RevisionHistory';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[h,l];}constructor(_0x58ba15){if(super(_0x58ba15),!this['editor']['config']['get']('revisionHistory'))throw new _0x2c9279('revision-history-missing-configuration',this);this['_viewerEditor']=null,this['set']('isRevisionViewerOpen',!0x1),this['editor']['config']['define']('revisionHistory.showRevisionViewerCallback',_0x5750f6=>this['_showRevisionViewer']({..._0x5750f6,'translations':this['editor']['locale']['translations']})),this['editor']['config']['define']('revisionHistory.closeRevisionViewerCallback',_0xe6a87a=>this['_closeRevisionViewer'](_0xe6a87a)),this['editor']['config']['define']('revisionHistory.restoreRevisionCallback',_0x41bcfc=>this['_restoreRevision'](_0x41bcfc)),this['editor']['config']['define']('revisionHistory.requireRevisionName',!0x1),this['_enhanceShowRevisionViewerCallback'](),this['_enhanceCloseRevisionViewerCallback']();}set['adapter'](_0x3c5dd5){this['editor']['plugins']['get']('RevisionTracker')['adapter']=_0x3c5dd5;}get['adapter'](){return this['editor']['plugins']['get']('RevisionTracker')['adapter'];}['addRevisionData'](_0x49d630){return this['editor']['plugins']['get']('RevisionTracker')['addRevisionData'](_0x49d630);}['getRevision'](_0x19d214){return this['editor']['plugins']['get']('RevisionsRepository')['getRevision'](_0x19d214);}['getRevisions'](_0x199504){return this['editor']['plugins']['get']('RevisionsRepository')['getRevisions'](_0x199504||{'toJSON':!0x1});}['_getRevisionViewerEditorConfig'](){const _0x48db92=this['editor'],_0x4b7a6f=_0x2ee32c(_0x48db92,p),_0x424a10=_0x48db92['plugins']['get']('RevisionTracker'),_0x2a2592=_0x48db92['plugins']['get']('Users')['users'];return _0x4b7a6f['toolbar']=['exitToEditing','restoreRevision','changesNavigation'],delete _0x4b7a6f['lazyRoots'],(_0x4b7a6f['plugins']['push'](at,u,v,class extends _0x9e7f10{static get['requires'](){return[u,'Users'];}['init'](){const _0x27ec58=this['editor']['plugins']['get']('Users');for(const _0xcf73d0 of _0x2a2592)_0xcf73d0['isAnonymous']||_0x27ec58['getUser'](_0xcf73d0['id'])||_0x27ec58['addUser'](_0xcf73d0);const _0x3c6cf7=_0x424a10['repository']['getRevisions']();let _0x5109b8=null;const _0xf0a544=this['editor']['plugins']['get']('RevisionViewer');_0xf0a544['adapter']=_0x424a10['adapter'],_0xf0a544['bind']('isEnabled')['to'](_0x424a10),this['editor']['commands']['get']('restoreRevision')['bind']('isEnabled')['to'](_0x48db92,'isReadOnly',_0x146fe1=>!_0x146fe1);for(const _0x5b04b8 of _0x3c6cf7){const _0x50612c=null===_0x5b04b8['creator'];if(_0x50612c&&_0x5b04b8['toVersion']===_0x5b04b8['fromVersion'])continue;const _0x4e888e=_0x5b04b8['toJSON']();_0xf0a544['addRevisionData'](_0x4e888e,(_0x1b361a,_0x360115,_0x1791fd)=>{if(_0x50612c){if(_0x5109b8)_0x5109b8['_update'](_0x1b361a,_0x360115);else{if(!_0x360115){const _0x3d711b=_0x1791fd['toJSON']();_0x3d711b['id']=_0x6a7f74(),_0x424a10['saveRevision'](_0x3d711b,_0x1791fd['toVersion'])['then'](_0xd83e48=>{_0x5109b8=_0xd83e48;});}}}else _0x5b04b8['_update'](_0x1b361a,_0x360115);});}}},d),_0x4b7a6f);}['_enhanceShowRevisionViewerCallback'](){const _0x168174=this['editor']['config']['get']('revisionHistory')['showRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.showRevisionViewerCallback',async()=>{this['editor']['enableReadOnlyMode']('revision-history-viewer-opened');const _0x31c3a6=this['editor']['plugins']['get']('RevisionTracker');if(this['editor']['plugins']['has']('Autosave')){const _0x1bdfbc=this['editor']['plugins']['get']('Autosave');await _0x1bdfbc['save']();}else await _0x31c3a6['update']();if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('Dialog')){const _0x251edf=this['editor']['plugins']['get']('Dialog');_0x251edf['isOpen']&&_0x251edf['hide']();}if(this['editor']['plugins']['has']('AITabs')){const _0x1f2501=this['editor']['plugins']['get']('AITabs')['view']['panelViews'];for(const _0x172ab2 of _0x1f2501)_0x172ab2['class']=_0x172ab2['class']?_0x172ab2['class']+'\x20ck-tab-panel_disabled':'ck-tab-panel_disabled';if(this['editor']['plugins']['has']('AIChat')){const _0x2b117b=document['querySelector']('.ck-ai-chat__prompt-input\x20.ck-textarea');_0x2b117b&&_0x2b117b['setAttribute']('tabindex','-1');}if(this['editor']['plugins']['has']('AIChatHistory')){const _0x1289d2=document['querySelector']('.ck-ai-chat-history\x20.ck-input');_0x1289d2&&_0x1289d2['setAttribute']('tabindex','-1');}}const _0x4ebeae=this['_getRevisionViewerEditorConfig']();return _0x168174(_0x4ebeae)['then'](_0x5144be=>{return(this['_viewerEditor']=_0x5144be,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'),_0x5144be);})['catch'](_0x3aef89=>(console['error'](_0x3aef89),this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),null));});}['_enhanceCloseRevisionViewerCallback'](){const _0x5a00b1=this['editor']['config']['get']('revisionHistory')['closeRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.closeRevisionViewerCallback',()=>{if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('DocumentOutline')&&(this['editor']['plugins']['get']('DocumentOutlineUI')['view']['element']['style']['display']=''),this['editor']['plugins']['has']('AITabs')){const _0x2159c1=this['editor']['plugins']['get']('AITabs')['view']['panelViews'];for(const _0x15edf1 of _0x2159c1)_0x15edf1['class']='ck-tab-panel_disabled'===_0x15edf1['class']?'':_0x15edf1['class']['replace']('\x20ck-tab-panel_disabled','');if(this['editor']['plugins']['has']('AIChat')){const _0x16fe8f=document['querySelector']('.ck-ai-chat__prompt-input\x20.ck-textarea');_0x16fe8f&&_0x16fe8f['removeAttribute']('tabindex');}if(this['editor']['plugins']['has']('AIChatHistory')){const _0x1c7552=document['querySelector']('.ck-ai-chat-history\x20.ck-input');_0x1c7552&&_0x1c7552['removeAttribute']('tabindex');}}return this['_viewerEditor']['plugins']['get']('RevisionViewer')['_cleanUp'](),_0x5a00b1(this['_viewerEditor'])['then'](()=>{if(this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),this['_viewerEditor']=null,this['editor']['plugins']['has']('Annotations')){const _0x32bad6=this['editor']['plugins']['get']('Annotations');_0x32bad6['refreshVisibility'](),_0x32bad6['refreshPositioning']();}});});}['_showRevisionViewer'](_0x7f4b26){const _0x1c7691=this['editor']['config']['get']('revisionHistory.editorContainer'),_0x4a2b50=this['editor']['config']['get']('revisionHistory.viewerContainer'),_0x310851=this['editor']['config']['get']('revisionHistory.viewerEditorElement');return f['create'](_0x310851,_0x7f4b26)['then'](_0x11991e=>(_0x4a2b50['style']['display']='block',_0x1c7691['style']['display']='none',this['isRevisionViewerOpen']=!0x0,_0x11991e));}['_closeRevisionViewer'](_0x294b91){const _0x2f0bf0=this['editor']['config']['get']('revisionHistory.editorContainer');return this['editor']['config']['get']('revisionHistory.viewerContainer')['style']['display']='none',_0x2f0bf0['style']['display']='',this['isRevisionViewerOpen']=!0x1,_0x294b91['destroy']();}async['_restoreRevision'](_0x517bdd){const _0x41b9d5=this['editor'],_0x26abb6=this['_viewerEditor']['plugins']['get']('RevisionViewer'),_0xbcf7b=_0x41b9d5['plugins']['get']('RevisionTracker'),_0x4d4fc7=_0x41b9d5['plugins']['get']('RevisionHistoryUtils'),_0x3486a4=_0x26abb6['repository']['getRevision'](_0x517bdd);let _0x34b497,_0x6e461f,_0x5b3a7b;try{await _0x4d4fc7['loadRevisionData'](_0x3486a4,this['adapter']),_0x34b497=_0x4d4fc7['getRevisionDocumentData'](_0x3486a4),_0x6e461f=_0x4d4fc7['getRevisionRootsAttributes'](_0x3486a4);}catch(_0x82a4fa){return void console['error'](_0x82a4fa);}_0x41b9d5['model']['change'](_0x1632c6=>{for(const _0x1d44dd of Array['from'](_0x41b9d5['model']['markers']['getMarkersGroup']('restrictedEditingException')))_0x1632c6['removeMarker'](_0x1d44dd);}),_0x26abb6['isReady']=!0x1,_0x41b9d5['model']['enqueueChange'](_0x894152=>{_0x894152['setSelection'](null),_0x894152['removeSelectionAttribute'](_0x41b9d5['model']['document']['selection']['getAttributeKeys']());const _0x146f03=Object['keys'](_0x34b497);for(const _0x2cb076 of _0x41b9d5['model']['document']['roots'])'$graveyard'!=_0x2cb076['rootName']&&_0x2cb076['isAttached']()&&!_0x146f03['includes'](_0x2cb076['rootName'])&&_0x894152['detachRoot'](_0x2cb076);for(const _0x3c665f of _0x146f03){let _0x2b5c44=_0x41b9d5['model']['document']['getRoot'](_0x3c665f);_0x2b5c44&&_0x2b5c44['isAttached']()||(_0x2b5c44=_0x894152['addRoot'](_0x3c665f));const _0xb1c0a3=_0x6e461f[_0x3c665f],_0x1b72ba=Object['keys'](_0xb1c0a3),_0x278940=_0x34b497[_0x3c665f];for(const _0x1c4e98 of _0x2b5c44['getAttributeKeys']())_0x1b72ba['includes'](_0x1c4e98)||_0x894152['removeAttribute'](_0x1c4e98,_0x2b5c44);for(const _0x393201 of _0x1b72ba)_0x894152['setAttribute'](_0x393201,_0x6e461f[_0x3c665f][_0x393201],_0x2b5c44);_0x894152['remove'](_0x894152['createRangeIn'](_0x2b5c44)),_0x894152['insert'](_0x41b9d5['data']['parse'](_0x278940,_0x2b5c44),_0x2b5c44,0x0);}});const _0x5035dd=m(_0x41b9d5['locale'],'Restored');if(_0x3486a4['name'])_0x5b3a7b=-0x1==_0x3486a4['name']['indexOf'](_0x5035dd)?_0x5035dd+':\x20'+_0x3486a4['name']:_0x3486a4['name'];else _0x5b3a7b=_0x5035dd+':\x20'+(_0x3486a4['createdAt']['toLocaleDateString'](_0x41b9d5['locale']['uiLanguage'],{'month':'long','day':'numeric'})+',\x20'+_0x3486a4['createdAt']['toLocaleTimeString'](_0x41b9d5['locale']['uiLanguage'],{'hour':'numeric','minute':'numeric'}));return await _0xbcf7b['saveRevision']({'name':_0x5b3a7b}),_0x26abb6['isReady']=!0x0,_0x41b9d5['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}}export{nt as RestoreRevisionCommand,I as Revision,ht as RevisionHistory,l as RevisionHistoryUI,$ as RevisionHistoryUtils,h as RevisionTracker,u as RevisionViewer,f as RevisionViewerEditor,at as RevisionViewerIntegration,Ri as RevisionViewerLoadingOverlay,v as RevisionViewerUI,S as RevisionsRepository,d as RevisionsSidebar,ot as ShowChangeCommand};
|
|
29
|
+
at();static get['pluginName'](){return'RevisionsSidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[u];}constructor(_0x1c5140){super(_0x1c5140),this['_revisionViewer']=_0x1c5140['plugins']['get'](u),this['_revisionsRepository']=this['_revisionViewer']['repository'],this['_sidebarView']=null;}['init'](){const _0x151ab1=this['_revisionsRepository']['_revisions'],_0x564426=this['_createRevisionActions'](),_0x2fa564=this['editor']['config']['get']('revisionHistory.viewerSidebarContainer');this['_sidebarView']=new di(this['editor']['locale'],_0x151ab1,_0x564426,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',(_0x534987,_0x4c31a8)=>{_0x4c31a8['revisionViews']['on']('add',(_0x46953e,_0x3dd8f2)=>{_0x3dd8f2['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)),_0x2fa564['appendChild'](this['_sidebarView']['element']);}['destroy'](){this['_sidebarView']['element']['remove'](),this['_sidebarView']['destroy']();}['_handleEditorDataReady'](){const _0x2c1a44=this['_revisionsRepository']['getRevision'](0x0);if(_0x2c1a44){const _0x47ec80=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x2c1a44['id']);this['_revisionViewer']['compare'](_0x2c1a44,_0x47ec80);}}['_handleRevisionSelected'](_0x5c4cf7,_0x23dd7b){const _0xbb2ab0=this['_revisionsRepository']['getRevision'](_0x23dd7b['id']),_0x3563b8=this['_revisionsRepository']['getEarlierVisibleRevision'](_0xbb2ab0['id']);this['_revisionViewer']['compare'](_0xbb2ab0,_0x3563b8);}['_handleRevisionSetName'](_0x3ece1f,_0x24c92d){this['_revisionsRepository']['getRevision'](_0x24c92d['id'])['setName'](_0x24c92d['name']);}['_handleDiffChange'](_0x5c6c57,_0x400d41,_0x316670){const _0x452009=this['_revisionsRepository']['getRevisionsInDiff'](_0x316670);_0x452009['length']>0x2?(this['_sidebarView']['highlightRevisions'](_0x452009),this['_sidebarView']['selectRevision'](null)):(this['_sidebarView']['highlightRevisions']([]),this['_sidebarView']['selectRevision'](_0x452009[0x0]));}['_createRevisionActions'](){const _0x41b496=this['editor'],_0x3b9389=d['availableRevisionActions'],_0x1761c0=_0x41b496['config']['get']('revisionHistory.revisionActions')||d['defaultRevisionActions'];if(_0x1761c0['length'])return _0x1761c0['map'](_0x5add35=>{const _0x3071f2='string'==typeof _0x5add35?Object['assign']({},_0x3b9389[_0x5add35]):_0x5add35;return _0x3071f2['action']=_0x3071f2['action']['bind'](this,_0x41b496),_0x3071f2['isVisible']&&(_0x3071f2['isVisible']=_0x3071f2['isVisible']['bind'](this,_0x41b496)),_0x3071f2;});}}function at(){return{'compareAgainstSelected':{'name':'Compare\x20against\x20selected','action':({plugins:_0xaae542},_0x2222d0)=>{const _0x512eb0=_0xaae542['get'](u),_0x54c44f=_0x512eb0['repository'];let _0x163d84=_0x512eb0['diff']['newRevisionId'],_0x38e215=_0x2222d0['id'];_0x54c44f['getIndex'](_0x163d84)>_0x54c44f['getIndex'](_0x38e215)&&([_0x163d84,_0x38e215]=[_0x38e215,_0x163d84]),_0x512eb0['compare'](_0x163d84,_0x38e215);},'isVisible':({plugins:_0x4bc137},_0x1282eb)=>{const _0x2c2667=_0x4bc137['get'](u);return!(_0x2c2667['repository']['getRevisionsInDiff'](_0x2c2667['diff'])['length']>0x2)&&!_0x1282eb['isSelected'];}},'restoreRevision':{'name':'Restore\x20this\x20revision','action':(_0x1461b4,{id:_0xcce213})=>{_0x1461b4['config']['get']('revisionHistory')['restoreRevisionCallback'](_0xcce213);},'isVisible':({plugins:_0x2e46a2},_0x47c2be)=>!!_0x2e46a2['get'](u)['repository']['getLaterVisibleRevision'](_0x47c2be['id'])},'nameRevision':{'name':'Name\x20this\x20revision','action':({plugins:_0x1a80b2},{id:_0x4308b8,revisionNameView:_0x16d873})=>{const _0x295c85=_0x1a80b2['get'](u),_0x1dfc2a=_0x295c85['repository']['getEarlierVisibleRevision'](_0x4308b8);_0x295c85['compare'](_0x4308b8,_0x1dfc2a),_0x16d873['focus'](),_0x16d873['fieldView']['select']();}}};}class Z extends tt{['_view'];['_toolbarConfig'];['_elementReplacer'];get['view'](){return this['_view'];}constructor(_0x44ace4,_0x142322){super(_0x44ace4),this['_view']=_0x142322,this['_toolbarConfig']=st(_0x44ace4['config']['get']('toolbar')),this['_elementReplacer']=new it();}get['element'](){return this['view']['element'];}['init'](_0x52dc77){const _0x42692e=this['editor'],_0x340d6b=this['view'],_0x6b0fdd=_0x42692e['editing']['view'],_0x30f04b=_0x340d6b['editable'],_0x38efe0=_0x6b0fdd['document']['getRoot']();_0x30f04b['name']=_0x38efe0['rootName'],_0x340d6b['render']();const _0x205ac9=_0x30f04b['element'];this['setEditableElement'](_0x30f04b['name'],_0x205ac9),_0x340d6b['editable']['bind']('isFocused')['to'](this['focusTracker']),_0x6b0fdd['attachDomRoot'](_0x205ac9),this['_elementReplacer']['replace'](_0x52dc77,this['element']),this['_initToolbar'](),this['fire']('ready');}['destroy'](){super['destroy']();const _0x401678=this['view'],_0x327beb=this['editor']['editing']['view'];this['_elementReplacer']['restore'](),_0x327beb['detachDomRoot'](_0x401678['editable']['name']),_0x401678['destroy']();}['_initToolbar'](){const _0x3d3018=this['view'];_0x3d3018['stickyPanel']['bind']('isActive')['to'](this['focusTracker'],'isFocused'),_0x3d3018['stickyPanel']['limiterElement']=_0x3d3018['element'],_0x3d3018['stickyPanel']['bind']('viewportTopOffset')['to'](this,'viewportOffset',({top:_0x15ce63})=>_0x15ce63),_0x3d3018['toolbar']['fillFromConfig'](this['_toolbarConfig'],this['componentFactory']),this['addToolbar'](_0x3d3018['toolbar']);}}class ii extends _0x4d5754{['_editable'];['stickyPanel'];['toolbar'];get['editable'](){return this['_editable'];}constructor(_0x686582,_0x1c5290,_0x1bb695={}){super(_0x686582),this['stickyPanel']=new _0x53b49a(_0x686582),this['toolbar']=new _0x423d27(_0x686582,{'shouldGroupWhenFull':_0x1bb695['shouldToolbarGroupWhenFull']}),this['_editable']=new te(_0x686582,_0x1c5290);}['render'](){super['render'](),this['stickyPanel']['content']['add'](this['toolbar']),this['top']['add'](this['stickyPanel']),this['main']['add'](this['editable']);}}class f extends/* #__PURE__ -- @preserve */
|
|
30
|
+
_0x15b0bc(_0x10091e){['_ui'];get['ui'](){return this['_ui'];}constructor(_0x367e13,_0x6f5ad6){super(_0x6f5ad6),this['sourceElement']=_0x367e13,this['model']['document']['createRoot']();const _0x4fb05f=new ii(this['locale'],this['editing']['view'],{'shouldToolbarGroupWhenFull':!0x0});this['_ui']=new Z(this,_0x4fb05f);}['destroy'](){return this['updateSourceElement'](),this['ui']['destroy'](),super['destroy']();}static async['create'](_0x32f6de,_0x447374){const _0x2b281a=new this(_0x32f6de,_0x447374);return await _0x2b281a['initPlugins'](),await _0x2b281a['ui']['init'](_0x32f6de),await _0x2b281a['data']['init'](_0x2b281a['config']['get']('initialData')||''),_0x2b281a['fire']('ready'),_0x2b281a;}}const p=['RevisionHistoryUI','RestrictedEditingMode','AIChat','AIReviewMode','AIBalloon','AIQuickActions','AIActions'];class ht extends _0xf4a8c2{['result'];static get['pluginName'](){return'RevisionViewerIntegration';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x9d4141){function _0x214e68(_0x10285c){return _0x10285c['map'](_0x438247=>String['fromCharCode'](_0x438247))['join']('');}super(_0x9d4141),this['result']='end',_0x9d4141[_0x214e68([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x214e68([0x76,0x69,0x65,0x77])][_0x214e68([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x214e68([0x61,0x75,0x74,0x6f]),_0x9d4141[_0x214e68([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x214e68([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x214e68([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x214e68([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x214e68([0x6f,0x6b])});}}class ct extends _0xf4a8c2{['_viewerEditor'];static get['pluginName'](){return'RevisionHistory';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[h,l];}constructor(_0x1b17d1){if(super(_0x1b17d1),!this['editor']['config']['get']('revisionHistory'))throw new _0x3aa039('revision-history-missing-configuration',this);this['_viewerEditor']=null,this['set']('isRevisionViewerOpen',!0x1),this['editor']['config']['define']('revisionHistory.showRevisionViewerCallback',_0x32fc2c=>this['_showRevisionViewer']({..._0x32fc2c,'translations':this['editor']['locale']['translations']})),this['editor']['config']['define']('revisionHistory.closeRevisionViewerCallback',_0xc38181=>this['_closeRevisionViewer'](_0xc38181)),this['editor']['config']['define']('revisionHistory.restoreRevisionCallback',_0xaa4ec2=>this['_restoreRevision'](_0xaa4ec2)),this['editor']['config']['define']('revisionHistory.requireRevisionName',!0x1),this['_enhanceShowRevisionViewerCallback'](),this['_enhanceCloseRevisionViewerCallback']();}set['adapter'](_0x555f79){this['editor']['plugins']['get']('RevisionTracker')['adapter']=_0x555f79;}get['adapter'](){return this['editor']['plugins']['get']('RevisionTracker')['adapter'];}['addRevisionData'](_0x65125a){return this['editor']['plugins']['get']('RevisionTracker')['addRevisionData'](_0x65125a);}['getRevision'](_0x340bae){return this['editor']['plugins']['get']('RevisionsRepository')['getRevision'](_0x340bae);}['getRevisions'](_0x19d6a0){return this['editor']['plugins']['get']('RevisionsRepository')['getRevisions'](_0x19d6a0||{'toJSON':!0x1});}['_getRevisionViewerEditorConfig'](){const _0x332ef1=this['editor'],_0x37db2a=_0x3f540c(_0x332ef1,p),_0x2a615a=_0x332ef1['plugins']['get']('RevisionTracker'),_0x2308d8=_0x332ef1['plugins']['get']('Users')['users'];return _0x37db2a['toolbar']=['exitToEditing','restoreRevision','changesNavigation'],delete _0x37db2a['lazyRoots'],(_0x37db2a['plugins']['push'](ht,u,v,class extends _0xf4a8c2{static get['requires'](){return[u,'Users'];}['init'](){const _0x20ef4f=this['editor']['plugins']['get']('Users');for(const _0x575bfb of _0x2308d8)_0x575bfb['isAnonymous']||_0x20ef4f['getUser'](_0x575bfb['id'])||_0x20ef4f['addUser'](_0x575bfb);const _0x294841=_0x2a615a['repository']['getRevisions']();let _0x21cb72=null;const _0x62a1e6=this['editor']['plugins']['get']('RevisionViewer');_0x62a1e6['adapter']=_0x2a615a['adapter'],_0x62a1e6['bind']('isEnabled')['to'](_0x2a615a),this['editor']['commands']['get']('restoreRevision')['bind']('isEnabled')['to'](_0x332ef1,'isReadOnly',_0x5c998b=>!_0x5c998b);for(const _0x4a6cbc of _0x294841){const _0x266f81=null===_0x4a6cbc['creator'];if(_0x266f81&&_0x4a6cbc['toVersion']===_0x4a6cbc['fromVersion'])continue;const _0x2a6c9b=_0x4a6cbc['toJSON']();_0x62a1e6['addRevisionData'](_0x2a6c9b,(_0x47df9f,_0x1649a9,_0x469f59)=>{if(_0x266f81){if(_0x21cb72)_0x21cb72['_update'](_0x47df9f,_0x1649a9);else{if(!_0x1649a9){const _0x3d5277=_0x469f59['toJSON']();_0x3d5277['id']=_0x422cf0(),_0x2a615a['saveRevision'](_0x3d5277,_0x469f59['toVersion'])['then'](_0x3517e4=>{_0x21cb72=_0x3517e4;});}}}else _0x4a6cbc['_update'](_0x47df9f,_0x1649a9);});}}},d),_0x37db2a);}['_enhanceShowRevisionViewerCallback'](){const _0x1de7bf=this['editor']['config']['get']('revisionHistory')['showRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.showRevisionViewerCallback',async()=>{this['editor']['enableReadOnlyMode']('revision-history-viewer-opened');const _0x2c3859=this['editor']['plugins']['get']('RevisionTracker');if(this['editor']['plugins']['has']('Autosave')){const _0x112193=this['editor']['plugins']['get']('Autosave');await _0x112193['save']();}else await _0x2c3859['update']();if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('Dialog')){const _0x42fc54=this['editor']['plugins']['get']('Dialog');_0x42fc54['isOpen']&&_0x42fc54['hide']();}if(this['editor']['plugins']['has']('AITabs')){const _0x14dba0=this['editor']['plugins']['get']('AITabs')['view']['panelViews'];for(const _0x175fd0 of _0x14dba0)_0x175fd0['class']=_0x175fd0['class']?_0x175fd0['class']+'\x20ck-tab-panel_disabled':'ck-tab-panel_disabled';if(this['editor']['plugins']['has']('AIChat')){const _0x4b4964=document['querySelector']('.ck-ai-chat__prompt-input\x20.ck-textarea');_0x4b4964&&_0x4b4964['setAttribute']('tabindex','-1');}if(this['editor']['plugins']['has']('AIChatHistory')){const _0x5ec9b2=document['querySelector']('.ck-ai-chat-history\x20.ck-input');_0x5ec9b2&&_0x5ec9b2['setAttribute']('tabindex','-1');}}const _0x5eb53a=this['_getRevisionViewerEditorConfig']();return _0x1de7bf(_0x5eb53a)['then'](_0xdbc3a7=>{return(this['_viewerEditor']=_0xdbc3a7,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'),_0xdbc3a7);})['catch'](_0x11d62c=>(console['error'](_0x11d62c),this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),null));});}['_enhanceCloseRevisionViewerCallback'](){const _0x59374a=this['editor']['config']['get']('revisionHistory')['closeRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.closeRevisionViewerCallback',()=>{if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('DocumentOutline')&&(this['editor']['plugins']['get']('DocumentOutlineUI')['view']['element']['style']['display']=''),this['editor']['plugins']['has']('AITabs')){const _0x54c471=this['editor']['plugins']['get']('AITabs')['view']['panelViews'];for(const _0x4db149 of _0x54c471)_0x4db149['class']='ck-tab-panel_disabled'===_0x4db149['class']?'':_0x4db149['class']['replace']('\x20ck-tab-panel_disabled','');if(this['editor']['plugins']['has']('AIChat')){const _0x4a65f4=document['querySelector']('.ck-ai-chat__prompt-input\x20.ck-textarea');_0x4a65f4&&_0x4a65f4['removeAttribute']('tabindex');}if(this['editor']['plugins']['has']('AIChatHistory')){const _0x126efc=document['querySelector']('.ck-ai-chat-history\x20.ck-input');_0x126efc&&_0x126efc['removeAttribute']('tabindex');}}return this['_viewerEditor']['plugins']['get']('RevisionViewer')['_cleanUp'](),_0x59374a(this['_viewerEditor'])['then'](()=>{if(this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),this['_viewerEditor']=null,this['editor']['plugins']['has']('Annotations')){const _0x6c1c96=this['editor']['plugins']['get']('Annotations');_0x6c1c96['refreshVisibility'](),_0x6c1c96['refreshPositioning']();}});});}['_showRevisionViewer'](_0x4148c3){const _0x4e0847=this['editor']['config']['get']('revisionHistory.editorContainer'),_0x1a9851=this['editor']['config']['get']('revisionHistory.viewerContainer'),_0x32e335=this['editor']['config']['get']('revisionHistory.viewerEditorElement');return f['create'](_0x32e335,_0x4148c3)['then'](_0x461377=>(_0x1a9851['style']['display']='block',_0x4e0847['style']['display']='none',this['isRevisionViewerOpen']=!0x0,_0x461377));}['_closeRevisionViewer'](_0x17a32f){const _0x4e721a=this['editor']['config']['get']('revisionHistory.editorContainer');return this['editor']['config']['get']('revisionHistory.viewerContainer')['style']['display']='none',_0x4e721a['style']['display']='',this['isRevisionViewerOpen']=!0x1,_0x17a32f['destroy']();}async['_restoreRevision'](_0x54f3){const _0x314fe9=this['editor'],_0x82f992=this['_viewerEditor']['plugins']['get']('RevisionViewer'),_0x40257b=_0x314fe9['plugins']['get']('RevisionTracker'),_0x4ed76c=_0x314fe9['plugins']['get']('RevisionHistoryUtils'),_0x260a6f=_0x82f992['repository']['getRevision'](_0x54f3);let _0x3858f0,_0x5201a5,_0xa2614c;try{await _0x4ed76c['loadRevisionData'](_0x260a6f,this['adapter']),_0x3858f0=_0x4ed76c['getRevisionDocumentData'](_0x260a6f),_0x5201a5=_0x4ed76c['getRevisionRootsAttributes'](_0x260a6f);}catch(_0x36b50c){return void console['error'](_0x36b50c);}_0x314fe9['model']['change'](_0x40d2de=>{for(const _0x5a448b of Array['from'](_0x314fe9['model']['markers']['getMarkersGroup']('restrictedEditingException')))_0x40d2de['removeMarker'](_0x5a448b);}),_0x82f992['isReady']=!0x1,_0x314fe9['model']['enqueueChange'](_0x242be9=>{_0x242be9['setSelection'](null),_0x242be9['removeSelectionAttribute'](_0x314fe9['model']['document']['selection']['getAttributeKeys']());const _0x313b69=Object['keys'](_0x3858f0);for(const _0xc5e73b of _0x314fe9['model']['document']['roots'])'$graveyard'!=_0xc5e73b['rootName']&&_0xc5e73b['isAttached']()&&!_0x313b69['includes'](_0xc5e73b['rootName'])&&_0x242be9['detachRoot'](_0xc5e73b);for(const _0xef000c of _0x313b69){let _0x3d370b=_0x314fe9['model']['document']['getRoot'](_0xef000c);_0x3d370b&&_0x3d370b['isAttached']()||(_0x3d370b=_0x242be9['addRoot'](_0xef000c));const _0x55bdcd=_0x5201a5[_0xef000c],_0x3fd45f=Object['keys'](_0x55bdcd),_0x43e89c=_0x3858f0[_0xef000c];for(const _0x1d9d01 of _0x3d370b['getAttributeKeys']())_0x3fd45f['includes'](_0x1d9d01)||_0x242be9['removeAttribute'](_0x1d9d01,_0x3d370b);for(const _0x36f3c9 of _0x3fd45f)_0x242be9['setAttribute'](_0x36f3c9,_0x5201a5[_0xef000c][_0x36f3c9],_0x3d370b);_0x242be9['remove'](_0x242be9['createRangeIn'](_0x3d370b)),_0x242be9['insert'](_0x314fe9['data']['parse'](_0x43e89c,_0x3d370b),_0x3d370b,0x0);}});const _0x6d0581=m(_0x314fe9['locale'],'Restored');if(_0x260a6f['name'])_0xa2614c=-0x1==_0x260a6f['name']['indexOf'](_0x6d0581)?_0x6d0581+':\x20'+_0x260a6f['name']:_0x260a6f['name'];else _0xa2614c=_0x6d0581+':\x20'+(_0x260a6f['createdAt']['toLocaleDateString'](_0x314fe9['locale']['uiLanguage'],{'month':'long','day':'numeric'})+',\x20'+_0x260a6f['createdAt']['toLocaleTimeString'](_0x314fe9['locale']['uiLanguage'],{'hour':'numeric','minute':'numeric'}));return await _0x40257b['saveRevision']({'name':_0xa2614c}),_0x82f992['isReady']=!0x0,_0x314fe9['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}}export{nt as RestoreRevisionCommand,I as Revision,ct as RevisionHistory,l as RevisionHistoryUI,$ as RevisionHistoryUtils,h as RevisionTracker,u as RevisionViewer,f as RevisionViewerEditor,ht as RevisionViewerIntegration,ji as RevisionViewerLoadingOverlay,v as RevisionViewerUI,S as RevisionsRepository,d as RevisionsSidebar,rt as ShowChangeCommand};
|