@ckeditor/ckeditor5-revision-history 45.1.0 → 45.2.0-alpha.1
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/dist/translations/af.js +1 -1
- package/dist/translations/af.umd.js +1 -1
- package/dist/translations/ar.js +1 -1
- package/dist/translations/ar.umd.js +1 -1
- package/dist/translations/ast.js +1 -1
- package/dist/translations/ast.umd.js +1 -1
- package/dist/translations/az.js +1 -1
- package/dist/translations/az.umd.js +1 -1
- package/dist/translations/be.js +1 -1
- package/dist/translations/be.umd.js +1 -1
- package/dist/translations/bg.js +1 -1
- package/dist/translations/bg.umd.js +1 -1
- package/dist/translations/bn.js +1 -1
- package/dist/translations/bn.umd.js +1 -1
- package/dist/translations/bs.js +1 -1
- package/dist/translations/bs.umd.js +1 -1
- package/dist/translations/ca.js +1 -1
- package/dist/translations/ca.umd.js +1 -1
- package/dist/translations/cs.js +1 -1
- package/dist/translations/cs.umd.js +1 -1
- package/dist/translations/da.js +1 -1
- package/dist/translations/da.umd.js +1 -1
- package/dist/translations/de-ch.js +1 -1
- package/dist/translations/de-ch.umd.js +1 -1
- package/dist/translations/de.js +1 -1
- package/dist/translations/de.umd.js +1 -1
- package/dist/translations/el.js +1 -1
- package/dist/translations/el.umd.js +1 -1
- package/dist/translations/en-au.js +1 -1
- package/dist/translations/en-au.umd.js +1 -1
- package/dist/translations/en-gb.js +1 -1
- package/dist/translations/en-gb.umd.js +1 -1
- package/dist/translations/en.js +1 -1
- package/dist/translations/en.umd.js +1 -1
- package/dist/translations/eo.js +1 -1
- package/dist/translations/eo.umd.js +1 -1
- package/dist/translations/es-co.js +1 -1
- package/dist/translations/es-co.umd.js +1 -1
- package/dist/translations/es.js +1 -1
- package/dist/translations/es.umd.js +1 -1
- package/dist/translations/et.js +1 -1
- package/dist/translations/et.umd.js +1 -1
- package/dist/translations/eu.js +1 -1
- package/dist/translations/eu.umd.js +1 -1
- package/dist/translations/fa.js +1 -1
- package/dist/translations/fa.umd.js +1 -1
- package/dist/translations/fi.js +1 -1
- package/dist/translations/fi.umd.js +1 -1
- package/dist/translations/fr.js +1 -1
- package/dist/translations/fr.umd.js +1 -1
- package/dist/translations/gl.js +1 -1
- package/dist/translations/gl.umd.js +1 -1
- package/dist/translations/gu.js +1 -1
- package/dist/translations/gu.umd.js +1 -1
- package/dist/translations/he.js +1 -1
- package/dist/translations/he.umd.js +1 -1
- package/dist/translations/hi.js +1 -1
- package/dist/translations/hi.umd.js +1 -1
- package/dist/translations/hr.js +1 -1
- package/dist/translations/hr.umd.js +1 -1
- package/dist/translations/hu.js +1 -1
- package/dist/translations/hu.umd.js +1 -1
- package/dist/translations/hy.js +1 -1
- package/dist/translations/hy.umd.js +1 -1
- package/dist/translations/id.js +1 -1
- package/dist/translations/id.umd.js +1 -1
- package/dist/translations/it.js +1 -1
- package/dist/translations/it.umd.js +1 -1
- package/dist/translations/ja.js +1 -1
- package/dist/translations/ja.umd.js +1 -1
- package/dist/translations/jv.js +1 -1
- package/dist/translations/jv.umd.js +1 -1
- package/dist/translations/kk.js +1 -1
- package/dist/translations/kk.umd.js +1 -1
- package/dist/translations/km.js +1 -1
- package/dist/translations/km.umd.js +1 -1
- package/dist/translations/kn.js +1 -1
- package/dist/translations/kn.umd.js +1 -1
- package/dist/translations/ko.js +1 -1
- package/dist/translations/ko.umd.js +1 -1
- package/dist/translations/ku.js +1 -1
- package/dist/translations/ku.umd.js +1 -1
- package/dist/translations/lt.js +1 -1
- package/dist/translations/lt.umd.js +1 -1
- package/dist/translations/lv.js +1 -1
- package/dist/translations/lv.umd.js +1 -1
- package/dist/translations/ms.js +1 -1
- package/dist/translations/ms.umd.js +1 -1
- package/dist/translations/nb.js +1 -1
- package/dist/translations/nb.umd.js +1 -1
- package/dist/translations/ne.js +1 -1
- package/dist/translations/ne.umd.js +1 -1
- package/dist/translations/nl.js +1 -1
- package/dist/translations/nl.umd.js +1 -1
- package/dist/translations/no.js +1 -1
- package/dist/translations/no.umd.js +1 -1
- package/dist/translations/oc.js +1 -1
- package/dist/translations/oc.umd.js +1 -1
- package/dist/translations/pl.js +1 -1
- package/dist/translations/pl.umd.js +1 -1
- package/dist/translations/pt-br.js +1 -1
- package/dist/translations/pt-br.umd.js +1 -1
- package/dist/translations/pt.js +1 -1
- package/dist/translations/pt.umd.js +1 -1
- package/dist/translations/ro.js +1 -1
- package/dist/translations/ro.umd.js +1 -1
- package/dist/translations/ru.js +1 -1
- package/dist/translations/ru.umd.js +1 -1
- package/dist/translations/si.js +1 -1
- package/dist/translations/si.umd.js +1 -1
- package/dist/translations/sk.js +1 -1
- package/dist/translations/sk.umd.js +1 -1
- package/dist/translations/sl.js +1 -1
- package/dist/translations/sl.umd.js +1 -1
- package/dist/translations/sq.js +1 -1
- package/dist/translations/sq.umd.js +1 -1
- package/dist/translations/sr-latn.js +1 -1
- package/dist/translations/sr-latn.umd.js +1 -1
- package/dist/translations/sr.js +1 -1
- package/dist/translations/sr.umd.js +1 -1
- package/dist/translations/sv.js +1 -1
- package/dist/translations/sv.umd.js +1 -1
- package/dist/translations/th.js +1 -1
- package/dist/translations/th.umd.js +1 -1
- package/dist/translations/ti.js +1 -1
- package/dist/translations/ti.umd.js +1 -1
- package/dist/translations/tk.js +1 -1
- package/dist/translations/tk.umd.js +1 -1
- package/dist/translations/tr.js +1 -1
- package/dist/translations/tr.umd.js +1 -1
- package/dist/translations/tt.js +1 -1
- package/dist/translations/tt.umd.js +1 -1
- package/dist/translations/ug.js +1 -1
- package/dist/translations/ug.umd.js +1 -1
- package/dist/translations/uk.js +1 -1
- package/dist/translations/uk.umd.js +1 -1
- package/dist/translations/ur.js +1 -1
- package/dist/translations/ur.umd.js +1 -1
- package/dist/translations/uz.js +1 -1
- package/dist/translations/uz.umd.js +1 -1
- package/dist/translations/vi.js +1 -1
- package/dist/translations/vi.umd.js +1 -1
- package/dist/translations/zh-cn.js +1 -1
- package/dist/translations/zh-cn.umd.js +1 -1
- package/dist/translations/zh.js +1 -1
- package/dist/translations/zh.umd.js +1 -1
- package/package.json +11 -11
- package/src/changeitem.js +2 -2
- package/src/editor/revisionviewereditor.js +2 -2
- package/src/editor/revisionviewereditorui.js +1 -1
- package/src/editor/revisionviewereditoruiview.js +1 -1
- package/src/index.js +1 -1
- package/src/revision.js +2 -2
- package/src/revisiondiff.js +1 -1
- package/src/revisionhistory.d.ts +1 -1
- package/src/revisionhistory.js +1 -1
- package/src/revisionhistoryutils.js +1 -1
- package/src/revisionsrepository.js +1 -1
- package/src/revisiontracker.js +1 -1
- package/src/revisionviewer.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/revision/utils.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/src/utils/common-translations.js +1 -1
package/dist/index.js
CHANGED
|
@@ -20,10 +20,10 @@
|
|
|
20
20
|
*
|
|
21
21
|
*
|
|
22
22
|
*/
|
|
23
|
-
import{ObservableMixin as
|
|
24
|
-
_0x5e88da(){['id'];['creator'];['authors'];['diffData'];['toVersion'];['fromVersion'];['model'];constructor(_0x194823){super(),this['id']=_0x194823['id']||_0x2bf2c8(),this['creator']=_0x194823['creator']||null,this['authors']=_0x194823['authors']||[],this['diffData']=_0x194823['diffData']||null,this['toVersion']=_0x194823['toVersion']||0x0,this['fromVersion']=_0x194823['fromVersion']||0x0,this['set']('name',_0x194823['name']||''),this['set']('createdAt',_0x194823['createdAt']||new Date()),this['set']('attributes',_0x194823['attributes']||{});}['setName'](_0x3b9512){this['_update']({'name':_0x3b9512});}['setAttribute'](_0x3a8f73,_0x485666){const _0x346449=_0xef8248(this['attributes']);_0x3afb79(_0x346449,_0x3a8f73,_0x485666),this['_update']({'attributes':_0x346449});}['removeAttribute'](_0x527e61){const _0x31c4b3=_0xef8248(this['attributes']);_0x5f314d(_0x31c4b3,_0x527e61),this['_update']({'attributes':_0x31c4b3});}['_update'](_0x2d87f2,_0x22d0d9=!0x1){let _0x1ac01f=!0x1;const _0x3c837d={'id':this['id']},_0x13dbe8=['name','createdAt','diffData','authors','attributes','toVersion','fromVersion','creatorId'];for(const _0x11e550 of _0x13dbe8){const _0x5eb899=_0x2d87f2[_0x11e550];void 0x0!==_0x5eb899&&_0x5eb899!==this[_0x11e550]&&(this[_0x11e550]=_0x5eb899,_0x3c837d[_0x11e550]=_0x5eb899,_0x1ac01f=!0x0);}_0x1ac01f&&(_0x3c837d['authors']&&(_0x3c837d['authorsIds']=_0x3c837d['authors']['map'](_0x17dbf1=>_0x17dbf1['id']),delete _0x3c837d['authors']),this['fire']('_update',_0x3c837d,_0x22d0d9));}['toJSON'](){return{'id':this['id'],'name':this['name'],'creatorId':this['creator']?this['creator']['id']:null,'authorsIds':this['authors']['map'](_0x28f0de=>_0x28f0de['id']),'diffData':this['diffData'],'createdAt':this['createdAt'],'attributes':this['attributes'],'fromVersion':this['fromVersion'],'toVersion':this['toVersion']};}}class I extends _0x45698e{['_revisions'];static get['requires'](){return[_0x30649f];}static get['pluginName'](){return'RevisionsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['length'](){return this['_revisions']['length'];}constructor(_0x2460c9){super(_0x2460c9),this['_revisions']=new _0x25586d();}['afterInit'](){!async function(_0x1eeef2){const _0x23913f=_0x2cc291([0x39,0x32,0x34,0x52,0x77,0x67,0x6c,0x62,0x4c,0x49,0x69,0x65,0x30,0x51,0x71,0x75,0x33,0x72,0x55,0x7a,0x36,0x6a,0x4a,0x50,0x46,0x6e,0x78,0x58,0x6d,0x59,0x68,0x54,0x56,0x4b,0x44,0x6f,0x74,0x47,0x31,0x61,0x63,0x6b,0x57,0x66,0x4e,0x73,0x5a,0x4f,0x70,0x64,0x43,0x42,0x4d,0x48,0x45,0x79,0x38,0x35,0x76,0x53,0x37,0x41]),_0x1e670a=0xeb829,_0x5efe89=0x4531eab0,_0x43b3db=0x45368d60^_0x5efe89,_0x14cc5f=window[_0x2cc291([0x44,0x61,0x74,0x65])][_0x2cc291([0x6e,0x6f,0x77])](),_0x32642b=_0x1eeef2[_0x2cc291([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x21ed4e=new window[(_0x2cc291([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x924988=>{_0x32642b[_0x2cc291([0x6f,0x6e,0x63,0x65])](_0x2cc291([0x72,0x65,0x61,0x64,0x79]),_0x924988);}),_0x3125f8={[_0x2cc291([0x6b,0x74,0x79])]:_0x2cc291([0x45,0x43]),[_0x2cc291([0x75,0x73,0x65])]:_0x2cc291([0x73,0x69,0x67]),[_0x2cc291([0x63,0x72,0x76])]:_0x2cc291([0x50,0x2d,0x32,0x35,0x36]),[_0x2cc291([0x78])]:_0x2cc291([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]),[_0x2cc291([0x79])]:_0x2cc291([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]),[_0x2cc291([0x61,0x6c,0x67])]:_0x2cc291([0x45,0x53,0x32,0x35,0x36])},_0x12faa5=_0x32642b[_0x2cc291([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x2cc291([0x67,0x65,0x74])](_0x2cc291([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x2da587(){let _0x3c639b,_0x38338a=null,_0x8a1e2a=null;try{if(_0x12faa5==_0x2cc291([0x47,0x50,0x4c]))return _0x2cc291([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x3c639b=_0x179d8c(),!_0x3c639b)return _0x2cc291([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x3c639b[_0x2cc291([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x8a1e2a=_0x54c172(_0x3c639b[_0x2cc291([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x3c639b[_0x2cc291([0x6a,0x74,0x69])])),await _0x36db15()?_0x122ebc()?_0x371e0b()?_0x2cc291([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x4412f8()?(_0x3c639b[_0x2cc291([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x2cc291([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x38338a=_0x5d4a70(_0x2cc291([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x3c639b[_0x2cc291([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x2cc291([0x74,0x72,0x69,0x61,0x6c])&&(_0x38338a=_0x5d4a70(_0x2cc291([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),await _0x50a611()):_0x2cc291([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x2cc291([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x2cc291([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch(_0x22d2ef){return _0x2cc291([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x371e0b(){const _0x47f5a2=[_0x2cc291([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x2cc291([0x74,0x72,0x69,0x61,0x6c])][_0x2cc291([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x3c639b[_0x2cc291([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x14cc5f/0x3e8:0xe10*_0x43b3db;return _0x3c639b[_0x2cc291([0x65,0x78,0x70])]<_0x47f5a2;}function _0x122ebc(){const _0x224f1a=_0x3c639b[_0x2cc291([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x224f1a)return!0x1;if(_0x224f1a[_0x2cc291([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x2cc291([0x2a])))return!0x0;if(_0x224f1a[_0x2cc291([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x2cc291([0x52,0x48])))return!0x0;if(_0x224f1a[_0x2cc291([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x2cc291([0x52,0x52,0x48]))){if(_0x567906())return!0x0;if(_0xb92f27()||_0x5353e3())return!0x0;}return!0x1;}function _0x4412f8(){const _0x55c4b5=_0x3c639b[_0x2cc291([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x55c4b5||0x0==_0x55c4b5[_0x2cc291([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x277c6e}=new URL(window[_0x2cc291([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x55c4b5[_0x2cc291([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x277c6e))return!0x0;const _0x3db612=_0x277c6e[_0x2cc291([0x73,0x70,0x6c,0x69,0x74])](_0x2cc291([0x2e]));return _0x55c4b5[_0x2cc291([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x396271=>_0x396271[_0x2cc291([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x2cc291([0x2a])))[_0x2cc291([0x6d,0x61,0x70])](_0x3f9aba=>_0x3f9aba[_0x2cc291([0x73,0x70,0x6c,0x69,0x74])](_0x2cc291([0x2e])))[_0x2cc291([0x73,0x6f,0x6d,0x65])](_0x3f3726=>_0x3db612[_0x2cc291([0x65,0x76,0x65,0x72,0x79])]((_0xe0e6d6,_0x114ebc)=>_0x3f3726[_0x114ebc]===_0xe0e6d6||_0x3f3726[_0x114ebc]===_0x2cc291([0x2a])));}function _0x50a611(){return _0x38338a&&_0x8a1e2a?new window[(_0x2cc291([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x5a52f6,_0x5fb910)=>{_0x38338a[_0x2cc291([0x74,0x68,0x65,0x6e])](_0x5a52f6,_0x5fb910),_0x8a1e2a[_0x2cc291([0x74,0x68,0x65,0x6e])](_0x3f52b3=>{_0x3f52b3!=_0x2cc291([0x56,0x61,0x6c,0x69,0x64])&&_0x5a52f6(_0x3f52b3);},_0x5fb910);}):_0x38338a||_0x8a1e2a||_0x2cc291([0x56,0x61,0x6c,0x69,0x64]);}}function _0x54c172(_0x3ed6ba,_0x47f7b0){return new window[(_0x2cc291([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x5a290e=>{if(_0x174d4a())return _0x5a290e(_0x2cc291([0x56,0x61,0x6c,0x69,0x64]));_0x3346e5(),_0x32642b[_0x2cc291([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x2cc291([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x4ae7e0=!0x1;const _0x54cc9a=_0x2bf2c8();function _0x5564d2(_0x1b66eb){return!!_0x1b66eb&&(typeof _0x1b66eb===_0x2cc291([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x1b66eb===_0x2cc291([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x1b66eb[_0x2cc291([0x74,0x68,0x65,0x6e])]===_0x2cc291([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x1b66eb[_0x2cc291([0x63,0x61,0x74,0x63,0x68])]===_0x2cc291([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x52828b(_0x570b75){_0xd512fa(_0x570b75)[_0x2cc291([0x74,0x68,0x65,0x6e])](_0xebb164=>{if(!_0xebb164||_0xebb164[_0x2cc291([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x2cc291([0x6f,0x6b]))return _0x2cc291([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x26e9b9(_0x174537(_0x54cc9a+_0x47f7b0))!=_0xebb164[_0x2cc291([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x2cc291([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x2cc291([0x56,0x61,0x6c,0x69,0x64]);})[_0x2cc291([0x74,0x68,0x65,0x6e])](_0x103bb5=>(_0x56336a(),_0x103bb5),()=>{const _0x22270e=_0x386c60();return null==_0x22270e?(_0x56336a(),_0x2cc291([0x56,0x61,0x6c,0x69,0x64])):_0x2cc291(_0x14cc5f-_0x22270e>(0x613d6eb0^_0x5efe89)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x2cc291([0x74,0x68,0x65,0x6e])](_0x5a290e)[_0x2cc291([0x63,0x61,0x74,0x63,0x68])](()=>{_0x5a290e(_0x2cc291([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x1a52df=0x45070430^_0x5efe89;function _0x56336a(){const _0x1144ee=_0x2cc291([0x6c,0x6c,0x63,0x74,0x2d])+_0x26e9b9(_0x174537(_0x3ed6ba)),_0x9caa4c=_0x334440(_0x26e9b9(window[_0x2cc291([0x4d,0x61,0x74,0x68])][_0x2cc291([0x63,0x65,0x69,0x6c])](_0x14cc5f/_0x1a52df)));window[_0x2cc291([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x2cc291([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x1144ee,_0x9caa4c);}function _0x386c60(){const _0x1d00f5=_0x2cc291([0x6c,0x6c,0x63,0x74,0x2d])+_0x26e9b9(_0x174537(_0x3ed6ba)),_0x525568=window[_0x2cc291([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x2cc291([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x1d00f5);return _0x525568?window[_0x2cc291([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x334440(_0x525568),0x10)*_0x1a52df:null;}function _0xd512fa(_0x1b9cef){return new window[(_0x2cc291([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x32a83,_0x53ea79)=>{_0x1b9cef[_0x2cc291([0x74,0x68,0x65,0x6e])](_0x32a83,_0x53ea79),window[_0x2cc291([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x53ea79,0x45303e70^_0x5efe89);});}}_0x32642b[_0x2cc291([0x6f,0x6e])](_0x2cc291([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0xd2674a,_0x2cdcbd)=>{if(_0x2cdcbd[0x0]!=_0x3ed6ba)return _0x5a290e(_0x2cc291([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x2cdcbd[0x1]={..._0x2cdcbd[0x1],[_0x2cc291([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x54cc9a};},{[_0x2cc291([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x2cc291([0x68,0x69,0x67,0x68])}),_0x32642b[_0x2cc291([0x6f,0x6e])](_0x2cc291([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x298151=>{_0x5564d2(_0x298151[_0x2cc291([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x4ae7e0=!0x0,_0x52828b(_0x298151[_0x2cc291([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x2cc291([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x2cc291([0x6c,0x6f,0x77])}),_0x21ed4e[_0x2cc291([0x74,0x68,0x65,0x6e])](()=>{_0x4ae7e0||_0x5a290e(_0x2cc291([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x174d4a(){return _0x32642b[_0x2cc291([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x2cc291([0x76,0x69,0x65,0x77])][_0x2cc291([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x2cc291([0x61,0x75,0x74,0x6f]);}function _0x3346e5(){_0x32642b[_0x2cc291([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x2cc291([0x76,0x69,0x65,0x77])][_0x2cc291([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x2cc291([0x61,0x75,0x74,0x6f]);}}function _0x5d4a70(_0xd3e83e){const _0x5615bf=[new window[(_0x2cc291([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x43c085=>setTimeout(_0x43c085,0x4538d47c^_0x5efe89)),_0x21ed4e[_0x2cc291([0x74,0x68,0x65,0x6e])](()=>new window[(_0x2cc291([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x30e3cb=>{const _0x72379f=0x4531eab7^_0x5efe89,_0x20dbc0=_0x1eeef2[_0x2cc291([0x5f,0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x73])];function _0x4aafc3(){_0x20dbc0[_0x2cc291([0x6c,0x65,0x6e,0x67,0x74,0x68])]>=_0x72379f&&_0x30e3cb();}_0x4aafc3(),_0x20dbc0[_0x2cc291([0x6f,0x6e])](_0x2cc291([0x61,0x64,0x64]),_0x4aafc3);})),new window[(_0x2cc291([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x5868c8=>{function _0xf93eaa(){for(const _0x2fa0fe in window)if(window[_0x2cc291([0x4e,0x75,0x6d,0x62,0x65,0x72])]['isNaN'](window[_0x2cc291([0x4e,0x75,0x6d,0x62,0x65,0x72])](_0x2fa0fe))&&window[_0x2fa0fe]==_0x1e670a)return _0x5868c8();_0x32642b[_0x2cc291([0x73,0x74,0x61,0x74,0x65])]!=_0x2cc291([0x64,0x65,0x73,0x74,0x72,0x6f,0x79,0x65,0x64])&&window[_0x2cc291([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0xf93eaa,0x4531f938^_0x5efe89);}_0x1fd8ee(_0x2cc291([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))&&_0xf93eaa();})];return window[_0x2cc291([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x2cc291([0x72,0x61,0x63,0x65])](_0x5615bf)[_0x2cc291([0x74,0x68,0x65,0x6e])](()=>_0xd3e83e);}async function _0x5c9c53(){if(await _0x21ed4e,_0x1fd8ee(_0x2cc291([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))){const _0x5bc56f=_0x1eeef2[_0x2cc291([0x67,0x65,0x74,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](0x0),_0x4bc94e=_0x1eeef2[_0x2cc291([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])](_0x5bc56f[_0x2cc291([0x69,0x64])]),_0x35c5de=_0x433ab0(_0x2cc291([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]));return await _0x35c5de[_0x2cc291([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])](_0x5bc56f['id'],_0x4bc94e?_0x4bc94e['id']:null,!0x0),_0x35c5de[_0x2cc291([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x2cc291([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x35c5de[_0x2cc291([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x35c5de[_0x2cc291([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])]=_0x986204,void(_0x35c5de[_0x2cc291([0x5f,0x67,0x65,0x74,0x44,0x69,0x66,0x66])]=_0x986204);}if(_0x1fd8ee(_0x2cc291([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]))){const _0x56d6d7=_0x433ab0(_0x2cc291([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]));_0x56d6d7[_0x2cc291([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x2cc291([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x56d6d7[_0x2cc291([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x56d6d7[_0x2cc291([0x75,0x70,0x64,0x61,0x74,0x65])]=_0x986204,_0x56d6d7[_0x2cc291([0x73,0x61,0x76,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])]=_0x986204;}_0x32642b[_0x2cc291([0x6d,0x6f,0x64,0x65,0x6c])][_0x2cc291([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x986204,_0x32642b[_0x2cc291([0x6d,0x6f,0x64,0x65,0x6c])][_0x2cc291([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x986204,_0x32642b[_0x2cc291([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x2cc291([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x567906(){return _0x1fd8ee(_0x2cc291([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x433ab0(_0x2cc291([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x2cc291([0x73,0x74,0x61,0x74,0x65])]==_0x2cc291([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0xb92f27(){return _0x1fd8ee(_0x2cc291([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 _0x5353e3(){return _0x1fd8ee(_0x2cc291([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0x554349(_0x3b2501){const _0x538299=_0x481377();_0x32642b[_0x538299]=_0x2cc291([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])+_0x3b2501,_0x3b2501[_0x2cc291([0x65,0x6e,0x64,0x73,0x57,0x69,0x74,0x68])](_0x2cc291([0x4c,0x69,0x6d,0x69,0x74]))&&(window[_0x481377()]=_0x1e670a),_0x3b2501!=_0x2cc291([0x56,0x61,0x6c,0x69,0x64])&&_0x5c9c53();}function _0x481377(){const _0x351ca0=window[_0x2cc291([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x2cc291([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x2cc291([0x6e,0x6f,0x77])]())[_0x2cc291([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x2cc291([0x2e]),'');let _0x54500d=_0x2cc291([0x52]);for(let _0xb72166=0x0;_0xb72166<_0x351ca0[_0x2cc291([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0xb72166+=0x2){let _0x61ed9f=window[_0x2cc291([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x351ca0[_0x2cc291([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0xb72166,_0xb72166+0x2));_0x61ed9f>=_0x23913f[_0x2cc291([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x61ed9f-=_0x23913f[_0x2cc291([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x54500d+=_0x23913f[_0x61ed9f];}return _0x54500d;}function _0x179d8c(){const _0x349b8a=_0x12faa5[_0x2cc291([0x73,0x70,0x6c,0x69,0x74])](_0x2cc291([0x2e]));if(0x3!=_0x349b8a[_0x2cc291([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x50864c(_0x349b8a[0x1]);function _0x50864c(_0xfa6022){const _0xd1c003=_0x4b7ff0(_0xfa6022);return _0xd1c003&&_0x2e5fa8()?_0xd1c003:null;function _0x2e5fa8(){const _0x3dc818=_0xd1c003[_0x2cc291([0x6a,0x74,0x69])],_0x559425=window[_0x2cc291([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x3dc818[_0x2cc291([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x3dc818[_0x2cc291([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x1dac7d={..._0xd1c003,[_0x2cc291([0x6a,0x74,0x69])]:_0x3dc818[_0x2cc291([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x3dc818[_0x2cc291([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x1dac7d[_0x2cc291([0x76,0x63])],_0x174537(_0x1dac7d)==_0x559425;}}}async function _0x36db15(){let _0x26de5d=!0x0;try{const _0x437da3=_0x12faa5[_0x2cc291([0x73,0x70,0x6c,0x69,0x74])](_0x2cc291([0x2e])),[_0x24df96,_0x105d73,_0x546a93]=_0x437da3;return _0x384f3d(_0x24df96),await _0x348038(_0x24df96,_0x105d73,_0x546a93),_0x26de5d;}catch(_0x4d5abc){return!0x1;}function _0x384f3d(_0x585692){const _0x3c7ef7=_0x4b7ff0(_0x585692);_0x3c7ef7&&_0x3c7ef7[_0x2cc291([0x61,0x6c,0x67])]==_0x2cc291([0x45,0x53,0x32,0x35,0x36])||(_0x26de5d=!0x1);}async function _0x348038(_0x5dc21d,_0xab7707,_0x598c8f){const _0x53f0cf=window[_0x2cc291([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x2cc291([0x66,0x72,0x6f,0x6d])](_0x429bc5(_0x598c8f),_0x67e7e0=>_0x67e7e0[_0x2cc291([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x28e50d=new window[(_0x2cc291([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x2cc291([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x5dc21d+_0x2cc291([0x2e])+_0xab7707),_0x5ea22d=window[_0x2cc291([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x2cc291([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x5ea22d)return;const _0x391ec4=await _0x5ea22d[_0x2cc291([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x2cc291([0x6a,0x77,0x6b]),_0x3125f8,{[_0x2cc291([0x6e,0x61,0x6d,0x65])]:_0x2cc291([0x45,0x43,0x44,0x53,0x41]),[_0x2cc291([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x2cc291([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x2cc291([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x5ea22d[_0x2cc291([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x2cc291([0x6e,0x61,0x6d,0x65])]:_0x2cc291([0x45,0x43,0x44,0x53,0x41]),[_0x2cc291([0x68,0x61,0x73,0x68])]:{[_0x2cc291([0x6e,0x61,0x6d,0x65])]:_0x2cc291([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x391ec4,_0x53f0cf,_0x28e50d)||(_0x26de5d=!0x1);}}function _0x4b7ff0(_0x307c22){return _0x307c22[_0x2cc291([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x2cc291([0x65,0x79]))?JSON[_0x2cc291([0x70,0x61,0x72,0x73,0x65])](_0x429bc5(_0x307c22)):null;}function _0x429bc5(_0x4761eb){return window[_0x2cc291([0x61,0x74,0x6f,0x62])](_0x4761eb[_0x2cc291([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x2cc291([0x2b]))[_0x2cc291([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x2cc291([0x2f])));}function _0x174537(_0x1a852a){let _0x34d724=0x1505;function _0x47384a(_0x4e04e5){for(let _0x31816d=0x0;_0x31816d<_0x4e04e5[_0x2cc291([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x31816d++){const _0x10eac9=_0x4e04e5[_0x2cc291([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x31816d);_0x34d724=(_0x34d724<<0x5)+_0x34d724+_0x10eac9,_0x34d724&=_0x34d724;}}function _0x3dc25f(_0x1a1ad4){Array[_0x2cc291([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x1a1ad4)?_0x1a1ad4[_0x2cc291([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x3dc25f):_0x1a1ad4&&typeof _0x1a1ad4==_0x2cc291([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x2cc291([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x1a1ad4)[_0x2cc291([0x73,0x6f,0x72,0x74])]()[_0x2cc291([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x359815,_0x237bdd])=>{_0x47384a(_0x359815),_0x3dc25f(_0x237bdd);}):_0x47384a(window[_0x2cc291([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x1a1ad4));}return _0x3dc25f(_0x1a852a),_0x34d724>>>0x0;}function _0x26e9b9(_0x97613e){return _0x97613e[_0x2cc291([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x2cc291([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x2cc291([0x30]));}function _0x334440(_0x239817){return _0x239817[_0x2cc291([0x73,0x70,0x6c,0x69,0x74])]('')[_0x2cc291([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x2cc291([0x6a,0x6f,0x69,0x6e])]('');}function _0x1fd8ee(_0x360178){return _0x32642b[_0x2cc291([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x2cc291([0x68,0x61,0x73])](_0x360178);}function _0x433ab0(_0x4bbf90){return _0x32642b[_0x2cc291([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x2cc291([0x67,0x65,0x74])](_0x4bbf90);}function _0x986204(){}function _0x2cc291(_0x789dd8){return _0x789dd8['map'](_0x5887a5=>String['fromCharCode'](_0x5887a5))['join']('');}_0x554349(await _0x2da587());}(this);}['createRevision'](_0x440a2e){const _0xc531fd=this['editor']['plugins']['get']('Users');return new h({'id':_0x440a2e['id'],'name':_0x440a2e['name'],'creator':_0x440a2e['creatorId']?_0xc531fd['getUser'](_0x440a2e['creatorId']):null,'diffData':_0x440a2e['diffData']||_0x440a2e['data'],'authors':_0x440a2e['authorsIds']['map'](_0x107e82=>_0xc531fd['getUser'](_0x107e82)),'createdAt':new Date(_0x440a2e['createdAt']),'attributes':_0x440a2e['attributes'],'fromVersion':_0x440a2e['fromVersion'],'toVersion':_0x440a2e['toVersion']});}['addRevision'](_0x1b50f0,_0x4b26c7=0x0){this['_revisions']['add'](_0x1b50f0,_0x4b26c7);}['getRevision'](_0x5a907b){return this['_revisions']['get'](_0x5a907b);}['getRevisions'](_0x556809={'toJSON':!0x1}){const _0x79e331=Array['from'](this['_revisions']);return _0x79e331['reverse'](),_0x556809['toJSON']?_0x79e331['map'](_0x2d70db=>_0x2d70db['toJSON']()):_0x79e331;}['getIndex'](_0x297b04){return this['_revisions']['getIndex'](_0x297b04);}['getEarlierVisibleRevision'](_0x4329be){const [,_0x217684]=this['getRevisionsIterator'](_0x4329be,{'direction':'earlier'});return _0x217684;}['getLaterVisibleRevision'](_0x2b767f){const [,_0x4f62a9]=this['getRevisionsIterator'](_0x2b767f,{'direction':'later'});return _0x4f62a9;}['getRevisionsInDiff'](_0x423bdd){const _0x96716b=[];for(const _0x59e86f of this['getRevisionsIterator'](_0x423bdd['newRevisionId']))if(_0x96716b['push'](_0x59e86f),_0x59e86f['id']===_0x423bdd['oldRevisionId'])break;return _0x96716b;}*['getRevisionsIterator'](_0x4c9cd9,{direction:_0x38468b='earlier',filter:_0x4b2c38=()=>!0x0}={}){const _0xa40e10='earlier'===_0x38468b?0x1:-0x1;let _0x49ead3=this['_revisions']['get'](_0x4c9cd9),_0x140888=this['getIndex'](_0x49ead3);for(yield _0x49ead3;_0x49ead3;){if(_0x140888+=_0xa40e10,_0x49ead3=this['getRevision'](_0x140888),!_0x49ead3)return;_0x4b2c38(_0x49ead3)&&(yield _0x49ead3);}}}class V extends _0x45698e{static get['pluginName'](){return'RevisionHistoryUtils';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['_viewClassToTypeChar']=new Map([[_0xefa514,'c'],[_0x5cbe7a,'a'],[_0x130320,'e'],[_0xc9123a,'r'],[_0x5c8ddc,'u']]);['_typeCharToViewClass']=new Map([['c',_0xefa514],['a',_0x5cbe7a],['e',_0x130320],['r',_0xc9123a],['u',_0x5c8ddc]]);async['loadRevisionData'](_0x3f115d,_0x4a7086){if(_0x3f115d['diffData']||!_0x4a7086)return;const _0x1b4e83=this['editor']['config']['get']('collaboration.channelId'),_0x3e3e62=await _0x4a7086['getRevision']({'channelId':_0x1b4e83,'revisionId':_0x3f115d['id']});_0x3f115d['diffData']=_0x3e3e62['diffData'];}['getRevisionDocumentData'](_0x1c9195){const _0x2b90ad={};for(const _0x3a68dd in _0x1c9195['diffData']){if(_0x1c9195['diffData'][_0x3a68dd]['attachChange']&&!_0x1c9195['diffData'][_0x3a68dd]['attachChange']['isAttached'])continue;const _0x329ed7=this['_removeRevisionMarkers'](JSON['parse'](_0x1c9195['diffData'][_0x3a68dd]['insertions'])),_0x28178d=this['editor']['editing']['view']['document'],_0x4972e7=new _0x3c0815(_0x28178d,_0x329ed7['map'](_0x22068e=>this['_getViewFromDiffObj'](_0x22068e,!0x1)));this['editor']['data']['processor']['useFillerType']('marked'),_0x2b90ad[_0x3a68dd]=this['editor']['data']['processor']['toData'](_0x4972e7),this['editor']['data']['processor']['useFillerType']('default');}return _0x2b90ad;}['getRevisionRootsAttributes'](_0x4f73ee){const _0x5a0648={};for(const _0x1b99ef in _0x4f73ee['diffData'])_0x4f73ee['diffData'][_0x1b99ef]['attachChange']&&!_0x4f73ee['diffData'][_0x1b99ef]['attachChange']['isAttached']||(_0x5a0648[_0x1b99ef]=_0x4f73ee['diffData'][_0x1b99ef]['attributesAfter']||{});return _0x5a0648;}['_getTypeCharForViewElement'](_0x29aea0){return this['_viewClassToTypeChar']['get'](_0x29aea0['constructor']);}['_getViewFromDiffObj'](_0x585ba3,_0x3aeb76){const _0x1c09cd=this['editor']['editing']['view']['document'];if('string'==typeof _0x585ba3)return new _0x5e53ef(_0x1c09cd,_0x585ba3);{let _0x51c0d6,_0x2550f8;_0x2550f8='u'==_0x585ba3['type']||'r'==_0x585ba3['type']?[]:_0x585ba3['children']['map'](_0x289088=>this['_getViewFromDiffObj'](_0x289088,_0x3aeb76));const _0x1d1537=this['_typeCharToViewClass']['get'](_0x585ba3['type'])||_0x33a267,_0x549efd=this['editor']['data']['htmlProcessor']['domConverter'];if(_0x51c0d6=new _0x1d1537(_0x1c09cd,_0x585ba3['name'],_0x585ba3['attributes'],_0x2550f8),'u'==_0x585ba3['type']&&_0x585ba3['children'][0x0]){const _0x264bdc=_0x585ba3['children'][0x0];if(_0x51c0d6['render']=function(_0x5c251e){const _0x566c0a=_0x5c251e['createElement']('div');return _0x566c0a['innerHTML']=_0x264bdc,_0x566c0a['childNodes'][0x0];},_0x3aeb76){const _0xb4f7b9=new _0x3c0815(_0x1c09cd);_0xb4f7b9['_appendChild'](_0x51c0d6);const _0x12bacf=Array['from'](_0x549efd['viewChildrenToDom'](_0xb4f7b9,{'bind':!0x1})),_0x2fb142=_0x549efd['domDocument']['createElement']('div');_0x2fb142['append'](..._0x12bacf),_0x51c0d6=Array['from'](_0x549efd['domChildrenToView'](_0x2fb142))[0x0];}}else{if('r'==_0x585ba3['type']&&_0x585ba3['children'][0x0]){const _0x409731=_0x585ba3['children'][0x0];if(_0x51c0d6['render']=function(_0x54e5af){_0x54e5af['innerHTML']=_0x409731;},_0x3aeb76){const _0x1edf8a=new _0x3c0815(_0x1c09cd);_0x1edf8a['_appendChild'](_0x51c0d6);const _0x421ec9=Array['from'](_0x549efd['viewChildrenToDom'](_0x1edf8a,{'bind':!0x1})),_0x24a0fe=_0x549efd['domDocument']['createElement']('div');_0x24a0fe['append'](..._0x421ec9);const _0x1ca229=Array['from'](_0x549efd['domChildrenToView'](_0x24a0fe));_0x1ca229['length']>0x1?_0x51c0d6['_appendChild'](_0x1ca229):_0x51c0d6=_0x1ca229[0x0];}}}if(_0x585ba3['customProperties']){for(const [_0x26d063,_0x405596]of _0x585ba3['customProperties'])_0x51c0d6['_setCustomProperty'](_0x26d063,_0x405596);}const _0x38a68b=void 0x0===_0x585ba3['fillerOffset']?null:_0x585ba3['fillerOffset'];return null!==_0x38a68b&&(_0x51c0d6['getFillerOffset']=()=>_0x38a68b),_0x51c0d6;}}['_makeModelFromViewString'](_0x49125f){const _0x125665=JSON['parse'](_0x49125f),_0x50ee2b=this['editor']['editing']['view']['document'],_0x25dcdb=new _0x3c0815(_0x50ee2b,_0x125665['map'](_0x56eff7=>this['_getViewFromDiffObj'](_0x56eff7,!0x0)));return this['editor']['data']['toModel'](_0x25dcdb);}['_removeRevisionMarkers'](_0x40dac8){return(_0x40dac8=_0x40dac8['filter'](_0x5c2e27=>!_0x5c2e27['name']||'revision-start'!==_0x5c2e27['name']&&'revision-end'!==_0x5c2e27['name']))['forEach'](_0x217a38=>{'string'!=typeof _0x217a38&&(_0x217a38['children']=this['_removeRevisionMarkers'](_0x217a38['children']),_0x217a38['attributes']=_0x217a38['attributes']['filter'](_0x1584c7=>!_0x1584c7[0x0]['startsWith']('data-revision-')));}),_0x40dac8;}}function g(_0x35e5a5,_0x1c6a66,_0x329fa5){const t=_0x35e5a5['t'];switch(_0x1c6a66){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'},_0x329fa5);case'X_OF_Y_CHANGES':return t({'string':'%0\x20of\x20%1','id':'X_OF_Y_CHANGES'},_0x329fa5);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 _0x45698e{['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[_0x30649f,I,V,_0x3cb8d4];}constructor(_0x4b8564){super(_0x4b8564),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 _0x590a54=_0x2bf2c8();this['_source']={'history':this['editor']['model']['document']['history'],'getLatestVersion':()=>Promise['resolve'](this['editor']['model']['document']['version']),'getCurrentRevisionId':()=>_0x590a54},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 _0x47e640=this['repository']['getRevision'](0x0),_0x3d63f7=_0x47e640&&null===_0x47e640['creator']?_0x47e640:null;if(this['_continueCurrentRevision']=!!_0x3d63f7&&this['editor']['config']['get']('revisionHistory.resumeUnsavedRevision'),this['editor']['plugins']['has']('RealTimeCollaborationClient')){const _0x528522=this['_source']['getCurrentRevisionId'](),_0x3abe27=this['repository']['getRevision'](_0x528522);if(_0x3abe27)this['_startingVersion']=_0x3abe27['fromVersion'],this['_continueCurrentRevision']=!0x1;else{const _0x1d5ef6=this['_source']['history']['_operations']['find'](_0x58836e=>!_0x58836e['_isInit']),_0x41a13a=_0x1d5ef6?_0x1d5ef6['baseVersion']:this['_source']['history']['version'];_0x47e640?(_0x47e640['toVersion']<_0x41a13a&&_0x47e640['_update']({'toVersion':_0x41a13a}),this['_continueCurrentRevision']?(this['_source']['getCurrentRevisionId']=()=>_0x3d63f7['id'],this['_startingVersion']=_0x3d63f7['fromVersion']):(this['_startingVersion']=_0x47e640['toVersion'],this['_continueCurrentRevision']=!0x1)):(this['_startingVersion']=_0x41a13a,this['_continueCurrentRevision']=!0x1);}}else _0x3d63f7&&(this['editor']['model']['document']['history']['version']=Math['max'](_0x3d63f7['toVersion'],this['editor']['model']['document']['history']['version']),_0x3d63f7['fromVersion']===_0x3d63f7['toVersion']?(0x0!==_0x3d63f7['fromVersion']&&(this['_source']['getCurrentRevisionId']=()=>_0x3d63f7['id']),this['_continueCurrentRevision']=!0x1):this['_continueCurrentRevision']&&(this['_source']['getCurrentRevisionId']=()=>_0x3d63f7['id'],this['_startingVersion']=_0x3d63f7['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',_0x46e7b3=>!_0x46e7b3),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0xbd0565=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x5a06d5;for(const _0x3248f3 in _0xbd0565){const _0x292126=_0x3248f3,_0x5efd46=_0xbd0565[_0x292126];if('revisionHistoryLicenseKeyValid'==_0x5efd46||'revisionHistoryLicenseKeyInvalid'==_0x5efd46||'revisionHistoryLicenseKeyExpired'==_0x5efd46||'revisionHistoryLicenseKeyDomainLimit'==_0x5efd46||'revisionHistoryLicenseKeyNotAllowed'==_0x5efd46||'revisionHistoryLicenseKeyEvaluationLimit'==_0x5efd46||'revisionHistoryLicenseKeyTrialLimit'==_0x5efd46||'revisionHistoryLicenseKeyUsageLimit'==_0x5efd46){delete _0xbd0565[_0x292126],_0x5a06d5=_0x5efd46,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'revisionHistoryLicenseKeyInvalid'==_0x5a06d5&&_0xbd0565['_showLicenseError']('invalid'),'revisionHistoryLicenseKeyExpired'==_0x5a06d5&&_0xbd0565['_showLicenseError']('expired'),'revisionHistoryLicenseKeyDomainLimit'==_0x5a06d5&&_0xbd0565['_showLicenseError']('domainLimit'),'revisionHistoryLicenseKeyNotAllowed'==_0x5a06d5&&_0xbd0565['_showLicenseError']('featureNotAllowed','RevisionHistory'),'revisionHistoryLicenseKeyEvaluationLimit'==_0x5a06d5&&_0xbd0565['_showLicenseError']('evaluationLimit'),'revisionHistoryLicenseKeyTrialLimit'==_0x5a06d5&&_0xbd0565['_showLicenseError']('trialLimit'),'revisionHistoryLicenseKeyUsageLimit'==_0x5a06d5&&_0xbd0565['_showLicenseError']('usageLimit');},0x3e8);}async['afterInit'](){if(this['repository']['length']>0x0){const _0x517fba=this['repository']['getRevision'](0x0),_0x9373f5=await this['getRevisionDocumentData'](_0x517fba),_0x1ecb42=await this['getRevisionRootsAttributes'](_0x517fba);this['_replaceEditorDataWithRevisionData'](_0x9373f5,_0x1ecb42);}}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['setSource'](_0x5a6b42){this['_source']=_0x5a6b42;}async['update'](){const _0xc1b38b=await this['_source']['getLatestVersion']();if(_0xc1b38b>this['currentRevision']['toVersion']){await this['_loadState']();const _0x58c42b=this['buildRevisionData']({'revision':this['currentRevision'],'to':_0xc1b38b});_0x58c42b['authors']=_0x58c42b['authorsIds']['map'](_0x235aef=>this['editor']['plugins']['get']('Users')['getUser'](_0x235aef)),this['currentRevision']['_update'](_0x58c42b);}}async['saveRevision'](_0x24c689={},_0x4c91de=null){const _0x5c4878=[];await this['_loadState'](),this['_continueCurrentRevision']=!0x1,_0x4c91de>this['currentRevision']['toVersion']&&(_0x4c91de=null),null===_0x4c91de&&(_0x4c91de=await this['_source']['getLatestVersion']());const _0x274b00=this['_getFromVersion'](_0x4c91de),_0x1bf6b0=this['buildRevisionData']({'from':_0x274b00,'to':_0x4c91de});if(this['currentRevision']['toVersion']<_0x4c91de){const _0x367a3f=this['buildRevisionData']({'revision':this['currentRevision'],'from':_0x4c91de,'to':_0x4c91de});_0x367a3f['authors']=[],_0x367a3f['authorsIds']=[],_0x367a3f['id']=this['currentRevision']['id'],this['currentRevision']['_update'](_0x367a3f,!0x0),delete _0x367a3f['authors'],_0x5c4878['push'](_0x367a3f);}_0x24c689['creatorId']=this['editor']['plugins']['get']('Users')['me']['id'],_0x24c689['name']=_0x24c689['name']||null,_0x24c689['id']=_0x24c689['id']||_0x2bf2c8(),_0x24c689={..._0x24c689,..._0x1bf6b0};const _0x4256f6=this['addRevisionData'](_0x24c689);_0x5c4878['push'](_0x24c689);const _0x3ba0a2=this['repository']['getIndex'](_0x4256f6);if(0x0!==_0x3ba0a2){const _0x43e746=this['repository']['getRevision'](_0x3ba0a2-0x1);if(_0x43e746['fromVersion']!==_0x4c91de){const _0x162c34=this['_revisionDataBuilder']['getData'](_0x4c91de,_0x43e746['toVersion']),_0x3713d1={'id':_0x43e746['id'],'diffData':_0x162c34['diffData'],'authorsIds':_0x162c34['authorsIds'],'authors':_0x162c34['authorsIds']['map'](_0xe8ad01=>this['editor']['plugins']['get']('Users')['getUser'](_0xe8ad01)),'fromVersion':_0x4c91de};_0x43e746===this['currentRevision']&&(_0x3713d1['createdAt']=new Date(_0x24c689['createdAt']['getTime']()+0xa)),_0x43e746['_update'](_0x3713d1,!0x0),delete _0x3713d1['authors'],_0x5c4878['push'](_0x3713d1);}}if(this['adapter']){for(const _0x8d6eae of _0x5c4878)this['_bufferUpdate'](_0x8d6eae['id'],_0x8d6eae,!0x0);this['sendBufferedUpdates']();}return _0x4256f6;}['addRevisionData'](_0x1b571d){const _0x6f50cd=this['repository']['createRevision'](_0x1b571d);return this['adapter']&&_0x6f50cd['on']('_update',(_0x3fbd3c,_0x33cf0d,_0x16f43b)=>{_0x16f43b||(this['_bufferUpdate'](_0x33cf0d['id'],_0x33cf0d,!0x0),this['sendBufferedUpdates']());}),this['repository']['addRevision'](_0x6f50cd,this['_findInsertionIndex'](_0x6f50cd)),_0x6f50cd;}async['getRevisionDocumentData'](_0x1462f7){return await this['_utils']['loadRevisionData'](_0x1462f7,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x1462f7);}async['getRevisionRootsAttributes'](_0x1841ae){return await this['_utils']['loadRevisionData'](_0x1841ae,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x1841ae);}['sendBufferedUpdates'](){if(0x0===this['_bufferedUpdates']['size'])return;if(this['_isPendingUpdate'])return;let _0x5578a8=Array['from'](this['_bufferedUpdates']['values']());this['_bufferedUpdates']['clear']();for(let _0x2f2a07=0x0;_0x2f2a07<_0x5578a8['length'];_0x2f2a07++){const _0x104ccb=_0x5578a8[_0x2f2a07];let _0x18590e=!0x1;for(const _0x19d1a2 of Object['keys'](_0x104ccb))void 0x0===_0x104ccb[_0x19d1a2]?delete _0x104ccb[_0x19d1a2]:'id'!==_0x19d1a2&&(_0x18590e=!0x0);_0x18590e||(_0x5578a8[_0x2f2a07]=null);}if(_0x5578a8=_0x5578a8['filter'](_0x4aec0d=>null!==_0x4aec0d),!_0x5578a8['length'])return;for(let _0x5ba3b2=0x0;_0x5ba3b2<_0x5578a8['length'];_0x5ba3b2++){const _0x161ccb=_0x5578a8[_0x5ba3b2];void 0x0!==_0x161ccb['fromVersion']&&void 0x0===_0x161ccb['toVersion']&&(_0x161ccb['toVersion']=this['repository']['getRevision'](_0x161ccb['id'])['toVersion']),void 0x0!==_0x161ccb['toVersion']&&void 0x0===_0x161ccb['fromVersion']&&(_0x161ccb['fromVersion']=this['repository']['getRevision'](_0x161ccb['id'])['fromVersion']);}const _0x2d6e37=this['editor']['config']['get']('collaboration.channelId');this['_isPendingUpdate']=!0x0,this['_addPendingAction'](),this['adapter']['updateRevisions'](_0x5578a8,_0x2d6e37)['finally'](()=>{this['_isPendingUpdate']=!0x1;})['then'](_0x5f20a9=>{if(_0x5f20a9){for(const _0x146512 of _0x5f20a9)this['setRevisionData']({'id':_0x146512['id'],'createdAt':_0x146512['createdAt']});}this['_removePendingAction'](),this['sendBufferedUpdates']();});}['buildRevisionData']({revision:_0x40c3f4=null,from:_0x2e387c=null,to:_0x17c8dd=null}){_0x2e387c=null!==_0x2e387c?_0x2e387c:_0x40c3f4['fromVersion'],_0x17c8dd=null!==_0x17c8dd?_0x17c8dd:_0x40c3f4['toVersion'];const _0x5611fd=this['_revisionDataBuilder']['getData'](_0x2e387c,_0x17c8dd),_0x3f57ac={'diffData':_0x5611fd['diffData'],'authorsIds':_0x5611fd['authorsIds'],'fromVersion':_0x2e387c,'toVersion':_0x17c8dd};if(!_0x40c3f4||_0x17c8dd!==_0x40c3f4['toVersion']){const _0x398244=_0x17c8dd-0x1,_0x4f3f6b=this['_source']['history']['getOperation'](_0x398244);_0x3f57ac['createdAt']=_0x4f3f6b&&_0x4f3f6b['createdAt']||new Date();}if(this['_loadedStateData']&&_0x2e387c===this['_loadedStateData']['fromVersion']){for(const _0x43becf of this['_loadedStateData']['authors'])_0x3f57ac['authorsIds']['includes'](_0x43becf['id'])||_0x3f57ac['authorsIds']['push'](_0x43becf['id']);}return _0x3f57ac;}['_bufferUpdate'](_0x59ea6a,_0x50eb6a,_0x22bf12){if(this['_bufferedUpdates']['has'](_0x59ea6a)){const _0x1f10aa=this['_bufferedUpdates']['get'](_0x59ea6a);_0x50eb6a=_0x22bf12?{..._0x1f10aa,..._0x50eb6a}:{..._0x50eb6a,..._0x1f10aa};}this['_bufferedUpdates']['set'](_0x59ea6a,_0x50eb6a);}['setRevisionData'](_0xd42aea){const _0x3309bd=this['repository']['getRevision'](_0xd42aea['id']);if(_0xd42aea['createdAt']&&(_0xd42aea['createdAt']=new Date(_0xd42aea['createdAt'])),_0xd42aea['authorsIds']){const _0x3756a2=this['editor']['plugins']['get']('Users');_0xd42aea['authors']=_0xd42aea['authorsIds']['map'](_0xf90291=>_0x3756a2['getUser'](_0xf90291));}_0x3309bd['_update'](_0xd42aea,!0x0);}['_createInitialRevision'](_0x322fa2){const _0xd79e9b=this['repository']['getRevision'](this['repository']['length']-0x1);if(_0xd79e9b)this['_initialRevisionId']=_0xd79e9b['id'];else{const _0x587c89=!this['editor']['model']['document']['roots']['find'](_0x5f47d9=>this['editor']['model']['hasContent'](_0x5f47d9)),_0x18e039=this['editor']['plugins']['get']('Users')['me']['id'],_0x1686c0=g(this['editor']['locale'],_0x587c89?'Empty\x20document':'Initial\x20revision');this['_makeRevision']({'from':_0x322fa2,'to':_0x322fa2,'id':this['_initialRevisionId'],'name':_0x1686c0,'creatorId':_0x18e039});}}['_createCurrentRevision'](_0x92cc20){const _0x3dbbc8=this['_source']['getCurrentRevisionId']();this['currentRevision']=this['repository']['getRevision'](_0x3dbbc8),this['currentRevision']||(this['currentRevision']=this['_makeRevision']({'from':_0x92cc20,'to':_0x92cc20,'id':_0x3dbbc8,'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'](_0x36cc82,_0x319e7b){let _0x29d0ba=this['editor']['config']['get']('initialData'),_0x41dc95=this['editor']['config']['get']('rootsAttributes');if(void 0x0===_0x29d0ba){_0x29d0ba={};for(const _0x335ef4 of this['editor']['model']['document']['getRootNames']())_0x29d0ba[_0x335ef4]='';}if('string'==typeof _0x29d0ba&&(_0x29d0ba={'main':_0x29d0ba}),void 0x0===_0x41dc95){_0x41dc95={};for(const _0x13e8ee of this['editor']['model']['document']['getRootNames']())_0x41dc95[_0x13e8ee]={};}let _0x24f453=!0x1;const _0x1128d8=Object['keys'](_0x29d0ba),_0x3fe11e=Object['keys'](_0x36cc82);for(const _0x135256 of _0x1128d8){if(_0x29d0ba[_0x135256]!==_0x36cc82[_0x135256]&&''!==_0x29d0ba[_0x135256]['trim']()){_0x24f453=!0x0;break;}if(!_0x3c74a0(_0x41dc95[_0x135256],_0x319e7b[_0x135256])&&Object['keys'](_0x41dc95[_0x135256])['length']>0x0){_0x24f453=!0x0;break;}}_0x24f453||(_0x24f453=_0x3fe11e['some'](_0x3551f0=>!this['editor']['model']['document']['getRoot'](_0x3551f0))),_0x24f453&&_0x46488b('editor-initial-data-replaced-with-revision-data',{'editorData':_0x29d0ba,'editorRootsAttributes':_0x41dc95,'revisionData':_0x36cc82,'revisionRootsAttributes':_0x319e7b}),this['editor']['config']['set']('initialData',_0x36cc82),this['editor']['config']['set']('rootsAttributes',_0x319e7b);}['_addPendingAction'](){if(!this['_pendingAction']){const _0x459a46=this['editor']['plugins']['get']('PendingActions');this['_pendingAction']=_0x459a46['add'](g(this['editor']['locale'],'PENDING_ACTION_REVISION_HISTORY'));}}['_removePendingAction'](){this['_pendingAction']&&(this['editor']['plugins']['get']('PendingActions')['remove'](this['_pendingAction']),this['_pendingAction']=null);}['_findInsertionIndex'](_0x170cbb){const _0x2ba5c7=this['repository']['getRevisions']();_0x2ba5c7['reverse']();let _0x5d04f5=0x0;for(;_0x5d04f5<_0x2ba5c7['length'];){const _0x395b9f=_0x2ba5c7[_0x5d04f5];if(_0x395b9f===this['currentRevision']){_0x5d04f5++;continue;}if(_0x395b9f['id']===this['_initialRevisionId'])break;const _0x179e5b=_0x170cbb['toVersion']-_0x395b9f['toVersion']||_0x170cbb['fromVersion']-_0x395b9f['fromVersion'];if(_0x179e5b>0x0)break;if(_0x179e5b<0x0)_0x5d04f5++;else{if(!_0x170cbb['creator']&&_0x395b9f['creator'])break;if(_0x395b9f['creator']||!_0x170cbb['creator']){if(_0x170cbb['createdAt']>_0x395b9f['createdAt'])break;_0x5d04f5++;}else _0x5d04f5++;}}return _0x5d04f5;}['_getFromVersion'](_0x4fd3ba){const _0x2e58b5=this['repository']['getRevisions']();_0x2e58b5['reverse'](),_0x2e58b5['shift']();const _0x3a1971=_0x2e58b5['find'](_0x418253=>_0x418253['toVersion']<=_0x4fd3ba)['toVersion'];return _0x3a1971<this['_startingVersion']?this['_startingVersion']:_0x3a1971;}['_makeRevision']({name:_0x49e694,from:_0x1ba901,to:_0x303895,creatorId:_0x5597fa,id:_0x55088d}){const _0x20313a=this['buildRevisionData']({'from':_0x1ba901,'to':_0x303895});_0x20313a['name']=_0x49e694,_0x20313a['creatorId']=_0x5597fa,_0x20313a['id']=_0x55088d;const _0x2d5551=this['addRevisionData'](_0x20313a);return this['adapter']&&this['_bufferUpdate'](_0x20313a['id'],_0x20313a,!0x0),_0x2d5551;}['_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(_0x2e5262){this['editor']=_0x2e5262,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'](_0xbc869f){this['source']=_0xbc869f;const _0x5b3b67=new Map(),_0x231fcc=new Map(),_0x3834f8=this['editor']['model']['document']['roots']['map'](_0x36d7eb=>_0x36d7eb['rootName']);for(const _0x51b462 of _0x3834f8){const _0x49eefb=this['editor']['model']['document']['getRoot'](_0x51b462),_0x9cc23d=N(_0x49eefb);_0x5b3b67['set'](_0x51b462,_0x9cc23d),_0x231fcc['set'](_0x51b462,Object['fromEntries'](_0x49eefb['getAttributes']()));}const _0x9ede2b=Array['from'](this['editor']['model']['markers'])['map'](_0x375565=>[_0x375565['name'],_0x375565['getRange']()]),_0x1215ef=this['source']['version'];this['_saveMetaData'](_0x1215ef,_0x5b3b67,_0x9ede2b,_0x231fcc),this['_startingRevisionId']=this['_revisionId'];const _0x35672e=new Map(),_0x247dde=new Map();for(const _0x555439 of _0x3834f8){const _0x47da92=P(_0x555439);_0x35672e['set'](_0x555439,_0x47da92),_0x247dde['set'](_0x555439,{});}this['_saveMetaData'](Number['NEGATIVE_INFINITY'],_0x35672e,[],_0x247dde);}['getData'](_0x409895,_0x39ffac){if(this['_lastFrom']===_0x409895&&this['_lastTo']<=_0x39ffac)this['_savedMetaData']['size']>0x1&&this['_removeMetaData'](this['_lastTo']),this['_applyOperations'](this['_lastTo'],_0x39ffac,!0x0);else{if(!this['_savedMetaData']['has'](_0x409895)){const _0x2b18f0=this['_getPreviousFrom'](_0x409895);this['_calculateMetaData'](_0x2b18f0,_0x409895,!0x1);}this['_calculateMetaData'](_0x409895,_0x39ffac,!0x0);}return this['_lastFrom']=_0x409895,this['_lastTo']=_0x39ffac,this['_getState']();}['loadState'](_0x504ca7){const _0xe611e=this['editor']['plugins']['get']('RevisionHistoryUtils');this['_reset'](),this['_lastFrom']=_0x504ca7['fromVersion'],this['_lastTo']=_0x504ca7['toVersion'];for(const _0x35eeee in _0x504ca7['diffData']){const _0x4f2795=_0x504ca7['diffData'][_0x35eeee]['attachChange'],_0x5eb278=_0xef8248(_0x504ca7['diffData'][_0x35eeee]['attributesBefore'])||{},_0x443746=_0xe611e['_makeModelFromViewString'](_0x504ca7['diffData'][_0x35eeee]['deletions']);_0x443746['rootName']=_0x35eeee,_0x443746['_isAttached']=!_0x4f2795||!_0x4f2795['isAttached'],_0x443746['isAttached']=()=>_0x443746['_isAttached'],this['_baseRoots']['set'](_0x35eeee,_0x443746),this['_baseRootsAttributes']['set'](_0x35eeee,_0x5eb278),_0x4f2795&&this['_touchedRoots']['set'](_0x35eeee,_0x4f2795);const _0x34acca=this['_makeIdsRoot'](_0x443746);this['_baseIdsRoots']['set'](_0x35eeee,_0x34acca);for(const [_0x2aa33d,_0x12fa17]of _0x443746['markers']){if(!_0x2aa33d['startsWith']('revision:'))continue;const _0x49fd11=_0x2aa33d['split'](':')[0x2];for(const _0x664d1a of _0x12fa17['getWalker']({'singleCharacters':!0x0})){const _0x5b971f=this['_getVidAttributeName'](_0x664d1a),_0x276f73='elementEnd'==_0x664d1a['type']?_0x664d1a['previousPosition']['path']['slice'](0x0,-0x1):_0x664d1a['previousPosition']['path'],_0x35d57b=_0x34acca['getNodeByPath'](_0x276f73)['getAttribute'](_0x5b971f);this['_touched']['set'](_0x35d57b,{'userId':_0x49fd11});}}}this['_startingRevisionId']=this['_revisionId'];const _0x170f4b=[...Array(this['_revisionId'])['keys']()]['slice'](0x1)['filter'](_0x17db31=>!this['_touched']['has'](_0x17db31));let _0x438569=0x0;const _0x30d610=new Map();for(const _0x4f7343 in _0x504ca7['diffData']){const _0x4dae91=_0x504ca7['diffData'][_0x4f7343]['attachChange'],_0x37642c=_0xef8248(_0x504ca7['diffData'][_0x4f7343]['attributesAfter'])||{},_0x3389f0=_0xe611e['_makeModelFromViewString'](_0x504ca7['diffData'][_0x4f7343]['insertions']);_0x3389f0['rootName']=_0x4f7343,_0x3389f0['_isAttached']=!_0x4dae91||_0x4dae91['isAttached'],_0x3389f0['isAttached']=()=>_0x3389f0['_isAttached'],this['_diffRoots']['set'](_0x4f7343,_0x3389f0),this['_diffRootsAttributes']['set'](_0x4f7343,_0x37642c);const _0xa8c7ff=this['_makeIdsRoot'](_0x3389f0,Number['NEGATIVE_INFINITY']);this['_idsRoots']['set'](_0x4f7343,_0xa8c7ff),_0x30d610['set'](_0x4f7343,_0x3389f0['isAttached']()?_0x37642c:{});for(const [_0x606192,_0x12cc8f]of _0x3389f0['markers']){if(!_0x606192['startsWith']('revision:'))continue;const _0x6051b4=_0x606192['split'](':')[0x2];for(const _0x4653e5 of _0x12cc8f['getWalker']({'singleCharacters':!0x0})){const _0x994e02=this['_getVidAttributeName'](_0x4653e5),_0x102f09=this['_revisionId']++,_0x55d5ac='elementEnd'==_0x4653e5['type']?_0x4653e5['previousPosition']['path']['slice'](0x0,-0x1):_0x4653e5['previousPosition']['path'];_0xa8c7ff['getNodeByPath'](_0x55d5ac)['_setAttribute'](_0x994e02,_0x102f09),this['_touched']['set'](_0x102f09,{'userId':_0x6051b4});}}for(const _0x28fe0e of this['editor']['model']['createRangeIn'](_0x3389f0)['getWalker']({'singleCharacters':!0x0})){const _0x30a5b0=this['_getVidAttributeName'](_0x28fe0e),_0x43c985='elementEnd'==_0x28fe0e['type']?_0x28fe0e['previousPosition']['path']['slice'](0x0,-0x1):_0x28fe0e['previousPosition']['path'],_0x14917c=_0xa8c7ff['getNodeByPath'](_0x43c985);_0x14917c['getAttribute'](_0x30a5b0)>0x0||_0x14917c['_setAttribute'](_0x30a5b0,_0x170f4b[_0x438569++]);}for(const [_0xa6082e,_0x5c0dce]of _0x3389f0['markers'])_0xa6082e['startsWith']('revision:')||this['_markers']['set'](_0xa6082e,_0x5c0dce);}const _0x37a4ff=P('$graveyard');this['_baseRoots']['set']('$graveyard',_0x37a4ff),this['_baseIdsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x37a4ff,0x1));const _0x11ec10=P('$graveyard');this['_diffRoots']['set']('$graveyard',_0x11ec10),this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x11ec10,0x1));const _0x42b23d=Array['from'](this['_diffRoots'])['map'](([_0x2ea2a3,_0x1561f7])=>[_0x2ea2a3,N(_0x1561f7)]);this['_saveMetaData'](this['_lastTo'],_0x42b23d,this['_markers'],_0x30d610);}['reInit'](){this['_reset'](),this['_lastFrom']=-0x1,this['_lastTo']=-0x1,this['_savedMetaData']['clear'](),this['init'](this['source']);}['_saveMetaData'](_0x57839a,_0x108a61,_0x1cf6df,_0x2714eb){const _0x46973a=new Map(_0x108a61),_0x8b432e=new Map(_0xef8248(_0x2714eb)),_0x9a479d=new Map();for(const [_0x336356,_0x47bdb1]of _0x1cf6df)_0x9a479d['set'](_0x336356,{'start':_0x47bdb1['start']['clone'](),'end':_0x47bdb1['end']['clone'](),'rootName':_0x47bdb1['root']['rootName']});this['_savedMetaData']['set'](_0x57839a,{'roots':_0x46973a,'markers':_0x9a479d,'rootsAttributes':_0x8b432e});}['_removeMetaData'](_0x345184){this['_savedMetaData']['delete'](_0x345184);}['_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'](_0x57cb41,_0x352c7b=null){let _0x280462=null;_0x57cb41['is']('documentFragment')||(_0x280462=new ut(_0x57cb41['name'],{'vid_start':null===_0x352c7b?this['_revisionId']++:_0x352c7b++}));const _0x125374=[];for(const _0x138a94 of _0x57cb41['getChildren']())if(_0x138a94['is']('element')){_0x125374['push'](this['_makeIdsRoot'](_0x138a94,_0x352c7b));const _0x3ddc64=_0x125374[_0x125374['length']-0x1];null!==_0x352c7b&&(_0x352c7b=_0x3ddc64['is']('element','$text')?_0x3ddc64['getAttribute']('vid')+0x1:_0x3ddc64['getAttribute']('vid_end')+0x1);}else{for(let _0xf0a50f=0x0;_0xf0a50f<_0x138a94['offsetSize'];_0xf0a50f++)_0x125374['push'](new ut('$text',{'vid':null===_0x352c7b?this['_revisionId']++:_0x352c7b++}));}if(_0x57cb41['is']('documentFragment')){const _0x198acf=P(_0x57cb41['rootName']);return _0x198acf['_insertChild'](0x0,_0x125374),_0x198acf;}return _0x280462['_setAttribute']('vid_end',null===_0x352c7b?this['_revisionId']++:_0x352c7b++),_0x280462['_insertChild'](0x0,_0x125374),_0x280462;}['_calculateMetaData'](_0x5f12c0,_0x19e755,_0x47633d){this['_reset']();const {roots:_0x3ca7d6,markers:_0x5ee841,rootsAttributes:_0x480870}=this['_savedMetaData']['get'](_0x5f12c0);this['_baseRoots']=new Map(_0x3ca7d6),this['_baseRootsAttributes']=new Map(_0xef8248(_0x480870));for(const [_0x3b00a3,_0x268224]of this['_baseRoots'])if('$graveyard'!==_0x3b00a3&&(this['_diffRoots']['set'](_0x3b00a3,N(_0x268224)),this['_diffRootsAttributes']=new Map(_0xef8248(_0x480870)),_0x47633d)){const _0x223951=this['_revisionId'];this['_idsRoots']['set'](_0x3b00a3,this['_makeIdsRoot'](_0x268224)),this['_baseIdsRoots']['set'](_0x3b00a3,this['_makeIdsRoot'](_0x268224,_0x223951));}this['_startingRevisionId']=this['_revisionId'],this['_diffRoots']['set']('$graveyard',N(this['_baseRoots']['get']('$graveyard'))),_0x47633d&&this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](this['_baseRoots']['get']('$graveyard')));for(const [_0x45afb0,_0x4dfe69]of _0x5ee841){const _0x205887=this['_baseRoots']['get'](_0x4dfe69['rootName']),_0x528d3c=this['_diffRoots']['get'](_0x4dfe69['rootName']),_0x56b2db=new lt(this['_fixPosition'](_0x4dfe69['start'],_0x205887),this['_fixPosition'](_0x4dfe69['end'],_0x205887)),_0xf0543c=this['_fixRange'](_0x56b2db,_0x528d3c);_0x205887['markers']['set'](_0x45afb0,_0x56b2db),this['_markers']['set'](_0x45afb0,_0xf0543c);}this['_applyOperations'](_0x5f12c0,_0x19e755,_0x47633d);}['_applyOperations'](_0xd94c6,_0x45e05c,_0x4658fa){for(const _0x55c5b6 of this['source']['getOperations'](_0xd94c6,_0x45e05c))this['_handleOperation'](_0x55c5b6,_0x4658fa);for(const _0x3b13d1 of this['_diffRoots']['values']())_0x3b13d1['markers']['clear']();for(const [_0x596da4,_0x53c6b0]of this['_markers']){this['_diffRoots']['get'](_0x53c6b0['root']['rootName'])['markers']['set'](_0x596da4,_0x53c6b0['clone']());}const _0x9ea0aa=new Map(),_0x5c088a=new Map();for(const [_0x2682d2,_0x4b4e5b]of this['_diffRoots'])_0x9ea0aa['set'](_0x2682d2,N(_0x4b4e5b)),_0x5c088a['set'](_0x2682d2,this['_diffRootsAttributes']['get'](_0x2682d2));this['_saveMetaData'](_0x45e05c,_0x9ea0aa,this['_markers'],_0x5c088a);}['_getPreviousFrom'](_0x573d54){const _0x2fb296=Array['from'](this['_savedMetaData']['keys']());_0x2fb296['sort']((_0x566275,_0x48c429)=>_0x566275-_0x48c429),_0x2fb296['reverse']();for(const _0x2beb13 of _0x2fb296)if(_0x2beb13<_0x573d54)return _0x2beb13;return Number['NEGATIVE_INFINITY'];}['_copyMarkers'](_0x397d29,_0x4136){const _0x4b5f37=Array['from'](_0x4136['markers'])['map'](([_0x55b615,_0x3fc7f0])=>[_0x55b615,this['_fixRange'](_0x3fc7f0,_0x397d29)]);_0x397d29['markers']=new Map(_0x4b5f37);}['_transformMarkers'](_0x49444b){for(const _0x4b74bd of this['_markers']['values']()){const _0x50768f=_0x4b74bd['getTransformedByOperation'](_0x49444b),_0x41224d=lt['_createFromRanges'](_0x50768f);_0x4b74bd['start']=_0x41224d['start'],_0x4b74bd['end']=_0x41224d['end'];}}['_handleOperation'](_0x48b803,_0x1ebc38){if('addRoot'!=_0x48b803['type']&&'detachRoot'!=_0x48b803['type']){if('insert'==_0x48b803['type']){const _0xd7e991=_0x48b803['position']['root']['rootName'];this['_diffRoots']['has'](_0xd7e991)||(this['_diffRoots']['set'](_0xd7e991,P(_0xd7e991,!0x0)),this['_diffRootsAttributes']['set'](_0xd7e991,{}),_0x1ebc38&&this['_idsRoots']['set'](_0xd7e991,P(_0xd7e991,!0x0)));}else{if('addRootAttribute'==_0x48b803['type']||'removeRootAttribute'==_0x48b803['type']||'changeRootAttribute'==_0x48b803['type'])return void this['_handleRootAttributeOperation'](_0x48b803);'marker'==_0x48b803['type']&&this['_handleMarkerOperation'](_0x48b803);}if('marker'!==_0x48b803['type']){const _0x411450=this['_cloneOperation'](_0x48b803,this['_diffRoots']);_0x411450['_execute'](),this['_transformMarkers'](_0x411450);}if(_0x1ebc38)switch(_0x48b803['type']){case'insert':this['_handleInsertOperation'](_0x48b803);break;case'move':case'remove':case'reinsert':this['_handleMoveOperation'](_0x48b803);break;case'merge':this['_handleMergeOperation'](_0x48b803);break;case'split':this['_handleSplitOperation'](_0x48b803);}}else this['_handleRootOperation'](_0x48b803,_0x1ebc38);}['_cloneOperation'](_0x15178c,_0x2f741d){const _0x8a55a6=_0x15178c['clone']();return _0x8a55a6['_authorId']=_0x15178c['_authorId'],this['_fixOperation'](_0x8a55a6,_0x2f741d),_0x8a55a6;}['_getBaseVids'](_0x42fec6){return _0x42fec6['map'](_0x2d8eb1=>{const _0x3a6f13=this['_getVidAttributeName'](_0x2d8eb1);return Number(_0x2d8eb1['item']['getAttribute'](_0x3a6f13));});}['_generateTape'](_0x431284,_0x586680){if(_0x431284['is']('element','$text'))_0x586680['push']({'item':_0x431284,'type':'text'});else{_0x431284['is']('element')&&_0x586680['push']({'item':_0x431284,'type':'elementStart'});for(const _0x4d3cc0 of _0x431284['getChildren']())this['_generateTape'](_0x4d3cc0,_0x586680);_0x431284['is']('element')&&_0x586680['push']({'item':_0x431284,'type':'elementEnd'});}return _0x586680;}['_getState'](){const _0x491740=new Map(this['_touched']),_0x77994b=new Map(_0x491740),_0x1867d8=new Map(),_0x3cfb08={'insertions':{},'deletions':{}},_0x1587f7={'insertions':{},'deletions':{}},_0x3b3c07=new Map(),_0x219a8e=new Set([...this['_baseRoots']['keys'](),...this['_diffRoots']['keys']()]);_0x219a8e['delete']('$graveyard');for(const _0x58b239 of _0x219a8e){const _0x4f6da1=this['_diffRoots']['get'](_0x58b239)||P(_0x58b239,!0x1),_0x3adccf=this['_baseRoots']['get'](_0x58b239)||P(_0x58b239,!0x1);_0x4f6da1['isAttached']()||_0x3adccf['isAttached']()?(_0x3cfb08['insertions'][_0x58b239]=N(_0x4f6da1),_0x3cfb08['deletions'][_0x58b239]=N(_0x3adccf),this['_copyMarkers'](_0x3cfb08['deletions'][_0x58b239],_0x3adccf),this['_copyMarkers'](_0x3cfb08['insertions'][_0x58b239],_0x4f6da1),_0x1587f7['insertions'][_0x58b239]=this['_generateTape'](this['_idsRoots']['get'](_0x58b239),[]),_0x1587f7['deletions'][_0x58b239]=this['_generateTape'](this['_baseIdsRoots']['get'](_0x58b239)||P(_0x58b239,!0x1),[])):_0x219a8e['delete'](_0x58b239);}for(const _0x176b43 of _0x219a8e){const _0x1e614d=_0x1587f7['insertions'][_0x176b43];for(const _0x371c17 of _0x1e614d){const _0x3c9e54=this['_getVidAttributeName'](_0x371c17),_0x197efd=_0x371c17['item']['getAttribute'](_0x3c9e54);_0x77994b['delete'](_0x197efd),_0x197efd>=this['_startingRevisionId']&&_0x1867d8['set'](_0x197efd,_0x491740['get'](_0x197efd));}}for(const _0x213ade of _0x219a8e){const _0x3c744a=_0x1587f7['insertions'][_0x213ade],_0x410b30=this['_getBaseVids'](_0x1587f7['deletions'][_0x213ade]);let _0x19b2ee=0x0;for(const _0x5628be of _0x3c744a){const _0xaf0abd=this['_getVidAttributeName'](_0x5628be),_0x354815=_0x5628be['item']['getAttribute'](_0xaf0abd);if(!_0x1867d8['has'](_0x354815)&&!_0x3b3c07['has'](_0x354815)){if(_0x77994b['has'](_0x354815))_0x19b2ee++;else{if(_0x354815!=_0x410b30[_0x19b2ee]){const _0x46c860=_0x491740['get'](_0x354815)||_0x491740['get'](_0x410b30[_0x19b2ee]);for(;_0x354815!=_0x410b30[_0x19b2ee];)_0x77994b['has'](_0x410b30[_0x19b2ee])||(_0x3b3c07['set'](_0x410b30[_0x19b2ee],_0x46c860),_0x491740['set'](_0x410b30[_0x19b2ee],_0x46c860)),_0x19b2ee++;}_0x19b2ee++;}}}}for(const _0x30d045 of _0x219a8e){const _0x3e4036=_0x1587f7['insertions'][_0x30d045];for(const _0x58132f of _0x3e4036){const _0xa61e24=this['_getVidAttributeName'](_0x58132f),_0x57447a=_0x58132f['item']['getAttribute'](_0xa61e24);if(_0x3b3c07['has'](_0x57447a)){const _0x21d5fc=_0x3b3c07['get'](_0x57447a);_0x77994b['has'](_0x57447a)||_0x77994b['set'](_0x57447a,{..._0x21d5fc}),_0x1867d8['set'](_0x57447a,{..._0x21d5fc});}}}for(const _0xae6f7a of _0x77994b['keys']())_0xae6f7a>=this['_startingRevisionId']&&_0x77994b['delete'](_0xae6f7a);const _0x520059=new Map();for(const _0x2433a9 of _0x219a8e){let _0xeb25fc=_0x1587f7['insertions'][_0x2433a9];for(const _0x46810e of _0xeb25fc)if(_0x46810e['item']['is']('element','tableCell')){const _0x16ef8d=this['_getVidAttributeName'](_0x46810e),_0x4a381a=_0x46810e['item']['getAttribute'](_0x16ef8d);if(_0x1867d8['has'](_0x4a381a)){const _0x3fa0f0=_0x46810e['item']['parent']['parent']['getAttribute']('vid_start'),_0x186f38=_0x520059['get'](_0x3fa0f0)||new Set();_0x186f38['add'](_0x1867d8['get'](_0x4a381a)['userId']),_0x520059['set'](_0x3fa0f0,_0x186f38);}}_0xeb25fc=_0x1587f7['deletions'][_0x2433a9];for(const _0x415f36 of _0xeb25fc)if(_0x415f36['item']['is']('element','tableCell')){const _0x84fba6=this['_getVidAttributeName'](_0x415f36),_0x4c55cb=_0x415f36['item']['getAttribute'](_0x84fba6);if(_0x77994b['has'](_0x4c55cb)){const _0x496203=_0x415f36['item']['parent']['parent']['getAttribute']('vid_start'),_0x46d5ca=_0x520059['get'](_0x496203)||new Set();_0x46d5ca['add'](_0x77994b['get'](_0x4c55cb)['userId']),_0x520059['set'](_0x496203,_0x46d5ca);}}for(const _0x524ef4 of _0x520059['keys']())(_0x1867d8['has'](_0x524ef4)||_0x77994b['has'](_0x524ef4))&&_0x520059['delete'](_0x524ef4);}for(const _0x25d8a3 of _0x219a8e){const _0x4975a4=_0x1587f7['insertions'][_0x25d8a3];let _0xd1ee52=null,_0x527eff=null;for(const _0xac7d02 of _0x4975a4){const _0x22dc49=this['_getVidAttributeName'](_0xac7d02),_0x291361=_0xac7d02['item']['getAttribute'](_0x22dc49),_0x3ae707=_0x520059['get'](_0x291361);_0x3ae707&&'elementStart'==_0xac7d02['type']&&(_0xd1ee52=Array['from'](_0x3ae707)[0x0],_0x527eff=_0xac7d02['item']['getAttribute']('vid_end')),_0xd1ee52&&(_0x77994b['set'](_0x291361,{'userId':_0xd1ee52}),_0x1867d8['set'](_0x291361,{'userId':_0xd1ee52})),_0x291361==_0x527eff&&(_0xd1ee52=null,_0x527eff=null);}}const _0x18c372={},_0x179472=new Set();for(const _0x359a72 of _0x219a8e){const _0x6f1caa=_0x3cfb08['deletions'][_0x359a72],_0x43e654=_0x3cfb08['insertions'][_0x359a72];for(const {userId:_0x3639ad}of this['_touchedMarkers']['values']())null!==_0x3639ad&&_0x179472['add'](_0x3639ad);for(const {userId:_0x54cf71}of this['_touchedRoots']['values']())null!==_0x54cf71&&_0x179472['add'](_0x54cf71);this['_markChanges'](_0x43e654,_0x1587f7['insertions'][_0x359a72],_0x1867d8,'insertion',_0x179472),this['_markChanges'](_0x6f1caa,_0x1587f7['deletions'][_0x359a72],_0x77994b,'deletion',_0x179472),_0x18c372[_0x359a72]={'insertions':this['_prepareViewToSave'](_0x43e654),'deletions':this['_prepareViewToSave'](_0x6f1caa),'attachChange':this['_touchedRoots']['get'](_0x359a72)||null,'attributesBefore':_0xef8248(this['_baseRootsAttributes']['get'](_0x359a72))||{},'attributesAfter':_0xef8248(this['_diffRootsAttributes']['get'](_0x359a72))};}return{'diffData':_0x18c372,'authorsIds':Array['from'](_0x179472)};}['_processRootBeforeSave'](_0xd8d67c){for(const [,_0x4b6383]of _0xd8d67c['markers']){const _0xfdfe94=_0x4b6383['start']['getAncestors']()['filter'](_0x38db15=>'tableCell'==_0x38db15['name']);for(const _0x4051b3 of _0xfdfe94)0x1==_0x4051b3['childCount']&&_0x4051b3['getChild'](0x0)['is']('element','paragraph')&&_0x4051b3['getChild'](0x0)['_setAttribute']('keepParagraph',!0x0);}}['_prepareViewToSave'](_0x411cf8){this['_processRootBeforeSave'](_0x411cf8);const _0x148f19=this['editor']['data']['toView'](_0x411cf8,{}),_0xfde940=Array['from'](_0x148f19['getChildren']())['map'](_0x315c37=>this['_getViewJson'](_0x315c37));return JSON['stringify'](_0xfde940);}['_getViewJson'](_0x15b66e){if(_0x15b66e['is']('$text'))return _0x15b66e['data'];{const _0x215ab7=this['editor']['plugins']['get']('RevisionHistoryUtils'),_0x2db136=_0x15b66e,_0x405142=this['editor']['data']['htmlProcessor']['domConverter'],_0x141780={'type':_0x215ab7['_getTypeCharForViewElement'](_0x2db136),'name':_0x2db136['name'],'attributes':Array['from'](_0x2db136['getAttributes']()),'children':Array['from'](_0x2db136['getChildren']())['map'](_0x30a883=>this['_getViewJson'](_0x30a883))};if(_0x15b66e['is']('uiElement')&&'$comment'!=_0x15b66e['name']){const _0x6fdb31=_0x15b66e['render'](_0x405142['domDocument'],_0x405142);_0x141780['children']['push'](_0x6fdb31['outerHTML']);}else{if(_0x15b66e['is']('rawElement')){const _0x5f5965=_0x405142['domDocument']['createElement'](_0x2db136['name']);_0x15b66e['render'](_0x5f5965,_0x405142),_0x141780['children']['push'](_0x5f5965['innerHTML']);}}const _0x34c188=Array['from'](_0x2db136['getCustomProperties']());_0x34c188['length']>0x0&&(_0x141780['customProperties']=_0x34c188);const _0x33524d=_0x2db136['getFillerOffset']();return null!==_0x33524d&&(_0x141780['fillerOffset']=_0x33524d),_0x141780;}}['_markChanges'](_0x450493,_0x196dd2,_0x4986e5,_0x10ff94,_0x5f4777){let _0x20e119=null,_0x39662=null,_0x121bbf=0x0;const _0x24c20c=this['editor']['model'];for(let _0x4ee3a5=0x0;_0x4ee3a5<_0x196dd2['length'];_0x4ee3a5++){const _0x19e3de=this['_getVidAttributeName'](_0x196dd2[_0x4ee3a5]),_0x46acd9=_0x196dd2[_0x4ee3a5]['item']['getAttribute'](_0x19e3de),_0x57dda5=_0x4986e5['get'](_0x46acd9),_0x6a2ddd=_0x4ee3a5==_0x196dd2['length']-0x1;(!_0x20e119&&_0x57dda5&&(_0x20e119=_0x57dda5,_0x39662=_0x196dd2[_0x4ee3a5]),_0x20e119&&(!_0x57dda5||_0x57dda5['userId']!=_0x20e119['userId']))&&(_0x1b5432(_0x57dda5,F(_0x39662,_0x450493,_0x24c20c),F(_0x196dd2[_0x4ee3a5],_0x450493,_0x24c20c)),_0x20e119=_0x57dda5||null,_0x39662=_0x57dda5?_0x196dd2[_0x4ee3a5]:null),_0x20e119&&_0x6a2ddd&&_0x1b5432(_0x57dda5,F(_0x39662,_0x450493,_0x24c20c),B(_0x196dd2[_0x4ee3a5],_0x450493,_0x24c20c));}function _0x1b5432(_0x4f99f3,_0x32481c,_0x49e434){const _0x5ef631=_0x20e119['userId'],_0xd4fe80='revision:'+_0x10ff94+':'+_0x5ef631+':'+_0x121bbf++,_0x24dd7b=_0x24c20c['createRange'](_0x32481c,_0x49e434);_0x450493['markers']['set'](_0xd4fe80,_0x24dd7b),null!==_0x5ef631&&_0x5f4777['add'](_0x5ef631);}}['_getVidAttributeName'](_0x4ba2e7){switch(_0x4ba2e7['type']){case'elementStart':return'vid_start';case'elementEnd':return'vid_end';default:return'vid';}}['_fixOperation'](_0x4571cb,_0xf31ff8){_0x4571cb['baseVersion']=null;for(const _0x16bb55 in _0x4571cb){const _0x5c7103=_0x4571cb[_0x16bb55];if(_0x5c7103 instanceof ft){const _0x19eba2=_0xf31ff8['get'](_0x5c7103['root']['rootName']);_0x4571cb[_0x16bb55]=this['_fixPosition'](_0x5c7103,_0x19eba2);}if(_0x5c7103 instanceof lt){const _0x21ab7a=_0xf31ff8['get'](_0x5c7103['root']['rootName']);_0x4571cb[_0x16bb55]=this['_fixRange'](_0x5c7103,_0x21ab7a);}'root'===_0x16bb55&&(_0x4571cb['root']=_0xf31ff8['get'](_0x4571cb['root']['rootName']));}}['_fixRange'](_0x4ee086,_0x4a279e){return this['editor']['model']['createRange'](this['_fixPosition'](_0x4ee086['start'],_0x4a279e),this['_fixPosition'](_0x4ee086['end'],_0x4a279e));}['_fixPosition'](_0x148332,_0x2e16e7){return this['editor']['model']['createPositionFromPath'](_0x2e16e7,_0x148332['path'],_0x148332['stickiness']);}['_handleInsertOperation'](_0x3405c){const _0x14de85=this['_idsRoots']['get'](_0x3405c['position']['root']['rootName']),_0x2b8c05=this['_fixPosition'](_0x3405c['position'],_0x14de85),_0x1b367e=null===_0x3405c['_authorId']?null:_0x3405c['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x31a5e9=_0x2b8c05['parent'],_0x21d253=this['_revisionId'],_0x35334d=[];for(const _0x35b479 of _0x3405c['nodes'])if(_0x35b479['is']('element'))_0x35334d['push'](this['_makeIdsRoot'](_0x35b479));else{for(let _0x284186=0x0;_0x284186<_0x35b479['offsetSize'];_0x284186++)_0x35334d['push'](new ut('$text',{'vid':this['_revisionId']++}));}const _0x5ab7b9=this['_revisionId'];for(let _0x46fb01=_0x21d253;_0x46fb01<_0x5ab7b9;_0x46fb01++)this['_touched']['set'](_0x46fb01,{'userId':_0x1b367e});_0x31a5e9['_insertChild'](_0x2b8c05['offset'],_0x35334d);}['_handleMoveOperation'](_0x1cdf9d){(_0x1cdf9d=this['_cloneOperation'](_0x1cdf9d,this['_idsRoots']))['_execute']();const _0x5a70cf=null===_0x1cdf9d['_authorId']?null:_0x1cdf9d['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x55a307=_0x1cdf9d['getMovedRangeStart'](),_0xfd4f0d=_0x55a307['parent'],_0x444a9d=_0x55a307['offset'];!function _0x87167f(_0x37523f,_0x2cf46e,_0x3f9aca,_0x843e03){for(let _0x451575=_0x3f9aca;_0x451575<_0x843e03;_0x451575++){const _0x15f9c6=_0x2cf46e['getChild'](_0x451575);_0x15f9c6['is']('element','$text')?_0x37523f['set'](_0x15f9c6['getAttribute']('vid'),{'userId':_0x5a70cf}):(_0x37523f['set'](_0x15f9c6['getAttribute']('vid_start'),{'userId':_0x5a70cf}),_0x87167f(_0x37523f,_0x15f9c6,0x0,_0x15f9c6['childCount']),_0x37523f['set'](_0x15f9c6['getAttribute']('vid_end'),{'userId':_0x5a70cf}));}}(this['_touched'],_0xfd4f0d,_0x444a9d,_0x444a9d+_0x1cdf9d['howMany']);}['_handleMergeOperation'](_0x5c1f84){const _0xed5094=null===(_0x5c1f84=this['_cloneOperation'](_0x5c1f84,this['_idsRoots']))['_authorId']?null:_0x5c1f84['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x2489ca=_0x5c1f84['targetPosition']['parent'],_0x531790=_0x5c1f84['sourcePosition']['parent'],_0x5a3ca4=_0x2489ca['getAttribute']('vid_end'),_0x4a0e12=_0x531790['getAttribute']('vid_start');_0x2489ca['_setAttribute']('vid_end',_0x531790['getAttribute']('vid_end')),_0x531790['_setAttribute']('vid_end',_0x5a3ca4),this['_touched']['set'](_0x4a0e12,{'userId':_0xed5094}),this['_touched']['set'](_0x5a3ca4,{'userId':_0xed5094}),_0x5c1f84['_execute']();}['_handleSplitOperation'](_0x2199ca){const _0x1c30f4=null===(_0x2199ca=this['_cloneOperation'](_0x2199ca,this['_idsRoots']))['_authorId']?null:_0x2199ca['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x33a0cc=_0x2199ca['graveyardPosition'],_0x588c69=_0x2199ca['splitPosition']['parent'];_0x2199ca['_execute']();const _0x44851e=_0x588c69['getAttribute']('vid_end'),_0xf74706=_0x2199ca['insertionPosition']['nodeAfter'];if(_0x33a0cc){const _0x1bc599=_0xf74706['getAttribute']('vid_end'),_0x463e92=_0x588c69['getAttribute']('vid_end');_0x588c69['_setAttribute']('vid_end',_0x1bc599),_0xf74706['_setAttribute']('vid_end',_0x463e92),this['_touched']['set'](_0x588c69['getAttribute']('vid_end'),{'userId':_0x1c30f4}),this['_touched']['set'](_0xf74706['getAttribute']('vid_start'),{'userId':_0x1c30f4});}else{const _0x4303b6=this['_revisionId']++,_0x2028c4=this['_revisionId']++;_0x588c69['_setAttribute']('vid_end',_0x4303b6),_0xf74706['_setAttribute']('vid_start',_0x2028c4),_0xf74706['_setAttribute']('vid_end',_0x44851e),this['_touched']['set'](_0x4303b6,{'userId':_0x1c30f4}),this['_touched']['set'](_0x2028c4,{'userId':_0x1c30f4});}}['_handleMarkerOperation'](_0x4d9046){if(!_0x4d9046['affectsData'])return;const _0x1c4d66=(_0x4d9046=this['_cloneOperation'](_0x4d9046,this['_diffRoots']))['oldRange']?_0x4d9046['oldRange']['root']:null,_0x53214f=_0x4d9046['newRange']?_0x4d9046['newRange']['root']:null;_0x1c4d66&&this['_markers']['delete'](_0x4d9046['name']),_0x53214f&&this['_markers']['set'](_0x4d9046['name'],_0x4d9046['newRange']['clone']());const _0x58087e=null===_0x4d9046['_authorId']?null:_0x4d9046['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x492a3a=_0x4d9046['name'];if(!this['_touchedMarkers']['has'](_0x492a3a))return void this['_touchedMarkers']['set'](_0x492a3a,{'range':_0x4d9046['oldRange'],'userId':_0x58087e});const _0x195921=this['_touchedMarkers']['get'](_0x492a3a),_0x29b05a=_0x195921['range'],_0x5e3f97=_0x4d9046['newRange'];null==_0x29b05a&&null==_0x5e3f97||_0x29b05a&&_0x5e3f97&&_0x29b05a['isEqual'](_0x5e3f97)?this['_touchedMarkers']['delete'](_0x4d9046['name']):_0x195921['userId']=_0x58087e;}['_handleRootOperation'](_0x2cdc87,_0x55cc11){this['_diffRoots']['has'](_0x2cdc87['rootName'])?this['_diffRoots']['get'](_0x2cdc87['rootName'])['_isAttached']=_0x2cdc87['isAdd']:(this['_diffRoots']['set'](_0x2cdc87['rootName'],P(_0x2cdc87['rootName'],!0x0)),this['_diffRootsAttributes']['set'](_0x2cdc87['rootName'],{}),_0x55cc11&&this['_idsRoots']['set'](_0x2cdc87['rootName'],P(_0x2cdc87['rootName'],!0x0)));const _0x5488da=null===_0x2cdc87['_authorId']?null:_0x2cdc87['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x18b59f=this['_touchedRoots']['get'](_0x2cdc87['rootName']);_0x18b59f&&_0x18b59f['userId']===_0x5488da?this['_touchedRoots']['delete'](_0x2cdc87['rootName']):this['_touchedRoots']['set'](_0x2cdc87['rootName'],{'userId':_0x5488da,'isAttached':_0x2cdc87['isAdd']});}['_handleRootAttributeOperation'](_0x3ed92d){const _0x1b3959=this['_diffRootsAttributes']['get'](_0x3ed92d['root']['rootName']);null===_0x3ed92d['newValue']?delete _0x1b3959[_0x3ed92d['key']]:_0x1b3959[_0x3ed92d['key']]=_0x3ed92d['newValue'];}}function N(_0x288641){const _0x188280=P(_0x288641['rootName'],_0x288641['isAttached']());for(const _0x48776c of _0x288641['getChildren']()){const _0x272068=_0x48776c['_clone'](!0x0);_0x188280['_appendChild'](_0x272068);}return _0x188280;}function P(_0x5216a1,_0x4b6c2f=!0x0){const _0x513031=new vt();return _0x513031['rootName']=_0x5216a1,_0x513031['_isAttached']=_0x4b6c2f,_0x513031['isAttached']=()=>_0x513031['_isAttached'],_0x513031;}function F(_0x44f785,_0x39f4e2,_0x2aca23){const _0x645263='elementEnd'==_0x44f785['type']?_0x2aca23['createPositionAt'](_0x44f785['item'],'end'):_0x2aca23['createPositionBefore'](_0x44f785['item']);return _0x2aca23['createPositionFromPath'](_0x39f4e2,_0x645263['path'],_0x645263['stickiness']);}function B(_0x8f89b9,_0x25f263,_0x312224){const _0x3a8009='elementStart'==_0x8f89b9['type']?_0x312224['createPositionAt'](_0x8f89b9['item'],0x0):_0x312224['createPositionAfter'](_0x8f89b9['item']);return _0x312224['createPositionFromPath'](_0x25f263,_0x3a8009['path'],_0x3a8009['stickiness']);}class hs extends ts{['focusTracker'];['keystrokes'];['revisionNameInputView'];constructor(_0x210791,_0x19a2c8){super(_0x210791),this['focusTracker']=new _0xe43251(),this['keystrokes']=new _0x24669c(),this['set']('revisionNameInputValue',''),this['revisionNameInputView']=this['_createRevisionNameInput'](_0x19a2c8),this['setTemplate']({'tag':'form','attributes':{'class':['ck','ck-revision-history-save-revision-form','ck-responsive-form'],'tabindex':'-1'},'children':[this['revisionNameInputView']]}),_0x2e45dd(this);}['render'](){super['render'](),_0x2a1594({'view':this}),this['focusTracker']['add'](this['revisionNameInputView']['element']),this['keystrokes']['listenTo'](this['element']);const _0x3bad85=_0x137d54=>_0x137d54['stopPropagation']();this['keystrokes']['set']('arrowright',_0x3bad85),this['keystrokes']['set']('arrowleft',_0x3bad85),this['keystrokes']['set']('arrowup',_0x3bad85),this['keystrokes']['set']('arrowdown',_0x3bad85);}['focus'](){this['revisionNameInputView']['focus']();}get['revisionName'](){return this['revisionNameInputView']['fieldView']['element']['value']['trim']();}set['revisionName'](_0x1cd8d6){this['revisionNameInputView']['fieldView']['element']['value']=_0x1cd8d6['trim']();}['reset'](){this['revisionNameInputView']['fieldView']['element']['value']='',this['revisionNameInputView']['errorText']=null;}['_createRevisionNameInput'](_0x48722e){const _0x58f361=new _0x4e0cda(this['locale'],_0x171e75),_0x92b15b=_0x58f361['fieldView'];_0x92b15b['extendTemplate']({'attributes':{'maxlength':'220'}});let _0x4b5cea=g(this['locale'],'Name\x20of\x20the\x20revision');return!_0x48722e&&(_0x4b5cea+='\x20('+g(this['locale'],'optional')+')'),(_0x58f361['label']=_0x4b5cea,_0x92b15b['on']('input',()=>{this['revisionNameInputValue']=_0x92b15b['element']['value']['trim']();}),_0x58f361);}}class f extends _0x45698e{static get['pluginName'](){return'RevisionHistoryUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[u];}['_saveRevisionFormView'];['init'](){const _0xd3bfa=this['editor'],_0x5c1737=_0xd3bfa['plugins']['get']('RevisionTracker');_0xd3bfa['ui']['componentFactory']['add']('revisionHistory',_0x3dbf8a=>{const _0x1c4014=_0x35f2ce(_0x3dbf8a),_0x4a9717=_0x1c4014['panelView']['children'],_0x279c81=new _0x275f78(_0x3dbf8a),_0x238cb9=new _0x351a8e(_0x3dbf8a),_0x12d74e=new te(_0x3dbf8a),_0x204005=new _0x351a8e(_0x3dbf8a),_0x4b44d4=new te(_0x3dbf8a);return _0x1c4014['bind']('isEnabled')['to'](_0x5c1737,'isReady',_0x5c1737,'isEnabled',_0xd3bfa,'isReadOnly',(_0x1e4de6,_0x20d60c,_0x1a1bc5)=>_0x1e4de6&&_0x20d60c&&!_0x1a1bc5),_0x1c4014['buttonView']['set']({'icon':_0x408408,'label':g(_0x3dbf8a,'Revision\x20history'),'tooltip':!0x0}),_0x12d74e['set']({'label':g(_0x3dbf8a,'Save\x20current\x20revision'),'withText':!0x0,'role':'menuitem'}),_0x12d74e['bind']('isEnabled')['to'](_0x5c1737,'isReady',_0x5c1737,'isEnabled',_0xd3bfa,'isReadOnly',(_0x3a5c9f,_0x24630c,_0x375962)=>_0x3a5c9f&&_0x24630c&&!_0x375962),_0x12d74e['on']('execute',()=>this['_showDialog']()),_0x4b44d4['set']({'label':g(_0x3dbf8a,'Open\x20revision\x20history'),'withText':!0x0,'role':'menuitem'}),_0x4b44d4['bind']('isEnabled')['to'](_0x5c1737,'isReady',_0xd3bfa,'isReadOnly',(_0x4cbfac,_0x22c6e5)=>_0x4cbfac&&!_0x22c6e5),_0x4b44d4['on']('execute',()=>{_0xd3bfa['config']['get']('revisionHistory')['showRevisionViewerCallback'](),_0x1c4014['isOpen']=!0x1,_0xd3bfa['editing']['view']['focus']();}),_0x238cb9['children']['add'](_0x12d74e),_0x204005['children']['add'](_0x4b44d4),_0x279c81['role']='menu',_0x279c81['items']['addMany']([_0x238cb9,_0x204005]),_0x4a9717['add'](_0x279c81),_0x1c4014;}),_0xd3bfa['ui']['componentFactory']['add']('menuBar:revisionHistory',()=>this['_registerMenuComponent']());}['_registerMenuComponent'](){const _0x3d881d=this['editor'],_0x2e33d8=_0x3d881d['locale'],_0x2a3cd8=new _0x30109a(_0x2e33d8),_0x362021=new _0x4d0740(_0x2e33d8);_0x2a3cd8['buttonView']['set']({'icon':_0x408408,'label':g(_0x2e33d8,'Revision\x20history')});const _0xcd783=new _0x10d427(_0x2e33d8,_0x2a3cd8),_0x307a41=new _0x4466de(_0x2e33d8);_0x307a41['set']({'label':g(_0x2e33d8,'Save\x20current\x20revision')}),_0x307a41['delegate']('execute')['to'](_0x2a3cd8),_0x307a41['on']('execute',()=>{this['_showDialog']();}),_0xcd783['children']['add'](_0x307a41),_0x362021['items']['add'](_0xcd783);const _0x474413=new _0x10d427(_0x2e33d8,_0x2a3cd8),_0x5bf4d6=new _0x4466de(_0x2e33d8);return _0x5bf4d6['set']({'label':g(_0x2e33d8,'Open\x20revision\x20history')}),_0x5bf4d6['delegate']('execute')['to'](_0x2a3cd8),_0x5bf4d6['on']('execute',()=>{_0x3d881d['config']['get']('revisionHistory')['showRevisionViewerCallback']();}),_0x474413['children']['add'](_0x5bf4d6),_0x362021['items']['add'](_0x474413),_0x2a3cd8['panelView']['children']['add'](_0x362021),_0x2a3cd8;}['_showDialog'](){const _0x117ad1=this['editor'],_0x2a5992=_0x117ad1['locale'],_0x2e19ce=_0x117ad1['plugins']['get']('Dialog'),_0x6c656b=_0x117ad1['plugins']['get']('RevisionTracker');function _0x15c7f8(_0x9fb4c1){_0x117ad1['config']['get']('revisionHistory.requireRevisionName')&&''===_0x9fb4c1['revisionName']?_0x9fb4c1['revisionNameInputView']['errorText']=g(_0x2a5992,'The\x20revision\x20name\x20cannot\x20be\x20empty.'):(_0x117ad1['plugins']['get'](u)['saveRevision']({'name':_0x9fb4c1['revisionName']}),_0x2e19ce['hide']());}this['_saveRevisionFormView']||(this['_createSaveRevisionFormView'](),this['_saveRevisionFormView']['on']('submit',()=>_0x15c7f8(this['_saveRevisionFormView']))),this['_saveRevisionFormView']['reset'](),_0x2e19ce['show']({'id':'revisionSave','title':g(_0x2a5992,'Save\x20current\x20revision'),'isModal':!0x0,'content':this['_saveRevisionFormView'],'actionButtons':[{'label':g(_0x117ad1['locale'],'Cancel'),'withText':!0x0,'onExecute':()=>_0x2e19ce['hide']()},{'label':g(_0x117ad1['locale'],'Accept'),'class':'ck-button-action','withText':!0x0,'onCreate'(_0x40cfc3){_0x40cfc3['bind']('isEnabled')['to'](_0x6c656b,'isReady',_0x6c656b,'isEnabled',_0x117ad1,'isReadOnly',(_0x2239bc,_0x5a04ab,_0x3d38e7)=>_0x2239bc&&_0x5a04ab&&!_0x3d38e7);},'onExecute':()=>_0x15c7f8(this['_saveRevisionFormView'])}]});}['_createSaveRevisionFormView'](){const _0xbaa1f2=this['editor'],_0x494aff=_0xbaa1f2['locale'];this['_saveRevisionFormView']=new hs(_0x494aff,_0xbaa1f2['config']['get']('revisionHistory.requireRevisionName')),this['_saveRevisionFormView']['render']();}}class Q extends ts{['changeId'];['_model'];constructor(_0x3173c9,_0x403309){super(_0x3173c9),this['_model']=_0x403309,this['changeId']=_0x403309['id'];const _0x3237f8=this['bindTemplate'],_0x27a5a9=g(_0x3173c9,_0x403309['data']['isSuggestion']?'Suggested\x20by':'add'==_0x403309['type']?'Added\x20by':'Removed\x20by');this['set']('type',_0x403309['type']),this['setTemplate']({'tag':'div','attributes':{'class':['ck-annotation','ck-revision-change',_0x3237f8['to']('type',_0x482cec=>'ck-revision-change__'+_0x482cec)],'tabindex':-0x1},'children':[{'tag':'span','children':[{'tag':'span','attributes':{'class':['ck-revision-change__label']},'children':[{'text':_0x27a5a9}]},{'text':'\x20'+_0x403309['author']['name']}]}]});}['focus'](){this['element']['focus']();}}class r extends/* #__PURE__ -- @preserve */
|
|
25
|
-
_0x5e88da(){['id'];['author'];['type'];['data'];['rootName'];constructor(_0x2c57e6){super(),this['id']=_0x2c57e6['id']||_0x2bf2c8(),this['author']=_0x2c57e6['author'],this['type']=_0x2c57e6['type'],this['data']=_0x2c57e6['data']||{},this['rootName']=_0x2c57e6['rootName'],this['set']('createdAt',_0x2c57e6['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(_0x32dd84,_0x1664ea){this['newRevisionId']=_0x32dd84,this['oldRevisionId']=_0x1664ea,this['changes']=new _0x25586d();}['_setChanges'](_0x52785b){for(const _0x1fe7aa of _0x52785b)this['changes']['add'](_0x1fe7aa);}}class m extends _0x45698e{['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[_0x30649f,_0x3f6ce7,I,V];}constructor(_0x20164f){super(_0x20164f),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',(_0x3343b2,_0x4d0e94,_0x1dde26)=>{this['activeChange']=null,this['activeView']=null,this['editor']['editing']['view']['change'](_0x38a004=>{for(const _0x25f371 of this['editor']['editing']['view']['document']['roots'])_0x1dde26?_0x38a004['removeClass']('ck-editor__editable__overlay',_0x25f371):_0x38a004['addClass']('ck-editor__editable__overlay',_0x25f371);});}),this['bind']('isNavigationMode')['to'](this,'activeChange',_0x50f246=>null!==_0x50f246),this['bind']('currentChangeNumber')['to'](this,'isReady',this,'diff',this,'activeChange',(_0x2f01c3,_0x38089e,_0x598fe7)=>_0x2f01c3&&_0x598fe7?_0x38089e['changes']['getIndex'](_0x598fe7):0x0),this['bind']('numberOfChanges')['to'](this,'isReady',this,'diff',(_0x259043,_0x3c15a4)=>_0x259043?_0x3c15a4['changes']['length']:0x0),this['_changeView']=null,this['_changeIdToChange']=new Map(),this['_balloon']=this['editor']['plugins']['get'](_0x3f6ce7);}['init'](){const _0x1b987a=this['editor'],_0x4f0a24=new wt(_0x1b987a,{'direction':'backward'}),_0x51c42a=new wt(_0x1b987a,{'direction':'forward'});(_0x1b987a['commands']['add']('showPreviousChange',_0x4f0a24),_0x1b987a['commands']['add']('showNextChange',_0x51c42a),_0x1b987a['commands']['add']('restoreRevision',new mt(_0x1b987a)),this['on']('change:numberOfChanges',()=>{_0x4f0a24['refresh'](),_0x51c42a['refresh']();}),this['_setConversion'](),this['_initInteractions'](),_0x1b987a['enableReadOnlyMode']('revision-viewer'),_0x1b987a['plugins']['has']('WidgetToolbarRepository'))&&_0x1b987a['plugins']['get']('WidgetToolbarRepository')['forceDisabled']('revision-viewer');}async['getRevisionDocumentData'](_0x757925){return await this['_utils']['loadRevisionData'](_0x757925,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x757925);}async['getRevisionRootsAttributes'](_0x1e703c){return await this['_utils']['loadRevisionData'](_0x1e703c,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x1e703c);}async['compare'](_0x493460,_0x29b824,_0x4b08c2=!0x1){if(!this['isEnabled'])return;const _0x56e63d=this['diff'],_0x3b21b6=this['repository'],_0xc6649e='string'==typeof _0x493460?_0x3b21b6['getRevision'](_0x493460):_0x493460,_0x158aae='string'==typeof _0x29b824?_0x3b21b6['getRevision'](_0x29b824):_0x29b824,_0x3843ad=_0xc6649e['id'],_0x3d904b=_0x158aae?_0x158aae['id']:null;if(!_0x4b08c2&&this['diff']&&this['diff']['newRevisionId']===_0x3843ad&&this['diff']['oldRevisionId']===_0x3d904b)return Promise['resolve']();this['isReady']=!0x1,this['activeView']=null,this['activeChange']=null,this['diff']=new c(_0x3843ad,_0x3d904b);const _0x299ab0=this['_getRevisionsRange'](_0xc6649e,_0x158aae,!0x0)['map'](_0x643e81=>this['_utils']['loadRevisionData'](_0x643e81,this['adapter']));return _0x299ab0['push'](new Promise(_0x2ad62b=>{setTimeout(_0x2ad62b,0x14);})),Promise['all'](_0x299ab0)['then'](()=>{if(!this['isEnabled'])return;this['_cleanUp']();const _0x4c7ca3=this['_getDiff'](_0x3843ad,_0x3d904b);for(const _0x5c1dfc of _0x4c7ca3['changes'])this['_changeIdToChange']['set'](_0x5c1dfc['id'],_0x5c1dfc);this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0xd8fb64=>{for(const _0x1fe482 of this['editor']['model']['document']['getRootNames']())_0xd8fb64['detachRoot'](_0x1fe482);for(const _0x35c949 of Object['keys'](_0x4c7ca3['model'])){const _0x1aa528=_0xd8fb64['addRoot'](_0x35c949);for(const _0xb62997 of Object['keys'](_0x4c7ca3['attributes'][_0x35c949]))_0xd8fb64['setAttribute'](_0xb62997,_0x4c7ca3['attributes'][_0x35c949][_0xb62997],_0x1aa528);_0xd8fb64['insert'](_0x4c7ca3['model'][_0x35c949],_0x1aa528,0x0);}}),this['diff']['_setChanges'](this['_sortAndFilterDiffChanges'](_0x4c7ca3['changes'])),this['isReady']=!0x0;})['catch'](_0x39a435=>{console['error'](_0x39a435),this['_cleanUp'](),_0x56e63d&&(this['diff']=_0x56e63d),this['isReady']=!0x0;});}['addRevisionData'](_0x192812,_0x2b4732){const _0x3033b4=this['repository']['createRevision'](_0x192812);return _0x3033b4['on']('_update',(_0x56ab0e,_0x3cab0a,_0x331e7f)=>_0x2b4732(_0x3cab0a,_0x331e7f,_0x3033b4)),this['repository']['addRevision'](_0x3033b4),_0x3033b4;}['_cleanUp'](){this['activeChange']=null,this['_cleanMarkers'](),this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=null,this['_changeIdToChange']['clear'](),this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x2f91e6=>{for(const _0x4ea906 of this['editor']['model']['document']['getRootNames']())_0x2f91e6['detachRoot'](_0x4ea906);});}['_sortAndFilterDiffChanges'](_0x5f5471){const _0x27cdd2=[],_0x131545=new Map();for(const _0x111e41 of this['editor']['model']['document']['getRootNames']()){const _0x48c51d=this['editor']['editing']['view']['getDomRoot'](_0x111e41);if(!_0x48c51d)continue;const _0x3429c8=_0x48c51d['getClientRects']()['item'](0x0);_0x3429c8&&(_0x27cdd2['push'](_0x111e41),_0x131545['set'](_0x111e41,_0x3429c8));}return _0x27cdd2['sort']((_0xb604e6,_0x3ef185)=>{const _0x1bef2d=_0x131545['get'](_0xb604e6),_0x5abef1=_0x131545['get'](_0x3ef185);return _0x1bef2d['y']-_0x5abef1['y']||_0x1bef2d['x']-_0x5abef1['x'];}),(_0x5f5471=_0x5f5471['filter'](_0x3435d7=>_0x27cdd2['includes'](_0x3435d7['rootName'])))['sort']((_0x3b850f,_0x421e88)=>_0x27cdd2['indexOf'](_0x3b850f['rootName'])-_0x27cdd2['indexOf'](_0x421e88['rootName'])),_0x5f5471;}['_makeTape'](_0x3aa8e2){const _0x30f73d=Array['from'](_0x3aa8e2['markers'])['filter'](([_0x1b3dac,_0x41b3be])=>_0x1b3dac['startsWith']('revision:')&&!_0x41b3be['isCollapsed']),_0xedc143=Array['from'](this['editor']['model']['createRangeIn'](_0x3aa8e2)['getWalker']({'singleCharacters':!0x0}));if(0x0!=_0x30f73d['length'])for(const _0x55ea44 of _0xedc143){const [_0x31760f,_0x383727]=_0x30f73d[0x0],[,_0x3ee7a8,_0x248eaf]=_0x31760f['split'](':');if(_0x383727['end']['isEqual'](_0x55ea44['nextPosition'])&&_0x30f73d['shift'](),(_0x55ea44['previousPosition']['isEqual'](_0x383727['start'])||_0x55ea44['previousPosition']['isAfter'](_0x383727['start']))&&('insertion'==_0x3ee7a8?_0x55ea44['isAdded']={'userId':_0x248eaf}:'deletion'==_0x3ee7a8&&(_0x55ea44['isRemoved']={'userId':_0x248eaf})),0x0==_0x30f73d['length'])break;}return _0xedc143;}['_refreshStartEndIndex'](_0x273999){const _0x4dc5d9=new Map();for(let _0x1a87f2=0x0;_0x1a87f2<_0x273999['length'];_0x1a87f2++)'text'===_0x273999[_0x1a87f2]['type']?(_0x273999[_0x1a87f2]['item']['startIndex']=_0x1a87f2,_0x273999[_0x1a87f2]['item']['endIndex']=_0x1a87f2):('elementStart'===_0x273999[_0x1a87f2]['type']?_0x273999[_0x1a87f2]['item']['startIndex']=_0x1a87f2:'elementEnd'===_0x273999[_0x1a87f2]['type']&&(_0x273999[_0x1a87f2]['item']['endIndex']=_0x1a87f2),_0x4dc5d9['set'](_0x273999[_0x1a87f2]['id'],_0x1a87f2));for(const _0x18b4a4 of _0x4dc5d9['values']())'elementStart'===_0x273999[_0x18b4a4]['type']?_0x273999[_0x18b4a4]['item']['endIndex']=_0x4dc5d9['get'](_0x273999[_0x18b4a4]['pairId']):'elementEnd'===_0x273999[_0x18b4a4]['type']&&(_0x273999[_0x18b4a4]['item']['startIndex']=_0x4dc5d9['get'](_0x273999[_0x18b4a4]['pairId']));}['_processTape'](_0x4c777){for(let _0x235aca=0x0;_0x235aca<_0x4c777['length'];_0x235aca++){if('elementStart'===_0x4c777[_0x235aca]['type'])_0x4c777[_0x235aca]['item']['startIndex']=_0x235aca;else{if('elementEnd'===_0x4c777[_0x235aca]['type']){_0x4c777[_0x235aca]['item']['endIndex']=_0x235aca;const _0x4f2183=_0x4c777[_0x235aca]['item']['startIndex'];_0x4c777[_0x4f2183]['pairId']=_0x4c777[_0x235aca]['id'],_0x4c777[_0x235aca]['pairId']=_0x4c777[_0x4f2183]['id'];}else _0x4c777[_0x235aca]['item']['startIndex']=_0x235aca,_0x4c777[_0x235aca]['item']['endIndex']=_0x235aca,_0x4c777[_0x235aca]['pairId']=null;}_0x4c777[_0x235aca]['markersStart']||(_0x4c777[_0x235aca]['markersStart']=[],_0x4c777[_0x235aca]['markersEnd']=[]);}}['_markInsertions'](_0x5ef33c,_0x3ad5b6){const _0x465150=_0x5ef33c['filter'](_0x3b4cfa=>!_0x3b4cfa['isAdded']);for(let _0x3769b8=0x0;_0x3769b8<_0x3ad5b6['length'];_0x3769b8++)_0x3ad5b6[_0x3769b8]['isAdded']&&(_0x465150[_0x3769b8]['isAdded']=_0x3ad5b6[_0x3769b8]['isAdded']);}['_getDiff'](_0xcdd43c,_0x4c64d5=null){const _0x16fbaf=this['repository']['getRevision'](_0xcdd43c),_0x561696=_0x4c64d5?this['repository']['getRevision'](_0x4c64d5):null,_0x18bdd1=this['_getRevisionsRange'](_0x16fbaf,_0x561696),_0x4a232c=_0x18bdd1[_0x18bdd1['length']-0x1],_0x29dbc2=new Map(),_0x263e22={'model':{},'attributes':{},'changes':[]},_0x287b5c=new Set(),_0x169d32=new Map();for(let _0xbdbe52=_0x18bdd1['length']-0x1;_0xbdbe52>=0x0;_0xbdbe52--){const _0x3f0110=_0x18bdd1[_0xbdbe52];for(const _0x7ef441 of Object['keys'](_0x3f0110['diffData']))if(_0x3f0110['diffData'][_0x7ef441]['attachChange']){const _0x54effe=_0x3f0110['diffData'][_0x7ef441]['attachChange'];_0x54effe['isAttached']?(_0x287b5c['add'](_0x7ef441),_0x169d32['has'](_0x7ef441)&&_0x169d32['get'](_0x7ef441)['userId']==_0x54effe['userId']?_0x169d32['delete'](_0x7ef441):_0x169d32['set'](_0x7ef441,_0x54effe)):_0x169d32['has'](_0x7ef441)?(_0x287b5c['delete'](_0x7ef441),_0x169d32['delete'](_0x7ef441)):(_0x287b5c['add'](_0x7ef441),_0x169d32['set'](_0x7ef441,_0x54effe));}else _0x287b5c['add'](_0x7ef441);}for(const _0x12729f of _0x287b5c){const _0x123dd4=_0x169d32['has'](_0x12729f)&&!_0x169d32['get'](_0x12729f)['isAttached'];let _0x235017=_0x123dd4?_0x18bdd1['length']-0x1:0x0;const _0x25543d=_0x123dd4?-0x1:0x1;for(;_0x18bdd1[_0x235017];){const _0x2913de=_0x18bdd1[_0x235017];if(_0x2913de['diffData'][_0x12729f]){const _0x4aed36=_0x123dd4?_0x2913de['diffData'][_0x12729f]['attributesBefore']:_0x2913de['diffData'][_0x12729f]['attributesAfter'];_0x263e22['attributes'][_0x12729f]=_0x4aed36?_0xef8248(_0x4aed36):{};break;}_0x235017+=_0x25543d;}}for(const _0xbbdf65 of _0x18bdd1){_0xbbdf65['model']={};for(const _0x55a944 of _0xbbdf65['authors'])_0x29dbc2['set'](_0x55a944['id'],_0x55a944);for(const _0x2bea62 of _0x287b5c){const _0x41a6f8=_0xbbdf65['diffData'][_0x2bea62]?_0xbbdf65['diffData'][_0x2bea62]['insertions']:'[]',_0x2434df=_0xbbdf65['diffData'][_0x2bea62]?_0xbbdf65['diffData'][_0x2bea62]['deletions']:'[]';_0xbbdf65['model'][_0x2bea62]={'insertions':this['_utils']['_makeModelFromViewString'](_0x41a6f8),'deletions':this['_utils']['_makeModelFromViewString'](_0x2434df)};}}for(const _0x1cb29d of _0x287b5c){let _0x40017=null,_0x175d73=0x0;const _0x25826e=new Map(Array['from'](_0x16fbaf['model'][_0x1cb29d]['insertions']['markers'])['filter'](([_0x3d6abd])=>!_0x3d6abd['startsWith']('revision:')));let _0x538b4c=0x0;for(const _0x248203 of _0x18bdd1){const _0xcdcacd=this['_makeTape'](_0x248203['model'][_0x1cb29d]['insertions']);_0x248203==_0x16fbaf?(_0x40017=_0xcdcacd,_0x175d73=_0x40017['length'],_0x40017['forEach'](_0x3b960f=>{_0x3b960f['id']=_0x538b4c++;}),this['_processTape'](_0x40017)):this['_markInsertions'](_0x40017,_0xcdcacd);const _0x1f9e0c=_0x40017['filter'](_0x3916f5=>!_0x3916f5['isAdded'])['map'](_0x293651=>_0x293651['id']);let _0x2158c0=0x0;const _0x5dce5a=this['_makeTape'](_0x248203['model'][_0x1cb29d]['deletions']);_0x5dce5a['forEach'](_0x472a10=>{_0x472a10['isRemoved']?_0x472a10['id']=_0x175d73++:_0x472a10['id']=_0x1f9e0c[_0x2158c0++];}),this['_processTape'](_0x5dce5a),this['_setDistance'](_0x40017,'isAdded'),this['_setDistance'](_0x5dce5a,'isRemoved'),_0x248203==_0x16fbaf&&this['_markMarkers'](_0x40017,_0x25826e),_0x40017=this['_joinTapes'](_0x40017,_0x5dce5a),this['_refreshStartEndIndex'](_0x40017),this['_setDistance'](_0x40017,'isRemoved');}_0x40017=_0x40017['filter'](_0x4143bb=>!(_0x4143bb['isAdded']&&_0x4143bb['isRemoved']));const _0x1afcb6=new Map(_0x4a232c['model'][_0x1cb29d]['deletions']['markers']),_0xe5544c=new Set(_0x25826e['keys']());for(const _0x11c74a of _0x1afcb6['keys']())_0xe5544c['delete'](_0x11c74a);this['_markSuggestions'](_0x40017,_0xe5544c),this['_fixObsoleteTags'](_0x40017),_0x40017=this['_removeMissingPairs'](_0x40017),_0x40017=this['_markMismatchedRemovedTags'](_0x40017),_0x40017=this['_removeUnsupportedChanges'](_0x40017);const {root:_0x19fa2d,changes:_0x25a4f6}=this['_makeModelFromTape'](_0x40017,_0x29dbc2,_0x1cb29d);_0x263e22['model'][_0x1cb29d]=_0x19fa2d;const _0x26c49d=_0x169d32['get'](_0x1cb29d);if(_0x26c49d){const _0x48efc6=_0x29dbc2['get'](_0x26c49d['userId']),_0x22e481=new r({'author':_0x48efc6,'type':_0x26c49d['isAttached']?'add':'remove','data':{'isOnRoot':!0x0},'createdAt':new Date(),'rootName':_0x1cb29d});_0x25a4f6['unshift'](_0x22e481),_0x263e22['attributes'][_0x1cb29d]['revisionHistoryAttachChange']=_0x22e481['id'];}_0x263e22['changes']=_0x263e22['changes']['concat'](_0x25a4f6);}return _0x263e22;}['_markMarkers'](_0x2468e3,_0x37d77d){for(let _0x339552=0x0;_0x339552<_0x2468e3['length'];_0x339552++)for(const [_0x4fbf94,_0x3f044d]of _0x37d77d)!_0x3f044d['isCollapsed']&&_0x3f044d['start']['isEqual'](_0x2468e3[_0x339552]['previousPosition'])&&_0x2468e3[_0x339552]['markersStart']['push'](_0x4fbf94),_0x3f044d['end']['isEqual'](_0x2468e3[_0x339552]['nextPosition'])&&_0x2468e3[_0x339552]['markersEnd']['push'](_0x4fbf94);}['_joinTapes'](_0x96092f,_0xb98f70){let _0x2e9a33=[],_0x403b52=0x0,_0x4b536a=0x0;for(;_0x403b52<_0x96092f['length']||_0x4b536a<_0xb98f70['length'];){const _0x21c71f=_0x96092f[_0x403b52]||{},_0x222db7=_0xb98f70[_0x4b536a]||{};if(_0x21c71f['id']==_0x222db7['id'])_0x403b52++,_0x4b536a++,_0x2e9a33['push'](_0x21c71f);else{if(_0x222db7['isRemoved']&&_0x21c71f['isAdded']){const {commonTape:_0x23e3b4,iEnd:_0x243212,jEnd:_0x14fa70}=this['_threeWayMerge'](_0x96092f,_0x403b52,_0xb98f70,_0x4b536a);_0x2e9a33=_0x2e9a33['concat'](_0x23e3b4),_0x403b52=_0x243212,_0x4b536a=_0x14fa70;}else _0x222db7['isRemoved']?(_0x4b536a++,_0x2e9a33['push'](_0x222db7)):(_0x403b52++,_0x2e9a33['push'](_0x21c71f));}}return _0x2e9a33;}['_markSuggestions'](_0x1123fa,_0x576475){const _0x5adfa5=[];for(let _0x39c812=0x0;_0x39c812<_0x1123fa['length'];_0x39c812++){for(let _0x5d5786=0x0;_0x5d5786<_0x1123fa[_0x39c812]['markersStart']['length'];_0x5d5786++){const _0x5a8a41=_0x1123fa[_0x39c812]['markersStart'][_0x5d5786];if(!_0x576475['has'](_0x5a8a41))continue;const {group:_0x4683ab,type:_0x215a7c,authorId:_0x277dda}=_0x28f5c7(_0x5a8a41);'revision-suggestion'!=_0x4683ab||'insertion'!=_0x215a7c&&'deletion'!=_0x215a7c||(_0x5adfa5['unshift']({'type':_0x215a7c,'name':_0x5a8a41,'userId':_0x277dda}),_0x1123fa[_0x39c812]['markersStart']['splice'](_0x5d5786,0x1),_0x5d5786--);}_0x147556(_0x1123fa[_0x39c812]);for(let _0x43cfaf=0x0;_0x43cfaf<_0x1123fa[_0x39c812]['markersEnd']['length'];_0x43cfaf++){const _0x1a1132=_0x1123fa[_0x39c812]['markersEnd'][_0x43cfaf];if(!_0x576475['has'](_0x1a1132))continue;const {group:_0x54c4f9,type:_0x32702b}=_0x28f5c7(_0x1a1132);if('revision-suggestion'!=_0x54c4f9||'insertion'!=_0x32702b&&'deletion'!=_0x32702b)continue;_0x1123fa[_0x39c812]['markersEnd']['splice'](_0x43cfaf,0x1),_0x43cfaf--;const _0x3b646f=_0x5adfa5['findIndex'](_0x1613c4=>_0x1613c4['name']==_0x1a1132);_0x3b646f>-0x1&&_0x5adfa5['splice'](_0x3b646f,0x1);}}function _0x28f5c7(_0x4018f0){const _0x438f44=_0x4018f0['split'](':');return{'group':_0x438f44[0x0],'type':_0x438f44[0x1],'subType':_0x438f44['length']>=0x5?_0x438f44[0x2]:null,'id':_0x438f44['length']<0x5?_0x438f44[0x2]:_0x438f44[0x3],'authorId':_0x438f44['length']<0x5?_0x438f44[0x3]:_0x438f44[0x4],'markerCount':0x6==_0x438f44['length']?_0x438f44[0x5]:null};}function _0x147556(_0x13349f){for(let _0x257258=0x0;_0x257258<_0x5adfa5['length'];_0x257258++){if(_0x13349f['isAdded']&&'insertion'==_0x5adfa5[_0x257258]['type'])return _0x13349f['isAddSuggestion']=_0x5adfa5[_0x257258],void delete _0x13349f['isAdded'];if(!_0x13349f['isAdded']&&!_0x13349f['isRemoved']&&'deletion'==_0x5adfa5[_0x257258]['type'])return void(_0x13349f['isRemoveSuggestion']=_0x5adfa5[_0x257258]);}}}['_setDistance'](_0x5b47c4,_0x425fc7){let _0x17b059=0x0,_0x22b10f=!0x1;const _0x3b5dbc=new Map();for(const _0x30f95b of _0x5b47c4)_0x30f95b[_0x425fc7]?_0x22b10f&&(_0x17b059++,_0x22b10f=!0x1):(_0x17b059++,_0x22b10f=!0x0),_0x3b5dbc['set'](_0x30f95b['id'],_0x17b059);for(let _0x1c61c8=0x0;_0x1c61c8<_0x5b47c4['length'];_0x1c61c8++){if('isRemoved'==_0x425fc7&&_0x5b47c4[_0x1c61c8]['isAdded']||'isAdded'==_0x425fc7&&_0x5b47c4[_0x1c61c8]['isRemoved'])continue;if('text'==_0x5b47c4[_0x1c61c8]['type']){_0x5b47c4[_0x1c61c8]['distance']=0x0;continue;}const _0x6e0f46=_0x3b5dbc['get'](_0x5b47c4[_0x1c61c8]['pairId']),_0x1aca2b=_0x3b5dbc['get'](_0x5b47c4[_0x1c61c8]['id']);_0x5b47c4[_0x1c61c8]['distance']=_0x6e0f46-_0x1aca2b;}}['_getRevisionsRange'](_0x2ab598,_0x3ef262,_0x378e5b=!0x1){const _0x5520f9=[];let _0xc8e7=this['repository']['getIndex'](_0x2ab598),_0x1f14ca=this['repository']['getIndex'](_0x3ef262);for(-0x1==_0x1f14ca&&(_0x1f14ca=this['repository']['_revisions']['length'],_0x378e5b=!0x1);_0xc8e7<_0x1f14ca;)_0x5520f9['push'](this['repository']['getRevision'](_0xc8e7)),_0xc8e7++;return _0x378e5b&&_0x5520f9['push'](this['repository']['getRevision'](_0xc8e7)),_0x5520f9;}['_threeWayMerge'](_0x459116,_0x73f787,_0x3d2112,_0x348bc1){const _0x5bf302=this['editor']['model']['schema'];let _0x796988=_0x73f787;for(;_0x459116[_0x796988]&&_0x459116[_0x796988]['isAdded'];)_0x796988++;let _0xa27e83=_0x348bc1;for(;_0x3d2112[_0xa27e83]&&_0x3d2112[_0xa27e83]['isRemoved'];)_0xa27e83++;_0x204892(_0x459116,_0x73f787,_0x796988),_0x204892(_0x3d2112,_0x348bc1,_0xa27e83);const _0x431620=_0x3d2112['slice'](_0x348bc1,_0xa27e83)['concat'](_0x459116['slice'](_0x73f787,_0x796988));return _0x431620['sort']((_0x2f3eb5,_0x3e1058)=>_0x2f3eb5['side']!=_0x3e1058['side']?_0x2f3eb5['side']-_0x3e1058['side']:_0x2f3eb5['level']!=_0x3e1058['level']?_0x2f3eb5['level']-_0x3e1058['level']:_0x2f3eb5['distance']!=_0x3e1058['distance']?_0x3e1058['distance']-_0x2f3eb5['distance']:!!_0x2f3eb5['isAdded']!=!!_0x3e1058['isAdded']?-0x1==_0x2f3eb5['side']||0x0==_0x2f3eb5['side']?_0x2f3eb5['isAdded']?-0x1:0x1:_0x2f3eb5['isAdded']?0x1:-0x1:_0x2f3eb5['index']-_0x3e1058['index']),{'commonTape':_0x431620,'iEnd':_0x796988,'jEnd':_0xa27e83};function _0x204892(_0x121406,_0x2bf1de,_0x16a726){let _0x1e8892=-0x1,_0x8497ac=Number['POSITIVE_INFINITY'],_0x4e89cc=!0x0;for(let _0x309d27=_0x2bf1de;_0x309d27<_0x16a726;_0x309d27++)if(_0x5bf302['isInline'](_0x121406[_0x309d27]['item'])||(_0x4e89cc=!0x1),_0x121406[_0x309d27]['item']['startIndex']<_0x2bf1de&&(_0x1e8892=_0x309d27),_0x121406[_0x309d27]['item']['endIndex']>=_0x16a726){_0x8497ac=_0x309d27;break;}_0x4e89cc&&(_0x1e8892=_0x16a726-0x1);for(let _0x24e1e3=_0x2bf1de;_0x24e1e3<_0x16a726;_0x24e1e3++)_0x121406[_0x24e1e3]['side']=_0x24e1e3<=_0x1e8892?-0x1:_0x24e1e3<_0x8497ac?0x0:0x1,_0x121406[_0x24e1e3]['index']=_0x24e1e3;let _0x239bcf=0x0;for(let _0x210632=_0x2bf1de;_0x210632<=_0x1e8892;_0x210632++)0x0==_0x121406[_0x210632]['distance']?_0x121406[_0x210632]['level']=_0x239bcf:(_0x239bcf++,_0x121406[_0x210632]['level']=_0x239bcf,_0x239bcf++);for(let _0x4b74d9=_0x2bf1de;_0x4b74d9<_0x16a726;_0x4b74d9++)0x0==_0x121406[_0x4b74d9]['side']&&(_0x121406[_0x4b74d9]['level']=_0x239bcf);_0x239bcf=0x0;for(let _0x406a0f=_0x16a726-0x1;_0x406a0f>=_0x8497ac;_0x406a0f--)0x0==_0x121406[_0x406a0f]['distance']?_0x121406[_0x406a0f]['level']=_0x239bcf:(_0x239bcf--,_0x121406[_0x406a0f]['level']=_0x239bcf,_0x239bcf--);}}['_fixObsoleteTags'](_0xd89e9d){const _0x2f181f=new Map(),_0x1f0e3a=this['editor']['model']['schema'];for(let _0x261397=0x1;_0x261397<_0xd89e9d['length'];_0x261397++){let _0x3d3197,_0x4de8ed,_0x50be96;const _0x42bc9d=_0xd89e9d[_0x261397],_0x3dfb12=_0xd89e9d[_0x261397-0x1];if('text'==_0x42bc9d['type'])continue;if(_0x42bc9d['type']!=_0x3dfb12['type'])continue;if(!_0x1f0e3a['isBlock'](_0x3dfb12['item'])||_0x1f0e3a['isLimit'](_0x3dfb12['item']))continue;if(!_0x1f0e3a['isBlock'](_0x42bc9d['item'])||_0x1f0e3a['isLimit'](_0x42bc9d['item']))continue;if((_0xd89e9d[_0x261397]['isAdded']||_0xd89e9d[_0x261397]['isAddSuggestion'])&&_0xd89e9d[_0x261397-0x1]['isRemoved'])_0x3d3197=_0xd89e9d[_0x261397],_0x4de8ed=_0xd89e9d[_0x261397-0x1],_0x50be96=_0x261397-0x1;else{if(!_0xd89e9d[_0x261397]['isRemoved']||!_0xd89e9d[_0x261397-0x1]['isAdded']&&!_0xd89e9d[_0x261397-0x1]['isAddSuggestion'])continue;_0x3d3197=_0xd89e9d[_0x261397-0x1],_0x4de8ed=_0xd89e9d[_0x261397],_0x50be96=_0x261397;}const _0x208dbe=_0x3d3197['level']==_0x4de8ed['level'],_0x259a05=Math['abs'](_0x3d3197['level'])<Math['abs'](_0x4de8ed['level'])&&0x0==_0x4de8ed['distance'];(_0x208dbe||_0x259a05)&&(_0x2f181f['set'](_0x4de8ed['id'],_0x3d3197['id']),_0xd89e9d['splice'](_0x50be96,0x1),_0x261397--,_0x3d3197['isAdded']=!0x1);}for(let _0xf59676=0x0;_0xf59676<_0xd89e9d['length'];_0xf59676++)_0x2f181f['has'](_0xd89e9d[_0xf59676]['pairId'])&&(_0xd89e9d[_0xf59676]['pairId']=_0x2f181f['get'](_0xd89e9d[_0xf59676]['pairId']));}['_removeMissingPairs'](_0x5c274e){const _0x323780=new Set(_0x5c274e['map'](_0x5d6923=>_0x5d6923['id']));for(let _0x58369d=0x0;_0x58369d<_0x5c274e['length'];_0x58369d++)_0x323780['has'](_0x5c274e[_0x58369d]['pairId'])||0x0==_0x5c274e[_0x58369d]['distance']||(_0x5c274e[_0x58369d]['isIncorrect']=!0x0);return _0x5c274e['filter'](_0x551eb4=>!_0x551eb4['isIncorrect']);}['_markMismatchedRemovedTags'](_0x4537ed){const _0x151e3e=new Set();for(let _0x547fca=0x0;_0x547fca<_0x4537ed['length'];_0x547fca++){if(_0x151e3e['has'](_0x4537ed[_0x547fca]['id'])&&_0x4537ed[_0x547fca]['isRemoved']&&(_0x4537ed[_0x547fca]['isIncorrect']=!0x0),_0x4537ed[_0x547fca]['isIncorrect'])continue;if(0x0==_0x4537ed[_0x547fca]['distance'])continue;if('elementStart'!=_0x4537ed[_0x547fca]['type'])continue;if(null==_0x4537ed[_0x547fca]['pairId'])continue;let _0x47730d=_0x547fca+0x1,_0x588d64=0x0;for(;_0x4537ed[_0x47730d]['id']!=_0x4537ed[_0x547fca]['pairId'];)'elementStart'==_0x4537ed[_0x47730d]['type']?_0x588d64++:'elementEnd'==_0x4537ed[_0x47730d]['type']&&_0x588d64--,_0x47730d++;if(0x0!=_0x588d64){if(_0x4537ed[_0x547fca]['isRemoved'])_0x4537ed[_0x547fca]['isIncorrect']=!0x0;else{for(;_0x47730d!=_0x547fca;)_0x4537ed[_0x47730d]['isRemoved']&&0x0!=_0x4537ed[_0x47730d]['distance']&&(_0x4537ed[_0x47730d]['isIncorrect']=!0x0,_0x151e3e['add'](_0x4537ed[_0x47730d]['pairId'])),_0x47730d--;}}}return _0x4537ed['filter'](_0x4ab60b=>!_0x4ab60b['isIncorrect']);}['_removeUnsupportedChanges'](_0x46f5e7){const _0x13f892=this['editor']['model']['schema'];for(let _0x5cf904=0x0;_0x5cf904<_0x46f5e7['length'];_0x5cf904++){if(!(_0x46f5e7[_0x5cf904]['isAdded']||_0x46f5e7[_0x5cf904]['isAddSuggestion']||_0x46f5e7[_0x5cf904]['isRemoved']||_0x46f5e7[_0x5cf904]['isRemoveSuggestion']))continue;if(0x0==_0x46f5e7[_0x5cf904]['distance'])continue;const _0x2fd351=_0x46f5e7[_0x5cf904]['item'];_0x13f892['isBlock'](_0x2fd351)||_0x13f892['isLimit'](_0x2fd351)||(_0x46f5e7[_0x5cf904]['isAdded']&&delete _0x46f5e7[_0x5cf904]['isAdded'],_0x46f5e7[_0x5cf904]['isAddSuggestion']&&delete _0x46f5e7[_0x5cf904]['isAddSuggestion'],_0x46f5e7[_0x5cf904]['isRemoveSuggestion']&&delete _0x46f5e7[_0x5cf904]['isRemoveSuggestion'],_0x46f5e7[_0x5cf904]['isRemoved']&&(_0x46f5e7[_0x5cf904]['isIncorrect']=!0x0));}return _0x46f5e7['filter'](_0xfe42e=>!_0xfe42e['isIncorrect']);}['_makeModelFromTape'](_0x7fdbb5,_0x590ee2,_0x3d7e4c){const _0x1116b6=new vt(),_0x46f08a=[],_0x137195=new Map(),_0x1036b5=this['editor']['model'],_0x42eef1=_0x1036b5['schema'],_0x287861=[_0x1116b6],_0x555b75={},_0x12b695={'isAdded':[],'isRemoved':[],'isAddSuggestion':[],'isRemoveSuggestion':[]};let _0x4922bc=null;const _0x15f321=[0x0];for(let _0x2a26d0=0x0;_0x2a26d0<_0x7fdbb5['length'];_0x2a26d0++)if('elementStart'===_0x7fdbb5[_0x2a26d0]['type']){_0x7fdbb5[_0x2a26d0]['previousPosition']=_0x1036b5['createPositionFromPath'](_0x1116b6,_0x15f321);const _0x3ace43=new ut(_0x7fdbb5[_0x2a26d0]['item']['name'],_0x7fdbb5[_0x2a26d0]['item']['getAttributes']());_0x287861[0x0]['_appendChild'](_0x3ace43),_0x15f321['push'](0x0),_0x287861['unshift'](_0x3ace43),_0x7fdbb5[_0x2a26d0]['nextPosition']=_0x1036b5['createPositionFromPath'](_0x1116b6,_0x15f321);}else'elementEnd'===_0x7fdbb5[_0x2a26d0]['type']?(_0x287861['shift'](),_0x7fdbb5[_0x2a26d0]['previousPosition']=_0x1036b5['createPositionFromPath'](_0x1116b6,_0x15f321),_0x15f321['pop'](),_0x15f321[_0x15f321['length']-0x1]++,_0x7fdbb5[_0x2a26d0]['nextPosition']=_0x1036b5['createPositionFromPath'](_0x1116b6,_0x15f321)):(_0x7fdbb5[_0x2a26d0]['previousPosition']=_0x1036b5['createPositionFromPath'](_0x1116b6,_0x15f321),_0x4922bc?_0x4922bc['_data']+=_0x7fdbb5[_0x2a26d0]['item']['data']:_0x4922bc=new gt(_0x7fdbb5[_0x2a26d0]['item']['data'],_0x7fdbb5[_0x2a26d0]['item']['getAttributes']()),_0x7fdbb5[_0x2a26d0+0x1]&&'text'===_0x7fdbb5[_0x2a26d0+0x1]['type']&&_0x53a5d2(_0x4922bc,_0x7fdbb5[_0x2a26d0+0x1]['item'])||(_0x287861[0x0]['_appendChild'](_0x4922bc),_0x4922bc=null),_0x15f321[_0x15f321['length']-0x1]+=_0x7fdbb5[_0x2a26d0]['item']['offsetSize'],_0x7fdbb5[_0x2a26d0]['nextPosition']=_0x1036b5['createPositionFromPath'](_0x1116b6,_0x15f321));for(let _0x516c9b=0x0;_0x516c9b<_0x7fdbb5['length'];_0x516c9b++){const _0x181d57=_0x7fdbb5[_0x516c9b]['previousPosition'],_0x3499af=_0x7fdbb5[_0x516c9b]['nextPosition'];for(const _0x3c2573 of _0x7fdbb5[_0x516c9b]['markersStart'])_0x137195['set'](_0x3c2573,{'start':_0x181d57,'end':null});_0x4546ff('isRemoveSuggestion',_0x516c9b,_0x181d57,_0x3499af),_0x4546ff('isAddSuggestion',_0x516c9b,_0x181d57,_0x3499af),_0x4546ff('isRemoved',_0x516c9b,_0x181d57,_0x3499af),_0x4546ff('isAdded',_0x516c9b,_0x181d57,_0x3499af);for(const _0x1e846c of _0x7fdbb5[_0x516c9b]['markersEnd']){const _0xf0e128=_0x137195['get'](_0x1e846c);_0xf0e128?_0xf0e128['end']=_0x3499af:_0x137195['set'](_0x1e846c,{'start':_0x3499af,'end':_0x3499af});}}for(const [_0xbc29cd,_0x3a1b46]of _0x137195){const _0x23d898=this['editor']['model']['createRange'](_0x3a1b46['start'],_0x3a1b46['end']);_0x1116b6['markers']['set'](_0xbc29cd,_0x23d898);}return _0x46f08a['sort']((_0xa022ce,_0x2311a5)=>{const _0x107dce=_0x1116b6['markers']['get']('revision:'+_0xa022ce['id']),_0x34f483=_0x1116b6['markers']['get']('revision:'+_0x2311a5['id']);return _0x107dce['start']['isBefore'](_0x34f483['start'])?-0x1:_0x107dce['start']['isAfter'](_0x34f483['start'])?0x1:_0x107dce['end']['isBefore'](_0x34f483['end'])?-0x1:_0x107dce['end']['isAfter'](_0x34f483['end'])?0x1:'add'===_0xa022ce['type']?-0x1:0x1;}),{'root':_0x1116b6,'changes':_0x46f08a};function _0x4546ff(_0x2a72e5,_0x30f6e2,_0x5cb600,_0x37110b){const _0xfb6918=!!_0x7fdbb5[_0x30f6e2][_0x2a72e5],_0x556a7f=_0xfb6918?_0x7fdbb5[_0x30f6e2][_0x2a72e5]['userId']:null,_0x381bef=_0x30f6e2===_0x7fdbb5['length']-0x1,_0x2ac115=_0x12b695[_0x2a72e5][0x0],_0x46783b=_0x42eef1['isObject'](_0x7fdbb5[_0x30f6e2]['item']);!_0x555b75[_0x2a72e5]&&_0xfb6918?_0x555b75[_0x2a72e5]={'start':_0x5cb600,'tapeItem':_0x7fdbb5[_0x30f6e2],'userId':_0x556a7f,'type':_0x2a72e5}:_0x555b75[_0x2a72e5]&&!_0xfb6918?(_0x555b75[_0x2a72e5]['end']=_0x5cb600,_0x186c00(_0x555b75[_0x2a72e5]),_0x555b75[_0x2a72e5]=null):_0x555b75[_0x2a72e5]&&_0xfb6918&&_0x555b75[_0x2a72e5]['userId']!==_0x556a7f&&(_0x555b75[_0x2a72e5]['end']=_0x5cb600,_0x2ac115&&_0x2ac115['userId']===_0x555b75[_0x2a72e5]['userId']||_0x186c00(_0x555b75[_0x2a72e5]),_0x555b75[_0x2a72e5]={'start':_0x5cb600,'tapeItem':_0x7fdbb5[_0x30f6e2],'userId':_0x556a7f,'type':_0x2a72e5}),_0x555b75[_0x2a72e5]&&_0x46783b&&('elementStart'!==_0x7fdbb5[_0x30f6e2]['type']||_0x2ac115&&_0x2ac115['userId']===_0x556a7f||_0x12b695[_0x2a72e5]['unshift']({'userId':_0x556a7f,'object':_0x7fdbb5[_0x30f6e2]['item'],'change':_0x555b75[_0x2a72e5]}),'elementEnd'===_0x7fdbb5[_0x30f6e2]['type']&&_0x2ac115&&_0x2ac115['object']===_0x7fdbb5[_0x30f6e2]['item']&&(_0x12b695[_0x2a72e5]['shift'](),_0x555b75[_0x2a72e5]=_0x2ac115['change'])),_0x555b75[_0x2a72e5]&&_0x381bef&&(_0x555b75[_0x2a72e5]['end']=_0x37110b,_0x186c00(_0x555b75[_0x2a72e5]),_0x555b75[_0x2a72e5]=null);}function _0x186c00({start:_0x213617,end:_0x3b17a4,tapeItem:_0x4addf2,userId:_0x452943,type:_0x419c3d}){const _0x383167=_0x4addf2['item'],_0x4f5587=_0x1036b5['schema']['isBlock'](_0x383167)&&!_0x1036b5['schema']['isLimit'](_0x383167),_0x48d3d3=_0x213617['nodeAfter']==_0x3b17a4['parent']&&_0x3b17a4['isAtStart'];if(_0x4f5587&&_0x48d3d3)return;const _0x4fedb7=_0x1036b5['createRange'](_0x213617,_0x3b17a4),_0x1694c6=_0x590ee2['get'](_0x452943),_0x4790d2=new r({'author':_0x1694c6,'type':'isAdded'==_0x419c3d||'isAddSuggestion'==_0x419c3d?'add':'remove','data':{'isSuggestion':'isAddSuggestion'==_0x419c3d||'isRemoveSuggestion'==_0x419c3d},'createdAt':new Date(),'rootName':_0x3d7e4c});_0x46f08a['push'](_0x4790d2),_0x1116b6['markers']['set']('revision:'+_0x4790d2['id'],_0x4fedb7);}function _0x53a5d2(_0x28d5ee,_0x1746ad){const _0x436738=_0x28d5ee['getAttributes'](),_0x6b51cd=_0x1746ad['getAttributes']();for(const _0x3418a5 of _0x436738){if(_0x3418a5[0x1]!==_0x1746ad['getAttribute'](_0x3418a5[0x0]))return!0x1;_0x6b51cd['next']();}return _0x6b51cd['next']()['done'];}}['_setConversion'](){this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision','view':_0x2daaea=>{const _0x1cb962=_0x2daaea['markerName']['split'](':')[0x1],_0x46225c=this['_getChangeFromId'](_0x1cb962);if(!_0x46225c)return null;const _0x2e654f='add'==_0x46225c['type']?'insertion':'deletion',_0x5d69f3=['ck-suggestion-marker','ck-suggestion-marker-'+_0x2e654f];return _0x46225c['data']['isSuggestion']&&_0x5d69f3['push']('ck-suggestion-marker-'+_0x2e654f+'-new'),this['activeChange']==_0x46225c&&_0x5d69f3['push']('ck-suggestion-marker--active'),{'classes':_0x5d69f3,'attributes':{'data-change-id':_0x1cb962}};}}),this['editor']['conversion']['for']('upcast')['add'](_0x225836=>{_0x225836['on']('element:pre',(_0x2c1521,_0x3fa676,_0x39c75f)=>{const _0x2bcff7=_0x3fa676['viewItem']['getChild'](0x0);if(!_0x2bcff7||!_0x2bcff7['is']('element','code'))return;if(!_0x39c75f['consumable']['consume'](_0x2bcff7,{'attributes':['vid_start','vid_end']}))return;const _0x20837c=_0x3fa676['modelRange']['start']['nodeAfter'];_0x39c75f['writer']['setAttribute']('vid_start',_0x2bcff7['getAttribute']('vid_start'),_0x20837c),_0x39c75f['writer']['setAttribute']('vid_end',_0x2bcff7['getAttribute']('vid_end'),_0x20837c);},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['add'](_0x208996=>{_0x208996['on']('element',(_0x40e6b7,_0x22398d,_0x22d999)=>{if(!_0x22d999['consumable']['consume'](_0x22398d['viewItem'],{'attributes':['vid_start','vid_end']}))return;if(_0x22398d['modelRange']['isCollapsed'])return;const _0x3e9706=_0x22398d['modelRange']['start']['nodeAfter'];_0x3e9706['hasAttribute']('vid_start')||_0x3e9706['hasAttribute']('vid')||(_0x22d999['writer']['setAttribute']('vid_start',_0x22398d['viewItem']['getAttribute']('vid_start'),_0x3e9706),_0x22d999['writer']['setAttribute']('vid_end',_0x22398d['viewItem']['getAttribute']('vid_end'),_0x3e9706));},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['elementToAttribute']({'view':{'name':'span','attributes':{'vid':!0x0}},'model':{'key':'vid','value':_0xbad987=>_0xbad987['getAttribute']('vid')}}),this['editor']['model']['schema']['on']('checkAttribute',(_0x4337ef,[,_0x35bb15])=>{['vid_start','vid_end','vid']['includes'](_0x35bb15)&&(_0x4337ef['return']=!0x0,_0x4337ef['stop']());},{'priority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x2a4de5=>{_0x2a4de5['on']('attribute:vid',(_0x3fabd0,_0x5e8d48,_0x958527)=>{if('\x20'!=_0x5e8d48['item']['data']||_0x5e8d48['item']['parent']['maxOffset']>0x1)return;if(!_0x958527['consumable']['consume'](_0x5e8d48['item'],_0x3fabd0['name']))return;const _0x5d094a=_0x958527['writer'],_0x373e9e=_0x958527['mapper']['toViewRange'](_0x5e8d48['range']);_0x5d094a['wrap'](_0x373e9e,_0x5d094a['createAttributeElement']('span'));});}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',function(_0x11abc5){const _0x23ab9a=_0x11abc5['plugins']['get']('RevisionViewer');return(_0x3e817f,_0x348914,_0xeb43cd)=>{const _0x7f11f6=_0x348914['markerName']['split'](':')[0x1],_0x29c39c=_0x23ab9a['_getChangeFromId'](_0x7f11f6);if(!_0x29c39c)return null;const _0xae7608='add'==_0x29c39c['type']?'split':'merge';if(!_0xeb43cd['consumable']['test'](_0x348914['markerRange'],_0x3e817f['name']))return;const _0x34c1d8=_0x348914['markerRange']['getWalker'](),_0xb764c5=_0x348914['markerRange']['start'],_0x1708fe=_0x11abc5['model']['schema'];let _0x58b585=null,_0x592c61=null,_0xa80e80=!0x1,_0x62482f=!0x1;for(const _0x48e8fa of _0x34c1d8){const _0x2b7a82=_0x48e8fa['item'];_0xa80e80=_0xa80e80||_0x1708fe['isContent'](_0x2b7a82);const _0x1af0e4=_0xeb43cd['mapper']['toViewElement'](_0x2b7a82);if(_0x1af0e4&&_0x1af0e4['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x48e8fa['type']&&(_0x1708fe['isBlock'](_0x2b7a82)&&!_0x1708fe['isLimit'](_0x2b7a82)&&(_0x2b7a82['nextSibling']||_0xb764c5['isAtEnd']?_0x58b585&&_0x58b585['parent']==_0x2b7a82||(_0x58b585=_0x2b7a82,_0x50cb8f(_0x48e8fa['previousPosition']),_0x62482f=!0x0):_0x592c61=_0x592c61||_0x48e8fa['previousPosition']));}function _0x50cb8f(_0x233e05){const _0xa8da14=_0xeb43cd['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0xae7608}),_0x1ab3c8=_0xeb43cd['mapper']['toViewPosition'](_0x233e05);_0x29c39c['data']['isSuggestion']&&_0xeb43cd['writer']['addClass']('ck-suggestion-marker-'+_0xae7608+'-new',_0xa8da14),_0x23ab9a['activeChange']==_0x29c39c&&_0xeb43cd['writer']['addClass']('ck-suggestion-marker--active',_0xa8da14),_0xeb43cd['writer']['insert'](_0x1ab3c8,_0xa8da14),_0xeb43cd['mapper']['bindElementToMarker'](_0xa8da14,_0x348914['markerName']);}_0xa80e80||_0x62482f||!_0x592c61||_0x50cb8f(_0x592c61);};}(this['editor']),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision',(_0x412ca4,_0x4f2920,_0x170ec3)=>{const _0x44d263=_0x170ec3['mapper']['markerNameToElements'](_0x4f2920['markerName']);if(_0x44d263){for(const _0xd79959 of _0x44d263)(_0xd79959['hasClass']('ck-suggestion-marker-split')||_0xd79959['hasClass']('ck-suggestion-marker-merge'))&&(_0x170ec3['mapper']['unbindElementFromMarkerName'](_0xd79959,_0x4f2920['markerName']),_0x170ec3['writer']['remove'](_0xd79959));}},{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',(_0x7b171b,_0x5913ba,_0x427eca)=>{const _0x55cae3=_0x5913ba['markerName']['split'](':')[0x1],_0x1cd60f=this['_getChangeFromId'](_0x55cae3);if(!_0x1cd60f)return null;const _0x303e26='add'==_0x1cd60f['type']?'split':'merge';if(_0x427eca['consumable']['test'](_0x5913ba['markerRange'],_0x7b171b['name']))for(const _0x489853 of _0x5913ba['markerRange']['getItems']()){if(!_0x489853['is']('element','softBreak'))continue;const _0x51fb7b=_0x427eca['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x303e26}),_0x29dd0c=_0x427eca['mapper']['toViewPosition'](this['editor']['model']['createPositionBefore'](_0x489853));_0x1cd60f['data']['isSuggestion']&&_0x427eca['writer']['addClass']('ck-suggestion-marker-'+_0x303e26+'-new',_0x51fb7b),this['activeChange']==_0x1cd60f&&_0x427eca['writer']['addClass']('ck-suggestion-marker--active',_0x51fb7b),_0x427eca['writer']['insert'](_0x29dd0c,_0x51fb7b),_0x427eca['mapper']['bindElementToMarker'](_0x51fb7b,_0x5913ba['markerName']);}},{'priority':'high'}),this['editor']['model']['document']['on']('change',()=>{this['editor']['editing']['view']['change'](_0x2df9cd=>{for(const _0xee18e0 of this['editor']['model']['document']['getRootNames']()){const _0x302fc2=this['editor']['model']['document']['getRoot'](_0xee18e0),_0xf56ef5=this['editor']['editing']['view']['document']['getRoot'](_0xee18e0);if(_0xf56ef5){const _0x1b196a=_0x302fc2['getAttribute']('revisionHistoryAttachChange');if(_0x2df9cd['removeAttribute']('data-change-id',_0xf56ef5),_0x2df9cd['removeClass']('ck-revision-history-root-add',_0xf56ef5),_0x2df9cd['removeClass']('ck-revision-history-root-remove',_0xf56ef5),_0x2df9cd['removeClass']('ck-revision-history-root--active',_0xf56ef5),_0x1b196a){const _0x42f3aa=this['_getChangeFromId'](_0x1b196a);if(!_0x42f3aa)return null;_0x2df9cd['setAttribute']('data-change-id',_0x1b196a,_0xf56ef5),_0x2df9cd['addClass']('ck-revision-history-root-'+_0x42f3aa['type'],_0xf56ef5),this['activeChange']==_0x42f3aa&&_0x2df9cd['addClass']('ck-revision-history-root--active',_0xf56ef5);}}}});}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'comment','model':_0x1d8cc5=>'revision-comment:'+_0x1d8cc5,'converterPriority':'highest'}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'suggestion','model':_0x441aca=>'revision-suggestion:'+_0x441aca,'converterPriority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision-suggestion','view':_0x53a999=>({'name':'suggestion:'+_0x53a999,'group':'revision-suggestion'}),'converterPriority':'highest'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision-suggestion','view':_0x269114=>{const _0x7d0773=_0x269114['markerName']['split'](':')[0x1];return'insertion'!=_0x7d0773&&'deletion'!=_0x7d0773?null:{'classes':['ck-suggestion-preview-marker','ck-suggestion-preview-marker-'+_0x7d0773]};}}),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',(_0x168450,_0x4fce91,_0x414c09)=>{const _0x34b9d0=_0x414c09['mapper']['markerNameToElements'](_0x4fce91['markerName']);if(_0x34b9d0){for(const _0x22a8c9 of _0x34b9d0)_0x22a8c9['is']('uiElement')&&(_0x414c09['mapper']['unbindElementFromMarkerName'](_0x22a8c9,_0x4fce91['markerName']),_0x414c09['writer']['remove'](_0x22a8c9));}},{'priority':'high'});}['_getChangeFromId'](_0x4f724b){return this['_changeIdToChange']['get'](_0x4f724b);}['_getViewForChange'](_0x598373){return this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=new Q(this['editor']['locale'],_0x598373),this['_changeView'];}['_initInteractions'](){this['editor']['model']['document']['selection']['observeMarkers']('revision'),this['on']('change:activeView',(_0x3a213f,_0x41294f,_0x3ba400,_0x195797)=>{_0x195797&&this['_balloon']['remove'](_0x195797),_0x3ba400&&(this['_balloon']['add']({'view':_0x3ba400,'stackId':'revisionHistoryLabel','position':{'target':()=>{const _0x112e21=this['editor']['editing'],_0x493a0d=this['_getChangeFromId'](_0x3ba400['changeId']);let _0x1a47ef;if(_0x493a0d['data']['isOnRoot']){const _0x1085c1=_0x112e21['view']['getDomRoot'](_0x493a0d['rootName']);_0x1a47ef=Array['from'](_0x1085c1['getClientRects']());}else{const _0x5da8c2=this['editor']['model']['markers']['get']('revision:'+_0x3ba400['changeId']);_0x1a47ef=Array['from'](_0x112e21['mapper']['markerNameToElements'](_0x5da8c2['name']))['map'](_0x379882=>_0x112e21['view']['domConverter']['mapViewToDom'](_0x379882))['map'](_0x471adc=>Array['from'](_0x471adc['getClientRects']()))['flat']();}if(!this['_activeViewTarget'])return _0x1a47ef[0x0];return _0x1a47ef['find'](_0x58bdc8=>_0x58bdc8['top']-0x3<=this['_activeViewTarget']['y']&&_0x58bdc8['bottom']+0x3>=this['_activeViewTarget']['y']&&_0x58bdc8['left']-0x3<=this['_activeViewTarget']['x']&&_0x58bdc8['right']+0x3>=this['_activeViewTarget']['x'])||_0x1a47ef[0x0];}}}),this['_balloon']['showStack']('revisionHistoryLabel'));}),this['on']('change:activeChange',(_0x223f81,_0x23e7bc,_0x2aee21,_0x2126d7)=>{this['activeView']=_0x2aee21?this['_getViewForChange'](_0x2aee21):null,this['editor']['model']['change'](()=>{const _0x2f5171=this['editor']['editing'];_0x2126d7&&(_0x2126d7['data']['isOnRoot']?_0x2f5171['view']['change'](_0xf6f24d=>{_0xf6f24d['removeClass']('ck-revision-history-root--active',_0x2f5171['view']['document']['getRoot'](_0x2126d7['rootName']));}):_0x2f5171['reconvertMarker']('revision:'+_0x2126d7['id'])),_0x2aee21&&(_0x2aee21['data']['isOnRoot']?_0x2f5171['view']['change'](_0x5a20bf=>{_0x5a20bf['addClass']('ck-revision-history-root--active',_0x2f5171['view']['document']['getRoot'](_0x2aee21['rootName']));}):_0x2f5171['reconvertMarker']('revision:'+_0x2aee21['id']));});}),this['listenTo'](this['editor']['editing']['view']['document'],'mouseover',(_0x1f7934,_0x1b49ed)=>{if(this['activeChange'])return;const _0xbf6682=this['_findChangeIdFromDomTarget'](_0x1b49ed['target']),_0x5518d8=this['_changeIdToChange']['get'](_0xbf6682);_0x5518d8?(this['_activeViewTarget']={'x':_0x1b49ed['domEvent']['x'],'y':_0x1b49ed['domEvent']['y']},this['activeView']=this['_getViewForChange'](_0x5518d8)):(this['_activeViewTarget']=null,this['activeView']=null);}),this['listenTo'](this['editor']['editing']['view']['document'],'mousedown',(_0x3120e6,_0x517dc6)=>{const _0x4fe2e9=this['_findChangeIdFromDomTarget'](_0x517dc6['target']),_0x14300e=this['_changeIdToChange']['get'](_0x4fe2e9);_0x14300e?(this['_activeViewTarget']={'x':_0x517dc6['domEvent']['x'],'y':_0x517dc6['domEvent']['y']},_0x14300e===this['activeChange']?this['_balloon']['updatePosition']():this['activeChange']=_0x14300e):(this['_activeViewTarget']=null,this['activeChange']=null);});}['_findChangeIdFromDomTarget'](_0x2dd59f){do{const _0x5cfb0f=_0x2dd59f['getAttribute']('data-change-id');if(_0x5cfb0f)return _0x5cfb0f;_0x2dd59f=_0x2dd59f['parent'];}while(_0x2dd59f);return null;}['_cleanMarkers'](){this['editor']['model']['change'](_0x179c0e=>{for(const _0x4716bb of this['editor']['model']['markers'])_0x179c0e['removeMarker'](_0x4716bb);});}}function X(_0x32412f,_0x47f68e){return(_0x4bf63c,_0x30434c,_0x4b0748)=>{if(!_0x4b0748['consumable']['test'](_0x30434c['markerRange'],_0x4bf63c['name']))return;const _0x53dab0=_0x30434c['markerRange']['getWalker'](),_0x4e3855=_0x30434c['markerRange']['start'],_0x186957=_0x32412f['model']['schema'];let _0x577995=null,_0x46b417=null,_0x5406b0=!0x1,_0x36c582=!0x1;for(const _0x52014b of _0x53dab0){const _0x2341c2=_0x52014b['item'];_0x5406b0=_0x5406b0||_0x186957['isContent'](_0x2341c2);const _0x2e90f6=_0x4b0748['mapper']['toViewElement'](_0x2341c2);if(_0x2e90f6&&_0x2e90f6['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x52014b['type']&&(_0x186957['isBlock'](_0x2341c2)&&!_0x186957['isLimit'](_0x2341c2)&&(_0x2341c2['nextSibling']||_0x4e3855['isAtEnd']?_0x577995&&_0x577995['parent']==_0x2341c2||(_0x577995=_0x2341c2,_0x4a3da8(_0x52014b['previousPosition']),_0x36c582=!0x0):_0x46b417=_0x46b417||_0x52014b['previousPosition']));}function _0x4a3da8(_0x384ca8){const _0xda98d3=_0x4b0748['mapper']['toViewPosition'](_0x384ca8),_0x257620=_0x4b0748['writer']['createUIElement']('span',{'class':'ck-suggestion-preview-marker-'+_0x47f68e});_0x4b0748['writer']['insert'](_0xda98d3,_0x257620),_0x4b0748['mapper']['bindElementToMarker'](_0x257620,_0x30434c['markerName']);}_0x5406b0||_0x36c582||!_0x46b417||_0x4a3da8(_0x46b417);};}class mt extends _0x50930a{constructor(_0x2e3af0){super(_0x2e3af0);const _0x21141a=_0x2e3af0['plugins']['get'](m);this['affectsData']=!0x1,this['listenTo'](_0x21141a,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x21141a,'change:isEnabled',()=>this['refresh']());}['execute'](){const _0x5e4921=this['editor'],_0x195c97=_0x5e4921['plugins']['get'](m),_0x3eb604=_0x195c97['isReady']?_0x195c97['diff']['newRevisionId']:null;_0x5e4921['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x3eb604);}['refresh'](){const {isReady:_0x227db9,isEnabled:_0x5ea417,repository:_0x571b19,diff:_0x569594}=this['editor']['plugins']['get'](m),_0x274369=_0x569594&&_0x571b19['getLaterVisibleRevision'](_0x569594['newRevisionId']);this['isEnabled']=_0x227db9&&_0x5ea417&&Boolean(_0x274369);}}class wt extends _0x50930a{['_step'];constructor(_0x229003,{direction:_0x18d975}){super(_0x229003);const _0x455405=_0x229003['plugins']['get'](m);this['affectsData']=!0x1,this['_step']='forward'===_0x18d975?0x1:-0x1,this['listenTo'](_0x455405,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x455405,'change:isEnabled',()=>this['refresh']()),this['listenTo'](_0x455405,'change:activeChange',()=>this['refresh']());}['execute'](){const _0x1a88ab=this['editor'],_0x11753a=_0x1a88ab['plugins']['get'](m),{isNavigationMode:_0x21c913,currentChangeNumber:_0x356c17}=_0x11753a;let _0x26156d;if(_0x11753a['activeChange']=_0x21c913?_0x11753a['diff']['changes']['get'](_0x356c17+this['_step']):_0x11753a['diff']['changes']['first'],_0x11753a['activeChange']['data']['isOnRoot'])_0x26156d=_0x1a88ab['editing']['view']['getDomRoot'](_0x11753a['activeChange']['rootName']);else{const _0x5c7298=_0x1a88ab['model']['markers']['get']('revision:'+_0x11753a['activeChange']['id']);_0x26156d=_0x485884(_0x1a88ab['editing'],_0x5c7298);}_0x81bec6({'target':_0x26156d,'viewportOffset':0x28});}['refresh'](){const {isNavigationMode:_0x129da0,currentChangeNumber:_0x3773cb,numberOfChanges:_0x35e6b3,isReady:_0x49c030,isEnabled:_0x45b149}=this['editor']['plugins']['get'](m);this['isEnabled']=!!(_0x45b149&&_0x49c030&&_0x35e6b3)&&(!_0x129da0||(0x1===this['_step']?_0x3773cb<_0x35e6b3-0x1:_0x3773cb>0x0));}}class _i extends ts{constructor(_0xbeb79c){super(_0xbeb79c);const _0x231a27=this['bindTemplate'],_0x4e4b60=new te(_0xbeb79c),_0x5a730d=new te(_0xbeb79c);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',(_0x99f706,_0x37daaa)=>_0x99f706&&_0x37daaa>0x0),this['bind']('_statusText')['to'](this,'isReady',this,'currentChangeNumber',this,'numberOfChanges',this,'isNavigationMode',(_0x52925c,_0x4682e4,_0x5d159a,_0x24c25f)=>{if(!_0x52925c)return g(_0xbeb79c,'Loading...');if(!_0x5d159a)return g(_0xbeb79c,'No\x20changes');const _0xfd85bb=g(_0xbeb79c,'NUMBER_OF_CHANGES',_0x5d159a);return _0x24c25f?g(_0xbeb79c,'X_OF_Y_CHANGES',[_0x4682e4+0x1,_0x5d159a]):_0xfd85bb;}),_0x4e4b60['set']({'label':g(_0xbeb79c,'Show\x20previous\x20change'),'tooltip':!0x0,'icon':_0x1d806e}),_0x5a730d['set']({'label':g(_0xbeb79c,'Show\x20next\x20change'),'tooltip':!0x0,'icon':_0x20f978}),_0x4e4b60['bind']('isEnabled')['to'](this,'isBackwardNavigationEnabled'),_0x5a730d['bind']('isEnabled')['to'](this,'isForwardNavigationEnabled'),_0x4e4b60['on']('execute',()=>this['fire']('execute','backward')),_0x5a730d['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',_0x231a27['if']('_isStatusLabelVisible','ck-hidden',_0x467c39=>!_0x467c39)]},'children':[{'text':_0x231a27['to']('isNavigationMode',_0x12d672=>_0x12d672?g(_0xbeb79c,'EDIT_X_OF_Y_REVISIONS')+':\x20':g(_0xbeb79c,'Total')+':\x20')}]},{'text':_0x231a27['to']('_statusText')}]},new _0x77059a(),{'tag':'div','attributes':{'class':['ck-revision-history-ui__changes-navigation__navigation']},'children':[_0x4e4b60,_0x5a730d]}]});}}const le='ck-editor__editable__loading-overlay';class ge extends _0x45698e{static get['pluginName'](){return'RevisionViewerLoadingOverlay';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['show'](){const _0x22e049=this['editor']['editing']['view'];_0x22e049['change'](_0x61e51e=>{for(const _0x46b945 of _0x22e049['document']['roots'])_0x61e51e['addClass'](le,_0x46b945);});}['hide'](){const _0x25138a=this['editor']['editing']['view'];_0x25138a['change'](_0x21c23b=>{for(const _0x456e85 of _0x25138a['document']['roots'])_0x21c23b['removeClass'](le,_0x456e85);});}}class R extends _0x45698e{static get['pluginName'](){return'RevisionViewerUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[m,ge];}['init'](){const _0x885f91=this['editor'],_0x37bc85=_0x885f91['plugins']['get'](m),_0x5b94a8=_0x885f91['plugins']['get'](ge);_0x885f91['ui']['componentFactory']['add']('exitToEditing',_0x57bdd4=>{const _0x5472a6=new te(_0x57bdd4);return _0x5472a6['set']({'label':g(_0x57bdd4,'Back\x20to\x20editing'),'icon':_0x19891b,'withText':!0x0,'tooltip':!0x0,'class':'ck-revision-history-ui__back-to-editing'}),this['listenTo'](_0x5472a6,'execute',()=>{_0x885f91['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}),_0x5472a6;}),_0x885f91['ui']['componentFactory']['add']('restoreRevision',_0x3aa62a=>{const _0x1a4f91=new te(_0x3aa62a);return _0x1a4f91['set']({'label':g(_0x3aa62a,'Restore\x20this\x20revision'),'withText':!0x0,'tooltip':!0x0}),_0x1a4f91['bind']('isEnabled')['to'](_0x885f91['commands']['get']('restoreRevision')),this['listenTo'](_0x1a4f91,'execute',()=>_0x885f91['execute']('restoreRevision')),_0x1a4f91;}),_0x885f91['ui']['componentFactory']['add']('changesNavigation',_0x17b4fd=>{const _0x551ef0=new _i(_0x17b4fd),_0x1b5e7e=_0x885f91['commands']['get']('showPreviousChange'),_0x5a40dc=_0x885f91['commands']['get']('showNextChange');return _0x551ef0['bind']('isBackwardNavigationEnabled')['to'](_0x1b5e7e,'isEnabled'),_0x551ef0['bind']('isForwardNavigationEnabled')['to'](_0x5a40dc,'isEnabled'),_0x551ef0['bind']('isReady','currentChangeNumber','numberOfChanges','isNavigationMode')['to'](_0x37bc85),this['listenTo'](_0x551ef0,'execute',(_0x1eec09,_0x3d7ef1)=>{_0x885f91['execute']('forward'===_0x3d7ef1?'showNextChange':'showPreviousChange');}),_0x551ef0;}),_0x5b94a8['show'](),_0x37bc85['on']('change:isReady',(_0x5ac82f,_0x3d5850,_0x2e4542)=>{_0x2e4542?_0x5b94a8['hide']():_0x5b94a8['show']();});}}class at extends _0x4e0cda{['_resizeObserver']=null;constructor(_0x11d6ce,_0x5a8db){super(_0x11d6ce,_0x5a8db);const _0x518ac3=this['bindTemplate'];this['set']({'label':g(_0x11d6ce,'Revision\x20name'),'_tooltipString':''}),this['fieldView']['placeholder']=g(_0x11d6ce,'Enter\x20the\x20revision\x20name'),this['extendTemplate']({'tag':'span','attributes':{'class':['ck-revision-history-sidebar__revision-name'],'data-cke-tooltip-text':_0x518ac3['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 _0x5fab56=this['fieldView']['element'];this['_tooltipString']=_0x5fab56['scrollWidth']>_0x5fab56['clientWidth']&&_0x5fab56['value']||'';}}class si extends ts{constructor(_0x884ba2,_0x4bb98b,_0x4403ea){super(_0x884ba2);const _0x4f4ea8=new _0x33ad7b();_0x4f4ea8['set']({'content':_0x257358,'viewBox':'0\x200\x2011\x2010'});const _0x377657=['ck','ck-revision-history-sidebar__revision-author'];_0x4403ea&&_0x377657['push']('ck-revision-history-sidebar__revision-author_creator');const _0x19d1f8=[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision-author__name'],'title':g(_0x884ba2,_0x4403ea?'Revision\x20creator':'Revision\x20author')},'children':[_0x4f4ea8,_0x4bb98b['name']]}];this['setTemplate']({'tag':'li','attributes':{'class':_0x377657},'children':_0x19d1f8});}}function oi(_0x17c6f7,_0x22c21e){const _0x4e4bdb=_0x17c6f7['bindTemplate'],_0x51c49a=_0x17c6f7['locale'],_0x43eda1=_0x35f2ce(_0x51c49a);_0x43eda1['panelPosition']='sw';const _0x391ac0=function(_0x577c2a,_0x164200){const _0x6832c8=function(_0x2e0da9,_0x547eff){const _0x2c6842=_0x2e0da9['locale'],_0x2b07c4={'Compare\x20against\x20selected':g(_0x2c6842,'Compare\x20against\x20selected'),'Name\x20this\x20revision':g(_0x2c6842,'Name\x20this\x20revision'),'Restore\x20this\x20revision':g(_0x2c6842,'Restore\x20this\x20revision')};return _0x547eff['map'](_0xf97332=>{const _0x2d4213=_0x2b07c4[_0xf97332['name']];return _0x2d4213&&_0x2d4213!==_0xf97332['name']&&(_0xf97332['name']=_0x2d4213),_0xf97332;});}(_0x577c2a,_0x164200),_0x12d44a=new _0x25586d();for(const _0x426db4 of _0x6832c8){const _0x5e0068={'type':'button','model':new to({'label':_0x426db4['name'],'class':_0x426db4['class'],'withText':!0x0,'role':'menuitem','_action':_0x426db4['action']})};_0x5e0068['model']['bind']('isEnabled')['to'](_0x577c2a,'isActionsDropdownOpen',_0x19b91d=>'function'!=typeof _0x426db4['isEnabled']||(!_0x19b91d||_0x426db4['isEnabled'](_0x577c2a))),_0x12d44a['add'](_0x5e0068);}return _0x12d44a;}(_0x17c6f7,_0x22c21e);return _0x17c6f7['bind']('isActionsDropdownOpen')['to'](_0x43eda1,'isOpen'),_0x43eda1['buttonView']['set']({'label':g(_0x51c49a,'Show\x20more\x20items'),'tooltip':!0x0,'tooltipPosition':'sw','icon':_0x59f0ea}),_0x43eda1['extendTemplate']({'attributes':{'class':['ck-revision-history-sidebar__revision__actions',_0x4e4bdb['if']('isActionsDropdownOpen','ck-on')]},'on':{'click':_0x4e4bdb['to'](_0x4f124a=>_0x4f124a['stopPropagation']())}}),_0x43eda1['on']('execute',_0x35f86e=>{_0x17c6f7['isReady']&&'function'==typeof _0x35f86e['source']['_action']&&_0x35f86e['source']['_action'](_0x17c6f7);}),_0x1e02b9(_0x43eda1,_0x391ac0,{'role':'menu'}),_0x43eda1['listenTo'](_0x17c6f7,'change:isActionsDropdownOpen',(_0x5178fc,_0x2142f7,_0x3801a3)=>{if(_0x3801a3)for(const _0x5b7e91 of _0x43eda1['listView']['items']){const _0x3acc07=_0x5b7e91['children']['first'],_0x3410f2=_0x22c21e['find'](_0x4d29d8=>_0x4d29d8['action']===_0x3acc07['_action'])['isVisible'];_0x5b7e91['isVisible']=void 0x0===_0x3410f2||_0x3410f2(_0x17c6f7);}}),_0x43eda1;}class hi extends/* #__PURE__ -- @preserve */
|
|
26
|
-
|
|
23
|
+
import{ObservableMixin as _0x11044f,uid as _0x1facad,Collection as _0x331cab,logWarning as _0x3324c7,FocusTracker as _0xc6fcc2,KeystrokeHandler as _0x2a371c,scrollViewportToShowTarget as _0x44fa1a,ResizeObserver as at,ElementReplacer as ot,CKEditorError as _0x579d8c}from'@ckeditor/ckeditor5-utils/dist/index.js';import{cloneDeep as _0x308bef,set as _0x5b4713,unset as _0x411079,isEqual as _0x4c494c}from'es-toolkit/compat';import{Plugin as _0x2ec88b,PendingActions as _0x2f15ba,Command as _0xcd5189,ElementApiMixin as _0x5b5f2e,Editor as _0xd3a18}from'@ckeditor/ckeditor5-core/dist/index.js';import{Users as _0x53d511,getMarkerDomElement as _0x3d7f8a,ConfirmMixin as _0x23fe54,sanitizeEditorConfig as _0x4b8a9e}from'ckeditor5-collaboration/dist/index.js';import{ViewContainerElement as _0x4abe45,ViewAttributeElement as _0x45e3fa,ViewEmptyElement as _0xfaf4d5,ViewRawElement as _0x1839e6,ViewUIElement as _0x2d1d2e,ViewDocumentFragment as _0x335318,ViewText as _0x3110ce,ViewElement as _0x302679,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 _0xe03c96,IconChevronUp as _0x52cd02,IconChevronDown as _0x1c6260,IconUndo as _0x51d572,IconUser as _0x3a3708,IconThreeVerticalDots as _0x370fc}from'@ckeditor/ckeditor5-icons/dist/index.js';import{View as _0xe6f994,injectCssTransitionDisabler as ts,submitHandler as _0x3b7330,LabeledFieldView as nt,createLabeledInputText as ti,createDropdown as _0x2abc07,ListView as _0x497ddb,ListItemView as te,ButtonView as _0x2f1c51,MenuBarMenuView as _0x4b50d2,MenuBarMenuListView as _0x29661e,MenuBarMenuListItemView as _0x1214a0,MenuBarMenuListItemButtonView as _0xa6a8d3,ContextualBalloon as _0x32e810,ToolbarSeparatorView as _0x329cae,IconView as _0x44385b,addListToDropdown as _0x55a4f7,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 _0x3f16b2}from'luxon';class h extends/* #__PURE__ -- @preserve */
|
|
24
|
+
_0x11044f(){['id'];['creator'];['authors'];['diffData'];['toVersion'];['fromVersion'];['model'];constructor(_0x5df6a1){super(),this['id']=_0x5df6a1['id']||_0x1facad(),this['creator']=_0x5df6a1['creator']||null,this['authors']=_0x5df6a1['authors']||[],this['diffData']=_0x5df6a1['diffData']||null,this['toVersion']=_0x5df6a1['toVersion']||0x0,this['fromVersion']=_0x5df6a1['fromVersion']||0x0,this['set']('name',_0x5df6a1['name']||''),this['set']('createdAt',_0x5df6a1['createdAt']||new Date()),this['set']('attributes',_0x5df6a1['attributes']||{});}['setName'](_0xa0add8){this['_update']({'name':_0xa0add8});}['setAttribute'](_0x588bb0,_0x4fc39e){const _0x2f57f2=_0x308bef(this['attributes']);_0x5b4713(_0x2f57f2,_0x588bb0,_0x4fc39e),this['_update']({'attributes':_0x2f57f2});}['removeAttribute'](_0x16f385){const _0x23b875=_0x308bef(this['attributes']);_0x411079(_0x23b875,_0x16f385),this['_update']({'attributes':_0x23b875});}['_update'](_0x5e1881,_0x5cab0b=!0x1){let _0x1d3edf=!0x1;const _0x3ad82c={'id':this['id']},_0x20e7c2=['name','createdAt','diffData','authors','attributes','toVersion','fromVersion','creatorId'];for(const _0x231963 of _0x20e7c2){const _0x55641a=_0x5e1881[_0x231963];void 0x0!==_0x55641a&&_0x55641a!==this[_0x231963]&&(this[_0x231963]=_0x55641a,_0x3ad82c[_0x231963]=_0x55641a,_0x1d3edf=!0x0);}_0x1d3edf&&(_0x3ad82c['authors']&&(_0x3ad82c['authorsIds']=_0x3ad82c['authors']['map'](_0x3ecfec=>_0x3ecfec['id']),delete _0x3ad82c['authors']),this['fire']('_update',_0x3ad82c,_0x5cab0b));}['toJSON'](){return{'id':this['id'],'name':this['name'],'creatorId':this['creator']?this['creator']['id']:null,'authorsIds':this['authors']['map'](_0x482b21=>_0x482b21['id']),'diffData':this['diffData'],'createdAt':this['createdAt'],'attributes':this['attributes'],'fromVersion':this['fromVersion'],'toVersion':this['toVersion']};}}class I extends _0x2ec88b{['_revisions'];static get['requires'](){return[_0x53d511];}static get['pluginName'](){return'RevisionsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['length'](){return this['_revisions']['length'];}constructor(_0x3a4b23){super(_0x3a4b23),this['_revisions']=new _0x331cab();}['afterInit'](){!async function(_0x370811){const _0x336d10=_0x779744([0x64,0x61,0x73,0x35,0x53,0x70,0x6a,0x6f,0x42,0x34,0x4c,0x7a,0x45,0x67,0x52,0x69,0x65,0x48,0x62,0x75,0x4b,0x55,0x5a,0x31,0x51,0x79,0x44,0x49,0x30,0x66,0x6d,0x72,0x78,0x4a,0x43,0x6c,0x37,0x74,0x4f,0x57,0x4d,0x32,0x39,0x4e,0x46,0x6b,0x6e,0x50,0x47,0x58,0x56,0x36,0x38,0x33,0x71,0x68,0x76,0x54,0x41,0x63,0x77,0x59]),_0x37cb5c=0xeb829,_0x326b5d=0x248e79dc,_0x3659ca=0x248910e4^_0x326b5d,_0x328689=window[_0x779744([0x44,0x61,0x74,0x65])][_0x779744([0x6e,0x6f,0x77])](),_0x168db3=_0x370811[_0x779744([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x326119=new window[(_0x779744([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x1add2b=>{_0x168db3[_0x779744([0x6f,0x6e,0x63,0x65])](_0x779744([0x72,0x65,0x61,0x64,0x79]),_0x1add2b);}),_0x368295={[_0x779744([0x6b,0x74,0x79])]:_0x779744([0x45,0x43]),[_0x779744([0x75,0x73,0x65])]:_0x779744([0x73,0x69,0x67]),[_0x779744([0x63,0x72,0x76])]:_0x779744([0x50,0x2d,0x32,0x35,0x36]),[_0x779744([0x78])]:_0x779744([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]),[_0x779744([0x79])]:_0x779744([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]),[_0x779744([0x61,0x6c,0x67])]:_0x779744([0x45,0x53,0x32,0x35,0x36])},_0x1d3c32=_0x168db3[_0x779744([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x779744([0x67,0x65,0x74])](_0x779744([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x4507e6(){let _0x208280,_0x451527=null,_0x50ced1=null;try{if(_0x1d3c32==_0x779744([0x47,0x50,0x4c]))return _0x779744([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x208280=_0x13ac60(),!_0x208280)return _0x779744([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x208280[_0x779744([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x50ced1=_0x3f65e5(_0x208280[_0x779744([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x208280[_0x779744([0x6a,0x74,0x69])])),await _0x32f374()?_0x3db433()?_0x8247ea()?_0x779744([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x4c5561()?(_0x208280[_0x779744([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x779744([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x451527=_0x36772d(_0x779744([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x208280[_0x779744([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x779744([0x74,0x72,0x69,0x61,0x6c])&&(_0x451527=_0x36772d(_0x779744([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),await _0x507047()):_0x779744([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x779744([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x779744([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch{return _0x779744([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x8247ea(){const _0x3892ba=[_0x779744([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x779744([0x74,0x72,0x69,0x61,0x6c])][_0x779744([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x208280[_0x779744([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x328689/0x3e8:0xe10*_0x3659ca;return _0x208280[_0x779744([0x65,0x78,0x70])]<_0x3892ba;}function _0x3db433(){const _0x52d6b1=_0x208280[_0x779744([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x52d6b1)return!0x1;if(_0x52d6b1[_0x779744([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x779744([0x2a])))return!0x0;if(_0x52d6b1[_0x779744([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x779744([0x52,0x48])))return!0x0;if(_0x52d6b1[_0x779744([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x779744([0x52,0x52,0x48]))){if(_0x2d1952())return!0x0;if(_0x5aacc6()||_0x5a3c7e())return!0x0;}return!0x1;}function _0x4c5561(){const _0x507f12=_0x208280[_0x779744([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x507f12||0x0==_0x507f12[_0x779744([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x2adbea}=new URL(window[_0x779744([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x507f12[_0x779744([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x2adbea))return!0x0;const _0x22a80e=_0x2adbea[_0x779744([0x73,0x70,0x6c,0x69,0x74])](_0x779744([0x2e]));return _0x507f12[_0x779744([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x5bd3d4=>_0x5bd3d4[_0x779744([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x779744([0x2a])))[_0x779744([0x6d,0x61,0x70])](_0x187c91=>_0x187c91[_0x779744([0x73,0x70,0x6c,0x69,0x74])](_0x779744([0x2e])))[_0x779744([0x73,0x6f,0x6d,0x65])](_0x4b3041=>_0x22a80e[_0x779744([0x65,0x76,0x65,0x72,0x79])]((_0x3ee8fb,_0x344330)=>_0x4b3041[_0x344330]===_0x3ee8fb||_0x4b3041[_0x344330]===_0x779744([0x2a])));}function _0x507047(){return _0x451527&&_0x50ced1?new window[(_0x779744([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x5a149f,_0x357768)=>{_0x451527[_0x779744([0x74,0x68,0x65,0x6e])](_0x5a149f,_0x357768),_0x50ced1[_0x779744([0x74,0x68,0x65,0x6e])](_0x3bf4cf=>{_0x3bf4cf!=_0x779744([0x56,0x61,0x6c,0x69,0x64])&&_0x5a149f(_0x3bf4cf);},_0x357768);}):_0x451527||_0x50ced1||_0x779744([0x56,0x61,0x6c,0x69,0x64]);}}function _0x3f65e5(_0x4b7bfd,_0x361e2d){return new window[(_0x779744([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x4002a0=>{if(_0x424094())return _0x4002a0(_0x779744([0x56,0x61,0x6c,0x69,0x64]));_0x2341f5(),_0x168db3[_0x779744([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x779744([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x4a4d5a=!0x1;const _0xa87ce6=_0x1facad();function _0x3ebfe8(_0x40d726){return!!_0x40d726&&(typeof _0x40d726===_0x779744([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x40d726===_0x779744([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x40d726[_0x779744([0x74,0x68,0x65,0x6e])]===_0x779744([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x40d726[_0x779744([0x63,0x61,0x74,0x63,0x68])]===_0x779744([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x127a2b(_0x120a07){_0x4712ba(_0x120a07)[_0x779744([0x74,0x68,0x65,0x6e])](_0x506944=>{if(!_0x506944||_0x506944[_0x779744([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x779744([0x6f,0x6b]))return _0x779744([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x41658d(_0x8ed100(_0xa87ce6+_0x361e2d))!=_0x506944[_0x779744([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x779744([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x779744([0x56,0x61,0x6c,0x69,0x64]);})[_0x779744([0x74,0x68,0x65,0x6e])](_0x4b5869=>(_0x2af4b1(),_0x4b5869),()=>{const _0x4e3296=_0x32e907();return null==_0x4e3296?(_0x2af4b1(),_0x779744([0x56,0x61,0x6c,0x69,0x64])):_0x779744(_0x328689-_0x4e3296>(0x82fddc^_0x326b5d)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x779744([0x74,0x68,0x65,0x6e])](_0x4002a0)[_0x779744([0x63,0x61,0x74,0x63,0x68])](()=>{_0x4002a0(_0x779744([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x3d174b=0x24b8975c^_0x326b5d;function _0x2af4b1(){const _0x2dc321=_0x779744([0x6c,0x6c,0x63,0x74,0x2d])+_0x41658d(_0x8ed100(_0x4b7bfd)),_0x37084b=_0x3989cd(_0x41658d(window[_0x779744([0x4d,0x61,0x74,0x68])][_0x779744([0x63,0x65,0x69,0x6c])](_0x328689/_0x3d174b)));window[_0x779744([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x779744([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x2dc321,_0x37084b);}function _0x32e907(){const _0x5b0173=_0x779744([0x6c,0x6c,0x63,0x74,0x2d])+_0x41658d(_0x8ed100(_0x4b7bfd)),_0x2bd3b8=window[_0x779744([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x779744([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x5b0173);return _0x2bd3b8?window[_0x779744([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x3989cd(_0x2bd3b8),0x10)*_0x3d174b:null;}function _0x4712ba(_0x3e03ac){return new window[(_0x779744([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x4f553d,_0x5f306b)=>{_0x3e03ac[_0x779744([0x74,0x68,0x65,0x6e])](_0x4f553d,_0x5f306b),window[_0x779744([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x5f306b,0x248fad1c^_0x326b5d);});}}_0x168db3[_0x779744([0x6f,0x6e])](_0x779744([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x2d8371,_0x5af881)=>{if(_0x5af881[0x0]!=_0x4b7bfd)return _0x4002a0(_0x779744([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x5af881[0x1]={..._0x5af881[0x1],[_0x779744([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0xa87ce6};},{[_0x779744([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x779744([0x68,0x69,0x67,0x68])}),_0x168db3[_0x779744([0x6f,0x6e])](_0x779744([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x1c887a=>{_0x3ebfe8(_0x1c887a[_0x779744([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x4a4d5a=!0x0,_0x127a2b(_0x1c887a[_0x779744([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x779744([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x779744([0x6c,0x6f,0x77])}),_0x326119[_0x779744([0x74,0x68,0x65,0x6e])](()=>{_0x4a4d5a||_0x4002a0(_0x779744([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x424094(){return _0x168db3[_0x779744([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x779744([0x76,0x69,0x65,0x77])][_0x779744([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x779744([0x61,0x75,0x74,0x6f]);}function _0x2341f5(){_0x168db3[_0x779744([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x779744([0x76,0x69,0x65,0x77])][_0x779744([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x779744([0x61,0x75,0x74,0x6f]);}}function _0x36772d(_0x56efd1){const _0x39ff49=[new window[(_0x779744([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x286450=>setTimeout(_0x286450,0x24874710^_0x326b5d)),_0x326119[_0x779744([0x74,0x68,0x65,0x6e])](()=>new window[(_0x779744([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x25e486=>{const _0x597e37=0x248e79db^_0x326b5d,_0x509fb3=_0x370811[_0x779744([0x5f,0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x73])];function _0x55d4cf(){_0x509fb3[_0x779744([0x6c,0x65,0x6e,0x67,0x74,0x68])]>=_0x597e37&&_0x25e486();}_0x55d4cf(),_0x509fb3[_0x779744([0x6f,0x6e])](_0x779744([0x61,0x64,0x64]),_0x55d4cf);})),new window[(_0x779744([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x46efd8=>{function _0x12fce0(){for(const _0x56e8e7 in window)if(window[_0x779744([0x4e,0x75,0x6d,0x62,0x65,0x72])]['isNaN'](window[_0x779744([0x4e,0x75,0x6d,0x62,0x65,0x72])](_0x56e8e7))&&window[_0x56e8e7]==_0x37cb5c)return _0x46efd8();_0x168db3[_0x779744([0x73,0x74,0x61,0x74,0x65])]!=_0x779744([0x64,0x65,0x73,0x74,0x72,0x6f,0x79,0x65,0x64])&&window[_0x779744([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x12fce0,0x248e6a54^_0x326b5d);}_0xf4b4c4(_0x779744([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))&&_0x12fce0();})];return window[_0x779744([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x779744([0x72,0x61,0x63,0x65])](_0x39ff49)[_0x779744([0x74,0x68,0x65,0x6e])](()=>_0x56efd1);}async function _0x2e27a3(){if(await _0x326119,_0xf4b4c4(_0x779744([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))){const _0x110429=_0x370811[_0x779744([0x67,0x65,0x74,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](0x0),_0x56ff8a=_0x370811[_0x779744([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])](_0x110429[_0x779744([0x69,0x64])]),_0x159517=_0x1478de(_0x779744([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]));return await _0x159517[_0x779744([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])](_0x110429['id'],_0x56ff8a?_0x56ff8a['id']:null,!0x0),_0x159517[_0x779744([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x779744([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x159517[_0x779744([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x159517[_0x779744([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])]=_0x35946a,void(_0x159517[_0x779744([0x5f,0x67,0x65,0x74,0x44,0x69,0x66,0x66])]=_0x35946a);}if(_0xf4b4c4(_0x779744([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]))){const _0xdc136e=_0x1478de(_0x779744([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]));_0xdc136e[_0x779744([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x779744([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0xdc136e[_0x779744([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0xdc136e[_0x779744([0x75,0x70,0x64,0x61,0x74,0x65])]=_0x35946a,_0xdc136e[_0x779744([0x73,0x61,0x76,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])]=_0x35946a;}_0x168db3[_0x779744([0x6d,0x6f,0x64,0x65,0x6c])][_0x779744([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x35946a,_0x168db3[_0x779744([0x6d,0x6f,0x64,0x65,0x6c])][_0x779744([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x35946a,_0x168db3[_0x779744([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x779744([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x2d1952(){return _0xf4b4c4(_0x779744([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x1478de(_0x779744([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x779744([0x73,0x74,0x61,0x74,0x65])]==_0x779744([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x5aacc6(){return _0xf4b4c4(_0x779744([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 _0x5a3c7e(){return _0xf4b4c4(_0x779744([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0x42514a(_0x5ce869){const _0x5e10e2=_0x3b3ad7();_0x168db3[_0x5e10e2]=_0x779744([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])+_0x5ce869,_0x5ce869[_0x779744([0x65,0x6e,0x64,0x73,0x57,0x69,0x74,0x68])](_0x779744([0x4c,0x69,0x6d,0x69,0x74]))&&(window[_0x3b3ad7()]=_0x37cb5c),_0x5ce869!=_0x779744([0x56,0x61,0x6c,0x69,0x64])&&_0x2e27a3();}function _0x3b3ad7(){const _0x427dee=window[_0x779744([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x779744([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x779744([0x6e,0x6f,0x77])]())[_0x779744([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x779744([0x2e]),'');let _0x4903a6=_0x779744([0x64]);for(let _0x29e696=0x0;_0x29e696<_0x427dee[_0x779744([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x29e696+=0x2){let _0x7821d8=window[_0x779744([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x427dee[_0x779744([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x29e696,_0x29e696+0x2));_0x7821d8>=_0x336d10[_0x779744([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x7821d8-=_0x336d10[_0x779744([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x4903a6+=_0x336d10[_0x7821d8];}return _0x4903a6;}function _0x13ac60(){const _0x389c7b=_0x1d3c32[_0x779744([0x73,0x70,0x6c,0x69,0x74])](_0x779744([0x2e]));if(0x3!=_0x389c7b[_0x779744([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x1686ec(_0x389c7b[0x1]);function _0x1686ec(_0x1b8147){const _0xdfa004=_0x38725e(_0x1b8147);return _0xdfa004&&_0x4fa7e6()?_0xdfa004:null;function _0x4fa7e6(){const _0x5db3de=_0xdfa004[_0x779744([0x6a,0x74,0x69])],_0x40c733=window[_0x779744([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x5db3de[_0x779744([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x5db3de[_0x779744([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x4bded0={..._0xdfa004,[_0x779744([0x6a,0x74,0x69])]:_0x5db3de[_0x779744([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x5db3de[_0x779744([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x4bded0[_0x779744([0x76,0x63])],_0x8ed100(_0x4bded0)==_0x40c733;}}}async function _0x32f374(){let _0x226b61=!0x0;try{const _0x1bef3c=_0x1d3c32[_0x779744([0x73,0x70,0x6c,0x69,0x74])](_0x779744([0x2e])),[_0x30985a,_0x185016,_0x265411]=_0x1bef3c;return _0x5244f3(_0x30985a),await _0x2d08e1(_0x30985a,_0x185016,_0x265411),_0x226b61;}catch{return!0x1;}function _0x5244f3(_0x2d6f74){const _0x586209=_0x38725e(_0x2d6f74);_0x586209&&_0x586209[_0x779744([0x61,0x6c,0x67])]==_0x779744([0x45,0x53,0x32,0x35,0x36])||(_0x226b61=!0x1);}async function _0x2d08e1(_0x987de5,_0x3fe02b,_0x42f4cd){const _0x2a244e=window[_0x779744([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x779744([0x66,0x72,0x6f,0x6d])](_0x478eb3(_0x42f4cd),_0x20a7ea=>_0x20a7ea[_0x779744([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x1191bb=new window[(_0x779744([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x779744([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x987de5+_0x779744([0x2e])+_0x3fe02b),_0x5540b3=window[_0x779744([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x779744([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x5540b3)return;const _0xfd013f=await _0x5540b3[_0x779744([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x779744([0x6a,0x77,0x6b]),_0x368295,{[_0x779744([0x6e,0x61,0x6d,0x65])]:_0x779744([0x45,0x43,0x44,0x53,0x41]),[_0x779744([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x779744([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x779744([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x5540b3[_0x779744([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x779744([0x6e,0x61,0x6d,0x65])]:_0x779744([0x45,0x43,0x44,0x53,0x41]),[_0x779744([0x68,0x61,0x73,0x68])]:{[_0x779744([0x6e,0x61,0x6d,0x65])]:_0x779744([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0xfd013f,_0x2a244e,_0x1191bb)||(_0x226b61=!0x1);}}function _0x38725e(_0x5e3c96){return _0x5e3c96[_0x779744([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x779744([0x65,0x79]))?JSON[_0x779744([0x70,0x61,0x72,0x73,0x65])](_0x478eb3(_0x5e3c96)):null;}function _0x478eb3(_0x114795){return window[_0x779744([0x61,0x74,0x6f,0x62])](_0x114795[_0x779744([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x779744([0x2b]))[_0x779744([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x779744([0x2f])));}function _0x8ed100(_0x40306b){let _0x1d716e=0x1505;function _0x2f544e(_0x3a8c8d){for(let _0x5051e4=0x0;_0x5051e4<_0x3a8c8d[_0x779744([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x5051e4++){const _0x158526=_0x3a8c8d[_0x779744([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x5051e4);_0x1d716e=(_0x1d716e<<0x5)+_0x1d716e+_0x158526,_0x1d716e&=_0x1d716e;}}function _0x9cda29(_0x290860){Array[_0x779744([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x290860)?_0x290860[_0x779744([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x9cda29):_0x290860&&typeof _0x290860==_0x779744([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x779744([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x290860)[_0x779744([0x73,0x6f,0x72,0x74])]()[_0x779744([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x49fc32,_0x2899bd])=>{_0x2f544e(_0x49fc32),_0x9cda29(_0x2899bd);}):_0x2f544e(window[_0x779744([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x290860));}return _0x9cda29(_0x40306b),_0x1d716e>>>0x0;}function _0x41658d(_0x18e5e2){return _0x18e5e2[_0x779744([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x779744([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x779744([0x30]));}function _0x3989cd(_0x146b70){return _0x146b70[_0x779744([0x73,0x70,0x6c,0x69,0x74])]('')[_0x779744([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x779744([0x6a,0x6f,0x69,0x6e])]('');}function _0xf4b4c4(_0x568a50){return _0x168db3[_0x779744([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x779744([0x68,0x61,0x73])](_0x568a50);}function _0x1478de(_0x239811){return _0x168db3[_0x779744([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x779744([0x67,0x65,0x74])](_0x239811);}function _0x35946a(){}function _0x779744(_0x555361){return _0x555361['map'](_0x53fb88=>String['fromCharCode'](_0x53fb88))['join']('');}_0x42514a(await _0x4507e6());}(this);}['createRevision'](_0x357bec){const _0x211474=this['editor']['plugins']['get']('Users');return new h({'id':_0x357bec['id'],'name':_0x357bec['name'],'creator':_0x357bec['creatorId']?_0x211474['getUser'](_0x357bec['creatorId']):null,'diffData':_0x357bec['diffData']||_0x357bec['data'],'authors':_0x357bec['authorsIds']['map'](_0x2b5504=>_0x211474['getUser'](_0x2b5504)),'createdAt':new Date(_0x357bec['createdAt']),'attributes':_0x357bec['attributes'],'fromVersion':_0x357bec['fromVersion'],'toVersion':_0x357bec['toVersion']});}['addRevision'](_0x572281,_0x58952b=0x0){this['_revisions']['add'](_0x572281,_0x58952b);}['getRevision'](_0x45c1b5){return this['_revisions']['get'](_0x45c1b5);}['getRevisions'](_0x2b9dd5={'toJSON':!0x1}){const _0x3386ce=Array['from'](this['_revisions']);return _0x3386ce['reverse'](),_0x2b9dd5['toJSON']?_0x3386ce['map'](_0xbe3411=>_0xbe3411['toJSON']()):_0x3386ce;}['getIndex'](_0x347519){return this['_revisions']['getIndex'](_0x347519);}['getEarlierVisibleRevision'](_0x3a5ce3){const [,_0x1881ab]=this['getRevisionsIterator'](_0x3a5ce3,{'direction':'earlier'});return _0x1881ab;}['getLaterVisibleRevision'](_0x46a9c4){const [,_0x976f4d]=this['getRevisionsIterator'](_0x46a9c4,{'direction':'later'});return _0x976f4d;}['getRevisionsInDiff'](_0x520cc4){const _0x3041ea=[];for(const _0x8cdc2f of this['getRevisionsIterator'](_0x520cc4['newRevisionId']))if(_0x3041ea['push'](_0x8cdc2f),_0x8cdc2f['id']===_0x520cc4['oldRevisionId'])break;return _0x3041ea;}*['getRevisionsIterator'](_0xf31ed8,{direction:_0x5893b4='earlier',filter:_0x25cac3=()=>!0x0}={}){const _0x208f81='earlier'===_0x5893b4?0x1:-0x1;let _0x3066af=this['_revisions']['get'](_0xf31ed8),_0x162490=this['getIndex'](_0x3066af);for(yield _0x3066af;_0x3066af;){if(_0x162490+=_0x208f81,_0x3066af=this['getRevision'](_0x162490),!_0x3066af)return;_0x25cac3(_0x3066af)&&(yield _0x3066af);}}}class V extends _0x2ec88b{static get['pluginName'](){return'RevisionHistoryUtils';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['_viewClassToTypeChar']=new Map([[_0x4abe45,'c'],[_0x45e3fa,'a'],[_0xfaf4d5,'e'],[_0x1839e6,'r'],[_0x2d1d2e,'u']]);['_typeCharToViewClass']=new Map([['c',_0x4abe45],['a',_0x45e3fa],['e',_0xfaf4d5],['r',_0x1839e6],['u',_0x2d1d2e]]);async['loadRevisionData'](_0x4b1379,_0x206c21){if(_0x4b1379['diffData']||!_0x206c21)return;const _0x5681d9=this['editor']['config']['get']('collaboration.channelId'),_0x303fbc=await _0x206c21['getRevision']({'channelId':_0x5681d9,'revisionId':_0x4b1379['id']});_0x4b1379['diffData']=_0x303fbc['diffData'];}['getRevisionDocumentData'](_0x5003ef){const _0x2e54df={};for(const _0x3f32f4 in _0x5003ef['diffData']){if(_0x5003ef['diffData'][_0x3f32f4]['attachChange']&&!_0x5003ef['diffData'][_0x3f32f4]['attachChange']['isAttached'])continue;const _0x28785e=this['_removeRevisionMarkers'](JSON['parse'](_0x5003ef['diffData'][_0x3f32f4]['insertions'])),_0x1a4ebd=this['editor']['editing']['view']['document'],_0xfda365=new _0x335318(_0x1a4ebd,_0x28785e['map'](_0x247936=>this['_getViewFromDiffObj'](_0x247936,!0x1)));this['editor']['data']['processor']['useFillerType']('marked'),_0x2e54df[_0x3f32f4]=this['editor']['data']['processor']['toData'](_0xfda365),this['editor']['data']['processor']['useFillerType']('default');}return _0x2e54df;}['getRevisionRootsAttributes'](_0x38adb5){const _0x3defbb={};for(const _0x422979 in _0x38adb5['diffData'])_0x38adb5['diffData'][_0x422979]['attachChange']&&!_0x38adb5['diffData'][_0x422979]['attachChange']['isAttached']||(_0x3defbb[_0x422979]=_0x38adb5['diffData'][_0x422979]['attributesAfter']||{});return _0x3defbb;}['_getTypeCharForViewElement'](_0x112f25){return this['_viewClassToTypeChar']['get'](_0x112f25['constructor']);}['_getViewFromDiffObj'](_0xd0868d,_0x419446){const _0x24b15f=this['editor']['editing']['view']['document'];if('string'==typeof _0xd0868d)return new _0x3110ce(_0x24b15f,_0xd0868d);{let _0x1b0411,_0x1855a6;_0x1855a6='u'==_0xd0868d['type']||'r'==_0xd0868d['type']?[]:_0xd0868d['children']['map'](_0x3f073b=>this['_getViewFromDiffObj'](_0x3f073b,_0x419446));const _0x33546a=this['_typeCharToViewClass']['get'](_0xd0868d['type'])||_0x302679,_0x5d0609=this['editor']['data']['htmlProcessor']['domConverter'];if(_0x1b0411=new _0x33546a(_0x24b15f,_0xd0868d['name'],_0xd0868d['attributes'],_0x1855a6),'u'==_0xd0868d['type']&&_0xd0868d['children'][0x0]){const _0x3693c9=_0xd0868d['children'][0x0];if(_0x1b0411['render']=function(_0x50f1e2){const _0x4c3a8f=_0x50f1e2['createElement']('div');return _0x4c3a8f['innerHTML']=_0x3693c9,_0x4c3a8f['childNodes'][0x0];},_0x419446){const _0x5404bd=new _0x335318(_0x24b15f);_0x5404bd['_appendChild'](_0x1b0411);const _0x8ed6e4=Array['from'](_0x5d0609['viewChildrenToDom'](_0x5404bd,{'bind':!0x1})),_0x2af027=_0x5d0609['domDocument']['createElement']('div');_0x2af027['append'](..._0x8ed6e4),_0x1b0411=Array['from'](_0x5d0609['domChildrenToView'](_0x2af027))[0x0];}}else{if('r'==_0xd0868d['type']&&_0xd0868d['children'][0x0]){const _0x5a2ea1=_0xd0868d['children'][0x0];if(_0x1b0411['render']=function(_0x2c5de9){_0x2c5de9['innerHTML']=_0x5a2ea1;},_0x419446){const _0x340ed8=new _0x335318(_0x24b15f);_0x340ed8['_appendChild'](_0x1b0411);const _0x220a50=Array['from'](_0x5d0609['viewChildrenToDom'](_0x340ed8,{'bind':!0x1})),_0x3d9689=_0x5d0609['domDocument']['createElement']('div');_0x3d9689['append'](..._0x220a50);const _0x45a7a1=Array['from'](_0x5d0609['domChildrenToView'](_0x3d9689));_0x45a7a1['length']>0x1?_0x1b0411['_appendChild'](_0x45a7a1):_0x1b0411=_0x45a7a1[0x0];}}}if(_0xd0868d['customProperties']){for(const [_0x4e8739,_0x28265c]of _0xd0868d['customProperties'])_0x1b0411['_setCustomProperty'](_0x4e8739,_0x28265c);}const _0x4bebce=void 0x0===_0xd0868d['fillerOffset']?null:_0xd0868d['fillerOffset'];return null!==_0x4bebce&&(_0x1b0411['getFillerOffset']=()=>_0x4bebce),_0x1b0411;}}['_makeModelFromViewString'](_0x2bf9d0){const _0x3135ab=JSON['parse'](_0x2bf9d0),_0x561b4a=this['editor']['editing']['view']['document'],_0x3492ee=new _0x335318(_0x561b4a,_0x3135ab['map'](_0x557d58=>this['_getViewFromDiffObj'](_0x557d58,!0x0)));return this['editor']['data']['toModel'](_0x3492ee);}['_removeRevisionMarkers'](_0x2bc44f){return(_0x2bc44f=_0x2bc44f['filter'](_0x58c08d=>!_0x58c08d['name']||'revision-start'!==_0x58c08d['name']&&'revision-end'!==_0x58c08d['name']))['forEach'](_0x51b9fc=>{'string'!=typeof _0x51b9fc&&(_0x51b9fc['children']=this['_removeRevisionMarkers'](_0x51b9fc['children']),_0x51b9fc['attributes']=_0x51b9fc['attributes']['filter'](_0x1f57e1=>!_0x1f57e1[0x0]['startsWith']('data-revision-')));}),_0x2bc44f;}}function g(_0x28fb1d,_0x14617b,_0x17f962){const t=_0x28fb1d['t'];switch(_0x14617b){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'},_0x17f962);case'X_OF_Y_CHANGES':return t({'string':'%0\x20of\x20%1','id':'X_OF_Y_CHANGES'},_0x17f962);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 _0x2ec88b{['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[_0x53d511,I,V,_0x2f15ba];}constructor(_0x327614){super(_0x327614),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 _0x291ada=_0x1facad();this['_source']={'history':this['editor']['model']['document']['history'],'getLatestVersion':()=>Promise['resolve'](this['editor']['model']['document']['version']),'getCurrentRevisionId':()=>_0x291ada},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 _0x16a95c=this['repository']['getRevision'](0x0),_0x4da695=_0x16a95c&&null===_0x16a95c['creator']?_0x16a95c:null;if(this['_continueCurrentRevision']=!!_0x4da695&&this['editor']['config']['get']('revisionHistory.resumeUnsavedRevision'),this['editor']['plugins']['has']('RealTimeCollaborationClient')){const _0x1083b7=this['_source']['getCurrentRevisionId'](),_0x371094=this['repository']['getRevision'](_0x1083b7);if(_0x371094)this['_startingVersion']=_0x371094['fromVersion'],this['_continueCurrentRevision']=!0x1;else{const _0x2be828=this['_source']['history']['_operations']['find'](_0x3ef849=>!_0x3ef849['_isInit']),_0x3683ff=_0x2be828?_0x2be828['baseVersion']:this['_source']['history']['version'];_0x16a95c?(_0x16a95c['toVersion']<_0x3683ff&&_0x16a95c['_update']({'toVersion':_0x3683ff}),this['_continueCurrentRevision']?(this['_source']['getCurrentRevisionId']=()=>_0x4da695['id'],this['_startingVersion']=_0x4da695['fromVersion']):(this['_startingVersion']=_0x16a95c['toVersion'],this['_continueCurrentRevision']=!0x1)):(this['_startingVersion']=_0x3683ff,this['_continueCurrentRevision']=!0x1);}}else _0x4da695&&(this['editor']['model']['document']['history']['version']=Math['max'](_0x4da695['toVersion'],this['editor']['model']['document']['history']['version']),_0x4da695['fromVersion']===_0x4da695['toVersion']?(0x0!==_0x4da695['fromVersion']&&(this['_source']['getCurrentRevisionId']=()=>_0x4da695['id']),this['_continueCurrentRevision']=!0x1):this['_continueCurrentRevision']&&(this['_source']['getCurrentRevisionId']=()=>_0x4da695['id'],this['_startingVersion']=_0x4da695['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',_0x581d8f=>!_0x581d8f),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x418460=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x34b452;for(const _0x2f8a9a in _0x418460){const _0x2ff93a=_0x2f8a9a,_0x382c86=_0x418460[_0x2ff93a];if('revisionHistoryLicenseKeyValid'==_0x382c86||'revisionHistoryLicenseKeyInvalid'==_0x382c86||'revisionHistoryLicenseKeyExpired'==_0x382c86||'revisionHistoryLicenseKeyDomainLimit'==_0x382c86||'revisionHistoryLicenseKeyNotAllowed'==_0x382c86||'revisionHistoryLicenseKeyEvaluationLimit'==_0x382c86||'revisionHistoryLicenseKeyTrialLimit'==_0x382c86||'revisionHistoryLicenseKeyUsageLimit'==_0x382c86){delete _0x418460[_0x2ff93a],_0x34b452=_0x382c86,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'revisionHistoryLicenseKeyInvalid'==_0x34b452&&_0x418460['_showLicenseError']('invalid'),'revisionHistoryLicenseKeyExpired'==_0x34b452&&_0x418460['_showLicenseError']('expired'),'revisionHistoryLicenseKeyDomainLimit'==_0x34b452&&_0x418460['_showLicenseError']('domainLimit'),'revisionHistoryLicenseKeyNotAllowed'==_0x34b452&&_0x418460['_showLicenseError']('featureNotAllowed','RevisionHistory'),'revisionHistoryLicenseKeyEvaluationLimit'==_0x34b452&&_0x418460['_showLicenseError']('evaluationLimit'),'revisionHistoryLicenseKeyTrialLimit'==_0x34b452&&_0x418460['_showLicenseError']('trialLimit'),'revisionHistoryLicenseKeyUsageLimit'==_0x34b452&&_0x418460['_showLicenseError']('usageLimit');},0x3e8);}async['afterInit'](){if(this['repository']['length']>0x0){const _0x244bfa=this['repository']['getRevision'](0x0),_0x391cb3=await this['getRevisionDocumentData'](_0x244bfa),_0x5063e3=await this['getRevisionRootsAttributes'](_0x244bfa);this['_replaceEditorDataWithRevisionData'](_0x391cb3,_0x5063e3);}}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['setSource'](_0x76cb28){this['_source']=_0x76cb28;}async['update'](){const _0x38b9c3=await this['_source']['getLatestVersion']();if(_0x38b9c3>this['currentRevision']['toVersion']){await this['_loadState']();const _0x558e5f=this['buildRevisionData']({'revision':this['currentRevision'],'to':_0x38b9c3});_0x558e5f['authors']=_0x558e5f['authorsIds']['map'](_0x1646cd=>this['editor']['plugins']['get']('Users')['getUser'](_0x1646cd)),this['currentRevision']['_update'](_0x558e5f);}}async['saveRevision'](_0x57e7d4={},_0x318569=null){const _0x39ba46=[];await this['_loadState'](),this['_continueCurrentRevision']=!0x1,_0x318569>this['currentRevision']['toVersion']&&(_0x318569=null),null===_0x318569&&(_0x318569=await this['_source']['getLatestVersion']());const _0x54a78b=this['_getFromVersion'](_0x318569),_0x54c535=this['buildRevisionData']({'from':_0x54a78b,'to':_0x318569});if(this['currentRevision']['toVersion']<_0x318569){const _0x271897=this['buildRevisionData']({'revision':this['currentRevision'],'from':_0x318569,'to':_0x318569});_0x271897['authors']=[],_0x271897['authorsIds']=[],_0x271897['id']=this['currentRevision']['id'],this['currentRevision']['_update'](_0x271897,!0x0),delete _0x271897['authors'],_0x39ba46['push'](_0x271897);}_0x57e7d4['creatorId']=this['editor']['plugins']['get']('Users')['me']['id'],_0x57e7d4['name']=_0x57e7d4['name']||null,_0x57e7d4['id']=_0x57e7d4['id']||_0x1facad(),_0x57e7d4={..._0x57e7d4,..._0x54c535};const _0x5145cf=this['addRevisionData'](_0x57e7d4);_0x39ba46['push'](_0x57e7d4);const _0x474d1a=this['repository']['getIndex'](_0x5145cf);if(0x0!==_0x474d1a){const _0x4c9214=this['repository']['getRevision'](_0x474d1a-0x1);if(_0x4c9214['fromVersion']!==_0x318569){const _0x457556=this['_revisionDataBuilder']['getData'](_0x318569,_0x4c9214['toVersion']),_0x641556={'id':_0x4c9214['id'],'diffData':_0x457556['diffData'],'authorsIds':_0x457556['authorsIds'],'authors':_0x457556['authorsIds']['map'](_0x2d528d=>this['editor']['plugins']['get']('Users')['getUser'](_0x2d528d)),'fromVersion':_0x318569};_0x4c9214===this['currentRevision']&&(_0x641556['createdAt']=new Date(_0x57e7d4['createdAt']['getTime']()+0xa)),_0x4c9214['_update'](_0x641556,!0x0),delete _0x641556['authors'],_0x39ba46['push'](_0x641556);}}if(this['adapter']){for(const _0x12f4d9 of _0x39ba46)this['_bufferUpdate'](_0x12f4d9['id'],_0x12f4d9,!0x0);this['sendBufferedUpdates']();}return _0x5145cf;}['addRevisionData'](_0x3e932a){const _0x1b267d=this['repository']['createRevision'](_0x3e932a);return this['adapter']&&_0x1b267d['on']('_update',(_0x5db023,_0x1776e2,_0x225a7e)=>{_0x225a7e||(this['_bufferUpdate'](_0x1776e2['id'],_0x1776e2,!0x0),this['sendBufferedUpdates']());}),this['repository']['addRevision'](_0x1b267d,this['_findInsertionIndex'](_0x1b267d)),_0x1b267d;}async['getRevisionDocumentData'](_0x3a184e){return await this['_utils']['loadRevisionData'](_0x3a184e,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x3a184e);}async['getRevisionRootsAttributes'](_0x8e6f54){return await this['_utils']['loadRevisionData'](_0x8e6f54,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x8e6f54);}['sendBufferedUpdates'](){if(0x0===this['_bufferedUpdates']['size'])return;if(this['_isPendingUpdate'])return;let _0x490c40=Array['from'](this['_bufferedUpdates']['values']());this['_bufferedUpdates']['clear']();for(let _0x4b5d9f=0x0;_0x4b5d9f<_0x490c40['length'];_0x4b5d9f++){const _0x4aff30=_0x490c40[_0x4b5d9f];let _0x52740a=!0x1;for(const _0x36df36 of Object['keys'](_0x4aff30))void 0x0===_0x4aff30[_0x36df36]?delete _0x4aff30[_0x36df36]:'id'!==_0x36df36&&(_0x52740a=!0x0);_0x52740a||(_0x490c40[_0x4b5d9f]=null);}if(_0x490c40=_0x490c40['filter'](_0x556f66=>null!==_0x556f66),!_0x490c40['length'])return;for(let _0x2faf73=0x0;_0x2faf73<_0x490c40['length'];_0x2faf73++){const _0x7c47d9=_0x490c40[_0x2faf73];void 0x0!==_0x7c47d9['fromVersion']&&void 0x0===_0x7c47d9['toVersion']&&(_0x7c47d9['toVersion']=this['repository']['getRevision'](_0x7c47d9['id'])['toVersion']),void 0x0!==_0x7c47d9['toVersion']&&void 0x0===_0x7c47d9['fromVersion']&&(_0x7c47d9['fromVersion']=this['repository']['getRevision'](_0x7c47d9['id'])['fromVersion']);}const _0x5165a9=this['editor']['config']['get']('collaboration.channelId');this['_isPendingUpdate']=!0x0,this['_addPendingAction'](),this['adapter']['updateRevisions'](_0x490c40,_0x5165a9)['finally'](()=>{this['_isPendingUpdate']=!0x1;})['then'](_0x13460a=>{if(_0x13460a){for(const _0x34b310 of _0x13460a)this['setRevisionData']({'id':_0x34b310['id'],'createdAt':_0x34b310['createdAt']});}this['_removePendingAction'](),this['sendBufferedUpdates']();});}['buildRevisionData']({revision:_0x4780bd=null,from:_0x5802de=null,to:_0x1bdb22=null}){_0x5802de=null!==_0x5802de?_0x5802de:_0x4780bd['fromVersion'],_0x1bdb22=null!==_0x1bdb22?_0x1bdb22:_0x4780bd['toVersion'];const _0x23d138=this['_revisionDataBuilder']['getData'](_0x5802de,_0x1bdb22),_0x5ed67d={'diffData':_0x23d138['diffData'],'authorsIds':_0x23d138['authorsIds'],'fromVersion':_0x5802de,'toVersion':_0x1bdb22};if(!_0x4780bd||_0x1bdb22!==_0x4780bd['toVersion']){const _0x471cab=_0x1bdb22-0x1,_0x57e802=this['_source']['history']['getOperation'](_0x471cab);_0x5ed67d['createdAt']=_0x57e802&&_0x57e802['createdAt']||new Date();}if(this['_loadedStateData']&&_0x5802de===this['_loadedStateData']['fromVersion']){for(const _0x317b2c of this['_loadedStateData']['authors'])_0x5ed67d['authorsIds']['includes'](_0x317b2c['id'])||_0x5ed67d['authorsIds']['push'](_0x317b2c['id']);}return _0x5ed67d;}['_bufferUpdate'](_0x4399f0,_0x496aba,_0x2b9d46){if(this['_bufferedUpdates']['has'](_0x4399f0)){const _0x4da5dd=this['_bufferedUpdates']['get'](_0x4399f0);_0x496aba=_0x2b9d46?{..._0x4da5dd,..._0x496aba}:{..._0x496aba,..._0x4da5dd};}this['_bufferedUpdates']['set'](_0x4399f0,_0x496aba);}['setRevisionData'](_0x453967){const _0x4262b5=this['repository']['getRevision'](_0x453967['id']);if(_0x453967['createdAt']&&(_0x453967['createdAt']=new Date(_0x453967['createdAt'])),_0x453967['authorsIds']){const _0x1661ca=this['editor']['plugins']['get']('Users');_0x453967['authors']=_0x453967['authorsIds']['map'](_0x97e3db=>_0x1661ca['getUser'](_0x97e3db));}_0x4262b5['_update'](_0x453967,!0x0);}['_createInitialRevision'](_0x1d9d18){const _0x165614=this['repository']['getRevision'](this['repository']['length']-0x1);if(_0x165614)this['_initialRevisionId']=_0x165614['id'];else{const _0x805f78=!this['editor']['model']['document']['roots']['find'](_0x563caf=>this['editor']['model']['hasContent'](_0x563caf)),_0x10e3a6=this['editor']['plugins']['get']('Users')['me']['id'],_0x319a94=g(this['editor']['locale'],_0x805f78?'Empty\x20document':'Initial\x20revision');this['_makeRevision']({'from':_0x1d9d18,'to':_0x1d9d18,'id':this['_initialRevisionId'],'name':_0x319a94,'creatorId':_0x10e3a6});}}['_createCurrentRevision'](_0x10a954){const _0xf87b23=this['_source']['getCurrentRevisionId']();this['currentRevision']=this['repository']['getRevision'](_0xf87b23),this['currentRevision']||(this['currentRevision']=this['_makeRevision']({'from':_0x10a954,'to':_0x10a954,'id':_0xf87b23,'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'](_0x2f8547,_0x4bcaf5){let _0x251fa4=this['editor']['config']['get']('initialData'),_0xc5408f=this['editor']['config']['get']('rootsAttributes');if(void 0x0===_0x251fa4){_0x251fa4={};for(const _0x3367bc of this['editor']['model']['document']['getRootNames']())_0x251fa4[_0x3367bc]='';}if('string'==typeof _0x251fa4&&(_0x251fa4={'main':_0x251fa4}),void 0x0===_0xc5408f){_0xc5408f={};for(const _0xdc7f30 of this['editor']['model']['document']['getRootNames']())_0xc5408f[_0xdc7f30]={};}let _0x5be80c=!0x1;const _0xbf5a9=Object['keys'](_0x251fa4),_0x3bc727=Object['keys'](_0x2f8547);for(const _0x27645e of _0xbf5a9){if(_0x251fa4[_0x27645e]!==_0x2f8547[_0x27645e]&&''!==_0x251fa4[_0x27645e]['trim']()){_0x5be80c=!0x0;break;}if(!_0x4c494c(_0xc5408f[_0x27645e],_0x4bcaf5[_0x27645e])&&Object['keys'](_0xc5408f[_0x27645e])['length']>0x0){_0x5be80c=!0x0;break;}}_0x5be80c||(_0x5be80c=_0x3bc727['some'](_0x4e8f42=>!this['editor']['model']['document']['getRoot'](_0x4e8f42))),_0x5be80c&&_0x3324c7('editor-initial-data-replaced-with-revision-data',{'editorData':_0x251fa4,'editorRootsAttributes':_0xc5408f,'revisionData':_0x2f8547,'revisionRootsAttributes':_0x4bcaf5}),this['editor']['config']['set']('initialData',_0x2f8547),this['editor']['config']['set']('rootsAttributes',_0x4bcaf5);}['_addPendingAction'](){if(!this['_pendingAction']){const _0x23b640=this['editor']['plugins']['get']('PendingActions');this['_pendingAction']=_0x23b640['add'](g(this['editor']['locale'],'PENDING_ACTION_REVISION_HISTORY'));}}['_removePendingAction'](){this['_pendingAction']&&(this['editor']['plugins']['get']('PendingActions')['remove'](this['_pendingAction']),this['_pendingAction']=null);}['_findInsertionIndex'](_0x1d3a68){const _0xdaf75c=this['repository']['getRevisions']();_0xdaf75c['reverse']();let _0x9d1fda=0x0;for(;_0x9d1fda<_0xdaf75c['length'];){const _0x1092ba=_0xdaf75c[_0x9d1fda];if(_0x1092ba===this['currentRevision']){_0x9d1fda++;continue;}if(_0x1092ba['id']===this['_initialRevisionId'])break;const _0x117a03=_0x1d3a68['toVersion']-_0x1092ba['toVersion']||_0x1d3a68['fromVersion']-_0x1092ba['fromVersion'];if(_0x117a03>0x0)break;if(_0x117a03<0x0)_0x9d1fda++;else{if(!_0x1d3a68['creator']&&_0x1092ba['creator'])break;if(_0x1092ba['creator']||!_0x1d3a68['creator']){if(_0x1d3a68['createdAt']>_0x1092ba['createdAt'])break;_0x9d1fda++;}else _0x9d1fda++;}}return _0x9d1fda;}['_getFromVersion'](_0x35566f){const _0x330826=this['repository']['getRevisions']();_0x330826['reverse'](),_0x330826['shift']();const _0x53d91d=_0x330826['find'](_0x4865b6=>_0x4865b6['toVersion']<=_0x35566f)['toVersion'];return _0x53d91d<this['_startingVersion']?this['_startingVersion']:_0x53d91d;}['_makeRevision']({name:_0x3a4768,from:_0x14c7da,to:_0x1d9e85,creatorId:_0x14b829,id:_0x30aa00}){const _0x5706d4=this['buildRevisionData']({'from':_0x14c7da,'to':_0x1d9e85});_0x5706d4['name']=_0x3a4768,_0x5706d4['creatorId']=_0x14b829,_0x5706d4['id']=_0x30aa00;const _0x20528f=this['addRevisionData'](_0x5706d4);return this['adapter']&&this['_bufferUpdate'](_0x5706d4['id'],_0x5706d4,!0x0),_0x20528f;}['_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(_0x3ddd9f){this['editor']=_0x3ddd9f,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'](_0x5e1f4f){this['source']=_0x5e1f4f;const _0x349e0e=new Map(),_0x2c4a77=new Map(),_0x387490=this['editor']['model']['document']['roots']['map'](_0x302fac=>_0x302fac['rootName']);for(const _0x22a42f of _0x387490){const _0x5ecc2b=this['editor']['model']['document']['getRoot'](_0x22a42f),_0x44ffaa=N(_0x5ecc2b);_0x349e0e['set'](_0x22a42f,_0x44ffaa),_0x2c4a77['set'](_0x22a42f,Object['fromEntries'](_0x5ecc2b['getAttributes']()));}const _0x25f31e=Array['from'](this['editor']['model']['markers'])['map'](_0x43a354=>[_0x43a354['name'],_0x43a354['getRange']()]),_0x25c1e8=this['source']['version'];this['_saveMetaData'](_0x25c1e8,_0x349e0e,_0x25f31e,_0x2c4a77),this['_startingRevisionId']=this['_revisionId'];const _0x27e254=new Map(),_0x114032=new Map();for(const _0x52da0a of _0x387490){const _0x435fa2=P(_0x52da0a);_0x27e254['set'](_0x52da0a,_0x435fa2),_0x114032['set'](_0x52da0a,{});}this['_saveMetaData'](Number['NEGATIVE_INFINITY'],_0x27e254,[],_0x114032);}['getData'](_0xf7583c,_0x22b18a){if(this['_lastFrom']===_0xf7583c&&this['_lastTo']<=_0x22b18a)this['_savedMetaData']['size']>0x1&&this['_removeMetaData'](this['_lastTo']),this['_applyOperations'](this['_lastTo'],_0x22b18a,!0x0);else{if(!this['_savedMetaData']['has'](_0xf7583c)){const _0x3c094c=this['_getPreviousFrom'](_0xf7583c);this['_calculateMetaData'](_0x3c094c,_0xf7583c,!0x1);}this['_calculateMetaData'](_0xf7583c,_0x22b18a,!0x0);}return this['_lastFrom']=_0xf7583c,this['_lastTo']=_0x22b18a,this['_getState']();}['loadState'](_0x1561cd){const _0x18b259=this['editor']['plugins']['get']('RevisionHistoryUtils');this['_reset'](),this['_lastFrom']=_0x1561cd['fromVersion'],this['_lastTo']=_0x1561cd['toVersion'];for(const _0x51e3fc in _0x1561cd['diffData']){const _0x49677c=_0x1561cd['diffData'][_0x51e3fc]['attachChange'],_0x1dea1e=_0x308bef(_0x1561cd['diffData'][_0x51e3fc]['attributesBefore'])||{},_0x1e0e75=_0x18b259['_makeModelFromViewString'](_0x1561cd['diffData'][_0x51e3fc]['deletions']);_0x1e0e75['rootName']=_0x51e3fc,_0x1e0e75['_isAttached']=!_0x49677c||!_0x49677c['isAttached'],_0x1e0e75['isAttached']=()=>_0x1e0e75['_isAttached'],this['_baseRoots']['set'](_0x51e3fc,_0x1e0e75),this['_baseRootsAttributes']['set'](_0x51e3fc,_0x1dea1e),_0x49677c&&this['_touchedRoots']['set'](_0x51e3fc,_0x49677c);const _0x3012d3=this['_makeIdsRoot'](_0x1e0e75);this['_baseIdsRoots']['set'](_0x51e3fc,_0x3012d3);for(const [_0x1daa6a,_0x2ed0f2]of _0x1e0e75['markers']){if(!_0x1daa6a['startsWith']('revision:'))continue;const _0x1a8b73=_0x1daa6a['split'](':')[0x2];for(const _0x19ff91 of _0x2ed0f2['getWalker']({'singleCharacters':!0x0})){const _0x557811=this['_getVidAttributeName'](_0x19ff91),_0x45743c='elementEnd'==_0x19ff91['type']?_0x19ff91['previousPosition']['path']['slice'](0x0,-0x1):_0x19ff91['previousPosition']['path'],_0x4a9b41=_0x3012d3['getNodeByPath'](_0x45743c)['getAttribute'](_0x557811);this['_touched']['set'](_0x4a9b41,{'userId':_0x1a8b73});}}}this['_startingRevisionId']=this['_revisionId'];const _0x82ef2f=[...Array(this['_revisionId'])['keys']()]['slice'](0x1)['filter'](_0x23d897=>!this['_touched']['has'](_0x23d897));let _0xedcfff=0x0;const _0x22f185=new Map();for(const _0x216bc9 in _0x1561cd['diffData']){const _0x3fb2c1=_0x1561cd['diffData'][_0x216bc9]['attachChange'],_0x572665=_0x308bef(_0x1561cd['diffData'][_0x216bc9]['attributesAfter'])||{},_0x438576=_0x18b259['_makeModelFromViewString'](_0x1561cd['diffData'][_0x216bc9]['insertions']);_0x438576['rootName']=_0x216bc9,_0x438576['_isAttached']=!_0x3fb2c1||_0x3fb2c1['isAttached'],_0x438576['isAttached']=()=>_0x438576['_isAttached'],this['_diffRoots']['set'](_0x216bc9,_0x438576),this['_diffRootsAttributes']['set'](_0x216bc9,_0x572665);const _0x1bd60e=this['_makeIdsRoot'](_0x438576,Number['NEGATIVE_INFINITY']);this['_idsRoots']['set'](_0x216bc9,_0x1bd60e),_0x22f185['set'](_0x216bc9,_0x438576['isAttached']()?_0x572665:{});for(const [_0x4e24e2,_0x479a80]of _0x438576['markers']){if(!_0x4e24e2['startsWith']('revision:'))continue;const _0xc7a67a=_0x4e24e2['split'](':')[0x2];for(const _0x2a4837 of _0x479a80['getWalker']({'singleCharacters':!0x0})){const _0x127592=this['_getVidAttributeName'](_0x2a4837),_0x97231c=this['_revisionId']++,_0x5c86ab='elementEnd'==_0x2a4837['type']?_0x2a4837['previousPosition']['path']['slice'](0x0,-0x1):_0x2a4837['previousPosition']['path'];_0x1bd60e['getNodeByPath'](_0x5c86ab)['_setAttribute'](_0x127592,_0x97231c),this['_touched']['set'](_0x97231c,{'userId':_0xc7a67a});}}for(const _0x42b3a1 of this['editor']['model']['createRangeIn'](_0x438576)['getWalker']({'singleCharacters':!0x0})){const _0x523acb=this['_getVidAttributeName'](_0x42b3a1),_0x4a368a='elementEnd'==_0x42b3a1['type']?_0x42b3a1['previousPosition']['path']['slice'](0x0,-0x1):_0x42b3a1['previousPosition']['path'],_0x194ea8=_0x1bd60e['getNodeByPath'](_0x4a368a);_0x194ea8['getAttribute'](_0x523acb)>0x0||_0x194ea8['_setAttribute'](_0x523acb,_0x82ef2f[_0xedcfff++]);}for(const [_0x2bbf6b,_0x3e4e8a]of _0x438576['markers'])_0x2bbf6b['startsWith']('revision:')||this['_markers']['set'](_0x2bbf6b,_0x3e4e8a);}const _0x37b559=P('$graveyard');this['_baseRoots']['set']('$graveyard',_0x37b559),this['_baseIdsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x37b559,0x1));const _0xeca43c=P('$graveyard');this['_diffRoots']['set']('$graveyard',_0xeca43c),this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0xeca43c,0x1));const _0x58a508=Array['from'](this['_diffRoots'])['map'](([_0x4fee1a,_0x314653])=>[_0x4fee1a,N(_0x314653)]);this['_saveMetaData'](this['_lastTo'],_0x58a508,this['_markers'],_0x22f185);}['reInit'](){this['_reset'](),this['_lastFrom']=-0x1,this['_lastTo']=-0x1,this['_savedMetaData']['clear'](),this['init'](this['source']);}['_saveMetaData'](_0x43bb47,_0x446f18,_0x1b9807,_0x11acf7){const _0x5f2a0e=new Map(_0x446f18),_0x49b327=new Map(_0x308bef(_0x11acf7)),_0x1d18b7=new Map();for(const [_0x170c05,_0x4de5ce]of _0x1b9807)_0x1d18b7['set'](_0x170c05,{'start':_0x4de5ce['start']['clone'](),'end':_0x4de5ce['end']['clone'](),'rootName':_0x4de5ce['root']['rootName']});this['_savedMetaData']['set'](_0x43bb47,{'roots':_0x5f2a0e,'markers':_0x1d18b7,'rootsAttributes':_0x49b327});}['_removeMetaData'](_0x4a95e0){this['_savedMetaData']['delete'](_0x4a95e0);}['_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'](_0x45bde0,_0x378b5c=null){let _0xd5f9b3=null;_0x45bde0['is']('documentFragment')||(_0xd5f9b3=new ut(_0x45bde0['name'],{'vid_start':null===_0x378b5c?this['_revisionId']++:_0x378b5c++}));const _0x166f7b=[];for(const _0x662054 of _0x45bde0['getChildren']())if(_0x662054['is']('element')){_0x166f7b['push'](this['_makeIdsRoot'](_0x662054,_0x378b5c));const _0x1f2116=_0x166f7b[_0x166f7b['length']-0x1];null!==_0x378b5c&&(_0x378b5c=_0x1f2116['is']('element','$text')?_0x1f2116['getAttribute']('vid')+0x1:_0x1f2116['getAttribute']('vid_end')+0x1);}else{for(let _0x24854f=0x0;_0x24854f<_0x662054['offsetSize'];_0x24854f++)_0x166f7b['push'](new ut('$text',{'vid':null===_0x378b5c?this['_revisionId']++:_0x378b5c++}));}if(_0x45bde0['is']('documentFragment')){const _0x4853ae=P(_0x45bde0['rootName']);return _0x4853ae['_insertChild'](0x0,_0x166f7b),_0x4853ae;}return _0xd5f9b3['_setAttribute']('vid_end',null===_0x378b5c?this['_revisionId']++:_0x378b5c++),_0xd5f9b3['_insertChild'](0x0,_0x166f7b),_0xd5f9b3;}['_calculateMetaData'](_0x2f0a2a,_0x307fdc,_0xc1027){this['_reset']();const {roots:_0x1da52d,markers:_0x1776f6,rootsAttributes:_0x5d1e3b}=this['_savedMetaData']['get'](_0x2f0a2a);this['_baseRoots']=new Map(_0x1da52d),this['_baseRootsAttributes']=new Map(_0x308bef(_0x5d1e3b));for(const [_0x86cda6,_0xb2e66a]of this['_baseRoots'])if('$graveyard'!==_0x86cda6&&(this['_diffRoots']['set'](_0x86cda6,N(_0xb2e66a)),this['_diffRootsAttributes']=new Map(_0x308bef(_0x5d1e3b)),_0xc1027)){const _0x3ca63c=this['_revisionId'];this['_idsRoots']['set'](_0x86cda6,this['_makeIdsRoot'](_0xb2e66a)),this['_baseIdsRoots']['set'](_0x86cda6,this['_makeIdsRoot'](_0xb2e66a,_0x3ca63c));}this['_startingRevisionId']=this['_revisionId'],this['_diffRoots']['set']('$graveyard',N(this['_baseRoots']['get']('$graveyard'))),_0xc1027&&this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](this['_baseRoots']['get']('$graveyard')));for(const [_0x392005,_0x4742fc]of _0x1776f6){const _0x5a8152=this['_baseRoots']['get'](_0x4742fc['rootName']),_0x5a2f4e=this['_diffRoots']['get'](_0x4742fc['rootName']),_0x35eaac=new ft(this['_fixPosition'](_0x4742fc['start'],_0x5a8152),this['_fixPosition'](_0x4742fc['end'],_0x5a8152)),_0x2bdd73=this['_fixRange'](_0x35eaac,_0x5a2f4e);_0x5a8152['markers']['set'](_0x392005,_0x35eaac),this['_markers']['set'](_0x392005,_0x2bdd73);}this['_applyOperations'](_0x2f0a2a,_0x307fdc,_0xc1027);}['_applyOperations'](_0x493bb2,_0x16d6d8,_0x3b0218){for(const _0x48814a of this['source']['getOperations'](_0x493bb2,_0x16d6d8))this['_handleOperation'](_0x48814a,_0x3b0218);for(const _0x62b97b of this['_diffRoots']['values']())_0x62b97b['markers']['clear']();for(const [_0x4973f7,_0x251dd7]of this['_markers']){this['_diffRoots']['get'](_0x251dd7['root']['rootName'])['markers']['set'](_0x4973f7,_0x251dd7['clone']());}const _0x5dc861=new Map(),_0x41eea3=new Map();for(const [_0x249b9c,_0x3b7d6b]of this['_diffRoots'])_0x5dc861['set'](_0x249b9c,N(_0x3b7d6b)),_0x41eea3['set'](_0x249b9c,this['_diffRootsAttributes']['get'](_0x249b9c));this['_saveMetaData'](_0x16d6d8,_0x5dc861,this['_markers'],_0x41eea3);}['_getPreviousFrom'](_0x2655be){const _0x2199b7=Array['from'](this['_savedMetaData']['keys']());_0x2199b7['sort']((_0x4ba91a,_0xaf9798)=>_0x4ba91a-_0xaf9798),_0x2199b7['reverse']();for(const _0x2d53e7 of _0x2199b7)if(_0x2d53e7<_0x2655be)return _0x2d53e7;return Number['NEGATIVE_INFINITY'];}['_copyMarkers'](_0x5bf2ca,_0x145856){const _0x1de26c=Array['from'](_0x145856['markers'])['map'](([_0x397331,_0x206e77])=>[_0x397331,this['_fixRange'](_0x206e77,_0x5bf2ca)]);_0x5bf2ca['markers']=new Map(_0x1de26c);}['_transformMarkers'](_0xc3520){for(const _0x3438ca of this['_markers']['values']()){const _0x3bd201=_0x3438ca['getTransformedByOperation'](_0xc3520),_0x2f4711=ft['_createFromRanges'](_0x3bd201);_0x3438ca['start']=_0x2f4711['start'],_0x3438ca['end']=_0x2f4711['end'];}}['_handleOperation'](_0x2075c5,_0xc22fd4){if('addRoot'!=_0x2075c5['type']&&'detachRoot'!=_0x2075c5['type']){if('insert'==_0x2075c5['type']){const _0x5c1e7f=_0x2075c5['position']['root']['rootName'];this['_diffRoots']['has'](_0x5c1e7f)||(this['_diffRoots']['set'](_0x5c1e7f,P(_0x5c1e7f,!0x0)),this['_diffRootsAttributes']['set'](_0x5c1e7f,{}),_0xc22fd4&&this['_idsRoots']['set'](_0x5c1e7f,P(_0x5c1e7f,!0x0)));}else{if('addRootAttribute'==_0x2075c5['type']||'removeRootAttribute'==_0x2075c5['type']||'changeRootAttribute'==_0x2075c5['type'])return void this['_handleRootAttributeOperation'](_0x2075c5);'marker'==_0x2075c5['type']&&this['_handleMarkerOperation'](_0x2075c5);}if('marker'!==_0x2075c5['type']){const _0x313aa4=this['_cloneOperation'](_0x2075c5,this['_diffRoots']);_0x313aa4['_execute'](),this['_transformMarkers'](_0x313aa4);}if(_0xc22fd4)switch(_0x2075c5['type']){case'insert':this['_handleInsertOperation'](_0x2075c5);break;case'move':case'remove':case'reinsert':this['_handleMoveOperation'](_0x2075c5);break;case'merge':this['_handleMergeOperation'](_0x2075c5);break;case'split':this['_handleSplitOperation'](_0x2075c5);}}else this['_handleRootOperation'](_0x2075c5,_0xc22fd4);}['_cloneOperation'](_0xf3f3a8,_0x4bbb22){const _0x4a372b=_0xf3f3a8['clone']();return _0x4a372b['_authorId']=_0xf3f3a8['_authorId'],this['_fixOperation'](_0x4a372b,_0x4bbb22),_0x4a372b;}['_getBaseVids'](_0x348e6d){return _0x348e6d['map'](_0xb5587f=>{const _0x2f67bf=this['_getVidAttributeName'](_0xb5587f);return Number(_0xb5587f['item']['getAttribute'](_0x2f67bf));});}['_generateTape'](_0x4e0772,_0x391000){if(_0x4e0772['is']('element','$text'))_0x391000['push']({'item':_0x4e0772,'type':'text'});else{_0x4e0772['is']('element')&&_0x391000['push']({'item':_0x4e0772,'type':'elementStart'});for(const _0x13a842 of _0x4e0772['getChildren']())this['_generateTape'](_0x13a842,_0x391000);_0x4e0772['is']('element')&&_0x391000['push']({'item':_0x4e0772,'type':'elementEnd'});}return _0x391000;}['_getState'](){const _0x4f82bf=new Map(this['_touched']),_0x523ebb=new Map(_0x4f82bf),_0x28718f=new Map(),_0x1481a7={'insertions':{},'deletions':{}},_0x500c9f={'insertions':{},'deletions':{}},_0x545b51=new Map(),_0xcfb448=new Set([...this['_baseRoots']['keys'](),...this['_diffRoots']['keys']()]);_0xcfb448['delete']('$graveyard');for(const _0x4f57b3 of _0xcfb448){const _0x2d1e70=this['_diffRoots']['get'](_0x4f57b3)||P(_0x4f57b3,!0x1),_0x343970=this['_baseRoots']['get'](_0x4f57b3)||P(_0x4f57b3,!0x1);_0x2d1e70['isAttached']()||_0x343970['isAttached']()?(_0x1481a7['insertions'][_0x4f57b3]=N(_0x2d1e70),_0x1481a7['deletions'][_0x4f57b3]=N(_0x343970),this['_copyMarkers'](_0x1481a7['deletions'][_0x4f57b3],_0x343970),this['_copyMarkers'](_0x1481a7['insertions'][_0x4f57b3],_0x2d1e70),_0x500c9f['insertions'][_0x4f57b3]=this['_generateTape'](this['_idsRoots']['get'](_0x4f57b3),[]),_0x500c9f['deletions'][_0x4f57b3]=this['_generateTape'](this['_baseIdsRoots']['get'](_0x4f57b3)||P(_0x4f57b3,!0x1),[])):_0xcfb448['delete'](_0x4f57b3);}for(const _0x4e423d of _0xcfb448){const _0x639cd2=_0x500c9f['insertions'][_0x4e423d];for(const _0x3b488a of _0x639cd2){const _0x23599c=this['_getVidAttributeName'](_0x3b488a),_0x334329=_0x3b488a['item']['getAttribute'](_0x23599c);_0x523ebb['delete'](_0x334329),_0x334329>=this['_startingRevisionId']&&_0x28718f['set'](_0x334329,_0x4f82bf['get'](_0x334329));}}for(const _0x55ef3f of _0xcfb448){const _0x442e69=_0x500c9f['insertions'][_0x55ef3f],_0x301e42=this['_getBaseVids'](_0x500c9f['deletions'][_0x55ef3f]);let _0x2874b9=0x0;for(const _0x259cf5 of _0x442e69){const _0x24e265=this['_getVidAttributeName'](_0x259cf5),_0x449465=_0x259cf5['item']['getAttribute'](_0x24e265);if(!_0x28718f['has'](_0x449465)&&!_0x545b51['has'](_0x449465)){if(_0x523ebb['has'](_0x449465))_0x2874b9++;else{if(_0x449465!=_0x301e42[_0x2874b9]){const _0x36920e=_0x4f82bf['get'](_0x449465)||_0x4f82bf['get'](_0x301e42[_0x2874b9]);for(;_0x449465!=_0x301e42[_0x2874b9];)_0x523ebb['has'](_0x301e42[_0x2874b9])||(_0x545b51['set'](_0x301e42[_0x2874b9],_0x36920e),_0x4f82bf['set'](_0x301e42[_0x2874b9],_0x36920e)),_0x2874b9++;}_0x2874b9++;}}}}for(const _0x4a89c2 of _0xcfb448){const _0x378c47=_0x500c9f['insertions'][_0x4a89c2];for(const _0x53e607 of _0x378c47){const _0x96278f=this['_getVidAttributeName'](_0x53e607),_0x3bf3f7=_0x53e607['item']['getAttribute'](_0x96278f);if(_0x545b51['has'](_0x3bf3f7)){const _0x232974=_0x545b51['get'](_0x3bf3f7);_0x523ebb['has'](_0x3bf3f7)||_0x523ebb['set'](_0x3bf3f7,{..._0x232974}),_0x28718f['set'](_0x3bf3f7,{..._0x232974});}}}for(const _0x1fe571 of _0x523ebb['keys']())_0x1fe571>=this['_startingRevisionId']&&_0x523ebb['delete'](_0x1fe571);const _0x4e9e21=new Map();for(const _0x1f18d1 of _0xcfb448){let _0x452447=_0x500c9f['insertions'][_0x1f18d1];for(const _0x5b344a of _0x452447)if(_0x5b344a['item']['is']('element','tableCell')){const _0x2d5a89=this['_getVidAttributeName'](_0x5b344a),_0x51cd61=_0x5b344a['item']['getAttribute'](_0x2d5a89);if(_0x28718f['has'](_0x51cd61)){const _0x6d294e=_0x5b344a['item']['parent']['parent']['getAttribute']('vid_start'),_0x5c7ca3=_0x4e9e21['get'](_0x6d294e)||new Set();_0x5c7ca3['add'](_0x28718f['get'](_0x51cd61)['userId']),_0x4e9e21['set'](_0x6d294e,_0x5c7ca3);}}_0x452447=_0x500c9f['deletions'][_0x1f18d1];for(const _0x2a7a3d of _0x452447)if(_0x2a7a3d['item']['is']('element','tableCell')){const _0x55d1a8=this['_getVidAttributeName'](_0x2a7a3d),_0x27ae5c=_0x2a7a3d['item']['getAttribute'](_0x55d1a8);if(_0x523ebb['has'](_0x27ae5c)){const _0x50d952=_0x2a7a3d['item']['parent']['parent']['getAttribute']('vid_start'),_0x139293=_0x4e9e21['get'](_0x50d952)||new Set();_0x139293['add'](_0x523ebb['get'](_0x27ae5c)['userId']),_0x4e9e21['set'](_0x50d952,_0x139293);}}for(const _0xb75a of _0x4e9e21['keys']())(_0x28718f['has'](_0xb75a)||_0x523ebb['has'](_0xb75a))&&_0x4e9e21['delete'](_0xb75a);}for(const _0x538144 of _0xcfb448){const _0x3f2bf9=_0x500c9f['insertions'][_0x538144];let _0x5ad20d=null,_0x4ef1d4=null;for(const _0x18ce81 of _0x3f2bf9){const _0x36b729=this['_getVidAttributeName'](_0x18ce81),_0x44b79b=_0x18ce81['item']['getAttribute'](_0x36b729),_0x59b0da=_0x4e9e21['get'](_0x44b79b);_0x59b0da&&'elementStart'==_0x18ce81['type']&&(_0x5ad20d=Array['from'](_0x59b0da)[0x0],_0x4ef1d4=_0x18ce81['item']['getAttribute']('vid_end')),_0x5ad20d&&(_0x523ebb['set'](_0x44b79b,{'userId':_0x5ad20d}),_0x28718f['set'](_0x44b79b,{'userId':_0x5ad20d})),_0x44b79b==_0x4ef1d4&&(_0x5ad20d=null,_0x4ef1d4=null);}}const _0x52fcc4={},_0x5833b0=new Set();for(const _0x5611f7 of _0xcfb448){const _0x127d10=_0x1481a7['deletions'][_0x5611f7],_0x28eaf4=_0x1481a7['insertions'][_0x5611f7];for(const {userId:_0x2b46e0}of this['_touchedMarkers']['values']())null!==_0x2b46e0&&_0x5833b0['add'](_0x2b46e0);for(const {userId:_0x2d4f81}of this['_touchedRoots']['values']())null!==_0x2d4f81&&_0x5833b0['add'](_0x2d4f81);this['_markChanges'](_0x28eaf4,_0x500c9f['insertions'][_0x5611f7],_0x28718f,'insertion',_0x5833b0),this['_markChanges'](_0x127d10,_0x500c9f['deletions'][_0x5611f7],_0x523ebb,'deletion',_0x5833b0),_0x52fcc4[_0x5611f7]={'insertions':this['_prepareViewToSave'](_0x28eaf4),'deletions':this['_prepareViewToSave'](_0x127d10),'attachChange':this['_touchedRoots']['get'](_0x5611f7)||null,'attributesBefore':_0x308bef(this['_baseRootsAttributes']['get'](_0x5611f7))||{},'attributesAfter':_0x308bef(this['_diffRootsAttributes']['get'](_0x5611f7))};}return{'diffData':_0x52fcc4,'authorsIds':Array['from'](_0x5833b0)};}['_processRootBeforeSave'](_0x1be384){for(const [,_0x5932e8]of _0x1be384['markers']){const _0x577589=_0x5932e8['start']['getAncestors']()['filter'](_0x3320c4=>'tableCell'==_0x3320c4['name']);for(const _0x35ed4f of _0x577589)0x1==_0x35ed4f['childCount']&&_0x35ed4f['getChild'](0x0)['is']('element','paragraph')&&_0x35ed4f['getChild'](0x0)['_setAttribute']('keepParagraph',!0x0);}}['_prepareViewToSave'](_0x2ce460){this['_processRootBeforeSave'](_0x2ce460);const _0x44bc95=this['editor']['data']['toView'](_0x2ce460,{}),_0x42eabb=Array['from'](_0x44bc95['getChildren']())['map'](_0x4812e9=>this['_getViewJson'](_0x4812e9));return JSON['stringify'](_0x42eabb);}['_getViewJson'](_0x54dc8b){if(_0x54dc8b['is']('$text'))return _0x54dc8b['data'];{const _0x2a02e2=this['editor']['plugins']['get']('RevisionHistoryUtils'),_0x4b1e03=_0x54dc8b,_0x278101=this['editor']['data']['htmlProcessor']['domConverter'],_0xba3932={'type':_0x2a02e2['_getTypeCharForViewElement'](_0x4b1e03),'name':_0x4b1e03['name'],'attributes':Array['from'](_0x4b1e03['getAttributes']()),'children':Array['from'](_0x4b1e03['getChildren']())['map'](_0x12d893=>this['_getViewJson'](_0x12d893))};if(_0x54dc8b['is']('uiElement')&&'$comment'!=_0x54dc8b['name']){const _0x2d2c86=_0x54dc8b['render'](_0x278101['domDocument'],_0x278101);_0xba3932['children']['push'](_0x2d2c86['outerHTML']);}else{if(_0x54dc8b['is']('rawElement')){const _0xee626e=_0x278101['domDocument']['createElement'](_0x4b1e03['name']);_0x54dc8b['render'](_0xee626e,_0x278101),_0xba3932['children']['push'](_0xee626e['innerHTML']);}}const _0x38684a=Array['from'](_0x4b1e03['getCustomProperties']());_0x38684a['length']>0x0&&(_0xba3932['customProperties']=_0x38684a);const _0x2d50e8=_0x4b1e03['getFillerOffset']();return null!==_0x2d50e8&&(_0xba3932['fillerOffset']=_0x2d50e8),_0xba3932;}}['_markChanges'](_0x554e98,_0x22bf68,_0x1aa6a7,_0x599d58,_0x57d61b){let _0x110114=null,_0x3e1194=null,_0x92f13f=0x0;const _0x363437=this['editor']['model'];for(let _0x3e0a1d=0x0;_0x3e0a1d<_0x22bf68['length'];_0x3e0a1d++){const _0x4f9d3e=this['_getVidAttributeName'](_0x22bf68[_0x3e0a1d]),_0x2546f8=_0x22bf68[_0x3e0a1d]['item']['getAttribute'](_0x4f9d3e),_0x3dadbf=_0x1aa6a7['get'](_0x2546f8),_0x5a8659=_0x3e0a1d==_0x22bf68['length']-0x1;(!_0x110114&&_0x3dadbf&&(_0x110114=_0x3dadbf,_0x3e1194=_0x22bf68[_0x3e0a1d]),_0x110114&&(!_0x3dadbf||_0x3dadbf['userId']!=_0x110114['userId']))&&(_0x42a35c(_0x3dadbf,F(_0x3e1194,_0x554e98,_0x363437),F(_0x22bf68[_0x3e0a1d],_0x554e98,_0x363437)),_0x110114=_0x3dadbf||null,_0x3e1194=_0x3dadbf?_0x22bf68[_0x3e0a1d]:null),_0x110114&&_0x5a8659&&_0x42a35c(_0x3dadbf,F(_0x3e1194,_0x554e98,_0x363437),B(_0x22bf68[_0x3e0a1d],_0x554e98,_0x363437));}function _0x42a35c(_0x267831,_0x3de0f1,_0x1467b7){const _0x5e1e02=_0x110114['userId'],_0x2ad82b='revision:'+_0x599d58+':'+_0x5e1e02+':'+_0x92f13f++,_0x35e4fc=_0x363437['createRange'](_0x3de0f1,_0x1467b7);_0x554e98['markers']['set'](_0x2ad82b,_0x35e4fc),null!==_0x5e1e02&&_0x57d61b['add'](_0x5e1e02);}}['_getVidAttributeName'](_0x55adc2){switch(_0x55adc2['type']){case'elementStart':return'vid_start';case'elementEnd':return'vid_end';default:return'vid';}}['_fixOperation'](_0x5ad39f,_0x194de4){_0x5ad39f['baseVersion']=null;for(const _0x14230b in _0x5ad39f){const _0x35abaa=_0x5ad39f[_0x14230b];if(_0x35abaa instanceof vt){const _0x35e384=_0x194de4['get'](_0x35abaa['root']['rootName']);_0x5ad39f[_0x14230b]=this['_fixPosition'](_0x35abaa,_0x35e384);}if(_0x35abaa instanceof ft){const _0x1a9f68=_0x194de4['get'](_0x35abaa['root']['rootName']);_0x5ad39f[_0x14230b]=this['_fixRange'](_0x35abaa,_0x1a9f68);}'root'===_0x14230b&&(_0x5ad39f['root']=_0x194de4['get'](_0x5ad39f['root']['rootName']));}}['_fixRange'](_0x4eee3d,_0x5a512f){return this['editor']['model']['createRange'](this['_fixPosition'](_0x4eee3d['start'],_0x5a512f),this['_fixPosition'](_0x4eee3d['end'],_0x5a512f));}['_fixPosition'](_0x2d75bd,_0x51f5a0){return this['editor']['model']['createPositionFromPath'](_0x51f5a0,_0x2d75bd['path'],_0x2d75bd['stickiness']);}['_handleInsertOperation'](_0x3a2a16){const _0x5121ef=this['_idsRoots']['get'](_0x3a2a16['position']['root']['rootName']),_0x2b2803=this['_fixPosition'](_0x3a2a16['position'],_0x5121ef),_0xcc92b4=null===_0x3a2a16['_authorId']?null:_0x3a2a16['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x5e5b2a=_0x2b2803['parent'],_0x49593b=this['_revisionId'],_0x155742=[];for(const _0x580d5e of _0x3a2a16['nodes'])if(_0x580d5e['is']('element'))_0x155742['push'](this['_makeIdsRoot'](_0x580d5e));else{for(let _0x1ecc6e=0x0;_0x1ecc6e<_0x580d5e['offsetSize'];_0x1ecc6e++)_0x155742['push'](new ut('$text',{'vid':this['_revisionId']++}));}const _0x2fe603=this['_revisionId'];for(let _0x561737=_0x49593b;_0x561737<_0x2fe603;_0x561737++)this['_touched']['set'](_0x561737,{'userId':_0xcc92b4});_0x5e5b2a['_insertChild'](_0x2b2803['offset'],_0x155742);}['_handleMoveOperation'](_0x632d32){(_0x632d32=this['_cloneOperation'](_0x632d32,this['_idsRoots']))['_execute']();const _0x4ce8e1=null===_0x632d32['_authorId']?null:_0x632d32['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x5ba383=_0x632d32['getMovedRangeStart'](),_0x3da3fa=_0x5ba383['parent'],_0x2b5ec5=_0x5ba383['offset'];!function _0x468c28(_0x29c700,_0x3f21e7,_0x20807e,_0x539dd7){for(let _0x1fb337=_0x20807e;_0x1fb337<_0x539dd7;_0x1fb337++){const _0xa8d257=_0x3f21e7['getChild'](_0x1fb337);_0xa8d257['is']('element','$text')?_0x29c700['set'](_0xa8d257['getAttribute']('vid'),{'userId':_0x4ce8e1}):(_0x29c700['set'](_0xa8d257['getAttribute']('vid_start'),{'userId':_0x4ce8e1}),_0x468c28(_0x29c700,_0xa8d257,0x0,_0xa8d257['childCount']),_0x29c700['set'](_0xa8d257['getAttribute']('vid_end'),{'userId':_0x4ce8e1}));}}(this['_touched'],_0x3da3fa,_0x2b5ec5,_0x2b5ec5+_0x632d32['howMany']);}['_handleMergeOperation'](_0x503861){const _0x1e19b0=null===(_0x503861=this['_cloneOperation'](_0x503861,this['_idsRoots']))['_authorId']?null:_0x503861['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x29b1cf=_0x503861['targetPosition']['parent'],_0x4fbaa1=_0x503861['sourcePosition']['parent'],_0x27bc80=_0x29b1cf['getAttribute']('vid_end'),_0x4c0183=_0x4fbaa1['getAttribute']('vid_start');_0x29b1cf['_setAttribute']('vid_end',_0x4fbaa1['getAttribute']('vid_end')),_0x4fbaa1['_setAttribute']('vid_end',_0x27bc80),this['_touched']['set'](_0x4c0183,{'userId':_0x1e19b0}),this['_touched']['set'](_0x27bc80,{'userId':_0x1e19b0}),_0x503861['_execute']();}['_handleSplitOperation'](_0x10dde3){const _0x3e84ad=null===(_0x10dde3=this['_cloneOperation'](_0x10dde3,this['_idsRoots']))['_authorId']?null:_0x10dde3['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x49fb24=_0x10dde3['graveyardPosition'],_0x7ceeba=_0x10dde3['splitPosition']['parent'];_0x10dde3['_execute']();const _0x1b9b2d=_0x7ceeba['getAttribute']('vid_end'),_0x1e1ea8=_0x10dde3['insertionPosition']['nodeAfter'];if(_0x49fb24){const _0x585447=_0x1e1ea8['getAttribute']('vid_end'),_0x4652a8=_0x7ceeba['getAttribute']('vid_end');_0x7ceeba['_setAttribute']('vid_end',_0x585447),_0x1e1ea8['_setAttribute']('vid_end',_0x4652a8),this['_touched']['set'](_0x7ceeba['getAttribute']('vid_end'),{'userId':_0x3e84ad}),this['_touched']['set'](_0x1e1ea8['getAttribute']('vid_start'),{'userId':_0x3e84ad});}else{const _0x59f1e6=this['_revisionId']++,_0x41757e=this['_revisionId']++;_0x7ceeba['_setAttribute']('vid_end',_0x59f1e6),_0x1e1ea8['_setAttribute']('vid_start',_0x41757e),_0x1e1ea8['_setAttribute']('vid_end',_0x1b9b2d),this['_touched']['set'](_0x59f1e6,{'userId':_0x3e84ad}),this['_touched']['set'](_0x41757e,{'userId':_0x3e84ad});}}['_handleMarkerOperation'](_0x394dd3){if(!_0x394dd3['affectsData'])return;const _0x27b160=(_0x394dd3=this['_cloneOperation'](_0x394dd3,this['_diffRoots']))['oldRange']?_0x394dd3['oldRange']['root']:null,_0x31fbdf=_0x394dd3['newRange']?_0x394dd3['newRange']['root']:null;_0x27b160&&this['_markers']['delete'](_0x394dd3['name']),_0x31fbdf&&this['_markers']['set'](_0x394dd3['name'],_0x394dd3['newRange']['clone']());const _0x2ac203=null===_0x394dd3['_authorId']?null:_0x394dd3['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x218e91=_0x394dd3['name'];if(!this['_touchedMarkers']['has'](_0x218e91))return void this['_touchedMarkers']['set'](_0x218e91,{'range':_0x394dd3['oldRange'],'userId':_0x2ac203});const _0x38bdeb=this['_touchedMarkers']['get'](_0x218e91),_0xd0e3fc=_0x38bdeb['range'],_0x1ed56e=_0x394dd3['newRange'];null==_0xd0e3fc&&null==_0x1ed56e||_0xd0e3fc&&_0x1ed56e&&_0xd0e3fc['isEqual'](_0x1ed56e)?this['_touchedMarkers']['delete'](_0x394dd3['name']):_0x38bdeb['userId']=_0x2ac203;}['_handleRootOperation'](_0x55a167,_0xb34051){this['_diffRoots']['has'](_0x55a167['rootName'])?this['_diffRoots']['get'](_0x55a167['rootName'])['_isAttached']=_0x55a167['isAdd']:(this['_diffRoots']['set'](_0x55a167['rootName'],P(_0x55a167['rootName'],!0x0)),this['_diffRootsAttributes']['set'](_0x55a167['rootName'],{}),_0xb34051&&this['_idsRoots']['set'](_0x55a167['rootName'],P(_0x55a167['rootName'],!0x0)));const _0x2839ab=null===_0x55a167['_authorId']?null:_0x55a167['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x29d72b=this['_touchedRoots']['get'](_0x55a167['rootName']);_0x29d72b&&_0x29d72b['userId']===_0x2839ab?this['_touchedRoots']['delete'](_0x55a167['rootName']):this['_touchedRoots']['set'](_0x55a167['rootName'],{'userId':_0x2839ab,'isAttached':_0x55a167['isAdd']});}['_handleRootAttributeOperation'](_0x5dfcba){const _0x18542a=this['_diffRootsAttributes']['get'](_0x5dfcba['root']['rootName']);null===_0x5dfcba['newValue']?delete _0x18542a[_0x5dfcba['key']]:_0x18542a[_0x5dfcba['key']]=_0x5dfcba['newValue'];}}function N(_0x345c2d){const _0x44ff35=P(_0x345c2d['rootName'],_0x345c2d['isAttached']());for(const _0x29937e of _0x345c2d['getChildren']()){const _0x1e1aa5=_0x29937e['_clone'](!0x0);_0x44ff35['_appendChild'](_0x1e1aa5);}return _0x44ff35;}function P(_0x55f79d,_0x2c2b49=!0x0){const _0x2575ed=new gt();return _0x2575ed['rootName']=_0x55f79d,_0x2575ed['_isAttached']=_0x2c2b49,_0x2575ed['isAttached']=()=>_0x2575ed['_isAttached'],_0x2575ed;}function F(_0x31f1f3,_0x2c3908,_0x4c7b5a){const _0x2a8be4='elementEnd'==_0x31f1f3['type']?_0x4c7b5a['createPositionAt'](_0x31f1f3['item'],'end'):_0x4c7b5a['createPositionBefore'](_0x31f1f3['item']);return _0x4c7b5a['createPositionFromPath'](_0x2c3908,_0x2a8be4['path'],_0x2a8be4['stickiness']);}function B(_0x39407d,_0x39d4b9,_0x2d0c03){const _0x4ea7cb='elementStart'==_0x39407d['type']?_0x2d0c03['createPositionAt'](_0x39407d['item'],0x0):_0x2d0c03['createPositionAfter'](_0x39407d['item']);return _0x2d0c03['createPositionFromPath'](_0x39d4b9,_0x4ea7cb['path'],_0x4ea7cb['stickiness']);}class os extends _0xe6f994{['focusTracker'];['keystrokes'];['revisionNameInputView'];constructor(_0x39bf3b,_0x532b68){super(_0x39bf3b),this['focusTracker']=new _0xc6fcc2(),this['keystrokes']=new _0x2a371c(),this['set']('revisionNameInputValue',''),this['revisionNameInputView']=this['_createRevisionNameInput'](_0x532b68),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'](),_0x3b7330({'view':this}),this['focusTracker']['add'](this['revisionNameInputView']['element']),this['keystrokes']['listenTo'](this['element']);const _0x361876=_0xa264bf=>_0xa264bf['stopPropagation']();this['keystrokes']['set']('arrowright',_0x361876),this['keystrokes']['set']('arrowleft',_0x361876),this['keystrokes']['set']('arrowup',_0x361876),this['keystrokes']['set']('arrowdown',_0x361876);}['focus'](){this['revisionNameInputView']['focus']();}get['revisionName'](){return this['revisionNameInputView']['fieldView']['element']['value']['trim']();}set['revisionName'](_0x8ab099){this['revisionNameInputView']['fieldView']['element']['value']=_0x8ab099['trim']();}['reset'](){this['revisionNameInputView']['fieldView']['element']['value']='',this['revisionNameInputView']['errorText']=null;}['_createRevisionNameInput'](_0x596db1){const _0x55664c=new nt(this['locale'],ti),_0x33935f=_0x55664c['fieldView'];_0x33935f['extendTemplate']({'attributes':{'maxlength':'220'}});let _0x3ef8e2=g(this['locale'],'Name\x20of\x20the\x20revision');return!_0x596db1&&(_0x3ef8e2+='\x20('+g(this['locale'],'optional')+')'),(_0x55664c['label']=_0x3ef8e2,_0x33935f['on']('input',()=>{this['revisionNameInputValue']=_0x33935f['element']['value']['trim']();}),_0x55664c);}}class f extends _0x2ec88b{static get['pluginName'](){return'RevisionHistoryUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[u];}['_saveRevisionFormView'];['init'](){const _0x5e067b=this['editor'],_0xa91495=_0x5e067b['plugins']['get']('RevisionTracker');_0x5e067b['ui']['componentFactory']['add']('revisionHistory',_0x19c234=>{const _0x265bc5=_0x2abc07(_0x19c234),_0x58af61=_0x265bc5['panelView']['children'],_0x237552=new _0x497ddb(_0x19c234),_0x49396b=new te(_0x19c234),_0x308627=new _0x2f1c51(_0x19c234),_0xf84b4c=new te(_0x19c234),_0x8bf4a3=new _0x2f1c51(_0x19c234);return _0x265bc5['bind']('isEnabled')['to'](_0xa91495,'isReady',_0xa91495,'isEnabled',_0x5e067b,'isReadOnly',(_0xc9222d,_0x5a2854,_0x16c214)=>_0xc9222d&&_0x5a2854&&!_0x16c214),_0x265bc5['buttonView']['set']({'icon':_0xe03c96,'label':g(_0x19c234,'Revision\x20history'),'tooltip':!0x0}),_0x308627['set']({'label':g(_0x19c234,'Save\x20current\x20revision'),'withText':!0x0,'role':'menuitem'}),_0x308627['bind']('isEnabled')['to'](_0xa91495,'isReady',_0xa91495,'isEnabled',_0x5e067b,'isReadOnly',(_0x23ffd0,_0x148f90,_0x168ec5)=>_0x23ffd0&&_0x148f90&&!_0x168ec5),_0x308627['on']('execute',()=>this['_showDialog']()),_0x8bf4a3['set']({'label':g(_0x19c234,'Open\x20revision\x20history'),'withText':!0x0,'role':'menuitem'}),_0x8bf4a3['bind']('isEnabled')['to'](_0xa91495,'isReady',_0x5e067b,'isReadOnly',(_0x6bb110,_0x3ac1f4)=>_0x6bb110&&!_0x3ac1f4),_0x8bf4a3['on']('execute',()=>{_0x5e067b['config']['get']('revisionHistory')['showRevisionViewerCallback'](),_0x265bc5['isOpen']=!0x1,_0x5e067b['editing']['view']['focus']();}),_0x49396b['children']['add'](_0x308627),_0xf84b4c['children']['add'](_0x8bf4a3),_0x237552['role']='menu',_0x237552['items']['addMany']([_0x49396b,_0xf84b4c]),_0x58af61['add'](_0x237552),_0x265bc5;}),_0x5e067b['ui']['componentFactory']['add']('menuBar:revisionHistory',()=>this['_registerMenuComponent']());}['_registerMenuComponent'](){const _0x5062db=this['editor'],_0x295d13=_0x5062db['locale'],_0x300346=new _0x4b50d2(_0x295d13),_0x40797d=new _0x29661e(_0x295d13);_0x300346['buttonView']['set']({'icon':_0xe03c96,'label':g(_0x295d13,'Revision\x20history')});const _0x400717=new _0x1214a0(_0x295d13,_0x300346),_0x236595=new _0xa6a8d3(_0x295d13);_0x236595['set']({'label':g(_0x295d13,'Save\x20current\x20revision')}),_0x236595['delegate']('execute')['to'](_0x300346),_0x236595['on']('execute',()=>{this['_showDialog']();}),_0x400717['children']['add'](_0x236595),_0x40797d['items']['add'](_0x400717);const _0x203aa1=new _0x1214a0(_0x295d13,_0x300346),_0xce3da=new _0xa6a8d3(_0x295d13);return _0xce3da['set']({'label':g(_0x295d13,'Open\x20revision\x20history')}),_0xce3da['delegate']('execute')['to'](_0x300346),_0xce3da['on']('execute',()=>{_0x5062db['config']['get']('revisionHistory')['showRevisionViewerCallback']();}),_0x203aa1['children']['add'](_0xce3da),_0x40797d['items']['add'](_0x203aa1),_0x300346['panelView']['children']['add'](_0x40797d),_0x300346;}['_showDialog'](){const _0x34f23c=this['editor'],_0x3a3424=_0x34f23c['locale'],_0x37f04=_0x34f23c['plugins']['get']('Dialog'),_0xa0ee1a=_0x34f23c['plugins']['get']('RevisionTracker');function _0x28e783(_0x473c4b){_0x34f23c['config']['get']('revisionHistory.requireRevisionName')&&''===_0x473c4b['revisionName']?_0x473c4b['revisionNameInputView']['errorText']=g(_0x3a3424,'The\x20revision\x20name\x20cannot\x20be\x20empty.'):(_0x34f23c['plugins']['get'](u)['saveRevision']({'name':_0x473c4b['revisionName']}),_0x37f04['hide']());}this['_saveRevisionFormView']||(this['_createSaveRevisionFormView'](),this['_saveRevisionFormView']['on']('submit',()=>_0x28e783(this['_saveRevisionFormView']))),this['_saveRevisionFormView']['reset'](),_0x37f04['show']({'id':'revisionSave','title':g(_0x3a3424,'Save\x20current\x20revision'),'isModal':!0x0,'content':this['_saveRevisionFormView'],'actionButtons':[{'label':g(_0x34f23c['locale'],'Cancel'),'withText':!0x0,'onExecute':()=>_0x37f04['hide']()},{'label':g(_0x34f23c['locale'],'Accept'),'class':'ck-button-action','withText':!0x0,'onCreate'(_0x53b6d7){_0x53b6d7['bind']('isEnabled')['to'](_0xa0ee1a,'isReady',_0xa0ee1a,'isEnabled',_0x34f23c,'isReadOnly',(_0x1c1afb,_0x5b1ff1,_0x54f5d8)=>_0x1c1afb&&_0x5b1ff1&&!_0x54f5d8);},'onExecute':()=>_0x28e783(this['_saveRevisionFormView'])}]});}['_createSaveRevisionFormView'](){const _0x470e55=this['editor'],_0xf4371=_0x470e55['locale'];this['_saveRevisionFormView']=new os(_0xf4371,_0x470e55['config']['get']('revisionHistory.requireRevisionName')),this['_saveRevisionFormView']['render']();}}class Q extends _0xe6f994{['changeId'];['_model'];constructor(_0x30ed2e,_0x2c245a){super(_0x30ed2e),this['_model']=_0x2c245a,this['changeId']=_0x2c245a['id'];const _0x180d78=this['bindTemplate'],_0x10556e=g(_0x30ed2e,_0x2c245a['data']['isSuggestion']?'Suggested\x20by':'add'==_0x2c245a['type']?'Added\x20by':'Removed\x20by');this['set']('type',_0x2c245a['type']),this['setTemplate']({'tag':'div','attributes':{'class':['ck-annotation','ck-revision-change',_0x180d78['to']('type',_0x529400=>'ck-revision-change__'+_0x529400)],'tabindex':-0x1},'children':[{'tag':'span','children':[{'tag':'span','attributes':{'class':['ck-revision-change__label']},'children':[{'text':_0x10556e}]},{'text':'\x20'+_0x2c245a['author']['name']}]}]});}['focus'](){this['element']['focus']();}}class r extends/* #__PURE__ -- @preserve */
|
|
25
|
+
_0x11044f(){['id'];['author'];['type'];['data'];['rootName'];constructor(_0x13ca27){super(),this['id']=_0x13ca27['id']||_0x1facad(),this['author']=_0x13ca27['author'],this['type']=_0x13ca27['type'],this['data']=_0x13ca27['data']||{},this['rootName']=_0x13ca27['rootName'],this['set']('createdAt',_0x13ca27['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(_0x2adae0,_0x15e47a){this['newRevisionId']=_0x2adae0,this['oldRevisionId']=_0x15e47a,this['changes']=new _0x331cab();}['_setChanges'](_0x44aece){for(const _0x6c4b57 of _0x44aece)this['changes']['add'](_0x6c4b57);}}class m extends _0x2ec88b{['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[_0x53d511,_0x32e810,I,V];}constructor(_0x510c89){super(_0x510c89),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',(_0x3c0427,_0x205b2e,_0x13cd9d)=>{this['activeChange']=null,this['activeView']=null,this['editor']['editing']['view']['change'](_0x5c6d37=>{for(const _0x1a89cf of this['editor']['editing']['view']['document']['roots'])_0x13cd9d?_0x5c6d37['removeClass']('ck-editor__editable__overlay',_0x1a89cf):_0x5c6d37['addClass']('ck-editor__editable__overlay',_0x1a89cf);});}),this['bind']('isNavigationMode')['to'](this,'activeChange',_0x5b3645=>null!==_0x5b3645),this['bind']('currentChangeNumber')['to'](this,'isReady',this,'diff',this,'activeChange',(_0x1abae7,_0x22bb4f,_0x283429)=>_0x1abae7&&_0x283429?_0x22bb4f['changes']['getIndex'](_0x283429):0x0),this['bind']('numberOfChanges')['to'](this,'isReady',this,'diff',(_0x30ca7e,_0x50c0d4)=>_0x30ca7e?_0x50c0d4['changes']['length']:0x0),this['_changeView']=null,this['_changeIdToChange']=new Map(),this['_balloon']=this['editor']['plugins']['get'](_0x32e810);}['init'](){const _0xf71767=this['editor'],_0x2835d6=new pt(_0xf71767,{'direction':'backward'}),_0x23a76a=new pt(_0xf71767,{'direction':'forward'});(_0xf71767['commands']['add']('showPreviousChange',_0x2835d6),_0xf71767['commands']['add']('showNextChange',_0x23a76a),_0xf71767['commands']['add']('restoreRevision',new wt(_0xf71767)),this['on']('change:numberOfChanges',()=>{_0x2835d6['refresh'](),_0x23a76a['refresh']();}),this['_setConversion'](),this['_initInteractions'](),_0xf71767['enableReadOnlyMode']('revision-viewer'),_0xf71767['plugins']['has']('WidgetToolbarRepository'))&&_0xf71767['plugins']['get']('WidgetToolbarRepository')['forceDisabled']('revision-viewer');}async['getRevisionDocumentData'](_0x11d6e2){return await this['_utils']['loadRevisionData'](_0x11d6e2,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x11d6e2);}async['getRevisionRootsAttributes'](_0x3adac2){return await this['_utils']['loadRevisionData'](_0x3adac2,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x3adac2);}async['compare'](_0x34b4ff,_0xe8e658,_0x32d8a1=!0x1){if(!this['isEnabled'])return;const _0x260349=this['diff'],_0x5903f8=this['repository'],_0x3fb0bb='string'==typeof _0x34b4ff?_0x5903f8['getRevision'](_0x34b4ff):_0x34b4ff,_0x5bcaf7='string'==typeof _0xe8e658?_0x5903f8['getRevision'](_0xe8e658):_0xe8e658,_0x1af08e=_0x3fb0bb['id'],_0x13ed5a=_0x5bcaf7?_0x5bcaf7['id']:null;if(!_0x32d8a1&&this['diff']&&this['diff']['newRevisionId']===_0x1af08e&&this['diff']['oldRevisionId']===_0x13ed5a)return Promise['resolve']();this['isReady']=!0x1,this['activeView']=null,this['activeChange']=null,this['diff']=new c(_0x1af08e,_0x13ed5a);const _0x191e21=this['_getRevisionsRange'](_0x3fb0bb,_0x5bcaf7,!0x0)['map'](_0xc2ab23=>this['_utils']['loadRevisionData'](_0xc2ab23,this['adapter']));return _0x191e21['push'](new Promise(_0xd8ddff=>{setTimeout(_0xd8ddff,0x14);})),Promise['all'](_0x191e21)['then'](()=>{if(!this['isEnabled'])return;this['_cleanUp']();const _0x19ff21=this['_getDiff'](_0x1af08e,_0x13ed5a);for(const _0x81e502 of _0x19ff21['changes'])this['_changeIdToChange']['set'](_0x81e502['id'],_0x81e502);this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x339c2b=>{for(const _0x47c298 of this['editor']['model']['document']['getRootNames']())_0x339c2b['detachRoot'](_0x47c298);for(const _0x4d8fc7 of Object['keys'](_0x19ff21['model'])){const _0x3e7d41=_0x339c2b['addRoot'](_0x4d8fc7);for(const _0x314647 of Object['keys'](_0x19ff21['attributes'][_0x4d8fc7]))_0x339c2b['setAttribute'](_0x314647,_0x19ff21['attributes'][_0x4d8fc7][_0x314647],_0x3e7d41);_0x339c2b['insert'](_0x19ff21['model'][_0x4d8fc7],_0x3e7d41,0x0);}}),this['diff']['_setChanges'](this['_sortAndFilterDiffChanges'](_0x19ff21['changes'])),this['isReady']=!0x0;})['catch'](_0x3e50de=>{console['error'](_0x3e50de),this['_cleanUp'](),_0x260349&&(this['diff']=_0x260349),this['isReady']=!0x0;});}['addRevisionData'](_0x511a08,_0x21a34c){const _0x5b7800=this['repository']['createRevision'](_0x511a08);return _0x5b7800['on']('_update',(_0x97fb50,_0x3e1846,_0x4704f0)=>_0x21a34c(_0x3e1846,_0x4704f0,_0x5b7800)),this['repository']['addRevision'](_0x5b7800),_0x5b7800;}['_cleanUp'](){this['activeChange']=null,this['_cleanMarkers'](),this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=null,this['_changeIdToChange']['clear'](),this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x5ed610=>{for(const _0x4ccc57 of this['editor']['model']['document']['getRootNames']())_0x5ed610['detachRoot'](_0x4ccc57);});}['_sortAndFilterDiffChanges'](_0x1dda22){const _0x59e9f7=[],_0x506d38=new Map();for(const _0x3c3b6e of this['editor']['model']['document']['getRootNames']()){const _0x3d7ac1=this['editor']['editing']['view']['getDomRoot'](_0x3c3b6e);if(!_0x3d7ac1)continue;const _0x52e21d=_0x3d7ac1['getClientRects']()['item'](0x0);_0x52e21d&&(_0x59e9f7['push'](_0x3c3b6e),_0x506d38['set'](_0x3c3b6e,_0x52e21d));}return _0x59e9f7['sort']((_0x9ccbfb,_0x483c85)=>{const _0x485e60=_0x506d38['get'](_0x9ccbfb),_0x5e443c=_0x506d38['get'](_0x483c85);return _0x485e60['y']-_0x5e443c['y']||_0x485e60['x']-_0x5e443c['x'];}),(_0x1dda22=_0x1dda22['filter'](_0x4afb61=>_0x59e9f7['includes'](_0x4afb61['rootName'])))['sort']((_0x7ce0e3,_0x1cd03a)=>_0x59e9f7['indexOf'](_0x7ce0e3['rootName'])-_0x59e9f7['indexOf'](_0x1cd03a['rootName'])),_0x1dda22;}['_makeTape'](_0x24fc78){const _0x3bf0bd=Array['from'](_0x24fc78['markers'])['filter'](([_0x49ab0b,_0xf1e706])=>_0x49ab0b['startsWith']('revision:')&&!_0xf1e706['isCollapsed']),_0x165ced=Array['from'](this['editor']['model']['createRangeIn'](_0x24fc78)['getWalker']({'singleCharacters':!0x0}));if(0x0!=_0x3bf0bd['length'])for(const _0x2aa0a9 of _0x165ced){const [_0x494534,_0x2f5e04]=_0x3bf0bd[0x0],[,_0x4c4179,_0xa6f778]=_0x494534['split'](':');if(_0x2f5e04['end']['isEqual'](_0x2aa0a9['nextPosition'])&&_0x3bf0bd['shift'](),(_0x2aa0a9['previousPosition']['isEqual'](_0x2f5e04['start'])||_0x2aa0a9['previousPosition']['isAfter'](_0x2f5e04['start']))&&('insertion'==_0x4c4179?_0x2aa0a9['isAdded']={'userId':_0xa6f778}:'deletion'==_0x4c4179&&(_0x2aa0a9['isRemoved']={'userId':_0xa6f778})),0x0==_0x3bf0bd['length'])break;}return _0x165ced;}['_refreshStartEndIndex'](_0x20a6ad){const _0x5c10e3=new Map();for(let _0x32902d=0x0;_0x32902d<_0x20a6ad['length'];_0x32902d++)'text'===_0x20a6ad[_0x32902d]['type']?(_0x20a6ad[_0x32902d]['item']['startIndex']=_0x32902d,_0x20a6ad[_0x32902d]['item']['endIndex']=_0x32902d):('elementStart'===_0x20a6ad[_0x32902d]['type']?_0x20a6ad[_0x32902d]['item']['startIndex']=_0x32902d:'elementEnd'===_0x20a6ad[_0x32902d]['type']&&(_0x20a6ad[_0x32902d]['item']['endIndex']=_0x32902d),_0x5c10e3['set'](_0x20a6ad[_0x32902d]['id'],_0x32902d));for(const _0x44db27 of _0x5c10e3['values']())'elementStart'===_0x20a6ad[_0x44db27]['type']?_0x20a6ad[_0x44db27]['item']['endIndex']=_0x5c10e3['get'](_0x20a6ad[_0x44db27]['pairId']):'elementEnd'===_0x20a6ad[_0x44db27]['type']&&(_0x20a6ad[_0x44db27]['item']['startIndex']=_0x5c10e3['get'](_0x20a6ad[_0x44db27]['pairId']));}['_processTape'](_0x3eccdc){for(let _0x4763d=0x0;_0x4763d<_0x3eccdc['length'];_0x4763d++){if('elementStart'===_0x3eccdc[_0x4763d]['type'])_0x3eccdc[_0x4763d]['item']['startIndex']=_0x4763d;else{if('elementEnd'===_0x3eccdc[_0x4763d]['type']){_0x3eccdc[_0x4763d]['item']['endIndex']=_0x4763d;const _0x27ed98=_0x3eccdc[_0x4763d]['item']['startIndex'];_0x3eccdc[_0x27ed98]['pairId']=_0x3eccdc[_0x4763d]['id'],_0x3eccdc[_0x4763d]['pairId']=_0x3eccdc[_0x27ed98]['id'];}else _0x3eccdc[_0x4763d]['item']['startIndex']=_0x4763d,_0x3eccdc[_0x4763d]['item']['endIndex']=_0x4763d,_0x3eccdc[_0x4763d]['pairId']=null;}_0x3eccdc[_0x4763d]['markersStart']||(_0x3eccdc[_0x4763d]['markersStart']=[],_0x3eccdc[_0x4763d]['markersEnd']=[]);}}['_markInsertions'](_0x1501c1,_0x374460){const _0x40a05c=_0x1501c1['filter'](_0x469b3b=>!_0x469b3b['isAdded']);for(let _0x390c30=0x0;_0x390c30<_0x374460['length'];_0x390c30++)_0x374460[_0x390c30]['isAdded']&&(_0x40a05c[_0x390c30]['isAdded']=_0x374460[_0x390c30]['isAdded']);}['_getDiff'](_0x452a7d,_0x489452=null){const _0x234b5f=this['repository']['getRevision'](_0x452a7d),_0x69b423=_0x489452?this['repository']['getRevision'](_0x489452):null,_0x5bf64a=this['_getRevisionsRange'](_0x234b5f,_0x69b423),_0x146421=_0x5bf64a[_0x5bf64a['length']-0x1],_0x14eda6=new Map(),_0x2dc881={'model':{},'attributes':{},'changes':[]},_0x5043b6=new Set(),_0x126205=new Map();for(let _0x148100=_0x5bf64a['length']-0x1;_0x148100>=0x0;_0x148100--){const _0x3b9b71=_0x5bf64a[_0x148100];for(const _0x563521 of Object['keys'](_0x3b9b71['diffData']))if(_0x3b9b71['diffData'][_0x563521]['attachChange']){const _0x2f02df=_0x3b9b71['diffData'][_0x563521]['attachChange'];_0x2f02df['isAttached']?(_0x5043b6['add'](_0x563521),_0x126205['has'](_0x563521)&&_0x126205['get'](_0x563521)['userId']==_0x2f02df['userId']?_0x126205['delete'](_0x563521):_0x126205['set'](_0x563521,_0x2f02df)):_0x126205['has'](_0x563521)?(_0x5043b6['delete'](_0x563521),_0x126205['delete'](_0x563521)):(_0x5043b6['add'](_0x563521),_0x126205['set'](_0x563521,_0x2f02df));}else _0x5043b6['add'](_0x563521);}for(const _0x39c668 of _0x5043b6){const _0x47beac=_0x126205['has'](_0x39c668)&&!_0x126205['get'](_0x39c668)['isAttached'];let _0x51517f=_0x47beac?_0x5bf64a['length']-0x1:0x0;const _0xed41ab=_0x47beac?-0x1:0x1;for(;_0x5bf64a[_0x51517f];){const _0x4d3c72=_0x5bf64a[_0x51517f];if(_0x4d3c72['diffData'][_0x39c668]){const _0x5a36f3=_0x47beac?_0x4d3c72['diffData'][_0x39c668]['attributesBefore']:_0x4d3c72['diffData'][_0x39c668]['attributesAfter'];_0x2dc881['attributes'][_0x39c668]=_0x5a36f3?_0x308bef(_0x5a36f3):{};break;}_0x51517f+=_0xed41ab;}}for(const _0x52e2fc of _0x5bf64a){_0x52e2fc['model']={};for(const _0x24d36a of _0x52e2fc['authors'])_0x14eda6['set'](_0x24d36a['id'],_0x24d36a);for(const _0x27e67f of _0x5043b6){const _0x5ce0aa=_0x52e2fc['diffData'][_0x27e67f]?_0x52e2fc['diffData'][_0x27e67f]['insertions']:'[]',_0x4b6df5=_0x52e2fc['diffData'][_0x27e67f]?_0x52e2fc['diffData'][_0x27e67f]['deletions']:'[]';_0x52e2fc['model'][_0x27e67f]={'insertions':this['_utils']['_makeModelFromViewString'](_0x5ce0aa),'deletions':this['_utils']['_makeModelFromViewString'](_0x4b6df5)};}}for(const _0x252d73 of _0x5043b6){let _0x426fd4=null,_0x3e5bf9=0x0;const _0x31146b=new Map(Array['from'](_0x234b5f['model'][_0x252d73]['insertions']['markers'])['filter'](([_0x5fe233])=>!_0x5fe233['startsWith']('revision:')));let _0x1f59c0=0x0;for(const _0x213b20 of _0x5bf64a){const _0x611789=this['_makeTape'](_0x213b20['model'][_0x252d73]['insertions']);_0x213b20==_0x234b5f?(_0x426fd4=_0x611789,_0x3e5bf9=_0x426fd4['length'],_0x426fd4['forEach'](_0x3776a5=>{_0x3776a5['id']=_0x1f59c0++;}),this['_processTape'](_0x426fd4)):this['_markInsertions'](_0x426fd4,_0x611789);const _0x572e31=_0x426fd4['filter'](_0x3ef851=>!_0x3ef851['isAdded'])['map'](_0x4a495f=>_0x4a495f['id']);let _0x140821=0x0;const _0x42a1ae=this['_makeTape'](_0x213b20['model'][_0x252d73]['deletions']);_0x42a1ae['forEach'](_0x3d9277=>{_0x3d9277['isRemoved']?_0x3d9277['id']=_0x3e5bf9++:_0x3d9277['id']=_0x572e31[_0x140821++];}),this['_processTape'](_0x42a1ae),this['_setDistance'](_0x426fd4,'isAdded'),this['_setDistance'](_0x42a1ae,'isRemoved'),_0x213b20==_0x234b5f&&this['_markMarkers'](_0x426fd4,_0x31146b),_0x426fd4=this['_joinTapes'](_0x426fd4,_0x42a1ae),this['_refreshStartEndIndex'](_0x426fd4),this['_setDistance'](_0x426fd4,'isRemoved');}_0x426fd4=_0x426fd4['filter'](_0x20038b=>!(_0x20038b['isAdded']&&_0x20038b['isRemoved']));const _0x108b17=new Map(_0x146421['model'][_0x252d73]['deletions']['markers']),_0x152fcc=new Set(_0x31146b['keys']());for(const _0x45df83 of _0x108b17['keys']())_0x152fcc['delete'](_0x45df83);this['_markSuggestions'](_0x426fd4,_0x152fcc),this['_fixObsoleteTags'](_0x426fd4),_0x426fd4=this['_removeMissingPairs'](_0x426fd4),_0x426fd4=this['_markMismatchedRemovedTags'](_0x426fd4),_0x426fd4=this['_removeUnsupportedChanges'](_0x426fd4);const {root:_0x4624c6,changes:_0x4a664c}=this['_makeModelFromTape'](_0x426fd4,_0x14eda6,_0x252d73);_0x2dc881['model'][_0x252d73]=_0x4624c6;const _0x128a98=_0x126205['get'](_0x252d73);if(_0x128a98){const _0x162210=_0x14eda6['get'](_0x128a98['userId']),_0x39c7c4=new r({'author':_0x162210,'type':_0x128a98['isAttached']?'add':'remove','data':{'isOnRoot':!0x0},'createdAt':new Date(),'rootName':_0x252d73});_0x4a664c['unshift'](_0x39c7c4),_0x2dc881['attributes'][_0x252d73]['revisionHistoryAttachChange']=_0x39c7c4['id'];}_0x2dc881['changes']=_0x2dc881['changes']['concat'](_0x4a664c);}return _0x2dc881;}['_markMarkers'](_0x4f585b,_0x268ca6){for(let _0x309ea0=0x0;_0x309ea0<_0x4f585b['length'];_0x309ea0++)for(const [_0x10578d,_0x1ac29c]of _0x268ca6)!_0x1ac29c['isCollapsed']&&_0x1ac29c['start']['isEqual'](_0x4f585b[_0x309ea0]['previousPosition'])&&_0x4f585b[_0x309ea0]['markersStart']['push'](_0x10578d),_0x1ac29c['end']['isEqual'](_0x4f585b[_0x309ea0]['nextPosition'])&&_0x4f585b[_0x309ea0]['markersEnd']['push'](_0x10578d);}['_joinTapes'](_0x4b9278,_0x131ae8){let _0x253355=[],_0x5b1692=0x0,_0x41fa89=0x0;for(;_0x5b1692<_0x4b9278['length']||_0x41fa89<_0x131ae8['length'];){const _0x3ce699=_0x4b9278[_0x5b1692]||{},_0xdcb75a=_0x131ae8[_0x41fa89]||{};if(_0x3ce699['id']==_0xdcb75a['id'])_0x5b1692++,_0x41fa89++,_0x253355['push'](_0x3ce699);else{if(_0xdcb75a['isRemoved']&&_0x3ce699['isAdded']){const {commonTape:_0x454c8c,iEnd:_0x5acbb8,jEnd:_0x464eb7}=this['_threeWayMerge'](_0x4b9278,_0x5b1692,_0x131ae8,_0x41fa89);_0x253355=_0x253355['concat'](_0x454c8c),_0x5b1692=_0x5acbb8,_0x41fa89=_0x464eb7;}else _0xdcb75a['isRemoved']?(_0x41fa89++,_0x253355['push'](_0xdcb75a)):(_0x5b1692++,_0x253355['push'](_0x3ce699));}}return _0x253355;}['_markSuggestions'](_0x30750a,_0x5aebc7){const _0x3c2047=[];for(let _0x2603e3=0x0;_0x2603e3<_0x30750a['length'];_0x2603e3++){for(let _0x5939ce=0x0;_0x5939ce<_0x30750a[_0x2603e3]['markersStart']['length'];_0x5939ce++){const _0x4328c0=_0x30750a[_0x2603e3]['markersStart'][_0x5939ce];if(!_0x5aebc7['has'](_0x4328c0))continue;const {group:_0xb2d1aa,type:_0x129233,authorId:_0x4d01ec}=_0x2695f1(_0x4328c0);'revision-suggestion'!=_0xb2d1aa||'insertion'!=_0x129233&&'deletion'!=_0x129233||(_0x3c2047['unshift']({'type':_0x129233,'name':_0x4328c0,'userId':_0x4d01ec}),_0x30750a[_0x2603e3]['markersStart']['splice'](_0x5939ce,0x1),_0x5939ce--);}_0x5926cd(_0x30750a[_0x2603e3]);for(let _0x244976=0x0;_0x244976<_0x30750a[_0x2603e3]['markersEnd']['length'];_0x244976++){const _0x39529a=_0x30750a[_0x2603e3]['markersEnd'][_0x244976];if(!_0x5aebc7['has'](_0x39529a))continue;const {group:_0x126ab1,type:_0x4a3f77}=_0x2695f1(_0x39529a);if('revision-suggestion'!=_0x126ab1||'insertion'!=_0x4a3f77&&'deletion'!=_0x4a3f77)continue;_0x30750a[_0x2603e3]['markersEnd']['splice'](_0x244976,0x1),_0x244976--;const _0x69e2f1=_0x3c2047['findIndex'](_0x49ddb6=>_0x49ddb6['name']==_0x39529a);_0x69e2f1>-0x1&&_0x3c2047['splice'](_0x69e2f1,0x1);}}function _0x2695f1(_0xc71912){const _0x37f6f3=_0xc71912['split'](':');return{'group':_0x37f6f3[0x0],'type':_0x37f6f3[0x1],'subType':_0x37f6f3['length']>=0x5?_0x37f6f3[0x2]:null,'id':_0x37f6f3['length']<0x5?_0x37f6f3[0x2]:_0x37f6f3[0x3],'authorId':_0x37f6f3['length']<0x5?_0x37f6f3[0x3]:_0x37f6f3[0x4],'markerCount':0x6==_0x37f6f3['length']?_0x37f6f3[0x5]:null};}function _0x5926cd(_0x38ba51){for(let _0x40aa44=0x0;_0x40aa44<_0x3c2047['length'];_0x40aa44++){if(_0x38ba51['isAdded']&&'insertion'==_0x3c2047[_0x40aa44]['type']&&_0x38ba51['isAdded']['userId']==_0x3c2047[_0x40aa44]['userId'])return _0x38ba51['isAddSuggestion']=_0x3c2047[_0x40aa44],void delete _0x38ba51['isAdded'];if(!_0x38ba51['isAdded']&&!_0x38ba51['isRemoved']&&'deletion'==_0x3c2047[_0x40aa44]['type'])return void(_0x38ba51['isRemoveSuggestion']=_0x3c2047[_0x40aa44]);}}}['_setDistance'](_0x499435,_0x22e7d9){let _0x157bbd=0x0,_0x2f4fe9=!0x1;const _0x5620bf=new Map();for(const _0x3a5673 of _0x499435)_0x3a5673[_0x22e7d9]?_0x2f4fe9&&(_0x157bbd++,_0x2f4fe9=!0x1):(_0x157bbd++,_0x2f4fe9=!0x0),_0x5620bf['set'](_0x3a5673['id'],_0x157bbd);for(let _0x467cf1=0x0;_0x467cf1<_0x499435['length'];_0x467cf1++){if('isRemoved'==_0x22e7d9&&_0x499435[_0x467cf1]['isAdded']||'isAdded'==_0x22e7d9&&_0x499435[_0x467cf1]['isRemoved'])continue;if('text'==_0x499435[_0x467cf1]['type']){_0x499435[_0x467cf1]['distance']=0x0;continue;}const _0x35d091=_0x5620bf['get'](_0x499435[_0x467cf1]['pairId']),_0x2836a0=_0x5620bf['get'](_0x499435[_0x467cf1]['id']);_0x499435[_0x467cf1]['distance']=_0x35d091-_0x2836a0;}}['_getRevisionsRange'](_0x29b8a7,_0x4bc465,_0x1cc18f=!0x1){const _0x1b70ca=[];let _0x3be102=this['repository']['getIndex'](_0x29b8a7),_0x5e56d2=this['repository']['getIndex'](_0x4bc465);for(-0x1==_0x5e56d2&&(_0x5e56d2=this['repository']['_revisions']['length'],_0x1cc18f=!0x1);_0x3be102<_0x5e56d2;)_0x1b70ca['push'](this['repository']['getRevision'](_0x3be102)),_0x3be102++;return _0x1cc18f&&_0x1b70ca['push'](this['repository']['getRevision'](_0x3be102)),_0x1b70ca;}['_threeWayMerge'](_0x4543b5,_0xa8011c,_0x1f248c,_0x5e1763){const _0x238433=this['editor']['model']['schema'];let _0x4c2fd2=_0xa8011c;for(;_0x4543b5[_0x4c2fd2]&&_0x4543b5[_0x4c2fd2]['isAdded'];)_0x4c2fd2++;let _0x56170f=_0x5e1763;for(;_0x1f248c[_0x56170f]&&_0x1f248c[_0x56170f]['isRemoved'];)_0x56170f++;_0x4ecf64(_0x4543b5,_0xa8011c,_0x4c2fd2),_0x4ecf64(_0x1f248c,_0x5e1763,_0x56170f);const _0x1f31ed=_0x1f248c['slice'](_0x5e1763,_0x56170f)['concat'](_0x4543b5['slice'](_0xa8011c,_0x4c2fd2));return _0x1f31ed['sort']((_0x504306,_0x342ccf)=>_0x504306['side']!=_0x342ccf['side']?_0x504306['side']-_0x342ccf['side']:_0x504306['level']!=_0x342ccf['level']?_0x504306['level']-_0x342ccf['level']:_0x504306['distance']!=_0x342ccf['distance']?_0x342ccf['distance']-_0x504306['distance']:!!_0x504306['isAdded']!=!!_0x342ccf['isAdded']?-0x1==_0x504306['side']||0x0==_0x504306['side']?_0x504306['isAdded']?-0x1:0x1:_0x504306['isAdded']?0x1:-0x1:_0x504306['index']-_0x342ccf['index']),{'commonTape':_0x1f31ed,'iEnd':_0x4c2fd2,'jEnd':_0x56170f};function _0x4ecf64(_0x21ccc6,_0x89b46b,_0x12898d){let _0x50586e=-0x1,_0x107337=Number['POSITIVE_INFINITY'],_0x1752b6=!0x0;for(let _0x4fa80a=_0x89b46b;_0x4fa80a<_0x12898d;_0x4fa80a++)if(_0x238433['isInline'](_0x21ccc6[_0x4fa80a]['item'])||(_0x1752b6=!0x1),_0x21ccc6[_0x4fa80a]['item']['startIndex']<_0x89b46b&&(_0x50586e=_0x4fa80a),_0x21ccc6[_0x4fa80a]['item']['endIndex']>=_0x12898d){_0x107337=_0x4fa80a;break;}_0x1752b6&&(_0x50586e=_0x12898d-0x1);for(let _0x34e775=_0x89b46b;_0x34e775<_0x12898d;_0x34e775++)_0x21ccc6[_0x34e775]['side']=_0x34e775<=_0x50586e?-0x1:_0x34e775<_0x107337?0x0:0x1,_0x21ccc6[_0x34e775]['index']=_0x34e775;let _0x47815b=0x0;for(let _0x14631d=_0x89b46b;_0x14631d<=_0x50586e;_0x14631d++)0x0==_0x21ccc6[_0x14631d]['distance']?_0x21ccc6[_0x14631d]['level']=_0x47815b:(_0x47815b++,_0x21ccc6[_0x14631d]['level']=_0x47815b,_0x47815b++);for(let _0x21a2fe=_0x89b46b;_0x21a2fe<_0x12898d;_0x21a2fe++)0x0==_0x21ccc6[_0x21a2fe]['side']&&(_0x21ccc6[_0x21a2fe]['level']=_0x47815b);_0x47815b=0x0;for(let _0x371588=_0x12898d-0x1;_0x371588>=_0x107337;_0x371588--)0x0==_0x21ccc6[_0x371588]['distance']?_0x21ccc6[_0x371588]['level']=_0x47815b:(_0x47815b--,_0x21ccc6[_0x371588]['level']=_0x47815b,_0x47815b--);}}['_fixObsoleteTags'](_0x2104e7){const _0x46467f=new Map(),_0x31b6cc=this['editor']['model']['schema'];for(let _0x40d64b=0x1;_0x40d64b<_0x2104e7['length'];_0x40d64b++){let _0x598797,_0x3c6cc0,_0x4deca5;const _0x4d19f1=_0x2104e7[_0x40d64b],_0x5995e0=_0x2104e7[_0x40d64b-0x1];if('text'==_0x4d19f1['type'])continue;if(_0x4d19f1['type']!=_0x5995e0['type'])continue;if(!_0x31b6cc['isBlock'](_0x5995e0['item'])||_0x31b6cc['isLimit'](_0x5995e0['item']))continue;if(!_0x31b6cc['isBlock'](_0x4d19f1['item'])||_0x31b6cc['isLimit'](_0x4d19f1['item']))continue;if((_0x2104e7[_0x40d64b]['isAdded']||_0x2104e7[_0x40d64b]['isAddSuggestion'])&&_0x2104e7[_0x40d64b-0x1]['isRemoved'])_0x598797=_0x2104e7[_0x40d64b],_0x3c6cc0=_0x2104e7[_0x40d64b-0x1],_0x4deca5=_0x40d64b-0x1;else{if(!_0x2104e7[_0x40d64b]['isRemoved']||!_0x2104e7[_0x40d64b-0x1]['isAdded']&&!_0x2104e7[_0x40d64b-0x1]['isAddSuggestion'])continue;_0x598797=_0x2104e7[_0x40d64b-0x1],_0x3c6cc0=_0x2104e7[_0x40d64b],_0x4deca5=_0x40d64b;}const _0x12a04a=_0x598797['level']==_0x3c6cc0['level'],_0x40e123=Math['abs'](_0x598797['level'])<Math['abs'](_0x3c6cc0['level'])&&0x0==_0x3c6cc0['distance'];(_0x12a04a||_0x40e123)&&(_0x46467f['set'](_0x3c6cc0['id'],_0x598797['id']),_0x2104e7['splice'](_0x4deca5,0x1),_0x40d64b--,_0x598797['isAdded']=!0x1);}for(let _0x22d844=0x0;_0x22d844<_0x2104e7['length'];_0x22d844++)_0x46467f['has'](_0x2104e7[_0x22d844]['pairId'])&&(_0x2104e7[_0x22d844]['pairId']=_0x46467f['get'](_0x2104e7[_0x22d844]['pairId']));}['_removeMissingPairs'](_0x335fe6){const _0x34e029=new Set(_0x335fe6['map'](_0x560487=>_0x560487['id']));for(let _0x222962=0x0;_0x222962<_0x335fe6['length'];_0x222962++)_0x34e029['has'](_0x335fe6[_0x222962]['pairId'])||0x0==_0x335fe6[_0x222962]['distance']||(_0x335fe6[_0x222962]['isIncorrect']=!0x0);return _0x335fe6['filter'](_0x3a963d=>!_0x3a963d['isIncorrect']);}['_markMismatchedRemovedTags'](_0x4cee3c){const _0x2a02ad=new Set();for(let _0x213ca6=0x0;_0x213ca6<_0x4cee3c['length'];_0x213ca6++){if(_0x2a02ad['has'](_0x4cee3c[_0x213ca6]['id'])&&_0x4cee3c[_0x213ca6]['isRemoved']&&(_0x4cee3c[_0x213ca6]['isIncorrect']=!0x0),_0x4cee3c[_0x213ca6]['isIncorrect'])continue;if(0x0==_0x4cee3c[_0x213ca6]['distance'])continue;if('elementStart'!=_0x4cee3c[_0x213ca6]['type'])continue;if(null==_0x4cee3c[_0x213ca6]['pairId'])continue;let _0x2d47f2=_0x213ca6+0x1,_0x557330=0x0;for(;_0x4cee3c[_0x2d47f2]['id']!=_0x4cee3c[_0x213ca6]['pairId'];)'elementStart'==_0x4cee3c[_0x2d47f2]['type']?_0x557330++:'elementEnd'==_0x4cee3c[_0x2d47f2]['type']&&_0x557330--,_0x2d47f2++;if(0x0!=_0x557330){if(_0x4cee3c[_0x213ca6]['isRemoved'])_0x4cee3c[_0x213ca6]['isIncorrect']=!0x0;else{for(;_0x2d47f2!=_0x213ca6;)_0x4cee3c[_0x2d47f2]['isRemoved']&&0x0!=_0x4cee3c[_0x2d47f2]['distance']&&(_0x4cee3c[_0x2d47f2]['isIncorrect']=!0x0,_0x2a02ad['add'](_0x4cee3c[_0x2d47f2]['pairId'])),_0x2d47f2--;}}}return _0x4cee3c['filter'](_0x41aa0d=>!_0x41aa0d['isIncorrect']);}['_removeUnsupportedChanges'](_0x52243f){const _0x387d47=this['editor']['model']['schema'];for(let _0x36fa05=0x0;_0x36fa05<_0x52243f['length'];_0x36fa05++){if(!(_0x52243f[_0x36fa05]['isAdded']||_0x52243f[_0x36fa05]['isAddSuggestion']||_0x52243f[_0x36fa05]['isRemoved']||_0x52243f[_0x36fa05]['isRemoveSuggestion']))continue;if(0x0==_0x52243f[_0x36fa05]['distance'])continue;const _0x11fdfa=_0x52243f[_0x36fa05]['item'];_0x387d47['isBlock'](_0x11fdfa)||_0x387d47['isLimit'](_0x11fdfa)||(_0x52243f[_0x36fa05]['isAdded']&&delete _0x52243f[_0x36fa05]['isAdded'],_0x52243f[_0x36fa05]['isAddSuggestion']&&delete _0x52243f[_0x36fa05]['isAddSuggestion'],_0x52243f[_0x36fa05]['isRemoveSuggestion']&&delete _0x52243f[_0x36fa05]['isRemoveSuggestion'],_0x52243f[_0x36fa05]['isRemoved']&&(_0x52243f[_0x36fa05]['isIncorrect']=!0x0));}return _0x52243f['filter'](_0x99bc60=>!_0x99bc60['isIncorrect']);}['_makeModelFromTape'](_0x45bc49,_0x284145,_0xd47f03){const _0x32295e=new gt(),_0x53aee4=[],_0x48db5f=new Map(),_0x14707f=this['editor']['model'],_0x3dae96=_0x14707f['schema'],_0x93f571=[_0x32295e],_0x19c6d1={},_0x1c26d9={'isAdded':[],'isRemoved':[],'isAddSuggestion':[],'isRemoveSuggestion':[]};let _0x4cea67=null;const _0x293152=[0x0];for(let _0x5ad446=0x0;_0x5ad446<_0x45bc49['length'];_0x5ad446++)if('elementStart'===_0x45bc49[_0x5ad446]['type']){_0x45bc49[_0x5ad446]['previousPosition']=_0x14707f['createPositionFromPath'](_0x32295e,_0x293152);const _0x17c0ef=new ut(_0x45bc49[_0x5ad446]['item']['name'],_0x45bc49[_0x5ad446]['item']['getAttributes']());_0x93f571[0x0]['_appendChild'](_0x17c0ef),_0x293152['push'](0x0),_0x93f571['unshift'](_0x17c0ef),_0x45bc49[_0x5ad446]['nextPosition']=_0x14707f['createPositionFromPath'](_0x32295e,_0x293152);}else'elementEnd'===_0x45bc49[_0x5ad446]['type']?(_0x93f571['shift'](),_0x45bc49[_0x5ad446]['previousPosition']=_0x14707f['createPositionFromPath'](_0x32295e,_0x293152),_0x293152['pop'](),_0x293152[_0x293152['length']-0x1]++,_0x45bc49[_0x5ad446]['nextPosition']=_0x14707f['createPositionFromPath'](_0x32295e,_0x293152)):(_0x45bc49[_0x5ad446]['previousPosition']=_0x14707f['createPositionFromPath'](_0x32295e,_0x293152),_0x4cea67?_0x4cea67['_data']+=_0x45bc49[_0x5ad446]['item']['data']:_0x4cea67=new mt(_0x45bc49[_0x5ad446]['item']['data'],_0x45bc49[_0x5ad446]['item']['getAttributes']()),_0x45bc49[_0x5ad446+0x1]&&'text'===_0x45bc49[_0x5ad446+0x1]['type']&&_0xa8686c(_0x4cea67,_0x45bc49[_0x5ad446+0x1]['item'])||(_0x93f571[0x0]['_appendChild'](_0x4cea67),_0x4cea67=null),_0x293152[_0x293152['length']-0x1]+=_0x45bc49[_0x5ad446]['item']['offsetSize'],_0x45bc49[_0x5ad446]['nextPosition']=_0x14707f['createPositionFromPath'](_0x32295e,_0x293152));for(let _0x1f6b32=0x0;_0x1f6b32<_0x45bc49['length'];_0x1f6b32++){const _0x156666=_0x45bc49[_0x1f6b32]['previousPosition'],_0x412592=_0x45bc49[_0x1f6b32]['nextPosition'];for(const _0x41a858 of _0x45bc49[_0x1f6b32]['markersStart'])_0x48db5f['set'](_0x41a858,{'start':_0x156666,'end':null});_0x15e7f0('isRemoveSuggestion',_0x1f6b32,_0x156666,_0x412592),_0x15e7f0('isAddSuggestion',_0x1f6b32,_0x156666,_0x412592),_0x15e7f0('isRemoved',_0x1f6b32,_0x156666,_0x412592),_0x15e7f0('isAdded',_0x1f6b32,_0x156666,_0x412592);for(const _0x3519ac of _0x45bc49[_0x1f6b32]['markersEnd']){const _0x47132e=_0x48db5f['get'](_0x3519ac);_0x47132e?_0x47132e['end']=_0x412592:_0x48db5f['set'](_0x3519ac,{'start':_0x412592,'end':_0x412592});}}for(const [_0x5285f4,_0x1b4a17]of _0x48db5f){const _0x47bef7=this['editor']['model']['createRange'](_0x1b4a17['start'],_0x1b4a17['end']);_0x32295e['markers']['set'](_0x5285f4,_0x47bef7);}return _0x53aee4['sort']((_0x374714,_0x4dcfa9)=>{const _0x34db0a=_0x32295e['markers']['get']('revision:'+_0x374714['id']),_0x1b0024=_0x32295e['markers']['get']('revision:'+_0x4dcfa9['id']);return _0x34db0a['start']['isBefore'](_0x1b0024['start'])?-0x1:_0x34db0a['start']['isAfter'](_0x1b0024['start'])?0x1:_0x34db0a['end']['isBefore'](_0x1b0024['end'])?-0x1:_0x34db0a['end']['isAfter'](_0x1b0024['end'])?0x1:'add'===_0x374714['type']?-0x1:0x1;}),{'root':_0x32295e,'changes':_0x53aee4};function _0x15e7f0(_0x463abd,_0x109220,_0xd76b54,_0x2f96d6){const _0x285e4b=!!_0x45bc49[_0x109220][_0x463abd],_0x5826c1=_0x285e4b?_0x45bc49[_0x109220][_0x463abd]['userId']:null,_0x44d526=_0x109220===_0x45bc49['length']-0x1,_0x66b2e9=_0x1c26d9[_0x463abd][0x0],_0x1239df=_0x3dae96['isObject'](_0x45bc49[_0x109220]['item']);!_0x19c6d1[_0x463abd]&&_0x285e4b?_0x19c6d1[_0x463abd]={'start':_0xd76b54,'tapeItem':_0x45bc49[_0x109220],'userId':_0x5826c1,'type':_0x463abd}:_0x19c6d1[_0x463abd]&&!_0x285e4b?(_0x19c6d1[_0x463abd]['end']=_0xd76b54,_0x235541(_0x19c6d1[_0x463abd]),_0x19c6d1[_0x463abd]=null):_0x19c6d1[_0x463abd]&&_0x285e4b&&_0x19c6d1[_0x463abd]['userId']!==_0x5826c1&&(_0x19c6d1[_0x463abd]['end']=_0xd76b54,_0x66b2e9&&_0x66b2e9['userId']===_0x19c6d1[_0x463abd]['userId']||_0x235541(_0x19c6d1[_0x463abd]),_0x19c6d1[_0x463abd]={'start':_0xd76b54,'tapeItem':_0x45bc49[_0x109220],'userId':_0x5826c1,'type':_0x463abd}),_0x19c6d1[_0x463abd]&&_0x1239df&&('elementStart'!==_0x45bc49[_0x109220]['type']||_0x66b2e9&&_0x66b2e9['userId']===_0x5826c1||_0x1c26d9[_0x463abd]['unshift']({'userId':_0x5826c1,'object':_0x45bc49[_0x109220]['item'],'change':_0x19c6d1[_0x463abd]}),'elementEnd'===_0x45bc49[_0x109220]['type']&&_0x66b2e9&&_0x66b2e9['object']===_0x45bc49[_0x109220]['item']&&(_0x1c26d9[_0x463abd]['shift'](),_0x19c6d1[_0x463abd]=_0x66b2e9['change'])),_0x19c6d1[_0x463abd]&&_0x44d526&&(_0x19c6d1[_0x463abd]['end']=_0x2f96d6,_0x235541(_0x19c6d1[_0x463abd]),_0x19c6d1[_0x463abd]=null);}function _0x235541({start:_0x87c90,end:_0x5e6bca,tapeItem:_0x1f47de,userId:_0x1d5593,type:_0xc267d1}){const _0xbab1be=_0x1f47de['item'],_0x2352d8=_0x14707f['schema']['isBlock'](_0xbab1be)&&!_0x14707f['schema']['isLimit'](_0xbab1be),_0x28efe2=_0x87c90['nodeAfter']==_0x5e6bca['parent']&&_0x5e6bca['isAtStart'];if(_0x2352d8&&_0x28efe2)return;const _0x3625bc=_0x14707f['createRange'](_0x87c90,_0x5e6bca),_0x339888=_0x284145['get'](_0x1d5593),_0x30fe24=new r({'author':_0x339888,'type':'isAdded'==_0xc267d1||'isAddSuggestion'==_0xc267d1?'add':'remove','data':{'isSuggestion':'isAddSuggestion'==_0xc267d1||'isRemoveSuggestion'==_0xc267d1},'createdAt':new Date(),'rootName':_0xd47f03});_0x53aee4['push'](_0x30fe24),_0x32295e['markers']['set']('revision:'+_0x30fe24['id'],_0x3625bc);}function _0xa8686c(_0x264e20,_0x2249c4){const _0xeaff91=_0x264e20['getAttributes'](),_0x36172b=_0x2249c4['getAttributes']();for(const _0x4951b2 of _0xeaff91){if(_0x4951b2[0x1]!==_0x2249c4['getAttribute'](_0x4951b2[0x0]))return!0x1;_0x36172b['next']();}return _0x36172b['next']()['done'];}}['_setConversion'](){this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision','view':_0x5e4fc4=>{const _0x3d164e=_0x5e4fc4['markerName']['split'](':')[0x1],_0x18aafd=this['_getChangeFromId'](_0x3d164e);if(!_0x18aafd)return null;const _0x454379='add'==_0x18aafd['type']?'insertion':'deletion',_0x61d91f=['ck-suggestion-marker','ck-suggestion-marker-'+_0x454379];return _0x18aafd['data']['isSuggestion']&&_0x61d91f['push']('ck-suggestion-marker-'+_0x454379+'-new'),this['activeChange']==_0x18aafd&&_0x61d91f['push']('ck-suggestion-marker--active'),{'classes':_0x61d91f,'attributes':{'data-change-id':_0x3d164e}};}}),this['editor']['conversion']['for']('upcast')['add'](_0x286b18=>{_0x286b18['on']('element:pre',(_0x1edd3a,_0x40955e,_0x4512a7)=>{const _0xa2e5a1=_0x40955e['viewItem']['getChild'](0x0);if(!_0xa2e5a1||!_0xa2e5a1['is']('element','code'))return;if(!_0x4512a7['consumable']['consume'](_0xa2e5a1,{'attributes':['vid_start','vid_end']}))return;const _0x51d568=_0x40955e['modelRange']['start']['nodeAfter'];_0x4512a7['writer']['setAttribute']('vid_start',_0xa2e5a1['getAttribute']('vid_start'),_0x51d568),_0x4512a7['writer']['setAttribute']('vid_end',_0xa2e5a1['getAttribute']('vid_end'),_0x51d568);},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['add'](_0x586cd5=>{_0x586cd5['on']('element',(_0x3fb386,_0x1624c6,_0x395f32)=>{if(!_0x395f32['consumable']['consume'](_0x1624c6['viewItem'],{'attributes':['vid_start','vid_end']}))return;if(_0x1624c6['modelRange']['isCollapsed'])return;const _0x4c0f8a=_0x1624c6['modelRange']['start']['nodeAfter'];_0x4c0f8a['hasAttribute']('vid_start')||_0x4c0f8a['hasAttribute']('vid')||(_0x395f32['writer']['setAttribute']('vid_start',_0x1624c6['viewItem']['getAttribute']('vid_start'),_0x4c0f8a),_0x395f32['writer']['setAttribute']('vid_end',_0x1624c6['viewItem']['getAttribute']('vid_end'),_0x4c0f8a));},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['elementToAttribute']({'view':{'name':'span','attributes':{'vid':!0x0}},'model':{'key':'vid','value':_0x170530=>_0x170530['getAttribute']('vid')}}),this['editor']['model']['schema']['on']('checkAttribute',(_0x1fcc88,[,_0x16d8ad])=>{['vid_start','vid_end','vid']['includes'](_0x16d8ad)&&(_0x1fcc88['return']=!0x0,_0x1fcc88['stop']());},{'priority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x36c93e=>{_0x36c93e['on']('attribute:vid',(_0x383938,_0x3ea467,_0x5b2df2)=>{if('\x20'!=_0x3ea467['item']['data']||_0x3ea467['item']['parent']['maxOffset']>0x1)return;if(!_0x5b2df2['consumable']['consume'](_0x3ea467['item'],_0x383938['name']))return;const _0x11e34a=_0x5b2df2['writer'],_0x457353=_0x5b2df2['mapper']['toViewRange'](_0x3ea467['range']);_0x11e34a['wrap'](_0x457353,_0x11e34a['createAttributeElement']('span'));});}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',function(_0x5aec45){const _0x2e7bba=_0x5aec45['plugins']['get']('RevisionViewer');return(_0x5198e1,_0x37bb63,_0x2c695b)=>{const _0x2ed45b=_0x37bb63['markerName']['split'](':')[0x1],_0x57871a=_0x2e7bba['_getChangeFromId'](_0x2ed45b);if(!_0x57871a)return null;const _0x1f7e06='add'==_0x57871a['type']?'split':'merge';if(!_0x2c695b['consumable']['test'](_0x37bb63['markerRange'],_0x5198e1['name']))return;const _0x3a5c99=_0x37bb63['markerRange']['getWalker'](),_0x344bdc=_0x37bb63['markerRange']['start'],_0x1a609b=_0x5aec45['model']['schema'];let _0x323fd0=null,_0xab6827=null,_0x4bbd90=!0x1,_0x446aff=!0x1;for(const _0x2034a3 of _0x3a5c99){const _0x34c05e=_0x2034a3['item'];_0x4bbd90=_0x4bbd90||_0x1a609b['isContent'](_0x34c05e);const _0x51f30c=_0x2c695b['mapper']['toViewElement'](_0x34c05e);if(_0x51f30c&&_0x51f30c['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x2034a3['type']&&(_0x1a609b['isBlock'](_0x34c05e)&&!_0x1a609b['isLimit'](_0x34c05e)&&(_0x34c05e['nextSibling']||_0x344bdc['isAtEnd']?_0x323fd0&&_0x323fd0['parent']==_0x34c05e||(_0x323fd0=_0x34c05e,_0x4af639(_0x2034a3['previousPosition']),_0x446aff=!0x0):_0xab6827=_0xab6827||_0x2034a3['previousPosition']));}function _0x4af639(_0xb0123d){const _0x55b5ed=_0x2c695b['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x1f7e06}),_0x45d718=_0x2c695b['mapper']['toViewPosition'](_0xb0123d);_0x57871a['data']['isSuggestion']&&_0x2c695b['writer']['addClass']('ck-suggestion-marker-'+_0x1f7e06+'-new',_0x55b5ed),_0x2e7bba['activeChange']==_0x57871a&&_0x2c695b['writer']['addClass']('ck-suggestion-marker--active',_0x55b5ed),_0x2c695b['writer']['insert'](_0x45d718,_0x55b5ed),_0x2c695b['mapper']['bindElementToMarker'](_0x55b5ed,_0x37bb63['markerName']);}_0x4bbd90||_0x446aff||!_0xab6827||_0x4af639(_0xab6827);};}(this['editor']),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision',(_0x2c3950,_0x439264,_0x3be9dc)=>{const _0x549c37=_0x3be9dc['mapper']['markerNameToElements'](_0x439264['markerName']);if(_0x549c37){for(const _0x137fc3 of _0x549c37)(_0x137fc3['hasClass']('ck-suggestion-marker-split')||_0x137fc3['hasClass']('ck-suggestion-marker-merge'))&&(_0x3be9dc['mapper']['unbindElementFromMarkerName'](_0x137fc3,_0x439264['markerName']),_0x3be9dc['writer']['remove'](_0x137fc3));}},{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',(_0xfda9d9,_0x7bb30b,_0x448306)=>{const _0x23c583=_0x7bb30b['markerName']['split'](':')[0x1],_0x35ea2e=this['_getChangeFromId'](_0x23c583);if(!_0x35ea2e)return null;const _0x46e7ec='add'==_0x35ea2e['type']?'split':'merge';if(_0x448306['consumable']['test'](_0x7bb30b['markerRange'],_0xfda9d9['name']))for(const _0xc7601f of _0x7bb30b['markerRange']['getItems']()){if(!_0xc7601f['is']('element','softBreak'))continue;const _0x2d8d6a=_0x448306['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x46e7ec}),_0x2e2494=_0x448306['mapper']['toViewPosition'](this['editor']['model']['createPositionBefore'](_0xc7601f));_0x35ea2e['data']['isSuggestion']&&_0x448306['writer']['addClass']('ck-suggestion-marker-'+_0x46e7ec+'-new',_0x2d8d6a),this['activeChange']==_0x35ea2e&&_0x448306['writer']['addClass']('ck-suggestion-marker--active',_0x2d8d6a),_0x448306['writer']['insert'](_0x2e2494,_0x2d8d6a),_0x448306['mapper']['bindElementToMarker'](_0x2d8d6a,_0x7bb30b['markerName']);}},{'priority':'high'}),this['editor']['model']['document']['on']('change',()=>{this['editor']['editing']['view']['change'](_0x26ee12=>{for(const _0x2c4a2e of this['editor']['model']['document']['getRootNames']()){const _0x225c8a=this['editor']['model']['document']['getRoot'](_0x2c4a2e),_0x500673=this['editor']['editing']['view']['document']['getRoot'](_0x2c4a2e);if(_0x500673){const _0x4ffec2=_0x225c8a['getAttribute']('revisionHistoryAttachChange');if(_0x26ee12['removeAttribute']('data-change-id',_0x500673),_0x26ee12['removeClass']('ck-revision-history-root-add',_0x500673),_0x26ee12['removeClass']('ck-revision-history-root-remove',_0x500673),_0x26ee12['removeClass']('ck-revision-history-root--active',_0x500673),_0x4ffec2){const _0x173a02=this['_getChangeFromId'](_0x4ffec2);if(!_0x173a02)return null;_0x26ee12['setAttribute']('data-change-id',_0x4ffec2,_0x500673),_0x26ee12['addClass']('ck-revision-history-root-'+_0x173a02['type'],_0x500673),this['activeChange']==_0x173a02&&_0x26ee12['addClass']('ck-revision-history-root--active',_0x500673);}}}});}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'comment','model':_0x35cc19=>'revision-comment:'+_0x35cc19,'converterPriority':'highest'}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'suggestion','model':_0x44fe31=>'revision-suggestion:'+_0x44fe31,'converterPriority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision-suggestion','view':_0x201b61=>({'name':'suggestion:'+_0x201b61,'group':'revision-suggestion'}),'converterPriority':'highest'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision-suggestion','view':_0x58328c=>{const _0x5e4523=_0x58328c['markerName']['split'](':')[0x1];return'insertion'!=_0x5e4523&&'deletion'!=_0x5e4523?null:{'classes':['ck-suggestion-preview-marker','ck-suggestion-preview-marker-'+_0x5e4523]};}}),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',(_0x4ea0aa,_0x23dca4,_0x5a4fe9)=>{const _0x21a272=_0x5a4fe9['mapper']['markerNameToElements'](_0x23dca4['markerName']);if(_0x21a272){for(const _0x1df92a of _0x21a272)_0x1df92a['is']('uiElement')&&(_0x5a4fe9['mapper']['unbindElementFromMarkerName'](_0x1df92a,_0x23dca4['markerName']),_0x5a4fe9['writer']['remove'](_0x1df92a));}},{'priority':'high'});}['_getChangeFromId'](_0x21a020){return this['_changeIdToChange']['get'](_0x21a020);}['_getViewForChange'](_0x162039){return this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=new Q(this['editor']['locale'],_0x162039),this['_changeView'];}['_initInteractions'](){this['editor']['model']['document']['selection']['observeMarkers']('revision'),this['on']('change:activeView',(_0xcb9e4e,_0x116bab,_0x5b56b7,_0x27be9f)=>{_0x27be9f&&this['_balloon']['remove'](_0x27be9f),_0x5b56b7&&(this['_balloon']['add']({'view':_0x5b56b7,'stackId':'revisionHistoryLabel','position':{'target':()=>{const _0x2ec503=this['editor']['editing'],_0x1dfc69=this['_getChangeFromId'](_0x5b56b7['changeId']);let _0x2bf643;if(_0x1dfc69['data']['isOnRoot']){const _0x20a385=_0x2ec503['view']['getDomRoot'](_0x1dfc69['rootName']);_0x2bf643=Array['from'](_0x20a385['getClientRects']());}else{const _0x1c093b=this['editor']['model']['markers']['get']('revision:'+_0x5b56b7['changeId']);_0x2bf643=Array['from'](_0x2ec503['mapper']['markerNameToElements'](_0x1c093b['name']))['map'](_0x2f22ae=>_0x2ec503['view']['domConverter']['mapViewToDom'](_0x2f22ae))['map'](_0x2cf499=>Array['from'](_0x2cf499['getClientRects']()))['flat']();}if(!this['_activeViewTarget'])return _0x2bf643[0x0];return _0x2bf643['find'](_0x52b2bc=>_0x52b2bc['top']-0x3<=this['_activeViewTarget']['y']&&_0x52b2bc['bottom']+0x3>=this['_activeViewTarget']['y']&&_0x52b2bc['left']-0x3<=this['_activeViewTarget']['x']&&_0x52b2bc['right']+0x3>=this['_activeViewTarget']['x'])||_0x2bf643[0x0];}}}),this['_balloon']['showStack']('revisionHistoryLabel'));}),this['on']('change:activeChange',(_0x32cad9,_0x1d5587,_0x13909d,_0x69ab7f)=>{this['activeView']=_0x13909d?this['_getViewForChange'](_0x13909d):null,this['editor']['model']['change'](()=>{const _0x4d9a5b=this['editor']['editing'];_0x69ab7f&&(_0x69ab7f['data']['isOnRoot']?_0x4d9a5b['view']['change'](_0x5eb804=>{_0x5eb804['removeClass']('ck-revision-history-root--active',_0x4d9a5b['view']['document']['getRoot'](_0x69ab7f['rootName']));}):_0x4d9a5b['reconvertMarker']('revision:'+_0x69ab7f['id'])),_0x13909d&&(_0x13909d['data']['isOnRoot']?_0x4d9a5b['view']['change'](_0x29699a=>{_0x29699a['addClass']('ck-revision-history-root--active',_0x4d9a5b['view']['document']['getRoot'](_0x13909d['rootName']));}):_0x4d9a5b['reconvertMarker']('revision:'+_0x13909d['id']));});}),this['listenTo'](this['editor']['editing']['view']['document'],'mouseover',(_0x3bf402,_0x28408b)=>{if(this['activeChange'])return;const _0x215713=this['_findChangeIdFromDomTarget'](_0x28408b['target']),_0x5104a8=this['_changeIdToChange']['get'](_0x215713);_0x5104a8?(this['_activeViewTarget']={'x':_0x28408b['domEvent']['x'],'y':_0x28408b['domEvent']['y']},this['activeView']=this['_getViewForChange'](_0x5104a8)):(this['_activeViewTarget']=null,this['activeView']=null);}),this['listenTo'](this['editor']['editing']['view']['document'],'mousedown',(_0x19efbb,_0x22f7de)=>{const _0x5acfd0=this['_findChangeIdFromDomTarget'](_0x22f7de['target']),_0x2d20bc=this['_changeIdToChange']['get'](_0x5acfd0);_0x2d20bc?(this['_activeViewTarget']={'x':_0x22f7de['domEvent']['x'],'y':_0x22f7de['domEvent']['y']},_0x2d20bc===this['activeChange']?this['_balloon']['updatePosition']():this['activeChange']=_0x2d20bc):(this['_activeViewTarget']=null,this['activeChange']=null);});}['_findChangeIdFromDomTarget'](_0x4910ab){do{const _0x42d2c8=_0x4910ab['getAttribute']('data-change-id');if(_0x42d2c8)return _0x42d2c8;_0x4910ab=_0x4910ab['parent'];}while(_0x4910ab);return null;}['_cleanMarkers'](){this['editor']['model']['change'](_0x180317=>{for(const _0x3cea75 of this['editor']['model']['markers'])_0x180317['removeMarker'](_0x3cea75);});}}function X(_0x509306,_0x259d3a){return(_0x487d5c,_0x3e7899,_0x5c364a)=>{if(!_0x5c364a['consumable']['test'](_0x3e7899['markerRange'],_0x487d5c['name']))return;const _0x1b6f90=_0x3e7899['markerRange']['getWalker'](),_0x3f1cfd=_0x3e7899['markerRange']['start'],_0x20bdad=_0x509306['model']['schema'];let _0x3a234d=null,_0x3d5104=null,_0x474ef4=!0x1,_0x250942=!0x1;for(const _0x448fdf of _0x1b6f90){const _0x108534=_0x448fdf['item'];_0x474ef4=_0x474ef4||_0x20bdad['isContent'](_0x108534);const _0x322801=_0x5c364a['mapper']['toViewElement'](_0x108534);if(_0x322801&&_0x322801['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x448fdf['type']&&(_0x20bdad['isBlock'](_0x108534)&&!_0x20bdad['isLimit'](_0x108534)&&(_0x108534['nextSibling']||_0x3f1cfd['isAtEnd']?_0x3a234d&&_0x3a234d['parent']==_0x108534||(_0x3a234d=_0x108534,_0x16a8ac(_0x448fdf['previousPosition']),_0x250942=!0x0):_0x3d5104=_0x3d5104||_0x448fdf['previousPosition']));}function _0x16a8ac(_0x24050c){const _0x35fa6f=_0x5c364a['mapper']['toViewPosition'](_0x24050c),_0xe30dc5=_0x5c364a['writer']['createUIElement']('span',{'class':'ck-suggestion-preview-marker-'+_0x259d3a});_0x5c364a['writer']['insert'](_0x35fa6f,_0xe30dc5),_0x5c364a['mapper']['bindElementToMarker'](_0xe30dc5,_0x3e7899['markerName']);}_0x474ef4||_0x250942||!_0x3d5104||_0x16a8ac(_0x3d5104);};}class wt extends _0xcd5189{constructor(_0x512956){super(_0x512956);const _0x2c7a07=_0x512956['plugins']['get'](m);this['affectsData']=!0x1,this['listenTo'](_0x2c7a07,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x2c7a07,'change:isEnabled',()=>this['refresh']());}['execute'](){const _0x12cbd6=this['editor'],_0x17b24d=_0x12cbd6['plugins']['get'](m),_0x318894=_0x17b24d['isReady']?_0x17b24d['diff']['newRevisionId']:null;_0x12cbd6['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x318894);}['refresh'](){const {isReady:_0x38cce3,isEnabled:_0x372efe,repository:_0x247136,diff:_0x31bc1d}=this['editor']['plugins']['get'](m),_0x2c4d96=_0x31bc1d&&_0x247136['getLaterVisibleRevision'](_0x31bc1d['newRevisionId']);this['isEnabled']=_0x38cce3&&_0x372efe&&Boolean(_0x2c4d96);}}class pt extends _0xcd5189{['_step'];constructor(_0x405b22,{direction:_0x5ba27f}){super(_0x405b22);const _0x3e9027=_0x405b22['plugins']['get'](m);this['affectsData']=!0x1,this['_step']='forward'===_0x5ba27f?0x1:-0x1,this['listenTo'](_0x3e9027,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x3e9027,'change:isEnabled',()=>this['refresh']()),this['listenTo'](_0x3e9027,'change:activeChange',()=>this['refresh']());}['execute'](){const _0x25a7e0=this['editor'],_0x11bbce=_0x25a7e0['plugins']['get'](m),{isNavigationMode:_0x318c72,currentChangeNumber:_0x11e01f}=_0x11bbce;let _0x3aa330;if(_0x11bbce['activeChange']=_0x318c72?_0x11bbce['diff']['changes']['get'](_0x11e01f+this['_step']):_0x11bbce['diff']['changes']['first'],_0x11bbce['activeChange']['data']['isOnRoot'])_0x3aa330=_0x25a7e0['editing']['view']['getDomRoot'](_0x11bbce['activeChange']['rootName']);else{const _0x4b9aa4=_0x25a7e0['model']['markers']['get']('revision:'+_0x11bbce['activeChange']['id']);_0x3aa330=_0x3d7f8a(_0x25a7e0['editing'],_0x4b9aa4);}_0x44fa1a({'target':_0x3aa330,'viewportOffset':0x28});}['refresh'](){const {isNavigationMode:_0x4dc0a6,currentChangeNumber:_0x30dfbf,numberOfChanges:_0x3cab6a,isReady:_0x1e0f3c,isEnabled:_0x4fa8c8}=this['editor']['plugins']['get'](m);this['isEnabled']=!!(_0x4fa8c8&&_0x1e0f3c&&_0x3cab6a)&&(!_0x4dc0a6||(0x1===this['_step']?_0x30dfbf<_0x3cab6a-0x1:_0x30dfbf>0x0));}}class _i extends _0xe6f994{constructor(_0x54c069){super(_0x54c069);const _0x2790ce=this['bindTemplate'],_0x27df9a=new _0x2f1c51(_0x54c069),_0x736dfa=new _0x2f1c51(_0x54c069);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',(_0xbd3771,_0x886328)=>_0xbd3771&&_0x886328>0x0),this['bind']('_statusText')['to'](this,'isReady',this,'currentChangeNumber',this,'numberOfChanges',this,'isNavigationMode',(_0x3875d8,_0xd7189c,_0x3e075b,_0xb8ae85)=>{if(!_0x3875d8)return g(_0x54c069,'Loading...');if(!_0x3e075b)return g(_0x54c069,'No\x20changes');const _0x26ddde=g(_0x54c069,'NUMBER_OF_CHANGES',_0x3e075b);return _0xb8ae85?g(_0x54c069,'X_OF_Y_CHANGES',[_0xd7189c+0x1,_0x3e075b]):_0x26ddde;}),_0x27df9a['set']({'label':g(_0x54c069,'Show\x20previous\x20change'),'tooltip':!0x0,'icon':_0x52cd02}),_0x736dfa['set']({'label':g(_0x54c069,'Show\x20next\x20change'),'tooltip':!0x0,'icon':_0x1c6260}),_0x27df9a['bind']('isEnabled')['to'](this,'isBackwardNavigationEnabled'),_0x736dfa['bind']('isEnabled')['to'](this,'isForwardNavigationEnabled'),_0x27df9a['on']('execute',()=>this['fire']('execute','backward')),_0x736dfa['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',_0x2790ce['if']('_isStatusLabelVisible','ck-hidden',_0x663327=>!_0x663327)]},'children':[{'text':_0x2790ce['to']('isNavigationMode',_0x40ffc5=>_0x40ffc5?g(_0x54c069,'EDIT_X_OF_Y_REVISIONS')+':\x20':g(_0x54c069,'Total')+':\x20')}]},{'text':_0x2790ce['to']('_statusText')}]},new _0x329cae(),{'tag':'div','attributes':{'class':['ck-revision-history-ui__changes-navigation__navigation']},'children':[_0x27df9a,_0x736dfa]}]});}}const ce='ck-editor__editable__loading-overlay';class le extends _0x2ec88b{static get['pluginName'](){return'RevisionViewerLoadingOverlay';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['show'](){const _0x138816=this['editor']['editing']['view'];_0x138816['change'](_0x17abcc=>{for(const _0x28238d of _0x138816['document']['roots'])_0x17abcc['addClass'](ce,_0x28238d);});}['hide'](){const _0x563d2e=this['editor']['editing']['view'];_0x563d2e['change'](_0x56595e=>{for(const _0x56d211 of _0x563d2e['document']['roots'])_0x56595e['removeClass'](ce,_0x56d211);});}}class R extends _0x2ec88b{static get['pluginName'](){return'RevisionViewerUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[m,le];}['init'](){const _0x19d541=this['editor'],_0x58b576=_0x19d541['plugins']['get'](m),_0x107d34=_0x19d541['plugins']['get'](le);_0x19d541['ui']['componentFactory']['add']('exitToEditing',_0x3e0ad3=>{const _0x395e50=new _0x2f1c51(_0x3e0ad3);return _0x395e50['set']({'label':g(_0x3e0ad3,'Back\x20to\x20editing'),'icon':_0x51d572,'withText':!0x0,'tooltip':!0x0,'class':'ck-revision-history-ui__back-to-editing'}),this['listenTo'](_0x395e50,'execute',()=>{_0x19d541['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}),_0x395e50;}),_0x19d541['ui']['componentFactory']['add']('restoreRevision',_0xd7b2ab=>{const _0x4e78ca=new _0x2f1c51(_0xd7b2ab);return _0x4e78ca['set']({'label':g(_0xd7b2ab,'Restore\x20this\x20revision'),'withText':!0x0,'tooltip':!0x0}),_0x4e78ca['bind']('isEnabled')['to'](_0x19d541['commands']['get']('restoreRevision')),this['listenTo'](_0x4e78ca,'execute',()=>_0x19d541['execute']('restoreRevision')),_0x4e78ca;}),_0x19d541['ui']['componentFactory']['add']('changesNavigation',_0x5dd718=>{const _0x15cdcd=new _i(_0x5dd718),_0x1c31d4=_0x19d541['commands']['get']('showPreviousChange'),_0x52dce4=_0x19d541['commands']['get']('showNextChange');return _0x15cdcd['bind']('isBackwardNavigationEnabled')['to'](_0x1c31d4,'isEnabled'),_0x15cdcd['bind']('isForwardNavigationEnabled')['to'](_0x52dce4,'isEnabled'),_0x15cdcd['bind']('isReady','currentChangeNumber','numberOfChanges','isNavigationMode')['to'](_0x58b576),this['listenTo'](_0x15cdcd,'execute',(_0x53abbb,_0x393c30)=>{_0x19d541['execute']('forward'===_0x393c30?'showNextChange':'showPreviousChange');}),_0x15cdcd;}),_0x107d34['show'](),_0x58b576['on']('change:isReady',(_0x5e8cc5,_0x67fa70,_0x507410)=>{_0x507410?_0x107d34['hide']():_0x107d34['show']();});}}class lt extends nt{['_resizeObserver']=null;constructor(_0x3bd76d,_0x1ad2ce){super(_0x3bd76d,_0x1ad2ce);const _0x3ff171=this['bindTemplate'];this['set']({'label':g(_0x3bd76d,'Revision\x20name'),'_tooltipString':''}),this['fieldView']['placeholder']=g(_0x3bd76d,'Enter\x20the\x20revision\x20name'),this['extendTemplate']({'tag':'span','attributes':{'class':['ck-revision-history-sidebar__revision-name'],'data-cke-tooltip-text':_0x3ff171['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 _0x25f28d=this['fieldView']['element'];this['_tooltipString']=_0x25f28d['scrollWidth']>_0x25f28d['clientWidth']&&_0x25f28d['value']||'';}}class oi extends _0xe6f994{constructor(_0x1ac676,_0x40452d,_0x5abb07){super(_0x1ac676);const _0x17cc49=new _0x44385b();_0x17cc49['set']({'content':_0x3a3708,'viewBox':'0\x200\x2011\x2010'});const _0x51bd46=['ck','ck-revision-history-sidebar__revision-author'];_0x5abb07&&_0x51bd46['push']('ck-revision-history-sidebar__revision-author_creator');const _0x1d2db2=[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision-author__name'],'title':g(_0x1ac676,_0x5abb07?'Revision\x20creator':'Revision\x20author')},'children':[_0x17cc49,_0x40452d['name']]}];this['setTemplate']({'tag':'li','attributes':{'class':_0x51bd46},'children':_0x1d2db2});}}function ni(_0x35179a,_0x249be0){const _0x3e9dd6=_0x35179a['bindTemplate'],_0xf93d72=_0x35179a['locale'],_0x4cf2b4=_0x2abc07(_0xf93d72);_0x4cf2b4['panelPosition']='sw';const _0x21d296=function(_0x1b105d,_0x1dd368){const _0x359ec9=function(_0x3cebdf,_0x1c7184){const _0x49a4cd=_0x3cebdf['locale'],_0x19c5a2={'Compare\x20against\x20selected':g(_0x49a4cd,'Compare\x20against\x20selected'),'Name\x20this\x20revision':g(_0x49a4cd,'Name\x20this\x20revision'),'Restore\x20this\x20revision':g(_0x49a4cd,'Restore\x20this\x20revision')};return _0x1c7184['map'](_0x40c28a=>{const _0x218fd6=_0x19c5a2[_0x40c28a['name']];return _0x218fd6&&_0x218fd6!==_0x40c28a['name']&&(_0x40c28a['name']=_0x218fd6),_0x40c28a;});}(_0x1b105d,_0x1dd368),_0xda6426=new _0x331cab();for(const _0x238abc of _0x359ec9){const _0x1e307e={'type':'button','model':new to({'label':_0x238abc['name'],'class':_0x238abc['class'],'withText':!0x0,'role':'menuitem','_action':_0x238abc['action']})};_0x1e307e['model']['bind']('isEnabled')['to'](_0x1b105d,'isActionsDropdownOpen',_0x32304d=>'function'!=typeof _0x238abc['isEnabled']||(!_0x32304d||_0x238abc['isEnabled'](_0x1b105d))),_0xda6426['add'](_0x1e307e);}return _0xda6426;}(_0x35179a,_0x249be0);return _0x35179a['bind']('isActionsDropdownOpen')['to'](_0x4cf2b4,'isOpen'),_0x4cf2b4['buttonView']['set']({'label':g(_0xf93d72,'Show\x20more\x20items'),'tooltip':!0x0,'tooltipPosition':'sw','icon':_0x370fc}),_0x4cf2b4['extendTemplate']({'attributes':{'class':['ck-revision-history-sidebar__revision__actions',_0x3e9dd6['if']('isActionsDropdownOpen','ck-on')]},'on':{'click':_0x3e9dd6['to'](_0x447bdc=>_0x447bdc['stopPropagation']())}}),_0x4cf2b4['on']('execute',_0x33ce0b=>{_0x35179a['isReady']&&'function'==typeof _0x33ce0b['source']['_action']&&_0x33ce0b['source']['_action'](_0x35179a);}),_0x55a4f7(_0x4cf2b4,_0x21d296,{'role':'menu'}),_0x4cf2b4['listenTo'](_0x35179a,'change:isActionsDropdownOpen',(_0x1ceb48,_0xe1a642,_0x2090a4)=>{if(_0x2090a4)for(const _0x4da5a1 of _0x4cf2b4['listView']['items']){const _0x3f6c9f=_0x4da5a1['children']['first'],_0x348c9d=_0x249be0['find'](_0x4c8657=>_0x4c8657['action']===_0x3f6c9f['_action'])['isVisible'];_0x4da5a1['isVisible']=void 0x0===_0x348c9d||_0x348c9d(_0x35179a);}}),_0x4cf2b4;}class ai extends/* #__PURE__ -- @preserve */
|
|
26
|
+
_0x23fe54(_0xe6f994){['id'];['revisionNameView'];['revisionActionsView'];['_revision'];['_requireRevisionName'];constructor(_0x8e3293,_0x20b19f,_0x132e11,_0x45dbf1){super(_0x8e3293);const _0xb8570d=this['bindTemplate'],_0x373d8c=function(_0x1c560,_0x495c72){const _0x5c34dc=Array['from'](_0x495c72['authors'])['filter'](_0x372884=>_0x372884!=_0x495c72['creator']);return _0x495c72['creator']&&_0x5c34dc['unshift'](_0x495c72['creator']),_0x5c34dc['map'](_0x346517=>new oi(_0x1c560,_0x346517,_0x346517==_0x495c72['creator']));}(_0x8e3293,_0x20b19f);this['id']=_0x20b19f['id'],this['_revision']=_0x20b19f,this['_requireRevisionName']=_0x45dbf1,this['bind']('name','createdAt')['to'](_0x20b19f),this['bind']('_createdAtFormatted')['to'](this,'createdAt',_0x39b2f2=>{return _0xee0895=_0x8e3293['uiLanguage'],(_0x574120=_0x39b2f2)['toLocaleDateString'](_0xee0895,{'month':'long','day':'numeric'})+',\x20'+_0x574120['toLocaleTimeString'](_0xee0895,{'hour':'numeric','minute':'numeric'});var _0xee0895,_0x574120;}),this['set']('isSelected',!0x1),this['set']('isHighlighted',!0x1),this['set']('isActionsDropdownOpen',!0x1),this['set']('isReady',!0x1),this['set']('isEnabled',!0x1),this['revisionNameView']=new lt(_0x8e3293,ti),this['revisionNameView']['fieldView']['extendTemplate']({'attributes':{'maxlength':'220'}}),this['revisionNameView']['fieldView']['bind']('value')['to'](this,'name',_0xa740c2=>_0xa740c2||this['_createdAtFormatted']),this['revisionNameView']['bind']('isEnabled')['to'](this,'isSelected',this,'isEnabled',(_0xe4ad1,_0x5bf600)=>_0xe4ad1&&_0x5bf600),this['revisionActionsView']=_0x132e11&&_0x132e11['length']?ni(this,_0x132e11):'',this['revisionActionsView']&&this['revisionActionsView']['bind']('isEnabled')['to'](this),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision-wrapper',_0xb8570d['if']('isConfirm','ck-revision-history-sidebar__revision-wrapper_confirmation_visible')]},'children':[{'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision',_0xb8570d['if']('isEnabled','ck-disabled',_0x3edb91=>!_0x3edb91),_0xb8570d['if']('isSelected','ck-revision-history-sidebar__revision_selected'),_0xb8570d['if']('isHighlighted','ck-revision-history-sidebar__revision_highlighted'),_0xb8570d['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':_0xb8570d['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':_0x373d8c}]},this['revisionActionsView']],'on':{'click':_0xb8570d['to'](_0x53b8dc=>{_0x53b8dc['srcElement']['closest']('.ck-thread__remove-confirm')||this['isReady']&&this['isEnabled']&&this['fire']('select',{'id':this['id']});})}}]});}['render'](){super['render']();const _0x18df14=this['revisionNameView']['fieldView']['element'];this['listenTo'](_0x18df14,'change',()=>{this['_requireRevisionName']&&!_0x18df14['value']||this['fire']('setName',{'id':this['id'],'name':_0x18df14['value']}),_0x18df14['value']||(_0x18df14['value']=this['name']?this['name']:this['_createdAtFormatted']);});}['select'](){this['isSelected']=!0x0;}['deselect'](){this['isSelected']=!0x1;}['highlight'](){this['isHighlighted']=!0x0;}['unhighlight'](){this['isHighlighted']=!0x1;}}function vi(_0x760e91,_0x58ba7d){const _0x28a7c6=_0x3f16b2['fromJSDate'](_0x760e91)['setLocale'](_0x58ba7d),_0x3f49bf=_0x3f16b2['local'](),_0x2683b6=_0x3f49bf['minus']({'days':0x1})['startOf']('day');let _0x47fc31,_0x199a56;return _0x28a7c6['hasSame'](_0x3f49bf,'day')?(_0x47fc31=_0x28a7c6['startOf']('day')['toJSDate'](),_0x199a56=_0x28a7c6['toRelativeCalendar']()):_0x28a7c6['hasSame'](_0x2683b6,'day')?(_0x47fc31=_0x2683b6['toJSDate'](),_0x199a56=_0x28a7c6['toRelativeCalendar']()):_0x28a7c6['hasSame'](_0x3f49bf,'week')?(_0x47fc31=_0x28a7c6['startOf']('week')['toJSDate'](),_0x199a56=_0x28a7c6['weekdayLong']||''):_0x28a7c6['hasSame'](_0x3f49bf,'year')?(_0x47fc31=_0x28a7c6['startOf']('month')['toJSDate'](),_0x199a56=_0x28a7c6['monthLong']||''):(_0x47fc31=_0x28a7c6['startOf']('year')['toJSDate'](),_0x199a56=String(_0x28a7c6['year'])),{'startDate':_0x47fc31,'localizedPeriodName':_0x199a56};}class mi extends _0xe6f994{['startDate'];['revisionViews'];['_revisionActions'];['_requireRevisionName'];constructor(_0x383aa5,_0x543a73,_0x501b0c,_0x2e8ef3){super(_0x383aa5);const _0x35a393=vi(_0x543a73,this['locale']['uiLanguage'])['localizedPeriodName'];this['startDate']=_0x543a73,this['revisionViews']=this['createCollection'](),this['_revisionActions']=_0x501b0c,this['_requireRevisionName']=_0x2e8ef3,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':_0x35a393}]},{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__time-period__revisions']},'children':this['revisionViews']}]});}['addRevision'](_0xfc0d48){const _0xc517b1=new ai(this['locale'],_0xfc0d48,this['_revisionActions'],this['_requireRevisionName']);this['revisionViews']['add'](_0xc517b1);}['removeRevision'](_0xbc7540){const _0x1bddf3=this['revisionViews']['find'](_0x34c499=>_0x34c499['id']===_0xbc7540['id']);this['revisionViews']['remove'](_0x1bddf3);}}class as extends _0xe6f994{constructor(_0x32e228){super(_0x32e228);const _0x3fd92b=new _0x44385b();_0x3fd92b['content']=_0xe03c96,this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset_all','ck-revision-history-sidebar__header']},'children':[_0x3fd92b,{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__header__label']},'children':[g(_0x32e228,'Revision\x20history')]}]});}}class di extends _0xe6f994{['timePeriodViews'];['_revisions'];['_revisionActions'];['_requireRevisionName'];constructor(_0x18bfec,_0x4d9ba7,_0x277b39,_0x33edc5){super(_0x18bfec);const _0x43a6e1=this['bindTemplate'];this['timePeriodViews']=this['createCollection'](),this['timePeriodViews']['delegate']('select')['to'](this),this['timePeriodViews']['delegate']('setName')['to'](this),this['_revisions']=_0x4d9ba7,this['_revisionActions']=_0x277b39,this['_requireRevisionName']=_0x33edc5,this['on']('select',(_0x474078,_0x408af8)=>{this['fire']('revisionSelected',_0x408af8);}),this['on']('setName',(_0x21ffd2,_0x57ee13)=>{this['fire']('revisionSetName',_0x57ee13);}),this['set']('isEnabled',!0x1),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-rounded-corners','ck-revision-history-sidebar']},'children':[new as(_0x18bfec),{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__timeline',_0x43a6e1['if']('isEnabled','ck-disabled',_0x3345d4=>!_0x3345d4)]},'children':this['timePeriodViews']}]});}['render'](){super['render']();for(const _0x2d3cf2 of this['_revisions'])this['_addRevision'](_0x2d3cf2);this['_revisions']['on']('add',(_0x52ca59,_0x37ad74)=>{this['_addRevision'](_0x37ad74);}),this['_revisions']['on']('remove',(_0x23b81b,_0x4fc8d8)=>{this['_removeRevision'](_0x4fc8d8);});}get['revisionViews'](){return this['timePeriodViews']['map'](_0xa9497d=>_0xa9497d['revisionViews']['map'](_0x11455b=>_0x11455b))['flat']();}['selectRevision'](_0x55fd7c){for(const _0x154ffc of this['revisionViews'])_0x55fd7c&&_0x55fd7c['id']===_0x154ffc['id']?_0x154ffc['select']():_0x154ffc['deselect']();}['highlightRevisions'](_0x42c2a7){for(const _0x4b5d26 of this['revisionViews'])_0x42c2a7['some'](({id:_0x5dfaec})=>_0x5dfaec===_0x4b5d26['id'])?_0x4b5d26['highlight']():_0x4b5d26['unhighlight']();}['_addRevision'](_0x4c8b95){const _0x38c161=vi(_0x4c8b95['createdAt'],this['locale']['uiLanguage'])['startDate'];let _0x505533=this['timePeriodViews']['get'](0x0);_0x505533&&_0x505533['startDate']['getTime']()===_0x38c161['getTime']()||(_0x505533=new mi(this['locale'],_0x38c161,this['_revisionActions'],this['_requireRevisionName']),this['timePeriodViews']['add'](_0x505533)),_0x505533['addRevision'](_0x4c8b95);}['_removeRevision'](_0x24ed0a){const _0x540688=vi(_0x24ed0a['createdAt'],this['locale']['uiLanguage'])['startDate'];this['_getTimePeriodViewByStartDate'](_0x540688)['removeRevision'](_0x24ed0a);}['_getTimePeriodViewByStartDate'](_0x259eb3){return this['timePeriodViews']['find'](_0x2e64f5=>_0x2e64f5['startDate']['getTime']()===_0x259eb3['getTime']());}}class d extends _0x2ec88b{['_revisionViewer'];['_revisionsRepository'];['_sidebarView'];static ['defaultRevisionActions']=/* #__PURE__ -- @preserve */
|
|
27
27
|
((()=>['compareAgainstSelected','restoreRevision','nameRevision'])());static ['availableRevisionActions']=/* #__PURE__ -- @preserve */
|
|
28
|
-
|
|
29
|
-
_0x63457(_0x586b6d){['_ui'];get['ui'](){return this['_ui'];}constructor(_0x4f1207,_0x34721b){super(_0x34721b),this['sourceElement']=_0x4f1207,this['model']['document']['createRoot']();const _0x580198=new it(this['locale'],this['editing']['view'],{'shouldToolbarGroupWhenFull':!0x0});this['_ui']=new tt(this,_0x580198);}['destroy'](){return this['updateSourceElement'](),this['ui']['destroy'](),super['destroy']();}static async['create'](_0x2ed366,_0x562170){const _0x10226a=new this(_0x2ed366,_0x562170);return await _0x10226a['initPlugins'](),await _0x10226a['ui']['init'](_0x2ed366),await _0x10226a['data']['init'](_0x10226a['config']['get']('initialData')||''),_0x10226a['fire']('ready'),_0x10226a;}}const p=['RevisionHistoryUI','RestrictedEditingMode'];class _t extends _0x45698e{['result'];static get['pluginName'](){return'RevisionViewerIntegration';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x52d504){function _0x389aca(_0x3be52f){return _0x3be52f['map'](_0x489611=>String['fromCharCode'](_0x489611))['join']('');}super(_0x52d504),this['result']='end',_0x52d504[_0x389aca([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x389aca([0x76,0x69,0x65,0x77])][_0x389aca([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x389aca([0x61,0x75,0x74,0x6f]),_0x52d504[_0x389aca([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x389aca([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x389aca([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x389aca([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x389aca([0x6f,0x6b])});}}class k extends _0x45698e{['_viewerEditor'];static get['pluginName'](){return'RevisionHistory';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[u,f];}constructor(_0x425b85){if(super(_0x425b85),!this['editor']['config']['get']('revisionHistory'))throw new _0x44e14a('revision-history-missing-configuration',this);this['_viewerEditor']=null,this['set']('isRevisionViewerOpen',!0x1),this['editor']['config']['define']('revisionHistory.showRevisionViewerCallback',_0x267600=>this['_showRevisionViewer']({..._0x267600,'translations':this['editor']['locale']['translations']})),this['editor']['config']['define']('revisionHistory.closeRevisionViewerCallback',_0x2e4907=>this['_closeRevisionViewer'](_0x2e4907)),this['editor']['config']['define']('revisionHistory.restoreRevisionCallback',_0x3664ff=>this['_restoreRevision'](_0x3664ff)),this['editor']['config']['define']('revisionHistory.requireRevisionName',!0x1),this['_enhanceShowRevisionViewerCallback'](),this['_enhanceCloseRevisionViewerCallback']();}set['adapter'](_0x1aec58){this['editor']['plugins']['get']('RevisionTracker')['adapter']=_0x1aec58;}get['adapter'](){return this['editor']['plugins']['get']('RevisionTracker')['adapter'];}['addRevisionData'](_0x44de65){return this['editor']['plugins']['get']('RevisionTracker')['addRevisionData'](_0x44de65);}['getRevision'](_0xfe78f6){return this['editor']['plugins']['get']('RevisionsRepository')['getRevision'](_0xfe78f6);}['getRevisions'](_0x165159){return this['editor']['plugins']['get']('RevisionsRepository')['getRevisions'](_0x165159||{'toJSON':!0x1});}['_getRevisionViewerEditorConfig'](){const _0x5592db=this['editor'],_0x19fc2a=_0x29abcc(_0x5592db,p),_0x3e3a85=_0x5592db['plugins']['get']('RevisionTracker'),_0x3630b5=_0x5592db['plugins']['get']('Users')['users'];return _0x19fc2a['toolbar']=['exitToEditing','restoreRevision','changesNavigation'],delete _0x19fc2a['lazyRoots'],(_0x19fc2a['plugins']['push'](_t,m,R,class extends _0x45698e{static get['requires'](){return[m,'Users'];}['init'](){const _0x2e7a9c=this['editor']['plugins']['get']('Users');for(const _0x3e703d of _0x3630b5)_0x3e703d['isAnonymous']||_0x2e7a9c['getUser'](_0x3e703d['id'])||_0x2e7a9c['addUser'](_0x3e703d);const _0x27145f=_0x3e3a85['repository']['getRevisions']();let _0x518ea9=null;const _0x3d47bc=this['editor']['plugins']['get']('RevisionViewer');_0x3d47bc['adapter']=_0x3e3a85['adapter'],_0x3d47bc['bind']('isEnabled')['to'](_0x3e3a85),this['editor']['commands']['get']('restoreRevision')['bind']('isEnabled')['to'](_0x5592db,'isReadOnly',_0xb08aa3=>!_0xb08aa3);for(const _0x49fc4b of _0x27145f){const _0x342f83=null===_0x49fc4b['creator'];if(_0x342f83&&_0x49fc4b['toVersion']===_0x49fc4b['fromVersion'])continue;const _0x1bbef0=_0x49fc4b['toJSON']();_0x3d47bc['addRevisionData'](_0x1bbef0,(_0x29d8c5,_0x53e32a,_0x31b8bf)=>{if(_0x342f83){if(_0x518ea9)_0x518ea9['_update'](_0x29d8c5,_0x53e32a);else{if(!_0x53e32a){const _0x508ad9=_0x31b8bf['toJSON']();_0x508ad9['id']=_0x2bf2c8(),_0x3e3a85['saveRevision'](_0x508ad9,_0x31b8bf['toVersion'])['then'](_0x288c6b=>{_0x518ea9=_0x288c6b;});}}}else _0x49fc4b['_update'](_0x29d8c5,_0x53e32a);});}}},d),_0x19fc2a);}['_enhanceShowRevisionViewerCallback'](){const _0x3b52c0=this['editor']['config']['get']('revisionHistory')['showRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.showRevisionViewerCallback',async()=>{this['editor']['enableReadOnlyMode']('revision-history-viewer-opened');const _0x4073c7=this['editor']['plugins']['get']('RevisionTracker');if(this['editor']['plugins']['has']('Autosave')){const _0x4e1488=this['editor']['plugins']['get']('Autosave');await _0x4e1488['save']();}else await _0x4073c7['update']();if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('Dialog')){const _0x2d3253=this['editor']['plugins']['get']('Dialog');_0x2d3253['isOpen']&&_0x2d3253['hide']();}const _0x2da63f=this['_getRevisionViewerEditorConfig']();return _0x3b52c0(_0x2da63f)['then'](_0x23bfc1=>{return(this['_viewerEditor']=_0x23bfc1,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'),_0x23bfc1);})['catch'](_0x26923c=>(console['error'](_0x26923c),this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),null));});}['_enhanceCloseRevisionViewerCallback'](){const _0x24bafe=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'](),_0x24bafe(this['_viewerEditor'])['then'](()=>{if(this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),this['_viewerEditor']=null,this['editor']['plugins']['has']('Annotations')){const _0x15908d=this['editor']['plugins']['get']('Annotations');_0x15908d['refreshVisibility'](),_0x15908d['refreshPositioning']();}})));}['_showRevisionViewer'](_0x51cb4f){const _0x2df896=this['editor']['config']['get']('revisionHistory.editorContainer'),_0x2545b6=this['editor']['config']['get']('revisionHistory.viewerContainer'),_0x1f0189=this['editor']['config']['get']('revisionHistory.viewerEditorElement');return w['create'](_0x1f0189,_0x51cb4f)['then'](_0x389694=>(_0x2545b6['style']['display']='block',_0x2df896['style']['display']='none',this['isRevisionViewerOpen']=!0x0,_0x389694));}['_closeRevisionViewer'](_0x3ae41a){const _0x4d93be=this['editor']['config']['get']('revisionHistory.editorContainer');return this['editor']['config']['get']('revisionHistory.viewerContainer')['style']['display']='none',_0x4d93be['style']['display']='',this['isRevisionViewerOpen']=!0x1,_0x3ae41a['destroy']();}async['_restoreRevision'](_0x24dd20){const _0x5d42b8=this['editor'],_0x3b75ba=this['_viewerEditor']['plugins']['get']('RevisionViewer'),_0x5a31b7=_0x5d42b8['plugins']['get']('RevisionTracker'),_0x177b8e=_0x5d42b8['plugins']['get']('RevisionHistoryUtils'),_0x4528a0=_0x3b75ba['repository']['getRevision'](_0x24dd20);let _0x43d004,_0xcbb65f,_0x56a834;try{await _0x177b8e['loadRevisionData'](_0x4528a0,this['adapter']),_0x43d004=_0x177b8e['getRevisionDocumentData'](_0x4528a0),_0xcbb65f=_0x177b8e['getRevisionRootsAttributes'](_0x4528a0);}catch(_0x29fea8){return void console['error'](_0x29fea8);}_0x5d42b8['model']['change'](_0xa116ce=>{for(const _0x33e76b of Array['from'](_0x5d42b8['model']['markers']['getMarkersGroup']('restrictedEditingException')))_0xa116ce['removeMarker'](_0x33e76b);}),_0x3b75ba['isReady']=!0x1,_0x5d42b8['model']['enqueueChange'](_0x331b93=>{_0x331b93['setSelection'](null),_0x331b93['removeSelectionAttribute'](_0x5d42b8['model']['document']['selection']['getAttributeKeys']());const _0x3d5f5f=Object['keys'](_0x43d004);for(const _0x2860c9 of _0x5d42b8['model']['document']['roots'])'$graveyard'!=_0x2860c9['rootName']&&_0x2860c9['isAttached']()&&!_0x3d5f5f['includes'](_0x2860c9['rootName'])&&_0x331b93['detachRoot'](_0x2860c9);for(const _0x167d6c of _0x3d5f5f){let _0x5e5bc8=_0x5d42b8['model']['document']['getRoot'](_0x167d6c);_0x5e5bc8&&_0x5e5bc8['isAttached']()||(_0x5e5bc8=_0x331b93['addRoot'](_0x167d6c));const _0x3526f5=_0xcbb65f[_0x167d6c],_0x2da33d=Object['keys'](_0x3526f5),_0x366e7d=_0x43d004[_0x167d6c];for(const _0x429bf9 of _0x5e5bc8['getAttributeKeys']())_0x2da33d['includes'](_0x429bf9)||_0x331b93['removeAttribute'](_0x429bf9,_0x5e5bc8);for(const _0x34c5e3 of _0x2da33d)_0x331b93['setAttribute'](_0x34c5e3,_0xcbb65f[_0x167d6c][_0x34c5e3],_0x5e5bc8);_0x331b93['remove'](_0x331b93['createRangeIn'](_0x5e5bc8)),_0x331b93['insert'](_0x5d42b8['data']['parse'](_0x366e7d,_0x5e5bc8),_0x5e5bc8,0x0);}});const _0xaa114c=g(_0x5d42b8['locale'],'Restored');if(_0x4528a0['name'])_0x56a834=-0x1==_0x4528a0['name']['indexOf'](_0xaa114c)?_0xaa114c+':\x20'+_0x4528a0['name']:_0x4528a0['name'];else _0x56a834=_0xaa114c+':\x20'+(_0x4528a0['createdAt']['toLocaleDateString'](_0x5d42b8['locale']['uiLanguage'],{'month':'long','day':'numeric'})+',\x20'+_0x4528a0['createdAt']['toLocaleTimeString'](_0x5d42b8['locale']['uiLanguage'],{'hour':'numeric','minute':'numeric'}));return await _0x5a31b7['saveRevision']({'name':_0x56a834}),_0x3b75ba['isReady']=!0x0,_0x5d42b8['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}}export{h as Revision,k as RevisionHistory,f as RevisionHistoryUI,V as RevisionHistoryUtils,u as RevisionTracker,m as RevisionViewer,w as RevisionViewerEditor,ge as RevisionViewerLoadingOverlay,R as RevisionViewerUI,I as RevisionsRepository,d as RevisionsSidebar};
|
|
28
|
+
_t();static get['pluginName'](){return'RevisionsSidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[m];}constructor(_0x506718){super(_0x506718),this['_revisionViewer']=_0x506718['plugins']['get'](m),this['_revisionsRepository']=this['_revisionViewer']['repository'],this['_sidebarView']=null;}['init'](){const _0x7b2aff=this['_revisionsRepository']['_revisions'],_0x490b50=this['_createRevisionActions'](),_0x5e172c=this['editor']['config']['get']('revisionHistory.viewerSidebarContainer');this['_sidebarView']=new di(this['editor']['locale'],_0x7b2aff,_0x490b50,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',(_0x358ff4,_0x4420a3)=>{_0x4420a3['revisionViews']['on']('add',(_0x3cafeb,_0x1779f9)=>{_0x1779f9['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)),_0x5e172c['appendChild'](this['_sidebarView']['element']);}['destroy'](){this['_sidebarView']['element']['remove'](),this['_sidebarView']['destroy']();}['_handleEditorDataReady'](){const _0x7555ca=this['_revisionsRepository']['getRevision'](0x0);if(_0x7555ca){const _0x2cfefa=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x7555ca['id']);this['_revisionViewer']['compare'](_0x7555ca,_0x2cfefa);}}['_handleRevisionSelected'](_0x206242,_0x57dcd0){const _0x32600a=this['_revisionsRepository']['getRevision'](_0x57dcd0['id']),_0x1f9522=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x32600a['id']);this['_revisionViewer']['compare'](_0x32600a,_0x1f9522);}['_handleRevisionSetName'](_0x35e67a,_0x5c90d8){this['_revisionsRepository']['getRevision'](_0x5c90d8['id'])['setName'](_0x5c90d8['name']);}['_handleDiffChange'](_0x1248eb,_0x44fccd,_0x3578e7){const _0x2df390=this['_revisionsRepository']['getRevisionsInDiff'](_0x3578e7);_0x2df390['length']>0x2?(this['_sidebarView']['highlightRevisions'](_0x2df390),this['_sidebarView']['selectRevision'](null)):(this['_sidebarView']['highlightRevisions']([]),this['_sidebarView']['selectRevision'](_0x2df390[0x0]));}['_createRevisionActions'](){const _0x37a74d=this['editor'],_0x16f5c3=d['availableRevisionActions'],_0x1eeca7=_0x37a74d['config']['get']('revisionHistory.revisionActions')||d['defaultRevisionActions'];if(_0x1eeca7['length'])return _0x1eeca7['map'](_0x3f9260=>{const _0x1be456='string'==typeof _0x3f9260?Object['assign']({},_0x16f5c3[_0x3f9260]):_0x3f9260;return _0x1be456['action']=_0x1be456['action']['bind'](this,_0x37a74d),_0x1be456['isVisible']&&(_0x1be456['isVisible']=_0x1be456['isVisible']['bind'](this,_0x37a74d)),_0x1be456;});}}function _t(){return{'compareAgainstSelected':{'name':'Compare\x20against\x20selected','action':({plugins:_0x579897},_0x1cb4ee)=>{const _0x4d43b8=_0x579897['get'](m),_0x1fcfbd=_0x4d43b8['repository'];let _0x4e5276=_0x4d43b8['diff']['newRevisionId'],_0x243e6b=_0x1cb4ee['id'];_0x1fcfbd['getIndex'](_0x4e5276)>_0x1fcfbd['getIndex'](_0x243e6b)&&([_0x4e5276,_0x243e6b]=[_0x243e6b,_0x4e5276]),_0x4d43b8['compare'](_0x4e5276,_0x243e6b);},'isVisible':({plugins:_0x18fb9f},_0x5d0b03)=>{const _0x487aad=_0x18fb9f['get'](m);return!(_0x487aad['repository']['getRevisionsInDiff'](_0x487aad['diff'])['length']>0x2)&&!_0x5d0b03['isSelected'];}},'restoreRevision':{'name':'Restore\x20this\x20revision','action':(_0x41ee60,{id:_0x4a212c})=>{_0x41ee60['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x4a212c);},'isVisible':({plugins:_0x50755a},_0x4bcfe8)=>!!_0x50755a['get'](m)['repository']['getLaterVisibleRevision'](_0x4bcfe8['id'])},'nameRevision':{'name':'Name\x20this\x20revision','action':({plugins:_0x22635c},{id:_0x4dc9eb,revisionNameView:_0x2b54a0})=>{const _0x50133c=_0x22635c['get'](m),_0x29b4be=_0x50133c['repository']['getEarlierVisibleRevision'](_0x4dc9eb);_0x50133c['compare'](_0x4dc9eb,_0x29b4be),_0x2b54a0['focus'](),_0x2b54a0['fieldView']['select']();}}};}class tt extends st{['_view'];['_toolbarConfig'];['_elementReplacer'];get['view'](){return this['_view'];}constructor(_0x35ccf1,_0x25e440){super(_0x35ccf1),this['_view']=_0x25e440,this['_toolbarConfig']=et(_0x35ccf1['config']['get']('toolbar')),this['_elementReplacer']=new ot();}get['element'](){return this['view']['element'];}['init'](_0x5d6cd5){const _0x3bd435=this['editor'],_0x5a10f7=this['view'],_0x81f4e7=_0x3bd435['editing']['view'],_0x36b393=_0x5a10f7['editable'],_0x23263c=_0x81f4e7['document']['getRoot']();_0x36b393['name']=_0x23263c['rootName'],_0x5a10f7['render']();const _0x5f1d28=_0x36b393['element'];this['setEditableElement'](_0x36b393['name'],_0x5f1d28),_0x5a10f7['editable']['bind']('isFocused')['to'](this['focusTracker']),_0x81f4e7['attachDomRoot'](_0x5f1d28),this['_elementReplacer']['replace'](_0x5d6cd5,this['element']),this['_initToolbar'](),this['fire']('ready');}['destroy'](){super['destroy']();const _0xc301f1=this['view'],_0x433c7a=this['editor']['editing']['view'];this['_elementReplacer']['restore'](),_0x433c7a['detachDomRoot'](_0xc301f1['editable']['name']),_0xc301f1['destroy']();}['_initToolbar'](){const _0x1acec6=this['view'];_0x1acec6['stickyPanel']['bind']('isActive')['to'](this['focusTracker'],'isFocused'),_0x1acec6['stickyPanel']['limiterElement']=_0x1acec6['element'],_0x1acec6['stickyPanel']['bind']('viewportTopOffset')['to'](this,'viewportOffset',({top:_0x58fc25})=>_0x58fc25),_0x1acec6['toolbar']['fillFromConfig'](this['_toolbarConfig'],this['componentFactory']),this['addToolbar'](_0x1acec6['toolbar']);}}class it extends rt{['_editable'];['stickyPanel'];['toolbar'];get['editable'](){return this['_editable'];}constructor(_0x330da8,_0x2c0715,_0x18196e={}){super(_0x330da8),this['stickyPanel']=new ht(_0x330da8),this['toolbar']=new dt(_0x330da8,{'shouldGroupWhenFull':_0x18196e['shouldToolbarGroupWhenFull']}),this['_editable']=new ct(_0x330da8,_0x2c0715);}['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
|
+
_0x5b5f2e(_0xd3a18){['_ui'];get['ui'](){return this['_ui'];}constructor(_0x3c85f5,_0x586b8d){super(_0x586b8d),this['sourceElement']=_0x3c85f5,this['model']['document']['createRoot']();const _0x249732=new it(this['locale'],this['editing']['view'],{'shouldToolbarGroupWhenFull':!0x0});this['_ui']=new tt(this,_0x249732);}['destroy'](){return this['updateSourceElement'](),this['ui']['destroy'](),super['destroy']();}static async['create'](_0x449708,_0xa694e1){const _0x1f7a4c=new this(_0x449708,_0xa694e1);return await _0x1f7a4c['initPlugins'](),await _0x1f7a4c['ui']['init'](_0x449708),await _0x1f7a4c['data']['init'](_0x1f7a4c['config']['get']('initialData')||''),_0x1f7a4c['fire']('ready'),_0x1f7a4c;}}const p=['RevisionHistoryUI','RestrictedEditingMode'];class yt extends _0x2ec88b{['result'];static get['pluginName'](){return'RevisionViewerIntegration';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x2eb5db){function _0x116867(_0xf7ca70){return _0xf7ca70['map'](_0x5c5d56=>String['fromCharCode'](_0x5c5d56))['join']('');}super(_0x2eb5db),this['result']='end',_0x2eb5db[_0x116867([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x116867([0x76,0x69,0x65,0x77])][_0x116867([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x116867([0x61,0x75,0x74,0x6f]),_0x2eb5db[_0x116867([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x116867([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x116867([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x116867([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x116867([0x6f,0x6b])});}}class k extends _0x2ec88b{['_viewerEditor'];static get['pluginName'](){return'RevisionHistory';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[u,f];}constructor(_0x451f80){if(super(_0x451f80),!this['editor']['config']['get']('revisionHistory'))throw new _0x579d8c('revision-history-missing-configuration',this);this['_viewerEditor']=null,this['set']('isRevisionViewerOpen',!0x1),this['editor']['config']['define']('revisionHistory.showRevisionViewerCallback',_0x3947fa=>this['_showRevisionViewer']({..._0x3947fa,'translations':this['editor']['locale']['translations']})),this['editor']['config']['define']('revisionHistory.closeRevisionViewerCallback',_0x3c2009=>this['_closeRevisionViewer'](_0x3c2009)),this['editor']['config']['define']('revisionHistory.restoreRevisionCallback',_0x3e7ecd=>this['_restoreRevision'](_0x3e7ecd)),this['editor']['config']['define']('revisionHistory.requireRevisionName',!0x1),this['_enhanceShowRevisionViewerCallback'](),this['_enhanceCloseRevisionViewerCallback']();}set['adapter'](_0x34251a){this['editor']['plugins']['get']('RevisionTracker')['adapter']=_0x34251a;}get['adapter'](){return this['editor']['plugins']['get']('RevisionTracker')['adapter'];}['addRevisionData'](_0x3e1604){return this['editor']['plugins']['get']('RevisionTracker')['addRevisionData'](_0x3e1604);}['getRevision'](_0x14ce03){return this['editor']['plugins']['get']('RevisionsRepository')['getRevision'](_0x14ce03);}['getRevisions'](_0x3fc460){return this['editor']['plugins']['get']('RevisionsRepository')['getRevisions'](_0x3fc460||{'toJSON':!0x1});}['_getRevisionViewerEditorConfig'](){const _0x514f88=this['editor'],_0x26c598=_0x4b8a9e(_0x514f88,p),_0x6abb28=_0x514f88['plugins']['get']('RevisionTracker'),_0x29ce26=_0x514f88['plugins']['get']('Users')['users'];return _0x26c598['toolbar']=['exitToEditing','restoreRevision','changesNavigation'],delete _0x26c598['lazyRoots'],(_0x26c598['plugins']['push'](yt,m,R,class extends _0x2ec88b{static get['requires'](){return[m,'Users'];}['init'](){const _0x1ebf18=this['editor']['plugins']['get']('Users');for(const _0x2c10f5 of _0x29ce26)_0x2c10f5['isAnonymous']||_0x1ebf18['getUser'](_0x2c10f5['id'])||_0x1ebf18['addUser'](_0x2c10f5);const _0x577d23=_0x6abb28['repository']['getRevisions']();let _0x50fee8=null;const _0x4a232a=this['editor']['plugins']['get']('RevisionViewer');_0x4a232a['adapter']=_0x6abb28['adapter'],_0x4a232a['bind']('isEnabled')['to'](_0x6abb28),this['editor']['commands']['get']('restoreRevision')['bind']('isEnabled')['to'](_0x514f88,'isReadOnly',_0x1787ea=>!_0x1787ea);for(const _0x26b9d6 of _0x577d23){const _0x12ca44=null===_0x26b9d6['creator'];if(_0x12ca44&&_0x26b9d6['toVersion']===_0x26b9d6['fromVersion'])continue;const _0x111b91=_0x26b9d6['toJSON']();_0x4a232a['addRevisionData'](_0x111b91,(_0x173939,_0x34d36d,_0x318d87)=>{if(_0x12ca44){if(_0x50fee8)_0x50fee8['_update'](_0x173939,_0x34d36d);else{if(!_0x34d36d){const _0x1a80a6=_0x318d87['toJSON']();_0x1a80a6['id']=_0x1facad(),_0x6abb28['saveRevision'](_0x1a80a6,_0x318d87['toVersion'])['then'](_0x2f8d9c=>{_0x50fee8=_0x2f8d9c;});}}}else _0x26b9d6['_update'](_0x173939,_0x34d36d);});}}},d),_0x26c598);}['_enhanceShowRevisionViewerCallback'](){const _0x4e9ed6=this['editor']['config']['get']('revisionHistory')['showRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.showRevisionViewerCallback',async()=>{this['editor']['enableReadOnlyMode']('revision-history-viewer-opened');const _0x5340f1=this['editor']['plugins']['get']('RevisionTracker');if(this['editor']['plugins']['has']('Autosave')){const _0x3e9512=this['editor']['plugins']['get']('Autosave');await _0x3e9512['save']();}else await _0x5340f1['update']();if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('Dialog')){const _0x2d4a5a=this['editor']['plugins']['get']('Dialog');_0x2d4a5a['isOpen']&&_0x2d4a5a['hide']();}const _0x227829=this['_getRevisionViewerEditorConfig']();return _0x4e9ed6(_0x227829)['then'](_0x3c0e4e=>{return(this['_viewerEditor']=_0x3c0e4e,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'),_0x3c0e4e);})['catch'](_0x544bc0=>(console['error'](_0x544bc0),this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),null));});}['_enhanceCloseRevisionViewerCallback'](){const _0xb1faf0=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'](),_0xb1faf0(this['_viewerEditor'])['then'](()=>{if(this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),this['_viewerEditor']=null,this['editor']['plugins']['has']('Annotations')){const _0x574763=this['editor']['plugins']['get']('Annotations');_0x574763['refreshVisibility'](),_0x574763['refreshPositioning']();}})));}['_showRevisionViewer'](_0x428350){const _0x523370=this['editor']['config']['get']('revisionHistory.editorContainer'),_0x3a8839=this['editor']['config']['get']('revisionHistory.viewerContainer'),_0x283ef5=this['editor']['config']['get']('revisionHistory.viewerEditorElement');return w['create'](_0x283ef5,_0x428350)['then'](_0x55833e=>(_0x3a8839['style']['display']='block',_0x523370['style']['display']='none',this['isRevisionViewerOpen']=!0x0,_0x55833e));}['_closeRevisionViewer'](_0x48ee73){const _0x16396a=this['editor']['config']['get']('revisionHistory.editorContainer');return this['editor']['config']['get']('revisionHistory.viewerContainer')['style']['display']='none',_0x16396a['style']['display']='',this['isRevisionViewerOpen']=!0x1,_0x48ee73['destroy']();}async['_restoreRevision'](_0x441808){const _0x1ed9c5=this['editor'],_0x13da02=this['_viewerEditor']['plugins']['get']('RevisionViewer'),_0x191f40=_0x1ed9c5['plugins']['get']('RevisionTracker'),_0x3cbd1c=_0x1ed9c5['plugins']['get']('RevisionHistoryUtils'),_0x5ea892=_0x13da02['repository']['getRevision'](_0x441808);let _0x47eb1c,_0x4d58ca,_0x339907;try{await _0x3cbd1c['loadRevisionData'](_0x5ea892,this['adapter']),_0x47eb1c=_0x3cbd1c['getRevisionDocumentData'](_0x5ea892),_0x4d58ca=_0x3cbd1c['getRevisionRootsAttributes'](_0x5ea892);}catch(_0x2d7bb3){return void console['error'](_0x2d7bb3);}_0x1ed9c5['model']['change'](_0x1e221f=>{for(const _0x42841f of Array['from'](_0x1ed9c5['model']['markers']['getMarkersGroup']('restrictedEditingException')))_0x1e221f['removeMarker'](_0x42841f);}),_0x13da02['isReady']=!0x1,_0x1ed9c5['model']['enqueueChange'](_0x5e4f55=>{_0x5e4f55['setSelection'](null),_0x5e4f55['removeSelectionAttribute'](_0x1ed9c5['model']['document']['selection']['getAttributeKeys']());const _0x2259fb=Object['keys'](_0x47eb1c);for(const _0x25e2c8 of _0x1ed9c5['model']['document']['roots'])'$graveyard'!=_0x25e2c8['rootName']&&_0x25e2c8['isAttached']()&&!_0x2259fb['includes'](_0x25e2c8['rootName'])&&_0x5e4f55['detachRoot'](_0x25e2c8);for(const _0xdb581a of _0x2259fb){let _0x137481=_0x1ed9c5['model']['document']['getRoot'](_0xdb581a);_0x137481&&_0x137481['isAttached']()||(_0x137481=_0x5e4f55['addRoot'](_0xdb581a));const _0x4c12f3=_0x4d58ca[_0xdb581a],_0xeeaba2=Object['keys'](_0x4c12f3),_0x19ccd7=_0x47eb1c[_0xdb581a];for(const _0x380d00 of _0x137481['getAttributeKeys']())_0xeeaba2['includes'](_0x380d00)||_0x5e4f55['removeAttribute'](_0x380d00,_0x137481);for(const _0x128824 of _0xeeaba2)_0x5e4f55['setAttribute'](_0x128824,_0x4d58ca[_0xdb581a][_0x128824],_0x137481);_0x5e4f55['remove'](_0x5e4f55['createRangeIn'](_0x137481)),_0x5e4f55['insert'](_0x1ed9c5['data']['parse'](_0x19ccd7,_0x137481),_0x137481,0x0);}});const _0x436382=g(_0x1ed9c5['locale'],'Restored');if(_0x5ea892['name'])_0x339907=-0x1==_0x5ea892['name']['indexOf'](_0x436382)?_0x436382+':\x20'+_0x5ea892['name']:_0x5ea892['name'];else _0x339907=_0x436382+':\x20'+(_0x5ea892['createdAt']['toLocaleDateString'](_0x1ed9c5['locale']['uiLanguage'],{'month':'long','day':'numeric'})+',\x20'+_0x5ea892['createdAt']['toLocaleTimeString'](_0x1ed9c5['locale']['uiLanguage'],{'hour':'numeric','minute':'numeric'}));return await _0x191f40['saveRevision']({'name':_0x339907}),_0x13da02['isReady']=!0x0,_0x1ed9c5['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};
|