@ckeditor/ckeditor5-revision-history 0.0.0-nightly-20250326.1 → 0.0.0-nightly-20250326.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/build/revision-history.js +1 -1
- package/dist/index.js +6 -6
- package/package.json +11 -11
- package/src/revisionsrepository.js +1 -1
- package/src/ui/revision/createrevisionactionsdropdown.js +1 -1
- package/src/ui/revision/revisionauthorview.js +1 -1
- package/src/ui/revision/revisionnameview.js +1 -1
- package/src/ui/revision/revisionview.js +2 -2
- package/src/ui/revision/subrevisioncollapserview.js +1 -1
- package/src/ui/revision/subrevisionview.js +1 -1
- package/src/ui/revisionhistory/revisionhistorysaverevisionformview.js +1 -1
- package/src/ui/revisionhistory/revisionhistoryui.js +1 -1
- package/src/ui/revisionssidebar/revisionssidebar.js +1 -1
- package/src/ui/revisionssidebar/revisionssidebarheaderview.js +1 -1
- package/src/ui/revisionssidebar/revisionssidebartimeperiodview.js +1 -1
- package/src/ui/revisionssidebar/revisionssidebarview.js +1 -1
- package/src/ui/revisionssidebar/utils.js +1 -1
- package/src/ui/revisionviewer/changedetailsview.js +1 -1
- package/src/ui/revisionviewer/changesnavigationview.js +1 -1
- package/src/ui/revisionviewer/revisionviewerloadingoverlay.js +1 -1
- package/src/ui/revisionviewer/revisionviewerui.js +1 -1
package/dist/index.js
CHANGED
|
@@ -20,10 +20,10 @@
|
|
|
20
20
|
*
|
|
21
21
|
*
|
|
22
22
|
*/
|
|
23
|
-
import{ObservableMixin as
|
|
24
|
-
_0x20a623(){['id'];['creator'];['authors'];['diffData'];['toVersion'];['fromVersion'];['model'];constructor(_0x3e69fd){super(),this['id']=_0x3e69fd['id']||_0x2b268f(),this['creator']=_0x3e69fd['creator']||null,this['authors']=_0x3e69fd['authors']||[],this['diffData']=_0x3e69fd['diffData']||null,this['toVersion']=_0x3e69fd['toVersion']||0x0,this['fromVersion']=_0x3e69fd['fromVersion']||0x0,this['set']('name',_0x3e69fd['name']||''),this['set']('createdAt',_0x3e69fd['createdAt']||new Date()),this['set']('attributes',_0x3e69fd['attributes']||{});}['setName'](_0x1bb04a){this['_update']({'name':_0x1bb04a});}['setAttribute'](_0x22515b,_0x4399e5){const _0x2d08e1=_0x33af60(this['attributes']);_0x1200d6(_0x2d08e1,_0x22515b,_0x4399e5),this['_update']({'attributes':_0x2d08e1});}['removeAttribute'](_0x278717){const _0x6b137=_0x33af60(this['attributes']);_0x4cd49e(_0x6b137,_0x278717),this['_update']({'attributes':_0x6b137});}['_update'](_0x931bfa,_0x450eec=!0x1){let _0x1894f3=!0x1;const _0x2805cf={'id':this['id']},_0x4b485e=['name','createdAt','diffData','authors','attributes','toVersion','fromVersion','creatorId'];for(const _0x486d3f of _0x4b485e){const _0x16af09=_0x931bfa[_0x486d3f];void 0x0!==_0x16af09&&_0x16af09!==this[_0x486d3f]&&(this[_0x486d3f]=_0x16af09,_0x2805cf[_0x486d3f]=_0x16af09,_0x1894f3=!0x0);}_0x1894f3&&(_0x2805cf['authors']&&(_0x2805cf['authorsIds']=_0x2805cf['authors']['map'](_0x2b4705=>_0x2b4705['id']),delete _0x2805cf['authors']),this['fire']('_update',_0x2805cf,_0x450eec));}['toJSON'](){return{'id':this['id'],'name':this['name'],'creatorId':this['creator']?this['creator']['id']:null,'authorsIds':this['authors']['map'](_0x5c5f44=>_0x5c5f44['id']),'diffData':this['diffData'],'createdAt':this['createdAt'],'attributes':this['attributes'],'fromVersion':this['fromVersion'],'toVersion':this['toVersion']};}}class I extends _0x47e767{['_revisions'];static get['requires'](){return[_0x256dd3];}static get['pluginName'](){return'RevisionsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['length'](){return this['_revisions']['length'];}constructor(_0x4899ed){super(_0x4899ed),this['_revisions']=new _0x9c7c74();}['afterInit'](){!async function(_0xe7cc6b){const _0x30cb1e=_0x29b809([0x79,0x61,0x49,0x69,0x35,0x4c,0x64,0x58,0x37,0x4d,0x72,0x42,0x65,0x76,0x30,0x59,0x63,0x4f,0x33,0x32,0x70,0x71,0x41,0x77,0x47,0x75,0x31,0x6d,0x43,0x6a,0x66,0x39,0x73,0x50,0x4a,0x5a,0x6f,0x45,0x6c,0x74,0x54,0x4e,0x52,0x38,0x62,0x46,0x6e,0x67,0x7a,0x4b,0x34,0x57,0x48,0x55,0x36,0x44,0x78,0x68,0x56,0x6b,0x53,0x51]),_0x19012c=0xeb829,_0x1bf96a=0x7e147cd,_0x1fd40d=0x7e624f5^_0x1bf96a,_0x3df1a9=window[_0x29b809([0x44,0x61,0x74,0x65])][_0x29b809([0x6e,0x6f,0x77])](),_0x30d293=_0xe7cc6b[_0x29b809([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x412b38=new window[(_0x29b809([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x2b2fd1=>{_0x30d293[_0x29b809([0x6f,0x6e,0x63,0x65])](_0x29b809([0x72,0x65,0x61,0x64,0x79]),_0x2b2fd1);}),_0x213de7={[_0x29b809([0x6b,0x74,0x79])]:_0x29b809([0x45,0x43]),[_0x29b809([0x75,0x73,0x65])]:_0x29b809([0x73,0x69,0x67]),[_0x29b809([0x63,0x72,0x76])]:_0x29b809([0x50,0x2d,0x32,0x35,0x36]),[_0x29b809([0x78])]:_0x29b809([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]),[_0x29b809([0x79])]:_0x29b809([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]),[_0x29b809([0x61,0x6c,0x67])]:_0x29b809([0x45,0x53,0x32,0x35,0x36])},_0x174ec1=_0x30d293[_0x29b809([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x29b809([0x67,0x65,0x74])](_0x29b809([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x458e0a(){let _0x123c34,_0x7c500f=null,_0x423f66=null;try{if(_0x174ec1==_0x29b809([0x47,0x50,0x4c]))return _0x29b809([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x123c34=_0x5d34f9(),!_0x123c34)return _0x29b809([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x123c34[_0x29b809([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x423f66=_0x5110e6(_0x123c34[_0x29b809([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x123c34[_0x29b809([0x6a,0x74,0x69])])),await _0x3e6847()?_0x2d0bae()?_0x33aef0()?_0x29b809([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x2e6293()?(_0x123c34[_0x29b809([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x29b809([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x7c500f=_0x1ebd48(_0x29b809([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x123c34[_0x29b809([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x29b809([0x74,0x72,0x69,0x61,0x6c])&&(_0x7c500f=_0x1ebd48(_0x29b809([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),await _0x3391ea()):_0x29b809([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x29b809([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x29b809([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch(_0x43b710){return _0x29b809([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x33aef0(){const _0x55d0db=[_0x29b809([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x29b809([0x74,0x72,0x69,0x61,0x6c])][_0x29b809([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x123c34[_0x29b809([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x3df1a9/0x3e8:0xe10*_0x1fd40d;return _0x123c34[_0x29b809([0x65,0x78,0x70])]<_0x55d0db;}function _0x2d0bae(){const _0xac94b1=_0x123c34[_0x29b809([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0xac94b1)return!0x1;if(_0xac94b1[_0x29b809([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x29b809([0x2a])))return!0x0;if(_0xac94b1[_0x29b809([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x29b809([0x52,0x48])))return!0x0;if(_0xac94b1[_0x29b809([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x29b809([0x52,0x52,0x48]))){if(_0x3f3756())return!0x0;if(_0x3a801e()||_0x4c78bc())return!0x0;}return!0x1;}function _0x2e6293(){const _0x375dc2=_0x123c34[_0x29b809([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x375dc2||0x0==_0x375dc2[_0x29b809([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x5ac722}=new URL(window[_0x29b809([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x375dc2[_0x29b809([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x5ac722))return!0x0;const _0x1b0d4b=_0x5ac722[_0x29b809([0x73,0x70,0x6c,0x69,0x74])](_0x29b809([0x2e]));return _0x375dc2[_0x29b809([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x5e5d5d=>_0x5e5d5d[_0x29b809([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x29b809([0x2a])))[_0x29b809([0x6d,0x61,0x70])](_0x25ce5f=>_0x25ce5f[_0x29b809([0x73,0x70,0x6c,0x69,0x74])](_0x29b809([0x2e])))[_0x29b809([0x73,0x6f,0x6d,0x65])](_0x473fb6=>_0x1b0d4b[_0x29b809([0x65,0x76,0x65,0x72,0x79])]((_0x583ba3,_0x1e76f0)=>_0x473fb6[_0x1e76f0]===_0x583ba3||_0x473fb6[_0x1e76f0]===_0x29b809([0x2a])));}function _0x3391ea(){return _0x7c500f&&_0x423f66?new window[(_0x29b809([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x337139,_0x383411)=>{_0x7c500f[_0x29b809([0x74,0x68,0x65,0x6e])](_0x337139,_0x383411),_0x423f66[_0x29b809([0x74,0x68,0x65,0x6e])](_0x466a53=>{_0x466a53!=_0x29b809([0x56,0x61,0x6c,0x69,0x64])&&_0x337139(_0x466a53);},_0x383411);}):_0x7c500f||_0x423f66||_0x29b809([0x56,0x61,0x6c,0x69,0x64]);}}function _0x5110e6(_0x428e4b,_0x1fb453){return new window[(_0x29b809([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x157c6c=>{if(_0x835cef())return _0x157c6c(_0x29b809([0x56,0x61,0x6c,0x69,0x64]));_0x2b3767(),_0x30d293[_0x29b809([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x29b809([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x5d053f=!0x1;const _0x5cbd24=_0x2b268f();function _0x20e9c5(_0x6ffc54){return!!_0x6ffc54&&(typeof _0x6ffc54===_0x29b809([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x6ffc54===_0x29b809([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x6ffc54[_0x29b809([0x74,0x68,0x65,0x6e])]===_0x29b809([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x6ffc54[_0x29b809([0x63,0x61,0x74,0x63,0x68])]===_0x29b809([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x28b774(_0x141a5f){_0x4beaa2(_0x141a5f)[_0x29b809([0x74,0x68,0x65,0x6e])](_0x56e201=>{if(!_0x56e201||_0x56e201[_0x29b809([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x29b809([0x6f,0x6b]))return _0x29b809([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x31206d(_0x4161d6(_0x5cbd24+_0x1fb453))!=_0x56e201[_0x29b809([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x29b809([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x29b809([0x56,0x61,0x6c,0x69,0x64]);})[_0x29b809([0x74,0x68,0x65,0x6e])](_0x46cce4=>(_0x3df3b3(),_0x46cce4),()=>{const _0x3bf561=_0x29fc59();return null==_0x3bf561?(_0x3df3b3(),_0x29b809([0x56,0x61,0x6c,0x69,0x64])):_0x29b809(_0x3df1a9-_0x3bf561>(0x23edc3cd^_0x1bf96a)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x29b809([0x74,0x68,0x65,0x6e])](_0x157c6c)[_0x29b809([0x63,0x61,0x74,0x63,0x68])](()=>{_0x157c6c(_0x29b809([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x27ad95=0x7d7a94d^_0x1bf96a;function _0x3df3b3(){const _0x4e5ffe=_0x29b809([0x6c,0x6c,0x63,0x74,0x2d])+_0x31206d(_0x4161d6(_0x428e4b)),_0x3e16a1=_0x294dd2(_0x31206d(window[_0x29b809([0x4d,0x61,0x74,0x68])][_0x29b809([0x63,0x65,0x69,0x6c])](_0x3df1a9/_0x27ad95)));window[_0x29b809([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x29b809([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x4e5ffe,_0x3e16a1);}function _0x29fc59(){const _0x34e507=_0x29b809([0x6c,0x6c,0x63,0x74,0x2d])+_0x31206d(_0x4161d6(_0x428e4b)),_0xe93202=window[_0x29b809([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x29b809([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x34e507);return _0xe93202?window[_0x29b809([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x294dd2(_0xe93202),0x10)*_0x27ad95:null;}function _0x4beaa2(_0x221a05){return new window[(_0x29b809([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x20b8d9,_0x20af7b)=>{_0x221a05[_0x29b809([0x74,0x68,0x65,0x6e])](_0x20b8d9,_0x20af7b),window[_0x29b809([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x20af7b,0x7e0930d^_0x1bf96a);});}}_0x30d293[_0x29b809([0x6f,0x6e])](_0x29b809([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x3348b2,_0x195929)=>{if(_0x195929[0x0]!=_0x428e4b)return _0x157c6c(_0x29b809([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x195929[0x1]={..._0x195929[0x1],[_0x29b809([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x5cbd24};},{[_0x29b809([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x29b809([0x68,0x69,0x67,0x68])}),_0x30d293[_0x29b809([0x6f,0x6e])](_0x29b809([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x4b88e7=>{_0x20e9c5(_0x4b88e7[_0x29b809([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x5d053f=!0x0,_0x28b774(_0x4b88e7[_0x29b809([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x29b809([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x29b809([0x6c,0x6f,0x77])}),_0x412b38[_0x29b809([0x74,0x68,0x65,0x6e])](()=>{_0x5d053f||_0x157c6c(_0x29b809([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x835cef(){return _0x30d293[_0x29b809([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x29b809([0x76,0x69,0x65,0x77])][_0x29b809([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x29b809([0x61,0x75,0x74,0x6f]);}function _0x2b3767(){_0x30d293[_0x29b809([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x29b809([0x76,0x69,0x65,0x77])][_0x29b809([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x29b809([0x61,0x75,0x74,0x6f]);}}function _0x1ebd48(_0xbf1385){const _0x4e64e4=[new window[(_0x29b809([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x540307=>setTimeout(_0x540307,0x7e87901^_0x1bf96a)),_0x412b38[_0x29b809([0x74,0x68,0x65,0x6e])](()=>new window[(_0x29b809([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x450e13=>{const _0x1a82d2=0x7e147ca^_0x1bf96a,_0x35668d=_0xe7cc6b[_0x29b809([0x5f,0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x73])];function _0x5de763(){_0x35668d[_0x29b809([0x6c,0x65,0x6e,0x67,0x74,0x68])]>=_0x1a82d2&&_0x450e13();}_0x5de763(),_0x35668d[_0x29b809([0x6f,0x6e])](_0x29b809([0x61,0x64,0x64]),_0x5de763);})),new window[(_0x29b809([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x8002b1=>{function _0x3ea209(){for(const _0x562eb8 in window)if(window[_0x29b809([0x4e,0x75,0x6d,0x62,0x65,0x72])]['isNaN'](window[_0x29b809([0x4e,0x75,0x6d,0x62,0x65,0x72])](_0x562eb8))&&window[_0x562eb8]==_0x19012c)return _0x8002b1();_0x30d293[_0x29b809([0x73,0x74,0x61,0x74,0x65])]!=_0x29b809([0x64,0x65,0x73,0x74,0x72,0x6f,0x79,0x65,0x64])&&window[_0x29b809([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x3ea209,0x7e15445^_0x1bf96a);}_0x4cad9e(_0x29b809([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))&&_0x3ea209();})];return window[_0x29b809([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x29b809([0x72,0x61,0x63,0x65])](_0x4e64e4)[_0x29b809([0x74,0x68,0x65,0x6e])](()=>_0xbf1385);}async function _0x5d5df1(){if(await _0x412b38,_0x4cad9e(_0x29b809([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))){const _0x598456=_0xe7cc6b[_0x29b809([0x67,0x65,0x74,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](0x0),_0x315ca5=_0xe7cc6b[_0x29b809([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])](_0x598456[_0x29b809([0x69,0x64])]),_0x1dfcd2=_0x4d01a5(_0x29b809([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]));return await _0x1dfcd2[_0x29b809([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])](_0x598456['id'],_0x315ca5?_0x315ca5['id']:null,!0x0),_0x1dfcd2[_0x29b809([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x29b809([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x1dfcd2[_0x29b809([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x1dfcd2[_0x29b809([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])]=_0x966b2a,void(_0x1dfcd2[_0x29b809([0x5f,0x67,0x65,0x74,0x44,0x69,0x66,0x66])]=_0x966b2a);}if(_0x4cad9e(_0x29b809([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]))){const _0x214779=_0x4d01a5(_0x29b809([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]));_0x214779[_0x29b809([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x29b809([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x214779[_0x29b809([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x214779[_0x29b809([0x75,0x70,0x64,0x61,0x74,0x65])]=_0x966b2a,_0x214779[_0x29b809([0x73,0x61,0x76,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])]=_0x966b2a;}_0x30d293[_0x29b809([0x6d,0x6f,0x64,0x65,0x6c])][_0x29b809([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x966b2a,_0x30d293[_0x29b809([0x6d,0x6f,0x64,0x65,0x6c])][_0x29b809([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x966b2a,_0x30d293[_0x29b809([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x29b809([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x3f3756(){return _0x4cad9e(_0x29b809([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x4d01a5(_0x29b809([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x29b809([0x73,0x74,0x61,0x74,0x65])]==_0x29b809([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x3a801e(){return _0x4cad9e(_0x29b809([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 _0x4c78bc(){return _0x4cad9e(_0x29b809([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0xd99b26(_0x545664){const _0x504444=_0x51f5f3();_0x30d293[_0x504444]=_0x29b809([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])+_0x545664,_0x545664[_0x29b809([0x65,0x6e,0x64,0x73,0x57,0x69,0x74,0x68])](_0x29b809([0x4c,0x69,0x6d,0x69,0x74]))&&(window[_0x51f5f3()]=_0x19012c),_0x545664!=_0x29b809([0x56,0x61,0x6c,0x69,0x64])&&_0x5d5df1();}function _0x51f5f3(){const _0x22e0d0=window[_0x29b809([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x29b809([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x29b809([0x6e,0x6f,0x77])]())[_0x29b809([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x29b809([0x2e]),'');let _0x18797e=_0x29b809([0x79]);for(let _0xb58238=0x0;_0xb58238<_0x22e0d0[_0x29b809([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0xb58238+=0x2){let _0x2221f2=window[_0x29b809([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x22e0d0[_0x29b809([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0xb58238,_0xb58238+0x2));_0x2221f2>=_0x30cb1e[_0x29b809([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x2221f2-=_0x30cb1e[_0x29b809([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x18797e+=_0x30cb1e[_0x2221f2];}return _0x18797e;}function _0x5d34f9(){const _0x2fd984=_0x174ec1[_0x29b809([0x73,0x70,0x6c,0x69,0x74])](_0x29b809([0x2e]));if(0x3!=_0x2fd984[_0x29b809([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x215d78(_0x2fd984[0x1]);function _0x215d78(_0x31c142){const _0x699186=_0x3ab9f4(_0x31c142);return _0x699186&&_0xfbf74()?_0x699186:null;function _0xfbf74(){const _0x406f34=_0x699186[_0x29b809([0x6a,0x74,0x69])],_0xcfc2ac=window[_0x29b809([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x406f34[_0x29b809([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x406f34[_0x29b809([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x2a981a={..._0x699186,[_0x29b809([0x6a,0x74,0x69])]:_0x406f34[_0x29b809([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x406f34[_0x29b809([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x2a981a[_0x29b809([0x76,0x63])],_0x4161d6(_0x2a981a)==_0xcfc2ac;}}}async function _0x3e6847(){let _0x5608eb=!0x0;try{const _0x327d36=_0x174ec1[_0x29b809([0x73,0x70,0x6c,0x69,0x74])](_0x29b809([0x2e])),[_0x1e8e31,_0xb71447,_0x4813ec]=_0x327d36;return _0x264d3f(_0x1e8e31),await _0x1a29da(_0x1e8e31,_0xb71447,_0x4813ec),_0x5608eb;}catch(_0x491c34){return!0x1;}function _0x264d3f(_0x138c50){const _0x2017d3=_0x3ab9f4(_0x138c50);_0x2017d3&&_0x2017d3[_0x29b809([0x61,0x6c,0x67])]==_0x29b809([0x45,0x53,0x32,0x35,0x36])||(_0x5608eb=!0x1);}async function _0x1a29da(_0x4b789b,_0x4679f5,_0x31a3c2){const _0x5a646d=window[_0x29b809([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x29b809([0x66,0x72,0x6f,0x6d])](_0x1eca9d(_0x31a3c2),_0x2fa12e=>_0x2fa12e[_0x29b809([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x3e4aca=new window[(_0x29b809([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x29b809([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x4b789b+_0x29b809([0x2e])+_0x4679f5),_0x519936=window[_0x29b809([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x29b809([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x519936)return;const _0x855bc4=await _0x519936[_0x29b809([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x29b809([0x6a,0x77,0x6b]),_0x213de7,{[_0x29b809([0x6e,0x61,0x6d,0x65])]:_0x29b809([0x45,0x43,0x44,0x53,0x41]),[_0x29b809([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x29b809([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x29b809([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x519936[_0x29b809([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x29b809([0x6e,0x61,0x6d,0x65])]:_0x29b809([0x45,0x43,0x44,0x53,0x41]),[_0x29b809([0x68,0x61,0x73,0x68])]:{[_0x29b809([0x6e,0x61,0x6d,0x65])]:_0x29b809([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x855bc4,_0x5a646d,_0x3e4aca)||(_0x5608eb=!0x1);}}function _0x3ab9f4(_0xdabdbb){return _0xdabdbb[_0x29b809([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x29b809([0x65,0x79]))?JSON[_0x29b809([0x70,0x61,0x72,0x73,0x65])](_0x1eca9d(_0xdabdbb)):null;}function _0x1eca9d(_0x2ad9ee){return window[_0x29b809([0x61,0x74,0x6f,0x62])](_0x2ad9ee[_0x29b809([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x29b809([0x2b]))[_0x29b809([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x29b809([0x2f])));}function _0x4161d6(_0x285ce4){let _0x10553d=0x1505;function _0x1c0f4e(_0x39b1b1){for(let _0x506203=0x0;_0x506203<_0x39b1b1[_0x29b809([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x506203++){const _0x310d0a=_0x39b1b1[_0x29b809([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x506203);_0x10553d=(_0x10553d<<0x5)+_0x10553d+_0x310d0a,_0x10553d&=_0x10553d;}}function _0x8813c0(_0x235868){Array[_0x29b809([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x235868)?_0x235868[_0x29b809([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x8813c0):_0x235868&&typeof _0x235868==_0x29b809([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x29b809([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x235868)[_0x29b809([0x73,0x6f,0x72,0x74])]()[_0x29b809([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x17cbca,_0x1a40d2])=>{_0x1c0f4e(_0x17cbca),_0x8813c0(_0x1a40d2);}):_0x1c0f4e(window[_0x29b809([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x235868));}return _0x8813c0(_0x285ce4),_0x10553d>>>0x0;}function _0x31206d(_0x14053d){return _0x14053d[_0x29b809([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x29b809([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x29b809([0x30]));}function _0x294dd2(_0x2f06ef){return _0x2f06ef[_0x29b809([0x73,0x70,0x6c,0x69,0x74])]('')[_0x29b809([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x29b809([0x6a,0x6f,0x69,0x6e])]('');}function _0x4cad9e(_0x3e1a73){return _0x30d293[_0x29b809([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x29b809([0x68,0x61,0x73])](_0x3e1a73);}function _0x4d01a5(_0x16c00e){return _0x30d293[_0x29b809([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x29b809([0x67,0x65,0x74])](_0x16c00e);}function _0x966b2a(){}function _0x29b809(_0x2a7fe0){return _0x2a7fe0['map'](_0x25cce9=>String['fromCharCode'](_0x25cce9))['join']('');}_0xd99b26(await _0x458e0a());}(this);}['createRevision'](_0x24247d){const _0x1df011=this['editor']['plugins']['get']('Users');return new h({'id':_0x24247d['id'],'name':_0x24247d['name'],'creator':_0x24247d['creatorId']?_0x1df011['getUser'](_0x24247d['creatorId']):null,'diffData':_0x24247d['diffData']||_0x24247d['data'],'authors':_0x24247d['authorsIds']['map'](_0x51528b=>_0x1df011['getUser'](_0x51528b)),'createdAt':new Date(_0x24247d['createdAt']),'attributes':_0x24247d['attributes'],'fromVersion':_0x24247d['fromVersion'],'toVersion':_0x24247d['toVersion']});}['addRevision'](_0x7cf9ab,_0x54120e=0x0){this['_revisions']['add'](_0x7cf9ab,_0x54120e);}['getRevision'](_0x39f330){return this['_revisions']['get'](_0x39f330);}['getRevisions'](_0x5d851c={'toJSON':!0x1}){const _0x2d01f6=Array['from'](this['_revisions']);return _0x2d01f6['reverse'](),_0x5d851c['toJSON']?_0x2d01f6['map'](_0x44f10d=>_0x44f10d['toJSON']()):_0x2d01f6;}['getIndex'](_0xca25a5){return this['_revisions']['getIndex'](_0xca25a5);}['getEarlierVisibleRevision'](_0x2b6b44){const [,_0x325ad9]=this['getRevisionsIterator'](_0x2b6b44,{'direction':'earlier'});return _0x325ad9;}['getLaterVisibleRevision'](_0x1bb16f){const [,_0x44e83a]=this['getRevisionsIterator'](_0x1bb16f,{'direction':'later'});return _0x44e83a;}['getRevisionsInDiff'](_0x334d42){const _0x4c9aee=[];for(const _0x362a7d of this['getRevisionsIterator'](_0x334d42['newRevisionId']))if(_0x4c9aee['push'](_0x362a7d),_0x362a7d['id']===_0x334d42['oldRevisionId'])break;return _0x4c9aee;}*['getRevisionsIterator'](_0x341a24,{direction:_0x2a6e3d='earlier',filter:_0xe1dd7b=()=>!0x0}={}){const _0x297887='earlier'===_0x2a6e3d?0x1:-0x1;let _0x58732d=this['_revisions']['get'](_0x341a24),_0x18e897=this['getIndex'](_0x58732d);for(yield _0x58732d;_0x58732d;){if(_0x18e897+=_0x297887,_0x58732d=this['getRevision'](_0x18e897),!_0x58732d)return;_0xe1dd7b(_0x58732d)&&(yield _0x58732d);}}}class V extends _0x47e767{static get['pluginName'](){return'RevisionHistoryUtils';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['_viewClassToTypeChar']=new Map([[_0x326d77,'c'],[_0x5ad368,'a'],[_0x1867f7,'e'],[_0x599f9f,'r'],[_0x3c8ee0,'u']]);['_typeCharToViewClass']=new Map([['c',_0x326d77],['a',_0x5ad368],['e',_0x1867f7],['r',_0x599f9f],['u',_0x3c8ee0]]);async['loadRevisionData'](_0x32f4cc,_0x70ee56){if(_0x32f4cc['diffData']||!_0x70ee56)return;const _0x2ec7e0=this['editor']['config']['get']('collaboration.channelId'),_0x2bdf05=await _0x70ee56['getRevision']({'channelId':_0x2ec7e0,'revisionId':_0x32f4cc['id']});_0x32f4cc['diffData']=_0x2bdf05['diffData'];}['getRevisionDocumentData'](_0x1a864e){const _0x43bf26={};for(const _0x286113 in _0x1a864e['diffData']){if(_0x1a864e['diffData'][_0x286113]['attachChange']&&!_0x1a864e['diffData'][_0x286113]['attachChange']['isAttached'])continue;const _0x3dfdc2=this['_removeRevisionMarkers'](JSON['parse'](_0x1a864e['diffData'][_0x286113]['insertions'])),_0x24a356=this['editor']['editing']['view']['document'],_0x337dd0=new _0x5c89a1(_0x24a356,_0x3dfdc2['map'](_0x5a3141=>this['_getViewFromDiffObj'](_0x5a3141,!0x1)));this['editor']['data']['processor']['useFillerType']('marked'),_0x43bf26[_0x286113]=this['editor']['data']['processor']['toData'](_0x337dd0),this['editor']['data']['processor']['useFillerType']('default');}return _0x43bf26;}['getRevisionRootsAttributes'](_0x38f612){const _0x5cf4ea={};for(const _0x1c5f82 in _0x38f612['diffData'])_0x38f612['diffData'][_0x1c5f82]['attachChange']&&!_0x38f612['diffData'][_0x1c5f82]['attachChange']['isAttached']||(_0x5cf4ea[_0x1c5f82]=_0x38f612['diffData'][_0x1c5f82]['attributesAfter']||{});return _0x5cf4ea;}['_getTypeCharForViewElement'](_0x5e1fc9){return this['_viewClassToTypeChar']['get'](_0x5e1fc9['constructor']);}['_getViewFromDiffObj'](_0xf2ecc5,_0xa37849){const _0x1a6d18=this['editor']['editing']['view']['document'];if('string'==typeof _0xf2ecc5)return new _0x4661ee(_0x1a6d18,_0xf2ecc5);{let _0x38dfa9,_0xefc015;_0xefc015='u'==_0xf2ecc5['type']||'r'==_0xf2ecc5['type']?[]:_0xf2ecc5['children']['map'](_0x24c461=>this['_getViewFromDiffObj'](_0x24c461,_0xa37849));const _0x5138df=this['_typeCharToViewClass']['get'](_0xf2ecc5['type'])||_0x4fde63,_0x5eeac4=this['editor']['data']['htmlProcessor']['domConverter'];if(_0x38dfa9=new _0x5138df(_0x1a6d18,_0xf2ecc5['name'],_0xf2ecc5['attributes'],_0xefc015),'u'==_0xf2ecc5['type']){const _0x551ac3=_0xf2ecc5['children'][0x0];if(_0x38dfa9['render']=function(_0x8e4adb){const _0x24ae10=_0x8e4adb['createElement']('div');return _0x24ae10['innerHTML']=_0x551ac3,_0x24ae10['childNodes'][0x0];},_0xa37849){const _0x120894=new _0x5c89a1(_0x1a6d18);_0x120894['_appendChild'](_0x38dfa9);const _0x337e2d=Array['from'](_0x5eeac4['viewChildrenToDom'](_0x120894,{'bind':!0x1})),_0x3c77c5=_0x5eeac4['domDocument']['createElement']('div');_0x3c77c5['append'](..._0x337e2d),_0x38dfa9=Array['from'](_0x5eeac4['domChildrenToView'](_0x3c77c5))[0x0];}}else{if('r'==_0xf2ecc5['type']){const _0x2db81c=_0xf2ecc5['children'][0x0];if(_0x38dfa9['render']=function(_0xf4326c){_0xf4326c['innerHTML']=_0x2db81c;},_0xa37849){const _0x3fc43=new _0x5c89a1(_0x1a6d18);_0x3fc43['_appendChild'](_0x38dfa9);const _0x1dfc44=Array['from'](_0x5eeac4['viewChildrenToDom'](_0x3fc43,{'bind':!0x1})),_0x4ff7b1=_0x5eeac4['domDocument']['createElement']('div');_0x4ff7b1['append'](..._0x1dfc44);const _0x1191b3=Array['from'](_0x5eeac4['domChildrenToView'](_0x4ff7b1));_0x1191b3['length']>0x1?_0x38dfa9['_appendChild'](_0x1191b3):_0x38dfa9=_0x1191b3[0x0];}}}if(_0xf2ecc5['customProperties']){for(const [_0x277703,_0x40beb3]of _0xf2ecc5['customProperties'])_0x38dfa9['_setCustomProperty'](_0x277703,_0x40beb3);}const _0x47e844=_0xf2ecc5['fillerOffset']||null;return _0x38dfa9['getFillerOffset']=()=>_0x47e844,_0x38dfa9;}}['_makeModelFromViewString'](_0x2c8749){const _0x209077=JSON['parse'](_0x2c8749),_0x2ec9af=this['editor']['editing']['view']['document'],_0x1f974d=new _0x5c89a1(_0x2ec9af,_0x209077['map'](_0x7d56c1=>this['_getViewFromDiffObj'](_0x7d56c1,!0x0)));return this['editor']['data']['toModel'](_0x1f974d);}['_removeRevisionMarkers'](_0x3a362e){return(_0x3a362e=_0x3a362e['filter'](_0x4f499f=>!_0x4f499f['name']||'revision-start'!==_0x4f499f['name']&&'revision-end'!==_0x4f499f['name']))['forEach'](_0xa3d710=>{'string'!=typeof _0xa3d710&&(_0xa3d710['children']=this['_removeRevisionMarkers'](_0xa3d710['children']),_0xa3d710['attributes']=_0xa3d710['attributes']['filter'](_0xa79ab0=>!_0xa79ab0[0x0]['startsWith']('data-revision-')));}),_0x3a362e;}}function g(_0x874c7a,_0x2c8199,_0x429e74){const t=_0x874c7a['t'];switch(_0x2c8199){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'},_0x429e74);case'X_OF_Y_CHANGES':return t({'string':'%0\x20of\x20%1','id':'X_OF_Y_CHANGES'},_0x429e74);case'Show\x20previous\x20change':return t('Show\x20previous\x20change');case'Show\x20next\x20change':return t('Show\x20next\x20change');case'EDIT_X_OF_Y_REVISIONS':return t({'string':'Edit','id':'EDIT_X_OF_Y_REVISIONS'});case'Total':return t('Total');case'Revision\x20creator':return t('Revision\x20creator');case'Revision\x20author':return t('Revision\x20author');case'Revision\x20name':return t('Revision\x20name');case'Save\x20current\x20revision':return t('Save\x20current\x20revision');case'Accept':return t('Accept');case'Save':return t('Save');case'Cancel':return t('Cancel');case'Name\x20of\x20the\x20revision':return t('Name\x20of\x20the\x20revision');case'optional':return t('optional');case'PENDING_ACTION_REVISION_HISTORY':return t({'string':'Unsaved\x20change\x20in\x20revision\x20history.','id':'PENDING_ACTION_REVISION_HISTORY'});case'The\x20revision\x20name\x20cannot\x20be\x20empty.':return t('The\x20revision\x20name\x20cannot\x20be\x20empty.');case'Enter\x20the\x20revision\x20name':return t('Enter\x20the\x20revision\x20name');default:return'';}}class u extends _0x47e767{['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[_0x256dd3,I,V,_0x426b0f];}constructor(_0x240dd5){super(_0x240dd5),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 _0x29fea3=_0x2b268f();this['_source']={'history':this['editor']['model']['document']['history'],'getLatestVersion':()=>Promise['resolve'](this['editor']['model']['document']['version']),'getCurrentRevisionId':()=>_0x29fea3},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 _0xf4bd34=this['repository']['getRevision'](0x0),_0x18aea8=_0xf4bd34&&null===_0xf4bd34['creator']?_0xf4bd34:null;if(this['_continueCurrentRevision']=!!_0x18aea8&&this['editor']['config']['get']('revisionHistory.resumeUnsavedRevision'),this['editor']['plugins']['has']('RealTimeCollaborationClient')){const _0x5905fc=this['_source']['getCurrentRevisionId'](),_0x5e739d=this['repository']['getRevision'](_0x5905fc);if(_0x5e739d)this['_startingVersion']=_0x5e739d['fromVersion'],this['_continueCurrentRevision']=!0x1;else{const _0x35a8c6=this['_source']['history']['_operations']['find'](_0x24eb02=>!_0x24eb02['_isInit']),_0x4e5d93=_0x35a8c6?_0x35a8c6['baseVersion']:this['_source']['history']['version'];_0xf4bd34?(_0xf4bd34['toVersion']<_0x4e5d93&&_0xf4bd34['_update']({'toVersion':_0x4e5d93}),this['_continueCurrentRevision']?(this['_source']['getCurrentRevisionId']=()=>_0x18aea8['id'],this['_startingVersion']=_0x18aea8['fromVersion']):(this['_startingVersion']=_0xf4bd34['toVersion'],this['_continueCurrentRevision']=!0x1)):(this['_startingVersion']=_0x4e5d93,this['_continueCurrentRevision']=!0x1);}}else _0x18aea8&&(this['editor']['model']['document']['history']['version']=Math['max'](_0x18aea8['toVersion'],this['editor']['model']['document']['history']['version']),_0x18aea8['fromVersion']===_0x18aea8['toVersion']?(0x0!==_0x18aea8['fromVersion']&&(this['_source']['getCurrentRevisionId']=()=>_0x18aea8['id']),this['_continueCurrentRevision']=!0x1):this['_continueCurrentRevision']&&(this['_source']['getCurrentRevisionId']=()=>_0x18aea8['id'],this['_startingVersion']=_0x18aea8['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',_0x13c529=>!_0x13c529),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x49e040=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x5a4e2e;for(const _0x46364e in _0x49e040){const _0x2a8ba5=_0x46364e,_0x1cd723=_0x49e040[_0x2a8ba5];if('revisionHistoryLicenseKeyValid'==_0x1cd723||'revisionHistoryLicenseKeyInvalid'==_0x1cd723||'revisionHistoryLicenseKeyExpired'==_0x1cd723||'revisionHistoryLicenseKeyDomainLimit'==_0x1cd723||'revisionHistoryLicenseKeyNotAllowed'==_0x1cd723||'revisionHistoryLicenseKeyEvaluationLimit'==_0x1cd723||'revisionHistoryLicenseKeyTrialLimit'==_0x1cd723||'revisionHistoryLicenseKeyUsageLimit'==_0x1cd723){delete _0x49e040[_0x2a8ba5],_0x5a4e2e=_0x1cd723,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'revisionHistoryLicenseKeyInvalid'==_0x5a4e2e&&_0x49e040['_showLicenseError']('invalid'),'revisionHistoryLicenseKeyExpired'==_0x5a4e2e&&_0x49e040['_showLicenseError']('expired'),'revisionHistoryLicenseKeyDomainLimit'==_0x5a4e2e&&_0x49e040['_showLicenseError']('domainLimit'),'revisionHistoryLicenseKeyNotAllowed'==_0x5a4e2e&&_0x49e040['_showLicenseError']('featureNotAllowed','RevisionHistory'),'revisionHistoryLicenseKeyEvaluationLimit'==_0x5a4e2e&&_0x49e040['_showLicenseError']('evaluationLimit'),'revisionHistoryLicenseKeyTrialLimit'==_0x5a4e2e&&_0x49e040['_showLicenseError']('trialLimit'),'revisionHistoryLicenseKeyUsageLimit'==_0x5a4e2e&&_0x49e040['_showLicenseError']('usageLimit');},0x3e8);}async['afterInit'](){if(this['repository']['length']>0x0){const _0x5afdb9=this['repository']['getRevision'](0x0),_0x24d6dd=await this['getRevisionDocumentData'](_0x5afdb9),_0x2c4e0a=await this['getRevisionRootsAttributes'](_0x5afdb9);this['_replaceEditorDataWithRevisionData'](_0x24d6dd,_0x2c4e0a);}}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['setSource'](_0x3cffbd){this['_source']=_0x3cffbd;}async['update'](){const _0x2e54a2=await this['_source']['getLatestVersion']();if(_0x2e54a2>this['currentRevision']['toVersion']){await this['_loadState']();const _0x2c81c9=this['buildRevisionData']({'revision':this['currentRevision'],'to':_0x2e54a2});_0x2c81c9['authors']=_0x2c81c9['authorsIds']['map'](_0x426b1a=>this['editor']['plugins']['get']('Users')['getUser'](_0x426b1a)),this['currentRevision']['_update'](_0x2c81c9);}}async['saveRevision'](_0x64dfa8={},_0xec045c=null){const _0x373734=[];await this['_loadState'](),this['_continueCurrentRevision']=!0x1,_0xec045c>this['currentRevision']['toVersion']&&(_0xec045c=null),null===_0xec045c&&(_0xec045c=await this['_source']['getLatestVersion']());const _0x1718ff=this['_getFromVersion'](_0xec045c),_0x30a4ba=this['buildRevisionData']({'from':_0x1718ff,'to':_0xec045c});if(this['currentRevision']['toVersion']<_0xec045c){const _0x3022de=this['buildRevisionData']({'revision':this['currentRevision'],'from':_0xec045c,'to':_0xec045c});_0x3022de['authors']=[],_0x3022de['authorsIds']=[],_0x3022de['id']=this['currentRevision']['id'],this['currentRevision']['_update'](_0x3022de,!0x0),delete _0x3022de['authors'],_0x373734['push'](_0x3022de);}_0x64dfa8['creatorId']=this['editor']['plugins']['get']('Users')['me']['id'],_0x64dfa8['name']=_0x64dfa8['name']||null,_0x64dfa8['id']=_0x64dfa8['id']||_0x2b268f(),_0x64dfa8={..._0x64dfa8,..._0x30a4ba};const _0x27d149=this['addRevisionData'](_0x64dfa8);_0x373734['push'](_0x64dfa8);const _0x653792=this['repository']['getIndex'](_0x27d149);if(0x0!==_0x653792){const _0x5ec71c=this['repository']['getRevision'](_0x653792-0x1);if(_0x5ec71c['fromVersion']!==_0xec045c){const _0x31d1e2=this['_revisionDataBuilder']['getData'](_0xec045c,_0x5ec71c['toVersion']),_0x1404d2={'id':_0x5ec71c['id'],'diffData':_0x31d1e2['diffData'],'authorsIds':_0x31d1e2['authorsIds'],'authors':_0x31d1e2['authorsIds']['map'](_0x9cfed8=>this['editor']['plugins']['get']('Users')['getUser'](_0x9cfed8)),'fromVersion':_0xec045c};_0x5ec71c===this['currentRevision']&&(_0x1404d2['createdAt']=new Date(_0x64dfa8['createdAt']['getTime']()+0xa)),_0x5ec71c['_update'](_0x1404d2,!0x0),delete _0x1404d2['authors'],_0x373734['push'](_0x1404d2);}}if(this['adapter']){for(const _0x2b433c of _0x373734)this['_bufferUpdate'](_0x2b433c['id'],_0x2b433c,!0x0);this['sendBufferedUpdates']();}return _0x27d149;}['addRevisionData'](_0x5d1047){const _0x38ff7c=this['repository']['createRevision'](_0x5d1047);return this['adapter']&&_0x38ff7c['on']('_update',(_0x1f536a,_0x5c3f9f,_0x1f8a21)=>{_0x1f8a21||(this['_bufferUpdate'](_0x5c3f9f['id'],_0x5c3f9f,!0x0),this['sendBufferedUpdates']());}),this['repository']['addRevision'](_0x38ff7c,this['_findInsertionIndex'](_0x38ff7c)),_0x38ff7c;}async['getRevisionDocumentData'](_0x3d248c){return await this['_utils']['loadRevisionData'](_0x3d248c,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x3d248c);}async['getRevisionRootsAttributes'](_0x1f2136){return await this['_utils']['loadRevisionData'](_0x1f2136,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x1f2136);}['sendBufferedUpdates'](){if(0x0===this['_bufferedUpdates']['size'])return;if(this['_isPendingUpdate'])return;let _0x42d52e=Array['from'](this['_bufferedUpdates']['values']());this['_bufferedUpdates']['clear']();for(let _0x1521f7=0x0;_0x1521f7<_0x42d52e['length'];_0x1521f7++){const _0x38074c=_0x42d52e[_0x1521f7];let _0xac2bf4=!0x1;for(const _0x4c93ca of Object['keys'](_0x38074c))void 0x0===_0x38074c[_0x4c93ca]?delete _0x38074c[_0x4c93ca]:'id'!==_0x4c93ca&&(_0xac2bf4=!0x0);_0xac2bf4||(_0x42d52e[_0x1521f7]=null);}if(_0x42d52e=_0x42d52e['filter'](_0x3f0b94=>null!==_0x3f0b94),!_0x42d52e['length'])return;for(let _0x226bad=0x0;_0x226bad<_0x42d52e['length'];_0x226bad++){const _0x1d92bb=_0x42d52e[_0x226bad];void 0x0!==_0x1d92bb['fromVersion']&&void 0x0===_0x1d92bb['toVersion']&&(_0x1d92bb['toVersion']=this['repository']['getRevision'](_0x1d92bb['id'])['toVersion']),void 0x0!==_0x1d92bb['toVersion']&&void 0x0===_0x1d92bb['fromVersion']&&(_0x1d92bb['fromVersion']=this['repository']['getRevision'](_0x1d92bb['id'])['fromVersion']);}const _0x30006f=this['editor']['config']['get']('collaboration.channelId');this['_isPendingUpdate']=!0x0,this['_addPendingAction'](),this['adapter']['updateRevisions'](_0x42d52e,_0x30006f)['finally'](()=>{this['_isPendingUpdate']=!0x1;})['then'](_0x3d4cff=>{if(_0x3d4cff){for(const _0x32ebc9 of _0x3d4cff)this['setRevisionData']({'id':_0x32ebc9['id'],'createdAt':_0x32ebc9['createdAt']});}this['_removePendingAction'](),this['sendBufferedUpdates']();});}['buildRevisionData']({revision:_0x961944=null,from:_0x561c6e=null,to:_0x5b784f=null}){_0x561c6e=null!==_0x561c6e?_0x561c6e:_0x961944['fromVersion'],_0x5b784f=null!==_0x5b784f?_0x5b784f:_0x961944['toVersion'];const _0x29c7ee=this['_revisionDataBuilder']['getData'](_0x561c6e,_0x5b784f),_0x37f938={'diffData':_0x29c7ee['diffData'],'authorsIds':_0x29c7ee['authorsIds'],'fromVersion':_0x561c6e,'toVersion':_0x5b784f};if(!_0x961944||_0x5b784f!==_0x961944['toVersion']){const _0x4bf3a4=_0x5b784f-0x1,_0x2c5f85=this['_source']['history']['getOperation'](_0x4bf3a4);_0x37f938['createdAt']=_0x2c5f85&&_0x2c5f85['createdAt']||new Date();}if(this['_loadedStateData']&&_0x561c6e===this['_loadedStateData']['fromVersion']){for(const _0xad2d30 of this['_loadedStateData']['authors'])_0x37f938['authorsIds']['includes'](_0xad2d30['id'])||_0x37f938['authorsIds']['push'](_0xad2d30['id']);}return _0x37f938;}['_bufferUpdate'](_0x17ef49,_0x4c701d,_0x90324a){if(this['_bufferedUpdates']['has'](_0x17ef49)){const _0x350ff2=this['_bufferedUpdates']['get'](_0x17ef49);_0x4c701d=_0x90324a?{..._0x350ff2,..._0x4c701d}:{..._0x4c701d,..._0x350ff2};}this['_bufferedUpdates']['set'](_0x17ef49,_0x4c701d);}['setRevisionData'](_0x49d8bb){const _0x3b9f6a=this['repository']['getRevision'](_0x49d8bb['id']);if(_0x49d8bb['createdAt']&&(_0x49d8bb['createdAt']=new Date(_0x49d8bb['createdAt'])),_0x49d8bb['authorsIds']){const _0x2eaa12=this['editor']['plugins']['get']('Users');_0x49d8bb['authors']=_0x49d8bb['authorsIds']['map'](_0x4da740=>_0x2eaa12['getUser'](_0x4da740));}_0x3b9f6a['_update'](_0x49d8bb,!0x0);}['_createInitialRevision'](_0x452257){const _0x5dae28=this['repository']['getRevision'](this['repository']['length']-0x1);if(_0x5dae28)this['_initialRevisionId']=_0x5dae28['id'];else{const _0x1545d4=!this['editor']['model']['document']['roots']['find'](_0x833847=>this['editor']['model']['hasContent'](_0x833847)),_0x30671d=this['editor']['plugins']['get']('Users')['me']['id'],_0x42a5b1=g(this['editor']['locale'],_0x1545d4?'Empty\x20document':'Initial\x20revision');this['_makeRevision']({'from':_0x452257,'to':_0x452257,'id':this['_initialRevisionId'],'name':_0x42a5b1,'creatorId':_0x30671d});}}['_createCurrentRevision'](_0x4cdf12){const _0x3987dc=this['_source']['getCurrentRevisionId']();this['currentRevision']=this['repository']['getRevision'](_0x3987dc),this['currentRevision']||(this['currentRevision']=this['_makeRevision']({'from':_0x4cdf12,'to':_0x4cdf12,'id':_0x3987dc,'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'](_0x28735e,_0x5983f5){let _0x3d60ad=this['editor']['config']['get']('initialData'),_0x1b6a92=this['editor']['config']['get']('rootsAttributes');if(void 0x0===_0x3d60ad){_0x3d60ad={};for(const _0x48b3fc of this['editor']['model']['document']['getRootNames']())_0x3d60ad[_0x48b3fc]='';}if('string'==typeof _0x3d60ad&&(_0x3d60ad={'main':_0x3d60ad}),void 0x0===_0x1b6a92){_0x1b6a92={};for(const _0x35b772 of this['editor']['model']['document']['getRootNames']())_0x1b6a92[_0x35b772]={};}let _0x356280=!0x1;const _0x2a37e0=Object['keys'](_0x3d60ad),_0x5f114e=Object['keys'](_0x28735e);for(const _0x162cbd of _0x2a37e0){if(_0x3d60ad[_0x162cbd]!==_0x28735e[_0x162cbd]&&''!==_0x3d60ad[_0x162cbd]['trim']()){_0x356280=!0x0;break;}if(!_0x161578(_0x1b6a92[_0x162cbd],_0x5983f5[_0x162cbd])&&Object['keys'](_0x1b6a92[_0x162cbd])['length']>0x0){_0x356280=!0x0;break;}}_0x356280||(_0x356280=_0x5f114e['some'](_0x336770=>!this['editor']['model']['document']['getRoot'](_0x336770))),_0x356280&&_0x2a30e3('editor-initial-data-replaced-with-revision-data',{'editorData':_0x3d60ad,'editorRootsAttributes':_0x1b6a92,'revisionData':_0x28735e,'revisionRootsAttributes':_0x5983f5}),this['editor']['config']['set']('initialData',_0x28735e),this['editor']['config']['set']('rootsAttributes',_0x5983f5);}['_addPendingAction'](){if(!this['_pendingAction']){const _0x24573e=this['editor']['plugins']['get']('PendingActions');this['_pendingAction']=_0x24573e['add'](g(this['editor']['locale'],'PENDING_ACTION_REVISION_HISTORY'));}}['_removePendingAction'](){this['_pendingAction']&&(this['editor']['plugins']['get']('PendingActions')['remove'](this['_pendingAction']),this['_pendingAction']=null);}['_findInsertionIndex'](_0x16c55a){const _0x4d933f=this['repository']['getRevisions']();_0x4d933f['reverse']();let _0x31e4a4=0x0;for(;_0x31e4a4<_0x4d933f['length'];){const _0xb9b3a1=_0x4d933f[_0x31e4a4];if(_0xb9b3a1===this['currentRevision']){_0x31e4a4++;continue;}if(_0xb9b3a1['id']===this['_initialRevisionId'])break;const _0x125df0=_0x16c55a['toVersion']-_0xb9b3a1['toVersion']||_0x16c55a['fromVersion']-_0xb9b3a1['fromVersion'];if(_0x125df0>0x0)break;if(_0x125df0<0x0)_0x31e4a4++;else{if(!_0x16c55a['creator']&&_0xb9b3a1['creator'])break;if(_0xb9b3a1['creator']||!_0x16c55a['creator']){if(_0x16c55a['createdAt']>_0xb9b3a1['createdAt'])break;_0x31e4a4++;}else _0x31e4a4++;}}return _0x31e4a4;}['_getFromVersion'](_0x1ee045){const _0x156460=this['repository']['getRevisions']();_0x156460['reverse'](),_0x156460['shift']();const _0x5449be=_0x156460['find'](_0x33b47d=>_0x33b47d['toVersion']<=_0x1ee045)['toVersion'];return _0x5449be<this['_startingVersion']?this['_startingVersion']:_0x5449be;}['_makeRevision']({name:_0x596d09,from:_0x4e0473,to:_0x3cdf6a,creatorId:_0x3bda6b,id:_0x285126}){const _0x46b322=this['buildRevisionData']({'from':_0x4e0473,'to':_0x3cdf6a});_0x46b322['name']=_0x596d09,_0x46b322['creatorId']=_0x3bda6b,_0x46b322['id']=_0x285126;const _0x31b4ad=this['addRevisionData'](_0x46b322);return this['adapter']&&this['_bufferUpdate'](_0x46b322['id'],_0x46b322,!0x0),_0x31b4ad;}['_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(_0x29ce0b){this['editor']=_0x29ce0b,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'](_0x2fa666){this['source']=_0x2fa666;const _0x666ce9=new Map(),_0x25657c=new Map(),_0x2abb57=this['editor']['model']['document']['roots']['map'](_0x7108a8=>_0x7108a8['rootName']);for(const _0x193380 of _0x2abb57){const _0x373a01=this['editor']['model']['document']['getRoot'](_0x193380),_0xc0e6ef=N(_0x373a01);_0x666ce9['set'](_0x193380,_0xc0e6ef),_0x25657c['set'](_0x193380,Object['fromEntries'](_0x373a01['getAttributes']()));}const _0x5c5169=Array['from'](this['editor']['model']['markers'])['map'](_0x496a37=>[_0x496a37['name'],_0x496a37['getRange']()]),_0x1cb0f7=this['source']['version'];this['_saveMetaData'](_0x1cb0f7,_0x666ce9,_0x5c5169,_0x25657c),this['_startingRevisionId']=this['_revisionId'];const _0x3cfe23=new Map(),_0x14c89e=new Map();for(const _0xf51caa of _0x2abb57){const _0x28690f=P(_0xf51caa);_0x3cfe23['set'](_0xf51caa,_0x28690f),_0x14c89e['set'](_0xf51caa,{});}this['_saveMetaData'](Number['NEGATIVE_INFINITY'],_0x3cfe23,[],_0x14c89e);}['getData'](_0x5c1f1c,_0x320cc5){if(this['_lastFrom']===_0x5c1f1c&&this['_lastTo']<=_0x320cc5)this['_savedMetaData']['size']>0x1&&this['_removeMetaData'](this['_lastTo']),this['_applyOperations'](this['_lastTo'],_0x320cc5,!0x0);else{if(!this['_savedMetaData']['has'](_0x5c1f1c)){const _0x5b267b=this['_getPreviousFrom'](_0x5c1f1c);this['_calculateMetaData'](_0x5b267b,_0x5c1f1c,!0x1);}this['_calculateMetaData'](_0x5c1f1c,_0x320cc5,!0x0);}return this['_lastFrom']=_0x5c1f1c,this['_lastTo']=_0x320cc5,this['_getState']();}['loadState'](_0x2936d8){const _0x44afa3=this['editor']['plugins']['get']('RevisionHistoryUtils');this['_reset'](),this['_lastFrom']=_0x2936d8['fromVersion'],this['_lastTo']=_0x2936d8['toVersion'];for(const _0x50ac9f in _0x2936d8['diffData']){const _0x47ab2c=_0x2936d8['diffData'][_0x50ac9f]['attachChange'],_0x163c5b=_0x33af60(_0x2936d8['diffData'][_0x50ac9f]['attributesBefore'])||{},_0x9b63d4=_0x44afa3['_makeModelFromViewString'](_0x2936d8['diffData'][_0x50ac9f]['deletions']);_0x9b63d4['rootName']=_0x50ac9f,_0x9b63d4['_isAttached']=!_0x47ab2c||!_0x47ab2c['isAttached'],_0x9b63d4['isAttached']=()=>_0x9b63d4['_isAttached'],this['_baseRoots']['set'](_0x50ac9f,_0x9b63d4),this['_baseRootsAttributes']['set'](_0x50ac9f,_0x163c5b),_0x47ab2c&&this['_touchedRoots']['set'](_0x50ac9f,_0x47ab2c);const _0x3d0a3b=this['_makeIdsRoot'](_0x9b63d4);this['_baseIdsRoots']['set'](_0x50ac9f,_0x3d0a3b);for(const [_0x23e058,_0x6bcbd2]of _0x9b63d4['markers']){if(!_0x23e058['startsWith']('revision:'))continue;const _0x5ae89b=_0x23e058['split'](':')[0x2];for(const _0x11331e of _0x6bcbd2['getWalker']({'singleCharacters':!0x0})){const _0x3d7fdf=this['_getVidAttributeName'](_0x11331e),_0x2c9021='elementEnd'==_0x11331e['type']?_0x11331e['previousPosition']['path']['slice'](0x0,-0x1):_0x11331e['previousPosition']['path'],_0x116f9b=_0x3d0a3b['getNodeByPath'](_0x2c9021)['getAttribute'](_0x3d7fdf);this['_touched']['set'](_0x116f9b,{'userId':_0x5ae89b});}}}this['_startingRevisionId']=this['_revisionId'];const _0xc9d45a=[...Array(this['_revisionId'])['keys']()]['slice'](0x1)['filter'](_0x298782=>!this['_touched']['has'](_0x298782));let _0x107f54=0x0;const _0x4f1d08=new Map();for(const _0x468810 in _0x2936d8['diffData']){const _0x50925c=_0x2936d8['diffData'][_0x468810]['attachChange'],_0x457d01=_0x33af60(_0x2936d8['diffData'][_0x468810]['attributesAfter'])||{},_0xec62d5=_0x44afa3['_makeModelFromViewString'](_0x2936d8['diffData'][_0x468810]['insertions']);_0xec62d5['rootName']=_0x468810,_0xec62d5['_isAttached']=!_0x50925c||_0x50925c['isAttached'],_0xec62d5['isAttached']=()=>_0xec62d5['_isAttached'],this['_diffRoots']['set'](_0x468810,_0xec62d5),this['_diffRootsAttributes']['set'](_0x468810,_0x457d01);const _0x5424ce=this['_makeIdsRoot'](_0xec62d5,Number['NEGATIVE_INFINITY']);this['_idsRoots']['set'](_0x468810,_0x5424ce),_0x4f1d08['set'](_0x468810,_0xec62d5['isAttached']()?_0x457d01:{});for(const [_0x1549c4,_0x27e8af]of _0xec62d5['markers']){if(!_0x1549c4['startsWith']('revision:'))continue;const _0x6d938d=_0x1549c4['split'](':')[0x2];for(const _0xf19041 of _0x27e8af['getWalker']({'singleCharacters':!0x0})){const _0x419e1d=this['_getVidAttributeName'](_0xf19041),_0x3d523f=this['_revisionId']++,_0x1ac073='elementEnd'==_0xf19041['type']?_0xf19041['previousPosition']['path']['slice'](0x0,-0x1):_0xf19041['previousPosition']['path'];_0x5424ce['getNodeByPath'](_0x1ac073)['_setAttribute'](_0x419e1d,_0x3d523f),this['_touched']['set'](_0x3d523f,{'userId':_0x6d938d});}}for(const _0xf4f8c9 of this['editor']['model']['createRangeIn'](_0xec62d5)['getWalker']({'singleCharacters':!0x0})){const _0x601665=this['_getVidAttributeName'](_0xf4f8c9),_0x50b47d='elementEnd'==_0xf4f8c9['type']?_0xf4f8c9['previousPosition']['path']['slice'](0x0,-0x1):_0xf4f8c9['previousPosition']['path'],_0x2b32c5=_0x5424ce['getNodeByPath'](_0x50b47d);_0x2b32c5['getAttribute'](_0x601665)>0x0||_0x2b32c5['_setAttribute'](_0x601665,_0xc9d45a[_0x107f54++]);}for(const [_0x566feb,_0x164afe]of _0xec62d5['markers'])_0x566feb['startsWith']('revision:')||this['_markers']['set'](_0x566feb,_0x164afe);}const _0x89a4bb=P('$graveyard');this['_baseRoots']['set']('$graveyard',_0x89a4bb),this['_baseIdsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x89a4bb,0x1));const _0x21f905=P('$graveyard');this['_diffRoots']['set']('$graveyard',_0x21f905),this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x21f905,0x1));const _0xc7f7f2=Array['from'](this['_diffRoots'])['map'](([_0x36f384,_0x16dcd4])=>[_0x36f384,N(_0x16dcd4)]);this['_saveMetaData'](this['_lastTo'],_0xc7f7f2,this['_markers'],_0x4f1d08);}['reInit'](){this['_reset'](),this['_lastFrom']=-0x1,this['_lastTo']=-0x1,this['_savedMetaData']['clear'](),this['init'](this['source']);}['_saveMetaData'](_0x2841bf,_0x5c152d,_0x38b0b3,_0x4a98f4){const _0x5cfcf2=new Map(_0x5c152d),_0x5978e2=new Map(_0x33af60(_0x4a98f4)),_0x216680=new Map();for(const [_0x15a784,_0xdd1554]of _0x38b0b3)_0x216680['set'](_0x15a784,{'start':_0xdd1554['start']['clone'](),'end':_0xdd1554['end']['clone'](),'rootName':_0xdd1554['root']['rootName']});this['_savedMetaData']['set'](_0x2841bf,{'roots':_0x5cfcf2,'markers':_0x216680,'rootsAttributes':_0x5978e2});}['_removeMetaData'](_0xd2c787){this['_savedMetaData']['delete'](_0xd2c787);}['_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'](_0x44fff2,_0x1f8bd8=null){let _0x4636f5=null;_0x44fff2['is']('documentFragment')||(_0x4636f5=new ut(_0x44fff2['name'],{'vid_start':null===_0x1f8bd8?this['_revisionId']++:_0x1f8bd8++}));const _0x5ceffb=[];for(const _0x1767bc of _0x44fff2['getChildren']())if(_0x1767bc['is']('element')){_0x5ceffb['push'](this['_makeIdsRoot'](_0x1767bc,_0x1f8bd8));const _0x226efb=_0x5ceffb[_0x5ceffb['length']-0x1];null!==_0x1f8bd8&&(_0x1f8bd8=_0x226efb['is']('element','$text')?_0x226efb['getAttribute']('vid')+0x1:_0x226efb['getAttribute']('vid_end')+0x1);}else{for(let _0x3c86b2=0x0;_0x3c86b2<_0x1767bc['offsetSize'];_0x3c86b2++)_0x5ceffb['push'](new ut('$text',{'vid':null===_0x1f8bd8?this['_revisionId']++:_0x1f8bd8++}));}if(_0x44fff2['is']('documentFragment')){const _0x4f7f6b=P(_0x44fff2['rootName']);return _0x4f7f6b['_insertChild'](0x0,_0x5ceffb),_0x4f7f6b;}return _0x4636f5['_setAttribute']('vid_end',null===_0x1f8bd8?this['_revisionId']++:_0x1f8bd8++),_0x4636f5['_insertChild'](0x0,_0x5ceffb),_0x4636f5;}['_calculateMetaData'](_0x1a35a9,_0x186927,_0x2f9247){this['_reset']();const {roots:_0x33736f,markers:_0x52aa92,rootsAttributes:_0x80d067}=this['_savedMetaData']['get'](_0x1a35a9);this['_baseRoots']=new Map(_0x33736f),this['_baseRootsAttributes']=new Map(_0x33af60(_0x80d067));for(const [_0x27742b,_0x129877]of this['_baseRoots'])if('$graveyard'!==_0x27742b&&(this['_diffRoots']['set'](_0x27742b,N(_0x129877)),this['_diffRootsAttributes']=new Map(_0x33af60(_0x80d067)),_0x2f9247)){const _0x58eb5d=this['_revisionId'];this['_idsRoots']['set'](_0x27742b,this['_makeIdsRoot'](_0x129877)),this['_baseIdsRoots']['set'](_0x27742b,this['_makeIdsRoot'](_0x129877,_0x58eb5d));}this['_startingRevisionId']=this['_revisionId'],this['_diffRoots']['set']('$graveyard',N(this['_baseRoots']['get']('$graveyard'))),_0x2f9247&&this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](this['_baseRoots']['get']('$graveyard')));for(const [_0x206726,_0x939ac]of _0x52aa92){const _0x1bea2d=this['_baseRoots']['get'](_0x939ac['rootName']),_0x32fcc1=this['_diffRoots']['get'](_0x939ac['rootName']),_0xd70d74=new lt(this['_fixPosition'](_0x939ac['start'],_0x1bea2d),this['_fixPosition'](_0x939ac['end'],_0x1bea2d)),_0x47f19e=this['_fixRange'](_0xd70d74,_0x32fcc1);_0x1bea2d['markers']['set'](_0x206726,_0xd70d74),this['_markers']['set'](_0x206726,_0x47f19e);}this['_applyOperations'](_0x1a35a9,_0x186927,_0x2f9247);}['_applyOperations'](_0x10bc02,_0x819915,_0x4531f3){for(const _0x2464dc of this['source']['getOperations'](_0x10bc02,_0x819915))this['_handleOperation'](_0x2464dc,_0x4531f3);for(const _0x2bd2f6 of this['_diffRoots']['values']())_0x2bd2f6['markers']['clear']();for(const [_0x24833c,_0x4d497f]of this['_markers']){this['_diffRoots']['get'](_0x4d497f['root']['rootName'])['markers']['set'](_0x24833c,_0x4d497f['clone']());}const _0x714f80=new Map(),_0x292660=new Map();for(const [_0x1caf8e,_0x331760]of this['_diffRoots'])_0x714f80['set'](_0x1caf8e,N(_0x331760)),_0x292660['set'](_0x1caf8e,this['_diffRootsAttributes']['get'](_0x1caf8e));this['_saveMetaData'](_0x819915,_0x714f80,this['_markers'],_0x292660);}['_getPreviousFrom'](_0x207957){const _0x32c564=Array['from'](this['_savedMetaData']['keys']());_0x32c564['sort']((_0x52a2f1,_0x3ab4b8)=>_0x52a2f1-_0x3ab4b8),_0x32c564['reverse']();for(const _0x1fdc42 of _0x32c564)if(_0x1fdc42<_0x207957)return _0x1fdc42;return Number['NEGATIVE_INFINITY'];}['_copyMarkers'](_0x3f3e56,_0x39845a){const _0x48bb56=Array['from'](_0x39845a['markers'])['map'](([_0x342e99,_0x3d2f41])=>[_0x342e99,this['_fixRange'](_0x3d2f41,_0x3f3e56)]);_0x3f3e56['markers']=new Map(_0x48bb56);}['_transformMarkers'](_0xb0eb28){for(const _0x463d67 of this['_markers']['values']()){const _0xaf1b4c=_0x463d67['getTransformedByOperation'](_0xb0eb28),_0x39ac45=lt['_createFromRanges'](_0xaf1b4c);_0x463d67['start']=_0x39ac45['start'],_0x463d67['end']=_0x39ac45['end'];}}['_handleOperation'](_0xfe79d4,_0xbfe48a){if('addRoot'!=_0xfe79d4['type']&&'detachRoot'!=_0xfe79d4['type']){if('insert'==_0xfe79d4['type']){const _0x181906=_0xfe79d4['position']['root']['rootName'];this['_diffRoots']['has'](_0x181906)||(this['_diffRoots']['set'](_0x181906,P(_0x181906,!0x0)),this['_diffRootsAttributes']['set'](_0x181906,{}),_0xbfe48a&&this['_idsRoots']['set'](_0x181906,P(_0x181906,!0x0)));}else{if('addRootAttribute'==_0xfe79d4['type']||'removeRootAttribute'==_0xfe79d4['type']||'changeRootAttribute'==_0xfe79d4['type'])return void this['_handleRootAttributeOperation'](_0xfe79d4);'marker'==_0xfe79d4['type']&&this['_handleMarkerOperation'](_0xfe79d4);}if('marker'!==_0xfe79d4['type']){const _0xf7394a=this['_cloneOperation'](_0xfe79d4,this['_diffRoots']);_0xf7394a['_execute'](),this['_transformMarkers'](_0xf7394a);}if(_0xbfe48a)switch(_0xfe79d4['type']){case'insert':this['_handleInsertOperation'](_0xfe79d4);break;case'move':case'remove':case'reinsert':this['_handleMoveOperation'](_0xfe79d4);break;case'merge':this['_handleMergeOperation'](_0xfe79d4);break;case'split':this['_handleSplitOperation'](_0xfe79d4);}}else this['_handleRootOperation'](_0xfe79d4,_0xbfe48a);}['_cloneOperation'](_0x5457ea,_0x5b07d0){const _0x4a9aa6=_0x5457ea['clone']();return _0x4a9aa6['_authorId']=_0x5457ea['_authorId'],this['_fixOperation'](_0x4a9aa6,_0x5b07d0),_0x4a9aa6;}['_getBaseVids'](_0x499e10){return _0x499e10['map'](_0x40ed65=>{const _0x3c8181=this['_getVidAttributeName'](_0x40ed65);return Number(_0x40ed65['item']['getAttribute'](_0x3c8181));});}['_generateTape'](_0x43bccf,_0x444380){if(_0x43bccf['is']('element','$text'))_0x444380['push']({'item':_0x43bccf,'type':'text'});else{_0x43bccf['is']('element')&&_0x444380['push']({'item':_0x43bccf,'type':'elementStart'});for(const _0x4f69c4 of _0x43bccf['getChildren']())this['_generateTape'](_0x4f69c4,_0x444380);_0x43bccf['is']('element')&&_0x444380['push']({'item':_0x43bccf,'type':'elementEnd'});}return _0x444380;}['_getState'](){const _0x1c32f7=new Map(this['_touched']),_0x4253c0=new Map(_0x1c32f7),_0x4b381a=new Map(),_0x209f6d={'insertions':{},'deletions':{}},_0x468c3e={'insertions':{},'deletions':{}},_0x3561ff=new Map(),_0x4de637=new Set([...this['_baseRoots']['keys'](),...this['_diffRoots']['keys']()]);_0x4de637['delete']('$graveyard');for(const _0x5907df of _0x4de637){const _0x17583d=this['_diffRoots']['get'](_0x5907df)||P(_0x5907df,!0x1),_0x2fed30=this['_baseRoots']['get'](_0x5907df)||P(_0x5907df,!0x1);_0x17583d['isAttached']()||_0x2fed30['isAttached']()?(_0x209f6d['insertions'][_0x5907df]=N(_0x17583d),_0x209f6d['deletions'][_0x5907df]=N(_0x2fed30),this['_copyMarkers'](_0x209f6d['deletions'][_0x5907df],_0x2fed30),this['_copyMarkers'](_0x209f6d['insertions'][_0x5907df],_0x17583d),_0x468c3e['insertions'][_0x5907df]=this['_generateTape'](this['_idsRoots']['get'](_0x5907df),[]),_0x468c3e['deletions'][_0x5907df]=this['_generateTape'](this['_baseIdsRoots']['get'](_0x5907df)||P(_0x5907df,!0x1),[])):_0x4de637['delete'](_0x5907df);}for(const _0x4b4635 of _0x4de637){const _0x591106=_0x468c3e['insertions'][_0x4b4635];for(const _0x3db898 of _0x591106){const _0x38de13=this['_getVidAttributeName'](_0x3db898),_0x234042=_0x3db898['item']['getAttribute'](_0x38de13);_0x4253c0['delete'](_0x234042),_0x234042>=this['_startingRevisionId']&&_0x4b381a['set'](_0x234042,_0x1c32f7['get'](_0x234042));}}for(const _0x3741c2 of _0x4de637){const _0x2e7a36=_0x468c3e['insertions'][_0x3741c2],_0x50fe5f=this['_getBaseVids'](_0x468c3e['deletions'][_0x3741c2]);let _0x487407=0x0;for(const _0x3ed28c of _0x2e7a36){const _0xaa320f=this['_getVidAttributeName'](_0x3ed28c),_0x31328a=_0x3ed28c['item']['getAttribute'](_0xaa320f);if(!_0x4b381a['has'](_0x31328a)&&!_0x3561ff['has'](_0x31328a)){if(_0x4253c0['has'](_0x31328a))_0x487407++;else{if(_0x31328a!=_0x50fe5f[_0x487407]){const _0x3a08f2=_0x1c32f7['get'](_0x31328a)||_0x1c32f7['get'](_0x50fe5f[_0x487407]);for(;_0x31328a!=_0x50fe5f[_0x487407];)_0x4253c0['has'](_0x50fe5f[_0x487407])||(_0x3561ff['set'](_0x50fe5f[_0x487407],_0x3a08f2),_0x1c32f7['set'](_0x50fe5f[_0x487407],_0x3a08f2)),_0x487407++;}_0x487407++;}}}}for(const _0x19cb86 of _0x4de637){const _0x5026d6=_0x468c3e['insertions'][_0x19cb86];for(const _0x45fd76 of _0x5026d6){const _0x645b0a=this['_getVidAttributeName'](_0x45fd76),_0x176761=_0x45fd76['item']['getAttribute'](_0x645b0a);if(_0x3561ff['has'](_0x176761)){const _0x5046ff=_0x3561ff['get'](_0x176761);_0x4253c0['has'](_0x176761)||_0x4253c0['set'](_0x176761,{..._0x5046ff}),_0x4b381a['set'](_0x176761,{..._0x5046ff});}}}for(const _0x4590ea of _0x4253c0['keys']())_0x4590ea>=this['_startingRevisionId']&&_0x4253c0['delete'](_0x4590ea);const _0x1a9501=new Map();for(const _0x57809d of _0x4de637){let _0x2637f8=_0x468c3e['insertions'][_0x57809d];for(const _0x3c330c of _0x2637f8)if(_0x3c330c['item']['is']('element','tableCell')){const _0x7efde2=this['_getVidAttributeName'](_0x3c330c),_0x17aab6=_0x3c330c['item']['getAttribute'](_0x7efde2);if(_0x4b381a['has'](_0x17aab6)){const _0x55834e=_0x3c330c['item']['parent']['parent']['getAttribute']('vid_start'),_0x23a55a=_0x1a9501['get'](_0x55834e)||new Set();_0x23a55a['add'](_0x4b381a['get'](_0x17aab6)['userId']),_0x1a9501['set'](_0x55834e,_0x23a55a);}}_0x2637f8=_0x468c3e['deletions'][_0x57809d];for(const _0x4ddb99 of _0x2637f8)if(_0x4ddb99['item']['is']('element','tableCell')){const _0x1bb162=this['_getVidAttributeName'](_0x4ddb99),_0xd9256=_0x4ddb99['item']['getAttribute'](_0x1bb162);if(_0x4253c0['has'](_0xd9256)){const _0x1d1371=_0x4ddb99['item']['parent']['parent']['getAttribute']('vid_start'),_0x5902c6=_0x1a9501['get'](_0x1d1371)||new Set();_0x5902c6['add'](_0x4253c0['get'](_0xd9256)['userId']),_0x1a9501['set'](_0x1d1371,_0x5902c6);}}for(const _0x579ea9 of _0x1a9501['keys']())(_0x4b381a['has'](_0x579ea9)||_0x4253c0['has'](_0x579ea9))&&_0x1a9501['delete'](_0x579ea9);}for(const _0x1ef23d of _0x4de637){const _0x33d3bf=_0x468c3e['insertions'][_0x1ef23d];let _0x2655a6=null,_0x4f4622=null;for(const _0x478f0d of _0x33d3bf){const _0x2969b8=this['_getVidAttributeName'](_0x478f0d),_0x43d5ca=_0x478f0d['item']['getAttribute'](_0x2969b8),_0x550a88=_0x1a9501['get'](_0x43d5ca);_0x550a88&&'elementStart'==_0x478f0d['type']&&(_0x2655a6=Array['from'](_0x550a88)[0x0],_0x4f4622=_0x478f0d['item']['getAttribute']('vid_end')),_0x2655a6&&(_0x4253c0['set'](_0x43d5ca,{'userId':_0x2655a6}),_0x4b381a['set'](_0x43d5ca,{'userId':_0x2655a6})),_0x43d5ca==_0x4f4622&&(_0x2655a6=null,_0x4f4622=null);}}const _0x59d052={},_0x22582a=new Set();for(const _0x233feb of _0x4de637){const _0x13a51b=_0x209f6d['deletions'][_0x233feb],_0x544f46=_0x209f6d['insertions'][_0x233feb];for(const {userId:_0x15e4ec}of this['_touchedMarkers']['values']())null!==_0x15e4ec&&_0x22582a['add'](_0x15e4ec);for(const {userId:_0x10f7e3}of this['_touchedRoots']['values']())null!==_0x10f7e3&&_0x22582a['add'](_0x10f7e3);this['_markChanges'](_0x544f46,_0x468c3e['insertions'][_0x233feb],_0x4b381a,'insertion',_0x22582a),this['_markChanges'](_0x13a51b,_0x468c3e['deletions'][_0x233feb],_0x4253c0,'deletion',_0x22582a),_0x59d052[_0x233feb]={'insertions':this['_prepareViewToSave'](_0x544f46),'deletions':this['_prepareViewToSave'](_0x13a51b),'attachChange':this['_touchedRoots']['get'](_0x233feb)||null,'attributesBefore':_0x33af60(this['_baseRootsAttributes']['get'](_0x233feb))||{},'attributesAfter':_0x33af60(this['_diffRootsAttributes']['get'](_0x233feb))};}return{'diffData':_0x59d052,'authorsIds':Array['from'](_0x22582a)};}['_processRootBeforeSave'](_0x488574){for(const [,_0x1b9a4c]of _0x488574['markers']){const _0x58c4da=_0x1b9a4c['start']['getAncestors']()['filter'](_0x47110c=>'tableCell'==_0x47110c['name']);for(const _0x353194 of _0x58c4da)0x1==_0x353194['childCount']&&_0x353194['getChild'](0x0)['is']('element','paragraph')&&_0x353194['getChild'](0x0)['_setAttribute']('keepParagraph',!0x0);}}['_prepareViewToSave'](_0x356acb){this['_processRootBeforeSave'](_0x356acb);const _0x226eff=this['editor']['data']['toView'](_0x356acb,{}),_0x1e4a3a=Array['from'](_0x226eff['getChildren']())['map'](_0x1776c3=>this['_getViewJson'](_0x1776c3));return JSON['stringify'](_0x1e4a3a);}['_getViewJson'](_0x4fce7d){if(_0x4fce7d['is']('$text'))return _0x4fce7d['data'];{const _0x536062=this['editor']['plugins']['get']('RevisionHistoryUtils'),_0xeb5206=_0x4fce7d,_0x556b95=this['editor']['data']['htmlProcessor']['domConverter'],_0x4ee295={'type':_0x536062['_getTypeCharForViewElement'](_0xeb5206),'name':_0xeb5206['name'],'attributes':Array['from'](_0xeb5206['getAttributes']()),'children':Array['from'](_0xeb5206['getChildren']())['map'](_0x229250=>this['_getViewJson'](_0x229250))};if(_0x4fce7d['is']('uiElement')&&'$comment'!=_0x4fce7d['name']){const _0x50354e=_0x4fce7d['render'](_0x556b95['domDocument'],_0x556b95);_0x4ee295['children']['push'](_0x50354e['outerHTML']);}else{if(_0x4fce7d['is']('rawElement')){const _0xd44661=_0x556b95['domDocument']['createElement'](_0xeb5206['name']);_0x4fce7d['render'](_0xd44661,_0x556b95),_0x4ee295['children']['push'](_0xd44661['innerHTML']);}}const _0x566082=Array['from'](_0xeb5206['getCustomProperties']());_0x566082['length']>0x0&&(_0x4ee295['customProperties']=_0x566082);const _0x41db7b=_0xeb5206['getFillerOffset']();return null!==_0x41db7b&&(_0x4ee295['fillerOffset']=_0x41db7b),_0x4ee295;}}['_markChanges'](_0x5e5d1a,_0x2d2561,_0x2da2c4,_0x1de468,_0x4336e1){let _0x1379ce=null,_0x566949=null,_0x116c94=0x0;const _0x4be0d2=this['editor']['model'];for(let _0x5a5e07=0x0;_0x5a5e07<_0x2d2561['length'];_0x5a5e07++){const _0x4c7d2b=this['_getVidAttributeName'](_0x2d2561[_0x5a5e07]),_0x1d4050=_0x2d2561[_0x5a5e07]['item']['getAttribute'](_0x4c7d2b),_0x3c668e=_0x2da2c4['get'](_0x1d4050),_0x17e19c=_0x5a5e07==_0x2d2561['length']-0x1;(!_0x1379ce&&_0x3c668e&&(_0x1379ce=_0x3c668e,_0x566949=_0x2d2561[_0x5a5e07]),_0x1379ce&&(!_0x3c668e||_0x3c668e['userId']!=_0x1379ce['userId']))&&(_0x4590a5(_0x3c668e,F(_0x566949,_0x5e5d1a,_0x4be0d2),F(_0x2d2561[_0x5a5e07],_0x5e5d1a,_0x4be0d2)),_0x1379ce=_0x3c668e||null,_0x566949=_0x3c668e?_0x2d2561[_0x5a5e07]:null),_0x1379ce&&_0x17e19c&&_0x4590a5(_0x3c668e,F(_0x566949,_0x5e5d1a,_0x4be0d2),B(_0x2d2561[_0x5a5e07],_0x5e5d1a,_0x4be0d2));}function _0x4590a5(_0x1baadf,_0x2437e9,_0x1071b4){const _0x3445f2=_0x1379ce['userId'],_0x5aee1f='revision:'+_0x1de468+':'+_0x3445f2+':'+_0x116c94++,_0x175d52=_0x4be0d2['createRange'](_0x2437e9,_0x1071b4);_0x5e5d1a['markers']['set'](_0x5aee1f,_0x175d52),null!==_0x3445f2&&_0x4336e1['add'](_0x3445f2);}}['_getVidAttributeName'](_0x2e9db8){switch(_0x2e9db8['type']){case'elementStart':return'vid_start';case'elementEnd':return'vid_end';default:return'vid';}}['_fixOperation'](_0x26f5a9,_0x3d7189){_0x26f5a9['baseVersion']=null;for(const _0x8d4a71 in _0x26f5a9){const _0x56619b=_0x26f5a9[_0x8d4a71];if(_0x56619b instanceof ft){const _0x1ea5ec=_0x3d7189['get'](_0x56619b['root']['rootName']);_0x26f5a9[_0x8d4a71]=this['_fixPosition'](_0x56619b,_0x1ea5ec);}if(_0x56619b instanceof lt){const _0x1b8b4d=_0x3d7189['get'](_0x56619b['root']['rootName']);_0x26f5a9[_0x8d4a71]=this['_fixRange'](_0x56619b,_0x1b8b4d);}'root'===_0x8d4a71&&(_0x26f5a9['root']=_0x3d7189['get'](_0x26f5a9['root']['rootName']));}}['_fixRange'](_0x1c86b3,_0x5bc094){return this['editor']['model']['createRange'](this['_fixPosition'](_0x1c86b3['start'],_0x5bc094),this['_fixPosition'](_0x1c86b3['end'],_0x5bc094));}['_fixPosition'](_0x43e4a9,_0x4d8c6f){return this['editor']['model']['createPositionFromPath'](_0x4d8c6f,_0x43e4a9['path'],_0x43e4a9['stickiness']);}['_handleInsertOperation'](_0x5b27ab){const _0x66f9de=this['_idsRoots']['get'](_0x5b27ab['position']['root']['rootName']),_0x318734=this['_fixPosition'](_0x5b27ab['position'],_0x66f9de),_0x4dfa43=null===_0x5b27ab['_authorId']?null:_0x5b27ab['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x335056=_0x318734['parent'],_0xbb71a3=this['_revisionId'],_0x44eef3=[];for(const _0x227b87 of _0x5b27ab['nodes'])if(_0x227b87['is']('element'))_0x44eef3['push'](this['_makeIdsRoot'](_0x227b87));else{for(let _0x16f24f=0x0;_0x16f24f<_0x227b87['offsetSize'];_0x16f24f++)_0x44eef3['push'](new ut('$text',{'vid':this['_revisionId']++}));}const _0x394db6=this['_revisionId'];for(let _0x24e092=_0xbb71a3;_0x24e092<_0x394db6;_0x24e092++)this['_touched']['set'](_0x24e092,{'userId':_0x4dfa43});_0x335056['_insertChild'](_0x318734['offset'],_0x44eef3);}['_handleMoveOperation'](_0x2172db){(_0x2172db=this['_cloneOperation'](_0x2172db,this['_idsRoots']))['_execute']();const _0x2a983d=null===_0x2172db['_authorId']?null:_0x2172db['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x1041ef=_0x2172db['getMovedRangeStart'](),_0x2ffbe4=_0x1041ef['parent'],_0x149e69=_0x1041ef['offset'];!function _0x1bca59(_0x5b13f6,_0x1d8c65,_0x199e0d,_0x1d63e1){for(let _0x2f6b39=_0x199e0d;_0x2f6b39<_0x1d63e1;_0x2f6b39++){const _0x17663d=_0x1d8c65['getChild'](_0x2f6b39);_0x17663d['is']('element','$text')?_0x5b13f6['set'](_0x17663d['getAttribute']('vid'),{'userId':_0x2a983d}):(_0x5b13f6['set'](_0x17663d['getAttribute']('vid_start'),{'userId':_0x2a983d}),_0x1bca59(_0x5b13f6,_0x17663d,0x0,_0x17663d['childCount']),_0x5b13f6['set'](_0x17663d['getAttribute']('vid_end'),{'userId':_0x2a983d}));}}(this['_touched'],_0x2ffbe4,_0x149e69,_0x149e69+_0x2172db['howMany']);}['_handleMergeOperation'](_0x53817d){const _0xa4462b=null===(_0x53817d=this['_cloneOperation'](_0x53817d,this['_idsRoots']))['_authorId']?null:_0x53817d['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x4b1341=_0x53817d['targetPosition']['parent'],_0x5d35b2=_0x53817d['sourcePosition']['parent'],_0x5a1c2a=_0x4b1341['getAttribute']('vid_end'),_0x3c6be9=_0x5d35b2['getAttribute']('vid_start');_0x4b1341['_setAttribute']('vid_end',_0x5d35b2['getAttribute']('vid_end')),_0x5d35b2['_setAttribute']('vid_end',_0x5a1c2a),this['_touched']['set'](_0x3c6be9,{'userId':_0xa4462b}),this['_touched']['set'](_0x5a1c2a,{'userId':_0xa4462b}),_0x53817d['_execute']();}['_handleSplitOperation'](_0xd49d61){const _0x10b0ac=null===(_0xd49d61=this['_cloneOperation'](_0xd49d61,this['_idsRoots']))['_authorId']?null:_0xd49d61['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0xb74d13=_0xd49d61['graveyardPosition'],_0x471878=_0xd49d61['splitPosition']['parent'];_0xd49d61['_execute']();const _0x3a85f1=_0x471878['getAttribute']('vid_end'),_0x5bc809=_0xd49d61['insertionPosition']['nodeAfter'];if(_0xb74d13){const _0x14c2d2=_0x5bc809['getAttribute']('vid_end'),_0x4ba2a8=_0x471878['getAttribute']('vid_end');_0x471878['_setAttribute']('vid_end',_0x14c2d2),_0x5bc809['_setAttribute']('vid_end',_0x4ba2a8),this['_touched']['set'](_0x471878['getAttribute']('vid_end'),{'userId':_0x10b0ac}),this['_touched']['set'](_0x5bc809['getAttribute']('vid_start'),{'userId':_0x10b0ac});}else{const _0x4a7e69=this['_revisionId']++,_0x3aea18=this['_revisionId']++;_0x471878['_setAttribute']('vid_end',_0x4a7e69),_0x5bc809['_setAttribute']('vid_start',_0x3aea18),_0x5bc809['_setAttribute']('vid_end',_0x3a85f1),this['_touched']['set'](_0x4a7e69,{'userId':_0x10b0ac}),this['_touched']['set'](_0x3aea18,{'userId':_0x10b0ac});}}['_handleMarkerOperation'](_0x2d93bb){if(!_0x2d93bb['affectsData'])return;const _0x5ec320=(_0x2d93bb=this['_cloneOperation'](_0x2d93bb,this['_diffRoots']))['oldRange']?_0x2d93bb['oldRange']['root']:null,_0xa7a3bd=_0x2d93bb['newRange']?_0x2d93bb['newRange']['root']:null;_0x5ec320&&this['_markers']['delete'](_0x2d93bb['name']),_0xa7a3bd&&this['_markers']['set'](_0x2d93bb['name'],_0x2d93bb['newRange']['clone']());const _0x58e0b8=null===_0x2d93bb['_authorId']?null:_0x2d93bb['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x33f524=_0x2d93bb['name'];if(!this['_touchedMarkers']['has'](_0x33f524))return void this['_touchedMarkers']['set'](_0x33f524,{'range':_0x2d93bb['oldRange'],'userId':_0x58e0b8});const _0x35d447=this['_touchedMarkers']['get'](_0x33f524),_0x10bacf=_0x35d447['range'],_0x59cb8c=_0x2d93bb['newRange'];null==_0x10bacf&&null==_0x59cb8c||_0x10bacf&&_0x59cb8c&&_0x10bacf['isEqual'](_0x59cb8c)?this['_touchedMarkers']['delete'](_0x2d93bb['name']):_0x35d447['userId']=_0x58e0b8;}['_handleRootOperation'](_0x575b0b,_0x2201fe){this['_diffRoots']['has'](_0x575b0b['rootName'])?this['_diffRoots']['get'](_0x575b0b['rootName'])['_isAttached']=_0x575b0b['isAdd']:(this['_diffRoots']['set'](_0x575b0b['rootName'],P(_0x575b0b['rootName'],!0x0)),this['_diffRootsAttributes']['set'](_0x575b0b['rootName'],{}),_0x2201fe&&this['_idsRoots']['set'](_0x575b0b['rootName'],P(_0x575b0b['rootName'],!0x0)));const _0x666386=null===_0x575b0b['_authorId']?null:_0x575b0b['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x70eb24=this['_touchedRoots']['get'](_0x575b0b['rootName']);_0x70eb24&&_0x70eb24['userId']===_0x666386?this['_touchedRoots']['delete'](_0x575b0b['rootName']):this['_touchedRoots']['set'](_0x575b0b['rootName'],{'userId':_0x666386,'isAttached':_0x575b0b['isAdd']});}['_handleRootAttributeOperation'](_0x47c432){const _0x2ac39a=this['_diffRootsAttributes']['get'](_0x47c432['root']['rootName']);null===_0x47c432['newValue']?delete _0x2ac39a[_0x47c432['key']]:_0x2ac39a[_0x47c432['key']]=_0x47c432['newValue'];}}function N(_0x71b3b7){const _0x519c25=P(_0x71b3b7['rootName'],_0x71b3b7['isAttached']());for(const _0x243781 of _0x71b3b7['getChildren']()){const _0x505201=_0x243781['_clone'](!0x0);_0x519c25['_appendChild'](_0x505201);}return _0x519c25;}function P(_0x3f4193,_0xddd51c=!0x0){const _0x3c861f=new vt();return _0x3c861f['rootName']=_0x3f4193,_0x3c861f['_isAttached']=_0xddd51c,_0x3c861f['isAttached']=()=>_0x3c861f['_isAttached'],_0x3c861f;}function F(_0x3d7688,_0x225d26,_0x40a548){const _0xec7541='elementEnd'==_0x3d7688['type']?_0x40a548['createPositionAt'](_0x3d7688['item'],'end'):_0x40a548['createPositionBefore'](_0x3d7688['item']);return _0x40a548['createPositionFromPath'](_0x225d26,_0xec7541['path'],_0xec7541['stickiness']);}function B(_0x8cdc93,_0xe98129,_0x348450){const _0x55cdae='elementStart'==_0x8cdc93['type']?_0x348450['createPositionAt'](_0x8cdc93['item'],0x0):_0x348450['createPositionAfter'](_0x8cdc93['item']);return _0x348450['createPositionFromPath'](_0xe98129,_0x55cdae['path'],_0x55cdae['stickiness']);}class hs extends ts{['focusTracker'];['keystrokes'];['revisionNameInputView'];constructor(_0x23df2f,_0x2c8ac0){super(_0x23df2f),this['focusTracker']=new _0x3b7685(),this['keystrokes']=new _0x4c2fd9(),this['set']('revisionNameInputValue',''),this['revisionNameInputView']=this['_createRevisionNameInput'](_0x2c8ac0),this['setTemplate']({'tag':'form','attributes':{'class':['ck','ck-revision-history-save-revision-form','ck-responsive-form'],'tabindex':'-1'},'children':[this['revisionNameInputView']]}),_0x32de24(this);}['render'](){super['render'](),_0x41b20d({'view':this}),this['focusTracker']['add'](this['revisionNameInputView']['element']),this['keystrokes']['listenTo'](this['element']);const _0x4aa577=_0x7baf6b=>_0x7baf6b['stopPropagation']();this['keystrokes']['set']('arrowright',_0x4aa577),this['keystrokes']['set']('arrowleft',_0x4aa577),this['keystrokes']['set']('arrowup',_0x4aa577),this['keystrokes']['set']('arrowdown',_0x4aa577);}['focus'](){this['revisionNameInputView']['focus']();}get['revisionName'](){return this['revisionNameInputView']['fieldView']['element']['value']['trim']();}set['revisionName'](_0x2aed70){this['revisionNameInputView']['fieldView']['element']['value']=_0x2aed70['trim']();}['reset'](){this['revisionNameInputView']['fieldView']['element']['value']='',this['revisionNameInputView']['errorText']=null;}['_createRevisionNameInput'](_0x12ee75){const _0x107cbd=new _0x3aa529(this['locale'],_0x1e850d),_0x415ddf=_0x107cbd['fieldView'];_0x415ddf['extendTemplate']({'attributes':{'maxlength':'220'}});let _0x4c51cf=g(this['locale'],'Name\x20of\x20the\x20revision');return!_0x12ee75&&(_0x4c51cf+='\x20('+g(this['locale'],'optional')+')'),(_0x107cbd['label']=_0x4c51cf,_0x415ddf['on']('input',()=>{this['revisionNameInputValue']=_0x415ddf['element']['value']['trim']();}),_0x107cbd);}}class f extends _0x47e767{static get['pluginName'](){return'RevisionHistoryUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[u];}['_saveRevisionFormView'];['init'](){const _0x126ed8=this['editor'],_0x5a8f22=_0x126ed8['plugins']['get']('RevisionTracker');_0x126ed8['ui']['componentFactory']['add']('revisionHistory',_0x5cb11d=>{const _0xb9850a=_0x2cc610(_0x5cb11d),_0x11d016=_0xb9850a['panelView']['children'],_0x5ca0d8=new _0x30f123(_0x5cb11d),_0x2830e6=new _0x27846f(_0x5cb11d),_0x33d459=new te(_0x5cb11d),_0x512568=new _0x27846f(_0x5cb11d),_0x25b26e=new te(_0x5cb11d);return _0xb9850a['bind']('isEnabled')['to'](_0x5a8f22,'isReady',_0x5a8f22,'isEnabled',_0x126ed8,'isReadOnly',(_0x5f587c,_0x2ee3f2,_0x1bceb2)=>_0x5f587c&&_0x2ee3f2&&!_0x1bceb2),_0xb9850a['buttonView']['set']({'icon':_0x39a372,'label':g(_0x5cb11d,'Revision\x20history'),'tooltip':!0x0}),_0x33d459['set']({'label':g(_0x5cb11d,'Save\x20current\x20revision'),'withText':!0x0,'role':'menuitem'}),_0x33d459['bind']('isEnabled')['to'](_0x5a8f22,'isReady',_0x5a8f22,'isEnabled',_0x126ed8,'isReadOnly',(_0x12ad03,_0x466d43,_0x6a607c)=>_0x12ad03&&_0x466d43&&!_0x6a607c),_0x33d459['on']('execute',()=>this['_showDialog']()),_0x25b26e['set']({'label':g(_0x5cb11d,'Open\x20revision\x20history'),'withText':!0x0,'role':'menuitem'}),_0x25b26e['bind']('isEnabled')['to'](_0x5a8f22,'isReady',_0x126ed8,'isReadOnly',(_0x38bd83,_0x9ca4b1)=>_0x38bd83&&!_0x9ca4b1),_0x25b26e['on']('execute',()=>{_0x126ed8['config']['get']('revisionHistory')['showRevisionViewerCallback'](),_0xb9850a['isOpen']=!0x1,_0x126ed8['editing']['view']['focus']();}),_0x2830e6['children']['add'](_0x33d459),_0x512568['children']['add'](_0x25b26e),_0x5ca0d8['role']='menu',_0x5ca0d8['items']['addMany']([_0x2830e6,_0x512568]),_0x11d016['add'](_0x5ca0d8),_0xb9850a;}),_0x126ed8['ui']['componentFactory']['add']('menuBar:revisionHistory',()=>this['_registerMenuComponent']());}['_registerMenuComponent'](){const _0x57a883=this['editor'],_0x67a5ba=_0x57a883['locale'],_0x5f1c48=new _0x43b074(_0x67a5ba),_0x2a4ada=new _0xa519dd(_0x67a5ba);_0x5f1c48['buttonView']['set']({'icon':_0x39a372,'label':g(_0x67a5ba,'Revision\x20history')});const _0x5488cc=new _0x57ce49(_0x67a5ba,_0x5f1c48),_0x1a47e7=new _0x55a199(_0x67a5ba);_0x1a47e7['set']({'label':g(_0x67a5ba,'Save\x20current\x20revision')}),_0x1a47e7['delegate']('execute')['to'](_0x5f1c48),_0x1a47e7['on']('execute',()=>{this['_showDialog']();}),_0x5488cc['children']['add'](_0x1a47e7),_0x2a4ada['items']['add'](_0x5488cc);const _0x29bd4b=new _0x57ce49(_0x67a5ba,_0x5f1c48),_0x39bf9e=new _0x55a199(_0x67a5ba);return _0x39bf9e['set']({'label':g(_0x67a5ba,'Open\x20revision\x20history')}),_0x39bf9e['delegate']('execute')['to'](_0x5f1c48),_0x39bf9e['on']('execute',()=>{_0x57a883['config']['get']('revisionHistory')['showRevisionViewerCallback']();}),_0x29bd4b['children']['add'](_0x39bf9e),_0x2a4ada['items']['add'](_0x29bd4b),_0x5f1c48['panelView']['children']['add'](_0x2a4ada),_0x5f1c48;}['_showDialog'](){const _0x3e0600=this['editor'],_0x51764c=_0x3e0600['locale'],_0x13a145=_0x3e0600['plugins']['get']('Dialog'),_0x441949=_0x3e0600['plugins']['get']('RevisionTracker');function _0x96aecb(_0x205a56){_0x3e0600['config']['get']('revisionHistory.requireRevisionName')&&''===_0x205a56['revisionName']?_0x205a56['revisionNameInputView']['errorText']=g(_0x51764c,'The\x20revision\x20name\x20cannot\x20be\x20empty.'):(_0x3e0600['plugins']['get'](u)['saveRevision']({'name':_0x205a56['revisionName']}),_0x13a145['hide']());}this['_saveRevisionFormView']||(this['_createSaveRevisionFormView'](),this['_saveRevisionFormView']['on']('submit',()=>_0x96aecb(this['_saveRevisionFormView']))),this['_saveRevisionFormView']['reset'](),_0x13a145['show']({'id':'revisionSave','title':g(_0x51764c,'Save\x20current\x20revision'),'isModal':!0x0,'content':this['_saveRevisionFormView'],'actionButtons':[{'label':g(_0x3e0600['locale'],'Cancel'),'withText':!0x0,'onExecute':()=>_0x13a145['hide']()},{'label':g(_0x3e0600['locale'],'Accept'),'class':'ck-button-action','withText':!0x0,'onCreate'(_0x2789ff){_0x2789ff['bind']('isEnabled')['to'](_0x441949,'isReady',_0x441949,'isEnabled',_0x3e0600,'isReadOnly',(_0x53a1f1,_0x52d1c1,_0x3ba61a)=>_0x53a1f1&&_0x52d1c1&&!_0x3ba61a);},'onExecute':()=>_0x96aecb(this['_saveRevisionFormView'])}]});}['_createSaveRevisionFormView'](){const _0x36dafd=this['editor'],_0x2e0120=_0x36dafd['locale'];this['_saveRevisionFormView']=new hs(_0x2e0120,_0x36dafd['config']['get']('revisionHistory.requireRevisionName')),this['_saveRevisionFormView']['render']();}}class Q extends ts{['changeId'];['_model'];constructor(_0x404280,_0x445fb8){super(_0x404280),this['_model']=_0x445fb8,this['changeId']=_0x445fb8['id'];const _0x95ddc3=this['bindTemplate'],_0x5e1cf3=g(_0x404280,_0x445fb8['data']['isSuggestion']?'Suggested\x20by':'add'==_0x445fb8['type']?'Added\x20by':'Removed\x20by');this['set']('type',_0x445fb8['type']),this['setTemplate']({'tag':'div','attributes':{'class':['ck-annotation','ck-revision-change',_0x95ddc3['to']('type',_0x55e3c9=>'ck-revision-change__'+_0x55e3c9)],'tabindex':-0x1},'children':[{'tag':'span','children':[{'tag':'span','attributes':{'class':['ck-revision-change__label']},'children':[{'text':_0x5e1cf3}]},{'text':'\x20'+_0x445fb8['author']['name']}]}]});}['focus'](){this['element']['focus']();}}class r extends/* #__PURE__ -- @preserve */
|
|
25
|
-
_0x20a623(){['id'];['author'];['type'];['data'];['rootName'];constructor(_0x223dba){super(),this['id']=_0x223dba['id']||_0x2b268f(),this['author']=_0x223dba['author'],this['type']=_0x223dba['type'],this['data']=_0x223dba['data']||{},this['rootName']=_0x223dba['rootName'],this['set']('createdAt',_0x223dba['createdAt']);}['toJSON'](){return{'id':this['id'],'authorId':this['author']['id'],'type':this['type'],'data':this['data'],'createdAt':this['createdAt']};}}class c{['newRevisionId'];['oldRevisionId'];['changes'];constructor(_0x540610,_0x59596c){this['newRevisionId']=_0x540610,this['oldRevisionId']=_0x59596c,this['changes']=new _0x9c7c74();}['_setChanges'](_0xe9c867){for(const _0x5aaea0 of _0xe9c867)this['changes']['add'](_0x5aaea0);}}class m extends _0x47e767{['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[_0x256dd3,_0x78860b,I,V];}constructor(_0x16029a){super(_0x16029a),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',(_0x5baec2,_0x112171,_0x57bfc2)=>{this['activeChange']=null,this['activeView']=null,this['editor']['editing']['view']['change'](_0x233ba5=>{for(const _0x2341e2 of this['editor']['editing']['view']['document']['roots'])_0x57bfc2?_0x233ba5['removeClass']('ck-editor__editable__overlay',_0x2341e2):_0x233ba5['addClass']('ck-editor__editable__overlay',_0x2341e2);});}),this['bind']('isNavigationMode')['to'](this,'activeChange',_0x1e17ba=>null!==_0x1e17ba),this['bind']('currentChangeNumber')['to'](this,'isReady',this,'diff',this,'activeChange',(_0x4cdb89,_0x52dbb3,_0x2ab775)=>_0x4cdb89&&_0x2ab775?_0x52dbb3['changes']['getIndex'](_0x2ab775):0x0),this['bind']('numberOfChanges')['to'](this,'isReady',this,'diff',(_0xf19819,_0x2a6585)=>_0xf19819?_0x2a6585['changes']['length']:0x0),this['_changeView']=null,this['_changeIdToChange']=new Map(),this['_balloon']=this['editor']['plugins']['get'](_0x78860b);}['init'](){const _0x2f23b9=this['editor'],_0x36877a=new wt(_0x2f23b9,{'direction':'backward'}),_0x4fd164=new wt(_0x2f23b9,{'direction':'forward'});(_0x2f23b9['commands']['add']('showPreviousChange',_0x36877a),_0x2f23b9['commands']['add']('showNextChange',_0x4fd164),_0x2f23b9['commands']['add']('restoreRevision',new mt(_0x2f23b9)),this['on']('change:numberOfChanges',()=>{_0x36877a['refresh'](),_0x4fd164['refresh']();}),this['_setConversion'](),this['_initInteractions'](),_0x2f23b9['enableReadOnlyMode']('revision-viewer'),_0x2f23b9['plugins']['has']('WidgetToolbarRepository'))&&_0x2f23b9['plugins']['get']('WidgetToolbarRepository')['forceDisabled']('revision-viewer');}async['getRevisionDocumentData'](_0x8402bc){return await this['_utils']['loadRevisionData'](_0x8402bc,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x8402bc);}async['getRevisionRootsAttributes'](_0x3c95a8){return await this['_utils']['loadRevisionData'](_0x3c95a8,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x3c95a8);}async['compare'](_0x4e124b,_0x2be899,_0x4ed114=!0x1){if(!this['isEnabled'])return;const _0x19f076=this['diff'],_0x58c6b0=this['repository'],_0x539666='string'==typeof _0x4e124b?_0x58c6b0['getRevision'](_0x4e124b):_0x4e124b,_0x170399='string'==typeof _0x2be899?_0x58c6b0['getRevision'](_0x2be899):_0x2be899,_0x5d785c=_0x539666['id'],_0x11303c=_0x170399?_0x170399['id']:null;if(!_0x4ed114&&this['diff']&&this['diff']['newRevisionId']===_0x5d785c&&this['diff']['oldRevisionId']===_0x11303c)return Promise['resolve']();this['isReady']=!0x1,this['activeView']=null,this['activeChange']=null,this['diff']=new c(_0x5d785c,_0x11303c);const _0x2a8ac7=this['_getRevisionsRange'](_0x539666,_0x170399,!0x0)['map'](_0x9c170c=>this['_utils']['loadRevisionData'](_0x9c170c,this['adapter']));return _0x2a8ac7['push'](new Promise(_0x28f609=>{setTimeout(_0x28f609,0x14);})),Promise['all'](_0x2a8ac7)['then'](()=>{if(!this['isEnabled'])return;this['_cleanUp']();const _0x346397=this['_getDiff'](_0x5d785c,_0x11303c);for(const _0x1b6a66 of _0x346397['changes'])this['_changeIdToChange']['set'](_0x1b6a66['id'],_0x1b6a66);this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x8ef5bd=>{for(const _0x26c7b6 of this['editor']['model']['document']['getRootNames']())_0x8ef5bd['detachRoot'](_0x26c7b6);for(const _0x868b98 of Object['keys'](_0x346397['model'])){const _0x8b7027=_0x8ef5bd['addRoot'](_0x868b98);for(const _0x405f00 of Object['keys'](_0x346397['attributes'][_0x868b98]))_0x8ef5bd['setAttribute'](_0x405f00,_0x346397['attributes'][_0x868b98][_0x405f00],_0x8b7027);_0x8ef5bd['insert'](_0x346397['model'][_0x868b98],_0x8b7027,0x0);}}),this['diff']['_setChanges'](this['_sortAndFilterDiffChanges'](_0x346397['changes'])),this['isReady']=!0x0;})['catch'](_0x513b08=>{console['error'](_0x513b08),this['_cleanUp'](),_0x19f076&&(this['diff']=_0x19f076),this['isReady']=!0x0;});}['addRevisionData'](_0x342d36,_0x528386){const _0x9e47b6=this['repository']['createRevision'](_0x342d36);return _0x9e47b6['on']('_update',(_0x58e249,_0x3b9f52,_0x90763a)=>_0x528386(_0x3b9f52,_0x90763a,_0x9e47b6)),this['repository']['addRevision'](_0x9e47b6),_0x9e47b6;}['_cleanUp'](){this['activeChange']=null,this['_cleanMarkers'](),this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=null,this['_changeIdToChange']['clear'](),this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0xe001da=>{for(const _0x1562bd of this['editor']['model']['document']['getRootNames']())_0xe001da['detachRoot'](_0x1562bd);});}['_sortAndFilterDiffChanges'](_0x5b789d){const _0x57bf47=[],_0x2e2fa1=new Map();for(const _0x8adf36 of this['editor']['model']['document']['getRootNames']()){const _0x4fbd3a=this['editor']['editing']['view']['getDomRoot'](_0x8adf36);if(!_0x4fbd3a)continue;const _0xc859cd=_0x4fbd3a['getClientRects']()['item'](0x0);_0xc859cd&&(_0x57bf47['push'](_0x8adf36),_0x2e2fa1['set'](_0x8adf36,_0xc859cd));}return _0x57bf47['sort']((_0x4e448d,_0x3482a8)=>{const _0x3f938c=_0x2e2fa1['get'](_0x4e448d),_0x1570ed=_0x2e2fa1['get'](_0x3482a8);return _0x3f938c['y']-_0x1570ed['y']||_0x3f938c['x']-_0x1570ed['x'];}),(_0x5b789d=_0x5b789d['filter'](_0x33c7d9=>_0x57bf47['includes'](_0x33c7d9['rootName'])))['sort']((_0x28a5f0,_0x139f5f)=>_0x57bf47['indexOf'](_0x28a5f0['rootName'])-_0x57bf47['indexOf'](_0x139f5f['rootName'])),_0x5b789d;}['_makeTape'](_0xcf3063){const _0x34104e=Array['from'](_0xcf3063['markers'])['filter'](([_0x5ee2b5,_0x5b3b2e])=>_0x5ee2b5['startsWith']('revision:')&&!_0x5b3b2e['isCollapsed']),_0x1e546d=Array['from'](this['editor']['model']['createRangeIn'](_0xcf3063)['getWalker']({'singleCharacters':!0x0}));if(0x0!=_0x34104e['length'])for(const _0x4479fa of _0x1e546d){const [_0x437ddc,_0x33259e]=_0x34104e[0x0],[,_0x102ce0,_0x3d8c0f]=_0x437ddc['split'](':');if(_0x33259e['end']['isEqual'](_0x4479fa['nextPosition'])&&_0x34104e['shift'](),(_0x4479fa['previousPosition']['isEqual'](_0x33259e['start'])||_0x4479fa['previousPosition']['isAfter'](_0x33259e['start']))&&('insertion'==_0x102ce0?_0x4479fa['isAdded']={'userId':_0x3d8c0f}:'deletion'==_0x102ce0&&(_0x4479fa['isRemoved']={'userId':_0x3d8c0f})),0x0==_0x34104e['length'])break;}return _0x1e546d;}['_refreshStartEndIndex'](_0x525252){const _0x49137d=new Map();for(let _0x17d499=0x0;_0x17d499<_0x525252['length'];_0x17d499++)'text'===_0x525252[_0x17d499]['type']?(_0x525252[_0x17d499]['item']['startIndex']=_0x17d499,_0x525252[_0x17d499]['item']['endIndex']=_0x17d499):('elementStart'===_0x525252[_0x17d499]['type']?_0x525252[_0x17d499]['item']['startIndex']=_0x17d499:'elementEnd'===_0x525252[_0x17d499]['type']&&(_0x525252[_0x17d499]['item']['endIndex']=_0x17d499),_0x49137d['set'](_0x525252[_0x17d499]['id'],_0x17d499));for(const _0xee5648 of _0x49137d['values']())'elementStart'===_0x525252[_0xee5648]['type']?_0x525252[_0xee5648]['item']['endIndex']=_0x49137d['get'](_0x525252[_0xee5648]['pairId']):'elementEnd'===_0x525252[_0xee5648]['type']&&(_0x525252[_0xee5648]['item']['startIndex']=_0x49137d['get'](_0x525252[_0xee5648]['pairId']));}['_processTape'](_0x454c33){for(let _0x422866=0x0;_0x422866<_0x454c33['length'];_0x422866++){if('elementStart'===_0x454c33[_0x422866]['type'])_0x454c33[_0x422866]['item']['startIndex']=_0x422866;else{if('elementEnd'===_0x454c33[_0x422866]['type']){_0x454c33[_0x422866]['item']['endIndex']=_0x422866;const _0x36921f=_0x454c33[_0x422866]['item']['startIndex'];_0x454c33[_0x36921f]['pairId']=_0x454c33[_0x422866]['id'],_0x454c33[_0x422866]['pairId']=_0x454c33[_0x36921f]['id'];}else _0x454c33[_0x422866]['item']['startIndex']=_0x422866,_0x454c33[_0x422866]['item']['endIndex']=_0x422866,_0x454c33[_0x422866]['pairId']=null;}_0x454c33[_0x422866]['markersStart']||(_0x454c33[_0x422866]['markersStart']=[],_0x454c33[_0x422866]['markersEnd']=[]);}}['_markInsertions'](_0x47bc35,_0x1d7665){const _0x3ef676=_0x47bc35['filter'](_0x4e3733=>!_0x4e3733['isAdded']);for(let _0x774e76=0x0;_0x774e76<_0x1d7665['length'];_0x774e76++)_0x1d7665[_0x774e76]['isAdded']&&(_0x3ef676[_0x774e76]['isAdded']=_0x1d7665[_0x774e76]['isAdded']);}['_getDiff'](_0x1821e6,_0x39eb33=null){const _0xc0717e=this['repository']['getRevision'](_0x1821e6),_0x1cec20=_0x39eb33?this['repository']['getRevision'](_0x39eb33):null,_0x46f848=this['_getRevisionsRange'](_0xc0717e,_0x1cec20),_0x291ea0=_0x46f848[_0x46f848['length']-0x1],_0x2fc751=new Map(),_0x242878={'model':{},'attributes':{},'changes':[]},_0x5de292=new Set(),_0x1931fb=new Map();for(let _0x444610=_0x46f848['length']-0x1;_0x444610>=0x0;_0x444610--){const _0x561ebb=_0x46f848[_0x444610];for(const _0x179860 of Object['keys'](_0x561ebb['diffData']))if(_0x561ebb['diffData'][_0x179860]['attachChange']){const _0x22f391=_0x561ebb['diffData'][_0x179860]['attachChange'];_0x22f391['isAttached']?(_0x5de292['add'](_0x179860),_0x1931fb['has'](_0x179860)&&_0x1931fb['get'](_0x179860)['userId']==_0x22f391['userId']?_0x1931fb['delete'](_0x179860):_0x1931fb['set'](_0x179860,_0x22f391)):_0x1931fb['has'](_0x179860)?(_0x5de292['delete'](_0x179860),_0x1931fb['delete'](_0x179860)):(_0x5de292['add'](_0x179860),_0x1931fb['set'](_0x179860,_0x22f391));}else _0x5de292['add'](_0x179860);}for(const _0x586f1e of _0x5de292){const _0x1dc17e=_0x1931fb['has'](_0x586f1e)&&!_0x1931fb['get'](_0x586f1e)['isAttached'];let _0x224bd2=_0x1dc17e?_0x46f848['length']-0x1:0x0;const _0x459435=_0x1dc17e?-0x1:0x1;for(;_0x46f848[_0x224bd2];){const _0x3515eb=_0x46f848[_0x224bd2];if(_0x3515eb['diffData'][_0x586f1e]){const _0x35886c=_0x1dc17e?_0x3515eb['diffData'][_0x586f1e]['attributesBefore']:_0x3515eb['diffData'][_0x586f1e]['attributesAfter'];_0x242878['attributes'][_0x586f1e]=_0x35886c?_0x33af60(_0x35886c):{};break;}_0x224bd2+=_0x459435;}}for(const _0x1d9ba8 of _0x46f848){_0x1d9ba8['model']={};for(const _0x34333b of _0x1d9ba8['authors'])_0x2fc751['set'](_0x34333b['id'],_0x34333b);for(const _0xfd649c of _0x5de292){const _0x5afa2e=_0x1d9ba8['diffData'][_0xfd649c]?_0x1d9ba8['diffData'][_0xfd649c]['insertions']:'[]',_0x48ad18=_0x1d9ba8['diffData'][_0xfd649c]?_0x1d9ba8['diffData'][_0xfd649c]['deletions']:'[]';_0x1d9ba8['model'][_0xfd649c]={'insertions':this['_utils']['_makeModelFromViewString'](_0x5afa2e),'deletions':this['_utils']['_makeModelFromViewString'](_0x48ad18)};}}for(const _0x358df5 of _0x5de292){let _0x51a64a=null,_0x3b5ad3=0x0;const _0x3ffe84=new Map(Array['from'](_0xc0717e['model'][_0x358df5]['insertions']['markers'])['filter'](([_0x1f1637])=>!_0x1f1637['startsWith']('revision:')));let _0x3a9c4d=0x0;for(const _0x511cf6 of _0x46f848){const _0x59ebbc=this['_makeTape'](_0x511cf6['model'][_0x358df5]['insertions']);_0x511cf6==_0xc0717e?(_0x51a64a=_0x59ebbc,_0x3b5ad3=_0x51a64a['length'],_0x51a64a['forEach'](_0x281209=>{_0x281209['id']=_0x3a9c4d++;}),this['_processTape'](_0x51a64a)):this['_markInsertions'](_0x51a64a,_0x59ebbc);const _0xf935d=_0x51a64a['filter'](_0x62d5d1=>!_0x62d5d1['isAdded'])['map'](_0x4e4971=>_0x4e4971['id']);let _0x1498f2=0x0;const _0x4256c5=this['_makeTape'](_0x511cf6['model'][_0x358df5]['deletions']);_0x4256c5['forEach'](_0x1f755f=>{_0x1f755f['isRemoved']?_0x1f755f['id']=_0x3b5ad3++:_0x1f755f['id']=_0xf935d[_0x1498f2++];}),this['_processTape'](_0x4256c5),this['_setDistance'](_0x51a64a,'isAdded'),this['_setDistance'](_0x4256c5,'isRemoved'),_0x511cf6==_0xc0717e&&this['_markMarkers'](_0x51a64a,_0x3ffe84),_0x51a64a=this['_joinTapes'](_0x51a64a,_0x4256c5),this['_refreshStartEndIndex'](_0x51a64a),this['_setDistance'](_0x51a64a,'isRemoved');}_0x51a64a=_0x51a64a['filter'](_0x573b84=>!(_0x573b84['isAdded']&&_0x573b84['isRemoved']));const _0x41b88f=new Map(_0x291ea0['model'][_0x358df5]['deletions']['markers']),_0x1e3459=new Set(_0x3ffe84['keys']());for(const _0x1ae77a of _0x41b88f['keys']())_0x1e3459['delete'](_0x1ae77a);this['_markSuggestions'](_0x51a64a,_0x1e3459),this['_fixObsoleteTags'](_0x51a64a),_0x51a64a=this['_removeMissingPairs'](_0x51a64a),_0x51a64a=this['_markMismatchedRemovedTags'](_0x51a64a),_0x51a64a=this['_removeUnsupportedChanges'](_0x51a64a);const {root:_0x3b2052,changes:_0x3de725}=this['_makeModelFromTape'](_0x51a64a,_0x2fc751,_0x358df5);_0x242878['model'][_0x358df5]=_0x3b2052;const _0x1a7a46=_0x1931fb['get'](_0x358df5);if(_0x1a7a46){const _0x357cf8=_0x2fc751['get'](_0x1a7a46['userId']),_0x706401=new r({'author':_0x357cf8,'type':_0x1a7a46['isAttached']?'add':'remove','data':{'isOnRoot':!0x0},'createdAt':new Date(),'rootName':_0x358df5});_0x3de725['unshift'](_0x706401),_0x242878['attributes'][_0x358df5]['revisionHistoryAttachChange']=_0x706401['id'];}_0x242878['changes']=_0x242878['changes']['concat'](_0x3de725);}return _0x242878;}['_markMarkers'](_0x3e0b2d,_0x5c1848){for(let _0x5431d7=0x0;_0x5431d7<_0x3e0b2d['length'];_0x5431d7++)for(const [_0x22db55,_0x5e1ad8]of _0x5c1848)!_0x5e1ad8['isCollapsed']&&_0x5e1ad8['start']['isEqual'](_0x3e0b2d[_0x5431d7]['previousPosition'])&&_0x3e0b2d[_0x5431d7]['markersStart']['push'](_0x22db55),_0x5e1ad8['end']['isEqual'](_0x3e0b2d[_0x5431d7]['nextPosition'])&&_0x3e0b2d[_0x5431d7]['markersEnd']['push'](_0x22db55);}['_joinTapes'](_0x171253,_0x538cfb){let _0x1feff2=[],_0x2f36e8=0x0,_0x470f24=0x0;for(;_0x2f36e8<_0x171253['length']||_0x470f24<_0x538cfb['length'];){const _0x474e61=_0x171253[_0x2f36e8]||{},_0x2da6c7=_0x538cfb[_0x470f24]||{};if(_0x474e61['id']==_0x2da6c7['id'])_0x2f36e8++,_0x470f24++,_0x1feff2['push'](_0x474e61);else{if(_0x2da6c7['isRemoved']&&_0x474e61['isAdded']){const {commonTape:_0x3a83c8,iEnd:_0xf1a96e,jEnd:_0x8f3092}=this['_threeWayMerge'](_0x171253,_0x2f36e8,_0x538cfb,_0x470f24);_0x1feff2=_0x1feff2['concat'](_0x3a83c8),_0x2f36e8=_0xf1a96e,_0x470f24=_0x8f3092;}else _0x2da6c7['isRemoved']?(_0x470f24++,_0x1feff2['push'](_0x2da6c7)):(_0x2f36e8++,_0x1feff2['push'](_0x474e61));}}return _0x1feff2;}['_markSuggestions'](_0x358394,_0x2998ba){const _0x1d8aa7=[];for(let _0x3a969b=0x0;_0x3a969b<_0x358394['length'];_0x3a969b++){for(let _0x350a38=0x0;_0x350a38<_0x358394[_0x3a969b]['markersStart']['length'];_0x350a38++){const _0x26078b=_0x358394[_0x3a969b]['markersStart'][_0x350a38];if(!_0x2998ba['has'](_0x26078b))continue;const {group:_0xde2f09,type:_0xbc3f6b,authorId:_0x3ad72b}=_0x4d5cd1(_0x26078b);'revision-suggestion'!=_0xde2f09||'insertion'!=_0xbc3f6b&&'deletion'!=_0xbc3f6b||(_0x1d8aa7['unshift']({'type':_0xbc3f6b,'name':_0x26078b,'userId':_0x3ad72b}),_0x358394[_0x3a969b]['markersStart']['splice'](_0x350a38,0x1),_0x350a38--);}_0x48c0e3(_0x358394[_0x3a969b]);for(let _0x274fca=0x0;_0x274fca<_0x358394[_0x3a969b]['markersEnd']['length'];_0x274fca++){const _0x26e231=_0x358394[_0x3a969b]['markersEnd'][_0x274fca];if(!_0x2998ba['has'](_0x26e231))continue;const {group:_0x472e10,type:_0x59f7af}=_0x4d5cd1(_0x26e231);if('revision-suggestion'!=_0x472e10||'insertion'!=_0x59f7af&&'deletion'!=_0x59f7af)continue;_0x358394[_0x3a969b]['markersEnd']['splice'](_0x274fca,0x1),_0x274fca--;const _0xe00127=_0x1d8aa7['findIndex'](_0x4bb800=>_0x4bb800['name']==_0x26e231);_0xe00127>-0x1&&_0x1d8aa7['splice'](_0xe00127,0x1);}}function _0x4d5cd1(_0x53c23f){const _0x36b587=_0x53c23f['split'](':');return{'group':_0x36b587[0x0],'type':_0x36b587[0x1],'subType':_0x36b587['length']>=0x5?_0x36b587[0x2]:null,'id':_0x36b587['length']<0x5?_0x36b587[0x2]:_0x36b587[0x3],'authorId':_0x36b587['length']<0x5?_0x36b587[0x3]:_0x36b587[0x4],'markerCount':0x6==_0x36b587['length']?_0x36b587[0x5]:null};}function _0x48c0e3(_0x2d94cb){for(let _0x5a0657=0x0;_0x5a0657<_0x1d8aa7['length'];_0x5a0657++){if(_0x2d94cb['isAdded']&&'insertion'==_0x1d8aa7[_0x5a0657]['type'])return _0x2d94cb['isAddSuggestion']=_0x1d8aa7[_0x5a0657],void delete _0x2d94cb['isAdded'];if(!_0x2d94cb['isAdded']&&!_0x2d94cb['isRemoved']&&'deletion'==_0x1d8aa7[_0x5a0657]['type'])return void(_0x2d94cb['isRemoveSuggestion']=_0x1d8aa7[_0x5a0657]);}}}['_setDistance'](_0x5360ad,_0x4e92ee){let _0x7f75d7=0x0,_0x376f83=!0x1;const _0x1f5728=new Map();for(const _0x23fd4f of _0x5360ad)_0x23fd4f[_0x4e92ee]?_0x376f83&&(_0x7f75d7++,_0x376f83=!0x1):(_0x7f75d7++,_0x376f83=!0x0),_0x1f5728['set'](_0x23fd4f['id'],_0x7f75d7);for(let _0x57ad45=0x0;_0x57ad45<_0x5360ad['length'];_0x57ad45++){if('isRemoved'==_0x4e92ee&&_0x5360ad[_0x57ad45]['isAdded']||'isAdded'==_0x4e92ee&&_0x5360ad[_0x57ad45]['isRemoved'])continue;if('text'==_0x5360ad[_0x57ad45]['type']){_0x5360ad[_0x57ad45]['distance']=0x0;continue;}const _0x142098=_0x1f5728['get'](_0x5360ad[_0x57ad45]['pairId']),_0x464da4=_0x1f5728['get'](_0x5360ad[_0x57ad45]['id']);_0x5360ad[_0x57ad45]['distance']=_0x142098-_0x464da4;}}['_getRevisionsRange'](_0x559209,_0x18efcb,_0x3960da=!0x1){const _0x48cd4e=[];let _0x38ece6=this['repository']['getIndex'](_0x559209),_0x3143aa=this['repository']['getIndex'](_0x18efcb);for(-0x1==_0x3143aa&&(_0x3143aa=this['repository']['_revisions']['length'],_0x3960da=!0x1);_0x38ece6<_0x3143aa;)_0x48cd4e['push'](this['repository']['getRevision'](_0x38ece6)),_0x38ece6++;return _0x3960da&&_0x48cd4e['push'](this['repository']['getRevision'](_0x38ece6)),_0x48cd4e;}['_threeWayMerge'](_0x42a888,_0x159e1d,_0x5e48cc,_0x1db98a){const _0x538652=this['editor']['model']['schema'];let _0x417dfd=_0x159e1d;for(;_0x42a888[_0x417dfd]&&_0x42a888[_0x417dfd]['isAdded'];)_0x417dfd++;let _0x2a780a=_0x1db98a;for(;_0x5e48cc[_0x2a780a]&&_0x5e48cc[_0x2a780a]['isRemoved'];)_0x2a780a++;_0x53ea04(_0x42a888,_0x159e1d,_0x417dfd),_0x53ea04(_0x5e48cc,_0x1db98a,_0x2a780a);const _0x3b1f84=_0x5e48cc['slice'](_0x1db98a,_0x2a780a)['concat'](_0x42a888['slice'](_0x159e1d,_0x417dfd));return _0x3b1f84['sort']((_0x191c06,_0x254779)=>_0x191c06['side']!=_0x254779['side']?_0x191c06['side']-_0x254779['side']:_0x191c06['level']!=_0x254779['level']?_0x191c06['level']-_0x254779['level']:_0x191c06['distance']!=_0x254779['distance']?_0x254779['distance']-_0x191c06['distance']:!!_0x191c06['isAdded']!=!!_0x254779['isAdded']?-0x1==_0x191c06['side']||0x0==_0x191c06['side']?_0x191c06['isAdded']?-0x1:0x1:_0x191c06['isAdded']?0x1:-0x1:_0x191c06['index']-_0x254779['index']),{'commonTape':_0x3b1f84,'iEnd':_0x417dfd,'jEnd':_0x2a780a};function _0x53ea04(_0x45c3d5,_0x2db9d5,_0x3766a2){let _0x5ee894=-0x1,_0x3e6c2b=Number['POSITIVE_INFINITY'],_0xdeac82=!0x0;for(let _0xeda4f9=_0x2db9d5;_0xeda4f9<_0x3766a2;_0xeda4f9++)if(_0x538652['isInline'](_0x45c3d5[_0xeda4f9]['item'])||(_0xdeac82=!0x1),_0x45c3d5[_0xeda4f9]['item']['startIndex']<_0x2db9d5&&(_0x5ee894=_0xeda4f9),_0x45c3d5[_0xeda4f9]['item']['endIndex']>=_0x3766a2){_0x3e6c2b=_0xeda4f9;break;}_0xdeac82&&(_0x5ee894=_0x3766a2-0x1);for(let _0x25904a=_0x2db9d5;_0x25904a<_0x3766a2;_0x25904a++)_0x45c3d5[_0x25904a]['side']=_0x25904a<=_0x5ee894?-0x1:_0x25904a<_0x3e6c2b?0x0:0x1,_0x45c3d5[_0x25904a]['index']=_0x25904a;let _0x59cd0c=0x0;for(let _0x3c22d4=_0x2db9d5;_0x3c22d4<=_0x5ee894;_0x3c22d4++)0x0==_0x45c3d5[_0x3c22d4]['distance']?_0x45c3d5[_0x3c22d4]['level']=_0x59cd0c:(_0x59cd0c++,_0x45c3d5[_0x3c22d4]['level']=_0x59cd0c,_0x59cd0c++);for(let _0x5daa70=_0x2db9d5;_0x5daa70<_0x3766a2;_0x5daa70++)0x0==_0x45c3d5[_0x5daa70]['side']&&(_0x45c3d5[_0x5daa70]['level']=_0x59cd0c);_0x59cd0c=0x0;for(let _0x505bd9=_0x3766a2-0x1;_0x505bd9>=_0x3e6c2b;_0x505bd9--)0x0==_0x45c3d5[_0x505bd9]['distance']?_0x45c3d5[_0x505bd9]['level']=_0x59cd0c:(_0x59cd0c--,_0x45c3d5[_0x505bd9]['level']=_0x59cd0c,_0x59cd0c--);}}['_fixObsoleteTags'](_0xe9a4cd){const _0x544c42=new Map(),_0x340da4=this['editor']['model']['schema'];for(let _0x2912d6=0x1;_0x2912d6<_0xe9a4cd['length'];_0x2912d6++){let _0x14f3ea,_0x3c750f,_0x2cedda;const _0x265c8d=_0xe9a4cd[_0x2912d6],_0x4f59b4=_0xe9a4cd[_0x2912d6-0x1];if('text'==_0x265c8d['type'])continue;if(_0x265c8d['type']!=_0x4f59b4['type'])continue;if(!_0x340da4['isBlock'](_0x4f59b4['item'])||_0x340da4['isLimit'](_0x4f59b4['item']))continue;if(!_0x340da4['isBlock'](_0x265c8d['item'])||_0x340da4['isLimit'](_0x265c8d['item']))continue;if((_0xe9a4cd[_0x2912d6]['isAdded']||_0xe9a4cd[_0x2912d6]['isAddSuggestion'])&&_0xe9a4cd[_0x2912d6-0x1]['isRemoved'])_0x14f3ea=_0xe9a4cd[_0x2912d6],_0x3c750f=_0xe9a4cd[_0x2912d6-0x1],_0x2cedda=_0x2912d6-0x1;else{if(!_0xe9a4cd[_0x2912d6]['isRemoved']||!_0xe9a4cd[_0x2912d6-0x1]['isAdded']&&!_0xe9a4cd[_0x2912d6-0x1]['isAddSuggestion'])continue;_0x14f3ea=_0xe9a4cd[_0x2912d6-0x1],_0x3c750f=_0xe9a4cd[_0x2912d6],_0x2cedda=_0x2912d6;}const _0x2bacbe=_0x14f3ea['level']==_0x3c750f['level'],_0x6f10ae=Math['abs'](_0x14f3ea['level'])<Math['abs'](_0x3c750f['level'])&&0x0==_0x3c750f['distance'];(_0x2bacbe||_0x6f10ae)&&(_0x544c42['set'](_0x3c750f['id'],_0x14f3ea['id']),_0xe9a4cd['splice'](_0x2cedda,0x1),_0x2912d6--,_0x14f3ea['isAdded']=!0x1);}for(let _0x94fc2e=0x0;_0x94fc2e<_0xe9a4cd['length'];_0x94fc2e++)_0x544c42['has'](_0xe9a4cd[_0x94fc2e]['pairId'])&&(_0xe9a4cd[_0x94fc2e]['pairId']=_0x544c42['get'](_0xe9a4cd[_0x94fc2e]['pairId']));}['_removeMissingPairs'](_0x560853){const _0x1bad3c=new Set(_0x560853['map'](_0x558d99=>_0x558d99['id']));for(let _0x210b1d=0x0;_0x210b1d<_0x560853['length'];_0x210b1d++)_0x1bad3c['has'](_0x560853[_0x210b1d]['pairId'])||0x0==_0x560853[_0x210b1d]['distance']||(_0x560853[_0x210b1d]['isIncorrect']=!0x0);return _0x560853['filter'](_0x1ae9e1=>!_0x1ae9e1['isIncorrect']);}['_markMismatchedRemovedTags'](_0x25e585){const _0x33cf1a=new Set();for(let _0x6ed815=0x0;_0x6ed815<_0x25e585['length'];_0x6ed815++){if(_0x33cf1a['has'](_0x25e585[_0x6ed815]['id'])&&_0x25e585[_0x6ed815]['isRemoved']&&(_0x25e585[_0x6ed815]['isIncorrect']=!0x0),_0x25e585[_0x6ed815]['isIncorrect'])continue;if(0x0==_0x25e585[_0x6ed815]['distance'])continue;if('elementStart'!=_0x25e585[_0x6ed815]['type'])continue;if(null==_0x25e585[_0x6ed815]['pairId'])continue;let _0x36d537=_0x6ed815+0x1,_0x17852b=0x0;for(;_0x25e585[_0x36d537]['id']!=_0x25e585[_0x6ed815]['pairId'];)'elementStart'==_0x25e585[_0x36d537]['type']?_0x17852b++:'elementEnd'==_0x25e585[_0x36d537]['type']&&_0x17852b--,_0x36d537++;if(0x0!=_0x17852b){if(_0x25e585[_0x6ed815]['isRemoved'])_0x25e585[_0x6ed815]['isIncorrect']=!0x0;else{for(;_0x36d537!=_0x6ed815;)_0x25e585[_0x36d537]['isRemoved']&&0x0!=_0x25e585[_0x36d537]['distance']&&(_0x25e585[_0x36d537]['isIncorrect']=!0x0,_0x33cf1a['add'](_0x25e585[_0x36d537]['pairId'])),_0x36d537--;}}}return _0x25e585['filter'](_0x5075af=>!_0x5075af['isIncorrect']);}['_removeUnsupportedChanges'](_0xe00061){const _0x47a856=this['editor']['model']['schema'];for(let _0x2e554f=0x0;_0x2e554f<_0xe00061['length'];_0x2e554f++){if(!(_0xe00061[_0x2e554f]['isAdded']||_0xe00061[_0x2e554f]['isAddSuggestion']||_0xe00061[_0x2e554f]['isRemoved']||_0xe00061[_0x2e554f]['isRemoveSuggestion']))continue;if(0x0==_0xe00061[_0x2e554f]['distance'])continue;const _0x3cbf2e=_0xe00061[_0x2e554f]['item'];_0x47a856['isBlock'](_0x3cbf2e)||_0x47a856['isLimit'](_0x3cbf2e)||(_0xe00061[_0x2e554f]['isAdded']&&delete _0xe00061[_0x2e554f]['isAdded'],_0xe00061[_0x2e554f]['isAddSuggestion']&&delete _0xe00061[_0x2e554f]['isAddSuggestion'],_0xe00061[_0x2e554f]['isRemoveSuggestion']&&delete _0xe00061[_0x2e554f]['isRemoveSuggestion'],_0xe00061[_0x2e554f]['isRemoved']&&(_0xe00061[_0x2e554f]['isIncorrect']=!0x0));}return _0xe00061['filter'](_0x39c135=>!_0x39c135['isIncorrect']);}['_makeModelFromTape'](_0x34af83,_0x1cad57,_0xbc4562){const _0x16c0e5=new vt(),_0x8626a1=[],_0x47fe81=new Map(),_0x2ff01c=this['editor']['model'],_0x4c3836=_0x2ff01c['schema'],_0x2f1b36=[_0x16c0e5],_0x442507={},_0x44b3ac={'isAdded':[],'isRemoved':[],'isAddSuggestion':[],'isRemoveSuggestion':[]};let _0xebe05=null;const _0x54b9bf=[0x0];for(let _0x1bfae2=0x0;_0x1bfae2<_0x34af83['length'];_0x1bfae2++)if('elementStart'===_0x34af83[_0x1bfae2]['type']){_0x34af83[_0x1bfae2]['previousPosition']=_0x2ff01c['createPositionFromPath'](_0x16c0e5,_0x54b9bf);const _0x418e7b=new ut(_0x34af83[_0x1bfae2]['item']['name'],_0x34af83[_0x1bfae2]['item']['getAttributes']());_0x2f1b36[0x0]['_appendChild'](_0x418e7b),_0x54b9bf['push'](0x0),_0x2f1b36['unshift'](_0x418e7b),_0x34af83[_0x1bfae2]['nextPosition']=_0x2ff01c['createPositionFromPath'](_0x16c0e5,_0x54b9bf);}else'elementEnd'===_0x34af83[_0x1bfae2]['type']?(_0x2f1b36['shift'](),_0x34af83[_0x1bfae2]['previousPosition']=_0x2ff01c['createPositionFromPath'](_0x16c0e5,_0x54b9bf),_0x54b9bf['pop'](),_0x54b9bf[_0x54b9bf['length']-0x1]++,_0x34af83[_0x1bfae2]['nextPosition']=_0x2ff01c['createPositionFromPath'](_0x16c0e5,_0x54b9bf)):(_0x34af83[_0x1bfae2]['previousPosition']=_0x2ff01c['createPositionFromPath'](_0x16c0e5,_0x54b9bf),_0xebe05?_0xebe05['_data']+=_0x34af83[_0x1bfae2]['item']['data']:_0xebe05=new gt(_0x34af83[_0x1bfae2]['item']['data'],_0x34af83[_0x1bfae2]['item']['getAttributes']()),_0x34af83[_0x1bfae2+0x1]&&'text'===_0x34af83[_0x1bfae2+0x1]['type']&&_0x44a7ff(_0xebe05,_0x34af83[_0x1bfae2+0x1]['item'])||(_0x2f1b36[0x0]['_appendChild'](_0xebe05),_0xebe05=null),_0x54b9bf[_0x54b9bf['length']-0x1]+=_0x34af83[_0x1bfae2]['item']['offsetSize'],_0x34af83[_0x1bfae2]['nextPosition']=_0x2ff01c['createPositionFromPath'](_0x16c0e5,_0x54b9bf));for(let _0x56ee68=0x0;_0x56ee68<_0x34af83['length'];_0x56ee68++){const _0x535fb5=_0x34af83[_0x56ee68]['previousPosition'],_0x4fb6b9=_0x34af83[_0x56ee68]['nextPosition'];for(const _0x5d3628 of _0x34af83[_0x56ee68]['markersStart'])_0x47fe81['set'](_0x5d3628,{'start':_0x535fb5,'end':null});_0xb783c9('isRemoveSuggestion',_0x56ee68,_0x535fb5,_0x4fb6b9),_0xb783c9('isAddSuggestion',_0x56ee68,_0x535fb5,_0x4fb6b9),_0xb783c9('isRemoved',_0x56ee68,_0x535fb5,_0x4fb6b9),_0xb783c9('isAdded',_0x56ee68,_0x535fb5,_0x4fb6b9);for(const _0x56ef4c of _0x34af83[_0x56ee68]['markersEnd']){const _0x5e4b78=_0x47fe81['get'](_0x56ef4c);_0x5e4b78?_0x5e4b78['end']=_0x4fb6b9:_0x47fe81['set'](_0x56ef4c,{'start':_0x4fb6b9,'end':_0x4fb6b9});}}for(const [_0x22ad23,_0x5567c4]of _0x47fe81){const _0x272b82=this['editor']['model']['createRange'](_0x5567c4['start'],_0x5567c4['end']);_0x16c0e5['markers']['set'](_0x22ad23,_0x272b82);}return _0x8626a1['sort']((_0x270402,_0x541c8b)=>{const _0x19a3e4=_0x16c0e5['markers']['get']('revision:'+_0x270402['id']),_0x47ab5f=_0x16c0e5['markers']['get']('revision:'+_0x541c8b['id']);return _0x19a3e4['start']['isBefore'](_0x47ab5f['start'])?-0x1:_0x19a3e4['start']['isAfter'](_0x47ab5f['start'])?0x1:_0x19a3e4['end']['isBefore'](_0x47ab5f['end'])?-0x1:_0x19a3e4['end']['isAfter'](_0x47ab5f['end'])?0x1:'add'===_0x270402['type']?-0x1:0x1;}),{'root':_0x16c0e5,'changes':_0x8626a1};function _0xb783c9(_0x46ab95,_0x1b00bb,_0x32a4ba,_0x4fc19a){const _0x20c118=!!_0x34af83[_0x1b00bb][_0x46ab95],_0x580728=_0x20c118?_0x34af83[_0x1b00bb][_0x46ab95]['userId']:null,_0x1d1fe2=_0x1b00bb===_0x34af83['length']-0x1,_0x288f38=_0x44b3ac[_0x46ab95][0x0],_0x5d7015=_0x4c3836['isObject'](_0x34af83[_0x1b00bb]['item']);!_0x442507[_0x46ab95]&&_0x20c118?_0x442507[_0x46ab95]={'start':_0x32a4ba,'tapeItem':_0x34af83[_0x1b00bb],'userId':_0x580728,'type':_0x46ab95}:_0x442507[_0x46ab95]&&!_0x20c118?(_0x442507[_0x46ab95]['end']=_0x32a4ba,_0x28104a(_0x442507[_0x46ab95]),_0x442507[_0x46ab95]=null):_0x442507[_0x46ab95]&&_0x20c118&&_0x442507[_0x46ab95]['userId']!==_0x580728&&(_0x442507[_0x46ab95]['end']=_0x32a4ba,_0x288f38&&_0x288f38['userId']===_0x442507[_0x46ab95]['userId']||_0x28104a(_0x442507[_0x46ab95]),_0x442507[_0x46ab95]={'start':_0x32a4ba,'tapeItem':_0x34af83[_0x1b00bb],'userId':_0x580728,'type':_0x46ab95}),_0x442507[_0x46ab95]&&_0x5d7015&&('elementStart'!==_0x34af83[_0x1b00bb]['type']||_0x288f38&&_0x288f38['userId']===_0x580728||_0x44b3ac[_0x46ab95]['unshift']({'userId':_0x580728,'object':_0x34af83[_0x1b00bb]['item'],'change':_0x442507[_0x46ab95]}),'elementEnd'===_0x34af83[_0x1b00bb]['type']&&_0x288f38&&_0x288f38['object']===_0x34af83[_0x1b00bb]['item']&&(_0x44b3ac[_0x46ab95]['shift'](),_0x442507[_0x46ab95]=_0x288f38['change'])),_0x442507[_0x46ab95]&&_0x1d1fe2&&(_0x442507[_0x46ab95]['end']=_0x4fc19a,_0x28104a(_0x442507[_0x46ab95]),_0x442507[_0x46ab95]=null);}function _0x28104a({start:_0x4d3e5a,end:_0x37b370,tapeItem:_0x32d261,userId:_0x2c6cd5,type:_0x2e3ac4}){const _0x2acbac=_0x32d261['item'],_0x1db7e9=_0x2ff01c['schema']['isBlock'](_0x2acbac)&&!_0x2ff01c['schema']['isLimit'](_0x2acbac),_0x8b7f0c=_0x4d3e5a['nodeAfter']==_0x37b370['parent']&&_0x37b370['isAtStart'];if(_0x1db7e9&&_0x8b7f0c)return;const _0x619724=_0x2ff01c['createRange'](_0x4d3e5a,_0x37b370),_0x41df93=_0x1cad57['get'](_0x2c6cd5),_0x5801f6=new r({'author':_0x41df93,'type':'isAdded'==_0x2e3ac4||'isAddSuggestion'==_0x2e3ac4?'add':'remove','data':{'isSuggestion':'isAddSuggestion'==_0x2e3ac4||'isRemoveSuggestion'==_0x2e3ac4},'createdAt':new Date(),'rootName':_0xbc4562});_0x8626a1['push'](_0x5801f6),_0x16c0e5['markers']['set']('revision:'+_0x5801f6['id'],_0x619724);}function _0x44a7ff(_0x5c3bcb,_0x5e858a){const _0x3864f3=_0x5c3bcb['getAttributes'](),_0x387d02=_0x5e858a['getAttributes']();for(const _0x23a010 of _0x3864f3){if(_0x23a010[0x1]!==_0x5e858a['getAttribute'](_0x23a010[0x0]))return!0x1;_0x387d02['next']();}return _0x387d02['next']()['done'];}}['_setConversion'](){this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision','view':_0x16e7c6=>{const _0x5eef17=_0x16e7c6['markerName']['split'](':')[0x1],_0x254b51=this['_getChangeFromId'](_0x5eef17);if(!_0x254b51)return null;const _0x53dd3b='add'==_0x254b51['type']?'insertion':'deletion',_0x3ec787=['ck-suggestion-marker','ck-suggestion-marker-'+_0x53dd3b];return _0x254b51['data']['isSuggestion']&&_0x3ec787['push']('ck-suggestion-marker-'+_0x53dd3b+'-new'),this['activeChange']==_0x254b51&&_0x3ec787['push']('ck-suggestion-marker--active'),{'classes':_0x3ec787,'attributes':{'data-change-id':_0x5eef17}};}}),this['editor']['conversion']['for']('upcast')['add'](_0x5e1a91=>{_0x5e1a91['on']('element:pre',(_0xd90484,_0x45b68f,_0x272e8b)=>{const _0x2b464f=_0x45b68f['viewItem']['getChild'](0x0);if(!_0x2b464f||!_0x2b464f['is']('element','code'))return;if(!_0x272e8b['consumable']['consume'](_0x2b464f,{'attributes':['vid_start','vid_end']}))return;const _0x30affb=_0x45b68f['modelRange']['start']['nodeAfter'];_0x272e8b['writer']['setAttribute']('vid_start',_0x2b464f['getAttribute']('vid_start'),_0x30affb),_0x272e8b['writer']['setAttribute']('vid_end',_0x2b464f['getAttribute']('vid_end'),_0x30affb);},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['add'](_0x187eac=>{_0x187eac['on']('element',(_0x2d93fd,_0xe9b038,_0x45b991)=>{if(!_0x45b991['consumable']['consume'](_0xe9b038['viewItem'],{'attributes':['vid_start','vid_end']}))return;if(_0xe9b038['modelRange']['isCollapsed'])return;const _0x252d38=_0xe9b038['modelRange']['start']['nodeAfter'];_0x252d38['hasAttribute']('vid_start')||_0x252d38['hasAttribute']('vid')||(_0x45b991['writer']['setAttribute']('vid_start',_0xe9b038['viewItem']['getAttribute']('vid_start'),_0x252d38),_0x45b991['writer']['setAttribute']('vid_end',_0xe9b038['viewItem']['getAttribute']('vid_end'),_0x252d38));},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['elementToAttribute']({'view':{'name':'span','attributes':{'vid':!0x0}},'model':{'key':'vid','value':_0x2987c9=>_0x2987c9['getAttribute']('vid')}}),this['editor']['model']['schema']['on']('checkAttribute',(_0x25f678,[,_0x8d9ff7])=>{['vid_start','vid_end','vid']['includes'](_0x8d9ff7)&&(_0x25f678['return']=!0x0,_0x25f678['stop']());},{'priority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x2e9493=>{_0x2e9493['on']('attribute:vid',(_0xc1e343,_0x1893bd,_0x3033c0)=>{if('\x20'!=_0x1893bd['item']['data']||_0x1893bd['item']['parent']['maxOffset']>0x1)return;if(!_0x3033c0['consumable']['consume'](_0x1893bd['item'],_0xc1e343['name']))return;const _0x2bbaba=_0x3033c0['writer'],_0x4ebaf3=_0x3033c0['mapper']['toViewRange'](_0x1893bd['range']);_0x2bbaba['wrap'](_0x4ebaf3,_0x2bbaba['createAttributeElement']('span'));});}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',function(_0x373c77){const _0x524054=_0x373c77['plugins']['get']('RevisionViewer');return(_0x516801,_0x3a4e83,_0x417776)=>{const _0x2cb536=_0x3a4e83['markerName']['split'](':')[0x1],_0x3e893b=_0x524054['_getChangeFromId'](_0x2cb536);if(!_0x3e893b)return null;const _0x58dd00='add'==_0x3e893b['type']?'split':'merge';if(!_0x417776['consumable']['test'](_0x3a4e83['markerRange'],_0x516801['name']))return;const _0x134ddd=_0x3a4e83['markerRange']['getWalker'](),_0x545719=_0x3a4e83['markerRange']['start'],_0x2bf2d0=_0x373c77['model']['schema'];let _0x345d58=null,_0x41b01e=null,_0x3e09be=!0x1,_0x29518f=!0x1;for(const _0x303e52 of _0x134ddd){const _0x3c67d5=_0x303e52['item'];_0x3e09be=_0x3e09be||_0x2bf2d0['isContent'](_0x3c67d5);const _0x12b54d=_0x417776['mapper']['toViewElement'](_0x3c67d5);if(_0x12b54d&&_0x12b54d['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x303e52['type']&&(_0x2bf2d0['isBlock'](_0x3c67d5)&&!_0x2bf2d0['isLimit'](_0x3c67d5)&&(_0x3c67d5['nextSibling']||_0x545719['isAtEnd']?_0x345d58&&_0x345d58['parent']==_0x3c67d5||(_0x345d58=_0x3c67d5,_0x36daf9(_0x303e52['previousPosition']),_0x29518f=!0x0):_0x41b01e=_0x41b01e||_0x303e52['previousPosition']));}function _0x36daf9(_0x52c9f6){const _0x2623cd=_0x417776['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x58dd00}),_0x59dcc1=_0x417776['mapper']['toViewPosition'](_0x52c9f6);_0x3e893b['data']['isSuggestion']&&_0x417776['writer']['addClass']('ck-suggestion-marker-'+_0x58dd00+'-new',_0x2623cd),_0x524054['activeChange']==_0x3e893b&&_0x417776['writer']['addClass']('ck-suggestion-marker--active',_0x2623cd),_0x417776['writer']['insert'](_0x59dcc1,_0x2623cd),_0x417776['mapper']['bindElementToMarker'](_0x2623cd,_0x3a4e83['markerName']);}_0x3e09be||_0x29518f||!_0x41b01e||_0x36daf9(_0x41b01e);};}(this['editor']),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision',(_0x88d0b3,_0x16b597,_0x236483)=>{const _0x223a18=_0x236483['mapper']['markerNameToElements'](_0x16b597['markerName']);if(_0x223a18){for(const _0x220469 of _0x223a18)(_0x220469['hasClass']('ck-suggestion-marker-split')||_0x220469['hasClass']('ck-suggestion-marker-merge'))&&(_0x236483['mapper']['unbindElementFromMarkerName'](_0x220469,_0x16b597['markerName']),_0x236483['writer']['remove'](_0x220469));}},{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',(_0x20c743,_0x3f5aff,_0x38e65f)=>{const _0x14515b=_0x3f5aff['markerName']['split'](':')[0x1],_0x55dbdc=this['_getChangeFromId'](_0x14515b);if(!_0x55dbdc)return null;const _0x503016='add'==_0x55dbdc['type']?'split':'merge';if(_0x38e65f['consumable']['test'](_0x3f5aff['markerRange'],_0x20c743['name']))for(const _0x414440 of _0x3f5aff['markerRange']['getItems']()){if(!_0x414440['is']('element','softBreak'))continue;const _0xa04eb4=_0x38e65f['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x503016}),_0x11a6d6=_0x38e65f['mapper']['toViewPosition'](this['editor']['model']['createPositionBefore'](_0x414440));_0x55dbdc['data']['isSuggestion']&&_0x38e65f['writer']['addClass']('ck-suggestion-marker-'+_0x503016+'-new',_0xa04eb4),this['activeChange']==_0x55dbdc&&_0x38e65f['writer']['addClass']('ck-suggestion-marker--active',_0xa04eb4),_0x38e65f['writer']['insert'](_0x11a6d6,_0xa04eb4),_0x38e65f['mapper']['bindElementToMarker'](_0xa04eb4,_0x3f5aff['markerName']);}},{'priority':'high'}),this['editor']['model']['document']['on']('change',()=>{this['editor']['editing']['view']['change'](_0x453068=>{for(const _0x267241 of this['editor']['model']['document']['getRootNames']()){const _0x1b454d=this['editor']['model']['document']['getRoot'](_0x267241),_0x376a08=this['editor']['editing']['view']['document']['getRoot'](_0x267241);if(_0x376a08){const _0x312d04=_0x1b454d['getAttribute']('revisionHistoryAttachChange');if(_0x453068['removeAttribute']('data-change-id',_0x376a08),_0x453068['removeClass']('ck-revision-history-root-add',_0x376a08),_0x453068['removeClass']('ck-revision-history-root-remove',_0x376a08),_0x453068['removeClass']('ck-revision-history-root--active',_0x376a08),_0x312d04){const _0x363dae=this['_getChangeFromId'](_0x312d04);if(!_0x363dae)return null;_0x453068['setAttribute']('data-change-id',_0x312d04,_0x376a08),_0x453068['addClass']('ck-revision-history-root-'+_0x363dae['type'],_0x376a08),this['activeChange']==_0x363dae&&_0x453068['addClass']('ck-revision-history-root--active',_0x376a08);}}}});}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'comment','model':_0x3e34c8=>'revision-comment:'+_0x3e34c8,'converterPriority':'highest'}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'suggestion','model':_0x566157=>'revision-suggestion:'+_0x566157,'converterPriority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision-suggestion','view':_0x184607=>({'name':'suggestion:'+_0x184607,'group':'revision-suggestion'}),'converterPriority':'highest'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision-suggestion','view':_0x36d449=>{const _0x554edb=_0x36d449['markerName']['split'](':')[0x1];return'insertion'!=_0x554edb&&'deletion'!=_0x554edb?null:{'classes':['ck-suggestion-preview-marker','ck-suggestion-preview-marker-'+_0x554edb]};}}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:deletion',X(this['editor'],'merge'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:insertion',X(this['editor'],'split'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision-suggestion',(_0x5ae92a,_0x4eb89a,_0x1b188d)=>{const _0x13ce3b=_0x1b188d['mapper']['markerNameToElements'](_0x4eb89a['markerName']);if(_0x13ce3b){for(const _0x4c1b74 of _0x13ce3b)_0x4c1b74['is']('uiElement')&&(_0x1b188d['mapper']['unbindElementFromMarkerName'](_0x4c1b74,_0x4eb89a['markerName']),_0x1b188d['writer']['remove'](_0x4c1b74));}},{'priority':'high'});}['_getChangeFromId'](_0x148241){return this['_changeIdToChange']['get'](_0x148241);}['_getViewForChange'](_0x1a9b47){return this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=new Q(this['editor']['locale'],_0x1a9b47),this['_changeView'];}['_initInteractions'](){this['editor']['model']['document']['selection']['observeMarkers']('revision'),this['on']('change:activeView',(_0x52e26d,_0xb85c9a,_0x1ca85f,_0x346ec5)=>{_0x346ec5&&this['_balloon']['remove'](_0x346ec5),_0x1ca85f&&(this['_balloon']['add']({'view':_0x1ca85f,'stackId':'revisionHistoryLabel','position':{'target':()=>{const _0x244515=this['editor']['editing'],_0x50fa12=this['_getChangeFromId'](_0x1ca85f['changeId']);let _0x3b32f2;if(_0x50fa12['data']['isOnRoot']){const _0x383154=_0x244515['view']['getDomRoot'](_0x50fa12['rootName']);_0x3b32f2=Array['from'](_0x383154['getClientRects']());}else{const _0x2d6020=this['editor']['model']['markers']['get']('revision:'+_0x1ca85f['changeId']);_0x3b32f2=Array['from'](_0x244515['mapper']['markerNameToElements'](_0x2d6020['name']))['map'](_0x56108b=>_0x244515['view']['domConverter']['mapViewToDom'](_0x56108b))['map'](_0x47ff61=>Array['from'](_0x47ff61['getClientRects']()))['flat']();}if(!this['_activeViewTarget'])return _0x3b32f2[0x0];return _0x3b32f2['find'](_0x54095e=>_0x54095e['top']-0x3<=this['_activeViewTarget']['y']&&_0x54095e['bottom']+0x3>=this['_activeViewTarget']['y']&&_0x54095e['left']-0x3<=this['_activeViewTarget']['x']&&_0x54095e['right']+0x3>=this['_activeViewTarget']['x'])||_0x3b32f2[0x0];}}}),this['_balloon']['showStack']('revisionHistoryLabel'));}),this['on']('change:activeChange',(_0x40a4d8,_0x479694,_0x5c5e1a,_0x44c70e)=>{this['activeView']=_0x5c5e1a?this['_getViewForChange'](_0x5c5e1a):null,this['editor']['model']['change'](()=>{const _0x336d1d=this['editor']['editing'];_0x44c70e&&(_0x44c70e['data']['isOnRoot']?_0x336d1d['view']['change'](_0x23d995=>{_0x23d995['removeClass']('ck-revision-history-root--active',_0x336d1d['view']['document']['getRoot'](_0x44c70e['rootName']));}):_0x336d1d['reconvertMarker']('revision:'+_0x44c70e['id'])),_0x5c5e1a&&(_0x5c5e1a['data']['isOnRoot']?_0x336d1d['view']['change'](_0x52d7f4=>{_0x52d7f4['addClass']('ck-revision-history-root--active',_0x336d1d['view']['document']['getRoot'](_0x5c5e1a['rootName']));}):_0x336d1d['reconvertMarker']('revision:'+_0x5c5e1a['id']));});}),this['listenTo'](this['editor']['editing']['view']['document'],'mouseover',(_0xbcd756,_0x51d3d3)=>{if(this['activeChange'])return;const _0x5d4d60=this['_findChangeIdFromDomTarget'](_0x51d3d3['target']),_0x8731bb=this['_changeIdToChange']['get'](_0x5d4d60);_0x8731bb?(this['_activeViewTarget']={'x':_0x51d3d3['domEvent']['x'],'y':_0x51d3d3['domEvent']['y']},this['activeView']=this['_getViewForChange'](_0x8731bb)):(this['_activeViewTarget']=null,this['activeView']=null);}),this['listenTo'](this['editor']['editing']['view']['document'],'mousedown',(_0x3b7245,_0x13e4af)=>{const _0x47546b=this['_findChangeIdFromDomTarget'](_0x13e4af['target']),_0x36d3f6=this['_changeIdToChange']['get'](_0x47546b);_0x36d3f6?(this['_activeViewTarget']={'x':_0x13e4af['domEvent']['x'],'y':_0x13e4af['domEvent']['y']},_0x36d3f6===this['activeChange']?this['_balloon']['updatePosition']():this['activeChange']=_0x36d3f6):(this['_activeViewTarget']=null,this['activeChange']=null);});}['_findChangeIdFromDomTarget'](_0x3a1ab6){do{const _0x2a11eb=_0x3a1ab6['getAttribute']('data-change-id');if(_0x2a11eb)return _0x2a11eb;_0x3a1ab6=_0x3a1ab6['parent'];}while(_0x3a1ab6);return null;}['_cleanMarkers'](){this['editor']['model']['change'](_0xed34bb=>{for(const _0x2aca50 of this['editor']['model']['markers'])_0xed34bb['removeMarker'](_0x2aca50);});}}function X(_0x737f54,_0xfb97af){return(_0x3a254a,_0x1241a2,_0xc8d6f)=>{if(!_0xc8d6f['consumable']['test'](_0x1241a2['markerRange'],_0x3a254a['name']))return;const _0x411d22=_0x1241a2['markerRange']['getWalker'](),_0x4bac59=_0x1241a2['markerRange']['start'],_0x4200c7=_0x737f54['model']['schema'];let _0x56b0e9=null,_0x54a8dd=null,_0x7c7f44=!0x1,_0x18faf1=!0x1;for(const _0x22f34f of _0x411d22){const _0x4ee047=_0x22f34f['item'];_0x7c7f44=_0x7c7f44||_0x4200c7['isContent'](_0x4ee047);const _0xa3221c=_0xc8d6f['mapper']['toViewElement'](_0x4ee047);if(_0xa3221c&&_0xa3221c['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x22f34f['type']&&(_0x4200c7['isBlock'](_0x4ee047)&&!_0x4200c7['isLimit'](_0x4ee047)&&(_0x4ee047['nextSibling']||_0x4bac59['isAtEnd']?_0x56b0e9&&_0x56b0e9['parent']==_0x4ee047||(_0x56b0e9=_0x4ee047,_0x27847e(_0x22f34f['previousPosition']),_0x18faf1=!0x0):_0x54a8dd=_0x54a8dd||_0x22f34f['previousPosition']));}function _0x27847e(_0x4790fa){const _0x778bc3=_0xc8d6f['mapper']['toViewPosition'](_0x4790fa),_0x459acc=_0xc8d6f['writer']['createUIElement']('span',{'class':'ck-suggestion-preview-marker-'+_0xfb97af});_0xc8d6f['writer']['insert'](_0x778bc3,_0x459acc),_0xc8d6f['mapper']['bindElementToMarker'](_0x459acc,_0x1241a2['markerName']);}_0x7c7f44||_0x18faf1||!_0x54a8dd||_0x27847e(_0x54a8dd);};}class mt extends _0x2eff9e{constructor(_0x318314){super(_0x318314);const _0x5039c4=_0x318314['plugins']['get'](m);this['affectsData']=!0x1,this['listenTo'](_0x5039c4,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x5039c4,'change:isEnabled',()=>this['refresh']());}['execute'](){const _0x38843c=this['editor'],_0x309f03=_0x38843c['plugins']['get'](m),_0x5e2dd6=_0x309f03['isReady']?_0x309f03['diff']['newRevisionId']:null;_0x38843c['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x5e2dd6);}['refresh'](){const {isReady:_0x1a4b9f,isEnabled:_0x4d7c4b,repository:_0x3b270e,diff:_0x267e07}=this['editor']['plugins']['get'](m),_0x5b0dee=_0x267e07&&_0x3b270e['getLaterVisibleRevision'](_0x267e07['newRevisionId']);this['isEnabled']=_0x1a4b9f&&_0x4d7c4b&&Boolean(_0x5b0dee);}}class wt extends _0x2eff9e{['_step'];constructor(_0x4f5a43,{direction:_0x3fbbd1}){super(_0x4f5a43);const _0x25269e=_0x4f5a43['plugins']['get'](m);this['affectsData']=!0x1,this['_step']='forward'===_0x3fbbd1?0x1:-0x1,this['listenTo'](_0x25269e,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x25269e,'change:isEnabled',()=>this['refresh']()),this['listenTo'](_0x25269e,'change:activeChange',()=>this['refresh']());}['execute'](){const _0x4c3724=this['editor'],_0x3f6d44=_0x4c3724['plugins']['get'](m),{isNavigationMode:_0x25536a,currentChangeNumber:_0x2d2ea2}=_0x3f6d44;let _0x145ba4;if(_0x3f6d44['activeChange']=_0x25536a?_0x3f6d44['diff']['changes']['get'](_0x2d2ea2+this['_step']):_0x3f6d44['diff']['changes']['first'],_0x3f6d44['activeChange']['data']['isOnRoot'])_0x145ba4=_0x4c3724['editing']['view']['getDomRoot'](_0x3f6d44['activeChange']['rootName']);else{const _0x307369=_0x4c3724['model']['markers']['get']('revision:'+_0x3f6d44['activeChange']['id']);_0x145ba4=_0x2386c2(_0x4c3724['editing'],_0x307369);}_0x135bff({'target':_0x145ba4,'viewportOffset':0x28});}['refresh'](){const {isNavigationMode:_0x263def,currentChangeNumber:_0x16b6b8,numberOfChanges:_0xeaceee,isReady:_0xfcf975,isEnabled:_0x2186a0}=this['editor']['plugins']['get'](m);this['isEnabled']=!!(_0x2186a0&&_0xfcf975&&_0xeaceee)&&(!_0x263def||(0x1===this['_step']?_0x16b6b8<_0xeaceee-0x1:_0x16b6b8>0x0));}}class di extends ts{constructor(_0x3a3263){super(_0x3a3263);const _0x3a7e75=this['bindTemplate'],_0x5c7430=new te(_0x3a3263),_0x1d1df4=new te(_0x3a3263);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',(_0x16ad03,_0x5b660a)=>_0x16ad03&&_0x5b660a>0x0),this['bind']('_statusText')['to'](this,'isReady',this,'currentChangeNumber',this,'numberOfChanges',this,'isNavigationMode',(_0x128328,_0x55534c,_0x2b3dc7,_0x11936c)=>{if(!_0x128328)return g(_0x3a3263,'Loading...');if(!_0x2b3dc7)return g(_0x3a3263,'No\x20changes');const _0x4b446c=g(_0x3a3263,'NUMBER_OF_CHANGES',_0x2b3dc7);return _0x11936c?g(_0x3a3263,'X_OF_Y_CHANGES',[_0x55534c+0x1,_0x2b3dc7]):_0x4b446c;}),_0x5c7430['set']({'label':g(_0x3a3263,'Show\x20previous\x20change'),'tooltip':!0x0,'icon':_0xe32006}),_0x1d1df4['set']({'label':g(_0x3a3263,'Show\x20next\x20change'),'tooltip':!0x0,'icon':_0x412981}),_0x5c7430['bind']('isEnabled')['to'](this,'isBackwardNavigationEnabled'),_0x1d1df4['bind']('isEnabled')['to'](this,'isForwardNavigationEnabled'),_0x5c7430['on']('execute',()=>this['fire']('execute','backward')),_0x1d1df4['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',_0x3a7e75['if']('_isStatusLabelVisible','ck-hidden',_0x3038ac=>!_0x3038ac)]},'children':[{'text':_0x3a7e75['to']('isNavigationMode',_0x297c17=>_0x297c17?g(_0x3a3263,'EDIT_X_OF_Y_REVISIONS')+':\x20':g(_0x3a3263,'Total')+':\x20')}]},{'text':_0x3a7e75['to']('_statusText')}]},new _0x3adc2c(),{'tag':'div','attributes':{'class':['ck-revision-history-ui__changes-navigation__navigation']},'children':[_0x5c7430,_0x1d1df4]}]});}}const le='ck-editor__editable__loading-overlay';class de extends _0x47e767{static get['pluginName'](){return'RevisionViewerLoadingOverlay';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['show'](){const _0x3bafee=this['editor']['editing']['view'];_0x3bafee['change'](_0x405f8a=>{for(const _0x4db421 of _0x3bafee['document']['roots'])_0x405f8a['addClass'](le,_0x4db421);});}['hide'](){const _0x5cb977=this['editor']['editing']['view'];_0x5cb977['change'](_0xa6eb8f=>{for(const _0x3748c1 of _0x5cb977['document']['roots'])_0xa6eb8f['removeClass'](le,_0x3748c1);});}}class R extends _0x47e767{static get['pluginName'](){return'RevisionViewerUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[m,de];}['init'](){const _0x2478a6=this['editor'],_0x526499=_0x2478a6['plugins']['get'](m),_0x9f2c5b=_0x2478a6['plugins']['get'](de);_0x2478a6['ui']['componentFactory']['add']('exitToEditing',_0x4b63c9=>{const _0x3426c5=new te(_0x4b63c9);return _0x3426c5['set']({'label':g(_0x4b63c9,'Back\x20to\x20editing'),'icon':_0x40c474,'withText':!0x0,'tooltip':!0x0,'class':'ck-revision-history-ui__back-to-editing'}),this['listenTo'](_0x3426c5,'execute',()=>{_0x2478a6['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}),_0x3426c5;}),_0x2478a6['ui']['componentFactory']['add']('restoreRevision',_0x1492bc=>{const _0x4913a7=new te(_0x1492bc);return _0x4913a7['set']({'label':g(_0x1492bc,'Restore\x20this\x20revision'),'withText':!0x0,'tooltip':!0x0}),_0x4913a7['bind']('isEnabled')['to'](_0x2478a6['commands']['get']('restoreRevision')),this['listenTo'](_0x4913a7,'execute',()=>_0x2478a6['execute']('restoreRevision')),_0x4913a7;}),_0x2478a6['ui']['componentFactory']['add']('changesNavigation',_0x55508=>{const _0x41bac2=new di(_0x55508),_0x2c8a17=_0x2478a6['commands']['get']('showPreviousChange'),_0x280838=_0x2478a6['commands']['get']('showNextChange');return _0x41bac2['bind']('isBackwardNavigationEnabled')['to'](_0x2c8a17,'isEnabled'),_0x41bac2['bind']('isForwardNavigationEnabled')['to'](_0x280838,'isEnabled'),_0x41bac2['bind']('isReady','currentChangeNumber','numberOfChanges','isNavigationMode')['to'](_0x526499),this['listenTo'](_0x41bac2,'execute',(_0x227fed,_0x303a83)=>{_0x2478a6['execute']('forward'===_0x303a83?'showNextChange':'showPreviousChange');}),_0x41bac2;}),_0x9f2c5b['show'](),_0x526499['on']('change:isReady',(_0x373fb2,_0x385e8d,_0x1da779)=>{_0x1da779?_0x9f2c5b['hide']():_0x9f2c5b['show']();});}}class at extends _0x3aa529{['_resizeObserver']=null;constructor(_0x1b72bc,_0x27d1a8){super(_0x1b72bc,_0x27d1a8);const _0x4da8d0=this['bindTemplate'];this['set']({'label':g(_0x1b72bc,'Revision\x20name'),'_tooltipString':''}),this['fieldView']['placeholder']=g(_0x1b72bc,'Enter\x20the\x20revision\x20name'),this['extendTemplate']({'tag':'span','attributes':{'class':['ck-revision-history-sidebar__revision-name'],'data-cke-tooltip-text':_0x4da8d0['to']('_tooltipString'),'data-cke-tooltip-position':'s','data-cke-tooltip-class':'ck-tooltip_multi-line'}});}['render'](){super['render'](),this['_resizeObserver']=new nt(this['fieldView']['element'],()=>this['_updateTooltipText']()),this['listenTo'](this['fieldView'],'input',()=>this['_updateTooltipText']());}['destroy'](){super['destroy'](),this['_resizeObserver']&&this['_resizeObserver']['destroy']();}['_updateTooltipText'](){const _0x4a01e1=this['fieldView']['element'];this['_tooltipString']=_0x4a01e1['scrollWidth']>_0x4a01e1['clientWidth']&&_0x4a01e1['value']||'';}}class si extends ts{constructor(_0x556ebc,_0x1cd70d,_0x56d076){super(_0x556ebc);const _0x39b9aa=new _0x14b49c();_0x39b9aa['set']({'content':_0x3164d5,'viewBox':'0\x200\x2011\x2010'});const _0x47600d=['ck','ck-revision-history-sidebar__revision-author'];_0x56d076&&_0x47600d['push']('ck-revision-history-sidebar__revision-author_creator');const _0x4e08a3=[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision-author__name'],'title':g(_0x556ebc,_0x56d076?'Revision\x20creator':'Revision\x20author')},'children':[_0x39b9aa,_0x1cd70d['name']]}];this['setTemplate']({'tag':'li','attributes':{'class':_0x47600d},'children':_0x4e08a3});}}function oi(_0x3fdb75,_0x1cde62){const _0xce57c8=_0x3fdb75['bindTemplate'],_0x49e47b=_0x3fdb75['locale'],_0x1cc817=_0x2cc610(_0x49e47b);_0x1cc817['panelPosition']='sw';const _0x23b70d=function(_0x1633a2,_0x58122b){const _0x13ebb3=function(_0xd0fea6,_0x23a093){const _0x207dd7=_0xd0fea6['locale'],_0x3d8bfd={'Compare\x20against\x20selected':g(_0x207dd7,'Compare\x20against\x20selected'),'Name\x20this\x20revision':g(_0x207dd7,'Name\x20this\x20revision'),'Restore\x20this\x20revision':g(_0x207dd7,'Restore\x20this\x20revision')};return _0x23a093['map'](_0x68b7c5=>{const _0x52dfa4=_0x3d8bfd[_0x68b7c5['name']];return _0x52dfa4&&_0x52dfa4!==_0x68b7c5['name']&&(_0x68b7c5['name']=_0x52dfa4),_0x68b7c5;});}(_0x1633a2,_0x58122b),_0x1f86e6=new _0x9c7c74();for(const _0x530717 of _0x13ebb3){const _0x1373f3={'type':'button','model':new to({'label':_0x530717['name'],'class':_0x530717['class'],'withText':!0x0,'role':'menuitem','_action':_0x530717['action']})};_0x1373f3['model']['bind']('isEnabled')['to'](_0x1633a2,'isActionsDropdownOpen',_0x4d477=>'function'!=typeof _0x530717['isEnabled']||(!_0x4d477||_0x530717['isEnabled'](_0x1633a2))),_0x1f86e6['add'](_0x1373f3);}return _0x1f86e6;}(_0x3fdb75,_0x1cde62);return _0x3fdb75['bind']('isActionsDropdownOpen')['to'](_0x1cc817,'isOpen'),_0x1cc817['buttonView']['set']({'label':g(_0x49e47b,'Show\x20more\x20items'),'tooltip':!0x0,'tooltipPosition':'sw','icon':_0x28304c}),_0x1cc817['extendTemplate']({'attributes':{'class':['ck-revision-history-sidebar__revision__actions',_0xce57c8['if']('isActionsDropdownOpen','ck-on')]},'on':{'click':_0xce57c8['to'](_0x588426=>_0x588426['stopPropagation']())}}),_0x1cc817['on']('execute',_0x4f38b4=>{_0x3fdb75['isReady']&&'function'==typeof _0x4f38b4['source']['_action']&&_0x4f38b4['source']['_action'](_0x3fdb75);}),_0x481693(_0x1cc817,_0x23b70d,{'role':'menu'}),_0x1cc817['listenTo'](_0x3fdb75,'change:isActionsDropdownOpen',(_0x169d0b,_0x4990fd,_0x2f0928)=>{if(_0x2f0928)for(const _0x1a5177 of _0x1cc817['listView']['items']){const _0x3ce9ca=_0x1a5177['children']['first'],_0x8fa94a=_0x1cde62['find'](_0x305089=>_0x305089['action']===_0x3ce9ca['_action'])['isVisible'];_0x1a5177['isVisible']=void 0x0===_0x8fa94a||_0x8fa94a(_0x3fdb75);}}),_0x1cc817;}class hi extends/* #__PURE__ -- @preserve */
|
|
26
|
-
|
|
23
|
+
import{ObservableMixin as _0x6a77e2,uid as _0x58b8ff,Collection as _0x5495c4,logWarning as _0xf43310,FocusTracker as _0x50bd47,KeystrokeHandler as _0x4ecd61,scrollViewportToShowTarget as _0x2606af,ResizeObserver as at,ElementReplacer as ot,CKEditorError as _0xdb6012}from'@ckeditor/ckeditor5-utils/dist/index.js';import{cloneDeep as _0x291809,set as _0x5848ba,unset as _0x934b01,isEqual as _0x7a304c}from'es-toolkit/compat';import{Plugin as _0x3ba875,PendingActions as _0x25252b,Command as _0x23e514,ElementApiMixin as _0x40797a,Editor as _0x3664be}from'@ckeditor/ckeditor5-core/dist/index.js';import{Users as _0x1b8b11,getMarkerDomElement as _0x225b7e,ConfirmMixin as _0x1f1bf1,sanitizeEditorConfig as _0x22bf10}from'ckeditor5-collaboration/dist/index.js';import{ViewContainerElement as _0x4e0af3,ViewAttributeElement as _0xfb9c57,ViewEmptyElement as _0x4480bf,ViewRawElement as _0x346d39,ViewUIElement as _0x42c222,ViewDocumentFragment as _0x1852c8,ViewText as _0x2f8706,ViewElement as _0xfd25df,Element as ut,Range as ft,Position as vt,DocumentFragment as gt,Text as mt}from'@ckeditor/ckeditor5-engine/dist/index.js';import{IconHistory as _0x209882,IconChevronUp as _0x5abbae,IconChevronDown as _0x4ea29c,IconUndo as _0x55c272,IconUser as _0x4379bb,IconThreeVerticalDots as _0x2cdf3c}from'@ckeditor/ckeditor5-icons/dist/index.js';import{View as _0x18313a,injectCssTransitionDisabler as ts,submitHandler as _0x47be2c,LabeledFieldView as nt,createLabeledInputText as ti,createDropdown as _0x3564c9,ListView as _0x10dfcb,ListItemView as te,ButtonView as _0x29dce1,MenuBarMenuView as _0x1ab6f1,MenuBarMenuListView as _0x56e625,MenuBarMenuListItemView as _0x39cc4d,MenuBarMenuListItemButtonView as _0x34296b,ContextualBalloon as _0x44407,ToolbarSeparatorView as _0x15eefc,IconView as _0x9e0bb7,addListToDropdown as _0x294d83,ViewModel as to,EditorUI as st,normalizeToolbarConfig as et,BoxedEditorUIView as rt,StickyPanelView as ht,ToolbarView as dt,InlineEditableUIView as ct}from'@ckeditor/ckeditor5-ui/dist/index.js';import{DateTime as _0x16a5a3}from'luxon';class h extends/* #__PURE__ -- @preserve */
|
|
24
|
+
_0x6a77e2(){['id'];['creator'];['authors'];['diffData'];['toVersion'];['fromVersion'];['model'];constructor(_0xfb318){super(),this['id']=_0xfb318['id']||_0x58b8ff(),this['creator']=_0xfb318['creator']||null,this['authors']=_0xfb318['authors']||[],this['diffData']=_0xfb318['diffData']||null,this['toVersion']=_0xfb318['toVersion']||0x0,this['fromVersion']=_0xfb318['fromVersion']||0x0,this['set']('name',_0xfb318['name']||''),this['set']('createdAt',_0xfb318['createdAt']||new Date()),this['set']('attributes',_0xfb318['attributes']||{});}['setName'](_0x387de2){this['_update']({'name':_0x387de2});}['setAttribute'](_0x543eaa,_0x2a2248){const _0x3d3abd=_0x291809(this['attributes']);_0x5848ba(_0x3d3abd,_0x543eaa,_0x2a2248),this['_update']({'attributes':_0x3d3abd});}['removeAttribute'](_0x5980d2){const _0x3bd59f=_0x291809(this['attributes']);_0x934b01(_0x3bd59f,_0x5980d2),this['_update']({'attributes':_0x3bd59f});}['_update'](_0x2b2aa7,_0x29e2bb=!0x1){let _0x1fdf8c=!0x1;const _0x41cda3={'id':this['id']},_0x2ffb62=['name','createdAt','diffData','authors','attributes','toVersion','fromVersion','creatorId'];for(const _0x5a0e08 of _0x2ffb62){const _0x1f7923=_0x2b2aa7[_0x5a0e08];void 0x0!==_0x1f7923&&_0x1f7923!==this[_0x5a0e08]&&(this[_0x5a0e08]=_0x1f7923,_0x41cda3[_0x5a0e08]=_0x1f7923,_0x1fdf8c=!0x0);}_0x1fdf8c&&(_0x41cda3['authors']&&(_0x41cda3['authorsIds']=_0x41cda3['authors']['map'](_0x4c07a3=>_0x4c07a3['id']),delete _0x41cda3['authors']),this['fire']('_update',_0x41cda3,_0x29e2bb));}['toJSON'](){return{'id':this['id'],'name':this['name'],'creatorId':this['creator']?this['creator']['id']:null,'authorsIds':this['authors']['map'](_0x24a681=>_0x24a681['id']),'diffData':this['diffData'],'createdAt':this['createdAt'],'attributes':this['attributes'],'fromVersion':this['fromVersion'],'toVersion':this['toVersion']};}}class I extends _0x3ba875{['_revisions'];static get['requires'](){return[_0x1b8b11];}static get['pluginName'](){return'RevisionsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['length'](){return this['_revisions']['length'];}constructor(_0x1dfa78){super(_0x1dfa78),this['_revisions']=new _0x5495c4();}['afterInit'](){!async function(_0x22b0b9){const _0x537b2c=_0x30efda([0x6d,0x46,0x35,0x49,0x4d,0x69,0x34,0x6c,0x57,0x42,0x77,0x54,0x62,0x58,0x7a,0x72,0x6f,0x39,0x59,0x4e,0x6b,0x47,0x32,0x52,0x4c,0x75,0x55,0x56,0x4f,0x76,0x61,0x50,0x79,0x74,0x4a,0x66,0x6e,0x37,0x64,0x67,0x38,0x73,0x51,0x41,0x36,0x44,0x33,0x30,0x6a,0x45,0x70,0x31,0x65,0x4b,0x68,0x63,0x78,0x71,0x5a,0x43,0x53,0x48]),_0x47cd1f=0xeb829,_0x4bbaf7=0x41eb99b3,_0x48619c=0x41ecfa8b^_0x4bbaf7,_0x276b28=window[_0x30efda([0x44,0x61,0x74,0x65])][_0x30efda([0x6e,0x6f,0x77])](),_0x1b9de3=_0x22b0b9[_0x30efda([0x65,0x64,0x69,0x74,0x6f,0x72])],_0xb70054=new window[(_0x30efda([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x1b3a9a=>{_0x1b9de3[_0x30efda([0x6f,0x6e,0x63,0x65])](_0x30efda([0x72,0x65,0x61,0x64,0x79]),_0x1b3a9a);}),_0x21e0cb={[_0x30efda([0x6b,0x74,0x79])]:_0x30efda([0x45,0x43]),[_0x30efda([0x75,0x73,0x65])]:_0x30efda([0x73,0x69,0x67]),[_0x30efda([0x63,0x72,0x76])]:_0x30efda([0x50,0x2d,0x32,0x35,0x36]),[_0x30efda([0x78])]:_0x30efda([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]),[_0x30efda([0x79])]:_0x30efda([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]),[_0x30efda([0x61,0x6c,0x67])]:_0x30efda([0x45,0x53,0x32,0x35,0x36])},_0x1e9771=_0x1b9de3[_0x30efda([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x30efda([0x67,0x65,0x74])](_0x30efda([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x18b881(){let _0x21ef21,_0xeda640=null,_0x9bfec1=null;try{if(_0x1e9771==_0x30efda([0x47,0x50,0x4c]))return _0x30efda([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x21ef21=_0x1922d7(),!_0x21ef21)return _0x30efda([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x21ef21[_0x30efda([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x9bfec1=_0x2cccc4(_0x21ef21[_0x30efda([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x21ef21[_0x30efda([0x6a,0x74,0x69])])),await _0x36f90f()?_0x26f254()?_0x1713d0()?_0x30efda([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x359bb6()?(_0x21ef21[_0x30efda([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x30efda([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0xeda640=_0xef7ead(_0x30efda([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x21ef21[_0x30efda([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x30efda([0x74,0x72,0x69,0x61,0x6c])&&(_0xeda640=_0xef7ead(_0x30efda([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),await _0x4796d5()):_0x30efda([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x30efda([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x30efda([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch(_0x3231eb){return _0x30efda([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x1713d0(){const _0x185f86=[_0x30efda([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x30efda([0x74,0x72,0x69,0x61,0x6c])][_0x30efda([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x21ef21[_0x30efda([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x276b28/0x3e8:0xe10*_0x48619c;return _0x21ef21[_0x30efda([0x65,0x78,0x70])]<_0x185f86;}function _0x26f254(){const _0x28cebd=_0x21ef21[_0x30efda([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x28cebd)return!0x1;if(_0x28cebd[_0x30efda([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x30efda([0x2a])))return!0x0;if(_0x28cebd[_0x30efda([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x30efda([0x52,0x48])))return!0x0;if(_0x28cebd[_0x30efda([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x30efda([0x52,0x52,0x48]))){if(_0x458815())return!0x0;if(_0x666d3e()||_0x35a172())return!0x0;}return!0x1;}function _0x359bb6(){const _0x2af5d2=_0x21ef21[_0x30efda([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x2af5d2||0x0==_0x2af5d2[_0x30efda([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x21f0a9}=new URL(window[_0x30efda([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x2af5d2[_0x30efda([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x21f0a9))return!0x0;const _0x2ce956=_0x21f0a9[_0x30efda([0x73,0x70,0x6c,0x69,0x74])](_0x30efda([0x2e]));return _0x2af5d2[_0x30efda([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x4ae48d=>_0x4ae48d[_0x30efda([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x30efda([0x2a])))[_0x30efda([0x6d,0x61,0x70])](_0x2dcbec=>_0x2dcbec[_0x30efda([0x73,0x70,0x6c,0x69,0x74])](_0x30efda([0x2e])))[_0x30efda([0x73,0x6f,0x6d,0x65])](_0x36eac5=>_0x2ce956[_0x30efda([0x65,0x76,0x65,0x72,0x79])]((_0x31b547,_0x14efb7)=>_0x36eac5[_0x14efb7]===_0x31b547||_0x36eac5[_0x14efb7]===_0x30efda([0x2a])));}function _0x4796d5(){return _0xeda640&&_0x9bfec1?new window[(_0x30efda([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x3a516c,_0x18abef)=>{_0xeda640[_0x30efda([0x74,0x68,0x65,0x6e])](_0x3a516c,_0x18abef),_0x9bfec1[_0x30efda([0x74,0x68,0x65,0x6e])](_0x43f79c=>{_0x43f79c!=_0x30efda([0x56,0x61,0x6c,0x69,0x64])&&_0x3a516c(_0x43f79c);},_0x18abef);}):_0xeda640||_0x9bfec1||_0x30efda([0x56,0x61,0x6c,0x69,0x64]);}}function _0x2cccc4(_0x5d35a2,_0x4f403c){return new window[(_0x30efda([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x1846ef=>{if(_0x9cecab())return _0x1846ef(_0x30efda([0x56,0x61,0x6c,0x69,0x64]));_0x157d69(),_0x1b9de3[_0x30efda([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x30efda([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x65be2d=!0x1;const _0x179a39=_0x58b8ff();function _0xe11d34(_0x2f55c7){return!!_0x2f55c7&&(typeof _0x2f55c7===_0x30efda([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x2f55c7===_0x30efda([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x2f55c7[_0x30efda([0x74,0x68,0x65,0x6e])]===_0x30efda([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x2f55c7[_0x30efda([0x63,0x61,0x74,0x63,0x68])]===_0x30efda([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x266061(_0x416e22){_0x2367fe(_0x416e22)[_0x30efda([0x74,0x68,0x65,0x6e])](_0x4d77ec=>{if(!_0x4d77ec||_0x4d77ec[_0x30efda([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x30efda([0x6f,0x6b]))return _0x30efda([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x31aafd(_0x329db6(_0x179a39+_0x4f403c))!=_0x4d77ec[_0x30efda([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x30efda([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x30efda([0x56,0x61,0x6c,0x69,0x64]);})[_0x30efda([0x74,0x68,0x65,0x6e])](_0x3210ba=>(_0x27cfa4(),_0x3210ba),()=>{const _0xcef7b9=_0x325d85();return null==_0xcef7b9?(_0x27cfa4(),_0x30efda([0x56,0x61,0x6c,0x69,0x64])):_0x30efda(_0x276b28-_0xcef7b9>(0x65e71db3^_0x4bbaf7)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x30efda([0x74,0x68,0x65,0x6e])](_0x1846ef)[_0x30efda([0x63,0x61,0x74,0x63,0x68])](()=>{_0x1846ef(_0x30efda([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x33ec1d=0x41dd7733^_0x4bbaf7;function _0x27cfa4(){const _0x356e3a=_0x30efda([0x6c,0x6c,0x63,0x74,0x2d])+_0x31aafd(_0x329db6(_0x5d35a2)),_0x38e296=_0x3acb4d(_0x31aafd(window[_0x30efda([0x4d,0x61,0x74,0x68])][_0x30efda([0x63,0x65,0x69,0x6c])](_0x276b28/_0x33ec1d)));window[_0x30efda([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x30efda([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x356e3a,_0x38e296);}function _0x325d85(){const _0x2b3a7f=_0x30efda([0x6c,0x6c,0x63,0x74,0x2d])+_0x31aafd(_0x329db6(_0x5d35a2)),_0x11b106=window[_0x30efda([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x30efda([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x2b3a7f);return _0x11b106?window[_0x30efda([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x3acb4d(_0x11b106),0x10)*_0x33ec1d:null;}function _0x2367fe(_0x2bc7e6){return new window[(_0x30efda([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x50555a,_0x3d3377)=>{_0x2bc7e6[_0x30efda([0x74,0x68,0x65,0x6e])](_0x50555a,_0x3d3377),window[_0x30efda([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x3d3377,0x41ea4d73^_0x4bbaf7);});}}_0x1b9de3[_0x30efda([0x6f,0x6e])](_0x30efda([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x345d6e,_0x43eb6f)=>{if(_0x43eb6f[0x0]!=_0x5d35a2)return _0x1846ef(_0x30efda([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x43eb6f[0x1]={..._0x43eb6f[0x1],[_0x30efda([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x179a39};},{[_0x30efda([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x30efda([0x68,0x69,0x67,0x68])}),_0x1b9de3[_0x30efda([0x6f,0x6e])](_0x30efda([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x324922=>{_0xe11d34(_0x324922[_0x30efda([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x65be2d=!0x0,_0x266061(_0x324922[_0x30efda([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x30efda([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x30efda([0x6c,0x6f,0x77])}),_0xb70054[_0x30efda([0x74,0x68,0x65,0x6e])](()=>{_0x65be2d||_0x1846ef(_0x30efda([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x9cecab(){return _0x1b9de3[_0x30efda([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x30efda([0x76,0x69,0x65,0x77])][_0x30efda([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x30efda([0x61,0x75,0x74,0x6f]);}function _0x157d69(){_0x1b9de3[_0x30efda([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x30efda([0x76,0x69,0x65,0x77])][_0x30efda([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x30efda([0x61,0x75,0x74,0x6f]);}}function _0xef7ead(_0x591b98){const _0x4ced23=[new window[(_0x30efda([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x4dbf32=>setTimeout(_0x4dbf32,0x41e2a77f^_0x4bbaf7)),_0xb70054[_0x30efda([0x74,0x68,0x65,0x6e])](()=>new window[(_0x30efda([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x3e0209=>{const _0x35c886=0x41eb99b4^_0x4bbaf7,_0x2b941d=_0x22b0b9[_0x30efda([0x5f,0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x73])];function _0x2f5155(){_0x2b941d[_0x30efda([0x6c,0x65,0x6e,0x67,0x74,0x68])]>=_0x35c886&&_0x3e0209();}_0x2f5155(),_0x2b941d[_0x30efda([0x6f,0x6e])](_0x30efda([0x61,0x64,0x64]),_0x2f5155);})),new window[(_0x30efda([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x358826=>{function _0x124d58(){for(const _0x59da24 in window)if(window[_0x30efda([0x4e,0x75,0x6d,0x62,0x65,0x72])]['isNaN'](window[_0x30efda([0x4e,0x75,0x6d,0x62,0x65,0x72])](_0x59da24))&&window[_0x59da24]==_0x47cd1f)return _0x358826();_0x1b9de3[_0x30efda([0x73,0x74,0x61,0x74,0x65])]!=_0x30efda([0x64,0x65,0x73,0x74,0x72,0x6f,0x79,0x65,0x64])&&window[_0x30efda([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x124d58,0x41eb8a3b^_0x4bbaf7);}_0x484062(_0x30efda([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))&&_0x124d58();})];return window[_0x30efda([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x30efda([0x72,0x61,0x63,0x65])](_0x4ced23)[_0x30efda([0x74,0x68,0x65,0x6e])](()=>_0x591b98);}async function _0x42839d(){if(await _0xb70054,_0x484062(_0x30efda([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))){const _0x55ae27=_0x22b0b9[_0x30efda([0x67,0x65,0x74,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](0x0),_0x27cfe9=_0x22b0b9[_0x30efda([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])](_0x55ae27[_0x30efda([0x69,0x64])]),_0x5f5bb4=_0xc0da89(_0x30efda([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]));return await _0x5f5bb4[_0x30efda([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])](_0x55ae27['id'],_0x27cfe9?_0x27cfe9['id']:null,!0x0),_0x5f5bb4[_0x30efda([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x30efda([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x5f5bb4[_0x30efda([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x5f5bb4[_0x30efda([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])]=_0x318bcf,void(_0x5f5bb4[_0x30efda([0x5f,0x67,0x65,0x74,0x44,0x69,0x66,0x66])]=_0x318bcf);}if(_0x484062(_0x30efda([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]))){const _0x1340ca=_0xc0da89(_0x30efda([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]));_0x1340ca[_0x30efda([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x30efda([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x1340ca[_0x30efda([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x1340ca[_0x30efda([0x75,0x70,0x64,0x61,0x74,0x65])]=_0x318bcf,_0x1340ca[_0x30efda([0x73,0x61,0x76,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])]=_0x318bcf;}_0x1b9de3[_0x30efda([0x6d,0x6f,0x64,0x65,0x6c])][_0x30efda([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x318bcf,_0x1b9de3[_0x30efda([0x6d,0x6f,0x64,0x65,0x6c])][_0x30efda([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x318bcf,_0x1b9de3[_0x30efda([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x30efda([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x458815(){return _0x484062(_0x30efda([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0xc0da89(_0x30efda([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x30efda([0x73,0x74,0x61,0x74,0x65])]==_0x30efda([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x666d3e(){return _0x484062(_0x30efda([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 _0x35a172(){return _0x484062(_0x30efda([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0x5d842e(_0xbb9630){const _0x57edf4=_0x1ed3a0();_0x1b9de3[_0x57edf4]=_0x30efda([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])+_0xbb9630,_0xbb9630[_0x30efda([0x65,0x6e,0x64,0x73,0x57,0x69,0x74,0x68])](_0x30efda([0x4c,0x69,0x6d,0x69,0x74]))&&(window[_0x1ed3a0()]=_0x47cd1f),_0xbb9630!=_0x30efda([0x56,0x61,0x6c,0x69,0x64])&&_0x42839d();}function _0x1ed3a0(){const _0x17b9e4=window[_0x30efda([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x30efda([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x30efda([0x6e,0x6f,0x77])]())[_0x30efda([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x30efda([0x2e]),'');let _0xacccd9=_0x30efda([0x6d]);for(let _0x42b1e1=0x0;_0x42b1e1<_0x17b9e4[_0x30efda([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x42b1e1+=0x2){let _0x13cdf1=window[_0x30efda([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x17b9e4[_0x30efda([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x42b1e1,_0x42b1e1+0x2));_0x13cdf1>=_0x537b2c[_0x30efda([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x13cdf1-=_0x537b2c[_0x30efda([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0xacccd9+=_0x537b2c[_0x13cdf1];}return _0xacccd9;}function _0x1922d7(){const _0x3e4b8a=_0x1e9771[_0x30efda([0x73,0x70,0x6c,0x69,0x74])](_0x30efda([0x2e]));if(0x3!=_0x3e4b8a[_0x30efda([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x192c77(_0x3e4b8a[0x1]);function _0x192c77(_0x228af6){const _0x34a0da=_0x2cef56(_0x228af6);return _0x34a0da&&_0x2e1718()?_0x34a0da:null;function _0x2e1718(){const _0x26f7c8=_0x34a0da[_0x30efda([0x6a,0x74,0x69])],_0x3604d9=window[_0x30efda([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x26f7c8[_0x30efda([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x26f7c8[_0x30efda([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x489d83={..._0x34a0da,[_0x30efda([0x6a,0x74,0x69])]:_0x26f7c8[_0x30efda([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x26f7c8[_0x30efda([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x489d83[_0x30efda([0x76,0x63])],_0x329db6(_0x489d83)==_0x3604d9;}}}async function _0x36f90f(){let _0x477d45=!0x0;try{const _0x1d8907=_0x1e9771[_0x30efda([0x73,0x70,0x6c,0x69,0x74])](_0x30efda([0x2e])),[_0x160e13,_0x39133b,_0x107a1b]=_0x1d8907;return _0xb7819e(_0x160e13),await _0x5417c3(_0x160e13,_0x39133b,_0x107a1b),_0x477d45;}catch(_0x33fa21){return!0x1;}function _0xb7819e(_0x8df2a3){const _0x46ad24=_0x2cef56(_0x8df2a3);_0x46ad24&&_0x46ad24[_0x30efda([0x61,0x6c,0x67])]==_0x30efda([0x45,0x53,0x32,0x35,0x36])||(_0x477d45=!0x1);}async function _0x5417c3(_0x596c09,_0x214d86,_0x4b578){const _0x4c910b=window[_0x30efda([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x30efda([0x66,0x72,0x6f,0x6d])](_0x20ccc2(_0x4b578),_0x443579=>_0x443579[_0x30efda([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0xde21f=new window[(_0x30efda([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x30efda([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x596c09+_0x30efda([0x2e])+_0x214d86),_0x33e9cc=window[_0x30efda([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x30efda([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x33e9cc)return;const _0x55410e=await _0x33e9cc[_0x30efda([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x30efda([0x6a,0x77,0x6b]),_0x21e0cb,{[_0x30efda([0x6e,0x61,0x6d,0x65])]:_0x30efda([0x45,0x43,0x44,0x53,0x41]),[_0x30efda([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x30efda([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x30efda([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x33e9cc[_0x30efda([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x30efda([0x6e,0x61,0x6d,0x65])]:_0x30efda([0x45,0x43,0x44,0x53,0x41]),[_0x30efda([0x68,0x61,0x73,0x68])]:{[_0x30efda([0x6e,0x61,0x6d,0x65])]:_0x30efda([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x55410e,_0x4c910b,_0xde21f)||(_0x477d45=!0x1);}}function _0x2cef56(_0x401837){return _0x401837[_0x30efda([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x30efda([0x65,0x79]))?JSON[_0x30efda([0x70,0x61,0x72,0x73,0x65])](_0x20ccc2(_0x401837)):null;}function _0x20ccc2(_0x55dacc){return window[_0x30efda([0x61,0x74,0x6f,0x62])](_0x55dacc[_0x30efda([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x30efda([0x2b]))[_0x30efda([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x30efda([0x2f])));}function _0x329db6(_0x174e40){let _0x2e0bef=0x1505;function _0x42466c(_0x51caf8){for(let _0x15cd5c=0x0;_0x15cd5c<_0x51caf8[_0x30efda([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x15cd5c++){const _0x371d93=_0x51caf8[_0x30efda([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x15cd5c);_0x2e0bef=(_0x2e0bef<<0x5)+_0x2e0bef+_0x371d93,_0x2e0bef&=_0x2e0bef;}}function _0x43eb24(_0x518bb5){Array[_0x30efda([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x518bb5)?_0x518bb5[_0x30efda([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x43eb24):_0x518bb5&&typeof _0x518bb5==_0x30efda([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x30efda([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x518bb5)[_0x30efda([0x73,0x6f,0x72,0x74])]()[_0x30efda([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x24ec8e,_0x463d6a])=>{_0x42466c(_0x24ec8e),_0x43eb24(_0x463d6a);}):_0x42466c(window[_0x30efda([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x518bb5));}return _0x43eb24(_0x174e40),_0x2e0bef>>>0x0;}function _0x31aafd(_0x33979c){return _0x33979c[_0x30efda([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x30efda([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x30efda([0x30]));}function _0x3acb4d(_0x29232d){return _0x29232d[_0x30efda([0x73,0x70,0x6c,0x69,0x74])]('')[_0x30efda([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x30efda([0x6a,0x6f,0x69,0x6e])]('');}function _0x484062(_0x1847eb){return _0x1b9de3[_0x30efda([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x30efda([0x68,0x61,0x73])](_0x1847eb);}function _0xc0da89(_0x5d77dc){return _0x1b9de3[_0x30efda([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x30efda([0x67,0x65,0x74])](_0x5d77dc);}function _0x318bcf(){}function _0x30efda(_0xb104a4){return _0xb104a4['map'](_0x1e475c=>String['fromCharCode'](_0x1e475c))['join']('');}_0x5d842e(await _0x18b881());}(this);}['createRevision'](_0x235389){const _0x4127d4=this['editor']['plugins']['get']('Users');return new h({'id':_0x235389['id'],'name':_0x235389['name'],'creator':_0x235389['creatorId']?_0x4127d4['getUser'](_0x235389['creatorId']):null,'diffData':_0x235389['diffData']||_0x235389['data'],'authors':_0x235389['authorsIds']['map'](_0x713c0=>_0x4127d4['getUser'](_0x713c0)),'createdAt':new Date(_0x235389['createdAt']),'attributes':_0x235389['attributes'],'fromVersion':_0x235389['fromVersion'],'toVersion':_0x235389['toVersion']});}['addRevision'](_0x4a80b5,_0x4f069d=0x0){this['_revisions']['add'](_0x4a80b5,_0x4f069d);}['getRevision'](_0x28567e){return this['_revisions']['get'](_0x28567e);}['getRevisions'](_0x32c835={'toJSON':!0x1}){const _0xc4d684=Array['from'](this['_revisions']);return _0xc4d684['reverse'](),_0x32c835['toJSON']?_0xc4d684['map'](_0x583a07=>_0x583a07['toJSON']()):_0xc4d684;}['getIndex'](_0x11f6a0){return this['_revisions']['getIndex'](_0x11f6a0);}['getEarlierVisibleRevision'](_0x33e26e){const [,_0x206ca3]=this['getRevisionsIterator'](_0x33e26e,{'direction':'earlier'});return _0x206ca3;}['getLaterVisibleRevision'](_0x390470){const [,_0x3917dc]=this['getRevisionsIterator'](_0x390470,{'direction':'later'});return _0x3917dc;}['getRevisionsInDiff'](_0x88599c){const _0x24831f=[];for(const _0x222fbe of this['getRevisionsIterator'](_0x88599c['newRevisionId']))if(_0x24831f['push'](_0x222fbe),_0x222fbe['id']===_0x88599c['oldRevisionId'])break;return _0x24831f;}*['getRevisionsIterator'](_0x3450a1,{direction:_0x37d935='earlier',filter:_0x17fff2=()=>!0x0}={}){const _0x1e8a65='earlier'===_0x37d935?0x1:-0x1;let _0x3f58db=this['_revisions']['get'](_0x3450a1),_0x7a8473=this['getIndex'](_0x3f58db);for(yield _0x3f58db;_0x3f58db;){if(_0x7a8473+=_0x1e8a65,_0x3f58db=this['getRevision'](_0x7a8473),!_0x3f58db)return;_0x17fff2(_0x3f58db)&&(yield _0x3f58db);}}}class V extends _0x3ba875{static get['pluginName'](){return'RevisionHistoryUtils';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['_viewClassToTypeChar']=new Map([[_0x4e0af3,'c'],[_0xfb9c57,'a'],[_0x4480bf,'e'],[_0x346d39,'r'],[_0x42c222,'u']]);['_typeCharToViewClass']=new Map([['c',_0x4e0af3],['a',_0xfb9c57],['e',_0x4480bf],['r',_0x346d39],['u',_0x42c222]]);async['loadRevisionData'](_0x3fb142,_0x55c8ab){if(_0x3fb142['diffData']||!_0x55c8ab)return;const _0x3ed88e=this['editor']['config']['get']('collaboration.channelId'),_0x1bad3f=await _0x55c8ab['getRevision']({'channelId':_0x3ed88e,'revisionId':_0x3fb142['id']});_0x3fb142['diffData']=_0x1bad3f['diffData'];}['getRevisionDocumentData'](_0x2c64ce){const _0x9ee63e={};for(const _0x346982 in _0x2c64ce['diffData']){if(_0x2c64ce['diffData'][_0x346982]['attachChange']&&!_0x2c64ce['diffData'][_0x346982]['attachChange']['isAttached'])continue;const _0x47636d=this['_removeRevisionMarkers'](JSON['parse'](_0x2c64ce['diffData'][_0x346982]['insertions'])),_0x43b8a3=this['editor']['editing']['view']['document'],_0x52a4ff=new _0x1852c8(_0x43b8a3,_0x47636d['map'](_0x4e0ed8=>this['_getViewFromDiffObj'](_0x4e0ed8,!0x1)));this['editor']['data']['processor']['useFillerType']('marked'),_0x9ee63e[_0x346982]=this['editor']['data']['processor']['toData'](_0x52a4ff),this['editor']['data']['processor']['useFillerType']('default');}return _0x9ee63e;}['getRevisionRootsAttributes'](_0x17cdf0){const _0x550b8c={};for(const _0x52a070 in _0x17cdf0['diffData'])_0x17cdf0['diffData'][_0x52a070]['attachChange']&&!_0x17cdf0['diffData'][_0x52a070]['attachChange']['isAttached']||(_0x550b8c[_0x52a070]=_0x17cdf0['diffData'][_0x52a070]['attributesAfter']||{});return _0x550b8c;}['_getTypeCharForViewElement'](_0x4884e6){return this['_viewClassToTypeChar']['get'](_0x4884e6['constructor']);}['_getViewFromDiffObj'](_0x804745,_0x29233d){const _0x524b39=this['editor']['editing']['view']['document'];if('string'==typeof _0x804745)return new _0x2f8706(_0x524b39,_0x804745);{let _0x50a09f,_0x4e9a2e;_0x4e9a2e='u'==_0x804745['type']||'r'==_0x804745['type']?[]:_0x804745['children']['map'](_0x189e69=>this['_getViewFromDiffObj'](_0x189e69,_0x29233d));const _0x4dc83c=this['_typeCharToViewClass']['get'](_0x804745['type'])||_0xfd25df,_0x3c4d05=this['editor']['data']['htmlProcessor']['domConverter'];if(_0x50a09f=new _0x4dc83c(_0x524b39,_0x804745['name'],_0x804745['attributes'],_0x4e9a2e),'u'==_0x804745['type']){const _0x574808=_0x804745['children'][0x0];if(_0x50a09f['render']=function(_0x2f5b82){const _0x45a57b=_0x2f5b82['createElement']('div');return _0x45a57b['innerHTML']=_0x574808,_0x45a57b['childNodes'][0x0];},_0x29233d){const _0x2f514e=new _0x1852c8(_0x524b39);_0x2f514e['_appendChild'](_0x50a09f);const _0xc8fbd5=Array['from'](_0x3c4d05['viewChildrenToDom'](_0x2f514e,{'bind':!0x1})),_0x30c4d7=_0x3c4d05['domDocument']['createElement']('div');_0x30c4d7['append'](..._0xc8fbd5),_0x50a09f=Array['from'](_0x3c4d05['domChildrenToView'](_0x30c4d7))[0x0];}}else{if('r'==_0x804745['type']){const _0x23d378=_0x804745['children'][0x0];if(_0x50a09f['render']=function(_0x569e3b){_0x569e3b['innerHTML']=_0x23d378;},_0x29233d){const _0x117a01=new _0x1852c8(_0x524b39);_0x117a01['_appendChild'](_0x50a09f);const _0x2628f6=Array['from'](_0x3c4d05['viewChildrenToDom'](_0x117a01,{'bind':!0x1})),_0x171c15=_0x3c4d05['domDocument']['createElement']('div');_0x171c15['append'](..._0x2628f6);const _0x46445c=Array['from'](_0x3c4d05['domChildrenToView'](_0x171c15));_0x46445c['length']>0x1?_0x50a09f['_appendChild'](_0x46445c):_0x50a09f=_0x46445c[0x0];}}}if(_0x804745['customProperties']){for(const [_0x21c84c,_0x30f452]of _0x804745['customProperties'])_0x50a09f['_setCustomProperty'](_0x21c84c,_0x30f452);}const _0x5430d2=_0x804745['fillerOffset']||null;return _0x50a09f['getFillerOffset']=()=>_0x5430d2,_0x50a09f;}}['_makeModelFromViewString'](_0x3d8b26){const _0x224ddd=JSON['parse'](_0x3d8b26),_0x2a4bca=this['editor']['editing']['view']['document'],_0x59e6f8=new _0x1852c8(_0x2a4bca,_0x224ddd['map'](_0x3fe5a5=>this['_getViewFromDiffObj'](_0x3fe5a5,!0x0)));return this['editor']['data']['toModel'](_0x59e6f8);}['_removeRevisionMarkers'](_0x3d7035){return(_0x3d7035=_0x3d7035['filter'](_0x42206e=>!_0x42206e['name']||'revision-start'!==_0x42206e['name']&&'revision-end'!==_0x42206e['name']))['forEach'](_0x2baaf5=>{'string'!=typeof _0x2baaf5&&(_0x2baaf5['children']=this['_removeRevisionMarkers'](_0x2baaf5['children']),_0x2baaf5['attributes']=_0x2baaf5['attributes']['filter'](_0x3df39b=>!_0x3df39b[0x0]['startsWith']('data-revision-')));}),_0x3d7035;}}function g(_0x4dcc87,_0x20fb40,_0x1b5a4d){const t=_0x4dcc87['t'];switch(_0x20fb40){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'},_0x1b5a4d);case'X_OF_Y_CHANGES':return t({'string':'%0\x20of\x20%1','id':'X_OF_Y_CHANGES'},_0x1b5a4d);case'Show\x20previous\x20change':return t('Show\x20previous\x20change');case'Show\x20next\x20change':return t('Show\x20next\x20change');case'EDIT_X_OF_Y_REVISIONS':return t({'string':'Edit','id':'EDIT_X_OF_Y_REVISIONS'});case'Total':return t('Total');case'Revision\x20creator':return t('Revision\x20creator');case'Revision\x20author':return t('Revision\x20author');case'Revision\x20name':return t('Revision\x20name');case'Save\x20current\x20revision':return t('Save\x20current\x20revision');case'Accept':return t('Accept');case'Save':return t('Save');case'Cancel':return t('Cancel');case'Name\x20of\x20the\x20revision':return t('Name\x20of\x20the\x20revision');case'optional':return t('optional');case'PENDING_ACTION_REVISION_HISTORY':return t({'string':'Unsaved\x20change\x20in\x20revision\x20history.','id':'PENDING_ACTION_REVISION_HISTORY'});case'The\x20revision\x20name\x20cannot\x20be\x20empty.':return t('The\x20revision\x20name\x20cannot\x20be\x20empty.');case'Enter\x20the\x20revision\x20name':return t('Enter\x20the\x20revision\x20name');default:return'';}}class u extends _0x3ba875{['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[_0x1b8b11,I,V,_0x25252b];}constructor(_0x276d8a){super(_0x276d8a),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 _0x157a42=_0x58b8ff();this['_source']={'history':this['editor']['model']['document']['history'],'getLatestVersion':()=>Promise['resolve'](this['editor']['model']['document']['version']),'getCurrentRevisionId':()=>_0x157a42},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 _0x2435a3=this['repository']['getRevision'](0x0),_0x470489=_0x2435a3&&null===_0x2435a3['creator']?_0x2435a3:null;if(this['_continueCurrentRevision']=!!_0x470489&&this['editor']['config']['get']('revisionHistory.resumeUnsavedRevision'),this['editor']['plugins']['has']('RealTimeCollaborationClient')){const _0x5c0b9e=this['_source']['getCurrentRevisionId'](),_0x55fa3d=this['repository']['getRevision'](_0x5c0b9e);if(_0x55fa3d)this['_startingVersion']=_0x55fa3d['fromVersion'],this['_continueCurrentRevision']=!0x1;else{const _0x2d35c7=this['_source']['history']['_operations']['find'](_0x499fbd=>!_0x499fbd['_isInit']),_0x4538a7=_0x2d35c7?_0x2d35c7['baseVersion']:this['_source']['history']['version'];_0x2435a3?(_0x2435a3['toVersion']<_0x4538a7&&_0x2435a3['_update']({'toVersion':_0x4538a7}),this['_continueCurrentRevision']?(this['_source']['getCurrentRevisionId']=()=>_0x470489['id'],this['_startingVersion']=_0x470489['fromVersion']):(this['_startingVersion']=_0x2435a3['toVersion'],this['_continueCurrentRevision']=!0x1)):(this['_startingVersion']=_0x4538a7,this['_continueCurrentRevision']=!0x1);}}else _0x470489&&(this['editor']['model']['document']['history']['version']=Math['max'](_0x470489['toVersion'],this['editor']['model']['document']['history']['version']),_0x470489['fromVersion']===_0x470489['toVersion']?(0x0!==_0x470489['fromVersion']&&(this['_source']['getCurrentRevisionId']=()=>_0x470489['id']),this['_continueCurrentRevision']=!0x1):this['_continueCurrentRevision']&&(this['_source']['getCurrentRevisionId']=()=>_0x470489['id'],this['_startingVersion']=_0x470489['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',_0x11e5aa=>!_0x11e5aa),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x4ce330=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x2e9074;for(const _0x1e6996 in _0x4ce330){const _0x5bc3e8=_0x1e6996,_0x2983d7=_0x4ce330[_0x5bc3e8];if('revisionHistoryLicenseKeyValid'==_0x2983d7||'revisionHistoryLicenseKeyInvalid'==_0x2983d7||'revisionHistoryLicenseKeyExpired'==_0x2983d7||'revisionHistoryLicenseKeyDomainLimit'==_0x2983d7||'revisionHistoryLicenseKeyNotAllowed'==_0x2983d7||'revisionHistoryLicenseKeyEvaluationLimit'==_0x2983d7||'revisionHistoryLicenseKeyTrialLimit'==_0x2983d7||'revisionHistoryLicenseKeyUsageLimit'==_0x2983d7){delete _0x4ce330[_0x5bc3e8],_0x2e9074=_0x2983d7,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'revisionHistoryLicenseKeyInvalid'==_0x2e9074&&_0x4ce330['_showLicenseError']('invalid'),'revisionHistoryLicenseKeyExpired'==_0x2e9074&&_0x4ce330['_showLicenseError']('expired'),'revisionHistoryLicenseKeyDomainLimit'==_0x2e9074&&_0x4ce330['_showLicenseError']('domainLimit'),'revisionHistoryLicenseKeyNotAllowed'==_0x2e9074&&_0x4ce330['_showLicenseError']('featureNotAllowed','RevisionHistory'),'revisionHistoryLicenseKeyEvaluationLimit'==_0x2e9074&&_0x4ce330['_showLicenseError']('evaluationLimit'),'revisionHistoryLicenseKeyTrialLimit'==_0x2e9074&&_0x4ce330['_showLicenseError']('trialLimit'),'revisionHistoryLicenseKeyUsageLimit'==_0x2e9074&&_0x4ce330['_showLicenseError']('usageLimit');},0x3e8);}async['afterInit'](){if(this['repository']['length']>0x0){const _0x4e2344=this['repository']['getRevision'](0x0),_0x4c892d=await this['getRevisionDocumentData'](_0x4e2344),_0x542c31=await this['getRevisionRootsAttributes'](_0x4e2344);this['_replaceEditorDataWithRevisionData'](_0x4c892d,_0x542c31);}}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['setSource'](_0x2c27ef){this['_source']=_0x2c27ef;}async['update'](){const _0x17863e=await this['_source']['getLatestVersion']();if(_0x17863e>this['currentRevision']['toVersion']){await this['_loadState']();const _0x19d794=this['buildRevisionData']({'revision':this['currentRevision'],'to':_0x17863e});_0x19d794['authors']=_0x19d794['authorsIds']['map'](_0xb7c27=>this['editor']['plugins']['get']('Users')['getUser'](_0xb7c27)),this['currentRevision']['_update'](_0x19d794);}}async['saveRevision'](_0x4a68d9={},_0x5841cf=null){const _0x28061c=[];await this['_loadState'](),this['_continueCurrentRevision']=!0x1,_0x5841cf>this['currentRevision']['toVersion']&&(_0x5841cf=null),null===_0x5841cf&&(_0x5841cf=await this['_source']['getLatestVersion']());const _0x27afed=this['_getFromVersion'](_0x5841cf),_0x8b204e=this['buildRevisionData']({'from':_0x27afed,'to':_0x5841cf});if(this['currentRevision']['toVersion']<_0x5841cf){const _0x1882e6=this['buildRevisionData']({'revision':this['currentRevision'],'from':_0x5841cf,'to':_0x5841cf});_0x1882e6['authors']=[],_0x1882e6['authorsIds']=[],_0x1882e6['id']=this['currentRevision']['id'],this['currentRevision']['_update'](_0x1882e6,!0x0),delete _0x1882e6['authors'],_0x28061c['push'](_0x1882e6);}_0x4a68d9['creatorId']=this['editor']['plugins']['get']('Users')['me']['id'],_0x4a68d9['name']=_0x4a68d9['name']||null,_0x4a68d9['id']=_0x4a68d9['id']||_0x58b8ff(),_0x4a68d9={..._0x4a68d9,..._0x8b204e};const _0x483b4b=this['addRevisionData'](_0x4a68d9);_0x28061c['push'](_0x4a68d9);const _0x5699e6=this['repository']['getIndex'](_0x483b4b);if(0x0!==_0x5699e6){const _0x55e8ea=this['repository']['getRevision'](_0x5699e6-0x1);if(_0x55e8ea['fromVersion']!==_0x5841cf){const _0x81ab04=this['_revisionDataBuilder']['getData'](_0x5841cf,_0x55e8ea['toVersion']),_0x3065f2={'id':_0x55e8ea['id'],'diffData':_0x81ab04['diffData'],'authorsIds':_0x81ab04['authorsIds'],'authors':_0x81ab04['authorsIds']['map'](_0x3f5d16=>this['editor']['plugins']['get']('Users')['getUser'](_0x3f5d16)),'fromVersion':_0x5841cf};_0x55e8ea===this['currentRevision']&&(_0x3065f2['createdAt']=new Date(_0x4a68d9['createdAt']['getTime']()+0xa)),_0x55e8ea['_update'](_0x3065f2,!0x0),delete _0x3065f2['authors'],_0x28061c['push'](_0x3065f2);}}if(this['adapter']){for(const _0x2a84ff of _0x28061c)this['_bufferUpdate'](_0x2a84ff['id'],_0x2a84ff,!0x0);this['sendBufferedUpdates']();}return _0x483b4b;}['addRevisionData'](_0x335146){const _0xd9f753=this['repository']['createRevision'](_0x335146);return this['adapter']&&_0xd9f753['on']('_update',(_0x2f4e5e,_0x3753e0,_0x518e2a)=>{_0x518e2a||(this['_bufferUpdate'](_0x3753e0['id'],_0x3753e0,!0x0),this['sendBufferedUpdates']());}),this['repository']['addRevision'](_0xd9f753,this['_findInsertionIndex'](_0xd9f753)),_0xd9f753;}async['getRevisionDocumentData'](_0x1c2f2d){return await this['_utils']['loadRevisionData'](_0x1c2f2d,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x1c2f2d);}async['getRevisionRootsAttributes'](_0x9b1d6b){return await this['_utils']['loadRevisionData'](_0x9b1d6b,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x9b1d6b);}['sendBufferedUpdates'](){if(0x0===this['_bufferedUpdates']['size'])return;if(this['_isPendingUpdate'])return;let _0x1dee34=Array['from'](this['_bufferedUpdates']['values']());this['_bufferedUpdates']['clear']();for(let _0x4cf0f1=0x0;_0x4cf0f1<_0x1dee34['length'];_0x4cf0f1++){const _0x26bc01=_0x1dee34[_0x4cf0f1];let _0x295cb9=!0x1;for(const _0x4722f8 of Object['keys'](_0x26bc01))void 0x0===_0x26bc01[_0x4722f8]?delete _0x26bc01[_0x4722f8]:'id'!==_0x4722f8&&(_0x295cb9=!0x0);_0x295cb9||(_0x1dee34[_0x4cf0f1]=null);}if(_0x1dee34=_0x1dee34['filter'](_0x49e579=>null!==_0x49e579),!_0x1dee34['length'])return;for(let _0x24ae4f=0x0;_0x24ae4f<_0x1dee34['length'];_0x24ae4f++){const _0x9ba915=_0x1dee34[_0x24ae4f];void 0x0!==_0x9ba915['fromVersion']&&void 0x0===_0x9ba915['toVersion']&&(_0x9ba915['toVersion']=this['repository']['getRevision'](_0x9ba915['id'])['toVersion']),void 0x0!==_0x9ba915['toVersion']&&void 0x0===_0x9ba915['fromVersion']&&(_0x9ba915['fromVersion']=this['repository']['getRevision'](_0x9ba915['id'])['fromVersion']);}const _0x1e00b2=this['editor']['config']['get']('collaboration.channelId');this['_isPendingUpdate']=!0x0,this['_addPendingAction'](),this['adapter']['updateRevisions'](_0x1dee34,_0x1e00b2)['finally'](()=>{this['_isPendingUpdate']=!0x1;})['then'](_0x48e0fc=>{if(_0x48e0fc){for(const _0x91599f of _0x48e0fc)this['setRevisionData']({'id':_0x91599f['id'],'createdAt':_0x91599f['createdAt']});}this['_removePendingAction'](),this['sendBufferedUpdates']();});}['buildRevisionData']({revision:_0x14f3bc=null,from:_0x4dc8c3=null,to:_0x55751e=null}){_0x4dc8c3=null!==_0x4dc8c3?_0x4dc8c3:_0x14f3bc['fromVersion'],_0x55751e=null!==_0x55751e?_0x55751e:_0x14f3bc['toVersion'];const _0x156dca=this['_revisionDataBuilder']['getData'](_0x4dc8c3,_0x55751e),_0xba55be={'diffData':_0x156dca['diffData'],'authorsIds':_0x156dca['authorsIds'],'fromVersion':_0x4dc8c3,'toVersion':_0x55751e};if(!_0x14f3bc||_0x55751e!==_0x14f3bc['toVersion']){const _0x36ebc3=_0x55751e-0x1,_0x3da5af=this['_source']['history']['getOperation'](_0x36ebc3);_0xba55be['createdAt']=_0x3da5af&&_0x3da5af['createdAt']||new Date();}if(this['_loadedStateData']&&_0x4dc8c3===this['_loadedStateData']['fromVersion']){for(const _0x3c65c3 of this['_loadedStateData']['authors'])_0xba55be['authorsIds']['includes'](_0x3c65c3['id'])||_0xba55be['authorsIds']['push'](_0x3c65c3['id']);}return _0xba55be;}['_bufferUpdate'](_0x4a562e,_0x102bbf,_0x2b7bae){if(this['_bufferedUpdates']['has'](_0x4a562e)){const _0x18b50b=this['_bufferedUpdates']['get'](_0x4a562e);_0x102bbf=_0x2b7bae?{..._0x18b50b,..._0x102bbf}:{..._0x102bbf,..._0x18b50b};}this['_bufferedUpdates']['set'](_0x4a562e,_0x102bbf);}['setRevisionData'](_0x178f56){const _0x2f2f2c=this['repository']['getRevision'](_0x178f56['id']);if(_0x178f56['createdAt']&&(_0x178f56['createdAt']=new Date(_0x178f56['createdAt'])),_0x178f56['authorsIds']){const _0x508f0f=this['editor']['plugins']['get']('Users');_0x178f56['authors']=_0x178f56['authorsIds']['map'](_0x3b0bfe=>_0x508f0f['getUser'](_0x3b0bfe));}_0x2f2f2c['_update'](_0x178f56,!0x0);}['_createInitialRevision'](_0x3ee5d4){const _0x32b398=this['repository']['getRevision'](this['repository']['length']-0x1);if(_0x32b398)this['_initialRevisionId']=_0x32b398['id'];else{const _0x316e4c=!this['editor']['model']['document']['roots']['find'](_0x5c47cc=>this['editor']['model']['hasContent'](_0x5c47cc)),_0x4a702b=this['editor']['plugins']['get']('Users')['me']['id'],_0x1e2852=g(this['editor']['locale'],_0x316e4c?'Empty\x20document':'Initial\x20revision');this['_makeRevision']({'from':_0x3ee5d4,'to':_0x3ee5d4,'id':this['_initialRevisionId'],'name':_0x1e2852,'creatorId':_0x4a702b});}}['_createCurrentRevision'](_0x20112b){const _0x29aa2a=this['_source']['getCurrentRevisionId']();this['currentRevision']=this['repository']['getRevision'](_0x29aa2a),this['currentRevision']||(this['currentRevision']=this['_makeRevision']({'from':_0x20112b,'to':_0x20112b,'id':_0x29aa2a,'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'](_0x49a180,_0x1cb9cc){let _0x344953=this['editor']['config']['get']('initialData'),_0x296459=this['editor']['config']['get']('rootsAttributes');if(void 0x0===_0x344953){_0x344953={};for(const _0x1c0a09 of this['editor']['model']['document']['getRootNames']())_0x344953[_0x1c0a09]='';}if('string'==typeof _0x344953&&(_0x344953={'main':_0x344953}),void 0x0===_0x296459){_0x296459={};for(const _0x46ab17 of this['editor']['model']['document']['getRootNames']())_0x296459[_0x46ab17]={};}let _0x2f06fa=!0x1;const _0x325169=Object['keys'](_0x344953),_0x19ff07=Object['keys'](_0x49a180);for(const _0x1edff9 of _0x325169){if(_0x344953[_0x1edff9]!==_0x49a180[_0x1edff9]&&''!==_0x344953[_0x1edff9]['trim']()){_0x2f06fa=!0x0;break;}if(!_0x7a304c(_0x296459[_0x1edff9],_0x1cb9cc[_0x1edff9])&&Object['keys'](_0x296459[_0x1edff9])['length']>0x0){_0x2f06fa=!0x0;break;}}_0x2f06fa||(_0x2f06fa=_0x19ff07['some'](_0x518572=>!this['editor']['model']['document']['getRoot'](_0x518572))),_0x2f06fa&&_0xf43310('editor-initial-data-replaced-with-revision-data',{'editorData':_0x344953,'editorRootsAttributes':_0x296459,'revisionData':_0x49a180,'revisionRootsAttributes':_0x1cb9cc}),this['editor']['config']['set']('initialData',_0x49a180),this['editor']['config']['set']('rootsAttributes',_0x1cb9cc);}['_addPendingAction'](){if(!this['_pendingAction']){const _0x4a046f=this['editor']['plugins']['get']('PendingActions');this['_pendingAction']=_0x4a046f['add'](g(this['editor']['locale'],'PENDING_ACTION_REVISION_HISTORY'));}}['_removePendingAction'](){this['_pendingAction']&&(this['editor']['plugins']['get']('PendingActions')['remove'](this['_pendingAction']),this['_pendingAction']=null);}['_findInsertionIndex'](_0x59d5bd){const _0x11150c=this['repository']['getRevisions']();_0x11150c['reverse']();let _0x10d197=0x0;for(;_0x10d197<_0x11150c['length'];){const _0x12996f=_0x11150c[_0x10d197];if(_0x12996f===this['currentRevision']){_0x10d197++;continue;}if(_0x12996f['id']===this['_initialRevisionId'])break;const _0x4fedd9=_0x59d5bd['toVersion']-_0x12996f['toVersion']||_0x59d5bd['fromVersion']-_0x12996f['fromVersion'];if(_0x4fedd9>0x0)break;if(_0x4fedd9<0x0)_0x10d197++;else{if(!_0x59d5bd['creator']&&_0x12996f['creator'])break;if(_0x12996f['creator']||!_0x59d5bd['creator']){if(_0x59d5bd['createdAt']>_0x12996f['createdAt'])break;_0x10d197++;}else _0x10d197++;}}return _0x10d197;}['_getFromVersion'](_0x5d00e5){const _0x2fe966=this['repository']['getRevisions']();_0x2fe966['reverse'](),_0x2fe966['shift']();const _0x3da049=_0x2fe966['find'](_0x3d1b33=>_0x3d1b33['toVersion']<=_0x5d00e5)['toVersion'];return _0x3da049<this['_startingVersion']?this['_startingVersion']:_0x3da049;}['_makeRevision']({name:_0x156efe,from:_0x484c58,to:_0x535877,creatorId:_0x458bca,id:_0x41fed6}){const _0x4ef63f=this['buildRevisionData']({'from':_0x484c58,'to':_0x535877});_0x4ef63f['name']=_0x156efe,_0x4ef63f['creatorId']=_0x458bca,_0x4ef63f['id']=_0x41fed6;const _0x5efd79=this['addRevisionData'](_0x4ef63f);return this['adapter']&&this['_bufferUpdate'](_0x4ef63f['id'],_0x4ef63f,!0x0),_0x5efd79;}['_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(_0x17da37){this['editor']=_0x17da37,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'](_0x56c612){this['source']=_0x56c612;const _0x3068b7=new Map(),_0x2a7dca=new Map(),_0x1bd84a=this['editor']['model']['document']['roots']['map'](_0xb079f6=>_0xb079f6['rootName']);for(const _0x1f070d of _0x1bd84a){const _0x1da0ad=this['editor']['model']['document']['getRoot'](_0x1f070d),_0x57a568=N(_0x1da0ad);_0x3068b7['set'](_0x1f070d,_0x57a568),_0x2a7dca['set'](_0x1f070d,Object['fromEntries'](_0x1da0ad['getAttributes']()));}const _0x1c2812=Array['from'](this['editor']['model']['markers'])['map'](_0xd5b215=>[_0xd5b215['name'],_0xd5b215['getRange']()]),_0x53bfd3=this['source']['version'];this['_saveMetaData'](_0x53bfd3,_0x3068b7,_0x1c2812,_0x2a7dca),this['_startingRevisionId']=this['_revisionId'];const _0x2c9b17=new Map(),_0xa2bfee=new Map();for(const _0x58fda0 of _0x1bd84a){const _0x5c5561=P(_0x58fda0);_0x2c9b17['set'](_0x58fda0,_0x5c5561),_0xa2bfee['set'](_0x58fda0,{});}this['_saveMetaData'](Number['NEGATIVE_INFINITY'],_0x2c9b17,[],_0xa2bfee);}['getData'](_0x5e9a03,_0x28b9bd){if(this['_lastFrom']===_0x5e9a03&&this['_lastTo']<=_0x28b9bd)this['_savedMetaData']['size']>0x1&&this['_removeMetaData'](this['_lastTo']),this['_applyOperations'](this['_lastTo'],_0x28b9bd,!0x0);else{if(!this['_savedMetaData']['has'](_0x5e9a03)){const _0x549e60=this['_getPreviousFrom'](_0x5e9a03);this['_calculateMetaData'](_0x549e60,_0x5e9a03,!0x1);}this['_calculateMetaData'](_0x5e9a03,_0x28b9bd,!0x0);}return this['_lastFrom']=_0x5e9a03,this['_lastTo']=_0x28b9bd,this['_getState']();}['loadState'](_0x4b3b18){const _0xacb9ac=this['editor']['plugins']['get']('RevisionHistoryUtils');this['_reset'](),this['_lastFrom']=_0x4b3b18['fromVersion'],this['_lastTo']=_0x4b3b18['toVersion'];for(const _0x4e0357 in _0x4b3b18['diffData']){const _0x49c3f6=_0x4b3b18['diffData'][_0x4e0357]['attachChange'],_0x3e1de3=_0x291809(_0x4b3b18['diffData'][_0x4e0357]['attributesBefore'])||{},_0x47bd55=_0xacb9ac['_makeModelFromViewString'](_0x4b3b18['diffData'][_0x4e0357]['deletions']);_0x47bd55['rootName']=_0x4e0357,_0x47bd55['_isAttached']=!_0x49c3f6||!_0x49c3f6['isAttached'],_0x47bd55['isAttached']=()=>_0x47bd55['_isAttached'],this['_baseRoots']['set'](_0x4e0357,_0x47bd55),this['_baseRootsAttributes']['set'](_0x4e0357,_0x3e1de3),_0x49c3f6&&this['_touchedRoots']['set'](_0x4e0357,_0x49c3f6);const _0x171d3e=this['_makeIdsRoot'](_0x47bd55);this['_baseIdsRoots']['set'](_0x4e0357,_0x171d3e);for(const [_0x2a56eb,_0x37455b]of _0x47bd55['markers']){if(!_0x2a56eb['startsWith']('revision:'))continue;const _0x30bbff=_0x2a56eb['split'](':')[0x2];for(const _0x3b3923 of _0x37455b['getWalker']({'singleCharacters':!0x0})){const _0x2b7cc4=this['_getVidAttributeName'](_0x3b3923),_0x3ceb2c='elementEnd'==_0x3b3923['type']?_0x3b3923['previousPosition']['path']['slice'](0x0,-0x1):_0x3b3923['previousPosition']['path'],_0x50656d=_0x171d3e['getNodeByPath'](_0x3ceb2c)['getAttribute'](_0x2b7cc4);this['_touched']['set'](_0x50656d,{'userId':_0x30bbff});}}}this['_startingRevisionId']=this['_revisionId'];const _0xf112d7=[...Array(this['_revisionId'])['keys']()]['slice'](0x1)['filter'](_0x322a4a=>!this['_touched']['has'](_0x322a4a));let _0x5b3a52=0x0;const _0x1bd8f9=new Map();for(const _0x17cade in _0x4b3b18['diffData']){const _0x182d66=_0x4b3b18['diffData'][_0x17cade]['attachChange'],_0x476778=_0x291809(_0x4b3b18['diffData'][_0x17cade]['attributesAfter'])||{},_0x58a02e=_0xacb9ac['_makeModelFromViewString'](_0x4b3b18['diffData'][_0x17cade]['insertions']);_0x58a02e['rootName']=_0x17cade,_0x58a02e['_isAttached']=!_0x182d66||_0x182d66['isAttached'],_0x58a02e['isAttached']=()=>_0x58a02e['_isAttached'],this['_diffRoots']['set'](_0x17cade,_0x58a02e),this['_diffRootsAttributes']['set'](_0x17cade,_0x476778);const _0x55dbd9=this['_makeIdsRoot'](_0x58a02e,Number['NEGATIVE_INFINITY']);this['_idsRoots']['set'](_0x17cade,_0x55dbd9),_0x1bd8f9['set'](_0x17cade,_0x58a02e['isAttached']()?_0x476778:{});for(const [_0x364918,_0x4984f8]of _0x58a02e['markers']){if(!_0x364918['startsWith']('revision:'))continue;const _0x3f9eb5=_0x364918['split'](':')[0x2];for(const _0xa5e318 of _0x4984f8['getWalker']({'singleCharacters':!0x0})){const _0x47b87e=this['_getVidAttributeName'](_0xa5e318),_0xdc23bb=this['_revisionId']++,_0x424b54='elementEnd'==_0xa5e318['type']?_0xa5e318['previousPosition']['path']['slice'](0x0,-0x1):_0xa5e318['previousPosition']['path'];_0x55dbd9['getNodeByPath'](_0x424b54)['_setAttribute'](_0x47b87e,_0xdc23bb),this['_touched']['set'](_0xdc23bb,{'userId':_0x3f9eb5});}}for(const _0x4ee11a of this['editor']['model']['createRangeIn'](_0x58a02e)['getWalker']({'singleCharacters':!0x0})){const _0x5488a9=this['_getVidAttributeName'](_0x4ee11a),_0x588f7b='elementEnd'==_0x4ee11a['type']?_0x4ee11a['previousPosition']['path']['slice'](0x0,-0x1):_0x4ee11a['previousPosition']['path'],_0x1baba2=_0x55dbd9['getNodeByPath'](_0x588f7b);_0x1baba2['getAttribute'](_0x5488a9)>0x0||_0x1baba2['_setAttribute'](_0x5488a9,_0xf112d7[_0x5b3a52++]);}for(const [_0x8e9622,_0x39f0a6]of _0x58a02e['markers'])_0x8e9622['startsWith']('revision:')||this['_markers']['set'](_0x8e9622,_0x39f0a6);}const _0xf502d3=P('$graveyard');this['_baseRoots']['set']('$graveyard',_0xf502d3),this['_baseIdsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0xf502d3,0x1));const _0x17ef2f=P('$graveyard');this['_diffRoots']['set']('$graveyard',_0x17ef2f),this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x17ef2f,0x1));const _0x594b7d=Array['from'](this['_diffRoots'])['map'](([_0x1f2b2a,_0x1ba7f3])=>[_0x1f2b2a,N(_0x1ba7f3)]);this['_saveMetaData'](this['_lastTo'],_0x594b7d,this['_markers'],_0x1bd8f9);}['reInit'](){this['_reset'](),this['_lastFrom']=-0x1,this['_lastTo']=-0x1,this['_savedMetaData']['clear'](),this['init'](this['source']);}['_saveMetaData'](_0x4a9d11,_0x33b8ea,_0xafcbdd,_0x1affe4){const _0x23609a=new Map(_0x33b8ea),_0x43b58e=new Map(_0x291809(_0x1affe4)),_0x5ce51a=new Map();for(const [_0x11f987,_0x362c55]of _0xafcbdd)_0x5ce51a['set'](_0x11f987,{'start':_0x362c55['start']['clone'](),'end':_0x362c55['end']['clone'](),'rootName':_0x362c55['root']['rootName']});this['_savedMetaData']['set'](_0x4a9d11,{'roots':_0x23609a,'markers':_0x5ce51a,'rootsAttributes':_0x43b58e});}['_removeMetaData'](_0x33c58d){this['_savedMetaData']['delete'](_0x33c58d);}['_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'](_0x3c7d4c,_0x2f56c0=null){let _0x393dbd=null;_0x3c7d4c['is']('documentFragment')||(_0x393dbd=new ut(_0x3c7d4c['name'],{'vid_start':null===_0x2f56c0?this['_revisionId']++:_0x2f56c0++}));const _0x507f3f=[];for(const _0x3a54fd of _0x3c7d4c['getChildren']())if(_0x3a54fd['is']('element')){_0x507f3f['push'](this['_makeIdsRoot'](_0x3a54fd,_0x2f56c0));const _0xbd1282=_0x507f3f[_0x507f3f['length']-0x1];null!==_0x2f56c0&&(_0x2f56c0=_0xbd1282['is']('element','$text')?_0xbd1282['getAttribute']('vid')+0x1:_0xbd1282['getAttribute']('vid_end')+0x1);}else{for(let _0x442e98=0x0;_0x442e98<_0x3a54fd['offsetSize'];_0x442e98++)_0x507f3f['push'](new ut('$text',{'vid':null===_0x2f56c0?this['_revisionId']++:_0x2f56c0++}));}if(_0x3c7d4c['is']('documentFragment')){const _0x31af24=P(_0x3c7d4c['rootName']);return _0x31af24['_insertChild'](0x0,_0x507f3f),_0x31af24;}return _0x393dbd['_setAttribute']('vid_end',null===_0x2f56c0?this['_revisionId']++:_0x2f56c0++),_0x393dbd['_insertChild'](0x0,_0x507f3f),_0x393dbd;}['_calculateMetaData'](_0x4369ca,_0x3ca5de,_0x414f00){this['_reset']();const {roots:_0x4d62b5,markers:_0x2c4653,rootsAttributes:_0x48922b}=this['_savedMetaData']['get'](_0x4369ca);this['_baseRoots']=new Map(_0x4d62b5),this['_baseRootsAttributes']=new Map(_0x291809(_0x48922b));for(const [_0x39f324,_0x38cef4]of this['_baseRoots'])if('$graveyard'!==_0x39f324&&(this['_diffRoots']['set'](_0x39f324,N(_0x38cef4)),this['_diffRootsAttributes']=new Map(_0x291809(_0x48922b)),_0x414f00)){const _0x2d8d39=this['_revisionId'];this['_idsRoots']['set'](_0x39f324,this['_makeIdsRoot'](_0x38cef4)),this['_baseIdsRoots']['set'](_0x39f324,this['_makeIdsRoot'](_0x38cef4,_0x2d8d39));}this['_startingRevisionId']=this['_revisionId'],this['_diffRoots']['set']('$graveyard',N(this['_baseRoots']['get']('$graveyard'))),_0x414f00&&this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](this['_baseRoots']['get']('$graveyard')));for(const [_0x2c9a1b,_0x59880d]of _0x2c4653){const _0x2dc2f8=this['_baseRoots']['get'](_0x59880d['rootName']),_0x2f810e=this['_diffRoots']['get'](_0x59880d['rootName']),_0x1812fc=new ft(this['_fixPosition'](_0x59880d['start'],_0x2dc2f8),this['_fixPosition'](_0x59880d['end'],_0x2dc2f8)),_0x1c52a3=this['_fixRange'](_0x1812fc,_0x2f810e);_0x2dc2f8['markers']['set'](_0x2c9a1b,_0x1812fc),this['_markers']['set'](_0x2c9a1b,_0x1c52a3);}this['_applyOperations'](_0x4369ca,_0x3ca5de,_0x414f00);}['_applyOperations'](_0x15d43f,_0x5049c8,_0x566cd6){for(const _0x4c8ff8 of this['source']['getOperations'](_0x15d43f,_0x5049c8))this['_handleOperation'](_0x4c8ff8,_0x566cd6);for(const _0x20e58d of this['_diffRoots']['values']())_0x20e58d['markers']['clear']();for(const [_0x5cb7de,_0xe9a8e8]of this['_markers']){this['_diffRoots']['get'](_0xe9a8e8['root']['rootName'])['markers']['set'](_0x5cb7de,_0xe9a8e8['clone']());}const _0x59a09a=new Map(),_0x4432e2=new Map();for(const [_0x2b90fd,_0x28b034]of this['_diffRoots'])_0x59a09a['set'](_0x2b90fd,N(_0x28b034)),_0x4432e2['set'](_0x2b90fd,this['_diffRootsAttributes']['get'](_0x2b90fd));this['_saveMetaData'](_0x5049c8,_0x59a09a,this['_markers'],_0x4432e2);}['_getPreviousFrom'](_0x3708d4){const _0x52e726=Array['from'](this['_savedMetaData']['keys']());_0x52e726['sort']((_0x1b2d3e,_0x427564)=>_0x1b2d3e-_0x427564),_0x52e726['reverse']();for(const _0x111aa1 of _0x52e726)if(_0x111aa1<_0x3708d4)return _0x111aa1;return Number['NEGATIVE_INFINITY'];}['_copyMarkers'](_0x27f878,_0x23ac67){const _0x32be9d=Array['from'](_0x23ac67['markers'])['map'](([_0x34e852,_0x5a727d])=>[_0x34e852,this['_fixRange'](_0x5a727d,_0x27f878)]);_0x27f878['markers']=new Map(_0x32be9d);}['_transformMarkers'](_0x7d139f){for(const _0x556f01 of this['_markers']['values']()){const _0x30e481=_0x556f01['getTransformedByOperation'](_0x7d139f),_0x341383=ft['_createFromRanges'](_0x30e481);_0x556f01['start']=_0x341383['start'],_0x556f01['end']=_0x341383['end'];}}['_handleOperation'](_0x5f1894,_0x4583a0){if('addRoot'!=_0x5f1894['type']&&'detachRoot'!=_0x5f1894['type']){if('insert'==_0x5f1894['type']){const _0x5e291f=_0x5f1894['position']['root']['rootName'];this['_diffRoots']['has'](_0x5e291f)||(this['_diffRoots']['set'](_0x5e291f,P(_0x5e291f,!0x0)),this['_diffRootsAttributes']['set'](_0x5e291f,{}),_0x4583a0&&this['_idsRoots']['set'](_0x5e291f,P(_0x5e291f,!0x0)));}else{if('addRootAttribute'==_0x5f1894['type']||'removeRootAttribute'==_0x5f1894['type']||'changeRootAttribute'==_0x5f1894['type'])return void this['_handleRootAttributeOperation'](_0x5f1894);'marker'==_0x5f1894['type']&&this['_handleMarkerOperation'](_0x5f1894);}if('marker'!==_0x5f1894['type']){const _0x1bd455=this['_cloneOperation'](_0x5f1894,this['_diffRoots']);_0x1bd455['_execute'](),this['_transformMarkers'](_0x1bd455);}if(_0x4583a0)switch(_0x5f1894['type']){case'insert':this['_handleInsertOperation'](_0x5f1894);break;case'move':case'remove':case'reinsert':this['_handleMoveOperation'](_0x5f1894);break;case'merge':this['_handleMergeOperation'](_0x5f1894);break;case'split':this['_handleSplitOperation'](_0x5f1894);}}else this['_handleRootOperation'](_0x5f1894,_0x4583a0);}['_cloneOperation'](_0x543e1d,_0x1d1b24){const _0x2b8870=_0x543e1d['clone']();return _0x2b8870['_authorId']=_0x543e1d['_authorId'],this['_fixOperation'](_0x2b8870,_0x1d1b24),_0x2b8870;}['_getBaseVids'](_0x4dc8fa){return _0x4dc8fa['map'](_0x30913c=>{const _0x3d6e27=this['_getVidAttributeName'](_0x30913c);return Number(_0x30913c['item']['getAttribute'](_0x3d6e27));});}['_generateTape'](_0x140813,_0x36f3d7){if(_0x140813['is']('element','$text'))_0x36f3d7['push']({'item':_0x140813,'type':'text'});else{_0x140813['is']('element')&&_0x36f3d7['push']({'item':_0x140813,'type':'elementStart'});for(const _0x5d32b7 of _0x140813['getChildren']())this['_generateTape'](_0x5d32b7,_0x36f3d7);_0x140813['is']('element')&&_0x36f3d7['push']({'item':_0x140813,'type':'elementEnd'});}return _0x36f3d7;}['_getState'](){const _0x5ddbda=new Map(this['_touched']),_0x356fb3=new Map(_0x5ddbda),_0xf6b48a=new Map(),_0x485090={'insertions':{},'deletions':{}},_0x4a15fa={'insertions':{},'deletions':{}},_0x1b51d5=new Map(),_0x4343e1=new Set([...this['_baseRoots']['keys'](),...this['_diffRoots']['keys']()]);_0x4343e1['delete']('$graveyard');for(const _0x381055 of _0x4343e1){const _0x5d72c1=this['_diffRoots']['get'](_0x381055)||P(_0x381055,!0x1),_0x11fcb4=this['_baseRoots']['get'](_0x381055)||P(_0x381055,!0x1);_0x5d72c1['isAttached']()||_0x11fcb4['isAttached']()?(_0x485090['insertions'][_0x381055]=N(_0x5d72c1),_0x485090['deletions'][_0x381055]=N(_0x11fcb4),this['_copyMarkers'](_0x485090['deletions'][_0x381055],_0x11fcb4),this['_copyMarkers'](_0x485090['insertions'][_0x381055],_0x5d72c1),_0x4a15fa['insertions'][_0x381055]=this['_generateTape'](this['_idsRoots']['get'](_0x381055),[]),_0x4a15fa['deletions'][_0x381055]=this['_generateTape'](this['_baseIdsRoots']['get'](_0x381055)||P(_0x381055,!0x1),[])):_0x4343e1['delete'](_0x381055);}for(const _0x31f087 of _0x4343e1){const _0x48faf6=_0x4a15fa['insertions'][_0x31f087];for(const _0x4331d2 of _0x48faf6){const _0x3f695c=this['_getVidAttributeName'](_0x4331d2),_0x343c95=_0x4331d2['item']['getAttribute'](_0x3f695c);_0x356fb3['delete'](_0x343c95),_0x343c95>=this['_startingRevisionId']&&_0xf6b48a['set'](_0x343c95,_0x5ddbda['get'](_0x343c95));}}for(const _0x520edb of _0x4343e1){const _0x5941b1=_0x4a15fa['insertions'][_0x520edb],_0x3a06eb=this['_getBaseVids'](_0x4a15fa['deletions'][_0x520edb]);let _0xa16ec6=0x0;for(const _0x30104f of _0x5941b1){const _0x40c3ef=this['_getVidAttributeName'](_0x30104f),_0xcbac44=_0x30104f['item']['getAttribute'](_0x40c3ef);if(!_0xf6b48a['has'](_0xcbac44)&&!_0x1b51d5['has'](_0xcbac44)){if(_0x356fb3['has'](_0xcbac44))_0xa16ec6++;else{if(_0xcbac44!=_0x3a06eb[_0xa16ec6]){const _0xb74075=_0x5ddbda['get'](_0xcbac44)||_0x5ddbda['get'](_0x3a06eb[_0xa16ec6]);for(;_0xcbac44!=_0x3a06eb[_0xa16ec6];)_0x356fb3['has'](_0x3a06eb[_0xa16ec6])||(_0x1b51d5['set'](_0x3a06eb[_0xa16ec6],_0xb74075),_0x5ddbda['set'](_0x3a06eb[_0xa16ec6],_0xb74075)),_0xa16ec6++;}_0xa16ec6++;}}}}for(const _0x4dc3b9 of _0x4343e1){const _0x1e4c68=_0x4a15fa['insertions'][_0x4dc3b9];for(const _0x3e05e4 of _0x1e4c68){const _0x5036c6=this['_getVidAttributeName'](_0x3e05e4),_0x360522=_0x3e05e4['item']['getAttribute'](_0x5036c6);if(_0x1b51d5['has'](_0x360522)){const _0x4213d5=_0x1b51d5['get'](_0x360522);_0x356fb3['has'](_0x360522)||_0x356fb3['set'](_0x360522,{..._0x4213d5}),_0xf6b48a['set'](_0x360522,{..._0x4213d5});}}}for(const _0x5f5833 of _0x356fb3['keys']())_0x5f5833>=this['_startingRevisionId']&&_0x356fb3['delete'](_0x5f5833);const _0x8d2f1a=new Map();for(const _0x24d729 of _0x4343e1){let _0x3ce740=_0x4a15fa['insertions'][_0x24d729];for(const _0x86ed0b of _0x3ce740)if(_0x86ed0b['item']['is']('element','tableCell')){const _0x224683=this['_getVidAttributeName'](_0x86ed0b),_0x35c58c=_0x86ed0b['item']['getAttribute'](_0x224683);if(_0xf6b48a['has'](_0x35c58c)){const _0x3004a0=_0x86ed0b['item']['parent']['parent']['getAttribute']('vid_start'),_0x59bd71=_0x8d2f1a['get'](_0x3004a0)||new Set();_0x59bd71['add'](_0xf6b48a['get'](_0x35c58c)['userId']),_0x8d2f1a['set'](_0x3004a0,_0x59bd71);}}_0x3ce740=_0x4a15fa['deletions'][_0x24d729];for(const _0x41074f of _0x3ce740)if(_0x41074f['item']['is']('element','tableCell')){const _0x5a251e=this['_getVidAttributeName'](_0x41074f),_0x5de5f5=_0x41074f['item']['getAttribute'](_0x5a251e);if(_0x356fb3['has'](_0x5de5f5)){const _0x1bad05=_0x41074f['item']['parent']['parent']['getAttribute']('vid_start'),_0xe2f3b8=_0x8d2f1a['get'](_0x1bad05)||new Set();_0xe2f3b8['add'](_0x356fb3['get'](_0x5de5f5)['userId']),_0x8d2f1a['set'](_0x1bad05,_0xe2f3b8);}}for(const _0x3ce12a of _0x8d2f1a['keys']())(_0xf6b48a['has'](_0x3ce12a)||_0x356fb3['has'](_0x3ce12a))&&_0x8d2f1a['delete'](_0x3ce12a);}for(const _0x1f4882 of _0x4343e1){const _0x302f02=_0x4a15fa['insertions'][_0x1f4882];let _0x14a33a=null,_0x4898c4=null;for(const _0x1b71f6 of _0x302f02){const _0x4e367f=this['_getVidAttributeName'](_0x1b71f6),_0x48c7db=_0x1b71f6['item']['getAttribute'](_0x4e367f),_0x3e1840=_0x8d2f1a['get'](_0x48c7db);_0x3e1840&&'elementStart'==_0x1b71f6['type']&&(_0x14a33a=Array['from'](_0x3e1840)[0x0],_0x4898c4=_0x1b71f6['item']['getAttribute']('vid_end')),_0x14a33a&&(_0x356fb3['set'](_0x48c7db,{'userId':_0x14a33a}),_0xf6b48a['set'](_0x48c7db,{'userId':_0x14a33a})),_0x48c7db==_0x4898c4&&(_0x14a33a=null,_0x4898c4=null);}}const _0x48ae2f={},_0x3ad26e=new Set();for(const _0x1e7579 of _0x4343e1){const _0x1ffb30=_0x485090['deletions'][_0x1e7579],_0x18656d=_0x485090['insertions'][_0x1e7579];for(const {userId:_0x36b952}of this['_touchedMarkers']['values']())null!==_0x36b952&&_0x3ad26e['add'](_0x36b952);for(const {userId:_0x55a61d}of this['_touchedRoots']['values']())null!==_0x55a61d&&_0x3ad26e['add'](_0x55a61d);this['_markChanges'](_0x18656d,_0x4a15fa['insertions'][_0x1e7579],_0xf6b48a,'insertion',_0x3ad26e),this['_markChanges'](_0x1ffb30,_0x4a15fa['deletions'][_0x1e7579],_0x356fb3,'deletion',_0x3ad26e),_0x48ae2f[_0x1e7579]={'insertions':this['_prepareViewToSave'](_0x18656d),'deletions':this['_prepareViewToSave'](_0x1ffb30),'attachChange':this['_touchedRoots']['get'](_0x1e7579)||null,'attributesBefore':_0x291809(this['_baseRootsAttributes']['get'](_0x1e7579))||{},'attributesAfter':_0x291809(this['_diffRootsAttributes']['get'](_0x1e7579))};}return{'diffData':_0x48ae2f,'authorsIds':Array['from'](_0x3ad26e)};}['_processRootBeforeSave'](_0x364550){for(const [,_0xadc428]of _0x364550['markers']){const _0x548f57=_0xadc428['start']['getAncestors']()['filter'](_0x2616f6=>'tableCell'==_0x2616f6['name']);for(const _0xbb004c of _0x548f57)0x1==_0xbb004c['childCount']&&_0xbb004c['getChild'](0x0)['is']('element','paragraph')&&_0xbb004c['getChild'](0x0)['_setAttribute']('keepParagraph',!0x0);}}['_prepareViewToSave'](_0x258159){this['_processRootBeforeSave'](_0x258159);const _0x13b59c=this['editor']['data']['toView'](_0x258159,{}),_0x27f422=Array['from'](_0x13b59c['getChildren']())['map'](_0x1817d2=>this['_getViewJson'](_0x1817d2));return JSON['stringify'](_0x27f422);}['_getViewJson'](_0x370d44){if(_0x370d44['is']('$text'))return _0x370d44['data'];{const _0xcbf328=this['editor']['plugins']['get']('RevisionHistoryUtils'),_0x56aeaf=_0x370d44,_0x3549f0=this['editor']['data']['htmlProcessor']['domConverter'],_0x46cfa1={'type':_0xcbf328['_getTypeCharForViewElement'](_0x56aeaf),'name':_0x56aeaf['name'],'attributes':Array['from'](_0x56aeaf['getAttributes']()),'children':Array['from'](_0x56aeaf['getChildren']())['map'](_0x48584e=>this['_getViewJson'](_0x48584e))};if(_0x370d44['is']('uiElement')&&'$comment'!=_0x370d44['name']){const _0x17b911=_0x370d44['render'](_0x3549f0['domDocument'],_0x3549f0);_0x46cfa1['children']['push'](_0x17b911['outerHTML']);}else{if(_0x370d44['is']('rawElement')){const _0x108a88=_0x3549f0['domDocument']['createElement'](_0x56aeaf['name']);_0x370d44['render'](_0x108a88,_0x3549f0),_0x46cfa1['children']['push'](_0x108a88['innerHTML']);}}const _0x36e1bc=Array['from'](_0x56aeaf['getCustomProperties']());_0x36e1bc['length']>0x0&&(_0x46cfa1['customProperties']=_0x36e1bc);const _0x729e05=_0x56aeaf['getFillerOffset']();return null!==_0x729e05&&(_0x46cfa1['fillerOffset']=_0x729e05),_0x46cfa1;}}['_markChanges'](_0x13d1a5,_0x5ba338,_0x490223,_0x46935a,_0x22a241){let _0x5e0e4d=null,_0x135e66=null,_0x54a5a7=0x0;const _0x277874=this['editor']['model'];for(let _0xde1ded=0x0;_0xde1ded<_0x5ba338['length'];_0xde1ded++){const _0x1d6926=this['_getVidAttributeName'](_0x5ba338[_0xde1ded]),_0xece8e5=_0x5ba338[_0xde1ded]['item']['getAttribute'](_0x1d6926),_0x297ba3=_0x490223['get'](_0xece8e5),_0x48a6b1=_0xde1ded==_0x5ba338['length']-0x1;(!_0x5e0e4d&&_0x297ba3&&(_0x5e0e4d=_0x297ba3,_0x135e66=_0x5ba338[_0xde1ded]),_0x5e0e4d&&(!_0x297ba3||_0x297ba3['userId']!=_0x5e0e4d['userId']))&&(_0x893173(_0x297ba3,F(_0x135e66,_0x13d1a5,_0x277874),F(_0x5ba338[_0xde1ded],_0x13d1a5,_0x277874)),_0x5e0e4d=_0x297ba3||null,_0x135e66=_0x297ba3?_0x5ba338[_0xde1ded]:null),_0x5e0e4d&&_0x48a6b1&&_0x893173(_0x297ba3,F(_0x135e66,_0x13d1a5,_0x277874),B(_0x5ba338[_0xde1ded],_0x13d1a5,_0x277874));}function _0x893173(_0x5bb342,_0x19cf0b,_0x5d0a74){const _0x6210d7=_0x5e0e4d['userId'],_0xdf5a4b='revision:'+_0x46935a+':'+_0x6210d7+':'+_0x54a5a7++,_0x5b13d3=_0x277874['createRange'](_0x19cf0b,_0x5d0a74);_0x13d1a5['markers']['set'](_0xdf5a4b,_0x5b13d3),null!==_0x6210d7&&_0x22a241['add'](_0x6210d7);}}['_getVidAttributeName'](_0x1f4952){switch(_0x1f4952['type']){case'elementStart':return'vid_start';case'elementEnd':return'vid_end';default:return'vid';}}['_fixOperation'](_0x360422,_0x3b7f91){_0x360422['baseVersion']=null;for(const _0x374bf1 in _0x360422){const _0x7a8c7e=_0x360422[_0x374bf1];if(_0x7a8c7e instanceof vt){const _0x1e9b5a=_0x3b7f91['get'](_0x7a8c7e['root']['rootName']);_0x360422[_0x374bf1]=this['_fixPosition'](_0x7a8c7e,_0x1e9b5a);}if(_0x7a8c7e instanceof ft){const _0x2b2453=_0x3b7f91['get'](_0x7a8c7e['root']['rootName']);_0x360422[_0x374bf1]=this['_fixRange'](_0x7a8c7e,_0x2b2453);}'root'===_0x374bf1&&(_0x360422['root']=_0x3b7f91['get'](_0x360422['root']['rootName']));}}['_fixRange'](_0x377561,_0x916784){return this['editor']['model']['createRange'](this['_fixPosition'](_0x377561['start'],_0x916784),this['_fixPosition'](_0x377561['end'],_0x916784));}['_fixPosition'](_0x2ddba2,_0x3c9c29){return this['editor']['model']['createPositionFromPath'](_0x3c9c29,_0x2ddba2['path'],_0x2ddba2['stickiness']);}['_handleInsertOperation'](_0x53a3c3){const _0x597da9=this['_idsRoots']['get'](_0x53a3c3['position']['root']['rootName']),_0x2dcc33=this['_fixPosition'](_0x53a3c3['position'],_0x597da9),_0x54e8fb=null===_0x53a3c3['_authorId']?null:_0x53a3c3['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x1d1507=_0x2dcc33['parent'],_0x597efd=this['_revisionId'],_0x255352=[];for(const _0x100f05 of _0x53a3c3['nodes'])if(_0x100f05['is']('element'))_0x255352['push'](this['_makeIdsRoot'](_0x100f05));else{for(let _0x3af4df=0x0;_0x3af4df<_0x100f05['offsetSize'];_0x3af4df++)_0x255352['push'](new ut('$text',{'vid':this['_revisionId']++}));}const _0x59a3f2=this['_revisionId'];for(let _0xb66128=_0x597efd;_0xb66128<_0x59a3f2;_0xb66128++)this['_touched']['set'](_0xb66128,{'userId':_0x54e8fb});_0x1d1507['_insertChild'](_0x2dcc33['offset'],_0x255352);}['_handleMoveOperation'](_0x5be334){(_0x5be334=this['_cloneOperation'](_0x5be334,this['_idsRoots']))['_execute']();const _0x1c182a=null===_0x5be334['_authorId']?null:_0x5be334['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0xb9c9c7=_0x5be334['getMovedRangeStart'](),_0x2afd68=_0xb9c9c7['parent'],_0x1527fa=_0xb9c9c7['offset'];!function _0x19d065(_0x4350ab,_0x58497d,_0x24a2f6,_0x551aa1){for(let _0x3ba6d9=_0x24a2f6;_0x3ba6d9<_0x551aa1;_0x3ba6d9++){const _0xcddfbc=_0x58497d['getChild'](_0x3ba6d9);_0xcddfbc['is']('element','$text')?_0x4350ab['set'](_0xcddfbc['getAttribute']('vid'),{'userId':_0x1c182a}):(_0x4350ab['set'](_0xcddfbc['getAttribute']('vid_start'),{'userId':_0x1c182a}),_0x19d065(_0x4350ab,_0xcddfbc,0x0,_0xcddfbc['childCount']),_0x4350ab['set'](_0xcddfbc['getAttribute']('vid_end'),{'userId':_0x1c182a}));}}(this['_touched'],_0x2afd68,_0x1527fa,_0x1527fa+_0x5be334['howMany']);}['_handleMergeOperation'](_0x3ef69b){const _0x558bbd=null===(_0x3ef69b=this['_cloneOperation'](_0x3ef69b,this['_idsRoots']))['_authorId']?null:_0x3ef69b['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x356a07=_0x3ef69b['targetPosition']['parent'],_0x419a95=_0x3ef69b['sourcePosition']['parent'],_0x4ce2df=_0x356a07['getAttribute']('vid_end'),_0x1ded0e=_0x419a95['getAttribute']('vid_start');_0x356a07['_setAttribute']('vid_end',_0x419a95['getAttribute']('vid_end')),_0x419a95['_setAttribute']('vid_end',_0x4ce2df),this['_touched']['set'](_0x1ded0e,{'userId':_0x558bbd}),this['_touched']['set'](_0x4ce2df,{'userId':_0x558bbd}),_0x3ef69b['_execute']();}['_handleSplitOperation'](_0x2fd47e){const _0x4f1497=null===(_0x2fd47e=this['_cloneOperation'](_0x2fd47e,this['_idsRoots']))['_authorId']?null:_0x2fd47e['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x5a5a43=_0x2fd47e['graveyardPosition'],_0x2a497d=_0x2fd47e['splitPosition']['parent'];_0x2fd47e['_execute']();const _0xae6cc1=_0x2a497d['getAttribute']('vid_end'),_0x708481=_0x2fd47e['insertionPosition']['nodeAfter'];if(_0x5a5a43){const _0x213cc3=_0x708481['getAttribute']('vid_end'),_0x6dbdd1=_0x2a497d['getAttribute']('vid_end');_0x2a497d['_setAttribute']('vid_end',_0x213cc3),_0x708481['_setAttribute']('vid_end',_0x6dbdd1),this['_touched']['set'](_0x2a497d['getAttribute']('vid_end'),{'userId':_0x4f1497}),this['_touched']['set'](_0x708481['getAttribute']('vid_start'),{'userId':_0x4f1497});}else{const _0x3b1bdc=this['_revisionId']++,_0x1575d6=this['_revisionId']++;_0x2a497d['_setAttribute']('vid_end',_0x3b1bdc),_0x708481['_setAttribute']('vid_start',_0x1575d6),_0x708481['_setAttribute']('vid_end',_0xae6cc1),this['_touched']['set'](_0x3b1bdc,{'userId':_0x4f1497}),this['_touched']['set'](_0x1575d6,{'userId':_0x4f1497});}}['_handleMarkerOperation'](_0x1da526){if(!_0x1da526['affectsData'])return;const _0x5d66ee=(_0x1da526=this['_cloneOperation'](_0x1da526,this['_diffRoots']))['oldRange']?_0x1da526['oldRange']['root']:null,_0x4d06b2=_0x1da526['newRange']?_0x1da526['newRange']['root']:null;_0x5d66ee&&this['_markers']['delete'](_0x1da526['name']),_0x4d06b2&&this['_markers']['set'](_0x1da526['name'],_0x1da526['newRange']['clone']());const _0x6dbec3=null===_0x1da526['_authorId']?null:_0x1da526['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x5642e2=_0x1da526['name'];if(!this['_touchedMarkers']['has'](_0x5642e2))return void this['_touchedMarkers']['set'](_0x5642e2,{'range':_0x1da526['oldRange'],'userId':_0x6dbec3});const _0x24fa08=this['_touchedMarkers']['get'](_0x5642e2),_0x1b57d7=_0x24fa08['range'],_0x1372e8=_0x1da526['newRange'];null==_0x1b57d7&&null==_0x1372e8||_0x1b57d7&&_0x1372e8&&_0x1b57d7['isEqual'](_0x1372e8)?this['_touchedMarkers']['delete'](_0x1da526['name']):_0x24fa08['userId']=_0x6dbec3;}['_handleRootOperation'](_0x102767,_0x166d13){this['_diffRoots']['has'](_0x102767['rootName'])?this['_diffRoots']['get'](_0x102767['rootName'])['_isAttached']=_0x102767['isAdd']:(this['_diffRoots']['set'](_0x102767['rootName'],P(_0x102767['rootName'],!0x0)),this['_diffRootsAttributes']['set'](_0x102767['rootName'],{}),_0x166d13&&this['_idsRoots']['set'](_0x102767['rootName'],P(_0x102767['rootName'],!0x0)));const _0x4b994e=null===_0x102767['_authorId']?null:_0x102767['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x271bf1=this['_touchedRoots']['get'](_0x102767['rootName']);_0x271bf1&&_0x271bf1['userId']===_0x4b994e?this['_touchedRoots']['delete'](_0x102767['rootName']):this['_touchedRoots']['set'](_0x102767['rootName'],{'userId':_0x4b994e,'isAttached':_0x102767['isAdd']});}['_handleRootAttributeOperation'](_0x82a35f){const _0x345dfe=this['_diffRootsAttributes']['get'](_0x82a35f['root']['rootName']);null===_0x82a35f['newValue']?delete _0x345dfe[_0x82a35f['key']]:_0x345dfe[_0x82a35f['key']]=_0x82a35f['newValue'];}}function N(_0x4f28a0){const _0xed9b64=P(_0x4f28a0['rootName'],_0x4f28a0['isAttached']());for(const _0xd05400 of _0x4f28a0['getChildren']()){const _0x3f020d=_0xd05400['_clone'](!0x0);_0xed9b64['_appendChild'](_0x3f020d);}return _0xed9b64;}function P(_0x5b9a4e,_0x8014aa=!0x0){const _0x2f0752=new gt();return _0x2f0752['rootName']=_0x5b9a4e,_0x2f0752['_isAttached']=_0x8014aa,_0x2f0752['isAttached']=()=>_0x2f0752['_isAttached'],_0x2f0752;}function F(_0x12d65c,_0x38ba7e,_0x1d1122){const _0x495092='elementEnd'==_0x12d65c['type']?_0x1d1122['createPositionAt'](_0x12d65c['item'],'end'):_0x1d1122['createPositionBefore'](_0x12d65c['item']);return _0x1d1122['createPositionFromPath'](_0x38ba7e,_0x495092['path'],_0x495092['stickiness']);}function B(_0x316456,_0x4a2cfc,_0x5b6078){const _0x448256='elementStart'==_0x316456['type']?_0x5b6078['createPositionAt'](_0x316456['item'],0x0):_0x5b6078['createPositionAfter'](_0x316456['item']);return _0x5b6078['createPositionFromPath'](_0x4a2cfc,_0x448256['path'],_0x448256['stickiness']);}class os extends _0x18313a{['focusTracker'];['keystrokes'];['revisionNameInputView'];constructor(_0x2a7faf,_0x2bb430){super(_0x2a7faf),this['focusTracker']=new _0x50bd47(),this['keystrokes']=new _0x4ecd61(),this['set']('revisionNameInputValue',''),this['revisionNameInputView']=this['_createRevisionNameInput'](_0x2bb430),this['setTemplate']({'tag':'form','attributes':{'class':['ck','ck-revision-history-save-revision-form','ck-responsive-form'],'tabindex':'-1'},'children':[this['revisionNameInputView']]}),ts(this);}['render'](){super['render'](),_0x47be2c({'view':this}),this['focusTracker']['add'](this['revisionNameInputView']['element']),this['keystrokes']['listenTo'](this['element']);const _0x4001ca=_0x4f8be3=>_0x4f8be3['stopPropagation']();this['keystrokes']['set']('arrowright',_0x4001ca),this['keystrokes']['set']('arrowleft',_0x4001ca),this['keystrokes']['set']('arrowup',_0x4001ca),this['keystrokes']['set']('arrowdown',_0x4001ca);}['focus'](){this['revisionNameInputView']['focus']();}get['revisionName'](){return this['revisionNameInputView']['fieldView']['element']['value']['trim']();}set['revisionName'](_0x47d138){this['revisionNameInputView']['fieldView']['element']['value']=_0x47d138['trim']();}['reset'](){this['revisionNameInputView']['fieldView']['element']['value']='',this['revisionNameInputView']['errorText']=null;}['_createRevisionNameInput'](_0xf8266e){const _0x3ea29e=new nt(this['locale'],ti),_0x75280b=_0x3ea29e['fieldView'];_0x75280b['extendTemplate']({'attributes':{'maxlength':'220'}});let _0x36180e=g(this['locale'],'Name\x20of\x20the\x20revision');return!_0xf8266e&&(_0x36180e+='\x20('+g(this['locale'],'optional')+')'),(_0x3ea29e['label']=_0x36180e,_0x75280b['on']('input',()=>{this['revisionNameInputValue']=_0x75280b['element']['value']['trim']();}),_0x3ea29e);}}class f extends _0x3ba875{static get['pluginName'](){return'RevisionHistoryUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[u];}['_saveRevisionFormView'];['init'](){const _0x443b66=this['editor'],_0x4cb857=_0x443b66['plugins']['get']('RevisionTracker');_0x443b66['ui']['componentFactory']['add']('revisionHistory',_0x3308ac=>{const _0x485770=_0x3564c9(_0x3308ac),_0x292455=_0x485770['panelView']['children'],_0x13ed58=new _0x10dfcb(_0x3308ac),_0x3798d2=new te(_0x3308ac),_0x5be490=new _0x29dce1(_0x3308ac),_0x3f908f=new te(_0x3308ac),_0x2b9e4b=new _0x29dce1(_0x3308ac);return _0x485770['bind']('isEnabled')['to'](_0x4cb857,'isReady',_0x4cb857,'isEnabled',_0x443b66,'isReadOnly',(_0xe569d5,_0x400b2b,_0x3897dc)=>_0xe569d5&&_0x400b2b&&!_0x3897dc),_0x485770['buttonView']['set']({'icon':_0x209882,'label':g(_0x3308ac,'Revision\x20history'),'tooltip':!0x0}),_0x5be490['set']({'label':g(_0x3308ac,'Save\x20current\x20revision'),'withText':!0x0,'role':'menuitem'}),_0x5be490['bind']('isEnabled')['to'](_0x4cb857,'isReady',_0x4cb857,'isEnabled',_0x443b66,'isReadOnly',(_0x27457e,_0x804ca,_0x26eb56)=>_0x27457e&&_0x804ca&&!_0x26eb56),_0x5be490['on']('execute',()=>this['_showDialog']()),_0x2b9e4b['set']({'label':g(_0x3308ac,'Open\x20revision\x20history'),'withText':!0x0,'role':'menuitem'}),_0x2b9e4b['bind']('isEnabled')['to'](_0x4cb857,'isReady',_0x443b66,'isReadOnly',(_0xc7e616,_0x1bbed7)=>_0xc7e616&&!_0x1bbed7),_0x2b9e4b['on']('execute',()=>{_0x443b66['config']['get']('revisionHistory')['showRevisionViewerCallback'](),_0x485770['isOpen']=!0x1,_0x443b66['editing']['view']['focus']();}),_0x3798d2['children']['add'](_0x5be490),_0x3f908f['children']['add'](_0x2b9e4b),_0x13ed58['role']='menu',_0x13ed58['items']['addMany']([_0x3798d2,_0x3f908f]),_0x292455['add'](_0x13ed58),_0x485770;}),_0x443b66['ui']['componentFactory']['add']('menuBar:revisionHistory',()=>this['_registerMenuComponent']());}['_registerMenuComponent'](){const _0x1bcde4=this['editor'],_0x76c58c=_0x1bcde4['locale'],_0xd0cfe5=new _0x1ab6f1(_0x76c58c),_0x508d09=new _0x56e625(_0x76c58c);_0xd0cfe5['buttonView']['set']({'icon':_0x209882,'label':g(_0x76c58c,'Revision\x20history')});const _0x36ba06=new _0x39cc4d(_0x76c58c,_0xd0cfe5),_0x49a411=new _0x34296b(_0x76c58c);_0x49a411['set']({'label':g(_0x76c58c,'Save\x20current\x20revision')}),_0x49a411['delegate']('execute')['to'](_0xd0cfe5),_0x49a411['on']('execute',()=>{this['_showDialog']();}),_0x36ba06['children']['add'](_0x49a411),_0x508d09['items']['add'](_0x36ba06);const _0x3265d2=new _0x39cc4d(_0x76c58c,_0xd0cfe5),_0x4e592b=new _0x34296b(_0x76c58c);return _0x4e592b['set']({'label':g(_0x76c58c,'Open\x20revision\x20history')}),_0x4e592b['delegate']('execute')['to'](_0xd0cfe5),_0x4e592b['on']('execute',()=>{_0x1bcde4['config']['get']('revisionHistory')['showRevisionViewerCallback']();}),_0x3265d2['children']['add'](_0x4e592b),_0x508d09['items']['add'](_0x3265d2),_0xd0cfe5['panelView']['children']['add'](_0x508d09),_0xd0cfe5;}['_showDialog'](){const _0xf26cfe=this['editor'],_0x24955b=_0xf26cfe['locale'],_0x5d7559=_0xf26cfe['plugins']['get']('Dialog'),_0x23c088=_0xf26cfe['plugins']['get']('RevisionTracker');function _0x53500f(_0x2db4a9){_0xf26cfe['config']['get']('revisionHistory.requireRevisionName')&&''===_0x2db4a9['revisionName']?_0x2db4a9['revisionNameInputView']['errorText']=g(_0x24955b,'The\x20revision\x20name\x20cannot\x20be\x20empty.'):(_0xf26cfe['plugins']['get'](u)['saveRevision']({'name':_0x2db4a9['revisionName']}),_0x5d7559['hide']());}this['_saveRevisionFormView']||(this['_createSaveRevisionFormView'](),this['_saveRevisionFormView']['on']('submit',()=>_0x53500f(this['_saveRevisionFormView']))),this['_saveRevisionFormView']['reset'](),_0x5d7559['show']({'id':'revisionSave','title':g(_0x24955b,'Save\x20current\x20revision'),'isModal':!0x0,'content':this['_saveRevisionFormView'],'actionButtons':[{'label':g(_0xf26cfe['locale'],'Cancel'),'withText':!0x0,'onExecute':()=>_0x5d7559['hide']()},{'label':g(_0xf26cfe['locale'],'Accept'),'class':'ck-button-action','withText':!0x0,'onCreate'(_0x3f3fe7){_0x3f3fe7['bind']('isEnabled')['to'](_0x23c088,'isReady',_0x23c088,'isEnabled',_0xf26cfe,'isReadOnly',(_0x34adee,_0xbe2bf7,_0x615836)=>_0x34adee&&_0xbe2bf7&&!_0x615836);},'onExecute':()=>_0x53500f(this['_saveRevisionFormView'])}]});}['_createSaveRevisionFormView'](){const _0x425035=this['editor'],_0x365802=_0x425035['locale'];this['_saveRevisionFormView']=new os(_0x365802,_0x425035['config']['get']('revisionHistory.requireRevisionName')),this['_saveRevisionFormView']['render']();}}class Q extends _0x18313a{['changeId'];['_model'];constructor(_0x2be4f3,_0x41778e){super(_0x2be4f3),this['_model']=_0x41778e,this['changeId']=_0x41778e['id'];const _0x36d94f=this['bindTemplate'],_0x1f0fd1=g(_0x2be4f3,_0x41778e['data']['isSuggestion']?'Suggested\x20by':'add'==_0x41778e['type']?'Added\x20by':'Removed\x20by');this['set']('type',_0x41778e['type']),this['setTemplate']({'tag':'div','attributes':{'class':['ck-annotation','ck-revision-change',_0x36d94f['to']('type',_0x4ffe9d=>'ck-revision-change__'+_0x4ffe9d)],'tabindex':-0x1},'children':[{'tag':'span','children':[{'tag':'span','attributes':{'class':['ck-revision-change__label']},'children':[{'text':_0x1f0fd1}]},{'text':'\x20'+_0x41778e['author']['name']}]}]});}['focus'](){this['element']['focus']();}}class r extends/* #__PURE__ -- @preserve */
|
|
25
|
+
_0x6a77e2(){['id'];['author'];['type'];['data'];['rootName'];constructor(_0x178ac6){super(),this['id']=_0x178ac6['id']||_0x58b8ff(),this['author']=_0x178ac6['author'],this['type']=_0x178ac6['type'],this['data']=_0x178ac6['data']||{},this['rootName']=_0x178ac6['rootName'],this['set']('createdAt',_0x178ac6['createdAt']);}['toJSON'](){return{'id':this['id'],'authorId':this['author']['id'],'type':this['type'],'data':this['data'],'createdAt':this['createdAt']};}}class c{['newRevisionId'];['oldRevisionId'];['changes'];constructor(_0x207624,_0x4837b5){this['newRevisionId']=_0x207624,this['oldRevisionId']=_0x4837b5,this['changes']=new _0x5495c4();}['_setChanges'](_0x5cbad2){for(const _0x4bca68 of _0x5cbad2)this['changes']['add'](_0x4bca68);}}class m extends _0x3ba875{['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[_0x1b8b11,_0x44407,I,V];}constructor(_0x3a99dd){super(_0x3a99dd),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',(_0x4767da,_0x4a4bab,_0x44d30e)=>{this['activeChange']=null,this['activeView']=null,this['editor']['editing']['view']['change'](_0xab8b00=>{for(const _0x26f414 of this['editor']['editing']['view']['document']['roots'])_0x44d30e?_0xab8b00['removeClass']('ck-editor__editable__overlay',_0x26f414):_0xab8b00['addClass']('ck-editor__editable__overlay',_0x26f414);});}),this['bind']('isNavigationMode')['to'](this,'activeChange',_0x416a64=>null!==_0x416a64),this['bind']('currentChangeNumber')['to'](this,'isReady',this,'diff',this,'activeChange',(_0x162014,_0x18cfd1,_0x56daf4)=>_0x162014&&_0x56daf4?_0x18cfd1['changes']['getIndex'](_0x56daf4):0x0),this['bind']('numberOfChanges')['to'](this,'isReady',this,'diff',(_0x558fb9,_0xb431ae)=>_0x558fb9?_0xb431ae['changes']['length']:0x0),this['_changeView']=null,this['_changeIdToChange']=new Map(),this['_balloon']=this['editor']['plugins']['get'](_0x44407);}['init'](){const _0x5b30ec=this['editor'],_0xa02973=new pt(_0x5b30ec,{'direction':'backward'}),_0x1892f0=new pt(_0x5b30ec,{'direction':'forward'});(_0x5b30ec['commands']['add']('showPreviousChange',_0xa02973),_0x5b30ec['commands']['add']('showNextChange',_0x1892f0),_0x5b30ec['commands']['add']('restoreRevision',new wt(_0x5b30ec)),this['on']('change:numberOfChanges',()=>{_0xa02973['refresh'](),_0x1892f0['refresh']();}),this['_setConversion'](),this['_initInteractions'](),_0x5b30ec['enableReadOnlyMode']('revision-viewer'),_0x5b30ec['plugins']['has']('WidgetToolbarRepository'))&&_0x5b30ec['plugins']['get']('WidgetToolbarRepository')['forceDisabled']('revision-viewer');}async['getRevisionDocumentData'](_0x2c3d9f){return await this['_utils']['loadRevisionData'](_0x2c3d9f,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x2c3d9f);}async['getRevisionRootsAttributes'](_0x139c6b){return await this['_utils']['loadRevisionData'](_0x139c6b,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x139c6b);}async['compare'](_0xe8e2db,_0x4fdc7a,_0x1f7944=!0x1){if(!this['isEnabled'])return;const _0x5dcd5e=this['diff'],_0x58d753=this['repository'],_0xc748cb='string'==typeof _0xe8e2db?_0x58d753['getRevision'](_0xe8e2db):_0xe8e2db,_0x26e2a2='string'==typeof _0x4fdc7a?_0x58d753['getRevision'](_0x4fdc7a):_0x4fdc7a,_0x3528d7=_0xc748cb['id'],_0x2c1e41=_0x26e2a2?_0x26e2a2['id']:null;if(!_0x1f7944&&this['diff']&&this['diff']['newRevisionId']===_0x3528d7&&this['diff']['oldRevisionId']===_0x2c1e41)return Promise['resolve']();this['isReady']=!0x1,this['activeView']=null,this['activeChange']=null,this['diff']=new c(_0x3528d7,_0x2c1e41);const _0x1b0404=this['_getRevisionsRange'](_0xc748cb,_0x26e2a2,!0x0)['map'](_0x3ac4d6=>this['_utils']['loadRevisionData'](_0x3ac4d6,this['adapter']));return _0x1b0404['push'](new Promise(_0x537851=>{setTimeout(_0x537851,0x14);})),Promise['all'](_0x1b0404)['then'](()=>{if(!this['isEnabled'])return;this['_cleanUp']();const _0xe8a9f0=this['_getDiff'](_0x3528d7,_0x2c1e41);for(const _0x458e51 of _0xe8a9f0['changes'])this['_changeIdToChange']['set'](_0x458e51['id'],_0x458e51);this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x4530cf=>{for(const _0x95d1 of this['editor']['model']['document']['getRootNames']())_0x4530cf['detachRoot'](_0x95d1);for(const _0x148a0a of Object['keys'](_0xe8a9f0['model'])){const _0x45d767=_0x4530cf['addRoot'](_0x148a0a);for(const _0x1a166c of Object['keys'](_0xe8a9f0['attributes'][_0x148a0a]))_0x4530cf['setAttribute'](_0x1a166c,_0xe8a9f0['attributes'][_0x148a0a][_0x1a166c],_0x45d767);_0x4530cf['insert'](_0xe8a9f0['model'][_0x148a0a],_0x45d767,0x0);}}),this['diff']['_setChanges'](this['_sortAndFilterDiffChanges'](_0xe8a9f0['changes'])),this['isReady']=!0x0;})['catch'](_0x3cc93d=>{console['error'](_0x3cc93d),this['_cleanUp'](),_0x5dcd5e&&(this['diff']=_0x5dcd5e),this['isReady']=!0x0;});}['addRevisionData'](_0x3a2e50,_0x105415){const _0x468aa1=this['repository']['createRevision'](_0x3a2e50);return _0x468aa1['on']('_update',(_0x2f527a,_0x18aa3e,_0x16df1a)=>_0x105415(_0x18aa3e,_0x16df1a,_0x468aa1)),this['repository']['addRevision'](_0x468aa1),_0x468aa1;}['_cleanUp'](){this['activeChange']=null,this['_cleanMarkers'](),this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=null,this['_changeIdToChange']['clear'](),this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x23bc24=>{for(const _0x58d93c of this['editor']['model']['document']['getRootNames']())_0x23bc24['detachRoot'](_0x58d93c);});}['_sortAndFilterDiffChanges'](_0x23b196){const _0x141f2d=[],_0xeaf635=new Map();for(const _0x4d49b0 of this['editor']['model']['document']['getRootNames']()){const _0x30f7bf=this['editor']['editing']['view']['getDomRoot'](_0x4d49b0);if(!_0x30f7bf)continue;const _0x321b8c=_0x30f7bf['getClientRects']()['item'](0x0);_0x321b8c&&(_0x141f2d['push'](_0x4d49b0),_0xeaf635['set'](_0x4d49b0,_0x321b8c));}return _0x141f2d['sort']((_0x263e5c,_0x5a4f73)=>{const _0xc63c23=_0xeaf635['get'](_0x263e5c),_0x5629e0=_0xeaf635['get'](_0x5a4f73);return _0xc63c23['y']-_0x5629e0['y']||_0xc63c23['x']-_0x5629e0['x'];}),(_0x23b196=_0x23b196['filter'](_0x1a3a3d=>_0x141f2d['includes'](_0x1a3a3d['rootName'])))['sort']((_0x4735c6,_0xd8049a)=>_0x141f2d['indexOf'](_0x4735c6['rootName'])-_0x141f2d['indexOf'](_0xd8049a['rootName'])),_0x23b196;}['_makeTape'](_0x4f150c){const _0x822270=Array['from'](_0x4f150c['markers'])['filter'](([_0x4c667e,_0xbdc58d])=>_0x4c667e['startsWith']('revision:')&&!_0xbdc58d['isCollapsed']),_0x3ee569=Array['from'](this['editor']['model']['createRangeIn'](_0x4f150c)['getWalker']({'singleCharacters':!0x0}));if(0x0!=_0x822270['length'])for(const _0x4d492c of _0x3ee569){const [_0xb3a3fd,_0x42f0b8]=_0x822270[0x0],[,_0x5d2b33,_0x5c9859]=_0xb3a3fd['split'](':');if(_0x42f0b8['end']['isEqual'](_0x4d492c['nextPosition'])&&_0x822270['shift'](),(_0x4d492c['previousPosition']['isEqual'](_0x42f0b8['start'])||_0x4d492c['previousPosition']['isAfter'](_0x42f0b8['start']))&&('insertion'==_0x5d2b33?_0x4d492c['isAdded']={'userId':_0x5c9859}:'deletion'==_0x5d2b33&&(_0x4d492c['isRemoved']={'userId':_0x5c9859})),0x0==_0x822270['length'])break;}return _0x3ee569;}['_refreshStartEndIndex'](_0x3c2731){const _0x2bf3e3=new Map();for(let _0x324e65=0x0;_0x324e65<_0x3c2731['length'];_0x324e65++)'text'===_0x3c2731[_0x324e65]['type']?(_0x3c2731[_0x324e65]['item']['startIndex']=_0x324e65,_0x3c2731[_0x324e65]['item']['endIndex']=_0x324e65):('elementStart'===_0x3c2731[_0x324e65]['type']?_0x3c2731[_0x324e65]['item']['startIndex']=_0x324e65:'elementEnd'===_0x3c2731[_0x324e65]['type']&&(_0x3c2731[_0x324e65]['item']['endIndex']=_0x324e65),_0x2bf3e3['set'](_0x3c2731[_0x324e65]['id'],_0x324e65));for(const _0x530cd9 of _0x2bf3e3['values']())'elementStart'===_0x3c2731[_0x530cd9]['type']?_0x3c2731[_0x530cd9]['item']['endIndex']=_0x2bf3e3['get'](_0x3c2731[_0x530cd9]['pairId']):'elementEnd'===_0x3c2731[_0x530cd9]['type']&&(_0x3c2731[_0x530cd9]['item']['startIndex']=_0x2bf3e3['get'](_0x3c2731[_0x530cd9]['pairId']));}['_processTape'](_0x2f795d){for(let _0x3ee77c=0x0;_0x3ee77c<_0x2f795d['length'];_0x3ee77c++){if('elementStart'===_0x2f795d[_0x3ee77c]['type'])_0x2f795d[_0x3ee77c]['item']['startIndex']=_0x3ee77c;else{if('elementEnd'===_0x2f795d[_0x3ee77c]['type']){_0x2f795d[_0x3ee77c]['item']['endIndex']=_0x3ee77c;const _0x25dcd1=_0x2f795d[_0x3ee77c]['item']['startIndex'];_0x2f795d[_0x25dcd1]['pairId']=_0x2f795d[_0x3ee77c]['id'],_0x2f795d[_0x3ee77c]['pairId']=_0x2f795d[_0x25dcd1]['id'];}else _0x2f795d[_0x3ee77c]['item']['startIndex']=_0x3ee77c,_0x2f795d[_0x3ee77c]['item']['endIndex']=_0x3ee77c,_0x2f795d[_0x3ee77c]['pairId']=null;}_0x2f795d[_0x3ee77c]['markersStart']||(_0x2f795d[_0x3ee77c]['markersStart']=[],_0x2f795d[_0x3ee77c]['markersEnd']=[]);}}['_markInsertions'](_0x83bc07,_0x23931c){const _0x2aaa06=_0x83bc07['filter'](_0x4e85da=>!_0x4e85da['isAdded']);for(let _0x3eaf67=0x0;_0x3eaf67<_0x23931c['length'];_0x3eaf67++)_0x23931c[_0x3eaf67]['isAdded']&&(_0x2aaa06[_0x3eaf67]['isAdded']=_0x23931c[_0x3eaf67]['isAdded']);}['_getDiff'](_0x5bc1a6,_0x546d52=null){const _0x4d18b3=this['repository']['getRevision'](_0x5bc1a6),_0x3e501c=_0x546d52?this['repository']['getRevision'](_0x546d52):null,_0x4a78bd=this['_getRevisionsRange'](_0x4d18b3,_0x3e501c),_0x17e436=_0x4a78bd[_0x4a78bd['length']-0x1],_0x3c2830=new Map(),_0x3207d6={'model':{},'attributes':{},'changes':[]},_0x3c5c2c=new Set(),_0x31c5cc=new Map();for(let _0x5df376=_0x4a78bd['length']-0x1;_0x5df376>=0x0;_0x5df376--){const _0x2c9ffc=_0x4a78bd[_0x5df376];for(const _0x2017b5 of Object['keys'](_0x2c9ffc['diffData']))if(_0x2c9ffc['diffData'][_0x2017b5]['attachChange']){const _0x1146ce=_0x2c9ffc['diffData'][_0x2017b5]['attachChange'];_0x1146ce['isAttached']?(_0x3c5c2c['add'](_0x2017b5),_0x31c5cc['has'](_0x2017b5)&&_0x31c5cc['get'](_0x2017b5)['userId']==_0x1146ce['userId']?_0x31c5cc['delete'](_0x2017b5):_0x31c5cc['set'](_0x2017b5,_0x1146ce)):_0x31c5cc['has'](_0x2017b5)?(_0x3c5c2c['delete'](_0x2017b5),_0x31c5cc['delete'](_0x2017b5)):(_0x3c5c2c['add'](_0x2017b5),_0x31c5cc['set'](_0x2017b5,_0x1146ce));}else _0x3c5c2c['add'](_0x2017b5);}for(const _0x139f57 of _0x3c5c2c){const _0x906e19=_0x31c5cc['has'](_0x139f57)&&!_0x31c5cc['get'](_0x139f57)['isAttached'];let _0x3cd81e=_0x906e19?_0x4a78bd['length']-0x1:0x0;const _0x1ef67f=_0x906e19?-0x1:0x1;for(;_0x4a78bd[_0x3cd81e];){const _0x9210e8=_0x4a78bd[_0x3cd81e];if(_0x9210e8['diffData'][_0x139f57]){const _0x1a01f9=_0x906e19?_0x9210e8['diffData'][_0x139f57]['attributesBefore']:_0x9210e8['diffData'][_0x139f57]['attributesAfter'];_0x3207d6['attributes'][_0x139f57]=_0x1a01f9?_0x291809(_0x1a01f9):{};break;}_0x3cd81e+=_0x1ef67f;}}for(const _0x50066c of _0x4a78bd){_0x50066c['model']={};for(const _0x4df297 of _0x50066c['authors'])_0x3c2830['set'](_0x4df297['id'],_0x4df297);for(const _0x13a844 of _0x3c5c2c){const _0x5d59f8=_0x50066c['diffData'][_0x13a844]?_0x50066c['diffData'][_0x13a844]['insertions']:'[]',_0x5350f7=_0x50066c['diffData'][_0x13a844]?_0x50066c['diffData'][_0x13a844]['deletions']:'[]';_0x50066c['model'][_0x13a844]={'insertions':this['_utils']['_makeModelFromViewString'](_0x5d59f8),'deletions':this['_utils']['_makeModelFromViewString'](_0x5350f7)};}}for(const _0x50ff79 of _0x3c5c2c){let _0x1e5a68=null,_0x18bee9=0x0;const _0x212962=new Map(Array['from'](_0x4d18b3['model'][_0x50ff79]['insertions']['markers'])['filter'](([_0x336371])=>!_0x336371['startsWith']('revision:')));let _0x5e407c=0x0;for(const _0x1837f4 of _0x4a78bd){const _0x3eca91=this['_makeTape'](_0x1837f4['model'][_0x50ff79]['insertions']);_0x1837f4==_0x4d18b3?(_0x1e5a68=_0x3eca91,_0x18bee9=_0x1e5a68['length'],_0x1e5a68['forEach'](_0x5abd4b=>{_0x5abd4b['id']=_0x5e407c++;}),this['_processTape'](_0x1e5a68)):this['_markInsertions'](_0x1e5a68,_0x3eca91);const _0x13a29c=_0x1e5a68['filter'](_0x3a6239=>!_0x3a6239['isAdded'])['map'](_0x3e1953=>_0x3e1953['id']);let _0x46f4df=0x0;const _0xfda3d3=this['_makeTape'](_0x1837f4['model'][_0x50ff79]['deletions']);_0xfda3d3['forEach'](_0x57ba7f=>{_0x57ba7f['isRemoved']?_0x57ba7f['id']=_0x18bee9++:_0x57ba7f['id']=_0x13a29c[_0x46f4df++];}),this['_processTape'](_0xfda3d3),this['_setDistance'](_0x1e5a68,'isAdded'),this['_setDistance'](_0xfda3d3,'isRemoved'),_0x1837f4==_0x4d18b3&&this['_markMarkers'](_0x1e5a68,_0x212962),_0x1e5a68=this['_joinTapes'](_0x1e5a68,_0xfda3d3),this['_refreshStartEndIndex'](_0x1e5a68),this['_setDistance'](_0x1e5a68,'isRemoved');}_0x1e5a68=_0x1e5a68['filter'](_0x31d35c=>!(_0x31d35c['isAdded']&&_0x31d35c['isRemoved']));const _0xa4e260=new Map(_0x17e436['model'][_0x50ff79]['deletions']['markers']),_0x3372b1=new Set(_0x212962['keys']());for(const _0x3950bb of _0xa4e260['keys']())_0x3372b1['delete'](_0x3950bb);this['_markSuggestions'](_0x1e5a68,_0x3372b1),this['_fixObsoleteTags'](_0x1e5a68),_0x1e5a68=this['_removeMissingPairs'](_0x1e5a68),_0x1e5a68=this['_markMismatchedRemovedTags'](_0x1e5a68),_0x1e5a68=this['_removeUnsupportedChanges'](_0x1e5a68);const {root:_0x47f16d,changes:_0x42e3cb}=this['_makeModelFromTape'](_0x1e5a68,_0x3c2830,_0x50ff79);_0x3207d6['model'][_0x50ff79]=_0x47f16d;const _0x55633b=_0x31c5cc['get'](_0x50ff79);if(_0x55633b){const _0x2ce1c4=_0x3c2830['get'](_0x55633b['userId']),_0x4ede97=new r({'author':_0x2ce1c4,'type':_0x55633b['isAttached']?'add':'remove','data':{'isOnRoot':!0x0},'createdAt':new Date(),'rootName':_0x50ff79});_0x42e3cb['unshift'](_0x4ede97),_0x3207d6['attributes'][_0x50ff79]['revisionHistoryAttachChange']=_0x4ede97['id'];}_0x3207d6['changes']=_0x3207d6['changes']['concat'](_0x42e3cb);}return _0x3207d6;}['_markMarkers'](_0x19a0ad,_0x2eefea){for(let _0x52c7eb=0x0;_0x52c7eb<_0x19a0ad['length'];_0x52c7eb++)for(const [_0x19ab29,_0xb78d4a]of _0x2eefea)!_0xb78d4a['isCollapsed']&&_0xb78d4a['start']['isEqual'](_0x19a0ad[_0x52c7eb]['previousPosition'])&&_0x19a0ad[_0x52c7eb]['markersStart']['push'](_0x19ab29),_0xb78d4a['end']['isEqual'](_0x19a0ad[_0x52c7eb]['nextPosition'])&&_0x19a0ad[_0x52c7eb]['markersEnd']['push'](_0x19ab29);}['_joinTapes'](_0x29b104,_0x26e641){let _0x55f5ba=[],_0x1e1a0a=0x0,_0x38ff39=0x0;for(;_0x1e1a0a<_0x29b104['length']||_0x38ff39<_0x26e641['length'];){const _0x379f96=_0x29b104[_0x1e1a0a]||{},_0x1fcc7a=_0x26e641[_0x38ff39]||{};if(_0x379f96['id']==_0x1fcc7a['id'])_0x1e1a0a++,_0x38ff39++,_0x55f5ba['push'](_0x379f96);else{if(_0x1fcc7a['isRemoved']&&_0x379f96['isAdded']){const {commonTape:_0x36fc8d,iEnd:_0x29227c,jEnd:_0x44bb95}=this['_threeWayMerge'](_0x29b104,_0x1e1a0a,_0x26e641,_0x38ff39);_0x55f5ba=_0x55f5ba['concat'](_0x36fc8d),_0x1e1a0a=_0x29227c,_0x38ff39=_0x44bb95;}else _0x1fcc7a['isRemoved']?(_0x38ff39++,_0x55f5ba['push'](_0x1fcc7a)):(_0x1e1a0a++,_0x55f5ba['push'](_0x379f96));}}return _0x55f5ba;}['_markSuggestions'](_0x1cee7b,_0xaa26e2){const _0x4a1e98=[];for(let _0x441dd6=0x0;_0x441dd6<_0x1cee7b['length'];_0x441dd6++){for(let _0x21e306=0x0;_0x21e306<_0x1cee7b[_0x441dd6]['markersStart']['length'];_0x21e306++){const _0x5eb0ab=_0x1cee7b[_0x441dd6]['markersStart'][_0x21e306];if(!_0xaa26e2['has'](_0x5eb0ab))continue;const {group:_0x485c61,type:_0x275d77,authorId:_0x533269}=_0x40dd5e(_0x5eb0ab);'revision-suggestion'!=_0x485c61||'insertion'!=_0x275d77&&'deletion'!=_0x275d77||(_0x4a1e98['unshift']({'type':_0x275d77,'name':_0x5eb0ab,'userId':_0x533269}),_0x1cee7b[_0x441dd6]['markersStart']['splice'](_0x21e306,0x1),_0x21e306--);}_0x29d385(_0x1cee7b[_0x441dd6]);for(let _0xd9a462=0x0;_0xd9a462<_0x1cee7b[_0x441dd6]['markersEnd']['length'];_0xd9a462++){const _0x1a4846=_0x1cee7b[_0x441dd6]['markersEnd'][_0xd9a462];if(!_0xaa26e2['has'](_0x1a4846))continue;const {group:_0x59b242,type:_0x5cd06e}=_0x40dd5e(_0x1a4846);if('revision-suggestion'!=_0x59b242||'insertion'!=_0x5cd06e&&'deletion'!=_0x5cd06e)continue;_0x1cee7b[_0x441dd6]['markersEnd']['splice'](_0xd9a462,0x1),_0xd9a462--;const _0x2741ea=_0x4a1e98['findIndex'](_0x4f7f64=>_0x4f7f64['name']==_0x1a4846);_0x2741ea>-0x1&&_0x4a1e98['splice'](_0x2741ea,0x1);}}function _0x40dd5e(_0xb77e1d){const _0xe25fbd=_0xb77e1d['split'](':');return{'group':_0xe25fbd[0x0],'type':_0xe25fbd[0x1],'subType':_0xe25fbd['length']>=0x5?_0xe25fbd[0x2]:null,'id':_0xe25fbd['length']<0x5?_0xe25fbd[0x2]:_0xe25fbd[0x3],'authorId':_0xe25fbd['length']<0x5?_0xe25fbd[0x3]:_0xe25fbd[0x4],'markerCount':0x6==_0xe25fbd['length']?_0xe25fbd[0x5]:null};}function _0x29d385(_0x5ce9fa){for(let _0x4284f4=0x0;_0x4284f4<_0x4a1e98['length'];_0x4284f4++){if(_0x5ce9fa['isAdded']&&'insertion'==_0x4a1e98[_0x4284f4]['type'])return _0x5ce9fa['isAddSuggestion']=_0x4a1e98[_0x4284f4],void delete _0x5ce9fa['isAdded'];if(!_0x5ce9fa['isAdded']&&!_0x5ce9fa['isRemoved']&&'deletion'==_0x4a1e98[_0x4284f4]['type'])return void(_0x5ce9fa['isRemoveSuggestion']=_0x4a1e98[_0x4284f4]);}}}['_setDistance'](_0x350bc7,_0x57208b){let _0x2a6007=0x0,_0x236bd9=!0x1;const _0x249c5f=new Map();for(const _0x1887a9 of _0x350bc7)_0x1887a9[_0x57208b]?_0x236bd9&&(_0x2a6007++,_0x236bd9=!0x1):(_0x2a6007++,_0x236bd9=!0x0),_0x249c5f['set'](_0x1887a9['id'],_0x2a6007);for(let _0x656fa7=0x0;_0x656fa7<_0x350bc7['length'];_0x656fa7++){if('isRemoved'==_0x57208b&&_0x350bc7[_0x656fa7]['isAdded']||'isAdded'==_0x57208b&&_0x350bc7[_0x656fa7]['isRemoved'])continue;if('text'==_0x350bc7[_0x656fa7]['type']){_0x350bc7[_0x656fa7]['distance']=0x0;continue;}const _0xe06aa0=_0x249c5f['get'](_0x350bc7[_0x656fa7]['pairId']),_0x5c3a2d=_0x249c5f['get'](_0x350bc7[_0x656fa7]['id']);_0x350bc7[_0x656fa7]['distance']=_0xe06aa0-_0x5c3a2d;}}['_getRevisionsRange'](_0x557d29,_0x4d05fa,_0xda74f0=!0x1){const _0x549abc=[];let _0x3f6022=this['repository']['getIndex'](_0x557d29),_0x33950f=this['repository']['getIndex'](_0x4d05fa);for(-0x1==_0x33950f&&(_0x33950f=this['repository']['_revisions']['length'],_0xda74f0=!0x1);_0x3f6022<_0x33950f;)_0x549abc['push'](this['repository']['getRevision'](_0x3f6022)),_0x3f6022++;return _0xda74f0&&_0x549abc['push'](this['repository']['getRevision'](_0x3f6022)),_0x549abc;}['_threeWayMerge'](_0x1781b9,_0xdcb765,_0x2babda,_0x493fa3){const _0x4aa1bc=this['editor']['model']['schema'];let _0x27cdfd=_0xdcb765;for(;_0x1781b9[_0x27cdfd]&&_0x1781b9[_0x27cdfd]['isAdded'];)_0x27cdfd++;let _0x5b15e6=_0x493fa3;for(;_0x2babda[_0x5b15e6]&&_0x2babda[_0x5b15e6]['isRemoved'];)_0x5b15e6++;_0x4cf84b(_0x1781b9,_0xdcb765,_0x27cdfd),_0x4cf84b(_0x2babda,_0x493fa3,_0x5b15e6);const _0x49e876=_0x2babda['slice'](_0x493fa3,_0x5b15e6)['concat'](_0x1781b9['slice'](_0xdcb765,_0x27cdfd));return _0x49e876['sort']((_0x241ee6,_0x472225)=>_0x241ee6['side']!=_0x472225['side']?_0x241ee6['side']-_0x472225['side']:_0x241ee6['level']!=_0x472225['level']?_0x241ee6['level']-_0x472225['level']:_0x241ee6['distance']!=_0x472225['distance']?_0x472225['distance']-_0x241ee6['distance']:!!_0x241ee6['isAdded']!=!!_0x472225['isAdded']?-0x1==_0x241ee6['side']||0x0==_0x241ee6['side']?_0x241ee6['isAdded']?-0x1:0x1:_0x241ee6['isAdded']?0x1:-0x1:_0x241ee6['index']-_0x472225['index']),{'commonTape':_0x49e876,'iEnd':_0x27cdfd,'jEnd':_0x5b15e6};function _0x4cf84b(_0x1faafd,_0x46388e,_0x1445fd){let _0x397dfa=-0x1,_0x381d75=Number['POSITIVE_INFINITY'],_0x439a78=!0x0;for(let _0x355114=_0x46388e;_0x355114<_0x1445fd;_0x355114++)if(_0x4aa1bc['isInline'](_0x1faafd[_0x355114]['item'])||(_0x439a78=!0x1),_0x1faafd[_0x355114]['item']['startIndex']<_0x46388e&&(_0x397dfa=_0x355114),_0x1faafd[_0x355114]['item']['endIndex']>=_0x1445fd){_0x381d75=_0x355114;break;}_0x439a78&&(_0x397dfa=_0x1445fd-0x1);for(let _0x3e8ee0=_0x46388e;_0x3e8ee0<_0x1445fd;_0x3e8ee0++)_0x1faafd[_0x3e8ee0]['side']=_0x3e8ee0<=_0x397dfa?-0x1:_0x3e8ee0<_0x381d75?0x0:0x1,_0x1faafd[_0x3e8ee0]['index']=_0x3e8ee0;let _0x553691=0x0;for(let _0x490d8f=_0x46388e;_0x490d8f<=_0x397dfa;_0x490d8f++)0x0==_0x1faafd[_0x490d8f]['distance']?_0x1faafd[_0x490d8f]['level']=_0x553691:(_0x553691++,_0x1faafd[_0x490d8f]['level']=_0x553691,_0x553691++);for(let _0xe5eef1=_0x46388e;_0xe5eef1<_0x1445fd;_0xe5eef1++)0x0==_0x1faafd[_0xe5eef1]['side']&&(_0x1faafd[_0xe5eef1]['level']=_0x553691);_0x553691=0x0;for(let _0x9c57c6=_0x1445fd-0x1;_0x9c57c6>=_0x381d75;_0x9c57c6--)0x0==_0x1faafd[_0x9c57c6]['distance']?_0x1faafd[_0x9c57c6]['level']=_0x553691:(_0x553691--,_0x1faafd[_0x9c57c6]['level']=_0x553691,_0x553691--);}}['_fixObsoleteTags'](_0x684510){const _0x30a835=new Map(),_0x52480=this['editor']['model']['schema'];for(let _0x563828=0x1;_0x563828<_0x684510['length'];_0x563828++){let _0x38e438,_0x44eb84,_0x577616;const _0x35448b=_0x684510[_0x563828],_0x4d2a17=_0x684510[_0x563828-0x1];if('text'==_0x35448b['type'])continue;if(_0x35448b['type']!=_0x4d2a17['type'])continue;if(!_0x52480['isBlock'](_0x4d2a17['item'])||_0x52480['isLimit'](_0x4d2a17['item']))continue;if(!_0x52480['isBlock'](_0x35448b['item'])||_0x52480['isLimit'](_0x35448b['item']))continue;if((_0x684510[_0x563828]['isAdded']||_0x684510[_0x563828]['isAddSuggestion'])&&_0x684510[_0x563828-0x1]['isRemoved'])_0x38e438=_0x684510[_0x563828],_0x44eb84=_0x684510[_0x563828-0x1],_0x577616=_0x563828-0x1;else{if(!_0x684510[_0x563828]['isRemoved']||!_0x684510[_0x563828-0x1]['isAdded']&&!_0x684510[_0x563828-0x1]['isAddSuggestion'])continue;_0x38e438=_0x684510[_0x563828-0x1],_0x44eb84=_0x684510[_0x563828],_0x577616=_0x563828;}const _0x1dc3f3=_0x38e438['level']==_0x44eb84['level'],_0x128bff=Math['abs'](_0x38e438['level'])<Math['abs'](_0x44eb84['level'])&&0x0==_0x44eb84['distance'];(_0x1dc3f3||_0x128bff)&&(_0x30a835['set'](_0x44eb84['id'],_0x38e438['id']),_0x684510['splice'](_0x577616,0x1),_0x563828--,_0x38e438['isAdded']=!0x1);}for(let _0x588af1=0x0;_0x588af1<_0x684510['length'];_0x588af1++)_0x30a835['has'](_0x684510[_0x588af1]['pairId'])&&(_0x684510[_0x588af1]['pairId']=_0x30a835['get'](_0x684510[_0x588af1]['pairId']));}['_removeMissingPairs'](_0x39c0ef){const _0x376fe3=new Set(_0x39c0ef['map'](_0x45441b=>_0x45441b['id']));for(let _0x12f1c8=0x0;_0x12f1c8<_0x39c0ef['length'];_0x12f1c8++)_0x376fe3['has'](_0x39c0ef[_0x12f1c8]['pairId'])||0x0==_0x39c0ef[_0x12f1c8]['distance']||(_0x39c0ef[_0x12f1c8]['isIncorrect']=!0x0);return _0x39c0ef['filter'](_0x2cff4b=>!_0x2cff4b['isIncorrect']);}['_markMismatchedRemovedTags'](_0x338ad8){const _0x5340c9=new Set();for(let _0x132144=0x0;_0x132144<_0x338ad8['length'];_0x132144++){if(_0x5340c9['has'](_0x338ad8[_0x132144]['id'])&&_0x338ad8[_0x132144]['isRemoved']&&(_0x338ad8[_0x132144]['isIncorrect']=!0x0),_0x338ad8[_0x132144]['isIncorrect'])continue;if(0x0==_0x338ad8[_0x132144]['distance'])continue;if('elementStart'!=_0x338ad8[_0x132144]['type'])continue;if(null==_0x338ad8[_0x132144]['pairId'])continue;let _0x28202a=_0x132144+0x1,_0xa97d77=0x0;for(;_0x338ad8[_0x28202a]['id']!=_0x338ad8[_0x132144]['pairId'];)'elementStart'==_0x338ad8[_0x28202a]['type']?_0xa97d77++:'elementEnd'==_0x338ad8[_0x28202a]['type']&&_0xa97d77--,_0x28202a++;if(0x0!=_0xa97d77){if(_0x338ad8[_0x132144]['isRemoved'])_0x338ad8[_0x132144]['isIncorrect']=!0x0;else{for(;_0x28202a!=_0x132144;)_0x338ad8[_0x28202a]['isRemoved']&&0x0!=_0x338ad8[_0x28202a]['distance']&&(_0x338ad8[_0x28202a]['isIncorrect']=!0x0,_0x5340c9['add'](_0x338ad8[_0x28202a]['pairId'])),_0x28202a--;}}}return _0x338ad8['filter'](_0x38fed7=>!_0x38fed7['isIncorrect']);}['_removeUnsupportedChanges'](_0x47d46d){const _0x447593=this['editor']['model']['schema'];for(let _0x40bb47=0x0;_0x40bb47<_0x47d46d['length'];_0x40bb47++){if(!(_0x47d46d[_0x40bb47]['isAdded']||_0x47d46d[_0x40bb47]['isAddSuggestion']||_0x47d46d[_0x40bb47]['isRemoved']||_0x47d46d[_0x40bb47]['isRemoveSuggestion']))continue;if(0x0==_0x47d46d[_0x40bb47]['distance'])continue;const _0x4d4f0a=_0x47d46d[_0x40bb47]['item'];_0x447593['isBlock'](_0x4d4f0a)||_0x447593['isLimit'](_0x4d4f0a)||(_0x47d46d[_0x40bb47]['isAdded']&&delete _0x47d46d[_0x40bb47]['isAdded'],_0x47d46d[_0x40bb47]['isAddSuggestion']&&delete _0x47d46d[_0x40bb47]['isAddSuggestion'],_0x47d46d[_0x40bb47]['isRemoveSuggestion']&&delete _0x47d46d[_0x40bb47]['isRemoveSuggestion'],_0x47d46d[_0x40bb47]['isRemoved']&&(_0x47d46d[_0x40bb47]['isIncorrect']=!0x0));}return _0x47d46d['filter'](_0x324154=>!_0x324154['isIncorrect']);}['_makeModelFromTape'](_0x5d57d2,_0x3af34e,_0x45457e){const _0x45761a=new gt(),_0x10ad1b=[],_0x4f52db=new Map(),_0x13e9d7=this['editor']['model'],_0x3ad15d=_0x13e9d7['schema'],_0x52025e=[_0x45761a],_0x462395={},_0x2dcdaf={'isAdded':[],'isRemoved':[],'isAddSuggestion':[],'isRemoveSuggestion':[]};let _0x4d19de=null;const _0x5d3bb8=[0x0];for(let _0x3f1cd7=0x0;_0x3f1cd7<_0x5d57d2['length'];_0x3f1cd7++)if('elementStart'===_0x5d57d2[_0x3f1cd7]['type']){_0x5d57d2[_0x3f1cd7]['previousPosition']=_0x13e9d7['createPositionFromPath'](_0x45761a,_0x5d3bb8);const _0x59deb6=new ut(_0x5d57d2[_0x3f1cd7]['item']['name'],_0x5d57d2[_0x3f1cd7]['item']['getAttributes']());_0x52025e[0x0]['_appendChild'](_0x59deb6),_0x5d3bb8['push'](0x0),_0x52025e['unshift'](_0x59deb6),_0x5d57d2[_0x3f1cd7]['nextPosition']=_0x13e9d7['createPositionFromPath'](_0x45761a,_0x5d3bb8);}else'elementEnd'===_0x5d57d2[_0x3f1cd7]['type']?(_0x52025e['shift'](),_0x5d57d2[_0x3f1cd7]['previousPosition']=_0x13e9d7['createPositionFromPath'](_0x45761a,_0x5d3bb8),_0x5d3bb8['pop'](),_0x5d3bb8[_0x5d3bb8['length']-0x1]++,_0x5d57d2[_0x3f1cd7]['nextPosition']=_0x13e9d7['createPositionFromPath'](_0x45761a,_0x5d3bb8)):(_0x5d57d2[_0x3f1cd7]['previousPosition']=_0x13e9d7['createPositionFromPath'](_0x45761a,_0x5d3bb8),_0x4d19de?_0x4d19de['_data']+=_0x5d57d2[_0x3f1cd7]['item']['data']:_0x4d19de=new mt(_0x5d57d2[_0x3f1cd7]['item']['data'],_0x5d57d2[_0x3f1cd7]['item']['getAttributes']()),_0x5d57d2[_0x3f1cd7+0x1]&&'text'===_0x5d57d2[_0x3f1cd7+0x1]['type']&&_0x413d82(_0x4d19de,_0x5d57d2[_0x3f1cd7+0x1]['item'])||(_0x52025e[0x0]['_appendChild'](_0x4d19de),_0x4d19de=null),_0x5d3bb8[_0x5d3bb8['length']-0x1]+=_0x5d57d2[_0x3f1cd7]['item']['offsetSize'],_0x5d57d2[_0x3f1cd7]['nextPosition']=_0x13e9d7['createPositionFromPath'](_0x45761a,_0x5d3bb8));for(let _0x1c3863=0x0;_0x1c3863<_0x5d57d2['length'];_0x1c3863++){const _0x124ff1=_0x5d57d2[_0x1c3863]['previousPosition'],_0x3d6448=_0x5d57d2[_0x1c3863]['nextPosition'];for(const _0xb33afe of _0x5d57d2[_0x1c3863]['markersStart'])_0x4f52db['set'](_0xb33afe,{'start':_0x124ff1,'end':null});_0x189c31('isRemoveSuggestion',_0x1c3863,_0x124ff1,_0x3d6448),_0x189c31('isAddSuggestion',_0x1c3863,_0x124ff1,_0x3d6448),_0x189c31('isRemoved',_0x1c3863,_0x124ff1,_0x3d6448),_0x189c31('isAdded',_0x1c3863,_0x124ff1,_0x3d6448);for(const _0xbee012 of _0x5d57d2[_0x1c3863]['markersEnd']){const _0x344945=_0x4f52db['get'](_0xbee012);_0x344945?_0x344945['end']=_0x3d6448:_0x4f52db['set'](_0xbee012,{'start':_0x3d6448,'end':_0x3d6448});}}for(const [_0x383a64,_0x23a033]of _0x4f52db){const _0x1bc7d7=this['editor']['model']['createRange'](_0x23a033['start'],_0x23a033['end']);_0x45761a['markers']['set'](_0x383a64,_0x1bc7d7);}return _0x10ad1b['sort']((_0x1ddfcd,_0x40ca72)=>{const _0x2ba7c2=_0x45761a['markers']['get']('revision:'+_0x1ddfcd['id']),_0x42477a=_0x45761a['markers']['get']('revision:'+_0x40ca72['id']);return _0x2ba7c2['start']['isBefore'](_0x42477a['start'])?-0x1:_0x2ba7c2['start']['isAfter'](_0x42477a['start'])?0x1:_0x2ba7c2['end']['isBefore'](_0x42477a['end'])?-0x1:_0x2ba7c2['end']['isAfter'](_0x42477a['end'])?0x1:'add'===_0x1ddfcd['type']?-0x1:0x1;}),{'root':_0x45761a,'changes':_0x10ad1b};function _0x189c31(_0x386938,_0x2cc315,_0x47b4c3,_0x1d33c2){const _0xf666a1=!!_0x5d57d2[_0x2cc315][_0x386938],_0x1a23b6=_0xf666a1?_0x5d57d2[_0x2cc315][_0x386938]['userId']:null,_0x5bd6c2=_0x2cc315===_0x5d57d2['length']-0x1,_0xebd258=_0x2dcdaf[_0x386938][0x0],_0x20ad1c=_0x3ad15d['isObject'](_0x5d57d2[_0x2cc315]['item']);!_0x462395[_0x386938]&&_0xf666a1?_0x462395[_0x386938]={'start':_0x47b4c3,'tapeItem':_0x5d57d2[_0x2cc315],'userId':_0x1a23b6,'type':_0x386938}:_0x462395[_0x386938]&&!_0xf666a1?(_0x462395[_0x386938]['end']=_0x47b4c3,_0xcd7bb3(_0x462395[_0x386938]),_0x462395[_0x386938]=null):_0x462395[_0x386938]&&_0xf666a1&&_0x462395[_0x386938]['userId']!==_0x1a23b6&&(_0x462395[_0x386938]['end']=_0x47b4c3,_0xebd258&&_0xebd258['userId']===_0x462395[_0x386938]['userId']||_0xcd7bb3(_0x462395[_0x386938]),_0x462395[_0x386938]={'start':_0x47b4c3,'tapeItem':_0x5d57d2[_0x2cc315],'userId':_0x1a23b6,'type':_0x386938}),_0x462395[_0x386938]&&_0x20ad1c&&('elementStart'!==_0x5d57d2[_0x2cc315]['type']||_0xebd258&&_0xebd258['userId']===_0x1a23b6||_0x2dcdaf[_0x386938]['unshift']({'userId':_0x1a23b6,'object':_0x5d57d2[_0x2cc315]['item'],'change':_0x462395[_0x386938]}),'elementEnd'===_0x5d57d2[_0x2cc315]['type']&&_0xebd258&&_0xebd258['object']===_0x5d57d2[_0x2cc315]['item']&&(_0x2dcdaf[_0x386938]['shift'](),_0x462395[_0x386938]=_0xebd258['change'])),_0x462395[_0x386938]&&_0x5bd6c2&&(_0x462395[_0x386938]['end']=_0x1d33c2,_0xcd7bb3(_0x462395[_0x386938]),_0x462395[_0x386938]=null);}function _0xcd7bb3({start:_0x2b8c6f,end:_0x113be1,tapeItem:_0x1b322b,userId:_0x53a8b9,type:_0x10ec64}){const _0x5bcb30=_0x1b322b['item'],_0x3ab1f1=_0x13e9d7['schema']['isBlock'](_0x5bcb30)&&!_0x13e9d7['schema']['isLimit'](_0x5bcb30),_0x46040f=_0x2b8c6f['nodeAfter']==_0x113be1['parent']&&_0x113be1['isAtStart'];if(_0x3ab1f1&&_0x46040f)return;const _0x5907aa=_0x13e9d7['createRange'](_0x2b8c6f,_0x113be1),_0x49b458=_0x3af34e['get'](_0x53a8b9),_0x1a89f4=new r({'author':_0x49b458,'type':'isAdded'==_0x10ec64||'isAddSuggestion'==_0x10ec64?'add':'remove','data':{'isSuggestion':'isAddSuggestion'==_0x10ec64||'isRemoveSuggestion'==_0x10ec64},'createdAt':new Date(),'rootName':_0x45457e});_0x10ad1b['push'](_0x1a89f4),_0x45761a['markers']['set']('revision:'+_0x1a89f4['id'],_0x5907aa);}function _0x413d82(_0x23fd05,_0x64a2c0){const _0x219f9a=_0x23fd05['getAttributes'](),_0x3f84a6=_0x64a2c0['getAttributes']();for(const _0x212b6b of _0x219f9a){if(_0x212b6b[0x1]!==_0x64a2c0['getAttribute'](_0x212b6b[0x0]))return!0x1;_0x3f84a6['next']();}return _0x3f84a6['next']()['done'];}}['_setConversion'](){this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision','view':_0x445f5c=>{const _0x376df0=_0x445f5c['markerName']['split'](':')[0x1],_0x261554=this['_getChangeFromId'](_0x376df0);if(!_0x261554)return null;const _0x160b32='add'==_0x261554['type']?'insertion':'deletion',_0x3fa95d=['ck-suggestion-marker','ck-suggestion-marker-'+_0x160b32];return _0x261554['data']['isSuggestion']&&_0x3fa95d['push']('ck-suggestion-marker-'+_0x160b32+'-new'),this['activeChange']==_0x261554&&_0x3fa95d['push']('ck-suggestion-marker--active'),{'classes':_0x3fa95d,'attributes':{'data-change-id':_0x376df0}};}}),this['editor']['conversion']['for']('upcast')['add'](_0x22c7d6=>{_0x22c7d6['on']('element:pre',(_0x1d58b6,_0x17589e,_0x34b572)=>{const _0x123241=_0x17589e['viewItem']['getChild'](0x0);if(!_0x123241||!_0x123241['is']('element','code'))return;if(!_0x34b572['consumable']['consume'](_0x123241,{'attributes':['vid_start','vid_end']}))return;const _0x2b463e=_0x17589e['modelRange']['start']['nodeAfter'];_0x34b572['writer']['setAttribute']('vid_start',_0x123241['getAttribute']('vid_start'),_0x2b463e),_0x34b572['writer']['setAttribute']('vid_end',_0x123241['getAttribute']('vid_end'),_0x2b463e);},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['add'](_0x133b63=>{_0x133b63['on']('element',(_0x5ea910,_0x3a8455,_0x2dff2a)=>{if(!_0x2dff2a['consumable']['consume'](_0x3a8455['viewItem'],{'attributes':['vid_start','vid_end']}))return;if(_0x3a8455['modelRange']['isCollapsed'])return;const _0x2723c9=_0x3a8455['modelRange']['start']['nodeAfter'];_0x2723c9['hasAttribute']('vid_start')||_0x2723c9['hasAttribute']('vid')||(_0x2dff2a['writer']['setAttribute']('vid_start',_0x3a8455['viewItem']['getAttribute']('vid_start'),_0x2723c9),_0x2dff2a['writer']['setAttribute']('vid_end',_0x3a8455['viewItem']['getAttribute']('vid_end'),_0x2723c9));},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['elementToAttribute']({'view':{'name':'span','attributes':{'vid':!0x0}},'model':{'key':'vid','value':_0x4d386a=>_0x4d386a['getAttribute']('vid')}}),this['editor']['model']['schema']['on']('checkAttribute',(_0xbd0239,[,_0x5da7a0])=>{['vid_start','vid_end','vid']['includes'](_0x5da7a0)&&(_0xbd0239['return']=!0x0,_0xbd0239['stop']());},{'priority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x2b3336=>{_0x2b3336['on']('attribute:vid',(_0x27c731,_0x52529b,_0x225c58)=>{if('\x20'!=_0x52529b['item']['data']||_0x52529b['item']['parent']['maxOffset']>0x1)return;if(!_0x225c58['consumable']['consume'](_0x52529b['item'],_0x27c731['name']))return;const _0x1f8a3f=_0x225c58['writer'],_0x53da1c=_0x225c58['mapper']['toViewRange'](_0x52529b['range']);_0x1f8a3f['wrap'](_0x53da1c,_0x1f8a3f['createAttributeElement']('span'));});}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',function(_0x54f9f9){const _0x5e5e0d=_0x54f9f9['plugins']['get']('RevisionViewer');return(_0x261de1,_0xb6b6d,_0x566b05)=>{const _0x3085fa=_0xb6b6d['markerName']['split'](':')[0x1],_0x13b691=_0x5e5e0d['_getChangeFromId'](_0x3085fa);if(!_0x13b691)return null;const _0x4bc2d7='add'==_0x13b691['type']?'split':'merge';if(!_0x566b05['consumable']['test'](_0xb6b6d['markerRange'],_0x261de1['name']))return;const _0x5dc296=_0xb6b6d['markerRange']['getWalker'](),_0x1331e5=_0xb6b6d['markerRange']['start'],_0x166fa5=_0x54f9f9['model']['schema'];let _0x2bf024=null,_0xb8378a=null,_0x3b51be=!0x1,_0x3370cc=!0x1;for(const _0x27bab6 of _0x5dc296){const _0x1f1f8c=_0x27bab6['item'];_0x3b51be=_0x3b51be||_0x166fa5['isContent'](_0x1f1f8c);const _0x3d9919=_0x566b05['mapper']['toViewElement'](_0x1f1f8c);if(_0x3d9919&&_0x3d9919['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x27bab6['type']&&(_0x166fa5['isBlock'](_0x1f1f8c)&&!_0x166fa5['isLimit'](_0x1f1f8c)&&(_0x1f1f8c['nextSibling']||_0x1331e5['isAtEnd']?_0x2bf024&&_0x2bf024['parent']==_0x1f1f8c||(_0x2bf024=_0x1f1f8c,_0x24c060(_0x27bab6['previousPosition']),_0x3370cc=!0x0):_0xb8378a=_0xb8378a||_0x27bab6['previousPosition']));}function _0x24c060(_0x28decd){const _0x478e0=_0x566b05['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x4bc2d7}),_0x255771=_0x566b05['mapper']['toViewPosition'](_0x28decd);_0x13b691['data']['isSuggestion']&&_0x566b05['writer']['addClass']('ck-suggestion-marker-'+_0x4bc2d7+'-new',_0x478e0),_0x5e5e0d['activeChange']==_0x13b691&&_0x566b05['writer']['addClass']('ck-suggestion-marker--active',_0x478e0),_0x566b05['writer']['insert'](_0x255771,_0x478e0),_0x566b05['mapper']['bindElementToMarker'](_0x478e0,_0xb6b6d['markerName']);}_0x3b51be||_0x3370cc||!_0xb8378a||_0x24c060(_0xb8378a);};}(this['editor']),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision',(_0x1f1ec1,_0x209d83,_0x686478)=>{const _0x41a6d8=_0x686478['mapper']['markerNameToElements'](_0x209d83['markerName']);if(_0x41a6d8){for(const _0x8a707f of _0x41a6d8)(_0x8a707f['hasClass']('ck-suggestion-marker-split')||_0x8a707f['hasClass']('ck-suggestion-marker-merge'))&&(_0x686478['mapper']['unbindElementFromMarkerName'](_0x8a707f,_0x209d83['markerName']),_0x686478['writer']['remove'](_0x8a707f));}},{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',(_0x327f42,_0x2cdcd4,_0x499641)=>{const _0x25ca49=_0x2cdcd4['markerName']['split'](':')[0x1],_0x18d1a0=this['_getChangeFromId'](_0x25ca49);if(!_0x18d1a0)return null;const _0x3d1f8c='add'==_0x18d1a0['type']?'split':'merge';if(_0x499641['consumable']['test'](_0x2cdcd4['markerRange'],_0x327f42['name']))for(const _0x5690ff of _0x2cdcd4['markerRange']['getItems']()){if(!_0x5690ff['is']('element','softBreak'))continue;const _0x176f21=_0x499641['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x3d1f8c}),_0x2ca8c2=_0x499641['mapper']['toViewPosition'](this['editor']['model']['createPositionBefore'](_0x5690ff));_0x18d1a0['data']['isSuggestion']&&_0x499641['writer']['addClass']('ck-suggestion-marker-'+_0x3d1f8c+'-new',_0x176f21),this['activeChange']==_0x18d1a0&&_0x499641['writer']['addClass']('ck-suggestion-marker--active',_0x176f21),_0x499641['writer']['insert'](_0x2ca8c2,_0x176f21),_0x499641['mapper']['bindElementToMarker'](_0x176f21,_0x2cdcd4['markerName']);}},{'priority':'high'}),this['editor']['model']['document']['on']('change',()=>{this['editor']['editing']['view']['change'](_0x31edf1=>{for(const _0x563bee of this['editor']['model']['document']['getRootNames']()){const _0x36f209=this['editor']['model']['document']['getRoot'](_0x563bee),_0x5b8661=this['editor']['editing']['view']['document']['getRoot'](_0x563bee);if(_0x5b8661){const _0x211569=_0x36f209['getAttribute']('revisionHistoryAttachChange');if(_0x31edf1['removeAttribute']('data-change-id',_0x5b8661),_0x31edf1['removeClass']('ck-revision-history-root-add',_0x5b8661),_0x31edf1['removeClass']('ck-revision-history-root-remove',_0x5b8661),_0x31edf1['removeClass']('ck-revision-history-root--active',_0x5b8661),_0x211569){const _0x1b907d=this['_getChangeFromId'](_0x211569);if(!_0x1b907d)return null;_0x31edf1['setAttribute']('data-change-id',_0x211569,_0x5b8661),_0x31edf1['addClass']('ck-revision-history-root-'+_0x1b907d['type'],_0x5b8661),this['activeChange']==_0x1b907d&&_0x31edf1['addClass']('ck-revision-history-root--active',_0x5b8661);}}}});}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'comment','model':_0x4172d8=>'revision-comment:'+_0x4172d8,'converterPriority':'highest'}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'suggestion','model':_0x34d575=>'revision-suggestion:'+_0x34d575,'converterPriority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision-suggestion','view':_0x1a1e1a=>({'name':'suggestion:'+_0x1a1e1a,'group':'revision-suggestion'}),'converterPriority':'highest'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision-suggestion','view':_0x5bca92=>{const _0x4ee63d=_0x5bca92['markerName']['split'](':')[0x1];return'insertion'!=_0x4ee63d&&'deletion'!=_0x4ee63d?null:{'classes':['ck-suggestion-preview-marker','ck-suggestion-preview-marker-'+_0x4ee63d]};}}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:deletion',X(this['editor'],'merge'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:insertion',X(this['editor'],'split'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision-suggestion',(_0x28a32c,_0x51c9e3,_0x2b85aa)=>{const _0x37f7d0=_0x2b85aa['mapper']['markerNameToElements'](_0x51c9e3['markerName']);if(_0x37f7d0){for(const _0x14596 of _0x37f7d0)_0x14596['is']('uiElement')&&(_0x2b85aa['mapper']['unbindElementFromMarkerName'](_0x14596,_0x51c9e3['markerName']),_0x2b85aa['writer']['remove'](_0x14596));}},{'priority':'high'});}['_getChangeFromId'](_0x29a45f){return this['_changeIdToChange']['get'](_0x29a45f);}['_getViewForChange'](_0x189154){return this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=new Q(this['editor']['locale'],_0x189154),this['_changeView'];}['_initInteractions'](){this['editor']['model']['document']['selection']['observeMarkers']('revision'),this['on']('change:activeView',(_0x2fa3ac,_0xbb754e,_0x301d67,_0x2f757a)=>{_0x2f757a&&this['_balloon']['remove'](_0x2f757a),_0x301d67&&(this['_balloon']['add']({'view':_0x301d67,'stackId':'revisionHistoryLabel','position':{'target':()=>{const _0x35e82b=this['editor']['editing'],_0x20910e=this['_getChangeFromId'](_0x301d67['changeId']);let _0x14a48f;if(_0x20910e['data']['isOnRoot']){const _0x249872=_0x35e82b['view']['getDomRoot'](_0x20910e['rootName']);_0x14a48f=Array['from'](_0x249872['getClientRects']());}else{const _0x113b70=this['editor']['model']['markers']['get']('revision:'+_0x301d67['changeId']);_0x14a48f=Array['from'](_0x35e82b['mapper']['markerNameToElements'](_0x113b70['name']))['map'](_0x18ba59=>_0x35e82b['view']['domConverter']['mapViewToDom'](_0x18ba59))['map'](_0x4ee363=>Array['from'](_0x4ee363['getClientRects']()))['flat']();}if(!this['_activeViewTarget'])return _0x14a48f[0x0];return _0x14a48f['find'](_0x3d6d16=>_0x3d6d16['top']-0x3<=this['_activeViewTarget']['y']&&_0x3d6d16['bottom']+0x3>=this['_activeViewTarget']['y']&&_0x3d6d16['left']-0x3<=this['_activeViewTarget']['x']&&_0x3d6d16['right']+0x3>=this['_activeViewTarget']['x'])||_0x14a48f[0x0];}}}),this['_balloon']['showStack']('revisionHistoryLabel'));}),this['on']('change:activeChange',(_0x3924a7,_0x31687b,_0x2c6d93,_0x4da6f0)=>{this['activeView']=_0x2c6d93?this['_getViewForChange'](_0x2c6d93):null,this['editor']['model']['change'](()=>{const _0x35da64=this['editor']['editing'];_0x4da6f0&&(_0x4da6f0['data']['isOnRoot']?_0x35da64['view']['change'](_0xa2879a=>{_0xa2879a['removeClass']('ck-revision-history-root--active',_0x35da64['view']['document']['getRoot'](_0x4da6f0['rootName']));}):_0x35da64['reconvertMarker']('revision:'+_0x4da6f0['id'])),_0x2c6d93&&(_0x2c6d93['data']['isOnRoot']?_0x35da64['view']['change'](_0x395587=>{_0x395587['addClass']('ck-revision-history-root--active',_0x35da64['view']['document']['getRoot'](_0x2c6d93['rootName']));}):_0x35da64['reconvertMarker']('revision:'+_0x2c6d93['id']));});}),this['listenTo'](this['editor']['editing']['view']['document'],'mouseover',(_0x544557,_0x3f7620)=>{if(this['activeChange'])return;const _0x329ca4=this['_findChangeIdFromDomTarget'](_0x3f7620['target']),_0x5d3d1e=this['_changeIdToChange']['get'](_0x329ca4);_0x5d3d1e?(this['_activeViewTarget']={'x':_0x3f7620['domEvent']['x'],'y':_0x3f7620['domEvent']['y']},this['activeView']=this['_getViewForChange'](_0x5d3d1e)):(this['_activeViewTarget']=null,this['activeView']=null);}),this['listenTo'](this['editor']['editing']['view']['document'],'mousedown',(_0x4ffe0d,_0x414fca)=>{const _0x1f2d1b=this['_findChangeIdFromDomTarget'](_0x414fca['target']),_0xcf976c=this['_changeIdToChange']['get'](_0x1f2d1b);_0xcf976c?(this['_activeViewTarget']={'x':_0x414fca['domEvent']['x'],'y':_0x414fca['domEvent']['y']},_0xcf976c===this['activeChange']?this['_balloon']['updatePosition']():this['activeChange']=_0xcf976c):(this['_activeViewTarget']=null,this['activeChange']=null);});}['_findChangeIdFromDomTarget'](_0x34b8b8){do{const _0x59bbb6=_0x34b8b8['getAttribute']('data-change-id');if(_0x59bbb6)return _0x59bbb6;_0x34b8b8=_0x34b8b8['parent'];}while(_0x34b8b8);return null;}['_cleanMarkers'](){this['editor']['model']['change'](_0x2eb654=>{for(const _0x4cf40c of this['editor']['model']['markers'])_0x2eb654['removeMarker'](_0x4cf40c);});}}function X(_0x2e57a3,_0x16fcbf){return(_0x1b7f0a,_0x2ffebe,_0x58a482)=>{if(!_0x58a482['consumable']['test'](_0x2ffebe['markerRange'],_0x1b7f0a['name']))return;const _0x45a515=_0x2ffebe['markerRange']['getWalker'](),_0x341210=_0x2ffebe['markerRange']['start'],_0x5a483d=_0x2e57a3['model']['schema'];let _0xc46b89=null,_0x530f63=null,_0x1dface=!0x1,_0x13758d=!0x1;for(const _0x43f3a5 of _0x45a515){const _0x16a532=_0x43f3a5['item'];_0x1dface=_0x1dface||_0x5a483d['isContent'](_0x16a532);const _0x3a3fc3=_0x58a482['mapper']['toViewElement'](_0x16a532);if(_0x3a3fc3&&_0x3a3fc3['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x43f3a5['type']&&(_0x5a483d['isBlock'](_0x16a532)&&!_0x5a483d['isLimit'](_0x16a532)&&(_0x16a532['nextSibling']||_0x341210['isAtEnd']?_0xc46b89&&_0xc46b89['parent']==_0x16a532||(_0xc46b89=_0x16a532,_0x151d3d(_0x43f3a5['previousPosition']),_0x13758d=!0x0):_0x530f63=_0x530f63||_0x43f3a5['previousPosition']));}function _0x151d3d(_0xfaa5ef){const _0x1956dc=_0x58a482['mapper']['toViewPosition'](_0xfaa5ef),_0x434f88=_0x58a482['writer']['createUIElement']('span',{'class':'ck-suggestion-preview-marker-'+_0x16fcbf});_0x58a482['writer']['insert'](_0x1956dc,_0x434f88),_0x58a482['mapper']['bindElementToMarker'](_0x434f88,_0x2ffebe['markerName']);}_0x1dface||_0x13758d||!_0x530f63||_0x151d3d(_0x530f63);};}class wt extends _0x23e514{constructor(_0x5821e3){super(_0x5821e3);const _0x7cbe91=_0x5821e3['plugins']['get'](m);this['affectsData']=!0x1,this['listenTo'](_0x7cbe91,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x7cbe91,'change:isEnabled',()=>this['refresh']());}['execute'](){const _0x372427=this['editor'],_0x1bcdf5=_0x372427['plugins']['get'](m),_0x48c9ce=_0x1bcdf5['isReady']?_0x1bcdf5['diff']['newRevisionId']:null;_0x372427['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x48c9ce);}['refresh'](){const {isReady:_0x56bdb8,isEnabled:_0x31d3f3,repository:_0x26d860,diff:_0x45f2e}=this['editor']['plugins']['get'](m),_0x4abbff=_0x45f2e&&_0x26d860['getLaterVisibleRevision'](_0x45f2e['newRevisionId']);this['isEnabled']=_0x56bdb8&&_0x31d3f3&&Boolean(_0x4abbff);}}class pt extends _0x23e514{['_step'];constructor(_0x234f74,{direction:_0x4111e8}){super(_0x234f74);const _0x10e765=_0x234f74['plugins']['get'](m);this['affectsData']=!0x1,this['_step']='forward'===_0x4111e8?0x1:-0x1,this['listenTo'](_0x10e765,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x10e765,'change:isEnabled',()=>this['refresh']()),this['listenTo'](_0x10e765,'change:activeChange',()=>this['refresh']());}['execute'](){const _0x124638=this['editor'],_0x437047=_0x124638['plugins']['get'](m),{isNavigationMode:_0x4ec6e4,currentChangeNumber:_0x136f54}=_0x437047;let _0x5bc919;if(_0x437047['activeChange']=_0x4ec6e4?_0x437047['diff']['changes']['get'](_0x136f54+this['_step']):_0x437047['diff']['changes']['first'],_0x437047['activeChange']['data']['isOnRoot'])_0x5bc919=_0x124638['editing']['view']['getDomRoot'](_0x437047['activeChange']['rootName']);else{const _0x4c28db=_0x124638['model']['markers']['get']('revision:'+_0x437047['activeChange']['id']);_0x5bc919=_0x225b7e(_0x124638['editing'],_0x4c28db);}_0x2606af({'target':_0x5bc919,'viewportOffset':0x28});}['refresh'](){const {isNavigationMode:_0x42b5ec,currentChangeNumber:_0x45ec7c,numberOfChanges:_0x5f2da,isReady:_0x485d51,isEnabled:_0xed26ef}=this['editor']['plugins']['get'](m);this['isEnabled']=!!(_0xed26ef&&_0x485d51&&_0x5f2da)&&(!_0x42b5ec||(0x1===this['_step']?_0x45ec7c<_0x5f2da-0x1:_0x45ec7c>0x0));}}class li extends _0x18313a{constructor(_0x480b8e){super(_0x480b8e);const _0x25dae3=this['bindTemplate'],_0x3eb2eb=new _0x29dce1(_0x480b8e),_0x11d7f1=new _0x29dce1(_0x480b8e);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',(_0x5721a0,_0x579dbb)=>_0x5721a0&&_0x579dbb>0x0),this['bind']('_statusText')['to'](this,'isReady',this,'currentChangeNumber',this,'numberOfChanges',this,'isNavigationMode',(_0xdb201c,_0x4a43f0,_0x160ef1,_0x4d87fd)=>{if(!_0xdb201c)return g(_0x480b8e,'Loading...');if(!_0x160ef1)return g(_0x480b8e,'No\x20changes');const _0x228e73=g(_0x480b8e,'NUMBER_OF_CHANGES',_0x160ef1);return _0x4d87fd?g(_0x480b8e,'X_OF_Y_CHANGES',[_0x4a43f0+0x1,_0x160ef1]):_0x228e73;}),_0x3eb2eb['set']({'label':g(_0x480b8e,'Show\x20previous\x20change'),'tooltip':!0x0,'icon':_0x5abbae}),_0x11d7f1['set']({'label':g(_0x480b8e,'Show\x20next\x20change'),'tooltip':!0x0,'icon':_0x4ea29c}),_0x3eb2eb['bind']('isEnabled')['to'](this,'isBackwardNavigationEnabled'),_0x11d7f1['bind']('isEnabled')['to'](this,'isForwardNavigationEnabled'),_0x3eb2eb['on']('execute',()=>this['fire']('execute','backward')),_0x11d7f1['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',_0x25dae3['if']('_isStatusLabelVisible','ck-hidden',_0x2b9d1c=>!_0x2b9d1c)]},'children':[{'text':_0x25dae3['to']('isNavigationMode',_0x3fe85d=>_0x3fe85d?g(_0x480b8e,'EDIT_X_OF_Y_REVISIONS')+':\x20':g(_0x480b8e,'Total')+':\x20')}]},{'text':_0x25dae3['to']('_statusText')}]},new _0x15eefc(),{'tag':'div','attributes':{'class':['ck-revision-history-ui__changes-navigation__navigation']},'children':[_0x3eb2eb,_0x11d7f1]}]});}}const ce='ck-editor__editable__loading-overlay';class le extends _0x3ba875{static get['pluginName'](){return'RevisionViewerLoadingOverlay';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['show'](){const _0xaf2c17=this['editor']['editing']['view'];_0xaf2c17['change'](_0xb4a12a=>{for(const _0x13d5e3 of _0xaf2c17['document']['roots'])_0xb4a12a['addClass'](ce,_0x13d5e3);});}['hide'](){const _0x4af265=this['editor']['editing']['view'];_0x4af265['change'](_0x1c2dd7=>{for(const _0x1add9c of _0x4af265['document']['roots'])_0x1c2dd7['removeClass'](ce,_0x1add9c);});}}class R extends _0x3ba875{static get['pluginName'](){return'RevisionViewerUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[m,le];}['init'](){const _0x2bf5da=this['editor'],_0x4b3755=_0x2bf5da['plugins']['get'](m),_0x18ab14=_0x2bf5da['plugins']['get'](le);_0x2bf5da['ui']['componentFactory']['add']('exitToEditing',_0x16e0f9=>{const _0x4ac8ef=new _0x29dce1(_0x16e0f9);return _0x4ac8ef['set']({'label':g(_0x16e0f9,'Back\x20to\x20editing'),'icon':_0x55c272,'withText':!0x0,'tooltip':!0x0,'class':'ck-revision-history-ui__back-to-editing'}),this['listenTo'](_0x4ac8ef,'execute',()=>{_0x2bf5da['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}),_0x4ac8ef;}),_0x2bf5da['ui']['componentFactory']['add']('restoreRevision',_0x21defb=>{const _0xa0dce9=new _0x29dce1(_0x21defb);return _0xa0dce9['set']({'label':g(_0x21defb,'Restore\x20this\x20revision'),'withText':!0x0,'tooltip':!0x0}),_0xa0dce9['bind']('isEnabled')['to'](_0x2bf5da['commands']['get']('restoreRevision')),this['listenTo'](_0xa0dce9,'execute',()=>_0x2bf5da['execute']('restoreRevision')),_0xa0dce9;}),_0x2bf5da['ui']['componentFactory']['add']('changesNavigation',_0x11f648=>{const _0x1ab322=new li(_0x11f648),_0x5622d7=_0x2bf5da['commands']['get']('showPreviousChange'),_0x3556e2=_0x2bf5da['commands']['get']('showNextChange');return _0x1ab322['bind']('isBackwardNavigationEnabled')['to'](_0x5622d7,'isEnabled'),_0x1ab322['bind']('isForwardNavigationEnabled')['to'](_0x3556e2,'isEnabled'),_0x1ab322['bind']('isReady','currentChangeNumber','numberOfChanges','isNavigationMode')['to'](_0x4b3755),this['listenTo'](_0x1ab322,'execute',(_0x39ab6d,_0x3b9500)=>{_0x2bf5da['execute']('forward'===_0x3b9500?'showNextChange':'showPreviousChange');}),_0x1ab322;}),_0x18ab14['show'](),_0x4b3755['on']('change:isReady',(_0x2b7e97,_0x2bb898,_0x31d4a7)=>{_0x31d4a7?_0x18ab14['hide']():_0x18ab14['show']();});}}class lt extends nt{['_resizeObserver']=null;constructor(_0x2dc23d,_0x3458fd){super(_0x2dc23d,_0x3458fd);const _0x471630=this['bindTemplate'];this['set']({'label':g(_0x2dc23d,'Revision\x20name'),'_tooltipString':''}),this['fieldView']['placeholder']=g(_0x2dc23d,'Enter\x20the\x20revision\x20name'),this['extendTemplate']({'tag':'span','attributes':{'class':['ck-revision-history-sidebar__revision-name'],'data-cke-tooltip-text':_0x471630['to']('_tooltipString'),'data-cke-tooltip-position':'s','data-cke-tooltip-class':'ck-tooltip_multi-line'}});}['render'](){super['render'](),this['_resizeObserver']=new at(this['fieldView']['element'],()=>this['_updateTooltipText']()),this['listenTo'](this['fieldView'],'input',()=>this['_updateTooltipText']());}['destroy'](){super['destroy'](),this['_resizeObserver']&&this['_resizeObserver']['destroy']();}['_updateTooltipText'](){const _0x266044=this['fieldView']['element'];this['_tooltipString']=_0x266044['scrollWidth']>_0x266044['clientWidth']&&_0x266044['value']||'';}}class oi extends _0x18313a{constructor(_0x4f92d6,_0x1ee551,_0x5b9bec){super(_0x4f92d6);const _0x1fa6fe=new _0x9e0bb7();_0x1fa6fe['set']({'content':_0x4379bb,'viewBox':'0\x200\x2011\x2010'});const _0x2e0ca9=['ck','ck-revision-history-sidebar__revision-author'];_0x5b9bec&&_0x2e0ca9['push']('ck-revision-history-sidebar__revision-author_creator');const _0x200a64=[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision-author__name'],'title':g(_0x4f92d6,_0x5b9bec?'Revision\x20creator':'Revision\x20author')},'children':[_0x1fa6fe,_0x1ee551['name']]}];this['setTemplate']({'tag':'li','attributes':{'class':_0x2e0ca9},'children':_0x200a64});}}function ni(_0x34dd1d,_0x2fc63f){const _0x2e8fae=_0x34dd1d['bindTemplate'],_0x360358=_0x34dd1d['locale'],_0x1af6ed=_0x3564c9(_0x360358);_0x1af6ed['panelPosition']='sw';const _0x1d6d46=function(_0x416dbd,_0x32bc65){const _0x11d590=function(_0xad8cf1,_0x3f4214){const _0x546b5e=_0xad8cf1['locale'],_0x2dcbff={'Compare\x20against\x20selected':g(_0x546b5e,'Compare\x20against\x20selected'),'Name\x20this\x20revision':g(_0x546b5e,'Name\x20this\x20revision'),'Restore\x20this\x20revision':g(_0x546b5e,'Restore\x20this\x20revision')};return _0x3f4214['map'](_0x301e29=>{const _0x425d84=_0x2dcbff[_0x301e29['name']];return _0x425d84&&_0x425d84!==_0x301e29['name']&&(_0x301e29['name']=_0x425d84),_0x301e29;});}(_0x416dbd,_0x32bc65),_0x351ddf=new _0x5495c4();for(const _0x2b9fb5 of _0x11d590){const _0x469760={'type':'button','model':new to({'label':_0x2b9fb5['name'],'class':_0x2b9fb5['class'],'withText':!0x0,'role':'menuitem','_action':_0x2b9fb5['action']})};_0x469760['model']['bind']('isEnabled')['to'](_0x416dbd,'isActionsDropdownOpen',_0x153870=>'function'!=typeof _0x2b9fb5['isEnabled']||(!_0x153870||_0x2b9fb5['isEnabled'](_0x416dbd))),_0x351ddf['add'](_0x469760);}return _0x351ddf;}(_0x34dd1d,_0x2fc63f);return _0x34dd1d['bind']('isActionsDropdownOpen')['to'](_0x1af6ed,'isOpen'),_0x1af6ed['buttonView']['set']({'label':g(_0x360358,'Show\x20more\x20items'),'tooltip':!0x0,'tooltipPosition':'sw','icon':_0x2cdf3c}),_0x1af6ed['extendTemplate']({'attributes':{'class':['ck-revision-history-sidebar__revision__actions',_0x2e8fae['if']('isActionsDropdownOpen','ck-on')]},'on':{'click':_0x2e8fae['to'](_0x455638=>_0x455638['stopPropagation']())}}),_0x1af6ed['on']('execute',_0x3b57fb=>{_0x34dd1d['isReady']&&'function'==typeof _0x3b57fb['source']['_action']&&_0x3b57fb['source']['_action'](_0x34dd1d);}),_0x294d83(_0x1af6ed,_0x1d6d46,{'role':'menu'}),_0x1af6ed['listenTo'](_0x34dd1d,'change:isActionsDropdownOpen',(_0x4de874,_0x23c409,_0x466874)=>{if(_0x466874)for(const _0x1eef7f of _0x1af6ed['listView']['items']){const _0x25e82b=_0x1eef7f['children']['first'],_0x58b679=_0x2fc63f['find'](_0x5f2bc9=>_0x5f2bc9['action']===_0x25e82b['_action'])['isVisible'];_0x1eef7f['isVisible']=void 0x0===_0x58b679||_0x58b679(_0x34dd1d);}}),_0x1af6ed;}class ai extends/* #__PURE__ -- @preserve */
|
|
26
|
+
_0x1f1bf1(_0x18313a){['id'];['revisionNameView'];['revisionActionsView'];['_revision'];['_requireRevisionName'];constructor(_0x29d823,_0x37c540,_0x2a671b,_0x5b0e06){super(_0x29d823);const _0x279b18=this['bindTemplate'],_0x444a4a=function(_0x40699b,_0x29698b){const _0x4bd527=Array['from'](_0x29698b['authors'])['filter'](_0x171a16=>_0x171a16!=_0x29698b['creator']);return _0x29698b['creator']&&_0x4bd527['unshift'](_0x29698b['creator']),_0x4bd527['map'](_0x48c321=>new oi(_0x40699b,_0x48c321,_0x48c321==_0x29698b['creator']));}(_0x29d823,_0x37c540);this['id']=_0x37c540['id'],this['_revision']=_0x37c540,this['_requireRevisionName']=_0x5b0e06,this['bind']('name','createdAt')['to'](_0x37c540),this['bind']('_createdAtFormatted')['to'](this,'createdAt',_0x53d179=>{return _0x49b837=_0x29d823['uiLanguage'],(_0x3125b1=_0x53d179)['toLocaleDateString'](_0x49b837,{'month':'long','day':'numeric'})+',\x20'+_0x3125b1['toLocaleTimeString'](_0x49b837,{'hour':'numeric','minute':'numeric'});var _0x49b837,_0x3125b1;}),this['set']('isSelected',!0x1),this['set']('isHighlighted',!0x1),this['set']('isActionsDropdownOpen',!0x1),this['set']('isReady',!0x1),this['set']('isEnabled',!0x1),this['revisionNameView']=new lt(_0x29d823,ti),this['revisionNameView']['fieldView']['extendTemplate']({'attributes':{'maxlength':'220'}}),this['revisionNameView']['fieldView']['bind']('value')['to'](this,'name',_0x1d1c0e=>_0x1d1c0e||this['_createdAtFormatted']),this['revisionNameView']['bind']('isEnabled')['to'](this,'isSelected',this,'isEnabled',(_0x5989f7,_0x18f6f9)=>_0x5989f7&&_0x18f6f9),this['revisionActionsView']=_0x2a671b&&_0x2a671b['length']?ni(this,_0x2a671b):'',this['revisionActionsView']&&this['revisionActionsView']['bind']('isEnabled')['to'](this),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision-wrapper',_0x279b18['if']('isConfirm','ck-revision-history-sidebar__revision-wrapper_confirmation_visible')]},'children':[{'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision',_0x279b18['if']('isEnabled','ck-disabled',_0x735598=>!_0x735598),_0x279b18['if']('isSelected','ck-revision-history-sidebar__revision_selected'),_0x279b18['if']('isHighlighted','ck-revision-history-sidebar__revision_highlighted'),_0x279b18['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':_0x279b18['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':_0x444a4a}]},this['revisionActionsView']],'on':{'click':_0x279b18['to'](_0x1e34bc=>{_0x1e34bc['srcElement']['closest']('.ck-thread__remove-confirm')||this['isReady']&&this['isEnabled']&&this['fire']('select',{'id':this['id']});})}}]});}['render'](){super['render']();const _0x4d029d=this['revisionNameView']['fieldView']['element'];this['listenTo'](_0x4d029d,'change',()=>{this['_requireRevisionName']&&!_0x4d029d['value']||this['fire']('setName',{'id':this['id'],'name':_0x4d029d['value']}),_0x4d029d['value']||(_0x4d029d['value']=this['name']?this['name']:this['_createdAtFormatted']);});}['select'](){this['isSelected']=!0x0;}['deselect'](){this['isSelected']=!0x1;}['highlight'](){this['isHighlighted']=!0x0;}['unhighlight'](){this['isHighlighted']=!0x1;}}function mi(_0x449721,_0x109eee){const _0x246f62=_0x16a5a3['fromJSDate'](_0x449721)['setLocale'](_0x109eee),_0x4633e8=_0x16a5a3['local'](),_0x7e88e5=_0x4633e8['minus']({'days':0x1})['startOf']('day');let _0x4c5bc2,_0xa833d5;return _0x246f62['hasSame'](_0x4633e8,'day')?(_0x4c5bc2=_0x246f62['startOf']('day')['toJSDate'](),_0xa833d5=_0x246f62['toRelativeCalendar']()):_0x246f62['hasSame'](_0x7e88e5,'day')?(_0x4c5bc2=_0x7e88e5['toJSDate'](),_0xa833d5=_0x246f62['toRelativeCalendar']()):_0x246f62['hasSame'](_0x4633e8,'week')?(_0x4c5bc2=_0x246f62['startOf']('week')['toJSDate'](),_0xa833d5=_0x246f62['weekdayLong']||''):_0x246f62['hasSame'](_0x4633e8,'year')?(_0x4c5bc2=_0x246f62['startOf']('month')['toJSDate'](),_0xa833d5=_0x246f62['monthLong']||''):(_0x4c5bc2=_0x246f62['startOf']('year')['toJSDate'](),_0xa833d5=String(_0x246f62['year'])),{'startDate':_0x4c5bc2,'localizedPeriodName':_0xa833d5};}class _i extends _0x18313a{['startDate'];['revisionViews'];['_revisionActions'];['_requireRevisionName'];constructor(_0x1f2d34,_0x8e805b,_0x3a9db9,_0x287b7b){super(_0x1f2d34);const _0x75892b=mi(_0x8e805b,this['locale']['uiLanguage'])['localizedPeriodName'];this['startDate']=_0x8e805b,this['revisionViews']=this['createCollection'](),this['_revisionActions']=_0x3a9db9,this['_requireRevisionName']=_0x287b7b,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':_0x75892b}]},{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__time-period__revisions']},'children':this['revisionViews']}]});}['addRevision'](_0x498f1c){const _0x1bfe32=new ai(this['locale'],_0x498f1c,this['_revisionActions'],this['_requireRevisionName']);this['revisionViews']['add'](_0x1bfe32);}['removeRevision'](_0x4beb9b){const _0x3f9d4b=this['revisionViews']['find'](_0x4eb9fc=>_0x4eb9fc['id']===_0x4beb9b['id']);this['revisionViews']['remove'](_0x3f9d4b);}}class as extends _0x18313a{constructor(_0x102f0f){super(_0x102f0f);const _0x520afc=new _0x9e0bb7();_0x520afc['content']=_0x209882,this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset_all','ck-revision-history-sidebar__header']},'children':[_0x520afc,{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__header__label']},'children':[g(_0x102f0f,'Revision\x20history')]}]});}}class vi extends _0x18313a{['timePeriodViews'];['_revisions'];['_revisionActions'];['_requireRevisionName'];constructor(_0x3dddbb,_0x546048,_0x3f4f00,_0x3ede37){super(_0x3dddbb);const _0x2c649a=this['bindTemplate'];this['timePeriodViews']=this['createCollection'](),this['timePeriodViews']['delegate']('select')['to'](this),this['timePeriodViews']['delegate']('setName')['to'](this),this['_revisions']=_0x546048,this['_revisionActions']=_0x3f4f00,this['_requireRevisionName']=_0x3ede37,this['on']('select',(_0x44f336,_0x370601)=>{this['fire']('revisionSelected',_0x370601);}),this['on']('setName',(_0x24a0f1,_0x3c597f)=>{this['fire']('revisionSetName',_0x3c597f);}),this['set']('isEnabled',!0x1),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-rounded-corners','ck-revision-history-sidebar']},'children':[new as(_0x3dddbb),{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__timeline',_0x2c649a['if']('isEnabled','ck-disabled',_0x2ddad8=>!_0x2ddad8)]},'children':this['timePeriodViews']}]});}['render'](){super['render']();for(const _0x1e65ba of this['_revisions'])this['_addRevision'](_0x1e65ba);this['_revisions']['on']('add',(_0x2dcef3,_0x24373a)=>{this['_addRevision'](_0x24373a);}),this['_revisions']['on']('remove',(_0x3a88bd,_0x187245)=>{this['_removeRevision'](_0x187245);});}get['revisionViews'](){return this['timePeriodViews']['map'](_0x1ee149=>_0x1ee149['revisionViews']['map'](_0x2c097b=>_0x2c097b))['flat']();}['selectRevision'](_0x1daa06){for(const _0x1adc43 of this['revisionViews'])_0x1daa06&&_0x1daa06['id']===_0x1adc43['id']?_0x1adc43['select']():_0x1adc43['deselect']();}['highlightRevisions'](_0x14bd08){for(const _0x11de00 of this['revisionViews'])_0x14bd08['some'](({id:_0x2077c2})=>_0x2077c2===_0x11de00['id'])?_0x11de00['highlight']():_0x11de00['unhighlight']();}['_addRevision'](_0x2bdd0a){const _0x4a78cf=mi(_0x2bdd0a['createdAt'],this['locale']['uiLanguage'])['startDate'];let _0x2c5209=this['timePeriodViews']['get'](0x0);_0x2c5209&&_0x2c5209['startDate']['getTime']()===_0x4a78cf['getTime']()||(_0x2c5209=new _i(this['locale'],_0x4a78cf,this['_revisionActions'],this['_requireRevisionName']),this['timePeriodViews']['add'](_0x2c5209)),_0x2c5209['addRevision'](_0x2bdd0a);}['_removeRevision'](_0x7cb352){const _0x1a2eb1=mi(_0x7cb352['createdAt'],this['locale']['uiLanguage'])['startDate'];this['_getTimePeriodViewByStartDate'](_0x1a2eb1)['removeRevision'](_0x7cb352);}['_getTimePeriodViewByStartDate'](_0x4551e5){return this['timePeriodViews']['find'](_0x11e8fe=>_0x11e8fe['startDate']['getTime']()===_0x4551e5['getTime']());}}class d extends _0x3ba875{['_revisionViewer'];['_revisionsRepository'];['_sidebarView'];static ['defaultRevisionActions']=/* #__PURE__ -- @preserve */
|
|
27
27
|
((()=>['compareAgainstSelected','restoreRevision','nameRevision'])());static ['availableRevisionActions']=/* #__PURE__ -- @preserve */
|
|
28
|
-
|
|
29
|
-
_0xc4c939(_0x394299){['_ui'];get['ui'](){return this['_ui'];}constructor(_0x35c30e,_0x27dea6){super(_0x27dea6),this['sourceElement']=_0x35c30e,this['model']['document']['createRoot']();const _0x297c45=new it(this['locale'],this['editing']['view'],{'shouldToolbarGroupWhenFull':!0x0});this['_ui']=new tt(this,_0x297c45);}['destroy'](){return this['updateSourceElement'](),this['ui']['destroy'](),super['destroy']();}static async['create'](_0x4be3e4,_0x255194){const _0x27e21b=new this(_0x4be3e4,_0x255194);return await _0x27e21b['initPlugins'](),await _0x27e21b['ui']['init'](_0x4be3e4),await _0x27e21b['data']['init'](_0x27e21b['config']['get']('initialData')||''),_0x27e21b['fire']('ready'),_0x27e21b;}}const p=['RevisionHistoryUI','RestrictedEditingMode'];class _t extends _0x47e767{['result'];static get['pluginName'](){return'RevisionViewerIntegration';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x82442c){function _0x3abf48(_0xd85dca){return _0xd85dca['map'](_0x40fd59=>String['fromCharCode'](_0x40fd59))['join']('');}super(_0x82442c),this['result']='end',_0x82442c[_0x3abf48([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x3abf48([0x76,0x69,0x65,0x77])][_0x3abf48([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x3abf48([0x61,0x75,0x74,0x6f]),_0x82442c[_0x3abf48([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x3abf48([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x3abf48([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x3abf48([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x3abf48([0x6f,0x6b])});}}class k extends _0x47e767{['_viewerEditor'];static get['pluginName'](){return'RevisionHistory';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[u,f];}constructor(_0x171786){if(super(_0x171786),!this['editor']['config']['get']('revisionHistory'))throw new _0x1dd723('revision-history-missing-configuration',this);this['_viewerEditor']=null,this['set']('isRevisionViewerOpen',!0x1),this['editor']['config']['define']('revisionHistory.showRevisionViewerCallback',_0x4c8dc6=>this['_showRevisionViewer']({..._0x4c8dc6,'translations':this['editor']['locale']['translations']})),this['editor']['config']['define']('revisionHistory.closeRevisionViewerCallback',_0x12c6da=>this['_closeRevisionViewer'](_0x12c6da)),this['editor']['config']['define']('revisionHistory.restoreRevisionCallback',_0x2ded39=>this['_restoreRevision'](_0x2ded39)),this['editor']['config']['define']('revisionHistory.requireRevisionName',!0x1),this['_enhanceShowRevisionViewerCallback'](),this['_enhanceCloseRevisionViewerCallback']();}set['adapter'](_0x4aa456){this['editor']['plugins']['get']('RevisionTracker')['adapter']=_0x4aa456;}get['adapter'](){return this['editor']['plugins']['get']('RevisionTracker')['adapter'];}['addRevisionData'](_0x599444){return this['editor']['plugins']['get']('RevisionTracker')['addRevisionData'](_0x599444);}['getRevision'](_0x24a44b){return this['editor']['plugins']['get']('RevisionsRepository')['getRevision'](_0x24a44b);}['getRevisions'](_0x59272a){return this['editor']['plugins']['get']('RevisionsRepository')['getRevisions'](_0x59272a||{'toJSON':!0x1});}['_getRevisionViewerEditorConfig'](){const _0x5a03b8=this['editor'],_0x399581=_0x516551(_0x5a03b8,p),_0x8a4783=_0x5a03b8['plugins']['get']('RevisionTracker'),_0x12d759=_0x5a03b8['plugins']['get']('Users')['users'];return _0x399581['toolbar']=['exitToEditing','restoreRevision','changesNavigation'],delete _0x399581['lazyRoots'],(_0x399581['plugins']['push'](_t,m,R,class extends _0x47e767{static get['requires'](){return[m,'Users'];}['init'](){const _0x320942=this['editor']['plugins']['get']('Users');for(const _0x5caa86 of _0x12d759)_0x5caa86['isAnonymous']||_0x320942['getUser'](_0x5caa86['id'])||_0x320942['addUser'](_0x5caa86);const _0x2a4409=_0x8a4783['repository']['getRevisions']();let _0x491d2a=null;const _0xc7cae9=this['editor']['plugins']['get']('RevisionViewer');_0xc7cae9['adapter']=_0x8a4783['adapter'],_0xc7cae9['bind']('isEnabled')['to'](_0x8a4783),this['editor']['commands']['get']('restoreRevision')['bind']('isEnabled')['to'](_0x5a03b8,'isReadOnly',_0x3dc5c0=>!_0x3dc5c0);for(const _0x1a1658 of _0x2a4409){const _0x442178=null===_0x1a1658['creator'];if(_0x442178&&_0x1a1658['toVersion']===_0x1a1658['fromVersion'])continue;const _0x136cf0=_0x1a1658['toJSON']();_0xc7cae9['addRevisionData'](_0x136cf0,(_0xa1b2c9,_0x587a94,_0x40032f)=>{if(_0x442178){if(_0x491d2a)_0x491d2a['_update'](_0xa1b2c9,_0x587a94);else{if(!_0x587a94){const _0x4c4399=_0x40032f['toJSON']();_0x4c4399['id']=_0x2b268f(),_0x8a4783['saveRevision'](_0x4c4399,_0x40032f['toVersion'])['then'](_0x1bc876=>{_0x491d2a=_0x1bc876;});}}}else _0x1a1658['_update'](_0xa1b2c9,_0x587a94);});}}},d),_0x399581);}['_enhanceShowRevisionViewerCallback'](){const _0x3940d2=this['editor']['config']['get']('revisionHistory')['showRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.showRevisionViewerCallback',async()=>{this['editor']['enableReadOnlyMode']('revision-history-viewer-opened');const _0x3e9ea3=this['editor']['plugins']['get']('RevisionTracker');if(this['editor']['plugins']['has']('Autosave')){const _0x105953=this['editor']['plugins']['get']('Autosave');await _0x105953['save']();}else await _0x3e9ea3['update']();if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('Dialog')){const _0x48e885=this['editor']['plugins']['get']('Dialog');_0x48e885['isOpen']&&_0x48e885['hide']();}const _0x1a7a1f=this['_getRevisionViewerEditorConfig']();return _0x3940d2(_0x1a7a1f)['then'](_0x19b4b5=>{return(this['_viewerEditor']=_0x19b4b5,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'),_0x19b4b5);})['catch'](_0x2c41e7=>(console['error'](_0x2c41e7),this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),null));});}['_enhanceCloseRevisionViewerCallback'](){const _0x9930f1=this['editor']['config']['get']('revisionHistory')['closeRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.closeRevisionViewerCallback',()=>(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('DocumentOutline')&&(this['editor']['plugins']['get']('DocumentOutlineUI')['view']['element']['style']['display']=''),this['_viewerEditor']['plugins']['get']('RevisionViewer')['_cleanUp'](),_0x9930f1(this['_viewerEditor'])['then'](()=>{if(this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),this['_viewerEditor']=null,this['editor']['plugins']['has']('Annotations')){const _0xca5eee=this['editor']['plugins']['get']('Annotations');_0xca5eee['refreshVisibility'](),_0xca5eee['refreshPositioning']();}})));}['_showRevisionViewer'](_0x3a314b){const _0x59ae31=this['editor']['config']['get']('revisionHistory.editorContainer'),_0x584f31=this['editor']['config']['get']('revisionHistory.viewerContainer'),_0x443f02=this['editor']['config']['get']('revisionHistory.viewerEditorElement');return w['create'](_0x443f02,_0x3a314b)['then'](_0x59f609=>(_0x584f31['style']['display']='block',_0x59ae31['style']['display']='none',this['isRevisionViewerOpen']=!0x0,_0x59f609));}['_closeRevisionViewer'](_0x45b591){const _0x2fe144=this['editor']['config']['get']('revisionHistory.editorContainer');return this['editor']['config']['get']('revisionHistory.viewerContainer')['style']['display']='none',_0x2fe144['style']['display']='',this['isRevisionViewerOpen']=!0x1,_0x45b591['destroy']();}async['_restoreRevision'](_0x2ef975){const _0x42b994=this['editor'],_0x930980=this['_viewerEditor']['plugins']['get']('RevisionViewer'),_0x5bf789=_0x42b994['plugins']['get']('RevisionTracker'),_0x190732=_0x42b994['plugins']['get']('RevisionHistoryUtils'),_0x5dcb8a=_0x930980['repository']['getRevision'](_0x2ef975);let _0xf3a5ca,_0x3169d5,_0x3b9f94;try{await _0x190732['loadRevisionData'](_0x5dcb8a,this['adapter']),_0xf3a5ca=_0x190732['getRevisionDocumentData'](_0x5dcb8a),_0x3169d5=_0x190732['getRevisionRootsAttributes'](_0x5dcb8a);}catch(_0x5eab69){return void console['error'](_0x5eab69);}_0x42b994['model']['change'](_0x4847a9=>{for(const _0x5f32f9 of Array['from'](_0x42b994['model']['markers']['getMarkersGroup']('restrictedEditingException')))_0x4847a9['removeMarker'](_0x5f32f9);}),_0x930980['isReady']=!0x1,_0x42b994['model']['enqueueChange'](_0x51397d=>{_0x51397d['setSelection'](null),_0x51397d['removeSelectionAttribute'](_0x42b994['model']['document']['selection']['getAttributeKeys']());const _0x4564b8=Object['keys'](_0xf3a5ca);for(const _0x13c50d of _0x42b994['model']['document']['roots'])'$graveyard'!=_0x13c50d['rootName']&&_0x13c50d['isAttached']()&&!_0x4564b8['includes'](_0x13c50d['rootName'])&&_0x51397d['detachRoot'](_0x13c50d);for(const _0x5cf706 of _0x4564b8){let _0x575d89=_0x42b994['model']['document']['getRoot'](_0x5cf706);_0x575d89&&_0x575d89['isAttached']()||(_0x575d89=_0x51397d['addRoot'](_0x5cf706));const _0x1b4cb5=_0x3169d5[_0x5cf706],_0x813a74=Object['keys'](_0x1b4cb5),_0x2894ec=_0xf3a5ca[_0x5cf706];for(const _0x65ce19 of _0x575d89['getAttributeKeys']())_0x813a74['includes'](_0x65ce19)||_0x51397d['removeAttribute'](_0x65ce19,_0x575d89);for(const _0x361727 of _0x813a74)_0x51397d['setAttribute'](_0x361727,_0x3169d5[_0x5cf706][_0x361727],_0x575d89);_0x51397d['remove'](_0x51397d['createRangeIn'](_0x575d89)),_0x51397d['insert'](_0x42b994['data']['parse'](_0x2894ec,_0x575d89),_0x575d89,0x0);}});const _0x2b4c49=g(_0x42b994['locale'],'Restored');if(_0x5dcb8a['name'])_0x3b9f94=-0x1==_0x5dcb8a['name']['indexOf'](_0x2b4c49)?_0x2b4c49+':\x20'+_0x5dcb8a['name']:_0x5dcb8a['name'];else _0x3b9f94=_0x2b4c49+':\x20'+(_0x5dcb8a['createdAt']['toLocaleDateString'](_0x42b994['locale']['uiLanguage'],{'month':'long','day':'numeric'})+',\x20'+_0x5dcb8a['createdAt']['toLocaleTimeString'](_0x42b994['locale']['uiLanguage'],{'hour':'numeric','minute':'numeric'}));return await _0x5bf789['saveRevision']({'name':_0x3b9f94}),_0x930980['isReady']=!0x0,_0x42b994['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}}export{h as Revision,k as RevisionHistory,f as RevisionHistoryUI,V as RevisionHistoryUtils,u as RevisionTracker,m as RevisionViewer,w as RevisionViewerEditor,de as RevisionViewerLoadingOverlay,R as RevisionViewerUI,I as RevisionsRepository,d as RevisionsSidebar};
|
|
28
|
+
_t();static get['pluginName'](){return'RevisionsSidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[m];}constructor(_0x38f044){super(_0x38f044),this['_revisionViewer']=_0x38f044['plugins']['get'](m),this['_revisionsRepository']=this['_revisionViewer']['repository'],this['_sidebarView']=null;}['init'](){const _0x125ba1=this['_revisionsRepository']['_revisions'],_0x3df4ad=this['_createRevisionActions'](),_0x3cd3f7=this['editor']['config']['get']('revisionHistory.viewerSidebarContainer');this['_sidebarView']=new vi(this['editor']['locale'],_0x125ba1,_0x3df4ad,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',(_0x452ce1,_0x59cc61)=>{_0x59cc61['revisionViews']['on']('add',(_0x4a65ba,_0xf400d5)=>{_0xf400d5['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)),_0x3cd3f7['appendChild'](this['_sidebarView']['element']);}['destroy'](){this['_sidebarView']['element']['remove'](),this['_sidebarView']['destroy']();}['_handleEditorDataReady'](){const _0x1a2b81=this['_revisionsRepository']['getRevision'](0x0);if(_0x1a2b81){const _0xdf10a8=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x1a2b81['id']);this['_revisionViewer']['compare'](_0x1a2b81,_0xdf10a8);}}['_handleRevisionSelected'](_0x15c09f,_0x13b136){const _0x60dda8=this['_revisionsRepository']['getRevision'](_0x13b136['id']),_0x2aa374=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x60dda8['id']);this['_revisionViewer']['compare'](_0x60dda8,_0x2aa374);}['_handleRevisionSetName'](_0x2e0532,_0x2ce658){this['_revisionsRepository']['getRevision'](_0x2ce658['id'])['setName'](_0x2ce658['name']);}['_handleDiffChange'](_0x58d6a6,_0x346318,_0x39c737){const _0x128720=this['_revisionsRepository']['getRevisionsInDiff'](_0x39c737);_0x128720['length']>0x2?(this['_sidebarView']['highlightRevisions'](_0x128720),this['_sidebarView']['selectRevision'](null)):(this['_sidebarView']['highlightRevisions']([]),this['_sidebarView']['selectRevision'](_0x128720[0x0]));}['_createRevisionActions'](){const _0x2edd7d=this['editor'],_0x42bfa9=d['availableRevisionActions'],_0x55a577=_0x2edd7d['config']['get']('revisionHistory.revisionActions')||d['defaultRevisionActions'];if(_0x55a577['length'])return _0x55a577['map'](_0x3d3f09=>{const _0x57df4c='string'==typeof _0x3d3f09?Object['assign']({},_0x42bfa9[_0x3d3f09]):_0x3d3f09;return _0x57df4c['action']=_0x57df4c['action']['bind'](this,_0x2edd7d),_0x57df4c['isVisible']&&(_0x57df4c['isVisible']=_0x57df4c['isVisible']['bind'](this,_0x2edd7d)),_0x57df4c;});}}function _t(){return{'compareAgainstSelected':{'name':'Compare\x20against\x20selected','action':({plugins:_0x5ea6ce},_0x221a8b)=>{const _0x5904f5=_0x5ea6ce['get'](m),_0x1d8664=_0x5904f5['repository'];let _0x586f8d=_0x5904f5['diff']['newRevisionId'],_0x3e3cfb=_0x221a8b['id'];_0x1d8664['getIndex'](_0x586f8d)>_0x1d8664['getIndex'](_0x3e3cfb)&&([_0x586f8d,_0x3e3cfb]=[_0x3e3cfb,_0x586f8d]),_0x5904f5['compare'](_0x586f8d,_0x3e3cfb);},'isVisible':({plugins:_0x42d988},_0x3d5069)=>{const _0xbfb2d5=_0x42d988['get'](m);return!(_0xbfb2d5['repository']['getRevisionsInDiff'](_0xbfb2d5['diff'])['length']>0x2)&&!_0x3d5069['isSelected'];}},'restoreRevision':{'name':'Restore\x20this\x20revision','action':(_0x190138,{id:_0x24dbfa})=>{_0x190138['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x24dbfa);},'isVisible':({plugins:_0x32bf52},_0x1ce2d0)=>!!_0x32bf52['get'](m)['repository']['getLaterVisibleRevision'](_0x1ce2d0['id'])},'nameRevision':{'name':'Name\x20this\x20revision','action':({plugins:_0x39a588},{id:_0x22d3a6,revisionNameView:_0x2a4fc6})=>{const _0x247afb=_0x39a588['get'](m),_0x25692d=_0x247afb['repository']['getEarlierVisibleRevision'](_0x22d3a6);_0x247afb['compare'](_0x22d3a6,_0x25692d),_0x2a4fc6['focus'](),_0x2a4fc6['fieldView']['select']();}}};}class tt extends st{['_view'];['_toolbarConfig'];['_elementReplacer'];get['view'](){return this['_view'];}constructor(_0x5fe99a,_0x393d92){super(_0x5fe99a),this['_view']=_0x393d92,this['_toolbarConfig']=et(_0x5fe99a['config']['get']('toolbar')),this['_elementReplacer']=new ot();}get['element'](){return this['view']['element'];}['init'](_0x4224f3){const _0xa585f0=this['editor'],_0x5a3b84=this['view'],_0x5d51c1=_0xa585f0['editing']['view'],_0x5f0138=_0x5a3b84['editable'],_0x36ecfe=_0x5d51c1['document']['getRoot']();_0x5f0138['name']=_0x36ecfe['rootName'],_0x5a3b84['render']();const _0x5e6778=_0x5f0138['element'];this['setEditableElement'](_0x5f0138['name'],_0x5e6778),_0x5a3b84['editable']['bind']('isFocused')['to'](this['focusTracker']),_0x5d51c1['attachDomRoot'](_0x5e6778),this['_elementReplacer']['replace'](_0x4224f3,this['element']),this['_initToolbar'](),this['fire']('ready');}['destroy'](){super['destroy']();const _0x358c59=this['view'],_0x28c36f=this['editor']['editing']['view'];this['_elementReplacer']['restore'](),_0x28c36f['detachDomRoot'](_0x358c59['editable']['name']),_0x358c59['destroy']();}['_initToolbar'](){const _0x47f439=this['view'];_0x47f439['stickyPanel']['bind']('isActive')['to'](this['focusTracker'],'isFocused'),_0x47f439['stickyPanel']['limiterElement']=_0x47f439['element'],_0x47f439['stickyPanel']['bind']('viewportTopOffset')['to'](this,'viewportOffset',({top:_0x37bfb2})=>_0x37bfb2),_0x47f439['toolbar']['fillFromConfig'](this['_toolbarConfig'],this['componentFactory']),this['addToolbar'](_0x47f439['toolbar']);}}class it extends rt{['_editable'];['stickyPanel'];['toolbar'];get['editable'](){return this['_editable'];}constructor(_0x1ebbff,_0x516912,_0x5cf9bf={}){super(_0x1ebbff),this['stickyPanel']=new ht(_0x1ebbff),this['toolbar']=new dt(_0x1ebbff,{'shouldGroupWhenFull':_0x5cf9bf['shouldToolbarGroupWhenFull']}),this['_editable']=new ct(_0x1ebbff,_0x516912);}['render'](){super['render'](),this['stickyPanel']['content']['add'](this['toolbar']),this['top']['add'](this['stickyPanel']),this['main']['add'](this['editable']);}}class w extends/* #__PURE__ -- @preserve */
|
|
29
|
+
_0x40797a(_0x3664be){['_ui'];get['ui'](){return this['_ui'];}constructor(_0x19f4a4,_0x1da438){super(_0x1da438),this['sourceElement']=_0x19f4a4,this['model']['document']['createRoot']();const _0x16c337=new it(this['locale'],this['editing']['view'],{'shouldToolbarGroupWhenFull':!0x0});this['_ui']=new tt(this,_0x16c337);}['destroy'](){return this['updateSourceElement'](),this['ui']['destroy'](),super['destroy']();}static async['create'](_0x57f482,_0x3cd7e3){const _0x496d55=new this(_0x57f482,_0x3cd7e3);return await _0x496d55['initPlugins'](),await _0x496d55['ui']['init'](_0x57f482),await _0x496d55['data']['init'](_0x496d55['config']['get']('initialData')||''),_0x496d55['fire']('ready'),_0x496d55;}}const p=['RevisionHistoryUI','RestrictedEditingMode'];class yt extends _0x3ba875{['result'];static get['pluginName'](){return'RevisionViewerIntegration';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x5b0cab){function _0x218d8c(_0x2b700f){return _0x2b700f['map'](_0x4d99c2=>String['fromCharCode'](_0x4d99c2))['join']('');}super(_0x5b0cab),this['result']='end',_0x5b0cab[_0x218d8c([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x218d8c([0x76,0x69,0x65,0x77])][_0x218d8c([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x218d8c([0x61,0x75,0x74,0x6f]),_0x5b0cab[_0x218d8c([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x218d8c([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x218d8c([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x218d8c([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x218d8c([0x6f,0x6b])});}}class k extends _0x3ba875{['_viewerEditor'];static get['pluginName'](){return'RevisionHistory';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[u,f];}constructor(_0x5c3827){if(super(_0x5c3827),!this['editor']['config']['get']('revisionHistory'))throw new _0xdb6012('revision-history-missing-configuration',this);this['_viewerEditor']=null,this['set']('isRevisionViewerOpen',!0x1),this['editor']['config']['define']('revisionHistory.showRevisionViewerCallback',_0x5335d5=>this['_showRevisionViewer']({..._0x5335d5,'translations':this['editor']['locale']['translations']})),this['editor']['config']['define']('revisionHistory.closeRevisionViewerCallback',_0x2eb10e=>this['_closeRevisionViewer'](_0x2eb10e)),this['editor']['config']['define']('revisionHistory.restoreRevisionCallback',_0x509e1f=>this['_restoreRevision'](_0x509e1f)),this['editor']['config']['define']('revisionHistory.requireRevisionName',!0x1),this['_enhanceShowRevisionViewerCallback'](),this['_enhanceCloseRevisionViewerCallback']();}set['adapter'](_0x22ad10){this['editor']['plugins']['get']('RevisionTracker')['adapter']=_0x22ad10;}get['adapter'](){return this['editor']['plugins']['get']('RevisionTracker')['adapter'];}['addRevisionData'](_0x2f1d24){return this['editor']['plugins']['get']('RevisionTracker')['addRevisionData'](_0x2f1d24);}['getRevision'](_0x66a1af){return this['editor']['plugins']['get']('RevisionsRepository')['getRevision'](_0x66a1af);}['getRevisions'](_0x53e0fb){return this['editor']['plugins']['get']('RevisionsRepository')['getRevisions'](_0x53e0fb||{'toJSON':!0x1});}['_getRevisionViewerEditorConfig'](){const _0x350870=this['editor'],_0x460c04=_0x22bf10(_0x350870,p),_0x94bd7b=_0x350870['plugins']['get']('RevisionTracker'),_0xa2fe98=_0x350870['plugins']['get']('Users')['users'];return _0x460c04['toolbar']=['exitToEditing','restoreRevision','changesNavigation'],delete _0x460c04['lazyRoots'],(_0x460c04['plugins']['push'](yt,m,R,class extends _0x3ba875{static get['requires'](){return[m,'Users'];}['init'](){const _0x252484=this['editor']['plugins']['get']('Users');for(const _0xb752e3 of _0xa2fe98)_0xb752e3['isAnonymous']||_0x252484['getUser'](_0xb752e3['id'])||_0x252484['addUser'](_0xb752e3);const _0x28bd8e=_0x94bd7b['repository']['getRevisions']();let _0x4c2298=null;const _0x26cc66=this['editor']['plugins']['get']('RevisionViewer');_0x26cc66['adapter']=_0x94bd7b['adapter'],_0x26cc66['bind']('isEnabled')['to'](_0x94bd7b),this['editor']['commands']['get']('restoreRevision')['bind']('isEnabled')['to'](_0x350870,'isReadOnly',_0x36a4ad=>!_0x36a4ad);for(const _0x2a1214 of _0x28bd8e){const _0x138b99=null===_0x2a1214['creator'];if(_0x138b99&&_0x2a1214['toVersion']===_0x2a1214['fromVersion'])continue;const _0x1274ca=_0x2a1214['toJSON']();_0x26cc66['addRevisionData'](_0x1274ca,(_0x14e11f,_0x35169e,_0x2a2fc0)=>{if(_0x138b99){if(_0x4c2298)_0x4c2298['_update'](_0x14e11f,_0x35169e);else{if(!_0x35169e){const _0x38596f=_0x2a2fc0['toJSON']();_0x38596f['id']=_0x58b8ff(),_0x94bd7b['saveRevision'](_0x38596f,_0x2a2fc0['toVersion'])['then'](_0x1fd5be=>{_0x4c2298=_0x1fd5be;});}}}else _0x2a1214['_update'](_0x14e11f,_0x35169e);});}}},d),_0x460c04);}['_enhanceShowRevisionViewerCallback'](){const _0x26df62=this['editor']['config']['get']('revisionHistory')['showRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.showRevisionViewerCallback',async()=>{this['editor']['enableReadOnlyMode']('revision-history-viewer-opened');const _0x1421ab=this['editor']['plugins']['get']('RevisionTracker');if(this['editor']['plugins']['has']('Autosave')){const _0x30876b=this['editor']['plugins']['get']('Autosave');await _0x30876b['save']();}else await _0x1421ab['update']();if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('Dialog')){const _0x20aacc=this['editor']['plugins']['get']('Dialog');_0x20aacc['isOpen']&&_0x20aacc['hide']();}const _0x107280=this['_getRevisionViewerEditorConfig']();return _0x26df62(_0x107280)['then'](_0x5c1341=>{return(this['_viewerEditor']=_0x5c1341,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'),_0x5c1341);})['catch'](_0x5e5662=>(console['error'](_0x5e5662),this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),null));});}['_enhanceCloseRevisionViewerCallback'](){const _0x4ca37c=this['editor']['config']['get']('revisionHistory')['closeRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.closeRevisionViewerCallback',()=>(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('DocumentOutline')&&(this['editor']['plugins']['get']('DocumentOutlineUI')['view']['element']['style']['display']=''),this['_viewerEditor']['plugins']['get']('RevisionViewer')['_cleanUp'](),_0x4ca37c(this['_viewerEditor'])['then'](()=>{if(this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),this['_viewerEditor']=null,this['editor']['plugins']['has']('Annotations')){const _0x53e591=this['editor']['plugins']['get']('Annotations');_0x53e591['refreshVisibility'](),_0x53e591['refreshPositioning']();}})));}['_showRevisionViewer'](_0x3afc44){const _0x4774bb=this['editor']['config']['get']('revisionHistory.editorContainer'),_0x3d6903=this['editor']['config']['get']('revisionHistory.viewerContainer'),_0xe346ee=this['editor']['config']['get']('revisionHistory.viewerEditorElement');return w['create'](_0xe346ee,_0x3afc44)['then'](_0x1f32c6=>(_0x3d6903['style']['display']='block',_0x4774bb['style']['display']='none',this['isRevisionViewerOpen']=!0x0,_0x1f32c6));}['_closeRevisionViewer'](_0x4fd397){const _0x5386c0=this['editor']['config']['get']('revisionHistory.editorContainer');return this['editor']['config']['get']('revisionHistory.viewerContainer')['style']['display']='none',_0x5386c0['style']['display']='',this['isRevisionViewerOpen']=!0x1,_0x4fd397['destroy']();}async['_restoreRevision'](_0x3fcc9d){const _0x4dd00d=this['editor'],_0x5b82e0=this['_viewerEditor']['plugins']['get']('RevisionViewer'),_0x6c1573=_0x4dd00d['plugins']['get']('RevisionTracker'),_0x15091a=_0x4dd00d['plugins']['get']('RevisionHistoryUtils'),_0x1d99bd=_0x5b82e0['repository']['getRevision'](_0x3fcc9d);let _0x3b0ca8,_0x435a4d,_0x1dbf76;try{await _0x15091a['loadRevisionData'](_0x1d99bd,this['adapter']),_0x3b0ca8=_0x15091a['getRevisionDocumentData'](_0x1d99bd),_0x435a4d=_0x15091a['getRevisionRootsAttributes'](_0x1d99bd);}catch(_0x464afd){return void console['error'](_0x464afd);}_0x4dd00d['model']['change'](_0x457c12=>{for(const _0x101c02 of Array['from'](_0x4dd00d['model']['markers']['getMarkersGroup']('restrictedEditingException')))_0x457c12['removeMarker'](_0x101c02);}),_0x5b82e0['isReady']=!0x1,_0x4dd00d['model']['enqueueChange'](_0x2ab8c1=>{_0x2ab8c1['setSelection'](null),_0x2ab8c1['removeSelectionAttribute'](_0x4dd00d['model']['document']['selection']['getAttributeKeys']());const _0x2594b0=Object['keys'](_0x3b0ca8);for(const _0x1f455b of _0x4dd00d['model']['document']['roots'])'$graveyard'!=_0x1f455b['rootName']&&_0x1f455b['isAttached']()&&!_0x2594b0['includes'](_0x1f455b['rootName'])&&_0x2ab8c1['detachRoot'](_0x1f455b);for(const _0x395cd3 of _0x2594b0){let _0x4acc21=_0x4dd00d['model']['document']['getRoot'](_0x395cd3);_0x4acc21&&_0x4acc21['isAttached']()||(_0x4acc21=_0x2ab8c1['addRoot'](_0x395cd3));const _0x3c6e75=_0x435a4d[_0x395cd3],_0x84fe9b=Object['keys'](_0x3c6e75),_0x24bf1f=_0x3b0ca8[_0x395cd3];for(const _0x21aca2 of _0x4acc21['getAttributeKeys']())_0x84fe9b['includes'](_0x21aca2)||_0x2ab8c1['removeAttribute'](_0x21aca2,_0x4acc21);for(const _0x122080 of _0x84fe9b)_0x2ab8c1['setAttribute'](_0x122080,_0x435a4d[_0x395cd3][_0x122080],_0x4acc21);_0x2ab8c1['remove'](_0x2ab8c1['createRangeIn'](_0x4acc21)),_0x2ab8c1['insert'](_0x4dd00d['data']['parse'](_0x24bf1f,_0x4acc21),_0x4acc21,0x0);}});const _0x4aab98=g(_0x4dd00d['locale'],'Restored');if(_0x1d99bd['name'])_0x1dbf76=-0x1==_0x1d99bd['name']['indexOf'](_0x4aab98)?_0x4aab98+':\x20'+_0x1d99bd['name']:_0x1d99bd['name'];else _0x1dbf76=_0x4aab98+':\x20'+(_0x1d99bd['createdAt']['toLocaleDateString'](_0x4dd00d['locale']['uiLanguage'],{'month':'long','day':'numeric'})+',\x20'+_0x1d99bd['createdAt']['toLocaleTimeString'](_0x4dd00d['locale']['uiLanguage'],{'hour':'numeric','minute':'numeric'}));return await _0x6c1573['saveRevision']({'name':_0x1dbf76}),_0x5b82e0['isReady']=!0x0,_0x4dd00d['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}}export{h as Revision,k as RevisionHistory,f as RevisionHistoryUI,V as RevisionHistoryUtils,u as RevisionTracker,m as RevisionViewer,w as RevisionViewerEditor,le as RevisionViewerLoadingOverlay,R as RevisionViewerUI,I as RevisionsRepository,d as RevisionsSidebar};
|