@ckeditor/ckeditor5-revision-history 46.1.0-alpha.2 → 46.1.1-alpha.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/build/revision-history.js +1 -1
- package/dist/index.js +7 -7
- package/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 -11
- package/src/changeitem.js +2 -2
- package/src/editor/revisionviewereditor.d.ts +1 -1
- 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.d.ts +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
|
-
_0x3e54cf(){['id'];['creator'];['authors'];['diffData'];['toVersion'];['fromVersion'];['model'];constructor(_0x57ac44){super(),this['id']=_0x57ac44['id']||_0x515d40(),this['creator']=_0x57ac44['creator']||null,this['authors']=_0x57ac44['authors']||[],this['diffData']=_0x57ac44['diffData']||null,this['toVersion']=_0x57ac44['toVersion']||0x0,this['fromVersion']=_0x57ac44['fromVersion']||0x0,this['set']('name',_0x57ac44['name']||''),this['set']('createdAt',_0x57ac44['createdAt']||new Date()),this['set']('attributes',_0x57ac44['attributes']||{});}['setName'](_0x2d11fe){this['_update']({'name':_0x2d11fe});}['setAttribute'](_0x5d67b8,_0x56995c){const _0xd9d267=_0x1fffc6(this['attributes']);_0x210c0b(_0xd9d267,_0x5d67b8,_0x56995c),this['_update']({'attributes':_0xd9d267});}['removeAttribute'](_0x52116c){const _0x528af7=_0x1fffc6(this['attributes']);_0x530359(_0x528af7,_0x52116c),this['_update']({'attributes':_0x528af7});}['_update'](_0x3232c7,_0x1c417f=!0x1){let _0x3787f3=!0x1;const _0x35b469={'id':this['id']},_0x898efb=['name','createdAt','diffData','authors','attributes','toVersion','fromVersion','creatorId'];for(const _0x2e9251 of _0x898efb){const _0x29f603=_0x3232c7[_0x2e9251];void 0x0!==_0x29f603&&_0x29f603!==this[_0x2e9251]&&(this[_0x2e9251]=_0x29f603,_0x35b469[_0x2e9251]=_0x29f603,_0x3787f3=!0x0);}_0x3787f3&&(_0x35b469['authors']&&(_0x35b469['authorsIds']=_0x35b469['authors']['map'](_0x79346a=>_0x79346a['id']),delete _0x35b469['authors']),this['fire']('_update',_0x35b469,_0x1c417f));}['toJSON'](){return{'id':this['id'],'name':this['name'],'creatorId':this['creator']?this['creator']['id']:null,'authorsIds':this['authors']['map'](_0x197a62=>_0x197a62['id']),'diffData':this['diffData'],'createdAt':this['createdAt'],'attributes':this['attributes'],'fromVersion':this['fromVersion'],'toVersion':this['toVersion']};}}class S extends _0x278e34{['_revisions'];static get['requires'](){return[_0x3fef6b];}static get['pluginName'](){return'RevisionsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['length'](){return this['_revisions']['length'];}constructor(_0x5d24ed){super(_0x5d24ed),this['_revisions']=new _0x42f581();}['afterInit'](){!async function(_0x2bb360){const _0x2a753a=_0x8a3931([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]),_0x2395b0=0xeb829,_0x482e6f=0x7374585f,_0x438ea3=0x73732aa7^_0x482e6f,_0x567523=window[_0x8a3931([0x44,0x61,0x74,0x65])][_0x8a3931([0x6e,0x6f,0x77])](),_0x50168b=_0x2bb360[_0x8a3931([0x65,0x64,0x69,0x74,0x6f,0x72])],_0xa570=new window[(_0x8a3931([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x51c118=>{_0x50168b[_0x8a3931([0x6f,0x6e,0x63,0x65])](_0x8a3931([0x72,0x65,0x61,0x64,0x79]),_0x51c118);}),_0x49363d={[_0x8a3931([0x6b,0x74,0x79])]:_0x8a3931([0x45,0x43]),[_0x8a3931([0x75,0x73,0x65])]:_0x8a3931([0x73,0x69,0x67]),[_0x8a3931([0x63,0x72,0x76])]:_0x8a3931([0x50,0x2d,0x32,0x35,0x36]),[_0x8a3931([0x78])]:_0x8a3931([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]),[_0x8a3931([0x79])]:_0x8a3931([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]),[_0x8a3931([0x61,0x6c,0x67])]:_0x8a3931([0x45,0x53,0x32,0x35,0x36])},_0x1749d2=_0x50168b[_0x8a3931([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x8a3931([0x67,0x65,0x74])](_0x8a3931([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x7bccac(){let _0x1679ac,_0x34cb8=null,_0x323189=null;try{if(_0x1749d2==_0x8a3931([0x47,0x50,0x4c]))return _0x8a3931([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x1679ac=_0x2ceb31(),!_0x1679ac)return _0x8a3931([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x1679ac[_0x8a3931([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x323189=_0x17d7bf(_0x1679ac[_0x8a3931([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x1679ac[_0x8a3931([0x6a,0x74,0x69])])),await _0x31ff92()?_0x55f0a7()?_0x38dba3()?_0x8a3931([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x479398()?(_0x1679ac[_0x8a3931([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x8a3931([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x34cb8=_0x3d4018(_0x8a3931([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x1679ac[_0x8a3931([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x8a3931([0x74,0x72,0x69,0x61,0x6c])&&(_0x34cb8=_0x3d4018(_0x8a3931([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),await _0x40d592()):_0x8a3931([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x8a3931([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x8a3931([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch{return _0x8a3931([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x38dba3(){const _0x1f1719=[_0x8a3931([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x8a3931([0x74,0x72,0x69,0x61,0x6c])][_0x8a3931([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x1679ac[_0x8a3931([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x567523/0x3e8:0xe10*_0x438ea3;return _0x1679ac[_0x8a3931([0x65,0x78,0x70])]<_0x1f1719;}function _0x55f0a7(){const _0x399cda=_0x1679ac[_0x8a3931([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x399cda)return!0x1;if(_0x399cda[_0x8a3931([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x8a3931([0x2a])))return!0x0;if(_0x399cda[_0x8a3931([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x8a3931([0x52,0x48])))return!0x0;if(_0x399cda[_0x8a3931([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x8a3931([0x52,0x52,0x48]))){if(_0x377302())return!0x0;if(_0x563cca()||_0x1d7145())return!0x0;}return!0x1;}function _0x479398(){const _0x7ddf36=_0x1679ac[_0x8a3931([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x7ddf36||0x0==_0x7ddf36[_0x8a3931([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x3393ca}=new URL(window[_0x8a3931([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x7ddf36[_0x8a3931([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x3393ca))return!0x0;const _0x34a9dd=_0x3393ca[_0x8a3931([0x73,0x70,0x6c,0x69,0x74])](_0x8a3931([0x2e]));return _0x7ddf36[_0x8a3931([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x21fa44=>_0x21fa44[_0x8a3931([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x8a3931([0x2a])))[_0x8a3931([0x6d,0x61,0x70])](_0x5cb321=>_0x5cb321[_0x8a3931([0x73,0x70,0x6c,0x69,0x74])](_0x8a3931([0x2e])))[_0x8a3931([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x533a45=>_0x533a45[_0x8a3931([0x6c,0x65,0x6e,0x67,0x74,0x68])]<=_0x34a9dd[_0x8a3931([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x8a3931([0x6d,0x61,0x70])](_0x5793d7=>Array(_0x34a9dd[_0x8a3931([0x6c,0x65,0x6e,0x67,0x74,0x68])]-_0x5793d7[_0x8a3931([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x8a3931([0x66,0x69,0x6c,0x6c])](_0x5793d7[0x0]===_0x8a3931([0x2a])?_0x8a3931([0x2a]):'')[_0x8a3931([0x63,0x6f,0x6e,0x63,0x61,0x74])](_0x5793d7))[_0x8a3931([0x73,0x6f,0x6d,0x65])](_0xb3fcee=>_0x34a9dd[_0x8a3931([0x65,0x76,0x65,0x72,0x79])]((_0x2f830f,_0x5c558c)=>_0xb3fcee[_0x5c558c]===_0x2f830f||_0xb3fcee[_0x5c558c]===_0x8a3931([0x2a])));}function _0x40d592(){return _0x34cb8&&_0x323189?new window[(_0x8a3931([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x4551f6,_0x2ff68b)=>{_0x34cb8[_0x8a3931([0x74,0x68,0x65,0x6e])](_0x4551f6,_0x2ff68b),_0x323189[_0x8a3931([0x74,0x68,0x65,0x6e])](_0x20dd64=>{_0x20dd64!=_0x8a3931([0x56,0x61,0x6c,0x69,0x64])&&_0x4551f6(_0x20dd64);},_0x2ff68b);}):_0x34cb8||_0x323189||_0x8a3931([0x56,0x61,0x6c,0x69,0x64]);}}function _0x17d7bf(_0x3e47af,_0x52ea96){return new window[(_0x8a3931([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x54869c=>{if(_0x3748bd())return _0x54869c(_0x8a3931([0x56,0x61,0x6c,0x69,0x64]));_0x21bed7(),_0x50168b[_0x8a3931([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x8a3931([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x36f885=!0x1;const _0x43b926=_0x515d40();function _0x30c5ec(_0x4b80f2){return!!_0x4b80f2&&(typeof _0x4b80f2===_0x8a3931([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x4b80f2===_0x8a3931([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x4b80f2[_0x8a3931([0x74,0x68,0x65,0x6e])]===_0x8a3931([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x4b80f2[_0x8a3931([0x63,0x61,0x74,0x63,0x68])]===_0x8a3931([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x2ba6e9(_0x242471){_0x59494a(_0x242471)[_0x8a3931([0x74,0x68,0x65,0x6e])](_0x118ba0=>{if(!_0x118ba0||_0x118ba0[_0x8a3931([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x8a3931([0x6f,0x6b]))return _0x8a3931([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x26136a(_0x357803(_0x43b926+_0x52ea96))!=_0x118ba0[_0x8a3931([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x8a3931([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x8a3931([0x56,0x61,0x6c,0x69,0x64]);})[_0x8a3931([0x74,0x68,0x65,0x6e])](_0x577ca0=>(_0x323cee(),_0x577ca0),()=>{const _0x2fe6da=_0x573332();return null==_0x2fe6da?(_0x323cee(),_0x8a3931([0x56,0x61,0x6c,0x69,0x64])):_0x8a3931(_0x567523-_0x2fe6da>(0x5778dc5f^_0x482e6f)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x8a3931([0x74,0x68,0x65,0x6e])](_0x54869c)[_0x8a3931([0x63,0x61,0x74,0x63,0x68])](()=>{_0x54869c(_0x8a3931([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x34f165=0x7342b6df^_0x482e6f;function _0x323cee(){const _0x3a6461=_0x8a3931([0x6c,0x6c,0x63,0x74,0x2d])+_0x26136a(_0x357803(_0x3e47af)),_0x5efd54=_0x481a01(_0x26136a(window[_0x8a3931([0x4d,0x61,0x74,0x68])][_0x8a3931([0x63,0x65,0x69,0x6c])](_0x567523/_0x34f165)));window[_0x8a3931([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x8a3931([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x3a6461,_0x5efd54);}function _0x573332(){const _0x5a3be7=_0x8a3931([0x6c,0x6c,0x63,0x74,0x2d])+_0x26136a(_0x357803(_0x3e47af)),_0x4569e6=window[_0x8a3931([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x8a3931([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x5a3be7);return _0x4569e6?window[_0x8a3931([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x481a01(_0x4569e6),0x10)*_0x34f165:null;}function _0x59494a(_0x4e8863){return new window[(_0x8a3931([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x1cbe04,_0x52e813)=>{_0x4e8863[_0x8a3931([0x74,0x68,0x65,0x6e])](_0x1cbe04,_0x52e813),window[_0x8a3931([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x52e813,0x73758c9f^_0x482e6f);});}}_0x50168b[_0x8a3931([0x6f,0x6e])](_0x8a3931([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x4ca058,_0x512d6c)=>{if(_0x512d6c[0x0]!=_0x3e47af)return _0x54869c(_0x8a3931([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x512d6c[0x1]={..._0x512d6c[0x1],[_0x8a3931([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x43b926};},{[_0x8a3931([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x8a3931([0x68,0x69,0x67,0x68])}),_0x50168b[_0x8a3931([0x6f,0x6e])](_0x8a3931([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x43f4fe=>{_0x30c5ec(_0x43f4fe[_0x8a3931([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x36f885=!0x0,_0x2ba6e9(_0x43f4fe[_0x8a3931([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x8a3931([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x8a3931([0x6c,0x6f,0x77])}),_0xa570[_0x8a3931([0x74,0x68,0x65,0x6e])](()=>{_0x36f885||_0x54869c(_0x8a3931([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x3748bd(){return _0x50168b[_0x8a3931([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x8a3931([0x76,0x69,0x65,0x77])][_0x8a3931([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x8a3931([0x61,0x75,0x74,0x6f]);}function _0x21bed7(){_0x50168b[_0x8a3931([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x8a3931([0x76,0x69,0x65,0x77])][_0x8a3931([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x8a3931([0x61,0x75,0x74,0x6f]);}}function _0x3d4018(_0x23de4c){const _0x1eb4e8=[new window[(_0x8a3931([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x1c2658=>setTimeout(_0x1c2658,0x737d6693^_0x482e6f)),_0xa570[_0x8a3931([0x74,0x68,0x65,0x6e])](()=>new window[(_0x8a3931([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0xa5ef79=>{const _0x3b2355=0x73745858^_0x482e6f,_0x249925=_0x2bb360[_0x8a3931([0x5f,0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x73])];function _0x4bef23(){_0x249925[_0x8a3931([0x6c,0x65,0x6e,0x67,0x74,0x68])]>=_0x3b2355&&_0xa5ef79();}_0x4bef23(),_0x249925[_0x8a3931([0x6f,0x6e])](_0x8a3931([0x61,0x64,0x64]),_0x4bef23);})),new window[(_0x8a3931([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x1a6540=>{function _0x3e473a(){for(const _0x3d9534 in window)if(window[_0x8a3931([0x4e,0x75,0x6d,0x62,0x65,0x72])]['isNaN'](window[_0x8a3931([0x4e,0x75,0x6d,0x62,0x65,0x72])](_0x3d9534))&&window[_0x3d9534]==_0x2395b0)return _0x1a6540();_0x50168b[_0x8a3931([0x73,0x74,0x61,0x74,0x65])]!=_0x8a3931([0x64,0x65,0x73,0x74,0x72,0x6f,0x79,0x65,0x64])&&window[_0x8a3931([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x3e473a,0x73744bd7^_0x482e6f);}_0x63e73f(_0x8a3931([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))&&_0x3e473a();})];return window[_0x8a3931([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x8a3931([0x72,0x61,0x63,0x65])](_0x1eb4e8)[_0x8a3931([0x74,0x68,0x65,0x6e])](()=>_0x23de4c);}async function _0x5804ec(){if(await _0xa570,_0x63e73f(_0x8a3931([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))){const _0x53d331=_0x2bb360[_0x8a3931([0x67,0x65,0x74,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](0x0),_0x5a7cf8=_0x2bb360[_0x8a3931([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])](_0x53d331[_0x8a3931([0x69,0x64])]),_0x231c54=_0x5cf4ad(_0x8a3931([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]));return await _0x231c54[_0x8a3931([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])](_0x53d331['id'],_0x5a7cf8?_0x5a7cf8['id']:null,!0x0),_0x231c54[_0x8a3931([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x8a3931([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x231c54[_0x8a3931([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x231c54[_0x8a3931([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])]=_0x5bf147,void(_0x231c54[_0x8a3931([0x5f,0x67,0x65,0x74,0x44,0x69,0x66,0x66])]=_0x5bf147);}if(_0x63e73f(_0x8a3931([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]))){const _0x2e5f2b=_0x5cf4ad(_0x8a3931([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]));_0x2e5f2b[_0x8a3931([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x8a3931([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x2e5f2b[_0x8a3931([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x2e5f2b[_0x8a3931([0x75,0x70,0x64,0x61,0x74,0x65])]=_0x5bf147,_0x2e5f2b[_0x8a3931([0x73,0x61,0x76,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])]=_0x5bf147;}_0x50168b[_0x8a3931([0x6d,0x6f,0x64,0x65,0x6c])][_0x8a3931([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x5bf147,_0x50168b[_0x8a3931([0x6d,0x6f,0x64,0x65,0x6c])][_0x8a3931([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x5bf147,_0x50168b[_0x8a3931([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x8a3931([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x377302(){return _0x63e73f(_0x8a3931([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x5cf4ad(_0x8a3931([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x8a3931([0x73,0x74,0x61,0x74,0x65])]==_0x8a3931([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x563cca(){return _0x63e73f(_0x8a3931([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 _0x1d7145(){return _0x63e73f(_0x8a3931([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0x4dacc0(_0x42670c){const _0x107f32=_0x25902f();_0x50168b[_0x107f32]=_0x8a3931([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])+_0x42670c,_0x42670c[_0x8a3931([0x65,0x6e,0x64,0x73,0x57,0x69,0x74,0x68])](_0x8a3931([0x4c,0x69,0x6d,0x69,0x74]))&&(window[_0x25902f()]=_0x2395b0),_0x42670c!=_0x8a3931([0x56,0x61,0x6c,0x69,0x64])&&_0x5804ec();}function _0x25902f(){const _0x147be3=window[_0x8a3931([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x8a3931([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x8a3931([0x6e,0x6f,0x77])]())[_0x8a3931([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x8a3931([0x2e]),'');let _0x104b41=_0x8a3931([0x73]);for(let _0x452b0e=0x0;_0x452b0e<_0x147be3[_0x8a3931([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x452b0e+=0x2){let _0x8ad3dd=window[_0x8a3931([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x147be3[_0x8a3931([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x452b0e,_0x452b0e+0x2));_0x8ad3dd>=_0x2a753a[_0x8a3931([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x8ad3dd-=_0x2a753a[_0x8a3931([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x104b41+=_0x2a753a[_0x8ad3dd];}return _0x104b41;}function _0x2ceb31(){const _0x813d38=_0x1749d2[_0x8a3931([0x73,0x70,0x6c,0x69,0x74])](_0x8a3931([0x2e]));if(0x3!=_0x813d38[_0x8a3931([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0xf223a5(_0x813d38[0x1]);function _0xf223a5(_0x42f0ba){const _0x39eb59=_0xe8d374(_0x42f0ba);return _0x39eb59&&_0x9d501c()?_0x39eb59:null;function _0x9d501c(){const _0x200cc6=_0x39eb59[_0x8a3931([0x6a,0x74,0x69])],_0x2dd24c=window[_0x8a3931([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x200cc6[_0x8a3931([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x200cc6[_0x8a3931([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x3f7cc2={..._0x39eb59,[_0x8a3931([0x6a,0x74,0x69])]:_0x200cc6[_0x8a3931([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x200cc6[_0x8a3931([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x3f7cc2[_0x8a3931([0x76,0x63])],_0x357803(_0x3f7cc2)==_0x2dd24c;}}}async function _0x31ff92(){let _0x346d53=!0x0;try{const _0x1032ff=_0x1749d2[_0x8a3931([0x73,0x70,0x6c,0x69,0x74])](_0x8a3931([0x2e])),[_0x45a68b,_0x4ef059,_0x45ef00]=_0x1032ff;return _0x48b73(_0x45a68b),await _0x14b96c(_0x45a68b,_0x4ef059,_0x45ef00),_0x346d53;}catch{return!0x1;}function _0x48b73(_0x53c46d){const _0x3801bd=_0xe8d374(_0x53c46d);_0x3801bd&&_0x3801bd[_0x8a3931([0x61,0x6c,0x67])]==_0x8a3931([0x45,0x53,0x32,0x35,0x36])||(_0x346d53=!0x1);}async function _0x14b96c(_0x29ffcc,_0x2318fd,_0x286858){const _0x151749=window[_0x8a3931([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x8a3931([0x66,0x72,0x6f,0x6d])](_0x236a21(_0x286858),_0x14dd20=>_0x14dd20[_0x8a3931([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x34ad5b=new window[(_0x8a3931([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x8a3931([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x29ffcc+_0x8a3931([0x2e])+_0x2318fd),_0x5e6bf1=window[_0x8a3931([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x8a3931([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x5e6bf1)return;const _0x4beeb6=await _0x5e6bf1[_0x8a3931([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x8a3931([0x6a,0x77,0x6b]),_0x49363d,{[_0x8a3931([0x6e,0x61,0x6d,0x65])]:_0x8a3931([0x45,0x43,0x44,0x53,0x41]),[_0x8a3931([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x8a3931([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x8a3931([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x5e6bf1[_0x8a3931([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x8a3931([0x6e,0x61,0x6d,0x65])]:_0x8a3931([0x45,0x43,0x44,0x53,0x41]),[_0x8a3931([0x68,0x61,0x73,0x68])]:{[_0x8a3931([0x6e,0x61,0x6d,0x65])]:_0x8a3931([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x4beeb6,_0x151749,_0x34ad5b)||(_0x346d53=!0x1);}}function _0xe8d374(_0x44f5f0){return _0x44f5f0[_0x8a3931([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x8a3931([0x65,0x79]))?JSON[_0x8a3931([0x70,0x61,0x72,0x73,0x65])](_0x236a21(_0x44f5f0)):null;}function _0x236a21(_0x3ef11d){return window[_0x8a3931([0x61,0x74,0x6f,0x62])](_0x3ef11d[_0x8a3931([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x8a3931([0x2b]))[_0x8a3931([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x8a3931([0x2f])));}function _0x357803(_0x66bce9){let _0x526f17=0x1505;function _0x3bdd90(_0x7c40fb){for(let _0x1d0500=0x0;_0x1d0500<_0x7c40fb[_0x8a3931([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x1d0500++){const _0x2b3af5=_0x7c40fb[_0x8a3931([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x1d0500);_0x526f17=(_0x526f17<<0x5)+_0x526f17+_0x2b3af5,_0x526f17&=_0x526f17;}}function _0x3067e6(_0x1fba11){Array[_0x8a3931([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x1fba11)?_0x1fba11[_0x8a3931([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x3067e6):_0x1fba11&&typeof _0x1fba11==_0x8a3931([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x8a3931([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x1fba11)[_0x8a3931([0x73,0x6f,0x72,0x74])]()[_0x8a3931([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x270ae3,_0x3bdfd6])=>{_0x3bdd90(_0x270ae3),_0x3067e6(_0x3bdfd6);}):_0x3bdd90(window[_0x8a3931([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x1fba11));}return _0x3067e6(_0x66bce9),_0x526f17>>>0x0;}function _0x26136a(_0x1adda1){return _0x1adda1[_0x8a3931([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x8a3931([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x8a3931([0x30]));}function _0x481a01(_0x492b96){return _0x492b96[_0x8a3931([0x73,0x70,0x6c,0x69,0x74])]('')[_0x8a3931([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x8a3931([0x6a,0x6f,0x69,0x6e])]('');}function _0x63e73f(_0x143e2f){return _0x50168b[_0x8a3931([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x8a3931([0x68,0x61,0x73])](_0x143e2f);}function _0x5cf4ad(_0x4a6d1b){return _0x50168b[_0x8a3931([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x8a3931([0x67,0x65,0x74])](_0x4a6d1b);}function _0x5bf147(){}function _0x8a3931(_0x2b0a14){return _0x2b0a14['map'](_0x3ba4dd=>String['fromCharCode'](_0x3ba4dd))['join']('');}_0x4dacc0(await _0x7bccac());}(this);}['createRevision'](_0x4b2747){const _0x4c4a82=this['editor']['plugins']['get']('Users');return new I({'id':_0x4b2747['id'],'name':_0x4b2747['name'],'creator':_0x4b2747['creatorId']?_0x4c4a82['getUser'](_0x4b2747['creatorId']):null,'diffData':_0x4b2747['diffData']||_0x4b2747['data'],'authors':_0x4b2747['authorsIds']['map'](_0x4ef13d=>_0x4c4a82['getUser'](_0x4ef13d)),'createdAt':new Date(_0x4b2747['createdAt']),'attributes':_0x4b2747['attributes'],'fromVersion':_0x4b2747['fromVersion'],'toVersion':_0x4b2747['toVersion']});}['addRevision'](_0x4e25f8,_0x2c557e=0x0){this['_revisions']['add'](_0x4e25f8,_0x2c557e);}['getRevision'](_0x14accb){return this['_revisions']['get'](_0x14accb);}['getRevisions'](_0xd04612={'toJSON':!0x1}){const _0x9c7fa4=Array['from'](this['_revisions']);return _0x9c7fa4['reverse'](),_0xd04612['toJSON']?_0x9c7fa4['map'](_0x3da48c=>_0x3da48c['toJSON']()):_0x9c7fa4;}['getIndex'](_0x3ab1a2){return this['_revisions']['getIndex'](_0x3ab1a2);}['getEarlierVisibleRevision'](_0x17bfa7){const [,_0x583dae]=this['getRevisionsIterator'](_0x17bfa7,{'direction':'earlier'});return _0x583dae;}['getLaterVisibleRevision'](_0xf5b29d){const [,_0x305aa2]=this['getRevisionsIterator'](_0xf5b29d,{'direction':'later'});return _0x305aa2;}['getRevisionsInDiff'](_0x26a021){const _0x3d2eaa=[];for(const _0x1f7a24 of this['getRevisionsIterator'](_0x26a021['newRevisionId']))if(_0x3d2eaa['push'](_0x1f7a24),_0x1f7a24['id']===_0x26a021['oldRevisionId'])break;return _0x3d2eaa;}*['getRevisionsIterator'](_0x76629d,{direction:_0x27c0a2='earlier',filter:_0x162ab4=()=>!0x0}={}){const _0x5b442e='earlier'===_0x27c0a2?0x1:-0x1;let _0x44d351=this['_revisions']['get'](_0x76629d),_0x35d76d=this['getIndex'](_0x44d351);for(yield _0x44d351;_0x44d351;){if(_0x35d76d+=_0x5b442e,_0x44d351=this['getRevision'](_0x35d76d),!_0x44d351)return;_0x162ab4(_0x44d351)&&(yield _0x44d351);}}}class $ extends _0x278e34{static get['pluginName'](){return'RevisionHistoryUtils';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['_viewClassToTypeChar']=new Map([[_0x208ffc,'c'],[_0x493eb1,'a'],[_0x5b4d65,'e'],[_0x397b2a,'r'],[_0x4ef9e2,'u']]);['_typeCharToViewClass']=new Map([['c',_0x208ffc],['a',_0x493eb1],['e',_0x5b4d65],['r',_0x397b2a],['u',_0x4ef9e2]]);async['loadRevisionData'](_0x121dbf,_0x462f43){if(_0x121dbf['diffData']||!_0x462f43)return;const _0x411ab3=this['editor']['config']['get']('collaboration.channelId'),_0xbd17a0=await _0x462f43['getRevision']({'channelId':_0x411ab3,'revisionId':_0x121dbf['id']});_0x121dbf['diffData']=_0xbd17a0['diffData'];}['getRevisionDocumentData'](_0x3e1a81){const _0x3180a0={};for(const _0x269d3e in _0x3e1a81['diffData']){if(_0x3e1a81['diffData'][_0x269d3e]['attachChange']&&!_0x3e1a81['diffData'][_0x269d3e]['attachChange']['isAttached'])continue;const _0x3e7bb9=this['_removeRevisionMarkers'](JSON['parse'](_0x3e1a81['diffData'][_0x269d3e]['insertions'])),_0x2742a9=this['editor']['editing']['view']['document'],_0xc68111=new _0x2691f3(_0x2742a9,_0x3e7bb9['map'](_0x2856b3=>this['_getViewFromDiffObj'](_0x2856b3,!0x1)));this['editor']['data']['processor']['useFillerType']('marked'),_0x3180a0[_0x269d3e]=this['editor']['data']['processor']['toData'](_0xc68111),this['editor']['data']['processor']['useFillerType']('default');}return _0x3180a0;}['getRevisionRootsAttributes'](_0x115f33){const _0x5f2443={};for(const _0x5cf715 in _0x115f33['diffData'])_0x115f33['diffData'][_0x5cf715]['attachChange']&&!_0x115f33['diffData'][_0x5cf715]['attachChange']['isAttached']||(_0x5f2443[_0x5cf715]=_0x115f33['diffData'][_0x5cf715]['attributesAfter']||{});return _0x5f2443;}['_getTypeCharForViewElement'](_0xdaeea8){return this['_viewClassToTypeChar']['get'](_0xdaeea8['constructor']);}['_getViewFromDiffObj'](_0x4b100d,_0x41d566){const _0x561f49=this['editor']['editing']['view']['document'];if('string'==typeof _0x4b100d)return new _0x1ffa98(_0x561f49,_0x4b100d);{let _0x39b52c,_0x55a8b1;_0x55a8b1='u'==_0x4b100d['type']||'r'==_0x4b100d['type']?[]:_0x4b100d['children']['map'](_0x341e28=>this['_getViewFromDiffObj'](_0x341e28,_0x41d566));const _0xa99c7c=this['_typeCharToViewClass']['get'](_0x4b100d['type'])||_0x1d49d0,_0x537dd3=this['editor']['data']['htmlProcessor']['domConverter'];if(_0x39b52c=new _0xa99c7c(_0x561f49,_0x4b100d['name'],_0x4b100d['attributes'],_0x55a8b1),'u'==_0x4b100d['type']&&_0x4b100d['children'][0x0]){const _0x3d5560=_0x4b100d['children'][0x0];if(_0x39b52c['render']=function(_0x36eacb){const _0x40ae62=_0x36eacb['createElement']('div');return _0x40ae62['innerHTML']=_0x3d5560,_0x40ae62['childNodes'][0x0];},_0x41d566){const _0x4a320d=new _0x2691f3(_0x561f49);_0x4a320d['_appendChild'](_0x39b52c);const _0x3f8190=Array['from'](_0x537dd3['viewChildrenToDom'](_0x4a320d,{'bind':!0x1})),_0x1acd48=_0x537dd3['domDocument']['createElement']('div');_0x1acd48['append'](..._0x3f8190),_0x39b52c=Array['from'](_0x537dd3['domChildrenToView'](_0x1acd48))[0x0];}}else{if('r'==_0x4b100d['type']&&_0x4b100d['children'][0x0]){const _0x448fbd=_0x4b100d['children'][0x0];if(_0x39b52c['render']=function(_0x3fb64a){_0x3fb64a['innerHTML']=_0x448fbd;},_0x41d566){const _0x3e455e=new _0x2691f3(_0x561f49);_0x3e455e['_appendChild'](_0x39b52c);const _0x720588=Array['from'](_0x537dd3['viewChildrenToDom'](_0x3e455e,{'bind':!0x1})),_0x311001=_0x537dd3['domDocument']['createElement']('div');_0x311001['append'](..._0x720588);const _0x493958=Array['from'](_0x537dd3['domChildrenToView'](_0x311001));_0x493958['length']>0x1?_0x39b52c['_appendChild'](_0x493958):_0x39b52c=_0x493958[0x0];}}}if(_0x4b100d['customProperties']){for(const [_0x47cd78,_0x329461]of _0x4b100d['customProperties'])_0x39b52c['_setCustomProperty'](_0x47cd78,_0x329461);}const _0x5b2b02=void 0x0===_0x4b100d['fillerOffset']?null:_0x4b100d['fillerOffset'];return null!==_0x5b2b02&&(_0x39b52c['getFillerOffset']=()=>_0x5b2b02),_0x39b52c;}}['_makeModelFromViewString'](_0x48dfc5){const _0x96f621=JSON['parse'](_0x48dfc5),_0x936f04=this['editor']['editing']['view']['document'],_0x1fac11=new _0x2691f3(_0x936f04,_0x96f621['map'](_0x55c1aa=>this['_getViewFromDiffObj'](_0x55c1aa,!0x0)));return this['editor']['data']['toModel'](_0x1fac11);}['_removeRevisionMarkers'](_0x4ea098){return(_0x4ea098=_0x4ea098['filter'](_0xd746f1=>!_0xd746f1['name']||'revision-start'!==_0xd746f1['name']&&'revision-end'!==_0xd746f1['name']))['forEach'](_0x478831=>{'string'!=typeof _0x478831&&(_0x478831['children']=this['_removeRevisionMarkers'](_0x478831['children']),_0x478831['attributes']=_0x478831['attributes']['filter'](_0x2ba54c=>!_0x2ba54c[0x0]['startsWith']('data-revision-')));}),_0x4ea098;}}function R(_0x58c558,_0x1338e3,_0x3c2f21){const t=_0x58c558['t'];switch(_0x1338e3){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'},_0x3c2f21);case'X_OF_Y_CHANGES':return t({'string':'%0\x20of\x20%1','id':'X_OF_Y_CHANGES'},_0x3c2f21);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 _0x278e34{['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[_0x3fef6b,S,$,_0xa1ccf3];}constructor(_0x596300){super(_0x596300),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 _0x19c50a=_0x515d40();this['_source']={'history':this['editor']['model']['document']['history'],'getLatestVersion':()=>Promise['resolve'](this['editor']['model']['document']['version']),'getCurrentRevisionId':()=>_0x19c50a},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 _0x47a4d2=this['repository']['getRevision'](0x0),_0x3e2c49=_0x47a4d2&&null===_0x47a4d2['creator']?_0x47a4d2:null;if(this['_continueCurrentRevision']=!!_0x3e2c49&&this['editor']['config']['get']('revisionHistory.resumeUnsavedRevision'),this['editor']['plugins']['has']('RealTimeCollaborationClient')){const _0x232315=this['_source']['getCurrentRevisionId'](),_0x8fedbd=this['repository']['getRevision'](_0x232315);if(_0x8fedbd)this['_startingVersion']=_0x8fedbd['fromVersion'],this['_continueCurrentRevision']=!0x1;else{const _0x32e91f=this['_source']['history']['_operations']['find'](_0x274ab8=>!_0x274ab8['_isInit']),_0x244d6b=_0x32e91f?_0x32e91f['baseVersion']:this['_source']['history']['version'];_0x47a4d2?(_0x47a4d2['toVersion']<_0x244d6b&&_0x47a4d2['_update']({'toVersion':_0x244d6b}),this['_continueCurrentRevision']?(this['_source']['getCurrentRevisionId']=()=>_0x3e2c49['id'],this['_startingVersion']=_0x3e2c49['fromVersion']):(this['_startingVersion']=_0x47a4d2['toVersion'],this['_continueCurrentRevision']=!0x1)):(this['_startingVersion']=_0x244d6b,this['_continueCurrentRevision']=!0x1);}}else _0x3e2c49&&(this['editor']['model']['document']['history']['version']=Math['max'](_0x3e2c49['toVersion'],this['editor']['model']['document']['history']['version']),_0x3e2c49['fromVersion']===_0x3e2c49['toVersion']?(0x0!==_0x3e2c49['fromVersion']&&(this['_source']['getCurrentRevisionId']=()=>_0x3e2c49['id']),this['_continueCurrentRevision']=!0x1):this['_continueCurrentRevision']&&(this['_source']['getCurrentRevisionId']=()=>_0x3e2c49['id'],this['_startingVersion']=_0x3e2c49['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',_0xd7cf3d=>!_0xd7cf3d),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x442839=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x56ef47;for(const _0x1f5a73 in _0x442839){const _0x2c4ef7=_0x1f5a73,_0x4385e7=_0x442839[_0x2c4ef7];if('revisionHistoryLicenseKeyValid'==_0x4385e7||'revisionHistoryLicenseKeyInvalid'==_0x4385e7||'revisionHistoryLicenseKeyExpired'==_0x4385e7||'revisionHistoryLicenseKeyDomainLimit'==_0x4385e7||'revisionHistoryLicenseKeyNotAllowed'==_0x4385e7||'revisionHistoryLicenseKeyEvaluationLimit'==_0x4385e7||'revisionHistoryLicenseKeyTrialLimit'==_0x4385e7||'revisionHistoryLicenseKeyUsageLimit'==_0x4385e7){delete _0x442839[_0x2c4ef7],_0x56ef47=_0x4385e7,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'revisionHistoryLicenseKeyInvalid'==_0x56ef47&&_0x442839['_showLicenseError']('invalid'),'revisionHistoryLicenseKeyExpired'==_0x56ef47&&_0x442839['_showLicenseError']('expired'),'revisionHistoryLicenseKeyDomainLimit'==_0x56ef47&&_0x442839['_showLicenseError']('domainLimit'),'revisionHistoryLicenseKeyNotAllowed'==_0x56ef47&&_0x442839['_showLicenseError']('featureNotAllowed','RevisionHistory'),'revisionHistoryLicenseKeyEvaluationLimit'==_0x56ef47&&_0x442839['_showLicenseError']('evaluationLimit'),'revisionHistoryLicenseKeyTrialLimit'==_0x56ef47&&_0x442839['_showLicenseError']('trialLimit'),'revisionHistoryLicenseKeyUsageLimit'==_0x56ef47&&_0x442839['_showLicenseError']('usageLimit');},0x3e8);}async['afterInit'](){if(this['repository']['length']>0x0){const _0x119251=this['repository']['getRevision'](0x0),_0x269a8a=await this['getRevisionDocumentData'](_0x119251),_0x3c4a11=await this['getRevisionRootsAttributes'](_0x119251);this['_replaceEditorDataWithRevisionData'](_0x269a8a,_0x3c4a11);}}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['setSource'](_0x40bd83){this['_source']=_0x40bd83;}async['update'](){const _0x539f82=await this['_source']['getLatestVersion']();if(_0x539f82>this['currentRevision']['toVersion']){await this['_loadState']();const _0x5dd093=this['buildRevisionData']({'revision':this['currentRevision'],'to':_0x539f82});_0x5dd093['authors']=_0x5dd093['authorsIds']['map'](_0x2c93f9=>this['editor']['plugins']['get']('Users')['getUser'](_0x2c93f9)),this['currentRevision']['_update'](_0x5dd093);}}async['saveRevision'](_0x3f4763={},_0x3950dd=null){const _0x140840=[];await this['_loadState'](),this['_continueCurrentRevision']=!0x1,_0x3950dd>this['currentRevision']['toVersion']&&(_0x3950dd=null),null===_0x3950dd&&(_0x3950dd=await this['_source']['getLatestVersion']());const _0x30dc77=this['_getFromVersion'](_0x3950dd),_0x250ca4=this['buildRevisionData']({'from':_0x30dc77,'to':_0x3950dd});if(this['currentRevision']['toVersion']<_0x3950dd){const _0x57e2af=this['buildRevisionData']({'revision':this['currentRevision'],'from':_0x3950dd,'to':_0x3950dd});_0x57e2af['authors']=[],_0x57e2af['authorsIds']=[],_0x57e2af['id']=this['currentRevision']['id'],this['currentRevision']['_update'](_0x57e2af,!0x0),delete _0x57e2af['authors'],_0x140840['push'](_0x57e2af);}_0x3f4763['creatorId']=this['editor']['plugins']['get']('Users')['me']['id'],_0x3f4763['name']=_0x3f4763['name']||null,_0x3f4763['id']=_0x3f4763['id']||_0x515d40(),_0x3f4763={..._0x3f4763,..._0x250ca4};const _0x80f118=this['addRevisionData'](_0x3f4763);_0x140840['push'](_0x3f4763);const _0x28bc1b=this['repository']['getIndex'](_0x80f118);if(0x0!==_0x28bc1b){const _0x134aa0=this['repository']['getRevision'](_0x28bc1b-0x1);if(_0x134aa0['fromVersion']!==_0x3950dd){const _0x34f219=this['_revisionDataBuilder']['getData'](_0x3950dd,_0x134aa0['toVersion']),_0x1d3c3f={'id':_0x134aa0['id'],'diffData':_0x34f219['diffData'],'authorsIds':_0x34f219['authorsIds'],'authors':_0x34f219['authorsIds']['map'](_0x474c0a=>this['editor']['plugins']['get']('Users')['getUser'](_0x474c0a)),'fromVersion':_0x3950dd};_0x134aa0===this['currentRevision']&&(_0x1d3c3f['createdAt']=new Date(_0x3f4763['createdAt']['getTime']()+0xa)),_0x134aa0['_update'](_0x1d3c3f,!0x0),delete _0x1d3c3f['authors'],_0x140840['push'](_0x1d3c3f);}}if(this['adapter']){for(const _0x59815b of _0x140840)this['_bufferUpdate'](_0x59815b['id'],_0x59815b,!0x0);this['sendBufferedUpdates']();}return _0x80f118;}['addRevisionData'](_0x3ab346){const _0x21c6d4=this['repository']['createRevision'](_0x3ab346);return this['adapter']&&_0x21c6d4['on']('_update',(_0x1a1d1b,_0x1acf23,_0x3912ad)=>{_0x3912ad||(this['_bufferUpdate'](_0x1acf23['id'],_0x1acf23,!0x0),this['sendBufferedUpdates']());}),this['repository']['addRevision'](_0x21c6d4,this['_findInsertionIndex'](_0x21c6d4)),_0x21c6d4;}async['getRevisionDocumentData'](_0x3c06ee){return await this['_utils']['loadRevisionData'](_0x3c06ee,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x3c06ee);}async['getRevisionRootsAttributes'](_0x184bcf){return await this['_utils']['loadRevisionData'](_0x184bcf,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x184bcf);}['sendBufferedUpdates'](){if(0x0===this['_bufferedUpdates']['size'])return;if(this['_isPendingUpdate'])return;let _0xfa4199=Array['from'](this['_bufferedUpdates']['values']());this['_bufferedUpdates']['clear']();for(let _0x414319=0x0;_0x414319<_0xfa4199['length'];_0x414319++){const _0x30cd90=_0xfa4199[_0x414319];let _0x1fc0ce=!0x1;for(const _0x2b4602 of Object['keys'](_0x30cd90))void 0x0===_0x30cd90[_0x2b4602]?delete _0x30cd90[_0x2b4602]:'id'!==_0x2b4602&&(_0x1fc0ce=!0x0);_0x1fc0ce||(_0xfa4199[_0x414319]=null);}if(_0xfa4199=_0xfa4199['filter'](_0xdb77a1=>null!==_0xdb77a1),!_0xfa4199['length'])return;for(let _0x165392=0x0;_0x165392<_0xfa4199['length'];_0x165392++){const _0x2902d1=_0xfa4199[_0x165392];void 0x0!==_0x2902d1['fromVersion']&&void 0x0===_0x2902d1['toVersion']&&(_0x2902d1['toVersion']=this['repository']['getRevision'](_0x2902d1['id'])['toVersion']),void 0x0!==_0x2902d1['toVersion']&&void 0x0===_0x2902d1['fromVersion']&&(_0x2902d1['fromVersion']=this['repository']['getRevision'](_0x2902d1['id'])['fromVersion']);}const _0x1d8b30=this['editor']['config']['get']('collaboration.channelId');this['_isPendingUpdate']=!0x0,this['_addPendingAction'](),this['adapter']['updateRevisions'](_0xfa4199,_0x1d8b30)['finally'](()=>{this['_isPendingUpdate']=!0x1;})['then'](_0x3fda85=>{if(_0x3fda85){for(const _0x48714a of _0x3fda85)this['setRevisionData']({'id':_0x48714a['id'],'createdAt':_0x48714a['createdAt']});}this['_removePendingAction'](),this['sendBufferedUpdates']();});}['buildRevisionData']({revision:_0x4e5940=null,from:_0x25ccf9=null,to:_0x5f4cf2=null}){_0x25ccf9=null!==_0x25ccf9?_0x25ccf9:_0x4e5940['fromVersion'],_0x5f4cf2=null!==_0x5f4cf2?_0x5f4cf2:_0x4e5940['toVersion'];const _0x3312e7=this['_revisionDataBuilder']['getData'](_0x25ccf9,_0x5f4cf2),_0x2340a1={'diffData':_0x3312e7['diffData'],'authorsIds':_0x3312e7['authorsIds'],'fromVersion':_0x25ccf9,'toVersion':_0x5f4cf2};if(!_0x4e5940||_0x5f4cf2!==_0x4e5940['toVersion']){const _0x1c1b50=_0x5f4cf2-0x1,_0x2ef136=this['_source']['history']['getOperation'](_0x1c1b50);_0x2340a1['createdAt']=_0x2ef136&&_0x2ef136['createdAt']||new Date();}if(this['_loadedStateData']&&_0x25ccf9===this['_loadedStateData']['fromVersion']){for(const _0x2b435a of this['_loadedStateData']['authors'])_0x2340a1['authorsIds']['includes'](_0x2b435a['id'])||_0x2340a1['authorsIds']['push'](_0x2b435a['id']);}return _0x2340a1;}['_bufferUpdate'](_0xc85fb6,_0xa28f9e,_0xa56743){if(this['_bufferedUpdates']['has'](_0xc85fb6)){const _0x388c86=this['_bufferedUpdates']['get'](_0xc85fb6);_0xa28f9e=_0xa56743?{..._0x388c86,..._0xa28f9e}:{..._0xa28f9e,..._0x388c86};}this['_bufferedUpdates']['set'](_0xc85fb6,_0xa28f9e);}['setRevisionData'](_0x50d6c2){const _0x1119a9=this['repository']['getRevision'](_0x50d6c2['id']);if(_0x50d6c2['createdAt']&&(_0x50d6c2['createdAt']=new Date(_0x50d6c2['createdAt'])),_0x50d6c2['authorsIds']){const _0x1583e2=this['editor']['plugins']['get']('Users');_0x50d6c2['authors']=_0x50d6c2['authorsIds']['map'](_0x2b0276=>_0x1583e2['getUser'](_0x2b0276));}_0x1119a9['_update'](_0x50d6c2,!0x0);}['_createInitialRevision'](_0x40fb42){const _0x15d3a1=this['repository']['getRevision'](this['repository']['length']-0x1);if(_0x15d3a1)this['_initialRevisionId']=_0x15d3a1['id'];else{const _0x1b9ba3=!this['editor']['model']['document']['roots']['find'](_0x1d19d6=>this['editor']['model']['hasContent'](_0x1d19d6)),_0x23412f=this['editor']['plugins']['get']('Users')['me']['id'],_0x1779a3=R(this['editor']['locale'],_0x1b9ba3?'Empty\x20document':'Initial\x20revision');this['_makeRevision']({'from':_0x40fb42,'to':_0x40fb42,'id':this['_initialRevisionId'],'name':_0x1779a3,'creatorId':_0x23412f});}}['_createCurrentRevision'](_0x208d7c){const _0xd72c4c=this['_source']['getCurrentRevisionId']();this['currentRevision']=this['repository']['getRevision'](_0xd72c4c),this['currentRevision']||(this['currentRevision']=this['_makeRevision']({'from':_0x208d7c,'to':_0x208d7c,'id':_0xd72c4c,'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'](_0x47da48,_0x522118){let _0x27f2f5=this['editor']['config']['get']('initialData'),_0x1a14e9=this['editor']['config']['get']('rootsAttributes');if(void 0x0===_0x27f2f5){_0x27f2f5={};for(const _0x1ca35c of this['editor']['model']['document']['getRootNames']())_0x27f2f5[_0x1ca35c]='';}if('string'==typeof _0x27f2f5&&(_0x27f2f5={'main':_0x27f2f5}),void 0x0===_0x1a14e9){_0x1a14e9={};for(const _0xa6bfe6 of this['editor']['model']['document']['getRootNames']())_0x1a14e9[_0xa6bfe6]={};}let _0x4f57ea=!0x1;const _0x568a24=Object['keys'](_0x27f2f5),_0xbe833d=Object['keys'](_0x47da48);for(const _0x25e407 of _0x568a24){if(_0x27f2f5[_0x25e407]!==_0x47da48[_0x25e407]&&''!==_0x27f2f5[_0x25e407]['trim']()){_0x4f57ea=!0x0;break;}if(!_0x225aa4(_0x1a14e9[_0x25e407],_0x522118[_0x25e407])&&Object['keys'](_0x1a14e9[_0x25e407])['length']>0x0){_0x4f57ea=!0x0;break;}}_0x4f57ea||(_0x4f57ea=_0xbe833d['some'](_0x3c693f=>!this['editor']['model']['document']['getRoot'](_0x3c693f))),_0x4f57ea&&_0x271880('editor-initial-data-replaced-with-revision-data',{'editorData':_0x27f2f5,'editorRootsAttributes':_0x1a14e9,'revisionData':_0x47da48,'revisionRootsAttributes':_0x522118}),this['editor']['config']['set']('initialData',_0x47da48),this['editor']['config']['set']('rootsAttributes',_0x522118);}['_addPendingAction'](){if(!this['_pendingAction']){const _0x21d801=this['editor']['plugins']['get']('PendingActions');this['_pendingAction']=_0x21d801['add'](R(this['editor']['locale'],'PENDING_ACTION_REVISION_HISTORY'));}}['_removePendingAction'](){this['_pendingAction']&&(this['editor']['plugins']['get']('PendingActions')['remove'](this['_pendingAction']),this['_pendingAction']=null);}['_findInsertionIndex'](_0x3d833e){const _0x362a15=this['repository']['getRevisions']();_0x362a15['reverse']();let _0x2c95f7=0x0;for(;_0x2c95f7<_0x362a15['length'];){const _0x1944d0=_0x362a15[_0x2c95f7];if(_0x1944d0===this['currentRevision']){_0x2c95f7++;continue;}if(_0x1944d0['id']===this['_initialRevisionId'])break;const _0x24ef35=_0x3d833e['toVersion']-_0x1944d0['toVersion']||_0x3d833e['fromVersion']-_0x1944d0['fromVersion'];if(_0x24ef35>0x0)break;if(_0x24ef35<0x0)_0x2c95f7++;else{if(!_0x3d833e['creator']&&_0x1944d0['creator'])break;if(_0x1944d0['creator']||!_0x3d833e['creator']){if(_0x3d833e['createdAt']>_0x1944d0['createdAt'])break;_0x2c95f7++;}else _0x2c95f7++;}}return _0x2c95f7;}['_getFromVersion'](_0x215322){const _0x3384c0=this['repository']['getRevisions']();_0x3384c0['reverse'](),_0x3384c0['shift']();const _0x4bf1d9=_0x3384c0['find'](_0x258cba=>_0x258cba['toVersion']<=_0x215322)['toVersion'];return _0x4bf1d9<this['_startingVersion']?this['_startingVersion']:_0x4bf1d9;}['_makeRevision']({name:_0x5af20e,from:_0x45b05a,to:_0x564cb9,creatorId:_0xe4c99f,id:_0x47bf89}){const _0x3d04a0=this['buildRevisionData']({'from':_0x45b05a,'to':_0x564cb9});_0x3d04a0['name']=_0x5af20e,_0x3d04a0['creatorId']=_0xe4c99f,_0x3d04a0['id']=_0x47bf89;const _0x1fc5cd=this['addRevisionData'](_0x3d04a0);return this['adapter']&&this['_bufferUpdate'](_0x3d04a0['id'],_0x3d04a0,!0x0),_0x1fc5cd;}['_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(_0x580a49){this['editor']=_0x580a49,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'](_0x74a99c){this['source']=_0x74a99c;const _0x1e53a1=new Map(),_0x26cc37=new Map(),_0x5acddf=this['editor']['model']['document']['roots']['map'](_0x45e7ca=>_0x45e7ca['rootName']);for(const _0x5aea98 of _0x5acddf){const _0xa4f583=this['editor']['model']['document']['getRoot'](_0x5aea98),_0x120a1b=x(_0xa4f583);_0x1e53a1['set'](_0x5aea98,_0x120a1b),_0x26cc37['set'](_0x5aea98,Object['fromEntries'](_0xa4f583['getAttributes']()));}const _0x540bea=Array['from'](this['editor']['model']['markers'])['map'](_0x3391db=>[_0x3391db['name'],_0x3391db['getRange']()]),_0xc0f0fb=this['source']['version'];this['_saveMetaData'](_0xc0f0fb,_0x1e53a1,_0x540bea,_0x26cc37),this['_startingRevisionId']=this['_revisionId'];const _0x1c8fd1=new Map(),_0x50ac2d=new Map();for(const _0x302d5 of _0x5acddf){const _0x3f563e=N(_0x302d5);_0x1c8fd1['set'](_0x302d5,_0x3f563e),_0x50ac2d['set'](_0x302d5,{});}this['_saveMetaData'](Number['NEGATIVE_INFINITY'],_0x1c8fd1,[],_0x50ac2d);}['getData'](_0x5644a0,_0x674da9){if(this['_lastFrom']===_0x5644a0&&this['_lastTo']<=_0x674da9)this['_savedMetaData']['size']>0x1&&this['_removeMetaData'](this['_lastTo']),this['_applyOperations'](this['_lastTo'],_0x674da9,!0x0);else{if(!this['_savedMetaData']['has'](_0x5644a0)){const _0x52e1ed=this['_getPreviousFrom'](_0x5644a0);this['_calculateMetaData'](_0x52e1ed,_0x5644a0,!0x1);}this['_calculateMetaData'](_0x5644a0,_0x674da9,!0x0);}return this['_lastFrom']=_0x5644a0,this['_lastTo']=_0x674da9,this['_getState']();}['loadState'](_0x43a425){const _0x3f2b65=this['editor']['plugins']['get']('RevisionHistoryUtils');this['_reset'](),this['_lastFrom']=_0x43a425['fromVersion'],this['_lastTo']=_0x43a425['toVersion'];for(const _0x20e68a in _0x43a425['diffData']){const _0x386702=_0x43a425['diffData'][_0x20e68a]['attachChange'],_0xc2d846=_0x1fffc6(_0x43a425['diffData'][_0x20e68a]['attributesBefore'])||{},_0x2d55f9=_0x3f2b65['_makeModelFromViewString'](_0x43a425['diffData'][_0x20e68a]['deletions']);_0x2d55f9['rootName']=_0x20e68a,_0x2d55f9['_isAttached']=!_0x386702||!_0x386702['isAttached'],_0x2d55f9['isAttached']=()=>_0x2d55f9['_isAttached'],this['_baseRoots']['set'](_0x20e68a,_0x2d55f9),this['_baseRootsAttributes']['set'](_0x20e68a,_0xc2d846),_0x386702&&this['_touchedRoots']['set'](_0x20e68a,_0x386702);const _0x194f92=this['_makeIdsRoot'](_0x2d55f9);this['_baseIdsRoots']['set'](_0x20e68a,_0x194f92);for(const [_0x1aa42b,_0x228bfe]of _0x2d55f9['markers']){if(!_0x1aa42b['startsWith']('revision:'))continue;const _0xdc5348=_0x1aa42b['split'](':')[0x2];for(const _0x1075c2 of _0x228bfe['getWalker']({'singleCharacters':!0x0})){const _0x2694ec=this['_getVidAttributeName'](_0x1075c2),_0x240f00='elementEnd'==_0x1075c2['type']?_0x1075c2['previousPosition']['path']['slice'](0x0,-0x1):_0x1075c2['previousPosition']['path'],_0x2fb4a6=_0x194f92['getNodeByPath'](_0x240f00)['getAttribute'](_0x2694ec);this['_touched']['set'](_0x2fb4a6,{'userId':_0xdc5348});}}}this['_startingRevisionId']=this['_revisionId'];const _0x2babfb=[...Array(this['_revisionId'])['keys']()]['slice'](0x1)['filter'](_0x29a713=>!this['_touched']['has'](_0x29a713));let _0x5e729c=0x0;const _0x4c63b6=new Map();for(const _0x128d63 in _0x43a425['diffData']){const _0x14b527=_0x43a425['diffData'][_0x128d63]['attachChange'],_0x43da8e=_0x1fffc6(_0x43a425['diffData'][_0x128d63]['attributesAfter'])||{},_0x4c53e8=_0x3f2b65['_makeModelFromViewString'](_0x43a425['diffData'][_0x128d63]['insertions']);_0x4c53e8['rootName']=_0x128d63,_0x4c53e8['_isAttached']=!_0x14b527||_0x14b527['isAttached'],_0x4c53e8['isAttached']=()=>_0x4c53e8['_isAttached'],this['_diffRoots']['set'](_0x128d63,_0x4c53e8),this['_diffRootsAttributes']['set'](_0x128d63,_0x43da8e);const _0x58a6fb=this['_makeIdsRoot'](_0x4c53e8,Number['NEGATIVE_INFINITY']);this['_idsRoots']['set'](_0x128d63,_0x58a6fb),_0x4c63b6['set'](_0x128d63,_0x4c53e8['isAttached']()?_0x43da8e:{});for(const [_0x42b159,_0x46287e]of _0x4c53e8['markers']){if(!_0x42b159['startsWith']('revision:'))continue;const _0x5e7aba=_0x42b159['split'](':')[0x2];for(const _0x2cbf0c of _0x46287e['getWalker']({'singleCharacters':!0x0})){const _0x9ebb64=this['_getVidAttributeName'](_0x2cbf0c),_0x1d3479=this['_revisionId']++,_0x1a8cf0='elementEnd'==_0x2cbf0c['type']?_0x2cbf0c['previousPosition']['path']['slice'](0x0,-0x1):_0x2cbf0c['previousPosition']['path'];_0x58a6fb['getNodeByPath'](_0x1a8cf0)['_setAttribute'](_0x9ebb64,_0x1d3479),this['_touched']['set'](_0x1d3479,{'userId':_0x5e7aba});}}for(const _0x5eb89d of this['editor']['model']['createRangeIn'](_0x4c53e8)['getWalker']({'singleCharacters':!0x0})){const _0x574ddd=this['_getVidAttributeName'](_0x5eb89d),_0x37b43e='elementEnd'==_0x5eb89d['type']?_0x5eb89d['previousPosition']['path']['slice'](0x0,-0x1):_0x5eb89d['previousPosition']['path'],_0x4f406c=_0x58a6fb['getNodeByPath'](_0x37b43e);_0x4f406c['getAttribute'](_0x574ddd)>0x0||_0x4f406c['_setAttribute'](_0x574ddd,_0x2babfb[_0x5e729c++]);}for(const [_0xc92031,_0x5058c3]of _0x4c53e8['markers'])_0xc92031['startsWith']('revision:')||this['_markers']['set'](_0xc92031,_0x5058c3);}const _0xc20d37=N('$graveyard');this['_baseRoots']['set']('$graveyard',_0xc20d37),this['_baseIdsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0xc20d37,0x1));const _0xfda269=N('$graveyard');this['_diffRoots']['set']('$graveyard',_0xfda269),this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0xfda269,0x1));const _0x5a26fd=Array['from'](this['_diffRoots'])['map'](([_0x1c1566,_0x1dac11])=>[_0x1c1566,x(_0x1dac11)]);this['_saveMetaData'](this['_lastTo'],_0x5a26fd,this['_markers'],_0x4c63b6);}['reInit'](){this['_reset'](),this['_lastFrom']=-0x1,this['_lastTo']=-0x1,this['_savedMetaData']['clear'](),this['init'](this['source']);}['_saveMetaData'](_0x5aa908,_0x24008b,_0x3cf310,_0x416a83){const _0x13947e=new Map(_0x24008b),_0x210761=new Map(_0x1fffc6(_0x416a83)),_0x5a5810=new Map();for(const [_0x5d0380,_0x58646d]of _0x3cf310)_0x5a5810['set'](_0x5d0380,{'start':_0x58646d['start']['clone'](),'end':_0x58646d['end']['clone'](),'rootName':_0x58646d['root']['rootName']});this['_savedMetaData']['set'](_0x5aa908,{'roots':_0x13947e,'markers':_0x5a5810,'rootsAttributes':_0x210761});}['_removeMetaData'](_0x59ff08){this['_savedMetaData']['delete'](_0x59ff08);}['_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'](_0x50bde6,_0x2ec1f8=null){let _0x3227b0=null;_0x50bde6['is']('documentFragment')||(_0x3227b0=new _0x37c7de(_0x50bde6['name'],{'vid_start':null===_0x2ec1f8?this['_revisionId']++:_0x2ec1f8++}));const _0x571858=[];for(const _0x40b071 of _0x50bde6['getChildren']())if(_0x40b071['is']('element')){_0x571858['push'](this['_makeIdsRoot'](_0x40b071,_0x2ec1f8));const _0x282887=_0x571858[_0x571858['length']-0x1];null!==_0x2ec1f8&&(_0x2ec1f8=_0x282887['is']('element','$text')?_0x282887['getAttribute']('vid')+0x1:_0x282887['getAttribute']('vid_end')+0x1);}else{for(let _0x564cac=0x0;_0x564cac<_0x40b071['offsetSize'];_0x564cac++)_0x571858['push'](new _0x37c7de('$text',{'vid':null===_0x2ec1f8?this['_revisionId']++:_0x2ec1f8++}));}if(_0x50bde6['is']('documentFragment')){const _0x5c3062=N(_0x50bde6['rootName']);return _0x5c3062['_insertChild'](0x0,_0x571858),_0x5c3062;}return _0x3227b0['_setAttribute']('vid_end',null===_0x2ec1f8?this['_revisionId']++:_0x2ec1f8++),_0x3227b0['_insertChild'](0x0,_0x571858),_0x3227b0;}['_calculateMetaData'](_0x256052,_0x1f0fba,_0x28b4f0){this['_reset']();const {roots:_0x51235c,markers:_0x19520f,rootsAttributes:_0x380ea5}=this['_savedMetaData']['get'](_0x256052);this['_baseRoots']=new Map(_0x51235c),this['_baseRootsAttributes']=new Map(_0x1fffc6(_0x380ea5));for(const [_0xcca2d0,_0x2b3d88]of this['_baseRoots'])if('$graveyard'!==_0xcca2d0&&(this['_diffRoots']['set'](_0xcca2d0,x(_0x2b3d88)),this['_diffRootsAttributes']=new Map(_0x1fffc6(_0x380ea5)),_0x28b4f0)){const _0x4aa7da=this['_revisionId'];this['_idsRoots']['set'](_0xcca2d0,this['_makeIdsRoot'](_0x2b3d88)),this['_baseIdsRoots']['set'](_0xcca2d0,this['_makeIdsRoot'](_0x2b3d88,_0x4aa7da));}this['_startingRevisionId']=this['_revisionId'],this['_diffRoots']['set']('$graveyard',x(this['_baseRoots']['get']('$graveyard'))),_0x28b4f0&&this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](this['_baseRoots']['get']('$graveyard')));for(const [_0x13377c,_0x963fc0]of _0x19520f){const _0x10d53c=this['_baseRoots']['get'](_0x963fc0['rootName']),_0x35e14e=this['_diffRoots']['get'](_0x963fc0['rootName']),_0x388f79=new _0x5cea6d(this['_fixPosition'](_0x963fc0['start'],_0x10d53c),this['_fixPosition'](_0x963fc0['end'],_0x10d53c)),_0x5176cb=this['_fixRange'](_0x388f79,_0x35e14e);_0x10d53c['markers']['set'](_0x13377c,_0x388f79),this['_markers']['set'](_0x13377c,_0x5176cb);}this['_applyOperations'](_0x256052,_0x1f0fba,_0x28b4f0);}['_applyOperations'](_0x16a521,_0x5b71b4,_0xbf050f){for(const _0x2559a6 of this['source']['getOperations'](_0x16a521,_0x5b71b4))this['_handleOperation'](_0x2559a6,_0xbf050f);for(const _0x4a7c70 of this['_diffRoots']['values']())_0x4a7c70['markers']['clear']();for(const [_0x5edbba,_0x2af985]of this['_markers']){this['_diffRoots']['get'](_0x2af985['root']['rootName'])['markers']['set'](_0x5edbba,_0x2af985['clone']());}const _0x5ffc0a=new Map(),_0x353d3a=new Map();for(const [_0x514ca3,_0x1e2b27]of this['_diffRoots'])_0x5ffc0a['set'](_0x514ca3,x(_0x1e2b27)),_0x353d3a['set'](_0x514ca3,this['_diffRootsAttributes']['get'](_0x514ca3));this['_saveMetaData'](_0x5b71b4,_0x5ffc0a,this['_markers'],_0x353d3a);}['_getPreviousFrom'](_0x2b3767){const _0x5831de=Array['from'](this['_savedMetaData']['keys']());_0x5831de['sort']((_0x347202,_0x4b1055)=>_0x347202-_0x4b1055),_0x5831de['reverse']();for(const _0x258164 of _0x5831de)if(_0x258164<_0x2b3767)return _0x258164;return Number['NEGATIVE_INFINITY'];}['_copyMarkers'](_0x206380,_0xfe970a){const _0x55931d=Array['from'](_0xfe970a['markers'])['map'](([_0x39eff2,_0x5c9acf])=>[_0x39eff2,this['_fixRange'](_0x5c9acf,_0x206380)]);_0x206380['markers']=new Map(_0x55931d);}['_transformMarkers'](_0x4084d1){for(const _0x307696 of this['_markers']['values']()){const _0x167f63=_0x307696['getTransformedByOperation'](_0x4084d1),_0x1c0dd3=_0x5cea6d['_createFromRanges'](_0x167f63);_0x307696['start']=_0x1c0dd3['start'],_0x307696['end']=_0x1c0dd3['end'];}}['_handleOperation'](_0x3c1a1a,_0x3cf9ac){if('addRoot'!=_0x3c1a1a['type']&&'detachRoot'!=_0x3c1a1a['type']){if('insert'==_0x3c1a1a['type']){const _0x2204de=_0x3c1a1a['position']['root']['rootName'];this['_diffRoots']['has'](_0x2204de)||(this['_diffRoots']['set'](_0x2204de,N(_0x2204de,!0x0)),this['_diffRootsAttributes']['set'](_0x2204de,{}),_0x3cf9ac&&this['_idsRoots']['set'](_0x2204de,N(_0x2204de,!0x0)));}else{if('addRootAttribute'==_0x3c1a1a['type']||'removeRootAttribute'==_0x3c1a1a['type']||'changeRootAttribute'==_0x3c1a1a['type'])return void this['_handleRootAttributeOperation'](_0x3c1a1a);'marker'==_0x3c1a1a['type']&&this['_handleMarkerOperation'](_0x3c1a1a);}if('marker'!==_0x3c1a1a['type']){const _0xfc279d=this['_cloneOperation'](_0x3c1a1a,this['_diffRoots']);_0xfc279d['_execute'](),this['_transformMarkers'](_0xfc279d);}if(_0x3cf9ac)switch(_0x3c1a1a['type']){case'insert':this['_handleInsertOperation'](_0x3c1a1a);break;case'move':case'remove':case'reinsert':this['_handleMoveOperation'](_0x3c1a1a);break;case'merge':this['_handleMergeOperation'](_0x3c1a1a);break;case'split':this['_handleSplitOperation'](_0x3c1a1a);}}else this['_handleRootOperation'](_0x3c1a1a,_0x3cf9ac);}['_cloneOperation'](_0x57473c,_0x2b100c){const _0x34c881=_0x57473c['clone']();return _0x34c881['_authorId']=_0x57473c['_authorId'],this['_fixOperation'](_0x34c881,_0x2b100c),_0x34c881;}['_getBaseVids'](_0x40a958){return _0x40a958['map'](_0x287e7d=>{const _0x3a01f1=this['_getVidAttributeName'](_0x287e7d);return Number(_0x287e7d['item']['getAttribute'](_0x3a01f1));});}['_generateTape'](_0x4cebce,_0x9ecf56){if(_0x4cebce['is']('element','$text'))_0x9ecf56['push']({'item':_0x4cebce,'type':'text'});else{_0x4cebce['is']('element')&&_0x9ecf56['push']({'item':_0x4cebce,'type':'elementStart'});for(const _0x5e522e of _0x4cebce['getChildren']())this['_generateTape'](_0x5e522e,_0x9ecf56);_0x4cebce['is']('element')&&_0x9ecf56['push']({'item':_0x4cebce,'type':'elementEnd'});}return _0x9ecf56;}['_getState'](){const _0x455bd2=new Map(this['_touched']),_0x389923=new Map(_0x455bd2),_0x9fac9d=new Map(),_0x2cf531={'insertions':{},'deletions':{}},_0x1f8ff7={'insertions':{},'deletions':{}},_0x9416de=new Map(),_0x4c7728=new Set([...this['_baseRoots']['keys'](),...this['_diffRoots']['keys']()]);_0x4c7728['delete']('$graveyard');for(const _0x2ad2cc of _0x4c7728){const _0x58e46b=this['_diffRoots']['get'](_0x2ad2cc)||N(_0x2ad2cc,!0x1),_0x46db96=this['_baseRoots']['get'](_0x2ad2cc)||N(_0x2ad2cc,!0x1);_0x58e46b['isAttached']()||_0x46db96['isAttached']()?(_0x2cf531['insertions'][_0x2ad2cc]=x(_0x58e46b),_0x2cf531['deletions'][_0x2ad2cc]=x(_0x46db96),this['_copyMarkers'](_0x2cf531['deletions'][_0x2ad2cc],_0x46db96),this['_copyMarkers'](_0x2cf531['insertions'][_0x2ad2cc],_0x58e46b),_0x1f8ff7['insertions'][_0x2ad2cc]=this['_generateTape'](this['_idsRoots']['get'](_0x2ad2cc),[]),_0x1f8ff7['deletions'][_0x2ad2cc]=this['_generateTape'](this['_baseIdsRoots']['get'](_0x2ad2cc)||N(_0x2ad2cc,!0x1),[])):_0x4c7728['delete'](_0x2ad2cc);}for(const _0x50d1ec of _0x4c7728){const _0x3f97d2=_0x1f8ff7['insertions'][_0x50d1ec];for(const _0x2fdf77 of _0x3f97d2){const _0x596a23=this['_getVidAttributeName'](_0x2fdf77),_0x398749=_0x2fdf77['item']['getAttribute'](_0x596a23);_0x389923['delete'](_0x398749),_0x398749>=this['_startingRevisionId']&&_0x9fac9d['set'](_0x398749,_0x455bd2['get'](_0x398749));}}for(const _0x3e0932 of _0x4c7728){const _0x253988=_0x1f8ff7['insertions'][_0x3e0932],_0x4a5080=this['_getBaseVids'](_0x1f8ff7['deletions'][_0x3e0932]);let _0x3e416e=0x0;for(const _0x300716 of _0x253988){const _0x4a563a=this['_getVidAttributeName'](_0x300716),_0xac3871=_0x300716['item']['getAttribute'](_0x4a563a);if(!_0x9fac9d['has'](_0xac3871)&&!_0x9416de['has'](_0xac3871)){if(_0x389923['has'](_0xac3871))_0x3e416e++;else{if(_0xac3871!=_0x4a5080[_0x3e416e]){const _0x48adda=_0x455bd2['get'](_0xac3871)||_0x455bd2['get'](_0x4a5080[_0x3e416e]);for(;_0xac3871!=_0x4a5080[_0x3e416e];)_0x389923['has'](_0x4a5080[_0x3e416e])||(_0x9416de['set'](_0x4a5080[_0x3e416e],_0x48adda),_0x455bd2['set'](_0x4a5080[_0x3e416e],_0x48adda)),_0x3e416e++;}_0x3e416e++;}}}}for(const _0x27b8fd of _0x4c7728){const _0x436667=_0x1f8ff7['insertions'][_0x27b8fd];for(const _0x565d8e of _0x436667){const _0x28aafb=this['_getVidAttributeName'](_0x565d8e),_0x171556=_0x565d8e['item']['getAttribute'](_0x28aafb);if(_0x9416de['has'](_0x171556)){const _0x455e0c=_0x9416de['get'](_0x171556);_0x389923['has'](_0x171556)||_0x389923['set'](_0x171556,{..._0x455e0c}),_0x9fac9d['set'](_0x171556,{..._0x455e0c});}}}for(const _0x50634a of _0x389923['keys']())_0x50634a>=this['_startingRevisionId']&&_0x389923['delete'](_0x50634a);const _0x42f60c=new Map();for(const _0x5ad31b of _0x4c7728){let _0x46a75f=_0x1f8ff7['insertions'][_0x5ad31b];for(const _0x5534d5 of _0x46a75f)if(_0x5534d5['item']['is']('element','tableCell')){const _0x3031=this['_getVidAttributeName'](_0x5534d5),_0x25fa8f=_0x5534d5['item']['getAttribute'](_0x3031);if(_0x9fac9d['has'](_0x25fa8f)){const _0x60ff0e=_0x5534d5['item']['parent']['parent']['getAttribute']('vid_start'),_0x1839ea=_0x42f60c['get'](_0x60ff0e)||new Set();_0x1839ea['add'](_0x9fac9d['get'](_0x25fa8f)['userId']),_0x42f60c['set'](_0x60ff0e,_0x1839ea);}}_0x46a75f=_0x1f8ff7['deletions'][_0x5ad31b];for(const _0x467903 of _0x46a75f)if(_0x467903['item']['is']('element','tableCell')){const _0x362547=this['_getVidAttributeName'](_0x467903),_0x385122=_0x467903['item']['getAttribute'](_0x362547);if(_0x389923['has'](_0x385122)){const _0x27ea5e=_0x467903['item']['parent']['parent']['getAttribute']('vid_start'),_0x4c231d=_0x42f60c['get'](_0x27ea5e)||new Set();_0x4c231d['add'](_0x389923['get'](_0x385122)['userId']),_0x42f60c['set'](_0x27ea5e,_0x4c231d);}}for(const _0x20d6ce of _0x42f60c['keys']())(_0x9fac9d['has'](_0x20d6ce)||_0x389923['has'](_0x20d6ce))&&_0x42f60c['delete'](_0x20d6ce);}for(const _0x339351 of _0x4c7728){const _0x45fc33=_0x1f8ff7['insertions'][_0x339351];let _0x7fff9d=null,_0x15c0d4=null;for(const _0x346dfc of _0x45fc33){const _0x591419=this['_getVidAttributeName'](_0x346dfc),_0x1f15c6=_0x346dfc['item']['getAttribute'](_0x591419),_0x4f774a=_0x42f60c['get'](_0x1f15c6);_0x4f774a&&'elementStart'==_0x346dfc['type']&&(_0x7fff9d=Array['from'](_0x4f774a)[0x0],_0x15c0d4=_0x346dfc['item']['getAttribute']('vid_end')),_0x7fff9d&&(_0x389923['set'](_0x1f15c6,{'userId':_0x7fff9d}),_0x9fac9d['set'](_0x1f15c6,{'userId':_0x7fff9d})),_0x1f15c6==_0x15c0d4&&(_0x7fff9d=null,_0x15c0d4=null);}}const _0x4556bb={},_0x59f9f0=new Set();for(const _0x54b016 of _0x4c7728){const _0x4e0780=_0x2cf531['deletions'][_0x54b016],_0x134d13=_0x2cf531['insertions'][_0x54b016];for(const {userId:_0x5f2f64}of this['_touchedMarkers']['values']())null!==_0x5f2f64&&_0x59f9f0['add'](_0x5f2f64);for(const {userId:_0x472b8b}of this['_touchedRoots']['values']())null!==_0x472b8b&&_0x59f9f0['add'](_0x472b8b);this['_markChanges'](_0x134d13,_0x1f8ff7['insertions'][_0x54b016],_0x9fac9d,'insertion',_0x59f9f0),this['_markChanges'](_0x4e0780,_0x1f8ff7['deletions'][_0x54b016],_0x389923,'deletion',_0x59f9f0),_0x4556bb[_0x54b016]={'insertions':this['_prepareViewToSave'](_0x134d13),'deletions':this['_prepareViewToSave'](_0x4e0780),'attachChange':this['_touchedRoots']['get'](_0x54b016)||null,'attributesBefore':_0x1fffc6(this['_baseRootsAttributes']['get'](_0x54b016))||{},'attributesAfter':_0x1fffc6(this['_diffRootsAttributes']['get'](_0x54b016))};}return{'diffData':_0x4556bb,'authorsIds':Array['from'](_0x59f9f0)};}['_processRootBeforeSave'](_0x1a70f8){for(const [,_0x3ce7ed]of _0x1a70f8['markers']){const _0x3164df=_0x3ce7ed['start']['getAncestors']()['filter'](_0x225ed6=>'tableCell'==_0x225ed6['name']);for(const _0x4f5d46 of _0x3164df)0x1==_0x4f5d46['childCount']&&_0x4f5d46['getChild'](0x0)['is']('element','paragraph')&&_0x4f5d46['getChild'](0x0)['_setAttribute']('keepParagraph',!0x0);}}['_prepareViewToSave'](_0x77692b){this['_processRootBeforeSave'](_0x77692b);const _0xd75785=this['editor']['data']['toView'](_0x77692b,{}),_0x5e4ca9=Array['from'](_0xd75785['getChildren']())['map'](_0x19376b=>this['_getViewJson'](_0x19376b));return JSON['stringify'](_0x5e4ca9);}['_getViewJson'](_0x440206){if(_0x440206['is']('$text'))return _0x440206['data'];{const _0x35ff96=this['editor']['plugins']['get']('RevisionHistoryUtils'),_0x2d7666=_0x440206,_0x3abdb0=this['editor']['data']['htmlProcessor']['domConverter'],_0x499f36={'type':_0x35ff96['_getTypeCharForViewElement'](_0x2d7666),'name':_0x2d7666['name'],'attributes':Array['from'](_0x2d7666['getAttributes']()),'children':Array['from'](_0x2d7666['getChildren']())['map'](_0x1c6f78=>this['_getViewJson'](_0x1c6f78))};if(_0x440206['is']('uiElement')&&'$comment'!=_0x440206['name']){const _0x121717=_0x440206['render'](_0x3abdb0['domDocument'],_0x3abdb0);_0x499f36['children']['push'](_0x121717['outerHTML']);}else{if(_0x440206['is']('rawElement')){const _0xa62fe0=_0x3abdb0['domDocument']['createElement'](_0x2d7666['name']);_0x440206['render'](_0xa62fe0,_0x3abdb0),_0x499f36['children']['push'](_0xa62fe0['innerHTML']);}}const _0x4de9f5=Array['from'](_0x2d7666['getCustomProperties']());_0x4de9f5['length']>0x0&&(_0x499f36['customProperties']=_0x4de9f5);const _0x28381a=_0x2d7666['getFillerOffset']();return null!==_0x28381a&&(_0x499f36['fillerOffset']=_0x28381a),_0x499f36;}}['_markChanges'](_0x48868c,_0x224c6f,_0x2c3f15,_0x2d8912,_0x264930){let _0x294dde=null,_0x49c480=null,_0x4cc06e=0x0;const _0x48428c=this['editor']['model'];for(let _0x231a2a=0x0;_0x231a2a<_0x224c6f['length'];_0x231a2a++){const _0x3e1358=this['_getVidAttributeName'](_0x224c6f[_0x231a2a]),_0x1c6b85=_0x224c6f[_0x231a2a]['item']['getAttribute'](_0x3e1358),_0x24c117=_0x2c3f15['get'](_0x1c6b85),_0x2b0912=_0x231a2a==_0x224c6f['length']-0x1;(!_0x294dde&&_0x24c117&&(_0x294dde=_0x24c117,_0x49c480=_0x224c6f[_0x231a2a]),_0x294dde&&(!_0x24c117||_0x24c117['userId']!=_0x294dde['userId']))&&(_0x40e104(_0x24c117,P(_0x49c480,_0x48868c,_0x48428c),P(_0x224c6f[_0x231a2a],_0x48868c,_0x48428c)),_0x294dde=_0x24c117||null,_0x49c480=_0x24c117?_0x224c6f[_0x231a2a]:null),_0x294dde&&_0x2b0912&&_0x40e104(_0x24c117,P(_0x49c480,_0x48868c,_0x48428c),V(_0x224c6f[_0x231a2a],_0x48868c,_0x48428c));}function _0x40e104(_0x48bb01,_0x4505ca,_0x53014b){const _0xe535c=_0x294dde['userId'],_0x10b0ba='revision:'+_0x2d8912+':'+_0xe535c+':'+_0x4cc06e++,_0x4f071b=_0x48428c['createRange'](_0x4505ca,_0x53014b);_0x48868c['markers']['set'](_0x10b0ba,_0x4f071b),null!==_0xe535c&&_0x264930['add'](_0xe535c);}}['_getVidAttributeName'](_0x55ff1f){switch(_0x55ff1f['type']){case'elementStart':return'vid_start';case'elementEnd':return'vid_end';default:return'vid';}}['_fixOperation'](_0x337e29,_0x3c2ff1){_0x337e29['baseVersion']=null;for(const _0x19a27a in _0x337e29){const _0xa67920=_0x337e29[_0x19a27a];if(_0xa67920 instanceof _0x37d3ad){const _0x45c260=_0x3c2ff1['get'](_0xa67920['root']['rootName']);_0x337e29[_0x19a27a]=this['_fixPosition'](_0xa67920,_0x45c260);}if(_0xa67920 instanceof _0x5cea6d){const _0x44d61b=_0x3c2ff1['get'](_0xa67920['root']['rootName']);_0x337e29[_0x19a27a]=this['_fixRange'](_0xa67920,_0x44d61b);}'root'===_0x19a27a&&(_0x337e29['root']=_0x3c2ff1['get'](_0x337e29['root']['rootName']));}}['_fixRange'](_0x13cdf1,_0x487e80){return this['editor']['model']['createRange'](this['_fixPosition'](_0x13cdf1['start'],_0x487e80),this['_fixPosition'](_0x13cdf1['end'],_0x487e80));}['_fixPosition'](_0x4d810a,_0x4ef0fc){return this['editor']['model']['createPositionFromPath'](_0x4ef0fc,_0x4d810a['path'],_0x4d810a['stickiness']);}['_handleInsertOperation'](_0x2b17ba){const _0xf5cd8e=this['_idsRoots']['get'](_0x2b17ba['position']['root']['rootName']),_0x205830=this['_fixPosition'](_0x2b17ba['position'],_0xf5cd8e),_0xbd363e=null===_0x2b17ba['_authorId']?null:_0x2b17ba['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x280c1b=_0x205830['parent'],_0x3b5de9=this['_revisionId'],_0x48eaca=[];for(const _0x51c053 of _0x2b17ba['nodes'])if(_0x51c053['is']('element'))_0x48eaca['push'](this['_makeIdsRoot'](_0x51c053));else{for(let _0x583785=0x0;_0x583785<_0x51c053['offsetSize'];_0x583785++)_0x48eaca['push'](new _0x37c7de('$text',{'vid':this['_revisionId']++}));}const _0x46cfdd=this['_revisionId'];for(let _0x1d1b08=_0x3b5de9;_0x1d1b08<_0x46cfdd;_0x1d1b08++)this['_touched']['set'](_0x1d1b08,{'userId':_0xbd363e});_0x280c1b['_insertChild'](_0x205830['offset'],_0x48eaca);}['_handleMoveOperation'](_0x41fb56){(_0x41fb56=this['_cloneOperation'](_0x41fb56,this['_idsRoots']))['_execute']();const _0x6873d6=null===_0x41fb56['_authorId']?null:_0x41fb56['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x24207a=_0x41fb56['getMovedRangeStart'](),_0x5d8cc9=_0x24207a['parent'],_0x36ec56=_0x24207a['offset'];!function _0x1e2333(_0x5566fd,_0x4c6f2b,_0x55e8d,_0x1af182){for(let _0x1ac814=_0x55e8d;_0x1ac814<_0x1af182;_0x1ac814++){const _0x43632e=_0x4c6f2b['getChild'](_0x1ac814);_0x43632e['is']('element','$text')?_0x5566fd['set'](_0x43632e['getAttribute']('vid'),{'userId':_0x6873d6}):(_0x5566fd['set'](_0x43632e['getAttribute']('vid_start'),{'userId':_0x6873d6}),_0x1e2333(_0x5566fd,_0x43632e,0x0,_0x43632e['childCount']),_0x5566fd['set'](_0x43632e['getAttribute']('vid_end'),{'userId':_0x6873d6}));}}(this['_touched'],_0x5d8cc9,_0x36ec56,_0x36ec56+_0x41fb56['howMany']);}['_handleMergeOperation'](_0x39d80b){const _0x205980=null===(_0x39d80b=this['_cloneOperation'](_0x39d80b,this['_idsRoots']))['_authorId']?null:_0x39d80b['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0xc5cbeb=_0x39d80b['targetPosition']['parent'],_0x5e82e5=_0x39d80b['sourcePosition']['parent'],_0x4ffb28=_0xc5cbeb['getAttribute']('vid_end'),_0xaea803=_0x5e82e5['getAttribute']('vid_start');_0xc5cbeb['_setAttribute']('vid_end',_0x5e82e5['getAttribute']('vid_end')),_0x5e82e5['_setAttribute']('vid_end',_0x4ffb28),this['_touched']['set'](_0xaea803,{'userId':_0x205980}),this['_touched']['set'](_0x4ffb28,{'userId':_0x205980}),_0x39d80b['_execute']();}['_handleSplitOperation'](_0x357a0d){const _0x565f85=null===(_0x357a0d=this['_cloneOperation'](_0x357a0d,this['_idsRoots']))['_authorId']?null:_0x357a0d['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x2af3c8=_0x357a0d['graveyardPosition'],_0x30b3c3=_0x357a0d['splitPosition']['parent'];_0x357a0d['_execute']();const _0x553e00=_0x30b3c3['getAttribute']('vid_end'),_0x3e5e73=_0x357a0d['insertionPosition']['nodeAfter'];if(_0x2af3c8){const _0x38501e=_0x3e5e73['getAttribute']('vid_end'),_0x2ca26d=_0x30b3c3['getAttribute']('vid_end');_0x30b3c3['_setAttribute']('vid_end',_0x38501e),_0x3e5e73['_setAttribute']('vid_end',_0x2ca26d),this['_touched']['set'](_0x30b3c3['getAttribute']('vid_end'),{'userId':_0x565f85}),this['_touched']['set'](_0x3e5e73['getAttribute']('vid_start'),{'userId':_0x565f85});}else{const _0x55ea1e=this['_revisionId']++,_0x2529d5=this['_revisionId']++;_0x30b3c3['_setAttribute']('vid_end',_0x55ea1e),_0x3e5e73['_setAttribute']('vid_start',_0x2529d5),_0x3e5e73['_setAttribute']('vid_end',_0x553e00),this['_touched']['set'](_0x55ea1e,{'userId':_0x565f85}),this['_touched']['set'](_0x2529d5,{'userId':_0x565f85});}}['_handleMarkerOperation'](_0x1292e9){if(!_0x1292e9['affectsData'])return;const _0x34b19c=(_0x1292e9=this['_cloneOperation'](_0x1292e9,this['_diffRoots']))['oldRange']?_0x1292e9['oldRange']['root']:null,_0x1996fd=_0x1292e9['newRange']?_0x1292e9['newRange']['root']:null;_0x34b19c&&this['_markers']['delete'](_0x1292e9['name']),_0x1996fd&&this['_markers']['set'](_0x1292e9['name'],_0x1292e9['newRange']['clone']());const _0x414b59=null===_0x1292e9['_authorId']?null:_0x1292e9['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x7b030e=_0x1292e9['name'];if(!this['_touchedMarkers']['has'](_0x7b030e))return void this['_touchedMarkers']['set'](_0x7b030e,{'range':_0x1292e9['oldRange'],'userId':_0x414b59});const _0x1d1a98=this['_touchedMarkers']['get'](_0x7b030e),_0x44eaed=_0x1d1a98['range'],_0xdc621c=_0x1292e9['newRange'];null==_0x44eaed&&null==_0xdc621c||_0x44eaed&&_0xdc621c&&_0x44eaed['isEqual'](_0xdc621c)?this['_touchedMarkers']['delete'](_0x1292e9['name']):_0x1d1a98['userId']=_0x414b59;}['_handleRootOperation'](_0x6359e0,_0x15d738){this['_diffRoots']['has'](_0x6359e0['rootName'])?this['_diffRoots']['get'](_0x6359e0['rootName'])['_isAttached']=_0x6359e0['isAdd']:(this['_diffRoots']['set'](_0x6359e0['rootName'],N(_0x6359e0['rootName'],!0x0)),this['_diffRootsAttributes']['set'](_0x6359e0['rootName'],{}),_0x15d738&&this['_idsRoots']['set'](_0x6359e0['rootName'],N(_0x6359e0['rootName'],!0x0)));const _0x396896=null===_0x6359e0['_authorId']?null:_0x6359e0['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x512023=this['_touchedRoots']['get'](_0x6359e0['rootName']);_0x512023&&_0x512023['userId']===_0x396896?this['_touchedRoots']['delete'](_0x6359e0['rootName']):this['_touchedRoots']['set'](_0x6359e0['rootName'],{'userId':_0x396896,'isAttached':_0x6359e0['isAdd']});}['_handleRootAttributeOperation'](_0x15416f){const _0x441cf4=this['_diffRootsAttributes']['get'](_0x15416f['root']['rootName']);null===_0x15416f['newValue']?delete _0x441cf4[_0x15416f['key']]:_0x441cf4[_0x15416f['key']]=_0x15416f['newValue'];}}function x(_0xac79df){const _0x2de2bc=N(_0xac79df['rootName'],_0xac79df['isAttached']());for(const _0x519431 of _0xac79df['getChildren']()){const _0xe46e97=_0x519431['_clone'](!0x0);_0x2de2bc['_appendChild'](_0xe46e97);}return _0x2de2bc;}function N(_0x1b74ed,_0x4f74b4=!0x0){const _0x2d89cf=new _0x72fa5();return _0x2d89cf['rootName']=_0x1b74ed,_0x2d89cf['_isAttached']=_0x4f74b4,_0x2d89cf['isAttached']=()=>_0x2d89cf['_isAttached'],_0x2d89cf;}function P(_0x44432f,_0x4a4bc0,_0x18fb89){const _0xd3e5a4='elementEnd'==_0x44432f['type']?_0x18fb89['createPositionAt'](_0x44432f['item'],'end'):_0x18fb89['createPositionBefore'](_0x44432f['item']);return _0x18fb89['createPositionFromPath'](_0x4a4bc0,_0xd3e5a4['path'],_0xd3e5a4['stickiness']);}function V(_0x207040,_0x3b922f,_0x41afee){const _0x51097a='elementStart'==_0x207040['type']?_0x41afee['createPositionAt'](_0x207040['item'],0x0):_0x41afee['createPositionAfter'](_0x207040['item']);return _0x41afee['createPositionFromPath'](_0x3b922f,_0x51097a['path'],_0x51097a['stickiness']);}class he extends/* #__PURE__ -- @preserve */
|
|
25
|
-
|
|
26
|
-
_0x3e54cf(){['id'];['author'];['type'];['data'];['rootName'];constructor(_0x174605){super(),this['id']=_0x174605['id']||_0x515d40(),this['author']=_0x174605['author'],this['type']=_0x174605['type'],this['data']=_0x174605['data']||{},this['rootName']=_0x174605['rootName'],this['set']('createdAt',_0x174605['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(_0x4d10f1,_0x124d5f){this['newRevisionId']=_0x4d10f1,this['oldRevisionId']=_0x124d5f,this['changes']=new _0x42f581();}['_setChanges'](_0xd2408b){for(const _0x3f5093 of _0xd2408b)this['changes']['add'](_0x3f5093);}}class l extends _0x278e34{['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[_0x3fef6b,_0x2d19fd,S,$];}constructor(_0x276a2f){super(_0x276a2f),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',(_0x4d5d43,_0x2dfa03,_0x29a674)=>{this['activeChange']=null,this['activeView']=null,this['editor']['editing']['view']['change'](_0x3fd11b=>{for(const _0x2d7f5c of this['editor']['editing']['view']['document']['roots'])_0x29a674?_0x3fd11b['removeClass']('ck-editor__editable__overlay',_0x2d7f5c):_0x3fd11b['addClass']('ck-editor__editable__overlay',_0x2d7f5c);});}),this['bind']('isNavigationMode')['to'](this,'activeChange',_0x2f3b1c=>null!==_0x2f3b1c),this['bind']('currentChangeNumber')['to'](this,'isReady',this,'diff',this,'activeChange',(_0x37406d,_0x1e4862,_0x221a35)=>_0x37406d&&_0x221a35?_0x1e4862['changes']['getIndex'](_0x221a35):0x0),this['bind']('numberOfChanges')['to'](this,'isReady',this,'diff',(_0x47edb5,_0x11187f)=>_0x47edb5?_0x11187f['changes']['length']:0x0),this['_changeView']=null,this['_changeIdToChange']=new Map(),this['_balloon']=this['editor']['plugins']['get'](_0x2d19fd);}['init'](){const _0x18080f=this['editor'],_0x560548=new ot(_0x18080f,{'direction':'backward'}),_0x1864b0=new ot(_0x18080f,{'direction':'forward'});(_0x18080f['commands']['add']('showPreviousChange',_0x560548),_0x18080f['commands']['add']('showNextChange',_0x1864b0),_0x18080f['commands']['add']('restoreRevision',new nt(_0x18080f)),this['on']('change:numberOfChanges',()=>{_0x560548['refresh'](),_0x1864b0['refresh']();}),this['_setConversion'](),this['_initInteractions'](),_0x18080f['enableReadOnlyMode']('revision-viewer'),_0x18080f['plugins']['has']('WidgetToolbarRepository'))&&_0x18080f['plugins']['get']('WidgetToolbarRepository')['forceDisabled']('revision-viewer');}async['getRevisionDocumentData'](_0xbc34ac){return await this['_utils']['loadRevisionData'](_0xbc34ac,this['adapter']),this['_utils']['getRevisionDocumentData'](_0xbc34ac);}async['getRevisionRootsAttributes'](_0x3fccf9){return await this['_utils']['loadRevisionData'](_0x3fccf9,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x3fccf9);}async['compare'](_0x13f96a,_0x2dd7af,_0x347d43=!0x1){if(!this['isEnabled'])return;const _0x1e6ead=this['diff'],_0x151bbe=this['repository'],_0x5cf251='string'==typeof _0x13f96a?_0x151bbe['getRevision'](_0x13f96a):_0x13f96a,_0x3f6963='string'==typeof _0x2dd7af?_0x151bbe['getRevision'](_0x2dd7af):_0x2dd7af,_0xac9b6f=_0x5cf251['id'],_0x13f5a9=_0x3f6963?_0x3f6963['id']:null;if(!_0x347d43&&this['diff']&&this['diff']['newRevisionId']===_0xac9b6f&&this['diff']['oldRevisionId']===_0x13f5a9)return Promise['resolve']();this['isReady']=!0x1,this['activeView']=null,this['activeChange']=null,this['diff']=new J(_0xac9b6f,_0x13f5a9);const _0x4256a4=this['_getRevisionsRange'](_0x5cf251,_0x3f6963,!0x0)['map'](_0x8fbf73=>this['_utils']['loadRevisionData'](_0x8fbf73,this['adapter']));return _0x4256a4['push'](new Promise(_0xeeae85=>{setTimeout(_0xeeae85,0x14);})),Promise['all'](_0x4256a4)['then'](()=>{if(!this['isEnabled'])return;this['_cleanUp']();const _0x1ac953=this['_getDiff'](_0xac9b6f,_0x13f5a9);for(const _0x4db76b of _0x1ac953['changes'])this['_changeIdToChange']['set'](_0x4db76b['id'],_0x4db76b);this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x369936=>{for(const _0x2990f5 of this['editor']['model']['document']['getRootNames']())_0x369936['detachRoot'](_0x2990f5);for(const _0x1cdb1c of Object['keys'](_0x1ac953['model'])){const _0x2c3cfd=_0x369936['addRoot'](_0x1cdb1c);for(const _0x1b8513 of Object['keys'](_0x1ac953['attributes'][_0x1cdb1c]))_0x369936['setAttribute'](_0x1b8513,_0x1ac953['attributes'][_0x1cdb1c][_0x1b8513],_0x2c3cfd);_0x369936['insert'](_0x1ac953['model'][_0x1cdb1c],_0x2c3cfd,0x0);}}),this['diff']['_setChanges'](this['_sortAndFilterDiffChanges'](_0x1ac953['changes'])),this['isReady']=!0x0;})['catch'](_0x438c70=>{console['error'](_0x438c70),this['_cleanUp'](),_0x1e6ead&&(this['diff']=_0x1e6ead),this['isReady']=!0x0;});}['addRevisionData'](_0x404c8f,_0xfa257d){const _0x571cf2=this['repository']['createRevision'](_0x404c8f);return _0x571cf2['on']('_update',(_0x32b2d4,_0x3be4d1,_0xf0f062)=>_0xfa257d(_0x3be4d1,_0xf0f062,_0x571cf2)),this['repository']['addRevision'](_0x571cf2),_0x571cf2;}['_cleanUp'](){this['activeChange']=null,this['_cleanMarkers'](),this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=null,this['_changeIdToChange']['clear'](),this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x526dff=>{for(const _0x376661 of this['editor']['model']['document']['getRootNames']())_0x526dff['detachRoot'](_0x376661);});}['_sortAndFilterDiffChanges'](_0x49c7bb){const _0x269064=[],_0x363969=new Map();for(const _0x4fc5cd of this['editor']['model']['document']['getRootNames']()){const _0x1c7f18=this['editor']['editing']['view']['getDomRoot'](_0x4fc5cd);if(!_0x1c7f18)continue;const _0x3f6bae=_0x1c7f18['getClientRects']()['item'](0x0);_0x3f6bae&&(_0x269064['push'](_0x4fc5cd),_0x363969['set'](_0x4fc5cd,_0x3f6bae));}return _0x269064['sort']((_0x522148,_0x153546)=>{const _0x520cba=_0x363969['get'](_0x522148),_0x564619=_0x363969['get'](_0x153546);return _0x520cba['y']-_0x564619['y']||_0x520cba['x']-_0x564619['x'];}),(_0x49c7bb=_0x49c7bb['filter'](_0x50402c=>_0x269064['includes'](_0x50402c['rootName'])))['sort']((_0x1ced80,_0x3d940a)=>_0x269064['indexOf'](_0x1ced80['rootName'])-_0x269064['indexOf'](_0x3d940a['rootName'])),_0x49c7bb;}['_makeTape'](_0x4d7d0f){const _0x9cf590=Array['from'](_0x4d7d0f['markers'])['filter'](([_0x3ec2c9,_0x296fac])=>_0x3ec2c9['startsWith']('revision:')&&!_0x296fac['isCollapsed']),_0x16a0ed=Array['from'](this['editor']['model']['createRangeIn'](_0x4d7d0f)['getWalker']({'singleCharacters':!0x0}));if(0x0!=_0x9cf590['length'])for(const _0x6a2c27 of _0x16a0ed){const [_0x5aad2a,_0x1c2443]=_0x9cf590[0x0],[,_0x16fe23,_0x5d0eee]=_0x5aad2a['split'](':');if(_0x1c2443['end']['isEqual'](_0x6a2c27['nextPosition'])&&_0x9cf590['shift'](),(_0x6a2c27['previousPosition']['isEqual'](_0x1c2443['start'])||_0x6a2c27['previousPosition']['isAfter'](_0x1c2443['start']))&&('insertion'==_0x16fe23?_0x6a2c27['isAdded']={'userId':_0x5d0eee}:'deletion'==_0x16fe23&&(_0x6a2c27['isRemoved']={'userId':_0x5d0eee})),0x0==_0x9cf590['length'])break;}return _0x16a0ed;}['_refreshStartEndIndex'](_0x473931){const _0xf147b9=new Map();for(let _0x49c1cf=0x0;_0x49c1cf<_0x473931['length'];_0x49c1cf++)'text'===_0x473931[_0x49c1cf]['type']?(_0x473931[_0x49c1cf]['item']['startIndex']=_0x49c1cf,_0x473931[_0x49c1cf]['item']['endIndex']=_0x49c1cf):('elementStart'===_0x473931[_0x49c1cf]['type']?_0x473931[_0x49c1cf]['item']['startIndex']=_0x49c1cf:'elementEnd'===_0x473931[_0x49c1cf]['type']&&(_0x473931[_0x49c1cf]['item']['endIndex']=_0x49c1cf),_0xf147b9['set'](_0x473931[_0x49c1cf]['id'],_0x49c1cf));for(const _0x4c0aac of _0xf147b9['values']())'elementStart'===_0x473931[_0x4c0aac]['type']?_0x473931[_0x4c0aac]['item']['endIndex']=_0xf147b9['get'](_0x473931[_0x4c0aac]['pairId']):'elementEnd'===_0x473931[_0x4c0aac]['type']&&(_0x473931[_0x4c0aac]['item']['startIndex']=_0xf147b9['get'](_0x473931[_0x4c0aac]['pairId']));}['_processTape'](_0x55c887){for(let _0x359498=0x0;_0x359498<_0x55c887['length'];_0x359498++){if('elementStart'===_0x55c887[_0x359498]['type'])_0x55c887[_0x359498]['item']['startIndex']=_0x359498;else{if('elementEnd'===_0x55c887[_0x359498]['type']){_0x55c887[_0x359498]['item']['endIndex']=_0x359498;const _0x358577=_0x55c887[_0x359498]['item']['startIndex'];_0x55c887[_0x358577]['pairId']=_0x55c887[_0x359498]['id'],_0x55c887[_0x359498]['pairId']=_0x55c887[_0x358577]['id'];}else _0x55c887[_0x359498]['item']['startIndex']=_0x359498,_0x55c887[_0x359498]['item']['endIndex']=_0x359498,_0x55c887[_0x359498]['pairId']=null;}_0x55c887[_0x359498]['markersStart']||(_0x55c887[_0x359498]['markersStart']=[],_0x55c887[_0x359498]['markersEnd']=[]);}}['_markInsertions'](_0x4a2fd6,_0x24a44b){const _0x13b890=_0x4a2fd6['filter'](_0x5b6e54=>!_0x5b6e54['isAdded']);for(let _0x3f4bc2=0x0;_0x3f4bc2<_0x24a44b['length'];_0x3f4bc2++)_0x24a44b[_0x3f4bc2]['isAdded']&&(_0x13b890[_0x3f4bc2]['isAdded']=_0x24a44b[_0x3f4bc2]['isAdded']);}['_getDiff'](_0x3c8e05,_0x30c8da=null){const _0x1b4b31=this['repository']['getRevision'](_0x3c8e05),_0x2fa91e=_0x30c8da?this['repository']['getRevision'](_0x30c8da):null,_0x7a9d6f=this['_getRevisionsRange'](_0x1b4b31,_0x2fa91e),_0x1816a5=_0x7a9d6f[_0x7a9d6f['length']-0x1],_0x45e9a4=new Map(),_0x3d9356={'model':{},'attributes':{},'changes':[]},_0x1a96cc=new Set(),_0x379700=new Map();for(let _0x1c83bc=_0x7a9d6f['length']-0x1;_0x1c83bc>=0x0;_0x1c83bc--){const _0x52461a=_0x7a9d6f[_0x1c83bc];for(const _0x587d12 of Object['keys'](_0x52461a['diffData']))if(_0x52461a['diffData'][_0x587d12]['attachChange']){const _0x4b50bc=_0x52461a['diffData'][_0x587d12]['attachChange'];_0x4b50bc['isAttached']?(_0x1a96cc['add'](_0x587d12),_0x379700['has'](_0x587d12)&&_0x379700['get'](_0x587d12)['userId']==_0x4b50bc['userId']?_0x379700['delete'](_0x587d12):_0x379700['set'](_0x587d12,_0x4b50bc)):_0x379700['has'](_0x587d12)?(_0x1a96cc['delete'](_0x587d12),_0x379700['delete'](_0x587d12)):(_0x1a96cc['add'](_0x587d12),_0x379700['set'](_0x587d12,_0x4b50bc));}else _0x1a96cc['add'](_0x587d12);}for(const _0x4a19b3 of _0x1a96cc){const _0x18bcbd=_0x379700['has'](_0x4a19b3)&&!_0x379700['get'](_0x4a19b3)['isAttached'];let _0x3c8c42=_0x18bcbd?_0x7a9d6f['length']-0x1:0x0;const _0x513437=_0x18bcbd?-0x1:0x1;for(;_0x7a9d6f[_0x3c8c42];){const _0x19e7ce=_0x7a9d6f[_0x3c8c42];if(_0x19e7ce['diffData'][_0x4a19b3]){const _0x95c9c5=_0x18bcbd?_0x19e7ce['diffData'][_0x4a19b3]['attributesBefore']:_0x19e7ce['diffData'][_0x4a19b3]['attributesAfter'];_0x3d9356['attributes'][_0x4a19b3]=_0x95c9c5?_0x1fffc6(_0x95c9c5):{};break;}_0x3c8c42+=_0x513437;}}for(const _0x271c0b of _0x7a9d6f){_0x271c0b['model']={};for(const _0x14d7fa of _0x271c0b['authors'])_0x45e9a4['set'](_0x14d7fa['id'],_0x14d7fa);for(const _0x1f12f7 of _0x1a96cc){const _0x4465a8=_0x271c0b['diffData'][_0x1f12f7]?_0x271c0b['diffData'][_0x1f12f7]['insertions']:'[]',_0x36714d=_0x271c0b['diffData'][_0x1f12f7]?_0x271c0b['diffData'][_0x1f12f7]['deletions']:'[]';_0x271c0b['model'][_0x1f12f7]={'insertions':this['_utils']['_makeModelFromViewString'](_0x4465a8),'deletions':this['_utils']['_makeModelFromViewString'](_0x36714d)};}}for(const _0x5610a2 of _0x1a96cc){let _0x41f28e=null,_0x1f0cc0=0x0;const _0x33b2a7=new Map(Array['from'](_0x1b4b31['model'][_0x5610a2]['insertions']['markers'])['filter'](([_0x5b7e03])=>!_0x5b7e03['startsWith']('revision:')));let _0x282040=0x0;for(const _0x520e32 of _0x7a9d6f){const _0x5db600=this['_makeTape'](_0x520e32['model'][_0x5610a2]['insertions']);_0x520e32==_0x1b4b31?(_0x41f28e=_0x5db600,_0x1f0cc0=_0x41f28e['length'],_0x41f28e['forEach'](_0x3dc7cd=>{_0x3dc7cd['id']=_0x282040++;}),this['_processTape'](_0x41f28e)):this['_markInsertions'](_0x41f28e,_0x5db600);const _0xd4c0f9=_0x41f28e['filter'](_0xba683f=>!_0xba683f['isAdded'])['map'](_0x57b73d=>_0x57b73d['id']);let _0x2a5e98=0x0;const _0x42a74d=this['_makeTape'](_0x520e32['model'][_0x5610a2]['deletions']);_0x42a74d['forEach'](_0x42fec1=>{_0x42fec1['isRemoved']?_0x42fec1['id']=_0x1f0cc0++:_0x42fec1['id']=_0xd4c0f9[_0x2a5e98++];}),this['_processTape'](_0x42a74d),this['_setDistance'](_0x41f28e,'isAdded'),this['_setDistance'](_0x42a74d,'isRemoved'),_0x520e32==_0x1b4b31&&this['_markMarkers'](_0x41f28e,_0x33b2a7),_0x41f28e=this['_joinTapes'](_0x41f28e,_0x42a74d),this['_refreshStartEndIndex'](_0x41f28e),this['_setDistance'](_0x41f28e,'isRemoved');}_0x41f28e=_0x41f28e['filter'](_0x206540=>!(_0x206540['isAdded']&&_0x206540['isRemoved']));const _0x44a3ab=new Map(_0x1816a5['model'][_0x5610a2]['deletions']['markers']),_0x9d7a2e=new Set(_0x33b2a7['keys']());for(const _0x30099a of _0x44a3ab['keys']())_0x9d7a2e['delete'](_0x30099a);this['_markSuggestions'](_0x41f28e,_0x9d7a2e),this['_fixObsoleteTags'](_0x41f28e),_0x41f28e=this['_removeMissingPairs'](_0x41f28e),_0x41f28e=this['_markMismatchedRemovedTags'](_0x41f28e),_0x41f28e=this['_removeUnsupportedChanges'](_0x41f28e);const {root:_0x174152,changes:_0x47f5f1}=this['_makeModelFromTape'](_0x41f28e,_0x45e9a4,_0x5610a2);_0x3d9356['model'][_0x5610a2]=_0x174152;const _0xc093d0=_0x379700['get'](_0x5610a2);if(_0xc093d0){const _0x45740e=_0x45e9a4['get'](_0xc093d0['userId']),_0x161c38=new G({'author':_0x45740e,'type':_0xc093d0['isAttached']?'add':'remove','data':{'isOnRoot':!0x0},'createdAt':new Date(),'rootName':_0x5610a2});_0x47f5f1['unshift'](_0x161c38),_0x3d9356['attributes'][_0x5610a2]['revisionHistoryAttachChange']=_0x161c38['id'];}_0x3d9356['changes']=_0x3d9356['changes']['concat'](_0x47f5f1);}return _0x3d9356;}['_markMarkers'](_0x5112fe,_0x3bd18e){for(let _0x1d22f3=0x0;_0x1d22f3<_0x5112fe['length'];_0x1d22f3++)for(const [_0x318c64,_0x594d79]of _0x3bd18e)!_0x594d79['isCollapsed']&&_0x594d79['start']['isEqual'](_0x5112fe[_0x1d22f3]['previousPosition'])&&_0x5112fe[_0x1d22f3]['markersStart']['push'](_0x318c64),_0x594d79['end']['isEqual'](_0x5112fe[_0x1d22f3]['nextPosition'])&&_0x5112fe[_0x1d22f3]['markersEnd']['push'](_0x318c64);}['_joinTapes'](_0x8b53bb,_0x1287db){let _0x1c84b6=[],_0x49a007=0x0,_0x2f9c8f=0x0;for(;_0x49a007<_0x8b53bb['length']||_0x2f9c8f<_0x1287db['length'];){const _0x2bf483=_0x8b53bb[_0x49a007]||{},_0xd952a5=_0x1287db[_0x2f9c8f]||{};if(_0x2bf483['id']==_0xd952a5['id'])_0x49a007++,_0x2f9c8f++,_0x1c84b6['push'](_0x2bf483);else{if(_0xd952a5['isRemoved']&&_0x2bf483['isAdded']){const {commonTape:_0x24f4e3,iEnd:_0x395c8a,jEnd:_0xc003c}=this['_threeWayMerge'](_0x8b53bb,_0x49a007,_0x1287db,_0x2f9c8f);_0x1c84b6=_0x1c84b6['concat'](_0x24f4e3),_0x49a007=_0x395c8a,_0x2f9c8f=_0xc003c;}else _0xd952a5['isRemoved']?(_0x2f9c8f++,_0x1c84b6['push'](_0xd952a5)):(_0x49a007++,_0x1c84b6['push'](_0x2bf483));}}return _0x1c84b6;}['_markSuggestions'](_0x1bb5f0,_0x4d3cd8){const _0xcf27f7=[];for(let _0x33f564=0x0;_0x33f564<_0x1bb5f0['length'];_0x33f564++){for(let _0x2a4862=0x0;_0x2a4862<_0x1bb5f0[_0x33f564]['markersStart']['length'];_0x2a4862++){const _0x426363=_0x1bb5f0[_0x33f564]['markersStart'][_0x2a4862];if(!_0x4d3cd8['has'](_0x426363))continue;const {group:_0x416297,type:_0x29625e,authorId:_0x48c793}=_0x30ef39(_0x426363);'revision-suggestion'!=_0x416297||'insertion'!=_0x29625e&&'deletion'!=_0x29625e||(_0xcf27f7['unshift']({'type':_0x29625e,'name':_0x426363,'userId':_0x48c793}),_0x1bb5f0[_0x33f564]['markersStart']['splice'](_0x2a4862,0x1),_0x2a4862--);}_0x5c5d29(_0x1bb5f0[_0x33f564]);for(let _0x25b43d=0x0;_0x25b43d<_0x1bb5f0[_0x33f564]['markersEnd']['length'];_0x25b43d++){const _0x20f595=_0x1bb5f0[_0x33f564]['markersEnd'][_0x25b43d];if(!_0x4d3cd8['has'](_0x20f595))continue;const {group:_0x40bd94,type:_0x2269d8}=_0x30ef39(_0x20f595);if('revision-suggestion'!=_0x40bd94||'insertion'!=_0x2269d8&&'deletion'!=_0x2269d8)continue;_0x1bb5f0[_0x33f564]['markersEnd']['splice'](_0x25b43d,0x1),_0x25b43d--;const _0x394c1c=_0xcf27f7['findIndex'](_0x16467e=>_0x16467e['name']==_0x20f595);_0x394c1c>-0x1&&_0xcf27f7['splice'](_0x394c1c,0x1);}}function _0x30ef39(_0x4555e6){const _0x23440a=_0x4555e6['split'](':');return{'group':_0x23440a[0x0],'type':_0x23440a[0x1],'subType':_0x23440a['length']>=0x5?_0x23440a[0x2]:null,'id':_0x23440a['length']<0x5?_0x23440a[0x2]:_0x23440a[0x3],'authorId':_0x23440a['length']<0x5?_0x23440a[0x3]:_0x23440a[0x4],'markerCount':0x6==_0x23440a['length']?_0x23440a[0x5]:null};}function _0x5c5d29(_0x4da31e){for(let _0x3603f1=0x0;_0x3603f1<_0xcf27f7['length'];_0x3603f1++){if(_0x4da31e['isAdded']&&'insertion'==_0xcf27f7[_0x3603f1]['type']&&_0x4da31e['isAdded']['userId']==_0xcf27f7[_0x3603f1]['userId'])return _0x4da31e['isAddSuggestion']=_0xcf27f7[_0x3603f1],void delete _0x4da31e['isAdded'];if(!_0x4da31e['isAdded']&&!_0x4da31e['isRemoved']&&'deletion'==_0xcf27f7[_0x3603f1]['type'])return void(_0x4da31e['isRemoveSuggestion']=_0xcf27f7[_0x3603f1]);}}}['_setDistance'](_0x13e553,_0x4817cc){let _0x4c5b17=0x0,_0x49641c=!0x1;const _0x5478d0=new Map();for(const _0x2b1099 of _0x13e553)_0x2b1099[_0x4817cc]?_0x49641c&&(_0x4c5b17++,_0x49641c=!0x1):(_0x4c5b17++,_0x49641c=!0x0),_0x5478d0['set'](_0x2b1099['id'],_0x4c5b17);for(let _0x50801d=0x0;_0x50801d<_0x13e553['length'];_0x50801d++){if('isRemoved'==_0x4817cc&&_0x13e553[_0x50801d]['isAdded']||'isAdded'==_0x4817cc&&_0x13e553[_0x50801d]['isRemoved'])continue;if('text'==_0x13e553[_0x50801d]['type']){_0x13e553[_0x50801d]['distance']=0x0;continue;}const _0x5092cb=_0x5478d0['get'](_0x13e553[_0x50801d]['pairId']),_0x3db345=_0x5478d0['get'](_0x13e553[_0x50801d]['id']);_0x13e553[_0x50801d]['distance']=_0x5092cb-_0x3db345;}}['_getRevisionsRange'](_0x378426,_0x8f9b0f,_0x5e02a3=!0x1){const _0x3279ab=[];let _0x4410b1=this['repository']['getIndex'](_0x378426),_0x211ab5=this['repository']['getIndex'](_0x8f9b0f);for(-0x1==_0x211ab5&&(_0x211ab5=this['repository']['_revisions']['length'],_0x5e02a3=!0x1);_0x4410b1<_0x211ab5;)_0x3279ab['push'](this['repository']['getRevision'](_0x4410b1)),_0x4410b1++;return _0x5e02a3&&_0x3279ab['push'](this['repository']['getRevision'](_0x4410b1)),_0x3279ab;}['_threeWayMerge'](_0x4c7429,_0x25a518,_0x1737dd,_0x5e406c){const _0x345bee=this['editor']['model']['schema'];let _0x2d911d=_0x25a518;for(;_0x4c7429[_0x2d911d]&&_0x4c7429[_0x2d911d]['isAdded'];)_0x2d911d++;let _0x5bfca5=_0x5e406c;for(;_0x1737dd[_0x5bfca5]&&_0x1737dd[_0x5bfca5]['isRemoved'];)_0x5bfca5++;_0x125afb(_0x4c7429,_0x25a518,_0x2d911d),_0x125afb(_0x1737dd,_0x5e406c,_0x5bfca5);const _0x377ed1=_0x1737dd['slice'](_0x5e406c,_0x5bfca5)['concat'](_0x4c7429['slice'](_0x25a518,_0x2d911d));return _0x377ed1['sort']((_0x3e1762,_0x4279c4)=>_0x3e1762['side']!=_0x4279c4['side']?_0x3e1762['side']-_0x4279c4['side']:_0x3e1762['level']!=_0x4279c4['level']?_0x3e1762['level']-_0x4279c4['level']:_0x3e1762['distance']!=_0x4279c4['distance']?_0x4279c4['distance']-_0x3e1762['distance']:!!_0x3e1762['isAdded']!=!!_0x4279c4['isAdded']?-0x1==_0x3e1762['side']||0x0==_0x3e1762['side']?_0x3e1762['isAdded']?-0x1:0x1:_0x3e1762['isAdded']?0x1:-0x1:_0x3e1762['index']-_0x4279c4['index']),{'commonTape':_0x377ed1,'iEnd':_0x2d911d,'jEnd':_0x5bfca5};function _0x125afb(_0x256a23,_0x4c1644,_0x42f650){let _0x297098=-0x1,_0x512a8e=Number['POSITIVE_INFINITY'],_0x4305a2=!0x0;for(let _0x187423=_0x4c1644;_0x187423<_0x42f650;_0x187423++)if(_0x345bee['isInline'](_0x256a23[_0x187423]['item'])||(_0x4305a2=!0x1),_0x256a23[_0x187423]['item']['startIndex']<_0x4c1644&&(_0x297098=_0x187423),_0x256a23[_0x187423]['item']['endIndex']>=_0x42f650){_0x512a8e=_0x187423;break;}_0x4305a2&&(_0x297098=_0x42f650-0x1);for(let _0x376e25=_0x4c1644;_0x376e25<_0x42f650;_0x376e25++)_0x256a23[_0x376e25]['side']=_0x376e25<=_0x297098?-0x1:_0x376e25<_0x512a8e?0x0:0x1,_0x256a23[_0x376e25]['index']=_0x376e25;let _0x14adb7=0x0;for(let _0x4275b0=_0x4c1644;_0x4275b0<=_0x297098;_0x4275b0++)0x0==_0x256a23[_0x4275b0]['distance']?_0x256a23[_0x4275b0]['level']=_0x14adb7:(_0x14adb7++,_0x256a23[_0x4275b0]['level']=_0x14adb7,_0x14adb7++);for(let _0xc94835=_0x4c1644;_0xc94835<_0x42f650;_0xc94835++)0x0==_0x256a23[_0xc94835]['side']&&(_0x256a23[_0xc94835]['level']=_0x14adb7);_0x14adb7=0x0;for(let _0x2fdacc=_0x42f650-0x1;_0x2fdacc>=_0x512a8e;_0x2fdacc--)0x0==_0x256a23[_0x2fdacc]['distance']?_0x256a23[_0x2fdacc]['level']=_0x14adb7:(_0x14adb7--,_0x256a23[_0x2fdacc]['level']=_0x14adb7,_0x14adb7--);}}['_fixObsoleteTags'](_0x3237e9){const _0x289447=new Map(),_0x1d4bc7=this['editor']['model']['schema'];for(let _0x29e19e=0x1;_0x29e19e<_0x3237e9['length'];_0x29e19e++){let _0x44ede1,_0x14a591,_0x56b6f8;const _0x205392=_0x3237e9[_0x29e19e],_0x58de1e=_0x3237e9[_0x29e19e-0x1];if('text'==_0x205392['type'])continue;if(_0x205392['type']!=_0x58de1e['type'])continue;if(!_0x1d4bc7['isBlock'](_0x58de1e['item'])||_0x1d4bc7['isLimit'](_0x58de1e['item']))continue;if(!_0x1d4bc7['isBlock'](_0x205392['item'])||_0x1d4bc7['isLimit'](_0x205392['item']))continue;if((_0x3237e9[_0x29e19e]['isAdded']||_0x3237e9[_0x29e19e]['isAddSuggestion'])&&_0x3237e9[_0x29e19e-0x1]['isRemoved'])_0x44ede1=_0x3237e9[_0x29e19e],_0x14a591=_0x3237e9[_0x29e19e-0x1],_0x56b6f8=_0x29e19e-0x1;else{if(!_0x3237e9[_0x29e19e]['isRemoved']||!_0x3237e9[_0x29e19e-0x1]['isAdded']&&!_0x3237e9[_0x29e19e-0x1]['isAddSuggestion'])continue;_0x44ede1=_0x3237e9[_0x29e19e-0x1],_0x14a591=_0x3237e9[_0x29e19e],_0x56b6f8=_0x29e19e;}const _0x40de98=_0x44ede1['level']==_0x14a591['level'],_0x382554=Math['abs'](_0x44ede1['level'])<Math['abs'](_0x14a591['level'])&&0x0==_0x14a591['distance'];(_0x40de98||_0x382554)&&(_0x289447['set'](_0x14a591['id'],_0x44ede1['id']),_0x3237e9['splice'](_0x56b6f8,0x1),_0x29e19e--,_0x44ede1['isAdded']=!0x1);}for(let _0x2518b1=0x0;_0x2518b1<_0x3237e9['length'];_0x2518b1++)_0x289447['has'](_0x3237e9[_0x2518b1]['pairId'])&&(_0x3237e9[_0x2518b1]['pairId']=_0x289447['get'](_0x3237e9[_0x2518b1]['pairId']));}['_removeMissingPairs'](_0x19fdbf){const _0x1083c0=new Set(_0x19fdbf['map'](_0x561f0a=>_0x561f0a['id']));for(let _0x4f9ff8=0x0;_0x4f9ff8<_0x19fdbf['length'];_0x4f9ff8++)_0x1083c0['has'](_0x19fdbf[_0x4f9ff8]['pairId'])||0x0==_0x19fdbf[_0x4f9ff8]['distance']||(_0x19fdbf[_0x4f9ff8]['isIncorrect']=!0x0);return _0x19fdbf['filter'](_0x6c07b6=>!_0x6c07b6['isIncorrect']);}['_markMismatchedRemovedTags'](_0xd5560f){const _0x452df9=new Set();for(let _0x5af8bc=0x0;_0x5af8bc<_0xd5560f['length'];_0x5af8bc++){if(_0x452df9['has'](_0xd5560f[_0x5af8bc]['id'])&&_0xd5560f[_0x5af8bc]['isRemoved']&&(_0xd5560f[_0x5af8bc]['isIncorrect']=!0x0),_0xd5560f[_0x5af8bc]['isIncorrect'])continue;if(0x0==_0xd5560f[_0x5af8bc]['distance'])continue;if('elementStart'!=_0xd5560f[_0x5af8bc]['type'])continue;if(null==_0xd5560f[_0x5af8bc]['pairId'])continue;let _0x4bae30=_0x5af8bc+0x1,_0x2a9199=0x0;for(;_0xd5560f[_0x4bae30]['id']!=_0xd5560f[_0x5af8bc]['pairId'];)'elementStart'==_0xd5560f[_0x4bae30]['type']?_0x2a9199++:'elementEnd'==_0xd5560f[_0x4bae30]['type']&&_0x2a9199--,_0x4bae30++;if(0x0!=_0x2a9199){if(_0xd5560f[_0x5af8bc]['isRemoved'])_0xd5560f[_0x5af8bc]['isIncorrect']=!0x0;else{for(;_0x4bae30!=_0x5af8bc;)_0xd5560f[_0x4bae30]['isRemoved']&&0x0!=_0xd5560f[_0x4bae30]['distance']&&(_0xd5560f[_0x4bae30]['isIncorrect']=!0x0,_0x452df9['add'](_0xd5560f[_0x4bae30]['pairId'])),_0x4bae30--;}}}return _0xd5560f['filter'](_0x5c295e=>!_0x5c295e['isIncorrect']);}['_removeUnsupportedChanges'](_0x5adc57){const _0x5e86c2=this['editor']['model']['schema'];for(let _0x3568d9=0x0;_0x3568d9<_0x5adc57['length'];_0x3568d9++){if(!(_0x5adc57[_0x3568d9]['isAdded']||_0x5adc57[_0x3568d9]['isAddSuggestion']||_0x5adc57[_0x3568d9]['isRemoved']||_0x5adc57[_0x3568d9]['isRemoveSuggestion']))continue;if(0x0==_0x5adc57[_0x3568d9]['distance'])continue;const _0x55d58c=_0x5adc57[_0x3568d9]['item'];_0x5e86c2['isBlock'](_0x55d58c)||_0x5e86c2['isLimit'](_0x55d58c)||(_0x5adc57[_0x3568d9]['isAdded']&&delete _0x5adc57[_0x3568d9]['isAdded'],_0x5adc57[_0x3568d9]['isAddSuggestion']&&delete _0x5adc57[_0x3568d9]['isAddSuggestion'],_0x5adc57[_0x3568d9]['isRemoveSuggestion']&&delete _0x5adc57[_0x3568d9]['isRemoveSuggestion'],_0x5adc57[_0x3568d9]['isRemoved']&&(_0x5adc57[_0x3568d9]['isIncorrect']=!0x0));}return _0x5adc57['filter'](_0x521824=>!_0x521824['isIncorrect']);}['_makeModelFromTape'](_0x285a76,_0x33cd55,_0x3618c9){const _0x221c4f=new _0x72fa5(),_0x5ae28e=[],_0x11dce6=new Map(),_0x23bef9=this['editor']['model'],_0x2c3b27=_0x23bef9['schema'],_0x529b95=[_0x221c4f],_0x5d2ea4={},_0x6b3112={'isAdded':[],'isRemoved':[],'isAddSuggestion':[],'isRemoveSuggestion':[]};let _0x40fa39=null;const _0x25e22f=[0x0];for(let _0x58a112=0x0;_0x58a112<_0x285a76['length'];_0x58a112++)if('elementStart'===_0x285a76[_0x58a112]['type']){_0x285a76[_0x58a112]['previousPosition']=_0x23bef9['createPositionFromPath'](_0x221c4f,_0x25e22f);const _0xbc717a=new _0x37c7de(_0x285a76[_0x58a112]['item']['name'],_0x285a76[_0x58a112]['item']['getAttributes']());_0x529b95[0x0]['_appendChild'](_0xbc717a),_0x25e22f['push'](0x0),_0x529b95['unshift'](_0xbc717a),_0x285a76[_0x58a112]['nextPosition']=_0x23bef9['createPositionFromPath'](_0x221c4f,_0x25e22f);}else'elementEnd'===_0x285a76[_0x58a112]['type']?(_0x529b95['shift'](),_0x285a76[_0x58a112]['previousPosition']=_0x23bef9['createPositionFromPath'](_0x221c4f,_0x25e22f),_0x25e22f['pop'](),_0x25e22f[_0x25e22f['length']-0x1]++,_0x285a76[_0x58a112]['nextPosition']=_0x23bef9['createPositionFromPath'](_0x221c4f,_0x25e22f)):(_0x285a76[_0x58a112]['previousPosition']=_0x23bef9['createPositionFromPath'](_0x221c4f,_0x25e22f),_0x40fa39?_0x40fa39['_data']+=_0x285a76[_0x58a112]['item']['data']:_0x40fa39=new _0x4230dd(_0x285a76[_0x58a112]['item']['data'],_0x285a76[_0x58a112]['item']['getAttributes']()),_0x285a76[_0x58a112+0x1]&&'text'===_0x285a76[_0x58a112+0x1]['type']&&_0x1cf62a(_0x40fa39,_0x285a76[_0x58a112+0x1]['item'])||(_0x529b95[0x0]['_appendChild'](_0x40fa39),_0x40fa39=null),_0x25e22f[_0x25e22f['length']-0x1]+=_0x285a76[_0x58a112]['item']['offsetSize'],_0x285a76[_0x58a112]['nextPosition']=_0x23bef9['createPositionFromPath'](_0x221c4f,_0x25e22f));for(let _0x188dc6=0x0;_0x188dc6<_0x285a76['length'];_0x188dc6++){const _0x250104=_0x285a76[_0x188dc6]['previousPosition'],_0x58bd4e=_0x285a76[_0x188dc6]['nextPosition'];for(const _0x4cff7c of _0x285a76[_0x188dc6]['markersStart'])_0x11dce6['set'](_0x4cff7c,{'start':_0x250104,'end':null});_0x526803('isRemoveSuggestion',_0x188dc6,_0x250104,_0x58bd4e),_0x526803('isAddSuggestion',_0x188dc6,_0x250104,_0x58bd4e),_0x526803('isRemoved',_0x188dc6,_0x250104,_0x58bd4e),_0x526803('isAdded',_0x188dc6,_0x250104,_0x58bd4e);for(const _0x57a83f of _0x285a76[_0x188dc6]['markersEnd']){const _0x4f0267=_0x11dce6['get'](_0x57a83f);_0x4f0267?_0x4f0267['end']=_0x58bd4e:_0x11dce6['set'](_0x57a83f,{'start':_0x58bd4e,'end':_0x58bd4e});}}for(const [_0x3c13b0,_0x1411ce]of _0x11dce6){const _0x4dee17=this['editor']['model']['createRange'](_0x1411ce['start'],_0x1411ce['end']);_0x221c4f['markers']['set'](_0x3c13b0,_0x4dee17);}return _0x5ae28e['sort']((_0x1f7315,_0x214a27)=>{const _0x1b7021=_0x221c4f['markers']['get']('revision:'+_0x1f7315['id']),_0x2a0665=_0x221c4f['markers']['get']('revision:'+_0x214a27['id']);return _0x1b7021['start']['isBefore'](_0x2a0665['start'])?-0x1:_0x1b7021['start']['isAfter'](_0x2a0665['start'])?0x1:_0x1b7021['end']['isBefore'](_0x2a0665['end'])?-0x1:_0x1b7021['end']['isAfter'](_0x2a0665['end'])?0x1:'add'===_0x1f7315['type']?-0x1:0x1;}),{'root':_0x221c4f,'changes':_0x5ae28e};function _0x526803(_0x2af650,_0x21d104,_0x4077c5,_0x34db7d){const _0x535213=!!_0x285a76[_0x21d104][_0x2af650],_0x511aef=_0x535213?_0x285a76[_0x21d104][_0x2af650]['userId']:null,_0x53119a=_0x21d104===_0x285a76['length']-0x1,_0x4172f0=_0x6b3112[_0x2af650][0x0],_0x498eee=_0x2c3b27['isObject'](_0x285a76[_0x21d104]['item']);!_0x5d2ea4[_0x2af650]&&_0x535213?_0x5d2ea4[_0x2af650]={'start':_0x4077c5,'tapeItem':_0x285a76[_0x21d104],'userId':_0x511aef,'type':_0x2af650}:_0x5d2ea4[_0x2af650]&&!_0x535213?(_0x5d2ea4[_0x2af650]['end']=_0x4077c5,_0x14de55(_0x5d2ea4[_0x2af650]),_0x5d2ea4[_0x2af650]=null):_0x5d2ea4[_0x2af650]&&_0x535213&&_0x5d2ea4[_0x2af650]['userId']!==_0x511aef&&(_0x5d2ea4[_0x2af650]['end']=_0x4077c5,_0x4172f0&&_0x4172f0['userId']===_0x5d2ea4[_0x2af650]['userId']||_0x14de55(_0x5d2ea4[_0x2af650]),_0x5d2ea4[_0x2af650]={'start':_0x4077c5,'tapeItem':_0x285a76[_0x21d104],'userId':_0x511aef,'type':_0x2af650}),_0x5d2ea4[_0x2af650]&&_0x498eee&&('elementStart'!==_0x285a76[_0x21d104]['type']||_0x4172f0&&_0x4172f0['userId']===_0x511aef||_0x6b3112[_0x2af650]['unshift']({'userId':_0x511aef,'object':_0x285a76[_0x21d104]['item'],'change':_0x5d2ea4[_0x2af650]}),'elementEnd'===_0x285a76[_0x21d104]['type']&&_0x4172f0&&_0x4172f0['object']===_0x285a76[_0x21d104]['item']&&(_0x6b3112[_0x2af650]['shift'](),_0x5d2ea4[_0x2af650]=_0x4172f0['change'])),_0x5d2ea4[_0x2af650]&&_0x53119a&&(_0x5d2ea4[_0x2af650]['end']=_0x34db7d,_0x14de55(_0x5d2ea4[_0x2af650]),_0x5d2ea4[_0x2af650]=null);}function _0x14de55({start:_0x54eb55,end:_0x52142e,tapeItem:_0x4af49c,userId:_0x1b07e2,type:_0x40b1d7}){const _0x546bdc=_0x4af49c['item'],_0x5d45a7=_0x23bef9['schema']['isBlock'](_0x546bdc)&&!_0x23bef9['schema']['isLimit'](_0x546bdc),_0x49276e=_0x54eb55['nodeAfter']==_0x52142e['parent']&&_0x52142e['isAtStart'];if(_0x5d45a7&&_0x49276e)return;const _0x4b3524=_0x23bef9['createRange'](_0x54eb55,_0x52142e),_0x36818d=_0x33cd55['get'](_0x1b07e2),_0x2a3cb8=new G({'author':_0x36818d,'type':'isAdded'==_0x40b1d7||'isAddSuggestion'==_0x40b1d7?'add':'remove','data':{'isSuggestion':'isAddSuggestion'==_0x40b1d7||'isRemoveSuggestion'==_0x40b1d7},'createdAt':new Date(),'rootName':_0x3618c9});_0x5ae28e['push'](_0x2a3cb8),_0x221c4f['markers']['set']('revision:'+_0x2a3cb8['id'],_0x4b3524);}function _0x1cf62a(_0x33d922,_0xdeb475){const _0x12558f=_0x33d922['getAttributes'](),_0x47a40c=_0xdeb475['getAttributes']();for(const _0xa7238b of _0x12558f){if(_0xa7238b[0x1]!==_0xdeb475['getAttribute'](_0xa7238b[0x0]))return!0x1;_0x47a40c['next']();}return _0x47a40c['next']()['done'];}}['_setConversion'](){this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision','view':_0x60914a=>{const _0x1a44eb=_0x60914a['markerName']['split'](':')[0x1],_0x2183d5=this['_getChangeFromId'](_0x1a44eb);if(!_0x2183d5)return null;const _0x12b046='add'==_0x2183d5['type']?'insertion':'deletion',_0x24802b=['ck-suggestion-marker','ck-suggestion-marker-'+_0x12b046];return _0x2183d5['data']['isSuggestion']&&_0x24802b['push']('ck-suggestion-marker-'+_0x12b046+'-new'),this['activeChange']==_0x2183d5&&_0x24802b['push']('ck-suggestion-marker--active'),{'classes':_0x24802b,'attributes':{'data-change-id':_0x1a44eb}};}}),this['editor']['conversion']['for']('upcast')['add'](_0x5c2a9b=>{_0x5c2a9b['on']('element:pre',(_0x3c614b,_0x277f18,_0x38377c)=>{const _0x2a8a70=_0x277f18['viewItem']['getChild'](0x0);if(!_0x2a8a70||!_0x2a8a70['is']('element','code'))return;if(!_0x38377c['consumable']['consume'](_0x2a8a70,{'attributes':['vid_start','vid_end']}))return;const _0x4aa788=_0x277f18['modelRange']['start']['nodeAfter'];_0x38377c['writer']['setAttribute']('vid_start',_0x2a8a70['getAttribute']('vid_start'),_0x4aa788),_0x38377c['writer']['setAttribute']('vid_end',_0x2a8a70['getAttribute']('vid_end'),_0x4aa788);},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['add'](_0xae337e=>{_0xae337e['on']('element',(_0x526eed,_0x5be237,_0x53617e)=>{if(!_0x53617e['consumable']['consume'](_0x5be237['viewItem'],{'attributes':['vid_start','vid_end']}))return;if(_0x5be237['modelRange']['isCollapsed'])return;const _0x30dbef=_0x5be237['modelRange']['start']['nodeAfter'];_0x30dbef['hasAttribute']('vid_start')||_0x30dbef['hasAttribute']('vid')||(_0x53617e['writer']['setAttribute']('vid_start',_0x5be237['viewItem']['getAttribute']('vid_start'),_0x30dbef),_0x53617e['writer']['setAttribute']('vid_end',_0x5be237['viewItem']['getAttribute']('vid_end'),_0x30dbef));},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['elementToAttribute']({'view':{'name':'span','attributes':{'vid':!0x0}},'model':{'key':'vid','value':_0xf58931=>_0xf58931['getAttribute']('vid')}}),this['editor']['model']['schema']['on']('checkAttribute',(_0x5131f7,[,_0x3f6c6f])=>{['vid_start','vid_end','vid']['includes'](_0x3f6c6f)&&(_0x5131f7['return']=!0x0,_0x5131f7['stop']());},{'priority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x464509=>{_0x464509['on']('attribute:vid',(_0x58d7db,_0x29624e,_0x151bc6)=>{if('\x20'!=_0x29624e['item']['data']||_0x29624e['item']['parent']['maxOffset']>0x1)return;if(!_0x151bc6['consumable']['consume'](_0x29624e['item'],_0x58d7db['name']))return;const _0x170574=_0x151bc6['writer'],_0x1ac5ab=_0x151bc6['mapper']['toViewRange'](_0x29624e['range']);_0x170574['wrap'](_0x1ac5ab,_0x170574['createAttributeElement']('span'));});}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',function(_0xfe9f74){const _0x112b24=_0xfe9f74['plugins']['get']('RevisionViewer');return(_0xeba3ba,_0x41d6f9,_0x31898a)=>{const _0x1b47cc=_0x41d6f9['markerName']['split'](':')[0x1],_0x543629=_0x112b24['_getChangeFromId'](_0x1b47cc);if(!_0x543629)return null;const _0x1a4d7d='add'==_0x543629['type']?'split':'merge';if(!_0x31898a['consumable']['test'](_0x41d6f9['markerRange'],_0xeba3ba['name']))return;const _0x3284a4=_0x41d6f9['markerRange']['getWalker'](),_0xdcc039=_0x41d6f9['markerRange']['start'],_0x351c05=_0xfe9f74['model']['schema'];let _0x1f2662=null,_0xd00026=null,_0x59043f=!0x1,_0x555174=!0x1;for(const _0x56cbe5 of _0x3284a4){const _0x44e5ce=_0x56cbe5['item'];_0x59043f=_0x59043f||_0x351c05['isContent'](_0x44e5ce);const _0x362b89=_0x31898a['mapper']['toViewElement'](_0x44e5ce);if(_0x362b89&&_0x362b89['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x56cbe5['type']&&(_0x351c05['isBlock'](_0x44e5ce)&&!_0x351c05['isLimit'](_0x44e5ce)&&(_0x44e5ce['nextSibling']||_0xdcc039['isAtEnd']?_0x1f2662&&_0x1f2662['parent']==_0x44e5ce||(_0x1f2662=_0x44e5ce,_0x290f7c(_0x56cbe5['previousPosition']),_0x555174=!0x0):_0xd00026=_0xd00026||_0x56cbe5['previousPosition']));}function _0x290f7c(_0x3da93b){const _0x16696e=_0x31898a['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x1a4d7d}),_0x237775=_0x31898a['mapper']['toViewPosition'](_0x3da93b);_0x543629['data']['isSuggestion']&&_0x31898a['writer']['addClass']('ck-suggestion-marker-'+_0x1a4d7d+'-new',_0x16696e),_0x112b24['activeChange']==_0x543629&&_0x31898a['writer']['addClass']('ck-suggestion-marker--active',_0x16696e),_0x31898a['writer']['insert'](_0x237775,_0x16696e),_0x31898a['mapper']['bindElementToMarker'](_0x16696e,_0x41d6f9['markerName']);}_0x59043f||_0x555174||!_0xd00026||_0x290f7c(_0xd00026);};}(this['editor']),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision',(_0x30dee1,_0x14f9ab,_0x378a8f)=>{const _0x2d0b32=_0x378a8f['mapper']['markerNameToElements'](_0x14f9ab['markerName']);if(_0x2d0b32){for(const _0x4597a7 of _0x2d0b32)(_0x4597a7['hasClass']('ck-suggestion-marker-split')||_0x4597a7['hasClass']('ck-suggestion-marker-merge'))&&(_0x378a8f['mapper']['unbindElementFromMarkerName'](_0x4597a7,_0x14f9ab['markerName']),_0x378a8f['writer']['remove'](_0x4597a7));}},{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',(_0x3f82cd,_0x1306a5,_0x38827e)=>{const _0x55a7bf=_0x1306a5['markerName']['split'](':')[0x1],_0x2b2279=this['_getChangeFromId'](_0x55a7bf);if(!_0x2b2279)return null;const _0x3c84c7='add'==_0x2b2279['type']?'split':'merge';if(_0x38827e['consumable']['test'](_0x1306a5['markerRange'],_0x3f82cd['name']))for(const _0x2a6625 of _0x1306a5['markerRange']['getItems']()){if(!_0x2a6625['is']('element','softBreak'))continue;const _0x111b03=_0x38827e['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x3c84c7}),_0x4d3502=_0x38827e['mapper']['toViewPosition'](this['editor']['model']['createPositionBefore'](_0x2a6625));_0x2b2279['data']['isSuggestion']&&_0x38827e['writer']['addClass']('ck-suggestion-marker-'+_0x3c84c7+'-new',_0x111b03),this['activeChange']==_0x2b2279&&_0x38827e['writer']['addClass']('ck-suggestion-marker--active',_0x111b03),_0x38827e['writer']['insert'](_0x4d3502,_0x111b03),_0x38827e['mapper']['bindElementToMarker'](_0x111b03,_0x1306a5['markerName']);}},{'priority':'high'}),this['editor']['model']['document']['on']('change',()=>{this['editor']['editing']['view']['change'](_0x3c171b=>{for(const _0x50ecd1 of this['editor']['model']['document']['getRootNames']()){const _0x2e8cc9=this['editor']['model']['document']['getRoot'](_0x50ecd1),_0x70585b=this['editor']['editing']['view']['document']['getRoot'](_0x50ecd1);if(_0x70585b){const _0xdc4697=_0x2e8cc9['getAttribute']('revisionHistoryAttachChange');if(_0x3c171b['removeAttribute']('data-change-id',_0x70585b),_0x3c171b['removeClass']('ck-revision-history-root-add',_0x70585b),_0x3c171b['removeClass']('ck-revision-history-root-remove',_0x70585b),_0x3c171b['removeClass']('ck-revision-history-root--active',_0x70585b),_0xdc4697){const _0x13c4e4=this['_getChangeFromId'](_0xdc4697);if(!_0x13c4e4)return null;_0x3c171b['setAttribute']('data-change-id',_0xdc4697,_0x70585b),_0x3c171b['addClass']('ck-revision-history-root-'+_0x13c4e4['type'],_0x70585b),this['activeChange']==_0x13c4e4&&_0x3c171b['addClass']('ck-revision-history-root--active',_0x70585b);}}}});}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'comment','model':_0x3f4326=>'revision-comment:'+_0x3f4326,'converterPriority':'highest'}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'suggestion','model':_0x3b5c58=>'revision-suggestion:'+_0x3b5c58,'converterPriority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision-suggestion','view':_0x2ae2cf=>({'name':'suggestion:'+_0x2ae2cf,'group':'revision-suggestion'}),'converterPriority':'highest'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision-suggestion','view':_0x357720=>{const _0x590122=_0x357720['markerName']['split'](':')[0x1];return'insertion'!=_0x590122&&'deletion'!=_0x590122?null:{'classes':['ck-suggestion-preview-marker','ck-suggestion-preview-marker-'+_0x590122]};}}),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',(_0x2dc5c4,_0x17171d,_0x211044)=>{const _0xaa74d3=_0x211044['mapper']['markerNameToElements'](_0x17171d['markerName']);if(_0xaa74d3){for(const _0x3be692 of _0xaa74d3)_0x3be692['is']('uiElement')&&(_0x211044['mapper']['unbindElementFromMarkerName'](_0x3be692,_0x17171d['markerName']),_0x211044['writer']['remove'](_0x3be692));}},{'priority':'high'});}['_getChangeFromId'](_0x16292b){return this['_changeIdToChange']['get'](_0x16292b);}['_getViewForChange'](_0x470ff0){return this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=new z(this['editor']['locale'],_0x470ff0),this['_changeView'];}['_initInteractions'](){this['editor']['model']['document']['selection']['observeMarkers']('revision'),this['on']('change:activeView',(_0x143ffc,_0x33be03,_0x4ffee8,_0x108457)=>{_0x108457&&this['_balloon']['remove'](_0x108457),_0x4ffee8&&(this['_balloon']['add']({'view':_0x4ffee8,'stackId':'revisionHistoryLabel','position':{'target':()=>{const _0x5db4d9=this['editor']['editing'],_0xc24d66=this['_getChangeFromId'](_0x4ffee8['changeId']);let _0x1a2586;if(_0xc24d66['data']['isOnRoot']){const _0x54f073=_0x5db4d9['view']['getDomRoot'](_0xc24d66['rootName']);_0x1a2586=Array['from'](_0x54f073['getClientRects']());}else{const _0x28c6ce=this['editor']['model']['markers']['get']('revision:'+_0x4ffee8['changeId']);_0x1a2586=Array['from'](_0x5db4d9['mapper']['markerNameToElements'](_0x28c6ce['name']))['map'](_0x5941c3=>_0x5db4d9['view']['domConverter']['mapViewToDom'](_0x5941c3))['map'](_0x3d859a=>Array['from'](_0x3d859a['getClientRects']()))['flat']();}if(!this['_activeViewTarget'])return _0x1a2586[0x0];return _0x1a2586['find'](_0x27394e=>_0x27394e['top']-0x3<=this['_activeViewTarget']['y']&&_0x27394e['bottom']+0x3>=this['_activeViewTarget']['y']&&_0x27394e['left']-0x3<=this['_activeViewTarget']['x']&&_0x27394e['right']+0x3>=this['_activeViewTarget']['x'])||_0x1a2586[0x0];}}}),this['_balloon']['showStack']('revisionHistoryLabel'));}),this['on']('change:activeChange',(_0x1835e5,_0x2675df,_0x119d27,_0x56c31e)=>{this['activeView']=_0x119d27?this['_getViewForChange'](_0x119d27):null,this['editor']['model']['change'](()=>{const _0xf0033a=this['editor']['editing'];_0x56c31e&&(_0x56c31e['data']['isOnRoot']?_0xf0033a['view']['change'](_0x248c14=>{_0x248c14['removeClass']('ck-revision-history-root--active',_0xf0033a['view']['document']['getRoot'](_0x56c31e['rootName']));}):_0xf0033a['reconvertMarker']('revision:'+_0x56c31e['id'])),_0x119d27&&(_0x119d27['data']['isOnRoot']?_0xf0033a['view']['change'](_0x577511=>{_0x577511['addClass']('ck-revision-history-root--active',_0xf0033a['view']['document']['getRoot'](_0x119d27['rootName']));}):_0xf0033a['reconvertMarker']('revision:'+_0x119d27['id']));});}),this['listenTo'](this['editor']['editing']['view']['document'],'mouseover',(_0xcfbf11,_0x25da03)=>{if(this['activeChange'])return;const _0x359221=this['_findChangeIdFromDomTarget'](_0x25da03['target']),_0x980ed0=this['_changeIdToChange']['get'](_0x359221);_0x980ed0?(this['_activeViewTarget']={'x':_0x25da03['domEvent']['x'],'y':_0x25da03['domEvent']['y']},this['activeView']=this['_getViewForChange'](_0x980ed0)):(this['_activeViewTarget']=null,this['activeView']=null);}),this['listenTo'](this['editor']['editing']['view']['document'],'mousedown',(_0x27da35,_0x164de3)=>{const _0x314d9a=this['_findChangeIdFromDomTarget'](_0x164de3['target']),_0x11dc49=this['_changeIdToChange']['get'](_0x314d9a);_0x11dc49?(this['_activeViewTarget']={'x':_0x164de3['domEvent']['x'],'y':_0x164de3['domEvent']['y']},_0x11dc49===this['activeChange']?this['_balloon']['updatePosition']():this['activeChange']=_0x11dc49):(this['_activeViewTarget']=null,this['activeChange']=null);});}['_findChangeIdFromDomTarget'](_0x42ad15){do{const _0x214ed8=_0x42ad15['getAttribute']('data-change-id');if(_0x214ed8)return _0x214ed8;_0x42ad15=_0x42ad15['parent'];}while(_0x42ad15);return null;}['_cleanMarkers'](){this['editor']['model']['change'](_0x48140e=>{for(const _0x3262e8 of this['editor']['model']['markers'])_0x48140e['removeMarker'](_0x3262e8);});}}function Q(_0x4a3937,_0x122286){return(_0x5931a7,_0x5ec875,_0x3cd687)=>{if(!_0x3cd687['consumable']['test'](_0x5ec875['markerRange'],_0x5931a7['name']))return;const _0x537678=_0x5ec875['markerRange']['getWalker'](),_0x1e23cb=_0x5ec875['markerRange']['start'],_0x500a30=_0x4a3937['model']['schema'];let _0x501da8=null,_0x199b4f=null,_0x5b7f0d=!0x1,_0x285527=!0x1;for(const _0x3b44e5 of _0x537678){const _0x1ad061=_0x3b44e5['item'];_0x5b7f0d=_0x5b7f0d||_0x500a30['isContent'](_0x1ad061);const _0x57267f=_0x3cd687['mapper']['toViewElement'](_0x1ad061);if(_0x57267f&&_0x57267f['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x3b44e5['type']&&(_0x500a30['isBlock'](_0x1ad061)&&!_0x500a30['isLimit'](_0x1ad061)&&(_0x1ad061['nextSibling']||_0x1e23cb['isAtEnd']?_0x501da8&&_0x501da8['parent']==_0x1ad061||(_0x501da8=_0x1ad061,_0x21433b(_0x3b44e5['previousPosition']),_0x285527=!0x0):_0x199b4f=_0x199b4f||_0x3b44e5['previousPosition']));}function _0x21433b(_0x171e50){const _0x140f6f=_0x3cd687['mapper']['toViewPosition'](_0x171e50),_0x3c8922=_0x3cd687['writer']['createUIElement']('span',{'class':'ck-suggestion-preview-marker-'+_0x122286});_0x3cd687['writer']['insert'](_0x140f6f,_0x3c8922),_0x3cd687['mapper']['bindElementToMarker'](_0x3c8922,_0x5ec875['markerName']);}_0x5b7f0d||_0x285527||!_0x199b4f||_0x21433b(_0x199b4f);};}class nt extends _0x2f8488{constructor(_0x3a7ade){super(_0x3a7ade);const _0x1d98c7=_0x3a7ade['plugins']['get'](l);this['affectsData']=!0x1,this['listenTo'](_0x1d98c7,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x1d98c7,'change:isEnabled',()=>this['refresh']());}['execute'](){const _0x59a101=this['editor'],_0x24938d=_0x59a101['plugins']['get'](l),_0x347f5d=_0x24938d['isReady']?_0x24938d['diff']['newRevisionId']:null;_0x59a101['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x347f5d);}['refresh'](){const {isReady:_0x26ac5a,isEnabled:_0x54d3a6,repository:_0x43d83a,diff:_0x1b1d9f}=this['editor']['plugins']['get'](l),_0x5520d8=_0x1b1d9f&&_0x43d83a['getLaterVisibleRevision'](_0x1b1d9f['newRevisionId']);this['isEnabled']=_0x26ac5a&&_0x54d3a6&&Boolean(_0x5520d8);}}class ot extends _0x2f8488{['_step'];constructor(_0x519a0b,{direction:_0x21e67d}){super(_0x519a0b);const _0x10f9b4=_0x519a0b['plugins']['get'](l);this['affectsData']=!0x1,this['_step']='forward'===_0x21e67d?0x1:-0x1,this['listenTo'](_0x10f9b4,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x10f9b4,'change:isEnabled',()=>this['refresh']()),this['listenTo'](_0x10f9b4,'change:activeChange',()=>this['refresh']());}['execute'](){const _0x5b151c=this['editor'],_0x382803=_0x5b151c['plugins']['get'](l),{isNavigationMode:_0x5aab20,currentChangeNumber:_0x317d38}=_0x382803;let _0x3cd235;if(_0x382803['activeChange']=_0x5aab20?_0x382803['diff']['changes']['get'](_0x317d38+this['_step']):_0x382803['diff']['changes']['first'],_0x382803['activeChange']['data']['isOnRoot'])_0x3cd235=_0x5b151c['editing']['view']['getDomRoot'](_0x382803['activeChange']['rootName']);else{const _0x352233=_0x5b151c['model']['markers']['get']('revision:'+_0x382803['activeChange']['id']);_0x3cd235=_0x2e5cd7(_0x5b151c['editing'],_0x352233);}_0xb54d25({'target':_0x3cd235,'viewportOffset':0x28});}['refresh'](){const {isNavigationMode:_0x37cb17,currentChangeNumber:_0x541202,numberOfChanges:_0x5a6b3d,isReady:_0x4c8dfc,isEnabled:_0x329f3d}=this['editor']['plugins']['get'](l);this['isEnabled']=!!(_0x329f3d&&_0x4c8dfc&&_0x5a6b3d)&&(!_0x37cb17||(0x1===this['_step']?_0x541202<_0x5a6b3d-0x1:_0x541202>0x0));}}class pi extends _0x6fccc7{constructor(_0x35dbb3){super(_0x35dbb3);const _0x347ff1=this['bindTemplate'],_0xc432e6=new _0x7ab364(_0x35dbb3),_0x396834=new _0x7ab364(_0x35dbb3);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',(_0x26d3f3,_0x4fae6e)=>_0x26d3f3&&_0x4fae6e>0x0),this['bind']('_statusText')['to'](this,'isReady',this,'currentChangeNumber',this,'numberOfChanges',this,'isNavigationMode',(_0x4059ad,_0x1b7043,_0x2ccca6,_0x307467)=>{if(!_0x4059ad)return R(_0x35dbb3,'Loading...');if(!_0x2ccca6)return R(_0x35dbb3,'No\x20changes');const _0x253f0f=R(_0x35dbb3,'NUMBER_OF_CHANGES',_0x2ccca6);return _0x307467?R(_0x35dbb3,'X_OF_Y_CHANGES',[_0x1b7043+0x1,_0x2ccca6]):_0x253f0f;}),_0xc432e6['set']({'label':R(_0x35dbb3,'Show\x20previous\x20change'),'tooltip':!0x0,'icon':_0xcdae82}),_0x396834['set']({'label':R(_0x35dbb3,'Show\x20next\x20change'),'tooltip':!0x0,'icon':_0x4cdf29}),_0xc432e6['bind']('isEnabled')['to'](this,'isBackwardNavigationEnabled'),_0x396834['bind']('isEnabled')['to'](this,'isForwardNavigationEnabled'),_0xc432e6['on']('execute',()=>this['fire']('execute','backward')),_0x396834['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',_0x347ff1['if']('_isStatusLabelVisible','ck-hidden',_0x40033a=>!_0x40033a)]},'children':[{'text':_0x347ff1['to']('isNavigationMode',_0x3dbb35=>_0x3dbb35?R(_0x35dbb3,'EDIT_X_OF_Y_REVISIONS')+':\x20':R(_0x35dbb3,'Total')+':\x20')}]},{'text':_0x347ff1['to']('_statusText')}]},new _0x5c0ae1(),{'tag':'div','attributes':{'class':['ck-revision-history-ui__changes-navigation__navigation']},'children':[_0xc432e6,_0x396834]}]});}}const ge='ck-editor__editable__loading-overlay';class fi extends _0x278e34{static get['pluginName'](){return'RevisionViewerLoadingOverlay';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['show'](){const _0x4ab4f7=this['editor']['editing']['view'];_0x4ab4f7['change'](_0x3291b4=>{for(const _0xbbe3a of _0x4ab4f7['document']['roots'])_0x3291b4['addClass'](ge,_0xbbe3a);});}['hide'](){const _0x24c85e=this['editor']['editing']['view'];_0x24c85e['change'](_0x4a4531=>{for(const _0xea38af of _0x24c85e['document']['roots'])_0x4a4531['removeClass'](ge,_0xea38af);});}}class u extends _0x278e34{static get['pluginName'](){return'RevisionViewerUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[l,fi];}['init'](){const _0x2d4ac5=this['editor'],_0x15ab37=_0x2d4ac5['plugins']['get'](l),_0x36671b=_0x2d4ac5['plugins']['get'](fi);_0x2d4ac5['ui']['componentFactory']['add']('exitToEditing',_0x54a2f9=>{const _0x4383d8=new _0x7ab364(_0x54a2f9);return _0x4383d8['set']({'label':R(_0x54a2f9,'Back\x20to\x20editing'),'icon':_0x5456c4,'withText':!0x0,'tooltip':!0x0,'class':'ck-revision-history-ui__back-to-editing'}),this['listenTo'](_0x4383d8,'execute',()=>{_0x2d4ac5['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}),_0x4383d8;}),_0x2d4ac5['ui']['componentFactory']['add']('restoreRevision',_0x10ff2f=>{const _0x208bb1=new _0x7ab364(_0x10ff2f);return _0x208bb1['set']({'label':R(_0x10ff2f,'Restore\x20this\x20revision'),'withText':!0x0,'tooltip':!0x0}),_0x208bb1['bind']('isEnabled')['to'](_0x2d4ac5['commands']['get']('restoreRevision')),this['listenTo'](_0x208bb1,'execute',()=>_0x2d4ac5['execute']('restoreRevision')),_0x208bb1;}),_0x2d4ac5['ui']['componentFactory']['add']('changesNavigation',_0x4a8654=>{const _0x3eab3d=new pi(_0x4a8654),_0x38c5e8=_0x2d4ac5['commands']['get']('showPreviousChange'),_0x2bfc5f=_0x2d4ac5['commands']['get']('showNextChange');return _0x3eab3d['bind']('isBackwardNavigationEnabled')['to'](_0x38c5e8,'isEnabled'),_0x3eab3d['bind']('isForwardNavigationEnabled')['to'](_0x2bfc5f,'isEnabled'),_0x3eab3d['bind']('isReady','currentChangeNumber','numberOfChanges','isNavigationMode')['to'](_0x15ab37),this['listenTo'](_0x3eab3d,'execute',(_0x1bbfb7,_0x1e084a)=>{_0x2d4ac5['execute']('forward'===_0x1e084a?'showNextChange':'showPreviousChange');}),_0x3eab3d;}),_0x36671b['show'](),_0x15ab37['on']('change:isReady',(_0x4eeb9b,_0x4ee00b,_0x5e643a)=>{_0x5e643a?_0x36671b['hide']():_0x36671b['show']();});}}class li extends ti{['_resizeObserver']=null;constructor(_0xb6b525,_0x4db335){super(_0xb6b525,_0x4db335);const _0x20b1dd=this['bindTemplate'];this['set']({'label':R(_0xb6b525,'Revision\x20name'),'_tooltipString':''}),this['fieldView']['placeholder']=R(_0xb6b525,'Enter\x20the\x20revision\x20name'),this['extendTemplate']({'tag':'span','attributes':{'class':['ck-revision-history-sidebar__revision-name'],'data-cke-tooltip-text':_0x20b1dd['to']('_tooltipString'),'data-cke-tooltip-position':'s','data-cke-tooltip-class':'ck-tooltip_multi-line'}});}['render'](){super['render'](),this['_resizeObserver']=new et(this['fieldView']['element'],()=>this['_updateTooltipText']()),this['listenTo'](this['fieldView'],'input',()=>this['_updateTooltipText']());}['destroy'](){super['destroy'](),this['_resizeObserver']&&this['_resizeObserver']['destroy']();}['_updateTooltipText'](){const _0x5202c0=this['fieldView']['element'];this['_tooltipString']=_0x5202c0['scrollWidth']>_0x5202c0['clientWidth']&&_0x5202c0['value']||'';}}class vi extends _0x6fccc7{constructor(_0x1ebc5d,_0x4120da,_0x5a9d5c){super(_0x1ebc5d);const _0x191db3=new _0x2d07b2();_0x191db3['set']({'content':_0x2aad10,'viewBox':'0\x200\x2011\x2010'});const _0x1ba140=['ck','ck-revision-history-sidebar__revision-author'];_0x5a9d5c&&_0x1ba140['push']('ck-revision-history-sidebar__revision-author_creator');const _0x30afda=[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision-author__name'],'title':R(_0x1ebc5d,_0x5a9d5c?'Revision\x20creator':'Revision\x20author')},'children':[_0x191db3,_0x4120da['name']]}];this['setTemplate']({'tag':'li','attributes':{'class':_0x1ba140},'children':_0x30afda});}}function mi(_0x24967e,_0x6501e){const _0x4ee764=_0x24967e['bindTemplate'],_0x5db953=_0x24967e['locale'],_0x5057c6=_0x135259(_0x5db953);_0x5057c6['panelPosition']='sw';const _0x581eca=function(_0x18a40c,_0x440e32){const _0x49311d=function(_0x37a11f,_0x12629b){const _0x48b628=_0x37a11f['locale'],_0x2ddd5f={'Compare\x20against\x20selected':R(_0x48b628,'Compare\x20against\x20selected'),'Name\x20this\x20revision':R(_0x48b628,'Name\x20this\x20revision'),'Restore\x20this\x20revision':R(_0x48b628,'Restore\x20this\x20revision')};return _0x12629b['map'](_0x15f172=>{const _0x1ea95b=_0x2ddd5f[_0x15f172['name']];return _0x1ea95b&&_0x1ea95b!==_0x15f172['name']&&(_0x15f172['name']=_0x1ea95b),_0x15f172;});}(_0x18a40c,_0x440e32),_0x55a62d=new _0x42f581();for(const _0x1b8dcf of _0x49311d){const _0x33a21c={'type':'button','model':new to({'label':_0x1b8dcf['name'],'class':_0x1b8dcf['class'],'withText':!0x0,'role':'menuitem','_action':_0x1b8dcf['action']})};_0x33a21c['model']['bind']('isEnabled')['to'](_0x18a40c,'isActionsDropdownOpen',_0x28676f=>'function'!=typeof _0x1b8dcf['isEnabled']||(!_0x28676f||_0x1b8dcf['isEnabled'](_0x18a40c))),_0x55a62d['add'](_0x33a21c);}return _0x55a62d;}(_0x24967e,_0x6501e);return _0x24967e['bind']('isActionsDropdownOpen')['to'](_0x5057c6,'isOpen'),_0x5057c6['buttonView']['set']({'label':R(_0x5db953,'Show\x20more\x20items'),'tooltip':!0x0,'tooltipPosition':'sw','icon':_0x1ce8ff}),_0x5057c6['extendTemplate']({'attributes':{'class':['ck-revision-history-sidebar__revision__actions',_0x4ee764['if']('isActionsDropdownOpen','ck-on')]},'on':{'click':_0x4ee764['to'](_0x30b633=>_0x30b633['stopPropagation']())}}),_0x5057c6['on']('execute',_0x2654cd=>{_0x24967e['isReady']&&'function'==typeof _0x2654cd['source']['_action']&&_0x2654cd['source']['_action'](_0x24967e);}),_0x4cc072(_0x5057c6,_0x581eca,{'role':'menu'}),_0x5057c6['listenTo'](_0x24967e,'change:isActionsDropdownOpen',(_0x23e736,_0x129e44,_0x119dd4)=>{if(_0x119dd4)for(const _0x115b00 of _0x5057c6['listView']['items']){const _0x294690=_0x115b00['children']['first'],_0x2975b9=_0x6501e['find'](_0x582403=>_0x582403['action']===_0x294690['_action'])['isVisible'];_0x115b00['isVisible']=void 0x0===_0x2975b9||_0x2975b9(_0x24967e);}}),_0x5057c6;}class ki extends/* #__PURE__ -- @preserve */
|
|
27
|
-
|
|
23
|
+
import{ObservableMixin as _0x4f3d81,uid as _0x1c1c29,Collection as _0x485594,logWarning as _0x4a2031,FocusTracker as _0x2db1ce,KeystrokeHandler as _0x5699cc,scrollViewportToShowTarget as _0x234f22,ResizeObserver as ot,ElementReplacer as it,CKEditorError as _0x308bd1}from'@ckeditor/ckeditor5-utils/dist/index.js';import{cloneDeep as _0x5b681f,set as _0x232aee,unset as _0x2051b7,isEqual as _0x480b44}from'es-toolkit/compat';import{Plugin as _0x3daf77,PendingActions as _0x485562,Command as _0x439955,ElementApiMixin as _0x3c1de6,Editor as _0x39d64c}from'@ckeditor/ckeditor5-core/dist/index.js';import{Users as _0x3c3d4d,getMarkerDomElement as _0x4aa28c,ConfirmMixin as _0x5d1b3d,sanitizeEditorConfig as _0x28a60b}from'ckeditor5-collaboration/dist/index.js';import{ViewContainerElement as _0x5310ca,ViewAttributeElement as _0x521fc7,ViewEmptyElement as _0x27d05e,ViewRawElement as _0x99885e,ViewUIElement as _0x7901b6,ViewDocumentFragment as _0x225429,ViewText as _0x5af1b3,ViewElement as _0x261aec,ModelElement as _0x2d434f,ModelRange as _0x36900d,ModelPosition as _0xb2d03b,ModelDocumentFragment as _0x5dcd6c,ModelText as _0x41b5b5}from'@ckeditor/ckeditor5-engine/dist/index.js';import{IconHistory as _0x11f60f,IconChevronUp as _0x5b0108,IconChevronDown as _0x24f5ef,IconUndo as _0xc406e8,IconUser as _0x5132bd,IconThreeVerticalDots as _0x25fb16}from'@ckeditor/ckeditor5-icons/dist/index.js';import{CssTransitionDisablerMixin as _0x567c82,View as _0x2027a1,submitHandler as _0x23e9a7,LabeledFieldView as et,createLabeledInputText as ti,createDropdown as _0x261f45,ListView as _0x1da0da,ListItemView as _0x37e66c,ButtonView as _0x304609,MenuBarMenuView as _0x14903e,MenuBarMenuListView as _0x16d90e,MenuBarMenuListItemView as _0x288c51,MenuBarMenuListItemButtonView as _0x4391ff,ContextualBalloon as _0x159e16,ToolbarSeparatorView as _0x45456d,IconView as _0x4e4b3c,addListToDropdown as _0x242355,UIModel as to,EditorUI as tt,normalizeToolbarConfig as st,BoxedEditorUIView as _0xedbfd4,StickyPanelView as _0x19738f,ToolbarView as _0x2094c1,InlineEditableUIView as te}from'@ckeditor/ckeditor5-ui/dist/index.js';import{DateTime as _0x4db10e}from'luxon';class I extends/* #__PURE__ -- @preserve */
|
|
24
|
+
_0x4f3d81(){['id'];['creator'];['authors'];['diffData'];['toVersion'];['fromVersion'];['model'];constructor(_0x31126f){super(),this['id']=_0x31126f['id']||_0x1c1c29(),this['creator']=_0x31126f['creator']||null,this['authors']=_0x31126f['authors']||[],this['diffData']=_0x31126f['diffData']||null,this['toVersion']=_0x31126f['toVersion']||0x0,this['fromVersion']=_0x31126f['fromVersion']||0x0,this['set']('name',_0x31126f['name']||''),this['set']('createdAt',_0x31126f['createdAt']||new Date()),this['set']('attributes',_0x31126f['attributes']||{});}['setName'](_0x164993){this['_update']({'name':_0x164993});}['setAttribute'](_0x3459d5,_0x88cdec){const _0x2290eb=_0x5b681f(this['attributes']);_0x232aee(_0x2290eb,_0x3459d5,_0x88cdec),this['_update']({'attributes':_0x2290eb});}['removeAttribute'](_0x40b2d2){const _0x1bea57=_0x5b681f(this['attributes']);_0x2051b7(_0x1bea57,_0x40b2d2),this['_update']({'attributes':_0x1bea57});}['_update'](_0x2ef7a8,_0x5cb783=!0x1){let _0x133227=!0x1;const _0x364ed0={'id':this['id']},_0x70182f=['name','createdAt','diffData','authors','attributes','toVersion','fromVersion','creatorId'];for(const _0x6510e0 of _0x70182f){const _0x194ca2=_0x2ef7a8[_0x6510e0];void 0x0!==_0x194ca2&&_0x194ca2!==this[_0x6510e0]&&(this[_0x6510e0]=_0x194ca2,_0x364ed0[_0x6510e0]=_0x194ca2,_0x133227=!0x0);}_0x133227&&(_0x364ed0['authors']&&(_0x364ed0['authorsIds']=_0x364ed0['authors']['map'](_0x35fc2f=>_0x35fc2f['id']),delete _0x364ed0['authors']),this['fire']('_update',_0x364ed0,_0x5cb783));}['toJSON'](){return{'id':this['id'],'name':this['name'],'creatorId':this['creator']?this['creator']['id']:null,'authorsIds':this['authors']['map'](_0x1c186a=>_0x1c186a['id']),'diffData':this['diffData'],'createdAt':this['createdAt'],'attributes':this['attributes'],'fromVersion':this['fromVersion'],'toVersion':this['toVersion']};}}class S extends _0x3daf77{['_revisions'];static get['requires'](){return[_0x3c3d4d];}static get['pluginName'](){return'RevisionsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['length'](){return this['_revisions']['length'];}constructor(_0x51ffe4){super(_0x51ffe4),this['_revisions']=new _0x485594();}['afterInit'](){!async function(_0x3a39ea){const _0x441afd=_0x482353([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]),_0x29fed7=0xeb829,_0x29fc43=0x7374585f,_0x2cc3df=0x73732b77^_0x29fc43,_0x12b164=window[_0x482353([0x44,0x61,0x74,0x65])][_0x482353([0x6e,0x6f,0x77])](),_0x19c869=_0x3a39ea[_0x482353([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x5d148d=new window[(_0x482353([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x3c40ea=>{_0x19c869[_0x482353([0x6f,0x6e,0x63,0x65])](_0x482353([0x72,0x65,0x61,0x64,0x79]),_0x3c40ea);}),_0x2b207f={[_0x482353([0x6b,0x74,0x79])]:_0x482353([0x45,0x43]),[_0x482353([0x75,0x73,0x65])]:_0x482353([0x73,0x69,0x67]),[_0x482353([0x63,0x72,0x76])]:_0x482353([0x50,0x2d,0x32,0x35,0x36]),[_0x482353([0x78])]:_0x482353([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]),[_0x482353([0x79])]:_0x482353([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]),[_0x482353([0x61,0x6c,0x67])]:_0x482353([0x45,0x53,0x32,0x35,0x36])},_0x9a7239=_0x19c869[_0x482353([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x482353([0x67,0x65,0x74])](_0x482353([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x13b21d(){let _0x502062,_0x3894f9=null,_0x5c4ed1=null;try{if(_0x9a7239==_0x482353([0x47,0x50,0x4c]))return _0x482353([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x502062=_0x35529a(),!_0x502062)return _0x482353([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x502062[_0x482353([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x5c4ed1=_0x2e3b14(_0x502062[_0x482353([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x502062[_0x482353([0x6a,0x74,0x69])])),await _0x4fbcb9()?_0xe64809()?_0x1f69be()?_0x482353([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x36f38b()?(_0x502062[_0x482353([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x482353([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x3894f9=_0x304a57(_0x482353([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x502062[_0x482353([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x482353([0x74,0x72,0x69,0x61,0x6c])&&(_0x3894f9=_0x304a57(_0x482353([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),await _0x39d1ee()):_0x482353([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x482353([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x482353([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch{return _0x482353([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x1f69be(){const _0x31d216=[_0x482353([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x482353([0x74,0x72,0x69,0x61,0x6c])][_0x482353([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x502062[_0x482353([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x12b164/0x3e8:0xe10*_0x2cc3df;return _0x502062[_0x482353([0x65,0x78,0x70])]<_0x31d216;}function _0xe64809(){const _0x3c07ca=_0x502062[_0x482353([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x3c07ca)return!0x1;if(_0x3c07ca[_0x482353([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x482353([0x2a])))return!0x0;if(_0x3c07ca[_0x482353([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x482353([0x52,0x48])))return!0x0;if(_0x3c07ca[_0x482353([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x482353([0x52,0x52,0x48]))){if(_0x25bac1())return!0x0;if(_0x4b3618()||_0x482569())return!0x0;}return!0x1;}function _0x36f38b(){const _0x1ed9ea=_0x502062[_0x482353([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x1ed9ea||0x0==_0x1ed9ea[_0x482353([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x127aa0}=new URL(window[_0x482353([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x1ed9ea[_0x482353([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x127aa0))return!0x0;const _0x7bf686=_0x127aa0[_0x482353([0x73,0x70,0x6c,0x69,0x74])](_0x482353([0x2e]));return _0x1ed9ea[_0x482353([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x369b9e=>_0x369b9e[_0x482353([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x482353([0x2a])))[_0x482353([0x6d,0x61,0x70])](_0x262084=>_0x262084[_0x482353([0x73,0x70,0x6c,0x69,0x74])](_0x482353([0x2e])))[_0x482353([0x66,0x69,0x6c,0x74,0x65,0x72])](_0xd8c8cd=>_0xd8c8cd[_0x482353([0x6c,0x65,0x6e,0x67,0x74,0x68])]<=_0x7bf686[_0x482353([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x482353([0x6d,0x61,0x70])](_0x47e4ec=>Array(_0x7bf686[_0x482353([0x6c,0x65,0x6e,0x67,0x74,0x68])]-_0x47e4ec[_0x482353([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x482353([0x66,0x69,0x6c,0x6c])](_0x47e4ec[0x0]===_0x482353([0x2a])?_0x482353([0x2a]):'')[_0x482353([0x63,0x6f,0x6e,0x63,0x61,0x74])](_0x47e4ec))[_0x482353([0x73,0x6f,0x6d,0x65])](_0x5bd1ab=>_0x7bf686[_0x482353([0x65,0x76,0x65,0x72,0x79])]((_0x442c23,_0x446da4)=>_0x5bd1ab[_0x446da4]===_0x442c23||_0x5bd1ab[_0x446da4]===_0x482353([0x2a])));}function _0x39d1ee(){return _0x3894f9&&_0x5c4ed1?new window[(_0x482353([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x48d707,_0x1b9f99)=>{_0x3894f9[_0x482353([0x74,0x68,0x65,0x6e])](_0x48d707,_0x1b9f99),_0x5c4ed1[_0x482353([0x74,0x68,0x65,0x6e])](_0x16ccbe=>{_0x16ccbe!=_0x482353([0x56,0x61,0x6c,0x69,0x64])&&_0x48d707(_0x16ccbe);},_0x1b9f99);}):_0x3894f9||_0x5c4ed1||_0x482353([0x56,0x61,0x6c,0x69,0x64]);}}function _0x2e3b14(_0x315f13,_0x5a2569){return new window[(_0x482353([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x304835=>{if(_0x114ced())return _0x304835(_0x482353([0x56,0x61,0x6c,0x69,0x64]));_0xfba3cf(),_0x19c869[_0x482353([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x482353([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x35d897=!0x1;const _0x442b38=_0x1c1c29();function _0x1c45a5(_0x484e3d){return!!_0x484e3d&&(typeof _0x484e3d===_0x482353([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x484e3d===_0x482353([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x484e3d[_0x482353([0x74,0x68,0x65,0x6e])]===_0x482353([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x484e3d[_0x482353([0x63,0x61,0x74,0x63,0x68])]===_0x482353([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x34badb(_0x38c760){_0x29a617(_0x38c760)[_0x482353([0x74,0x68,0x65,0x6e])](_0x2e8ed3=>{if(!_0x2e8ed3||_0x2e8ed3[_0x482353([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x482353([0x6f,0x6b]))return _0x482353([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x309308(_0x57feb8(_0x442b38+_0x5a2569))!=_0x2e8ed3[_0x482353([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x482353([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x482353([0x56,0x61,0x6c,0x69,0x64]);})[_0x482353([0x74,0x68,0x65,0x6e])](_0x4704c5=>(_0x143b69(),_0x4704c5),()=>{const _0x515999=_0x273e0b();return null==_0x515999?(_0x143b69(),_0x482353([0x56,0x61,0x6c,0x69,0x64])):_0x482353(_0x12b164-_0x515999>(0x5778dc5f^_0x29fc43)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x482353([0x74,0x68,0x65,0x6e])](_0x304835)[_0x482353([0x63,0x61,0x74,0x63,0x68])](()=>{_0x304835(_0x482353([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x31444d=0x7342b6df^_0x29fc43;function _0x143b69(){const _0x44b6ad=_0x482353([0x6c,0x6c,0x63,0x74,0x2d])+_0x309308(_0x57feb8(_0x315f13)),_0x2ae238=_0x4e6ed8(_0x309308(window[_0x482353([0x4d,0x61,0x74,0x68])][_0x482353([0x63,0x65,0x69,0x6c])](_0x12b164/_0x31444d)));window[_0x482353([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x482353([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x44b6ad,_0x2ae238);}function _0x273e0b(){const _0x5621e7=_0x482353([0x6c,0x6c,0x63,0x74,0x2d])+_0x309308(_0x57feb8(_0x315f13)),_0x2a807e=window[_0x482353([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x482353([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x5621e7);return _0x2a807e?window[_0x482353([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x4e6ed8(_0x2a807e),0x10)*_0x31444d:null;}function _0x29a617(_0x103def){return new window[(_0x482353([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x2038f0,_0x2c0909)=>{_0x103def[_0x482353([0x74,0x68,0x65,0x6e])](_0x2038f0,_0x2c0909),window[_0x482353([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x2c0909,0x73758c9f^_0x29fc43);});}}_0x19c869[_0x482353([0x6f,0x6e])](_0x482353([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x1cdd3f,_0x4a13a8)=>{if(_0x4a13a8[0x0]!=_0x315f13)return _0x304835(_0x482353([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x4a13a8[0x1]={..._0x4a13a8[0x1],[_0x482353([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x442b38};},{[_0x482353([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x482353([0x68,0x69,0x67,0x68])}),_0x19c869[_0x482353([0x6f,0x6e])](_0x482353([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x3ca50c=>{_0x1c45a5(_0x3ca50c[_0x482353([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x35d897=!0x0,_0x34badb(_0x3ca50c[_0x482353([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x482353([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x482353([0x6c,0x6f,0x77])}),_0x5d148d[_0x482353([0x74,0x68,0x65,0x6e])](()=>{_0x35d897||_0x304835(_0x482353([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x114ced(){return _0x19c869[_0x482353([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x482353([0x76,0x69,0x65,0x77])][_0x482353([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x482353([0x61,0x75,0x74,0x6f]);}function _0xfba3cf(){_0x19c869[_0x482353([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x482353([0x76,0x69,0x65,0x77])][_0x482353([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x482353([0x61,0x75,0x74,0x6f]);}}function _0x304a57(_0x42cde){const _0x50779e=[new window[(_0x482353([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x23c92a=>setTimeout(_0x23c92a,0x737d6693^_0x29fc43)),_0x5d148d[_0x482353([0x74,0x68,0x65,0x6e])](()=>new window[(_0x482353([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x2a28d9=>{const _0x152058=0x73745858^_0x29fc43,_0x23674a=_0x3a39ea[_0x482353([0x5f,0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x73])];function _0xf21050(){_0x23674a[_0x482353([0x6c,0x65,0x6e,0x67,0x74,0x68])]>=_0x152058&&_0x2a28d9();}_0xf21050(),_0x23674a[_0x482353([0x6f,0x6e])](_0x482353([0x61,0x64,0x64]),_0xf21050);})),new window[(_0x482353([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x110d62=>{function _0x4a8c6b(){for(const _0x3968f9 in window)if(window[_0x482353([0x4e,0x75,0x6d,0x62,0x65,0x72])]['isNaN'](window[_0x482353([0x4e,0x75,0x6d,0x62,0x65,0x72])](_0x3968f9))&&window[_0x3968f9]==_0x29fed7)return _0x110d62();_0x19c869[_0x482353([0x73,0x74,0x61,0x74,0x65])]!=_0x482353([0x64,0x65,0x73,0x74,0x72,0x6f,0x79,0x65,0x64])&&window[_0x482353([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x4a8c6b,0x73744bd7^_0x29fc43);}_0x2b69e3(_0x482353([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))&&_0x4a8c6b();})];return window[_0x482353([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x482353([0x72,0x61,0x63,0x65])](_0x50779e)[_0x482353([0x74,0x68,0x65,0x6e])](()=>_0x42cde);}async function _0x25f027(){if(await _0x5d148d,_0x2b69e3(_0x482353([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))){const _0x3daa31=_0x3a39ea[_0x482353([0x67,0x65,0x74,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](0x0),_0x5a1860=_0x3a39ea[_0x482353([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])](_0x3daa31[_0x482353([0x69,0x64])]),_0x343974=_0x3d3de1(_0x482353([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]));return await _0x343974[_0x482353([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])](_0x3daa31['id'],_0x5a1860?_0x5a1860['id']:null,!0x0),_0x343974[_0x482353([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x482353([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x343974[_0x482353([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x343974[_0x482353([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])]=_0x201f4e,void(_0x343974[_0x482353([0x5f,0x67,0x65,0x74,0x44,0x69,0x66,0x66])]=_0x201f4e);}if(_0x2b69e3(_0x482353([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]))){const _0x1badaf=_0x3d3de1(_0x482353([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]));_0x1badaf[_0x482353([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x482353([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x1badaf[_0x482353([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x1badaf[_0x482353([0x75,0x70,0x64,0x61,0x74,0x65])]=_0x201f4e,_0x1badaf[_0x482353([0x73,0x61,0x76,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])]=_0x201f4e;}_0x19c869[_0x482353([0x6d,0x6f,0x64,0x65,0x6c])][_0x482353([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x201f4e,_0x19c869[_0x482353([0x6d,0x6f,0x64,0x65,0x6c])][_0x482353([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x201f4e,_0x19c869[_0x482353([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x482353([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x25bac1(){return _0x2b69e3(_0x482353([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x3d3de1(_0x482353([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x482353([0x73,0x74,0x61,0x74,0x65])]==_0x482353([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x4b3618(){return _0x2b69e3(_0x482353([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 _0x482569(){return _0x2b69e3(_0x482353([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0xa19b70(_0x543d56){const _0x240fb0=_0x5af0fe();_0x19c869[_0x240fb0]=_0x482353([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])+_0x543d56,_0x543d56[_0x482353([0x65,0x6e,0x64,0x73,0x57,0x69,0x74,0x68])](_0x482353([0x4c,0x69,0x6d,0x69,0x74]))&&(window[_0x5af0fe()]=_0x29fed7),_0x543d56!=_0x482353([0x56,0x61,0x6c,0x69,0x64])&&_0x25f027();}function _0x5af0fe(){const _0x1970c4=window[_0x482353([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x482353([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x482353([0x6e,0x6f,0x77])]())[_0x482353([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x482353([0x2e]),'');let _0x5f20e9=_0x482353([0x73]);for(let _0x43e451=0x0;_0x43e451<_0x1970c4[_0x482353([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x43e451+=0x2){let _0x2968ae=window[_0x482353([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x1970c4[_0x482353([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x43e451,_0x43e451+0x2));_0x2968ae>=_0x441afd[_0x482353([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x2968ae-=_0x441afd[_0x482353([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x5f20e9+=_0x441afd[_0x2968ae];}return _0x5f20e9;}function _0x35529a(){const _0x31caee=_0x9a7239[_0x482353([0x73,0x70,0x6c,0x69,0x74])](_0x482353([0x2e]));if(0x3!=_0x31caee[_0x482353([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x3c2400(_0x31caee[0x1]);function _0x3c2400(_0x3a2210){const _0x2a2938=_0x3f02e1(_0x3a2210);return _0x2a2938&&_0x53d1d6()?_0x2a2938:null;function _0x53d1d6(){const _0x4aa5ef=_0x2a2938[_0x482353([0x6a,0x74,0x69])],_0x4e7165=window[_0x482353([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x4aa5ef[_0x482353([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x4aa5ef[_0x482353([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x290002={..._0x2a2938,[_0x482353([0x6a,0x74,0x69])]:_0x4aa5ef[_0x482353([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x4aa5ef[_0x482353([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x290002[_0x482353([0x76,0x63])],_0x57feb8(_0x290002)==_0x4e7165;}}}async function _0x4fbcb9(){let _0x1d3288=!0x0;try{const _0x15a470=_0x9a7239[_0x482353([0x73,0x70,0x6c,0x69,0x74])](_0x482353([0x2e])),[_0x5a5954,_0x5c1d49,_0x1fdb2a]=_0x15a470;return _0x37c21d(_0x5a5954),await _0x44eca9(_0x5a5954,_0x5c1d49,_0x1fdb2a),_0x1d3288;}catch{return!0x1;}function _0x37c21d(_0x320f28){const _0x2216f9=_0x3f02e1(_0x320f28);_0x2216f9&&_0x2216f9[_0x482353([0x61,0x6c,0x67])]==_0x482353([0x45,0x53,0x32,0x35,0x36])||(_0x1d3288=!0x1);}async function _0x44eca9(_0x1ea1b2,_0x3f41f0,_0x505a65){const _0xf6232=window[_0x482353([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x482353([0x66,0x72,0x6f,0x6d])](_0x1ada59(_0x505a65),_0x28fa4c=>_0x28fa4c[_0x482353([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x563485=new window[(_0x482353([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x482353([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x1ea1b2+_0x482353([0x2e])+_0x3f41f0),_0x226c71=window[_0x482353([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x482353([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x226c71)return;const _0x6a41ee=await _0x226c71[_0x482353([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x482353([0x6a,0x77,0x6b]),_0x2b207f,{[_0x482353([0x6e,0x61,0x6d,0x65])]:_0x482353([0x45,0x43,0x44,0x53,0x41]),[_0x482353([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x482353([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x482353([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x226c71[_0x482353([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x482353([0x6e,0x61,0x6d,0x65])]:_0x482353([0x45,0x43,0x44,0x53,0x41]),[_0x482353([0x68,0x61,0x73,0x68])]:{[_0x482353([0x6e,0x61,0x6d,0x65])]:_0x482353([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x6a41ee,_0xf6232,_0x563485)||(_0x1d3288=!0x1);}}function _0x3f02e1(_0x5332a0){return _0x5332a0[_0x482353([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x482353([0x65,0x79]))?JSON[_0x482353([0x70,0x61,0x72,0x73,0x65])](_0x1ada59(_0x5332a0)):null;}function _0x1ada59(_0x3d75d1){return window[_0x482353([0x61,0x74,0x6f,0x62])](_0x3d75d1[_0x482353([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x482353([0x2b]))[_0x482353([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x482353([0x2f])));}function _0x57feb8(_0xcf480f){let _0x286637=0x1505;function _0x37b9d3(_0x32471e){for(let _0x203669=0x0;_0x203669<_0x32471e[_0x482353([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x203669++){const _0x4033c0=_0x32471e[_0x482353([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x203669);_0x286637=(_0x286637<<0x5)+_0x286637+_0x4033c0,_0x286637&=_0x286637;}}function _0x33ee40(_0x28d051){Array[_0x482353([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x28d051)?_0x28d051[_0x482353([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x33ee40):_0x28d051&&typeof _0x28d051==_0x482353([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x482353([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x28d051)[_0x482353([0x73,0x6f,0x72,0x74])]()[_0x482353([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x5d43e6,_0x248361])=>{_0x37b9d3(_0x5d43e6),_0x33ee40(_0x248361);}):_0x37b9d3(window[_0x482353([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x28d051));}return _0x33ee40(_0xcf480f),_0x286637>>>0x0;}function _0x309308(_0x49e843){return _0x49e843[_0x482353([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x482353([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x482353([0x30]));}function _0x4e6ed8(_0x4b8d37){return _0x4b8d37[_0x482353([0x73,0x70,0x6c,0x69,0x74])]('')[_0x482353([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x482353([0x6a,0x6f,0x69,0x6e])]('');}function _0x2b69e3(_0x5110c2){return _0x19c869[_0x482353([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x482353([0x68,0x61,0x73])](_0x5110c2);}function _0x3d3de1(_0xdecd2f){return _0x19c869[_0x482353([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x482353([0x67,0x65,0x74])](_0xdecd2f);}function _0x201f4e(){}function _0x482353(_0x143d06){return _0x143d06['map'](_0xfcaaa4=>String['fromCharCode'](_0xfcaaa4))['join']('');}_0xa19b70(await _0x13b21d());}(this);}['createRevision'](_0x5f174b){const _0x214b73=this['editor']['plugins']['get']('Users');return new I({'id':_0x5f174b['id'],'name':_0x5f174b['name'],'creator':_0x5f174b['creatorId']?_0x214b73['getUser'](_0x5f174b['creatorId']):null,'diffData':_0x5f174b['diffData']||_0x5f174b['data'],'authors':_0x5f174b['authorsIds']['map'](_0x20f059=>_0x214b73['getUser'](_0x20f059)),'createdAt':new Date(_0x5f174b['createdAt']),'attributes':_0x5f174b['attributes'],'fromVersion':_0x5f174b['fromVersion'],'toVersion':_0x5f174b['toVersion']});}['addRevision'](_0x490673,_0x27e84f=0x0){this['_revisions']['add'](_0x490673,_0x27e84f);}['getRevision'](_0x14b93b){return this['_revisions']['get'](_0x14b93b);}['getRevisions'](_0x3ce8db={'toJSON':!0x1}){const _0x321cda=Array['from'](this['_revisions']);return _0x321cda['reverse'](),_0x3ce8db['toJSON']?_0x321cda['map'](_0x2c8f80=>_0x2c8f80['toJSON']()):_0x321cda;}['getIndex'](_0x1f10bd){return this['_revisions']['getIndex'](_0x1f10bd);}['getEarlierVisibleRevision'](_0x1356d7){const [,_0x54b355]=this['getRevisionsIterator'](_0x1356d7,{'direction':'earlier'});return _0x54b355;}['getLaterVisibleRevision'](_0x412a5f){const [,_0x29c007]=this['getRevisionsIterator'](_0x412a5f,{'direction':'later'});return _0x29c007;}['getRevisionsInDiff'](_0x3d272f){const _0x29bb81=[];for(const _0x253ec5 of this['getRevisionsIterator'](_0x3d272f['newRevisionId']))if(_0x29bb81['push'](_0x253ec5),_0x253ec5['id']===_0x3d272f['oldRevisionId'])break;return _0x29bb81;}*['getRevisionsIterator'](_0x267adb,{direction:_0x2c8b2a='earlier',filter:_0x5feb93=()=>!0x0}={}){const _0x3e5b5f='earlier'===_0x2c8b2a?0x1:-0x1;let _0x58c7e2=this['_revisions']['get'](_0x267adb),_0x2be69c=this['getIndex'](_0x58c7e2);for(yield _0x58c7e2;_0x58c7e2;){if(_0x2be69c+=_0x3e5b5f,_0x58c7e2=this['getRevision'](_0x2be69c),!_0x58c7e2)return;_0x5feb93(_0x58c7e2)&&(yield _0x58c7e2);}}}class $ extends _0x3daf77{static get['pluginName'](){return'RevisionHistoryUtils';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['_viewClassToTypeChar']=new Map([[_0x5310ca,'c'],[_0x521fc7,'a'],[_0x27d05e,'e'],[_0x99885e,'r'],[_0x7901b6,'u']]);['_typeCharToViewClass']=new Map([['c',_0x5310ca],['a',_0x521fc7],['e',_0x27d05e],['r',_0x99885e],['u',_0x7901b6]]);async['loadRevisionData'](_0x585124,_0x4a5c26){if(_0x585124['diffData']||!_0x4a5c26)return;const _0x464430=this['editor']['config']['get']('collaboration.channelId'),_0x4712d9=await _0x4a5c26['getRevision']({'channelId':_0x464430,'revisionId':_0x585124['id']});_0x585124['diffData']=_0x4712d9['diffData'];}['getRevisionDocumentData'](_0x934c50){const _0x5be2c9={};for(const _0x1a724d in _0x934c50['diffData']){if(_0x934c50['diffData'][_0x1a724d]['attachChange']&&!_0x934c50['diffData'][_0x1a724d]['attachChange']['isAttached'])continue;const _0x5c1f5c=this['_removeRevisionMarkers'](JSON['parse'](_0x934c50['diffData'][_0x1a724d]['insertions'])),_0x333300=this['editor']['editing']['view']['document'],_0x15873f=new _0x225429(_0x333300,_0x5c1f5c['map'](_0x1e1d55=>this['_getViewFromDiffObj'](_0x1e1d55,!0x1)));this['editor']['data']['processor']['useFillerType']('marked'),_0x5be2c9[_0x1a724d]=this['editor']['data']['processor']['toData'](_0x15873f),this['editor']['data']['processor']['useFillerType']('default');}return _0x5be2c9;}['getRevisionRootsAttributes'](_0x31bcae){const _0x2d8fa7={};for(const _0x165a2e in _0x31bcae['diffData'])_0x31bcae['diffData'][_0x165a2e]['attachChange']&&!_0x31bcae['diffData'][_0x165a2e]['attachChange']['isAttached']||(_0x2d8fa7[_0x165a2e]=_0x31bcae['diffData'][_0x165a2e]['attributesAfter']||{});return _0x2d8fa7;}['_getTypeCharForViewElement'](_0x1efea0){return this['_viewClassToTypeChar']['get'](_0x1efea0['constructor']);}['_getViewFromDiffObj'](_0x5bdbe9,_0x4376ff){const _0x3af97d=this['editor']['editing']['view']['document'];if('string'==typeof _0x5bdbe9)return new _0x5af1b3(_0x3af97d,_0x5bdbe9);{let _0x73905e,_0x20fc0d;_0x20fc0d='u'==_0x5bdbe9['type']||'r'==_0x5bdbe9['type']?[]:_0x5bdbe9['children']['map'](_0x2def3c=>this['_getViewFromDiffObj'](_0x2def3c,_0x4376ff));const _0x96dbe4=this['_typeCharToViewClass']['get'](_0x5bdbe9['type'])||_0x261aec,_0xaa72fb=this['editor']['data']['htmlProcessor']['domConverter'];if(_0x73905e=new _0x96dbe4(_0x3af97d,_0x5bdbe9['name'],_0x5bdbe9['attributes'],_0x20fc0d),'u'==_0x5bdbe9['type']&&_0x5bdbe9['children'][0x0]){const _0x35a832=_0x5bdbe9['children'][0x0];if(_0x73905e['render']=function(_0x4da11b){const _0x5504ae=_0x4da11b['createElement']('div');return _0x5504ae['innerHTML']=_0x35a832,_0x5504ae['childNodes'][0x0];},_0x4376ff){const _0xc2c393=new _0x225429(_0x3af97d);_0xc2c393['_appendChild'](_0x73905e);const _0x55ab61=Array['from'](_0xaa72fb['viewChildrenToDom'](_0xc2c393,{'bind':!0x1})),_0x32c2fd=_0xaa72fb['domDocument']['createElement']('div');_0x32c2fd['append'](..._0x55ab61),_0x73905e=Array['from'](_0xaa72fb['domChildrenToView'](_0x32c2fd))[0x0];}}else{if('r'==_0x5bdbe9['type']&&_0x5bdbe9['children'][0x0]){const _0x524c59=_0x5bdbe9['children'][0x0];if(_0x73905e['render']=function(_0x4be845){_0x4be845['innerHTML']=_0x524c59;},_0x4376ff){const _0x3d44d5=new _0x225429(_0x3af97d);_0x3d44d5['_appendChild'](_0x73905e);const _0x580384=Array['from'](_0xaa72fb['viewChildrenToDom'](_0x3d44d5,{'bind':!0x1})),_0x127adf=_0xaa72fb['domDocument']['createElement']('div');_0x127adf['append'](..._0x580384);const _0x78f397=Array['from'](_0xaa72fb['domChildrenToView'](_0x127adf));_0x78f397['length']>0x1?_0x73905e['_appendChild'](_0x78f397):_0x73905e=_0x78f397[0x0];}}}if(_0x5bdbe9['customProperties']){for(const [_0x44815d,_0xfd382b]of _0x5bdbe9['customProperties'])_0x73905e['_setCustomProperty'](_0x44815d,_0xfd382b);}const _0x3f61df=void 0x0===_0x5bdbe9['fillerOffset']?null:_0x5bdbe9['fillerOffset'];return null!==_0x3f61df&&(_0x73905e['getFillerOffset']=()=>_0x3f61df),_0x73905e;}}['_makeModelFromViewString'](_0x49a55d){const _0x11d655=JSON['parse'](_0x49a55d),_0x7fc4a2=this['editor']['editing']['view']['document'],_0xdffc88=new _0x225429(_0x7fc4a2,_0x11d655['map'](_0x286cc1=>this['_getViewFromDiffObj'](_0x286cc1,!0x0)));return this['editor']['data']['toModel'](_0xdffc88);}['_removeRevisionMarkers'](_0xdb877e){return(_0xdb877e=_0xdb877e['filter'](_0x11a50e=>!_0x11a50e['name']||'revision-start'!==_0x11a50e['name']&&'revision-end'!==_0x11a50e['name']))['forEach'](_0x5bc775=>{'string'!=typeof _0x5bc775&&(_0x5bc775['children']=this['_removeRevisionMarkers'](_0x5bc775['children']),_0x5bc775['attributes']=_0x5bc775['attributes']['filter'](_0x516850=>!_0x516850[0x0]['startsWith']('data-revision-')));}),_0xdb877e;}}function R(_0x349324,_0x2da8fc,_0x107793){const t=_0x349324['t'];switch(_0x2da8fc){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'},_0x107793);case'X_OF_Y_CHANGES':return t({'string':'%0\x20of\x20%1','id':'X_OF_Y_CHANGES'},_0x107793);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 _0x3daf77{['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[_0x3c3d4d,S,$,_0x485562];}constructor(_0x538ddc){super(_0x538ddc),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 _0x131616=_0x1c1c29();this['_source']={'history':this['editor']['model']['document']['history'],'getLatestVersion':()=>Promise['resolve'](this['editor']['model']['document']['version']),'getCurrentRevisionId':()=>_0x131616},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 _0x18cfde=this['repository']['getRevision'](0x0),_0x17bfae=_0x18cfde&&null===_0x18cfde['creator']?_0x18cfde:null;if(this['_continueCurrentRevision']=!!_0x17bfae&&this['editor']['config']['get']('revisionHistory.resumeUnsavedRevision'),this['editor']['plugins']['has']('RealTimeCollaborationClient')){const _0x210bde=this['_source']['getCurrentRevisionId'](),_0x57d899=this['repository']['getRevision'](_0x210bde);if(_0x57d899)this['_startingVersion']=_0x57d899['fromVersion'],this['_continueCurrentRevision']=!0x1;else{const _0x303687=this['_source']['history']['_operations']['find'](_0xe76bd8=>!_0xe76bd8['_isInit']),_0x1cab6b=_0x303687?_0x303687['baseVersion']:this['_source']['history']['version'];_0x18cfde?(_0x18cfde['toVersion']<_0x1cab6b&&_0x18cfde['_update']({'toVersion':_0x1cab6b}),this['_continueCurrentRevision']?(this['_source']['getCurrentRevisionId']=()=>_0x17bfae['id'],this['_startingVersion']=_0x17bfae['fromVersion']):(this['_startingVersion']=_0x18cfde['toVersion'],this['_continueCurrentRevision']=!0x1)):(this['_startingVersion']=_0x1cab6b,this['_continueCurrentRevision']=!0x1);}}else _0x17bfae&&(this['editor']['model']['document']['history']['version']=Math['max'](_0x17bfae['toVersion'],this['editor']['model']['document']['history']['version']),_0x17bfae['fromVersion']===_0x17bfae['toVersion']?(0x0!==_0x17bfae['fromVersion']&&(this['_source']['getCurrentRevisionId']=()=>_0x17bfae['id']),this['_continueCurrentRevision']=!0x1):this['_continueCurrentRevision']&&(this['_source']['getCurrentRevisionId']=()=>_0x17bfae['id'],this['_startingVersion']=_0x17bfae['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',_0x566940=>!_0x566940),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x1948d3=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x4bdd2a;for(const _0x45d427 in _0x1948d3){const _0x390439=_0x45d427,_0x10e696=_0x1948d3[_0x390439];if('revisionHistoryLicenseKeyValid'==_0x10e696||'revisionHistoryLicenseKeyInvalid'==_0x10e696||'revisionHistoryLicenseKeyExpired'==_0x10e696||'revisionHistoryLicenseKeyDomainLimit'==_0x10e696||'revisionHistoryLicenseKeyNotAllowed'==_0x10e696||'revisionHistoryLicenseKeyEvaluationLimit'==_0x10e696||'revisionHistoryLicenseKeyTrialLimit'==_0x10e696||'revisionHistoryLicenseKeyUsageLimit'==_0x10e696){delete _0x1948d3[_0x390439],_0x4bdd2a=_0x10e696,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'revisionHistoryLicenseKeyInvalid'==_0x4bdd2a&&_0x1948d3['_showLicenseError']('invalid'),'revisionHistoryLicenseKeyExpired'==_0x4bdd2a&&_0x1948d3['_showLicenseError']('expired'),'revisionHistoryLicenseKeyDomainLimit'==_0x4bdd2a&&_0x1948d3['_showLicenseError']('domainLimit'),'revisionHistoryLicenseKeyNotAllowed'==_0x4bdd2a&&_0x1948d3['_showLicenseError']('featureNotAllowed','RevisionHistory'),'revisionHistoryLicenseKeyEvaluationLimit'==_0x4bdd2a&&_0x1948d3['_showLicenseError']('evaluationLimit'),'revisionHistoryLicenseKeyTrialLimit'==_0x4bdd2a&&_0x1948d3['_showLicenseError']('trialLimit'),'revisionHistoryLicenseKeyUsageLimit'==_0x4bdd2a&&_0x1948d3['_showLicenseError']('usageLimit');},0x3e8);}async['afterInit'](){if(this['repository']['length']>0x0){const _0x48e7c9=this['repository']['getRevision'](0x0),_0x49319b=await this['getRevisionDocumentData'](_0x48e7c9),_0x399568=await this['getRevisionRootsAttributes'](_0x48e7c9);this['_replaceEditorDataWithRevisionData'](_0x49319b,_0x399568);}}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['setSource'](_0xe7fcc3){this['_source']=_0xe7fcc3;}async['update'](){const _0xb52e0a=await this['_source']['getLatestVersion']();if(_0xb52e0a>this['currentRevision']['toVersion']){await this['_loadState']();const _0x5e1219=this['buildRevisionData']({'revision':this['currentRevision'],'to':_0xb52e0a});_0x5e1219['authors']=_0x5e1219['authorsIds']['map'](_0x3e07a5=>this['editor']['plugins']['get']('Users')['getUser'](_0x3e07a5)),this['currentRevision']['_update'](_0x5e1219);}}async['saveRevision'](_0x50e41f={},_0x4e0455=null){const _0x3c8dee=[];await this['_loadState'](),this['_continueCurrentRevision']=!0x1,_0x4e0455>this['currentRevision']['toVersion']&&(_0x4e0455=null),null===_0x4e0455&&(_0x4e0455=await this['_source']['getLatestVersion']());const _0x14618a=this['_getFromVersion'](_0x4e0455),_0x5efa70=this['buildRevisionData']({'from':_0x14618a,'to':_0x4e0455});if(this['currentRevision']['toVersion']<_0x4e0455){const _0x124904=this['buildRevisionData']({'revision':this['currentRevision'],'from':_0x4e0455,'to':_0x4e0455});_0x124904['authors']=[],_0x124904['authorsIds']=[],_0x124904['id']=this['currentRevision']['id'],this['currentRevision']['_update'](_0x124904,!0x0),delete _0x124904['authors'],_0x3c8dee['push'](_0x124904);}_0x50e41f['creatorId']=this['editor']['plugins']['get']('Users')['me']['id'],_0x50e41f['name']=_0x50e41f['name']||null,_0x50e41f['id']=_0x50e41f['id']||_0x1c1c29(),_0x50e41f={..._0x50e41f,..._0x5efa70};const _0x544547=this['addRevisionData'](_0x50e41f);_0x3c8dee['push'](_0x50e41f);const _0x565968=this['repository']['getIndex'](_0x544547);if(0x0!==_0x565968){const _0x50e446=this['repository']['getRevision'](_0x565968-0x1);if(_0x50e446['fromVersion']!==_0x4e0455){const _0x37d250=this['_revisionDataBuilder']['getData'](_0x4e0455,_0x50e446['toVersion']),_0x48ebc4={'id':_0x50e446['id'],'diffData':_0x37d250['diffData'],'authorsIds':_0x37d250['authorsIds'],'authors':_0x37d250['authorsIds']['map'](_0x262144=>this['editor']['plugins']['get']('Users')['getUser'](_0x262144)),'fromVersion':_0x4e0455};_0x50e446===this['currentRevision']&&(_0x48ebc4['createdAt']=new Date(_0x50e41f['createdAt']['getTime']()+0xa)),_0x50e446['_update'](_0x48ebc4,!0x0),delete _0x48ebc4['authors'],_0x3c8dee['push'](_0x48ebc4);}}if(this['adapter']){for(const _0x16af4d of _0x3c8dee)this['_bufferUpdate'](_0x16af4d['id'],_0x16af4d,!0x0);this['sendBufferedUpdates']();}return _0x544547;}['addRevisionData'](_0x1058be){const _0x10e19c=this['repository']['createRevision'](_0x1058be);return this['adapter']&&_0x10e19c['on']('_update',(_0xe4b782,_0x49fbb6,_0x319496)=>{_0x319496||(this['_bufferUpdate'](_0x49fbb6['id'],_0x49fbb6,!0x0),this['sendBufferedUpdates']());}),this['repository']['addRevision'](_0x10e19c,this['_findInsertionIndex'](_0x10e19c)),_0x10e19c;}async['getRevisionDocumentData'](_0x3b1339){return await this['_utils']['loadRevisionData'](_0x3b1339,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x3b1339);}async['getRevisionRootsAttributes'](_0x2eff3c){return await this['_utils']['loadRevisionData'](_0x2eff3c,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x2eff3c);}['sendBufferedUpdates'](){if(0x0===this['_bufferedUpdates']['size'])return;if(this['_isPendingUpdate'])return;let _0x4362a5=Array['from'](this['_bufferedUpdates']['values']());this['_bufferedUpdates']['clear']();for(let _0x3489a9=0x0;_0x3489a9<_0x4362a5['length'];_0x3489a9++){const _0x24a6d1=_0x4362a5[_0x3489a9];let _0x25da84=!0x1;for(const _0x30e445 of Object['keys'](_0x24a6d1))void 0x0===_0x24a6d1[_0x30e445]?delete _0x24a6d1[_0x30e445]:'id'!==_0x30e445&&(_0x25da84=!0x0);_0x25da84||(_0x4362a5[_0x3489a9]=null);}if(_0x4362a5=_0x4362a5['filter'](_0xd54670=>null!==_0xd54670),!_0x4362a5['length'])return;for(let _0x42dde2=0x0;_0x42dde2<_0x4362a5['length'];_0x42dde2++){const _0x1091cd=_0x4362a5[_0x42dde2];void 0x0!==_0x1091cd['fromVersion']&&void 0x0===_0x1091cd['toVersion']&&(_0x1091cd['toVersion']=this['repository']['getRevision'](_0x1091cd['id'])['toVersion']),void 0x0!==_0x1091cd['toVersion']&&void 0x0===_0x1091cd['fromVersion']&&(_0x1091cd['fromVersion']=this['repository']['getRevision'](_0x1091cd['id'])['fromVersion']);}const _0x1fca3a=this['editor']['config']['get']('collaboration.channelId');this['_isPendingUpdate']=!0x0,this['_addPendingAction'](),this['adapter']['updateRevisions'](_0x4362a5,_0x1fca3a)['finally'](()=>{this['_isPendingUpdate']=!0x1;})['then'](_0x4c9dc0=>{if(_0x4c9dc0){for(const _0x2b93b9 of _0x4c9dc0)this['setRevisionData']({'id':_0x2b93b9['id'],'createdAt':_0x2b93b9['createdAt']});}this['_removePendingAction'](),this['sendBufferedUpdates']();});}['buildRevisionData']({revision:_0x2fbb6e=null,from:_0xb8c144=null,to:_0x24a3c3=null}){_0xb8c144=null!==_0xb8c144?_0xb8c144:_0x2fbb6e['fromVersion'],_0x24a3c3=null!==_0x24a3c3?_0x24a3c3:_0x2fbb6e['toVersion'];const _0x4786a7=this['_revisionDataBuilder']['getData'](_0xb8c144,_0x24a3c3),_0x484ac9={'diffData':_0x4786a7['diffData'],'authorsIds':_0x4786a7['authorsIds'],'fromVersion':_0xb8c144,'toVersion':_0x24a3c3};if(!_0x2fbb6e||_0x24a3c3!==_0x2fbb6e['toVersion']){const _0x1dd267=_0x24a3c3-0x1,_0x53f422=this['_source']['history']['getOperation'](_0x1dd267);_0x484ac9['createdAt']=_0x53f422&&_0x53f422['createdAt']||new Date();}if(this['_loadedStateData']&&_0xb8c144===this['_loadedStateData']['fromVersion']){for(const _0x15d5f0 of this['_loadedStateData']['authors'])_0x484ac9['authorsIds']['includes'](_0x15d5f0['id'])||_0x484ac9['authorsIds']['push'](_0x15d5f0['id']);}return _0x484ac9;}['_bufferUpdate'](_0x11d1e8,_0x356757,_0x405378){if(this['_bufferedUpdates']['has'](_0x11d1e8)){const _0x4f17e9=this['_bufferedUpdates']['get'](_0x11d1e8);_0x356757=_0x405378?{..._0x4f17e9,..._0x356757}:{..._0x356757,..._0x4f17e9};}this['_bufferedUpdates']['set'](_0x11d1e8,_0x356757);}['setRevisionData'](_0x1c21a1){const _0x11df90=this['repository']['getRevision'](_0x1c21a1['id']);if(_0x1c21a1['createdAt']&&(_0x1c21a1['createdAt']=new Date(_0x1c21a1['createdAt'])),_0x1c21a1['authorsIds']){const _0x5a28ed=this['editor']['plugins']['get']('Users');_0x1c21a1['authors']=_0x1c21a1['authorsIds']['map'](_0x25f1ee=>_0x5a28ed['getUser'](_0x25f1ee));}_0x11df90['_update'](_0x1c21a1,!0x0);}['_createInitialRevision'](_0x224521){const _0x388d2b=this['repository']['getRevision'](this['repository']['length']-0x1);if(_0x388d2b)this['_initialRevisionId']=_0x388d2b['id'];else{const _0x4a3e13=!this['editor']['model']['document']['roots']['find'](_0x44f3b9=>this['editor']['model']['hasContent'](_0x44f3b9)),_0x7a257=this['editor']['plugins']['get']('Users')['me']['id'],_0x3d8b9e=R(this['editor']['locale'],_0x4a3e13?'Empty\x20document':'Initial\x20revision');this['_makeRevision']({'from':_0x224521,'to':_0x224521,'id':this['_initialRevisionId'],'name':_0x3d8b9e,'creatorId':_0x7a257});}}['_createCurrentRevision'](_0xb78c44){const _0x2f817e=this['_source']['getCurrentRevisionId']();this['currentRevision']=this['repository']['getRevision'](_0x2f817e),this['currentRevision']||(this['currentRevision']=this['_makeRevision']({'from':_0xb78c44,'to':_0xb78c44,'id':_0x2f817e,'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'](_0xd6d8d4,_0x16ceb0){let _0x24d975=this['editor']['config']['get']('initialData'),_0x1003c1=this['editor']['config']['get']('rootsAttributes');if(void 0x0===_0x24d975){_0x24d975={};for(const _0x38c1e8 of this['editor']['model']['document']['getRootNames']())_0x24d975[_0x38c1e8]='';}if('string'==typeof _0x24d975&&(_0x24d975={'main':_0x24d975}),void 0x0===_0x1003c1){_0x1003c1={};for(const _0x2fe104 of this['editor']['model']['document']['getRootNames']())_0x1003c1[_0x2fe104]={};}let _0x479c57=!0x1;const _0x2bb6ae=Object['keys'](_0x24d975),_0x209e2f=Object['keys'](_0xd6d8d4);for(const _0x30621c of _0x2bb6ae){if(_0x24d975[_0x30621c]!==_0xd6d8d4[_0x30621c]&&''!==_0x24d975[_0x30621c]['trim']()){_0x479c57=!0x0;break;}if(!_0x480b44(_0x1003c1[_0x30621c],_0x16ceb0[_0x30621c])&&Object['keys'](_0x1003c1[_0x30621c])['length']>0x0){_0x479c57=!0x0;break;}}_0x479c57||(_0x479c57=_0x209e2f['some'](_0xce8b91=>!this['editor']['model']['document']['getRoot'](_0xce8b91))),_0x479c57&&_0x4a2031('editor-initial-data-replaced-with-revision-data',{'editorData':_0x24d975,'editorRootsAttributes':_0x1003c1,'revisionData':_0xd6d8d4,'revisionRootsAttributes':_0x16ceb0}),this['editor']['config']['set']('initialData',_0xd6d8d4),this['editor']['config']['set']('rootsAttributes',_0x16ceb0);}['_addPendingAction'](){if(!this['_pendingAction']){const _0x2cc7f3=this['editor']['plugins']['get']('PendingActions');this['_pendingAction']=_0x2cc7f3['add'](R(this['editor']['locale'],'PENDING_ACTION_REVISION_HISTORY'));}}['_removePendingAction'](){this['_pendingAction']&&(this['editor']['plugins']['get']('PendingActions')['remove'](this['_pendingAction']),this['_pendingAction']=null);}['_findInsertionIndex'](_0x1eea32){const _0x4ca3c6=this['repository']['getRevisions']();_0x4ca3c6['reverse']();let _0x132969=0x0;for(;_0x132969<_0x4ca3c6['length'];){const _0x4ae555=_0x4ca3c6[_0x132969];if(_0x4ae555===this['currentRevision']){_0x132969++;continue;}if(_0x4ae555['id']===this['_initialRevisionId'])break;const _0x4d4d21=_0x1eea32['toVersion']-_0x4ae555['toVersion']||_0x1eea32['fromVersion']-_0x4ae555['fromVersion'];if(_0x4d4d21>0x0)break;if(_0x4d4d21<0x0)_0x132969++;else{if(!_0x1eea32['creator']&&_0x4ae555['creator'])break;if(_0x4ae555['creator']||!_0x1eea32['creator']){if(_0x1eea32['createdAt']>_0x4ae555['createdAt'])break;_0x132969++;}else _0x132969++;}}return _0x132969;}['_getFromVersion'](_0x10a88e){const _0x40921a=this['repository']['getRevisions']();_0x40921a['reverse'](),_0x40921a['shift']();const _0x410c48=_0x40921a['find'](_0x18a5ea=>_0x18a5ea['toVersion']<=_0x10a88e)['toVersion'];return _0x410c48<this['_startingVersion']?this['_startingVersion']:_0x410c48;}['_makeRevision']({name:_0x58de99,from:_0x3e9a86,to:_0x3e8bc6,creatorId:_0x138c10,id:_0x3080ae}){const _0x5a63ac=this['buildRevisionData']({'from':_0x3e9a86,'to':_0x3e8bc6});_0x5a63ac['name']=_0x58de99,_0x5a63ac['creatorId']=_0x138c10,_0x5a63ac['id']=_0x3080ae;const _0x4c361d=this['addRevisionData'](_0x5a63ac);return this['adapter']&&this['_bufferUpdate'](_0x5a63ac['id'],_0x5a63ac,!0x0),_0x4c361d;}['_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(_0x398086){this['editor']=_0x398086,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'](_0x2ee47c){this['source']=_0x2ee47c;const _0x6af5d1=new Map(),_0x23edb3=new Map(),_0x265968=this['editor']['model']['document']['roots']['map'](_0x178797=>_0x178797['rootName']);for(const _0x1be264 of _0x265968){const _0x575073=this['editor']['model']['document']['getRoot'](_0x1be264),_0x3e555c=x(_0x575073);_0x6af5d1['set'](_0x1be264,_0x3e555c),_0x23edb3['set'](_0x1be264,Object['fromEntries'](_0x575073['getAttributes']()));}const _0x79670b=Array['from'](this['editor']['model']['markers'])['map'](_0x336213=>[_0x336213['name'],_0x336213['getRange']()]),_0x163095=this['source']['version'];this['_saveMetaData'](_0x163095,_0x6af5d1,_0x79670b,_0x23edb3),this['_startingRevisionId']=this['_revisionId'];const _0x1c5c35=new Map(),_0x702ae2=new Map();for(const _0x104e55 of _0x265968){const _0x34ea4e=N(_0x104e55);_0x1c5c35['set'](_0x104e55,_0x34ea4e),_0x702ae2['set'](_0x104e55,{});}this['_saveMetaData'](Number['NEGATIVE_INFINITY'],_0x1c5c35,[],_0x702ae2);}['getData'](_0x2aceff,_0x4f79a3){if(this['_lastFrom']===_0x2aceff&&this['_lastTo']<=_0x4f79a3)this['_savedMetaData']['size']>0x1&&this['_removeMetaData'](this['_lastTo']),this['_applyOperations'](this['_lastTo'],_0x4f79a3,!0x0);else{if(!this['_savedMetaData']['has'](_0x2aceff)){const _0x8debe1=this['_getPreviousFrom'](_0x2aceff);this['_calculateMetaData'](_0x8debe1,_0x2aceff,!0x1);}this['_calculateMetaData'](_0x2aceff,_0x4f79a3,!0x0);}return this['_lastFrom']=_0x2aceff,this['_lastTo']=_0x4f79a3,this['_getState']();}['loadState'](_0x48a148){const _0x1f6bd2=this['editor']['plugins']['get']('RevisionHistoryUtils');this['_reset'](),this['_lastFrom']=_0x48a148['fromVersion'],this['_lastTo']=_0x48a148['toVersion'];for(const _0x4389fe in _0x48a148['diffData']){const _0x5ceb02=_0x48a148['diffData'][_0x4389fe]['attachChange'],_0x5aeea2=_0x5b681f(_0x48a148['diffData'][_0x4389fe]['attributesBefore'])||{},_0x450b20=_0x1f6bd2['_makeModelFromViewString'](_0x48a148['diffData'][_0x4389fe]['deletions']);_0x450b20['rootName']=_0x4389fe,_0x450b20['_isAttached']=!_0x5ceb02||!_0x5ceb02['isAttached'],_0x450b20['isAttached']=()=>_0x450b20['_isAttached'],this['_baseRoots']['set'](_0x4389fe,_0x450b20),this['_baseRootsAttributes']['set'](_0x4389fe,_0x5aeea2),_0x5ceb02&&this['_touchedRoots']['set'](_0x4389fe,_0x5ceb02);const _0x5ab1e9=this['_makeIdsRoot'](_0x450b20);this['_baseIdsRoots']['set'](_0x4389fe,_0x5ab1e9);for(const [_0x121396,_0x402ee0]of _0x450b20['markers']){if(!_0x121396['startsWith']('revision:'))continue;const _0x1dc4ff=_0x121396['split'](':')[0x2];for(const _0x184adb of _0x402ee0['getWalker']({'singleCharacters':!0x0})){const _0x3cc3b2=this['_getVidAttributeName'](_0x184adb),_0x1a38d7='elementEnd'==_0x184adb['type']?_0x184adb['previousPosition']['path']['slice'](0x0,-0x1):_0x184adb['previousPosition']['path'],_0x493a3d=_0x5ab1e9['getNodeByPath'](_0x1a38d7)['getAttribute'](_0x3cc3b2);this['_touched']['set'](_0x493a3d,{'userId':_0x1dc4ff});}}}this['_startingRevisionId']=this['_revisionId'];const _0x34a48a=[...Array(this['_revisionId'])['keys']()]['slice'](0x1)['filter'](_0x2b91e7=>!this['_touched']['has'](_0x2b91e7));let _0x185fbf=0x0;const _0x3dc342=new Map();for(const _0x2e52b7 in _0x48a148['diffData']){const _0x4f8c45=_0x48a148['diffData'][_0x2e52b7]['attachChange'],_0x22a2fd=_0x5b681f(_0x48a148['diffData'][_0x2e52b7]['attributesAfter'])||{},_0x3fec93=_0x1f6bd2['_makeModelFromViewString'](_0x48a148['diffData'][_0x2e52b7]['insertions']);_0x3fec93['rootName']=_0x2e52b7,_0x3fec93['_isAttached']=!_0x4f8c45||_0x4f8c45['isAttached'],_0x3fec93['isAttached']=()=>_0x3fec93['_isAttached'],this['_diffRoots']['set'](_0x2e52b7,_0x3fec93),this['_diffRootsAttributes']['set'](_0x2e52b7,_0x22a2fd);const _0x84f63d=this['_makeIdsRoot'](_0x3fec93,Number['NEGATIVE_INFINITY']);this['_idsRoots']['set'](_0x2e52b7,_0x84f63d),_0x3dc342['set'](_0x2e52b7,_0x3fec93['isAttached']()?_0x22a2fd:{});for(const [_0x2446fe,_0x4453c3]of _0x3fec93['markers']){if(!_0x2446fe['startsWith']('revision:'))continue;const _0x29b69d=_0x2446fe['split'](':')[0x2];for(const _0x198040 of _0x4453c3['getWalker']({'singleCharacters':!0x0})){const _0x340026=this['_getVidAttributeName'](_0x198040),_0x37b62f=this['_revisionId']++,_0x32b2d3='elementEnd'==_0x198040['type']?_0x198040['previousPosition']['path']['slice'](0x0,-0x1):_0x198040['previousPosition']['path'];_0x84f63d['getNodeByPath'](_0x32b2d3)['_setAttribute'](_0x340026,_0x37b62f),this['_touched']['set'](_0x37b62f,{'userId':_0x29b69d});}}for(const _0x5c6371 of this['editor']['model']['createRangeIn'](_0x3fec93)['getWalker']({'singleCharacters':!0x0})){const _0x4f0264=this['_getVidAttributeName'](_0x5c6371),_0x3f904c='elementEnd'==_0x5c6371['type']?_0x5c6371['previousPosition']['path']['slice'](0x0,-0x1):_0x5c6371['previousPosition']['path'],_0x2ae154=_0x84f63d['getNodeByPath'](_0x3f904c);_0x2ae154['getAttribute'](_0x4f0264)>0x0||_0x2ae154['_setAttribute'](_0x4f0264,_0x34a48a[_0x185fbf++]);}for(const [_0x4d6b9a,_0xc2c570]of _0x3fec93['markers'])_0x4d6b9a['startsWith']('revision:')||this['_markers']['set'](_0x4d6b9a,_0xc2c570);}const _0x3f3284=N('$graveyard');this['_baseRoots']['set']('$graveyard',_0x3f3284),this['_baseIdsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x3f3284,0x1));const _0x33649f=N('$graveyard');this['_diffRoots']['set']('$graveyard',_0x33649f),this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x33649f,0x1));const _0x2885ac=Array['from'](this['_diffRoots'])['map'](([_0xb97c24,_0xd2ecc0])=>[_0xb97c24,x(_0xd2ecc0)]);this['_saveMetaData'](this['_lastTo'],_0x2885ac,this['_markers'],_0x3dc342);}['reInit'](){this['_reset'](),this['_lastFrom']=-0x1,this['_lastTo']=-0x1,this['_savedMetaData']['clear'](),this['init'](this['source']);}['_saveMetaData'](_0x339179,_0x53558a,_0x549384,_0x337b58){const _0x566aa4=new Map(_0x53558a),_0x21683f=new Map(_0x5b681f(_0x337b58)),_0x114f9f=new Map();for(const [_0x2176af,_0x110ec8]of _0x549384)_0x114f9f['set'](_0x2176af,{'start':_0x110ec8['start']['clone'](),'end':_0x110ec8['end']['clone'](),'rootName':_0x110ec8['root']['rootName']});this['_savedMetaData']['set'](_0x339179,{'roots':_0x566aa4,'markers':_0x114f9f,'rootsAttributes':_0x21683f});}['_removeMetaData'](_0x231800){this['_savedMetaData']['delete'](_0x231800);}['_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'](_0x5b3584,_0x1dfc3b=null){let _0x228c04=null;_0x5b3584['is']('documentFragment')||(_0x228c04=new _0x2d434f(_0x5b3584['name'],{'vid_start':null===_0x1dfc3b?this['_revisionId']++:_0x1dfc3b++}));const _0x28c262=[];for(const _0x4f7f9d of _0x5b3584['getChildren']())if(_0x4f7f9d['is']('element')){_0x28c262['push'](this['_makeIdsRoot'](_0x4f7f9d,_0x1dfc3b));const _0x185b27=_0x28c262[_0x28c262['length']-0x1];null!==_0x1dfc3b&&(_0x1dfc3b=_0x185b27['is']('element','$text')?_0x185b27['getAttribute']('vid')+0x1:_0x185b27['getAttribute']('vid_end')+0x1);}else{for(let _0x59a83a=0x0;_0x59a83a<_0x4f7f9d['offsetSize'];_0x59a83a++)_0x28c262['push'](new _0x2d434f('$text',{'vid':null===_0x1dfc3b?this['_revisionId']++:_0x1dfc3b++}));}if(_0x5b3584['is']('documentFragment')){const _0x4efc4c=N(_0x5b3584['rootName']);return _0x4efc4c['_insertChild'](0x0,_0x28c262),_0x4efc4c;}return _0x228c04['_setAttribute']('vid_end',null===_0x1dfc3b?this['_revisionId']++:_0x1dfc3b++),_0x228c04['_insertChild'](0x0,_0x28c262),_0x228c04;}['_calculateMetaData'](_0x4512b0,_0x509a84,_0x5052b5){this['_reset']();const {roots:_0x3d5d87,markers:_0x5e89c0,rootsAttributes:_0x5a05ef}=this['_savedMetaData']['get'](_0x4512b0);this['_baseRoots']=new Map(_0x3d5d87),this['_baseRootsAttributes']=new Map(_0x5b681f(_0x5a05ef));for(const [_0x2b2005,_0x5d687b]of this['_baseRoots'])if('$graveyard'!==_0x2b2005&&(this['_diffRoots']['set'](_0x2b2005,x(_0x5d687b)),this['_diffRootsAttributes']=new Map(_0x5b681f(_0x5a05ef)),_0x5052b5)){const _0x5d917c=this['_revisionId'];this['_idsRoots']['set'](_0x2b2005,this['_makeIdsRoot'](_0x5d687b)),this['_baseIdsRoots']['set'](_0x2b2005,this['_makeIdsRoot'](_0x5d687b,_0x5d917c));}this['_startingRevisionId']=this['_revisionId'],this['_diffRoots']['set']('$graveyard',x(this['_baseRoots']['get']('$graveyard'))),_0x5052b5&&this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](this['_baseRoots']['get']('$graveyard')));for(const [_0x25c4d3,_0x50c5b2]of _0x5e89c0){const _0x571d25=this['_baseRoots']['get'](_0x50c5b2['rootName']),_0x4961c5=this['_diffRoots']['get'](_0x50c5b2['rootName']),_0x3b39e1=new _0x36900d(this['_fixPosition'](_0x50c5b2['start'],_0x571d25),this['_fixPosition'](_0x50c5b2['end'],_0x571d25)),_0x1beaa0=this['_fixRange'](_0x3b39e1,_0x4961c5);_0x571d25['markers']['set'](_0x25c4d3,_0x3b39e1),this['_markers']['set'](_0x25c4d3,_0x1beaa0);}this['_applyOperations'](_0x4512b0,_0x509a84,_0x5052b5);}['_applyOperations'](_0x3e7fc8,_0x50e2d1,_0x51aebd){for(const _0x27e454 of this['source']['getOperations'](_0x3e7fc8,_0x50e2d1))this['_handleOperation'](_0x27e454,_0x51aebd);for(const _0x3a3059 of this['_diffRoots']['values']())_0x3a3059['markers']['clear']();for(const [_0x4af7eb,_0x3297fe]of this['_markers']){this['_diffRoots']['get'](_0x3297fe['root']['rootName'])['markers']['set'](_0x4af7eb,_0x3297fe['clone']());}const _0xa7b6e6=new Map(),_0x36efef=new Map();for(const [_0x268f05,_0x346a03]of this['_diffRoots'])_0xa7b6e6['set'](_0x268f05,x(_0x346a03)),_0x36efef['set'](_0x268f05,this['_diffRootsAttributes']['get'](_0x268f05));this['_saveMetaData'](_0x50e2d1,_0xa7b6e6,this['_markers'],_0x36efef);}['_getPreviousFrom'](_0x57c575){const _0x28578f=Array['from'](this['_savedMetaData']['keys']());_0x28578f['sort']((_0x4fe56e,_0x3be56a)=>_0x4fe56e-_0x3be56a),_0x28578f['reverse']();for(const _0x19b969 of _0x28578f)if(_0x19b969<_0x57c575)return _0x19b969;return Number['NEGATIVE_INFINITY'];}['_copyMarkers'](_0x113eb6,_0x3172fc){const _0x1c280d=Array['from'](_0x3172fc['markers'])['map'](([_0x3de21d,_0x525aad])=>[_0x3de21d,this['_fixRange'](_0x525aad,_0x113eb6)]);_0x113eb6['markers']=new Map(_0x1c280d);}['_transformMarkers'](_0x34e9f2){for(const _0x4e1cb2 of this['_markers']['values']()){const _0x37702a=_0x4e1cb2['getTransformedByOperation'](_0x34e9f2),_0xa1f188=_0x36900d['_createFromRanges'](_0x37702a);_0x4e1cb2['start']=_0xa1f188['start'],_0x4e1cb2['end']=_0xa1f188['end'];}}['_handleOperation'](_0x1c22cf,_0x2e8fee){if('addRoot'!=_0x1c22cf['type']&&'detachRoot'!=_0x1c22cf['type']){if('insert'==_0x1c22cf['type']){const _0x326ac3=_0x1c22cf['position']['root']['rootName'];this['_diffRoots']['has'](_0x326ac3)||(this['_diffRoots']['set'](_0x326ac3,N(_0x326ac3,!0x0)),this['_diffRootsAttributes']['set'](_0x326ac3,{}),_0x2e8fee&&this['_idsRoots']['set'](_0x326ac3,N(_0x326ac3,!0x0)));}else{if('addRootAttribute'==_0x1c22cf['type']||'removeRootAttribute'==_0x1c22cf['type']||'changeRootAttribute'==_0x1c22cf['type'])return void this['_handleRootAttributeOperation'](_0x1c22cf);'marker'==_0x1c22cf['type']&&this['_handleMarkerOperation'](_0x1c22cf);}if('marker'!==_0x1c22cf['type']){const _0xb099fd=this['_cloneOperation'](_0x1c22cf,this['_diffRoots']);_0xb099fd['_execute'](),this['_transformMarkers'](_0xb099fd);}if(_0x2e8fee)switch(_0x1c22cf['type']){case'insert':this['_handleInsertOperation'](_0x1c22cf);break;case'move':case'remove':case'reinsert':this['_handleMoveOperation'](_0x1c22cf);break;case'merge':this['_handleMergeOperation'](_0x1c22cf);break;case'split':this['_handleSplitOperation'](_0x1c22cf);}}else this['_handleRootOperation'](_0x1c22cf,_0x2e8fee);}['_cloneOperation'](_0x2bfc06,_0x39df45){const _0x19347b=_0x2bfc06['clone']();return _0x19347b['_authorId']=_0x2bfc06['_authorId'],this['_fixOperation'](_0x19347b,_0x39df45),_0x19347b;}['_getBaseVids'](_0x1dd0bd){return _0x1dd0bd['map'](_0x3162b5=>{const _0x5a6681=this['_getVidAttributeName'](_0x3162b5);return Number(_0x3162b5['item']['getAttribute'](_0x5a6681));});}['_generateTape'](_0x2556df,_0x53babd){if(_0x2556df['is']('element','$text'))_0x53babd['push']({'item':_0x2556df,'type':'text'});else{_0x2556df['is']('element')&&_0x53babd['push']({'item':_0x2556df,'type':'elementStart'});for(const _0x3c4139 of _0x2556df['getChildren']())this['_generateTape'](_0x3c4139,_0x53babd);_0x2556df['is']('element')&&_0x53babd['push']({'item':_0x2556df,'type':'elementEnd'});}return _0x53babd;}['_getState'](){const _0x3a5edb=new Map(this['_touched']),_0xaf5bd8=new Map(_0x3a5edb),_0x573f3b=new Map(),_0x190000={'insertions':{},'deletions':{}},_0x4ca124={'insertions':{},'deletions':{}},_0xd23e2c=new Map(),_0x2a99ca=new Set([...this['_baseRoots']['keys'](),...this['_diffRoots']['keys']()]);_0x2a99ca['delete']('$graveyard');for(const _0x52b109 of _0x2a99ca){const _0x49b749=this['_diffRoots']['get'](_0x52b109)||N(_0x52b109,!0x1),_0x36593e=this['_baseRoots']['get'](_0x52b109)||N(_0x52b109,!0x1);_0x49b749['isAttached']()||_0x36593e['isAttached']()?(_0x190000['insertions'][_0x52b109]=x(_0x49b749),_0x190000['deletions'][_0x52b109]=x(_0x36593e),this['_copyMarkers'](_0x190000['deletions'][_0x52b109],_0x36593e),this['_copyMarkers'](_0x190000['insertions'][_0x52b109],_0x49b749),_0x4ca124['insertions'][_0x52b109]=this['_generateTape'](this['_idsRoots']['get'](_0x52b109),[]),_0x4ca124['deletions'][_0x52b109]=this['_generateTape'](this['_baseIdsRoots']['get'](_0x52b109)||N(_0x52b109,!0x1),[])):_0x2a99ca['delete'](_0x52b109);}for(const _0x2e8eec of _0x2a99ca){const _0x249ce3=_0x4ca124['insertions'][_0x2e8eec];for(const _0x206f2c of _0x249ce3){const _0x40265e=this['_getVidAttributeName'](_0x206f2c),_0x356f72=_0x206f2c['item']['getAttribute'](_0x40265e);_0xaf5bd8['delete'](_0x356f72),_0x356f72>=this['_startingRevisionId']&&_0x573f3b['set'](_0x356f72,_0x3a5edb['get'](_0x356f72));}}for(const _0x51dcba of _0x2a99ca){const _0x11a62c=_0x4ca124['insertions'][_0x51dcba],_0x31f1fe=this['_getBaseVids'](_0x4ca124['deletions'][_0x51dcba]);let _0xf55e93=0x0;for(const _0x535bba of _0x11a62c){const _0x10f3a3=this['_getVidAttributeName'](_0x535bba),_0xfcf88f=_0x535bba['item']['getAttribute'](_0x10f3a3);if(!_0x573f3b['has'](_0xfcf88f)&&!_0xd23e2c['has'](_0xfcf88f)){if(_0xaf5bd8['has'](_0xfcf88f))_0xf55e93++;else{if(_0xfcf88f!=_0x31f1fe[_0xf55e93]){const _0x3fc56b=_0x3a5edb['get'](_0xfcf88f)||_0x3a5edb['get'](_0x31f1fe[_0xf55e93]);for(;_0xfcf88f!=_0x31f1fe[_0xf55e93];)_0xaf5bd8['has'](_0x31f1fe[_0xf55e93])||(_0xd23e2c['set'](_0x31f1fe[_0xf55e93],_0x3fc56b),_0x3a5edb['set'](_0x31f1fe[_0xf55e93],_0x3fc56b)),_0xf55e93++;}_0xf55e93++;}}}}for(const _0x52ffd7 of _0x2a99ca){const _0x1ee6f2=_0x4ca124['insertions'][_0x52ffd7];for(const _0xc413fe of _0x1ee6f2){const _0x264d16=this['_getVidAttributeName'](_0xc413fe),_0x30f923=_0xc413fe['item']['getAttribute'](_0x264d16);if(_0xd23e2c['has'](_0x30f923)){const _0x531a84=_0xd23e2c['get'](_0x30f923);_0xaf5bd8['has'](_0x30f923)||_0xaf5bd8['set'](_0x30f923,{..._0x531a84}),_0x573f3b['set'](_0x30f923,{..._0x531a84});}}}for(const _0x23e75c of _0xaf5bd8['keys']())_0x23e75c>=this['_startingRevisionId']&&_0xaf5bd8['delete'](_0x23e75c);const _0x167410=new Map();for(const _0x5632fa of _0x2a99ca){let _0x495fcf=_0x4ca124['insertions'][_0x5632fa];for(const _0x4b053f of _0x495fcf)if(_0x4b053f['item']['is']('element','tableCell')){const _0xb60b84=this['_getVidAttributeName'](_0x4b053f),_0x3ac093=_0x4b053f['item']['getAttribute'](_0xb60b84);if(_0x573f3b['has'](_0x3ac093)){const _0x155ab8=_0x4b053f['item']['parent']['parent']['getAttribute']('vid_start'),_0x3b449f=_0x167410['get'](_0x155ab8)||new Set();_0x3b449f['add'](_0x573f3b['get'](_0x3ac093)['userId']),_0x167410['set'](_0x155ab8,_0x3b449f);}}_0x495fcf=_0x4ca124['deletions'][_0x5632fa];for(const _0x44d228 of _0x495fcf)if(_0x44d228['item']['is']('element','tableCell')){const _0x10375a=this['_getVidAttributeName'](_0x44d228),_0x3bdfdc=_0x44d228['item']['getAttribute'](_0x10375a);if(_0xaf5bd8['has'](_0x3bdfdc)){const _0x56f564=_0x44d228['item']['parent']['parent']['getAttribute']('vid_start'),_0x4c87b5=_0x167410['get'](_0x56f564)||new Set();_0x4c87b5['add'](_0xaf5bd8['get'](_0x3bdfdc)['userId']),_0x167410['set'](_0x56f564,_0x4c87b5);}}for(const _0x2926dc of _0x167410['keys']())(_0x573f3b['has'](_0x2926dc)||_0xaf5bd8['has'](_0x2926dc))&&_0x167410['delete'](_0x2926dc);}for(const _0x4d1e4f of _0x2a99ca){const _0x1592d8=_0x4ca124['insertions'][_0x4d1e4f];let _0x34669c=null,_0x255313=null;for(const _0x142118 of _0x1592d8){const _0xffcd73=this['_getVidAttributeName'](_0x142118),_0x10eef1=_0x142118['item']['getAttribute'](_0xffcd73),_0x52ff4d=_0x167410['get'](_0x10eef1);_0x52ff4d&&'elementStart'==_0x142118['type']&&(_0x34669c=Array['from'](_0x52ff4d)[0x0],_0x255313=_0x142118['item']['getAttribute']('vid_end')),_0x34669c&&(_0xaf5bd8['set'](_0x10eef1,{'userId':_0x34669c}),_0x573f3b['set'](_0x10eef1,{'userId':_0x34669c})),_0x10eef1==_0x255313&&(_0x34669c=null,_0x255313=null);}}const _0x4ce27b={},_0x2e6a8b=new Set();for(const _0x2be6e4 of _0x2a99ca){const _0x5008d2=_0x190000['deletions'][_0x2be6e4],_0x1891ad=_0x190000['insertions'][_0x2be6e4];for(const {userId:_0x3322fd}of this['_touchedMarkers']['values']())null!==_0x3322fd&&_0x2e6a8b['add'](_0x3322fd);for(const {userId:_0x44d3b5}of this['_touchedRoots']['values']())null!==_0x44d3b5&&_0x2e6a8b['add'](_0x44d3b5);this['_markChanges'](_0x1891ad,_0x4ca124['insertions'][_0x2be6e4],_0x573f3b,'insertion',_0x2e6a8b),this['_markChanges'](_0x5008d2,_0x4ca124['deletions'][_0x2be6e4],_0xaf5bd8,'deletion',_0x2e6a8b),_0x4ce27b[_0x2be6e4]={'insertions':this['_prepareViewToSave'](_0x1891ad),'deletions':this['_prepareViewToSave'](_0x5008d2),'attachChange':this['_touchedRoots']['get'](_0x2be6e4)||null,'attributesBefore':_0x5b681f(this['_baseRootsAttributes']['get'](_0x2be6e4))||{},'attributesAfter':_0x5b681f(this['_diffRootsAttributes']['get'](_0x2be6e4))};}return{'diffData':_0x4ce27b,'authorsIds':Array['from'](_0x2e6a8b)};}['_processRootBeforeSave'](_0x4606b5){for(const [,_0x4302c0]of _0x4606b5['markers']){const _0x1803df=_0x4302c0['start']['getAncestors']()['filter'](_0x29cde3=>'tableCell'==_0x29cde3['name']);for(const _0x20e3d7 of _0x1803df)0x1==_0x20e3d7['childCount']&&_0x20e3d7['getChild'](0x0)['is']('element','paragraph')&&_0x20e3d7['getChild'](0x0)['_setAttribute']('keepParagraph',!0x0);}}['_prepareViewToSave'](_0x1aee6f){this['_processRootBeforeSave'](_0x1aee6f);const _0xe46c50=this['editor']['data']['toView'](_0x1aee6f,{}),_0xc53440=Array['from'](_0xe46c50['getChildren']())['map'](_0x5ae36d=>this['_getViewJson'](_0x5ae36d));return JSON['stringify'](_0xc53440);}['_getViewJson'](_0x5c6bd9){if(_0x5c6bd9['is']('$text'))return _0x5c6bd9['data'];{const _0x4aabbb=this['editor']['plugins']['get']('RevisionHistoryUtils'),_0xa30eb5=_0x5c6bd9,_0x1ecc83=this['editor']['data']['htmlProcessor']['domConverter'],_0x5b4b0a={'type':_0x4aabbb['_getTypeCharForViewElement'](_0xa30eb5),'name':_0xa30eb5['name'],'attributes':Array['from'](_0xa30eb5['getAttributes']()),'children':Array['from'](_0xa30eb5['getChildren']())['map'](_0x5f40b6=>this['_getViewJson'](_0x5f40b6))};if(_0x5c6bd9['is']('uiElement')&&'$comment'!=_0x5c6bd9['name']){const _0x1a67bf=_0x5c6bd9['render'](_0x1ecc83['domDocument'],_0x1ecc83);_0x5b4b0a['children']['push'](_0x1a67bf['outerHTML']);}else{if(_0x5c6bd9['is']('rawElement')){const _0x474420=_0x1ecc83['domDocument']['createElement'](_0xa30eb5['name']);_0x5c6bd9['render'](_0x474420,_0x1ecc83),_0x5b4b0a['children']['push'](_0x474420['innerHTML']);}}const _0x53888a=Array['from'](_0xa30eb5['getCustomProperties']());_0x53888a['length']>0x0&&(_0x5b4b0a['customProperties']=_0x53888a);const _0x497a93=_0xa30eb5['getFillerOffset']();return null!==_0x497a93&&(_0x5b4b0a['fillerOffset']=_0x497a93),_0x5b4b0a;}}['_markChanges'](_0x5d99b3,_0x16aa1e,_0x150194,_0x3e291b,_0x2c48c1){let _0x2324b6=null,_0x2014ed=null,_0x18aa43=0x0;const _0x3e9336=this['editor']['model'];for(let _0x37942b=0x0;_0x37942b<_0x16aa1e['length'];_0x37942b++){const _0x4a10d4=this['_getVidAttributeName'](_0x16aa1e[_0x37942b]),_0x139dda=_0x16aa1e[_0x37942b]['item']['getAttribute'](_0x4a10d4),_0x4c8528=_0x150194['get'](_0x139dda),_0x2b2794=_0x37942b==_0x16aa1e['length']-0x1;(!_0x2324b6&&_0x4c8528&&(_0x2324b6=_0x4c8528,_0x2014ed=_0x16aa1e[_0x37942b]),_0x2324b6&&(!_0x4c8528||_0x4c8528['userId']!=_0x2324b6['userId']))&&(_0x1342f2(_0x4c8528,P(_0x2014ed,_0x5d99b3,_0x3e9336),P(_0x16aa1e[_0x37942b],_0x5d99b3,_0x3e9336)),_0x2324b6=_0x4c8528||null,_0x2014ed=_0x4c8528?_0x16aa1e[_0x37942b]:null),_0x2324b6&&_0x2b2794&&_0x1342f2(_0x4c8528,P(_0x2014ed,_0x5d99b3,_0x3e9336),V(_0x16aa1e[_0x37942b],_0x5d99b3,_0x3e9336));}function _0x1342f2(_0x24fc9,_0x4a9c8f,_0x26ed09){const _0x42c347=_0x2324b6['userId'],_0x5aa4c8='revision:'+_0x3e291b+':'+_0x42c347+':'+_0x18aa43++,_0x440a55=_0x3e9336['createRange'](_0x4a9c8f,_0x26ed09);_0x5d99b3['markers']['set'](_0x5aa4c8,_0x440a55),null!==_0x42c347&&_0x2c48c1['add'](_0x42c347);}}['_getVidAttributeName'](_0x4ceb43){switch(_0x4ceb43['type']){case'elementStart':return'vid_start';case'elementEnd':return'vid_end';default:return'vid';}}['_fixOperation'](_0x3f72f3,_0xf4246a){_0x3f72f3['baseVersion']=null;for(const _0x555c08 in _0x3f72f3){const _0x4b0fe5=_0x3f72f3[_0x555c08];if(_0x4b0fe5 instanceof _0xb2d03b){const _0x46834b=_0xf4246a['get'](_0x4b0fe5['root']['rootName']);_0x3f72f3[_0x555c08]=this['_fixPosition'](_0x4b0fe5,_0x46834b);}if(_0x4b0fe5 instanceof _0x36900d){const _0x450f48=_0xf4246a['get'](_0x4b0fe5['root']['rootName']);_0x3f72f3[_0x555c08]=this['_fixRange'](_0x4b0fe5,_0x450f48);}'root'===_0x555c08&&(_0x3f72f3['root']=_0xf4246a['get'](_0x3f72f3['root']['rootName']));}}['_fixRange'](_0x5ef438,_0x584bff){return this['editor']['model']['createRange'](this['_fixPosition'](_0x5ef438['start'],_0x584bff),this['_fixPosition'](_0x5ef438['end'],_0x584bff));}['_fixPosition'](_0x2d41df,_0x2e4bfd){return this['editor']['model']['createPositionFromPath'](_0x2e4bfd,_0x2d41df['path'],_0x2d41df['stickiness']);}['_handleInsertOperation'](_0x2e0c4e){const _0x3c3e04=this['_idsRoots']['get'](_0x2e0c4e['position']['root']['rootName']),_0xcd525=this['_fixPosition'](_0x2e0c4e['position'],_0x3c3e04),_0x254589=null===_0x2e0c4e['_authorId']?null:_0x2e0c4e['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x52c21d=_0xcd525['parent'],_0x3220cc=this['_revisionId'],_0x52397a=[];for(const _0x2fe939 of _0x2e0c4e['nodes'])if(_0x2fe939['is']('element'))_0x52397a['push'](this['_makeIdsRoot'](_0x2fe939));else{for(let _0x584c2f=0x0;_0x584c2f<_0x2fe939['offsetSize'];_0x584c2f++)_0x52397a['push'](new _0x2d434f('$text',{'vid':this['_revisionId']++}));}const _0x39e231=this['_revisionId'];for(let _0x32c3ec=_0x3220cc;_0x32c3ec<_0x39e231;_0x32c3ec++)this['_touched']['set'](_0x32c3ec,{'userId':_0x254589});_0x52c21d['_insertChild'](_0xcd525['offset'],_0x52397a);}['_handleMoveOperation'](_0x35e5c9){(_0x35e5c9=this['_cloneOperation'](_0x35e5c9,this['_idsRoots']))['_execute']();const _0x5d8a31=null===_0x35e5c9['_authorId']?null:_0x35e5c9['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x16fdbd=_0x35e5c9['getMovedRangeStart'](),_0xb39387=_0x16fdbd['parent'],_0x3646e7=_0x16fdbd['offset'];!function _0x1de5c0(_0xf8d650,_0x449cef,_0x3f2619,_0xeb60a5){for(let _0x939029=_0x3f2619;_0x939029<_0xeb60a5;_0x939029++){const _0xa71c4=_0x449cef['getChild'](_0x939029);_0xa71c4['is']('element','$text')?_0xf8d650['set'](_0xa71c4['getAttribute']('vid'),{'userId':_0x5d8a31}):(_0xf8d650['set'](_0xa71c4['getAttribute']('vid_start'),{'userId':_0x5d8a31}),_0x1de5c0(_0xf8d650,_0xa71c4,0x0,_0xa71c4['childCount']),_0xf8d650['set'](_0xa71c4['getAttribute']('vid_end'),{'userId':_0x5d8a31}));}}(this['_touched'],_0xb39387,_0x3646e7,_0x3646e7+_0x35e5c9['howMany']);}['_handleMergeOperation'](_0x34d5a2){const _0x55d9cc=null===(_0x34d5a2=this['_cloneOperation'](_0x34d5a2,this['_idsRoots']))['_authorId']?null:_0x34d5a2['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x26a5a5=_0x34d5a2['targetPosition']['parent'],_0x3e294c=_0x34d5a2['sourcePosition']['parent'],_0x54188a=_0x26a5a5['getAttribute']('vid_end'),_0x16b79d=_0x3e294c['getAttribute']('vid_start');_0x26a5a5['_setAttribute']('vid_end',_0x3e294c['getAttribute']('vid_end')),_0x3e294c['_setAttribute']('vid_end',_0x54188a),this['_touched']['set'](_0x16b79d,{'userId':_0x55d9cc}),this['_touched']['set'](_0x54188a,{'userId':_0x55d9cc}),_0x34d5a2['_execute']();}['_handleSplitOperation'](_0x154ee3){const _0x48b99a=null===(_0x154ee3=this['_cloneOperation'](_0x154ee3,this['_idsRoots']))['_authorId']?null:_0x154ee3['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x3bd953=_0x154ee3['graveyardPosition'],_0x15e17f=_0x154ee3['splitPosition']['parent'];_0x154ee3['_execute']();const _0x25831e=_0x15e17f['getAttribute']('vid_end'),_0x5778f6=_0x154ee3['insertionPosition']['nodeAfter'];if(_0x3bd953){const _0x556de3=_0x5778f6['getAttribute']('vid_end'),_0x25a7e1=_0x15e17f['getAttribute']('vid_end');_0x15e17f['_setAttribute']('vid_end',_0x556de3),_0x5778f6['_setAttribute']('vid_end',_0x25a7e1),this['_touched']['set'](_0x15e17f['getAttribute']('vid_end'),{'userId':_0x48b99a}),this['_touched']['set'](_0x5778f6['getAttribute']('vid_start'),{'userId':_0x48b99a});}else{const _0x420a68=this['_revisionId']++,_0x24284e=this['_revisionId']++;_0x15e17f['_setAttribute']('vid_end',_0x420a68),_0x5778f6['_setAttribute']('vid_start',_0x24284e),_0x5778f6['_setAttribute']('vid_end',_0x25831e),this['_touched']['set'](_0x420a68,{'userId':_0x48b99a}),this['_touched']['set'](_0x24284e,{'userId':_0x48b99a});}}['_handleMarkerOperation'](_0x19ae78){if(!_0x19ae78['affectsData'])return;const _0x118fdc=(_0x19ae78=this['_cloneOperation'](_0x19ae78,this['_diffRoots']))['oldRange']?_0x19ae78['oldRange']['root']:null,_0x214e49=_0x19ae78['newRange']?_0x19ae78['newRange']['root']:null;_0x118fdc&&this['_markers']['delete'](_0x19ae78['name']),_0x214e49&&this['_markers']['set'](_0x19ae78['name'],_0x19ae78['newRange']['clone']());const _0x194661=null===_0x19ae78['_authorId']?null:_0x19ae78['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x53cd72=_0x19ae78['name'];if(!this['_touchedMarkers']['has'](_0x53cd72))return void this['_touchedMarkers']['set'](_0x53cd72,{'range':_0x19ae78['oldRange'],'userId':_0x194661});const _0x4ba1c9=this['_touchedMarkers']['get'](_0x53cd72),_0x500ca5=_0x4ba1c9['range'],_0x31133e=_0x19ae78['newRange'];null==_0x500ca5&&null==_0x31133e||_0x500ca5&&_0x31133e&&_0x500ca5['isEqual'](_0x31133e)?this['_touchedMarkers']['delete'](_0x19ae78['name']):_0x4ba1c9['userId']=_0x194661;}['_handleRootOperation'](_0x214142,_0x27e56b){this['_diffRoots']['has'](_0x214142['rootName'])?this['_diffRoots']['get'](_0x214142['rootName'])['_isAttached']=_0x214142['isAdd']:(this['_diffRoots']['set'](_0x214142['rootName'],N(_0x214142['rootName'],!0x0)),this['_diffRootsAttributes']['set'](_0x214142['rootName'],{}),_0x27e56b&&this['_idsRoots']['set'](_0x214142['rootName'],N(_0x214142['rootName'],!0x0)));const _0x147955=null===_0x214142['_authorId']?null:_0x214142['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x271d29=this['_touchedRoots']['get'](_0x214142['rootName']);_0x271d29&&_0x271d29['userId']===_0x147955?this['_touchedRoots']['delete'](_0x214142['rootName']):this['_touchedRoots']['set'](_0x214142['rootName'],{'userId':_0x147955,'isAttached':_0x214142['isAdd']});}['_handleRootAttributeOperation'](_0x23cb6f){const _0x381847=this['_diffRootsAttributes']['get'](_0x23cb6f['root']['rootName']);null===_0x23cb6f['newValue']?delete _0x381847[_0x23cb6f['key']]:_0x381847[_0x23cb6f['key']]=_0x23cb6f['newValue'];}}function x(_0x543637){const _0x57f2ce=N(_0x543637['rootName'],_0x543637['isAttached']());for(const _0x40338d of _0x543637['getChildren']()){const _0x1a4639=_0x40338d['_clone'](!0x0);_0x57f2ce['_appendChild'](_0x1a4639);}return _0x57f2ce;}function N(_0x5b7b17,_0x4b3e26=!0x0){const _0x4c8e4d=new _0x5dcd6c();return _0x4c8e4d['rootName']=_0x5b7b17,_0x4c8e4d['_isAttached']=_0x4b3e26,_0x4c8e4d['isAttached']=()=>_0x4c8e4d['_isAttached'],_0x4c8e4d;}function P(_0x4aacfd,_0x263e53,_0x40dee4){const _0x16d515='elementEnd'==_0x4aacfd['type']?_0x40dee4['createPositionAt'](_0x4aacfd['item'],'end'):_0x40dee4['createPositionBefore'](_0x4aacfd['item']);return _0x40dee4['createPositionFromPath'](_0x263e53,_0x16d515['path'],_0x16d515['stickiness']);}function V(_0x439dac,_0x52bd5c,_0x365f67){const _0x3cfe79='elementStart'==_0x439dac['type']?_0x365f67['createPositionAt'](_0x439dac['item'],0x0):_0x365f67['createPositionAfter'](_0x439dac['item']);return _0x365f67['createPositionFromPath'](_0x52bd5c,_0x3cfe79['path'],_0x3cfe79['stickiness']);}class me extends/* #__PURE__ -- @preserve */
|
|
25
|
+
_0x567c82(_0x2027a1){['focusTracker'];['keystrokes'];['revisionNameInputView'];constructor(_0x412be6,_0x3a524e){super(_0x412be6),this['focusTracker']=new _0x2db1ce(),this['keystrokes']=new _0x5699cc(),this['set']('revisionNameInputValue',''),this['revisionNameInputView']=this['_createRevisionNameInput'](_0x3a524e),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'](),_0x23e9a7({'view':this}),this['focusTracker']['add'](this['revisionNameInputView']['element']),this['keystrokes']['listenTo'](this['element']);const _0x55f532=_0x3a9fb3=>_0x3a9fb3['stopPropagation']();this['keystrokes']['set']('arrowright',_0x55f532),this['keystrokes']['set']('arrowleft',_0x55f532),this['keystrokes']['set']('arrowup',_0x55f532),this['keystrokes']['set']('arrowdown',_0x55f532);}['focus'](){this['revisionNameInputView']['focus']();}get['revisionName'](){return this['revisionNameInputView']['fieldView']['element']['value']['trim']();}set['revisionName'](_0x512a24){this['revisionNameInputView']['fieldView']['element']['value']=_0x512a24['trim']();}['reset'](){this['revisionNameInputView']['fieldView']['element']['value']='',this['revisionNameInputView']['errorText']=null;}['_createRevisionNameInput'](_0x4d85d2){const _0x59ba20=new et(this['locale'],ti),_0x4598a4=_0x59ba20['fieldView'];_0x4598a4['extendTemplate']({'attributes':{'maxlength':'220'}});let _0x2449e4=R(this['locale'],'Name\x20of\x20the\x20revision');return!_0x4d85d2&&(_0x2449e4+='\x20('+R(this['locale'],'optional')+')'),(_0x59ba20['label']=_0x2449e4,_0x4598a4['on']('input',()=>{this['revisionNameInputValue']=_0x4598a4['element']['value']['trim']();}),_0x59ba20);}}class v extends _0x3daf77{static get['pluginName'](){return'RevisionHistoryUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[h];}['_saveRevisionFormView'];['init'](){const _0x1a4dc0=this['editor'],_0x24a6aa=_0x1a4dc0['plugins']['get']('RevisionTracker');_0x1a4dc0['ui']['componentFactory']['add']('revisionHistory',_0x3d128f=>{const _0x302231=_0x261f45(_0x3d128f),_0x31508f=_0x302231['panelView']['children'],_0x20957c=new _0x1da0da(_0x3d128f),_0x3d51b3=new _0x37e66c(_0x3d128f),_0x2e0582=new _0x304609(_0x3d128f),_0x2ddc8f=new _0x37e66c(_0x3d128f),_0x2d57b1=new _0x304609(_0x3d128f);return _0x302231['bind']('isEnabled')['to'](_0x24a6aa,'isReady',_0x24a6aa,'isEnabled',_0x1a4dc0,'isReadOnly',(_0x5438ab,_0x52e169,_0x4f9aea)=>_0x5438ab&&_0x52e169&&!_0x4f9aea),_0x302231['buttonView']['set']({'icon':_0x11f60f,'label':R(_0x3d128f,'Revision\x20history'),'tooltip':!0x0}),_0x2e0582['set']({'label':R(_0x3d128f,'Save\x20current\x20revision'),'withText':!0x0,'role':'menuitem'}),_0x2e0582['bind']('isEnabled')['to'](_0x24a6aa,'isReady',_0x24a6aa,'isEnabled',_0x1a4dc0,'isReadOnly',(_0x3434ef,_0x5a5208,_0x53882a)=>_0x3434ef&&_0x5a5208&&!_0x53882a),_0x2e0582['on']('execute',()=>this['_showDialog']()),_0x2d57b1['set']({'label':R(_0x3d128f,'Open\x20revision\x20history'),'withText':!0x0,'role':'menuitem'}),_0x2d57b1['bind']('isEnabled')['to'](_0x24a6aa,'isReady',_0x1a4dc0,'isReadOnly',(_0x4460f0,_0x4cba46)=>_0x4460f0&&!_0x4cba46),_0x2d57b1['on']('execute',()=>{_0x1a4dc0['config']['get']('revisionHistory')['showRevisionViewerCallback'](),_0x302231['isOpen']=!0x1,_0x1a4dc0['editing']['view']['focus']();}),_0x3d51b3['children']['add'](_0x2e0582),_0x2ddc8f['children']['add'](_0x2d57b1),_0x20957c['role']='menu',_0x20957c['items']['addMany']([_0x3d51b3,_0x2ddc8f]),_0x31508f['add'](_0x20957c),_0x302231;}),_0x1a4dc0['ui']['componentFactory']['add']('menuBar:revisionHistory',()=>this['_registerMenuComponent']());}['_registerMenuComponent'](){const _0x58f27c=this['editor'],_0x6c1673=_0x58f27c['locale'],_0x48deea=new _0x14903e(_0x6c1673),_0x263e7d=new _0x16d90e(_0x6c1673);_0x48deea['buttonView']['set']({'icon':_0x11f60f,'label':R(_0x6c1673,'Revision\x20history')});const _0x55a71f=new _0x288c51(_0x6c1673,_0x48deea),_0x32d6dd=new _0x4391ff(_0x6c1673);_0x32d6dd['set']({'label':R(_0x6c1673,'Save\x20current\x20revision')}),_0x32d6dd['delegate']('execute')['to'](_0x48deea),_0x32d6dd['on']('execute',()=>{this['_showDialog']();}),_0x55a71f['children']['add'](_0x32d6dd),_0x263e7d['items']['add'](_0x55a71f);const _0x266523=new _0x288c51(_0x6c1673,_0x48deea),_0x47c066=new _0x4391ff(_0x6c1673);return _0x47c066['set']({'label':R(_0x6c1673,'Open\x20revision\x20history')}),_0x47c066['delegate']('execute')['to'](_0x48deea),_0x47c066['on']('execute',()=>{_0x58f27c['config']['get']('revisionHistory')['showRevisionViewerCallback']();}),_0x266523['children']['add'](_0x47c066),_0x263e7d['items']['add'](_0x266523),_0x48deea['panelView']['children']['add'](_0x263e7d),_0x48deea;}['_showDialog'](){const _0x3cfcec=this['editor'],_0xc56c35=_0x3cfcec['locale'],_0x7c7403=_0x3cfcec['plugins']['get']('Dialog'),_0x1ec221=_0x3cfcec['plugins']['get']('RevisionTracker');function _0x27bc75(_0x312d71){_0x3cfcec['config']['get']('revisionHistory.requireRevisionName')&&''===_0x312d71['revisionName']?_0x312d71['revisionNameInputView']['errorText']=R(_0xc56c35,'The\x20revision\x20name\x20cannot\x20be\x20empty.'):(_0x3cfcec['plugins']['get'](h)['saveRevision']({'name':_0x312d71['revisionName']}),_0x7c7403['hide']());}this['_saveRevisionFormView']||(this['_createSaveRevisionFormView'](),this['_saveRevisionFormView']['on']('submit',()=>_0x27bc75(this['_saveRevisionFormView']))),this['_saveRevisionFormView']['reset'](),_0x7c7403['show']({'id':'revisionSave','title':R(_0xc56c35,'Save\x20current\x20revision'),'isModal':!0x0,'content':this['_saveRevisionFormView'],'actionButtons':[{'label':R(_0x3cfcec['locale'],'Cancel'),'withText':!0x0,'onExecute':()=>_0x7c7403['hide']()},{'label':R(_0x3cfcec['locale'],'Accept'),'class':'ck-button-action','withText':!0x0,'onCreate'(_0x4edb7d){_0x4edb7d['bind']('isEnabled')['to'](_0x1ec221,'isReady',_0x1ec221,'isEnabled',_0x3cfcec,'isReadOnly',(_0x1ad75c,_0x504feb,_0x527e80)=>_0x1ad75c&&_0x504feb&&!_0x527e80);},'onExecute':()=>_0x27bc75(this['_saveRevisionFormView'])}]});}['_createSaveRevisionFormView'](){const _0x161092=this['editor'],_0x14e580=_0x161092['locale'];this['_saveRevisionFormView']=new me(_0x14e580,_0x161092['config']['get']('revisionHistory.requireRevisionName')),this['_saveRevisionFormView']['render']();}}class z extends _0x2027a1{['changeId'];['_model'];constructor(_0x14315d,_0x1e0f55){super(_0x14315d),this['_model']=_0x1e0f55,this['changeId']=_0x1e0f55['id'];const _0x3804d9=this['bindTemplate'],_0x5dff24=R(_0x14315d,_0x1e0f55['data']['isSuggestion']?'Suggested\x20by':'add'==_0x1e0f55['type']?'Added\x20by':'Removed\x20by');this['set']('type',_0x1e0f55['type']),this['setTemplate']({'tag':'div','attributes':{'class':['ck-annotation','ck-revision-change',_0x3804d9['to']('type',_0x20ba3a=>'ck-revision-change__'+_0x20ba3a)],'tabindex':-0x1},'children':[{'tag':'span','children':[{'tag':'span','attributes':{'class':['ck-revision-change__label']},'children':[{'text':_0x5dff24}]},{'text':'\x20'+_0x1e0f55['author']['name']}]}]});}['focus'](){this['element']['focus']();}}class G extends/* #__PURE__ -- @preserve */
|
|
26
|
+
_0x4f3d81(){['id'];['author'];['type'];['data'];['rootName'];constructor(_0x540e15){super(),this['id']=_0x540e15['id']||_0x1c1c29(),this['author']=_0x540e15['author'],this['type']=_0x540e15['type'],this['data']=_0x540e15['data']||{},this['rootName']=_0x540e15['rootName'],this['set']('createdAt',_0x540e15['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(_0x5cbf1b,_0x407025){this['newRevisionId']=_0x5cbf1b,this['oldRevisionId']=_0x407025,this['changes']=new _0x485594();}['_setChanges'](_0xbfda30){for(const _0x44b51b of _0xbfda30)this['changes']['add'](_0x44b51b);}}class l extends _0x3daf77{['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[_0x3c3d4d,_0x159e16,S,$];}constructor(_0x3b3ca7){super(_0x3b3ca7),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',(_0x188b4c,_0x3f0d52,_0xfd941c)=>{this['activeChange']=null,this['activeView']=null,this['editor']['editing']['view']['change'](_0x1c2761=>{for(const _0x57fd3f of this['editor']['editing']['view']['document']['roots'])_0xfd941c?_0x1c2761['removeClass']('ck-editor__editable__overlay',_0x57fd3f):_0x1c2761['addClass']('ck-editor__editable__overlay',_0x57fd3f);});}),this['bind']('isNavigationMode')['to'](this,'activeChange',_0x595752=>null!==_0x595752),this['bind']('currentChangeNumber')['to'](this,'isReady',this,'diff',this,'activeChange',(_0x2bf6b8,_0x199407,_0x22df79)=>_0x2bf6b8&&_0x22df79?_0x199407['changes']['getIndex'](_0x22df79):0x0),this['bind']('numberOfChanges')['to'](this,'isReady',this,'diff',(_0x2c25b4,_0xd60ea0)=>_0x2c25b4?_0xd60ea0['changes']['length']:0x0),this['_changeView']=null,this['_changeIdToChange']=new Map(),this['_balloon']=this['editor']['plugins']['get'](_0x159e16);}['init'](){const _0xcc56b5=this['editor'],_0x1c1697=new rt(_0xcc56b5,{'direction':'backward'}),_0xa38a79=new rt(_0xcc56b5,{'direction':'forward'});(_0xcc56b5['commands']['add']('showPreviousChange',_0x1c1697),_0xcc56b5['commands']['add']('showNextChange',_0xa38a79),_0xcc56b5['commands']['add']('restoreRevision',new nt(_0xcc56b5)),this['on']('change:numberOfChanges',()=>{_0x1c1697['refresh'](),_0xa38a79['refresh']();}),this['_setConversion'](),this['_initInteractions'](),_0xcc56b5['enableReadOnlyMode']('revision-viewer'),_0xcc56b5['plugins']['has']('WidgetToolbarRepository'))&&_0xcc56b5['plugins']['get']('WidgetToolbarRepository')['forceDisabled']('revision-viewer');}async['getRevisionDocumentData'](_0x38c48b){return await this['_utils']['loadRevisionData'](_0x38c48b,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x38c48b);}async['getRevisionRootsAttributes'](_0x2b5a23){return await this['_utils']['loadRevisionData'](_0x2b5a23,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x2b5a23);}async['compare'](_0x3b6133,_0x4b7278,_0x3580ed=!0x1){if(!this['isEnabled'])return;const _0x22f309=this['diff'],_0x28b46e=this['repository'],_0x32da5d='string'==typeof _0x3b6133?_0x28b46e['getRevision'](_0x3b6133):_0x3b6133,_0x222aa7='string'==typeof _0x4b7278?_0x28b46e['getRevision'](_0x4b7278):_0x4b7278,_0xa6b9f2=_0x32da5d['id'],_0x588867=_0x222aa7?_0x222aa7['id']:null;if(!_0x3580ed&&this['diff']&&this['diff']['newRevisionId']===_0xa6b9f2&&this['diff']['oldRevisionId']===_0x588867)return Promise['resolve']();this['isReady']=!0x1,this['activeView']=null,this['activeChange']=null,this['diff']=new J(_0xa6b9f2,_0x588867);const _0x2fd661=this['_getRevisionsRange'](_0x32da5d,_0x222aa7,!0x0)['map'](_0x4c4309=>this['_utils']['loadRevisionData'](_0x4c4309,this['adapter']));return _0x2fd661['push'](new Promise(_0x3f19d4=>{setTimeout(_0x3f19d4,0x14);})),Promise['all'](_0x2fd661)['then'](()=>{if(!this['isEnabled'])return;this['_cleanUp']();const _0xf8dc18=this['_getDiff'](_0xa6b9f2,_0x588867);for(const _0x501fb7 of _0xf8dc18['changes'])this['_changeIdToChange']['set'](_0x501fb7['id'],_0x501fb7);this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0xa96d08=>{for(const _0x5ba827 of this['editor']['model']['document']['getRootNames']())_0xa96d08['detachRoot'](_0x5ba827);for(const _0x1a5aab of Object['keys'](_0xf8dc18['model'])){const _0x351766=_0xa96d08['addRoot'](_0x1a5aab);for(const _0x3fae86 of Object['keys'](_0xf8dc18['attributes'][_0x1a5aab]))_0xa96d08['setAttribute'](_0x3fae86,_0xf8dc18['attributes'][_0x1a5aab][_0x3fae86],_0x351766);_0xa96d08['insert'](_0xf8dc18['model'][_0x1a5aab],_0x351766,0x0);}}),this['diff']['_setChanges'](this['_sortAndFilterDiffChanges'](_0xf8dc18['changes'])),this['isReady']=!0x0;})['catch'](_0x3e4a08=>{console['error'](_0x3e4a08),this['_cleanUp'](),_0x22f309&&(this['diff']=_0x22f309),this['isReady']=!0x0;});}['addRevisionData'](_0x36a8e3,_0x2591b4){const _0x175d08=this['repository']['createRevision'](_0x36a8e3);return _0x175d08['on']('_update',(_0x53c3cd,_0x483a2c,_0x4f5209)=>_0x2591b4(_0x483a2c,_0x4f5209,_0x175d08)),this['repository']['addRevision'](_0x175d08),_0x175d08;}['_cleanUp'](){this['activeChange']=null,this['_cleanMarkers'](),this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=null,this['_changeIdToChange']['clear'](),this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x10f732=>{for(const _0x2db058 of this['editor']['model']['document']['getRootNames']())_0x10f732['detachRoot'](_0x2db058);});}['_sortAndFilterDiffChanges'](_0x7af0ff){const _0x41b6c7=[],_0x3fc376=new Map();for(const _0x3f51fb of this['editor']['model']['document']['getRootNames']()){const _0x4dbf0f=this['editor']['editing']['view']['getDomRoot'](_0x3f51fb);if(!_0x4dbf0f)continue;const _0x48719a=_0x4dbf0f['getClientRects']()['item'](0x0);_0x48719a&&(_0x41b6c7['push'](_0x3f51fb),_0x3fc376['set'](_0x3f51fb,_0x48719a));}return _0x41b6c7['sort']((_0x5d98b0,_0x35f50d)=>{const _0x845bb=_0x3fc376['get'](_0x5d98b0),_0x30b178=_0x3fc376['get'](_0x35f50d);return _0x845bb['y']-_0x30b178['y']||_0x845bb['x']-_0x30b178['x'];}),(_0x7af0ff=_0x7af0ff['filter'](_0x5e2d31=>_0x41b6c7['includes'](_0x5e2d31['rootName'])))['sort']((_0x470dcb,_0xef5bfe)=>_0x41b6c7['indexOf'](_0x470dcb['rootName'])-_0x41b6c7['indexOf'](_0xef5bfe['rootName'])),_0x7af0ff;}['_makeTape'](_0x577fe1){const _0x448536=Array['from'](_0x577fe1['markers'])['filter'](([_0x723b6f,_0x253cf9])=>_0x723b6f['startsWith']('revision:')&&!_0x253cf9['isCollapsed']),_0xae208b=Array['from'](this['editor']['model']['createRangeIn'](_0x577fe1)['getWalker']({'singleCharacters':!0x0}));if(0x0!=_0x448536['length'])for(const _0x5ec4ad of _0xae208b){const [_0x19b819,_0x47f52e]=_0x448536[0x0],[,_0x5b3626,_0x1559af]=_0x19b819['split'](':');if(_0x47f52e['end']['isEqual'](_0x5ec4ad['nextPosition'])&&_0x448536['shift'](),(_0x5ec4ad['previousPosition']['isEqual'](_0x47f52e['start'])||_0x5ec4ad['previousPosition']['isAfter'](_0x47f52e['start']))&&('insertion'==_0x5b3626?_0x5ec4ad['isAdded']={'userId':_0x1559af}:'deletion'==_0x5b3626&&(_0x5ec4ad['isRemoved']={'userId':_0x1559af})),0x0==_0x448536['length'])break;}return _0xae208b;}['_refreshStartEndIndex'](_0x2d3a69){const _0x472eda=new Map();for(let _0x44a923=0x0;_0x44a923<_0x2d3a69['length'];_0x44a923++)'text'===_0x2d3a69[_0x44a923]['type']?(_0x2d3a69[_0x44a923]['item']['startIndex']=_0x44a923,_0x2d3a69[_0x44a923]['item']['endIndex']=_0x44a923):('elementStart'===_0x2d3a69[_0x44a923]['type']?_0x2d3a69[_0x44a923]['item']['startIndex']=_0x44a923:'elementEnd'===_0x2d3a69[_0x44a923]['type']&&(_0x2d3a69[_0x44a923]['item']['endIndex']=_0x44a923),_0x472eda['set'](_0x2d3a69[_0x44a923]['id'],_0x44a923));for(const _0x5ce7e3 of _0x472eda['values']())'elementStart'===_0x2d3a69[_0x5ce7e3]['type']?_0x2d3a69[_0x5ce7e3]['item']['endIndex']=_0x472eda['get'](_0x2d3a69[_0x5ce7e3]['pairId']):'elementEnd'===_0x2d3a69[_0x5ce7e3]['type']&&(_0x2d3a69[_0x5ce7e3]['item']['startIndex']=_0x472eda['get'](_0x2d3a69[_0x5ce7e3]['pairId']));}['_processTape'](_0x1f4232){for(let _0x5d8f63=0x0;_0x5d8f63<_0x1f4232['length'];_0x5d8f63++){if('elementStart'===_0x1f4232[_0x5d8f63]['type'])_0x1f4232[_0x5d8f63]['item']['startIndex']=_0x5d8f63;else{if('elementEnd'===_0x1f4232[_0x5d8f63]['type']){_0x1f4232[_0x5d8f63]['item']['endIndex']=_0x5d8f63;const _0x1c2ad1=_0x1f4232[_0x5d8f63]['item']['startIndex'];_0x1f4232[_0x1c2ad1]['pairId']=_0x1f4232[_0x5d8f63]['id'],_0x1f4232[_0x5d8f63]['pairId']=_0x1f4232[_0x1c2ad1]['id'];}else _0x1f4232[_0x5d8f63]['item']['startIndex']=_0x5d8f63,_0x1f4232[_0x5d8f63]['item']['endIndex']=_0x5d8f63,_0x1f4232[_0x5d8f63]['pairId']=null;}_0x1f4232[_0x5d8f63]['markersStart']||(_0x1f4232[_0x5d8f63]['markersStart']=[],_0x1f4232[_0x5d8f63]['markersEnd']=[]);}}['_markInsertions'](_0x309a2e,_0x152432){const _0x2c1d87=_0x309a2e['filter'](_0x222d60=>!_0x222d60['isAdded']);for(let _0x33e4fd=0x0;_0x33e4fd<_0x152432['length'];_0x33e4fd++)_0x152432[_0x33e4fd]['isAdded']&&(_0x2c1d87[_0x33e4fd]['isAdded']=_0x152432[_0x33e4fd]['isAdded']);}['_getDiff'](_0x135b64,_0x4eca94=null){const _0x13dcf2=this['repository']['getRevision'](_0x135b64),_0x5b2928=_0x4eca94?this['repository']['getRevision'](_0x4eca94):null,_0x2f0d95=this['_getRevisionsRange'](_0x13dcf2,_0x5b2928),_0x42e95e=_0x2f0d95[_0x2f0d95['length']-0x1],_0x35549b=new Map(),_0x4c93df={'model':{},'attributes':{},'changes':[]},_0x4af802=new Set(),_0x45b736=new Map();for(let _0x2ccfd5=_0x2f0d95['length']-0x1;_0x2ccfd5>=0x0;_0x2ccfd5--){const _0x139b0c=_0x2f0d95[_0x2ccfd5];for(const _0x14cc0c of Object['keys'](_0x139b0c['diffData']))if(_0x139b0c['diffData'][_0x14cc0c]['attachChange']){const _0x2e8266=_0x139b0c['diffData'][_0x14cc0c]['attachChange'];_0x2e8266['isAttached']?(_0x4af802['add'](_0x14cc0c),_0x45b736['has'](_0x14cc0c)&&_0x45b736['get'](_0x14cc0c)['userId']==_0x2e8266['userId']?_0x45b736['delete'](_0x14cc0c):_0x45b736['set'](_0x14cc0c,_0x2e8266)):_0x45b736['has'](_0x14cc0c)?(_0x4af802['delete'](_0x14cc0c),_0x45b736['delete'](_0x14cc0c)):(_0x4af802['add'](_0x14cc0c),_0x45b736['set'](_0x14cc0c,_0x2e8266));}else _0x4af802['add'](_0x14cc0c);}for(const _0x271d81 of _0x4af802){const _0x157c21=_0x45b736['has'](_0x271d81)&&!_0x45b736['get'](_0x271d81)['isAttached'];let _0x2a7537=_0x157c21?_0x2f0d95['length']-0x1:0x0;const _0x51faaf=_0x157c21?-0x1:0x1;for(;_0x2f0d95[_0x2a7537];){const _0xaa814f=_0x2f0d95[_0x2a7537];if(_0xaa814f['diffData'][_0x271d81]){const _0x3a914f=_0x157c21?_0xaa814f['diffData'][_0x271d81]['attributesBefore']:_0xaa814f['diffData'][_0x271d81]['attributesAfter'];_0x4c93df['attributes'][_0x271d81]=_0x3a914f?_0x5b681f(_0x3a914f):{};break;}_0x2a7537+=_0x51faaf;}}for(const _0x2cadbc of _0x2f0d95){_0x2cadbc['model']={};for(const _0x317c8f of _0x2cadbc['authors'])_0x35549b['set'](_0x317c8f['id'],_0x317c8f);for(const _0x3d1260 of _0x4af802){const _0x21eb05=_0x2cadbc['diffData'][_0x3d1260]?_0x2cadbc['diffData'][_0x3d1260]['insertions']:'[]',_0x1df506=_0x2cadbc['diffData'][_0x3d1260]?_0x2cadbc['diffData'][_0x3d1260]['deletions']:'[]';_0x2cadbc['model'][_0x3d1260]={'insertions':this['_utils']['_makeModelFromViewString'](_0x21eb05),'deletions':this['_utils']['_makeModelFromViewString'](_0x1df506)};}}for(const _0x20360c of _0x4af802){let _0x5ebc0e=null,_0x314ba5=0x0;const _0x13837f=new Map(Array['from'](_0x13dcf2['model'][_0x20360c]['insertions']['markers'])['filter'](([_0xf16b8c])=>!_0xf16b8c['startsWith']('revision:')));let _0xa8b1b4=0x0;for(const _0xb917b9 of _0x2f0d95){const _0x93fc42=this['_makeTape'](_0xb917b9['model'][_0x20360c]['insertions']);_0xb917b9==_0x13dcf2?(_0x5ebc0e=_0x93fc42,_0x314ba5=_0x5ebc0e['length'],_0x5ebc0e['forEach'](_0x7b88c7=>{_0x7b88c7['id']=_0xa8b1b4++;}),this['_processTape'](_0x5ebc0e)):this['_markInsertions'](_0x5ebc0e,_0x93fc42);const _0x3e7557=_0x5ebc0e['filter'](_0x7c974f=>!_0x7c974f['isAdded'])['map'](_0x27da30=>_0x27da30['id']);let _0x4e402c=0x0;const _0xe22389=this['_makeTape'](_0xb917b9['model'][_0x20360c]['deletions']);_0xe22389['forEach'](_0x557b09=>{_0x557b09['isRemoved']?_0x557b09['id']=_0x314ba5++:_0x557b09['id']=_0x3e7557[_0x4e402c++];}),this['_processTape'](_0xe22389),this['_setDistance'](_0x5ebc0e,'isAdded'),this['_setDistance'](_0xe22389,'isRemoved'),_0xb917b9==_0x13dcf2&&this['_markMarkers'](_0x5ebc0e,_0x13837f),_0x5ebc0e=this['_joinTapes'](_0x5ebc0e,_0xe22389),this['_refreshStartEndIndex'](_0x5ebc0e),this['_setDistance'](_0x5ebc0e,'isRemoved');}_0x5ebc0e=_0x5ebc0e['filter'](_0x540d2e=>!(_0x540d2e['isAdded']&&_0x540d2e['isRemoved']));const _0x262094=new Map(_0x42e95e['model'][_0x20360c]['deletions']['markers']),_0x3aecbc=new Set(_0x13837f['keys']());for(const _0x28ceb4 of _0x262094['keys']())_0x3aecbc['delete'](_0x28ceb4);this['_markSuggestions'](_0x5ebc0e,_0x3aecbc),this['_fixObsoleteTags'](_0x5ebc0e),_0x5ebc0e=this['_removeMissingPairs'](_0x5ebc0e),_0x5ebc0e=this['_markMismatchedRemovedTags'](_0x5ebc0e),_0x5ebc0e=this['_removeUnsupportedChanges'](_0x5ebc0e);const {root:_0x2fe219,changes:_0x175e6c}=this['_makeModelFromTape'](_0x5ebc0e,_0x35549b,_0x20360c);_0x4c93df['model'][_0x20360c]=_0x2fe219;const _0x278063=_0x45b736['get'](_0x20360c);if(_0x278063){const _0xab8410=_0x35549b['get'](_0x278063['userId']),_0x35d42d=new G({'author':_0xab8410,'type':_0x278063['isAttached']?'add':'remove','data':{'isOnRoot':!0x0},'createdAt':new Date(),'rootName':_0x20360c});_0x175e6c['unshift'](_0x35d42d),_0x4c93df['attributes'][_0x20360c]['revisionHistoryAttachChange']=_0x35d42d['id'];}_0x4c93df['changes']=_0x4c93df['changes']['concat'](_0x175e6c);}return _0x4c93df;}['_markMarkers'](_0x182688,_0x46f9a2){for(let _0x56e742=0x0;_0x56e742<_0x182688['length'];_0x56e742++)for(const [_0x883442,_0x1de724]of _0x46f9a2)!_0x1de724['isCollapsed']&&_0x1de724['start']['isEqual'](_0x182688[_0x56e742]['previousPosition'])&&_0x182688[_0x56e742]['markersStart']['push'](_0x883442),_0x1de724['end']['isEqual'](_0x182688[_0x56e742]['nextPosition'])&&_0x182688[_0x56e742]['markersEnd']['push'](_0x883442);}['_joinTapes'](_0xebc5b4,_0x5b68f1){let _0x330328=[],_0x8c6253=0x0,_0x24422d=0x0;for(;_0x8c6253<_0xebc5b4['length']||_0x24422d<_0x5b68f1['length'];){const _0x24911a=_0xebc5b4[_0x8c6253]||{},_0x4ca9cd=_0x5b68f1[_0x24422d]||{};if(_0x24911a['id']==_0x4ca9cd['id'])_0x8c6253++,_0x24422d++,_0x330328['push'](_0x24911a);else{if(_0x4ca9cd['isRemoved']&&_0x24911a['isAdded']){const {commonTape:_0x24735e,iEnd:_0x3d15c1,jEnd:_0x1bf24f}=this['_threeWayMerge'](_0xebc5b4,_0x8c6253,_0x5b68f1,_0x24422d);_0x330328=_0x330328['concat'](_0x24735e),_0x8c6253=_0x3d15c1,_0x24422d=_0x1bf24f;}else _0x4ca9cd['isRemoved']?(_0x24422d++,_0x330328['push'](_0x4ca9cd)):(_0x8c6253++,_0x330328['push'](_0x24911a));}}return _0x330328;}['_markSuggestions'](_0x1f308f,_0x414eed){const _0x763ec6=[];for(let _0xdbb457=0x0;_0xdbb457<_0x1f308f['length'];_0xdbb457++){for(let _0x16b412=0x0;_0x16b412<_0x1f308f[_0xdbb457]['markersStart']['length'];_0x16b412++){const _0x35d605=_0x1f308f[_0xdbb457]['markersStart'][_0x16b412];if(!_0x414eed['has'](_0x35d605))continue;const {group:_0x387e03,type:_0x114d45,authorId:_0x3afd8e}=_0x4a8dbc(_0x35d605);'revision-suggestion'!=_0x387e03||'insertion'!=_0x114d45&&'deletion'!=_0x114d45||(_0x763ec6['unshift']({'type':_0x114d45,'name':_0x35d605,'userId':_0x3afd8e}),_0x1f308f[_0xdbb457]['markersStart']['splice'](_0x16b412,0x1),_0x16b412--);}_0x7f92c8(_0x1f308f[_0xdbb457]);for(let _0x3ba71a=0x0;_0x3ba71a<_0x1f308f[_0xdbb457]['markersEnd']['length'];_0x3ba71a++){const _0x2d180f=_0x1f308f[_0xdbb457]['markersEnd'][_0x3ba71a];if(!_0x414eed['has'](_0x2d180f))continue;const {group:_0x1dc8a2,type:_0xa5c480}=_0x4a8dbc(_0x2d180f);if('revision-suggestion'!=_0x1dc8a2||'insertion'!=_0xa5c480&&'deletion'!=_0xa5c480)continue;_0x1f308f[_0xdbb457]['markersEnd']['splice'](_0x3ba71a,0x1),_0x3ba71a--;const _0x55ad6b=_0x763ec6['findIndex'](_0x4ec709=>_0x4ec709['name']==_0x2d180f);_0x55ad6b>-0x1&&_0x763ec6['splice'](_0x55ad6b,0x1);}}function _0x4a8dbc(_0x4f4be0){const _0x37716c=_0x4f4be0['split'](':');return{'group':_0x37716c[0x0],'type':_0x37716c[0x1],'subType':_0x37716c['length']>=0x5?_0x37716c[0x2]:null,'id':_0x37716c['length']<0x5?_0x37716c[0x2]:_0x37716c[0x3],'authorId':_0x37716c['length']<0x5?_0x37716c[0x3]:_0x37716c[0x4],'markerCount':0x6==_0x37716c['length']?_0x37716c[0x5]:null};}function _0x7f92c8(_0x544a9f){for(let _0x5a8552=0x0;_0x5a8552<_0x763ec6['length'];_0x5a8552++){if(_0x544a9f['isAdded']&&'insertion'==_0x763ec6[_0x5a8552]['type']&&_0x544a9f['isAdded']['userId']==_0x763ec6[_0x5a8552]['userId'])return _0x544a9f['isAddSuggestion']=_0x763ec6[_0x5a8552],void delete _0x544a9f['isAdded'];if(!_0x544a9f['isAdded']&&!_0x544a9f['isRemoved']&&'deletion'==_0x763ec6[_0x5a8552]['type'])return void(_0x544a9f['isRemoveSuggestion']=_0x763ec6[_0x5a8552]);}}}['_setDistance'](_0x35e359,_0x4c1733){let _0x2a906b=0x0,_0x20064f=!0x1;const _0x5af1e5=new Map();for(const _0x5b5125 of _0x35e359)_0x5b5125[_0x4c1733]?_0x20064f&&(_0x2a906b++,_0x20064f=!0x1):(_0x2a906b++,_0x20064f=!0x0),_0x5af1e5['set'](_0x5b5125['id'],_0x2a906b);for(let _0x153e40=0x0;_0x153e40<_0x35e359['length'];_0x153e40++){if('isRemoved'==_0x4c1733&&_0x35e359[_0x153e40]['isAdded']||'isAdded'==_0x4c1733&&_0x35e359[_0x153e40]['isRemoved'])continue;if('text'==_0x35e359[_0x153e40]['type']){_0x35e359[_0x153e40]['distance']=0x0;continue;}const _0xdc6bc0=_0x5af1e5['get'](_0x35e359[_0x153e40]['pairId']),_0x25d17b=_0x5af1e5['get'](_0x35e359[_0x153e40]['id']);_0x35e359[_0x153e40]['distance']=_0xdc6bc0-_0x25d17b;}}['_getRevisionsRange'](_0x30efa8,_0x6e4e21,_0x34a36a=!0x1){const _0x1b998d=[];let _0xfcda71=this['repository']['getIndex'](_0x30efa8),_0x3dffea=this['repository']['getIndex'](_0x6e4e21);for(-0x1==_0x3dffea&&(_0x3dffea=this['repository']['_revisions']['length'],_0x34a36a=!0x1);_0xfcda71<_0x3dffea;)_0x1b998d['push'](this['repository']['getRevision'](_0xfcda71)),_0xfcda71++;return _0x34a36a&&_0x1b998d['push'](this['repository']['getRevision'](_0xfcda71)),_0x1b998d;}['_threeWayMerge'](_0x23f1e5,_0x3c3b2c,_0x5bcdfd,_0xfae694){const _0x7271e9=this['editor']['model']['schema'];let _0x397d38=_0x3c3b2c;for(;_0x23f1e5[_0x397d38]&&_0x23f1e5[_0x397d38]['isAdded'];)_0x397d38++;let _0x342c43=_0xfae694;for(;_0x5bcdfd[_0x342c43]&&_0x5bcdfd[_0x342c43]['isRemoved'];)_0x342c43++;_0x2b9c10(_0x23f1e5,_0x3c3b2c,_0x397d38),_0x2b9c10(_0x5bcdfd,_0xfae694,_0x342c43);const _0xae6e67=_0x5bcdfd['slice'](_0xfae694,_0x342c43)['concat'](_0x23f1e5['slice'](_0x3c3b2c,_0x397d38));return _0xae6e67['sort']((_0x38d59f,_0x40078b)=>_0x38d59f['side']!=_0x40078b['side']?_0x38d59f['side']-_0x40078b['side']:_0x38d59f['level']!=_0x40078b['level']?_0x38d59f['level']-_0x40078b['level']:_0x38d59f['distance']!=_0x40078b['distance']?_0x40078b['distance']-_0x38d59f['distance']:!!_0x38d59f['isAdded']!=!!_0x40078b['isAdded']?-0x1==_0x38d59f['side']||0x0==_0x38d59f['side']?_0x38d59f['isAdded']?-0x1:0x1:_0x38d59f['isAdded']?0x1:-0x1:_0x38d59f['index']-_0x40078b['index']),{'commonTape':_0xae6e67,'iEnd':_0x397d38,'jEnd':_0x342c43};function _0x2b9c10(_0x47996b,_0x205bc0,_0xf5ec9){let _0x844fca=-0x1,_0x118f7b=Number['POSITIVE_INFINITY'],_0x311188=!0x0;for(let _0x55dd49=_0x205bc0;_0x55dd49<_0xf5ec9;_0x55dd49++)if(_0x7271e9['isInline'](_0x47996b[_0x55dd49]['item'])||(_0x311188=!0x1),_0x47996b[_0x55dd49]['item']['startIndex']<_0x205bc0&&(_0x844fca=_0x55dd49),_0x47996b[_0x55dd49]['item']['endIndex']>=_0xf5ec9){_0x118f7b=_0x55dd49;break;}_0x311188&&(_0x844fca=_0xf5ec9-0x1);for(let _0x4e2307=_0x205bc0;_0x4e2307<_0xf5ec9;_0x4e2307++)_0x47996b[_0x4e2307]['side']=_0x4e2307<=_0x844fca?-0x1:_0x4e2307<_0x118f7b?0x0:0x1,_0x47996b[_0x4e2307]['index']=_0x4e2307;let _0x5c0fa0=0x0;for(let _0x3c6214=_0x205bc0;_0x3c6214<=_0x844fca;_0x3c6214++)0x0==_0x47996b[_0x3c6214]['distance']?_0x47996b[_0x3c6214]['level']=_0x5c0fa0:(_0x5c0fa0++,_0x47996b[_0x3c6214]['level']=_0x5c0fa0,_0x5c0fa0++);for(let _0xb3625a=_0x205bc0;_0xb3625a<_0xf5ec9;_0xb3625a++)0x0==_0x47996b[_0xb3625a]['side']&&(_0x47996b[_0xb3625a]['level']=_0x5c0fa0);_0x5c0fa0=0x0;for(let _0xfe5c48=_0xf5ec9-0x1;_0xfe5c48>=_0x118f7b;_0xfe5c48--)0x0==_0x47996b[_0xfe5c48]['distance']?_0x47996b[_0xfe5c48]['level']=_0x5c0fa0:(_0x5c0fa0--,_0x47996b[_0xfe5c48]['level']=_0x5c0fa0,_0x5c0fa0--);}}['_fixObsoleteTags'](_0x1d9c6b){const _0x262b21=new Map(),_0x37fd78=this['editor']['model']['schema'];for(let _0x155731=0x1;_0x155731<_0x1d9c6b['length'];_0x155731++){let _0x487d9b,_0x4b9bf7,_0x4d3956;const _0x500176=_0x1d9c6b[_0x155731],_0xb4f3f9=_0x1d9c6b[_0x155731-0x1];if('text'==_0x500176['type'])continue;if(_0x500176['type']!=_0xb4f3f9['type'])continue;if(!_0x37fd78['isBlock'](_0xb4f3f9['item'])||_0x37fd78['isLimit'](_0xb4f3f9['item']))continue;if(!_0x37fd78['isBlock'](_0x500176['item'])||_0x37fd78['isLimit'](_0x500176['item']))continue;if((_0x1d9c6b[_0x155731]['isAdded']||_0x1d9c6b[_0x155731]['isAddSuggestion'])&&_0x1d9c6b[_0x155731-0x1]['isRemoved'])_0x487d9b=_0x1d9c6b[_0x155731],_0x4b9bf7=_0x1d9c6b[_0x155731-0x1],_0x4d3956=_0x155731-0x1;else{if(!_0x1d9c6b[_0x155731]['isRemoved']||!_0x1d9c6b[_0x155731-0x1]['isAdded']&&!_0x1d9c6b[_0x155731-0x1]['isAddSuggestion'])continue;_0x487d9b=_0x1d9c6b[_0x155731-0x1],_0x4b9bf7=_0x1d9c6b[_0x155731],_0x4d3956=_0x155731;}const _0x4d461b=_0x487d9b['level']==_0x4b9bf7['level'],_0x14bb4b=Math['abs'](_0x487d9b['level'])<Math['abs'](_0x4b9bf7['level'])&&0x0==_0x4b9bf7['distance'];(_0x4d461b||_0x14bb4b)&&(_0x262b21['set'](_0x4b9bf7['id'],_0x487d9b['id']),_0x1d9c6b['splice'](_0x4d3956,0x1),_0x155731--,_0x487d9b['isAdded']=!0x1);}for(let _0x4136f5=0x0;_0x4136f5<_0x1d9c6b['length'];_0x4136f5++)_0x262b21['has'](_0x1d9c6b[_0x4136f5]['pairId'])&&(_0x1d9c6b[_0x4136f5]['pairId']=_0x262b21['get'](_0x1d9c6b[_0x4136f5]['pairId']));}['_removeMissingPairs'](_0x4e1947){const _0x123e89=new Set(_0x4e1947['map'](_0x1ab9c9=>_0x1ab9c9['id']));for(let _0x2750de=0x0;_0x2750de<_0x4e1947['length'];_0x2750de++)_0x123e89['has'](_0x4e1947[_0x2750de]['pairId'])||0x0==_0x4e1947[_0x2750de]['distance']||(_0x4e1947[_0x2750de]['isIncorrect']=!0x0);return _0x4e1947['filter'](_0x352c4a=>!_0x352c4a['isIncorrect']);}['_markMismatchedRemovedTags'](_0x19db1a){const _0x479a41=new Set();for(let _0x132c42=0x0;_0x132c42<_0x19db1a['length'];_0x132c42++){if(_0x479a41['has'](_0x19db1a[_0x132c42]['id'])&&_0x19db1a[_0x132c42]['isRemoved']&&(_0x19db1a[_0x132c42]['isIncorrect']=!0x0),_0x19db1a[_0x132c42]['isIncorrect'])continue;if(0x0==_0x19db1a[_0x132c42]['distance'])continue;if('elementStart'!=_0x19db1a[_0x132c42]['type'])continue;if(null==_0x19db1a[_0x132c42]['pairId'])continue;let _0x4e544a=_0x132c42+0x1,_0x30c4b8=0x0;for(;_0x19db1a[_0x4e544a]['id']!=_0x19db1a[_0x132c42]['pairId'];)'elementStart'==_0x19db1a[_0x4e544a]['type']?_0x30c4b8++:'elementEnd'==_0x19db1a[_0x4e544a]['type']&&_0x30c4b8--,_0x4e544a++;if(0x0!=_0x30c4b8){if(_0x19db1a[_0x132c42]['isRemoved'])_0x19db1a[_0x132c42]['isIncorrect']=!0x0;else{for(;_0x4e544a!=_0x132c42;)_0x19db1a[_0x4e544a]['isRemoved']&&0x0!=_0x19db1a[_0x4e544a]['distance']&&(_0x19db1a[_0x4e544a]['isIncorrect']=!0x0,_0x479a41['add'](_0x19db1a[_0x4e544a]['pairId'])),_0x4e544a--;}}}return _0x19db1a['filter'](_0x5c0d21=>!_0x5c0d21['isIncorrect']);}['_removeUnsupportedChanges'](_0x3787e2){const _0x3d7bf9=this['editor']['model']['schema'];for(let _0x4a7ab1=0x0;_0x4a7ab1<_0x3787e2['length'];_0x4a7ab1++){if(!(_0x3787e2[_0x4a7ab1]['isAdded']||_0x3787e2[_0x4a7ab1]['isAddSuggestion']||_0x3787e2[_0x4a7ab1]['isRemoved']||_0x3787e2[_0x4a7ab1]['isRemoveSuggestion']))continue;if(0x0==_0x3787e2[_0x4a7ab1]['distance'])continue;const _0x30c4f3=_0x3787e2[_0x4a7ab1]['item'];_0x3d7bf9['isBlock'](_0x30c4f3)||_0x3d7bf9['isLimit'](_0x30c4f3)||(_0x3787e2[_0x4a7ab1]['isAdded']&&delete _0x3787e2[_0x4a7ab1]['isAdded'],_0x3787e2[_0x4a7ab1]['isAddSuggestion']&&delete _0x3787e2[_0x4a7ab1]['isAddSuggestion'],_0x3787e2[_0x4a7ab1]['isRemoveSuggestion']&&delete _0x3787e2[_0x4a7ab1]['isRemoveSuggestion'],_0x3787e2[_0x4a7ab1]['isRemoved']&&(_0x3787e2[_0x4a7ab1]['isIncorrect']=!0x0));}return _0x3787e2['filter'](_0x168fe2=>!_0x168fe2['isIncorrect']);}['_makeModelFromTape'](_0x385213,_0x3fb48f,_0x76cc07){const _0x3ce1f9=new _0x5dcd6c(),_0x33b4cb=[],_0x45fcda=new Map(),_0x5388c6=this['editor']['model'],_0x356933=_0x5388c6['schema'],_0x2bd2cb=[_0x3ce1f9],_0x25c53c={},_0x121802={'isAdded':[],'isRemoved':[],'isAddSuggestion':[],'isRemoveSuggestion':[]};let _0x43924e=null;const _0x424975=[0x0];for(let _0x51aa66=0x0;_0x51aa66<_0x385213['length'];_0x51aa66++)if('elementStart'===_0x385213[_0x51aa66]['type']){_0x385213[_0x51aa66]['previousPosition']=_0x5388c6['createPositionFromPath'](_0x3ce1f9,_0x424975);const _0x3ce063=new _0x2d434f(_0x385213[_0x51aa66]['item']['name'],_0x385213[_0x51aa66]['item']['getAttributes']());_0x2bd2cb[0x0]['_appendChild'](_0x3ce063),_0x424975['push'](0x0),_0x2bd2cb['unshift'](_0x3ce063),_0x385213[_0x51aa66]['nextPosition']=_0x5388c6['createPositionFromPath'](_0x3ce1f9,_0x424975);}else'elementEnd'===_0x385213[_0x51aa66]['type']?(_0x2bd2cb['shift'](),_0x385213[_0x51aa66]['previousPosition']=_0x5388c6['createPositionFromPath'](_0x3ce1f9,_0x424975),_0x424975['pop'](),_0x424975[_0x424975['length']-0x1]++,_0x385213[_0x51aa66]['nextPosition']=_0x5388c6['createPositionFromPath'](_0x3ce1f9,_0x424975)):(_0x385213[_0x51aa66]['previousPosition']=_0x5388c6['createPositionFromPath'](_0x3ce1f9,_0x424975),_0x43924e?_0x43924e['_data']+=_0x385213[_0x51aa66]['item']['data']:_0x43924e=new _0x41b5b5(_0x385213[_0x51aa66]['item']['data'],_0x385213[_0x51aa66]['item']['getAttributes']()),_0x385213[_0x51aa66+0x1]&&'text'===_0x385213[_0x51aa66+0x1]['type']&&_0x27a5d8(_0x43924e,_0x385213[_0x51aa66+0x1]['item'])||(_0x2bd2cb[0x0]['_appendChild'](_0x43924e),_0x43924e=null),_0x424975[_0x424975['length']-0x1]+=_0x385213[_0x51aa66]['item']['offsetSize'],_0x385213[_0x51aa66]['nextPosition']=_0x5388c6['createPositionFromPath'](_0x3ce1f9,_0x424975));for(let _0x15819d=0x0;_0x15819d<_0x385213['length'];_0x15819d++){const _0x476a49=_0x385213[_0x15819d]['previousPosition'],_0x583f5a=_0x385213[_0x15819d]['nextPosition'];for(const _0x266f8c of _0x385213[_0x15819d]['markersStart'])_0x45fcda['set'](_0x266f8c,{'start':_0x476a49,'end':null});_0x46096e('isRemoveSuggestion',_0x15819d,_0x476a49,_0x583f5a),_0x46096e('isAddSuggestion',_0x15819d,_0x476a49,_0x583f5a),_0x46096e('isRemoved',_0x15819d,_0x476a49,_0x583f5a),_0x46096e('isAdded',_0x15819d,_0x476a49,_0x583f5a);for(const _0x332d48 of _0x385213[_0x15819d]['markersEnd']){const _0x44802b=_0x45fcda['get'](_0x332d48);_0x44802b?_0x44802b['end']=_0x583f5a:_0x45fcda['set'](_0x332d48,{'start':_0x583f5a,'end':_0x583f5a});}}for(const [_0x5dd0c3,_0x5c09cc]of _0x45fcda){const _0x320721=this['editor']['model']['createRange'](_0x5c09cc['start'],_0x5c09cc['end']);_0x3ce1f9['markers']['set'](_0x5dd0c3,_0x320721);}return _0x33b4cb['sort']((_0x2dac35,_0x4ce631)=>{const _0x4b7484=_0x3ce1f9['markers']['get']('revision:'+_0x2dac35['id']),_0x3fee48=_0x3ce1f9['markers']['get']('revision:'+_0x4ce631['id']);return _0x4b7484['start']['isBefore'](_0x3fee48['start'])?-0x1:_0x4b7484['start']['isAfter'](_0x3fee48['start'])?0x1:_0x4b7484['end']['isBefore'](_0x3fee48['end'])?-0x1:_0x4b7484['end']['isAfter'](_0x3fee48['end'])?0x1:'add'===_0x2dac35['type']?-0x1:0x1;}),{'root':_0x3ce1f9,'changes':_0x33b4cb};function _0x46096e(_0x1fdf3a,_0x198c9f,_0x118276,_0x4565be){const _0xa4be84=!!_0x385213[_0x198c9f][_0x1fdf3a],_0xc928d8=_0xa4be84?_0x385213[_0x198c9f][_0x1fdf3a]['userId']:null,_0x2d7f47=_0x198c9f===_0x385213['length']-0x1,_0xbe223=_0x121802[_0x1fdf3a][0x0],_0x21274a=_0x356933['isObject'](_0x385213[_0x198c9f]['item']);!_0x25c53c[_0x1fdf3a]&&_0xa4be84?_0x25c53c[_0x1fdf3a]={'start':_0x118276,'tapeItem':_0x385213[_0x198c9f],'userId':_0xc928d8,'type':_0x1fdf3a}:_0x25c53c[_0x1fdf3a]&&!_0xa4be84?(_0x25c53c[_0x1fdf3a]['end']=_0x118276,_0x25130e(_0x25c53c[_0x1fdf3a]),_0x25c53c[_0x1fdf3a]=null):_0x25c53c[_0x1fdf3a]&&_0xa4be84&&_0x25c53c[_0x1fdf3a]['userId']!==_0xc928d8&&(_0x25c53c[_0x1fdf3a]['end']=_0x118276,_0xbe223&&_0xbe223['userId']===_0x25c53c[_0x1fdf3a]['userId']||_0x25130e(_0x25c53c[_0x1fdf3a]),_0x25c53c[_0x1fdf3a]={'start':_0x118276,'tapeItem':_0x385213[_0x198c9f],'userId':_0xc928d8,'type':_0x1fdf3a}),_0x25c53c[_0x1fdf3a]&&_0x21274a&&('elementStart'!==_0x385213[_0x198c9f]['type']||_0xbe223&&_0xbe223['userId']===_0xc928d8||_0x121802[_0x1fdf3a]['unshift']({'userId':_0xc928d8,'object':_0x385213[_0x198c9f]['item'],'change':_0x25c53c[_0x1fdf3a]}),'elementEnd'===_0x385213[_0x198c9f]['type']&&_0xbe223&&_0xbe223['object']===_0x385213[_0x198c9f]['item']&&(_0x121802[_0x1fdf3a]['shift'](),_0x25c53c[_0x1fdf3a]=_0xbe223['change'])),_0x25c53c[_0x1fdf3a]&&_0x2d7f47&&(_0x25c53c[_0x1fdf3a]['end']=_0x4565be,_0x25130e(_0x25c53c[_0x1fdf3a]),_0x25c53c[_0x1fdf3a]=null);}function _0x25130e({start:_0xba1b8f,end:_0x21ba59,tapeItem:_0x45964d,userId:_0x4b7c57,type:_0x52de3a}){const _0x4a264d=_0x45964d['item'],_0x1f6705=_0x5388c6['schema']['isBlock'](_0x4a264d)&&!_0x5388c6['schema']['isLimit'](_0x4a264d),_0x1f06a1=_0xba1b8f['nodeAfter']==_0x21ba59['parent']&&_0x21ba59['isAtStart'];if(_0x1f6705&&_0x1f06a1)return;const _0x2865bf=_0x5388c6['createRange'](_0xba1b8f,_0x21ba59),_0xc225fb=_0x3fb48f['get'](_0x4b7c57),_0x1f58eb=new G({'author':_0xc225fb,'type':'isAdded'==_0x52de3a||'isAddSuggestion'==_0x52de3a?'add':'remove','data':{'isSuggestion':'isAddSuggestion'==_0x52de3a||'isRemoveSuggestion'==_0x52de3a},'createdAt':new Date(),'rootName':_0x76cc07});_0x33b4cb['push'](_0x1f58eb),_0x3ce1f9['markers']['set']('revision:'+_0x1f58eb['id'],_0x2865bf);}function _0x27a5d8(_0x3e9938,_0x454543){const _0x3ce236=_0x3e9938['getAttributes'](),_0x2e115d=_0x454543['getAttributes']();for(const _0x58fa6c of _0x3ce236){if(_0x58fa6c[0x1]!==_0x454543['getAttribute'](_0x58fa6c[0x0]))return!0x1;_0x2e115d['next']();}return _0x2e115d['next']()['done'];}}['_setConversion'](){this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision','view':_0x331e65=>{const _0x233005=_0x331e65['markerName']['split'](':')[0x1],_0x426f81=this['_getChangeFromId'](_0x233005);if(!_0x426f81)return null;const _0x2132c7='add'==_0x426f81['type']?'insertion':'deletion',_0x3cad93=['ck-suggestion-marker','ck-suggestion-marker-'+_0x2132c7];return _0x426f81['data']['isSuggestion']&&_0x3cad93['push']('ck-suggestion-marker-'+_0x2132c7+'-new'),this['activeChange']==_0x426f81&&_0x3cad93['push']('ck-suggestion-marker--active'),{'classes':_0x3cad93,'attributes':{'data-change-id':_0x233005}};}}),this['editor']['conversion']['for']('upcast')['add'](_0x346712=>{_0x346712['on']('element:pre',(_0x254662,_0x1c8d74,_0x55cee8)=>{const _0x480d06=_0x1c8d74['viewItem']['getChild'](0x0);if(!_0x480d06||!_0x480d06['is']('element','code'))return;if(!_0x55cee8['consumable']['consume'](_0x480d06,{'attributes':['vid_start','vid_end']}))return;const _0x2e37f1=_0x1c8d74['modelRange']['start']['nodeAfter'];_0x55cee8['writer']['setAttribute']('vid_start',_0x480d06['getAttribute']('vid_start'),_0x2e37f1),_0x55cee8['writer']['setAttribute']('vid_end',_0x480d06['getAttribute']('vid_end'),_0x2e37f1);},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['add'](_0x27d9a8=>{_0x27d9a8['on']('element',(_0x19181a,_0x10ae3f,_0x3b7713)=>{if(!_0x3b7713['consumable']['consume'](_0x10ae3f['viewItem'],{'attributes':['vid_start','vid_end']}))return;if(_0x10ae3f['modelRange']['isCollapsed'])return;const _0x765732=_0x10ae3f['modelRange']['start']['nodeAfter'];_0x765732['hasAttribute']('vid_start')||_0x765732['hasAttribute']('vid')||(_0x3b7713['writer']['setAttribute']('vid_start',_0x10ae3f['viewItem']['getAttribute']('vid_start'),_0x765732),_0x3b7713['writer']['setAttribute']('vid_end',_0x10ae3f['viewItem']['getAttribute']('vid_end'),_0x765732));},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['elementToAttribute']({'view':{'name':'span','attributes':{'vid':!0x0}},'model':{'key':'vid','value':_0x52f5be=>_0x52f5be['getAttribute']('vid')}}),this['editor']['model']['schema']['on']('checkAttribute',(_0x1fa6ef,[,_0x6ff02])=>{['vid_start','vid_end','vid']['includes'](_0x6ff02)&&(_0x1fa6ef['return']=!0x0,_0x1fa6ef['stop']());},{'priority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x53adb6=>{_0x53adb6['on']('attribute:vid',(_0x5d7668,_0x4caf13,_0x1adb2e)=>{if('\x20'!=_0x4caf13['item']['data']||_0x4caf13['item']['parent']['maxOffset']>0x1)return;if(!_0x1adb2e['consumable']['consume'](_0x4caf13['item'],_0x5d7668['name']))return;const _0x230c9e=_0x1adb2e['writer'],_0xd65e53=_0x1adb2e['mapper']['toViewRange'](_0x4caf13['range']);_0x230c9e['wrap'](_0xd65e53,_0x230c9e['createAttributeElement']('span'));});}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',function(_0x44c346){const _0xf54561=_0x44c346['plugins']['get']('RevisionViewer');return(_0x4f5e96,_0x226dd1,_0x18c079)=>{const _0x7b4679=_0x226dd1['markerName']['split'](':')[0x1],_0x492f99=_0xf54561['_getChangeFromId'](_0x7b4679);if(!_0x492f99)return null;const _0x13e706='add'==_0x492f99['type']?'split':'merge';if(!_0x18c079['consumable']['test'](_0x226dd1['markerRange'],_0x4f5e96['name']))return;const _0x4e3187=_0x226dd1['markerRange']['getWalker'](),_0x571c8e=_0x226dd1['markerRange']['start'],_0x3314bc=_0x44c346['model']['schema'];let _0x3e324a=null,_0x1d5950=null,_0x1bff61=!0x1,_0x2c6c4b=!0x1;for(const _0xab0974 of _0x4e3187){const _0x50dd97=_0xab0974['item'];_0x1bff61=_0x1bff61||_0x3314bc['isContent'](_0x50dd97);const _0x3be7ff=_0x18c079['mapper']['toViewElement'](_0x50dd97);if(_0x3be7ff&&_0x3be7ff['getCustomProperty']('addHighlight'))return;'elementEnd'==_0xab0974['type']&&(_0x3314bc['isBlock'](_0x50dd97)&&!_0x3314bc['isLimit'](_0x50dd97)&&(_0x50dd97['nextSibling']||_0x571c8e['isAtEnd']?_0x3e324a&&_0x3e324a['parent']==_0x50dd97||(_0x3e324a=_0x50dd97,_0x2246fb(_0xab0974['previousPosition']),_0x2c6c4b=!0x0):_0x1d5950=_0x1d5950||_0xab0974['previousPosition']));}function _0x2246fb(_0x526f48){const _0x520596=_0x18c079['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x13e706}),_0x1d3e34=_0x18c079['mapper']['toViewPosition'](_0x526f48);_0x492f99['data']['isSuggestion']&&_0x18c079['writer']['addClass']('ck-suggestion-marker-'+_0x13e706+'-new',_0x520596),_0xf54561['activeChange']==_0x492f99&&_0x18c079['writer']['addClass']('ck-suggestion-marker--active',_0x520596),_0x18c079['writer']['insert'](_0x1d3e34,_0x520596),_0x18c079['mapper']['bindElementToMarker'](_0x520596,_0x226dd1['markerName']);}_0x1bff61||_0x2c6c4b||!_0x1d5950||_0x2246fb(_0x1d5950);};}(this['editor']),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision',(_0x567dc5,_0x573c76,_0x386dec)=>{const _0x4522b6=_0x386dec['mapper']['markerNameToElements'](_0x573c76['markerName']);if(_0x4522b6){for(const _0x23291f of _0x4522b6)(_0x23291f['hasClass']('ck-suggestion-marker-split')||_0x23291f['hasClass']('ck-suggestion-marker-merge'))&&(_0x386dec['mapper']['unbindElementFromMarkerName'](_0x23291f,_0x573c76['markerName']),_0x386dec['writer']['remove'](_0x23291f));}},{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',(_0x246319,_0xa5b018,_0x59050c)=>{const _0x111073=_0xa5b018['markerName']['split'](':')[0x1],_0x1b0e96=this['_getChangeFromId'](_0x111073);if(!_0x1b0e96)return null;const _0x58698c='add'==_0x1b0e96['type']?'split':'merge';if(_0x59050c['consumable']['test'](_0xa5b018['markerRange'],_0x246319['name']))for(const _0x5a6842 of _0xa5b018['markerRange']['getItems']()){if(!_0x5a6842['is']('element','softBreak'))continue;const _0x1347cb=_0x59050c['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x58698c}),_0x256c73=_0x59050c['mapper']['toViewPosition'](this['editor']['model']['createPositionBefore'](_0x5a6842));_0x1b0e96['data']['isSuggestion']&&_0x59050c['writer']['addClass']('ck-suggestion-marker-'+_0x58698c+'-new',_0x1347cb),this['activeChange']==_0x1b0e96&&_0x59050c['writer']['addClass']('ck-suggestion-marker--active',_0x1347cb),_0x59050c['writer']['insert'](_0x256c73,_0x1347cb),_0x59050c['mapper']['bindElementToMarker'](_0x1347cb,_0xa5b018['markerName']);}},{'priority':'high'}),this['editor']['model']['document']['on']('change',()=>{this['editor']['editing']['view']['change'](_0x2a9dae=>{for(const _0x1f52d2 of this['editor']['model']['document']['getRootNames']()){const _0xed2703=this['editor']['model']['document']['getRoot'](_0x1f52d2),_0x37aa71=this['editor']['editing']['view']['document']['getRoot'](_0x1f52d2);if(_0x37aa71){const _0x5f41bf=_0xed2703['getAttribute']('revisionHistoryAttachChange');if(_0x2a9dae['removeAttribute']('data-change-id',_0x37aa71),_0x2a9dae['removeClass']('ck-revision-history-root-add',_0x37aa71),_0x2a9dae['removeClass']('ck-revision-history-root-remove',_0x37aa71),_0x2a9dae['removeClass']('ck-revision-history-root--active',_0x37aa71),_0x5f41bf){const _0xf08045=this['_getChangeFromId'](_0x5f41bf);if(!_0xf08045)return null;_0x2a9dae['setAttribute']('data-change-id',_0x5f41bf,_0x37aa71),_0x2a9dae['addClass']('ck-revision-history-root-'+_0xf08045['type'],_0x37aa71),this['activeChange']==_0xf08045&&_0x2a9dae['addClass']('ck-revision-history-root--active',_0x37aa71);}}}});}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'comment','model':_0x349dfe=>'revision-comment:'+_0x349dfe,'converterPriority':'highest'}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'suggestion','model':_0x5dd5cd=>'revision-suggestion:'+_0x5dd5cd,'converterPriority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision-suggestion','view':_0x4d8d34=>({'name':'suggestion:'+_0x4d8d34,'group':'revision-suggestion'}),'converterPriority':'highest'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision-suggestion','view':_0x57ae9a=>{const _0x48840c=_0x57ae9a['markerName']['split'](':')[0x1];return'insertion'!=_0x48840c&&'deletion'!=_0x48840c?null:{'classes':['ck-suggestion-preview-marker','ck-suggestion-preview-marker-'+_0x48840c]};}}),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',(_0xa06219,_0x273b84,_0x53a4fb)=>{const _0x12dc10=_0x53a4fb['mapper']['markerNameToElements'](_0x273b84['markerName']);if(_0x12dc10){for(const _0x391909 of _0x12dc10)_0x391909['is']('uiElement')&&(_0x53a4fb['mapper']['unbindElementFromMarkerName'](_0x391909,_0x273b84['markerName']),_0x53a4fb['writer']['remove'](_0x391909));}},{'priority':'high'});}['_getChangeFromId'](_0x40ae8e){return this['_changeIdToChange']['get'](_0x40ae8e);}['_getViewForChange'](_0x1dbe39){return this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=new z(this['editor']['locale'],_0x1dbe39),this['_changeView'];}['_initInteractions'](){this['editor']['model']['document']['selection']['observeMarkers']('revision'),this['on']('change:activeView',(_0x366723,_0x2d9906,_0x3982c3,_0x5d08ca)=>{_0x5d08ca&&this['_balloon']['remove'](_0x5d08ca),_0x3982c3&&(this['_balloon']['add']({'view':_0x3982c3,'stackId':'revisionHistoryLabel','position':{'target':()=>{const _0x2d5d07=this['editor']['editing'],_0x213def=this['_getChangeFromId'](_0x3982c3['changeId']);let _0x266ed7;if(_0x213def['data']['isOnRoot']){const _0x5f40df=_0x2d5d07['view']['getDomRoot'](_0x213def['rootName']);_0x266ed7=Array['from'](_0x5f40df['getClientRects']());}else{const _0x516337=this['editor']['model']['markers']['get']('revision:'+_0x3982c3['changeId']);_0x266ed7=Array['from'](_0x2d5d07['mapper']['markerNameToElements'](_0x516337['name']))['map'](_0x33f30e=>_0x2d5d07['view']['domConverter']['mapViewToDom'](_0x33f30e))['map'](_0x172ef7=>Array['from'](_0x172ef7['getClientRects']()))['flat']();}if(!this['_activeViewTarget'])return _0x266ed7[0x0];return _0x266ed7['find'](_0x3da15b=>_0x3da15b['top']-0x3<=this['_activeViewTarget']['y']&&_0x3da15b['bottom']+0x3>=this['_activeViewTarget']['y']&&_0x3da15b['left']-0x3<=this['_activeViewTarget']['x']&&_0x3da15b['right']+0x3>=this['_activeViewTarget']['x'])||_0x266ed7[0x0];}}}),this['_balloon']['showStack']('revisionHistoryLabel'));}),this['on']('change:activeChange',(_0x502c1e,_0x86f553,_0x585566,_0x1e2334)=>{this['activeView']=_0x585566?this['_getViewForChange'](_0x585566):null,this['editor']['model']['change'](()=>{const _0x154666=this['editor']['editing'];_0x1e2334&&(_0x1e2334['data']['isOnRoot']?_0x154666['view']['change'](_0x58db67=>{_0x58db67['removeClass']('ck-revision-history-root--active',_0x154666['view']['document']['getRoot'](_0x1e2334['rootName']));}):_0x154666['reconvertMarker']('revision:'+_0x1e2334['id'])),_0x585566&&(_0x585566['data']['isOnRoot']?_0x154666['view']['change'](_0x153201=>{_0x153201['addClass']('ck-revision-history-root--active',_0x154666['view']['document']['getRoot'](_0x585566['rootName']));}):_0x154666['reconvertMarker']('revision:'+_0x585566['id']));});}),this['listenTo'](this['editor']['editing']['view']['document'],'mouseover',(_0x50192b,_0x181bda)=>{if(this['activeChange'])return;const _0x1ecf7b=this['_findChangeIdFromDomTarget'](_0x181bda['target']),_0x598a77=this['_changeIdToChange']['get'](_0x1ecf7b);_0x598a77?(this['_activeViewTarget']={'x':_0x181bda['domEvent']['x'],'y':_0x181bda['domEvent']['y']},this['activeView']=this['_getViewForChange'](_0x598a77)):(this['_activeViewTarget']=null,this['activeView']=null);}),this['listenTo'](this['editor']['editing']['view']['document'],'mousedown',(_0x5021ea,_0x37dc81)=>{const _0x52cc7d=this['_findChangeIdFromDomTarget'](_0x37dc81['target']),_0x4fc446=this['_changeIdToChange']['get'](_0x52cc7d);_0x4fc446?(this['_activeViewTarget']={'x':_0x37dc81['domEvent']['x'],'y':_0x37dc81['domEvent']['y']},_0x4fc446===this['activeChange']?this['_balloon']['updatePosition']():this['activeChange']=_0x4fc446):(this['_activeViewTarget']=null,this['activeChange']=null);});}['_findChangeIdFromDomTarget'](_0xab2636){do{const _0x38a432=_0xab2636['getAttribute']('data-change-id');if(_0x38a432)return _0x38a432;_0xab2636=_0xab2636['parent'];}while(_0xab2636);return null;}['_cleanMarkers'](){this['editor']['model']['change'](_0x5eae09=>{for(const _0x48113a of this['editor']['model']['markers'])_0x5eae09['removeMarker'](_0x48113a);});}}function Q(_0x3bb4f5,_0x1e7061){return(_0x353970,_0x10d76b,_0x3bb173)=>{if(!_0x3bb173['consumable']['test'](_0x10d76b['markerRange'],_0x353970['name']))return;const _0xf1b602=_0x10d76b['markerRange']['getWalker'](),_0x3ba584=_0x10d76b['markerRange']['start'],_0x15d5ef=_0x3bb4f5['model']['schema'];let _0x4184fc=null,_0x3a114e=null,_0x2e9fd4=!0x1,_0x49f49e=!0x1;for(const _0x59a5d5 of _0xf1b602){const _0x15029c=_0x59a5d5['item'];_0x2e9fd4=_0x2e9fd4||_0x15d5ef['isContent'](_0x15029c);const _0x57e31d=_0x3bb173['mapper']['toViewElement'](_0x15029c);if(_0x57e31d&&_0x57e31d['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x59a5d5['type']&&(_0x15d5ef['isBlock'](_0x15029c)&&!_0x15d5ef['isLimit'](_0x15029c)&&(_0x15029c['nextSibling']||_0x3ba584['isAtEnd']?_0x4184fc&&_0x4184fc['parent']==_0x15029c||(_0x4184fc=_0x15029c,_0x46f35f(_0x59a5d5['previousPosition']),_0x49f49e=!0x0):_0x3a114e=_0x3a114e||_0x59a5d5['previousPosition']));}function _0x46f35f(_0xd895da){const _0x2dc8c2=_0x3bb173['mapper']['toViewPosition'](_0xd895da),_0x3378b6=_0x3bb173['writer']['createUIElement']('span',{'class':'ck-suggestion-preview-marker-'+_0x1e7061});_0x3bb173['writer']['insert'](_0x2dc8c2,_0x3378b6),_0x3bb173['mapper']['bindElementToMarker'](_0x3378b6,_0x10d76b['markerName']);}_0x2e9fd4||_0x49f49e||!_0x3a114e||_0x46f35f(_0x3a114e);};}class nt extends _0x439955{constructor(_0x5854b6){super(_0x5854b6);const _0x2e25b8=_0x5854b6['plugins']['get'](l);this['affectsData']=!0x1,this['listenTo'](_0x2e25b8,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x2e25b8,'change:isEnabled',()=>this['refresh']());}['execute'](){const _0x5250c2=this['editor'],_0x2c184a=_0x5250c2['plugins']['get'](l),_0x52bfde=_0x2c184a['isReady']?_0x2c184a['diff']['newRevisionId']:null;_0x5250c2['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x52bfde);}['refresh'](){const {isReady:_0x575dc7,isEnabled:_0x4126ef,repository:_0x44943,diff:_0x3455ca}=this['editor']['plugins']['get'](l),_0x5b2084=_0x3455ca&&_0x44943['getLaterVisibleRevision'](_0x3455ca['newRevisionId']);this['isEnabled']=_0x575dc7&&_0x4126ef&&Boolean(_0x5b2084);}}class rt extends _0x439955{['_step'];constructor(_0x47b66e,{direction:_0x36119e}){super(_0x47b66e);const _0x48d00c=_0x47b66e['plugins']['get'](l);this['affectsData']=!0x1,this['_step']='forward'===_0x36119e?0x1:-0x1,this['listenTo'](_0x48d00c,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x48d00c,'change:isEnabled',()=>this['refresh']()),this['listenTo'](_0x48d00c,'change:activeChange',()=>this['refresh']());}['execute'](){const _0xb3c88b=this['editor'],_0x42974d=_0xb3c88b['plugins']['get'](l),{isNavigationMode:_0x1f8f9d,currentChangeNumber:_0x3c5cb4}=_0x42974d;let _0x50c654;if(_0x42974d['activeChange']=_0x1f8f9d?_0x42974d['diff']['changes']['get'](_0x3c5cb4+this['_step']):_0x42974d['diff']['changes']['first'],_0x42974d['activeChange']['data']['isOnRoot'])_0x50c654=_0xb3c88b['editing']['view']['getDomRoot'](_0x42974d['activeChange']['rootName']);else{const _0x38e0d6=_0xb3c88b['model']['markers']['get']('revision:'+_0x42974d['activeChange']['id']);_0x50c654=_0x4aa28c(_0xb3c88b['editing'],_0x38e0d6);}_0x234f22({'target':_0x50c654,'viewportOffset':0x28});}['refresh'](){const {isNavigationMode:_0x3fb4e3,currentChangeNumber:_0x3df021,numberOfChanges:_0x4d2cdd,isReady:_0x51de07,isEnabled:_0x29b22c}=this['editor']['plugins']['get'](l);this['isEnabled']=!!(_0x29b22c&&_0x51de07&&_0x4d2cdd)&&(!_0x3fb4e3||(0x1===this['_step']?_0x3df021<_0x4d2cdd-0x1:_0x3df021>0x0));}}class fi extends _0x2027a1{constructor(_0x5557d3){super(_0x5557d3);const _0x52f125=this['bindTemplate'],_0xb61028=new _0x304609(_0x5557d3),_0x5554be=new _0x304609(_0x5557d3);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',(_0x46444f,_0x34c489)=>_0x46444f&&_0x34c489>0x0),this['bind']('_statusText')['to'](this,'isReady',this,'currentChangeNumber',this,'numberOfChanges',this,'isNavigationMode',(_0x1fc80b,_0x410eb3,_0x3fc9b7,_0x428f26)=>{if(!_0x1fc80b)return R(_0x5557d3,'Loading...');if(!_0x3fc9b7)return R(_0x5557d3,'No\x20changes');const _0x2b1a04=R(_0x5557d3,'NUMBER_OF_CHANGES',_0x3fc9b7);return _0x428f26?R(_0x5557d3,'X_OF_Y_CHANGES',[_0x410eb3+0x1,_0x3fc9b7]):_0x2b1a04;}),_0xb61028['set']({'label':R(_0x5557d3,'Show\x20previous\x20change'),'tooltip':!0x0,'icon':_0x5b0108}),_0x5554be['set']({'label':R(_0x5557d3,'Show\x20next\x20change'),'tooltip':!0x0,'icon':_0x24f5ef}),_0xb61028['bind']('isEnabled')['to'](this,'isBackwardNavigationEnabled'),_0x5554be['bind']('isEnabled')['to'](this,'isForwardNavigationEnabled'),_0xb61028['on']('execute',()=>this['fire']('execute','backward')),_0x5554be['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',_0x52f125['if']('_isStatusLabelVisible','ck-hidden',_0x5c4089=>!_0x5c4089)]},'children':[{'text':_0x52f125['to']('isNavigationMode',_0x5ca375=>_0x5ca375?R(_0x5557d3,'EDIT_X_OF_Y_REVISIONS')+':\x20':R(_0x5557d3,'Total')+':\x20')}]},{'text':_0x52f125['to']('_statusText')}]},new _0x45456d(),{'tag':'div','attributes':{'class':['ck-revision-history-ui__changes-navigation__navigation']},'children':[_0xb61028,_0x5554be]}]});}}const ge='ck-editor__editable__loading-overlay';class bi extends _0x3daf77{static get['pluginName'](){return'RevisionViewerLoadingOverlay';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['show'](){const _0x253e0a=this['editor']['editing']['view'];_0x253e0a['change'](_0x707011=>{for(const _0x3bee1a of _0x253e0a['document']['roots'])_0x707011['addClass'](ge,_0x3bee1a);});}['hide'](){const _0x4e4aea=this['editor']['editing']['view'];_0x4e4aea['change'](_0x151aa6=>{for(const _0x118043 of _0x4e4aea['document']['roots'])_0x151aa6['removeClass'](ge,_0x118043);});}}class u extends _0x3daf77{static get['pluginName'](){return'RevisionViewerUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[l,bi];}['init'](){const _0x1eaf1f=this['editor'],_0x1d73d1=_0x1eaf1f['plugins']['get'](l),_0x22eb78=_0x1eaf1f['plugins']['get'](bi);_0x1eaf1f['ui']['componentFactory']['add']('exitToEditing',_0x4b36eb=>{const _0x4a1e55=new _0x304609(_0x4b36eb);return _0x4a1e55['set']({'label':R(_0x4b36eb,'Back\x20to\x20editing'),'icon':_0xc406e8,'withText':!0x0,'tooltip':!0x0,'class':'ck-revision-history-ui__back-to-editing'}),this['listenTo'](_0x4a1e55,'execute',()=>{_0x1eaf1f['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}),_0x4a1e55;}),_0x1eaf1f['ui']['componentFactory']['add']('restoreRevision',_0x236532=>{const _0x186c23=new _0x304609(_0x236532);return _0x186c23['set']({'label':R(_0x236532,'Restore\x20this\x20revision'),'withText':!0x0,'tooltip':!0x0}),_0x186c23['bind']('isEnabled')['to'](_0x1eaf1f['commands']['get']('restoreRevision')),this['listenTo'](_0x186c23,'execute',()=>_0x1eaf1f['execute']('restoreRevision')),_0x186c23;}),_0x1eaf1f['ui']['componentFactory']['add']('changesNavigation',_0x357256=>{const _0x45ac5f=new fi(_0x357256),_0x4c6279=_0x1eaf1f['commands']['get']('showPreviousChange'),_0x398536=_0x1eaf1f['commands']['get']('showNextChange');return _0x45ac5f['bind']('isBackwardNavigationEnabled')['to'](_0x4c6279,'isEnabled'),_0x45ac5f['bind']('isForwardNavigationEnabled')['to'](_0x398536,'isEnabled'),_0x45ac5f['bind']('isReady','currentChangeNumber','numberOfChanges','isNavigationMode')['to'](_0x1d73d1),this['listenTo'](_0x45ac5f,'execute',(_0x39fde3,_0x35f945)=>{_0x1eaf1f['execute']('forward'===_0x35f945?'showNextChange':'showPreviousChange');}),_0x45ac5f;}),_0x22eb78['show'](),_0x1d73d1['on']('change:isReady',(_0x195594,_0xadb9e1,_0x9efe9c)=>{_0x9efe9c?_0x22eb78['hide']():_0x22eb78['show']();});}}class hi extends et{['_resizeObserver']=null;constructor(_0x2f9fc1,_0x122f7e){super(_0x2f9fc1,_0x122f7e);const _0x55803b=this['bindTemplate'];this['set']({'label':R(_0x2f9fc1,'Revision\x20name'),'_tooltipString':''}),this['fieldView']['placeholder']=R(_0x2f9fc1,'Enter\x20the\x20revision\x20name'),this['extendTemplate']({'tag':'span','attributes':{'class':['ck-revision-history-sidebar__revision-name'],'data-cke-tooltip-text':_0x55803b['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 _0x222274=this['fieldView']['element'];this['_tooltipString']=_0x222274['scrollWidth']>_0x222274['clientWidth']&&_0x222274['value']||'';}}class ni extends _0x2027a1{constructor(_0x16578f,_0x40d669,_0x9f9014){super(_0x16578f);const _0x13083b=new _0x4e4b3c();_0x13083b['set']({'content':_0x5132bd,'viewBox':'0\x200\x2011\x2010'});const _0x4d63c0=['ck','ck-revision-history-sidebar__revision-author'];_0x9f9014&&_0x4d63c0['push']('ck-revision-history-sidebar__revision-author_creator');const _0x477497=[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision-author__name'],'title':R(_0x16578f,_0x9f9014?'Revision\x20creator':'Revision\x20author')},'children':[_0x13083b,_0x40d669['name']]}];this['setTemplate']({'tag':'li','attributes':{'class':_0x4d63c0},'children':_0x477497});}}function ci(_0xb90f12,_0x3bd72a){const _0x5c4070=_0xb90f12['bindTemplate'],_0x19c1b5=_0xb90f12['locale'],_0x39240e=_0x261f45(_0x19c1b5);_0x39240e['panelPosition']='sw';const _0x25f316=function(_0x1037d6,_0x333cd7){const _0x4f2b21=function(_0x55b200,_0x43f472){const _0x2e833d=_0x55b200['locale'],_0x2b7dec={'Compare\x20against\x20selected':R(_0x2e833d,'Compare\x20against\x20selected'),'Name\x20this\x20revision':R(_0x2e833d,'Name\x20this\x20revision'),'Restore\x20this\x20revision':R(_0x2e833d,'Restore\x20this\x20revision')};return _0x43f472['map'](_0x576fe5=>{const _0xe12612=_0x2b7dec[_0x576fe5['name']];return _0xe12612&&_0xe12612!==_0x576fe5['name']&&(_0x576fe5['name']=_0xe12612),_0x576fe5;});}(_0x1037d6,_0x333cd7),_0xc2c8af=new _0x485594();for(const _0x481b72 of _0x4f2b21){const _0x4dd811={'type':'button','model':new to({'label':_0x481b72['name'],'class':_0x481b72['class'],'withText':!0x0,'role':'menuitem','_action':_0x481b72['action']})};_0x4dd811['model']['bind']('isEnabled')['to'](_0x1037d6,'isActionsDropdownOpen',_0x1eaf24=>'function'!=typeof _0x481b72['isEnabled']||(!_0x1eaf24||_0x481b72['isEnabled'](_0x1037d6))),_0xc2c8af['add'](_0x4dd811);}return _0xc2c8af;}(_0xb90f12,_0x3bd72a);return _0xb90f12['bind']('isActionsDropdownOpen')['to'](_0x39240e,'isOpen'),_0x39240e['buttonView']['set']({'label':R(_0x19c1b5,'Show\x20more\x20items'),'tooltip':!0x0,'tooltipPosition':'sw','icon':_0x25fb16}),_0x39240e['extendTemplate']({'attributes':{'class':['ck-revision-history-sidebar__revision__actions',_0x5c4070['if']('isActionsDropdownOpen','ck-on')]},'on':{'click':_0x5c4070['to'](_0x5b4f9c=>_0x5b4f9c['stopPropagation']())}}),_0x39240e['on']('execute',_0x18dd3d=>{_0xb90f12['isReady']&&'function'==typeof _0x18dd3d['source']['_action']&&_0x18dd3d['source']['_action'](_0xb90f12);}),_0x242355(_0x39240e,_0x25f316,{'role':'menu'}),_0x39240e['listenTo'](_0xb90f12,'change:isActionsDropdownOpen',(_0x5acc00,_0x3b7d27,_0x16cc64)=>{if(_0x16cc64)for(const _0x57cf30 of _0x39240e['listView']['items']){const _0x3d758a=_0x57cf30['children']['first'],_0x1b5e66=_0x3bd72a['find'](_0x69243f=>_0x69243f['action']===_0x3d758a['_action'])['isVisible'];_0x57cf30['isVisible']=void 0x0===_0x1b5e66||_0x1b5e66(_0xb90f12);}}),_0x39240e;}class _i extends/* #__PURE__ -- @preserve */
|
|
27
|
+
_0x5d1b3d(_0x2027a1){['id'];['revisionNameView'];['revisionActionsView'];['_revision'];['_requireRevisionName'];constructor(_0x61e01f,_0x35c920,_0x5b34c1,_0x2025ab){super(_0x61e01f);const _0x9085c1=this['bindTemplate'],_0x1dabe5=function(_0x4fe894,_0x2c09bc){const _0x1a7abc=Array['from'](_0x2c09bc['authors'])['filter'](_0x470e12=>_0x470e12!=_0x2c09bc['creator']);return _0x2c09bc['creator']&&_0x1a7abc['unshift'](_0x2c09bc['creator']),_0x1a7abc['map'](_0x3b69db=>new ni(_0x4fe894,_0x3b69db,_0x3b69db==_0x2c09bc['creator']));}(_0x61e01f,_0x35c920);this['id']=_0x35c920['id'],this['_revision']=_0x35c920,this['_requireRevisionName']=_0x2025ab,this['bind']('name','createdAt')['to'](_0x35c920),this['bind']('_createdAtFormatted')['to'](this,'createdAt',_0x42bcea=>{return _0x11fd3a=_0x61e01f['uiLanguage'],(_0x4e8f2c=_0x42bcea)['toLocaleDateString'](_0x11fd3a,{'month':'long','day':'numeric'})+',\x20'+_0x4e8f2c['toLocaleTimeString'](_0x11fd3a,{'hour':'numeric','minute':'numeric'});var _0x11fd3a,_0x4e8f2c;}),this['set']('isSelected',!0x1),this['set']('isHighlighted',!0x1),this['set']('isActionsDropdownOpen',!0x1),this['set']('isReady',!0x1),this['set']('isEnabled',!0x1),this['revisionNameView']=new hi(_0x61e01f,ti),this['revisionNameView']['fieldView']['extendTemplate']({'attributes':{'maxlength':'220'}}),this['revisionNameView']['fieldView']['bind']('value')['to'](this,'name',_0x49189c=>_0x49189c||this['_createdAtFormatted']),this['revisionNameView']['bind']('isEnabled')['to'](this,'isSelected',this,'isEnabled',(_0x35fd6a,_0x45848a)=>_0x35fd6a&&_0x45848a),this['revisionActionsView']=_0x5b34c1&&_0x5b34c1['length']?ci(this,_0x5b34c1):'',this['revisionActionsView']&&this['revisionActionsView']['bind']('isEnabled')['to'](this),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision-wrapper',_0x9085c1['if']('isConfirm','ck-revision-history-sidebar__revision-wrapper_confirmation_visible')]},'children':[{'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision',_0x9085c1['if']('isEnabled','ck-disabled',_0x1ea89c=>!_0x1ea89c),_0x9085c1['if']('isSelected','ck-revision-history-sidebar__revision_selected'),_0x9085c1['if']('isHighlighted','ck-revision-history-sidebar__revision_highlighted'),_0x9085c1['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':_0x9085c1['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':_0x1dabe5}]},this['revisionActionsView']],'on':{'click':_0x9085c1['to'](_0x301775=>{_0x301775['srcElement']['closest']('.ck-thread__remove-confirm')||this['isReady']&&this['isEnabled']&&this['fire']('select',{'id':this['id']});})}}]});}['render'](){super['render']();const _0x6030cf=this['revisionNameView']['fieldView']['element'];this['listenTo'](_0x6030cf,'change',()=>{this['_requireRevisionName']&&!_0x6030cf['value']||this['fire']('setName',{'id':this['id'],'name':_0x6030cf['value']}),_0x6030cf['value']||(_0x6030cf['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(_0x59367f,_0x25d577){const _0x56fcdd=_0x4db10e['fromJSDate'](_0x59367f)['setLocale'](_0x25d577),_0x58388f=_0x4db10e['local'](),_0x2ef812=_0x58388f['minus']({'days':0x1})['startOf']('day');let _0x410619,_0x22ffd7;return _0x56fcdd['hasSame'](_0x58388f,'day')?(_0x410619=_0x56fcdd['startOf']('day')['toJSDate'](),_0x22ffd7=_0x56fcdd['toRelativeCalendar']()):_0x56fcdd['hasSame'](_0x2ef812,'day')?(_0x410619=_0x2ef812['toJSDate'](),_0x22ffd7=_0x56fcdd['toRelativeCalendar']()):_0x56fcdd['hasSame'](_0x58388f,'week')?(_0x410619=_0x56fcdd['startOf']('week')['toJSDate'](),_0x22ffd7=_0x56fcdd['weekdayLong']||''):_0x56fcdd['hasSame'](_0x58388f,'year')?(_0x410619=_0x56fcdd['startOf']('month')['toJSDate'](),_0x22ffd7=_0x56fcdd['monthLong']||''):(_0x410619=_0x56fcdd['startOf']('year')['toJSDate'](),_0x22ffd7=String(_0x56fcdd['year'])),{'startDate':_0x410619,'localizedPeriodName':_0x22ffd7};}class ji extends _0x2027a1{['startDate'];['revisionViews'];['_revisionActions'];['_requireRevisionName'];constructor(_0x3d2ede,_0x24dfaa,_0x6a8c19,_0x45d0e5){super(_0x3d2ede);const _0x490c77=ki(_0x24dfaa,this['locale']['uiLanguage'])['localizedPeriodName'];this['startDate']=_0x24dfaa,this['revisionViews']=this['createCollection'](),this['_revisionActions']=_0x6a8c19,this['_requireRevisionName']=_0x45d0e5,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':_0x490c77}]},{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__time-period__revisions']},'children':this['revisionViews']}]});}['addRevision'](_0x54a339){const _0x5c6318=new _i(this['locale'],_0x54a339,this['_revisionActions'],this['_requireRevisionName']);this['revisionViews']['add'](_0x5c6318);}['removeRevision'](_0xd02e0){const _0x5317ed=this['revisionViews']['find'](_0x4ec437=>_0x4ec437['id']===_0xd02e0['id']);this['revisionViews']['remove'](_0x5317ed);}}class Ni extends _0x2027a1{constructor(_0x244b9b){super(_0x244b9b);const _0x1a712d=new _0x4e4b3c();_0x1a712d['content']=_0x11f60f,this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset_all','ck-revision-history-sidebar__header']},'children':[_0x1a712d,{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__header__label']},'children':[R(_0x244b9b,'Revision\x20history')]}]});}}class Ri extends _0x2027a1{['timePeriodViews'];['_revisions'];['_revisionActions'];['_requireRevisionName'];constructor(_0xedf743,_0x50ebf2,_0x54f403,_0x402249){super(_0xedf743);const _0x243e09=this['bindTemplate'];this['timePeriodViews']=this['createCollection'](),this['timePeriodViews']['delegate']('select')['to'](this),this['timePeriodViews']['delegate']('setName')['to'](this),this['_revisions']=_0x50ebf2,this['_revisionActions']=_0x54f403,this['_requireRevisionName']=_0x402249,this['on']('select',(_0x10c939,_0x1a9a00)=>{this['fire']('revisionSelected',_0x1a9a00);}),this['on']('setName',(_0x33bb4a,_0x3e0b75)=>{this['fire']('revisionSetName',_0x3e0b75);}),this['set']('isEnabled',!0x1),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-rounded-corners','ck-revision-history-sidebar']},'children':[new Ni(_0xedf743),{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__timeline',_0x243e09['if']('isEnabled','ck-disabled',_0x433534=>!_0x433534)]},'children':this['timePeriodViews']}]});}['render'](){super['render']();for(const _0x5c418e of this['_revisions'])this['_addRevision'](_0x5c418e);this['_revisions']['on']('add',(_0x3535ed,_0x548436)=>{this['_addRevision'](_0x548436);}),this['_revisions']['on']('remove',(_0x2703fe,_0x181c8)=>{this['_removeRevision'](_0x181c8);});}get['revisionViews'](){return this['timePeriodViews']['map'](_0x1cd07a=>_0x1cd07a['revisionViews']['map'](_0x6f4475=>_0x6f4475))['flat']();}['selectRevision'](_0x5219ce){for(const _0x10ae07 of this['revisionViews'])_0x5219ce&&_0x5219ce['id']===_0x10ae07['id']?_0x10ae07['select']():_0x10ae07['deselect']();}['highlightRevisions'](_0x3fdf09){for(const _0x5cabe5 of this['revisionViews'])_0x3fdf09['some'](({id:_0x23a8a5})=>_0x23a8a5===_0x5cabe5['id'])?_0x5cabe5['highlight']():_0x5cabe5['unhighlight']();}['_addRevision'](_0x32658f){const _0x5ee7b8=ki(_0x32658f['createdAt'],this['locale']['uiLanguage'])['startDate'];let _0x3e7ea6=this['timePeriodViews']['get'](0x0);_0x3e7ea6&&_0x3e7ea6['startDate']['getTime']()===_0x5ee7b8['getTime']()||(_0x3e7ea6=new ji(this['locale'],_0x5ee7b8,this['_revisionActions'],this['_requireRevisionName']),this['timePeriodViews']['add'](_0x3e7ea6)),_0x3e7ea6['addRevision'](_0x32658f);}['_removeRevision'](_0x1e0dcf){const _0x1bba61=ki(_0x1e0dcf['createdAt'],this['locale']['uiLanguage'])['startDate'];this['_getTimePeriodViewByStartDate'](_0x1bba61)['removeRevision'](_0x1e0dcf);}['_getTimePeriodViewByStartDate'](_0x38124f){return this['timePeriodViews']['find'](_0x181ba4=>_0x181ba4['startDate']['getTime']()===_0x38124f['getTime']());}}class f extends _0x3daf77{['_revisionViewer'];['_revisionsRepository'];['_sidebarView'];static ['defaultRevisionActions']=/* #__PURE__ -- @preserve */
|
|
28
28
|
((()=>['compareAgainstSelected','restoreRevision','nameRevision'])());static ['availableRevisionActions']=/* #__PURE__ -- @preserve */
|
|
29
|
-
|
|
30
|
-
_0x3148ac(_0x581663){['_ui'];get['ui'](){return this['_ui'];}constructor(_0x851922,_0x502a54){super(_0x502a54),this['sourceElement']=_0x851922,this['model']['document']['createRoot']();const _0x17c003=new ii(this['locale'],this['editing']['view'],{'shouldToolbarGroupWhenFull':!0x0});this['_ui']=new Z(this,_0x17c003);}['destroy'](){return this['updateSourceElement'](),this['ui']['destroy'](),super['destroy']();}static async['create'](_0x42a7c3,_0x2d3c75){const _0x2919b9=new this(_0x42a7c3,_0x2d3c75);return await _0x2919b9['initPlugins'](),await _0x2919b9['ui']['init'](_0x42a7c3),await _0x2919b9['data']['init'](_0x2919b9['config']['get']('initialData')||''),_0x2919b9['fire']('ready'),_0x2919b9;}}const d=['RevisionHistoryUI','RestrictedEditingMode'];class at extends _0x278e34{['result'];static get['pluginName'](){return'RevisionViewerIntegration';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x2b4434){function _0x49db68(_0x584eb2){return _0x584eb2['map'](_0x2c064c=>String['fromCharCode'](_0x2c064c))['join']('');}super(_0x2b4434),this['result']='end',_0x2b4434[_0x49db68([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x49db68([0x76,0x69,0x65,0x77])][_0x49db68([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x49db68([0x61,0x75,0x74,0x6f]),_0x2b4434[_0x49db68([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x49db68([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x49db68([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x49db68([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x49db68([0x6f,0x6b])});}}class ht extends _0x278e34{['_viewerEditor'];static get['pluginName'](){return'RevisionHistory';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[h,v];}constructor(_0x2b6fa3){if(super(_0x2b6fa3),!this['editor']['config']['get']('revisionHistory'))throw new _0x28ebcb('revision-history-missing-configuration',this);this['_viewerEditor']=null,this['set']('isRevisionViewerOpen',!0x1),this['editor']['config']['define']('revisionHistory.showRevisionViewerCallback',_0x3501d1=>this['_showRevisionViewer']({..._0x3501d1,'translations':this['editor']['locale']['translations']})),this['editor']['config']['define']('revisionHistory.closeRevisionViewerCallback',_0x6f2fd4=>this['_closeRevisionViewer'](_0x6f2fd4)),this['editor']['config']['define']('revisionHistory.restoreRevisionCallback',_0x555d7e=>this['_restoreRevision'](_0x555d7e)),this['editor']['config']['define']('revisionHistory.requireRevisionName',!0x1),this['_enhanceShowRevisionViewerCallback'](),this['_enhanceCloseRevisionViewerCallback']();}set['adapter'](_0xce3592){this['editor']['plugins']['get']('RevisionTracker')['adapter']=_0xce3592;}get['adapter'](){return this['editor']['plugins']['get']('RevisionTracker')['adapter'];}['addRevisionData'](_0x84101b){return this['editor']['plugins']['get']('RevisionTracker')['addRevisionData'](_0x84101b);}['getRevision'](_0x5ac6cd){return this['editor']['plugins']['get']('RevisionsRepository')['getRevision'](_0x5ac6cd);}['getRevisions'](_0x44bd0f){return this['editor']['plugins']['get']('RevisionsRepository')['getRevisions'](_0x44bd0f||{'toJSON':!0x1});}['_getRevisionViewerEditorConfig'](){const _0x1b4e5c=this['editor'],_0x468938=_0x72e067(_0x1b4e5c,d),_0x1430ec=_0x1b4e5c['plugins']['get']('RevisionTracker'),_0x178f8a=_0x1b4e5c['plugins']['get']('Users')['users'];return _0x468938['toolbar']=['exitToEditing','restoreRevision','changesNavigation'],delete _0x468938['lazyRoots'],(_0x468938['plugins']['push'](at,l,u,class extends _0x278e34{static get['requires'](){return[l,'Users'];}['init'](){const _0x2a7954=this['editor']['plugins']['get']('Users');for(const _0x506bc5 of _0x178f8a)_0x506bc5['isAnonymous']||_0x2a7954['getUser'](_0x506bc5['id'])||_0x2a7954['addUser'](_0x506bc5);const _0x32db20=_0x1430ec['repository']['getRevisions']();let _0x46af7e=null;const _0x4118f6=this['editor']['plugins']['get']('RevisionViewer');_0x4118f6['adapter']=_0x1430ec['adapter'],_0x4118f6['bind']('isEnabled')['to'](_0x1430ec),this['editor']['commands']['get']('restoreRevision')['bind']('isEnabled')['to'](_0x1b4e5c,'isReadOnly',_0x11b87f=>!_0x11b87f);for(const _0x20add5 of _0x32db20){const _0x5e05ea=null===_0x20add5['creator'];if(_0x5e05ea&&_0x20add5['toVersion']===_0x20add5['fromVersion'])continue;const _0x404c40=_0x20add5['toJSON']();_0x4118f6['addRevisionData'](_0x404c40,(_0x5cd217,_0x46924b,_0x25f1ad)=>{if(_0x5e05ea){if(_0x46af7e)_0x46af7e['_update'](_0x5cd217,_0x46924b);else{if(!_0x46924b){const _0xa85998=_0x25f1ad['toJSON']();_0xa85998['id']=_0x515d40(),_0x1430ec['saveRevision'](_0xa85998,_0x25f1ad['toVersion'])['then'](_0x6f517f=>{_0x46af7e=_0x6f517f;});}}}else _0x20add5['_update'](_0x5cd217,_0x46924b);});}}},f),_0x468938);}['_enhanceShowRevisionViewerCallback'](){const _0x13d87f=this['editor']['config']['get']('revisionHistory')['showRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.showRevisionViewerCallback',async()=>{this['editor']['enableReadOnlyMode']('revision-history-viewer-opened');const _0x27d3af=this['editor']['plugins']['get']('RevisionTracker');if(this['editor']['plugins']['has']('Autosave')){const _0x2f9a97=this['editor']['plugins']['get']('Autosave');await _0x2f9a97['save']();}else await _0x27d3af['update']();if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('Dialog')){const _0x934dc4=this['editor']['plugins']['get']('Dialog');_0x934dc4['isOpen']&&_0x934dc4['hide']();}const _0x370931=this['_getRevisionViewerEditorConfig']();return _0x13d87f(_0x370931)['then'](_0x2e67df=>{return(this['_viewerEditor']=_0x2e67df,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'),_0x2e67df);})['catch'](_0x56ed4b=>(console['error'](_0x56ed4b),this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),null));});}['_enhanceCloseRevisionViewerCallback'](){const _0x535d73=this['editor']['config']['get']('revisionHistory')['closeRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.closeRevisionViewerCallback',()=>(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('DocumentOutline')&&(this['editor']['plugins']['get']('DocumentOutlineUI')['view']['element']['style']['display']=''),this['_viewerEditor']['plugins']['get']('RevisionViewer')['_cleanUp'](),_0x535d73(this['_viewerEditor'])['then'](()=>{if(this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),this['_viewerEditor']=null,this['editor']['plugins']['has']('Annotations')){const _0xf1a255=this['editor']['plugins']['get']('Annotations');_0xf1a255['refreshVisibility'](),_0xf1a255['refreshPositioning']();}})));}['_showRevisionViewer'](_0x582468){const _0x44e33c=this['editor']['config']['get']('revisionHistory.editorContainer'),_0x51c79d=this['editor']['config']['get']('revisionHistory.viewerContainer'),_0x53598e=this['editor']['config']['get']('revisionHistory.viewerEditorElement');return m['create'](_0x53598e,_0x582468)['then'](_0x40ea26=>(_0x51c79d['style']['display']='block',_0x44e33c['style']['display']='none',this['isRevisionViewerOpen']=!0x0,_0x40ea26));}['_closeRevisionViewer'](_0x4d5b3e){const _0x5e496c=this['editor']['config']['get']('revisionHistory.editorContainer');return this['editor']['config']['get']('revisionHistory.viewerContainer')['style']['display']='none',_0x5e496c['style']['display']='',this['isRevisionViewerOpen']=!0x1,_0x4d5b3e['destroy']();}async['_restoreRevision'](_0x10d8ee){const _0x4a3d87=this['editor'],_0x24fcb7=this['_viewerEditor']['plugins']['get']('RevisionViewer'),_0x4b5eab=_0x4a3d87['plugins']['get']('RevisionTracker'),_0x95748d=_0x4a3d87['plugins']['get']('RevisionHistoryUtils'),_0x244d56=_0x24fcb7['repository']['getRevision'](_0x10d8ee);let _0x3e6249,_0x66a9d5,_0xe59742;try{await _0x95748d['loadRevisionData'](_0x244d56,this['adapter']),_0x3e6249=_0x95748d['getRevisionDocumentData'](_0x244d56),_0x66a9d5=_0x95748d['getRevisionRootsAttributes'](_0x244d56);}catch(_0x16b622){return void console['error'](_0x16b622);}_0x4a3d87['model']['change'](_0x544333=>{for(const _0x12da11 of Array['from'](_0x4a3d87['model']['markers']['getMarkersGroup']('restrictedEditingException')))_0x544333['removeMarker'](_0x12da11);}),_0x24fcb7['isReady']=!0x1,_0x4a3d87['model']['enqueueChange'](_0x21a82a=>{_0x21a82a['setSelection'](null),_0x21a82a['removeSelectionAttribute'](_0x4a3d87['model']['document']['selection']['getAttributeKeys']());const _0x11a301=Object['keys'](_0x3e6249);for(const _0x576109 of _0x4a3d87['model']['document']['roots'])'$graveyard'!=_0x576109['rootName']&&_0x576109['isAttached']()&&!_0x11a301['includes'](_0x576109['rootName'])&&_0x21a82a['detachRoot'](_0x576109);for(const _0x43102e of _0x11a301){let _0x355c49=_0x4a3d87['model']['document']['getRoot'](_0x43102e);_0x355c49&&_0x355c49['isAttached']()||(_0x355c49=_0x21a82a['addRoot'](_0x43102e));const _0x51f1a3=_0x66a9d5[_0x43102e],_0x334eed=Object['keys'](_0x51f1a3),_0x503a8f=_0x3e6249[_0x43102e];for(const _0x4f3311 of _0x355c49['getAttributeKeys']())_0x334eed['includes'](_0x4f3311)||_0x21a82a['removeAttribute'](_0x4f3311,_0x355c49);for(const _0x1ac181 of _0x334eed)_0x21a82a['setAttribute'](_0x1ac181,_0x66a9d5[_0x43102e][_0x1ac181],_0x355c49);_0x21a82a['remove'](_0x21a82a['createRangeIn'](_0x355c49)),_0x21a82a['insert'](_0x4a3d87['data']['parse'](_0x503a8f,_0x355c49),_0x355c49,0x0);}});const _0x2fb2ef=R(_0x4a3d87['locale'],'Restored');if(_0x244d56['name'])_0xe59742=-0x1==_0x244d56['name']['indexOf'](_0x2fb2ef)?_0x2fb2ef+':\x20'+_0x244d56['name']:_0x244d56['name'];else _0xe59742=_0x2fb2ef+':\x20'+(_0x244d56['createdAt']['toLocaleDateString'](_0x4a3d87['locale']['uiLanguage'],{'month':'long','day':'numeric'})+',\x20'+_0x244d56['createdAt']['toLocaleTimeString'](_0x4a3d87['locale']['uiLanguage'],{'hour':'numeric','minute':'numeric'}));return await _0x4b5eab['saveRevision']({'name':_0xe59742}),_0x24fcb7['isReady']=!0x0,_0x4a3d87['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}}export{nt as RestoreRevisionCommand,I as Revision,ht as RevisionHistory,v as RevisionHistoryUI,$ as RevisionHistoryUtils,h as RevisionTracker,l as RevisionViewer,m as RevisionViewerEditor,at as RevisionViewerIntegration,fi as RevisionViewerLoadingOverlay,u as RevisionViewerUI,S as RevisionsRepository,f as RevisionsSidebar,ot as ShowChangeCommand};
|
|
29
|
+
at();static get['pluginName'](){return'RevisionsSidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[l];}constructor(_0x54ba23){super(_0x54ba23),this['_revisionViewer']=_0x54ba23['plugins']['get'](l),this['_revisionsRepository']=this['_revisionViewer']['repository'],this['_sidebarView']=null;}['init'](){const _0x562426=this['_revisionsRepository']['_revisions'],_0x4bee8e=this['_createRevisionActions'](),_0x2a9f82=this['editor']['config']['get']('revisionHistory.viewerSidebarContainer');this['_sidebarView']=new Ri(this['editor']['locale'],_0x562426,_0x4bee8e,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',(_0x3720cb,_0x5b1bea)=>{_0x5b1bea['revisionViews']['on']('add',(_0x2f044b,_0xf3d372)=>{_0xf3d372['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)),_0x2a9f82['appendChild'](this['_sidebarView']['element']);}['destroy'](){this['_sidebarView']['element']['remove'](),this['_sidebarView']['destroy']();}['_handleEditorDataReady'](){const _0x355d26=this['_revisionsRepository']['getRevision'](0x0);if(_0x355d26){const _0x284807=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x355d26['id']);this['_revisionViewer']['compare'](_0x355d26,_0x284807);}}['_handleRevisionSelected'](_0x3d47e3,_0x4c10bd){const _0x5b7baf=this['_revisionsRepository']['getRevision'](_0x4c10bd['id']),_0x38590e=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x5b7baf['id']);this['_revisionViewer']['compare'](_0x5b7baf,_0x38590e);}['_handleRevisionSetName'](_0xddd4e0,_0xa8114b){this['_revisionsRepository']['getRevision'](_0xa8114b['id'])['setName'](_0xa8114b['name']);}['_handleDiffChange'](_0x340ff4,_0x229c06,_0x4c8cfb){const _0x3a89e6=this['_revisionsRepository']['getRevisionsInDiff'](_0x4c8cfb);_0x3a89e6['length']>0x2?(this['_sidebarView']['highlightRevisions'](_0x3a89e6),this['_sidebarView']['selectRevision'](null)):(this['_sidebarView']['highlightRevisions']([]),this['_sidebarView']['selectRevision'](_0x3a89e6[0x0]));}['_createRevisionActions'](){const _0x4dd53d=this['editor'],_0x1a579d=f['availableRevisionActions'],_0x2c132d=_0x4dd53d['config']['get']('revisionHistory.revisionActions')||f['defaultRevisionActions'];if(_0x2c132d['length'])return _0x2c132d['map'](_0x32ac36=>{const _0x46c0e3='string'==typeof _0x32ac36?Object['assign']({},_0x1a579d[_0x32ac36]):_0x32ac36;return _0x46c0e3['action']=_0x46c0e3['action']['bind'](this,_0x4dd53d),_0x46c0e3['isVisible']&&(_0x46c0e3['isVisible']=_0x46c0e3['isVisible']['bind'](this,_0x4dd53d)),_0x46c0e3;});}}function at(){return{'compareAgainstSelected':{'name':'Compare\x20against\x20selected','action':({plugins:_0x173854},_0x5ee3eb)=>{const _0x40ceef=_0x173854['get'](l),_0x18f318=_0x40ceef['repository'];let _0x2a9859=_0x40ceef['diff']['newRevisionId'],_0x2c8d45=_0x5ee3eb['id'];_0x18f318['getIndex'](_0x2a9859)>_0x18f318['getIndex'](_0x2c8d45)&&([_0x2a9859,_0x2c8d45]=[_0x2c8d45,_0x2a9859]),_0x40ceef['compare'](_0x2a9859,_0x2c8d45);},'isVisible':({plugins:_0x1418c2},_0x18b052)=>{const _0x7cf9c=_0x1418c2['get'](l);return!(_0x7cf9c['repository']['getRevisionsInDiff'](_0x7cf9c['diff'])['length']>0x2)&&!_0x18b052['isSelected'];}},'restoreRevision':{'name':'Restore\x20this\x20revision','action':(_0x30a547,{id:_0x1fda7c})=>{_0x30a547['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x1fda7c);},'isVisible':({plugins:_0x8c2c7},_0x4e51be)=>!!_0x8c2c7['get'](l)['repository']['getLaterVisibleRevision'](_0x4e51be['id'])},'nameRevision':{'name':'Name\x20this\x20revision','action':({plugins:_0x2e02b6},{id:_0xb1e652,revisionNameView:_0x2b26f6})=>{const _0x5472eb=_0x2e02b6['get'](l),_0x5369c4=_0x5472eb['repository']['getEarlierVisibleRevision'](_0xb1e652);_0x5472eb['compare'](_0xb1e652,_0x5369c4),_0x2b26f6['focus'](),_0x2b26f6['fieldView']['select']();}}};}class Z extends tt{['_view'];['_toolbarConfig'];['_elementReplacer'];get['view'](){return this['_view'];}constructor(_0x99eeaf,_0x344a0b){super(_0x99eeaf),this['_view']=_0x344a0b,this['_toolbarConfig']=st(_0x99eeaf['config']['get']('toolbar')),this['_elementReplacer']=new it();}get['element'](){return this['view']['element'];}['init'](_0x5635d4){const _0x2c4453=this['editor'],_0x4510ce=this['view'],_0x1cfecc=_0x2c4453['editing']['view'],_0x706b9=_0x4510ce['editable'],_0x310fa8=_0x1cfecc['document']['getRoot']();_0x706b9['name']=_0x310fa8['rootName'],_0x4510ce['render']();const _0x4af559=_0x706b9['element'];this['setEditableElement'](_0x706b9['name'],_0x4af559),_0x4510ce['editable']['bind']('isFocused')['to'](this['focusTracker']),_0x1cfecc['attachDomRoot'](_0x4af559),this['_elementReplacer']['replace'](_0x5635d4,this['element']),this['_initToolbar'](),this['fire']('ready');}['destroy'](){super['destroy']();const _0x3c9585=this['view'],_0x330df2=this['editor']['editing']['view'];this['_elementReplacer']['restore'](),_0x330df2['detachDomRoot'](_0x3c9585['editable']['name']),_0x3c9585['destroy']();}['_initToolbar'](){const _0x7fad6=this['view'];_0x7fad6['stickyPanel']['bind']('isActive')['to'](this['focusTracker'],'isFocused'),_0x7fad6['stickyPanel']['limiterElement']=_0x7fad6['element'],_0x7fad6['stickyPanel']['bind']('viewportTopOffset')['to'](this,'viewportOffset',({top:_0x231abb})=>_0x231abb),_0x7fad6['toolbar']['fillFromConfig'](this['_toolbarConfig'],this['componentFactory']),this['addToolbar'](_0x7fad6['toolbar']);}}class ii extends _0xedbfd4{['_editable'];['stickyPanel'];['toolbar'];get['editable'](){return this['_editable'];}constructor(_0xf5a8f2,_0x8da31d,_0x55ab12={}){super(_0xf5a8f2),this['stickyPanel']=new _0x19738f(_0xf5a8f2),this['toolbar']=new _0x2094c1(_0xf5a8f2,{'shouldGroupWhenFull':_0x55ab12['shouldToolbarGroupWhenFull']}),this['_editable']=new te(_0xf5a8f2,_0x8da31d);}['render'](){super['render'](),this['stickyPanel']['content']['add'](this['toolbar']),this['top']['add'](this['stickyPanel']),this['main']['add'](this['editable']);}}class m extends/* #__PURE__ -- @preserve */
|
|
30
|
+
_0x3c1de6(_0x39d64c){['_ui'];get['ui'](){return this['_ui'];}constructor(_0x3489f7,_0x412afe){super(_0x412afe),this['sourceElement']=_0x3489f7,this['model']['document']['createRoot']();const _0x5387a2=new ii(this['locale'],this['editing']['view'],{'shouldToolbarGroupWhenFull':!0x0});this['_ui']=new Z(this,_0x5387a2);}['destroy'](){return this['updateSourceElement'](),this['ui']['destroy'](),super['destroy']();}static async['create'](_0x2028fa,_0x41ac17){const _0x57111f=new this(_0x2028fa,_0x41ac17);return await _0x57111f['initPlugins'](),await _0x57111f['ui']['init'](_0x2028fa),await _0x57111f['data']['init'](_0x57111f['config']['get']('initialData')||''),_0x57111f['fire']('ready'),_0x57111f;}}const d=['RevisionHistoryUI','RestrictedEditingMode'];class ht extends _0x3daf77{['result'];static get['pluginName'](){return'RevisionViewerIntegration';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x32716f){function _0x489e98(_0x50b0e2){return _0x50b0e2['map'](_0x344358=>String['fromCharCode'](_0x344358))['join']('');}super(_0x32716f),this['result']='end',_0x32716f[_0x489e98([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x489e98([0x76,0x69,0x65,0x77])][_0x489e98([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x489e98([0x61,0x75,0x74,0x6f]),_0x32716f[_0x489e98([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x489e98([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x489e98([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x489e98([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x489e98([0x6f,0x6b])});}}class ct extends _0x3daf77{['_viewerEditor'];static get['pluginName'](){return'RevisionHistory';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[h,v];}constructor(_0x476ba3){if(super(_0x476ba3),!this['editor']['config']['get']('revisionHistory'))throw new _0x308bd1('revision-history-missing-configuration',this);this['_viewerEditor']=null,this['set']('isRevisionViewerOpen',!0x1),this['editor']['config']['define']('revisionHistory.showRevisionViewerCallback',_0x5450e3=>this['_showRevisionViewer']({..._0x5450e3,'translations':this['editor']['locale']['translations']})),this['editor']['config']['define']('revisionHistory.closeRevisionViewerCallback',_0x5c634c=>this['_closeRevisionViewer'](_0x5c634c)),this['editor']['config']['define']('revisionHistory.restoreRevisionCallback',_0x336a53=>this['_restoreRevision'](_0x336a53)),this['editor']['config']['define']('revisionHistory.requireRevisionName',!0x1),this['_enhanceShowRevisionViewerCallback'](),this['_enhanceCloseRevisionViewerCallback']();}set['adapter'](_0x4c70b3){this['editor']['plugins']['get']('RevisionTracker')['adapter']=_0x4c70b3;}get['adapter'](){return this['editor']['plugins']['get']('RevisionTracker')['adapter'];}['addRevisionData'](_0x3e13b6){return this['editor']['plugins']['get']('RevisionTracker')['addRevisionData'](_0x3e13b6);}['getRevision'](_0x508196){return this['editor']['plugins']['get']('RevisionsRepository')['getRevision'](_0x508196);}['getRevisions'](_0x169996){return this['editor']['plugins']['get']('RevisionsRepository')['getRevisions'](_0x169996||{'toJSON':!0x1});}['_getRevisionViewerEditorConfig'](){const _0x2b23d9=this['editor'],_0xf08e95=_0x28a60b(_0x2b23d9,d),_0x1aaa7a=_0x2b23d9['plugins']['get']('RevisionTracker'),_0x57b247=_0x2b23d9['plugins']['get']('Users')['users'];return _0xf08e95['toolbar']=['exitToEditing','restoreRevision','changesNavigation'],delete _0xf08e95['lazyRoots'],(_0xf08e95['plugins']['push'](ht,l,u,class extends _0x3daf77{static get['requires'](){return[l,'Users'];}['init'](){const _0x1ed363=this['editor']['plugins']['get']('Users');for(const _0x5e9cff of _0x57b247)_0x5e9cff['isAnonymous']||_0x1ed363['getUser'](_0x5e9cff['id'])||_0x1ed363['addUser'](_0x5e9cff);const _0x481be8=_0x1aaa7a['repository']['getRevisions']();let _0x4ddec1=null;const _0x167110=this['editor']['plugins']['get']('RevisionViewer');_0x167110['adapter']=_0x1aaa7a['adapter'],_0x167110['bind']('isEnabled')['to'](_0x1aaa7a),this['editor']['commands']['get']('restoreRevision')['bind']('isEnabled')['to'](_0x2b23d9,'isReadOnly',_0x35b73b=>!_0x35b73b);for(const _0x18949c of _0x481be8){const _0x17888e=null===_0x18949c['creator'];if(_0x17888e&&_0x18949c['toVersion']===_0x18949c['fromVersion'])continue;const _0x1908ae=_0x18949c['toJSON']();_0x167110['addRevisionData'](_0x1908ae,(_0xd58b33,_0x2ad130,_0x1bedc0)=>{if(_0x17888e){if(_0x4ddec1)_0x4ddec1['_update'](_0xd58b33,_0x2ad130);else{if(!_0x2ad130){const _0x501d8d=_0x1bedc0['toJSON']();_0x501d8d['id']=_0x1c1c29(),_0x1aaa7a['saveRevision'](_0x501d8d,_0x1bedc0['toVersion'])['then'](_0x11c227=>{_0x4ddec1=_0x11c227;});}}}else _0x18949c['_update'](_0xd58b33,_0x2ad130);});}}},f),_0xf08e95);}['_enhanceShowRevisionViewerCallback'](){const _0x38c867=this['editor']['config']['get']('revisionHistory')['showRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.showRevisionViewerCallback',async()=>{this['editor']['enableReadOnlyMode']('revision-history-viewer-opened');const _0x16d37b=this['editor']['plugins']['get']('RevisionTracker');if(this['editor']['plugins']['has']('Autosave')){const _0x21ec6a=this['editor']['plugins']['get']('Autosave');await _0x21ec6a['save']();}else await _0x16d37b['update']();if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('Dialog')){const _0x354811=this['editor']['plugins']['get']('Dialog');_0x354811['isOpen']&&_0x354811['hide']();}const _0x5d2fc9=this['_getRevisionViewerEditorConfig']();return _0x38c867(_0x5d2fc9)['then'](_0x17174c=>{return(this['_viewerEditor']=_0x17174c,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'),_0x17174c);})['catch'](_0x53fb1e=>(console['error'](_0x53fb1e),this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),null));});}['_enhanceCloseRevisionViewerCallback'](){const _0x3a145e=this['editor']['config']['get']('revisionHistory')['closeRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.closeRevisionViewerCallback',()=>(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('DocumentOutline')&&(this['editor']['plugins']['get']('DocumentOutlineUI')['view']['element']['style']['display']=''),this['_viewerEditor']['plugins']['get']('RevisionViewer')['_cleanUp'](),_0x3a145e(this['_viewerEditor'])['then'](()=>{if(this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),this['_viewerEditor']=null,this['editor']['plugins']['has']('Annotations')){const _0x570db5=this['editor']['plugins']['get']('Annotations');_0x570db5['refreshVisibility'](),_0x570db5['refreshPositioning']();}})));}['_showRevisionViewer'](_0x10739b){const _0xf601a1=this['editor']['config']['get']('revisionHistory.editorContainer'),_0x2faaa8=this['editor']['config']['get']('revisionHistory.viewerContainer'),_0x19123b=this['editor']['config']['get']('revisionHistory.viewerEditorElement');return m['create'](_0x19123b,_0x10739b)['then'](_0x2e7c2e=>(_0x2faaa8['style']['display']='block',_0xf601a1['style']['display']='none',this['isRevisionViewerOpen']=!0x0,_0x2e7c2e));}['_closeRevisionViewer'](_0x55e427){const _0xd5c293=this['editor']['config']['get']('revisionHistory.editorContainer');return this['editor']['config']['get']('revisionHistory.viewerContainer')['style']['display']='none',_0xd5c293['style']['display']='',this['isRevisionViewerOpen']=!0x1,_0x55e427['destroy']();}async['_restoreRevision'](_0x414fb1){const _0x5b871b=this['editor'],_0x19e71c=this['_viewerEditor']['plugins']['get']('RevisionViewer'),_0x2443ef=_0x5b871b['plugins']['get']('RevisionTracker'),_0x391460=_0x5b871b['plugins']['get']('RevisionHistoryUtils'),_0x3ead63=_0x19e71c['repository']['getRevision'](_0x414fb1);let _0xa289e8,_0x48adec,_0x199fe7;try{await _0x391460['loadRevisionData'](_0x3ead63,this['adapter']),_0xa289e8=_0x391460['getRevisionDocumentData'](_0x3ead63),_0x48adec=_0x391460['getRevisionRootsAttributes'](_0x3ead63);}catch(_0x2240e1){return void console['error'](_0x2240e1);}_0x5b871b['model']['change'](_0x45fcdc=>{for(const _0x35fc63 of Array['from'](_0x5b871b['model']['markers']['getMarkersGroup']('restrictedEditingException')))_0x45fcdc['removeMarker'](_0x35fc63);}),_0x19e71c['isReady']=!0x1,_0x5b871b['model']['enqueueChange'](_0x404548=>{_0x404548['setSelection'](null),_0x404548['removeSelectionAttribute'](_0x5b871b['model']['document']['selection']['getAttributeKeys']());const _0x4fef6b=Object['keys'](_0xa289e8);for(const _0x1734fb of _0x5b871b['model']['document']['roots'])'$graveyard'!=_0x1734fb['rootName']&&_0x1734fb['isAttached']()&&!_0x4fef6b['includes'](_0x1734fb['rootName'])&&_0x404548['detachRoot'](_0x1734fb);for(const _0x159bef of _0x4fef6b){let _0x286cae=_0x5b871b['model']['document']['getRoot'](_0x159bef);_0x286cae&&_0x286cae['isAttached']()||(_0x286cae=_0x404548['addRoot'](_0x159bef));const _0x45897a=_0x48adec[_0x159bef],_0x2b31d5=Object['keys'](_0x45897a),_0x2cf618=_0xa289e8[_0x159bef];for(const _0x1c7d2b of _0x286cae['getAttributeKeys']())_0x2b31d5['includes'](_0x1c7d2b)||_0x404548['removeAttribute'](_0x1c7d2b,_0x286cae);for(const _0x14b74f of _0x2b31d5)_0x404548['setAttribute'](_0x14b74f,_0x48adec[_0x159bef][_0x14b74f],_0x286cae);_0x404548['remove'](_0x404548['createRangeIn'](_0x286cae)),_0x404548['insert'](_0x5b871b['data']['parse'](_0x2cf618,_0x286cae),_0x286cae,0x0);}});const _0x28d0e2=R(_0x5b871b['locale'],'Restored');if(_0x3ead63['name'])_0x199fe7=-0x1==_0x3ead63['name']['indexOf'](_0x28d0e2)?_0x28d0e2+':\x20'+_0x3ead63['name']:_0x3ead63['name'];else _0x199fe7=_0x28d0e2+':\x20'+(_0x3ead63['createdAt']['toLocaleDateString'](_0x5b871b['locale']['uiLanguage'],{'month':'long','day':'numeric'})+',\x20'+_0x3ead63['createdAt']['toLocaleTimeString'](_0x5b871b['locale']['uiLanguage'],{'hour':'numeric','minute':'numeric'}));return await _0x2443ef['saveRevision']({'name':_0x199fe7}),_0x19e71c['isReady']=!0x0,_0x5b871b['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}}export{nt as RestoreRevisionCommand,I as Revision,ct as RevisionHistory,v as RevisionHistoryUI,$ as RevisionHistoryUtils,h as RevisionTracker,l as RevisionViewer,m as RevisionViewerEditor,ht as RevisionViewerIntegration,bi as RevisionViewerLoadingOverlay,u as RevisionViewerUI,S as RevisionsRepository,f as RevisionsSidebar,rt as ShowChangeCommand};
|