@ckeditor/ckeditor5-revision-history 47.0.0-alpha.0 → 47.0.0-alpha.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/build/revision-history.js +1 -1
- package/dist/index.js +7 -7
- package/dist/translations/af.js +1 -1
- package/dist/translations/af.umd.js +1 -1
- package/dist/translations/ar.js +1 -1
- package/dist/translations/ar.umd.js +1 -1
- package/dist/translations/ast.js +1 -1
- package/dist/translations/ast.umd.js +1 -1
- package/dist/translations/az.js +1 -1
- package/dist/translations/az.umd.js +1 -1
- package/dist/translations/be.js +1 -1
- package/dist/translations/be.umd.js +1 -1
- package/dist/translations/bg.js +1 -1
- package/dist/translations/bg.umd.js +1 -1
- package/dist/translations/bn.js +1 -1
- package/dist/translations/bn.umd.js +1 -1
- package/dist/translations/bs.js +1 -1
- package/dist/translations/bs.umd.js +1 -1
- package/dist/translations/ca.js +1 -1
- package/dist/translations/ca.umd.js +1 -1
- package/dist/translations/cs.js +1 -1
- package/dist/translations/cs.umd.js +1 -1
- package/dist/translations/da.js +1 -1
- package/dist/translations/da.umd.js +1 -1
- package/dist/translations/de-ch.js +1 -1
- package/dist/translations/de-ch.umd.js +1 -1
- package/dist/translations/de.js +1 -1
- package/dist/translations/de.umd.js +1 -1
- package/dist/translations/el.js +1 -1
- package/dist/translations/el.umd.js +1 -1
- package/dist/translations/en-au.js +1 -1
- package/dist/translations/en-au.umd.js +1 -1
- package/dist/translations/en-gb.js +1 -1
- package/dist/translations/en-gb.umd.js +1 -1
- package/dist/translations/en.js +1 -1
- package/dist/translations/en.umd.js +1 -1
- package/dist/translations/eo.js +1 -1
- package/dist/translations/eo.umd.js +1 -1
- package/dist/translations/es-co.js +1 -1
- package/dist/translations/es-co.umd.js +1 -1
- package/dist/translations/es.js +1 -1
- package/dist/translations/es.umd.js +1 -1
- package/dist/translations/et.js +1 -1
- package/dist/translations/et.umd.js +1 -1
- package/dist/translations/eu.js +1 -1
- package/dist/translations/eu.umd.js +1 -1
- package/dist/translations/fa.js +1 -1
- package/dist/translations/fa.umd.js +1 -1
- package/dist/translations/fi.js +1 -1
- package/dist/translations/fi.umd.js +1 -1
- package/dist/translations/fr.js +1 -1
- package/dist/translations/fr.umd.js +1 -1
- package/dist/translations/gl.js +1 -1
- package/dist/translations/gl.umd.js +1 -1
- package/dist/translations/gu.js +1 -1
- package/dist/translations/gu.umd.js +1 -1
- package/dist/translations/he.js +1 -1
- package/dist/translations/he.umd.js +1 -1
- package/dist/translations/hi.js +1 -1
- package/dist/translations/hi.umd.js +1 -1
- package/dist/translations/hr.js +1 -1
- package/dist/translations/hr.umd.js +1 -1
- package/dist/translations/hu.js +1 -1
- package/dist/translations/hu.umd.js +1 -1
- package/dist/translations/hy.js +1 -1
- package/dist/translations/hy.umd.js +1 -1
- package/dist/translations/id.js +1 -1
- package/dist/translations/id.umd.js +1 -1
- package/dist/translations/it.js +1 -1
- package/dist/translations/it.umd.js +1 -1
- package/dist/translations/ja.js +1 -1
- package/dist/translations/ja.umd.js +1 -1
- package/dist/translations/jv.js +1 -1
- package/dist/translations/jv.umd.js +1 -1
- package/dist/translations/kk.js +1 -1
- package/dist/translations/kk.umd.js +1 -1
- package/dist/translations/km.js +1 -1
- package/dist/translations/km.umd.js +1 -1
- package/dist/translations/kn.js +1 -1
- package/dist/translations/kn.umd.js +1 -1
- package/dist/translations/ko.js +1 -1
- package/dist/translations/ko.umd.js +1 -1
- package/dist/translations/ku.js +1 -1
- package/dist/translations/ku.umd.js +1 -1
- package/dist/translations/lt.js +1 -1
- package/dist/translations/lt.umd.js +1 -1
- package/dist/translations/lv.js +1 -1
- package/dist/translations/lv.umd.js +1 -1
- package/dist/translations/ms.js +1 -1
- package/dist/translations/ms.umd.js +1 -1
- package/dist/translations/nb.js +1 -1
- package/dist/translations/nb.umd.js +1 -1
- package/dist/translations/ne.js +1 -1
- package/dist/translations/ne.umd.js +1 -1
- package/dist/translations/nl.js +1 -1
- package/dist/translations/nl.umd.js +1 -1
- package/dist/translations/no.js +1 -1
- package/dist/translations/no.umd.js +1 -1
- package/dist/translations/oc.js +1 -1
- package/dist/translations/oc.umd.js +1 -1
- package/dist/translations/pl.js +1 -1
- package/dist/translations/pl.umd.js +1 -1
- package/dist/translations/pt-br.js +1 -1
- package/dist/translations/pt-br.umd.js +1 -1
- package/dist/translations/pt.js +1 -1
- package/dist/translations/pt.umd.js +1 -1
- package/dist/translations/ro.js +1 -1
- package/dist/translations/ro.umd.js +1 -1
- package/dist/translations/ru.js +1 -1
- package/dist/translations/ru.umd.js +1 -1
- package/dist/translations/si.js +1 -1
- package/dist/translations/si.umd.js +1 -1
- package/dist/translations/sk.js +1 -1
- package/dist/translations/sk.umd.js +1 -1
- package/dist/translations/sl.js +1 -1
- package/dist/translations/sl.umd.js +1 -1
- package/dist/translations/sq.js +1 -1
- package/dist/translations/sq.umd.js +1 -1
- package/dist/translations/sr-latn.js +1 -1
- package/dist/translations/sr-latn.umd.js +1 -1
- package/dist/translations/sr.js +1 -1
- package/dist/translations/sr.umd.js +1 -1
- package/dist/translations/sv.js +1 -1
- package/dist/translations/sv.umd.js +1 -1
- package/dist/translations/th.js +1 -1
- package/dist/translations/th.umd.js +1 -1
- package/dist/translations/ti.js +1 -1
- package/dist/translations/ti.umd.js +1 -1
- package/dist/translations/tk.js +1 -1
- package/dist/translations/tk.umd.js +1 -1
- package/dist/translations/tr.js +1 -1
- package/dist/translations/tr.umd.js +1 -1
- package/dist/translations/tt.js +1 -1
- package/dist/translations/tt.umd.js +1 -1
- package/dist/translations/ug.js +1 -1
- package/dist/translations/ug.umd.js +1 -1
- package/dist/translations/uk.js +1 -1
- package/dist/translations/uk.umd.js +1 -1
- package/dist/translations/ur.js +1 -1
- package/dist/translations/ur.umd.js +1 -1
- package/dist/translations/uz.js +1 -1
- package/dist/translations/uz.umd.js +1 -1
- package/dist/translations/vi.js +1 -1
- package/dist/translations/vi.umd.js +1 -1
- package/dist/translations/zh-cn.js +1 -1
- package/dist/translations/zh-cn.umd.js +1 -1
- package/dist/translations/zh.js +1 -1
- package/dist/translations/zh.umd.js +1 -1
- package/package.json +12 -12
- package/src/changeitem.js +2 -2
- package/src/editor/revisionviewereditor.js +2 -2
- package/src/editor/revisionviewereditorui.js +1 -1
- package/src/editor/revisionviewereditoruiview.js +1 -1
- package/src/index.js +1 -1
- package/src/revision.js +2 -2
- package/src/revisiondiff.js +1 -1
- package/src/revisionhistory.js +1 -1
- package/src/revisionhistoryutils.js +1 -1
- package/src/revisionsrepository.js +1 -1
- package/src/revisiontracker.js +1 -1
- package/src/revisionviewer.js +1 -1
- package/src/ui/revision/createrevisionactionsdropdown.js +1 -1
- package/src/ui/revision/revisionauthorview.js +1 -1
- package/src/ui/revision/revisionnameview.js +1 -1
- package/src/ui/revision/revisionview.js +2 -2
- package/src/ui/revision/subrevisioncollapserview.js +1 -1
- package/src/ui/revision/subrevisionview.js +1 -1
- package/src/ui/revision/utils.js +1 -1
- package/src/ui/revisionhistory/revisionhistorysaverevisionformview.js +2 -2
- package/src/ui/revisionhistory/revisionhistoryui.js +1 -1
- package/src/ui/revisionssidebar/revisionssidebar.js +1 -1
- package/src/ui/revisionssidebar/revisionssidebarheaderview.js +1 -1
- package/src/ui/revisionssidebar/revisionssidebartimeperiodview.js +1 -1
- package/src/ui/revisionssidebar/revisionssidebarview.js +1 -1
- package/src/ui/revisionssidebar/utils.js +1 -1
- package/src/ui/revisionviewer/changedetailsview.js +1 -1
- package/src/ui/revisionviewer/changesnavigationview.js +1 -1
- package/src/ui/revisionviewer/revisionviewerloadingoverlay.js +1 -1
- package/src/ui/revisionviewer/revisionviewerui.js +1 -1
- package/src/utils/common-translations.js +1 -1
package/dist/index.js
CHANGED
|
@@ -20,11 +20,11 @@
|
|
|
20
20
|
*
|
|
21
21
|
*
|
|
22
22
|
*/
|
|
23
|
-
import{ObservableMixin as
|
|
24
|
-
_0x408429(){['id'];['creator'];['authors'];['diffData'];['toVersion'];['fromVersion'];['model'];constructor(_0x54e8d9){super(),this['id']=_0x54e8d9['id']||_0x4df7d4(),this['creator']=_0x54e8d9['creator']||null,this['authors']=_0x54e8d9['authors']||[],this['diffData']=_0x54e8d9['diffData']||null,this['toVersion']=_0x54e8d9['toVersion']||0x0,this['fromVersion']=_0x54e8d9['fromVersion']||0x0,this['set']('name',_0x54e8d9['name']||''),this['set']('createdAt',_0x54e8d9['createdAt']||new Date()),this['set']('attributes',_0x54e8d9['attributes']||{});}['setName'](_0x1bfddb){this['_update']({'name':_0x1bfddb});}['setAttribute'](_0x642215,_0x3e69c9){const _0x43ea3e=_0x13ac74(this['attributes']);_0x989ba6(_0x43ea3e,_0x642215,_0x3e69c9),this['_update']({'attributes':_0x43ea3e});}['removeAttribute'](_0x28954d){const _0x2f3dd1=_0x13ac74(this['attributes']);_0x45bc8c(_0x2f3dd1,_0x28954d),this['_update']({'attributes':_0x2f3dd1});}['_update'](_0x2b8749,_0x565301=!0x1){let _0x4a24b5=!0x1;const _0x2d8220={'id':this['id']},_0x746092=['name','createdAt','diffData','authors','attributes','toVersion','fromVersion','creatorId'];for(const _0x92e2c5 of _0x746092){const _0x3b3d08=_0x2b8749[_0x92e2c5];void 0x0!==_0x3b3d08&&_0x3b3d08!==this[_0x92e2c5]&&(this[_0x92e2c5]=_0x3b3d08,_0x2d8220[_0x92e2c5]=_0x3b3d08,_0x4a24b5=!0x0);}_0x4a24b5&&(_0x2d8220['authors']&&(_0x2d8220['authorsIds']=_0x2d8220['authors']['map'](_0x29ebdb=>_0x29ebdb['id']),delete _0x2d8220['authors']),this['fire']('_update',_0x2d8220,_0x565301));}['toJSON'](){return{'id':this['id'],'name':this['name'],'creatorId':this['creator']?this['creator']['id']:null,'authorsIds':this['authors']['map'](_0x308ffa=>_0x308ffa['id']),'diffData':this['diffData'],'createdAt':this['createdAt'],'attributes':this['attributes'],'fromVersion':this['fromVersion'],'toVersion':this['toVersion']};}}class S extends _0x280bdd{['_revisions'];static get['requires'](){return[_0x1439ad];}static get['pluginName'](){return'RevisionsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['length'](){return this['_revisions']['length'];}constructor(_0x4f445b){super(_0x4f445b),this['_revisions']=new _0x5b3f34();}['afterInit'](){!async function(_0x1ebc20){const _0x3275fc=_0x31df44([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]),_0xff3b8=0xeb829,_0x5e6f07=0x7374585f,_0x32f512=0x73732c17^_0x5e6f07,_0x26e4da=window[_0x31df44([0x44,0x61,0x74,0x65])][_0x31df44([0x6e,0x6f,0x77])](),_0x39728a=_0x1ebc20[_0x31df44([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x389240=new window[(_0x31df44([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x2a52bc=>{_0x39728a[_0x31df44([0x6f,0x6e,0x63,0x65])](_0x31df44([0x72,0x65,0x61,0x64,0x79]),_0x2a52bc);}),_0x112eaf={[_0x31df44([0x6b,0x74,0x79])]:_0x31df44([0x45,0x43]),[_0x31df44([0x75,0x73,0x65])]:_0x31df44([0x73,0x69,0x67]),[_0x31df44([0x63,0x72,0x76])]:_0x31df44([0x50,0x2d,0x32,0x35,0x36]),[_0x31df44([0x78])]:_0x31df44([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]),[_0x31df44([0x79])]:_0x31df44([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]),[_0x31df44([0x61,0x6c,0x67])]:_0x31df44([0x45,0x53,0x32,0x35,0x36])},_0x477a34=_0x39728a[_0x31df44([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x31df44([0x67,0x65,0x74])](_0x31df44([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x3b4293(){let _0x316088,_0x1055a6=null,_0xdf8aee=null;try{if(_0x477a34==_0x31df44([0x47,0x50,0x4c]))return _0x31df44([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x316088=_0x3c3c05(),!_0x316088)return _0x31df44([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x316088[_0x31df44([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0xdf8aee=_0x2c735c(_0x316088[_0x31df44([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x316088[_0x31df44([0x6a,0x74,0x69])])),await _0x419040()?_0xda8bcf()?_0x4022fb()?_0x31df44([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x56a530()?(_0x316088[_0x31df44([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x31df44([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x1055a6=_0x5af5d9(_0x31df44([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x316088[_0x31df44([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x31df44([0x74,0x72,0x69,0x61,0x6c])&&(_0x1055a6=_0x5af5d9(_0x31df44([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),await _0x5378e9()):_0x31df44([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x31df44([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x31df44([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch{return _0x31df44([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x4022fb(){const _0x4f833b=[_0x31df44([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x31df44([0x74,0x72,0x69,0x61,0x6c])][_0x31df44([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x316088[_0x31df44([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x26e4da/0x3e8:0xe10*_0x32f512;return _0x316088[_0x31df44([0x65,0x78,0x70])]<_0x4f833b;}function _0xda8bcf(){const _0x4b45d3=_0x316088[_0x31df44([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x4b45d3)return!0x1;if(_0x4b45d3[_0x31df44([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x31df44([0x2a])))return!0x0;if(_0x4b45d3[_0x31df44([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x31df44([0x52,0x48])))return!0x0;if(_0x4b45d3[_0x31df44([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x31df44([0x52,0x52,0x48]))){if(_0x5d018a())return!0x0;if(_0x33cfca()||_0x202343())return!0x0;}return!0x1;}function _0x56a530(){const _0x5a00bf=_0x316088[_0x31df44([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x5a00bf||0x0==_0x5a00bf[_0x31df44([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x272457}=new URL(window[_0x31df44([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x5a00bf[_0x31df44([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x272457))return!0x0;const _0x47391e=_0x272457[_0x31df44([0x73,0x70,0x6c,0x69,0x74])](_0x31df44([0x2e]));return _0x5a00bf[_0x31df44([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x404066=>_0x404066[_0x31df44([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x31df44([0x2a])))[_0x31df44([0x6d,0x61,0x70])](_0x407471=>_0x407471[_0x31df44([0x73,0x70,0x6c,0x69,0x74])](_0x31df44([0x2e])))[_0x31df44([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x1a7be9=>_0x1a7be9[_0x31df44([0x6c,0x65,0x6e,0x67,0x74,0x68])]<=_0x47391e[_0x31df44([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x31df44([0x6d,0x61,0x70])](_0x5b1740=>Array(_0x47391e[_0x31df44([0x6c,0x65,0x6e,0x67,0x74,0x68])]-_0x5b1740[_0x31df44([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x31df44([0x66,0x69,0x6c,0x6c])](_0x5b1740[0x0]===_0x31df44([0x2a])?_0x31df44([0x2a]):'')[_0x31df44([0x63,0x6f,0x6e,0x63,0x61,0x74])](_0x5b1740))[_0x31df44([0x73,0x6f,0x6d,0x65])](_0xa3a356=>_0x47391e[_0x31df44([0x65,0x76,0x65,0x72,0x79])]((_0xe09069,_0x335484)=>_0xa3a356[_0x335484]===_0xe09069||_0xa3a356[_0x335484]===_0x31df44([0x2a])));}function _0x5378e9(){return _0x1055a6&&_0xdf8aee?new window[(_0x31df44([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x1493dd,_0x406810)=>{_0x1055a6[_0x31df44([0x74,0x68,0x65,0x6e])](_0x1493dd,_0x406810),_0xdf8aee[_0x31df44([0x74,0x68,0x65,0x6e])](_0x27eedd=>{_0x27eedd!=_0x31df44([0x56,0x61,0x6c,0x69,0x64])&&_0x1493dd(_0x27eedd);},_0x406810);}):_0x1055a6||_0xdf8aee||_0x31df44([0x56,0x61,0x6c,0x69,0x64]);}}function _0x2c735c(_0x16df99,_0x2fe19d){return new window[(_0x31df44([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x3bd484=>{if(_0x282fbf())return _0x3bd484(_0x31df44([0x56,0x61,0x6c,0x69,0x64]));_0x437b49(),_0x39728a[_0x31df44([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x31df44([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x1a2255=!0x1;const _0x12921c=_0x4df7d4();function _0x4408e2(_0x1ef26e){return!!_0x1ef26e&&(typeof _0x1ef26e===_0x31df44([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x1ef26e===_0x31df44([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x1ef26e[_0x31df44([0x74,0x68,0x65,0x6e])]===_0x31df44([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x1ef26e[_0x31df44([0x63,0x61,0x74,0x63,0x68])]===_0x31df44([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x27b8a0(_0x2fce95){_0x800fcc(_0x2fce95)[_0x31df44([0x74,0x68,0x65,0x6e])](_0x5f5d65=>{if(!_0x5f5d65||_0x5f5d65[_0x31df44([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x31df44([0x6f,0x6b]))return _0x31df44([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x19bc6c(_0x5f3288(_0x12921c+_0x2fe19d))!=_0x5f5d65[_0x31df44([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x31df44([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x31df44([0x56,0x61,0x6c,0x69,0x64]);})[_0x31df44([0x74,0x68,0x65,0x6e])](_0x208d4b=>(_0x56088e(),_0x208d4b),()=>{const _0x3621ef=_0x2f641a();return null==_0x3621ef?(_0x56088e(),_0x31df44([0x56,0x61,0x6c,0x69,0x64])):_0x31df44(_0x26e4da-_0x3621ef>(0x5778dc5f^_0x5e6f07)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x31df44([0x74,0x68,0x65,0x6e])](_0x3bd484)[_0x31df44([0x63,0x61,0x74,0x63,0x68])](()=>{_0x3bd484(_0x31df44([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x264e35=0x7342b6df^_0x5e6f07;function _0x56088e(){const _0x114fd2=_0x31df44([0x6c,0x6c,0x63,0x74,0x2d])+_0x19bc6c(_0x5f3288(_0x16df99)),_0x575a5a=_0x52844d(_0x19bc6c(window[_0x31df44([0x4d,0x61,0x74,0x68])][_0x31df44([0x63,0x65,0x69,0x6c])](_0x26e4da/_0x264e35)));window[_0x31df44([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x31df44([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x114fd2,_0x575a5a);}function _0x2f641a(){const _0x51e7d5=_0x31df44([0x6c,0x6c,0x63,0x74,0x2d])+_0x19bc6c(_0x5f3288(_0x16df99)),_0x103491=window[_0x31df44([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x31df44([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x51e7d5);return _0x103491?window[_0x31df44([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x52844d(_0x103491),0x10)*_0x264e35:null;}function _0x800fcc(_0xf6c44e){return new window[(_0x31df44([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0xb909b9,_0x4cf79f)=>{_0xf6c44e[_0x31df44([0x74,0x68,0x65,0x6e])](_0xb909b9,_0x4cf79f),window[_0x31df44([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x4cf79f,0x73758c9f^_0x5e6f07);});}}_0x39728a[_0x31df44([0x6f,0x6e])](_0x31df44([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x81d16f,_0x1bd461)=>{if(_0x1bd461[0x0]!=_0x16df99)return _0x3bd484(_0x31df44([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x1bd461[0x1]={..._0x1bd461[0x1],[_0x31df44([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x12921c};},{[_0x31df44([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x31df44([0x68,0x69,0x67,0x68])}),_0x39728a[_0x31df44([0x6f,0x6e])](_0x31df44([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x24eef6=>{_0x4408e2(_0x24eef6[_0x31df44([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x1a2255=!0x0,_0x27b8a0(_0x24eef6[_0x31df44([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x31df44([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x31df44([0x6c,0x6f,0x77])}),_0x389240[_0x31df44([0x74,0x68,0x65,0x6e])](()=>{_0x1a2255||_0x3bd484(_0x31df44([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x282fbf(){return _0x39728a[_0x31df44([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x31df44([0x76,0x69,0x65,0x77])][_0x31df44([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x31df44([0x61,0x75,0x74,0x6f]);}function _0x437b49(){_0x39728a[_0x31df44([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x31df44([0x76,0x69,0x65,0x77])][_0x31df44([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x31df44([0x61,0x75,0x74,0x6f]);}}function _0x5af5d9(_0x3bed50){const _0x10e4e5=[new window[(_0x31df44([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x3e6b32=>setTimeout(_0x3e6b32,0x737d6693^_0x5e6f07)),_0x389240[_0x31df44([0x74,0x68,0x65,0x6e])](()=>new window[(_0x31df44([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x31586d=>{const _0x3ca42e=0x73745858^_0x5e6f07,_0x3070db=_0x1ebc20[_0x31df44([0x5f,0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x73])];function _0x1544f2(){_0x3070db[_0x31df44([0x6c,0x65,0x6e,0x67,0x74,0x68])]>=_0x3ca42e&&_0x31586d();}_0x1544f2(),_0x3070db[_0x31df44([0x6f,0x6e])](_0x31df44([0x61,0x64,0x64]),_0x1544f2);})),new window[(_0x31df44([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x3c30e7=>{function _0x244a62(){for(const _0xd1fb7f in window)if(window[_0x31df44([0x4e,0x75,0x6d,0x62,0x65,0x72])]['isNaN'](window[_0x31df44([0x4e,0x75,0x6d,0x62,0x65,0x72])](_0xd1fb7f))&&window[_0xd1fb7f]==_0xff3b8)return _0x3c30e7();_0x39728a[_0x31df44([0x73,0x74,0x61,0x74,0x65])]!=_0x31df44([0x64,0x65,0x73,0x74,0x72,0x6f,0x79,0x65,0x64])&&window[_0x31df44([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x244a62,0x73744bd7^_0x5e6f07);}_0x29ba41(_0x31df44([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))&&_0x244a62();})];return window[_0x31df44([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x31df44([0x72,0x61,0x63,0x65])](_0x10e4e5)[_0x31df44([0x74,0x68,0x65,0x6e])](()=>_0x3bed50);}async function _0x2ac0ae(){if(await _0x389240,_0x29ba41(_0x31df44([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))){const _0x4f813b=_0x1ebc20[_0x31df44([0x67,0x65,0x74,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](0x0),_0x3e31bb=_0x1ebc20[_0x31df44([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])](_0x4f813b[_0x31df44([0x69,0x64])]),_0x279369=_0x43b061(_0x31df44([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]));return await _0x279369[_0x31df44([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])](_0x4f813b['id'],_0x3e31bb?_0x3e31bb['id']:null,!0x0),_0x279369[_0x31df44([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x31df44([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x279369[_0x31df44([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x279369[_0x31df44([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])]=_0x5cde59,void(_0x279369[_0x31df44([0x5f,0x67,0x65,0x74,0x44,0x69,0x66,0x66])]=_0x5cde59);}if(_0x29ba41(_0x31df44([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]))){const _0x2e193c=_0x43b061(_0x31df44([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]));_0x2e193c[_0x31df44([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x31df44([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x2e193c[_0x31df44([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x2e193c[_0x31df44([0x75,0x70,0x64,0x61,0x74,0x65])]=_0x5cde59,_0x2e193c[_0x31df44([0x73,0x61,0x76,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])]=_0x5cde59;}_0x39728a[_0x31df44([0x6d,0x6f,0x64,0x65,0x6c])][_0x31df44([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x5cde59,_0x39728a[_0x31df44([0x6d,0x6f,0x64,0x65,0x6c])][_0x31df44([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x5cde59,_0x39728a[_0x31df44([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x31df44([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x5d018a(){return _0x29ba41(_0x31df44([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x43b061(_0x31df44([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x31df44([0x73,0x74,0x61,0x74,0x65])]==_0x31df44([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x33cfca(){return _0x29ba41(_0x31df44([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 _0x202343(){return _0x29ba41(_0x31df44([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0x34b3ec(_0x55bb04){const _0x4411a9=_0x516070();_0x39728a[_0x4411a9]=_0x31df44([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])+_0x55bb04,_0x55bb04[_0x31df44([0x65,0x6e,0x64,0x73,0x57,0x69,0x74,0x68])](_0x31df44([0x4c,0x69,0x6d,0x69,0x74]))&&(window[_0x516070()]=_0xff3b8),_0x55bb04!=_0x31df44([0x56,0x61,0x6c,0x69,0x64])&&_0x2ac0ae();}function _0x516070(){const _0x48edfa=window[_0x31df44([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x31df44([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x31df44([0x6e,0x6f,0x77])]())[_0x31df44([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x31df44([0x2e]),'');let _0x533c60=_0x31df44([0x73]);for(let _0x346777=0x0;_0x346777<_0x48edfa[_0x31df44([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x346777+=0x2){let _0x5c2074=window[_0x31df44([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x48edfa[_0x31df44([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x346777,_0x346777+0x2));_0x5c2074>=_0x3275fc[_0x31df44([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x5c2074-=_0x3275fc[_0x31df44([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x533c60+=_0x3275fc[_0x5c2074];}return _0x533c60;}function _0x3c3c05(){const _0x2428ec=_0x477a34[_0x31df44([0x73,0x70,0x6c,0x69,0x74])](_0x31df44([0x2e]));if(0x3!=_0x2428ec[_0x31df44([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x231802(_0x2428ec[0x1]);function _0x231802(_0x37c7d9){const _0x25cbd3=_0xb223a6(_0x37c7d9);return _0x25cbd3&&_0xbd9a3e()?_0x25cbd3:null;function _0xbd9a3e(){const _0x5f4e5d=_0x25cbd3[_0x31df44([0x6a,0x74,0x69])],_0x40e86f=window[_0x31df44([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x5f4e5d[_0x31df44([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x5f4e5d[_0x31df44([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x27f61d={..._0x25cbd3,[_0x31df44([0x6a,0x74,0x69])]:_0x5f4e5d[_0x31df44([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x5f4e5d[_0x31df44([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x27f61d[_0x31df44([0x76,0x63])],_0x5f3288(_0x27f61d)==_0x40e86f;}}}async function _0x419040(){let _0x2b611c=!0x0;try{const _0x59cc76=_0x477a34[_0x31df44([0x73,0x70,0x6c,0x69,0x74])](_0x31df44([0x2e])),[_0x4a4274,_0x1c3ebe,_0x49bbf0]=_0x59cc76;return _0x51625b(_0x4a4274),await _0x5d2f9b(_0x4a4274,_0x1c3ebe,_0x49bbf0),_0x2b611c;}catch{return!0x1;}function _0x51625b(_0x2bc49d){const _0xd18eed=_0xb223a6(_0x2bc49d);_0xd18eed&&_0xd18eed[_0x31df44([0x61,0x6c,0x67])]==_0x31df44([0x45,0x53,0x32,0x35,0x36])||(_0x2b611c=!0x1);}async function _0x5d2f9b(_0x46c03c,_0x246d2c,_0x1b04f1){const _0x388267=window[_0x31df44([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x31df44([0x66,0x72,0x6f,0x6d])](_0x3ef371(_0x1b04f1),_0x5d347c=>_0x5d347c[_0x31df44([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x558016=new window[(_0x31df44([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x31df44([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x46c03c+_0x31df44([0x2e])+_0x246d2c),_0x493b7c=window[_0x31df44([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x31df44([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x493b7c)return;const _0x2d191b=await _0x493b7c[_0x31df44([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x31df44([0x6a,0x77,0x6b]),_0x112eaf,{[_0x31df44([0x6e,0x61,0x6d,0x65])]:_0x31df44([0x45,0x43,0x44,0x53,0x41]),[_0x31df44([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x31df44([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x31df44([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x493b7c[_0x31df44([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x31df44([0x6e,0x61,0x6d,0x65])]:_0x31df44([0x45,0x43,0x44,0x53,0x41]),[_0x31df44([0x68,0x61,0x73,0x68])]:{[_0x31df44([0x6e,0x61,0x6d,0x65])]:_0x31df44([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x2d191b,_0x388267,_0x558016)||(_0x2b611c=!0x1);}}function _0xb223a6(_0x206da6){return _0x206da6[_0x31df44([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x31df44([0x65,0x79]))?JSON[_0x31df44([0x70,0x61,0x72,0x73,0x65])](_0x3ef371(_0x206da6)):null;}function _0x3ef371(_0x47dc4a){return window[_0x31df44([0x61,0x74,0x6f,0x62])](_0x47dc4a[_0x31df44([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x31df44([0x2b]))[_0x31df44([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x31df44([0x2f])));}function _0x5f3288(_0x3b26fa){let _0x1680bc=0x1505;function _0x49d286(_0x331b95){for(let _0x447623=0x0;_0x447623<_0x331b95[_0x31df44([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x447623++){const _0x210574=_0x331b95[_0x31df44([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x447623);_0x1680bc=(_0x1680bc<<0x5)+_0x1680bc+_0x210574,_0x1680bc&=_0x1680bc;}}function _0x28ba35(_0x2eccf0){Array[_0x31df44([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x2eccf0)?_0x2eccf0[_0x31df44([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x28ba35):_0x2eccf0&&typeof _0x2eccf0==_0x31df44([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x31df44([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x2eccf0)[_0x31df44([0x73,0x6f,0x72,0x74])]()[_0x31df44([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x3191d5,_0x5db9de])=>{_0x49d286(_0x3191d5),_0x28ba35(_0x5db9de);}):_0x49d286(window[_0x31df44([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x2eccf0));}return _0x28ba35(_0x3b26fa),_0x1680bc>>>0x0;}function _0x19bc6c(_0x394828){return _0x394828[_0x31df44([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x31df44([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x31df44([0x30]));}function _0x52844d(_0x21c07b){return _0x21c07b[_0x31df44([0x73,0x70,0x6c,0x69,0x74])]('')[_0x31df44([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x31df44([0x6a,0x6f,0x69,0x6e])]('');}function _0x29ba41(_0x112701){return _0x39728a[_0x31df44([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x31df44([0x68,0x61,0x73])](_0x112701);}function _0x43b061(_0x2a4ce0){return _0x39728a[_0x31df44([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x31df44([0x67,0x65,0x74])](_0x2a4ce0);}function _0x5cde59(){}function _0x31df44(_0x419245){return _0x419245['map'](_0x2f7a52=>String['fromCharCode'](_0x2f7a52))['join']('');}_0x34b3ec(await _0x3b4293());}(this);}['createRevision'](_0xbe3c90){const _0x855019=this['editor']['plugins']['get']('Users');return new I({'id':_0xbe3c90['id'],'name':_0xbe3c90['name'],'creator':_0xbe3c90['creatorId']?_0x855019['getUser'](_0xbe3c90['creatorId']):null,'diffData':_0xbe3c90['diffData']||_0xbe3c90['data'],'authors':_0xbe3c90['authorsIds']['map'](_0x5b0c79=>_0x855019['getUser'](_0x5b0c79)),'createdAt':new Date(_0xbe3c90['createdAt']),'attributes':_0xbe3c90['attributes'],'fromVersion':_0xbe3c90['fromVersion'],'toVersion':_0xbe3c90['toVersion']});}['addRevision'](_0x102eb5,_0x362a2d=0x0){this['_revisions']['add'](_0x102eb5,_0x362a2d);}['getRevision'](_0x5c5cf4){return this['_revisions']['get'](_0x5c5cf4);}['getRevisions'](_0x5286a4={'toJSON':!0x1}){const _0x4db729=Array['from'](this['_revisions']);return _0x4db729['reverse'](),_0x5286a4['toJSON']?_0x4db729['map'](_0x5d96ab=>_0x5d96ab['toJSON']()):_0x4db729;}['getIndex'](_0x4b8be6){return this['_revisions']['getIndex'](_0x4b8be6);}['getEarlierVisibleRevision'](_0x207a98){const [,_0x5e6efd]=this['getRevisionsIterator'](_0x207a98,{'direction':'earlier'});return _0x5e6efd;}['getLaterVisibleRevision'](_0x3fde90){const [,_0x16b2a7]=this['getRevisionsIterator'](_0x3fde90,{'direction':'later'});return _0x16b2a7;}['getRevisionsInDiff'](_0x4208a6){const _0x38a4a5=[];for(const _0x540be3 of this['getRevisionsIterator'](_0x4208a6['newRevisionId']))if(_0x38a4a5['push'](_0x540be3),_0x540be3['id']===_0x4208a6['oldRevisionId'])break;return _0x38a4a5;}*['getRevisionsIterator'](_0x4a4e31,{direction:_0x4c5ce7='earlier',filter:_0x35d185=()=>!0x0}={}){const _0x2387d5='earlier'===_0x4c5ce7?0x1:-0x1;let _0x129df6=this['_revisions']['get'](_0x4a4e31),_0x4142b3=this['getIndex'](_0x129df6);for(yield _0x129df6;_0x129df6;){if(_0x4142b3+=_0x2387d5,_0x129df6=this['getRevision'](_0x4142b3),!_0x129df6)return;_0x35d185(_0x129df6)&&(yield _0x129df6);}}}class $ extends _0x280bdd{static get['pluginName'](){return'RevisionHistoryUtils';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['_viewClassToTypeChar']=new Map([[_0x1a066a,'c'],[_0x36fac9,'a'],[_0x464fd4,'e'],[_0x53660b,'r'],[_0x15608e,'u']]);['_typeCharToViewClass']=new Map([['c',_0x1a066a],['a',_0x36fac9],['e',_0x464fd4],['r',_0x53660b],['u',_0x15608e]]);async['loadRevisionData'](_0x3cc5d6,_0x34637d){if(_0x3cc5d6['diffData']||!_0x34637d)return;const _0x539979=this['editor']['config']['get']('collaboration.channelId'),_0x4be530=await _0x34637d['getRevision']({'channelId':_0x539979,'revisionId':_0x3cc5d6['id']});_0x3cc5d6['diffData']=_0x4be530['diffData'];}['getRevisionDocumentData'](_0x1023c7){const _0x9f634a={};for(const _0x1e7cd9 in _0x1023c7['diffData']){if(_0x1023c7['diffData'][_0x1e7cd9]['attachChange']&&!_0x1023c7['diffData'][_0x1e7cd9]['attachChange']['isAttached'])continue;const _0x5913f5=this['_removeRevisionMarkers'](JSON['parse'](_0x1023c7['diffData'][_0x1e7cd9]['insertions'])),_0x8b1ec4=this['editor']['editing']['view']['document'],_0x26532a=new _0x49b5e5(_0x8b1ec4,_0x5913f5['map'](_0x2c5c53=>this['_getViewFromDiffObj'](_0x2c5c53,!0x1)));this['editor']['data']['processor']['useFillerType']('marked'),_0x9f634a[_0x1e7cd9]=this['editor']['data']['processor']['toData'](_0x26532a),this['editor']['data']['processor']['useFillerType']('default');}return _0x9f634a;}['getRevisionRootsAttributes'](_0x35cb69){const _0x5eb071={};for(const _0x543a79 in _0x35cb69['diffData'])_0x35cb69['diffData'][_0x543a79]['attachChange']&&!_0x35cb69['diffData'][_0x543a79]['attachChange']['isAttached']||(_0x5eb071[_0x543a79]=_0x35cb69['diffData'][_0x543a79]['attributesAfter']||{});return _0x5eb071;}['_getTypeCharForViewElement'](_0x3afb13){return this['_viewClassToTypeChar']['get'](_0x3afb13['constructor']);}['_getViewFromDiffObj'](_0x5aad32,_0xd66f0e){const _0x1c8d1c=this['editor']['editing']['view']['document'];if('string'==typeof _0x5aad32)return new _0x3138c4(_0x1c8d1c,_0x5aad32);{let _0x4a6490,_0x456bf3;_0x456bf3='u'==_0x5aad32['type']||'r'==_0x5aad32['type']?[]:_0x5aad32['children']['map'](_0x4bf8e1=>this['_getViewFromDiffObj'](_0x4bf8e1,_0xd66f0e));const _0x41698e=this['_typeCharToViewClass']['get'](_0x5aad32['type'])||_0x33b3f1,_0x2e6592=this['editor']['data']['htmlProcessor']['domConverter'];if(_0x4a6490=new _0x41698e(_0x1c8d1c,_0x5aad32['name'],_0x5aad32['attributes'],_0x456bf3),'u'==_0x5aad32['type']&&_0x5aad32['children'][0x0]){const _0x3b6557=_0x5aad32['children'][0x0];if(_0x4a6490['render']=function(_0x2a6328){const _0x18e207=_0x2a6328['createElement']('div');return _0x18e207['innerHTML']=_0x3b6557,_0x18e207['childNodes'][0x0];},_0xd66f0e){const _0x5efee4=new _0x49b5e5(_0x1c8d1c);_0x5efee4['_appendChild'](_0x4a6490);const _0x565a7f=Array['from'](_0x2e6592['viewChildrenToDom'](_0x5efee4,{'bind':!0x1})),_0x97d2f9=_0x2e6592['domDocument']['createElement']('div');_0x97d2f9['append'](..._0x565a7f),_0x4a6490=Array['from'](_0x2e6592['domChildrenToView'](_0x97d2f9))[0x0];}}else{if('r'==_0x5aad32['type']&&_0x5aad32['children'][0x0]){const _0x4c462a=_0x5aad32['children'][0x0];if(_0x4a6490['render']=function(_0x3934a0){_0x3934a0['innerHTML']=_0x4c462a;},_0xd66f0e){const _0x3b6430=new _0x49b5e5(_0x1c8d1c);_0x3b6430['_appendChild'](_0x4a6490);const _0x9f218=Array['from'](_0x2e6592['viewChildrenToDom'](_0x3b6430,{'bind':!0x1})),_0x342360=_0x2e6592['domDocument']['createElement']('div');_0x342360['append'](..._0x9f218);const _0x315094=Array['from'](_0x2e6592['domChildrenToView'](_0x342360));_0x315094['length']>0x1?_0x4a6490['_appendChild'](_0x315094):_0x4a6490=_0x315094[0x0];}}}if(_0x5aad32['customProperties']){for(const [_0x2c2167,_0x54ffae]of _0x5aad32['customProperties'])_0x4a6490['_setCustomProperty'](_0x2c2167,_0x54ffae);}const _0x53b58a=void 0x0===_0x5aad32['fillerOffset']?null:_0x5aad32['fillerOffset'];return null!==_0x53b58a&&(_0x4a6490['getFillerOffset']=()=>_0x53b58a),_0x4a6490;}}['_makeModelFromViewString'](_0x156fed){const _0x2ff694=JSON['parse'](_0x156fed),_0x3d4269=this['editor']['editing']['view']['document'],_0x291b13=new _0x49b5e5(_0x3d4269,_0x2ff694['map'](_0xb679ec=>this['_getViewFromDiffObj'](_0xb679ec,!0x0)));return this['editor']['data']['toModel'](_0x291b13);}['_removeRevisionMarkers'](_0x2b2298){return(_0x2b2298=_0x2b2298['filter'](_0x2e3b92=>!_0x2e3b92['name']||'revision-start'!==_0x2e3b92['name']&&'revision-end'!==_0x2e3b92['name']))['forEach'](_0x658737=>{'string'!=typeof _0x658737&&(_0x658737['children']=this['_removeRevisionMarkers'](_0x658737['children']),_0x658737['attributes']=_0x658737['attributes']['filter'](_0x562b85=>!_0x562b85[0x0]['startsWith']('data-revision-')));}),_0x2b2298;}}function R(_0x253a87,_0x7158b0,_0x5cec8d){const t=_0x253a87['t'];switch(_0x7158b0){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'},_0x5cec8d);case'X_OF_Y_CHANGES':return t({'string':'%0\x20of\x20%1','id':'X_OF_Y_CHANGES'},_0x5cec8d);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 _0x280bdd{['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[_0x1439ad,S,$,_0x45514d];}constructor(_0x42cbac){super(_0x42cbac),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 _0x3cbc7b=_0x4df7d4();this['_source']={'history':this['editor']['model']['document']['history'],'getLatestVersion':()=>Promise['resolve'](this['editor']['model']['document']['version']),'getCurrentRevisionId':()=>_0x3cbc7b},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 _0x3d8051=this['repository']['getRevision'](0x0),_0x306022=_0x3d8051&&null===_0x3d8051['creator']?_0x3d8051:null;if(this['_continueCurrentRevision']=!!_0x306022&&this['editor']['config']['get']('revisionHistory.resumeUnsavedRevision'),this['editor']['plugins']['has']('RealTimeCollaborationClient')){const _0x9aadf0=this['_source']['getCurrentRevisionId'](),_0x520974=this['repository']['getRevision'](_0x9aadf0);if(_0x520974)this['_startingVersion']=_0x520974['fromVersion'],this['_continueCurrentRevision']=!0x1;else{const _0x5a1441=this['_source']['history']['_operations']['find'](_0x5cee67=>!_0x5cee67['_isInit']),_0x1ad016=_0x5a1441?_0x5a1441['baseVersion']:this['_source']['history']['version'];_0x3d8051?(_0x3d8051['toVersion']<_0x1ad016&&_0x3d8051['_update']({'toVersion':_0x1ad016}),this['_continueCurrentRevision']?(this['_source']['getCurrentRevisionId']=()=>_0x306022['id'],this['_startingVersion']=_0x306022['fromVersion']):(this['_startingVersion']=_0x3d8051['toVersion'],this['_continueCurrentRevision']=!0x1)):(this['_startingVersion']=_0x1ad016,this['_continueCurrentRevision']=!0x1);}}else _0x306022&&(this['editor']['model']['document']['history']['version']=Math['max'](_0x306022['toVersion'],this['editor']['model']['document']['history']['version']),_0x306022['fromVersion']===_0x306022['toVersion']?(0x0!==_0x306022['fromVersion']&&(this['_source']['getCurrentRevisionId']=()=>_0x306022['id']),this['_continueCurrentRevision']=!0x1):this['_continueCurrentRevision']&&(this['_source']['getCurrentRevisionId']=()=>_0x306022['id'],this['_startingVersion']=_0x306022['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',_0x294f65=>!_0x294f65),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x18d9f7=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x229a9a;for(const _0x35704b in _0x18d9f7){const _0x2eb696=_0x35704b,_0x3c868f=_0x18d9f7[_0x2eb696];if('revisionHistoryLicenseKeyValid'==_0x3c868f||'revisionHistoryLicenseKeyInvalid'==_0x3c868f||'revisionHistoryLicenseKeyExpired'==_0x3c868f||'revisionHistoryLicenseKeyDomainLimit'==_0x3c868f||'revisionHistoryLicenseKeyNotAllowed'==_0x3c868f||'revisionHistoryLicenseKeyEvaluationLimit'==_0x3c868f||'revisionHistoryLicenseKeyTrialLimit'==_0x3c868f||'revisionHistoryLicenseKeyUsageLimit'==_0x3c868f){delete _0x18d9f7[_0x2eb696],_0x229a9a=_0x3c868f,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'revisionHistoryLicenseKeyInvalid'==_0x229a9a&&_0x18d9f7['_showLicenseError']('invalid'),'revisionHistoryLicenseKeyExpired'==_0x229a9a&&_0x18d9f7['_showLicenseError']('expired'),'revisionHistoryLicenseKeyDomainLimit'==_0x229a9a&&_0x18d9f7['_showLicenseError']('domainLimit'),'revisionHistoryLicenseKeyNotAllowed'==_0x229a9a&&_0x18d9f7['_showLicenseError']('featureNotAllowed','RevisionHistory'),'revisionHistoryLicenseKeyEvaluationLimit'==_0x229a9a&&_0x18d9f7['_showLicenseError']('evaluationLimit'),'revisionHistoryLicenseKeyTrialLimit'==_0x229a9a&&_0x18d9f7['_showLicenseError']('trialLimit'),'revisionHistoryLicenseKeyUsageLimit'==_0x229a9a&&_0x18d9f7['_showLicenseError']('usageLimit');},0x3e8);}async['afterInit'](){if(this['repository']['length']>0x0){const _0x5a4c88=this['repository']['getRevision'](0x0),_0x18ac8c=await this['getRevisionDocumentData'](_0x5a4c88),_0x5374a5=await this['getRevisionRootsAttributes'](_0x5a4c88);this['_replaceEditorDataWithRevisionData'](_0x18ac8c,_0x5374a5);}}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['setSource'](_0x38a03a){this['_source']=_0x38a03a;}async['update'](){const _0x3823bd=await this['_source']['getLatestVersion']();if(_0x3823bd>this['currentRevision']['toVersion']){await this['_loadState']();const _0x267e44=this['buildRevisionData']({'revision':this['currentRevision'],'to':_0x3823bd});_0x267e44['authors']=_0x267e44['authorsIds']['map'](_0x26fa04=>this['editor']['plugins']['get']('Users')['getUser'](_0x26fa04)),this['currentRevision']['_update'](_0x267e44);}}async['saveRevision'](_0x49414a={},_0x361f21=null){const _0x547941=[];await this['_loadState'](),this['_continueCurrentRevision']=!0x1,_0x361f21>this['currentRevision']['toVersion']&&(_0x361f21=null),null===_0x361f21&&(_0x361f21=await this['_source']['getLatestVersion']());const _0x202aa9=this['_getFromVersion'](_0x361f21),_0x3afb29=this['buildRevisionData']({'from':_0x202aa9,'to':_0x361f21});if(this['currentRevision']['toVersion']<_0x361f21){const _0x107a3b=this['buildRevisionData']({'revision':this['currentRevision'],'from':_0x361f21,'to':_0x361f21});_0x107a3b['authors']=[],_0x107a3b['authorsIds']=[],_0x107a3b['id']=this['currentRevision']['id'],this['currentRevision']['_update'](_0x107a3b,!0x0),delete _0x107a3b['authors'],_0x547941['push'](_0x107a3b);}_0x49414a['creatorId']=this['editor']['plugins']['get']('Users')['me']['id'],_0x49414a['name']=_0x49414a['name']||null,_0x49414a['id']=_0x49414a['id']||_0x4df7d4(),_0x49414a={..._0x49414a,..._0x3afb29};const _0x10ecf6=this['addRevisionData'](_0x49414a);_0x547941['push'](_0x49414a);const _0x3fe429=this['repository']['getIndex'](_0x10ecf6);if(0x0!==_0x3fe429){const _0x3a9faa=this['repository']['getRevision'](_0x3fe429-0x1);if(_0x3a9faa['fromVersion']!==_0x361f21){const _0x232d11=this['_revisionDataBuilder']['getData'](_0x361f21,_0x3a9faa['toVersion']),_0xc3c2bb={'id':_0x3a9faa['id'],'diffData':_0x232d11['diffData'],'authorsIds':_0x232d11['authorsIds'],'authors':_0x232d11['authorsIds']['map'](_0x43b7ac=>this['editor']['plugins']['get']('Users')['getUser'](_0x43b7ac)),'fromVersion':_0x361f21};_0x3a9faa===this['currentRevision']&&(_0xc3c2bb['createdAt']=new Date(_0x49414a['createdAt']['getTime']()+0xa)),_0x3a9faa['_update'](_0xc3c2bb,!0x0),delete _0xc3c2bb['authors'],_0x547941['push'](_0xc3c2bb);}}if(this['adapter']){for(const _0x12ebfc of _0x547941)this['_bufferUpdate'](_0x12ebfc['id'],_0x12ebfc,!0x0);this['sendBufferedUpdates']();}return _0x10ecf6;}['addRevisionData'](_0xeacc4c){const _0x426a8d=this['repository']['createRevision'](_0xeacc4c);return this['adapter']&&_0x426a8d['on']('_update',(_0x2c8483,_0x197ece,_0x490c71)=>{_0x490c71||(this['_bufferUpdate'](_0x197ece['id'],_0x197ece,!0x0),this['sendBufferedUpdates']());}),this['repository']['addRevision'](_0x426a8d,this['_findInsertionIndex'](_0x426a8d)),_0x426a8d;}async['getRevisionDocumentData'](_0x1ab44a){return await this['_utils']['loadRevisionData'](_0x1ab44a,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x1ab44a);}async['getRevisionRootsAttributes'](_0x5000ae){return await this['_utils']['loadRevisionData'](_0x5000ae,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x5000ae);}['sendBufferedUpdates'](){if(0x0===this['_bufferedUpdates']['size'])return;if(this['_isPendingUpdate'])return;let _0xe3689a=Array['from'](this['_bufferedUpdates']['values']());this['_bufferedUpdates']['clear']();for(let _0x3afd9f=0x0;_0x3afd9f<_0xe3689a['length'];_0x3afd9f++){const _0x1c1930=_0xe3689a[_0x3afd9f];let _0x123061=!0x1;for(const _0xafdeeb of Object['keys'](_0x1c1930))void 0x0===_0x1c1930[_0xafdeeb]?delete _0x1c1930[_0xafdeeb]:'id'!==_0xafdeeb&&(_0x123061=!0x0);_0x123061||(_0xe3689a[_0x3afd9f]=null);}if(_0xe3689a=_0xe3689a['filter'](_0x215a69=>null!==_0x215a69),!_0xe3689a['length'])return;for(let _0x5af254=0x0;_0x5af254<_0xe3689a['length'];_0x5af254++){const _0xbcb317=_0xe3689a[_0x5af254];void 0x0!==_0xbcb317['fromVersion']&&void 0x0===_0xbcb317['toVersion']&&(_0xbcb317['toVersion']=this['repository']['getRevision'](_0xbcb317['id'])['toVersion']),void 0x0!==_0xbcb317['toVersion']&&void 0x0===_0xbcb317['fromVersion']&&(_0xbcb317['fromVersion']=this['repository']['getRevision'](_0xbcb317['id'])['fromVersion']);}const _0xd3cf0f=this['editor']['config']['get']('collaboration.channelId');this['_isPendingUpdate']=!0x0,this['_addPendingAction'](),this['adapter']['updateRevisions'](_0xe3689a,_0xd3cf0f)['finally'](()=>{this['_isPendingUpdate']=!0x1;})['then'](_0x229525=>{if(_0x229525){for(const _0x289daf of _0x229525)this['setRevisionData']({'id':_0x289daf['id'],'createdAt':_0x289daf['createdAt']});}this['_removePendingAction'](),this['sendBufferedUpdates']();});}['buildRevisionData']({revision:_0x59cd10=null,from:_0x4acf46=null,to:_0x77874a=null}){_0x4acf46=null!==_0x4acf46?_0x4acf46:_0x59cd10['fromVersion'],_0x77874a=null!==_0x77874a?_0x77874a:_0x59cd10['toVersion'];const _0x193624=this['_revisionDataBuilder']['getData'](_0x4acf46,_0x77874a),_0x380a22={'diffData':_0x193624['diffData'],'authorsIds':_0x193624['authorsIds'],'fromVersion':_0x4acf46,'toVersion':_0x77874a};if(!_0x59cd10||_0x77874a!==_0x59cd10['toVersion']){const _0xc676d=_0x77874a-0x1,_0x5f1d46=this['_source']['history']['getOperation'](_0xc676d);_0x380a22['createdAt']=_0x5f1d46&&_0x5f1d46['createdAt']||new Date();}if(this['_loadedStateData']&&_0x4acf46===this['_loadedStateData']['fromVersion']){for(const _0x2907cb of this['_loadedStateData']['authors'])_0x380a22['authorsIds']['includes'](_0x2907cb['id'])||_0x380a22['authorsIds']['push'](_0x2907cb['id']);}return _0x380a22;}['_bufferUpdate'](_0x56d9fe,_0x40639c,_0x491b01){if(this['_bufferedUpdates']['has'](_0x56d9fe)){const _0x467b46=this['_bufferedUpdates']['get'](_0x56d9fe);_0x40639c=_0x491b01?{..._0x467b46,..._0x40639c}:{..._0x40639c,..._0x467b46};}this['_bufferedUpdates']['set'](_0x56d9fe,_0x40639c);}['setRevisionData'](_0x5d3e5b){const _0x3247c6=this['repository']['getRevision'](_0x5d3e5b['id']);if(_0x5d3e5b['createdAt']&&(_0x5d3e5b['createdAt']=new Date(_0x5d3e5b['createdAt'])),_0x5d3e5b['authorsIds']){const _0x5d1b43=this['editor']['plugins']['get']('Users');_0x5d3e5b['authors']=_0x5d3e5b['authorsIds']['map'](_0x2d4b41=>_0x5d1b43['getUser'](_0x2d4b41));}_0x3247c6['_update'](_0x5d3e5b,!0x0);}['_createInitialRevision'](_0x3c39a3){const _0x5b64fe=this['repository']['getRevision'](this['repository']['length']-0x1);if(_0x5b64fe)this['_initialRevisionId']=_0x5b64fe['id'];else{const _0x250e4e=!this['editor']['model']['document']['roots']['find'](_0x14caa3=>this['editor']['model']['hasContent'](_0x14caa3)),_0x131e44=this['editor']['plugins']['get']('Users')['me']['id'],_0x2474d7=R(this['editor']['locale'],_0x250e4e?'Empty\x20document':'Initial\x20revision');this['_makeRevision']({'from':_0x3c39a3,'to':_0x3c39a3,'id':this['_initialRevisionId'],'name':_0x2474d7,'creatorId':_0x131e44});}}['_createCurrentRevision'](_0x793ff5){const _0xf0c2f3=this['_source']['getCurrentRevisionId']();this['currentRevision']=this['repository']['getRevision'](_0xf0c2f3),this['currentRevision']||(this['currentRevision']=this['_makeRevision']({'from':_0x793ff5,'to':_0x793ff5,'id':_0xf0c2f3,'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'](_0x4b99f1,_0x122974){let _0x141b86=this['editor']['config']['get']('initialData'),_0x568f58=this['editor']['config']['get']('rootsAttributes');if(void 0x0===_0x141b86){_0x141b86={};for(const _0xbdcb71 of this['editor']['model']['document']['getRootNames']())_0x141b86[_0xbdcb71]='';}if('string'==typeof _0x141b86&&(_0x141b86={'main':_0x141b86}),void 0x0===_0x568f58){_0x568f58={};for(const _0x416d0e of this['editor']['model']['document']['getRootNames']())_0x568f58[_0x416d0e]={};}let _0x58a21c=!0x1;const _0x5b0213=Object['keys'](_0x141b86),_0x7e3c2a=Object['keys'](_0x4b99f1);for(const _0x303df9 of _0x5b0213){if(_0x141b86[_0x303df9]!==_0x4b99f1[_0x303df9]&&''!==_0x141b86[_0x303df9]['trim']()){_0x58a21c=!0x0;break;}if(!_0x312f3e(_0x568f58[_0x303df9],_0x122974[_0x303df9])&&Object['keys'](_0x568f58[_0x303df9])['length']>0x0){_0x58a21c=!0x0;break;}}_0x58a21c||(_0x58a21c=_0x7e3c2a['some'](_0x5198f0=>!this['editor']['model']['document']['getRoot'](_0x5198f0))),_0x58a21c&&_0x287230('editor-initial-data-replaced-with-revision-data',{'editorData':_0x141b86,'editorRootsAttributes':_0x568f58,'revisionData':_0x4b99f1,'revisionRootsAttributes':_0x122974}),this['editor']['config']['set']('initialData',_0x4b99f1),this['editor']['config']['set']('rootsAttributes',_0x122974);}['_addPendingAction'](){if(!this['_pendingAction']){const _0x4a2582=this['editor']['plugins']['get']('PendingActions');this['_pendingAction']=_0x4a2582['add'](R(this['editor']['locale'],'PENDING_ACTION_REVISION_HISTORY'));}}['_removePendingAction'](){this['_pendingAction']&&(this['editor']['plugins']['get']('PendingActions')['remove'](this['_pendingAction']),this['_pendingAction']=null);}['_findInsertionIndex'](_0x4d414e){const _0x39e1a4=this['repository']['getRevisions']();_0x39e1a4['reverse']();let _0x512f19=0x0;for(;_0x512f19<_0x39e1a4['length'];){const _0x193d8f=_0x39e1a4[_0x512f19];if(_0x193d8f===this['currentRevision']){_0x512f19++;continue;}if(_0x193d8f['id']===this['_initialRevisionId'])break;const _0x257db8=_0x4d414e['toVersion']-_0x193d8f['toVersion']||_0x4d414e['fromVersion']-_0x193d8f['fromVersion'];if(_0x257db8>0x0)break;if(_0x257db8<0x0)_0x512f19++;else{if(!_0x4d414e['creator']&&_0x193d8f['creator'])break;if(_0x193d8f['creator']||!_0x4d414e['creator']){if(_0x4d414e['createdAt']>_0x193d8f['createdAt'])break;_0x512f19++;}else _0x512f19++;}}return _0x512f19;}['_getFromVersion'](_0xaaa129){const _0x5848c7=this['repository']['getRevisions']();_0x5848c7['reverse'](),_0x5848c7['shift']();const _0x2ec5e2=_0x5848c7['find'](_0x2f70bb=>_0x2f70bb['toVersion']<=_0xaaa129)['toVersion'];return _0x2ec5e2<this['_startingVersion']?this['_startingVersion']:_0x2ec5e2;}['_makeRevision']({name:_0x5aec77,from:_0x304897,to:_0x25c711,creatorId:_0x4a3597,id:_0x212d64}){const _0xcd5eef=this['buildRevisionData']({'from':_0x304897,'to':_0x25c711});_0xcd5eef['name']=_0x5aec77,_0xcd5eef['creatorId']=_0x4a3597,_0xcd5eef['id']=_0x212d64;const _0x560eaf=this['addRevisionData'](_0xcd5eef);return this['adapter']&&this['_bufferUpdate'](_0xcd5eef['id'],_0xcd5eef,!0x0),_0x560eaf;}['_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(_0xe36758){this['editor']=_0xe36758,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'](_0x4a9b89){this['source']=_0x4a9b89;const _0x16eb0b=new Map(),_0x5b39d7=new Map(),_0x49f37f=this['editor']['model']['document']['roots']['map'](_0x41acda=>_0x41acda['rootName']);for(const _0x300ae8 of _0x49f37f){const _0x567e81=this['editor']['model']['document']['getRoot'](_0x300ae8),_0xabee25=x(_0x567e81);_0x16eb0b['set'](_0x300ae8,_0xabee25),_0x5b39d7['set'](_0x300ae8,Object['fromEntries'](_0x567e81['getAttributes']()));}const _0x12073d=Array['from'](this['editor']['model']['markers'])['map'](_0x589ce7=>[_0x589ce7['name'],_0x589ce7['getRange']()]),_0x42940e=this['source']['version'];this['_saveMetaData'](_0x42940e,_0x16eb0b,_0x12073d,_0x5b39d7),this['_startingRevisionId']=this['_revisionId'];const _0x45b52c=new Map(),_0x159b30=new Map();for(const _0x1e8d84 of _0x49f37f){const _0x48c55c=N(_0x1e8d84);_0x45b52c['set'](_0x1e8d84,_0x48c55c),_0x159b30['set'](_0x1e8d84,{});}this['_saveMetaData'](Number['NEGATIVE_INFINITY'],_0x45b52c,[],_0x159b30);}['getData'](_0x22ec14,_0x5aab6e){if(this['_lastFrom']===_0x22ec14&&this['_lastTo']<=_0x5aab6e)this['_savedMetaData']['size']>0x1&&this['_removeMetaData'](this['_lastTo']),this['_applyOperations'](this['_lastTo'],_0x5aab6e,!0x0);else{if(!this['_savedMetaData']['has'](_0x22ec14)){const _0x188c00=this['_getPreviousFrom'](_0x22ec14);this['_calculateMetaData'](_0x188c00,_0x22ec14,!0x1);}this['_calculateMetaData'](_0x22ec14,_0x5aab6e,!0x0);}return this['_lastFrom']=_0x22ec14,this['_lastTo']=_0x5aab6e,this['_getState']();}['loadState'](_0x29edd2){if(!this['_savedMetaData']['has'](_0x29edd2['fromVersion'])){const _0xe8670b=this['_getPreviousFrom'](_0x29edd2['fromVersion']);this['_calculateMetaData'](_0xe8670b,_0x29edd2['fromVersion'],!0x1);}this['_calculateMetaData'](_0x29edd2['fromVersion'],_0x29edd2['toVersion'],!0x1);const _0x388249=this['editor']['plugins']['get']('RevisionHistoryUtils');this['_reset'](),this['_lastFrom']=_0x29edd2['fromVersion'],this['_lastTo']=_0x29edd2['toVersion'];for(const _0x3c60ce in _0x29edd2['diffData']){const _0xe0fb54=_0x29edd2['diffData'][_0x3c60ce]['attachChange'],_0x4897f2=_0x13ac74(_0x29edd2['diffData'][_0x3c60ce]['attributesBefore'])||{},_0x383ee4=_0x388249['_makeModelFromViewString'](_0x29edd2['diffData'][_0x3c60ce]['deletions']);_0x383ee4['rootName']=_0x3c60ce,_0x383ee4['_isAttached']=!_0xe0fb54||!_0xe0fb54['isAttached'],_0x383ee4['isAttached']=()=>_0x383ee4['_isAttached'],this['_baseRoots']['set'](_0x3c60ce,_0x383ee4),this['_baseRootsAttributes']['set'](_0x3c60ce,_0x4897f2),_0xe0fb54&&this['_touchedRoots']['set'](_0x3c60ce,_0xe0fb54);const _0x49f07e=this['_makeIdsRoot'](_0x383ee4);this['_baseIdsRoots']['set'](_0x3c60ce,_0x49f07e);for(const [_0x1768f6,_0x6cac5e]of _0x383ee4['markers']){if(!_0x1768f6['startsWith']('revision:'))continue;const _0x2c0397=_0x1768f6['split'](':')[0x2];for(const _0x414f3b of _0x6cac5e['getWalker']({'singleCharacters':!0x0})){const _0x19698b=this['_getVidAttributeName'](_0x414f3b),_0x120e8d='elementEnd'==_0x414f3b['type']?_0x414f3b['previousPosition']['path']['slice'](0x0,-0x1):_0x414f3b['previousPosition']['path'],_0x7a7226=_0x49f07e['getNodeByPath'](_0x120e8d)['getAttribute'](_0x19698b);this['_touched']['set'](_0x7a7226,{'userId':_0x2c0397});}}}this['_startingRevisionId']=this['_revisionId'];const _0x23ca52=[...Array(this['_revisionId'])['keys']()]['slice'](0x1)['filter'](_0x504306=>!this['_touched']['has'](_0x504306));let _0x82135=0x0;const _0x5575b5=new Map();for(const _0x28d549 in _0x29edd2['diffData']){const _0x3f5f94=_0x29edd2['diffData'][_0x28d549]['attachChange'],_0x1a40f7=_0x13ac74(_0x29edd2['diffData'][_0x28d549]['attributesAfter'])||{},_0xda4826=_0x388249['_makeModelFromViewString'](_0x29edd2['diffData'][_0x28d549]['insertions']);_0xda4826['rootName']=_0x28d549,_0xda4826['_isAttached']=!_0x3f5f94||_0x3f5f94['isAttached'],_0xda4826['isAttached']=()=>_0xda4826['_isAttached'],this['_diffRoots']['set'](_0x28d549,_0xda4826),this['_diffRootsAttributes']['set'](_0x28d549,_0x1a40f7);const _0x2f2fac=this['_makeIdsRoot'](_0xda4826,Number['NEGATIVE_INFINITY']);this['_idsRoots']['set'](_0x28d549,_0x2f2fac),_0x5575b5['set'](_0x28d549,_0xda4826['isAttached']()?_0x1a40f7:{});for(const [_0x2b69f4,_0x4fd523]of _0xda4826['markers']){if(!_0x2b69f4['startsWith']('revision:'))continue;const _0xb94535=_0x2b69f4['split'](':')[0x2];for(const _0x9ad04b of _0x4fd523['getWalker']({'singleCharacters':!0x0})){const _0x26a5aa=this['_getVidAttributeName'](_0x9ad04b),_0x3d1159=this['_revisionId']++,_0x21894e='elementEnd'==_0x9ad04b['type']?_0x9ad04b['previousPosition']['path']['slice'](0x0,-0x1):_0x9ad04b['previousPosition']['path'];_0x2f2fac['getNodeByPath'](_0x21894e)['_setAttribute'](_0x26a5aa,_0x3d1159),this['_touched']['set'](_0x3d1159,{'userId':_0xb94535});}}for(const _0x5d89ad of this['editor']['model']['createRangeIn'](_0xda4826)['getWalker']({'singleCharacters':!0x0})){const _0xe8b5d9=this['_getVidAttributeName'](_0x5d89ad),_0x241b9b='elementEnd'==_0x5d89ad['type']?_0x5d89ad['previousPosition']['path']['slice'](0x0,-0x1):_0x5d89ad['previousPosition']['path'],_0x4a4d23=_0x2f2fac['getNodeByPath'](_0x241b9b);_0x4a4d23['getAttribute'](_0xe8b5d9)>0x0||_0x4a4d23['_setAttribute'](_0xe8b5d9,_0x23ca52[_0x82135++]);}for(const [_0x298377,_0x406765]of _0xda4826['markers'])_0x298377['startsWith']('revision:')||this['_markers']['set'](_0x298377,_0x406765);}const {roots:_0x5b8d0a}=this['_savedMetaData']['get'](_0x29edd2['fromVersion']),{roots:_0x4c68fa}=this['_savedMetaData']['get'](_0x29edd2['toVersion']),_0x316c2d=x(_0x5b8d0a['get']('$graveyard'));this['_baseRoots']['set']('$graveyard',_0x316c2d),this['_baseIdsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x316c2d,Number['NEGATIVE_INFINITY']));const _0x418e99=x(_0x4c68fa['get']('$graveyard'));this['_diffRoots']['set']('$graveyard',_0x418e99),this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x418e99));const _0x50ff46=Array['from'](this['_diffRoots'])['map'](([_0x579372,_0x2d9485])=>[_0x579372,x(_0x2d9485)]);this['_saveMetaData'](this['_lastTo'],_0x50ff46,this['_markers'],_0x5575b5);}['reInit'](){this['_reset'](),this['_lastFrom']=-0x1,this['_lastTo']=-0x1,this['_savedMetaData']['clear'](),this['init'](this['source']);}['_saveMetaData'](_0xb8c5f7,_0x3ffb5c,_0x49d4a1,_0x1f5ee1){const _0x42107a=new Map(_0x3ffb5c),_0x4d6c21=new Map(_0x13ac74(_0x1f5ee1)),_0x366f3d=new Map();for(const [_0x18c340,_0x33312e]of _0x49d4a1)_0x366f3d['set'](_0x18c340,{'start':_0x33312e['start']['clone'](),'end':_0x33312e['end']['clone'](),'rootName':_0x33312e['root']['rootName']});this['_savedMetaData']['set'](_0xb8c5f7,{'roots':_0x42107a,'markers':_0x366f3d,'rootsAttributes':_0x4d6c21});}['_removeMetaData'](_0x4cf8ca){this['_savedMetaData']['delete'](_0x4cf8ca);}['_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'](_0x3ec91a,_0x40d407=null){let _0x449aff=null;_0x3ec91a['is']('documentFragment')||(_0x449aff=new _0x306706(_0x3ec91a['name'],{'vid_start':null===_0x40d407?this['_revisionId']++:_0x40d407++}));const _0x3a59e2=[];for(const _0x3d546b of _0x3ec91a['getChildren']())if(_0x3d546b['is']('element')){_0x3a59e2['push'](this['_makeIdsRoot'](_0x3d546b,_0x40d407));const _0x2da1de=_0x3a59e2[_0x3a59e2['length']-0x1];null!==_0x40d407&&(_0x40d407=_0x2da1de['is']('element','$text')?_0x2da1de['getAttribute']('vid')+0x1:_0x2da1de['getAttribute']('vid_end')+0x1);}else{for(let _0x412c76=0x0;_0x412c76<_0x3d546b['offsetSize'];_0x412c76++)_0x3a59e2['push'](new _0x306706('$text',{'vid':null===_0x40d407?this['_revisionId']++:_0x40d407++}));}if(_0x3ec91a['is']('documentFragment')){const _0x121a92=N(_0x3ec91a['rootName']);return _0x121a92['_insertChild'](0x0,_0x3a59e2),_0x121a92;}return _0x449aff['_setAttribute']('vid_end',null===_0x40d407?this['_revisionId']++:_0x40d407++),_0x449aff['_insertChild'](0x0,_0x3a59e2),_0x449aff;}['_calculateMetaData'](_0x510d51,_0x1e8638,_0x2121e1){this['_reset']();const {roots:_0x338c3d,markers:_0x34cacf,rootsAttributes:_0x45224a}=this['_savedMetaData']['get'](_0x510d51);this['_baseRoots']=new Map(_0x338c3d),this['_baseRootsAttributes']=new Map(_0x13ac74(_0x45224a));for(const [_0x10238c,_0x122319]of this['_baseRoots'])if('$graveyard'!==_0x10238c&&(this['_diffRoots']['set'](_0x10238c,x(_0x122319)),this['_diffRootsAttributes']=new Map(_0x13ac74(_0x45224a)),_0x2121e1)){const _0x4ee16c=this['_revisionId'];this['_idsRoots']['set'](_0x10238c,this['_makeIdsRoot'](_0x122319)),this['_baseIdsRoots']['set'](_0x10238c,this['_makeIdsRoot'](_0x122319,_0x4ee16c));}this['_startingRevisionId']=this['_revisionId'],this['_diffRoots']['set']('$graveyard',x(this['_baseRoots']['get']('$graveyard'))),_0x2121e1&&this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](this['_baseRoots']['get']('$graveyard')));for(const [_0x51678d,_0x5a83ee]of _0x34cacf){const _0x1cdcf1=this['_baseRoots']['get'](_0x5a83ee['rootName']),_0x61ddf0=this['_diffRoots']['get'](_0x5a83ee['rootName']),_0x2fe113=new _0x11fd17(this['_fixPosition'](_0x5a83ee['start'],_0x1cdcf1),this['_fixPosition'](_0x5a83ee['end'],_0x1cdcf1)),_0x4ee0fd=this['_fixRange'](_0x2fe113,_0x61ddf0);_0x1cdcf1['markers']['set'](_0x51678d,_0x2fe113),this['_markers']['set'](_0x51678d,_0x4ee0fd);}this['_applyOperations'](_0x510d51,_0x1e8638,_0x2121e1);}['_applyOperations'](_0x5c3d10,_0x4cfca4,_0x3f1210){for(const _0x352deb of this['source']['getOperations'](_0x5c3d10,_0x4cfca4))this['_handleOperation'](_0x352deb,_0x3f1210);for(const _0x2b1909 of this['_diffRoots']['values']())_0x2b1909['markers']['clear']();for(const [_0x15180b,_0xc3847e]of this['_markers']){this['_diffRoots']['get'](_0xc3847e['root']['rootName'])['markers']['set'](_0x15180b,_0xc3847e['clone']());}const _0x4b185b=new Map(),_0x23ae81=new Map();for(const [_0xfdc22,_0x5d9b34]of this['_diffRoots'])_0x4b185b['set'](_0xfdc22,x(_0x5d9b34)),_0x23ae81['set'](_0xfdc22,this['_diffRootsAttributes']['get'](_0xfdc22));this['_saveMetaData'](_0x4cfca4,_0x4b185b,this['_markers'],_0x23ae81);}['_getPreviousFrom'](_0x4f31b7){const _0x44b3ea=Array['from'](this['_savedMetaData']['keys']());_0x44b3ea['sort']((_0x55c5ee,_0x57ab69)=>_0x55c5ee-_0x57ab69),_0x44b3ea['reverse']();for(const _0x22fe69 of _0x44b3ea)if(_0x22fe69<_0x4f31b7)return _0x22fe69;return Number['NEGATIVE_INFINITY'];}['_copyMarkers'](_0x59d38d,_0x334d53){const _0x2707d6=Array['from'](_0x334d53['markers'])['map'](([_0x46cad6,_0x5316bb])=>[_0x46cad6,this['_fixRange'](_0x5316bb,_0x59d38d)]);_0x59d38d['markers']=new Map(_0x2707d6);}['_transformMarkers'](_0x5b8bca){for(const _0x699882 of this['_markers']['values']()){const _0xee9869=_0x699882['getTransformedByOperation'](_0x5b8bca),_0x40cd13=_0x11fd17['_createFromRanges'](_0xee9869);_0x699882['start']=_0x40cd13['start'],_0x699882['end']=_0x40cd13['end'];}}['_handleOperation'](_0x54dcca,_0x5c18ef){if('addRoot'!=_0x54dcca['type']&&'detachRoot'!=_0x54dcca['type']){if('insert'==_0x54dcca['type']){const _0x485a39=_0x54dcca['position']['root']['rootName'];this['_diffRoots']['has'](_0x485a39)||(this['_diffRoots']['set'](_0x485a39,N(_0x485a39,!0x0)),this['_diffRootsAttributes']['set'](_0x485a39,{}),_0x5c18ef&&this['_idsRoots']['set'](_0x485a39,N(_0x485a39,!0x0)));}else{if('addRootAttribute'==_0x54dcca['type']||'removeRootAttribute'==_0x54dcca['type']||'changeRootAttribute'==_0x54dcca['type'])return void this['_handleRootAttributeOperation'](_0x54dcca);'marker'==_0x54dcca['type']&&this['_handleMarkerOperation'](_0x54dcca);}if('marker'!==_0x54dcca['type']){const _0x34ab68=this['_cloneOperation'](_0x54dcca,this['_diffRoots']);_0x34ab68['_execute'](),this['_transformMarkers'](_0x34ab68);}if(_0x5c18ef)switch(_0x54dcca['type']){case'insert':this['_handleInsertOperation'](_0x54dcca);break;case'move':case'remove':case'reinsert':this['_handleMoveOperation'](_0x54dcca);break;case'merge':this['_handleMergeOperation'](_0x54dcca);break;case'split':this['_handleSplitOperation'](_0x54dcca);}}else this['_handleRootOperation'](_0x54dcca,_0x5c18ef);}['_cloneOperation'](_0xca2660,_0x5db205){const _0x6a3366=_0xca2660['clone']();return _0x6a3366['_authorId']=_0xca2660['_authorId'],this['_fixOperation'](_0x6a3366,_0x5db205),_0x6a3366;}['_getBaseVids'](_0x3213f6){return _0x3213f6['map'](_0x382aae=>{const _0x6a38ee=this['_getVidAttributeName'](_0x382aae);return Number(_0x382aae['item']['getAttribute'](_0x6a38ee));});}['_generateTape'](_0x2101c4,_0x576a08){if(_0x2101c4['is']('element','$text'))_0x576a08['push']({'item':_0x2101c4,'type':'text'});else{_0x2101c4['is']('element')&&_0x576a08['push']({'item':_0x2101c4,'type':'elementStart'});for(const _0x457d1a of _0x2101c4['getChildren']())this['_generateTape'](_0x457d1a,_0x576a08);_0x2101c4['is']('element')&&_0x576a08['push']({'item':_0x2101c4,'type':'elementEnd'});}return _0x576a08;}['_getState'](){const _0x28f707=new Map(this['_touched']),_0x3a5cc2=new Map(_0x28f707),_0x429799=new Map(),_0xe684c8={'insertions':{},'deletions':{}},_0x2df34f={'insertions':{},'deletions':{}},_0x3fb552=new Map(),_0x1e736a=new Set([...this['_baseRoots']['keys'](),...this['_diffRoots']['keys']()]);_0x1e736a['delete']('$graveyard');for(const _0x123a31 of _0x1e736a){const _0x27c0ff=this['_diffRoots']['get'](_0x123a31)||N(_0x123a31,!0x1),_0x319a70=this['_baseRoots']['get'](_0x123a31)||N(_0x123a31,!0x1);_0x27c0ff['isAttached']()||_0x319a70['isAttached']()?(_0xe684c8['insertions'][_0x123a31]=x(_0x27c0ff),_0xe684c8['deletions'][_0x123a31]=x(_0x319a70),this['_copyMarkers'](_0xe684c8['deletions'][_0x123a31],_0x319a70),this['_copyMarkers'](_0xe684c8['insertions'][_0x123a31],_0x27c0ff),_0x2df34f['insertions'][_0x123a31]=this['_generateTape'](this['_idsRoots']['get'](_0x123a31),[]),_0x2df34f['deletions'][_0x123a31]=this['_generateTape'](this['_baseIdsRoots']['get'](_0x123a31)||N(_0x123a31,!0x1),[])):_0x1e736a['delete'](_0x123a31);}for(const _0x5c8a01 of _0x1e736a){const _0x2dd032=_0x2df34f['insertions'][_0x5c8a01];for(const _0x5484f6 of _0x2dd032){const _0x37f61e=this['_getVidAttributeName'](_0x5484f6),_0xa42235=_0x5484f6['item']['getAttribute'](_0x37f61e);_0x3a5cc2['delete'](_0xa42235),_0xa42235>=this['_startingRevisionId']&&_0x429799['set'](_0xa42235,_0x28f707['get'](_0xa42235));}}for(const _0x3c0a4d of _0x1e736a){const _0x4ca3a6=_0x2df34f['insertions'][_0x3c0a4d],_0x919832=this['_getBaseVids'](_0x2df34f['deletions'][_0x3c0a4d]);let _0x48c171=0x0;for(const _0x7d54d6 of _0x4ca3a6){const _0x18f54b=this['_getVidAttributeName'](_0x7d54d6),_0x1d63fa=_0x7d54d6['item']['getAttribute'](_0x18f54b);if(!_0x429799['has'](_0x1d63fa)&&!_0x3fb552['has'](_0x1d63fa)){if(_0x3a5cc2['has'](_0x1d63fa))_0x48c171++;else{if(_0x1d63fa!=_0x919832[_0x48c171]){const _0x47958e=_0x28f707['get'](_0x1d63fa)||_0x28f707['get'](_0x919832[_0x48c171]);for(;_0x1d63fa!=_0x919832[_0x48c171];)_0x3a5cc2['has'](_0x919832[_0x48c171])||(_0x3fb552['set'](_0x919832[_0x48c171],_0x47958e),_0x28f707['set'](_0x919832[_0x48c171],_0x47958e)),_0x48c171++;}_0x48c171++;}}}}for(const _0x597ea2 of _0x1e736a){const _0x4b9015=_0x2df34f['insertions'][_0x597ea2];for(const _0x12a574 of _0x4b9015){const _0x1723f1=this['_getVidAttributeName'](_0x12a574),_0x2f2d60=_0x12a574['item']['getAttribute'](_0x1723f1);if(_0x3fb552['has'](_0x2f2d60)){const _0x20817e=_0x3fb552['get'](_0x2f2d60);_0x3a5cc2['has'](_0x2f2d60)||_0x3a5cc2['set'](_0x2f2d60,{..._0x20817e}),_0x429799['set'](_0x2f2d60,{..._0x20817e});}}}for(const _0x18ab46 of _0x3a5cc2['keys']())_0x18ab46>=this['_startingRevisionId']&&_0x3a5cc2['delete'](_0x18ab46);const _0x3cafaf=new Map();for(const _0x2fca41 of _0x1e736a){let _0x5b8db4=_0x2df34f['insertions'][_0x2fca41];for(const _0x2579ce of _0x5b8db4)if(_0x2579ce['item']['is']('element','tableCell')){const _0x3577d2=this['_getVidAttributeName'](_0x2579ce),_0x30eef6=_0x2579ce['item']['getAttribute'](_0x3577d2);if(_0x429799['has'](_0x30eef6)){const _0x1c47ea=_0x2579ce['item']['parent']['parent']['getAttribute']('vid_start'),_0x443dc9=_0x3cafaf['get'](_0x1c47ea)||new Set();_0x443dc9['add'](_0x429799['get'](_0x30eef6)['userId']),_0x3cafaf['set'](_0x1c47ea,_0x443dc9);}}_0x5b8db4=_0x2df34f['deletions'][_0x2fca41];for(const _0x4bb073 of _0x5b8db4)if(_0x4bb073['item']['is']('element','tableCell')){const _0x58507d=this['_getVidAttributeName'](_0x4bb073),_0x513a40=_0x4bb073['item']['getAttribute'](_0x58507d);if(_0x3a5cc2['has'](_0x513a40)){const _0x23b712=_0x4bb073['item']['parent']['parent']['getAttribute']('vid_start'),_0x54a2c2=_0x3cafaf['get'](_0x23b712)||new Set();_0x54a2c2['add'](_0x3a5cc2['get'](_0x513a40)['userId']),_0x3cafaf['set'](_0x23b712,_0x54a2c2);}}for(const _0x1a4fe1 of _0x3cafaf['keys']())(_0x429799['has'](_0x1a4fe1)||_0x3a5cc2['has'](_0x1a4fe1))&&_0x3cafaf['delete'](_0x1a4fe1);}for(const _0x2398db of _0x1e736a){const _0x513a06=_0x2df34f['insertions'][_0x2398db];let _0x264b36=null,_0x54c7df=null;for(const _0x4fab99 of _0x513a06){const _0x56bc2e=this['_getVidAttributeName'](_0x4fab99),_0x33497a=_0x4fab99['item']['getAttribute'](_0x56bc2e),_0x1b396d=_0x3cafaf['get'](_0x33497a);_0x1b396d&&'elementStart'==_0x4fab99['type']&&(_0x264b36=Array['from'](_0x1b396d)[0x0],_0x54c7df=_0x4fab99['item']['getAttribute']('vid_end')),_0x264b36&&(_0x3a5cc2['set'](_0x33497a,{'userId':_0x264b36}),_0x429799['set'](_0x33497a,{'userId':_0x264b36})),_0x33497a==_0x54c7df&&(_0x264b36=null,_0x54c7df=null);}}const _0x18f34d={},_0xcf7fff=new Set();for(const _0x42fbe5 of _0x1e736a){const _0x48748d=_0xe684c8['deletions'][_0x42fbe5],_0x25d28f=_0xe684c8['insertions'][_0x42fbe5];for(const {userId:_0x583ab1}of this['_touchedMarkers']['values']())null!==_0x583ab1&&_0xcf7fff['add'](_0x583ab1);for(const {userId:_0x47a7cf}of this['_touchedRoots']['values']())null!==_0x47a7cf&&_0xcf7fff['add'](_0x47a7cf);this['_markChanges'](_0x25d28f,_0x2df34f['insertions'][_0x42fbe5],_0x429799,'insertion',_0xcf7fff),this['_markChanges'](_0x48748d,_0x2df34f['deletions'][_0x42fbe5],_0x3a5cc2,'deletion',_0xcf7fff),_0x18f34d[_0x42fbe5]={'insertions':this['_prepareViewToSave'](_0x25d28f),'deletions':this['_prepareViewToSave'](_0x48748d),'attachChange':this['_touchedRoots']['get'](_0x42fbe5)||null,'attributesBefore':_0x13ac74(this['_baseRootsAttributes']['get'](_0x42fbe5))||{},'attributesAfter':_0x13ac74(this['_diffRootsAttributes']['get'](_0x42fbe5))};}return{'diffData':_0x18f34d,'authorsIds':Array['from'](_0xcf7fff)};}['_processRootBeforeSave'](_0x404c5f){for(const [,_0x419d4d]of _0x404c5f['markers']){const _0x3156e5=_0x419d4d['start']['getAncestors']()['filter'](_0x492c94=>'tableCell'==_0x492c94['name']);for(const _0x594733 of _0x3156e5)0x1==_0x594733['childCount']&&_0x594733['getChild'](0x0)['is']('element','paragraph')&&_0x594733['getChild'](0x0)['_setAttribute']('keepParagraph',!0x0);}}['_prepareViewToSave'](_0x13fac9){this['_processRootBeforeSave'](_0x13fac9);const _0x4a5cc5=this['editor']['data']['toView'](_0x13fac9,{}),_0x125933=Array['from'](_0x4a5cc5['getChildren']())['map'](_0x405a9d=>this['_getViewJson'](_0x405a9d));return JSON['stringify'](_0x125933);}['_getViewJson'](_0x4dfc45){if(_0x4dfc45['is']('$text'))return _0x4dfc45['data'];{const _0x54eff5=this['editor']['plugins']['get']('RevisionHistoryUtils'),_0x3f66f5=_0x4dfc45,_0x33ff59=this['editor']['data']['htmlProcessor']['domConverter'],_0x59f90f={'type':_0x54eff5['_getTypeCharForViewElement'](_0x3f66f5),'name':_0x3f66f5['name'],'attributes':Array['from'](_0x3f66f5['getAttributes']()),'children':Array['from'](_0x3f66f5['getChildren']())['map'](_0x1e8afa=>this['_getViewJson'](_0x1e8afa))};if(_0x4dfc45['is']('uiElement')&&'$comment'!=_0x4dfc45['name']){const _0x398430=_0x4dfc45['render'](_0x33ff59['domDocument'],_0x33ff59);_0x59f90f['children']['push'](_0x398430['outerHTML']);}else{if(_0x4dfc45['is']('rawElement')){const _0x561654=_0x33ff59['domDocument']['createElement'](_0x3f66f5['name']);_0x4dfc45['render'](_0x561654,_0x33ff59),_0x59f90f['children']['push'](_0x561654['innerHTML']);}}const _0x496cf7=Array['from'](_0x3f66f5['getCustomProperties']());_0x496cf7['length']>0x0&&(_0x59f90f['customProperties']=_0x496cf7);const _0x5d06af=_0x3f66f5['getFillerOffset']();return null!==_0x5d06af&&(_0x59f90f['fillerOffset']=_0x5d06af),_0x59f90f;}}['_markChanges'](_0x3baa23,_0x16c275,_0x2c47c6,_0xd20306,_0x13c3dc){let _0x8511ff=null,_0x247618=null,_0x539c0a=0x0;const _0xb974e7=this['editor']['model'];for(let _0x172468=0x0;_0x172468<_0x16c275['length'];_0x172468++){const _0x122a0e=this['_getVidAttributeName'](_0x16c275[_0x172468]),_0x4a997f=_0x16c275[_0x172468]['item']['getAttribute'](_0x122a0e),_0x2a7982=_0x2c47c6['get'](_0x4a997f),_0x9b6cca=_0x172468==_0x16c275['length']-0x1;(!_0x8511ff&&_0x2a7982&&(_0x8511ff=_0x2a7982,_0x247618=_0x16c275[_0x172468]),_0x8511ff&&(!_0x2a7982||_0x2a7982['userId']!=_0x8511ff['userId']))&&(_0x2d0231(_0x2a7982,P(_0x247618,_0x3baa23,_0xb974e7),P(_0x16c275[_0x172468],_0x3baa23,_0xb974e7)),_0x8511ff=_0x2a7982||null,_0x247618=_0x2a7982?_0x16c275[_0x172468]:null),_0x8511ff&&_0x9b6cca&&_0x2d0231(_0x2a7982,P(_0x247618,_0x3baa23,_0xb974e7),V(_0x16c275[_0x172468],_0x3baa23,_0xb974e7));}function _0x2d0231(_0x577ad8,_0x2a9a74,_0x14de04){const _0x878ef2=_0x8511ff['userId'],_0x316f6e='revision:'+_0xd20306+':'+_0x878ef2+':'+_0x539c0a++,_0x5476de=_0xb974e7['createRange'](_0x2a9a74,_0x14de04);_0x3baa23['markers']['set'](_0x316f6e,_0x5476de),null!==_0x878ef2&&_0x13c3dc['add'](_0x878ef2);}}['_getVidAttributeName'](_0x50d71a){switch(_0x50d71a['type']){case'elementStart':return'vid_start';case'elementEnd':return'vid_end';default:return'vid';}}['_fixOperation'](_0x1f660d,_0x5d5fef){_0x1f660d['baseVersion']=null;for(const _0x358759 in _0x1f660d){const _0x552931=_0x1f660d[_0x358759];if(_0x552931 instanceof _0x23879f){const _0x235748=_0x5d5fef['get'](_0x552931['root']['rootName']);_0x1f660d[_0x358759]=this['_fixPosition'](_0x552931,_0x235748);}if(_0x552931 instanceof _0x11fd17){const _0x36c8b2=_0x5d5fef['get'](_0x552931['root']['rootName']);_0x1f660d[_0x358759]=this['_fixRange'](_0x552931,_0x36c8b2);}'root'===_0x358759&&(_0x1f660d['root']=_0x5d5fef['get'](_0x1f660d['root']['rootName']));}}['_fixRange'](_0x200f9a,_0x2eea6c){return this['editor']['model']['createRange'](this['_fixPosition'](_0x200f9a['start'],_0x2eea6c),this['_fixPosition'](_0x200f9a['end'],_0x2eea6c));}['_fixPosition'](_0x39afb3,_0x739561){return this['editor']['model']['createPositionFromPath'](_0x739561,_0x39afb3['path'],_0x39afb3['stickiness']);}['_handleInsertOperation'](_0x30b6a5){const _0xe0ae8e=this['_idsRoots']['get'](_0x30b6a5['position']['root']['rootName']),_0x3b8b90=this['_fixPosition'](_0x30b6a5['position'],_0xe0ae8e),_0x1684ee=null===_0x30b6a5['_authorId']?null:_0x30b6a5['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x316137=_0x3b8b90['parent'],_0x309000=this['_revisionId'],_0x18bb9e=[];for(const _0x226a91 of _0x30b6a5['nodes'])if(_0x226a91['is']('element'))_0x18bb9e['push'](this['_makeIdsRoot'](_0x226a91));else{for(let _0x54c81f=0x0;_0x54c81f<_0x226a91['offsetSize'];_0x54c81f++)_0x18bb9e['push'](new _0x306706('$text',{'vid':this['_revisionId']++}));}const _0x1755cd=this['_revisionId'];for(let _0x35f1fe=_0x309000;_0x35f1fe<_0x1755cd;_0x35f1fe++)this['_touched']['set'](_0x35f1fe,{'userId':_0x1684ee});_0x316137['_insertChild'](_0x3b8b90['offset'],_0x18bb9e);}['_handleMoveOperation'](_0x515f8c){(_0x515f8c=this['_cloneOperation'](_0x515f8c,this['_idsRoots']))['_execute']();const _0x49a49e=null===_0x515f8c['_authorId']?null:_0x515f8c['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x45b914=_0x515f8c['getMovedRangeStart'](),_0x16b849=_0x45b914['parent'],_0x27e2e3=_0x45b914['offset'];!function _0x33c48d(_0x59eaae,_0x34c7e9,_0x4e95cb,_0x7456e1){for(let _0x336343=_0x4e95cb;_0x336343<_0x7456e1;_0x336343++){const _0x13bee9=_0x34c7e9['getChild'](_0x336343);_0x13bee9['is']('element','$text')?_0x59eaae['set'](_0x13bee9['getAttribute']('vid'),{'userId':_0x49a49e}):(_0x59eaae['set'](_0x13bee9['getAttribute']('vid_start'),{'userId':_0x49a49e}),_0x33c48d(_0x59eaae,_0x13bee9,0x0,_0x13bee9['childCount']),_0x59eaae['set'](_0x13bee9['getAttribute']('vid_end'),{'userId':_0x49a49e}));}}(this['_touched'],_0x16b849,_0x27e2e3,_0x27e2e3+_0x515f8c['howMany']);}['_handleMergeOperation'](_0x328380){const _0x1b4266=null===(_0x328380=this['_cloneOperation'](_0x328380,this['_idsRoots']))['_authorId']?null:_0x328380['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x34a0eb=_0x328380['targetPosition']['parent'],_0x482ad5=_0x328380['sourcePosition']['parent'],_0x3c85b0=_0x34a0eb['getAttribute']('vid_end'),_0x5c8540=_0x482ad5['getAttribute']('vid_start');_0x34a0eb['_setAttribute']('vid_end',_0x482ad5['getAttribute']('vid_end')),_0x482ad5['_setAttribute']('vid_end',_0x3c85b0),this['_touched']['set'](_0x5c8540,{'userId':_0x1b4266}),this['_touched']['set'](_0x3c85b0,{'userId':_0x1b4266}),_0x328380['_execute']();}['_handleSplitOperation'](_0x359f5d){const _0x56de65=null===(_0x359f5d=this['_cloneOperation'](_0x359f5d,this['_idsRoots']))['_authorId']?null:_0x359f5d['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x225eeb=_0x359f5d['graveyardPosition'],_0x34301f=_0x359f5d['splitPosition']['parent'];_0x359f5d['_execute']();const _0x599e8a=_0x34301f['getAttribute']('vid_end'),_0x50b238=_0x359f5d['insertionPosition']['nodeAfter'];if(_0x225eeb){const _0x2d6495=_0x50b238['getAttribute']('vid_end'),_0x1ed08e=_0x34301f['getAttribute']('vid_end');_0x34301f['_setAttribute']('vid_end',_0x2d6495),_0x50b238['_setAttribute']('vid_end',_0x1ed08e),this['_touched']['set'](_0x34301f['getAttribute']('vid_end'),{'userId':_0x56de65}),this['_touched']['set'](_0x50b238['getAttribute']('vid_start'),{'userId':_0x56de65});}else{const _0x31448a=this['_revisionId']++,_0xb00d9=this['_revisionId']++;_0x34301f['_setAttribute']('vid_end',_0x31448a),_0x50b238['_setAttribute']('vid_start',_0xb00d9),_0x50b238['_setAttribute']('vid_end',_0x599e8a),this['_touched']['set'](_0x31448a,{'userId':_0x56de65}),this['_touched']['set'](_0xb00d9,{'userId':_0x56de65});}}['_handleMarkerOperation'](_0x52e6e1){if(!_0x52e6e1['affectsData'])return;const _0x2abec4=(_0x52e6e1=this['_cloneOperation'](_0x52e6e1,this['_diffRoots']))['oldRange']?_0x52e6e1['oldRange']['root']:null,_0x1402bf=_0x52e6e1['newRange']?_0x52e6e1['newRange']['root']:null;_0x2abec4&&this['_markers']['delete'](_0x52e6e1['name']),_0x1402bf&&this['_markers']['set'](_0x52e6e1['name'],_0x52e6e1['newRange']['clone']());const _0x4a573a=null===_0x52e6e1['_authorId']?null:_0x52e6e1['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x13cf2a=_0x52e6e1['name'];if(!this['_touchedMarkers']['has'](_0x13cf2a))return void this['_touchedMarkers']['set'](_0x13cf2a,{'range':_0x52e6e1['oldRange'],'userId':_0x4a573a});const _0x3cef04=this['_touchedMarkers']['get'](_0x13cf2a),_0x23b280=_0x3cef04['range'],_0x496b42=_0x52e6e1['newRange'];null==_0x23b280&&null==_0x496b42||_0x23b280&&_0x496b42&&_0x23b280['isEqual'](_0x496b42)?this['_touchedMarkers']['delete'](_0x52e6e1['name']):_0x3cef04['userId']=_0x4a573a;}['_handleRootOperation'](_0x40e158,_0x48212f){this['_diffRoots']['has'](_0x40e158['rootName'])?this['_diffRoots']['get'](_0x40e158['rootName'])['_isAttached']=_0x40e158['isAdd']:(this['_diffRoots']['set'](_0x40e158['rootName'],N(_0x40e158['rootName'],!0x0)),this['_diffRootsAttributes']['set'](_0x40e158['rootName'],{}),_0x48212f&&this['_idsRoots']['set'](_0x40e158['rootName'],N(_0x40e158['rootName'],!0x0)));const _0x253ff1=null===_0x40e158['_authorId']?null:_0x40e158['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x1fcbd9=this['_touchedRoots']['get'](_0x40e158['rootName']);_0x1fcbd9&&_0x1fcbd9['userId']===_0x253ff1?this['_touchedRoots']['delete'](_0x40e158['rootName']):this['_touchedRoots']['set'](_0x40e158['rootName'],{'userId':_0x253ff1,'isAttached':_0x40e158['isAdd']});}['_handleRootAttributeOperation'](_0x51f4b4){const _0x1c1129=this['_diffRootsAttributes']['get'](_0x51f4b4['root']['rootName']);null===_0x51f4b4['newValue']?delete _0x1c1129[_0x51f4b4['key']]:_0x1c1129[_0x51f4b4['key']]=_0x51f4b4['newValue'];}}function x(_0x4a0310){const _0x4dfd9a=N(_0x4a0310['rootName'],_0x4a0310['isAttached']());for(const _0x4d9626 of _0x4a0310['getChildren']()){const _0xd0552c=_0x4d9626['_clone'](!0x0);_0x4dfd9a['_appendChild'](_0xd0552c);}return _0x4dfd9a;}function N(_0x3d5d6e,_0x401848=!0x0){const _0x44cf98=new _0x34988e();return _0x44cf98['rootName']=_0x3d5d6e,_0x44cf98['_isAttached']=_0x401848,_0x44cf98['isAttached']=()=>_0x44cf98['_isAttached'],_0x44cf98;}function P(_0x49e97f,_0x5910d3,_0x4d5fb7){const _0x4781bb='elementEnd'==_0x49e97f['type']?_0x4d5fb7['createPositionAt'](_0x49e97f['item'],'end'):_0x4d5fb7['createPositionBefore'](_0x49e97f['item']);return _0x4d5fb7['createPositionFromPath'](_0x5910d3,_0x4781bb['path'],_0x4781bb['stickiness']);}function V(_0x48ba61,_0x56066e,_0x39c7b6){const _0x3db979='elementStart'==_0x48ba61['type']?_0x39c7b6['createPositionAt'](_0x48ba61['item'],0x0):_0x39c7b6['createPositionAfter'](_0x48ba61['item']);return _0x39c7b6['createPositionFromPath'](_0x56066e,_0x3db979['path'],_0x3db979['stickiness']);}class he extends/* #__PURE__ -- @preserve */
|
|
25
|
-
|
|
26
|
-
_0x408429(){['id'];['author'];['type'];['data'];['rootName'];constructor(_0x47fb20){super(),this['id']=_0x47fb20['id']||_0x4df7d4(),this['author']=_0x47fb20['author'],this['type']=_0x47fb20['type'],this['data']=_0x47fb20['data']||{},this['rootName']=_0x47fb20['rootName'],this['set']('createdAt',_0x47fb20['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(_0x3b2eda,_0xa78211){this['newRevisionId']=_0x3b2eda,this['oldRevisionId']=_0xa78211,this['changes']=new _0x5b3f34();}['_setChanges'](_0x1b8263){for(const _0x5048ff of _0x1b8263)this['changes']['add'](_0x5048ff);}}class l extends _0x280bdd{['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[_0x1439ad,_0x17eb32,S,$];}constructor(_0x3fe912){super(_0x3fe912),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',(_0x240727,_0x560e5f,_0x253cec)=>{this['activeChange']=null,this['activeView']=null,this['editor']['editing']['view']['change'](_0x390851=>{for(const _0x36f7ae of this['editor']['editing']['view']['document']['roots'])_0x253cec?_0x390851['removeClass']('ck-editor__editable__overlay',_0x36f7ae):_0x390851['addClass']('ck-editor__editable__overlay',_0x36f7ae);});}),this['bind']('isNavigationMode')['to'](this,'activeChange',_0x4bb893=>null!==_0x4bb893),this['bind']('currentChangeNumber')['to'](this,'isReady',this,'diff',this,'activeChange',(_0x2ec756,_0x54354b,_0xa78950)=>_0x2ec756&&_0xa78950?_0x54354b['changes']['getIndex'](_0xa78950):0x0),this['bind']('numberOfChanges')['to'](this,'isReady',this,'diff',(_0x94ff04,_0x26bdb3)=>_0x94ff04?_0x26bdb3['changes']['length']:0x0),this['_changeView']=null,this['_changeIdToChange']=new Map(),this['_balloon']=this['editor']['plugins']['get'](_0x17eb32);}['init'](){const _0x61a54d=this['editor'],_0x1a6c54=new ot(_0x61a54d,{'direction':'backward'}),_0x384c61=new ot(_0x61a54d,{'direction':'forward'});(_0x61a54d['commands']['add']('showPreviousChange',_0x1a6c54),_0x61a54d['commands']['add']('showNextChange',_0x384c61),_0x61a54d['commands']['add']('restoreRevision',new nt(_0x61a54d)),this['on']('change:numberOfChanges',()=>{_0x1a6c54['refresh'](),_0x384c61['refresh']();}),this['_setConversion'](),this['_initInteractions'](),_0x61a54d['enableReadOnlyMode']('revision-viewer'),_0x61a54d['plugins']['has']('WidgetToolbarRepository'))&&_0x61a54d['plugins']['get']('WidgetToolbarRepository')['forceDisabled']('revision-viewer');}async['getRevisionDocumentData'](_0x3006e6){return await this['_utils']['loadRevisionData'](_0x3006e6,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x3006e6);}async['getRevisionRootsAttributes'](_0x5e3d01){return await this['_utils']['loadRevisionData'](_0x5e3d01,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x5e3d01);}async['compare'](_0x6f6cfe,_0x3069fc,_0x108129=!0x1){if(!this['isEnabled'])return;const _0x35ce29=this['diff'],_0x1fac21=this['repository'],_0x32e0b3='string'==typeof _0x6f6cfe?_0x1fac21['getRevision'](_0x6f6cfe):_0x6f6cfe,_0x47ca02='string'==typeof _0x3069fc?_0x1fac21['getRevision'](_0x3069fc):_0x3069fc,_0x4bcff9=_0x32e0b3['id'],_0x30d715=_0x47ca02?_0x47ca02['id']:null;if(!_0x108129&&this['diff']&&this['diff']['newRevisionId']===_0x4bcff9&&this['diff']['oldRevisionId']===_0x30d715)return Promise['resolve']();this['isReady']=!0x1,this['activeView']=null,this['activeChange']=null,this['diff']=new J(_0x4bcff9,_0x30d715);const _0x219d72=this['_getRevisionsRange'](_0x32e0b3,_0x47ca02,!0x0)['map'](_0x13b00a=>this['_utils']['loadRevisionData'](_0x13b00a,this['adapter']));return _0x219d72['push'](new Promise(_0x3e11dd=>{setTimeout(_0x3e11dd,0x14);})),Promise['all'](_0x219d72)['then'](()=>{if(!this['isEnabled'])return;this['_cleanUp']();const _0x271f3a=this['_getDiff'](_0x4bcff9,_0x30d715);for(const _0x1b7eaa of _0x271f3a['changes'])this['_changeIdToChange']['set'](_0x1b7eaa['id'],_0x1b7eaa);this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x1fbffb=>{for(const _0x4d70ea of this['editor']['model']['document']['getRootNames']())_0x1fbffb['detachRoot'](_0x4d70ea);for(const _0x590aea of Object['keys'](_0x271f3a['model'])){const _0x2fc608=_0x1fbffb['addRoot'](_0x590aea);for(const _0x2d445d of Object['keys'](_0x271f3a['attributes'][_0x590aea]))_0x1fbffb['setAttribute'](_0x2d445d,_0x271f3a['attributes'][_0x590aea][_0x2d445d],_0x2fc608);_0x1fbffb['insert'](_0x271f3a['model'][_0x590aea],_0x2fc608,0x0);}}),this['diff']['_setChanges'](this['_sortAndFilterDiffChanges'](_0x271f3a['changes'])),this['isReady']=!0x0;})['catch'](_0x514a6c=>{console['error'](_0x514a6c),this['_cleanUp'](),_0x35ce29&&(this['diff']=_0x35ce29),this['isReady']=!0x0;});}['addRevisionData'](_0xc5c318,_0x3cb1b8){const _0x9d9bb=this['repository']['createRevision'](_0xc5c318);return _0x9d9bb['on']('_update',(_0x13d289,_0x451054,_0x1163dc)=>_0x3cb1b8(_0x451054,_0x1163dc,_0x9d9bb)),this['repository']['addRevision'](_0x9d9bb),_0x9d9bb;}['_cleanUp'](){this['activeChange']=null,this['_cleanMarkers'](),this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=null,this['_changeIdToChange']['clear'](),this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x4b7d7d=>{for(const _0x4c0b04 of this['editor']['model']['document']['getRootNames']())_0x4b7d7d['detachRoot'](_0x4c0b04);});}['_sortAndFilterDiffChanges'](_0xcaa664){const _0x1b378f=[],_0x156428=new Map();for(const _0xb771e9 of this['editor']['model']['document']['getRootNames']()){const _0x24c94f=this['editor']['editing']['view']['getDomRoot'](_0xb771e9);if(!_0x24c94f)continue;const _0xc1dc8=_0x24c94f['getClientRects']()['item'](0x0);_0xc1dc8&&(_0x1b378f['push'](_0xb771e9),_0x156428['set'](_0xb771e9,_0xc1dc8));}return _0x1b378f['sort']((_0x3bd60d,_0x58a9c2)=>{const _0x3c3352=_0x156428['get'](_0x3bd60d),_0x1658d5=_0x156428['get'](_0x58a9c2);return _0x3c3352['y']-_0x1658d5['y']||_0x3c3352['x']-_0x1658d5['x'];}),(_0xcaa664=_0xcaa664['filter'](_0x5e0ec7=>_0x1b378f['includes'](_0x5e0ec7['rootName'])))['sort']((_0x4536f8,_0x4b6249)=>_0x1b378f['indexOf'](_0x4536f8['rootName'])-_0x1b378f['indexOf'](_0x4b6249['rootName'])),_0xcaa664;}['_makeTape'](_0x2d70a1){const _0x5ac6b3=Array['from'](_0x2d70a1['markers'])['filter'](([_0x53afc6,_0x4e36f9])=>_0x53afc6['startsWith']('revision:')&&!_0x4e36f9['isCollapsed']),_0x5a805e=Array['from'](this['editor']['model']['createRangeIn'](_0x2d70a1)['getWalker']({'singleCharacters':!0x0}));if(0x0!=_0x5ac6b3['length'])for(const _0x9d9573 of _0x5a805e){const [_0x5be4d8,_0x7ba465]=_0x5ac6b3[0x0],[,_0x3635fd,_0x3402b3]=_0x5be4d8['split'](':');if(_0x7ba465['end']['isEqual'](_0x9d9573['nextPosition'])&&_0x5ac6b3['shift'](),(_0x9d9573['previousPosition']['isEqual'](_0x7ba465['start'])||_0x9d9573['previousPosition']['isAfter'](_0x7ba465['start']))&&('insertion'==_0x3635fd?_0x9d9573['isAdded']={'userId':_0x3402b3}:'deletion'==_0x3635fd&&(_0x9d9573['isRemoved']={'userId':_0x3402b3})),0x0==_0x5ac6b3['length'])break;}return _0x5a805e;}['_refreshStartEndIndex'](_0x5079da){const _0x1c0a14=new Map();for(let _0x476f6c=0x0;_0x476f6c<_0x5079da['length'];_0x476f6c++)'text'===_0x5079da[_0x476f6c]['type']?(_0x5079da[_0x476f6c]['item']['startIndex']=_0x476f6c,_0x5079da[_0x476f6c]['item']['endIndex']=_0x476f6c):('elementStart'===_0x5079da[_0x476f6c]['type']?_0x5079da[_0x476f6c]['item']['startIndex']=_0x476f6c:'elementEnd'===_0x5079da[_0x476f6c]['type']&&(_0x5079da[_0x476f6c]['item']['endIndex']=_0x476f6c),_0x1c0a14['set'](_0x5079da[_0x476f6c]['id'],_0x476f6c));for(const _0x3f1cfc of _0x1c0a14['values']())'elementStart'===_0x5079da[_0x3f1cfc]['type']?_0x5079da[_0x3f1cfc]['item']['endIndex']=_0x1c0a14['get'](_0x5079da[_0x3f1cfc]['pairId']):'elementEnd'===_0x5079da[_0x3f1cfc]['type']&&(_0x5079da[_0x3f1cfc]['item']['startIndex']=_0x1c0a14['get'](_0x5079da[_0x3f1cfc]['pairId']));}['_processTape'](_0x3b8868){for(let _0x3d30e8=0x0;_0x3d30e8<_0x3b8868['length'];_0x3d30e8++){if('elementStart'===_0x3b8868[_0x3d30e8]['type'])_0x3b8868[_0x3d30e8]['item']['startIndex']=_0x3d30e8;else{if('elementEnd'===_0x3b8868[_0x3d30e8]['type']){_0x3b8868[_0x3d30e8]['item']['endIndex']=_0x3d30e8;const _0x4daf39=_0x3b8868[_0x3d30e8]['item']['startIndex'];_0x3b8868[_0x4daf39]['pairId']=_0x3b8868[_0x3d30e8]['id'],_0x3b8868[_0x3d30e8]['pairId']=_0x3b8868[_0x4daf39]['id'];}else _0x3b8868[_0x3d30e8]['item']['startIndex']=_0x3d30e8,_0x3b8868[_0x3d30e8]['item']['endIndex']=_0x3d30e8,_0x3b8868[_0x3d30e8]['pairId']=null;}_0x3b8868[_0x3d30e8]['markersStart']||(_0x3b8868[_0x3d30e8]['markersStart']=[],_0x3b8868[_0x3d30e8]['markersEnd']=[]);}}['_markInsertions'](_0x3f176f,_0x458109){const _0x5c508c=_0x3f176f['filter'](_0x3c828f=>!_0x3c828f['isAdded']);for(let _0x58d2e9=0x0;_0x58d2e9<_0x458109['length'];_0x58d2e9++)_0x458109[_0x58d2e9]['isAdded']&&(_0x5c508c[_0x58d2e9]['isAdded']=_0x458109[_0x58d2e9]['isAdded']);}['_getDiff'](_0x546317,_0x38f241=null){const _0x1027c1=this['repository']['getRevision'](_0x546317),_0x5cda03=_0x38f241?this['repository']['getRevision'](_0x38f241):null,_0x3b4e87=this['_getRevisionsRange'](_0x1027c1,_0x5cda03),_0x3207a0=_0x3b4e87[_0x3b4e87['length']-0x1],_0x126b47=new Map(),_0x2527a6={'model':{},'attributes':{},'changes':[]},_0x5abd5e=new Set(),_0x12bb54=new Map();for(let _0x22d865=_0x3b4e87['length']-0x1;_0x22d865>=0x0;_0x22d865--){const _0x3692da=_0x3b4e87[_0x22d865];for(const _0x538605 of Object['keys'](_0x3692da['diffData']))if(_0x3692da['diffData'][_0x538605]['attachChange']){const _0x111aeb=_0x3692da['diffData'][_0x538605]['attachChange'];_0x111aeb['isAttached']?(_0x5abd5e['add'](_0x538605),_0x12bb54['has'](_0x538605)&&_0x12bb54['get'](_0x538605)['userId']==_0x111aeb['userId']?_0x12bb54['delete'](_0x538605):_0x12bb54['set'](_0x538605,_0x111aeb)):_0x12bb54['has'](_0x538605)?(_0x5abd5e['delete'](_0x538605),_0x12bb54['delete'](_0x538605)):(_0x5abd5e['add'](_0x538605),_0x12bb54['set'](_0x538605,_0x111aeb));}else _0x5abd5e['add'](_0x538605);}for(const _0xe51188 of _0x5abd5e){const _0xe83e6=_0x12bb54['has'](_0xe51188)&&!_0x12bb54['get'](_0xe51188)['isAttached'];let _0x2dae50=_0xe83e6?_0x3b4e87['length']-0x1:0x0;const _0x80647b=_0xe83e6?-0x1:0x1;for(;_0x3b4e87[_0x2dae50];){const _0x2ec356=_0x3b4e87[_0x2dae50];if(_0x2ec356['diffData'][_0xe51188]){const _0x2ee19d=_0xe83e6?_0x2ec356['diffData'][_0xe51188]['attributesBefore']:_0x2ec356['diffData'][_0xe51188]['attributesAfter'];_0x2527a6['attributes'][_0xe51188]=_0x2ee19d?_0x13ac74(_0x2ee19d):{};break;}_0x2dae50+=_0x80647b;}}for(const _0x33d75a of _0x3b4e87){_0x33d75a['model']={};for(const _0x38fcc6 of _0x33d75a['authors'])_0x126b47['set'](_0x38fcc6['id'],_0x38fcc6);for(const _0x48dc62 of _0x5abd5e){const _0x3a8095=_0x33d75a['diffData'][_0x48dc62]?_0x33d75a['diffData'][_0x48dc62]['insertions']:'[]',_0x454b17=_0x33d75a['diffData'][_0x48dc62]?_0x33d75a['diffData'][_0x48dc62]['deletions']:'[]';_0x33d75a['model'][_0x48dc62]={'insertions':this['_utils']['_makeModelFromViewString'](_0x3a8095),'deletions':this['_utils']['_makeModelFromViewString'](_0x454b17)};}}for(const _0x4e365a of _0x5abd5e){let _0x3e36f8=null,_0xa4e446=0x0;const _0x18fa85=new Map(Array['from'](_0x1027c1['model'][_0x4e365a]['insertions']['markers'])['filter'](([_0x15cd6a])=>!_0x15cd6a['startsWith']('revision:')));let _0x2b86b1=0x0;for(const _0x18af21 of _0x3b4e87){const _0x499dec=this['_makeTape'](_0x18af21['model'][_0x4e365a]['insertions']);_0x18af21==_0x1027c1?(_0x3e36f8=_0x499dec,_0xa4e446=_0x3e36f8['length'],_0x3e36f8['forEach'](_0x2de4e6=>{_0x2de4e6['id']=_0x2b86b1++;}),this['_processTape'](_0x3e36f8)):this['_markInsertions'](_0x3e36f8,_0x499dec);const _0x48e2f4=_0x3e36f8['filter'](_0x4e4725=>!_0x4e4725['isAdded'])['map'](_0x152e42=>_0x152e42['id']);let _0x1be234=0x0;const _0x4f195e=this['_makeTape'](_0x18af21['model'][_0x4e365a]['deletions']);_0x4f195e['forEach'](_0x4638f6=>{_0x4638f6['isRemoved']?_0x4638f6['id']=_0xa4e446++:_0x4638f6['id']=_0x48e2f4[_0x1be234++];}),this['_processTape'](_0x4f195e),this['_setDistance'](_0x3e36f8,'isAdded'),this['_setDistance'](_0x4f195e,'isRemoved'),_0x18af21==_0x1027c1&&this['_markMarkers'](_0x3e36f8,_0x18fa85),_0x3e36f8=this['_joinTapes'](_0x3e36f8,_0x4f195e),this['_refreshStartEndIndex'](_0x3e36f8),this['_setDistance'](_0x3e36f8,'isRemoved');}_0x3e36f8=_0x3e36f8['filter'](_0x596c5d=>!(_0x596c5d['isAdded']&&_0x596c5d['isRemoved']));const _0x5abc93=new Map(_0x3207a0['model'][_0x4e365a]['deletions']['markers']),_0x3c51fb=new Set(_0x18fa85['keys']());for(const _0x3b77a0 of _0x5abc93['keys']())_0x3c51fb['delete'](_0x3b77a0);this['_markSuggestions'](_0x3e36f8,_0x3c51fb),this['_fixObsoleteTags'](_0x3e36f8),_0x3e36f8=this['_removeMissingPairs'](_0x3e36f8),_0x3e36f8=this['_markMismatchedRemovedTags'](_0x3e36f8),_0x3e36f8=this['_removeUnsupportedChanges'](_0x3e36f8);const {root:_0x10429a,changes:_0xa95046}=this['_makeModelFromTape'](_0x3e36f8,_0x126b47,_0x4e365a);_0x2527a6['model'][_0x4e365a]=_0x10429a;const _0x551223=_0x12bb54['get'](_0x4e365a);if(_0x551223){const _0x4f0567=_0x126b47['get'](_0x551223['userId']),_0x21f8d0=new G({'author':_0x4f0567,'type':_0x551223['isAttached']?'add':'remove','data':{'isOnRoot':!0x0},'createdAt':new Date(),'rootName':_0x4e365a});_0xa95046['unshift'](_0x21f8d0),_0x2527a6['attributes'][_0x4e365a]['revisionHistoryAttachChange']=_0x21f8d0['id'];}_0x2527a6['changes']=_0x2527a6['changes']['concat'](_0xa95046);}return _0x2527a6;}['_markMarkers'](_0x365daa,_0x315e9a){for(let _0x5452d7=0x0;_0x5452d7<_0x365daa['length'];_0x5452d7++)for(const [_0x38c3e1,_0x55460b]of _0x315e9a)!_0x55460b['isCollapsed']&&_0x55460b['start']['isEqual'](_0x365daa[_0x5452d7]['previousPosition'])&&_0x365daa[_0x5452d7]['markersStart']['push'](_0x38c3e1),_0x55460b['end']['isEqual'](_0x365daa[_0x5452d7]['nextPosition'])&&_0x365daa[_0x5452d7]['markersEnd']['push'](_0x38c3e1);}['_joinTapes'](_0x3a1985,_0x2a12d6){let _0x15826d=[],_0x3e3f54=0x0,_0x103bd0=0x0;for(;_0x3e3f54<_0x3a1985['length']||_0x103bd0<_0x2a12d6['length'];){const _0x4d7d21=_0x3a1985[_0x3e3f54]||{},_0x94c7cc=_0x2a12d6[_0x103bd0]||{};if(_0x4d7d21['id']==_0x94c7cc['id'])_0x3e3f54++,_0x103bd0++,_0x15826d['push'](_0x4d7d21);else{if(_0x94c7cc['isRemoved']&&_0x4d7d21['isAdded']){const {commonTape:_0x431d8f,iEnd:_0x5b8aa2,jEnd:_0x47b03a}=this['_threeWayMerge'](_0x3a1985,_0x3e3f54,_0x2a12d6,_0x103bd0);_0x15826d=_0x15826d['concat'](_0x431d8f),_0x3e3f54=_0x5b8aa2,_0x103bd0=_0x47b03a;}else _0x94c7cc['isRemoved']?(_0x103bd0++,_0x15826d['push'](_0x94c7cc)):(_0x3e3f54++,_0x15826d['push'](_0x4d7d21));}}return _0x15826d;}['_markSuggestions'](_0x3a6867,_0x5a2e50){const _0x2145ed=[];for(let _0xc3d6b2=0x0;_0xc3d6b2<_0x3a6867['length'];_0xc3d6b2++){for(let _0x4c9fdd=0x0;_0x4c9fdd<_0x3a6867[_0xc3d6b2]['markersStart']['length'];_0x4c9fdd++){const _0x4659e3=_0x3a6867[_0xc3d6b2]['markersStart'][_0x4c9fdd];if(!_0x5a2e50['has'](_0x4659e3))continue;const {group:_0x8aa3f8,type:_0x1353bc,authorId:_0x203750}=_0x2ae793(_0x4659e3);'revision-suggestion'!=_0x8aa3f8||'insertion'!=_0x1353bc&&'deletion'!=_0x1353bc||(_0x2145ed['unshift']({'type':_0x1353bc,'name':_0x4659e3,'userId':_0x203750}),_0x3a6867[_0xc3d6b2]['markersStart']['splice'](_0x4c9fdd,0x1),_0x4c9fdd--);}_0x56baf6(_0x3a6867[_0xc3d6b2]);for(let _0x22cc9d=0x0;_0x22cc9d<_0x3a6867[_0xc3d6b2]['markersEnd']['length'];_0x22cc9d++){const _0x4b97c4=_0x3a6867[_0xc3d6b2]['markersEnd'][_0x22cc9d];if(!_0x5a2e50['has'](_0x4b97c4))continue;const {group:_0x545c59,type:_0x440824}=_0x2ae793(_0x4b97c4);if('revision-suggestion'!=_0x545c59||'insertion'!=_0x440824&&'deletion'!=_0x440824)continue;_0x3a6867[_0xc3d6b2]['markersEnd']['splice'](_0x22cc9d,0x1),_0x22cc9d--;const _0x47e741=_0x2145ed['findIndex'](_0x5de2cd=>_0x5de2cd['name']==_0x4b97c4);_0x47e741>-0x1&&_0x2145ed['splice'](_0x47e741,0x1);}}function _0x2ae793(_0x1f804e){const _0x54ff8d=_0x1f804e['split'](':');return{'group':_0x54ff8d[0x0],'type':_0x54ff8d[0x1],'subType':_0x54ff8d['length']>=0x5?_0x54ff8d[0x2]:null,'id':_0x54ff8d['length']<0x5?_0x54ff8d[0x2]:_0x54ff8d[0x3],'authorId':_0x54ff8d['length']<0x5?_0x54ff8d[0x3]:_0x54ff8d[0x4],'markerCount':0x6==_0x54ff8d['length']?_0x54ff8d[0x5]:null};}function _0x56baf6(_0x2d436a){for(let _0x3b28cb=0x0;_0x3b28cb<_0x2145ed['length'];_0x3b28cb++){if(_0x2d436a['isAdded']&&'insertion'==_0x2145ed[_0x3b28cb]['type']&&_0x2d436a['isAdded']['userId']==_0x2145ed[_0x3b28cb]['userId'])return _0x2d436a['isAddSuggestion']=_0x2145ed[_0x3b28cb],void delete _0x2d436a['isAdded'];if(!_0x2d436a['isAdded']&&!_0x2d436a['isRemoved']&&'deletion'==_0x2145ed[_0x3b28cb]['type'])return void(_0x2d436a['isRemoveSuggestion']=_0x2145ed[_0x3b28cb]);}}}['_setDistance'](_0x5a2409,_0xab9ba){let _0x41f1da=0x0,_0x4e4388=!0x1;const _0x407673=new Map();for(const _0x1b442c of _0x5a2409)_0x1b442c[_0xab9ba]?_0x4e4388&&(_0x41f1da++,_0x4e4388=!0x1):(_0x41f1da++,_0x4e4388=!0x0),_0x407673['set'](_0x1b442c['id'],_0x41f1da);for(let _0x2e6efe=0x0;_0x2e6efe<_0x5a2409['length'];_0x2e6efe++){if('isRemoved'==_0xab9ba&&_0x5a2409[_0x2e6efe]['isAdded']||'isAdded'==_0xab9ba&&_0x5a2409[_0x2e6efe]['isRemoved'])continue;if('text'==_0x5a2409[_0x2e6efe]['type']){_0x5a2409[_0x2e6efe]['distance']=0x0;continue;}const _0x3e9ca4=_0x407673['get'](_0x5a2409[_0x2e6efe]['pairId']),_0x10325c=_0x407673['get'](_0x5a2409[_0x2e6efe]['id']);_0x5a2409[_0x2e6efe]['distance']=_0x3e9ca4-_0x10325c;}}['_getRevisionsRange'](_0x294acc,_0x41ce88,_0x1f59f4=!0x1){const _0x2fffb7=[];let _0x11ff0e=this['repository']['getIndex'](_0x294acc),_0xd33ce4=this['repository']['getIndex'](_0x41ce88);for(-0x1==_0xd33ce4&&(_0xd33ce4=this['repository']['_revisions']['length'],_0x1f59f4=!0x1);_0x11ff0e<_0xd33ce4;)_0x2fffb7['push'](this['repository']['getRevision'](_0x11ff0e)),_0x11ff0e++;return _0x1f59f4&&_0x2fffb7['push'](this['repository']['getRevision'](_0x11ff0e)),_0x2fffb7;}['_threeWayMerge'](_0x227131,_0x3d0c8d,_0x4c584,_0x5ebdd0){const _0x2f87c9=this['editor']['model']['schema'];let _0x45049d=_0x3d0c8d;for(;_0x227131[_0x45049d]&&_0x227131[_0x45049d]['isAdded'];)_0x45049d++;let _0x411fa2=_0x5ebdd0;for(;_0x4c584[_0x411fa2]&&_0x4c584[_0x411fa2]['isRemoved'];)_0x411fa2++;_0x3cee65(_0x227131,_0x3d0c8d,_0x45049d),_0x3cee65(_0x4c584,_0x5ebdd0,_0x411fa2);const _0xe6a8a4=_0x4c584['slice'](_0x5ebdd0,_0x411fa2)['concat'](_0x227131['slice'](_0x3d0c8d,_0x45049d));return _0xe6a8a4['sort']((_0x16f138,_0x278de1)=>_0x16f138['side']!=_0x278de1['side']?_0x16f138['side']-_0x278de1['side']:_0x16f138['level']!=_0x278de1['level']?_0x16f138['level']-_0x278de1['level']:_0x16f138['distance']!=_0x278de1['distance']?_0x278de1['distance']-_0x16f138['distance']:!!_0x16f138['isAdded']!=!!_0x278de1['isAdded']?-0x1==_0x16f138['side']||0x0==_0x16f138['side']?_0x16f138['isAdded']?-0x1:0x1:_0x16f138['isAdded']?0x1:-0x1:_0x16f138['index']-_0x278de1['index']),{'commonTape':_0xe6a8a4,'iEnd':_0x45049d,'jEnd':_0x411fa2};function _0x3cee65(_0x5b95e5,_0x2f4d71,_0x465442){let _0x32282d=-0x1,_0x248d4f=Number['POSITIVE_INFINITY'],_0x2391f9=!0x0;for(let _0x14facf=_0x2f4d71;_0x14facf<_0x465442;_0x14facf++)if(_0x2f87c9['isInline'](_0x5b95e5[_0x14facf]['item'])||(_0x2391f9=!0x1),_0x5b95e5[_0x14facf]['item']['startIndex']<_0x2f4d71&&(_0x32282d=_0x14facf),_0x5b95e5[_0x14facf]['item']['endIndex']>=_0x465442){_0x248d4f=_0x14facf;break;}_0x2391f9&&(_0x32282d=_0x465442-0x1);for(let _0x357b16=_0x2f4d71;_0x357b16<_0x465442;_0x357b16++)_0x5b95e5[_0x357b16]['side']=_0x357b16<=_0x32282d?-0x1:_0x357b16<_0x248d4f?0x0:0x1,_0x5b95e5[_0x357b16]['index']=_0x357b16;let _0x4c6de6=0x0;for(let _0x24353e=_0x2f4d71;_0x24353e<=_0x32282d;_0x24353e++)0x0==_0x5b95e5[_0x24353e]['distance']?_0x5b95e5[_0x24353e]['level']=_0x4c6de6:(_0x4c6de6++,_0x5b95e5[_0x24353e]['level']=_0x4c6de6,_0x4c6de6++);for(let _0x5c0aa7=_0x2f4d71;_0x5c0aa7<_0x465442;_0x5c0aa7++)0x0==_0x5b95e5[_0x5c0aa7]['side']&&(_0x5b95e5[_0x5c0aa7]['level']=_0x4c6de6);_0x4c6de6=0x0;for(let _0x18d3b5=_0x465442-0x1;_0x18d3b5>=_0x248d4f;_0x18d3b5--)0x0==_0x5b95e5[_0x18d3b5]['distance']?_0x5b95e5[_0x18d3b5]['level']=_0x4c6de6:(_0x4c6de6--,_0x5b95e5[_0x18d3b5]['level']=_0x4c6de6,_0x4c6de6--);}}['_fixObsoleteTags'](_0x598c31){const _0x3467af=new Map(),_0x2b7286=this['editor']['model']['schema'];for(let _0x17968a=0x1;_0x17968a<_0x598c31['length'];_0x17968a++){let _0x39393b,_0x268f19,_0x338b21;const _0x24baca=_0x598c31[_0x17968a],_0x583e12=_0x598c31[_0x17968a-0x1];if('text'==_0x24baca['type'])continue;if(_0x24baca['type']!=_0x583e12['type'])continue;if(!_0x2b7286['isBlock'](_0x583e12['item'])||_0x2b7286['isLimit'](_0x583e12['item']))continue;if(!_0x2b7286['isBlock'](_0x24baca['item'])||_0x2b7286['isLimit'](_0x24baca['item']))continue;if((_0x598c31[_0x17968a]['isAdded']||_0x598c31[_0x17968a]['isAddSuggestion'])&&_0x598c31[_0x17968a-0x1]['isRemoved'])_0x39393b=_0x598c31[_0x17968a],_0x268f19=_0x598c31[_0x17968a-0x1],_0x338b21=_0x17968a-0x1;else{if(!_0x598c31[_0x17968a]['isRemoved']||!_0x598c31[_0x17968a-0x1]['isAdded']&&!_0x598c31[_0x17968a-0x1]['isAddSuggestion'])continue;_0x39393b=_0x598c31[_0x17968a-0x1],_0x268f19=_0x598c31[_0x17968a],_0x338b21=_0x17968a;}const _0x253da5=_0x39393b['level']==_0x268f19['level'],_0x16898e=Math['abs'](_0x39393b['level'])<Math['abs'](_0x268f19['level'])&&0x0==_0x268f19['distance'];(_0x253da5||_0x16898e)&&(_0x3467af['set'](_0x268f19['id'],_0x39393b['id']),_0x598c31['splice'](_0x338b21,0x1),_0x17968a--,_0x39393b['isAdded']=!0x1);}for(let _0x15863c=0x0;_0x15863c<_0x598c31['length'];_0x15863c++)_0x3467af['has'](_0x598c31[_0x15863c]['pairId'])&&(_0x598c31[_0x15863c]['pairId']=_0x3467af['get'](_0x598c31[_0x15863c]['pairId']));}['_removeMissingPairs'](_0x54df87){const _0x5b7ed3=new Set(_0x54df87['map'](_0x3c5a1e=>_0x3c5a1e['id']));for(let _0x5468de=0x0;_0x5468de<_0x54df87['length'];_0x5468de++)_0x5b7ed3['has'](_0x54df87[_0x5468de]['pairId'])||0x0==_0x54df87[_0x5468de]['distance']||(_0x54df87[_0x5468de]['isIncorrect']=!0x0);return _0x54df87['filter'](_0xc8f4e6=>!_0xc8f4e6['isIncorrect']);}['_markMismatchedRemovedTags'](_0x14cb48){const _0x171069=new Set();for(let _0x4ba4f0=0x0;_0x4ba4f0<_0x14cb48['length'];_0x4ba4f0++){if(_0x171069['has'](_0x14cb48[_0x4ba4f0]['id'])&&_0x14cb48[_0x4ba4f0]['isRemoved']&&(_0x14cb48[_0x4ba4f0]['isIncorrect']=!0x0),_0x14cb48[_0x4ba4f0]['isIncorrect'])continue;if(0x0==_0x14cb48[_0x4ba4f0]['distance'])continue;if('elementStart'!=_0x14cb48[_0x4ba4f0]['type'])continue;if(null==_0x14cb48[_0x4ba4f0]['pairId'])continue;let _0x57d04c=_0x4ba4f0+0x1,_0x339d7a=0x0;for(;_0x14cb48[_0x57d04c]['id']!=_0x14cb48[_0x4ba4f0]['pairId'];)'elementStart'==_0x14cb48[_0x57d04c]['type']?_0x339d7a++:'elementEnd'==_0x14cb48[_0x57d04c]['type']&&_0x339d7a--,_0x57d04c++;if(0x0!=_0x339d7a){if(_0x14cb48[_0x4ba4f0]['isRemoved'])_0x14cb48[_0x4ba4f0]['isIncorrect']=!0x0;else{for(;_0x57d04c!=_0x4ba4f0;)_0x14cb48[_0x57d04c]['isRemoved']&&0x0!=_0x14cb48[_0x57d04c]['distance']&&(_0x14cb48[_0x57d04c]['isIncorrect']=!0x0,_0x171069['add'](_0x14cb48[_0x57d04c]['pairId'])),_0x57d04c--;}}}return _0x14cb48['filter'](_0xf9bcba=>!_0xf9bcba['isIncorrect']);}['_removeUnsupportedChanges'](_0x3d7bfc){const _0x109480=this['editor']['model']['schema'];for(let _0x5b552e=0x0;_0x5b552e<_0x3d7bfc['length'];_0x5b552e++){if(!(_0x3d7bfc[_0x5b552e]['isAdded']||_0x3d7bfc[_0x5b552e]['isAddSuggestion']||_0x3d7bfc[_0x5b552e]['isRemoved']||_0x3d7bfc[_0x5b552e]['isRemoveSuggestion']))continue;if(0x0==_0x3d7bfc[_0x5b552e]['distance'])continue;const _0x1d4b4c=_0x3d7bfc[_0x5b552e]['item'];_0x109480['isBlock'](_0x1d4b4c)||_0x109480['isLimit'](_0x1d4b4c)||(_0x3d7bfc[_0x5b552e]['isAdded']&&delete _0x3d7bfc[_0x5b552e]['isAdded'],_0x3d7bfc[_0x5b552e]['isAddSuggestion']&&delete _0x3d7bfc[_0x5b552e]['isAddSuggestion'],_0x3d7bfc[_0x5b552e]['isRemoveSuggestion']&&delete _0x3d7bfc[_0x5b552e]['isRemoveSuggestion'],_0x3d7bfc[_0x5b552e]['isRemoved']&&(_0x3d7bfc[_0x5b552e]['isIncorrect']=!0x0));}return _0x3d7bfc['filter'](_0x4f6d41=>!_0x4f6d41['isIncorrect']);}['_makeModelFromTape'](_0x43893c,_0x4a0cde,_0x4130d3){const _0x17f4a4=new _0x34988e(),_0x50935e=[],_0x45996d=new Map(),_0x22becd=this['editor']['model'],_0x684ca2=_0x22becd['schema'],_0x409e9d=[_0x17f4a4],_0x2bfab5={},_0x23a9df={'isAdded':[],'isRemoved':[],'isAddSuggestion':[],'isRemoveSuggestion':[]};let _0x598066=null;const _0x4e4f72=[0x0];for(let _0x4e6167=0x0;_0x4e6167<_0x43893c['length'];_0x4e6167++)if('elementStart'===_0x43893c[_0x4e6167]['type']){_0x43893c[_0x4e6167]['previousPosition']=_0x22becd['createPositionFromPath'](_0x17f4a4,_0x4e4f72);const _0x2a033c=new _0x306706(_0x43893c[_0x4e6167]['item']['name'],_0x43893c[_0x4e6167]['item']['getAttributes']());_0x409e9d[0x0]['_appendChild'](_0x2a033c),_0x4e4f72['push'](0x0),_0x409e9d['unshift'](_0x2a033c),_0x43893c[_0x4e6167]['nextPosition']=_0x22becd['createPositionFromPath'](_0x17f4a4,_0x4e4f72);}else'elementEnd'===_0x43893c[_0x4e6167]['type']?(_0x409e9d['shift'](),_0x43893c[_0x4e6167]['previousPosition']=_0x22becd['createPositionFromPath'](_0x17f4a4,_0x4e4f72),_0x4e4f72['pop'](),_0x4e4f72[_0x4e4f72['length']-0x1]++,_0x43893c[_0x4e6167]['nextPosition']=_0x22becd['createPositionFromPath'](_0x17f4a4,_0x4e4f72)):(_0x43893c[_0x4e6167]['previousPosition']=_0x22becd['createPositionFromPath'](_0x17f4a4,_0x4e4f72),_0x598066?_0x598066['_data']+=_0x43893c[_0x4e6167]['item']['data']:_0x598066=new _0x1ae1a6(_0x43893c[_0x4e6167]['item']['data'],_0x43893c[_0x4e6167]['item']['getAttributes']()),_0x43893c[_0x4e6167+0x1]&&'text'===_0x43893c[_0x4e6167+0x1]['type']&&_0x4f30bc(_0x598066,_0x43893c[_0x4e6167+0x1]['item'])||(_0x409e9d[0x0]['_appendChild'](_0x598066),_0x598066=null),_0x4e4f72[_0x4e4f72['length']-0x1]+=_0x43893c[_0x4e6167]['item']['offsetSize'],_0x43893c[_0x4e6167]['nextPosition']=_0x22becd['createPositionFromPath'](_0x17f4a4,_0x4e4f72));for(let _0x15f059=0x0;_0x15f059<_0x43893c['length'];_0x15f059++){const _0x2e3546=_0x43893c[_0x15f059]['previousPosition'],_0x2dfd9c=_0x43893c[_0x15f059]['nextPosition'];for(const _0xc04845 of _0x43893c[_0x15f059]['markersStart'])_0x45996d['set'](_0xc04845,{'start':_0x2e3546,'end':null});_0x4ffb83('isRemoveSuggestion',_0x15f059,_0x2e3546,_0x2dfd9c),_0x4ffb83('isAddSuggestion',_0x15f059,_0x2e3546,_0x2dfd9c),_0x4ffb83('isRemoved',_0x15f059,_0x2e3546,_0x2dfd9c),_0x4ffb83('isAdded',_0x15f059,_0x2e3546,_0x2dfd9c);for(const _0x2f7634 of _0x43893c[_0x15f059]['markersEnd']){const _0x5c97f3=_0x45996d['get'](_0x2f7634);_0x5c97f3?_0x5c97f3['end']=_0x2dfd9c:_0x45996d['set'](_0x2f7634,{'start':_0x2dfd9c,'end':_0x2dfd9c});}}for(const [_0x5c97ff,_0x2dde9a]of _0x45996d){const _0x53bd2c=this['editor']['model']['createRange'](_0x2dde9a['start'],_0x2dde9a['end']);_0x17f4a4['markers']['set'](_0x5c97ff,_0x53bd2c);}return _0x50935e['sort']((_0x370ce0,_0xa6a4eb)=>{const _0x44a731=_0x17f4a4['markers']['get']('revision:'+_0x370ce0['id']),_0x4c2322=_0x17f4a4['markers']['get']('revision:'+_0xa6a4eb['id']);return _0x44a731['start']['isBefore'](_0x4c2322['start'])?-0x1:_0x44a731['start']['isAfter'](_0x4c2322['start'])?0x1:_0x44a731['end']['isBefore'](_0x4c2322['end'])?-0x1:_0x44a731['end']['isAfter'](_0x4c2322['end'])?0x1:'add'===_0x370ce0['type']?-0x1:0x1;}),{'root':_0x17f4a4,'changes':_0x50935e};function _0x4ffb83(_0x532428,_0x36c04f,_0xcd3406,_0x13e9f6){const _0x4ac5ea=!!_0x43893c[_0x36c04f][_0x532428],_0x5e4930=_0x4ac5ea?_0x43893c[_0x36c04f][_0x532428]['userId']:null,_0x471d23=_0x36c04f===_0x43893c['length']-0x1,_0x47a9c7=_0x23a9df[_0x532428][0x0],_0x59fff2=_0x684ca2['isObject'](_0x43893c[_0x36c04f]['item']);!_0x2bfab5[_0x532428]&&_0x4ac5ea?_0x2bfab5[_0x532428]={'start':_0xcd3406,'tapeItem':_0x43893c[_0x36c04f],'userId':_0x5e4930,'type':_0x532428}:_0x2bfab5[_0x532428]&&!_0x4ac5ea?(_0x2bfab5[_0x532428]['end']=_0xcd3406,_0x4efadf(_0x2bfab5[_0x532428]),_0x2bfab5[_0x532428]=null):_0x2bfab5[_0x532428]&&_0x4ac5ea&&_0x2bfab5[_0x532428]['userId']!==_0x5e4930&&(_0x2bfab5[_0x532428]['end']=_0xcd3406,_0x47a9c7&&_0x47a9c7['userId']===_0x2bfab5[_0x532428]['userId']||_0x4efadf(_0x2bfab5[_0x532428]),_0x2bfab5[_0x532428]={'start':_0xcd3406,'tapeItem':_0x43893c[_0x36c04f],'userId':_0x5e4930,'type':_0x532428}),_0x2bfab5[_0x532428]&&_0x59fff2&&('elementStart'!==_0x43893c[_0x36c04f]['type']||_0x47a9c7&&_0x47a9c7['userId']===_0x5e4930||_0x23a9df[_0x532428]['unshift']({'userId':_0x5e4930,'object':_0x43893c[_0x36c04f]['item'],'change':_0x2bfab5[_0x532428]}),'elementEnd'===_0x43893c[_0x36c04f]['type']&&_0x47a9c7&&_0x47a9c7['object']===_0x43893c[_0x36c04f]['item']&&(_0x23a9df[_0x532428]['shift'](),_0x2bfab5[_0x532428]=_0x47a9c7['change'])),_0x2bfab5[_0x532428]&&_0x471d23&&(_0x2bfab5[_0x532428]['end']=_0x13e9f6,_0x4efadf(_0x2bfab5[_0x532428]),_0x2bfab5[_0x532428]=null);}function _0x4efadf({start:_0x481352,end:_0x154fd8,tapeItem:_0x397b78,userId:_0xdacd39,type:_0x356d46}){const _0x51b91d=_0x397b78['item'],_0x487c12=_0x22becd['schema']['isBlock'](_0x51b91d)&&!_0x22becd['schema']['isLimit'](_0x51b91d),_0x466035=_0x481352['nodeAfter']==_0x154fd8['parent']&&_0x154fd8['isAtStart'];if(_0x487c12&&_0x466035)return;const _0x17e146=_0x22becd['createRange'](_0x481352,_0x154fd8),_0x421c3e=_0x4a0cde['get'](_0xdacd39),_0x40fb20=new G({'author':_0x421c3e,'type':'isAdded'==_0x356d46||'isAddSuggestion'==_0x356d46?'add':'remove','data':{'isSuggestion':'isAddSuggestion'==_0x356d46||'isRemoveSuggestion'==_0x356d46},'createdAt':new Date(),'rootName':_0x4130d3});_0x50935e['push'](_0x40fb20),_0x17f4a4['markers']['set']('revision:'+_0x40fb20['id'],_0x17e146);}function _0x4f30bc(_0x44f063,_0x137e0e){const _0x4173d9=_0x44f063['getAttributes'](),_0x247a8d=_0x137e0e['getAttributes']();for(const _0x28745d of _0x4173d9){if(_0x28745d[0x1]!==_0x137e0e['getAttribute'](_0x28745d[0x0]))return!0x1;_0x247a8d['next']();}return _0x247a8d['next']()['done'];}}['_setConversion'](){this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision','view':_0x10b57a=>{const _0x164b9e=_0x10b57a['markerName']['split'](':')[0x1],_0x13da5a=this['_getChangeFromId'](_0x164b9e);if(!_0x13da5a)return null;const _0x15314e='add'==_0x13da5a['type']?'insertion':'deletion',_0x5290a2=['ck-suggestion-marker','ck-suggestion-marker-'+_0x15314e];return _0x13da5a['data']['isSuggestion']&&_0x5290a2['push']('ck-suggestion-marker-'+_0x15314e+'-new'),this['activeChange']==_0x13da5a&&_0x5290a2['push']('ck-suggestion-marker--active'),{'classes':_0x5290a2,'attributes':{'data-change-id':_0x164b9e}};}}),this['editor']['conversion']['for']('upcast')['add'](_0x39d5fb=>{_0x39d5fb['on']('element:pre',(_0x2c0bcf,_0x8f829a,_0xae132a)=>{const _0x2696a7=_0x8f829a['viewItem']['getChild'](0x0);if(!_0x2696a7||!_0x2696a7['is']('element','code'))return;if(!_0xae132a['consumable']['consume'](_0x2696a7,{'attributes':['vid_start','vid_end']}))return;const _0x2e3588=_0x8f829a['modelRange']['start']['nodeAfter'];_0xae132a['writer']['setAttribute']('vid_start',_0x2696a7['getAttribute']('vid_start'),_0x2e3588),_0xae132a['writer']['setAttribute']('vid_end',_0x2696a7['getAttribute']('vid_end'),_0x2e3588);},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['add'](_0x3f41a9=>{_0x3f41a9['on']('element',(_0x1eaa95,_0x2bf7b9,_0x11ca1d)=>{if(!_0x11ca1d['consumable']['consume'](_0x2bf7b9['viewItem'],{'attributes':['vid_start','vid_end']}))return;if(_0x2bf7b9['modelRange']['isCollapsed'])return;const _0x8aaa15=_0x2bf7b9['modelRange']['start']['nodeAfter'];_0x8aaa15['hasAttribute']('vid_start')||_0x8aaa15['hasAttribute']('vid')||(_0x11ca1d['writer']['setAttribute']('vid_start',_0x2bf7b9['viewItem']['getAttribute']('vid_start'),_0x8aaa15),_0x11ca1d['writer']['setAttribute']('vid_end',_0x2bf7b9['viewItem']['getAttribute']('vid_end'),_0x8aaa15));},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['elementToAttribute']({'view':{'name':'span','attributes':{'vid':!0x0}},'model':{'key':'vid','value':_0x9abf65=>_0x9abf65['getAttribute']('vid')}}),this['editor']['model']['schema']['on']('checkAttribute',(_0x4daf60,[,_0x59455d])=>{['vid_start','vid_end','vid']['includes'](_0x59455d)&&(_0x4daf60['return']=!0x0,_0x4daf60['stop']());},{'priority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x2092ce=>{_0x2092ce['on']('attribute:vid',(_0x36d1ad,_0xb19d8f,_0x406262)=>{if('\x20'!=_0xb19d8f['item']['data']||_0xb19d8f['item']['parent']['maxOffset']>0x1)return;if(!_0x406262['consumable']['consume'](_0xb19d8f['item'],_0x36d1ad['name']))return;const _0xb965ea=_0x406262['writer'],_0x3c54b9=_0x406262['mapper']['toViewRange'](_0xb19d8f['range']);_0xb965ea['wrap'](_0x3c54b9,_0xb965ea['createAttributeElement']('span'));});}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',function(_0x4c809b){const _0x1ad73c=_0x4c809b['plugins']['get']('RevisionViewer');return(_0x455caa,_0x2dcb91,_0x4f1248)=>{const _0x59a291=_0x2dcb91['markerName']['split'](':')[0x1],_0x563ef0=_0x1ad73c['_getChangeFromId'](_0x59a291);if(!_0x563ef0)return null;const _0x23699d='add'==_0x563ef0['type']?'split':'merge';if(!_0x4f1248['consumable']['test'](_0x2dcb91['markerRange'],_0x455caa['name']))return;const _0x25081f=_0x2dcb91['markerRange']['getWalker'](),_0x8f2894=_0x2dcb91['markerRange']['start'],_0x4eaae4=_0x4c809b['model']['schema'];let _0xb8b4de=null,_0x1eb243=null,_0x18a895=!0x1,_0x2c41c8=!0x1;for(const _0x161271 of _0x25081f){const _0x535372=_0x161271['item'];_0x18a895=_0x18a895||_0x4eaae4['isContent'](_0x535372);const _0x18ce11=_0x4f1248['mapper']['toViewElement'](_0x535372);if(_0x18ce11&&_0x18ce11['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x161271['type']&&(_0x4eaae4['isBlock'](_0x535372)&&!_0x4eaae4['isLimit'](_0x535372)&&(_0x535372['nextSibling']||_0x8f2894['isAtEnd']?_0xb8b4de&&_0xb8b4de['parent']==_0x535372||(_0xb8b4de=_0x535372,_0x1d05d3(_0x161271['previousPosition']),_0x2c41c8=!0x0):_0x1eb243=_0x1eb243||_0x161271['previousPosition']));}function _0x1d05d3(_0x258af0){const _0x17ea04=_0x4f1248['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x23699d}),_0x121149=_0x4f1248['mapper']['toViewPosition'](_0x258af0);_0x563ef0['data']['isSuggestion']&&_0x4f1248['writer']['addClass']('ck-suggestion-marker-'+_0x23699d+'-new',_0x17ea04),_0x1ad73c['activeChange']==_0x563ef0&&_0x4f1248['writer']['addClass']('ck-suggestion-marker--active',_0x17ea04),_0x4f1248['writer']['insert'](_0x121149,_0x17ea04),_0x4f1248['mapper']['bindElementToMarker'](_0x17ea04,_0x2dcb91['markerName']);}_0x18a895||_0x2c41c8||!_0x1eb243||_0x1d05d3(_0x1eb243);};}(this['editor']),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision',(_0x18dc93,_0x50f437,_0x4b7f77)=>{const _0x4bf27d=_0x4b7f77['mapper']['markerNameToElements'](_0x50f437['markerName']);if(_0x4bf27d){for(const _0xd5649f of _0x4bf27d)(_0xd5649f['hasClass']('ck-suggestion-marker-split')||_0xd5649f['hasClass']('ck-suggestion-marker-merge'))&&(_0x4b7f77['mapper']['unbindElementFromMarkerName'](_0xd5649f,_0x50f437['markerName']),_0x4b7f77['writer']['remove'](_0xd5649f));}},{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',(_0x3cfc45,_0x1e9fa1,_0x3316cf)=>{const _0x4be1b3=_0x1e9fa1['markerName']['split'](':')[0x1],_0xbc9a67=this['_getChangeFromId'](_0x4be1b3);if(!_0xbc9a67)return null;const _0xdae676='add'==_0xbc9a67['type']?'split':'merge';if(_0x3316cf['consumable']['test'](_0x1e9fa1['markerRange'],_0x3cfc45['name']))for(const _0x5d5d68 of _0x1e9fa1['markerRange']['getItems']()){if(!_0x5d5d68['is']('element','softBreak'))continue;const _0x477fc3=_0x3316cf['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0xdae676}),_0xe3aca6=_0x3316cf['mapper']['toViewPosition'](this['editor']['model']['createPositionBefore'](_0x5d5d68));_0xbc9a67['data']['isSuggestion']&&_0x3316cf['writer']['addClass']('ck-suggestion-marker-'+_0xdae676+'-new',_0x477fc3),this['activeChange']==_0xbc9a67&&_0x3316cf['writer']['addClass']('ck-suggestion-marker--active',_0x477fc3),_0x3316cf['writer']['insert'](_0xe3aca6,_0x477fc3),_0x3316cf['mapper']['bindElementToMarker'](_0x477fc3,_0x1e9fa1['markerName']);}},{'priority':'high'}),this['editor']['model']['document']['on']('change',()=>{this['editor']['editing']['view']['change'](_0x960f76=>{for(const _0x4a71cb of this['editor']['model']['document']['getRootNames']()){const _0x543af6=this['editor']['model']['document']['getRoot'](_0x4a71cb),_0x1df11a=this['editor']['editing']['view']['document']['getRoot'](_0x4a71cb);if(_0x1df11a){const _0x344ef9=_0x543af6['getAttribute']('revisionHistoryAttachChange');if(_0x960f76['removeAttribute']('data-change-id',_0x1df11a),_0x960f76['removeClass']('ck-revision-history-root-add',_0x1df11a),_0x960f76['removeClass']('ck-revision-history-root-remove',_0x1df11a),_0x960f76['removeClass']('ck-revision-history-root--active',_0x1df11a),_0x344ef9){const _0x4535c3=this['_getChangeFromId'](_0x344ef9);if(!_0x4535c3)return null;_0x960f76['setAttribute']('data-change-id',_0x344ef9,_0x1df11a),_0x960f76['addClass']('ck-revision-history-root-'+_0x4535c3['type'],_0x1df11a),this['activeChange']==_0x4535c3&&_0x960f76['addClass']('ck-revision-history-root--active',_0x1df11a);}}}});}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'comment','model':_0x15f825=>'revision-comment:'+_0x15f825,'converterPriority':'highest'}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'suggestion','model':_0x45ffa1=>'revision-suggestion:'+_0x45ffa1,'converterPriority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision-suggestion','view':_0x1043e1=>({'name':'suggestion:'+_0x1043e1,'group':'revision-suggestion'}),'converterPriority':'highest'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision-suggestion','view':_0x155f9f=>{const _0x129bde=_0x155f9f['markerName']['split'](':')[0x1];return'insertion'!=_0x129bde&&'deletion'!=_0x129bde?null:{'classes':['ck-suggestion-preview-marker','ck-suggestion-preview-marker-'+_0x129bde]};}}),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',(_0x2af813,_0x261915,_0x2ab337)=>{const _0x29fd2b=_0x2ab337['mapper']['markerNameToElements'](_0x261915['markerName']);if(_0x29fd2b){for(const _0x95306d of _0x29fd2b)_0x95306d['is']('uiElement')&&(_0x2ab337['mapper']['unbindElementFromMarkerName'](_0x95306d,_0x261915['markerName']),_0x2ab337['writer']['remove'](_0x95306d));}},{'priority':'high'});}['_getChangeFromId'](_0x15b22b){return this['_changeIdToChange']['get'](_0x15b22b);}['_getViewForChange'](_0x30061d){return this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=new z(this['editor']['locale'],_0x30061d),this['_changeView'];}['_initInteractions'](){this['editor']['model']['document']['selection']['observeMarkers']('revision'),this['on']('change:activeView',(_0x33cdfe,_0x1552ef,_0xaf6d9e,_0x3d7599)=>{_0x3d7599&&this['_balloon']['remove'](_0x3d7599),_0xaf6d9e&&(this['_balloon']['add']({'view':_0xaf6d9e,'stackId':'revisionHistoryLabel','position':{'target':()=>{const _0x4ff686=this['editor']['editing'],_0x3346f0=this['_getChangeFromId'](_0xaf6d9e['changeId']);let _0x41009b;if(_0x3346f0['data']['isOnRoot']){const _0x243b67=_0x4ff686['view']['getDomRoot'](_0x3346f0['rootName']);_0x41009b=Array['from'](_0x243b67['getClientRects']());}else{const _0x482992=this['editor']['model']['markers']['get']('revision:'+_0xaf6d9e['changeId']);_0x41009b=Array['from'](_0x4ff686['mapper']['markerNameToElements'](_0x482992['name']))['map'](_0x2b105a=>_0x4ff686['view']['domConverter']['mapViewToDom'](_0x2b105a))['map'](_0x58da08=>Array['from'](_0x58da08['getClientRects']()))['flat']();}if(!this['_activeViewTarget'])return _0x41009b[0x0];return _0x41009b['find'](_0x2694f4=>_0x2694f4['top']-0x3<=this['_activeViewTarget']['y']&&_0x2694f4['bottom']+0x3>=this['_activeViewTarget']['y']&&_0x2694f4['left']-0x3<=this['_activeViewTarget']['x']&&_0x2694f4['right']+0x3>=this['_activeViewTarget']['x'])||_0x41009b[0x0];}}}),this['_balloon']['showStack']('revisionHistoryLabel'));}),this['on']('change:activeChange',(_0x5b460d,_0x5919a7,_0x29edc9,_0x28687f)=>{this['activeView']=_0x29edc9?this['_getViewForChange'](_0x29edc9):null,this['editor']['model']['change'](()=>{const _0x1718fb=this['editor']['editing'];_0x28687f&&(_0x28687f['data']['isOnRoot']?_0x1718fb['view']['change'](_0x732c7f=>{_0x732c7f['removeClass']('ck-revision-history-root--active',_0x1718fb['view']['document']['getRoot'](_0x28687f['rootName']));}):_0x1718fb['reconvertMarker']('revision:'+_0x28687f['id'])),_0x29edc9&&(_0x29edc9['data']['isOnRoot']?_0x1718fb['view']['change'](_0x1af9f1=>{_0x1af9f1['addClass']('ck-revision-history-root--active',_0x1718fb['view']['document']['getRoot'](_0x29edc9['rootName']));}):_0x1718fb['reconvertMarker']('revision:'+_0x29edc9['id']));});}),this['listenTo'](this['editor']['editing']['view']['document'],'mouseover',(_0x548c37,_0x40abcd)=>{if(this['activeChange'])return;const _0x50fe67=this['_findChangeIdFromDomTarget'](_0x40abcd['target']),_0x200322=this['_changeIdToChange']['get'](_0x50fe67);_0x200322?(this['_activeViewTarget']={'x':_0x40abcd['domEvent']['x'],'y':_0x40abcd['domEvent']['y']},this['activeView']=this['_getViewForChange'](_0x200322)):(this['_activeViewTarget']=null,this['activeView']=null);}),this['listenTo'](this['editor']['editing']['view']['document'],'mousedown',(_0x16069a,_0x18b107)=>{const _0x13fd51=this['_findChangeIdFromDomTarget'](_0x18b107['target']),_0x2e28ce=this['_changeIdToChange']['get'](_0x13fd51);_0x2e28ce?(this['_activeViewTarget']={'x':_0x18b107['domEvent']['x'],'y':_0x18b107['domEvent']['y']},_0x2e28ce===this['activeChange']?this['_balloon']['updatePosition']():this['activeChange']=_0x2e28ce):(this['_activeViewTarget']=null,this['activeChange']=null);});}['_findChangeIdFromDomTarget'](_0x412c2e){do{const _0xc6fc84=_0x412c2e['getAttribute']('data-change-id');if(_0xc6fc84)return _0xc6fc84;_0x412c2e=_0x412c2e['parent'];}while(_0x412c2e);return null;}['_cleanMarkers'](){this['editor']['model']['change'](_0x15b7b1=>{for(const _0x30e1e8 of this['editor']['model']['markers'])_0x15b7b1['removeMarker'](_0x30e1e8);});}}function Q(_0x56a86f,_0x424567){return(_0x3cc1db,_0x41179f,_0x35c4bd)=>{if(!_0x35c4bd['consumable']['test'](_0x41179f['markerRange'],_0x3cc1db['name']))return;const _0x4bcba4=_0x41179f['markerRange']['getWalker'](),_0x4e3dc1=_0x41179f['markerRange']['start'],_0x187c03=_0x56a86f['model']['schema'];let _0x587a46=null,_0xd06bdd=null,_0x1db19f=!0x1,_0x27427f=!0x1;for(const _0xe9e540 of _0x4bcba4){const _0x2e19f3=_0xe9e540['item'];_0x1db19f=_0x1db19f||_0x187c03['isContent'](_0x2e19f3);const _0x2cd1f8=_0x35c4bd['mapper']['toViewElement'](_0x2e19f3);if(_0x2cd1f8&&_0x2cd1f8['getCustomProperty']('addHighlight'))return;'elementEnd'==_0xe9e540['type']&&(_0x187c03['isBlock'](_0x2e19f3)&&!_0x187c03['isLimit'](_0x2e19f3)&&(_0x2e19f3['nextSibling']||_0x4e3dc1['isAtEnd']?_0x587a46&&_0x587a46['parent']==_0x2e19f3||(_0x587a46=_0x2e19f3,_0xe7e897(_0xe9e540['previousPosition']),_0x27427f=!0x0):_0xd06bdd=_0xd06bdd||_0xe9e540['previousPosition']));}function _0xe7e897(_0x46833d){const _0x33cf8b=_0x35c4bd['mapper']['toViewPosition'](_0x46833d),_0x53bfd2=_0x35c4bd['writer']['createUIElement']('span',{'class':'ck-suggestion-preview-marker-'+_0x424567});_0x35c4bd['writer']['insert'](_0x33cf8b,_0x53bfd2),_0x35c4bd['mapper']['bindElementToMarker'](_0x53bfd2,_0x41179f['markerName']);}_0x1db19f||_0x27427f||!_0xd06bdd||_0xe7e897(_0xd06bdd);};}class nt extends _0x2ce108{constructor(_0x410296){super(_0x410296);const _0x5330f6=_0x410296['plugins']['get'](l);this['affectsData']=!0x1,this['listenTo'](_0x5330f6,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x5330f6,'change:isEnabled',()=>this['refresh']());}['execute'](){const _0x453858=this['editor'],_0x4a0ca5=_0x453858['plugins']['get'](l),_0x3dbf3a=_0x4a0ca5['isReady']?_0x4a0ca5['diff']['newRevisionId']:null;_0x453858['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x3dbf3a);}['refresh'](){const {isReady:_0xf3e94,isEnabled:_0xbfdd0b,repository:_0x55e640,diff:_0x462243}=this['editor']['plugins']['get'](l),_0x5710e4=_0x462243&&_0x55e640['getLaterVisibleRevision'](_0x462243['newRevisionId']);this['isEnabled']=_0xf3e94&&_0xbfdd0b&&Boolean(_0x5710e4);}}class ot extends _0x2ce108{['_step'];constructor(_0x35964c,{direction:_0x48b9ce}){super(_0x35964c);const _0x1f80aa=_0x35964c['plugins']['get'](l);this['affectsData']=!0x1,this['_step']='forward'===_0x48b9ce?0x1:-0x1,this['listenTo'](_0x1f80aa,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x1f80aa,'change:isEnabled',()=>this['refresh']()),this['listenTo'](_0x1f80aa,'change:activeChange',()=>this['refresh']());}['execute'](){const _0x5a2dd8=this['editor'],_0x3e5899=_0x5a2dd8['plugins']['get'](l),{isNavigationMode:_0x5878c2,currentChangeNumber:_0x4ebe3f}=_0x3e5899;let _0x52b149;if(_0x3e5899['activeChange']=_0x5878c2?_0x3e5899['diff']['changes']['get'](_0x4ebe3f+this['_step']):_0x3e5899['diff']['changes']['first'],_0x3e5899['activeChange']['data']['isOnRoot'])_0x52b149=_0x5a2dd8['editing']['view']['getDomRoot'](_0x3e5899['activeChange']['rootName']);else{const _0x245ba0=_0x5a2dd8['model']['markers']['get']('revision:'+_0x3e5899['activeChange']['id']);_0x52b149=_0x5b68a6(_0x5a2dd8['editing'],_0x245ba0);}_0x151929({'target':_0x52b149,'viewportOffset':0x28});}['refresh'](){const {isNavigationMode:_0x291a4a,currentChangeNumber:_0x2acaec,numberOfChanges:_0xe1a5ad,isReady:_0x1b9ece,isEnabled:_0x272bc0}=this['editor']['plugins']['get'](l);this['isEnabled']=!!(_0x272bc0&&_0x1b9ece&&_0xe1a5ad)&&(!_0x291a4a||(0x1===this['_step']?_0x2acaec<_0xe1a5ad-0x1:_0x2acaec>0x0));}}class pi extends _0xaf2574{constructor(_0x13dc0f){super(_0x13dc0f);const _0x597556=this['bindTemplate'],_0xde57ee=new _0x14f10b(_0x13dc0f),_0x1ff622=new _0x14f10b(_0x13dc0f);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',(_0x4f9464,_0x2dbae6)=>_0x4f9464&&_0x2dbae6>0x0),this['bind']('_statusText')['to'](this,'isReady',this,'currentChangeNumber',this,'numberOfChanges',this,'isNavigationMode',(_0x487036,_0x28a359,_0x3e00f0,_0x3fae32)=>{if(!_0x487036)return R(_0x13dc0f,'Loading...');if(!_0x3e00f0)return R(_0x13dc0f,'No\x20changes');const _0x205f75=R(_0x13dc0f,'NUMBER_OF_CHANGES',_0x3e00f0);return _0x3fae32?R(_0x13dc0f,'X_OF_Y_CHANGES',[_0x28a359+0x1,_0x3e00f0]):_0x205f75;}),_0xde57ee['set']({'label':R(_0x13dc0f,'Show\x20previous\x20change'),'tooltip':!0x0,'icon':_0x461ee6}),_0x1ff622['set']({'label':R(_0x13dc0f,'Show\x20next\x20change'),'tooltip':!0x0,'icon':_0x4e9a93}),_0xde57ee['bind']('isEnabled')['to'](this,'isBackwardNavigationEnabled'),_0x1ff622['bind']('isEnabled')['to'](this,'isForwardNavigationEnabled'),_0xde57ee['on']('execute',()=>this['fire']('execute','backward')),_0x1ff622['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',_0x597556['if']('_isStatusLabelVisible','ck-hidden',_0x312774=>!_0x312774)]},'children':[{'text':_0x597556['to']('isNavigationMode',_0x48ebdf=>_0x48ebdf?R(_0x13dc0f,'EDIT_X_OF_Y_REVISIONS')+':\x20':R(_0x13dc0f,'Total')+':\x20')}]},{'text':_0x597556['to']('_statusText')}]},new _0x3caa56(),{'tag':'div','attributes':{'class':['ck-revision-history-ui__changes-navigation__navigation']},'children':[_0xde57ee,_0x1ff622]}]});}}const ge='ck-editor__editable__loading-overlay';class fi extends _0x280bdd{static get['pluginName'](){return'RevisionViewerLoadingOverlay';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['show'](){const _0x33a6e7=this['editor']['editing']['view'];_0x33a6e7['change'](_0x4799ba=>{for(const _0x44aef0 of _0x33a6e7['document']['roots'])_0x4799ba['addClass'](ge,_0x44aef0);});}['hide'](){const _0x4df2f7=this['editor']['editing']['view'];_0x4df2f7['change'](_0x2b55b3=>{for(const _0x5b685c of _0x4df2f7['document']['roots'])_0x2b55b3['removeClass'](ge,_0x5b685c);});}}class u extends _0x280bdd{static get['pluginName'](){return'RevisionViewerUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[l,fi];}['init'](){const _0x24ed59=this['editor'],_0x499f30=_0x24ed59['plugins']['get'](l),_0x2d11a1=_0x24ed59['plugins']['get'](fi);_0x24ed59['ui']['componentFactory']['add']('exitToEditing',_0x5d29f7=>{const _0x293a64=new _0x14f10b(_0x5d29f7);return _0x293a64['set']({'label':R(_0x5d29f7,'Back\x20to\x20editing'),'icon':_0x45b922,'withText':!0x0,'tooltip':!0x0,'class':'ck-revision-history-ui__back-to-editing'}),this['listenTo'](_0x293a64,'execute',()=>{_0x24ed59['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}),_0x293a64;}),_0x24ed59['ui']['componentFactory']['add']('restoreRevision',_0xffc6f4=>{const _0x3b843b=new _0x14f10b(_0xffc6f4);return _0x3b843b['set']({'label':R(_0xffc6f4,'Restore\x20this\x20revision'),'withText':!0x0,'tooltip':!0x0}),_0x3b843b['bind']('isEnabled')['to'](_0x24ed59['commands']['get']('restoreRevision')),this['listenTo'](_0x3b843b,'execute',()=>_0x24ed59['execute']('restoreRevision')),_0x3b843b;}),_0x24ed59['ui']['componentFactory']['add']('changesNavigation',_0x5738b0=>{const _0xf98dcd=new pi(_0x5738b0),_0x115ad5=_0x24ed59['commands']['get']('showPreviousChange'),_0x3289b9=_0x24ed59['commands']['get']('showNextChange');return _0xf98dcd['bind']('isBackwardNavigationEnabled')['to'](_0x115ad5,'isEnabled'),_0xf98dcd['bind']('isForwardNavigationEnabled')['to'](_0x3289b9,'isEnabled'),_0xf98dcd['bind']('isReady','currentChangeNumber','numberOfChanges','isNavigationMode')['to'](_0x499f30),this['listenTo'](_0xf98dcd,'execute',(_0x89b169,_0x5552b4)=>{_0x24ed59['execute']('forward'===_0x5552b4?'showNextChange':'showPreviousChange');}),_0xf98dcd;}),_0x2d11a1['show'](),_0x499f30['on']('change:isReady',(_0x85948,_0x13795b,_0x1be843)=>{_0x1be843?_0x2d11a1['hide']():_0x2d11a1['show']();});}}class li extends ti{['_resizeObserver']=null;constructor(_0xad4d2a,_0x4bc822){super(_0xad4d2a,_0x4bc822);const _0x5e0fdf=this['bindTemplate'];this['set']({'label':R(_0xad4d2a,'Revision\x20name'),'_tooltipString':''}),this['fieldView']['placeholder']=R(_0xad4d2a,'Enter\x20the\x20revision\x20name'),this['extendTemplate']({'tag':'span','attributes':{'class':['ck-revision-history-sidebar__revision-name'],'data-cke-tooltip-text':_0x5e0fdf['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 _0x3633a7=this['fieldView']['element'];this['_tooltipString']=_0x3633a7['scrollWidth']>_0x3633a7['clientWidth']&&_0x3633a7['value']||'';}}class vi extends _0xaf2574{constructor(_0x1e07eb,_0x2c299c,_0x7d7841){super(_0x1e07eb);const _0x1d9fa5=new _0x498c78();_0x1d9fa5['set']({'content':_0x8baae7,'viewBox':'0\x200\x2011\x2010'});const _0x24943c=['ck','ck-revision-history-sidebar__revision-author'];_0x7d7841&&_0x24943c['push']('ck-revision-history-sidebar__revision-author_creator');const _0x56c70b=[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision-author__name'],'title':R(_0x1e07eb,_0x7d7841?'Revision\x20creator':'Revision\x20author')},'children':[_0x1d9fa5,_0x2c299c['name']]}];this['setTemplate']({'tag':'li','attributes':{'class':_0x24943c},'children':_0x56c70b});}}function mi(_0xb6ef2a,_0x2ec3cd){const _0x4b4a8c=_0xb6ef2a['bindTemplate'],_0x17171a=_0xb6ef2a['locale'],_0x3a398d=_0x4e60e8(_0x17171a);_0x3a398d['panelPosition']='sw';const _0x1b652f=function(_0x5ac950,_0x4be54f){const _0x2ea796=function(_0x39941b,_0x38d580){const _0x5537fe=_0x39941b['locale'],_0x85e659={'Compare\x20against\x20selected':R(_0x5537fe,'Compare\x20against\x20selected'),'Name\x20this\x20revision':R(_0x5537fe,'Name\x20this\x20revision'),'Restore\x20this\x20revision':R(_0x5537fe,'Restore\x20this\x20revision')};return _0x38d580['map'](_0x145869=>{const _0x555f1e=_0x85e659[_0x145869['name']];return _0x555f1e&&_0x555f1e!==_0x145869['name']&&(_0x145869['name']=_0x555f1e),_0x145869;});}(_0x5ac950,_0x4be54f),_0x2e767b=new _0x5b3f34();for(const _0x281f1a of _0x2ea796){const _0x17689f={'type':'button','model':new to({'label':_0x281f1a['name'],'class':_0x281f1a['class'],'withText':!0x0,'role':'menuitem','_action':_0x281f1a['action']})};_0x17689f['model']['bind']('isEnabled')['to'](_0x5ac950,'isActionsDropdownOpen',_0x152393=>'function'!=typeof _0x281f1a['isEnabled']||(!_0x152393||_0x281f1a['isEnabled'](_0x5ac950))),_0x2e767b['add'](_0x17689f);}return _0x2e767b;}(_0xb6ef2a,_0x2ec3cd);return _0xb6ef2a['bind']('isActionsDropdownOpen')['to'](_0x3a398d,'isOpen'),_0x3a398d['buttonView']['set']({'label':R(_0x17171a,'Show\x20more\x20items'),'tooltip':!0x0,'tooltipPosition':'sw','icon':_0x46aadc}),_0x3a398d['extendTemplate']({'attributes':{'class':['ck-revision-history-sidebar__revision__actions',_0x4b4a8c['if']('isActionsDropdownOpen','ck-on')]},'on':{'click':_0x4b4a8c['to'](_0x45ffb5=>_0x45ffb5['stopPropagation']())}}),_0x3a398d['on']('execute',_0x43c83b=>{_0xb6ef2a['isReady']&&'function'==typeof _0x43c83b['source']['_action']&&_0x43c83b['source']['_action'](_0xb6ef2a);}),_0x5ccf61(_0x3a398d,_0x1b652f,{'role':'menu'}),_0x3a398d['listenTo'](_0xb6ef2a,'change:isActionsDropdownOpen',(_0x375949,_0x15b566,_0x1a0ade)=>{if(_0x1a0ade)for(const _0x3a73b2 of _0x3a398d['listView']['items']){const _0x31b663=_0x3a73b2['children']['first'],_0x40eeba=_0x2ec3cd['find'](_0x2eda5c=>_0x2eda5c['action']===_0x31b663['_action'])['isVisible'];_0x3a73b2['isVisible']=void 0x0===_0x40eeba||_0x40eeba(_0xb6ef2a);}}),_0x3a398d;}class ki extends/* #__PURE__ -- @preserve */
|
|
27
|
-
|
|
23
|
+
import{ObservableMixin as _0x15d64b,uid as _0xeb3ed1,Collection as _0x2d6f70,logWarning as _0x30689d,FocusTracker as _0x1dbf64,KeystrokeHandler as _0x76073c,scrollViewportToShowTarget as _0x190ffa,ResizeObserver as ot,ElementReplacer as it,CKEditorError as _0x1aab03}from'@ckeditor/ckeditor5-utils/dist/index.js';import{cloneDeep as _0x1ba0a9,set as _0x21a6ab,unset as _0x1558ff,isEqual as _0x148e72}from'es-toolkit/compat';import{Plugin as _0x382226,PendingActions as _0x3455df,Command as _0x34dfa9,ElementApiMixin as _0x161316,Editor as _0x4558d5}from'@ckeditor/ckeditor5-core/dist/index.js';import{Users as _0x5e2d35,getMarkerDomElement as _0x150676,ConfirmMixin as _0x3b9285,sanitizeEditorConfig as _0x15a0ff}from'ckeditor5-collaboration/dist/index.js';import{ViewContainerElement as _0x53d542,ViewAttributeElement as _0x95f075,ViewEmptyElement as _0x22118c,ViewRawElement as _0x2bb2a6,ViewUIElement as _0x3698f6,ViewDocumentFragment as _0x36fe0e,ViewText as _0x39be7f,ViewElement as _0x4c8e38,ModelElement as _0x2768fe,ModelRange as _0x2651c6,ModelPosition as _0x2ecc6e,ModelDocumentFragment as _0x5ebf7b,ModelText as _0x2d98db}from'@ckeditor/ckeditor5-engine/dist/index.js';import{IconHistory as _0x179e8c,IconChevronUp as _0x143fac,IconChevronDown as _0x405e50,IconUndo as _0x31cc52,IconUser as _0x1b5193,IconThreeVerticalDots as _0x130113}from'@ckeditor/ckeditor5-icons/dist/index.js';import{CssTransitionDisablerMixin as _0x565943,View as _0x366bc3,submitHandler as _0xcc0e94,LabeledFieldView as et,createLabeledInputText as ti,createDropdown as _0x31cb79,ListView as _0x3e000b,ListItemView as _0xdbf374,ButtonView as _0x2c9755,MenuBarMenuView as _0x4b7d73,MenuBarMenuListView as _0x28aba1,MenuBarMenuListItemView as _0x46ae30,MenuBarMenuListItemButtonView as _0x53996e,ContextualBalloon as _0x466db6,ToolbarSeparatorView as _0x41d832,IconView as _0x4f1c42,addListToDropdown as _0x4e33a1,UIModel as to,EditorUI as tt,normalizeToolbarConfig as st,BoxedEditorUIView as _0x6f8624,StickyPanelView as _0x7dd8fd,ToolbarView as _0x14d8c1,InlineEditableUIView as te}from'@ckeditor/ckeditor5-ui/dist/index.js';import{DateTime as _0x33fe39}from'luxon';class I extends/* #__PURE__ -- @preserve */
|
|
24
|
+
_0x15d64b(){['id'];['creator'];['authors'];['diffData'];['toVersion'];['fromVersion'];['model'];constructor(_0x31f811){super(),this['id']=_0x31f811['id']||_0xeb3ed1(),this['creator']=_0x31f811['creator']||null,this['authors']=_0x31f811['authors']||[],this['diffData']=_0x31f811['diffData']||null,this['toVersion']=_0x31f811['toVersion']||0x0,this['fromVersion']=_0x31f811['fromVersion']||0x0,this['set']('name',_0x31f811['name']||''),this['set']('createdAt',_0x31f811['createdAt']||new Date()),this['set']('attributes',_0x31f811['attributes']||{});}['setName'](_0x4e51a6){this['_update']({'name':_0x4e51a6});}['setAttribute'](_0x3a21cd,_0x39b762){const _0x4d8bc5=_0x1ba0a9(this['attributes']);_0x21a6ab(_0x4d8bc5,_0x3a21cd,_0x39b762),this['_update']({'attributes':_0x4d8bc5});}['removeAttribute'](_0x37e999){const _0x26af0c=_0x1ba0a9(this['attributes']);_0x1558ff(_0x26af0c,_0x37e999),this['_update']({'attributes':_0x26af0c});}['_update'](_0x1f4d67,_0x4bc9dc=!0x1){let _0x1c5d6b=!0x1;const _0x279c54={'id':this['id']},_0x1d00d9=['name','createdAt','diffData','authors','attributes','toVersion','fromVersion','creatorId'];for(const _0x189a67 of _0x1d00d9){const _0x3292cf=_0x1f4d67[_0x189a67];void 0x0!==_0x3292cf&&_0x3292cf!==this[_0x189a67]&&(this[_0x189a67]=_0x3292cf,_0x279c54[_0x189a67]=_0x3292cf,_0x1c5d6b=!0x0);}_0x1c5d6b&&(_0x279c54['authors']&&(_0x279c54['authorsIds']=_0x279c54['authors']['map'](_0x38c8fe=>_0x38c8fe['id']),delete _0x279c54['authors']),this['fire']('_update',_0x279c54,_0x4bc9dc));}['toJSON'](){return{'id':this['id'],'name':this['name'],'creatorId':this['creator']?this['creator']['id']:null,'authorsIds':this['authors']['map'](_0xc0469f=>_0xc0469f['id']),'diffData':this['diffData'],'createdAt':this['createdAt'],'attributes':this['attributes'],'fromVersion':this['fromVersion'],'toVersion':this['toVersion']};}}class S extends _0x382226{['_revisions'];static get['requires'](){return[_0x5e2d35];}static get['pluginName'](){return'RevisionsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['length'](){return this['_revisions']['length'];}constructor(_0xb9dcac){super(_0xb9dcac),this['_revisions']=new _0x2d6f70();}['afterInit'](){!async function(_0x578088){const _0x23919b=_0x1803e3([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]),_0x1f4bdd=0xeb829,_0x92b202=0x7374585f,_0x3b5818=0x73732c3f^_0x92b202,_0x2f2f1e=window[_0x1803e3([0x44,0x61,0x74,0x65])][_0x1803e3([0x6e,0x6f,0x77])](),_0x16f29e=_0x578088[_0x1803e3([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x38526d=new window[(_0x1803e3([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x49acfe=>{_0x16f29e[_0x1803e3([0x6f,0x6e,0x63,0x65])](_0x1803e3([0x72,0x65,0x61,0x64,0x79]),_0x49acfe);}),_0x171c8c={[_0x1803e3([0x6b,0x74,0x79])]:_0x1803e3([0x45,0x43]),[_0x1803e3([0x75,0x73,0x65])]:_0x1803e3([0x73,0x69,0x67]),[_0x1803e3([0x63,0x72,0x76])]:_0x1803e3([0x50,0x2d,0x32,0x35,0x36]),[_0x1803e3([0x78])]:_0x1803e3([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]),[_0x1803e3([0x79])]:_0x1803e3([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]),[_0x1803e3([0x61,0x6c,0x67])]:_0x1803e3([0x45,0x53,0x32,0x35,0x36])},_0x383d0b=_0x16f29e[_0x1803e3([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x1803e3([0x67,0x65,0x74])](_0x1803e3([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x11c2e1(){let _0x2563bd,_0x2f8373=null,_0x1abe25=null;try{if(_0x383d0b==_0x1803e3([0x47,0x50,0x4c]))return _0x1803e3([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x2563bd=_0x1429c8(),!_0x2563bd)return _0x1803e3([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x2563bd[_0x1803e3([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x1abe25=_0x48c7b8(_0x2563bd[_0x1803e3([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x2563bd[_0x1803e3([0x6a,0x74,0x69])])),await _0x2cf2c3()?_0x1ae50a()?_0x17fb35()?_0x1803e3([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x19dec2()?(_0x2563bd[_0x1803e3([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x1803e3([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x2f8373=_0x410260(_0x1803e3([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x2563bd[_0x1803e3([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x1803e3([0x74,0x72,0x69,0x61,0x6c])&&(_0x2f8373=_0x410260(_0x1803e3([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),await _0x5a6332()):_0x1803e3([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x1803e3([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x1803e3([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch{return _0x1803e3([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x17fb35(){const _0x5acb4d=[_0x1803e3([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x1803e3([0x74,0x72,0x69,0x61,0x6c])][_0x1803e3([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x2563bd[_0x1803e3([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x2f2f1e/0x3e8:0xe10*_0x3b5818;return _0x2563bd[_0x1803e3([0x65,0x78,0x70])]<_0x5acb4d;}function _0x1ae50a(){const _0x431c6a=_0x2563bd[_0x1803e3([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x431c6a)return!0x1;if(_0x431c6a[_0x1803e3([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x1803e3([0x2a])))return!0x0;if(_0x431c6a[_0x1803e3([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x1803e3([0x52,0x48])))return!0x0;if(_0x431c6a[_0x1803e3([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x1803e3([0x52,0x52,0x48]))){if(_0x41e6d0())return!0x0;if(_0x5d26a4()||_0x168560())return!0x0;}return!0x1;}function _0x19dec2(){const _0x30dff4=_0x2563bd[_0x1803e3([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x30dff4||0x0==_0x30dff4[_0x1803e3([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0xfd20bd}=new URL(window[_0x1803e3([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x30dff4[_0x1803e3([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0xfd20bd))return!0x0;const _0x5c987f=_0xfd20bd[_0x1803e3([0x73,0x70,0x6c,0x69,0x74])](_0x1803e3([0x2e]));return _0x30dff4[_0x1803e3([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x144e45=>_0x144e45[_0x1803e3([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x1803e3([0x2a])))[_0x1803e3([0x6d,0x61,0x70])](_0x35ec56=>_0x35ec56[_0x1803e3([0x73,0x70,0x6c,0x69,0x74])](_0x1803e3([0x2e])))[_0x1803e3([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x4b96c3=>_0x4b96c3[_0x1803e3([0x6c,0x65,0x6e,0x67,0x74,0x68])]<=_0x5c987f[_0x1803e3([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x1803e3([0x6d,0x61,0x70])](_0x5b2cbd=>Array(_0x5c987f[_0x1803e3([0x6c,0x65,0x6e,0x67,0x74,0x68])]-_0x5b2cbd[_0x1803e3([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x1803e3([0x66,0x69,0x6c,0x6c])](_0x5b2cbd[0x0]===_0x1803e3([0x2a])?_0x1803e3([0x2a]):'')[_0x1803e3([0x63,0x6f,0x6e,0x63,0x61,0x74])](_0x5b2cbd))[_0x1803e3([0x73,0x6f,0x6d,0x65])](_0x3793cb=>_0x5c987f[_0x1803e3([0x65,0x76,0x65,0x72,0x79])]((_0x2c3037,_0x52e64f)=>_0x3793cb[_0x52e64f]===_0x2c3037||_0x3793cb[_0x52e64f]===_0x1803e3([0x2a])));}function _0x5a6332(){return _0x2f8373&&_0x1abe25?new window[(_0x1803e3([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x2780c3,_0x17669e)=>{_0x2f8373[_0x1803e3([0x74,0x68,0x65,0x6e])](_0x2780c3,_0x17669e),_0x1abe25[_0x1803e3([0x74,0x68,0x65,0x6e])](_0x5c0c29=>{_0x5c0c29!=_0x1803e3([0x56,0x61,0x6c,0x69,0x64])&&_0x2780c3(_0x5c0c29);},_0x17669e);}):_0x2f8373||_0x1abe25||_0x1803e3([0x56,0x61,0x6c,0x69,0x64]);}}function _0x48c7b8(_0x6ee9a1,_0x289085){return new window[(_0x1803e3([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x5e052b=>{if(_0x22b4e6())return _0x5e052b(_0x1803e3([0x56,0x61,0x6c,0x69,0x64]));_0x292239(),_0x16f29e[_0x1803e3([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x1803e3([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x383c94=!0x1;const _0x52ed5b=_0xeb3ed1();function _0x888912(_0x5cdfa9){return!!_0x5cdfa9&&(typeof _0x5cdfa9===_0x1803e3([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x5cdfa9===_0x1803e3([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x5cdfa9[_0x1803e3([0x74,0x68,0x65,0x6e])]===_0x1803e3([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x5cdfa9[_0x1803e3([0x63,0x61,0x74,0x63,0x68])]===_0x1803e3([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x4fd8fa(_0x5af200){_0x11a4bc(_0x5af200)[_0x1803e3([0x74,0x68,0x65,0x6e])](_0x57fa6b=>{if(!_0x57fa6b||_0x57fa6b[_0x1803e3([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x1803e3([0x6f,0x6b]))return _0x1803e3([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x8338d0(_0x4c6cba(_0x52ed5b+_0x289085))!=_0x57fa6b[_0x1803e3([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x1803e3([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x1803e3([0x56,0x61,0x6c,0x69,0x64]);})[_0x1803e3([0x74,0x68,0x65,0x6e])](_0x5bbc0b=>(_0x1aff06(),_0x5bbc0b),()=>{const _0x353832=_0x4ce1e0();return null==_0x353832?(_0x1aff06(),_0x1803e3([0x56,0x61,0x6c,0x69,0x64])):_0x1803e3(_0x2f2f1e-_0x353832>(0x5778dc5f^_0x92b202)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x1803e3([0x74,0x68,0x65,0x6e])](_0x5e052b)[_0x1803e3([0x63,0x61,0x74,0x63,0x68])](()=>{_0x5e052b(_0x1803e3([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x21f03d=0x7342b6df^_0x92b202;function _0x1aff06(){const _0x3c940e=_0x1803e3([0x6c,0x6c,0x63,0x74,0x2d])+_0x8338d0(_0x4c6cba(_0x6ee9a1)),_0x167dc7=_0x28c533(_0x8338d0(window[_0x1803e3([0x4d,0x61,0x74,0x68])][_0x1803e3([0x63,0x65,0x69,0x6c])](_0x2f2f1e/_0x21f03d)));window[_0x1803e3([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x1803e3([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x3c940e,_0x167dc7);}function _0x4ce1e0(){const _0x3e3e6b=_0x1803e3([0x6c,0x6c,0x63,0x74,0x2d])+_0x8338d0(_0x4c6cba(_0x6ee9a1)),_0x546298=window[_0x1803e3([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x1803e3([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x3e3e6b);return _0x546298?window[_0x1803e3([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x28c533(_0x546298),0x10)*_0x21f03d:null;}function _0x11a4bc(_0x9ca7a0){return new window[(_0x1803e3([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x305544,_0x333b28)=>{_0x9ca7a0[_0x1803e3([0x74,0x68,0x65,0x6e])](_0x305544,_0x333b28),window[_0x1803e3([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x333b28,0x73758c9f^_0x92b202);});}}_0x16f29e[_0x1803e3([0x6f,0x6e])](_0x1803e3([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x2e5fab,_0x5eeb2b)=>{if(_0x5eeb2b[0x0]!=_0x6ee9a1)return _0x5e052b(_0x1803e3([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x5eeb2b[0x1]={..._0x5eeb2b[0x1],[_0x1803e3([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x52ed5b};},{[_0x1803e3([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x1803e3([0x68,0x69,0x67,0x68])}),_0x16f29e[_0x1803e3([0x6f,0x6e])](_0x1803e3([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x594c40=>{_0x888912(_0x594c40[_0x1803e3([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x383c94=!0x0,_0x4fd8fa(_0x594c40[_0x1803e3([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x1803e3([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x1803e3([0x6c,0x6f,0x77])}),_0x38526d[_0x1803e3([0x74,0x68,0x65,0x6e])](()=>{_0x383c94||_0x5e052b(_0x1803e3([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x22b4e6(){return _0x16f29e[_0x1803e3([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x1803e3([0x76,0x69,0x65,0x77])][_0x1803e3([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x1803e3([0x61,0x75,0x74,0x6f]);}function _0x292239(){_0x16f29e[_0x1803e3([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x1803e3([0x76,0x69,0x65,0x77])][_0x1803e3([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x1803e3([0x61,0x75,0x74,0x6f]);}}function _0x410260(_0x53021e){const _0x3e7a1d=[new window[(_0x1803e3([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x23f880=>setTimeout(_0x23f880,0x737d6693^_0x92b202)),_0x38526d[_0x1803e3([0x74,0x68,0x65,0x6e])](()=>new window[(_0x1803e3([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x445dbc=>{const _0xfe6c67=0x73745858^_0x92b202,_0x3e14f7=_0x578088[_0x1803e3([0x5f,0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x73])];function _0x59454a(){_0x3e14f7[_0x1803e3([0x6c,0x65,0x6e,0x67,0x74,0x68])]>=_0xfe6c67&&_0x445dbc();}_0x59454a(),_0x3e14f7[_0x1803e3([0x6f,0x6e])](_0x1803e3([0x61,0x64,0x64]),_0x59454a);})),new window[(_0x1803e3([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x26091a=>{function _0xc23fe0(){for(const _0x372ed9 in window)if(window[_0x1803e3([0x4e,0x75,0x6d,0x62,0x65,0x72])]['isNaN'](window[_0x1803e3([0x4e,0x75,0x6d,0x62,0x65,0x72])](_0x372ed9))&&window[_0x372ed9]==_0x1f4bdd)return _0x26091a();_0x16f29e[_0x1803e3([0x73,0x74,0x61,0x74,0x65])]!=_0x1803e3([0x64,0x65,0x73,0x74,0x72,0x6f,0x79,0x65,0x64])&&window[_0x1803e3([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0xc23fe0,0x73744bd7^_0x92b202);}_0x506ddb(_0x1803e3([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))&&_0xc23fe0();})];return window[_0x1803e3([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x1803e3([0x72,0x61,0x63,0x65])](_0x3e7a1d)[_0x1803e3([0x74,0x68,0x65,0x6e])](()=>_0x53021e);}async function _0x138ad2(){if(await _0x38526d,_0x506ddb(_0x1803e3([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))){const _0x5c049c=_0x578088[_0x1803e3([0x67,0x65,0x74,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](0x0),_0x161eed=_0x578088[_0x1803e3([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])](_0x5c049c[_0x1803e3([0x69,0x64])]),_0x2f0fe3=_0x28e527(_0x1803e3([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]));return await _0x2f0fe3[_0x1803e3([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])](_0x5c049c['id'],_0x161eed?_0x161eed['id']:null,!0x0),_0x2f0fe3[_0x1803e3([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x1803e3([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x2f0fe3[_0x1803e3([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x2f0fe3[_0x1803e3([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])]=_0x1a7be7,void(_0x2f0fe3[_0x1803e3([0x5f,0x67,0x65,0x74,0x44,0x69,0x66,0x66])]=_0x1a7be7);}if(_0x506ddb(_0x1803e3([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]))){const _0x516f34=_0x28e527(_0x1803e3([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]));_0x516f34[_0x1803e3([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x1803e3([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x516f34[_0x1803e3([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x516f34[_0x1803e3([0x75,0x70,0x64,0x61,0x74,0x65])]=_0x1a7be7,_0x516f34[_0x1803e3([0x73,0x61,0x76,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])]=_0x1a7be7;}_0x16f29e[_0x1803e3([0x6d,0x6f,0x64,0x65,0x6c])][_0x1803e3([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x1a7be7,_0x16f29e[_0x1803e3([0x6d,0x6f,0x64,0x65,0x6c])][_0x1803e3([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x1a7be7,_0x16f29e[_0x1803e3([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x1803e3([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x41e6d0(){return _0x506ddb(_0x1803e3([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x28e527(_0x1803e3([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x1803e3([0x73,0x74,0x61,0x74,0x65])]==_0x1803e3([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x5d26a4(){return _0x506ddb(_0x1803e3([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 _0x168560(){return _0x506ddb(_0x1803e3([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0x88ce6d(_0x4d5121){const _0x365cc4=_0x443861();_0x16f29e[_0x365cc4]=_0x1803e3([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])+_0x4d5121,_0x4d5121[_0x1803e3([0x65,0x6e,0x64,0x73,0x57,0x69,0x74,0x68])](_0x1803e3([0x4c,0x69,0x6d,0x69,0x74]))&&(window[_0x443861()]=_0x1f4bdd),_0x4d5121!=_0x1803e3([0x56,0x61,0x6c,0x69,0x64])&&_0x138ad2();}function _0x443861(){const _0x30b477=window[_0x1803e3([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x1803e3([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x1803e3([0x6e,0x6f,0x77])]())[_0x1803e3([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x1803e3([0x2e]),'');let _0x2370d4=_0x1803e3([0x73]);for(let _0x1e798a=0x0;_0x1e798a<_0x30b477[_0x1803e3([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x1e798a+=0x2){let _0x3fe993=window[_0x1803e3([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x30b477[_0x1803e3([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x1e798a,_0x1e798a+0x2));_0x3fe993>=_0x23919b[_0x1803e3([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x3fe993-=_0x23919b[_0x1803e3([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x2370d4+=_0x23919b[_0x3fe993];}return _0x2370d4;}function _0x1429c8(){const _0x13d16e=_0x383d0b[_0x1803e3([0x73,0x70,0x6c,0x69,0x74])](_0x1803e3([0x2e]));if(0x3!=_0x13d16e[_0x1803e3([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0xc6661b(_0x13d16e[0x1]);function _0xc6661b(_0x2f5011){const _0x29a1e2=_0x3ead33(_0x2f5011);return _0x29a1e2&&_0x285de0()?_0x29a1e2:null;function _0x285de0(){const _0x56057b=_0x29a1e2[_0x1803e3([0x6a,0x74,0x69])],_0x19e3b5=window[_0x1803e3([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x56057b[_0x1803e3([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x56057b[_0x1803e3([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x4a1cfa={..._0x29a1e2,[_0x1803e3([0x6a,0x74,0x69])]:_0x56057b[_0x1803e3([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x56057b[_0x1803e3([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x4a1cfa[_0x1803e3([0x76,0x63])],_0x4c6cba(_0x4a1cfa)==_0x19e3b5;}}}async function _0x2cf2c3(){let _0x220729=!0x0;try{const _0xa5355c=_0x383d0b[_0x1803e3([0x73,0x70,0x6c,0x69,0x74])](_0x1803e3([0x2e])),[_0x2577b7,_0x19dc6c,_0x36adcc]=_0xa5355c;return _0x33a2f5(_0x2577b7),await _0x5cc36d(_0x2577b7,_0x19dc6c,_0x36adcc),_0x220729;}catch{return!0x1;}function _0x33a2f5(_0x56741d){const _0x10f7de=_0x3ead33(_0x56741d);_0x10f7de&&_0x10f7de[_0x1803e3([0x61,0x6c,0x67])]==_0x1803e3([0x45,0x53,0x32,0x35,0x36])||(_0x220729=!0x1);}async function _0x5cc36d(_0x4dcb53,_0x3037d4,_0x1812ef){const _0x343dd8=window[_0x1803e3([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x1803e3([0x66,0x72,0x6f,0x6d])](_0x5e52ef(_0x1812ef),_0x210279=>_0x210279[_0x1803e3([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x43b0ed=new window[(_0x1803e3([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x1803e3([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x4dcb53+_0x1803e3([0x2e])+_0x3037d4),_0x358d1f=window[_0x1803e3([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x1803e3([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x358d1f)return;const _0x5cecf6=await _0x358d1f[_0x1803e3([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x1803e3([0x6a,0x77,0x6b]),_0x171c8c,{[_0x1803e3([0x6e,0x61,0x6d,0x65])]:_0x1803e3([0x45,0x43,0x44,0x53,0x41]),[_0x1803e3([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x1803e3([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x1803e3([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x358d1f[_0x1803e3([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x1803e3([0x6e,0x61,0x6d,0x65])]:_0x1803e3([0x45,0x43,0x44,0x53,0x41]),[_0x1803e3([0x68,0x61,0x73,0x68])]:{[_0x1803e3([0x6e,0x61,0x6d,0x65])]:_0x1803e3([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x5cecf6,_0x343dd8,_0x43b0ed)||(_0x220729=!0x1);}}function _0x3ead33(_0x3a4c5d){return _0x3a4c5d[_0x1803e3([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x1803e3([0x65,0x79]))?JSON[_0x1803e3([0x70,0x61,0x72,0x73,0x65])](_0x5e52ef(_0x3a4c5d)):null;}function _0x5e52ef(_0x5029d4){return window[_0x1803e3([0x61,0x74,0x6f,0x62])](_0x5029d4[_0x1803e3([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x1803e3([0x2b]))[_0x1803e3([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x1803e3([0x2f])));}function _0x4c6cba(_0x506592){let _0x3213ab=0x1505;function _0x4c0003(_0x26e698){for(let _0x21f588=0x0;_0x21f588<_0x26e698[_0x1803e3([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x21f588++){const _0x38301a=_0x26e698[_0x1803e3([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x21f588);_0x3213ab=(_0x3213ab<<0x5)+_0x3213ab+_0x38301a,_0x3213ab&=_0x3213ab;}}function _0x30c3a1(_0x3b13c4){Array[_0x1803e3([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x3b13c4)?_0x3b13c4[_0x1803e3([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x30c3a1):_0x3b13c4&&typeof _0x3b13c4==_0x1803e3([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x1803e3([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x3b13c4)[_0x1803e3([0x73,0x6f,0x72,0x74])]()[_0x1803e3([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x3a2ecb,_0x398ab8])=>{_0x4c0003(_0x3a2ecb),_0x30c3a1(_0x398ab8);}):_0x4c0003(window[_0x1803e3([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x3b13c4));}return _0x30c3a1(_0x506592),_0x3213ab>>>0x0;}function _0x8338d0(_0x1cb3dd){return _0x1cb3dd[_0x1803e3([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x1803e3([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x1803e3([0x30]));}function _0x28c533(_0x3d2e1c){return _0x3d2e1c[_0x1803e3([0x73,0x70,0x6c,0x69,0x74])]('')[_0x1803e3([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x1803e3([0x6a,0x6f,0x69,0x6e])]('');}function _0x506ddb(_0x4c11a7){return _0x16f29e[_0x1803e3([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x1803e3([0x68,0x61,0x73])](_0x4c11a7);}function _0x28e527(_0x5032c7){return _0x16f29e[_0x1803e3([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x1803e3([0x67,0x65,0x74])](_0x5032c7);}function _0x1a7be7(){}function _0x1803e3(_0x137a14){return _0x137a14['map'](_0x2682fa=>String['fromCharCode'](_0x2682fa))['join']('');}_0x88ce6d(await _0x11c2e1());}(this);}['createRevision'](_0x12fe5b){const _0x2a8911=this['editor']['plugins']['get']('Users');return new I({'id':_0x12fe5b['id'],'name':_0x12fe5b['name'],'creator':_0x12fe5b['creatorId']?_0x2a8911['getUser'](_0x12fe5b['creatorId']):null,'diffData':_0x12fe5b['diffData']||_0x12fe5b['data'],'authors':_0x12fe5b['authorsIds']['map'](_0x3b61f4=>_0x2a8911['getUser'](_0x3b61f4)),'createdAt':new Date(_0x12fe5b['createdAt']),'attributes':_0x12fe5b['attributes'],'fromVersion':_0x12fe5b['fromVersion'],'toVersion':_0x12fe5b['toVersion']});}['addRevision'](_0x694019,_0x4621c=0x0){this['_revisions']['add'](_0x694019,_0x4621c);}['getRevision'](_0x276625){return this['_revisions']['get'](_0x276625);}['getRevisions'](_0x4c3fc5={'toJSON':!0x1}){const _0x366623=Array['from'](this['_revisions']);return _0x366623['reverse'](),_0x4c3fc5['toJSON']?_0x366623['map'](_0xb61ee1=>_0xb61ee1['toJSON']()):_0x366623;}['getIndex'](_0x178fcf){return this['_revisions']['getIndex'](_0x178fcf);}['getEarlierVisibleRevision'](_0x1690b2){const [,_0x501dba]=this['getRevisionsIterator'](_0x1690b2,{'direction':'earlier'});return _0x501dba;}['getLaterVisibleRevision'](_0x11305c){const [,_0x8ec6b1]=this['getRevisionsIterator'](_0x11305c,{'direction':'later'});return _0x8ec6b1;}['getRevisionsInDiff'](_0x594571){const _0xb10b08=[];for(const _0x4896bd of this['getRevisionsIterator'](_0x594571['newRevisionId']))if(_0xb10b08['push'](_0x4896bd),_0x4896bd['id']===_0x594571['oldRevisionId'])break;return _0xb10b08;}*['getRevisionsIterator'](_0x4dc902,{direction:_0x1d9135='earlier',filter:_0x48837d=()=>!0x0}={}){const _0x9c892c='earlier'===_0x1d9135?0x1:-0x1;let _0x4191f0=this['_revisions']['get'](_0x4dc902),_0x5bbfc8=this['getIndex'](_0x4191f0);for(yield _0x4191f0;_0x4191f0;){if(_0x5bbfc8+=_0x9c892c,_0x4191f0=this['getRevision'](_0x5bbfc8),!_0x4191f0)return;_0x48837d(_0x4191f0)&&(yield _0x4191f0);}}}class $ extends _0x382226{static get['pluginName'](){return'RevisionHistoryUtils';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['_viewClassToTypeChar']=new Map([[_0x53d542,'c'],[_0x95f075,'a'],[_0x22118c,'e'],[_0x2bb2a6,'r'],[_0x3698f6,'u']]);['_typeCharToViewClass']=new Map([['c',_0x53d542],['a',_0x95f075],['e',_0x22118c],['r',_0x2bb2a6],['u',_0x3698f6]]);async['loadRevisionData'](_0x55760f,_0xb9fd05){if(_0x55760f['diffData']||!_0xb9fd05)return;const _0x1740b7=this['editor']['config']['get']('collaboration.channelId'),_0x43a96f=await _0xb9fd05['getRevision']({'channelId':_0x1740b7,'revisionId':_0x55760f['id']});_0x55760f['diffData']=_0x43a96f['diffData'];}['getRevisionDocumentData'](_0x2a8bd0){const _0x2b34ed={};for(const _0x4c379c in _0x2a8bd0['diffData']){if(_0x2a8bd0['diffData'][_0x4c379c]['attachChange']&&!_0x2a8bd0['diffData'][_0x4c379c]['attachChange']['isAttached'])continue;const _0x1862c3=this['_removeRevisionMarkers'](JSON['parse'](_0x2a8bd0['diffData'][_0x4c379c]['insertions'])),_0x3a63b8=this['editor']['editing']['view']['document'],_0x56a6ac=new _0x36fe0e(_0x3a63b8,_0x1862c3['map'](_0x207f3c=>this['_getViewFromDiffObj'](_0x207f3c,!0x1)));this['editor']['data']['processor']['useFillerType']('marked'),_0x2b34ed[_0x4c379c]=this['editor']['data']['processor']['toData'](_0x56a6ac),this['editor']['data']['processor']['useFillerType']('default');}return _0x2b34ed;}['getRevisionRootsAttributes'](_0x2c43fc){const _0x906c97={};for(const _0x4ec78d in _0x2c43fc['diffData'])_0x2c43fc['diffData'][_0x4ec78d]['attachChange']&&!_0x2c43fc['diffData'][_0x4ec78d]['attachChange']['isAttached']||(_0x906c97[_0x4ec78d]=_0x2c43fc['diffData'][_0x4ec78d]['attributesAfter']||{});return _0x906c97;}['_getTypeCharForViewElement'](_0x5b6fa0){return this['_viewClassToTypeChar']['get'](_0x5b6fa0['constructor']);}['_getViewFromDiffObj'](_0x5d1b81,_0x4ecc6c){const _0x126c09=this['editor']['editing']['view']['document'];if('string'==typeof _0x5d1b81)return new _0x39be7f(_0x126c09,_0x5d1b81);{let _0x2ac119,_0x14dbf8;_0x14dbf8='u'==_0x5d1b81['type']||'r'==_0x5d1b81['type']?[]:_0x5d1b81['children']['map'](_0x3d6af8=>this['_getViewFromDiffObj'](_0x3d6af8,_0x4ecc6c));const _0x375cd1=this['_typeCharToViewClass']['get'](_0x5d1b81['type'])||_0x4c8e38,_0x24b45a=this['editor']['data']['htmlProcessor']['domConverter'];if(_0x2ac119=new _0x375cd1(_0x126c09,_0x5d1b81['name'],_0x5d1b81['attributes'],_0x14dbf8),'u'==_0x5d1b81['type']&&_0x5d1b81['children'][0x0]){const _0x575519=_0x5d1b81['children'][0x0];if(_0x2ac119['render']=function(_0xec3e96){const _0x1b180e=_0xec3e96['createElement']('div');return _0x1b180e['innerHTML']=_0x575519,_0x1b180e['childNodes'][0x0];},_0x4ecc6c){const _0x2abc17=new _0x36fe0e(_0x126c09);_0x2abc17['_appendChild'](_0x2ac119);const _0x1542e5=Array['from'](_0x24b45a['viewChildrenToDom'](_0x2abc17,{'bind':!0x1})),_0x5034af=_0x24b45a['domDocument']['createElement']('div');_0x5034af['append'](..._0x1542e5),_0x2ac119=Array['from'](_0x24b45a['domChildrenToView'](_0x5034af))[0x0];}}else{if('r'==_0x5d1b81['type']&&_0x5d1b81['children'][0x0]){const _0x49abe0=_0x5d1b81['children'][0x0];if(_0x2ac119['render']=function(_0x80903b){_0x80903b['innerHTML']=_0x49abe0;},_0x4ecc6c){const _0x48b6ed=new _0x36fe0e(_0x126c09);_0x48b6ed['_appendChild'](_0x2ac119);const _0x276f95=Array['from'](_0x24b45a['viewChildrenToDom'](_0x48b6ed,{'bind':!0x1})),_0x4c4c18=_0x24b45a['domDocument']['createElement']('div');_0x4c4c18['append'](..._0x276f95);const _0x8cef8b=Array['from'](_0x24b45a['domChildrenToView'](_0x4c4c18));_0x8cef8b['length']>0x1?_0x2ac119['_appendChild'](_0x8cef8b):_0x2ac119=_0x8cef8b[0x0];}}}if(_0x5d1b81['customProperties']){for(const [_0x1988bd,_0xb950cf]of _0x5d1b81['customProperties'])_0x2ac119['_setCustomProperty'](_0x1988bd,_0xb950cf);}const _0x45fec6=void 0x0===_0x5d1b81['fillerOffset']?null:_0x5d1b81['fillerOffset'];return null!==_0x45fec6&&(_0x2ac119['getFillerOffset']=()=>_0x45fec6),_0x2ac119;}}['_makeModelFromViewString'](_0x27e803){const _0x4e22dd=JSON['parse'](_0x27e803),_0x4d412d=this['editor']['editing']['view']['document'],_0x12b440=new _0x36fe0e(_0x4d412d,_0x4e22dd['map'](_0x13e1b6=>this['_getViewFromDiffObj'](_0x13e1b6,!0x0)));return this['editor']['data']['toModel'](_0x12b440);}['_removeRevisionMarkers'](_0x1040de){return(_0x1040de=_0x1040de['filter'](_0x1c1445=>!_0x1c1445['name']||'revision-start'!==_0x1c1445['name']&&'revision-end'!==_0x1c1445['name']))['forEach'](_0x943e57=>{'string'!=typeof _0x943e57&&(_0x943e57['children']=this['_removeRevisionMarkers'](_0x943e57['children']),_0x943e57['attributes']=_0x943e57['attributes']['filter'](_0xa013ed=>!_0xa013ed[0x0]['startsWith']('data-revision-')));}),_0x1040de;}}function R(_0x453206,_0x5bbfc0,_0x5aed11){const t=_0x453206['t'];switch(_0x5bbfc0){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'},_0x5aed11);case'X_OF_Y_CHANGES':return t({'string':'%0\x20of\x20%1','id':'X_OF_Y_CHANGES'},_0x5aed11);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 _0x382226{['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[_0x5e2d35,S,$,_0x3455df];}constructor(_0x2bac71){super(_0x2bac71),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 _0x3ade49=_0xeb3ed1();this['_source']={'history':this['editor']['model']['document']['history'],'getLatestVersion':()=>Promise['resolve'](this['editor']['model']['document']['version']),'getCurrentRevisionId':()=>_0x3ade49},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 _0x55f5a1=this['repository']['getRevision'](0x0),_0x9df161=_0x55f5a1&&null===_0x55f5a1['creator']?_0x55f5a1:null;if(this['_continueCurrentRevision']=!!_0x9df161&&this['editor']['config']['get']('revisionHistory.resumeUnsavedRevision'),this['editor']['plugins']['has']('RealTimeCollaborationClient')){const _0x5c8224=this['_source']['getCurrentRevisionId'](),_0x4809b1=this['repository']['getRevision'](_0x5c8224);if(_0x4809b1)this['_startingVersion']=_0x4809b1['fromVersion'],this['_continueCurrentRevision']=!0x1;else{const _0x59365d=this['_source']['history']['_operations']['find'](_0x4e478c=>!_0x4e478c['_isInit']),_0x25b2d9=_0x59365d?_0x59365d['baseVersion']:this['_source']['history']['version'];_0x55f5a1?(_0x55f5a1['toVersion']<_0x25b2d9&&_0x55f5a1['_update']({'toVersion':_0x25b2d9}),this['_continueCurrentRevision']?(this['_source']['getCurrentRevisionId']=()=>_0x9df161['id'],this['_startingVersion']=_0x9df161['fromVersion']):(this['_startingVersion']=_0x55f5a1['toVersion'],this['_continueCurrentRevision']=!0x1)):(this['_startingVersion']=_0x25b2d9,this['_continueCurrentRevision']=!0x1);}}else _0x9df161&&(this['editor']['model']['document']['history']['version']=Math['max'](_0x9df161['toVersion'],this['editor']['model']['document']['history']['version']),_0x9df161['fromVersion']===_0x9df161['toVersion']?(0x0!==_0x9df161['fromVersion']&&(this['_source']['getCurrentRevisionId']=()=>_0x9df161['id']),this['_continueCurrentRevision']=!0x1):this['_continueCurrentRevision']&&(this['_source']['getCurrentRevisionId']=()=>_0x9df161['id'],this['_startingVersion']=_0x9df161['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',_0x2d36f8=>!_0x2d36f8),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x14111b=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x167d44;for(const _0x3c1861 in _0x14111b){const _0xcdd2d6=_0x3c1861,_0x173b94=_0x14111b[_0xcdd2d6];if('revisionHistoryLicenseKeyValid'==_0x173b94||'revisionHistoryLicenseKeyInvalid'==_0x173b94||'revisionHistoryLicenseKeyExpired'==_0x173b94||'revisionHistoryLicenseKeyDomainLimit'==_0x173b94||'revisionHistoryLicenseKeyNotAllowed'==_0x173b94||'revisionHistoryLicenseKeyEvaluationLimit'==_0x173b94||'revisionHistoryLicenseKeyTrialLimit'==_0x173b94||'revisionHistoryLicenseKeyUsageLimit'==_0x173b94){delete _0x14111b[_0xcdd2d6],_0x167d44=_0x173b94,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'revisionHistoryLicenseKeyInvalid'==_0x167d44&&_0x14111b['_showLicenseError']('invalid'),'revisionHistoryLicenseKeyExpired'==_0x167d44&&_0x14111b['_showLicenseError']('expired'),'revisionHistoryLicenseKeyDomainLimit'==_0x167d44&&_0x14111b['_showLicenseError']('domainLimit'),'revisionHistoryLicenseKeyNotAllowed'==_0x167d44&&_0x14111b['_showLicenseError']('featureNotAllowed','RevisionHistory'),'revisionHistoryLicenseKeyEvaluationLimit'==_0x167d44&&_0x14111b['_showLicenseError']('evaluationLimit'),'revisionHistoryLicenseKeyTrialLimit'==_0x167d44&&_0x14111b['_showLicenseError']('trialLimit'),'revisionHistoryLicenseKeyUsageLimit'==_0x167d44&&_0x14111b['_showLicenseError']('usageLimit');},0x3e8);}async['afterInit'](){if(this['repository']['length']>0x0){const _0x294e24=this['repository']['getRevision'](0x0),_0x5ac584=await this['getRevisionDocumentData'](_0x294e24),_0x59e366=await this['getRevisionRootsAttributes'](_0x294e24);this['_replaceEditorDataWithRevisionData'](_0x5ac584,_0x59e366);}}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['setSource'](_0x31d3b1){this['_source']=_0x31d3b1;}async['update'](){const _0x3ad358=await this['_source']['getLatestVersion']();if(_0x3ad358>this['currentRevision']['toVersion']){await this['_loadState']();const _0x29a13f=this['buildRevisionData']({'revision':this['currentRevision'],'to':_0x3ad358});_0x29a13f['authors']=_0x29a13f['authorsIds']['map'](_0x4377e3=>this['editor']['plugins']['get']('Users')['getUser'](_0x4377e3)),this['currentRevision']['_update'](_0x29a13f);}}async['saveRevision'](_0x1ee731={},_0x8382f3=null){const _0x2415dc=[];await this['_loadState'](),this['_continueCurrentRevision']=!0x1,_0x8382f3>this['currentRevision']['toVersion']&&(_0x8382f3=null),null===_0x8382f3&&(_0x8382f3=await this['_source']['getLatestVersion']());const _0x5efd36=this['_getFromVersion'](_0x8382f3),_0x126907=this['buildRevisionData']({'from':_0x5efd36,'to':_0x8382f3});if(this['currentRevision']['toVersion']<_0x8382f3){const _0x17cd3c=this['buildRevisionData']({'revision':this['currentRevision'],'from':_0x8382f3,'to':_0x8382f3});_0x17cd3c['authors']=[],_0x17cd3c['authorsIds']=[],_0x17cd3c['id']=this['currentRevision']['id'],this['currentRevision']['_update'](_0x17cd3c,!0x0),delete _0x17cd3c['authors'],_0x2415dc['push'](_0x17cd3c);}_0x1ee731['creatorId']=this['editor']['plugins']['get']('Users')['me']['id'],_0x1ee731['name']=_0x1ee731['name']||null,_0x1ee731['id']=_0x1ee731['id']||_0xeb3ed1(),_0x1ee731={..._0x1ee731,..._0x126907};const _0x5c569b=this['addRevisionData'](_0x1ee731);_0x2415dc['push'](_0x1ee731);const _0x3c7a80=this['repository']['getIndex'](_0x5c569b);if(0x0!==_0x3c7a80){const _0x34ab48=this['repository']['getRevision'](_0x3c7a80-0x1);if(_0x34ab48['fromVersion']!==_0x8382f3){const _0x392c64=this['_revisionDataBuilder']['getData'](_0x8382f3,_0x34ab48['toVersion']),_0x1f5153={'id':_0x34ab48['id'],'diffData':_0x392c64['diffData'],'authorsIds':_0x392c64['authorsIds'],'authors':_0x392c64['authorsIds']['map'](_0x429194=>this['editor']['plugins']['get']('Users')['getUser'](_0x429194)),'fromVersion':_0x8382f3};_0x34ab48===this['currentRevision']&&(_0x1f5153['createdAt']=new Date(_0x1ee731['createdAt']['getTime']()+0xa)),_0x34ab48['_update'](_0x1f5153,!0x0),delete _0x1f5153['authors'],_0x2415dc['push'](_0x1f5153);}}if(this['adapter']){for(const _0x4b7884 of _0x2415dc)this['_bufferUpdate'](_0x4b7884['id'],_0x4b7884,!0x0);this['sendBufferedUpdates']();}return _0x5c569b;}['addRevisionData'](_0x287978){const _0x4a0b1c=this['repository']['createRevision'](_0x287978);return this['adapter']&&_0x4a0b1c['on']('_update',(_0x12f3ae,_0x351e5c,_0x303aee)=>{_0x303aee||(this['_bufferUpdate'](_0x351e5c['id'],_0x351e5c,!0x0),this['sendBufferedUpdates']());}),this['repository']['addRevision'](_0x4a0b1c,this['_findInsertionIndex'](_0x4a0b1c)),_0x4a0b1c;}async['getRevisionDocumentData'](_0x5c5caa){return await this['_utils']['loadRevisionData'](_0x5c5caa,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x5c5caa);}async['getRevisionRootsAttributes'](_0xe27096){return await this['_utils']['loadRevisionData'](_0xe27096,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0xe27096);}['sendBufferedUpdates'](){if(0x0===this['_bufferedUpdates']['size'])return;if(this['_isPendingUpdate'])return;let _0x50e9fe=Array['from'](this['_bufferedUpdates']['values']());this['_bufferedUpdates']['clear']();for(let _0x4c95a6=0x0;_0x4c95a6<_0x50e9fe['length'];_0x4c95a6++){const _0x25e77d=_0x50e9fe[_0x4c95a6];let _0x4f38a5=!0x1;for(const _0x139345 of Object['keys'](_0x25e77d))void 0x0===_0x25e77d[_0x139345]?delete _0x25e77d[_0x139345]:'id'!==_0x139345&&(_0x4f38a5=!0x0);_0x4f38a5||(_0x50e9fe[_0x4c95a6]=null);}if(_0x50e9fe=_0x50e9fe['filter'](_0x8e151a=>null!==_0x8e151a),!_0x50e9fe['length'])return;for(let _0x46e7ac=0x0;_0x46e7ac<_0x50e9fe['length'];_0x46e7ac++){const _0x36beef=_0x50e9fe[_0x46e7ac];void 0x0!==_0x36beef['fromVersion']&&void 0x0===_0x36beef['toVersion']&&(_0x36beef['toVersion']=this['repository']['getRevision'](_0x36beef['id'])['toVersion']),void 0x0!==_0x36beef['toVersion']&&void 0x0===_0x36beef['fromVersion']&&(_0x36beef['fromVersion']=this['repository']['getRevision'](_0x36beef['id'])['fromVersion']);}const _0x70a9bc=this['editor']['config']['get']('collaboration.channelId');this['_isPendingUpdate']=!0x0,this['_addPendingAction'](),this['adapter']['updateRevisions'](_0x50e9fe,_0x70a9bc)['finally'](()=>{this['_isPendingUpdate']=!0x1;})['then'](_0x21ea46=>{if(_0x21ea46){for(const _0x47852b of _0x21ea46)this['setRevisionData']({'id':_0x47852b['id'],'createdAt':_0x47852b['createdAt']});}this['_removePendingAction'](),this['sendBufferedUpdates']();});}['buildRevisionData']({revision:_0x4394d5=null,from:_0x5ede5a=null,to:_0x455587=null}){_0x5ede5a=null!==_0x5ede5a?_0x5ede5a:_0x4394d5['fromVersion'],_0x455587=null!==_0x455587?_0x455587:_0x4394d5['toVersion'];const _0x16b743=this['_revisionDataBuilder']['getData'](_0x5ede5a,_0x455587),_0x1f1d89={'diffData':_0x16b743['diffData'],'authorsIds':_0x16b743['authorsIds'],'fromVersion':_0x5ede5a,'toVersion':_0x455587};if(!_0x4394d5||_0x455587!==_0x4394d5['toVersion']){const _0x122e60=_0x455587-0x1,_0x5593ab=this['_source']['history']['getOperation'](_0x122e60);_0x1f1d89['createdAt']=_0x5593ab&&_0x5593ab['createdAt']||new Date();}if(this['_loadedStateData']&&_0x5ede5a===this['_loadedStateData']['fromVersion']){for(const _0x191f89 of this['_loadedStateData']['authors'])_0x1f1d89['authorsIds']['includes'](_0x191f89['id'])||_0x1f1d89['authorsIds']['push'](_0x191f89['id']);}return _0x1f1d89;}['_bufferUpdate'](_0x4c2a5b,_0x4cd1fd,_0x201a6f){if(this['_bufferedUpdates']['has'](_0x4c2a5b)){const _0x3bceae=this['_bufferedUpdates']['get'](_0x4c2a5b);_0x4cd1fd=_0x201a6f?{..._0x3bceae,..._0x4cd1fd}:{..._0x4cd1fd,..._0x3bceae};}this['_bufferedUpdates']['set'](_0x4c2a5b,_0x4cd1fd);}['setRevisionData'](_0x5cd86f){const _0x4774ac=this['repository']['getRevision'](_0x5cd86f['id']);if(_0x5cd86f['createdAt']&&(_0x5cd86f['createdAt']=new Date(_0x5cd86f['createdAt'])),_0x5cd86f['authorsIds']){const _0x566e80=this['editor']['plugins']['get']('Users');_0x5cd86f['authors']=_0x5cd86f['authorsIds']['map'](_0x1bb931=>_0x566e80['getUser'](_0x1bb931));}_0x4774ac['_update'](_0x5cd86f,!0x0);}['_createInitialRevision'](_0x17a25b){const _0x4290ca=this['repository']['getRevision'](this['repository']['length']-0x1);if(_0x4290ca)this['_initialRevisionId']=_0x4290ca['id'];else{const _0x5bffa2=!this['editor']['model']['document']['roots']['find'](_0x1e50bc=>this['editor']['model']['hasContent'](_0x1e50bc)),_0x510303=this['editor']['plugins']['get']('Users')['me']['id'],_0x4754e0=R(this['editor']['locale'],_0x5bffa2?'Empty\x20document':'Initial\x20revision');this['_makeRevision']({'from':_0x17a25b,'to':_0x17a25b,'id':this['_initialRevisionId'],'name':_0x4754e0,'creatorId':_0x510303});}}['_createCurrentRevision'](_0x2b252b){const _0x27bbc4=this['_source']['getCurrentRevisionId']();this['currentRevision']=this['repository']['getRevision'](_0x27bbc4),this['currentRevision']||(this['currentRevision']=this['_makeRevision']({'from':_0x2b252b,'to':_0x2b252b,'id':_0x27bbc4,'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'](_0x1b6e97,_0x2166fd){let _0x20c54c=this['editor']['config']['get']('initialData'),_0x23f849=this['editor']['config']['get']('rootsAttributes');if(void 0x0===_0x20c54c){_0x20c54c={};for(const _0x2793ff of this['editor']['model']['document']['getRootNames']())_0x20c54c[_0x2793ff]='';}if('string'==typeof _0x20c54c&&(_0x20c54c={'main':_0x20c54c}),void 0x0===_0x23f849){_0x23f849={};for(const _0x19aba1 of this['editor']['model']['document']['getRootNames']())_0x23f849[_0x19aba1]={};}let _0x10c4f3=!0x1;const _0x3b51fe=Object['keys'](_0x20c54c),_0x43859f=Object['keys'](_0x1b6e97);for(const _0x1ae6c7 of _0x3b51fe){if(_0x20c54c[_0x1ae6c7]!==_0x1b6e97[_0x1ae6c7]&&''!==_0x20c54c[_0x1ae6c7]['trim']()){_0x10c4f3=!0x0;break;}if(!_0x148e72(_0x23f849[_0x1ae6c7],_0x2166fd[_0x1ae6c7])&&Object['keys'](_0x23f849[_0x1ae6c7])['length']>0x0){_0x10c4f3=!0x0;break;}}_0x10c4f3||(_0x10c4f3=_0x43859f['some'](_0x256121=>!this['editor']['model']['document']['getRoot'](_0x256121))),_0x10c4f3&&_0x30689d('editor-initial-data-replaced-with-revision-data',{'editorData':_0x20c54c,'editorRootsAttributes':_0x23f849,'revisionData':_0x1b6e97,'revisionRootsAttributes':_0x2166fd}),this['editor']['config']['set']('initialData',_0x1b6e97),this['editor']['config']['set']('rootsAttributes',_0x2166fd);}['_addPendingAction'](){if(!this['_pendingAction']){const _0x16421f=this['editor']['plugins']['get']('PendingActions');this['_pendingAction']=_0x16421f['add'](R(this['editor']['locale'],'PENDING_ACTION_REVISION_HISTORY'));}}['_removePendingAction'](){this['_pendingAction']&&(this['editor']['plugins']['get']('PendingActions')['remove'](this['_pendingAction']),this['_pendingAction']=null);}['_findInsertionIndex'](_0x131ad7){const _0x2ff40e=this['repository']['getRevisions']();_0x2ff40e['reverse']();let _0x12f728=0x0;for(;_0x12f728<_0x2ff40e['length'];){const _0x5183d1=_0x2ff40e[_0x12f728];if(_0x5183d1===this['currentRevision']){_0x12f728++;continue;}if(_0x5183d1['id']===this['_initialRevisionId'])break;const _0x2918ed=_0x131ad7['toVersion']-_0x5183d1['toVersion']||_0x131ad7['fromVersion']-_0x5183d1['fromVersion'];if(_0x2918ed>0x0)break;if(_0x2918ed<0x0)_0x12f728++;else{if(!_0x131ad7['creator']&&_0x5183d1['creator'])break;if(_0x5183d1['creator']||!_0x131ad7['creator']){if(_0x131ad7['createdAt']>_0x5183d1['createdAt'])break;_0x12f728++;}else _0x12f728++;}}return _0x12f728;}['_getFromVersion'](_0x25f453){const _0x1fa661=this['repository']['getRevisions']();_0x1fa661['reverse'](),_0x1fa661['shift']();const _0x107890=_0x1fa661['find'](_0x498752=>_0x498752['toVersion']<=_0x25f453)['toVersion'];return _0x107890<this['_startingVersion']?this['_startingVersion']:_0x107890;}['_makeRevision']({name:_0x59ea00,from:_0x359cf9,to:_0xaaa920,creatorId:_0x44bd21,id:_0x379158}){const _0x28d583=this['buildRevisionData']({'from':_0x359cf9,'to':_0xaaa920});_0x28d583['name']=_0x59ea00,_0x28d583['creatorId']=_0x44bd21,_0x28d583['id']=_0x379158;const _0x3f733a=this['addRevisionData'](_0x28d583);return this['adapter']&&this['_bufferUpdate'](_0x28d583['id'],_0x28d583,!0x0),_0x3f733a;}['_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(_0x126e92){this['editor']=_0x126e92,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'](_0x77f062){this['source']=_0x77f062;const _0x4f1f67=new Map(),_0x2f1ef5=new Map(),_0x3f4d6d=this['editor']['model']['document']['roots']['map'](_0xbd099e=>_0xbd099e['rootName']);for(const _0x44d1b5 of _0x3f4d6d){const _0xda2b89=this['editor']['model']['document']['getRoot'](_0x44d1b5),_0x1cfc08=x(_0xda2b89);_0x4f1f67['set'](_0x44d1b5,_0x1cfc08),_0x2f1ef5['set'](_0x44d1b5,Object['fromEntries'](_0xda2b89['getAttributes']()));}const _0x20e542=Array['from'](this['editor']['model']['markers'])['map'](_0x38809d=>[_0x38809d['name'],_0x38809d['getRange']()]),_0x33c340=this['source']['version'];this['_saveMetaData'](_0x33c340,_0x4f1f67,_0x20e542,_0x2f1ef5),this['_startingRevisionId']=this['_revisionId'];const _0x2a5458=new Map(),_0x181323=new Map();for(const _0x5d4438 of _0x3f4d6d){const _0x1e9aea=N(_0x5d4438);_0x2a5458['set'](_0x5d4438,_0x1e9aea),_0x181323['set'](_0x5d4438,{});}this['_saveMetaData'](Number['NEGATIVE_INFINITY'],_0x2a5458,[],_0x181323);}['getData'](_0xeae7a3,_0xd03be1){if(this['_lastFrom']===_0xeae7a3&&this['_lastTo']<=_0xd03be1)this['_savedMetaData']['size']>0x1&&this['_removeMetaData'](this['_lastTo']),this['_applyOperations'](this['_lastTo'],_0xd03be1,!0x0);else{if(!this['_savedMetaData']['has'](_0xeae7a3)){const _0x47d038=this['_getPreviousFrom'](_0xeae7a3);this['_calculateMetaData'](_0x47d038,_0xeae7a3,!0x1);}this['_calculateMetaData'](_0xeae7a3,_0xd03be1,!0x0);}return this['_lastFrom']=_0xeae7a3,this['_lastTo']=_0xd03be1,this['_getState']();}['loadState'](_0x176ab5){if(!this['_savedMetaData']['has'](_0x176ab5['fromVersion'])){const _0x242aee=this['_getPreviousFrom'](_0x176ab5['fromVersion']);this['_calculateMetaData'](_0x242aee,_0x176ab5['fromVersion'],!0x1);}this['_calculateMetaData'](_0x176ab5['fromVersion'],_0x176ab5['toVersion'],!0x1);const _0x443843=this['editor']['plugins']['get']('RevisionHistoryUtils');this['_reset'](),this['_lastFrom']=_0x176ab5['fromVersion'],this['_lastTo']=_0x176ab5['toVersion'];for(const _0x190850 in _0x176ab5['diffData']){const _0x220155=_0x176ab5['diffData'][_0x190850]['attachChange'],_0x4025c9=_0x1ba0a9(_0x176ab5['diffData'][_0x190850]['attributesBefore'])||{},_0x378b08=_0x443843['_makeModelFromViewString'](_0x176ab5['diffData'][_0x190850]['deletions']);_0x378b08['rootName']=_0x190850,_0x378b08['_isAttached']=!_0x220155||!_0x220155['isAttached'],_0x378b08['isAttached']=()=>_0x378b08['_isAttached'],this['_baseRoots']['set'](_0x190850,_0x378b08),this['_baseRootsAttributes']['set'](_0x190850,_0x4025c9),_0x220155&&this['_touchedRoots']['set'](_0x190850,_0x220155);const _0x4fd745=this['_makeIdsRoot'](_0x378b08);this['_baseIdsRoots']['set'](_0x190850,_0x4fd745);for(const [_0x5d70b1,_0x364dea]of _0x378b08['markers']){if(!_0x5d70b1['startsWith']('revision:'))continue;const _0x273191=_0x5d70b1['split'](':')[0x2];for(const _0x53a7ef of _0x364dea['getWalker']({'singleCharacters':!0x0})){const _0x5aefd3=this['_getVidAttributeName'](_0x53a7ef),_0xf47078='elementEnd'==_0x53a7ef['type']?_0x53a7ef['previousPosition']['path']['slice'](0x0,-0x1):_0x53a7ef['previousPosition']['path'],_0x261ec6=_0x4fd745['getNodeByPath'](_0xf47078)['getAttribute'](_0x5aefd3);this['_touched']['set'](_0x261ec6,{'userId':_0x273191});}}}this['_startingRevisionId']=this['_revisionId'];const _0x1970be=[...Array(this['_revisionId'])['keys']()]['slice'](0x1)['filter'](_0x209a31=>!this['_touched']['has'](_0x209a31));let _0x16e44e=0x0;const _0x354a8a=new Map();for(const _0x524e64 in _0x176ab5['diffData']){const _0x51e627=_0x176ab5['diffData'][_0x524e64]['attachChange'],_0x2fa361=_0x1ba0a9(_0x176ab5['diffData'][_0x524e64]['attributesAfter'])||{},_0x427a1a=_0x443843['_makeModelFromViewString'](_0x176ab5['diffData'][_0x524e64]['insertions']);_0x427a1a['rootName']=_0x524e64,_0x427a1a['_isAttached']=!_0x51e627||_0x51e627['isAttached'],_0x427a1a['isAttached']=()=>_0x427a1a['_isAttached'],this['_diffRoots']['set'](_0x524e64,_0x427a1a),this['_diffRootsAttributes']['set'](_0x524e64,_0x2fa361);const _0x591b7c=this['_makeIdsRoot'](_0x427a1a,Number['NEGATIVE_INFINITY']);this['_idsRoots']['set'](_0x524e64,_0x591b7c),_0x354a8a['set'](_0x524e64,_0x427a1a['isAttached']()?_0x2fa361:{});for(const [_0x93db52,_0x115c66]of _0x427a1a['markers']){if(!_0x93db52['startsWith']('revision:'))continue;const _0x5c4e77=_0x93db52['split'](':')[0x2];for(const _0x552c9b of _0x115c66['getWalker']({'singleCharacters':!0x0})){const _0x504330=this['_getVidAttributeName'](_0x552c9b),_0xc843ff=this['_revisionId']++,_0xd25ece='elementEnd'==_0x552c9b['type']?_0x552c9b['previousPosition']['path']['slice'](0x0,-0x1):_0x552c9b['previousPosition']['path'];_0x591b7c['getNodeByPath'](_0xd25ece)['_setAttribute'](_0x504330,_0xc843ff),this['_touched']['set'](_0xc843ff,{'userId':_0x5c4e77});}}for(const _0x1dadaf of this['editor']['model']['createRangeIn'](_0x427a1a)['getWalker']({'singleCharacters':!0x0})){const _0x537f81=this['_getVidAttributeName'](_0x1dadaf),_0x46a91a='elementEnd'==_0x1dadaf['type']?_0x1dadaf['previousPosition']['path']['slice'](0x0,-0x1):_0x1dadaf['previousPosition']['path'],_0x41438d=_0x591b7c['getNodeByPath'](_0x46a91a);_0x41438d['getAttribute'](_0x537f81)>0x0||_0x41438d['_setAttribute'](_0x537f81,_0x1970be[_0x16e44e++]);}for(const [_0x309d7a,_0x530ef0]of _0x427a1a['markers'])_0x309d7a['startsWith']('revision:')||this['_markers']['set'](_0x309d7a,_0x530ef0);}const {roots:_0x5a4ac2}=this['_savedMetaData']['get'](_0x176ab5['fromVersion']),{roots:_0x3bbbc0}=this['_savedMetaData']['get'](_0x176ab5['toVersion']),_0x286249=x(_0x5a4ac2['get']('$graveyard'));this['_baseRoots']['set']('$graveyard',_0x286249),this['_baseIdsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x286249,Number['NEGATIVE_INFINITY']));const _0x453e0a=x(_0x3bbbc0['get']('$graveyard'));this['_diffRoots']['set']('$graveyard',_0x453e0a),this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x453e0a));const _0x3ed3a0=Array['from'](this['_diffRoots'])['map'](([_0x585540,_0x10e1a7])=>[_0x585540,x(_0x10e1a7)]);this['_saveMetaData'](this['_lastTo'],_0x3ed3a0,this['_markers'],_0x354a8a);}['reInit'](){this['_reset'](),this['_lastFrom']=-0x1,this['_lastTo']=-0x1,this['_savedMetaData']['clear'](),this['init'](this['source']);}['_saveMetaData'](_0x5d3239,_0x5f3a00,_0x1c137f,_0x26a118){const _0x257227=new Map(_0x5f3a00),_0x2d9c43=new Map(_0x1ba0a9(_0x26a118)),_0x48a68d=new Map();for(const [_0x5522a9,_0x3e675e]of _0x1c137f)_0x48a68d['set'](_0x5522a9,{'start':_0x3e675e['start']['clone'](),'end':_0x3e675e['end']['clone'](),'rootName':_0x3e675e['root']['rootName']});this['_savedMetaData']['set'](_0x5d3239,{'roots':_0x257227,'markers':_0x48a68d,'rootsAttributes':_0x2d9c43});}['_removeMetaData'](_0x29a051){this['_savedMetaData']['delete'](_0x29a051);}['_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'](_0x2388b5,_0x53feb5=null){let _0x18f885=null;_0x2388b5['is']('documentFragment')||(_0x18f885=new _0x2768fe(_0x2388b5['name'],{'vid_start':null===_0x53feb5?this['_revisionId']++:_0x53feb5++}));const _0x42708c=[];for(const _0x4a1169 of _0x2388b5['getChildren']())if(_0x4a1169['is']('element')){_0x42708c['push'](this['_makeIdsRoot'](_0x4a1169,_0x53feb5));const _0x5d421c=_0x42708c[_0x42708c['length']-0x1];null!==_0x53feb5&&(_0x53feb5=_0x5d421c['is']('element','$text')?_0x5d421c['getAttribute']('vid')+0x1:_0x5d421c['getAttribute']('vid_end')+0x1);}else{for(let _0x863e20=0x0;_0x863e20<_0x4a1169['offsetSize'];_0x863e20++)_0x42708c['push'](new _0x2768fe('$text',{'vid':null===_0x53feb5?this['_revisionId']++:_0x53feb5++}));}if(_0x2388b5['is']('documentFragment')){const _0x341445=N(_0x2388b5['rootName']);return _0x341445['_insertChild'](0x0,_0x42708c),_0x341445;}return _0x18f885['_setAttribute']('vid_end',null===_0x53feb5?this['_revisionId']++:_0x53feb5++),_0x18f885['_insertChild'](0x0,_0x42708c),_0x18f885;}['_calculateMetaData'](_0x32e2ab,_0x293e23,_0x41ce7d){this['_reset']();const {roots:_0x193b3d,markers:_0xb666b5,rootsAttributes:_0xd1ab16}=this['_savedMetaData']['get'](_0x32e2ab);this['_baseRoots']=new Map(_0x193b3d),this['_baseRootsAttributes']=new Map(_0x1ba0a9(_0xd1ab16));for(const [_0x7757fd,_0xc37963]of this['_baseRoots'])if('$graveyard'!==_0x7757fd&&(this['_diffRoots']['set'](_0x7757fd,x(_0xc37963)),this['_diffRootsAttributes']=new Map(_0x1ba0a9(_0xd1ab16)),_0x41ce7d)){const _0x1cf176=this['_revisionId'];this['_idsRoots']['set'](_0x7757fd,this['_makeIdsRoot'](_0xc37963)),this['_baseIdsRoots']['set'](_0x7757fd,this['_makeIdsRoot'](_0xc37963,_0x1cf176));}this['_startingRevisionId']=this['_revisionId'],this['_diffRoots']['set']('$graveyard',x(this['_baseRoots']['get']('$graveyard'))),_0x41ce7d&&this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](this['_baseRoots']['get']('$graveyard')));for(const [_0x14d66d,_0x2bf300]of _0xb666b5){const _0xe26191=this['_baseRoots']['get'](_0x2bf300['rootName']),_0x388e8e=this['_diffRoots']['get'](_0x2bf300['rootName']),_0x3da6b8=new _0x2651c6(this['_fixPosition'](_0x2bf300['start'],_0xe26191),this['_fixPosition'](_0x2bf300['end'],_0xe26191)),_0x5b7294=this['_fixRange'](_0x3da6b8,_0x388e8e);_0xe26191['markers']['set'](_0x14d66d,_0x3da6b8),this['_markers']['set'](_0x14d66d,_0x5b7294);}this['_applyOperations'](_0x32e2ab,_0x293e23,_0x41ce7d);}['_applyOperations'](_0x41beb1,_0x22fd2d,_0x85e68c){for(const _0x4272a3 of this['source']['getOperations'](_0x41beb1,_0x22fd2d))this['_handleOperation'](_0x4272a3,_0x85e68c);for(const _0x4a6a3d of this['_diffRoots']['values']())_0x4a6a3d['markers']['clear']();for(const [_0x3f5490,_0x2af786]of this['_markers']){this['_diffRoots']['get'](_0x2af786['root']['rootName'])['markers']['set'](_0x3f5490,_0x2af786['clone']());}const _0x21e8c9=new Map(),_0x14e25a=new Map();for(const [_0x35abee,_0x46f236]of this['_diffRoots'])_0x21e8c9['set'](_0x35abee,x(_0x46f236)),_0x14e25a['set'](_0x35abee,this['_diffRootsAttributes']['get'](_0x35abee));this['_saveMetaData'](_0x22fd2d,_0x21e8c9,this['_markers'],_0x14e25a);}['_getPreviousFrom'](_0x5b8444){const _0x13af19=Array['from'](this['_savedMetaData']['keys']());_0x13af19['sort']((_0x4da463,_0x14fb77)=>_0x4da463-_0x14fb77),_0x13af19['reverse']();for(const _0x425d5d of _0x13af19)if(_0x425d5d<_0x5b8444)return _0x425d5d;return Number['NEGATIVE_INFINITY'];}['_copyMarkers'](_0x4524fe,_0x1dd14b){const _0x43e60a=Array['from'](_0x1dd14b['markers'])['map'](([_0xe2c1c3,_0x5d678b])=>[_0xe2c1c3,this['_fixRange'](_0x5d678b,_0x4524fe)]);_0x4524fe['markers']=new Map(_0x43e60a);}['_transformMarkers'](_0x2fe327){for(const _0x46a452 of this['_markers']['values']()){const _0x54131a=_0x46a452['getTransformedByOperation'](_0x2fe327),_0x1c2dec=_0x2651c6['_createFromRanges'](_0x54131a);_0x46a452['start']=_0x1c2dec['start'],_0x46a452['end']=_0x1c2dec['end'];}}['_handleOperation'](_0x5b7f38,_0x4838a2){if('addRoot'!=_0x5b7f38['type']&&'detachRoot'!=_0x5b7f38['type']){if('insert'==_0x5b7f38['type']){const _0x13ed99=_0x5b7f38['position']['root']['rootName'];this['_diffRoots']['has'](_0x13ed99)||(this['_diffRoots']['set'](_0x13ed99,N(_0x13ed99,!0x0)),this['_diffRootsAttributes']['set'](_0x13ed99,{}),_0x4838a2&&this['_idsRoots']['set'](_0x13ed99,N(_0x13ed99,!0x0)));}else{if('addRootAttribute'==_0x5b7f38['type']||'removeRootAttribute'==_0x5b7f38['type']||'changeRootAttribute'==_0x5b7f38['type'])return void this['_handleRootAttributeOperation'](_0x5b7f38);'marker'==_0x5b7f38['type']&&this['_handleMarkerOperation'](_0x5b7f38);}if('marker'!==_0x5b7f38['type']){const _0x5892ff=this['_cloneOperation'](_0x5b7f38,this['_diffRoots']);_0x5892ff['_execute'](),this['_transformMarkers'](_0x5892ff);}if(_0x4838a2)switch(_0x5b7f38['type']){case'insert':this['_handleInsertOperation'](_0x5b7f38);break;case'move':case'remove':case'reinsert':this['_handleMoveOperation'](_0x5b7f38);break;case'merge':this['_handleMergeOperation'](_0x5b7f38);break;case'split':this['_handleSplitOperation'](_0x5b7f38);}}else this['_handleRootOperation'](_0x5b7f38,_0x4838a2);}['_cloneOperation'](_0x521b8a,_0x2d10d9){const _0x1119d8=_0x521b8a['clone']();return _0x1119d8['_authorId']=_0x521b8a['_authorId'],this['_fixOperation'](_0x1119d8,_0x2d10d9),_0x1119d8;}['_getBaseVids'](_0x51de3e){return _0x51de3e['map'](_0x1ff82a=>{const _0x497bec=this['_getVidAttributeName'](_0x1ff82a);return Number(_0x1ff82a['item']['getAttribute'](_0x497bec));});}['_generateTape'](_0xe9b0df,_0x4a1fd4){if(_0xe9b0df['is']('element','$text'))_0x4a1fd4['push']({'item':_0xe9b0df,'type':'text'});else{_0xe9b0df['is']('element')&&_0x4a1fd4['push']({'item':_0xe9b0df,'type':'elementStart'});for(const _0x28b1d5 of _0xe9b0df['getChildren']())this['_generateTape'](_0x28b1d5,_0x4a1fd4);_0xe9b0df['is']('element')&&_0x4a1fd4['push']({'item':_0xe9b0df,'type':'elementEnd'});}return _0x4a1fd4;}['_getState'](){const _0x390d33=new Map(this['_touched']),_0x5d0297=new Map(_0x390d33),_0x3a8fff=new Map(),_0x4a8bdf={'insertions':{},'deletions':{}},_0x1e390a={'insertions':{},'deletions':{}},_0x229e02=new Map(),_0x43bdfe=new Set([...this['_baseRoots']['keys'](),...this['_diffRoots']['keys']()]);_0x43bdfe['delete']('$graveyard');for(const _0x48ff4a of _0x43bdfe){const _0x56dda0=this['_diffRoots']['get'](_0x48ff4a)||N(_0x48ff4a,!0x1),_0x18d6b4=this['_baseRoots']['get'](_0x48ff4a)||N(_0x48ff4a,!0x1);_0x56dda0['isAttached']()||_0x18d6b4['isAttached']()?(_0x4a8bdf['insertions'][_0x48ff4a]=x(_0x56dda0),_0x4a8bdf['deletions'][_0x48ff4a]=x(_0x18d6b4),this['_copyMarkers'](_0x4a8bdf['deletions'][_0x48ff4a],_0x18d6b4),this['_copyMarkers'](_0x4a8bdf['insertions'][_0x48ff4a],_0x56dda0),_0x1e390a['insertions'][_0x48ff4a]=this['_generateTape'](this['_idsRoots']['get'](_0x48ff4a),[]),_0x1e390a['deletions'][_0x48ff4a]=this['_generateTape'](this['_baseIdsRoots']['get'](_0x48ff4a)||N(_0x48ff4a,!0x1),[])):_0x43bdfe['delete'](_0x48ff4a);}for(const _0x12159e of _0x43bdfe){const _0xebba85=_0x1e390a['insertions'][_0x12159e];for(const _0x78d88e of _0xebba85){const _0x2d8b78=this['_getVidAttributeName'](_0x78d88e),_0x2cd187=_0x78d88e['item']['getAttribute'](_0x2d8b78);_0x5d0297['delete'](_0x2cd187),_0x2cd187>=this['_startingRevisionId']&&_0x3a8fff['set'](_0x2cd187,_0x390d33['get'](_0x2cd187));}}for(const _0xfb2f95 of _0x43bdfe){const _0x304870=_0x1e390a['insertions'][_0xfb2f95],_0x7849c8=this['_getBaseVids'](_0x1e390a['deletions'][_0xfb2f95]);let _0x3bb47f=0x0;for(const _0x588530 of _0x304870){const _0x25a682=this['_getVidAttributeName'](_0x588530),_0x257720=_0x588530['item']['getAttribute'](_0x25a682);if(!_0x3a8fff['has'](_0x257720)&&!_0x229e02['has'](_0x257720)){if(_0x5d0297['has'](_0x257720))_0x3bb47f++;else{if(_0x257720!=_0x7849c8[_0x3bb47f]){const _0x2d1151=_0x390d33['get'](_0x257720)||_0x390d33['get'](_0x7849c8[_0x3bb47f]);for(;_0x257720!=_0x7849c8[_0x3bb47f];)_0x5d0297['has'](_0x7849c8[_0x3bb47f])||(_0x229e02['set'](_0x7849c8[_0x3bb47f],_0x2d1151),_0x390d33['set'](_0x7849c8[_0x3bb47f],_0x2d1151)),_0x3bb47f++;}_0x3bb47f++;}}}}for(const _0x516281 of _0x43bdfe){const _0x59495f=_0x1e390a['insertions'][_0x516281];for(const _0x5e49f0 of _0x59495f){const _0x2f964b=this['_getVidAttributeName'](_0x5e49f0),_0xca484a=_0x5e49f0['item']['getAttribute'](_0x2f964b);if(_0x229e02['has'](_0xca484a)){const _0x4c9318=_0x229e02['get'](_0xca484a);_0x5d0297['has'](_0xca484a)||_0x5d0297['set'](_0xca484a,{..._0x4c9318}),_0x3a8fff['set'](_0xca484a,{..._0x4c9318});}}}for(const _0x420daa of _0x5d0297['keys']())_0x420daa>=this['_startingRevisionId']&&_0x5d0297['delete'](_0x420daa);const _0x13dc20=new Map();for(const _0x9f4530 of _0x43bdfe){let _0x325f15=_0x1e390a['insertions'][_0x9f4530];for(const _0x4fc765 of _0x325f15)if(_0x4fc765['item']['is']('element','tableCell')){const _0x5b5c17=this['_getVidAttributeName'](_0x4fc765),_0x395dcc=_0x4fc765['item']['getAttribute'](_0x5b5c17);if(_0x3a8fff['has'](_0x395dcc)){const _0x5e47e1=_0x4fc765['item']['parent']['parent']['getAttribute']('vid_start'),_0x4dca91=_0x13dc20['get'](_0x5e47e1)||new Set();_0x4dca91['add'](_0x3a8fff['get'](_0x395dcc)['userId']),_0x13dc20['set'](_0x5e47e1,_0x4dca91);}}_0x325f15=_0x1e390a['deletions'][_0x9f4530];for(const _0x66c0a7 of _0x325f15)if(_0x66c0a7['item']['is']('element','tableCell')){const _0x4d2552=this['_getVidAttributeName'](_0x66c0a7),_0x12335b=_0x66c0a7['item']['getAttribute'](_0x4d2552);if(_0x5d0297['has'](_0x12335b)){const _0x375e5e=_0x66c0a7['item']['parent']['parent']['getAttribute']('vid_start'),_0x173544=_0x13dc20['get'](_0x375e5e)||new Set();_0x173544['add'](_0x5d0297['get'](_0x12335b)['userId']),_0x13dc20['set'](_0x375e5e,_0x173544);}}for(const _0x55c90b of _0x13dc20['keys']())(_0x3a8fff['has'](_0x55c90b)||_0x5d0297['has'](_0x55c90b))&&_0x13dc20['delete'](_0x55c90b);}for(const _0x1e92d5 of _0x43bdfe){const _0xea247d=_0x1e390a['insertions'][_0x1e92d5];let _0x10ebab=null,_0x23fc1f=null;for(const _0x14f73b of _0xea247d){const _0x4874a4=this['_getVidAttributeName'](_0x14f73b),_0x27aa13=_0x14f73b['item']['getAttribute'](_0x4874a4),_0x2bc4b7=_0x13dc20['get'](_0x27aa13);_0x2bc4b7&&'elementStart'==_0x14f73b['type']&&(_0x10ebab=Array['from'](_0x2bc4b7)[0x0],_0x23fc1f=_0x14f73b['item']['getAttribute']('vid_end')),_0x10ebab&&(_0x5d0297['set'](_0x27aa13,{'userId':_0x10ebab}),_0x3a8fff['set'](_0x27aa13,{'userId':_0x10ebab})),_0x27aa13==_0x23fc1f&&(_0x10ebab=null,_0x23fc1f=null);}}const _0x48ebfa={},_0x3ba412=new Set();for(const _0x4e0a10 of _0x43bdfe){const _0x425ef3=_0x4a8bdf['deletions'][_0x4e0a10],_0x4a00ff=_0x4a8bdf['insertions'][_0x4e0a10];for(const {userId:_0x413542}of this['_touchedMarkers']['values']())null!==_0x413542&&_0x3ba412['add'](_0x413542);for(const {userId:_0x268421}of this['_touchedRoots']['values']())null!==_0x268421&&_0x3ba412['add'](_0x268421);this['_markChanges'](_0x4a00ff,_0x1e390a['insertions'][_0x4e0a10],_0x3a8fff,'insertion',_0x3ba412),this['_markChanges'](_0x425ef3,_0x1e390a['deletions'][_0x4e0a10],_0x5d0297,'deletion',_0x3ba412),_0x48ebfa[_0x4e0a10]={'insertions':this['_prepareViewToSave'](_0x4a00ff),'deletions':this['_prepareViewToSave'](_0x425ef3),'attachChange':this['_touchedRoots']['get'](_0x4e0a10)||null,'attributesBefore':_0x1ba0a9(this['_baseRootsAttributes']['get'](_0x4e0a10))||{},'attributesAfter':_0x1ba0a9(this['_diffRootsAttributes']['get'](_0x4e0a10))};}return{'diffData':_0x48ebfa,'authorsIds':Array['from'](_0x3ba412)};}['_processRootBeforeSave'](_0x1c70fc){for(const [,_0x13167d]of _0x1c70fc['markers']){const _0x5e028e=_0x13167d['start']['getAncestors']()['filter'](_0x4f0f89=>'tableCell'==_0x4f0f89['name']);for(const _0x53090a of _0x5e028e)0x1==_0x53090a['childCount']&&_0x53090a['getChild'](0x0)['is']('element','paragraph')&&_0x53090a['getChild'](0x0)['_setAttribute']('keepParagraph',!0x0);}}['_prepareViewToSave'](_0xbc85e){this['_processRootBeforeSave'](_0xbc85e);const _0xe7afbc=this['editor']['data']['toView'](_0xbc85e,{}),_0x2ec4f7=Array['from'](_0xe7afbc['getChildren']())['map'](_0x96526a=>this['_getViewJson'](_0x96526a));return JSON['stringify'](_0x2ec4f7);}['_getViewJson'](_0x265c19){if(_0x265c19['is']('$text'))return _0x265c19['data'];{const _0x3a00dd=this['editor']['plugins']['get']('RevisionHistoryUtils'),_0x4d338c=_0x265c19,_0x48bc9b=this['editor']['data']['htmlProcessor']['domConverter'],_0x3048ca={'type':_0x3a00dd['_getTypeCharForViewElement'](_0x4d338c),'name':_0x4d338c['name'],'attributes':Array['from'](_0x4d338c['getAttributes']()),'children':Array['from'](_0x4d338c['getChildren']())['map'](_0x58a0c0=>this['_getViewJson'](_0x58a0c0))};if(_0x265c19['is']('uiElement')&&'$comment'!=_0x265c19['name']){const _0x330b01=_0x265c19['render'](_0x48bc9b['domDocument'],_0x48bc9b);_0x3048ca['children']['push'](_0x330b01['outerHTML']);}else{if(_0x265c19['is']('rawElement')){const _0x1f13d6=_0x48bc9b['domDocument']['createElement'](_0x4d338c['name']);_0x265c19['render'](_0x1f13d6,_0x48bc9b),_0x3048ca['children']['push'](_0x1f13d6['innerHTML']);}}const _0x5a7424=Array['from'](_0x4d338c['getCustomProperties']());_0x5a7424['length']>0x0&&(_0x3048ca['customProperties']=_0x5a7424);const _0x4e388b=_0x4d338c['getFillerOffset']();return null!==_0x4e388b&&(_0x3048ca['fillerOffset']=_0x4e388b),_0x3048ca;}}['_markChanges'](_0x310974,_0x48f74a,_0x582c72,_0x56b419,_0x340411){let _0xb4bfdf=null,_0x33bf49=null,_0x54f290=0x0;const _0x4dab3c=this['editor']['model'];for(let _0x564d2a=0x0;_0x564d2a<_0x48f74a['length'];_0x564d2a++){const _0x56feec=this['_getVidAttributeName'](_0x48f74a[_0x564d2a]),_0x530b81=_0x48f74a[_0x564d2a]['item']['getAttribute'](_0x56feec),_0x8fa988=_0x582c72['get'](_0x530b81),_0x5ce0d8=_0x564d2a==_0x48f74a['length']-0x1;(!_0xb4bfdf&&_0x8fa988&&(_0xb4bfdf=_0x8fa988,_0x33bf49=_0x48f74a[_0x564d2a]),_0xb4bfdf&&(!_0x8fa988||_0x8fa988['userId']!=_0xb4bfdf['userId']))&&(_0x347c38(_0x8fa988,P(_0x33bf49,_0x310974,_0x4dab3c),P(_0x48f74a[_0x564d2a],_0x310974,_0x4dab3c)),_0xb4bfdf=_0x8fa988||null,_0x33bf49=_0x8fa988?_0x48f74a[_0x564d2a]:null),_0xb4bfdf&&_0x5ce0d8&&_0x347c38(_0x8fa988,P(_0x33bf49,_0x310974,_0x4dab3c),V(_0x48f74a[_0x564d2a],_0x310974,_0x4dab3c));}function _0x347c38(_0x552cda,_0x5de601,_0x274ed9){const _0x2fd205=_0xb4bfdf['userId'],_0x31dd05='revision:'+_0x56b419+':'+_0x2fd205+':'+_0x54f290++,_0x17d598=_0x4dab3c['createRange'](_0x5de601,_0x274ed9);_0x310974['markers']['set'](_0x31dd05,_0x17d598),null!==_0x2fd205&&_0x340411['add'](_0x2fd205);}}['_getVidAttributeName'](_0x506461){switch(_0x506461['type']){case'elementStart':return'vid_start';case'elementEnd':return'vid_end';default:return'vid';}}['_fixOperation'](_0x595555,_0x40f988){_0x595555['baseVersion']=null;for(const _0x485a48 in _0x595555){const _0x5d6f6f=_0x595555[_0x485a48];if(_0x5d6f6f instanceof _0x2ecc6e){const _0xc6a418=_0x40f988['get'](_0x5d6f6f['root']['rootName']);_0x595555[_0x485a48]=this['_fixPosition'](_0x5d6f6f,_0xc6a418);}if(_0x5d6f6f instanceof _0x2651c6){const _0x1dc201=_0x40f988['get'](_0x5d6f6f['root']['rootName']);_0x595555[_0x485a48]=this['_fixRange'](_0x5d6f6f,_0x1dc201);}'root'===_0x485a48&&(_0x595555['root']=_0x40f988['get'](_0x595555['root']['rootName']));}}['_fixRange'](_0x49bab8,_0x85f6){return this['editor']['model']['createRange'](this['_fixPosition'](_0x49bab8['start'],_0x85f6),this['_fixPosition'](_0x49bab8['end'],_0x85f6));}['_fixPosition'](_0x2ea28d,_0x8dfd65){return this['editor']['model']['createPositionFromPath'](_0x8dfd65,_0x2ea28d['path'],_0x2ea28d['stickiness']);}['_handleInsertOperation'](_0xeb19c8){const _0x481de8=this['_idsRoots']['get'](_0xeb19c8['position']['root']['rootName']),_0x5d13eb=this['_fixPosition'](_0xeb19c8['position'],_0x481de8),_0x34eb1a=null===_0xeb19c8['_authorId']?null:_0xeb19c8['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x45a334=_0x5d13eb['parent'],_0x2f33c1=this['_revisionId'],_0x3335f2=[];for(const _0x3956a2 of _0xeb19c8['nodes'])if(_0x3956a2['is']('element'))_0x3335f2['push'](this['_makeIdsRoot'](_0x3956a2));else{for(let _0x72ba42=0x0;_0x72ba42<_0x3956a2['offsetSize'];_0x72ba42++)_0x3335f2['push'](new _0x2768fe('$text',{'vid':this['_revisionId']++}));}const _0x492ace=this['_revisionId'];for(let _0x504ac9=_0x2f33c1;_0x504ac9<_0x492ace;_0x504ac9++)this['_touched']['set'](_0x504ac9,{'userId':_0x34eb1a});_0x45a334['_insertChild'](_0x5d13eb['offset'],_0x3335f2);}['_handleMoveOperation'](_0x5d9b18){(_0x5d9b18=this['_cloneOperation'](_0x5d9b18,this['_idsRoots']))['_execute']();const _0x3130a=null===_0x5d9b18['_authorId']?null:_0x5d9b18['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x471664=_0x5d9b18['getMovedRangeStart'](),_0x3266ae=_0x471664['parent'],_0x200f0d=_0x471664['offset'];!function _0xbb0589(_0x532ada,_0x2f93fb,_0x35cd69,_0x45938d){for(let _0x2e1788=_0x35cd69;_0x2e1788<_0x45938d;_0x2e1788++){const _0x49bf3d=_0x2f93fb['getChild'](_0x2e1788);_0x49bf3d['is']('element','$text')?_0x532ada['set'](_0x49bf3d['getAttribute']('vid'),{'userId':_0x3130a}):(_0x532ada['set'](_0x49bf3d['getAttribute']('vid_start'),{'userId':_0x3130a}),_0xbb0589(_0x532ada,_0x49bf3d,0x0,_0x49bf3d['childCount']),_0x532ada['set'](_0x49bf3d['getAttribute']('vid_end'),{'userId':_0x3130a}));}}(this['_touched'],_0x3266ae,_0x200f0d,_0x200f0d+_0x5d9b18['howMany']);}['_handleMergeOperation'](_0x21e47a){const _0x5819f5=null===(_0x21e47a=this['_cloneOperation'](_0x21e47a,this['_idsRoots']))['_authorId']?null:_0x21e47a['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x78a45d=_0x21e47a['targetPosition']['parent'],_0x4fe53f=_0x21e47a['sourcePosition']['parent'],_0x514de9=_0x78a45d['getAttribute']('vid_end'),_0x5cd6fb=_0x4fe53f['getAttribute']('vid_start');_0x78a45d['_setAttribute']('vid_end',_0x4fe53f['getAttribute']('vid_end')),_0x4fe53f['_setAttribute']('vid_end',_0x514de9),this['_touched']['set'](_0x5cd6fb,{'userId':_0x5819f5}),this['_touched']['set'](_0x514de9,{'userId':_0x5819f5}),_0x21e47a['_execute']();}['_handleSplitOperation'](_0x4710fb){const _0x4aeaf5=null===(_0x4710fb=this['_cloneOperation'](_0x4710fb,this['_idsRoots']))['_authorId']?null:_0x4710fb['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x868c8=_0x4710fb['graveyardPosition'],_0x2fb49e=_0x4710fb['splitPosition']['parent'];_0x4710fb['_execute']();const _0x25137d=_0x2fb49e['getAttribute']('vid_end'),_0x19dd4e=_0x4710fb['insertionPosition']['nodeAfter'];if(_0x868c8){const _0x5eba67=_0x19dd4e['getAttribute']('vid_end'),_0x10c22a=_0x2fb49e['getAttribute']('vid_end');_0x2fb49e['_setAttribute']('vid_end',_0x5eba67),_0x19dd4e['_setAttribute']('vid_end',_0x10c22a),this['_touched']['set'](_0x2fb49e['getAttribute']('vid_end'),{'userId':_0x4aeaf5}),this['_touched']['set'](_0x19dd4e['getAttribute']('vid_start'),{'userId':_0x4aeaf5});}else{const _0x2a8b22=this['_revisionId']++,_0x138071=this['_revisionId']++;_0x2fb49e['_setAttribute']('vid_end',_0x2a8b22),_0x19dd4e['_setAttribute']('vid_start',_0x138071),_0x19dd4e['_setAttribute']('vid_end',_0x25137d),this['_touched']['set'](_0x2a8b22,{'userId':_0x4aeaf5}),this['_touched']['set'](_0x138071,{'userId':_0x4aeaf5});}}['_handleMarkerOperation'](_0x5abeb2){if(!_0x5abeb2['affectsData'])return;const _0x5c4971=(_0x5abeb2=this['_cloneOperation'](_0x5abeb2,this['_diffRoots']))['oldRange']?_0x5abeb2['oldRange']['root']:null,_0x1e4586=_0x5abeb2['newRange']?_0x5abeb2['newRange']['root']:null;_0x5c4971&&this['_markers']['delete'](_0x5abeb2['name']),_0x1e4586&&this['_markers']['set'](_0x5abeb2['name'],_0x5abeb2['newRange']['clone']());const _0x58c42e=null===_0x5abeb2['_authorId']?null:_0x5abeb2['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x3eb6e5=_0x5abeb2['name'];if(!this['_touchedMarkers']['has'](_0x3eb6e5))return void this['_touchedMarkers']['set'](_0x3eb6e5,{'range':_0x5abeb2['oldRange'],'userId':_0x58c42e});const _0x31bbee=this['_touchedMarkers']['get'](_0x3eb6e5),_0x5bcbe9=_0x31bbee['range'],_0x5d3735=_0x5abeb2['newRange'];null==_0x5bcbe9&&null==_0x5d3735||_0x5bcbe9&&_0x5d3735&&_0x5bcbe9['isEqual'](_0x5d3735)?this['_touchedMarkers']['delete'](_0x5abeb2['name']):_0x31bbee['userId']=_0x58c42e;}['_handleRootOperation'](_0x548d46,_0xcfe938){this['_diffRoots']['has'](_0x548d46['rootName'])?this['_diffRoots']['get'](_0x548d46['rootName'])['_isAttached']=_0x548d46['isAdd']:(this['_diffRoots']['set'](_0x548d46['rootName'],N(_0x548d46['rootName'],!0x0)),this['_diffRootsAttributes']['set'](_0x548d46['rootName'],{}),_0xcfe938&&this['_idsRoots']['set'](_0x548d46['rootName'],N(_0x548d46['rootName'],!0x0)));const _0x2b2a28=null===_0x548d46['_authorId']?null:_0x548d46['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x4bcd34=this['_touchedRoots']['get'](_0x548d46['rootName']);_0x4bcd34&&_0x4bcd34['userId']===_0x2b2a28?this['_touchedRoots']['delete'](_0x548d46['rootName']):this['_touchedRoots']['set'](_0x548d46['rootName'],{'userId':_0x2b2a28,'isAttached':_0x548d46['isAdd']});}['_handleRootAttributeOperation'](_0x7d2132){const _0x388a10=this['_diffRootsAttributes']['get'](_0x7d2132['root']['rootName']);null===_0x7d2132['newValue']?delete _0x388a10[_0x7d2132['key']]:_0x388a10[_0x7d2132['key']]=_0x7d2132['newValue'];}}function x(_0x42fcd2){const _0x3616d2=N(_0x42fcd2['rootName'],_0x42fcd2['isAttached']());for(const _0x2f62e8 of _0x42fcd2['getChildren']()){const _0x40715e=_0x2f62e8['_clone'](!0x0);_0x3616d2['_appendChild'](_0x40715e);}return _0x3616d2;}function N(_0x2a636d,_0x29595b=!0x0){const _0x23e3fe=new _0x5ebf7b();return _0x23e3fe['rootName']=_0x2a636d,_0x23e3fe['_isAttached']=_0x29595b,_0x23e3fe['isAttached']=()=>_0x23e3fe['_isAttached'],_0x23e3fe;}function P(_0x46c045,_0x575fda,_0x3e2d03){const _0x5f290d='elementEnd'==_0x46c045['type']?_0x3e2d03['createPositionAt'](_0x46c045['item'],'end'):_0x3e2d03['createPositionBefore'](_0x46c045['item']);return _0x3e2d03['createPositionFromPath'](_0x575fda,_0x5f290d['path'],_0x5f290d['stickiness']);}function V(_0x547b37,_0x2ea988,_0x5a8bc6){const _0x7e677f='elementStart'==_0x547b37['type']?_0x5a8bc6['createPositionAt'](_0x547b37['item'],0x0):_0x5a8bc6['createPositionAfter'](_0x547b37['item']);return _0x5a8bc6['createPositionFromPath'](_0x2ea988,_0x7e677f['path'],_0x7e677f['stickiness']);}class me extends/* #__PURE__ -- @preserve */
|
|
25
|
+
_0x565943(_0x366bc3){['focusTracker'];['keystrokes'];['revisionNameInputView'];constructor(_0x2477c8,_0x1cfb2c){super(_0x2477c8),this['focusTracker']=new _0x1dbf64(),this['keystrokes']=new _0x76073c(),this['set']('revisionNameInputValue',''),this['revisionNameInputView']=this['_createRevisionNameInput'](_0x1cfb2c),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'](),_0xcc0e94({'view':this}),this['focusTracker']['add'](this['revisionNameInputView']['element']),this['keystrokes']['listenTo'](this['element']);const _0xdcffdf=_0x51a25d=>_0x51a25d['stopPropagation']();this['keystrokes']['set']('arrowright',_0xdcffdf),this['keystrokes']['set']('arrowleft',_0xdcffdf),this['keystrokes']['set']('arrowup',_0xdcffdf),this['keystrokes']['set']('arrowdown',_0xdcffdf);}['focus'](){this['revisionNameInputView']['focus']();}get['revisionName'](){return this['revisionNameInputView']['fieldView']['element']['value']['trim']();}set['revisionName'](_0x306d85){this['revisionNameInputView']['fieldView']['element']['value']=_0x306d85['trim']();}['reset'](){this['revisionNameInputView']['fieldView']['element']['value']='',this['revisionNameInputView']['errorText']=null;}['_createRevisionNameInput'](_0x4e8d37){const _0x19a18c=new et(this['locale'],ti),_0xf8dd4c=_0x19a18c['fieldView'];_0xf8dd4c['extendTemplate']({'attributes':{'maxlength':'220'}});let _0xe2d539=R(this['locale'],'Name\x20of\x20the\x20revision');return!_0x4e8d37&&(_0xe2d539+='\x20('+R(this['locale'],'optional')+')'),(_0x19a18c['label']=_0xe2d539,_0xf8dd4c['on']('input',()=>{this['revisionNameInputValue']=_0xf8dd4c['element']['value']['trim']();}),_0x19a18c);}}class v extends _0x382226{static get['pluginName'](){return'RevisionHistoryUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[h];}['_saveRevisionFormView'];['init'](){const _0x3de5a2=this['editor'],_0x5f1946=_0x3de5a2['plugins']['get']('RevisionTracker');_0x3de5a2['ui']['componentFactory']['add']('revisionHistory',_0x2673e0=>{const _0x54828d=_0x31cb79(_0x2673e0),_0x3c43f8=_0x54828d['panelView']['children'],_0x319c64=new _0x3e000b(_0x2673e0),_0x349f8e=new _0xdbf374(_0x2673e0),_0x4e0b53=new _0x2c9755(_0x2673e0),_0xed22c6=new _0xdbf374(_0x2673e0),_0x18adb5=new _0x2c9755(_0x2673e0);return _0x54828d['bind']('isEnabled')['to'](_0x5f1946,'isReady',_0x5f1946,'isEnabled',_0x3de5a2,'isReadOnly',(_0x1df96a,_0xc48a13,_0x313930)=>_0x1df96a&&_0xc48a13&&!_0x313930),_0x54828d['buttonView']['set']({'icon':_0x179e8c,'label':R(_0x2673e0,'Revision\x20history'),'tooltip':!0x0}),_0x4e0b53['set']({'label':R(_0x2673e0,'Save\x20current\x20revision'),'withText':!0x0,'role':'menuitem'}),_0x4e0b53['bind']('isEnabled')['to'](_0x5f1946,'isReady',_0x5f1946,'isEnabled',_0x3de5a2,'isReadOnly',(_0x33cd94,_0x3538f7,_0x112a4f)=>_0x33cd94&&_0x3538f7&&!_0x112a4f),_0x4e0b53['on']('execute',()=>this['_showDialog']()),_0x18adb5['set']({'label':R(_0x2673e0,'Open\x20revision\x20history'),'withText':!0x0,'role':'menuitem'}),_0x18adb5['bind']('isEnabled')['to'](_0x5f1946,'isReady',_0x3de5a2,'isReadOnly',(_0x25a88c,_0x39f836)=>_0x25a88c&&!_0x39f836),_0x18adb5['on']('execute',()=>{_0x3de5a2['config']['get']('revisionHistory')['showRevisionViewerCallback'](),_0x54828d['isOpen']=!0x1,_0x3de5a2['editing']['view']['focus']();}),_0x349f8e['children']['add'](_0x4e0b53),_0xed22c6['children']['add'](_0x18adb5),_0x319c64['role']='menu',_0x319c64['items']['addMany']([_0x349f8e,_0xed22c6]),_0x3c43f8['add'](_0x319c64),_0x54828d;}),_0x3de5a2['ui']['componentFactory']['add']('menuBar:revisionHistory',()=>this['_registerMenuComponent']());}['_registerMenuComponent'](){const _0x4881da=this['editor'],_0x1fccfa=_0x4881da['locale'],_0x560451=new _0x4b7d73(_0x1fccfa),_0x2efcc6=new _0x28aba1(_0x1fccfa);_0x560451['buttonView']['set']({'icon':_0x179e8c,'label':R(_0x1fccfa,'Revision\x20history')});const _0xd79f21=new _0x46ae30(_0x1fccfa,_0x560451),_0x50ec1a=new _0x53996e(_0x1fccfa);_0x50ec1a['set']({'label':R(_0x1fccfa,'Save\x20current\x20revision')}),_0x50ec1a['delegate']('execute')['to'](_0x560451),_0x50ec1a['on']('execute',()=>{this['_showDialog']();}),_0xd79f21['children']['add'](_0x50ec1a),_0x2efcc6['items']['add'](_0xd79f21);const _0xef1ae5=new _0x46ae30(_0x1fccfa,_0x560451),_0x52b219=new _0x53996e(_0x1fccfa);return _0x52b219['set']({'label':R(_0x1fccfa,'Open\x20revision\x20history')}),_0x52b219['delegate']('execute')['to'](_0x560451),_0x52b219['on']('execute',()=>{_0x4881da['config']['get']('revisionHistory')['showRevisionViewerCallback']();}),_0xef1ae5['children']['add'](_0x52b219),_0x2efcc6['items']['add'](_0xef1ae5),_0x560451['panelView']['children']['add'](_0x2efcc6),_0x560451;}['_showDialog'](){const _0x42c7d3=this['editor'],_0xb62eb7=_0x42c7d3['locale'],_0x433797=_0x42c7d3['plugins']['get']('Dialog'),_0x225c02=_0x42c7d3['plugins']['get']('RevisionTracker');function _0x1d4dbf(_0x3d58f9){_0x42c7d3['config']['get']('revisionHistory.requireRevisionName')&&''===_0x3d58f9['revisionName']?_0x3d58f9['revisionNameInputView']['errorText']=R(_0xb62eb7,'The\x20revision\x20name\x20cannot\x20be\x20empty.'):(_0x42c7d3['plugins']['get'](h)['saveRevision']({'name':_0x3d58f9['revisionName']}),_0x433797['hide']());}this['_saveRevisionFormView']||(this['_createSaveRevisionFormView'](),this['_saveRevisionFormView']['on']('submit',()=>_0x1d4dbf(this['_saveRevisionFormView']))),this['_saveRevisionFormView']['reset'](),_0x433797['show']({'id':'revisionSave','title':R(_0xb62eb7,'Save\x20current\x20revision'),'isModal':!0x0,'content':this['_saveRevisionFormView'],'actionButtons':[{'label':R(_0x42c7d3['locale'],'Cancel'),'withText':!0x0,'onExecute':()=>_0x433797['hide']()},{'label':R(_0x42c7d3['locale'],'Accept'),'class':'ck-button-action','withText':!0x0,'onCreate'(_0x5d27c0){_0x5d27c0['bind']('isEnabled')['to'](_0x225c02,'isReady',_0x225c02,'isEnabled',_0x42c7d3,'isReadOnly',(_0x52a84e,_0x761ffc,_0x46d89d)=>_0x52a84e&&_0x761ffc&&!_0x46d89d);},'onExecute':()=>_0x1d4dbf(this['_saveRevisionFormView'])}]});}['_createSaveRevisionFormView'](){const _0x2979cf=this['editor'],_0x36de0f=_0x2979cf['locale'];this['_saveRevisionFormView']=new me(_0x36de0f,_0x2979cf['config']['get']('revisionHistory.requireRevisionName')),this['_saveRevisionFormView']['render']();}}class z extends _0x366bc3{['changeId'];['_model'];constructor(_0x1b8d06,_0x4f525e){super(_0x1b8d06),this['_model']=_0x4f525e,this['changeId']=_0x4f525e['id'];const _0x58751b=this['bindTemplate'],_0x4a0e3a=R(_0x1b8d06,_0x4f525e['data']['isSuggestion']?'Suggested\x20by':'add'==_0x4f525e['type']?'Added\x20by':'Removed\x20by');this['set']('type',_0x4f525e['type']),this['setTemplate']({'tag':'div','attributes':{'class':['ck-annotation','ck-revision-change',_0x58751b['to']('type',_0x3cabf7=>'ck-revision-change__'+_0x3cabf7)],'tabindex':-0x1},'children':[{'tag':'span','children':[{'tag':'span','attributes':{'class':['ck-revision-change__label']},'children':[{'text':_0x4a0e3a}]},{'text':'\x20'+_0x4f525e['author']['name']}]}]});}['focus'](){this['element']['focus']();}}class G extends/* #__PURE__ -- @preserve */
|
|
26
|
+
_0x15d64b(){['id'];['author'];['type'];['data'];['rootName'];constructor(_0x2add78){super(),this['id']=_0x2add78['id']||_0xeb3ed1(),this['author']=_0x2add78['author'],this['type']=_0x2add78['type'],this['data']=_0x2add78['data']||{},this['rootName']=_0x2add78['rootName'],this['set']('createdAt',_0x2add78['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(_0x73838d,_0x5f2c24){this['newRevisionId']=_0x73838d,this['oldRevisionId']=_0x5f2c24,this['changes']=new _0x2d6f70();}['_setChanges'](_0x5aa231){for(const _0xe8fa8b of _0x5aa231)this['changes']['add'](_0xe8fa8b);}}class l extends _0x382226{['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[_0x5e2d35,_0x466db6,S,$];}constructor(_0x23c745){super(_0x23c745),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',(_0x1a82bf,_0x3f8b4c,_0x29aec6)=>{this['activeChange']=null,this['activeView']=null,this['editor']['editing']['view']['change'](_0x1d4ba7=>{for(const _0x5ec918 of this['editor']['editing']['view']['document']['roots'])_0x29aec6?_0x1d4ba7['removeClass']('ck-editor__editable__overlay',_0x5ec918):_0x1d4ba7['addClass']('ck-editor__editable__overlay',_0x5ec918);});}),this['bind']('isNavigationMode')['to'](this,'activeChange',_0x180d1c=>null!==_0x180d1c),this['bind']('currentChangeNumber')['to'](this,'isReady',this,'diff',this,'activeChange',(_0x2dc791,_0x67db44,_0x39101b)=>_0x2dc791&&_0x39101b?_0x67db44['changes']['getIndex'](_0x39101b):0x0),this['bind']('numberOfChanges')['to'](this,'isReady',this,'diff',(_0x599185,_0x4e85f5)=>_0x599185?_0x4e85f5['changes']['length']:0x0),this['_changeView']=null,this['_changeIdToChange']=new Map(),this['_balloon']=this['editor']['plugins']['get'](_0x466db6);}['init'](){const _0xa77277=this['editor'],_0x5ccd20=new rt(_0xa77277,{'direction':'backward'}),_0x18252b=new rt(_0xa77277,{'direction':'forward'});(_0xa77277['commands']['add']('showPreviousChange',_0x5ccd20),_0xa77277['commands']['add']('showNextChange',_0x18252b),_0xa77277['commands']['add']('restoreRevision',new nt(_0xa77277)),this['on']('change:numberOfChanges',()=>{_0x5ccd20['refresh'](),_0x18252b['refresh']();}),this['_setConversion'](),this['_initInteractions'](),_0xa77277['enableReadOnlyMode']('revision-viewer'),_0xa77277['plugins']['has']('WidgetToolbarRepository'))&&_0xa77277['plugins']['get']('WidgetToolbarRepository')['forceDisabled']('revision-viewer');}async['getRevisionDocumentData'](_0x2a8c1f){return await this['_utils']['loadRevisionData'](_0x2a8c1f,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x2a8c1f);}async['getRevisionRootsAttributes'](_0x22bc71){return await this['_utils']['loadRevisionData'](_0x22bc71,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x22bc71);}async['compare'](_0x12af9f,_0x1778ca,_0x330de3=!0x1){if(!this['isEnabled'])return;const _0x164b8a=this['diff'],_0xded1ee=this['repository'],_0x5791d2='string'==typeof _0x12af9f?_0xded1ee['getRevision'](_0x12af9f):_0x12af9f,_0x12b7e8='string'==typeof _0x1778ca?_0xded1ee['getRevision'](_0x1778ca):_0x1778ca,_0x1b7a49=_0x5791d2['id'],_0x380521=_0x12b7e8?_0x12b7e8['id']:null;if(!_0x330de3&&this['diff']&&this['diff']['newRevisionId']===_0x1b7a49&&this['diff']['oldRevisionId']===_0x380521)return Promise['resolve']();this['isReady']=!0x1,this['activeView']=null,this['activeChange']=null,this['diff']=new J(_0x1b7a49,_0x380521);const _0x55c91c=this['_getRevisionsRange'](_0x5791d2,_0x12b7e8,!0x0)['map'](_0x881b65=>this['_utils']['loadRevisionData'](_0x881b65,this['adapter']));return _0x55c91c['push'](new Promise(_0x548016=>{setTimeout(_0x548016,0x14);})),Promise['all'](_0x55c91c)['then'](()=>{if(!this['isEnabled'])return;this['_cleanUp']();const _0x36067b=this['_getDiff'](_0x1b7a49,_0x380521);for(const _0x59b665 of _0x36067b['changes'])this['_changeIdToChange']['set'](_0x59b665['id'],_0x59b665);this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x256cf4=>{for(const _0x1f0e4d of this['editor']['model']['document']['getRootNames']())_0x256cf4['detachRoot'](_0x1f0e4d);for(const _0x13e3bb of Object['keys'](_0x36067b['model'])){const _0x5a5deb=_0x256cf4['addRoot'](_0x13e3bb);for(const _0x5bdc95 of Object['keys'](_0x36067b['attributes'][_0x13e3bb]))_0x256cf4['setAttribute'](_0x5bdc95,_0x36067b['attributes'][_0x13e3bb][_0x5bdc95],_0x5a5deb);_0x256cf4['insert'](_0x36067b['model'][_0x13e3bb],_0x5a5deb,0x0);}}),this['diff']['_setChanges'](this['_sortAndFilterDiffChanges'](_0x36067b['changes'])),this['isReady']=!0x0;})['catch'](_0x4b55e6=>{console['error'](_0x4b55e6),this['_cleanUp'](),_0x164b8a&&(this['diff']=_0x164b8a),this['isReady']=!0x0;});}['addRevisionData'](_0x2e7121,_0xb76b74){const _0x4431fb=this['repository']['createRevision'](_0x2e7121);return _0x4431fb['on']('_update',(_0xad7064,_0xe2af9c,_0x2be42f)=>_0xb76b74(_0xe2af9c,_0x2be42f,_0x4431fb)),this['repository']['addRevision'](_0x4431fb),_0x4431fb;}['_cleanUp'](){this['activeChange']=null,this['_cleanMarkers'](),this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=null,this['_changeIdToChange']['clear'](),this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x15e1c5=>{for(const _0x4e11dc of this['editor']['model']['document']['getRootNames']())_0x15e1c5['detachRoot'](_0x4e11dc);});}['_sortAndFilterDiffChanges'](_0x3c6abf){const _0x24debb=[],_0x2454ab=new Map();for(const _0x7928de of this['editor']['model']['document']['getRootNames']()){const _0x5150a9=this['editor']['editing']['view']['getDomRoot'](_0x7928de);if(!_0x5150a9)continue;const _0x5af18a=_0x5150a9['getClientRects']()['item'](0x0);_0x5af18a&&(_0x24debb['push'](_0x7928de),_0x2454ab['set'](_0x7928de,_0x5af18a));}return _0x24debb['sort']((_0x127807,_0x17def1)=>{const _0x58f56a=_0x2454ab['get'](_0x127807),_0x216e85=_0x2454ab['get'](_0x17def1);return _0x58f56a['y']-_0x216e85['y']||_0x58f56a['x']-_0x216e85['x'];}),(_0x3c6abf=_0x3c6abf['filter'](_0x25d4f2=>_0x24debb['includes'](_0x25d4f2['rootName'])))['sort']((_0x57e788,_0x1878af)=>_0x24debb['indexOf'](_0x57e788['rootName'])-_0x24debb['indexOf'](_0x1878af['rootName'])),_0x3c6abf;}['_makeTape'](_0x2b04c5){const _0x233471=Array['from'](_0x2b04c5['markers'])['filter'](([_0x2847b5,_0x61b7cc])=>_0x2847b5['startsWith']('revision:')&&!_0x61b7cc['isCollapsed']),_0x8b98f4=Array['from'](this['editor']['model']['createRangeIn'](_0x2b04c5)['getWalker']({'singleCharacters':!0x0}));if(0x0!=_0x233471['length'])for(const _0x5c2240 of _0x8b98f4){const [_0x49ac6b,_0x5dac62]=_0x233471[0x0],[,_0x542211,_0x42c73d]=_0x49ac6b['split'](':');if(_0x5dac62['end']['isEqual'](_0x5c2240['nextPosition'])&&_0x233471['shift'](),(_0x5c2240['previousPosition']['isEqual'](_0x5dac62['start'])||_0x5c2240['previousPosition']['isAfter'](_0x5dac62['start']))&&('insertion'==_0x542211?_0x5c2240['isAdded']={'userId':_0x42c73d}:'deletion'==_0x542211&&(_0x5c2240['isRemoved']={'userId':_0x42c73d})),0x0==_0x233471['length'])break;}return _0x8b98f4;}['_refreshStartEndIndex'](_0x3fc993){const _0x323f2c=new Map();for(let _0x3619ac=0x0;_0x3619ac<_0x3fc993['length'];_0x3619ac++)'text'===_0x3fc993[_0x3619ac]['type']?(_0x3fc993[_0x3619ac]['item']['startIndex']=_0x3619ac,_0x3fc993[_0x3619ac]['item']['endIndex']=_0x3619ac):('elementStart'===_0x3fc993[_0x3619ac]['type']?_0x3fc993[_0x3619ac]['item']['startIndex']=_0x3619ac:'elementEnd'===_0x3fc993[_0x3619ac]['type']&&(_0x3fc993[_0x3619ac]['item']['endIndex']=_0x3619ac),_0x323f2c['set'](_0x3fc993[_0x3619ac]['id'],_0x3619ac));for(const _0x345825 of _0x323f2c['values']())'elementStart'===_0x3fc993[_0x345825]['type']?_0x3fc993[_0x345825]['item']['endIndex']=_0x323f2c['get'](_0x3fc993[_0x345825]['pairId']):'elementEnd'===_0x3fc993[_0x345825]['type']&&(_0x3fc993[_0x345825]['item']['startIndex']=_0x323f2c['get'](_0x3fc993[_0x345825]['pairId']));}['_processTape'](_0x5c54a3){for(let _0x3382eb=0x0;_0x3382eb<_0x5c54a3['length'];_0x3382eb++){if('elementStart'===_0x5c54a3[_0x3382eb]['type'])_0x5c54a3[_0x3382eb]['item']['startIndex']=_0x3382eb;else{if('elementEnd'===_0x5c54a3[_0x3382eb]['type']){_0x5c54a3[_0x3382eb]['item']['endIndex']=_0x3382eb;const _0x3463d3=_0x5c54a3[_0x3382eb]['item']['startIndex'];_0x5c54a3[_0x3463d3]['pairId']=_0x5c54a3[_0x3382eb]['id'],_0x5c54a3[_0x3382eb]['pairId']=_0x5c54a3[_0x3463d3]['id'];}else _0x5c54a3[_0x3382eb]['item']['startIndex']=_0x3382eb,_0x5c54a3[_0x3382eb]['item']['endIndex']=_0x3382eb,_0x5c54a3[_0x3382eb]['pairId']=null;}_0x5c54a3[_0x3382eb]['markersStart']||(_0x5c54a3[_0x3382eb]['markersStart']=[],_0x5c54a3[_0x3382eb]['markersEnd']=[]);}}['_markInsertions'](_0x5d22c2,_0x4f8b63){const _0x494d95=_0x5d22c2['filter'](_0x3f41b2=>!_0x3f41b2['isAdded']);for(let _0x21cd02=0x0;_0x21cd02<_0x4f8b63['length'];_0x21cd02++)_0x4f8b63[_0x21cd02]['isAdded']&&(_0x494d95[_0x21cd02]['isAdded']=_0x4f8b63[_0x21cd02]['isAdded']);}['_getDiff'](_0x1bdc3d,_0x2b3980=null){const _0x39f256=this['repository']['getRevision'](_0x1bdc3d),_0xe6e819=_0x2b3980?this['repository']['getRevision'](_0x2b3980):null,_0x29d813=this['_getRevisionsRange'](_0x39f256,_0xe6e819),_0x52fd0b=_0x29d813[_0x29d813['length']-0x1],_0x1b5fe2=new Map(),_0x3fb274={'model':{},'attributes':{},'changes':[]},_0x2dfe22=new Set(),_0x49997d=new Map();for(let _0x5fa25b=_0x29d813['length']-0x1;_0x5fa25b>=0x0;_0x5fa25b--){const _0x320a71=_0x29d813[_0x5fa25b];for(const _0x3836dd of Object['keys'](_0x320a71['diffData']))if(_0x320a71['diffData'][_0x3836dd]['attachChange']){const _0x58b42e=_0x320a71['diffData'][_0x3836dd]['attachChange'];_0x58b42e['isAttached']?(_0x2dfe22['add'](_0x3836dd),_0x49997d['has'](_0x3836dd)&&_0x49997d['get'](_0x3836dd)['userId']==_0x58b42e['userId']?_0x49997d['delete'](_0x3836dd):_0x49997d['set'](_0x3836dd,_0x58b42e)):_0x49997d['has'](_0x3836dd)?(_0x2dfe22['delete'](_0x3836dd),_0x49997d['delete'](_0x3836dd)):(_0x2dfe22['add'](_0x3836dd),_0x49997d['set'](_0x3836dd,_0x58b42e));}else _0x2dfe22['add'](_0x3836dd);}for(const _0x231792 of _0x2dfe22){const _0xef8e08=_0x49997d['has'](_0x231792)&&!_0x49997d['get'](_0x231792)['isAttached'];let _0x501e04=_0xef8e08?_0x29d813['length']-0x1:0x0;const _0x51a1f7=_0xef8e08?-0x1:0x1;for(;_0x29d813[_0x501e04];){const _0x17ad20=_0x29d813[_0x501e04];if(_0x17ad20['diffData'][_0x231792]){const _0xe9eb12=_0xef8e08?_0x17ad20['diffData'][_0x231792]['attributesBefore']:_0x17ad20['diffData'][_0x231792]['attributesAfter'];_0x3fb274['attributes'][_0x231792]=_0xe9eb12?_0x1ba0a9(_0xe9eb12):{};break;}_0x501e04+=_0x51a1f7;}}for(const _0xe72d2e of _0x29d813){_0xe72d2e['model']={};for(const _0x48e59b of _0xe72d2e['authors'])_0x1b5fe2['set'](_0x48e59b['id'],_0x48e59b);for(const _0xb1c4e7 of _0x2dfe22){const _0x26e1dc=_0xe72d2e['diffData'][_0xb1c4e7]?_0xe72d2e['diffData'][_0xb1c4e7]['insertions']:'[]',_0x2ef3f2=_0xe72d2e['diffData'][_0xb1c4e7]?_0xe72d2e['diffData'][_0xb1c4e7]['deletions']:'[]';_0xe72d2e['model'][_0xb1c4e7]={'insertions':this['_utils']['_makeModelFromViewString'](_0x26e1dc),'deletions':this['_utils']['_makeModelFromViewString'](_0x2ef3f2)};}}for(const _0x37de33 of _0x2dfe22){let _0xabcdf0=null,_0x192dd0=0x0;const _0x327d2d=new Map(Array['from'](_0x39f256['model'][_0x37de33]['insertions']['markers'])['filter'](([_0x196a9a])=>!_0x196a9a['startsWith']('revision:')));let _0x14752b=0x0;for(const _0x56b597 of _0x29d813){const _0x986e7a=this['_makeTape'](_0x56b597['model'][_0x37de33]['insertions']);_0x56b597==_0x39f256?(_0xabcdf0=_0x986e7a,_0x192dd0=_0xabcdf0['length'],_0xabcdf0['forEach'](_0x220d75=>{_0x220d75['id']=_0x14752b++;}),this['_processTape'](_0xabcdf0)):this['_markInsertions'](_0xabcdf0,_0x986e7a);const _0x1b56e2=_0xabcdf0['filter'](_0x235c73=>!_0x235c73['isAdded'])['map'](_0xa4914d=>_0xa4914d['id']);let _0x454c56=0x0;const _0x28aea7=this['_makeTape'](_0x56b597['model'][_0x37de33]['deletions']);_0x28aea7['forEach'](_0x44c1ae=>{_0x44c1ae['isRemoved']?_0x44c1ae['id']=_0x192dd0++:_0x44c1ae['id']=_0x1b56e2[_0x454c56++];}),this['_processTape'](_0x28aea7),this['_setDistance'](_0xabcdf0,'isAdded'),this['_setDistance'](_0x28aea7,'isRemoved'),_0x56b597==_0x39f256&&this['_markMarkers'](_0xabcdf0,_0x327d2d),_0xabcdf0=this['_joinTapes'](_0xabcdf0,_0x28aea7),this['_refreshStartEndIndex'](_0xabcdf0),this['_setDistance'](_0xabcdf0,'isRemoved');}_0xabcdf0=_0xabcdf0['filter'](_0x342ac5=>!(_0x342ac5['isAdded']&&_0x342ac5['isRemoved']));const _0x375c67=new Map(_0x52fd0b['model'][_0x37de33]['deletions']['markers']),_0x28a594=new Set(_0x327d2d['keys']());for(const _0x4739b4 of _0x375c67['keys']())_0x28a594['delete'](_0x4739b4);this['_markSuggestions'](_0xabcdf0,_0x28a594),this['_fixObsoleteTags'](_0xabcdf0),_0xabcdf0=this['_removeMissingPairs'](_0xabcdf0),_0xabcdf0=this['_markMismatchedRemovedTags'](_0xabcdf0),_0xabcdf0=this['_removeUnsupportedChanges'](_0xabcdf0);const {root:_0x3a6764,changes:_0x3f7d1}=this['_makeModelFromTape'](_0xabcdf0,_0x1b5fe2,_0x37de33);_0x3fb274['model'][_0x37de33]=_0x3a6764;const _0x4fed91=_0x49997d['get'](_0x37de33);if(_0x4fed91){const _0x383b1b=_0x1b5fe2['get'](_0x4fed91['userId']),_0x4eaf81=new G({'author':_0x383b1b,'type':_0x4fed91['isAttached']?'add':'remove','data':{'isOnRoot':!0x0},'createdAt':new Date(),'rootName':_0x37de33});_0x3f7d1['unshift'](_0x4eaf81),_0x3fb274['attributes'][_0x37de33]['revisionHistoryAttachChange']=_0x4eaf81['id'];}_0x3fb274['changes']=_0x3fb274['changes']['concat'](_0x3f7d1);}return _0x3fb274;}['_markMarkers'](_0x48800d,_0x504a3e){for(let _0x4dd6d4=0x0;_0x4dd6d4<_0x48800d['length'];_0x4dd6d4++)for(const [_0xf36701,_0x108d1c]of _0x504a3e)!_0x108d1c['isCollapsed']&&_0x108d1c['start']['isEqual'](_0x48800d[_0x4dd6d4]['previousPosition'])&&_0x48800d[_0x4dd6d4]['markersStart']['push'](_0xf36701),_0x108d1c['end']['isEqual'](_0x48800d[_0x4dd6d4]['nextPosition'])&&_0x48800d[_0x4dd6d4]['markersEnd']['push'](_0xf36701);}['_joinTapes'](_0x5bda13,_0x39eb11){let _0x136423=[],_0x5da44e=0x0,_0x21fa72=0x0;for(;_0x5da44e<_0x5bda13['length']||_0x21fa72<_0x39eb11['length'];){const _0x5583fa=_0x5bda13[_0x5da44e]||{},_0x19f2b8=_0x39eb11[_0x21fa72]||{};if(_0x5583fa['id']==_0x19f2b8['id'])_0x5da44e++,_0x21fa72++,_0x136423['push'](_0x5583fa);else{if(_0x19f2b8['isRemoved']&&_0x5583fa['isAdded']){const {commonTape:_0x4a4ee8,iEnd:_0x236835,jEnd:_0x59f544}=this['_threeWayMerge'](_0x5bda13,_0x5da44e,_0x39eb11,_0x21fa72);_0x136423=_0x136423['concat'](_0x4a4ee8),_0x5da44e=_0x236835,_0x21fa72=_0x59f544;}else _0x19f2b8['isRemoved']?(_0x21fa72++,_0x136423['push'](_0x19f2b8)):(_0x5da44e++,_0x136423['push'](_0x5583fa));}}return _0x136423;}['_markSuggestions'](_0x1d8e7d,_0x29206c){const _0x673ab6=[];for(let _0x2e0a84=0x0;_0x2e0a84<_0x1d8e7d['length'];_0x2e0a84++){for(let _0x473396=0x0;_0x473396<_0x1d8e7d[_0x2e0a84]['markersStart']['length'];_0x473396++){const _0xefddb7=_0x1d8e7d[_0x2e0a84]['markersStart'][_0x473396];if(!_0x29206c['has'](_0xefddb7))continue;const {group:_0xe7df1d,type:_0x52871a,authorId:_0x5b237c}=_0x17977b(_0xefddb7);'revision-suggestion'!=_0xe7df1d||'insertion'!=_0x52871a&&'deletion'!=_0x52871a||(_0x673ab6['unshift']({'type':_0x52871a,'name':_0xefddb7,'userId':_0x5b237c}),_0x1d8e7d[_0x2e0a84]['markersStart']['splice'](_0x473396,0x1),_0x473396--);}_0xa6fa23(_0x1d8e7d[_0x2e0a84]);for(let _0x325a5e=0x0;_0x325a5e<_0x1d8e7d[_0x2e0a84]['markersEnd']['length'];_0x325a5e++){const _0x457dac=_0x1d8e7d[_0x2e0a84]['markersEnd'][_0x325a5e];if(!_0x29206c['has'](_0x457dac))continue;const {group:_0x5cf9fc,type:_0x3ed4c2}=_0x17977b(_0x457dac);if('revision-suggestion'!=_0x5cf9fc||'insertion'!=_0x3ed4c2&&'deletion'!=_0x3ed4c2)continue;_0x1d8e7d[_0x2e0a84]['markersEnd']['splice'](_0x325a5e,0x1),_0x325a5e--;const _0x5384f8=_0x673ab6['findIndex'](_0x2916cf=>_0x2916cf['name']==_0x457dac);_0x5384f8>-0x1&&_0x673ab6['splice'](_0x5384f8,0x1);}}function _0x17977b(_0x4e2ea6){const _0x319855=_0x4e2ea6['split'](':');return{'group':_0x319855[0x0],'type':_0x319855[0x1],'subType':_0x319855['length']>=0x5?_0x319855[0x2]:null,'id':_0x319855['length']<0x5?_0x319855[0x2]:_0x319855[0x3],'authorId':_0x319855['length']<0x5?_0x319855[0x3]:_0x319855[0x4],'markerCount':0x6==_0x319855['length']?_0x319855[0x5]:null};}function _0xa6fa23(_0x25d85e){for(let _0xb730c0=0x0;_0xb730c0<_0x673ab6['length'];_0xb730c0++){if(_0x25d85e['isAdded']&&'insertion'==_0x673ab6[_0xb730c0]['type']&&_0x25d85e['isAdded']['userId']==_0x673ab6[_0xb730c0]['userId'])return _0x25d85e['isAddSuggestion']=_0x673ab6[_0xb730c0],void delete _0x25d85e['isAdded'];if(!_0x25d85e['isAdded']&&!_0x25d85e['isRemoved']&&'deletion'==_0x673ab6[_0xb730c0]['type'])return void(_0x25d85e['isRemoveSuggestion']=_0x673ab6[_0xb730c0]);}}}['_setDistance'](_0x654997,_0x5d428c){let _0x5415eb=0x0,_0x253295=!0x1;const _0x3c5aa7=new Map();for(const _0xe2c634 of _0x654997)_0xe2c634[_0x5d428c]?_0x253295&&(_0x5415eb++,_0x253295=!0x1):(_0x5415eb++,_0x253295=!0x0),_0x3c5aa7['set'](_0xe2c634['id'],_0x5415eb);for(let _0x45e8a0=0x0;_0x45e8a0<_0x654997['length'];_0x45e8a0++){if('isRemoved'==_0x5d428c&&_0x654997[_0x45e8a0]['isAdded']||'isAdded'==_0x5d428c&&_0x654997[_0x45e8a0]['isRemoved'])continue;if('text'==_0x654997[_0x45e8a0]['type']){_0x654997[_0x45e8a0]['distance']=0x0;continue;}const _0xfa5615=_0x3c5aa7['get'](_0x654997[_0x45e8a0]['pairId']),_0x1b3e6d=_0x3c5aa7['get'](_0x654997[_0x45e8a0]['id']);_0x654997[_0x45e8a0]['distance']=_0xfa5615-_0x1b3e6d;}}['_getRevisionsRange'](_0xeec179,_0x3d8e6b,_0xdaa2c7=!0x1){const _0x5befeb=[];let _0x14c8d6=this['repository']['getIndex'](_0xeec179),_0x395ef4=this['repository']['getIndex'](_0x3d8e6b);for(-0x1==_0x395ef4&&(_0x395ef4=this['repository']['_revisions']['length'],_0xdaa2c7=!0x1);_0x14c8d6<_0x395ef4;)_0x5befeb['push'](this['repository']['getRevision'](_0x14c8d6)),_0x14c8d6++;return _0xdaa2c7&&_0x5befeb['push'](this['repository']['getRevision'](_0x14c8d6)),_0x5befeb;}['_threeWayMerge'](_0xeea4b2,_0x5c0649,_0x170408,_0x51d8fc){const _0x5754af=this['editor']['model']['schema'];let _0x13e1f2=_0x5c0649;for(;_0xeea4b2[_0x13e1f2]&&_0xeea4b2[_0x13e1f2]['isAdded'];)_0x13e1f2++;let _0xff26fb=_0x51d8fc;for(;_0x170408[_0xff26fb]&&_0x170408[_0xff26fb]['isRemoved'];)_0xff26fb++;_0x35e84a(_0xeea4b2,_0x5c0649,_0x13e1f2),_0x35e84a(_0x170408,_0x51d8fc,_0xff26fb);const _0x4d5ed5=_0x170408['slice'](_0x51d8fc,_0xff26fb)['concat'](_0xeea4b2['slice'](_0x5c0649,_0x13e1f2));return _0x4d5ed5['sort']((_0x5df321,_0x1c2201)=>_0x5df321['side']!=_0x1c2201['side']?_0x5df321['side']-_0x1c2201['side']:_0x5df321['level']!=_0x1c2201['level']?_0x5df321['level']-_0x1c2201['level']:_0x5df321['distance']!=_0x1c2201['distance']?_0x1c2201['distance']-_0x5df321['distance']:!!_0x5df321['isAdded']!=!!_0x1c2201['isAdded']?-0x1==_0x5df321['side']||0x0==_0x5df321['side']?_0x5df321['isAdded']?-0x1:0x1:_0x5df321['isAdded']?0x1:-0x1:_0x5df321['index']-_0x1c2201['index']),{'commonTape':_0x4d5ed5,'iEnd':_0x13e1f2,'jEnd':_0xff26fb};function _0x35e84a(_0x428b36,_0x11fb6b,_0x28cf67){let _0x7242fc=-0x1,_0x1d1bc6=Number['POSITIVE_INFINITY'],_0x2be516=!0x0;for(let _0x14c250=_0x11fb6b;_0x14c250<_0x28cf67;_0x14c250++)if(_0x5754af['isInline'](_0x428b36[_0x14c250]['item'])||(_0x2be516=!0x1),_0x428b36[_0x14c250]['item']['startIndex']<_0x11fb6b&&(_0x7242fc=_0x14c250),_0x428b36[_0x14c250]['item']['endIndex']>=_0x28cf67){_0x1d1bc6=_0x14c250;break;}_0x2be516&&(_0x7242fc=_0x28cf67-0x1);for(let _0x3e406d=_0x11fb6b;_0x3e406d<_0x28cf67;_0x3e406d++)_0x428b36[_0x3e406d]['side']=_0x3e406d<=_0x7242fc?-0x1:_0x3e406d<_0x1d1bc6?0x0:0x1,_0x428b36[_0x3e406d]['index']=_0x3e406d;let _0xf84c8c=0x0;for(let _0x341983=_0x11fb6b;_0x341983<=_0x7242fc;_0x341983++)0x0==_0x428b36[_0x341983]['distance']?_0x428b36[_0x341983]['level']=_0xf84c8c:(_0xf84c8c++,_0x428b36[_0x341983]['level']=_0xf84c8c,_0xf84c8c++);for(let _0x25cb0d=_0x11fb6b;_0x25cb0d<_0x28cf67;_0x25cb0d++)0x0==_0x428b36[_0x25cb0d]['side']&&(_0x428b36[_0x25cb0d]['level']=_0xf84c8c);_0xf84c8c=0x0;for(let _0x45859f=_0x28cf67-0x1;_0x45859f>=_0x1d1bc6;_0x45859f--)0x0==_0x428b36[_0x45859f]['distance']?_0x428b36[_0x45859f]['level']=_0xf84c8c:(_0xf84c8c--,_0x428b36[_0x45859f]['level']=_0xf84c8c,_0xf84c8c--);}}['_fixObsoleteTags'](_0x1fab72){const _0x4ac6a6=new Map(),_0x47c4a2=this['editor']['model']['schema'];for(let _0x38a9a6=0x1;_0x38a9a6<_0x1fab72['length'];_0x38a9a6++){let _0x181a1a,_0x20f43b,_0x595557;const _0x511c7c=_0x1fab72[_0x38a9a6],_0x229b62=_0x1fab72[_0x38a9a6-0x1];if('text'==_0x511c7c['type'])continue;if(_0x511c7c['type']!=_0x229b62['type'])continue;if(!_0x47c4a2['isBlock'](_0x229b62['item'])||_0x47c4a2['isLimit'](_0x229b62['item']))continue;if(!_0x47c4a2['isBlock'](_0x511c7c['item'])||_0x47c4a2['isLimit'](_0x511c7c['item']))continue;if((_0x1fab72[_0x38a9a6]['isAdded']||_0x1fab72[_0x38a9a6]['isAddSuggestion'])&&_0x1fab72[_0x38a9a6-0x1]['isRemoved'])_0x181a1a=_0x1fab72[_0x38a9a6],_0x20f43b=_0x1fab72[_0x38a9a6-0x1],_0x595557=_0x38a9a6-0x1;else{if(!_0x1fab72[_0x38a9a6]['isRemoved']||!_0x1fab72[_0x38a9a6-0x1]['isAdded']&&!_0x1fab72[_0x38a9a6-0x1]['isAddSuggestion'])continue;_0x181a1a=_0x1fab72[_0x38a9a6-0x1],_0x20f43b=_0x1fab72[_0x38a9a6],_0x595557=_0x38a9a6;}const _0x14e65f=_0x181a1a['level']==_0x20f43b['level'],_0x15e17c=Math['abs'](_0x181a1a['level'])<Math['abs'](_0x20f43b['level'])&&0x0==_0x20f43b['distance'];(_0x14e65f||_0x15e17c)&&(_0x4ac6a6['set'](_0x20f43b['id'],_0x181a1a['id']),_0x1fab72['splice'](_0x595557,0x1),_0x38a9a6--,_0x181a1a['isAdded']=!0x1);}for(let _0x36f30c=0x0;_0x36f30c<_0x1fab72['length'];_0x36f30c++)_0x4ac6a6['has'](_0x1fab72[_0x36f30c]['pairId'])&&(_0x1fab72[_0x36f30c]['pairId']=_0x4ac6a6['get'](_0x1fab72[_0x36f30c]['pairId']));}['_removeMissingPairs'](_0x5d0c4d){const _0x5b2726=new Set(_0x5d0c4d['map'](_0x5a7425=>_0x5a7425['id']));for(let _0x5ade48=0x0;_0x5ade48<_0x5d0c4d['length'];_0x5ade48++)_0x5b2726['has'](_0x5d0c4d[_0x5ade48]['pairId'])||0x0==_0x5d0c4d[_0x5ade48]['distance']||(_0x5d0c4d[_0x5ade48]['isIncorrect']=!0x0);return _0x5d0c4d['filter'](_0xbce3e3=>!_0xbce3e3['isIncorrect']);}['_markMismatchedRemovedTags'](_0x9adaff){const _0xe43e5c=new Set();for(let _0xed955f=0x0;_0xed955f<_0x9adaff['length'];_0xed955f++){if(_0xe43e5c['has'](_0x9adaff[_0xed955f]['id'])&&_0x9adaff[_0xed955f]['isRemoved']&&(_0x9adaff[_0xed955f]['isIncorrect']=!0x0),_0x9adaff[_0xed955f]['isIncorrect'])continue;if(0x0==_0x9adaff[_0xed955f]['distance'])continue;if('elementStart'!=_0x9adaff[_0xed955f]['type'])continue;if(null==_0x9adaff[_0xed955f]['pairId'])continue;let _0x4ca195=_0xed955f+0x1,_0x12c2b4=0x0;for(;_0x9adaff[_0x4ca195]['id']!=_0x9adaff[_0xed955f]['pairId'];)'elementStart'==_0x9adaff[_0x4ca195]['type']?_0x12c2b4++:'elementEnd'==_0x9adaff[_0x4ca195]['type']&&_0x12c2b4--,_0x4ca195++;if(0x0!=_0x12c2b4){if(_0x9adaff[_0xed955f]['isRemoved'])_0x9adaff[_0xed955f]['isIncorrect']=!0x0;else{for(;_0x4ca195!=_0xed955f;)_0x9adaff[_0x4ca195]['isRemoved']&&0x0!=_0x9adaff[_0x4ca195]['distance']&&(_0x9adaff[_0x4ca195]['isIncorrect']=!0x0,_0xe43e5c['add'](_0x9adaff[_0x4ca195]['pairId'])),_0x4ca195--;}}}return _0x9adaff['filter'](_0x34c45d=>!_0x34c45d['isIncorrect']);}['_removeUnsupportedChanges'](_0x3e23e4){const _0x297bc7=this['editor']['model']['schema'];for(let _0x5afa84=0x0;_0x5afa84<_0x3e23e4['length'];_0x5afa84++){if(!(_0x3e23e4[_0x5afa84]['isAdded']||_0x3e23e4[_0x5afa84]['isAddSuggestion']||_0x3e23e4[_0x5afa84]['isRemoved']||_0x3e23e4[_0x5afa84]['isRemoveSuggestion']))continue;if(0x0==_0x3e23e4[_0x5afa84]['distance'])continue;const _0x5f433d=_0x3e23e4[_0x5afa84]['item'];_0x297bc7['isBlock'](_0x5f433d)||_0x297bc7['isLimit'](_0x5f433d)||(_0x3e23e4[_0x5afa84]['isAdded']&&delete _0x3e23e4[_0x5afa84]['isAdded'],_0x3e23e4[_0x5afa84]['isAddSuggestion']&&delete _0x3e23e4[_0x5afa84]['isAddSuggestion'],_0x3e23e4[_0x5afa84]['isRemoveSuggestion']&&delete _0x3e23e4[_0x5afa84]['isRemoveSuggestion'],_0x3e23e4[_0x5afa84]['isRemoved']&&(_0x3e23e4[_0x5afa84]['isIncorrect']=!0x0));}return _0x3e23e4['filter'](_0x33effb=>!_0x33effb['isIncorrect']);}['_makeModelFromTape'](_0x134afa,_0x180207,_0x48936f){const _0x29002d=new _0x5ebf7b(),_0x3f5b03=[],_0xd8e720=new Map(),_0x5cbeff=this['editor']['model'],_0x5425c7=_0x5cbeff['schema'],_0x172b0e=[_0x29002d],_0x394d9c={},_0x41cd50={'isAdded':[],'isRemoved':[],'isAddSuggestion':[],'isRemoveSuggestion':[]};let _0x91c13a=null;const _0x206f7f=[0x0];for(let _0xbb37e8=0x0;_0xbb37e8<_0x134afa['length'];_0xbb37e8++)if('elementStart'===_0x134afa[_0xbb37e8]['type']){_0x134afa[_0xbb37e8]['previousPosition']=_0x5cbeff['createPositionFromPath'](_0x29002d,_0x206f7f);const _0x32e73f=new _0x2768fe(_0x134afa[_0xbb37e8]['item']['name'],_0x134afa[_0xbb37e8]['item']['getAttributes']());_0x172b0e[0x0]['_appendChild'](_0x32e73f),_0x206f7f['push'](0x0),_0x172b0e['unshift'](_0x32e73f),_0x134afa[_0xbb37e8]['nextPosition']=_0x5cbeff['createPositionFromPath'](_0x29002d,_0x206f7f);}else'elementEnd'===_0x134afa[_0xbb37e8]['type']?(_0x172b0e['shift'](),_0x134afa[_0xbb37e8]['previousPosition']=_0x5cbeff['createPositionFromPath'](_0x29002d,_0x206f7f),_0x206f7f['pop'](),_0x206f7f[_0x206f7f['length']-0x1]++,_0x134afa[_0xbb37e8]['nextPosition']=_0x5cbeff['createPositionFromPath'](_0x29002d,_0x206f7f)):(_0x134afa[_0xbb37e8]['previousPosition']=_0x5cbeff['createPositionFromPath'](_0x29002d,_0x206f7f),_0x91c13a?_0x91c13a['_data']+=_0x134afa[_0xbb37e8]['item']['data']:_0x91c13a=new _0x2d98db(_0x134afa[_0xbb37e8]['item']['data'],_0x134afa[_0xbb37e8]['item']['getAttributes']()),_0x134afa[_0xbb37e8+0x1]&&'text'===_0x134afa[_0xbb37e8+0x1]['type']&&_0x57f5d5(_0x91c13a,_0x134afa[_0xbb37e8+0x1]['item'])||(_0x172b0e[0x0]['_appendChild'](_0x91c13a),_0x91c13a=null),_0x206f7f[_0x206f7f['length']-0x1]+=_0x134afa[_0xbb37e8]['item']['offsetSize'],_0x134afa[_0xbb37e8]['nextPosition']=_0x5cbeff['createPositionFromPath'](_0x29002d,_0x206f7f));for(let _0x4e9e57=0x0;_0x4e9e57<_0x134afa['length'];_0x4e9e57++){const _0x1cf71a=_0x134afa[_0x4e9e57]['previousPosition'],_0x50642b=_0x134afa[_0x4e9e57]['nextPosition'];for(const _0x43b46c of _0x134afa[_0x4e9e57]['markersStart'])_0xd8e720['set'](_0x43b46c,{'start':_0x1cf71a,'end':null});_0x2e73fd('isRemoveSuggestion',_0x4e9e57,_0x1cf71a,_0x50642b),_0x2e73fd('isAddSuggestion',_0x4e9e57,_0x1cf71a,_0x50642b),_0x2e73fd('isRemoved',_0x4e9e57,_0x1cf71a,_0x50642b),_0x2e73fd('isAdded',_0x4e9e57,_0x1cf71a,_0x50642b);for(const _0x5eda51 of _0x134afa[_0x4e9e57]['markersEnd']){const _0x5ed06a=_0xd8e720['get'](_0x5eda51);_0x5ed06a?_0x5ed06a['end']=_0x50642b:_0xd8e720['set'](_0x5eda51,{'start':_0x50642b,'end':_0x50642b});}}for(const [_0x2e2143,_0x3d2528]of _0xd8e720){const _0x455192=this['editor']['model']['createRange'](_0x3d2528['start'],_0x3d2528['end']);_0x29002d['markers']['set'](_0x2e2143,_0x455192);}return _0x3f5b03['sort']((_0x9aa9c7,_0x56071c)=>{const _0x1ecdca=_0x29002d['markers']['get']('revision:'+_0x9aa9c7['id']),_0xa28a73=_0x29002d['markers']['get']('revision:'+_0x56071c['id']);return _0x1ecdca['start']['isBefore'](_0xa28a73['start'])?-0x1:_0x1ecdca['start']['isAfter'](_0xa28a73['start'])?0x1:_0x1ecdca['end']['isBefore'](_0xa28a73['end'])?-0x1:_0x1ecdca['end']['isAfter'](_0xa28a73['end'])?0x1:'add'===_0x9aa9c7['type']?-0x1:0x1;}),{'root':_0x29002d,'changes':_0x3f5b03};function _0x2e73fd(_0x3e37b6,_0x4f175e,_0x299893,_0x189715){const _0x52b1b8=!!_0x134afa[_0x4f175e][_0x3e37b6],_0x7ce2f7=_0x52b1b8?_0x134afa[_0x4f175e][_0x3e37b6]['userId']:null,_0x1f4a48=_0x4f175e===_0x134afa['length']-0x1,_0x94aae3=_0x41cd50[_0x3e37b6][0x0],_0x4213f3=_0x5425c7['isObject'](_0x134afa[_0x4f175e]['item']);!_0x394d9c[_0x3e37b6]&&_0x52b1b8?_0x394d9c[_0x3e37b6]={'start':_0x299893,'tapeItem':_0x134afa[_0x4f175e],'userId':_0x7ce2f7,'type':_0x3e37b6}:_0x394d9c[_0x3e37b6]&&!_0x52b1b8?(_0x394d9c[_0x3e37b6]['end']=_0x299893,_0x5cdc35(_0x394d9c[_0x3e37b6]),_0x394d9c[_0x3e37b6]=null):_0x394d9c[_0x3e37b6]&&_0x52b1b8&&_0x394d9c[_0x3e37b6]['userId']!==_0x7ce2f7&&(_0x394d9c[_0x3e37b6]['end']=_0x299893,_0x94aae3&&_0x94aae3['userId']===_0x394d9c[_0x3e37b6]['userId']||_0x5cdc35(_0x394d9c[_0x3e37b6]),_0x394d9c[_0x3e37b6]={'start':_0x299893,'tapeItem':_0x134afa[_0x4f175e],'userId':_0x7ce2f7,'type':_0x3e37b6}),_0x394d9c[_0x3e37b6]&&_0x4213f3&&('elementStart'!==_0x134afa[_0x4f175e]['type']||_0x94aae3&&_0x94aae3['userId']===_0x7ce2f7||_0x41cd50[_0x3e37b6]['unshift']({'userId':_0x7ce2f7,'object':_0x134afa[_0x4f175e]['item'],'change':_0x394d9c[_0x3e37b6]}),'elementEnd'===_0x134afa[_0x4f175e]['type']&&_0x94aae3&&_0x94aae3['object']===_0x134afa[_0x4f175e]['item']&&(_0x41cd50[_0x3e37b6]['shift'](),_0x394d9c[_0x3e37b6]=_0x94aae3['change'])),_0x394d9c[_0x3e37b6]&&_0x1f4a48&&(_0x394d9c[_0x3e37b6]['end']=_0x189715,_0x5cdc35(_0x394d9c[_0x3e37b6]),_0x394d9c[_0x3e37b6]=null);}function _0x5cdc35({start:_0x453119,end:_0x1c6433,tapeItem:_0x64a3ae,userId:_0x3b9abd,type:_0xc29e}){const _0x81f0ac=_0x64a3ae['item'],_0x132f79=_0x5cbeff['schema']['isBlock'](_0x81f0ac)&&!_0x5cbeff['schema']['isLimit'](_0x81f0ac),_0x13d52b=_0x453119['nodeAfter']==_0x1c6433['parent']&&_0x1c6433['isAtStart'];if(_0x132f79&&_0x13d52b)return;const _0x44593e=_0x5cbeff['createRange'](_0x453119,_0x1c6433),_0xbe3d91=_0x180207['get'](_0x3b9abd),_0x4d0a80=new G({'author':_0xbe3d91,'type':'isAdded'==_0xc29e||'isAddSuggestion'==_0xc29e?'add':'remove','data':{'isSuggestion':'isAddSuggestion'==_0xc29e||'isRemoveSuggestion'==_0xc29e},'createdAt':new Date(),'rootName':_0x48936f});_0x3f5b03['push'](_0x4d0a80),_0x29002d['markers']['set']('revision:'+_0x4d0a80['id'],_0x44593e);}function _0x57f5d5(_0x35302d,_0x31fec4){const _0xeeb9df=_0x35302d['getAttributes'](),_0x15ac89=_0x31fec4['getAttributes']();for(const _0x4142c4 of _0xeeb9df){if(_0x4142c4[0x1]!==_0x31fec4['getAttribute'](_0x4142c4[0x0]))return!0x1;_0x15ac89['next']();}return _0x15ac89['next']()['done'];}}['_setConversion'](){this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision','view':_0xc90129=>{const _0x27c4cb=_0xc90129['markerName']['split'](':')[0x1],_0x568e89=this['_getChangeFromId'](_0x27c4cb);if(!_0x568e89)return null;const _0x4e55e2='add'==_0x568e89['type']?'insertion':'deletion',_0x24b2e5=['ck-suggestion-marker','ck-suggestion-marker-'+_0x4e55e2];return _0x568e89['data']['isSuggestion']&&_0x24b2e5['push']('ck-suggestion-marker-'+_0x4e55e2+'-new'),this['activeChange']==_0x568e89&&_0x24b2e5['push']('ck-suggestion-marker--active'),{'classes':_0x24b2e5,'attributes':{'data-change-id':_0x27c4cb}};}}),this['editor']['conversion']['for']('upcast')['add'](_0x2c8bc7=>{_0x2c8bc7['on']('element:pre',(_0x5254c4,_0x4b83b4,_0x4075f4)=>{const _0x29d523=_0x4b83b4['viewItem']['getChild'](0x0);if(!_0x29d523||!_0x29d523['is']('element','code'))return;if(!_0x4075f4['consumable']['consume'](_0x29d523,{'attributes':['vid_start','vid_end']}))return;const _0x4d9491=_0x4b83b4['modelRange']['start']['nodeAfter'];_0x4075f4['writer']['setAttribute']('vid_start',_0x29d523['getAttribute']('vid_start'),_0x4d9491),_0x4075f4['writer']['setAttribute']('vid_end',_0x29d523['getAttribute']('vid_end'),_0x4d9491);},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['add'](_0xa25630=>{_0xa25630['on']('element',(_0x3c4394,_0x2764ff,_0x5808b1)=>{if(!_0x5808b1['consumable']['consume'](_0x2764ff['viewItem'],{'attributes':['vid_start','vid_end']}))return;if(_0x2764ff['modelRange']['isCollapsed'])return;const _0x3f00e0=_0x2764ff['modelRange']['start']['nodeAfter'];_0x3f00e0['hasAttribute']('vid_start')||_0x3f00e0['hasAttribute']('vid')||(_0x5808b1['writer']['setAttribute']('vid_start',_0x2764ff['viewItem']['getAttribute']('vid_start'),_0x3f00e0),_0x5808b1['writer']['setAttribute']('vid_end',_0x2764ff['viewItem']['getAttribute']('vid_end'),_0x3f00e0));},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['elementToAttribute']({'view':{'name':'span','attributes':{'vid':!0x0}},'model':{'key':'vid','value':_0x35965b=>_0x35965b['getAttribute']('vid')}}),this['editor']['model']['schema']['on']('checkAttribute',(_0x33cf57,[,_0x33eca4])=>{['vid_start','vid_end','vid']['includes'](_0x33eca4)&&(_0x33cf57['return']=!0x0,_0x33cf57['stop']());},{'priority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x4c8d63=>{_0x4c8d63['on']('attribute:vid',(_0x395ed4,_0x1ee0ac,_0x12ad5b)=>{if('\x20'!=_0x1ee0ac['item']['data']||_0x1ee0ac['item']['parent']['maxOffset']>0x1)return;if(!_0x12ad5b['consumable']['consume'](_0x1ee0ac['item'],_0x395ed4['name']))return;const _0x4c0e3b=_0x12ad5b['writer'],_0x12c8f6=_0x12ad5b['mapper']['toViewRange'](_0x1ee0ac['range']);_0x4c0e3b['wrap'](_0x12c8f6,_0x4c0e3b['createAttributeElement']('span'));});}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',function(_0x56b756){const _0x53ba0b=_0x56b756['plugins']['get']('RevisionViewer');return(_0x53e612,_0x147400,_0x3600de)=>{const _0x4ddc38=_0x147400['markerName']['split'](':')[0x1],_0x569441=_0x53ba0b['_getChangeFromId'](_0x4ddc38);if(!_0x569441)return null;const _0x2424d2='add'==_0x569441['type']?'split':'merge';if(!_0x3600de['consumable']['test'](_0x147400['markerRange'],_0x53e612['name']))return;const _0x4b59c5=_0x147400['markerRange']['getWalker'](),_0x214fa4=_0x147400['markerRange']['start'],_0x4f3d44=_0x56b756['model']['schema'];let _0x225cce=null,_0x5bce29=null,_0x2110c1=!0x1,_0xe33675=!0x1;for(const _0x54cea5 of _0x4b59c5){const _0x20973a=_0x54cea5['item'];_0x2110c1=_0x2110c1||_0x4f3d44['isContent'](_0x20973a);const _0x4457cb=_0x3600de['mapper']['toViewElement'](_0x20973a);if(_0x4457cb&&_0x4457cb['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x54cea5['type']&&(_0x4f3d44['isBlock'](_0x20973a)&&!_0x4f3d44['isLimit'](_0x20973a)&&(_0x20973a['nextSibling']||_0x214fa4['isAtEnd']?_0x225cce&&_0x225cce['parent']==_0x20973a||(_0x225cce=_0x20973a,_0x590e2c(_0x54cea5['previousPosition']),_0xe33675=!0x0):_0x5bce29=_0x5bce29||_0x54cea5['previousPosition']));}function _0x590e2c(_0x380af4){const _0x5b9408=_0x3600de['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x2424d2}),_0x5acf76=_0x3600de['mapper']['toViewPosition'](_0x380af4);_0x569441['data']['isSuggestion']&&_0x3600de['writer']['addClass']('ck-suggestion-marker-'+_0x2424d2+'-new',_0x5b9408),_0x53ba0b['activeChange']==_0x569441&&_0x3600de['writer']['addClass']('ck-suggestion-marker--active',_0x5b9408),_0x3600de['writer']['insert'](_0x5acf76,_0x5b9408),_0x3600de['mapper']['bindElementToMarker'](_0x5b9408,_0x147400['markerName']);}_0x2110c1||_0xe33675||!_0x5bce29||_0x590e2c(_0x5bce29);};}(this['editor']),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision',(_0x52f128,_0x3e2220,_0x147fed)=>{const _0x11a71b=_0x147fed['mapper']['markerNameToElements'](_0x3e2220['markerName']);if(_0x11a71b){for(const _0x348d62 of _0x11a71b)(_0x348d62['hasClass']('ck-suggestion-marker-split')||_0x348d62['hasClass']('ck-suggestion-marker-merge'))&&(_0x147fed['mapper']['unbindElementFromMarkerName'](_0x348d62,_0x3e2220['markerName']),_0x147fed['writer']['remove'](_0x348d62));}},{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',(_0x7c932c,_0x416fc8,_0x4efd4e)=>{const _0x509f31=_0x416fc8['markerName']['split'](':')[0x1],_0x4dc558=this['_getChangeFromId'](_0x509f31);if(!_0x4dc558)return null;const _0x13f82e='add'==_0x4dc558['type']?'split':'merge';if(_0x4efd4e['consumable']['test'](_0x416fc8['markerRange'],_0x7c932c['name']))for(const _0x518ec9 of _0x416fc8['markerRange']['getItems']()){if(!_0x518ec9['is']('element','softBreak'))continue;const _0x42e882=_0x4efd4e['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x13f82e}),_0x197c61=_0x4efd4e['mapper']['toViewPosition'](this['editor']['model']['createPositionBefore'](_0x518ec9));_0x4dc558['data']['isSuggestion']&&_0x4efd4e['writer']['addClass']('ck-suggestion-marker-'+_0x13f82e+'-new',_0x42e882),this['activeChange']==_0x4dc558&&_0x4efd4e['writer']['addClass']('ck-suggestion-marker--active',_0x42e882),_0x4efd4e['writer']['insert'](_0x197c61,_0x42e882),_0x4efd4e['mapper']['bindElementToMarker'](_0x42e882,_0x416fc8['markerName']);}},{'priority':'high'}),this['editor']['model']['document']['on']('change',()=>{this['editor']['editing']['view']['change'](_0x2b7552=>{for(const _0x145792 of this['editor']['model']['document']['getRootNames']()){const _0x174f79=this['editor']['model']['document']['getRoot'](_0x145792),_0x3034aa=this['editor']['editing']['view']['document']['getRoot'](_0x145792);if(_0x3034aa){const _0x253bb6=_0x174f79['getAttribute']('revisionHistoryAttachChange');if(_0x2b7552['removeAttribute']('data-change-id',_0x3034aa),_0x2b7552['removeClass']('ck-revision-history-root-add',_0x3034aa),_0x2b7552['removeClass']('ck-revision-history-root-remove',_0x3034aa),_0x2b7552['removeClass']('ck-revision-history-root--active',_0x3034aa),_0x253bb6){const _0x16905b=this['_getChangeFromId'](_0x253bb6);if(!_0x16905b)return null;_0x2b7552['setAttribute']('data-change-id',_0x253bb6,_0x3034aa),_0x2b7552['addClass']('ck-revision-history-root-'+_0x16905b['type'],_0x3034aa),this['activeChange']==_0x16905b&&_0x2b7552['addClass']('ck-revision-history-root--active',_0x3034aa);}}}});}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'comment','model':_0x36f52e=>'revision-comment:'+_0x36f52e,'converterPriority':'highest'}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'suggestion','model':_0x16a75e=>'revision-suggestion:'+_0x16a75e,'converterPriority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision-suggestion','view':_0x5cf8ca=>({'name':'suggestion:'+_0x5cf8ca,'group':'revision-suggestion'}),'converterPriority':'highest'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision-suggestion','view':_0x57de10=>{const _0x547573=_0x57de10['markerName']['split'](':')[0x1];return'insertion'!=_0x547573&&'deletion'!=_0x547573?null:{'classes':['ck-suggestion-preview-marker','ck-suggestion-preview-marker-'+_0x547573]};}}),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',(_0x5d9826,_0x428800,_0x27a6b9)=>{const _0x151871=_0x27a6b9['mapper']['markerNameToElements'](_0x428800['markerName']);if(_0x151871){for(const _0x15ee67 of _0x151871)_0x15ee67['is']('uiElement')&&(_0x27a6b9['mapper']['unbindElementFromMarkerName'](_0x15ee67,_0x428800['markerName']),_0x27a6b9['writer']['remove'](_0x15ee67));}},{'priority':'high'});}['_getChangeFromId'](_0xb80c5f){return this['_changeIdToChange']['get'](_0xb80c5f);}['_getViewForChange'](_0x4aa397){return this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=new z(this['editor']['locale'],_0x4aa397),this['_changeView'];}['_initInteractions'](){this['editor']['model']['document']['selection']['observeMarkers']('revision'),this['on']('change:activeView',(_0x21dc87,_0x535053,_0xac4294,_0x1964d5)=>{_0x1964d5&&this['_balloon']['remove'](_0x1964d5),_0xac4294&&(this['_balloon']['add']({'view':_0xac4294,'stackId':'revisionHistoryLabel','position':{'target':()=>{const _0x3f999c=this['editor']['editing'],_0x489375=this['_getChangeFromId'](_0xac4294['changeId']);let _0x328f41;if(_0x489375['data']['isOnRoot']){const _0x5bb58e=_0x3f999c['view']['getDomRoot'](_0x489375['rootName']);_0x328f41=Array['from'](_0x5bb58e['getClientRects']());}else{const _0x5cebd5=this['editor']['model']['markers']['get']('revision:'+_0xac4294['changeId']);_0x328f41=Array['from'](_0x3f999c['mapper']['markerNameToElements'](_0x5cebd5['name']))['map'](_0x9814ee=>_0x3f999c['view']['domConverter']['mapViewToDom'](_0x9814ee))['map'](_0x31b6dd=>Array['from'](_0x31b6dd['getClientRects']()))['flat']();}if(!this['_activeViewTarget'])return _0x328f41[0x0];return _0x328f41['find'](_0x4ff1c7=>_0x4ff1c7['top']-0x3<=this['_activeViewTarget']['y']&&_0x4ff1c7['bottom']+0x3>=this['_activeViewTarget']['y']&&_0x4ff1c7['left']-0x3<=this['_activeViewTarget']['x']&&_0x4ff1c7['right']+0x3>=this['_activeViewTarget']['x'])||_0x328f41[0x0];}}}),this['_balloon']['showStack']('revisionHistoryLabel'));}),this['on']('change:activeChange',(_0x12d965,_0x38f850,_0x258d6d,_0x386e31)=>{this['activeView']=_0x258d6d?this['_getViewForChange'](_0x258d6d):null,this['editor']['model']['change'](()=>{const _0x2f6631=this['editor']['editing'];_0x386e31&&(_0x386e31['data']['isOnRoot']?_0x2f6631['view']['change'](_0x4b3045=>{_0x4b3045['removeClass']('ck-revision-history-root--active',_0x2f6631['view']['document']['getRoot'](_0x386e31['rootName']));}):_0x2f6631['reconvertMarker']('revision:'+_0x386e31['id'])),_0x258d6d&&(_0x258d6d['data']['isOnRoot']?_0x2f6631['view']['change'](_0x2411bf=>{_0x2411bf['addClass']('ck-revision-history-root--active',_0x2f6631['view']['document']['getRoot'](_0x258d6d['rootName']));}):_0x2f6631['reconvertMarker']('revision:'+_0x258d6d['id']));});}),this['listenTo'](this['editor']['editing']['view']['document'],'mouseover',(_0x589131,_0xde2e22)=>{if(this['activeChange'])return;const _0x24ce35=this['_findChangeIdFromDomTarget'](_0xde2e22['target']),_0x526ade=this['_changeIdToChange']['get'](_0x24ce35);_0x526ade?(this['_activeViewTarget']={'x':_0xde2e22['domEvent']['x'],'y':_0xde2e22['domEvent']['y']},this['activeView']=this['_getViewForChange'](_0x526ade)):(this['_activeViewTarget']=null,this['activeView']=null);}),this['listenTo'](this['editor']['editing']['view']['document'],'mousedown',(_0x36cff4,_0x47741e)=>{const _0x23a5d8=this['_findChangeIdFromDomTarget'](_0x47741e['target']),_0x2abeb8=this['_changeIdToChange']['get'](_0x23a5d8);_0x2abeb8?(this['_activeViewTarget']={'x':_0x47741e['domEvent']['x'],'y':_0x47741e['domEvent']['y']},_0x2abeb8===this['activeChange']?this['_balloon']['updatePosition']():this['activeChange']=_0x2abeb8):(this['_activeViewTarget']=null,this['activeChange']=null);});}['_findChangeIdFromDomTarget'](_0x2660f2){do{const _0x3cc8a7=_0x2660f2['getAttribute']('data-change-id');if(_0x3cc8a7)return _0x3cc8a7;_0x2660f2=_0x2660f2['parent'];}while(_0x2660f2);return null;}['_cleanMarkers'](){this['editor']['model']['change'](_0x147987=>{for(const _0x47468f of this['editor']['model']['markers'])_0x147987['removeMarker'](_0x47468f);});}}function Q(_0x5479c3,_0x25acf6){return(_0x4e8c28,_0x3f5165,_0x24fe2d)=>{if(!_0x24fe2d['consumable']['test'](_0x3f5165['markerRange'],_0x4e8c28['name']))return;const _0x183dd4=_0x3f5165['markerRange']['getWalker'](),_0x5a8a3a=_0x3f5165['markerRange']['start'],_0x24b0da=_0x5479c3['model']['schema'];let _0xe1c9bf=null,_0x1d9d2e=null,_0x578324=!0x1,_0x55ccbe=!0x1;for(const _0x589ddd of _0x183dd4){const _0x25d762=_0x589ddd['item'];_0x578324=_0x578324||_0x24b0da['isContent'](_0x25d762);const _0xd7c011=_0x24fe2d['mapper']['toViewElement'](_0x25d762);if(_0xd7c011&&_0xd7c011['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x589ddd['type']&&(_0x24b0da['isBlock'](_0x25d762)&&!_0x24b0da['isLimit'](_0x25d762)&&(_0x25d762['nextSibling']||_0x5a8a3a['isAtEnd']?_0xe1c9bf&&_0xe1c9bf['parent']==_0x25d762||(_0xe1c9bf=_0x25d762,_0x303f05(_0x589ddd['previousPosition']),_0x55ccbe=!0x0):_0x1d9d2e=_0x1d9d2e||_0x589ddd['previousPosition']));}function _0x303f05(_0x44e64c){const _0x282bdf=_0x24fe2d['mapper']['toViewPosition'](_0x44e64c),_0x88f10f=_0x24fe2d['writer']['createUIElement']('span',{'class':'ck-suggestion-preview-marker-'+_0x25acf6});_0x24fe2d['writer']['insert'](_0x282bdf,_0x88f10f),_0x24fe2d['mapper']['bindElementToMarker'](_0x88f10f,_0x3f5165['markerName']);}_0x578324||_0x55ccbe||!_0x1d9d2e||_0x303f05(_0x1d9d2e);};}class nt extends _0x34dfa9{constructor(_0x158857){super(_0x158857);const _0x107855=_0x158857['plugins']['get'](l);this['affectsData']=!0x1,this['listenTo'](_0x107855,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x107855,'change:isEnabled',()=>this['refresh']());}['execute'](){const _0x1358e4=this['editor'],_0x496d6f=_0x1358e4['plugins']['get'](l),_0x1c51c2=_0x496d6f['isReady']?_0x496d6f['diff']['newRevisionId']:null;_0x1358e4['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x1c51c2);}['refresh'](){const {isReady:_0x4abeca,isEnabled:_0x145785,repository:_0x2170df,diff:_0x121f85}=this['editor']['plugins']['get'](l),_0x3e306f=_0x121f85&&_0x2170df['getLaterVisibleRevision'](_0x121f85['newRevisionId']);this['isEnabled']=_0x4abeca&&_0x145785&&Boolean(_0x3e306f);}}class rt extends _0x34dfa9{['_step'];constructor(_0xfc8fb6,{direction:_0x247f59}){super(_0xfc8fb6);const _0x4295ec=_0xfc8fb6['plugins']['get'](l);this['affectsData']=!0x1,this['_step']='forward'===_0x247f59?0x1:-0x1,this['listenTo'](_0x4295ec,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x4295ec,'change:isEnabled',()=>this['refresh']()),this['listenTo'](_0x4295ec,'change:activeChange',()=>this['refresh']());}['execute'](){const _0x206593=this['editor'],_0x464a9a=_0x206593['plugins']['get'](l),{isNavigationMode:_0x138ddc,currentChangeNumber:_0x486b5d}=_0x464a9a;let _0x3ca19f;if(_0x464a9a['activeChange']=_0x138ddc?_0x464a9a['diff']['changes']['get'](_0x486b5d+this['_step']):_0x464a9a['diff']['changes']['first'],_0x464a9a['activeChange']['data']['isOnRoot'])_0x3ca19f=_0x206593['editing']['view']['getDomRoot'](_0x464a9a['activeChange']['rootName']);else{const _0x5ee3e9=_0x206593['model']['markers']['get']('revision:'+_0x464a9a['activeChange']['id']);_0x3ca19f=_0x150676(_0x206593['editing'],_0x5ee3e9);}_0x190ffa({'target':_0x3ca19f,'viewportOffset':0x28});}['refresh'](){const {isNavigationMode:_0x1b86cb,currentChangeNumber:_0x23c138,numberOfChanges:_0x129a29,isReady:_0x4da7eb,isEnabled:_0x1386f2}=this['editor']['plugins']['get'](l);this['isEnabled']=!!(_0x1386f2&&_0x4da7eb&&_0x129a29)&&(!_0x1b86cb||(0x1===this['_step']?_0x23c138<_0x129a29-0x1:_0x23c138>0x0));}}class Ri extends _0x366bc3{constructor(_0x1d23d6){super(_0x1d23d6);const _0x2a926c=this['bindTemplate'],_0x2b01cb=new _0x2c9755(_0x1d23d6),_0x4177b6=new _0x2c9755(_0x1d23d6);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',(_0x32d62a,_0x34deca)=>_0x32d62a&&_0x34deca>0x0),this['bind']('_statusText')['to'](this,'isReady',this,'currentChangeNumber',this,'numberOfChanges',this,'isNavigationMode',(_0x5c20e9,_0x35faa6,_0x190a02,_0x3653f8)=>{if(!_0x5c20e9)return R(_0x1d23d6,'Loading...');if(!_0x190a02)return R(_0x1d23d6,'No\x20changes');const _0x57d2c4=R(_0x1d23d6,'NUMBER_OF_CHANGES',_0x190a02);return _0x3653f8?R(_0x1d23d6,'X_OF_Y_CHANGES',[_0x35faa6+0x1,_0x190a02]):_0x57d2c4;}),_0x2b01cb['set']({'label':R(_0x1d23d6,'Show\x20previous\x20change'),'tooltip':!0x0,'icon':_0x143fac}),_0x4177b6['set']({'label':R(_0x1d23d6,'Show\x20next\x20change'),'tooltip':!0x0,'icon':_0x405e50}),_0x2b01cb['bind']('isEnabled')['to'](this,'isBackwardNavigationEnabled'),_0x4177b6['bind']('isEnabled')['to'](this,'isForwardNavigationEnabled'),_0x2b01cb['on']('execute',()=>this['fire']('execute','backward')),_0x4177b6['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',_0x2a926c['if']('_isStatusLabelVisible','ck-hidden',_0x1e5c86=>!_0x1e5c86)]},'children':[{'text':_0x2a926c['to']('isNavigationMode',_0x1cdb78=>_0x1cdb78?R(_0x1d23d6,'EDIT_X_OF_Y_REVISIONS')+':\x20':R(_0x1d23d6,'Total')+':\x20')}]},{'text':_0x2a926c['to']('_statusText')}]},new _0x41d832(),{'tag':'div','attributes':{'class':['ck-revision-history-ui__changes-navigation__navigation']},'children':[_0x2b01cb,_0x4177b6]}]});}}const ge='ck-editor__editable__loading-overlay';class ji extends _0x382226{static get['pluginName'](){return'RevisionViewerLoadingOverlay';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['show'](){const _0x4ff975=this['editor']['editing']['view'];_0x4ff975['change'](_0x20278b=>{for(const _0x357bfd of _0x4ff975['document']['roots'])_0x20278b['addClass'](ge,_0x357bfd);});}['hide'](){const _0x552425=this['editor']['editing']['view'];_0x552425['change'](_0x5f0b28=>{for(const _0x489bfb of _0x552425['document']['roots'])_0x5f0b28['removeClass'](ge,_0x489bfb);});}}class u extends _0x382226{static get['pluginName'](){return'RevisionViewerUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[l,ji];}['init'](){const _0x2a1c41=this['editor'],_0x458ed8=_0x2a1c41['plugins']['get'](l),_0x273cde=_0x2a1c41['plugins']['get'](ji);_0x2a1c41['ui']['componentFactory']['add']('exitToEditing',_0x55ae4c=>{const _0x1b5bd=new _0x2c9755(_0x55ae4c);return _0x1b5bd['set']({'label':R(_0x55ae4c,'Back\x20to\x20editing'),'icon':_0x31cc52,'withText':!0x0,'tooltip':!0x0,'class':'ck-revision-history-ui__back-to-editing'}),this['listenTo'](_0x1b5bd,'execute',()=>{_0x2a1c41['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}),_0x1b5bd;}),_0x2a1c41['ui']['componentFactory']['add']('restoreRevision',_0x2bf19c=>{const _0x5629b8=new _0x2c9755(_0x2bf19c);return _0x5629b8['set']({'label':R(_0x2bf19c,'Restore\x20this\x20revision'),'withText':!0x0,'tooltip':!0x0}),_0x5629b8['bind']('isEnabled')['to'](_0x2a1c41['commands']['get']('restoreRevision')),this['listenTo'](_0x5629b8,'execute',()=>_0x2a1c41['execute']('restoreRevision')),_0x5629b8;}),_0x2a1c41['ui']['componentFactory']['add']('changesNavigation',_0x2d32b4=>{const _0x36fd0d=new Ri(_0x2d32b4),_0x4c95cf=_0x2a1c41['commands']['get']('showPreviousChange'),_0xa3b14f=_0x2a1c41['commands']['get']('showNextChange');return _0x36fd0d['bind']('isBackwardNavigationEnabled')['to'](_0x4c95cf,'isEnabled'),_0x36fd0d['bind']('isForwardNavigationEnabled')['to'](_0xa3b14f,'isEnabled'),_0x36fd0d['bind']('isReady','currentChangeNumber','numberOfChanges','isNavigationMode')['to'](_0x458ed8),this['listenTo'](_0x36fd0d,'execute',(_0x4b0abe,_0x5868b9)=>{_0x2a1c41['execute']('forward'===_0x5868b9?'showNextChange':'showPreviousChange');}),_0x36fd0d;}),_0x273cde['show'](),_0x458ed8['on']('change:isReady',(_0x4f0825,_0x104be6,_0x2fdbf8)=>{_0x2fdbf8?_0x273cde['hide']():_0x273cde['show']();});}}class hi extends et{['_resizeObserver']=null;constructor(_0x45066f,_0x36f0e9){super(_0x45066f,_0x36f0e9);const _0x56a9e4=this['bindTemplate'];this['set']({'label':R(_0x45066f,'Revision\x20name'),'_tooltipString':''}),this['fieldView']['placeholder']=R(_0x45066f,'Enter\x20the\x20revision\x20name'),this['extendTemplate']({'tag':'span','attributes':{'class':['ck-revision-history-sidebar__revision-name'],'data-cke-tooltip-text':_0x56a9e4['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 _0x284ef5=this['fieldView']['element'];this['_tooltipString']=_0x284ef5['scrollWidth']>_0x284ef5['clientWidth']&&_0x284ef5['value']||'';}}class ni extends _0x366bc3{constructor(_0x4b86d1,_0x28e644,_0x24379f){super(_0x4b86d1);const _0x52cd24=new _0x4f1c42();_0x52cd24['set']({'content':_0x1b5193,'viewBox':'0\x200\x2011\x2010'});const _0x54f0ac=['ck','ck-revision-history-sidebar__revision-author'];_0x24379f&&_0x54f0ac['push']('ck-revision-history-sidebar__revision-author_creator');const _0x187a87=[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision-author__name'],'title':R(_0x4b86d1,_0x24379f?'Revision\x20creator':'Revision\x20author')},'children':[_0x52cd24,_0x28e644['name']]}];this['setTemplate']({'tag':'li','attributes':{'class':_0x54f0ac},'children':_0x187a87});}}function ai(_0x334ff9,_0x561527){const _0x29a91d=_0x334ff9['bindTemplate'],_0x11f6e9=_0x334ff9['locale'],_0x15bbe4=_0x31cb79(_0x11f6e9);_0x15bbe4['panelPosition']='sw';const _0x1275f4=function(_0x4413cf,_0x12b555){const _0x4f17bb=function(_0x49e3aa,_0x1a96ed){const _0x581085=_0x49e3aa['locale'],_0x108526={'Compare\x20against\x20selected':R(_0x581085,'Compare\x20against\x20selected'),'Name\x20this\x20revision':R(_0x581085,'Name\x20this\x20revision'),'Restore\x20this\x20revision':R(_0x581085,'Restore\x20this\x20revision')};return _0x1a96ed['map'](_0x30e0b6=>{const _0x522fbd=_0x108526[_0x30e0b6['name']];return _0x522fbd&&_0x522fbd!==_0x30e0b6['name']&&(_0x30e0b6['name']=_0x522fbd),_0x30e0b6;});}(_0x4413cf,_0x12b555),_0x254bc0=new _0x2d6f70();for(const _0x173aae of _0x4f17bb){const _0x51354d={'type':'button','model':new to({'label':_0x173aae['name'],'class':_0x173aae['class'],'withText':!0x0,'role':'menuitem','_action':_0x173aae['action']})};_0x51354d['model']['bind']('isEnabled')['to'](_0x4413cf,'isActionsDropdownOpen',_0x335c86=>'function'!=typeof _0x173aae['isEnabled']||(!_0x335c86||_0x173aae['isEnabled'](_0x4413cf))),_0x254bc0['add'](_0x51354d);}return _0x254bc0;}(_0x334ff9,_0x561527);return _0x334ff9['bind']('isActionsDropdownOpen')['to'](_0x15bbe4,'isOpen'),_0x15bbe4['buttonView']['set']({'label':R(_0x11f6e9,'Show\x20more\x20items'),'tooltip':!0x0,'tooltipPosition':'sw','icon':_0x130113}),_0x15bbe4['extendTemplate']({'attributes':{'class':['ck-revision-history-sidebar__revision__actions',_0x29a91d['if']('isActionsDropdownOpen','ck-on')]},'on':{'click':_0x29a91d['to'](_0x12b85d=>_0x12b85d['stopPropagation']())}}),_0x15bbe4['on']('execute',_0x134fc0=>{_0x334ff9['isReady']&&'function'==typeof _0x134fc0['source']['_action']&&_0x134fc0['source']['_action'](_0x334ff9);}),_0x4e33a1(_0x15bbe4,_0x1275f4,{'role':'menu'}),_0x15bbe4['listenTo'](_0x334ff9,'change:isActionsDropdownOpen',(_0x1f4f2f,_0x4c47c3,_0x414b51)=>{if(_0x414b51)for(const _0x3137ce of _0x15bbe4['listView']['items']){const _0x2fd26c=_0x3137ce['children']['first'],_0x34f0c1=_0x561527['find'](_0x591280=>_0x591280['action']===_0x2fd26c['_action'])['isVisible'];_0x3137ce['isVisible']=void 0x0===_0x34f0c1||_0x34f0c1(_0x334ff9);}}),_0x15bbe4;}class _i extends/* #__PURE__ -- @preserve */
|
|
27
|
+
_0x3b9285(_0x366bc3){['id'];['revisionNameView'];['revisionActionsView'];['_revision'];['_requireRevisionName'];constructor(_0x64444f,_0xdea2fd,_0x345d4d,_0x5dcd1b){super(_0x64444f);const _0x171488=this['bindTemplate'],_0xd409c8=function(_0x546dda,_0x226fe2){const _0x2d64e7=Array['from'](_0x226fe2['authors'])['filter'](_0x1cbd2c=>_0x1cbd2c!=_0x226fe2['creator']);return _0x226fe2['creator']&&_0x2d64e7['unshift'](_0x226fe2['creator']),_0x2d64e7['map'](_0x21252d=>new ni(_0x546dda,_0x21252d,_0x21252d==_0x226fe2['creator']));}(_0x64444f,_0xdea2fd);this['id']=_0xdea2fd['id'],this['_revision']=_0xdea2fd,this['_requireRevisionName']=_0x5dcd1b,this['bind']('name','createdAt')['to'](_0xdea2fd),this['bind']('_createdAtFormatted')['to'](this,'createdAt',_0x91f6ca=>{return _0x1eb182=_0x64444f['uiLanguage'],(_0x3e1d65=_0x91f6ca)['toLocaleDateString'](_0x1eb182,{'month':'long','day':'numeric'})+',\x20'+_0x3e1d65['toLocaleTimeString'](_0x1eb182,{'hour':'numeric','minute':'numeric'});var _0x1eb182,_0x3e1d65;}),this['set']('isSelected',!0x1),this['set']('isHighlighted',!0x1),this['set']('isActionsDropdownOpen',!0x1),this['set']('isReady',!0x1),this['set']('isEnabled',!0x1),this['revisionNameView']=new hi(_0x64444f,ti),this['revisionNameView']['fieldView']['extendTemplate']({'attributes':{'maxlength':'220'}}),this['revisionNameView']['fieldView']['bind']('value')['to'](this,'name',_0x5b21d0=>_0x5b21d0||this['_createdAtFormatted']),this['revisionNameView']['bind']('isEnabled')['to'](this,'isSelected',this,'isEnabled',(_0x21ae89,_0x4e187e)=>_0x21ae89&&_0x4e187e),this['revisionActionsView']=_0x345d4d&&_0x345d4d['length']?ai(this,_0x345d4d):'',this['revisionActionsView']&&this['revisionActionsView']['bind']('isEnabled')['to'](this),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision-wrapper',_0x171488['if']('isConfirm','ck-revision-history-sidebar__revision-wrapper_confirmation_visible')]},'children':[{'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision',_0x171488['if']('isEnabled','ck-disabled',_0x290cc5=>!_0x290cc5),_0x171488['if']('isSelected','ck-revision-history-sidebar__revision_selected'),_0x171488['if']('isHighlighted','ck-revision-history-sidebar__revision_highlighted'),_0x171488['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':_0x171488['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':_0xd409c8}]},this['revisionActionsView']],'on':{'click':_0x171488['to'](_0x3ac99f=>{_0x3ac99f['srcElement']['closest']('.ck-confirm-view')||this['isReady']&&this['isEnabled']&&this['fire']('select',{'id':this['id']});})}}]});}['render'](){super['render']();const _0x2226e9=this['revisionNameView']['fieldView']['element'];this['listenTo'](_0x2226e9,'change',()=>{this['_requireRevisionName']&&!_0x2226e9['value']||this['fire']('setName',{'id':this['id'],'name':_0x2226e9['value']}),_0x2226e9['value']||(_0x2226e9['value']=this['name']?this['name']:this['_createdAtFormatted']);});}['select'](){this['isSelected']=!0x0;}['deselect'](){this['isSelected']=!0x1;}['highlight'](){this['isHighlighted']=!0x0;}['unhighlight'](){this['isHighlighted']=!0x1;}}function li(_0x57dd07,_0x46cd49){const _0xbfe555=_0x33fe39['fromJSDate'](_0x57dd07)['setLocale'](_0x46cd49),_0x3be407=_0x33fe39['local'](),_0x1c5344=_0x3be407['minus']({'days':0x1})['startOf']('day');let _0x2490c4,_0x163f94;return _0xbfe555['hasSame'](_0x3be407,'day')?(_0x2490c4=_0xbfe555['startOf']('day')['toJSDate'](),_0x163f94=_0xbfe555['toRelativeCalendar']()):_0xbfe555['hasSame'](_0x1c5344,'day')?(_0x2490c4=_0x1c5344['toJSDate'](),_0x163f94=_0xbfe555['toRelativeCalendar']()):_0xbfe555['hasSame'](_0x3be407,'week')?(_0x2490c4=_0xbfe555['startOf']('week')['toJSDate'](),_0x163f94=_0xbfe555['weekdayLong']||''):_0xbfe555['hasSame'](_0x3be407,'year')?(_0x2490c4=_0xbfe555['startOf']('month')['toJSDate'](),_0x163f94=_0xbfe555['monthLong']||''):(_0x2490c4=_0xbfe555['startOf']('year')['toJSDate'](),_0x163f94=String(_0xbfe555['year'])),{'startDate':_0x2490c4,'localizedPeriodName':_0x163f94};}class bi extends _0x366bc3{['startDate'];['revisionViews'];['_revisionActions'];['_requireRevisionName'];constructor(_0x4c2ca7,_0x391ffc,_0x40d285,_0x6dec7b){super(_0x4c2ca7);const _0x5ee7eb=li(_0x391ffc,this['locale']['uiLanguage'])['localizedPeriodName'];this['startDate']=_0x391ffc,this['revisionViews']=this['createCollection'](),this['_revisionActions']=_0x40d285,this['_requireRevisionName']=_0x6dec7b,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':_0x5ee7eb}]},{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__time-period__revisions']},'children':this['revisionViews']}]});}['addRevision'](_0x302237){const _0x52af83=new _i(this['locale'],_0x302237,this['_revisionActions'],this['_requireRevisionName']);this['revisionViews']['add'](_0x52af83);}['removeRevision'](_0x41857d){const _0x5ef940=this['revisionViews']['find'](_0x3aae49=>_0x3aae49['id']===_0x41857d['id']);this['revisionViews']['remove'](_0x5ef940);}}class fi extends _0x366bc3{constructor(_0x5aab1a){super(_0x5aab1a);const _0x35643b=new _0x4f1c42();_0x35643b['content']=_0x179e8c,this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset_all','ck-revision-history-sidebar__header']},'children':[_0x35643b,{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__header__label']},'children':[R(_0x5aab1a,'Revision\x20history')]}]});}}class di extends _0x366bc3{['timePeriodViews'];['_revisions'];['_revisionActions'];['_requireRevisionName'];constructor(_0x311be9,_0x2e7c38,_0x3d8897,_0x41eb3f){super(_0x311be9);const _0x35125d=this['bindTemplate'];this['timePeriodViews']=this['createCollection'](),this['timePeriodViews']['delegate']('select')['to'](this),this['timePeriodViews']['delegate']('setName')['to'](this),this['_revisions']=_0x2e7c38,this['_revisionActions']=_0x3d8897,this['_requireRevisionName']=_0x41eb3f,this['on']('select',(_0x240da5,_0x11d045)=>{this['fire']('revisionSelected',_0x11d045);}),this['on']('setName',(_0x2f2551,_0x2161fb)=>{this['fire']('revisionSetName',_0x2161fb);}),this['set']('isEnabled',!0x1),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-rounded-corners','ck-revision-history-sidebar']},'children':[new fi(_0x311be9),{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__timeline',_0x35125d['if']('isEnabled','ck-disabled',_0x459d00=>!_0x459d00)]},'children':this['timePeriodViews']}]});}['render'](){super['render']();for(const _0x18fa84 of this['_revisions'])this['_addRevision'](_0x18fa84);this['_revisions']['on']('add',(_0x4efe32,_0x554dac)=>{this['_addRevision'](_0x554dac);}),this['_revisions']['on']('remove',(_0x5a9bc9,_0x2b6dcf)=>{this['_removeRevision'](_0x2b6dcf);});}get['revisionViews'](){return this['timePeriodViews']['map'](_0x287b21=>_0x287b21['revisionViews']['map'](_0x8302f2=>_0x8302f2))['flat']();}['selectRevision'](_0x13f14a){for(const _0x222c92 of this['revisionViews'])_0x13f14a&&_0x13f14a['id']===_0x222c92['id']?_0x222c92['select']():_0x222c92['deselect']();}['highlightRevisions'](_0x5f1d5d){for(const _0x4a1adb of this['revisionViews'])_0x5f1d5d['some'](({id:_0x5aa0ee})=>_0x5aa0ee===_0x4a1adb['id'])?_0x4a1adb['highlight']():_0x4a1adb['unhighlight']();}['_addRevision'](_0x4cbf1e){const _0x184676=li(_0x4cbf1e['createdAt'],this['locale']['uiLanguage'])['startDate'];let _0x10045e=this['timePeriodViews']['get'](0x0);_0x10045e&&_0x10045e['startDate']['getTime']()===_0x184676['getTime']()||(_0x10045e=new bi(this['locale'],_0x184676,this['_revisionActions'],this['_requireRevisionName']),this['timePeriodViews']['add'](_0x10045e)),_0x10045e['addRevision'](_0x4cbf1e);}['_removeRevision'](_0x140517){const _0x389d87=li(_0x140517['createdAt'],this['locale']['uiLanguage'])['startDate'];this['_getTimePeriodViewByStartDate'](_0x389d87)['removeRevision'](_0x140517);}['_getTimePeriodViewByStartDate'](_0x3189b6){return this['timePeriodViews']['find'](_0x421e58=>_0x421e58['startDate']['getTime']()===_0x3189b6['getTime']());}}class f extends _0x382226{['_revisionViewer'];['_revisionsRepository'];['_sidebarView'];static ['defaultRevisionActions']=/* #__PURE__ -- @preserve */
|
|
28
28
|
((()=>['compareAgainstSelected','restoreRevision','nameRevision'])());static ['availableRevisionActions']=/* #__PURE__ -- @preserve */
|
|
29
|
-
|
|
30
|
-
_0x320a62(_0x282fb8){['_ui'];get['ui'](){return this['_ui'];}constructor(_0x1b9894,_0x4dee85){super(_0x4dee85),this['sourceElement']=_0x1b9894,this['model']['document']['createRoot']();const _0x20a236=new ii(this['locale'],this['editing']['view'],{'shouldToolbarGroupWhenFull':!0x0});this['_ui']=new Z(this,_0x20a236);}['destroy'](){return this['updateSourceElement'](),this['ui']['destroy'](),super['destroy']();}static async['create'](_0x16e227,_0x2c6242){const _0xdb022d=new this(_0x16e227,_0x2c6242);return await _0xdb022d['initPlugins'](),await _0xdb022d['ui']['init'](_0x16e227),await _0xdb022d['data']['init'](_0xdb022d['config']['get']('initialData')||''),_0xdb022d['fire']('ready'),_0xdb022d;}}const d=['RevisionHistoryUI','RestrictedEditingMode'];class at extends _0x280bdd{['result'];static get['pluginName'](){return'RevisionViewerIntegration';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0xd2059b){function _0x33f693(_0x3468c3){return _0x3468c3['map'](_0xfa6cfd=>String['fromCharCode'](_0xfa6cfd))['join']('');}super(_0xd2059b),this['result']='end',_0xd2059b[_0x33f693([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x33f693([0x76,0x69,0x65,0x77])][_0x33f693([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x33f693([0x61,0x75,0x74,0x6f]),_0xd2059b[_0x33f693([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x33f693([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x33f693([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x33f693([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x33f693([0x6f,0x6b])});}}class ht extends _0x280bdd{['_viewerEditor'];static get['pluginName'](){return'RevisionHistory';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[h,v];}constructor(_0x193eee){if(super(_0x193eee),!this['editor']['config']['get']('revisionHistory'))throw new _0x5eb79a('revision-history-missing-configuration',this);this['_viewerEditor']=null,this['set']('isRevisionViewerOpen',!0x1),this['editor']['config']['define']('revisionHistory.showRevisionViewerCallback',_0xbd9aea=>this['_showRevisionViewer']({..._0xbd9aea,'translations':this['editor']['locale']['translations']})),this['editor']['config']['define']('revisionHistory.closeRevisionViewerCallback',_0x5a9bb3=>this['_closeRevisionViewer'](_0x5a9bb3)),this['editor']['config']['define']('revisionHistory.restoreRevisionCallback',_0x3fff20=>this['_restoreRevision'](_0x3fff20)),this['editor']['config']['define']('revisionHistory.requireRevisionName',!0x1),this['_enhanceShowRevisionViewerCallback'](),this['_enhanceCloseRevisionViewerCallback']();}set['adapter'](_0x20e73c){this['editor']['plugins']['get']('RevisionTracker')['adapter']=_0x20e73c;}get['adapter'](){return this['editor']['plugins']['get']('RevisionTracker')['adapter'];}['addRevisionData'](_0x27615a){return this['editor']['plugins']['get']('RevisionTracker')['addRevisionData'](_0x27615a);}['getRevision'](_0x59c8a7){return this['editor']['plugins']['get']('RevisionsRepository')['getRevision'](_0x59c8a7);}['getRevisions'](_0x236e90){return this['editor']['plugins']['get']('RevisionsRepository')['getRevisions'](_0x236e90||{'toJSON':!0x1});}['_getRevisionViewerEditorConfig'](){const _0x543412=this['editor'],_0x4dbe54=_0x368f06(_0x543412,d),_0x4401b0=_0x543412['plugins']['get']('RevisionTracker'),_0x45088a=_0x543412['plugins']['get']('Users')['users'];return _0x4dbe54['toolbar']=['exitToEditing','restoreRevision','changesNavigation'],delete _0x4dbe54['lazyRoots'],(_0x4dbe54['plugins']['push'](at,l,u,class extends _0x280bdd{static get['requires'](){return[l,'Users'];}['init'](){const _0x3bc510=this['editor']['plugins']['get']('Users');for(const _0x51cc6f of _0x45088a)_0x51cc6f['isAnonymous']||_0x3bc510['getUser'](_0x51cc6f['id'])||_0x3bc510['addUser'](_0x51cc6f);const _0x5b6ff2=_0x4401b0['repository']['getRevisions']();let _0x488b3b=null;const _0x26500b=this['editor']['plugins']['get']('RevisionViewer');_0x26500b['adapter']=_0x4401b0['adapter'],_0x26500b['bind']('isEnabled')['to'](_0x4401b0),this['editor']['commands']['get']('restoreRevision')['bind']('isEnabled')['to'](_0x543412,'isReadOnly',_0xac373f=>!_0xac373f);for(const _0x3dc6e6 of _0x5b6ff2){const _0x77557d=null===_0x3dc6e6['creator'];if(_0x77557d&&_0x3dc6e6['toVersion']===_0x3dc6e6['fromVersion'])continue;const _0x215803=_0x3dc6e6['toJSON']();_0x26500b['addRevisionData'](_0x215803,(_0x1b66f6,_0x5b619b,_0x4edc49)=>{if(_0x77557d){if(_0x488b3b)_0x488b3b['_update'](_0x1b66f6,_0x5b619b);else{if(!_0x5b619b){const _0x203c6b=_0x4edc49['toJSON']();_0x203c6b['id']=_0x4df7d4(),_0x4401b0['saveRevision'](_0x203c6b,_0x4edc49['toVersion'])['then'](_0xf3eed9=>{_0x488b3b=_0xf3eed9;});}}}else _0x3dc6e6['_update'](_0x1b66f6,_0x5b619b);});}}},f),_0x4dbe54);}['_enhanceShowRevisionViewerCallback'](){const _0x59ec87=this['editor']['config']['get']('revisionHistory')['showRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.showRevisionViewerCallback',async()=>{this['editor']['enableReadOnlyMode']('revision-history-viewer-opened');const _0x48d5b1=this['editor']['plugins']['get']('RevisionTracker');if(this['editor']['plugins']['has']('Autosave')){const _0x2a5997=this['editor']['plugins']['get']('Autosave');await _0x2a5997['save']();}else await _0x48d5b1['update']();if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('Dialog')){const _0xd101b5=this['editor']['plugins']['get']('Dialog');_0xd101b5['isOpen']&&_0xd101b5['hide']();}const _0x4a0e48=this['_getRevisionViewerEditorConfig']();return _0x59ec87(_0x4a0e48)['then'](_0x53b104=>{return(this['_viewerEditor']=_0x53b104,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'),_0x53b104);})['catch'](_0x464e8a=>(console['error'](_0x464e8a),this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),null));});}['_enhanceCloseRevisionViewerCallback'](){const _0x2c7437=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'](),_0x2c7437(this['_viewerEditor'])['then'](()=>{if(this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),this['_viewerEditor']=null,this['editor']['plugins']['has']('Annotations')){const _0x10a3f3=this['editor']['plugins']['get']('Annotations');_0x10a3f3['refreshVisibility'](),_0x10a3f3['refreshPositioning']();}})));}['_showRevisionViewer'](_0x1886da){const _0x23a8d1=this['editor']['config']['get']('revisionHistory.editorContainer'),_0x469ac2=this['editor']['config']['get']('revisionHistory.viewerContainer'),_0xffa717=this['editor']['config']['get']('revisionHistory.viewerEditorElement');return m['create'](_0xffa717,_0x1886da)['then'](_0x4945e3=>(_0x469ac2['style']['display']='block',_0x23a8d1['style']['display']='none',this['isRevisionViewerOpen']=!0x0,_0x4945e3));}['_closeRevisionViewer'](_0xa331bd){const _0x25be4e=this['editor']['config']['get']('revisionHistory.editorContainer');return this['editor']['config']['get']('revisionHistory.viewerContainer')['style']['display']='none',_0x25be4e['style']['display']='',this['isRevisionViewerOpen']=!0x1,_0xa331bd['destroy']();}async['_restoreRevision'](_0x59aecc){const _0x1ce8bd=this['editor'],_0x58c758=this['_viewerEditor']['plugins']['get']('RevisionViewer'),_0x40df13=_0x1ce8bd['plugins']['get']('RevisionTracker'),_0x10ed03=_0x1ce8bd['plugins']['get']('RevisionHistoryUtils'),_0x8b0f83=_0x58c758['repository']['getRevision'](_0x59aecc);let _0x287132,_0x2ad4db,_0x382392;try{await _0x10ed03['loadRevisionData'](_0x8b0f83,this['adapter']),_0x287132=_0x10ed03['getRevisionDocumentData'](_0x8b0f83),_0x2ad4db=_0x10ed03['getRevisionRootsAttributes'](_0x8b0f83);}catch(_0x32954d){return void console['error'](_0x32954d);}_0x1ce8bd['model']['change'](_0x25f357=>{for(const _0x40e15b of Array['from'](_0x1ce8bd['model']['markers']['getMarkersGroup']('restrictedEditingException')))_0x25f357['removeMarker'](_0x40e15b);}),_0x58c758['isReady']=!0x1,_0x1ce8bd['model']['enqueueChange'](_0x46045a=>{_0x46045a['setSelection'](null),_0x46045a['removeSelectionAttribute'](_0x1ce8bd['model']['document']['selection']['getAttributeKeys']());const _0x2b7578=Object['keys'](_0x287132);for(const _0x2debe8 of _0x1ce8bd['model']['document']['roots'])'$graveyard'!=_0x2debe8['rootName']&&_0x2debe8['isAttached']()&&!_0x2b7578['includes'](_0x2debe8['rootName'])&&_0x46045a['detachRoot'](_0x2debe8);for(const _0x2637eb of _0x2b7578){let _0x5b6a5d=_0x1ce8bd['model']['document']['getRoot'](_0x2637eb);_0x5b6a5d&&_0x5b6a5d['isAttached']()||(_0x5b6a5d=_0x46045a['addRoot'](_0x2637eb));const _0x2d5340=_0x2ad4db[_0x2637eb],_0x27838b=Object['keys'](_0x2d5340),_0x26e76a=_0x287132[_0x2637eb];for(const _0x512aef of _0x5b6a5d['getAttributeKeys']())_0x27838b['includes'](_0x512aef)||_0x46045a['removeAttribute'](_0x512aef,_0x5b6a5d);for(const _0x499976 of _0x27838b)_0x46045a['setAttribute'](_0x499976,_0x2ad4db[_0x2637eb][_0x499976],_0x5b6a5d);_0x46045a['remove'](_0x46045a['createRangeIn'](_0x5b6a5d)),_0x46045a['insert'](_0x1ce8bd['data']['parse'](_0x26e76a,_0x5b6a5d),_0x5b6a5d,0x0);}});const _0x21d7e0=R(_0x1ce8bd['locale'],'Restored');if(_0x8b0f83['name'])_0x382392=-0x1==_0x8b0f83['name']['indexOf'](_0x21d7e0)?_0x21d7e0+':\x20'+_0x8b0f83['name']:_0x8b0f83['name'];else _0x382392=_0x21d7e0+':\x20'+(_0x8b0f83['createdAt']['toLocaleDateString'](_0x1ce8bd['locale']['uiLanguage'],{'month':'long','day':'numeric'})+',\x20'+_0x8b0f83['createdAt']['toLocaleTimeString'](_0x1ce8bd['locale']['uiLanguage'],{'hour':'numeric','minute':'numeric'}));return await _0x40df13['saveRevision']({'name':_0x382392}),_0x58c758['isReady']=!0x0,_0x1ce8bd['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(_0x200680){super(_0x200680),this['_revisionViewer']=_0x200680['plugins']['get'](l),this['_revisionsRepository']=this['_revisionViewer']['repository'],this['_sidebarView']=null;}['init'](){const _0x5a6c4f=this['_revisionsRepository']['_revisions'],_0x14b4d8=this['_createRevisionActions'](),_0x3b1603=this['editor']['config']['get']('revisionHistory.viewerSidebarContainer');this['_sidebarView']=new di(this['editor']['locale'],_0x5a6c4f,_0x14b4d8,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',(_0x587a75,_0x409a23)=>{_0x409a23['revisionViews']['on']('add',(_0x5a6312,_0x4a4a7b)=>{_0x4a4a7b['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)),_0x3b1603['appendChild'](this['_sidebarView']['element']);}['destroy'](){this['_sidebarView']['element']['remove'](),this['_sidebarView']['destroy']();}['_handleEditorDataReady'](){const _0x5d4deb=this['_revisionsRepository']['getRevision'](0x0);if(_0x5d4deb){const _0x41d0bc=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x5d4deb['id']);this['_revisionViewer']['compare'](_0x5d4deb,_0x41d0bc);}}['_handleRevisionSelected'](_0xfc7198,_0x22b358){const _0x1e2c2f=this['_revisionsRepository']['getRevision'](_0x22b358['id']),_0x135c34=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x1e2c2f['id']);this['_revisionViewer']['compare'](_0x1e2c2f,_0x135c34);}['_handleRevisionSetName'](_0xe03d10,_0x252bc1){this['_revisionsRepository']['getRevision'](_0x252bc1['id'])['setName'](_0x252bc1['name']);}['_handleDiffChange'](_0x68869a,_0x3b596d,_0x37d29e){const _0x3af48f=this['_revisionsRepository']['getRevisionsInDiff'](_0x37d29e);_0x3af48f['length']>0x2?(this['_sidebarView']['highlightRevisions'](_0x3af48f),this['_sidebarView']['selectRevision'](null)):(this['_sidebarView']['highlightRevisions']([]),this['_sidebarView']['selectRevision'](_0x3af48f[0x0]));}['_createRevisionActions'](){const _0xc5e4c9=this['editor'],_0x454792=f['availableRevisionActions'],_0xd694e8=_0xc5e4c9['config']['get']('revisionHistory.revisionActions')||f['defaultRevisionActions'];if(_0xd694e8['length'])return _0xd694e8['map'](_0x4ed049=>{const _0x4fb345='string'==typeof _0x4ed049?Object['assign']({},_0x454792[_0x4ed049]):_0x4ed049;return _0x4fb345['action']=_0x4fb345['action']['bind'](this,_0xc5e4c9),_0x4fb345['isVisible']&&(_0x4fb345['isVisible']=_0x4fb345['isVisible']['bind'](this,_0xc5e4c9)),_0x4fb345;});}}function at(){return{'compareAgainstSelected':{'name':'Compare\x20against\x20selected','action':({plugins:_0x363f0c},_0x2c9f59)=>{const _0x4448c2=_0x363f0c['get'](l),_0x4eba8c=_0x4448c2['repository'];let _0x121c82=_0x4448c2['diff']['newRevisionId'],_0x426251=_0x2c9f59['id'];_0x4eba8c['getIndex'](_0x121c82)>_0x4eba8c['getIndex'](_0x426251)&&([_0x121c82,_0x426251]=[_0x426251,_0x121c82]),_0x4448c2['compare'](_0x121c82,_0x426251);},'isVisible':({plugins:_0x296f20},_0x1260cf)=>{const _0x4df183=_0x296f20['get'](l);return!(_0x4df183['repository']['getRevisionsInDiff'](_0x4df183['diff'])['length']>0x2)&&!_0x1260cf['isSelected'];}},'restoreRevision':{'name':'Restore\x20this\x20revision','action':(_0x5ea100,{id:_0x3a5bf7})=>{_0x5ea100['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x3a5bf7);},'isVisible':({plugins:_0x48008b},_0x551b64)=>!!_0x48008b['get'](l)['repository']['getLaterVisibleRevision'](_0x551b64['id'])},'nameRevision':{'name':'Name\x20this\x20revision','action':({plugins:_0x5b6740},{id:_0x26cb6c,revisionNameView:_0x2285a8})=>{const _0x41cfab=_0x5b6740['get'](l),_0x5c89f3=_0x41cfab['repository']['getEarlierVisibleRevision'](_0x26cb6c);_0x41cfab['compare'](_0x26cb6c,_0x5c89f3),_0x2285a8['focus'](),_0x2285a8['fieldView']['select']();}}};}class Z extends tt{['_view'];['_toolbarConfig'];['_elementReplacer'];get['view'](){return this['_view'];}constructor(_0x4c382d,_0x40a881){super(_0x4c382d),this['_view']=_0x40a881,this['_toolbarConfig']=st(_0x4c382d['config']['get']('toolbar')),this['_elementReplacer']=new it();}get['element'](){return this['view']['element'];}['init'](_0x378e09){const _0x2c7989=this['editor'],_0x21e266=this['view'],_0x1c87a5=_0x2c7989['editing']['view'],_0x175631=_0x21e266['editable'],_0x358a83=_0x1c87a5['document']['getRoot']();_0x175631['name']=_0x358a83['rootName'],_0x21e266['render']();const _0x497bf8=_0x175631['element'];this['setEditableElement'](_0x175631['name'],_0x497bf8),_0x21e266['editable']['bind']('isFocused')['to'](this['focusTracker']),_0x1c87a5['attachDomRoot'](_0x497bf8),this['_elementReplacer']['replace'](_0x378e09,this['element']),this['_initToolbar'](),this['fire']('ready');}['destroy'](){super['destroy']();const _0x39488d=this['view'],_0x31e2be=this['editor']['editing']['view'];this['_elementReplacer']['restore'](),_0x31e2be['detachDomRoot'](_0x39488d['editable']['name']),_0x39488d['destroy']();}['_initToolbar'](){const _0x4cbfb9=this['view'];_0x4cbfb9['stickyPanel']['bind']('isActive')['to'](this['focusTracker'],'isFocused'),_0x4cbfb9['stickyPanel']['limiterElement']=_0x4cbfb9['element'],_0x4cbfb9['stickyPanel']['bind']('viewportTopOffset')['to'](this,'viewportOffset',({top:_0x2173d4})=>_0x2173d4),_0x4cbfb9['toolbar']['fillFromConfig'](this['_toolbarConfig'],this['componentFactory']),this['addToolbar'](_0x4cbfb9['toolbar']);}}class ii extends _0x6f8624{['_editable'];['stickyPanel'];['toolbar'];get['editable'](){return this['_editable'];}constructor(_0x272012,_0x4c448f,_0xba2f11={}){super(_0x272012),this['stickyPanel']=new _0x7dd8fd(_0x272012),this['toolbar']=new _0x14d8c1(_0x272012,{'shouldGroupWhenFull':_0xba2f11['shouldToolbarGroupWhenFull']}),this['_editable']=new te(_0x272012,_0x4c448f);}['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
|
+
_0x161316(_0x4558d5){['_ui'];get['ui'](){return this['_ui'];}constructor(_0x55b1ec,_0x142f21){super(_0x142f21),this['sourceElement']=_0x55b1ec,this['model']['document']['createRoot']();const _0x5975ed=new ii(this['locale'],this['editing']['view'],{'shouldToolbarGroupWhenFull':!0x0});this['_ui']=new Z(this,_0x5975ed);}['destroy'](){return this['updateSourceElement'](),this['ui']['destroy'](),super['destroy']();}static async['create'](_0x2e0ac9,_0x12d234){const _0x2a5571=new this(_0x2e0ac9,_0x12d234);return await _0x2a5571['initPlugins'](),await _0x2a5571['ui']['init'](_0x2e0ac9),await _0x2a5571['data']['init'](_0x2a5571['config']['get']('initialData')||''),_0x2a5571['fire']('ready'),_0x2a5571;}}const d=['RevisionHistoryUI','RestrictedEditingMode'];class ht extends _0x382226{['result'];static get['pluginName'](){return'RevisionViewerIntegration';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x4b54b3){function _0x4663c0(_0x54eb68){return _0x54eb68['map'](_0x24d7c8=>String['fromCharCode'](_0x24d7c8))['join']('');}super(_0x4b54b3),this['result']='end',_0x4b54b3[_0x4663c0([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x4663c0([0x76,0x69,0x65,0x77])][_0x4663c0([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x4663c0([0x61,0x75,0x74,0x6f]),_0x4b54b3[_0x4663c0([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x4663c0([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x4663c0([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x4663c0([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x4663c0([0x6f,0x6b])});}}class ct extends _0x382226{['_viewerEditor'];static get['pluginName'](){return'RevisionHistory';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[h,v];}constructor(_0x7bb0c2){if(super(_0x7bb0c2),!this['editor']['config']['get']('revisionHistory'))throw new _0x1aab03('revision-history-missing-configuration',this);this['_viewerEditor']=null,this['set']('isRevisionViewerOpen',!0x1),this['editor']['config']['define']('revisionHistory.showRevisionViewerCallback',_0x191af7=>this['_showRevisionViewer']({..._0x191af7,'translations':this['editor']['locale']['translations']})),this['editor']['config']['define']('revisionHistory.closeRevisionViewerCallback',_0x3f5665=>this['_closeRevisionViewer'](_0x3f5665)),this['editor']['config']['define']('revisionHistory.restoreRevisionCallback',_0x413ceb=>this['_restoreRevision'](_0x413ceb)),this['editor']['config']['define']('revisionHistory.requireRevisionName',!0x1),this['_enhanceShowRevisionViewerCallback'](),this['_enhanceCloseRevisionViewerCallback']();}set['adapter'](_0x3244b1){this['editor']['plugins']['get']('RevisionTracker')['adapter']=_0x3244b1;}get['adapter'](){return this['editor']['plugins']['get']('RevisionTracker')['adapter'];}['addRevisionData'](_0x4077ba){return this['editor']['plugins']['get']('RevisionTracker')['addRevisionData'](_0x4077ba);}['getRevision'](_0x33834c){return this['editor']['plugins']['get']('RevisionsRepository')['getRevision'](_0x33834c);}['getRevisions'](_0x16cfc1){return this['editor']['plugins']['get']('RevisionsRepository')['getRevisions'](_0x16cfc1||{'toJSON':!0x1});}['_getRevisionViewerEditorConfig'](){const _0x11cfb0=this['editor'],_0x34d216=_0x15a0ff(_0x11cfb0,d),_0x2d1a45=_0x11cfb0['plugins']['get']('RevisionTracker'),_0x5a2538=_0x11cfb0['plugins']['get']('Users')['users'];return _0x34d216['toolbar']=['exitToEditing','restoreRevision','changesNavigation'],delete _0x34d216['lazyRoots'],(_0x34d216['plugins']['push'](ht,l,u,class extends _0x382226{static get['requires'](){return[l,'Users'];}['init'](){const _0x53636e=this['editor']['plugins']['get']('Users');for(const _0x443615 of _0x5a2538)_0x443615['isAnonymous']||_0x53636e['getUser'](_0x443615['id'])||_0x53636e['addUser'](_0x443615);const _0x32e9a6=_0x2d1a45['repository']['getRevisions']();let _0x1182b8=null;const _0x548ee4=this['editor']['plugins']['get']('RevisionViewer');_0x548ee4['adapter']=_0x2d1a45['adapter'],_0x548ee4['bind']('isEnabled')['to'](_0x2d1a45),this['editor']['commands']['get']('restoreRevision')['bind']('isEnabled')['to'](_0x11cfb0,'isReadOnly',_0x4327aa=>!_0x4327aa);for(const _0xd291ce of _0x32e9a6){const _0x45c4a7=null===_0xd291ce['creator'];if(_0x45c4a7&&_0xd291ce['toVersion']===_0xd291ce['fromVersion'])continue;const _0x2d3417=_0xd291ce['toJSON']();_0x548ee4['addRevisionData'](_0x2d3417,(_0x49233e,_0x3aad92,_0x28959e)=>{if(_0x45c4a7){if(_0x1182b8)_0x1182b8['_update'](_0x49233e,_0x3aad92);else{if(!_0x3aad92){const _0xa19324=_0x28959e['toJSON']();_0xa19324['id']=_0xeb3ed1(),_0x2d1a45['saveRevision'](_0xa19324,_0x28959e['toVersion'])['then'](_0x2dfd7c=>{_0x1182b8=_0x2dfd7c;});}}}else _0xd291ce['_update'](_0x49233e,_0x3aad92);});}}},f),_0x34d216);}['_enhanceShowRevisionViewerCallback'](){const _0x366067=this['editor']['config']['get']('revisionHistory')['showRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.showRevisionViewerCallback',async()=>{this['editor']['enableReadOnlyMode']('revision-history-viewer-opened');const _0x50b8a8=this['editor']['plugins']['get']('RevisionTracker');if(this['editor']['plugins']['has']('Autosave')){const _0x38d71d=this['editor']['plugins']['get']('Autosave');await _0x38d71d['save']();}else await _0x50b8a8['update']();if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('Dialog')){const _0x53d276=this['editor']['plugins']['get']('Dialog');_0x53d276['isOpen']&&_0x53d276['hide']();}const _0x5b6f20=this['_getRevisionViewerEditorConfig']();return _0x366067(_0x5b6f20)['then'](_0x2dd1f0=>{return(this['_viewerEditor']=_0x2dd1f0,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'),_0x2dd1f0);})['catch'](_0x430012=>(console['error'](_0x430012),this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),null));});}['_enhanceCloseRevisionViewerCallback'](){const _0x2bd5bc=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'](),_0x2bd5bc(this['_viewerEditor'])['then'](()=>{if(this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),this['_viewerEditor']=null,this['editor']['plugins']['has']('Annotations')){const _0x283cd4=this['editor']['plugins']['get']('Annotations');_0x283cd4['refreshVisibility'](),_0x283cd4['refreshPositioning']();}})));}['_showRevisionViewer'](_0x12a433){const _0x195792=this['editor']['config']['get']('revisionHistory.editorContainer'),_0x41ffe0=this['editor']['config']['get']('revisionHistory.viewerContainer'),_0xc91826=this['editor']['config']['get']('revisionHistory.viewerEditorElement');return m['create'](_0xc91826,_0x12a433)['then'](_0x151eed=>(_0x41ffe0['style']['display']='block',_0x195792['style']['display']='none',this['isRevisionViewerOpen']=!0x0,_0x151eed));}['_closeRevisionViewer'](_0x2341b3){const _0x5dea1e=this['editor']['config']['get']('revisionHistory.editorContainer');return this['editor']['config']['get']('revisionHistory.viewerContainer')['style']['display']='none',_0x5dea1e['style']['display']='',this['isRevisionViewerOpen']=!0x1,_0x2341b3['destroy']();}async['_restoreRevision'](_0x43734d){const _0x4a818f=this['editor'],_0x3fefe8=this['_viewerEditor']['plugins']['get']('RevisionViewer'),_0x2f1066=_0x4a818f['plugins']['get']('RevisionTracker'),_0x3ed790=_0x4a818f['plugins']['get']('RevisionHistoryUtils'),_0x1be6f9=_0x3fefe8['repository']['getRevision'](_0x43734d);let _0x10fe0c,_0x45f92e,_0x29dba4;try{await _0x3ed790['loadRevisionData'](_0x1be6f9,this['adapter']),_0x10fe0c=_0x3ed790['getRevisionDocumentData'](_0x1be6f9),_0x45f92e=_0x3ed790['getRevisionRootsAttributes'](_0x1be6f9);}catch(_0x3cf28b){return void console['error'](_0x3cf28b);}_0x4a818f['model']['change'](_0x516175=>{for(const _0x32c1bd of Array['from'](_0x4a818f['model']['markers']['getMarkersGroup']('restrictedEditingException')))_0x516175['removeMarker'](_0x32c1bd);}),_0x3fefe8['isReady']=!0x1,_0x4a818f['model']['enqueueChange'](_0x3581e0=>{_0x3581e0['setSelection'](null),_0x3581e0['removeSelectionAttribute'](_0x4a818f['model']['document']['selection']['getAttributeKeys']());const _0x1fdb85=Object['keys'](_0x10fe0c);for(const _0x28e2a9 of _0x4a818f['model']['document']['roots'])'$graveyard'!=_0x28e2a9['rootName']&&_0x28e2a9['isAttached']()&&!_0x1fdb85['includes'](_0x28e2a9['rootName'])&&_0x3581e0['detachRoot'](_0x28e2a9);for(const _0x5890dd of _0x1fdb85){let _0xbe2283=_0x4a818f['model']['document']['getRoot'](_0x5890dd);_0xbe2283&&_0xbe2283['isAttached']()||(_0xbe2283=_0x3581e0['addRoot'](_0x5890dd));const _0x3447f5=_0x45f92e[_0x5890dd],_0xe24c76=Object['keys'](_0x3447f5),_0x4b2a14=_0x10fe0c[_0x5890dd];for(const _0x3577b1 of _0xbe2283['getAttributeKeys']())_0xe24c76['includes'](_0x3577b1)||_0x3581e0['removeAttribute'](_0x3577b1,_0xbe2283);for(const _0x18e08c of _0xe24c76)_0x3581e0['setAttribute'](_0x18e08c,_0x45f92e[_0x5890dd][_0x18e08c],_0xbe2283);_0x3581e0['remove'](_0x3581e0['createRangeIn'](_0xbe2283)),_0x3581e0['insert'](_0x4a818f['data']['parse'](_0x4b2a14,_0xbe2283),_0xbe2283,0x0);}});const _0xedaa1b=R(_0x4a818f['locale'],'Restored');if(_0x1be6f9['name'])_0x29dba4=-0x1==_0x1be6f9['name']['indexOf'](_0xedaa1b)?_0xedaa1b+':\x20'+_0x1be6f9['name']:_0x1be6f9['name'];else _0x29dba4=_0xedaa1b+':\x20'+(_0x1be6f9['createdAt']['toLocaleDateString'](_0x4a818f['locale']['uiLanguage'],{'month':'long','day':'numeric'})+',\x20'+_0x1be6f9['createdAt']['toLocaleTimeString'](_0x4a818f['locale']['uiLanguage'],{'hour':'numeric','minute':'numeric'}));return await _0x2f1066['saveRevision']({'name':_0x29dba4}),_0x3fefe8['isReady']=!0x0,_0x4a818f['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,ji as RevisionViewerLoadingOverlay,u as RevisionViewerUI,S as RevisionsRepository,f as RevisionsSidebar,rt as ShowChangeCommand};
|