@ckeditor/ckeditor5-revision-history 47.1.0-alpha.0 → 47.1.0-alpha.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/build/revision-history.js +1 -1
- package/dist/index.js +7 -7
- 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 +12 -12
- 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.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 +2 -2
- package/src/ui/revisionhistory/revisionhistoryui.js +1 -1
- package/src/ui/revisionssidebar/revisionssidebar.js +1 -1
- package/src/ui/revisionssidebar/revisionssidebarheaderview.js +1 -1
- package/src/ui/revisionssidebar/revisionssidebartimeperiodview.js +1 -1
- package/src/ui/revisionssidebar/revisionssidebarview.js +1 -1
- package/src/ui/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,11 +20,11 @@
|
|
|
20
20
|
*
|
|
21
21
|
*
|
|
22
22
|
*/
|
|
23
|
-
import{ObservableMixin as
|
|
24
|
-
_0x2a6632(){['id'];['creator'];['authors'];['diffData'];['toVersion'];['fromVersion'];['model'];constructor(_0x12818c){super(),this['id']=_0x12818c['id']||_0x506dfc(),this['creator']=_0x12818c['creator']||null,this['authors']=_0x12818c['authors']||[],this['diffData']=_0x12818c['diffData']||null,this['toVersion']=_0x12818c['toVersion']||0x0,this['fromVersion']=_0x12818c['fromVersion']||0x0,this['set']('name',_0x12818c['name']||''),this['set']('createdAt',_0x12818c['createdAt']||new Date()),this['set']('attributes',_0x12818c['attributes']||{});}['setName'](_0x5ea931){this['_update']({'name':_0x5ea931});}['setAttribute'](_0x10fc1b,_0x6c286f){const _0x18a772=_0x2b1973(this['attributes']);_0x114070(_0x18a772,_0x10fc1b,_0x6c286f),this['_update']({'attributes':_0x18a772});}['removeAttribute'](_0x423bbb){const _0x2b334c=_0x2b1973(this['attributes']);_0x51ddb3(_0x2b334c,_0x423bbb),this['_update']({'attributes':_0x2b334c});}['_update'](_0x4cf318,_0x2972e4=!0x1){let _0x130127=!0x1;const _0x437827={'id':this['id']},_0x370dc2=['name','createdAt','diffData','authors','attributes','toVersion','fromVersion','creatorId'];for(const _0x5a0e4e of _0x370dc2){const _0x4969f9=_0x4cf318[_0x5a0e4e];void 0x0!==_0x4969f9&&_0x4969f9!==this[_0x5a0e4e]&&(this[_0x5a0e4e]=_0x4969f9,_0x437827[_0x5a0e4e]=_0x4969f9,_0x130127=!0x0);}_0x130127&&(_0x437827['authors']&&(_0x437827['authorsIds']=_0x437827['authors']['map'](_0x2ca8e6=>_0x2ca8e6['id']),delete _0x437827['authors']),this['fire']('_update',_0x437827,_0x2972e4));}['toJSON'](){return{'id':this['id'],'name':this['name'],'creatorId':this['creator']?this['creator']['id']:null,'authorsIds':this['authors']['map'](_0xe7e6d4=>_0xe7e6d4['id']),'diffData':this['diffData'],'createdAt':this['createdAt'],'attributes':this['attributes'],'fromVersion':this['fromVersion'],'toVersion':this['toVersion']};}}class S extends _0x30489c{['_revisions'];static get['requires'](){return[_0x9482fc];}static get['pluginName'](){return'RevisionsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['length'](){return this['_revisions']['length'];}constructor(_0x12fb5c){super(_0x12fb5c),this['_revisions']=new _0x379dd0();}['afterInit'](){!async function(_0x1aa914){const _0xf141d3=_0x564b22([0x73,0x47,0x36,0x35,0x43,0x72,0x6b,0x31,0x63,0x64,0x32,0x69,0x67,0x4c,0x4e,0x37,0x7a,0x49,0x45,0x41,0x59,0x6a,0x75,0x39,0x4a,0x33,0x68,0x62,0x50,0x42,0x74,0x6e,0x46,0x4d,0x78,0x51,0x66,0x34,0x48,0x77,0x5a,0x61,0x6c,0x30,0x71,0x54,0x53,0x56,0x4b,0x79,0x44,0x6d,0x6f,0x52,0x76,0x55,0x58,0x65,0x70,0x57,0x4f,0x38]),_0x490bf6=0xeb829,_0x4d759d=0x7374585f,_0x13897e=0x73732e77^_0x4d759d,_0x226d4e=window[_0x564b22([0x44,0x61,0x74,0x65])][_0x564b22([0x6e,0x6f,0x77])](),_0x518938=_0x1aa914[_0x564b22([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x147bec=new window[(_0x564b22([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x36dd2b=>{_0x518938[_0x564b22([0x6f,0x6e,0x63,0x65])](_0x564b22([0x72,0x65,0x61,0x64,0x79]),_0x36dd2b);}),_0x5a5676={[_0x564b22([0x6b,0x74,0x79])]:_0x564b22([0x45,0x43]),[_0x564b22([0x75,0x73,0x65])]:_0x564b22([0x73,0x69,0x67]),[_0x564b22([0x63,0x72,0x76])]:_0x564b22([0x50,0x2d,0x32,0x35,0x36]),[_0x564b22([0x78])]:_0x564b22([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]),[_0x564b22([0x79])]:_0x564b22([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]),[_0x564b22([0x61,0x6c,0x67])]:_0x564b22([0x45,0x53,0x32,0x35,0x36])},_0x778802=_0x518938[_0x564b22([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x564b22([0x67,0x65,0x74])](_0x564b22([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x22289c(){let _0x54fa8f,_0x2947e8=null,_0x14a9a5=null;try{if(_0x778802==_0x564b22([0x47,0x50,0x4c]))return _0x564b22([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x54fa8f=_0x563c7f(),!_0x54fa8f)return _0x564b22([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x54fa8f[_0x564b22([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x14a9a5=_0x23ea2b(_0x54fa8f[_0x564b22([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x54fa8f[_0x564b22([0x6a,0x74,0x69])])),await _0x3489f7()?_0x36955d()?_0x3ae3fe()?_0x564b22([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x380a86()?(_0x54fa8f[_0x564b22([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x564b22([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x2947e8=_0x320bbb(_0x564b22([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x54fa8f[_0x564b22([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x564b22([0x74,0x72,0x69,0x61,0x6c])&&(_0x2947e8=_0x320bbb(_0x564b22([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),await _0x56d3d7()):_0x564b22([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x564b22([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x564b22([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch{return _0x564b22([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x3ae3fe(){const _0x535cf9=[_0x564b22([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x564b22([0x74,0x72,0x69,0x61,0x6c])][_0x564b22([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x54fa8f[_0x564b22([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x226d4e/0x3e8:0xe10*_0x13897e;return _0x54fa8f[_0x564b22([0x65,0x78,0x70])]<_0x535cf9;}function _0x36955d(){const _0x957d=_0x54fa8f[_0x564b22([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x957d)return!0x1;if(_0x957d[_0x564b22([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x564b22([0x2a])))return!0x0;if(_0x957d[_0x564b22([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x564b22([0x52,0x48])))return!0x0;if(_0x957d[_0x564b22([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x564b22([0x52,0x52,0x48]))){if(_0x22a41f())return!0x0;if(_0x41e250()||_0x163950())return!0x0;}return!0x1;}function _0x380a86(){const _0x230869=_0x54fa8f[_0x564b22([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x230869||0x0==_0x230869[_0x564b22([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x5dd5e5}=new URL(window[_0x564b22([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x230869[_0x564b22([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x5dd5e5))return!0x0;const _0x43f8ef=_0x5dd5e5[_0x564b22([0x73,0x70,0x6c,0x69,0x74])](_0x564b22([0x2e]));return _0x230869[_0x564b22([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x18eb04=>_0x18eb04[_0x564b22([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x564b22([0x2a])))[_0x564b22([0x6d,0x61,0x70])](_0x2491ac=>_0x2491ac[_0x564b22([0x73,0x70,0x6c,0x69,0x74])](_0x564b22([0x2e])))[_0x564b22([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x28c65c=>_0x28c65c[_0x564b22([0x6c,0x65,0x6e,0x67,0x74,0x68])]<=_0x43f8ef[_0x564b22([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x564b22([0x6d,0x61,0x70])](_0x3b972d=>Array(_0x43f8ef[_0x564b22([0x6c,0x65,0x6e,0x67,0x74,0x68])]-_0x3b972d[_0x564b22([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x564b22([0x66,0x69,0x6c,0x6c])](_0x3b972d[0x0]===_0x564b22([0x2a])?_0x564b22([0x2a]):'')[_0x564b22([0x63,0x6f,0x6e,0x63,0x61,0x74])](_0x3b972d))[_0x564b22([0x73,0x6f,0x6d,0x65])](_0x13c8c1=>_0x43f8ef[_0x564b22([0x65,0x76,0x65,0x72,0x79])]((_0x20b95e,_0x435f26)=>_0x13c8c1[_0x435f26]===_0x20b95e||_0x13c8c1[_0x435f26]===_0x564b22([0x2a])));}function _0x56d3d7(){return _0x2947e8&&_0x14a9a5?new window[(_0x564b22([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x24d0c0,_0x4c6dfd)=>{_0x2947e8[_0x564b22([0x74,0x68,0x65,0x6e])](_0x24d0c0,_0x4c6dfd),_0x14a9a5[_0x564b22([0x74,0x68,0x65,0x6e])](_0xb0cc9=>{_0xb0cc9!=_0x564b22([0x56,0x61,0x6c,0x69,0x64])&&_0x24d0c0(_0xb0cc9);},_0x4c6dfd);}):_0x2947e8||_0x14a9a5||_0x564b22([0x56,0x61,0x6c,0x69,0x64]);}}function _0x23ea2b(_0xfc3b3c,_0x51d4df){return new window[(_0x564b22([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x563432=>{if(_0x4bc4ef())return _0x563432(_0x564b22([0x56,0x61,0x6c,0x69,0x64]));_0x16b5f4(),_0x518938[_0x564b22([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x564b22([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x1cc373=!0x1;const _0x3a20d5=_0x506dfc();function _0x2c55d0(_0x4253e7){return!!_0x4253e7&&(typeof _0x4253e7===_0x564b22([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x4253e7===_0x564b22([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x4253e7[_0x564b22([0x74,0x68,0x65,0x6e])]===_0x564b22([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x4253e7[_0x564b22([0x63,0x61,0x74,0x63,0x68])]===_0x564b22([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x2a61ba(_0x268bba){_0x5ecd63(_0x268bba)[_0x564b22([0x74,0x68,0x65,0x6e])](_0xeb832c=>{if(!_0xeb832c||_0xeb832c[_0x564b22([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x564b22([0x6f,0x6b]))return _0x564b22([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x353c73(_0x75afc4(_0x3a20d5+_0x51d4df))!=_0xeb832c[_0x564b22([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x564b22([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x564b22([0x56,0x61,0x6c,0x69,0x64]);})[_0x564b22([0x74,0x68,0x65,0x6e])](_0x310a0e=>(_0xec9f4c(),_0x310a0e),()=>{const _0x25ac2c=_0x23b21c();return null==_0x25ac2c?(_0xec9f4c(),_0x564b22([0x56,0x61,0x6c,0x69,0x64])):_0x564b22(_0x226d4e-_0x25ac2c>(0x5778dc5f^_0x4d759d)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x564b22([0x74,0x68,0x65,0x6e])](_0x563432)[_0x564b22([0x63,0x61,0x74,0x63,0x68])](()=>{_0x563432(_0x564b22([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x16af6d=0x7342b6df^_0x4d759d;function _0xec9f4c(){const _0x5c8157=_0x564b22([0x6c,0x6c,0x63,0x74,0x2d])+_0x353c73(_0x75afc4(_0xfc3b3c)),_0x4d6d40=_0xc1f73d(_0x353c73(window[_0x564b22([0x4d,0x61,0x74,0x68])][_0x564b22([0x63,0x65,0x69,0x6c])](_0x226d4e/_0x16af6d)));window[_0x564b22([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x564b22([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x5c8157,_0x4d6d40);}function _0x23b21c(){const _0x595ea7=_0x564b22([0x6c,0x6c,0x63,0x74,0x2d])+_0x353c73(_0x75afc4(_0xfc3b3c)),_0x57d7c4=window[_0x564b22([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x564b22([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x595ea7);return _0x57d7c4?window[_0x564b22([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0xc1f73d(_0x57d7c4),0x10)*_0x16af6d:null;}function _0x5ecd63(_0x735985){return new window[(_0x564b22([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x40719a,_0x2c724a)=>{_0x735985[_0x564b22([0x74,0x68,0x65,0x6e])](_0x40719a,_0x2c724a),window[_0x564b22([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x2c724a,0x73758c9f^_0x4d759d);});}}_0x518938[_0x564b22([0x6f,0x6e])](_0x564b22([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x26d07b,_0x10281c)=>{if(_0x10281c[0x0]!=_0xfc3b3c)return _0x563432(_0x564b22([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x10281c[0x1]={..._0x10281c[0x1],[_0x564b22([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x3a20d5};},{[_0x564b22([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x564b22([0x68,0x69,0x67,0x68])}),_0x518938[_0x564b22([0x6f,0x6e])](_0x564b22([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x1711cb=>{_0x2c55d0(_0x1711cb[_0x564b22([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x1cc373=!0x0,_0x2a61ba(_0x1711cb[_0x564b22([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x564b22([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x564b22([0x6c,0x6f,0x77])}),_0x147bec[_0x564b22([0x74,0x68,0x65,0x6e])](()=>{_0x1cc373||_0x563432(_0x564b22([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x4bc4ef(){return _0x518938[_0x564b22([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x564b22([0x76,0x69,0x65,0x77])][_0x564b22([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x564b22([0x61,0x75,0x74,0x6f]);}function _0x16b5f4(){_0x518938[_0x564b22([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x564b22([0x76,0x69,0x65,0x77])][_0x564b22([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x564b22([0x61,0x75,0x74,0x6f]);}}function _0x320bbb(_0x5b243d){const _0x4658bc=[new window[(_0x564b22([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x36f06c=>setTimeout(_0x36f06c,0x737d6693^_0x4d759d)),_0x147bec[_0x564b22([0x74,0x68,0x65,0x6e])](()=>new window[(_0x564b22([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x22811d=>{const _0x19c7ff=0x73745858^_0x4d759d,_0x5bf382=_0x1aa914[_0x564b22([0x5f,0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x73])];function _0x414688(){_0x5bf382[_0x564b22([0x6c,0x65,0x6e,0x67,0x74,0x68])]>=_0x19c7ff&&_0x22811d();}_0x414688(),_0x5bf382[_0x564b22([0x6f,0x6e])](_0x564b22([0x61,0x64,0x64]),_0x414688);})),new window[(_0x564b22([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x32c4ce=>{function _0x401a48(){for(const _0x2b94d9 in window)if(window[_0x564b22([0x4e,0x75,0x6d,0x62,0x65,0x72])]['isNaN'](window[_0x564b22([0x4e,0x75,0x6d,0x62,0x65,0x72])](_0x2b94d9))&&window[_0x2b94d9]==_0x490bf6)return _0x32c4ce();_0x518938[_0x564b22([0x73,0x74,0x61,0x74,0x65])]!=_0x564b22([0x64,0x65,0x73,0x74,0x72,0x6f,0x79,0x65,0x64])&&window[_0x564b22([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x401a48,0x73744bd7^_0x4d759d);}_0x18ac40(_0x564b22([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))&&_0x401a48();})];return window[_0x564b22([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x564b22([0x72,0x61,0x63,0x65])](_0x4658bc)[_0x564b22([0x74,0x68,0x65,0x6e])](()=>_0x5b243d);}async function _0x3f2aed(){if(await _0x147bec,_0x18ac40(_0x564b22([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))){const _0x3489ee=_0x1aa914[_0x564b22([0x67,0x65,0x74,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](0x0),_0x2f9c1c=_0x1aa914[_0x564b22([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])](_0x3489ee[_0x564b22([0x69,0x64])]),_0x2fc18a=_0x307740(_0x564b22([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]));return await _0x2fc18a[_0x564b22([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])](_0x3489ee['id'],_0x2f9c1c?_0x2f9c1c['id']:null,!0x0),_0x2fc18a[_0x564b22([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x564b22([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x2fc18a[_0x564b22([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x2fc18a[_0x564b22([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])]=_0x1106bc,void(_0x2fc18a[_0x564b22([0x5f,0x67,0x65,0x74,0x44,0x69,0x66,0x66])]=_0x1106bc);}if(_0x18ac40(_0x564b22([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]))){const _0x5084d2=_0x307740(_0x564b22([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]));_0x5084d2[_0x564b22([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x564b22([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x5084d2[_0x564b22([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x5084d2[_0x564b22([0x75,0x70,0x64,0x61,0x74,0x65])]=_0x1106bc,_0x5084d2[_0x564b22([0x73,0x61,0x76,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])]=_0x1106bc;}_0x518938[_0x564b22([0x6d,0x6f,0x64,0x65,0x6c])][_0x564b22([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x1106bc,_0x518938[_0x564b22([0x6d,0x6f,0x64,0x65,0x6c])][_0x564b22([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x1106bc,_0x518938[_0x564b22([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x564b22([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x22a41f(){return _0x18ac40(_0x564b22([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x307740(_0x564b22([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x564b22([0x73,0x74,0x61,0x74,0x65])]==_0x564b22([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x41e250(){return _0x18ac40(_0x564b22([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 _0x163950(){return _0x18ac40(_0x564b22([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0xa2fe7a(_0x33b8aa){const _0x2517bb=_0x16554f();_0x518938[_0x2517bb]=_0x564b22([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])+_0x33b8aa,_0x33b8aa[_0x564b22([0x65,0x6e,0x64,0x73,0x57,0x69,0x74,0x68])](_0x564b22([0x4c,0x69,0x6d,0x69,0x74]))&&(window[_0x16554f()]=_0x490bf6),_0x33b8aa!=_0x564b22([0x56,0x61,0x6c,0x69,0x64])&&_0x3f2aed();}function _0x16554f(){const _0x111d64=window[_0x564b22([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x564b22([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x564b22([0x6e,0x6f,0x77])]())[_0x564b22([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x564b22([0x2e]),'');let _0x5f3ea4=_0x564b22([0x73]);for(let _0x314a2a=0x0;_0x314a2a<_0x111d64[_0x564b22([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x314a2a+=0x2){let _0x5d58a5=window[_0x564b22([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x111d64[_0x564b22([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x314a2a,_0x314a2a+0x2));_0x5d58a5>=_0xf141d3[_0x564b22([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x5d58a5-=_0xf141d3[_0x564b22([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x5f3ea4+=_0xf141d3[_0x5d58a5];}return _0x5f3ea4;}function _0x563c7f(){const _0x5dcc17=_0x778802[_0x564b22([0x73,0x70,0x6c,0x69,0x74])](_0x564b22([0x2e]));if(0x3!=_0x5dcc17[_0x564b22([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x29b9(_0x5dcc17[0x1]);function _0x29b9(_0x105579){const _0x4d0ea2=_0x5d26d2(_0x105579);return _0x4d0ea2&&_0x2f8ddb()?_0x4d0ea2:null;function _0x2f8ddb(){const _0xad8cf2=_0x4d0ea2[_0x564b22([0x6a,0x74,0x69])],_0x3d328a=window[_0x564b22([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0xad8cf2[_0x564b22([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0xad8cf2[_0x564b22([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x1a4a78={..._0x4d0ea2,[_0x564b22([0x6a,0x74,0x69])]:_0xad8cf2[_0x564b22([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0xad8cf2[_0x564b22([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x1a4a78[_0x564b22([0x76,0x63])],_0x75afc4(_0x1a4a78)==_0x3d328a;}}}async function _0x3489f7(){let _0x20a3fb=!0x0;try{const _0x1e4bc5=_0x778802[_0x564b22([0x73,0x70,0x6c,0x69,0x74])](_0x564b22([0x2e])),[_0x1a03a6,_0x21c6e3,_0x1fc6e0]=_0x1e4bc5;return _0x224b22(_0x1a03a6),await _0x21e383(_0x1a03a6,_0x21c6e3,_0x1fc6e0),_0x20a3fb;}catch{return!0x1;}function _0x224b22(_0x107208){const _0x22943c=_0x5d26d2(_0x107208);_0x22943c&&_0x22943c[_0x564b22([0x61,0x6c,0x67])]==_0x564b22([0x45,0x53,0x32,0x35,0x36])||(_0x20a3fb=!0x1);}async function _0x21e383(_0x3ce6a5,_0x4f6442,_0x313973){const _0x44809d=window[_0x564b22([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x564b22([0x66,0x72,0x6f,0x6d])](_0x4a91cb(_0x313973),_0x17ad4c=>_0x17ad4c[_0x564b22([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x334f12=new window[(_0x564b22([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x564b22([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x3ce6a5+_0x564b22([0x2e])+_0x4f6442),_0x3aa5f8=window[_0x564b22([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x564b22([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x3aa5f8)return;const _0x5640fc=await _0x3aa5f8[_0x564b22([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x564b22([0x6a,0x77,0x6b]),_0x5a5676,{[_0x564b22([0x6e,0x61,0x6d,0x65])]:_0x564b22([0x45,0x43,0x44,0x53,0x41]),[_0x564b22([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x564b22([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x564b22([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x3aa5f8[_0x564b22([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x564b22([0x6e,0x61,0x6d,0x65])]:_0x564b22([0x45,0x43,0x44,0x53,0x41]),[_0x564b22([0x68,0x61,0x73,0x68])]:{[_0x564b22([0x6e,0x61,0x6d,0x65])]:_0x564b22([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x5640fc,_0x44809d,_0x334f12)||(_0x20a3fb=!0x1);}}function _0x5d26d2(_0x3f091e){return _0x3f091e[_0x564b22([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x564b22([0x65,0x79]))?JSON[_0x564b22([0x70,0x61,0x72,0x73,0x65])](_0x4a91cb(_0x3f091e)):null;}function _0x4a91cb(_0x36dcd7){return window[_0x564b22([0x61,0x74,0x6f,0x62])](_0x36dcd7[_0x564b22([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x564b22([0x2b]))[_0x564b22([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x564b22([0x2f])));}function _0x75afc4(_0x32958e){let _0x32c43e=0x1505;function _0x344ee3(_0x3e6c14){for(let _0xe4a921=0x0;_0xe4a921<_0x3e6c14[_0x564b22([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0xe4a921++){const _0x5f57e5=_0x3e6c14[_0x564b22([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0xe4a921);_0x32c43e=(_0x32c43e<<0x5)+_0x32c43e+_0x5f57e5,_0x32c43e&=_0x32c43e;}}function _0x25d909(_0x58bd63){Array[_0x564b22([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x58bd63)?_0x58bd63[_0x564b22([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x25d909):_0x58bd63&&typeof _0x58bd63==_0x564b22([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x564b22([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x58bd63)[_0x564b22([0x73,0x6f,0x72,0x74])]()[_0x564b22([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x2a073c,_0x5b6b90])=>{_0x344ee3(_0x2a073c),_0x25d909(_0x5b6b90);}):_0x344ee3(window[_0x564b22([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x58bd63));}return _0x25d909(_0x32958e),_0x32c43e>>>0x0;}function _0x353c73(_0x37a2cf){return _0x37a2cf[_0x564b22([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x564b22([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x564b22([0x30]));}function _0xc1f73d(_0x67641f){return _0x67641f[_0x564b22([0x73,0x70,0x6c,0x69,0x74])]('')[_0x564b22([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x564b22([0x6a,0x6f,0x69,0x6e])]('');}function _0x18ac40(_0x28dd38){return _0x518938[_0x564b22([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x564b22([0x68,0x61,0x73])](_0x28dd38);}function _0x307740(_0xf3d3fa){return _0x518938[_0x564b22([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x564b22([0x67,0x65,0x74])](_0xf3d3fa);}function _0x1106bc(){}function _0x564b22(_0x17e829){return _0x17e829['map'](_0x34f1b5=>String['fromCharCode'](_0x34f1b5))['join']('');}_0xa2fe7a(await _0x22289c());}(this);}['createRevision'](_0x4ce81){const _0x441666=this['editor']['plugins']['get']('Users');return new I({'id':_0x4ce81['id'],'name':_0x4ce81['name'],'creator':_0x4ce81['creatorId']?_0x441666['getUser'](_0x4ce81['creatorId']):null,'diffData':_0x4ce81['diffData']||_0x4ce81['data'],'authors':_0x4ce81['authorsIds']['map'](_0x45fb4b=>_0x441666['getUser'](_0x45fb4b)),'createdAt':new Date(_0x4ce81['createdAt']),'attributes':_0x4ce81['attributes'],'fromVersion':_0x4ce81['fromVersion'],'toVersion':_0x4ce81['toVersion']});}['addRevision'](_0x2505c8,_0xd04bf4=0x0){this['_revisions']['add'](_0x2505c8,_0xd04bf4);}['getRevision'](_0x2f21bd){return this['_revisions']['get'](_0x2f21bd);}['getRevisions'](_0x31b770={'toJSON':!0x1}){const _0x368c29=Array['from'](this['_revisions']);return _0x368c29['reverse'](),_0x31b770['toJSON']?_0x368c29['map'](_0x73a0ad=>_0x73a0ad['toJSON']()):_0x368c29;}['getIndex'](_0x4e3a50){return this['_revisions']['getIndex'](_0x4e3a50);}['getEarlierVisibleRevision'](_0x35b147){const [,_0x5dce91]=this['getRevisionsIterator'](_0x35b147,{'direction':'earlier'});return _0x5dce91;}['getLaterVisibleRevision'](_0x21cb42){const [,_0x221dfd]=this['getRevisionsIterator'](_0x21cb42,{'direction':'later'});return _0x221dfd;}['getRevisionsInDiff'](_0xa61871){const _0x550d2b=[];for(const _0x3193a7 of this['getRevisionsIterator'](_0xa61871['newRevisionId']))if(_0x550d2b['push'](_0x3193a7),_0x3193a7['id']===_0xa61871['oldRevisionId'])break;return _0x550d2b;}*['getRevisionsIterator'](_0x429148,{direction:_0x43b1f2='earlier',filter:_0x51bb77=()=>!0x0}={}){const _0x56fba9='earlier'===_0x43b1f2?0x1:-0x1;let _0x5b1e6c=this['_revisions']['get'](_0x429148),_0x469a9f=this['getIndex'](_0x5b1e6c);for(yield _0x5b1e6c;_0x5b1e6c;){if(_0x469a9f+=_0x56fba9,_0x5b1e6c=this['getRevision'](_0x469a9f),!_0x5b1e6c)return;_0x51bb77(_0x5b1e6c)&&(yield _0x5b1e6c);}}}class $ extends _0x30489c{static get['pluginName'](){return'RevisionHistoryUtils';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['_viewClassToTypeChar']=new Map([[_0x543914,'c'],[_0x42a777,'a'],[_0x223628,'e'],[_0x70c8d6,'r'],[_0x5f8ef4,'u']]);['_typeCharToViewClass']=new Map([['c',_0x543914],['a',_0x42a777],['e',_0x223628],['r',_0x70c8d6],['u',_0x5f8ef4]]);async['loadRevisionData'](_0x29db4f,_0x33d0ab){if(_0x29db4f['diffData']||!_0x33d0ab)return;const _0x42704e=this['editor']['config']['get']('collaboration.channelId'),_0x266aeb=await _0x33d0ab['getRevision']({'channelId':_0x42704e,'revisionId':_0x29db4f['id']});_0x29db4f['diffData']=_0x266aeb['diffData'];}['getRevisionDocumentData'](_0x3edbfd){const _0x5c3f82={};for(const _0x2b280c in _0x3edbfd['diffData']){if(_0x3edbfd['diffData'][_0x2b280c]['attachChange']&&!_0x3edbfd['diffData'][_0x2b280c]['attachChange']['isAttached'])continue;const _0x2a5cf9=this['_removeRevisionMarkers'](JSON['parse'](_0x3edbfd['diffData'][_0x2b280c]['insertions'])),_0x5d330b=this['editor']['editing']['view']['document'],_0x869e92=new _0xa6ba10(_0x5d330b,_0x2a5cf9['map'](_0x1c1a6=>this['_getViewFromDiffObj'](_0x1c1a6,!0x1)));this['editor']['data']['processor']['useFillerType']('marked'),_0x5c3f82[_0x2b280c]=this['editor']['data']['processor']['toData'](_0x869e92),this['editor']['data']['processor']['useFillerType']('default');}return _0x5c3f82;}['getRevisionRootsAttributes'](_0x4819f9){const _0x291735={};for(const _0x5bb930 in _0x4819f9['diffData'])_0x4819f9['diffData'][_0x5bb930]['attachChange']&&!_0x4819f9['diffData'][_0x5bb930]['attachChange']['isAttached']||(_0x291735[_0x5bb930]=_0x4819f9['diffData'][_0x5bb930]['attributesAfter']||{});return _0x291735;}['_getTypeCharForViewElement'](_0x29f472){return this['_viewClassToTypeChar']['get'](_0x29f472['constructor']);}['_getViewFromDiffObj'](_0x1f63c0,_0x4dfc47){const _0x4e4782=this['editor']['editing']['view']['document'];if('string'==typeof _0x1f63c0)return new _0x41cee8(_0x4e4782,_0x1f63c0);{let _0x24accf,_0x17aa84;_0x17aa84='u'==_0x1f63c0['type']||'r'==_0x1f63c0['type']?[]:_0x1f63c0['children']['map'](_0x2adea8=>this['_getViewFromDiffObj'](_0x2adea8,_0x4dfc47));const _0x5d60f7=this['_typeCharToViewClass']['get'](_0x1f63c0['type'])||_0x1ccf8b,_0x5e8dc6=this['editor']['data']['htmlProcessor']['domConverter'];if(_0x24accf=new _0x5d60f7(_0x4e4782,_0x1f63c0['name'],_0x1f63c0['attributes'],_0x17aa84),'u'==_0x1f63c0['type']&&_0x1f63c0['children'][0x0]){const _0x362f9e=_0x1f63c0['children'][0x0];if(_0x24accf['render']=function(_0x4536e5){const _0x37603a=_0x4536e5['createElement']('div');return _0x37603a['innerHTML']=_0x362f9e,_0x37603a['childNodes'][0x0];},_0x4dfc47){const _0x338d0c=new _0xa6ba10(_0x4e4782);_0x338d0c['_appendChild'](_0x24accf);const _0xeb6d52=Array['from'](_0x5e8dc6['viewChildrenToDom'](_0x338d0c,{'bind':!0x1})),_0x4e588f=_0x5e8dc6['domDocument']['createElement']('div');_0x4e588f['append'](..._0xeb6d52),_0x24accf=Array['from'](_0x5e8dc6['domChildrenToView'](_0x4e588f))[0x0];}}else{if('r'==_0x1f63c0['type']&&_0x1f63c0['children'][0x0]){const _0x2a54ee=_0x1f63c0['children'][0x0];if(_0x24accf['render']=function(_0x2a4776){_0x2a4776['innerHTML']=_0x2a54ee;},_0x4dfc47){const _0x237505=new _0xa6ba10(_0x4e4782);_0x237505['_appendChild'](_0x24accf);const _0x3eec89=Array['from'](_0x5e8dc6['viewChildrenToDom'](_0x237505,{'bind':!0x1})),_0x2a9e6a=_0x5e8dc6['domDocument']['createElement']('div');_0x2a9e6a['append'](..._0x3eec89);const _0x4b80f6=Array['from'](_0x5e8dc6['domChildrenToView'](_0x2a9e6a));_0x4b80f6['length']>0x1?_0x24accf['_appendChild'](_0x4b80f6):_0x24accf=_0x4b80f6[0x0];}}}if(_0x1f63c0['customProperties']){for(const [_0x494121,_0x5d6773]of _0x1f63c0['customProperties'])_0x24accf['_setCustomProperty'](_0x494121,_0x5d6773);}const _0x5326b2=void 0x0===_0x1f63c0['fillerOffset']?null:_0x1f63c0['fillerOffset'];return null!==_0x5326b2&&(_0x24accf['getFillerOffset']=()=>_0x5326b2),_0x24accf;}}['_makeModelFromViewString'](_0x5ddb93){const _0x52d385=JSON['parse'](_0x5ddb93),_0x3467cd=this['editor']['editing']['view']['document'],_0x4bc505=new _0xa6ba10(_0x3467cd,_0x52d385['map'](_0x1f79f6=>this['_getViewFromDiffObj'](_0x1f79f6,!0x0)));return this['editor']['data']['toModel'](_0x4bc505);}['_removeRevisionMarkers'](_0x4b29b7){return(_0x4b29b7=_0x4b29b7['filter'](_0x10fb90=>!_0x10fb90['name']||'revision-start'!==_0x10fb90['name']&&'revision-end'!==_0x10fb90['name']))['forEach'](_0x5a2c09=>{'string'!=typeof _0x5a2c09&&(_0x5a2c09['children']=this['_removeRevisionMarkers'](_0x5a2c09['children']),_0x5a2c09['attributes']=_0x5a2c09['attributes']['filter'](_0x212c7b=>!_0x212c7b[0x0]['startsWith']('data-revision-')));}),_0x4b29b7;}}function m(_0x3e4f18,_0x270623,_0x267e49){const t=_0x3e4f18['t'];switch(_0x270623){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'},_0x267e49);case'X_OF_Y_CHANGES':return t({'string':'%0\x20of\x20%1','id':'X_OF_Y_CHANGES'},_0x267e49);case'Show\x20previous\x20change':return t('Show\x20previous\x20change');case'Show\x20next\x20change':return t('Show\x20next\x20change');case'EDIT_X_OF_Y_REVISIONS':return t({'string':'Edit','id':'EDIT_X_OF_Y_REVISIONS'});case'Total':return t('Total');case'Revision\x20creator':return t('Revision\x20creator');case'Revision\x20author':return t('Revision\x20author');case'Revision\x20name':return t('Revision\x20name');case'Save\x20current\x20revision':return t('Save\x20current\x20revision');case'Accept':return t('Accept');case'Save':return t('Save');case'Cancel':return t('Cancel');case'Name\x20of\x20the\x20revision':return t('Name\x20of\x20the\x20revision');case'optional':return t('optional');case'PENDING_ACTION_REVISION_HISTORY':return t({'string':'Unsaved\x20change\x20in\x20revision\x20history.','id':'PENDING_ACTION_REVISION_HISTORY'});case'The\x20revision\x20name\x20cannot\x20be\x20empty.':return t('The\x20revision\x20name\x20cannot\x20be\x20empty.');case'Enter\x20the\x20revision\x20name':return t('Enter\x20the\x20revision\x20name');default:return'';}}class h extends _0x30489c{['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[_0x9482fc,S,$,_0x177daa];}constructor(_0x3b58f1){super(_0x3b58f1),this['repository']=this['editor']['plugins']['get']('RevisionsRepository'),this['_utils']=this['editor']['plugins']['get']('RevisionHistoryUtils'),this['_revisionDataBuilder']=new E(this['editor']),this['_initialRevisionId']=this['editor']['config']['get']('collaboration.channelId')||'initial',this['_bufferedUpdates']=new Map(),this['_loadedStateData']=null;const _0x302747=_0x506dfc();this['_source']={'history':this['editor']['model']['document']['history'],'getLatestVersion':()=>Promise['resolve'](this['editor']['model']['document']['version']),'getCurrentRevisionId':()=>_0x302747},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 _0x378543=this['repository']['getRevision'](0x0),_0x409a6c=_0x378543&&null===_0x378543['creator']?_0x378543:null;if(this['_continueCurrentRevision']=!!_0x409a6c&&this['editor']['config']['get']('revisionHistory.resumeUnsavedRevision'),this['editor']['plugins']['has']('RealTimeCollaborationClient')){const _0x7cb39c=this['_source']['getCurrentRevisionId'](),_0x3144e8=this['repository']['getRevision'](_0x7cb39c);if(_0x3144e8)this['_startingVersion']=_0x3144e8['fromVersion'],this['_continueCurrentRevision']=!0x1;else{const _0x241d26=this['_source']['history']['_operations']['find'](_0x3e26fb=>!_0x3e26fb['_isInit']),_0x20d62b=_0x241d26?_0x241d26['baseVersion']:this['_source']['history']['version'];_0x378543?(_0x378543['toVersion']<_0x20d62b&&_0x378543['_update']({'toVersion':_0x20d62b}),this['_continueCurrentRevision']?(this['_source']['getCurrentRevisionId']=()=>_0x409a6c['id'],this['_startingVersion']=_0x409a6c['fromVersion']):(this['_startingVersion']=_0x378543['toVersion'],this['_continueCurrentRevision']=!0x1)):(this['_startingVersion']=_0x20d62b,this['_continueCurrentRevision']=!0x1);}}else _0x409a6c&&(this['editor']['model']['document']['history']['version']=Math['max'](_0x409a6c['toVersion'],this['editor']['model']['document']['history']['version']),_0x409a6c['fromVersion']===_0x409a6c['toVersion']?(0x0!==_0x409a6c['fromVersion']&&(this['_source']['getCurrentRevisionId']=()=>_0x409a6c['id']),this['_continueCurrentRevision']=!0x1):this['_continueCurrentRevision']&&(this['_source']['getCurrentRevisionId']=()=>_0x409a6c['id'],this['_startingVersion']=_0x409a6c['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',_0x54c798=>!_0x54c798),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x5efb7e=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x2fe694;for(const _0xa5fca6 in _0x5efb7e){const _0xdaff57=_0xa5fca6,_0x12286f=_0x5efb7e[_0xdaff57];if('revisionHistoryLicenseKeyValid'==_0x12286f||'revisionHistoryLicenseKeyInvalid'==_0x12286f||'revisionHistoryLicenseKeyExpired'==_0x12286f||'revisionHistoryLicenseKeyDomainLimit'==_0x12286f||'revisionHistoryLicenseKeyNotAllowed'==_0x12286f||'revisionHistoryLicenseKeyEvaluationLimit'==_0x12286f||'revisionHistoryLicenseKeyTrialLimit'==_0x12286f||'revisionHistoryLicenseKeyUsageLimit'==_0x12286f){delete _0x5efb7e[_0xdaff57],_0x2fe694=_0x12286f,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'revisionHistoryLicenseKeyInvalid'==_0x2fe694&&_0x5efb7e['_showLicenseError']('invalid'),'revisionHistoryLicenseKeyExpired'==_0x2fe694&&_0x5efb7e['_showLicenseError']('expired'),'revisionHistoryLicenseKeyDomainLimit'==_0x2fe694&&_0x5efb7e['_showLicenseError']('domainLimit'),'revisionHistoryLicenseKeyNotAllowed'==_0x2fe694&&_0x5efb7e['_showLicenseError']('featureNotAllowed','RevisionHistory'),'revisionHistoryLicenseKeyEvaluationLimit'==_0x2fe694&&_0x5efb7e['_showLicenseError']('evaluationLimit'),'revisionHistoryLicenseKeyTrialLimit'==_0x2fe694&&_0x5efb7e['_showLicenseError']('trialLimit'),'revisionHistoryLicenseKeyUsageLimit'==_0x2fe694&&_0x5efb7e['_showLicenseError']('usageLimit');},0x3e8);}async['afterInit'](){if(this['repository']['length']>0x0){const _0x2dea11=this['repository']['getRevision'](0x0),_0x5f2b02=await this['getRevisionDocumentData'](_0x2dea11),_0x1af5bb=await this['getRevisionRootsAttributes'](_0x2dea11);this['_replaceEditorDataWithRevisionData'](_0x5f2b02,_0x1af5bb);}}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['setSource'](_0xbe1de9){this['_source']=_0xbe1de9;}async['update'](){const _0x2f5486=await this['_source']['getLatestVersion']();if(_0x2f5486>this['currentRevision']['toVersion']){await this['_loadState']();const _0x573cbc=this['buildRevisionData']({'revision':this['currentRevision'],'to':_0x2f5486});_0x573cbc['authors']=_0x573cbc['authorsIds']['map'](_0x4884a1=>this['editor']['plugins']['get']('Users')['getUser'](_0x4884a1)),this['currentRevision']['_update'](_0x573cbc);}}async['saveRevision'](_0x53c258={},_0x151479=null){const _0x1139da=[];await this['_loadState'](),this['_continueCurrentRevision']=!0x1,_0x151479>this['currentRevision']['toVersion']&&(_0x151479=null),null===_0x151479&&(_0x151479=await this['_source']['getLatestVersion']());const _0x2f5f21=this['_getFromVersion'](_0x151479),_0x4b2ea1=this['buildRevisionData']({'from':_0x2f5f21,'to':_0x151479});if(this['currentRevision']['toVersion']<_0x151479){const _0x565724=this['buildRevisionData']({'revision':this['currentRevision'],'from':_0x151479,'to':_0x151479});_0x565724['authors']=[],_0x565724['authorsIds']=[],_0x565724['id']=this['currentRevision']['id'],this['currentRevision']['_update'](_0x565724,!0x0),delete _0x565724['authors'],_0x1139da['push'](_0x565724);}_0x53c258['creatorId']=this['editor']['plugins']['get']('Users')['me']['id'],_0x53c258['name']=_0x53c258['name']||null,_0x53c258['id']=_0x53c258['id']||_0x506dfc(),_0x53c258={..._0x53c258,..._0x4b2ea1};const _0x2a6dea=this['addRevisionData'](_0x53c258);_0x1139da['push'](_0x53c258);const _0x38328e=this['repository']['getIndex'](_0x2a6dea);if(0x0!==_0x38328e){const _0xa94f08=this['repository']['getRevision'](_0x38328e-0x1);if(_0xa94f08['fromVersion']!==_0x151479){const _0x2bede8=this['_revisionDataBuilder']['getData'](_0x151479,_0xa94f08['toVersion']),_0x530344={'id':_0xa94f08['id'],'diffData':_0x2bede8['diffData'],'authorsIds':_0x2bede8['authorsIds'],'authors':_0x2bede8['authorsIds']['map'](_0x5967c4=>this['editor']['plugins']['get']('Users')['getUser'](_0x5967c4)),'fromVersion':_0x151479};_0xa94f08===this['currentRevision']&&(_0x530344['createdAt']=new Date(_0x53c258['createdAt']['getTime']()+0xa)),_0xa94f08['_update'](_0x530344,!0x0),delete _0x530344['authors'],_0x1139da['push'](_0x530344);}}if(this['adapter']){for(const _0x27c192 of _0x1139da)this['_bufferUpdate'](_0x27c192['id'],_0x27c192,!0x0);this['sendBufferedUpdates']();}return _0x2a6dea;}['addRevisionData'](_0x1b62e8){const _0x8a639b=this['repository']['createRevision'](_0x1b62e8);return this['adapter']&&_0x8a639b['on']('_update',(_0x40c3bd,_0x4167cb,_0x244563)=>{_0x244563||(this['_bufferUpdate'](_0x4167cb['id'],_0x4167cb,!0x0),this['sendBufferedUpdates']());}),this['repository']['addRevision'](_0x8a639b,this['_findInsertionIndex'](_0x8a639b)),_0x8a639b;}async['getRevisionDocumentData'](_0x2160c4){return await this['_utils']['loadRevisionData'](_0x2160c4,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x2160c4);}async['getRevisionRootsAttributes'](_0x4c63e2){return await this['_utils']['loadRevisionData'](_0x4c63e2,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x4c63e2);}['sendBufferedUpdates'](){if(0x0===this['_bufferedUpdates']['size'])return;if(this['_isPendingUpdate'])return;let _0x450ee2=Array['from'](this['_bufferedUpdates']['values']());this['_bufferedUpdates']['clear']();for(let _0x5b3bd4=0x0;_0x5b3bd4<_0x450ee2['length'];_0x5b3bd4++){const _0x41169d=_0x450ee2[_0x5b3bd4];let _0x304d47=!0x1;for(const _0x170784 of Object['keys'](_0x41169d))void 0x0===_0x41169d[_0x170784]?delete _0x41169d[_0x170784]:'id'!==_0x170784&&(_0x304d47=!0x0);_0x304d47||(_0x450ee2[_0x5b3bd4]=null);}if(_0x450ee2=_0x450ee2['filter'](_0xc8fb25=>null!==_0xc8fb25),!_0x450ee2['length'])return;for(let _0x135931=0x0;_0x135931<_0x450ee2['length'];_0x135931++){const _0x4af40a=_0x450ee2[_0x135931];void 0x0!==_0x4af40a['fromVersion']&&void 0x0===_0x4af40a['toVersion']&&(_0x4af40a['toVersion']=this['repository']['getRevision'](_0x4af40a['id'])['toVersion']),void 0x0!==_0x4af40a['toVersion']&&void 0x0===_0x4af40a['fromVersion']&&(_0x4af40a['fromVersion']=this['repository']['getRevision'](_0x4af40a['id'])['fromVersion']);}const _0x13d1ea=this['editor']['config']['get']('collaboration.channelId');this['_isPendingUpdate']=!0x0,this['_addPendingAction'](),this['adapter']['updateRevisions'](_0x450ee2,_0x13d1ea)['finally'](()=>{this['_isPendingUpdate']=!0x1;})['then'](_0xa01aa3=>{if(_0xa01aa3){for(const _0x510016 of _0xa01aa3)this['setRevisionData']({'id':_0x510016['id'],'createdAt':_0x510016['createdAt']});}this['_removePendingAction'](),this['sendBufferedUpdates']();});}['buildRevisionData']({revision:_0x4a304e=null,from:_0x4fe122=null,to:_0x224524=null}){_0x4fe122=null!==_0x4fe122?_0x4fe122:_0x4a304e['fromVersion'],_0x224524=null!==_0x224524?_0x224524:_0x4a304e['toVersion'];const _0x5b8d67=this['_revisionDataBuilder']['getData'](_0x4fe122,_0x224524),_0x48aaf0={'diffData':_0x5b8d67['diffData'],'authorsIds':_0x5b8d67['authorsIds'],'fromVersion':_0x4fe122,'toVersion':_0x224524};if(!_0x4a304e||_0x224524!==_0x4a304e['toVersion']){const _0x330eb0=_0x224524-0x1,_0x22659a=this['_source']['history']['getOperation'](_0x330eb0);_0x48aaf0['createdAt']=_0x22659a&&_0x22659a['createdAt']||new Date();}if(this['_loadedStateData']&&_0x4fe122===this['_loadedStateData']['fromVersion']){for(const _0x17b480 of this['_loadedStateData']['authors'])_0x48aaf0['authorsIds']['includes'](_0x17b480['id'])||_0x48aaf0['authorsIds']['push'](_0x17b480['id']);}return _0x48aaf0;}['_bufferUpdate'](_0x4630bb,_0x1f2f2d,_0x31d362){if(this['_bufferedUpdates']['has'](_0x4630bb)){const _0x5e2c80=this['_bufferedUpdates']['get'](_0x4630bb);_0x1f2f2d=_0x31d362?{..._0x5e2c80,..._0x1f2f2d}:{..._0x1f2f2d,..._0x5e2c80};}this['_bufferedUpdates']['set'](_0x4630bb,_0x1f2f2d);}['setRevisionData'](_0x4c28ad){const _0x3495cf=this['repository']['getRevision'](_0x4c28ad['id']);if(_0x4c28ad['createdAt']&&(_0x4c28ad['createdAt']=new Date(_0x4c28ad['createdAt'])),_0x4c28ad['authorsIds']){const _0x335cfd=this['editor']['plugins']['get']('Users');_0x4c28ad['authors']=_0x4c28ad['authorsIds']['map'](_0x143526=>_0x335cfd['getUser'](_0x143526));}_0x3495cf['_update'](_0x4c28ad,!0x0);}['_createInitialRevision'](_0x3c1e24){const _0x1ae19b=this['repository']['getRevision'](this['repository']['length']-0x1);if(_0x1ae19b)this['_initialRevisionId']=_0x1ae19b['id'];else{const _0xd4581c=!this['editor']['model']['document']['roots']['find'](_0x52568e=>this['editor']['model']['hasContent'](_0x52568e)),_0x2ba037=this['editor']['plugins']['get']('Users')['me']['id'],_0x4de131=m(this['editor']['locale'],_0xd4581c?'Empty\x20document':'Initial\x20revision');this['_makeRevision']({'from':_0x3c1e24,'to':_0x3c1e24,'id':this['_initialRevisionId'],'name':_0x4de131,'creatorId':_0x2ba037});}}['_createCurrentRevision'](_0x5a29e5){const _0x4cdf87=this['_source']['getCurrentRevisionId']();this['currentRevision']=this['repository']['getRevision'](_0x4cdf87),this['currentRevision']||(this['currentRevision']=this['_makeRevision']({'from':_0x5a29e5,'to':_0x5a29e5,'id':_0x4cdf87,'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'](_0x3e1f32,_0x5ade8d){let _0x48972d=this['editor']['config']['get']('initialData'),_0x51beae=this['editor']['config']['get']('rootsAttributes');if(void 0x0===_0x48972d){_0x48972d={};for(const _0x1a23b9 of this['editor']['model']['document']['getRootNames']())_0x48972d[_0x1a23b9]='';}if('string'==typeof _0x48972d&&(_0x48972d={'main':_0x48972d}),void 0x0===_0x51beae){_0x51beae={};for(const _0x543f94 of this['editor']['model']['document']['getRootNames']())_0x51beae[_0x543f94]={};}let _0x1238d8=!0x1;const _0x17080a=Object['keys'](_0x48972d),_0x5bea13=Object['keys'](_0x3e1f32);for(const _0x5f5547 of _0x17080a){if(_0x48972d[_0x5f5547]!==_0x3e1f32[_0x5f5547]&&''!==_0x48972d[_0x5f5547]['trim']()){_0x1238d8=!0x0;break;}if(!_0x4a9e9c(_0x51beae[_0x5f5547],_0x5ade8d[_0x5f5547])&&Object['keys'](_0x51beae[_0x5f5547])['length']>0x0){_0x1238d8=!0x0;break;}}_0x1238d8||(_0x1238d8=_0x5bea13['some'](_0x401210=>!this['editor']['model']['document']['getRoot'](_0x401210))),_0x1238d8&&_0x3d0d05('editor-initial-data-replaced-with-revision-data',{'editorData':_0x48972d,'editorRootsAttributes':_0x51beae,'revisionData':_0x3e1f32,'revisionRootsAttributes':_0x5ade8d}),this['editor']['config']['set']('initialData',_0x3e1f32),this['editor']['config']['set']('rootsAttributes',_0x5ade8d);}['_addPendingAction'](){if(!this['_pendingAction']){const _0x7e49a2=this['editor']['plugins']['get']('PendingActions');this['_pendingAction']=_0x7e49a2['add'](m(this['editor']['locale'],'PENDING_ACTION_REVISION_HISTORY'));}}['_removePendingAction'](){this['_pendingAction']&&(this['editor']['plugins']['get']('PendingActions')['remove'](this['_pendingAction']),this['_pendingAction']=null);}['_findInsertionIndex'](_0x32c4df){const _0x229017=this['repository']['getRevisions']();_0x229017['reverse']();let _0x4f4e76=0x0;for(;_0x4f4e76<_0x229017['length'];){const _0x763ae4=_0x229017[_0x4f4e76];if(_0x763ae4===this['currentRevision']){_0x4f4e76++;continue;}if(_0x763ae4['id']===this['_initialRevisionId'])break;const _0x430915=_0x32c4df['toVersion']-_0x763ae4['toVersion']||_0x32c4df['fromVersion']-_0x763ae4['fromVersion'];if(_0x430915>0x0)break;if(_0x430915<0x0)_0x4f4e76++;else{if(!_0x32c4df['creator']&&_0x763ae4['creator'])break;if(_0x763ae4['creator']||!_0x32c4df['creator']){if(_0x32c4df['createdAt']>_0x763ae4['createdAt'])break;_0x4f4e76++;}else _0x4f4e76++;}}return _0x4f4e76;}['_getFromVersion'](_0x1455cd){const _0x247839=this['repository']['getRevisions']();_0x247839['reverse'](),_0x247839['shift']();const _0x23bbf9=_0x247839['find'](_0x1f97a4=>_0x1f97a4['toVersion']<=_0x1455cd)['toVersion'];return _0x23bbf9<this['_startingVersion']?this['_startingVersion']:_0x23bbf9;}['_makeRevision']({name:_0x7f5da,from:_0x30b9f4,to:_0x2cbec,creatorId:_0xf3fab0,id:_0x298790}){const _0x20b8dd=this['buildRevisionData']({'from':_0x30b9f4,'to':_0x2cbec});_0x20b8dd['name']=_0x7f5da,_0x20b8dd['creatorId']=_0xf3fab0,_0x20b8dd['id']=_0x298790;const _0xc7f7d7=this['addRevisionData'](_0x20b8dd);return this['adapter']&&this['_bufferUpdate'](_0x20b8dd['id'],_0x20b8dd,!0x0),_0xc7f7d7;}['_setConversion'](){this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'});}}class E{['editor'];['source'];['_savedMetaData'];['_lastFrom'];['_lastTo'];['_markers'];['_diffRoots'];['_diffRootsAttributes'];['_baseRoots'];['_baseRootsAttributes'];['_idsRoots'];['_baseIdsRoots'];['_touched'];['_touchedMarkers'];['_touchedRoots'];['_revisionId'];['_startingRevisionId'];constructor(_0x56485d){this['editor']=_0x56485d,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'](_0x32c738){this['source']=_0x32c738;const _0xf873ae=new Map(),_0x3e8494=new Map(),_0x3c5729=this['editor']['model']['document']['roots']['map'](_0x52d4c6=>_0x52d4c6['rootName']);for(const _0x347394 of _0x3c5729){const _0x3496f4=this['editor']['model']['document']['getRoot'](_0x347394),_0x959024=x(_0x3496f4);_0xf873ae['set'](_0x347394,_0x959024),_0x3e8494['set'](_0x347394,Object['fromEntries'](_0x3496f4['getAttributes']()));}const _0x2bf085=Array['from'](this['editor']['model']['markers'])['map'](_0x3f845a=>[_0x3f845a['name'],_0x3f845a['getRange']()]),_0x5c218e=this['source']['version'];this['_saveMetaData'](_0x5c218e,_0xf873ae,_0x2bf085,_0x3e8494),this['_startingRevisionId']=this['_revisionId'];const _0x5949ec=new Map(),_0x58fb77=new Map();for(const _0x3f6115 of _0x3c5729){const _0x86b8c3=N(_0x3f6115);_0x5949ec['set'](_0x3f6115,_0x86b8c3),_0x58fb77['set'](_0x3f6115,{});}this['_saveMetaData'](Number['NEGATIVE_INFINITY'],_0x5949ec,[],_0x58fb77);}['getData'](_0x222541,_0x8c805d){if(this['_lastFrom']===_0x222541&&this['_lastTo']<=_0x8c805d)this['_savedMetaData']['size']>0x1&&this['_removeMetaData'](this['_lastTo']),this['_applyOperations'](this['_lastTo'],_0x8c805d,!0x0);else{if(!this['_savedMetaData']['has'](_0x222541)){const _0x404bd9=this['_getPreviousFrom'](_0x222541);this['_calculateMetaData'](_0x404bd9,_0x222541,!0x1);}this['_calculateMetaData'](_0x222541,_0x8c805d,!0x0);}return this['_lastFrom']=_0x222541,this['_lastTo']=_0x8c805d,this['_getState']();}['loadState'](_0x3fe561){if(!this['_savedMetaData']['has'](_0x3fe561['fromVersion'])){const _0x978ac1=this['_getPreviousFrom'](_0x3fe561['fromVersion']);this['_calculateMetaData'](_0x978ac1,_0x3fe561['fromVersion'],!0x1);}this['_calculateMetaData'](_0x3fe561['fromVersion'],_0x3fe561['toVersion'],!0x1);const _0x15f89f=this['editor']['plugins']['get']('RevisionHistoryUtils');this['_reset'](),this['_lastFrom']=_0x3fe561['fromVersion'],this['_lastTo']=_0x3fe561['toVersion'];for(const _0x11f239 in _0x3fe561['diffData']){const _0x9a3c77=_0x3fe561['diffData'][_0x11f239]['attachChange'],_0x4be334=_0x2b1973(_0x3fe561['diffData'][_0x11f239]['attributesBefore'])||{},_0x67d84f=_0x15f89f['_makeModelFromViewString'](_0x3fe561['diffData'][_0x11f239]['deletions']);_0x67d84f['rootName']=_0x11f239,_0x67d84f['_isAttached']=!_0x9a3c77||!_0x9a3c77['isAttached'],_0x67d84f['isAttached']=()=>_0x67d84f['_isAttached'],this['_baseRoots']['set'](_0x11f239,_0x67d84f),this['_baseRootsAttributes']['set'](_0x11f239,_0x4be334),_0x9a3c77&&this['_touchedRoots']['set'](_0x11f239,_0x9a3c77);const _0x18b691=this['_makeIdsRoot'](_0x67d84f);this['_baseIdsRoots']['set'](_0x11f239,_0x18b691);for(const [_0x5cd186,_0x2cffa7]of _0x67d84f['markers']){if(!_0x5cd186['startsWith']('revision:'))continue;const _0x1127b6=_0x5cd186['split'](':')[0x2];for(const _0x48301e of _0x2cffa7['getWalker']({'singleCharacters':!0x0})){const _0x491ce0=this['_getVidAttributeName'](_0x48301e),_0x57b518='elementEnd'==_0x48301e['type']?_0x48301e['previousPosition']['path']['slice'](0x0,-0x1):_0x48301e['previousPosition']['path'],_0x1f6e95=_0x18b691['getNodeByPath'](_0x57b518)['getAttribute'](_0x491ce0);this['_touched']['set'](_0x1f6e95,{'userId':_0x1127b6});}_0x67d84f['markers']['delete'](_0x5cd186);}}this['_startingRevisionId']=this['_revisionId'];const _0x272e34=[...Array(this['_revisionId'])['keys']()]['slice'](0x1)['filter'](_0x51b279=>!this['_touched']['has'](_0x51b279));let _0x1a0c55=0x0;const _0x104ccb=new Map();for(const _0x5c1c4a in _0x3fe561['diffData']){const _0xda5d8b=_0x3fe561['diffData'][_0x5c1c4a]['attachChange'],_0x269ba1=_0x2b1973(_0x3fe561['diffData'][_0x5c1c4a]['attributesAfter'])||{},_0xae959=_0x15f89f['_makeModelFromViewString'](_0x3fe561['diffData'][_0x5c1c4a]['insertions']);_0xae959['rootName']=_0x5c1c4a,_0xae959['_isAttached']=!_0xda5d8b||_0xda5d8b['isAttached'],_0xae959['isAttached']=()=>_0xae959['_isAttached'],this['_diffRoots']['set'](_0x5c1c4a,_0xae959),this['_diffRootsAttributes']['set'](_0x5c1c4a,_0x269ba1);const _0xd5467e=this['_makeIdsRoot'](_0xae959,Number['NEGATIVE_INFINITY']);this['_idsRoots']['set'](_0x5c1c4a,_0xd5467e),_0x104ccb['set'](_0x5c1c4a,_0xae959['isAttached']()?_0x269ba1:{});for(const [_0x2ef94a,_0x1927f1]of _0xae959['markers']){if(!_0x2ef94a['startsWith']('revision:'))continue;const _0xfe11b1=_0x2ef94a['split'](':')[0x2];for(const _0x49bf58 of _0x1927f1['getWalker']({'singleCharacters':!0x0})){const _0x4b6ece=this['_getVidAttributeName'](_0x49bf58),_0x333bb9=this['_revisionId']++,_0x417fa0='elementEnd'==_0x49bf58['type']?_0x49bf58['previousPosition']['path']['slice'](0x0,-0x1):_0x49bf58['previousPosition']['path'];_0xd5467e['getNodeByPath'](_0x417fa0)['_setAttribute'](_0x4b6ece,_0x333bb9),this['_touched']['set'](_0x333bb9,{'userId':_0xfe11b1});}_0xae959['markers']['delete'](_0x2ef94a);}for(const _0x2b6219 of this['editor']['model']['createRangeIn'](_0xae959)['getWalker']({'singleCharacters':!0x0})){const _0xcebbc9=this['_getVidAttributeName'](_0x2b6219),_0x52f754='elementEnd'==_0x2b6219['type']?_0x2b6219['previousPosition']['path']['slice'](0x0,-0x1):_0x2b6219['previousPosition']['path'],_0x2000cf=_0xd5467e['getNodeByPath'](_0x52f754);_0x2000cf['getAttribute'](_0xcebbc9)>0x0||_0x2000cf['_setAttribute'](_0xcebbc9,_0x272e34[_0x1a0c55++]);}for(const [_0x21afa5,_0x26f83d]of _0xae959['markers'])_0x21afa5['startsWith']('revision:')||this['_markers']['set'](_0x21afa5,_0x26f83d);}const {roots:_0x545f46}=this['_savedMetaData']['get'](_0x3fe561['fromVersion']),{roots:_0x1bf286}=this['_savedMetaData']['get'](_0x3fe561['toVersion']),_0x29558f=x(_0x545f46['get']('$graveyard'));this['_baseRoots']['set']('$graveyard',_0x29558f),this['_baseIdsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x29558f,Number['NEGATIVE_INFINITY']));const _0x13c2c2=x(_0x1bf286['get']('$graveyard'));this['_diffRoots']['set']('$graveyard',_0x13c2c2),this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x13c2c2));const _0x9abcba=Array['from'](this['_diffRoots'])['map'](([_0x2cb9d6,_0x2f397c])=>[_0x2cb9d6,x(_0x2f397c)]);this['_saveMetaData'](this['_lastTo'],_0x9abcba,this['_markers'],_0x104ccb);}['reInit'](){this['_reset'](),this['_lastFrom']=-0x1,this['_lastTo']=-0x1,this['_savedMetaData']['clear'](),this['init'](this['source']);}['_saveMetaData'](_0x42aeae,_0x54e046,_0x31d1d1,_0x4f9303){const _0x50cbb7=new Map(_0x54e046),_0x165e91=new Map(_0x2b1973(_0x4f9303)),_0x3dd5af=new Map();for(const [_0x429442,_0xe08259]of _0x31d1d1)_0x3dd5af['set'](_0x429442,{'start':_0xe08259['start']['clone'](),'end':_0xe08259['end']['clone'](),'rootName':_0xe08259['root']['rootName']});this['_savedMetaData']['set'](_0x42aeae,{'roots':_0x50cbb7,'markers':_0x3dd5af,'rootsAttributes':_0x165e91});}['_removeMetaData'](_0x2c4f9d){this['_savedMetaData']['delete'](_0x2c4f9d);}['_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'](_0x29d750,_0x533bb8=null){let _0x2890cd=null;_0x29d750['is']('documentFragment')||(_0x2890cd=new _0x236395(_0x29d750['name'],{'vid_start':null===_0x533bb8?this['_revisionId']++:_0x533bb8++}));const _0x3efe75=[];for(const _0x41f00e of _0x29d750['getChildren']())if(_0x41f00e['is']('element')){_0x3efe75['push'](this['_makeIdsRoot'](_0x41f00e,_0x533bb8));const _0x4add81=_0x3efe75[_0x3efe75['length']-0x1];null!==_0x533bb8&&(_0x533bb8=_0x4add81['is']('element','$text')?_0x4add81['getAttribute']('vid')+0x1:_0x4add81['getAttribute']('vid_end')+0x1);}else{for(let _0x472a7e=0x0;_0x472a7e<_0x41f00e['offsetSize'];_0x472a7e++)_0x3efe75['push'](new _0x236395('$text',{'vid':null===_0x533bb8?this['_revisionId']++:_0x533bb8++}));}if(_0x29d750['is']('documentFragment')){const _0x37a918=N(_0x29d750['rootName']);return _0x37a918['_insertChild'](0x0,_0x3efe75),_0x37a918;}return _0x2890cd['_setAttribute']('vid_end',null===_0x533bb8?this['_revisionId']++:_0x533bb8++),_0x2890cd['_insertChild'](0x0,_0x3efe75),_0x2890cd;}['_calculateMetaData'](_0x40635f,_0x3485d9,_0x14ac3c){this['_reset']();const {roots:_0x4b61e1,markers:_0x38edfb,rootsAttributes:_0xa11558}=this['_savedMetaData']['get'](_0x40635f);this['_baseRoots']=new Map(_0x4b61e1),this['_baseRootsAttributes']=new Map(_0x2b1973(_0xa11558));for(const [_0x2a5ecd,_0x2328f0]of this['_baseRoots'])if('$graveyard'!==_0x2a5ecd&&(this['_diffRoots']['set'](_0x2a5ecd,x(_0x2328f0)),this['_diffRootsAttributes']=new Map(_0x2b1973(_0xa11558)),_0x14ac3c)){const _0x322c49=this['_revisionId'];this['_idsRoots']['set'](_0x2a5ecd,this['_makeIdsRoot'](_0x2328f0)),this['_baseIdsRoots']['set'](_0x2a5ecd,this['_makeIdsRoot'](_0x2328f0,_0x322c49));}this['_startingRevisionId']=this['_revisionId'],this['_diffRoots']['set']('$graveyard',x(this['_baseRoots']['get']('$graveyard'))),_0x14ac3c&&this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](this['_baseRoots']['get']('$graveyard')));for(const [_0x1525b1,_0x47dd38]of _0x38edfb){const _0x59758b=this['_baseRoots']['get'](_0x47dd38['rootName']),_0x5ee52c=this['_diffRoots']['get'](_0x47dd38['rootName']),_0x114be8=new _0x9392bd(this['_fixPosition'](_0x47dd38['start'],_0x59758b),this['_fixPosition'](_0x47dd38['end'],_0x59758b)),_0x59c2d7=this['_fixRange'](_0x114be8,_0x5ee52c);_0x59758b['markers']['set'](_0x1525b1,_0x114be8),this['_markers']['set'](_0x1525b1,_0x59c2d7);}this['_applyOperations'](_0x40635f,_0x3485d9,_0x14ac3c);}['_applyOperations'](_0x195eda,_0x278276,_0x27a81d){for(const _0x1741a3 of this['source']['getOperations'](_0x195eda,_0x278276))this['_handleOperation'](_0x1741a3,_0x27a81d);for(const _0xa3435d of this['_diffRoots']['values']())_0xa3435d['markers']['clear']();for(const [_0x540f56,_0x9adc44]of this['_markers']){this['_diffRoots']['get'](_0x9adc44['root']['rootName'])['markers']['set'](_0x540f56,_0x9adc44['clone']());}const _0x35357a=new Map(),_0x5cd96a=new Map();for(const [_0xaf83b3,_0x49d12e]of this['_diffRoots'])_0x35357a['set'](_0xaf83b3,x(_0x49d12e)),_0x5cd96a['set'](_0xaf83b3,this['_diffRootsAttributes']['get'](_0xaf83b3));this['_saveMetaData'](_0x278276,_0x35357a,this['_markers'],_0x5cd96a);}['_getPreviousFrom'](_0x31e879){const _0x2c5ea8=Array['from'](this['_savedMetaData']['keys']());_0x2c5ea8['sort']((_0x18133b,_0x3cc843)=>_0x18133b-_0x3cc843),_0x2c5ea8['reverse']();for(const _0x157940 of _0x2c5ea8)if(_0x157940<_0x31e879)return _0x157940;return Number['NEGATIVE_INFINITY'];}['_copyMarkers'](_0x476258,_0x5793c2){const _0x41aa43=Array['from'](_0x5793c2['markers'])['map'](([_0x150a3a,_0x554599])=>[_0x150a3a,this['_fixRange'](_0x554599,_0x476258)]);_0x476258['markers']=new Map(_0x41aa43);}['_transformMarkers'](_0x2b889e){for(const _0x108e40 of this['_markers']['values']()){const _0x50d881=_0x108e40['getTransformedByOperation'](_0x2b889e),_0x1a741b=_0x9392bd['_createFromRanges'](_0x50d881);_0x108e40['start']=_0x1a741b['start'],_0x108e40['end']=_0x1a741b['end'];}}['_handleOperation'](_0x330b4c,_0x172b74){if('addRoot'!=_0x330b4c['type']&&'detachRoot'!=_0x330b4c['type']){if('insert'==_0x330b4c['type']){const _0x437137=_0x330b4c['position']['root']['rootName'];this['_diffRoots']['has'](_0x437137)||(this['_diffRoots']['set'](_0x437137,N(_0x437137,!0x0)),this['_diffRootsAttributes']['set'](_0x437137,{}),_0x172b74&&this['_idsRoots']['set'](_0x437137,N(_0x437137,!0x0)));}else{if('addRootAttribute'==_0x330b4c['type']||'removeRootAttribute'==_0x330b4c['type']||'changeRootAttribute'==_0x330b4c['type'])return void this['_handleRootAttributeOperation'](_0x330b4c);'marker'==_0x330b4c['type']&&this['_handleMarkerOperation'](_0x330b4c);}if('marker'!==_0x330b4c['type']){const _0x3b47d0=this['_cloneOperation'](_0x330b4c,this['_diffRoots']);_0x3b47d0['_execute'](),this['_transformMarkers'](_0x3b47d0);}if(_0x172b74)switch(_0x330b4c['type']){case'insert':this['_handleInsertOperation'](_0x330b4c);break;case'move':case'remove':case'reinsert':this['_handleMoveOperation'](_0x330b4c);break;case'merge':this['_handleMergeOperation'](_0x330b4c);break;case'split':this['_handleSplitOperation'](_0x330b4c);}}else this['_handleRootOperation'](_0x330b4c,_0x172b74);}['_cloneOperation'](_0xef32a6,_0x4c0be8){const _0x1294d1=_0xef32a6['clone']();return _0x1294d1['_authorId']=_0xef32a6['_authorId'],this['_fixOperation'](_0x1294d1,_0x4c0be8),_0x1294d1;}['_getBaseVids'](_0x1b63dd){return _0x1b63dd['map'](_0xc9239a=>{const _0x169c54=this['_getVidAttributeName'](_0xc9239a);return Number(_0xc9239a['item']['getAttribute'](_0x169c54));});}['_generateTape'](_0x2e87bb,_0x25488f){if(_0x2e87bb['is']('element','$text'))_0x25488f['push']({'item':_0x2e87bb,'type':'text'});else{_0x2e87bb['is']('element')&&_0x25488f['push']({'item':_0x2e87bb,'type':'elementStart'});for(const _0x584921 of _0x2e87bb['getChildren']())this['_generateTape'](_0x584921,_0x25488f);_0x2e87bb['is']('element')&&_0x25488f['push']({'item':_0x2e87bb,'type':'elementEnd'});}return _0x25488f;}['_getState'](){const _0x6bd9f5=new Map(this['_touched']),_0x4a8f52=new Map(_0x6bd9f5),_0x92ff40=new Map(),_0x20ffa6={'insertions':{},'deletions':{}},_0x4091c3={'insertions':{},'deletions':{}},_0x41d388=new Map(),_0x580f02=new Set([...this['_baseRoots']['keys'](),...this['_diffRoots']['keys']()]);_0x580f02['delete']('$graveyard');for(const _0x4f5500 of _0x580f02){const _0x47e63b=this['_diffRoots']['get'](_0x4f5500)||N(_0x4f5500,!0x1),_0x46e79b=this['_baseRoots']['get'](_0x4f5500)||N(_0x4f5500,!0x1);_0x47e63b['isAttached']()||_0x46e79b['isAttached']()?(_0x20ffa6['insertions'][_0x4f5500]=x(_0x47e63b),_0x20ffa6['deletions'][_0x4f5500]=x(_0x46e79b),this['_copyMarkers'](_0x20ffa6['deletions'][_0x4f5500],_0x46e79b),this['_copyMarkers'](_0x20ffa6['insertions'][_0x4f5500],_0x47e63b),_0x4091c3['insertions'][_0x4f5500]=this['_generateTape'](this['_idsRoots']['get'](_0x4f5500),[]),_0x4091c3['deletions'][_0x4f5500]=this['_generateTape'](this['_baseIdsRoots']['get'](_0x4f5500)||N(_0x4f5500,!0x1),[])):_0x580f02['delete'](_0x4f5500);}for(const _0x3c1210 of _0x580f02){const _0x48c554=_0x4091c3['insertions'][_0x3c1210];for(const _0x4941ce of _0x48c554){const _0x452dc2=this['_getVidAttributeName'](_0x4941ce),_0x1293d0=_0x4941ce['item']['getAttribute'](_0x452dc2);_0x4a8f52['delete'](_0x1293d0),_0x1293d0>=this['_startingRevisionId']&&_0x92ff40['set'](_0x1293d0,_0x6bd9f5['get'](_0x1293d0));}}for(const _0x422b53 of _0x580f02){const _0xe1986b=_0x4091c3['insertions'][_0x422b53],_0x51b145=this['_getBaseVids'](_0x4091c3['deletions'][_0x422b53]);let _0x1045f6=0x0;for(const _0x2f801c of _0xe1986b){const _0xc6eb86=this['_getVidAttributeName'](_0x2f801c),_0x217608=_0x2f801c['item']['getAttribute'](_0xc6eb86);if(!_0x92ff40['has'](_0x217608)&&!_0x41d388['has'](_0x217608)){if(_0x4a8f52['has'](_0x217608))_0x1045f6++;else{if(_0x217608!=_0x51b145[_0x1045f6]){const _0x4327a2=_0x6bd9f5['get'](_0x217608)||_0x6bd9f5['get'](_0x51b145[_0x1045f6]);for(;_0x217608!=_0x51b145[_0x1045f6];)_0x4a8f52['has'](_0x51b145[_0x1045f6])||(_0x41d388['set'](_0x51b145[_0x1045f6],_0x4327a2),_0x6bd9f5['set'](_0x51b145[_0x1045f6],_0x4327a2)),_0x1045f6++;}_0x1045f6++;}}}}for(const _0xd1af18 of _0x580f02){const _0x3aeb42=_0x4091c3['insertions'][_0xd1af18];for(const _0x3e8958 of _0x3aeb42){const _0x54a2d2=this['_getVidAttributeName'](_0x3e8958),_0x40ab08=_0x3e8958['item']['getAttribute'](_0x54a2d2);if(_0x41d388['has'](_0x40ab08)){const _0x45b27f=_0x41d388['get'](_0x40ab08);_0x4a8f52['has'](_0x40ab08)||_0x4a8f52['set'](_0x40ab08,{..._0x45b27f}),_0x92ff40['set'](_0x40ab08,{..._0x45b27f});}}}for(const _0x3342ba of _0x4a8f52['keys']())_0x3342ba>=this['_startingRevisionId']&&_0x4a8f52['delete'](_0x3342ba);const _0x436626=new Map();for(const _0x158ac8 of _0x580f02){let _0x29ed63=_0x4091c3['insertions'][_0x158ac8];for(const _0x3d35fb of _0x29ed63)if(_0x3d35fb['item']['is']('element','tableCell')){const _0x5329ae=this['_getVidAttributeName'](_0x3d35fb),_0x230210=_0x3d35fb['item']['getAttribute'](_0x5329ae);if(_0x92ff40['has'](_0x230210)){const _0x4c0ad0=_0x3d35fb['item']['parent']['parent']['getAttribute']('vid_start'),_0x74b52f=_0x436626['get'](_0x4c0ad0)||new Set();_0x74b52f['add'](_0x92ff40['get'](_0x230210)['userId']),_0x436626['set'](_0x4c0ad0,_0x74b52f);}}_0x29ed63=_0x4091c3['deletions'][_0x158ac8];for(const _0x1fdd49 of _0x29ed63)if(_0x1fdd49['item']['is']('element','tableCell')){const _0x4bcb8b=this['_getVidAttributeName'](_0x1fdd49),_0x31bb63=_0x1fdd49['item']['getAttribute'](_0x4bcb8b);if(_0x4a8f52['has'](_0x31bb63)){const _0x37dc60=_0x1fdd49['item']['parent']['parent']['getAttribute']('vid_start'),_0x4f2747=_0x436626['get'](_0x37dc60)||new Set();_0x4f2747['add'](_0x4a8f52['get'](_0x31bb63)['userId']),_0x436626['set'](_0x37dc60,_0x4f2747);}}for(const _0x1ceac5 of _0x436626['keys']())(_0x92ff40['has'](_0x1ceac5)||_0x4a8f52['has'](_0x1ceac5))&&_0x436626['delete'](_0x1ceac5);}for(const _0x5589ce of _0x580f02){const _0x1f7afd=_0x4091c3['insertions'][_0x5589ce];let _0x2113dd=null,_0x260f76=null;for(const _0x2eef88 of _0x1f7afd){const _0x1e7e85=this['_getVidAttributeName'](_0x2eef88),_0x3576af=_0x2eef88['item']['getAttribute'](_0x1e7e85),_0x3d01ff=_0x436626['get'](_0x3576af);_0x3d01ff&&'elementStart'==_0x2eef88['type']&&(_0x2113dd=Array['from'](_0x3d01ff)[0x0],_0x260f76=_0x2eef88['item']['getAttribute']('vid_end')),_0x2113dd&&(_0x4a8f52['set'](_0x3576af,{'userId':_0x2113dd}),_0x92ff40['set'](_0x3576af,{'userId':_0x2113dd})),_0x3576af==_0x260f76&&(_0x2113dd=null,_0x260f76=null);}}const _0x2d1a02={},_0x2ac56b=new Set();for(const _0x14300b of _0x580f02){const _0x290bc9=_0x20ffa6['deletions'][_0x14300b],_0x429026=_0x20ffa6['insertions'][_0x14300b];for(const {userId:_0xf30cfc}of this['_touchedMarkers']['values']())null!==_0xf30cfc&&_0x2ac56b['add'](_0xf30cfc);for(const {userId:_0x5cb06a}of this['_touchedRoots']['values']())null!==_0x5cb06a&&_0x2ac56b['add'](_0x5cb06a);this['_markChanges'](_0x429026,_0x4091c3['insertions'][_0x14300b],_0x92ff40,'insertion',_0x2ac56b),this['_markChanges'](_0x290bc9,_0x4091c3['deletions'][_0x14300b],_0x4a8f52,'deletion',_0x2ac56b),_0x2d1a02[_0x14300b]={'insertions':this['_prepareViewToSave'](_0x429026),'deletions':this['_prepareViewToSave'](_0x290bc9),'attachChange':this['_touchedRoots']['get'](_0x14300b)||null,'attributesBefore':_0x2b1973(this['_baseRootsAttributes']['get'](_0x14300b))||{},'attributesAfter':_0x2b1973(this['_diffRootsAttributes']['get'](_0x14300b))};}return{'diffData':_0x2d1a02,'authorsIds':Array['from'](_0x2ac56b)};}['_processRootBeforeSave'](_0x45f89e){for(const [,_0x46ec64]of _0x45f89e['markers']){const _0x30e4db=_0x46ec64['start']['getAncestors']()['filter'](_0x50d744=>'tableCell'==_0x50d744['name']);for(const _0x318714 of _0x30e4db)0x1==_0x318714['childCount']&&_0x318714['getChild'](0x0)['is']('element','paragraph')&&_0x318714['getChild'](0x0)['_setAttribute']('keepParagraph',!0x0);}}['_prepareViewToSave'](_0x18f49f){this['_processRootBeforeSave'](_0x18f49f);const _0xe5afcf=this['editor']['data']['toView'](_0x18f49f,{}),_0x296e9e=Array['from'](_0xe5afcf['getChildren']())['map'](_0x1f3359=>this['_getViewJson'](_0x1f3359));return JSON['stringify'](_0x296e9e);}['_getViewJson'](_0x49e127){if(_0x49e127['is']('$text'))return _0x49e127['data'];{const _0x29e045=this['editor']['plugins']['get']('RevisionHistoryUtils'),_0x2f716b=_0x49e127,_0x197bcf=this['editor']['data']['htmlProcessor']['domConverter'],_0x4b414b={'type':_0x29e045['_getTypeCharForViewElement'](_0x2f716b),'name':_0x2f716b['name'],'attributes':Array['from'](_0x2f716b['getAttributes']()),'children':Array['from'](_0x2f716b['getChildren']())['map'](_0x262bda=>this['_getViewJson'](_0x262bda))};if(_0x49e127['is']('uiElement')&&'$comment'!=_0x49e127['name']){const _0x2c13bb=_0x49e127['render'](_0x197bcf['domDocument'],_0x197bcf);_0x4b414b['children']['push'](_0x2c13bb['outerHTML']);}else{if(_0x49e127['is']('rawElement')){const _0x476156=_0x197bcf['domDocument']['createElement'](_0x2f716b['name']);_0x49e127['render'](_0x476156,_0x197bcf),_0x4b414b['children']['push'](_0x476156['innerHTML']);}}const _0x507bdf=Array['from'](_0x2f716b['getCustomProperties']());_0x507bdf['length']>0x0&&(_0x4b414b['customProperties']=_0x507bdf);const _0xbc2318=_0x2f716b['getFillerOffset']();return null!==_0xbc2318&&(_0x4b414b['fillerOffset']=_0xbc2318),_0x4b414b;}}['_markChanges'](_0x1f8b3a,_0x488dd0,_0x3f78fe,_0x4ac2e2,_0x578ac1){let _0x518fef=null,_0x1e9261=null,_0x508e14=0x0;const _0x446abf=this['editor']['model'];for(let _0x36fdbf=0x0;_0x36fdbf<_0x488dd0['length'];_0x36fdbf++){const _0x487a4c=this['_getVidAttributeName'](_0x488dd0[_0x36fdbf]),_0x13a525=_0x488dd0[_0x36fdbf]['item']['getAttribute'](_0x487a4c),_0x45821f=_0x3f78fe['get'](_0x13a525),_0x3b2821=_0x36fdbf==_0x488dd0['length']-0x1;(!_0x518fef&&_0x45821f&&(_0x518fef=_0x45821f,_0x1e9261=_0x488dd0[_0x36fdbf]),_0x518fef&&(!_0x45821f||_0x45821f['userId']!=_0x518fef['userId']))&&(_0x4e1a10(_0x45821f,P(_0x1e9261,_0x1f8b3a,_0x446abf),P(_0x488dd0[_0x36fdbf],_0x1f8b3a,_0x446abf)),_0x518fef=_0x45821f||null,_0x1e9261=_0x45821f?_0x488dd0[_0x36fdbf]:null),_0x518fef&&_0x3b2821&&_0x4e1a10(_0x45821f,P(_0x1e9261,_0x1f8b3a,_0x446abf),V(_0x488dd0[_0x36fdbf],_0x1f8b3a,_0x446abf));}function _0x4e1a10(_0x5bc49b,_0x57eb28,_0x1ede33){const _0x12abe7=_0x518fef['userId'],_0x3986c2='revision:'+_0x4ac2e2+':'+_0x12abe7+':'+_0x508e14++,_0x57a336=_0x446abf['createRange'](_0x57eb28,_0x1ede33);_0x1f8b3a['markers']['set'](_0x3986c2,_0x57a336),null!==_0x12abe7&&_0x578ac1['add'](_0x12abe7);}}['_getVidAttributeName'](_0x2d6620){switch(_0x2d6620['type']){case'elementStart':return'vid_start';case'elementEnd':return'vid_end';default:return'vid';}}['_fixOperation'](_0x3b32f4,_0x27e0f7){_0x3b32f4['baseVersion']=null;for(const _0x3c33eb in _0x3b32f4){const _0x9d7a91=_0x3b32f4[_0x3c33eb];if(_0x9d7a91 instanceof _0xa02f8d){const _0x49fc86=_0x27e0f7['get'](_0x9d7a91['root']['rootName']);_0x3b32f4[_0x3c33eb]=this['_fixPosition'](_0x9d7a91,_0x49fc86);}if(_0x9d7a91 instanceof _0x9392bd){const _0x23fc13=_0x27e0f7['get'](_0x9d7a91['root']['rootName']);_0x3b32f4[_0x3c33eb]=this['_fixRange'](_0x9d7a91,_0x23fc13);}'root'===_0x3c33eb&&(_0x3b32f4['root']=_0x27e0f7['get'](_0x3b32f4['root']['rootName']));}}['_fixRange'](_0x54b4e7,_0x1cb00b){return this['editor']['model']['createRange'](this['_fixPosition'](_0x54b4e7['start'],_0x1cb00b),this['_fixPosition'](_0x54b4e7['end'],_0x1cb00b));}['_fixPosition'](_0x271496,_0x29f2c2){return this['editor']['model']['createPositionFromPath'](_0x29f2c2,_0x271496['path'],_0x271496['stickiness']);}['_handleInsertOperation'](_0x428fc7){const _0x27874a=this['_idsRoots']['get'](_0x428fc7['position']['root']['rootName']),_0xdac7b0=this['_fixPosition'](_0x428fc7['position'],_0x27874a),_0x27e13b=null===_0x428fc7['_authorId']?null:_0x428fc7['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x36a1ed=_0xdac7b0['parent'],_0x59be00=this['_revisionId'],_0x16395f=[];for(const _0x39c721 of _0x428fc7['nodes'])if(_0x39c721['is']('element'))_0x16395f['push'](this['_makeIdsRoot'](_0x39c721));else{for(let _0x56322=0x0;_0x56322<_0x39c721['offsetSize'];_0x56322++)_0x16395f['push'](new _0x236395('$text',{'vid':this['_revisionId']++}));}const _0x1342d0=this['_revisionId'];for(let _0xc6208=_0x59be00;_0xc6208<_0x1342d0;_0xc6208++)this['_touched']['set'](_0xc6208,{'userId':_0x27e13b});_0x36a1ed['_insertChild'](_0xdac7b0['offset'],_0x16395f);}['_handleMoveOperation'](_0x5628e2){(_0x5628e2=this['_cloneOperation'](_0x5628e2,this['_idsRoots']))['_execute']();const _0x4e8c9f=null===_0x5628e2['_authorId']?null:_0x5628e2['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x280b08=_0x5628e2['getMovedRangeStart'](),_0x5bf7eb=_0x280b08['parent'],_0xa5710b=_0x280b08['offset'];!function _0x112338(_0x14cec0,_0x55e7f4,_0x5ec1d5,_0x2584d4){for(let _0x4f76b0=_0x5ec1d5;_0x4f76b0<_0x2584d4;_0x4f76b0++){const _0xa4b2d3=_0x55e7f4['getChild'](_0x4f76b0);_0xa4b2d3['is']('element','$text')?_0x14cec0['set'](_0xa4b2d3['getAttribute']('vid'),{'userId':_0x4e8c9f}):(_0x14cec0['set'](_0xa4b2d3['getAttribute']('vid_start'),{'userId':_0x4e8c9f}),_0x112338(_0x14cec0,_0xa4b2d3,0x0,_0xa4b2d3['childCount']),_0x14cec0['set'](_0xa4b2d3['getAttribute']('vid_end'),{'userId':_0x4e8c9f}));}}(this['_touched'],_0x5bf7eb,_0xa5710b,_0xa5710b+_0x5628e2['howMany']);}['_handleMergeOperation'](_0x21ff95){const _0x5db895=null===(_0x21ff95=this['_cloneOperation'](_0x21ff95,this['_idsRoots']))['_authorId']?null:_0x21ff95['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x5a2e3f=_0x21ff95['targetPosition']['parent'],_0x15f9e1=_0x21ff95['sourcePosition']['parent'],_0x11d8f0=_0x5a2e3f['getAttribute']('vid_end'),_0x420152=_0x15f9e1['getAttribute']('vid_start');_0x5a2e3f['_setAttribute']('vid_end',_0x15f9e1['getAttribute']('vid_end')),_0x15f9e1['_setAttribute']('vid_end',_0x11d8f0),this['_touched']['set'](_0x420152,{'userId':_0x5db895}),this['_touched']['set'](_0x11d8f0,{'userId':_0x5db895}),_0x21ff95['_execute']();}['_handleSplitOperation'](_0x44c900){const _0x5dd293=null===(_0x44c900=this['_cloneOperation'](_0x44c900,this['_idsRoots']))['_authorId']?null:_0x44c900['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x545fd9=_0x44c900['graveyardPosition'],_0x2c1cf3=_0x44c900['splitPosition']['parent'];_0x44c900['_execute']();const _0x49fb25=_0x2c1cf3['getAttribute']('vid_end'),_0x412359=_0x44c900['insertionPosition']['nodeAfter'];if(_0x545fd9){const _0x30aa77=_0x412359['getAttribute']('vid_end'),_0x54def5=_0x2c1cf3['getAttribute']('vid_end');_0x2c1cf3['_setAttribute']('vid_end',_0x30aa77),_0x412359['_setAttribute']('vid_end',_0x54def5),this['_touched']['set'](_0x2c1cf3['getAttribute']('vid_end'),{'userId':_0x5dd293}),this['_touched']['set'](_0x412359['getAttribute']('vid_start'),{'userId':_0x5dd293});}else{const _0x1ca845=this['_revisionId']++,_0x4b7cea=this['_revisionId']++;_0x2c1cf3['_setAttribute']('vid_end',_0x1ca845),_0x412359['_setAttribute']('vid_start',_0x4b7cea),_0x412359['_setAttribute']('vid_end',_0x49fb25),this['_touched']['set'](_0x1ca845,{'userId':_0x5dd293}),this['_touched']['set'](_0x4b7cea,{'userId':_0x5dd293});}}['_handleMarkerOperation'](_0x265831){if(!_0x265831['affectsData'])return;const _0x3fafac=(_0x265831=this['_cloneOperation'](_0x265831,this['_diffRoots']))['oldRange']?_0x265831['oldRange']['root']:null,_0x3f0066=_0x265831['newRange']?_0x265831['newRange']['root']:null;_0x3fafac&&this['_markers']['delete'](_0x265831['name']),_0x3f0066&&this['_markers']['set'](_0x265831['name'],_0x265831['newRange']['clone']());const _0x413a41=null===_0x265831['_authorId']?null:_0x265831['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x17bcb0=_0x265831['name'];if(!this['_touchedMarkers']['has'](_0x17bcb0))return void this['_touchedMarkers']['set'](_0x17bcb0,{'range':_0x265831['oldRange'],'userId':_0x413a41});const _0x139c82=this['_touchedMarkers']['get'](_0x17bcb0),_0x1a86ae=_0x139c82['range'],_0x512da5=_0x265831['newRange'];null==_0x1a86ae&&null==_0x512da5||_0x1a86ae&&_0x512da5&&_0x1a86ae['isEqual'](_0x512da5)?this['_touchedMarkers']['delete'](_0x265831['name']):_0x139c82['userId']=_0x413a41;}['_handleRootOperation'](_0x4ec607,_0x1e5a9a){this['_diffRoots']['has'](_0x4ec607['rootName'])?this['_diffRoots']['get'](_0x4ec607['rootName'])['_isAttached']=_0x4ec607['isAdd']:(this['_diffRoots']['set'](_0x4ec607['rootName'],N(_0x4ec607['rootName'],!0x0)),this['_diffRootsAttributes']['set'](_0x4ec607['rootName'],{}),_0x1e5a9a&&this['_idsRoots']['set'](_0x4ec607['rootName'],N(_0x4ec607['rootName'],!0x0)));const _0x11ba63=null===_0x4ec607['_authorId']?null:_0x4ec607['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x5560d0=this['_touchedRoots']['get'](_0x4ec607['rootName']);_0x5560d0&&_0x5560d0['userId']===_0x11ba63?this['_touchedRoots']['delete'](_0x4ec607['rootName']):this['_touchedRoots']['set'](_0x4ec607['rootName'],{'userId':_0x11ba63,'isAttached':_0x4ec607['isAdd']});}['_handleRootAttributeOperation'](_0x359ec6){const _0x13a2a5=this['_diffRootsAttributes']['get'](_0x359ec6['root']['rootName']);null===_0x359ec6['newValue']?delete _0x13a2a5[_0x359ec6['key']]:_0x13a2a5[_0x359ec6['key']]=_0x359ec6['newValue'];}}function x(_0x394d66){const _0x91bde3=N(_0x394d66['rootName'],_0x394d66['isAttached']());for(const _0x3cf86f of _0x394d66['getChildren']()){const _0x9142c7=_0x3cf86f['_clone'](!0x0);_0x91bde3['_appendChild'](_0x9142c7);}return _0x91bde3;}function N(_0x47ac87,_0x5d4aef=!0x0){const _0xd81a90=new _0x416f4f();return _0xd81a90['rootName']=_0x47ac87,_0xd81a90['_isAttached']=_0x5d4aef,_0xd81a90['isAttached']=()=>_0xd81a90['_isAttached'],_0xd81a90;}function P(_0x243747,_0x2113a7,_0x3be34b){const _0x387ff7='elementEnd'==_0x243747['type']?_0x3be34b['createPositionAt'](_0x243747['item'],'end'):_0x3be34b['createPositionBefore'](_0x243747['item']);return _0x3be34b['createPositionFromPath'](_0x2113a7,_0x387ff7['path'],_0x387ff7['stickiness']);}function V(_0x467b32,_0x2bd5af,_0x1b813c){const _0x8ac811='elementStart'==_0x467b32['type']?_0x1b813c['createPositionAt'](_0x467b32['item'],0x0):_0x1b813c['createPositionAfter'](_0x467b32['item']);return _0x1b813c['createPositionFromPath'](_0x2bd5af,_0x8ac811['path'],_0x8ac811['stickiness']);}class me extends/* #__PURE__ -- @preserve */
|
|
25
|
-
|
|
26
|
-
_0x2a6632(){['id'];['author'];['type'];['data'];['rootName'];constructor(_0x28aa68){super(),this['id']=_0x28aa68['id']||_0x506dfc(),this['author']=_0x28aa68['author'],this['type']=_0x28aa68['type'],this['data']=_0x28aa68['data']||{},this['rootName']=_0x28aa68['rootName'],this['set']('createdAt',_0x28aa68['createdAt']);}['toJSON'](){return{'id':this['id'],'authorId':this['author']['id'],'type':this['type'],'data':this['data'],'createdAt':this['createdAt']};}}class J{['newRevisionId'];['oldRevisionId'];['changes'];constructor(_0x52724e,_0x46dd3a){this['newRevisionId']=_0x52724e,this['oldRevisionId']=_0x46dd3a,this['changes']=new _0x379dd0();}['_setChanges'](_0xcc7ca5){for(const _0x21b0b5 of _0xcc7ca5)this['changes']['add'](_0x21b0b5);}}class u extends _0x30489c{['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[_0x9482fc,_0x190eaa,S,$];}constructor(_0x213b91){super(_0x213b91),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',(_0x276107,_0x2f26b7,_0x489428)=>{this['activeChange']=null,this['activeView']=null,this['editor']['editing']['view']['change'](_0x32b4ff=>{for(const _0x4222c3 of this['editor']['editing']['view']['document']['roots'])_0x489428?_0x32b4ff['removeClass']('ck-editor__editable__overlay',_0x4222c3):_0x32b4ff['addClass']('ck-editor__editable__overlay',_0x4222c3);});}),this['bind']('isNavigationMode')['to'](this,'activeChange',_0x286247=>null!==_0x286247),this['bind']('currentChangeNumber')['to'](this,'isReady',this,'diff',this,'activeChange',(_0x4971d7,_0x382dc0,_0x412549)=>_0x4971d7&&_0x412549?_0x382dc0['changes']['getIndex'](_0x412549):0x0),this['bind']('numberOfChanges')['to'](this,'isReady',this,'diff',(_0x453082,_0x515bda)=>_0x453082?_0x515bda['changes']['length']:0x0),this['_changeView']=null,this['_changeIdToChange']=new Map(),this['_balloon']=this['editor']['plugins']['get'](_0x190eaa);}['init'](){const _0x45fb2e=this['editor'],_0x1cfb36=new rt(_0x45fb2e,{'direction':'backward'}),_0x5316d6=new rt(_0x45fb2e,{'direction':'forward'});(_0x45fb2e['commands']['add']('showPreviousChange',_0x1cfb36),_0x45fb2e['commands']['add']('showNextChange',_0x5316d6),_0x45fb2e['commands']['add']('restoreRevision',new nt(_0x45fb2e)),this['on']('change:numberOfChanges',()=>{_0x1cfb36['refresh'](),_0x5316d6['refresh']();}),this['_setConversion'](),this['_initInteractions'](),_0x45fb2e['enableReadOnlyMode']('revision-viewer'),_0x45fb2e['plugins']['has']('WidgetToolbarRepository'))&&_0x45fb2e['plugins']['get']('WidgetToolbarRepository')['forceDisabled']('revision-viewer');}async['getRevisionDocumentData'](_0x5263db){return await this['_utils']['loadRevisionData'](_0x5263db,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x5263db);}async['getRevisionRootsAttributes'](_0x155b15){return await this['_utils']['loadRevisionData'](_0x155b15,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x155b15);}async['compare'](_0x30367e,_0x285573,_0x5c0879=!0x1){if(!this['isEnabled'])return;const _0x47cef1=this['diff'],_0x5b77c3=this['repository'],_0x2a791c='string'==typeof _0x30367e?_0x5b77c3['getRevision'](_0x30367e):_0x30367e,_0xf32a36='string'==typeof _0x285573?_0x5b77c3['getRevision'](_0x285573):_0x285573,_0x1731b3=_0x2a791c['id'],_0x622f2b=_0xf32a36?_0xf32a36['id']:null;if(!_0x5c0879&&this['diff']&&this['diff']['newRevisionId']===_0x1731b3&&this['diff']['oldRevisionId']===_0x622f2b)return Promise['resolve']();this['isReady']=!0x1,this['activeView']=null,this['activeChange']=null,this['diff']=new J(_0x1731b3,_0x622f2b);const _0x1eee59=this['_getRevisionsRange'](_0x2a791c,_0xf32a36,!0x0)['map'](_0x11b637=>this['_utils']['loadRevisionData'](_0x11b637,this['adapter']));return _0x1eee59['push'](new Promise(_0x2fb3ac=>{setTimeout(_0x2fb3ac,0x14);})),Promise['all'](_0x1eee59)['then'](()=>{if(!this['isEnabled'])return;this['_cleanUp']();const _0x1a2010=this['_getDiff'](_0x1731b3,_0x622f2b);for(const _0x3edb03 of _0x1a2010['changes'])this['_changeIdToChange']['set'](_0x3edb03['id'],_0x3edb03);this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x57b1a2=>{for(const _0xba3f6f of this['editor']['model']['document']['getRootNames']())_0x57b1a2['detachRoot'](_0xba3f6f);for(const _0x42d575 of Object['keys'](_0x1a2010['model'])){const _0x4f1e32=_0x57b1a2['addRoot'](_0x42d575);for(const _0x2f7de8 of Object['keys'](_0x1a2010['attributes'][_0x42d575]))_0x57b1a2['setAttribute'](_0x2f7de8,_0x1a2010['attributes'][_0x42d575][_0x2f7de8],_0x4f1e32);_0x57b1a2['insert'](_0x1a2010['model'][_0x42d575],_0x4f1e32,0x0);}}),this['diff']['_setChanges'](this['_sortAndFilterDiffChanges'](_0x1a2010['changes'])),this['isReady']=!0x0;})['catch'](_0x251df=>{console['error'](_0x251df),this['_cleanUp'](),_0x47cef1&&(this['diff']=_0x47cef1),this['isReady']=!0x0;});}['addRevisionData'](_0x49adf5,_0x4620c1){const _0xdf49f5=this['repository']['createRevision'](_0x49adf5);return _0xdf49f5['on']('_update',(_0x2674e5,_0x3cd0c2,_0x324c51)=>_0x4620c1(_0x3cd0c2,_0x324c51,_0xdf49f5)),this['repository']['addRevision'](_0xdf49f5),_0xdf49f5;}['_cleanUp'](){this['activeChange']=null,this['_cleanMarkers'](),this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=null,this['_changeIdToChange']['clear'](),this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x450ba2=>{for(const _0x2dee8f of this['editor']['model']['document']['getRootNames']())_0x450ba2['detachRoot'](_0x2dee8f);});}['_sortAndFilterDiffChanges'](_0x4f8361){const _0x488bcf=[],_0x23d6d3=new Map();for(const _0x59d110 of this['editor']['model']['document']['getRootNames']()){const _0x389d6c=this['editor']['editing']['view']['getDomRoot'](_0x59d110);if(!_0x389d6c)continue;const _0x26f364=_0x389d6c['getClientRects']()['item'](0x0);_0x26f364&&(_0x488bcf['push'](_0x59d110),_0x23d6d3['set'](_0x59d110,_0x26f364));}return _0x488bcf['sort']((_0x420804,_0x546185)=>{const _0x160d51=_0x23d6d3['get'](_0x420804),_0x5c8a96=_0x23d6d3['get'](_0x546185);return _0x160d51['y']-_0x5c8a96['y']||_0x160d51['x']-_0x5c8a96['x'];}),(_0x4f8361=_0x4f8361['filter'](_0x5b0bfb=>_0x488bcf['includes'](_0x5b0bfb['rootName'])))['sort']((_0x3c07c7,_0x397aa8)=>_0x488bcf['indexOf'](_0x3c07c7['rootName'])-_0x488bcf['indexOf'](_0x397aa8['rootName'])),_0x4f8361;}['_makeTape'](_0x52adf7){const _0x5668b9=Array['from'](_0x52adf7['markers'])['filter'](([_0xb78674,_0x367637])=>_0xb78674['startsWith']('revision:')&&!_0x367637['isCollapsed']),_0x1e43aa=Array['from'](this['editor']['model']['createRangeIn'](_0x52adf7)['getWalker']({'singleCharacters':!0x0}));if(0x0!=_0x5668b9['length'])for(const _0x192594 of _0x1e43aa){const [_0x302885,_0x13e641]=_0x5668b9[0x0],[,_0x23762b,_0x479555]=_0x302885['split'](':');if(_0x13e641['end']['isEqual'](_0x192594['nextPosition'])&&_0x5668b9['shift'](),(_0x192594['previousPosition']['isEqual'](_0x13e641['start'])||_0x192594['previousPosition']['isAfter'](_0x13e641['start']))&&('insertion'==_0x23762b?_0x192594['isAdded']={'userId':_0x479555}:'deletion'==_0x23762b&&(_0x192594['isRemoved']={'userId':_0x479555})),0x0==_0x5668b9['length'])break;}return _0x1e43aa;}['_refreshStartEndIndex'](_0x5e8f04){const _0x30df36=new Map();for(let _0x3216c5=0x0;_0x3216c5<_0x5e8f04['length'];_0x3216c5++)'text'===_0x5e8f04[_0x3216c5]['type']?(_0x5e8f04[_0x3216c5]['item']['startIndex']=_0x3216c5,_0x5e8f04[_0x3216c5]['item']['endIndex']=_0x3216c5):('elementStart'===_0x5e8f04[_0x3216c5]['type']?_0x5e8f04[_0x3216c5]['item']['startIndex']=_0x3216c5:'elementEnd'===_0x5e8f04[_0x3216c5]['type']&&(_0x5e8f04[_0x3216c5]['item']['endIndex']=_0x3216c5),_0x30df36['set'](_0x5e8f04[_0x3216c5]['id'],_0x3216c5));for(const _0x5a9dc3 of _0x30df36['values']())'elementStart'===_0x5e8f04[_0x5a9dc3]['type']?_0x5e8f04[_0x5a9dc3]['item']['endIndex']=_0x30df36['get'](_0x5e8f04[_0x5a9dc3]['pairId']):'elementEnd'===_0x5e8f04[_0x5a9dc3]['type']&&(_0x5e8f04[_0x5a9dc3]['item']['startIndex']=_0x30df36['get'](_0x5e8f04[_0x5a9dc3]['pairId']));}['_processTape'](_0x578f3d){for(let _0xbc29ef=0x0;_0xbc29ef<_0x578f3d['length'];_0xbc29ef++){if('elementStart'===_0x578f3d[_0xbc29ef]['type'])_0x578f3d[_0xbc29ef]['item']['startIndex']=_0xbc29ef;else{if('elementEnd'===_0x578f3d[_0xbc29ef]['type']){_0x578f3d[_0xbc29ef]['item']['endIndex']=_0xbc29ef;const _0x2473d0=_0x578f3d[_0xbc29ef]['item']['startIndex'];_0x578f3d[_0x2473d0]['pairId']=_0x578f3d[_0xbc29ef]['id'],_0x578f3d[_0xbc29ef]['pairId']=_0x578f3d[_0x2473d0]['id'];}else _0x578f3d[_0xbc29ef]['item']['startIndex']=_0xbc29ef,_0x578f3d[_0xbc29ef]['item']['endIndex']=_0xbc29ef,_0x578f3d[_0xbc29ef]['pairId']=null;}_0x578f3d[_0xbc29ef]['markersStart']||(_0x578f3d[_0xbc29ef]['markersStart']=[],_0x578f3d[_0xbc29ef]['markersEnd']=[]);}}['_markInsertions'](_0x20cf5f,_0x4403df){const _0x28ec9b=_0x20cf5f['filter'](_0x3a344a=>!_0x3a344a['isAdded']);for(let _0x27188d=0x0;_0x27188d<_0x4403df['length'];_0x27188d++)_0x4403df[_0x27188d]['isAdded']&&(_0x28ec9b[_0x27188d]['isAdded']=_0x4403df[_0x27188d]['isAdded']);}['_getDiff'](_0x3315b7,_0x51339b=null){const _0x2df979=this['repository']['getRevision'](_0x3315b7),_0x2b22bf=_0x51339b?this['repository']['getRevision'](_0x51339b):null,_0x33f6e1=this['_getRevisionsRange'](_0x2df979,_0x2b22bf),_0x313ec2=_0x33f6e1[_0x33f6e1['length']-0x1],_0x29cfc6=new Map(),_0x3831f0={'model':{},'attributes':{},'changes':[]},_0x1acee7=new Set(),_0x5f57e9=new Map();for(let _0x4ab03f=_0x33f6e1['length']-0x1;_0x4ab03f>=0x0;_0x4ab03f--){const _0x59fa94=_0x33f6e1[_0x4ab03f];for(const _0x7b059e of Object['keys'](_0x59fa94['diffData']))if(_0x59fa94['diffData'][_0x7b059e]['attachChange']){const _0x5435e6=_0x59fa94['diffData'][_0x7b059e]['attachChange'];_0x5435e6['isAttached']?(_0x1acee7['add'](_0x7b059e),_0x5f57e9['has'](_0x7b059e)&&_0x5f57e9['get'](_0x7b059e)['userId']==_0x5435e6['userId']?_0x5f57e9['delete'](_0x7b059e):_0x5f57e9['set'](_0x7b059e,_0x5435e6)):_0x5f57e9['has'](_0x7b059e)?(_0x1acee7['delete'](_0x7b059e),_0x5f57e9['delete'](_0x7b059e)):(_0x1acee7['add'](_0x7b059e),_0x5f57e9['set'](_0x7b059e,_0x5435e6));}else _0x1acee7['add'](_0x7b059e);}for(const _0x2c6f78 of _0x1acee7){const _0x383aca=_0x5f57e9['has'](_0x2c6f78)&&!_0x5f57e9['get'](_0x2c6f78)['isAttached'];let _0x57f699=_0x383aca?_0x33f6e1['length']-0x1:0x0;const _0x1b164c=_0x383aca?-0x1:0x1;for(;_0x33f6e1[_0x57f699];){const _0x2f5c98=_0x33f6e1[_0x57f699];if(_0x2f5c98['diffData'][_0x2c6f78]){const _0x15be44=_0x383aca?_0x2f5c98['diffData'][_0x2c6f78]['attributesBefore']:_0x2f5c98['diffData'][_0x2c6f78]['attributesAfter'];_0x3831f0['attributes'][_0x2c6f78]=_0x15be44?_0x2b1973(_0x15be44):{};break;}_0x57f699+=_0x1b164c;}}for(const _0x572d79 of _0x33f6e1){_0x572d79['model']={};for(const _0x46c11b of _0x572d79['authors'])_0x29cfc6['set'](_0x46c11b['id'],_0x46c11b);for(const _0x100386 of _0x1acee7){const _0x5d67e6=_0x572d79['diffData'][_0x100386]?_0x572d79['diffData'][_0x100386]['insertions']:'[]',_0x51f1ae=_0x572d79['diffData'][_0x100386]?_0x572d79['diffData'][_0x100386]['deletions']:'[]';_0x572d79['model'][_0x100386]={'insertions':this['_utils']['_makeModelFromViewString'](_0x5d67e6),'deletions':this['_utils']['_makeModelFromViewString'](_0x51f1ae)};}}for(const _0x413f8c of _0x1acee7){let _0x5aa994=null,_0x331bdb=0x0;const _0x584699=new Map(Array['from'](_0x2df979['model'][_0x413f8c]['insertions']['markers'])['filter'](([_0x36217a])=>!_0x36217a['startsWith']('revision:')));let _0x4c10b6=0x0;for(const _0x3fa4eb of _0x33f6e1){const _0x16b507=this['_makeTape'](_0x3fa4eb['model'][_0x413f8c]['insertions']);_0x3fa4eb==_0x2df979?(_0x5aa994=_0x16b507,_0x331bdb=_0x5aa994['length'],_0x5aa994['forEach'](_0x4cfc8f=>{_0x4cfc8f['id']=_0x4c10b6++;}),this['_processTape'](_0x5aa994)):this['_markInsertions'](_0x5aa994,_0x16b507);const _0x12b373=_0x5aa994['filter'](_0x200b8f=>!_0x200b8f['isAdded'])['map'](_0x11c7a3=>_0x11c7a3['id']);let _0x238c88=0x0;const _0x102b8c=this['_makeTape'](_0x3fa4eb['model'][_0x413f8c]['deletions']);_0x102b8c['forEach'](_0x5cecc5=>{_0x5cecc5['isRemoved']?_0x5cecc5['id']=_0x331bdb++:_0x5cecc5['id']=_0x12b373[_0x238c88++];}),this['_processTape'](_0x102b8c),this['_setDistance'](_0x5aa994,'isAdded'),this['_setDistance'](_0x102b8c,'isRemoved'),_0x3fa4eb==_0x2df979&&this['_markMarkers'](_0x5aa994,_0x584699),_0x5aa994=this['_joinTapes'](_0x5aa994,_0x102b8c),this['_refreshStartEndIndex'](_0x5aa994),this['_setDistance'](_0x5aa994,'isRemoved');}_0x5aa994=_0x5aa994['filter'](_0x617ca6=>!(_0x617ca6['isAdded']&&_0x617ca6['isRemoved']));const _0xc40123=new Map(_0x313ec2['model'][_0x413f8c]['deletions']['markers']),_0x24dcf8=new Set(_0x584699['keys']());for(const _0xd4088f of _0xc40123['keys']())_0x24dcf8['delete'](_0xd4088f);this['_markSuggestions'](_0x5aa994,_0x24dcf8),this['_fixObsoleteTags'](_0x5aa994),_0x5aa994=this['_removeMissingPairs'](_0x5aa994),_0x5aa994=this['_markMismatchedRemovedTags'](_0x5aa994),_0x5aa994=this['_removeUnsupportedChanges'](_0x5aa994);const {root:_0x5a57b8,changes:_0x345f72}=this['_makeModelFromTape'](_0x5aa994,_0x29cfc6,_0x413f8c);_0x3831f0['model'][_0x413f8c]=_0x5a57b8;const _0x4fda6e=_0x5f57e9['get'](_0x413f8c);if(_0x4fda6e){const _0x186cd8=_0x29cfc6['get'](_0x4fda6e['userId']),_0x5f1518=new G({'author':_0x186cd8,'type':_0x4fda6e['isAttached']?'add':'remove','data':{'isOnRoot':!0x0},'createdAt':new Date(),'rootName':_0x413f8c});_0x345f72['unshift'](_0x5f1518),_0x3831f0['attributes'][_0x413f8c]['revisionHistoryAttachChange']=_0x5f1518['id'];}_0x3831f0['changes']=_0x3831f0['changes']['concat'](_0x345f72);}return _0x3831f0;}['_markMarkers'](_0x2d28cb,_0x45fbc2){for(let _0x1a7a81=0x0;_0x1a7a81<_0x2d28cb['length'];_0x1a7a81++)for(const [_0x40d31d,_0x1aa90b]of _0x45fbc2)!_0x1aa90b['isCollapsed']&&_0x1aa90b['start']['isEqual'](_0x2d28cb[_0x1a7a81]['previousPosition'])&&_0x2d28cb[_0x1a7a81]['markersStart']['push'](_0x40d31d),_0x1aa90b['end']['isEqual'](_0x2d28cb[_0x1a7a81]['nextPosition'])&&_0x2d28cb[_0x1a7a81]['markersEnd']['push'](_0x40d31d);}['_joinTapes'](_0x27cd6d,_0x5e59c5){let _0x5145cf=[],_0x4c82ae=0x0,_0x44ab6d=0x0;for(;_0x4c82ae<_0x27cd6d['length']||_0x44ab6d<_0x5e59c5['length'];){const _0x2ce9a0=_0x27cd6d[_0x4c82ae]||{},_0x335f94=_0x5e59c5[_0x44ab6d]||{};if(_0x2ce9a0['id']==_0x335f94['id'])_0x4c82ae++,_0x44ab6d++,_0x5145cf['push'](_0x2ce9a0);else{if(_0x335f94['isRemoved']&&_0x2ce9a0['isAdded']){const {commonTape:_0x4d82da,iEnd:_0x749e90,jEnd:_0x16a466}=this['_threeWayMerge'](_0x27cd6d,_0x4c82ae,_0x5e59c5,_0x44ab6d);_0x5145cf=_0x5145cf['concat'](_0x4d82da),_0x4c82ae=_0x749e90,_0x44ab6d=_0x16a466;}else _0x335f94['isRemoved']?(_0x44ab6d++,_0x5145cf['push'](_0x335f94)):(_0x4c82ae++,_0x5145cf['push'](_0x2ce9a0));}}return _0x5145cf;}['_markSuggestions'](_0x2a6b54,_0x42acee){const _0x1f7337=[];for(let _0x1e950d=0x0;_0x1e950d<_0x2a6b54['length'];_0x1e950d++){for(let _0x282ec5=0x0;_0x282ec5<_0x2a6b54[_0x1e950d]['markersStart']['length'];_0x282ec5++){const _0x12b7cf=_0x2a6b54[_0x1e950d]['markersStart'][_0x282ec5];if(!_0x42acee['has'](_0x12b7cf))continue;const {group:_0x576bf2,type:_0x9e65e0,authorId:_0x508357}=_0x592327(_0x12b7cf);'revision-suggestion'!=_0x576bf2||'insertion'!=_0x9e65e0&&'deletion'!=_0x9e65e0||(_0x1f7337['unshift']({'type':_0x9e65e0,'name':_0x12b7cf,'userId':_0x508357}),_0x2a6b54[_0x1e950d]['markersStart']['splice'](_0x282ec5,0x1),_0x282ec5--);}_0x322a82(_0x2a6b54[_0x1e950d]);for(let _0x4f947e=0x0;_0x4f947e<_0x2a6b54[_0x1e950d]['markersEnd']['length'];_0x4f947e++){const _0x1d3976=_0x2a6b54[_0x1e950d]['markersEnd'][_0x4f947e];if(!_0x42acee['has'](_0x1d3976))continue;const {group:_0x500947,type:_0x2b263a}=_0x592327(_0x1d3976);if('revision-suggestion'!=_0x500947||'insertion'!=_0x2b263a&&'deletion'!=_0x2b263a)continue;_0x2a6b54[_0x1e950d]['markersEnd']['splice'](_0x4f947e,0x1),_0x4f947e--;const _0x595c25=_0x1f7337['findIndex'](_0x51226d=>_0x51226d['name']==_0x1d3976);_0x595c25>-0x1&&_0x1f7337['splice'](_0x595c25,0x1);}}function _0x592327(_0x569c26){const _0x56320b=_0x569c26['split'](':');return{'group':_0x56320b[0x0],'type':_0x56320b[0x1],'subType':_0x56320b['length']>=0x5?_0x56320b[0x2]:null,'id':_0x56320b['length']<0x5?_0x56320b[0x2]:_0x56320b[0x3],'authorId':_0x56320b['length']<0x5?_0x56320b[0x3]:_0x56320b[0x4],'markerCount':0x6==_0x56320b['length']?_0x56320b[0x5]:null};}function _0x322a82(_0xe0ff1d){for(let _0x5a5abb=0x0;_0x5a5abb<_0x1f7337['length'];_0x5a5abb++){if(_0xe0ff1d['isAdded']&&'insertion'==_0x1f7337[_0x5a5abb]['type']&&_0xe0ff1d['isAdded']['userId']==_0x1f7337[_0x5a5abb]['userId'])return _0xe0ff1d['isAddSuggestion']=_0x1f7337[_0x5a5abb],void delete _0xe0ff1d['isAdded'];if(!_0xe0ff1d['isAdded']&&!_0xe0ff1d['isRemoved']&&'deletion'==_0x1f7337[_0x5a5abb]['type'])return void(_0xe0ff1d['isRemoveSuggestion']=_0x1f7337[_0x5a5abb]);}}}['_setDistance'](_0xf6191e,_0x406c87){let _0x2338b4=0x0,_0x358d98=!0x1;const _0xdb3a6c=new Map();for(const _0x32e54d of _0xf6191e)_0x32e54d[_0x406c87]?_0x358d98&&(_0x2338b4++,_0x358d98=!0x1):(_0x2338b4++,_0x358d98=!0x0),_0xdb3a6c['set'](_0x32e54d['id'],_0x2338b4);for(let _0x58d662=0x0;_0x58d662<_0xf6191e['length'];_0x58d662++){if('isRemoved'==_0x406c87&&_0xf6191e[_0x58d662]['isAdded']||'isAdded'==_0x406c87&&_0xf6191e[_0x58d662]['isRemoved'])continue;if('text'==_0xf6191e[_0x58d662]['type']){_0xf6191e[_0x58d662]['distance']=0x0;continue;}const _0x5c2916=_0xdb3a6c['get'](_0xf6191e[_0x58d662]['pairId']),_0x2ddfce=_0xdb3a6c['get'](_0xf6191e[_0x58d662]['id']);_0xf6191e[_0x58d662]['distance']=_0x5c2916-_0x2ddfce;}}['_getRevisionsRange'](_0x55d14d,_0x9cff72,_0x3ed648=!0x1){const _0x5384e8=[];let _0x1ded7b=this['repository']['getIndex'](_0x55d14d),_0x13805f=this['repository']['getIndex'](_0x9cff72);for(-0x1==_0x13805f&&(_0x13805f=this['repository']['_revisions']['length'],_0x3ed648=!0x1);_0x1ded7b<_0x13805f;)_0x5384e8['push'](this['repository']['getRevision'](_0x1ded7b)),_0x1ded7b++;return _0x3ed648&&_0x5384e8['push'](this['repository']['getRevision'](_0x1ded7b)),_0x5384e8;}['_threeWayMerge'](_0x2dd29f,_0xa4844b,_0x428a36,_0x58ff2c){const _0x427ac1=this['editor']['model']['schema'];let _0x43c6d4=_0xa4844b;for(;_0x2dd29f[_0x43c6d4]&&_0x2dd29f[_0x43c6d4]['isAdded'];)_0x43c6d4++;let _0x20dc6d=_0x58ff2c;for(;_0x428a36[_0x20dc6d]&&_0x428a36[_0x20dc6d]['isRemoved'];)_0x20dc6d++;_0x403de7(_0x2dd29f,_0xa4844b,_0x43c6d4),_0x403de7(_0x428a36,_0x58ff2c,_0x20dc6d);const _0x765063=_0x428a36['slice'](_0x58ff2c,_0x20dc6d)['concat'](_0x2dd29f['slice'](_0xa4844b,_0x43c6d4));return _0x765063['sort']((_0x3b3571,_0x3b9722)=>_0x3b3571['side']!=_0x3b9722['side']?_0x3b3571['side']-_0x3b9722['side']:_0x3b3571['level']!=_0x3b9722['level']?_0x3b3571['level']-_0x3b9722['level']:_0x3b3571['distance']!=_0x3b9722['distance']?_0x3b9722['distance']-_0x3b3571['distance']:!!_0x3b3571['isAdded']!=!!_0x3b9722['isAdded']?-0x1==_0x3b3571['side']||0x0==_0x3b3571['side']?_0x3b3571['isAdded']?-0x1:0x1:_0x3b3571['isAdded']?0x1:-0x1:_0x3b3571['index']-_0x3b9722['index']),{'commonTape':_0x765063,'iEnd':_0x43c6d4,'jEnd':_0x20dc6d};function _0x403de7(_0x8fc43e,_0x49c551,_0x151bf2){let _0x23c997=-0x1,_0x16d8bd=Number['POSITIVE_INFINITY'],_0x170caf=!0x0;for(let _0x46ac2f=_0x49c551;_0x46ac2f<_0x151bf2;_0x46ac2f++)if(_0x427ac1['isInline'](_0x8fc43e[_0x46ac2f]['item'])||(_0x170caf=!0x1),_0x8fc43e[_0x46ac2f]['item']['startIndex']<_0x49c551&&(_0x23c997=_0x46ac2f),_0x8fc43e[_0x46ac2f]['item']['endIndex']>=_0x151bf2){_0x16d8bd=_0x46ac2f;break;}_0x170caf&&(_0x23c997=_0x151bf2-0x1);for(let _0x306814=_0x49c551;_0x306814<_0x151bf2;_0x306814++)_0x8fc43e[_0x306814]['side']=_0x306814<=_0x23c997?-0x1:_0x306814<_0x16d8bd?0x0:0x1,_0x8fc43e[_0x306814]['index']=_0x306814;let _0x4d8764=0x0;for(let _0x322545=_0x49c551;_0x322545<=_0x23c997;_0x322545++)0x0==_0x8fc43e[_0x322545]['distance']?_0x8fc43e[_0x322545]['level']=_0x4d8764:(_0x4d8764++,_0x8fc43e[_0x322545]['level']=_0x4d8764,_0x4d8764++);for(let _0xdacd34=_0x49c551;_0xdacd34<_0x151bf2;_0xdacd34++)0x0==_0x8fc43e[_0xdacd34]['side']&&(_0x8fc43e[_0xdacd34]['level']=_0x4d8764);_0x4d8764=0x0;for(let _0x4380eb=_0x151bf2-0x1;_0x4380eb>=_0x16d8bd;_0x4380eb--)0x0==_0x8fc43e[_0x4380eb]['distance']?_0x8fc43e[_0x4380eb]['level']=_0x4d8764:(_0x4d8764--,_0x8fc43e[_0x4380eb]['level']=_0x4d8764,_0x4d8764--);}}['_fixObsoleteTags'](_0x48f711){const _0x254af3=new Map(),_0x5dddb8=this['editor']['model']['schema'];for(let _0x4a47de=0x1;_0x4a47de<_0x48f711['length'];_0x4a47de++){let _0x2618e0,_0x38f2f7,_0x9c13dc;const _0x3ec237=_0x48f711[_0x4a47de],_0x117e78=_0x48f711[_0x4a47de-0x1];if('text'==_0x3ec237['type'])continue;if(_0x3ec237['type']!=_0x117e78['type'])continue;if(!_0x5dddb8['isBlock'](_0x117e78['item'])||_0x5dddb8['isLimit'](_0x117e78['item']))continue;if(!_0x5dddb8['isBlock'](_0x3ec237['item'])||_0x5dddb8['isLimit'](_0x3ec237['item']))continue;if((_0x48f711[_0x4a47de]['isAdded']||_0x48f711[_0x4a47de]['isAddSuggestion'])&&_0x48f711[_0x4a47de-0x1]['isRemoved'])_0x2618e0=_0x48f711[_0x4a47de],_0x38f2f7=_0x48f711[_0x4a47de-0x1],_0x9c13dc=_0x4a47de-0x1;else{if(!_0x48f711[_0x4a47de]['isRemoved']||!_0x48f711[_0x4a47de-0x1]['isAdded']&&!_0x48f711[_0x4a47de-0x1]['isAddSuggestion'])continue;_0x2618e0=_0x48f711[_0x4a47de-0x1],_0x38f2f7=_0x48f711[_0x4a47de],_0x9c13dc=_0x4a47de;}const _0x82c48d=_0x2618e0['level']==_0x38f2f7['level'],_0x3f4feb=Math['abs'](_0x2618e0['level'])<Math['abs'](_0x38f2f7['level'])&&0x0==_0x38f2f7['distance'];(_0x82c48d||_0x3f4feb)&&(_0x254af3['set'](_0x38f2f7['id'],_0x2618e0['id']),_0x48f711['splice'](_0x9c13dc,0x1),_0x4a47de--,_0x2618e0['isAdded']=!0x1);}for(let _0x594d62=0x0;_0x594d62<_0x48f711['length'];_0x594d62++)_0x254af3['has'](_0x48f711[_0x594d62]['pairId'])&&(_0x48f711[_0x594d62]['pairId']=_0x254af3['get'](_0x48f711[_0x594d62]['pairId']));}['_removeMissingPairs'](_0x5e5c1d){const _0x43fb84=new Set(_0x5e5c1d['map'](_0x4c05dd=>_0x4c05dd['id']));for(let _0x2b0c2f=0x0;_0x2b0c2f<_0x5e5c1d['length'];_0x2b0c2f++)_0x43fb84['has'](_0x5e5c1d[_0x2b0c2f]['pairId'])||0x0==_0x5e5c1d[_0x2b0c2f]['distance']||(_0x5e5c1d[_0x2b0c2f]['isIncorrect']=!0x0);return _0x5e5c1d['filter'](_0x333b40=>!_0x333b40['isIncorrect']);}['_markMismatchedRemovedTags'](_0x10ed36){const _0x2841a4=new Set();for(let _0x5750c1=0x0;_0x5750c1<_0x10ed36['length'];_0x5750c1++){if(_0x2841a4['has'](_0x10ed36[_0x5750c1]['id'])&&_0x10ed36[_0x5750c1]['isRemoved']&&(_0x10ed36[_0x5750c1]['isIncorrect']=!0x0),_0x10ed36[_0x5750c1]['isIncorrect'])continue;if(0x0==_0x10ed36[_0x5750c1]['distance'])continue;if('elementStart'!=_0x10ed36[_0x5750c1]['type'])continue;if(null==_0x10ed36[_0x5750c1]['pairId'])continue;let _0x3c0aa4=_0x5750c1+0x1,_0x5c88a5=0x0;for(;_0x10ed36[_0x3c0aa4]['id']!=_0x10ed36[_0x5750c1]['pairId'];)'elementStart'==_0x10ed36[_0x3c0aa4]['type']?_0x5c88a5++:'elementEnd'==_0x10ed36[_0x3c0aa4]['type']&&_0x5c88a5--,_0x3c0aa4++;if(0x0!=_0x5c88a5){if(_0x10ed36[_0x5750c1]['isRemoved'])_0x10ed36[_0x5750c1]['isIncorrect']=!0x0;else{for(;_0x3c0aa4!=_0x5750c1;)_0x10ed36[_0x3c0aa4]['isRemoved']&&0x0!=_0x10ed36[_0x3c0aa4]['distance']&&(_0x10ed36[_0x3c0aa4]['isIncorrect']=!0x0,_0x2841a4['add'](_0x10ed36[_0x3c0aa4]['pairId'])),_0x3c0aa4--;}}}return _0x10ed36['filter'](_0x3d70c8=>!_0x3d70c8['isIncorrect']);}['_removeUnsupportedChanges'](_0xe7904a){const _0x591a6d=this['editor']['model']['schema'];for(let _0x11e389=0x0;_0x11e389<_0xe7904a['length'];_0x11e389++){if(!(_0xe7904a[_0x11e389]['isAdded']||_0xe7904a[_0x11e389]['isAddSuggestion']||_0xe7904a[_0x11e389]['isRemoved']||_0xe7904a[_0x11e389]['isRemoveSuggestion']))continue;if(0x0==_0xe7904a[_0x11e389]['distance'])continue;const _0x4bb855=_0xe7904a[_0x11e389]['item'];_0x591a6d['isBlock'](_0x4bb855)||_0x591a6d['isLimit'](_0x4bb855)||(_0xe7904a[_0x11e389]['isAdded']&&delete _0xe7904a[_0x11e389]['isAdded'],_0xe7904a[_0x11e389]['isAddSuggestion']&&delete _0xe7904a[_0x11e389]['isAddSuggestion'],_0xe7904a[_0x11e389]['isRemoveSuggestion']&&delete _0xe7904a[_0x11e389]['isRemoveSuggestion'],_0xe7904a[_0x11e389]['isRemoved']&&(_0xe7904a[_0x11e389]['isIncorrect']=!0x0));}return _0xe7904a['filter'](_0x425ffc=>!_0x425ffc['isIncorrect']);}['_makeModelFromTape'](_0x9e231a,_0x421af7,_0x18de5f){const _0x42dece=new _0x416f4f(),_0xc5ff76=[],_0x1f7c61=new Map(),_0x573966=this['editor']['model'],_0x418879=_0x573966['schema'],_0x4b6b5e=[_0x42dece],_0xc29777={},_0x3b1bee={'isAdded':[],'isRemoved':[],'isAddSuggestion':[],'isRemoveSuggestion':[]};let _0x380260=null;const _0x5eac13=[0x0];for(let _0x46d924=0x0;_0x46d924<_0x9e231a['length'];_0x46d924++)if('elementStart'===_0x9e231a[_0x46d924]['type']){_0x9e231a[_0x46d924]['previousPosition']=_0x573966['createPositionFromPath'](_0x42dece,_0x5eac13);const _0x13e23b=new _0x236395(_0x9e231a[_0x46d924]['item']['name'],_0x9e231a[_0x46d924]['item']['getAttributes']());_0x4b6b5e[0x0]['_appendChild'](_0x13e23b),_0x5eac13['push'](0x0),_0x4b6b5e['unshift'](_0x13e23b),_0x9e231a[_0x46d924]['nextPosition']=_0x573966['createPositionFromPath'](_0x42dece,_0x5eac13);}else'elementEnd'===_0x9e231a[_0x46d924]['type']?(_0x4b6b5e['shift'](),_0x9e231a[_0x46d924]['previousPosition']=_0x573966['createPositionFromPath'](_0x42dece,_0x5eac13),_0x5eac13['pop'](),_0x5eac13[_0x5eac13['length']-0x1]++,_0x9e231a[_0x46d924]['nextPosition']=_0x573966['createPositionFromPath'](_0x42dece,_0x5eac13)):(_0x9e231a[_0x46d924]['previousPosition']=_0x573966['createPositionFromPath'](_0x42dece,_0x5eac13),_0x380260?_0x380260['_data']+=_0x9e231a[_0x46d924]['item']['data']:_0x380260=new _0x5fe234(_0x9e231a[_0x46d924]['item']['data'],_0x9e231a[_0x46d924]['item']['getAttributes']()),_0x9e231a[_0x46d924+0x1]&&'text'===_0x9e231a[_0x46d924+0x1]['type']&&_0x37b2d4(_0x380260,_0x9e231a[_0x46d924+0x1]['item'])||(_0x4b6b5e[0x0]['_appendChild'](_0x380260),_0x380260=null),_0x5eac13[_0x5eac13['length']-0x1]+=_0x9e231a[_0x46d924]['item']['offsetSize'],_0x9e231a[_0x46d924]['nextPosition']=_0x573966['createPositionFromPath'](_0x42dece,_0x5eac13));for(let _0x51e71b=0x0;_0x51e71b<_0x9e231a['length'];_0x51e71b++){const _0x270a80=_0x9e231a[_0x51e71b]['previousPosition'],_0x2faf65=_0x9e231a[_0x51e71b]['nextPosition'];for(const _0x4013c2 of _0x9e231a[_0x51e71b]['markersStart'])_0x1f7c61['set'](_0x4013c2,{'start':_0x270a80,'end':null});_0x4f328f('isRemoveSuggestion',_0x51e71b,_0x270a80,_0x2faf65),_0x4f328f('isAddSuggestion',_0x51e71b,_0x270a80,_0x2faf65),_0x4f328f('isRemoved',_0x51e71b,_0x270a80,_0x2faf65),_0x4f328f('isAdded',_0x51e71b,_0x270a80,_0x2faf65);for(const _0x1575fb of _0x9e231a[_0x51e71b]['markersEnd']){const _0x44b0f7=_0x1f7c61['get'](_0x1575fb);_0x44b0f7?_0x44b0f7['end']=_0x2faf65:_0x1f7c61['set'](_0x1575fb,{'start':_0x2faf65,'end':_0x2faf65});}}for(const [_0x16efb6,_0x4e7d12]of _0x1f7c61){const _0x4b9fda=this['editor']['model']['createRange'](_0x4e7d12['start'],_0x4e7d12['end']);_0x42dece['markers']['set'](_0x16efb6,_0x4b9fda);}return _0xc5ff76['sort']((_0xb0be19,_0x1be82e)=>{const _0x550f3b=_0x42dece['markers']['get']('revision:'+_0xb0be19['id']),_0x380b89=_0x42dece['markers']['get']('revision:'+_0x1be82e['id']);return _0x550f3b['start']['isBefore'](_0x380b89['start'])?-0x1:_0x550f3b['start']['isAfter'](_0x380b89['start'])?0x1:_0x550f3b['end']['isBefore'](_0x380b89['end'])?-0x1:_0x550f3b['end']['isAfter'](_0x380b89['end'])?0x1:'add'===_0xb0be19['type']?-0x1:0x1;}),{'root':_0x42dece,'changes':_0xc5ff76};function _0x4f328f(_0x44a6b7,_0x1d23d2,_0x47ef5a,_0x3a6721){const _0x29df56=!!_0x9e231a[_0x1d23d2][_0x44a6b7],_0x251ef5=_0x29df56?_0x9e231a[_0x1d23d2][_0x44a6b7]['userId']:null,_0x4d799f=_0x1d23d2===_0x9e231a['length']-0x1,_0x5d6399=_0x3b1bee[_0x44a6b7][0x0],_0xeb14bc=_0x418879['isObject'](_0x9e231a[_0x1d23d2]['item']);!_0xc29777[_0x44a6b7]&&_0x29df56?_0xc29777[_0x44a6b7]={'start':_0x47ef5a,'tapeItem':_0x9e231a[_0x1d23d2],'userId':_0x251ef5,'type':_0x44a6b7}:_0xc29777[_0x44a6b7]&&!_0x29df56?(_0xc29777[_0x44a6b7]['end']=_0x47ef5a,_0x5a7905(_0xc29777[_0x44a6b7]),_0xc29777[_0x44a6b7]=null):_0xc29777[_0x44a6b7]&&_0x29df56&&_0xc29777[_0x44a6b7]['userId']!==_0x251ef5&&(_0xc29777[_0x44a6b7]['end']=_0x47ef5a,_0x5d6399&&_0x5d6399['userId']===_0xc29777[_0x44a6b7]['userId']||_0x5a7905(_0xc29777[_0x44a6b7]),_0xc29777[_0x44a6b7]={'start':_0x47ef5a,'tapeItem':_0x9e231a[_0x1d23d2],'userId':_0x251ef5,'type':_0x44a6b7}),_0xc29777[_0x44a6b7]&&_0xeb14bc&&('elementStart'!==_0x9e231a[_0x1d23d2]['type']||_0x5d6399&&_0x5d6399['userId']===_0x251ef5||_0x3b1bee[_0x44a6b7]['unshift']({'userId':_0x251ef5,'object':_0x9e231a[_0x1d23d2]['item'],'change':_0xc29777[_0x44a6b7]}),'elementEnd'===_0x9e231a[_0x1d23d2]['type']&&_0x5d6399&&_0x5d6399['object']===_0x9e231a[_0x1d23d2]['item']&&(_0x3b1bee[_0x44a6b7]['shift'](),_0xc29777[_0x44a6b7]=_0x5d6399['change'])),_0xc29777[_0x44a6b7]&&_0x4d799f&&(_0xc29777[_0x44a6b7]['end']=_0x3a6721,_0x5a7905(_0xc29777[_0x44a6b7]),_0xc29777[_0x44a6b7]=null);}function _0x5a7905({start:_0x2a2513,end:_0x28527d,tapeItem:_0x5520cb,userId:_0x3681f4,type:_0x212e1d}){const _0xee8811=_0x5520cb['item'],_0x5c3e58=_0x573966['schema']['isBlock'](_0xee8811)&&!_0x573966['schema']['isLimit'](_0xee8811),_0x3cece2=_0x2a2513['nodeAfter']==_0x28527d['parent']&&_0x28527d['isAtStart'];if(_0x5c3e58&&_0x3cece2)return;const _0x480ab2=_0x573966['createRange'](_0x2a2513,_0x28527d),_0x38f8c6=_0x421af7['get'](_0x3681f4),_0x467dcb=new G({'author':_0x38f8c6,'type':'isAdded'==_0x212e1d||'isAddSuggestion'==_0x212e1d?'add':'remove','data':{'isSuggestion':'isAddSuggestion'==_0x212e1d||'isRemoveSuggestion'==_0x212e1d},'createdAt':new Date(),'rootName':_0x18de5f});_0xc5ff76['push'](_0x467dcb),_0x42dece['markers']['set']('revision:'+_0x467dcb['id'],_0x480ab2);}function _0x37b2d4(_0xe39653,_0x48dd4d){const _0x5b3c43=_0xe39653['getAttributes'](),_0xaff9dd=_0x48dd4d['getAttributes']();for(const _0x39a464 of _0x5b3c43){if(_0x39a464[0x1]!==_0x48dd4d['getAttribute'](_0x39a464[0x0]))return!0x1;_0xaff9dd['next']();}return _0xaff9dd['next']()['done'];}}['_setConversion'](){this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision','view':_0x40a937=>{const _0x2edcc9=_0x40a937['markerName']['split'](':')[0x1],_0x26fb8e=this['_getChangeFromId'](_0x2edcc9);if(!_0x26fb8e)return null;const _0x39b187='add'==_0x26fb8e['type']?'insertion':'deletion',_0xcbe146=['ck-suggestion-marker','ck-suggestion-marker-'+_0x39b187];return _0x26fb8e['data']['isSuggestion']&&_0xcbe146['push']('ck-suggestion-marker-'+_0x39b187+'-new'),this['activeChange']==_0x26fb8e&&_0xcbe146['push']('ck-suggestion-marker--active'),{'classes':_0xcbe146,'attributes':{'data-change-id':_0x2edcc9}};}}),this['editor']['conversion']['for']('upcast')['add'](_0x5572f1=>{_0x5572f1['on']('element:pre',(_0x2d29b7,_0x17e32d,_0x21d20f)=>{const _0x1ae01a=_0x17e32d['viewItem']['getChild'](0x0);if(!_0x1ae01a||!_0x1ae01a['is']('element','code'))return;if(!_0x21d20f['consumable']['consume'](_0x1ae01a,{'attributes':['vid_start','vid_end']}))return;const _0x2a0d46=_0x17e32d['modelRange']['start']['nodeAfter'];_0x21d20f['writer']['setAttribute']('vid_start',_0x1ae01a['getAttribute']('vid_start'),_0x2a0d46),_0x21d20f['writer']['setAttribute']('vid_end',_0x1ae01a['getAttribute']('vid_end'),_0x2a0d46);},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['add'](_0x7bd16d=>{_0x7bd16d['on']('element',(_0x18d641,_0x1842e6,_0x3e8862)=>{if(!_0x3e8862['consumable']['consume'](_0x1842e6['viewItem'],{'attributes':['vid_start','vid_end']}))return;if(_0x1842e6['modelRange']['isCollapsed'])return;const _0x576b41=_0x1842e6['modelRange']['start']['nodeAfter'];_0x576b41['hasAttribute']('vid_start')||_0x576b41['hasAttribute']('vid')||(_0x3e8862['writer']['setAttribute']('vid_start',_0x1842e6['viewItem']['getAttribute']('vid_start'),_0x576b41),_0x3e8862['writer']['setAttribute']('vid_end',_0x1842e6['viewItem']['getAttribute']('vid_end'),_0x576b41));},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['elementToAttribute']({'view':{'name':'span','attributes':{'vid':!0x0}},'model':{'key':'vid','value':_0x2924d9=>_0x2924d9['getAttribute']('vid')}}),this['editor']['model']['schema']['on']('checkAttribute',(_0x389402,[,_0x39ebbf])=>{['vid_start','vid_end','vid']['includes'](_0x39ebbf)&&(_0x389402['return']=!0x0,_0x389402['stop']());},{'priority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x536232=>{_0x536232['on']('attribute:vid',(_0x1a29e0,_0x32d72a,_0x48d22a)=>{if('\x20'!=_0x32d72a['item']['data']||_0x32d72a['item']['parent']['maxOffset']>0x1)return;if(!_0x48d22a['consumable']['consume'](_0x32d72a['item'],_0x1a29e0['name']))return;const _0x1454ef=_0x48d22a['writer'],_0x3887dc=_0x48d22a['mapper']['toViewRange'](_0x32d72a['range']);_0x1454ef['wrap'](_0x3887dc,_0x1454ef['createAttributeElement']('span'));});}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',function(_0x52230f){const _0x19ddbc=_0x52230f['plugins']['get']('RevisionViewer');return(_0x3aac80,_0x5f4fbd,_0x3d15f8)=>{const _0x2293d6=_0x5f4fbd['markerName']['split'](':')[0x1],_0xf57d11=_0x19ddbc['_getChangeFromId'](_0x2293d6);if(!_0xf57d11)return null;const _0x45117b='add'==_0xf57d11['type']?'split':'merge';if(!_0x3d15f8['consumable']['test'](_0x5f4fbd['markerRange'],_0x3aac80['name']))return;const _0x46e74f=_0x5f4fbd['markerRange']['getWalker'](),_0x4b5e71=_0x5f4fbd['markerRange']['start'],_0x36a41b=_0x52230f['model']['schema'];let _0xff71ec=null,_0x510501=null,_0x27cd46=!0x1,_0x365ef1=!0x1;for(const _0x4e31c3 of _0x46e74f){const _0x506840=_0x4e31c3['item'];_0x27cd46=_0x27cd46||_0x36a41b['isContent'](_0x506840);const _0x4902b7=_0x3d15f8['mapper']['toViewElement'](_0x506840);if(_0x4902b7&&_0x4902b7['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x4e31c3['type']&&(_0x36a41b['isBlock'](_0x506840)&&!_0x36a41b['isLimit'](_0x506840)&&(_0x506840['nextSibling']||_0x4b5e71['isAtEnd']?_0xff71ec&&_0xff71ec['parent']==_0x506840||(_0xff71ec=_0x506840,_0x400d55(_0x4e31c3['previousPosition']),_0x365ef1=!0x0):_0x510501=_0x510501||_0x4e31c3['previousPosition']));}function _0x400d55(_0x4bc48b){const _0x457679=_0x3d15f8['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x45117b}),_0x44c4ab=_0x3d15f8['mapper']['toViewPosition'](_0x4bc48b);_0xf57d11['data']['isSuggestion']&&_0x3d15f8['writer']['addClass']('ck-suggestion-marker-'+_0x45117b+'-new',_0x457679),_0x19ddbc['activeChange']==_0xf57d11&&_0x3d15f8['writer']['addClass']('ck-suggestion-marker--active',_0x457679),_0x3d15f8['writer']['insert'](_0x44c4ab,_0x457679),_0x3d15f8['mapper']['bindElementToMarker'](_0x457679,_0x5f4fbd['markerName']);}_0x27cd46||_0x365ef1||!_0x510501||_0x400d55(_0x510501);};}(this['editor']),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision',(_0x1a4c6b,_0x27b4f2,_0xb105e8)=>{const _0x581503=_0xb105e8['mapper']['markerNameToElements'](_0x27b4f2['markerName']);if(_0x581503){for(const _0x5b96c0 of _0x581503)(_0x5b96c0['hasClass']('ck-suggestion-marker-split')||_0x5b96c0['hasClass']('ck-suggestion-marker-merge'))&&(_0xb105e8['mapper']['unbindElementFromMarkerName'](_0x5b96c0,_0x27b4f2['markerName']),_0xb105e8['writer']['remove'](_0x5b96c0));}},{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',(_0x521490,_0x11923a,_0x476c01)=>{const _0x5eb63f=_0x11923a['markerName']['split'](':')[0x1],_0x559c62=this['_getChangeFromId'](_0x5eb63f);if(!_0x559c62)return null;const _0x5b386c='add'==_0x559c62['type']?'split':'merge';if(_0x476c01['consumable']['test'](_0x11923a['markerRange'],_0x521490['name']))for(const _0x288f20 of _0x11923a['markerRange']['getItems']()){if(!_0x288f20['is']('element','softBreak'))continue;const _0x2b1f89=_0x476c01['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x5b386c}),_0x400fad=_0x476c01['mapper']['toViewPosition'](this['editor']['model']['createPositionBefore'](_0x288f20));_0x559c62['data']['isSuggestion']&&_0x476c01['writer']['addClass']('ck-suggestion-marker-'+_0x5b386c+'-new',_0x2b1f89),this['activeChange']==_0x559c62&&_0x476c01['writer']['addClass']('ck-suggestion-marker--active',_0x2b1f89),_0x476c01['writer']['insert'](_0x400fad,_0x2b1f89),_0x476c01['mapper']['bindElementToMarker'](_0x2b1f89,_0x11923a['markerName']);}},{'priority':'high'}),this['editor']['model']['document']['on']('change',()=>{this['editor']['editing']['view']['change'](_0x10cdc8=>{for(const _0x1984b7 of this['editor']['model']['document']['getRootNames']()){const _0x11568f=this['editor']['model']['document']['getRoot'](_0x1984b7),_0x25c76f=this['editor']['editing']['view']['document']['getRoot'](_0x1984b7);if(_0x25c76f){const _0x4b9b42=_0x11568f['getAttribute']('revisionHistoryAttachChange');if(_0x10cdc8['removeAttribute']('data-change-id',_0x25c76f),_0x10cdc8['removeClass']('ck-revision-history-root-add',_0x25c76f),_0x10cdc8['removeClass']('ck-revision-history-root-remove',_0x25c76f),_0x10cdc8['removeClass']('ck-revision-history-root--active',_0x25c76f),_0x4b9b42){const _0x2d7d2c=this['_getChangeFromId'](_0x4b9b42);if(!_0x2d7d2c)return null;_0x10cdc8['setAttribute']('data-change-id',_0x4b9b42,_0x25c76f),_0x10cdc8['addClass']('ck-revision-history-root-'+_0x2d7d2c['type'],_0x25c76f),this['activeChange']==_0x2d7d2c&&_0x10cdc8['addClass']('ck-revision-history-root--active',_0x25c76f);}}}});}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'comment','model':_0x2f242d=>'revision-comment:'+_0x2f242d,'converterPriority':'highest'}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'suggestion','model':_0x20a318=>'revision-suggestion:'+_0x20a318,'converterPriority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision-suggestion','view':_0x500c1f=>({'name':'suggestion:'+_0x500c1f,'group':'revision-suggestion'}),'converterPriority':'highest'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision-suggestion','view':_0x3fb715=>{const _0x262415=_0x3fb715['markerName']['split'](':')[0x1];return'insertion'!=_0x262415&&'deletion'!=_0x262415?null:{'classes':['ck-suggestion-preview-marker','ck-suggestion-preview-marker-'+_0x262415]};}}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:deletion',Q(this['editor'],'merge'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:insertion',Q(this['editor'],'split'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision-suggestion',(_0xe2c89f,_0xf28b93,_0x31bfde)=>{const _0x11dadc=_0x31bfde['mapper']['markerNameToElements'](_0xf28b93['markerName']);if(_0x11dadc){for(const _0xe6f396 of _0x11dadc)_0xe6f396['is']('uiElement')&&(_0x31bfde['mapper']['unbindElementFromMarkerName'](_0xe6f396,_0xf28b93['markerName']),_0x31bfde['writer']['remove'](_0xe6f396));}},{'priority':'high'});}['_getChangeFromId'](_0x1fc2a7){return this['_changeIdToChange']['get'](_0x1fc2a7);}['_getViewForChange'](_0x3b3cdc){return this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=new z(this['editor']['locale'],_0x3b3cdc),this['_changeView'];}['_initInteractions'](){this['editor']['model']['document']['selection']['observeMarkers']('revision'),this['on']('change:activeView',(_0x1812f4,_0x4a6cdc,_0x3dd5cc,_0x3bf009)=>{_0x3bf009&&this['_balloon']['remove'](_0x3bf009),_0x3dd5cc&&(this['_balloon']['add']({'view':_0x3dd5cc,'stackId':'revisionHistoryLabel','position':{'target':()=>{const _0x4a7933=this['editor']['editing'],_0x400af4=this['_getChangeFromId'](_0x3dd5cc['changeId']);let _0xf24a38;if(_0x400af4['data']['isOnRoot']){const _0x8c139a=_0x4a7933['view']['getDomRoot'](_0x400af4['rootName']);_0xf24a38=Array['from'](_0x8c139a['getClientRects']());}else{const _0x595f7d=this['editor']['model']['markers']['get']('revision:'+_0x3dd5cc['changeId']);_0xf24a38=Array['from'](_0x4a7933['mapper']['markerNameToElements'](_0x595f7d['name']))['map'](_0x35b6c4=>_0x4a7933['view']['domConverter']['mapViewToDom'](_0x35b6c4))['map'](_0x2c8853=>Array['from'](_0x2c8853['getClientRects']()))['flat']();}if(!this['_activeViewTarget'])return _0xf24a38[0x0];return _0xf24a38['find'](_0x2ad370=>_0x2ad370['top']-0x3<=this['_activeViewTarget']['y']&&_0x2ad370['bottom']+0x3>=this['_activeViewTarget']['y']&&_0x2ad370['left']-0x3<=this['_activeViewTarget']['x']&&_0x2ad370['right']+0x3>=this['_activeViewTarget']['x'])||_0xf24a38[0x0];}}}),this['_balloon']['showStack']('revisionHistoryLabel'));}),this['on']('change:activeChange',(_0x3bf8fd,_0x4c60e8,_0x57787b,_0x5c5e60)=>{this['activeView']=_0x57787b?this['_getViewForChange'](_0x57787b):null,this['editor']['model']['change'](()=>{const _0x5df0ae=this['editor']['editing'];_0x5c5e60&&(_0x5c5e60['data']['isOnRoot']?_0x5df0ae['view']['change'](_0x5d9f7d=>{_0x5d9f7d['removeClass']('ck-revision-history-root--active',_0x5df0ae['view']['document']['getRoot'](_0x5c5e60['rootName']));}):_0x5df0ae['reconvertMarker']('revision:'+_0x5c5e60['id'])),_0x57787b&&(_0x57787b['data']['isOnRoot']?_0x5df0ae['view']['change'](_0x32fd70=>{_0x32fd70['addClass']('ck-revision-history-root--active',_0x5df0ae['view']['document']['getRoot'](_0x57787b['rootName']));}):_0x5df0ae['reconvertMarker']('revision:'+_0x57787b['id']));});}),this['listenTo'](this['editor']['editing']['view']['document'],'mouseover',(_0x575740,_0x1b71ca)=>{if(this['activeChange'])return;const _0x2fbee7=this['_findChangeIdFromDomTarget'](_0x1b71ca['target']),_0x25ad6f=this['_changeIdToChange']['get'](_0x2fbee7);_0x25ad6f?(this['_activeViewTarget']={'x':_0x1b71ca['domEvent']['x'],'y':_0x1b71ca['domEvent']['y']},this['activeView']=this['_getViewForChange'](_0x25ad6f)):(this['_activeViewTarget']=null,this['activeView']=null);}),this['listenTo'](this['editor']['editing']['view']['document'],'mousedown',(_0x39c5f,_0x4ec595)=>{const _0x441930=this['_findChangeIdFromDomTarget'](_0x4ec595['target']),_0x18a8a0=this['_changeIdToChange']['get'](_0x441930);_0x18a8a0?(this['_activeViewTarget']={'x':_0x4ec595['domEvent']['x'],'y':_0x4ec595['domEvent']['y']},_0x18a8a0===this['activeChange']?this['_balloon']['updatePosition']():this['activeChange']=_0x18a8a0):(this['_activeViewTarget']=null,this['activeChange']=null);});}['_findChangeIdFromDomTarget'](_0x46a465){do{const _0x18d04d=_0x46a465['getAttribute']('data-change-id');if(_0x18d04d)return _0x18d04d;_0x46a465=_0x46a465['parent'];}while(_0x46a465);return null;}['_cleanMarkers'](){this['editor']['model']['change'](_0x4a7561=>{for(const _0x53cce7 of this['editor']['model']['markers'])_0x4a7561['removeMarker'](_0x53cce7);});}}function Q(_0x27f294,_0x3a39d7){return(_0x12411f,_0x5eb567,_0x32e6c9)=>{if(!_0x32e6c9['consumable']['test'](_0x5eb567['markerRange'],_0x12411f['name']))return;const _0x3824c9=_0x5eb567['markerRange']['getWalker'](),_0x4e5b82=_0x5eb567['markerRange']['start'],_0xb804e2=_0x27f294['model']['schema'];let _0x2ffffb=null,_0x4247c8=null,_0x28e5e2=!0x1,_0x2ae952=!0x1;for(const _0x59a5fe of _0x3824c9){const _0x5394e9=_0x59a5fe['item'];_0x28e5e2=_0x28e5e2||_0xb804e2['isContent'](_0x5394e9);const _0x98530a=_0x32e6c9['mapper']['toViewElement'](_0x5394e9);if(_0x98530a&&_0x98530a['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x59a5fe['type']&&(_0xb804e2['isBlock'](_0x5394e9)&&!_0xb804e2['isLimit'](_0x5394e9)&&(_0x5394e9['nextSibling']||_0x4e5b82['isAtEnd']?_0x2ffffb&&_0x2ffffb['parent']==_0x5394e9||(_0x2ffffb=_0x5394e9,_0x5a8428(_0x59a5fe['previousPosition']),_0x2ae952=!0x0):_0x4247c8=_0x4247c8||_0x59a5fe['previousPosition']));}function _0x5a8428(_0x19c820){const _0x53cced=_0x32e6c9['mapper']['toViewPosition'](_0x19c820),_0x264ae5=_0x32e6c9['writer']['createUIElement']('span',{'class':'ck-suggestion-preview-marker-'+_0x3a39d7});_0x32e6c9['writer']['insert'](_0x53cced,_0x264ae5),_0x32e6c9['mapper']['bindElementToMarker'](_0x264ae5,_0x5eb567['markerName']);}_0x28e5e2||_0x2ae952||!_0x4247c8||_0x5a8428(_0x4247c8);};}class nt extends _0x3068ad{constructor(_0x17a139){super(_0x17a139);const _0x12570e=_0x17a139['plugins']['get'](u);this['affectsData']=!0x1,this['listenTo'](_0x12570e,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x12570e,'change:isEnabled',()=>this['refresh']());}['execute'](){const _0x490846=this['editor'],_0x4ea986=_0x490846['plugins']['get'](u),_0x286e39=_0x4ea986['isReady']?_0x4ea986['diff']['newRevisionId']:null;_0x490846['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x286e39);}['refresh'](){const {isReady:_0x1652d8,isEnabled:_0xc76a2e,repository:_0xa7feca,diff:_0xe8e249}=this['editor']['plugins']['get'](u),_0x143792=_0xe8e249&&_0xa7feca['getLaterVisibleRevision'](_0xe8e249['newRevisionId']);this['isEnabled']=_0x1652d8&&_0xc76a2e&&Boolean(_0x143792);}}class rt extends _0x3068ad{['_step'];constructor(_0x564a3f,{direction:_0x571262}){super(_0x564a3f);const _0x5ead75=_0x564a3f['plugins']['get'](u);this['affectsData']=!0x1,this['_step']='forward'===_0x571262?0x1:-0x1,this['listenTo'](_0x5ead75,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x5ead75,'change:isEnabled',()=>this['refresh']()),this['listenTo'](_0x5ead75,'change:activeChange',()=>this['refresh']());}['execute'](){const _0x1837ba=this['editor'],_0x23fc6c=_0x1837ba['plugins']['get'](u),{isNavigationMode:_0x3fb2da,currentChangeNumber:_0x71c80b}=_0x23fc6c;let _0x1809a4;if(_0x23fc6c['activeChange']=_0x3fb2da?_0x23fc6c['diff']['changes']['get'](_0x71c80b+this['_step']):_0x23fc6c['diff']['changes']['first'],_0x23fc6c['activeChange']['data']['isOnRoot'])_0x1809a4=_0x1837ba['editing']['view']['getDomRoot'](_0x23fc6c['activeChange']['rootName']);else{const _0x1109bf=_0x1837ba['model']['markers']['get']('revision:'+_0x23fc6c['activeChange']['id']);_0x1809a4=_0x54852a(_0x1837ba['editing'],_0x1109bf);}_0x32b079({'target':_0x1809a4,'viewportOffset':0x28});}['refresh'](){const {isNavigationMode:_0x1c4bd9,currentChangeNumber:_0x102561,numberOfChanges:_0x3c250c,isReady:_0x57ac42,isEnabled:_0x33b90e}=this['editor']['plugins']['get'](u);this['isEnabled']=!!(_0x33b90e&&_0x57ac42&&_0x3c250c)&&(!_0x1c4bd9||(0x1===this['_step']?_0x102561<_0x3c250c-0x1:_0x102561>0x0));}}class Ri extends _0x171a1e{constructor(_0x1cfc37){super(_0x1cfc37);const _0x23e029=this['bindTemplate'],_0x58af86=new _0x2f07f1(_0x1cfc37),_0x48817b=new _0x2f07f1(_0x1cfc37);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',(_0x205549,_0x2274df)=>_0x205549&&_0x2274df>0x0),this['bind']('_statusText')['to'](this,'isReady',this,'currentChangeNumber',this,'numberOfChanges',this,'isNavigationMode',(_0x2da7de,_0x7c28e0,_0x45120e,_0xf2286e)=>{if(!_0x2da7de)return m(_0x1cfc37,'Loading...');if(!_0x45120e)return m(_0x1cfc37,'No\x20changes');const _0x535525=m(_0x1cfc37,'NUMBER_OF_CHANGES',_0x45120e);return _0xf2286e?m(_0x1cfc37,'X_OF_Y_CHANGES',[_0x7c28e0+0x1,_0x45120e]):_0x535525;}),_0x58af86['set']({'label':m(_0x1cfc37,'Show\x20previous\x20change'),'tooltip':!0x0,'icon':_0x42f1c3}),_0x48817b['set']({'label':m(_0x1cfc37,'Show\x20next\x20change'),'tooltip':!0x0,'icon':_0x2114d9}),_0x58af86['bind']('isEnabled')['to'](this,'isBackwardNavigationEnabled'),_0x48817b['bind']('isEnabled')['to'](this,'isForwardNavigationEnabled'),_0x58af86['on']('execute',()=>this['fire']('execute','backward')),_0x48817b['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',_0x23e029['if']('_isStatusLabelVisible','ck-hidden',_0x2312b2=>!_0x2312b2)]},'children':[{'text':_0x23e029['to']('isNavigationMode',_0x5760ca=>_0x5760ca?m(_0x1cfc37,'EDIT_X_OF_Y_REVISIONS')+':\x20':m(_0x1cfc37,'Total')+':\x20')}]},{'text':_0x23e029['to']('_statusText')}]},new _0xa1dda6(),{'tag':'div','attributes':{'class':['ck-revision-history-ui__changes-navigation__navigation']},'children':[_0x58af86,_0x48817b]}]});}}const ge='ck-editor__editable__loading-overlay';class ji extends _0x30489c{static get['pluginName'](){return'RevisionViewerLoadingOverlay';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['show'](){const _0x2a9091=this['editor']['editing']['view'];_0x2a9091['change'](_0xc020a3=>{for(const _0x45dcf1 of _0x2a9091['document']['roots'])_0xc020a3['addClass'](ge,_0x45dcf1);});}['hide'](){const _0x2fbce1=this['editor']['editing']['view'];_0x2fbce1['change'](_0x23e252=>{for(const _0x4d64fb of _0x2fbce1['document']['roots'])_0x23e252['removeClass'](ge,_0x4d64fb);});}}class v extends _0x30489c{static get['pluginName'](){return'RevisionViewerUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[u,ji];}['init'](){const _0x50b1b5=this['editor'],_0x39bc16=_0x50b1b5['plugins']['get'](u),_0x2672d0=_0x50b1b5['plugins']['get'](ji);_0x50b1b5['ui']['componentFactory']['add']('exitToEditing',_0x532233=>{const _0x539135=new _0x2f07f1(_0x532233);return _0x539135['set']({'label':m(_0x532233,'Back\x20to\x20editing'),'icon':_0xa73157,'withText':!0x0,'tooltip':!0x0,'class':'ck-revision-history-ui__back-to-editing'}),this['listenTo'](_0x539135,'execute',()=>{_0x50b1b5['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}),_0x539135;}),_0x50b1b5['ui']['componentFactory']['add']('restoreRevision',_0x4a4b92=>{const _0x364d5c=new _0x2f07f1(_0x4a4b92);return _0x364d5c['set']({'label':m(_0x4a4b92,'Restore\x20this\x20revision'),'withText':!0x0,'tooltip':!0x0}),_0x364d5c['bind']('isEnabled')['to'](_0x50b1b5['commands']['get']('restoreRevision')),this['listenTo'](_0x364d5c,'execute',()=>_0x50b1b5['execute']('restoreRevision')),_0x364d5c;}),_0x50b1b5['ui']['componentFactory']['add']('changesNavigation',_0xcaa4c4=>{const _0x59be78=new Ri(_0xcaa4c4),_0x1a45d1=_0x50b1b5['commands']['get']('showPreviousChange'),_0x2c03b7=_0x50b1b5['commands']['get']('showNextChange');return _0x59be78['bind']('isBackwardNavigationEnabled')['to'](_0x1a45d1,'isEnabled'),_0x59be78['bind']('isForwardNavigationEnabled')['to'](_0x2c03b7,'isEnabled'),_0x59be78['bind']('isReady','currentChangeNumber','numberOfChanges','isNavigationMode')['to'](_0x39bc16),this['listenTo'](_0x59be78,'execute',(_0x44eff7,_0x32cc52)=>{_0x50b1b5['execute']('forward'===_0x32cc52?'showNextChange':'showPreviousChange');}),_0x59be78;}),_0x2672d0['show'](),_0x39bc16['on']('change:isReady',(_0x171b5d,_0x581d53,_0x3752b5)=>{_0x3752b5?_0x2672d0['hide']():_0x2672d0['show']();});}}class hi extends et{['_resizeObserver']=null;constructor(_0x48e31d,_0x2e9fc6){super(_0x48e31d,_0x2e9fc6);const _0x11c91a=this['bindTemplate'];this['set']({'label':m(_0x48e31d,'Revision\x20name'),'_tooltipString':''}),this['fieldView']['placeholder']=m(_0x48e31d,'Enter\x20the\x20revision\x20name'),this['extendTemplate']({'tag':'span','attributes':{'class':['ck-revision-history-sidebar__revision-name'],'data-cke-tooltip-text':_0x11c91a['to']('_tooltipString'),'data-cke-tooltip-position':'s','data-cke-tooltip-class':'ck-tooltip_multi-line'}});}['render'](){super['render'](),this['_resizeObserver']=new ot(this['fieldView']['element'],()=>this['_updateTooltipText']()),this['listenTo'](this['fieldView'],'input',()=>this['_updateTooltipText']());}['destroy'](){super['destroy'](),this['_resizeObserver']&&this['_resizeObserver']['destroy']();}['_updateTooltipText'](){const _0x3b47c8=this['fieldView']['element'];this['_tooltipString']=_0x3b47c8['scrollWidth']>_0x3b47c8['clientWidth']&&_0x3b47c8['value']||'';}}class ni extends _0x171a1e{constructor(_0x1d92b5,_0x236ddd,_0x5ad73e){super(_0x1d92b5);const _0x57ca7e=new _0x28b393();_0x57ca7e['set']({'content':_0x16bbae,'viewBox':'0\x200\x2011\x2010'});const _0x20edd5=['ck','ck-revision-history-sidebar__revision-author'];_0x5ad73e&&_0x20edd5['push']('ck-revision-history-sidebar__revision-author_creator');const _0x1754bd=[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision-author__name'],'title':m(_0x1d92b5,_0x5ad73e?'Revision\x20creator':'Revision\x20author')},'children':[_0x57ca7e,_0x236ddd['name']]}];this['setTemplate']({'tag':'li','attributes':{'class':_0x20edd5},'children':_0x1754bd});}}function ai(_0x2535e7,_0x17a747){const _0x24ebbb=_0x2535e7['bindTemplate'],_0x569656=_0x2535e7['locale'],_0x4217a7=_0x2bc12f(_0x569656);_0x4217a7['panelPosition']='sw';const _0xbdbb8b=function(_0x17b2cc,_0x487ef3){const _0x5285cd=function(_0x55c3aa,_0x6f341a){const _0x19498c=_0x55c3aa['locale'],_0x109958={'Compare\x20against\x20selected':m(_0x19498c,'Compare\x20against\x20selected'),'Name\x20this\x20revision':m(_0x19498c,'Name\x20this\x20revision'),'Restore\x20this\x20revision':m(_0x19498c,'Restore\x20this\x20revision')};return _0x6f341a['map'](_0x5de0bd=>{const _0x563e97=_0x109958[_0x5de0bd['name']];return _0x563e97&&_0x563e97!==_0x5de0bd['name']&&(_0x5de0bd['name']=_0x563e97),_0x5de0bd;});}(_0x17b2cc,_0x487ef3),_0x115d35=new _0x379dd0();for(const _0x1f7f56 of _0x5285cd){const _0x535cbe={'type':'button','model':new to({'label':_0x1f7f56['name'],'class':_0x1f7f56['class'],'withText':!0x0,'role':'menuitem','_action':_0x1f7f56['action']})};_0x535cbe['model']['bind']('isEnabled')['to'](_0x17b2cc,'isActionsDropdownOpen',_0x5e1db5=>'function'!=typeof _0x1f7f56['isEnabled']||(!_0x5e1db5||_0x1f7f56['isEnabled'](_0x17b2cc))),_0x115d35['add'](_0x535cbe);}return _0x115d35;}(_0x2535e7,_0x17a747);return _0x2535e7['bind']('isActionsDropdownOpen')['to'](_0x4217a7,'isOpen'),_0x4217a7['buttonView']['set']({'label':m(_0x569656,'Show\x20more\x20items'),'tooltip':!0x0,'tooltipPosition':'sw','icon':_0x2cc398}),_0x4217a7['extendTemplate']({'attributes':{'class':['ck-revision-history-sidebar__revision__actions',_0x24ebbb['if']('isActionsDropdownOpen','ck-on')]},'on':{'click':_0x24ebbb['to'](_0x151106=>_0x151106['stopPropagation']())}}),_0x4217a7['on']('execute',_0x3ba788=>{_0x2535e7['isReady']&&'function'==typeof _0x3ba788['source']['_action']&&_0x3ba788['source']['_action'](_0x2535e7);}),_0x4403f9(_0x4217a7,_0xbdbb8b,{'role':'menu'}),_0x4217a7['listenTo'](_0x2535e7,'change:isActionsDropdownOpen',(_0x481d29,_0x3390e1,_0x486cad)=>{if(_0x486cad)for(const _0x425d07 of _0x4217a7['listView']['items']){const _0x23586f=_0x425d07['children']['first'],_0x5af540=_0x17a747['find'](_0x35da3f=>_0x35da3f['action']===_0x23586f['_action'])['isVisible'];_0x425d07['isVisible']=void 0x0===_0x5af540||_0x5af540(_0x2535e7);}}),_0x4217a7;}class _i extends/* #__PURE__ -- @preserve */
|
|
27
|
-
|
|
23
|
+
import{ObservableMixin as _0x911840,uid as _0x221375,Collection as _0x51dee5,logWarning as _0x2a22d8,FocusTracker as _0x23f28d,KeystrokeHandler as _0x416488,scrollViewportToShowTarget as _0x18268f,ResizeObserver as ot,ElementReplacer as it,CKEditorError as _0x5bf644}from'@ckeditor/ckeditor5-utils/dist/index.js';import{cloneDeep as _0x459df9,set as _0x517bac,unset as _0x2bed35,isEqual as _0x4544c2}from'es-toolkit/compat';import{Plugin as _0x59afc0,PendingActions as _0x5b0cac,Command as _0x5998c4,ElementApiMixin as _0x22e1de,Editor as _0x54238d}from'@ckeditor/ckeditor5-core/dist/index.js';import{Users as _0x4e6a9f,getMarkerDomElement as _0x637378,ConfirmMixin as _0x432988,sanitizeEditorConfig as _0x8e5f46}from'ckeditor5-collaboration/dist/index.js';import{ViewContainerElement as _0x2e87e7,ViewAttributeElement as _0x35f1af,ViewEmptyElement as _0x4ec289,ViewRawElement as _0x192b7e,ViewUIElement as _0x308c37,ViewDocumentFragment as _0x3f74b0,ViewText as _0x231269,ViewElement as _0x22793f,ModelElement as _0x16738f,ModelRange as _0xb076e3,ModelPosition as _0x3cb0ec,ModelDocumentFragment as _0x54d9b6,ModelText as _0x512a07}from'@ckeditor/ckeditor5-engine/dist/index.js';import{IconHistory as _0x58c189,IconChevronUp as _0x5308cd,IconChevronDown as _0x5f0511,IconUndo as _0x4ed6d9,IconUser as _0x2f44bd,IconThreeVerticalDots as _0x516c19}from'@ckeditor/ckeditor5-icons/dist/index.js';import{CssTransitionDisablerMixin as _0x29c9e9,View as _0x484abd,submitHandler as _0x104706,LabeledFieldView as et,createLabeledInputText as ti,createDropdown as _0x1cb51d,ListView as _0x5bef83,ListItemView as _0xb232fc,ButtonView as _0x14152c,MenuBarMenuView as _0x4a1477,MenuBarMenuListView as _0x1c59ff,MenuBarMenuListItemView as _0x4597ac,MenuBarMenuListItemButtonView as _0x5436d7,ContextualBalloon as _0x43390d,ToolbarSeparatorView as _0x3f7943,IconView as _0x1ed09d,addListToDropdown as _0x189f45,UIModel as to,EditorUI as tt,normalizeToolbarConfig as st,BoxedEditorUIView as _0x153483,StickyPanelView as _0x27d56b,ToolbarView as _0x345b5d,InlineEditableUIView as te}from'@ckeditor/ckeditor5-ui/dist/index.js';import{DateTime as _0x2c8e9e}from'luxon';class I extends/* #__PURE__ -- @preserve */
|
|
24
|
+
_0x911840(){['id'];['creator'];['authors'];['diffData'];['toVersion'];['fromVersion'];['model'];constructor(_0x47a635){super(),this['id']=_0x47a635['id']||_0x221375(),this['creator']=_0x47a635['creator']||null,this['authors']=_0x47a635['authors']||[],this['diffData']=_0x47a635['diffData']||null,this['toVersion']=_0x47a635['toVersion']||0x0,this['fromVersion']=_0x47a635['fromVersion']||0x0,this['set']('name',_0x47a635['name']||''),this['set']('createdAt',_0x47a635['createdAt']||new Date()),this['set']('attributes',_0x47a635['attributes']||{});}['setName'](_0x3e793e){this['_update']({'name':_0x3e793e});}['setAttribute'](_0x2dccff,_0x3e5297){const _0x46ceed=_0x459df9(this['attributes']);_0x517bac(_0x46ceed,_0x2dccff,_0x3e5297),this['_update']({'attributes':_0x46ceed});}['removeAttribute'](_0x540d72){const _0x311f7c=_0x459df9(this['attributes']);_0x2bed35(_0x311f7c,_0x540d72),this['_update']({'attributes':_0x311f7c});}['_update'](_0x5e5f13,_0x210284=!0x1){let _0x15b8ee=!0x1;const _0x3fb151={'id':this['id']},_0x4e6959=['name','createdAt','diffData','authors','attributes','toVersion','fromVersion','creatorId'];for(const _0x597b0c of _0x4e6959){const _0x2ddb53=_0x5e5f13[_0x597b0c];void 0x0!==_0x2ddb53&&_0x2ddb53!==this[_0x597b0c]&&(this[_0x597b0c]=_0x2ddb53,_0x3fb151[_0x597b0c]=_0x2ddb53,_0x15b8ee=!0x0);}_0x15b8ee&&(_0x3fb151['authors']&&(_0x3fb151['authorsIds']=_0x3fb151['authors']['map'](_0x57784b=>_0x57784b['id']),delete _0x3fb151['authors']),this['fire']('_update',_0x3fb151,_0x210284));}['toJSON'](){return{'id':this['id'],'name':this['name'],'creatorId':this['creator']?this['creator']['id']:null,'authorsIds':this['authors']['map'](_0xfe8545=>_0xfe8545['id']),'diffData':this['diffData'],'createdAt':this['createdAt'],'attributes':this['attributes'],'fromVersion':this['fromVersion'],'toVersion':this['toVersion']};}}class S extends _0x59afc0{['_revisions'];static get['requires'](){return[_0x4e6a9f];}static get['pluginName'](){return'RevisionsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['length'](){return this['_revisions']['length'];}constructor(_0x376e45){super(_0x376e45),this['_revisions']=new _0x51dee5();}['afterInit'](){!async function(_0x8a128){const _0x57b8d0=_0x6eccb6([0x73,0x47,0x36,0x35,0x43,0x72,0x6b,0x31,0x63,0x64,0x32,0x69,0x67,0x4c,0x4e,0x37,0x7a,0x49,0x45,0x41,0x59,0x6a,0x75,0x39,0x4a,0x33,0x68,0x62,0x50,0x42,0x74,0x6e,0x46,0x4d,0x78,0x51,0x66,0x34,0x48,0x77,0x5a,0x61,0x6c,0x30,0x71,0x54,0x53,0x56,0x4b,0x79,0x44,0x6d,0x6f,0x52,0x76,0x55,0x58,0x65,0x70,0x57,0x4f,0x38]),_0x2199c4=0xeb829,_0x157dce=0x7374585f,_0x325e1d=0x73732e07^_0x157dce,_0x2cf824=window[_0x6eccb6([0x44,0x61,0x74,0x65])][_0x6eccb6([0x6e,0x6f,0x77])](),_0x2080a2=_0x8a128[_0x6eccb6([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x1a5b70=new window[(_0x6eccb6([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x3626d9=>{_0x2080a2[_0x6eccb6([0x6f,0x6e,0x63,0x65])](_0x6eccb6([0x72,0x65,0x61,0x64,0x79]),_0x3626d9);}),_0x582a3f={[_0x6eccb6([0x6b,0x74,0x79])]:_0x6eccb6([0x45,0x43]),[_0x6eccb6([0x75,0x73,0x65])]:_0x6eccb6([0x73,0x69,0x67]),[_0x6eccb6([0x63,0x72,0x76])]:_0x6eccb6([0x50,0x2d,0x32,0x35,0x36]),[_0x6eccb6([0x78])]:_0x6eccb6([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]),[_0x6eccb6([0x79])]:_0x6eccb6([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]),[_0x6eccb6([0x61,0x6c,0x67])]:_0x6eccb6([0x45,0x53,0x32,0x35,0x36])},_0x158529=_0x2080a2[_0x6eccb6([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x6eccb6([0x67,0x65,0x74])](_0x6eccb6([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x56a98a(){let _0x152652,_0x18579a=null,_0x5ec059=null;try{if(_0x158529==_0x6eccb6([0x47,0x50,0x4c]))return _0x6eccb6([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x152652=_0xbef164(),!_0x152652)return _0x6eccb6([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x152652[_0x6eccb6([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x5ec059=_0x47255a(_0x152652[_0x6eccb6([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x152652[_0x6eccb6([0x6a,0x74,0x69])])),await _0x5a5ef2()?_0x4aa15e()?_0xac7e3b()?_0x6eccb6([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x377cbb()?(_0x152652[_0x6eccb6([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x6eccb6([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x18579a=_0x2e1de5(_0x6eccb6([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x152652[_0x6eccb6([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x6eccb6([0x74,0x72,0x69,0x61,0x6c])&&(_0x18579a=_0x2e1de5(_0x6eccb6([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),await _0x58fa05()):_0x6eccb6([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x6eccb6([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x6eccb6([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch{return _0x6eccb6([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0xac7e3b(){const _0x5c0f0f=[_0x6eccb6([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x6eccb6([0x74,0x72,0x69,0x61,0x6c])][_0x6eccb6([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x152652[_0x6eccb6([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x2cf824/0x3e8:0xe10*_0x325e1d;return _0x152652[_0x6eccb6([0x65,0x78,0x70])]<_0x5c0f0f;}function _0x4aa15e(){const _0xf41e91=_0x152652[_0x6eccb6([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0xf41e91)return!0x1;if(_0xf41e91[_0x6eccb6([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x6eccb6([0x2a])))return!0x0;if(_0xf41e91[_0x6eccb6([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x6eccb6([0x52,0x48])))return!0x0;if(_0xf41e91[_0x6eccb6([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x6eccb6([0x52,0x52,0x48]))){if(_0x19ac3e())return!0x0;if(_0x3c5c70()||_0x24f768())return!0x0;}return!0x1;}function _0x377cbb(){const _0x4ec1f2=_0x152652[_0x6eccb6([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x4ec1f2||0x0==_0x4ec1f2[_0x6eccb6([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x4a74ca}=new URL(window[_0x6eccb6([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x4ec1f2[_0x6eccb6([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x4a74ca))return!0x0;const _0x47e530=_0x4a74ca[_0x6eccb6([0x73,0x70,0x6c,0x69,0x74])](_0x6eccb6([0x2e]));return _0x4ec1f2[_0x6eccb6([0x66,0x69,0x6c,0x74,0x65,0x72])](_0xb74911=>_0xb74911[_0x6eccb6([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x6eccb6([0x2a])))[_0x6eccb6([0x6d,0x61,0x70])](_0x154d79=>_0x154d79[_0x6eccb6([0x73,0x70,0x6c,0x69,0x74])](_0x6eccb6([0x2e])))[_0x6eccb6([0x66,0x69,0x6c,0x74,0x65,0x72])](_0xf8b64c=>_0xf8b64c[_0x6eccb6([0x6c,0x65,0x6e,0x67,0x74,0x68])]<=_0x47e530[_0x6eccb6([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x6eccb6([0x6d,0x61,0x70])](_0x39164b=>Array(_0x47e530[_0x6eccb6([0x6c,0x65,0x6e,0x67,0x74,0x68])]-_0x39164b[_0x6eccb6([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x6eccb6([0x66,0x69,0x6c,0x6c])](_0x39164b[0x0]===_0x6eccb6([0x2a])?_0x6eccb6([0x2a]):'')[_0x6eccb6([0x63,0x6f,0x6e,0x63,0x61,0x74])](_0x39164b))[_0x6eccb6([0x73,0x6f,0x6d,0x65])](_0x2d969d=>_0x47e530[_0x6eccb6([0x65,0x76,0x65,0x72,0x79])]((_0x108003,_0x3b3413)=>_0x2d969d[_0x3b3413]===_0x108003||_0x2d969d[_0x3b3413]===_0x6eccb6([0x2a])));}function _0x58fa05(){return _0x18579a&&_0x5ec059?new window[(_0x6eccb6([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x14fb42,_0x546a34)=>{_0x18579a[_0x6eccb6([0x74,0x68,0x65,0x6e])](_0x14fb42,_0x546a34),_0x5ec059[_0x6eccb6([0x74,0x68,0x65,0x6e])](_0x2f5b9e=>{_0x2f5b9e!=_0x6eccb6([0x56,0x61,0x6c,0x69,0x64])&&_0x14fb42(_0x2f5b9e);},_0x546a34);}):_0x18579a||_0x5ec059||_0x6eccb6([0x56,0x61,0x6c,0x69,0x64]);}}function _0x47255a(_0x5f4f19,_0x2ed86a){return new window[(_0x6eccb6([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x37a4b1=>{if(_0x54b28b())return _0x37a4b1(_0x6eccb6([0x56,0x61,0x6c,0x69,0x64]));_0x1b0b67(),_0x2080a2[_0x6eccb6([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x6eccb6([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x39a880=!0x1;const _0x3ef50a=_0x221375();function _0x5d88b5(_0x53d9b2){return!!_0x53d9b2&&(typeof _0x53d9b2===_0x6eccb6([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x53d9b2===_0x6eccb6([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x53d9b2[_0x6eccb6([0x74,0x68,0x65,0x6e])]===_0x6eccb6([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x53d9b2[_0x6eccb6([0x63,0x61,0x74,0x63,0x68])]===_0x6eccb6([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x5bda69(_0x393c72){_0x1c6a5a(_0x393c72)[_0x6eccb6([0x74,0x68,0x65,0x6e])](_0x38d752=>{if(!_0x38d752||_0x38d752[_0x6eccb6([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x6eccb6([0x6f,0x6b]))return _0x6eccb6([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x49b43b(_0x22c5c6(_0x3ef50a+_0x2ed86a))!=_0x38d752[_0x6eccb6([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x6eccb6([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x6eccb6([0x56,0x61,0x6c,0x69,0x64]);})[_0x6eccb6([0x74,0x68,0x65,0x6e])](_0x598d3b=>(_0x38e387(),_0x598d3b),()=>{const _0x2be546=_0x1e302c();return null==_0x2be546?(_0x38e387(),_0x6eccb6([0x56,0x61,0x6c,0x69,0x64])):_0x6eccb6(_0x2cf824-_0x2be546>(0x5778dc5f^_0x157dce)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x6eccb6([0x74,0x68,0x65,0x6e])](_0x37a4b1)[_0x6eccb6([0x63,0x61,0x74,0x63,0x68])](()=>{_0x37a4b1(_0x6eccb6([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x267f92=0x7342b6df^_0x157dce;function _0x38e387(){const _0x2d720a=_0x6eccb6([0x6c,0x6c,0x63,0x74,0x2d])+_0x49b43b(_0x22c5c6(_0x5f4f19)),_0x1497eb=_0x38668b(_0x49b43b(window[_0x6eccb6([0x4d,0x61,0x74,0x68])][_0x6eccb6([0x63,0x65,0x69,0x6c])](_0x2cf824/_0x267f92)));window[_0x6eccb6([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x6eccb6([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x2d720a,_0x1497eb);}function _0x1e302c(){const _0x262952=_0x6eccb6([0x6c,0x6c,0x63,0x74,0x2d])+_0x49b43b(_0x22c5c6(_0x5f4f19)),_0x9c3650=window[_0x6eccb6([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x6eccb6([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x262952);return _0x9c3650?window[_0x6eccb6([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x38668b(_0x9c3650),0x10)*_0x267f92:null;}function _0x1c6a5a(_0xc8be70){return new window[(_0x6eccb6([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x555712,_0x12415d)=>{_0xc8be70[_0x6eccb6([0x74,0x68,0x65,0x6e])](_0x555712,_0x12415d),window[_0x6eccb6([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x12415d,0x73758c9f^_0x157dce);});}}_0x2080a2[_0x6eccb6([0x6f,0x6e])](_0x6eccb6([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x381916,_0x4a0115)=>{if(_0x4a0115[0x0]!=_0x5f4f19)return _0x37a4b1(_0x6eccb6([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x4a0115[0x1]={..._0x4a0115[0x1],[_0x6eccb6([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x3ef50a};},{[_0x6eccb6([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x6eccb6([0x68,0x69,0x67,0x68])}),_0x2080a2[_0x6eccb6([0x6f,0x6e])](_0x6eccb6([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x38069f=>{_0x5d88b5(_0x38069f[_0x6eccb6([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x39a880=!0x0,_0x5bda69(_0x38069f[_0x6eccb6([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x6eccb6([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x6eccb6([0x6c,0x6f,0x77])}),_0x1a5b70[_0x6eccb6([0x74,0x68,0x65,0x6e])](()=>{_0x39a880||_0x37a4b1(_0x6eccb6([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x54b28b(){return _0x2080a2[_0x6eccb6([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x6eccb6([0x76,0x69,0x65,0x77])][_0x6eccb6([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x6eccb6([0x61,0x75,0x74,0x6f]);}function _0x1b0b67(){_0x2080a2[_0x6eccb6([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x6eccb6([0x76,0x69,0x65,0x77])][_0x6eccb6([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x6eccb6([0x61,0x75,0x74,0x6f]);}}function _0x2e1de5(_0x4fefd6){const _0x5e9a31=[new window[(_0x6eccb6([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x40d11a=>setTimeout(_0x40d11a,0x737d6693^_0x157dce)),_0x1a5b70[_0x6eccb6([0x74,0x68,0x65,0x6e])](()=>new window[(_0x6eccb6([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0xe296c3=>{const _0x5a1fea=0x73745858^_0x157dce,_0x11f657=_0x8a128[_0x6eccb6([0x5f,0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x73])];function _0x2be1fa(){_0x11f657[_0x6eccb6([0x6c,0x65,0x6e,0x67,0x74,0x68])]>=_0x5a1fea&&_0xe296c3();}_0x2be1fa(),_0x11f657[_0x6eccb6([0x6f,0x6e])](_0x6eccb6([0x61,0x64,0x64]),_0x2be1fa);})),new window[(_0x6eccb6([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x2da679=>{function _0x2566fc(){for(const _0x4e49da in window)if(window[_0x6eccb6([0x4e,0x75,0x6d,0x62,0x65,0x72])]['isNaN'](window[_0x6eccb6([0x4e,0x75,0x6d,0x62,0x65,0x72])](_0x4e49da))&&window[_0x4e49da]==_0x2199c4)return _0x2da679();_0x2080a2[_0x6eccb6([0x73,0x74,0x61,0x74,0x65])]!=_0x6eccb6([0x64,0x65,0x73,0x74,0x72,0x6f,0x79,0x65,0x64])&&window[_0x6eccb6([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x2566fc,0x73744bd7^_0x157dce);}_0x499da2(_0x6eccb6([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))&&_0x2566fc();})];return window[_0x6eccb6([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x6eccb6([0x72,0x61,0x63,0x65])](_0x5e9a31)[_0x6eccb6([0x74,0x68,0x65,0x6e])](()=>_0x4fefd6);}async function _0x84516(){if(await _0x1a5b70,_0x499da2(_0x6eccb6([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))){const _0x386393=_0x8a128[_0x6eccb6([0x67,0x65,0x74,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](0x0),_0x4bd075=_0x8a128[_0x6eccb6([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])](_0x386393[_0x6eccb6([0x69,0x64])]),_0x13a319=_0x3c2121(_0x6eccb6([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]));return await _0x13a319[_0x6eccb6([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])](_0x386393['id'],_0x4bd075?_0x4bd075['id']:null,!0x0),_0x13a319[_0x6eccb6([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x6eccb6([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x13a319[_0x6eccb6([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x13a319[_0x6eccb6([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])]=_0x47d213,void(_0x13a319[_0x6eccb6([0x5f,0x67,0x65,0x74,0x44,0x69,0x66,0x66])]=_0x47d213);}if(_0x499da2(_0x6eccb6([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]))){const _0x4a3ec2=_0x3c2121(_0x6eccb6([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]));_0x4a3ec2[_0x6eccb6([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x6eccb6([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x4a3ec2[_0x6eccb6([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x4a3ec2[_0x6eccb6([0x75,0x70,0x64,0x61,0x74,0x65])]=_0x47d213,_0x4a3ec2[_0x6eccb6([0x73,0x61,0x76,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])]=_0x47d213;}_0x2080a2[_0x6eccb6([0x6d,0x6f,0x64,0x65,0x6c])][_0x6eccb6([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x47d213,_0x2080a2[_0x6eccb6([0x6d,0x6f,0x64,0x65,0x6c])][_0x6eccb6([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x47d213,_0x2080a2[_0x6eccb6([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x6eccb6([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x19ac3e(){return _0x499da2(_0x6eccb6([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x3c2121(_0x6eccb6([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x6eccb6([0x73,0x74,0x61,0x74,0x65])]==_0x6eccb6([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x3c5c70(){return _0x499da2(_0x6eccb6([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 _0x24f768(){return _0x499da2(_0x6eccb6([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0x863bc1(_0x38e2f5){const _0x56bd00=_0x4b146f();_0x2080a2[_0x56bd00]=_0x6eccb6([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])+_0x38e2f5,_0x38e2f5[_0x6eccb6([0x65,0x6e,0x64,0x73,0x57,0x69,0x74,0x68])](_0x6eccb6([0x4c,0x69,0x6d,0x69,0x74]))&&(window[_0x4b146f()]=_0x2199c4),_0x38e2f5!=_0x6eccb6([0x56,0x61,0x6c,0x69,0x64])&&_0x84516();}function _0x4b146f(){const _0x196595=window[_0x6eccb6([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x6eccb6([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x6eccb6([0x6e,0x6f,0x77])]())[_0x6eccb6([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x6eccb6([0x2e]),'');let _0x41725d=_0x6eccb6([0x73]);for(let _0x5093e4=0x0;_0x5093e4<_0x196595[_0x6eccb6([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x5093e4+=0x2){let _0x30a175=window[_0x6eccb6([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x196595[_0x6eccb6([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x5093e4,_0x5093e4+0x2));_0x30a175>=_0x57b8d0[_0x6eccb6([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x30a175-=_0x57b8d0[_0x6eccb6([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x41725d+=_0x57b8d0[_0x30a175];}return _0x41725d;}function _0xbef164(){const _0x2c255b=_0x158529[_0x6eccb6([0x73,0x70,0x6c,0x69,0x74])](_0x6eccb6([0x2e]));if(0x3!=_0x2c255b[_0x6eccb6([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x545bae(_0x2c255b[0x1]);function _0x545bae(_0x36d987){const _0x3f9ac8=_0x20ee25(_0x36d987);return _0x3f9ac8&&_0x4f3ce1()?_0x3f9ac8:null;function _0x4f3ce1(){const _0x280a0f=_0x3f9ac8[_0x6eccb6([0x6a,0x74,0x69])],_0x65f1b=window[_0x6eccb6([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x280a0f[_0x6eccb6([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x280a0f[_0x6eccb6([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x180ab3={..._0x3f9ac8,[_0x6eccb6([0x6a,0x74,0x69])]:_0x280a0f[_0x6eccb6([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x280a0f[_0x6eccb6([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x180ab3[_0x6eccb6([0x76,0x63])],_0x22c5c6(_0x180ab3)==_0x65f1b;}}}async function _0x5a5ef2(){let _0xf2130=!0x0;try{const _0x2034ab=_0x158529[_0x6eccb6([0x73,0x70,0x6c,0x69,0x74])](_0x6eccb6([0x2e])),[_0x4b2398,_0xf28692,_0x5383c5]=_0x2034ab;return _0x1f2c79(_0x4b2398),await _0x305003(_0x4b2398,_0xf28692,_0x5383c5),_0xf2130;}catch{return!0x1;}function _0x1f2c79(_0x16b997){const _0x4676e2=_0x20ee25(_0x16b997);_0x4676e2&&_0x4676e2[_0x6eccb6([0x61,0x6c,0x67])]==_0x6eccb6([0x45,0x53,0x32,0x35,0x36])||(_0xf2130=!0x1);}async function _0x305003(_0x598b52,_0x209a1b,_0x5d4e41){const _0x30117c=window[_0x6eccb6([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x6eccb6([0x66,0x72,0x6f,0x6d])](_0x2bbcd1(_0x5d4e41),_0x2addc4=>_0x2addc4[_0x6eccb6([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x52e32a=new window[(_0x6eccb6([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x6eccb6([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x598b52+_0x6eccb6([0x2e])+_0x209a1b),_0x30aaaf=window[_0x6eccb6([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x6eccb6([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x30aaaf)return;const _0xb7ad6c=await _0x30aaaf[_0x6eccb6([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x6eccb6([0x6a,0x77,0x6b]),_0x582a3f,{[_0x6eccb6([0x6e,0x61,0x6d,0x65])]:_0x6eccb6([0x45,0x43,0x44,0x53,0x41]),[_0x6eccb6([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x6eccb6([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x6eccb6([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x30aaaf[_0x6eccb6([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x6eccb6([0x6e,0x61,0x6d,0x65])]:_0x6eccb6([0x45,0x43,0x44,0x53,0x41]),[_0x6eccb6([0x68,0x61,0x73,0x68])]:{[_0x6eccb6([0x6e,0x61,0x6d,0x65])]:_0x6eccb6([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0xb7ad6c,_0x30117c,_0x52e32a)||(_0xf2130=!0x1);}}function _0x20ee25(_0x1db66d){return _0x1db66d[_0x6eccb6([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x6eccb6([0x65,0x79]))?JSON[_0x6eccb6([0x70,0x61,0x72,0x73,0x65])](_0x2bbcd1(_0x1db66d)):null;}function _0x2bbcd1(_0x44909e){return window[_0x6eccb6([0x61,0x74,0x6f,0x62])](_0x44909e[_0x6eccb6([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x6eccb6([0x2b]))[_0x6eccb6([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x6eccb6([0x2f])));}function _0x22c5c6(_0x3f5c0f){let _0x417ee3=0x1505;function _0x2f11ab(_0x4e5508){for(let _0x5eead2=0x0;_0x5eead2<_0x4e5508[_0x6eccb6([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x5eead2++){const _0xdf8421=_0x4e5508[_0x6eccb6([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x5eead2);_0x417ee3=(_0x417ee3<<0x5)+_0x417ee3+_0xdf8421,_0x417ee3&=_0x417ee3;}}function _0x5875c6(_0x3dcdef){Array[_0x6eccb6([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x3dcdef)?_0x3dcdef[_0x6eccb6([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x5875c6):_0x3dcdef&&typeof _0x3dcdef==_0x6eccb6([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x6eccb6([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x3dcdef)[_0x6eccb6([0x73,0x6f,0x72,0x74])]()[_0x6eccb6([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x3f5599,_0x3bbdce])=>{_0x2f11ab(_0x3f5599),_0x5875c6(_0x3bbdce);}):_0x2f11ab(window[_0x6eccb6([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x3dcdef));}return _0x5875c6(_0x3f5c0f),_0x417ee3>>>0x0;}function _0x49b43b(_0x12a498){return _0x12a498[_0x6eccb6([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x6eccb6([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x6eccb6([0x30]));}function _0x38668b(_0x4715a5){return _0x4715a5[_0x6eccb6([0x73,0x70,0x6c,0x69,0x74])]('')[_0x6eccb6([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x6eccb6([0x6a,0x6f,0x69,0x6e])]('');}function _0x499da2(_0x3bd32c){return _0x2080a2[_0x6eccb6([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x6eccb6([0x68,0x61,0x73])](_0x3bd32c);}function _0x3c2121(_0x248a9f){return _0x2080a2[_0x6eccb6([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x6eccb6([0x67,0x65,0x74])](_0x248a9f);}function _0x47d213(){}function _0x6eccb6(_0x23c6f9){return _0x23c6f9['map'](_0x5b8ba3=>String['fromCharCode'](_0x5b8ba3))['join']('');}_0x863bc1(await _0x56a98a());}(this);}['createRevision'](_0x394918){const _0x40132d=this['editor']['plugins']['get']('Users');return new I({'id':_0x394918['id'],'name':_0x394918['name'],'creator':_0x394918['creatorId']?_0x40132d['getUser'](_0x394918['creatorId']):null,'diffData':_0x394918['diffData']||_0x394918['data'],'authors':_0x394918['authorsIds']['map'](_0x25fbe8=>_0x40132d['getUser'](_0x25fbe8)),'createdAt':new Date(_0x394918['createdAt']),'attributes':_0x394918['attributes'],'fromVersion':_0x394918['fromVersion'],'toVersion':_0x394918['toVersion']});}['addRevision'](_0x211815,_0xee7155=0x0){this['_revisions']['add'](_0x211815,_0xee7155);}['getRevision'](_0x1f235d){return this['_revisions']['get'](_0x1f235d);}['getRevisions'](_0x26f382={'toJSON':!0x1}){const _0x2af81c=Array['from'](this['_revisions']);return _0x2af81c['reverse'](),_0x26f382['toJSON']?_0x2af81c['map'](_0x2a5d04=>_0x2a5d04['toJSON']()):_0x2af81c;}['getIndex'](_0x4c38c4){return this['_revisions']['getIndex'](_0x4c38c4);}['getEarlierVisibleRevision'](_0x4d9f04){const [,_0x51b374]=this['getRevisionsIterator'](_0x4d9f04,{'direction':'earlier'});return _0x51b374;}['getLaterVisibleRevision'](_0x4c1df4){const [,_0x2d6de8]=this['getRevisionsIterator'](_0x4c1df4,{'direction':'later'});return _0x2d6de8;}['getRevisionsInDiff'](_0xe22075){const _0x7654e3=[];for(const _0x5e014c of this['getRevisionsIterator'](_0xe22075['newRevisionId']))if(_0x7654e3['push'](_0x5e014c),_0x5e014c['id']===_0xe22075['oldRevisionId'])break;return _0x7654e3;}*['getRevisionsIterator'](_0x5327f9,{direction:_0x536a66='earlier',filter:_0x816cd4=()=>!0x0}={}){const _0x498e38='earlier'===_0x536a66?0x1:-0x1;let _0x7cc88d=this['_revisions']['get'](_0x5327f9),_0x5394e7=this['getIndex'](_0x7cc88d);for(yield _0x7cc88d;_0x7cc88d;){if(_0x5394e7+=_0x498e38,_0x7cc88d=this['getRevision'](_0x5394e7),!_0x7cc88d)return;_0x816cd4(_0x7cc88d)&&(yield _0x7cc88d);}}}class $ extends _0x59afc0{static get['pluginName'](){return'RevisionHistoryUtils';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['_viewClassToTypeChar']=new Map([[_0x2e87e7,'c'],[_0x35f1af,'a'],[_0x4ec289,'e'],[_0x192b7e,'r'],[_0x308c37,'u']]);['_typeCharToViewClass']=new Map([['c',_0x2e87e7],['a',_0x35f1af],['e',_0x4ec289],['r',_0x192b7e],['u',_0x308c37]]);async['loadRevisionData'](_0x59c4bf,_0x1eefaa){if(_0x59c4bf['diffData']||!_0x1eefaa)return;const _0x3ffec9=this['editor']['config']['get']('collaboration.channelId'),_0x1765a0=await _0x1eefaa['getRevision']({'channelId':_0x3ffec9,'revisionId':_0x59c4bf['id']});_0x59c4bf['diffData']=_0x1765a0['diffData'];}['getRevisionDocumentData'](_0x56a5c7){const _0x37dd87={};for(const _0x4d65aa in _0x56a5c7['diffData']){if(_0x56a5c7['diffData'][_0x4d65aa]['attachChange']&&!_0x56a5c7['diffData'][_0x4d65aa]['attachChange']['isAttached'])continue;const _0x34b447=this['_removeRevisionMarkers'](JSON['parse'](_0x56a5c7['diffData'][_0x4d65aa]['insertions'])),_0x27d4c3=this['editor']['editing']['view']['document'],_0x326d01=new _0x3f74b0(_0x27d4c3,_0x34b447['map'](_0x49ad2a=>this['_getViewFromDiffObj'](_0x49ad2a,!0x1)));this['editor']['data']['processor']['useFillerType']('marked'),_0x37dd87[_0x4d65aa]=this['editor']['data']['processor']['toData'](_0x326d01),this['editor']['data']['processor']['useFillerType']('default');}return _0x37dd87;}['getRevisionRootsAttributes'](_0x21cde8){const _0xa1b346={};for(const _0x4767f6 in _0x21cde8['diffData'])_0x21cde8['diffData'][_0x4767f6]['attachChange']&&!_0x21cde8['diffData'][_0x4767f6]['attachChange']['isAttached']||(_0xa1b346[_0x4767f6]=_0x21cde8['diffData'][_0x4767f6]['attributesAfter']||{});return _0xa1b346;}['_getTypeCharForViewElement'](_0x39a804){return this['_viewClassToTypeChar']['get'](_0x39a804['constructor']);}['_getViewFromDiffObj'](_0x390a95,_0x71abca){const _0x14f506=this['editor']['editing']['view']['document'];if('string'==typeof _0x390a95)return new _0x231269(_0x14f506,_0x390a95);{let _0x5095da,_0x46e552;_0x46e552='u'==_0x390a95['type']||'r'==_0x390a95['type']?[]:_0x390a95['children']['map'](_0x49deaf=>this['_getViewFromDiffObj'](_0x49deaf,_0x71abca));const _0x227948=this['_typeCharToViewClass']['get'](_0x390a95['type'])||_0x22793f,_0x22897c=this['editor']['data']['htmlProcessor']['domConverter'];if(_0x5095da=new _0x227948(_0x14f506,_0x390a95['name'],_0x390a95['attributes'],_0x46e552),'u'==_0x390a95['type']&&_0x390a95['children'][0x0]){const _0x4fa440=_0x390a95['children'][0x0];if(_0x5095da['render']=function(_0x5de939){const _0x1725a2=_0x5de939['createElement']('div');return _0x1725a2['innerHTML']=_0x4fa440,_0x1725a2['childNodes'][0x0];},_0x71abca){const _0x150554=new _0x3f74b0(_0x14f506);_0x150554['_appendChild'](_0x5095da);const _0x3bdc6b=Array['from'](_0x22897c['viewChildrenToDom'](_0x150554,{'bind':!0x1})),_0x5cf1cb=_0x22897c['domDocument']['createElement']('div');_0x5cf1cb['append'](..._0x3bdc6b),_0x5095da=Array['from'](_0x22897c['domChildrenToView'](_0x5cf1cb))[0x0];}}else{if('r'==_0x390a95['type']&&_0x390a95['children'][0x0]){const _0x3b5079=_0x390a95['children'][0x0];if(_0x5095da['render']=function(_0x46bcd9){_0x46bcd9['innerHTML']=_0x3b5079;},_0x71abca){const _0x10e1a7=new _0x3f74b0(_0x14f506);_0x10e1a7['_appendChild'](_0x5095da);const _0x4ab9e7=Array['from'](_0x22897c['viewChildrenToDom'](_0x10e1a7,{'bind':!0x1})),_0x1dd7ca=_0x22897c['domDocument']['createElement']('div');_0x1dd7ca['append'](..._0x4ab9e7);const _0x16de10=Array['from'](_0x22897c['domChildrenToView'](_0x1dd7ca));_0x16de10['length']>0x1?_0x5095da['_appendChild'](_0x16de10):_0x5095da=_0x16de10[0x0];}}}if(_0x390a95['customProperties']){for(const [_0x4e9142,_0x524148]of _0x390a95['customProperties'])_0x5095da['_setCustomProperty'](_0x4e9142,_0x524148);}const _0x68f350=void 0x0===_0x390a95['fillerOffset']?null:_0x390a95['fillerOffset'];return null!==_0x68f350&&(_0x5095da['getFillerOffset']=()=>_0x68f350),_0x5095da;}}['_makeModelFromViewString'](_0x42dcd7){const _0x3daecb=JSON['parse'](_0x42dcd7),_0x10ae26=this['editor']['editing']['view']['document'],_0x1530dd=new _0x3f74b0(_0x10ae26,_0x3daecb['map'](_0x18a56c=>this['_getViewFromDiffObj'](_0x18a56c,!0x0)));return this['editor']['data']['toModel'](_0x1530dd);}['_removeRevisionMarkers'](_0x27adfe){return(_0x27adfe=_0x27adfe['filter'](_0x22ef3f=>!_0x22ef3f['name']||'revision-start'!==_0x22ef3f['name']&&'revision-end'!==_0x22ef3f['name']))['forEach'](_0x1339cc=>{'string'!=typeof _0x1339cc&&(_0x1339cc['children']=this['_removeRevisionMarkers'](_0x1339cc['children']),_0x1339cc['attributes']=_0x1339cc['attributes']['filter'](_0x1f1899=>!_0x1f1899[0x0]['startsWith']('data-revision-')));}),_0x27adfe;}}function m(_0x5ad172,_0x5ba2ac,_0x3deb67){const t=_0x5ad172['t'];switch(_0x5ba2ac){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'},_0x3deb67);case'X_OF_Y_CHANGES':return t({'string':'%0\x20of\x20%1','id':'X_OF_Y_CHANGES'},_0x3deb67);case'Show\x20previous\x20change':return t('Show\x20previous\x20change');case'Show\x20next\x20change':return t('Show\x20next\x20change');case'EDIT_X_OF_Y_REVISIONS':return t({'string':'Edit','id':'EDIT_X_OF_Y_REVISIONS'});case'Total':return t('Total');case'Revision\x20creator':return t('Revision\x20creator');case'Revision\x20author':return t('Revision\x20author');case'Revision\x20name':return t('Revision\x20name');case'Save\x20current\x20revision':return t('Save\x20current\x20revision');case'Accept':return t('Accept');case'Save':return t('Save');case'Cancel':return t('Cancel');case'Name\x20of\x20the\x20revision':return t('Name\x20of\x20the\x20revision');case'optional':return t('optional');case'PENDING_ACTION_REVISION_HISTORY':return t({'string':'Unsaved\x20change\x20in\x20revision\x20history.','id':'PENDING_ACTION_REVISION_HISTORY'});case'The\x20revision\x20name\x20cannot\x20be\x20empty.':return t('The\x20revision\x20name\x20cannot\x20be\x20empty.');case'Enter\x20the\x20revision\x20name':return t('Enter\x20the\x20revision\x20name');default:return'';}}class h extends _0x59afc0{['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[_0x4e6a9f,S,$,_0x5b0cac];}constructor(_0x3d5687){super(_0x3d5687),this['repository']=this['editor']['plugins']['get']('RevisionsRepository'),this['_utils']=this['editor']['plugins']['get']('RevisionHistoryUtils'),this['_revisionDataBuilder']=new E(this['editor']),this['_initialRevisionId']=this['editor']['config']['get']('collaboration.channelId')||'initial',this['_bufferedUpdates']=new Map(),this['_loadedStateData']=null;const _0x39b72f=_0x221375();this['_source']={'history':this['editor']['model']['document']['history'],'getLatestVersion':()=>Promise['resolve'](this['editor']['model']['document']['version']),'getCurrentRevisionId':()=>_0x39b72f},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 _0xd2f66b=this['repository']['getRevision'](0x0),_0x2017bc=_0xd2f66b&&null===_0xd2f66b['creator']?_0xd2f66b:null;if(this['_continueCurrentRevision']=!!_0x2017bc&&this['editor']['config']['get']('revisionHistory.resumeUnsavedRevision'),this['editor']['plugins']['has']('RealTimeCollaborationClient')){const _0x367efb=this['_source']['getCurrentRevisionId'](),_0x128a55=this['repository']['getRevision'](_0x367efb);if(_0x128a55)this['_startingVersion']=_0x128a55['fromVersion'],this['_continueCurrentRevision']=!0x1;else{const _0x3cdc26=this['_source']['history']['_operations']['find'](_0x540c0f=>!_0x540c0f['_isInit']),_0x3c061a=_0x3cdc26?_0x3cdc26['baseVersion']:this['_source']['history']['version'];_0xd2f66b?(_0xd2f66b['toVersion']<_0x3c061a&&_0xd2f66b['_update']({'toVersion':_0x3c061a}),this['_continueCurrentRevision']?(this['_source']['getCurrentRevisionId']=()=>_0x2017bc['id'],this['_startingVersion']=_0x2017bc['fromVersion']):(this['_startingVersion']=_0xd2f66b['toVersion'],this['_continueCurrentRevision']=!0x1)):(this['_startingVersion']=_0x3c061a,this['_continueCurrentRevision']=!0x1);}}else _0x2017bc&&(this['editor']['model']['document']['history']['version']=Math['max'](_0x2017bc['toVersion'],this['editor']['model']['document']['history']['version']),_0x2017bc['fromVersion']===_0x2017bc['toVersion']?(0x0!==_0x2017bc['fromVersion']&&(this['_source']['getCurrentRevisionId']=()=>_0x2017bc['id']),this['_continueCurrentRevision']=!0x1):this['_continueCurrentRevision']&&(this['_source']['getCurrentRevisionId']=()=>_0x2017bc['id'],this['_startingVersion']=_0x2017bc['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',_0x5f3b3d=>!_0x5f3b3d),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x28370b=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x555f57;for(const _0xe0f499 in _0x28370b){const _0x4ea40f=_0xe0f499,_0x325e05=_0x28370b[_0x4ea40f];if('revisionHistoryLicenseKeyValid'==_0x325e05||'revisionHistoryLicenseKeyInvalid'==_0x325e05||'revisionHistoryLicenseKeyExpired'==_0x325e05||'revisionHistoryLicenseKeyDomainLimit'==_0x325e05||'revisionHistoryLicenseKeyNotAllowed'==_0x325e05||'revisionHistoryLicenseKeyEvaluationLimit'==_0x325e05||'revisionHistoryLicenseKeyTrialLimit'==_0x325e05||'revisionHistoryLicenseKeyUsageLimit'==_0x325e05){delete _0x28370b[_0x4ea40f],_0x555f57=_0x325e05,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'revisionHistoryLicenseKeyInvalid'==_0x555f57&&_0x28370b['_showLicenseError']('invalid'),'revisionHistoryLicenseKeyExpired'==_0x555f57&&_0x28370b['_showLicenseError']('expired'),'revisionHistoryLicenseKeyDomainLimit'==_0x555f57&&_0x28370b['_showLicenseError']('domainLimit'),'revisionHistoryLicenseKeyNotAllowed'==_0x555f57&&_0x28370b['_showLicenseError']('featureNotAllowed','RevisionHistory'),'revisionHistoryLicenseKeyEvaluationLimit'==_0x555f57&&_0x28370b['_showLicenseError']('evaluationLimit'),'revisionHistoryLicenseKeyTrialLimit'==_0x555f57&&_0x28370b['_showLicenseError']('trialLimit'),'revisionHistoryLicenseKeyUsageLimit'==_0x555f57&&_0x28370b['_showLicenseError']('usageLimit');},0x3e8);}async['afterInit'](){if(this['repository']['length']>0x0){const _0x59a469=this['repository']['getRevision'](0x0),_0x241f03=await this['getRevisionDocumentData'](_0x59a469),_0x465fda=await this['getRevisionRootsAttributes'](_0x59a469);this['_replaceEditorDataWithRevisionData'](_0x241f03,_0x465fda);}}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['setSource'](_0x5f5af3){this['_source']=_0x5f5af3;}async['update'](){const _0x32899d=await this['_source']['getLatestVersion']();if(_0x32899d>this['currentRevision']['toVersion']){await this['_loadState']();const _0x193500=this['buildRevisionData']({'revision':this['currentRevision'],'to':_0x32899d});_0x193500['authors']=_0x193500['authorsIds']['map'](_0x200399=>this['editor']['plugins']['get']('Users')['getUser'](_0x200399)),this['currentRevision']['_update'](_0x193500);}}async['saveRevision'](_0x5ccab4={},_0x37954f=null){const _0x155ad3=[];await this['_loadState'](),this['_continueCurrentRevision']=!0x1,_0x37954f>this['currentRevision']['toVersion']&&(_0x37954f=null),null===_0x37954f&&(_0x37954f=await this['_source']['getLatestVersion']());const _0x211fac=this['_getFromVersion'](_0x37954f),_0x4c26ab=this['buildRevisionData']({'from':_0x211fac,'to':_0x37954f});if(this['currentRevision']['toVersion']<_0x37954f){const _0x2c2e8b=this['buildRevisionData']({'revision':this['currentRevision'],'from':_0x37954f,'to':_0x37954f});_0x2c2e8b['authors']=[],_0x2c2e8b['authorsIds']=[],_0x2c2e8b['id']=this['currentRevision']['id'],this['currentRevision']['_update'](_0x2c2e8b,!0x0),delete _0x2c2e8b['authors'],_0x155ad3['push'](_0x2c2e8b);}_0x5ccab4['creatorId']=this['editor']['plugins']['get']('Users')['me']['id'],_0x5ccab4['name']=_0x5ccab4['name']||null,_0x5ccab4['id']=_0x5ccab4['id']||_0x221375(),_0x5ccab4={..._0x5ccab4,..._0x4c26ab};const _0x3a3882=this['addRevisionData'](_0x5ccab4);_0x155ad3['push'](_0x5ccab4);const _0x298571=this['repository']['getIndex'](_0x3a3882);if(0x0!==_0x298571){const _0x39b968=this['repository']['getRevision'](_0x298571-0x1);if(_0x39b968['fromVersion']!==_0x37954f){const _0x27662f=this['_revisionDataBuilder']['getData'](_0x37954f,_0x39b968['toVersion']),_0x1ad510={'id':_0x39b968['id'],'diffData':_0x27662f['diffData'],'authorsIds':_0x27662f['authorsIds'],'authors':_0x27662f['authorsIds']['map'](_0x530c02=>this['editor']['plugins']['get']('Users')['getUser'](_0x530c02)),'fromVersion':_0x37954f};_0x39b968===this['currentRevision']&&(_0x1ad510['createdAt']=new Date(_0x5ccab4['createdAt']['getTime']()+0xa)),_0x39b968['_update'](_0x1ad510,!0x0),delete _0x1ad510['authors'],_0x155ad3['push'](_0x1ad510);}}if(this['adapter']){for(const _0x4eb546 of _0x155ad3)this['_bufferUpdate'](_0x4eb546['id'],_0x4eb546,!0x0);this['sendBufferedUpdates']();}return _0x3a3882;}['addRevisionData'](_0x2dcf72){const _0x510feb=this['repository']['createRevision'](_0x2dcf72);return this['adapter']&&_0x510feb['on']('_update',(_0x325625,_0x548bc7,_0x2d71ce)=>{_0x2d71ce||(this['_bufferUpdate'](_0x548bc7['id'],_0x548bc7,!0x0),this['sendBufferedUpdates']());}),this['repository']['addRevision'](_0x510feb,this['_findInsertionIndex'](_0x510feb)),_0x510feb;}async['getRevisionDocumentData'](_0x752a7c){return await this['_utils']['loadRevisionData'](_0x752a7c,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x752a7c);}async['getRevisionRootsAttributes'](_0x57df1c){return await this['_utils']['loadRevisionData'](_0x57df1c,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x57df1c);}['sendBufferedUpdates'](){if(0x0===this['_bufferedUpdates']['size'])return;if(this['_isPendingUpdate'])return;let _0x50e26c=Array['from'](this['_bufferedUpdates']['values']());this['_bufferedUpdates']['clear']();for(let _0x3986da=0x0;_0x3986da<_0x50e26c['length'];_0x3986da++){const _0x4e015a=_0x50e26c[_0x3986da];let _0x179fd6=!0x1;for(const _0x4d42b2 of Object['keys'](_0x4e015a))void 0x0===_0x4e015a[_0x4d42b2]?delete _0x4e015a[_0x4d42b2]:'id'!==_0x4d42b2&&(_0x179fd6=!0x0);_0x179fd6||(_0x50e26c[_0x3986da]=null);}if(_0x50e26c=_0x50e26c['filter'](_0x1aa6af=>null!==_0x1aa6af),!_0x50e26c['length'])return;for(let _0x5ae9a1=0x0;_0x5ae9a1<_0x50e26c['length'];_0x5ae9a1++){const _0x110016=_0x50e26c[_0x5ae9a1];void 0x0!==_0x110016['fromVersion']&&void 0x0===_0x110016['toVersion']&&(_0x110016['toVersion']=this['repository']['getRevision'](_0x110016['id'])['toVersion']),void 0x0!==_0x110016['toVersion']&&void 0x0===_0x110016['fromVersion']&&(_0x110016['fromVersion']=this['repository']['getRevision'](_0x110016['id'])['fromVersion']);}const _0x2078d9=this['editor']['config']['get']('collaboration.channelId');this['_isPendingUpdate']=!0x0,this['_addPendingAction'](),this['adapter']['updateRevisions'](_0x50e26c,_0x2078d9)['finally'](()=>{this['_isPendingUpdate']=!0x1;})['then'](_0x555250=>{if(_0x555250){for(const _0x55e8ca of _0x555250)this['setRevisionData']({'id':_0x55e8ca['id'],'createdAt':_0x55e8ca['createdAt']});}this['_removePendingAction'](),this['sendBufferedUpdates']();});}['buildRevisionData']({revision:_0x2565a4=null,from:_0x4b8dd9=null,to:_0x1ab34c=null}){_0x4b8dd9=null!==_0x4b8dd9?_0x4b8dd9:_0x2565a4['fromVersion'],_0x1ab34c=null!==_0x1ab34c?_0x1ab34c:_0x2565a4['toVersion'];const _0x1d185c=this['_revisionDataBuilder']['getData'](_0x4b8dd9,_0x1ab34c),_0x52268c={'diffData':_0x1d185c['diffData'],'authorsIds':_0x1d185c['authorsIds'],'fromVersion':_0x4b8dd9,'toVersion':_0x1ab34c};if(!_0x2565a4||_0x1ab34c!==_0x2565a4['toVersion']){const _0x52a1f8=_0x1ab34c-0x1,_0x360257=this['_source']['history']['getOperation'](_0x52a1f8);_0x52268c['createdAt']=_0x360257&&_0x360257['createdAt']||new Date();}if(this['_loadedStateData']&&_0x4b8dd9===this['_loadedStateData']['fromVersion']){for(const _0x5695a2 of this['_loadedStateData']['authors'])_0x52268c['authorsIds']['includes'](_0x5695a2['id'])||_0x52268c['authorsIds']['push'](_0x5695a2['id']);}return _0x52268c;}['_bufferUpdate'](_0x4bdb2d,_0x56b3d7,_0x50f90f){if(this['_bufferedUpdates']['has'](_0x4bdb2d)){const _0x21b614=this['_bufferedUpdates']['get'](_0x4bdb2d);_0x56b3d7=_0x50f90f?{..._0x21b614,..._0x56b3d7}:{..._0x56b3d7,..._0x21b614};}this['_bufferedUpdates']['set'](_0x4bdb2d,_0x56b3d7);}['setRevisionData'](_0x45d2a4){const _0x421d98=this['repository']['getRevision'](_0x45d2a4['id']);if(_0x45d2a4['createdAt']&&(_0x45d2a4['createdAt']=new Date(_0x45d2a4['createdAt'])),_0x45d2a4['authorsIds']){const _0x489f3e=this['editor']['plugins']['get']('Users');_0x45d2a4['authors']=_0x45d2a4['authorsIds']['map'](_0x4b50cf=>_0x489f3e['getUser'](_0x4b50cf));}_0x421d98['_update'](_0x45d2a4,!0x0);}['_createInitialRevision'](_0x463dc1){const _0x5b3de1=this['repository']['getRevision'](this['repository']['length']-0x1);if(_0x5b3de1)this['_initialRevisionId']=_0x5b3de1['id'];else{const _0x4b2dc4=!this['editor']['model']['document']['roots']['find'](_0x569a3f=>this['editor']['model']['hasContent'](_0x569a3f)),_0x51d96f=this['editor']['plugins']['get']('Users')['me']['id'],_0x279bdf=m(this['editor']['locale'],_0x4b2dc4?'Empty\x20document':'Initial\x20revision');this['_makeRevision']({'from':_0x463dc1,'to':_0x463dc1,'id':this['_initialRevisionId'],'name':_0x279bdf,'creatorId':_0x51d96f});}}['_createCurrentRevision'](_0x470142){const _0x209c42=this['_source']['getCurrentRevisionId']();this['currentRevision']=this['repository']['getRevision'](_0x209c42),this['currentRevision']||(this['currentRevision']=this['_makeRevision']({'from':_0x470142,'to':_0x470142,'id':_0x209c42,'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'](_0x390caf,_0x480eb5){let _0x595411=this['editor']['config']['get']('initialData'),_0x220c92=this['editor']['config']['get']('rootsAttributes');if(void 0x0===_0x595411){_0x595411={};for(const _0x4f9378 of this['editor']['model']['document']['getRootNames']())_0x595411[_0x4f9378]='';}if('string'==typeof _0x595411&&(_0x595411={'main':_0x595411}),void 0x0===_0x220c92){_0x220c92={};for(const _0x18af17 of this['editor']['model']['document']['getRootNames']())_0x220c92[_0x18af17]={};}let _0x17c1db=!0x1;const _0x5da878=Object['keys'](_0x595411),_0x2e707e=Object['keys'](_0x390caf);for(const _0x158b90 of _0x5da878){if(_0x595411[_0x158b90]!==_0x390caf[_0x158b90]&&''!==_0x595411[_0x158b90]['trim']()){_0x17c1db=!0x0;break;}if(!_0x4544c2(_0x220c92[_0x158b90],_0x480eb5[_0x158b90])&&Object['keys'](_0x220c92[_0x158b90])['length']>0x0){_0x17c1db=!0x0;break;}}_0x17c1db||(_0x17c1db=_0x2e707e['some'](_0x71098f=>!this['editor']['model']['document']['getRoot'](_0x71098f))),_0x17c1db&&_0x2a22d8('editor-initial-data-replaced-with-revision-data',{'editorData':_0x595411,'editorRootsAttributes':_0x220c92,'revisionData':_0x390caf,'revisionRootsAttributes':_0x480eb5}),this['editor']['config']['set']('initialData',_0x390caf),this['editor']['config']['set']('rootsAttributes',_0x480eb5);}['_addPendingAction'](){if(!this['_pendingAction']){const _0x686680=this['editor']['plugins']['get']('PendingActions');this['_pendingAction']=_0x686680['add'](m(this['editor']['locale'],'PENDING_ACTION_REVISION_HISTORY'));}}['_removePendingAction'](){this['_pendingAction']&&(this['editor']['plugins']['get']('PendingActions')['remove'](this['_pendingAction']),this['_pendingAction']=null);}['_findInsertionIndex'](_0x48a44d){const _0x4ab347=this['repository']['getRevisions']();_0x4ab347['reverse']();let _0x47c160=0x0;for(;_0x47c160<_0x4ab347['length'];){const _0x1e6724=_0x4ab347[_0x47c160];if(_0x1e6724===this['currentRevision']){_0x47c160++;continue;}if(_0x1e6724['id']===this['_initialRevisionId'])break;const _0xa6e406=_0x48a44d['toVersion']-_0x1e6724['toVersion']||_0x48a44d['fromVersion']-_0x1e6724['fromVersion'];if(_0xa6e406>0x0)break;if(_0xa6e406<0x0)_0x47c160++;else{if(!_0x48a44d['creator']&&_0x1e6724['creator'])break;if(_0x1e6724['creator']||!_0x48a44d['creator']){if(_0x48a44d['createdAt']>_0x1e6724['createdAt'])break;_0x47c160++;}else _0x47c160++;}}return _0x47c160;}['_getFromVersion'](_0x783622){const _0x5f1eea=this['repository']['getRevisions']();_0x5f1eea['reverse'](),_0x5f1eea['shift']();const _0x2104b9=_0x5f1eea['find'](_0x10be7a=>_0x10be7a['toVersion']<=_0x783622)['toVersion'];return _0x2104b9<this['_startingVersion']?this['_startingVersion']:_0x2104b9;}['_makeRevision']({name:_0xef77e0,from:_0x3093bc,to:_0x3a85b6,creatorId:_0x252632,id:_0x1648c2}){const _0x37915b=this['buildRevisionData']({'from':_0x3093bc,'to':_0x3a85b6});_0x37915b['name']=_0xef77e0,_0x37915b['creatorId']=_0x252632,_0x37915b['id']=_0x1648c2;const _0x1edb37=this['addRevisionData'](_0x37915b);return this['adapter']&&this['_bufferUpdate'](_0x37915b['id'],_0x37915b,!0x0),_0x1edb37;}['_setConversion'](){this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'});}}class E{['editor'];['source'];['_savedMetaData'];['_lastFrom'];['_lastTo'];['_markers'];['_diffRoots'];['_diffRootsAttributes'];['_baseRoots'];['_baseRootsAttributes'];['_idsRoots'];['_baseIdsRoots'];['_touched'];['_touchedMarkers'];['_touchedRoots'];['_revisionId'];['_startingRevisionId'];constructor(_0x3e58bd){this['editor']=_0x3e58bd,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'](_0x49cdce){this['source']=_0x49cdce;const _0x29a1d7=new Map(),_0x1bce2e=new Map(),_0x36e1c0=this['editor']['model']['document']['roots']['map'](_0x31f493=>_0x31f493['rootName']);for(const _0x35334f of _0x36e1c0){const _0x2f3afc=this['editor']['model']['document']['getRoot'](_0x35334f),_0x262079=x(_0x2f3afc);_0x29a1d7['set'](_0x35334f,_0x262079),_0x1bce2e['set'](_0x35334f,Object['fromEntries'](_0x2f3afc['getAttributes']()));}const _0x1eb64c=Array['from'](this['editor']['model']['markers'])['map'](_0x40ce1b=>[_0x40ce1b['name'],_0x40ce1b['getRange']()]),_0x48aa39=this['source']['version'];this['_saveMetaData'](_0x48aa39,_0x29a1d7,_0x1eb64c,_0x1bce2e),this['_startingRevisionId']=this['_revisionId'];const _0x42eaab=new Map(),_0x352b27=new Map();for(const _0x1fe8b0 of _0x36e1c0){const _0x17a7ed=N(_0x1fe8b0);_0x42eaab['set'](_0x1fe8b0,_0x17a7ed),_0x352b27['set'](_0x1fe8b0,{});}this['_saveMetaData'](Number['NEGATIVE_INFINITY'],_0x42eaab,[],_0x352b27);}['getData'](_0x26bafc,_0x4706d8){if(this['_lastFrom']===_0x26bafc&&this['_lastTo']<=_0x4706d8)this['_savedMetaData']['size']>0x1&&this['_removeMetaData'](this['_lastTo']),this['_applyOperations'](this['_lastTo'],_0x4706d8,!0x0);else{if(!this['_savedMetaData']['has'](_0x26bafc)){const _0x36ab3c=this['_getPreviousFrom'](_0x26bafc);this['_calculateMetaData'](_0x36ab3c,_0x26bafc,!0x1);}this['_calculateMetaData'](_0x26bafc,_0x4706d8,!0x0);}return this['_lastFrom']=_0x26bafc,this['_lastTo']=_0x4706d8,this['_getState']();}['loadState'](_0x487e70){if(!this['_savedMetaData']['has'](_0x487e70['fromVersion'])){const _0xa70197=this['_getPreviousFrom'](_0x487e70['fromVersion']);this['_calculateMetaData'](_0xa70197,_0x487e70['fromVersion'],!0x1);}this['_calculateMetaData'](_0x487e70['fromVersion'],_0x487e70['toVersion'],!0x1);const _0x3ae3e1=this['editor']['plugins']['get']('RevisionHistoryUtils');this['_reset'](),this['_lastFrom']=_0x487e70['fromVersion'],this['_lastTo']=_0x487e70['toVersion'];for(const _0x18649e in _0x487e70['diffData']){const _0x49ec21=_0x487e70['diffData'][_0x18649e]['attachChange'],_0x232676=_0x459df9(_0x487e70['diffData'][_0x18649e]['attributesBefore'])||{},_0x5b739c=_0x3ae3e1['_makeModelFromViewString'](_0x487e70['diffData'][_0x18649e]['deletions']);_0x5b739c['rootName']=_0x18649e,_0x5b739c['_isAttached']=!_0x49ec21||!_0x49ec21['isAttached'],_0x5b739c['isAttached']=()=>_0x5b739c['_isAttached'],this['_baseRoots']['set'](_0x18649e,_0x5b739c),this['_baseRootsAttributes']['set'](_0x18649e,_0x232676),_0x49ec21&&this['_touchedRoots']['set'](_0x18649e,_0x49ec21);const _0x1ea424=this['_makeIdsRoot'](_0x5b739c);this['_baseIdsRoots']['set'](_0x18649e,_0x1ea424);for(const [_0x1a11f3,_0x1226c0]of _0x5b739c['markers']){if(!_0x1a11f3['startsWith']('revision:'))continue;const _0x183c03=_0x1a11f3['split'](':')[0x2];for(const _0x1c8345 of _0x1226c0['getWalker']({'singleCharacters':!0x0})){const _0x186dcb=this['_getVidAttributeName'](_0x1c8345),_0xf803a='elementEnd'==_0x1c8345['type']?_0x1c8345['previousPosition']['path']['slice'](0x0,-0x1):_0x1c8345['previousPosition']['path'],_0x1fba59=_0x1ea424['getNodeByPath'](_0xf803a)['getAttribute'](_0x186dcb);this['_touched']['set'](_0x1fba59,{'userId':_0x183c03});}_0x5b739c['markers']['delete'](_0x1a11f3);}}this['_startingRevisionId']=this['_revisionId'];const _0x14afa8=[...Array(this['_revisionId'])['keys']()]['slice'](0x1)['filter'](_0x340be5=>!this['_touched']['has'](_0x340be5));let _0x2f0062=0x0;const _0x1abb2b=new Map();for(const _0xe1b23 in _0x487e70['diffData']){const _0xd37b8a=_0x487e70['diffData'][_0xe1b23]['attachChange'],_0x1ad6aa=_0x459df9(_0x487e70['diffData'][_0xe1b23]['attributesAfter'])||{},_0x3c2326=_0x3ae3e1['_makeModelFromViewString'](_0x487e70['diffData'][_0xe1b23]['insertions']);_0x3c2326['rootName']=_0xe1b23,_0x3c2326['_isAttached']=!_0xd37b8a||_0xd37b8a['isAttached'],_0x3c2326['isAttached']=()=>_0x3c2326['_isAttached'],this['_diffRoots']['set'](_0xe1b23,_0x3c2326),this['_diffRootsAttributes']['set'](_0xe1b23,_0x1ad6aa);const _0x511784=this['_makeIdsRoot'](_0x3c2326,Number['NEGATIVE_INFINITY']);this['_idsRoots']['set'](_0xe1b23,_0x511784),_0x1abb2b['set'](_0xe1b23,_0x3c2326['isAttached']()?_0x1ad6aa:{});for(const [_0x2b8fdd,_0x142b9f]of _0x3c2326['markers']){if(!_0x2b8fdd['startsWith']('revision:'))continue;const _0xa35ee6=_0x2b8fdd['split'](':')[0x2];for(const _0x471a18 of _0x142b9f['getWalker']({'singleCharacters':!0x0})){const _0x4a372f=this['_getVidAttributeName'](_0x471a18),_0xdcbd7d=this['_revisionId']++,_0x125da0='elementEnd'==_0x471a18['type']?_0x471a18['previousPosition']['path']['slice'](0x0,-0x1):_0x471a18['previousPosition']['path'];_0x511784['getNodeByPath'](_0x125da0)['_setAttribute'](_0x4a372f,_0xdcbd7d),this['_touched']['set'](_0xdcbd7d,{'userId':_0xa35ee6});}_0x3c2326['markers']['delete'](_0x2b8fdd);}for(const _0x220937 of this['editor']['model']['createRangeIn'](_0x3c2326)['getWalker']({'singleCharacters':!0x0})){const _0x5336f9=this['_getVidAttributeName'](_0x220937),_0x7d9e13='elementEnd'==_0x220937['type']?_0x220937['previousPosition']['path']['slice'](0x0,-0x1):_0x220937['previousPosition']['path'],_0x4afb92=_0x511784['getNodeByPath'](_0x7d9e13);_0x4afb92['getAttribute'](_0x5336f9)>0x0||_0x4afb92['_setAttribute'](_0x5336f9,_0x14afa8[_0x2f0062++]);}for(const [_0x71227a,_0x56bd7a]of _0x3c2326['markers'])_0x71227a['startsWith']('revision:')||this['_markers']['set'](_0x71227a,_0x56bd7a);}const {roots:_0x1d6d16}=this['_savedMetaData']['get'](_0x487e70['fromVersion']),{roots:_0x3eb829}=this['_savedMetaData']['get'](_0x487e70['toVersion']),_0x3c1e87=x(_0x1d6d16['get']('$graveyard'));this['_baseRoots']['set']('$graveyard',_0x3c1e87),this['_baseIdsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x3c1e87,Number['NEGATIVE_INFINITY']));const _0xdd2baf=x(_0x3eb829['get']('$graveyard'));this['_diffRoots']['set']('$graveyard',_0xdd2baf),this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0xdd2baf));const _0x5a41b7=Array['from'](this['_diffRoots'])['map'](([_0x5bfe25,_0x497684])=>[_0x5bfe25,x(_0x497684)]);this['_saveMetaData'](this['_lastTo'],_0x5a41b7,this['_markers'],_0x1abb2b);}['reInit'](){this['_reset'](),this['_lastFrom']=-0x1,this['_lastTo']=-0x1,this['_savedMetaData']['clear'](),this['init'](this['source']);}['_saveMetaData'](_0x24fe8b,_0xd9e9ec,_0x226ef0,_0x48c749){const _0x46f165=new Map(_0xd9e9ec),_0x38ef44=new Map(_0x459df9(_0x48c749)),_0x4b5a97=new Map();for(const [_0x4e9021,_0x533025]of _0x226ef0)_0x4b5a97['set'](_0x4e9021,{'start':_0x533025['start']['clone'](),'end':_0x533025['end']['clone'](),'rootName':_0x533025['root']['rootName']});this['_savedMetaData']['set'](_0x24fe8b,{'roots':_0x46f165,'markers':_0x4b5a97,'rootsAttributes':_0x38ef44});}['_removeMetaData'](_0x378329){this['_savedMetaData']['delete'](_0x378329);}['_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'](_0x1ebc26,_0xa6893d=null){let _0x3437eb=null;_0x1ebc26['is']('documentFragment')||(_0x3437eb=new _0x16738f(_0x1ebc26['name'],{'vid_start':null===_0xa6893d?this['_revisionId']++:_0xa6893d++}));const _0x984d82=[];for(const _0x27b73f of _0x1ebc26['getChildren']())if(_0x27b73f['is']('element')){_0x984d82['push'](this['_makeIdsRoot'](_0x27b73f,_0xa6893d));const _0x1c38c5=_0x984d82[_0x984d82['length']-0x1];null!==_0xa6893d&&(_0xa6893d=_0x1c38c5['is']('element','$text')?_0x1c38c5['getAttribute']('vid')+0x1:_0x1c38c5['getAttribute']('vid_end')+0x1);}else{for(let _0x1f4579=0x0;_0x1f4579<_0x27b73f['offsetSize'];_0x1f4579++)_0x984d82['push'](new _0x16738f('$text',{'vid':null===_0xa6893d?this['_revisionId']++:_0xa6893d++}));}if(_0x1ebc26['is']('documentFragment')){const _0x46b47a=N(_0x1ebc26['rootName']);return _0x46b47a['_insertChild'](0x0,_0x984d82),_0x46b47a;}return _0x3437eb['_setAttribute']('vid_end',null===_0xa6893d?this['_revisionId']++:_0xa6893d++),_0x3437eb['_insertChild'](0x0,_0x984d82),_0x3437eb;}['_calculateMetaData'](_0x31f189,_0x1ae6f5,_0x21578a){this['_reset']();const {roots:_0x502855,markers:_0x2ae3cd,rootsAttributes:_0x543364}=this['_savedMetaData']['get'](_0x31f189);this['_baseRoots']=new Map(_0x502855),this['_baseRootsAttributes']=new Map(_0x459df9(_0x543364));for(const [_0x56e564,_0xd27f5b]of this['_baseRoots'])if('$graveyard'!==_0x56e564&&(this['_diffRoots']['set'](_0x56e564,x(_0xd27f5b)),this['_diffRootsAttributes']=new Map(_0x459df9(_0x543364)),_0x21578a)){const _0x457bf1=this['_revisionId'];this['_idsRoots']['set'](_0x56e564,this['_makeIdsRoot'](_0xd27f5b)),this['_baseIdsRoots']['set'](_0x56e564,this['_makeIdsRoot'](_0xd27f5b,_0x457bf1));}this['_startingRevisionId']=this['_revisionId'],this['_diffRoots']['set']('$graveyard',x(this['_baseRoots']['get']('$graveyard'))),_0x21578a&&this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](this['_baseRoots']['get']('$graveyard')));for(const [_0x176ee3,_0x463d43]of _0x2ae3cd){const _0x51cb95=this['_baseRoots']['get'](_0x463d43['rootName']),_0x3227da=this['_diffRoots']['get'](_0x463d43['rootName']),_0x4f4cfa=new _0xb076e3(this['_fixPosition'](_0x463d43['start'],_0x51cb95),this['_fixPosition'](_0x463d43['end'],_0x51cb95)),_0x12dff5=this['_fixRange'](_0x4f4cfa,_0x3227da);_0x51cb95['markers']['set'](_0x176ee3,_0x4f4cfa),this['_markers']['set'](_0x176ee3,_0x12dff5);}this['_applyOperations'](_0x31f189,_0x1ae6f5,_0x21578a);}['_applyOperations'](_0x4b1a96,_0x57f49e,_0x4c5b21){for(const _0x421dc7 of this['source']['getOperations'](_0x4b1a96,_0x57f49e))this['_handleOperation'](_0x421dc7,_0x4c5b21);for(const _0x3a2086 of this['_diffRoots']['values']())_0x3a2086['markers']['clear']();for(const [_0xff2972,_0x1246d0]of this['_markers']){this['_diffRoots']['get'](_0x1246d0['root']['rootName'])['markers']['set'](_0xff2972,_0x1246d0['clone']());}const _0x59a765=new Map(),_0x425faa=new Map();for(const [_0x2e8388,_0x4e2056]of this['_diffRoots'])_0x59a765['set'](_0x2e8388,x(_0x4e2056)),_0x425faa['set'](_0x2e8388,this['_diffRootsAttributes']['get'](_0x2e8388));this['_saveMetaData'](_0x57f49e,_0x59a765,this['_markers'],_0x425faa);}['_getPreviousFrom'](_0x2669ab){const _0x18b04c=Array['from'](this['_savedMetaData']['keys']());_0x18b04c['sort']((_0x727f0a,_0x8d485e)=>_0x727f0a-_0x8d485e),_0x18b04c['reverse']();for(const _0x56a6a5 of _0x18b04c)if(_0x56a6a5<_0x2669ab)return _0x56a6a5;return Number['NEGATIVE_INFINITY'];}['_copyMarkers'](_0x4cc75d,_0x237d5d){const _0x4d5716=Array['from'](_0x237d5d['markers'])['map'](([_0x473c0a,_0x1e3c90])=>[_0x473c0a,this['_fixRange'](_0x1e3c90,_0x4cc75d)]);_0x4cc75d['markers']=new Map(_0x4d5716);}['_transformMarkers'](_0x1a964c){for(const _0x52f9a0 of this['_markers']['values']()){const _0x17c403=_0x52f9a0['getTransformedByOperation'](_0x1a964c),_0x522e50=_0xb076e3['_createFromRanges'](_0x17c403);_0x52f9a0['start']=_0x522e50['start'],_0x52f9a0['end']=_0x522e50['end'];}}['_handleOperation'](_0x5606c0,_0xcae450){if('addRoot'!=_0x5606c0['type']&&'detachRoot'!=_0x5606c0['type']){if('insert'==_0x5606c0['type']){const _0x395f17=_0x5606c0['position']['root']['rootName'];this['_diffRoots']['has'](_0x395f17)||(this['_diffRoots']['set'](_0x395f17,N(_0x395f17,!0x0)),this['_diffRootsAttributes']['set'](_0x395f17,{}),_0xcae450&&this['_idsRoots']['set'](_0x395f17,N(_0x395f17,!0x0)));}else{if('addRootAttribute'==_0x5606c0['type']||'removeRootAttribute'==_0x5606c0['type']||'changeRootAttribute'==_0x5606c0['type'])return void this['_handleRootAttributeOperation'](_0x5606c0);'marker'==_0x5606c0['type']&&this['_handleMarkerOperation'](_0x5606c0);}if('marker'!==_0x5606c0['type']){const _0x349cbb=this['_cloneOperation'](_0x5606c0,this['_diffRoots']);_0x349cbb['_execute'](),this['_transformMarkers'](_0x349cbb);}if(_0xcae450)switch(_0x5606c0['type']){case'insert':this['_handleInsertOperation'](_0x5606c0);break;case'move':case'remove':case'reinsert':this['_handleMoveOperation'](_0x5606c0);break;case'merge':this['_handleMergeOperation'](_0x5606c0);break;case'split':this['_handleSplitOperation'](_0x5606c0);}}else this['_handleRootOperation'](_0x5606c0,_0xcae450);}['_cloneOperation'](_0xe697ea,_0x5da46c){const _0x13b379=_0xe697ea['clone']();return _0x13b379['_authorId']=_0xe697ea['_authorId'],this['_fixOperation'](_0x13b379,_0x5da46c),_0x13b379;}['_getBaseVids'](_0x133d05){return _0x133d05['map'](_0x1759d4=>{const _0x5d6561=this['_getVidAttributeName'](_0x1759d4);return Number(_0x1759d4['item']['getAttribute'](_0x5d6561));});}['_generateTape'](_0x2e9be3,_0x3c37f2){if(_0x2e9be3['is']('element','$text'))_0x3c37f2['push']({'item':_0x2e9be3,'type':'text'});else{_0x2e9be3['is']('element')&&_0x3c37f2['push']({'item':_0x2e9be3,'type':'elementStart'});for(const _0x30b285 of _0x2e9be3['getChildren']())this['_generateTape'](_0x30b285,_0x3c37f2);_0x2e9be3['is']('element')&&_0x3c37f2['push']({'item':_0x2e9be3,'type':'elementEnd'});}return _0x3c37f2;}['_getState'](){const _0x2cab37=new Map(this['_touched']),_0x5c1df6=new Map(_0x2cab37),_0x23c77f=new Map(),_0x12a692={'insertions':{},'deletions':{}},_0x37aca8={'insertions':{},'deletions':{}},_0x2feca0=new Map(),_0x270e6f=new Set([...this['_baseRoots']['keys'](),...this['_diffRoots']['keys']()]);_0x270e6f['delete']('$graveyard');for(const _0x1872fe of _0x270e6f){const _0x151855=this['_diffRoots']['get'](_0x1872fe)||N(_0x1872fe,!0x1),_0x5761ad=this['_baseRoots']['get'](_0x1872fe)||N(_0x1872fe,!0x1);_0x151855['isAttached']()||_0x5761ad['isAttached']()?(_0x12a692['insertions'][_0x1872fe]=x(_0x151855),_0x12a692['deletions'][_0x1872fe]=x(_0x5761ad),this['_copyMarkers'](_0x12a692['deletions'][_0x1872fe],_0x5761ad),this['_copyMarkers'](_0x12a692['insertions'][_0x1872fe],_0x151855),_0x37aca8['insertions'][_0x1872fe]=this['_generateTape'](this['_idsRoots']['get'](_0x1872fe),[]),_0x37aca8['deletions'][_0x1872fe]=this['_generateTape'](this['_baseIdsRoots']['get'](_0x1872fe)||N(_0x1872fe,!0x1),[])):_0x270e6f['delete'](_0x1872fe);}for(const _0x5bd111 of _0x270e6f){const _0x31407f=_0x37aca8['insertions'][_0x5bd111];for(const _0xe6ab82 of _0x31407f){const _0x4a0a15=this['_getVidAttributeName'](_0xe6ab82),_0x44ecc9=_0xe6ab82['item']['getAttribute'](_0x4a0a15);_0x5c1df6['delete'](_0x44ecc9),_0x44ecc9>=this['_startingRevisionId']&&_0x23c77f['set'](_0x44ecc9,_0x2cab37['get'](_0x44ecc9));}}for(const _0x5507ec of _0x270e6f){const _0x521e8d=_0x37aca8['insertions'][_0x5507ec],_0x17b7a4=this['_getBaseVids'](_0x37aca8['deletions'][_0x5507ec]);let _0x94261c=0x0;for(const _0x5238de of _0x521e8d){const _0x2c3da9=this['_getVidAttributeName'](_0x5238de),_0x133fb2=_0x5238de['item']['getAttribute'](_0x2c3da9);if(!_0x23c77f['has'](_0x133fb2)&&!_0x2feca0['has'](_0x133fb2)){if(_0x5c1df6['has'](_0x133fb2))_0x94261c++;else{if(_0x133fb2!=_0x17b7a4[_0x94261c]){const _0x352385=_0x2cab37['get'](_0x133fb2)||_0x2cab37['get'](_0x17b7a4[_0x94261c]);for(;_0x133fb2!=_0x17b7a4[_0x94261c];)_0x5c1df6['has'](_0x17b7a4[_0x94261c])||(_0x2feca0['set'](_0x17b7a4[_0x94261c],_0x352385),_0x2cab37['set'](_0x17b7a4[_0x94261c],_0x352385)),_0x94261c++;}_0x94261c++;}}}}for(const _0x9f6a73 of _0x270e6f){const _0x4887d8=_0x37aca8['insertions'][_0x9f6a73];for(const _0xd3c91c of _0x4887d8){const _0x20516e=this['_getVidAttributeName'](_0xd3c91c),_0x338f9e=_0xd3c91c['item']['getAttribute'](_0x20516e);if(_0x2feca0['has'](_0x338f9e)){const _0x3da11a=_0x2feca0['get'](_0x338f9e);_0x5c1df6['has'](_0x338f9e)||_0x5c1df6['set'](_0x338f9e,{..._0x3da11a}),_0x23c77f['set'](_0x338f9e,{..._0x3da11a});}}}for(const _0xbf1183 of _0x5c1df6['keys']())_0xbf1183>=this['_startingRevisionId']&&_0x5c1df6['delete'](_0xbf1183);const _0x33b2be=new Map();for(const _0x399d9c of _0x270e6f){let _0x2b81ca=_0x37aca8['insertions'][_0x399d9c];for(const _0x44a371 of _0x2b81ca)if(_0x44a371['item']['is']('element','tableCell')){const _0x58364e=this['_getVidAttributeName'](_0x44a371),_0x3c8c6a=_0x44a371['item']['getAttribute'](_0x58364e);if(_0x23c77f['has'](_0x3c8c6a)){const _0x4d6a35=_0x44a371['item']['parent']['parent']['getAttribute']('vid_start'),_0x7dbc78=_0x33b2be['get'](_0x4d6a35)||new Set();_0x7dbc78['add'](_0x23c77f['get'](_0x3c8c6a)['userId']),_0x33b2be['set'](_0x4d6a35,_0x7dbc78);}}_0x2b81ca=_0x37aca8['deletions'][_0x399d9c];for(const _0x519ad7 of _0x2b81ca)if(_0x519ad7['item']['is']('element','tableCell')){const _0x553c09=this['_getVidAttributeName'](_0x519ad7),_0x25f948=_0x519ad7['item']['getAttribute'](_0x553c09);if(_0x5c1df6['has'](_0x25f948)){const _0x5655f8=_0x519ad7['item']['parent']['parent']['getAttribute']('vid_start'),_0x195728=_0x33b2be['get'](_0x5655f8)||new Set();_0x195728['add'](_0x5c1df6['get'](_0x25f948)['userId']),_0x33b2be['set'](_0x5655f8,_0x195728);}}for(const _0x48725b of _0x33b2be['keys']())(_0x23c77f['has'](_0x48725b)||_0x5c1df6['has'](_0x48725b))&&_0x33b2be['delete'](_0x48725b);}for(const _0x1b68b8 of _0x270e6f){const _0x1a4a85=_0x37aca8['insertions'][_0x1b68b8];let _0x1c0189=null,_0x5e9d51=null;for(const _0x29103e of _0x1a4a85){const _0x289895=this['_getVidAttributeName'](_0x29103e),_0x3e17b1=_0x29103e['item']['getAttribute'](_0x289895),_0x48e9ed=_0x33b2be['get'](_0x3e17b1);_0x48e9ed&&'elementStart'==_0x29103e['type']&&(_0x1c0189=Array['from'](_0x48e9ed)[0x0],_0x5e9d51=_0x29103e['item']['getAttribute']('vid_end')),_0x1c0189&&(_0x5c1df6['set'](_0x3e17b1,{'userId':_0x1c0189}),_0x23c77f['set'](_0x3e17b1,{'userId':_0x1c0189})),_0x3e17b1==_0x5e9d51&&(_0x1c0189=null,_0x5e9d51=null);}}const _0x193f29={},_0xfa6cea=new Set();for(const _0x670097 of _0x270e6f){const _0x4fe73a=_0x12a692['deletions'][_0x670097],_0x9b040=_0x12a692['insertions'][_0x670097];for(const {userId:_0xe9464}of this['_touchedMarkers']['values']())null!==_0xe9464&&_0xfa6cea['add'](_0xe9464);for(const {userId:_0x35c2da}of this['_touchedRoots']['values']())null!==_0x35c2da&&_0xfa6cea['add'](_0x35c2da);this['_markChanges'](_0x9b040,_0x37aca8['insertions'][_0x670097],_0x23c77f,'insertion',_0xfa6cea),this['_markChanges'](_0x4fe73a,_0x37aca8['deletions'][_0x670097],_0x5c1df6,'deletion',_0xfa6cea),_0x193f29[_0x670097]={'insertions':this['_prepareViewToSave'](_0x9b040),'deletions':this['_prepareViewToSave'](_0x4fe73a),'attachChange':this['_touchedRoots']['get'](_0x670097)||null,'attributesBefore':_0x459df9(this['_baseRootsAttributes']['get'](_0x670097))||{},'attributesAfter':_0x459df9(this['_diffRootsAttributes']['get'](_0x670097))};}return{'diffData':_0x193f29,'authorsIds':Array['from'](_0xfa6cea)};}['_processRootBeforeSave'](_0x2edfbf){for(const [,_0x348ba5]of _0x2edfbf['markers']){const _0x144bb0=_0x348ba5['start']['getAncestors']()['filter'](_0x54f62c=>'tableCell'==_0x54f62c['name']);for(const _0x585c09 of _0x144bb0)0x1==_0x585c09['childCount']&&_0x585c09['getChild'](0x0)['is']('element','paragraph')&&_0x585c09['getChild'](0x0)['_setAttribute']('keepParagraph',!0x0);}}['_prepareViewToSave'](_0xe58741){this['_processRootBeforeSave'](_0xe58741);const _0x5d45b6=this['editor']['data']['toView'](_0xe58741,{}),_0x28807d=Array['from'](_0x5d45b6['getChildren']())['map'](_0xc5c452=>this['_getViewJson'](_0xc5c452));return JSON['stringify'](_0x28807d);}['_getViewJson'](_0x4092bb){if(_0x4092bb['is']('$text'))return _0x4092bb['data'];{const _0x17e128=this['editor']['plugins']['get']('RevisionHistoryUtils'),_0x98e86e=_0x4092bb,_0xe4f0ff=this['editor']['data']['htmlProcessor']['domConverter'],_0x2ed3ed={'type':_0x17e128['_getTypeCharForViewElement'](_0x98e86e),'name':_0x98e86e['name'],'attributes':Array['from'](_0x98e86e['getAttributes']()),'children':Array['from'](_0x98e86e['getChildren']())['map'](_0x500013=>this['_getViewJson'](_0x500013))};if(_0x4092bb['is']('uiElement')&&'$comment'!=_0x4092bb['name']){const _0x535995=_0x4092bb['render'](_0xe4f0ff['domDocument'],_0xe4f0ff);_0x2ed3ed['children']['push'](_0x535995['outerHTML']);}else{if(_0x4092bb['is']('rawElement')){const _0x56a49c=_0xe4f0ff['domDocument']['createElement'](_0x98e86e['name']);_0x4092bb['render'](_0x56a49c,_0xe4f0ff),_0x2ed3ed['children']['push'](_0x56a49c['innerHTML']);}}const _0x3dee63=Array['from'](_0x98e86e['getCustomProperties']());_0x3dee63['length']>0x0&&(_0x2ed3ed['customProperties']=_0x3dee63);const _0x5b57c3=_0x98e86e['getFillerOffset']();return null!==_0x5b57c3&&(_0x2ed3ed['fillerOffset']=_0x5b57c3),_0x2ed3ed;}}['_markChanges'](_0x409e64,_0x412ec4,_0x2db651,_0x2f945e,_0x54858e){let _0x35a26f=null,_0x12a5f4=null,_0x4ea7b4=0x0;const _0x23c2e0=this['editor']['model'];for(let _0x57b458=0x0;_0x57b458<_0x412ec4['length'];_0x57b458++){const _0x45d45a=this['_getVidAttributeName'](_0x412ec4[_0x57b458]),_0x572da0=_0x412ec4[_0x57b458]['item']['getAttribute'](_0x45d45a),_0x2e7ddf=_0x2db651['get'](_0x572da0),_0x2a7a48=_0x57b458==_0x412ec4['length']-0x1;(!_0x35a26f&&_0x2e7ddf&&(_0x35a26f=_0x2e7ddf,_0x12a5f4=_0x412ec4[_0x57b458]),_0x35a26f&&(!_0x2e7ddf||_0x2e7ddf['userId']!=_0x35a26f['userId']))&&(_0x4ae7ca(_0x2e7ddf,P(_0x12a5f4,_0x409e64,_0x23c2e0),P(_0x412ec4[_0x57b458],_0x409e64,_0x23c2e0)),_0x35a26f=_0x2e7ddf||null,_0x12a5f4=_0x2e7ddf?_0x412ec4[_0x57b458]:null),_0x35a26f&&_0x2a7a48&&_0x4ae7ca(_0x2e7ddf,P(_0x12a5f4,_0x409e64,_0x23c2e0),V(_0x412ec4[_0x57b458],_0x409e64,_0x23c2e0));}function _0x4ae7ca(_0x4ca5a0,_0x49633d,_0x6cbb16){const _0x3ea36e=_0x35a26f['userId'],_0x1637f7='revision:'+_0x2f945e+':'+_0x3ea36e+':'+_0x4ea7b4++,_0x45f053=_0x23c2e0['createRange'](_0x49633d,_0x6cbb16);_0x409e64['markers']['set'](_0x1637f7,_0x45f053),null!==_0x3ea36e&&_0x54858e['add'](_0x3ea36e);}}['_getVidAttributeName'](_0x2a4ffc){switch(_0x2a4ffc['type']){case'elementStart':return'vid_start';case'elementEnd':return'vid_end';default:return'vid';}}['_fixOperation'](_0x13ccd0,_0x258b24){_0x13ccd0['baseVersion']=null;for(const _0x55f6e8 in _0x13ccd0){const _0x40dee5=_0x13ccd0[_0x55f6e8];if(_0x40dee5 instanceof _0x3cb0ec){const _0x195de6=_0x258b24['get'](_0x40dee5['root']['rootName']);_0x13ccd0[_0x55f6e8]=this['_fixPosition'](_0x40dee5,_0x195de6);}if(_0x40dee5 instanceof _0xb076e3){const _0x1789d9=_0x258b24['get'](_0x40dee5['root']['rootName']);_0x13ccd0[_0x55f6e8]=this['_fixRange'](_0x40dee5,_0x1789d9);}'root'===_0x55f6e8&&(_0x13ccd0['root']=_0x258b24['get'](_0x13ccd0['root']['rootName']));}}['_fixRange'](_0x9b0a1d,_0x2ebe3e){return this['editor']['model']['createRange'](this['_fixPosition'](_0x9b0a1d['start'],_0x2ebe3e),this['_fixPosition'](_0x9b0a1d['end'],_0x2ebe3e));}['_fixPosition'](_0x331f2a,_0x5adc74){return this['editor']['model']['createPositionFromPath'](_0x5adc74,_0x331f2a['path'],_0x331f2a['stickiness']);}['_handleInsertOperation'](_0x37cb17){const _0x15d133=this['_idsRoots']['get'](_0x37cb17['position']['root']['rootName']),_0x112c68=this['_fixPosition'](_0x37cb17['position'],_0x15d133),_0x316a0c=null===_0x37cb17['_authorId']?null:_0x37cb17['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x53d7af=_0x112c68['parent'],_0x1fe468=this['_revisionId'],_0x5105cb=[];for(const _0x4fe734 of _0x37cb17['nodes'])if(_0x4fe734['is']('element'))_0x5105cb['push'](this['_makeIdsRoot'](_0x4fe734));else{for(let _0x514f12=0x0;_0x514f12<_0x4fe734['offsetSize'];_0x514f12++)_0x5105cb['push'](new _0x16738f('$text',{'vid':this['_revisionId']++}));}const _0x556759=this['_revisionId'];for(let _0x2a449f=_0x1fe468;_0x2a449f<_0x556759;_0x2a449f++)this['_touched']['set'](_0x2a449f,{'userId':_0x316a0c});_0x53d7af['_insertChild'](_0x112c68['offset'],_0x5105cb);}['_handleMoveOperation'](_0x3a122a){(_0x3a122a=this['_cloneOperation'](_0x3a122a,this['_idsRoots']))['_execute']();const _0x3abbcf=null===_0x3a122a['_authorId']?null:_0x3a122a['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x1d0ba0=_0x3a122a['getMovedRangeStart'](),_0x58a299=_0x1d0ba0['parent'],_0xcae527=_0x1d0ba0['offset'];!function _0x33eb0e(_0x217efd,_0x4e98c5,_0x1a8005,_0x1ad437){for(let _0x232284=_0x1a8005;_0x232284<_0x1ad437;_0x232284++){const _0x176b40=_0x4e98c5['getChild'](_0x232284);_0x176b40['is']('element','$text')?_0x217efd['set'](_0x176b40['getAttribute']('vid'),{'userId':_0x3abbcf}):(_0x217efd['set'](_0x176b40['getAttribute']('vid_start'),{'userId':_0x3abbcf}),_0x33eb0e(_0x217efd,_0x176b40,0x0,_0x176b40['childCount']),_0x217efd['set'](_0x176b40['getAttribute']('vid_end'),{'userId':_0x3abbcf}));}}(this['_touched'],_0x58a299,_0xcae527,_0xcae527+_0x3a122a['howMany']);}['_handleMergeOperation'](_0x12187){const _0x46519d=null===(_0x12187=this['_cloneOperation'](_0x12187,this['_idsRoots']))['_authorId']?null:_0x12187['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x16eee0=_0x12187['targetPosition']['parent'],_0x450192=_0x12187['sourcePosition']['parent'],_0x2928dd=_0x16eee0['getAttribute']('vid_end'),_0x22f90a=_0x450192['getAttribute']('vid_start');_0x16eee0['_setAttribute']('vid_end',_0x450192['getAttribute']('vid_end')),_0x450192['_setAttribute']('vid_end',_0x2928dd),this['_touched']['set'](_0x22f90a,{'userId':_0x46519d}),this['_touched']['set'](_0x2928dd,{'userId':_0x46519d}),_0x12187['_execute']();}['_handleSplitOperation'](_0x9c2957){const _0x40c561=null===(_0x9c2957=this['_cloneOperation'](_0x9c2957,this['_idsRoots']))['_authorId']?null:_0x9c2957['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x54dcd0=_0x9c2957['graveyardPosition'],_0x5b095b=_0x9c2957['splitPosition']['parent'];_0x9c2957['_execute']();const _0x2881c5=_0x5b095b['getAttribute']('vid_end'),_0x4ff0f0=_0x9c2957['insertionPosition']['nodeAfter'];if(_0x54dcd0){const _0x291676=_0x4ff0f0['getAttribute']('vid_end'),_0x4bdc3e=_0x5b095b['getAttribute']('vid_end');_0x5b095b['_setAttribute']('vid_end',_0x291676),_0x4ff0f0['_setAttribute']('vid_end',_0x4bdc3e),this['_touched']['set'](_0x5b095b['getAttribute']('vid_end'),{'userId':_0x40c561}),this['_touched']['set'](_0x4ff0f0['getAttribute']('vid_start'),{'userId':_0x40c561});}else{const _0xd6ffdd=this['_revisionId']++,_0x3fad4e=this['_revisionId']++;_0x5b095b['_setAttribute']('vid_end',_0xd6ffdd),_0x4ff0f0['_setAttribute']('vid_start',_0x3fad4e),_0x4ff0f0['_setAttribute']('vid_end',_0x2881c5),this['_touched']['set'](_0xd6ffdd,{'userId':_0x40c561}),this['_touched']['set'](_0x3fad4e,{'userId':_0x40c561});}}['_handleMarkerOperation'](_0x587d08){if(!_0x587d08['affectsData'])return;const _0x221699=(_0x587d08=this['_cloneOperation'](_0x587d08,this['_diffRoots']))['oldRange']?_0x587d08['oldRange']['root']:null,_0x158037=_0x587d08['newRange']?_0x587d08['newRange']['root']:null;_0x221699&&this['_markers']['delete'](_0x587d08['name']),_0x158037&&this['_markers']['set'](_0x587d08['name'],_0x587d08['newRange']['clone']());const _0x11072e=null===_0x587d08['_authorId']?null:_0x587d08['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x44a5e9=_0x587d08['name'];if(!this['_touchedMarkers']['has'](_0x44a5e9))return void this['_touchedMarkers']['set'](_0x44a5e9,{'range':_0x587d08['oldRange'],'userId':_0x11072e});const _0x591cec=this['_touchedMarkers']['get'](_0x44a5e9),_0x2f2eae=_0x591cec['range'],_0x5c78a1=_0x587d08['newRange'];null==_0x2f2eae&&null==_0x5c78a1||_0x2f2eae&&_0x5c78a1&&_0x2f2eae['isEqual'](_0x5c78a1)?this['_touchedMarkers']['delete'](_0x587d08['name']):_0x591cec['userId']=_0x11072e;}['_handleRootOperation'](_0x2e60a3,_0x3e4a22){this['_diffRoots']['has'](_0x2e60a3['rootName'])?this['_diffRoots']['get'](_0x2e60a3['rootName'])['_isAttached']=_0x2e60a3['isAdd']:(this['_diffRoots']['set'](_0x2e60a3['rootName'],N(_0x2e60a3['rootName'],!0x0)),this['_diffRootsAttributes']['set'](_0x2e60a3['rootName'],{}),_0x3e4a22&&this['_idsRoots']['set'](_0x2e60a3['rootName'],N(_0x2e60a3['rootName'],!0x0)));const _0x28b460=null===_0x2e60a3['_authorId']?null:_0x2e60a3['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x5f40ff=this['_touchedRoots']['get'](_0x2e60a3['rootName']);_0x5f40ff&&_0x5f40ff['userId']===_0x28b460?this['_touchedRoots']['delete'](_0x2e60a3['rootName']):this['_touchedRoots']['set'](_0x2e60a3['rootName'],{'userId':_0x28b460,'isAttached':_0x2e60a3['isAdd']});}['_handleRootAttributeOperation'](_0x324e48){const _0x1a0651=this['_diffRootsAttributes']['get'](_0x324e48['root']['rootName']);null===_0x324e48['newValue']?delete _0x1a0651[_0x324e48['key']]:_0x1a0651[_0x324e48['key']]=_0x324e48['newValue'];}}function x(_0x243a9b){const _0x4bb270=N(_0x243a9b['rootName'],_0x243a9b['isAttached']());for(const _0x52b13a of _0x243a9b['getChildren']()){const _0x59842b=_0x52b13a['_clone'](!0x0);_0x4bb270['_appendChild'](_0x59842b);}return _0x4bb270;}function N(_0x28f6d4,_0x3a5a5f=!0x0){const _0x26480d=new _0x54d9b6();return _0x26480d['rootName']=_0x28f6d4,_0x26480d['_isAttached']=_0x3a5a5f,_0x26480d['isAttached']=()=>_0x26480d['_isAttached'],_0x26480d;}function P(_0x43d577,_0x59f6e8,_0x1b6928){const _0x101433='elementEnd'==_0x43d577['type']?_0x1b6928['createPositionAt'](_0x43d577['item'],'end'):_0x1b6928['createPositionBefore'](_0x43d577['item']);return _0x1b6928['createPositionFromPath'](_0x59f6e8,_0x101433['path'],_0x101433['stickiness']);}function V(_0x326d59,_0x229f6f,_0x74783d){const _0x484e91='elementStart'==_0x326d59['type']?_0x74783d['createPositionAt'](_0x326d59['item'],0x0):_0x74783d['createPositionAfter'](_0x326d59['item']);return _0x74783d['createPositionFromPath'](_0x229f6f,_0x484e91['path'],_0x484e91['stickiness']);}class me extends/* #__PURE__ -- @preserve */
|
|
25
|
+
_0x29c9e9(_0x484abd){['focusTracker'];['keystrokes'];['revisionNameInputView'];constructor(_0x1fd28e,_0x2232c7){super(_0x1fd28e),this['focusTracker']=new _0x23f28d(),this['keystrokes']=new _0x416488(),this['set']('revisionNameInputValue',''),this['revisionNameInputView']=this['_createRevisionNameInput'](_0x2232c7),this['setTemplate']({'tag':'form','attributes':{'class':['ck','ck-revision-history-save-revision-form','ck-responsive-form'],'tabindex':'-1'},'children':[this['revisionNameInputView']]}),this['initializeCssTransitionDisablerMixin']();}['render'](){super['render'](),_0x104706({'view':this}),this['focusTracker']['add'](this['revisionNameInputView']['element']),this['keystrokes']['listenTo'](this['element']);const _0x147c69=_0x361c66=>_0x361c66['stopPropagation']();this['keystrokes']['set']('arrowright',_0x147c69),this['keystrokes']['set']('arrowleft',_0x147c69),this['keystrokes']['set']('arrowup',_0x147c69),this['keystrokes']['set']('arrowdown',_0x147c69);}['focus'](){this['revisionNameInputView']['focus']();}get['revisionName'](){return this['revisionNameInputView']['fieldView']['element']['value']['trim']();}set['revisionName'](_0x3f8e7f){this['revisionNameInputView']['fieldView']['element']['value']=_0x3f8e7f['trim']();}['reset'](){this['revisionNameInputView']['fieldView']['element']['value']='',this['revisionNameInputView']['errorText']=null;}['_createRevisionNameInput'](_0x1943f1){const _0x1543b0=new et(this['locale'],ti),_0x46d855=_0x1543b0['fieldView'];_0x46d855['extendTemplate']({'attributes':{'maxlength':'220'}});let _0x2712bf=m(this['locale'],'Name\x20of\x20the\x20revision');return!_0x1943f1&&(_0x2712bf+='\x20('+m(this['locale'],'optional')+')'),(_0x1543b0['label']=_0x2712bf,_0x46d855['on']('input',()=>{this['revisionNameInputValue']=_0x46d855['element']['value']['trim']();}),_0x1543b0);}}class l extends _0x59afc0{static get['pluginName'](){return'RevisionHistoryUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[h];}['_saveRevisionFormView'];['init'](){const _0x446607=this['editor'],_0x3a6779=_0x446607['plugins']['get']('RevisionTracker');_0x446607['ui']['componentFactory']['add']('revisionHistory',_0xbbf15f=>{const _0x40a102=_0x1cb51d(_0xbbf15f),_0x4cb6e0=_0x40a102['panelView']['children'],_0x4fbc40=new _0x5bef83(_0xbbf15f),_0x36009b=new _0xb232fc(_0xbbf15f),_0x271f68=new _0x14152c(_0xbbf15f),_0x62f422=new _0xb232fc(_0xbbf15f),_0x367220=new _0x14152c(_0xbbf15f);return _0x40a102['bind']('isEnabled')['to'](_0x3a6779,'isReady',_0x3a6779,'isEnabled',_0x446607,'isReadOnly',(_0x28b988,_0x140f9c,_0x114917)=>_0x28b988&&_0x140f9c&&!_0x114917),_0x40a102['buttonView']['set']({'icon':_0x58c189,'label':m(_0xbbf15f,'Revision\x20history'),'tooltip':!0x0}),_0x271f68['set']({'label':m(_0xbbf15f,'Save\x20current\x20revision'),'withText':!0x0,'role':'menuitem'}),_0x271f68['bind']('isEnabled')['to'](_0x3a6779,'isReady',_0x3a6779,'isEnabled',_0x446607,'isReadOnly',(_0x9de58a,_0x15d307,_0x3a1333)=>_0x9de58a&&_0x15d307&&!_0x3a1333),_0x271f68['on']('execute',()=>this['_showDialog']()),_0x367220['set']({'label':m(_0xbbf15f,'Open\x20revision\x20history'),'withText':!0x0,'role':'menuitem'}),_0x367220['bind']('isEnabled')['to'](_0x3a6779,'isReady',_0x446607,'isReadOnly',(_0x4fb023,_0x4e26b3)=>_0x4fb023&&!_0x4e26b3),_0x367220['on']('execute',()=>{_0x446607['config']['get']('revisionHistory')['showRevisionViewerCallback'](),_0x40a102['isOpen']=!0x1,_0x446607['editing']['view']['focus']();}),_0x36009b['children']['add'](_0x271f68),_0x62f422['children']['add'](_0x367220),_0x4fbc40['role']='menu',_0x4fbc40['items']['addMany']([_0x36009b,_0x62f422]),_0x4cb6e0['add'](_0x4fbc40),_0x40a102;}),_0x446607['ui']['componentFactory']['add']('menuBar:revisionHistory',()=>this['_registerMenuComponent']());}['_registerMenuComponent'](){const _0x259456=this['editor'],_0x4f0f2a=_0x259456['locale'],_0x32ada3=new _0x4a1477(_0x4f0f2a),_0x22c214=new _0x1c59ff(_0x4f0f2a);_0x32ada3['buttonView']['set']({'icon':_0x58c189,'label':m(_0x4f0f2a,'Revision\x20history')});const _0x46b8fc=new _0x4597ac(_0x4f0f2a,_0x32ada3),_0x12d4bb=new _0x5436d7(_0x4f0f2a);_0x12d4bb['set']({'label':m(_0x4f0f2a,'Save\x20current\x20revision')}),_0x12d4bb['delegate']('execute')['to'](_0x32ada3),_0x12d4bb['on']('execute',()=>{this['_showDialog']();}),_0x46b8fc['children']['add'](_0x12d4bb),_0x22c214['items']['add'](_0x46b8fc);const _0x16a4ca=new _0x4597ac(_0x4f0f2a,_0x32ada3),_0x2b8c87=new _0x5436d7(_0x4f0f2a);return _0x2b8c87['set']({'label':m(_0x4f0f2a,'Open\x20revision\x20history')}),_0x2b8c87['delegate']('execute')['to'](_0x32ada3),_0x2b8c87['on']('execute',()=>{_0x259456['config']['get']('revisionHistory')['showRevisionViewerCallback']();}),_0x16a4ca['children']['add'](_0x2b8c87),_0x22c214['items']['add'](_0x16a4ca),_0x32ada3['panelView']['children']['add'](_0x22c214),_0x32ada3;}['_showDialog'](){const _0x2ceb70=this['editor'],_0x1893f2=_0x2ceb70['locale'],_0xb76e12=_0x2ceb70['plugins']['get']('Dialog'),_0x88a11b=_0x2ceb70['plugins']['get']('RevisionTracker');function _0x26f4f3(_0x439447){_0x2ceb70['config']['get']('revisionHistory.requireRevisionName')&&''===_0x439447['revisionName']?_0x439447['revisionNameInputView']['errorText']=m(_0x1893f2,'The\x20revision\x20name\x20cannot\x20be\x20empty.'):(_0x2ceb70['plugins']['get'](h)['saveRevision']({'name':_0x439447['revisionName']}),_0xb76e12['hide']());}this['_saveRevisionFormView']||(this['_createSaveRevisionFormView'](),this['_saveRevisionFormView']['on']('submit',()=>_0x26f4f3(this['_saveRevisionFormView']))),this['_saveRevisionFormView']['reset'](),_0xb76e12['show']({'id':'revisionSave','title':m(_0x1893f2,'Save\x20current\x20revision'),'isModal':!0x0,'content':this['_saveRevisionFormView'],'actionButtons':[{'label':m(_0x2ceb70['locale'],'Cancel'),'withText':!0x0,'onExecute':()=>_0xb76e12['hide']()},{'label':m(_0x2ceb70['locale'],'Accept'),'class':'ck-button-action','withText':!0x0,'onCreate'(_0x5b188d){_0x5b188d['bind']('isEnabled')['to'](_0x88a11b,'isReady',_0x88a11b,'isEnabled',_0x2ceb70,'isReadOnly',(_0x130766,_0x5404c0,_0x1c067c)=>_0x130766&&_0x5404c0&&!_0x1c067c);},'onExecute':()=>_0x26f4f3(this['_saveRevisionFormView'])}]});}['_createSaveRevisionFormView'](){const _0x1f2c69=this['editor'],_0x5af9a4=_0x1f2c69['locale'];this['_saveRevisionFormView']=new me(_0x5af9a4,_0x1f2c69['config']['get']('revisionHistory.requireRevisionName')),this['_saveRevisionFormView']['render']();}}class z extends _0x484abd{['changeId'];['_model'];constructor(_0x518145,_0x3b7ef5){super(_0x518145),this['_model']=_0x3b7ef5,this['changeId']=_0x3b7ef5['id'];const _0x3c5d7a=this['bindTemplate'],_0x567b1b=m(_0x518145,_0x3b7ef5['data']['isSuggestion']?'Suggested\x20by':'add'==_0x3b7ef5['type']?'Added\x20by':'Removed\x20by');this['set']('type',_0x3b7ef5['type']),this['setTemplate']({'tag':'div','attributes':{'class':['ck-annotation','ck-revision-change',_0x3c5d7a['to']('type',_0x473491=>'ck-revision-change__'+_0x473491)],'tabindex':-0x1},'children':[{'tag':'span','children':[{'tag':'span','attributes':{'class':['ck-revision-change__label']},'children':[{'text':_0x567b1b}]},{'text':'\x20'+_0x3b7ef5['author']['name']}]}]});}['focus'](){this['element']['focus']();}}class G extends/* #__PURE__ -- @preserve */
|
|
26
|
+
_0x911840(){['id'];['author'];['type'];['data'];['rootName'];constructor(_0x4cbae6){super(),this['id']=_0x4cbae6['id']||_0x221375(),this['author']=_0x4cbae6['author'],this['type']=_0x4cbae6['type'],this['data']=_0x4cbae6['data']||{},this['rootName']=_0x4cbae6['rootName'],this['set']('createdAt',_0x4cbae6['createdAt']);}['toJSON'](){return{'id':this['id'],'authorId':this['author']['id'],'type':this['type'],'data':this['data'],'createdAt':this['createdAt']};}}class J{['newRevisionId'];['oldRevisionId'];['changes'];constructor(_0x51da46,_0x44442f){this['newRevisionId']=_0x51da46,this['oldRevisionId']=_0x44442f,this['changes']=new _0x51dee5();}['_setChanges'](_0x1aeb79){for(const _0xc8660a of _0x1aeb79)this['changes']['add'](_0xc8660a);}}class u extends _0x59afc0{['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[_0x4e6a9f,_0x43390d,S,$];}constructor(_0x26318f){super(_0x26318f),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',(_0x13256f,_0x288b74,_0x559108)=>{this['activeChange']=null,this['activeView']=null,this['editor']['editing']['view']['change'](_0xe97598=>{for(const _0x21b666 of this['editor']['editing']['view']['document']['roots'])_0x559108?_0xe97598['removeClass']('ck-editor__editable__overlay',_0x21b666):_0xe97598['addClass']('ck-editor__editable__overlay',_0x21b666);});}),this['bind']('isNavigationMode')['to'](this,'activeChange',_0x1a2892=>null!==_0x1a2892),this['bind']('currentChangeNumber')['to'](this,'isReady',this,'diff',this,'activeChange',(_0x44c7f9,_0x31a180,_0x5b654a)=>_0x44c7f9&&_0x5b654a?_0x31a180['changes']['getIndex'](_0x5b654a):0x0),this['bind']('numberOfChanges')['to'](this,'isReady',this,'diff',(_0x348638,_0x56d010)=>_0x348638?_0x56d010['changes']['length']:0x0),this['_changeView']=null,this['_changeIdToChange']=new Map(),this['_balloon']=this['editor']['plugins']['get'](_0x43390d);}['init'](){const _0x590110=this['editor'],_0x3e81f9=new rt(_0x590110,{'direction':'backward'}),_0x4edb62=new rt(_0x590110,{'direction':'forward'});(_0x590110['commands']['add']('showPreviousChange',_0x3e81f9),_0x590110['commands']['add']('showNextChange',_0x4edb62),_0x590110['commands']['add']('restoreRevision',new nt(_0x590110)),this['on']('change:numberOfChanges',()=>{_0x3e81f9['refresh'](),_0x4edb62['refresh']();}),this['_setConversion'](),this['_initInteractions'](),_0x590110['enableReadOnlyMode']('revision-viewer'),_0x590110['plugins']['has']('WidgetToolbarRepository'))&&_0x590110['plugins']['get']('WidgetToolbarRepository')['forceDisabled']('revision-viewer');}async['getRevisionDocumentData'](_0x210feb){return await this['_utils']['loadRevisionData'](_0x210feb,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x210feb);}async['getRevisionRootsAttributes'](_0x3dabcf){return await this['_utils']['loadRevisionData'](_0x3dabcf,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x3dabcf);}async['compare'](_0x184c6b,_0x2403e4,_0x2ebceb=!0x1){if(!this['isEnabled'])return;const _0x4b7c8f=this['diff'],_0x565f3e=this['repository'],_0x1e43ea='string'==typeof _0x184c6b?_0x565f3e['getRevision'](_0x184c6b):_0x184c6b,_0x311099='string'==typeof _0x2403e4?_0x565f3e['getRevision'](_0x2403e4):_0x2403e4,_0x362ff2=_0x1e43ea['id'],_0x46a04c=_0x311099?_0x311099['id']:null;if(!_0x2ebceb&&this['diff']&&this['diff']['newRevisionId']===_0x362ff2&&this['diff']['oldRevisionId']===_0x46a04c)return Promise['resolve']();this['isReady']=!0x1,this['activeView']=null,this['activeChange']=null,this['diff']=new J(_0x362ff2,_0x46a04c);const _0x3f08fa=this['_getRevisionsRange'](_0x1e43ea,_0x311099,!0x0)['map'](_0x1dfeac=>this['_utils']['loadRevisionData'](_0x1dfeac,this['adapter']));return _0x3f08fa['push'](new Promise(_0x454f6d=>{setTimeout(_0x454f6d,0x14);})),Promise['all'](_0x3f08fa)['then'](()=>{if(!this['isEnabled'])return;this['_cleanUp']();const _0x45242f=this['_getDiff'](_0x362ff2,_0x46a04c);for(const _0x46709f of _0x45242f['changes'])this['_changeIdToChange']['set'](_0x46709f['id'],_0x46709f);this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x29fbab=>{for(const _0x286f7a of this['editor']['model']['document']['getRootNames']())_0x29fbab['detachRoot'](_0x286f7a);for(const _0x1c687e of Object['keys'](_0x45242f['model'])){const _0x28b4df=_0x29fbab['addRoot'](_0x1c687e);for(const _0x2e07a3 of Object['keys'](_0x45242f['attributes'][_0x1c687e]))_0x29fbab['setAttribute'](_0x2e07a3,_0x45242f['attributes'][_0x1c687e][_0x2e07a3],_0x28b4df);_0x29fbab['insert'](_0x45242f['model'][_0x1c687e],_0x28b4df,0x0);}}),this['diff']['_setChanges'](this['_sortAndFilterDiffChanges'](_0x45242f['changes'])),this['isReady']=!0x0;})['catch'](_0x5d1388=>{console['error'](_0x5d1388),this['_cleanUp'](),_0x4b7c8f&&(this['diff']=_0x4b7c8f),this['isReady']=!0x0;});}['addRevisionData'](_0x324143,_0xb24126){const _0x2a4c92=this['repository']['createRevision'](_0x324143);return _0x2a4c92['on']('_update',(_0x370a41,_0x559c6a,_0x46df98)=>_0xb24126(_0x559c6a,_0x46df98,_0x2a4c92)),this['repository']['addRevision'](_0x2a4c92),_0x2a4c92;}['_cleanUp'](){this['activeChange']=null,this['_cleanMarkers'](),this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=null,this['_changeIdToChange']['clear'](),this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x33ac67=>{for(const _0x307ae2 of this['editor']['model']['document']['getRootNames']())_0x33ac67['detachRoot'](_0x307ae2);});}['_sortAndFilterDiffChanges'](_0x583eaa){const _0x57bffc=[],_0x53a419=new Map();for(const _0x321dc4 of this['editor']['model']['document']['getRootNames']()){const _0x117c64=this['editor']['editing']['view']['getDomRoot'](_0x321dc4);if(!_0x117c64)continue;const _0x3aaab3=_0x117c64['getClientRects']()['item'](0x0);_0x3aaab3&&(_0x57bffc['push'](_0x321dc4),_0x53a419['set'](_0x321dc4,_0x3aaab3));}return _0x57bffc['sort']((_0xa3bcc2,_0x5ee4fe)=>{const _0x4b2d38=_0x53a419['get'](_0xa3bcc2),_0x179af1=_0x53a419['get'](_0x5ee4fe);return _0x4b2d38['y']-_0x179af1['y']||_0x4b2d38['x']-_0x179af1['x'];}),(_0x583eaa=_0x583eaa['filter'](_0x229255=>_0x57bffc['includes'](_0x229255['rootName'])))['sort']((_0x46bf88,_0x54b472)=>_0x57bffc['indexOf'](_0x46bf88['rootName'])-_0x57bffc['indexOf'](_0x54b472['rootName'])),_0x583eaa;}['_makeTape'](_0x19857b){const _0x5dde87=Array['from'](_0x19857b['markers'])['filter'](([_0xa13c65,_0x45fec8])=>_0xa13c65['startsWith']('revision:')&&!_0x45fec8['isCollapsed']),_0x454c29=Array['from'](this['editor']['model']['createRangeIn'](_0x19857b)['getWalker']({'singleCharacters':!0x0}));if(0x0!=_0x5dde87['length'])for(const _0x27f8a0 of _0x454c29){const [_0x1edb6c,_0x9a7124]=_0x5dde87[0x0],[,_0xf73c3f,_0x395350]=_0x1edb6c['split'](':');if(_0x9a7124['end']['isEqual'](_0x27f8a0['nextPosition'])&&_0x5dde87['shift'](),(_0x27f8a0['previousPosition']['isEqual'](_0x9a7124['start'])||_0x27f8a0['previousPosition']['isAfter'](_0x9a7124['start']))&&('insertion'==_0xf73c3f?_0x27f8a0['isAdded']={'userId':_0x395350}:'deletion'==_0xf73c3f&&(_0x27f8a0['isRemoved']={'userId':_0x395350})),0x0==_0x5dde87['length'])break;}return _0x454c29;}['_refreshStartEndIndex'](_0x10bf2b){const _0xe4e34d=new Map();for(let _0xc4690b=0x0;_0xc4690b<_0x10bf2b['length'];_0xc4690b++)'text'===_0x10bf2b[_0xc4690b]['type']?(_0x10bf2b[_0xc4690b]['item']['startIndex']=_0xc4690b,_0x10bf2b[_0xc4690b]['item']['endIndex']=_0xc4690b):('elementStart'===_0x10bf2b[_0xc4690b]['type']?_0x10bf2b[_0xc4690b]['item']['startIndex']=_0xc4690b:'elementEnd'===_0x10bf2b[_0xc4690b]['type']&&(_0x10bf2b[_0xc4690b]['item']['endIndex']=_0xc4690b),_0xe4e34d['set'](_0x10bf2b[_0xc4690b]['id'],_0xc4690b));for(const _0x480dbc of _0xe4e34d['values']())'elementStart'===_0x10bf2b[_0x480dbc]['type']?_0x10bf2b[_0x480dbc]['item']['endIndex']=_0xe4e34d['get'](_0x10bf2b[_0x480dbc]['pairId']):'elementEnd'===_0x10bf2b[_0x480dbc]['type']&&(_0x10bf2b[_0x480dbc]['item']['startIndex']=_0xe4e34d['get'](_0x10bf2b[_0x480dbc]['pairId']));}['_processTape'](_0x197396){for(let _0x4c850b=0x0;_0x4c850b<_0x197396['length'];_0x4c850b++){if('elementStart'===_0x197396[_0x4c850b]['type'])_0x197396[_0x4c850b]['item']['startIndex']=_0x4c850b;else{if('elementEnd'===_0x197396[_0x4c850b]['type']){_0x197396[_0x4c850b]['item']['endIndex']=_0x4c850b;const _0x211966=_0x197396[_0x4c850b]['item']['startIndex'];_0x197396[_0x211966]['pairId']=_0x197396[_0x4c850b]['id'],_0x197396[_0x4c850b]['pairId']=_0x197396[_0x211966]['id'];}else _0x197396[_0x4c850b]['item']['startIndex']=_0x4c850b,_0x197396[_0x4c850b]['item']['endIndex']=_0x4c850b,_0x197396[_0x4c850b]['pairId']=null;}_0x197396[_0x4c850b]['markersStart']||(_0x197396[_0x4c850b]['markersStart']=[],_0x197396[_0x4c850b]['markersEnd']=[]);}}['_markInsertions'](_0x32e1eb,_0x39f9fa){const _0x545462=_0x32e1eb['filter'](_0x32098d=>!_0x32098d['isAdded']);for(let _0x422573=0x0;_0x422573<_0x39f9fa['length'];_0x422573++)_0x39f9fa[_0x422573]['isAdded']&&(_0x545462[_0x422573]['isAdded']=_0x39f9fa[_0x422573]['isAdded']);}['_getDiff'](_0x3a1b92,_0x3147be=null){const _0x2e6cf8=this['repository']['getRevision'](_0x3a1b92),_0x4c36c9=_0x3147be?this['repository']['getRevision'](_0x3147be):null,_0x123f15=this['_getRevisionsRange'](_0x2e6cf8,_0x4c36c9),_0x1c4bf0=_0x123f15[_0x123f15['length']-0x1],_0x5f335a=new Map(),_0x396b49={'model':{},'attributes':{},'changes':[]},_0x350999=new Set(),_0x257fef=new Map();for(let _0x361d3d=_0x123f15['length']-0x1;_0x361d3d>=0x0;_0x361d3d--){const _0x253e56=_0x123f15[_0x361d3d];for(const _0x31b196 of Object['keys'](_0x253e56['diffData']))if(_0x253e56['diffData'][_0x31b196]['attachChange']){const _0x27f2a7=_0x253e56['diffData'][_0x31b196]['attachChange'];_0x27f2a7['isAttached']?(_0x350999['add'](_0x31b196),_0x257fef['has'](_0x31b196)&&_0x257fef['get'](_0x31b196)['userId']==_0x27f2a7['userId']?_0x257fef['delete'](_0x31b196):_0x257fef['set'](_0x31b196,_0x27f2a7)):_0x257fef['has'](_0x31b196)?(_0x350999['delete'](_0x31b196),_0x257fef['delete'](_0x31b196)):(_0x350999['add'](_0x31b196),_0x257fef['set'](_0x31b196,_0x27f2a7));}else _0x350999['add'](_0x31b196);}for(const _0x51e847 of _0x350999){const _0x4b397f=_0x257fef['has'](_0x51e847)&&!_0x257fef['get'](_0x51e847)['isAttached'];let _0x1dcc6f=_0x4b397f?_0x123f15['length']-0x1:0x0;const _0x1d630a=_0x4b397f?-0x1:0x1;for(;_0x123f15[_0x1dcc6f];){const _0x1c36b0=_0x123f15[_0x1dcc6f];if(_0x1c36b0['diffData'][_0x51e847]){const _0x1f8931=_0x4b397f?_0x1c36b0['diffData'][_0x51e847]['attributesBefore']:_0x1c36b0['diffData'][_0x51e847]['attributesAfter'];_0x396b49['attributes'][_0x51e847]=_0x1f8931?_0x459df9(_0x1f8931):{};break;}_0x1dcc6f+=_0x1d630a;}}for(const _0x24913e of _0x123f15){_0x24913e['model']={};for(const _0x1d56b4 of _0x24913e['authors'])_0x5f335a['set'](_0x1d56b4['id'],_0x1d56b4);for(const _0x3e914a of _0x350999){const _0x542aef=_0x24913e['diffData'][_0x3e914a]?_0x24913e['diffData'][_0x3e914a]['insertions']:'[]',_0x556203=_0x24913e['diffData'][_0x3e914a]?_0x24913e['diffData'][_0x3e914a]['deletions']:'[]';_0x24913e['model'][_0x3e914a]={'insertions':this['_utils']['_makeModelFromViewString'](_0x542aef),'deletions':this['_utils']['_makeModelFromViewString'](_0x556203)};}}for(const _0x208f66 of _0x350999){let _0x1d1209=null,_0x30acc8=0x0;const _0x631860=new Map(Array['from'](_0x2e6cf8['model'][_0x208f66]['insertions']['markers'])['filter'](([_0x292a67])=>!_0x292a67['startsWith']('revision:')));let _0x35cfeb=0x0;for(const _0x3813b1 of _0x123f15){const _0x463d8a=this['_makeTape'](_0x3813b1['model'][_0x208f66]['insertions']);_0x3813b1==_0x2e6cf8?(_0x1d1209=_0x463d8a,_0x30acc8=_0x1d1209['length'],_0x1d1209['forEach'](_0x253c57=>{_0x253c57['id']=_0x35cfeb++;}),this['_processTape'](_0x1d1209)):this['_markInsertions'](_0x1d1209,_0x463d8a);const _0xca6924=_0x1d1209['filter'](_0x12039f=>!_0x12039f['isAdded'])['map'](_0x34e1b6=>_0x34e1b6['id']);let _0x4b81dd=0x0;const _0x183b7e=this['_makeTape'](_0x3813b1['model'][_0x208f66]['deletions']);_0x183b7e['forEach'](_0xabc3e5=>{_0xabc3e5['isRemoved']?_0xabc3e5['id']=_0x30acc8++:_0xabc3e5['id']=_0xca6924[_0x4b81dd++];}),this['_processTape'](_0x183b7e),this['_setDistance'](_0x1d1209,'isAdded'),this['_setDistance'](_0x183b7e,'isRemoved'),_0x3813b1==_0x2e6cf8&&this['_markMarkers'](_0x1d1209,_0x631860),_0x1d1209=this['_joinTapes'](_0x1d1209,_0x183b7e),this['_refreshStartEndIndex'](_0x1d1209),this['_setDistance'](_0x1d1209,'isRemoved');}_0x1d1209=_0x1d1209['filter'](_0x2e4ddc=>!(_0x2e4ddc['isAdded']&&_0x2e4ddc['isRemoved']));const _0x53078e=new Map(_0x1c4bf0['model'][_0x208f66]['deletions']['markers']),_0x5a20c5=new Set(_0x631860['keys']());for(const _0x6b90a of _0x53078e['keys']())_0x5a20c5['delete'](_0x6b90a);this['_markSuggestions'](_0x1d1209,_0x5a20c5),this['_fixObsoleteTags'](_0x1d1209),_0x1d1209=this['_removeMissingPairs'](_0x1d1209),_0x1d1209=this['_markMismatchedRemovedTags'](_0x1d1209),_0x1d1209=this['_removeUnsupportedChanges'](_0x1d1209);const {root:_0x250822,changes:_0x4d75b4}=this['_makeModelFromTape'](_0x1d1209,_0x5f335a,_0x208f66);_0x396b49['model'][_0x208f66]=_0x250822;const _0x525b1c=_0x257fef['get'](_0x208f66);if(_0x525b1c){const _0x3df6b3=_0x5f335a['get'](_0x525b1c['userId']),_0x5f1859=new G({'author':_0x3df6b3,'type':_0x525b1c['isAttached']?'add':'remove','data':{'isOnRoot':!0x0},'createdAt':new Date(),'rootName':_0x208f66});_0x4d75b4['unshift'](_0x5f1859),_0x396b49['attributes'][_0x208f66]['revisionHistoryAttachChange']=_0x5f1859['id'];}_0x396b49['changes']=_0x396b49['changes']['concat'](_0x4d75b4);}return _0x396b49;}['_markMarkers'](_0x153d46,_0x471a83){for(let _0x5368e3=0x0;_0x5368e3<_0x153d46['length'];_0x5368e3++)for(const [_0xcf0012,_0x4e7d53]of _0x471a83)!_0x4e7d53['isCollapsed']&&_0x4e7d53['start']['isEqual'](_0x153d46[_0x5368e3]['previousPosition'])&&_0x153d46[_0x5368e3]['markersStart']['push'](_0xcf0012),_0x4e7d53['end']['isEqual'](_0x153d46[_0x5368e3]['nextPosition'])&&_0x153d46[_0x5368e3]['markersEnd']['push'](_0xcf0012);}['_joinTapes'](_0x1818ca,_0x287b95){let _0x313ce8=[],_0x5d907f=0x0,_0x57ab85=0x0;for(;_0x5d907f<_0x1818ca['length']||_0x57ab85<_0x287b95['length'];){const _0xd34f1e=_0x1818ca[_0x5d907f]||{},_0x408a32=_0x287b95[_0x57ab85]||{};if(_0xd34f1e['id']==_0x408a32['id'])_0x5d907f++,_0x57ab85++,_0x313ce8['push'](_0xd34f1e);else{if(_0x408a32['isRemoved']&&_0xd34f1e['isAdded']){const {commonTape:_0x2c8f24,iEnd:_0x4fe390,jEnd:_0x24871c}=this['_threeWayMerge'](_0x1818ca,_0x5d907f,_0x287b95,_0x57ab85);_0x313ce8=_0x313ce8['concat'](_0x2c8f24),_0x5d907f=_0x4fe390,_0x57ab85=_0x24871c;}else _0x408a32['isRemoved']?(_0x57ab85++,_0x313ce8['push'](_0x408a32)):(_0x5d907f++,_0x313ce8['push'](_0xd34f1e));}}return _0x313ce8;}['_markSuggestions'](_0x2db8d8,_0xff18ab){const _0x1511fe=[];for(let _0x383a38=0x0;_0x383a38<_0x2db8d8['length'];_0x383a38++){for(let _0xe821cd=0x0;_0xe821cd<_0x2db8d8[_0x383a38]['markersStart']['length'];_0xe821cd++){const _0x325986=_0x2db8d8[_0x383a38]['markersStart'][_0xe821cd];if(!_0xff18ab['has'](_0x325986))continue;const {group:_0xfeafd2,type:_0x1b3ffa,authorId:_0x139e0c}=_0x25a012(_0x325986);'revision-suggestion'!=_0xfeafd2||'insertion'!=_0x1b3ffa&&'deletion'!=_0x1b3ffa||(_0x1511fe['unshift']({'type':_0x1b3ffa,'name':_0x325986,'userId':_0x139e0c}),_0x2db8d8[_0x383a38]['markersStart']['splice'](_0xe821cd,0x1),_0xe821cd--);}_0x554e51(_0x2db8d8[_0x383a38]);for(let _0x33ffc0=0x0;_0x33ffc0<_0x2db8d8[_0x383a38]['markersEnd']['length'];_0x33ffc0++){const _0x341d04=_0x2db8d8[_0x383a38]['markersEnd'][_0x33ffc0];if(!_0xff18ab['has'](_0x341d04))continue;const {group:_0x555464,type:_0x1e015b}=_0x25a012(_0x341d04);if('revision-suggestion'!=_0x555464||'insertion'!=_0x1e015b&&'deletion'!=_0x1e015b)continue;_0x2db8d8[_0x383a38]['markersEnd']['splice'](_0x33ffc0,0x1),_0x33ffc0--;const _0x1cafd3=_0x1511fe['findIndex'](_0x2ebdbb=>_0x2ebdbb['name']==_0x341d04);_0x1cafd3>-0x1&&_0x1511fe['splice'](_0x1cafd3,0x1);}}function _0x25a012(_0x1cceb2){const _0xeb93e9=_0x1cceb2['split'](':');return{'group':_0xeb93e9[0x0],'type':_0xeb93e9[0x1],'subType':_0xeb93e9['length']>=0x5?_0xeb93e9[0x2]:null,'id':_0xeb93e9['length']<0x5?_0xeb93e9[0x2]:_0xeb93e9[0x3],'authorId':_0xeb93e9['length']<0x5?_0xeb93e9[0x3]:_0xeb93e9[0x4],'markerCount':0x6==_0xeb93e9['length']?_0xeb93e9[0x5]:null};}function _0x554e51(_0xbad66c){for(let _0x5316db=0x0;_0x5316db<_0x1511fe['length'];_0x5316db++){if(_0xbad66c['isAdded']&&'insertion'==_0x1511fe[_0x5316db]['type']&&_0xbad66c['isAdded']['userId']==_0x1511fe[_0x5316db]['userId'])return _0xbad66c['isAddSuggestion']=_0x1511fe[_0x5316db],void delete _0xbad66c['isAdded'];if(!_0xbad66c['isAdded']&&!_0xbad66c['isRemoved']&&'deletion'==_0x1511fe[_0x5316db]['type'])return void(_0xbad66c['isRemoveSuggestion']=_0x1511fe[_0x5316db]);}}}['_setDistance'](_0x22a5f8,_0x3e3ff0){let _0x52966a=0x0,_0x506849=!0x1;const _0x383453=new Map();for(const _0x4b0b90 of _0x22a5f8)_0x4b0b90[_0x3e3ff0]?_0x506849&&(_0x52966a++,_0x506849=!0x1):(_0x52966a++,_0x506849=!0x0),_0x383453['set'](_0x4b0b90['id'],_0x52966a);for(let _0x283d9f=0x0;_0x283d9f<_0x22a5f8['length'];_0x283d9f++){if('isRemoved'==_0x3e3ff0&&_0x22a5f8[_0x283d9f]['isAdded']||'isAdded'==_0x3e3ff0&&_0x22a5f8[_0x283d9f]['isRemoved'])continue;if('text'==_0x22a5f8[_0x283d9f]['type']){_0x22a5f8[_0x283d9f]['distance']=0x0;continue;}const _0x1e61af=_0x383453['get'](_0x22a5f8[_0x283d9f]['pairId']),_0x3a4f75=_0x383453['get'](_0x22a5f8[_0x283d9f]['id']);_0x22a5f8[_0x283d9f]['distance']=_0x1e61af-_0x3a4f75;}}['_getRevisionsRange'](_0x4e856b,_0x3cf679,_0x588567=!0x1){const _0x5e6116=[];let _0x118503=this['repository']['getIndex'](_0x4e856b),_0xe3443c=this['repository']['getIndex'](_0x3cf679);for(-0x1==_0xe3443c&&(_0xe3443c=this['repository']['_revisions']['length'],_0x588567=!0x1);_0x118503<_0xe3443c;)_0x5e6116['push'](this['repository']['getRevision'](_0x118503)),_0x118503++;return _0x588567&&_0x5e6116['push'](this['repository']['getRevision'](_0x118503)),_0x5e6116;}['_threeWayMerge'](_0x267261,_0x18f0fc,_0x22b537,_0x3d74ba){const _0x4d1e5e=this['editor']['model']['schema'];let _0x3c6eee=_0x18f0fc;for(;_0x267261[_0x3c6eee]&&_0x267261[_0x3c6eee]['isAdded'];)_0x3c6eee++;let _0x26a619=_0x3d74ba;for(;_0x22b537[_0x26a619]&&_0x22b537[_0x26a619]['isRemoved'];)_0x26a619++;_0x2ede18(_0x267261,_0x18f0fc,_0x3c6eee),_0x2ede18(_0x22b537,_0x3d74ba,_0x26a619);const _0x1508cc=_0x22b537['slice'](_0x3d74ba,_0x26a619)['concat'](_0x267261['slice'](_0x18f0fc,_0x3c6eee));return _0x1508cc['sort']((_0x2f7b08,_0x1bc8a1)=>_0x2f7b08['side']!=_0x1bc8a1['side']?_0x2f7b08['side']-_0x1bc8a1['side']:_0x2f7b08['level']!=_0x1bc8a1['level']?_0x2f7b08['level']-_0x1bc8a1['level']:_0x2f7b08['distance']!=_0x1bc8a1['distance']?_0x1bc8a1['distance']-_0x2f7b08['distance']:!!_0x2f7b08['isAdded']!=!!_0x1bc8a1['isAdded']?-0x1==_0x2f7b08['side']||0x0==_0x2f7b08['side']?_0x2f7b08['isAdded']?-0x1:0x1:_0x2f7b08['isAdded']?0x1:-0x1:_0x2f7b08['index']-_0x1bc8a1['index']),{'commonTape':_0x1508cc,'iEnd':_0x3c6eee,'jEnd':_0x26a619};function _0x2ede18(_0x1fdad5,_0x19e083,_0x1ba875){let _0x474ef4=-0x1,_0x43a0ee=Number['POSITIVE_INFINITY'],_0x3c008a=!0x0;for(let _0x5211ef=_0x19e083;_0x5211ef<_0x1ba875;_0x5211ef++)if(_0x4d1e5e['isInline'](_0x1fdad5[_0x5211ef]['item'])||(_0x3c008a=!0x1),_0x1fdad5[_0x5211ef]['item']['startIndex']<_0x19e083&&(_0x474ef4=_0x5211ef),_0x1fdad5[_0x5211ef]['item']['endIndex']>=_0x1ba875){_0x43a0ee=_0x5211ef;break;}_0x3c008a&&(_0x474ef4=_0x1ba875-0x1);for(let _0x226e0e=_0x19e083;_0x226e0e<_0x1ba875;_0x226e0e++)_0x1fdad5[_0x226e0e]['side']=_0x226e0e<=_0x474ef4?-0x1:_0x226e0e<_0x43a0ee?0x0:0x1,_0x1fdad5[_0x226e0e]['index']=_0x226e0e;let _0x25acb8=0x0;for(let _0x527a74=_0x19e083;_0x527a74<=_0x474ef4;_0x527a74++)0x0==_0x1fdad5[_0x527a74]['distance']?_0x1fdad5[_0x527a74]['level']=_0x25acb8:(_0x25acb8++,_0x1fdad5[_0x527a74]['level']=_0x25acb8,_0x25acb8++);for(let _0x281e6f=_0x19e083;_0x281e6f<_0x1ba875;_0x281e6f++)0x0==_0x1fdad5[_0x281e6f]['side']&&(_0x1fdad5[_0x281e6f]['level']=_0x25acb8);_0x25acb8=0x0;for(let _0x4ceb8f=_0x1ba875-0x1;_0x4ceb8f>=_0x43a0ee;_0x4ceb8f--)0x0==_0x1fdad5[_0x4ceb8f]['distance']?_0x1fdad5[_0x4ceb8f]['level']=_0x25acb8:(_0x25acb8--,_0x1fdad5[_0x4ceb8f]['level']=_0x25acb8,_0x25acb8--);}}['_fixObsoleteTags'](_0x5efcca){const _0x43e1b9=new Map(),_0x2074b1=this['editor']['model']['schema'];for(let _0xb84c3d=0x1;_0xb84c3d<_0x5efcca['length'];_0xb84c3d++){let _0x4b7d64,_0x5868a3,_0x110e33;const _0x261177=_0x5efcca[_0xb84c3d],_0x44a8ed=_0x5efcca[_0xb84c3d-0x1];if('text'==_0x261177['type'])continue;if(_0x261177['type']!=_0x44a8ed['type'])continue;if(!_0x2074b1['isBlock'](_0x44a8ed['item'])||_0x2074b1['isLimit'](_0x44a8ed['item']))continue;if(!_0x2074b1['isBlock'](_0x261177['item'])||_0x2074b1['isLimit'](_0x261177['item']))continue;if((_0x5efcca[_0xb84c3d]['isAdded']||_0x5efcca[_0xb84c3d]['isAddSuggestion'])&&_0x5efcca[_0xb84c3d-0x1]['isRemoved'])_0x4b7d64=_0x5efcca[_0xb84c3d],_0x5868a3=_0x5efcca[_0xb84c3d-0x1],_0x110e33=_0xb84c3d-0x1;else{if(!_0x5efcca[_0xb84c3d]['isRemoved']||!_0x5efcca[_0xb84c3d-0x1]['isAdded']&&!_0x5efcca[_0xb84c3d-0x1]['isAddSuggestion'])continue;_0x4b7d64=_0x5efcca[_0xb84c3d-0x1],_0x5868a3=_0x5efcca[_0xb84c3d],_0x110e33=_0xb84c3d;}const _0x1b07c4=_0x4b7d64['level']==_0x5868a3['level'],_0x2e9901=Math['abs'](_0x4b7d64['level'])<Math['abs'](_0x5868a3['level'])&&0x0==_0x5868a3['distance'];(_0x1b07c4||_0x2e9901)&&(_0x43e1b9['set'](_0x5868a3['id'],_0x4b7d64['id']),_0x5efcca['splice'](_0x110e33,0x1),_0xb84c3d--,_0x4b7d64['isAdded']=!0x1);}for(let _0x54a69c=0x0;_0x54a69c<_0x5efcca['length'];_0x54a69c++)_0x43e1b9['has'](_0x5efcca[_0x54a69c]['pairId'])&&(_0x5efcca[_0x54a69c]['pairId']=_0x43e1b9['get'](_0x5efcca[_0x54a69c]['pairId']));}['_removeMissingPairs'](_0x3fbcb3){const _0x39a1be=new Set(_0x3fbcb3['map'](_0x33f5e5=>_0x33f5e5['id']));for(let _0x883de1=0x0;_0x883de1<_0x3fbcb3['length'];_0x883de1++)_0x39a1be['has'](_0x3fbcb3[_0x883de1]['pairId'])||0x0==_0x3fbcb3[_0x883de1]['distance']||(_0x3fbcb3[_0x883de1]['isIncorrect']=!0x0);return _0x3fbcb3['filter'](_0xd70fa7=>!_0xd70fa7['isIncorrect']);}['_markMismatchedRemovedTags'](_0x26bc68){const _0x463936=new Set();for(let _0x36f680=0x0;_0x36f680<_0x26bc68['length'];_0x36f680++){if(_0x463936['has'](_0x26bc68[_0x36f680]['id'])&&_0x26bc68[_0x36f680]['isRemoved']&&(_0x26bc68[_0x36f680]['isIncorrect']=!0x0),_0x26bc68[_0x36f680]['isIncorrect'])continue;if(0x0==_0x26bc68[_0x36f680]['distance'])continue;if('elementStart'!=_0x26bc68[_0x36f680]['type'])continue;if(null==_0x26bc68[_0x36f680]['pairId'])continue;let _0x34a50a=_0x36f680+0x1,_0x28dea5=0x0;for(;_0x26bc68[_0x34a50a]['id']!=_0x26bc68[_0x36f680]['pairId'];)'elementStart'==_0x26bc68[_0x34a50a]['type']?_0x28dea5++:'elementEnd'==_0x26bc68[_0x34a50a]['type']&&_0x28dea5--,_0x34a50a++;if(0x0!=_0x28dea5){if(_0x26bc68[_0x36f680]['isRemoved'])_0x26bc68[_0x36f680]['isIncorrect']=!0x0;else{for(;_0x34a50a!=_0x36f680;)_0x26bc68[_0x34a50a]['isRemoved']&&0x0!=_0x26bc68[_0x34a50a]['distance']&&(_0x26bc68[_0x34a50a]['isIncorrect']=!0x0,_0x463936['add'](_0x26bc68[_0x34a50a]['pairId'])),_0x34a50a--;}}}return _0x26bc68['filter'](_0x41f678=>!_0x41f678['isIncorrect']);}['_removeUnsupportedChanges'](_0x4ccd6a){const _0x57c67b=this['editor']['model']['schema'];for(let _0x2238ee=0x0;_0x2238ee<_0x4ccd6a['length'];_0x2238ee++){if(!(_0x4ccd6a[_0x2238ee]['isAdded']||_0x4ccd6a[_0x2238ee]['isAddSuggestion']||_0x4ccd6a[_0x2238ee]['isRemoved']||_0x4ccd6a[_0x2238ee]['isRemoveSuggestion']))continue;if(0x0==_0x4ccd6a[_0x2238ee]['distance'])continue;const _0x16a028=_0x4ccd6a[_0x2238ee]['item'];_0x57c67b['isBlock'](_0x16a028)||_0x57c67b['isLimit'](_0x16a028)||(_0x4ccd6a[_0x2238ee]['isAdded']&&delete _0x4ccd6a[_0x2238ee]['isAdded'],_0x4ccd6a[_0x2238ee]['isAddSuggestion']&&delete _0x4ccd6a[_0x2238ee]['isAddSuggestion'],_0x4ccd6a[_0x2238ee]['isRemoveSuggestion']&&delete _0x4ccd6a[_0x2238ee]['isRemoveSuggestion'],_0x4ccd6a[_0x2238ee]['isRemoved']&&(_0x4ccd6a[_0x2238ee]['isIncorrect']=!0x0));}return _0x4ccd6a['filter'](_0x44bc51=>!_0x44bc51['isIncorrect']);}['_makeModelFromTape'](_0x57f7f1,_0x2845b6,_0x11935c){const _0x21ca2b=new _0x54d9b6(),_0x48c545=[],_0x436938=new Map(),_0xd20d0b=this['editor']['model'],_0x3b7bab=_0xd20d0b['schema'],_0x5393cd=[_0x21ca2b],_0x8a2479={},_0x59ef06={'isAdded':[],'isRemoved':[],'isAddSuggestion':[],'isRemoveSuggestion':[]};let _0x5935b4=null;const _0x542348=[0x0];for(let _0x309b6b=0x0;_0x309b6b<_0x57f7f1['length'];_0x309b6b++)if('elementStart'===_0x57f7f1[_0x309b6b]['type']){_0x57f7f1[_0x309b6b]['previousPosition']=_0xd20d0b['createPositionFromPath'](_0x21ca2b,_0x542348);const _0x6b4d3e=new _0x16738f(_0x57f7f1[_0x309b6b]['item']['name'],_0x57f7f1[_0x309b6b]['item']['getAttributes']());_0x5393cd[0x0]['_appendChild'](_0x6b4d3e),_0x542348['push'](0x0),_0x5393cd['unshift'](_0x6b4d3e),_0x57f7f1[_0x309b6b]['nextPosition']=_0xd20d0b['createPositionFromPath'](_0x21ca2b,_0x542348);}else'elementEnd'===_0x57f7f1[_0x309b6b]['type']?(_0x5393cd['shift'](),_0x57f7f1[_0x309b6b]['previousPosition']=_0xd20d0b['createPositionFromPath'](_0x21ca2b,_0x542348),_0x542348['pop'](),_0x542348[_0x542348['length']-0x1]++,_0x57f7f1[_0x309b6b]['nextPosition']=_0xd20d0b['createPositionFromPath'](_0x21ca2b,_0x542348)):(_0x57f7f1[_0x309b6b]['previousPosition']=_0xd20d0b['createPositionFromPath'](_0x21ca2b,_0x542348),_0x5935b4?_0x5935b4['_data']+=_0x57f7f1[_0x309b6b]['item']['data']:_0x5935b4=new _0x512a07(_0x57f7f1[_0x309b6b]['item']['data'],_0x57f7f1[_0x309b6b]['item']['getAttributes']()),_0x57f7f1[_0x309b6b+0x1]&&'text'===_0x57f7f1[_0x309b6b+0x1]['type']&&_0x171d49(_0x5935b4,_0x57f7f1[_0x309b6b+0x1]['item'])||(_0x5393cd[0x0]['_appendChild'](_0x5935b4),_0x5935b4=null),_0x542348[_0x542348['length']-0x1]+=_0x57f7f1[_0x309b6b]['item']['offsetSize'],_0x57f7f1[_0x309b6b]['nextPosition']=_0xd20d0b['createPositionFromPath'](_0x21ca2b,_0x542348));for(let _0x579517=0x0;_0x579517<_0x57f7f1['length'];_0x579517++){const _0x38360c=_0x57f7f1[_0x579517]['previousPosition'],_0x4a7151=_0x57f7f1[_0x579517]['nextPosition'];for(const _0x334e31 of _0x57f7f1[_0x579517]['markersStart'])_0x436938['set'](_0x334e31,{'start':_0x38360c,'end':null});_0x597433('isRemoveSuggestion',_0x579517,_0x38360c,_0x4a7151),_0x597433('isAddSuggestion',_0x579517,_0x38360c,_0x4a7151),_0x597433('isRemoved',_0x579517,_0x38360c,_0x4a7151),_0x597433('isAdded',_0x579517,_0x38360c,_0x4a7151);for(const _0x203273 of _0x57f7f1[_0x579517]['markersEnd']){const _0x41f014=_0x436938['get'](_0x203273);_0x41f014?_0x41f014['end']=_0x4a7151:_0x436938['set'](_0x203273,{'start':_0x4a7151,'end':_0x4a7151});}}for(const [_0x332e8b,_0xc231c5]of _0x436938){const _0x4e08fb=this['editor']['model']['createRange'](_0xc231c5['start'],_0xc231c5['end']);_0x21ca2b['markers']['set'](_0x332e8b,_0x4e08fb);}return _0x48c545['sort']((_0x4db0c8,_0x395b27)=>{const _0x102f8c=_0x21ca2b['markers']['get']('revision:'+_0x4db0c8['id']),_0x5be2cd=_0x21ca2b['markers']['get']('revision:'+_0x395b27['id']);return _0x102f8c['start']['isBefore'](_0x5be2cd['start'])?-0x1:_0x102f8c['start']['isAfter'](_0x5be2cd['start'])?0x1:_0x102f8c['end']['isBefore'](_0x5be2cd['end'])?-0x1:_0x102f8c['end']['isAfter'](_0x5be2cd['end'])?0x1:'add'===_0x4db0c8['type']?-0x1:0x1;}),{'root':_0x21ca2b,'changes':_0x48c545};function _0x597433(_0x5c4b99,_0x49093c,_0x44b319,_0x4a5fb3){const _0x924b3e=!!_0x57f7f1[_0x49093c][_0x5c4b99],_0x1c264a=_0x924b3e?_0x57f7f1[_0x49093c][_0x5c4b99]['userId']:null,_0x2b1327=_0x49093c===_0x57f7f1['length']-0x1,_0x1fff0c=_0x59ef06[_0x5c4b99][0x0],_0x4562be=_0x3b7bab['isObject'](_0x57f7f1[_0x49093c]['item']);!_0x8a2479[_0x5c4b99]&&_0x924b3e?_0x8a2479[_0x5c4b99]={'start':_0x44b319,'tapeItem':_0x57f7f1[_0x49093c],'userId':_0x1c264a,'type':_0x5c4b99}:_0x8a2479[_0x5c4b99]&&!_0x924b3e?(_0x8a2479[_0x5c4b99]['end']=_0x44b319,_0x9e8b75(_0x8a2479[_0x5c4b99]),_0x8a2479[_0x5c4b99]=null):_0x8a2479[_0x5c4b99]&&_0x924b3e&&_0x8a2479[_0x5c4b99]['userId']!==_0x1c264a&&(_0x8a2479[_0x5c4b99]['end']=_0x44b319,_0x1fff0c&&_0x1fff0c['userId']===_0x8a2479[_0x5c4b99]['userId']||_0x9e8b75(_0x8a2479[_0x5c4b99]),_0x8a2479[_0x5c4b99]={'start':_0x44b319,'tapeItem':_0x57f7f1[_0x49093c],'userId':_0x1c264a,'type':_0x5c4b99}),_0x8a2479[_0x5c4b99]&&_0x4562be&&('elementStart'!==_0x57f7f1[_0x49093c]['type']||_0x1fff0c&&_0x1fff0c['userId']===_0x1c264a||_0x59ef06[_0x5c4b99]['unshift']({'userId':_0x1c264a,'object':_0x57f7f1[_0x49093c]['item'],'change':_0x8a2479[_0x5c4b99]}),'elementEnd'===_0x57f7f1[_0x49093c]['type']&&_0x1fff0c&&_0x1fff0c['object']===_0x57f7f1[_0x49093c]['item']&&(_0x59ef06[_0x5c4b99]['shift'](),_0x8a2479[_0x5c4b99]=_0x1fff0c['change'])),_0x8a2479[_0x5c4b99]&&_0x2b1327&&(_0x8a2479[_0x5c4b99]['end']=_0x4a5fb3,_0x9e8b75(_0x8a2479[_0x5c4b99]),_0x8a2479[_0x5c4b99]=null);}function _0x9e8b75({start:_0x3ed919,end:_0x264e31,tapeItem:_0x17ab19,userId:_0x3ecb83,type:_0x113b09}){const _0x43b8b4=_0x17ab19['item'],_0x71df5c=_0xd20d0b['schema']['isBlock'](_0x43b8b4)&&!_0xd20d0b['schema']['isLimit'](_0x43b8b4),_0x42120b=_0x3ed919['nodeAfter']==_0x264e31['parent']&&_0x264e31['isAtStart'];if(_0x71df5c&&_0x42120b)return;const _0x2e122d=_0xd20d0b['createRange'](_0x3ed919,_0x264e31),_0x323162=_0x2845b6['get'](_0x3ecb83),_0x4bee4a=new G({'author':_0x323162,'type':'isAdded'==_0x113b09||'isAddSuggestion'==_0x113b09?'add':'remove','data':{'isSuggestion':'isAddSuggestion'==_0x113b09||'isRemoveSuggestion'==_0x113b09},'createdAt':new Date(),'rootName':_0x11935c});_0x48c545['push'](_0x4bee4a),_0x21ca2b['markers']['set']('revision:'+_0x4bee4a['id'],_0x2e122d);}function _0x171d49(_0x3b9577,_0x4748a1){const _0x5cb1a6=_0x3b9577['getAttributes'](),_0x273a1d=_0x4748a1['getAttributes']();for(const _0x5731ef of _0x5cb1a6){if(_0x5731ef[0x1]!==_0x4748a1['getAttribute'](_0x5731ef[0x0]))return!0x1;_0x273a1d['next']();}return _0x273a1d['next']()['done'];}}['_setConversion'](){this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision','view':_0x2af933=>{const _0x42b875=_0x2af933['markerName']['split'](':')[0x1],_0x54ad7f=this['_getChangeFromId'](_0x42b875);if(!_0x54ad7f)return null;const _0x540c56='add'==_0x54ad7f['type']?'insertion':'deletion',_0x46e3af=['ck-suggestion-marker','ck-suggestion-marker-'+_0x540c56];return _0x54ad7f['data']['isSuggestion']&&_0x46e3af['push']('ck-suggestion-marker-'+_0x540c56+'-new'),this['activeChange']==_0x54ad7f&&_0x46e3af['push']('ck-suggestion-marker--active'),{'classes':_0x46e3af,'attributes':{'data-change-id':_0x42b875}};}}),this['editor']['conversion']['for']('upcast')['add'](_0x46ac10=>{_0x46ac10['on']('element:pre',(_0x4fbc73,_0x1b6f33,_0x4a7b36)=>{const _0x4e44e0=_0x1b6f33['viewItem']['getChild'](0x0);if(!_0x4e44e0||!_0x4e44e0['is']('element','code'))return;if(!_0x4a7b36['consumable']['consume'](_0x4e44e0,{'attributes':['vid_start','vid_end']}))return;const _0x50678a=_0x1b6f33['modelRange']['start']['nodeAfter'];_0x4a7b36['writer']['setAttribute']('vid_start',_0x4e44e0['getAttribute']('vid_start'),_0x50678a),_0x4a7b36['writer']['setAttribute']('vid_end',_0x4e44e0['getAttribute']('vid_end'),_0x50678a);},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['add'](_0x41ff5b=>{_0x41ff5b['on']('element',(_0x1e40a9,_0x47d0e4,_0x119392)=>{if(!_0x119392['consumable']['consume'](_0x47d0e4['viewItem'],{'attributes':['vid_start','vid_end']}))return;if(_0x47d0e4['modelRange']['isCollapsed'])return;const _0x38f62b=_0x47d0e4['modelRange']['start']['nodeAfter'];_0x38f62b['hasAttribute']('vid_start')||_0x38f62b['hasAttribute']('vid')||(_0x119392['writer']['setAttribute']('vid_start',_0x47d0e4['viewItem']['getAttribute']('vid_start'),_0x38f62b),_0x119392['writer']['setAttribute']('vid_end',_0x47d0e4['viewItem']['getAttribute']('vid_end'),_0x38f62b));},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['elementToAttribute']({'view':{'name':'span','attributes':{'vid':!0x0}},'model':{'key':'vid','value':_0x126de4=>_0x126de4['getAttribute']('vid')}}),this['editor']['model']['schema']['on']('checkAttribute',(_0x2a56cb,[,_0x100797])=>{['vid_start','vid_end','vid']['includes'](_0x100797)&&(_0x2a56cb['return']=!0x0,_0x2a56cb['stop']());},{'priority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x10ce8e=>{_0x10ce8e['on']('attribute:vid',(_0x2fd259,_0x1de4e4,_0x5eba76)=>{if('\x20'!=_0x1de4e4['item']['data']||_0x1de4e4['item']['parent']['maxOffset']>0x1)return;if(!_0x5eba76['consumable']['consume'](_0x1de4e4['item'],_0x2fd259['name']))return;const _0x55ea14=_0x5eba76['writer'],_0x488c2f=_0x5eba76['mapper']['toViewRange'](_0x1de4e4['range']);_0x55ea14['wrap'](_0x488c2f,_0x55ea14['createAttributeElement']('span'));});}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',function(_0x35391e){const _0xc4dc79=_0x35391e['plugins']['get']('RevisionViewer');return(_0x25d742,_0x59f98c,_0x3c718b)=>{const _0x5afe0c=_0x59f98c['markerName']['split'](':')[0x1],_0x48e670=_0xc4dc79['_getChangeFromId'](_0x5afe0c);if(!_0x48e670)return null;const _0x3df566='add'==_0x48e670['type']?'split':'merge';if(!_0x3c718b['consumable']['test'](_0x59f98c['markerRange'],_0x25d742['name']))return;const _0x3b6ded=_0x59f98c['markerRange']['getWalker'](),_0x200874=_0x59f98c['markerRange']['start'],_0x302a57=_0x35391e['model']['schema'];let _0x1dd623=null,_0x3a497a=null,_0x5026db=!0x1,_0x5dfeff=!0x1;for(const _0x17c6a9 of _0x3b6ded){const _0x509af9=_0x17c6a9['item'];_0x5026db=_0x5026db||_0x302a57['isContent'](_0x509af9);const _0x5ac0ca=_0x3c718b['mapper']['toViewElement'](_0x509af9);if(_0x5ac0ca&&_0x5ac0ca['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x17c6a9['type']&&(_0x302a57['isBlock'](_0x509af9)&&!_0x302a57['isLimit'](_0x509af9)&&(_0x509af9['nextSibling']||_0x200874['isAtEnd']?_0x1dd623&&_0x1dd623['parent']==_0x509af9||(_0x1dd623=_0x509af9,_0x3016ac(_0x17c6a9['previousPosition']),_0x5dfeff=!0x0):_0x3a497a=_0x3a497a||_0x17c6a9['previousPosition']));}function _0x3016ac(_0x53adf5){const _0x13a203=_0x3c718b['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x3df566}),_0x146d1d=_0x3c718b['mapper']['toViewPosition'](_0x53adf5);_0x48e670['data']['isSuggestion']&&_0x3c718b['writer']['addClass']('ck-suggestion-marker-'+_0x3df566+'-new',_0x13a203),_0xc4dc79['activeChange']==_0x48e670&&_0x3c718b['writer']['addClass']('ck-suggestion-marker--active',_0x13a203),_0x3c718b['writer']['insert'](_0x146d1d,_0x13a203),_0x3c718b['mapper']['bindElementToMarker'](_0x13a203,_0x59f98c['markerName']);}_0x5026db||_0x5dfeff||!_0x3a497a||_0x3016ac(_0x3a497a);};}(this['editor']),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision',(_0x3ab62f,_0x2aaf64,_0x5c2a0)=>{const _0x3fa350=_0x5c2a0['mapper']['markerNameToElements'](_0x2aaf64['markerName']);if(_0x3fa350){for(const _0x59d318 of _0x3fa350)(_0x59d318['hasClass']('ck-suggestion-marker-split')||_0x59d318['hasClass']('ck-suggestion-marker-merge'))&&(_0x5c2a0['mapper']['unbindElementFromMarkerName'](_0x59d318,_0x2aaf64['markerName']),_0x5c2a0['writer']['remove'](_0x59d318));}},{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',(_0x23ce47,_0x3755c6,_0x5c078b)=>{const _0x19629d=_0x3755c6['markerName']['split'](':')[0x1],_0x21344c=this['_getChangeFromId'](_0x19629d);if(!_0x21344c)return null;const _0x5cb4ab='add'==_0x21344c['type']?'split':'merge';if(_0x5c078b['consumable']['test'](_0x3755c6['markerRange'],_0x23ce47['name']))for(const _0x2e54b7 of _0x3755c6['markerRange']['getItems']()){if(!_0x2e54b7['is']('element','softBreak'))continue;const _0x34825c=_0x5c078b['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x5cb4ab}),_0x5c9b69=_0x5c078b['mapper']['toViewPosition'](this['editor']['model']['createPositionBefore'](_0x2e54b7));_0x21344c['data']['isSuggestion']&&_0x5c078b['writer']['addClass']('ck-suggestion-marker-'+_0x5cb4ab+'-new',_0x34825c),this['activeChange']==_0x21344c&&_0x5c078b['writer']['addClass']('ck-suggestion-marker--active',_0x34825c),_0x5c078b['writer']['insert'](_0x5c9b69,_0x34825c),_0x5c078b['mapper']['bindElementToMarker'](_0x34825c,_0x3755c6['markerName']);}},{'priority':'high'}),this['editor']['model']['document']['on']('change',()=>{this['editor']['editing']['view']['change'](_0x8447bd=>{for(const _0x6c09a0 of this['editor']['model']['document']['getRootNames']()){const _0x3d3a33=this['editor']['model']['document']['getRoot'](_0x6c09a0),_0x46def6=this['editor']['editing']['view']['document']['getRoot'](_0x6c09a0);if(_0x46def6){const _0x3428f8=_0x3d3a33['getAttribute']('revisionHistoryAttachChange');if(_0x8447bd['removeAttribute']('data-change-id',_0x46def6),_0x8447bd['removeClass']('ck-revision-history-root-add',_0x46def6),_0x8447bd['removeClass']('ck-revision-history-root-remove',_0x46def6),_0x8447bd['removeClass']('ck-revision-history-root--active',_0x46def6),_0x3428f8){const _0x55d0ea=this['_getChangeFromId'](_0x3428f8);if(!_0x55d0ea)return null;_0x8447bd['setAttribute']('data-change-id',_0x3428f8,_0x46def6),_0x8447bd['addClass']('ck-revision-history-root-'+_0x55d0ea['type'],_0x46def6),this['activeChange']==_0x55d0ea&&_0x8447bd['addClass']('ck-revision-history-root--active',_0x46def6);}}}});}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'comment','model':_0x79c20f=>'revision-comment:'+_0x79c20f,'converterPriority':'highest'}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'suggestion','model':_0x1afec6=>'revision-suggestion:'+_0x1afec6,'converterPriority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision-suggestion','view':_0x4ae412=>({'name':'suggestion:'+_0x4ae412,'group':'revision-suggestion'}),'converterPriority':'highest'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision-suggestion','view':_0x58adba=>{const _0x18fd41=_0x58adba['markerName']['split'](':')[0x1];return'insertion'!=_0x18fd41&&'deletion'!=_0x18fd41?null:{'classes':['ck-suggestion-preview-marker','ck-suggestion-preview-marker-'+_0x18fd41]};}}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:deletion',Q(this['editor'],'merge'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:insertion',Q(this['editor'],'split'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision-suggestion',(_0xf9d56f,_0x31b8f9,_0x803614)=>{const _0x168c02=_0x803614['mapper']['markerNameToElements'](_0x31b8f9['markerName']);if(_0x168c02){for(const _0x3b2db6 of _0x168c02)_0x3b2db6['is']('uiElement')&&(_0x803614['mapper']['unbindElementFromMarkerName'](_0x3b2db6,_0x31b8f9['markerName']),_0x803614['writer']['remove'](_0x3b2db6));}},{'priority':'high'});}['_getChangeFromId'](_0x2918d8){return this['_changeIdToChange']['get'](_0x2918d8);}['_getViewForChange'](_0x3c5d7e){return this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=new z(this['editor']['locale'],_0x3c5d7e),this['_changeView'];}['_initInteractions'](){this['editor']['model']['document']['selection']['observeMarkers']('revision'),this['on']('change:activeView',(_0x39e512,_0xfb19f8,_0x43dfa8,_0x48aae7)=>{_0x48aae7&&this['_balloon']['remove'](_0x48aae7),_0x43dfa8&&(this['_balloon']['add']({'view':_0x43dfa8,'stackId':'revisionHistoryLabel','position':{'target':()=>{const _0x45088d=this['editor']['editing'],_0x20400c=this['_getChangeFromId'](_0x43dfa8['changeId']);let _0x1c3612;if(_0x20400c['data']['isOnRoot']){const _0x37d0b9=_0x45088d['view']['getDomRoot'](_0x20400c['rootName']);_0x1c3612=Array['from'](_0x37d0b9['getClientRects']());}else{const _0x56dc4a=this['editor']['model']['markers']['get']('revision:'+_0x43dfa8['changeId']);_0x1c3612=Array['from'](_0x45088d['mapper']['markerNameToElements'](_0x56dc4a['name']))['map'](_0x19263e=>_0x45088d['view']['domConverter']['mapViewToDom'](_0x19263e))['map'](_0x3d25f6=>Array['from'](_0x3d25f6['getClientRects']()))['flat']();}if(!this['_activeViewTarget'])return _0x1c3612[0x0];return _0x1c3612['find'](_0x3d8eb5=>_0x3d8eb5['top']-0x3<=this['_activeViewTarget']['y']&&_0x3d8eb5['bottom']+0x3>=this['_activeViewTarget']['y']&&_0x3d8eb5['left']-0x3<=this['_activeViewTarget']['x']&&_0x3d8eb5['right']+0x3>=this['_activeViewTarget']['x'])||_0x1c3612[0x0];}}}),this['_balloon']['showStack']('revisionHistoryLabel'));}),this['on']('change:activeChange',(_0x4d9f35,_0x45ca22,_0x17ba6c,_0x48ba57)=>{this['activeView']=_0x17ba6c?this['_getViewForChange'](_0x17ba6c):null,this['editor']['model']['change'](()=>{const _0x4916ef=this['editor']['editing'];_0x48ba57&&(_0x48ba57['data']['isOnRoot']?_0x4916ef['view']['change'](_0x1e215f=>{_0x1e215f['removeClass']('ck-revision-history-root--active',_0x4916ef['view']['document']['getRoot'](_0x48ba57['rootName']));}):_0x4916ef['reconvertMarker']('revision:'+_0x48ba57['id'])),_0x17ba6c&&(_0x17ba6c['data']['isOnRoot']?_0x4916ef['view']['change'](_0x5b8b2e=>{_0x5b8b2e['addClass']('ck-revision-history-root--active',_0x4916ef['view']['document']['getRoot'](_0x17ba6c['rootName']));}):_0x4916ef['reconvertMarker']('revision:'+_0x17ba6c['id']));});}),this['listenTo'](this['editor']['editing']['view']['document'],'mouseover',(_0x426ed1,_0x144724)=>{if(this['activeChange'])return;const _0x2b3c9a=this['_findChangeIdFromDomTarget'](_0x144724['target']),_0x3cfce6=this['_changeIdToChange']['get'](_0x2b3c9a);_0x3cfce6?(this['_activeViewTarget']={'x':_0x144724['domEvent']['x'],'y':_0x144724['domEvent']['y']},this['activeView']=this['_getViewForChange'](_0x3cfce6)):(this['_activeViewTarget']=null,this['activeView']=null);}),this['listenTo'](this['editor']['editing']['view']['document'],'mousedown',(_0x291795,_0xfe2176)=>{const _0x1ffb45=this['_findChangeIdFromDomTarget'](_0xfe2176['target']),_0x25c8f5=this['_changeIdToChange']['get'](_0x1ffb45);_0x25c8f5?(this['_activeViewTarget']={'x':_0xfe2176['domEvent']['x'],'y':_0xfe2176['domEvent']['y']},_0x25c8f5===this['activeChange']?this['_balloon']['updatePosition']():this['activeChange']=_0x25c8f5):(this['_activeViewTarget']=null,this['activeChange']=null);});}['_findChangeIdFromDomTarget'](_0x10744f){do{const _0x125567=_0x10744f['getAttribute']('data-change-id');if(_0x125567)return _0x125567;_0x10744f=_0x10744f['parent'];}while(_0x10744f);return null;}['_cleanMarkers'](){this['editor']['model']['change'](_0xd2a6ee=>{for(const _0x6e3095 of this['editor']['model']['markers'])_0xd2a6ee['removeMarker'](_0x6e3095);});}}function Q(_0x2ec7a2,_0x24d765){return(_0x4d542b,_0x4b68d0,_0x241450)=>{if(!_0x241450['consumable']['test'](_0x4b68d0['markerRange'],_0x4d542b['name']))return;const _0x55cd8d=_0x4b68d0['markerRange']['getWalker'](),_0x1d834c=_0x4b68d0['markerRange']['start'],_0x4f8c3d=_0x2ec7a2['model']['schema'];let _0x38a66b=null,_0x171073=null,_0x5ad4c0=!0x1,_0x33d661=!0x1;for(const _0x793771 of _0x55cd8d){const _0x1c3da8=_0x793771['item'];_0x5ad4c0=_0x5ad4c0||_0x4f8c3d['isContent'](_0x1c3da8);const _0x5c5906=_0x241450['mapper']['toViewElement'](_0x1c3da8);if(_0x5c5906&&_0x5c5906['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x793771['type']&&(_0x4f8c3d['isBlock'](_0x1c3da8)&&!_0x4f8c3d['isLimit'](_0x1c3da8)&&(_0x1c3da8['nextSibling']||_0x1d834c['isAtEnd']?_0x38a66b&&_0x38a66b['parent']==_0x1c3da8||(_0x38a66b=_0x1c3da8,_0x98a991(_0x793771['previousPosition']),_0x33d661=!0x0):_0x171073=_0x171073||_0x793771['previousPosition']));}function _0x98a991(_0x1a864d){const _0x3c0100=_0x241450['mapper']['toViewPosition'](_0x1a864d),_0x5e730d=_0x241450['writer']['createUIElement']('span',{'class':'ck-suggestion-preview-marker-'+_0x24d765});_0x241450['writer']['insert'](_0x3c0100,_0x5e730d),_0x241450['mapper']['bindElementToMarker'](_0x5e730d,_0x4b68d0['markerName']);}_0x5ad4c0||_0x33d661||!_0x171073||_0x98a991(_0x171073);};}class nt extends _0x5998c4{constructor(_0x3f7260){super(_0x3f7260);const _0xbdb0de=_0x3f7260['plugins']['get'](u);this['affectsData']=!0x1,this['listenTo'](_0xbdb0de,'change:isReady',()=>this['refresh']()),this['listenTo'](_0xbdb0de,'change:isEnabled',()=>this['refresh']());}['execute'](){const _0x276c46=this['editor'],_0xb85b2c=_0x276c46['plugins']['get'](u),_0x585799=_0xb85b2c['isReady']?_0xb85b2c['diff']['newRevisionId']:null;_0x276c46['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x585799);}['refresh'](){const {isReady:_0x3c7079,isEnabled:_0x1b7853,repository:_0xd10d40,diff:_0x2a77ff}=this['editor']['plugins']['get'](u),_0x49b4ca=_0x2a77ff&&_0xd10d40['getLaterVisibleRevision'](_0x2a77ff['newRevisionId']);this['isEnabled']=_0x3c7079&&_0x1b7853&&Boolean(_0x49b4ca);}}class rt extends _0x5998c4{['_step'];constructor(_0x25ceda,{direction:_0x5f07ea}){super(_0x25ceda);const _0x4438f6=_0x25ceda['plugins']['get'](u);this['affectsData']=!0x1,this['_step']='forward'===_0x5f07ea?0x1:-0x1,this['listenTo'](_0x4438f6,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x4438f6,'change:isEnabled',()=>this['refresh']()),this['listenTo'](_0x4438f6,'change:activeChange',()=>this['refresh']());}['execute'](){const _0x5add53=this['editor'],_0x58368e=_0x5add53['plugins']['get'](u),{isNavigationMode:_0xe0d132,currentChangeNumber:_0x392263}=_0x58368e;let _0xd566a0;if(_0x58368e['activeChange']=_0xe0d132?_0x58368e['diff']['changes']['get'](_0x392263+this['_step']):_0x58368e['diff']['changes']['first'],_0x58368e['activeChange']['data']['isOnRoot'])_0xd566a0=_0x5add53['editing']['view']['getDomRoot'](_0x58368e['activeChange']['rootName']);else{const _0xdfafe2=_0x5add53['model']['markers']['get']('revision:'+_0x58368e['activeChange']['id']);_0xd566a0=_0x637378(_0x5add53['editing'],_0xdfafe2);}_0x18268f({'target':_0xd566a0,'viewportOffset':0x28});}['refresh'](){const {isNavigationMode:_0x2cf036,currentChangeNumber:_0x21379f,numberOfChanges:_0x23d3d7,isReady:_0x545713,isEnabled:_0x498d0e}=this['editor']['plugins']['get'](u);this['isEnabled']=!!(_0x498d0e&&_0x545713&&_0x23d3d7)&&(!_0x2cf036||(0x1===this['_step']?_0x21379f<_0x23d3d7-0x1:_0x21379f>0x0));}}class fi extends _0x484abd{constructor(_0x5bec56){super(_0x5bec56);const _0x596aa8=this['bindTemplate'],_0x38f9e4=new _0x14152c(_0x5bec56),_0x1288e9=new _0x14152c(_0x5bec56);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',(_0x9abb41,_0x5cd7d4)=>_0x9abb41&&_0x5cd7d4>0x0),this['bind']('_statusText')['to'](this,'isReady',this,'currentChangeNumber',this,'numberOfChanges',this,'isNavigationMode',(_0x3a0138,_0x22d03a,_0x3faa32,_0x47f98c)=>{if(!_0x3a0138)return m(_0x5bec56,'Loading...');if(!_0x3faa32)return m(_0x5bec56,'No\x20changes');const _0x3f3757=m(_0x5bec56,'NUMBER_OF_CHANGES',_0x3faa32);return _0x47f98c?m(_0x5bec56,'X_OF_Y_CHANGES',[_0x22d03a+0x1,_0x3faa32]):_0x3f3757;}),_0x38f9e4['set']({'label':m(_0x5bec56,'Show\x20previous\x20change'),'tooltip':!0x0,'icon':_0x5308cd}),_0x1288e9['set']({'label':m(_0x5bec56,'Show\x20next\x20change'),'tooltip':!0x0,'icon':_0x5f0511}),_0x38f9e4['bind']('isEnabled')['to'](this,'isBackwardNavigationEnabled'),_0x1288e9['bind']('isEnabled')['to'](this,'isForwardNavigationEnabled'),_0x38f9e4['on']('execute',()=>this['fire']('execute','backward')),_0x1288e9['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',_0x596aa8['if']('_isStatusLabelVisible','ck-hidden',_0x429cea=>!_0x429cea)]},'children':[{'text':_0x596aa8['to']('isNavigationMode',_0x58b715=>_0x58b715?m(_0x5bec56,'EDIT_X_OF_Y_REVISIONS')+':\x20':m(_0x5bec56,'Total')+':\x20')}]},{'text':_0x596aa8['to']('_statusText')}]},new _0x3f7943(),{'tag':'div','attributes':{'class':['ck-revision-history-ui__changes-navigation__navigation']},'children':[_0x38f9e4,_0x1288e9]}]});}}const ge='ck-editor__editable__loading-overlay';class bi extends _0x59afc0{static get['pluginName'](){return'RevisionViewerLoadingOverlay';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['show'](){const _0x390dd0=this['editor']['editing']['view'];_0x390dd0['change'](_0x4f0da6=>{for(const _0x266efd of _0x390dd0['document']['roots'])_0x4f0da6['addClass'](ge,_0x266efd);});}['hide'](){const _0x5317e1=this['editor']['editing']['view'];_0x5317e1['change'](_0x22319b=>{for(const _0x73319b of _0x5317e1['document']['roots'])_0x22319b['removeClass'](ge,_0x73319b);});}}class v extends _0x59afc0{static get['pluginName'](){return'RevisionViewerUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[u,bi];}['init'](){const _0x559f02=this['editor'],_0xffc4b6=_0x559f02['plugins']['get'](u),_0x2030cb=_0x559f02['plugins']['get'](bi);_0x559f02['ui']['componentFactory']['add']('exitToEditing',_0xeb26c1=>{const _0x12782e=new _0x14152c(_0xeb26c1);return _0x12782e['set']({'label':m(_0xeb26c1,'Back\x20to\x20editing'),'icon':_0x4ed6d9,'withText':!0x0,'tooltip':!0x0,'class':'ck-revision-history-ui__back-to-editing'}),this['listenTo'](_0x12782e,'execute',()=>{_0x559f02['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}),_0x12782e;}),_0x559f02['ui']['componentFactory']['add']('restoreRevision',_0x4b27a8=>{const _0x8e341e=new _0x14152c(_0x4b27a8);return _0x8e341e['set']({'label':m(_0x4b27a8,'Restore\x20this\x20revision'),'withText':!0x0,'tooltip':!0x0}),_0x8e341e['bind']('isEnabled')['to'](_0x559f02['commands']['get']('restoreRevision')),this['listenTo'](_0x8e341e,'execute',()=>_0x559f02['execute']('restoreRevision')),_0x8e341e;}),_0x559f02['ui']['componentFactory']['add']('changesNavigation',_0x824b93=>{const _0x4cfe81=new fi(_0x824b93),_0x18add0=_0x559f02['commands']['get']('showPreviousChange'),_0x49efaa=_0x559f02['commands']['get']('showNextChange');return _0x4cfe81['bind']('isBackwardNavigationEnabled')['to'](_0x18add0,'isEnabled'),_0x4cfe81['bind']('isForwardNavigationEnabled')['to'](_0x49efaa,'isEnabled'),_0x4cfe81['bind']('isReady','currentChangeNumber','numberOfChanges','isNavigationMode')['to'](_0xffc4b6),this['listenTo'](_0x4cfe81,'execute',(_0x4c4ced,_0x4382aa)=>{_0x559f02['execute']('forward'===_0x4382aa?'showNextChange':'showPreviousChange');}),_0x4cfe81;}),_0x2030cb['show'](),_0xffc4b6['on']('change:isReady',(_0x2f5dc8,_0x102b1a,_0x3330e5)=>{_0x3330e5?_0x2030cb['hide']():_0x2030cb['show']();});}}class hi extends et{['_resizeObserver']=null;constructor(_0x496108,_0x507927){super(_0x496108,_0x507927);const _0x554489=this['bindTemplate'];this['set']({'label':m(_0x496108,'Revision\x20name'),'_tooltipString':''}),this['fieldView']['placeholder']=m(_0x496108,'Enter\x20the\x20revision\x20name'),this['extendTemplate']({'tag':'span','attributes':{'class':['ck-revision-history-sidebar__revision-name'],'data-cke-tooltip-text':_0x554489['to']('_tooltipString'),'data-cke-tooltip-position':'s','data-cke-tooltip-class':'ck-tooltip_multi-line'}});}['render'](){super['render'](),this['_resizeObserver']=new ot(this['fieldView']['element'],()=>this['_updateTooltipText']()),this['listenTo'](this['fieldView'],'input',()=>this['_updateTooltipText']());}['destroy'](){super['destroy'](),this['_resizeObserver']&&this['_resizeObserver']['destroy']();}['_updateTooltipText'](){const _0x8f87dc=this['fieldView']['element'];this['_tooltipString']=_0x8f87dc['scrollWidth']>_0x8f87dc['clientWidth']&&_0x8f87dc['value']||'';}}class ni extends _0x484abd{constructor(_0x2d0302,_0x1d18de,_0x152559){super(_0x2d0302);const _0x5325ec=new _0x1ed09d();_0x5325ec['set']({'content':_0x2f44bd,'viewBox':'0\x200\x2011\x2010'});const _0x3cb405=['ck','ck-revision-history-sidebar__revision-author'];_0x152559&&_0x3cb405['push']('ck-revision-history-sidebar__revision-author_creator');const _0x420e16=[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision-author__name'],'title':m(_0x2d0302,_0x152559?'Revision\x20creator':'Revision\x20author')},'children':[_0x5325ec,_0x1d18de['name']]}];this['setTemplate']({'tag':'li','attributes':{'class':_0x3cb405},'children':_0x420e16});}}function ai(_0x24ca1d,_0x55c6a1){const _0x19657c=_0x24ca1d['bindTemplate'],_0x1ff376=_0x24ca1d['locale'],_0x216ee6=_0x1cb51d(_0x1ff376);_0x216ee6['panelPosition']='sw';const _0x4a1cbc=function(_0x1562dc,_0x58b497){const _0x5b317c=function(_0x36f4e3,_0x9b7bb5){const _0x3f871c=_0x36f4e3['locale'],_0x4ddcd5={'Compare\x20against\x20selected':m(_0x3f871c,'Compare\x20against\x20selected'),'Name\x20this\x20revision':m(_0x3f871c,'Name\x20this\x20revision'),'Restore\x20this\x20revision':m(_0x3f871c,'Restore\x20this\x20revision')};return _0x9b7bb5['map'](_0x1c32e4=>{const _0x7d1d9f=_0x4ddcd5[_0x1c32e4['name']];return _0x7d1d9f&&_0x7d1d9f!==_0x1c32e4['name']&&(_0x1c32e4['name']=_0x7d1d9f),_0x1c32e4;});}(_0x1562dc,_0x58b497),_0x54ea14=new _0x51dee5();for(const _0x532855 of _0x5b317c){const _0xf0e0={'type':'button','model':new to({'label':_0x532855['name'],'class':_0x532855['class'],'withText':!0x0,'role':'menuitem','_action':_0x532855['action']})};_0xf0e0['model']['bind']('isEnabled')['to'](_0x1562dc,'isActionsDropdownOpen',_0x231e8e=>'function'!=typeof _0x532855['isEnabled']||(!_0x231e8e||_0x532855['isEnabled'](_0x1562dc))),_0x54ea14['add'](_0xf0e0);}return _0x54ea14;}(_0x24ca1d,_0x55c6a1);return _0x24ca1d['bind']('isActionsDropdownOpen')['to'](_0x216ee6,'isOpen'),_0x216ee6['buttonView']['set']({'label':m(_0x1ff376,'Show\x20more\x20items'),'tooltip':!0x0,'tooltipPosition':'sw','icon':_0x516c19}),_0x216ee6['extendTemplate']({'attributes':{'class':['ck-revision-history-sidebar__revision__actions',_0x19657c['if']('isActionsDropdownOpen','ck-on')]},'on':{'click':_0x19657c['to'](_0xddf6d2=>_0xddf6d2['stopPropagation']())}}),_0x216ee6['on']('execute',_0x4cc6b3=>{_0x24ca1d['isReady']&&'function'==typeof _0x4cc6b3['source']['_action']&&_0x4cc6b3['source']['_action'](_0x24ca1d);}),_0x189f45(_0x216ee6,_0x4a1cbc,{'role':'menu'}),_0x216ee6['listenTo'](_0x24ca1d,'change:isActionsDropdownOpen',(_0x4b3d05,_0x35966f,_0x4fc83d)=>{if(_0x4fc83d)for(const _0x1a1571 of _0x216ee6['listView']['items']){const _0x2eaa7c=_0x1a1571['children']['first'],_0x3b82d0=_0x55c6a1['find'](_0x400fa0=>_0x400fa0['action']===_0x2eaa7c['_action'])['isVisible'];_0x1a1571['isVisible']=void 0x0===_0x3b82d0||_0x3b82d0(_0x24ca1d);}}),_0x216ee6;}class _i extends/* #__PURE__ -- @preserve */
|
|
27
|
+
_0x432988(_0x484abd){['id'];['revisionNameView'];['revisionActionsView'];['_revision'];['_requireRevisionName'];constructor(_0x41b9b5,_0x1b7d58,_0x58975d,_0x37fb67){super(_0x41b9b5);const _0xe31df9=this['bindTemplate'],_0x305c92=function(_0x3678f9,_0x502b26){const _0x214781=Array['from'](_0x502b26['authors'])['filter'](_0xd320b2=>_0xd320b2!=_0x502b26['creator']);return _0x502b26['creator']&&_0x214781['unshift'](_0x502b26['creator']),_0x214781['map'](_0x1b2578=>new ni(_0x3678f9,_0x1b2578,_0x1b2578==_0x502b26['creator']));}(_0x41b9b5,_0x1b7d58);this['id']=_0x1b7d58['id'],this['_revision']=_0x1b7d58,this['_requireRevisionName']=_0x37fb67,this['bind']('name','createdAt')['to'](_0x1b7d58),this['bind']('_createdAtFormatted')['to'](this,'createdAt',_0xcfa444=>{return _0x1f5114=_0x41b9b5['uiLanguage'],(_0x17d6f1=_0xcfa444)['toLocaleDateString'](_0x1f5114,{'month':'long','day':'numeric'})+',\x20'+_0x17d6f1['toLocaleTimeString'](_0x1f5114,{'hour':'numeric','minute':'numeric'});var _0x1f5114,_0x17d6f1;}),this['set']('isSelected',!0x1),this['set']('isHighlighted',!0x1),this['set']('isActionsDropdownOpen',!0x1),this['set']('isReady',!0x1),this['set']('isEnabled',!0x1),this['revisionNameView']=new hi(_0x41b9b5,ti),this['revisionNameView']['fieldView']['extendTemplate']({'attributes':{'maxlength':'220'}}),this['revisionNameView']['fieldView']['bind']('value')['to'](this,'name',_0x238518=>_0x238518||this['_createdAtFormatted']),this['revisionNameView']['bind']('isEnabled')['to'](this,'isSelected',this,'isEnabled',(_0xa2b87a,_0x1df94c)=>_0xa2b87a&&_0x1df94c),this['revisionActionsView']=_0x58975d&&_0x58975d['length']?ai(this,_0x58975d):'',this['revisionActionsView']&&this['revisionActionsView']['bind']('isEnabled')['to'](this),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision-wrapper',_0xe31df9['if']('isConfirm','ck-revision-history-sidebar__revision-wrapper_confirmation_visible')]},'children':[{'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision',_0xe31df9['if']('isEnabled','ck-disabled',_0x34b9cf=>!_0x34b9cf),_0xe31df9['if']('isSelected','ck-revision-history-sidebar__revision_selected'),_0xe31df9['if']('isHighlighted','ck-revision-history-sidebar__revision_highlighted'),_0xe31df9['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':_0xe31df9['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':_0x305c92}]},this['revisionActionsView']],'on':{'click':_0xe31df9['to'](_0x539068=>{_0x539068['srcElement']['closest']('.ck-confirm-view')||this['isReady']&&this['isEnabled']&&this['fire']('select',{'id':this['id']});})}}]});}['render'](){super['render']();const _0x5560d7=this['revisionNameView']['fieldView']['element'];this['listenTo'](_0x5560d7,'change',()=>{this['_requireRevisionName']&&!_0x5560d7['value']||this['fire']('setName',{'id':this['id'],'name':_0x5560d7['value']}),_0x5560d7['value']||(_0x5560d7['value']=this['name']?this['name']:this['_createdAtFormatted']);});}['select'](){this['isSelected']=!0x0;}['deselect'](){this['isSelected']=!0x1;}['highlight'](){this['isHighlighted']=!0x0;}['unhighlight'](){this['isHighlighted']=!0x1;}}function ki(_0x2481be,_0x1be861){const _0x6c81df=_0x2c8e9e['fromJSDate'](_0x2481be)['setLocale'](_0x1be861),_0x142a2a=_0x2c8e9e['local'](),_0x3c5213=_0x142a2a['minus']({'days':0x1})['startOf']('day');let _0x4af708,_0x82319f;return _0x6c81df['hasSame'](_0x142a2a,'day')?(_0x4af708=_0x6c81df['startOf']('day')['toJSDate'](),_0x82319f=_0x6c81df['toRelativeCalendar']()):_0x6c81df['hasSame'](_0x3c5213,'day')?(_0x4af708=_0x3c5213['toJSDate'](),_0x82319f=_0x6c81df['toRelativeCalendar']()):_0x6c81df['hasSame'](_0x142a2a,'week')?(_0x4af708=_0x6c81df['startOf']('week')['toJSDate'](),_0x82319f=_0x6c81df['weekdayLong']||''):_0x6c81df['hasSame'](_0x142a2a,'year')?(_0x4af708=_0x6c81df['startOf']('month')['toJSDate'](),_0x82319f=_0x6c81df['monthLong']||''):(_0x4af708=_0x6c81df['startOf']('year')['toJSDate'](),_0x82319f=String(_0x6c81df['year'])),{'startDate':_0x4af708,'localizedPeriodName':_0x82319f};}class ji extends _0x484abd{['startDate'];['revisionViews'];['_revisionActions'];['_requireRevisionName'];constructor(_0x5b1b37,_0x16c9b8,_0x262bf7,_0x401039){super(_0x5b1b37);const _0x1f6afa=ki(_0x16c9b8,this['locale']['uiLanguage'])['localizedPeriodName'];this['startDate']=_0x16c9b8,this['revisionViews']=this['createCollection'](),this['_revisionActions']=_0x262bf7,this['_requireRevisionName']=_0x401039,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':_0x1f6afa}]},{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__time-period__revisions']},'children':this['revisionViews']}]});}['addRevision'](_0x1915f4){const _0x1dede3=new _i(this['locale'],_0x1915f4,this['_revisionActions'],this['_requireRevisionName']);this['revisionViews']['add'](_0x1dede3);}['removeRevision'](_0x1f4030){const _0x224558=this['revisionViews']['find'](_0x261bc1=>_0x261bc1['id']===_0x1f4030['id']);this['revisionViews']['remove'](_0x224558);}}class Ni extends _0x484abd{constructor(_0x42de2d){super(_0x42de2d);const _0x1bb89c=new _0x1ed09d();_0x1bb89c['content']=_0x58c189,this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset_all','ck-revision-history-sidebar__header']},'children':[_0x1bb89c,{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__header__label']},'children':[m(_0x42de2d,'Revision\x20history')]}]});}}class Ri extends _0x484abd{['timePeriodViews'];['_revisions'];['_revisionActions'];['_requireRevisionName'];constructor(_0x18c826,_0x495118,_0x29d3e1,_0x185b70){super(_0x18c826);const _0x380ca7=this['bindTemplate'];this['timePeriodViews']=this['createCollection'](),this['timePeriodViews']['delegate']('select')['to'](this),this['timePeriodViews']['delegate']('setName')['to'](this),this['_revisions']=_0x495118,this['_revisionActions']=_0x29d3e1,this['_requireRevisionName']=_0x185b70,this['on']('select',(_0x2f0cd8,_0x30d995)=>{this['fire']('revisionSelected',_0x30d995);}),this['on']('setName',(_0x17ba29,_0x578f27)=>{this['fire']('revisionSetName',_0x578f27);}),this['set']('isEnabled',!0x1),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-rounded-corners','ck-revision-history-sidebar']},'children':[new Ni(_0x18c826),{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__timeline',_0x380ca7['if']('isEnabled','ck-disabled',_0xdb47e4=>!_0xdb47e4)]},'children':this['timePeriodViews']}]});}['render'](){super['render']();for(const _0x2fa126 of this['_revisions'])this['_addRevision'](_0x2fa126);this['_revisions']['on']('add',(_0x5e2456,_0x6720b3)=>{this['_addRevision'](_0x6720b3);}),this['_revisions']['on']('remove',(_0x479caa,_0x3aa433)=>{this['_removeRevision'](_0x3aa433);});}get['revisionViews'](){return this['timePeriodViews']['map'](_0x2f9c7a=>_0x2f9c7a['revisionViews']['map'](_0x58d757=>_0x58d757))['flat']();}['selectRevision'](_0x3a14ab){for(const _0x54849c of this['revisionViews'])_0x3a14ab&&_0x3a14ab['id']===_0x54849c['id']?_0x54849c['select']():_0x54849c['deselect']();}['highlightRevisions'](_0x10dea4){for(const _0x36dccc of this['revisionViews'])_0x10dea4['some'](({id:_0x11818})=>_0x11818===_0x36dccc['id'])?_0x36dccc['highlight']():_0x36dccc['unhighlight']();}['_addRevision'](_0x51a3b7){const _0x27c7a5=ki(_0x51a3b7['createdAt'],this['locale']['uiLanguage'])['startDate'];let _0x388eeb=this['timePeriodViews']['get'](0x0);_0x388eeb&&_0x388eeb['startDate']['getTime']()===_0x27c7a5['getTime']()||(_0x388eeb=new ji(this['locale'],_0x27c7a5,this['_revisionActions'],this['_requireRevisionName']),this['timePeriodViews']['add'](_0x388eeb)),_0x388eeb['addRevision'](_0x51a3b7);}['_removeRevision'](_0x2ad08b){const _0x49ab76=ki(_0x2ad08b['createdAt'],this['locale']['uiLanguage'])['startDate'];this['_getTimePeriodViewByStartDate'](_0x49ab76)['removeRevision'](_0x2ad08b);}['_getTimePeriodViewByStartDate'](_0x59ab3e){return this['timePeriodViews']['find'](_0x26767d=>_0x26767d['startDate']['getTime']()===_0x59ab3e['getTime']());}}class d extends _0x59afc0{['_revisionViewer'];['_revisionsRepository'];['_sidebarView'];static ['defaultRevisionActions']=/* #__PURE__ -- @preserve */
|
|
28
28
|
((()=>['compareAgainstSelected','restoreRevision','nameRevision'])());static ['availableRevisionActions']=/* #__PURE__ -- @preserve */
|
|
29
|
-
at();static get['pluginName'](){return'RevisionsSidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[u];}constructor(
|
|
30
|
-
_0x17b6f3(_0x36b6af){['_ui'];get['ui'](){return this['_ui'];}constructor(_0x3ca6dc,_0x254363){super(_0x254363),this['sourceElement']=_0x3ca6dc,this['model']['document']['createRoot']();const _0x3196ff=new ii(this['locale'],this['editing']['view'],{'shouldToolbarGroupWhenFull':!0x0});this['_ui']=new Z(this,_0x3196ff);}['destroy'](){return this['updateSourceElement'](),this['ui']['destroy'](),super['destroy']();}static async['create'](_0x2828f0,_0x2ddc96){const _0x4f0cbb=new this(_0x2828f0,_0x2ddc96);return await _0x4f0cbb['initPlugins'](),await _0x4f0cbb['ui']['init'](_0x2828f0),await _0x4f0cbb['data']['init'](_0x4f0cbb['config']['get']('initialData')||''),_0x4f0cbb['fire']('ready'),_0x4f0cbb;}}const p=['RevisionHistoryUI','RestrictedEditingMode','AIChat','AIReviewMode','AIBalloon','AIQuickActions','AIActions'];class ht extends _0x30489c{['result'];static get['pluginName'](){return'RevisionViewerIntegration';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x2e17bb){function _0x18b3f7(_0xab712b){return _0xab712b['map'](_0x69a397=>String['fromCharCode'](_0x69a397))['join']('');}super(_0x2e17bb),this['result']='end',_0x2e17bb[_0x18b3f7([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x18b3f7([0x76,0x69,0x65,0x77])][_0x18b3f7([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x18b3f7([0x61,0x75,0x74,0x6f]),_0x2e17bb[_0x18b3f7([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x18b3f7([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x18b3f7([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x18b3f7([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x18b3f7([0x6f,0x6b])});}}class ct extends _0x30489c{['_viewerEditor'];static get['pluginName'](){return'RevisionHistory';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[h,l];}constructor(_0x4ef1bf){if(super(_0x4ef1bf),!this['editor']['config']['get']('revisionHistory'))throw new _0x1dc26f('revision-history-missing-configuration',this);this['_viewerEditor']=null,this['set']('isRevisionViewerOpen',!0x1),this['editor']['config']['define']('revisionHistory.showRevisionViewerCallback',_0x2a89b2=>this['_showRevisionViewer']({..._0x2a89b2,'translations':this['editor']['locale']['translations']})),this['editor']['config']['define']('revisionHistory.closeRevisionViewerCallback',_0x5e7cb9=>this['_closeRevisionViewer'](_0x5e7cb9)),this['editor']['config']['define']('revisionHistory.restoreRevisionCallback',_0x2bc5b8=>this['_restoreRevision'](_0x2bc5b8)),this['editor']['config']['define']('revisionHistory.requireRevisionName',!0x1),this['_enhanceShowRevisionViewerCallback'](),this['_enhanceCloseRevisionViewerCallback']();}set['adapter'](_0x13730f){this['editor']['plugins']['get']('RevisionTracker')['adapter']=_0x13730f;}get['adapter'](){return this['editor']['plugins']['get']('RevisionTracker')['adapter'];}['addRevisionData'](_0x1f1852){return this['editor']['plugins']['get']('RevisionTracker')['addRevisionData'](_0x1f1852);}['getRevision'](_0x597f6b){return this['editor']['plugins']['get']('RevisionsRepository')['getRevision'](_0x597f6b);}['getRevisions'](_0x15295d){return this['editor']['plugins']['get']('RevisionsRepository')['getRevisions'](_0x15295d||{'toJSON':!0x1});}['_getRevisionViewerEditorConfig'](){const _0x20f5af=this['editor'],_0x1fa220=_0x5f47aa(_0x20f5af,p),_0x31addd=_0x20f5af['plugins']['get']('RevisionTracker'),_0x598046=_0x20f5af['plugins']['get']('Users')['users'];return _0x1fa220['toolbar']=['exitToEditing','restoreRevision','changesNavigation'],delete _0x1fa220['lazyRoots'],(_0x1fa220['plugins']['push'](ht,u,v,class extends _0x30489c{static get['requires'](){return[u,'Users'];}['init'](){const _0x5ef61d=this['editor']['plugins']['get']('Users');for(const _0x10f1df of _0x598046)_0x10f1df['isAnonymous']||_0x5ef61d['getUser'](_0x10f1df['id'])||_0x5ef61d['addUser'](_0x10f1df);const _0xf061aa=_0x31addd['repository']['getRevisions']();let _0x5ecc0a=null;const _0x57c49c=this['editor']['plugins']['get']('RevisionViewer');_0x57c49c['adapter']=_0x31addd['adapter'],_0x57c49c['bind']('isEnabled')['to'](_0x31addd),this['editor']['commands']['get']('restoreRevision')['bind']('isEnabled')['to'](_0x20f5af,'isReadOnly',_0xfd3fc6=>!_0xfd3fc6);for(const _0x5f4f55 of _0xf061aa){const _0x224980=null===_0x5f4f55['creator'];if(_0x224980&&_0x5f4f55['toVersion']===_0x5f4f55['fromVersion'])continue;const _0x490fb9=_0x5f4f55['toJSON']();_0x57c49c['addRevisionData'](_0x490fb9,(_0x60d19d,_0x5a4e2a,_0x14afac)=>{if(_0x224980){if(_0x5ecc0a)_0x5ecc0a['_update'](_0x60d19d,_0x5a4e2a);else{if(!_0x5a4e2a){const _0x38d11b=_0x14afac['toJSON']();_0x38d11b['id']=_0x506dfc(),_0x31addd['saveRevision'](_0x38d11b,_0x14afac['toVersion'])['then'](_0xf60afe=>{_0x5ecc0a=_0xf60afe;});}}}else _0x5f4f55['_update'](_0x60d19d,_0x5a4e2a);});}}},d),_0x1fa220);}['_enhanceShowRevisionViewerCallback'](){const _0x2971b1=this['editor']['config']['get']('revisionHistory')['showRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.showRevisionViewerCallback',async()=>{this['editor']['enableReadOnlyMode']('revision-history-viewer-opened');const _0x40c0d8=this['editor']['plugins']['get']('RevisionTracker');if(this['editor']['plugins']['has']('Autosave')){const _0x24048e=this['editor']['plugins']['get']('Autosave');await _0x24048e['save']();}else await _0x40c0d8['update']();if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('Dialog')){const _0x592e9c=this['editor']['plugins']['get']('Dialog');_0x592e9c['isOpen']&&_0x592e9c['hide']();}if(this['editor']['plugins']['has']('AITabs')){const _0x51624a=this['editor']['plugins']['get']('AITabs')['view']['panelViews'];for(const _0x2e8104 of _0x51624a)_0x2e8104['class']=_0x2e8104['class']?_0x2e8104['class']+'\x20ck-tab-panel_disabled':'ck-tab-panel_disabled';if(this['editor']['plugins']['has']('AIChat')){const _0x1afa43=document['querySelector']('.ck-ai-chat__prompt-input\x20.ck-textarea');_0x1afa43&&_0x1afa43['setAttribute']('tabindex','-1');}if(this['editor']['plugins']['has']('AIChatHistory')){const _0x26ec6a=document['querySelector']('.ck-ai-chat-history\x20.ck-input');_0x26ec6a&&_0x26ec6a['setAttribute']('tabindex','-1');}}const _0x22e665=this['_getRevisionViewerEditorConfig']();return _0x2971b1(_0x22e665)['then'](_0x54018f=>{return(this['_viewerEditor']=_0x54018f,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'),_0x54018f);})['catch'](_0x44a22e=>(console['error'](_0x44a22e),this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),null));});}['_enhanceCloseRevisionViewerCallback'](){const _0x3eaaf6=this['editor']['config']['get']('revisionHistory')['closeRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.closeRevisionViewerCallback',()=>{if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('DocumentOutline')&&(this['editor']['plugins']['get']('DocumentOutlineUI')['view']['element']['style']['display']=''),this['editor']['plugins']['has']('AITabs')){const _0x5a56ff=this['editor']['plugins']['get']('AITabs')['view']['panelViews'];for(const _0x167ca7 of _0x5a56ff)_0x167ca7['class']='ck-tab-panel_disabled'===_0x167ca7['class']?'':_0x167ca7['class']['replace']('\x20ck-tab-panel_disabled','');if(this['editor']['plugins']['has']('AIChat')){const _0x524b64=document['querySelector']('.ck-ai-chat__prompt-input\x20.ck-textarea');_0x524b64&&_0x524b64['removeAttribute']('tabindex');}if(this['editor']['plugins']['has']('AIChatHistory')){const _0x178375=document['querySelector']('.ck-ai-chat-history\x20.ck-input');_0x178375&&_0x178375['removeAttribute']('tabindex');}}return this['_viewerEditor']['plugins']['get']('RevisionViewer')['_cleanUp'](),_0x3eaaf6(this['_viewerEditor'])['then'](()=>{if(this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),this['_viewerEditor']=null,this['editor']['plugins']['has']('Annotations')){const _0x3f7178=this['editor']['plugins']['get']('Annotations');_0x3f7178['refreshVisibility'](),_0x3f7178['refreshPositioning']();}});});}['_showRevisionViewer'](_0xd6266d){const _0x1cbd3c=this['editor']['config']['get']('revisionHistory.editorContainer'),_0x1d03f0=this['editor']['config']['get']('revisionHistory.viewerContainer'),_0xf89ccc=this['editor']['config']['get']('revisionHistory.viewerEditorElement');return f['create'](_0xf89ccc,_0xd6266d)['then'](_0x15da5c=>(_0x1d03f0['style']['display']='block',_0x1cbd3c['style']['display']='none',this['isRevisionViewerOpen']=!0x0,_0x15da5c));}['_closeRevisionViewer'](_0x348d64){const _0x4bdd8b=this['editor']['config']['get']('revisionHistory.editorContainer');return this['editor']['config']['get']('revisionHistory.viewerContainer')['style']['display']='none',_0x4bdd8b['style']['display']='',this['isRevisionViewerOpen']=!0x1,_0x348d64['destroy']();}async['_restoreRevision'](_0xc848c1){const _0x27120c=this['editor'],_0xacd13c=this['_viewerEditor']['plugins']['get']('RevisionViewer'),_0x5f0e24=_0x27120c['plugins']['get']('RevisionTracker'),_0x53c8a9=_0x27120c['plugins']['get']('RevisionHistoryUtils'),_0x3b1561=_0xacd13c['repository']['getRevision'](_0xc848c1);let _0x385bfc,_0x4f8d2f,_0x51e269;try{await _0x53c8a9['loadRevisionData'](_0x3b1561,this['adapter']),_0x385bfc=_0x53c8a9['getRevisionDocumentData'](_0x3b1561),_0x4f8d2f=_0x53c8a9['getRevisionRootsAttributes'](_0x3b1561);}catch(_0x3fb6be){return void console['error'](_0x3fb6be);}_0x27120c['model']['change'](_0x4ba7e=>{for(const _0x5150de of Array['from'](_0x27120c['model']['markers']['getMarkersGroup']('restrictedEditingException')))_0x4ba7e['removeMarker'](_0x5150de);}),_0xacd13c['isReady']=!0x1,_0x27120c['model']['enqueueChange'](_0x285714=>{_0x285714['setSelection'](null),_0x285714['removeSelectionAttribute'](_0x27120c['model']['document']['selection']['getAttributeKeys']());const _0x3ca21f=Object['keys'](_0x385bfc);for(const _0x5bb8b6 of _0x27120c['model']['document']['roots'])'$graveyard'!=_0x5bb8b6['rootName']&&_0x5bb8b6['isAttached']()&&!_0x3ca21f['includes'](_0x5bb8b6['rootName'])&&_0x285714['detachRoot'](_0x5bb8b6);for(const _0x4273f2 of _0x3ca21f){let _0x3eba55=_0x27120c['model']['document']['getRoot'](_0x4273f2);_0x3eba55&&_0x3eba55['isAttached']()||(_0x3eba55=_0x285714['addRoot'](_0x4273f2));const _0x5e4514=_0x4f8d2f[_0x4273f2],_0x16715b=Object['keys'](_0x5e4514),_0x71c344=_0x385bfc[_0x4273f2];for(const _0x28621d of _0x3eba55['getAttributeKeys']())_0x16715b['includes'](_0x28621d)||_0x285714['removeAttribute'](_0x28621d,_0x3eba55);for(const _0x28db53 of _0x16715b)_0x285714['setAttribute'](_0x28db53,_0x4f8d2f[_0x4273f2][_0x28db53],_0x3eba55);_0x285714['remove'](_0x285714['createRangeIn'](_0x3eba55)),_0x285714['insert'](_0x27120c['data']['parse'](_0x71c344,_0x3eba55),_0x3eba55,0x0);}});const _0x1109d3=m(_0x27120c['locale'],'Restored');if(_0x3b1561['name'])_0x51e269=-0x1==_0x3b1561['name']['indexOf'](_0x1109d3)?_0x1109d3+':\x20'+_0x3b1561['name']:_0x3b1561['name'];else _0x51e269=_0x1109d3+':\x20'+(_0x3b1561['createdAt']['toLocaleDateString'](_0x27120c['locale']['uiLanguage'],{'month':'long','day':'numeric'})+',\x20'+_0x3b1561['createdAt']['toLocaleTimeString'](_0x27120c['locale']['uiLanguage'],{'hour':'numeric','minute':'numeric'}));return await _0x5f0e24['saveRevision']({'name':_0x51e269}),_0xacd13c['isReady']=!0x0,_0x27120c['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}}export{nt as RestoreRevisionCommand,I as Revision,ct as RevisionHistory,l as RevisionHistoryUI,$ as RevisionHistoryUtils,h as RevisionTracker,u as RevisionViewer,f as RevisionViewerEditor,ht as RevisionViewerIntegration,ji as RevisionViewerLoadingOverlay,v as RevisionViewerUI,S as RevisionsRepository,d as RevisionsSidebar,rt as ShowChangeCommand};
|
|
29
|
+
at();static get['pluginName'](){return'RevisionsSidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[u];}constructor(_0x373033){super(_0x373033),this['_revisionViewer']=_0x373033['plugins']['get'](u),this['_revisionsRepository']=this['_revisionViewer']['repository'],this['_sidebarView']=null;}['init'](){const _0x249a0a=this['_revisionsRepository']['_revisions'],_0x3a871c=this['_createRevisionActions'](),_0x18b29e=this['editor']['config']['get']('revisionHistory.viewerSidebarContainer');this['_sidebarView']=new Ri(this['editor']['locale'],_0x249a0a,_0x3a871c,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',(_0x33b47d,_0xae9d6e)=>{_0xae9d6e['revisionViews']['on']('add',(_0x3d0f4f,_0xec811f)=>{_0xec811f['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)),_0x18b29e['appendChild'](this['_sidebarView']['element']);}['destroy'](){this['_sidebarView']['element']['remove'](),this['_sidebarView']['destroy']();}['_handleEditorDataReady'](){const _0x863179=this['_revisionsRepository']['getRevision'](0x0);if(_0x863179){const _0x5c5af9=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x863179['id']);this['_revisionViewer']['compare'](_0x863179,_0x5c5af9);}}['_handleRevisionSelected'](_0x21652d,_0xbf0b46){const _0x3748c6=this['_revisionsRepository']['getRevision'](_0xbf0b46['id']),_0x35bfdb=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x3748c6['id']);this['_revisionViewer']['compare'](_0x3748c6,_0x35bfdb);}['_handleRevisionSetName'](_0x4ae5ef,_0x485017){this['_revisionsRepository']['getRevision'](_0x485017['id'])['setName'](_0x485017['name']);}['_handleDiffChange'](_0x1de78a,_0x3e0259,_0x5debe7){const _0x78c8d4=this['_revisionsRepository']['getRevisionsInDiff'](_0x5debe7);_0x78c8d4['length']>0x2?(this['_sidebarView']['highlightRevisions'](_0x78c8d4),this['_sidebarView']['selectRevision'](null)):(this['_sidebarView']['highlightRevisions']([]),this['_sidebarView']['selectRevision'](_0x78c8d4[0x0]));}['_createRevisionActions'](){const _0x49bb5b=this['editor'],_0x3c52e4=d['availableRevisionActions'],_0xb1fb85=_0x49bb5b['config']['get']('revisionHistory.revisionActions')||d['defaultRevisionActions'];if(_0xb1fb85['length'])return _0xb1fb85['map'](_0x42fd31=>{const _0x10967b='string'==typeof _0x42fd31?Object['assign']({},_0x3c52e4[_0x42fd31]):_0x42fd31;return _0x10967b['action']=_0x10967b['action']['bind'](this,_0x49bb5b),_0x10967b['isVisible']&&(_0x10967b['isVisible']=_0x10967b['isVisible']['bind'](this,_0x49bb5b)),_0x10967b;});}}function at(){return{'compareAgainstSelected':{'name':'Compare\x20against\x20selected','action':({plugins:_0x48a363},_0x3294b4)=>{const _0x5b41b6=_0x48a363['get'](u),_0x3e79a2=_0x5b41b6['repository'];let _0x9372=_0x5b41b6['diff']['newRevisionId'],_0x4c1dfb=_0x3294b4['id'];_0x3e79a2['getIndex'](_0x9372)>_0x3e79a2['getIndex'](_0x4c1dfb)&&([_0x9372,_0x4c1dfb]=[_0x4c1dfb,_0x9372]),_0x5b41b6['compare'](_0x9372,_0x4c1dfb);},'isVisible':({plugins:_0x5e5f85},_0x100b92)=>{const _0xf0c874=_0x5e5f85['get'](u);return!(_0xf0c874['repository']['getRevisionsInDiff'](_0xf0c874['diff'])['length']>0x2)&&!_0x100b92['isSelected'];}},'restoreRevision':{'name':'Restore\x20this\x20revision','action':(_0x5064a5,{id:_0x36f2f5})=>{_0x5064a5['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x36f2f5);},'isVisible':({plugins:_0x347785},_0x3dcc25)=>!!_0x347785['get'](u)['repository']['getLaterVisibleRevision'](_0x3dcc25['id'])},'nameRevision':{'name':'Name\x20this\x20revision','action':({plugins:_0x14bdfb},{id:_0x35304e,revisionNameView:_0x5cecdd})=>{const _0x39196d=_0x14bdfb['get'](u),_0x1a93bd=_0x39196d['repository']['getEarlierVisibleRevision'](_0x35304e);_0x39196d['compare'](_0x35304e,_0x1a93bd),_0x5cecdd['focus'](),_0x5cecdd['fieldView']['select']();}}};}class Z extends tt{['_view'];['_toolbarConfig'];['_elementReplacer'];get['view'](){return this['_view'];}constructor(_0x3d6a78,_0x197d9a){super(_0x3d6a78),this['_view']=_0x197d9a,this['_toolbarConfig']=st(_0x3d6a78['config']['get']('toolbar')),this['_elementReplacer']=new it();}get['element'](){return this['view']['element'];}['init'](_0x1e9712){const _0x343066=this['editor'],_0x5b1803=this['view'],_0x1f54e8=_0x343066['editing']['view'],_0x406b4b=_0x5b1803['editable'],_0x4926eb=_0x1f54e8['document']['getRoot']();_0x406b4b['name']=_0x4926eb['rootName'],_0x5b1803['render']();const _0x341356=_0x406b4b['element'];this['setEditableElement'](_0x406b4b['name'],_0x341356),_0x5b1803['editable']['bind']('isFocused')['to'](this['focusTracker']),_0x1f54e8['attachDomRoot'](_0x341356),this['_elementReplacer']['replace'](_0x1e9712,this['element']),this['_initToolbar'](),this['fire']('ready');}['destroy'](){super['destroy']();const _0x2d31d4=this['view'],_0x1aa0e2=this['editor']['editing']['view'];this['_elementReplacer']['restore'](),_0x1aa0e2['detachDomRoot'](_0x2d31d4['editable']['name']),_0x2d31d4['destroy']();}['_initToolbar'](){const _0x1b490f=this['view'];_0x1b490f['stickyPanel']['bind']('isActive')['to'](this['focusTracker'],'isFocused'),_0x1b490f['stickyPanel']['limiterElement']=_0x1b490f['element'],_0x1b490f['stickyPanel']['bind']('viewportTopOffset')['to'](this,'viewportOffset',({top:_0x4f4005})=>_0x4f4005),_0x1b490f['toolbar']['fillFromConfig'](this['_toolbarConfig'],this['componentFactory']),this['addToolbar'](_0x1b490f['toolbar']);}}class ii extends _0x153483{['_editable'];['stickyPanel'];['toolbar'];get['editable'](){return this['_editable'];}constructor(_0x50c909,_0x3d1d11,_0x313f42={}){super(_0x50c909),this['stickyPanel']=new _0x27d56b(_0x50c909),this['toolbar']=new _0x345b5d(_0x50c909,{'shouldGroupWhenFull':_0x313f42['shouldToolbarGroupWhenFull']}),this['_editable']=new te(_0x50c909,_0x3d1d11);}['render'](){super['render'](),this['stickyPanel']['content']['add'](this['toolbar']),this['top']['add'](this['stickyPanel']),this['main']['add'](this['editable']);}}class f extends/* #__PURE__ -- @preserve */
|
|
30
|
+
_0x22e1de(_0x54238d){['_ui'];get['ui'](){return this['_ui'];}constructor(_0x5849c4,_0x23e29f){super(_0x23e29f),this['sourceElement']=_0x5849c4,this['model']['document']['createRoot']();const _0x5ab809=new ii(this['locale'],this['editing']['view'],{'shouldToolbarGroupWhenFull':!0x0});this['_ui']=new Z(this,_0x5ab809);}['destroy'](){return this['updateSourceElement'](),this['ui']['destroy'](),super['destroy']();}static async['create'](_0x5518b8,_0x2678c0){const _0x339bc0=new this(_0x5518b8,_0x2678c0);return await _0x339bc0['initPlugins'](),await _0x339bc0['ui']['init'](_0x5518b8),await _0x339bc0['data']['init'](_0x339bc0['config']['get']('initialData')||''),_0x339bc0['fire']('ready'),_0x339bc0;}}const p=['RevisionHistoryUI','RestrictedEditingMode','AIChat','AIReviewMode','AIBalloon','AIQuickActions','AIActions'];class ht extends _0x59afc0{['result'];static get['pluginName'](){return'RevisionViewerIntegration';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0xdad6d3){function _0x42e5af(_0x2a8cd4){return _0x2a8cd4['map'](_0x5c815d=>String['fromCharCode'](_0x5c815d))['join']('');}super(_0xdad6d3),this['result']='end',_0xdad6d3[_0x42e5af([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x42e5af([0x76,0x69,0x65,0x77])][_0x42e5af([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x42e5af([0x61,0x75,0x74,0x6f]),_0xdad6d3[_0x42e5af([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x42e5af([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x42e5af([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x42e5af([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x42e5af([0x6f,0x6b])});}}class ct extends _0x59afc0{['_viewerEditor'];static get['pluginName'](){return'RevisionHistory';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[h,l];}constructor(_0x595296){if(super(_0x595296),!this['editor']['config']['get']('revisionHistory'))throw new _0x5bf644('revision-history-missing-configuration',this);this['_viewerEditor']=null,this['set']('isRevisionViewerOpen',!0x1),this['editor']['config']['define']('revisionHistory.showRevisionViewerCallback',_0x14f852=>this['_showRevisionViewer']({..._0x14f852,'translations':this['editor']['locale']['translations']})),this['editor']['config']['define']('revisionHistory.closeRevisionViewerCallback',_0x100125=>this['_closeRevisionViewer'](_0x100125)),this['editor']['config']['define']('revisionHistory.restoreRevisionCallback',_0x1ef81e=>this['_restoreRevision'](_0x1ef81e)),this['editor']['config']['define']('revisionHistory.requireRevisionName',!0x1),this['_enhanceShowRevisionViewerCallback'](),this['_enhanceCloseRevisionViewerCallback']();}set['adapter'](_0x4acbba){this['editor']['plugins']['get']('RevisionTracker')['adapter']=_0x4acbba;}get['adapter'](){return this['editor']['plugins']['get']('RevisionTracker')['adapter'];}['addRevisionData'](_0x25d18a){return this['editor']['plugins']['get']('RevisionTracker')['addRevisionData'](_0x25d18a);}['getRevision'](_0x28454f){return this['editor']['plugins']['get']('RevisionsRepository')['getRevision'](_0x28454f);}['getRevisions'](_0x10d14c){return this['editor']['plugins']['get']('RevisionsRepository')['getRevisions'](_0x10d14c||{'toJSON':!0x1});}['_getRevisionViewerEditorConfig'](){const _0xc4e78=this['editor'],_0x346732=_0x8e5f46(_0xc4e78,p),_0x39f831=_0xc4e78['plugins']['get']('RevisionTracker'),_0x30c077=_0xc4e78['plugins']['get']('Users')['users'];return _0x346732['toolbar']=['exitToEditing','restoreRevision','changesNavigation'],delete _0x346732['lazyRoots'],(_0x346732['plugins']['push'](ht,u,v,class extends _0x59afc0{static get['requires'](){return[u,'Users'];}['init'](){const _0x2b5e28=this['editor']['plugins']['get']('Users');for(const _0x2746da of _0x30c077)_0x2746da['isAnonymous']||_0x2b5e28['getUser'](_0x2746da['id'])||_0x2b5e28['addUser'](_0x2746da);const _0x545143=_0x39f831['repository']['getRevisions']();let _0x5d4dac=null;const _0x302222=this['editor']['plugins']['get']('RevisionViewer');_0x302222['adapter']=_0x39f831['adapter'],_0x302222['bind']('isEnabled')['to'](_0x39f831),this['editor']['commands']['get']('restoreRevision')['bind']('isEnabled')['to'](_0xc4e78,'isReadOnly',_0x4878d3=>!_0x4878d3);for(const _0x5eb6e0 of _0x545143){const _0x1cfa33=null===_0x5eb6e0['creator'];if(_0x1cfa33&&_0x5eb6e0['toVersion']===_0x5eb6e0['fromVersion'])continue;const _0x3992ef=_0x5eb6e0['toJSON']();_0x302222['addRevisionData'](_0x3992ef,(_0x119edc,_0x21de56,_0xf69f4c)=>{if(_0x1cfa33){if(_0x5d4dac)_0x5d4dac['_update'](_0x119edc,_0x21de56);else{if(!_0x21de56){const _0x335c4b=_0xf69f4c['toJSON']();_0x335c4b['id']=_0x221375(),_0x39f831['saveRevision'](_0x335c4b,_0xf69f4c['toVersion'])['then'](_0x410e9=>{_0x5d4dac=_0x410e9;});}}}else _0x5eb6e0['_update'](_0x119edc,_0x21de56);});}}},d),_0x346732);}['_enhanceShowRevisionViewerCallback'](){const _0x567834=this['editor']['config']['get']('revisionHistory')['showRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.showRevisionViewerCallback',async()=>{this['editor']['enableReadOnlyMode']('revision-history-viewer-opened');const _0x15914a=this['editor']['plugins']['get']('RevisionTracker');if(this['editor']['plugins']['has']('Autosave')){const _0x4a4fb8=this['editor']['plugins']['get']('Autosave');await _0x4a4fb8['save']();}else await _0x15914a['update']();if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('Dialog')){const _0x500966=this['editor']['plugins']['get']('Dialog');_0x500966['isOpen']&&_0x500966['hide']();}if(this['editor']['plugins']['has']('AITabs')){const _0x288734=this['editor']['plugins']['get']('AITabs')['view']['panelViews'];for(const _0x5aa7f6 of _0x288734)_0x5aa7f6['class']=_0x5aa7f6['class']?_0x5aa7f6['class']+'\x20ck-tab-panel_disabled':'ck-tab-panel_disabled';if(this['editor']['plugins']['has']('AIChat')){const _0x4a5b35=document['querySelector']('.ck-ai-chat__prompt-input\x20.ck-textarea');_0x4a5b35&&_0x4a5b35['setAttribute']('tabindex','-1');}if(this['editor']['plugins']['has']('AIChatHistory')){const _0x39e9a8=document['querySelector']('.ck-ai-chat-history\x20.ck-input');_0x39e9a8&&_0x39e9a8['setAttribute']('tabindex','-1');}}const _0x487861=this['_getRevisionViewerEditorConfig']();return _0x567834(_0x487861)['then'](_0x30dc2c=>{return(this['_viewerEditor']=_0x30dc2c,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'),_0x30dc2c);})['catch'](_0x4724f2=>(console['error'](_0x4724f2),this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),null));});}['_enhanceCloseRevisionViewerCallback'](){const _0x531cfa=this['editor']['config']['get']('revisionHistory')['closeRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.closeRevisionViewerCallback',()=>{if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('DocumentOutline')&&(this['editor']['plugins']['get']('DocumentOutlineUI')['view']['element']['style']['display']=''),this['editor']['plugins']['has']('AITabs')){const _0x101198=this['editor']['plugins']['get']('AITabs')['view']['panelViews'];for(const _0x420960 of _0x101198)_0x420960['class']='ck-tab-panel_disabled'===_0x420960['class']?'':_0x420960['class']['replace']('\x20ck-tab-panel_disabled','');if(this['editor']['plugins']['has']('AIChat')){const _0x52e196=document['querySelector']('.ck-ai-chat__prompt-input\x20.ck-textarea');_0x52e196&&_0x52e196['removeAttribute']('tabindex');}if(this['editor']['plugins']['has']('AIChatHistory')){const _0x352e37=document['querySelector']('.ck-ai-chat-history\x20.ck-input');_0x352e37&&_0x352e37['removeAttribute']('tabindex');}}return this['_viewerEditor']['plugins']['get']('RevisionViewer')['_cleanUp'](),_0x531cfa(this['_viewerEditor'])['then'](()=>{if(this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),this['_viewerEditor']=null,this['editor']['plugins']['has']('Annotations')){const _0x17fdb3=this['editor']['plugins']['get']('Annotations');_0x17fdb3['refreshVisibility'](),_0x17fdb3['refreshPositioning']();}});});}['_showRevisionViewer'](_0x163822){const _0x5241e5=this['editor']['config']['get']('revisionHistory.editorContainer'),_0x21b1d8=this['editor']['config']['get']('revisionHistory.viewerContainer'),_0x2a527d=this['editor']['config']['get']('revisionHistory.viewerEditorElement');return f['create'](_0x2a527d,_0x163822)['then'](_0x40eb9b=>(_0x21b1d8['style']['display']='block',_0x5241e5['style']['display']='none',this['isRevisionViewerOpen']=!0x0,_0x40eb9b));}['_closeRevisionViewer'](_0x4c70e2){const _0x423096=this['editor']['config']['get']('revisionHistory.editorContainer');return this['editor']['config']['get']('revisionHistory.viewerContainer')['style']['display']='none',_0x423096['style']['display']='',this['isRevisionViewerOpen']=!0x1,_0x4c70e2['destroy']();}async['_restoreRevision'](_0xf130f6){const _0x2fd558=this['editor'],_0xe540fa=this['_viewerEditor']['plugins']['get']('RevisionViewer'),_0x42967d=_0x2fd558['plugins']['get']('RevisionTracker'),_0x37ac17=_0x2fd558['plugins']['get']('RevisionHistoryUtils'),_0x15ff15=_0xe540fa['repository']['getRevision'](_0xf130f6);let _0x2f2f1a,_0x2481f7,_0x194874;try{await _0x37ac17['loadRevisionData'](_0x15ff15,this['adapter']),_0x2f2f1a=_0x37ac17['getRevisionDocumentData'](_0x15ff15),_0x2481f7=_0x37ac17['getRevisionRootsAttributes'](_0x15ff15);}catch(_0xf65f8d){return void console['error'](_0xf65f8d);}_0x2fd558['model']['change'](_0x3f7a0b=>{for(const _0xd686e8 of Array['from'](_0x2fd558['model']['markers']['getMarkersGroup']('restrictedEditingException')))_0x3f7a0b['removeMarker'](_0xd686e8);}),_0xe540fa['isReady']=!0x1,_0x2fd558['model']['enqueueChange'](_0x1cd9ec=>{_0x1cd9ec['setSelection'](null),_0x1cd9ec['removeSelectionAttribute'](_0x2fd558['model']['document']['selection']['getAttributeKeys']());const _0x3b0d09=Object['keys'](_0x2f2f1a);for(const _0x4a43b6 of _0x2fd558['model']['document']['roots'])'$graveyard'!=_0x4a43b6['rootName']&&_0x4a43b6['isAttached']()&&!_0x3b0d09['includes'](_0x4a43b6['rootName'])&&_0x1cd9ec['detachRoot'](_0x4a43b6);for(const _0x385bd5 of _0x3b0d09){let _0x24d93d=_0x2fd558['model']['document']['getRoot'](_0x385bd5);_0x24d93d&&_0x24d93d['isAttached']()||(_0x24d93d=_0x1cd9ec['addRoot'](_0x385bd5));const _0x5c71ac=_0x2481f7[_0x385bd5],_0x4c19a3=Object['keys'](_0x5c71ac),_0x24836e=_0x2f2f1a[_0x385bd5];for(const _0x2fbea5 of _0x24d93d['getAttributeKeys']())_0x4c19a3['includes'](_0x2fbea5)||_0x1cd9ec['removeAttribute'](_0x2fbea5,_0x24d93d);for(const _0x4af3a7 of _0x4c19a3)_0x1cd9ec['setAttribute'](_0x4af3a7,_0x2481f7[_0x385bd5][_0x4af3a7],_0x24d93d);_0x1cd9ec['remove'](_0x1cd9ec['createRangeIn'](_0x24d93d)),_0x1cd9ec['insert'](_0x2fd558['data']['parse'](_0x24836e,_0x24d93d),_0x24d93d,0x0);}});const _0x5ea02b=m(_0x2fd558['locale'],'Restored');if(_0x15ff15['name'])_0x194874=-0x1==_0x15ff15['name']['indexOf'](_0x5ea02b)?_0x5ea02b+':\x20'+_0x15ff15['name']:_0x15ff15['name'];else _0x194874=_0x5ea02b+':\x20'+(_0x15ff15['createdAt']['toLocaleDateString'](_0x2fd558['locale']['uiLanguage'],{'month':'long','day':'numeric'})+',\x20'+_0x15ff15['createdAt']['toLocaleTimeString'](_0x2fd558['locale']['uiLanguage'],{'hour':'numeric','minute':'numeric'}));return await _0x42967d['saveRevision']({'name':_0x194874}),_0xe540fa['isReady']=!0x0,_0x2fd558['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}}export{nt as RestoreRevisionCommand,I as Revision,ct as RevisionHistory,l as RevisionHistoryUI,$ as RevisionHistoryUtils,h as RevisionTracker,u as RevisionViewer,f as RevisionViewerEditor,ht as RevisionViewerIntegration,bi as RevisionViewerLoadingOverlay,v as RevisionViewerUI,S as RevisionsRepository,d as RevisionsSidebar,rt as ShowChangeCommand};
|